## HatchBrush class

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

```csharp
public sealed class HatchBrush : Brush
```

## Constructors

| Name | Description |
| --- | --- |
| [HatchBrush](hatchbrush/#constructor)(HatchStyle, Color) | Initializes a new instance of the `HatchBrush` class with the specified HatchStyle enumeration and foreground color. |
| [HatchBrush](hatchbrush/#constructor_1)(HatchStyle, Color, Color) | Initializes a new instance of the `HatchBrush` class with the specified HatchStyle enumeration, foreground color, and background color. |

## Properties

| Name | Description |
| --- | --- |
| [BackgroundColor](../../system.drawing.drawing2d/hatchbrush/backgroundcolor/) { get; } | Gets the color of spaces between the hatch lines drawn by this HatchBrush object. |
| [ForegroundColor](../../system.drawing.drawing2d/hatchbrush/foregroundcolor/) { get; } | Gets the color of hatch lines drawn by this HatchBrush object. |
| [HatchStyle](../../system.drawing.drawing2d/hatchbrush/hatchstyle/) { get; } | Gets the hatch style of this HatchBrush object. |

## Methods

| Name | Description |
| --- | --- |
| override [Clone](../../system.drawing.drawing2d/hatchbrush/clone/)() | Creates an exact copy of this HatchBrush object. |
| [Dispose](../../system.drawing/brush/dispose/)() | Releases all resources used by this Brush object. |

### See Also

* class [Brush](../../system.drawing/brush/)
* namespace [System.Drawing.Drawing2D](../../system.drawing.drawing2d/)
* assembly [Aspose.Drawing](../../)


