to_hex method

to_hex

Returns this color in hexadecimal string representation

Returns

Color hex representation string

def to_hex(self):
    ...

Example

Returns “#FF0000” for Red

See Also