xref: /titanic_44/usr/src/cmd/eqn/e.h (revision b7f45089ccbe01bab3d7c7377b49d80d2ae18a69)
1 /*	Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T	*/
2 /*	  All Rights Reserved  	*/
3 
4 
5 /*
6  * Copyright (c) 1980 Regents of the University of California.
7  * All rights reserved. The Berkeley software License Agreement
8  * specifies the terms and conditions for redistribution.
9  */
10 
11 /*
12  * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
13  * All Rights Reserved.
14  */
15 
16 # ident	"%Z%%M%	%I%	%E% SMI"	/* "@(#)ucbeqn:e.h 1.1" */
17 
18 #include <stdio.h>
19 
20 #define	FATAL	1
21 #define	ROM	'1'
22 #ifndef NEQN
23 #define	ITAL	'2'
24 #define	BLD	'3'
25 #else NEQN
26 #define	ITAL	'1'
27 #define	BLD	'1'
28 #endif NEQN
29 
30 #ifndef NEQN
31 #define	VERT(n)	((((n)+1)/3)*3)
32 #define POINT	72
33 #define EM(m, ps)	(int)((((float)(m)*(ps) * resolution) / POINT))
34 #else NEQN
35 #define	VERT(n)	(20 * (n))
36 #endif NEQN
37 #define	EFFPS(p)	((p) >= 6 ? (p) : 6)
38 
39 extern int	dbg;
40 extern int	ct;
41 extern int	lp[];
42 extern int	used[];	/* available registers */
43 extern int	ps;	/* dflt init pt size */
44 extern int	resolution;	/* resolution of ditroff */
45 extern int	deltaps;	/* default change in ps */
46 extern int	gsize;	/* global size */
47 extern int	gfont;	/* global font */
48 extern int	ft;	/* dflt font */
49 extern FILE	*curfile;	/* current input file */
50 extern int	ifile;	/* input file number */
51 extern int	linect;	/* line number in current file */
52 extern int	eqline;	/* line where eqn started */
53 extern int	svargc;
54 extern char	**svargv;
55 extern int	eht[];
56 extern int	ebase[];
57 extern int	lfont[];
58 extern int	rfont[];
59 extern int	yyval;
60 extern int	*yypv;
61 extern int	yylval;
62 extern int	eqnreg, eqnht;
63 extern int	lefteq, righteq;
64 extern int	lastchar;	/* last character read by lex */
65 extern int	markline;	/* 1 if this EQ/EN contains mark or lineup */
66 
67 typedef struct s_tbl {
68 	char	*name;
69 	char	*defn;
70 	struct s_tbl *next;
71 } tbl;
72 extern  char    *spaceval;  /* use in place of normal \x (for pic) */
73