Bug 474644

Summary: Dolphin's hold-click-drag to select performance is very poor
Product: [Applications] dolphin Reporter: miranda
Component: generalAssignee: Dolphin Bug Assignee <dolphin-bugs-null>
Status: REPORTED ---    
Severity: normal CC: kfm-devel, miranda
Priority: NOR    
Version First Reported In: 23.08.1   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description miranda 2023-09-18 04:55:48 UTC
SUMMARY
Dolphin uses an extraordinary amount of CPU for the selection rectangle. This dramatically worsens as resolution increases. As a result, it feels quite choppy. It's especially noticeable on high refresh monitors. I'm guessing something accidentally hit O(n^2) instead of O(n).

STEPS TO REPRODUCE
1. Open Dolphin, maximized. On a high res screen if possible, or alternatively at low display scale factors
2. Watch CPU usage for Dolphin, in my case I just ran htop --pid=$(pgrep dolphin) --delay=1
3. Click and drag anywhere in the window (and not by scrolling, but by moving the mouse cursor)

OBSERVED RESULT
Dolphin's CPU usage spikes to the point it maxes out a core and the effect feels really choppy

EXPECTED RESULT
Select dragging is performant, not choppy, and doesn't max out a core

SOFTWARE/OS VERSIONS
Linux Version: 6.5.3-arch1-1
KDE Plasma Version: 5.27.8
KDE Frameworks Version: 5.110.0
Qt Version: 5.15.10
KWin Backend: Wayland
Mesa 23.1.7 (AMD RX 6600 XT)

ADDITIONAL INFORMATION
Note this is NOT to do with selecting files/folders and moving them. This is only as you CREATE the selection box.