Commit | Line | Data |
---|---|---|
a09e091a JB |
1 | /* |
2 | ||
3 | Copyright 1993 by Davor Matic | |
4 | ||
5 | Permission to use, copy, modify, distribute, and sell this software | |
6 | and its documentation for any purpose is hereby granted without fee, | |
7 | provided that the above copyright notice appear in all copies and that | |
8 | both that copyright notice and this permission notice appear in | |
9 | supporting documentation. Davor Matic makes no representations about | |
10 | the suitability of this software for any purpose. It is provided "as | |
11 | is" without express or implied warranty. | |
12 | ||
13 | */ | |
14 | ||
15 | #ifndef XNESTWINDOW_H | |
16 | #define XNESTWINDOW_H | |
17 | ||
18 | typedef struct { | |
19 | Window window; | |
20 | Window parent; | |
21 | int x; | |
22 | int y; | |
23 | unsigned int width; | |
24 | unsigned int height; | |
25 | unsigned int border_width; | |
26 | Window sibling_above; | |
27 | RegionPtr bounding_shape; | |
28 | RegionPtr clip_shape; | |
29 | } xnestPrivWin; | |
30 | ||
31 | typedef struct { | |
32 | WindowPtr pWin; | |
33 | Window window; | |
34 | } xnestWindowMatch; | |
35 | ||
36 | extern DevPrivateKeyRec xnestWindowPrivateKeyRec; | |
37 | ||
38 | #define xnestWindowPrivateKey (&xnestWindowPrivateKeyRec) | |
39 | ||
40 | #define xnestWindowPriv(pWin) ((xnestPrivWin *) \ | |
41 | dixLookupPrivate(&(pWin)->devPrivates, xnestWindowPrivateKey)) | |
42 | ||
43 | #define xnestWindow(pWin) (xnestWindowPriv(pWin)->window) | |
44 | ||
45 | #define xnestWindowParent(pWin) \ | |
46 | ((pWin)->parent ? \ | |
47 | xnestWindow((pWin)->parent) : \ | |
48 | xnestDefaultWindows[pWin->drawable.pScreen->myNum]) | |
49 | ||
50 | #define xnestWindowSiblingAbove(pWin) \ | |
51 | ((pWin)->prevSib ? xnestWindow((pWin)->prevSib) : None) | |
52 | ||
53 | #define xnestWindowSiblingBelow(pWin) \ | |
54 | ((pWin)->nextSib ? xnestWindow((pWin)->nextSib) : None) | |
55 | ||
56 | #define CWParent CWSibling | |
57 | #define CWStackingOrder CWStackMode | |
58 | ||
59 | WindowPtr xnestWindowPtr(Window window); | |
60 | Bool xnestCreateWindow(WindowPtr pWin); | |
61 | Bool xnestDestroyWindow(WindowPtr pWin); | |
62 | Bool xnestPositionWindow(WindowPtr pWin, int x, int y); | |
63 | void xnestConfigureWindow(WindowPtr pWin, unsigned int mask); | |
64 | Bool xnestChangeWindowAttributes(WindowPtr pWin, unsigned long mask); | |
65 | Bool xnestRealizeWindow(WindowPtr pWin); | |
66 | Bool xnestUnrealizeWindow(WindowPtr pWin); | |
67 | void xnestCopyWindow(WindowPtr pWin, xPoint oldOrigin, RegionPtr oldRegion); | |
68 | void xnestClipNotify(WindowPtr pWin, int dx, int dy); | |
69 | void xnestWindowExposures(WindowPtr pWin, RegionPtr pRgn, | |
70 | RegionPtr other_exposed); | |
71 | void xnestSetShape(WindowPtr pWin, int kind); | |
72 | void xnestShapeWindow(WindowPtr pWin); | |
73 | ||
74 | #endif /* XNESTWINDOW_H */ |