Main Page
Using the Pens and Brushes Classes
When you draw using the Graphics class's methods, you need to supply a Pen object. Rather than creating a pen from scratch, you can use a predefined pen from the Pens class. These pens have a width of one pixel, and you can refer to them as Pens.ForestGreen, Pens.LightSeaGreen, and so on. And instead of creating a brush from scratch, you can use a solid color brush from the Brushes class like this: Brushes.Coral,Brushes.Moccasin, and so on. The possible colors for use with these classes appear in Table 13.6.