Contents

mirror

An option that repeats the gradient outside its nominal range, reflecting every other instance.

Declaration

static var mirror: GraphicsContext.GradientOptions { get }

Discussion

Use this option to cause the gradient to repeat its pattern in areas that exceed the bounds of its start and end points. The repetitions alternately reverse the start and end points, producing a pattern like 0 -> 1, 1 -> 0, 0 -> 1, and so on.

Without either this option or repeat, the gradient stops at the end of its range. This option takes precendence if you set both this one and repeat.

See Also

Getting gradient options