X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fuisupport%2Ftabcompleter.cpp;h=88c2f0c6c1e2fe870800d257f72d95505f4845af;hb=906391224228274450914361efd104630827e580;hp=b9b6eb1414352d4ecc746bcf8cc374796e06ccd3;hpb=f047a4f7add72ef7e32ad33f884e62a5773ecc72;p=quassel.git diff --git a/src/uisupport/tabcompleter.cpp b/src/uisupport/tabcompleter.cpp index b9b6eb14..88c2f0c6 100644 --- a/src/uisupport/tabcompleter.cpp +++ b/src/uisupport/tabcompleter.cpp @@ -61,8 +61,8 @@ void TabCompleter::buildCompletionList() { if(!_currentNetwork) return; - QString tabAbbrev = _lineEdit->text().left(_lineEdit->cursorPosition()).section(' ',-1,-1); - QRegExp regex(QString("^[^a-zA-Z]*").append(QRegExp::escape(tabAbbrev)), Qt::CaseInsensitive); + QString tabAbbrev = _lineEdit->text().left(_lineEdit->cursorPosition()).section(QRegExp("[^\\w\\d-_\\[\\]{}|`^.\\\\]"),-1,-1); + QRegExp regex(QString("^[-_\\[\\]{}|`^.\\\\]*").append(QRegExp::escape(tabAbbrev)), Qt::CaseInsensitive); switch(static_cast(currentIndex.data(NetworkModel::BufferTypeRole).toInt())) { case BufferInfo::ChannelBuffer: