Solved CWM autogroup workings?

Hi,

I'm using wm/cwm a lot and am optimizing my .cwmrc. The 'autogroup' setting however is somekind of a mystery to me.

Programs are set in some autogroup, eg.:
Code:
autogroup 5 gimp,inkscape

When starting gimp (through cwm-menu, d-menu or key-bind) in any of the groups, the window opens where it is started -- left mouse button list of active windows shows the group the program is in.

I'd expect (here) the gimp window to be only opened in group 5, but that's not the fact.

Hope anyone can enlighten me on how this works.

BTW, I tried putting the program names between quotation marks " but to no effect.

TIA,
 
According to the manpage, the syntax is :
Code:
autogroup group [windowname,]windowclass

So for gimp, you would add:
Code:
autogroup 5 gimp,Gimp
or
Code:
autogroup 5 Gimp

You would use a separate line for inkscape.
 
TNX, this helps a lot and works for GUI programs.

'Next level' challenge is how to fit CLI programs like mutt and vim into this and direct them to their given autogroup. Preferably with standard settings -- that means to avoid calling third programs or writing additional scripts...

xprop | grep WM_CLASS only gives "xterm", "XTerm" for CLI programs running within. The WM_NAME (STRING) gives the proper CLI program name that is running, but that doesn't direct to the right autogroup in x11/cwm.

Now x11/xterm has the option to change the WM_CLASS with the -class option. After experimenting it seems that the class option has to come before calling the program.

By setting xterm -class <program_name> -e <program> in my .cwmcr, the autogroup works as intended.

Remember to change all instances of menu commands and key-binds in your .cwmcr and restart CWM CMS-r.

-- learned a lot on this sunny Sunday morning ! Hope this helps others too using the clutterless power of CWM.
 
Back
Top