Expand/Shrink

cdCanvasPalette

Definition: include pGUI.e

cdCanvasPalette(cdCanvas canvas, sequence colours, integer mode=CD_POLITE)
Description: In systems limited to 256 palette colors, this function aims at adding length(colours) colors to the system's palette.
In such systems, the colors demanded forward or backward which are not in the palette are approximated to the closest available color.
The mode can be CD_FORCE or CD_POLITE.
CD_FORCE ignores the system colors and interface elements, since the menus and dialogues may be in illegible colors, but there will be more colors available.
CD_POLITE is the recommended type.
It must always be used before drawing. It cannot be queried.
pwa/p2js: Not supported.