summaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2011-04-29 20:40:31 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2011-04-29 20:40:31 (GMT)
commit711229c3380f31201f16faeb489cc89730971336 (patch)
tree996d157291634a42f80133f51a600dc3b4bc23db /tests/auto
parent0e7510e104365363836173a1bc068b16dec76bcc (diff)
parent49d2906a9566c8b44df48f51ca137b9ba2feb671 (diff)
downloadQt-711229c3380f31201f16faeb489cc89730971336.zip
Qt-711229c3380f31201f16faeb489cc89730971336.tar.gz
Qt-711229c3380f31201f16faeb489cc89730971336.tar.bz2
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-fire-team
* 'master' of git://scm.dev.nokia.troll.no/qt/qt-fire-team: Make sure removed QTextBlock is invalid Make sure QFont's resolve mask is copied on compilers with C++0x support Fix glyph position issue with fallback fonts
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/qtextblock/tst_qtextblock.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/auto/qtextblock/tst_qtextblock.cpp b/tests/auto/qtextblock/tst_qtextblock.cpp
index cec3a6a..748d921 100644
--- a/tests/auto/qtextblock/tst_qtextblock.cpp
+++ b/tests/auto/qtextblock/tst_qtextblock.cpp
@@ -76,6 +76,7 @@ private slots:
void excludeParagraphSeparatorFragment();
void backwardsBlockIterator();
void previousBlock_qtbug18026();
+ void removedBlock_qtbug18500();
private:
QTextDocument *doc;
@@ -181,5 +182,16 @@ void tst_QTextBlock::previousBlock_qtbug18026()
QVERIFY(last.isValid());
}
+void tst_QTextBlock::removedBlock_qtbug18500()
+{
+ cursor.insertText("line 1\nline 2\nline 3 \nline 4\n");
+ cursor.setPosition(7);
+ QTextBlock block = cursor.block();
+ cursor.setPosition(21, QTextCursor::KeepAnchor);
+
+ cursor.removeSelectedText();
+ QVERIFY(!block.isValid());
+}
+
QTEST_MAIN(tst_QTextBlock)
#include "tst_qtextblock.moc"