Subject: FVWM: FvwmButtons: ActiveColorset

From: Kai Kühne <[email-masked]>
Date: Thu, 24 Feb 2005 19:43:26 +0000

Hello list.

I have a button panel with several buttons.
Here a code snipplet:

*Panel: (3x1, Title(Side) " dillo", Left, Icon
$[fvwm_img_panel]/dillo.png, Action(Mouse 1) `Exec dillo`)

Now I want to change the colorset, when i hover the mouse over this location.
ActiveColorset works great, but I don't want this on _every_ button in my panel.

*Panel: (3x1, >> ActiveColorset 8, << Title(Side) " dillo", Left, Icon
$[fvwm_img_panel]/dillo.png, Action(Mouse 1) `Exec dillo`)

Doesn't work.
Has anybody an idea how i can do it?

Thank you very much,
Kai.
--
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: Scott Smedley <[email-masked]>
Date: Fri, 25 Feb 2005 11:23:58 +1100

Hi Kai,

> ActiveColorset works great, but I don't want this on _every_ button in my panel.

This feature is not currently implemented.

It is trivial to add - just need a new flag (IgnoreActiveColorset?) &
a few lines of code in buttonColorset() in FvwmButtons/button.c ... the
only catch is that we have run out of flags! Therefore, FvwmButtons
needs a bit of restructuring ... it's on my TODO list.

SCoTT. :)

---

From: Kai Kühne <[email-masked]>
Date: Fri, 25 Feb 2005 00:33:41 +0000

> It is trivial to add - just need a new flag (IgnoreActiveColorset?) 

Ah ok, I've searched for that option... hehe.
Thanks for implementing it.

> SCoTT. :)

Regards

---

From: Scott Smedley <[email-masked]>
Date: Sun, 27 Feb 2005 19:01:15 +1100

> > Now I want to change the colorset, when i hover the mouse over this
> > location. ActiveColorset works great, but I don't want this on _every_
> > button in my panel.
> 

This feature is now implemented (in CVS version of FVWM).

> It is trivial to add - just need a new flag (IgnoreActiveColorset?)

I choose to add 2 new options for _individual_ buttons:
 * PressColorset
 * ActiveColorset

These options (when specified for an individual button) take precedence
over any global option setting (of the same name).

To get the effect you describe above, use a Transparent colorset.

ie.
Colorset 21 fg darkorange, bg green
Colorset 22 Transparent
*MyButtonbar: : ActiveColorset 21
...
*MyButtonbar(Title Button1, Action Echo button1)
*MyButtonbar(Title Button2, Action Echo butto21)
*MyButtonbar(Title TestButton, ActiveColorset 22, Action Echo testing)

This feature is flexible enough to allow you to have a different
highlight color (ActiveColorset) for each button. (if you were mad
enough to desire such an effect!)

> only catch is that we have run out of flags!

The 'flags' field was converted from a 32-bit field to a proper C
struct so now we can add as many new flags as we like.

SCoTT. :)