⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 intrinsic.h

📁 早期freebsd实现
💻 H
📖 第 1 页 / 共 5 页
字号:
/* $XConsortium: Intrinsic.h,v 1.174 91/09/09 16:25:56 converse Exp $ *//***********************************************************Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,and the Massachusetts Institute of Technology, Cambridge, Massachusetts.			All Rights ReservedPermission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appear in all copies and thatboth that copyright notice and this permission notice appear in supporting documentation, and that the names of Digital or MIT not beused in advertising or publicity pertaining to distribution of thesoftware without specific, written prior permission.  DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDINGALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALLDIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES ORANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THISSOFTWARE.******************************************************************/#ifndef _XtIntrinsic_h#define _XtIntrinsic_h#include	<X11/Xlib.h>#include	<X11/Xutil.h>#include	<X11/Xresource.h>#include	<X11/Xfuncproto.h>#ifdef XT_BC#include <X11/Xos.h>		/* for R4 compatibility */#else#include <X11/Xosdefs.h>#ifndef X_NOT_STDC_ENV#include <string.h>		/* for XtNewString */#else#ifdef SYSV#include <string.h>#else#include <strings.h>#endif /* SYSV else */#endif /* !X_NOT_STDC_ENV else */#endif /* XT_BC else */#define XtSpecificationRelease 5typedef char *String;#if NeedFunctionPrototypes/* We do this in order to get "const" declarations to work right.  We * use _XtString instead of String so that C++ applications can * #define String to something else if they choose, to avoid conflicts * with other C++ libraries. */#define _XtString char*/* _Xt names are private to Xt implementation, do not use in client code */#if NeedWidePrototypes#define _XtBoolean	int#define _XtDimension	unsigned int#define _XtKeyCode	unsigned int#define _XtPosition	int#define _XtXtEnum	unsigned int#else#define _XtBoolean	Boolean#define _XtDimension	Dimension#define _XtKeyCode	KeyCode#define _XtPosition	Position#define _XtXtEnum	XtEnum#endif /* NeedWidePrototypes */#endif /* NeedFunctionPrototypes */#ifndef NULL#define NULL 0#endif#ifdef VMS#define externalref globalref#define externaldef(psect) globaldef {"psect"} noshare#else#define externalref extern#define externaldef(psect)#endif /* VMS */#ifndef FALSE#define FALSE 0#define TRUE 1#endif#define XtNumber(arr)		((Cardinal) (sizeof(arr) / sizeof(arr[0])))typedef struct _WidgetRec *Widget;typedef Widget *WidgetList;typedef struct _WidgetClassRec *WidgetClass;typedef struct _CompositeRec *CompositeWidget;typedef struct _XtActionsRec *XtActionList;typedef struct _XtEventRec *XtEventTable;typedef struct _XtBoundAccActionRec *XtBoundAccActions;typedef struct _XtAppStruct *XtAppContext;typedef unsigned long	XtValueMask;typedef unsigned long	XtIntervalId;typedef unsigned long	XtInputId;typedef unsigned long	XtWorkProcId;typedef unsigned int	XtGeometryMask;typedef unsigned long	XtGCMask;   /* Mask of values that are used by widget*/typedef unsigned long	Pixel;	    /* Index into colormap		*/typedef int		XtCacheType;#define			XtCacheNone	  0x001#define			XtCacheAll	  0x002#define			XtCacheByDisplay  0x003#define			XtCacheRefCount	  0x100/**************************************************************** * * System Dependent Definitions; see spec for specific range * requirements.  Do not assume every implementation uses the * same base types! * * * XtArgVal ought to be a union of XtPointer, char *, long, int *, and proc * * but casting to union types is not really supported. * * So the typedef for XtArgVal should be chosen such that * *	sizeof (XtArgVal) >=	sizeof(XtPointer) *				sizeof(char *) *				sizeof(long) *				sizeof(int *) *				sizeof(proc *) * * ArgLists rely heavily on the above typedef. * ****************************************************************/#ifdef CRAYtypedef long		Boolean;typedef char*		XtArgVal;typedef long		XtEnum;#elsetypedef char		Boolean;typedef long		XtArgVal;typedef unsigned char	XtEnum;#endiftypedef unsigned int	Cardinal;typedef unsigned short	Dimension;  /* Size in pixels			*/typedef short		Position;   /* Offset from 0 coordinate		*/#if NeedFunctionPrototypestypedef void*		XtPointer;#elsetypedef char*		XtPointer;#endif/* The type Opaque is NOT part of the Xt standard, do NOT use it. *//* (It remains here only for backward compatibility.) */typedef XtPointer	Opaque;#include <X11/Core.h>#include <X11/Composite.h>#include <X11/Constraint.h>#include <X11/Object.h>#include <X11/RectObj.h>typedef struct _TranslationData *XtTranslations;typedef struct _TranslationData *XtAccelerators;typedef unsigned int Modifiers;typedef void (*XtActionProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    XEvent*		/* event */,    String*		/* params */,    Cardinal*		/* num_params */#endif);typedef XtActionProc* XtBoundActions;typedef struct _XtActionsRec{    String	 string;    XtActionProc proc;} XtActionsRec;typedef enum {/* address mode		parameter representation    *//* ------------		------------------------    */    XtAddress,		/* address		    */    XtBaseOffset,	/* offset		    */    XtImmediate,	/* constant		    */    XtResourceString,	/* resource name string	    */    XtResourceQuark,	/* resource name quark	    */    XtWidgetBaseOffset,	/* offset from ancestor	    */    XtProcedureArg	/* procedure to invoke	    */} XtAddressMode;typedef struct {    XtAddressMode   address_mode;    XtPointer	    address_id;    Cardinal	    size;} XtConvertArgRec, *XtConvertArgList;typedef void (*XtConvertArgProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    Cardinal*		/* size */,    XrmValue*		/* value */#endif);typedef struct {    XtGeometryMask request_mode;    Position x, y;    Dimension width, height, border_width;    Widget sibling;    int stack_mode;   /* Above, Below, TopIf, BottomIf, Opposite, DontChange */} XtWidgetGeometry;/* Additions to Xlib geometry requests: ask what would happen, don't do it */#define XtCWQueryOnly	(1 << 7)/* Additions to Xlib stack modes: don't change stack order */#define XtSMDontChange	5typedef void (*XtConverter)( /* obsolete */#if NeedFunctionPrototypes    XrmValue*		/* args */,    Cardinal*		/* num_args */,    XrmValue*		/* from */,    XrmValue*		/* to */#endif);typedef Boolean (*XtTypeConverter)(#if NeedFunctionPrototypes    Display*		/* dpy */,    XrmValue*		/* args */,    Cardinal*		/* num_args */,    XrmValue*		/* from */,    XrmValue*		/* to */,    XtPointer*		/* converter_data */#endif);typedef void (*XtDestructor)(#if NeedFunctionPrototypes    XtAppContext	/* app */,    XrmValue*		/* to */,    XtPointer 		/* converter_data */,    XrmValue*		/* args */,    Cardinal*		/* num_args */#endif);typedef Opaque XtCacheRef;typedef Opaque XtActionHookId;typedef void (*XtActionHookProc)(#if NeedFunctionPrototypes    Widget		/* w */,    XtPointer		/* client_data */,    String		/* action_name */,    XEvent*		/* event */,    String*		/* params */,    Cardinal*		/* num_params */#endif);typedef void (*XtKeyProc)(#if NeedFunctionPrototypes    Display*		/* dpy */,    _XtKeyCode 		/* keycode */,    Modifiers		/* modifiers */,    Modifiers*		/* modifiers_return */,    KeySym*		/* keysym_return */#endif);typedef void (*XtCaseProc)(#if NeedFunctionPrototypes    Display*		/* display */,    KeySym		/* keysym */,    KeySym*		/* lower_return */,    KeySym*		/* upper_return */#endif);typedef void (*XtEventHandler)(#if NeedFunctionPrototypes    Widget 		/* widget */,    XtPointer 		/* closure */,    XEvent*		/* event */,    Boolean*		/* continue_to_dispatch */#endif);typedef unsigned long EventMask;typedef enum {XtListHead, XtListTail } XtListPosition;typedef unsigned long	XtInputMask;#define XtInputNoneMask		0L#define XtInputReadMask		(1L<<0)#define XtInputWriteMask	(1L<<1)#define XtInputExceptMask	(1L<<2)typedef void (*XtTimerCallbackProc)(#if NeedFunctionPrototypes    XtPointer 		/* closure */,    XtIntervalId*	/* id */#endif);typedef void (*XtInputCallbackProc)(#if NeedFunctionPrototypes    XtPointer 		/* closure */,    int*		/* source */,    XtInputId*		/* id */#endif);typedef struct {    String	name;    XtArgVal	value;} Arg, *ArgList;typedef XtPointer	XtVarArgsList;typedef void (*XtCallbackProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    XtPointer 		/* closure */,	/* data the application registered */    XtPointer 		/* call_data */	/* callback specific data */#endif);typedef struct _XtCallbackRec {    XtCallbackProc  callback;    XtPointer	    closure;} XtCallbackRec, *XtCallbackList;typedef enum {	XtCallbackNoList,	XtCallbackHasNone,	XtCallbackHasSome} XtCallbackStatus;typedef enum  {    XtGeometryYes,	  /* Request accepted. */    XtGeometryNo,	  /* Request denied. */    XtGeometryAlmost,	  /* Request denied, but willing to take replyBox. */    XtGeometryDone	  /* Request accepted and done. */} XtGeometryResult;typedef enum {XtGrabNone, XtGrabNonexclusive, XtGrabExclusive} XtGrabKind;typedef struct {    Widget  shell_widget;    Widget  enable_widget;} XtPopdownIDRec, *XtPopdownID;typedef struct _XtResource {    String	resource_name;	/* Resource name			    */    String	resource_class;	/* Resource class			    */    String	resource_type;	/* Representation type desired		    */    Cardinal	resource_size;	/* Size in bytes of representation	    */    Cardinal	resource_offset;/* Offset from base to put resource value   */    String	default_type;	/* representation type of specified default */    XtPointer	default_addr;	/* Address of default resource		    */} XtResource, *XtResourceList;typedef void (*XtResourceDefaultProc)(#if NeedFunctionPrototypes    Widget	/* widget */,    int		/* offset */,    XrmValue*	/* value */#endif);typedef String (*XtLanguageProc)(#if NeedFunctionPrototypes    Display*	/* dpy */,    String	/* xnl */,    XtPointer	/* client_data */#endif);typedef void (*XtErrorMsgHandler)(#if NeedFunctionPrototypes    String 		/* name */,    String		/* type */,    String		/* class */,    String		/* default */,    String*		/* params */,    Cardinal*		/* num_params */#endif);typedef void (*XtErrorHandler)(#if NeedFunctionPrototypes  String		/* msg */#endif);typedef void (*XtCreatePopupChildProc)(#if NeedFunctionPrototypes    Widget	/* shell */#endif);typedef Boolean (*XtWorkProc)(#if NeedFunctionPrototypes    XtPointer 		/* closure */	/* data the application registered */#endif);typedef struct {    char match;    String substitution;} SubstitutionRec, *Substitution;typedef Boolean (*XtFilePredicate)(#if NeedFunctionPrototypes   String /* filename */#endif);typedef XtPointer XtRequestId;typedef Boolean (*XtConvertSelectionProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    Atom*		/* selection */,    Atom*		/* target */,    Atom*		/* type_return */,    XtPointer*		/* value_return */,    unsigned long*	/* length_return */,    int*		/* format_return */#endif);typedef void (*XtLoseSelectionProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    Atom*		/* selection */#endif);typedef void (*XtSelectionDoneProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    Atom*		/* selection */,    Atom*		/* target */#endif);typedef void (*XtSelectionCallbackProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    XtPointer 		/* closure */,    Atom*		/* selection */,    Atom*		/* type */,    XtPointer 		/* value */,    unsigned long*	/* length */,    int*		/* format */#endif);typedef void (*XtLoseSelectionIncrProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    Atom*		/* selection */,    XtPointer 		/* client_data */#endif);typedef void (*XtSelectionDoneIncrProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    Atom*		/* selection */,    Atom*		/* target */,    XtRequestId*	/* receiver_id */,    XtPointer 		/* client_data */#endif);typedef Boolean (*XtConvertSelectionIncrProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    Atom*		/* selection */,    Atom*		/* target */,    Atom*		/* type */,    XtPointer*		/* value */,    unsigned long*	/* length */,    int*		/* format */,    unsigned long*	/* max_length */,    XtPointer 		/* client_data */,    XtRequestId*	/* receiver_id */#endif);typedef void (*XtCancelConvertSelectionProc)(#if NeedFunctionPrototypes    Widget 		/* widget */,    Atom*		/* selection */,    Atom*		/* target */,    XtRequestId*	/* receiver_id */,    XtPointer 		/* client_data */#endif);/*************************************************************** * * Exported Interfaces * ****************************************************************/_XFUNCPROTOBEGINextern Boolean XtConvertAndStore(#if NeedFunctionPrototypes    Widget 		/* widget */,    _Xconst _XtString 	/* from_type */,    XrmValue*		/* from */,    _Xconst _XtString 	/* to_type */,    XrmValue*		/* to_in_out */#endif);extern Boolean XtCallConverter(#if NeedFunctionPrototypes    Display*		/* dpy */,    XtTypeConverter 	/* converter */,    XrmValuePtr 	/* args */,    Cardinal 		/* num_args */,    XrmValuePtr 	/* from */,    XrmValue*		/* to_in_out */,    XtCacheRef*		/* cache_ref_return */#endif);extern Boolean XtDispatchEvent(#if NeedFunctionPrototypes    XEvent* 		/* event */#endif);extern Boolean XtCallAcceptFocus(#if NeedFunctionPrototypes    Widget 		/* widget */,    Time*		/* time */#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -