projects
/
konrad/qtdeclarative.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
ddd6afe
)
Fix lineHeight test for QQuickText
author
Jiang Jiang
<jiang.jiang@nokia.com>
Wed, 30 May 2012 07:50:34 +0000 (09:50 +0200)
committer
Qt by Nokia
<qt-info@nokia.com>
Wed, 30 May 2012 11:30:06 +0000 (13:30 +0200)
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>
tests/auto/quick/qquicktext/tst_qquicktext.cpp
patch
|
blob
|
history
diff --git
a/tests/auto/quick/qquicktext/tst_qquicktext.cpp
b/tests/auto/quick/qquicktext/tst_qquicktext.cpp
index
d9395ca
..
28eed57
100644
(file)
--- 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);