summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-09-10 16:20:20 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-09-10 16:20:20 (GMT)
commit3dc18b19ee2a02b93cc509a9162bf0a3900c6fd0 (patch)
tree7865bc34d720c17d68f84570be836cc52e8fb5aa /tests
parent72cc21e597f2d77ea1be3c1a3f7df36d8909d2fc (diff)
parente78274d5f8c0eb5c10b9b58e069b90b6475c6f71 (diff)
downloadQt-3dc18b19ee2a02b93cc509a9162bf0a3900c6fd0.zip
Qt-3dc18b19ee2a02b93cc509a9162bf0a3900c6fd0.tar.gz
Qt-3dc18b19ee2a02b93cc509a9162bf0a3900c6fd0.tar.bz2
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2: Prevented crash in GL window surface when deleting native child widgets. Fix a regression where setPreferredSize(QSize(100, -1)) did not work. Force MeeGo touch to use native graphics system for now. Fixed compiler warnings in meego graphics system helper. Added meego graphics system helper to features/qt.prf and syncqt. Use QFactoryLoader to ensure we get the correct graphics system plugin. Updated license headers for meego graphics system helper. Fixed compilation and API of meego graphics system helper. Renamed meego graphics system helper files. Imported meego graphics system helper sources. Updated license headers for meego graphics system. Fixed compilation and API of meego graphics system. Renamed meego graphics system files. Imported meego graphics system sources. Fix cache_cost initialization of QFontEngineMultiWin Fix crash when using unprintable chars in QStaticText Don't waste memory on the share widget in the GL window surface.
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/qgraphicslayoutitem/tst_qgraphicslayoutitem.cpp8
-rw-r--r--tests/auto/qstatictext/tst_qstatictext.cpp11
2 files changed, 19 insertions, 0 deletions
diff --git a/tests/auto/qgraphicslayoutitem/tst_qgraphicslayoutitem.cpp b/tests/auto/qgraphicslayoutitem/tst_qgraphicslayoutitem.cpp
index 879e12b..dbffa6e 100644
--- a/tests/auto/qgraphicslayoutitem/tst_qgraphicslayoutitem.cpp
+++ b/tests/auto/qgraphicslayoutitem/tst_qgraphicslayoutitem.cpp
@@ -75,6 +75,7 @@ private slots:
void setPreferredSize_data();
void setPreferredSize();
void setSizePolicy_data();
+ void setPreferredSize2();
void setSizePolicy();
};
@@ -343,6 +344,13 @@ void tst_QGraphicsLayoutItem::setPreferredSize()
}
}
+void tst_QGraphicsLayoutItem::setPreferredSize2()
+{
+ SubQGraphicsLayoutItem layoutItem;
+ layoutItem.setPreferredSize(QSizeF(30, -1));
+ QCOMPARE(layoutItem.preferredWidth(), qreal(30));
+}
+
void tst_QGraphicsLayoutItem::setSizePolicy_data()
{
QTest::addColumn<QSizePolicy>("policy");
diff --git a/tests/auto/qstatictext/tst_qstatictext.cpp b/tests/auto/qstatictext/tst_qstatictext.cpp
index 2a60e9e..68c3ea9 100644
--- a/tests/auto/qstatictext/tst_qstatictext.cpp
+++ b/tests/auto/qstatictext/tst_qstatictext.cpp
@@ -91,6 +91,8 @@ private slots:
void drawStruckOutText();
void drawOverlinedText();
void drawUnderlinedText();
+
+ void unprintableCharacter_qtbug12614();
};
void tst_QStaticText::init()
@@ -753,5 +755,14 @@ void tst_QStaticText::drawUnderlinedText()
QCOMPARE(imageDrawText, imageDrawStaticText);
}
+void tst_QStaticText::unprintableCharacter_qtbug12614()
+{
+ QString s(QChar(0x200B)); // U+200B, ZERO WIDTH SPACE
+
+ QStaticText staticText(s);
+
+ QVERIFY(staticText.size().isValid()); // Force layout. Should not crash.
+}
+
QTEST_MAIN(tst_QStaticText)
#include "tst_qstatictext.moc"