On Thu, 23 Jun 2022 06:05:57 GMT, Sergey Bylokhov <[email protected]> wrote:

>> The following test was changed to generic based on this [Review 
>> Comment](https://urldefense.com/v3/__https://github.com/openjdk/jdk/pull/9118*discussion_r897553780__;Iw!!ACWV5N9M2RV99hQ!PzEP--HZMd-cIGZirzJpRTsQ2E09rc1Z49qxljJ5UkXKhZCo2iuQREEwcjSXTRjfuF3-u8yQmJW--mqx-WrLE64X$
>>  ) and as the condition `frame.getSize() == frame.getPreferredSize() ` 
>> should hold on all platforms when frame.pack() is used.
>
> test/jdk/java/awt/Frame/AwtFramePackTest.java line 44:
> 
>> 42:  * @summary Tests whether insets are calculated correctly on Windows
>> 43:  * for AWT Frame by checking the actual and expected/preferred frame 
>> sizes.
>> 44:  * @run main/othervm -Dsun.java2d.uiScale=1 AwtFramePackTest
> 
> Please double check that the "-Dsun.java2d.uiScale=1" option is needed here, 
> It does not affect the frame decoration, and I think this can cause the test 
> to fail if the desktop scale=200% is set in the WIndows.

@mrserb Thank you for catching it :) 
I do see that the test fails when scale >= 200% and passes when the uiScale 
option is removed. I'll additionally test it on other platforms to check for 
stability before making the changes.

-------------

PR: https://git.openjdk.org/jdk/pull/9248

Reply via email to