Version 6.3.13 for Windows
 —  Programming Guide  —

Defining Color

You can define colors for dialogs and dialog elements. These can be foreground colors and background colors. To do this, you use the following attributes:

You can assign only standard colors to the attributes ending with NAME. The attributes ending on VALUE, however, can be assigned customized colors following the RGB model.

You can set colors:

You can directly assign a value to the attributes ending with NAME. If you want to assign a value to an attribute ending with VALUE, you must set the NAME attribute to the value CUSTOM. If you do not set the NAME attribute to the value CUSTOM, the VALUE attribute is ignored.

Examples:

#DIA.BACKGROUND-COLOUR-NAME:= MAGENTA     /* Assign a value to a NAME 
                                          /* attribute 
#DIA.BACKGROUND-COLOUR-NAME:= CUSTOM      /* Set NAME to CUSTOM 
#DIA.BACKGROUND-COLOUR-VALUE:= H'FF0000'  /* Then assign Red, Green, and 
                                          /* Blue values to the VALUE  
                                          /* attribute (hexadecimal)

Note:
You can not use all customized colors in all parts of the user interface. Colors in text, for example, must always be monochrome.

When setting a color in an attributes window, you have three possibilities:

Start of instruction setTo define a color

  1. Choose the Custom push-button control right of the Background color entry. A dialog box appears.

  2. Select one of the predefined colors or choose the Define Custom Colors push-button control. To set the red, green, and blue values, use the cursor to select the desired color or enter a value from 1 to 253 in the red, green, and blue value display fields.

  3. Choose the Add to Custom Color push button control. To save the newly defined color, choose the OK button in the dialog box. The newly defined color is now selected by default.

  4. To set it, close the attributes window.

Top of page