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

Make overlay scrolling configurable via the palette settings #592

Merged
merged 1 commit into from
Oct 20, 2024

Conversation

ptziegler
Copy link
Contributor

This adds a new checkbox to the settings dialog that allows the user to replace the overlay scrollbar with the native scrollbar. Linux only, as the overlay is not available on any other platforms.

Resolves #569

@ptziegler
Copy link
Contributor Author

Not really sure about adding it to the dialog, as the addition of static fields causes the API tools to act up...

image

@ptziegler ptziegler force-pushed the overlay-scrolling branch 3 times, most recently from 5177803 to 1107a9e Compare October 17, 2024 18:45
@ptziegler ptziegler marked this pull request as ready for review October 17, 2024 18:50
@ptziegler
Copy link
Contributor Author

ptziegler commented Oct 17, 2024

In order to avoid API breakage, I've created an internal subclass of the settings dialog. If people only use the PaletteSettingsDialog, they won't have any UI to configure it, but are free to implement it, given that the propery name is public.
image

This adds a new checkbox to the settings dialog that allows the user to
replace the overlay scrollbar with the native scrollbar. Linux only, as
the overlay is not available on any other platforms.

Resolves eclipse#569
Copy link
Contributor

@azoitl azoitl left a comment

Choose a reason for hiding this comment

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

Dumb question: Should we provide not only a preference dialog but also a preference page that users could hook into the Eclipse Platform preference dialog? Or do you expect that applications needing that would do that by themselves in app specific ways?

@ptziegler
Copy link
Contributor Author

I think a preference page is too much, especially because we don't have any yet.

At the end of the day, this whole overlay issue is something that probably only very rarely. First you have to use Linux and then you also have to explicitly enable the vertical scrollbar. It can also happen with the default configuration, but only when the editor is really small.

Because the global scrollbar is never set withing GEF, this is something that has happen in user code, but then the user can simply set setScrollbarsMode() on the FigureCanvas. This property is just a way to make it a little easier.

Hm... with a property page, it would also become a global property, so it would be very easy to enable it for palettes where you don't really want it. And for my use-case, I would want to use my own preference store, which would make things a lot more tedious... 😐

@azoitl
Copy link
Contributor

azoitl commented Oct 20, 2024

@ptziegler I didn't mean as part of this PR but for a new PR. However you bring quite some points that shows we shouldn't provide one even es reference in gef itself. It is maybe a better idea to have it in the Logic Editor example to serve as best practice for our uers.

@azoitl azoitl merged commit b4d3dcf into eclipse:master Oct 20, 2024
9 checks passed
@ptziegler ptziegler added this to the 3.22.0 milestone Oct 20, 2024
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.

[Linux] Overlay scrollbar obscures "pinned" icon
2 participants