aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiang Jiang <jiang.jiang@nokia.com>2012-05-30 09:50:34 +0200
committerQt by Nokia <qt-info@nokia.com>2012-05-30 13:30:06 +0200
commit3beebd602b2d6074a745d797de64f04a13093456 (patch)
tree10ddd98ade78b19738f6485904cebdff54f28ddb
parentddd6afe066377e8c39a7fac5c7e358bacc4cd84f (diff)
Fix lineHeight test for QQuickText
qCeil() should be used to wrap the result of height() instead of the end result after multiply with 1.5. Change-Id: Ia69d63ad4a9aa9c48365b8c3b994708bbbdab7c5 Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com>
-rw-r--r--tests/auto/quick/qquicktext/tst_qquicktext.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/quick/qquicktext/tst_qquicktext.cpp b/tests/auto/quick/qquicktext/tst_qquicktext.cpp
index d9395ca78d..28eed57a95 100644
--- a/tests/auto/quick/qquicktext/tst_qquicktext.cpp
+++ b/tests/auto/quick/qquicktext/tst_qquicktext.cpp
@@ -1602,7 +1602,7 @@ void tst_qquicktext::lineHeight()
qreal h = myText->height();
myText->setLineHeight(1.5);
- QCOMPARE(myText->height(), qreal(qCeil(h * 1.5)));
+ QCOMPARE(myText->height(), qreal(qCeil(h)) * 1.5);
myText->setLineHeightMode(QQuickText::FixedHeight);
myText->setLineHeight(20);