Bug 98672 - screenshot tools like scrot or maim do not work under (gnome) wayland
Summary: screenshot tools like scrot or maim do not work under (gnome) wayland
Status: RESOLVED NOTABUG
Alias: None
Product: Wayland
Classification: Unclassified
Component: XWayland (show other bugs)
Version: unspecified
Hardware: Other Linux (All)
: medium normal
Assignee: Wayland bug list
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-11-10 12:22 UTC by Lesmana Zimmer
Modified: 2018-02-18 09:24 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Lesmana Zimmer 2016-11-10 12:22:15 UTC
screenshot tools like scrot or maim do not work under (gnome) wayland.

scrot and maim produce black images with the dimension of my display.

import of imagemagick produces following error message

    $ import -window root foo.png
    import: unable to read X window image `root': Resource temporarily unavailable @ error/xwindow.c/XImportImage/4983.
    import: missing an image filename `foo.png' @ error/import.c/ImportImageCommand/1287.

this happened on my system since gnome 3.22 which uses wayland by default. previously i did not test wayland.

when using gnome with X then scrot and maim and import produce screenshots as expected.

i reported this bug to the maim developers. they said the following: "you'll be better off submitting bug reports to the wayland team since imlib2's X11 calls aren't being translated properly."

https://github.com/naelstrof/maim/issues/67

i use arch linux.

    $ pacman -Q gnome-shell wayland xorg-server-xwayland
    gnome-shell 3.22.1+2+g5a08886-1
    wayland 1.12.0-1
    xorg-server-xwayland 1.18.4-1

please tell me what more information do you need.
Comment 1 Olivier Fourdan 2016-11-10 12:41:43 UTC
By design, Wayland is a lot more secure than X11 and does not allow one application to capture the content of other applications' windows, meanignath a X11 based screenshot tool cannot work underWayland/Xwayland.

Both Weston and gnome-shell (Wayland compositors) have screencast and screenshot features built-in.
Comment 2 Ben Creasy 2018-02-18 09:24:42 UTC
It seems like this should have been marked as Resolved, so I'm doing so as NOTABUG (could also be WONTFIX?).

I recommend looking at https://bugs.freedesktop.org/show_bug.cgi?id=98894 tho! Possibly someday in the not too distant future there will be a cross-toolkit way to take screenshots.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.