summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp')
-rw-r--r--tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp b/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp
index da8ae5606f..aa9a81ed27 100644
--- a/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp
+++ b/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp
@@ -63,6 +63,7 @@ private slots:
void boundingRect();
void mixedScripts();
void multiLineBoundingRect();
+ void defaultIgnorables();
private:
int m_testFontId;
@@ -631,6 +632,21 @@ void tst_QGlyphRun::multiLineBoundingRect()
QVERIFY(firstLineGlyphRun.boundingRect().height() < allGlyphRun.boundingRect().height());
}
+void tst_QGlyphRun::defaultIgnorables()
+{
+ QTextLayout layout;
+ layout.setFont(QFont("QtsSpecialTestFont"));
+ layout.setText(QChar(0x200D));
+ layout.beginLayout();
+ layout.createLine();
+ layout.endLayout();
+
+ QList<QGlyphRun> runs = layout.glyphRuns();
+ QCOMPARE(runs.size(), 1);
+ QCOMPARE(runs.at(0).glyphIndexes().size(), 1);
+ QCOMPARE(runs.at(0).glyphIndexes()[0], 0);
+}
+
#endif // QT_NO_RAWFONT
QTEST_MAIN(tst_QGlyphRun)