X Link Kit data structures and files
This section describes the X Link kit data structures and files.
X resources are data structures inside the server.
Client applications create and manipulate
these structures according to the rules established by
the X protocol. Clients refer to these objects or resources
with resource IDs which are 32 bit integers. Within the server
they are C structures and are referred to by pointers.
The SCO X Server Link Kit eliminates
the need to understand how clients establish connections
with the server
or how they access resources in the server.
Instead, developers only need to concern themselves
with the server's resource data structures
and the pointers that provide access to them.
The DDX (Device Dependant X)
layer has several kinds of resources,
including windows, pixmaps, screens, devices,
colormaps, fonts, cursors, and graphics contexts.
The type names of the more important server structures
usually end in ``Rec'' (short for record,
for example, DeviceRec);
the pointer types usually end in ``Ptr'',
(for example, DevicePtr).
The structures and important defined constants
are declared in header files
that have names that suggest the name of the object.
For example, there are two header files for windows.
windows.h defines the minimal amount of information
needed to use windows resources;
windowstr.h defines the structures
with all of their components in great detail
for those who need it.
Most of the header files referred to in this
section are found in:
This directory structure assumes that ../xlink is the root
of the X Link Kit filesystem.
These structures have three types of members:
attribute fields (structure fields that contain values)
pointers to procedures that operate on the object
a private field (or two) used by your
DDX code to keep private data
(typically, a pointer to another data structure).
DIX (Device Independent X)
makes calls through pointers
to procedures to do its tasks.
These procedures are set either directly or indirectly
by DDX procedures.
Most of the procedures described in section D3nfb
are accessed through one of these structures.
For example, the procedure to create a pixmap is attached to a
structure and can be called by the expression:
(* pScreen->CreatePixmap) (pScreen, width, height, depth);
All procedure pointers must be set to some routine
unless otherwise noted;
a NULL pointer has unfortunate consequences.
The SCO Server Link Kit supplies the
that you can assign to procedure pointers
when they are not used.
Procedure routines are indicated in this documentation
by this convention:
void pScreen->MyScreenRoutine(arg0, arg1 ...)
A free routine (meaning it is not in a data structure)
looks like this:
void MyFreeRoutine(arg0, arg1, ...)
The attribute fields are mostly set by
the DIX layer;
the DDX should not modify them
unless otherwise noted.
19 June 2005
© 2005 The SCO Group, Inc. All rights reserved.
OpenServer 6 and UnixWare (SVR5) HDK - June 2005