The i3 FAQ has migrated to https://github.com/i3/i3/discussions. All content here is read-only.
Ask Your Question
0

bindsym for screenshot partially not working

asked 2015-09-22 15:19:05 +0000

a_flamethrowing_duck gravatar image

I want to have different ways of making a screenshot, handy with a key combination.

So this is what I came up with.. Print for the regular screenshots, Shift+print for selection only and $mod+print+shift for the active window.

bindsym Print exec "scrot -m '/home/user/Pictures/screenshots/%s_%H%M_%d.%m.%Y_$wx$h.png'"
bindsym Shift+Print exec "scrot -s '/home/user/Pictures/screenshots/%s_%H%M_%d%m%Y_$wx$h.png'"
bindsym $mod+Shift+Print exec "scrot -u -d 4 '/home/user/Pictures/screenshots/%s_%H%M_%d%m%Y_$wx$h.png'"

Regular screenshots and screenshots of the active window work fine. The Shift+Print, for the selection screenshot doesn't work at all. The command itself works perfectly fine in the terminal, but not when run with the key combination.

What am I missing?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2015-09-22 18:33:07 +0000

Airblader gravatar image

I figured it out now. It's actually a known problem, I was just blind. Sorry, I also missed this in my answer on the other thread. You need to add "--release":

bindsym --release Print exec "scrot -m '/home/user/Pictures/screenshots/%s_%H%M_%d.%m.%Y_$wx$h.png'"
bindsym --release Shift+Print exec "scrot -s '/home/user/Pictures/screenshots/%s_%H%M_%d%m%Y_$wx$h.png'"
bindsym --release $mod+Shift+Print exec "scrot -u -d 4 '/home/user/Pictures/screenshots/%s_%H%M_%d%m%Y_$wx$h.png'"
edit flag offensive delete link more

Comments

very nice! works perfectly now.. thank you so much!

a_flamethrowing_duck gravatar imagea_flamethrowing_duck ( 2015-09-22 22:56:55 +0000 )edit

Question Tools

1 follower

Stats

Asked: 2015-09-22 15:19:05 +0000

Seen: 54 times

Last updated: Sep 22