<AWT Dev> RFR: 8221823 Requested JDialog width is ignored

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Sun Feb 9 09:25:15 UTC 2020


Hello.
Please review the fix for jdk/client.

Bug: https://bugs.openjdk.java.net/browse/JDK-8221823
Fix: http://cr.openjdk.java.net/~serb/8221823/webrev.04

The root cause of the bug is that we use GetSystemMetrics(SM_C[X/Y]MIN) as-is.
So if the dpi of the screen is 200% we create the window twice bigger
than necessary, since we use the value in pixels as user's space points.

The logic of the fix is simple, results of this method should be
downscaled according to the scale of the current window.


-- 
Best regards, Sergey.


More information about the awt-dev mailing list