libxlsxwriter
|
Throughout libxlsxwriter colors are specified using a Html style RGB integer value. For example with a Format object:
For convenience a limited number of color names are supported:
The color names and corresponding RRGGBB value are shown below:
Color | Define | Value |
---|---|---|
Black | LXW_COLOR_BLACK | 0x1000000 (note) |
Blue | LXW_COLOR_BLUE | 0x0000FF |
Brown | LXW_COLOR_BROWN | 0x800000 |
Cyan | LXW_COLOR_CYAN | 0x00FFFF |
Gray | LXW_COLOR_GRAY | 0x808080 |
Green | LXW_COLOR_GREEN | 0x008000 |
Lime | LXW_COLOR_LIME | 0x00FF00 |
Magenta | LXW_COLOR_MAGENTA | 0xFF00FF |
Navy | LXW_COLOR_NAVY | 0x000080 |
Orange | LXW_COLOR_ORANGE | 0xFF6600 |
Pink | LXW_COLOR_PINK | 0xFF00FF |
Purple | LXW_COLOR_PURPLE | 0x800080 |
Red | LXW_COLOR_RED | 0xFF0000 |
Silver | LXW_COLOR_SILVER | 0xC0C0C0 |
White | LXW_COLOR_WHITE | 0xFFFFFF |
Yellow | LXW_COLOR_YELLOW | 0xFFFF00 |
0x000000
but #LXW_COLOR_BLACK
is defined as 0x1000000 to avoid confusion with an undefined or Zero color value. It is converted to the correct Html code internally.Next: Working with Formulas