VirtualBox

source: vbox/trunk/src/VBox/Additions/x11/x11include/xorg-server-1.4.2/compint.h@ 68495

Last change on this file since 68495 was 43272, checked in by vboxsync, 12 years ago

Additions/x11: more original X server headers.

  • Property svn:eol-style set to native
File size: 7.9 KB
Line 
1/*
2 * Copyright © 2006 Sun Microsystems
3 *
4 * Permission to use, copy, modify, distribute, and sell this software and its
5 * documentation for any purpose is hereby granted without fee, provided that
6 * the above copyright notice appear in all copies and that both that
7 * copyright notice and this permission notice appear in supporting
8 * documentation, and that the name of Sun Microsystems not be used in
9 * advertising or publicity pertaining to distribution of the software without
10 * specific, written prior permission. Sun Microsystems makes no
11 * representations about the suitability of this software for any purpose. It
12 * is provided "as is" without express or implied warranty.
13 *
14 * SUN MICROSYSTEMS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
15 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
16 * EVENT SHALL SUN MICROSYSTEMS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
17 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
18 * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
19 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
20 * PERFORMANCE OF THIS SOFTWARE.
21 *
22 * Copyright © 2003 Keith Packard
23 *
24 * Permission to use, copy, modify, distribute, and sell this software and its
25 * documentation for any purpose is hereby granted without fee, provided that
26 * the above copyright notice appear in all copies and that both that
27 * copyright notice and this permission notice appear in supporting
28 * documentation, and that the name of Keith Packard not be used in
29 * advertising or publicity pertaining to distribution of the software without
30 * specific, written prior permission. Keith Packard makes no
31 * representations about the suitability of this software for any purpose. It
32 * is provided "as is" without express or implied warranty.
33 *
34 * KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
35 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
36 * EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
37 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
38 * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
39 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
40 * PERFORMANCE OF THIS SOFTWARE.
41 */
42
43#ifdef HAVE_DIX_CONFIG_H
44#include <dix-config.h>
45#endif
46
47#ifndef _COMPINT_H_
48#define _COMPINT_H_
49
50#include "misc.h"
51#include "scrnintstr.h"
52#include "os.h"
53#include "regionstr.h"
54#include "validate.h"
55#include "windowstr.h"
56#include "input.h"
57#include "resource.h"
58#include "colormapst.h"
59#include "cursorstr.h"
60#include "dixstruct.h"
61#include "gcstruct.h"
62#include "servermd.h"
63#include "dixevents.h"
64#include "globals.h"
65#include "picturestr.h"
66#include "extnsionst.h"
67#include "mi.h"
68#include "damage.h"
69#include "damageextint.h"
70#include "xfixes.h"
71#include <X11/extensions/compositeproto.h>
72#include <assert.h>
73
74/*
75 * enable this for debugging
76
77 #define COMPOSITE_DEBUG
78 */
79
80typedef struct _CompClientWindow {
81 struct _CompClientWindow *next;
82 XID id;
83 int update;
84} CompClientWindowRec, *CompClientWindowPtr;
85
86typedef struct _CompWindow {
87 RegionRec borderClip;
88 DamagePtr damage; /* for automatic update mode */
89 Bool damageRegistered;
90 Bool damaged;
91 int update;
92 CompClientWindowPtr clients;
93 int oldx;
94 int oldy;
95 PixmapPtr pOldPixmap;
96 int borderClipX, borderClipY;
97} CompWindowRec, *CompWindowPtr;
98
99#define COMP_ORIGIN_INVALID 0x80000000
100
101typedef struct _CompSubwindows {
102 int update;
103 CompClientWindowPtr clients;
104} CompSubwindowsRec, *CompSubwindowsPtr;
105
106#ifndef COMP_INCLUDE_RGB24_VISUAL
107#define COMP_INCLUDE_RGB24_VISUAL 0
108#endif
109
110typedef struct _CompOverlayClientRec *CompOverlayClientPtr;
111
112typedef struct _CompOverlayClientRec {
113 CompOverlayClientPtr pNext;
114 ClientPtr pClient;
115 ScreenPtr pScreen;
116 XID resource;
117} CompOverlayClientRec;
118
119typedef struct _CompScreen {
120 PositionWindowProcPtr PositionWindow;
121 CopyWindowProcPtr CopyWindow;
122 CreateWindowProcPtr CreateWindow;
123 DestroyWindowProcPtr DestroyWindow;
124 RealizeWindowProcPtr RealizeWindow;
125 UnrealizeWindowProcPtr UnrealizeWindow;
126 PaintWindowProcPtr PaintWindowBackground;
127 ClipNotifyProcPtr ClipNotify;
128 /*
129 * Called from ConfigureWindow, these
130 * three track changes to the offscreen storage
131 * geometry
132 */
133 MoveWindowProcPtr MoveWindow;
134 ResizeWindowProcPtr ResizeWindow;
135 ChangeBorderWidthProcPtr ChangeBorderWidth;
136 /*
137 * Reparenting has an effect on Subwindows redirect
138 */
139 ReparentWindowProcPtr ReparentWindow;
140
141 /*
142 * Colormaps for new visuals better not get installed
143 */
144 InstallColormapProcPtr InstallColormap;
145
146 ScreenBlockHandlerProcPtr BlockHandler;
147 CloseScreenProcPtr CloseScreen;
148 Bool damaged;
149 int numAlternateVisuals;
150 VisualID *alternateVisuals;
151
152 WindowPtr pOverlayWin;
153 CompOverlayClientPtr pOverlayClients;
154
155} CompScreenRec, *CompScreenPtr;
156
157extern int CompScreenPrivateIndex;
158extern int CompWindowPrivateIndex;
159extern int CompSubwindowsPrivateIndex;
160
161#define GetCompScreen(s) ((CompScreenPtr) ((s)->devPrivates[CompScreenPrivateIndex].ptr))
162#define GetCompWindow(w) ((CompWindowPtr) ((w)->devPrivates[CompWindowPrivateIndex].ptr))
163#define GetCompSubwindows(w) ((CompSubwindowsPtr) ((w)->devPrivates[CompSubwindowsPrivateIndex].ptr))
164
165extern RESTYPE CompositeClientWindowType;
166extern RESTYPE CompositeClientSubwindowsType;
167
168/*
169 * compalloc.c
170 */
171
172Bool
173compRedirectWindow (ClientPtr pClient, WindowPtr pWin, int update);
174
175void
176compFreeClientWindow (WindowPtr pWin, XID id);
177
178int
179compUnredirectWindow (ClientPtr pClient, WindowPtr pWin, int update);
180
181int
182compRedirectSubwindows (ClientPtr pClient, WindowPtr pWin, int update);
183
184void
185compFreeClientSubwindows (WindowPtr pWin, XID id);
186
187int
188compUnredirectSubwindows (ClientPtr pClient, WindowPtr pWin, int update);
189
190int
191compRedirectOneSubwindow (WindowPtr pParent, WindowPtr pWin);
192
193int
194compUnredirectOneSubwindow (WindowPtr pParent, WindowPtr pWin);
195
196Bool
197compAllocPixmap (WindowPtr pWin);
198
199void
200compFreePixmap (WindowPtr pWin);
201
202Bool
203compReallocPixmap (WindowPtr pWin, int x, int y,
204 unsigned int w, unsigned int h, int bw);
205
206/*
207 * compext.c
208 */
209
210void
211CompositeExtensionInit (void);
212
213/*
214 * compinit.c
215 */
216
217Bool
218CompositeRegisterAlternateVisuals (ScreenPtr pScreen,
219 VisualID *vids, int nVisuals);
220
221Bool
222compScreenInit (ScreenPtr pScreen);
223
224/*
225 * compwindow.c
226 */
227
228#ifdef COMPOSITE_DEBUG
229void
230compCheckTree (ScreenPtr pScreen);
231#else
232#define compCheckTree(s)
233#endif
234
235PictFormatPtr
236compWindowFormat (WindowPtr pWin);
237
238void
239compSetPixmap (WindowPtr pWin, PixmapPtr pPixmap);
240
241Bool
242compCheckRedirect (WindowPtr pWin);
243
244Bool
245compPositionWindow (WindowPtr pWin, int x, int y);
246
247Bool
248compRealizeWindow (WindowPtr pWin);
249
250Bool
251compUnrealizeWindow (WindowPtr pWin);
252
253void
254compPaintWindowBackground (WindowPtr pWin, RegionPtr pRegion, int what);
255
256void
257compClipNotify (WindowPtr pWin, int dx, int dy);
258
259void
260compMoveWindow (WindowPtr pWin, int x, int y, WindowPtr pSib, VTKind kind);
261
262void
263compResizeWindow (WindowPtr pWin, int x, int y,
264 unsigned int w, unsigned int h, WindowPtr pSib);
265
266void
267compChangeBorderWidth (WindowPtr pWin, unsigned int border_width);
268
269void
270compReparentWindow (WindowPtr pWin, WindowPtr pPriorParent);
271
272Bool
273compCreateWindow (WindowPtr pWin);
274
275Bool
276compDestroyWindow (WindowPtr pWin);
277
278void
279compSetRedirectBorderClip (WindowPtr pWin, RegionPtr pRegion);
280
281RegionPtr
282compGetRedirectBorderClip (WindowPtr pWin);
283
284void
285compCopyWindow (WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc);
286
287void
288compWindowUpdate (WindowPtr pWin);
289
290void
291deleteCompOverlayClientsForScreen (ScreenPtr pScreen);
292
293WindowPtr
294CompositeRealChildHead (WindowPtr pWin);
295
296int
297DeleteWindowNoInputDevices(pointer value, XID wid);
298
299#endif /* _COMPINT_H_ */
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette