Accusoft.ImagXpressSdk Namespace > ImageX Class : Palette Property |
'Declaration Public Property Palette As ColorPalette
'Usage Dim instance As ImageX Dim value As ColorPalette instance.Palette = value value = instance.Palette
public ColorPalette Palette {get; set;}
public: __property ColorPalette* get_Palette(); public: __property void set_Palette( ColorPalette* value );
public: property ColorPalette^ Palette { ColorPalette^ get(); void set ( ColorPalette^ value); }
If the ImageX does not have a palette then an empty palette is returned.
The Palette property returns and sets a palette in one operation. Like the System.Drawing.Bitmap class, the Palette can not be modified on the fly.
imageX.Palette.Entries[0] = System.Drawing.Color.Red;
System.Drawing.Imaging.ColorPalette palette;
palette = imageX.Palette;
if ( palette.Entries.Length > 0 )
{
palette.Entries[0] = System.Drawing.Color.Red;
imageX.Palette = palette;
}