Whereas the Brush classes are used to fill shapes, the Pen class is used to frame shapes. The interesting members are shown here:

 sealed class Pen : MarshalByRefObject, ICloneable, IDisposable { // Constructors public Pen(Brush brush); public Pen(Brush brush, float width); public Pen(Color color); public Pen(Color color, float width); // Properties public PenAlignment Alignment { get; set; } public Brush Brush { get; set; } public Color Color { get; set; } public float[] CompoundArray { get; set; } public CustomLineCap CustomEndCap { get; set; } public CustomLineCap CustomStartCap { get; set; } public DashCap DashCap { get; set; } public float DashOffset { get; set; } public float[] DashPattern { get; set; } public DashStyle DashStyle { ...

Get Windows Forms Programming in C# 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.