xorg-headers-native: haven't been updated since 2006, do so now
[openembedded.git] / recipes / xorg-lib / xorg-headers-native / X11 / CoreP.h
blob57836e615af0bf0bf750b5b8e284e5273aafe832
1 /*
2 * $Xorg: CoreP.h,v 1.4 2001/02/09 02:03:54 xorgcvs Exp $
3 * $oHeader: CoreP.h,v 1.2 88/08/18 15:54:37 asente Exp $
4 */
6 /***********************************************************
8 Copyright 1987, 1988, 1998 The Open Group
10 Permission to use, copy, modify, distribute, and sell this software and its
11 documentation for any purpose is hereby granted without fee, provided that
12 the above copyright notice appear in all copies and that both that
13 copyright notice and this permission notice appear in supporting
14 documentation.
16 The above copyright notice and this permission notice shall be included in
17 all copies or substantial portions of the Software.
19 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
22 OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
23 AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
24 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
26 Except as contained in this notice, the name of The Open Group shall not be
27 used in advertising or otherwise to promote the sale, use or other dealings
28 in this Software without prior written authorization from The Open Group.
31 Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts.
33 All Rights Reserved
35 Permission to use, copy, modify, and distribute this software and its
36 documentation for any purpose and without fee is hereby granted,
37 provided that the above copyright notice appear in all copies and that
38 both that copyright notice and this permission notice appear in
39 supporting documentation, and that the name of Digital not be
40 used in advertising or publicity pertaining to distribution of the
41 software without specific, written prior permission.
43 DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
44 ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
45 DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
46 ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
47 WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
48 ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
49 SOFTWARE.
51 ******************************************************************/
53 #ifndef XtCoreP_h
54 #define XtCoreP_h
56 #include <X11/Core.h>
58 _XFUNCPROTOBEGIN
60 externalref int _XtInheritTranslations;
62 #define XtInheritTranslations ((String) &_XtInheritTranslations)
63 #define XtInheritRealize ((XtRealizeProc) _XtInherit)
64 #define XtInheritResize ((XtWidgetProc) _XtInherit)
65 #define XtInheritExpose ((XtExposeProc) _XtInherit)
66 #define XtInheritSetValuesAlmost ((XtAlmostProc) _XtInherit)
67 #define XtInheritAcceptFocus ((XtAcceptFocusProc) _XtInherit)
68 #define XtInheritQueryGeometry ((XtGeometryHandler) _XtInherit)
69 #define XtInheritDisplayAccelerator ((XtStringProc) _XtInherit)
71 /***************************************************************
72 * Widget Core Data Structures
75 **************************************************************/
77 typedef struct _CorePart {
78 Widget self; /* pointer to widget itself */
79 WidgetClass widget_class; /* pointer to Widget's ClassRec */
80 Widget parent; /* parent widget */
81 XrmName xrm_name; /* widget resource name quarkified */
82 Boolean being_destroyed; /* marked for destroy */
83 XtCallbackList destroy_callbacks; /* who to call when widget destroyed */
84 XtPointer constraints; /* constraint record */
85 Position x, y; /* window position */
86 Dimension width, height; /* window dimensions */
87 Dimension border_width; /* window border width */
88 Boolean managed; /* is widget geometry managed? */
89 Boolean sensitive; /* is widget sensitive to user events*/
90 Boolean ancestor_sensitive; /* are all ancestors sensitive? */
91 XtEventTable event_table; /* private to event dispatcher */
92 XtTMRec tm; /* translation management */
93 XtTranslations accelerators; /* accelerator translations */
94 Pixel border_pixel; /* window border pixel */
95 Pixmap border_pixmap; /* window border pixmap or NULL */
96 WidgetList popup_list; /* list of popups */
97 Cardinal num_popups; /* how many popups */
98 String name; /* widget resource name */
99 Screen *screen; /* window's screen */
100 Colormap colormap; /* colormap */
101 Window window; /* window ID */
102 Cardinal depth; /* number of planes in window */
103 Pixel background_pixel; /* window background pixel */
104 Pixmap background_pixmap; /* window background pixmap or NULL */
105 Boolean visible; /* is window mapped and not occluded?*/
106 Boolean mapped_when_managed;/* map window if it's managed? */
107 } CorePart;
109 typedef struct _WidgetRec {
110 CorePart core;
111 } WidgetRec, CoreRec;
115 /******************************************************************
117 * Core Class Structure. Widgets, regardless of their class, will have
118 * these fields. All widgets of a given class will have the same values
119 * for these fields. Widgets of a given class may also have additional
120 * common fields. These additional fields are included in incremental
121 * class structures, such as CommandClass.
123 * The fields that are specific to this subclass, as opposed to fields that
124 * are part of the superclass, are called "subclass fields" below. Many
125 * procedures are responsible only for the subclass fields, and not for
126 * any superclass fields.
128 ********************************************************************/
130 typedef struct _CoreClassPart {
131 WidgetClass superclass; /* pointer to superclass ClassRec */
132 String class_name; /* widget resource class name */
133 Cardinal widget_size; /* size in bytes of widget record */
134 XtProc class_initialize; /* class initialization proc */
135 XtWidgetClassProc class_part_initialize; /* dynamic initialization */
136 XtEnum class_inited; /* has class been initialized? */
137 XtInitProc initialize; /* initialize subclass fields */
138 XtArgsProc initialize_hook; /* notify that initialize called */
139 XtRealizeProc realize; /* XCreateWindow for widget */
140 XtActionList actions; /* widget semantics name to proc map */
141 Cardinal num_actions; /* number of entries in actions */
142 XtResourceList resources; /* resources for subclass fields */
143 Cardinal num_resources; /* number of entries in resources */
144 XrmClass xrm_class; /* resource class quarkified */
145 Boolean compress_motion; /* compress MotionNotify for widget */
146 XtEnum compress_exposure; /* compress Expose events for widget*/
147 Boolean compress_enterleave;/* compress enter and leave events */
148 Boolean visible_interest; /* select for VisibilityNotify */
149 XtWidgetProc destroy; /* free data for subclass pointers */
150 XtWidgetProc resize; /* geom manager changed widget size */
151 XtExposeProc expose; /* rediplay window */
152 XtSetValuesFunc set_values; /* set subclass resource values */
153 XtArgsFunc set_values_hook; /* notify that set_values called */
154 XtAlmostProc set_values_almost; /* set_values got "Almost" geo reply */
155 XtArgsProc get_values_hook; /* notify that get_values called */
156 XtAcceptFocusProc accept_focus; /* assign input focus to widget */
157 XtVersionType version; /* version of intrinsics used */
158 XtPointer callback_private; /* list of callback offsets */
159 String tm_table; /* state machine */
160 XtGeometryHandler query_geometry; /* return preferred geometry */
161 XtStringProc display_accelerator;/* display your accelerator */
162 XtPointer extension; /* pointer to extension record */
163 } CoreClassPart;
165 typedef struct _WidgetClassRec {
166 CoreClassPart core_class;
167 } WidgetClassRec, CoreClassRec;
169 externalref WidgetClassRec widgetClassRec;
170 #define coreClassRec widgetClassRec
172 _XFUNCPROTOEND
174 #endif /* _XtCoreP_h */
175 /* DON'T ADD STUFF AFTER THIS #endif */