|Navigation: Templates > Guide to all Templates > Additional Libraries and Templates > MenuStyleManager Class > MenuStyleManager Methods >====== MixColors (mix two colors) ======|
MixColors( Color1, Color2, Percentage ),LONG
|Color1||A LONG value that represents a valid RGB composite color to be mixed with the second color (color1)|
|Color2||A LONG value that represents a valid RGB composite color to be mixed with the first color (color1)|
|percentage||A BYTE value that represents the percentage of mix applied to the two colors.|
The MixColors method is a PROTECTED method used to calculate and return a composite mix of two colors with a given percentage of mix.
Each color passed to this method is a RGB composite color extracted as follows:
The mixing of colors is applied using the following formula to all RGB elements:
(RGBT1.R + 1)
Return Value: LONG
The MIxColors method is used by the SetThemeColors method to detect and set the proper theme menu style color based on the active theme detected.