www.icetips.com  Icetips Utilities Documentation 12/16/2014    

Utility Class: ColorToRGB

Previous  Top  Next  


Prototype: (Long pColor, <*Long pRed>,<*Long pGreen>, <*Long pBlue>)

 

pColorColor to split into RGB
pRedOptional parameter to return the Red color
pGreenOptional parameter to return the Green color
pBlueOptional parameter to return the Blue color

 

This method takes a Clarion color and splits it into Red, Green and Blue values.

 

Example:

ITU  ITUtilityClass

R   LONG

G   LONG

B   LONG

Col LONG

CODE

Col = COLOR:Red

ITU.ColorToRGB(Col, R, G, B)

IF ITU.RGBToColor(R, G, B) <> Col

   MESSAGE('Something is wrong, color is not returned correctly')

ELSE

   MESSAGE('Got the correct color back!')

END

 

 

See also:

ColorToHTML

RGBToColor

RGBToHSL

 



Direct link to this page: http://www.icetips.com/manuals/utilities/colortorgb_utility.htm