Contents

linearGradient(stops:startPoint:endPoint:)

A linear gradient defined by a collection of color stops.

Declaration

static func linearGradient(stops: [Gradient.Stop], startPoint: UnitPoint, endPoint: UnitPoint) -> LinearGradient

Discussion

The gradient applies the color function along an axis, as defined by its start and end points. The gradient maps the unit space points into the bounding rectangle of each shape filled with the gradient.

For information about how to use shape styles, see ShapeStyle.

See Also

Linear gradients