Bug 506467 - Screenshots from fullscreen Wayland apps are not copied to clipboard (Spectacle)
Summary: Screenshots from fullscreen Wayland apps are not copied to clipboard (Spectacle)
Status: RESOLVED FIXED
Alias: None
Product: Spectacle
Classification: Applications
Component: General (other bugs)
Version First Reported In: 6.4.1
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Noah Davis
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-07-02 04:15 UTC by Egor Tkachev
Modified: 2025-12-15 10:20 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In: 6.22
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Egor Tkachev 2025-07-02 04:15:08 UTC
When taking a screenshot using Spectacle in a fullscreen Wayland application (e.g. Chrome in F11 mode or a game running via Wine + Wayland), the screenshot is not copied to the clipboard — pasting via Ctrl+V does nothing. However, the image does appear in the clipboard history, but clicking on it still doesn't allow it to be pasted. A workaround is to click on any other item in the clipboard history first, and then click back on the screenshot — after that, Ctrl+V works as expected.

I'm not sure whether this is a bug in Spectacle or in the KDE clipboard manager.

Expected behavior:
The screenshot should be immediately available for pasting via Ctrl+V after being taken, which not works when screenshot is taken from fullscreen wayland app

System Information:
Operating System: CachyOS Linux
KDE Plasma Version: 6.4.1
KDE Frameworks Version: 6.15.0
Qt Version: 6.9.1
Kernel Version: 6.15.4-4-cachyos (64-bit)
Graphics Platform: Wayland
Processors: 16 × Intel® Core™ i7-10700K CPU @ 3.80GHz
Memory: 32 GiB RAM (27.4 GiB usable)
Graphics Processor: NVIDIA GeForce RTX 3060 Ti
Manufacturer: Gigabyte Technology Co., Ltd.
Product Name: Z490 UD
Comment 1 Juts 2025-07-03 07:34:54 UTC
I have the exact same issue. It is inconsistent as well. I feel like if you are fast (like within 1 second) its in the clipboard and you can paste it. Then something clears it out. 

Same behavior between both flameshot and spectacle. The images show in the clipboard manager and I can toggle between the previous and latest to restore it to the clipboard and then paste it. 


Operating System: CachyOS Linux 
KDE Plasma Version: 6.4.2
KDE Frameworks Version: 6.15.0
Qt Version: 6.9.1
Kernel Version: 6.15.4-4-cachyos (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 9800X3D 8-Core Processor
Memory: 64 GiB of RAM (62.4 GiB usable)
Graphics Processor: NVIDIA GeForce RTX 5090
Manufacturer: ASRock
Product Name: X870E Taichi Lite
Comment 2 pcmaniaks_spam 2025-07-07 09:17:14 UTC
I can also confirm that this bug also happens on my machine when playing games - any screenshots (either rectangular snips or full) taken ingame can't be pasted anywhere (about 9 out of 10 times - sometimes it works). To elaborate on the previous comments, I think that it only affects games running in borderless windowed mode (or forced to fullscreen via taskbar menu). Whenever I run a game in "true" fullscreen (or in a window), the screenshots seem to work fine, ie. they can be pasted normally.

OS: Manjaro (Wayland)
KDE Plasma Version: 6.3.5
KDE Frameworks Version: 6.15.0
Qt Version: 6.9.1
Kernel Version: 6.13.12-2 (64-bit)
Comment 3 physphase 2025-07-09 11:10:30 UTC
I have the same issue, when I look in my clipboard contents, it shows up as an empty bar or empty image. I can paste the failed screenshot  into obsidian, it recognizes it as an image but shows 'broken image' pictogram. Opening the spectacle application instead of using the screenshot button sometimes works; other times I'd have to click "new image" after opening the program and then it would work.
Comment 4 physphase 2025-07-09 11:12:43 UTC
(In reply to physphase from comment #3)
> I have the same issue, when I look in my clipboard contents, it shows up as
> an empty bar or empty image. I can paste the failed screenshot  into
> obsidian, it recognizes it as an image but shows 'broken image' pictogram.
> Opening the spectacle application instead of using the screenshot button
> sometimes works; other times I'd have to click "new image" after opening the
> program and then it would work.

Excuse me, new here and forgot to add distro etc.
OS: Arch Linux x86_64 
Host: 750XFG P07CFL 
Kernel: 6.12.36-1-lts 
Resolution: 1920x1080 
DE: Plasma 6.4.2 
WM: kwin 
Theme: Breeze-Dark [GTK2], Breeze [GTK3] 
Icons: breeze-dark [GTK2/3] 
CPU: 13th Gen Intel i5-1335U (12) @ 4.600GHz 
GPU: Intel Raptor Lake-P [Iris Xe Graphics] 
Memory: 6009MiB / 15671MiB
Comment 5 Bug Janitor Service 2025-09-06 14:02:09 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kguiaddons/-/merge_requests/182
Comment 6 Bug Janitor Service 2025-12-11 10:42:44 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kguiaddons/-/merge_requests/191
Comment 7 David Edmundson 2025-12-15 10:20:42 UTC
Git commit b71af4e1afcf72b8c9da315dc8d728db70d753c0 by David Edmundson, on behalf of David Redondo.
Committed on 15/12/2025 at 10:16.
Pushed by davidedmundson into branch 'master'.

ksystemclipboard: Dispatch read events in another thread

WaylandClipboard wraps ext_data_control if an application tried to read
the clipboard using QClipboard whilst it owns the data control we would
deadlock.

This was previously being solved by trying to transfer mimedata to the
regular clipboard upon gaining focus. However this never worked
reliably and efforts to fix this only made it more complicated.

To solve the original deadlock all ext_data_control classes now live on
another thread which dispatches events on a separate queue. A recursive
mutex allows the main thread to read mimedata and no wayland events
which change the mimedata process until this is complete.
Related: bug 480448, bug 496029, bug 502831, bug 505281, bug 507792, bug 509065, bug 509689, bug 511736
FIXED-IN: 6.22

M  +116  -14   src/systemclipboard/waylandclipboard.cpp
M  +3    -0    src/systemclipboard/waylandclipboard_p.h

https://invent.kde.org/frameworks/kguiaddons/-/commit/b71af4e1afcf72b8c9da315dc8d728db70d753c0