path: root/src/gui/painting/qplatformbackingstore.h
diff options
authorJocelyn Turcotte <>2014-03-28 15:40:28 +0100
committerThe Qt Project <>2014-04-03 11:07:07 +0200
commit4bbf313e9d3cab70c6dab6da4c03bf2ad60aa760 (patch)
treeda7d22709196427b4ecdb80b42e7a1f28cdef425 /src/gui/painting/qplatformbackingstore.h
parentafacf694d5a6f34b88989e76971d70d700ce4949 (diff)
Fix UI squishing when using QWidget::setRenderToTexture
When resizing a window, a window might not be resized synchronously with its backing store. We need to use the actual texture size as the transform to avoid stretching the rendered texture. Change-Id: I945f6d190577ccdcb54483a267a1e42df1ca3156 Reviewed-by: Paul Olav Tvete <> Reviewed-by: Laszlo Agocs <>
Diffstat (limited to 'src/gui/painting/qplatformbackingstore.h')
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/painting/qplatformbackingstore.h b/src/gui/painting/qplatformbackingstore.h
index 76fd3d40b4..4728622cac 100644
--- a/src/gui/painting/qplatformbackingstore.h
+++ b/src/gui/painting/qplatformbackingstore.h
@@ -111,7 +111,7 @@ public:
#ifndef QT_NO_OPENGL
virtual void composeAndFlush(QWindow *window, const QRegion &region, const QPoint &offset, QPlatformTextureList *textures, QOpenGLContext *context);
virtual QImage toImage() const;
- virtual GLuint toTexture(const QRegion &dirtyRegion) const;
+ virtual GLuint toTexture(const QRegion &dirtyRegion, QSize *textureSize) const;
virtual void resize(const QSize &size, const QRegion &staticContents) = 0;