diff options
author | Martin Jones <martin.jones@nokia.com> | 2011-12-13 12:37:10 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-12-14 04:47:06 +0100 |
commit | 7a6befdf2572f09fbffc81122c0f0f1b30265af4 (patch) | |
tree | 37aed04b2dec514e5803f9ce84a334d2a81849e3 /src/quick/util/qdeclarativestyledtext.cpp | |
parent | 2a3990fc4125eeb0c73eaae05450789717dfd045 (diff) |
Support <strong> in styled text.
Task-number: QTBUG-23105
Change-Id: I15968c43fd0797b94584f110c6aeca06eca832b7
Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
Diffstat (limited to 'src/quick/util/qdeclarativestyledtext.cpp')
-rw-r--r-- | src/quick/util/qdeclarativestyledtext.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/quick/util/qdeclarativestyledtext.cpp b/src/quick/util/qdeclarativestyledtext.cpp index 1c7ca5fbfd..2f79fad9a2 100644 --- a/src/quick/util/qdeclarativestyledtext.cpp +++ b/src/quick/util/qdeclarativestyledtext.cpp @@ -253,6 +253,9 @@ bool QDeclarativeStyledTextPrivate::parseTag(const QChar *&ch, const QString &te if (!hasNewLine) textOut.append(QChar::LineSeparator); } + } else if (char0 == QLatin1Char('s')) { + if (tag == QLatin1String("strong")) + format.setFontWeight(QFont::Bold); } else if (char0 == QLatin1Char('u')) { if (tagLength == 1) format.setFontUnderline(true); @@ -384,6 +387,8 @@ bool QDeclarativeStyledTextPrivate::parseCloseTag(const QChar *&ch, const QStrin return true; } else if (tag == QLatin1String("font")) { return true; + } else if (tag == QLatin1String("strong")) { + return true; } else if (tag == QLatin1String("ol")) { if (!listStack.isEmpty()) { listStack.pop(); |