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

implement shrinkable scrollbar #2732

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

JL710
Copy link
Contributor

@JL710 JL710 commented Jan 17, 2025

This PR adds the ability to let the scrollbar shrink if the scrollbar is neither hovered nor dragged. This behavior only affects the drawing and not the layout or anything else. So the hover area is not affected.

By default, this is disabled but can be enabled with the shrinking_scrollbar function. The default behavior is defined in the scrollbar_shrink_factor field of the Scrollable.

An advantage of a shrinking scrollbar is, beside subjective design, that the scrollbar hides less content.

widget/src/scrollable.rs Outdated Show resolved Hide resolved
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.

2 participants