Java Code Examples for sun.java2d.SunGraphicsEnvironment#getDebugScale()
The following examples show how to use
sun.java2d.SunGraphicsEnvironment#getDebugScale() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: X11GraphicsDevice.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
private int initScaleFactor() { if (SunGraphicsEnvironment.isUIScaleEnabled()) { double debugScale = SunGraphicsEnvironment.getDebugScale(); if (debugScale >= 1) { return (int) debugScale; } int nativeScale = getNativeScale(); return nativeScale >= 1 ? nativeScale : 1; } return 1; }
Example 2
Source File: CGraphicsDevice.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
private void initScaleFactor() { if (SunGraphicsEnvironment.isUIScaleEnabled()) { double debugScale = SunGraphicsEnvironment.getDebugScale(); scale = (int) (debugScale >= 1 ? Math.round(debugScale) : nativeGetScaleFactor(displayID)); } else { scale = 1; } }
Example 3
Source File: CGraphicsDevice.java From jdk8u_jdk with GNU General Public License v2.0 | 5 votes |
private void initScaleFactor() { if (SunGraphicsEnvironment.isUIScaleEnabled()) { double debugScale = SunGraphicsEnvironment.getDebugScale(); scale = (int) (debugScale >= 1 ? Math.round(debugScale) : nativeGetScaleFactor(displayID)); } else { scale = 1; } }