diff options
author | Warwick Allison <warwick.allison@nokia.com> | 2009-08-14 06:56:46 (GMT) |
---|---|---|
committer | Warwick Allison <warwick.allison@nokia.com> | 2009-08-14 06:56:46 (GMT) |
commit | c57c204a63168e875e513d299bb152c0a1ab0094 (patch) | |
tree | 0603881035f17a7ecbce6a6e3c3e5f8f18b2f845 /tests | |
parent | c80302a19f43ed1c39675a979762499fc589743a (diff) | |
download | Qt-c57c204a63168e875e513d299bb152c0a1ab0094.zip Qt-c57c204a63168e875e513d299bb152c0a1ab0094.tar.gz Qt-c57c204a63168e875e513d299bb152c0a1ab0094.tar.bz2 |
Fix MLS test
"sm"+ellipsis (...) is same length as "small" in some fonts
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/qfontmetrics/tst_qfontmetrics.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/auto/qfontmetrics/tst_qfontmetrics.cpp b/tests/auto/qfontmetrics/tst_qfontmetrics.cpp index 9a743ef..9ffbc05 100644 --- a/tests/auto/qfontmetrics/tst_qfontmetrics.cpp +++ b/tests/auto/qfontmetrics/tst_qfontmetrics.cpp @@ -218,8 +218,9 @@ void tst_QFontMetrics::elidedMultiLength() QCOMPARE(fm.elidedText(text1,Qt::ElideRight, width_short), text1_short); QCOMPARE(fm.elidedText(text1,Qt::ElideRight, width_short - 1), text1_small); + // Not even wide enough for "small" - should use ellipsis QChar ellipsisChar(0x2026); - QString text1_el = QString::fromLatin1("sm") + ellipsisChar; + QString text1_el = QString::fromLatin1("s") + ellipsisChar; int width_small = fm.width(text1_el); QCOMPARE(fm.elidedText(text1,Qt::ElideRight, width_small + 1), text1_el); |