From 78113baeaa4a75ee616c92addf2ae43c5f3c724c Mon Sep 17 00:00:00 2001 From: speedie Date: Wed, 13 Sep 2023 20:40:33 +0200 Subject: [PATCH] Fix X11 screenshotting --- screenshot-spmenu | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/screenshot-spmenu b/screenshot-spmenu index 6a0af71..82d3259 100755 --- a/screenshot-spmenu +++ b/screenshot-spmenu @@ -24,10 +24,10 @@ screenshot_take() { [ "$2" = "true" ] && [ "$x11" != "true" ] && POS="$(slurp)" if [ "$x11" = "true" ] && [ -x "$(command -v maim)" ]; then - [ "$2" = "true" ] && sel_arg="-s" + [ "$2" = "true" ] && sel_arg=s [ "$3" = "true" ] && [ "$2" != "true" ] && cursor_arg=u - maim -"${sel_arg}""${cursor_arg}"B > "$1" || exit 1 + maim -${sel_arg}${cursor_arg}B > "$1" || exit 1 elif [ -x "$(command -v slurp)" ] && [ -x "$(command -v grim)" ] && [ "$PREFER_WAYSHOT" != "true" ]; then if [ "$2" = "true" ]; then grim -g "$POS" - > "$1" || exit 1