In this article, we will teach you how to use a nice command-line tool called scrot that is used take screenshots in your Linux machine. According to the description in the manual, this screen capture utility uses imlib2 library to acquire and save images. I like to practice the tool as much as possible, so let's open a new terminal (CTRL+ALT+T) and start the action.
Note: scrot is available in every repository, so the installation should be very easy.
How to take Screenshots with scrot
1. Run the following command to capture your whole screen.
When used without an option, scrot utility will capture your whole screen and will save the output in the following format inside your home directory.
The format: year-month-day-screen_resolution_scrot.png.
2. If you like to select a window or grab a rectangle, you should use the -s option which is the short version of --selection.
Type the above command in your terminal, hit enter and select the area you want to grab with your mouse. The screenshot will be saved in your home directory.
3. A very useful option that I use alot and would like to share with you Linux geeks, is the -d option which is used to wait a number of seconds before taking a shot. You can also use the -c option while working with delays because it displays a nice countdown.
scrot -d 13 -c