WinStudio

Creating and Applying a Background Color Definition Variable

To ensure consistency and "same-look-and-feel" across a variety of forms and components, you can create and apply a set of standard color definition variables for the forms and components in your application. These color definition variables are created and maintained using the Edit Color dialog box. Once created, these background color definition variables are available for use in other forms and components.

NOTES:

To create and apply a new color definition variable (and add it to a list of existing color definition variables):

  1. Open a form in Design Mode.
  2. On the Form/Collections property sheet, select the Form tab or the component to which you want to apply the background color definition.
  3. In the property sheet Appearance group, select the Background Color property.
  4. In the right margin, to open the Edit Color dialog box, click the ellipsis (...) button.
  5. In the Edit Color dialog box, select one of these options:
  6. In the WinStudio Designer dialog box, specify the name for the new color definition variable.
  7. NOTE: When specifying the name, you need not provide the "gbgc_" prefix to the variable name. WinStudio supplies that prefix automatically.  

  8. Click OK.
  9. Use the buttons and fields in the Color group box to specify:
  10. When you have the color definition specified to your satisfaction, click OK.

NOTE: Whatever the settings are when you click OK becomes the color definition for this variable. To change the color definition later, open the Edit Color dialog box, adjust the settings, and again click OK. Changing the color definition variable this way does not change previous uses of the variable, only future assignments.

WinStudio immediately applies the color definition to the form background or the designated component. If you do not immediately see the change, you can click elsewhere on the form to refresh the view.

Notice that the Background Color property field displays "V(gbgc_variableName), and the Ext. Color attribute fields are populated with the values as specified in the color definition.


Related Topics

About Setting Form and Component Background Colors

Edit Color Dialog Box

Selecting and Applying a Background Color Definition Variable

Background Color Property