home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 5 Edit / 05-Edit.zip / pmcstex.zip / install / cmd.CS / MAKETEXP.cmd < prev    next >
OS/2 REXX Batch file  |  1996-04-24  |  3KB  |  89 lines

  1. @echo off
  2. REM    This script files has been modified by Guido Sawade basing
  3. REM    upon suggestions of lots of dvips users.
  4. REM
  5. REM    This script file makes a new TeX PK font, because one wasn't
  6. REM    found.  Parameters are:
  7. REM 
  8. REM    name dpi bdpi magnification [mode]
  9. REM 
  10. REM    `name' is the name of the font, such as `cmr10'.  `dpi' is
  11. REM    the resolution the font is needed at.  `bdpi' is the base
  12. REM    resolution, useful for figuring out the mode to make the font
  13. REM    in.  `magnification' is a string to pass to MF as the
  14. REM    magnification.  `mode', if supplied, is the mode to use.
  15. REM
  16. REM    When you want to get tfm or log files of the fonts generated,
  17. REM    see section 'donemode:'
  18. REM 
  19. REM    Because of MSDOS memory constraints, this batch file just
  20. REM    creates a mfjob file, so that the fonts can be created later.
  21. REM    Under OS/2, change at the bootom of file to create fonts immediately
  22. REM
  23.  
  24. REM NAME=%1 DPI=%2 BDPI=%3 MAG=%4 MODE=%5
  25.  
  26. if NOT '%4%' == '' goto nousage
  27. echo USAGE: maketexp NAME DPI BDPI MAG [MODE]
  28. echo !  see comments in /emtex/bin/maketexp.bat/.cmd  !
  29. goto exit
  30.  
  31. :nousage
  32. if exist dvips.mfj  goto :second
  33. echo %% dvips.mfj - created by dvips > dvips.mfj
  34. echo input [dvidrv]; >> dvips.mfj
  35. echo Created dvips.mfj
  36.  
  37. :second
  38. echo { >> dvips.mfj
  39. echo base=plain; >> dvips.mfj
  40. echo font=%1; >> dvips.mfj
  41. echo mag=%4;  >> dvips.mfj
  42.  
  43. if "%5" == ""  goto :nomode
  44. if "%5" == "imagen"  goto :hpmode
  45. if "%5" == "laserjet"  goto :hpmode
  46. if "%5" == "laserjetIV"  goto :hpIVmode
  47. if "%5" == "deskjet"  goto :hpdjmode
  48.  
  49. :goodmode
  50. echo mode=%5[%3]; >> dvips.mfj
  51. echo output=pk[%DVIDRVFONTS%\%5\@Rrdpi\@f]; >> dvips.mfj
  52. goto :donemode
  53.  
  54. :hpmode
  55. echo mode=laserjet[%3]; >> dvips.mfj
  56. echo output=pk[%DVIDRVFONTS%\lj\dpi@Rr\@f]; >> dvips.mfj
  57. goto :donemode
  58.  
  59. :hpIVmode
  60. echo mode=laserjetIV[%3]; >> dvips.mfj
  61. echo output=pk[%DVIDRVFONTS%\ljh\dpi@Rr\@f]; >> dvips.mfj
  62. goto :donemode
  63.  
  64. :hpdjmode
  65. echo mode=deskjet[%3]; >> dvips.mfj
  66. echo output=pk[%DVIDRVFONTS%\dj\dpi@Rr\@f]; >> dvips.mfj
  67. goto :donemode
  68.  
  69. :nomode
  70. echo m; >> dvips.mfj
  71.  
  72. :donemode
  73. REM Uncomment one or both of the following if you want
  74. REM to get additional files from the METAFONT run.
  75. REM echo output=tfm[%DVIDRVFONTS%\tfm\@f]; >> dvips.mfj
  76. REM echo output=log[%DVIDRVFONTS%\log\@f]; >> dvips.mfj
  77. echo } >> dvips.mfj
  78.  
  79.  
  80. REM Yes, this is really the bottom :)    *************************************
  81. REM
  82. REM Uncomment the following lines and comment out the echo instruction to
  83. REM make operation automatic:
  84. mfjob dvips
  85. del dvips.mfj
  86. rem echo Run "mfjob dvips"
  87.  
  88. :exit 
  89.