Bug 501715 - Text rendering in Plasma UI components using Text.Rendering does not respect system's hinting and sub-pixel anti-aliasing settings resulting in blurry fonts
Summary: Text rendering in Plasma UI components using Text.Rendering does not respect ...
Status: CONFIRMED
Alias: None
Product: libplasma
Classification: Frameworks and Libraries
Component: components (other bugs)
Version First Reported In: 6.1
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: accessibility
: 502664 503381 504643 506244 (view as bug list)
Depends on:
Blocks:
 
Reported: 2025-03-18 22:58 UTC by Rain
Modified: 2025-09-22 22:29 UTC (History)
10 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
zoomed in text on the desktop being rendered with RGB subpixel antialiasing (244.88 KB, image/png)
2025-03-18 22:58 UTC, Rain
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rain 2025-03-18 22:58:29 UTC
Created attachment 179555 [details]
zoomed in text on the desktop being rendered with RGB subpixel antialiasing

SUMMARY

Sometimes, the text all over plasmashell is rendered using RGB subpixel antialiasing while my system default is set to None. It only seems to happen in plasmashell components- other apps like Firefox, Kate, even System Settings work as expected.

STEPS TO REPRODUCE

TODO: Have not yet been able to deduce.

OBSERVED RESULT

As explained prior, see attachment.

EXPECTED RESULT

Text should be rendered according to the same antialiasing rules the rest of the system abide by *all* the time, not most.

SOFTWARE/OS VERSIONS

Linux/KDE Plasma: 
KDE Plasma Version: 6.3.2
KDE Frameworks Version: 6.11.0
Qt Version: 6.8.2

ADDITIONAL INFORMATION

Worked around by restarting plasmashell, such as by running `plasmashell --replace`
Comment 1 Nate Graham 2025-04-11 14:15:24 UTC
*** Bug 502664 has been marked as a duplicate of this bug. ***
Comment 2 Nate Graham 2025-04-11 14:49:50 UTC
*** Bug 502664 has been marked as a duplicate of this bug. ***
Comment 3 John Kizer 2025-04-27 18:56:36 UTC
*** Bug 503381 has been marked as a duplicate of this bug. ***
Comment 4 cyangalaxy 2025-05-02 12:16:20 UTC
I found out that the forced RGB subpixel anti-aliasing comes from Qt Quick's renderType "Text.QtRendering". Switching to the renderType "Text.NativeRendering" fixes this issue, because Text.NativeRendering does acknowledge the native font rendering settings.

However it seems that the renderType of a Qt Quick application is only changeable at compile-time. I was not able to change the renderType globally via Linux environment variables, so Idk how to fix it for my KDE Plasma desktop and third party Qt Quick apps.

I was only able to fix in my own Qt Quick app by adding "renderType: Text.NativeRendering".

This is a problem, because I don't have a RGB monitor, but BGR monitor, and the forced RGB subpixel anti-aliasing causes colour-fringing/chromatic aberration for texts in Qt Quick/QML.

https://doc.qt.io/qt-6/qml-qtquick-text.html#renderType-prop
Comment 5 Nate Graham 2025-05-06 14:43:42 UTC
Oh, that makes perfect sense. Thanks for tracking it down.

I recall that we've bounced back and forth a few times between QtRendering and NativeRendering. Unfortunately each one is affected by different bugs' NativeRendering isn't as good with fractional scale factors IIRC.
Comment 6 Nate Graham 2025-05-28 17:06:34 UTC
*** Bug 504643 has been marked as a duplicate of this bug. ***
Comment 7 Zamundaaa 2025-09-09 13:58:27 UTC
*** Bug 506244 has been marked as a duplicate of this bug. ***
Comment 8 Nate Graham 2025-09-22 22:29:55 UTC
I dug into this a bit and found that we use QtTextRendering to work around a Qt bug that makes text look really weird at random fractional scale factors: https://bugreports.qt.io/browse/QTBUG-126577

In qqc2-desktop-style (which controls apps, not Plasma) there's some code to use use NativeTextRendering if your scale factor is 1, but Plasma doesn't have that. As a result, everything in Plasma always uses QtTextRendering, which exposes everyone to the different bug of QtRendering failing to respect your hinting and sub-pixel anti-aliasing settings.

It would appear this is blocked on https://bugreports.qt.io/browse/QTBUG-126577 being resolved; once it is, we can consider going back to NativeTextRendering.

Lowering priority because unfortunately this isn't actionable right now.