Version: (using Devel) OS: Linux Installed from: Compiled sources When scrolling, or simply when a new message comes (causing the window to scroll automatically) and a background image is set it doesn't redraw the entire window. I'll attach a screenshot of the issue in a comment on this bug report as it's easier to just see it rather than explain it. Don't know if it's of any help, but I have this issue using the NVIDIA driver, 190.53. (NVIDIA 9600M GT videocard)
Created attachment 40195 [details] Screenshot of Konversation redrawing issue.
We really need your KDE and Qt version numbers as well, since we don't control the background image drawing ourselves - it's a Qt widget. So the bug is unlikely to be ours and might be specific to a particular Qt version (it doesn't happen here).
(I have KDE 4.4rc1 on Qt 4.6.1, fwiw.)
KDE 4.3.95 (KDE 4.4 RC2) "Release 214" and Qt 4.6.1-86.1 Packages from: http://download.opensuse.org/repositories/KDE:/KDE4:/Factory:/Desktop/openSUSE_11.2/x86_64/ I've had the same thing happen under KDE 4.5 however
commit c0491dc653337f7b40a8e4cb88835e745fde7968 Author: Bernd Buschinski <b.buschinski@web.de> Date: Fri Sep 10 14:08:58 2010 +0200 Set backgroundimage with Qt Style Sheets as they seems to be more eager in repainting the whole image as the QPalette background brush. Tested on my intel-gfx laptop with current git drivers (where it always happened) and on my desktop gf8800gt with nvidia-260.19.04(where it only happens with my test login). BUG:224033 diff --git a/src/viewer/ircview.cpp b/src/viewer/ircview.cpp index 6cecaa1..90c2bf6 100644 --- a/src/viewer/ircview.cpp +++ b/src/viewer/ircview.cpp @@ -557,25 +557,19 @@ void IRCView::updateAppearance() setVerticalScrollBarPolicy(Preferences::self()->showIRCViewScrollBar() ? Qt::ScrollBarAlwaysOn : Qt::ScrollBarAlwaysOff); - QPalette p; - - p.setColor(QPalette::Base, Preferences::self()->color(Preferences::TextViewBackground)); - if (Preferences::self()->showBackgroundImage()) { KUrl url = Preferences::self()->backgroundImage(); if (!url.isEmpty()) { - QBrush brush; - - brush.setTexture(QPixmap(url.path())); - - p.setBrush(QPalette::Base, brush); + setStyleSheet("QTextBrowser { background-image: url("+url.path()+");background-attachment: fixed }"); } } - - setPalette(p); + else + { + setStyleSheet("QTextBrowser { background-color:" + Preferences::self()->color(Preferences::TextViewBackground).name() + " }"); + } } // Data insertion
commit c5da3e3f4e8c527f7e77aa4abef7eabbacfe4158 Author: Bernd Buschinski <b.buschinski@web.de> Date: Fri Sep 10 16:47:33 2010 +0200 Revert Qt Style Sheet solution, as it breaks scrollbar drawing CCBUG:224033 diff --git a/src/viewer/ircview.cpp b/src/viewer/ircview.cpp index 4d55bd8..33bf88b 100644 --- a/src/viewer/ircview.cpp +++ b/src/viewer/ircview.cpp @@ -557,28 +557,24 @@ void IRCView::updateAppearance() setVerticalScrollBarPolicy(Preferences::self()->showIRCViewScrollBar() ? Qt::ScrollBarAlwaysOn : Qt::ScrollBarAlwaysOff); - bool bgImageSet = false; + QPalette p; + + p.setColor(QPalette::Base, Preferences::self()->color(Preferences::TextViewBackground)); + if (Preferences::self()->showBackgroundImage()) { KUrl url = Preferences::self()->backgroundImage(); if (!url.isEmpty()) { - setStyleSheet("QTextBrowser { background-image: url("+url.path()+");background-attachment: fixed }"); - bgImageSet = true; - } - } + QBrush brush; - if (!bgImageSet) - { - if (!styleSheet().isEmpty()) - { - setStyleSheet(""); + brush.setTexture(QPixmap(url.path())); + + p.setBrush(QPalette::Base, brush); } - QPalette p; - p.setColor(QPalette::Base, Preferences::self()->color(Preferences::TextViewBackground)); - setPalette(p); } + setPalette(p); } // Data insertion
commit 01e0349a8e6ee2d1ed6bfa81daaaa5ecdb77f7b4 Author: Eike Hein <hein@kde.org> Date: Sat Sep 11 09:06:06 2010 +0200 Rejig ircview background image code. Back to the stylesheet approach, but set it only on the viewport. Plus better sanity checking on the wallpaper path. BUG:224033 diff --git a/ChangeLog b/ChangeLog index dcf085d..82861d4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -184,6 +184,8 @@ Changes since 1.3.1: the connection status tab before the "Looking for server" message if the DNS response was already cached. * Added support for the 475 numeric (ERR_BADCHANNELKEY). +* Rewrote chat text view wallpaper image support to avoid rendering pro- + blems some users were experiencing. Changes from 1.3 to 1.3.1: diff --git a/src/viewer/ircview.cpp b/src/viewer/ircview.cpp index 33bf88b..5928ce6 100644 --- a/src/viewer/ircview.cpp +++ b/src/viewer/ircview.cpp @@ -557,26 +557,27 @@ void IRCView::updateAppearance() setVerticalScrollBarPolicy(Preferences::self()->showIRCViewScrollBar() ? Qt::ScrollBarAlwaysOn : Qt::ScrollBarAlwaysOff); - QPalette p; - - p.setColor(QPalette::Base, Preferences::self()->color(Preferences::TextViewBackground)); - if (Preferences::self()->showBackgroundImage()) { KUrl url = Preferences::self()->backgroundImage(); - if (!url.isEmpty()) + if (url.hasPath()) { - QBrush brush; - - brush.setTexture(QPixmap(url.path())); + viewport()->setStyleSheet("QWidget { background-image: url("+url.path()+"); background-attachment:fixed; }"); - p.setBrush(QPalette::Base, brush); + return; } } + + if (!viewport()->styleSheet().isEmpty()) + viewport()->setStyleSheet(""); + + QPalette p; + p.setColor(QPalette::Base, Preferences::self()->color(Preferences::TextViewBackground)); setPalette(p); } + // Data insertion void IRCView::append(const QString& nick, const QString& message)