Bug 473572

Summary: On X11, QT_SCREEN_SCALE_FACTORS causes pixelated rendering of some QT apps when fractional scaling is on (Telegram, MegaSync...)
Product: [Plasma] plasmashell Reporter: Pavel Shirshov <pshirshov>
Component: Startup processAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED WORKSFORME    
Severity: normal CC: kde, nate
Priority: NOR    
Version First Reported In: 5.27.7   
Target Milestone: 1.0   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Pavel Shirshov 2023-08-20 19:16:59 UTC
I'm using Plasma with hiDPI displays, so I have fractional scaling turned on.

When fractional scaling is on, plasma-workspace sets environment variable QT_SCREEN_SCALE_FACTORS. For some reason this variable causes strange rendering issues with Telegram, MegaSync and some other QT applications.

The only way to remove this variable is to patch startplasma-x11.cpp:

```
diff --color -ru a/startkde/startplasma-x11.cpp b/startkde/startplasma-x11.cpp
--- a/startkde/startplasma-x11.cpp	2022-08-23 17:55:27.827687762 +0100
+++ b/startkde/startplasma-x11.cpp	2022-08-23 17:56:11.170498094 +0100
@@ -48,7 +48,7 @@
         KConfigGroup kscreenGroup = cfg.group("KScreen");
         const auto screenScaleFactors = kscreenGroup.readEntry("ScreenScaleFactors", QByteArray());
         if (!screenScaleFactors.isEmpty()) {
-            qputenv("QT_SCREEN_SCALE_FACTORS", screenScaleFactors);
+            // qputenv("QT_SCREEN_SCALE_FACTORS", screenScaleFactors);
         }
```

I haven't noticed any rendering issues with this variable unset, only improvements.
Comment 1 Nate Graham 2023-08-22 21:16:50 UTC
David, do you know the context of this?
Comment 2 Nate Graham 2025-01-09 22:29:51 UTC
Sorry it took us so long to get to this. I can't reproduce it in current git master, which will shortly become Plasma 6.3. Are you still able to reproduce the issue in Plasma 6.2.5 or later? Thanks!
Comment 3 Bug Janitor Service 2025-01-24 03:47:12 UTC
๐Ÿ›๐Ÿงน โš ๏ธ This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information, then set the bug status to REPORTED. If there is no change for at least 30 days, it will be automatically closed as RESOLVED WORKSFORME.

For more information about our bug triaging procedures, please read https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging.

Thank you for helping us make KDE software even better for everyone!
Comment 4 Bug Janitor Service 2025-02-08 03:47:43 UTC
๐Ÿ›๐Ÿงน This bug has been in NEEDSINFO status with no change for at least 30 days. Closing as RESOLVED WORKSFORME.