SetPen

<< Click to Display Table of Contents >>

Navigation:  Drawing Functions >

SetPen

Previous pageReturn to chapter overviewNext page

Sets the style of the pen - all properties at once. All drawing objects that are inherited from the pen-object will use the pen (see "The Object-Oriented Style" in the Programmer's Manual for details). The pen can be made invisible by setting the PenSize to 0.

You can use the psXyz pen styles from Windows GDI, but pen styles other than psSolid are limited by the GDI to pens with a size of 1 pixel under Win 3.x, 9x and ME. So you should always use psSolid until the GDI changes.

method void VPE.SetPen(

VpeCoord Size,

PenStyle [integer] Style,

Color Color

)

also supported by TVPEObject

VpeCoord Size

the thickness of the pen

PenStyle [integer] Style

possible values are:

ActiveX / VCL

Value

Enum

Comment

psSolid

0

Solid

 

psDash

1

Dash

-------

psDot

2

Dot

........

psDashDot

3

DashDot

_._._._

psDashDotDot

4

DashDotDot

_.._.._

Color Color

any of the "COLOR_xyz" constants described in Programmer's Manual

or ActiveX / VCL: any RGB value

or .NET: any member of the .NET Color structure

Default:

0.03 (which is 0.3 mm), psSolid, COLOR_BLACK