Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!wasatch!cs.utexas.edu!uunet!mcvax!guido From: guido@cwi.nl (Guido van Rossum) Newsgroups: comp.windows.x Subject: Re: Virtual colormaps & DECwindows Message-ID: <8286@boring.cwi.nl> Date: 24 Jul 89 18:17:21 GMT References: <223@nap1.cds.wpafb.af.mil> <8907240118.AA18657@jumbo.pa.dec.com> Sender: news@cwi.nl Reply-To: guido@cwi.nl (Guido van Rossum) Organization: The Royal Society for Prevention of Cruelty to Amoebae Lines: 29 Vern Staats writes: >> Is there some way to tell dxwm to leave my map installed, or at least >> reinstall it when my application has focus? Mark Manasse replies: >The currently-shipped version of dxwm keeps >track of what it believes to be the focus window for colormap, and >keeps that window's colormap installed. Since the current release >of dxwm predates the ICCCM's adoption of COLORMAP_WINDOWS, it does >not implement that feature of the ICCCM. > >Mark Mark's explanation seems to imply that you can't get a colormap installed at all by dxwm, but life isn't that bad. Some playing with Doug Young's coloredit example (which needs some lay-out changes for 256 colors, BTW!) reveals that calling XSetWindowColormap(display, window, colormap) works, both for twm and for dxwm. Young claims this is the ICCCM-conformant way. The colormap is uninstalled when the application loses the color focus and reinstalled when it regains it. (dxwm seems to maintain separate color and keyboard focuses; with twm, the color map seems to simply follow the keyboard focus). -- Guido van Rossum, Centre for Mathematics and Computer Science (CWI), Amsterdam guido@cwi.nl or mcvax!guido or guido%cwi.nl@uunet.uu.net "Repo man has all night, every night."