9.1. Line Caps and Line Styles
In previous chapters we saw how to draw lines and curves using Draw-Line, DrawCurve, and related methods of the Graphics class. In these cases we drew only solid lines and curves. Lines and curves can also have styles. For example, you can draw a dotted line with circular caps.
A line has three parts: the line body, starting cap, and ending cap. The line starts with a starting cap and ends with an ending cap. The part that connects these two caps is the line body. The caps and body of a line can have different styles. Figure 9.1 shows two lines with different starting and ending cap and body styles.
Figure 9.1. Lines with different starting cap, ending cap, and dash styles
The ends of a line can have different ...
Get Graphics Programming with GDI+ now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.