AW: Convert rgb to lightness or darkness

Tiemo Hollmann TB toolbook at
Wed Oct 8 04:21:37 EDT 2014

Just a guess, didn't tried it.
If you add the three RGB values of the mousecolor, white (light) would be
765 and black (dark) 0. Somewhere around 382 you can switch from black to
yellow text.

> -----Ursprüngliche Nachricht-----
> Von: use-livecode [mailto:use-livecode-bounces at] Im
> von William Prothero
> Gesendet: Dienstag, 7. Oktober 2014 21:59
> An: Use-livecode Use-livecode
> Betreff: Convert rgb to lightness or darkness
> Folks:
> I’m putting text on an image that will be turned into a snapshot. The
> goes from light to dark. The text is a one or two digit integer. I want it
> show up on the image. For dark parts of the image, I set it to yellow, but
> light parts of the image, I want to set it to black. Is there a simple
> for changing an rgb value into a darkness value that will let me choose
> between yellow or black text?  I don’t want to just set the ink of the
> because sometimes I write the text over itself, which diminishes the
> Thanks,
> Bill
> William A. Prothero
> _______________________________________________
> use-livecode mailing list
> use-livecode at
> Please visit this url to subscribe, unsubscribe and manage your
> preferences:

More information about the use-livecode mailing list