1AUTOINST(1) Marc Penninga AUTOINST(1)
2
3
4
6 autoinst - wrapper around the LCDF TypeTools, for installing and using
7 OpenType fonts in (La)TeX.
8
10 autoinst [options] fontfile(s)
11
13 Eddie Kohler's LCDF TypeTools are superb tools for installing OpenType
14 fonts in LaTeX, but they can be hard to use: they need many, often
15 long, command lines and don't generate the fd and sty files LaTeX
16 needs. autoinst simplifies the use of the TypeTools for font
17 installation by generating and executing all commands for otftotfm and
18 by creating and installing all necessary fd and sty files.
19
20 Given a family of font files (in otf or ttf format), autoinst will
21 create several LaTeX font families:
22
23 - Four text families (with lining and oldstyle digits, each in both
24 tabular and proportional variants), all with the following shapes:
25
26 n Roman (i.e., upright) text
27
28 it, sl Italic and slanted (sometimes called oblique) text
29
30 sc Small caps
31
32 sw Swash
33
34 tl Titling shape. Meant for all-caps text; letterspacing
35 and the positioning of punctuation characters have been
36 adjusted to suit all-caps text. (This shape is only
37 generated for the families with lining digits, since
38 old-style digits make no sense with all-caps text.)
39
40 scit, scsl
41 Italic and slanted small caps
42
43 nw "Upright swash"; usually roman text with a few
44 "oldstyle" ligatures like ct, sp and st.
45
46 tlit, tlsl
47 Italic and slanted titling text
48
49 - For each T1-encoded text family: a family of TS1-encoded symbol
50 fonts, in roman, italic and slanted shapes.
51
52 - Families with superiors, inferiors, numerators and denominators,
53 in roman, italic and slanted shapes.
54
55 - An ornament family, also in roman, italic and slanted shapes.
56
57 Of course, if your fonts don't contain italics, oldstyle digits, small
58 caps etc., the corresponding shapes and families are not created. In
59 addition, the creation of most families and shapes can be controlled by
60 the user (see "COMMAND-LINE OPTIONS" below).
61
62 These families use the FontPro project's naming scheme:
63 <FontFamily>-<Suffix>, where <Suffix> is:
64
65 LF proportional (i.e., figures have varying widths) lining figures
66
67 TLF tabular (i.e., all figures have the same width) lining figures
68
69 OsF proportional oldstyle figures
70
71 TOsF tabular oldstyle figures
72
73 Sup superior characters (note that most fonts have only an
74 incomplete set of superior characters: digits, some punctuation
75 and the letters abdeilmnorst; normal forms are used for other
76 characters)
77
78 Inf inferior characters; usually only digits and some punctuation,
79 normal forms for other characters
80
81 Orn ornaments
82
83 Numr numerators
84
85 Dnom denominators
86
87 The individual fonts are named <FontName>-<suffix>-<shape>-<enc>, where
88 <suffix> is the same as above (but in lowercase), <shape> is either
89 empty, "sc", "swash" or "titling", and <enc> is the encoding (also in
90 lowercase). A typical name in this scheme would be
91 "FiraSans-Light-osf-sc-ly1".
92
93 On the choice of text encoding
94 By default, autoinst generates text fonts with OT1, T1 and LY1
95 encodings, and the generated style files use LY1 as the default text
96 encoding. LY1 has been chosen over T1 because it has some empty slots
97 to accommodate the additional ligatures found in many OpenType fonts.
98 Other encodings can be chosen using the -encoding option (see "COMMAND-
99 LINE OPTIONS" below).
100
101 Using the fonts in your LaTeX documents
102 autoinst generates a style file for using the fonts in LaTeX documents,
103 named <FontFamily>.sty. This style file also takes care of loading the
104 fontenc and textcomp packages. To use the fonts, add the command
105 "\usepackage{<FontFamily>}" to the preamble of your document.
106
107 This style file defines a number of options:
108
109 "lining", "oldstyle", "tabular", "proportional"
110 Choose which figure style to use. The defaults are "oldstyle" and
111 "proportional" (if available).
112
113 "scale=<number>"
114 Scale the font by a factor of <number>. E.g., to increase the size
115 of the font by 5%, use "\usepackage[scale=1.05]{<FontFamily>}".
116 May also be spelled "scaled".
117
118 This option is only available when you have the xkeyval package
119 installed.
120
121 "light", "medium", "book", "text", "regular"
122 Select the weight that LaTeX will use as the "regular" weight; the
123 default is "regular".
124
125 "heavy", "ultrablack", "extrablack", "black", "ultrabold", "extrabold",
126 "demibold", "semibold", "bold"
127 Select the weight that LaTeX will use as the "bold" weight; the
128 default is "bold".
129
130 The previous two groups of options will only work if you have the
131 mweights package installed.
132
133 The style file will also try to load the fontaxes package (available on
134 CTAN), which gives easy access to various font shapes and styles.
135 Using the machinery set up by fontaxes, the generated style file
136 defines a number of commands (which take the text to be typeset as
137 argument) and declarations (which don't take arguments, but affect all
138 text up to the end of the current group) to access titling, superior
139 and inferior characters:
140
141 DECLARATION COMMAND SHORT FORM OF COMMAND
142
143 \tlshape \texttitling \texttl
144 \sufigures \textsuperior \textsu
145 \infigures \textinferior \textin
146
147 In addition, the "\swshape" and "\textsw" commands are redefined to
148 place swash on fontaxes' secondary shape axis (fontaxes places it on
149 the primary shape axis) to make them behave properly when nested, so
150 that "\swshape\upshape" will give upright swash.
151
152 There are no commands for accessing the numerator and denominator
153 fonts; these can be selected using fontaxes' standard commands, e.g.,
154 "\fontfigurestyle{numerator}\selectfont".
155
156 The style file also provides a command "\ornament{<number>}", where
157 "<number>" is a number from 0 to the total number of ornaments minus
158 one. Ornaments are always typeset using the current family, series and
159 shape. A list of all ornaments in a font can be created by running
160 LaTeX on the file nfssfont.tex (part of a standard LaTeX installation)
161 and supplying the name of the ornament font.
162
163 To access ornament glyphs, autoinst creates a font-specific encoding
164 file <FontFamily>_orn.enc, but only if that file doesn't yet exist in
165 the current directory. This is a deliberate feature that allows you to
166 provide your own encoding vector, e.g. if your fonts use non-standard
167 glyph names for ornaments.
168
169 These commands are only generated for existing shapes and number
170 styles; no commands are generated for shapes and styles that don't
171 exist, or whose generation was turned off by the user. Also these
172 commands are built on top of fontaxes, so if that package cannot be
173 found, you're limited to using the lower-level commands from standard
174 NFSS ("\fontfamily", "\fontseries", "\fontshape" etc.).
175
176 NFSS codes
177 NFSS identifies fonts by a combination of family, series (the
178 concatenation of weight and width), shape and size. autoinst parses
179 the output of "otfinfo --info" to determine these parameters. When this
180 fails (e.g., because the font family contains uncommon widths or
181 weights), autoinst ends up with different fonts having the same values
182 for these font parameters, and so cannot be used in NFSS. In that
183 case, autoinst will split the font family into multiple subfamilies
184 (based on each font file's "Subfamily" value) and try again. (Since
185 many font vendors misunderstand the "Subfamily" concept and make each
186 font file its own separate subfamily, this strategy is only used as a
187 last resort.)
188
189 If a proliferation of font families is unwanted, either run autoinst on
190 a smaller set of fonts or add the missing widths, weights and shapes to
191 the tables %FD_WIDTH, %FD_WEIGHT and %FD_SHAPE, at the beginning of the
192 source code. Please also send a bug report (see AUTHOR below).
193
194 autoinst maps widths, weights and shapes to NFSS codes using the
195 following tables. These are based on the standard Fontname scheme and
196 Philipp Lehman's Font Installation Guide, but some changes had to be
197 made to avoid name clashes in font families with many widths and
198 weights, such as Helvetica Neue and Fira Sans.
199
200 WEIGHT WIDTH
201 ------------------------ -------------------------------
202 Two 2 Ultra Compressed up
203 Four 4 Extra Compressed ep
204 Eight 8 Compressed p
205 Hair a Compact p
206 Thin i Ultra Condensed uc
207 Ultra Light ul Extra Condensed ec
208 Extra Light el Condensed c
209 Light l Narrow n
210 Regular - [1] Semicondensed sc
211 Text t [2] Regular - [1]
212 Book o [2] Semiextended sx
213 Medium mb Extended x
214 Demibold db Expanded e
215 Semibold sb Wide w
216 Bold b
217 Extra Bold eb SHAPE
218 Ultra (Bold) ub -------------------------------
219 Black k Roman, Upright n [3]
220 Extra Black ek Italic, Cursive,
221 Ultra Black uk Kursiv it
222 Heavy h Oblique, Slanted,
223 Poster r Incline(d) sl
224
225 [1] When both weight and width are empty, the NFSS "series" attribute
226 becomes "m".
227
228 [2] Until release 2017-06-16, "Text" and "Book" were treated as
229 synonyms for "Regular". As there are some fonts (IBM Plex, Fira
230 Sans) that contain separate "Text" or "Book" in addition to
231 "Regular" weights, I decided to give them their own codes. When
232 there is no "Regular" weight, autoinst will generate ssub rules to
233 substitute either the "Text" or the "Book" font in its place.
234
235 [3] Adobe Silentium Pro contains two roman shapes; "Roman I" is mapped
236 to "n", "Roman II" to "it".
237
238 A note for MiKTeX users
239 Automatically installing the fonts into a suitable TEXMF tree (as
240 autoinst tries to do by default) requires a TeX-installation that uses
241 the kpathsea library; with TeX distributions that implement their own
242 directory searching (such as MiKTeX), autoinst will complain that it
243 cannot find the kpsewhich program and install all generated files into
244 subdirectories of the current directory. If you use such a TeX
245 distribution, you should either move these files to their correct
246 destinations by hand, or use the -target option (see "COMMAND-LINE
247 OPTIONS" below) to specify a TEXMF tree.
248
249 Also, some OpenType fonts may lead to pl and vpl files that are too big
250 for MiKTeX's pltotf and vptovf; the versions that come with W32TeX
251 (http://www.w32tex.org) and TeXLive (http://tug.org/texlive) don't seem
252 to have this problem.
253
255 autoinst tries hard to do The Right Thing (TM) by default, so you
256 usually won't really need these options; but most aspects of its
257 operation can be fine-tuned if you want to.
258
259 You may use either one or two dashes before options, and option names
260 may be shortened to a unique prefix (e.g., -encoding may be abbreviated
261 to -enc or even -en, but -e is ambiguous (it may mean either -encoding
262 or -extra)).
263
264 -dryrun
265 Don't generate any output files; only parse the input fonts and
266 create autoinst.log showing which fonts would have been generated.
267
268 -encoding=encoding[,encoding]
269 Generate the specified encoding(s) for the text fonts. The default
270 is "OT1,T1,LY1". For each encoding, a file <encoding>.enc (in all
271 lowercase!) should be somewhere where otftotfm can find it.
272 Suitable encoding files for OT1, T1/TS1 and LY1 come with autoinst.
273 (These files are called fontools_ot1.enc etc. to avoid name clashes
274 with other packages; the "fontools_" prefix may be omitted.)
275
276 Multiple text encodings can be specified as a comma-separated list:
277 "-encoding=OT1,T1" (without spaces!). The generated style file
278 passes these encodings to fontenc in the specified order, so the
279 last one will become the default text encoding for your documents.
280
281 -ts1 / -nots1
282 Control the creation of TS1-encoded fonts. The default is -ts1 if
283 the text encodings (see -encoding above) include T1, -nots1
284 otherwise.
285
286 -sanserif
287 Install the font as a sanserif font, accessed via "\sffamily" and
288 "\textsf". The generated style file redefines "\familydefault", so
289 including it will still make this font the default text font.
290
291 -typewriter
292 Install the font as a typewriter font, accessed via "\ttfamily" and
293 "\texttt". The generated style file redefines "\familydefault", so
294 including it will still make this font the default text font.
295
296 -lining / -nolining
297 Control the creation of fonts with lining figures. The default is
298 -lining.
299
300 -oldstyle / -nooldstyle
301 Control the creation of fonts with oldstyle figures. The default is
302 -oldstyle.
303
304 -proportional / -noproportional
305 Control the creation of fonts with proportional figures. The
306 default is -proportional.
307
308 -tabular / -notabular
309 Control the creation of fonts with tabular figures. The default is
310 -tabular.
311
312 -smallcaps / -nosmallcaps
313 Control the creation of small caps fonts. The default is
314 -smallcaps.
315
316 -swash / -noswash
317 Control the creation of swash fonts. The default is -swash.
318
319 -titling / -notitling
320 Control the creation of titling fonts. The default is -titling.
321
322 -superiors / -nosuperiors
323 Control the creation of fonts with superior characters. The
324 default is -superiors.
325
326 -inferiors=[ sinf | subs | dnom ]
327 The OpenType standard defines several kinds of digits that might be
328 used as inferiors or subscripts: "Scientific Inferiors" (OpenType
329 feature "sinf"), "Subscripts" ("subs") and "Denominators" ("dnom").
330 This option allows the user to determine which of these styles
331 autoinst should use for the inferior characters. The default is not
332 to create fonts with inferior characters.
333
334 Note that many fonts contain only one (or even none) of these types
335 of inferior characters. If you specify a style of inferiors that
336 isn't actually present in the font, autoinst silently falls back to
337 its default of not creating fonts with inferiors; it doesn't try to
338 substitute one of the other features.
339
340 -fractions / -nofractions
341 Control the creation of fonts with numerators and denominators.
342 The default is -nofractions.
343
344 -ornaments / -noornaments
345 Control the creation of ornament fonts. The default is -ornaments.
346
347 -defaultlining / -defaultoldstyle
348 -defaulttabular / -defaultproportional
349 Tell autoinst which figure style is the current font family's
350 default (i.e., which figures you get when you don't specify any
351 OpenType features).
352
353 Don't use these options unless you are certain you need them! They
354 are only needed for fonts that don't provide OpenType features for
355 their default figure style; and even in that case, autoinst's
356 default values (-defaultlining and -defaulttabular) are usually
357 correct.
358
359 -nofigurekern
360 Some fonts provide kerning pairs for tabular figures. This is very
361 probably not what you want (e.g., numbers in tables won't line up
362 exactly). This option adds extra --ligkern options to the
363 commands for otftotfm to suppress such kerns. Note that this
364 option leads to very long commands (it adds one hundred --ligkern
365 options), which may cause problems on some systems.
366
367 -mergewidths / -nomergewidths
368 Some font families put Condensed and Extended fonts in separate
369 families; this option tells autoinst to merge those separate
370 families into the "main" font family. The default is
371 -nomergewidths.
372
373 -extra=text
374 Append text as extra options to the command lines for otftotfm. To
375 prevent text from accidentily being interpreted as options to
376 autoinst, it should be properly quoted.
377
378 -manual
379 Manual mode. By default, autoinst immediately executes all otftotfm
380 commands it generates; with the -manual option, these commands are
381 instead written to a file autoinst.bat. Furthermore it adds the
382 --pl option (which tells otftotfm to generate human
383 readable/editable pl and vpl files instead of the default tfm and
384 vf files) and omits the --automatic option (which causes otftotfm
385 to leave all generated files in the current directory, rather than
386 install them into your TEXMF tree). Manual mode is meant to enable
387 tweaking the generated commands and post-processing the generated
388 files.
389
390 When using this option, run pltotf and vptovf after executing the
391 commands (to convert the pl and vf files to tfm and vf format) and
392 move all generated files to their proper destinations.
393
394 All following options are only meaningful in automatic mode, and hence
395 ignored in manual mode:
396
397 -target=DIRECTORY
398 Install all generated files into the TEXMF tree at DIRECTORY. This
399 option allows the user to override autoinst's default behaviour,
400 which is to search the $TEXMFLOCAL and $TEXMFHOME paths and install
401 all files into subdirectories of the first writable TEXMF tree it
402 finds (or into subdirectories of the current directory, if no
403 writable directory is found).
404
405 -vendor=VENDOR
406 -typeface=TYPEFACE
407 These options are equivalent to otftotfm's --vendor and
408 --typeface options: they change the "vendor" and "typeface" parts
409 of the names of the subdirectories in the TEXMF tree where
410 generated files will be stored. The default values are "lcdftools"
411 and the font's FontFamily name.
412
413 Note that these options change only directory names, not the names
414 of any generated files.
415
416 -updmap / -noupdmap
417 Control whether or not updmap is called after the last call to
418 otftotfm. The default is -updmap.
419
421 Eddie Kohler's TypeTools (http://www.lcdf.org/type).
422
423 Perl can be obtained from http://www.perl.org; it is included in most
424 Linux distributions. For Windows, try ActivePerl
425 (http://www.activestate.com) or Strawberry Perl
426 (http://strawberryperl.com).
427
428 XeTeX (http://www.tug.org/xetex) and LuaTeX (http://www.luatex.org) are
429 Unicode-aware TeX engines that can use OpenType fonts directly, without
430 any (La)TeX-specific support files.
431
432 The FontPro project (https://github.com/sebschub/FontPro) offers very
433 complete LaTeX support (even for typesetting maths) for Adobe's Minion
434 Pro, Myriad Pro and Cronos Pro font families.
435
437 Marc Penninga (marcpenninga@gmail.com)
438
439 When sending a bug report, please give as much relevant information as
440 possible. If you see any error messages (either from autoinst itself,
441 from the LCDF TypeTools, from Perl or from the OS), include these
442 verbatim; don't paraphrase.
443
445 Copyright (C) 2005-2018 Marc Penninga.
446
448 This program is free software; you can redistribute it and/or modify it
449 under the terms of the GNU General Public License as published by the
450 Free Software Foundation, either version 2 of the License, or (at your
451 option) any later version. A copy of the text of the GNU General
452 Public License is included in the fontools distribution; see the file
453 GPLv2.txt.
454
456 This program is distributed in the hope that it will be useful, but
457 WITHOUT ANY WARRANTY; without even the implied warranty of
458 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
459 General Public License for more details.
460
462 (See the source for the full story, all the way back to 2005.)
463
464 2018-03-26 Added the "Text" weight and the -(no)mergewidths option.
465 Changed the NFSS codes for "Thin" and "Book" to "i" and
466 "o", respectively. Tried to improve the documentation.
467
468 2018-01-09 Added the "sl" weight for font families (such as Fira Sans)
469 that contain both "Book" and "Regular" weights (reported by
470 Bob Tennent). Added the "Two", "Four", "Eight" and "Hair"
471 weights (for Fira Sans).
472
473 2017-06-16 Changed the -inferiors option from a binary yes-or-no
474 choice to allow the user to choose one of the "sinf",
475 "subs" and "dnom" features. autoinst now always creates a
476 log file.
477
478 2017-03-21 Updated the fontools_ot1.enc encoding file to include the
479 "Lslash" and "lslash" glyphs (thanks to Bob Tennent).
480
481
482
483fontools 2018-03-26 AUTOINST(1)