summaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>2012-02-03 14:28:16 +0100
committerQt by Nokia <qt-info@nokia.com>2012-02-17 05:26:44 +0100
commitcb8445f0323b0eefbb04f1d8adad81a00b53abd8 (patch)
tree502411d2ce366cb25a1ac9424eb314c320ece905 /src/plugins
parent2801db558c56e98753e297c1aeabd4fd2975e09a (diff)
Remove historical +1 from font height calculation
Historically, we've calculated font height as ascent+descent+1. In Qt 4, a patch was added to work around this by subtracting 1 from the descent of the font engines. We now remove the +1 and the work arounds. Change-Id: I7e25d49b97ac892015d3328f32d70eb9a7c2d88f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/platforms/windows/qwindowsfontengine.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/plugins/platforms/windows/qwindowsfontengine.cpp b/src/plugins/platforms/windows/qwindowsfontengine.cpp
index ffa57ad58f..007f6d597a 100644
--- a/src/plugins/platforms/windows/qwindowsfontengine.cpp
+++ b/src/plugins/platforms/windows/qwindowsfontengine.cpp
@@ -517,9 +517,7 @@ QFixed QWindowsFontEngine::ascent() const
QFixed QWindowsFontEngine::descent() const
{
- // ### we subtract 1 to even out the historical +1 in QFontMetrics'
- // ### height=asc+desc+1 equation. Fix in Qt5.
- return tm.tmDescent - 1;
+ return tm.tmDescent;
}
QFixed QWindowsFontEngine::leading() const