Selectable area for screenshots on gnome
Install required software:
$ sudo apt-get install zenity scrot xclip
Script for capturing screen areas (change targets at the beginning of the file):
#!/bin/bash targetdir=/home/public-www/tmp/ targeturi=http://wunderlin.net/tmp/ icon=/usr/share/icons/gnome/22x22/apps/applets-screenshooter.png # ask for filename file=$(zenity --title="Screenshot" --width=800 --window-icon=$icon \ --text="Filename:" --filename="$targetdir" --file-selection) if [[ "$file" == ".png" || -z "$file" ]]; then exit 1; fi scrot --select "$file" uri=$(echo "$file" | sed -e 's|'$targetdir'||') echo "$targeturi$uri" | xclip -i -selection clip-board # zenity --info --text="$targeturi$uri" --title="Screenshot URL" --window-icon=$icon echo $file; exit 0;
Steps for creating a custom hotkey to launch any application in GNOME:
- Open "gconf-editor" as the user as you're logged in in GNOME
- Go to "apps" -> "metacity" -> "keybinding_commands"
- Double click on e.g. "command_1"
- Type in the name of the application you want to launch, e.g. "gcalctool", the GNOME calculator
- Go to "apps" -> "metacity" -> "global_keybindings"
- Double click on e.g. "run_command_1"
- Type in e.g. <Control><Alt>c
- Note the < and > for the special function keys
- DONE! Close the gconf-editor and press CTRL-ALT-c and the calculator should come up