Undecorate / Decorate ignored

I’m trying to decorate / undecorate windows using Devil’s Pie, i.e. remove their title bar and resize handles. Example script:

(if (is (window_class) "Firefox")
    (begin (undecorate)
           (geometry "2592x1620-0+0")))

The geometry command works, but undecorate is ignored by FVWM.

Any workaround?

Background: I want to script window decoration and placement depending on some complex rules. For example, I want to have the first Firefox window be full screen, and without decorations, and all subsequent Firefox windows should be floating on top, with decorations. I think with FVWM alone this cannot be done.

Well, I think it can all be done with FVWM.

Only I ran into what looks like a bug. Here’s a simple configuration, that makes a new xterm window stay on top, and only if there are not already any windows on top:

Module FvwmEvent

AddToFunc MyUpdate
+ I WindowStyle StaysOnTop

AddToFunc MyUpdateIfXterm
+ I Current ("XTerm") MyUpdate

AddToFunc MyUpdateIfLayer6Empty
+ I None (Layer 6) MyUpdateIfXterm

*FvwmEvent: Cmd
*FvwmEvent: add_window MyUpdateIfLayer6Empty

Style * ClickToFocus

This works fine, until I also remove the title bar by changing line 4:

+ I WindowStyle StaysOnTop, NoTitle

Now, the window is not moved to the top anymore.

See also my post on unix.stackexchange.com

Can anyone confirm the problem?

Found a workaround, by adding a second event handler:

AddToFunc MyRemoveTitleInLayer6
+ I All (Layer 6) WindowStyle NoTitle

*FvwmEvent: raise_window MyRemoveTitleInLayer6