home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.windows.x:14432 comp.windows.x.motif:5240
- Newsgroups: comp.windows.x,comp.windows.x.motif
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!usc!cs.utexas.edu!torn!watserv1!sparky.waterloo.edu!andrew
- From: andrew@sparky.uwaterloo.ca (Andrew MacLean)
- Subject: Help with Copying Colormaps
- Message-ID: <Bs1vKy.HnF@watserv1.uwaterloo.ca>
- Originator: andrew@sparky.waterloo.edu
- Sender: news@watserv1.uwaterloo.ca
- Organization: University of Waterloo
- Distribution: na
- Date: Mon, 27 Jul 1992 13:46:09 GMT
- Lines: 39
-
-
- I am creating a Motif program that allocates a variable number of
- colors in the root window colormap. (I am loading color images,
- which have a condensed colormap table.) I would like to use a command
- similar to XCopyColormapAndFree so that I can create a SECOND
- colormap with all of the Motif colors and my image colors
- copied to the new colormap.
-
- The problem is that I do NOT want the colors to be freed from the
- root window colormap. (ie. I do not want to have my program
- window borders change colors when I move from one image window
- to another image window.)
-
- Summary of desires:
-
- 1) A copy of the Root window colormap that contains ONLY
- those color cells that were allocated by my program.
-
- 2) The color cells in the root window MUST NOT be freed.
-
- 3) The copy of the root window colormap CANNOT have any
- colors allocated that are not a part of my program
- as I will be using those extra colors later.
-
- One way to approach this problem is to go through the root
- window colormap and decide whether my program has allocated
- this color or not. My question is how can I tell which colors
- were allocated by me, and which were allocated by another
- program? How can I tell which colors were allocated by the
- Motif part of my program?
-
-
- Thanks in advance.
- Andrew
- --
- ------------------=========================================------------------
- Andrew MacLean email: andrew@sparky.uwaterloo.ca
- Civil Engineering phone: (519)885-1211 x3862
- University of Waterloo "You want me to document WHAT?!?!"
-