Edit this page

StrokeOptions

Shape stroke configuration options.

Fields

color String

The stroke color in any of the following formats.

Value Description
red Basic or Extended CSS Color name
#ff0000 Hex RGB value
rgb(255, 0, 0) RGB value

Specifying 'none', 'transparent' or '' (empty string) will clear the stroke.

dashType String (default: "solid")

The stroke dash type.

Value Description
dash dash a line consisting of dashes
dashDot dash a line consisting of a repeating pattern of dash-dot
dot dash a line consisting of dots
longDash dash a line consisting of a repeating pattern of long-dash
longDashDot dash a line consisting of a repeating pattern of long-dash dot
longDashDotDot dash a line consisting of a repeating pattern of long-dash dot-dot
solid dash a solid line

lineCap String (default: "butt")

The stroke line cap style.

Value Description
butt dash a flat edge with no cap
round dash a rounded cap
square dash a square cap

lineJoin String (default: "miter")

The stroke line join style.

Value Description
bevel dash a beveled join
miter dash a square join
round dash a rounded join

opacity Number

The stroke opacity. Ranges from 0 (completely transparent) to 1 (completely opaque).

width Number

The stroke width in pixels.

Is this article helpful? Yes / No
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article

close
Dummy