From fab3611a210fc8467fee5b958e56eb70226b91b2 Mon Sep 17 00:00:00 2001 From: Thomas Georgiou Date: Sun, 7 Oct 2007 23:32:56 +0000 Subject: [PATCH] Transparency works now!! Aaron, remember to fill QPixmaps with Qt::transparent. svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=722710 --- widgets/widget.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/widgets/widget.cpp b/widgets/widget.cpp index b0a408515..6f33a2472 100644 --- a/widgets/widget.cpp +++ b/widgets/widget.cpp @@ -325,6 +325,7 @@ void Widget::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QW // Recreate the pixmap if it's gone. if (pix.isNull()) { pix = QPixmap(d->cacheSize); + pix.fill(Qt::transparent); exposed = brect; } @@ -372,6 +373,7 @@ void Widget::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QW // Auto-adjust the pixmap size. if (deviceRect.size() != pix.size()) { pix = QPixmap(deviceRect.size()); + pix.fill(Qt::transparent); exposed = brect; }