From f0f632c7c1043f9c8097b4677f0a9eae01f916d2 Mon Sep 17 00:00:00 2001 From: David Edmundson Date: Sun, 11 Mar 2018 23:15:38 +0000 Subject: Fix non-integer scale factors with Text native rendering MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Task-number: QTBUG-67007 Change-Id: Id32cc14ea1bc258cfc139a859ccae014f5893563 Reviewed-by: Morten Johan Sørvig --- src/quick/scenegraph/qsgdefaultglyphnode_p.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/quick/scenegraph/qsgdefaultglyphnode_p.cpp') diff --git a/src/quick/scenegraph/qsgdefaultglyphnode_p.cpp b/src/quick/scenegraph/qsgdefaultglyphnode_p.cpp index dc473a6640..ce706d76f7 100644 --- a/src/quick/scenegraph/qsgdefaultglyphnode_p.cpp +++ b/src/quick/scenegraph/qsgdefaultglyphnode_p.cpp @@ -71,9 +71,9 @@ static inline QVector4D qsg_premultiply(const QVector4D &c, float globalOpacity) return QVector4D(c.x() * o, c.y() * o, c.z() * o, o); } -static inline int qsg_device_pixel_ratio(QOpenGLContext *ctx) +static inline qreal qsg_device_pixel_ratio(QOpenGLContext *ctx) { - int devicePixelRatio = 1; + qreal devicePixelRatio = 1; if (ctx->surface()->surfaceClass() == QSurface::Window) { QWindow *w = static_cast(ctx->surface()); if (QQuickWindow *qw = qobject_cast(w)) -- cgit v1.2.3