Contents

gradient

Returns the standard gradient for the color self.

Declaration

var gradient: AnyGradient { get }

Discussion

For example, filling a rectangle with a gradient derived from the standard blue color:

Rectangle().fill(.blue.gradient)

See Also

Modifying a color