Programming with Reflection

image\rwnprg32.gif GetColorRGB method

 

Syntax ComponentValue = object.GetColorRGB(Color, WhichValue)

 

Description

Reflection creates displays using a palette of 16 colors. (You can view these colors in the Colors tab of the Display Setup dialog box.) Each color is defined using different values for three basic color components—red, green, and blue. This method returns the current value for a specific component of a particular color. For example, the following expression returns the current value of the blue component for cyan:

Session.GetColorRGB(rcCyan, rcBlue)

Use SetColorRGB to change the current color configuration for any color in the palette.

Arguments

Color Argument type: Enumeration
Required
Identifies one of the colors of the palette. (Note: If adjustments to a color have been made using either the Display Setup dialog box or the SetColorRGB method, a constant, such as rcRed, may no longer identify a red color.) The possible values are:

 rcWhite
rcGrey
rcRed
rcBlue
rcGreen
rcYellow
rcCyan
rcMagenta
rcBlack
rcDkGrey
rcDkRed
rcDkBlue
rcDkGreen
rcDkYellow
rcDkCyan
rcDkMagenta

WhichValue Argument type: Enumeration
Required
One of the three color components. The possible values are:

 rcRed
rcGreen
rcBlue

Return

ComponentValue Return type: Integer
The value for the specified component. This can be any value between 0 and 255 in Reflection for HP or Reflection for UNIX and OpenVMS. It can be any value between 0 and 100 in Reflection for ReGIS Graphics.

 

 

image\jump.gif Example

image\jump.gif Keyword Index

image\popup.gif Related Topics

image\popup.gif Reflection products that use this command