1444c061aSmrg/*********************************************************** 2444c061aSmrg 3444c061aSmrgCopyright 1987, 1988, 1998 The Open Group 4444c061aSmrg 5444c061aSmrgPermission to use, copy, modify, distribute, and sell this software and its 6444c061aSmrgdocumentation for any purpose is hereby granted without fee, provided that 7444c061aSmrgthe above copyright notice appear in all copies and that both that 8444c061aSmrgcopyright notice and this permission notice appear in supporting 9444c061aSmrgdocumentation. 10444c061aSmrg 11444c061aSmrgThe above copyright notice and this permission notice shall be included in 12444c061aSmrgall copies or substantial portions of the Software. 13444c061aSmrg 14444c061aSmrgTHE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15444c061aSmrgIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16444c061aSmrgFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17444c061aSmrgOPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN 18444c061aSmrgAN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 19444c061aSmrgCONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 20444c061aSmrg 21444c061aSmrgExcept as contained in this notice, the name of The Open Group shall not be 22444c061aSmrgused in advertising or otherwise to promote the sale, use or other dealings 23444c061aSmrgin this Software without prior written authorization from The Open Group. 24444c061aSmrg 25444c061aSmrg 26444c061aSmrgCopyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts. 27444c061aSmrg 28444c061aSmrg All Rights Reserved 29444c061aSmrg 309e7bcd65SmrgPermission to use, copy, modify, and distribute this software and its 319e7bcd65Smrgdocumentation for any purpose and without fee is hereby granted, 32444c061aSmrgprovided that the above copyright notice appear in all copies and that 339e7bcd65Smrgboth that copyright notice and this permission notice appear in 34444c061aSmrgsupporting documentation, and that the name of Digital not be 35444c061aSmrgused in advertising or publicity pertaining to distribution of the 369e7bcd65Smrgsoftware without specific, written prior permission. 37444c061aSmrg 38444c061aSmrgDIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING 39444c061aSmrgALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL 40444c061aSmrgDIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR 41444c061aSmrgANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 42444c061aSmrgWHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, 43444c061aSmrgARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS 44444c061aSmrgSOFTWARE. 45444c061aSmrg 46444c061aSmrg******************************************************************/ 47444c061aSmrg 48444c061aSmrg#ifndef XtCoreP_h 49444c061aSmrg#define XtCoreP_h 50444c061aSmrg 51444c061aSmrg#include <X11/Core.h> 52444c061aSmrg 532265a131Smrg_XFUNCPROTOBEGIN 542265a131Smrg 55444c061aSmrgexternalref int _XtInheritTranslations; 56444c061aSmrg 57444c061aSmrg#define XtInheritTranslations ((String) &_XtInheritTranslations) 58444c061aSmrg#define XtInheritRealize ((XtRealizeProc) _XtInherit) 59444c061aSmrg#define XtInheritResize ((XtWidgetProc) _XtInherit) 60444c061aSmrg#define XtInheritExpose ((XtExposeProc) _XtInherit) 61444c061aSmrg#define XtInheritSetValuesAlmost ((XtAlmostProc) _XtInherit) 62444c061aSmrg#define XtInheritAcceptFocus ((XtAcceptFocusProc) _XtInherit) 63444c061aSmrg#define XtInheritQueryGeometry ((XtGeometryHandler) _XtInherit) 64444c061aSmrg#define XtInheritDisplayAccelerator ((XtStringProc) _XtInherit) 65444c061aSmrg 66444c061aSmrg/*************************************************************** 67444c061aSmrg * Widget Core Data Structures 68444c061aSmrg * 69444c061aSmrg * 70444c061aSmrg **************************************************************/ 71444c061aSmrg 72444c061aSmrgtypedef struct _CorePart { 73444c061aSmrg Widget self; /* pointer to widget itself */ 74444c061aSmrg WidgetClass widget_class; /* pointer to Widget's ClassRec */ 75444c061aSmrg Widget parent; /* parent widget */ 76444c061aSmrg XrmName xrm_name; /* widget resource name quarkified */ 77444c061aSmrg Boolean being_destroyed; /* marked for destroy */ 78444c061aSmrg XtCallbackList destroy_callbacks; /* who to call when widget destroyed */ 79444c061aSmrg XtPointer constraints; /* constraint record */ 80444c061aSmrg Position x, y; /* window position */ 81444c061aSmrg Dimension width, height; /* window dimensions */ 82444c061aSmrg Dimension border_width; /* window border width */ 83444c061aSmrg Boolean managed; /* is widget geometry managed? */ 84444c061aSmrg Boolean sensitive; /* is widget sensitive to user events*/ 85444c061aSmrg Boolean ancestor_sensitive; /* are all ancestors sensitive? */ 86444c061aSmrg XtEventTable event_table; /* private to event dispatcher */ 87444c061aSmrg XtTMRec tm; /* translation management */ 88444c061aSmrg XtTranslations accelerators; /* accelerator translations */ 89444c061aSmrg Pixel border_pixel; /* window border pixel */ 90444c061aSmrg Pixmap border_pixmap; /* window border pixmap or NULL */ 91444c061aSmrg WidgetList popup_list; /* list of popups */ 92444c061aSmrg Cardinal num_popups; /* how many popups */ 93444c061aSmrg String name; /* widget resource name */ 94444c061aSmrg Screen *screen; /* window's screen */ 95444c061aSmrg Colormap colormap; /* colormap */ 96444c061aSmrg Window window; /* window ID */ 97444c061aSmrg Cardinal depth; /* number of planes in window */ 98444c061aSmrg Pixel background_pixel; /* window background pixel */ 99444c061aSmrg Pixmap background_pixmap; /* window background pixmap or NULL */ 100444c061aSmrg Boolean visible; /* is window mapped and not occluded?*/ 101444c061aSmrg Boolean mapped_when_managed;/* map window if it's managed? */ 102444c061aSmrg} CorePart; 103444c061aSmrg 104444c061aSmrgtypedef struct _WidgetRec { 105444c061aSmrg CorePart core; 106444c061aSmrg } WidgetRec, CoreRec; 107444c061aSmrg 108444c061aSmrg 109444c061aSmrg 110444c061aSmrg/****************************************************************** 111444c061aSmrg * 112444c061aSmrg * Core Class Structure. Widgets, regardless of their class, will have 113444c061aSmrg * these fields. All widgets of a given class will have the same values 114444c061aSmrg * for these fields. Widgets of a given class may also have additional 115444c061aSmrg * common fields. These additional fields are included in incremental 116444c061aSmrg * class structures, such as CommandClass. 117444c061aSmrg * 118444c061aSmrg * The fields that are specific to this subclass, as opposed to fields that 119444c061aSmrg * are part of the superclass, are called "subclass fields" below. Many 120444c061aSmrg * procedures are responsible only for the subclass fields, and not for 121444c061aSmrg * any superclass fields. 122444c061aSmrg * 123444c061aSmrg ********************************************************************/ 124444c061aSmrg 125444c061aSmrgtypedef struct _CoreClassPart { 126444c061aSmrg WidgetClass superclass; /* pointer to superclass ClassRec */ 127444c061aSmrg String class_name; /* widget resource class name */ 128444c061aSmrg Cardinal widget_size; /* size in bytes of widget record */ 129444c061aSmrg XtProc class_initialize; /* class initialization proc */ 130444c061aSmrg XtWidgetClassProc class_part_initialize; /* dynamic initialization */ 131444c061aSmrg XtEnum class_inited; /* has class been initialized? */ 132444c061aSmrg XtInitProc initialize; /* initialize subclass fields */ 133444c061aSmrg XtArgsProc initialize_hook; /* notify that initialize called */ 134444c061aSmrg XtRealizeProc realize; /* XCreateWindow for widget */ 135444c061aSmrg XtActionList actions; /* widget semantics name to proc map */ 136444c061aSmrg Cardinal num_actions; /* number of entries in actions */ 137444c061aSmrg XtResourceList resources; /* resources for subclass fields */ 138444c061aSmrg Cardinal num_resources; /* number of entries in resources */ 139444c061aSmrg XrmClass xrm_class; /* resource class quarkified */ 140444c061aSmrg Boolean compress_motion; /* compress MotionNotify for widget */ 141444c061aSmrg XtEnum compress_exposure; /* compress Expose events for widget*/ 142444c061aSmrg Boolean compress_enterleave;/* compress enter and leave events */ 143444c061aSmrg Boolean visible_interest; /* select for VisibilityNotify */ 144444c061aSmrg XtWidgetProc destroy; /* free data for subclass pointers */ 145444c061aSmrg XtWidgetProc resize; /* geom manager changed widget size */ 146444c061aSmrg XtExposeProc expose; /* rediplay window */ 147444c061aSmrg XtSetValuesFunc set_values; /* set subclass resource values */ 148444c061aSmrg XtArgsFunc set_values_hook; /* notify that set_values called */ 149444c061aSmrg XtAlmostProc set_values_almost; /* set_values got "Almost" geo reply */ 150444c061aSmrg XtArgsProc get_values_hook; /* notify that get_values called */ 151444c061aSmrg XtAcceptFocusProc accept_focus; /* assign input focus to widget */ 152444c061aSmrg XtVersionType version; /* version of intrinsics used */ 153444c061aSmrg XtPointer callback_private; /* list of callback offsets */ 154444c061aSmrg String tm_table; /* state machine */ 155444c061aSmrg XtGeometryHandler query_geometry; /* return preferred geometry */ 156444c061aSmrg XtStringProc display_accelerator;/* display your accelerator */ 157444c061aSmrg XtPointer extension; /* pointer to extension record */ 158444c061aSmrg } CoreClassPart; 159444c061aSmrg 160444c061aSmrgtypedef struct _WidgetClassRec { 161444c061aSmrg CoreClassPart core_class; 162444c061aSmrg} WidgetClassRec, CoreClassRec; 163444c061aSmrg 164444c061aSmrgexternalref WidgetClassRec widgetClassRec; 165444c061aSmrg#define coreClassRec widgetClassRec 166444c061aSmrg 1672265a131Smrg_XFUNCPROTOEND 1682265a131Smrg 169444c061aSmrg#endif /* _XtCoreP_h */ 170444c061aSmrg/* DON'T ADD STUFF AFTER THIS #endif */ 171