How to conditionally apply styles?

Here’s what I want to do:

I have a lot of Eterms hanging around and I’d like to differentiate between them based on their title, I’ve got one name “Fvwm Console” and I’d like it to look other than the rest, but I can’t seem to find any way to do it…

I’v already tried something like this:

Style All ("Eterm", "Fvwm Console") TitleAtRight

But that doesn’t seem to work…

Any help, suggestions or links to possible solutions are greatly appreciated.


You probably wanted something like this:

Style "Eterm" TitleAtRight
Style "Fvwm Console" TitleAtRight

I think you can only use the All keyword from a function or something…

Not quite. What you actually want is something like this:

All (CurrentDesk, !Iconic) ThisWindow ("rxvt") WindowStyle TitleAtRight

Of course, the options you apply inside “All” are entirely upto you. :slight_smile:


– Thomas Adam

But wouldn’t that only be applied when the config was loaded? So if there were no windows up at the time the line is executed, then there would be no match and the window style wouldn’t be applied to anything…?

Yes – so either you use:

Style <some_unique_window_name> TitleAtRight

Or you use FvwmEvent and apply the condition to any windows mapped at that time.

– Thomas Adam