[Use-revolution] Re: Button colors

Jeanne A. E. DeVoto jeanne at runrev.com
Sat Nov 24 16:07:01 EST 2001

At 5:08 AM -0800 11/24/2001, Neil Phillips wrote:
>I can't seem to get the colors to work properly for buttons in Revolution
>1.1. The colors work properly in version 1.0. In 1.1 I can set the
>foreground color ok but the other colors cannot be set by the Colors and
>Patterns palette or by a script. I've tried it out on a blue and white G3
>running System 9.04 and a G4 Cube running System 9.1. Both machines have
>plenty of ram.
>Field colors can be set ok.
>Is this a bug or am I missing something?

What's going on is that with the new Appearance Manager support, standard
buttons are now drawn using the Mac OS appearance routines. Those routines
control the button appearance, so the only thing a script can control in
them is the text color.

You can do one of the following:

- Change the lookAndFeel to "Macintosh" instead of "Appearance Manager" (or
choose from the Look and Feel submenu in the View menu).

- Set the button's style to rectangle or roundRect intead of standard.

Doing either or both of these will cause the button to be drawn by
Revolution instead of by the operating system routines, allowing you to
color it.

Jeanne A. E. DeVoto ~ jeanne at runrev.com
Runtime Revolution Limited - Power to the Developer!

More information about the use-livecode mailing list