JFrame scaling in Java 9

后端 未结 1 1196
一生所求
一生所求 2020-12-31 04:37

Exactly the same code running under Java 9u4 on the left and 8u144 on the right on Windows 7.

Java 9 seems to making the window larger. What is causing this

相关标签:
1条回答
  • 2020-12-31 04:42

    I found this obscure option in a substance bug report. This fixes the issue for Swing applications.

    -Dsun.java2d.uiScale=1.0

    If you're using JavaFX you'll need

    -Dprism.allowhidpi=false

    Unfortunately I cannot find official documentation for either of these options

    0 讨论(0)
提交回复
热议问题