Color Constructor | |
Construct a color
Namespace:
VO
Assembly:
VOGUIClasses (in VOGUIClasses.dll) Version: 2.21
Syntax CONSTRUCTOR(
nRed,
nGreen,
nBlue
) CLIPPER
[ClipperCallingConventionAttribute(new string[] { ... })]
public Color(
Usual nRed = default,
Usual nGreen = default,
Usual nBlue = default
)
Request Example
View SourceParameters
- nRed (Optional)
- Type: Usual
The amount of red to be used to create the color. This can be a value between 0 (lowest intensity) and 255 (highest intensity). The default value is 0.
- nGreen (Optional)
- Type: Usual
The amount of green to be used to create the color. This can be a value between 0 (lowest intensity) and 255 (highest intensity). The default value is 0.
- nBlue (Optional)
- Type: Usual
The amount of blue to be used to create the color. This can be a value between 0 (lowest intensity) and 255 (highest intensity). The default value is 0.
Remarks
If the first and second argument are both numeric and the second argument is -1, VO will treat the first number as the colorref of the color object.
In that case the first number indicates the standard color to create, specified as one of the following constants:
Constant | Color |
---|
COLORBLACK | Black |
COLORBLUE | Blue |
COLORCYAN | Cyan |
COLORGREEN | Green |
COLORMAGENTA | Magenta |
COLORRED | Red |
COLORWHITE | White |
COLORYELLOW | Yellow |
Examples
The following example defines some colors:
1oRed := Color{COLORRED}
2oWhite := Color{ 255, 255, 255}
3oMediumAquamarine := Color{ 50, 204, 153}
4oBlack := Color{ 0, 0, 0}
5oBlue := Color{ 0, 0, 255}
6oCadetBlue := Color{ 95, 159, 159}
7oCornflowerBlue := Color{ 66, 66, 111}
8oDarkSlateBlue := Color{ 107, 35, 142}
See Also