xref: /csrg-svn/old/roff/common_source/tdef.h (revision 48302)
1*48302Sbostic /*-
2*48302Sbostic  * Copyright (c) 1991 The Regents of the University of California.
3*48302Sbostic  * All rights reserved.
4*48302Sbostic  *
5*48302Sbostic  * %sccs.include.proprietary.c%
6*48302Sbostic  *
7*48302Sbostic  *	@(#)tdef.h	4.9 (Berkeley) 04/18/91
8*48302Sbostic  */
914515Ssam 
1030993Skarels #include <sys/param.h>
1130993Skarels #undef CMASK			/* XXX */
1230993Skarels #undef BIG			/* XXX */
1330993Skarels #define MAXPTR (-1)		/* max value of any pointer variable */
147059Srrh #ifdef NROFF	/*NROFF*/
157059Srrh #define EM t.Em
167059Srrh #define HOR t.Hor
177059Srrh #define VERT t.Vert
187059Srrh #define INCH 240	/*increments per inch*/
197059Srrh #define SPS INCH/10	/*space size*/
207059Srrh #define SS INCH/10	/* " */
217059Srrh #define TRAILER 0
227059Srrh #define UNPAD 0227
237059Srrh #define PO 0 /*page offset*/
247059Srrh #define ASCII 1
257059Srrh #define PTID 1
267059Srrh #define LG 0
277059Srrh #define DTAB 0	/*set at 8 Ems at init time*/
287059Srrh #define ICS 2*SPS
297059Srrh #define TEMP 256	/*65K*/
307059Srrh #endif
317059Srrh #ifndef NROFF	/*TROFF*/
327059Srrh #define INCH 432	/*troff resolution*/
337059Srrh #define SPS 20	/*space size at 10pt; 1/3 Em*/
347059Srrh #define SS 12	/*space size in 36ths of an em*/
357059Srrh #define TRAILER 6048	/*144*14*3 = 14 inches*/
367059Srrh #define UNPAD 027
377059Srrh #define PO 416 /*page offset 26/27ths inch*/
387059Srrh #define HOR 1
397059Srrh #define VERT 3
407059Srrh #define EM (6*(pts&077))
417059Srrh #define ASCII 0
427059Srrh #define PTID 0
437059Srrh #define LG 1
447059Srrh #define DTAB (INCH/2)
457059Srrh #define ICS 3*SPS
467059Srrh #define TEMP 512	/*128K*/
477059Srrh #endif
487059Srrh 
497059Srrh #include <signal.h>
507059Srrh #define NARSP 0177	/*narrow space*/
517059Srrh #define HNSP 0226	/*half narrow space*/
527059Srrh #define PS 10	/*default point size*/
537059Srrh #define FT 0	/*default font position*/
547059Srrh #define LL 65*INCH/10	/*line length; 39picas=6.5in*/
557059Srrh #define VS INCH/6	/*vert space; 12points*/
5613256Srrh #ifdef VMUNIX
5713256Srrh #define NN 528	/*number registers*/
5813256Srrh #else
5913256Srrh #define NN 132	/*number registers*/
6013256Srrh #endif
6113256Srrh /* #define NN 200	*/
627059Srrh #define NNAMES 14 /*predefined reg names*/
637059Srrh #define NIF 15	/*if-else nesting*/
647059Srrh #define NS 64	/*name buffer*/
657059Srrh #define NTM 256	/*tm buffer*/
667059Srrh #define NEV 3	/*environments*/
677059Srrh #define EVLSZ 10	/*size of ev stack*/
687059Srrh /* #define EVS 4*256	*/
6913256Srrh #ifdef VMUNIX
7013256Srrh #define NM 600
7113256Srrh #define EVS 6*256	/*environment size in words*/
7213256Srrh #else
737059Srrh #define NM 300	/*requests + macros*/
7413256Srrh #define EVS 3*256	/*environment size in words*/
7513256Srrh #endif
767059Srrh #define DELTA 512	/*delta core bytes*/
777059Srrh #define NHYP 10	/*max hyphens per word*/
787059Srrh #define NHEX 128	/*byte size of exception word list*/
797059Srrh #define NTAB 35	/*tab stops*/
807059Srrh #define NSO 5	/*"so" depth*/
8113256Srrh #ifdef VMUNIX
8213256Srrh #define WDSIZE 340	/*word buffer size*/
8313256Srrh #define LNSIZE 960	/*line buffer size*/
8413256Srrh #else
857059Srrh #define WDSIZE 170	/*word buffer size*/
867059Srrh #define LNSIZE 480	/*line buffer size*/
8713256Srrh #endif
887059Srrh /* #define LNSIZE 680	*/
897059Srrh #define NDI 5	/*number of diversions*/
907059Srrh #define DBL 0100000	/*double size indicator*/
917059Srrh #define MOT 0100000	/*motion character indicator*/
927059Srrh #define MOTV 0160000	/*clear for motion part*/
937059Srrh #define VMOT 0040000	/*vert motion bit*/
947059Srrh #define NMOT 0020000	/* negative motion indicator*/
957059Srrh #define MMASK 0100000	/*macro mask indicator*/
967059Srrh #define CMASK 0100377
977059Srrh #define ZBIT 0400	/*zero width char*/
987059Srrh #define BMASK 0377
997059Srrh #define BYTE 8
1007059Srrh #define IMP 004	/*impossible char*/
1017059Srrh #define FILLER 037
1027059Srrh #define PRESC 026
1037059Srrh #define HX 0376	/*High-order part of xlss*/
1047059Srrh #define LX 0375	/*low-order part of xlss*/
1057059Srrh #define CONT 025
1067059Srrh #define COLON 013
1077059Srrh #define XPAR 030
1087059Srrh #define ESC 033
1097059Srrh #define FLSS 031
1107059Srrh #define RPT 014
1117059Srrh #define JREG 0374
1127059Srrh #define NTRAP 20	/*number of traps*/
1137059Srrh #define NPN 20	/*numbers in "-o"*/
1147059Srrh #define T_PAD 0101	/*cat padding*/
1157059Srrh #define T_INIT 0100
1167059Srrh #define T_IESC 16 /*initial offset*/
1177059Srrh #define T_STOP 0111
1187059Srrh #define NPP 10	/*pads per field*/
11913256Srrh #ifdef VMUNIX
12013256Srrh #define FBUFSZ 1024
12113256Srrh #else
1227059Srrh #define FBUFSZ 256	/*field buf size words*/
12313256Srrh #endif
12419953Smckusick #define OBUFSZ 8192	/*bytes*/
12519953Smckusick #define IBUFSZ 8192	/*bytes*/
1267059Srrh #define NC 256	/*cbuf size words*/
1277059Srrh #define NOV 10	/*number of overstrike chars*/
1287059Srrh #define TDELIM 032
1297059Srrh #define LEFT 035
1307059Srrh #define RIGHT 036
1317059Srrh #define LEADER 001
1327059Srrh #define TAB 011
1337059Srrh #define TMASK  037777
1347059Srrh #define RTAB 0100000
1357059Srrh #define CTAB 0040000
1367059Srrh #define OHC 024
1377059Srrh 
1387059Srrh #define PAIR(A,B) (A|(B<<BYTE))
1397059Srrh 
1407059Srrh #define BLK  128	/*alloc block words*/
14113257Srrh 
14213257Srrh #ifdef VMUNIX
14313257Srrh #define	BIG 1024
14413257Srrh #endif VMUNIX
14513257Srrh 
1467059Srrh #ifdef BIG
1477059Srrh typedef long filep;
1487059Srrh #define NBLIST BIG	/*allocation , BIG = 256 per 65k*/
1497059Srrh #define BLKBITS 7	/*for BLK=128*/
1507059Srrh #endif
1517059Srrh #ifndef BIG
1527059Srrh typedef unsigned filep;
1537059Srrh #define NBLIST TEMP	/*allocation list, TEMP<=512*/
1547059Srrh /* BLK*NBLIST<=65536 words, if filep=unsigned */
1557059Srrh #define BLKBITS 0
1567059Srrh #endif
157