mirror of
https://github.com/mintycube/dotfiles.git
synced 2024-10-22 14:05:41 +02:00
change menu positions
This commit is contained in:
parent
4599a4fe84
commit
d24fa040f7
@ -2,7 +2,7 @@
|
|||||||
import subprocess
|
import subprocess
|
||||||
|
|
||||||
dmenu_command = "dmenu -i -l 16 -W 200 -Y 15 -X 1151 -bw 2"
|
dmenu_command = "dmenu -i -l 16 -W 200 -Y 15 -X 1151 -bw 2"
|
||||||
apps = "dmenu_run -bw 2 -i -W 390 -X 961 -Y 15 -l 16 -g 3"
|
apps = "dmenu_run -bw 2 -i -W 390 -X 8 -Y 420 -l 15 -g 3"
|
||||||
camera = (
|
camera = (
|
||||||
"mpv --untimed --no-cache --no-osc "
|
"mpv --untimed --no-cache --no-osc "
|
||||||
"--no-input-default-bindings --profile=low-latency "
|
"--no-input-default-bindings --profile=low-latency "
|
||||||
@ -12,21 +12,21 @@ camera = (
|
|||||||
bar_colors_toggle = '[ -e "$HOME/.cache/bar_color" ] && { rm "$HOME/.cache/bar_color"; renew-dwm; } || { touch "$HOME/.cache/bar_color"; renew-dwm; }'
|
bar_colors_toggle = '[ -e "$HOME/.cache/bar_color" ] && { rm "$HOME/.cache/bar_color"; renew-dwm; } || { touch "$HOME/.cache/bar_color"; renew-dwm; }'
|
||||||
|
|
||||||
options = {
|
options = {
|
||||||
f" Apps": apps,
|
" Apps": apps,
|
||||||
f" Bar colors": bar_colors_toggle,
|
" Bar colors": bar_colors_toggle,
|
||||||
f" Fix audio": "fix-audio",
|
" Fix audio": "fix-audio",
|
||||||
f" Edit Configs": "st -e confedit",
|
" Edit Configs": "st -e confedit",
|
||||||
f" Web Search": "dmenu_web",
|
" Web Search": "dmenu_web",
|
||||||
f" Handler": "dmenuhandler",
|
" Handler": "dmenuhandler",
|
||||||
f" Keybinds": "keybinds",
|
" Keybinds": "keybinds",
|
||||||
f" Mount": "mounter",
|
" Mount": "mounter",
|
||||||
f" Unmount": "unmounter",
|
" Unmount": "unmounter",
|
||||||
f" Kill": "processkill",
|
" Kill": "processkill",
|
||||||
f" Pick Color": "xcolor-pick",
|
" Pick Color": "xcolor-pick",
|
||||||
f" Screenshot": "maimpick",
|
" Screenshot": "maimpick",
|
||||||
f" Record": "dmenurecord",
|
" Record": "dmenurecord",
|
||||||
f" Camera": camera,
|
" Camera": camera,
|
||||||
f" NerdFont Icons": "dmenunerdsymbols",
|
" NerdFont Icons": "dmenunerdsymbols",
|
||||||
}
|
}
|
||||||
option_list = list(options.keys())
|
option_list = list(options.keys())
|
||||||
try:
|
try:
|
||||||
|
@ -18,7 +18,7 @@ commands=(
|
|||||||
"xset dpms force suspend"
|
"xset dpms force suspend"
|
||||||
)
|
)
|
||||||
|
|
||||||
if prompt=$(printf '%s\n' "${options[@]}" | dmenu -i -bw 2 -g 1 -l 9 -W 200 -X 1151 -Y 15); then
|
if prompt=$(printf '%s\n' "${options[@]}" | dmenu -i -bw 2 -g 1 -l 9 -W 200 -X 1157 -Y 598); then
|
||||||
selected_index=$(printf '%s\n' "${options[@]}" | grep -xn "$prompt" | cut -d ":" -f 1)
|
selected_index=$(printf '%s\n' "${options[@]}" | grep -xn "$prompt" | cut -d ":" -f 1)
|
||||||
${commands[$selected_index - 1]}
|
${commands[$selected_index - 1]}
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user