From: Bas Pape Date: Tue, 27 Aug 2013 19:59:37 +0000 (+0200) Subject: Strip formatting when looking up the clickable. X-Git-Tag: 0.10-beta1~128 X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=commitdiff_plain;h=2a912804c20a066356db4e156661468ca49bcc57 Strip formatting when looking up the clickable. In the TopicWidget the list of Clickables is initialized with text stripped of formatting, so when looking up their positions again, the formatting should be stripped as well. Fixes #1115 --- diff --git a/src/qtui/topicwidget.cpp b/src/qtui/topicwidget.cpp index 8b8e16d4..827452cc 100644 --- a/src/qtui/topicwidget.cpp +++ b/src/qtui/topicwidget.cpp @@ -24,6 +24,8 @@ #include "iconloader.h" #include "networkmodel.h" #include "uisettings.h" +#include "graphicalui.h" +#include "uistyle.h" TopicWidget::TopicWidget(QWidget *parent) : AbstractItemView(parent) @@ -191,7 +193,8 @@ void TopicWidget::updateResizeMode() void TopicWidget::clickableActivated(const Clickable &click) { NetworkId networkId = selectionModel()->currentIndex().data(NetworkModel::NetworkIdRole).value(); - click.activate(networkId, _topic); + UiStyle::StyledString sstr = GraphicalUi::uiStyle()->styleString(GraphicalUi::uiStyle()->mircToInternal(_topic), UiStyle::PlainMsg); + click.activate(networkId, sstr.plainText); }