X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fchatscene.cpp;h=1588f4df5c9b0cf13eba50a599e7043133aa1b75;hp=d609f0a8ffb70b4d600b33bc01c57e1982b48f1e;hb=b8e812857ca64834078e1f620bf98fffa48b7768;hpb=6d32c0e7661d4404c2bd0e44652439b6c55b4545 diff --git a/src/qtui/chatscene.cpp b/src/qtui/chatscene.cpp index d609f0a8..1588f4df 100644 --- a/src/qtui/chatscene.cpp +++ b/src/qtui/chatscene.cpp @@ -75,6 +75,7 @@ ChatScene::ChatScene(QAbstractItemModel *model, const QString &idString, qreal w _markerLineValid(false), _markerLineJumpPending(false), _cutoffMode(CutoffRight), + _alwaysBracketSender(false), _selectingItem(0), _selectionStart(-1), _isSelecting(false), @@ -1050,9 +1051,14 @@ QString ChatScene::selection() const } if (_selectionMinCol <= ChatLineModel::SenderColumn) { ChatItem *item = _lines[l]->item(ChatLineModel::SenderColumn); - if (!_showSenderBrackets && item->chatLine()->msgType() == Message::Plain) { - // Copying to plain-text. Only re-add the sender brackets if they're normally - // hidden. + if (!_showSenderBrackets && (_alwaysBracketSender + || item->chatLine()->msgType() == Message::Plain)) { + // Copying to plain-text. Re-add the sender brackets if they're normally hidden + // for... + // * Plain messages + // * All messages in the Chat Monitor + // + // The Chat Monitor sets alwaysBracketSender() to true. result += QString("<%1> ").arg(item->data(MessageModel::DisplayRole) .toString()); } else {