Command to move a window to all desktops

desktopopenboxscriptingxorg

I'd like to be able to move (pin) an existing window to all desktops using a scriptable command, rather than through the window menu.

wmctrl -r <WIN> -t <DESK> will move a window to a different desktop, but I haven't found a way to use this to cause the window to be displayed on all desktops. wmctrl -l shows -1 as the desktop number for windows which are displayed on all desktops, but passing -1 to -t doesn't work.

An unresolved fedora bug report seems to address this issue: apparently the -1 value is used internally by wmctrl, and for this reason cannot be passed to -t. The bug report also mentions window can be pinned with some window managers by giving the target window the sticky property. However, I'm running openbox and this approach does not seem to work for me. There is actually a patch posted to that bug report; I haven't tried using it. It is from 2009. I'd prefer to avoid patching wmctrl or anything else.

Is there another way to script this behaviour that will work under openbox?

Best Answer

Like a user said in the comments, wmctrl hasn't been touched since October 2005. Its very possible that the featured worked at the time, and has since been made broken due to packages changing around it.

Here's the wmctrl changelog