home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / unixtex-6.1b-src.tgz / tar.out / contrib / unixtex / dviljk / config.h < prev    next >
C/C++ Source or Header  |  1996-09-28  |  6KB  |  275 lines

  1. /* gcc -ansi doesn't predefine `unix', since ANSI forbids it.  And AIX
  2.    generally doesn't predefine unix, who knows why.  */
  3. #ifndef unix
  4. #if defined (__unix__) || defined (_AIX)
  5. #define unix
  6. #endif
  7. #endif
  8.  
  9. #define USEPXL
  10.  
  11. /*
  12.  *  default font path
  13.  *  can be overridden by environment variable TEXPXL
  14.  *  or -a command line option
  15.  *  popular choice:
  16.  * #define  FONTAREA       "/usr/local/lib/tex/fonts/pk"
  17.  */
  18. #ifndef FONTAREA
  19. #ifdef vms
  20. #define FONTAREA    "tex$pkdir:"
  21. #else
  22. #ifdef _AMIGA
  23. #define FONTAREA    "TeX:pk"
  24. #else
  25. #define FONTAREA    "/usr/local/lib/tex/pk300"
  26. #endif
  27. #endif
  28. #endif
  29.  
  30. /* if DO_SUBDIRECTORIES is specified, search to this depth */
  31. #ifndef MAX_SUBDIR_SEARCH_DEPTH 
  32. #define MAX_SUBDIR_SEARCH_DEPTH 10
  33. #endif
  34.  
  35. /* 
  36.  * if your LaserJet II P or LaserJet III or LaserJet 2000
  37.  * complains about not enough memory, you might try to reduce 
  38.  * the value below or uncomment to use the default settings
  39.  */  
  40. #ifdef LJ2P
  41. #define  MAX_FONTS_PER_PAGE 255         /* maximum number of fonts per page */
  42. #endif
  43.  
  44.  
  45. /* Timing is not very portable.... if you have troubles, use
  46.  * -DNO_TIMING in the Makefile
  47.  */
  48.  
  49. #ifdef u3b2
  50. #define NO_TIMING
  51. #endif
  52. #ifdef _AMIGA
  53. #define NO_TIMING
  54. #endif
  55. #ifdef KPATHSEA
  56. #define NO_TIMING
  57. #endif
  58.  
  59. #ifndef NO_TIMING
  60. #define TIMING
  61. #endif
  62.  
  63. /*
  64.  * per default use MakeTexPK in unix environments unless it is not wanted 
  65.  */
  66. #ifdef unix
  67. #ifndef MAKETEXPK
  68. /* name of the program which is called to generate missing pk files
  69.  */
  70. #define MAKETEXPK "MakeTeXPK"
  71. #endif
  72. #endif
  73.  
  74. #if defined(_AMIGA) || defined (__amigaos__)
  75. #ifndef MAKETEXPK
  76. /* name of the program which is called to generate missing pk files
  77.  */
  78. #define MAKETEXPK "MakeTeXPK"
  79. #endif
  80. #endif
  81.  
  82.  
  83.  
  84. #ifdef NO_MAKETEXPK
  85. #undef MAKETEXPK
  86. #endif
  87.  
  88. /*
  89.  * assure that LJ2P is defined when LJ4 is defined;
  90.  * compile with support for LJ4's resident fonts
  91.  */
  92. #ifdef LJ4
  93. #define LJ2P
  94. #define LJ_RESIDENT_FONTS
  95. #endif
  96.  
  97. /*
  98.  * assure that LJ2 is defined when LJ2P is defined
  99.  */
  100. #ifdef LJ2P
  101. #ifndef LJ2
  102. #define LJ2
  103. #endif
  104. #endif
  105.  
  106. /*
  107.  * assure that LJ is defined when LJ2 of LJ4 is defined
  108.  */
  109. #if defined(LJ2)
  110. #ifndef LJ
  111. #define LJ
  112. #endif
  113. #endif
  114.  
  115. /*
  116.  * assure that IBM3812 is not defined when LJ is defined
  117.  */ 
  118. #ifdef LJ
  119. #ifdef IBM3812
  120. #undef IBM3812
  121. #endif
  122. #endif
  123.  
  124. #ifdef LJ_RESIDENT_FONTS
  125. #ifndef DEFAULT_TFM_PATH
  126. #define DEFAULT_TFM_PATH   "/usr/local/lib/tex/fonts"
  127. #endif
  128. #endif
  129.  
  130.  
  131. #define  _TRUE      (bool) 1
  132. #define  _FALSE     (bool) 0
  133.  
  134. #define  STRSIZE         255     /* stringsize for file specifications  */
  135.  
  136. typedef  char    bool;
  137.  
  138. /* The smallest signed type: use `signed char' if ANSI C, `short' if
  139.    char is unsigned, otherwise `char'.  */
  140. #ifndef SCHAR_TYPE
  141. #ifdef __STDC__
  142. #define SCHAR_TYPE signed char
  143. #else /* not __STDC */
  144. #ifdef __CHAR_UNSIGNED__
  145. #define SCHAR_TYPE short
  146. #else
  147. #define SCHAR_TYPE char
  148. #endif
  149. #endif /* not __STDC__ */
  150. #endif /* not SCHAR_TYPE */
  151. typedef SCHAR_TYPE signed_char;
  152.  
  153.  
  154. #if !defined(u3b2) && !defined(LONG_64_BITS)
  155. #define  ARITHMETIC_RIGHT_SHIFT
  156. #endif
  157.  
  158. #if SIZEOF_LONG > 4
  159. #define long4 int
  160. #else
  161. #define long4 long
  162. #endif
  163.  
  164. bool findfile();
  165.  
  166.  
  167. /* 
  168.  * maximal number of characters in font file
  169.  * #define  LASTFNTCHAR  127        7-bit classic version
  170.  * #define  LASTFNTCHAR  255        8-bit fonts
  171.  */
  172.  
  173. #ifdef SEVENBIT 
  174. #define LASTFNTCHAR 127
  175. #else
  176. #define LASTFNTCHAR  255
  177. #endif
  178.  
  179.  
  180.  
  181. /* this information is needed in findfile.c and dvi2xx.c, NO CUSTOMIZATION */
  182. #ifdef LJ
  183. # ifndef MFMODE300
  184. #  define MFMODE300 "cx"     /* mode definition for metafont 300dpi */
  185. # endif
  186. # ifdef LJ4
  187. #  ifndef MFMODE600
  188. #   define MFMODE600 "ljfour"   /* mode definition for metafont 600dpi */
  189. #  endif
  190. # else
  191. #  define MFMODE MFMODE300       /* default mode */
  192. # endif
  193. #endif
  194.  
  195. #ifdef IBM3812
  196. #define RESOLUTION    240
  197. #ifndef MFMODE
  198. #define MFMODE "ibmteot"    /* mode definition for metafont */
  199. #endif
  200. #endif
  201.  
  202.  
  203. #ifdef unix
  204. #define OS "Unix"
  205. #define READ_BINARY     "r"
  206. #define WRITE_BINARY    "w"
  207. #if !defined (STDC_HEADERS) && !defined (labs)
  208. #define labs(x) abs(x)
  209. #endif
  210. #endif
  211. #ifdef MSDOS
  212. #define OS "MS-DOS"
  213. #define READ_BINARY     "rb"
  214. #define WRITE_BINARY    "wb"
  215. #define MSC5
  216. #endif
  217. #ifdef OS2
  218. #define OS "OS/2"
  219. #define READ_BINARY     "rb"
  220. #define WRITE_BINARY    "wb"
  221. #define MSC5
  222. #endif
  223.  
  224. #ifdef vms
  225. #define OS "VMS"
  226. #include <ssdef.h>
  227. #include <stsdef.h>
  228. #define ftell vms_ftell            /* use some external routines, because */
  229. #define fseek vms_fseek            /* of some bugs in the VMS run time    */
  230. #define getchar vms_getchar        /* library */
  231. #define getenv vms_getenv
  232. #define ungetc vms_ungetc
  233. #define getname vms_getname
  234. #define READ_BINARY     "rb"
  235. #define WRITE_BINARY    "wb","rfm=fix","bls=512","mrs=512" /* fixed records */
  236. #define labs(x) abs(x)
  237. #endif
  238.  
  239. #if defined (_AMIGA) || defined (__amigaos__)
  240. #define OS "Amiga"
  241. #define READ_BINARY     "r"
  242. #define WRITE_BINARY    "w"
  243. #ifdef __SASC
  244. #define sys_errlist __sys_errlist
  245. #include <stdlib.h>
  246. #endif
  247. #endif
  248.  
  249.  
  250. /* Information returned by tfm_read_info. */
  251. typedef struct {
  252.   /* These string lengths are imposed by the TFM format. Either of these
  253.      values may be the empty string.  */
  254.   char coding_scheme[40];
  255.   char family[20];
  256.    
  257.   /* The second fontdimen. */
  258.   unsigned interword;
  259.    
  260.   /* These values are what will work to select the font in PCL. If this
  261.      TFM file doesn't have the `KN' extensions (distinguishable by the
  262.      family == "HPAUTOTFM"). */
  263. #define SPACING_FIXED 0
  264. #define SPACING_PROPORTIONAL 1
  265.   unsigned spacing;
  266.   int weight;
  267.   unsigned style;
  268.   unsigned typeface_id;
  269.  
  270.   /* TFM files can always have 256 characters, even if we're using the
  271.      old pixel format that only supports 128. The values are fix-words
  272.      scaled by the design size; i.e., straight from the TFM file. */
  273.   long4 widths[256];
  274. } tfm_info_type;
  275.