Skip to navigation

Screenshots with ImageMagick’s “import”

For quick-and-dirty screenshots ImageMagick’s import command is unbeatable.

sudo aptitude install imagemagick

ImageMagick is worth getting for a lot of other reasons, too, just see man convert or man mogrify after installing.

Here are the most important options for import

import pic.jpg

This changes the cursor to a crosshair — draw around the region you want a screenshot of; no need to take a screenshot of the entire screen and then crop. Combined with a verve mini commandline in the Xfce panel, this is ideal for taking quick images of order confirmations, error messages that you need to google later, etc.

import -screen pic.jpg

This also changes the cursor to a crosshair, but instead of drawing a region, you point it at one of your windows and click, and you get a screenshot of that window only.

import -window root pic.jpg
import -pause 2 -window root pic.jpg

Screenshot of the entire screen, without or with a delay.

My only gripe with import is that it doesn’t do transparency, at least not by default (for example, transparent terminals are opaque black in the screenshot), and probably related is that it loses some of my window borders (I’m using Compiz & Emerald). With the gazillion options, I’m sure there’s some way to fix it, but I have no time to figure it out. For pretty screenshots of transparent windows, I did instead:

sudo aptitude install gnome-utils

and use gnome-screenshot (which instead has the advantage that you don’t necessarily have to save the screenshot — you can drag and drop the thumbnail preview from the save dialogues to apps that are capable of receiving drag and drop).

Comments are closed.