From f34c2c3b1198afac23f9894a56c5ab2fae798f59 Mon Sep 17 00:00:00 2001 From: mae Date: Mon, 15 Jun 2009 10:34:07 +0200 Subject: Fix QPlainTextEdit auto test Width 0 was used as magic value to optimize the widget's startup and initial resize. We now use the illegal value -1 as magic value insetad. --- src/gui/widgets/qplaintextedit.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/widgets/qplaintextedit.cpp b/src/gui/widgets/qplaintextedit.cpp index af11aa7..ca7dffd 100644 --- a/src/gui/widgets/qplaintextedit.cpp +++ b/src/gui/widgets/qplaintextedit.cpp @@ -761,7 +761,7 @@ void QPlainTextEditPrivate::init(const QString &txt) // set a null page size initially to avoid any relayouting until the textedit // is shown. relayoutDocument() will take care of setting the page size to the // viewport dimensions later. - doc->setTextWidth(0); + doc->setTextWidth(-1); doc->documentLayout()->setPaintDevice(viewport); doc->setDefaultFont(q->font()); -- cgit v0.12