Subject: FVWM: Trigger function for switch decor

From: "Viktor Vislobokov" <[email-masked]>
Date: Mon, 15 Mar 2004 09:43:43 +0500

Hello All.

   I have a problem with fvwm 2.5.9.
   In order Windooze behavior emulation, I try to change pixmap over
maximize button while a window coming maximizing. I have two decors: 
first with icon1.xpm over maximize button and second with icon2.xpm over
maximize button.
    I wrote function MaxFunction as follow:

AddToFunc MaxFunction
+ I ChangeDecor Decor1
+ I TestRc (Maximized) ChangeDecor Decor2

   I bound this function on press maximize button event.

   At result: while a window maximized, it decor is changed, but
while the window unmaximized, it decor is not changed. There is
stay icon2.xpm over maximize button.

   Where are I wrong?

-- 
С уважением, Виктор

--
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 [email-masked].
To report problems, send mail to [email-masked].

---

From: Mikhael Goikhman <[email-masked]>
Date: Mon, 15 Mar 2004 07:19:17 +0000

> + I TestRc (Maximized) ChangeDecor Decor2

This is incorrect. TestRc is only valid after conditional commands
and it only accepts currently "Match", "NoMatch" and "Error" values.
You probably want:

  ThisWindow (Maximized) ChangeDecor Decor2

or maybe:

  ThisWindow (Maximized) ChangeDecor Decor1
  TestRc (!Match) ChangeDecor Decor2

> stay icon2.xpm over maximize button.

Also consider not to use ChangeDecor if you can, since it may disapper,
but something like "WindowStyle Font xxx, Colorset nn, HandleWidth n".

Regards,
Mikhael.

---

From: "Viktor Vislobokov" <[email-masked]>
Date: Tue, 16 Mar 2004 08:32:35 +0500

>   ThisWindow (Maximized) ChangeDecor Decor2

    Thanks. This work perfectly.

> but something like "WindowStyle Font xxx, Colorset nn, HandleWidth n".

    Hmm. I'll be try.

-- 
With best wishes,
Victor Vislobokov
Perm, Russia