]> git.sesse.net Git - rdpsrv/blob - Xserver/lib/X11/Xutil.h
Support RDP5 logon packets.
[rdpsrv] / Xserver / lib / X11 / Xutil.h
1 /* $XConsortium: Xutil.h,v 11.78 94/04/17 20:21:56 rws Exp $ */
2 /* $XFree86: xc/lib/X11/Xutil.h,v 3.0 1996/12/09 11:49:36 dawes Exp $ */
3
4 /***********************************************************
5
6 Copyright (c) 1987  X Consortium
7
8 Permission is hereby granted, free of charge, to any person obtaining a copy
9 of this software and associated documentation files (the "Software"), to deal
10 in the Software without restriction, including without limitation the rights
11 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12 copies of the Software, and to permit persons to whom the Software is
13 furnished to do so, subject to the following conditions:
14
15 The above copyright notice and this permission notice shall be included in
16 all copies or substantial portions of the Software.
17
18 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
21 X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
22 AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
23 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
24
25 Except as contained in this notice, the name of the X Consortium shall not be
26 used in advertising or otherwise to promote the sale, use or other dealings
27 in this Software without prior written authorization from the X Consortium.
28
29
30 Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.
31
32                         All Rights Reserved
33
34 Permission to use, copy, modify, and distribute this software and its 
35 documentation for any purpose and without fee is hereby granted, 
36 provided that the above copyright notice appear in all copies and that
37 both that copyright notice and this permission notice appear in 
38 supporting documentation, and that the name of Digital not be
39 used in advertising or publicity pertaining to distribution of the
40 software without specific, written prior permission.  
41
42 DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
43 ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
44 DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
45 ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
46 WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
47 ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
48 SOFTWARE.
49
50 ******************************************************************/
51
52 #ifndef _XUTIL_H_
53 #define _XUTIL_H_
54
55 /* You must include <X11/Xlib.h> before including this file */
56
57 /* 
58  * Bitmask returned by XParseGeometry().  Each bit tells if the corresponding
59  * value (x, y, width, height) was found in the parsed string.
60  */
61 #define NoValue         0x0000
62 #define XValue          0x0001
63 #define YValue          0x0002
64 #define WidthValue      0x0004
65 #define HeightValue     0x0008
66 #define AllValues       0x000F
67 #define XNegative       0x0010
68 #define YNegative       0x0020
69
70 /*
71  * new version containing base_width, base_height, and win_gravity fields;
72  * used with WM_NORMAL_HINTS.
73  */
74 typedef struct {
75         long flags;     /* marks which fields in this structure are defined */
76         int x, y;               /* obsolete for new window mgrs, but clients */
77         int width, height;      /* should set so old wm's don't mess up */
78         int min_width, min_height;
79         int max_width, max_height;
80         int width_inc, height_inc;
81         struct {
82                 int x;  /* numerator */
83                 int y;  /* denominator */
84         } min_aspect, max_aspect;
85         int base_width, base_height;            /* added by ICCCM version 1 */
86         int win_gravity;                        /* added by ICCCM version 1 */
87 } XSizeHints;
88
89 /*
90  * The next block of definitions are for window manager properties that
91  * clients and applications use for communication.
92  */
93
94 /* flags argument in size hints */
95 #define USPosition      (1L << 0) /* user specified x, y */
96 #define USSize          (1L << 1) /* user specified width, height */
97
98 #define PPosition       (1L << 2) /* program specified position */
99 #define PSize           (1L << 3) /* program specified size */
100 #define PMinSize        (1L << 4) /* program specified minimum size */
101 #define PMaxSize        (1L << 5) /* program specified maximum size */
102 #define PResizeInc      (1L << 6) /* program specified resize increments */
103 #define PAspect         (1L << 7) /* program specified min and max aspect ratios */
104 #define PBaseSize       (1L << 8) /* program specified base for incrementing */
105 #define PWinGravity     (1L << 9) /* program specified window gravity */
106
107 /* obsolete */
108 #define PAllHints (PPosition|PSize|PMinSize|PMaxSize|PResizeInc|PAspect)
109
110
111
112 typedef struct {
113         long flags;     /* marks which fields in this structure are defined */
114         Bool input;     /* does this application rely on the window manager to
115                         get keyboard input? */
116         int initial_state;      /* see below */
117         Pixmap icon_pixmap;     /* pixmap to be used as icon */
118         Window icon_window;     /* window to be used as icon */
119         int icon_x, icon_y;     /* initial position of icon */
120         Pixmap icon_mask;       /* icon mask bitmap */
121         XID window_group;       /* id of related window group */
122         /* this structure may be extended in the future */
123 } XWMHints;
124
125 /* definition for flags of XWMHints */
126
127 #define InputHint               (1L << 0)
128 #define StateHint               (1L << 1)
129 #define IconPixmapHint          (1L << 2)
130 #define IconWindowHint          (1L << 3)
131 #define IconPositionHint        (1L << 4)
132 #define IconMaskHint            (1L << 5)
133 #define WindowGroupHint         (1L << 6)
134 #define AllHints (InputHint|StateHint|IconPixmapHint|IconWindowHint| \
135 IconPositionHint|IconMaskHint|WindowGroupHint)
136 #define XUrgencyHint            (1L << 8)
137
138 /* definitions for initial window state */
139 #define WithdrawnState 0        /* for windows that are not mapped */
140 #define NormalState 1   /* most applications want to start this way */
141 #define IconicState 3   /* application wants to start as an icon */
142
143 /*
144  * Obsolete states no longer defined by ICCCM
145  */
146 #define DontCareState 0 /* don't know or care */
147 #define ZoomState 2     /* application wants to start zoomed */
148 #define InactiveState 4 /* application believes it is seldom used; */
149                         /* some wm's may put it on inactive menu */
150
151
152 /*
153  * new structure for manipulating TEXT properties; used with WM_NAME, 
154  * WM_ICON_NAME, WM_CLIENT_MACHINE, and WM_COMMAND.
155  */
156 typedef struct {
157     unsigned char *value;               /* same as Property routines */
158     Atom encoding;                      /* prop type */
159     int format;                         /* prop data format: 8, 16, or 32 */
160     unsigned long nitems;               /* number of data items in value */
161 } XTextProperty;
162
163 #define XNoMemory -1
164 #define XLocaleNotSupported -2
165 #define XConverterNotFound -3
166
167 typedef enum {
168     XStringStyle,               /* STRING */
169     XCompoundTextStyle,         /* COMPOUND_TEXT */
170     XTextStyle,                 /* text in owner's encoding (current locale)*/
171     XStdICCTextStyle            /* STRING, else COMPOUND_TEXT */
172 } XICCEncodingStyle;
173
174 typedef struct {
175         int min_width, min_height;
176         int max_width, max_height;
177         int width_inc, height_inc;
178 } XIconSize;
179
180 typedef struct {
181         char *res_name;
182         char *res_class;
183 } XClassHint;
184
185 /*
186  * These macros are used to give some sugar to the image routines so that
187  * naive people are more comfortable with them.
188  */
189 #define XDestroyImage(ximage) \
190         ((*((ximage)->f.destroy_image))((ximage)))
191 #define XGetPixel(ximage, x, y) \
192         ((*((ximage)->f.get_pixel))((ximage), (x), (y)))
193 #define XPutPixel(ximage, x, y, pixel) \
194         ((*((ximage)->f.put_pixel))((ximage), (x), (y), (pixel)))
195 #define XSubImage(ximage, x, y, width, height)  \
196         ((*((ximage)->f.sub_image))((ximage), (x), (y), (width), (height)))
197 #define XAddPixel(ximage, value) \
198         ((*((ximage)->f.add_pixel))((ximage), (value)))
199
200 /*
201  * Compose sequence status structure, used in calling XLookupString.
202  */
203 typedef struct _XComposeStatus {
204     XPointer compose_ptr;       /* state table pointer */
205     int chars_matched;          /* match state */
206 } XComposeStatus;
207
208 /*
209  * Keysym macros, used on Keysyms to test for classes of symbols
210  */
211 #define IsKeypadKey(keysym) \
212   (((KeySym)(keysym) >= XK_KP_Space) && ((KeySym)(keysym) <= XK_KP_Equal))
213
214 #define IsPrivateKeypadKey(keysym) \
215   (((KeySym)(keysym) >= 0x11000000) && ((KeySym)(keysym) <= 0x1100FFFF))
216
217 #define IsCursorKey(keysym) \
218   (((KeySym)(keysym) >= XK_Home)     && ((KeySym)(keysym) <  XK_Select))
219
220 #define IsPFKey(keysym) \
221   (((KeySym)(keysym) >= XK_KP_F1)     && ((KeySym)(keysym) <= XK_KP_F4))
222
223 #define IsFunctionKey(keysym) \
224   (((KeySym)(keysym) >= XK_F1)       && ((KeySym)(keysym) <= XK_F35))
225
226 #define IsMiscFunctionKey(keysym) \
227   (((KeySym)(keysym) >= XK_Select)   && ((KeySym)(keysym) <= XK_Break))
228
229 #define IsModifierKey(keysym) \
230   ((((KeySym)(keysym) >= XK_Shift_L) && ((KeySym)(keysym) <= XK_Hyper_R)) \
231    || ((KeySym)(keysym) == XK_Mode_switch) \
232    || ((KeySym)(keysym) == XK_Num_Lock))
233 /*
234  * opaque reference to Region data type 
235  */
236 typedef struct _XRegion *Region; 
237
238 /* Return values from XRectInRegion() */
239  
240 #define RectangleOut 0
241 #define RectangleIn  1
242 #define RectanglePart 2
243  
244
245 /*
246  * Information used by the visual utility routines to find desired visual
247  * type from the many visuals a display may support.
248  */
249
250 typedef struct {
251   Visual *visual;
252   VisualID visualid;
253   int screen;
254   int depth;
255 #if defined(__cplusplus) || defined(c_plusplus)
256   int c_class;                                  /* C++ */
257 #else
258   int class;
259 #endif
260   unsigned long red_mask;
261   unsigned long green_mask;
262   unsigned long blue_mask;
263   int colormap_size;
264   int bits_per_rgb;
265 } XVisualInfo;
266
267 #define VisualNoMask            0x0
268 #define VisualIDMask            0x1
269 #define VisualScreenMask        0x2
270 #define VisualDepthMask         0x4
271 #define VisualClassMask         0x8
272 #define VisualRedMaskMask       0x10
273 #define VisualGreenMaskMask     0x20
274 #define VisualBlueMaskMask      0x40
275 #define VisualColormapSizeMask  0x80
276 #define VisualBitsPerRGBMask    0x100
277 #define VisualAllMask           0x1FF
278
279 /*
280  * This defines a window manager property that clients may use to
281  * share standard color maps of type RGB_COLOR_MAP:
282  */
283 typedef struct {
284         Colormap colormap;
285         unsigned long red_max;
286         unsigned long red_mult;
287         unsigned long green_max;
288         unsigned long green_mult;
289         unsigned long blue_max;
290         unsigned long blue_mult;
291         unsigned long base_pixel;
292         VisualID visualid;              /* added by ICCCM version 1 */
293         XID killid;                     /* added by ICCCM version 1 */
294 } XStandardColormap;
295
296 #define ReleaseByFreeingColormap ((XID) 1L)  /* for killid field above */
297
298
299 /*
300  * return codes for XReadBitmapFile and XWriteBitmapFile
301  */
302 #define BitmapSuccess           0
303 #define BitmapOpenFailed        1
304 #define BitmapFileInvalid       2
305 #define BitmapNoMemory          3
306
307 /****************************************************************
308  *
309  * Context Management
310  *
311  ****************************************************************/
312
313
314 /* Associative lookup table return codes */
315
316 #define XCSUCCESS 0     /* No error. */
317 #define XCNOMEM   1    /* Out of memory */
318 #define XCNOENT   2    /* No entry in table */
319
320 typedef int XContext;
321
322 #define XUniqueContext()       ((XContext) XrmUniqueQuark())
323 #define XStringToContext(string)   ((XContext) XrmStringToQuark(string))
324
325 _XFUNCPROTOBEGIN
326
327 /* The following declarations are alphabetized. */
328
329 extern XClassHint *XAllocClassHint (
330 #if NeedFunctionPrototypes
331     void
332 #endif
333 );
334
335 extern XIconSize *XAllocIconSize (
336 #if NeedFunctionPrototypes
337     void
338 #endif
339 );
340
341 extern XSizeHints *XAllocSizeHints (
342 #if NeedFunctionPrototypes
343     void
344 #endif
345 );
346
347 extern XStandardColormap *XAllocStandardColormap (
348 #if NeedFunctionPrototypes
349     void
350 #endif
351 );
352
353 extern XWMHints *XAllocWMHints (
354 #if NeedFunctionPrototypes
355     void
356 #endif
357 );
358
359 extern int XClipBox(
360 #if NeedFunctionPrototypes
361     Region              /* r */,
362     XRectangle*         /* rect_return */
363 #endif
364 );
365
366 extern Region XCreateRegion(
367 #if NeedFunctionPrototypes
368     void
369 #endif
370 );
371
372 extern char *XDefaultString(
373 #if NeedFunctionPrototypes
374     void
375 #endif
376 );
377
378 extern int XDeleteContext(
379 #if NeedFunctionPrototypes
380     Display*            /* display */,
381     XID                 /* rid */,
382     XContext            /* context */
383 #endif
384 );
385
386 extern int XDestroyRegion(
387 #if NeedFunctionPrototypes
388     Region              /* r */
389 #endif
390 );
391
392 extern int XEmptyRegion(
393 #if NeedFunctionPrototypes
394     Region              /* r */
395 #endif
396 );
397
398 extern int XEqualRegion(
399 #if NeedFunctionPrototypes
400     Region              /* r1 */,
401     Region              /* r2 */
402 #endif
403 );
404
405 extern int XFindContext(
406 #if NeedFunctionPrototypes
407     Display*            /* display */,
408     XID                 /* rid */,
409     XContext            /* context */,
410     XPointer*           /* data_return */
411 #endif
412 );
413
414 extern Status XGetClassHint(
415 #if NeedFunctionPrototypes
416     Display*            /* display */,
417     Window              /* w */,
418     XClassHint*         /* class_hints_return */
419 #endif
420 );
421
422 extern Status XGetIconSizes(
423 #if NeedFunctionPrototypes
424     Display*            /* display */,
425     Window              /* w */,
426     XIconSize**         /* size_list_return */,
427     int*                /* count_return */
428 #endif
429 );
430
431 extern Status XGetNormalHints(
432 #if NeedFunctionPrototypes
433     Display*            /* display */,
434     Window              /* w */,
435     XSizeHints*         /* hints_return */
436 #endif
437 );
438
439 extern Status XGetRGBColormaps(
440 #if NeedFunctionPrototypes
441     Display*            /* display */,
442     Window              /* w */,
443     XStandardColormap** /* stdcmap_return */,
444     int*                /* count_return */,
445     Atom                /* property */
446 #endif
447 );
448
449 extern Status XGetSizeHints(
450 #if NeedFunctionPrototypes
451     Display*            /* display */,
452     Window              /* w */,
453     XSizeHints*         /* hints_return */,
454     Atom                /* property */
455 #endif
456 );
457
458 extern Status XGetStandardColormap(
459 #if NeedFunctionPrototypes
460     Display*            /* display */,
461     Window              /* w */,
462     XStandardColormap*  /* colormap_return */,
463     Atom                /* property */                      
464 #endif
465 );
466
467 extern Status XGetTextProperty(
468 #if NeedFunctionPrototypes
469     Display*            /* display */,
470     Window              /* window */,
471     XTextProperty*      /* text_prop_return */,
472     Atom                /* property */
473 #endif
474 );
475
476 extern XVisualInfo *XGetVisualInfo(
477 #if NeedFunctionPrototypes
478     Display*            /* display */,
479     long                /* vinfo_mask */,
480     XVisualInfo*        /* vinfo_template */,
481     int*                /* nitems_return */
482 #endif
483 );
484
485 extern Status XGetWMClientMachine(
486 #if NeedFunctionPrototypes
487     Display*            /* display */,
488     Window              /* w */,
489     XTextProperty*      /* text_prop_return */
490 #endif
491 );
492
493 extern XWMHints *XGetWMHints(
494 #if NeedFunctionPrototypes
495     Display*            /* display */,
496     Window              /* w */               
497 #endif
498 );
499
500 extern Status XGetWMIconName(
501 #if NeedFunctionPrototypes
502     Display*            /* display */,
503     Window              /* w */,
504     XTextProperty*      /* text_prop_return */
505 #endif
506 );
507
508 extern Status XGetWMName(
509 #if NeedFunctionPrototypes
510     Display*            /* display */,
511     Window              /* w */,
512     XTextProperty*      /* text_prop_return */
513 #endif
514 );
515
516 extern Status XGetWMNormalHints(
517 #if NeedFunctionPrototypes
518     Display*            /* display */,
519     Window              /* w */,
520     XSizeHints*         /* hints_return */,
521     long*               /* supplied_return */ 
522 #endif
523 );
524
525 extern Status XGetWMSizeHints(
526 #if NeedFunctionPrototypes
527     Display*            /* display */,
528     Window              /* w */,
529     XSizeHints*         /* hints_return */,
530     long*               /* supplied_return */,
531     Atom                /* property */
532 #endif
533 );
534
535 extern Status XGetZoomHints(
536 #if NeedFunctionPrototypes
537     Display*            /* display */,
538     Window              /* w */,
539     XSizeHints*         /* zhints_return */
540 #endif
541 );
542
543 extern int XIntersectRegion(
544 #if NeedFunctionPrototypes
545     Region              /* sra */,
546     Region              /* srb */,
547     Region              /* dr_return */
548 #endif
549 );
550
551 extern void XConvertCase(
552 #if NeedFunctionPrototypes
553     KeySym              /* sym */,
554     KeySym*             /* lower */,
555     KeySym*             /* upper */
556 #endif
557 );
558
559 extern int XLookupString(
560 #if NeedFunctionPrototypes
561     XKeyEvent*          /* event_struct */,
562     char*               /* buffer_return */,
563     int                 /* bytes_buffer */,
564     KeySym*             /* keysym_return */,
565     XComposeStatus*     /* status_in_out */
566 #endif
567 );
568
569 extern Status XMatchVisualInfo(
570 #if NeedFunctionPrototypes
571     Display*            /* display */,
572     int                 /* screen */,
573     int                 /* depth */,
574     int                 /* class */,
575     XVisualInfo*        /* vinfo_return */
576 #endif
577 );
578
579 extern int XOffsetRegion(
580 #if NeedFunctionPrototypes
581     Region              /* r */,
582     int                 /* dx */,
583     int                 /* dy */
584 #endif
585 );
586
587 extern Bool XPointInRegion(
588 #if NeedFunctionPrototypes
589     Region              /* r */,
590     int                 /* x */,
591     int                 /* y */
592 #endif
593 );
594
595 extern Region XPolygonRegion(
596 #if NeedFunctionPrototypes
597     XPoint*             /* points */,
598     int                 /* n */,
599     int                 /* fill_rule */
600 #endif
601 );
602
603 extern int XRectInRegion(
604 #if NeedFunctionPrototypes
605     Region              /* r */,
606     int                 /* x */,
607     int                 /* y */,
608     unsigned int        /* width */,
609     unsigned int        /* height */
610 #endif
611 );
612
613 extern int XSaveContext(
614 #if NeedFunctionPrototypes
615     Display*            /* display */,
616     XID                 /* rid */,
617     XContext            /* context */,
618     _Xconst char*       /* data */
619 #endif
620 );
621
622 extern int XSetClassHint(
623 #if NeedFunctionPrototypes
624     Display*            /* display */,
625     Window              /* w */,
626     XClassHint*         /* class_hints */
627 #endif
628 );
629
630 extern int XSetIconSizes(
631 #if NeedFunctionPrototypes
632     Display*            /* display */,
633     Window              /* w */,
634     XIconSize*          /* size_list */,
635     int                 /* count */    
636 #endif
637 );
638
639 extern int XSetNormalHints(
640 #if NeedFunctionPrototypes
641     Display*            /* display */,
642     Window              /* w */,
643     XSizeHints*         /* hints */
644 #endif
645 );
646
647 extern void XSetRGBColormaps(
648 #if NeedFunctionPrototypes
649     Display*            /* display */,
650     Window              /* w */,
651     XStandardColormap*  /* stdcmaps */,
652     int                 /* count */,
653     Atom                /* property */
654 #endif
655 );
656
657 extern int XSetSizeHints(
658 #if NeedFunctionPrototypes
659     Display*            /* display */,
660     Window              /* w */,
661     XSizeHints*         /* hints */,
662     Atom                /* property */
663 #endif
664 );
665
666 extern int XSetStandardProperties(
667 #if NeedFunctionPrototypes
668     Display*            /* display */,
669     Window              /* w */,
670     _Xconst char*       /* window_name */,
671     _Xconst char*       /* icon_name */,
672     Pixmap              /* icon_pixmap */,
673     char**              /* argv */,
674     int                 /* argc */,
675     XSizeHints*         /* hints */
676 #endif
677 );
678
679 extern void XSetTextProperty(
680 #if NeedFunctionPrototypes
681     Display*            /* display */,
682     Window              /* w */,
683     XTextProperty*      /* text_prop */,
684     Atom                /* property */
685 #endif
686 );
687
688 extern void XSetWMClientMachine(
689 #if NeedFunctionPrototypes
690     Display*            /* display */,
691     Window              /* w */,
692     XTextProperty*      /* text_prop */
693 #endif
694 );
695
696 extern int XSetWMHints(
697 #if NeedFunctionPrototypes
698     Display*            /* display */,
699     Window              /* w */,
700     XWMHints*           /* wm_hints */
701 #endif
702 );
703
704 extern void XSetWMIconName(
705 #if NeedFunctionPrototypes
706     Display*            /* display */,
707     Window              /* w */,
708     XTextProperty*      /* text_prop */
709 #endif
710 );
711
712 extern void XSetWMName(
713 #if NeedFunctionPrototypes
714     Display*            /* display */,
715     Window              /* w */,
716     XTextProperty*      /* text_prop */
717 #endif
718 );
719
720 extern void XSetWMNormalHints(
721 #if NeedFunctionPrototypes
722     Display*            /* display */,
723     Window              /* w */,
724     XSizeHints*         /* hints */
725 #endif
726 );
727
728 extern void XSetWMProperties(
729 #if NeedFunctionPrototypes
730     Display*            /* display */,
731     Window              /* w */,
732     XTextProperty*      /* window_name */,
733     XTextProperty*      /* icon_name */,
734     char**              /* argv */,
735     int                 /* argc */,
736     XSizeHints*         /* normal_hints */,
737     XWMHints*           /* wm_hints */,
738     XClassHint*         /* class_hints */
739 #endif
740 );
741
742 extern void XmbSetWMProperties(
743 #if NeedFunctionPrototypes
744     Display*            /* display */,
745     Window              /* w */,
746     _Xconst char*       /* window_name */,
747     _Xconst char*       /* icon_name */,
748     char**              /* argv */,
749     int                 /* argc */,
750     XSizeHints*         /* normal_hints */,
751     XWMHints*           /* wm_hints */,
752     XClassHint*         /* class_hints */
753 #endif
754 );
755
756 extern void XSetWMSizeHints(
757 #if NeedFunctionPrototypes
758     Display*            /* display */,
759     Window              /* w */,
760     XSizeHints*         /* hints */,
761     Atom                /* property */
762 #endif
763 );
764
765 extern int XSetRegion(
766 #if NeedFunctionPrototypes
767     Display*            /* display */,
768     GC                  /* gc */,
769     Region              /* r */
770 #endif
771 );
772
773 extern void XSetStandardColormap(
774 #if NeedFunctionPrototypes
775     Display*            /* display */,
776     Window              /* w */,
777     XStandardColormap*  /* colormap */,
778     Atom                /* property */
779 #endif
780 );
781
782 extern int XSetZoomHints(
783 #if NeedFunctionPrototypes
784     Display*            /* display */,
785     Window              /* w */,
786     XSizeHints*         /* zhints */
787 #endif
788 );
789
790 extern int XShrinkRegion(
791 #if NeedFunctionPrototypes
792     Region              /* r */,
793     int                 /* dx */,
794     int                 /* dy */
795 #endif
796 );
797
798 extern Status XStringListToTextProperty(
799 #if NeedFunctionPrototypes
800     char**              /* list */,
801     int                 /* count */,
802     XTextProperty*      /* text_prop_return */
803 #endif
804 );
805
806 extern int XSubtractRegion(
807 #if NeedFunctionPrototypes
808     Region              /* sra */,
809     Region              /* srb */,
810     Region              /* dr_return */
811 #endif
812 );
813
814 extern int XmbTextListToTextProperty(
815 #if NeedFunctionPrototypes
816     Display*            /* display */,
817     char**              /* list */,
818     int                 /* count */,
819     XICCEncodingStyle   /* style */,
820     XTextProperty*      /* text_prop_return */
821 #endif
822 );
823
824 extern int XwcTextListToTextProperty(
825 #if NeedFunctionPrototypes
826     Display*            /* display */,
827     wchar_t**           /* list */,
828     int                 /* count */,
829     XICCEncodingStyle   /* style */,
830     XTextProperty*      /* text_prop_return */
831 #endif
832 );
833
834 extern void XwcFreeStringList(
835 #if NeedFunctionPrototypes
836     wchar_t**           /* list */
837 #endif
838 );
839
840 extern Status XTextPropertyToStringList(
841 #if NeedFunctionPrototypes
842     XTextProperty*      /* text_prop */,
843     char***             /* list_return */,
844     int*                /* count_return */
845 #endif
846 );
847
848 extern int XmbTextPropertyToTextList(
849 #if NeedFunctionPrototypes
850     Display*            /* display */,
851     XTextProperty*      /* text_prop */,
852     char***             /* list_return */,
853     int*                /* count_return */
854 #endif
855 );
856
857 extern int XwcTextPropertyToTextList(
858 #if NeedFunctionPrototypes
859     Display*            /* display */,
860     XTextProperty*      /* text_prop */,
861     wchar_t***          /* list_return */,
862     int*                /* count_return */
863 #endif
864 );
865
866 extern int XUnionRectWithRegion(
867 #if NeedFunctionPrototypes
868     XRectangle*         /* rectangle */,
869     Region              /* src_region */,
870     Region              /* dest_region_return */
871 #endif
872 );
873
874 extern int XUnionRegion(
875 #if NeedFunctionPrototypes
876     Region              /* sra */,
877     Region              /* srb */,
878     Region              /* dr_return */
879 #endif
880 );
881
882 extern int XWMGeometry(
883 #if NeedFunctionPrototypes
884     Display*            /* display */,
885     int                 /* screen_number */,
886     _Xconst char*       /* user_geometry */,
887     _Xconst char*       /* default_geometry */,
888     unsigned int        /* border_width */,
889     XSizeHints*         /* hints */,
890     int*                /* x_return */,
891     int*                /* y_return */,
892     int*                /* width_return */,
893     int*                /* height_return */,
894     int*                /* gravity_return */
895 #endif
896 );
897
898 extern int XXorRegion(
899 #if NeedFunctionPrototypes
900     Region              /* sra */,
901     Region              /* srb */,
902     Region              /* dr_return */
903 #endif
904 );
905
906 _XFUNCPROTOEND
907
908 #endif /* _XUTIL_H_ */