opening applications on startup on different desks


i am so happy to finally have found this forum. i use fvwm quite some time, not toying around a lot with my configuration, coz i am quite happy with it. but for some things i did not find the solution jet and the man pages did not help. and, as i copy/pasted a lot when i created my fvwm2rc 2 years ago, i am not sure, if i understand things correctly

one of them is that i have some applications opening on startup. that works via a StartFunction

+ I exec mozilla-firefox etc
but how to make them opening on different desks ?
i tried

[code]+ I exec Eterm StartsOnDesk 4

  • I exec Eterm StartsOnPage 4
  • I exec Eterm StartsOnDesk 0 4[/code]

as well as defining Style:

Style firefox StartsOnDesk 4 Style firefox StartsOnPage 4 Style firefox StartsOnDesk 0 4

coz i am not sure how and where i define if i use desks or pages - forgot the difference, but as i switch them with

Key 1 A CM GotoDesk 0 0

it must be desks, no ?

but still every startup-application starts on the desk 0 0
why ?

thnx morlaa

I didn’t toy with it, so I don’t know if this is the solution, but you might find some usefull info here:


thnax, i saw that thread - the idea of using style comes from there. but it does not help me to find out why it is not working on my comp…

You are using the correct classname for firefox, aren’t you? It’s “Firefox-bin” for me, you can use the FvwmIdent module to find out the classname of windows :slight_smile:

Right – the “StartsOn{Desk,Page}” stuff can only be done via style lines (although re-read the thread that Johan pointed you at, as I have explained it enough there).

Yes, these are the lines that you want – but remember that in this instance, the LAST style line as you have it there will get used. Remember that a “Desk” is just a container for a number of “Pages” (again, the main FVWM FAQ explains the difference between them.)

In the first instance, yes – but the second number will also switch to that specified PAGE as well.

Because you’re misunderstanding how things relate. Take Firefox (I have explained this in another thread, BTW). That will either have a class of:




The reason you want to match on a window’s class in this instance is that it’s more specific, and less ambiguous than the title of the window, which might be something like this:

“Fvwm Forums :: Post a reply - Mozilla Firefox”.

Of course, some people would naturally match by title, and try a command such as:

Style *Firefox* StartsOnPage 0 4

… but this has some issues with it. Since you’re matching firefox anywhere in the title, it could match erroneous windows, or ones you don’t want. So the next thing to try is to match by “Class”. To obtain a specific window’s class, you can use a few methods. Perhaps the preferred option is using the module “FvwmIdent”. Although window manager agnostic commands such as “xwininfo” and “xprop” can also be used. Hence, you’d replace the previous style command with:

Style Gecko StartsOnPage 0 4

… you can be fairly well assured that the Class of a window tends to be unique to that application (the exceptions are things like RXVT which sometimes have been known to set their class to that of Xterm.)

Indeed, you might be wondering how style lines know in which order to match. Truth is, they don’t really know how to match, however FVWM defaults to cycling through a known series of window attributes. Hence, FVWM will match your window name in a style command thus:

Title --> Class --> Resource

So it checks the title of a window first, and if a match is unsuccessful, it will then look at the class, and if that fails, it will then look at the resource of that window for a match. By and large, where wildcards are used in style lines – it’s normally the window’s title that gets matched in the first instance.

One thing I’d love to see in a future version of FVWM is something like:

Style (class=Xterm, title=foo) StartsOnPage 0 4

… which would really be quite powerful.

I hope this helps.

– Thomas Adam

cool, that helps a lot.
Did not know about this class thing - i thought the path-name - /usr/bin/firefox - would be enough.
learnt something, thank you 8)

You’re welcome, of course. But I am unclear as to what you mean by using the pathname as matching the window title – no version of Mozilla or Firefox I have used ever puts the full path as the window’s title.

– Thomas Adam

I think he thought Fvwm determined with application a window belongs to by the binary, which of course, is not the case.

That is listed in the todo list for fvwm 3.0 (I guess it’s still a long way until we get there)

Yes, I know it’s listed in the to-do list. FVWM3 is a long way off yet. there’s several milestones to be reached once FVWM 2.6 hits the 'net.

– Thomas Adam