14 Line styles

class line_style.T
This class defines the looks of line segments. This class supports the following attributes:

cap_style
Type: int Default: 0.

Defines the style of the tip of the line segment. 0: butt cap (square cutoff, with no projection beyond), 1: round cap (arc), 2: projecting square cap (square cutoff, but the line extends half the line width). See also Postscript/PDF reference manual.

color
Type: color.T ( see Section 15) Default: color.black.

The color of the line.

dash
Type: tuple Default: None.

The value of None will draw a solid line. Otherwise, this attribute specifies the style of dashed lines. The 2N'th value specifies the length of the line (in points), and 2N+1'th value specifies the length of the blank.

For example, the dash style of (3,2,4,1) draws a dashed line that looks like --__--_--__--_....

join_style
Type: int Default: 0.

Join style. 0: Miter join (sharp, pointed corners), 1: round join (rounded corners), 2: bevel join (flattened corners). See also Postscript/PDF reference manual.

width
Type: length in points (
xrefunit) Default: 0.4.

Width of the line, in points.

The below picture show standard line styles. These styles are referred to by names line_style.name, where name is the label below each item.

Image linestyles