See Bug 1373 Comment 1
See AWT Java 9+ related: 'JEP 263: HiDPI Graphics on Windows and Linux'
OSX uses a monitor related 'float pixelScale',
which we have adopted in bug 1120 and OSX High-DPI fix in bug 741.
Our groundwork for High-DPI support indeed has been done for bug 741.
AWT on OSX should work appropriately based on fixed for bug 741 and bug 1120.
AWT on Linux may use the environment variable GDK_SCALE for both dimensions.
AWT on Windows may use the DPI override.
See long discussion: http://forum.jogamp.org/JOGL-broken-with-JRE-gt-8-and-Windows-window-scaling-td4039122.html
Bug 1363: Java 11: Don't use GraphicsDevice.getScaleFactor() on Java9+ [illegal reflective access]
Use non-reflective method to get the pixel scale on Java9+
It's now possible to use GraphicsConfiguration.getDefaultTransform()
instead of using reflection to get the pixel scale, which eliminates an
illegal reflective access warning.
Orig patch by Wade Walker
Bug 1363: Java 11: Use getPixelScale standard method even on Mac under Java9+
Changed getPixelScale to use standard method, even on Mac
Previously it used a Mac-specific method, but the new standard method of
device.getDefaultConfiguration().getDefaultTransform() seems to work on
Mac, so use it instead to avoid illegal reflective access warnings.
Orig patch by Wade Walker.
Bug 1363: Java 11: Resolve unsupported JAWTUtil.getMonitorDisplayID(..)
Previous commits removed access to OSX's GraphicsDevice.getCGDisplayID()
on Java9+, avoiding illegal reflective access.
Here we JAWTUtil.getMonitorDisplayID(..) simply returns null
if Java9 or !OSX, so the sole NewtFactory caller falls back
to the alternative working solution.
Orig patch Wade Walker:
This was used on Mac OS only to create a MonitorDevice in
NewtFactoryAWT. But there was a fallback method for creating
MonitorDevice, and testing with TestGearsES2GLJPanelAWT shows that the
fallback method seems to give identical results on Mac, so changed to
just use the fallback method (which is now the only method) everywhere.
This gets rid of an illegal reflective access.