DotPattern class

A dotted pattern fill.

Inheritance

Constructors

DotPattern({double radius = 2, double spacingX = 10, double spacingY = 10, bool staggered = false, Color backgroundColor = const Color(0x00000000), Color foregroundColor = const Color(0xFF000000)})
Creates a dot pattern.
const
DotPattern.grid({double radius = 2, double spacing = 10, Color backgroundColor = const Color(0x00000000), Color foregroundColor = const Color(0xFF000000)})
Creates a regular grid dot pattern.
factory
DotPattern.staggered({double radius = 2, double spacing = 10, Color backgroundColor = const Color(0x00000000), Color foregroundColor = const Color(0xFF000000)})
Creates a staggered (honeycomb) dot pattern.
factory

Properties

backgroundColor Color
The background color.
finalinherited
foregroundColor Color
The foreground/pattern color.
finalinherited
hashCode int
The hash code for this object.
no setterinherited
height double
The pattern height.
finalinherited
radius double
The radius of each dot.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
spacingX double
The horizontal spacing between dots.
final
spacingY double
The vertical spacing between dots.
final
staggered bool
Whether to offset alternating rows.
final
width double
The pattern width.
finalinherited

Methods

createShader(Rect bounds) Shader
Creates a shader that tiles this pattern.
inherited
drawPattern(Canvas canvas, Size size) → void
Draws the pattern once at origin.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited