|
|
1.1 root 1: #include "copyright.h"
2:
3: /* $Header: XReconfWin.c,v 11.9 87/09/11 08:06:30 toddb Exp $ */
4: /* Copyright Massachusetts Institute of Technology 1986 */
5:
6: #include "Xlibint.h"
7:
8: XConfigureWindow(dpy, w, mask, changes)
9: register Display *dpy;
10: Window w;
11: unsigned int mask;
12: XWindowChanges *changes;
13: {
14: unsigned long values[7];
15: register unsigned long *value = values;
16: long nvalues;
17: register xConfigureWindowReq *req;
18:
19: LockDisplay(dpy);
20: GetReq(ConfigureWindow, req);
21: req->window = w;
22: req->mask = mask;
23:
24: /* Warning! This code assumes that "unsigned long" is 32-bits wide */
25:
26: if (mask & CWX)
27: *value++ = changes->x;
28:
29: if (mask & CWY)
30: *value++ = changes->y;
31:
32: if (mask & CWWidth)
33: *value++ = changes->width;
34:
35: if (mask & CWHeight)
36: *value++ = changes->height;
37:
38: if (mask & CWBorderWidth)
39: *value++ = changes->border_width;
40:
41: if (mask & CWSibling)
42: *value++ = changes->sibling;
43:
44: if (mask & CWStackMode)
45: *value++ = changes->stack_mode;
46:
47: req->length += (nvalues = value - values);
48:
49: /* note: Data is a macro that uses its arguments multiple
50: times, so "nvalues" is changed in a separate assignment
51: statement */
52:
53: nvalues <<= 2;
54: Data (dpy, (char *) values, nvalues);
55: UnlockDisplay(dpy);
56: SyncHandle();
57:
58: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.