X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fchatitem.cpp;h=3d2e065ebe33fd817833a3764896e1abac58b6fa;hp=a78d2f8a450695c7ea49d2c758bc9463115033df;hb=952ac961af5ad09fa4105de5c938c147b260b3a0;hpb=230b29dce3fa51ffac9d5e834e6bc7c4764f2c15 diff --git a/src/qtui/chatitem.cpp b/src/qtui/chatitem.cpp index a78d2f8a..3d2e065e 100644 --- a/src/qtui/chatitem.cpp +++ b/src/qtui/chatitem.cpp @@ -278,7 +278,7 @@ void SenderChatItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *op if(layoutWidth > width()) { // Draw a nice gradient for longer items // Qt's text drawing with a gradient brush sucks, so we use an alpha-channeled pixmap instead - QPixmap pixmap(QSize(layout()->boundingRect().width(), layout()->boundingRect().height())); + QPixmap pixmap(layout()->boundingRect().toRect().size()); pixmap.fill(Qt::transparent); QPainter pixPainter(&pixmap); layout()->draw(&pixPainter, QPointF(qMax(offset, (qreal)0), 0), QVector() << selectFmt); @@ -359,7 +359,7 @@ void ContentsChatItem::doLayout() { QList ContentsChatItem::findClickables() const { // For matching URLs static QString urlEnd("(?:>|[,.;:\"]*\\s|\\b|$)"); - static QString urlChars("(?:[,.;:]*[\\w\\-~@/?&=+$()!%#])"); + static QString urlChars("(?:[,.;:]*[\\w\\-~@/?&=+$()!%#*|{}\\[\\]])"); static QRegExp regExp[] = { // URL