python-webcolors
is a module for working with HTML/CSS color definitions. Normalizing and converting between the following formats is supported.
Specification-defined color names
Six-digit hexadecimal
Three-digit hexadecimal
Integer rgb() triplet
Percentage rgb() triplet
Only the RGB colorspace is supported. Conversion to/from the HSL colorspace can be handled by the colorsys
module in the Python standard library.
python-webcolors
is a module for working with HTML/CSS color definitions. Normalizing and converting between the following formats is supported.
Specification-defined color names
Six-digit hexadecimal
Three-digit hexadecimal
Integer rgb() triplet
Percentage rgb() triplet
Only the RGB colorspace is supported. Conversion to/from the HSL colorspace can be handled by the colorsys
module in the Python standard library.