[comp.windows.x] Need Help using XView CMS

cflatter@zia.aoc.nrao.EDU (Chris Flatters) (01/09/91)

> I'm writing an Image Display program in XView. Since I have an option to
> install various colormap I use XV_DYNAMIC_CMS when creating a Cms. To
> minimize screen flashing would like to set the first 30 or so cells to be 
> equal to the default colormap and be able to read/write at least other
> 200 cells.

I've done something like this.  The easiest way is to forget about XView
colormap segments and use X11 colormaps directly.  What I do is allocate
a private map with XCreateColormap and then copy values from the default
colormap into it.  You can associate the new colormap with a window by
reading the windows XID and using it in an appropriate Xlib function
(eg. XSetWMColormapWindows).

			Chris Flatters