|
|
1.1 root 1: #include "copyright.h"
2:
3: /* $Header: XAllCells.c,v 11.14 87/09/11 08:00:51 toddb Exp $ */
4: /* Copyright Massachusetts Institute of Technology 1986 */
5: #define NEED_REPLIES
6:
7: #include "Xlibint.h"
8:
9: Status XAllocColorCells(dpy, cmap, contig, masks, nplanes, pixels, ncolors)
10: register Display *dpy;
11: Colormap cmap;
12: Bool contig;
13: unsigned int ncolors; /* CARD16 */
14: unsigned int nplanes; /* CARD16 */
15: unsigned long masks[]; /* LISTofCARD32 */ /* RETURN */
16: unsigned long pixels[]; /* LISTofCARD32 */ /* RETURN */
17: {
18:
19: Status status;
20: xAllocColorCellsReply rep;
21: register xAllocColorCellsReq *req;
22: LockDisplay(dpy);
23: GetReq(AllocColorCells, req);
24:
25: req->cmap = cmap;
26: req->colors = ncolors;
27: req->planes = nplanes;
28: req->contiguous = contig;
29:
30: status = _XReply(dpy, (xReply *)&rep, 0, xFalse);
31:
32: if (status) {
33: _XRead (dpy, (char *) pixels, 4 * rep.nPixels);
34: _XRead (dpy, (char *) masks, 4 * rep.nMasks);
35: }
36:
37: UnlockDisplay(dpy);
38: SyncHandle();
39: return(status);
40: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.