add directory Linux-0.98
This commit is contained in:
659
Linux-0.98/Yggdrasil-0.98.3/usr/X11/lib/Server/include/X.h
Normal file
659
Linux-0.98/Yggdrasil-0.98.3/usr/X11/lib/Server/include/X.h
Normal file
@@ -0,0 +1,659 @@
|
||||
/*
|
||||
* $XConsortium: X.h,v 1.66 88/09/06 15:55:56 jim Exp $
|
||||
*/
|
||||
|
||||
/* Definitions for the X window system likely to be used by applications */
|
||||
|
||||
#ifndef X_H
|
||||
#define X_H
|
||||
|
||||
/***********************************************************
|
||||
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
|
||||
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.
|
||||
|
||||
All Rights Reserved
|
||||
|
||||
Permission 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 that
|
||||
both that copyright notice and this permission notice appear in
|
||||
supporting documentation, and that the names of Digital or MIT not be
|
||||
used in advertising or publicity pertaining to distribution of the
|
||||
software without specific, written prior permission.
|
||||
|
||||
DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
|
||||
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
|
||||
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
|
||||
ANY 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 THIS
|
||||
SOFTWARE.
|
||||
|
||||
******************************************************************/
|
||||
#define X_PROTOCOL 11 /* current protocol version */
|
||||
#define X_PROTOCOL_REVISION 0 /* current minor version */
|
||||
|
||||
/* Resources */
|
||||
|
||||
typedef unsigned long XID;
|
||||
|
||||
typedef XID Window;
|
||||
typedef XID Drawable;
|
||||
typedef XID Font;
|
||||
typedef XID Pixmap;
|
||||
typedef XID Cursor;
|
||||
typedef XID Colormap;
|
||||
typedef XID GContext;
|
||||
typedef XID KeySym;
|
||||
|
||||
typedef unsigned long Mask;
|
||||
|
||||
typedef unsigned long Atom;
|
||||
|
||||
typedef unsigned long VisualID;
|
||||
|
||||
typedef unsigned long Time;
|
||||
|
||||
typedef unsigned char KeyCode;
|
||||
|
||||
/*****************************************************************
|
||||
* RESERVED RESOURCE AND CONSTANT DEFINITIONS
|
||||
*****************************************************************/
|
||||
|
||||
#define None 0L /* universal null resource or null atom */
|
||||
|
||||
#define ParentRelative 1L /* background pixmap in CreateWindow
|
||||
and ChangeWindowAttributes */
|
||||
|
||||
#define CopyFromParent 0L /* border pixmap in CreateWindow
|
||||
and ChangeWindowAttributes
|
||||
special VisualID and special window
|
||||
class passed to CreateWindow */
|
||||
|
||||
#define PointerWindow 0L /* destination window in SendEvent */
|
||||
#define InputFocus 1L /* destination window in SendEvent */
|
||||
|
||||
#define PointerRoot 1L /* focus window in SetInputFocus */
|
||||
|
||||
#define AnyPropertyType 0L /* special Atom, passed to GetProperty */
|
||||
|
||||
#define AnyKey 0L /* special Key Code, passed to GrabKey */
|
||||
|
||||
#define AnyButton 0L /* special Button Code, passed to GrabButton */
|
||||
|
||||
#define AllTemporary 0L /* special Resource ID passed to KillClient */
|
||||
|
||||
#define CurrentTime 0L /* special Time */
|
||||
|
||||
#define NoSymbol 0L /* special KeySym */
|
||||
|
||||
/*****************************************************************
|
||||
* EVENT DEFINITIONS
|
||||
*****************************************************************/
|
||||
|
||||
/* Input Event Masks. Used as event-mask window attribute and as arguments
|
||||
to Grab requests. Not to be confused with event names. */
|
||||
|
||||
#define NoEventMask 0L
|
||||
#define KeyPressMask (1L<<0)
|
||||
#define KeyReleaseMask (1L<<1)
|
||||
#define ButtonPressMask (1L<<2)
|
||||
#define ButtonReleaseMask (1L<<3)
|
||||
#define EnterWindowMask (1L<<4)
|
||||
#define LeaveWindowMask (1L<<5)
|
||||
#define PointerMotionMask (1L<<6)
|
||||
#define PointerMotionHintMask (1L<<7)
|
||||
#define Button1MotionMask (1L<<8)
|
||||
#define Button2MotionMask (1L<<9)
|
||||
#define Button3MotionMask (1L<<10)
|
||||
#define Button4MotionMask (1L<<11)
|
||||
#define Button5MotionMask (1L<<12)
|
||||
#define ButtonMotionMask (1L<<13)
|
||||
#define KeymapStateMask (1L<<14)
|
||||
#define ExposureMask (1L<<15)
|
||||
#define VisibilityChangeMask (1L<<16)
|
||||
#define StructureNotifyMask (1L<<17)
|
||||
#define ResizeRedirectMask (1L<<18)
|
||||
#define SubstructureNotifyMask (1L<<19)
|
||||
#define SubstructureRedirectMask (1L<<20)
|
||||
#define FocusChangeMask (1L<<21)
|
||||
#define PropertyChangeMask (1L<<22)
|
||||
#define ColormapChangeMask (1L<<23)
|
||||
#define OwnerGrabButtonMask (1L<<24)
|
||||
|
||||
/* Event names. Used in "type" field in XEvent structures. Not to be
|
||||
confused with event masks above. They start from 2 because 0 and 1
|
||||
are reserved in the protocol for errors and replies. */
|
||||
|
||||
#define KeyPress 2
|
||||
#define KeyRelease 3
|
||||
#define ButtonPress 4
|
||||
#define ButtonRelease 5
|
||||
#define MotionNotify 6
|
||||
#define EnterNotify 7
|
||||
#define LeaveNotify 8
|
||||
#define FocusIn 9
|
||||
#define FocusOut 10
|
||||
#define KeymapNotify 11
|
||||
#define Expose 12
|
||||
#define GraphicsExpose 13
|
||||
#define NoExpose 14
|
||||
#define VisibilityNotify 15
|
||||
#define CreateNotify 16
|
||||
#define DestroyNotify 17
|
||||
#define UnmapNotify 18
|
||||
#define MapNotify 19
|
||||
#define MapRequest 20
|
||||
#define ReparentNotify 21
|
||||
#define ConfigureNotify 22
|
||||
#define ConfigureRequest 23
|
||||
#define GravityNotify 24
|
||||
#define ResizeRequest 25
|
||||
#define CirculateNotify 26
|
||||
#define CirculateRequest 27
|
||||
#define PropertyNotify 28
|
||||
#define SelectionClear 29
|
||||
#define SelectionRequest 30
|
||||
#define SelectionNotify 31
|
||||
#define ColormapNotify 32
|
||||
#define ClientMessage 33
|
||||
#define MappingNotify 34
|
||||
#define LASTEvent 35 /* must be bigger than any event # */
|
||||
|
||||
|
||||
/* Key masks. Used as modifiers to GrabButton and GrabKey, results of QueryPointer,
|
||||
state in various key-, mouse-, and button-related events. */
|
||||
|
||||
#define ShiftMask (1<<0)
|
||||
#define LockMask (1<<1)
|
||||
#define ControlMask (1<<2)
|
||||
#define Mod1Mask (1<<3)
|
||||
#define Mod2Mask (1<<4)
|
||||
#define Mod3Mask (1<<5)
|
||||
#define Mod4Mask (1<<6)
|
||||
#define Mod5Mask (1<<7)
|
||||
|
||||
/* modifier names. Used to build a SetModifierMapping request or
|
||||
to read a GetModifierMapping request. These correspond to the
|
||||
masks defined above. */
|
||||
#define ShiftMapIndex 0
|
||||
#define LockMapIndex 1
|
||||
#define ControlMapIndex 2
|
||||
#define Mod1MapIndex 3
|
||||
#define Mod2MapIndex 4
|
||||
#define Mod3MapIndex 5
|
||||
#define Mod4MapIndex 6
|
||||
#define Mod5MapIndex 7
|
||||
|
||||
|
||||
/* button masks. Used in same manner as Key masks above. Not to be confused
|
||||
with button names below. */
|
||||
|
||||
#define Button1Mask (1<<8)
|
||||
#define Button2Mask (1<<9)
|
||||
#define Button3Mask (1<<10)
|
||||
#define Button4Mask (1<<11)
|
||||
#define Button5Mask (1<<12)
|
||||
|
||||
#define AnyModifier (1<<15) /* used in GrabButton, GrabKey */
|
||||
|
||||
|
||||
/* button names. Used as arguments to GrabButton and as detail in ButtonPress
|
||||
and ButtonRelease events. Not to be confused with button masks above.
|
||||
Note that 0 is already defined above as "AnyButton". */
|
||||
|
||||
#define Button1 1
|
||||
#define Button2 2
|
||||
#define Button3 3
|
||||
#define Button4 4
|
||||
#define Button5 5
|
||||
|
||||
/* Notify modes */
|
||||
|
||||
#define NotifyNormal 0
|
||||
#define NotifyGrab 1
|
||||
#define NotifyUngrab 2
|
||||
#define NotifyWhileGrabbed 3
|
||||
|
||||
#define NotifyHint 1 /* for MotionNotify events */
|
||||
|
||||
/* Notify detail */
|
||||
|
||||
#define NotifyAncestor 0
|
||||
#define NotifyVirtual 1
|
||||
#define NotifyInferior 2
|
||||
#define NotifyNonlinear 3
|
||||
#define NotifyNonlinearVirtual 4
|
||||
#define NotifyPointer 5
|
||||
#define NotifyPointerRoot 6
|
||||
#define NotifyDetailNone 7
|
||||
|
||||
/* Visibility notify */
|
||||
|
||||
#define VisibilityUnobscured 0
|
||||
#define VisibilityPartiallyObscured 1
|
||||
#define VisibilityFullyObscured 2
|
||||
|
||||
/* Circulation request */
|
||||
|
||||
#define PlaceOnTop 0
|
||||
#define PlaceOnBottom 1
|
||||
|
||||
/* protocol families */
|
||||
|
||||
#define FamilyInternet 0
|
||||
#define FamilyDECnet 1
|
||||
#define FamilyChaos 2
|
||||
|
||||
/* Property notification */
|
||||
|
||||
#define PropertyNewValue 0
|
||||
#define PropertyDelete 1
|
||||
|
||||
/* Color Map notification */
|
||||
|
||||
#define ColormapUninstalled 0
|
||||
#define ColormapInstalled 1
|
||||
|
||||
/* GrabPointer, GrabButton, GrabKeyboard, GrabKey Modes */
|
||||
|
||||
#define GrabModeSync 0
|
||||
#define GrabModeAsync 1
|
||||
|
||||
/* GrabPointer, GrabKeyboard reply status */
|
||||
|
||||
#define GrabSuccess 0
|
||||
#define AlreadyGrabbed 1
|
||||
#define GrabInvalidTime 2
|
||||
#define GrabNotViewable 3
|
||||
#define GrabFrozen 4
|
||||
|
||||
/* AllowEvents modes */
|
||||
|
||||
#define AsyncPointer 0
|
||||
#define SyncPointer 1
|
||||
#define ReplayPointer 2
|
||||
#define AsyncKeyboard 3
|
||||
#define SyncKeyboard 4
|
||||
#define ReplayKeyboard 5
|
||||
#define AsyncBoth 6
|
||||
#define SyncBoth 7
|
||||
|
||||
/* Used in SetInputFocus, GetInputFocus */
|
||||
|
||||
#define RevertToNone (int)None
|
||||
#define RevertToPointerRoot (int)PointerRoot
|
||||
#define RevertToParent 2
|
||||
|
||||
/*****************************************************************
|
||||
* ERROR CODES
|
||||
*****************************************************************/
|
||||
|
||||
#define Success 0 /* everything's okay */
|
||||
#define BadRequest 1 /* bad request code */
|
||||
#define BadValue 2 /* int parameter out of range */
|
||||
#define BadWindow 3 /* parameter not a Window */
|
||||
#define BadPixmap 4 /* parameter not a Pixmap */
|
||||
#define BadAtom 5 /* parameter not an Atom */
|
||||
#define BadCursor 6 /* parameter not a Cursor */
|
||||
#define BadFont 7 /* parameter not a Font */
|
||||
#define BadMatch 8 /* parameter mismatch */
|
||||
#define BadDrawable 9 /* parameter not a Pixmap or Window */
|
||||
#define BadAccess 10 /* depending on context:
|
||||
- key/button already grabbed
|
||||
- attempt to free an illegal
|
||||
cmap entry
|
||||
- attempt to store into a read-only
|
||||
color map entry.
|
||||
- attempt to modify the access control
|
||||
list from other than the local host.
|
||||
*/
|
||||
#define BadAlloc 11 /* insufficient resources */
|
||||
#define BadColor 12 /* no such colormap */
|
||||
#define BadGC 13 /* parameter not a GC */
|
||||
#define BadIDChoice 14 /* choice not in range or already used */
|
||||
#define BadName 15 /* font or color name doesn't exist */
|
||||
#define BadLength 16 /* Request length incorrect */
|
||||
#define BadImplementation 17 /* server is defective */
|
||||
|
||||
#define FirstExtensionError 128
|
||||
#define LastExtensionError 255
|
||||
|
||||
/*****************************************************************
|
||||
* WINDOW DEFINITIONS
|
||||
*****************************************************************/
|
||||
|
||||
/* Window classes used by CreateWindow */
|
||||
/* Note that CopyFromParent is already defined as 0 above */
|
||||
|
||||
#define InputOutput 1
|
||||
#define InputOnly 2
|
||||
|
||||
/* Window attributes for CreateWindow and ChangeWindowAttributes */
|
||||
|
||||
#define CWBackPixmap (1L<<0)
|
||||
#define CWBackPixel (1L<<1)
|
||||
#define CWBorderPixmap (1L<<2)
|
||||
#define CWBorderPixel (1L<<3)
|
||||
#define CWBitGravity (1L<<4)
|
||||
#define CWWinGravity (1L<<5)
|
||||
#define CWBackingStore (1L<<6)
|
||||
#define CWBackingPlanes (1L<<7)
|
||||
#define CWBackingPixel (1L<<8)
|
||||
#define CWOverrideRedirect (1L<<9)
|
||||
#define CWSaveUnder (1L<<10)
|
||||
#define CWEventMask (1L<<11)
|
||||
#define CWDontPropagate (1L<<12)
|
||||
#define CWColormap (1L<<13)
|
||||
#define CWCursor (1L<<14)
|
||||
|
||||
/* ConfigureWindow structure */
|
||||
|
||||
#define CWX (1<<0)
|
||||
#define CWY (1<<1)
|
||||
#define CWWidth (1<<2)
|
||||
#define CWHeight (1<<3)
|
||||
#define CWBorderWidth (1<<4)
|
||||
#define CWSibling (1<<5)
|
||||
#define CWStackMode (1<<6)
|
||||
|
||||
|
||||
/* Bit Gravity */
|
||||
|
||||
#define ForgetGravity 0
|
||||
#define NorthWestGravity 1
|
||||
#define NorthGravity 2
|
||||
#define NorthEastGravity 3
|
||||
#define WestGravity 4
|
||||
#define CenterGravity 5
|
||||
#define EastGravity 6
|
||||
#define SouthWestGravity 7
|
||||
#define SouthGravity 8
|
||||
#define SouthEastGravity 9
|
||||
#define StaticGravity 10
|
||||
|
||||
/* Window gravity + bit gravity above */
|
||||
|
||||
#define UnmapGravity 0
|
||||
|
||||
/* Used in CreateWindow for backing-store hint */
|
||||
|
||||
#define NotUseful 0
|
||||
#define WhenMapped 1
|
||||
#define Always 2
|
||||
|
||||
/* Used in GetWindowAttributes reply */
|
||||
|
||||
#define IsUnmapped 0
|
||||
#define IsUnviewable 1
|
||||
#define IsViewable 2
|
||||
|
||||
/* Used in ChangeSaveSet */
|
||||
|
||||
#define SetModeInsert 0
|
||||
#define SetModeDelete 1
|
||||
|
||||
/* Used in ChangeCloseDownMode */
|
||||
|
||||
#define DestroyAll 0
|
||||
#define RetainPermanent 1
|
||||
#define RetainTemporary 2
|
||||
|
||||
/* Window stacking method (in configureWindow) */
|
||||
|
||||
#define Above 0
|
||||
#define Below 1
|
||||
#define TopIf 2
|
||||
#define BottomIf 3
|
||||
#define Opposite 4
|
||||
|
||||
/* Circulation direction */
|
||||
|
||||
#define RaiseLowest 0
|
||||
#define LowerHighest 1
|
||||
|
||||
/* Property modes */
|
||||
|
||||
#define PropModeReplace 0
|
||||
#define PropModePrepend 1
|
||||
#define PropModeAppend 2
|
||||
|
||||
/*****************************************************************
|
||||
* GRAPHICS DEFINITIONS
|
||||
*****************************************************************/
|
||||
|
||||
/* graphics functions, as in GC.alu */
|
||||
|
||||
#define GXclear 0x0 /* 0 */
|
||||
#define GXand 0x1 /* src AND dst */
|
||||
#define GXandReverse 0x2 /* src AND NOT dst */
|
||||
#define GXcopy 0x3 /* src */
|
||||
#define GXandInverted 0x4 /* NOT src AND dst */
|
||||
#define GXnoop 0x5 /* dst */
|
||||
#define GXxor 0x6 /* src XOR dst */
|
||||
#define GXor 0x7 /* src OR dst */
|
||||
#define GXnor 0x8 /* NOT src AND NOT dst */
|
||||
#define GXequiv 0x9 /* NOT src XOR dst */
|
||||
#define GXinvert 0xa /* NOT dst */
|
||||
#define GXorReverse 0xb /* src OR NOT dst */
|
||||
#define GXcopyInverted 0xc /* NOT src */
|
||||
#define GXorInverted 0xd /* NOT src OR dst */
|
||||
#define GXnand 0xe /* NOT src OR NOT dst */
|
||||
#define GXset 0xf /* 1 */
|
||||
|
||||
/* LineStyle */
|
||||
|
||||
#define LineSolid 0
|
||||
#define LineOnOffDash 1
|
||||
#define LineDoubleDash 2
|
||||
|
||||
/* capStyle */
|
||||
|
||||
#define CapNotLast 0
|
||||
#define CapButt 1
|
||||
#define CapRound 2
|
||||
#define CapProjecting 3
|
||||
|
||||
/* joinStyle */
|
||||
|
||||
#define JoinMiter 0
|
||||
#define JoinRound 1
|
||||
#define JoinBevel 2
|
||||
|
||||
/* fillStyle */
|
||||
|
||||
#define FillSolid 0
|
||||
#define FillTiled 1
|
||||
#define FillStippled 2
|
||||
#define FillOpaqueStippled 3
|
||||
|
||||
/* fillRule */
|
||||
|
||||
#define EvenOddRule 0
|
||||
#define WindingRule 1
|
||||
|
||||
/* subwindow mode */
|
||||
|
||||
#define ClipByChildren 0
|
||||
#define IncludeInferiors 1
|
||||
|
||||
/* SetClipRectangles ordering */
|
||||
|
||||
#define Unsorted 0
|
||||
#define YSorted 1
|
||||
#define YXSorted 2
|
||||
#define YXBanded 3
|
||||
|
||||
/* CoordinateMode for drawing routines */
|
||||
|
||||
#define CoordModeOrigin 0 /* relative to the origin */
|
||||
#define CoordModePrevious 1 /* relative to previous point */
|
||||
|
||||
/* Polygon shapes */
|
||||
|
||||
#define Complex 0 /* paths may intersect */
|
||||
#define Nonconvex 1 /* no paths intersect, but not convex */
|
||||
#define Convex 2 /* wholly convex */
|
||||
|
||||
/* Arc modes for PolyFillArc */
|
||||
|
||||
#define ArcChord 0 /* join endpoints of arc */
|
||||
#define ArcPieSlice 1 /* join endpoints to center of arc */
|
||||
|
||||
/* GC components: masks used in CreateGC, CopyGC, ChangeGC, OR'ed into
|
||||
GC.stateChanges */
|
||||
|
||||
#define GCFunction (1L<<0)
|
||||
#define GCPlaneMask (1L<<1)
|
||||
#define GCForeground (1L<<2)
|
||||
#define GCBackground (1L<<3)
|
||||
#define GCLineWidth (1L<<4)
|
||||
#define GCLineStyle (1L<<5)
|
||||
#define GCCapStyle (1L<<6)
|
||||
#define GCJoinStyle (1L<<7)
|
||||
#define GCFillStyle (1L<<8)
|
||||
#define GCFillRule (1L<<9)
|
||||
#define GCTile (1L<<10)
|
||||
#define GCStipple (1L<<11)
|
||||
#define GCTileStipXOrigin (1L<<12)
|
||||
#define GCTileStipYOrigin (1L<<13)
|
||||
#define GCFont (1L<<14)
|
||||
#define GCSubwindowMode (1L<<15)
|
||||
#define GCGraphicsExposures (1L<<16)
|
||||
#define GCClipXOrigin (1L<<17)
|
||||
#define GCClipYOrigin (1L<<18)
|
||||
#define GCClipMask (1L<<19)
|
||||
#define GCDashOffset (1L<<20)
|
||||
#define GCDashList (1L<<21)
|
||||
#define GCArcMode (1L<<22)
|
||||
|
||||
#define GCLastBit 22
|
||||
/*****************************************************************
|
||||
* FONTS
|
||||
*****************************************************************/
|
||||
|
||||
/* used in QueryFont -- draw direction */
|
||||
|
||||
#define FontLeftToRight 0
|
||||
#define FontRightToLeft 1
|
||||
|
||||
#define FontChange 255
|
||||
|
||||
/*****************************************************************
|
||||
* IMAGING
|
||||
*****************************************************************/
|
||||
|
||||
/* ImageFormat -- PutImage, GetImage */
|
||||
|
||||
#define XYBitmap 0 /* depth 1, XYFormat */
|
||||
#define XYPixmap 1 /* depth == drawable depth */
|
||||
#define ZPixmap 2 /* depth == drawable depth */
|
||||
|
||||
/*****************************************************************
|
||||
* COLOR MAP STUFF
|
||||
*****************************************************************/
|
||||
|
||||
/* For CreateColormap */
|
||||
|
||||
#define AllocNone 0 /* create map with no entries */
|
||||
#define AllocAll 1 /* allocate entire map writeable */
|
||||
|
||||
|
||||
/* Flags used in StoreNamedColor, StoreColors */
|
||||
|
||||
#define DoRed (1<<0)
|
||||
#define DoGreen (1<<1)
|
||||
#define DoBlue (1<<2)
|
||||
|
||||
/*****************************************************************
|
||||
* CURSOR STUFF
|
||||
*****************************************************************/
|
||||
|
||||
/* QueryBestSize Class */
|
||||
|
||||
#define CursorShape 0 /* largest size that can be displayed */
|
||||
#define TileShape 1 /* size tiled fastest */
|
||||
#define StippleShape 2 /* size stippled fastest */
|
||||
|
||||
/*****************************************************************
|
||||
* KEYBOARD/POINTER STUFF
|
||||
*****************************************************************/
|
||||
|
||||
#define AutoRepeatModeOff 0
|
||||
#define AutoRepeatModeOn 1
|
||||
#define AutoRepeatModeDefault 2
|
||||
|
||||
#define LedModeOff 0
|
||||
#define LedModeOn 1
|
||||
|
||||
/* masks for ChangeKeyboardControl */
|
||||
|
||||
#define KBKeyClickPercent (1L<<0)
|
||||
#define KBBellPercent (1L<<1)
|
||||
#define KBBellPitch (1L<<2)
|
||||
#define KBBellDuration (1L<<3)
|
||||
#define KBLed (1L<<4)
|
||||
#define KBLedMode (1L<<5)
|
||||
#define KBKey (1L<<6)
|
||||
#define KBAutoRepeatMode (1L<<7)
|
||||
|
||||
#define MappingSuccess 0
|
||||
#define MappingBusy 1
|
||||
#define MappingFailed 2
|
||||
|
||||
#define MappingModifier 0
|
||||
#define MappingKeyboard 1
|
||||
#define MappingPointer 2
|
||||
|
||||
/*****************************************************************
|
||||
* SCREEN SAVER STUFF
|
||||
*****************************************************************/
|
||||
|
||||
#define DontPreferBlanking 0
|
||||
#define PreferBlanking 1
|
||||
#define DefaultBlanking 2
|
||||
|
||||
#define DisableScreenSaver 0
|
||||
#define DisableScreenInterval 0
|
||||
|
||||
#define DontAllowExposures 0
|
||||
#define AllowExposures 1
|
||||
#define DefaultExposures 2
|
||||
|
||||
/* for ForceScreenSaver */
|
||||
|
||||
#define ScreenSaverReset 0
|
||||
#define ScreenSaverActive 1
|
||||
|
||||
/*****************************************************************
|
||||
* HOSTS AND CONNECTIONS
|
||||
*****************************************************************/
|
||||
|
||||
/* for ChangeHosts */
|
||||
|
||||
#define HostInsert 0
|
||||
#define HostDelete 1
|
||||
|
||||
/* for ChangeAccessControl */
|
||||
|
||||
#define EnableAccess 1
|
||||
#define DisableAccess 0
|
||||
|
||||
/* Display classes used in opening the connection
|
||||
* Note that the statically allocated ones are even numbered and the
|
||||
* dynamically changeable ones are odd numbered */
|
||||
|
||||
#define StaticGray 0
|
||||
#define GrayScale 1
|
||||
#define StaticColor 2
|
||||
#define PseudoColor 3
|
||||
#define TrueColor 4
|
||||
#define DirectColor 5
|
||||
|
||||
|
||||
/* Byte order used in imageByteOrder and bitmapBitOrder */
|
||||
|
||||
#define LSBFirst 0
|
||||
#define MSBFirst 1
|
||||
|
||||
#endif /* X_H */
|
||||
157
Linux-0.98/Yggdrasil-0.98.3/usr/X11/lib/Server/include/misc.h
Normal file
157
Linux-0.98/Yggdrasil-0.98.3/usr/X11/lib/Server/include/misc.h
Normal file
@@ -0,0 +1,157 @@
|
||||
/***********************************************************
|
||||
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
|
||||
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.
|
||||
|
||||
All Rights Reserved
|
||||
|
||||
Permission 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 that
|
||||
both that copyright notice and this permission notice appear in
|
||||
supporting documentation, and that the names of Digital or MIT not be
|
||||
used in advertising or publicity pertaining to distribution of the
|
||||
software without specific, written prior permission.
|
||||
|
||||
DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
|
||||
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
|
||||
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
|
||||
ANY 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 THIS
|
||||
SOFTWARE.
|
||||
|
||||
******************************************************************/
|
||||
/* $XConsortium: misc.h,v 1.58 91/04/10 08:53:39 rws Exp $ */
|
||||
#ifndef MISC_H
|
||||
#define MISC_H 1
|
||||
/*
|
||||
* X internal definitions
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
extern unsigned long globalSerialNumber;
|
||||
extern unsigned long serverGeneration;
|
||||
|
||||
#include <X11/Xosdefs.h>
|
||||
|
||||
#ifndef NULL
|
||||
#ifndef X_NOT_STDC_ENV
|
||||
#include <stddef.h>
|
||||
#else
|
||||
#define NULL 0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#define MAXSCREENS 3
|
||||
#define MAXCLIENTS 128
|
||||
#define MAXFORMATS 8
|
||||
#define MAXVISUALS_PER_SCREEN 50
|
||||
|
||||
typedef unsigned char *pointer;
|
||||
typedef int Bool;
|
||||
typedef unsigned long PIXEL;
|
||||
typedef unsigned long ATOM;
|
||||
|
||||
|
||||
#ifndef TRUE
|
||||
#define TRUE 1
|
||||
#define FALSE 0
|
||||
#endif
|
||||
#include "os.h" /* for ALLOCATE_LOCAL and DEALLOCATE_LOCAL */
|
||||
#include <X11/Xfuncs.h> /* for bcopy, bzero, and bcmp */
|
||||
|
||||
#define NullBox ((BoxPtr)0)
|
||||
#define MILLI_PER_MIN (1000 * 60)
|
||||
#define MILLI_PER_SECOND (1000)
|
||||
|
||||
/* this next is used with None and ParentRelative to tell
|
||||
PaintWin() what to use to paint the background. Also used
|
||||
in the macro IS_VALID_PIXMAP */
|
||||
|
||||
#define USE_BACKGROUND_PIXEL 3
|
||||
#define USE_BORDER_PIXEL 3
|
||||
|
||||
|
||||
/* byte swap a long literal */
|
||||
#define lswapl(x) ((((x) & 0xff) << 24) |\
|
||||
(((x) & 0xff00) << 8) |\
|
||||
(((x) & 0xff0000) >> 8) |\
|
||||
(((x) >> 24) & 0xff))
|
||||
|
||||
/* byte swap a short literal */
|
||||
#define lswaps(x) ((((x) & 0xff) << 8) | (((x) >> 8) & 0xff))
|
||||
|
||||
#define min(a, b) (((a) < (b)) ? (a) : (b))
|
||||
#define max(a, b) (((a) > (b)) ? (a) : (b))
|
||||
#ifndef abs
|
||||
#define abs(a) ((a) > 0 ? (a) : -(a))
|
||||
#endif
|
||||
#ifndef fabs
|
||||
#define fabs(a) ((a) > 0.0 ? (a) : -(a)) /* floating absolute value */
|
||||
#endif
|
||||
#define sign(x) ((x) < 0 ? -1 : ((x) > 0 ? 1 : 0))
|
||||
/* this assumes b > 0 */
|
||||
#define modulus(a, b, d) if (((d) = (a) % (b)) < 0) (d) += (b)
|
||||
/*
|
||||
* return the least significant bit in x which is set
|
||||
*
|
||||
* This works on 1's complement and 2's complement machines.
|
||||
* If you care about the extra instruction on 2's complement
|
||||
* machines, change to ((x) & (-(x)))
|
||||
*/
|
||||
#define lowbit(x) ((x) & (~(x) + 1))
|
||||
|
||||
#define MAXSHORT 32767
|
||||
#define MINSHORT -MAXSHORT
|
||||
|
||||
|
||||
/* some macros to help swap requests, replies, and events */
|
||||
|
||||
#define LengthRestB(stuff) \
|
||||
(((unsigned long)stuff->length << 2) - sizeof(*stuff))
|
||||
|
||||
#define LengthRestS(stuff) \
|
||||
(((unsigned long)stuff->length << 1) - (sizeof(*stuff) >> 1))
|
||||
|
||||
#define LengthRestL(stuff) \
|
||||
((unsigned long)stuff->length - (sizeof(*stuff) >> 2))
|
||||
|
||||
#define SwapRestS(stuff) \
|
||||
SwapShorts((short *)(stuff + 1), LengthRestS(stuff))
|
||||
|
||||
#define SwapRestL(stuff) \
|
||||
SwapLongs((long *)(stuff + 1), LengthRestL(stuff))
|
||||
|
||||
/* byte swap a long */
|
||||
#define swapl(x, n) n = ((char *) (x))[0];\
|
||||
((char *) (x))[0] = ((char *) (x))[3];\
|
||||
((char *) (x))[3] = n;\
|
||||
n = ((char *) (x))[1];\
|
||||
((char *) (x))[1] = ((char *) (x))[2];\
|
||||
((char *) (x))[2] = n;
|
||||
|
||||
/* byte swap a short */
|
||||
#define swaps(x, n) n = ((char *) (x))[0];\
|
||||
((char *) (x))[0] = ((char *) (x))[1];\
|
||||
((char *) (x))[1] = n
|
||||
|
||||
/* copy long from src to dst byteswapping on the way */
|
||||
#define cpswapl(src, dst) \
|
||||
((char *)&(dst))[0] = ((char *) &(src))[3];\
|
||||
((char *)&(dst))[1] = ((char *) &(src))[2];\
|
||||
((char *)&(dst))[2] = ((char *) &(src))[1];\
|
||||
((char *)&(dst))[3] = ((char *) &(src))[0];
|
||||
|
||||
/* copy short from src to dst byteswapping on the way */
|
||||
#define cpswaps(src, dst)\
|
||||
((char *) &(dst))[0] = ((char *) &(src))[1];\
|
||||
((char *) &(dst))[1] = ((char *) &(src))[0];
|
||||
|
||||
extern void SwapLongs();
|
||||
extern void SwapShorts();
|
||||
|
||||
typedef struct _DDXPoint *DDXPointPtr;
|
||||
typedef struct _Box *BoxPtr;
|
||||
|
||||
#endif /* MISC_H */
|
||||
149
Linux-0.98/Yggdrasil-0.98.3/usr/X11/lib/Server/include/os.h
Normal file
149
Linux-0.98/Yggdrasil-0.98.3/usr/X11/lib/Server/include/os.h
Normal file
@@ -0,0 +1,149 @@
|
||||
/***********************************************************
|
||||
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
|
||||
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.
|
||||
|
||||
All Rights Reserved
|
||||
|
||||
Permission 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 that
|
||||
both that copyright notice and this permission notice appear in
|
||||
supporting documentation, and that the names of Digital or MIT not be
|
||||
used in advertising or publicity pertaining to distribution of the
|
||||
software without specific, written prior permission.
|
||||
|
||||
DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
|
||||
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
|
||||
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
|
||||
ANY 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 THIS
|
||||
SOFTWARE.
|
||||
|
||||
******************************************************************/
|
||||
|
||||
/* $Header: /home/x_cvs/mit/server/include/os.h,v 1.3 1992/08/29 07:28:36 dawes Exp $ */
|
||||
/* $XConsortium: os.h,v 1.44 91/07/18 23:01:12 keith Exp $ */
|
||||
|
||||
#ifndef OS_H
|
||||
#define OS_H
|
||||
#include "misc.h"
|
||||
|
||||
#ifdef INCLUDE_ALLOCA_H
|
||||
#include <alloca.h>
|
||||
#endif
|
||||
|
||||
#define NullFID ((FID) 0)
|
||||
|
||||
#define SCREEN_SAVER_ON 0
|
||||
#define SCREEN_SAVER_OFF 1
|
||||
#define SCREEN_SAVER_FORCER 2
|
||||
|
||||
#ifndef MAX_REQUEST_SIZE
|
||||
#define MAX_REQUEST_SIZE 65535
|
||||
#endif
|
||||
|
||||
typedef pointer FID;
|
||||
typedef struct _FontPathRec *FontPathPtr;
|
||||
typedef struct _NewClientRec *NewClientPtr;
|
||||
|
||||
#ifndef NO_ALLOCA
|
||||
/*
|
||||
* os-dependent definition of local allocation and deallocation
|
||||
* If you want something other than Xalloc/Xfree for ALLOCATE/DEALLOCATE
|
||||
* LOCAL then you add that in here.
|
||||
*/
|
||||
#ifdef __HIGHC__
|
||||
|
||||
extern char *alloca();
|
||||
|
||||
#if HCVERSION < 21003
|
||||
#define ALLOCATE_LOCAL(size) alloca((int)(size))
|
||||
pragma on(alloca);
|
||||
#else /* HCVERSION >= 21003 */
|
||||
#define ALLOCATE_LOCAL(size) _Alloca((int)(size))
|
||||
#endif /* HCVERSION < 21003 */
|
||||
|
||||
#define DEALLOCATE_LOCAL(ptr) /* as nothing */
|
||||
|
||||
#endif /* defined(__HIGHC__) */
|
||||
|
||||
|
||||
#ifdef __GNUC__
|
||||
#define alloca __builtin_alloca
|
||||
#endif
|
||||
|
||||
/*
|
||||
* warning: old mips alloca (pre 2.10) is unusable, new one is builtin
|
||||
* Test is easy, the new one is named __builtin_alloca and comes
|
||||
* from alloca.h which #defines alloca.
|
||||
*/
|
||||
#if defined(vax) || defined(sun) || defined(apollo) || defined(stellar) || defined(alloca)
|
||||
/*
|
||||
* Some System V boxes extract alloca.o from /lib/libPW.a; if you
|
||||
* decide that you don't want to use alloca, you might want to fix
|
||||
* ../os/4.2bsd/Imakefile
|
||||
*/
|
||||
#ifndef alloca
|
||||
char *alloca();
|
||||
#endif
|
||||
#define ALLOCATE_LOCAL(size) alloca((int)(size))
|
||||
#define DEALLOCATE_LOCAL(ptr) /* as nothing */
|
||||
#endif /* who does alloca */
|
||||
|
||||
#endif /* NO_ALLOCA */
|
||||
|
||||
#ifdef CAHILL_MALLOC
|
||||
#define Xalloc(len) debug_Xalloc(__FILE__,__LINE__,(len))
|
||||
#define Xcalloc(len) debug_Xcalloc(__FILE__,__LINE__,(len))
|
||||
#define Xrealloc(ptr,len) debug_Xrealloc(__FILE__,__LINE__,(ptr),(len))
|
||||
#define Xfree(ptr) debug_Xfree(__FILE__,__LINE__,(ptr))
|
||||
#endif
|
||||
|
||||
#ifndef ALLOCATE_LOCAL
|
||||
#define ALLOCATE_LOCAL(size) Xalloc((unsigned long)(size))
|
||||
#define DEALLOCATE_LOCAL(ptr) Xfree((pointer)(ptr))
|
||||
#endif /* ALLOCATE_LOCAL */
|
||||
|
||||
|
||||
#define xalloc(size) Xalloc(((unsigned long)(size)))
|
||||
#define xrealloc(ptr, size) Xrealloc(((pointer)(ptr)), ((unsigned long)(size)))
|
||||
#define xfree(ptr) Xfree(((pointer)(ptr)))
|
||||
|
||||
#ifndef X_NOT_STDC_ENV
|
||||
#include <string.h>
|
||||
#else
|
||||
#ifdef SYSV
|
||||
#include <string.h>
|
||||
#else
|
||||
#include <strings.h>
|
||||
#endif
|
||||
#endif
|
||||
|
||||
int ReadRequestFromClient();
|
||||
Bool CloseDownConnection();
|
||||
FontPathPtr ExpandFontNamePattern();
|
||||
FID FiOpenForRead();
|
||||
void CreateWellKnownSockets();
|
||||
int SetDefaultFontPath();
|
||||
void FreeFontRecord();
|
||||
int SetFontPath();
|
||||
void ErrorF();
|
||||
void Error();
|
||||
void FatalError();
|
||||
void ProcessCommandLine();
|
||||
void FlushAllOutput();
|
||||
void FlushIfCriticalOutputPending();
|
||||
#ifndef CAHILL_MALLOC
|
||||
void Xfree();
|
||||
unsigned long *Xalloc();
|
||||
unsigned long *Xrealloc();
|
||||
#else
|
||||
void debug_Xfree();
|
||||
unsigned long *debug_Xalloc();
|
||||
unsigned long *debug_Xcalloc();
|
||||
unsigned long *debug_Xrealloc();
|
||||
#endif
|
||||
long GetTimeInMillis();
|
||||
|
||||
#endif /* OS_H */
|
||||
144
Linux-0.98/Yggdrasil-0.98.3/usr/X11/lib/Server/include/x386.h
Normal file
144
Linux-0.98/Yggdrasil-0.98.3/usr/X11/lib/Server/include/x386.h
Normal file
@@ -0,0 +1,144 @@
|
||||
/* $Header: /home/x_cvs/mit/server/ddx/x386/common/x386.h,v 1.15 1992/08/29 10:08:26 dawes Exp $ */
|
||||
/*
|
||||
* Copyright 1990,91 by Thomas Roell, Dinkelscherben, Germany.
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||
* documentation for any purpose is hereby granted without fee, provided that
|
||||
* the above copyright notice appear in all copies and that both that
|
||||
* copyright notice and this permission notice appear in supporting
|
||||
* documentation, and that the name of Thomas Roell not be used in
|
||||
* advertising or publicity pertaining to distribution of the software without
|
||||
* specific, written prior permission. Thomas Roell makes no representations
|
||||
* about the suitability of this software for any purpose. It is provided
|
||||
* "as is" without express or implied warranty.
|
||||
*
|
||||
* THOMAS ROELL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
|
||||
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
|
||||
* EVENT SHALL THOMAS ROELL BE LIABLE FOR ANY SPECIAL, INDIRECT OR
|
||||
* CONSEQUENTIAL DAMAGES OR ANY 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 THIS SOFTWARE.
|
||||
*
|
||||
* $Header: /proj/X11/mit/server/ddx/x386/RCS/x386.h,v 1.1 1991/06/02 22:36:07 root Exp $
|
||||
*/
|
||||
|
||||
#ifndef _X386_H
|
||||
#define _X386_H
|
||||
|
||||
/*
|
||||
* structure common for all modes
|
||||
*/
|
||||
typedef struct _DispM {
|
||||
struct _DispM *prev,*next;
|
||||
char *name; /* identifier of this mode */
|
||||
int Clock; /* doclock */
|
||||
int HDisplay; /* horizontal timing */
|
||||
int HSyncStart;
|
||||
int HSyncEnd;
|
||||
int HTotal;
|
||||
int VDisplay; /* vertical timing */
|
||||
int VSyncStart;
|
||||
int VSyncEnd;
|
||||
int VTotal;
|
||||
int Flags;
|
||||
} DisplayModeRec, *DisplayModePtr;
|
||||
|
||||
#define V_PHSYNC 0x0001
|
||||
#define V_NHSYNC 0x0002
|
||||
#define V_PVSYNC 0x0004
|
||||
#define V_NVSYNC 0x0008
|
||||
#define V_INTERLACE 0x0010
|
||||
#define V_DBLSCAN 0x0020
|
||||
|
||||
#define MAXCLOCKS 32
|
||||
|
||||
/*
|
||||
* the graphic device
|
||||
*/
|
||||
typedef struct {
|
||||
Bool configured;
|
||||
int index;
|
||||
Bool (* Probe)();
|
||||
Bool (* Init)();
|
||||
void (* EnterLeaveVT)();
|
||||
void (* EnterLeaveMonitor)();
|
||||
void (* EnterLeaveCursor)();
|
||||
void (* AdjustFrame)();
|
||||
void (* SwitchMode)();
|
||||
void (* PrintIdent)();
|
||||
int depth;
|
||||
int bitsPerPixel;
|
||||
int defaultVisual;
|
||||
int virtualX,virtualY;
|
||||
int frameX0, frameY0, frameX1, frameY1;
|
||||
char *vendor;
|
||||
char *chipset;
|
||||
int clocks;
|
||||
int clock[MAXCLOCKS];
|
||||
int videoRam;
|
||||
int width, height; /* real display dimensions */
|
||||
unsigned long speedup; /* Use SpeedUp code */
|
||||
DisplayModePtr modes;
|
||||
} ScrnInfoRec, *ScrnInfoPtr;
|
||||
|
||||
#define VGA_DRIVER 1
|
||||
#define V256_DRIVER 2
|
||||
#define WGA_DRIVER 3
|
||||
#define XGA_DRIVER 4
|
||||
|
||||
#define ENTER 1
|
||||
#define LEAVE 0
|
||||
|
||||
/* SpeedUp options */
|
||||
|
||||
#define SPEEDUP_FILLBOX 1
|
||||
#define SPEEDUP_FILLRECT 2
|
||||
#define SPEEDUP_BITBLT 4
|
||||
#define SPEEDUP_LINE 8
|
||||
#define SPEEDUP_TEGBLT8 0x10
|
||||
#define SPEEDUP_RECTSTIP 0x20
|
||||
|
||||
/*
|
||||
* This is the routines where SpeedUp is quicker than fX386. The problem is
|
||||
* that the SpeedUp fillbox is better for drawing vertical and horizontal
|
||||
* line segments, and the fX386 version is significantly better for
|
||||
* more general lines
|
||||
*/
|
||||
#define SPEEDUP_BEST (SPEEDUP_FILLRECT | SPEEDUP_BITBLT | \
|
||||
SPEEDUP_LINE | SPEEDUP_TEGBLT8 | \
|
||||
SPEEDUP_RECTSTIP)
|
||||
/*
|
||||
#define SPEEDUP_BEST (SPEEDUP_FILLBOX | SPEEDUP_FILLRECT | \
|
||||
SPEEDUP_BITBLT | SPEEDUP_LINE | \
|
||||
SPEEDUP_TEGBLT8 | SPEEDUP_RECTSTIP)
|
||||
*/
|
||||
|
||||
/*
|
||||
* SpeedUp routines which are not dependent on the screen virtual resolution
|
||||
*/
|
||||
#ifndef SPEEDUP_ANYWIDTH
|
||||
#define SPEEDUP_ANYWIDTH (SPEEDUP_FILLRECT | SPEEDUP_BITBLT | \
|
||||
SPEEDUP_LINE | SPEEDUP_FILLBOX)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* SpeedUp routines which are not dependent on ET4000
|
||||
*/
|
||||
#ifndef SPEEDUP_ANYCHIPSET
|
||||
#define SPEEDUP_ANYCHIPSET (SPEEDUP_TEGBLT8 | SPEEDUP_RECTSTIP)
|
||||
#endif
|
||||
|
||||
/* All SpeedUps */
|
||||
#define SPEEDUP_ALL (SPEEDUP_FILLBOX | SPEEDUP_FILLRECT | \
|
||||
SPEEDUP_BITBLT | SPEEDUP_LINE | \
|
||||
SPEEDUP_TEGBLT8 | SPEEDUP_RECTSTIP)
|
||||
|
||||
/* SpeedUp flags used if SpeedUp is not in Xconfig */
|
||||
#define SPEEDUP_DEFAULT SPEEDUP_ALL
|
||||
|
||||
extern Bool x386VTSema;
|
||||
|
||||
#endif /* _X386_H */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user