I am trying to hide my panel under a few specific conditions but I cant make it work.
I'm using lemonbar and have set an Xname of "sp" and then queried window ID using xwininfo. The spw is the panelwindowID.
Got "bspc node "${spw}" -g hidden=on" which works for normal windows tracked by bspwm but not for panels.
So what am I missing here?
In the source code of rule.c you can find the following:
...
} else if (a == ewmh->_NET_WM_WINDOW_TYPE_DOCK ||
a == ewmh->_NET_WM_WINDOW_TYPE_DESKTOP ||
a == ewmh->_NET_WM_WINDOW_TYPE_NOTIFICATION) {
csq->manage = false;
...
And since Lemonbar is a dock as you can see with xprop:
_NET_WM_WINDOW_TYPE(ATOM) = _NET_WM_WINDOW_TYPE_DOCK
Means that bspwm will not manage the Lemonbar windows, so any bspc command on them will fail.
Instead you could use the xdo program by the same author as bspwm: xdo hide -a sp. I do not know what your reason is to hide the panel, but I use xdo to make sure the Lemonbar windows are not above fullscreen windows with the following: xdo lower -a sp.
PS: If xdo does not work for you, be sure to use the latest version (0.5.6), because earlier versions did not sync with the X server, causing commands to sometimes not take effect in time.
@Anachron did xdo hide work for you?
Yep, closing.
Most helpful comment
In the source code of
rule.cyou can find the following:And since Lemonbar is a dock as you can see with
xprop:Means that
bspwmwill not manage the Lemonbar windows, so anybspccommand on them will fail.Instead you could use the
xdoprogram by the same author asbspwm:xdo hide -a sp. I do not know what your reason is to hide the panel, but I usexdoto make sure the Lemonbar windows are not above fullscreen windows with the following:xdo lower -a sp.PS: If
xdodoes not work for you, be sure to use the latest version (0.5.6), because earlier versions did not sync with the X server, causing commands to sometimes not take effect in time.