There are a number of desktop apps (Chromium, Signal Desktop, Mattermost) in the last couple of monts that when they are displayed on my laptop screen with 85% scale-down resolution, begin to act very funny. Clicking in the app, makes them smaller, clicking on something highlights something else not tooo far away. On my external monitor (100% scaling) there is no issue. Clearly there is something amiss with how Electron and KDE on Wayland are playing together.
It seems that some Electron apps have problems with fractional scaling under wayland especially if the main monitor is scaled , for example in my case, to 120% and one or more external monitors are scaled below 100% (90% in my case).
The solution for Chromium is to edit the .desktop file in ~/.local/share/applications/ (or wherever yours is located) and add:
--ozone-platform=x11
as a parameter to the Exec line. For VS Code first run:
which code
to find out where your executable is located (/usr/bin/code for me) and then change all Exec lines in ~/.local/share/applications/code.desktop to:
Exec=env GDK_BACKEND=x11 /usr/bin/code --ozone-platform=x11 %F
If ~/.local/share/applications/code.desktop does not exist on your system copy it from /usr/share/applications using:
cp /usr/share/applications/code.desktop ~/.local/share/applications/
then change the excec as shown above and update the desktop database using:
update-desktop-database ~/.local/share/applications/
These solutions worked for me with Chromium and VS Code. My code is installed using the Microsoft repositories. I also had the problem that Libreoffice was unusable on my main screen as it was simply to small. I was able to fix it with copying all related .desktop files and modify all Exec lines in all of them (there are 2) to look like:
Exec=env QT_QPA_PLATFORM=xcb libreoffice --calc %U
I updated the desktop database after all changes. I am not sure if this is actually necessary but I did it anyway. I hope that helps or at least gives you an idea where to start. Cheers.
THANK YOU! I’ll have a look at that right away. But this is, however, a workaround. Who are the right people/group to report this bug to? This is really deep-in-the-weeds kind of stuff! ![]()
This is actually a known problem. There is a discussion here… Chromium Issues, and I found a few other post about it in different forums but without a real solution. Or… let’s say none of them worked for me out of the box. It has also been labelled as a bug on the Electron GitHub page (search for wayland).
It quickly became clear that this is an Electron/Wayland/x11 thing and I had to fiddle around with it quite a bit but the above is what I finally came up with and what worked for me. That doesn’t neccessarily mean it works for everyone, but it’s a good starting point for narrowing things down and getting them to work as expected until it’s fixed at the base.