add support for more floating/stacking WMs:

xfwm4, metacity, fvwm, sawfish, and goomwwm
long-opts
angelic-sedition 10 years ago
parent 18eaffaa3a
commit 76f91e5636

@ -57,12 +57,17 @@ If your window manager does not support floating, there's nothing to worry about
For floating window managers, tdrop should also generally "just work", but you will need to add the '-a' option. Many floating window managers will either center or resize a window when mapping then unmapping it. Tdrop provides for a `--post-commmand` to deal with this. '-a' will automatically determine the proper post command to use for your window manager if one exists. The '-a' option will also set things up so that window geometry/position will be properly restored on an `auto_show`.
That said, these are the floating window managers that currently have '-a' settings:
- xfwm4
- metacity
- openbox
- pekwm
- fluxbox
- blackbox
- fvwm
- sawfish
- goomwwm
It is a simple matter to add new ones to this list. If your dropdown moves out of place when being shown, make an issue, and I will add settings for it.
Usually, it is a simple matter to add new ones to this list. If your dropdown moves out of place when being shown, make an issue, and I will add settings for it.
#### Tiling with Floating Support
These window managers currently will work with '-a'. I will add a lot more.

@ -103,7 +103,8 @@ done
#
get_window_manager() {
xprop -notype -id "$(xprop -root -notype | awk '$1=="_NET_SUPPORTING_WM_CHECK:"{print $5}')" -f _NET_WM_NAME 8u | awk -F "\"" '/WM_NAME/ {print $2}'
# xfwm4 and fvwm at least will give two names (hence piping into head)
xprop -notype -id "$(xprop -root -notype | awk '$1=="_NET_SUPPORTING_WM_CHECK:"{print $5}')" -f _NET_WM_NAME 8u | awk -F "\"" '/WM_NAME/ {print $2}' | head -n 1
}
# tilers w/ floating support: settings for floating a window when mapping it
@ -177,12 +178,14 @@ wm_autoset_for_window() {
xdotool windowmove "$1" "$xoff" "$yoff" windowsize "$1" "$width" "$height"
}
# floating window managers that may move a window after unmapping then mapping it
elif [[ $wm == pekwm ]] || [[ $wm == fluxbox ]] || [[ $wm == Blackbox ]]; then
elif [[ $wm =~ ^(pekwm|fluxbox|Blackbox|xfwm4|Metacity|FVWM|Sawfish|GoomwW)$ ]]; then
# most will center
# xfwm4 will normally move to top left; metacity will move close to top left
# sawfish just moves all over the place
map_post() {
xdotool windowmove "$1" "$xoff" "$yoff"
}
fi
}
#

Loading…
Cancel
Save