Add custom script for screenshot taking

This commit is contained in:
ItsDrike 2022-11-17 16:28:24 +01:00
parent 07479d0426
commit 7bf40cbf70
No known key found for this signature in database
GPG key ID: B014E761034AF742
2 changed files with 239 additions and 7 deletions

View file

@ -135,6 +135,9 @@ windowrulev2 = float, class:^(firefox)$,title:^(Extension: \(uBlock Origin\))
### KEY BINDINGS ###
####################
$SCREENSHOT_FORMAT = "${XDG_SCREENSHOTS_DIR:-$HOME/Pictures/Screenshots}/Screenshot_$(date +%Y-%m-%d_%H-%M-%S).png"
$SCREENSHOT_DELAY = 2000
$MOUSE_LMB = mouse:272
$MOUSE_RMB = mouse:273
$MOUSE_MMB = mouse:274
@ -178,13 +181,16 @@ binde = SUPER, Left, exec, brightness -d 5% -n
binde = , XF86MonBrightnessUp, exec, brightness -i 5% -n
binde = , XF86MonBrightnessDown, exec, brightness -d 5% -n
# Screenshots
bind = ,Print, exec, grim -g "$(slurp)" - | wl-copy --type image/png && notify-send "Screenshot" "Screenshot saved to clipboard"
bind = SUPER, Print, exec, grim -g "$(slurp)" - | swappy -f - -o - | wl-copy --type image/png
bind = CTRL, Print, exec, echo "" | wofi --prompt "Set delay (ms)" --show dmenu | xargs -I _ sleep _e-3 && grim -g "$(slurp)" - | wl-copy --type image/png
bind = SUPER_CTRL, Print, exec, echo "" | wofi --prompt "Set delay (ms)" --show dmenu | xargs -I _ sleep _e-3 && grim -g "$(slurp)" - | swappy -f - -o - | wl-copy --type image/png
bind = SHIFT, Print, exec, wl-copy --type image/png "$(hyprpicker)" && notify-send 'Picked color' "$(wl-paste) (saved to clipboard)"
bind = SUPER_SHIFT_CTRL, Print, exec, grim
# Screenshots (with custom screenshot script)
bind = ALT, Print, exec, wl-copy --type image/png "$(hyprpicker)" && notify-send 'Picked color' "$(wl-paste) (saved to clipboard)"
bind = , Print, exec, screenshot --notify --copy --target area
bind = SUPER, Print, exec, screenshot --notify --copy --target area --edit
bind = SHIFT, Print, exec, screenshot --notify --save $SCREENSHOT_FORMAT --target area
bind = CTRL, Print, exec, screenshot --notify --copy --target area --delay $SCREENSHOT_DELAY
bind = SUPER_SHIFT, Print, exec, screenshot --notify --save $SCREENSHOT_FORMAT --target area --edit
bind = SUPER_CTRL, Print, exec, screenshot --notify --copy --target area --delay $SCREENSHOT_DELAY --edit
bind = SUPER_SHIFT_CTRL, Print, exec, screenshot --notify --save $SCREENSHOT_FORMAT --target area --delay $SCREENSHOT_DELAY --edit
# Active window
bind = SUPER, W, killactive,