taurus.core.util.colors

This module contains color codes for state and quality

Classes

class ColorPalette(dat, int_decoder_dict=None)[source]

Provides the list of taurus colors equivalent to Tango colors.

(more info)

Functions

darker(red: int, green: int, blue: int, fraction: float) → Tuple[int, int, int][source]

Return the RGB color darkened by a fraction between 0 and 1.

get_best_foreground(red: int, green: int, blue: int) → str[source]

Return the foreground color with the best contrast.

is_dark(red: int, green: int, blue: int) → bool[source]

Return whether an RGB color is considered dark.

lighter(red: int, green: int, blue: int, fraction: float) → Tuple[int, int, int][source]

Return the RGB color lightened by a fraction between 0 and 1.

Variables

ATTRIBUTE_QUALITY_DATA
ATTRIBUTE_QUALITY_PALETTE
DEVICE_STATE_DATA
DEVICE_STATE_PALETTE