/* Generated by Ctran from prdrv.cat */
#define PRDRV_G
#ifndef P_FILE_H
#include <p_file.h>
#endif
#ifndef APPMAN_G
#include <appman.g>
#endif
/* Class Numbers */
#define C_WDR 6
#define C_PDR 7
/* Method Numbers */
#define O_WDR_SEARCH_TYPEFACE 7
#define O_PDR_PAGE 7
#define O_WDR_TYPEFACE 6
#define O_PDR_STYLE 12
#define O_PDR_PRINT 2
#define O_WDR_TWIPS_TO_XY 12
#define O_WDR_FONT_HEIGHT 8
#define O_WDR_SENSE_MODEL 5
#define O_WDR_SET_MODEL 4
#define O_WDR_SENSE_WIDTH 11
#define O_WDR_COUNT_MODELS 2
#define O_PDR_END 6
#define O_PDR_TEXT 8
#define O_PDR_DESTROY 4
#define O_PDR_START 5
#define O_PDR_INIT 1
#define O_WDR_INIT 1
#define O_PDR_RIGHT 10
#define O_PDR_ADD_COMMAND 3
#define O_WDR_GET_WIDTH_TABLE 10
#define O_WDR_OPEN_PRINT 13
#define O_WDR_LOAD_RECORD 14
#define O_WDR_SEARCH_HEIGHT 9
#define O_PDR_FONT 11
#define O_WDR_SENSE_MODEL_NAME 3
#define O_PDR_LINE 9
/* Constants for wdr */
#define WDR_PRINT_PAGE 0x01
#define WDR_PRINT_LINE 0x02
#define WDR_PRINT_RIGHT 0x04
#define WDR_PRINT_FONT 0x08
#define WDR_PRINT_TEXT 0x10
#define WDR_PRINT_START 0x20
#define WDR_PRINT_END 0x40
#define WDR_PRINT_IDLE 0x4000
#define WDR_PRINT_KEEP 0x8000
#define WDR_PDR_LANDSCAPE 0x01
#define WDR_RSC_HEADER 1
#define WDR_RSC_COMMANDS 2
#define WDR_DYL_LOAD 0x01
#define WDR_HP_PCL 0x02
#define WDR_STYLE_NORMAL 0x0000
#define WDR_STYLE_UNDERLINE 0x0001
#define WDR_STYLE_BOLD 0x0002
#define WDR_STYLE_ITALIC 0x0004
#define WDR_STYLE_SUPER 0x0008
#define WDR_STYLE_SUB 0x0010
#define WDR_STYLE_MONOSPACE 0x8000
#define WDR_STYLE_SANS_SERIF 0x4000
#define WDR_TYPF_PROPORTIONAL 0x01
#define WDR_TYPF_SCALED 0x02
#define WDR_TYPF_SERIF 0x04
#define WDR_MODEL_LANDSCAPE_AVAILABLE 1
#define WDR_MODEL_MINX_IS_DOTS_PER_INCH 4
#define WDR_SCALE_DEFAULT_HEIGHT 1000
#define WDR_FONT_NAME_LEN 20
#define PRINTER_NAME_LEN 24
#define PRINT_TYPE_LEN 9
#define PDR_FILE_LEN 9
/* Types for wdr */
typedef struct
{
unsigned short int height;
unsigned short int height_max;
unsigned short int height_delta;
unsigned short int width_scale;
unsigned short int width_normal;
unsigned short int width_italic;
unsigned short int width_bold;
unsigned short int width_bold_italic;
unsigned short int command;
} WDR_FONT;
typedef struct
{
char name[WDR_FONT_NAME_LEN];
unsigned short int typeface;
unsigned short int type;
short int trans_rid;
unsigned short int num_heights;
WDR_FONT font[1];
} WDR_TYPEFACE;
typedef struct
{
unsigned short int minx;
unsigned short int miny;
unsigned short int skipx;
unsigned short int skipy;
unsigned short int flags;
unsigned short int num_typefaces;
WDR_TYPEFACE *typeface[1];
} WDR_MODEL;
typedef struct
{
unsigned short int rid;
char name[PRINTER_NAME_LEN];
} WDR_MODEL_INDEX;
typedef struct
{
char id[6];
unsigned short int flags;
unsigned short int num_model;
WDR_MODEL_INDEX model[1];
} WDR_HEADER;
typedef struct width_table
{
struct width_table *next;
unsigned short int rid;
unsigned short int height;
unsigned char *table;
} WDR_WIDTH_TABLE;
typedef struct
{
short int flags;
short int typf;
short int fheight;
short int style;
short int down;
short int indent;
short int height;
short int right;
char *buf;
unsigned short int blen;
} WDR_PRINT;
/* Property of wdr */
typedef struct {
PR_RSCFILE *file;
WDR_HEADER *head;
WDR_MODEL *model;
WDR_WIDTH_TABLE *wid;
char wdrname[P_FNAMESIZE];
} PRS_WDR;
typedef struct pr_wdr
{
PRS_ROOT root;
PRS_WDR wdr;
} PR_WDR;
/* Constants for pdr */
#define PDR_CMD_RESET 0
#define PDR_CMD_FORM_LENGTH 1
#define PDR_CMD_PREAMBLE 2
#define PDR_CMD_POSTAMBLE 3
#define PDR_CMD_UNDERLINE_ON 4
#define PDR_CMD_UNDERLINE_OFF 5
#define PDR_CMD_BOLD_ON 6
#define PDR_CMD_BOLD_OFF 7
#define PDR_CMD_ITALIC_ON 8
#define PDR_CMD_ITALIC_OFF 9
#define PDR_CMD_SUPERSCRIPT_ON 10
#define PDR_CMD_SUPERSCRIPT_OFF 11
#define PDR_CMD_SUBSCRIPT_ON 12
#define PDR_CMD_SUBSCRIPT_OFF 13
#define PDR_CMD_NEW_PAGE 14
#define PDR_CMD_CARRIAGE_RETURN 15
#define PDR_CMD_MOVE_DOWN 16
#define PDR_CMD_MOVE_RIGHT_PREFIX 17
#define PDR_CMD_MOVE_RIGHT 18
#define PDR_CMD_MOVE_RIGHT_SUFFIX 19
#define PDR_CMD_LANDSCAPE 20
/* Types for pdr */
typedef struct
{
PR_WDR *wdr;
short int flags;
short int page_length;
int dyl;
WDR_HEADER *head;
WDR_MODEL *model;
} PDR_INIT;
typedef struct
{
unsigned char *commands;
unsigned char *outbuf;
unsigned char *trans_res;
char **tix;
} PDR_ALLOC;
/* Property of pdr */
typedef struct {
PDR_INIT par;
unsigned short int mode;
short int typfix;
short int fhix;
short int style;
short int lheight;
PDR_ALLOC a;
unsigned short int trans_rid;
short int outlen;
unsigned short int skipy;
} PRS_PDR;
typedef struct pr_pdr
{
PRS_ROOT root;
PRS_PDR pdr;
} PR_PDR;
