Skip to content

Interactive screenshot fails with g-io-error-quark on maximized and fullscreen windows on X11 #373

Description

@kachapman

Description:Usinggradia --screenshot=INTERACTIVE` fails with a generic error when attempting to capture a maximized or fullscreen window on X11. The same operation succeeds only when the window is restored to normal (non-maximized, non-fullscreen) state.


Environment:

Field Value
Desktop Session X11 (not Wayland)
Display Server X.Org
Desktop Environment GNOME / Mutter (Zorin OS 18 based on Ubuntu)
Tool Gradia CLI (version unknown)
Affected Application Any GTK app (tested with gThumb image viewer)

Steps to Reproduce:

  1. Open any GTK-based application (e.g., gthumb, gnome image viewer)
  2. Load an image or content
  3. Maximize the window (click title bar or press Super+Up) OR put it in fullscreen (press F11)
  4. Run: gradia --screenshot=INTERACTIVE
  5. Select the affected window from the picker

Actual Behavior:
Screenshot failed: g-io-error-quark: Screenshot failed (0)
Screenshot was cancelled or failed. Exiting.

Expected Behavior:
Interactive screenshot should successfully capture the selected portion maximized or fullscreen window, or gracefully degrade to full-screen capture if window-specific grab fails.


Window State Summary:

Window State Result
Normal (restored) Works
Maximized Fails
Fullscreen Fails

Possible Root Cause:
Picker's X11 window enumeration logic may not handle _NET_WM_STATE_MAXIMIZED_* or _NET_WM_STATE_FULLSCREEN properties correctly. Alternatively, the D-Bus portal call may timeout or reject these window states.


Sorry, I used AI to summarize the troubleshooting I tried into a format that developers might be more familiar with.

Thanks for your work on this great app!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions