Developer Documentation
PATH  Mac OS X Documentation > Application Kit Reference: Objective-C

Table of Contents

Defined Types

Note: This section has not been updated and has not received recent technical review. It is included in this release to test the linkage between application development tools and on-line documentation. The information in this section should be considered at best preliminary and subject to change.


DPSContextRec

Declared In:
dpsclient/dpsfriends.h

Synopsis:

typedef struct _t_DPSContextRec {
	char *priv;
DPSSpace space;
DPSProgramEncoding programEncoding;
DPSNameEncoding nameEncoding;
struct _t_DPSProcsRec const * procs;
void (*textProc)();
void (*errorProc)();
DPSResults resultTable;
unsigned int resultTableLength;
struct _t_DPSContextRec *chainParent, *chainChild;
DPSContextType type;
} DPSContextRec, *DPSContext;

 

Description:
The DPSContextRec structure represents a Display PostScript context.


DPSContextType

Declared In:
dpsclient/dpsfriends.h

Synopsis:

typedef enum {
	dps_machServer,
dps_fdServer,
dps_stream
} DPSContextType;

 

Description:
These represent the context types supported by NeXT's version of Display PostScript, as used in the type field of a DPSContextRec structure.


DPSErrorCode

Declared In:
dpsclient/dpsclient.h

Synopsis:

typedef enum _DPSErrorCode {
	dps_err_ps = DPS_ERROR_BASE,
dps_err_nameTooLong,
dps_err_resultTagCheck,
dps_err_resultTypeCheck,
dps_err_invalidContext,
dps_err_select = DPS_NEXT_ERROR_BASE,
dps_err_connectionClosed,
dps_err_read,
dps_err_write,
dps_err_invalidFD,
dps_err_invalidTE,
dps_err_invalidPort,
dps_err_outOfMemory,
dps_err_cantConnect
} DPSErrorCode;

 

Description:
Error codes passed to a DPSErrorProc() function.


DPSEventFilterFunc

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef int (*DPSEventFilterFunc)(NXEvent *ev);

Description:
Call-back function used to filter events.


DPSFDProc

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef void (*DPSFDProc)(int fd, void *userData);

Description:
Call-back function used when a file descriptor is registered through DPSAddFD().


DPSNumberFormat

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef enum _DPSNumberFormat {
#ifdef __BIG_ENDIAN__
dps_float = 48,
dps_long = 0,
dps_short = 32
#else
dps_float = 48+128,
dps_long = 0+128,
dps_short = 32+128
} DPSNumberFormat;

 

Description:
These constants are used by the DPSDoUserPath() function to describe the type of numbers that are being passed.


DPSPingProc

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef void (*DPSPingProc)
	(DPSContext ctxt, 
void *userData);

 

Description:
Call-back function used by DPSAsynchronousWaitContext().


DPSPortProc

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef void (*DPSPortProc)
	(msg_header_t *msg, 
void *userData);

 

Description:
Call-back function used when a port is registered through DPSAddPort().


DPSTimedEntry

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef struct __DPSTimedEntry *DPSTimedEntry;

Description:
The return type for DPSAddTimedEntry().


DPSTimedEntryProc

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef void (*DPSTimedEntryProc)
	(DPSTimedEntry timedEntry,
double now,
void *userData);

 

Description:
Call-back function used when a timed entry is registered through DPSAddTimedEntry().


DPSUserPathAction

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef enum _DPSUserPathAction {
	dps_uappend,
dps_ufill,
dps_ueofill,
dps_ustroke,
dps_ustrokepath,
dps_inufill,
dps_inueofill,
dps_inustroke,
dps_def,
dps_put
} DPSUserPathAction;

 

Description:
These constants are convenient representations of some of the PostScript operator indices, suitable for enrollment in the action array passed to DPSDoUserPath().


DPSUserPathOp

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

typedef enum _DPSUserPathOp {
	dps_setbbox,
dps_moveto,
dps_rmoveto,
dps_lineto,
dps_rlineto,
dps_curveto,
dps_rcurveto,
dps_arc,
dps_arcn,
dps_arct,
dps_closepath,
dps_ucache
} DPSUserPathOp;

 

Description:
These constants represent the PostScript operators that can be passed in DPSDoUserPath()'s operator array.


NXCoord

Declared In:
dpsclient/event.h

Synopsis:

typedef float NXCoord

Description:
Used to represent a single coordinate in a Cartesian coordinate system.


NXEvent

Declared In:
dpsclient/event.h

Synopsis:

typedef struct _NXEvent {
	int type; 
NXPoint location;
long time;
int flags;
unsigned int window;
NXEventData data;
DPSContext ctxt;
} NXEvent, *NXEventPtr;

 

Description:
Represents a single event; this structure is also known as the event record. The fields are:

type

The type of event (see "Event Types," below)

location

The event's location in the base coordinate system of its window

time

The time of the event (in hardware-dependent units) since system startup

flags

Mouse-button and modifier-key flags (see "Event Flags," below)

window

The window number of the window associated with the event

data

Additional type-specific data (see "NXEventData," below)

ctxt

The PostScript context of the event


NXEventData

Declared In:
dpsclient/event.h

Synopsis:

typedef union {
	struct { 
short eventNum;
int click;
unsigned char pressure;
} mouse;
struct {
short repeat;
unsigned short charSet;
unsigned short charCode;
unsigned short keyCode;
short keyData;
} key;
struct {
short eventNum;
int trackingNum;
int userData;
} tracking;
struct {
short subtype;
union {
float F[2];
long L[2];
short S[4];
char C[8];
} misc;
} compound;
} NXEventData;

 

Description:
This structure supplies type-specific information for an event. It's a union of four structures, where the type of the event determines which structure is pertinent:


NXPoint

Declared In:
dpsclient/event.h

Synopsis:

typedef struct _NXPoint {
	NXCoord x;
NXCoord y;
} NXPoint;

 

Description:
Represents a point in a Cartesian coordinate system.


NXSize

Declared In:
dpsclient/event.h

Synopsis:

typedef struct _NXSize {
	NXCoord width;
NXCoord height;
} NXSize;

 

Description:
Represents a two-dimensional size.

Symbolic Constants


All Contexts

Declared In:
dpsclient/NSDPSContext.h

Synopsis:

DPS_ALLCONTEXTS 

Description:
This constant represents all extant contexts.


Alpha Constants

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

NX_DATA
NX_ONES

 

Description:
These constants represent alpha values.


Character Set Values

Declared In:
dpsclient/event.h

Synopsis:

NX_ASCIISET 
NX_SYMBOLSET 
NX_DINGBATSSET

 

Description:
These constants represent the values that may occur in the data.key.charSet field of an NXEvent structure.


Compositing Operations

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

NX_CLEAR 
NX_COPY
NX_SOVER
NX_SIN
NX_SOUT
NX_SATOP
NX_DOVER
NX_DIN
NX_DOUT
NX_DATOP
NX_XOR
NX_PLUSD
NX_HIGHLIGHT
NX_PLUSL

 

Description:
These represent the compositing operations used by PScomposite() and the NXImage class.


Error Code Bases

Declared In:
dpsclient/dpsclient.h

Synopsis:

DPS_ERROR_BASE
DPS_NEXT_ERROR_BASE

 

Description:
These constants represent the lowest values for Display PostScript error codes.


Event Types

Declared In:
dpsclient/event.h

Type

Meaning

NX_NULLEVENT

A non-event

NX_LMOUSEDOWN

Left mouse-down

NX_LMOUSEUP

Left mouse-up

NX_LMOUSEDRAGGED

left mouse-dragged

NX_MOUSEDOWN

Same as NX_LMOUSEDOWN

NX_MOUSEUP

Same as NX_LMOUSEUP

NX_MOUSEDRAGGED

Same as NX_LMOUSEDRAGGED

NX_RMOUSEDOWN

Right mouse-down

NX_RMOUSEUP

Right mouse-up

NX_RMOUSEDRAGGED

Right mouse-dragged

NX_MOUSEMOVED

Mouse-moved

NX_MOUSEENTERED

Mouse-entered

NX_MOUSEEXITED

Mouse-exited

NX_KEYDOWN

Key-down

NX_KEYUP

Key-up event

NX_FLAGSCHANGED

Flags-changed

NX_KITDEFINED

Application Kit-defined

NX_SYSDEFINED

System-defined

NX_APPDEFINED

Application-defined

NX_TIMER

Timer used for tracking

NX_CURSORUPDATE

Cursor tracking

NX_JOURNALEVENT

Event used by journaling

NX_FIRSTEVENT

The smallest-valued event constant

NX_LASTEVENT

The greatest-valued event constant

NX_ALLEVENTS

A value that includes all event types

 

Description:
These constants represent event types. They're passed as the type field of the NXEvent structure that's created when an event occurs.


Event Type Masks

Declared In:
dpsclient/event.h

Synopsis:

NX_NULLEVENTMASK
NX_LMOUSEDOWNMASK
NX_LMOUSEUPMASK
NX_RMOUSEDOWNMASK
NX_RMOUSEUPMASK
NX_MOUSEMOVEDMASK
NX_LMOUSEDRAGGEDMASK
NX_RMOUSEDRAGGEDMASK
NX_MOUSEENTEREDMASK
NX_MOUSEEXITEDMASK
NX_KEYDOWNMASK
NX_KEYUPMASK
NX_FLAGSCHANGEDMASK
NX_KITDEFINEDMASK
NX_APPDEFINEDMASK
NX_SYSDEFINEDMASK
NX_TIMERMASK
NX_CURSORUPDATEMASK
NX_MOUSEDOWNMASK
NX_MOUSEUPMASK
NX_MOUSEDRAGGEDMASK
NX_JOURNALEVENTMASK

 

Description:
These masks correspond to the event types defined immediately above. They let you query the type field of an NXEvent structure for the existence of a particular event type.


Forever

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

NX_FOREVER

Description:
A long, long time. Typically used as the timeout argument to DPSGetEvent().


Keyboard State Flags Masks

Declared In:
dpsclient/event.h

Type

Meaning

NX_ALPHASHIFTMASK

Shift lock

NX_SHIFTMASK

Shift key

NX_CONTROLMASK

Control key

NX_ALTERNATEMASK

Alt key

NX_COMMANDMASK

Command key

NX_NUMERICPADMASK

Number pad key

NX_HELPMASK

Help key

NX_NEXTCTRLKEYMASK

Control key

NX_NEXTLSHIFTKEYMASK

Left shift key

NX_NEXTRSHIFTKEYMASK

Right shift key

NX_NEXTLCMDKEYMASK

Left command key

NX_NEXTRCMDKEYMASK

Right command key

NX_NEXTLALTKEYMASK

Left alt key

NX_NEXTRALTKEYMASK

Right alt key

 

Description:
These masks correspond to keyboard states that might be included in an NXEvent structure's flags mask. The masks are grouped as device-independent (NX_ALPHASHIFTMASK through NX_HELPMASK) and device-dependent (all others).


Miscellaneous Event Flags Masks

Declared In:
dpsclient/event.h

Type

Meaning

NX_STYLUSPROXIMITYMASK

Stylus is in proximity (for tablets)

NX_NONCOALSESCEDMASK

Event coalescing disabled

 

Description:
These masks correspond to miscellaneous states that might be included in an NXEvent structure's flags mask.


Window Backing Types

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

NX_RETAINED
NX_NONRETAINED
NX_BUFFERED

 

Description:
These represent the three backing types provided by window devices (and used by the Application Kit's Window objects).


Window Screen List Placement

Declared In:
dpsclient/dpsNeXT.h

Synopsis:

NX_ABOVE
NX_BELOW
NX_OUT

 

Description:
These represent the placement of a window device in the screen list.



Table of Contents

Copyright © 1997, Apple Computer, Inc. All rights reserved.