From 73391c83177ad96643aa3df5ace4ca7e424b447e Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Mon, 24 Mar 2025 11:17:52 +0100 Subject: ... --- accounts/gkleen@sif/niri/default.nix | 28 ++++++++++------------------ 1 file changed, 10 insertions(+), 18 deletions(-) (limited to 'accounts') diff --git a/accounts/gkleen@sif/niri/default.nix b/accounts/gkleen@sif/niri/default.nix index e4a93a49..302baea9 100644 --- a/accounts/gkleen@sif/niri/default.nix +++ b/accounts/gkleen@sif/niri/default.nix @@ -387,6 +387,8 @@ in { in [ (flag "prefer-no-csd") + (leaf "screenshot-path" "~/screenshots/%Y-%m-%dT%H:%M:%S.png") + (plain "hotkey-overlay" [ (flag "skip-at-startup") ]) @@ -703,27 +705,17 @@ in { wl-copy "$(cut -d ':' -f 1 <<<"$FUZZEL_RES" | tr -d '\n')" && wtype -k XF86Paste ''; })); - "Print".action = spawn (lib.getExe (pkgs.writeShellApplication { - name = "screenshot"; - runtimeInputs = with pkgs; [ grim slurp wl-clipboard-rs coreutils ]; - text = '' - grim -g "$(slurp -b 00000080 -c FFFFFFFF -s 00000000 -w 1)" - \ - | tee "$HOME/screenshots/$(date +"%Y-%m-%dT%H:%M:%S").png" \ - | wl-copy --type image/png - ''; - })); - "Shift+Print".action = spawn (lib.getExe (pkgs.writeShellApplication { - name = "screenshot"; - runtimeInputs = with pkgs; [ grim niri gojq wl-clipboard-rs coreutils ]; - text = '' - grim -o "$(niri msg -j workspaces | jq -r '.[] | select(.is_focused) | .output')" - \ - | tee "$HOME/screenshots/$(date +"%Y-%m-%dT%H:%M:%S").png" \ - | wl-copy --type image/png - ''; - })); + "Print".action = screenshot; + "Control+Print".action = screenshot-window; + # "Shift+Print".action = screenshot-screen; "Mod+B".action = with-select-window-action ".workspace_id == ($active_workspace | tonumber)" "{\"Action\":{\"FocusWindow\":{\"id\": .id}}}"; "Mod+Shift+B".action = with-select-window-action "true" "{\"Action\":{\"FocusWindow\":{\"id\": .id}}}"; + "Mod+Escape" = { + allow-inhibiting = false; + action = toggle-keyboard-shortcuts-inhibit; + }; + "Mod+H".action = focus-column-left; "Mod+T".action = focus-window-down; "Mod+N".action = focus-window-up; -- cgit v1.2.3