XNWindow.h revision 6747b715
105b261ecSmrg/* 205b261ecSmrg 305b261ecSmrgCopyright 1993 by Davor Matic 405b261ecSmrg 505b261ecSmrgPermission to use, copy, modify, distribute, and sell this software 605b261ecSmrgand its documentation for any purpose is hereby granted without fee, 705b261ecSmrgprovided that the above copyright notice appear in all copies and that 805b261ecSmrgboth that copyright notice and this permission notice appear in 905b261ecSmrgsupporting documentation. Davor Matic makes no representations about 1005b261ecSmrgthe suitability of this software for any purpose. It is provided "as 1105b261ecSmrgis" without express or implied warranty. 1205b261ecSmrg 1305b261ecSmrg*/ 1405b261ecSmrg 1505b261ecSmrg#ifndef XNESTWINDOW_H 1605b261ecSmrg#define XNESTWINDOW_H 1705b261ecSmrg 1805b261ecSmrgtypedef struct { 1905b261ecSmrg Window window; 2005b261ecSmrg Window parent; 2105b261ecSmrg int x; 2205b261ecSmrg int y; 2305b261ecSmrg unsigned int width; 2405b261ecSmrg unsigned int height; 2505b261ecSmrg unsigned int border_width; 2605b261ecSmrg Window sibling_above; 2705b261ecSmrg RegionPtr bounding_shape; 2805b261ecSmrg RegionPtr clip_shape; 2905b261ecSmrg} xnestPrivWin; 3005b261ecSmrg 3105b261ecSmrgtypedef struct { 3205b261ecSmrg WindowPtr pWin; 3305b261ecSmrg Window window; 3405b261ecSmrg} xnestWindowMatch; 3505b261ecSmrg 366747b715Smrgextern DevPrivateKeyRec xnestWindowPrivateKeyRec; 376747b715Smrg#define xnestWindowPrivateKey (&xnestWindowPrivateKeyRec) 3805b261ecSmrg 394642e01fSmrg#define xnestWindowPriv(pWin) ((xnestPrivWin *) \ 404642e01fSmrg dixLookupPrivate(&(pWin)->devPrivates, xnestWindowPrivateKey)) 4105b261ecSmrg 4205b261ecSmrg#define xnestWindow(pWin) (xnestWindowPriv(pWin)->window) 4305b261ecSmrg 4405b261ecSmrg#define xnestWindowParent(pWin) \ 4505b261ecSmrg ((pWin)->parent ? \ 4605b261ecSmrg xnestWindow((pWin)->parent) : \ 4705b261ecSmrg xnestDefaultWindows[pWin->drawable.pScreen->myNum]) 4805b261ecSmrg 4905b261ecSmrg#define xnestWindowSiblingAbove(pWin) \ 5005b261ecSmrg ((pWin)->prevSib ? xnestWindow((pWin)->prevSib) : None) 5105b261ecSmrg 5205b261ecSmrg#define xnestWindowSiblingBelow(pWin) \ 5305b261ecSmrg ((pWin)->nextSib ? xnestWindow((pWin)->nextSib) : None) 5405b261ecSmrg 5505b261ecSmrg#define CWParent CWSibling 5605b261ecSmrg#define CWStackingOrder CWStackMode 5705b261ecSmrg 5805b261ecSmrgWindowPtr xnestWindowPtr(Window window); 5905b261ecSmrgBool xnestCreateWindow(WindowPtr pWin); 6005b261ecSmrgBool xnestDestroyWindow(WindowPtr pWin); 6105b261ecSmrgBool xnestPositionWindow(WindowPtr pWin, int x, int y); 6205b261ecSmrgvoid xnestConfigureWindow(WindowPtr pWin, unsigned int mask); 6305b261ecSmrgBool xnestChangeWindowAttributes(WindowPtr pWin, unsigned long mask); 6405b261ecSmrgBool xnestRealizeWindow(WindowPtr pWin); 6505b261ecSmrgBool xnestUnrealizeWindow(WindowPtr pWin); 6605b261ecSmrgvoid xnestCopyWindow(WindowPtr pWin, xPoint oldOrigin, RegionPtr oldRegion); 6705b261ecSmrgvoid xnestClipNotify(WindowPtr pWin, int dx, int dy); 6805b261ecSmrgvoid xnestWindowExposures(WindowPtr pWin, RegionPtr pRgn, 6905b261ecSmrg RegionPtr other_exposed); 706747b715Smrgvoid xnestSetShape(WindowPtr pWin, int kind); 7105b261ecSmrgvoid xnestShapeWindow(WindowPtr pWin); 7205b261ecSmrg 7305b261ecSmrg#endif /* XNESTWINDOW_H */ 74