summaryrefslogtreecommitdiffstats
path: root/src/gui/text/qtextdocument.cpp
diff options
context:
space:
mode:
authorAndy Shaw <qt-info@nokia.com>2010-06-21 12:08:26 +0200
committerAndy Shaw <qt-info@nokia.com>2010-06-21 12:08:26 +0200
commit033fea2483945aa2ecb238751121098b594a1877 (patch)
treef8a2b28e95640dab0e801037722e73b4633d0296 /src/gui/text/qtextdocument.cpp
parent1fb24d6852e34bd58f35172dea4bfd4c41236689 (diff)
parent448dd8593f3e7e680ce3d0f92e279aad3c88d7d6 (diff)
Merge branch '4.7' of git@scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7
Diffstat (limited to 'src/gui/text/qtextdocument.cpp')
-rw-r--r--src/gui/text/qtextdocument.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/gui/text/qtextdocument.cpp b/src/gui/text/qtextdocument.cpp
index 65e88ab297..e0386f1ffe 100644
--- a/src/gui/text/qtextdocument.cpp
+++ b/src/gui/text/qtextdocument.cpp
@@ -2498,13 +2498,10 @@ void QTextHtmlExporter::emitBlockAttributes(const QTextBlock &block)
QTextBlockFormat format = block.blockFormat();
emitAlignment(format.alignment());
- Qt::LayoutDirection dir = format.layoutDirection();
- if (dir == Qt::LeftToRight) {
- // assume default to not bloat the html too much
- // html += QLatin1String(" dir='ltr'");
- } else {
+ // assume default to not bloat the html too much
+ // html += QLatin1String(" dir='ltr'");
+ if (block.textDirection() == Qt::RightToLeft)
html += QLatin1String(" dir='rtl'");
- }
QLatin1String style(" style=\"");
html += style;