Modify

Opened 19 months ago

Last modified 3 months ago

#21278 new defect

JOSM.exe runs upscaled

Reported by: anonymous Owned by: team
Priority: normal Milestone:
Component: Core Version:
Keywords: template_report jpackage windows hidpi scaling usablity Cc: Klerik7, matheusgomesms

Description

What steps will reproduce the problem?

  1. When I run latest Windows 18191 JOSM.exe JOSM is upscaled, when I run .jar using command prompt "java -jar josm-custom.jar" everything is ok.

https://i.imgur.com/GlJxC6t.png
https://i.imgur.com/4s5n8FX.png

What is the expected result?

What happens instead?

Please provide any additional information below. Attach a screenshot if possible.

Revision:18191
Build-Date:2021-09-01 22:57:30

Identification: JOSM/1.5 (18191 en) Windows 10 64-Bit
OS Build number: Windows 10 Enterprise 2009 (19042)
Memory Usage: 376 MB / 10184 MB (193 MB allocated, but free)
Java version: 16.0.2+7, Azul Systems, Inc., OpenJDK 64-Bit Server VM
Look and Feel: com.sun.java.swing.plaf.windows.WindowsLookAndFeel
Screen: \Display0 1920×1080 (scaling 1.25×1.25)
Maximum Screen Size: 1920×1080
Best cursor sizes: 16×16→32×32, 32×32→32×32
System property file.encoding: Cp1252
System property sun.jnu.encoding: Cp1257
Locale info: en_US
Numbers with default locale: 1234567890 -> 1234567890
VM arguments: [-Djpackage.app-version=1.5.18191, --add-modules=java.scripting,java.sql,javafx.controls,javafx.media,javafx.swing,javafx.web, --add-exports=java.base/sun.security.action=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED, --add-opens=java.base/java.lang=ALL-UNNAMED, --add-opens=java.base/java.nio=ALL-UNNAMED, --add-opens=java.base/jdk.internal.loader=ALL-UNNAMED, --add-opens=java.base/jdk.internal.ref=ALL-UNNAMED, --add-opens=java.desktop/javax.imageio.spi=ALL-UNNAMED, --add-opens=java.desktop/javax.swing.text.html=ALL-UNNAMED, --add-opens=java.prefs/java.util.prefs=ALL-UNNAMED, -Djpackage.app-path=%UserProfile%\AppData\Local\JOSM\JOSM.exe]

Plugins:
+ EasyPresets (1623509627)
+ apache-commons (35524)
+ ejml (35458)
+ geotools (35458)
+ jaxb (35543)
+ jts (35458)
+ opendata (35803)
+ reltoolbox (35640)
+ utilsplugin2 (35792)

Tagging presets:
+ <josm.pref>/EasyPresets.xml

Last errors/warnings:
- 00000.521 W: extended font config - overriding 'filename.Myanmar_Text=mmrtext.ttf' with 'MMRTEXT.TTF'
- 00000.524 W: extended font config - overriding 'filename.Mongolian_Baiti=monbaiti.ttf' with 'MONBAITI.TTF'
- 00003.271 E: java.security.KeyStoreException: Windows-ROOT not found. Cause: java.security.NoSuchAlgorithmException: Windows-ROOT KeyStore not available
- 00009.824 W: Cannot lock cache directory. Will not use disk cache

Attachments (4)

screenshot_JOSM_1.PNG (231.7 KB) - added by SafetyIng 17 months ago.
screenshot_JOSM_2.PNG (102.6 KB) - added by SafetyIng 17 months ago.
screenshot_JOSM_3.PNG (334.2 KB) - added by SafetyIng 17 months ago.
Screenshot 2021-12-18 183207.jpg (187.1 KB) - added by SafetyIng 16 months ago.

Download all attachments as: .zip

Change History (43)

comment:1 Changed 19 months ago by Don-vip

Keywords: jpackage windows added

comment:2 Changed 19 months ago by gaben

Spotted the issue: Java version: 16.0.2+7 + scaling 1.25×1.25.

Java 8+ fractional scaling on Windows is weird. See my comment here. I guess when you run it with jar, you actually run it with Java 8 where everything* looks good. The whole issue originates around JDK-8055212.

*everything: nearly, but sadly no, see eg. #20850

Last edited 19 months ago by gaben (previous) (diff)

comment:3 Changed 19 months ago by skyper

Ticket #21283 has been marked as a duplicate of this ticket.

comment:4 in reply to:  2 Changed 19 months ago by skyper

Cc: Klerik7 added

Replying to gaben:

Spotted the issue: Java version: 16.0.2+7 + scaling 1.25×1.25.

Java 8+ fractional scaling on Windows is weird. See my comment here. I guess when you run it with jar, you actually run it with Java 8 where everything* looks good. The whole issue originates around JDK-8055212.

*everything: nearly, but sadly no, see eg. #20850

HiDpi support was added in java 9. Please, take a look at the status report when running the .jar file. It should tell you which java version is used.

comment:5 Changed 19 months ago by skyper

Ticket #21297 has been marked as a duplicate of this ticket.

comment:6 Changed 19 months ago by skyper

Cc: matheusgomesms added

comment:7 Changed 19 months ago by gaben

Keywords: hidpi scaling usablity added
Priority: normalmajor

I think it's fair to assume it is a major usability issue. Users just started using the new exe and already having issues.

comment:8 Changed 19 months ago by InsertUser

I am also getting a comically enlarged version of JOSM after the latest update to 18193. The file menu now scrolls because it won't fit on the screen. Map tiles also appear to be rendering too small. Unfortunately the 18118 version left behind by the new installer now complains about plugins that it is too old for.

Is there a way to fix this?

comment:9 Changed 19 months ago by skyper

Is this a problem with the windows installer or a general issue with hiDPI + Windows + java16?

comment:10 Changed 19 months ago by Don-vip

Customized scaling issue, behaviour changed for users who went straight from Java 8 to Java 16 with the new installer:
#21278: 1920×1080 (scaling 1.25×1.25)
#21283: 1920×1080 (scaling 1.25×1.25)
#21297: 3200×1800 (scaling 2.00×2.00)

comment:11 Changed 19 months ago by Don-vip

Milestone: 21.09

comment:12 Changed 18 months ago by Don-vip

Milestone: 21.0921.10

Milestone renamed

comment:13 Changed 17 months ago by Don-vip

Milestone: 21.10

I tried to increase Windows scaling and I confirm icons are bigger with Java11+... but I think Java 8 behaviour was simply wrong.

comment:14 Changed 17 months ago by Don-vip

Priority: majornormal

comment:15 Changed 17 months ago by gaben

Just the icons? For me, it looks the same as in the report.

comment:16 Changed 17 months ago by Don-vip

The text is bigger too but is the same for me between Java 8 and Java 11+, and that's the whole point of this Windows setting.

comment:17 Changed 17 months ago by InsertUser

I've just played with my windows scaling settings, everything seems to be scaling along with the slider, but unfortunately the icon and text sizes are significantly bigger than the Windows defaults for other apps.

Were these bumped up in size to compensate for the lack of proper scaling before? Is there a setting somewhere to put them back to something reasonable?

comment:18 in reply to:  17 Changed 17 months ago by gaben

Replying to InsertUser:

Were these bumped up in size to compensate for the lack of proper scaling before?

Yes, scaling was changed in Java 9, see JEP 262. You can start inspecting the issue around here https://stackoverflow.com/q/47613006.

comment:19 Changed 17 months ago by SafetyIng

Hey, have you a workaround for a run-of-the-mill user? For me, this issue is critical, because I can not read some texts, buttons text is somewhere pixelated.....

comment:20 Changed 17 months ago by skyper

Did you try it with new, empty preferences?
Did you take a look at the mentioned system settings in the link to stackoverflow above?
Text size may depend on the font you use which can be changed in advanced preferences.

comment:21 Changed 17 months ago by Don-vip

I don't see this as a critical issue. I tried the custom scaling and Windows becomes really ugly. JOSM becomes ugly as well with bigger icons but at least it's consistent with the system. I will accept patches if someone want to dig into this but I will focus my time on more important issues.

comment:22 Changed 17 months ago by Don-vip

The workaround is to revert Windows scaling settings and stick to 100%.

comment:23 Changed 17 months ago by InsertUser

Don-vip:

The workaround is to revert Windows scaling settings and stick to 100%.

This is not an acceptable workaround. Other apps that observe proper scaling then become too small to use comfortably. Making the rest of the system less usable because of a JOSM specific issue is not a solution.

Don-vip:

I tried the custom scaling and Windows becomes really ugly. JOSM becomes ugly as well with bigger icons but at least it's consistent with the system.

It is not consistent as it appear that JOSM text and icon sizes are artificially enlarged compared to other apps even without any scaling.

comment:24 Changed 17 months ago by gaben

If you do it right, only badly behaving Java apps will be ugly, not limited to JOSM. A good example would be JetBrains IDEs with consistent look, although they use their own JRE.

I think there is a reason why anyone uses other than 100% scaling, so better workaround to stick to Java 8 with .jnlp or .jar until it's fixed.

Last edited 17 months ago by gaben (previous) (diff)

comment:25 in reply to:  20 ; Changed 17 months ago by SafetyIng

Replying to skyper:

Did you try it with new, empty preferences?

Same problem. Nothing changed.

Did you take a look at the mentioned system settings in the link to stackoverflow above?
Text size may depend on the font you use which can be changed in advanced preferences.

I don't have changed there anything. Wich key would be changed?

Replying to Don-vip:

I don't see this as a critical issue.

I see there a critical issue, when JOSM is not workable. I have added some screenshots. See yourself.
Scaling 100%, FullHD (1920x1080px). Before the update JOSM were around 2x or 3x smaller....

Replying to Don-vip:

The workaround is to revert Windows scaling settings and stick to 100%.

As I wrote further: My Screen, where I use JOSM is on scaling 100%. lower is not possible.
I don't see any workaround here...?

comment:26 Changed 17 months ago by Don-vip

@SafetyIng can you please post your status report? All bug reports I saw on this subject had a custom scaling from 1.25 to 2.00.

Changed 17 months ago by SafetyIng

Attachment: screenshot_JOSM_1.PNG added

Changed 17 months ago by SafetyIng

Attachment: screenshot_JOSM_2.PNG added

comment:27 Changed 17 months ago by InsertUser

After a brief test it seems that setting the program compatibility mode to put all of the scaling onto the application brings the text size on the menus to a text sizes seem more consistent with the rest of the OS and in line with my install of LibreOffice 7.2. The icons are still seem a bit big, but that seems to be happening with LibreOffice too so I'm probably just a bit too used to the previous version's mini-icons. With this set the file menu items now all fit on screen without an arrow for the overflow. With this set JOSM does still change scale along with the global Windows setting.

Settings accessed via: Right click on JOSM in taskbar > Right click on JOSM > 🔧 Properties > Compatibility > Change high DPI settings > ☑ Override high DPI scaling behaviour. Scaling performed by: Application

NB my default scale is 150% so won't help with anyone who finds things too big at 100%.

Last edited 17 months ago by InsertUser (previous) (diff)

comment:28 in reply to:  26 ; Changed 17 months ago by SafetyIng

Replying to Don-vip:

@SafetyIng can you please post your status report? All bug reports I saw on this subject had a custom scaling from 1.25 to 2.00.

Here you are:

Revision:18307
Is-Local-Build:true
Build-Date:2021-11-03 14:00:03

Identification: JOSM/1.5 (18307 SVN de) Windows 10 64-Bit
OS Build number: Windows 10 Home 2009 (19042)
Memory Usage: 201 MB / 2020 MB (77 MB allocated, but free)
Java version: 17.0.1+12-LTS, Azul Systems, Inc., OpenJDK 64-Bit Server VM
Look and Feel: com.sun.java.swing.plaf.windows.WindowsLookAndFeel
Screen: \Display0 1920×1080 (scaling 1.25×1.25) \Display1 1920×1080 (scaling 1.25×1.25)
Maximum Screen Size: 1920×1080
Best cursor sizes: 16×16→32×32, 32×32→32×32
System property file.encoding: Cp1252
System property sun.jnu.encoding: Cp1252
Locale info: de_DE
Numbers with default locale: 1234567890 -> 1234567890
VM arguments: [-Djpackage.app-version=1.5.18303, --add-modules=java.scripting,java.sql,javafx.controls,javafx.media,javafx.swing,javafx.web, --add-exports=java.base/sun.security.action=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED, --add-opens=java.base/java.lang=ALL-UNNAMED, --add-opens=java.base/java.nio=ALL-UNNAMED, --add-opens=java.base/jdk.internal.loader=ALL-UNNAMED, --add-opens=java.base/jdk.internal.ref=ALL-UNNAMED, --add-opens=java.desktop/javax.imageio.spi=ALL-UNNAMED, --add-opens=java.desktop/javax.swing.text.html=ALL-UNNAMED, --add-opens=java.prefs/java.util.prefs=ALL-UNNAMED, -Djpackage.app-path=%UserProfile%\AppData\Local\JOSM\JOSM.exe]

Last errors/warnings:
- 00000.867 W: extended font config - overriding 'filename.Myanmar_Text=mmrtext.ttf' with 'MMRTEXT.TTF'
- 00000.875 W: extended font config - overriding 'filename.Mongolian_Baiti=monbaiti.ttf' with 'MONBAITI.TTF'
- 00003.341 E: java.security.KeyStoreException: Windows-ROOT not found. Ursache: java.security.NoSuchAlgorithmException: Windows-ROOT KeyStore not available

I use JOSM on my display1 - interesting is, that there a scaling of 1.25x1.25 is listed, but in my computer settings there is set up 100% (1.00x1.00) so something must go wrong in the Setup of JOSM <-> Java <-> OS...?

Last edited 17 months ago by skyper (previous) (diff)

Changed 17 months ago by SafetyIng

Attachment: screenshot_JOSM_3.PNG added

comment:29 in reply to:  28 ; Changed 17 months ago by Don-vip

Replying to SafetyIng:

I use JOSM on my display1 - interesting is, that there a scaling of 1.25x1.25 is listed, but in my computer settings there is set up 100% (1.00x1.00) so something must go wrong in the Setup of JOSM <-> Java <-> OS...?

Interesting, speaking of hardware, what is your screen monitor (manufacturer/model)? Is 1920×1080 the native resolution?

comment:30 in reply to:  25 Changed 17 months ago by skyper

Replying to SafetyIng:

Replying to skyper:

Did you take a look at the mentioned system settings in the link to stackoverflow above?

Somewhere the scaling must be set. Either in Windows general, as general option for java or in the startup script.
Sorry, I have not Windows so all I can do is reading.
I guess somewhere -Dsun.java2d.uiScale=* or -Dprism.allowhidpi=* is set or missing.

Text size may depend on the font you use which can be changed in advanced preferences.

I don't have changed there anything. Wich key would be changed?

I hope we find the setting causing this in first place but last option are font and icon size. Just search for font resp. iconsize in advanced preferences. (You need to enable expert mode for it.)

comment:31 in reply to:  29 Changed 17 months ago by SafetyIng

Replying to Don-vip:

Interesting, speaking of hardware, what is your screen monitor (manufacturer/model)? Is 1920×1080 the native resolution?

I use a DELL P2217 ; and yes 1920x1080 is native.

Replying to skyper:

Somewhere the scaling must be set. Either in Windows general, as general option for java or in the startup script.
Sorry, I have not Windows so all I can do is reading.
I guess somewhere -Dsun.java2d.uiScale=* or -Dprism.allowhidpi=* is set or missing.

Then i would say, it miss in the windows starter`?

I hope we find the setting causing this in first place but last option are font and icon size. Just search for font resp. iconsize in advanced preferences.

I found a fontsize with the entry 8, the normal iconsizes were between 16 and 24 (i think pixel?) For me, the reality is a little bit too big for 16 or 24px....

comment:32 Changed 16 months ago by SafetyIng

Hey, I think this fits here. When I have JOSM on my screen 1 for a longer time and i move it to the screen 2 then it is scaled some crazy things, i can't describe. So I added a screenshot as an attachment.

Changed 16 months ago by SafetyIng

comment:33 Changed 13 months ago by taylor.smock

Ticket #21937 has been marked as a duplicate of this ticket.

comment:34 Changed 5 months ago by taylor.smock

Ticket #22429 has been marked as a duplicate of this ticket.

comment:35 Changed 5 months ago by taylor.smock

Ticket #21776 has been marked as a duplicate of this ticket.

comment:36 Changed 4 months ago by anonymous

what is the main problem, when for some it works normally? so how can I solve this problem when I use 1920x1080 resolution and 125% scale in windows? I'm fine with this, but it's not good in josm

comment:37 Changed 3 months ago by Multi Pass

Here's a workaround that may help someone:

I run "java -jar josm-custom.jar" to launch JOSM using Windows with system scaling at 150%.

Normally I scale JOSM back to 100% through JOSM in taskbar > Right click on JOSM > 🔧 Properties > Compatibility > Change high DPI settings > ☑ Override high DPI scaling behaviour. Scaling performed by: Application

I upgraded to Zulu JRE 17 after seeing the message "JOSM soon will no longer support this version of Java, you should update to version 11 or better"

However, the new version of Java does not respect the application scaling setting as stated above.

Scaling is fixed if JOSM is launched with -Dsun.java2d.uiScale=1.0 ("java -Dsun.java2d.uiScale=1.0 -jar josm-custom.jar"), high dpi settings are default (unchecked).

SUMMARY
For JRE 11+ -Dsun.java2d.uiScale=1.0 has the same 100% scaling effect as Right click > Properties > Compatibility > Change high DPI settings for JRE 8.

comment:38 Changed 3 months ago by Klerik7

could someone show me on the screen where exactly I can find this setting to change the DPI? I can't find it

comment:39 Changed 3 months ago by skyper

@All:
Would be nice, if you could document your findings under Help/HiDPISupport, thanks.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain team.
as The resolution will be set.
to The owner will be changed from team to the specified user.
The owner will change to anonymous
as duplicate The resolution will be set to duplicate.The specified ticket will be cross-referenced with this ticket
The owner will be changed from team to anonymous.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.