You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So the issue here is subtle, but getParentBounds() is returning a rectangle that does not necessarily have it's corner on 0,0, however only the width is used to limit, not x + width for what the "maximum x" you're allowed to resize to.
Actual example
Setup: Left monitor is 1280px wide, Right monitor is 2560px wide
When your app is on the right monitor, and you try to resize, the rectangle has x=1280, and width 2560, your mouse x location can be anywhere between 1280 and 3840, but any value above 2560 will not be allowed, so roughly half the screen is the maximum the app can be resized to.
Resizing towards the left does not have this bug, i haven't confirmed if resizing up/down has it as my monitor setup wouldn't cause that.
The text was updated successfully, but these errors were encountered:
When resizing towards the right, on a multi-screen setup, the logic that limits resizing is wrong for multi-screen setups:
https://github.com/JFormDesigner/FlatLaf/blob/main/flatlaf-core/src/main/java/com/formdev/flatlaf/ui/FlatWindowResizer.java#L627 reads as follows:
So the issue here is subtle, but
getParentBounds()
is returning a rectangle that does not necessarily have it's corner on0,0
, however only thewidth
is used to limit, notx + width
for what the "maximum x" you're allowed to resize to.Actual example
Setup: Left monitor is 1280px wide, Right monitor is 2560px wide
When your app is on the right monitor, and you try to resize, the rectangle has x=1280, and width 2560, your mouse x location can be anywhere between 1280 and 3840, but any value above 2560 will not be allowed, so roughly half the screen is the maximum the app can be resized to.
Resizing towards the left does not have this bug, i haven't confirmed if resizing up/down has it as my monitor setup wouldn't cause that.
The text was updated successfully, but these errors were encountered: