Tips Linux Explorers   All Things Linux Forum   Great Linux Links   LinuxClues.com   Hometown    



SCREENSHOT SCRIPT


Currently in most KDE distros the Print Screen key is assigned to the Ksnapshot program, but you can re-assign it to another program.

The command to make a screenshot of the full screen is: "import -window root screenshot.png". Now, you can make a bash-script that includes this command and place it in /usr/local/bin, like this:


CODE
$ kdesu kwrite /usr/local/bin/ScreenShotScript

and in the file paste:

QUOTE
#!/bin/bash
import -window root `date +%d-%m-%y_%H:%M:%S`_sreenshot.png
#End script

NOTE: This will give each screenshot a date and time stamp.


Next make the script executable:

CODE
# chmod 775 /usr/local/bin/ScreenShotScript

Finally you make a new menu item with "kmenuedit", call it ScreenShotScript and in the box "command" write "/usr/local/bin/ScreenShotScript" ( deselect the box for "enable launch feedback" ) . . . . and in the dialog of kmenuedit you can re-assign the hotkey to the Print Screen button.

This way no dialog or feedback will pop up when you press the Print Screen key and you will find the screenshots nicely time stamped in /home



Bruno


NOTE: the  `  in the script are NOT  '  or  ´



-- Jun 30 2007 --


Tips Linux Explorers   All Things Linux Forum   Great Linux Links   LinuxClues.com   Hometown