安装:
sudo apt-get install scrot
-------------------------------------------------------------------------------------------
使用:
查看下帮助:
scrot --help
Usage : scrot [OPTIONS]... [FILE] //中间是选项,最后是文件名。
eg:
scrot a.png
选项比较多,常用的两个:
-s, --select interactively choose a window or rectangle with the mouse 使用这个选项是会让使用者选择一个窗体,或者用鼠标选择一个矩形区域作为截屏的区域。
eg:
scrot -s a.png //执行的时候会等待用户选择,点击下窗体,或用鼠标选择个矩形区域。
-d, --delay NUM wait NUM seconds before taking a shot //若干秒后截屏
eg:
scrot -d 10 a.png //10秒后截屏
还可以使用另一个参数
-c, --count show a countdown before taking the shot //截屏前会倒数。。。
eg:
scrot -c -d 5 ~/a.png