System.Drawing.Drawing2D.HatchBrush Class

Defines a rectangular brush with a hatch style, a foreground color, and a background color. This class cannot be inherited.

See Also: HatchBrush Members

Syntax

public sealed class HatchBrush : System.Drawing.Brush

Remarks

A hatch pattern is made from two colors: one defined by the HatchBrush.BackgroundColor, which fills the background and one for the lines that form the pattern over the background defined by the HatchBrush.ForegroundColor property. The HatchBrush.HatchStyle property defines what type of pattern the brush has and can be any value from the System.Drawing.Drawing2D.HatchStyle enumeration. There are more than fifty elements in the System.Drawing.Drawing2D.HatchStyle enumeration.

The following illustration shows an ellipse filled with a horizontal hatch pattern.

Requirements

Namespace: System.Drawing.Drawing2D
Assembly: System.Drawing (in System.Drawing.dll)
Assembly Versions: 1.0.3300.0, 1.0.5000.0, 2.0.0.0