Rumor has it that Eclipse supports high resolution screens with scaling active. Right now my Eclipse shows icons on my 3840 x 2160 monitor in 16 x 16 pixel, which is not usable.
I debugged the code and found that DPIUtil.setDeviceZoom(int)
uses some fixed value for nativeDeviceZoom
, and so always calculates 100 for deviceZoom
(which is then used to scale images). The culprit seems to be the following line (#439):
deviceZoom = Math.max ((nativeDeviceZoom + 25) / 100 * 100, 100);
However by setting the SWT_AUTOSCALE
property I can get around this, and then I'm able to see the Eclipse application with nicely auto-scaled icons.
The bigger problem is that when the scaling is 200, 150 or 100, nativeDeviceZoom
is always 150, which means deviceZoom
is always 100.
I have no idea what any of these methods are supposed to represent, and the calculation does not make any sense to me.
Still there must be something I can do to get it to work. What is it?
Edit: After restarting twice Eclipse and our application suddenly started to scale. Now, after restarting again, we are back to not scaling at all.