From 0b8050b5386e1587f9664c8c768fc381ab883776 Mon Sep 17 00:00:00 2001 From: speedie Date: Sun, 25 Jun 2023 22:17:35 +0200 Subject: [PATCH] spmenu should always spawn at the top --- scripts/st_buffer | 4 ++-- scripts/st_copyout | 2 +- scripts/st_emojicopy | 2 +- scripts/st_urllist | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/st_buffer b/scripts/st_buffer index d43bdce..0e90700 100755 --- a/scripts/st_buffer +++ b/scripts/st_buffer @@ -35,11 +35,11 @@ function trigger_sigusr1() { } function dmenu_copy() { trigger_sigusr1 - cat $BUFFER_FILE | $RUNLAUNCHER -l 10 -i -w $(xdotool getactivewindow) -p 'Screen Copy' | sed 's/↵/\n/g' | xclip -i + cat $BUFFER_FILE | $RUNLAUNCHER -t -l 10 -i -w $(xdotool getactivewindow) -p 'Screen Copy' | sed 's/↵/\n/g' | xclip -i } function dmenu_type() { trigger_sigusr1 - cat $BUFFER_FILE | $RUNLAUNCHER -l 10 -i -w $(xdotool getactivewindow) -p 'Screen Type' | sed 's/↵/\n/g' | xargs -IC xdotool type --delay 0 "C" + cat $BUFFER_FILE | $RUNLAUNCHER -t -l 10 -i -w $(xdotool getactivewindow) -p 'Screen Type' | sed 's/↵/\n/g' | xargs -IC xdotool type --delay 0 "C" } function pipe_combine() { trigger_sigusr1 diff --git a/scripts/st_copyout b/scripts/st_copyout index 684f1b6..059e37a 100755 --- a/scripts/st_copyout +++ b/scripts/st_copyout @@ -6,6 +6,6 @@ trap 'rm -f "$tmpfile"' 0 1 15 sed -n "w $tmpfile" sed -i 's/\x0//g' "$tmpfile" ps1="$(grep "\S" "$tmpfile" | tail -n 1 | sed 's/^\s*//' | cut -d' ' -f1)" -chosen="$(grep -F "$ps1" "$tmpfile" | sed '$ d' | tac | $RUNLAUNCHER -p "Copy which command's output?" -na -i -l 10 -w $WINDOWID -g 1 | sed 's/[^^]/[&]/g; s/\^/\\^/g')" +chosen="$(grep -F "$ps1" "$tmpfile" | sed '$ d' | tac | $RUNLAUNCHER -p "Copy which command's output?" -na -i -l 10 -w $WINDOWID -g 1 -t | sed 's/[^^]/[&]/g; s/\^/\\^/g')" eps1="$(echo "$ps1" | sed 's/[^^]/[&]/g; s/\^/\\^/g')" awk "/^$chosen$/{p=1;print;next} p&&/$eps1/{p=0};p" "$tmpfile" | xclip -selection clipboard diff --git a/scripts/st_emojicopy b/scripts/st_emojicopy index 5b2e2ce..8e4b570 100755 --- a/scripts/st_emojicopy +++ b/scripts/st_emojicopy @@ -1658,6 +1658,6 @@ printf "\ " } -EMOJISEL="$(printf "%s" "$(EMOJILIST)" | $RUNLAUNCHER -l 5 -na -w $WINDOWID -p 'Pick an emoji: ' | awk '{ print $1 }')" +EMOJISEL="$(printf "%s" "$(EMOJILIST)" | $RUNLAUNCHER -t -l 5 -na -w $WINDOWID -p 'Pick an emoji: ' | awk '{ print $1 }')" [ -z "$EMOJISEL" ] && exit printf "%s" "$EMOJISEL" | xclip -selection clipboard && notify-send "$EMOJISEL copied to clipboard." diff --git a/scripts/st_urllist b/scripts/st_urllist index 73e71ba..b5cc608 100755 --- a/scripts/st_urllist +++ b/scripts/st_urllist @@ -5,7 +5,7 @@ esac command -v xdg-open > /dev/null && BROWSER="xdg-open" -URL=$(st_xurls | grep http | awk '!_[$1]++' | $RUNLAUNCHER -l 10 -w $WINDOWID -g 1 -p 'Open:' -na) +URL=$(st_xurls | grep http | awk '!_[$1]++' | $RUNLAUNCHER -t -l 10 -w $WINDOWID -g 1 -p 'Open:' -na) case "$1" in "") $BROWSER $URL ;;