3 Copyright 1989, 1998 The Open Group
5 Permission to use, copy, modify, distribute, and sell this software and its
6 documentation for any purpose is hereby granted without fee, provided that
7 the above copyright notice appear in all copies and that both that
8 copyright notice and this permission notice appear in supporting
11 The above copyright notice and this permission notice shall be included in
12 all copies or substantial portions of the Software.
14 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17 OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
18 AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
19 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21 Except as contained in this notice, the name of The Open Group shall not be
22 used in advertising or otherwise to promote the sale, use or other dealings
23 in this Software without prior written authorization from The Open Group.
29 #include <X11/Xfuncproto.h>
31 #include <X11/extensions/multibufconst.h>
33 #if !defined(UNIXCPP) || defined(ANSICPP)
34 #define MbufGetReq(name,req,info) GetReq (name, req); \
35 req->reqType = info->codes->major_opcode; \
36 req->mbufReqType = X_##name;
38 #define MbufGetReq(name,req,info) GetReq (name, req); \
39 req->reqType = info->codes->major_opcode; \
40 req->mbufReqType = X_/**/name;
44 * Extra definitions that will only be needed in the client
46 typedef XID Multibuffer;
49 int type; /* of event */
50 unsigned long serial; /* # of last request processed by server */
51 int send_event; /* true if this came frome a SendEvent request */
52 Display *display; /* Display the event was read from */
53 Multibuffer buffer; /* buffer of event */
54 int state; /* see Clobbered constants above */
55 } XmbufClobberNotifyEvent;
58 int type; /* of event */
59 unsigned long serial; /* # of last request processed by server */
60 int send_event; /* true if this came frome a SendEvent request */
61 Display *display; /* Display the event was read from */
62 Multibuffer buffer; /* buffer of event */
63 } XmbufUpdateNotifyEvent;
67 * per-window attributes that can be got
70 int displayed_index; /* which buffer is being displayed */
71 int update_action; /* Undefined, Background, Untouched, Copied */
72 int update_hint; /* Frequent, Intermittent, Static */
73 int window_mode; /* Mono, Stereo */
74 int nbuffers; /* Number of buffers */
75 Multibuffer *buffers; /* Buffers */
76 } XmbufWindowAttributes;
79 * per-window attributes that can be set
82 int update_hint; /* Frequent, Intermittent, Static */
83 } XmbufSetWindowAttributes;
87 * per-buffer attributes that can be got
90 Window window; /* which window this belongs to */
91 unsigned long event_mask; /* events that have been selected */
92 int buffer_index; /* which buffer is this */
93 int side; /* Mono, Left, Right */
94 } XmbufBufferAttributes;
97 * per-buffer attributes that can be set
100 unsigned long event_mask; /* events that have been selected */
101 } XmbufSetBufferAttributes;
105 * per-screen buffer info (there will be lists of them)
108 VisualID visualid; /* visual usuable at this depth */
109 int max_buffers; /* most buffers for this visual */
110 int depth; /* depth of buffers to be created */
115 extern Bool XmbufQueryExtension(
117 int* /* event_base_return */,
118 int* /* error_base_return */
121 extern Status XmbufGetVersion(
123 int* /* major_version_return */,
124 int* /* minor_version_return */
127 extern int XmbufCreateBuffers(
131 int /* update_action */,
132 int /* update_hint */,
133 Multibuffer* /* buffers */
136 extern void XmbufDestroyBuffers(
141 extern void XmbufDisplayBuffers(
144 Multibuffer* /* buffers */,
149 extern Status XmbufGetWindowAttributes(
152 XmbufWindowAttributes* /* attr */
155 extern void XmbufChangeWindowAttributes(
158 unsigned long /* valuemask */,
159 XmbufSetWindowAttributes* /* attr */
162 extern Status XmbufGetBufferAttributes(
165 XmbufBufferAttributes* /* attr */
168 extern void XmbufChangeBufferAttributes(
171 unsigned long /* valuemask */,
172 XmbufSetBufferAttributes* /* attr */
175 extern Status XmbufGetScreenInfo(
178 int* /* nmono_return */,
179 XmbufBufferInfo** /* mono_info_return */,
180 int* /* nstereo_return */,
181 XmbufBufferInfo** /* stereo_info_return */
184 extern Window XmbufCreateStereoWindow(
189 unsigned int /* width */,
190 unsigned int /* height */,
191 unsigned int /* border_width */,
193 unsigned int /* class */,
194 Visual* /* visual */,
195 unsigned long /* valuemask */,
196 XSetWindowAttributes* /* attr */,
197 Multibuffer* /* leftp */,
198 Multibuffer* /* rightp */
201 extern void XmbufClearBufferArea(
203 Multibuffer /* buffer */,
206 unsigned int /* width */,
207 unsigned int /* height */,
213 #endif /* _MULTIBUF_H_ */