home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OpenStep 4.2J (Developer)
/
os42jdev.iso
/
NextDeveloper
/
OpenStepConversion
/
IntermediateFrameworks2
/
DPSClient.framework
/
Headers
/
dpsOpenStep.h
< prev
next >
Wrap
Text File
|
1995-12-21
|
4KB
|
173 lines
/*
dpsOpenStep.h
DPS routines specific to the OpenStep implementation of dpsclient.
This API is part of OpenStep.
Copyright (c) 1994 NeXT, Inc. as an unpublished work.
All rights reserved.
*/
#ifndef DPSOPENSTEP_H
#define DPSOPENSTEP_H
#import "dpsclient.h"
#import <Foundation/Foundation.h>
/* === Exception names === */
extern NSString *DPSPostscriptErrorException;
extern NSString *DPSNameTooLongException;
extern NSString *DPSResultTagCheckException;
extern NSString *DPSResultTypeCheckException;
extern NSString *DPSInvalidContextException;
extern NSString *DPSSelectException;
extern NSString *DPSConnectionClosedException;
extern NSString *DPSReadException;
extern NSString *DPSWriteException;
extern NSString *DPSInvalidFDException;
extern NSString *DPSInvalidTEException;
extern NSString *DPSInvalidPortException;
extern NSString *DPSOutOfMemoryException;
extern NSString *DPSCantConnectException;
/*=== CONSTANTS ===*/
/* operation types for composite operators */
typedef enum _NSCompositingOperation {
NSCompositeClear = 0,
NSCompositeCopy = 1,
NSCompositeSourceOver = 2,
NSCompositeSourceIn = 3,
NSCompositeSourceOut = 4,
NSCompositeSourceAtop = 5,
NSCompositeDestinationOver = 6,
NSCompositeDestinationIn = 7,
NSCompositeDestinationOut = 8,
NSCompositeDestinationAtop = 9,
NSCompositeXOR = 10,
NSCompositePlusDarker = 11,
NSCompositeHighlight = 12,
NSCompositePlusLighter = 13
} NSCompositingOperation;
/* special values for alpha */
enum {
NSAlphaEqualToData = 1,
NSAlphaAlwaysOne = 2
};
/* types of window backing store */
typedef enum _NSBackingStoreType {
NSBackingStoreRetained = 0,
NSBackingStoreNonretained = 1,
NSBackingStoreBuffered = 2
} NSBackingStoreType;
/* ways to order windows */
typedef enum _NSWindowOrderingMode {
NSWindowAbove = 1,
NSWindowBelow = -1,
NSWindowOut = 0
} NSWindowOrderingMode;
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
#endif
} DPSNumberFormat;
/* Constants for DPSDoUserPath describing what type of coordinates are
being used. Other legal values are:
For 32-bit fixed point numbers, use dps_long plus the number of bits
in the fractional part.
For 16-bit fixed point numbers, use dps_short plus the number of bits
in the fractional part.
*/
typedef enum _DPSUserPathOp {
dps_setbbox = 0,
dps_moveto,
dps_rmoveto,
dps_lineto,
dps_rlineto,
dps_curveto,
dps_rcurveto,
dps_arc,
dps_arcn,
dps_arct,
dps_closepath,
dps_ucache
} DPSUserPathOp;
/* Constants for constructing operator array parameter of DPSDoUserPath. */
typedef enum _DPSUserPathAction {
dps_uappend = 176,
dps_ufill = 179,
dps_ueofill = 178,
dps_ustroke = 183,
dps_ustrokepath = 364,
dps_inufill = 93,
dps_inueofill = 92,
dps_inustroke = 312,
dps_def = 51,
dps_put = 120
} DPSUserPathAction;
/* Constants for the action of DPSDoUserPath. In addition to these, any
other system name index may be used.
*/
/* a userobject that can be used to pass a PostScript "null" */
enum {
DPSNullObject = 1
};
/*=== PROCEDURES ===*/
extern void DPSFlush(void);
/* Flushes the current connection */
extern void PSWait(void);
/* Flushes the current connection, waits for acknowledgement */
extern int DPSDefineUserObject(int index);
/* Maps a PostScript object to a user object index. If index is 0, a new
userobject index is allocated; otherwise the supplied index is used.
In either case, the new index for the object is returned. This index
can be passed to a pswrap generated function taking a "userobject"
parameter. This routine should be called with the object that is
to be indexed on the top of the operand stack.
*/
extern void DPSUndefineUserObject(int index);
/* Unmaps a previously created user object. */
extern void DPSDoUserPath(
void *coords,
int numCoords,
DPSNumberFormat numType,
unsigned char *ops,
int numOps,
void *bbox,
int action);
extern void DPSDoUserPathWithMatrix(
void *coords,
int numCoords,
DPSNumberFormat numType,
unsigned char *ops,
int numOps,
void *bbox,
int action,
float matrix[6]);
#endif DPSOPENSTEP_H