Color and colortools
Using colors¶
Our engine has some build in predefined colors so it's a bit easier for you with colors, to acess the colors you run:
All colors¶
The color name is always capitalised as per PEP 8 → Constants. All colors are defined and named (with capitalised form) as per Sublime Text → Docs → Color Schemes → Appendix - CSS Colors.
Custom color¶
If you want your own color, you just give your function a Color object as argument with RGBA colors, here is an example:
Hex to rgba¶
If you have a hex color and want to convert it to rgba you can use this function:
HSV to RGB¶
If you have a HSV color and want to convert it to RGB you can use this function:
hsv_to_rgb(hue, sat, val, alpha) -> Color