From 4598939ee2fad1238609ca43717199fd4e98c75f Mon Sep 17 00:00:00 2001 From: Andrew den Exter Date: Thu, 5 Jul 2012 10:18:43 +1000 Subject: Speed up TextEdit construction time. Defer setting content on the QTextDocument until componentComplete() to avoid unnecessary layouts and move one time setup for the text document from setContent to the constructor. Reduces the construction time of a TextEdit with RichText textFormat by about a third. Change-Id: Idde0772063bf769cde984efddd68589c55a7431a Reviewed-by: Martin Jones --- src/quick/items/qquicktextcontrol_p.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/quick/items/qquicktextcontrol_p.h') diff --git a/src/quick/items/qquicktextcontrol_p.h b/src/quick/items/qquicktextcontrol_p.h index e8abfc090e..293a465ca2 100644 --- a/src/quick/items/qquicktextcontrol_p.h +++ b/src/quick/items/qquicktextcontrol_p.h @@ -150,7 +150,6 @@ Q_SIGNALS: // control signals void updateCursorRequest(); void updateRequest(); - void documentSizeChanged(const QSizeF &); void cursorRectangleChanged(); void linkActivated(const QString &link); @@ -175,7 +174,6 @@ private: Q_DISABLE_COPY(QQuickTextControl) Q_PRIVATE_SLOT(d_func(), void _q_updateCurrentCharFormatAndSelection()) Q_PRIVATE_SLOT(d_func(), void _q_emitCursorPosChanged(const QTextCursor &)) - Q_PRIVATE_SLOT(d_func(), void _q_documentLayoutChanged()) }; -- cgit v1.2.3