summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>2012-09-12 12:13:35 +0200
committerQt by Nokia <qt-info@nokia.com>2012-09-12 16:05:12 +0200
commite640ebacb97f6eea9614925b1da3b97a0ff51409 (patch)
treecaf05a1bd603e1c05a42359e1531064a3bfcf29e /src
parentee1e37cc64bf68f221e80dd0aa11c571f2e40a33 (diff)
Fix regression in QTextDocument::toHtml() with font pixel size
Introduced by 2e0003eda4783f69a40fb4b31e7084c761d9640d. We were missing a attributesEmitted=true which caused the output from toHtml() to sometimes be invalid when using pixel sizes to specify the font size. Task-number: QTBUG-25778 Change-Id: Ied61fcaef425a590d71c0b52292ac676cb88ba52 Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org> Reviewed-by: Jiang Jiang <gzjjgod@gmail.com>
Diffstat (limited to 'src')
-rw-r--r--src/gui/text/qtextdocument.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gui/text/qtextdocument.cpp b/src/gui/text/qtextdocument.cpp
index 3203f85cc9..19c75b7b39 100644
--- a/src/gui/text/qtextdocument.cpp
+++ b/src/gui/text/qtextdocument.cpp
@@ -2142,6 +2142,7 @@ bool QTextHtmlExporter::emitCharFormatStyle(const QTextCharFormat &format)
html += QLatin1String(" font-size:");
html += QString::number(format.intProperty(QTextFormat::FontPixelSize));
html += QLatin1String("px;");
+ attributesEmitted = true;
}
if (format.hasProperty(QTextFormat::FontWeight)