API Documentation > CorelDRAW > 2025-v26 > HatchFill > IVGHatchFill
HatchFill.AddPattern method
Adds a new pattern to the hatch
Syntax:
Function AddPattern(ByVal Angle As Double, ByVal Spacing As Double, Optional ByVal Shift As Double = 0, Optional ByVal OriginX As Double = 0, Optional ByVal OriginY As Double = 0, Optional ByVal Width As Double = -1, Optional ByVal Color As Color = Nothing, Optional ByVal Style As OutlineStyle = Nothing, Optional ByVal DashDotLength As Double = -1, Optional ByVal PenWidth As Double = 0) As HatchPattern
Parameters:
Name Type Description
Angle
Double
Spacing
Double
Shift
Double
Specifies an additional relative horizontal shift of the lines in the hatch-fill pattern.
OriginX
Double
Specifies the horizontal offset of the start of the first line in the hatch-fill pattern.
OriginY
Double
Specifies the vertical offset of the start of the first line in the hatch-fill pattern.
Width
Double
Specifies the width at which to apply the hatch fill.
Color
Specifies the color for the hatch fill.
Style
Specifies the outline style for the hatch fill.
DashDotLength
Double
Specifies the dash-dot length of the lines in the hatch fill.
PenWidth
Double
Specifies the pen width of the lines in the hatch fill.
Remarks:
The AddPattern method adds a new pattern to the hatch.