From 991b817e7521d56862f42aad78568368e16f0f48 Mon Sep 17 00:00:00 2001 From: Gunnar Sletta Date: Mon, 27 May 2013 13:56:59 +0200 Subject: Avoid double-highdpi scaling for attached painters. updateMatrix will us both redirection matrix and highdpi scale matrix, so make sure we don't multiply it in twice. Change-Id: I7394e504746a8de54b4dc79492264deba320538f Reviewed-by: Richard Moe Gustavsen --- src/gui/painting/qpainter.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/gui/painting/qpainter.cpp b/src/gui/painting/qpainter.cpp index d950c4e45f..cfb9d71f5c 100644 --- a/src/gui/painting/qpainter.cpp +++ b/src/gui/painting/qpainter.cpp @@ -293,6 +293,7 @@ bool QPainterPrivate::attachPainterPrivate(QPainter *q, QPaintDevice *pdev) // Update matrix. if (q->d_ptr->state->WxF) { q->d_ptr->state->redirectionMatrix = q->d_ptr->state->matrix; + q->d_ptr->state->redirectionMatrix *= q->d_ptr->hidpiScaleTransform().inverted(); q->d_ptr->state->redirectionMatrix.translate(-offset.x(), -offset.y()); q->d_ptr->state->worldMatrix = QTransform(); q->d_ptr->state->WxF = false; -- cgit v1.2.3