Created attachment 136054 [details] Notification center inform picture as in clipboard SUMMARY Despite the configuration, the image is not always copied to the clipboard. STEPS TO REPRODUCE 1. Configure spectacle to copy image in clipboard 2. Take screenshot as rectangular selection 3. Try to paste into libreoffice writer or discord, nothing happens OBSERVED RESULT Spectable notify (by the notification center) a screenshot as copied in clipboard. The application see the message but I can't paste thye picture. EXPECTED RESULT Picture in clipboard and possibility to past anywhere SOFTWARE/OS VERSIONS Linux/KDE Plasma: Neon (available in About System) KDE Plasma Version: 5.21.0 KDE Frameworks Version: 5.79.0 Qt Version: 5.15.2 ADDITIONAL INFORMATION I have to go through the clipboard manager 8 times out of 10 to be able to paste the image where I want it. Otherwise, nothing happens. I have not found what is the element that disturbs the operation.
How exactly are you triggering the screenshot? From the app, via shortcut, from the command line?
(In reply to Nicolas Fella from comment #1) > How exactly are you triggering the screenshot? From the app, via shortcut, > from the command line? I use meta key + shift + print screen to start capturing zone.
Hmm, that seems to work fine for me. What I do notice is when I run "spectacle -b" the image does not get copied to the clipboard, but the path to the saved image does.
If there was an option to have a debug log (without having the application running before using the shortcut keys), I think I could provide more information. For information, I do not encounter this bug with the ksnip application
I have an idea, could it come from the ignore images option in the KDE Clipboard Manager?
> If there was an option to have a debug log (without having the application running before using the shortcut keys), I think I could provide more information. You can use "spectacle -s" on the command line and then launch it via shortcut > I have an idea, could it come from the ignore images option in the KDE Clipboard Manager? It works for me even with that option
> You can use "spectacle -s" on the command line and then launch it via shortcut I started Spectacle with the -s option. Where are the dbus logs generated by this option? Because just after launching spectacle -s in a console (alway opened), I captured an area and couldn't paste anything into LibreOffice Writer.
I can confirm this happens for me as well. All signs point to this commit being the culprit: https://github.com/KDE/spectacle/commit/a232723b35a1c2c2d8f27f6bf4a59f2ff3775863 Commit Msg: > This fixes the bug that keeps Spectacle running, happens when it's launched via either spectacle --region --background or Meta + Shift + Prt.sc. It seems like Spectacle isn't working as expected here. Previously the region screenshot -> clipboard via shortcut action worked, but that actually seems like a bug. In other words, Spectacle was able to copy to the clipboard because it was still running in the background. As of v20.12.2-2, if I have Spectacle open and do a rectangular region capture with the Copy to Clipboard option enabled, the image is copied to the clipboard, as expected. Essentially, it as if Spectacle is closing before it can copy the image to the clipboard when running in background mode, due to the "bugfix" mentioned above.
(In reply to lvxejay from comment #8) > I can confirm this happens for me as well. All signs point to this commit > being the culprit: > > https://github.com/KDE/spectacle/commit/ > a232723b35a1c2c2d8f27f6bf4a59f2ff3775863 > > Commit Msg: > > This fixes the bug that keeps Spectacle running, happens when it's launched via either spectacle --region --background or Meta + Shift + Prt.sc. > > It seems like Spectacle isn't working as expected here. Previously the > region screenshot -> clipboard via shortcut action worked, but that actually > seems like a bug. In other words, Spectacle was able to copy to the > clipboard because it was still running in the background. > > As of v20.12.2-2, if I have Spectacle open and do a rectangular region > capture with the Copy to Clipboard option enabled, the image is copied to > the clipboard, as expected. Essentially, it as if Spectacle is closing > before it can copy the image to the clipboard when running in background > mode, due to the "bugfix" mentioned above. That's my commit, and I just tried with the latest spectacle version build off from the git master branch (21.03.70). Works now. With the current version (20.12.3 , arch repo), I can confirm the bug. Must be something in between that fixed it?
I updated to 21.03.80-1 kde-unstable repo and the bug persists.
(In reply to lvxejay from comment #10) > I updated to 21.03.80-1 kde-unstable repo and the bug persists. Version 21.07.70, latest git build Works with "meta key + shift + print screen"
This is still broken, even with Meta-Shift-Print on the latest version in the Arch stable repos.
The ability to capture a rectangular screenshot and copy it to the clipboard without having to open the application is core functionality and convenience for this application. It is the only reason I use Spectacle. Please fix this. Again, it seems to me like the fact that it was ever working at all was a bug disguised as feature that was "fixed", revealing the fact that there is actually a bug here. Spectacle does not stay running long enough to copy the screenshot to the clipboard. In other words, before this commit, Spectacle was staying "open" (unintentionally) in the background long enough to capture a screenshot and copy it to the clipboard: https://github.com/KDE/spectacle/commit/a232723b35a1c2c2d8f27f6bf4a59f2ff3775863 Subsequently, after this commit was added, Spectacle copy-to-clipboard no longer works.
I'm going to mark this as resolved, tentatively. I had a 2-years-old custom shortcut in place that served as a workaround when the Copy to Clipboard feature wasn't working. I disabled the custom shortcut command and now copy to clipboard works. However, it should be noted that prior to commit I mentioned, even with my custom shortcut in place, copy to clipboard was working. The shortcut: /usr/bin/xclip -selection clipboard -target image/png -i $(ls -1tr /home/$USER/pictures/screenshots/Screenshot_*.png | tail -n 1)
Re-opening. I had the Spectacle window Open while taking the screenshot after I had disabled my custom shortcut. It worked. Then I tried again, without my custom shortcut command, and with the Spectacle window closed. Now it does not work. Can definitely confirm this is still not working as intended.
(In reply to lvxejay from comment #15) > Re-opening. I had the Spectacle window Open while taking the screenshot > after I had disabled my custom shortcut. It worked. > > Then I tried again, without my custom shortcut command, and with the > Spectacle window closed. Now it does not work. Can definitely confirm this > is still not working as intended. What custom keyboard shortcut do you have set and is it set via Spectacle or KDE's System Settings Shortcuts?
i cant get copy to clipboard to work via shortcut or pressing the copy to clipboard button in spectacle: Operating System: KDE neon 5.22 KDE Plasma Version: 5.22.0 KDE Frameworks Version: 5.83.0 Qt Version: 5.15.3 Kernel Version: 5.8.0-55-generic (64-bit) Graphics Platform: Wayland Processors: 4 × Intel® Core™ i7-5600U CPU @ 2.60GHz Memory: 7.7 GiB of RAM Graphics Processor: Mesa Intel® HD Graphics 5500
Does not work for me. Notifications stopped to popup also. Image just is not copied to clipboard. File is created though. spectacle 21.08.1 Operating System: Kubuntu 21.10 KDE Plasma Version: 5.22.5 KDE Frameworks Version: 5.86.0 Qt Version: 5.15.2 Kernel Version: 5.13.0-27-generic (64-bit) Graphics Platform: X11 Processors: 12 × Intel® Xeon® W-11855M CPU @ 3.20GHz Memory: 62,6 GiB of RAM Graphics Processor: NVIDIA RTX A2000 Laptop GPU/PCIe/SSE2
Created attachment 145703 [details] clipboar_settings Do you have these settings in clipboard?
Thanks for quick response. What do you mean saying "clipboar_settings"?
Adding more details: Copying to clipboard works if spectacle GUI is open. If it is closed and region mode is launched via shortcut - it does not work. Notification does not appear either. When GUI closed, after screenshot is made I feel 1-2s freeze (not able to switch to other apps), image is saved as a file, but not copied to clipboard
I found what setting caused copying to stop working: I disabled "Show notification in popup" option in Spectacle notifications setting. Reason behind it was not to show notifications. Therefore I figured out that we still can have "Show notification in popup" enabled but "Show popups" disabled - this combination will not show popups and still keep copying to clipboard working.
(In reply to Alexander Radzishevsky from comment #20) > Thanks for quick response. > What do you mean saying "clipboar_settings"? Klipper's configuration. Can you check that please? did some of you try with the latest 22.04.02? Still works fine for me , tho it autosaves the pic to the default folder even tho it's not configured to do so, but that bugfix is already on it's way.
This seems to be fixed.