From 9cc4568de330e0075c960a5431ecd69a1f9a761d Mon Sep 17 00:00:00 2001 From: Shawn Rutledge Date: Wed, 4 Dec 2019 11:28:24 +0100 Subject: Teach QQuickPixmap to handle requests for image regions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit For vector image formats that could take a long time to render (such as SVG and PDF), we need to be able to request smaller regions of the page. The region needs to be specified in original units (i.e. points in a PDF or pixels in an SVG). Change-Id: I9c9eecb22d929f6e7b2636a2a44f50c8eea4c6b2 Reviewed-by: Jan Arve Sæther --- src/quick/items/qquicktext.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/quick/items/qquicktext.cpp') diff --git a/src/quick/items/qquicktext.cpp b/src/quick/items/qquicktext.cpp index 9493303314..c2980b792d 100644 --- a/src/quick/items/qquicktext.cpp +++ b/src/quick/items/qquicktext.cpp @@ -1212,7 +1212,7 @@ void QQuickTextPrivate::setLineGeometry(QTextLine &line, qreal lineWidth, qreal if (!image->pix) { QUrl url = q->baseUrl().resolved(image->url); - image->pix = new QQuickPixmap(qmlEngine(q), url, image->size); + image->pix = new QQuickPixmap(qmlEngine(q), url, QRect(), image->size); if (image->pix->isLoading()) { image->pix->connectFinished(q, SLOT(imageDownloadFinished())); if (!extra.isAllocated() || !extra->nbActiveDownloads) -- cgit v1.2.3