Class rgb_color

Version added: before 9.5
The rgb_color class is a basic structure for storing a color value, including opacity/transparency.

Properties:

Name Type Description Version added
r int The red component of the color. Values can range from 0 to 255. before 9.5
g int The green component of the color. Values can range from 0 to 255. before 9.5
b int The blue component of the color. Values can range from 0 to 255. before 9.5
a int The alpha (or opacity) component of the color. Values can range from 0 to 255. An alpha of 0 is a totally transparent color, while a value of 255 indicates a totally opaque color. before 9.5