Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Good looking Blueprint View #962

Merged
merged 15 commits into from
Jan 27, 2023
Merged

Good looking Blueprint View #962

merged 15 commits into from
Jan 27, 2023

Conversation

emilk
Copy link
Member

@emilk emilk commented Jan 27, 2023

This adds a nice hover-effect on the items in the blueprint tree.

This was a lot more work than I anticipated, and not much code to show for it. A lot of false starts. Though for a long time that I would have to get emilk/egui#2633 merged before doing this (so I spent quite some time on it), but then realized I didn't. Anyways, I think it looks and feels very nice now. Not perfect, but Good Enough.

blueprint-hover-niceness

Closes #953

Checklist

  • I have read and agree to Contributor Guide and the Code of Conduct
  • I've included a screenshot or gif (if applicable)
  • I've added a line to CHANGELOG.md (if this is a big enough change to warrant it)

@Wumpf Wumpf self-requested a review January 27, 2023 16:28
Copy link
Member

@Wumpf Wumpf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gorgeous!!
what I like a lot about this is that it makes it a lot easier to select stuff with short names in the blueprint

Comment on lines +623 to +625
let button_hovered = ui
.interact(main_button_rect, ui.id(), egui::Sense::hover())
.hovered();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we sync up with the global hover state right here? (i.e. close most of #935 as unmerged then?)
btw. with #964 we'll have relevant hover effects a lot more often 😃

Copy link
Member Author

@emilk emilk Jan 27, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We would still want #935 for all other buttons, but yeah, good idea! Though it requires some more piping, so will do in a later PR

@emilk emilk merged commit 31e8d0f into main Jan 27, 2023
@emilk emilk deleted the emilk/blueprint-view-ui branch January 27, 2023 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Hovering a menu also hovers things below it
2 participants