On Wed, Mar 17, 2010 at 11:16:09PM +0000, Thomas Adam wrote: > On Wed, Mar 17, 2010 at 10:10:35PM +0000, David Chanters wrote: > > On 17 March 2010 22:00, <des...@verizon.net> wrote: > > > The way I understand your request, you are asking for Fvwm to > > > un-minimize windows on a restart. > > > > or any window that id used initialmapcommand on - it was useful if id > > done something to these windows to put them in their original state > > when restarting fvwm > > Well, you could cheat. If you knew you had groups of windows which you had > toggleable actions on, such as Iconify and Maximize, then you could make use > of State to assign those actions, such as: > > Style foo State 1, InitialMapCommand Iconify > Style bar State 2, InitialMapCommand Maximize > > AddToFunc StartFunction > + I Test (Init) Exec exec foo > + I Test (Init) Exec exec bar > + I Test (Init) Break > + I All (State 2) Iconify > + I All (State 3) Maximize
s/State 2/State 1/ s/State 3/State 2/ Sorry about that, I got ahead of myself. :P > So, any windows with State 1, will be uniconified on restart, otherwise they > start iconic. Likewise for State 2, for unmaximizing windows on restart. > > There are timing issues here in terms of foo and bar starting up before the > "Break" statement runs -- see the wiki on FunctionSynchronisation on how to > potentially solve this. But ought not to be too much of a problem. > > Ideally, a more stateful approach using WindowStyle might be appropriate, > but it won't work since when the window is recaptured by FVWM on restart, > the same windowid is used, as the window is already mapped. Obviously. -- Thomas Adam -- "It was the cruelest game I've ever played and it's played inside my head." -- "Hush The Warmth", Gorky's Zygotic Mynci.