change_palette method

change_palette

Changes the palette for the spreadsheet in the specified index.

def change_palette(self, color, index):
    ...
ParameterTypeDescription
coloraspose.pydrawing.ColorColor structure.
indexintPalette index, 0 - 55.

Remarks

The palette has 56 entries, each represented by an RGB value.

If you set a color which is not in the palette, it will not take effect.

So if you want to set a custom color, please change the palette at first.

The following is the standard color palette.

ColorRedGreenBlue
Black000
White255255255
Red25500
Lime02550
Blue00255
Yellow2552550
Magenta2550255
Cyan0255255
Maroon12800
Green01280
Navy00128
Olive1281280
Purple1280128
Teal0128128
Silver192192192
Gray128128128
Color17153153255
Color1815351102
Color19255255204
Color20204255255
Color211020102
Color22255128128
Color230102204
Color24204204255
Color2500128
Color262550255
Color272552550
Color280255255
Color291280128
Color3012800
Color310128128
Color3200255
Color330204255
Color34204255255
Color35204255204
Color36255255153
Color37153204255
Color38255153204
Color39204153255
Color40255204153
Color4151102255
Color4251204204
Color431532040
Color442552040
Color452551530
Color462551020
Color47102102153
Color48150150150
Color49051102
Color5051153102
Color510510
Color5251510
Color53153510
Color5415351102
Color555151153
Color56515151

See Also