Method AddColor
AddColor(Color, float)
Add a color entry in the current swatch. This methods is useful to create gradients dynamically.
Declaration
public int AddColor(Color newColor, float position)
Parameters
Type | Name | Description |
---|---|---|
Color | newColor | The color to add. |
float | position | At which position the given color should be added. The expected value must be normalized. |
Returns
Type | Description |
---|---|
int | The index of the added color entry in the list. |