-
Notifications
You must be signed in to change notification settings - Fork 598
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
Add an option to disable the scrollbox containing the scrollbar #988
Comments
The way I listed above isn't a great way to not draw the scrollbox. I haven't used Qt much but it looks like the option should be in the QStyleOptionSlider but I can't find a way to manipulate the drawing of the box. I've tried setting the painter to fill transparent and tried to set the painter pen to have no width but that didn't have any effect on the box. How could I go about hiding the scrollbox? |
What Style and what platform are you on? |
Fluent Style on macOS with Qt 6. |
I'm a bit confused, because the Fluent style is not having a dark mode like on your screenshot. |
Oh your right I got confused. It is the native style. |
Hm, now that you mention it - I see the scroll box on macOS, for example in Safari and TextEdit. Where in macOS would it be absent? Or do you mean transparent overlay scrollbars like on iOS/iPadOS? Maybe @n-raine has an idea as well? |
@lukas-jung kindly helped me "see" - when disconnecting my "real" mouse and just use the touchpad I get overlay scrollbars. @jrmoulton are you looking for rendering overlay scrollbars basically? |
Qt seems to be capable of overlay (transient) scrollbars. But I don't know (yet) how to use QStyle to draw them that way. And we also need to do the logic for showing/hiding ourselves, as well as run a timer for the animation. |
@tronical Yep. I didn't know the name of what I was looking for but after a google search it seems like overlay scrollbars are what I was looking for. I'll keep looking and see if I can find how to do that with Qt. |
Relates to #824 ? |
The cupertino style is now the recommended style on mac, and we don't really support the qt style on mac anymore. |
Currently Slint has no way to disable the boxes around a scrollbar in a scrollview. It would be nice to have the option to be able to disable them.
with

vs without

I got this workign in Qt but it feels pretty hacky. On this line
slint/internal/backends/qt/qt_widgets/scrollview.rs
Line 356 in 55fb9c1
I initialized QRect with
(0,0,0, r.size().height())
What would be the best way to go about adding this feature? Do similar changes need to be made in all backends?
The text was updated successfully, but these errors were encountered: