summaryrefslogtreecommitdiff
path: root/fonts/utilities/ps4mf/ps4mf.txt
blob: da04f4ab7b2fd9d4b5d7bde6f0fe78fa8b0d1e5e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
                            +-------------------+
                            |  -*-  PS4MF -*-   |
                            +-------------------+
                        Unix-Version: 1.1 June 1996

                      (c) Markus Neteler 1994 - 1996
                           Hannover, Germany

                 Conversion of Postscript-Type1-fonts to TeX
 
 CONTENTS

  I.    Description
  II.   Quality of letters
  III.  What to do
  IV.   Some information about <font>.afm
  V.    Any problems ?
  VI.   Where to get fonts
  VII.  New versions of ps4mfxx.zip
  VIII. Copyright


 I. DESCRIPTION

   In order to use Postscript-Type1-fonts for TeX without any special
   encoding scheme (like dc,ec,nfss) you now can convert your favourite
   Postscript-font.
   This font has to be encoded in the "AdobeStandardEncoding-scheme".
   After conversion into the standard-cm-encoding of TeX you can use
   the fonts in LaTeX 2.09.
   If you use LaTeX 2.e you need dc-encoding: this is also possible.

   This package is based on the ps2mf-package of the authors:
   Marcel Dings (original idea of the ps2mf-package) and Erik-Jan Vens (new
   ps2mf).


 II. QUALITY OF LETTERS

   Fonts made by programs like Adobe(tm), Corel's Wfnboss(tm) and Fontographer
   (Apple(tm)) seem to be of a better quality than fonts generated by
   ghostscript's getafm. If you get free or shareware-fonts you should take
   care of that.


 III. WHAT TO DO
      (Please read ../ps4mf/install.txt before you start!)

  (0) Copy your postscript-font into directory ../ps4mf.
       ../ stands for your home or whereever you put the package.

  (1) Because of two different AdobeEncodingSchemes look at <font>.afm for
      the actual used encoding scheme:

        conv_ado.sh          Adobe-made-fonts converting routine
        conv_east.sh          east-european converting routine for special
                              postscript-fonts
        conv_dc.sh           dc encoding converting routine for Adobefonts

      (a) Fonts made by programs like Adobe(tm), Corel's Wfnboss(tm) with
          AdobeStandardEncoding and Fontographer (EncodingScheme AppleStandard)
          must be converted with conv_ado.sh -- Ado like Adobe:

          Typical encoding in <font>.afm:
            character "grave" has got the number C 128 or C 96:
            "C 128 ; W ... grave ... "
            "C 96  ; W ... grave ... "


          To avoid trivial problems with syntax-error "C 175":
           While looking for the name of the font-generating program
           at <font>.afm, check this line:
                C 175 ; WX 278 ; N ; B 11 33 44 566
           If no charactername is specified (like here), delete this line.
           Otherwise you maybe won't get a metafont-file!
           Please read PROBLEMS (3) further down for this, too.


      (b) For east-europe-TeXusers I have added conv_east.sh:
          It generates a special encoded metafont-file (8 bit font) -
          please look at encoding scheme in ps2mf/east.cfg.

      (c) If you want to have dc-encoded fonts take conv_dc.sh

      If you don't find a notice of the font-generating program or don't have
      the character "grave" to look for the number just try both - you will
      just see the upper and lower letters and no accents and foreign letters
      etc. in your TeX document if you are wrong.
      Just take the better result!

     IMPORTANT:

     IF FILES <font>.afm OR <font>.pfb ARE MISSING:

      - If <font>.afm is missing and you only have <font>.pfm try
              pfm2afm <font>
        to convert the <font>.pfm -file to <font>.afm .
        Look on ftp-servers for this program.
      - You can also take ghostscript's getafm together with t1tools/t1utils
        written by Thomas  Wolff@inf.fu-berlin.de.


  (2) If necessary edit conv_ado.sh  for your TeX-directory-structure.

  (3) Now run simply conv_ado.sh with fontname as parameter.

      Example:
                conv_ado garamond

  (4) Use the new font in your TeX-documents:


   (A) For the use of LaTeX 2.09:

          (You should move newfont.tex and redefint.tex from /ps4mf/texinput
           into the TeX-directory /usr/local/tex/texinput.)

          (a) By using TeX-command
               e.g. \newfont{\garamond}{garamond scaled 1000}.

           or
          (b) If you want to change fonts generally from computer-modern
              fontfamily to your favourite postscriptfonts, just declare the
              new fontnames in the file "newfont.tex". Then every magnification
              (\large, \Huge etc.) will use your postscript-font.
             

      Look at
      ../ps4mf/texinput/sample1.tex (LaTeX: use of newfont.tex) or
      ../ps4mf/texinput/sample2.tex (LaTeX: use of redefint.tex) or
      ../ps4mf/texinput/dingbats.tex (LaTeX: use of font dingbats) or
      ../ps4mf/texinput/testfont.tex (TeX: character-table) for example.
 
   (B) For the use of LaTeX 2.e (and the teTeX-package, for other packages 
                                 please send a mail to me with suggestions):

        It seems to be somehow complicated but is rather simple... :)

        (a) Copy the base-file ps2mfbas.mf to:
             
               /usr/lib/teTeX/texmf/metafont/misc/

        (b) Copy the (meta-)font-files *.mf (with dc-encoding) to:

               /usr/lib/teTeX/texmf/fonts/source/myfonts/dc/

            You have to create both directories ../myfonts/dc/.
   
        (c) The *.tfm-files are created by metafont, you can ignore them.


        (d) The original postscript-files have to be copied, too:

           - the *.afm -files to:
              
               /usr/lib/teTeX/texmf/fonts/afm/myfonts/
          
            Here you have to create the directory ../myfonts/.

           - the *.pfb -files also:

               /usr/lib/teTeX/texmf/fonts/type1/myfonts/

            Here you have to create the directory ../myfonts/.


         (e) Now you can declare a font-family (similar to "newfont.tex" which
             was for LaTeX 2.09):

            - Change to the directory

               /usr/lib/teTeX/texmf/tex/latex/psnfss
 
            - Create a file called  "T1xxxxx.fd"  where  xxxxx has to be
              substituted with the familyname which is defined in the first
              line of the file. Here you define all shapes etc. as you like it.
              Look further down for an example:

              Example for family "baskerville":

                 T1bask.fd   

              Content of file:        

                   \DeclareFontFamily{T1}{bask}{}
                   \DeclareFontShape{T1}{bask}{m}{n}{ <-> baskvl }{}     
                                               % medium norm.
                   \DeclareFontShape{T1}{bask}{b}{n}{ <-> baskvlb }{}    
                                               % bold norm.
                   \DeclareFontShape{T1}{bask}{bx}{n}{ <-> baskvlb }{}   
                                               % bold ext. norm.
                   \DeclareFontShape{T1}{bask}{m}{it}{ <-> baskvli }{}   
                                               % med. ital.

              Another example ist at ps4mf/font-definition/.

          (f) For the tetex-package you have to execute "texhash" at 
              unix-prompt to tell the system that there are more files 
              present now.

          (g) Now the big bang is coming ...

              Take you TeX-Document and add the following to the header

               %%%%%%%%%%%%%%%%%
               %[some of your definitions]

                   \usepackage[T1]{fontenc} 
                   \renewcommand{\familydefault}{bask}

               % Fuer deutschsprachige AnwenderInnen zusaetzlich:
                   \usepackage[iso]{umlaute}
                   \usepackage{german}
                   \selectlanguage{german}


 ENJOY!



 IV. SOME INFORMATION ABOUT <font>.afm

   (1)  The <font>.afm-file contains some lines like
           C 168 ; WX 445 ; N dieresis ; B -9 16 455 480 ;

        The "C 168" is the character-number,
        the "WX 445" I don't know at the moment,
        the "N dieresis" is the name of the character,
        the "B -9 16 455 480" is the character bounding box information.

   (2)  If you just have the <font>.pfb-file you can try to create a new
        <font>.afm-file with getafm.sh. Just type
         getafm <font>    (without extension .pfb).

        For getafm see above.


   (3)  To clean up afm-files or correct characters you can use "t1tidy.zip"
        (ask archie or me)


 V. ANY PROBLEMS ?

  (1) utopia.zip   - metafont problems!
        If you look into the .mf file after using conv_Gho you find many lines
        sprinkled randomly about the file containing only a right parenthesis
        " ) ". After deleting these lines Metafont runs without a problem
        and you now have a Utopia font.

  (2) If you get an error from ps2mf and afm2tfm like :

       B expected ; ! syntax error
        C 32 ; WX 278 ; N space ;
                                 ^
      there is no hope to convert this font. Some part of the font-description
      is missing (bug of the postscript-font generating program), you have to
      use another font or to get it via anonymous ftp (see further down).

      The correct syntax at file <font>.afm looks like
        C 32 ; WX 278 ; N space ; B 278 0 278 0 ;
      The part following "B" is necessary for ps2mf and afm2tfm.

  (3) No <font>.mf file is generated:
       ps2mf reports an syntax-error with C 175 or similar:
         ! syntax error
         C 175 ; WX 278 ; N ;
                           ^
      The character-name is missing, just delete this line in file <font>.afm
      This is an error of Corel's Wfnboss (the font-generating program).

  (4) You don't see any "umlauts" or other accents although there is a line

        e.g.:  C 168 ; WX 445 ; N dieresis ; B -9 16 455 480 ;
               (or some other character)

      There is a definition at <font>.afm but there no information
      in the binary file (<font>.pfb) - get another font, blame the
      font-creator...

  (5) You get an error of afm2tfm like

          "  Kern char not found
             KPX Y a -68         "

      Just ignore this.

  (6) If you have MAC-files you can try to convert them to Adobe with
        refont

  (7) Metafont-error like:
         "  ... [89][90][91]
            >> -1
            ! Invalid code has been replaced by 0.
            <to be read again>
                              ;
            l.9067 105=:-1;

            I was looking for a number between 0 and 255, or for a
            string of length 1. Didn't find it; will use 0 instead. "

      Please edit /usr/local/tex/mfinput/<font>.mf for that error:
        Then there are lines like

           ligtable 102:
           105=:-1;

        The "-1" is unknown by metafont - delete all
            ligtables <no>   followed by
            <no>=:-1

      Then you can run metafont again.

  (8) It was reported that dvihplq/dvidot give checksum errors. But it is
      possible to print out anyway. If you take the <font>.tfm file produced
      by metafont the problem will disappear (then your font won't end
      with character 127 but with 255 - the encoding of the first 128
      characters is still like computer modern: no differences!)



 VI. WHERE TO GET FONTS:
   
   


 VI. WHERE TO GET FONTS: 
 ----------------------- 
 (a)  To get a nice listings, character-pictures and ftp-connections of fonts 
      try WWW with mosaic/netscape/etc.: 
 
        CTAN at WWW: 
        http://jasper.ora.com/ 
 
        There is a fontpage which allows to look at fonts and download them 
        directly! 
 
 
 (b)  You can get postscript-fonts via anonymous ftp at 
 
    -  ftp.uni-stuttgart.de          (mirror of hobbes.nmsu.edu) 
          /pub/systems/os2/hobbes-mirror/multimed/fonts 
 
    -  ftp.uni-freiburg.de 
          /pc/os2/atmfonts 
 
    -  ftp obelix.icce.rug.nl 
          /pub/erikjan/fonts/type.one.fonts 
          /pub/erikjan/fonts/BitStream 
 
    -  garbo.uwasa.fi 
          /pc/fonts 
            - Attention: utopia.zip   - metafont problems! 
                If you look into the .mf file after using conv_gho you find 
                several hundred lines sprinkled randomly about the file 
                containing only a right parenthesis. When you delete these 
                lines, Metafont runs without a problem and you now have a 
                Utopia font. 
 
 
   Both files <font>.afm and <font>.pfb are necessary. 
   

   Recommended (tested) fonts: 
     agate.zip 
       agateb.zip 
       agatei.zip 
     bodoni.zip 
       bodonib.zip 
       bodonii.zip (change "ItalicAngle" from 1 to 16 in bodonii.afm) 
     boecklin.zip 
     dingbats.zip 
     fr-n.zip        (Frutiger) 
       fr-b.zip etc. (Frutiger bold) 
     garmnd.zip 
       garmndmi.zip (change "ItalicAngle" from 1 to 15 in garmndmi.afm) 
     goudyoi.zip  (change "ItalicAngle" from 1 to 4 in goudyoi.afm) 
     hobo.zip 
     kaufmann.zip 
     lowereas.zip  (use conv_ado2.bat to convert) 
     lowerwes.zip  (use conv_ado2.bat to convert) 
     peigmed.zip 
     peignot.zip 
     postcr.zip (from package atmfonts.zip, use conv_ado2.bat to convert) 
     sntfra.zip (from package atmfonts.zip, use conv_ado2.bat to convert) 
     utopia.zip (for fixing a simple problem look at PROBLEMS (V.1)) 
 
   *  ATTENTION - Fonts made by Corel's Wfnboss (that's a lot!):     * 
   *    To avoid trivial problems please read PROBLEMS (V.3) above.  * 
 
 
 VII. NEW VERSIONS OF ps4mf-unix.tar.gz:
          ftp.rrzn.uni-hannover.de  
          /incoming/tex

 VIII. COPYRIGHT: Please read copying.gnu.


 --------------------------------
 Please get hints and comments to

   Markus Neteler
   email: neteler@geog.uni-hannover.de