fzy and more

This commit is contained in:
#root_informatica 2024-02-06 23:18:02 -03:00
parent 88b7e8575e
commit b23101fa67
5 changed files with 34 additions and 13 deletions

View File

@ -1,3 +1,10 @@
# wallpaper #
WALL="$HOME/.wall.png"
BITMAP="$HOME/.bitmap.xbm"
# gif #
GIF="$HOME/.gif"
# terminal
TERMINAL=xterm
@ -23,6 +30,9 @@ IC=4D4D4D
# background color
BC=101010
# font color
FC=A0A0A0
# windows percentage
WP=90

View File

@ -2,6 +2,10 @@
. /tmp/wms_var
$TERMINAL -name 'wms_launcher' \
$TERMINAL -name 'wms_launcher' \
-g $GEOMETRY \
-e bash -c 'cmd=$(compgen -c | sort -u | grep -v fzf | fzf --bind 'ctrl-e:print-query' --no-sort); setsid -f $cmd'
-e bash -c 'cmd=$(compgen -c | sort -u | grep -v fzy | fzy); \
setsid -f $cmd'
# -e bash -c

View File

@ -2,6 +2,10 @@
. /tmp/wms_var
$TERMINAL -name "wms_menu" \
$TERMINAL -name "wms_menu" \
-g $GEOMETRY \
-e "fzf --bind 'ctrl-e:print-query' --no-sort $* < /proc/$$/fd/0 > /proc/$$/fd/1"
-e "fzy < /proc/$$/fd/0 > /proc/$$/fd/1"
# fzf line:

View File

@ -1,3 +1,4 @@
#!/bin/sh
## some layouts to order the windows ##

View File

@ -32,6 +32,14 @@ wms_revalue.sh [ -b, -B, -d, -g, -G, -m, -M, -w, -W]
EOF
}
# default values.
default() {
# copy wms_var file in /tmp.
cp $HOME/.config/wms/wms_var /tmp/wms_var
# give some name to the window manager.
atomx WM_NAME=wms $(lsw -r) &
}
# increase border. (+2 pixels)
border_inc() {
if [ $BW -le 10 ]; then
@ -47,12 +55,11 @@ border_dec() {
wms_mainrole.sh $FW
fi
}
# increase gaps. (+2 pixels)
gap_inc() {
if [ $GAP -le 40 ]; then
sed -i "s/^.*\bGAP=\b.*$/GAP=$((GAP + 2))/" $WMSVAR
wms_usher.sh -t
fi
}
@ -60,7 +67,6 @@ gap_inc() {
gap_dec() {
if [ $GAP -ge 2 ]; then
sed -i "s/^.*\bGAP=\b.*$/GAP=$((GAP - 2))/" $WMSVAR
wms_usher.sh -t
fi
}
@ -68,7 +74,6 @@ gap_dec() {
master_inc() {
if [ $MP -le 80 ]; then
sed -i "s/^.*\bMP=\b.*$/MP=$((MP + 5))/" $WMSVAR
wms_usher.sh -t
fi
}
@ -76,7 +81,6 @@ master_inc() {
master_dec() {
if [ $MP -ge 20 ]; then
sed -i "s/^.*\bMP=\b.*$/MP=$((MP - 5))/" $WMSVAR
wms_usher.sh -t
fi
}
@ -84,7 +88,6 @@ master_dec() {
windowperc_inc() {
if [ $WP -le 90 ]; then
sed -i "s/^.*\bWP=\b.*$/WP=$((WP + 5))/" $WMSVAR
wms_usher.sh -w
fi
}
@ -92,7 +95,6 @@ windowperc_inc() {
windowperc_dec() {
if [ $WP -ge 60 ]; then
sed -i "s/^.*\bWP=\b.*$/WP=$((WP - 5))/" $WMSVAR
wms_usher.sh -w
fi
}
@ -104,8 +106,8 @@ if [ -n "$FLAG" ]; then
-B)
border_inc
;;
-d) # load defaults
cp $HOME/.config/wms/wms_var /tmp/wms_var
-d)
default
;;
-g)
gap_dec