summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@digia.com>2014-11-11 13:48:27 +0100
committerAllan Sandfeld Jensen <allan.jensen@theqtcompany.com>2014-11-11 15:45:23 +0100
commit501c510cc3cb6215aed27af7599395480a049667 (patch)
tree47ff2a6675c73e26a36b890fb5b9e8b7df9af41a /src/plugins/platforms
parent320c1e0540b31eae227221dc34dfab9a8bd20afa (diff)
Do not apply subpixel gamma-correction on XCB
To match rendering of subpixel antialiased text in Qt 4.8 and other toolkits on X11, we should not apply gamma-correction. This also makes the rendering of subpixel antialiased text closer to normal antialiased text. Task-number: QTBUG-41590 Change-Id: I45ad3448334951353657b878d002eea429858f2d Reviewed-by: Samuel Rødal <srodal@gmail.com> Reviewed-by: Sérgio Martins <sergio.martins@kdab.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
Diffstat (limited to 'src/plugins/platforms')
-rw-r--r--src/plugins/platforms/xcb/qxcbintegration.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/plugins/platforms/xcb/qxcbintegration.cpp b/src/plugins/platforms/xcb/qxcbintegration.cpp
index cace087613..3818494d99 100644
--- a/src/plugins/platforms/xcb/qxcbintegration.cpp
+++ b/src/plugins/platforms/xcb/qxcbintegration.cpp
@@ -427,12 +427,14 @@ QVariant QXcbIntegration::styleHint(QPlatformIntegration::StyleHint hint) const
case QPlatformIntegration::StartDragTime:
case QPlatformIntegration::KeyboardAutoRepeatRate:
case QPlatformIntegration::PasswordMaskDelay:
- case QPlatformIntegration::FontSmoothingGamma:
case QPlatformIntegration::StartDragVelocity:
case QPlatformIntegration::UseRtlExtensions:
case QPlatformIntegration::PasswordMaskCharacter:
// TODO using various xcb, gnome or KDE settings
break; // Not implemented, use defaults
+ case QPlatformIntegration::FontSmoothingGamma:
+ // Match Qt 4.8 text rendering, and rendering of other X11 toolkits.
+ return qreal(1.0);
case QPlatformIntegration::StartDragDistance: {
// The default (in QPlatformTheme::defaultThemeHint) is 10 pixels, but
// on a high-resolution screen it makes sense to increase it.