Blurry UI in wayland with hyprland

Blurry UI in Wayland with Hyprland

When first installing JOSM on Arch with Wayland and Hyprland, the java app was blurring all the text. (My resolution is 1920x1080)

It was an XWayland and auto-scaling problem. I solved it by disabling auto-scaling and setting GDK_SCALE in my hyprland.conf

Here’s how:

Add this to ~/.config/hypr/hyprland.conf :

# Set static scaling (2 is big for laptops)
env = GDK_SCALE,2

# Tell xwayland to not auto-scale any Xorg programs
xwayland {
  force_zero_scaling = true
}

This might apply to all Wayland systems, but I don’t know how to configure others.

I hope it could help ! Have fun mapping

2 Likes

Hi - I’ve moved this out of “tagging” and into the regular “help and support” area, and added a JOSM tag. I hope it’ll be useful to someone!

What might also be good to add is the screen resolution at which you got the original problem.

1 Like

Thanks ! I’ve added my resolution

I also use GDK_SCALE=2, because by default JOSMs interface is too small on my monitor. When I only use a laptop, it is ok. There is a much bigger difference between the size of the interface on the monitor and the laptop in other applications than in JOSM. The ideal size would be in the middle, but GDK_SCALE does not accept fractional values and I am not sure there is a setting in JOSM to just make fonts and icons slightly bigger.

1 Like

Yeah I tried to find a parameter in JOSM but could not

Open the settings with F12. You might need to activate “Expert Mode”.

The sizes of icons can be changed in the “Advanced Preferences” tab. Search for iconsize. iconsize.largeicon for example changes the size of the toolbar icons. I can’t remember if the size of the text can be changed as well.

I recommend as well to switch through the “look and feel” options in the “Display” tab. The GTK+ setting was not working very well for me, but I’m on X11 not wayland.

1 Like

I am not sure which icons sizes those icons change. Anyway, my main problem is with the font size and I see no settings to that effect there (which I am kind of surprised by, JOSM is normally quite customizable).

Hi, I’m on windows and these JOSM settings are working for me:

Also, there is a “Hi-DPI” style for enlarging the elements in the editing-pane.

For JAVA I’m using a scaling of 1.25, but as already noted, fractional scaling for JAVA is not supported on Linux.

Hm, that just leads to a mix of big and small letters, very inconsistent :-( . I set all scales I could find to 2. See how "Bing Aerial imagery! has a nice big text but “Layers” just above that is almost unreadable.

I guess I should report bugs for those but I think I will just stick with GDK_SCALE=2.