From 498c0fc0e077290c0dcf5aef26a5b4d4ea875cfc Mon Sep 17 00:00:00 2001 From: Albert Astals Cid Date: Sat, 6 Oct 2007 23:04:28 +0000 Subject: [PATCH] QPixmap::toImage does not always give us QImage::Format_ARGB32_Premultiplied so enforce it svn path=/trunk/KDE/kdegraphics/okular/; revision=722225 --- ui/pagepainter.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/ui/pagepainter.cpp b/ui/pagepainter.cpp index 27d4fcc5f..75794c1b0 100644 --- a/ui/pagepainter.cpp +++ b/ui/pagepainter.cpp @@ -662,6 +662,7 @@ void PagePainter::cropPixmapOnImage( QImage & dest, const QPixmap * src, const Q if ( r == QRect( 0, 0, src->width(), src->height() ) ) { dest = src->toImage(); + dest = dest.convertToFormat(QImage::Format_ARGB32_Premultiplied); } // else copy a portion of the src to an internal pixmap (smaller) and convert it else