set_palette


Description:

[ Version ( since = "3.0" ) ]
public unowned Palette set_palette (Palette new_palette)

Set the image's colormap to a copy of palette

This procedure changes the image's colormap to an exact copy of palette and returns the palette of this. If the image is not in Indexed color mode, nothing happens and null is returned.

Parameters:

this

The image.

new_palette

The palette to copy from.

Returns:

The image's colormap palette.