summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Aardal Hanssen <andreas.aardal.hanssen@nokia.com>2009-04-21 14:05:42 (GMT)
committerAndreas Aardal Hanssen <andreas.aardal.hanssen@nokia.com>2009-04-21 14:05:42 (GMT)
commit183cb6052c45d7c83e36c78da4e2c59c768209c7 (patch)
tree2fbcbe20239179fd29b79724d7c3be97c6c06011
parent08feb22f9a924ce120da8b5c6e1669d2a630dd54 (diff)
downloadQt-183cb6052c45d7c83e36c78da4e2c59c768209c7.zip
Qt-183cb6052c45d7c83e36c78da4e2c59c768209c7.tar.gz
Qt-183cb6052c45d7c83e36c78da4e2c59c768209c7.tar.bz2
BT: Revert "Fixes: Don't fill the pixmap because we will copy the cache into it."
This reverts commit 0985805ab3c7de5b15c115a98afb15944b6d93b9. The Elastic Nodes example shows a black background for the cache pixmap if the call to fill isn't there. Alexis and I both agree that it makes no sense that we fill the pixmap with transparent pixels instead of just drawing with QPainter::CompositionMode_Source, but since this regression was introduced after 4.5.0 was released we must revert before we investigate further. Reviewed-by: Alexis
-rw-r--r--src/gui/graphicsview/qgraphicsscene.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gui/graphicsview/qgraphicsscene.cpp b/src/gui/graphicsview/qgraphicsscene.cpp
index b75c422..13f70e5 100644
--- a/src/gui/graphicsview/qgraphicsscene.cpp
+++ b/src/gui/graphicsview/qgraphicsscene.cpp
@@ -4890,9 +4890,11 @@ void QGraphicsScenePrivate::drawItemHelper(QGraphicsItem *item, QPainter *painte
if (newCacheIndent != deviceData->cacheIndent || deviceRect.size() != pix.size()) {
QPoint diff = newCacheIndent - deviceData->cacheIndent;
QPixmap newPix(deviceRect.size());
+ // ### Investigate removing this fill (test with Plasma and
+ // graphicssystem raster).
+ newPix.fill(Qt::transparent);
if (!pix.isNull()) {
QPainter newPixPainter(&newPix);
- newPixPainter.setCompositionMode(QPainter::CompositionMode_Source);
newPixPainter.drawPixmap(-diff, pix);
newPixPainter.end();
}