Refix printing of dpr>1 images on Windows
This modifies 9e453dacc3
to make sure
that QPainter uses the adjusted DPR when doing the tile copying.
Fixes: QTBUG-99990
Pick-to: 6.5 6.2
Change-Id: Id9c7b5576d5036e20bb399f3c8b82d4a467dc70f
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
This commit is contained in:
parent
f19147d164
commit
daa77824b3
@ -561,9 +561,9 @@ void QWin32PrintEngine::drawPixmap(const QRectF &targetRect,
|
||||
|
||||
|
||||
QImage img(QSize(imgw, imgh), QImage::Format_RGB32);
|
||||
img.setDevicePixelRatio(pixmap.devicePixelRatio());
|
||||
img.fill(Qt::white);
|
||||
QPainter painter(&img);
|
||||
img.setDevicePixelRatio(pixmap.devicePixelRatio());
|
||||
painter.drawPixmap(0,0, pixmap, tileSize * x, tileSize * y, imgw, imgh);
|
||||
QPixmap p = QPixmap::fromImage(img);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user