Translation(s): English - Español - Français - Italiano

(!) ?Discussion


How do I take a screenshot in Debian?

Using Gnome

Gnome has built-in capability to make a screenshot (package gnome-utils). Simply press:

More options are available in "Gnome Application Menu/Accessories/Take Screenshot" (like delayed screen shot).

Using KDE

KDE Plasma should be able to capture a screenshot on most normal setups using package kde-spectacle, included with almost all of Debian's KDE metapackages and tasks. In this case:

Using Xfce

The xfce4-screenshooter is an utility for the Xfce Desktop Environment that can be used to take snapshots of your desktop screen. A panel plugin is provided too.

The xfce4-screenshooter application allows you to capture the entire screen, the active window or a selected region. You can set the delay that elapses before the screenshot is taken and the action that will be done with the screenshot: save it to a PNG file, copy it to the clipboard, open it using another application, or host it on ZimageZ, a free online image hosting service.

https://screenshots.debian.net/screenshot/xfce4-screenshooter/18223.png

https://screenshots.debian.net/screenshot/xfce4-screenshooter/18224.png

You can also use the commandline to take screenshot more quickly with xfce4-screenshooter.

Using command line

Just open a graphical terminal and type:

The command xwd is a standard xorg tool, which creates a pnm file. You can then use imagemagick 's convert, or netpbm 's xwdtopnm tool.

Similarly the screenshot of a single window can be obtained by not specifying a target window to xwd:

the mouse pointer then becomes a crosshair and the user must click on the desired window.

Similar results can be obtained combining the xwininfo utility in x11-utils with imagemagick 's import; first run xwininfo and it will prompt the user to click on the desired window. xwininfo output will start with a line similar to:

which contains the ID for that Window (0x1600077 in this example).

To capture a screenshot of that window, use the "import" command passing the window ID in its "-window" option:

The above command will create a .jpg file, but other file formats are available.

To capture a screenshot of the whole desktop (with a 5 seconds delay) use this command:

A powerful alternative tool is scrot, which can directly save files as png (and other formats), and generate a filename. See scrot(1).

On Wayland

grim stores a full screenshot ~/Pictures/Screenshots/ as png file.

grim

grim can also grab a selected portion of the screen using slurp

grim -g "$(slurp)"

Note about text screenshots

Rather that making a graphical snapshot of the console/command line or the terminal emulator, to share for example in IRC or other support medium, we highly recommend to copy the actual text content (select the region with a mouse) and paste the desired text.

Console

To use the mouse on the console screen(tty), install gpm (run apt-get install gpm).

Advanced tip: if you don't want to open a text editor, run cat > /tmp/outfile.txt, then paste the content using middle-button, then press Ctrl-D (once).

Framebuffer

If your system is using framebuffer (vga=XXX kernel argument, etc.), you can use fbgrab to capture and convert the framebuffer content.

Hint: If fbgrab isn't installed when you want to capture the screen, you can use cp /dev/fb0 screen.raw, then use fbgrab -f screen.raw -w 1024 -h 768 -b 16 screen.png.

Other Tools

Debian provides some other (advanced) tools to make screenshot, including gimp.

Debian Installer GUI screenshots

DebianInstaller's GUI has a take "Screenshot" button.

To fetch the captured screen :

If you complete the installation, the screenshots can also be found in the directory /var/log/installer/ (after the reboot into the installed system).

License of screenshots

Screenshots are considered as derivative works (according to SPI legal counsel), see http://lists.debian.org/debian-legal/2008/08/msg00016.html.

Taking screenshots for Debian

screenshots.debian.net, is a public repository of screenshots taken from applications contained in the Debian GNU/Linux distribution. Application showcases can be contributed easily, anonymously or not, through this service. The images are being used in packages.debian.org and also can be seen in many places through this wiki.