aboutsummaryrefslogtreecommitdiffstats
path: root/.sxiv/exec/key-handler
blob: f47c88a002f565be8c154cf0a04de7fe99f17e1d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh

# The key combo argument has the following form: "[C-][M-][S-]KEY",
# where C/M/S indicate Ctrl/Meta(Alt)/Shift modifier states and KEY is the X
# keysym as listed in /usr/include/X11/keysymdef.h without the "XK_" prefix.

case "$1" in
"C-c")
        echo -n "$2" | xclip -selection clipboard ;;
"C-d")
        rm "$2" ;;
"C-g")
        gimp "$2" & ;;
esac