-
Notifications
You must be signed in to change notification settings - Fork 806
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
Fullscreen Resolution Slider #2642
Conversation
The resolution controls would not fit in the allocated space, so I changed the rendering of slidercontrols to enable rendering the slider bar and the value text in the same area. Signed-off-by: MeeniMc <[email protected]>
reduce the length of scrollbars so that it doesn't look as busy Signed-off-by: MeeniMc <[email protected]>
…hat the box can be reduced to avoid overlapping with the undo button. Signed-off-by: MeeniMc <[email protected]>
# Conflicts: # src/main/java/net/caffeinemc/mods/sodium/client/gui/SodiumOptionsGUI.java # src/main/java/net/caffeinemc/mods/sodium/client/gui/options/control/SliderControl.java
It's a good idea but it doesn't work with AUTO gui scale, there is no vertical scrolling and the extra line renders outside the screen now. |
That's a good point, do you know where one makes the control element notify the GUI system of it's correct size? Is there a place where it calculates the total size of the GUI for determining the scale? |
I've updated it to be only one line but truncate the width of the label dynamically based on the slider's value width. |
LGTM |
add two-line fullscreen resolution option remove two-line option but make it the normal style refactor label truncation and slider rendering to work together, this means the label will now be truncated based on the slider's current actual content width. other control elements can but don't have to implement accurate content width information.
8e7ea7f
to
2cb97e9
Compare
resolved conflicts and brought the branch up to speed with dev |
common/src/main/java/net/caffeinemc/mods/sodium/client/gui/options/control/ControlElement.java
Show resolved
Hide resolved
This is fine as a temporary solution for now. But I wouldn't want to keep around multi-line controls once we rework the video setting screen. |
This PR doesn't add it as a multiline option (anymore), I replaced it with label truncation. |
My bad for not updating the description |
As a compromise, this adds a fullscreen resolution slider but truncates the label to fit into one line. The design can be refined later, but at least users won't have to go to the vanilla settings for this now.
Thanks to @MeeniMc for their previous work in #2296 on adding the option in the first place. I added the two-line functionality and changed the style.
related: #46
Closes #2692