A shortcut key for hiding all visible windows on current workspace.
Created attachment 166 Patch to add requested functionality
Sorry, but show desktop is already implemented in xfwm4 and conforms to the EWMH specifications, it would be good to use that instead of a loop to hide all clients.
Created attachment 169 Improved version The shortcut keys now toggle showing of desktop, i.e. if there are visible windows they are hidden, otherwise windows are restored. For this I also modified clientToggleShowDesktop() (client.c:2195) to take current workspace into account. Does this break or violate some rules Xfce tries to conform to?
Created attachment 170 Hopefully EWMH compliant Hopefully this is now EWMH compliant. In current state this does have a slight defect, though. But I'm not alone, the show desktop panel plugin will also suffer of this defect if I've got it right... If windows are restored from taskbar instead of the shortcut key the _NET_SHOWING_DESKTOP hint won't get updated, so another press of "Show Desktop" will result in rest, if any, of the windows being restored instead of hiding the visible windows as one would expect. Perhaps I'll try to look in taskbar code in order to fix this.
I'm sorry, but that patch is wrong, it just duplicate code that is already is in xfwm4.
Sorry for my previous statement, I misread your code. I applied a slightly modified version to HEAD. Thanks! Olivier.