gradient background

Dar Scott dsc at swcp.com
Mon Jul 21 14:39:01 EDT 2003


On Monday, July 21, 2003, at 10:15 AM, rtamesis at cox.net wrote:

> I want to create a gradient background for my stack without having to 
> import an image for that purpose. Can anyone tell me how to accomplish 
> this?

One approach: Group an image.  Set the backgroundBehavior to true.  
Make a group handler that makes sure the image size is right (a little 
hand waving, here) computes the gradient, builds an imageData string 
and sets the imageData of the image.  Perhaps it is based on custom 
properties and stack size.  At design time run the handler using the 
"Send Message" submenu on the context menu.  If it is fast enough, you 
might be able to do this at run time.  You might get bands; maybe 
adding a little noise before rounding to color values will help.

Dar Scott




More information about the use-livecode mailing list