summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAleix Pol <aleixpol@kde.org>2016-01-20 17:45:00 +0100
committerAleix Pol Gonzalez <aleixpol@kde.org>2016-02-09 21:24:46 +0000
commit8b4ac65e2913bd7fbdd996ca290b129659f89a9e (patch)
treeb09fe3f2de0439c13493d5f4300b123b29e16a27 /src
parent22c262d2d7a7c262c7cecf68c2f6bef5ec29e6b5 (diff)
Provide QCss with the correct font for <pre> blocks
Labels would use a statically defined font for <pre> blocks. Use the one defined by the QPlatformTheme instead, through QFontDatabase::systemFont(FixedFont) Task-number: QTBUG-50564 Change-Id: I5491bd0defce651bdf809bcbc6a529a900f4959b Reviewed-by: Milian Wolff <milian.wolff@kdab.com>
Diffstat (limited to 'src')
-rw-r--r--src/gui/text/qtexthtmlparser.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/gui/text/qtexthtmlparser.cpp b/src/gui/text/qtexthtmlparser.cpp
index f8f41bb53d..77da01be3f 100644
--- a/src/gui/text/qtexthtmlparser.cpp
+++ b/src/gui/text/qtexthtmlparser.cpp
@@ -1926,13 +1926,7 @@ QVector<QCss::Declaration> standardDeclarationForNode(const QTextHtmlParserNode
decl.d->propertyId = QCss::FontFamily;
QVector<QCss::Value> values;
val.type = QCss::Value::String;
- val.variant = QLatin1String("Courier New");
- values << val;
- val.type = QCss::Value::TermOperatorComma;
- val.variant = QVariant();
- values << val;
- val.type = QCss::Value::String;
- val.variant = QLatin1String("courier");
+ val.variant = QFontDatabase::systemFont(QFontDatabase::FixedFont).family();
values << val;
decl.d->values = values;
decl.d->inheritable = true;