Brush.property

Description

Settings for the fill pattern and color of a graphic control.

Applies to

Oval, Rectangle, and RoundRectangle controls

Syntax

Describe and Modify argument:

"controlname.Brush.property { = ' value ' }"

Parameter

Description

controlname

The name of the Line, Oval, Rectangle, RoundRectangle, or Text control whose Brush property you want to get or set.

property

A property that applies to the Brush characteristics of a control, as listed in the table below.

value

Values for the properties are shown in the next table. Value can be a quoted DataWindow expression.

Property for Brush

Value

Color

(exp) A long expression specifying the color (the red, green, and blue values) to be used to fill the control.

Hatch

(exp) A number expression specifying the fill pattern of controlname.

Values are:

  • 0 – Horizontal

  • 1 – Bdiagonal (lines from lower left to upper right)

  • 2 – Vertical

  • 3 – Cross

  • 4 – Fdiagonal (lines from upper left to lower right)

  • 5 – DiagCross

  • 6 – Solid

  • 7 – Transparent

  • 8 - Background (use the settings on the Background tab)

Usage


In the painter

Select the control and set the value in the Properties view, General tab.

When you choose a Brush Hatch fill pattern other than Solid or Transparent, the Background Color and the Brush Color are used for the pattern colors.

Examples

Example 1

ls_data = dw1.Describe("oval_1.Brush.Hatch")

dw1.Modify("oval_1.Brush.Hatch='5'")

dw1.Modify("oval_1.Brush.Color='16731766'")