[frameworks/ktexteditor] src/view: Drag pixmap: use devicePixelRatio of highest screen device pixel ratio

Friedrich W. H. Kossebau <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 58ed288373cd62bef0476a9cd92be31b0a83b330 by Friedrich W. H. Kossebau.
Committed on 27/07/2026 at 12:54.
Pushed by kossebau into branch 'master'.

Drag pixmap: use devicePixelRatio of highest screen device pixel ratio

M  +2    -1    src/view/kateviewinternal.cpp

https://invent.kde.org/frameworks/ktexteditor/-/commit/58ed288373cd62bef0476a9cd92be31b0a83b330

diff --git a/src/view/kateviewinternal.cpp b/src/view/kateviewinternal.cpp
index f5120b453..b3f7ec226 100644
--- a/src/view/kateviewinternal.cpp
+++ b/src/view/kateviewinternal.cpp
@@ -4141,7 +4141,8 @@ void KateViewInternal::doDrag()
     }
 
     // Create a pixmap this selection and set it, if not null
-    const qreal dpr = devicePixelRatioF();
+    // Use highest screen device pixel ratio as drag could be moved to any screen
+    const qreal dpr = qApp->devicePixelRatio();
     if (QPixmap pixmap(w * dpr, h * dpr); !pixmap.isNull()) {
         pixmap.setDevicePixelRatio(dpr);
         pixmap.fill(Qt::transparent);
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.