
## ColorPalette class

Defines an array of colors that make up a color palette. The colors are 32-bit ARGB colors. Not inheritable.



The ColorPalette type exposes the following members:

### Constructors
| Constructor | Description |
| :- | :- |
| [__init__](/cad/python-net/aspose.cad/colorpalette/__init__/#list-bool) | Initializes a new instance of the [`ColorPalette`](/cad/python-net/aspose.cad/colorpalette) class. |
| [__init__](/cad/python-net/aspose.cad/colorpalette/__init__/#list) | Initializes a new instance of the [`ColorPalette`](/cad/python-net/aspose.cad/colorpalette) class and IsCompactPalette is false. |
| [__init__](/cad/python-net/aspose.cad/colorpalette/__init__/#list-bool) | Initializes a new instance of the [`ColorPalette`](/cad/python-net/aspose.cad/colorpalette) class. |
| [__init__](/cad/python-net/aspose.cad/colorpalette/__init__/#list) | Initializes a new instance of the [`ColorPalette`](/cad/python-net/aspose.cad/colorpalette) class and IsCompactPalette is false. |


### Properties
| Property | Description |
| :- | :- |
| [entries_count](/cad/python-net/aspose.cad/colorpalette/entries_count) | Gets the entries count. |
| [argb_32_entries](/cad/python-net/aspose.cad/colorpalette/argb_32_entries) | Gets an array of 32-bit ARGB structures. |
| [entries](/cad/python-net/aspose.cad/colorpalette/entries) | Gets an array of [`Color`](/cad/python-net/aspose.cad/color) structures. |
| [is_compact_palette](/cad/python-net/aspose.cad/colorpalette/is_compact_palette) | Gets or sets a value indicating whether compact palette is used. |


### Methods
| Method | Description |
| :- | :- |
| [copy_palette](/cad/python-net/aspose.cad/colorpalette/copy_palette/#aspose.cad.IColorPalette-bool) | Copies the palette. |
| [copy_palette](/cad/python-net/aspose.cad/colorpalette/copy_palette/#aspose.cad.IColorPalette) | Copies the palette. |
| [get_nearest_color_index](/cad/python-net/aspose.cad/colorpalette/get_nearest_color_index/#int) | Gets the index of the nearest color. |
| [get_nearest_color_index](/cad/python-net/aspose.cad/colorpalette/get_nearest_color_index/#aspose.cad.Color) | Gets the index of the nearest color. |
| [get_argb_32_color](/cad/python-net/aspose.cad/colorpalette/get_argb_32_color/#int) | Gets the 32-bit ARGB palette color by index. |
| [get_color](/cad/python-net/aspose.cad/colorpalette/get_color/#int) | Gets the palette color by index. |



### See Also
* module [`aspose.cad`](..)
* class [`Color`](/cad/python-net/aspose.cad/color)
* class [`ColorPalette`](/cad/python-net/aspose.cad/colorpalette)
* class [`IColorPalette`](/cad/python-net/aspose.cad/icolorpalette)
