LuciadCPillar 2023.1.04
luciad::ArrowPatternBuilder Class Reference

Creates a pattern with an arrow shape. More...

#include <luciad/layers/styles/complexstrokes/builders/ArrowPatternBuilder.h>

Public Member Functions

ComplexStrokePattern build ()
 Build the arrow pattern as configured. More...
 
ArrowPatternBuilderfillColor (Color color)
 Sets the fill color. More...
 
ArrowPatternBuilderforward (bool forward)
 If true, the arrow is oriented towards the end of the line. More...
 
ArrowPatternBuilderheight (double height)
 The height of the arrow, in pixels. More...
 
ArrowPatternBuilderlineColor (Color color)
 Sets the line color. More...
 
ArrowPatternBuilderlineWidth (double lineWidth)
 Sets the line width. More...
 
ArrowPatternBuilderoffset (double offset)
 The offset of the arrow, relative to the base line, in pixels. More...
 
ArrowPatternBuildersize (double size)
 The size (~length) of the arrow, in pixels. More...
 
ArrowPatternBuildertype (ComplexStrokePatternArrowType type)
 Sets the arrow's type. More...
 

Detailed Description

Creates a pattern with an arrow shape.

See also
ComplexStrokePatternFactory::arrowBuilder()
Since
2023.1

Member Function Documentation

◆ build()

ComplexStrokePattern luciad::ArrowPatternBuilder::build ( )

Build the arrow pattern as configured.

Returns
the ComplexStrokePattern.

◆ fillColor()

ArrowPatternBuilder & luciad::ArrowPatternBuilder::fillColor ( Color  color)

Sets the fill color.

Parameters
colorthe arrow's fill color, defaults to white.
Returns
this builder.

◆ forward()

ArrowPatternBuilder & luciad::ArrowPatternBuilder::forward ( bool  forward)

If true, the arrow is oriented towards the end of the line.

Defaults to true.

Parameters
forwardwhether the arrow is oriented towards the end of the line.
Returns
this builder.

◆ height()

ArrowPatternBuilder & luciad::ArrowPatternBuilder::height ( double  height)

The height of the arrow, in pixels.

Must be strictly greater than 0. If it is not set, the arrow uses a default height, depending on the arrow type.

Parameters
heightthe height of the arrow.
Returns
this builder.
Exceptions
luciad::InvalidArgumentExceptionheight must be >0.

◆ lineColor()

ArrowPatternBuilder & luciad::ArrowPatternBuilder::lineColor ( Color  color)

Sets the line color.

Parameters
colorthe arrow's line color, defaults to black.
Returns
this builder.

◆ lineWidth()

ArrowPatternBuilder & luciad::ArrowPatternBuilder::lineWidth ( double  lineWidth)

Sets the line width.

Parameters
lineWidththe line's width, defaults to 1.
Returns
this builder.
Exceptions
luciad::InvalidArgumentExceptionlineWidth must be >0.

◆ offset()

ArrowPatternBuilder & luciad::ArrowPatternBuilder::offset ( double  offset)

The offset of the arrow, relative to the base line, in pixels.

Defaults to 0.

Parameters
offsetthe offset of the arrow.
Returns
this builder.

◆ size()

ArrowPatternBuilder & luciad::ArrowPatternBuilder::size ( double  size)

The size (~length) of the arrow, in pixels.

Defaults to 5.

Parameters
sizethe size of the arrow.
Returns
this builder.
Exceptions
luciad::InvalidArgumentExceptionsize must be >0.

◆ type()

ArrowPatternBuilder & luciad::ArrowPatternBuilder::type ( ComplexStrokePatternArrowType  type)

Sets the arrow's type.

Defaults to ArrowType.RegularFilled.

Parameters
typethe arrow's type.
Returns
this builder.