On Wed, 16 Apr 2025 17:00:00 GMT, Harshitha Onkar <hon...@openjdk.org> wrote:

> It is better to test it at uiScale of 1 especially on windows to avoid 
> fractional pixels side effects with `robot.getPixelColor` although this might 
> not be a problem on CI.
> 
> ` * @run main/othervm -Dsun.java2d.uiScale=1 bug4952462`
> 
> Can we change the line where the current theme is queried from AppContext to 
> setting it explicitly ?
> 
> ` MetalTheme theme = (MetalTheme) 
> AppContext.getAppContext().get("currentMetalTheme");`
> 
> to
> 
> ```
>             MetalLookAndFeel.setCurrentTheme(new OceanTheme());
>             
> UIManager.setLookAndFeel("javax.swing.plaf.metal.MetalLookAndFeel");
> ```

Updated. Thanks for the tip

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

PR Comment: https://git.openjdk.org/jdk/pull/24693#issuecomment-2810204856

Reply via email to