diff options
author | Jiang Jiang <jiang.jiang@nokia.com> | 2010-09-22 13:10:44 (GMT) |
---|---|---|
committer | Jesper Thomschutz <jesper.thomschutz@nokia.com> | 2010-09-23 15:04:36 (GMT) |
commit | 0c63d0ed5417c72056632fc5b4bfc29f889b1cc1 (patch) | |
tree | 85398ee8df6ab5eea54daa751400d4ab61a28f7e /src/gui | |
parent | 638face91faa7b6ff8cb85e6228faa1967cc66ac (diff) | |
download | Qt-0c63d0ed5417c72056632fc5b4bfc29f889b1cc1.zip Qt-0c63d0ed5417c72056632fc5b4bfc29f889b1cc1.tar.gz Qt-0c63d0ed5417c72056632fc5b4bfc29f889b1cc1.tar.bz2 |
Fix text direction setting in QTextBlock layout
QTextControl should no longer inherit the layout direction of
parent widget as its default text direction.
Reviewed-by: Eskil Abrahamsen Blomfeldt
Reviewed-by: Lars Knoll
(cherry picked from commit 6397e5bc49f11e20a9d1838d8d8df46dd9486263)
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/text/qtextcontrol.cpp | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/src/gui/text/qtextcontrol.cpp b/src/gui/text/qtextcontrol.cpp index 5fe0c0c..7f2c4e9 100644 --- a/src/gui/text/qtextcontrol.cpp +++ b/src/gui/text/qtextcontrol.cpp @@ -404,12 +404,6 @@ void QTextControlPrivate::init(Qt::TextFormat format, const QString &text, QText Q_Q(QTextControl); setContent(format, text, document); - QWidget *parentWidget = qobject_cast<QWidget*>(parent); - if (parentWidget) { - QTextOption opt = doc->defaultTextOption(); - opt.setTextDirection(parentWidget->layoutDirection()); - doc->setDefaultTextOption(opt); - } doc->setUndoRedoEnabled(interactionFlags & Qt::TextEditable); q->setCursorWidth(-1); } |