1*381Smuffin /* 2*381Smuffin * Copyright 1998 Sun Microsystems, Inc. All rights reserved. 3*381Smuffin * Use is subject to license terms. 4*381Smuffin */ 5*381Smuffin 60Sstevel@tonic-gate /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */ 70Sstevel@tonic-gate /* All Rights Reserved */ 80Sstevel@tonic-gate 90Sstevel@tonic-gate /* 100Sstevel@tonic-gate * Copyright (c) 1980 Regents of the University of California. 110Sstevel@tonic-gate * All rights reserved. The Berkeley software License Agreement 120Sstevel@tonic-gate * specifies the terms and conditions for redistribution. 130Sstevel@tonic-gate */ 140Sstevel@tonic-gate 15*381Smuffin #pragma ident "%Z%%M% %I% %E% SMI" 160Sstevel@tonic-gate 170Sstevel@tonic-gate /* t..c : external declarations */ 180Sstevel@tonic-gate 190Sstevel@tonic-gate # include "stdio.h" 200Sstevel@tonic-gate # include "ctype.h" 210Sstevel@tonic-gate 220Sstevel@tonic-gate # define MAXLIN 200 230Sstevel@tonic-gate # define MAXHEAD 100 240Sstevel@tonic-gate # define MAXCOL 20 250Sstevel@tonic-gate # define MAXCHS 2000 260Sstevel@tonic-gate # define MAXSTR 1024 270Sstevel@tonic-gate # define MAXRPT 100 280Sstevel@tonic-gate # define CLLEN 10 290Sstevel@tonic-gate # define SHORTLINE 4 300Sstevel@tonic-gate # define BIGBUF 8192 31*381Smuffin extern char *gets1(char *, int); 320Sstevel@tonic-gate extern int nlin, ncol, iline, nclin, nslin; 330Sstevel@tonic-gate extern int style[MAXHEAD][MAXCOL]; 340Sstevel@tonic-gate extern int ctop[MAXHEAD][MAXCOL]; 350Sstevel@tonic-gate extern char font[MAXHEAD][MAXCOL][2]; 360Sstevel@tonic-gate extern char csize[MAXHEAD][MAXCOL][4]; 370Sstevel@tonic-gate extern char vsize[MAXHEAD][MAXCOL][4]; 380Sstevel@tonic-gate extern char cll[MAXCOL][CLLEN]; 390Sstevel@tonic-gate extern int stynum[]; 400Sstevel@tonic-gate extern int F1, F2; 410Sstevel@tonic-gate extern int lefline[MAXHEAD][MAXCOL]; 420Sstevel@tonic-gate extern int fullbot[]; 430Sstevel@tonic-gate extern char *instead[]; 440Sstevel@tonic-gate extern int expflg; 450Sstevel@tonic-gate extern int ctrflg; 460Sstevel@tonic-gate extern int evenflg; 470Sstevel@tonic-gate extern int evenup[]; 480Sstevel@tonic-gate extern int boxflg; 490Sstevel@tonic-gate extern int dboxflg; 500Sstevel@tonic-gate extern int linsize; 510Sstevel@tonic-gate extern int tab; 520Sstevel@tonic-gate extern int pr1403; 530Sstevel@tonic-gate extern int linsize, delim1, delim2; 540Sstevel@tonic-gate extern int allflg; 550Sstevel@tonic-gate extern int textflg; 560Sstevel@tonic-gate extern int left1flg; 570Sstevel@tonic-gate extern int rightl; 580Sstevel@tonic-gate struct colstr {char *col, *rcol;}; 590Sstevel@tonic-gate extern struct colstr *table[]; 60*381Smuffin extern int *alocv(int); 610Sstevel@tonic-gate extern char *cspace, *cstore; 62*381Smuffin extern char *chspace(void); 63*381Smuffin extern char *maknew(char *); 640Sstevel@tonic-gate extern char *exstore, *exlim; 650Sstevel@tonic-gate extern int sep[]; 660Sstevel@tonic-gate extern int used[], lused[], rused[]; 670Sstevel@tonic-gate extern int linestop[]; 680Sstevel@tonic-gate extern char *leftover; 690Sstevel@tonic-gate extern char *last, *ifile; 700Sstevel@tonic-gate extern int texname; 710Sstevel@tonic-gate extern int texct; 720Sstevel@tonic-gate extern char texstr[]; 730Sstevel@tonic-gate extern int linstart; 740Sstevel@tonic-gate 750Sstevel@tonic-gate 760Sstevel@tonic-gate extern FILE *tabin, *tabout; 770Sstevel@tonic-gate # define CRIGHT 80 780Sstevel@tonic-gate # define CLEFT 40 790Sstevel@tonic-gate # define CMID 60 800Sstevel@tonic-gate # define S1 31 810Sstevel@tonic-gate # define S2 32 820Sstevel@tonic-gate # define TMP 38 830Sstevel@tonic-gate # define SF 35 840Sstevel@tonic-gate # define SL 34 850Sstevel@tonic-gate # define LSIZE 33 860Sstevel@tonic-gate # define SIND 37 870Sstevel@tonic-gate # define SVS 36 880Sstevel@tonic-gate /* this refers to the relative position of lines */ 890Sstevel@tonic-gate # define LEFT 1 900Sstevel@tonic-gate # define RIGHT 2 910Sstevel@tonic-gate # define THRU 3 920Sstevel@tonic-gate # define TOP 1 930Sstevel@tonic-gate # define BOT 2 94