Bug 441043 - Enable DPI based scaling on wayland
Summary: Enable DPI based scaling on wayland
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: 5.22.4
Platform: Other Linux
: NOR normal (vote)
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-08-16 13:43 UTC by Tom B
Modified: 2021-08-17 15:08 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.23


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom B 2021-08-16 13:43:33 UTC
SUMMARY

Display scaling on Wayland is generally a poor experience:

- GTK apps look blurry  
- XWayland applications look blurry
- Games (which generally use XWayland) cannot be run at native resolution.
- Fractional scaling generally looks poor

This is a huge downgrade from Xorg where setting a font DPI however high correctly scales application and looks consistently sharp. Certain UI aspects e.g. 1px borders do look thinner but this is much more preferable to blurry windows and unexpected side effects like games not seeing native resolution.

Steps to reproduce:

1. Set font DPI to 192 in systemsettings font panel
2. Log out and back in on a wayland session
3. No effect can be observed. Xorg works fine.
Comment 1 David Edmundson 2021-08-16 14:17:13 UTC
Font DPI should work with that method should work, however I can see it has got broken recently in various ports.

I will fix that.

Wayland scaling still remains the preferred and supported way of changing scale though.
Comment 2 Bug Janitor Service 2021-08-16 16:13:41 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/1008
Comment 3 David Edmundson 2021-08-17 09:24:34 UTC
Git commit 5d77262527060f688f58b6b4f0d73dd57f24c987 by David Edmundson.
Committed on 17/08/2021 at 09:24.
Pushed by davidedmundson into branch 'master'.

Fix font DPI loading and saving for wayland

On wayland a separate config value was used from X11. The rationale
being if you're using wayland screen scaling, we don't want to scale
fonts as well, it would cause a double scaling. (plasma-desktop
fbbdfa100128e9c4cc12b37854a4a054562983bc)

In the port to kcfg this got broken.
The loading is also somewhat broken.

M  +6    -3    kcms/fonts/fontsaasettings.cpp

https://invent.kde.org/plasma/plasma-workspace/commit/5d77262527060f688f58b6b4f0d73dd57f24c987