SUMMARY Copy and paste do not work from some text editors (e.g: "vim" or "micro") in Konsole to other some applications e.g: kate But copy history can not be saved in System Tray Clipboard too when copying any text in "micro" or "vim" in Konsole. STEPS TO REPRODUCE 1. Switch to Wayland 2. Open some text editors in konsole. e.g. "Vim" or "Micro" 3. Copy any text from "Vim" or "Micro" to some applications e.g. "Kate" OBSERVED RESULT Copy and paste do not work (because of bad communication between Wayland, X11 and Xwayland ? ) EXPECTED RESULT I checked Gnome Wayland that has no issue, but KDE Wayland has this issue. SOFTWARE/OS VERSIONS Operating System: Manjaro Linux KDE Plasma Version: 5.25.5 KDE Frameworks Version: 5.98.0 Qt Version: 5.15.6 Kernel Version: 5.19.9-1-MANJARO (64-bit) Graphics Platform: Wayland
Copy & paste (Shared Clipboard) does not work from KDE Wayland in my host to KDE Wayland in Virtualbox. It does not work from Virtualbox to my host too. But Gnome Wayland has no issue with shared clipboard.
How is X11/XWayland involved here? You didn't force Konsole to run under XWayland, did you? I ask because Konsole and Kate are fully Wayland native so the paste should be going: wayland app <----> wayland compositor <----> wayland app Which is much simpler and less error-prone than when XWayland is involved.
(In reply to Nate Graham from comment #2) > How is X11/XWayland involved here? You didn't force Konsole to run under > XWayland, did you? I ask because Konsole and Kate are fully Wayland native > so the paste should be going: > > wayland app <----> wayland compositor <----> wayland app > > Which is much simpler and less error-prone than when XWayland is involved. Thanks for the reply! I did not force Konsole to run under XWayland. It run under native Wayland for sure without using "QT_QPA_PLATFORM=xcb". I did not mean: Konsole (Wayland) <----> Wayland compositor <----> Kate (Wayland) But I mean: Run "micro" as text editor in Konsole (Wayland) <----> Wayland compositor <----> Kate (Wayland) , that does not work
In the Wayland session, I am experiencing that copying text and links in Firefox Wayland do NOT appear on my Klipper clipboard, however when running Firefox under xwayland, it works like normal and anything I copy appears on my clipboard. Been experiencing this since before 5.25 released, but was unsure whether that was a Firefox bug or not and didn't get around to looking into it. Does that essentially confirm this bug? Leaving it at reported just in case I'm wrong..
Should add that whatever I copy in Firefox stays within Firefox, as if it has its own sandboxed clipboard.
It sounds like your clipboard isn't working at all... are there any apps across which it does work?
(In reply to Nate Graham from comment #6) > are there any apps across which it does work? Yes, seemingly everything, be it XWayland or Wayland native software. Just tested and it works in Konversation, Discord (XWayland), Konsole. Tutanota, Signal and Telegram also all work, those are running as Wayland apps. Oh actually while writing this comment I just noticed, that it works in Firefox Wayland when copying page contents, it's the URL I can't copy, which is odd... Copying any text on this page shows up on my clipboard manager, copying the URL from the URL bar (in Firefox Wayland of course) just doesn't get sent to Klipper.
If you uninstall both xclip and xsel and leave only wl-clipboard installed, does clipboard work in micro?
(In reply to Vlad Zahorodnii from comment #8) > If you uninstall both xclip and xsel and leave only wl-clipboard installed, > does clipboard work in micro? wl-clipboard was already installed. I have no xsel and uninstalled xclip today, then Micro can not be opened after reboot, but it only shows black and blank (No text) in Konsole.
> wl-clipboard was already installed. > I have no xsel and uninstalled xclip today, then Micro can not be opened > after reboot, but it only shows black and blank (No text) in Konsole. Update: Micro appears with text and works fine with wl-clipboard when Klipper (System Tray Clipboard) is not empty! If Klipper (System Tray Clipboard) is EMPTY, then Micro can not be opened.
(In reply to Zesko from comment #1) > Copy & paste (Shared Clipboard) does not work from KDE Wayland in my host to > KDE Wayland in Virtualbox. > It does not work from Virtualbox to my host too. But Gnome Wayland has no > issue with shared clipboard. I noticed that some shared-clipboard works, some shared-clipboard does not work: Shared-clipboard does not work if: - Kate in KDE Wayland in VirtualBox -------> any applications in same KDE Wayland in Host. - Any applications in KDE Wayland in VirtualBox <------- Kate in same KDE Wayland in Host. Shared-clipboard works if: - Copy any URL in Firefox in KDE Wayland in VirtualBox --------> any applications in KDE Wayland in Host, it appears in Klipper too. - Any applications in KDE Wayland in VirtualBox <-------- Copy any URL in Firefox in KDE Wayland in Host.
If you set the clipboard option of micro to "terminal", does it work properly then? It not working through X11 calls is expected as no X11 window is focused. Afaik VirtualBox is still only using X11 in the guest for clipboard integration as well, so it's also expected that it won't work properly - it works with Firefox because that's still running through Xwayland by default, but it won't work with native Wayland apps. Micro hanging while klipper is empty is most likely caused by wl-paste hanging until it can paste something. Other than possibly making Klipper always keep an empty clipboard entry around I don't think we can do anything against that, it's something wl-clipboard needs to handle
I appear to have this issue only with KeePassXC running as wayland native. Relevant bug upstream: https://github.com/keepassxreboot/keepassxc/issues/8492#issuecomment-1265963567 There you can find one workaround that surprisingly works, and probably can give a hint on the origin of the issue. Copy anything from the app itself, and after doing that paste works again. Can anyone reproduce this behavior with other apps?
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/3735
Git commit 46cad20ea861567d325a8f8fee74cd6e42278f61 by Vlad Zahorodnii, on behalf of David Edmundson. Committed on 03/03/2023 at 11:25. Pushed by vladz into branch 'master'. wayland: Cancel selections if set without focus Otherwise we confused clients in the following situation: Client A sets selection, but due to timing has lost focus User copies something in client B Client later tries to paste in client A. Client A still thinks it owns the selection so does nothing. M +10 -2 src/wayland/seat_interface.cpp https://invent.kde.org/plasma/kwin/commit/46cad20ea861567d325a8f8fee74cd6e42278f61
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/3741
Git commit 4bb1000377ca798544727a7fdae68b8cb4d3ff53 by Vlad Zahorodnii, on behalf of David Edmundson. Committed on 03/03/2023 at 17:41. Pushed by vladz into branch 'Plasma/5.27'. wayland: Cancel selections if set without focus Otherwise we confused clients in the following situation: Client A sets selection, but due to timing has lost focus User copies something in client B Client later tries to paste in client A. Client A still thinks it owns the selection so does nothing. (cherry picked from commit 46cad20ea861567d325a8f8fee74cd6e42278f61) M +10 -2 src/wayland/seat_interface.cpp https://invent.kde.org/plasma/kwin/commit/4bb1000377ca798544727a7fdae68b8cb4d3ff53
https://github.com/bugaevc/wl-clipboard/issues/149#issuecomment-1454687844 The issue would be related to Kwin Wayland, which does not work with wl-clipboard together. But Gnome Wayland has no issue with that.
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/4313
Git commit 169257416e5a545349d0a39184d41c9531572b6b by David Edmundson. Committed on 11/08/2023 at 08:47. Pushed by davidedmundson into branch 'master'. wayland: Send data device selections to data control on bind even if null Specification for data control states: "The first selection event is sent upon binding the wlr_data_control_device object." This differs to other data devices. M +2 -6 src/wayland/seat_interface.cpp https://invent.kde.org/plasma/kwin/-/commit/169257416e5a545349d0a39184d41c9531572b6b
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/4318
Git commit e8769ea8aaabe162213f9292ef51aa453f74d1f2 by Vlad Zahorodnii, on behalf of David Edmundson. Committed on 22/08/2023 at 09:27. Pushed by vladz into branch 'Plasma/5.27'. wayland: Send data device selections to data control on bind even if null Specification for data control states: "The first selection event is sent upon binding the wlr_data_control_device object." This differs to other data devices. (cherry picked from commit 169257416e5a545349d0a39184d41c9531572b6b) M +2 -6 src/wayland/seat_interface.cpp https://invent.kde.org/plasma/kwin/-/commit/e8769ea8aaabe162213f9292ef51aa453f74d1f2
I think this is still an issue. I tried copying stuff from konsole to chromium or vivaldi. Both should run in wayland and its not always working. Sometimes I have to multiple times copy from konsole for it to even appear in klipper. Maybe it has something to do with tmux running on the terminal but I use the right click copy function or CTRL+Shift+C which should use Konsole's copy process.
The bug is active for a few years now and never went away! this is the most annoying KDE bug that exists! should be priority number one as copy and paste is trivial for everyday use! I use KDE Neon with Wayland on 2 laptops and both are doing same thing. Hope this will get fixed in 6.0.0!
I narrowed down the issue for me to XWayland clients (apps running in XWayland) suffering from this issue. Restarting XWayland helps there or copying something in a XWayland client to clipboard again to make it able to paste again. For now I fixed my browsers by starting them in Wayland mode (Vivaldi, Chromium & Firefox) and that fixes the issue for me. Maybe others can check if thats the case for them too.
Is that happening in 6.0 as well? Would you mind checking?
(In reply to Nate Graham from comment #26) > Is that happening in 6.0 as well? Would you mind checking? (In reply to Zesko from comment #3) > But I mean: Run "micro" as text editor in Konsole (Wayland) <----> Wayland compositor <----> Kate (Wayland) , that does not work I checked Plasma 6.0.1 on two different devices. I confirmed this fixed the issue. Thank you! However, there is another known issue: Copy text from Kate (Wayland) in Plasma 6.0 in VM (QEMU/KVM) <-----> Kate (Wayland) in Plasma 6.0 in my host. That does not work.
I confirm; but this has been marked as resolved?
(In reply to Lorenzo Bettini from comment #28) > I confirm; but this has been marked as resolved? How to reproduce your issue? I have no problem copying any text from any text editor for example "micro" in Konsole (Wayland) <--------> Kate (Wayland) on the same host except VM. This requires a dependency “wl-clipboard” for that.
(In reply to Zesko from comment #29) > (In reply to Lorenzo Bettini from comment #28) > > I confirm; but this has been marked as resolved? > > How to reproduce your issue? > > I have no problem copying any text from any text editor for example "micro" > in Konsole (Wayland) <--------> Kate (Wayland) on the same host except VM. > This requires a dependency “wl-clipboard” for that. Sorry, I wasn't clear: I cannot copy and paste from host to VM and vice-versa, when the VM is KDE Wayland.
I have the same issue on Fedora 40 and QEMU/KVM-based virtual machines (started with Virt Manager or Gnome Boxes) . (In reply to Lorenzo Bettini from comment #30) > I cannot copy and paste from host to VM and > vice-versa, when the VM is KDE Wayland. Same here. I'm using Fedora 40 and QEMU/KVM-based virtual machines (Virt Manager / Virt Viewer / Gnome Boxes). Can we please re-open this issue? Seems like it's not resolved.
(In reply to Lorenzo Bettini from comment #30) > Sorry, I wasn't clear: I cannot copy and paste from host to VM and (In reply to Yevhen Popok from comment #31) > I have the same issue on Fedora 40 and QEMU/KVM-based virtual machines There are two directional (bidirectional) clipboard share: You need to install "wl-clipboard" * Copy text from Kate (Wayland) on KDE host to Kate (Wayland) on KDE VM, that works! * Copy text from Kate (Wayland) on KDE VM to Kate (Wayland) on KDE host, that does not work. (In reply to Yevhen Popok from comment #31) > Can we please re-open this issue? Seems like it's not resolved. I re-open it.
I have a similar problem. When I open clipboard history, clicking on any entry (away from its buttons) has no effect, but I would expect it to paste. I _think_ I'm using Klipper, and its documentation says ["Previous clipboard entries are shown at the top of the pop-up menu which appears. Selecting one of these copies it to the clipboard, from where it can be pasted into any KDE or X application as usual."](https://help.ubuntu.com/community/Klipper) I have tested this with copying from Chromium and then pasting into it, and also with: VS Code, KSnip annotator, Xournal++, and others. Note that clicking the delete or edit button of an entry does work. Operating System: Kubuntu 22.04 KDE Plasma Version: 5.24.7 KDE Frameworks Version: 5.92.0 Qt Version: 5.15.3 Kernel Version: 6.5.0-28-generic (64-bit) Graphics Platform: X11 Processors: 16 × 13th Gen Intel® Core™ i5-1340P Memory: 15.3 GiB of RAM Graphics Processor: Mesa Intel® Graphics
When running Linux on Macbookpro as VM guest, seemingly only way to get hi dpi resolution (1920x1200) work properly, together with full open-vm-tools functionalty is to run Plasma with Wayland and EnableHiDpi=true. There are other open-vm-tools issues that can be mitigated with manual configuration but this one single bug prevents anyone to use any Linux properly in mac as VM guest. Can i humbly ask priority to this? Imo it would boost KDE (neon) as the goto-distro for macbook owners. -- Jyrki Yli-Nokari
I think this is the issue that I'm currently happening where i copy-paste a piece of text, then try to do it again and instead of pasting the new contents, the old contents will be pasted instead, i have to click on the tray icon, select the latest thing i copied and then paste it again to get content moved/copied. I haven't noticed a pattern between applications.
The original issue opened by Zesko is confirmed as fixed now. I'm going to close this one. Unfortunately lots of people have piled onto this Bugzilla ticket with related-looking clipboard issues. All of those need to be expressed in their own bug reports so they can be tracked and investigated separately. The reason is because every clipboard issue is potentially caused by a different bug. For people still able to experience any clipboard issues in Plasma 6.1.3 or later, please open a new bug report for each individual clipboard issue. Thanks!