diff --git a/config/mango/config.template.conf b/config/mango/config.template.conf index b052e14..2698dea 100644 --- a/config/mango/config.template.conf +++ b/config/mango/config.template.conf @@ -195,7 +195,8 @@ bind=SUPER,e,set_proportion,1.0 bind=SUPER,x,switch_proportion_preset, # switch layout -bind=SUPER,n,switch_layout +bind=SUPER,n,spawn,"$HOME/.config/mango/layout_change" +bind=SUPER+SHIFT,t,spawn_shell,$HOME/.config/mango/layout_change T # tag switch bind=SUPER,Left,viewtoleft,0 diff --git a/config/mango/layout_change b/config/mango/layout_change new file mode 100755 index 0000000..e191e18 --- /dev/null +++ b/config/mango/layout_change @@ -0,0 +1,13 @@ +#!/bin/sh + +layout="$1" + +if [[ -z "$layout" ]]; then + #echo "switch_layout" + mmsg -d switch_layout + layout="$(mmsg -g | grep ' layout' | cut -d' ' -f3)" +else + mmsg -l "$layout" +fi + +notify-send -a MongoWC -i view-grid "Layout changed" "$layout"