From 4256ac4821446383da9a9dcda3532fbfa3eb6beb Mon Sep 17 00:00:00 2001 From: Manuel Nickschas Date: Tue, 5 Aug 2008 13:02:53 +0200 Subject: [PATCH] Fix URL regexp to not include whitespace anymore --- src/qtui/chatitem.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qtui/chatitem.cpp b/src/qtui/chatitem.cpp index adfcd9c8..f09553b5 100644 --- a/src/qtui/chatitem.cpp +++ b/src/qtui/chatitem.cpp @@ -241,7 +241,7 @@ void ChatItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { void ChatItem::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) { // FIXME dirty and fast hack to make http:// urls klickable - QRegExp regex("\\b((?:h|f)t{1,2}ps?:\\/\\/.+)\\b"); + QRegExp regex("\\b((?:h|f)t{1,2}ps?://[^\\s]+)\\b"); QString str = data(ChatLineModel::DisplayRole).toString(); int idx = posToCursor(event->pos()); int mi = 0; -- 2.20.1