···157157 grim "$filename" > "$SCR_CACHE_DIR/pic.log" 2>&1
158158 else
159159 # Get the geometry of the screenshot from the user and take the screenshot
160160- # TODO: add a SLURP_OPTS environment variable to allow the user to customize slurp
161161- if [ "$output" ]; then set -- -o "$output"; else set -- -g "$(slurp)"; fi
160160+ if [ "$output" ]; then set -- -o "$output"; else set -- -g "$(slurp "${SLURP_ARGS}")"; fi
162161 grim "$@" "$filename" > "$SCR_CACHE_DIR/pic.log" 2>&1
163162 fi
164163···198197 # Intercept Ctrl+C and exit wf-recorder instead of the script
199198 trap '' INT
200199201201- if [ "$output" ]; then set -- -o "$output"; else set -- -g "$(slurp)"; fi
200200+ if [ "$output" ]; then set -- -o "$output"; else set -- -g "$(slurp "${SLURP_ARGS}")"; fi
202201 # Word splitting is favorable here
203202 # shellcheck disable=SC2086
204203 wf-recorder $args $rec_extraflags "$@" -f "$filename" > "$SCR_CACHE_DIR/rec.log" 2>&1 &