BrowserView

The document describes capabilities and limitations of JxBrowser in HiDPI environments.

macOS

On macOS, JxBrowser supports HiDPI displays out of the box.

Windows

On Windows, JxBrowser supports HiDPI displays out of the box in Swing and JavaFX.

SWT

The library only recognizes the scale factor of a primary monitor. The scale factor should be a multiple of 25%.

It is mandatory to use the swt.autoScale system property if you need HiDPI support. The supported values are quarter and exact:

java -Dswt.autoScale=quarter -jar application.jar

In Eclipse 4.6 and higher, the swt.autoScale property is always quarter.

Read more about swt.autoScale here.

Linux

The scale factor should be explicitly configured when launching JVM. It is automatically detected.

Swing

To configure the scale factor in a Swing application, use the sun.java2d.uiScale system property. It accepts only integer values.

java -Dsun.java2d.uiScale=2 -jar application.jar

JavaFX

To configure the scale factor in a JavaFX application, use the glass.gtk.uiScale system property. It accepts only integer values.

java -Dglass.gtk.uiScale=2 -jar application.jar
Go Top