Setting color, line width, and style
You can use the Pen(Mode, Value) method to set the color, line width, and style of your drawings.
Setting a color
Use the following syntax to set the color:
Pen('Color','<ColorName>');
Where <ColorName> is the name of the color you want to use.
Example
Pen('Color','Blue');
Alternatively, you can use the PenColor method:
PenColor('Blue');
Setting line width
Use the following syntax to set the line width:
Pen('Width','<LineWidthValue>');
Where <LineWidthValue> is the thickness of the line.
Example
Pen('Width','3');
Alternatively, you can use the PenWidth method:
PenWidth('3')
Setting line style
Use the following syntax to set the line style:
Pen('Style','<StyleValue>');
Where <StyleValue> can take one of the following values:
- Solid. Specifies to use solid line.
- Dash. Specifies to use dashes.
- Dot. Specifies to use dots.
- DashDot. Specifies to use alternating dashes and dots.
- DashDotDot. Specifies to use a series of dash-dot-dot combinations.
- Clear. Specifies that no line is used. Use this value to omit the line around shapes that draw an outline using the current pen.
Examples
Pen('Style','Dot');
Pen('Style','Solid');
Pen('Style','Clear');