Details
-
Bug
-
Resolution: Won't Do
-
P2: Important
-
4.6.3, 5.3.0, 5.3.1
-
Windows 7 Enterprise, 32bit, English
-
9150563940f61be9fb17510be49c0734244866a5 (dev, 4.7.2014)
Description
Steps:
1. Create a QImage object with transparency.
2. QClipboard::setImage to set clipboard, save teh QImage to a PNG file also.
3. Paste the clibpard to word or other applications.
Note: the transparent pixels were filed with black.
This looks like a regression on 4.6.3. (I didn't find it on 4.6.2)
Please use the code below to recreate this defect:
#include <QtCore> #include <QApplication> #include <QClipboard> #include <QPainter> #include <QImage> int main(int argc, char **argv) { QApplication app(argc, argv); QImage img( 100, 100, QImage::Format_ARGB32_Premultiplied ); img.fill( QColor(Qt::transparent).rgba() ); { QPainter painter( &img ); painter.setBrush( Qt::blue ); painter.drawPie( 20, 20, 50, 50, 45 * 16, 135 * 16 ); } QApplication::clipboard()->setImage( img ); img.save( "C:/test.png" ); return 0; }
Attachments
Issue Links
- relates to
-
QTBUG-57410 Copying image to clipboard removes alpha channel
- Closed
-
QTBUG-64322 [Windows] Cannot drag and drop PNG images to PowerPoint
- Closed
-
QTBUG-45265 Windows: Copying QImage of QImage::Format_ARGB32 into QClipboard results in corrupted image
- Closed
- resulted in
-
QTBUG-47656 [Reg 5.3->5.4] QClipboard fails to create DIB from image with transparency
- Closed