if index is not valid for the given pattern. If the pattern is not a gradient pattern, [cairo.types.Status.PatternTypeMismatch] is returned.
Pattern.getColorStopRgba
cairo.types.Status getColorStopRgba(int index, out double offset, out double red, out double green, out double blue, out double alpha)Gets the color and offset information at the given index for a gradient pattern. Values of index range from 0 to n-1 where n is the number returned by [cairo.pattern.Pattern.getColorStopCount].
Note that the color and alpha values are not premultiplied.
Parameters
index | index of the stop to return data for |
offset | return value for the offset of the stop, or null |
red | return value for red component of color, or null |
green | return value for green component of color, or null |
blue | return value for blue component of color, or null |
alpha | return value for alpha component of color, or null |
Returns
[cairo.types.Status.Success], or [cairo.types.Status.InvalidIndex]