sway: Add key bindings for screenshots
This commit is contained in:
parent
45c32595e1
commit
9d31a63799
1 changed files with 17 additions and 0 deletions
17
sway/config
17
sway/config
|
|
@ -150,6 +150,23 @@ mode "$mode_system" {
|
|||
}
|
||||
bindcode $mod+Shift+55 mode "$mode_system"
|
||||
|
||||
# Screenshot
|
||||
set $mode_screenshot Screenshot (o) output, (a) active, (r) region, (Shift+o) copy output, (Shift+a) copy active, (Shift+r) copy region
|
||||
mode "$mode_screenshot" {
|
||||
bindsym o exec 'grimshot save output | xargs -I {} notify-send -t 10000 Screenshot "{}"', mode "default"
|
||||
bindsym a exec 'grimshot save active | xargs -I {} notify-send -t 10000 Screenshot "{}"', mode "default"
|
||||
bindsym r exec 'grimshot save area | xargs -I {} notify-send -t 10000 Screenshot "{}"', mode "default"
|
||||
bindsym Shift+o exec 'grimshot copy output | xargs -I {} notify-send -t 10000 Screenshot "{}"', mode "default"
|
||||
bindsym Shift+a exec 'grimshot copy active | xargs -I {} notify-send -t 10000 Screenshot "{}"', mode "default"
|
||||
bindsym Shift+r exec 'grimshot copy area | xargs -I {} notify-send -t 10000 Screenshot "{}"', mode "default"
|
||||
bindsym Return mode "default"
|
||||
bindsym mod3+Return mode "default"
|
||||
bindsym Escape mode "default"
|
||||
bindsym mod3+Escape mode "default"
|
||||
}
|
||||
bindsym $mod+l mode "$mode_screenshot"
|
||||
bindsym Print exec grimshot save output | xargs -I {} notify-send -t 10000 Screenshot "{}"
|
||||
|
||||
# Systemd environment
|
||||
exec "systemctl --user import-environment; systemctl --user start sway-session.target"
|
||||
exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue