SVGBuilderExtensions.AddPattern

AddPattern<TBuilder>(this TBuilder, CoordinateUnits?, CoordinateUnits?, string, string, Action<SVGPatternElementBuilder>)

Adds a ‘pattern’ element to the SVG builder, specifying the coordinate system and units for the pattern’s content.

public static TBuilder AddPattern<TBuilder>(this TBuilder builder, CoordinateUnits? patternUnits, 
    CoordinateUnits? patternContentUnits, string href = null, string id = null, 
    Action<SVGPatternElementBuilder> extend = null)
    where TBuilder : ISVGElementBuilder, IShapeElementBuilder
ParameterDescription
TBuilderThe type of the SVG element builder, facilitating fluent API usage.
builderThe SVG builder instance to which the ‘pattern’ element will be added.
patternUnitsSpecifies the coordinate system for the pattern. Optional parameter.
patternContentUnitsSpecifies the coordinate system for the content within the pattern. Optional parameter.
hrefThe reference to another pattern, if applicable. Optional parameter.
idThe unique identifier for the pattern element. Optional parameter.
extendAn optional action to further configure the pattern element builder.

Return Value

The builder instance, allowing for method chaining.

See Also


AddPattern<TBuilder>(this TBuilder, Action<SVGPatternElementBuilder>)

Adds a ‘pattern’ element configuration to the builder.

public static TBuilder AddPattern<TBuilder>(this TBuilder builder, 
    Action<SVGPatternElementBuilder> configure)
    where TBuilder : ISVGElementBuilder, IPaintServerElementBuilder
ParameterDescription
TBuilderThe type of the SVG element builder.
builderThe builder instance.
configureThe configuration action for the ‘pattern’ element.

Return Value

The builder instance for chaining.

See Also