On Sat, Jun 03, 2000 at 04:55:53AM +0200, Dominik Vogt wrote:
> On Fri, Jun 02, 2000 at 05:35:00PM -0600, sa_at_space.itacs.to wrote:
> > Hello Everone,
> > 
> > I am trying to make a fvwm function, and I need some guidance. 
> > I want it to raise and move my clock to the center of the 
> > screen, then move it back when I run the function again. This 
> > is what I've got right now:
> > 
> > Key c  A   MC  SeeHideFunc "2.1.10*"
> > # "2.1.10*" is the title of my clock.
> > 
> > DestroyFunc SeeFunc
> > AddToFunc SeeFunc
> > + I All ($0)         Raise
> > + I All ($0)         AnimatedMove +44 +44
> > + I All ($0)         Stick
> > 
> > DestroyFunc HideFunc
> > AddToFunc HideFunc
> > + I All ($0)         Lower
> > + I All ($0)         AnimatedMove -0 -0
> > + I All ($0)         Stick
> > 
> > DestroyFunc SeeHideFunc
> > AddToFunc SeeHideFunc
> > + I All ($0, "!Sticky")   HideFunc $0
> > + I All ($0, "Sticky")    SeeFunc  $0
> > 
> > The problem is: SeeHideFunc executes HideFunc AND SeeFunc. Is there a
> > way to only execute one? Or is there a better way do write my function?
> 
> Remove the line
> 
>   + I All ($0)         Stick
> 
> from the SeeFunc and the HideFunc and add it to SeeHideFunc
> instead.  Also, I think the syntax of the condition is incorrect.
> I think you may not use a comma to separate conditions.
> 
>   DestroyFunc SeeFunc
>   AddToFunc SeeFunc
>   + I All ($0)         Raise
>   + I All ($0)         AnimatedMove +44 +44
> 
>   DestroyFunc HideFunc
>   AddToFunc HideFunc
>   + I All ($0)         Lower
>   + I All ($0)         AnimatedMove -0 -0
> 
>   DestroyFunc SeeHideFunc
>   AddToFunc SeeHideFunc
>   + I All ($0 "!Sticky")   HideFunc $0
>   + I All ($0 "Sticky")    SeeFunc  $0
>   + I All ($0)         Stick
> 
> Bye
> 
> Dominik ^_^
>
 
Ahh, thanks this is much better than what I came up with. 
BTW, the man page says:
      All [(conditions)] command
              Execute.  command on all windows meeting the condi<AD>
              tions.   Conditions  are  used  exactly as with the
              Current command.
      Current [(condition...)] command
              Performs command on the currently focused window if
              it  satisfies all conditions.  The contidions are a
              list of keywords from the list below and are  sepa<AD>
              rated  by commas or whitespace. 
                        ^^^^^^
Thanks,
sa
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to majordomo_at_fvwm.org.
To report problems, send mail to fvwm-owner_at_fvwm.org.
Received on Sat Jun 03 2000 - 08:28:43 BST