This commit is contained in:
rootniformaticaservice 2023-03-07 08:55:59 -03:00
parent 57f3cc6afe
commit 02db2406be

View file

@ -1,65 +0,0 @@
#!/bin/sh
. $HOME/.config/rootwm/rwm_var
FLAG=$1
RID=$(lsw -r) # root window id
usage() {
echo "usage:
rwm_setting.sh [ -m, -M ]
-m) minimize tiling master area
-M) maximize tiling master area"
}
mp=$(atomx WM_MP $RID) # tiling master area percent from atom
master_inc() {
atomx WM_MP=$((mp + 5)) $RID
rwm_arrangement.sh -t
} # increase master area percent
master_dec() {
atomx WM_MP=$((mp - 5)) $RID
rwm_arrangement.sh -t
} # decrease master area percent
wp=$(atomx WM_WP $RID) # windows percent size from atom
windowperc_inc() {
atomx WM_WP=$((wp + 5)) $RID
rwm_arrangement.sh -w
} # increase windows percent size
windowperc_dec() {
atomx WM_WP=$((wp -5)) $RID
rwm_arrangement.sh -w
} # decrease windows percent size
if [ -n "$FLAG" ]; then
case $FLAG in
-m) # minimize tiling master area
master_dec
;;
-M) # maximize tiling master area
master_inc
;;
-w) # minimize window size
windowperc_dec
;;
-W) # maximize window size
windowperc_inc
;;
*)
usage
;;
esac
else
atomx WM_NAME=$NAME $RID
atomx WM_WP=$WP $RID
atomx WM_MP=$MP $RID
fi