-
-
Notifications
You must be signed in to change notification settings - Fork 102
Fix setResizable(true) bug on Linux Mint #1091
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
Fix setResizable(true) bug on Linux Mint #1091
Conversation
Hi @duskvirkus and thanks for your efforts on this PR.
I did notice a couple issues in testing (some of those may not be new). Note: I only tested on macOS so feel free to ignore those in case they are not relevant to the issue on Linux Mint. I can also open a new issue.
1. Glitchy rendering when resizing below the minimum size
A notable issue: when dragging inside the window beyond the minimal size, rendering starts glitching out.
Note: this issue is already present in 4.4.3
Screen.Recording.2025年05月12日.at.22.48.24.mov
2. Low resolution after exiting fullscreen
If you set the window to fullscreen (using the green maximize button on macOS), then press the green button again to return the sketch to its windowed state, the sketch gets very pixelated.
Note: this issue does not exist in 4.4.3 so it seems to be a regression from this PR.
Edit: I'm now unable to reproduce this issue.
imageThanks for the feedback. I took a quick look at some of these issues and was able to reproduce the first issue.
I could not find a quick fix for it so it I'll have to continue working on it over the coming days or weeks when I've got some free time.
I have yet to reproduce the second one but I will continue trying. It seems like it might be a infrequent bug so not sure if it was produced in this pr if it only happens sometimes. Unfortunately I don't have a mac to see if it is platform specific.
Fixes #1003
Tested this after a gradle clean. Ran it about 8-10 times to ensure it was working as expected.
Screenshot from 2025年05月12日 12-44-51
I hope the reasoning behind the change is explained in comments but it seems like for whatever reason sometimes the window manager doesn't like multiple calls to
frame.setResizable(). Noticed in debugging that if I removed where we set it tofalsethen it works as expected. So the solution ultimately was to dispose of the frame and recreate it. Also noticed that a previous section of code about Insets likely would be good to un-comment because I was noticing black bars around sketches occasionally and this block of code seems to solve that.This pr is intended to be squash merged.