X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fqtui%2Fqtuimessageprocessor.cpp;h=eee90aab002d88c805ef0509dae0556709388b13;hb=faa66f7e00aeeea661b46f01bdfc715567eef669;hp=84deebee27371e1cd58134f4d787fc05738976e1;hpb=83662b607de9eb742fe9de4dd9445914a6bd9456;p=quassel.git diff --git a/src/qtui/qtuimessageprocessor.cpp b/src/qtui/qtuimessageprocessor.cpp index 84deebee..eee90aab 100644 --- a/src/qtui/qtuimessageprocessor.cpp +++ b/src/qtui/qtuimessageprocessor.cpp @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2005-2015 by the Quassel Project * + * Copyright (C) 2005-2016 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -130,7 +130,7 @@ void QtUiMessageProcessor::checkForHighlight(Message &msg) } foreach(QString nickname, nickList) { QRegExp nickRegExp("(^|\\W)" + QRegExp::escape(nickname) + "(\\W|$)", _nicksCaseSensitive ? Qt::CaseSensitive : Qt::CaseInsensitive); - if (nickRegExp.indexIn(msg.contents()) >= 0) { + if (nickRegExp.indexIn(stripFormatCodes(msg.contents())) >= 0) { msg.setFlags(msg.flags() | Message::Highlight); return; } @@ -161,7 +161,7 @@ void QtUiMessageProcessor::checkForHighlight(Message &msg) else { rx = QRegExp("(^|\\W)" + QRegExp::escape(rule.name) + "(\\W|$)", rule.caseSensitive ? Qt::CaseSensitive : Qt::CaseInsensitive); } - bool match = (rx.indexIn(msg.contents()) >= 0); + bool match = (rx.indexIn(stripFormatCodes(msg.contents())) >= 0); if (match) { msg.setFlags(msg.flags() | Message::Highlight); return;