Screenshots

Lots of folks have recommended ImageMagic and it's an excellent tool, but I've found it can be overly complex. I've found graphics/GraphicsMagick (to be a much more compact, efficient, and easier tool than ImageMagick. Per it's website about the Import function:

Import reads an image from any visible window on an X server and outputs it as an image file. You can capture a single window, the entire screen, or any rectangular portion of the screen. Use display for redisplay, printing, editing, formatting, archiving, image processing, etc. of the captured image.

The target window can be specified by id, name, or may be selected by clicking the mouse in the desired window. If you press a button and then drag, a rectangle will form which expands and contracts as the mouse moves. To save the portion of the screen defined by the rectangle, just release the button. The keyboard bell is rung once at the beginning of the screen capture and twice when it completes.

GM started as a fork of ImageMagic since version 5.5, but has seen been completely rewritten. I've found it a better match for my particular needs.
Also, your particular DE should have a utility for screenshots (built-in or as an addon). I use Xfce and there's a seperate utility for screenshots - Xfce4-Screenshooter (/x11/xfce4-screenshooter-plugin/). Your DE may have something as well.
 
Last edited:
Isn't there a short name x-something tool for doing that? Like xsh. I never remember what it is and never think about it till I need it. Then I can't find it
 
… According to the Wikipedia article it can be .xwd.

True, thanks. Result:

1621736125387.png


  • GIMP was already the default for '.xwd
  • I weeded Ark and other peculiarities from the list of applications, to leave Thunderbird as the only other.
 
The problem with GIMP is that you cannot map the screenshot capture to a key. E.g. I map the ImageMagick's action to the PrtScr key to trigger it quickly when needed.
I don't, but you can.

On the Gimp Main Menu at the top chose Edit - Keyboard Shortcuts and it will bring up the Configure Keyboard Shortcuts box shown in the shot. Then go to Plugins - Screenshot:

keycut.jpg
 
It has a checkbox to "Save keyboard shortcuts on exit" at the bottom of the Configure Keyboard Shortcuts box.
If you have it open and it's not in focus it stands to reason it should still work.
 
FreeBSD 13.0 xfce with custom kernel, zfs, geli fully encrypted in VM (host Slackware)
 

Attachments

  • FreeBSD-GELI-ZFS-XFCE4.png
    FreeBSD-GELI-ZFS-XFCE4.png
    357.1 KB · Views: 256
Whenever I've installed KDE or MATE, there is always a screenshot capability built-in to the Desktop Environment software, which launches itself automatically whenever you press the [Print Screen] key (or [prt sc] key on some keyboards). It's always just there; I never have to do anything to enable it or use it, other than pressing [Print Screen]. On KDE it's called "Spectacle" but I don't even know what it's called in MATE, probably something like "mate-printscreen" I'm guessing. Super-convenient.
 
I used to use graphics/scrot with following setting in the x11-wm/i3

~/.config/i3/config
Code:
set $mod Mod4
bindsym Control+Print exec scrot -z -o '%y%m%d%H%M%S.png' -e 'convert $f -crop 1920x1080+0+0 $f && mv $f PICTURE_FOLDER'
bindsym Shift+Print exec scrot -z -o '%y%m%d%H%M%S.png' -e 'convert $f -crop 1366x768+1920+0 $f && mv $f PICTURE_FOLDER'
bindsym $mod+Print exec scrot -z -o '%y%m%d%H%M%S.png' -e 'mv $f PICTURE_FOLDER'
bindsym Print exec scrot -z -o -u '%y%m%d%H%M%S.png' -e 'mv $f PICTURE_FOLDER'
bindsym --release Control+Shift+Print exec scrot -z -o -s '%y%m%d%H%M%S.png' -e 'mv $f PICTURE_FOLDER'

Footnotes:
* PICTURE_FOLDER == Screenshot folder.

* Separate screenshot for 2 monitors:
>> 1920x1080 (primary)
>> 1366x768 (secondary)
 
Back
Top