diff options
author | Martin Jones <martin.jones@nokia.com> | 2010-07-21 00:36:17 (GMT) |
---|---|---|
committer | Martin Jones <martin.jones@nokia.com> | 2010-07-21 00:36:17 (GMT) |
commit | 78a01438e5a37fd1778924f73ca8bfa55960b0d0 (patch) | |
tree | 5c19f64dc405ef24be8618f6d3a709d27e46793e /tests/auto/declarative/qdeclarativetext | |
parent | 164b2b54922d87a44a60efe6dbbe2fa3b7716820 (diff) | |
download | Qt-78a01438e5a37fd1778924f73ca8bfa55960b0d0.zip Qt-78a01438e5a37fd1778924f73ca8bfa55960b0d0.tar.gz Qt-78a01438e5a37fd1778924f73ca8bfa55960b0d0.tar.bz2 |
font.letterSpacing used percentage rather than absolute values.
... and percentage is useless.
Task-number: QTBUG-12282
Reviewed-by: Warwick Allison
Diffstat (limited to 'tests/auto/declarative/qdeclarativetext')
-rw-r--r-- | tests/auto/declarative/qdeclarativetext/tst_qdeclarativetext.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/auto/declarative/qdeclarativetext/tst_qdeclarativetext.cpp b/tests/auto/declarative/qdeclarativetext/tst_qdeclarativetext.cpp index 53862ec..821394d 100644 --- a/tests/auto/declarative/qdeclarativetext/tst_qdeclarativetext.cpp +++ b/tests/auto/declarative/qdeclarativetext/tst_qdeclarativetext.cpp @@ -848,22 +848,22 @@ void tst_qdeclarativetext::letterSpacing() QCOMPARE(textObject->font().letterSpacing(), 0.0); } { - QString componentStr = "import Qt 4.7\nText { text: \"Hello world!\"; font.letterSpacing: -50 }"; + QString componentStr = "import Qt 4.7\nText { text: \"Hello world!\"; font.letterSpacing: -2 }"; QDeclarativeComponent textComponent(&engine); textComponent.setData(componentStr.toLatin1(), QUrl::fromLocalFile("")); QDeclarativeText *textObject = qobject_cast<QDeclarativeText*>(textComponent.create()); QVERIFY(textObject != 0); - QCOMPARE(textObject->font().letterSpacing(), -50.); + QCOMPARE(textObject->font().letterSpacing(), -2.); } { - QString componentStr = "import Qt 4.7\nText { text: \"Hello world!\"; font.letterSpacing: 200 }"; + QString componentStr = "import Qt 4.7\nText { text: \"Hello world!\"; font.letterSpacing: 3 }"; QDeclarativeComponent textComponent(&engine); textComponent.setData(componentStr.toLatin1(), QUrl::fromLocalFile("")); QDeclarativeText *textObject = qobject_cast<QDeclarativeText*>(textComponent.create()); QVERIFY(textObject != 0); - QCOMPARE(textObject->font().letterSpacing(), 200.); + QCOMPARE(textObject->font().letterSpacing(), 3.); } } |