FillStyle
import type { FillStyle } from 'pixi-silk';
How a fill is painted: colour or gradient, opacity, blur with spread, blend mode and inner shadows.
Extended by#
Properties#
| Property | Type | Description | Defined in |
|---|---|---|---|
alpha? | number | Opacity from 0 to 1. Default 1. | SilkGraphics.ts:84 |
blend? | "normal" | "add" | add paints plus-lighter: colours add to what is underneath, so overlapping glows bloom towards white. Default normal. | SilkGraphics.ts:98 |
blur? | number | ProgressiveBlur | Gaussian blur (standard deviation, local units) for glows and soft shadows. A ProgressiveBlur changes the radius across the shape. | SilkGraphics.ts:91 |
color? | ColorSource | Colour, any Pixi ColorSource. With a gradient, it tints the gradient. | SilkGraphics.ts:82 |
gradient? | Gradient | Gradient paint. color (if given) tints it. | SilkGraphics.ts:86 |
innerShadow? | InnerShadow | InnerShadow[] | One or more shadows inside closed shapes, drawn in order on top of the fill. | SilkGraphics.ts:100 |
op? | ShapeOp | Combines the closed shapes of the active path into one shape. subtract takes every later shape out of the first one, intersect keeps what they all cover, and exclude keeps what an odd number of them cover. union is the same as union: true. A path from moveTo() or svgPath() takes part as one shape, even-odd. With stroke(), the stroke follows the outline of the result. See SilkGraphics.boolean for nested operations. Default none: every shape is painted on its own. | SilkGraphics.ts:117 |
spread? | number | Grows the shape by this many local units before it is blurred, like a Figma shadow spread. Negative shrinks it. | SilkGraphics.ts:93 |
union? | boolean | Paints every closed shape of the active path as one shape: their distance fields merge, so overlaps are painted once and blur, anti-aliasing and opacity show no seam where they meet. Polygons from poly() and moveTo() join in too, each subpath on its own. With stroke(), the stroke follows the outline of the union, and open paths merge into one stroke. Default false. | SilkGraphics.ts:108 |