Bug 494904

Summary: Dragging selected text while Ctrl key is down doesn't copy the text
Product: [Applications] kate Reporter: Tom Duhamel <tom420.duhamel>
Component: applicationAssignee: KWrite Developers <kwrite-bugs-null>
Status: RESOLVED WORKSFORME    
Severity: minor CC: christoph, waqar.17a
Priority: NOR    
Version First Reported In: 24.08.2   
Target Milestone: ---   
Platform: Fedora RPMs   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Tom Duhamel 2024-10-17 03:08:18 UTC
SUMMARY

Pressing Ctrl key after starting dragging selected text does not cause the text to be copied as intended, even if the small "+" icon is overlayed to cause that expectation.

STEPS TO REPRODUCE
1. Select some text
2. Start dragging the selected text
3. Press down Ctrl key; a small icon appears over the mouse pointer
4. Release the selected text into new position while still holding the Ctrl key down

OBSERVED RESULT

The text is moved into the new position

EXPECTED RESULT

It should be a copy, and therefore the original text is expected to remain into its original position.

SOFTWARE/OS VERSIONS

Linux/KDE Plasma:  Fedora 41/KDE 6.2.0
KDE Plasma Version: 6.2.0
KDE Frameworks Version: 6.7.0
Qt Version: 6.7.2

ADDITIONAL INFORMATION

This works just fine when holding the Ctrl key down before starting the drag operation, though the mouse pointer confusingly becomes invisible temporarily.

The same behaviour is observed when holding down the Shift key while dragging selected text into a different panel. In that case, you would expect the text to be moved (the "+" icon disappears to indicate this expected behaviour), however the original text is not removed.
Comment 1 Christoph Cullmann 2024-10-19 18:35:01 UTC
Mmm, works for me with current master and Qt 6.8 both on X11 and Wayland.
Comment 2 Waqar Ahmed 2024-10-19 21:35:19 UTC
works for me as well
Comment 3 Christoph Cullmann 2024-10-20 17:45:05 UTC
I think this is an issue with the some other parts of the stack. I would hope some other updates will fix that for you.