The COLORMAP_APPLICABLE function determines whether the current visual class supports the use of a colormap, and if so, whether colormap changes affect pre-displayed Direct Graphics or if the graphics must be redrawn to pick up colormap changes.

This routine is written in the IDL language. Its source code can be found in the file colormap_applicable.pro in the lib subdirectory of the IDL distribution.

Examples


To determine whether to redisplay an image after a colormap change:

result = COLORMAP_APPLICABLE(redrawRequired)
IF ((result GT 0) AND (redrawRequired GT 0)) THEN BEGIN
   my_redraw
ENDIF

Syntax


Result = COLORMAP_APPLICABLE( redrawRequired )

Return Value


The function returns a long value of 1 if the current visual class allows modification of the color table, and 0 otherwise.

Arguments


redrawRequired

A named variable to retrieve a value indicating whether the visual class supports automatic updating of graphics. The value is 0 if the graphics are updated automatically, or 1 if the graphics must be redrawn to pick up changes to the colormap.

Keywords


None.

Version History


5.2

Introduced