}
}
- _formats[fmtType] = format;
+ _formats[fmtType].merge(format);
}
quint64 QssParser::parseFormatType(const QString &decl) {
quint64 labeltype = 0;
if(condValue == "highlight")
labeltype = UiStyle::Highlight;
+ else if(condValue == "selected")
+ labeltype = UiStyle::Selected;
else {
qWarning() << Q_FUNC_INFO << tr("Invalid message label: %1").arg(condValue);
return UiStyle::Invalid;
/******** Font Properties ********/
void QssParser::parseFont(const QString& value, QTextCharFormat* format) {
- QRegExp rx("((?:(?:normal|italic|oblique|bold|100|200|300|400|500|600|700|800|900) ){0,2}) ?(\\d+)(pt|px)? \"(.*)\"");
+ QRegExp rx("((?:(?:normal|italic|oblique|underline|bold|100|200|300|400|500|600|700|800|900) ){0,2}) ?(\\d+)(pt|px)? \"(.*)\"");
if(!rx.exactMatch(value)) {
qWarning() << Q_FUNC_INFO << tr("Invalid font specification: %1").arg(value);
return;
foreach(QString prop, proplist) {
if(prop == "italic")
format->setFontItalic(true);
+ else if(prop == "underline")
+ format->setFontUnderline(true);
//else if(prop == "oblique")
// format->setStyle(QFont::StyleOblique);
else if(prop == "bold")
format->setFontItalic(false);
else if(value == "italic")
format->setFontItalic(true);
+ else if(value == "underline")
+ format->setFontUnderline(true);
//else if(value == "oblique")
// format->setStyle(QFont::StyleOblique);
else {