Bug 462875

Summary: No longer able to capture drop down menus
Product: [Applications] Spectacle Reporter: Peter <exup>
Component: GeneralAssignee: Boudhayan Gupta <me>
Status: VERIFIED UPSTREAM    
Severity: normal CC: kde, nate
Priority: NOR    
Version First Reported In: 22.12.0   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Peter 2022-12-11 00:59:54 UTC
SUMMARY
I used to just hit print screen to automatically open spectacle and capture rectangular region. But it does not start the capture process, until I click away from the menus (close them) then will screen shot normally.
A work around now is to use the built in delay (3 secs) to start the capture, open the menus and it will allow me to capture the menus.

STEPS TO REPRODUCE
1. Configure Spectacle to use the print key to start capture using rectangular region.
2. Right click desktop to show menus
3. Hit print key nothing happens does not start capture
4. Close menu on desktop - hit print key again and spectacle capture starts.

OBSERVED RESULT
Does not start capture when menus are open in any application

EXPECTED RESULT
Should start capture rectangular region


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 5.26.4
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 5.100.0 
Qt Version: 5.15.7

ADDITIONAL INFORMATION
This used to work since about 4 weeks ago.
Comment 1 Nate Graham 2023-01-03 20:45:43 UTC
Are you using the X11 or Wayland session?
Comment 2 Peter 2023-01-04 01:18:17 UTC
X11 is where I am seeing the issue. I just did a full upgrade today and result is the same. Its does not have a GPU and is Intel i7
On my separate laptop same build, but running only Wayland it works ok. So just the Xorg one has this issue.
Comment 3 Nate Graham 2023-01-04 17:28:05 UTC
On X11, it's never been possible to capture pop-up menus that are implemented as their own windows (such as QMenus in Qt apps, as opposed to in-window popups and overlay sheets) without using the delay feature. This is an X11 limitation as such "I'm actually a window" popups steal focus and prevent Spectacle from being launched while they're open, without closing them.

It already works on Wayland, as you've noticed.

I'm not sure why you experienced this working before on X11; it should never have worked on X11 and it's never been expected to work on X11. If for some reason it ever did, consider yourself lucky, somehow!
Comment 4 Peter 2023-01-04 22:45:06 UTC
Ah OK, maybe I am wrong and never did try this before, I make copious notes on various things and use Spectacle daily. Looking through all my notes I can only see screenshots of in application drop down menus etc, never the application menu bar drop downs. Anyway good to see it working in Wayland and many thanks for all the hard work. 
I'll sign up to the 100 euro donation program.
Comment 5 Nate Graham 2023-01-05 15:17:06 UTC
Oh nice, thanks so much!