wmutils is a set of tools for X window manipulation. These individual programs can be combined to uniquely manage windows.
When I used dwm, I set the monocle layout to the default and rarely used the tiling mode. My workflow looked like this:
- Work in a window.
- Open a second window that is referenced (such as a web browser).
- Run a few commands in a third window.
- Try to go to the previous one for reference.
- Waddle around with Alt+j or Alt+k after realizing the opposite was needed, or move a window to a different tag.
With wmutils, this is no longer a problem as it provides a program to change the stacking order, allowing me to bind Alt+Tab to switch between the last two focused windows, preventing distracted multitasking.
The scripts I use are based on z3bra's from the contrib repo. In my xinitrc, I call the winwatch script (depends on wew) to fullscreen windows on the MAP X event and focus the previous window when one is destroyed. The MAP event is used rather than CREATE to work with web browsers that create multiple windows.
In dwm, even when in monocle mode, other windows were still visible at a small gap to the bottom of my screen. With the script for fullscreening, a fullscreen means a fullscreen.
For a status bar, instead of using xsetroot, I now use lemonbar with this command: while status; do sleep 1m; done | lemonbar -d -F '#ccc' &
. The -d option prevents it from being focused or deleted by my keybinds. The status command does the following: echo "%{r} $(cat /sys/class/power_supply/BAT0/capacity)% | $(date +%I:%M) | $(uptime -p)"
. The %{r}
right-aligns the text.
In the fullscreen script, there is an offset, preventing the windows from hiding the status bar. xprop can be used to find the resolution of a window.