Screenshot-annotate.sh

This commit is contained in:
Aleksandr Lebedev 2026-04-18 13:34:48 +02:00
parent 7b9a972e97
commit 13da32970b
2 changed files with 13 additions and 3 deletions

View file

@ -14,6 +14,7 @@ input {
// For example:
layout "eu,ru"
//variant "dvorak,,"
options "grp:lctrl_toggle, ctrl:nocaps"
// If this section is empty, niri will fetch xkb settings
@ -344,6 +345,14 @@ window-rule {
// This app-id regular expression will work for both:
// - host Firefox (app-id is "firefox")
// - Flatpak Firefox (app-id is "org.mozilla.firefox")
match app-id="com.gabm.satty"
open-floating true
open-focused true
min-width 700
min-height 400
}
window-rule {
match app-id=r#"librewolf$"# title="^Picture-in-Picture$"
open-floating true
}
@ -610,9 +619,8 @@ binds {
// Mod+Space { switch-layout "next"; }
// Mod+Shift+Space { switch-layout "prev"; }
Print { screenshot; }
Ctrl+Print { screenshot-screen; }
Alt+Print { screenshot-window; }
Print { spawn "screenshot-annotate.sh"; }
Mod+Shift+S { spawn "screenshot-annotate.sh"; }
// Applications such as remote-desktop clients and software KVM switches may
// request that niri stops processing the keyboard shortcuts defined here

View file

@ -0,0 +1,2 @@
#!/usr/bin/env bash
grim -g "$(slurp -w 0)" -t ppm - | satty --early-exit --copy-command 'wl-copy' --filename='-' -o '~/Pictures/Screenshots/Screenshot-%Y-%m-%d_%H:%M:%S.png' --initial-tool brush