Take Screenshot By Command or Terminal in Linux Based Machine
By Fahad Ahammed
- 2 minutes read - 265 wordsTaking screenshot is now a days very important. This is used for many purpose like writing blog post, sharing problem facing in the system and much more things. There are many tools to take shot of your desktop but here i will show you how to take screenshot by terminal or command line interface in linux based machine.
Let, you want to take screenshot of full screen. Then copy below command and run in your terminal.
Above , sleep 2 is just asking the command to wait 2 seconds. And capture.png is the screenshot file. This file will be created on the default folder.This command will capture full screen including the terminal you are using to take the shot.See the shot.
You can click the big window to hide the terminal which you are using to take the screenshot.
Now if you want to take the screenshot of a particular window. Use below code.
Above command will show you a “+” icon and this will actually ask you to select the window. But if you chose the window below the terminal you are using for taking the shot will include the shadow of that window.
But you can take time take the window in the front.
Above command will give you 2 second time to take the window to the front and then will show the “+” icon to select that window.
That is all for today. I have used LXDE version of Debian Wheezy in Virtualbox. This commands works with XORG. Let me know if it doesn’t work for you. Thank You for reading.