On Thu, 26 Mar 2026 21:55:08 GMT, Phil Race <[email protected]> wrote:
>> src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsProgressBarUI.java >> line 153: >> >>> 151: int dpi = >>> java.awt.Toolkit.getDefaultToolkit().getScreenResolution(); >>> 152: scaleX = (double) dpi / 96.0; >>> 153: scaleY = (double) dpi / 96.0; >> >> Is there any other way to get scale factor that doesn't use AffineTransform? > > Hmm. Do you really need it ? Why not just use scale of 1 if doing AWT 1.1 API > printing. > > The code in the 2D case seems to be trying to handle on-screen hi-dpi pixel > rounding and I'm not very sure that it's ideal but that is a somewhat > separate can of worms. OK...I wanted to have it similar to 2D case but it seems we can use 1 scalefactor, didnt notice any difference in printing..Updated.. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/29752#discussion_r2999082831
