/*
 * Source generated with ARexxBox 1.12 (May 18 1993)
 * which is Copyright (c) 1992,1993 Michael Balzer
 */

#include <exec/types.h>
#include <dos/dos.h>
#include <rexx/storage.h>

#define NO_GLOBALS
#include "TeXPrtRexx.h"

#define RESINDEX(stype) (((long) &((struct stype *)0)->res) / sizeof(long))

char	RexxPortBaseName[80] = "TeXPrtPort";
char	*rexx_extension = "TeXPrtPort";

struct rxs_command rxs_commandlist[] =
{
	{ "CONFIG", "SAVE/S,SAVEAS/K", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_config, 1 },
	{ "COPIES", "NUMBER/A/N", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_copies, 1 },
	{ "DRIVER", "NUMBER/N", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_driver, 1 },
	{ "DVIFILE", "FILE/A", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_dvifile, 1 },
	{ "FROM_TO", "DOCUMENT/S,FROM/N/K,TO/N/K", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_from_to, 1 },
	{ "HOFFSET", "MM/A/N", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_hoffset, 1 },
	{ "OPTION1", "ON/S,OFF/S", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_option1, 1 },
	{ "OPTION2", "ON/S,OFF/S", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_option2, 1 },
	{ "OPTION3", "ON/S,OFF/S", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_option3, 1 },
	{ "OPTION4", "ON/S,OFF/S", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_option4, 1 },
	{ "ORIENTATION", "PORTRAIT/S,LANDSCAPE/S", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_orientation, 1 },
	{ "PAGES", "ALL/S,EVEN/S,ODD/S", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_pages, 1 },
	{ "PRINT", NULL, NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_print, 1 },
	{ "QUIT", "FORCE/S", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_quit, 1 },
	{ "REVERSE", "ON/S,OFF/S", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_reverse, 1 },
	{ "TOBACK", NULL, NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_toback, 1 },
	{ "TOFRONT", NULL, NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_tofront, 1 },
	{ "VOFFSET", "MM/A/N", NULL, 0, (void (*)(struct RexxHost *,void **,long,struct RexxMsg *)) rx_voffset, 1 },
	{ NULL, NULL, NULL, NULL, NULL }
};

int		command_cnt = 18;

static struct arb_p_link link0[] = {
	{"VOFFSET", 1}, {"TO", 2}, {"REVERSE", 5}, {"QUIT", 6}, {"P", 7}, {"O", 10},
	{"HOFFSET", 17}, {"FROM_TO", 18}, {"D", 19}, {"CO", 22}, {NULL, 0} };

static struct arb_p_link link2[] = {
	{"FRONT", 3}, {"BACK", 4}, {NULL, 0} };

static struct arb_p_link link7[] = {
	{"RINT", 8}, {"AGES", 9}, {NULL, 0} };

static struct arb_p_link link10[] = {
	{"RIENTATION", 11}, {"PTION", 12}, {NULL, 0} };

static struct arb_p_link link12[] = {
	{"4", 13}, {"3", 14}, {"2", 15}, {"1", 16}, {NULL, 0} };

static struct arb_p_link link19[] = {
	{"VIFILE", 20}, {"RIVER", 21}, {NULL, 0} };

static struct arb_p_link link22[] = {
	{"PIES", 23}, {"NFIG", 24}, {NULL, 0} };

struct arb_p_state arb_p_state[] = {
	{-1, link0}, {17, NULL}, {15, link2}, {16, NULL}, {15, NULL},
	{14, NULL}, {13, NULL}, {11, link7}, {12, NULL}, {11, NULL},
	{6, link10}, {10, NULL}, {6, link12}, {9, NULL}, {8, NULL},
	{7, NULL}, {6, NULL}, {5, NULL}, {4, NULL}, {2, link19},
	{3, NULL}, {2, NULL}, {0, link22}, {1, NULL}, {0, NULL} 
	};

