Here's a tint function from way back. pRGB is an RGB triplet, pValue is a
decimal percent value for the desired tint of the color.
function colorTint pRGB, pValue
-- pRGB is RGB triplet
-- pValue is between 0 and 1
put pRGB into theTint
repeat with N = 1 to 3
put item N of pRGB into theColorItem
put round ((1- pValue) * theColorItem + (pValue * 255)) into item N
of theTint
end repeat
return theTint
end colorTint
Regards,
Scott Rossi
Creative Director
Tactile Media, UX/UI Design
On 9/10/16, 3:00 PM, "use-livecode on behalf of Dr. Hawkins"
<[email protected] on behalf of [email protected]>
wrote:
>I am adding the ability to have multiple clients open, and want to use
>colors as a cue.
>
>Is there a way to "lighten" a color. That is (I suppose), to grab the
>numeric representation, and convert that to a much paler shade of the
>color?
>
>--
>Dr. Richard E. Hawkins, Esq.
>(702) 508-8462
>_______________________________________________
>use-livecode mailing list
>[email protected]
>Please visit this url to subscribe, unsubscribe and manage your
>subscription preferences:
>http://lists.runrev.com/mailman/listinfo/use-livecode
_______________________________________________
use-livecode mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode