QT applications and plasma have their icons under-scaled on a HiDPI display when running KDE #131032
Labels
0.kind: bug
Something is broken
2.status: stale
https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md
6.topic: nixos
Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS
6.topic: qt/kde
Describe the bug
QT applications and plasma will have their icons under-scaled if you only set
services.xserver.dpi
.While you can adjust the icon size in the system settings, it does not work for some applications such as Krita.
After some debugging, I found out that this is caused by
startplasma-x11
which always setsQT_AUTO_SCREEN_SCALE_FACTOR
to0
even if you've already set them in/etc/profile
(viaenvironment.sessionVariables
). If I setQT_AUTO_SCREEN_SCALE_FACTOR
to 1 (or just unset it) for any QT application then it will display icons with the right size. After some more research, I found this similar issue #96055. According to this comment under that issue, there was a time whereQT_AUTO_SCREEN_SCALE_FACTOR
is unset but now it is always set (to1
). I think this is what caused this bug and I wonder what might have changed between then and now.Of course, this issue can be avoided if we use only KDE to configure HiDPI (through display configurations > global scale), that is to not set
services.xserver.dpi
. But this workaround is not deterministic and does not work when you want to switch between a DE and a pure WM without rebuilding (the latter requiresservices.xserver.dpi
to be set to work properly on a HiDPI screen).To Reproduce
Steps to reproduce the behavior:
services.xserver.dpi
to a proper value and set the environment variablePLASMA_USE_QT_SCALING
to 1 viaenvironment.sessionVariables
Expected behavior
HiDPI should work on KDE/plasma
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.
Notify maintainers
@petabyteboy @worldofpeace @ttuegel @NixOS/freedesktop @NixOS/qt-kde
Metadata
"x86_64-linux"
Linux 5.12.12, NixOS, 21.11.20210704.20887e4 (Porcupine)
yes
yes
nix-env (Nix) 2.4pre20210601_5985b8b
""
/nix/store/rplqpacaa11i2wlpjbjz71g8vfynnvb3-source
Maintainer information:
The text was updated successfully, but these errors were encountered: