 |
Index for Section 9 |
|
 |
Alphabetical listing for S |
|
 |
Bottom of page |
|
ScreenRec(9s)
NAME
ScreenRec - Graphics: Used by the DDX to describe the graphics display
characteristics
SYNOPSIS
typedef struct _Screen {
int myNum;
ATOM id;
short width, height;
short mmWidth, mmHeight;
short numDepths;
u_char rootDepth;
DepthPtr allowedDepths;
u_long rootVisual;
u_long defColormap;
short minInstalledCmaps, maxInstalledCmaps;
char backingStoreSupport, saveUnderSupport;
u_long whitePixel, blackPixel;
u_long rgf;
GCPtr GCperDepth[MAXFORMATS+1];
PixmapPtr PixmapPerDepth[1];
pointer devPrivate;
short numVisuals;
VisualPtr visuals;
int WindowPrivateLen;
unsigned *WindowPrivateSizes;
unsigned totalWindowSize;
int GCPrivateLen;
unsigned *GCPrivateSizes;
unsigned totalGCSize;
/* Random screen procedures */
CloseScreenProcPtr CloseScreen;
QueryBestSizeProcPtr QueryBestSize;
SaveScreenProcPtr SaveScreen;
GetImageProcPtr GetImage;
GetSpansProcPtr GetSpans;
PointerNonInterestBoxProcPtr PointerNonInterestBox;
SourceValidateProcPtr SourceValidate;
/* Window Procedures */
CreateWindowProcPtr CreateWindow;
DestroyWindowProcPtr DestroyWindow;
PositionWindowProcPtr PositionWindow;
ChangeWindowAttributesProcPtr ChangeWindowAttributes;
RealizeWindowProcPtr RealizeWindow;
UnrealizeWindowProcPtr UnrealizeWindow;
ValidateTreeProcPtr ValidateTree;
PostValidateTreeProcPtr PostValidateTree;
WindowExposuresProcPtr WindowExposures;
PaintWindowBackgroundProcPtr PaintWindowBackground;
PaintWindowBorderProcPtr PaintWindowBorder;
CopyWindowProcPtr CopyWindow;
ClearToBackgroundProcPtr ClearToBackground;
ClipNotifyProcPtr ClipNotify;
/* Pixmap procedures */
CreatePixmapProcPtr CreatePixmap;
DestroyPixmapProcPtr DestroyPixmap;
/* Backing store procedures */
SaveDoomedAreasProcPtr SaveDoomedAreas;
RestoreAreasProcPtr RestoreAreas;
ExposeCopyProcPtr ExposeCopy;
TranslateBackingStoreProcPtr TranslateBackingStore;
ClearBackingStoreProcPtr ClearBackingStore;
DrawGuaranteeProcPtr DrawGuarantee;
/* Font procedures */
RealizeFontProcPtr RealizeFont;
UnrealizeFontProcPtr UnrealizeFont;
/* Cursor Procedures */
ConstrainCursorProcPtr ConstrainCursor;
CursorLimitsProcPtr CursorLimits;
DisplayCursorProcPtr DisplayCursor;
RealizeCursorProcPtr RealizeCursor;
UnrealizeCursorProcPtr UnrealizeCursor;
RecolorCursorProcPtr RecolorCursor;
SetCursorPositionProcPtr SetCursorPosition;
/* GC procedures */
CreateGCProcPtr CreateGC;
/* Colormap procedures */
CreateColormapProcPtr CreateColormap;
DestroyColormapProcPtr DestroyColormap;
InstallColormapProcPtr InstallColormap;
UninstallColormapProcPtr UninstallColormap;
ListInstalledColormapsProcPtr ListInstalledColormaps;
StoreColorsProcPtr StoreColors;
ResolveColorProcPtr ResolveColor;
/* Region procedures */
RegionCreateProcPtr RegionCreate;
RegionInitProcPtr RegionInit;
RegionCopyProcPtr RegionCopy;
RegionDestroyProcPtr RegionDestroy;
RegionUninitProcPtr RegionUninit;
IntersectProcPtr Intersect;
UnionProcPtr Union;
SubtractProcPtr Subtract;
InverseProcPtr Inverse;
RegionResetProcPtr RegionReset;
TranslateRegionProcPtr TranslateRegion;
RectInProcPtr RectIn;
PointInRegionProcPtr PointInRegion;
RegionNotEmptyProcPtr RegionNotEmpty;
RegionEmptyProcPtr RegionEmpty;
RegionExtentsProcPtr RegionExtents;
RegionAppendProcPtr RegionAppend;
RegionValidateProcPtr RegionValidate;
BitmapToRegionProcPtr BitmapToRegion;
RectsToRegionProcPtr RectsToRegion;
SendGraphicsExposeProcPtr SendGraphicsExpose;
/* Operating System Procedures */
ScreenBlockHandlerProcPtr BlockHandler;
ScreenWakeupHandlerProcPtr WakeupHandler;
pointer blockData;
pointer wakeupData;
DevUnion *devPrivates;
CreateScreenResourcesProcPtr CreateScreenResources;
ModifyPixmapHeaderProcPtr ModifyPixmapHeader;
PixmapPtr pScratchPixmap;
MarkWindowProcPtr MarkWindow;
MarkOverlappedWindowsProcPtr MarkOverlappedWindows;
ChangeSaveUnderProcPtr ChangeSaveUnder;
PostChangeSaveUnderProcPtr PostChangeSaveUnder;
MoveWindowProcPtr MoveWindow;
ResizeWindowProcPtr ResizeWindow;
GetLayerWindowProcPtr GetLayerWindow;
HandleExposuresProcPtr HandleExposures;
ReparentWindowProcPtr ReparentWindow;
ChangeBorderWidthProcPtr ChangeBorderWidth;
SetShapeProcPtr SetShape;
MarkUnrealizedWindowProcPtr MarkUnrealizedWindow;
} ScreenRec;
MEMBERS
myNum
Specifies an index into an array of screens to this ScreenRec
structure.
id Specifies the screen number -- a unique number assigned to the screen
by the server at startup.
width, height
Specify the width and height of the screen, in pixels.
mmWidth, mmHeight
Specify the width and height of the screen, in millimeters.
numDepths
Specifies the number of depths that the screen supports.
rootDepth
Specifies the depth of the root window.
allowedDepths
Specifies the number of depths that the screen supports.
rootVisual
Specifies the visual class of the root window.
defColormap
Specifies the default colormap.
minInstalledCmaps, maxInstalledCmaps
Specify the minimum and maximum number of colormaps that the user can
install on the screen.
backingStoreSupport, saveUnderSupport
Specify whether backing store and save under are supported.
whitePixel, blackPixel
Specify the pixel value of white and black.
rgf Specifies an array of pointers.
GCperDepth
Specifies the number of graphics contexts that a depth supports.
PixmapPerDepth
Specifies the number of pixmaps that a depth supports.
devPrivate
Specifies a pointer to the device private areas.
numVisuals
Specifies the number of visuals that the screen supports.
visuals
Specifies a pointer to the visuals.
WindowPrivateLen
Specifies the length of a window private area.
WindowPrivateSizes
Specifies a pointer to the window private areas.
totalWindowSize
Specifies the total size of all window private areas.
GCPrivateLen
Specifies the size of a graphics context private area.
GCPrivateSizes
Specifies a pointer to the graphics context private areas.
totalGCSize
Specifies the total size of all graphics context private areas.
Screen Procedures
Define the routines that handle screen operations. You need to define
the following screen procedures:
_____________________________________________________________
Procedure Description
_____________________________________________________________
CloseScreen
Closes the screen and frees resources
that the screen uses.
VGA default: None (the DDX must
provide this routine)
QueryBestSize
Returns the largest possible size for
a cursor, tile, or stipple.
VGA default: mfbQueryBestSize
SaveScreen
Turns the screen saver on or off, or
forces the screen saver to change
modes.
VGA default: colorSaveScreen
GetImage
Extracts a portion of a drawable
image and stores it in an XImage
structure.
VGA default: vgaGetImage
GetSpansP
Extracts a number of lines from the
drawable image and stores them in a
buffer.
VGA default: vgaGetSpans
PointerNonInterestBox
Called by the DIX, indicates whether
pointer events can be ignored.
VGA default:
colorPointerNonInterestBox
SourceValidate
Ensures that a drawable image is
ready to be copied.
VGA default: NULL pointer
_____________________________________________________________
Window Procedures
Define the routines that handle window operations. You need to define
the following window procedures:
_________________________________________________________________
Procedure Description
_________________________________________________________________
CreateWindow Creates a new window.
VGA default: vgaCreateWindow
DestroyWindow
Frees resources associated with a window
that is about to be destroyed.
VGA default: vgaDestroyWindow
PositionWindow
Updates data structures to a new window
position prior to moving the window to
that position.
VGA default: vgaPositionWindow
ChangeWindowAttributes
Updates window attributes and any
resources that depend on those
attributes.
VGA default: vgaChangeWindowAttributes
RealizeWindow
Allocates and initializes resources a
window needs if it is going to be mapped
to the screen.
VGA default: vgaMapWindow
UnrealizeWindow
Deallocates the resources that
RealizeWindow allocates when a window is
unmapped.
VGA default: vgaUnmapWindow
ValidateTree
Computes the border clip region and
window clip region for every marked
window in a window tree when a portion
of the tree changes.
VGA default: miValidateTree
PostValidateTree
Performs device-dependent operations on
a window tree that has been validated.
VGA default: NULL pointer
WindowExposures
Paints the exposed areas of any window
that has been validated.
VGA default: miWindowExposures
PaintWindowBackground
Paints the exposed areas of a window
background.
VGA default: vgaPaintWindow
PaintWindowBorder
Paints the exposed areas of a window
border.
VGA default: vgaPaintWindow
CopyWindow
Copies an exposed area from a window to
another place on the screen.
VGA default: vgaCopyWindow
ClearToBackground
Draws the window background or generates
exposure events for a portion of a
window.
VGA default: miClearToBackground
ClipNotify
Adjusts the window's hardware clipping
resources when the clip list changes.
VGA default: None
_________________________________________________________________
Pixmap Procedures
Define the routines that handle pixmap operations. You need to define
the following pixmap procedures:
___________________________________________________________________
Procedure Description
___________________________________________________________________
CreatePixmap
Allocates a PixmapRec structure for a new pixmap.
VGA default: vgaCreatePixmap
DestroyPixmap Deallocates the resources for a pixmap.
VGA default: vgaDestroyPixmap
___________________________________________________________________
Backing Store Procedures
Define the routines that handle backing store operations. You need to
define the following backing store procedures:
________________________________________________________________
Procedure Description
________________________________________________________________
SaveDoomedAreas
Saves a portion of a window that is
about to be obscured or moved and places
it in a backing store pixmap.
VGA default: Null pointer
RestoreAreas
Recovers an area of a window that was
previously saved to a backing store
pixmap.
VGA default: Null pointer
ExposeCopy
Copies an area from a backing store
pixmap, moves it to another place on the
screen, and exposes any portion of the
area that is no longer obscured.
VGA default: Null pointer
TranslateBackingStore
Allocates a new backing store pixmap, if
necessary, when a window is resized or
moved.
VGA default: Null pointer
ClearBackingStore
Clears an area of a backing store
pixmap.
VGA default: Null pointer
DrawGuarantee
Specifies whether any upcoming graphics
events will be clipped to the window's
border clip region.
VGA default: Null pointer
________________________________________________________________
Font Procedures
Define the routines that handle font operations. You need to define
the following font procedures:
___________________________________________________________________
Procedure Description
___________________________________________________________________
RealizeFont
Initializes any font-specific data structures for a
screen when a font is opened.
VGA default: vgaRealizeFont
UnrealizeFont
Frees any resources that RealizeFont allocates.
VGA default: vgaUnrealizeFont
___________________________________________________________________
Cursor Procedures
Define the routines that handle cursor operations. You need to define
the following cursor procedures:
______________________________________________________________
Procedure Description
______________________________________________________________
ConstrainCursor
Forces a cursor to stay within a given
area.
VGA default: None
CursorLimits
Returns the physical constraints a cursor
would have if ConstrainCursor was called
with a specified area.
VGA default: None
DisplayCursor Displays the cursor on the screen.
VGA default: None
RealizeCursor
Allocates and initializes device-specific
resources for a cursor before displaying
the cursor on the screen.
VGA default: None
UnrealizeCursor Deallocates the resources for a cursor.
VGA default: None
RecolorCursor Changes the color of a cursor.
VGA default: None
SetCursorPosition
Moves the cursor to the specified position
on the screen.
VGA default: None
______________________________________________________________
Graphics Context Procedure
Defines the routine that handles graphics context operations. You need
to define the following graphics context procedure:
______________________________________________________________
Procedure Description
______________________________________________________________
CreateGC
Allocates resources needed for a new graphics
context.
VGA default: vgaCreateGC
______________________________________________________________
Colormap Procedures
Define the routines that handle colormap operations. You need to define
the following colormap procedures:
_________________________________________________________________
Procedure Description
_________________________________________________________________
CreateColormap Allocates resources for a new colormap.
VGA default: vgaCreateColormap
DestroyColormap
Deallocates resources for a colormap
that is to be destroyed.
VGA default: vgaDestroyColormap
InstallColormap
Changes the mapping of pixel values to
colors that match a new colormap.
VGA default: None
UninstallColormap
Removes a colormap and replaces it with
the default colormap for the screen.
VGA default: None
ListInstalledColormaps
Returns the numbers and resource IDs of
all colormaps installed on the screen.
VGA default: None
StoreColors
Stores one or more colors in a colormap.
VGA default: None
ResolveColor
Adjusts the server's universal color
values to values that are appropriate
for the screen.
VGA default: vgaResolveColor
_________________________________________________________________
Region Procedures
Define the routines that handle region operations. You need to define
the following region procedures:
_________________________________________________________________
Procedure Description
_________________________________________________________________
RegionCreate
Allocates and initializes a RegionRec
structure for a new region.
VGA default: miRegionCreate
RegionInit
Initializes the RegionRec structure for an
existing region.
VGA default: miRegionInit
RegionCopy
Copies the contents of one region to
another.
VGA default: miRegionCopy
RegionDestroy Deallocates the resources for a region.
VGA default: miRegionDestroy
RegionUninit
Deallocates resources for a statically
allocated region but does not deallocate its
RegionRec structure.
VGA default: miRegionUninit
Intersect Returns the intersection of two regions.
VGA default: miIntersect
Union Returns the union of two regions.
VGA default: miUnion
Subtract Returns the difference between two regions.
VGA default: miSubtract
Inverse Returns the inverse of a region.
VGA default: miInverse
RegionReset Changes the extents of a region.
VGA default: miRegionReset
TranslateRegion
Moves a region to a new location on the
screen.
VGA default: miTranslateRegion
RectIn
Determines whether a rectangle falls within
a region.
VGA default: miRectIn
PointInRegion
Determines whether a point falls within a
region.
VGA default: miPointInRegion
RegionNotEmpty
Returns true if a specified region is not
empty.
VGA default: miRegionNotEmpty
RegionEmpty
Returns true if a specified region is empty.
VGA default: miRegionEmpty
RegionExtents
Returns the smallest rectangle that encloses
a specified region.
VGA default: miRegionExtents
RegionAppend Concatenates two regions.
VGA default: miRegionAppend
RegionValidate
Creates a single region from several screen
areas concatenated by multiple calls to
RegionAppend.
VGA default: miRegionValidate
BitmapToRegion Converts a bitmap to a region.
VGA default: mfbBitmapToRegion
RectsToRegion Creates a region from several rectangles.
VGA default: miRectsToRegion
SendGraphicsExpose
Sends a GraphicsExpose or NoExpose event to
the client for a specified region.
VGA default: miSendGraphicsExpose
_________________________________________________________________
Operating System Procedures
Define the routines that handle operating system operations. The MI
library defines the following operating system procedures. A DDX does
not usually need to define routines to perform these operations.
________________________________________________________________
Procedure Description
________________________________________________________________
BlockHandler VGA default: NoopDDA
WakeupHandler VGA default: NoopDDA
ModifyPixmapHeader
VGA default: miModifyPixmapHeader
CreateScreenResources
VGA default: miCreateScreenResources
MarkWindow VGA default: miMarkWindow
MarkOverlappedWindows
VGA default: miMarkOverlappedWindows
ChangeSaveUnder
VGA default: miChangeSaveUnder
PostChangeSaveUnder
VGA default: miPostChangeSaveUnder
MoveWindow VGA default: miMoveWindow
ResizeWindow VGA default: miResizeWindoW
GetLayerWindow VGA default: miGetLayerWindow
HandleExposures
VGA default: miHandleExposures
ReparentWindow VGA default: NULL pointer
ChangeBorderWidth
VGA default: miChangeBorderWidth
SetShape VGA default: miSetShape
MarkUnrealizedWindow
VGA default: miMarkUnrealizedWindow
________________________________________________________________
The following are not procedure pointer types, rather they are
operating system miscellaneous types.
_________________________________________________________
Procedure Description
_________________________________________________________
blockData
Specifies a pointer to an area that the
block handler can use.
wakeupData
Specifies a pointer to an area that the
wakeup handler can use.
devPrivates
Specifies a pointer to a DDX-specific
data structure.
pScratchPixmap
Specifies a pointer to an area that the
DDX can use for pixmaps.
_________________________________________________________
DESCRIPTION
The ScreenRec data structure defines the characteristics of a screen. The
DDX creates one ScreenRec data structure for each screen detected when the
server starts up.
FILES
<usr/X11R6/xc/programs/Xserver/include/scrnintstr.h>
SEE ALSO
Data Structures: DepthRec(9s), VisualRec(9s)
 |
Index for Section 9 |
|
 |
Alphabetical listing for S |
|
 |
Top of page |
|