You can change the colors and locations of a gradient.
By default, a gradient has the following 2 colors:
This implies that the gradient will draw C4Pink
from it’s start point to C4Blue
at its end point.
You can change this value by setting the colors
variable with an array of at least 2 Color
objects.
By default, a gradient has the following 2 locations:
These “normalized” values map to the start and end points of the gradient. If you have more than 2 colors you will need to also specify an array of locations that have the same count as the colors array.