From be296837aabf6d5a4c1bfa19b7c8f82bba421ce1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Dudr?= Date: Sun, 15 Jan 2023 13:20:12 +0100 Subject: [PATCH] hlwm: scrot -> maim --- dot_config/herbstluftwm/executable_autostart.tmpl | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/dot_config/herbstluftwm/executable_autostart.tmpl b/dot_config/herbstluftwm/executable_autostart.tmpl index 39cc273..3d30cb4 100644 --- a/dot_config/herbstluftwm/executable_autostart.tmpl +++ b/dot_config/herbstluftwm/executable_autostart.tmpl @@ -143,14 +143,14 @@ hc keybind XF86AudioPrev spawn systemd-run --scope --user "$HOME/bin/mprisctl" p hc keybind XF86AudioPlay spawn systemd-run --scope --user "$HOME/bin/mprisctl" toggle # shellcheck disable=2016 # needed to pass whole script to keybind... -hc keybind XF86TouchpadToggle spawn systemd-run --scope --user dash -c 'xinput --set-prop "SynPS/2 Synaptics TouchPad" "Device Enabled" $(xinput --list-props "SynPS/2 Synaptics TouchPad" | awk -F ":\t+" "/Device Enabled/ { print (1+\$2)%2}")' +hc keybind XF86TouchpadToggle spawn systemd-run --scope --user sh -c 'xinput --set-prop "SynPS/2 Synaptics TouchPad" "Device Enabled" $(xinput --list-props "SynPS/2 Synaptics TouchPad" | awk -F ":\t+" "/Device Enabled/ { print (1+\$2)%2}")' hc keybind XF86Display spawn systemd-run --scope --user ~/.config/herbstluftwm/monitors hc keybind XF86ScreenSaver and a spawn systemd-run --scope --user slock a spawn xset dpms force off -# shellcheck disable=2016 # $f is scrot interpolation string, not shells -hc keybind Print spawn systemd-run --scope --user scrot --focused --exec 'imv $f' "${HOME}/Pictures/scrot/%F-scrot.png" +hc keybind Print spawn systemd-run --scope --user sh -c 'maim --hidecursor | xclip -t image/png -selection clip' +hc keybind Shift-Print spawn systemd-run --scope --user sh -c 'maim --select --hidecursor | xclip -t image/png -selection clip' # shellcheck disable=SC2016 -hc keybind Shift-Print spawn systemd-run --scope --user scrot --select --exec 'imv $f' "${HOME}/Pictures/scrot/%F-scrot.png" +hc keybind Ctrl-Print spawn systemd-run --scope --user sh -c 'maim -i $(xdotool getactivewindow) | xclip -t image/png -selection clip' # theme hc attr theme.tiling.reset 1 @@ -222,9 +222,7 @@ hc rule class='mpv' floating=on hc set tree_style '╾│ ├└╼─┐' -{{ if eq .chezmoi.hostname "ws" }} -xrandr --output HDMI-1 --right-of DVI-D-1 -{{end}} + # do multi monitor setup here, e.g.: # hc set_monitors 1280x1024+0+0 1280x1024+1280+0