summaryrefslogtreecommitdiffstats
path: root/src/gui/text/qtextlayout.cpp
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/gui/text/qtextlayout.cpp
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/gui/text/qtextlayout.cpp')
-rw-r--r--src/gui/text/qtextlayout.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/text/qtextlayout.cpp b/src/gui/text/qtextlayout.cpp
index 84d3fce518..943caea644 100644
--- a/src/gui/text/qtextlayout.cpp
+++ b/src/gui/text/qtextlayout.cpp
@@ -1429,9 +1429,9 @@ qreal QTextLine::descent() const
}
/*!
- Returns the line's height. This is equal to ascent() + descent() + 1
+ Returns the line's height. This is equal to ascent() + descent()
if leading is not included. If leading is included, this equals to
- ascent() + descent() + leading() + 1.
+ ascent() + descent() + leading().
\sa ascent(), descent(), leading(), setLeadingIncluded()
*/