Bug 435829

Summary: Selection paste seems broken
Product: [I don't know] kde Reporter: Anton Karmanov <bergentroll>
Component: generalAssignee: Unassigned bugs <unassigned-bugs-null>
Status: RESOLVED WORKSFORME    
Severity: normal CC: nate
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Anton Karmanov 2021-04-16 19:05:21 UTC
SUMMARY
I am not sure which component is involved.

Selection paste works fine with middle mouse button. It works in Konsole and Yaquake with default C+S+Insert shortcut. In majority of applications it seems inconsistent. Paste selection shortcut inserts something different than middle mouse button and different to other applications' windows (sometimes it pastes nothing). It is so also with disabled selection buffer at the Klipper's settings.

STEPS TO REPRODUCE
1. Map some shortcut at System Settings -> Shortcuts -> Edit -> Paste Selection (or just keep the default, I'd prefer the Ctrl+Insert).
2. Some app window, e. g. Firfox or LibreOffice.
3. Select some text with mouse.
4. Paste the buffer in some text field with middle mouse button.
5. Paste the buffer in some text field with "Paste Selection" shortcut.
6. Try to past in other application window.

OBSERVED RESULT
Paste actions produce different text.

EXPECTED RESULT
Paste actions produce the same string before the next selection (because there is should be one selection buffer).

SOFTWARE/OS VERSIONS
GNU Linux/KDE Plasma:
Archlinux with Xorg 
KDE Plasma Version: 5.21.4
KDE Frameworks Version: 5.81.0
Qt Version: 5.15.2
Comment 1 Nate Graham 2021-04-21 18:16:04 UTC
When you select text with the mouse, it isn't actually officially placed in the clipboard; it goes in a special area where it can only be pasted using a middle-click. If you want mouse-selected text to be paste-able using the other paste actions, you will need to go to the system tray's clipboard applet > configure > check "Synchronize contents of clipboard and the selection". Then it should work how you want.