to_string method

to_string

Converts color components to string representation.

Returns

String representation of the color components.

def to_string(self, include_alpha, as_decimal, digits):
    ...
ParameterTypeDescription
include_alphaboolSpecifies whether to add Alpha component.
as_decimalboolSpecifies whether color components are preserved as a decimal number or as a percentage.
digitsintSets the rounding precision for color components.

See Also