HighDPI Scaling Bug On Linux With JavaFX Interoperability With SWT (Possible Solution)

marcel Austenfeld marcel.au at web.de
Thu Nov 14 20:21:40 UTC 2019

I filed this bug regarding the high dpi scaling on Linux when using the FXCanvas for SWT:
I think I found the problem in the FXCancas class whereas the Linux case is simply not handled:

In both cases the scale factor for MacOSX and Windows is returned (by reflection) but not for Linux which I think i the same method as for Windows.
Thus the scaling factor is always 1 which leads to this graphical distortion (if I set the scale with DPIUtil.setScale differently I can also cause a distortion!)
However I was not able to built openjfx on Ubuntu 19.10 so far.
Is there a gradle command to built the swt module only?
@Kevin Rushforth: can you confirm that this is the cause for the bug?
Unfortunately there is no issue tab on the Github page so I post here.

More information about the openjfx-dev mailing list