The pergola.pattern library object defines pattern methods. Pattern elements are not created at runtime The function creates the pattern with unique ID based on parameters–if it doesn't exist–and returns the URI string.
All pattern definitions have
transform properties, and some also have
"stroke-width", where applicable.
The examples above were obtained by simply fiddling around with values. Overriding the
height can produce dramatic deviations from the original design, while playing with transformations can be more interesting. For some of the types, overridden width and height are ignored. Learn more in the PATTERNS library section of the Tutorial.
To use a pattern assign the call to the
fill and, or
stroke properties of an element: