-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Added scrollable style focused
to be displayed when mouse is over the scrollable area
#1669
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the name should be hovered
instead of focused
, like in a button::StyleSheet
.
The point is that |
@hecrj may I ask you what can I do to make this PR ready to be merged? |
@GyulyVGC We need a better name here. |
You are free to suggest a name of your preference. Hovered would be awesome, but the problem is that it's already used. |
I think we could just add a boolean |
Wouldn't this method also require to pass two distinct As an alternative, what about naming it |
No. The |
Following your suggestion, I renamed it to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
I just added the is_mouse_over_scrollbar
flag as I suggested in the end. No need for additional methods.
Amazing! Thanks for the corrections! |
Hi! It's my first PR here for iced!
I added a style
focused
thought to be displayed when the scrollable area is hovered (not the scrollbar itself).In my opinion, this is a more flexible solution to #1573.
In this way, a user can decide to hide the scroller when the area is not hovered or simply to have a different style from the
active
case, which would now be used when the scrollable area is not hovered.If
focused
is not implemented,active
will be used anyway.If you don't like the name "focused", suggestions are welcomed!
Untitled.mp4