Color getByRGB

From Catglobe Wiki
Revision as of 11:13, 12 December 2011 by Cg huyphong (talk | contribs)
Jump to: navigation, search



Color_getByRGB

This function creates a color object that can be used in some of the other chart style setting functions.

Syntax

Color_getByRGB(number1, number2, number3)

Color_getByRGB(“hexadecimal”)

Arguments

number1, number2, number3: numbers (from 0 to 255) for red color, green color and blue color.

hexadecimal: is a hexadecimal value describing a color (a string).

Return type

Returns the following array

Constant

Type

Initial/Default value

Description

OBJECT_TYPE

Number

17

Enumeration for the type of object.

COLOR_RED

Number

As set in function

Color code between 0 and 255

COLOR_GREEN

Number

As set in function

Color code between 0 and 255

COLOR_BLUE

Number

As set in function

Color code between 0 and 255

Examples

array fill = Color_getByRGB(255, 255, 0); // Yellow

array fill = Color_getByRGB(“#000000”); // Black

Availability

Version 5.8.1