DrawMode Property (AForm)

Returns or sets the appearance of output for the graphics methods.

Syntax

Object.DrawMode [ = enFormDrawMode ]

The DrawMode property syntax has the following parts:

 

Name

Type

Description

Object

AForm

AForm object

enFormDrawMode

enumAFormDrawMode

An integer that determines the appearance of output for the graphics methods.

Where

enumAFormDrawMode:

 

Name

Value

Description

aformDrawModeBlackness

1 *

Blackness

aformDrawModeNotMergePen

2

Not Merge Pen

aformDrawModeMaskNotPen

3

Mask Not Pen

aformDrawModeNotCopyPen

4

Not Copy Pen

aformDrawModeMaskPenNot

5

Mask Pen Not

aformDrawModeInvert

6

Invert

aformDrawModeXorPen

7

Xor Pen

aformDrawModeNotMaskPen

8

Not Mask Pen

aformDrawModeMaskPen

9

Mask Pen

aformDrawModeNotXorPen

10

Not Xor Pen

aformDrawModeNop

11

Nop

aformDrawModeMergeNotPen

12

Merge Not Pen

aformDrawModeCopyPen

13

Copy Pen

aformDrawModeMergePenNot

14

Merge Pen Not

aformDrawModeMergePen

15

Merge Pen

aformDrawModeWhiteness

16

Whiteness

Comments

Use this property to produce visual effects with Shape or Line controls or when drawing with the graphics methods. Each pixel is compared in the draw pattern to the corresponding pixel in the existing background and then bit-wise operations are applied. For example, setting 7 (Xor Pen) uses the Xor operator to combine a draw pattern pixel with a background pixel.

The exact effect of a DrawMode setting depends on the way the color of a line drawn at run time combines with colors already on the screen. Settings 1, 6, 7, 11, 13, and 16 yield the most predictable results.

The property is not applicable for MDI Form type since drawing functions are not supported for MDI Forms.

Example

The following statement changes the AForm DrawMode to Blackness:

DrawMode=aformDrawModeBlackness

Applies to

AForm

See Also

DrawStyle, DrawWidth, FillStyle