Bug 391183

Summary: When Spectacle is invoked from its pinned Task Manager icon's context menu and the Fade effect is active, a half-faded version of the context menu appears in the screenshot
Product: [Applications] Spectacle Reporter: drokergeek
Component: GeneralAssignee: Boudhayan Gupta <me>
Status: RESOLVED DUPLICATE    
Severity: normal CC: bugseforuns, nate, null, scott
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: video description
showing my current desktop theme

Description drokergeek 2018-02-27 19:50:24 UTC
Created attachment 111063 [details]
video description

When I use the context menu in a launcher of spectacle in the taskbar to make a screenshot, after clicking the proper menu button the menu starts to dim out but the screenshot is taken before the menu dims completely, appearing an almost transparent context menu in the screenshot and also the spectacle menu that jumps when a program is launched and is loading
Comment 1 Nate Graham 2018-02-28 18:55:51 UTC
Interesting bug, and thanks for the screen recording, that helped me try to reproduce it.

I'm unable to reproduce with eithe a pinned Task Manager launcher or a Panel launcher using Plasma 5.12.2 and Spectacle 17.12.2 . What versions are you using?
Comment 2 drokergeek 2018-02-28 18:58:38 UTC
(In reply to Nate Graham from comment #1)
> Interesting bug, and thanks for the screen recording, that helped me try to
> reproduce it.
> 
> I'm unable to reproduce with eithe a pinned Task Manager launcher or a Panel
> launcher using Plasma 5.12.2 and Spectacle 17.12.2 . What versions are you
> using?

Thats interesting because it has always happened to me since when i started using kde months ago as i remember
Im using archlinux with the latest kde, 5.12.2
Comment 3 Nate Graham 2018-03-02 03:50:59 UTC
Are you using a 3rd-party theme? It looks like your context menu fades out over a period of time that isn't long enough to fully disappear before Spectacle captures the screenshot. Does this reproduce for you when using Breeze?
Comment 4 drokergeek 2018-03-02 07:45:41 UTC
(In reply to Nate Graham from comment #3)
> Are you using a 3rd-party theme? It looks like your context menu fades out
> over a period of time that isn't long enough to fully disappear before
> Spectacle captures the screenshot. Does this reproduce for you when using
> Breeze?

Im only using arc dark as desktop theme, im uploading a new vid
Comment 5 drokergeek 2018-03-02 07:47:35 UTC
Created attachment 111127 [details]
showing my current desktop theme
Comment 6 Nate Graham 2018-03-02 19:37:04 UTC
Ah, it's the Fade KWin effect, which is independent of your theme.

So the bug here is that with Fade effect on, and Spectacle invoked from its pinned task manager icon's context menu, the menu doesn't fully disappear before Spectacle takes the screenshot.
Comment 7 drokergeek 2018-03-02 19:40:58 UTC
(In reply to Nate Graham from comment #6)
> Ah, it's the Fade KWin effect, which is independent of your theme.
> 
> So the bug here is that with Fade effect on, and Spectacle invoked from its
> pinned task manager icon's context menu, the menu doesn't fully disappear
> before Spectacle takes the screenshot.

I can confirm disabling the fade effect no longer appears in the screenshot the menu but it still appears the jumping icon, so it is another thing to consider
Comment 8 Scott Harvey 2018-03-19 11:56:07 UTC
There's already code in Spectacle to add a slight delay (200msec) when compositing is enabled, allowing enough time for the window to hide itself. I'm not sure how we could increase this accurately to account for various KWin effects. I get a similar "ghost" effect when launching Spectacle and using KWin's "Glide" effect. Since KWin behavior scripts can be written by anyone and freely shared, there's an infinite number of potential delays and transition effects possible.

As for the bouncing icon, that's part of Plasma's "Application Launch Feedback" effects. I believe it bounces until the application window appears.

(I attempted to turn this off as well, but there appears to be a bug where the setting does not save. I filed that as Bug 392050.)

I don't know how this could be handled effectively. We shouldn't expect users to disable all their graphical effects to take effective screenshots, but I can't see how we'd enable a large enough delay without affecting Spectacle's (perceived) performance.
Comment 9 null 2018-03-19 16:39:45 UTC
Ideally there would be a way to get a signal from KWin once all animations finished. We really should not add even more timeout hacks.
Comment 10 Scott Harvey 2018-03-19 16:54:57 UTC
No more timing hacks! Couldn't agree more. I've already been the victim of at least one.

KWin strikes me as a place where mere mortals dare not tread, but I'll have a quick look to see if any usable signals are already being emitted.
Comment 11 Nate Graham 2018-11-14 18:38:05 UTC
Same issue (or at least the same root cause) as Bug 376865. Since it captures a screenshot immediately, the capture includes any in-progress or half-finished animations triggered by launching the app.

*** This bug has been marked as a duplicate of bug 376865 ***