summaryrefslogtreecommitdiff
path: root/fonts/utilities/fontinst
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
committerNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
commite0c6872cf40896c7be36b11dcc744620f10adf1d (patch)
tree60335e10d2f4354b0674ec22d7b53f0f8abee672 /fonts/utilities/fontinst
Initial commit
Diffstat (limited to 'fonts/utilities/fontinst')
-rw-r--r--fonts/utilities/fontinst/README114
-rw-r--r--fonts/utilities/fontinst/doc/encspecs/encspecs.tex1443
-rw-r--r--fonts/utilities/fontinst/doc/encspecs/omxdraft.etx985
-rw-r--r--fonts/utilities/fontinst/doc/encspecs/ot1draft.etx1027
-rw-r--r--fonts/utilities/fontinst/doc/encspecs/t1draft.etx1484
-rw-r--r--fonts/utilities/fontinst/doc/manual/fontinst.pdfbin0 -> 463486 bytes
-rw-r--r--fonts/utilities/fontinst/doc/manual/fontinst.tex4680
-rw-r--r--fonts/utilities/fontinst/doc/manual/intro98.pdfbin0 -> 190986 bytes
-rw-r--r--fonts/utilities/fontinst/doc/manual/intro98.tex1330
-rw-r--r--fonts/utilities/fontinst/doc/manual/roadmap.eps265
-rw-r--r--fonts/utilities/fontinst/doc/talks/et99-font-tables.pdfbin0 -> 201767 bytes
-rw-r--r--fonts/utilities/fontinst/doc/talks/et99-font-tutorial.pdfbin0 -> 242186 bytes
-rw-r--r--fonts/utilities/fontinst/examples/basic/basicex.tex431
-rw-r--r--fonts/utilities/fontinst/examples/basic/basicex2.tex50
-rw-r--r--fonts/utilities/fontinst/examples/eurofont/Makefile45
-rw-r--r--fonts/utilities/fontinst/examples/eurofont/eurofont.map12
-rw-r--r--fonts/utilities/fontinst/examples/eurofont/eurofont.tex43
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/Makefile24
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/fontptcm.tex75
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/mathtest.tex643
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/resetsy.mtx30
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/unsetmu.mtx7
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/zrhax.mtx15
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/zrmhax.mtx14
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/zrmkern.mtx158
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/zrvhax.mtx73
-rw-r--r--fonts/utilities/fontinst/examples/mathptm/zryhax.mtx26
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/Makefile23
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/fontptcmx.tex76
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/mathptmx.sty42
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/mathtestx.tex643
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/resetsy.mtx30
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/unsetmu.mtx7
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/zrhax.mtx15
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/zrmhax.mtx14
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/zrmkernx.mtx239
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/zrvhax.mtx73
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/zryhax.mtx26
-rw-r--r--fonts/utilities/fontinst/examples/mathptmx/zrykernx.mtx35
-rw-r--r--fonts/utilities/fontinst/inputs/base/bbox.sty163
-rw-r--r--fonts/utilities/fontinst/inputs/base/cfntinst.sty3688
-rw-r--r--fonts/utilities/fontinst/inputs/base/finstmsc.sty1470
-rw-r--r--fonts/utilities/fontinst/inputs/base/fontinst.ini97
-rw-r--r--fonts/utilities/fontinst/inputs/base/fontinst.sty3676
-rw-r--r--fonts/utilities/fontinst/inputs/base/multislot.sty234
-rw-r--r--fonts/utilities/fontinst/inputs/base/xfntinst.sty3775
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/8r.etx1354
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/8y.etx1305
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1.etx938
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1c.etx92
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1cj.etx69
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1ctt.etx63
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1i.etx56
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1ij.etx56
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1itt.etx70
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1j.etx52
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/ot1tt.etx66
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/t1.etx1478
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/t1c.etx63
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/t1cj.etx51
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/t1i.etx20
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/t1ij.etx20
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/t1j.etx20
-rw-r--r--fonts/utilities/fontinst/inputs/latinetx/txtfdmns.etx136
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/8r.mtx234
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/8y.mtx251
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/latin.mtx1791
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/latinsc.mtx1324
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/llbuild.mtx568
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/lsbuild.mtx260
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/lsfake.mtx359
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/lsmisc.mtx194
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/ltcmds.mtx305
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/ltpunct.mtx247
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/lubuild.mtx656
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/newlatin.mtx190
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/resetsc.mtx166
-rw-r--r--fonts/utilities/fontinst/inputs/latinmtx/unsetalf.mtx114
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/euex.etx164
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/eufrak.etx238
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/eurm.etx239
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/euscr.etx171
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/msam.etx636
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/msbm.etx619
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/oml.etx627
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/oms.etx678
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/omx.etx731
-rw-r--r--fonts/utilities/fontinst/inputs/mathetx/rsfs.etx92
-rw-r--r--fonts/utilities/fontinst/inputs/mathmtx/mathex.mtx303
-rw-r--r--fonts/utilities/fontinst/inputs/mathmtx/mathit.mtx280
-rw-r--r--fonts/utilities/fontinst/inputs/mathmtx/mathsy.mtx313
-rw-r--r--fonts/utilities/fontinst/inputs/misc/csc2x.tex118
-rw-r--r--fonts/utilities/fontinst/inputs/misc/csckrn2x.tex121
-rw-r--r--fonts/utilities/fontinst/inputs/misc/glyphbox.mtx62
-rw-r--r--fonts/utilities/fontinst/inputs/misc/glyphoff.mtx8
-rw-r--r--fonts/utilities/fontinst/inputs/misc/glyphon.mtx7
-rw-r--r--fonts/utilities/fontinst/inputs/misc/kernoff.mtx6
-rw-r--r--fonts/utilities/fontinst/inputs/misc/kernon.mtx6
-rw-r--r--fonts/utilities/fontinst/inputs/misc/osf2x.tex37
-rw-r--r--fonts/utilities/fontinst/inputs/smbletx/digit2.etx10
-rw-r--r--fonts/utilities/fontinst/inputs/smbletx/ts1.etx764
-rw-r--r--fonts/utilities/fontinst/inputs/smbletx/ts1i.etx7
-rw-r--r--fonts/utilities/fontinst/inputs/smbletx/ts1ij.etx7
-rw-r--r--fonts/utilities/fontinst/inputs/smbletx/ts1j.etx7
-rw-r--r--fonts/utilities/fontinst/inputs/smblmtx/resetosf.mtx88
-rw-r--r--fonts/utilities/fontinst/inputs/smblmtx/textcomp.mtx561
-rw-r--r--fonts/utilities/fontinst/inputs/smblmtx/unsetnum.mtx62
-rw-r--r--fonts/utilities/fontinst/latex/fontdoc.sty1390
-rw-r--r--fonts/utilities/fontinst/source/CHANGES648
-rw-r--r--fonts/utilities/fontinst/source/fibasics.dtx2345
-rw-r--r--fonts/utilities/fontinst/source/ficommon.dtx2416
-rw-r--r--fonts/utilities/fontinst/source/ficonv.dtx3169
-rw-r--r--fonts/utilities/fontinst/source/filtfam.dtx1187
-rw-r--r--fonts/utilities/fontinst/source/fimain.dtx4965
-rw-r--r--fonts/utilities/fontinst/source/fimapgen.dtx1607
-rw-r--r--fonts/utilities/fontinst/source/fisource.dvibin0 -> 1147220 bytes
-rw-r--r--fonts/utilities/fontinst/source/fisource.ist47
-rw-r--r--fonts/utilities/fontinst/source/fisource.sty691
-rw-r--r--fonts/utilities/fontinst/source/fisource.tex3037
-rw-r--r--fonts/utilities/fontinst/source/fitrig.dtx326
-rw-r--r--fonts/utilities/fontinst/source/fontinst.ins135
-rw-r--r--fonts/utilities/fontinst/test/cc-pl.enc258
-rw-r--r--fonts/utilities/fontinst/test/comparemetrics.sty941
-rw-r--r--fonts/utilities/fontinst/test/comparepls.tex73
-rw-r--r--fonts/utilities/fontinst/test/fadrr.mtx51
-rw-r--r--fonts/utilities/fontinst/test/multislot-test.tex16
-rw-r--r--fonts/utilities/fontinst/test/multislot.etx54
-rw-r--r--fonts/utilities/fontinst/test/omsdraft.etx871
-rw-r--r--fonts/utilities/fontinst/test/testsc.tex41
-rw-r--r--fonts/utilities/fontinst/test/v1901test.mtx22
-rw-r--r--fonts/utilities/fontinst/test/v1901test.tex214
-rw-r--r--fonts/utilities/fontinst/test/v1902test.tex11
-rw-r--r--fonts/utilities/fontinst/test/v1905test.tex22
-rw-r--r--fonts/utilities/fontinst/test/v1906test.etx128
-rw-r--r--fonts/utilities/fontinst/test/v1906test.mtx64
-rw-r--r--fonts/utilities/fontinst/test/v1906test.tex12
-rw-r--r--fonts/utilities/fontinst/test/v1913test.tex21
-rw-r--r--fonts/utilities/fontinst/test/v1914test.tex50
-rw-r--r--fonts/utilities/fontinst/test/v1914testmap.tex17
-rw-r--r--fonts/utilities/fontinst/test/v1914testshow.tex22
-rw-r--r--fonts/utilities/fontinst/test/v1915test.tex25
-rw-r--r--fonts/utilities/fontinst/test/v1915testmap.tex9
-rw-r--r--fonts/utilities/fontinst/test/v1916test.mtx23
-rw-r--r--fonts/utilities/fontinst/test/v1916test.tex14
-rw-r--r--fonts/utilities/fontinst/test/v1916test2.tex27
-rw-r--r--fonts/utilities/fontinst/test/v1923test.tex47
-rw-r--r--fonts/utilities/fontinst/test/v1927test.tex18
-rw-r--r--fonts/utilities/fontinst/test/v1928test.tex13
-rw-r--r--fonts/utilities/fontinst/test/v1928test2.tex32
-rw-r--r--fonts/utilities/fontinst/test/v1930test.tex16
-rw-r--r--fonts/utilities/fontinst/test/v1931test0.tex8
-rw-r--r--fonts/utilities/fontinst/test/v1931test1.tex50
-rw-r--r--fonts/utilities/fontinst/test/v1931test2.tex35
153 files changed, 71998 insertions, 0 deletions
diff --git a/fonts/utilities/fontinst/README b/fonts/utilities/fontinst/README
new file mode 100644
index 0000000000..b6a30ea506
--- /dev/null
+++ b/fonts/utilities/fontinst/README
@@ -0,0 +1,114 @@
+README for fontinst
+
+* What is it?
+
+Fontinst is a program that helps with installing fonts
+for (La)TeX. Since it is written entirely in TeX macros,
+it is completely portable.
+
+More precisely, fontinst helps mainly with the number
+crunching and shoveling parts of font installation. This
+means in practice that it creates a number of files which
+give the TeX metrics (and related information) for a font
+family that (La)TeX needs to do any typesetting in these
+fonts. Fontinst furthermore makes it easy to create fonts
+containing glyphs from more than one base font, taking
+advantage of e.g. "expert" font sets.
+
+Fontinst cannot examine files to see if they contain any
+useful information or work with binary file formats; those
+tasks must normally be done manually or with the help of
+some other tool, such as the pltotf and vptovf programs.
+Nor can fontinst automatically search for files, but if
+they are named according to the fontname scheme (Berry)
+then fontinst sometimes succeeds very well in guessing
+what the interesting files are called.
+
+
+* Documentation
+
+The doc directory contains pure documentation; in
+particular the doc/manual directory should be of
+interest, as it contains the fontinst manual. For questions
+about the meaning of fontinst commands, see this manual.
+
+The manual is however not a tutorial on how to use fontinst.
+Some alternative sources of information that you may find
+useful are:
+
+ * Philipp Lehman's "The Font Installation Guide"
+ Available on CTAN, at info/Type1fonts/fontinstallationguide/
+
+ * intro98.tex - parts of the 1998 fontinst v1.8 manual
+ that were split off during the v1.9 revision. These are
+ much more tutorial in style, although not entirely modern.
+
+ * The fontinst mailing list and its archives
+ (See below for relevant addresses.)
+
+ * The fontinst Literate Programming sources (see
+ source/fisource.dvi). If a command isn't documented
+ anywhere else, there is probably a discussion of it
+ in the sources. They're thoroughly indexed.
+
+The examples directory contains some examples (with
+comments) of using fontinst to install a font family.
+
+
+* Installation
+
+To use fontinst, you only need to make sure the inputs
+directory and its subdirectories are on TeX's input path.
+Usually you do this by moving it to a suitable location.
+In a TDS texmf tree, the inputs directory is usually
+made the ${TEXMF}/tex/fontinst directory.
+
+You will probably also want to move the file fontdoc.sty
+in the latex directory to some location where TeX will
+find it. Many of the .mtx and .etx files in the inputs
+hierarchy are simultaneously fontinst input files and
+LaTeX documents; the fontdoc package is needed to typeset
+them as the latter. In a TDS texmf tree, the normal place
+for fontdoc.sty is in the tex/latex/misc directory.
+
+Also recall that some TeX implementations maintain a
+database over files that have been installed. If you've
+placed fontinst in a suitable place but TeX complains it
+cannot find the file fontinst.sty then the problem may
+be that you need to update this database of files. That
+is however nothing that is particular for fontinst.
+
+
+* Latin and other scripts
+
+The fontinst distribution includes the necessary encoding
+definition (.etx) files for the latin script as used in
+European languages, but there is nothing in fontinst as
+a program that restricts it to these languages. In the T2
+bundle (CTAN:macros/latex/contrib/t2) there are
+corresponding fontinst files for the cyrillic scripts
+(and in the future it might become part of the main
+fontinst distribution).
+
+
+* The test directory
+
+This is mainly of interest for advanced fontinst users.
+It collects some files that were written to test the new
+features in various versions of fontinst.
+
+
+* Mailing list
+
+Questions and bug reports should be sent to the fontinst
+mailing list
+
+ fontinst@tug.org
+
+General information about the mailing list is at:
+
+ http://tug.org/mailman/listinfo/fontinst
+
+
+22 August 2009,
+Lars Hellstr\"om
diff --git a/fonts/utilities/fontinst/doc/encspecs/encspecs.tex b/fonts/utilities/fontinst/doc/encspecs/encspecs.tex
new file mode 100644
index 0000000000..a23be98dd2
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/encspecs/encspecs.tex
@@ -0,0 +1,1443 @@
+\documentclass[a4paper]{article}
+
+\usepackage{array}
+
+\makeatletter
+\@ifundefined{l@nohyphenation}{\newlanguage\l@nohyphenation}{}
+\DeclareRobustCommand\meta[1]{%
+ \ensuremath{\langle}%
+ \sbox{\z@}{%
+ \setlanguage\l@nohyphenation
+ \normalfont\itshape #1\/%
+ \setlanguage\language
+ }%
+ \unhbox\z@
+ \ensuremath{\rangle}%
+}
+\makeatother
+\DeclareRobustCommand\marg[1]{%
+ \texttt{\char`\{}\meta{#1}\texttt{\char`\}}%
+}
+\DeclareRobustCommand\cs[1]{\texttt{\char`\\#1}}
+
+\makeatletter
+\DeclareTextFontCommand\textsmaller{%
+ \fontsize{\scaledsize{\f@size}}{\f@baselineskip}\selectfont
+}
+\newcommand\scaledsize[1]{%
+ \ifdim #1\p@>6\p@
+ \ifdim #1\p@>7\p@
+ \ifdim #1\p@>8\p@
+ \ifdim #1\p@>9\p@
+ \ifdim #1\p@>10\p@
+ \ifdim #1\p@>11\p@
+ \ifdim #1\p@>12\p@
+ \ifdim #1\p@>14\p@ 14%
+ \else 12\fi
+ \else 11\fi
+ \else 10\fi
+ \else 9\fi
+ \else 8\fi
+ \else 7\fi
+ \else 6\fi
+ \else 5\fi
+}
+\makeatother
+\DeclareRobustCommand\ETX{\textsmaller{ETX}}
+\DeclareRobustCommand\PDF{\textsmaller{PDF}}
+
+% From tugboat.cls
+\def\thinskip{\hskip 0.16667em\relax}
+\def\endash{--}
+\def\emdash{\endash-}
+\makeatletter
+\def\d@sh#1#2{\unskip#1\thinskip#2\thinskip\ignorespaces}
+\def\dash{\d@sh\nobreak\endash}
+\def\Dash{\d@sh\nobreak\emdash}
+\def\ldash{\d@sh\empty{\hbox{\endash}\nobreak}}
+\def\rdash{\d@sh\nobreak\endash}
+\def\Ldash{\d@sh\empty{\hbox{\emdash}\nobreak}}
+\def\Rdash{\d@sh\nobreak\emdash}
+\newcommand{\La}%
+ {L\kern-.36em
+ {\setbox0\hbox{T}%
+ \vbox to\ht0{\hbox{$\m@th$%
+ \csname S@\f@size\endcsname
+ \fontsize\sf@size\z@
+ \math@fontsfalse\selectfont
+ A}%
+ \vss}%
+ }}
+\IfFileExists{mflogo.sty}%
+ {\RequirePackage{mflogo}}%
+ {\TBWarning
+ {Package mflogo.sty not available --\MessageBreak
+ Proceeding to emulate mflogo.sty}
+ \DeclareRobustCommand\logofamily{%
+ \not@math@alphabet\logofamily\relax
+ \fontencoding{U}\fontfamily{logo}\selectfont}
+ \DeclareTextFontCommand{\textlogo}{\logofamily}
+ \def\MF{\textlogo{META}\-\textlogo{FONT}\@}
+ \def\MP{\textlogo{META}\-\textlogo{POST}\@}
+ \DeclareFontFamily{U}{logo}{}
+ \DeclareFontShape{U}{logo}{m}{n}{%
+ <8><9>gen*logo%
+ <10><10.95><12><14.4><17.28><20.74><24.88>logo10%
+ }{}
+ \DeclareFontShape{U}{logo}{m}{sl}{%
+ <8><9>gen*logosl%
+ <10><10.95><12><14.4><17.28><20.74><24.88>logosl10%
+ }{}
+ \DeclareFontShape{U}{logo}{m}{it}{%
+ <->ssub*logo/m/sl%
+ }{}%
+ }
+\makeatother
+\def\AllTeX{(\La\kern-.075em)\kern-.075em\TeX}
+
+\usepackage{shortvrb}
+\MakeShortVerb{\|}
+\DeclareRobustCommand\cs[1]{\texttt{\char`\\#1}}
+
+\newcommand{\TeXOmega}{Omega}
+\DeclareRobustCommand\eTeX{\ensuremath{\varepsilon}-\kern-.125em\TeX}
+\DeclareRobustCommand\package[1]{\textsf{#1}}
+
+\providecommand*{\href}[2]{#2}
+\newcommand*{\ctanref}[2]{\href{ftp://ftp.ctan.org/#1}{#2}}
+
+\title{Writing \ETX\ format font encoding specifications}
+\author{Lars Hellstr\"om}
+\date{2003/07/09}
+
+\begin{document}
+\maketitle
+
+\begin{abstract}
+ This paper explains how one writes formal specifications of font
+ encodings for \LaTeX\ and suggests a ratification procedure for such
+ specifications.
+\end{abstract}
+
+
+\tableofcontents
+
+\vspace{0mm plus 35mm}
+\pagebreak[2]
+
+
+\section{Introduction}
+
+One of the many difficult problems any creator of a new typesetting
+system encounters is that of \emph{font construction}\Dash to create
+fonts that provide all information that the typesetting system needs
+to do its job. From the early history of \TeX, we learn that this
+problem is so significant that it motivated the creation of \TeX's
+companion and equal \MF, whose implementation proved to be an even
+greater scientific challenge than \TeX\ was. It is also a tell-tale
+sign that the \texttt{fonts} subtree of the te\TeX\ distribution is
+about three times as large as the \texttt{tex} subtree: fonts are
+important, and not at all trivial to generate.
+
+The most respected and celebrated part of font construction is
+\emph{font design}\Ldash the creation from practically nothing of new
+letter (and symbol) shapes, in pursuit of an artistic
+vision\Dash but it is also something very few people have the time
+and skill to carry through. More common is the task of \emph{font
+installation}, where one has to solve the very concrete problem of how
+to set up an existing font so that it can be used with \AllTeX. The
+subproblems in this domain ranges from the very technical\Ldash how
+to make different pieces of software ``talk'' to each other, for
+example making information in file format~$A$ available to
+program~$B$\Dash to the almost artistic\Ldash finding values for
+glyph metrics and kerns that will make them look good in text\Dash
+but these extremes tend to be clearly defined even if solving them
+can be hard, so they are not what will be considered here. Rather,
+this paper is about a class of more subtle problems that have to do
+with how a font is organised.
+
+The technical name for such a ``font organisation'' is a \emph{font
+encoding}. In some contexts, font encodings are assumed to be mere
+mappings from a set of ``slots'' to a set of glyph identifiers, but
+in \TeX\ the concept entails much more; the various aspects are
+detailed in subsequent sections. For the moment, it is sufficient to
+observe that the role that a font encoding plays in a typesetting
+system is that of a standard: it describes what an author can expect
+from a font, so that a document or macro package can be written that
+work with a large class of fonts rather than just for one font family.
+The world of \AllTeX\ would be very different if papers published in
+journal $X$ that is printed in commercial font $Y$ could not use
+essentially the same sources as the author prepared for typesetting
+in the free font $Z$. Fine-tuning of a document (overfull lines, bad
+page breaks, etc.\@) depends on the exact font used, but it is a great
+convenience that one can typeset a well-coded body of text under a
+rather wide range of layout parameter (of which the main font family
+is one) values and still expect the result to look decent, often even
+good. Had font encodings not been standardised, the results might not
+even have been readable.
+
+When font encodings are viewed as standards, the historical states of
+most \AllTeX\ font encodings becomes rather embarrassing, as they
+lack something as fundamental as proper specifications! The typical
+origin of a font encoding has been that some\-one creates a font that
+behaves noticably different from other fonts, macro packages are then
+created to support this new font, and in time other people create other
+fonts that work with the same macros. At the end of this story the new
+encoding exists, but it is not clear who created it, and there is
+probably no document that describes all aspects of the encoding. Later
+contributors have typically had to rely on a combination of imitation
+of previous works, folklore, and reverse engineering of existing
+software when trying to figure out what they need to provide, but the
+results are not always verifiable. Furthermore the errors in this area
+are usually silent\Ldash the classical error being that a `\textdollar'
+was substituted for a `\textsterling' (or vice versa)\Dash which means
+they can only be discovered through careful proofreading, and then
+only \emph{provided} there at all exists a document which exercises
+all aspects of the font encoding. Since font encodings interact with
+hyphenation, exhaustive font verification through proofreading is
+probably beyond the capabilities of any living \TeX pert on purely
+linguistic grounds.
+
+Proper specifications of font encodings makes the task of font
+installation\Ldash and to some extent also the task of font design,
+as it too is subject to the technicalities of font encodings\Dash
+much simpler, as there is then a document that authoratively gives
+all details of a font encoding. This paper even goes one step further,
+and proposes (i)~a standard format for formal specifications of
+\AllTeX\ font encodings and (ii)~a process through which such
+specifications can be ratified as \emph{the} specification of a
+particular encoding. My hope is that future \AllTeX\ font encodings
+will have proper specifications from the start, as this will greatly
+simplify making more fonts available in these encodings, and perhaps
+also make font designers aware of the subtler points of \AllTeX\ font
+design, as many details have been poorly documented.
+
+The proposed file format for encoding specifications is a development
+of the \textsf{fontinst}~\cite{fontinst-pre} \ETX\ format. One reason
+for this choice was that it is an established format; many of those
+who are making fonts already use it, even if for a slightly
+different purpose. Another major reason is that an \ETX\ file is both
+a \LaTeX\ document and a processable data file; this is the same kind
+of bilinguality that has made the \texttt{.dtx} format so useful.
+Finally the \ETX\ format makes it easy to create experimental font
+installations when a new encoding is being designed; \textsf{fontinst}
+can directly read the file, but the file can also be automatically
+converted to a PostScript encoding vector if that approach seems more
+convenient.
+On the other hand, there are some features\Ldash most notably the
+prominent role of the glyph names\Dash of the \ETX\ format that would
+probably had been done differently in a file format that was built
+from scratch, but this is necessary for several of the advantages
+listed above.
+
+
+% \paragraph*{Why should one make formal specifications?}
+% Because the informal specifications that we have today
+% are incomplete and hard to use. E.g.\ the \LaTeX\
+% \meta{enc}\texttt{enc.def} files only say something about the
+% characters that are accessed via commands, and even for those you
+% really have to do reverse engineering to figure out what the
+% encoding contains. To figure out what the remaining characters
+% should do you have to compile what the various user manuals claim
+% to work and then work backwards from that, but I don't think the
+% general problem of which character tokens are allowed in input is
+% thoroughly treated anywhere. On top of that, \LaTeX\ itself
+% contributes some character tokens when the document is being
+% typeset.\footnote{This is basically the ``a \texttt{T}$*$ encoding
+% must contain the characters \ldots'' problem that was the reason
+% that the \texttt{T2} encoding had to be split up.}
+%
+% On the other side of things there are the files which tell e.g.
+% \textsf{fontinst} or \textsf{AFMtoTFM} what the target font
+% encoding is. These are basically recipes which are known (?\@) to
+% produce valid results, and they do usually provide more
+% information about the encoding than the sources listed above, but
+% they don't give much information about where the recipe can be
+% modified.
+
+% \paragraph*{Why use the \ETX\ format?}
+
+
+\section{Points to keep in mind}
+
+\subsection{Characters, glyphs, and slots}
+
+One fundamental difference one must understand is that between
+characters and glyphs. A \emph{character} is a semantic entity---it
+carries some meaning, even if you usually have to combine several
+characters to make up even one word---whereas a \emph{glyph} simply
+is a piece of graphics. In printed text, glyphs are used to represent
+characters and the first step of reading is to determine which
+character(s) a given glyph is representing.\footnote{Some \PDF\ viewers
+also try to accomplish this, but in general they need extra
+information to do it right. The generic solution provided is to embed
+a \emph{ToUnicode CMap}\Ldash which is precisely a map from slots to
+characters\Rdash in the \PDF\ font object.}
+
+In the output, \TeX\ neither deals with characters nor glyphs, really
+(although many of its messages speak of characters), but with
+\emph{slots}, which essentially are numbered positions in a font. To
+\TeX, a slot is simply something which can have certain metric
+properties (width, height, depth, etc.\@) but to the driver which
+actually does the printing the slot also specifies a glyph. The same
+slot in two different fonts can correspond to two quite different
+characters.
+
+For completeness it should also be mentioned that the \emph{input} of
+\TeX\ is a stream of semantic entities and thus \TeX\ is dealing with
+characters on that side, but the input is not the subject of this
+paper.
+
+
+\subsection{Ligatures}
+
+In typography, a \emph{ligature} is a glyph which has been formed by
+joining glyphs that represent two or more characters; this joining can
+involve quite a lot of deformation of the original shapes. Examples
+of ligatures are the `fi' ligature (from `f' and `i'), the `\AE'
+ligature (from `A' and `E'), and the `\textit{\&}' character (from `E'
+and `t'), the latter two of which has evolved to become characters of
+their own. For those ligatures (such as `fi') that have not evolved to
+characters, \TeX\ has a mechanism for forming the ligature out of the
+characters it is composed from, under the guidance of ligature\slash
+kerning programs found in the font.
+
+More technically, what happens is really that if the |\char| (or
+equivalent) for one slot is immediately followed by the |\char| (or
+equivalent) for another (or the same) slot and there is a ligaturing
+instruction in the \texttt{\small LIGKERN} table of the current font
+which applies to this slot pair then this ligaturing instruction is
+executed. This usually replaces the two slots in the pair with a
+single new slot specified by the ligaturing instruction (it could
+also keep one or both of the original slots, but that is less common).
+\TeX\ has no idea about whether these replacements change the meaning
+of anything, but \TeX\ assumes that it doesn't, and it is up to the
+font designer to ensure that this is the case.
+
+Apart from forming ligatures in text, the ligaturing mechanism of
+\TeX\ is traditionally also employed for another task which is much
+more problematic. Ligatures are also used to produce certain
+characters which are not part of visible ASCII---the most common are
+the endash (typed as |--|) and the emdash (typed as |---|). This is a
+problem because it violates \TeX's assumption that the meaning is
+unchanged; the classical problem with this appears in the \texttt{OT2}
+encoding, where the Unicode character \texttt{U+0446}
+(\textsc{cyrillic small letter tse}) could be typed as |ts|, whilst
+the |t| and |s| by themselves produced Unicode characters
+\texttt{U+0442} (\textsc{cyrillic small letter te}) and \texttt{U+0441}
+(\textsc{cyrillic small letter es}) respectively. \TeX's hyphenation
+mechanism can however decompose ligatures, so it sometimes happened
+that the \textsc{tse} was hyphenated as \textsc{te}-\textsc{es},
+which is quite different from what was intended. Since this is such
+an obvious disadvantage, the use of ligatures for forming non-English
+letters quickly disappeared after 8-bit input encodings became
+available. The practice still remains in use for punctuation, however,
+and the font designer must be aware of this. For many font encodings
+there is a set of ligatures which must be present and replace two or
+more characters by a single, different character. These ligatures are
+called \emph{mandatory ligatures} in this paper.
+
+The use of mandatory ligatures in new font encodings is strongly
+discouraged, for a number of reasons. The main problem is that they
+create unhealthy dependencies between input and output encoding,
+whereas these should ideally be totally independent. Using ligatures
+in this way complicates the internal representation of text, and it
+also makes it much harder to typeset text where those ligatures are not
+wanted (such as verbatim text). Furthermore it creates problems with
+kerning, since the ``ligature'' has not yet been formed when a kern
+to the left of it is inserted. Finally, a much better solution (when
+it is available) is to use an \TeXOmega\ translation process
+(see~\cite[Sec.~8--11]{Omega-doc}), since that \emph{is} independent
+of the font, different translations can be combined, and they can
+easily handle even ``abbreviations'' much more complicated than those
+ligatures can deal with.
+
+
+\subsection{Output stages}
+
+On its way out of \LaTeX\ towards the printed text, a character passes
+through a number of stages. The following five seem to cover what is
+relevant for the present discussion:
+\begin{enumerate}
+ \item \emph{\LaTeX\ Internal Character Representation} (LICR);
+ see~\cite{LaTeXCompanion}, Section~7.11 for a full description.
+ At this point the character is a character token (e.g.~|a|),
+ a text command (e.g.~|\ss|), or a combination (e.g.~|\H{o}|).
+ \item \emph{Horizontal material;} this is what the character is
+ en route from \TeX's mouth to its stomach. For most characters
+ this is equivalent to a single |\char| command (e.g.\ |a| is
+ equivalent to |\char|\,|97|), but some require more than one, some
+ are combined using the |\accent| and |\char| commands, some
+ involve rules and\slash or kerns, and some are built using boxes
+ that arbitrarily combine the above elements.
+ \item \emph{DVI commands;} this is the DVI file commands that
+ produce the printed representation of the character.
+ \item \emph{Printed text;} this is the graphical representation of
+ the character, e.g. as ink on paper or as a pattern on a computer
+ screen. Here the text consists of glyphs.
+ \item \emph{Interpreted text;} this is essentially printed text
+ modulo equivalence of interpretation, hence the text doesn't really
+ reach this stage until someone reads it. Here the text consists of
+ characters.
+\end{enumerate}
+
+In theory there is a universal mapping from LICR to interpreted text,
+but various technical restrictions make it impossible to simultaneously
+support the entire mapping. A \LaTeX\ encoding selects a restriction
+of this mapping to a limited set which will be ``well supported''
+(meaning kerning and such between characters in the set works), whereas
+elements outside this set at best can be supported through temporary
+encoding changes. The encoding also specifies a decomposition of the
+mapping into one part which maps LICR to horizontal material and one
+part which maps horizontal material to interpreted text. The first
+part is realized by the text command definitions usually found in the
+\meta{enc}\texttt{enc.def} file for the encoding. The second part is
+the font encoding, the specification of which is the topic of this
+paper. It is also worth noticing that an actual font is a mapping of
+horizontal material to printed text.
+
+An alternative decomposition of the mapping from LICR to interpreted
+text would be at the DVI command level, but even though this
+decomposition is realized in most \TeX\ implementations, it has very
+little relevance for the discussion of encodings. The main reason for
+this is that it depends not only on the encoding of a font, but
+also on its metrics. Furthermore it is worth noticing that in e.g.\
+pdf\TeX\ there need not be a DVI command level.
+
+
+\subsection{Hyphenation}
+
+There are strong connections between font encoding and hyphenation because
+\TeX's hyphenation mechanism operates on horizontal material; more
+precisely the hyphenation mechanism only works on pieces of horizontal
+material that are equivalent to sequences of |\char| commands. This
+implies that hyphenation patterns, as selected via the |\language|
+parameter, are not only for a specific language, they are also for a
+specific font encoding.
+
+The hyphenation mechanism uses the |\lccode| values to distinguish
+between three types of slots: lower case letters (|\lccode|\(\,n =
+n\)), upper case letters (|\lccode|\(\,n \notin \{0,n\}\)), and
+non-letters (|\lccode|\(\,n = 0\)); only the first two types can be
+part of a hyphenatable word and only lower case letters are needed
+in the hyphenation patters. This does however place severe
+restrictions on how letters can be placed in a text font because
+\TeX\ uses the same |\lccode| values for all text in a paragraph and
+therefore these values cannot be changed whenever the encoding changes.
+In \LaTeX\ the |\lccode| table is not allowed to change at all and
+consequently all text font encodings must work using the standard set
+of |\lccode| values.
+
+In \eTeX\ each set of hyphenation patterns has its own set of
+|\lccode| values for hyphenation, so the problem isn't as severe
+there. The hyphenation mechanism of \TeXOmega\ should become
+completely independent of the font encoding, although the last time I
+checked it was still operating on material encoded according to
+a font encoding.
+
+
+\subsection{Production and specification \ETX\ files}
+
+Finally, it is worth pointing out the difference between an \ETX\ file
+created for the specification of a font encoding and one created for
+being used in actually producing fonts with this encoding. They are
+usually not the same. Specification \ETX s certainly may be of direct
+use in the production of fonts---especially experimental fonts
+produced as part of the work on a new encoding---but they are usually
+not ideal for the purpose. In particular there is often a need to
+switch between alternative names for a glyph to accommodate what is
+actually in the fonts, but such trickeries are undesirable
+complications in a specification. On the other hand a production
+\ETX\ file has little need for verbose comments, whereas they are rather
+an advantage in a specification \ETX\ file.
+
+Therefore one shouldn't be surprised if there are two \ETX\ files for a
+specific encoding: one which is a specification version and one which
+is a production version. If both might need to be in the same
+directory then one should, as a rule of thumb, include a
+`\texttt{spec}' in the name of the specification version.
+
+
+\section{Font encoding specifications}
+\label{Sec:FontEncSpec}
+
+\subsection{Basic principles}
+
+Most features of the font encoding are categorized as either
+\emph{mandatory} or \emph{ordinary}. The mandatory features are what
+macros may rely on, whereas the ordinary simply are something which
+fonts with this encoding normally provide. Font designers may choose
+to provide other features than the ordinary, but are recommended to
+provide the ordinary features to the extent that the available
+resources permit.
+
+Many internal references in the specification are in the form of
+\emph{glyph names} and the choice of these is a slightly tricky
+matter. From the point of formal specification, the choices can be
+completely arbitrary, but from the point of practical usefulness they
+most likely are not. One of the main advantages of the \ETX\ format
+for specifications is that such specifications can also be used to
+make experimental implementations, but this requires that the glyph
+names in the specification are the same as those used in the fonts
+from which the experimental implementation should be built. Yet
+another aspect is that the glyph names are best chosen to be the ones
+one can expect to find in actual fonts, as that will make things
+easier for other people that want to make non-experimental
+implementations later. For this last purpose, a good reference is
+Adobe's technical note on Unicode and glyph names~\cite{unicodesign}.
+For most common glyphs, \cite{unicodesign} ends up recommending that
+one should follow the Adobe glyph list~\cite{AGL}, which however has
+the peculiar trait of recommending names on the form
+\texttt{afii}\textit{ddddd} (rather than the Unicode-based alternative
+\texttt{uni}\textit{xxxx}) for most non-latin glyphs. This is somewhat
+put in perspective by~\cite{ATN5013}.
+
+
+\subsection{Slot assignments}
+
+The purpose of the slot assignments is to specify for each slot which
+character or characters it is mapped to. That one slot is mapped to
+many characters is an unfortunate, but not very uncommon, reality in
+many encodings, as limitations in font size have often encouraged
+identifications of two characters which are almost the same. It should
+be avoided in new encodings.
+
+Slot assignmets are done using the |\nextslot| command and a
+|\setslot| \dots\ |\endsetslot| construction as follows:
+\begin{quote}
+ |\nextslot|\marg{slot number}\\*
+ |\setslot|\marg{glyph name}\\*
+ \mbox{\quad}\meta{slot commands}\\*
+ |\endsetslot|
+\end{quote}
+A typical example of this is
+\begin{quote}\begin{verbatim}
+\nextslot{65}
+\setslot{A}
+ \Unicode{0041}{LATIN CAPITAL LETTER A}
+\endsetslot
+\end{verbatim}\end{quote}
+which gets typeset as
+\begin{quote}
+ \textbf{Slot 65 `\texttt{A}'}\\*
+ Unicode character \texttt{U+0041}, \textsc{latin capital letter a}.
+\end{quote}
+
+The |\nextslot| command does not typeset anything; it simply stores
+the slot number in a counter, for later use by |\setslot|. The
+|\endsetslot| command increments this counter by one. Hence the
+|\nextslot| command is unnecessary between |\setslot|s for consecutive
+slots. Besides |\nextslot|, there is also a command |\skipslots| which
+increments the slot number counter by a specified amount. The
+argument of both |\nextslot| and |\skipslots| can be arbitrary
+\package{fontinst} integer expressions (see~\cite{fontinst-man}). All
+\TeX\ \meta{number}s that survive full expansion are valid
+\package{fontinst} integer expressions, but for example |`\~| isn't,
+as |\~| is a macro which will break before the expression is typeset.
+These cases can however be fixed by preceding the \TeX\ \meta{number}
+by |\number|, as |\number`\~| survives full expansion by expanding to
+|126|.
+
+The main duty of the \meta{slot commands} is to specify the target
+character (or characters) for this slot. The simplest way of doing
+this is to use the |\Unicode| command, which has the syntax
+\begin{quote}
+ |\Unicode|\marg{code point}\marg{name}
+\end{quote}
+The \meta{code point} is the number of the character (in hexadecimal
+notation, usually a four-digit number) and the \meta{name} is the name.
+Case is insignificant in these arguments. If a slot corresponds to a
+string of characters rather than to a single character, then one uses
+the |\charseq| command, which has the syntax
+\begin{quote}
+ |\charseq|\marg{\cs{Unicode} commands}
+\end{quote}
+e.g.
+\begin{quote}\begin{verbatim}
+\nextslot{30}
+\setslot{ffi}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0069}{LATIN SMALL LETTER I}
+ }
+\endsetslot
+\end{verbatim}\end{quote}
+Several |\Unicode| commands not in the argument of a |\charseq|
+instead mean that each of the listed characters is a valid
+interpretation of the slot.
+
+If a character cannot be specified in terms of Unicode code points then
+the specification should simply be a description in text which
+identifies the character. Such descriptions are written using the
+|\comment| command
+\begin{quote}
+ |\comment|\marg{text}
+\end{quote}
+It is worth noticing that the \meta{text} is technically only an
+argument of |\comment| when the program processing the \ETX\ file is
+ignoring |\comment| commands. This means |\verb| and similar
+catcode-changing commands \emph{can} be used in the \meta{text}. The
+|\par| command is on the other hand not allowed in the \meta{text}.
+
+The |\comment| command should also be used for any further piece of
+explanation of or commentary to the character used for the slot, if the
+exposition seems to need it. There can be any number of |\comment|
+commands in the \meta{slot commands}.
+
+
+\subsection{Ligatures}
+
+There are three classes of ligatures in the font encoding
+specifications: mandatory, ordinary, and odd. Mandatory ligatures must
+be present in any font which complies with the encoding, whereas
+ordinary and odd ligatures need not be. No clear distinction can be
+made between ordinary and odd ligatures, but a non-mandatory ligature
+should be categorized as ordinary if it makes sense for the majority
+of users, and as odd otherwise. Hence the `fi' ligature is
+categorized as ordinary in the \texttt{T1} encoding (although it
+makes no sense in Turkish), whereas the `ij' ligature is odd.
+
+In the \ETX\ format, a ligature is specified using one of the slot
+commands
+\begin{quote}
+ |\Ligature|\marg{ligtype}\marg{right}\marg{new}\\
+ |\ligature|\marg{ligtype}\marg{right}\marg{new}\\
+ |\oddligature|\marg{note}\marg{ligtype}\marg{right}\marg{new}
+\end{quote}
+|\Ligature| is used for mandatory ligatures, |\ligature| is used for
+ordinary ligatures, and |\oddligature| is used for odd ligatures. The
+\meta{right} and \meta{new} arguments are names of the glyphs being
+assigned to the slots involved in this ligature. The \meta{right}
+specifies the right part in the slot pair being affected by the
+ligature, whereas the left part is the one of the |\setslot| \dots\
+|\endsetslot| construction in which the ligaturing command is placed.
+The \meta{new} specifies a new slot which will be inserted by the
+ligaturing instruction. The \meta{ligtype} is the actual ligaturing
+instruction that will be used; it must be |LIG|, |/LIG|, |/LIG>|,
+|LIG/|, |LIG/>|, |/LIG/|, |/LIG/>|, or |/LIG/>>|. The slashes specify
+retention of the left or right original character; the |>| signs
+specify passing over that many slots in the result without further
+ligature processing. \meta{note}, finally, is a piece of text which
+explains when the odd ligature may be appropriate. It is typeset as a
+footnote.
+
+As an example of ligatures we find the following in the specification
+of the \texttt{T1} encoding:
+\begin{quote}
+ |\nextslot{33}|\\
+ |\setslot{exclam}|\\
+ | \Unicode{0021}{EXCLAMATION MARK}|\\
+ | \Ligature{LIG}{quoteleft}{exclamdown}|\\
+ |\endsetslot|
+\end{quote}
+It is typeset as
+\begin{quote}
+ \textbf{Slot 33 `\texttt{exclam}'}\\*
+ Unicode character \texttt{U+0021}, \textsc{exclamation mark}.\\*
+ \textbf{Mandatory ligature}
+ \texttt{exclam}${}*{}$\texttt{quoteleft}${}\rightarrow
+ {}$\texttt{exclamdown}
+\end{quote}
+With other \meta{ligtype}s there may be more names listed on the
+right hand side and possibly a `$\lfloor$' symbol showing the
+position at which ligature processing will start afterwards.
+
+
+\subsection{Math font specialities}
+
+There are numerous technicalities which are special to math fonts, but
+only a few of them are exhibited in \ETX\ files.\footnote{For an
+overview of the subject, see for example Vieth~\cite{Vieth2001}.} Most
+of these have to do with the \TeX\ mechanisms that find sufficiently
+large characters for commands like |\left|, |\sqrt|, and |\widetilde|.
+
+The first mechanism for this is that a character in a font can sort of
+say ``If I'm too small, then then try character \dots\ instead''. This
+is expressed in an \ETX\ file using the |\nextlarger| command, which
+has the syntax
+\begin{quote}
+ |\nextlarger|\marg{glyph name}
+\end{quote}
+The second mechanism constructs a sufficiently large character from
+smaller pieces; this is known as a `varchar' or `extensible character'.
+This is expressed in an \ETX\ file using an ``extensible recipe'', the
+syntax for which is
+\begin{quote}
+ |\varchar| \meta{varchar commands} |\endvarchar|
+\end{quote}
+where each \meta{varchar command} is one of
+\begin{quote}
+ |\varrep|\marg{glyph name}\\
+ |\vartop|\marg{glyph name}\\
+ |\varmid|\marg{glyph name}\\
+ |\varbot|\marg{glyph name}
+\end{quote}
+There can be at most one of each and their order is irrelevant. The
+most important is the |\varrep| command, as that is the part which is
+repeated until the character is sufficiently large. The |\vartop|,
+|\varmid|, and |\varbot| commands are used to specify some other part
+which should be put at the top, middle, and bottom of the extensible
+character respectively. Not all extensible recipes use all of these,
+however.
+
+As an example, here is how a very large left brace is constructed:
+\begin{center}
+ \begin{tabular}{>{%
+ \fontencoding{OMX}\fontfamily{cmex}\selectfont
+ $\vcenter\bgroup\hbox\bgroup
+ }l<{\egroup\egroup$} l}
+ \char"38& For |\vartop{bracelefttp}|\\
+ \char"3E& For |\varrep{braceex}|\\
+ \char"3C& For |\varmid{braceleftmid}|\\
+ \char"3E& Again for |\varrep{braceex}|\\
+ \char"3A& For |\varbot{braceleftbt}|
+ \end{tabular}
+\end{center}
+
+Both |\nextlarger| and |\varchar| commands are like |\ligature| in
+that they describe ordinary features for the encoding; they appear in
+a specification \ETX\ file mainly to explain the purpose of some
+ordinary character. There is no such thing as a mandatory |\nextlarger|
+or |\varchar|, but varchars are occationally used to a similar effect.
+In these cases, the character generated by the extensible recipe is
+something quite different from what a |\char| for that slot would
+produce. Thus for the slot to produce the expected result it must be
+referenced using a |\delimiter| or |\radical| primitive, since those
+are the only ones which make use of the extensible recipe. The effect
+is that the slot has a \emph{semimandatory} assignment; the result of
+|\char| is unspecified (as for a slot with an ordinary assignment), but
+the result for a large delimiter or radical is not (as for a slot with
+a mandatory assignment).
+
+Thus some math fonts have an extra section ``Semimandatory characters''
+between the mandatory and ordinary character sections. In that section
+for the \texttt{OMX} encoding we find for example
+\begin{quote}\begin{verbatim}
+\nextslot{60}
+\setslot{braceleftmid}
+ \Unicode{2016}{DOUBLE VERTICAL LINE}
+ \comment{This is the large size of the |\Arrowvert|
+ delimiter, a glyphic variation on |\Vert|.
+ The \texttt{braceleftmid} glyph ordinarily
+ placed in this slot must not be too tall,
+ or else the extensible recipe actually producing
+ the character might sometimes not be used.}
+ \varchar
+ \varrep{arrowvertex}
+ \endvarchar
+\endsetslot
+\end{verbatim}\end{quote}
+which is typeset as
+\begin{quote}
+ \textbf{Slot 60 `\texttt{braceleftmid}'}\\*
+ Unicode character \texttt{U+2016}, \textsc{double vertical line}.\\
+ This is the large size of the |\Arrowvert|
+ delimiter, a glyphic variation on |\Vert|.
+ The \texttt{braceleftmid} glyph ordinarily
+ placed in this slot must not be too tall,
+ or else the extensible recipe actually producing
+ the character might sometimes not be used.\\
+ \textbf{Extensible glyph:}\\*
+ \textbf{Repeated} \texttt{arrowvertex}
+\end{quote}
+
+
+
+
+\subsection{Fontdimens}
+
+Each \TeX\ font contains a list of fontdimens, numbered from $1$ and
+up, which are accessible via the |\fontdimen| \TeX\ primitive. Quite a
+few are also used implicitly by \TeX\ and therefore cannot be left out
+even if they are totally irrelevant, but as one can always include
+some extra fontdimens in a font---the only bounds on how many
+fontdimens there may be are the general bound on the size of a TFM
+file and the amount of font memory \TeX\ has available---this is
+usually not a problem.
+
+The reason fontdimens are part of font encoding specifications is
+that the meaning of e.g.\ |\fontdimen|\,|8| varies between different
+fonts depending on their encoding; thus the encoding specification
+must define the quantity stored in each |\fontdimen| parameter. This
+is done using the |\setfontdimen| command, which has the syntax
+\begin{quote}
+ |\setfontdimen|\marg{number}\marg{name}
+\end{quote}
+The \meta{number} is the fontdimen number (as a sequence of decimal
+digits where the first digit isn't zero) and the \meta{name} is a
+symbolic name for the quantity.
+
+The standard list of symbolic names for fontdimen quantities appears
+below; the listed quantities should always be described using the names
+in this list. Encoding specifications that employ other quantities as
+fontdimens should include definitions of these quantities. Those
+quantities that are defined as ``Formula parameter \dots'' have to
+do with how mathematical formulae are rendered and are usually much
+too complicated to explain here. For exact definitions of these
+parameters, the reader is referred to Appendix~G of \textit{The
+\TeX book}~\cite{TeXbook}.
+\begin{list}{}{%
+ \setlength\labelwidth{0pt}%
+ \setlength\itemindent{-\leftmargin}%
+ \def\makelabel#1{\hspace{\labelsep}\normalfont\itshape #1}%
+ \setlength\itemsep{0.5\itemsep}%
+ \setlength\parsep{0.5\parsep}%
+}
+\item[acccapheight]
+ The height of accented full capitals.
+\item[ascender]
+ The height of lower case letters with ascenders.
+\item[axisheight] Formula parameter $\sigma_{22}$.
+\item[baselineskip]
+ The font designer's recommendation for natural length of the
+ \TeX\ parameter |\baselineskip|.
+\item[bigopspacing1] Formula parameter $\xi_{9}$.
+\item[bigopspacing2] Formula parameter $\xi_{10}$.
+\item[bigopspacing3] Formula parameter $\xi_{11}$.
+\item[bigopspacing4] Formula parameter $\xi_{12}$.
+\item[bigopspacing5] Formula parameter $\xi_{13}$.
+\item[capheight]
+ The height of full capitals.
+\item[defaultrulethickness] Formula parameter $\xi_{8}$.
+\item[delim1] Formula parameter $\sigma_{20}$.
+\item[delim2] Formula parameter $\sigma_{21}$.
+\item[denom1] Formula parameter $\sigma_{11}$.
+\item[denom2] Formula parameter $\sigma_{12}$.
+\item[descender]
+ The depth of lower case letters with descenders.
+\item[digitwidth]
+ The median width of the digits in the font.
+\item[extraspace]
+ The natural width of extra interword glue at the end of a sentence.
+ \TeX\ implicitly uses this parameter if |\spacefactor| is $2000$ or
+ more and |\xspaceskip| is zero.
+\item[interword]
+ The natural width of interword glue (spaces). \TeX\ implicitly uses
+ this parameter unless |\spaceskip| is nonzero.
+\item[italicslant]
+ The slant per point of the font. Unlike all other fontdimens, it is
+ not proportional to the font size.
+\item[maxdepth]
+ The maximal depth over all slots in the font.
+\item[maxheight]
+ The maximal height over all slots in the font.
+\item[num1] Formula parameter $\sigma_{8}$.
+\item[num2] Formula parameter $\sigma_{9}$.
+\item[num3] Formula parameter $\sigma_{10}$.
+\item[quad]
+ The quad width of the font, normally approximately equal to the
+ font size and\slash or the width of an `M'. Also implicitly available
+ as the length unit |em| and used for determining the size of the
+ length unit |mu|.
+\item[shrinkword]
+ The (finite) shrink component of interword glue (spaces). \TeX\
+ implicitly uses this parameter unless |\spaceskip| is nonzero.
+\item[stretchword]
+ The (finite) stretch component of interword glue (spaces). \TeX\
+ implicitly uses this parameter unless |\spaceskip| is nonzero.
+\item[sub1] Formula parameter $\sigma_{16}$.
+\item[sub2] Formula parameter $\sigma_{17}$.
+\item[subdrop] Formula parameter $\sigma_{19}$.
+\item[sup1] Formula parameter $\sigma_{13}$.
+\item[sup2] Formula parameter $\sigma_{14}$.
+\item[sup3] Formula parameter $\sigma_{15}$.
+\item[supdrop] Formula parameter $\sigma_{18}$.
+\item[verticalstem]
+ The dominant width of vertical stems. This quantity is meant to be used
+ as a measure of how ``dark'' the font is.
+\item[xheight]
+ The x-height (height of lower case letters without ascenders). Also
+ implicitly available as the length unit |ex|.
+\end{list}
+
+
+\subsection{The codingscheme}
+
+The final encoding-dependent piece of information in a \TeX\ font is
+the codingscheme, which is essentially a string declaring what
+encoding the font has. This information is currently only used by
+programs that convert the information in a \TeX\ font to some other
+format and these use it to identify the glyphs in the font. Therefore
+this string should be chosen so that the contents of the slots in the
+font can be positively identified. Observe that the encoding
+specification by itself does not provide enough information for this,
+since there are usually a couple of slots that do not contain
+mandatory characters. On the other hand, it is not a problem in this
+context if the font leaves some of the slots (even mandatory ones)
+empty as that is anyway easily detected. The only problem is with
+fonts where the slots are assigned to other characters than the ones
+specified in the encoding.
+
+For that reason, it is appropriate to assign two codingscheme strings
+to each encoding. The main codingscheme is for fonts were all slots
+(mandatory and ordinary alike) have been assigned according to the
+specification or have been left empty. The variant codingscheme is for
+fonts where some ordinary slots have been assigned other characters
+than the ones listed in the specification, but where the mandatory
+slots are still assigned according to the specification or are left
+empty. The font encoding specification should give the main
+codingscheme name, whereas the variant codingscheme name could be
+formed by adding \verb*| VARIANT| to the main codingscheme name.
+
+Technically the codingscheme is specified by setting the
+\texttt{codingscheme} string variable. This has the syntax
+\begin{quote}
+ |\setstr{codingscheme}|\marg{codingscheme name}
+\end{quote}
+e.g.
+\begin{quote}
+ |\setstr{codingscheme}{EXTENDED TEX FONT ENCODING - LATIN}|
+\end{quote}
+which is typeset as
+\begin{quote}
+ \textbf{Default} s(\texttt{codingscheme}) =
+ \verb*|EXTENDED TEX FONT ENCODING - LATIN|
+\end{quote}
+A codingscheme name may be at most 40 characters long and may not
+contain parentheses. If the entire \verb*| VARIANT| cannot be suffixed
+to a main name because the result becomes to long (as in the above
+example) then use the first 40 characters of the result.
+
+
+\subsection{Overall document structure}
+\label{Ssec:Structure}
+
+The overall structure of a font encoding specification should be
+roughly the following
+\begin{quote}
+ |\relax|\\
+ |\documentclass[twocolumn]{article}|\\
+ |\usepackage[specification]{fontdoc}|\\
+ \meta{preamble}\\
+ |\begin{document}|\\
+ \meta{title}\\
+ \meta{manifest}\\
+ |\encoding|\\
+ \meta{body}\\
+ |\endencoding|\\
+ \meta{discussion}\\
+ \meta{change history}\\
+ \meta{bibliography}\\
+ |\end{document}|
+\end{quote}
+The commands described in the preceding subsections must all go in
+the \meta{body} part of the document, as that is the only part of the
+file which actually gets processed as a data file. The part before
+|\encoding| is skipped and the part after |\endencoding| is never
+even input, so whatever appears there is only part of the \LaTeX\
+document. For the purposes of processing as a data file, the
+important markers in the file are the |\relax|, the |\endcoding|, and
+the |\endencoding| commands.
+
+The \meta{title} is the usual |\maketitle| (and the like) stuff. The
+person or persons who appear as author(s) are elsewhere in this paper
+described as the \emph{encoding proposers}. The \meta{title} should
+also give the date when the specification was last changed.
+
+The \meta{manifest} is an important, although usually pretty short,
+part of the specification. It is a piece of text which explains the
+purpose of the encoding (in particular what it can be used for) and
+the basic ideas (if any) which have been used in its construction. It
+is often best marked up as an abstract.
+
+The \meta{discussion} is the place for any longer comments on the
+encoding, such as analyses of different implementations, comparisons
+with other encodings, etc. This is also the place to explain any more
+general structures in the encoding, such as the arrow kit in the
+proposed \texttt{MS2} encoding~\cite{ClasenVieth}. In cases where the
+specification is mainly a formulation of what is already an
+established standard the \meta{discussion} is often rather short as
+the relevant discussion has already been published elsewhere, but
+it is anyway a service to the reader to include this information.
+References to the original documents should always be given.
+
+It might be convenient to include an FAQ section at the end of the
+discussion. This is particularly suited for explaining things where
+one has to look for a while and consult the references to find the
+relevant information.
+
+The \meta{change history} documents how the specification has changed
+over time. It is preferably detailed, as each detail in an encoding
+is important, but one should not be surprised if it is anyway rather
+short due to that there haven't been that many changes.
+
+The \meta{bibliography} is an important part of the specification. It
+should at the very least include all the sources which have been used
+in compiling the encoding specification, regardless of whether they
+are printed, available on the net, merely ``personal communication'',
+or something else. It is also a service to the reader to include in
+the bibliography some more general references for related matters.
+
+The \meta{preamble} is just a normal \LaTeX\ preamble and there are no
+restrictions on defining new commands in it, although use of such
+commands in the \meta{body} part is subject to the same restrictions
+as use of any general \LaTeX\ command. The preamble should however
+\emph{not} load any packages not part of the required suite of
+\LaTeX\ packages, as that may prevent users who do not have these
+packages from typesetting the specification. Likewise, the
+specification should \emph{not} require that some special font is
+available. Glyph examples for characters are usually better
+referenced via Unicode character charts than via special fonts.
+
+An exception to this rule about packages is that the specification
+must load the \package{fontdoc} package, as shown in the outline
+above, since that defines the |\setslot| etc.\ commands that should
+appear in the \meta{body}. This should not be a problem, as the
+\package{fontdoc} package can preferably be kept in the same directory
+as the collection of encoding specifications (see below). The
+\texttt{specification} option should be passed to the package to let it know
+that the file being processed is an encoding specification---otherwise
+|\Ligature| and |\ligature| will get the same formatting, for one. It
+is not necessary to use the \package{article} document class, and
+neither must it be passed the \texttt{twocolumn} option, but it is
+customary to do so. In principle any other document class within
+required \LaTeX\ will do just as well.
+
+If you absolutely think that using some non-required package
+significantly improves the specification, then try writing the code so
+that is loads the package only if it is available and provide some
+kind of fallback definition for sites where it is not. E.g.\ the
+\package{url} package could be loaded as
+\begin{verbatim}
+\IfFileExists{url.sty}{\usepackage{url}}{}
+\providecommand\url{\verb}
+\end{verbatim}
+The |\url| command defined by this is not equivalent to the command
+defined by the \package{url} package, but it can serve fairly well
+(with a couple of extra overfull lines as only ill effect) if its
+use is somewhat restricted.
+
+Finally, a technical restriction on the \meta{preamble}, \meta{title},
+and \meta{manifest} is that they must not contain any mismatched
+|\if|s (of any type) or |\fi|s, as \TeX\ conditionals will be used for
+skipping those parts of the file when it is processed as a data file.
+If the definition of some macro includes mismatched |\if|s or |\fi|s
+(this will probably occur only rarely) then include some extra code
+so that they do match.
+
+
+% All technical parts of the encoding specification (slot assignments,
+% fontdimens, etc.\@) have to be in the \meta{encoding commands} part.
+% The other parts are suitably used for longer commentry, such as the
+% mainfest (see below), revision history, and bibliography.
+%
+% When the file is being typeset as a \LaTeX\ document there is nothing
+% special going on. The |\encoding| and |\endencoding| commands may set
+% some internal variables, but otherwise they do very little. When the
+% file is being read by \package{fontinst}, things are quite different.
+% Everything between the initial |\relax| and |\encoding| is skipped,
+% and the file is not read further than to the |\endencoding|. Hence
+% the \meta{preamble}, \meta{\LaTeX\ text 1}, and \meta{\LaTeX\ text 2}
+% can contain pretty much anything (with a few exceptions) which is
+% legal in a \LaTeX\ document.
+
+
+\subsection{Encoding specification body syntax}
+
+The \meta{body} part of an encoding specification must comply to a
+much stricter syntax than the rest of the file. The \meta{body} is
+a sequence of \meta{encoding command}s, each of which should be one
+of the following:
+\begin{quote}
+ |\setslot|\marg{glyph name} \meta{slots commands} |\endsetslot|\\
+ |\nextslot|\marg{number}\\
+ |\skipslots|\marg{number}\\
+ |\setfontdimen|\marg{number}\marg{name}\\
+ |\setstr{codingscheme}|\marg{codingscheme name}\\
+ |\needsfontinstversion|\marg{version number}
+\end{quote}
+The |\needsfontinstversion| command is usually placed immediately
+after the |\encoding| command. The \meta{version number} must be at
+least |1.918| for many of the features described in this file to be
+available, and at least |1.928| if the |\charseq| command is used.
+
+The \meta{slot commands} are likewise a sequence of \meta{slot
+command}s, each of which should be one of the following:
+\begin{quote}
+ |\Unicode|\marg{code point}\marg{name}\\
+ |\charseq|\marg{\cs{Unicode} commands}\\
+ |\comment|\marg{text}\\
+ |\Ligature|\marg{ligtype}\marg{right}\marg{new}\\
+ |\ligature|\marg{ligtype}\marg{right}\marg{new}\\
+ |\oddligature|\marg{note}\marg{ligtype}\marg{right}\marg{new}\\
+ |\nextlarger|\marg{glyph name}\\
+ |\varchar| \meta{varchar commands} |\endvarchar|
+\end{quote}
+where \meta{varchar commands} similarly is a sequence of \meta{varchar
+command}s, each of which should be one of the following:
+\begin{quote}
+ |\varrep|\marg{glyph name}\\
+ |\vartop|\marg{glyph name}\\
+ |\varmid|\marg{glyph name}\\
+ |\varbot|\marg{glyph name}
+\end{quote}
+Finally, one can include any number of \meta{comment command}s between
+any two encoding, slot, or varchar commands. The comment commands are
+\begin{quote}
+ |\begincomment| \meta{\LaTeX\ text} |\endcomment|\\
+ |\label|\marg{reference label}
+\end{quote}
+The \meta{\LaTeX\ text} can be pretty much any \LaTeX\ code that can
+appear in conditional text. (|\begincomment| is either |\iffalse| or
+|\iftrue| depending on whether the encoding specification is
+processed as a data file or typeset as a \LaTeX\ document respectively.
+|\endcomment| is always |\fi|.) The |\label| command is just
+the normal \LaTeX\ |\label| command; when it is used in a \meta{slot
+commands} it references that particular slot (by number and glyph
+name).
+
+The full syntax of the \ETX\ format can be found in the
+\package{fontinst} manual~\cite{fontinst-man}, but font encoding
+specifications only need a subset of that.
+
+
+\subsection{Additional \package{fontdoc} features}
+
+There is an ``in comment paragraph'' form |\textunicode| of the
+|\Unicode| command. Both commands have the same syntax, but
+|\textunicode| is only allowed in ``comment'' contexts. A typical use
+of |\textunicode| is
+\begin{quote}
+ |\comment{An |\dots\\
+ \quad\dots| this is \textunicode{2012}{FIGURE DASH}; in |\dots\\
+ |}|
+\end{quote}
+which is typeset as
+\begin{quote}
+ An \dots\ this is \texttt{U+2012} (\textsc{figure dash}); in \dots
+\end{quote}
+
+The \package{fontdoc} package inputs a configuration file
+\texttt{fontdoc.cfg} if that exists. This can be used to pass
+additional options to the package. The only currently available
+options that this could be of interest for are the \texttt{hypertex}
+and \texttt{pdftex} options, which hyperlinks each \texttt{U+}\dots\
+generated by |\Unicode| or |\textunicode| (using Hyper\TeX\ or
+pdf\TeX\ conventions\footnote{One could just as well do the same
+thing using some other convention if a suitable definition of
+\cs{FD@codepoint} is included in \texttt{fontdoc.cfg}. See the
+\package{fontinst} sources~\cite{fontinst-pre} for more details.}
+respectively) to a corresponding glyph image on the Unicode consortium
+website. To use this feature one should put the line
+\begin{quote}
+ |\ExecuteOptions{hypertex}|
+\end{quote}
+or
+\begin{quote}
+ |\ExecuteOptions{pdftex}|
+\end{quote}
+in the \texttt{fontdoc.cfg} file. \emph{Please} do not include this
+option in the |\usepackage|\nolinebreak[1]|{fontdoc}| of an encoding
+specification file as that can be a severe annoyance for people whose
+\TeX\ program or DVI viewers do not support the necessary extensions.
+% Hyper\TeX\ |\special|s.
+
+
+\section{Font encoding ratification}
+
+This section describes a suggested ratification process for font
+encoding specifications. As there are fewer technical matters that
+impose restrictions on what it may look like, it is probably more
+subjective than the other parts of this paper.
+
+\medskip
+
+A specification in the process of being ratified can be in one of
+three different stages: \emph{draft}, \emph{beta}, or \emph{final}.
+Initially the specification is in the draft stage, during which it
+will be scrutinized and can be subject to major changes. A
+specification which is in the beta stage has got a formal approval
+but the encoding in question may still be subject to some minor
+changes if weighty arguments present themselves. Once the
+specification has reached the final stage, the encoding may not
+change at all.
+
+
+\subsection{Getting to the draft stage}
+
+The process of taking an encoding to the draft stage can be
+summarized in the following steps. Being in the draft stage doesn't
+really say anything about whether the encoding is in any way correct
+or useful, except in that some people (the encoding proposers)
+believe it is and are willing to spend some time on ratifying it.
+
+\paragraph{Write an encoding specification} The first step is to
+write a specification for the font encoding in question. This
+document must not only technically describe the encoding but also
+explain what the encoding is for and why it was created. See
+Subsection~\ref{Ssec:Structure} for details on how the document is
+preferably organised.
+
+\paragraph{Request an encoding name} The second step is to write to
+the \LaTeX3 project and request a \LaTeX\ encoding name for the
+encoding. This mail should be in the form of a \LaTeX\ bug report, it
+must be sent to
+\begin{quote}
+ \href{mailto:latex-bugs@latex-project.org}%
+ {\texttt{latex-bugs@latex-project.org}},
+\end{quote}
+and it must include the encoding specification file. Suggestions for
+an encoding name are appreciated, but not necessarily accepted.
+The purpose of this mail is \emph{not} to get an approval of the
+encoding, but only to have a reasonable name assigned to it.
+
+\paragraph{Upload the specification to CTAN} The third step is make
+the encoding specification publicly available by uploading it to
+CTAN. Encoding specifications are collected in the
+\begin{quote}
+ \ctanref{info/encodings}{\texttt{info/encodings}}
+\end{quote}
+directory (which should also contain the most recent version of this
+paper). The name of the uploaded file should be
+\meta{encoding name}\texttt{draft.etx}. The reason for this naming is
+that it must be clear that the specification has not yet been ratified.
+
+\paragraph{Announce the encoding} When the upload has been confirmed,
+it is time to announce the encoding by posting a message about it to
+the relevant forums. Most important is the \texttt{tex-fonts} mailing
+list, since that is where new encodings should be debated. Messages
+should also be posted to the \texttt{comp.text.tex} newsgroup and any
+forums related to the intended use of the encoding: an encoding for
+Sanskrit should be announced on Indian \TeX\ users forums, an
+encoding for printing chess positions should be announced on some
+chess-with-\TeX\ user forum, etc.; in the extent that such forums exist.
+
+The full address of the \texttt{tex-fonts} mailing list is
+\begin{quote}
+ \texttt{tex-fonts@math.utah.edu}
+\end{quote}
+This list rejects postings from non-members, so you need to subscribe
+to it before you can post your announcement. This is done by sending
+a `subscribe me' mail to
+\begin{quote}
+ \href{mailto:tex-fonts-request@math.utah.edu}
+ {\texttt{tex-fonts-request@math.utah.edu}}
+\end{quote}
+The list archives can be found at
+\begin{quote}
+ \href{http://www.math.utah.edu/mailman/listinfo/tex-fonts}
+ {\textsc{http:}/\slash \texttt{www.math.utah.edu}\slash
+ \texttt{mailman}\slash \texttt{listinfo}\slash
+ \texttt{tex-fonts}}
+\end{quote}
+A tip is to read through the messages from a couple of months
+before you write up your announcement, as that should help you get
+acquainted with the normal style on the list. Please do not send
+messages encoded in markup languages (notably, \textsmaller{HTML},
+\textsmaller{XML}, and word processor formats) to the list.
+
+\paragraph{Experimental encodings} There is a point in going through
+the above procedure even for experimental encodings, i.e., encodings
+whose names start with an \texttt{E}. Of course there is no idea in
+ratifying a specification of an experimental encoding, as it is very
+likely to frequently change, but having a proper name assigned to the
+encoding and uploading its specification to CTAN makes it much simpler
+for other people to learn about and make references to the encoding.
+
+
+\subsection{From draft to beta stage}
+
+The main difference between a draft and beta stage specification
+respectively is that beta stage specifications have been scrutinized
+by other people and found to be free of errors. The practical
+implementation of this is that a debate is held (in the normal
+anarchical manner of mailing list debates) on the \texttt{tex-fonts}
+mailing list. In particular the following aspects of the
+specification should be checked:
+\begin{enumerate}
+ \item \emph{Is the encoding technically correct?}
+ There are many factors which affect what \TeX\ does and it is
+ easy to overlook some. (The \cs{lccode}s seem to be particularly
+ troublesome, in this respect.) Sometimes fonts simply cannot work
+ as an encoding specifies they should and it is important that
+ such defects in the encoding are discovered on an early stage.
+ \item \emph{Are there any errors in the specification?}
+ A font encoding specification is largely a table and typos are
+ easy to make. Proof-reading may be boring, but it is very, very
+ important.
+ \item \emph{Is the specification sufficiently precise?}
+ Are there any omissions, ambiguities, inaccuracies, or completely
+ irrelevant material in the specification? There shouldn't be.
+\end{enumerate}
+During the debate, the encoding proposers should hear what other
+people have to say about the encoding draft, revise it accordingly
+when some flaw is pointed out, and upload the revised version. This
+cycle may well have to be repeated several times before everyone's
+content. It is worth pointing out that in practice the debate should
+turn out to be more of a collective authoring of the specification
+than a defense of its validity. There is no point in going into it
+expecting the worst.
+
+Unfortunately, it might happen that there never is a complete agreement
+on an encoding specification---depending on what side on takes, either
+the encoding proposers refuse to correct obvious flaws in it, or someone
+on the list insists that there is a flaw although there is obviously
+not---but hopefully that will never happen. If it anyway does happen
+then the person objecting should send a mail whose subject contains the
+phrase "formal protest against XXX encoding" (with XXX replaced by
+whatever the encoding is called) to the list. Then it will be up to
+the powers that be to decide on the fate of the encoding (see below).
+
+\paragraph{Summarize the debate} When the debate on the encoding is
+over---e.g.\ a month after anyone last posted anything new on the
+subject---then the encoding proposers should summarize the debate on
+the encoding specification draft and post this summary as a follow-up
+on the original mail to \texttt{latex-bugs}. This summary should list
+the changes that have been made to the encoding, what suggestions there
+were for changes which have not been included, and whether there were
+any formal protests against the encoding. The summary should also explain
+what the proposers want to have be done with the encoding. In the
+usual case this is having it advanced to beta stage, but the proposers
+might alternatively at this point have reached the conclusion that the
+encoding wasn't such a good idea to start with and therefore withdraw
+it, possibly to come again later with a different proposal.
+
+In response to this summary, the \LaTeX-project people may do one of
+three things:
+\begin{itemize}
+ \item
+ If the proposers wants the encoding specification advanced and
+ there are no formal protests against this, then the encoding
+ should be advanced to the beta stage. The \LaTeX-project
+ people do this by adding the encoding to the list of approved
+ (beta or final stage) encodings that they [presumably] maintain.
+ \item
+ If the proposers want to withdraw the encoding specification
+ then the name assigned to it should once again be made available
+ for use for other encodings.
+ \item
+ If the proposers want the encoding specification advanced but
+ there is some formal protest against this, then the entire matter
+ should be handed over to some suitable authority, as a suggestion
+ some technical TUG committee, for resolution.
+\end{itemize}
+
+
+\paragraph{Update the specification on CTAN} When the specification
+has reached the beta stage, its file on CTAN should be updated to say
+so. In particular the file name should be changed from \meta{encoding
+name}\texttt{draft.etx} to \meta{encoding name}\texttt{spec.etx}.
+
+
+\paragraph{Modifying beta stage encodings} If a beta stage encoding is
+modified then the revised specification should go through the above
+procedure of ratification again before it can replace the previous
+\meta{encoding name}\texttt{spec.etx} file on CTAN. The revised
+version should thus initially be uploaded as \meta{encoding
+name}\texttt{draft.etx}, reannounced, and redebated. It can however
+be expected that such debates will not be as extensive as the
+original debates.
+
+
+\subsection{From beta stage to final stage}
+
+The requirements for going from beta stage to final stage are more
+about showing that the encoding has reached a certain maturity than
+about demonstrating any technical merits of it. The main difference in
+usefulness between a beta stage encoding and a final stage encoding is
+that the latter can be considered safe for archival purposes, whereas
+one should have certain reservations against such use of beta stage
+encodings.
+
+It seems reasonable that the following conditions should have to be
+fulfilled before a beta stage encoding can be made a final stage
+encoding:
+\begin{itemize}
+ \item At least one year must have passed since the last change was
+ made to the specification.
+ \item At least two people other than the proposer must have
+ succeeded in implemented the encoding in a font.
+\end{itemize}
+It is quite possible that some condition should be added or some of
+the above conditions reformulated.
+
+
+% References updated 2004/08/07.
+\begin{thebibliography}{???}
+\bibitem{ATN5013}
+ Adobe Systems Incorporated:
+ \textit{Adobe Standard Cyrillic Font Specification},
+ Adobe Technical Note \#5013, 1998;
+ \href{http://partners.adobe.com/asn/developer/pdfs/tn/%
+ 5013.Cyrillic_Font_Spec.pdf}{\textsc{http}:/\slash
+ \texttt{partners.adobe.com}\slash \texttt{asn}\slash
+ \texttt{developer}\slash \texttt{pdfs}\slash \texttt{tn}\slash
+ \texttt{5013.Cyrillic\_Font\_Spec.pdf}}.
+\bibitem{AGL}
+ Adobe Systems Incorporated: \textit{Adobe Glyph List},
+ text file, 1998,
+ \href{http://partners.adobe.com/asn/developer/type/glyphlist.txt}
+ {\textsc{http}:/\slash \texttt{partners.adobe.com}\slash
+ \texttt{asn}\slash \texttt{developer}\slash \texttt{type}\slash
+ \texttt{glyphlist.txt}}.
+\bibitem{unicodesign}
+ Adobe Systems Incorporated:
+ \textit{Adobe Solutions Network: Unicode and Glyph Names},
+ web page, 1998,
+ \href{http://partners.adobe.com/asn/developer/type/unicodegn.html}
+ {\textsc{http}:/\slash \texttt{partners.adobe.com}\slash
+ \texttt{asn}\slash \texttt{developer}\slash \texttt{type}\slash
+ \texttt{unicodegn.html}}.
+\bibitem{ClasenVieth}
+ Matthias Clasen and Ulrik Vieth:
+ \textit{Towards a new Math Font Encoding for (La)TeX},
+ March 1998, presented at EuroTeX'98;
+ \href{http://tug.org/twg/mfg/papers/current/mfg-euro-all.ps.gz}
+ {\textsc{http}:/\slash \texttt{tug.org}\slash \texttt{twg}\slash
+ \texttt{mfg}\slash \texttt{papers}\slash \texttt{current}\slash
+ \texttt{mfg-euro-all.ps.gz}}.
+\bibitem{fontinst-man}
+ Alan Jeffrey, Rowland McDonnell, Ulrik Vieth, and Lars Hellstr\"om:
+ \textit{\package{fontinst}---font installation software for \TeX}
+ (manual), 2004,
+ \ctanref{fonts/utilities/fontinst/doc/fontinst.tex}{%
+ \textsc{ctan}:\discretionary{}{}{\thinspace}%
+ \texttt{fonts}\slash \texttt{utilities}\slash
+ \texttt{fontinst}\slash \texttt{doc}\slash \texttt{fontinst.tex}}.
+% \bibitem{fontinst}
+% Alan Jeffrey, Sebastian Rahtz, and Ulrik Vieth:
+% \textit{The \package{fontinst} utility}, documented source code,
+% v\,1.801,
+% \ctanref{fonts/utilities/fontinst/source}{%
+% \textsc{ctan}:\discretionary{}{}{\thinspace}%
+% \texttt{fonts}\slash \texttt{utilities}\slash
+% \texttt{fontinst}\slash \texttt{source}/}.
+\bibitem{fontinst-pre}
+ Alan Jeffrey, Sebastian Rahtz, Ulrik Vieth, and Lars Hellstr\"om:
+ \textit{The \package{fontinst} utility}, documented source code,
+ v\,1.9xx,
+ \ctanref{fonts/utilities/fontinst/source}{%
+ \textsc{ctan}:\discretionary{}{}{\thinspace}%
+ \texttt{fonts}\slash \texttt{utilities}\slash
+ \texttt{fontinst}\slash \texttt{source}/}.
+\bibitem{TeXbook}
+ Donald E.\ Knuth, Duane Bibby (illustrations): \textit{The \TeX book},
+ Ad\-di\-son--Wes\-ley, 1991;
+ volume A of \textit{Computers and typesetting}.
+\bibitem{LaTeXCompanion}
+ Frank Mittelbach and Michel Goossens, with Johannes Braams,
+ David Carlisle, and Chris Rowley:
+ \textit{The \LaTeX\ Companion} (second edition),
+ Ad\-di\-son--Wes\-ley, 2004; ISBN~0-201-36299-6.
+\bibitem{Omega-doc}
+ John Plaice and Yannis Haralambous:
+ \textit{Draft documentation for the Omega system},
+ version~1.12, 1999;
+ \href{http://omega.cse.unsw.edu.au:8080/doc-1.12.ps}{%
+ \textsc{http:}/\slash \texttt{omega.cse.unsw.edu.au:8080}\slash
+ \texttt{doc-1.12.ps}}.
+% \textsc{ctan}:\discretionary{}{}{\thinspace}%
+% \texttt{systems}\slash \texttt{omega}\slash
+% \texttt{omega-doc-1.8.tar.gz}.
+\bibitem{Vieth2001}
+ Ulrik Vieth:
+ \textit{Math typesetting in \TeX: The~good, the~bad, the~ugly},
+ to appear in the proceedings of Euro\TeX\ 2001;
+ \href{http://www.ntg.nl/eurotex/vieth.pdf}{%
+ \textsc{http}:/\slash \texttt{www.ntg.nl}\slash
+ \texttt{eurotex}\slash \texttt{vieth.pdf}}.
+\end{thebibliography}
+
+
+\end{document} \ No newline at end of file
diff --git a/fonts/utilities/fontinst/doc/encspecs/omxdraft.etx b/fonts/utilities/fontinst/doc/encspecs/omxdraft.etx
new file mode 100644
index 0000000000..efccabde85
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/encspecs/omxdraft.etx
@@ -0,0 +1,985 @@
+\documentclass[twocolumn]{article}
+\usepackage[specification]{fontdoc}[2001/06/01]
+
+% \usepackage[T1]{fontenc}
+\DeclareTextCommandDefault{\textvisiblespace}{%
+ \mbox{\kern.06em\vrule height.3ex}%
+ \vbox{\hrule width.3em}%
+ \hbox{\vrule height.3ex\kern.06em}}
+
+\DeclareRobustCommand\cs[1]{\texttt{\char`\\#1}}
+
+\showbranches
+
+\begin{document}
+
+\title{\texttt{OMX} encoding draft specification}
+\author{Lars Hellstr\"om}
+\date{2001/10/20}
+\maketitle
+
+\begin{abstract}
+ The \TeX\ math extensions (\texttt{OMX}) encoding is a container for
+ most of the ``growing'' characters in the standard math set-up, but
+ that is pretty much the extent of it. Some of the characters occur
+ in ``normal size'' in other encodings; in these cases it is usually
+ a single math command that usually make use of characters in both
+ encodings.
+\end{abstract}
+
+
+\encoding
+
+\begincomment
+\section{Mandatory characters}
+
+\subsection{Delimiters}
+\endcomment
+
+\nextslot{0}
+\setslot{parenleftbig}
+ \Unicode{0028}{LEFT PARENTHESIS}
+ \nextlarger{parenleftBig}
+\endsetslot
+
+\setslot{parenrightbig}
+ \Unicode{0029}{RIGHT PARENTHESIS}
+ \nextlarger{parenrightBig}
+\endsetslot
+
+\setslot{bracketleftbig}
+ \Unicode{005B}{LEFT SQUARE BRACKET}
+ \nextlarger{bracketleftBig}
+\endsetslot
+
+\setslot{bracketrightbig}
+ \Unicode{005D}{RIGHT SQUARE BRACKET}
+ \nextlarger{bracketrightBig}
+\endsetslot
+
+\setslot{floorleftbig}
+ \Unicode{230A}{LEFT FLOOR}
+ \nextlarger{floorleftBig}
+\endsetslot
+
+\setslot{floorrightbig}
+ \Unicode{230B}{RIGHT FLOOR}
+ \nextlarger{floorrightBig}
+\endsetslot
+
+\setslot{ceilingleftbig}
+ \Unicode{2308}{LEFT CEILING}
+ \nextlarger{ceilingleftBig}
+\endsetslot
+
+\setslot{ceilingrightbig}
+ \Unicode{2309}{RIGHT CEILING}
+ \nextlarger{ceilingrightBig}
+\endsetslot
+
+\setslot{braceleftbig}
+ \Unicode{007B}{LEFT CURLY BRACKET}
+ \nextlarger{braceleftBig}
+\endsetslot
+
+\setslot{bracerightbig}
+ \Unicode{007D}{RIGHT CURLY BRACKET}
+ \nextlarger{bracerightBig}
+\endsetslot
+
+\setslot{angleleftbig}
+ \Unicode{2329}{LEFT-POINTING ANGLE BRACKET}
+ \nextlarger{angleleftBig}
+\endsetslot
+
+\setslot{anglerightbig}
+ \Unicode{232A}{RIGHT-POINTING ANGLE BRACKET}
+ \nextlarger{anglerightBig}
+\endsetslot
+
+\setslot{barex}
+ \Unicode{007C}{VERTICAL LINE}
+ \comment{This is used by the \cs{vert} command. When not accessed
+ as a delimiter, this character may be much shorter than one
+ would expect.}
+ \varchar
+ \varrep{barex}
+ \endvarchar
+\endsetslot
+
+\setslot{bardblex}
+ \Unicode{2016}{DOUBLE VERTICAL LINE}
+ \comment{This is used by the \cs{Vert} command. When not accessed
+ as a delimiter, this character may be much shorter than one
+ would expect.}
+ \varchar
+ \varrep{bardblex}
+ \endvarchar
+\endsetslot
+
+\setslot{slashbig}
+ \Unicode{2215}{DIVISION SLASH}
+ \comment{Although this character is normally accessed via \TeX's
+ growing delimiter mechanism, it is not used as such in formulae,
+ but as a large division slash. Since the use is unambigously for
+ division and the like, it would be inaccurate to identify this
+ character with \textunicode{002F}{SOLIDUS}.}
+ \nextlarger{slashBig}
+\endsetslot
+
+\setslot{backslashbig}
+ \Unicode{005C}{REVERSE SOLIDUS}
+ \comment{This is \TeX's \cs{backslash} (use for ``double coset''),
+ not \cs{setminus}, and hence it is not
+ \textunicode{2216}{SET MINUS}.}
+ \nextlarger{backslashBig}
+\endsetslot
+
+\nextslot{62}
+\setslot{braceex}
+ \Unicode{007C}{VERTICAL LINE}
+ \comment{This is used by the \cs{bracevert} command.}
+ \label{braceex}
+ \varchar
+ \varrep{braceex}
+ \endvarchar
+ \comment{This slot contains the repeatable part of a extensible
+ brace delimiter. In the standard set-up, the extensible recipes of
+ slots~\ref{bracelefttp}, \ref{bracerighttp}, \ref{braceleftbt},
+ \ref{bracerightbt}, \ref{parenleftbt}, and \ref{parenrightbt} all
+ make use of this slot.}
+\endsetslot
+
+\nextslot{"42}
+\setslot{parenleftex}
+ \Unicode{007C}{VERTICAL LINE}
+ \comment{As astonishing as it may seem, there is no command which
+ accesses this slot. The glyph is similar to that in
+ slot~\ref{braceex}, but shifted to the left.}
+ \varchar
+ \varrep{parenleftex}
+ \endvarchar
+\endsetslot
+
+\setslot{parenrightex}
+ \Unicode{007C}{VERTICAL LINE}
+ \comment{As astonishing as it may seem, there is no command which
+ accesses this slot. The glyph is similar to that in
+ slot~\ref{braceex}, but shifted to the right.}
+ \varchar
+ \varrep{parenrightex}
+ \endvarchar
+\endsetslot
+
+\nextslot{"7A}
+\setslot{bracehtipdownleft}
+ \comment{This is \cs{braceld}, a tip (pointing left, bending down)
+ used to build over- and underbraces.}
+\endsetslot
+
+\setslot{bracehtipdownright}
+ \comment{This is \cs{bracerd}, a tip (pointing right, bending down)
+ used to build over- and underbraces.}
+\endsetslot
+
+\setslot{bracehtipupleft}
+ \comment{This is \cs{bracelu}, a tip (pointing left, bending up)
+ used to build over- and underbraces.}
+\endsetslot
+
+\setslot{bracehtipupright}
+ \comment{This is \cs{braceru}, a tip (pointing right, bending up)
+ used to build over- and underbraces.}
+\endsetslot
+
+
+
+\begincomment
+\subsection{Text style operators}
+
+With the exception of the integrals, all the following characters
+should be \textsc{n-ary \dots}, but some cases there are no such
+variants defined in Unicode.
+\endcomment
+
+\nextslot{"46}
+\setslot{unionsqtext}
+ \Unicode{2294}{SQUARE CUP}
+ \nextlarger{unionsqdisplay}
+\endsetslot
+
+\skipslots{1}
+\setslot{contintegraltext}
+ \Unicode{222E}{CONTOUR INTEGRAL}
+ \nextlarger{contintegraldisplay}
+\endsetslot
+
+\skipslots{1}
+\setslot{circledottext}
+ \Unicode{2299}{CIRCLED DOT OPERATOR}
+ \nextlarger{circledotdisplay}
+\endsetslot
+
+\skipslots{1}
+\setslot{circleplustext}
+ \Unicode{2295}{CIRCLED PLUS}
+ \nextlarger{circleplusdisplay}
+\endsetslot
+
+\skipslots{1}
+\setslot{circlemultiplytext}
+ \Unicode{2297}{CIRCLED TIMES}
+ \nextlarger{circlemultiplydisplay}
+\endsetslot
+
+\skipslots{1}
+\setslot{summationtext}
+ \Unicode{2211}{N-ARY SUMMATION}
+ \nextlarger{summationdisplay}
+\endsetslot
+
+\setslot{producttext}
+ \Unicode{220F}{N-ARY PRODUCT}
+ \nextlarger{productdisplay}
+\endsetslot
+
+\setslot{integraltext}
+ \Unicode{222B}{INTEGRAL}
+ \nextlarger{integraldisplay}
+\endsetslot
+
+\setslot{uniontext}
+ \Unicode{22C3}{N-ARY UNION}
+ \nextlarger{uniondisplay}
+\endsetslot
+
+\setslot{intersectiontext}
+ \Unicode{22C2}{N-ARY INTERSECTION}
+ \nextlarger{intersectiondisplay}
+\endsetslot
+
+\setslot{unionmultitext}
+ \Unicode{228E}{MULTISET UNION}
+ \nextlarger{unionmultidisplay}
+\endsetslot
+
+\setslot{logicalandtext}
+ \Unicode{22C0}{N-ARY LOGICAL AND}
+ \nextlarger{logicalanddisplay}
+\endsetslot
+
+\setslot{logicalortext}
+ \Unicode{22C1}{N-ARY LOGICAL OR}
+ \nextlarger{logicalordisplay}
+\endsetslot
+
+\skipslots{8}
+\setslot{coproducttext}
+ \Unicode{2210}{N-ARY COPRODUCT}
+ \nextlarger{coproductdisplay}
+\endsetslot
+
+
+
+\begincomment
+\subsection{Accents, arrows, and the radical}
+\endcomment
+
+\nextslot{"62}
+\setslot{hatwide}
+ \Unicode{0302}{COMBINING CIRCUMFLEX ACCENT}
+ \nextlarger{hatwider}
+\endsetslot
+
+\skipslots{2}
+
+\setslot{tildewide}
+ \Unicode{0303}{COMBINING TILDE}
+ \nextlarger{tildewider}
+\endsetslot
+
+\nextslot{"70}
+\setslot{radicalbig}
+ \Unicode{221A}{SQUARE ROOT}
+ \nextlarger{radicalBig}
+\endsetslot
+
+\nextslot{"78}
+\setslot{arrowtp}
+ \Unicode{2191}{UPWARDS ARROW}
+ \varchar
+ \vartop{arrowtp}
+ \varrep{arrowvertex}
+ \endvarchar
+\endsetslot
+
+\setslot{arrowbt}
+ \Unicode{2193}{DOWNWARDS ARROW}
+ \varchar
+ \varrep{arrowvertex}
+ \varbot{arrowbt}
+ \endvarchar
+\endsetslot
+
+\nextslot{"7E}
+\setslot{arrowdbltp}
+ \Unicode{21D1}{UPWARDS DOUBLE ARROW}
+ \varchar
+ \vartop{arrowdbltp}
+ \varrep{arrowdblvertex}
+ \endvarchar
+\endsetslot
+
+\setslot{arrowdblbt}
+ \Unicode{21D3}{DOWNWARDS DOUBLE ARROW}
+ \varchar
+ \varrep{arrowdblvertex}
+ \varbot{arrowdblbt}
+ \endvarchar
+\endsetslot
+
+
+
+
+
+
+\begincomment
+\section{Semimandatory characters}
+\endcomment
+
+\nextslot{"3A}
+\setslot{braceleftbt}
+ \comment{This is the \cs{lgroup} delimiter, which looks like a
+ \textunicode{007B}{LEFT CURLY BRACKET} with flat middle section.
+ There does not seem to be such a character in Unicode, but a
+ close approximation would be a narrowed
+ \textunicode{3014}{LEFT TORTOISE SHELL BRACKET}.}
+ \label{braceleftbt}
+ \varchar
+ \vartop{bracelefttp}
+ \varrep{braceex}
+ \varbot{braceleftbt}
+ \endvarchar
+ \comment{The slot contains the curved bottom of a
+ \textunicode{007B}{LEFT CURLY BRACKET}.}
+\endsetslot
+
+\setslot{bracerightbt}
+ \comment{This is the \cs{rgroup} delimiter, which looks like a
+ \textunicode{007D}{RIGHT CURLY BRACKET} with flat middle section.
+ There does not seem to be such a character in Unicode, but a
+ close approximation would be a narrowed
+ \textunicode{3015}{RIGHT TORTOISE SHELL BRACKET}.}
+ \label{bracerightbt}
+ \varchar
+ \vartop{bracerighttp}
+ \varrep{braceex}
+ \varbot{bracerightbt}
+ \endvarchar
+ \comment{The slot contains the curved bottom of a
+ \textunicode{007D}{RIGHT CURLY BRACKET}.}
+\endsetslot
+
+\setslot{braceleftmid}
+ \Unicode{007C}{VERTICAL LINE}
+ \comment{This is used by the \cs{arrowvert} command.}
+ \varchar
+ \varrep{arrowvertex}
+ \endvarchar
+ \comment{The slot contains the middle part of a
+ \textunicode{007B}{LEFT CURLY BRACKET}.}
+\endsetslot
+
+\setslot{bracerightmid}
+ \Unicode{2016}{DOUBLE VERTICAL LINE}
+ \comment{This is used by the \cs{Arrowvert} command.}
+ \varchar
+ \varrep{arrowdblvertex}
+ \endvarchar
+ \comment{The slot contains the middle part of a
+ \textunicode{007D}{RIGHT CURLY BRACKET}.}
+\endsetslot
+
+\skipslots{1}
+
+\setslot{arrowvertex}
+ \Unicode{2195}{UP DOWN ARROW}
+ \varchar
+ \vartop{arrowtp}
+ \varrep{arrowvertex}
+ \varbot{arrowbt}
+ \endvarchar
+ \comment{This slot contains the repeatable middle part of a vertical
+ arrow.}
+\endsetslot
+
+\setslot{parenleftbt}
+ \label{parenleftbt}
+ \comment{This is the \cs{lmoustache} delimiter, whose top half is
+ like \cs{lgroup} and whose bottom half is like \cs{rgroup}.}
+ \varchar
+ \vartop{bracelefttp}
+ \varrep{braceex}
+ \varbot{bracerightbt}
+ \endvarchar
+ \comment{This slot contains the curved bottom of a
+ \textunicode{0028}{LEFT PARENTHESIS}.}
+\endsetslot
+
+\setslot{parenrightbt}
+ \label{parenrightbt}
+ \comment{This is the \cs{rmoustache} delimiter, whose top half is
+ like \cs{rgroup} and whose bottom half is like \cs{lgroup}.}
+ \varchar
+ \vartop{bracerighttp}
+ \varrep{braceex}
+ \varbot{braceleftbt}
+ \endvarchar
+ \comment{This slot contains the curved bottom of a
+ \textunicode{0029}{RIGHT PARENTHESIS}.}
+\endsetslot
+
+\nextslot{"77}
+\setslot{arrowdblvertex}
+ \Unicode{21D5}{UP DOWN DOUBLE ARROW}
+ \varchar
+ \vartop{arrowdbltp}
+ \varbot{arrowdblbt}
+ \varrep{arrowdblvertex}
+ \endvarchar
+ \comment{This slot contains the repeatable middle part of a vertical
+ double arrow.}
+\endsetslot
+
+
+
+
+
+\begincomment
+\section{Ordinary characters}
+\endcomment
+
+
+\begincomment
+\subsection{\texttt{Big} size delimiters}
+\endcomment
+
+\nextslot{16}
+\setslot{parenleftBig}
+ \Unicode{0028}{LEFT PARENTHESIS}
+ \nextlarger{parenleftbigg}
+\endsetslot
+
+\setslot{parenrightBig}
+ \Unicode{0029}{RIGHT PARENTHESIS}
+ \nextlarger{parenrightbigg}
+\endsetslot
+
+\nextslot{46}
+\setslot{slashBig}
+ \Unicode{2215}{DIVISION SLASH}
+ \nextlarger{slashbigg}
+\endsetslot
+
+\setslot{backslashBig}
+ \Unicode{005C}{REVERSE SOLIDUS}
+ \nextlarger{backslashbigg}
+\endsetslot
+
+\nextslot{"44}
+\setslot{angleleftBig}
+ \Unicode{2329}{LEFT-POINTING ANGLE BRACKET}
+ \nextlarger{angleleftbigg}
+\endsetslot
+
+\setslot{anglerightBig}
+ \Unicode{232A}{RIGHT-POINTING ANGLE BRACKET}
+ \nextlarger{anglerightbigg}
+\endsetslot
+
+\nextslot{"68}
+\setslot{bracketleftBig}
+ \Unicode{005B}{LEFT SQUARE BRACKET}
+ \nextlarger{bracketleftbigg}
+\endsetslot
+
+\setslot{bracketrightBig}
+ \Unicode{005D}{RIGHT SQUARE BRACKET}
+ \nextlarger{bracketrightbigg}
+\endsetslot
+
+\setslot{floorleftBig}
+ \Unicode{230A}{LEFT FLOOR}
+ \nextlarger{floorleftbigg}
+\endsetslot
+
+\setslot{floorrightBig}
+ \Unicode{230B}{RIGHT FLOOR}
+ \nextlarger{floorrightbigg}
+\endsetslot
+
+\setslot{ceilingleftBig}
+ \Unicode{2308}{LEFT CEILING}
+ \nextlarger{ceilingleftbigg}
+\endsetslot
+
+\setslot{ceilingrightBig}
+ \Unicode{2309}{RIGHT CEILING}
+ \nextlarger{ceilingrightbigg}
+\endsetslot
+
+\setslot{braceleftBig}
+ \Unicode{007B}{LEFT CURLY BRACKET}
+ \nextlarger{braceleftbigg}
+\endsetslot
+
+\setslot{bracerightBig}
+ \Unicode{007D}{RIGHT CURLY BRACKET}
+ \nextlarger{bracerightbigg}
+\endsetslot
+
+
+
+
+
+\begincomment
+\subsection{\texttt{bigg} size delimiters}
+\endcomment
+
+\nextslot{18}
+\setslot{parenleftbigg}
+ \Unicode{0028}{LEFT PARENTHESIS}
+ \nextlarger{parenleftBigg}
+\endsetslot
+
+\setslot{parenrightbigg}
+ \Unicode{0029}{RIGHT PARENTHESIS}
+ \nextlarger{parenrightBigg}
+\endsetslot
+
+\setslot{bracketleftbigg}
+ \Unicode{005B}{LEFT SQUARE BRACKET}
+ \nextlarger{bracketleftBigg}
+\endsetslot
+
+\setslot{bracketrightbigg}
+ \Unicode{005D}{RIGHT SQUARE BRACKET}
+ \nextlarger{bracketrightBigg}
+\endsetslot
+
+\setslot{floorleftbigg}
+ \Unicode{230A}{LEFT FLOOR}
+ \nextlarger{floorleftBigg}
+\endsetslot
+
+\setslot{floorrightbigg}
+ \Unicode{230B}{RIGHT FLOOR}
+ \nextlarger{floorrightBigg}
+\endsetslot
+
+\setslot{ceilingleftbigg}
+ \Unicode{2308}{LEFT CEILING}
+ \nextlarger{ceilingleftBigg}
+\endsetslot
+
+\setslot{ceilingrightbigg}
+ \Unicode{2309}{RIGHT CEILING}
+ \nextlarger{ceilingrightBigg}
+\endsetslot
+
+\setslot{braceleftbigg}
+ \Unicode{007B}{LEFT CURLY BRACKET}
+ \nextlarger{braceleftBigg}
+\endsetslot
+
+\setslot{bracerightbigg}
+ \Unicode{007D}{RIGHT CURLY BRACKET}
+ \nextlarger{bracerightBigg}
+\endsetslot
+
+\setslot{angleleftbigg}
+ \Unicode{2329}{LEFT-POINTING ANGLE BRACKET}
+ \nextlarger{angleleftBigg}
+\endsetslot
+
+\setslot{anglerightbigg}
+ \Unicode{232A}{RIGHT-POINTING ANGLE BRACKET}
+ \nextlarger{anglerightBigg}
+\endsetslot
+
+\setslot{slashbigg}
+ \Unicode{2215}{DIVISION SLASH}
+ \nextlarger{slashBigg}
+\endsetslot
+
+\setslot{backslashbigg}
+ \Unicode{005C}{REVERSE SOLIDUS}
+ \nextlarger{backslashBigg}
+\endsetslot
+
+
+
+\begincomment
+\subsection{\texttt{Bigg} size delimiters}
+\endcomment
+
+\nextslot{32}
+\setslot{parenleftBigg}
+ \Unicode{0028}{LEFT PARENTHESIS}
+ \nextlarger{parenlefttp}
+\endsetslot
+
+\setslot{parenrightBigg}
+ \Unicode{0029}{RIGHT PARENTHESIS}
+ \nextlarger{parenrighttp}
+\endsetslot
+
+\setslot{bracketleftBigg}
+ \Unicode{005B}{LEFT SQUARE BRACKET}
+ \nextlarger{bracketlefttp}
+\endsetslot
+
+\setslot{bracketrightBigg}
+ \Unicode{005D}{RIGHT SQUARE BRACKET}
+ \nextlarger{bracketrighttp}
+\endsetslot
+
+\setslot{floorleftBigg}
+ \Unicode{230A}{LEFT FLOOR}
+ \nextlarger{bracketleftbt}
+\endsetslot
+
+\setslot{floorrightBigg}
+ \Unicode{230B}{RIGHT FLOOR}
+ \nextlarger{bracketrightbt}
+\endsetslot
+
+\setslot{ceilingleftBigg}
+ \Unicode{2308}{LEFT CEILING}
+ \nextlarger{bracketleftex}
+\endsetslot
+
+\setslot{ceilingrightBigg}
+ \Unicode{2309}{RIGHT CEILING}
+ \nextlarger{bracketrightex}
+\endsetslot
+
+\setslot{braceleftBigg}
+ \Unicode{007B}{LEFT CURLY BRACKET}
+ \nextlarger{bracelefttp}
+\endsetslot
+
+\setslot{bracerightBigg}
+ \Unicode{007D}{RIGHT CURLY BRACKET}
+ \nextlarger{bracerighttp}
+\endsetslot
+
+\setslot{angleleftBigg}
+ \Unicode{2329}{LEFT-POINTING ANGLE BRACKET}
+\endsetslot
+
+\setslot{anglerightBigg}
+ \Unicode{232A}{RIGHT-POINTING ANGLE BRACKET}
+\endsetslot
+
+\setslot{slashBigg}
+ \Unicode{2215}{DIVISION SLASH}
+\endsetslot
+
+\setslot{backslashBigg}
+ \Unicode{005C}{REVERSE SOLIDUS}
+\endsetslot
+
+
+
+\begincomment
+\subsection{Extensible delimiters}
+\endcomment
+
+\nextslot{48}
+\setslot{parenlefttp}
+ \comment{This slot contains the curved top of a
+ \textunicode{0028}{LEFT PARENTHESIS}.}
+ \varchar
+ \vartop{parenlefttp}
+ \varrep{parenleftex}
+ \varbot{parenleftbt}
+ \endvarchar
+\endsetslot
+
+\setslot{parenrighttp}
+ \comment{This slot contains the curved top of a
+ \textunicode{0029}{RIGHT PARENTHESIS}.}
+ \varchar
+ \vartop{parenrighttp}
+ \varrep{parenrightex}
+ \varbot{parenrightbt}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketlefttp}
+ \comment{This slot contains the corner top of a
+ \textunicode{005B}{LEFT SQUARE BRACKET}.}
+ \varchar
+ \vartop{bracketlefttp}
+ \varrep{bracketleftex}
+ \varbot{bracketleftbt}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketrighttp}
+ \comment{This slot contains the corner top of a
+ \textunicode{005D}{RIGHT SQUARE BRACKET}.}
+ \varchar
+ \vartop{bracketrighttp}
+ \varrep{bracketrightex}
+ \varbot{bracketrightbt}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketleftbt}
+ \comment{This slot contains the corner bottom of a
+ \textunicode{005B}{LEFT SQUARE BRACKET}, but it serves as the
+ final slot in the chain of larger sizes of
+ \textunicode{230A}{LEFT FLOOR}.}
+ \varchar
+ \varrep{bracketleftex}
+ \varbot{bracketleftbt}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketrightbt}
+ \comment{This slot contains the corner bottom of a
+ \textunicode{005D}{RIGHT SQUARE BRACKET}, but it serves as the
+ final slot in the chain of larger sizes of
+ \textunicode{230B}{RIGHT FLOOR}.}
+ \varchar
+ \varrep{bracketrightex}
+ \varbot{bracketrightbt}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketleftex}
+ \comment{This slot contains the repeatable middle part of a
+ \textunicode{005B}{LEFT SQUARE BRACKET}, but it serves as the
+ final slot in the chain of larger sizes of
+ \textunicode{2308}{LEFT CEILING}.}
+ \varchar
+ \vartop{bracketlefttp}
+ \varrep{bracketleftex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketrightex}
+ \comment{This slot contains the repeatable middle part of a
+ \textunicode{005D}{RIGHT SQUARE BRACKET}, but it serves as the
+ final slot in the chain of larger sizes of
+ \textunicode{2309}{RIGHT CEILING}.}
+ \varchar
+ \vartop{bracketrighttp}
+ \varrep{bracketrightex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracelefttp}
+ \comment{This slot contains the curved top of a
+ \textunicode{007B}{LEFT CURLY BRACKET}.}
+ \label{bracelefttp}
+ \varchar
+ \vartop{bracelefttp}
+ \varrep{braceex}
+ \varmid{braceleftmid}
+ \varbot{braceleftbt}
+ \endvarchar
+\endsetslot
+
+\setslot{bracerighttp}
+ \comment{This slot contains the curved top of a
+ \textunicode{007D}{RIGHT CURLY BRACKET}.}
+ \label{bracerighttp}
+ \varchar
+ \vartop{bracerighttp}
+ \varrep{braceex}
+ \varmid{bracerightmid}
+ \varbot{bracerightbt}
+ \endvarchar
+\endsetslot
+
+
+
+
+
+\begincomment
+\subsection{Display style operators}
+\endcomment
+
+\nextslot{"47}
+\setslot{unionsqdisplay}
+ \Unicode{2294}{SQUARE CUP}
+\endsetslot
+
+\skipslots{1}
+\setslot{contintegraldisplay}
+ \Unicode{222E}{CONTOUR INTEGRAL}
+\endsetslot
+
+\skipslots{1}
+\setslot{circledotdisplay}
+ \Unicode{2299}{CIRCLED DOT OPERATOR}
+\endsetslot
+
+\skipslots{1}
+\setslot{circleplusdisplay}
+ \Unicode{2295}{CIRCLED PLUS}
+\endsetslot
+
+\skipslots{1}
+\setslot{circlemultiplydisplay}
+ \Unicode{2297}{CIRCLED TIMES}
+\endsetslot
+
+\skipslots{8}
+\setslot{summationdisplay}
+ \Unicode{2211}{N-ARY SUMMATION}
+\endsetslot
+
+\setslot{productdisplay}
+ \Unicode{220F}{N-ARY PRODUCT}
+\endsetslot
+
+\setslot{integraldisplay}
+ \Unicode{222B}{INTEGRAL}
+\endsetslot
+
+\setslot{uniondisplay}
+ \Unicode{22C3}{N-ARY UNION}
+\endsetslot
+
+\setslot{intersectiondisplay}
+ \Unicode{22C2}{N-ARY INTERSECTION}
+\endsetslot
+
+\setslot{unionmultidisplay}
+ \Unicode{228E}{MULTISET UNION}
+\endsetslot
+
+\setslot{logicalanddisplay}
+ \Unicode{22C0}{N-ARY LOGICAL AND}
+\endsetslot
+
+\setslot{logicalordisplay}
+ \Unicode{22C1}{N-ARY LOGICAL OR}
+\endsetslot
+
+\skipslots{1}
+\setslot{coproductdisplay}
+ \Unicode{2210}{N-ARY COPRODUCT}
+\endsetslot
+
+
+
+\begincomment
+\subsection{Accents}
+\endcomment
+
+\nextslot{"63}
+\setslot{hatwider}
+ \Unicode{0302}{COMBINING CIRCUMFLEX ACCENT}
+ \nextlarger{hatwiderr}
+\endsetslot
+
+\setslot{hatwiderr}
+ \Unicode{0302}{COMBINING CIRCUMFLEX ACCENT}
+\endsetslot
+
+\skipslots{1}
+
+\setslot{tildewider}
+ \Unicode{0303}{COMBINING TILDE}
+ \nextlarger{tildewiderr}
+\endsetslot
+
+\setslot{tildewiderr}
+ \Unicode{0303}{COMBINING TILDE}
+\endsetslot
+
+
+\begincomment
+\subsection{Radicals}
+\endcomment
+
+\nextslot{"71}
+\setslot{radicalBig}
+ \Unicode{221A}{SQUARE ROOT}
+ \nextlarger{radicalbigg}
+\endsetslot
+
+\setslot{radicalbigg}
+ \Unicode{221A}{SQUARE ROOT}
+ \nextlarger{radicalBigg}
+\endsetslot
+
+\setslot{radicalBigg}
+ \Unicode{221A}{SQUARE ROOT}
+ \nextlarger{radicalbt}
+\endsetslot
+
+\setslot{radicalbt}
+ \Unicode{221A}{SQUARE ROOT}
+ \varchar
+ \varbot{radicalbt}
+ \vartop{radicaltp}
+ \varrep{radicalvertex}
+ \endvarchar
+\endsetslot
+
+\setslot{radicalvertex}
+ \comment{This is the repeatable, vertically middle part of an
+ extensible \textunicode{221A}{SQUARE ROOT}.}
+\endsetslot
+
+\setslot{radicaltp}
+ \comment{This is the top corner part of an extensible
+ \textunicode{221A}{SQUARE ROOT}.}
+\endsetslot
+
+
+
+
+
+\begincomment
+\section{Fontdimens and codingscheme}
+
+\texttt{OMX} fonts have the necessary fontdimens to serve as a math
+group 3 font.
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+\setfontdimen{8}{defaultrulethickness} % default rule thickness
+\setfontdimen{9}{bigopspacing1} % bigopspacing 1
+\setfontdimen{10}{bigopspacing2} % bigopspacing 2
+\setfontdimen{11}{bigopspacing3} % bigopspacing 3
+\setfontdimen{12}{bigopspacing4} % bigopspacing 4
+\setfontdimen{13}{bigopspacing5} % bigopspacing 5
+
+\setstr{codingscheme}{TEX MATH EXTENSION}
+
+
+
+
+
+\endencoding
+
+
+\section{Discussion}
+
+
+
+\end{document}
diff --git a/fonts/utilities/fontinst/doc/encspecs/ot1draft.etx b/fonts/utilities/fontinst/doc/encspecs/ot1draft.etx
new file mode 100644
index 0000000000..6f07bbd6f4
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/encspecs/ot1draft.etx
@@ -0,0 +1,1027 @@
+\relax
+\documentclass[twocolumn]{article}
+\usepackage[specification]{fontdoc}[2004/11/28]
+
+\DeclareRobustCommand\cs[1]{\texttt{\char`\\#1}}
+
+\showbranches
+
+\begin{document}
+
+\title{\texttt{OT1} encoding draft specification}
+\author{Lars Hellstr\"om}
+\date{2004/12/16}
+\maketitle
+
+\begin{abstract}
+ The \texttt{OT1} encoding is an attempt to describe the encoding of
+ the text fonts in Donald~E.~Knuth's \emph{Computer Modern} family
+ of fonts~\cite{ComputerModern}. This is an impossibile goal, since
+ these fonts present no less than five different encodings, but they
+ are nontheless largely treated by \LaTeX\ as having identical
+ encodings. Due to the ambiguities this creates, and in view of that
+ the \texttt{T1} encoding supersedes \texttt{OT1} as text font
+ encoding, there is little point in using the text commands for
+ distiguishing mandatory features of \texttt{OT1} from the ordinary.
+
+ \texttt{OT1} is however also used as a math font encoding (to go
+ with \texttt{OML}, \texttt{OMS}, and \texttt{OMX}), and that use is
+ today the by far most important since there is no obvious alternative
+ to the standard math font set-up. Therefore this specification
+ considers a feature of the encoding to be mandatory if it is
+ (i)~necessary for the standard math set-up or (ii)~is a text feature
+ which works for all encoding variants.
+\end{abstract}
+
+\encoding
+\needsfontinstversion{1.928}
+
+
+
+\begincomment
+\section{Encoding variants}
+
+This document aims to record all the encoding variations that are
+present within the set of fonts classified by \LaTeX\ as having the
+\texttt{OT1} encoding. It turns out that they can all be described
+using only two parameters. One of these might be called
+`\textit{ligaturing}' as one factor it affects is how many ligatures
+there will be in the font. The other parameter is best called
+`\textit{italicizing}' as it is different between italic and
+non-italic fonts. Most of the Computer Modern fonts have
+\(\mathit{ligaturing} = 2\) and \(\mathit{italicizing} = 0\).
+
+\endcomment
+\setint{ligaturing}{2}
+\setint{italicizing}{0}
+
+
+\begincomment
+
+
+\section{Mandatory characters}
+
+\subsection{Latin letters}
+\endcomment
+
+\nextslot{16}
+\setslot{dotlessi}
+ \Unicode{0131}{LATIN SMALL LETTER DOTLESS I}
+ \comment{A dotless i `\i', used to produce accented letters such as
+ `\=\i'. It is not used for math.}
+\endsetslot
+
+\setslot{dotlessj}
+ \Unicode{F6BE}{LATIN SMALL LETTER DOTLESS J}
+ \comment{A dotless j `\j', used to produce accented letters such as
+ `\=\j'. It is not used for math. The Unicode standard does not
+ define this character, but Adobe has assigned code point
+ \texttt{U+F6BE} (which is in the private use subarea assigned by
+ Adobe) to it.}
+\endsetslot
+
+\nextslot{25}
+\setslot{germandbls}
+ \Unicode{00DF}{LATIN SMALL LETTER SHARP S}
+ \comment{This slot is not used in math.}
+\endsetslot
+
+\setslot{ae}
+ \Unicode{00E6}{LATIN SMALL LETTER AE}
+ \comment{This slot is not used in math.}
+\endsetslot
+
+\setslot{oe}
+ \Unicode{0153}{LATIN SMALL LIGATURE OE}
+ \comment{This is a single letter, and should not be faked with `oe'.
+ It is not used in math.}
+\endsetslot
+
+\setslot{oslash}
+ \Unicode{00F8}{LATIN SMALL LETTER O WITH STROKE}
+ \comment{This slot is not used in math.}
+\endsetslot
+
+\setslot{AE}
+ \Unicode{00C6}{LATIN CAPITAL LETTER AE}
+ \comment{This slot is not used in math.}
+\endsetslot
+
+\setslot{OE}
+ \Unicode{0152}{LATIN CAPITAL LIGATURE OE}
+ \comment{This is a single letter, and should not be faked with
+ `OE'. It is not used in math.}
+\endsetslot
+
+\setslot{Oslash}
+ \Unicode{00D8}{LATIN CAPITAL LETTER O WITH STROKE}
+ \comment{This slot is not used in math.}
+\endsetslot
+
+
+\nextslot{65}
+\setslot{A}
+ \Unicode{0041}{LATIN CAPITAL LETTER A}
+ \label{A}
+\endsetslot
+
+\setslot{B}
+ \Unicode{0042}{LATIN CAPITAL LETTER B}
+\endsetslot
+
+\setslot{C}
+ \Unicode{0043}{LATIN CAPITAL LETTER C}
+\endsetslot
+
+\setslot{D}
+ \Unicode{0044}{LATIN CAPITAL LETTER D}
+\endsetslot
+
+\setslot{E}
+ \Unicode{0045}{LATIN CAPITAL LETTER E}
+\endsetslot
+
+\setslot{F}
+ \Unicode{0046}{LATIN CAPITAL LETTER F}
+\endsetslot
+
+\setslot{G}
+ \Unicode{0047}{LATIN CAPITAL LETTER G}
+\endsetslot
+
+\setslot{H}
+ \Unicode{0048}{LATIN CAPITAL LETTER H}
+\endsetslot
+
+\setslot{I}
+ \Unicode{0049}{LATIN CAPITAL LETTER I}
+\endsetslot
+
+\setslot{J}
+ \Unicode{004A}{LATIN CAPITAL LETTER J}
+\endsetslot
+
+\setslot{K}
+ \Unicode{004B}{LATIN CAPITAL LETTER K}
+\endsetslot
+
+\setslot{L}
+ \Unicode{004C}{LATIN CAPITAL LETTER L}
+\endsetslot
+
+\setslot{M}
+ \Unicode{004D}{LATIN CAPITAL LETTER M}
+\endsetslot
+
+\setslot{N}
+ \Unicode{004E}{LATIN CAPITAL LETTER N}
+\endsetslot
+
+\setslot{O}
+ \Unicode{004F}{LATIN CAPITAL LETTER O}
+\endsetslot
+
+\setslot{P}
+ \Unicode{0050}{LATIN CAPITAL LETTER P}
+\endsetslot
+
+\setslot{Q}
+ \Unicode{0051}{LATIN CAPITAL LETTER Q}
+\endsetslot
+
+\setslot{R}
+ \Unicode{0052}{LATIN CAPITAL LETTER R}
+\endsetslot
+
+\setslot{S}
+ \Unicode{0053}{LATIN CAPITAL LETTER S}
+\endsetslot
+
+\setslot{T}
+ \Unicode{0054}{LATIN CAPITAL LETTER T}
+\endsetslot
+
+\setslot{U}
+ \Unicode{0055}{LATIN CAPITAL LETTER U}
+\endsetslot
+
+\setslot{V}
+ \Unicode{0056}{LATIN CAPITAL LETTER V}
+\endsetslot
+
+\setslot{W}
+ \Unicode{0057}{LATIN CAPITAL LETTER W}
+\endsetslot
+
+\setslot{X}
+ \Unicode{0058}{LATIN CAPITAL LETTER X}
+\endsetslot
+
+\setslot{Y}
+ \Unicode{0059}{LATIN CAPITAL LETTER Y}
+ \label{Y}
+\endsetslot
+
+\setslot{Z}
+ \Unicode{005A}{LATIN CAPITAL LETTER Z}
+\endsetslot
+
+
+\nextslot{97}
+\setslot{a}
+ \Unicode{0061}{LATIN SMALL LETTER A}
+\endsetslot
+
+\setslot{b}
+ \Unicode{0062}{LATIN SMALL LETTER B}
+\endsetslot
+
+\setslot{c}
+ \Unicode{0063}{LATIN SMALL LETTER C}
+\endsetslot
+
+\setslot{d}
+ \Unicode{0064}{LATIN SMALL LETTER D}
+\endsetslot
+
+\setslot{e}
+ \Unicode{0065}{LATIN SMALL LETTER E}
+\endsetslot
+
+\setslot{f}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \ifnumber{\int{ligaturing}}={2}\then
+ \ligature{LIG}{f}{ff}
+ \ligature{LIG}{i}{fi}
+ \ligature{LIG}{l}{fl}
+ \Fi
+\endsetslot
+
+\setslot{g}
+ \Unicode{0067}{LATIN SMALL LETTER G}
+\endsetslot
+
+\setslot{h}
+ \Unicode{0068}{LATIN SMALL LETTER H}
+\endsetslot
+
+\setslot{i}
+ \Unicode{0069}{LATIN SMALL LETTER I}
+\endsetslot
+
+\setslot{j}
+ \Unicode{006A}{LATIN SMALL LETTER J}
+\endsetslot
+
+\setslot{k}
+ \Unicode{006B}{LATIN SMALL LETTER K}
+\endsetslot
+
+\setslot{l}
+ \Unicode{006C}{LATIN SMALL LETTER L}
+\endsetslot
+
+\setslot{m}
+ \Unicode{006D}{LATIN SMALL LETTER M}
+\endsetslot
+
+\setslot{n}
+ \Unicode{006E}{LATIN SMALL LETTER N}
+\endsetslot
+
+\setslot{o}
+ \Unicode{006F}{LATIN SMALL LETTER O}
+\endsetslot
+
+\setslot{p}
+ \Unicode{0070}{LATIN SMALL LETTER P}
+\endsetslot
+
+\setslot{q}
+ \Unicode{0071}{LATIN SMALL LETTER Q}
+\endsetslot
+
+\setslot{r}
+ \Unicode{0072}{LATIN SMALL LETTER R}
+\endsetslot
+
+\setslot{s}
+ \Unicode{0073}{LATIN SMALL LETTER S}
+\endsetslot
+
+\setslot{t}
+ \Unicode{0074}{LATIN SMALL LETTER T}
+\endsetslot
+
+\setslot{u}
+ \Unicode{0075}{LATIN SMALL LETTER U}
+\endsetslot
+
+\setslot{v}
+ \Unicode{0076}{LATIN SMALL LETTER V}
+\endsetslot
+
+\setslot{w}
+ \Unicode{0077}{LATIN SMALL LETTER W}
+\endsetslot
+
+\setslot{x}
+ \Unicode{0078}{LATIN SMALL LETTER X}
+\endsetslot
+
+\setslot{y}
+ \Unicode{0079}{LATIN SMALL LETTER Y}
+\endsetslot
+
+\setslot{z}
+ \Unicode{007A}{LATIN SMALL LETTER Z}
+\endsetslot
+
+
+\begincomment
+\subsection{Greek letters}
+\endcomment
+
+\nextslot{0}
+\setslot{Gamma}
+ \Unicode{0393}{GREEK CAPITAL LETTER GAMMA}
+\endsetslot
+
+\setslot{Delta}
+ \Unicode{0394}{GREEK CAPITAL LETTER DELTA}
+\endsetslot
+
+\setslot{Theta}
+ \Unicode{0398}{GREEK CAPITAL LETTER THETA}
+\endsetslot
+
+\setslot{Lambda}
+ \Unicode{039B}{GREEK CAPITAL LETTER LAMBDA}
+ % Unicode's preferred name for this character seems to be
+ % GREEK CAPITAL LETTER LAMDA, i.e., without the `B'. Why?
+ % GREEK CAPITAL LETTER LAMBDA is listed as an alternative name.
+\endsetslot
+
+\setslot{Xi}
+ \Unicode{039E}{GREEK CAPITAL LETTER XI}
+\endsetslot
+
+\setslot{Pi}
+ \Unicode{03A0}{GREEK CAPITAL LETTER PI}
+\endsetslot
+
+\setslot{Sigma}
+ \Unicode{03A3}{GREEK CAPITAL LETTER SIGMA}
+\endsetslot
+
+\setslot{Upsilon1}
+ \Unicode{03D2}{GREEK UPSILON WITH HOOK SYMBOL}
+ \comment{This is primarily a math character and it is should
+ be visually distinct from the character in slot~\ref{Y}. This is
+ not generally the case for the normal Upsilon
+ \textunicode{03A5}{GREEK CAPITAL LETTER UPSILON}, which is by
+ the way what usually has the glyph name \texttt{Upsilon}.
+ An argument for the latter is however that all the purely
+ mathematical Upsilons that exist in the Unicode standard are
+ described as variants of the non-hook character.}
+\endsetslot
+
+\setslot{Phi}
+ \Unicode{03A6}{GREEK CAPITAL LETTER PHI}
+\endsetslot
+
+\setslot{Psi}
+ \Unicode{03A8}{GREEK CAPITAL LETTER PSI}
+\endsetslot
+
+\setslot{Omega}
+ \Unicode{03A9}{GREEK CAPITAL LETTER OMEGA}
+\endsetslot
+
+
+\begincomment
+\subsection{Digits}
+\endcomment
+
+\nextslot{48}
+\setslot{zero}
+ \Unicode{0030}{DIGIT ZERO}
+\endsetslot
+
+\setslot{one}
+ \Unicode{0031}{DIGIT ONE}
+\endsetslot
+
+\setslot{two}
+ \Unicode{0032}{DIGIT TWO}
+\endsetslot
+
+\setslot{three}
+ \Unicode{0033}{DIGIT THREE}
+\endsetslot
+
+\setslot{four}
+ \Unicode{0034}{DIGIT FOUR}
+\endsetslot
+
+\setslot{five}
+ \Unicode{0035}{DIGIT FIVE}
+\endsetslot
+
+\setslot{six}
+ \Unicode{0036}{DIGIT SIX}
+\endsetslot
+
+\setslot{seven}
+ \Unicode{0037}{DIGIT SEVEN}
+\endsetslot
+
+\setslot{eight}
+ \Unicode{0038}{DIGIT EIGHT}
+\endsetslot
+
+\setslot{nine}
+ \Unicode{0039}{DIGIT NINE}
+\endsetslot
+
+
+\begincomment
+\subsection{Accents}
+\endcomment
+
+\nextslot{18}
+\setslot{grave}
+ \Unicode{0300}{COMBINING GRAVE ACCENT}
+\endsetslot
+
+\setslot{acute}
+ \Unicode{0301}{COMBINING ACUTE ACCENT}
+\endsetslot
+
+\setslot{caron}
+ \Unicode{030C}{COMBINING CARON}
+ \comment{The caron or h\'a\v cek accent `\v{}'.}
+\endsetslot
+
+\setslot{breve}
+ \Unicode{0306}{COMBINING BREVE}
+\endsetslot
+
+\setslot{macron}
+ \Unicode{0304}{COMBINING MACRON}
+\endsetslot
+
+\setslot{ring}
+ \Unicode{030A}{COMBINING RING ABOVE}
+ \comment{The text definition of `\verb|\r{A}|' assumes that this
+ glyph has the same width as that in slot~\ref{A}.}
+\endsetslot
+
+\setslot{cedilla}
+ \Unicode{0327}{COMBINING CEDILLA}
+ \comment{This slot is not required for math, but is used by
+ the \cs{c} \LaTeX\ command.}
+\endsetslot
+
+
+\nextslot{94}
+\setslot{circumflex}
+ \Unicode{0302}{COMBINING CIRCUMFLEX ACCENT}
+ \Unicode{005E}{CIRCUMFLEX ACCENT}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{dotaccent}
+ \Unicode{0307}{COMBINING DOT ABOVE}
+ \label{dotaccent}
+\endsetslot
+
+\begincomment
+\par\medskip
+Note that the \(\mathit{ligaturing} = 0\) assignment to
+slot~\ref{underscore} is ordinary, not mandatory.
+\endcomment
+
+\Fi
+
+
+\nextslot{126}
+\setslot{tilde}
+ \Unicode{0303}{COMBINING TILDE}
+ \Unicode{007E}{TILDE}
+\endsetslot
+
+\setslot{dieresis}
+ \Unicode{0308}{COMBINING DIAERESIS}
+\endsetslot
+
+
+\begincomment
+\subsection{Symbols}
+\endcomment
+
+\nextslot{33}
+\setslot{exclam}
+ \Unicode{0021}{EXCLAMATION MARK}
+ \Ligature{LIG}{quoteleft}{exclamdown}
+\endsetslot
+
+\skipslots{1}
+
+\setslot{numbersign}
+ \Unicode{0023}{NUMBER SIGN}
+ \comment{This slot is not used for math.}
+\endsetslot
+
+\ifnumber{\int{italicizing}}={0}\then
+
+\setslot{dollar}
+ \Unicode{0024}{DOLLAR SIGN}
+\endsetslot
+
+\Else
+
+\setslot{sterling}
+ \Unicode{00A3}{POUND SIGN}
+\endsetslot
+
+\Fi
+
+\setslot{percent}
+ \Unicode{0025}{PERCENT SIGN}
+ \comment{This slot is not used for math.}
+\endsetslot
+
+\setslot{ampersand}
+ \Unicode{0026}{AMPERSAND}
+ \comment{This slot is not used for math.}
+\endsetslot
+
+\setslot{quoteright}
+ \Unicode{2019}{RIGHT SINGLE QUOTATION MARK}
+ \comment{This slot is not used for math.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \Ligature{LIG}{quoteright}{quotedblright}
+ \Fi
+\endsetslot
+
+\setslot{parenleft}
+ \Unicode{0028}{LEFT PARENTHESIS}
+\endsetslot
+
+\setslot{parenright}
+ \Unicode{0029}{RIGHT PARENTHESIS}
+\endsetslot
+
+\setslot{asterisk}
+ \Unicode{002A}{ASTERISK}
+ \comment{This slot is not used for math.}
+\endsetslot
+
+\setslot{plus}
+ \Unicode{002B}{PLUS SIGN}
+\endsetslot
+
+\setslot{comma}
+ \Unicode{002C}{COMMA}
+ \comment{This slot is not used for math.}
+\endsetslot
+
+\setslot{hyphen}
+ \Unicode{002D}{HYPHEN-MINUS}
+ \comment{This slot is not used for math.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \Ligature{LIG}{hyphen}{endash}
+ \Fi
+\endsetslot
+
+\setslot{period}
+ \Unicode{002E}{FULL STOP}
+ \comment{This slot is not used for math.}
+\endsetslot
+
+\setslot{slash}
+ \Unicode{002F}{SOLIDUS}
+\endsetslot
+
+\nextslot{58}
+\setslot{colon}
+ \Unicode{003A}{COLON}
+\endsetslot
+
+\setslot{semicolon}
+ \Unicode{003B}{SEMICOLON}
+\endsetslot
+
+\skipslots{1}
+
+\setslot{equal}
+ \Unicode{003D}{EQUALS SIGN}
+\endsetslot
+
+\skipslots{1}
+
+\setslot{question}
+ \Unicode{003F}{QUESTION MARK}
+ \Ligature{LIG}{quoteleft}{questiondown}
+\endsetslot
+
+\setslot{at}
+ \Unicode{0040}{COMMERCIAL AT}
+ \comment{This slot is not used for math.}
+\endsetslot
+
+\nextslot{91}
+\setslot{bracketleft}
+ \Unicode{005B}{LEFT SQUARE BRACKET}
+\endsetslot
+
+\skipslots{1}
+
+\setslot{bracketright}
+ \Unicode{005D}{RIGHT SQUARE BRACKET}
+\endsetslot
+
+\nextslot{96}
+\setslot{quoteleft}
+ \Unicode{2018}{LEFT SINGLE QUOTATION MARK}
+ \comment{This slot is not used for math.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \Ligature{LIG}{quoteleft}{quotedblleft}
+ \Fi
+\endsetslot
+
+
+
+\begincomment
+\section{Ordinary characters}
+
+\subsection{Letters}
+\endcomment
+
+\ifnumber{\int{ligaturing}}={2}\then
+
+\nextslot{11}
+\setslot{ff}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ }
+ \comment{This glyph should be two characters wide in a monowidth
+ font.}
+ \ligature{LIG}{i}{ffi}
+ \ligature{LIG}{l}{ffl}
+\endsetslot
+
+\setslot{fi}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0069}{LATIN SMALL LETTER I}
+ }
+ \comment{This glyph should be two characters wide in a monowidth
+ font.}
+\endsetslot
+
+\setslot{fl}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{006C}{LATIN SMALL LETTER L}
+ }
+ \comment{This glyph should be two characters wide in a monowidth
+ font.}
+\endsetslot
+
+\setslot{ffi}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0069}{LATIN SMALL LETTER I}
+ }
+ \comment{This glyph should be three characters wide in a monowidth
+ font.}
+\endsetslot
+
+\setslot{ffl}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{006C}{LATIN SMALL LETTER L}
+ }
+ \comment{This glyph should be three characters wide in a monowidth
+ font.}
+\endsetslot
+
+\Fi
+
+\nextslot{"8A}
+\setslot{Lslash}
+ \Unicode{0141}{LATIN CAPITAL LETTER L WITH STROKE}
+ \comment{The letter `\L'.}
+\endsetslot
+
+\nextslot{"AA}
+\setslot{lslash}
+ \Unicode{0142}{LATIN SMALL LETTER L WITH STROKE}
+ \comment{The letter `\l'.}
+\endsetslot
+
+
+\begincomment
+\subsection{Accents}
+\endcomment
+
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\nextslot{125}
+\setslot{hungarumlaut}
+ \Unicode{030B}{COMBINING DOUBLE ACUTE ACCENT}
+ \comment{The long Hungarian umlaut `\H{}'.}
+\endsetslot
+
+\Fi
+
+\begincomment
+\subsection{Symbols}
+\endcomment
+
+\ifnumber{\int{ligaturing}}<{2}\then
+
+\nextslot{11}
+\setslot{arrowup}
+ \Unicode{2191}{UPWARDS ARROW}
+\endsetslot
+
+\setslot{arrowdown}
+ \Unicode{2193}{DOWNWARDS ARROW}
+\endsetslot
+
+\setslot{quotesingle}
+ \Unicode{0027}{APOSTROPHE}
+\endsetslot
+
+\setslot{exclamdown}
+ \Unicode{00A1}{INVERTED EXCLAMATION MARK}
+\endsetslot
+
+\setslot{questiondown}
+ \Unicode{00BF}{INVERTED QUESTION MARK}
+\endsetslot
+
+\Fi
+
+\nextslot{32}
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{lslashslash}
+ \comment{When this character is followed by
+ \textunicode{004C}{LATIN CAPITAL LETTER L} then the combined
+ result is \textunicode{0141}{LATIN CAPITAL LETTER L WITH STROKE};
+ this is used by the \cs{L} command. When this character is
+ followed by \textunicode{006C}{LATIN SMALL LETTER L} then the
+ combined result is \textunicode{0142}{LATIN SMALL LETTER L WITH
+ STROKE}; this is used by the \cs{l} command. There are no further
+ semantics for this character.}
+ \ligature{LIG}{L}{Lslash}
+ \ligature{LIG}{l}{lslash}
+ \comment{These ligatures, and the characters they point to, were
+ added by Alan Jeffrey early in \textsf{fontinst} development in
+ order to allow the character in this slot to exhibit the correct
+ behaviour even in fonts where there is no corresponding glyph.}
+\endsetslot
+
+\Else
+
+\setslot{visiblespace}
+ \Unicode{2423}{OPEN BOX}
+ \comment{A visible space glyph `\textvisiblespace'.}
+\endsetslot
+
+\Fi
+
+
+\nextslot{34}
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{quotedblright}
+ \Unicode{201D}{RIGHT DOUBLE QUOTATION MARK}
+\endsetslot
+
+\Else
+
+\setslot{quotedbl}
+ \Unicode{0022}{QUOTATION MARK}
+\endsetslot
+
+\Fi
+
+\nextslot{60}
+\ifnumber{\int{ligaturing}}={2}\then
+
+\setslot{exclamdown}
+ \Unicode{00A1}{INVERTED EXCLAMATION MARK}
+\endsetslot
+
+\skipslots{1}
+
+\setslot{questiondown}
+ \Unicode{00BF}{INVERTED QUESTION MARK}
+\endsetslot
+
+\Else
+
+\setslot{less}
+ \Unicode{003C}{LESS-THAN SIGN}
+\endsetslot
+
+\skipslots{1}
+
+\setslot{greater}
+ \Unicode{003E}{GREATER-THAN SIGN}
+\endsetslot
+
+\Fi
+
+\nextslot{92}
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{quotedblleft}
+ \Unicode{201C}{LEFT DOUBLE QUOTATION MARK}
+\endsetslot
+
+\Else
+
+\setslot{backslash}
+ \Unicode{005C}{REVERSE SOLIDUS}
+\endsetslot
+
+\nextslot{95}
+\setslot{underscore}
+ \Unicode{005F}{LOW LINE}
+ \label{underscore}
+\endsetslot
+
+\begincomment
+\par\medskip
+Note that the \(\mathit{ligaturing} > 0\) assignment to
+slot~\ref{dotaccent} is mandatory, not ordinary.
+\endcomment
+
+\Fi
+
+
+\nextslot{123}
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{endash}
+ \Unicode{2013}{EN DASH}
+ \Ligature{LIG}{hyphen}{emdash}
+\endsetslot
+
+\setslot{emdash}
+ \Unicode{2014}{EM DASH}
+ \comment{In a monowidth font this character is preferably given the
+ width of two normal characters.}
+\endsetslot
+
+\Else
+
+\setslot{braceleft}
+ \Unicode{007B}{LEFT CURLY BRACKET}
+\endsetslot
+
+\setslot{bar}
+ \Unicode{007C}{VERTICAL LINE}
+\endsetslot
+
+\setslot{braceright}
+ \Unicode{007D}{RIGHT CURLY BRACKET}
+\endsetslot
+
+\Fi
+
+
+\begincomment
+\section{Fontdimens}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+
+\begincomment
+\section{Coding scheme}
+\endcomment
+
+\ifnumber{\int{ligaturing}}={2}\then
+
+\setstr{codingscheme}{TEX TEXT}
+
+\Else\ifnumber{\int{ligaturing}}={1}\then
+
+\setstr{codingscheme}{TEX TEXT WITHOUT F-LIGATURES}
+
+\Else
+
+\setstr{codingscheme}{TEX TYPEWRITER TEXT}
+
+\Fi\Fi
+
+
+\endencoding
+
+
+\section{Discussion}
+
+
+\subsection{\texttt{OT1} as math font encoding}
+
+As source for the math requirements on the \texttt{OT1} encoding
+was used the standard \LaTeX\ math set-up~\cite{fontdef}. Those
+definitions that make use of \texttt{OT1} fonts either use the
+\texttt{operators} symbol font\slash font family~0 or have math
+class~7 (\cs{mathalpha}).
+
+There are two slots used for math that have different assignments
+in different encoding variants. Slot 36 (\texttt{dollar}\slash
+\texttt{sterling}) depends on the $\mathit{italicizing}$, and is used
+by the commands \cs{mathdollar} (called by \verb|\$|) and
+\cs{mathsterling} (called by \cs{pounds}). This works because these
+commands explicitly take the character from a font with the correct
+$\mathit{italicizing}$.
+
+Slot~95 (\texttt{dotaccent}\slash \texttt{underline}) depends on the
+$\mathit{ligaturing}$ and is used by the \cs{dot} command. This
+command does \emph{not} work for fonts with \(\mathit{ligaturing}=0\),
+and hence e.g.\ the formula \verb|$\mathtt{\dot{x}}$| does not produce
+a typewriter dotted `x', but rather an `x' and underscore printed on
+top of each other. This is thus an error, but due to that it is
+unlikely that the error will be missed by the author who encounters
+it, the error is probably harmless.
+
+
+\subsection{\texttt{OT1} as text font encoding}
+
+The sources used to determine the text requirements on the
+\texttt{OT1} encoding were~\cite{ltoutenc}.
+
+It turns out that there are LICR commands which rely on non-mandatory
+features of the font. It is mostly for the \(\mathit{ligaturing} = 0\)
+fonts that commands produce incorrect results. The following commands
+work with all \texttt{OT1} fonts which have \(\mathit{ligaturing} > 0\)
+but fail with the others: \cs{L}, \cs{l}, \cs{.}, \cs{H},
+\cs{textemdash}, \cs{textendash}, and \cs{textquotedblleft}.
+In addition, the command \cs{textquotedblright} produces a
+reasonable, but not exactly correct, result.
+
+Traditionally the \cs{textexclamdown} and \cs{textquestiondown} have
+only worked for fonts which have \(\mathit{ligaturing} = 2\), but
+that can be fixed; see~\cite{latex/3368}.
+
+
+\section{Changes}
+
+The changes made to this specification since the original 2001/09/09
+version are as follows.
+
+2004/12/16: Changed the f-ligatures to character sequences, which
+makes more sense for \texttt{CMap}s. Incremented needed versions
+accordingly. /LH
+
+
+\begin{thebibliography}{9}
+\bibitem{ltoutenc}
+ Johannes Braams, David Carlisle, Alan Jeffrey, Frank Mittelbach,
+ Chris Rowley, and Rainer Sch\"opf:
+ \textit{ltoutenc.dtx}, v\,1.91 (2000);
+ the file \texttt{ltoutenc.dtx} in the \LaTeX\ base distribution.
+\bibitem{latex/3368}
+ Lars Hellstr\"om:
+ \textit{\texttt{OT1} def.\ of \cs{textexclamdown} and
+ \cs{textquestiondown}}, \LaTeX\ bugs database entry
+ \textbf{latex/3368}, 2001.
+% ; \textsc{http:}/\slash \texttt{www.latex-project.org}\slash
+% \texttt{cgi-bin}\slash \texttt{ltxbugs2html\discretionary{?}{}{?}%
+% pr=latex/3368}.
+\bibitem{ComputerModern}
+ Donald E. Knuth:
+ \textit{Computer Modern Typefaces},
+ volume E of \textit{Computers \& Typesetting},
+ Ad\-di\-son--Wes\-ley, 1986, xvi+588\,pp.;
+ ISBN~0-201-13446-2.
+\bibitem{fontdef}
+ Frank Mittelbach and Rainer Sch\"opf:
+ \textit{The \texttt{fontdef.dtx} file}, v\,2.2x (1999);
+ the file \texttt{fontdef.dtx} in the \LaTeX\ base distribution.
+\end{thebibliography}
+
+
+\end{document}
+
+
+
diff --git a/fonts/utilities/fontinst/doc/encspecs/t1draft.etx b/fonts/utilities/fontinst/doc/encspecs/t1draft.etx
new file mode 100644
index 0000000000..d82c9e53ed
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/encspecs/t1draft.etx
@@ -0,0 +1,1484 @@
+\relax
+\documentclass[twocolumn]{article}
+\usepackage[specification]{fontdoc}[2004/11/28]
+\usepackage{shortvrb}
+
+\MakeShortVerb{\|}
+
+\begin{document}
+\title{\texttt{T1} encoding draft specification}
+\author{Lars Hellstr\"om}
+\date{2002/07/05}
+\maketitle
+
+\begin{abstract}
+ The \texttt{T1} encoding covers most\footnote{But not quite all.}
+ letters in the latin script that are used in European languages.
+ Code points 32--126 coincide with ASCII\footnote{As defined in
+ Appendix C of \emph{The \TeX book}~\cite{TeXbook}, not as defined
+ by the ANSI.} and code points 192--255 are mainly the same as in
+ the latin-1 encoding~\cite{ISO8859-1,latin-page}, but there are
+ exceptions.
+\end{abstract}
+
+\encoding
+
+\needsfontinstversion{1.928}
+
+\begincomment
+\section{Mandatory characters}
+\endcomment
+
+\begincomment
+\subsection{Letters}
+More than two thirds of the characters in the encoding are letters.
+This is a deliberate choice: \TeX's hyphenation algorithm requires
+that all characters in a word are taken from the same font, hence it
+is advantageous\footnote{Probably less so than what was thought when
+the encoding was designed, but still advantageous.} to keep as many
+letters as possible in the same font. Taking symbols from other fonts
+is less of a disadvantage.
+
+\subsubsection{``Unaccented'' letters in slots 0--127}
+\endcomment
+
+\nextslot{25}
+\setslot{dotlessi}
+ \Unicode{0131}{LATIN SMALL LETTER DOTLESS I}
+ \comment{A dotless i `\i', used to produce accented letters such as
+ `\=\i'.}
+\endsetslot
+
+\setslot{dotlessj}
+ \Unicode{F6BE}{LATIN SMALL LETTER DOTLESS J}
+ \comment{A dotless j `\j', used to produce accented letters such as
+ `\=\j'. The Unicode standard does not define this character, but
+ Adobe has assigned code point \texttt{U+F6BE} (which lies
+ in the private use subarea assigned by Adobe) to it.}
+\endsetslot
+
+
+\nextslot{65}
+\setslot{A}
+ \Unicode{0041}{LATIN CAPITAL LETTER A}
+\endsetslot
+
+\setslot{B}
+ \Unicode{0042}{LATIN CAPITAL LETTER B}
+\endsetslot
+
+\setslot{C}
+ \Unicode{0043}{LATIN CAPITAL LETTER C}
+\endsetslot
+
+\setslot{D}
+ \Unicode{0044}{LATIN CAPITAL LETTER D}
+\endsetslot
+
+\setslot{E}
+ \Unicode{0045}{LATIN CAPITAL LETTER E}
+\endsetslot
+
+\setslot{F}
+ \Unicode{0046}{LATIN CAPITAL LETTER F}
+\endsetslot
+
+\setslot{G}
+ \Unicode{0047}{LATIN CAPITAL LETTER G}
+\endsetslot
+
+\setslot{H}
+ \Unicode{0048}{LATIN CAPITAL LETTER H}
+\endsetslot
+
+\setslot{I}
+ \Unicode{0049}{LATIN CAPITAL LETTER I}
+ \oddligature{This ligature only occurs in Dutch typography.}
+ {LIG}{J}{IJ}
+ \oddligature{This ligature only occurs in Dutch typography.}
+ {LIG}{j}{IJ}
+\endsetslot
+
+\setslot{J}
+ \Unicode{004A}{LATIN CAPITAL LETTER J}
+\endsetslot
+
+\setslot{K}
+ \Unicode{004B}{LATIN CAPITAL LETTER K}
+\endsetslot
+
+\setslot{L}
+ \Unicode{004C}{LATIN CAPITAL LETTER L}
+\endsetslot
+
+\setslot{M}
+ \Unicode{004D}{LATIN CAPITAL LETTER M}
+\endsetslot
+
+\setslot{N}
+ \Unicode{004E}{LATIN CAPITAL LETTER N}
+\endsetslot
+
+\setslot{O}
+ \Unicode{004F}{LATIN CAPITAL LETTER O}
+\endsetslot
+
+\setslot{P}
+ \Unicode{0050}{LATIN CAPITAL LETTER P}
+\endsetslot
+
+\setslot{Q}
+ \Unicode{0051}{LATIN CAPITAL LETTER Q}
+\endsetslot
+
+\setslot{R}
+ \Unicode{0052}{LATIN CAPITAL LETTER R}
+\endsetslot
+
+\setslot{S}
+ \Unicode{0053}{LATIN CAPITAL LETTER S}
+\endsetslot
+
+\setslot{T}
+ \Unicode{0054}{LATIN CAPITAL LETTER T}
+\endsetslot
+
+\setslot{U}
+ \Unicode{0055}{LATIN CAPITAL LETTER U}
+\endsetslot
+
+\setslot{V}
+ \Unicode{0056}{LATIN CAPITAL LETTER V}
+\endsetslot
+
+\setslot{W}
+ \Unicode{0057}{LATIN CAPITAL LETTER W}
+\endsetslot
+
+\setslot{X}
+ \Unicode{0058}{LATIN CAPITAL LETTER X}
+\endsetslot
+
+\setslot{Y}
+ \Unicode{0059}{LATIN CAPITAL LETTER Y}
+\endsetslot
+
+\setslot{Z}
+ \Unicode{005A}{LATIN CAPITAL LETTER Z}
+\endsetslot
+
+
+\nextslot{97}
+\setslot{a}
+ \Unicode{0061}{LATIN SMALL LETTER A}
+\endsetslot
+
+\setslot{b}
+ \Unicode{0062}{LATIN SMALL LETTER B}
+\endsetslot
+
+\setslot{c}
+ \Unicode{0063}{LATIN SMALL LETTER C}
+\endsetslot
+
+\setslot{d}
+ \Unicode{0064}{LATIN SMALL LETTER D}
+\endsetslot
+
+\setslot{e}
+ \Unicode{0065}{LATIN SMALL LETTER E}
+\endsetslot
+
+\setslot{f}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \ligature{LIG}{f}{ff}
+ \ligature{LIG}{i}{fi}
+ \ligature{LIG}{l}{fl}
+\endsetslot
+
+\setslot{g}
+ \Unicode{0067}{LATIN SMALL LETTER G}
+\endsetslot
+
+\setslot{h}
+ \Unicode{0068}{LATIN SMALL LETTER H}
+\endsetslot
+
+\setslot{i}
+ \Unicode{0069}{LATIN SMALL LETTER I}
+ \oddligature{This ligature only occurs in Dutch typography.}
+ {LIG}{j}{ij}
+\endsetslot
+
+\setslot{j}
+ \Unicode{006A}{LATIN SMALL LETTER J}
+\endsetslot
+
+\setslot{k}
+ \Unicode{006B}{LATIN SMALL LETTER K}
+\endsetslot
+
+\setslot{l}
+ \Unicode{006C}{LATIN SMALL LETTER L}
+\endsetslot
+
+\setslot{m}
+ \Unicode{006D}{LATIN SMALL LETTER M}
+\endsetslot
+
+\setslot{n}
+ \Unicode{006E}{LATIN SMALL LETTER N}
+\endsetslot
+
+\setslot{o}
+ \Unicode{006F}{LATIN SMALL LETTER O}
+\endsetslot
+
+\setslot{p}
+ \Unicode{0070}{LATIN SMALL LETTER P}
+\endsetslot
+
+\setslot{q}
+ \Unicode{0071}{LATIN SMALL LETTER Q}
+\endsetslot
+
+\setslot{r}
+ \Unicode{0072}{LATIN SMALL LETTER R}
+\endsetslot
+
+\setslot{s}
+ \Unicode{0073}{LATIN SMALL LETTER S}
+\endsetslot
+
+\setslot{t}
+ \Unicode{0074}{LATIN SMALL LETTER T}
+\endsetslot
+
+\setslot{u}
+ \Unicode{0075}{LATIN SMALL LETTER U}
+\endsetslot
+
+\setslot{v}
+ \Unicode{0076}{LATIN SMALL LETTER V}
+\endsetslot
+
+\setslot{w}
+ \Unicode{0077}{LATIN SMALL LETTER W}
+\endsetslot
+
+\setslot{x}
+ \Unicode{0078}{LATIN SMALL LETTER X}
+\endsetslot
+
+\setslot{y}
+ \Unicode{0079}{LATIN SMALL LETTER Y}
+\endsetslot
+
+\setslot{z}
+ \Unicode{007A}{LATIN SMALL LETTER Z}
+\endsetslot
+
+
+\begincomment
+\subsubsection{Mainly East-European accented letters
+ in slots 128--191}
+\endcomment
+
+\nextslot{128}
+\setslot{Abreve}
+ \Unicode{0102}{LATIN CAPITAL LETTER A WITH BREVE}
+\endsetslot
+
+\setslot{Aogonek}
+ \Unicode{0104}{LATIN CAPITAL LETTER A WITH OGONEK}
+\endsetslot
+
+\setslot{Cacute}
+ \Unicode{0106}{LATIN CAPITAL LETTER C WITH ACUTE}
+\endsetslot
+
+\setslot{Ccaron}
+ \Unicode{010C}{LATIN CAPITAL LETTER C WITH CARON}
+\endsetslot
+
+\setslot{Dcaron}
+ \Unicode{010E}{LATIN CAPITAL LETTER D WITH CARON}
+\endsetslot
+
+\setslot{Ecaron}
+ \Unicode{011A}{LATIN CAPITAL LETTER E WITH CARON}
+\endsetslot
+
+\setslot{Eogonek}
+ \Unicode{0118}{LATIN CAPITAL LETTER E WITH OGONEK}
+\endsetslot
+
+\setslot{Gbreve}
+ \Unicode{011E}{LATIN CAPITAL LETTER G WITH BREVE}
+\endsetslot
+
+\setslot{Lacute}
+ \Unicode{0139}{LATIN CAPITAL LETTER L WITH ACUTE}
+\endsetslot
+
+\setslot{Lcaron}
+ \Unicode{013D}{LATIN CAPITAL LETTER L WITH CARON}
+ \comment{The normal glyph for this character consists of a capital
+ L and a right single quote, but the underlying accent is a caron.
+ The glyph name \texttt{Lquoteright} is not uncommon, but
+ \cite{AGL} uses \texttt{Lcaron}.}
+\endsetslot
+
+\setslot{Lslash}
+ \Unicode{0141}{LATIN CAPITAL LETTER L WITH STROKE}
+ \comment{The letter `\L'.}
+\endsetslot
+
+\setslot{Nacute}
+ \Unicode{0143}{LATIN CAPITAL LETTER N WITH ACUTE}
+\endsetslot
+
+\setslot{Ncaron}
+ \Unicode{0147}{LATIN CAPITAL LETTER N WITH CARON}
+\endsetslot
+
+\setslot{Eng}
+ \Unicode{014A}{LATIN CAPITAL LETTER ENG}
+\endsetslot
+
+\setslot{Ohungarumlaut}
+ \Unicode{0150}{LATIN CAPITAL LETTER O WITH DOUBLE ACUTE}
+ \comment{The letter `\H{O}'.}
+\endsetslot
+
+\setslot{Racute}
+ \Unicode{0154}{LATIN CAPITAL LETTER R WITH ACUTE}
+\endsetslot
+
+\setslot{Rcaron}
+ \Unicode{0158}{LATIN CAPITAL LETTER R WITH CARON}
+\endsetslot
+
+\setslot{Sacute}
+ \Unicode{015A}{LATIN CAPITAL LETTER S WITH ACUTE}
+\endsetslot
+
+\setslot{Scaron}
+ \Unicode{0160}{LATIN CAPITAL LETTER S WITH CARON}
+\endsetslot
+
+\setslot{Scedilla}
+ \Unicode{015E}{LATIN CAPITAL LETTER S WITH CEDILLA}
+ \comment{In Romanian, character \textunicode{0218}{latin
+ capital letter s with comma below} is preferred, but that
+ wasn't known when this encoding was designed.}
+\endsetslot
+
+\setslot{Tcaron}
+ \Unicode{0164}{LATIN CAPITAL LETTER T WITH CARON}
+\endsetslot
+
+\setslot{Tcommaaccent}
+ \Unicode{021A}{LATIN CAPITAL LETTER T WITH COMMA BELOW}
+\endsetslot
+
+\setslot{Uhungarumlaut}
+ \Unicode{0170}{LATIN CAPITAL LETTER U WITH DOUBLE ACUTE}
+ \comment{The letter `\H{U}'.}
+\endsetslot
+
+\setslot{Uring}
+ \Unicode{016E}{LATIN CAPITAL LETTER U WITH RING ABOVE}
+\endsetslot
+
+\setslot{Ydieresis}
+ \Unicode{0178}{LATIN CAPITAL LETTER Y WITH DIAERESIS}
+\endsetslot
+
+\setslot{Zacute}
+ \Unicode{0179}{LATIN CAPITAL LETTER Z WITH ACUTE}
+\endsetslot
+
+\setslot{Zcaron}
+ \Unicode{017D}{LATIN CAPITAL LETTER Z WITH CARON}
+\endsetslot
+
+\setslot{Zdotaccent}
+ \Unicode{017B}{LATIN CAPITAL LETTER Z WITH DOT ABOVE}
+\endsetslot
+
+\skipslots{1}
+\setslot{Idotaccent}
+ \Unicode{0130}{LATIN CAPITAL LETTER I WITH DOT ABOVE}
+ \comment{This character's |\lccode| value points to slot 105
+ (\texttt{i}), as does that of slot 73 (\texttt{I}).}
+\endsetslot
+
+\setslot{dcroat}
+ \Unicode{0111}{LATIN SMALL LETTER D WITH STROKE}
+\endsetslot
+
+
+\nextslot{160}
+\setslot{abreve}
+ \Unicode{0103}{LATIN SMALL LETTER A WITH BREVE}
+\endsetslot
+
+\setslot{aogonek}
+ \Unicode{0105}{LATIN SMALL LETTER A WITH OGONEK}
+\endsetslot
+
+\setslot{cacute}
+ \Unicode{0107}{LATIN SMALL LETTER C WITH ACUTE}
+\endsetslot
+
+\setslot{ccaron}
+ \Unicode{010D}{LATIN SMALL LETTER C WITH CARON}
+\endsetslot
+
+\setslot{dcaron}
+ \Unicode{010F}{LATIN SMALL LETTER D WITH CARON}
+ \comment{The normal glyph for this character consists of a
+ lower case d and a right single quote, but the underlying
+ accent is a caron.}
+\endsetslot
+
+\setslot{ecaron}
+ \Unicode{011B}{LATIN SMALL LETTER E WITH CARON}
+\endsetslot
+
+\setslot{eogonek}
+ \Unicode{0119}{LATIN SMALL LETTER E WITH OGONEK}
+\endsetslot
+
+\setslot{gbreve}
+ \Unicode{011F}{LATIN SMALL LETTER G WITH BREVE}
+\endsetslot
+
+\setslot{lacute}
+ \Unicode{013A}{LATIN SMALL LETTER L WITH ACUTE}
+\endsetslot
+
+\setslot{lcaron}
+ \Unicode{013E}{LATIN SMALL LETTER L WITH CARON}
+ \comment{The normal glyph for this character consists of a
+ lower case l and a right single quote, but the underlying
+ accent is a caron. The glyph name \texttt{lquoteright} is
+ not uncommon, but \cite{AGL} uses \texttt{lcaron}.}
+\endsetslot
+
+\setslot{lslash}
+ \Unicode{0142}{LATIN SMALL LETTER L WITH STROKE}
+\endsetslot
+
+\setslot{nacute}
+ \Unicode{0144}{LATIN SMALL LETTER N WITH ACUTE}
+\endsetslot
+
+\setslot{ncaron}
+ \Unicode{0148}{LATIN SMALL LETTER N WITH CARON}
+\endsetslot
+
+\setslot{eng}
+ \Unicode{014B}{LATIN SMALL LETTER ENG}
+\endsetslot
+
+\setslot{ohungarumlaut}
+ \Unicode{0151}{LATIN SMALL LETTER O WITH DOUBLE ACUTE}
+ \comment{The letter `\H{o}'.}
+\endsetslot
+
+\setslot{racute}
+ \Unicode{0155}{LATIN SMALL LETTER R WITH ACUTE}
+\endsetslot
+
+\setslot{rcaron}
+ \Unicode{0159}{LATIN SMALL LETTER R WITH CARON}
+\endsetslot
+
+\setslot{sacute}
+ \Unicode{015B}{LATIN SMALL LETTER S WITH ACUTE}
+\endsetslot
+
+\setslot{scaron}
+ \Unicode{0161}{LATIN SMALL LETTER S WITH CARON}
+\endsetslot
+
+\setslot{scedilla}
+ \Unicode{015F}{LATIN SMALL LETTER S WITH CEDILLA}
+ \comment{In Romanian, character \textunicode{0219}{latin
+ small letter s with comma below} is preferred, but that
+ wasn't known when this encoding was designed.}
+\endsetslot
+
+\setslot{tcaron}
+ \Unicode{0165}{LATIN SMALL LETTER T WITH CARON}
+ \comment{The normal glyph for this character consists of a
+ lower case t and a right single quote, but the underlying
+ accent is a caron.}
+\endsetslot
+
+\setslot{tcommaaccent}
+ \Unicode{021B}{LATIN SMALL LETTER T WITH COMMA BELOW}
+\endsetslot
+
+\setslot{uhungarumlaut}
+ \Unicode{0171}{LATIN SMALL LETTER U WITH DOUBLE ACUTE}
+\endsetslot
+
+\setslot{uring}
+ \Unicode{016F}{LATIN SMALL LETTER U WITH RING ABOVE}
+\endsetslot
+
+\setslot{ydieresis}
+ \Unicode{00FF}{LATIN SMALL LETTER Y WITH DIAERESIS}
+\endsetslot
+
+\setslot{zacute}
+ \Unicode{017A}{LATIN SMALL LETTER Z WITH ACUTE}
+\endsetslot
+
+\setslot{zcaron}
+ \Unicode{017E}{LATIN SMALL LETTER Z WITH CARON}
+\endsetslot
+
+\setslot{zdotaccent}
+ \Unicode{017C}{LATIN SMALL LETTER Z WITH DOT ABOVE}
+\endsetslot
+
+
+\begincomment
+\subsubsection{Mainly West-European accented letters in slots 192--255}
+\endcomment
+
+\nextslot{192}
+\setslot{Agrave}
+ \Unicode{00C0}{LATIN CAPITAL LETTER A WITH GRAVE}
+\endsetslot
+
+\setslot{Aacute}
+ \Unicode{00C1}{LATIN CAPITAL LETTER A WITH ACUTE}
+\endsetslot
+
+\setslot{Acircumflex}
+ \Unicode{00C2}{LATIN CAPITAL LETTER A WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{Atilde}
+ \Unicode{00C3}{LATIN CAPITAL LETTER A WITH TILDE}
+\endsetslot
+
+\setslot{Adieresis}
+ \Unicode{00C4}{LATIN CAPITAL LETTER A WITH DIAERESIS}
+\endsetslot
+
+\setslot{Aring}
+ \Unicode{00C5}{LATIN CAPITAL LETTER A WITH RING ABOVE}
+\endsetslot
+
+\setslot{AE}
+ \Unicode{00C6}{LATIN CAPITAL LETTER AE}
+\endsetslot
+
+\setslot{Ccedilla}
+ \Unicode{00C7}{LATIN CAPITAL LETTER C WITH CEDILLA}
+\endsetslot
+
+\setslot{Egrave}
+ \Unicode{00C8}{LATIN CAPITAL LETTER E WITH GRAVE}
+\endsetslot
+
+\setslot{Eacute}
+ \Unicode{00C9}{LATIN CAPITAL LETTER E WITH ACUTE}
+\endsetslot
+
+\setslot{Ecircumflex}
+ \Unicode{00CA}{LATIN CAPITAL LETTER E WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{Edieresis}
+ \Unicode{00CB}{LATIN CAPITAL LETTER E WITH DIAERESIS}
+\endsetslot
+
+\setslot{Igrave}
+ \Unicode{00CC}{LATIN CAPITAL LETTER I WITH GRAVE}
+\endsetslot
+
+\setslot{Iacute}
+ \Unicode{00CD}{LATIN CAPITAL LETTER I WITH ACUTE}
+\endsetslot
+
+\setslot{Icircumflex}
+ \Unicode{00CE}{LATIN CAPITAL LETTER I WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{Idieresis}
+ \Unicode{00CF}{LATIN CAPITAL LETTER I WITH DIAERESIS}
+\endsetslot
+
+\setslot{Eth}
+ \Unicode{00D0}{LATIN CAPITAL LETTER ETH}
+ \Unicode{0110}{LATIN CAPITAL LETTER D WITH STROKE}
+ \comment{This slot is being used to represent two different
+ letters whose capital forms are identical. The |\lccode| value
+ points to slot \ref{eth}.}
+\endsetslot
+
+\setslot{Ntilde}
+ \Unicode{00D1}{LATIN CAPITAL LETTER N WITH TILDE}
+\endsetslot
+
+\setslot{Ograve}
+ \Unicode{00D2}{LATIN CAPITAL LETTER O WITH GRAVE}
+\endsetslot
+
+\setslot{Oacute}
+ \Unicode{00D3}{LATIN CAPITAL LETTER O WITH ACUTE}
+\endsetslot
+
+\setslot{Ocircumflex}
+ \Unicode{00D4}{LATIN CAPITAL LETTER O WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{Otilde}
+ \Unicode{00D5}{LATIN CAPITAL LETTER O WITH TILDE}
+\endsetslot
+
+\setslot{Odieresis}
+ \Unicode{00D6}{LATIN CAPITAL LETTER O WITH DIAERESIS}
+\endsetslot
+
+\setslot{OE}
+ \Unicode{0152}{LATIN CAPITAL LIGATURE OE}
+ \comment{This is a single letter, and should not be faked with `OE'.}
+\endsetslot
+
+\setslot{Oslash}
+ \Unicode{00D8}{LATIN CAPITAL LETTER O WITH STROKE}
+\endsetslot
+
+\setslot{Ugrave}
+ \Unicode{00D9}{LATIN CAPITAL LETTER U WITH GRAVE}
+\endsetslot
+
+\setslot{Uacute}
+ \Unicode{00DA}{LATIN CAPITAL LETTER U WITH ACUTE}
+\endsetslot
+
+\setslot{Ucircumflex}
+ \Unicode{00DB}{LATIN CAPITAL LETTER U WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{Udieresis}
+ \Unicode{00DC}{LATIN CAPITAL LETTER U WITH DIAERESIS}
+\endsetslot
+
+\setslot{Yacute}
+ \Unicode{00DD}{LATIN CAPITAL LETTER Y WITH ACUTE}
+\endsetslot
+
+\setslot{Thorn}
+ \Unicode{00DE}{LATIN CAPITAL LETTER THORN}
+\endsetslot
+
+\setslot{SS}
+ \comment{This is an ``uppercased'' sharp s (`\ss') which always
+ looks exactly like two S's next to each other. In a monowidth
+ font it should be two letters wide. There are other characters
+ which could have made better use of this slot; the only function
+ of this slot which could not have been handled using macros is
+ that |\SS| and |SS| can have different hyphenation.}
+ \label{SS}
+ \charseq{
+ \Unicode{0053}{LATIN CAPITAL LETTER S}
+ \Unicode{0053}{LATIN CAPITAL LETTER S}
+ }
+\endsetslot
+
+\setslot{agrave}
+ \Unicode{00E0}{LATIN SMALL LETTER A WITH GRAVE}
+\endsetslot
+
+\setslot{aacute}
+ \Unicode{00E1}{LATIN SMALL LETTER A WITH ACUTE}
+\endsetslot
+
+\setslot{acircumflex}
+ \Unicode{00E2}{LATIN SMALL LETTER A WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{atilde}
+ \Unicode{00E3}{LATIN SMALL LETTER A WITH TILDE}
+\endsetslot
+
+\setslot{adieresis}
+ \Unicode{00E4}{LATIN SMALL LETTER A WITH DIAERESIS}
+\endsetslot
+
+\setslot{aring}
+ \Unicode{00E5}{LATIN SMALL LETTER A WITH RING ABOVE}
+\endsetslot
+
+\setslot{ae}
+ \Unicode{00E6}{LATIN SMALL LETTER AE}
+\endsetslot
+
+\setslot{ccedilla}
+ \Unicode{00E7}{LATIN SMALL LETTER C WITH CEDILLA}
+\endsetslot
+
+\setslot{egrave}
+ \Unicode{00E8}{LATIN SMALL LETTER E WITH GRAVE}
+\endsetslot
+
+\setslot{eacute}
+ \Unicode{00E9}{LATIN SMALL LETTER E WITH ACUTE}
+\endsetslot
+
+\setslot{ecircumflex}
+ \Unicode{00EA}{LATIN SMALL LETTER E WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{edieresis}
+ \Unicode{00EB}{LATIN SMALL LETTER E WITH DIAERESIS}
+\endsetslot
+
+\setslot{igrave}
+ \Unicode{00EC}{LATIN SMALL LETTER I WITH GRAVE}
+\endsetslot
+
+\setslot{iacute}
+ \Unicode{00ED}{LATIN SMALL LETTER I WITH ACUTE}
+\endsetslot
+
+\setslot{icircumflex}
+ \Unicode{00EE}{LATIN SMALL LETTER I WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{idieresis}
+ \Unicode{00EF}{LATIN SMALL LETTER I WITH DIAERESIS}
+\endsetslot
+
+\setslot{eth}
+ \Unicode{00F0}{LATIN SMALL LETTER ETH}
+ \label{eth}
+\endsetslot
+
+\setslot{ntilde}
+ \Unicode{00F1}{LATIN SMALL LETTER N WITH TILDE}
+\endsetslot
+
+\setslot{ograve}
+ \Unicode{00F2}{LATIN SMALL LETTER O WITH GRAVE}
+\endsetslot
+
+\setslot{oacute}
+ \Unicode{00F3}{LATIN SMALL LETTER O WITH ACUTE}
+\endsetslot
+
+\setslot{ocircumflex}
+ \Unicode{00F4}{LATIN SMALL LETTER O WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{otilde}
+ \Unicode{00F5}{LATIN SMALL LETTER O WITH TILDE}
+\endsetslot
+
+\setslot{odieresis}
+ \Unicode{00F6}{LATIN SMALL LETTER O WITH DIAERESIS}
+\endsetslot
+
+\setslot{oe}
+ \Unicode{0153}{LATIN SMALL LIGATURE OE}
+ \comment{This is a single letter, and should not be faked with `oe'.}
+\endsetslot
+
+\setslot{oslash}
+ \Unicode{00F8}{LATIN SMALL LETTER O WITH STROKE}
+\endsetslot
+
+\setslot{ugrave}
+ \Unicode{00F9}{LATIN SMALL LETTER U WITH GRAVE}
+\endsetslot
+
+\setslot{uacute}
+ \Unicode{00FA}{LATIN SMALL LETTER U WITH ACUTE}
+\endsetslot
+
+\setslot{ucircumflex}
+ \Unicode{00FB}{LATIN SMALL LETTER U WITH CIRCUMFLEX}
+\endsetslot
+
+\setslot{udieresis}
+ \Unicode{00FC}{LATIN SMALL LETTER U WITH DIAERESIS}
+\endsetslot
+
+\setslot{yacute}
+ \Unicode{00FD}{LATIN SMALL LETTER Y WITH ACUTE}
+\endsetslot
+
+\setslot{thorn}
+ \Unicode{00FE}{LATIN SMALL LETTER THORN}
+\endsetslot
+
+\setslot{germandbls}
+ \Unicode{00DF}{LATIN SMALL LETTER SHARP S}
+\endsetslot
+
+
+\begincomment
+\subsection{Accents}
+The Unicode equivalents of the accents are taken to be the combining
+forms of the accents found in code point \texttt{U+0300} and upwards.
+The reasons for this are (i) that they are primarily used with the
+|\accent| primitive, i.e., as combining characters, (ii) that some
+of them (e.g. \texttt{tilde}) have non-combining counterparts
+elsewhere in the encoding, and (iii) that they are not primarily
+phonetic marks.
+\endcomment
+
+\nextslot{0}
+\setslot{grave}
+ \Unicode{0300}{COMBINING GRAVE ACCENT}
+\endsetslot
+
+\setslot{acute}
+ \Unicode{0301}{COMBINING ACUTE ACCENT}
+\endsetslot
+
+\setslot{circumflex}
+ \Unicode{0302}{COMBINING CIRCUMFLEX ACCENT}
+\endsetslot
+
+\setslot{tilde}
+ \Unicode{0303}{COMBINING TILDE}
+\endsetslot
+
+\setslot{dieresis}
+ \Unicode{0308}{COMBINING DIAERESIS}
+\endsetslot
+
+\setslot{hungarumlaut}
+ \Unicode{030B}{COMBINING DOUBLE ACUTE ACCENT}
+ \comment{The long Hungarian umlaut `\H{}'.}
+\endsetslot
+
+\setslot{ring}
+ \Unicode{030A}{COMBINING RING ABOVE}
+\endsetslot
+
+\setslot{caron}
+ \Unicode{030C}{COMBINING CARON}
+ \comment{The caron or h\'a\v cek accent `\v{}'.}
+\endsetslot
+
+\setslot{breve}
+ \Unicode{0306}{COMBINING BREVE}
+\endsetslot
+
+\setslot{macron}
+ \Unicode{0304}{COMBINING MACRON}
+\endsetslot
+
+\setslot{dotaccent}
+ \Unicode{0307}{COMBINING DOT ABOVE}
+\endsetslot
+
+\setslot{cedilla}
+ \Unicode{0327}{COMBINING CEDILLA}
+\endsetslot
+
+\setslot{ogonek}
+ \Unicode{0328}{COMBINING OGONEK}
+\endsetslot
+
+
+\begincomment
+\subsection{Digits}
+\endcomment
+
+\nextslot{48}
+\setslot{zero}
+ \Unicode{0030}{DIGIT ZERO}
+\endsetslot
+
+\setslot{one}
+ \Unicode{0031}{DIGIT ONE}
+\endsetslot
+
+\setslot{two}
+ \Unicode{0032}{DIGIT TWO}
+\endsetslot
+
+\setslot{three}
+ \Unicode{0033}{DIGIT THREE}
+\endsetslot
+
+\setslot{four}
+ \Unicode{0034}{DIGIT FOUR}
+\endsetslot
+
+\setslot{five}
+ \Unicode{0035}{DIGIT FIVE}
+\endsetslot
+
+\setslot{six}
+ \Unicode{0036}{DIGIT SIX}
+\endsetslot
+
+\setslot{seven}
+ \Unicode{0037}{DIGIT SEVEN}
+\endsetslot
+
+\setslot{eight}
+ \Unicode{0038}{DIGIT EIGHT}
+\endsetslot
+
+\setslot{nine}
+ \Unicode{0039}{DIGIT NINE}
+\endsetslot
+
+
+\begincomment
+\subsection{Symbols and punctuation}
+\endcomment
+
+\nextslot{13}
+\setslot{quotesinglbase}
+ \Unicode{201A}{SINGLE LOW-9 QUOTATION MARK}
+\endsetslot
+
+\setslot{guilsinglleft}
+ \Unicode{2039}{SINGLE LEFT-POINTING ANGLE QUOTATION MARK}
+ \comment{In French typography this is an opening quotation mark,
+ but in German typography it is a closing quotation mark. The
+ character should kern well in both cases.}
+\endsetslot
+
+\setslot{guilsinglright}
+ \Unicode{203A}{SINGLE RIGHT-POINTING ANGLE QUOTATION MARK}
+ \comment{In French typography this is a closing quotation mark,
+ but in German typography it is an opening quotation mark. The
+ character should kern well in both cases.}
+\endsetslot
+
+\setslot{quotedblleft}
+ \Unicode{201C}{LEFT DOUBLE QUOTATION MARK}
+\endsetslot
+
+\setslot{quotedblright}
+ \Unicode{201D}{RIGHT DOUBLE QUOTATION MARK}
+ \comment{In English typography this quotation mark is always
+ closing, but in Swedish typography it is also an opening
+ quotation mark. The character should kern well in both cases.}
+\endsetslot
+
+\setslot{quotedblbase}
+ \Unicode{201E}{DOUBLE LOW-9 QUOTATION MARK}
+\endsetslot
+
+\setslot{guillemotleft}
+ \Unicode{00AB}{LEFT-POINTING DOUBLE ANGLE QUOTATION MARK}
+ \comment{In French typography this is an opening quotation mark,
+ but in German typography it is a closing quotation mark. The
+ character should kern well in both cases. The glyph name is
+ misspelt (it should be \texttt{guillemetleft}), but this
+ incorrect name is \emph{de facto} the glyph name used.}
+\endsetslot
+
+\setslot{guillemotright}
+ \Unicode{00BB}{RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK}
+ \comment{In French typography this is a closing quotation mark,
+ but in German typography it is an opening quotation mark. The
+ character should kern well in both cases. The glyph name is
+ misspelt (it should be \texttt{guillemetright}), but this
+ incorrect name is \emph{de facto} the glyph name used.}
+\endsetslot
+
+\setslot{endash}
+ \Unicode{2013}{EN DASH}
+ \label{endash}
+ \Ligature{LIG}{hyphen}{emdash}
+\endsetslot
+
+\setslot{emdash}
+ \Unicode{2014}{EM DASH}
+ \comment{In a monowidth font this character is preferably given the
+ width of two normal characters.}
+\endsetslot
+
+\nextslot{32}
+\setslot{visiblespace}
+ \Unicode{2423}{OPEN BOX}
+ \comment{A visible space glyph `\textvisiblespace'.}
+\endsetslot
+
+\setslot{exclam}
+ \Unicode{0021}{EXCLAMATION MARK}
+ \Ligature{LIG}{quoteleft}{exclamdown}
+\endsetslot
+
+\setslot{quotedbl}
+ \Unicode{0022}{QUOTATION MARK}
+ \comment{The `neutral' double quotation mark, included for use in
+ monowidth fonts, or for setting computer programs.}
+\endsetslot
+
+\setslot{numbersign}
+ \Unicode{0023}{NUMBER SIGN}
+\endsetslot
+
+\setslot{dollar}
+ \Unicode{0024}{DOLLAR SIGN}
+\endsetslot
+
+\setslot{percent}
+ \Unicode{0025}{PERCENT SIGN}
+\endsetslot
+
+\setslot{ampersand}
+ \Unicode{0026}{AMPERSAND}
+\endsetslot
+
+\setslot{quoteright}
+ \Unicode{2019}{RIGHT SINGLE QUOTATION MARK}
+ \Ligature{LIG}{quoteright}{quotedblright}
+\endsetslot
+
+\setslot{parenleft}
+ \Unicode{0028}{LEFT PARENTHESIS}
+\endsetslot
+
+\setslot{parenright}
+ \Unicode{0029}{RIGHT PARENTHESIS}
+\endsetslot
+
+\setslot{asterisk}
+ \Unicode{002A}{ASTERISK}
+\endsetslot
+
+\setslot{plus}
+ \Unicode{002B}{PLUS SIGN}
+\endsetslot
+
+\setslot{comma}
+ \Unicode{002C}{COMMA}
+ \Ligature{LIG}{comma}{quotedblbase}
+\endsetslot
+
+\setslot{hyphen}
+ \Unicode{002D}{HYPHEN-MINUS}
+ \Ligature{LIG}{hyphen}{endash}
+ \Ligature{LIG}{hyphenchar}{hyphenchar}
+ \comment{See also slot \ref{hyphenchar}.}
+ \label{hyphen}
+\endsetslot
+
+\setslot{period}
+ \Unicode{002E}{FULL STOP}
+\endsetslot
+
+\setslot{slash}
+ \Unicode{002F}{SOLIDUS}
+\endsetslot
+
+\skipslots{10}
+\setslot{colon}
+ \Unicode{003A}{COLON}
+\endsetslot
+
+\setslot{semicolon}
+ \Unicode{003B}{SEMICOLON}
+\endsetslot
+
+\setslot{less}
+ \Unicode{003C}{LESS-THAN SIGN}
+ \Ligature{LIG}{less}{guillemotleft}
+\endsetslot
+
+\setslot{equal}
+ \Unicode{003D}{EQUALS SIGN}
+\endsetslot
+
+\setslot{greater}
+ \Unicode{003E}{GREATER-THAN SIGN}
+ \Ligature{LIG}{greater}{guillemotright}
+\endsetslot
+
+\setslot{question}
+ \Unicode{003F}{QUESTION MARK}
+ \Ligature{LIG}{quoteleft}{questiondown}
+\endsetslot
+
+\setslot{at}
+ \Unicode{0040}{COMMERCIAL AT}
+\endsetslot
+
+\nextslot{91}
+\setslot{bracketleft}
+ \Unicode{005B}{LEFT SQUARE BRACKET}
+\endsetslot
+
+\setslot{backslash}
+ \Unicode{005C}{REVERSE SOLIDUS}
+\endsetslot
+
+\setslot{bracketright}
+ \Unicode{005D}{RIGHT SQUARE BRACKET}
+\endsetslot
+
+\setslot{asciicircum}
+ \Unicode{005E}{CIRCUMFLEX ACCENT}
+ \comment{The ASCII upward-pointing arrow head `\textasciicircum'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{underscore}
+ \Unicode{005F}{LOW LINE}
+ \comment{The ASCII underline character `\textunderscore', usually
+ set on the baseline. This is included for compatibility with
+ typewriter fonts used for computer listings.}
+\endsetslot
+
+\setslot{quoteleft}
+ \Unicode{2018}{LEFT SINGLE QUOTATION MARK}
+ \Ligature{LIG}{quoteleft}{quotedblleft}
+\endsetslot
+
+\nextslot{123}
+\setslot{braceleft}
+ \Unicode{007B}{LEFT CURLY BRACKET}
+\endsetslot
+
+\setslot{bar}
+ \Unicode{007C}{VERTICAL LINE}
+ \comment{The ASCII vertical bar `\textbar'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{braceright}
+ \Unicode{007D}{RIGHT CURLY BRACKET}
+\endsetslot
+
+\setslot{asciitilde}
+ \Unicode{007E}{TILDE}
+ \comment{The ASCII tilde `\textasciitilde'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\nextslot{159}
+\setslot{section}
+ \Unicode{00A7}{SECTION SIGN}
+\endsetslot
+
+\nextslot{189}
+\setslot{exclamdown}
+ \Unicode{00A1}{INVERTED EXCLAMATION MARK}
+\endsetslot
+
+\setslot{questiondown}
+ \Unicode{00BF}{INVERTED QUESTION MARK}
+\endsetslot
+
+\setslot{sterling}
+ \Unicode{00A3}{POUND SIGN}
+\endsetslot
+
+
+
+\begincomment
+\subsection{Miscellanea}
+\endcomment
+
+\nextslot{23}
+\setslot{compwordmark}
+ \Unicode{200C}{ZERO WIDTH NON-JOINER}
+ \comment{An invisible glyph, with zero width and depth, but the
+ height of lower case letters without ascenders.
+ It is used to stop ligaturing in words like `shelf{}ful'.
+ It is possible that this character should be considered a
+ letter (and that hyphenation patterns should be designed to
+ include it), but since its |\lccode| is 0, \TeX's hyphenation
+ mechanism considers it to be a nonletter which ends the
+ hyphenatable part of a word.}
+\endsetslot
+
+\setslot{perthousandzero}
+ \comment{A glyph which is placed after `\%' to produce a
+ `per-thousand', or twice to produce `per-ten-thousand'.
+ Your guess is as good as mine as to what this glyph should look
+ like in a monowidth font. Since most fonts don't include this
+ glyph anyway, its use is discouraged.}
+\endsetslot
+
+\nextslot{127}
+\setslot{hyphenchar}
+ \label{hyphenchar}
+ \comment{This character is provided as a discretionary hyphen
+ symbol and may only appear at the end of a line, since it is often
+ hanging out of the character box, but apart from that it is almost
+ always the same as the \texttt{hyphen} character. Since \LaTeX\
+ sets the |\hyphenchar| of \texttt{T1} fonts to slot \ref{hyphen}
+ rather than this slot, this feature is usually not used.}
+\endsetslot
+
+
+
+\begincomment
+\section{Usual characters}
+The following characters are only accessed through ligatures and can
+therefore be replaced by others or completely left out if the
+ligature programs are modified accordingly.
+\endcomment
+
+
+\nextslot{27}
+\setslot{ff}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ }
+ \comment{This glyph should be two characters wide in a monowidth
+ font.}
+ \ligature{LIG}{i}{ffi}
+ \ligature{LIG}{l}{ffl}
+\endsetslot
+
+\setslot{fi}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0069}{LATIN SMALL LETTER I}
+ }
+ \comment{This glyph should be two characters wide in a monowidth
+ font.}
+\endsetslot
+
+\setslot{fl}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{006C}{LATIN SMALL LETTER L}
+ }
+ \comment{This glyph should be two characters wide in a monowidth
+ font.}
+\endsetslot
+
+\setslot{ffi}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0069}{LATIN SMALL LETTER I}
+ }
+ \comment{This glyph should be three characters wide in a monowidth
+ font.}
+\endsetslot
+
+\setslot{ffl}
+ \charseq{
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{0066}{LATIN SMALL LETTER F}
+ \Unicode{006C}{LATIN SMALL LETTER L}
+ }
+ \comment{This glyph should be three characters wide in a monowidth
+ font.}
+\endsetslot
+
+\nextslot{156}
+\setslot{IJ}
+ \Unicode{0132}{LATIN CAPITAL LIGATURE IJ}
+ \comment{This is a single letter, and in a monowidth font should
+ ideally be one letter wide.}
+\endsetslot
+
+\nextslot{188}
+\setslot{ij}
+ \Unicode{0133}{LATIN SMALL LIGATURE IJ}
+ \comment{This is a single letter, and in a monowidth font should
+ ideally be one letter wide.}
+\endsetslot
+
+
+\begincomment
+\section{Fontdimens}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+\setfontdimen{8}{capheight} % cap height
+\setfontdimen{9}{ascender} % ascender
+\setfontdimen{10}{acccapheight} % accented cap height
+\setfontdimen{11}{descender} % descender's depth
+\setfontdimen{12}{maxheight} % max height
+\setfontdimen{13}{maxdepth} % max depth
+\setfontdimen{14}{digitwidth} % digit width
+\setfontdimen{15}{verticalstem} % dominant width of verical stems
+\setfontdimen{16}{baselineskip} % baselineskip
+
+
+\begincomment
+\section{Coding scheme}
+\endcomment
+
+\setstr{codingscheme}{EXTENDED TEX FONT ENCODING - LATIN}
+
+
+\endencoding
+
+
+\section{Discussion}
+
+As the \texttt{T1} encoding is an established standard, the discussion
+of it has already been published elsewhere. [Unfortunately, I do not
+know where as it all happened long before I started using \TeX. This
+part of the document definitely needs to be improved. To begin with, I
+would like to know if the TUGboat articles whose bibliography entries
+appear in Figure~\ref{Bib-entries} are relevant for the matter.
+\begin{figure*}
+\small
+\begin{verbatim}
+@Article{Beebe:TB11-2-171,
+ author = "Nelson Beebe",
+ title = "{Character set encoding}",
+ journal = j-TUGboat,
+ volume = "11",
+ number = "2",
+ pages = "171--175",
+ month = jun,
+ year = "1990",
+ ISSN = "0896-3207",
+ bibdate = "Fri Jun 4 18:08:09 MDT 1999",
+ bibsource = "ftp://ftp.math.utah.edu/pub/tex/bib/tugboat.bib;
+ http://www.math.utah.edu/pub/tex/bib/index-table-t.html#tugboat",
+ acknowledgement = ack-bnb # " and " # ack-nhfb,
+}
+@Article{Bien:TB11-2-175,
+ author = "Janusz S. Bie{\'n}",
+ title = "{On standards for computer modern font extensions}",
+ journal = j-TUGboat,
+ volume = "11",
+ number = "2",
+ pages = "175--183",
+ month = jun,
+ year = "1990",
+ ISSN = "0896-3207",
+ bibdate = "Fri Jun 4 18:08:09 MDT 1999",
+ bibsource = "ftp://ftp.math.utah.edu/pub/tex/bib/tugboat.bib;
+ http://www.math.utah.edu/pub/tex/bib/index-table-t.html#tugboat",
+ acknowledgement = ack-bnb # " and " # ack-nhfb,
+}
+@Article{Ferguson:TB11-4-514,
+ author = "Michael Ferguson",
+ title = "{Report on multilingual activities}",
+ journal = j-TUGboat,
+ volume = "11",
+ number = "4",
+ pages = "514--516",
+ month = nov,
+ year = "1990",
+ ISSN = "0896-3207",
+ bibdate = "Fri Jun 4 18:08:09 MDT 1999",
+ bibsource = "ftp://ftp.math.utah.edu/pub/tex/bib/tugboat.bib;
+ http://www.math.utah.edu/pub/tex/bib/index-table-t.html#tugboat",
+ acknowledgement = ack-bnb # " and " # ack-nhfb,
+}
+\end{verbatim}
+\normalsize
+
+\caption{Entries in \texttt{tugboat.bib} which may describe papers
+that contain (at least part of) the discussion regarding the
+\texttt{T1} encoding}
+\label{Bib-entries}
+\end{figure*}
+Actually reading them would be nice too, as would of course getting
+the references for whatever other papers there might be that
+constituted the discussion of the \texttt{T1} encoding. The file
+\texttt{cork.enc} in the \textit{Fontname} standard makes a cryptic
+reference to ``TTN 1(4), December 1992'', whatever that might be.]
+
+I can however answer questions on the more immediate matter of how the
+interpretation of the established standard that this file expresses was
+constructed. It is mainly the result of a comparison between the
+file \texttt{t1.etx}~\cite{t1.etx}, the Unicode
+standard~\cite{Unicode}, and the Adobe glyph list~\cite{AGL}.
+
+(Some concerns have been expressed about the fact that the glyph name
+listed for slot~0 is `\texttt{grave}', although that glyph name in
+\cite{AGL} corresponds to \textunicode{0060}{GRAVE ACCENT}, whereas
+\textunicode{0300}{COMBINING GRAVE ACCENT} is listed as corresponding
+to `\texttt{gravecomb}'. This is however formally irrelevant, since
+the glyph names are formally only internal labels in the encoding
+specification. `\texttt{gravecomb}' would furthermore be a more
+impractical label, since most font contains a `\texttt{grave}' glyph
+that is used as a combining accent but no `\texttt{gravecomb}'
+glyph.)
+
+
+\section{Changes}
+
+The changes made to this specification since the original 2001/06/19
+version are as follows.
+
+2001/09/01: Corrected some typos (reported by Vladimir Volovich). /LH
+
+2001/09/16: Added \cite{latin-page} to the bibliography. /LH
+
+2001/09/21: Removed comment on \textunicode{2012}{FIGURE DASH} from
+slot~\ref{endash}. \cite[Sec.~6.1]{Unicode} makes quite clear that
+it's not to be used for ranges. /LH
+
+2002/07/05: Added the Ferguson:TB11-4-514 and ``TTN~1(4)'' references
+to the discussion section. Also added remark on \texttt{grave} versus
+\texttt{gravecomb}. /LH
+
+2004/11/28: Changed the f-ligatures to character sequences, which
+makes more sense for \texttt{CMap}s. Added equivalent for
+slot~\ref{SS}. /LH
+
+
+\begin{thebibliography}{9}
+\bibitem{AGL}
+ Adobe Systems Incorporated: \textit{Adobe Glyph List}, 1998;
+ \textsc{http}:/\slash \texttt{partners.adobe.com}\slash
+ \texttt{asn}\slash \texttt{developer}\slash \texttt{type}\slash
+ \texttt{glyphlist.txt}
+\bibitem{latin-page}
+ Roman Czyborra: \textit{The ISO 8859 Alphabet Soup}, web page at
+ \textsc{http:}/\slash \texttt{czyborra.com}\slash
+ \texttt{charsets}\slash \texttt{iso8859.html}, 1998.
+\bibitem{ISO8859-1}
+ International Organization for Standardization:
+ \textit{ISO/IEC standard 8859-1} (Information technology --
+ 8-bit single-byte coded graphic character sets --
+ Part 1: Latin alphabet No. 1).
+ See also~\cite{latin-page}.
+\bibitem{t1.etx}
+ Alan Jeffrey, Sebastian Rahtz, and Ulrik Vieth:
+ \textit{The \TeX\ extended text encoding vector},
+ version~1.801, 1998,
+ \textsc{ctan}:\discretionary{}{}{\thinspace}\texttt{fonts}\slash
+ \texttt{utilities}\slash \texttt{fontinst}\slash
+ \texttt{inputs}\slash \texttt{etx}\slash \texttt{t1.etx}.
+\bibitem{TeXbook}
+ Donald E.\ Knuth, Duane Bibby (illustrations):
+ \textit{The \TeX book}, Ad\-di\-son--Wes\-ley, 1986;
+ ISBN~0-201-13447-0.
+\bibitem{Unicode}
+ The Unicode Consortium (editor), \emph{et al.}:
+ \textit{The Unicode Standard, Version 3.0},
+ Addison Wesley Longman Publisher, 2000; ISBN~0-201-61633-5.
+ Most of the information in this book is also available online at
+ the Unicode consortium website, at \textsc{http}:/\slash
+ \texttt{www.unicode.org}\slash \texttt{unicode}\slash
+ \texttt{uni2book}\slash \texttt{u2.html}.
+\end{thebibliography}
+
+
+
+\end{document} \ No newline at end of file
diff --git a/fonts/utilities/fontinst/doc/manual/fontinst.pdf b/fonts/utilities/fontinst/doc/manual/fontinst.pdf
new file mode 100644
index 0000000000..d05b42d320
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/manual/fontinst.pdf
Binary files differ
diff --git a/fonts/utilities/fontinst/doc/manual/fontinst.tex b/fonts/utilities/fontinst/doc/manual/fontinst.tex
new file mode 100644
index 0000000000..a66b89054c
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/manual/fontinst.tex
@@ -0,0 +1,4680 @@
+%%% ====================================================================
+%%% @LaTeX-file{
+%%% author = "Alan Jeffrey and Rowland McDonnell and
+%%% Ulrik Vieth and Lars Hellstr{\"o}m",
+%%% version = "1.928",
+%%% date = "2007-09-06",
+%%% time = "11:22:41 +02:00",
+%%% filename = "fontinst.tex",
+%%% email = "fontinst@tug.org",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "fontinst, TeX, PostScript, documentation",
+%%% supported = "yes",
+%%% abstract = "This is the documentation for the fontinst
+%%% font installation package.",
+%%% package = "fontinst",
+%%% dependencies = "ltxguide.cls, url.sty, xspace.sty"
+%%% }
+%%% ====================================================================
+
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey
+
+% Modified by Rowland McDonnell June 1998
+% Modified and revised by Ulrik Vieth June 1998
+% Modified by Lars Hellstr\"om July 2004 and later
+
+
+
+\documentclass[a4paper]{ltxguide}
+\usepackage[OT1]{fontenc}
+\usepackage{url,xspace}
+\usepackage{graphicx}
+
+\IfFileExists{palatino.flag}{
+ \renewcommand\rmdefault{ppl}
+}
+%\renewcommand\rmdefault{padx}
+%\renewcommand\rmdefault{pmnx}
+
+% \MakeShortVerb{\|}
+
+
+% Title page and running heads.
+
+\makeatletter
+\newcommand{\subtitle}[1]{\renewcommand{\@subtitle}{#1}}
+\newcommand{\version}[1]{\renewcommand{\@version}{#1}}
+\newcommand{\illustration}[1]{\renewcommand{\@illustration}{#1}}
+
+\newcommand{\@subtitle}{}
+\newcommand{\@version}{???}
+\newcommand{\@illustration}{cover.eps}
+
+% \pagestyle{myheadings}
+% \AtBeginDocument{\markright{\small\itshape
+% \@author\hfill\@title: \@subtitle\quad}}
+
+
+\renewcommand{\maketitle}{{%
+ \thispagestyle{empty}%
+ \normalfont\centering
+ \null
+ {\fontsize{100}{100}\textit{\@title}}%
+ \par\bigskip
+ {\Large\textbf{\@subtitle}}%
+ \vfill
+ \includegraphics[width=\textwidth]{\@illustration}%
+ \vfill
+ {\Large\textbf{%
+ \def\and{\egroup\qquad\hbox\bgroup}
+ \leavevmode \hbox{\@author}\\[\smallskipamount]
+ \@title~v\@version
+ \quad\textperiodcentered\quad \@date}}%
+ \clearpage
+}}
+\makeatother
+
+
+% Set lists tighter (assuming non-zero \parskip).
+
+\makeatletter
+\renewcommand{\@listI}{%
+ \leftmargin\leftmargini
+ \parsep\medskipamount
+ \itemsep\z@ % + parsep
+ \topsep\z@ % + parskip
+ \partopsep\z@
+}
+\newenvironment{isyntax}{%
+ \let\\\@centercr
+ \list{}{%
+ \itemsep \z@
+ \itemindent -1.5em%
+ \listparindent \itemindent
+ \advance \leftmargin 1.5em%
+ }%
+ \advance \rightskip \z@\@plus0.7\linewidth \relax
+ \linepenalty=100\relax
+ \item\relax
+}{\endlist}
+\makeatother
+
+\newenvironment{smalldes}{%
+ \list{}{%
+ \setlength\labelwidth{0pt}%
+ \setlength\itemindent{-\leftmargin}%
+ \setlength\listparindent{1em}%
+ \setlength\parsep{0pt}%
+ \setlength\itemsep{0pt plus 1pt}%
+ \setlength\topsep{\itemsep}%
+ \let\makelabel\descriptionlabel
+ }%
+}{\endlist}
+
+\newenvironment{hackernote}{%
+ \list{}{
+ \setlength{\leftmargin}{0pt}%
+ \setlength\labelwidth{0pt}%
+ \setlength{\listparindent}{1.4em}%
+ \setlength{\parsep}{0pt plus 1pt}%
+ \setlength{\itemsep}{\medskipamount}%
+ }\item[]%
+ \small
+ \textit{Note for hackers.}\hspace{0.5em}%
+}{\endlist}
+
+% % I don't use the <...> feature for verbatim,
+% % so I undo that ltxguide feature.
+% \makeatletter
+% \renewcommand{\verbatim@font}{%
+% \normalfont \ttfamily
+% % \catcode`\<=\active
+% % \catcode`\>=\active
+% }
+% \makeatother
+
+
+% ltxguide.cls decl environment, but with equal space above and
+% below.
+\DeleteShortVerb{\|}
+\makeatletter
+\newenvironment{decl*}[1][]{%
+ \par
+ \small
+ \addvspace{2.3ex}%
+ \vskip -\parskip
+ \ifx\relax#1\relax
+ \def\@decl@date{}%
+ \else
+ \def\@decl@date{\NEWfeature{#1}}%
+ \fi
+ \noindent\hspace{-\leftmargini}%
+ \begin{tabular}{|l|}%
+ \hline\ignorespaces
+}{%
+ \\\hline
+ \end{tabular}%
+ \nobreak\@decl@date\par\nobreak
+ \vspace{2.3ex}\vskip -\parskip
+}
+\makeatother
+\MakeShortVerb{\|}
+
+
+% Set spacing around captions.
+
+\setlength{\abovecaptionskip}{\medskipamount}
+\setlength{\belowcaptionskip}{\medskipamount}
+
+% Markup for logos, file types, programs, etc.
+
+\newcommand*{\meta}{\m}
+\newcommand*{\marg}{\arg}
+\newcommand*{\parg}[1]{\texttt{(}\m{#1}\texttt{)}}
+
+\newcommand*{\cs}[1]{\texttt{\char`\\ #1}\xspace}
+
+\newcommand*{\OzTeX}{O\kern-.03em z\kern-.15em\TeX}
+\newcommand*{\OzMF}{O\kern-.03em zMF}
+\newcommand*{\OzTools}{O\kern-.03em z\kern-.15em Tools}
+
+\makeatletter
+\newcommand{\La}{%
+ L\kern-.36em
+ {%
+ \setbox0\hbox{T}%
+ \vbox to\ht0{\hbox{%
+ $\m@th$\csname S@\f@size\endcsname
+ \fontsize\sf@size\z@\math@fontsfalse\selectfont
+ A%
+ }\vss}%
+ }%
+}
+\makeatother
+\DeclareRobustCommand\AllTeX{(\La\kern-.075em)\kern-.075em\TeX}
+
+\newcommand{\PS}{Post\-Script\xspace}
+\newcommand{\TT}{True\-Type\xspace}
+
+\newcommand*{\setfilename}[1]{\texttt{#1}}
+\newcommand*{\setdotfilename}[1]{\setfilename{.#1}}
+\newcommand*{\setpackagename}[1]{\textsf{#1}}
+
+\newcommand{\dvips} {\setpackagename{dvips}\xspace}
+\newcommand{\Dvips} {\setpackagename{Dvips}\xspace}
+\newcommand{\fontinst}{\setpackagename{font\-inst}\xspace}
+\newcommand{\Fontinst}{\setpackagename{Font\-inst}\xspace}
+\newcommand{\fontdoc}{\setpackagename{font\-doc}\xspace}
+\newcommand{\Fontdoc}{\setpackagename{Font\-doc}\xspace}
+
+% \show\fontname
+\newcommand{\fontnamekb}{fontname\xspace}
+\newcommand{\Fontnamekb}{Fontname\xspace}
+
+\newcommand{\mf} {\setfilename{mf}\xspace}
+\newcommand{\Mf} {\setfilename{Mf}\xspace}
+\newcommand{\vf} {\setfilename{vf}\xspace}
+\newcommand{\Vf} {\setfilename{Vf}\xspace}
+\newcommand{\pl} {\setfilename{pl}\xspace}
+\newcommand{\Pl} {\setfilename{Pl}\xspace}
+\newcommand{\fd} {\setfilename{fd}\xspace}
+\newcommand{\Fd} {\setfilename{Fd}\xspace}
+\newcommand{\pk} {\setfilename{pk}\xspace}
+\newcommand{\Pk} {\setfilename{Pk}\xspace}
+\newcommand{\afm}{\setfilename{afm}\xspace}
+\newcommand{\Afm}{\setfilename{Afm}\xspace}
+\newcommand{\vpl}{\setfilename{vpl}\xspace}
+\newcommand{\Vpl}{\setfilename{Vpl}\xspace}
+\newcommand{\cvpl}{(\setfilename{v})\setfilename{pl}\xspace}
+\newcommand{\tfm}{\setfilename{tfm}\xspace}
+\newcommand{\Tfm}{\setfilename{Tfm}\xspace}
+\newcommand{\mtx}{\setfilename{mtx}\xspace}
+\newcommand{\Mtx}{\setfilename{Mtx}\xspace}
+\newcommand{\etx}{\setfilename{etx}\xspace}
+\newcommand{\Etx}{\setfilename{Etx}\xspace}
+\newcommand{\enc}{\setfilename{enc}\xspace}
+\newcommand{\Enc}{\setfilename{Enc}\xspace}
+\newcommand{\pfa}{\setfilename{pfa}\xspace}
+\newcommand{\Pfa}{\setfilename{Pfa}\xspace}
+\newcommand{\pfb}{\setfilename{pfb}\xspace}
+\newcommand{\Pfb}{\setfilename{Pfb}\xspace}
+\newcommand{\dvi}{\setfilename{dvi}\xspace}
+\newcommand{\Dvi}{\setfilename{Dvi}\xspace}
+\newcommand{\pdf}{\setfilename{pdf}\xspace}
+\newcommand{\Pdf}{\setfilename{Pdf}\xspace}
+\newcommand{\ttf}{\setfilename{ttf}\xspace}
+\newcommand{\Ttf}{\setfilename{Ttf}\xspace}
+\newcommand{\map}{\setfilename{map}\xspace}
+\newcommand{\Map}{\setfilename{Map}\xspace}
+
+
+\newcommand{\vftovp}{\setpackagename{vftovp}\xspace}
+\newcommand{\vptovf}{\setpackagename{vptovf}\xspace}
+\newcommand{\pltotf}{\setpackagename{pltotf}\xspace}
+\newcommand{\tftopl}{\setpackagename{tftopl}\xspace}
+
+\newcommand{\BibTeX}{Bib\TeX}
+
+
+
+
+\title{fontinst}
+\subtitle{Font installation software for \TeX}
+\author{Alan Jeffrey\and Rowland McDonnell\and Lars Hellstr\"om}
+\illustration{roadmap.eps}
+\version{1.9}
+\date{August 2009}
+
+\begin{document}
+
+\maketitle
+
+
+% \begin{itshape}
+% This manual is currently being rewritten, and may therefore be a
+% bit disorganised. For authoritative information on command syntaxes
+% and the like, see the Literate Programming sources for
+% \fontinst. The main file there is \textsl{\texttt{fisource.tex}}.
+% \end{itshape}
+%
+% \bigskip
+
+\begin{footnotesize}
+ This manual describes the \texttt{fontinst} software for converting
+ fonts from Adobe Font Metric format to forms readable by \TeX. This
+ manual should be distributed with the \texttt{fontinst} software,
+ which is available by anonymous FTP from
+ \url{ftp://ftp.tex.ac.uk/tex-archive/fonts/utilities/fontinst}, and
+ on the various CD-ROMs containing material from the CTAN archives.
+ Please do not contact the author directly for copies.
+
+ If you would like to report a bug with \texttt{fontinst}, please
+ mail \url{fontinst@tug.org}. The mail will be sent to the
+ \texttt{fontinst} mailing list. If you would like to be on the
+ \texttt{fontinst} mailing list, see
+ \url{http://tug.org/mailman/listinfo/fontinst}.
+\end{footnotesize}
+
+\tableofcontents
+
+% \vfill
+
+\clearpage
+
+
+\section{Introduction}
+
+The purpose of \fontinst is to make digital fonts, as they may
+be bought from a foundry or other supplier, usable with \AllTeX;
+in general, they are not directly so. An obvious problem can be
+that the font information is not available in a format that \TeX\
+understands. A more subtle problem is that the fonts are often
+organised in a way that is unsuitable for automatic typesetting.
+It is furthermore necessary to inform \AllTeX\ and related software
+about the existence of the new font, and the pieces of code needed
+to do this are somewhat exotic.
+
+Regarding the first problem, \fontinst can bridge the gap between
+non-\TeX\ and \TeX-specific file formats, but may need some help from
+other tools (\setfilename{pltotf}, \setfilename{vptovf},
+\setfilename{ttf2afm}, etc.) with conversions between text and binary
+file formats. Regarding the last problem, \fontinst can generate the
+necessary code, although you may in some cases need to paste it into
+the right configuration file yourself. It is however with respect to
+the second problem that \fontinst shines, as the many minutiae of
+providing fonts for \AllTeX\ are automated to a very high degree,
+while still providing you as user with the power to fine-tune every
+detail of the output. In addition, \fontinst is available for every
+platform that has \TeX.
+
+The reason \fontinst is so portable is simply that it is written in
+\TeX, exploiting those features of the language which does other
+things than typesetting. A drawback of this is the inability to work
+directly with binary file formats, but an advantage is that users
+do not need to learn a separate command language before they can
+configure the tool; \fontinst only introduces a set of new \TeX\
+commands, not a new set of syntax rules. Moreover, many encoding and
+metric files used with \fontinst can also be typeset as \LaTeX\
+documents, yielding a rendering of their contents which might be more
+pleasing to the eye than the raw code.
+
+The main thing \fontinst does is creating virtual fonts (\vf's). For
+this, it takes the approach that the world is full of glyphs, and a
+subset of these are to be picked, perhaps tweaked, and finally wrapped
+up as a new font for \TeX\ to use. In the basic case where one merely
+wants to make a specific foundry-supplied font available to \TeX, what
+one does is to present only that font as glyphbase for \fontinst, since
+this means all glyphs in the resulting virtual font will come from that
+base font, only reorganised to meet the requirements of \AllTeX. It is
+however not uncommon to use several base fonts for forming a single
+glyphbase, maybe because the foundry has arbitrarily decided to divide
+the basic font up into separate ``base'', ``expert'', and ``alternate''
+varieties that don't match the needs of \TeX, or maybe because the
+foundry did not provide all the glyphs of standard \TeX\ fonts and glyphs
+from some other font family are used to fill in the gaps. Either way,
+since it's you that's doing the packaging, it is you that gets to say
+what goes into the package.
+
+In the process of creating some virtual fonts, many minor pieces of
+data are encounted that would be needed when informing \AllTeX\ and
+related software about these new fonts.
+\Fontinst records this information and provides for writing finished
+files in the most common formats, notably \LaTeX\ \fd files and
+\dvips \map files. One can even ask \fontinst to have certain
+transformations performed on the base fonts, to extend or tweak the
+repertoire of glyph shapes that are available.
+
+
+\subsection{Overview of the process}
+
+If you're using \fontinst, the usual steps you need to take to use
+an ordinary \PS latin text font with \LaTeX\ are these:
+\marginpar{Related commands:}
+\begin{enumerate}
+\item \label{WhatToDoList:1}
+ Gather \afm files for the base fonts you want to make use of, and
+ (optionally) give the \afm files appropriate names.
+\item \label{WhatToDoList:2}
+ Use \fontinst\marginpar{\cs{transformfont}} to produce \texttt{8r}
+ encoded \pl files from these \afm files.
+\item \label{WhatToDoList:3}
+ Use \fontinst\marginpar{\cs{installfont}} to create T1 and OT1
+ encoded \pl and \vpl files from the |8r| encoded \pl files (this
+ procedure will also create suitable \fd files).
+\item \label{WhatToDoList:4}
+ Use \fontinst (its \setfilename{finstmsc.sty}\marginpar{
+ \cs{adddriver}} variety) to generate the mapfile entries needed
+ for the above.
+\item
+ Use \pltotf to turn each \pl file into a \tfm file.
+\item
+ Use \vptovf to turn each \vpl file into a pair of \vf and
+ \tfm files.
+\item
+ Move the \tfm, \vf, and \fd files into the appropriate
+ directories so \LaTeX\ can see them.
+\item
+ Tell your \dvi driver about the new font (typically involves
+ editing some configuration file or files, possibly also running
+ some helper command to update cached configuration information).
+\item
+ Test it. (The \LaTeX\ command \cs{usefont} lets you select a font
+ by encoding, family, series, and shape. The Plain\TeX\ file
+ \setfilename{testfont.tex} provides an easy way of producing font
+ tables.)
+\item
+ Perhaps write a package file to make selecting the new font
+ a little easier.
+\end{enumerate}
+
+The \setfilename{examples\slash basic\slash basicex.tex} file
+contains examples of doing \ref{WhatToDoList:2}
+and~\ref{WhatToDoList:3}; in many cases, it is possible to use the
+|\latinfamily| command to do all of this.
+The \setfilename{examples\slash basic\slash basicex2.tex} file
+contains examples of doing \ref{WhatToDoList:4}.
+
+
+\section{Defining terms}
+
+The process of making fonts usable involves some rather technical
+issues, so in order to understand a discussion of what is going on,
+it is necessary to first get the terminology straight. Feel free to
+skip parts of this if you think you already know the material covered
+or for the moment want to concentrate on other aspects of what
+\fontinst does, but bear in mind that you may then have reason to return
+to this section at a later time.
+
+% This is rather a large and perhaps tedious section. You might be
+% tempted to skip it so you can get to some more direct information on
+% how to use \fontinst. That's fine if you understand everything about
+% how \TeX\ handles fonts. If not, we suggest you at least skim though
+% this section.
+
+\subsection{What's a font?}
+
+Once upon a time, this question was easily answered: a font is a
+set of type in one size, style, etc. There used to be no
+ambiguity, because a font was a collection of chunks of type metal
+kept in a drawer, one drawer for each font.
+
+These days, with digital typesetting, things are more complicated.
+What a font `is' isn't easy to pin down. A typical use of a \PS
+font with \LaTeX\ might use these elements:
+\begin{itemize}
+\item Type 1 printer font file
+\item Bitmap screen font file
+\item Adobe font metric file (\afm file)
+\item \TeX\ font metric file (\tfm file)
+\item Virtual font file (\vf file)
+\item font definition file (\fd file)
+\end{itemize}
+Looked at from a particular point of view, each of these files
+`is' the font. So what's going on?
+
+
+\subsubsection{Type 1 printer font files}
+
+These files contain the information needed by your printer to draw
+the shapes of all the characters in a font. They're typically
+files with a \pfa or \pfb extension; on Macs they're usually in
+files of type `LWFN' and have icons that look like a
+laser printer. The information in all these formats is basically
+the same: the only difference is in its representation. \pfa
+stands for `printer font ASCII', while \pfb stands for `printer
+font binary'. \pfa files are pure \PS code (though in parts highly
+convoluted) and can typically be pasted into or copied from \PS
+documents using a text editor if one feels like hacking. Since \pfa
+files contain a large chunk of hex-encoded binary data, they are
+however about twice the size of the equivalent \pfb, where text and
+binary data reside in separate sections of an overall binary file
+format.
+
+% That is, \pfa files contain plain text information,
+% while \pfb files contain the same information encoded as
+% machine-readable binary data.
+
+% If you have Adobe Type Manager (ATM) installed on your computer,
+% ATM will use these files to draw an accurate representation of the
+% letters on the screen of your computer when you are previewing a
+% \TeX\ document.
+
+Printer font files are not used directly by \TeX\ at all -- \TeX\
+just prepares a \dvi file that refers to the fonts by name and the
+characters by number: \TeX\ knows nothing about the shapes
+involved. The \dvi driver uses the printer font files when you ask
+it to print the \dvi file. This means that you can produce a \dvi
+file which uses, say, Palatino, even if you do not have the
+Type~1 printer font file for this font on your computer. You will
+need to find a computer that does have Palatino before you can
+print it or preview it, though.
+(Pdf\TeX\ is different from \TeX\ in this respect; since pdf\TeX\
+integrates most of the functionality of a \dvi driver, it may be unable
+to generate working \pdf output if the some Type~1 printer font file
+is not available.)
+
+\Dvi drivers generating \pdf often require Type~1 fonts to be in \pfb
+format, as that is very close to how the data is stored in a \pdf
+file.
+
+
+\subsubsection{Bitmap screen font files}
+
+These files contain a low-resolution bitmap for drawing a
+representation of the font on the screen of your computer if ATM
+is not installed. In the \TeX\ world, these files are only used
+for screen previews by \dvi drivers that use the windowing system
+for rendering text.
+% They are kept in font suitcase files on Macintoshes.
+%\marginnote{And where on other computers?}
+
+Technically, \pk files are also bitmap font files, for use on screen
+or with a printer, but \TeX\ systems tend to be set up so that \pk
+files are generated automatically when needed. (Of course, this
+requires that the font is first available in some other format,
+usually \mf or \pfb.)
+
+
+\subsubsection{Adobe font metric files (\afm files)}
+
+These files are text files which contain information about the
+size of each character in a font, kerning and ligature
+information, and so on. They can't be used by \TeX\ directly, but
+the information they contain is essential if you want to use a
+font with \TeX. \Fontinst can from an \afm file create the
+necessary \tfm and \vf files (well, really \pl and \vpl files, but
+see below) so you can use a font with \TeX.
+Once you have created all the files you need to use a font with
+\TeX, you can remove the corresponding \afm files from your
+computer unless you have other software that needs them.
+
+The job of turning an \afm file into a set of \tfm and \vf files
+is one of the main uses for \fontinst. Most of this document is
+concerned with this process, so don't worry if it seems a bit
+vague at the moment.
+
+
+\subsubsection{\TT and OpenType font files}
+
+The \TT format was created as an Apple--Microsoft collaboration to
+avoid being dependent on Adobe's font technologies. Later Adobe and
+Microsoft went on to define the OpenType format, which is a
+development of \TT. However, the three don't always agree on the
+fine details of the format.
+
+A \TT font file is a collection of rather disparate tables, and can
+therefore contain scalable outline fonts (like \PS~type~1), bitmap
+screen fonts, and font metrics all in one file; for software with
+direct support for \TT this tends to simplify font installation, but
+for \TeX\ it rather adds a level of complication. An advantage for
+\TeX\ use is that the suppliers provide font metrics in a
+cross-platform format (as opposed to rather obscure platform-specific
+formats, which could previously be the norm), but they still have to
+undergo conversion before we can use them. \TT is furthermore a
+``there is more than one way to do it'' format, so it sometimes
+happens that information which is present in the font is ignored by
+some programs because that information happened to be in an unusal
+format\dots
+
+Classical \TT fonts have outlines defined in terms of quadratic
+Bezier curves. The main addition in the OpenType specification was a
+second outline format (CFF\slash type~2) which uses cubic Bezier
+curves. Both outline formats are directly supported in \pdf and can
+(even if the driver doesn't have built-in support for the format)
+with a thin wrapper be used in \PS, but there is also a tradition of
+rather converting to type~1 before using such fonts with \TeX; the
+latter leads to a slight drop in quality.
+
+
+
+
+\subsubsection{\TeX\ font metric files (\tfm files)}
+
+These are binary data files in a format designed for use by \TeX\
+which contain (more-or-less) the same information as \afm files:
+the size of each character in a font (font metric data), kerning,
+and ligature information.
+
+When you select a font in \TeX, you are telling \TeX\ to typeset
+using a particular \tfm file; from \TeX's point of view, a \tfm
+file (and nothing else) \emph{is} a font. \TeX\ itself doesn't
+see printer font files, screen bitmaps, \pk files, \vf files, or
+anything else to do with fonts: only \tfm files.
+
+\TeX\ uses these \tfm files to decide where to put characters when
+typesetting. From \TeX's point of view, \tfm files \emph{are}
+fonts, even though they contain no information about the shape of
+letters, and are rarely needed by anything except \TeX. (\Dvi drivers
+generally read \tfm files so that they can keep track of exact glyph
+widths and fine-tune positioning accordingly, but they would get by
+fairly well with only the information in the printer fonts.)
+
+
+\subsubsection{Property list files (\pl files)}
+
+\pl files are human-readable text files which contain all the font
+metric, kerning, ligature, and other information needed to create
+a \tfm file. You can convert between the two file formats using
+\tftopl and \pltotf, which are standard utilities in a \TeX\ system.
+
+
+\subsubsection{Virtual font files (\vf files)}
+
+These are binary data files in a format designed for use by \TeX\
+\dvi drivers. Their main purpose in life is to replace the raw font
+abstraction available in the printer with one more convenient for
+\TeX. These files are used by \dvi driver software only.
+
+\Dvi drivers use \vf files to work out what should \emph{really} be
+printed when you ask for a particular character.
+Technically they are like subroutine libraries for \dvi drivers,
+with one subroutine for each character in the virtual font: when
+the \dvi driver sees a \dvi command to set a character from a virtual
+font, it will execute a sequence of \dvi commands (the ``mapcommands
+property'' of this character) that it reads in the \vf file. You need
+not worry about the details of this, as \fontinst deals with them for
+you. Creating and using virtual fonts is what this document is about,
+so don't worry if this doesn't make sense yet. (After all, how much
+do you need to know about the inner workings of \dvi files to typeset
+and print \TeX\ documents?)
+
+Each \vf file has a \tfm file with the same name. To use a
+virtual font, you select the \tfm file as the font to use in your
+document. When the \dvi driver comes across this \tfm file in the
+\dvi file, it looks up the \vf file and uses that to decide what
+to do.
+
+
+\subsubsection{Virtual property list files (\vpl files)}
+
+\vpl files are human-readable text files which contain all the
+font metric, kerning, mapping, and other information needed to
+create a \vf and \tfm pair.
+
+\vptovf will create a \vf/\tfm pair from a \vpl file. \vftovp
+will create a \vpl from a \vf/\tfm pair. \vftovp also needs to be
+able to read all the \tfm files that are referred to by a \vf to
+recreate the \vpl\ -- it looks at the checksums to verify that
+everything's okay.
+
+
+\subsubsection{Font definition files (\fd files)}
+
+These are files containing commands to tell \LaTeX\ which \tfm
+files to associate with a request for a font using \LaTeX's font
+selection commands.
+
+For example, here is a small and edited part of the \fd file
+supplied with \setpackagename{PSNFSS} to allow you to use the
+Adobe Times font in T1 encoding:
+
+\begin{verbatim}
+ \ProvidesFile{t1ptm.fd}
+ [1997/02/11 Fontinst v1.6 font definitions for T1/ptm.]
+
+ \DeclareFontFamily{T1}{ptm}{}
+
+ \DeclareFontShape{T1}{ptm}{m}{n} {<<->> ptmr8t}{}
+ \DeclareFontShape{T1}{ptm}{m}{it}{<<->> ptmri8t}{}
+ ...
+ \DeclareFontShape{T1}{ptm}{b}{n} {<<->> ptmb8t}{}
+ \DeclareFontShape{T1}{ptm}{b}{it}{<<->> ptmbi8t}{}
+ ...
+\end{verbatim}
+What this means is: when you use \LaTeX\ to select the font family
+|ptm| in T1 encoding in the medium series (|m|) and normal shape
+(|n|), \TeX\ uses the font \texttt{ptmr8t.tfm}. Similarly, if you
+select bold italic, \TeX\ uses \texttt{ptmbi8t.tfm}.
+
+\LaTeX\ works out which \fd file to load based on the current
+encoding and font family selected. If you've selected T1 encoded
+|ptm| like this:
+\begin{verbatim}
+ \fontencoding{T1}\fontfamily{ptm}\selectfont
+\end{verbatim}
+\LaTeX\ loads the file \url{t1ptm.fd} (if it doesn't exist, you're
+in trouble). As you can see above, this file contains information
+so that \LaTeX\ knows which \tfm file to use. So if you ask for,
+say, |T1/ptm/b/it| (T1 encoded Times-Roman, bold series, italic
+shape), you get the font \texttt{ptmbi8t}.
+
+You can find more about \fd files and \LaTeX's font selection commands
+at CTAN:
+\url{ftp://ftp.tex.ac.uk/tex-archive/macros/latex/base/fntguide.tex}
+and \url{ftp://ftp.tex.ac.uk/tex-archive/info/simple-nfss.tex} are
+both useful.
+
+
+\subsubsection{Font mapping files (\map files)}
+
+These are files telling \dvi drivers which printer fonts correspond to
+specific \TeX\ fonts (\tfm files) -- how a specific \TeX\ font should
+be \emph{mapped} onto a font concept available in the \dvi driver's
+output format. Unlike \tfm, \fd, and \vf files,
+which tend to be found as soon as they're in a suitable location
+(such as the current directory), mapfiles typically need to be fully
+installed or selected through a command-line option before any notice
+is taken of them.
+
+The format of mapfiles varies from driver to driver, but a common
+format is that of \dvips, where each line is a separate entry (except
+lines that contain comments). The first word of an entry is the
+\TeX~font name, the second word is the basic printer font name, and
+remaining words provide additional information (e.g., the name of the
+file in which the font is stored).
+
+The default in most \TeX\ systems is that fonts are assumed to be \mf
+fonts unless there is a specific \map file entry which says otherwise.
+Hence if you're trying to use a new Type~1 font, but the \dvi driver
+gives you an error message that `\textit{somefile}\texttt{.mf} not
+found', then the problem is most likely with the mapfiles.
+
+
+
+
+
+
+\subsection{Fonts and characters}
+
+The term `character' (or just `char') is frequently used in
+discussions of fonts, but not always correctly, and when getting into
+the details of what \fontinst does it is necessary to keep the
+terminology straight.
+
+\begin{description}
+\item[Glyph]
+ A glyph is an image, often associated with one or several characters.
+ Some examples of glyphs are:
+ `A', `\textsf{A}', `$\mathcal{A}$', `B', `F',
+ `{\usefont{OT1}{cmr}{m}{n}f}',
+ `{\usefont{OT1}{cmr}{m}{n}fi}', `\~{}'.
+ Fonts are collections of glyphs. \Fontinst refers to glyphs by name.
+\item[Slot]
+ This is jargon for `a numbered position in a font'. (What is
+ important is the number, and that this number refers to a position
+ in a font, but which font is usually specified separately.)
+ For typesetting, \TeX\ identifies glyphs as ``slot $n$ in font $f$''.
+\item[Character]
+ The modern definition is that a character is the smallest component
+ of written language that has semantic value. Speaking of a
+ character, one refers to the abstract meaning, rather
+ than a specific shape.
+
+ Since fonts have often contained a unique glyph for each character
+ and each usable glyph has been assigned a particular slot,
+ it is not uncommon (in particular in older terminology) to see the
+ three mixed up, usually so that one says `character' where one of
+ the other two would have been more correct. The \TeX-related font
+ file formats is no exception, as you may see examples of elsewhere
+ in this document.
+\item[Encoding]
+ There are really two different encoding concepts that one encounters
+ when using \fontinst. The differences are not great, and an
+ encoding of one kind often corresponds to an encoding of the other
+ kind, but it is not merely a matter of translation.
+
+ A \emph{\LaTeX\ encoding} is a mapping from characters (or more
+ formally \LaTeX\ Internal Character Representations) to slots.
+ In the \texttt{OT1} encoding, `\o' (or more technically `|\o|') maps
+ to slot~28, whereas in the \texttt{T1} encoding it maps to slot~248.
+ This kind of encoding affects what \TeX\ is doing; \dvi drivers are
+ not involved.
+
+ A \emph{font encoding} (or \emph{encoding vector}) is a mapping from
+ slots to glyph names. This is the kind of encoding that \fontinst
+ primarily deals with, and also the kind of encoding that \dvi
+ drivers make use of. \texttt{ot1.etx} associates slot~28 with
+ `\texttt{oslash}', whereas \texttt{t1.etx} and \texttt{EC.enc} (one
+ of several to \texttt{T1} corresponding encoding vectors that come
+ with \dvips) associates slot~28 with `\texttt{fi}'.
+
+ \LaTeX\ encodings occur in \fontinst only as names and only in
+ relation to \fd files. It is unlikely that you will need to create
+ one of your own. The mappings defined by font encodings are on the
+ other hand of great importance and \etx files are used to direct
+ the generation of virtual fonts. Advanced \fontinst users may well
+ find that they need to create new font encodings to achieve their
+ goals.
+\end{description}
+
+\fontinst creates \vpl and \pl files from \afm or \pl files to map
+any glyph or combination of glyphs in the original font files to
+any slot in the output font file. There, isn't that better? Off
+you go now\ldots
+
+% You're probably familiar with ASCII
+% encoding, which has the letter `A' in slot~65, `B' in slot~66,
+% and so on. That's it, really. \TeX\ uses several different
+% encodings. The most common ones are OT1 (the original \TeX\
+% 7~bit encoding) and T1 (the newer \TeX\ 8~bit encoding).
+% % -- much more on this later.
+
+The thing is that the average \PS font comes in Adobe standard
+encoding, which, for example, has the glyph dotless~i `\i' in
+slot~245. But \TeX\ \texttt{T1} encoding expects the glyph o~dieresis
+`{\"o}' in that slot, and wants dotless~i in slot~25. So if you
+tried to use a raw \PS font with \TeX, any time you tried to get
+an `\"o', you'd get a `\i'; and every time you tried to get a `\i',
+you'd get a blank, because Adobe standard encoding says that
+slot~25 is empty. The process of dealing with this problem is
+called `re-encoding', and is one thing \fontinst helps with.
+
+% This might not make much sense yet; the best thing to do is relax.
+% There's a lot of things that need to be dealt with when you're
+% setting up \LaTeX\ to use a new font, so you can expect to be a
+% bit confused until you've done it a few times.
+
+
+\subsection{What are verbatim, typewriter, and monowidth fonts?}
+
+The verbatim, typewriter, and monowidth concepts are common sources
+of confusion for those who use \fontinst to install fonts
+with \LaTeX; in particular
+there are many misconceptions about the relation between them. The
+official view (of which not much has actually been brought forward)
+is that these concepts are really about three quite different things.
+
+A font is a \emph{monowidth} (monospaced, fixed-pitch) font if all
+glyphs in it have exactly the same width. Some font formats make
+special provisions for such fonts; the most notable example is the
+\afm format, where a single \texttt{CharWidth} keyword specifies the
+width for all glyphs in the font. \Fontinst responds to this
+by including the command
+\begin{quote}
+ |\setint{monowidth}{1}|
+\end{quote}
+in the \mtx file generated from an \afm, but that is everything that is
+hard-wired into the program. That a font is monowidth is however
+something that one should take note of when installing it for \TeX,
+as it means many of the glyphs in it have such a strange appearance
+that they are (pretty much) useless. The \texttt{endash} is for
+example usually only half as long as the \texttt{hyphen} and the
+letters in ligature glyphs are only half as wide as normal letters.
+Many of the \etx and \mtx files that come with \fontinst
+contain special commands to avoid making use of such degenerate
+glyphs.
+
+That a font is a \emph{typewriter} font really only means that it has
+a typewriterish look about it. The two most familiar typewriter fonts
+are probably Computer Modern Typewriter (\texttt{cmtt}) and Courier.
+Both of these fonts are monowidth, but there is no absolute rule about
+this. One of the standard \TeX\ fonts is for example Computer Modern
+Variable-width Typewriter (\texttt{cmvtt}), which is not a monowidth
+font, as Figure~\ref{Fig:TTvsVTT} shows.
+\begin{figure}
+ \begin{tabular}{ll}
+ \texttt{cmtt}:& \fontfamily{cmtt}\selectfont
+ The quick brown fox jumps over the lazy dog.\\
+ \texttt{cmvtt}:& \fontfamily{cmvtt}\selectfont
+ The quick brown fox jumps over the lazy dog.
+ \end{tabular}
+ \caption{Two typewriter fonts}
+ \label{Fig:TTvsVTT}
+\end{figure}
+
+The verbatim concept has very little to do with fonts at all; in
+\LaTeX\ it is considered to be a property of the environment
+(\texttt{verbatim}, \texttt{macrocode}, etc.) rather than a property
+of the font. The connection there is with fonts is that the encoding
+of the font must contain visible ASCII (as defined in Appendix~C
+of \emph{The \TeX book}%~\cite{TeXbook}
+) as a subset for the text to
+be rendered correctly. The \texttt{cmtt} family is the only one amongst
+the original Computer Modern fonts which meets this criterion and
+that is the primary grounds for the idea that these three concepts
+should be connected. Today that reason is at best a very weak one, as
+all \texttt{T1}-encoded fonts also meet the criterion of containing
+visible ASCII as a subset.
+
+A circumstance which has probably added to the confusion is that
+\texttt{OT1} is usually claimed to be one encoding. In reality the
+Computer Modern fonts that are declared in \LaTeX\ as being
+\texttt{OT1} display as many as five different encodings, as shown in
+Table~\ref{Tab:OT1-fonts}.
+\begin{table}[!tb]
+ \DeleteShortVerb{\|}
+ \begin{tabular}{l|c|c|c|}
+ & \texttt{TEX TEXT}&
+ \begin{tabular}[b]{c}
+ \texttt{TEX TEXT}\\
+ \texttt{WITHOUT}\\
+ \texttt{F-LIGATURES}
+ \end{tabular}&
+ \begin{tabular}[b]{c}\texttt{TEX}\\
+ \texttt{TYPEWRITER}\\
+ \texttt{TEXT}
+ \end{tabular}\\
+ \hline
+ non-italic&
+ \begin{tabular}{l}
+ \texttt{cmb10}\\
+ \texttt{cmbx5}--\texttt{12}\\
+ \texttt{cmbxsl10}\\
+ \texttt{cmdunh10}\\
+ \texttt{cmff10}\\
+ \texttt{cmfib8}\\
+ \texttt{cmr6}--\texttt{17}\\
+ \end{tabular}
+ \begin{tabular}{l}
+ \texttt{cmsl8}--\texttt{12}\\
+ \texttt{cmss8}--\texttt{17}\\
+ \texttt{cmssbx10}\\
+ \texttt{cmssdc10}\\
+ \texttt{cmssi8}--\texttt{17}\\
+ \texttt{cmssq8}\\
+ \texttt{cmssqi8}\\
+ \texttt{cmvtt10}
+ \end{tabular}&
+ \begin{tabular}{l}
+ \texttt{cmcsc8}--\texttt{10}\\
+ \texttt{cmr5}
+ \end{tabular}&
+ \begin{tabular}{l}
+ \texttt{cmsltt10}\\
+ \texttt{cmtcsc10}\\
+ \texttt{cmtt8}--\texttt{12}
+ \end{tabular}\\
+ \hline
+ italic&
+ \begin{tabular}{l}
+ \texttt{cmbxti10}\\
+ \texttt{cmfi10}\\
+ \texttt{cmti7}--\texttt{12}\\
+ \texttt{cmu10}
+ \end{tabular}&&
+ \begin{tabular}{l}
+ \texttt{cmitt10}
+ \end{tabular}\\
+ \hline
+ \end{tabular}
+ \MakeShortVerb{\|}
+ \caption{``\texttt{OT1}-encoded'' Computer Modern fonts, collected
+ according to the actual font encoding}
+ \label{Tab:OT1-fonts}
+\end{table}
+Since most monowidth fonts are only used for setting verbatim text,
+there is some code in \texttt{ot1.etx} which automatically chooses a
+\texttt{TEX TYPEWRITER TEXT} encoding for the font when the
+\texttt{monowidth} integer is set. The only reason for this is the
+guess that this is what the user wanted.
+
+
+
+\section{Fontmaking commands}
+
+There are three main types of files that you may write to control what
+\fontinst does: \emph{command files} (usually with suffix
+\setdotfilename{tex}), \emph{encoding definition files} (suffix
+\setdotfilename{etx}), and \emph{metric files} (suffix
+\setdotfilename{mtx}). Command files directly tell \fontinst to do
+things, whereas the purpose of an encoding or metric file is more to
+store data, but all three file types are technically sequences of
+\TeX\ commands that \fontinst execute when reading the file. Normal
+\TeX\ syntax rules apply in all three file types, although a few
+commands may behave in unfamiliar ways.
+
+Within the command file category, it is possible to discern certain
+subcategories. Most command files are written for one particular
+task, but some are common pieces that have been factored out from
+larger command files and are merely meant to be |\input| where
+appropriate. (\setfilename{csc2x.tex} in the \fontinst distribution is
+an example of this latter kind.) One may also distinguish between
+command files that are made for use with \setfilename{fontinst.sty}
+command definitions and command files that are made for use with
+\setfilename{finstmsc.sty} command definitions. This section documents
+the commands that are particular to the former category, whereas the
+next section documents commands that are particular to the latter.
+
+
+\subsection{Install commands}
+
+The core fontmaking takes place within a block of ``install
+commands''. (This name is a bit unfortunate since nothing is actually
+installed; rather some files that need to be installed are generated.)
+Such blocks have the structure
+\begin{quote}
+ |\installfonts|\\
+ \m{install commands}\\
+ |\endinstallfonts|
+\end{quote}
+The \m{install commands} describe the fonts, glyphs and encodings used
+to build fonts, whereas the purpose of the delimiting |\installfonts|
+and |\end|\-|install|\-|fonts| are rather to organise the writing
+of \fd files.
+
+\begin{decl*}
+ |\installfonts|\\
+ |\endinstallfonts|
+\end{decl*}
+At |\installfonts|, \fontinst's internal list of \fd files to generate
+are cleared. At |\endinstallfonts|, \fd files are written for those
+combinations of encoding and font family that appeared in the
+\meta{install commands}.
+
+\begin{hackernote}
+ |\installfonts|, |\endinstallfonts|, and the individual
+ install commands between them also cooperate in a rather complicated
+ grouping scheme to cache glyphbases. This may interfere with
+ non-\fontinst commands in the \meta{install commands}. If for
+ example an assignment to some |\tracing|\dots\ parameter here does
+ not seem to have any effect, try making the assignment |\global|.
+\end{hackernote}
+
+The most important \meta{install command} is
+\begin{decl*}
+ |\installfont|\arg{font-name}\arg{metrics-list}\arg{etx-list}\\
+ \hspace*{1.5em}\arg{encoding}\arg{family}\arg{series}%
+ \arg{shape}\arg{size}
+\end{decl*}
+This produces a \TeX\ virtual font called \m{font-name}. The
+\meta{metrics-list} and the \meta{etx-list} determine this font,
+whereas the other arguments specify how the \fd file will declare it
+for \LaTeX. The \m{encoding}, \m{family}, \m{series}, and \m{shape}
+are precisely the NFSS parameters. The \m{size} is either a shorthand
+declared by \verb|\declaresize| (see below), or is an \fd size
+specification.
+
+Like most \fontinst lists, the elements in the \meta{metrics-list} and
+\meta{etx-list} are separated by commas (so-called comma-separated
+lists). In their simplest form, the elements of these lists are file
+names (minus suffixes): \mtx files in the \meta{metrics-list} and
+\etx files in the \meta{etx-list}. First the \mtx files are processed
+to build up a glyphbase, i.e., store definitions of glyphs and their
+metric properties in memory, and then the \etx files are processed
+(several times) to select a set of glyphs and write the corresponding
+information to a \vpl file.
+
+For example, to install the \texttt{T1}-encoded Times Roman font
+(using \texttt{t1.etx} and \texttt{latin.mtx}), you say:
+\begin{verbatim}
+ \installfont{ptmr8t}{ptmr8r,latin}{t1}
+ {T1}{ptm}{m}{n}{}
+\end{verbatim}
+To install a \texttt{OT1}-encoded Times Roman font, with a scaled
+version of Symbol for the Greek letters, you say:
+\begin{verbatim}
+ \installfont{zptmrsy}{ptmr8r,psyr scaled 1100,latin}{ot1}
+ {OT1}{ptm}{m}{n}{}
+\end{verbatim}
+
+As the second example indicates, there is more to the list items than
+just file names. In the case of an metrics list item, the syntax
+permits the two forms
+\begin{decl*}
+ \meta{filename}\meta{optional modifiers}\\
+ |\metrics| \meta{metric commands}
+\end{decl*}
+\NEWfeature{v1.923}
+where an \meta{optional modifier} is one of
+\begin{decl*}
+ \verb*| scaled |\meta{rawscale factor}\\
+ \verb*| suffix |\meta{glyph name suffix}\\
+ \verb*| encoding |\meta{etx}\\
+ \verb*| option |\meta{string}
+\end{decl*}
+A list item may contain several such modifiers, but most commonly it
+does not contain any. The
+\meta{metric commands} are explicit metric commands, as described in
+Section~\ref{Sec:Metric}; this latter feature is meant for minor
+adjustments that you don't want to bother creating a separate \mtx
+file for.
+
+The \meta{filename} above primarily refers to a file
+\meta{filename}\texttt{.mtx}, but that need not always exist before
+executing the above command. If there exists a \pl, \afm, or \vpl file
+with the right name then that is first converted to a corresponding
+\mtx file. However, a special case occurs if there is an |encoding|
+modifier: this forces conversion of a \pl or \vpl file even if an
+\mtx file exists, and also forces using the specified \etx file when
+assigning glyph names to the slots of that file. Normally the choice
+of \etx file for such conversions to \mtx is based on
+|\declareencoding| declarations.
+
+The |scaled| modifier sets the \texttt{rawscale} variable for the
+processing of that file. This has the effect of scaling all raw
+glyphs from that file to \meta{rawscale factor} per milles of their
+previous size. The |suffix| modified causes the \meta{glyph name
+suffix} to be implicitly appended to all glyphs defined by this file.
+The |option| modifier adds the \meta{string} to the list of ``options''
+for this file. The |\ifoption| command can be used in the file to test
+whether a particular string has been supplied as an option.
+
+\begin{hackernote}
+ In general, \fontinst commands process comma-separated list arguments
+ by first splitting at commas and then fully expanding each item, but
+ this \meta{metrics-list} argument is an exception. This is first
+ fully expanded (|\edef|) and then split into items. The difference
+ is that a macro used in this \meta{metrics-list} argument can expand
+ to several list items, whereas a macro used in an ordinary
+ comma-separated list argument can only expand to (part of) a single
+ list item.
+
+ The |\metrics| list items do however constitute an exception within
+ this exception. These list items are in their entirety protected
+ from the initial full expansion, so you don't have to worry about
+ peculiar fragility errors there.
+\end{hackernote}
+
+The elements in the \meta{etx-list} have fewer variants, but there is
+still a general syntax
+\begin{decl*}
+ \meta{filename}\meta{optional modifiers}
+\end{decl*}
+The \meta{optional modifier}s permitted are:
+\begin{decl*}
+ \verb*| mtxasetx|\\
+ \verb*| option |\meta{string}
+\end{decl*}
+The \texttt{option} one is as for metric files. \texttt{mtxasetx} is
+probably only relevant for use with |\installrawfont| (see below).
+
+
+\begin{decl}[v1.912]
+ |\installfontas|\arg{font-name}\\%
+ \hspace*{1.5em}\arg{encoding}\arg{family}\arg{series}%
+ \arg{shape}\arg{size}
+\end{decl}
+This install command adds an \fd entry for the \meta{font-name}, but
+it doesn't actually generate that font. Usually that font was
+generated by a previous |\installfont|, and this is used to create
+additional entries for the font.
+
+
+\begin{decl}
+ |\installrawfont|\arg{font-name}\arg{metrics-list}\arg{etx-list}\\
+ \hspace*{1.5em}\arg{encoding}\arg{family}\arg{series}%
+ \arg{shape}\arg{size}
+\end{decl}
+This is similar to |\installfont| except that it produces
+a \TeX\ raw font as \pl file rather than a virtual font. Often a \pl
+file with the specified name will already exist when this command is
+called, and that will then be overwritten. These two \pl files will
+typically be somewhat different.
+The normal reason for using this command is that one wishes to
+``refine'' the metrics of a font that was generated by transformation
+commands.
+
+For example, to install an \texttt{8r}-encoded Times Roman raw font
+(using \texttt{8r.etx} and \texttt{8r.mtx}), you say:
+\begin{verbatim}
+ \installrawfont{ptmr8r}{ptmr8r,8r}{8r}
+ {8r}{ptm}{m}{n}{}
+\end{verbatim}
+(The files referred to are, in order, \texttt{ptmr8r.pl},
+\texttt{ptmr8r.mtx}, \texttt{8r.mtx}, and \texttt{8r.etx}.)
+
+The effect of a
+\begin{decl*}[v1.923]
+ \meta{filename}\verb*| mtxasetx|
+\end{decl*}
+in the \meta{etx-list} is not that \meta{filename}\texttt{.etx} is
+read, but that \meta{filename}\texttt{.mtx} is read. The
+interpretation of the commands in this file is however not the
+customary, and almost the only thing paid attention to is the
+correspondence between glyph names and slot numbers that is provided
+by the |\setrawglyph| and |\setscaledrawglyph| commands; this
+correspondence is treated as if it was given by |\setslot| \dots\
+|\endsetslot| commands in an \etx file. This is however only
+guaranteed to work with transformable metric files.
+
+The purpose of this feature is to simplify installation of fonts with
+very special encodings, such as ``Dingbat'' or ``Pi'' fonts. Instead
+of creating an \etx file, which would probably only be useful with
+that particular font, one can make use of the fact that the
+interesting information is anyway available in the \mtx file. To
+install Zapf Dingbats in their default encoding, one can thus say
+\begin{verbatim}
+ \installrawfont{pzdr}{pzdr}{pzdr mtxasetx}
+ {U}{pzd}{m}{n}{}
+\end{verbatim}
+
+Unlike the case with |\installfont|, which actually creates a real
+(although virtual) font, |\installrawfont| can only create the
+metrics for a font. The \dvi driver will require some other kind of
+implementation of this font, usually an entry in some map file (e.g.
+\texttt{psfonts.map}, in the case of \dvips) that links the \TeX\ font
+name to e.g.\ a \PS\ font name and file. (Many \dvi drivers are
+configured in such a way that they, without such a map file entry,
+will call Metafont with the font name and thereby raise a sequence of
+error messages about a \setdotfilename{mf} that doesn't exist. These
+results are often rather confusing.)
+
+
+
+\begin{decl}
+ |\installfamily|\arg{encoding}\arg{family}\arg{fd-commands}
+\end{decl}
+This tells \fontinst to write an \fd file for the given combination
+of encoding and family, and clears the internal list of entries to
+put in that file. |\installfamily| commands usually come first in each
+block of \meta{install commands}.
+
+For example, if you intend to produce a \texttt{T1}-encoded Times
+family of fonts, you say:
+\begin{verbatim}
+ \installfamily{T1}{ptm}{}
+\end{verbatim}
+The \m{fd-commands} are executed every time a font in that family is
+loaded, for example to stop the Courier font from being hyphenated you
+say:
+\begin{verbatim}
+ \installfamily{T1}{pcr}{\hyphenchar\font=-1}
+\end{verbatim}
+In more recent versions of \fontinst, the |\installfamily| command is
+only necessary if you want the \m{fd-commands} argument to be
+nonempty, but it doesn't hurt to make it explicit.
+
+\begin{hackernote}
+ The \m{fd-commands} argument is tokenized with the current catcodes
+ and written to file without expansion. In particular this means
+ that spaces will be inserted after all control sequences whose
+ names consists of letters, which can be unexpected if you intend to
+ make use of control sequences whose names contain |@| characters.
+
+ One way around this is to use |\fontinstcc| and |\normalcc| to
+ temporarily switch catcodes around the |\installfamily| command.
+\end{hackernote}
+
+
+
+\subsection{Transformation commands}
+
+
+\begin{decl}
+ |\transformfont|\arg{font-name}\arg{transformed font}
+\end{decl}
+This makes a raw transformed font, for example expanded, slanted,
+condensed or re-encoded. \emph{It is the responsibility of the device
+ driver to implement this transform.} Each \verb|\transformfont|
+command writes out an \mtx file and a raw \pl file for \m{font-name}.
+
+The following commands are valid \m{transformed font}s:
+\begin{decl*}
+ |\fromafm|\arg{afm}\\
+ |\fromany|\arg{whatever}\\
+ |\frompl|\arg{pl}\\
+ |\fromplgivenetx|\marg{pl}\marg{etx}\\
+ |\frommtx|\arg{mtx}
+\end{decl*}
+These read the metrics of the font which is about to be transformed from
+an external file. |\fromafm|, |\frompl|, and |\fromplgivenetx| write out
+an \mtx file corresponding to the \afm or \pl file. In addition,
+|\fromafm| also writes out a raw \pl file, containing just the glyph
+metrics but no kerning information. |\fromplgivenetx| permits
+specifying which encoding file to use when associating glyph names to
+slots, whereas |\frompl| tries to guess this from the
+\texttt{CODINGSCHEME} property of the \pl file. |\fromany| looks for
+a file in any of the formats (in the order \mtx, \pl, \afm) and
+behaves as the first |\from|\dots\ for which it found a file.
+
+A \m{transformed font} may also be one of the following:
+\begin{decl*}
+ |\scalefont|\arg{integer expression}\arg{transformed font}\\
+ |\xscalefont|\arg{integer expression}\arg{transformed font}\\
+ |\yscalefont|\arg{integer expression}\arg{transformed font}\\
+ |\slantfont|\arg{integer expression}\arg{transformed font}
+\end{decl*}
+This applies a geometric transformation to the font metrics of
+\m{transformed font}. The scale factor or slant factor are given in
+units 1000 to the design size. Typical examples are 167 for slanted
+fonts (a slant of $\frac{1}{6}$) or 850 for condensed fonts (shrunk
+to 85\% of their natural width).
+
+The final case of a \m{transformed font} is:
+\begin{decl*}
+ |\reencodefont|\arg{etx}\arg{transformed font}
+\end{decl*}
+This rearranges the encoding vector of \m{transformed font} to match
+the encoding given by the \etx file.
+
+
+For example, to create an oblique, |8r|-encoded version of Adobe Times
+called \texttt{ptmro8r} you say:
+\begin{verbatim}
+ \transformfont{ptmro8r}{
+ \reencodefont{8r}{
+ \slantfont{167}{\fromafm{ptmr8a}}
+ }
+ }
+\end{verbatim}
+This will create \texttt{ptmr8a.mtx}, \texttt{ptmr8a.pl},
+\texttt{ptmro8r.mtx} and \texttt{ptmro8r.pl}, which can then be used
+as raw fonts in \verb|\installfont| commands. The equivalent
+transformation can also be achieved in two steps:
+\begin{verbatim}
+ \transformfont{ptmr8r}{\reencodefont{8r}{\fromafm{ptmr8a}}}
+ \transformfont{ptmro8r}{\slantfont{167}{\frommtx{ptmr8r}}}
+\end{verbatim}
+This will create \texttt{ptmr8a.mtx}, \texttt{ptmr8a.pl},
+\texttt{ptmr8r.mtx}, \texttt{ptmr8r.pl}, \texttt{ptmro8r.mtx} and
+\texttt{ptmro8r.pl}.
+
+You will have to inform your device driver about the transformed font,
+using the syntax appropriate for that driver. For example, in \dvips
+you add a line to \texttt{psfonts.map}:
+\begin{verbatim}
+ ptmro8r Times-Roman ".167 SlantFont TeXBase1Encoding ReEncodeFont" <<8r.enc
+\end{verbatim}
+See Section~\ref{Sec:Mapmaking} and
+Subsection~\ref{Ssec:MapFragments} for details on how to generate
+such lines automatically.
+
+
+\subsection{The \cs{latinfamily} command}
+
+
+\begin{decl}
+ |\latinfamily|\marg{family}\marg{commands}
+\end{decl}
+This command is by itself an entire |\installfonts| \dots\
+|\endinstallfonts| block, automatically doing |\transformfont|s,
+|\installfont|s, and |\install|\-|raw|\-|font|s depending on which
+base font metrics it finds. It generates virtual fonts in the
+\texttt{T1}, \texttt{OT1}, and \texttt{TS1} encodings.
+
+There is really much to much about this command for it to be described
+in full here. Please see other available documentation.
+
+\begin{decl}
+ |\fakenarrow|\marg{width factor}
+\end{decl}
+This command makes |\latinfamily| fake `narrow' fonts in the family it
+is working on, by $x$-scaling the normal fonts. The \meta{width factor}
+is the scale factor to use.
+
+
+\subsection{Reglyphing commands}
+
+``Reglyphing'' is an \mtx file transformation that changes glyph
+names but leaves the slot numbers and metrics as they were;
+optionally it may drop some of the metric commands. See
+Subsection~\ref{Ssec:Des:Reglyph} for an introduction to this.
+
+Like installation commands, reglyphing commands are preferably placed
+in a block between two delimiter commands:
+\begin{decl*}
+ |\reglyphfonts|\\
+ \meta{reglyphing commands}\\
+ |\endreglyphfonts|
+\end{decl*}
+The purpose of these delimiter commands is to delimit the scope in
+which the various declarations made take effect. After
+|\endreglyphfont|, you're back to the ``clean'' state that existed
+before the |\reglyphfont|.
+
+\begin{decl}
+ |\reglyphfont|\marg{destination font}\marg{source font}
+\end{decl}
+This is the only command that actually does something; all the other
+commands simply set parameters for the processing carried out here.
+What the command does is that it reads the \meta{source font} (which
+may be in \mtx, \pl, \afm, or \vpl format, but will be converted to
+\mtx before it is read for reglyphing) and writes each command back to
+the \meta{destination font} (in \mtx format \emph{only}), but often
+with some subtle modifications.
+
+It should be observed that the ``destination font'' generated by this
+command is not a real font, but just an \mtx file. If that \mtx file
+contains raw glyph defintions (|\setscaledrawglyph| commands) then
+these will refer to the \meta{source font}, so that is all a \dvi
+driver needs to be informed about.
+
+\begin{decl}
+ |\renameglyph|\marg{to}\marg{from}\\
+ |\renameglyphweighted|\marg{to}\marg{from}\marg{weight}\\
+ |\killglyph|\marg{glyph}\\
+ |\killglyphweighted|\marg{glyph}\marg{weight}
+\end{decl}
+The |\renameglyph| and |\renameglyphweighted| commands cause each
+reference to the glyph \meta{from} in the source font to be replaced
+by a reference to the glyph \meta{to} in the destination font. Thus if
+the source font contains a command that sets a glyph with the name
+\meta{from}, then this will in the destination font be changed to a
+command that sets a glyph with the name \meta{to}, but with the same
+metrics, slot, and base font name as in the source font. Kerns are
+similarly adjusted to be for the \meta{to} glyph.
+
+There is also a ``weight'' associated with each command being copied
+from source font to destination font, and if that weight is too small
+then the command will be omitted from the destination font. The weight
+of a command is the sum of the weights of all glyphs mentioned in that
+command. A glyph for which no settings have been made has weight $0$.
+A glyph name which is the \meta{from} of a |\renameglyphweighted| or
+the \meta{glyph} of a |\killglyphweighted| has the \meta{weight}
+specified there. A \meta{from} glyph of a |\renameglyph| gets the
+weight stored in the \texttt{renameweight} integer variable
+(by default $1$) and the \meta{glyph} of a |\killglyph| gets the
+weight stored in the \texttt{killweight} integer variable (by default
+$-10$). It is this large negative weight that makes |\killglyph|
+``kill'' glyphs.
+
+The weight condition for keeping a command is given by the
+|\iftokeep| command, which is regarded as a \fontinst command
+variable (see Section~\ref{Sec:Variables}). The default definition is
+to keep things with non-negative weight (typically everything that
+doesn't involve a glyph that has been killed), but for example
+\setfilename{csckrn2x.tex} redefines it to only keep things with
+positive weight (typically everything involving at least one glyph
+that has been renamed and not any that has been killed).
+
+
+\begin{decl}
+ |\offmtxcommand|\marg{command}\\
+ |\onmtxcommand|\marg{command}
+\end{decl}
+Turning a command `off' using |\offmtxcommand| means no such commands
+are to be copied to a destination font by |\reglyphfont|. Turning it
+back `on' using |\onmtxcommand| restores it to normal, i.e., whether
+it is copied depends on the weight of the command.
+
+\begin{hackernote}
+ |\offmtxcommand| and |\onmtxcommand| are wrappers around the
+ general-purpose |\offcommand| and |\oncommand| commands (see
+ Subsection~\ref{Ssec:Variables}). The wrapping makes the general
+ commands to act on a family of internal macros, namely those which
+ are used by |\reglyphfont| as definitions of the transformable
+ metric commands.
+\end{hackernote}
+
+
+\subsection{Miscellaneous settings}
+
+\begin{decl}
+ |\substitutesilent|\arg{to}\arg{from}\\
+ |\substitutenoisy|\arg{to}\arg{from}
+\end{decl}
+This declares a \LaTeX\ font substitution, that the series or shape
+\m{to} should be substituted if necessary by the series or shape
+\m{from}. Font substitutions happen at |\endinstallfonts| time, and
+cause font declarations using |sub| or |ssub| to be added to the \fd
+files being written.
+
+\verb|\substitutenoisy| means that a warning will be given when
+the substitution is made by \LaTeX.
+\verb|\substitutesilent| means that \LaTeX\ should not warn when
+the font substitution is made.
+
+For example, to say that the series |bx| can be replaced by the
+series |b| (a request for series |bx| selects a font with actual series
+|b|), you say:
+\begin{verbatim}
+ \substitutesilent{bx}{b}
+\end{verbatim}
+To say that the shape |ui| can be replaced by the shape |it| (a
+request for shape |ui| selects a font with actual shape |it|), you say:
+\begin{verbatim}
+ \substitutenoisy{ui}{it}
+\end{verbatim}
+
+The following weight substitutions are standard:
+\begin{verbatim}
+ \substitutesilent{bx}{b}
+ \substitutesilent{b}{bx}
+ \substitutesilent{b}{sb}
+ \substitutesilent{b}{db}
+ \substitutesilent{m}{mb}
+ \substitutesilent{m}{l}
+\end{verbatim}
+The following shape substitutions are standard:
+\begin{verbatim}
+ \substitutenoisy{ui}{it}
+ \substitutesilent{it}{sl}
+ \substitutesilent{sl}{it}
+\end{verbatim}
+In order to disable a default substitution, use the \meta{from} for
+both arguments.
+
+The |\installfontas| command should be considered as an
+alternative to using font substitution, as it gives much finer
+control over what \fd entries will be made.
+
+
+\begin{decl}
+ |\declaresize|\arg{size}\arg{fd-size-range}
+\end{decl}
+This declares a new size shorthand, and gives the \fd size
+specifications for it. For example, \url{fontinst.sty} declares
+the following sizes:
+\begin{verbatim}
+ \declaresize{}{<<->>}
+ \declaresize{5}{<<5>>}
+ \declaresize{6}{<<6>>}
+ \declaresize{7}{<<7>>}
+ \declaresize{8}{<<8>>}
+ \declaresize{9}{<<9>>}
+ \declaresize{10}{<<10>>}
+ \declaresize{11}{<<10.95>>}
+ \declaresize{12}{<<12>>}
+ \declaresize{14}{<<14.4>>}
+ \declaresize{17}{<<17.28>>}
+ \declaresize{20}{<<20.74>>}
+ \declaresize{25}{<<24.88>>}
+\end{verbatim}
+The first of these is what gives an empty \meta{size} argument for
+the font installation commands the meaning ``all sizes''.
+
+\begin{decl}
+ |\declareencoding|\arg{string}\arg{etx}
+\end{decl}
+This declares which \etx file corresponds to which
+\texttt{CODINGSCHEME} string, and is used when reading metrics in \pl
+format. For example, \url{fontinst.sty} declares the following
+encoding strings:
+\begin{verbatim}
+ \declareencoding{TEX TEXT}{ot1}
+ \declareencoding{TEX TEXT WITHOUT F-LIGATURES}{ot1}
+ \declareencoding{TEX TYPEWRITER TEXT}{ot1tt}
+ \declareencoding{TEX MATH ITALIC}{oml}
+ \declareencoding{TEX MATH SYMBOLS}{oms}
+ \declareencoding{TEX MATH EXTENSION}{omx}
+ \declareencoding{EXTENDED TEX FONT ENCODING - LATIN}{t1}
+ \declareencoding{TEX TEXT COMPANION SYMBOLS 1---TS1}{ts1}
+ \declareencoding{TEXBASE1ENCODING}{8r}
+ \declareencoding{TEX TYPEWRITER AND WINDOWS ANSI}{8y}
+\end{verbatim}
+
+
+\subsection{Low-level conversion commands}
+
+The following commands are the low-level commands which carry out
+various conversions. There's usually no need to bother about them
+unless you are hacking \fontinst, but you may see them in the header
+comments of files \fontinst generates, so here's a description of what
+they do and when they are used.
+
+\begin{decl}
+ |\afmtomtx|\marg{afmfile}\marg{mtxfile}\\
+ |\generalpltomtx|\marg{plfile}\marg{mtxfile}%
+ \marg{plsuffix}\marg{opt-enc}
+\end{decl}
+These handle importing font metric data to the \fontinst native \mtx
+format.
+
+|\afmtomtx| converts metrics in \afm format. It uses the
+\texttt{minimumkern} integer variable and the |\slanteditalcorr| and
+|\uprightitalcorr| command variables.
+
+|\generalpltomtx| converts metrics in \pl or \vpl format. If the
+\meta{opt-enc} string expression is nonempty then that is taken as the
+name of an \etx file that assigns glyph names to the slots in the font.
+
+\begin{decl}
+ |\mtxtomtx|\marg{source MTX}\marg{destination MTX}
+\end{decl}
+This is the heart of the |\transformfont| command. It makes use of the
+\texttt{x-scale}, \texttt{y-scale}, and \texttt{slant-scale} integer
+variables, and the \texttt{etx-name} string variable.
+
+\begin{decl}
+ |\mtxtopl|\marg{mtxfile}\marg{plfile}
+\end{decl}
+This converts \mtx metrics to \pl format; more precisely it generates
+\texttt{CHARACTER} property lists for |\setrawglyph| and
+|\setscaledrawglyph| commands. Kerning information is ignored.
+
+The command is used immediately after an |\afmtomtx| or |\mtxtomtx|.
+The invariant is that if there can be some |\setrawglyph| or
+|\setscaledrawglyph| command which refers to a glyph in some font,
+then there must also be a \pl file with metrics for that font.
+
+\begin{decl}
+ |\etxtovpl|\marg{encoding list}\marg{vplfile}\\
+ |\etxtopl|\marg{encoding list}\marg{plfile}
+\end{decl}
+These are the cores of |\installfont| and |\installrawfont|
+respectively. They don't really convert files---it's more like
+generating a \vpl or \pl under the control of the \etx.
+
+
+
+
+
+
+\subsection{Other}
+
+The following commands also belong in this section, but don't belong
+to any of the major groups.
+
+\begin{decl}
+ |\recordtransforms|\marg{filename}\\
+ |\endrecordtransforms|
+\end{decl}
+See Subsection~\ref{Ssec:MapFragments} for an explanation of how these
+are used.
+
+\begin{decl}
+ |\NOFILES|
+\end{decl}
+This command switches off file generation, and causes \fontinst to
+only generate empty files. It only affects the user level commands,
+so it is primarily of use when debugging commands that build on
+these, such as for example the |\latin|\-|family| command.
+
+
+
+
+
+\section{Mapmaking commands}
+\label{Sec:Mapmaking}
+
+The commands described in this section are for use with command files
+that input \texttt{finstmsc.sty}.
+
+
+\subsection{Mapfile command reference}
+
+For an introduction to making map file entries, see
+Subsection~\ref{Ssec:MapFragments}.
+
+\begin{decl}
+ |\adddriver|\marg{driver name}\marg{fragment file name}
+\end{decl}
+This opens the file \meta{fragment file name} for writing mapfile
+entries to. The \meta{driver name} selects the format of these
+entries. \emph{Note} that if the \meta{fragment file name} does not
+include a suffix, it will get the suffix \setfilename{tex}, which is
+probably not what you want.
+
+\begin{decl}
+ |\makemapentry|\marg{\TeX\ font name}
+\end{decl}
+This causes a mapfile entry for the specified font to be written to
+all files currently open for receiving mapfile entries. These
+commands are usually automatically generated by \fontinst.
+
+\begin{decl}
+ |\donedrivers|
+\end{decl}
+This closes all files open for receiving mapfile entries.
+
+
+\subsection{Drivers}
+
+The \meta{driver name}s that may be used with |\adddriver| are:
+
+\begin{decl}
+ |dvips|
+\end{decl}
+The \dvips driver. The mapfiles generated are useful also with
+pdf\TeX, but one does not always use the exact same file for both;
+sometimes they require different settings.
+
+\begin{decl}
+ |dvipdfm|
+\end{decl}
+The \setpackagename{dvipdfm} \dvi-to-\pdf driver. Not much tested,
+but appears to work.
+
+\begin{decl}[v1.915]
+ |pltotf|
+\end{decl}
+Not really a \dvi driver. The file that is generated is a shell
+script of \texttt{pltotf} commands for converting precisely those \pl
+files which are needed to \tfm files (\fontinst generally generates
+also a bunch of \pl files that in the end turn out to be
+unnecessary). The \texttt{TFMfileprefix} variable can be used to
+specify a path to the directory where these files should be placed.
+
+\begin{decl}
+ |debug|
+\end{decl}
+Not a \dvi driver either, but for each base font a report on the
+information that was available. Useful if you need to write the
+driver file yourself.
+
+\begin{hackernote}
+ Creating a new driver \meta{foo} is mostly a matter of suitably
+ defining the |\make_|\meta{foo} command.
+\end{hackernote}
+
+
+\subsection{Configuration commands}
+\label{Ssec:MapConfig}
+
+The following commands configure the generation of mapfile entries,
+mostly with respect to how various pieces of information are deduced
+from other pieces.
+
+\begin{decl}
+ |\AssumeAMSBSYY|\\
+ |\AssumeBaKoMa|\\
+ |\AssumeMetafont|
+\end{decl}
+These commands change what the map file writer does when it needs to
+know the \PS name for a font but only knows the \TeX\ name. This
+usually happen when the metrics came from a \pl file.
+
+|\AssumeAMSBSYY| tells it to uppercase the \TeX\ name and use that as
+\PS name; this is correct for the AMS\slash Blue~Sky\slash Y\&Y
+conversions of the Computer Modern fonts.
+
+|\AssumeBaKoMa| tells it to lowercase the \TeX\ name and use that as
+\PS name; this is correct for the BaKoMa conversions of the Computer
+Modern fonts.
+
+|\AssumeMetafont| tells it to ignore base fonts for which no \PS name
+is known, on the assumption that they are \mf fonts.
+
+
+\begin{decl}
+ |\AssumeLWFN|
+\end{decl}
+This commands changes what the map file writer does when it needs to
+know the name of the file in which a \PS font is stored. The file name
+is constructed from the \PS font name using the $5+3+3+\cdots$
+convention used in (Classic) Mac~OS.
+
+By default \fontinst uses as \PS font file name the \TeX\ name of the
+font (i.e., the name of the source \afm or whatever file) and appends
+to that the contents of the \texttt{PSfontsuffix} string.
+
+For fonts which fit neither of these schemes, one can give individual
+specifications using the command
+\begin{decl*}
+ |\specifypsfont|\marg{PS font name}\marg{actions}
+\end{decl*}
+Note that the font is here identified using its \PS font name, not the
+\TeX\ font name.
+
+An \meta{action} is one of\footnote{Additional actions can be added
+in the future, if there is a need for them. It is not a problem if not
+all driver can support an action, since all actions typically default
+to \cs{download}.}
+\begin{decl*}[v1.928]
+ |\download|\marg{file}\\
+ |\fulldownload|\marg{file}
+\end{decl*}
+where \meta{file} is a file to download (`download' typically means
+``include in the generated \PS output or equivalent''). The difference
+between |\download| and |\fulldownload| have to do with how partial
+downloading (subsetting) of fonts should be handled. |\download| means
+use the driver's defaults (often settable via command line options)
+for this. |\fulldownload| means don't subset: always include the full
+font, if \fontinst knows how to express this in a map file entry for
+this particular driver.
+
+If FooBar-Regular is a non-subsettable font, then you may specify this
+to \fontinst through a command like
+\begin{verbatim}
+ \specifypsfont{FooBar-Regular}{\fulldownload{foobar.pfb}}
+\end{verbatim}
+To specify that the PDF ``base 14'' fonts do not require downloading,
+one would say
+\begin{verbatim}
+ \specifypsfont{Courier}{}
+ \specifypsfont{Courier-Bold}{}
+ \specifypsfont{Courier-BoldOblique}{}
+ \specifypsfont{Courier-Oblique}{}
+ \specifypsfont{Helvetica}{}
+ \specifypsfont{Helvetica-Bold}{}
+ \specifypsfont{Helvetica-BoldOblique}{}
+ \specifypsfont{Helvetica-Oblique}{}
+ \specifypsfont{Times-Roman}{}
+ \specifypsfont{Times-Bold}{}
+ \specifypsfont{Times-Italic}{}
+ \specifypsfont{Times-BoldItalic}{}
+ \specifypsfont{Symbol}{}
+ \specifypsfont{ZapfDingbats}{}
+\end{verbatim}
+When more than one action appears in the \meta{actions} argument,
+then it is usually the last that actually creates the font, whereas
+the others contain resources needed by the last.
+
+
+\begin{decl}
+ |\declarepsencoding|\marg{etx}\marg{postscript name}\marg{action}
+\end{decl}
+This command specifies how reencoding using a particular \etx file
+should be performed by the driver. The \meta{postscript name} is the
+\PS name of the encoding vector used, whereas the \meta{action} is the
+action (as above) that the driver needs to perform to make the
+encoding known to whatever it is that it is serving (often a \PS
+interpreter).
+
+Usually the right thing to do is to |\download| an \enc file, but
+there is also an action
+\begin{decl*}[v1.931]
+ |\encodingdownload|\marg{file}
+\end{decl*}
+which tries to express the fact that the \meta{file} contains an
+encoding vector. In the case of \dvips this is only necessary if
+(i)~the font is being subsetted and (ii)~the \meta{file} name is
+nonstandard (does not end with \enc).
+
+\begin{decl}[v1.931]
+ |\providepsencoding|\marg{etx}\marg{postscript name}\marg{action}
+\end{decl}
+This command is the same as |\declarepsencoding|, except that it
+doesn't do anything if an encoding has already been declared for this
+\meta{etx}. It is used for autogenerated encoding declarations, so
+that these will not override one issued by the user.
+
+
+
+\begin{decl}
+ |\storemapdata|\marg{\TeX\ font name}\marg{source}\marg{transforms}
+\end{decl}
+This records information about how the font named \meta{\TeX\ font
+name} was generated. Such commands are usually found in the file of
+recorded transforms. If a font is encountered for which no
+information has been stored, then the corresponding \mtx file will be
+sourced, looking for a |\storemapdata| command there.
+
+A \meta{source} is one of
+\begin{decl*}
+ |\fromafm|\marg{\afm name}\marg{PS name}\\
+ |\frompl|\marg{\pl name}\\
+ |\frommtx|\marg{\mtx name}\\
+ |\fromvpl|
+\end{decl*}
+Note that several of them have a different syntax and meaning than
+they do in fontmaking command files.
+
+A \meta{transform} is one of
+\begin{decl*}
+ |\reencodefont|\marg{etx}\\
+ |\reglyphfont|\\
+ |\transformfont|\marg{x-scale}\marg{slant-scale}
+\end{decl*}
+Note that all of these have a different meaning than they do in
+fontmaking command files.
+
+\begin{decl}
+ |\debugvalue|\arg{name}
+\end{decl}
+This adds a value to the list of those that are reported by the
+\texttt{debug} driver. Example:
+\begin{verbatim}
+ \debugvalue{PS_font_file}
+\end{verbatim}
+
+
+
+\subsection{Basic conversion commands}
+
+Some of the basic ``convert an $X$ file to a $Y$ file'' commands in
+\fontinst are not useful as part of a fontmaking run, and are
+available only in \texttt{finstmsc.sty} to conserve some memory.
+
+\begin{decl}
+ |\enctoetx|\marg{encfile}\marg{etxfile}
+\end{decl}
+This reads the file \meta{encfile}\texttt{.enc} which should be
+simple \PS code defining a \PS encoding vector and generates a
+corresponding rudimentary \fontinst encoding file
+\meta{etxfile}\texttt{.etx}. It's a basic ``import encoding to
+\fontinst'' command.
+
+\begin{decl}[v1.911]
+ |\etxtoenc|\marg{etxfiles}\marg{encfile}
+\end{decl}
+This does the opposite of |\enctoetx|; the information in the \etx
+files that is converted is the correspondence between slots and glyph
+names.
+\NEWfeature{v1.927}
+The \meta{etxfiles} argument is a comma-separated list of encoding
+files which are superimposed to generate the \PS encoding. The first
+|\setslot| for a particular slot is the one which decides which glyph
+will be placed there.
+
+\begin{decl}[v1.928]
+ |\etxtocmap|\marg{etxfile}\marg{cmapfile}
+\end{decl}
+This reads an \etx file and generates a corresponding ToUnicode CMap
+file; the information that is converted is the map from slot numbers
+to |\Unicode| code points.
+
+
+
+
+\section{General commands}
+
+
+
+This section describes commands and mechanisms that are the same in
+all file types. Commands that are particular for one type of file are
+described in subsequent sections.
+
+
+\subsection{Variables}
+\label{Ssec:Variables}
+
+Many (but not all) of the activities \fontinst perform can be
+understood as either ``setting variables'' or ``formatting and writing
+to file data stored in some variable''. The accessing of variables is
+an important aspect of how \fontinst works.
+
+Variables come in different types and variables of different types
+live in different namespaces; |\int{foo}|, |\str{foo}|, and
+|\dim{foo}| refer to three different variables which are all named
+|foo|. Variables are either set or not set. Unless the contrary is
+stated explicitly, each variable defaults to not being set. It is an
+error to access the value of a variable that has not been set.
+\Fontinst variable assignments are as a rule local, i.e., will be
+undone when the enclosing \TeX\ group is ended. Most command file
+commands that cause files to be read will begin a group before
+reading the file(s) and end the group at some point after having
+read them.
+
+Taking string variables as an example, there are three commands for
+changing a string variable:
+\begin{decl*}
+ |\setstr|\arg{name}\arg{string expression}\\
+ |\resetstr|\arg{name}\arg{string expression}\\
+ |\unsetstr|\arg{name}
+\end{decl*}
+The |\resetstr| command unconditionally sets the string variable
+\meta{name} to the full expansion of the \meta{string expression}.
+The |\unsetstr| command unconditionally renders the string variable
+\meta{name} unset. If the the string variable \meta{name} is
+currently unset then the |\setstr| command will set it to the full
+expansion of the \meta{string expression}, but if it already is set
+then |\setstr| does nothing.
+
+This pattern with three commands, one |\set|\dots\ which only sets
+unset variables, one |\reset|\dots\ which sets variables regardless of
+whether they have been set or not, and one |\unset|\dots\ which unsets
+variables is recurring in \fontinst. Variables are most commonly set
+using some |\set|\dots\ command; this has the effect that the first
+command to try to set a variable is the one which actually sets it.
+
+If |\set|\dots\ is the command for setting the value of a variable,
+the command for getting that value has the same name without the
+|set| part, e.g., |\setint|--|\int|, |\setglyph|--|\glyph|, etc.
+(Notable exceptions are |\setkern|, where the ``get'' command is
+called |\kerning|, and |\setcommand|, where no separate ``get''
+command is needed.) There
+are typically also conditionals for testing whether variables are
+set, and these take the form |\ifis|\dots\arg{name}|\then|.
+
+\medskip
+% The following commands for changing the value of a variable can be
+% used anywhere:
+
+\begin{decl}
+ |\setdim|\arg{dim}\arg{dimension}\\
+ |\setint|\arg{int}\arg{integer expression}\\
+ |\setstr|\arg{str}\arg{string expression}
+\end{decl}
+If the dimension variable \m{dim} is currently undefined, it is
+defined to be the current value of \m{dimension}.
+
+If the integer variable \m{int} is currently undefined, it is
+defined to be the current value of \m{integer expression}.
+
+If the string variable \m{str} is currently undefined, it is
+defined to be the current value of \m{string expression}.
+
+\begin{decl}
+ |\setcommand|\arg{command}\meta{parameter text}\arg{replacement text}
+\end{decl}
+If the command \m{command} is currently undefined, it is defined to
+grab parameters as specified by the \meta{parameter text} and then
+expand to the \m{replacement text}. This uses the same syntax for
+parameters as the \TeX\ \verb|\def| command.
+\begin{center}
+ \begin{tabular}{r l}
+ Number of parameters& \meta{parameter text}\\
+ 0& (empty)\\
+ 1& |#1|\\
+ 2& |#1#2|\\
+ 3& |#1#2#3|\\
+ \multicolumn{2}{c}{and so on.}
+ \end{tabular}
+\end{center}
+Some examples:
+\begin{verbatim}
+ \setcommand\lc#1#2{#2}
+ \setcommand\lc#1#2{#1small}
+\end{verbatim}
+With the first definition, |\lc{A}{a}| expands to |a|, but with the
+second it expands to |Asmall|.
+
+\begin{decl}
+ |\resetdim|\arg{dim}\arg{dimension}\\
+ |\resetint|\arg{int}\arg{integer expression}\\
+ |\resetstr|\arg{str}\arg{string expression}
+\end{decl}
+The dimension variable \m{dim} is defined to be the current value
+of \m{dimension}.
+
+The integer variable \m{int} is defined to be the current value of
+\m{integer expression}.
+
+The string variable \m{str} is defined to be the current value of
+the \m{string expression}. (|\resetstr| mostly boils down to a \TeX\
+|\edef| command.)
+
+\begin{decl}
+ |\resetcommand|\arg{command}\meta{parameter text}\arg{replacement text}
+\end{decl}
+The command \m{command} is defined to grab parameters as specified by
+the \meta{parameter text} and then expand to the \m{replacement text}.
+This is a synonym for the \TeX\ \verb|\def| command.
+
+\begin{decl}
+ |\unsetdim|\arg{dim}\\
+ |\unsetint|\arg{int}\\
+ |\unsetstr|\arg{str}\\
+ |\unsetcommand|\arg{command}
+\end{decl}
+Makes \m{dim}, \m{int}, \m{str}, or \m{command} an undefined
+dimension, integer, string or command.
+
+\begin{decl}[v1.900]
+ |\offcommand|\marg{command}\\
+ |\oncommand|\marg{command}
+\end{decl}
+|\offcommand| turns off a command, i.e., it redefines it to do
+nothing (while still taking the same number of arguments).
+|\oncommand| turns a command back on, i.e., it restores the
+definition the command had before a previous |\offcommand|. Using
+|\offcommand| on a command that is already off or |\oncommand| on a
+command that is not off has no effect.
+
+
+\subsection{Argument types and expansion}
+
+Most arguments of \fontinst commands belong to one of the following
+six categories:
+\begin{itemize}
+ \item integer expressions,
+ \item string expressions,
+ \item comma-separated lists of string expressions,
+ \item dimensions,
+ \item commands (i.e., a single \TeX\ control sequence), and
+ \item code (zero or more commands in sequence, each of which may
+ have arguments of its own).
+\end{itemize}
+Integer expressions are explained in Subsection~\ref{Sec:integer}
+below.
+
+The most common form of a string expression is simply a sequence of
+character tokens, but any balanced text which expands to such a
+sequence of tokens is legal. Several of the standard \etx files use
+macros in string expressions to make glyph names to some extent
+configurable. Besides such custom macros, the following \fontinst
+commands may be used to access variable values inside a string
+expression
+\begin{decl*}
+ |\strint|\arg{int}\\
+ |\str|\arg{str}\\
+ |\dim|\arg{dim}
+\end{decl*}
+Incidentally, these \m{int}, \m{str}, and \m{dim} are themselves
+string expressions (for the names of integer, string, and dimen
+respectively variables).
+
+Dimensions are simply \TeX\ \meta{dimen}s; their use is rather
+limited. \Fontinst does not provide for any sort of ``dimen
+expressions''. Most actual lengths are expressed as integer
+expressions, in AFM units ($1/1000$ of the font size).
+
+Common to integer expressions, string expressions, and
+dimensions is that these argument types get expanded during
+evaluation (in the case of string expressions, this expansion
+\emph{is} the evaluation), which means one can use macros in
+arguments of these types. Command arguments do not get
+expanded---they are mainly used with commands that modify the
+definitions of other commands.
+
+Comma-separated lists of string expressions are first split at commas
+(without prior expansion) and each element is then treated as a
+string expression (i.e., \emph{gets expanded}). (As remarked elsewhere,
+the \meta{metrics-list} argument of |\installfont| is not properly a
+comma-separated list of string expressions, even though it may look
+like one.)
+
+Code arguments are generally expanded, but one should not make any
+presumptions about \emph{when} this will happen, and similarly not
+assume that code placed in such an argument will only be executed
+once. It is typically safe to use a macro in a code argument if the
+definition of that macro stays the same throughout, but one should
+otherwise not use any other commands in code arguments than those
+explicitly documented as legal there.
+
+Finally, there are command arguments which do not fall into any of
+these categories. For these, one cannot give any rules: they
+might get expanded, but it could also happen that they won't.
+
+
+
+\subsection{Integer expressions}
+\label{Sec:integer}
+
+The \emph{integer expressions} provide a user-friendly syntax for
+\TeX\ arithmetic. They are used to manipulate any integers,
+including glyph dimensions (which are given in AFM units, that is
+1000 to the design size). \TeX\ \pl fonts have their dimensions
+converted to AFM units automatically.
+
+The \emph{integer expressions} are:
+
+\begin{decl}
+ \m{number}
+\end{decl}
+Returns the value of a \TeX\ \m{number} (as explained in
+\emph{The \TeX book}). Typical examples of this kind of integer
+expression are |0|, |1000|, |538|, |-20|, |"9C|, |'177|, etc.
+
+\begin{decl}
+ |\int|\arg{int}
+\end{decl}
+Returns the value of the integer variable \m{int}.
+
+\begin{decl}
+ |\width|\arg{glyph}\\
+ |\height|\arg{glyph}\\
+ |\depth|\arg{glyph}\\
+ |\italic|\arg{glyph}
+\end{decl}
+Returns the width, height, depth, or italic correction of the glyph
+variable \m{glyph}.
+
+\begin{decl}
+ |\kerning|\arg{left}\arg{right}
+\end{decl}
+Returns the kerning between the \m{left} and \m{right} glyphs. Unlike
+other types of variable accesses, where it is an error to access
+something that has not been explicitly set, this command returns |0|
+if no kern has been set between the two glyphs.
+
+\begin{decl}
+ |\neg|\arg{integer expression}\\
+ |\add|\arg{integer expression}\arg{integer expression}\\
+ |\sub|\arg{integer expression}\arg{integer expression}\\
+ |\max|\arg{integer expression}\arg{integer expression}\\
+ |\min|\arg{integer expression}\arg{integer expression}\\
+ |\mul|\arg{integer expression}\arg{integer expression}\\
+ |\div|\arg{integer expression}\arg{integer expression}\\
+ |\scale|\arg{integer expression}\arg{integer expression}\\
+ |\half|\arg{integer expression}\\
+ |\otherhalf|\arg{integer expression}
+\end{decl}
+These commands evaluate their argument(s) and perform some arithmetic
+operations on the result(s).
+
+|\neg| returns the negation of the \m{integer expression}.
+
+|\add| returns the sum of the two \m{integer expression}s.
+
+|\sub| returns the first \m{integer expression} minus the second.
+
+|\max| returns the maximum of the two \m{integer expression}s.
+
+|\min| returns the minimum of the two \m{integer expression}s.
+
+|\mul| returns the product of the two \m{integer expression}s.
+
+|\div| returns the first \m{integer expression} divided by the second.
+
+|\scale| returns the first \m{integer expression} times the second,
+divided by 1000. |\scale| does better rounding than the corresponding
+combination of |\mul| and |\div|.
+
+|\half| returns half the \m{integer expression}. It does better
+rounding than |\scale|\arg{integer expression}|{500}| or
+|\div|\arg{integer expression}|{2}|.
+
+|\otherhalf| returns the ``other half'' of the \m{integer
+expression}, i.e., the sum of |\half| something and |\otherhalf| the
+same thing is that thing back.
+
+
+\subsection{Conditionals and loops}
+
+\Fontinst has a rather extensive family of conditionals (|\if|s), and
+as of late also some convenient loop commands. The most common forms
+of a \fontinst conditional are
+\begin{decl*}
+ |\if|\dots \meta{argument(s)}|\then| \meta{then branch} |\Fi|\\
+ |\if|\dots \meta{argument(s)}|\then| \meta{then branch} |\Else|
+ \meta{else branch} |\Fi|
+\end{decl*}
+i.e., \fontinst uses Plain\TeX\ style conditionals (with else and fi
+control sequences) rather than \LaTeX\ style conditionals (with
+separate arguments for the two branches). Every |\if|\dots\ command
+can be thought of as testing some condition.
+If the condition is true then the \meta{then branch} will be executed,
+but not the \meta{else branch} (if there is one).
+If the condition is false then the \meta{then branch} will not be
+executed, but if there is an \meta{else branch} then that will be
+executed. Conditionals may be nested (i.e., occur in the then or else
+branch).
+
+\begin{hackernote}
+ The |\then| is not just syntactic sugar, but a functional part of
+ those conditionals which take arguments. Its purpose is to look
+ like an |\if| to \TeX\ when the conditional occurs in a skipped
+ branch of another conditional.
+\end{hackernote}
+
+The most common conditionals are those which test if a variable is set.
+\begin{decl*}
+ |\ifisint|\arg{int}|\then|\\
+ |\ifisdim|\arg{dim}|\then|\\
+ |\ifisstr|\arg{str}|\then|\\
+ |\ifiscommand|\arg{command}|\then|
+\end{decl*}
+These cause the following \meta{then branch} to be executed if the
+specified variable is set, and the \meta{else branch} to be executed
+if the variable is not set. The \meta{int}, \meta{dim}, and
+\meta{str} are string expressions for the names of an integer,
+dimension, and string respectively variable. The \meta{command} is
+the actual control sequence (command variable) that should be tested.
+
+\begin{decl}
+ |\ifisglyph|\arg{glyph}|\then|
+\end{decl}
+This similarly tests if a glyph (also a variable of a kind) is set in
+the current glyph base. The glyph name \meta{glyph} is a string
+expression.
+
+\begin{decl}[v1.917]
+ |\ifareglyphs|\marg{glyph list}|\then|
+\end{decl}
+This command tests whether all the glyphs in the \meta{glyph list}
+(a comma-separated list of string expressions) are set in the current
+glyph base. If one of the glyphs is not set then the condition is
+false.
+
+\begin{decl}[v1.900]
+ |\ifnumber|\marg{integer expression}\meta{rel}%
+ \marg{integer expression}|\then|
+\end{decl}
+The \meta{rel} is one of \texttt{<}, \texttt{=}, and \texttt{>}.
+This command evaluates the two \meta{integer expression}s and
+then tests whether the specified relation holds between their values.
+
+\begin{decl}[v1.900]
+ |\ifiskern|\marg{glyph1}\marg{glyph2}|\then|
+\end{decl}
+This tests whether a kern has been set with \meta{glyph1} on the left
+and \meta{glyph2} on the right (both arguments are string
+expressions). This is almost the negation of
+\begin{verbatim}
+ \ifnumber{\kerning{<glyph1>}{<glyph2>}}={0}\then
+\end{verbatim}
+but |\ifiskern| can distinguish the case that an zero kern has been
+set (true) from the case that no such kern has been set (false),
+which |\kerning| can not. It is however unlikely that this
+distinction would ever be of use in a practical situation.
+
+\begin{decl}[v1.924]
+ |\ifoption|\marg{string}|\then|
+\end{decl}
+Test whether \meta{string} (a string expression) is among the current
+list of options. This list is by default empty, elements are added
+using |option| modifiers (cf.~the description of |\installfont|), and
+the list is cleared for each new file for which one can specify
+options.
+
+\begin{decl}[v1.909]
+ |\Else|
+ |\Fi|
+\end{decl}
+For \fontinst, these two control sequences are precisely the same as
+the \TeX\ primitives |\else| and |\fi|, but things are a bit more
+complicated in \fontdoc. The mechanism in \fontdoc\ that allows it to
+present both branches of the conditional in the typeset output
+requires that |\Else| and |\Fi| generate typeset output. See also the
+|\showbranches| \fontdoc command.
+
+\begin{hackernote}
+ Before |\Else| and |\Fi| were introduced, the \TeX\ primitives
+ |\else| and |\fi| were used instead for \fontinst conditionals.
+ Back then, \fontdoc defined all conditionals to expand to |\iftrue|.
+
+ It used to be the case that all conditionals would be fully
+ expandable (which in particular would have made it possible to use
+ them in string expressions), but that is no longer the case.
+\end{hackernote}
+
+The \fontdoc formatter for visible branches treats an |\Else|
+immediately followed by an `if' as an `else if', i.e., it assumes the
+entire else branch consists of the conditional begun at that `if' and
+leaves out one level of indentation. When that is not the case, you
+will upon typesetting get a \LaTeX\ error about |\begin{IfBranchDummy}|
+and |\end{IfBranch}|. In that case you need to help the formatter by
+placing something between the |\Else| and the `if'; as it turns out
+leaving an empty line there is sufficient (although just a single
+newline is not).
+
+
+\begin{decl}[v1.901]
+ |\for|\parg{name}\marg{start}\marg{stop}\marg{step}
+ \meta{body} |\endfor|\parg{name}
+\end{decl}
+will cause the \meta{body} code to be repeated some number of times.
+How many depends on the values of \meta{start}, \meta{stop}, and
+\meta{step}, which are integer expressions.
+
+As a precaution, the \meta{body} is not allowed to contain any
+empty lines (|\par| tokens). If you want to have the visual
+separation (for sakes of legibility or otherwise), put a |%|
+somewhere on the line---that makes it nonempty.
+
+\meta{name} should consist of character tokens only. It is used as
+the name of an integer variable, which will serve as loop variable.
+This variable gets reset to the value of \meta{start} before the first
+repetition of \meta{body code}. After each repetition but the last,
+it is incremented by \meta{step}. \meta{body} gets repeated if
+the value of \meta{name} has not gotten past that of \meta{stop}. To
+get past means to be bigger if \meta{step} is positive and to be
+smaller if \meta{step} is negative. In the case that \meta{step} is
+zero, the entire construction above will be equivalent to
+\begin{quote}
+ |\resetint|\marg{name}\marg{start}\\
+ \meta{body}
+\end{quote}
+
+|\for| \textellipsis\ |\endfor| constructions can be nested.
+\meta{name} is used by |\for| to identify its matching |\endfor|, so
+they need to be identical in |\for| and |\endfor|. \textbf{Note} that
+the delimiters around the \meta{name} are parentheses, not braces.
+
+
+\begin{decl}[v1.901]
+ |\foreach|\parg{name}\marg{csep-list}
+ \meta{body} |\endfor|\parg{name}
+\end{decl}
+will cause the \meta{body} code to be repeated one time for each item
+in the \meta{csep-list}. \meta{csep-list} is a comma-separated list
+of string expressions.
+
+As a precaution, the \meta{body} is not allowed to contain any
+empty lines (|\par| tokens). If you want to have the visual
+separation (for sakes of legibility or otherwise), put a |%|
+somewhere on the line---that makes it nonempty.
+
+\meta{name} should consist of character tokens only. It is used as
+the name of a string variable, which will serve as loop variable.
+Before each repetition of the \meta{body code}, the loop variable will
+get reset to the next item in the \meta{csep-list}.
+
+|\foreach|\textellipsis\ |\endfor| constructions can be nested.
+\meta{name} is used by |\foreach| to identify its matching |\endfor|,
+so they need to be identical in |\foreach| and |\endfor|.
+\textbf{Note} that the delimiters around the \meta{name} are
+parentheses, not braces.
+
+
+
+\subsection{Other general commands}
+
+\begin{decl}
+ |\needsfontinstversion|\arg{version}
+\end{decl}
+This issues a warning if the current version of the \fontinst
+package is less than \m{version}.
+
+\begin{decl}[v1.914]
+ |\needsTeXextension|\marg{extension tests}\marg{who}
+\end{decl}
+The |\needsTeXextension| command issues a warning if \fontinst is not
+being run on one of the listed extensions of \TeX. This can be used to
+protect files that make use of features not present in base \TeX. As
+\meta{who} is preferably used the file name in which the command
+occurs; it should be the answer to ``who is issuing this warning?''
+
+An extension test is one of:
+\begin{decl*}
+ |\eTeX|\marg{version number}\\
+ |\pdfTeX|\marg{version number}\marg{revision}
+\end{decl*}
+Multiple tests in sequence are \textsc{or}'ed together. If you rather
+need to \textsc{and} them, then use separate |\needsTeXextension|
+commands.
+
+\begin{hackernote}
+ At present there is no test for Omega. This is really a shame,
+ because the extended character codes (outside the 0--255 range)
+ provided by Omega is the existing extension that would be most
+ useful for \fontinst, but Omega documentation does not give any
+ indication of how such a test should be implemented. Code
+ contributions are welcome.
+\end{hackernote}
+
+
+\begin{decl}[v1.915]
+ |\fontinstcc|\\
+ |\normalcc|
+\end{decl}
+|\fontinstcc| switches to the catcodes used in e.g.\@
+\texttt{fontinst.sty}: |_| and |@| are letters, space and newline are
+ignored, and |~| is a space. |\normalcc| switches back to normal
+catcodes.
+
+\begin{decl}[v1.900]
+ |\begincomment| \meta{text} |\endcomment|
+\end{decl}
+This hides the \meta{text} from \fontinst processing, but allows it
+to show up when the file is typeset with \fontdoc.
+
+\begin{decl}[v1.906]
+ |\fontinsterror|\marg{subsystem}\marg{error}\marg{help}\\
+ |\fontinstwarning|\marg{subsystem}\marg{warning}\\
+ |\fontinstwarningnoline|\marg{subsystem}\marg{warning}\\
+ |\fontinstinfo|\marg{subsystem}\marg{info}
+\end{decl}
+General commands to convey information to the user, based on \LaTeX's
+|\PackageError|, |\PackageWarning|, etc.
+
+\begin{decl}[v1.906]
+ |\messagebreak|
+\end{decl}
+Used to start a new line in an \meta{error}, \meta{help},
+\meta{warning}, or \meta{info} message.
+
+
+Finally, there are two Plain\TeX\ commands which should be mentioned:
+\begin{decl*}
+ |\input| \meta{file name}\\
+ |\bye|
+\end{decl*}
+|\input| followed by a \meta{file name} (\emph{without} braces around)
+is the recommended way of inputting a \fontinst command file, or the
+\fontinst package itself (\texttt{fontinst.sty},
+\texttt{finstmsc.sty}, etc.). This is the only way to make things work
+regardless of whether the underlying format is \LaTeX, Plain\TeX, or
+even a raw Ini\TeX.
+
+|\bye| is the command to use to terminate a \fontinst command file.
+
+
+
+
+
+\section{Encoding files}
+
+An \emph{encoding file} (or \texttt{.etx} file) is a \TeX\ document
+with the structure:
+\begin{quote}
+ |\relax|\\
+ \meta{ignored material}\\
+ |\encoding|\\
+ \meta{encoding commands}\\
+ |\endencoding|\\
+ \meta{ignored material}
+\end{quote}
+This describes the encoding of a font, using the \m{encoding commands}.
+
+Since the encoding file ignores any material between \verb|\relax| and
+\verb|\encoding|, an \emph{encoding file} can also be a \LaTeX\
+document. The structure is then
+\begin{quote}
+ |\relax|\\
+ |\documentclass{article} %| Or some other class\\
+ |\usepackage{fontdoc}|\\
+ \meta{\LaTeX\ preamble}\\
+ |\begin{document}|\\
+ \meta{\LaTeX\ text}\\
+ |\encoding|\\
+ \m{encoding commands}\\
+ |\endencoding|\\
+ \meta{\LaTeX\ text}\\
+ |\end{document}|
+\end{quote}
+
+
+See also the descriptions in \emph{Writing ETX format font encoding
+specifications} (\texttt{encspecs.tex}).
+
+
+\subsection{Encoding commands}
+
+The \m{encoding commands} are:
+
+\begin{decl}
+ |\nextslot|\arg{integer expression}
+\end{decl}
+Sets the number of the next slot. If there is no \verb|\nextslot|
+command, the number is the successor of the previous slot. Immediately
+after |\encoding|, the next slot number is $0$.
+
+\begin{decl}[v1.8]
+ |\skipslots|\arg{integer expressions}
+\end{decl}
+Advances the number of the next slot.
+
+\begin{decl}
+ |\setslot|\arg{glyph} \m{slot commands} |\endsetslot|
+\end{decl}
+Assigns \m{glyph} to the current slot. The \m{slot commands} can be
+used to specify additional behaviour for the slot, and typically also
+contains comments about the glyph.
+
+\begin{decl}[v1.9]
+ |\setleftboundary|\marg{glyph} \m{slot commands}
+ |\endsetleftboundary|
+\end{decl}
+Makes the beginning of a word (left boundary) behave like the right
+side of \m{glyph} with respect to kerning. |\ligature| commands in
+the \meta{slot commands} create beginning of word ligatures.
+
+\begin{decl}[v1.9]
+ |\setrightboundary|\marg{glyph}
+\end{decl}
+Makes the end of a word (right boundary) behave like the left
+side of \m{glyph} with respect to kerning and ligatures. The current
+slot position is left empty.
+
+\begin{decl}
+ |\inputetx|\arg{file}
+\end{decl}
+Inputs the \m{encoding commands} of \m{file}\texttt{.etx}.
+
+\begin{decl}[v1.917]
+ |\setfontdimen|\marg{fontdimen no.}\marg{integer variable}
+\end{decl}
+Sets up a correspondence between a font dimension and an integer
+variable. When generating a font, the font dimension value is taken
+from the integer variable. When converting a font from \pl or \vpl
+format, the fontdimen value will be recorded as a |\setint| command
+for the variable.
+
+\begin{decl}[v1.924]
+ |\ifdirect|
+\end{decl}
+Encoding files set up a correspondence between slot numbers and glyph
+names, which can be used in two different ways. In the \emph{direct}
+mode, encoding files map slot numbers to glyph names. In the
+\emph{inverse} mode, glyph names are mapped to slot numbers. The
+inverse mapping can in general be one-to-many, and when precisely one
+target slot is needed \fontinst chooses that arbitrarily. The |\ifdirect|
+conditional can be used to disambiguate the inverse mapping, by
+conditionalising all undesired |\setslot|s on that the file is being
+interpreted in the direct mode. For example:
+\begin{verbatim}
+ \ifdirect
+ \setslot{hyphen}
+ \comment{Soft hyphen slot}
+ \endsetslot
+ \Else
+ \skipslots{1}
+ \Fi
+\end{verbatim}
+
+Currently the only case in which encoding files are being read in
+the inverse mode is when reencoding fonts.
+
+\begin{decl}[v1.8]
+ |\setslotcomment|\marg{text}\\
+ |\resetslotcomment|\marg{text}\\
+ |\unsetslotcomment|
+\end{decl}
+These commands can be used to specify an automatic |\comment| text
+for all slots. They are ignored by \fontinst, but interpreted by
+\fontdoc.
+
+\begin{decl}[v1.8]
+ |\useexamplefont|\marg{font}
+\end{decl}
+This command is ignored by \fontinst. In \fontdoc it sets the font
+that is used by the |\slotexample| command. The \meta{font} argument
+has the same syntax for a font as the \TeX\ primitive |\font|.
+
+
+
+
+\subsection{Slot commands}
+
+The \m{slot commands} are:
+
+\begin{decl}
+ |\comment|\arg{text}
+\end{decl}
+A comment, which is ignored by \fontinst, but typeset as a separate
+paragraph by \fontdoc.
+
+\begin{decl}[v1.917]
+ |\label|\arg{text}
+\end{decl}
+A reference label (like in \LaTeX), which records the slot number and
+glyph name. Ignored by \fontinst.
+
+\begin{decl}
+ |\ligature|\arg{ligtype}\arg{glyph1}\arg{glyph2}
+\end{decl}
+|\ligature| declares a ligature of type \m{ligtype}, which will take
+effect if the current glyph is immediately followed by \meta{glyph1}
+when \TeX\ is constructing a list of horizontal material. This
+ligature will then replace the two glyphs by the third glyph
+\meta{glyph2}. For example:
+\begin{verbatim}
+ \setslot{ff}
+ \comment{The `ff' ligature.}
+ \ligature{LIG}{i}{ffi}
+ \ligature{LIG}{l}{ffl}
+ \endsetslot
+\end{verbatim}
+declares one ligature \(\texttt{ff}*\texttt{i} \longrightarrow
+\texttt{ffi}\) and one ligature \(\texttt{ff}*\texttt{l}
+\longrightarrow \texttt{ffl}\).
+
+The eight \m{ligtype}s are the names of the underlying \pl
+properties, i.e.,:
+\begin{quote}
+ \texttt{LIG}\hfil
+ \texttt{/LIG}\hfil
+ \texttt{/LIG>}\hfil
+ \texttt{LIG/}\hfil
+ \texttt{LIG/>}\hfil
+ \texttt{/LIG/}\hfil
+ \texttt{/LIG/>}\hfil
+ \texttt{/LIG/>>}
+\end{quote}
+The basic \texttt{LIG} may be immediately preceded or followed by a
+slash, and then immediately followed by \texttt{>} characters not
+exceeding the number of slashes. The slashes specify retention of the
+left or right original glyph; the \texttt{>} signs specify passing
+over that many glyphs of the result without further ligature or kern
+processing.
+
+\begin{decl}[v1.918]
+ |\Ligature|\arg{ligtype}\arg{glyph}\arg{glyph}\\
+ |\oddligature|\marg{note}\arg{ligtype}\arg{glyph}\arg{glyph}
+\end{decl}
+The |\Ligature| command is by default a synonym of |\ligature| (but
+\fontdoc may typeset them differently). The |\oddligature| command is
+by default ignored by \fontinst. See \setfilename{encspecs.tex} for
+an explanation of the semantic differences.
+
+\begin{decl}
+ |\makerightboundary|\arg{glyph}
+\end{decl}
+This makes the current slot the end of word (right boundary) marker
+with respect to ligatures and kerning, i.e., \TeX\ will kern and
+ligature as if there was an invisible occurrence of this character
+after the last character of every word. All kerns and ligatures with
+\meta{glyph} as the right part will apply for this slot.
+
+It is preferable to use |\setrightboundary| to control end of word
+behaviour if you have an empty slot to spare.
+
+\begin{decl}
+ |\Unicode|\marg{code point}\marg{name}\\
+ |\charseq|\marg{\cs{Unicode} commands}
+\end{decl}
+These commands declare a Unicode character or character sequence as
+possible interpretations of what is in this slot. They are ignored
+when making fonts, but \fontdoc give them a prominent role in
+encoding specifications and to |\etxtocmap| they are the primary
+properties of the slot.
+
+\begin{decl}[Obsolete?!]
+ |\usedas|\arg{type}\arg{control sequence}
+\end{decl}
+This command declares a \TeX\ control sequence for this slot, with
+the \emph{type} taken from:
+\begin{verbatim}
+ char accent mathord
+ mathbin mathrel mathopen
+ mathclose mathpunct mathvariable
+ mathaccent mathdelim
+\end{verbatim}
+There is currently no code in \fontinst which makes any use of this
+command. It might in principle be possible to autogenerate \LaTeX\
+output encoding definition (\meta{enc}\texttt{enc.def}) files and
+math symbol declarations from this information.
+
+\begin{decl}
+ |\nextlarger|\arg{glyph}
+\end{decl}
+Math font property: makes \meta{glyph} the \textsc{nextlarger} entry
+of the current slot.
+
+\begin{decl}
+ |\varchar|
+ \m{varchar commands}
+ |\endvarchar|
+\end{decl}
+Math font property: sets the \textsc{varchar} entry for the current
+slot, using the \m{varchar commands}. The possible \m{varchar
+commands} are:
+\begin{decl*}
+ |\vartop|\arg{glyph}\\
+ |\varmid|\arg{glyph}\\
+ |\varbot|\arg{glyph}\\
+ |\varrep|\arg{glyph}
+\end{decl*}
+Sets the top, middle, bottom, or repeated \m{glyph} of the
+\textsc{varchar}.
+
+
+\subsection{Other}
+
+\begin{decl}[v1.9]
+ |\ifisinslot|\marg{glyph}\marg{slot}|\then|
+\end{decl}
+During \vpl\slash\pl generation, this conditional tests whether glyph
+\meta{glyph} (a string expression) is put in the slot \meta{slot} (an
+integer expression). Since encoding files are normally read several
+times in that context, the exact behaviour of this command is a bit
+uncertain. It was intended to support collecting additional
+information about the fonts being generated, but at the time of
+writing this is probably only of academic interest.
+
+
+\begin{decl}[v1.931]
+ |\declarepsencoding|\marg{etx-name}\marg{PS-encoding-name}%
+ \marg{action}
+\end{decl}
+This command is placed in \etx files generated by |\enctoetx|, and has
+the same syntax as in a mapmaking command file (see
+Subsection~\ref{Ssec:MapConfig}). It records information about the
+source encoding file to assist the map file writer, but is mostly
+ignored by main \fontinst.
+
+
+
+
+\section{Metric files}
+\label{Sec:Metric}
+
+
+A \emph{metric file} (or \mtx file) is a \TeX\ document with the
+structure:
+\begin{quote}
+ |\relax|\\
+ \emph{ignored material}\\
+ |\metrics|\\
+ \m{metric commands}\\
+ |\endmetrics|\\
+ \emph{ignored material}
+\end{quote}
+This describes the glyphs in a font, using the \m{metric commands}.
+Like encoding files, metric files can simultaneously be \LaTeX\
+documents.
+
+Metric files are usually either \emph{hand-crafted} or
+\emph{transformable}. The transformable metric files typically encode
+the metrics of one particular font and are automatically generated.
+Hand-crafted metric files (such as \setfilename{latin.mtx}) typically
+do not contain much explicit metric data, instead the code there makes
+use of metrics previously specified by other files to construct new
+glyphs or adjust metrics to meet special conditions. Whereas
+transformable metric files tend to be mere lists of metric data, the
+hand-crafted metric files are more like programs.
+
+
+\subsection{Metric commands}
+
+The \m{metric commands} are as follows. All glyph name arguments are
+string expressions.
+
+\begin{decl}
+ |\setglyph|\arg{name} \m{glyph commands} |\endsetglyph|
+\end{decl}
+If the glyph called \m{name} is undefined, it is built using the
+\m{glyph commands}, for example:
+\begin{verbatim}
+ \setglyph{IJ}
+ \glyph{I}{1000}
+ \glyph{J}{1000}
+ \endsetglyph
+
+ \setglyph{Asmall}
+ \glyph{A}{850}
+ \endsetglyph
+\end{verbatim}
+The \meta{glyph commands} are not executed if the glyph has already
+been set.
+
+\begin{decl}
+ |\resetglyph|\arg{name}
+ \m{glyph commands}
+ |\endresetglyph|
+\end{decl}
+This builds a glyph using the \m{glyph commands}, and defines
+(at~|\endresetglyph|) \meta{name} to be that glyph, regardless of
+whether that glyph was already defined.
+
+\begin{decl}
+ |\unsetglyph|\arg{name}
+\end{decl}
+Makes the glyph called \m{name} undefined.
+
+\begin{decl}
+ |\setrawglyph|\arg{name}\arg{font}\arg{dimen}\arg{slot}\\
+ \hspace*{1.5em}\arg{width}\arg{height}\arg{depth}\arg{italic
+ correction}\\
+ |\setscaledrawglyph|%
+ \arg{name}\arg{font}\arg{dimen}\arg{scale}\arg{slot}\\
+ \hspace*{1.5em}\arg{width}\arg{height}\arg{depth}\arg{italic
+ correction}
+\end{decl}
+These commands will usually be
+generated automatically from an \afm or \pl file.
+If the glyph \meta{name} is undefined, then this sets it to be that
+which is found in slot \meta{slot} of font \meta{font}. The
+\meta{width}, \meta{height}, \meta{depth}, and \meta{italic} are
+saved away as the width, height, depth and italic correction
+respectively of the glyph.
+
+The \meta{scale} is a scaling factor which has been applied to the
+font to give it the specified metrics.
+If the integer variable \texttt{rawscale} is set, another scaling by
+that amount will be applied to the glyph (this is how the |scaled|
+keyword in |\installfont| metrics-lists take effect).
+
+The \meta{dimen} is the nominal \emph{design size} of the \meta{font},
+usually |10pt|; this information isn't really needed for anything, but
+the \vf format requires it to be specified and match what is in
+\meta{font}\setfilename{.tfm}, so a \dvi driver is allowed to error
+out on us if we don't get this value right.
+
+
+\begin{decl}
+ |\setnotglyph|\arg{name}\arg{font}\arg{dimen}\arg{slot}\\
+ \hspace*{1.5em}\arg{width}\arg{height}\arg{depth}\arg{italic
+ correction}\\
+ |\setscalednotglyph|%
+ \arg{name}\arg{font}\arg{dimen}\arg{scale}\arg{slot}\\
+ \hspace*{1.5em}\arg{width}\arg{height}\arg{depth}\arg{italic
+ correction}
+\end{decl}
+These set a glyph called \m{name}\texttt{-not} (if that wasn't set
+already) to have the specified width, height, depth, and italic
+correction but be invisible in print.
+
+Such commands are usually generated automatically from an \afm file,
+when a glyph is present in the \m{font} but is not in the default
+encoding. They take the same arguments as |\setrawglyph| and
+|\setscaledrawglyph| respectively (although the \meta{slot} will
+normally be |-1|), because
+reencoding a font can turn |\setrawglyph| commands into
+|\setnotglyph| commands and vice versa.
+
+
+\begin{decl}
+ |\inputmtx|\arg{file}
+\end{decl}
+Inputs the \m{metric commands} of \m{file}\texttt{.mtx}.
+
+\begin{decl}[v1.9]
+ |\usemtxpackage|\marg{package~list}\\
+ |\ProvidesMtxPackage|\marg{package~name}
+\end{decl}
+|\usemtxpackage| behaves like |\inputmtx|, but it will only input a
+file if no |\ProvidesMtxPackage| for that file has been issued. By
+putting a |\ProvidesMtxPackage| in an \mtx file one can |use| it in
+several places without having to worry about it being sourced more
+than once.
+
+\begin{hackernote}
+ |\ProvidesMtxPackage| declarations make local assignments, so the
+ package is forgotten when the current group ends. In particular, the
+ settings made with |\ProvidesMtxPackage| are forgotten when the
+ current glyph base is flushed.
+\end{hackernote}
+
+
+
+\subsection{Glyph commands}
+
+The \m{glyph commands} add material to the glyph currently being
+constructed in a |\setglyph| \dots\ |\endsetglyph| or
+|\resetglyph| \dots\ |\endresetglyph|. They are:
+
+\begin{decl}
+ |\glyph|\arg{glyph}\arg{integer expression}
+\end{decl}
+Sets the named glyph \m{glyph} at the given scale, with 1000 as the
+natural size. This:
+\begin{itemize}
+ \item
+ Advances the current glyph width.
+ \item
+ Sets the current glyph height to be at least the height of the
+ named glyph, adjusted for the current vertical offset.
+ \item
+ Sets the current glyph depth to be at least the depth of the
+ named glyph, adjusted for the current vertical offset.
+ \item
+ Sets the current glyph italic correction to be the same as the
+ set glyph.
+\end{itemize}
+The named glyph must have already been defined, otherwise an error
+will occur. For example:
+\begin{verbatim}
+ \setglyph{fi}
+ \glyph{f}{1000}
+ \glyph{i}{1000}
+ \endsetglyph
+\end{verbatim}
+
+\begin{decl}
+ |\glyphrule|\arg{integer expression}\arg{integer expression}
+\end{decl}
+Sets a rule of the given width and height, for example:
+\begin{verbatim}
+ \setglyph{underline}
+ \glyphrule{333}{40}
+ \endsetglyph
+\end{verbatim}
+
+\begin{decl}
+ |\glyphspecial|\arg{string expression}
+\end{decl}
+Sets a driver-dependent \verb|\special|, for example:
+\begin{verbatim}
+ \setglyph{crest}
+ \glyphspecial{Filename: crest.eps}
+ \endsetglyph
+\end{verbatim}
+
+\begin{decl}
+ |\glyphwarning|\arg{string expression}
+\end{decl}
+Sets a warning \verb|\special|, and produces a warning message each
+time the glyph is used, for example:
+\begin{verbatim}
+ \setglyph{missingglyph}
+ \glyphrule{500}{500}
+ \glyphwarning{Missing glyph `missingglyph'}
+ \endsetglyph
+\end{verbatim}
+
+\begin{decl}
+ |\movert|\arg{integer expression}
+\end{decl}
+Moves right by the given amount, and advances the current glyph width,
+for example:
+\begin{verbatim}
+ \setglyph{Asmall}
+ \movert{50}
+ \glyph{A}{700}
+ \movert{50}
+ \endsetglyph
+\end{verbatim}
+
+\begin{decl}
+ |\moveup|\arg{integer expression}
+\end{decl}
+Moves up by the given amount, and advances the current vertical
+offset. Each glyph should always end at vertical offset zero, for
+example:
+\begin{verbatim}
+ \setglyph{onehalf}
+ \moveup{500}
+ \glyph{one}{700}
+ \moveup{-500}
+ \glyph{slash}{1000}
+ \moveup{-200}
+ \glyph{two}{700}
+ \moveup{200}
+ \endsetglyph
+\end{verbatim}
+
+\begin{decl}
+ |\push| \m{glyph commands} |\pop|
+\end{decl}
+Performs the \m{glyph commands}, but at the |\pop| the current
+position and glyph width are restored to what they were at the |\push|,
+for example:
+\begin{verbatim}
+ \setglyph{aacute}
+ \push
+ \movert{\half{\sub{\width{a}}{\width{acute}}}}
+ \glyph{acute}{1000}
+ \pop
+ \glyph{a}{1000}
+ \endsetglyph
+\end{verbatim}
+
+\begin{decl}
+ |\glyphpcc|\arg{glyph}\arg{integer expression}\arg{integer expression}
+\end{decl}
+This is generated from \texttt{PCC} instructions in an \afm file, and
+is syntactic sugar for:
+\begin{quote}
+ \small
+ |\push|\\
+ |\movert|\arg{first integer expression}\\
+ |\moveup|\arg{second integer expression}\\
+ |\glyph|\arg{glyph}|{1000}|\\
+ |\pop|
+\end{quote}
+
+\begin{decl}
+ |\resetwidth|\arg{integer expression}\\
+ |\resetheight|\arg{integer expression}\\
+ |\resetdepth|\arg{integer expression}\\
+ |\resetitalic|\arg{integer expression}
+\end{decl}
+Sets the width, height, depth, or italic correction of the current
+glyph.
+
+\begin{decl}
+ |\samesize|\arg{glyph}
+\end{decl}
+Sets the dimensions of the current glyph to be the same as \m{glyph}.
+
+\bigskip
+
+Inside a |\setglyph| definition of \m{glyph}, you can use expressions
+such as |\width|\arg{glyph} to refer to the glyph defined so far.
+For example, a display summation sign can be defined to be a text
+summation $\sum$ scaled 120\% with 0.5\,pt extra height and depth
+using:
+\begin{verbatim}
+ \setglyph{summationdisplay}
+ \glyph{summationtext}{1200}
+ \resetheight{\add{\height{summationdisplay}}{50}}
+ \resetdepth{\add{\depth{summationdisplay}}{50}}
+ \endsetglyph
+\end{verbatim}
+Within a |\resetglyph|, these expressions will refer to the previous
+definition of the glyph. For example, you can add sidebearings to the
+letter `A' with:
+\begin{verbatim}
+ \resetglyph{A}
+ \movert{25}
+ \glyph{A}{1000}
+ \movert{25}
+ \endresetglyph
+\end{verbatim}
+
+
+\subsection{Kerning commands}
+
+The kerning commands may be used anywhere in a metrics file.
+
+\begin{decl}
+ |\setkern|\arg{glyph}\arg{glyph}\arg{integer expression}
+\end{decl}
+This sets a kern between the two glyphs, scaled by the current
+value of \texttt{rawscale}, unless such a kern already has been set.
+
+\begin{decl}[v1.9]
+ |\resetkern|\arg{glyph}\arg{glyph}\arg{integer expression}
+\end{decl}
+|\resetkern| unconditionally sets a kern between the two glyphs,
+scaled by the current value of \texttt{rawscale}.
+
+\begin{decl}
+ |\setleftkerning|\arg{glyph}\arg{glyph}\arg{integer expression}\\
+ |\setrightkerning|\arg{glyph}\arg{glyph}\arg{integer expression}
+\end{decl}
+Sets the amount by which the first glyph should mimic how the second
+glyph kerns on the left or right, for example:
+\begin{verbatim}
+ \setleftkerning{Asmall}{A}{850}
+ \setrightkerning{Asmall}{A}{850}
+ \setleftkerning{IJ}{I}{1000}
+ \setrightkerning{IJ}{J}{1000}
+\end{verbatim}
+The commands work by copying kerning pairs containing the first glyph.
+As the names indicates, these commands do not override kerning pairs
+previously set.
+
+\begin{decl}[v1.8]
+ |\setleftrightkerning|\arg{glyph}\arg{glyph}\arg{integer expression}
+\end{decl}
+Sets the amount by which the first glyph should mimic how the second
+glyph kerns on both sides, for example:
+\begin{verbatim}
+ \setleftrightkerning{Asmall}{A}{850}
+\end{verbatim}
+This command is equivalent to doing first a |\setleftkerning| and
+then a |\setrightkerning|.
+
+\begin{decl}[v1.906]
+ |\noleftkerning|\arg{glyph}\\
+ |\norightkerning|\arg{glyph}\\
+ |\noleftrightkerning|\arg{glyph}
+\end{decl}
+Removes all kerning on the specified side(s) of the \meta{glyph}.
+
+\begin{decl}[v1.9]
+ |\unsetkerns|\marg{left~glyph~list}\marg{right~glyph~list}
+\end{decl}
+Removes all kerns with one glyph in the \meta{left glyph list} on the
+left and one glyph in the \meta{right glyph list} on the right.
+
+
+
+\subsection{Other}
+
+\begin{decl}[v1.915]
+ |\aliased|\marg{font's name}\marg{alias name}
+\end{decl}
+This command, which syntactically counts as a \meta{string
+expression}, is meant to be used in glyph name arguments of commands
+one may find in metric files. It was added to support combining
+mapfile entry generation with a custom form of reglyphing that has
+been developed for the \texttt{T2} bundle (Cyrillic font support).
+This does however not necessarily mean that the \texttt{T2} bundle
+has been updated to take advantage of this feature.
+
+The basic problem is that cyrillic fonts display a much greater
+variation in how the glyphs are named than latin fonts do.%
+\footnote{The Adobe guidelines have not been as prevailing here as
+in the latin range, but this isn't entirely surprising when they
+give opaque suggestions such as using the name \texttt{afii10018}
+for \texttt{U+0411} (\textsc{cyrillic capital letter be}). The
+suggestion made some sense though; AFII (Association for Font
+Information Interchange) maintained a glyph registry.}
+This complicates writing files similar to \setfilename{latin.mtx}, so
+the author of the \texttt{T2} bundle took the route to regularize the
+glyph names at the \afm to \mtx conversion step. Since \TeX\ does not
+know anything about glyph names, this makes no difference for the
+virtual fonts that are built.
+The glyph names do however make a difference for base fonts that are
+reencoded, since \PS encoding vectors list explicit glyph names that
+have to be the same as in the font. \Fontinst's choice of encoding
+vector for a mapfile entry is based on which \etx file was used in the
+reencoding, and hence the glyph names used when reencoding must match
+those actually used in the font, or problems will follow.
+
+The |\aliased| command can be used to preserve the information
+necessary for such reencodings. If a glyph name is specified as for
+example
+\begin{verbatim}
+ \aliased{afii10018}{CYRB}
+\end{verbatim}
+then \fontinst will behave as if the glyph name is \texttt{CYRB}
+(i.e., the \meta{alias name}) for all purposes \emph{except}
+reencoding, where instead \fontinst behaves as if the glyph name is
+the \meta{font's name} \texttt{afii10018}. This makes it possible to
+use \etx files when reencoding which can be correctly translated to
+the right encoding vectors.
+
+
+\begin{decl}[v1.931]
+ |\providepsencoding|\marg{etx}\marg{postscript name}\marg{action}
+\end{decl}
+If this command occurs in an \mtx file then it was placed there by a
+|\declare|\-|ps|\-|encoding| in an \etx file that was used to
+reencode this \mtx. It is meant for consumption by the mapfile writer,
+and is ignored by main \fontinst.
+
+
+
+\section{\textsf{fontdoc} commands}
+
+The following commands are defined by \fontdoc but are unknown to
+\fontinst.
+
+
+\subsection{Comment commands}
+
+\begin{decl}
+ |\plaindiv|\\
+ |\plainint|\\
+ |\plainmax|\\
+ |\plainmin|\\
+ |\plainneg|
+\end{decl}
+These are the \LaTeX\ definitions of |\div|, |\int|, |\max|, |\min|,
+and |\neg| respectively. They are provided under these names because
+\fontinst uses the normal names for integer expression constructions.
+
+\begin{decl}[v1.8]
+ |\slotexample|
+\end{decl}
+This typesets the character in the current slot from the example font
+(cf.~|\use|\-|example|\-|font|).
+
+\begin{decl}[v1.916]
+ |\macroparameter|\marg{digit}
+\end{decl}
+This can be used in integer and string expressions. It typesets as
+\textit{\#n}, where `\textit{n}' is the \meta{digit}.
+
+\begin{decl}[v1.918]
+ |\textunicode|\marg{code point}\marg{name}
+\end{decl}
+This generates a reference to a particular Unicode character, for use
+within a |\comment| or similar.
+
+
+\subsection{Style control commands}
+
+\begin{decl}[v1.909]
+ |\showbranches|
+\end{decl}
+The is the main switch that turns on displaying both branches of
+\fontinst conditionals. If you use this command in an encoding or
+metrics file, you \textbf{must} use |\Else| and |\Fi| to delimit the
+conditionals in that file. If you do not use this command in an
+encoding or metrics file, then the conditionals will not generate any
+typeset material and neither will their \meta{else branch}es.
+
+
+
+
+\section{\fontinst variables}
+\label{Sec:Variables}
+
+The following is a list of the \fontinst variables that are
+accessible for the user through the |\set|\textellipsis,
+|\reset|\textellipsis, |\unset|\textellipsis, etc.\ commands. You may
+of course set or use other variables in the \mtx and \etx files you
+write yourself, as does for example the standard \mtx file
+\texttt{latin.mtx}, but all variables that \fontinst commands
+implicitly use or set are listed below.
+
+% \begin{list}{}{%
+% \setlength\labelwidth{0pt}%
+% \setlength\itemindent{-\leftmargin}%
+% \setlength\parsep{0pt}
+% \def\makelabel#1{\hspace\labelsep \normalfont\ttfamily #1}%
+% }
+\begin{itemize}
+ \item[acccapheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The height of accented full capitals.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[address] (string)
+ \begin{smalldes}
+ \item[Description] Snailmail address put in \BibTeX-style file
+ header of automatically generated \enc files. No
+ \texttt{address} field is written unless the \texttt{address}
+ string is set. Quotes are not automatically inserted around
+ the \texttt{address} string.
+ \item[Set by] \etx files.
+ \item[Used by] The \etx-to-\enc converter.
+ \end{smalldes}
+ \item[afm-name] (string)
+ \begin{smalldes}
+ \item[Description] Name of source font. Internal variable.
+ \item[Set by] |\from|\dots\ commands.
+ \item[Used by] The |\transform|\-|font|, |\install|\-|font|,
+ |\install|\-|raw|\-|font|, and |\reglyph|\-|font| commands.
+ \end{smalldes}
+ \item[ascender] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The ascender height of the font.
+ \item[Set by] \mtx files. The \afm-to-\mtx converter usually writes
+ |\setint| commands for this integer.
+ \item[Used by] Some \mtx and \etx files.
+ \end{smalldes}
+ \item[author] (string)
+ \begin{smalldes}
+ \item[Description] Author name(s) put in \BibTeX-style file
+ header of automatically generated \enc files. See the macro
+ |\ref_to_sourcefile| for more details.
+ \item[Set by] \etx files.
+ \item[Used by] The \etx-to-\enc converter. When not set, the
+ value \texttt{"See file }\meta{etx name}\texttt{"} is used
+ instead.
+ \end{smalldes}
+ \item[\cs{autoinstallfamily}] (command)
+ \begin{smalldes}
+ \item[Description] Command called by the font installation
+ commands, as
+ \begin{quote}
+ |\autoinstallfamily|\marg{encoding}\marg{family}
+ \end{quote}
+ when they are asked to install a font with a combination of
+ \meta{encoding} and \meta{family} that has not been seen
+ before (there was no explicit |\installfamily|).
+ \item[Set by] Explicit commands. Defaults to calling
+ |\installfamily|.
+ \item[Used by] Font installation commands.
+ \end{smalldes}
+ \item[axisheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{22}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[baselineskip] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The font designer's recommendation for natural length of the
+ \TeX\ parameter |\baselineskip|.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[bigopspacing1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{9}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[bigopspacing2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{10}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[bigopspacing3] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{11}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[bigopspacing4] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{12}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[bigopspacing5] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{13}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[capheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The height of the font's full capitals.
+ \item[Set by] \mtx files. The \afm-to-\mtx converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some \mtx and \etx files.
+ \end{smalldes}
+ \item[cmapname] (string)
+ \begin{smalldes}
+ \item[Description] The name given to the CMap generated from
+ an \etx file.
+ \item[Set by] \etx files.
+ \item[Used by] The \etx-to-CMap converter. When not set, the
+ value |fontinst-|\nolinebreak[1]\meta{cmap file name} is
+ used instead.
+ \end{smalldes}
+ \item[codingscheme] (string)
+ \begin{smalldes}
+ \item[Description] The codingscheme name.
+ \item[Set by] \etx files.
+ \item[Used by] The \cvpl writer. When not set, the
+ value \texttt{UNKNOWN} is used instead.
+ \end{smalldes}
+ \item[defaultrulethickness] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{8}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[delim1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{20}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[delim2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{21}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[denom1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{11}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[denom2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{12}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[descender] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The depth of lower case letters with descenders.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[descender\_neg] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The vertical position of the descender line
+ of the font, i.e., the negative of the font's descender depth.
+ \item[Set by] \mtx files. The \afm-to-\mtx converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some \mtx and \etx files.
+ \end{smalldes}
+ \item[designsize] (dimension)
+ \begin{smalldes}
+ \item[Description] The design size of the font.
+ \item[Set by] \mtx files. The \cvpl-to-\mtx converter usually writes
+ |\setdim| commands for this variable.
+ \item[Used by] The \cvpl writer. The design size defaults to
+ $10\,\mathrm{pt}$ if this variable is not set.
+ \item[Note] The value of this variable has no effect on how
+ the font is declared to \LaTeX.
+ \end{smalldes}
+ \item[designunits] (dimension denoting a real number)
+ \begin{smalldes}
+ \item[Description] The design size of a font expressed in the
+ design unit used in a \cvpl file.
+ \item[Set by] \mtx files. The \cvpl-to-\mtx converter usually writes
+ |\setdim| commands for this variable.
+ \item[Used by] Nothing. If this variable is set, but to any
+ value other than $1\,\mathrm{pt}$, then some metrics are most
+ likely wrong.
+ \end{smalldes}
+ \item[digitwidth] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The median width of the digits in the font.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[email] (string)
+ \begin{smalldes}
+ \item[Description] Email address put in \BibTeX-style file
+ header of automatically generated \enc files. See the macro
+ |\ref_to_sourcefile| for more details.
+ \item[Set by] \etx files.
+ \item[Used by] The \etx-to-\enc converter. When not set, the
+ value \texttt{"See file }\meta{etx name}\texttt{"} is used
+ instead.
+ \end{smalldes}
+ \item[encodingname] (string)
+ \begin{smalldes}
+ \item[Description] The name by which the encoding in question is
+ made known to a Postscript interpreter.
+ \item[Set by] \etx files.
+ \item[Used by] The \etx-to-\enc converter. When not set, the
+ value |fontinst-|\nolinebreak[1]|autoenc-|\nolinebreak[1]%
+ \meta{etx name} is used instead.
+ \end{smalldes}
+ \item[etx-name] (string)
+ \begin{smalldes}
+ \item[Description] Name of \etx file. Internal variable in
+ |\transform|\-|font|.
+ \item[Set by] The |\reencodefont| command.
+ \item[Used by] The |\mtxtomtx| command.
+ \end{smalldes}
+ \item[extraspace] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The natural width of extra interword glue at the end of a
+ sentence.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[fontdimen($n$)] (integer)
+ \begin{smalldes}
+ \item[Description] Family of semi-internal variables that store
+ the values to use for font dimension $n$. It is preferred
+ that the newer |\set|\-|font|\-|dimen| interface is used for
+ setting these values.
+ \item[Set by] \etx files.
+ \item[Used by] The \cvpl writer.
+ \end{smalldes}
+ \item[\cs{iftokeep}] (macro)
+ \begin{smalldes}
+ \item[Description] |\iftokeep|\,\#1\,|\then|, where \#1 will
+ be a \meta{number}, behaves like a switch and decides whether
+ a glyph is kept or not while reglyphing.
+ \item[Set by] Explicit commands. Defaults to
+ $$
+ \mbox{\cs{iftokeep}\,\#1\,\cs{then}} \mapsto
+ \mbox{\cs{ifnum}\,\texttt{-1<}\#1}
+ $$
+ \item[Used by] The |\reglyphfont| command.
+ \end{smalldes}
+ \item[interword] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The natural width of interword glue (spaces).
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[italicslant] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] The italic slant of a font.
+ \item[Set by] \mtx files generated from \afm or \cvpl files. \mtx
+ files generated by |\transformfont|. Locally in the \afm-to-\mtx
+ converter for possible use in |\uprightitalcorr| or
+ |\slanteditalcorr|.
+ \item[Used by] \mtx files (\texttt{latin.mtx} and the like). \etx
+ files (for determining \texttt{fontdimen(1)}).
+ \end{smalldes}
+ \item[killweight] (integer)
+ \begin{smalldes}
+ \item[Description] Weight for glyphs that are killed.
+ \item[Set by] Explicit commands. Defaults to $-10$ if not set.
+ \item[Used by] The |\kill|\-|glyph| command; indirectly
+ the |\reglyphfont| command.
+ \end{smalldes}
+ \item[letterspacing] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Extra width added to all glyphs of a font.
+ \item[Set by] \mtx (preferred) or \etx files.
+ \item[Used by] The \cvpl writer. Defaults to $0$ if not set.
+ \end{smalldes}
+ \item[maxdepth] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The maximal depth over all slots in the font.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[maxdepth\_neg] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The negative of the maximal depth of a glyph in
+ the font.
+ \item[Set by] \mtx files. The \afm-to-\mtx converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[maxheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The maximal height of a glyph in the font.
+ \item[Set by] \mtx files. The \afm-to-\mtx converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[minimumkern] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Kerns whose size in absolute value is less
+ than or equal to this variable are ignored.
+ \item[Set by] Command files or \mtx files.
+ \item[Used by] The \afm-to-\mtx converter and the \cvpl file
+ generator. When not set, the value $0$ is used instead.
+ \end{smalldes}
+ \item[monowidth] (flag integer)
+ \begin{smalldes}
+ \item[Description] Set if this font is monowidth, unset otherwise.
+ \item[Set by] \mtx files. The \afm-to-\mtx converter writes a
+ |\setint| command for this variable if the \afm specifies
+ \texttt{IsFixedPitch true}.
+ \item[Used by] Some \mtx files (\texttt{latin.mtx} and the like),
+ \etx files.
+ \end{smalldes}
+ \item[num1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{8}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[num2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{9}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[num3] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{10}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[quad] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The quad width of the font, normally approximately equal to
+ the font size and\slash or the width of an `M'.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \item[Note]
+ It is the quad width in the symbol math font (family~|2|)
+ that \TeX\ uses as reference when translating |mu|s to
+ ordinary lengths. Hence that quad can be considered a math
+ font designer's scaling factor for |mu|.
+ \end{smalldes}
+ \item[PSfontsuffix] (string)
+ \begin{smalldes}
+ \item[Description] Suffix added to font names to form name of
+ file to download to include font.
+ \item[Set by] Explicit commands in mapmaking command
+ files. Defaults to `\texttt{.pfa}'.
+ \item[Used by] The map file fragments writer.
+ \end{smalldes}
+ \item[rawscale] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] Scaling factor applied to raw glyphs.
+ \item[Set by] The |\installfont| command (\texttt{scaled}
+ clauses in argument \#2). Unset for metric files listed
+ without a \texttt{scaled} clause.
+ \item[Used by] The |\set|\-|raw|\-|glyph|,
+ |\set|\-|not|\-|glyph|, |\set|\-|scaled|\-|raw|\-|glyph|,
+ |\set|\-|scaled|\-|not|\-|glyph|, |\set|\-|kern|, and
+ |\reset|\-|kern| commands.
+ \end{smalldes}
+ \item[renameweight] (integer)
+ \begin{smalldes}
+ \item[Description] Weight for glyphs that are renamed.
+ \item[Set by] Explicit commands. Defaults to $1$ if not set.
+ \item[Used by] The |\rename|\-|glyph| command; indirectly
+ the |\reglyphfont| command.
+ \end{smalldes}
+ \item[requireglyphs] (flag integer)
+ \begin{smalldes}
+ \item[Description] Set if warnings are to be generated for
+ glyphs listed in \etx files but not present in the glyph
+ base.
+ \item[Set by] Explicit commands. By default not set.
+ \item[Used by] The \cvpl file generator.
+ \end{smalldes}
+ \item[rightboundary] (string)
+ \begin{smalldes}
+ \item[Description] The name of a glyph with the property that
+ kerns on the left may be intended as right word boundary kerns.
+ \item[Set by] \mtx files. The \cvpl-to-\mtx converter can write
+ |\setstr| commands for this variable.
+ \item[Used by] Some \mtx files.
+ \end{smalldes}
+ \item[shrinkword] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The (finite) shrink component of interword glue.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[slant-scale] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] Factor to slant by.
+ Internal variable in |\transform|\-|font|.
+ \item[Set by] The |\slant|\-|font|, |\xscale|\-|font|, and
+ |\scale|\-|font| commands.
+ \item[Used by] The |\mtxtomtx| command.
+ \end{smalldes}
+ \item[\cs{SlantAmount}] (macro expanding to an integer expression)
+ \begin{smalldes}
+ \item[Description] Slant factor used for faking oblique shape.
+ \item[Set by] Explicit commands. Defaults to \texttt{167}.
+ \item[Used by] The |\latinfamily| command.
+ \end{smalldes}
+ \item[\cs{slanteditalcorr}]
+ (macro expanding to an integer expression)
+ \begin{smalldes}
+ \item[Description] The integer expression used to calculate a
+ guess for the italic correction of glyphs in a font with
+ positive slant. It has the syntax
+ \begin{quote}
+ \cs{slanteditalcorr}\marg{width}\marg{left}\marg{right}%
+ \marg{bottom}\marg{top}
+ \end{quote}
+ where \meta{width} is the glyph's advance width, and the
+ remaining arguments are coordinates of sides of the glyph's
+ bounding box. The \texttt{italicslant} integer provides the
+ italic slant of the font.
+ \item[Set by] Explicit commands in \textsf{fontinst} command
+ files. Defaults to
+ $$
+ \max\{0, \mathit{right}-\mathit{width}\}.
+ $$
+ \item[Used by] The \afm-to-\mtx converter.
+ \end{smalldes}
+ \item[stretchword] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The (finite) stretch component of interword glue.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[sub1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{16}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[sub2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{17}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[subdrop] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{19}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[sup1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{13}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[sup2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{14}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[sup3] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{15}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[supdrop] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{18}$.
+ \item[Set by] \mtx files.
+ \item[Used by] Some \etx and \mtx files.
+ \end{smalldes}
+ \item[TFMfileprefix] (string)
+ \begin{smalldes}
+ \item[Description] Prefix (typically a path) added to names of
+ TFM files.
+ \item[Set by] Explicit commands in mapmaking command
+ files. By default not set, which is equivalent to being empty.
+ \item[Used by] The \texttt{pltotf} ``map file fragments writer''.
+ \end{smalldes}
+ \item[underlinethickness] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The recommended thickness of an underlining
+ rule.
+ \item[Set by] \mtx files. The \afm-to-\mtx converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some \mtx files (\texttt{latin.mtx} and the like).
+ \end{smalldes}
+ \item[\cs{uprightitalcorr}]
+ (macro expanding to an integer expression)
+ \begin{smalldes}
+ \item[Description] The integer expression used to calculate a
+ guess for the italic correction of glyphs in a font with
+ non-positive slant. It has the syntax
+ \begin{quote}
+ \cs{uprightitalcorr}\marg{width}\marg{left}\marg{right}%
+ \marg{bottom}\marg{top}
+ \end{quote}
+ where \meta{width} is the glyph's advance width, and the
+ remaining arguments are coordinates of sides of the glyph's
+ bounding box. The \texttt{italicslant} integer provides the
+ italic slant of the font.
+ \item[Set by] Explicit commands in \textsf{fontinst} command
+ files. Defaults to $0$.
+ \item[Used by] The \afm-to-\mtx converter.
+ \end{smalldes}
+ \item[version] (string)
+ \begin{smalldes}
+ \item[Description] Version number put in \BibTeX-style file
+ header of automatically generated \enc files. See the macro
+ |\ref_to_sourcefile| for more details.
+ \item[Set by] \etx files.
+ \item[Used by] The \etx-to-\enc converter. When not set, the
+ value \texttt{"See file }\meta{etx name}\texttt{"} is used
+ instead.
+ \end{smalldes}
+ \item[verticalstem] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The dominant width of vertical stems
+ (usually the width of stems of lower case letters).
+ \item[Set by] \mtx files. The \afm-to-\mtx converter writes
+ |\setint| commands for this variable if the \afm file specifies
+ \texttt{StdVW}.
+ \item[Used by] Currently nothing.
+ \end{smalldes}
+ \item[\texttt{warningspecials}] (switch)
+ \begin{smalldes}
+ \item[Description] Controls whether |\glyphwarning| commands
+ will generate \vpl \texttt{SPECIAL}s. Defaults to `true'.
+ \item[Set by] Explicit commands (|\warningspecialstrue| and
+ |\warningspecialsfalse|).
+ \item[Used by] The \cvpl file generator.
+ \end{smalldes}
+ \item[x-scale] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] Horizontal scaling factor.
+ Internal variable in |\transform|\-|font|.
+ \item[Set by] The |\xscale|\-|font| and |\scale|\-|font| commands.
+ \item[Used by] The |\mtxtomtx| command.
+ \end{smalldes}
+ \item[xheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The x-height of the font.
+ \item[Set by] \mtx files. The \afm-to-\mtx and \cvpl-to-\mtx
+ converters usually write |\setint| commands for this variable.
+ \item[Used by] \mtx files, and \etx files (for determining
+ \texttt{fontdimen(5)}).
+ \end{smalldes}
+ \item[y-scale] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] Vertical scaling factor.
+ Internal variable in |\transform|\-|font|.
+ \item[Set by] The |\yscale|\-|font| and |\scale|\-|font| commands.
+ \item[Used by] The |\mtxtomtx| command.
+ \end{smalldes}
+ \item[\meta{\rmfamily glyph}-spacing] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Glyph-specific override for
+ \texttt{letterspacing}; extra width added to the glyph
+ \meta{glyph} as part of the process of writing a \vpl
+ file.
+ \item[Set by] \etx or \mtx files.
+ \item[Used by] The \cvpl writer. Defaults to $0$ if not set.
+ \end{smalldes}
+\end{itemize}
+% \end{list}
+Besides these, the |\latinfamily| command provides a whole range of
+helper macros (|\latin_weights|, |\latin_widths|, |\latin_shapes|,
+etc.) that are often used somewhat like variables. That subject
+does however deserve to be treated separately.
+
+
+
+\section{Customisation}
+
+The \fontinst package reads a file \texttt{fontinst.rc} if it
+exists. This can contain your own customisations. The catcodes that
+are in force when this file is read are the same as those selected by
+|\fontinstcc|.
+
+Similarly \texttt{finstmsc.sty} reads \texttt{finstmsc.rc} and the
+\fontdoc package reads \texttt{fontdoc.cfg}.
+
+You can create a \texttt{fontinst} format by running ini\TeX{} on
+\texttt{fontinst.sty} then saying \verb|\dump|.
+
+
+\section{Notes on features new with v\,1.9}
+
+The following notes are copied from \texttt{fisource.tex}; they were
+written to explain new \fontinst features to old \fontinst users.
+
+
+\subsection{Metric packages}
+
+\Fontinst has traditionally come with a collection of \mtx
+files that complement the \mtx files generated from base font metrics,
+in that they build glyphs that may be missing from the base fonts or
+in some other way needs to be improved. The most well-known of these
+is the \texttt{latin.mtx} file; other examples include
+\texttt{textcomp.mtx}, \texttt{mathit.mtx}, and \texttt{latinsc.mtx}.
+A problem with these is however that they cannot produce optimal
+results for all fonts simply because there are irregular differences
+in how fonts are set up by the foundries. Most glyphs come out all right,
+but there are usually a few for which the parameters used are more or
+less wrong. Therefore most high quality font installations are made
+with modified versions of these files, where the parameters have been
+tuned to the specific font design.
+
+Modifying in particular \texttt{latin.mtx} is however not an entirely
+easy task, because this is a rather large file (with plenty of
+archaic pieces of code in curious places). Doing it once is no big
+problem, but if one has to do it several times (maybe because some
+errors are discovered in the original \texttt{latin.mtx}) then it is
+probably no fun anymore. Furthermore, if one has two or three
+modified copies of this file because one has made high quality
+installations of that many different fonts then even a trivial bugfix
+might start to feel like entirely too much work.
+
+If one has to make modifications then it is usually easier to deal
+with several small files (many of which can be used unchanged) than
+one big file. Thus it would be better if these big files were split up
+into several smaller ones.
+The main problem with splitting up something like \texttt{latin.mtx}
+is that there are some commands which are defined at the top and
+which are then used in almost all sections of the file. One must make
+certain that these commands are always loaded, which makes the metric
+files somewhat harder to use (especially if the one who tries to use
+them is not the one who wrote them).
+
+One strategy is to include all definitions needed for a metric file in
+it. This has the slight disadvantage that the commands will have to be
+defined several times. What is worse however, is that the command
+definitions will appear in several files, so if one finds a bug in one
+of them, one cannot simply correct this bug in one place. As the number
+of files can soon become quite large, correcting such bugs can become
+a boring procedure indeed.
+
+Another strategy is to put all the command definitions in one file
+and then explicitly include it in the \meta{file-list} argument of
+|\installfont|. This eliminates the repeated bug fixing problem, but
+requires the user to do something that the computer can actually do
+just as well.
+
+A third strategy is to put the command definitions in one or several
+files and then in each metric file the user explicitly mentions load
+the command definitions needed for that particular file. Metric
+packages uses an improved version of this strategy, since they also
+make it possible for \fontinst to remember which packages (i.e., sets
+of command definitions) that have already been loaded, so that they
+are not unnecessarily loaded again. The \texttt{newlatin.mtx} file is
+an alternative to \texttt{latin.mtx} that implements this strategy.
+Most of the actual code is located in the following metric packages:
+\begin{center}
+\begin{tabular}{l p{0.7\linewidth}}
+ \texttt{ltcmds.mtx}& Defines some common commands used by the other
+ files.\\
+ \texttt{llbuild.mtx}& Builds the latin lower case alphabet
+ (unaccented letters are `unfakable', the rest are constructed if
+ not present in the base fonts).\\
+ \texttt{lubuild.mtx}& Builds the latin upper case alphabet.\\
+ \texttt{lsbuild.mtx}& Builds accented letters in the latin
+ smallcaps alphabet, but only if there are unaccented letters to
+ build them from in the base fonts.\\
+ \texttt{lsfake.mtx}& Fakes a latin smallcaps alphabet by shrinking
+ the upper case alphabet, but only if the glyph had not already
+ been manufactured.\\
+ \texttt{lsmisc.mtx}& Make some miscellaneous smallcaps glyphs
+ (mostly ``smallcaps f-ligatures'').\\
+ \texttt{ltpunct.mtx}& Makes digits, punctuation marks, and other
+ symbols (mostly by marking as ``unfakable'').
+\end{tabular}
+\end{center}
+\noindent All of these are easy to use as components of equivalents
+of a modified \texttt{latin.mtx} files, and all dependencies of one
+package upon another are handled via explicit |\usemtxpackage|
+commands.
+
+% For information on the syntax etcetera of commands related to metric
+% packages, see Section~\ref{Sec:Metric files}.
+
+
+\subsection{Word boundary ligatures and kerns}
+
+One of the new features added in \TeX~3 was that of ligatures and
+kerns with word boundaries. \Fontinst has had an interface
+for making such ligatures and kerns, but it has been completely
+redesigned in v\,1.9 and the old interface (setting the integer
+|boundarychar|) is no longer recognized by \fontinst. Files
+which use the old interface can still be processed with
+\texttt{cfntinst.sty}, though.
+
+Before considering the new commands, it is suitable to make a
+distinction between proper glyphs and pseudoglyphs. A proper glyph has
+been set using one of the commands |\setrawglyph|, |\setglyph|, and
+|\resetglyph|. A pseudoglyph is any name used in the context of a
+glyph name which does not denote a proper glyph. If a pseudoglyph
+|g-not| was set using the |\setnotglyph| command, then
+|\ifisglyph{g-not}\then| will evaluate to true, but something can be
+a pseudoglyph even if an |\ifisglyph| test evaluates to false. The
+interesting point about pseudoglyphs when considering word boundaries
+however, is that a pseudoglyph can have ligatures and kerns.
+
+Kerns and ligatures at the left word boundary (beginning of word) are
+specified using the commands |\setleftboundary| and
+|\endsetleftboundary|, which are syntactically identical to
+|\setslot| and |\endsetslot| respectively. One important difference is
+however that the argument to |\setslot| must be a proper glyph, while
+the argument to |\setleftboundary| may be any glyph, hence any
+pseudoglyph will do just fine.
+
+|\ligature| commands between |\setleftboundary| and
+|\endsetleftboundary| will generate beginning of word ligatures. Kerns
+on the right of the glyph specified in |\setleftboundary| will become
+beginning of word kerns.
+
+Kerns and ligatures at the right word boundary (end of word) are
+trickier, due to the asymmetrical nature of the ligkern table in a \pl
+file. What a font can do is to specify that the right word boundary,
+for purposes of kerning and ligatures, should be interpreted as
+character $n$. By including a kern or ligature with character $n$ on
+the right, that kern or ligature will be used at the end of a word,
+but it will also be used each time the next character is character
+$n$. Because of this, one usually wants the slot $n$, which the right
+word boundary is interpreted as being, to be empty whenever the
+encoding allows this.
+
+The command
+\begin{quote}
+ |\setrightboundary|\marg{glyph}
+\end{quote}
+will mark the current slot as used to denote the right word boundary,
+and leave the slot empty, increasing the current slot number by one
+just like a |\setslot| \textellipsis\ |\endsetslot| block does. Kerns on
+the left of \meta{glyph} will be end of word kerns and |\ligature|
+commands with \meta{glyph} as the second argument will be for the end
+of a word.
+
+The command
+\begin{quote}
+ |\makerightboundary|\marg{glyph}
+\end{quote}
+is similar to |\setrightboundary|, but it is a slot command which may
+only be used between a |\setslot| and the matching |\endsetslot|. Like
+|\setrightboundary|, it marks the current slot as used to denote the
+right word boundary, but the glyph specified in the enclosing |\setslot|
+will be written to that slot. Ligatures for the glyph specified by the
+|\setslot| and ligatures for the glyph specified by the
+|\makerightboundary| will both be for this single slot. Kerns on the
+right of the |\setslot| glyph and the |\makerightboundary| glyph will
+similarly both be for this single slot. The idea is that the |\setslot|
+glyph should be used when making a kern or ligature for that glyph,
+while the |\makerightboundary| glyph should be used when making a kern
+or ligature for the end of a word. \Fontinst will warn you if
+these two uses of the slot directly contradict each other.
+
+
+\subsection{Changing the names of glyphs}
+\label{Ssec:Des:Reglyph}
+
+Sometimes, primarily when making a virtual font from more than one raw
+font and two of the raw fonts contain different glyphs with the same
+name, it becomes necessary to change the names of some glyphs to make
+some sense out of it. The main source of this kind of trouble is the
+``caps and small caps'' (SC) and ``oldstyle figures'' (OsF) fonts
+within many commercial font families. The typical problem is that what
+is typographically different glyphs---such as the lowercase `a'
+(\texttt{a}, for \fontinst) and the smallcaps `\textsc{a}'
+(\texttt{Asmall}, for \fontinst)---are given the same name by
+the foundry.
+
+One way to get round this is to say for example
+\begin{quote}
+ |\setglyph{Asmall} \glyph{a}{1000} \endsetglyph|\\
+ |\setleftrightkerning{Asmall}{a}{1000}|\\
+ |\unsetglyph{a}|\\
+ |\noleftrightkerning{a}|
+\end{quote}
+and continuing like that for all the duplicate glyph names. This is
+however a rather prolix method and if the number of glyphs is large
+then it is usually simpler to use the |\reglyphfont| command.
+
+To reglyph one or several fonts, one writes
+\begin{quote}
+ |\reglyphfonts|\\
+ \vadjust{}\quad \meta{reglyphing commands}\\
+ |\endreglyphfonts|
+\end{quote}
+There are two types of reglyphing commands: the |\reglyphfont|
+command, and the commands that modify what |\reglyphfont| will do to
+the fonts it operates on. The syntax of |\reglyphfont| is
+\begin{quote}
+ |\reglyphfont|\marg{destination font}\marg{source font}
+\end{quote}
+The \meta{source font} font here is the name (suffix not included, of
+course) of the font metric file one wants to change the glyph names in.
+This font metric file can be in any of the formats \mtx, \pl, \afm, and
+\vpl, and it will be converted to \mtx format if it isn't already in
+that format (this happens just as for files listed in the second
+argument of |\installfont|). \meta{destination font} (which must be
+different from \meta{source font}) will be taken as the name for a
+new \texttt{.mtx} file that will be generated. The destination font
+can differ from the source font only in two ways: the names of some
+glyphs in the source font might be changed, and some of the commands
+from the source font might not have been copied to the destination
+font. To what extent the fonts are different is determined by what
+modifying commands have been executed; when no modifying commands
+have been executed, the source and destination font are equal.
+
+The modifying reglyphing commands are
+\begin{quote}
+ |\renameglyph|\marg{to}\marg{from}\\
+ |\renameglyphweighted|\marg{to}\marg{from}\marg{weight}\\
+ |\killglyph|\marg{glyph}\\
+ |\killglyphweighted|\marg{glyph}\marg{weight}\\
+ |\offmtxcommand|\marg{command}\\
+ |\onmtxcommand|\marg{command}
+\end{quote}
+|\renameglyph| simply declares that occurrences of the glyph name
+\meta{from} should be replaced by the glyph name \meta{to}. To each
+glyph name is also assigned a \emph{weight}, which is used by a
+mechanism which conditions copying of commands from the source font to
+the destination font by the set of glyphs that command mentions. The
+details of this mechanism are however somewhat tricky, so those
+interested in the full generality should read the comments in the
+source of \fontinst. Here it needs only be noted that if one applies
+|\killglyph| to a glyph name, then (under most circumstances) commands
+that refer to that glyph name will not be copied to the destination
+font.
+
+|\offmtxcommand| and |\onmtxcommand| also control whether commands are
+copied to the destination font, but they look at the actual command
+rather than the glyphs it refers to. For example, after the command
+\begin{quote}
+ |\offmtxcommand{\setkern}|
+\end{quote}
+no |\setkern| commands will be copied. By using |\offmtxcommand|, it
+is possible to achieve effects similar to those of the files
+\texttt{kernoff.mtx} and \texttt{glyphoff.mtx}---the difference is
+that with |\offmtxcommand|, it happens at an earlier stage of the font
+generation. As expected, |\onmtxcommand| undoes the effect of
+|\offmtxcommand|.
+
+A special rule pertains to the |\set|\-|raw|\-|glyph|,
+|\set|\-|not|\-|glyph|, |\set|\-|scaled|\-|raw|\-|glyph|, and
+|\set|\-|scaled|\-|not|\-|glyph| commands, since |\transformfont|
+doesn't care what something was in the source font when it generates
+the transformed font. To turn these commands off while reglyphing,
+you use |\offmtx|\-|command| on |\set|\-|scaled|\-|raw|\-|glyph|.
+
+The effects of modifying reglyphing commands are delimited by
+|\reglyphfonts| and |\endreglyphfonts|, which starts and ends a group
+respectively.
+
+As we expect the most common reglyphing operation will be to go from SC
+glyph names to expert glyph names, there is a file \texttt{csc2x.tex}
+in the \fontinst distribution which contains the modifying
+reglyphing commands needed for setting up that conversion. Thus you
+can write for example
+\begin{quote}
+ |\reglyphfonts|\\
+ | \input csc2x|\\
+ | \reglyphfont{padrcx8r}{padrc8r}|\\
+ | \reglyphfont{padscx8r}{padsc8r}|\\
+ |\endreglyphfonts|
+\end{quote}
+to alter the glyph names in the SC fonts in the Adobe Garamond
+(\texttt{pad}) family.
+Note that the names of the destination fonts here really are rather
+arbitrary, since they will only exist as \texttt{.mtx} files, and
+thus only need to work within your local file system. In particular,
+all the |\setrawglyph| commands in the destination font files still
+refer to the source font, so it is that font which the drivers need
+to know about.
+
+
+\subsection{Making map file fragments}
+\label{Ssec:MapFragments}
+
+A \emph{map file fragment} is the lines\footnote{Not in general an
+entire map file, hence the word \emph{fragment}.} of a map file that
+the corresponding driver would need for handling some set of fonts.
+When told to, \fontinst can (in a fairly automatic way) create
+the map file fragment which is needed for the set of raw fonts
+\fontinst has (i) installed directly (using |\installrawfont|)
+or (ii) used as a base font for some installed virtual font (generated
+by |\installfont|). \Fontinst does not support the map file
+syntaxes of every existing driver, but the system is designed to be
+extendable and contributions that extend its capabilities are welcome.
+Nor can \fontinst examine your \TeX\ system and
+determine every piece of information needed to make the correct map
+file fragments, but you can tell it roughly how your installation
+looks, it can make guesses which work most of the time, and you can
+specify most things explicitly if the guesses turn out to be wrong.
+Should the available options for configuring the process turn out to
+be inadequate for your needs, then please write to the
+\fontinst mailing list about this---there is probably a way
+to improve the system so that your needs can be met.
+
+Now what does one have to do to use this map file fragment writer,
+then? First you need to tell \fontinst to record the
+information the map file fragment writer needs. You do this by giving
+the command
+\begin{quote}
+ |\recordtransforms{whatever.tex}|
+\end{quote}
+at the beginning of the run. Here \texttt{whatever.tex} is the name of
+a file that will be created, so you can use some other name if you
+like. After that you do all the calls to |\transform|\-|font|,
+|\install|\-|font|, |\install|\-|raw|\-|font|, |\latin|\-|family|,
+etc.\ you need to make the fonts you want. When you're done, you give
+the command
+\begin{quote}
+ |\endrecordtransforms|
+\end{quote}
+and end the run (say |\bye|). The file \texttt{whatever.tex} will now
+contain the information about which fonts were used and what needs to
+be done with them.
+
+The second step is to actually run the map file fragment writer.
+Observe that it is located in the file \texttt{finstmsc.sty}, not
+\texttt{fontinst.sty}! The commands you need to give it can be so few
+that you can type them in at \TeX's \texttt{*} prompt, but if you are
+writing a command file then it should typically have the following
+structure (comments not necessary, of course):
+\begin{center}
+ \begin{tabular}{ll}
+ |\input finstmsc.sty|& |%| Input command definitions\\
+ \meta{general settings} & |%| See below\\
+ |\adddriver|\marg{driver name}\marg{output file}&
+ |%| Open output file\\
+ |\input whatever.tex|& |%| Writes to output file(s)\\
+ |\donedrivers|& |%| Close output file(s), tidy up\\
+ |\bye|& |%| Quit
+ \end{tabular}
+\end{center}
+The |\adddriver| command gives the order ``write map file entries for
+the \meta{driver name} \dvi driver to the file \meta{output file}.'' The
+plan is that it should be possible to use the name of just about any
+major driver (\texttt{dvips}, \texttt{xdvi},\footnote{Or
+does that use the same map file as \texttt{dvips}? I heard somewhere
+that it did. /LH} \texttt{pdftex},\footnote{pdf\TeX\ can read
+the map files generated for \texttt{dvips}, but a separate driver is
+desirable because the formats are not completely identical.}
+\texttt{OzTeX}, etc.) here and get suitable map file entries for that
+driver as output, but for the moment only the \texttt{dvips} and
+\texttt{dvipdfm}\footnote{Whose support I made very much to illustrate
+that you \emph{don't} have to be a big and ancient driver like
+\texttt{dvips} to have supporting code put into \fontinst.
+(The fact that I just happened to have printed out the documentation and
+that is was easy to read also helped, of course.) Note, however, that
+there won't be any support for a driver unless someone sits down and
+writes the code for it! Don't assume I will. /LH} drivers are supported.
+
+You may also use \texttt{debug} or \texttt{pltotf} for \meta{driver name}.
+The \texttt{debug} ``\dvi driver'' file simply contains all the available
+information about each font (hence it should come handy for debugging
+code writing entries for real drivers) in a format that should be easy
+to interpret for a human. It could be the right choice if you're going
+to write the map file manually, as the combined effects of several
+font transformations are not always easy to compute manually. The
+file generated for the \texttt{pltotf} ``driver'' is actually a shell
+script consisting of a sequence of \pltotf commands. These commands
+perform the \pl to \tfm conversion for precisely those fonts that are
+actually needed (\fontinst usually generates \pl files also for a
+number of fonts at intermediate stages of transformation, and many of
+these need not be converted to \tfm files). The \texttt{TFMfileprefix}
+string can be used to add a directory path to the \tfm file names,
+perhaps saving the step of moving them to their proper location later.
+
+The file \texttt{whatever.tex} in the above example contains the
+commands (|\make|\-|map|\-|entry| commands) that actually cause entries
+to be written to the output file. It also contains a number of
+|\store|\-|map|\-|data| commands---these describe how some given font
+was made. If some metric file you have used contains
+|\set|\-|raw|\-|glyph| commands that were not automatically generated
+by \fontinst, then there might not be a |\store|\-|map|\-|data| for
+the font they refer to in \texttt{whatever.tex}, so you will have to
+include such a command yourself somewhere. This can for example be done
+in the \meta{general settings} part of the above example file.
+
+Another class of things that will typically appear in the
+\meta{general settings} part above is commands that will inform the
+routines actually writing output about your \TeX\ system, about the set
+of fonts you are using on this run, or about something else that might
+be useful. Some such commands are of a general nature and affect what
+assumptions \fontinst will make in certain conditions when no
+specific information is available. For the moment there commands are:
+\begin{description}
+ \item[\cs{AssumeMetafont}] Assume all fonts with \pl metrics are
+ bitmaps generated by Metafont, and therefore make no entries for
+ them.
+ \item[\cs{AssumeAMSBSYY}] Assume all fonts with \pl metrics have their
+ \TeX\ names in all upper case as postscript names---just like the
+ Computer Modern fonts in the AMS\slash Blue~Sky\slash Y\&Y
+ distribution.
+ \item[\cs{AssumeBaKoMa}] Assume all fonts with \pl metrics have their
+ \TeX\ names in all lower case as postscript names---just like the
+ Computer Modern fonts in the BaKoMa distribution.
+\end{description}
+Otherwise the default action of the routine for finding out the
+postscript name of a font simply is to observe that it hasn't got a clue
+about what the right value is when the metrics were taken from a \pl
+file, and therefore it writes `\texttt{??????}' for the postscript name.
+\begin{description}
+ \item[\cs{AssumeLWFN}] Assume postscript fonts for which nothing
+ else has been specified are stored in files which are named
+ according to the \mbox{MacOS} scheme for
+ \texttt{LWFN}s.%\footnote{LaserWriter FoNt}
+\end{description}
+Otherwise the default action is to use the name of the \afm or \pl from
+which the metrics were originally taken, and add the file suffix stored
+in the string \texttt{PSfontsuffix}. The default value of this string
+is \texttt{.pfa}, but it can be changed using |\resetstr|.
+
+If neither the default nor the LWFN scheme produce correct results
+then you may use the more specific |\specifypsfont| command, which
+describes exactly which file (or files, if any) a given font is stored
+in. The syntax of this command is
+\begin{quote}
+ |\specifypsfont|\marg{PS font name}\marg{actions}
+\end{quote}
+where the \meta{actions} is a sequence of ``action commands''.
+Currently the only such command is
+\begin{quote}
+ |\download|\marg{file}
+\end{quote}
+which instructs the map file writer to include in any entry using
+that PS font and ``instruction'' that the specified file should be
+downloaded. Some examples are
+\begin{verbatim}
+ \specifypsfont{Times-Roman}{}
+ \specifypsfont{Shareware-Cyrillic-Regular}{\download{fcyr.gsf}}
+ \specifypsfont{zmnl8ac6}{%
+ \download{MinionMM.pfb}\download{zmnl8ac6.pro}%
+ }
+\end{verbatim}
+Many \dvi drivers (for example \dvips) have more than one style of
+font downloading (e.g., partial and full downloading). This interface
+could be extended to control also such finer details (for example by
+adding a |\fulldownload| command to force full download of a font),
+but requests for this has so far been scarce.
+
+Finally, there is the |\declarepsencoding| command which is used to
+link \etx files to postscript encodings. If no postscript encoding has
+been linked to a given \etx file then \fontinst will
+automatically create a postscript encoding (\texttt{.enc}) file for
+that encoding, and use this file for all reencoding commands.
+The \texttt{8r} encoding is predeclared, and it doesn't
+matter if an encoding is undeclared if you never use it to reencode
+fonts, but there is potentially a problem with not having declared
+encodings you have installed and use for reencoding, as you may then
+find yourself having two files with identical names that define
+encodings that do not have the same name (as far as postscript is
+concerned).
+
+
+
+\subsection{Tuning accent positions---an application of loops}
+
+The accent placements made by \texttt{latin.mtx} certainly aren't
+perfect for all fonts, and the only way to find out where they should
+be put is through trying in text the accented letters you get for a
+couple of values for the position parameter and deciding which one
+works best. Since to try one parameter value you need to (i) edit it
+into an \mtx file, (ii) run \fontinst, (iii) run
+\vptovf, (iv) run \TeX\ on some test text, and (v) print that
+text, trying one parameter value can take annoyingly much time.
+Repeating the same procedure ten times to test ten values is not
+something one does without being bored (unless one scripts it, of
+course), but it is possible to try ten parameter values in a single
+virtual font, and without doing very much typing.
+
+Say you're not too happy with how \texttt{latin.mtx} positions the
+accent in the \texttt{ohungarumlaut} glyph:
+\begin{quote}
+ |\setglyph{ohungarumlaut}|\\
+ | \topaccent{o}{hungarumlaut}{500}|\\
+ |\endsetglyph|
+\end{quote}
+The |500| is the horizontal position (in thousandths of the width of
+the \texttt{o}) that the centre of \texttt{hungarumlaut} in the glyph
+constructed will have, so that is the position parameter value that
+you want to change. Create an \mtx file containing the code
+\begin{quote}
+ |\for(pos){250}{750}{50}|\\
+ | \setglyph{ohungarumlaut\strint{pos}}|\\
+ | \topaccent{o}{hungarumlaut}{\int{pos}}|\\
+ | \endsetglyph|\\
+ | \setleftrightkerning{ohungarumlaut\strint{pos}}|\\
+ | {ohungarumlaut}{1000}|\\
+ |\endfor(pos)|
+\end{quote}
+This will set eleven glyphs \texttt{ohungarumlaut250},
+\texttt{ohungarumlaut300}, \texttt{ohungarumlaut350}, \textellipsis\,,
+\texttt{ohungarumlaut750}, each being an Hungarianly umlauted `o'
+(i.e., an `\H{o}') but all having that umlaut in slightly different
+positions. In order to put them in a font, you also need to make an
+encoding that contains them. Therefore create an \etx file which
+contains the code
+\begin{quote}
+ |\relax\encoding|\\
+ |\nextslot{"C0}|\\
+ |\for(pos){250}{750}{50}|\\
+ | \setslot{ohungarumlaut\strint{pos}}|\\
+ | \endsetslot|\\
+ |\endfor(pos)|\\
+ |\endencoding|
+\end{quote}
+The command for installing this experiment font would be something like
+\begin{quote}
+ |\installfont|\marg{some name}|{|\meta{the normal list of metrics}%
+ |,|\penalty0\meta{the new \mtx}|}|\penalty0
+ |{ot1,|\meta{the new \etx}|}|\penalty0|{OT1}|\textellipsis
+\end{quote}
+The reason for including \texttt{ot1} in the third argument above is
+that you'll need letters other than `\H{o}' against which you can
+compare the experimental glyphs. It would not have been possible to
+use \texttt{t1} instead of \texttt{ot1} (even though that has more
+Hungarian letters) since that would set all slots in the font and
+leave none for these experimental \texttt{ohungarumlaut}s.
+
+It is even possible to use a loop for making the test text. The
+\LaTeX\ macros
+\begin{verbatim}
+\newcount\slotcount
+\newcommand\testtext[3]{%
+ \slotcount=#1\relax
+ \begin{description}%
+ \loop\item[\the\slotcount]#3%
+ \ifnum #2>>\slotcount \advance \slotcount 1 \repeat
+ \end{description}%
+}
+\DeclareTextCompositeCommand{\H}{OT1}{o}{\char\slotcount}
+\end{verbatim}
+will let you write
+\begin{quote}
+ |\testtext|\marg{first}\marg{last}\marg{text}
+\end{quote}
+to get the text \meta{text} typeset once for each slot from
+\meta{first} to \meta{last} inclusive, with |\H{o}| ranging through the
+glyphs in this interval. Thus in this case
+|\testtext|\penalty\hyphenpenalty|{"C0}|\penalty\hyphenpenalty|{"CA}|%
+\penalty\hyphenpenalty|{Erd\H{o}s}| would be a trivial test.
+
+
+\subsection{Font installation commands}
+\label{Ssec:FontInstCmds}
+
+The |\installfont|, |\installrawfont|, and |\installfontas| commands
+have the respective syntaxes
+\begin{isyntax}
+ |\installfont|\marg{font-name}\marg{metrics}\marg{etx-list}\penalty0
+ \marg{encoding}\marg{family}\marg{series}\marg{shape}\marg{size}\\
+ |\installrawfont|\marg{font-name}\marg{metrics}\marg{etx-list}%
+ \penalty0
+ \marg{encoding}\marg{family}\marg{series}\marg{shape}\marg{size}\\
+ |\installfontas|\marg{font-name}\penalty0\marg{encoding}%
+ \marg{family}\marg{series}\marg{shape}\marg{size}
+\end{isyntax}
+The \meta{font-name} argument and the last five arguments are common
+to all these commands. The first argument is the name of a \TeX\ font
+to install. The last five arguments are the NFSS attributes under which
+that font will be declared to \LaTeX---encoding, family, series, shape,
+and size. It is worth observing that encoding names are usually in
+upper case, whereas the family, series, and shape are usually in lower
+case. The size argument is either a shorthand (declared using
+|\declaresize|) for a particular font
+size (or range of font sizes), or an explicit list of font sizes or
+ranges of sizes, which is copied directly to the font declaration.
+The most common case is to let the size argument be empty, as that is
+declared as a shorthand for ``any size''.
+
+The |\installfontas| command does not itself create the font, it just
+makes a note that the specified font declaration should be written to
+the proper FD file at |\end|\-|install|\-|fonts|. The
+|\install|\-|font| and |\install|\-|raw|\-|font| commands do however
+produce the font, in the sense that they write a \vpl and \pl
+respectively file for the font. It depends solely on the \meta{metrics}
+and \meta{etx-list} arguments what this font will contain. Many
+features of these arguments are new with \fontinst v\,1.9;
+therefore the complete syntaxes are described below.
+
+Both arguments are comma-separated lists of basically file names (not
+including an extension). The files listed in the \meta{metrics} are
+font metric files which together build up a \emph{glyph base}
+(definitions of glyphs and metrics related to one or several glyphs),
+whereas the files listed in the \meta{etx-list} are encoding definition
+files that select a subset of the glyph base for turning into a
+\TeX\ font. The font metrics can be in either of the four formats
+\mtx, \pl, \afm, and \vpl, which are considered in that order. If the
+metrics are not originally in \mtx format then they will be converted
+to this format (a new file will be created) before they are used.
+The encoding definitions must be in \etx format. The files actually
+read will have a suffix \texttt{.mtx}, \texttt{.pl}, \texttt{.afm},
+\texttt{.vpl}, or \texttt{.etx} appended to the name given, depending
+on which format is expected.
+
+Within each element of the comma-separated list, the actual file name
+is followed by zero or more \emph{modifier clause}s. A \meta{modifier
+clause} consists of a \emph{keyword} followed by some number (usually
+one) of \emph{arguments}, separated by spaces. The whole thing looks
+a lot like the \meta{rule specifications} of e.g.\ the |\vrule|
+command, but here the spaces are mandatory. The currently defined
+\meta{modifier clause}s are
+\begin{description}
+ \item[\mdseries\textvisiblespace\texttt{option}\textvisiblespace
+ \meta{string}]
+ Available for metric and encoding files. This adds \meta{string}
+ to the list of options for this file, which may affect what code
+ the file executes. The file can then test, using the |\ifoption|
+ command, whether a specific string is one of the options it was
+ given.
+ \item[\mdseries\textvisiblespace\texttt{scaled}\textvisiblespace
+ \meta{factor}]
+ Available for metric files. Causes the \texttt{rawscale} integer
+ variable to be set to the \meta{factor} (an integer expression)
+ while the file is being read. This scales glyphs and kerns that
+ are added to the glyph base by the \meta{factor}.
+ \item[\mdseries\textvisiblespace\texttt{suffix}\textvisiblespace
+ \meta{suffix}]
+ Available for metric files. Causes \meta{suffix} to be appended
+ to every glyph name appearing in a glyph or kern that file adds
+ to the glyph base. Thus ``\texttt{suffix /2}'' effectively
+ changes a
+ \begin{quote}
+ |\setrawglyph{a}|\dots
+ \end{quote}
+ to a
+ \begin{quote}
+ |\setrawglyph{a/2}|\dots
+ \end{quote}
+ \item[\mdseries\textvisiblespace\texttt{encoding}\textvisiblespace
+ \meta{etx-name}]
+ Available for metric files, and forces \fontinst to
+ only consider the \pl and \vpl formats for this font.
+ As these file formats do not contain glyph names, an \etx file
+ is used to assign glyph names to the slots in the font.
+ This \etx file is usually selected according to the
+ \texttt{CODINGSCHEME} property of the \pl or \vpl (using the
+ correspondences set up via the |\declare|\-|encoding| command),
+ but that information is not always as one would want it (there
+ are even fonts for which it is quite wrong). An \texttt{encoding}
+ clause bypasses this automatic mechanism, so that the file
+ \meta{etx-name}\texttt{.etx} is used instead.
+
+% % The following is no longer true as of v1.926:
+% \textbf{Note:} The first time that a file in PL or VPL format is
+% used in a \meta{metrics} argument, a corresponding \mtx file is
+% generated. This means that if the same file reference is used
+% another time then the reference will be to the \mtx file, not to
+% the original PL or VPL, and thus \texttt{encoding} clauses on
+% subsequent uses will have no effect. Each font only has one
+% encoding, so it usually makes no sense to switch the \etx file
+% used to interpret a font, but since \mtx files are not
+% automatically deleted between runs there is a risk that this
+% takes away the intended effect of an \texttt{encoding} clause.
+
+ \item[\mdseries\textvisiblespace\texttt{mtxasetx}]
+ This is available for files in the \meta{etx-list}. The actual
+ function of a
+ \begin{quote}
+ \meta{file-name} \texttt{mtxasetx}
+ \end{quote}
+ item in the \meta{etx-list} is that the file
+ \meta{file-name}\texttt{.mtx} is inputted (\emph{not}
+ \meta{file-name}\texttt{.etx}) and that the correspondence
+ between glyph names and slot numbers set up in
+ |\set|\-|raw|\-|glyph| or |\set|\-|scaled|\-|raw|\-|glyph|
+ commands in this file is treated as if it had been set up by
+ |\setslot| commands in an \etx file. Provided the \mtx file is
+ transformable, the glyph base will be unaffected.
+
+ The purpose of this feature is to simplify quick and dirty
+ installations of odd fonts for which no suitable \etx file is
+ available. This can be useful in early stages of the design of
+ a new font, but is inferior to installation using proper \etx
+ files since one for example cannot specify any ligatures in
+ \mtx files.
+\end{description}
+Furthermore there is a special exception for the \meta{metrics}: if
+the first token in one of the list items is the control sequence
+|\metrics|, then the rest of that item is interpreted as explicit
+metric commands to execute.
+
+If the \meta{metrics} of two subsequent |\install|\-|font|
+or |\install|\-|raw|\-|font| commands are identical then the glyph
+bases will be identical as well. This creates an opportunity for
+optimization, which \fontinst makes use of by caching glyph
+bases from one installation command to the next so that the glyph
+base does not have to be rebuilt in these cases. A side-effect of
+this caching is that local assignments made between two font
+installation commands are cleared out with the glyph base, but
+|\setint| and similar \fontinst commands make global
+assignments when used in such positions.
+
+Some examples might be in order. The first is an adaptation of an
+installation command from \texttt{mfnt-0.59} %~\cite{mfnt}
+by Matthias Clasen and Ulrik Vieth: the installation command for the
+8-bit math font \texttt{xma1000} (which can be thought of as being
+to \texttt{cmmi10} sort of as \texttt{ecrm1000} is to \texttt{cmr10}).
+The first three \texttt{encoding} clauses are more fine-tuning---without
+them, a few glyphs would get incorrect names---but the last two are
+quite essential, as the \texttt{msam10} and \texttt{msbm10} fonts
+incorrectly claim to have the coding scheme \texttt{TEX MATH
+SYMBOLS}.
+\begin{verbatim}
+ \installfont{xma1000}{%
+ yma1000 encoding mcin,%
+ cmr10 encoding ot1upright,%
+ cmmi10,%
+ cmsy10 encoding omscal,%
+ msam10 encoding msam,%
+ msbm10 encoding msbm,%
+ mccmhax,mccmkern,mcmissing,%
+ cmsy10-base,cmsy10-extra%
+ }{mc}{MC}{cm}{m}{n}{<<10->>}
+\end{verbatim}
+Also note the explicit \LaTeX\ size specification for the range
+``10\,pt and up''.
+
+The second example makes use of a \texttt{suffix} clause to combine
+the letters from one font with the digits from another.
+\begin{verbatim}
+ \installfont{msbrj8t}{msbr8r,msbrc8r suffix /2,latin}{digit2,t1}
+ {T1}{msbj}{m}{n}{}
+\end{verbatim}
+In this case, the glyph base contains the glyphs of Monotype Sabon
+(SabonMT)---under names such as \texttt{A} for `A', \texttt{a} for
+`a', and \texttt{one} for a lining digit one---as well as the
+glyphs of Monotype Sabon Small Caps and Oldstyle Figures
+(SabonMT-SCOSF)---under names such as \texttt{A/2} for `A',
+\texttt{a/2} for `\textsc{a}', and \texttt{one/2} for a hanging
+digit one. The \texttt{digit2.etx} file simply makes the definition
+\begin{verbatim}
+ \setcommand\digit#1{#1/2}
+\end{verbatim}
+which causes \texttt{t1.etx} to put \texttt{zero/2} in slot 48 (digit
+zero), \texttt{one/2} in slot 49 etc., instead of as it normally
+would \texttt{zero} in slot 48, \texttt{one} in slot 49 and so on.
+The net effect is that the digits in the generated \texttt{msbrj8t}
+is from \texttt{msbrc8r} (SabonMT-SCOSF) but everything else is from
+\texttt{msbr8r} (SabonMT).
+
+The third example makes use of an \texttt{mtxasetx} clause to install
+(with its default encoding) a font for which creating an appropriate
+\etx file seems not worth the trouble.
+\begin{verbatim}
+ \installrawfont{psyr}{psyr,\metrics
+ \setint{xheight}{\height{alpha}}
+ }{txtfdmns,psyr mtxasetx}{U}{psy}{m}{n}{}
+\end{verbatim}
+The effect of the second \texttt{psyr} is that \texttt{psyr.mtx} is
+read (in case there was no \texttt{psyr.mtx} then it is created from
+(hopefully) \texttt{psyr.afm}) and the information in it will form
+the glyph base. Because of the |\metrics| control sequence, the rest
+of that item will be interpreted as explicit metric commands
+modifying the glyph base, and thus the |\setint| command can provide
+a value for the \texttt{xheight} variable (there doesn't seem to be
+such a value in the \afm). Once the glyph base is completed, the
+|\install|\-|raw|\-|font| starts writing the file \texttt{psyr.pl}
+(that's for the first \texttt{psyr}). The encoding of that font will,
+because of the \texttt{psyr mtxasetx}, be the same as that used in
+\texttt{psyr.mtx}. Finally, the \texttt{txtfdmns} is for
+\texttt{txtfdmns.etx}, an \etx file which sets fontdimens 1--16 as for
+a \texttt{T1} encoded font but does not set any slots. Since
+\texttt{psyr.mtx} reinterpreted as an \etx file sets slots but no
+fontdimens, these complement each other nicely.
+
+
+
+\subsection{Bounding boxes}
+
+Han The Thanh has created an implementation of bounding box support
+for \fontinst, and it is a modified form of that support
+is distributed with \fontinst as the file \texttt{bbox.sty}. To load
+this, begin your command file with
+\begin{verbatim}
+ \input fontinst.sty
+ \input bbox.sty
+\end{verbatim}
+The reason for not making it default is that keeping track of bounding
+boxes increases some of \fontinst's memory requirements quite a lot.
+
+One important
+characteristic of this implementation is that the dimensions of the
+bounding box are not bundled into the same data structure (the
+|\g-|\meta{glyph} macros) as the glyph's width, height, depth, and
+italic correction are, but stored in a separate data structure (the
+|\gb-|\meta{glyph} macros). A glyph doesn't need to have its bounding
+box set, it is simply a piece of information that \fontinst
+will store if you tell it to and which you can later retrieve.
+
+The bounding box will be stored as coordinates of the sides in the
+normal AFM coordinate system. The commands for retrieving these
+coordinates are
+\begin{center}
+ \begin{tabular}{ll}
+ \textbf{Command}& \textbf{Side}\\
+ |\bbtop|\marg{glyph}& top ($y$-coordinate)\\
+ |\bbbottom|\marg{glyph}& bottom ($y$-coordinate)\\
+ |\bbleft|\marg{glyph}& left ($x$-coordinate)\\
+ |\bbright|\marg{glyph}& right ($x$-coordinate)
+ \end{tabular}
+\end{center}
+In Thanh's implementation the command names were |\ury|, |\lly|,
+|\llx|, and |\urx| respectively instead, but I think the former are
+easier to remember. If no bounding box has been set for a glyph then
+the above commands will instead report the corresponding coordinate of
+the glyph's \TeX\ box (i.e.\ |\height|\marg{glyph},
+|\neg{\depth|\marg{glyph}|}|, |0|, and |\width|\marg{glyph}
+respectively).
+
+The command for setting the bounding box of a glyph is
+\begin{quote}
+ |\setglyphbb|\marg{glyph}\marg{left}\marg{bottom}\marg{right}%
+ \marg{top}
+\end{quote}
+
+
+
+
+
+\section*{Acknowledgements}
+
+We'd like to thank all of the \fontinst $\alpha$-testers, especially
+Karl Berry, Damian Cugley, Steve Grahthwohl, Yannis Haralambous, Alan
+Hoenig, Rob Hutchings, Constantin Kahn, Peter Busk Laursen, Ciar{\'a}n {\'O}
+Duibh{\'\i}n, Hilmar Schlegel, Paul Thompson, Norman Walsh and John Wells,
+who made excellent bug-catchers!
+
+Thanks to Barry Smith, Frank Mittelbach, and especially Sebastian
+Rahtz for many useful email discussions on how virtual fonts should
+interact with \LaTeXe.
+
+Thanks to Karl Berry and Damain Cugley for detailed comments on this
+documentation.
+
+Thanks to David Carlisle for the use of his \texttt{trig} macros for
+calculating trigonometry.
+
+
+% \section*{Warranty and distribution}
+%
+% There is no warranty for the \fontinst package, to the extent
+% permitted by applicable law. Except when otherwise stated in writing,
+% the author provides the program `as is' without warranty of any kind,
+% either expressed or implied, including, but not limited to, the
+% implied warranties of merchantability and fitness for a particular
+% purpose. The entire risk as to the quality and performance of the
+% program is with you. Should the package prove defective, you assume
+% the cost of all necessary servicing, repair or correction.
+%
+% In no event unless required by applicable law or agreed to in writing
+% will the author be liable to you for damages, including any general,
+% special, incidental or consequential damages arising out of the use or
+% inability to use the program (including but not limited to loss of
+% data or data being rendered inaccurate or losses sustained by you or
+% third parties or a failure of the program to operate with any other
+% programs), even if such holder or other party has been advised of the
+% possibility of such damages.
+%
+% Redistribution of unchanged files is allowed provided that all files
+% listed in the \texttt{MANIFEST} file are distributed.
+%
+% If you receive only some of these files from someone, or if you
+% receieve altered files, then complain!
+
+\end{document}
diff --git a/fonts/utilities/fontinst/doc/manual/intro98.pdf b/fonts/utilities/fontinst/doc/manual/intro98.pdf
new file mode 100644
index 0000000000..a7bb583f6b
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/manual/intro98.pdf
Binary files differ
diff --git a/fonts/utilities/fontinst/doc/manual/intro98.tex b/fonts/utilities/fontinst/doc/manual/intro98.tex
new file mode 100644
index 0000000000..0e7c485ab6
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/manual/intro98.tex
@@ -0,0 +1,1330 @@
+%%% ====================================================================
+%%% @LaTeX-file{
+%%% author = "Alan Jeffrey and Rowland McDonnell and
+%%% Ulrik Vieth and Lars Hellstr{\"o}m",
+%%% version = "1.927",
+%%% date = "28 July 2004",
+%%% time = "23:20:27 CEST",
+%%% filename = "intro98.tex",
+%%% email = "fontinst@tug.org",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "fontinst, TeX, PostScript, documentation",
+%%% supported = "yes",
+%%% abstract = "This is documentation for the fontinst
+%%% font installation package.",
+%%% package = "fontinst",
+%%% dependencies = "ltxguide.cls, url.sty, xspace.sty"
+%%% }
+%%% ====================================================================
+
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey
+
+% Modified by Rowland McDonnell June 1998
+% Modified and revised by Ulrik Vieth June 1998
+
+\documentclass[a4paper]{ltxguide}
+\usepackage[OT1]{fontenc}
+\usepackage{url,xspace}
+\usepackage{graphicx}
+%\renewcommand\rmdefault{ppl}
+%\renewcommand\rmdefault{padx}
+%\renewcommand\rmdefault{pmnx}
+
+
+% Title page and running heads.
+
+\makeatletter
+\newcommand{\subtitle}[1]{\renewcommand{\@subtitle}{#1}}
+\newcommand{\version}[1]{\renewcommand{\@version}{#1}}
+\newcommand{\illustration}[1]{\renewcommand{\@illustration}{#1}}
+
+\newcommand{\@subtitle}{}
+\newcommand{\@version}{???}
+\newcommand{\@illustration}{cover.eps}
+
+\pagestyle{myheadings}
+\AtBeginDocument{\markright{\small\itshape
+ \@author\hfill\@title: \@subtitle\quad}}
+
+
+\renewcommand{\maketitle}{{%
+ \thispagestyle{empty}%
+ \normalfont\centering
+ \null
+ {\fontsize{100}{100}\textit{\@title}}%
+ \par\bigskip
+ {\Large\textbf{\@subtitle}}%
+ \vfill
+ \includegraphics[width=\textwidth]{\@illustration}%
+ \vfill
+ {\Large\textbf{%
+ \@author\\[\smallskipamount] \@title~v\@version
+ \quad\textperiodcentered\quad \@date}}%
+ \clearpage
+}}
+\makeatother
+
+
+% Set lists tighter (assuming non-zero \parskip).
+
+\makeatletter
+\renewcommand{\@listI}{%
+ \leftmargin\leftmargini
+ \parsep\medskipamount
+ \itemsep\z@ % + parsep
+ \topsep\z@ % + parskip
+ \partopsep\z@
+}
+\makeatother
+
+% Set spacing around captions.
+
+\setlength{\abovecaptionskip}{\medskipamount}
+\setlength{\belowcaptionskip}{\medskipamount}
+
+% Markup for logos, file types, programs, etc.
+
+\newcommand*{\cs}[1]{\texttt{\char`\\ #1}\xspace}
+
+\newcommand*{\OzTeX}{O\kern-.03em z\kern-.15em\TeX}
+\newcommand*{\OzMF}{O\kern-.03em zMF}
+\newcommand*{\OzTools}{O\kern-.03em z\kern-.15em Tools}
+
+\newcommand{\PS}{Post\-Script\xspace}
+\newcommand{\TT}{True\-Type\xspace}
+
+\newcommand*{\setfilename}[1]{\texttt{#1}}
+\newcommand*{\setdotfilename}[1]{\setfilename{.#1}}
+\newcommand*{\setpackagename}[1]{\textsc{#1}}
+
+\newcommand{\dvips} {\setpackagename{dvips}\xspace}
+\newcommand{\Dvips} {\setpackagename{Dvips}\xspace}
+\newcommand{\fontinst}{\setpackagename{font\-inst}\xspace}
+\newcommand{\Fontinst}{\setpackagename{Font\-inst}\xspace}
+
+% \show\fontname
+\newcommand{\fontnamekb}{fontname\xspace}
+\newcommand{\Fontnamekb}{Fontname\xspace}
+
+\newcommand{\mf} {\setfilename{mf}\xspace}
+\newcommand{\Mf} {\setfilename{Mf}\xspace}
+\newcommand{\vf} {\setfilename{vf}\xspace}
+\newcommand{\Vf} {\setfilename{Vf}\xspace}
+\newcommand{\pl} {\setfilename{pl}\xspace}
+\newcommand{\Pl} {\setfilename{Pl}\xspace}
+\newcommand{\fd} {\setfilename{fd}\xspace}
+\newcommand{\Fd} {\setfilename{Fd}\xspace}
+\newcommand{\pk} {\setfilename{pk}\xspace}
+\newcommand{\Pk} {\setfilename{Pk}\xspace}
+\newcommand{\afm}{\setfilename{afm}\xspace}
+\newcommand{\Afm}{\setfilename{Afm}\xspace}
+\newcommand{\vpl}{\setfilename{vpl}\xspace}
+\newcommand{\Vpl}{\setfilename{Vpl}\xspace}
+\newcommand{\tfm}{\setfilename{tfm}\xspace}
+\newcommand{\Tfm}{\setfilename{Tfm}\xspace}
+\newcommand{\mtx}{\setfilename{mtx}\xspace}
+\newcommand{\Mtx}{\setfilename{Mtx}\xspace}
+\newcommand{\etx}{\setfilename{etx}\xspace}
+\newcommand{\Etx}{\setfilename{Etx}\xspace}
+\newcommand{\pfa}{\setfilename{pfa}\xspace}
+\newcommand{\Pfa}{\setfilename{Pfa}\xspace}
+\newcommand{\pfb}{\setfilename{pfb}\xspace}
+\newcommand{\Pfb}{\setfilename{Pfb}\xspace}
+\newcommand{\dvi}{\setfilename{dvi}\xspace}
+\newcommand{\Dvi}{\setfilename{Dvi}\xspace}
+\newcommand{\ttf}{\setfilename{ttf}\xspace}
+\newcommand{\Ttf}{\setfilename{Ttf}\xspace}
+
+\newcommand{\vftovp}{\setpackagename{vftovp}\xspace}
+\newcommand{\vptovf}{\setpackagename{vptovf}\xspace}
+\newcommand{\pltotf}{\setpackagename{pltotf}\xspace}
+\newcommand{\tftopl}{\setpackagename{tftopl}\xspace}
+
+
+% Stolen from Dr Knuth
+\makeatletter % borrow the private macros of PLAIN (with care)
+\def\oct#1{\hbox{\rm\'{}\kern-.2em\it#1\/\kern.05em}} % octal constant
+\def\hex#1{\hbox{\rm\H{}\tt#1}} % hexadecimal constant
+% macros for font tables
+\def\oddline#1{\cr
+ \noalign{\nointerlineskip}
+ \multispan{19}\hrulefill&
+ \setbox0=\hbox{\lower 2.3pt\hbox{\hex{#1x}}}\smash{\box0}\cr
+ \noalign{\nointerlineskip}}
+\def\evenline{\cr\noalign{\hrule}}
+\def\chartstrut{\lower4.5pt\vbox to14pt{}}
+\def\beginchart#1{$$\global\count@=0 #1
+ \halign to\hsize\bgroup
+ \chartstrut##\tabskip0pt plus10pt&
+ &\hfil##\hfil&\vrule##\cr
+ \lower6.5pt\null
+ &&&\oct0&&\oct1&&\oct2&&\oct3&&\oct4&&\oct5&&\oct6&&\oct7&\evenline}
+\def\endchart{\raise11.5pt\null&&&\hex 8&&\hex 9&&\hex A&&\hex B&
+ &\hex C&&\hex D&&\hex E&&\hex F&\cr\egroup$$}
+\def\*{\global\advance\count@ by1 }
+\def\:{\setbox0=\hbox{\char\count@}%
+ \ifdim\ht0>7.5pt\reposition
+ \else\ifdim\dp0>2.5pt\reposition\fi\fi
+ \box0\global\advance\count@ by1 }
+\def\reposition{\setbox0=\hbox{$\vcenter{\kern2pt\box0\kern2pt}$}}
+\def\smallchart{%
+%\global\advance\count@ by16
+ &\oct{00x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline0
+ &\oct{01x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{02x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline1
+ &\oct{03x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{04x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline2
+ &\oct{05x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{06x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline3
+ &\oct{07x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{10x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline4
+ &\oct{11x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{12x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline5
+ &\oct{13x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{14x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline6
+ &\oct{15x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{16x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline7
+ &\oct{17x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline}
+
+\def\bigchart{%
+%\global\advance\count@ by16
+ &\oct{00x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline0
+ &\oct{01x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{02x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline1
+ &\oct{03x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{04x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline2
+ &\oct{05x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{06x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline3
+ &\oct{07x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{10x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline4
+ &\oct{11x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{12x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline5
+ &\oct{13x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{14x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline6
+ &\oct{15x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{16x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline7
+ &\oct{17x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{20x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline8
+ &\oct{21x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{22x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline9
+ &\oct{23x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{24x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline{A}
+ &\oct{25x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{26x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline{B}
+ &\oct{27x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{30x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline{C}
+ &\oct{31x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{32x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline{D}
+ &\oct{33x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{34x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline{E}
+ &\oct{35x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline
+ &\oct{36x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\oddline{F}
+ &\oct{37x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&\evenline}
+
+% \font\xrm = cmr10 at 10pt % change this line to test font
+% \beginchart\xrm \normalchart \endchart
+
+\newcommand{\smallfontchart}[1]{%
+ \font\xrm = #1 \beginchart\xrm \smallchart \endchart}
+\newcommand{\bigfontchart}[1]{%
+ \font\xrm = #1 \beginchart\xrm \bigchart \endchart}
+
+% \smallfontchart{cmr10 at 10pt}
+% \bigfontchart{ecrm1000 at 10pt}
+\makeatother
+% End stolen from Dr Knuth
+
+
+
+\title{fontinst}
+\subtitle{Font installation software for \TeX}
+\author{Alan Jeffrey and Rowland McDonnell}
+\illustration{roadmap.eps}
+\version{1.8}
+\date{30 June 1998}
+
+\begin{document}
+
+\maketitle
+
+
+\begin{small}
+ This is the tutorial part of the 1998 \fontinst manual, chiefly
+ written by Rowland McDonnell and conveying his then-view on related
+ subjects. Although most of it is still correct,
+ the passing of time has rendered it somewhat antiquated, and the
+ average current (2004) user new to \fontinst would probably find
+ Philipp Lehman's \emph{The Font Installation Guide}
+ (\url{http://www.ctan.org/tex-archive/info/Type1fonts/fontinstallationguide/})
+ more relevant.
+\end{small}
+
+\tableofcontents
+
+
+\clearpage
+
+\section{Introduction}
+
+The \fontinst package is a set of \TeX\ macros written to create
+virtual fonts for use with \TeX. Its main use is creating the
+files needed so you can use PostScript Type 1 fonts with \LaTeX.
+
+\Fontinst needs information about the fonts it works with. This
+information needs to be supplied in an Adobe Font Metric (\afm) or
+\TeX\ Property List (\pl) file. \pl files can be created from
+\tfm files using \tftopl, a program normally included with a \TeX\
+system.
+
+The job that \fontinst does is complicated, but it can be used for
+many tasks by people who are not \TeX\ font wizards. Having said
+that, you do need to understand at least the basics of \LaTeXe's
+font selection mechanism, which is documented in
+\texttt{fntguide.tex}, part of the standard \LaTeX\ distribution.
+\url{ftp://ftp.tex.ac.uk/tex-archive/macros/latex/base/fntguide.tex}
+will fetch a copy if you don't have one to hand.
+
+To get the most benefit out of \fontinst, it's important to
+understand and use Karl Berry's `\Fontnamekb' naming scheme. The
+definitive version of this is available from your nearest CTAN
+server. The following URL will fetch all the files needed
+compressed into a single ZIP archive:
+\url{ftp://ftp.tex.ac.uk/tex-archive/info/fontname.zip}. I
+suggest that you print out the \Fontnamekb documentation and have
+it handy when you're learning about \fontinst.
+
+The \fontinst package:
+\begin{itemize}
+\item Is written in \TeX, for maximum portability (at the cost of
+ speed).
+\item Supports the OT1 (Computer Modern) and T1 (Cork) encodings.
+\item Allows fonts to be generated with arbitrary `fake'
+ characters; for example the `ij' character can be faked if
+ necessary by putting an `i' next to a `j'.
+\item Allows caps and small caps fonts with letter spacing and
+ kerning.
+\item Allows kerning to be shared between characters, for example
+ `ij' can be kerned on the left as if it were an `i' and on the
+ right as if it were a `j'. This is useful, since many
+ PostScript fonts only include kerning information for characters
+ without diacriticals.
+\item Allows the generation of math fonts with \verb|nextlarger|,
+ \verb|varchar|, and arbitrary font dimensions.
+\item Allows more than one PostScript font to contribute to a
+ \TeX\ font, for example the `ffi' ligatures for a font can be
+ taken from the Expert encoding, if you have it.
+\item Can automatically generate a \fd file for use with \LaTeXe.
+\item Can be customized by the user to deal with arbitrary font
+ encodings.
+\end{itemize}
+Fontinst has been a stable piece of software since mid-1994. All
+further updates will be upwardly compatible with the interface
+described in this document.
+
+\subsection{What does \fontinst do?}
+
+\Fontinst is a tool written in \TeX\ that can create the various
+extra files needed so you can use \PS fonts with \LaTeX\ and \TeX.
+It can read in \afm files, and produces the necessary \vpl, \pl,
+and \fd files to use the fonts (the human-readable \vpl and \pl
+files produced by \fontinst are turned into the machine-readable
+\vf and \tfm forms by \vptovf and \pltotf). It does not help you
+configure your DVI driver.
+
+There also exists a \texttt{perl} front-end to \fontinst, intended
+specifically for use with a Unix \TeX\ system, which takes care of
+routine tasks such as running \vptovf and \pltotf on the generated
+files after \fontinst has finished it's job. It also generates a
+font map file for use with \dvips.
+
+\Fontinst's main job is creating \vf files (virtual fonts). Not
+all \TeX\ systems can use them. As far as I know, all current
+(1998) free and shareware \TeX\ systems can; virtual fonts have
+been in widespread use with \TeX\ since 1990. If you have a TeX
+system that can't use virtual fonts, \fontinst is most likely
+useless to you.
+
+There are some nice things about having a tool written in \TeX\ to
+do this: it's completely portable and you can modify its behaviour
+using \TeX\ commands. The only real problem is that it's
+relatively slow: you can expect a typical \fontinst run to take
+something like 10--20 minutes on, say, a 40~MHz 80486SX PC or a
+25~MHz 68LC040 Macintosh.
+
+\Fontinst can do its work on any font for which you have a
+corresponding \afm or \tfm metric file, so it's not limited to
+working with \PS fonts; I have used it to produce the files I
+needed to use \TT fonts with \LaTeX. Whether or not you can do
+this depends on whether or not you have suitable metric files and
+whether or not your \TeX\ system can use \TT fonts. In
+particular, the pdf\TeX\ program supports \TT fonts and includes a
+utility \texttt{ttf2afm} to generate \afm files from \ttf fonts.
+
+Some people have used \fontinst to produce `special effects' with
+normal \TeX\ fonts. One example is the \setpackagename{eco} set
+of fonts (available from CTAN:
+\url{ftp://ftp.tex.ac.uk/tex-archive/fonts/eco/}). These fonts
+are the same as the standard EC (European Modern) fonts, but with
+normal numerals replaced with old style numerals --
+\oldstylenums{12345} rather than 12345 -- everywhere except in
+maths mode.
+
+\subsection{Installation}
+
+To install \fontinst, put the contents of the \url{inputs/tex},
+\url{inputs/etx}, \url{inputs/mtx} and \url{examples} directories
+into a directory read by \TeX, for example
+\url{TEXMF/tex/generic/fontinst}.
+
+When you use \fontinst, you need to make sure that the \afm and
+\pl files it will work on are in a directory searched by \TeX.
+
+If you are using \texttt{web2c} \TeX\ on a Unix system with the
+\TeX\ directory structure (TDS), you might put all the \afm files
+in subdirectories of \url{TEXMF/fonts/afm/*}. And then say:
+\begin{verbatim}
+ setenv TEXINPUTS $TEXMF/fonts/afm//::
+\end{verbatim}%$
+Note that \pl files are not normally kept in \TeX\ installations, so
+if you want to use MF fonts with \fontinst you have to generate the
+corresponding \pl files from \tfm files and put them in your working
+directory before running \fontinst.
+
+You could adopt a similar strategy with other \TeX\ systems:
+create directories for the required files and then change the
+relevant parameter (\url{input_folders} in the default
+configuration file with \OzTeX, for example).
+
+The approach I use is this: I write a file containing commands for
+\fontinst to process, and put the \afm and \pl files needed in the
+same directory as that file. When \fontinst has finished working,
+I delete the \afm and \pl files because they are not needed and
+waste space on my hard disc drive. Some application programs on
+some computers need \afm files, so it's not always a good idea to
+remove them completely.
+
+\subsection{Why do we need \fontinst?}
+
+\TeX\ refers to characters by number when it's typesetting. When
+you use a command like \verb|\i|, \TeX\ puts a number (16 if
+you're using OT1, 25 if you're using T1) into the \dvi file. If
+you're using a font designed for use with \TeX, this number will
+correspond to the character `\i'. Assuming OT1 encoding for the
+moment, when you come to print out your \dvi file, the DVI driver
+will see the number 16 in the \dvi file, and select the character
+that sits in position 16 of the corresponding printer font file (a
+\pk file in the case of normal \TeX\ fonts). Unless something has
+gone wrong, that will result in the character `\i' being placed on
+the page.
+
+It's useful to think of these numbers and the actual characters
+corresponding to each number as sets called `encodings'. A
+particular set of characters are assigned particular numbers. An
+example of an encoding is shown in table~\ref{OT1table}.
+
+\TeX\ began life using 7-bit fonts. This means the original \TeX\
+fonts used the numbers 0--127 to represent characters:
+128~characters per font. \TeX\ can now use 8-bit fonts:
+256~numbers from 0--255, but even so, most typesetting with \TeX\
+still uses the original 7-bit encoding, now called `OT1' (Old
+\TeX~1 encoding). This has a correspondance between numbers and
+characters shown in table~\ref{OT1table}. The numbers used in
+that table are hexadecimal and octal because it makes for a neat
+table and anyway I stole the code to generate it from Donald Knuth
+and that's how he did it.
+
+\begin{table}[!t]
+\smallfontchart{cmr10 at 10pt}
+\caption{The OT1 font encoding}\label{OT1table}
+\end{table}
+
+Returning to the example above, if you've a number 16 in your \dvi
+file (expecting `\i', a dotless~i), but rather than printing
+with an OT1 encoded font, you print using a non re-encoded \PS
+font in Adobe standard encoding, you'll get a blank, because the
+Adobe standard encoding has nothing in that character position.
+
+There are several ways round this problem; I'll consider two cases
+here. If you are using \LaTeX\ you can tell it about a new
+encoding and re-define the commands that produce characters like
+`\i' that live in different positions in different encodings, or
+you can use a tool to re-encode the font so that it has the
+expected characters in the appropriate positions.
+
+Re-encoding is the approach \fontinst uses: it can produce files
+to map the characters in the new font to one of \TeX's existing
+encodings; this works with formats other than \LaTeX.
+
+The first approach is used to define the standard encodings that
+\LaTeX\ uses. See, for example, the file \texttt{ot1enc.def} that
+comes with the current \LaTeX\ distribution, which defines the a
+few commands that refer to characters which aren't in the
+positions \TeX\ would otherwise assume. This works only with
+modern versions of \LaTeX.
+
+The second approach is used to allow you to use fonts in other
+encodings with any dialect of \TeX. It has the some advantages
+over the first method: it works with any \TeX\ format; and it
+improves portability, because you can typeset a document using a
+standard \TeX\ encoding, sure that the same document will print
+correctly on a different kind of computer using a font with a
+different encoding. For example, you might say:
+\begin{verbatim}
+ \usepackage{times}
+\end{verbatim}
+in the preamble of your document. On my computer, that means my
+DVI driver will use a Macintosh encoded \TT version of Times. On
+your computer, it might mean the dvi driver will use a Unicode
+encoded \PS version of Times-Roman. The results will be identical
+in either case, without needing to modify the document.
+
+\subsection{How do you use \fontinst?}
+
+\Fontinst works on \afm files named (more-or-less) according to
+Karl Berry's font naming scheme (see
+\url{ftp://ftp.tex.ac.uk/tex-archive/info/fontname} at CTAN).
+Let's say you want to use the Adobe Times fonts. You can get the
+metric files for this font from CTAN:
+\begin{center}
+\begin{small}
+\begin{tabular}{ll}
+ \emph{Location of file at CTAN} & \emph{Rename to} \\
+ \url{fonts/psfonts/adobeafm/base35/tib_____.afm} &
+ \texttt{ptmb8a.afm} \\
+ \url{fonts/psfonts/adobeafm/base35/tibi____.afm} &
+ \texttt{ptmbi8a.afm} \\
+ \url{fonts/psfonts/adobeafm/base35/tii_____.afm} &
+ \texttt{ptmri8a.afm} \\
+ \url{fonts/psfonts/adobeafm/base35/tir_____.afm} &
+ \texttt{ptmr8a.afm}
+\end{tabular}
+\end{small}
+\end{center}
+The new name is the name you should give the \tfm files so that
+\fontinst understands what each file contains. The initial `|p|'
+means `Adobe'; `|tm|' means `Times'; `|b|' bold, `|r|' roman,
+`|i|' italic; and `|8a|' means `Adobe standard encoding'.
+
+The simplest use of \fontinst is to put the four \afm files in the
+same directory as \texttt{fontinst.sty} and run \TeX\ on
+\texttt{fontinst.sty}. At the \verb|*| prompt type:
+\begin{verbatim}
+ *\latinfamily{ptm}{} \bye
+\end{verbatim}
+
+Some time later (about 17 minutes on my rather old computer),
+\fontinst will have finished, having created:
+\begin{itemize}
+\item Two \pl files for each \afm file
+\item One \vpl file for each \TeX\ font
+\item One \fd file for each family
+\end{itemize}
+The \pl files come in pairs: for example, \texttt{ptmb8a.pl} and
+\texttt{ptmb8r.pl}. The |8a| version has the same encoding as the
+original font; the |8r| version is re-encoded to |TeXBase1| (|8r|)
+encoding, and is the font that is the base on which the T1 and OT1
+encoded versions are based on. The raw |8a| (Adobe standard)
+encoded font is not normally used.
+
+These can be converted to \TeX\ fonts using \pltotf or \vptovf.
+If you have \OzTeX, launch \OzMF, select \pltotf (or \vptovf) from
+the Tools menu, and say `Do all files'.
+
+If you use the \texttt{bash} shell on a Unix system, you can
+process all files using these one-liners at the \verb|$| prompt:
+\begin{verbatim}
+ $ for f in in *.pl; do pltotf $f; done
+ $ for f in in *.vpl; do vptovf $f; done
+\end{verbatim}%$
+(This assumes that \pltotf and \vptovf can deduce the file names
+of the corresponding \tfm and \vf files automatically.)
+
+You should then:
+\begin{itemize}
+\item Move the \tfm files to your \TeX\ fonts directory\\
+ (e.g.~\url{TEXMFLOCAL/fonts/tfm/*}).
+\item Move the \vf files to your virtual fonts directory\\
+ (e.g.~\url{TEXMFLOCAL/fonts/vf/*}).
+\item Move the \fd files to your \TeX\ inputs directory\\
+ (e.g.~\url{TEXMFLOCAL/tex/latex/psfonts/*}).
+\end{itemize}
+If your \TeX\ installation is organized using the \TeX\ directory
+structure (TDS), it is customary to subdivide the \tfm and \vf
+files into subdirectories by supplier and typeface name.
+
+The \pl, \vpl, and \mtx files are debris that can now be deleted.
+\mtx files are font metric files \fontinst creates for its own use
+from \afm and \pl files. They're just more convenient for \TeX\
+to read than other forms -- think of them as \fontinst readable
+\afm and \pl files.
+
+By now, you have all the files in place to produce a \dvi file
+using the new fonts. You can make Adobe Times the default roman
+font in your document by putting this in your preamble:
+\begin{verbatim}
+ \renewcommand{\rmdefault}{ptm}
+\end{verbatim}
+
+\TeX\ will now happily produce a perfectly good \dvi file
+including the new font, which your DVI driver will choke on
+because you've not yet told it about the new fonts. Exactly how
+you do this depends on the dvi driver, but they all need the same
+information: the name of a \TeX\ font; the printer font name it
+corresponds to; some information to handle an re-encoding needed;
+and (in the case of a \PS driver) perhaps an instruction to
+download the font to the printer. You don't need to download the
+Times font to a \PS printer, because Times is built in to every
+\PS printer.
+
+If you use \dvips, these lines added to your \texttt{psfonts.map}
+file will do the job:
+\begin{verbatim}
+ ptmr8r Times-Roman "TeXBase1Encoding ReEncodeFont" <<8r.enc
+ ptmri8r Times-Italic "TeXBase1Encoding ReEncodeFont" <<8r.enc
+ ptmb8r Times-Bold "TeXBase1Encoding ReEncodeFont" <<8r.enc
+ ptmbi8r Times-BoldItalic "TeXBase1Encoding ReEncodeFont" <<8r.enc
+ ptmro8r Times-Roman "0.167 SlantFont TeXBase1Encoding ReEncodeFont" <<8r.enc
+ ptmbo8r Times-Bold "0.167 SlantFont TeXBase1Encoding ReEncodeFont" <<8r.enc
+\end{verbatim}
+And now you can print a \dvi file containing the new fonts. If
+you really do want to use the `raw' |8a| encoded fonts for some
+reason, you need to add these lines to your \texttt{psfonts.map}
+file:
+\begin{verbatim}
+ ptmr8a Times-Roman
+ ptmri8a Times-Italic
+ ptmb8a Times-Bold
+ ptmbi8a Times-BoldItalic
+ ptmro8a Times-Roman "0.167 SlantFont"
+ ptmbo8a Times-Bold "0.167 SlantFont"
+\end{verbatim}
+
+Assuming that you're using the \fd file that \fontinst has
+produced, and that you've asked for the Adobe Times family (|ptm|)
+in medium series (|m|) and upright shape (|n| for normal) using
+the NFSS font selection commands:
+\begin{verbatim}
+ \renewcommand{\rmdefault}{ptm}
+ \rmfamily \mdseries \upshape
+\end{verbatim}
+Assuming further that you are using the \fd file \texttt{t1ptm.fd}
+produced by \fontinst, the \TeX\ font (\tfm file) \texttt{ptmr8t.tfm}
+will be selected by the above commands, as you can see from the
+relevant line in \texttt{t1ptm.fd}:
+\begin{verbatim}
+ \DeclareFontShape{T1}{ptm}{m}{n}{<<->> ptmr8t}{}
+\end{verbatim}
+
+This is what happens:
+\begin{itemize}
+\item \TeX\ typesets your document using the font metric file
+ \texttt{ptmr8t.tfm}; this is the font that is put in the \dvi
+ file.
+\item \Dvips looks at the \dvi file, and sees a reference to the
+ font \texttt{ptmr8t}.
+\item \Dvips searches for a \vf file corresponding to
+ \texttt{ptmr8t}; when it finds \texttt{ptmr8t.vf}, it knows it
+ has a virtual font on its hands.
+ %\footnote{This is a slight lie--why?}
+\item \Dvips follows the instructions in the \vf file, which map
+ characters in \texttt{ptmr8t.tfm} to characters in the font
+ \texttt{ptmr8r.tfm}. That is, when it sees a number~25 in the
+ \dvi file (dotless~i -- `\i' -- in T1 encoding), it replaces it
+ with a number~17, which is a dotless~i in |8r| encoding.
+\item Then \dvips looks up the name of each number according to
+ the scheme given in the file \texttt{8r.enc}, and replaces each
+ number with the name of the character, in this case, number~17
+ is listed as `dotlessi'.
+\item And finally, \dvips tells the printer to print the named
+ character.
+\end{itemize}
+
+Not all DVI drivers can manage re-encoding as well as \dvips can.
+For example, \OzTeX's built-in non-\PS \dvi driver can only work
+with numbers, so if I'm using a \PS font, I can't print characters
+(such as Eth) that don't have a number in Macintosh text encoding
+unless I use \dvips and print on a \PS printer. \Dvips works with
+character names, so it's not subject to this restriction. In the
+example above, \OzTeX\ would replace the number~17 for `dotlessi'
+in |8r| encoding with a number~245 for `dotlessi' in Macintosh
+text encoding.
+
+The details of the \LaTeXe{} font selection scheme are described
+in \emph{\LaTeXe{} font selection} (distributed with \LaTeXe\ as
+the file \texttt{fntguide.tex}) and \emph{The \LaTeX\ Companion}
+(Goossens, Mittelbach and Samarin, Addison-Wesley).
+%You might also find useful the file \url{info/simple-nfss.tex}
+%available at your nearest comprehensive \TeX\ archive network
+%(CTAN) FTP server.
+
+The files you need to use Times, Helvetica, Courier, and the rest
+of the `standard' \PS fonts are distributed as part of the
+\setpackagename{PSNFSS} bundle available from CTAN, so there's no
+need to create new files to use these fonts.
+
+A more involved example of \fontinst use can be seen in the file
+\texttt{fontptcm.tex} which creates the files you need to use a
+combination of Times, Symbol, Zapf Chancery and Computer Modern as
+\TeX\ math fonts.
+
+
+\section{Installing your own font family}
+
+The \fontinst package has a command \verb|\latinfamily| meant to
+do most of the work to install a `normal' set (family) of roman
+text fonts from Adobe. Assuming you have a set of \afm files to
+match the fonts you wish to use, the first step is to rename the
+\afm files according to the \Fontnamekb naming scheme.
+
+A `normal' set of text fonts usually includes the basic upright
+roman version, bold, italic, and bold italic. Sometimes there
+will also be small caps versions, perhaps some `expert' fonts, and
+maybe some other weights such as light, medium, semi bold, black
+or ultra bold.
+
+The most important point to note is this: no matter what sort of
+computer you're using and no matter what font encoding it uses
+normally, \afm files for text fonts are almost always in |8a|
+encoding (Adobe standard encoding), so the \afm files when renamed
+normally end in |8a|.
+
+A typical set of four \afm files re-named for use with \fontinst
+is this:
+\begin{verbatim}
+ ptmr8r.afm Times-Roman
+ ptmri8r.afm Times-Italic
+ ptmb8r.afm Times-Bold
+ ptmbi8r.afm Times-BoldItalic
+\end{verbatim}
+Not all \afm files use |8a| encoding. If you open an \afm file
+using a text editor, you'll see a line looking like this somewhere
+near the top:
+\begin{verbatim}
+ EncodingScheme AdobeStandardEncoding
+\end{verbatim}
+and if you see exactly that, the \afm file should end with |8a|.
+If you see something like this:
+\begin{verbatim}
+ EncodingScheme FontSpecific
+\end{verbatim}
+have a look at the name of the font in the \afm file. If you see
+something like this:
+\begin{verbatim}
+ FontName AGaramondExp-Regular
+ FullName Adobe Garamond Regular Expert
+\end{verbatim}
+you have an `expert' encoded font on your hands, and the \afm file
+should end with |8x| to indicate this to \fontinst. An |8x|
+encoded font contains extra glyphs like old style numerals, small
+capital letters, more ligatures, and so on.
+
+%% UV: taken out -- repeated below
+%%
+%If you have an expert font, you can tell \fontinst to use it when
+%it's processing a \verb|\latinfamily| command by putting an `|x|'
+%on the end of the family name:
+%\begin{verbatim}
+% \latinfamily{padx}{}
+%\end{verbatim}
+%If you want to tell \fontinst to use expert fonts to install fonts
+%with old style numerals, you can do so by putting an `|j|' on the
+%end of the family name:
+%\begin{verbatim}
+% \latinfamily{padj}{}
+%\end{verbatim}
+
+The |\latinfamily| command is used like this:
+\begin{decl}
+ |\latinfamily|\arg{family}\arg{commands}
+\end{decl}
+This installs a Latin family of fonts.
+
+For example, to install Adobe Times, you say:
+\begin{verbatim}
+ \latinfamily{ptm}{}
+\end{verbatim}
+The \textit{commands} issued by \LaTeX\ each time a font from that
+family is loaded. This is most often used with typewriter fonts,
+to switch off hyphenation. For example, Adobe Courier can be
+installed with:
+\begin{verbatim}
+ \latinfamily{pcr}{\hyphenchar\font=-1}
+\end{verbatim}
+Once the installation is over (which may take some time) the fonts
+can be used in \LaTeX\ by selecting an appropriate
+\verb|\fontfamily|, for example Adobe Times can be selected with:
+\begin{verbatim}
+ \fontfamily{ptm}\selectfont
+\end{verbatim}
+If the fourth letter of the family name is `|x|' then \fontinst
+will use expert fonts in creating the fonts. If the fourth letter
+is `|j|' (or for backward compatibility `|9|') then \fontinst will
+use expert fonts to create fonts with old style digits.
+
+For example, to install Adobe Garamond using expert fonts, you say:
+\begin{verbatim}
+ \latinfamily{padx}{}
+\end{verbatim}
+To install Adobe Garamond using expert fonts with oldstyle digits,
+you say:
+\begin{verbatim}
+ \latinfamily{padj}{}
+\end{verbatim}
+
+When you have expert fonts, and you've told \fontinst to use
+them, it will carry on as normal, but the resulting font family
+will have the name `|padx|' or `|padj|', and it will use expert
+glyphs whenever possible, so you'll have a real (rather than
+faked) small caps font, real (rather than faked) `ffl' ligatures,
+and so on.
+
+Before using these commands, you will need to make sure that you
+have the Adobe Font Metric (\afm) files for the fonts, and that
+they have appropriate names. The \fontinst package uses the
+\LaTeX\ convention for naming fonts, and uses a \emph{font family}
+name which consists of:
+\begin{itemize}
+\item a \emph{supplier} (or foundry), such as `|p|' for Adobe.
+\item a \emph{typeface}, such as `|ad|' for Adobe Garamond.
+\item up to two \emph{variants}, such as `|j|' or `|x|' for `old
+ style digits' or `expert'.
+\end{itemize}
+So the family name `|padj|' indicates Adobe Garamond with old
+style digits. Note that the variants `|j|' or `|x|' are
+interpreted by \fontinst itself and do not appear in external font
+names, whereas other variants are passed through as part of the
+font names. (This is needed for families which have a sans serif
+or typewriter variant.)
+
+The \emph{supplier} must be one letter, and the \emph{typeface}
+must be two (this is an attempt to fit all filenames into MS-DOS
+format). Each variant is one letter. The full list of foundries,
+typefaces, shapes and variants is given in Karl Berry's
+`\emph{Filenames for fonts}' (available by anonymous FTP from
+\url{ftp://ftp.tex.ac.uk/tex-archive/info/fontname}), but the more
+common ones are given in
+Tables~\ref{Tab:foundry}--\ref{Tab:typeface}.
+
+\begin{table}[!t]
+\begin{minipage}{0.5\textwidth}
+ \small
+ \begin{tabular}{ll}
+ |b| & Bitstream \\
+ |f| & `free' (public domain) \\
+ |h| & Bigelow \& Holmes \\
+ |i| & ITC \\
+ |l| & Linotype \\
+ |m| & Monotype \\
+ |p| & Adobe (|p| for \PS) \\
+ |r| & `raw' (obsolete) \\
+ |u| & URW \\
+ |z| & bizarre
+ \end{tabular}
+ \caption{A partial list of foundries}
+ \label{Tab:foundry}
+ \begin{tabular}{ll}
+ |a| & alternate \\
+ |d| & display, titling \\
+ |f| & fraktur, handtooled \\
+ |j| & oldstyle digits \\
+ |n| & informal, casual \\
+ |p| & ornaments \\
+ |s| & sans serif \\
+ |t| & typewriter \\
+ |w| & script, handwriting, swash \\
+ |x| & expert \\
+ \end{tabular}
+ \caption{A partial list of variants}
+ \label{Tab:variant}
+ \begin{tabular}{ll}
+ |c| & small caps \\
+ |i| & italic \\
+ |o| & oblique (i.e.,~slanted) \\
+ |u| & unslanted italic \\
+ \end{tabular}
+ \caption{A partial list of shapes}
+ \label{Tab:shape}
+\end{minipage}
+\begin{minipage}{0.5\textwidth}
+ \small
+ \begin{tabular}{ll}
+ |ac| & Adobe Caslon \\
+ |ad| & Adobe Garamond \\
+ |ag| & Avantgarde \\
+ |bb| & Bembo \\
+ |bd| & Bodoni \\
+ |bk| & Bookman \\
+ |bv| & Baskerville \\
+ |ca| & Caslon \\
+ |ch| & Charter \\
+ |cr| & Courier \\
+ |fr| & Frutiger \\
+ |fu| & Futura \\
+ |gl| & Galliard \\
+ |gm| & Garamond \\
+ |gs| & Gill Sans \\
+ |hv| & Helvetica \\
+ |mn| & Minion \\
+ |lc| & Lucida \\
+ |lh| & Lucida Bright \\
+ |ls| & Lucida Sans \\
+ |nb| & New Baskerville \\
+ |nc| & New Century Schoolbook \\
+ |op| & Optima \\
+ |pl| & Palatino \\
+ |sy| & Symbol \\
+ |tm| & Times \\
+ |ut| & Utopia \\
+ |zc| & Zapf Chancery \\
+ |zd| & Zapf Dingbats \\
+ \end{tabular}
+ \caption{A partial list of faces}
+ \label{Tab:typeface}
+\end{minipage}
+\end{table}
+
+The \fontinst package uses Karl Berry's naming scheme for \afm
+files. The full naming scheme is rather more flexible than the
+subset used by \fontinst, which uses filenames consisting of:
+\begin{itemize}
+\item a \emph{supplier}, such as `|p|' for Adobe.
+\item a \emph{typeface}, such as `|hv|' for Helvetica.
+\item a \emph{weight}, such as `|r|' for regular.
+\item up to two \emph{shapes} or \emph{variants}, such as `|o|'
+ for oblique.
+\item an \emph{encoding}, such as `|7t|' for Knuth's 7-bit \TeX{}
+ encoding.
+\item an optional \emph{width}, such as `|n|' for narrow.
+\item a \emph{file extension}, such as `\texttt{.tfm}'
+ for \TeX{} Font Metric.
+\end{itemize}
+So the filename name `\texttt{phvro7tn.tfm}' indicates Adobe
+Helvetica regular oblique narrow, in the 7-bit \TeX{} encoding.
+
+The full list of shapes, encodings and weights is given in Karl
+Berry's `\emph{Filenames for fonts}', but the more common ones are
+given in Tables~\ref{Tab:shape}--\ref{Tab:weight}.
+
+\begin{table}
+\begin{minipage}{0.5\textwidth}
+ \small
+ \begin{tabular}{ll}
+ |b| & bold \\
+ |c| & black \\
+ |d| & demibold \\
+ |h| & heavy \\
+ |k| & book \\
+ |l| & light \\
+ |m| & medium \\
+ |r| & regular \\
+ |s| & semibold \\
+ |u| & ultra bold \\
+ |x| & extra bold \\
+ \end{tabular}
+ \caption{A partial list of weights}
+ \label{Tab:weight}
+ \begin{tabular}{ll}
+ |c| & condensed \\
+ |n| & narrow \\
+ |w| & wide \\
+ |x| & extended \\
+ \end{tabular}
+ \caption{A partial list of widths}
+ \label{Tab:width}
+\end{minipage}
+\begin{minipage}{0.5\textwidth}
+ \small
+ \begin{tabular}{ll}
+ |8a| & Adobe Standard \\
+ |8x| & Adobe Expert \\
+ |8r| & \TeX{} 8-bit `raw' (\texttt{TeXBase1}) \\
+ |8y| & \TeX{} 8-bit `raw' (\texttt{TeXnANSI}) \\
+ |7t| & \TeX{} 7-bit text (\texttt{OT1}) \\
+ |7m| & \TeX{} 7-bit math italic (\texttt{OML}) \\
+ |7y| & \TeX{} 7-bit math symbol (\texttt{OMS}) \\
+ |7v| & \TeX{} 7-bit math extension (\texttt{OMX}) \\
+ |8t| & \TeX{} 8-bit text (\texttt{T1}) \\
+ |8c| & \TeX{} 8-bit text symbols (\texttt{TS1}) \\
+ |9t| & \TeX{} 7-bit text with expert glyphs \\
+ |9o| & \TeX{} 7-bit text with expert glyphs \\
+ & and old-style digits \\
+ |9e| & \TeX{} 8-bit text with expert glyphs \\
+ |9d| & \TeX{} 8-bit text with expert glyphs \\
+ & and old-style digits \\
+ |9c| & \TeX{} 8-bit symbols with expert glyphs \\
+ & and old-style digits \\
+ \end{tabular}
+ \caption{A partial list of encodings}
+\end{minipage}
+\end{table}
+
+For example, to install Adobe Garamond including the expert fonts, you
+would need to rename the \afm files:
+\begin{center}
+\begin{small}
+\begin{tabular}{lll}
+ \emph{Adobe name} & \emph{ATM name} & \emph{Fontinst name} \\
+ |AGaramond-Bold.afm| & |gdb_____.afm| & |padb8a.afm| \\
+ |AGaramond-BoldItalic.afm| & |gdbi____.afm| & |padbi8a.afm| \\
+ |AGaramond-Italic.afm| & |gdi_____.afm| & |padri8a.afm| \\
+ |AGaramond-Regular.afm| & |gdrg____.afm| & |padr8a.afm| \\
+ |AGaramond-Semibold.afm| & |gdsb____.afm| & |pads8a.afm| \\
+ |AGaramond-SemiboldItalic.afm| & |gdsbi___.afm| & |padsi8a.afm| \\
+ |AGaramondExp-Bold.afm| & |geb_____.afm| & |padb8x.afm| \\
+ |AGaramondExp-BoldItalic.afm| & |gebi____.afm| & |padbi8x.afm| \\
+ |AGaramondExp-Italic.afm| & |gei_____.afm| & |padri8x.afm| \\
+ |AGaramondExp-Regular.afm| & |gerg____.afm| & |padr8x.afm| \\
+ |AGaramondExp-Semibold.afm| & |gesb____.afm| & |pads8x.afm| \\
+ |AGaramondExp-SemiboldItalic.afm| & |gesbi___.afm| & |padsi8x.afm| \\
+ |AGaramond-RegularSC.afm| & |gdsc____.afm| & |padrc8a.afm| \\
+ |AGaramond-SemiboldSC.afm| & |gdsbs___.afm| & |padsc8a.afm| \\
+\end{tabular}
+\end{small}
+\end{center}
+You can then run \TeX{} on the following document to install the
+Adobe Garamond family:
+\begin{verbatim}
+ \input fontinst.sty
+ \latinfamily{padx}{}
+ \latinfamily{padj}{}
+ \bye
+\end{verbatim}
+Not all font families can be installed using the \verb|\latinfamily|
+command, nor does it always produce optimal results. The main
+interfaces to \fontinst are at a slightly lower level, where all font
+names appear explicitly in command arguments, and at that level it is
+possible to fine tune the font generation. The \verb|\latinfamily|
+command is mainly a clever collection of macros which expand to a
+mostly fixed\footnote{Commands that would refer to files which are
+not present are skipped, and in some cases there is a ``Plan B''
+when ``Plan A'' would have made use of such a nonexistent file, but
+that is about it.} sequence of lower level \fontinst commands.
+
+\begin{bfseries}
+ Descriptions of the sub-\verb|\latinfamily| commands can be found
+ in the main \fontinst manual.
+\end{bfseries}
+
+
+
+\section{More on the \cs{latinfamily} command}
+
+The \verb|\latinfamily| command is essentially a short-cut to save you
+preparing a huge file with many different \fontinst commands in it.
+
+It takes \afm or \mtx files as the source of font metric data to work
+with. Usually, you have a set of \afm files. They must be named
+according to a subset of the \Fontnamekb naming scheme. To illustrate
+the process, here is an edited part of the console log from a use of
+\verb|\latinfamily|:
+\begin{verbatim}
+ \latinfamily{pad}{}
+\end{verbatim}
+This log does not show \fontinst `in action'; it's just to illustrate
+which fonts are looked for when you use the \verb|\latinfamily|
+command.
+\begin{verbatim}
+ INFO>> to make LaTeX font shape <<pad,m,n,>> seek padr8r.mtx
+ INFO>> to make LaTeX font shape <<pad,m,sc,>> seek padrc8r.mtx
+ INFO>> to make LaTeX font shape <<pad,m,sl,>> seek padro8r.mtx
+ INFO>> to make LaTeX font shape <<pad,m,it,>> seek padri8r.mtx
+ INFO>> to make LaTeX font shape <<pad,m,n,c>> seek padr8rn.mtx
+ INFO>> to make LaTeX font shape <<pad,m,sc,c>> seek padrc8rn.mtx
+ INFO>> to make LaTeX font shape <<pad,m,sl,c>> seek padro8rn.mtx
+ INFO>> to make LaTeX font shape <<pad,m,it,c>> seek padri8rn.mtx
+\end{verbatim}
+
+The important point to notice is that \fontinst needs an |8r| encoded
+\mtx file for each font when you are using the \verb|latinfamily|
+command. If it can't find an |8r| encoded \mtx file, it'll look for
+for an |8a| encoded \afm file. It will automatically turn the file it
+finds into an |8r| encoded \mtx file. So when \fontinst says
+`\verb|seek padr8r.mtx|', it is in fact looking for
+\texttt{padr8r.mtx} and \texttt{padr8a.afm}. Whatever it finds, it
+will end up with \verb|padr8r.mtx| to work on.
+
+The first line of the log shows that \fontinst is trying to create a
+\vpl file for |pad/m/n|. That is, font family |pad| (Adobe Garamond),
+font series |m| (normal `book' or `regular' weight), and font shape
+|n| (normal upright).
+
+If it finds what it's looking for, it will create the files:
+\begin{verbatim}
+ padr7t.vpl
+ padr8t.vpl
+ padr8c.vpl
+\end{verbatim}
+And add these lines to the given \fd files:
+\begin{verbatim}
+ OT1pad.fd: \DeclareFontShape{OT1}{pad}{m}{n}{<<->> padr7t}{}
+ T1pad.fd: \DeclareFontShape{T1} {pad}{m}{n}{<<->> padr8t}{}
+ TS1pad.fd: \DeclareFontShape{TS1}{pad}{m}{n}{<<->> padr8c}{}
+\end{verbatim}
+This means you will have three new fonts to use in \LaTeX: the OT1, T1
+and TS1 encoded versions of |pad/m/n|. You'll be able to select (say)
+|T1/pad/m/n| by saying:
+\begin{verbatim}
+ \fontencoding{T1}\fontfamily{pad}\fontseries{m}\fontshape{n}\selectfont
+\end{verbatim}
+This is the clumsiest way of selecting that particular font, but I've
+done it to illustrate exactly what's happening.
+
+The next line:
+\begin{verbatim}
+ INFO>> to make LaTeX font shape <<pad,m,sc,>> seek padrc8r.mtx
+\end{verbatim}
+shows that \fontinst is trying to install a small caps font. If you
+have a real small caps metric file named \texttt{padrc8r.mtx} (don't
+forget it'll look for an |8a| encoded \afm file), \fontinst will go
+ahead and create the \vpl file and \fd file entry as expected.
+
+But you don't normally have a real small caps font, so \fontinst will
+quite happily produce a fake small caps font. To do this, it looks
+for a suitable metric file by dropping the `|c|':
+\begin{quote}
+ `Hmm\ldots\ I can't find \texttt{padrc8r}, so I'll look for
+ \texttt{padr8r}.'
+\end{quote}
+And you will eventually have:
+\begin{verbatim}
+ padrc7t.vpl
+ padrc8t.vpl
+\end{verbatim}
+And add these lines to the given \fd files:
+\begin{verbatim}
+ OT1pad.fd: \DeclareFontShape{OT1}{pad}{m}{sc}{<<->> padrc7t}{}
+ T1pad.fd: \DeclareFontShape{T1} {pad}{m}{sc}{<<->> padrc8t}{}
+\end{verbatim}
+(Note that it won't install a TS1-encoded small caps font because
+TS1 is a text symbol font, which would look the same in the upright
+and small caps shape.)
+
+The next log line shows \fontinst trying to create a \vpl for the
+oblique version of Adobe Garamond:
+\begin{verbatim}
+ INFO>> to make LaTeX font shape <<pad,m,sl,>> seek padro8r.mtx
+\end{verbatim}
+It's quite usual for an oblique version to be unavailable, but
+\fontinst has a way round this: it can fake an oblique font from the
+corresponding `straight' version:
+\begin{quote}
+ `Oh dear: I can't find \texttt{padro8r}, so I'll look for
+ \texttt{padr8r} and use clever maths to fake a slanted version.'
+\end{quote}
+This is not as straightforward as the small caps case. \Fontinst
+only works out what the metrics ought to be if the entire font is
+slanted to the right. It's up to the DVI driver to actually print a
+slanted font. \Dvips can do this.
+
+You will eventually have:
+\begin{verbatim}
+ padro7t.vpl
+ padro8t.vpl
+ padro8c.vpl
+\end{verbatim}
+And these lines added to the given \fd files:
+\begin{verbatim}
+ OT1pad.fd: \DeclareFontShape{OT1}{pad}{m}{sl}{<<->> padro7t}{}
+ T1pad.fd: \DeclareFontShape{T1} {pad}{m}{sl}{<<->> padro8t}{}
+ TS1pad.fd: \DeclareFontShape{TS1}{pad}{m}{sl}{<<->> padro8c}{}
+\end{verbatim}
+
+The next line is straightforward:
+\begin{verbatim}
+ INFO>> to make LaTeX font shape <<pad,m,it,>> seek padri8r.mtx
+\end{verbatim}
+If \fontinst can't find a suitable metrics file (\texttt{padri8r.mtx}
+or \texttt{padri8a.afm}), it carries on without doing anything. If it
+does find a suitable metrics file, it churns away until you will
+eventually have:
+\begin{verbatim}
+ padri7t.vpl
+ padri8t.vpl
+ padri8c.vpl
+\end{verbatim}
+And these lines added to the given \fd files:
+\begin{verbatim}
+ OT1pad.fd: \DeclareFontShape{OT1}{pad}{m}{it}{<<->> padri7t}{}
+ T1pad.fd: \DeclareFontShape{T1} {pad}{m}{it}{<<->> padri8t}{}
+ TS1pad.fd: \DeclareFontShape{TS1}{pad}{m}{it}{<<->> padri8c}{}
+\end{verbatim}
+
+The next line is a bit different. \Fontinst is now trying to create a
+\vpl file for a \emph{condensed} font:
+\begin{verbatim}
+ INFO>> to make LaTeX font shape <<pad,m,n,c>> seek padr8rn.mtx
+\end{verbatim}
+If it finds a suitable metric file (Adobe Garamond, medium weight,
+normal upright shape, condensed), it will eventually produce:
+\begin{verbatim}
+ padr7tn.vpl
+ padr8tn.vpl
+ padr8cn.vpl
+\end{verbatim}
+And these lines added to the given \fd files:
+\begin{verbatim}
+ OT1pad.fd: \DeclareFontShape{OT1}{pad}{mc}{n}{<<->> padr7tn}{}
+ T1pad.fd: \DeclareFontShape{T1} {pad}{mc}{n}{<<->> padr8tn}{}
+ TS1pad.fd: \DeclareFontShape{TS1}{pad}{mc}{n}{<<->> padr8cn}{}
+\end{verbatim}
+There is no standard \LaTeX\ command like \verb|\bfseries| to select
+the medium condensed (|mc|) series created here. If you want to use
+this font, you must do something like:
+\begin{verbatim}
+ \fontfamily{pad}\fontseries{mc}\selectfont
+\end{verbatim}
+If it doesn't find a suitable metric file for a narrow series,
+\fontinst will just skip over and continue, unless you specifically
+tell it to fake a narrow series.
+
+And so the process continues: \fontinst attempts to create \vpl files
+for condensed versions of all the font shapes met so far, and then
+goes on to:
+\begin{verbatim}
+ INFO>> to make LaTeX font shape <<pad,b,n,>> seek padb8r.mtx
+\end{verbatim}
+And again, if it finds a suitable metric file (\texttt{padb8r.mtx} or
+\texttt{padb8a.afm}), it'll potter off and create the files:
+\begin{verbatim}
+ padb7t.vpl
+ padb8t.vpl
+ padb8c.vpl
+\end{verbatim}
+And these lines added to the given \fd files:
+\begin{verbatim}
+ OT1pad.fd: \DeclareFontShape{OT1}{pad}{b}{n}{<<->> padb7t}{}
+ T1pad.fd: \DeclareFontShape{T1} {pad}{b}{n}{<<->> padb8t}{}
+ TS1pad.fd: \DeclareFontShape{TS1}{pad}{b}{n}{<<->> padb8c}{}
+\end{verbatim}
+With this step done, fontinst will try to create \vpl files for the
+small caps, slanted, and italic versions of |pad/b|; and then it'll
+try to create condensed versions of all those:
+\begin{verbatim}
+ INFO>> to make LaTeX font shape <<pad,b,n,>> seek padb8r.mtx
+ INFO>> to make LaTeX font shape <<pad,b,sc,>> seek padbc8r.mtx
+ INFO>> to make LaTeX font shape <<pad,b,sl,>> seek padbo8r.mtx
+ INFO>> to make LaTeX font shape <<pad,b,it,>> seek padbi8r.mtx
+ INFO>> to make LaTeX font shape <<pad,b,n,c>> seek padb8rn.mtx
+ INFO>> to make LaTeX font shape <<pad,b,sc,c>> seek padbc8rn.mtx
+ INFO>> to make LaTeX font shape <<pad,b,sl,c>> seek padbo8rn.mtx
+ INFO>> to make LaTeX font shape <<pad,b,it,c>> seek padbi8rn.mtx
+\end{verbatim}
+If it manages to find the files it needs to create the \vpl files to
+use all those fonts with \LaTeX, you'll end up with the following
+lines in the T1 \fd file (I've ignored the OT1 \fd file to save some
+space):
+\begin{verbatim}
+ \DeclareFontShape{T1} {pad}{b} {n} {<<->> padb8t}{}
+ \DeclareFontShape{T1} {pad}{b} {sc}{<<->> padbc8t}{}
+ \DeclareFontShape{T1} {pad}{b} {sl}{<<->> padbo8t}{}
+ \DeclareFontShape{T1} {pad}{b} {it}{<<->> padbi8t}{}
+ \DeclareFontShape{T1} {pad}{bc}{n} {<<->> padb8tn}{}
+ \DeclareFontShape{T1} {pad}{bc}{sc}{<<->> padbc8tn}{}
+ \DeclareFontShape{T1} {pad}{bc}{sl}{<<->> padbo8tn}{}
+ \DeclareFontShape{T1} {pad}{bc}{it}{<<->> pckbi8tn}{}
+\end{verbatim}
+To translate into English: Adobe Garamond bold in `normal', small
+caps, slanted, and italic versions, as well as condensed versions of
+all four.
+
+Again, because there's no convenient way of selecting the condensed
+versions with existing \LaTeX\ commands, you need to say something
+like:
+\begin{verbatim}
+ \fontfamily{pad}\fontseries{bc}\selectfont
+\end{verbatim}
+to use the bold condensed (|bc|) versions of this font; you can of
+course use \verb|\itshape|, \verb|\scshape|, \verb|\slshape|, and
+\verb|upshape| to switch between the italic, small caps, slanted, and
+`normal' versions of Adobe Garamond bold condensed once you've got
+|pad/bc| selected.
+
+So far, you've seen \verb|\latinfamily| look at two different weights
+and two different widths. For each weight, \verb|\latinfamily| will
+try and install eight different fonts as you can see above. It will
+try and install the same eight different fonts for each of the
+following different weights:
+\begin{center}
+\begin{tabular}{lll}
+ \emph{\LaTeX} & \emph{Fontname} & \emph{description} \\
+ |ul| & |a| & ultra light \\
+ |el| & |i| & extra light \\
+ |l| & |l| & light \\
+ |m| & |k|, |r| & book, regular \\
+ |mb| & |m| & medium \\
+ |db| & |d| & demi bold \\
+ |sb| & |s| & semi bold \\
+ |b| & |b| & bold \\
+ |eb| & |c|, |h|, |x| & black, heavy, extra bold \\
+ |ub| & |u| & ultra bold
+\end{tabular}
+\end{center}
+The \LaTeX\ column contains the label that will be used in the
+\verb|\DeclareFontShape| command to specify the font series. The
+\Fontnamekb column contains the width specifier used to name the font
+metric file that \fontinst will look for in that case.
+
+In other words, at some stage \fontinst will look for:
+\begin{verbatim}
+ INFO>> to make LaTeX font shape <<pad,sb,n,>> seek pads8r.mtx
+\end{verbatim}
+and if it finds a suitable metric file (\texttt{pads8r.mtx} or
+\texttt{pads8a.afm}), it will create:
+\begin{verbatim}
+ pads7t.vpl
+ pads8t.vpl
+ pads8c.vpl
+\end{verbatim}
+and \fd file entries like this:
+\begin{verbatim}
+ OT1pad.fd: \DeclareFontShape{OT1}{pad}{sb}{n}{<<->> pads7t}{}
+ T1pad.fd: \DeclareFontShape{T1} {pad}{sb}{n}{<<->> pads8t}{}
+ TS1pad.fd: \DeclareFontShape{TS1}{pad}{sb}{n}{<<->> pads8c}{}
+\end{verbatim}
+and since |sb| is not a normal \LaTeX\ font series, you'll need to use
+something like:
+\begin{verbatim}
+ \fontfamily{pad}\fontseries{sb}\selectfont
+\end{verbatim}
+to use this font.
+
+% For example, \verb|\latinfamily{ptm}{}| is
+% syntactic sugar for:
+% \begin{verbatim}
+% \transformfont{ptmr8r}{\reencodefont{8r}{\fromafm{ptmr8a}}}
+% \transformfont{ptmri8r}{\reencodefont{8r}{\fromafm{ptmri8a}}}
+% \transformfont{ptmb8r}{\reencodefont{8r}{\fromafm{ptmb8a}}}
+% \transformfont{ptmbi8r}{\reencodefont{8r}{\fromafm{ptmbi8a}}}
+% \transformfont{ptmro8r}{\slantfont{167}{\frommtx{ptmr8r}}}
+% \transformfont{ptmbo8r}{\slantfont{167}{\frommtx{ptmb8r}}}
+% \installfonts
+% \installfamily{T1}{ptm}{}
+% \installfamily{OT1}{ptm}{}
+% \installfont{ptmr8t}{ptmr8r,latin}{T1}{T1}{ptm}{m}{n}{}
+% \installfont{ptmr7t}{ptmr8r,latin}{OT1}{OT1}{ptm}{m}{n}{}
+% \installfont{ptmrc8t}{ptmr8r,latin}{T1c}{T1}{ptm}{m}{sc}{}
+% \installfont{ptmrc7t}{ptmr8r,latin}{OT1c}{OT1}{ptm}{m}{sc}{}
+% \installfont{ptmri8t}{ptmri8r,latin}{T1}{T1}{ptm}{m}{it}{}
+% \installfont{ptmri7t}{ptmri8r,latin}{OT1i}{OT1}{ptm}{m}{it}{}
+% \installfont{ptmro8t}{ptmro8r,latin}{T1}{T1}{ptm}{m}{sl}{}
+% \installfont{ptmro7t}{ptmro8r,latin}{OT1}{OT1}{ptm}{m}{sl}{}
+% \installfont{ptmb8t}{ptmb8r,latin}{T1}{T1}{ptm}{b}{n}{}
+% \installfont{ptmb7t}{ptmb8r,latin}{OT1}{OT1}{ptm}{b}{n}{}
+% \installfont{ptmbc8t}{ptmb8r,latin}{T1c}{T1}{ptm}{b}{sc}{}
+% \installfont{ptmbc7t}{ptmb8r,latin}{OT1c}{OT1}{ptm}{b}{sc}{}
+% \installfont{ptmbi8t}{ptmbi8r,latin}{T1}{T1}{ptm}{b}{it}{}
+% \installfont{ptmbi7t}{ptmbi8r,latin}{OT1i}{OT1}{ptm}{b}{it}{}
+% \installfont{ptmbo8t}{ptmbo8r,latin}{T1}{T1}{ptm}{b}{sl}{}
+% \installfont{ptmbo7t}{ptmbo8r,latin}{OT1}{OT1}{ptm}{b}{sl}{}
+% \endinstallfonts
+% \end{verbatim}
+
+
+The \texttt{basicex.tex} file in the \texttt{examples} directory of
+the main \fontinst distribution is an annotated command file which
+does roughly the same things as the \verb|\latinfamily| command for
+the \texttt{pad} family of fonts.
+
+
+\end{document}
diff --git a/fonts/utilities/fontinst/doc/manual/roadmap.eps b/fonts/utilities/fontinst/doc/manual/roadmap.eps
new file mode 100644
index 0000000000..8ca14df79d
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/manual/roadmap.eps
@@ -0,0 +1,265 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: roadmap.fig
+%%Creator: fig2dev Version 3.1 Patchlevel 1
+%%CreationDate: Sat Sep 16 18:24:06 1995
+%%For: alanje@rsuna.crn.cogs.susx.ac.uk (Alan Jeffrey, Research Fellow)
+%%Orientation: Portrait
+%%BoundingBox: 0 0 298 312
+%%Pages: 0
+%%BeginSetup
+%%IncludeFeature: *PageSize A4
+%%EndSetup
+%%EndComments
+/$F2psDict 200 dict def
+$F2psDict begin
+$F2psDict /mtrx matrix put
+/col-1 {} def
+/col0 {0.000 0.000 0.000 srgb} bind def
+/col1 {0.000 0.000 1.000 srgb} bind def
+/col2 {0.000 1.000 0.000 srgb} bind def
+/col3 {0.000 1.000 1.000 srgb} bind def
+/col4 {1.000 0.000 0.000 srgb} bind def
+/col5 {1.000 0.000 1.000 srgb} bind def
+/col6 {1.000 1.000 0.000 srgb} bind def
+/col7 {1.000 1.000 1.000 srgb} bind def
+/col8 {0.000 0.000 0.560 srgb} bind def
+/col9 {0.000 0.000 0.690 srgb} bind def
+/col10 {0.000 0.000 0.820 srgb} bind def
+/col11 {0.530 0.810 1.000 srgb} bind def
+/col12 {0.000 0.560 0.000 srgb} bind def
+/col13 {0.000 0.690 0.000 srgb} bind def
+/col14 {0.000 0.820 0.000 srgb} bind def
+/col15 {0.000 0.560 0.560 srgb} bind def
+/col16 {0.000 0.690 0.690 srgb} bind def
+/col17 {0.000 0.820 0.820 srgb} bind def
+/col18 {0.560 0.000 0.000 srgb} bind def
+/col19 {0.690 0.000 0.000 srgb} bind def
+/col20 {0.820 0.000 0.000 srgb} bind def
+/col21 {0.560 0.000 0.560 srgb} bind def
+/col22 {0.690 0.000 0.690 srgb} bind def
+/col23 {0.820 0.000 0.820 srgb} bind def
+/col24 {0.500 0.190 0.000 srgb} bind def
+/col25 {0.630 0.250 0.000 srgb} bind def
+/col26 {0.750 0.380 0.000 srgb} bind def
+/col27 {1.000 0.500 0.500 srgb} bind def
+/col28 {1.000 0.630 0.630 srgb} bind def
+/col29 {1.000 0.750 0.750 srgb} bind def
+/col30 {1.000 0.880 0.880 srgb} bind def
+/col31 {1.000 0.840 0.000 srgb} bind def
+
+end
+save
+-112.0 334.0 translate
+1 -1 scale
+
+/clp {closepath} bind def
+/ef {eofill} bind def
+/gr {grestore} bind def
+/gs {gsave} bind def
+/l {lineto} bind def
+/m {moveto} bind def
+/n {newpath} bind def
+/s {stroke} bind def
+/slc {setlinecap} bind def
+/slj {setlinejoin} bind def
+/slw {setlinewidth} bind def
+/srgb {setrgbcolor} bind def
+/rot {rotate} bind def
+/sc {scale} bind def
+/tr {translate} bind def
+/tnt {dup dup currentrgbcolor
+ 4 -2 roll dup 1 exch sub 3 -1 roll mul add
+ 4 -2 roll dup 1 exch sub 3 -1 roll mul add
+ 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}
+ bind def
+/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul
+ 4 -2 roll mul srgb} bind def
+ /DrawEllipse {
+ /endangle exch def
+ /startangle exch def
+ /yrad exch def
+ /xrad exch def
+ /y exch def
+ /x exch def
+ /savematrix mtrx currentmatrix def
+ x y tr xrad yrad sc 0 0 1 startangle endangle arc
+ closepath
+ savematrix setmatrix
+ } def
+
+/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def
+/$F2psEnd {$F2psEnteredState restore end} def
+%%EndProlog
+
+$F2psBegin
+10 setmiterlimit
+ 0.06000 0.06000 sc
+7.500 slw
+% Arc
+n 4813.51 1452.05 m 4800.00 1575.00 l 4754.06 1460.15 l gs col-1 s gr
+n 4284.38 1645.31 520.40 -91.03 -7.77 arc
+gs col-1 s gr
+
+% Arc
+n 3045.94 1460.15 m 3000.00 1575.00 l 2986.49 1452.05 l gs col-1 s gr
+n 3515.62 1645.31 520.40 -88.97 -172.23 arcn
+gs col-1 s gr
+
+% Arc
+n 2771.84 3251.35 m 2775.00 3375.00 l 2714.02 3267.38 l gs col-1 s gr
+n 2279.17 3512.50 514.55 -84.89 -15.50 arc
+gs col-1 s gr
+
+% Arc
+n 3285.98 3267.38 m 3225.00 3375.00 l 3228.16 3251.35 l gs col-1 s gr
+n 3720.83 3512.50 514.55 -95.11 -164.50 arcn
+gs col-1 s gr
+
+% Arc
+n 4247.24 2906.08 m 4125.00 2925.00 l 4223.95 2850.78 l gs col-1 s gr
+n 3525.00 1500.00 1546.16 39.09 67.17 arc
+gs col-1 s gr
+
+% Arc
+n 3403.37 4702.50 m 3525.00 4725.00 l 3407.09 4762.39 l gs col-1 s gr
+n 3493.27 4214.42 511.56 164.63 86.44 arcn
+gs col-1 s gr
+
+% Arc
+n 4394.64 4681.42 m 4275.00 4650.00 l 4395.35 4621.42 l gs col-1 s gr
+n 4291.72 3239.01 1411.09 -3.62 90.68 arc
+gs col-1 s gr
+
+% Arc
+n 4398.18 4811.29 m 4275.00 4800.00 l 4389.00 4752.00 l gs col-1 s gr
+n 3787.50 1650.00 3187.50 28.07 81.20 arc
+gs col-1 s gr
+
+% Arc
+n 4306.30 4511.76 m 4200.00 4575.00 l 4264.03 4469.17 l gs col-1 s gr
+n 2769.64 3133.93 2030.42 0.45 45.21 arc
+gs col-1 s gr
+
+% Ellipse
+n 3900 2962 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 3900 562 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 3900 1762 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 3000 1762 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 4800 1762 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 4800 2962 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 5700 2962 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 6600 2962 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 2100 2962 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 3000 4162 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Ellipse
+n 3900 5362 225 187 0 360 DrawEllipse gs col-1 s gr
+
+% Polyline
+n 3525 975 m 4275 975 l 4275 1275 l 3525 1275 l clp gs col-1 s gr
+% Polyline
+n 3525 2175 m 4275 2175 l 4275 2475 l 3525 2475 l clp gs col-1 s gr
+% Polyline
+n 4425 2175 m 5175 2175 l 5175 2475 l 4425 2475 l clp gs col-1 s gr
+% Polyline
+n 2625 3375 m 3375 3375 l 3375 3675 l 2625 3675 l clp gs col-1 s gr
+% Polyline
+n 3525 4575 m 4275 4575 l 4275 4875 l 3525 4875 l clp gs col-1 s gr
+% Polyline
+n 3900 750 m 3900 975 l gs col-1 s gr
+n 3930.00 855.00 m 3900.00 975.00 l 3870.00 855.00 l gs col-1 s gr
+% Polyline
+n 3900 1275 m 3900 1575 l gs col-1 s gr
+n 3930.00 1455.00 m 3900.00 1575.00 l 3870.00 1455.00 l gs col-1 s gr
+% Polyline
+n 3900 1950 m 3900 2175 l gs col-1 s gr
+n 3930.00 2055.00 m 3900.00 2175.00 l 3870.00 2055.00 l gs col-1 s gr
+% Polyline
+n 3900 2475 m 3900 2775 l gs col-1 s gr
+n 3930.00 2655.00 m 3900.00 2775.00 l 3870.00 2655.00 l gs col-1 s gr
+% Polyline
+n 4800 1950 m 4800 2175 l gs col-1 s gr
+n 4830.00 2055.00 m 4800.00 2175.00 l 4770.00 2055.00 l gs col-1 s gr
+% Polyline
+n 4800 2475 m 4800 2775 l gs col-1 s gr
+n 4830.00 2655.00 m 4800.00 2775.00 l 4770.00 2655.00 l gs col-1 s gr
+% Polyline
+n 3000 1950 m 3000 3375 l gs col-1 s gr
+n 3030.00 3255.00 m 3000.00 3375.00 l 2970.00 3255.00 l gs col-1 s gr
+% Polyline
+n 3000 3675 m 3000 3975 l gs col-1 s gr
+n 3030.00 3855.00 m 3000.00 3975.00 l 2970.00 3855.00 l gs col-1 s gr
+% Polyline
+n 3900 3150 m 3900 4575 l gs col-1 s gr
+n 3930.00 4455.00 m 3900.00 4575.00 l 3870.00 4455.00 l gs col-1 s gr
+% Polyline
+n 3900 4875 m 3900 5175 l gs col-1 s gr
+n 3930.00 5055.00 m 3900.00 5175.00 l 3870.00 5055.00 l gs col-1 s gr
+/Helvetica findfont 180.00 scalefont setfont
+3900 3000 m
+gs 1 -1 sc (tfm) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+3900 600 m
+gs 1 -1 sc (afm) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+3900 1800 m
+gs 1 -1 sc (pl) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+4800 1800 m
+gs 1 -1 sc (vpl) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+3000 1800 m
+gs 1 -1 sc (fd) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+4800 3000 m
+gs 1 -1 sc (vf) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+5700 3000 m
+gs 1 -1 sc (pfa) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+6600 3000 m
+gs 1 -1 sc (pfb) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+2100 3000 m
+gs 1 -1 sc (tex) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+3000 4200 m
+gs 1 -1 sc (dvi) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Helvetica findfont 180.00 scalefont setfont
+3900 5400 m
+gs 1 -1 sc (ps) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Palatino-Italic findfont 180.00 scalefont setfont
+3900 1175 m
+gs 1 -1 sc (fontinst) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Palatino-Italic findfont 180.00 scalefont setfont
+3900 2375 m
+gs 1 -1 sc (pltotf) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Palatino-Italic findfont 180.00 scalefont setfont
+4800 2375 m
+gs 1 -1 sc (vptovf) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Palatino-Italic findfont 180.00 scalefont setfont
+3000 3575 m
+gs 1 -1 sc (latex) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+/Palatino-Italic findfont 180.00 scalefont setfont
+3900 4775 m
+gs 1 -1 sc (dvips) dup stringwidth pop 2 div neg 0 rmoveto col-1 show gr
+$F2psEnd
+restore
diff --git a/fonts/utilities/fontinst/doc/talks/et99-font-tables.pdf b/fonts/utilities/fontinst/doc/talks/et99-font-tables.pdf
new file mode 100644
index 0000000000..8d6c2b593c
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/talks/et99-font-tables.pdf
Binary files differ
diff --git a/fonts/utilities/fontinst/doc/talks/et99-font-tutorial.pdf b/fonts/utilities/fontinst/doc/talks/et99-font-tutorial.pdf
new file mode 100644
index 0000000000..4ae8a1eeb7
--- /dev/null
+++ b/fonts/utilities/fontinst/doc/talks/et99-font-tutorial.pdf
Binary files differ
diff --git a/fonts/utilities/fontinst/examples/basic/basicex.tex b/fonts/utilities/fontinst/examples/basic/basicex.tex
new file mode 100644
index 0000000000..fe7f6f6993
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/basic/basicex.tex
@@ -0,0 +1,431 @@
+% basicex.tex
+%
+% This file contains some basic examples of commands for
+% installing the AGaramond family of fonts with fontinst v1.9.
+% It is pretty similar to what the \latinfamily command
+% does for these fonts, but the details are not identical.
+%
+% In case you want to run this file yourself, the metrics for
+% the AGaramond font family can be downloaded from
+%
+% ftp://ftp.adobe.com/pub/adobe/type/win/all/afmfiles/051-100/100/
+% and
+% ftp://ftp.adobe.com/pub/adobe/type/win/all/afmfiles/101-150/101/
+%
+% The AFM files found in these directories should then be renamed
+% as indicated in the Fontname adobe.map file. Also note that
+% the line endings are Windows-style (CRLF), so you probably need
+% to download as binary and do some conversion before you can use
+% these files comfortably.
+
+\input fontinst.sty
+
+% This tells fontinst to collect information about font
+% transformations in the file basicex.recs. That file is
+% then used by basicex2.tex.
+\recordtransforms{basicex.recs}
+
+% These commands perform transformations on the metrics of
+% some of the fonts, thereby creating new metrics files for
+% the transformed fonts.
+\transformfont{padr8r}{\reencodefont{8r}{\fromafm{padr8a}}}
+\transformfont{padrc8r}{\reencodefont{8r}{\fromafm{padrc8a}}}
+\transformfont{padri8r}{\reencodefont{8r}{\fromafm{padri8a}}}
+\transformfont{padro8r}{\slantfont{250}{\frommtx{padr8r}}}
+\transformfont{padro8x}{\slantfont{250}{\fromafm{padr8x}}}
+
+% The first three lines of each group reencode fonts
+% so that TeX can access all glyphs in them.
+\transformfont{pads8r}{\reencodefont{8r}{\fromafm{pads8a}}}
+\transformfont{padsc8r}{\reencodefont{8r}{\fromafm{padsc8a}}}
+\transformfont{padsi8r}{\reencodefont{8r}{\fromafm{padsi8a}}}
+% The last two lines artifically create slanted variants
+% of fonts by skewing them. 250 is the natural slant of
+% the italics in this family.
+\transformfont{padso8r}{\slantfont{250}{\frommtx{pads8r}}}
+\transformfont{padso8x}{\slantfont{250}{\fromafm{pads8x}}}
+
+\transformfont{padb8r}{\reencodefont{8r}{\fromafm{padb8a}}}
+% There is no padbc8a, hence nothing to make a padbc8r from.
+\transformfont{padbi8r}{\reencodefont{8r}{\fromafm{padbi8a}}}
+\transformfont{padbo8r}{\slantfont{250}{\frommtx{padb8r}}}
+\transformfont{padbo8x}{\slantfont{250}{\fromafm{padb8x}}}
+% The DVI driver must be told to make the same transformations
+% to the actual fonts when a document using them is to be viewed
+% or printed. The information collected in basicex.recs can
+% help with this. The job of basicex2.tex is to translate this
+% information to a format understood by DVI drivers.
+
+
+% The \transformfont commands above generate metric files in MTX
+% format (for use by the \installfont commands below) and PL
+% format (for transformation to TFMs that are needed by the DVI
+% driver when interpreting VFs based on these fonts). These PL
+% files are minimal and not suitable for direct use in typesetting
+% since there is no kerning information, ligaturing instructions,
+% or fontdimens, but they are perfectly adequate to serve as
+% base fonts for VFs.
+%
+% The next bunch of commands generate a new set of PL files for
+% these fonts (overwriting the previous), and these new files
+% do contain kerning information, ligaturing instructions, and
+% fontdimens. (As a side-effect, these files are also larger than
+% the previous ones.) Since 8r-encoded fonts are not in practice
+% used for typesetting (not much, anyway), it is perfectly
+% possible to skip this step.
+\installfonts
+ \installrawfont {padr8r}{padr8r,8r}{8r} {8r}{pad}{m}{n}{}
+ \installrawfont {padrc8r}{padrc8r,8r}{8r} {8r}{pad}{m}{sc}{}
+ \installrawfont {padri8r}{padri8r,8r}{8r} {8r}{pad}{m}{it}{}
+ \installrawfont {padro8r}{padro8r,8r}{8r} {8r}{pad}{m}{sl}{}
+
+ \installrawfont {pads8r}{pads8r,8r}{8r} {8r}{pad}{sb}{n}{}
+ \installrawfont {padsc8r}{padsc8r,8r}{8r} {8r}{pad}{sb}{sc}{}
+ \installrawfont {padsi8r}{padsi8r,8r}{8r} {8r}{pad}{sb}{it}{}
+ \installrawfont {padso8r}{padso8r,8r}{8r} {8r}{pad}{sb}{sl}{}
+
+ \installrawfont {padb8r}{padb8r,8r}{8r} {8r}{pad}{b}{n}{}
+ \installrawfont {padbi8r}{padbi8r,8r}{8r} {8r}{pad}{b}{it}{}
+ \installrawfont {padbo8r}{padbo8r,8r}{8r} {8r}{pad}{b}{sl}{}
+\endinstallfonts
+
+
+% In the above commands, the commands have been lined up to
+% visually separate those arguments that have to do with how
+% a font is declared to LaTeX (rightmost) from those arguments
+% that specify how the font is made and what it should be called.
+
+
+% The following commands make a very basic installation of "pad"
+% families in the OT1, T1, and TS1 encodings; there is not attempt
+% to make use of the -Exp (expert) or -SC (smallcaps) fonts in
+% the AGaramond family. (One reason for making this distinction
+% is that Adobe sell these other fonts separately, so some people
+% may have the basic set used below and nothing more. Another
+% reason is that for many typefaces, there are no expert or -SC
+% fonts at all. Adapting an example using such fonts to a typeface
+% which do not have them is much too confusing for a beginner.)
+\installfonts
+ \installfamily{OT1}{pad}{}
+ \installfamily{T1}{pad}{}
+ \installfamily{TS1}{pad}{}
+
+ \installfont {padr8t}{padr8r,newlatin}{t1} {T1}{pad}{m}{n}{}
+ \installfont {padr7t}{padr8r,newlatin}{ot1} {OT1}{pad}{m}{n}{}
+ \installfont {padrc8t}{padr8r,newlatin}{t1c} {T1}{pad}{m}{sc}{}
+ \installfont {padrc7t}{padr8r,newlatin}{ot1c} {OT1}{pad}{m}{sc}{}
+ \installfont {padr8i}{padr8r,textcomp}{ts1} {TS1}{pad}{m}{n}{}
+ % There is no difference between the n and the sc shapes
+ % of TS1 encoded fonts, hence the same TeX font can be
+ % used for both. LaTeX does however need the declarations
+ % to be explicit, hence this \installfontas command.
+ \installfontas{padr8i} {TS1}{pad}{m}{sc}{}
+ % The "option nosc" below is a speed optimization.
+ % newlatin.mtx normally makes sure that a smallcaps
+ % alphabet is defined (faking it if necessary),
+ % regardless of whether that alphabet is at all
+ % going to be used. By passing it the "nosc" option,
+ % one can tell newlatin.mtx to completely skip those
+ % commands that have to do with smallcaps.
+ \installfont {padri8t}{padri8r,newlatin option nosc}{t1} {T1}{pad}{m}{it}{}
+ \installfont {padri7t}{padri8r,newlatin option nosc}{ot1} {OT1}{pad}{m}{it}{}
+ \installfont {padri8i}{padri8r,textcomp}{ts1} {TS1}{pad}{m}{it}{}
+ \installfont {padro8t}{padro8r,newlatin option nosc}{t1} {T1}{pad}{m}{sl}{}
+ \installfont {padro7t}{padro8r,newlatin option nosc}{ot1} {OT1}{pad}{m}{sl}{}
+ \installfont {padro8i}{padro8r,textcomp}{ts1} {TS1}{pad}{m}{sl}{}
+
+ % The reason newlatin is not passed the nosc option when
+ % making the "n" shape fonts here is another (more tricky)
+ % speed optimization. If the metric argument of two
+ % subsequent \installfont commands are identical then the
+ % respective glyph bases will be identical too, and in these
+ % cases fontinst saves work by not rebuilding the glyph base
+ % at the second command, but instead using the cached
+ % definitions from the first.
+ \installfont {pads8t}{pads8r,newlatin}{t1} {T1}{pad}{sb}{n}{}
+ \installfont {pads7t}{pads8r,newlatin}{ot1} {OT1}{pad}{sb}{n}{}
+ \installfont {padsc8t}{pads8r,newlatin}{t1c} {T1}{pad}{sb}{sc}{}
+ \installfont {padsc7t}{pads8r,newlatin}{ot1c} {OT1}{pad}{sb}{sc}{}
+ % Thus the last four commands cause four fonts to be
+ % generated, but the pads8r.mtx and newlatin.mtx files
+ % are only read once.
+ \installfont {pads8i}{pads8r,textcomp}{ts1} {TS1}{pad}{sb}{n}{}
+ \installfontas{pads8i} {TS1}{pad}{sb}{sc}{}
+ \installfont {padsi8t}{padsi8r,newlatin option nosc}{t1} {T1}{pad}{sb}{it}{}
+ \installfont {padsi7t}{padsi8r,newlatin option nosc}{ot1} {OT1}{pad}{sb}{it}{}
+ \installfont {padsi8i}{padsi8r,textcomp}{ts1} {TS1}{pad}{sb}{it}{}
+ \installfont {padso8t}{padso8r,newlatin option nosc}{t1} {T1}{pad}{sb}{sl}{}
+ \installfont {padso7t}{padso8r,newlatin option nosc}{ot1} {OT1}{pad}{sb}{sl}{}
+ \installfont {padso8i}{padso8r,textcomp}{ts1} {TS1}{pad}{sb}{sl}{}
+
+ \installfont {padb8t}{padb8r,newlatin}{t1} {T1}{pad}{b}{n}{}
+ \installfont {padb7t}{padb8r,newlatin}{ot1} {OT1}{pad}{b}{n}{}
+ \installfont {padbc8t}{padb8r,newlatin}{t1c} {T1}{pad}{b}{sc}{}
+ \installfont {padbc7t}{padb8r,newlatin}{ot1c} {OT1}{pad}{b}{sc}{}
+ \installfont {padb8i}{padb8r,textcomp}{ts1} {TS1}{pad}{b}{n}{}
+ \installfontas{padb8i} {TS1}{pad}{b}{sc}{}
+ \installfont {padbi8t}{padbi8r,newlatin option nosc}{t1} {T1}{pad}{b}{it}{}
+ \installfont {padbi7t}{padbi8r,newlatin option nosc}{ot1} {OT1}{pad}{b}{it}{}
+ \installfont {padbi8i}{padbi8r,textcomp}{ts1} {TS1}{pad}{b}{it}{}
+ \installfont {padbo8t}{padbo8r,newlatin option nosc}{t1} {T1}{pad}{b}{sl}{}
+ \installfont {padbo7t}{padbo8r,newlatin option nosc}{ot1} {OT1}{pad}{b}{sl}{}
+ \installfont {padbo8i}{padbo8r,textcomp}{ts1} {TS1}{pad}{b}{sl}{}
+\endinstallfonts
+
+
+% The set of commands above will "fake" an sc shape for the typeface
+% by making dual use of the capitals in the n shape (Regular): both
+% as normal (for the upper case in the sc shape) and shrunk to 80% of
+% their normal size (for the lower case in the sc shape). This works
+% (anyone who looks at it will understand what was intended), but it
+% does not look good, and therefore it is always better to make use
+% of proper smallcaps when it is available.
+%
+% The next set of commands is another take at creating the "pad"
+% families, this time making use of the proper smallcaps in padrc8r
+% and padsc8r. The files created by this set of commands will
+% completely overwrite the files created by the previous set of
+% commands; in practice one would only include one set of commands,
+% but both are provided here for comparison.
+\installfonts
+ \installfamily{OT1}{pad}{}
+ \installfamily{T1}{pad}{}
+ \installfamily{TS1}{pad}{}
+
+ % Since the glyph bases used for the n and sc shapes in this
+ % case are different, there is no point in doing the smallcaps
+ % processing when making the n shape fonts.
+ \installfont {padr8t}{padr8r,newlatin option nosc}{t1} {T1}{pad}{m}{n}{}
+ \installfont {padr7t}{padr8r,newlatin option nosc}{ot1} {OT1}{pad}{m}{n}{}
+ % There is actually no point in doing that processing for
+ % the sc shape fonts either! This is because the glyph names
+ % used in padrc8r are the same as those used in padr8r (and
+ % padri8r), and thus the smallcaps glyphs will already have
+ % been delt with by the code for lower case glyphs. Another
+ % consequence is that the same ETX files as are used for
+ % the other shapes should be used for the sc shape.
+ \installfont {padrc8t}{padrc8r,newlatin option nosc}{t1} {T1}{pad}{m}{sc}{}
+ \installfont {padrc7t}{padrc8r,newlatin option nosc}{ot1} {OT1}{pad}{m}{sc}{}
+ \installfont {padr8i}{padr8r,textcomp}{ts1} {TS1}{pad}{m}{n}{}
+ \installfontas{padr8i} {TS1}{pad}{m}{sc}{}
+ \installfont {padri8t}{padri8r,newlatin option nosc}{t1} {T1}{pad}{m}{it}{}
+ \installfont {padri7t}{padri8r,newlatin option nosc}{ot1} {OT1}{pad}{m}{it}{}
+ \installfont {padri8i}{padri8r,textcomp}{ts1} {TS1}{pad}{m}{it}{}
+ \installfont {padro8t}{padro8r,newlatin option nosc}{t1} {T1}{pad}{m}{sl}{}
+ \installfont {padro7t}{padro8r,newlatin option nosc}{ot1} {OT1}{pad}{m}{sl}{}
+ \installfont {padro8i}{padro8r,textcomp}{ts1} {TS1}{pad}{m}{sl}{}
+
+ \installfont {pads8t}{pads8r,newlatin option nosc}{t1} {T1}{pad}{sb}{n}{}
+ \installfont {pads7t}{pads8r,newlatin option nosc}{ot1} {OT1}{pad}{sb}{n}{}
+ \installfont {padsc8t}{padsc8r,newlatin option nosc}{t1} {T1}{pad}{sb}{sc}{}
+ \installfont {padsc7t}{padsc8r,newlatin option nosc}{ot1} {OT1}{pad}{sb}{sc}{}
+ \installfont {pads8i}{pads8r,textcomp}{ts1} {TS1}{pad}{sb}{n}{}
+ \installfontas{pads8i} {TS1}{pad}{sb}{sc}{}
+ \installfont {padsi8t}{padsi8r,newlatin option nosc}{t1} {T1}{pad}{sb}{it}{}
+ \installfont {padsi7t}{padsi8r,newlatin option nosc}{ot1} {OT1}{pad}{sb}{it}{}
+ \installfont {padsi8i}{padsi8r,textcomp}{ts1} {TS1}{pad}{sb}{it}{}
+ \installfont {padso8t}{padso8r,newlatin option nosc}{t1} {T1}{pad}{sb}{sl}{}
+ \installfont {padso7t}{padso8r,newlatin option nosc}{ot1} {OT1}{pad}{sb}{sl}{}
+ \installfont {padso8i}{padso8r,textcomp}{ts1} {TS1}{pad}{sb}{sl}{}
+
+ % There is however no padbc8r font; hence the sc shape of
+ % the b series must still be faked, just as above.
+ \installfont {padb8t}{padb8r,newlatin}{t1} {T1}{pad}{b}{n}{}
+ \installfont {padb7t}{padb8r,newlatin}{ot1} {OT1}{pad}{b}{n}{}
+ \installfont {padbc8t}{padb8r,newlatin}{t1c} {T1}{pad}{b}{sc}{}
+ \installfont {padbc7t}{padb8r,newlatin}{ot1c} {OT1}{pad}{b}{sc}{}
+ \installfont {padb8i}{padb8r,textcomp}{ts1} {TS1}{pad}{b}{n}{}
+ \installfontas{padb8i} {TS1}{pad}{b}{sc}{}
+ \installfont {padbi8t}{padbi8r,newlatin option nosc}{t1} {T1}{pad}{b}{it}{}
+ \installfont {padbi7t}{padbi8r,newlatin option nosc}{ot1} {OT1}{pad}{b}{it}{}
+ \installfont {padbi8i}{padbi8r,textcomp}{ts1} {TS1}{pad}{b}{it}{}
+ \installfont {padbo8t}{padbo8r,newlatin option nosc}{t1} {T1}{pad}{b}{sl}{}
+ \installfont {padbo7t}{padbo8r,newlatin option nosc}{ot1} {OT1}{pad}{b}{sl}{}
+ \installfont {padbo8i}{padbo8r,textcomp}{ts1} {TS1}{pad}{b}{sl}{}
+\endinstallfonts
+
+
+% The "pad" family installed above is however still far from perfect.
+% The `ff', `ffi', and `ffl' ligatures are fakes, since those aren't
+% available in the fonts used. There are however such glyphs in the
+% expert (8x) companions of the fonts used above, and hence the
+% results will be better if these resources can be combined.
+%
+% One of the great advantages with TeX, virtual fonts, and fontinst
+% is the ease with which one can combine glyphs from (what the foundry
+% has packaged as) several different fonts into a single font;
+% if \installfont is given the metrics of two fonts, and some glyph
+% is available in one font but not the other, then fontinst will
+% automatically take it from the font where it was available.
+% Hence one can fill in (at least some of) the blanks of one font
+% by also listing a second font in the metrics argument of
+% \installfont. It will do the right thing automatically.
+\installfonts
+ \installfamily{OT1}{padx}{}
+ \installfamily{T1}{padx}{}
+ \installfamily{TS1}{padx}{}
+ % The "padx" family name used here is mainly motivated by
+ % tradition. It has been considered useful to simultaneously
+ % on a single system have both a family of virtual fonts which
+ % do not make use of the expert set of base fonts, and a family
+ % of virtual fonts which do make use of the expert set of base
+ % fonts. For this to work, the different fonts must have
+ % different names. In the Fontname scheme, this is accomplished
+ % by including an "x" variant letter in the names to signify that
+ % the font is "expertized". In LaTeX there is no proper standard
+ % for this, but the custom is to similarly append an "x" to the
+ % basic three letter family name, thus yielding "padx" instead
+ % of "pad".
+
+ % The Fontname scheme is in this case further complicated by
+ % a desire to avoid names of more than eight characters
+ % (a limit which is important in many old file systems).
+ % Therefore many of the two-character variants starting with
+ % 9 is a combination of an encoding variant with one or two
+ % other variants (most commonly the "x" variant). The commands
+ % below utilize these abbreviations (but there is no software
+ % involved which would require them to).
+ \installfont {padr9e}{padr8r,padr8x,newlatin}{t1} {T1}{padx}{m}{n}{}
+ \installfont {padr9t}{padr8r,padr8x,newlatin}{ot1} {OT1}{padx}{m}{n}{}
+ % Besides the extra ligatures, the upright 8x fonts also contain
+ % a proper smallcaps alphabet. This makes it possible to make do
+ % without the -c8r fonts. The commands below will make a font
+ % using the upper case from padr8r and (as lower case) the
+ % small caps from padr8x.
+ \installfont {padrc9e}{padr8r,padr8x,newlatin}{t1c} {T1}{padx}{m}{sc}{}
+ \installfont {padrc9t}{padr8r,padr8x,newlatin}{ot1c} {OT1}{padx}{m}{sc}{}
+ \installfont {padr9i}{padr8r,padr8x,textcomp}{ts1} {TS1}{padx}{m}{n}{}
+ \installfontas{padr9i} {TS1}{padx}{m}{sc}{}
+ \installfont {padri9e}{padri8r,padri8x,newlatin option nosc}{t1} {T1}{padx}{m}{it}{}
+ \installfont {padri9t}{padri8r,padri8x,newlatin option nosc}{ot1} {OT1}{padx}{m}{it}{}
+ \installfont {padri9i}{padri8r,padri8x,textcomp}{ts1} {TS1}{padx}{m}{it}{}
+ \installfont {padro9e}{padro8r,padro8x,newlatin option nosc}{t1} {T1}{padx}{m}{sl}{}
+ \installfont {padro9t}{padro8r,padro8x,newlatin option nosc}{ot1} {OT1}{padx}{m}{sl}{}
+ \installfont {padro9i}{padro8r,padro8x,textcomp}{ts1} {TS1}{padx}{m}{sl}{}
+
+ \installfont {pads9e}{pads8r,pads8x,newlatin}{t1} {T1}{padx}{sb}{n}{}
+ \installfont {pads9t}{pads8r,pads8x,newlatin}{ot1} {OT1}{padx}{sb}{n}{}
+ \installfont {padsc9e}{pads8r,pads8x,newlatin}{t1c} {T1}{padx}{sb}{sc}{}
+ \installfont {padsc9t}{pads8r,pads8x,newlatin}{ot1c} {OT1}{padx}{sb}{sc}{}
+ \installfont {pads9i}{pads8r,pads8x,textcomp}{ts1} {TS1}{padx}{sb}{n}{}
+ \installfontas{pads9i} {TS1}{padx}{sb}{sc}{}
+ \installfont {padsi9e}{padsi8r,padsi8x,newlatin option nosc}{t1} {T1}{padx}{sb}{it}{}
+ \installfont {padsi9t}{padsi8r,padsi8x,newlatin option nosc}{ot1} {OT1}{padx}{sb}{it}{}
+ \installfont {padsi9i}{padsi8r,padsi8x,textcomp}{ts1} {TS1}{padx}{sb}{it}{}
+ \installfont {padso9e}{padso8r,padso8x,newlatin option nosc}{t1} {T1}{padx}{sb}{sl}{}
+ \installfont {padso9t}{padso8r,padso8x,newlatin option nosc}{ot1} {OT1}{padx}{sb}{sl}{}
+ \installfont {padso9i}{padso8r,padso8x,textcomp}{ts1} {TS1}{padx}{sb}{sl}{}
+
+ \installfont {padb9e}{padb8r,padb8x,newlatin}{t1} {T1}{padx}{b}{n}{}
+ \installfont {padb9t}{padb8r,padb8x,newlatin}{ot1} {OT1}{padx}{b}{n}{}
+ % The padb8x font does not contain a smallcaps alphabet --
+ % hence in this case the newlatin.mtx file reverts to faking
+ % such an alphabet by shrinking the upper case. The commands
+ % can however be the same as above!
+ \installfont {padbc9e}{padb8r,padb8x,newlatin}{t1c} {T1}{padx}{b}{sc}{}
+ \installfont {padbc9t}{padb8r,padb8x,newlatin}{ot1c} {OT1}{padx}{b}{sc}{}
+ \installfont {padb9i}{padb8r,padb8x,textcomp}{ts1} {TS1}{padx}{b}{n}{}
+ \installfontas{padb9i} {TS1}{padx}{b}{sc}{}
+ \installfont {padbi9e}{padbi8r,padbi8x,newlatin option nosc}{t1} {T1}{padx}{b}{it}{}
+ \installfont {padbi9t}{padbi8r,padbi8x,newlatin option nosc}{ot1} {OT1}{padx}{b}{it}{}
+ \installfont {padbi9i}{padbi8r,padbi8x,textcomp}{ts1} {TS1}{padx}{b}{it}{}
+ \installfont {padbo9e}{padbo8r,padbo8x,newlatin option nosc}{t1} {T1}{padx}{b}{sl}{}
+ \installfont {padbo9t}{padbo8r,padbo8x,newlatin option nosc}{ot1} {OT1}{padx}{b}{sl}{}
+ \installfont {padbo9i}{padbo8r,padbo8x,textcomp}{ts1} {TS1}{padx}{b}{sl}{}
+\endinstallfonts
+
+
+% Finally we get to my personal favourite -- the families with hanging
+% (a.k.a. oldstyle) figures. From a historical point of view, this is
+% really the most correct appearence of these fonts, because in the 16th
+% century (when Claude Garamond designed the metal types after which the
+% AGaramond fonts where modelled) there was no such thing as lining
+% figures; all figures were hanging.
+%
+% The 8x fonts all contain a suitable set of hanging figures. This makes
+% it very straightforward to make use of these instead of the lining
+% digits of the base fonts. One simply has to make use of ETX files
+% which selects these glyphs hanging figure glyphs instead of the
+% lining figure glyphs.
+\installfonts
+ \installfamily{OT1}{padj}{}
+ \installfamily{T1}{padj}{}
+ \installfamily{TS1}{padj}{}
+ % Another custom: a "j" (the Fontname hanging figure variant letter)
+ % is appended to the LaTeX family name to distinguish between
+ % lining and hanging figure families.
+
+ \installfont {padr9d}{padr8r,padr8x,newlatin}{t1j} {T1}{padj}{m}{n}{}
+ \installfont {padr9o}{padr8r,padr8x,newlatin}{ot1j} {OT1}{padj}{m}{n}{}
+ \installfont {padrc9d}{padr8r,padr8x,newlatin}{t1cj} {T1}{padj}{m}{sc}{}
+ \installfont {padrc9o}{padr8r,padr8x,newlatin}{ot1cj} {OT1}{padj}{m}{sc}{}
+ \installfont {padr9i}{padr8r,padr8x,textcomp}{ts1} {TS1}{padj}{m}{n}{}
+ \installfontas{padr9i} {TS1}{padj}{m}{sc}{}
+ \installfont {padri9d}{padri8r,padri8x,newlatin option nosc}{t1j} {T1}{padj}{m}{it}{}
+ \installfont {padri9o}{padri8r,padri8x,newlatin option nosc}{ot1j} {OT1}{padj}{m}{it}{}
+ \installfont {padri9i}{padri8r,padri8x,textcomp}{ts1} {TS1}{padj}{m}{it}{}
+ \installfont {padro9d}{padro8r,padro8x,newlatin option nosc}{t1j} {T1}{padj}{m}{sl}{}
+ \installfont {padro9o}{padro8r,padro8x,newlatin option nosc}{ot1j} {OT1}{padj}{m}{sl}{}
+ \installfont {padro9i}{padro8r,padro8x,textcomp}{ts1} {TS1}{padj}{m}{sl}{}
+
+ \installfont {pads9d}{pads8r,pads8x,newlatin}{t1j} {T1}{padj}{sb}{n}{}
+ \installfont {pads9o}{pads8r,pads8x,newlatin}{ot1j} {OT1}{padj}{sb}{n}{}
+ \installfont {padsc9d}{pads8r,pads8x,newlatin}{t1cj} {T1}{padj}{sb}{sc}{}
+ \installfont {padsc9o}{pads8r,pads8x,newlatin}{ot1cj} {OT1}{padj}{sb}{sc}{}
+ \installfont {pads9i}{pads8r,pads8x,textcomp}{ts1} {TS1}{padj}{sb}{n}{}
+ \installfontas{pads9i} {TS1}{padj}{sb}{sc}{}
+ \installfont {padsi9d}{padsi8r,padsi8x,newlatin option nosc}{t1j} {T1}{padj}{sb}{it}{}
+ \installfont {padsi9o}{padsi8r,padsi8x,newlatin option nosc}{ot1j} {OT1}{padj}{sb}{it}{}
+ \installfont {padsi9i}{padsi8r,padsi8x,textcomp}{ts1} {TS1}{padj}{sb}{it}{}
+ \installfont {padso9d}{padso8r,padso8x,newlatin option nosc}{t1j} {T1}{padj}{sb}{sl}{}
+ \installfont {padso9o}{padso8r,padso8x,newlatin option nosc}{ot1j} {OT1}{padj}{sb}{sl}{}
+ \installfont {padso9i}{padso8r,padso8x,textcomp}{ts1} {TS1}{padj}{sb}{sl}{}
+
+ \installfont {padb9d}{padb8r,padb8x,newlatin}{t1j} {T1}{padj}{b}{n}{}
+ \installfont {padb9o}{padb8r,padb8x,newlatin}{ot1j} {OT1}{padj}{b}{n}{}
+ \installfont {padbc9d}{padb8r,padb8x,newlatin}{t1cj} {T1}{padj}{b}{sc}{}
+ \installfont {padbc9o}{padb8r,padb8x,newlatin}{ot1cj} {OT1}{padj}{b}{sc}{}
+ \installfont {padb9i}{padb8r,padb8x,textcomp}{ts1} {TS1}{padj}{b}{n}{}
+ \installfontas{padb9i} {TS1}{padj}{b}{sc}{}
+ \installfont {padbi9d}{padbi8r,padbi8x,newlatin option nosc}{t1j} {T1}{padj}{b}{it}{}
+ \installfont {padbi9o}{padbi8r,padbi8x,newlatin option nosc}{ot1j} {OT1}{padj}{b}{it}{}
+ \installfont {padbi9i}{padbi8r,padbi8x,textcomp}{ts1} {TS1}{padj}{b}{it}{}
+ \installfont {padbo9d}{padbo8r,padbo8x,newlatin option nosc}{t1j} {T1}{padj}{b}{sl}{}
+ \installfont {padbo9o}{padbo8r,padbo8x,newlatin option nosc}{ot1j} {OT1}{padj}{b}{sl}{}
+ \installfont {padbo9i}{padbo8r,padbo8x,textcomp}{ts1} {TS1}{padj}{b}{sl}{}
+\endinstallfonts
+
+% This closes the file opened by \recordtransforms above.
+\endrecordtransforms
+
+\bye
+
+% The installations made by the above commands are certainly not
+% optimal. Some things which can be improved are:
+%
+% - Although the padrc9e, padrc9t, padsc9e, padsc9t, padrc9d,
+% padrc9o, padsc9d, and padsc9o fonts contain proper smallcaps
+% glyphs, there are no kerns between the smallcaps and
+% the upper case in these fonts, because there were no such
+% kerns in any of the fonts they are based on. There are
+% however such kerning pairs in padrc8r and padsc8r, and it is
+% quite easy to extract this information using the \reglyphfont
+% command with the settings in the csckrn2x.tex file.
+%
+% - The padrc8t, padrc7t, padsc8t, and padsc7t fonts that are
+% based on padrc8r and padsc8r respectively have hanging figures,
+% whereas the other fonts in the same family have lining figures.
+% This is only because that is how the foundry packaged the
+% glyphs into fonts, and the careful font installer might want
+% to straighten out this situation. One way to do that is
+% to make use of the unsetnum.mtx file, another is to make
+% use of the `suffix' mechanism (new in v1.923).
+%
+% - One glyph which is missing from all the fonts made above is
+% the Euro glyph (and that is kind of awkward these days, although
+% as of v1.926 textcomp.mtx fakes this using a C and two rules).
+% One way to supply a Euro glyph is to provide yet another font
+% (besides the -8r's and -8x's) as base font, if that extra
+% font contains the missing Euro glyph. The same trick can be used
+% to get greek capitals for the OT1-encoded fonts.
+
diff --git a/fonts/utilities/fontinst/examples/basic/basicex2.tex b/fonts/utilities/fontinst/examples/basic/basicex2.tex
new file mode 100644
index 0000000000..74fe2a4df5
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/basic/basicex2.tex
@@ -0,0 +1,50 @@
+%
+% basicex2.tex
+%
+% fontinst command file for writing map file fragments for
+% the raw fonts used by the fonts made in basicex.tex.
+%
+
+\input finstmsc.sty
+
+% At this point, you might want to change some settings
+% to make the map file fragments written better adjusted
+% to your particular system. Some common examples are:
+%
+% \resetstr{PSfontsuffix}{.pfb}
+%
+% which is useful if the actual fonts are in PFB format.
+%
+% \AssumeLWFN
+%
+% This is useful if the font files are named according to
+% the old Mac OS Classic convention for PostScript fonts
+% (names like AGarBolIta).
+
+\adddriver{dvips}{dvips.map}
+% This causes a .map file for dvips to be written.
+% It is probably better to choose a name that has to
+% do with the fonts than to use `dvips.map'.
+% In some systems, there is a program updmap which combines
+% several small .map files such as this one into a large
+% psfonts.map file.
+\adddriver{dvipdfm}{dvipdfm.map}
+% Similar file for dvipdfm.
+\adddriver{pltotf}{pltotf-script.sh}
+% A shell script that runs pltotf on those .pl files
+% which you need to turn into .tfm files.
+\adddriver{debug}{mapdump.txt}
+% This file contains the available data in a human-readable
+% format. This is useful if your dvi driver uses some other
+% kind of map file.
+
+\input basicex.recs
+% This is where all the work is done.
+
+\donedrivers
+% This closes the files and does some cleanup.
+
+\bye
+
+
+
diff --git a/fonts/utilities/fontinst/examples/eurofont/Makefile b/fonts/utilities/fontinst/examples/eurofont/Makefile
new file mode 100644
index 0000000000..ec07888a1a
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/eurofont/Makefile
@@ -0,0 +1,45 @@
+## Makefile to build TS1-encoded text companion fonts
+## for Times, Helvetica and Symbol using the Adobe Euro Fonts
+
+all: afms tex vfs
+
+afms:
+ cp _3______.afm zpeur.afm
+ cp _3i_____.afm zpeuri.afm
+ cp _3b_____.afm zpeub.afm
+ cp _3bi____.afm zpeubi.afm
+ cp _1______.afm zpeurs.afm
+ cp _1i_____.afm zpeuris.afm
+ cp _1b_____.afm zpeubs.afm
+ cp _1bi____.afm zpeubis.afm
+ cp _2______.afm zpeurt.afm
+ cp _2i_____.afm zpeurit.afm
+ cp _2b_____.afm zpeubt.afm
+ cp _2bi____.afm zpeubit.afm
+
+tex:
+ tex eurofont.tex
+
+vfs:
+ vptovf ptmr8c.vpl ptmr8c.vf ptmr8c.tfm
+ vptovf ptmro8c.vpl ptmro8c.vf ptmro8c.tfm
+ vptovf ptmri8c.vpl ptmri8c.vf ptmri8c.tfm
+ vptovf ptmb8c.vpl ptmb8c.vf ptmb8c.tfm
+ vptovf ptmbo8c.vpl ptmbo8c.vf ptmbo8c.tfm
+ vptovf ptmbi8c.vpl ptmbi8c.vf ptmbi8c.tfm
+
+ vptovf phvr8c.vpl phvr8c.vf phvr8c.tfm
+ vptovf phvro8c.vpl phvro8c.vf phvro8c.tfm
+ vptovf phvb8c.vpl phvb8c.vf phvb8c.tfm
+ vptovf phvbo8c.vpl phvbo8c.vf phvbo8c.tfm
+
+ vptovf pcrr8c.vpl pcrr8c.vf pcrr8c.tfm
+ vptovf pcrro8c.vpl pcrro8c.vf pcrro8c.tfm
+ vptovf pcrb8c.vpl pcrb8c.vf pcrb8c.tfm
+ vptovf pcrbo8c.vpl pcrbo8c.vf pcrbo8c.tfm
+
+clean:
+ -rm *.mtx *.pl *.vpl *.log
+
+realclean: clean
+ -rm p*.tfm *.vf *.fd
diff --git a/fonts/utilities/fontinst/examples/eurofont/eurofont.map b/fonts/utilities/fontinst/examples/eurofont/eurofont.map
new file mode 100644
index 0000000000..373ffd2d16
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/eurofont/eurofont.map
@@ -0,0 +1,12 @@
+zpeur EuroSerif-Regular <_3______.pfb
+zpeuri EuroSerif-Italic <_3i_____.pfb
+zpeub EuroSerif-Bold <_3b_____.pfb
+zpeubi EuroSerif-BoldItalic <_3bi____.pfb
+zpeurs EuroSans-Regular <_1______.pfb
+zpeuris EuroSans-Italic <_1i_____.pfb
+zpeubs EuroSans-Bold <_1b_____.pfb
+zpeubis EuroSans-BoldItalic <_1bi____.pfb
+zpeurt EuroMono-Regular <_2______.pfb
+zpeurit EuroMono-Italic <_2i_____.pfb
+zpeubt EuroMono-Bold <_2b_____.pfb
+zpeubit EuroMono-BoldItalic <_2bi____.pfb
diff --git a/fonts/utilities/fontinst/examples/eurofont/eurofont.tex b/fonts/utilities/fontinst/examples/eurofont/eurofont.tex
new file mode 100644
index 0000000000..b97cfeb84a
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/eurofont/eurofont.tex
@@ -0,0 +1,43 @@
+\input fontinst.sty
+
+\transformfont{ptmr8r} {\reencodefont{8r}{\fromafm{ptmr8a}}}
+\transformfont{ptmro8r}{\slantfont{167} {\frommtx{ptmr8r}}}
+\transformfont{ptmri8r}{\reencodefont{8r}{\fromafm{ptmri8a}}}
+\transformfont{ptmb8r} {\reencodefont{8r}{\fromafm{ptmb8a}}}
+\transformfont{ptmbo8r}{\slantfont{167} {\frommtx{ptmb8r}}}
+\transformfont{ptmbi8r}{\reencodefont{8r}{\fromafm{ptmbi8a}}}
+
+\transformfont{phvr8r} {\reencodefont{8r}{\fromafm{phvr8a}}}
+\transformfont{phvro8r}{\reencodefont{8r}{\fromafm{phvro8a}}}
+\transformfont{phvb8r} {\reencodefont{8r}{\fromafm{phvb8a}}}
+\transformfont{phvbo8r}{\reencodefont{8r}{\fromafm{phvbo8a}}}
+
+\transformfont{pcrr8r} {\reencodefont{8r}{\fromafm{pcrr8a}}}
+\transformfont{pcrro8r}{\reencodefont{8r}{\fromafm{pcrro8a}}}
+\transformfont{pcrb8r} {\reencodefont{8r}{\fromafm{pcrb8a}}}
+\transformfont{pcrbo8r}{\reencodefont{8r}{\fromafm{pcrbo8a}}}
+
+\installfonts
+
+\installfamily{TS1}{ptm}{}
+\installfont{ptmr8c} {ptmr8r,zpeur,textcomp} {TS1}{TS1}{ptm}{m}{n}{}
+\installfont{ptmro8c}{ptmro8r,zpeuri,textcomp}{TS1}{TS1}{ptm}{m}{sl}{}
+\installfont{ptmri8c}{ptmri8r,zpeuri,textcomp}{TS1}{TS1}{ptm}{m}{it}{}
+\installfont{ptmb8c} {ptmb8r,zpeub,textcomp} {TS1}{TS1}{ptm}{b}{n}{}
+\installfont{ptmbo8c}{ptmbo8r,zpeubi,textcomp}{TS1}{TS1}{ptm}{b}{sl}{}
+\installfont{ptmbi8c}{ptmbi8r,zpeubi,textcomp}{TS1}{TS1}{ptm}{b}{it}{}
+
+\installfamily{TS1}{phv}{}
+\installfont{phvr8c} {phvr8r,zpeurs,textcomp} {TS1}{TS1}{phv}{m}{n}{}
+\installfont{phvro8c}{phvro8r,zpeuris,textcomp}{TS1}{TS1}{phv}{m}{sl}{}
+\installfont{phvb8c} {phvb8r,zpeubs,textcomp} {TS1}{TS1}{phv}{b}{n}{}
+\installfont{phvbo8c}{phvbo8r,zpeubis,textcomp}{TS1}{TS1}{phv}{b}{sl}{}
+
+\installfamily{TS1}{pcr}{}
+\installfont{pcrr8c} {pcrr8r,zpeurt,textcomp} {TS1}{TS1}{pcr}{m}{n}{}
+\installfont{pcrro8c}{pcrro8r,zpeurit,textcomp}{TS1}{TS1}{pcr}{m}{sl}{}
+\installfont{pcrb8c} {pcrb8r,zpeubt,textcomp} {TS1}{TS1}{pcr}{b}{n}{}
+\installfont{pcrbo8c}{pcrbo8r,zpeubit,textcomp}{TS1}{TS1}{pcr}{b}{sl}{}
+
+\endinstallfonts
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/examples/mathptm/Makefile b/fonts/utilities/fontinst/examples/mathptm/Makefile
new file mode 100644
index 0000000000..8f2b4df065
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/Makefile
@@ -0,0 +1,24 @@
+ZAP= cmex10.mtx cmex9.mtx cmr10.mtx cmmi10.mtx cmsy10.mtx \
+ psyr.mtx psyr.pl \
+ ptmr8a.mtx ptmr8a.pl ptmr8r.mtx ptmr8r.pl \
+ ptmri8a.mtx ptmri8a.pl ptmri8r.mtx ptmri8r.pl \
+ pzcmi8a.mtx pzcmi8a.pl pzcmi8r.mtx pzcmi8r.pl \
+ zpsycmrv.vpl zptmcmr.vpl zptmcmrm.vpl zpzccmry.vpl \
+ fontptcm.log
+
+all: tex vfs
+
+tex:
+ tex fontptcm
+
+vfs:
+ vptovf zpsycmrv.vpl zpsycmrv.vf zpsycmrv.tfm
+ vptovf zptmcmr.vpl zptmcmr.vf zptmcmr.tfm
+ vptovf zptmcmrm.vpl zptmcmrm.vf zptmcmrm.tfm
+ vptovf zpzccmry.vpl zpzccmry.vf zpzccmry.tfm
+
+clean:
+ -rm $(ZAP) *.log
+
+realclean: clean
+ -rm p*tfm z*.tfm *.vf *.fd
diff --git a/fonts/utilities/fontinst/examples/mathptm/fontptcm.tex b/fonts/utilities/fontinst/examples/mathptm/fontptcm.tex
new file mode 100644
index 0000000000..12f9200f1a
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/fontptcm.tex
@@ -0,0 +1,75 @@
+%%% ====================================================================
+%%% @TeX-file{
+%%% author = "Alan Jeffrey and Sebastian Rathz and
+%%% Ulrik Vieth",
+%%% version = "1.801",
+%%% date = "30 June 1998",
+%%% time = "00:24:26 CEST",
+%%% filename = "fontptcm.tex",
+%%% email = "vieth@thphy.uni-duesseldorf.de",
+%%% URL = "http://www.thphy.uni-duesseldorf.de/~vieth/",
+%%% checksum = "55484 75 248 2976",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "font installation example",
+%%% supported = "yes",
+%%% abstract = "This is an example program which uses
+%%% Adobe Times, Adobe Symbol and Computer
+%%% Modern fonts to build Times math fonts.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, ptmr8a.afm, ptmri8a.afm,
+%%% pzcmi8a.afm, psyr.afm, cmr10.pl,
+%%% cmmi10.pl, cmsy10.pl, cmex10.pl, cmex9.pl,
+%%% mathit.mtx, mathsy.mtx, mathex.mtx,
+%%% zrhax.mtx, zrmhax.mtx, zrvhax.mtx,
+%%% zrmkern.mtx, unsethum.mtx, unsetalf.mtx,
+%%% resetsy.mtx, kernoff.mtx, kernon.mtx",
+%%% }
+%%% ====================================================================
+
+% Math fonts built from Times, Symbol, Zapf Chancery and CM math.
+
+\input fontinst.sty
+
+\needsfontinstversion{1.800}
+
+\installfonts
+ \transformfont{ptmr8r} {\reencodefont{8r}{\fromafm{ptmr8a}}}
+ \transformfont{ptmri8r}{\reencodefont{8r}{\fromafm{ptmri8a}}}
+ \transformfont{pzcmi8r}{\reencodefont{8r}{\fromafm{pzcmi8a}}}
+ \fromafm{psyr}
+
+ % OT1: Latin and digits from Times-Roman, Greek from Symbol,
+ % accents and punctuation from Times, delimiters from cmr10
+ \installfamily{OT1}{ptmcm}{}
+ \installfont{zptmcmr}
+ {ptmr8r,psyr,resetsy,latin,%
+ zrhax,kernoff,cmr10,kernon}
+ {OT1}{OT1}{ptmcm}{m}{n}{}
+
+ % OML: Latin from Times-Italic, Greek from Adobe Symbol,
+ % operators, delimiters and punctuation from cmmi10
+ \installfamily{OML}{ptmcm}{\skewchar\font=127}
+ \installfont{zptmcmrm}
+ {ptmri8r,psyr,resetsy,%
+ zrmhax,kernoff,cmmi10,kernon,%
+ zrmkern,mathit}
+ {OML}{OML}{ptmcm}{m}{it}{}
+
+ % OMS: Humanist symbols from Times-Roman and Symbol,
+ % Calligraphic alphabet from Zapf Chancery,
+ % operators, delimiters and arrows from cmsy10
+ \installfamily{OMS}{pzccm}{}
+ \installfont{zpzccmry}
+ {cmsy10,zryhax,psyr,ptmr8r,%
+ unsetalf,pzcmi8r scaled 1124,mathsy}
+ {OMS}{OMS}{pzccm}{m}{n}{}
+
+ % OMX: summation and product from psyr, bigops from cmex9,
+ % delimiters, radicals and arrows from cmex10
+ \installfamily{OMX}{psycm}{}
+ \installfont{zpsycmrv}
+ {cmex10,psyr,zrvhax,cmex9 scaled 900}
+ {OMX}{OMX}{psycm}{m}{n}{}
+
+\endinstallfonts
+\end
diff --git a/fonts/utilities/fontinst/examples/mathptm/mathtest.tex b/fonts/utilities/fontinst/examples/mathptm/mathtest.tex
new file mode 100644
index 0000000000..f0504baf5c
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/mathtest.tex
@@ -0,0 +1,643 @@
+\documentclass[fleqn]{article}
+\usepackage{mathptm}
+
+\DeclareMathSymbol{\Gamma} {\mathalpha}{letters}{"00}
+\DeclareMathSymbol{\Delta} {\mathalpha}{letters}{"01}
+\DeclareMathSymbol{\Theta} {\mathalpha}{letters}{"02}
+\DeclareMathSymbol{\Lambda} {\mathalpha}{letters}{"03}
+\DeclareMathSymbol{\Xi} {\mathalpha}{letters}{"04}
+\DeclareMathSymbol{\Pi} {\mathalpha}{letters}{"05}
+\DeclareMathSymbol{\Sigma} {\mathalpha}{letters}{"06}
+\DeclareMathSymbol{\Upsilon}{\mathalpha}{letters}{"07}
+\DeclareMathSymbol{\Phi} {\mathalpha}{letters}{"08}
+\DeclareMathSymbol{\Psi} {\mathalpha}{letters}{"09}
+\DeclareMathSymbol{\Omega} {\mathalpha}{letters}{"0A}
+
+\DeclareMathSymbol{\alpha} {\mathalpha}{letters}{"0B}
+\DeclareMathSymbol{\beta} {\mathalpha}{letters}{"0C}
+\DeclareMathSymbol{\gamma} {\mathalpha}{letters}{"0D}
+\DeclareMathSymbol{\delta} {\mathalpha}{letters}{"0E}
+\DeclareMathSymbol{\epsilon}{\mathalpha}{letters}{"0F}
+\DeclareMathSymbol{\zeta} {\mathalpha}{letters}{"10}
+\DeclareMathSymbol{\eta} {\mathalpha}{letters}{"11}
+\DeclareMathSymbol{\theta} {\mathalpha}{letters}{"12}
+\DeclareMathSymbol{\iota} {\mathalpha}{letters}{"13}
+\DeclareMathSymbol{\kappa} {\mathalpha}{letters}{"14}
+\DeclareMathSymbol{\lambda} {\mathalpha}{letters}{"15}
+\DeclareMathSymbol{\mu} {\mathalpha}{letters}{"16}
+\DeclareMathSymbol{\nu} {\mathalpha}{letters}{"17}
+\DeclareMathSymbol{\xi} {\mathalpha}{letters}{"18}
+\DeclareMathSymbol{\pi} {\mathalpha}{letters}{"19}
+\DeclareMathSymbol{\rho} {\mathalpha}{letters}{"1A}
+\DeclareMathSymbol{\sigma} {\mathalpha}{letters}{"1B}
+\DeclareMathSymbol{\tau} {\mathalpha}{letters}{"1C}
+\DeclareMathSymbol{\upsilon}{\mathalpha}{letters}{"1D}
+\DeclareMathSymbol{\phi} {\mathalpha}{letters}{"1E}
+\DeclareMathSymbol{\chi} {\mathalpha}{letters}{"1F}
+\DeclareMathSymbol{\psi} {\mathalpha}{letters}{"20}
+\DeclareMathSymbol{\omega} {\mathalpha}{letters}{"21}
+\DeclareMathSymbol{\varepsilon} {\mathalpha}{letters}{"22}
+\DeclareMathSymbol{\vartheta} {\mathalpha}{letters}{"23}
+\DeclareMathSymbol{\varpi} {\mathalpha}{letters}{"24}
+\DeclareMathSymbol{\varrho} {\mathalpha}{letters}{"25}
+\DeclareMathSymbol{\varsigma} {\mathalpha}{letters}{"26}
+\DeclareMathSymbol{\varphi} {\mathalpha}{letters}{"27}
+
+\DeclareMathSymbol{\dit}{\mathord}{letters}{`d}
+\DeclareMathSymbol{\dup}{\mathord}{operators}{`d}
+
+\nofiles
+
+\parindent 0pt
+\mathindent 1em
+
+\def\test#1{#1}
+
+\def\testnums{%
+ \test 0 \test 1 \test 2 \test 3 \test 4 \test 5 \test 6 \test 7
+ \test 8 \test 9 }
+\def\testupperi{%
+ \test A \test B \test C \test D \test E \test F \test G \test H
+ \test I \test J \test K \test L \test M }
+\def\testupperii{%
+ \test N \test O \test P \test Q \test R \test S \test T \test U
+ \test V \test W \test X \test Y \test Z }
+\def\testupper{%
+ \testupperi\testupperii}
+
+\def\testloweri{%
+ \test a \test b \test c \test d \test e \test f \test g \test h
+ \test i \test j \test k \test l \test m }
+\def\testlowerii{%
+ \test n \test o \test p \test q \test r \test s \test t \test u
+ \test v \test w \test x \test y \test z
+ \test\imath \test\jmath }
+\def\testlower{%
+ \testloweri\testlowerii}
+
+\def\testupgreeki{%
+ \test A \test B \test\Gamma \test\Delta \test E \test Z \test H
+ \test\Theta \test I \test K \test\Lambda \test M }
+\def\testupgreekii{%
+ \test N \test\Xi \test O \test\Pi \test P \test\Sigma \test T
+ \test\Upsilon \test\Phi \test X \test\Psi \test\Omega
+ \test\nabla }
+\def\testupgreek{%
+ \testupgreeki\testupgreekii}
+
+\def\testlowgreeki{%
+ \test\alpha \test\beta \test\gamma \test\delta \test\epsilon
+ \test\zeta \test\eta \test\theta \test\iota \test\kappa \test\lambda
+ \test\mu }
+\def\testlowgreekii{%
+ \test\nu \test\xi \test o \test\pi \test\rho \test\sigma \test\tau
+ \test\upsilon \test\phi \test\chi \test\psi \test\omega }
+\def\testlowgreekiii{%
+ \test\varepsilon \test\vartheta \test\varpi \test\varrho
+ \test\varsigma \test\varphi}
+\def\testlowgreek{%
+ \testlowgreeki\testlowgreekii\testlowgreekiii}
+
+
+\begin{document}
+
+\section{Math Alphabets}
+
+Math Italic (\texttt{\string\mathnormal})
+\def\test#1{\mathnormal{#1},}
+\begin{eqnarray*}
+ && {\testnums}\\
+ && {\testupper}\\
+ && {\testlower}\\
+ && {\testupgreek}\\
+ && {\testlowgreek}
+\end{eqnarray*}%
+
+Math Roman (\texttt{\string\mathrm})
+\def\test#1{\mathrm{#1},}
+\begin{eqnarray*}
+ && {\testnums}\\
+ && {\testupper}\\
+ && {\testlower}\\
+ && {\testupgreek}
+\end{eqnarray*}%
+
+%Math Italic Bold
+%\def\test#1{\mathbm{#1},}
+%\begin{eqnarray*}
+% && {\testnums}\\
+% && {\testupper}\\
+% && {\testlower}\\
+% && {\testupgreek}\\
+% && {\testlowgreek}
+%\end{eqnarray*}%
+
+%Math Bold (\texttt{\string\mathbf})
+%\def\test#1{\mathbf{#1},}
+%\begin{eqnarray*}
+% && {\testnums}\\
+% && {\testupper}\\
+% && {\testlower}\\
+% && {\testupgreek}
+%\end{eqnarray*}%
+
+Caligraphic (\texttt{\string\mathcal})
+\def\test#1{\mathcal{#1},}
+\begin{eqnarray*}
+ && {\testupper}
+\end{eqnarray*}%
+
+%Script (\texttt{\string\mathscr})
+%\def\test#1{\mathscr{#1},}
+%\begin{eqnarray*}
+% && {\testupper}
+%\end{eqnarray*}%
+
+%Fraktur (\texttt{\string\mathfrak})
+%\def\test#1{\mathfrak{#1},}
+%\begin{eqnarray*}
+% && {\testupper}\\
+% && {\testlower}
+%\end{eqnarray*}%
+
+%Blackboard Bold (\texttt{\string\mathbb})
+%\def\test#1{\mathbb{#1},}
+%\begin{eqnarray*}
+% && {\testupper}
+%\end{eqnarray*}%
+
+
+\clearpage
+\section{Character Sidebearings}
+
+\def\test#1{|#1|+}
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}%
+%
+\def\test#1{|\mathrm{#1}|+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+%\def\test#1{|\mathbm{#1}|+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}\\
+% && {\testlowgreeki}\\
+% && {\testlowgreekii}\\
+% && {\testlowgreekiii}
+%\end{eqnarray*}%
+%%
+%\def\test#1{|\mathbf{#1}|+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}
+%\end{eqnarray*}%
+%
+\def\test#1{|\mathcal{#1}|+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Superscript positioning}
+
+\def\test#1{#1^{2}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}%
+%
+\def\test#1{\mathrm{#1}^{2}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+%\def\test#1{\mathbm{#1}^{2}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}\\
+% && {\testlowgreeki}\\
+% && {\testlowgreekii}\\
+% && {\testlowgreekiii}
+%\end{eqnarray*}%
+%
+%\def\test#1{\mathbf{#1}^{2}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}
+%\end{eqnarray*}
+%
+\def\test#1{\mathcal{#1}^{2}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Subscript positioning}
+
+\def\test#1{\mathnormal{#1}_{i}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}%
+%
+\def\test#1{\mathrm{#1}_{i}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+%\def\test#1{\mathbm{#1}_{i}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}\\
+% && {\testlowgreeki}\\
+% && {\testlowgreekii}\\
+% && {\testlowgreekiii}
+%\end{eqnarray*}
+%%
+%\def\test#1{\mathbf{#1}_{i}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}
+%\end{eqnarray*}%
+%
+\def\test#1{\mathcal{#1}_{i}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Accent positioning}
+
+\def\test#1{\hat{#1}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}%
+%
+\def\test#1{\hat{\mathrm{#1}}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+%\def\test#1{\hat{\mathbm{#1}}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}\\
+% && {\testlowgreeki}\\
+% && {\testlowgreekii}\\
+% && {\testlowgreekiii}
+%\end{eqnarray*}%
+%%
+%\def\test#1{\hat{\mathbf{#1}}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}
+%\end{eqnarray*}
+%
+\def\test#1{\hat{\mathcal{#1}}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Differentials}
+
+\begin{eqnarray*}
+\gdef\test#1{\dit #1+}%
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}\\
+\gdef\test#1{\dit \mathrm{#1}+}%
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+\begin{eqnarray*}
+\gdef\test#1{\dup #1+}%
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}\\
+\gdef\test#1{\dup \mathrm{#1}+}%
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+\begin{eqnarray*}
+\gdef\test#1{\partial #1+}%
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}\\
+\gdef\test#1{\partial \mathrm{#1}+}%
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Slash kerning}
+
+\def\test#1{1/#1+}
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}
+
+\def\test#1{#1/2+}
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}
+
+
+\clearpage
+\section{Big operators}
+
+\def\testop#1{#1_{i=1}^{n} x^{n} \quad}
+\begin{displaymath}
+ \testop\sum
+ \testop\prod
+ \testop\coprod
+ \testop\int
+ \testop\oint
+\end{displaymath}
+\begin{displaymath}
+ \testop\bigotimes
+ \testop\bigoplus
+ \testop\bigodot
+ \testop\bigwedge
+ \testop\bigvee
+ \testop\biguplus
+ \testop\bigcup
+ \testop\bigcap
+ \testop\bigsqcup
+% \testop\bigsqcap
+\end{displaymath}
+
+
+\section{Radicals}
+
+\begin{displaymath}
+ \sqrt{x+y} \qquad \sqrt{x^{2}+y^{2}} \qquad
+ \sqrt{x_{i}^{2}+y_{j}^{2}} \qquad
+ \sqrt{\left(\frac{\cos x}{2}\right)} \qquad
+ \sqrt{\left(\frac{\sin x}{2}\right)}
+\end{displaymath}
+
+\begingroup
+\delimitershortfall-1pt
+\begin{displaymath}
+ \sqrt{\sqrt{\sqrt{\sqrt{\sqrt{\sqrt{\sqrt{x+y}}}}}}}
+\end{displaymath}
+\endgroup % \delimitershortfall
+
+
+\section{Over- and underbraces}
+
+\begin{displaymath}
+ \overbrace{x} \quad
+ \overbrace{x+y} \quad
+ \overbrace{x^{2}+y^{2}} \quad
+ \overbrace{x_{i}^{2}+y_{j}^{2}} \quad
+ \underbrace{x} \quad
+ \underbrace{x+y} \quad
+ \underbrace{x_{i}+y_{j}} \quad
+ \underbrace{x_{i}^{2}+y_{j}^{2}} \quad
+\end{displaymath}
+
+
+\section{Normal and wide accents}
+
+\begin{displaymath}
+ \dot{x} \quad
+ \ddot{x} \quad
+ \vec{x} \quad
+ \bar{x} \quad
+ \overline{x} \quad
+ \overline{xx} \quad
+ \tilde{x} \quad
+ \widetilde{x} \quad
+ \widetilde{xx} \quad
+ \widetilde{xxx} \quad
+ \hat{x} \quad
+ \widehat{x} \quad
+ \widehat{xx} \quad
+ \widehat{xxx} \quad
+\end{displaymath}
+
+
+\section{Long arrows}
+
+\begin{displaymath}
+ \leftarrow \mathrel{-} \rightarrow \quad
+ \leftrightarrow \quad
+ \longleftarrow \quad
+ \longrightarrow \quad
+ \longleftrightarrow \quad
+ \Leftarrow = \Rightarrow \quad
+ \Leftrightarrow \quad
+ \Longleftarrow \quad
+ \Longrightarrow \quad
+ \Longleftrightarrow \quad
+\end{displaymath}
+
+
+\section{Left and right delimters}
+
+\def\testdelim#1#2{ - #1 f #2 - }
+\begin{displaymath}
+ \testdelim()
+ \testdelim[]
+ \testdelim\lfloor\rfloor
+ \testdelim\lceil\rceil
+ \testdelim\langle\rangle
+ \testdelim\{\}
+\end{displaymath}
+
+\def\testdelim#1#2{ - \left#1 f \right#2 - }
+\begin{displaymath}
+ \testdelim()
+ \testdelim[]
+ \testdelim\lfloor\rfloor
+ \testdelim\lceil\rceil
+ \testdelim\langle\rangle
+ \testdelim\{\}
+% \testdelim\lgroup\rgroup
+% \testdelim\lmoustache\rmoustache
+\end{displaymath}
+\begin{displaymath}
+ \testdelim)(
+ \testdelim][
+ \testdelim//
+ \testdelim\backslash\backslash
+ \testdelim/\backslash
+ \testdelim\backslash/
+\end{displaymath}
+
+
+\clearpage
+\section{Big-g-g delimters}
+
+\def\testdelim#1#2{%
+ - \left#1\left#1\left#1\left#1\left#1\left#1\left#1\left#1 -
+ \right#2\right#2\right#2\right#2\right#2\right#2\right#2\right#2 -}
+
+\begingroup
+\delimitershortfall-1pt
+\begin{displaymath}
+ \testdelim\lfloor\rfloor
+ \qquad
+ \testdelim()
+\end{displaymath}
+\begin{displaymath}
+ \testdelim\lceil\rceil
+ \qquad
+ \testdelim\{\}
+\end{displaymath}
+\begin{displaymath}
+ \testdelim[]
+ \qquad
+ \testdelim\lgroup\rgroup
+\end{displaymath}
+\begin{displaymath}
+ \testdelim\langle\rangle
+ \qquad
+ \testdelim\lmoustache\rmoustache
+\end{displaymath}
+\begin{displaymath}
+ \testdelim\uparrow\downarrow \quad
+ \testdelim\Uparrow\Downarrow \quad
+\end{displaymath}
+\endgroup % \delimitershortfall
+
+
+
+\end{document}
+
+%%% Local Variables:
+%%% mode: latex
+%%% TeX-master: t
+%%% End:
diff --git a/fonts/utilities/fontinst/examples/mathptm/resetsy.mtx b/fonts/utilities/fontinst/examples/mathptm/resetsy.mtx
new file mode 100644
index 0000000000..27da54c046
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/resetsy.mtx
@@ -0,0 +1,30 @@
+\relax
+
+\metrics
+
+\unsetglyph{Upsilon}
+\setglyph{Upsilon}
+ \glyph{Upsilon1}{1000}
+\endsetglyph
+
+\setglyph{pi1}
+ \glyph{omega1}{1000}
+\endsetglyph
+
+\setglyph{epsilon1}
+ \glyph{epsilon}{1000}
+\endsetglyph
+
+\setglyph{rho1}
+ \glyph{rho}{1000}
+\endsetglyph
+
+\setglyph{dotlessj}
+ \moveup{\neg{\depth{j}}}
+ \glyphrule{\width{j}}{\add{\depth{j}}{\height{dotlessi}}}
+ \resetitalic{\italic{dotlessi}}
+ \moveup{\depth{j}}
+ \glyphwarning{missing glyph `dotlessj'}
+\endsetglyph
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptm/unsetmu.mtx b/fonts/utilities/fontinst/examples/mathptm/unsetmu.mtx
new file mode 100644
index 0000000000..63b222ed9f
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/unsetmu.mtx
@@ -0,0 +1,7 @@
+\relax
+
+\metrics
+
+\unsetglyph{mu}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptm/zrhax.mtx b/fonts/utilities/fontinst/examples/mathptm/zrhax.mtx
new file mode 100644
index 0000000000..ce1bc5a281
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/zrhax.mtx
@@ -0,0 +1,15 @@
+\relax
+
+\metrics
+
+% This metrics file is loaded after having read the Times-Roman
+% glyphs. We unset those glyphs that should be taken from cmr.
+
+\unsetglyph{plus}
+\unsetglyph{equal}
+\unsetglyph{parenleft}
+\unsetglyph{parenright}
+\unsetglyph{bracketleft}
+\unsetglyph{bracketright}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptm/zrmhax.mtx b/fonts/utilities/fontinst/examples/mathptm/zrmhax.mtx
new file mode 100644
index 0000000000..141899c6dc
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/zrmhax.mtx
@@ -0,0 +1,14 @@
+\relax
+
+\metrics
+
+% This metrics file is loaded after having read the Times-Italic
+% glyphs. We unset those glyphs that should be taken from cmmi.
+
+\unsetglyph{period}
+\unsetglyph{comma}
+\unsetglyph{less}
+\unsetglyph{slash}
+\unsetglyph{greater}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptm/zrmkern.mtx b/fonts/utilities/fontinst/examples/mathptm/zrmkern.mtx
new file mode 100644
index 0000000000..62ccd50a84
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/zrmkern.mtx
@@ -0,0 +1,158 @@
+\relax
+
+% The following adjustments (as originally derived by Alan Jeffrey)
+% are tuned for Times-Italic and non-oblique Adobe Symbol.
+
+\metrics
+
+\needsfontinstversion{1.800}
+
+% \shiftglyph takes four parameters:
+%
+% #1 the name of the glyph
+% #2 the amount of extra space at the left
+% #3 the amount of extra space at the right
+% #4 the amount of extra space for subscripts
+
+\setcommand\shiftglyph#1#2#3#4{
+ \resetglyph{#1}
+ \movert{#2}
+ \glyph{#1}{1000}
+ \movert{#4}
+ \resetitalic{\add{\italic{#1}}{\sub{#3}{#4}}}
+ \endresetglyph
+}
+
+% \skewkern sets a skewchar kern, assuming that `tie'
+% is the skewchar.
+%
+% #1 the name of the glyph
+% #2 the amount of skewchar kerning
+
+\setcommand\skewkern#1#2{\setkern{#1}{tie}{#2}}
+
+
+% A
+% B
+\shiftglyph{C}{-50}{0}{-25}
+% D
+\shiftglyph{E}{0}{50}{0}
+\shiftglyph{F}{0}{50}{-100}
+% G
+\shiftglyph{H}{0}{25}{-25}
+\shiftglyph{I}{0}{0}{-25}
+\shiftglyph{J}{0}{0}{-25}
+\shiftglyph{K}{0}{0}{-25}
+% L
+% M
+\shiftglyph{N}{0}{0}{-25}
+% O
+\shiftglyph{P}{0}{0}{-100}
+% Q
+% R
+% S
+\shiftglyph{T}{0}{50}{-75}
+\shiftglyph{U}{-50}{50}{-25}
+\shiftglyph{V}{-50}{50}{-50}
+\shiftglyph{W}{-50}{50}{-50}
+\shiftglyph{X}{0}{50}{-25}
+\shiftglyph{Y}{-50}{50}{-50}
+% Z
+
+% a
+\shiftglyph{b}{0}{-25}{0}
+% c
+\shiftglyph{d}{0}{25}{0}
+% e
+\shiftglyph{f}{150}{0}{25}
+\shiftglyph{g}{0}{-50}{0}
+% h
+% i
+\shiftglyph{j}{150}{25}{0}
+% k
+\shiftglyph{l}{0}{50}{0}
+% m
+% n
+\shiftglyph{o}{0}{-50}{0}
+\shiftglyph{p}{75}{-25}{0}
+% q
+% r
+% s
+\shiftglyph{t}{-25}{50}{0}
+% u
+% v
+% w
+% x
+% y
+% z
+
+\shiftglyph{Upsilon}{0}{0}{-150} % was: -50 -100, adds up to -150
+\shiftglyph{weierstrass}{-100}{-200}{-150}
+
+\skewkern{A}{75}
+\skewkern{B}{100}
+\skewkern{C}{100}
+\skewkern{D}{50}
+\skewkern{E}{75}
+\skewkern{F}{75}
+\skewkern{G}{100}
+\skewkern{H}{50}
+\skewkern{I}{100}
+\skewkern{J}{200}
+\skewkern{K}{75}
+% L
+\skewkern{M}{100}
+\skewkern{N}{25}
+\skewkern{O}{100}
+\skewkern{P}{100}
+\skewkern{Q}{100}
+\skewkern{R}{100}
+\skewkern{S}{100}
+\skewkern{T}{50}
+\skewkern{U}{50}
+\skewkern{X}{50}
+\skewkern{Z}{50}
+
+\skewkern{a}{75}
+% b
+\skewkern{c}{75}
+\skewkern{d}{200}
+\skewkern{e}{75}
+\skewkern{f}{150}
+\skewkern{g}{75}
+% h
+\skewkern{i}{75}
+\skewkern{j}{150}
+% k
+\skewkern{l}{100}
+\skewkern{m}{50}
+\skewkern{n}{50}
+\skewkern{o}{75}
+\skewkern{p}{100}
+\skewkern{q}{75}
+\skewkern{r}{50}
+\skewkern{s}{100}
+\skewkern{t}{50}
+\skewkern{u}{75}
+\skewkern{v}{75}
+\skewkern{w}{75}
+\skewkern{x}{75}
+\skewkern{y}{75}
+\skewkern{z}{50}
+
+\skewkern{dotlessi}{50}
+\skewkern{dotlessj}{50}
+
+\skewkern{upsilon}{25}
+\skewkern{iota}{-50}
+\skewkern{lambda}{-75}
+\skewkern{weierstrass}{175}
+\skewkern{lscript}{125}
+
+\resetglyph{vector}
+ \movert{-100}
+ \glyph{vector}{1000}
+ \movert{100}
+\endresetglyph
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptm/zrvhax.mtx b/fonts/utilities/fontinst/examples/mathptm/zrvhax.mtx
new file mode 100644
index 0000000000..6270feb615
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/zrvhax.mtx
@@ -0,0 +1,73 @@
+\relax
+
+% This metrics file is loaded after having read the cmex glyps.
+% We unset the big operators that should be taken from Symbol
+% or from a scaled-down version of cmex.
+
+\metrics
+
+\setint{psy-textscale}{1000}
+\setint{psy-displayscale}{1440}
+
+\unsetglyph{circledotdisplay}
+\unsetglyph{circledottext}
+\unsetglyph{circlemultiplydisplay}
+\unsetglyph{circlemultiplytext}
+\unsetglyph{circleplusdisplay}
+\unsetglyph{circleplustext}
+\unsetglyph{contintegraldisplay}
+\unsetglyph{contintegraltext}
+\unsetglyph{integraldisplay}
+\unsetglyph{integraltext}
+\unsetglyph{intersectiondisplay}
+\unsetglyph{intersectiontext}
+\unsetglyph{logicalanddisplay}
+\unsetglyph{logicalandtext}
+\unsetglyph{logicalordisplay}
+\unsetglyph{logicalortext}
+\unsetglyph{uniondisplay}
+\unsetglyph{unionmultidisplay}
+\unsetglyph{unionmultitext}
+\unsetglyph{unionsqdisplay}
+\unsetglyph{unionsqtext}
+\unsetglyph{uniontext}
+
+\resetglyph{summationtext}
+ \glyph{summation}{\int{psy-textscale}}
+\endresetglyph
+
+\resetglyph{summationdisplay}
+ \glyph{summation}{\int{psy-displayscale}}
+\endresetglyph
+
+\resetglyph{producttext}
+ \glyph{product}{\int{psy-textscale}}
+\endresetglyph
+
+\resetglyph{productdisplay}
+ \glyph{product}{\int{psy-displayscale}}
+\endresetglyph
+
+\resetglyph{coproducttext}
+ \moveup{\neg{\depth{producttext}}}
+ \glyphrule{
+ \width{producttext}
+ }{
+ \add{\height{producttext}}{\depth{producttext}}
+ }
+ \moveup{\depth{producttext}}
+ \glyphwarning{missing glyph `coproducttext'}
+\endresetglyph
+
+\resetglyph{coproductdisplay}
+ \moveup{\neg{\depth{productdisplay}}}
+ \glyphrule{
+ \width{productdisplay}
+ }{
+ \add{\height{productdisplay}}{\depth{productdisplay}}
+ }
+ \moveup{\depth{productdisplay}}
+ \glyphwarning{missing glyph `coproductdisplay'}
+\endresetglyph
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptm/zryhax.mtx b/fonts/utilities/fontinst/examples/mathptm/zryhax.mtx
new file mode 100644
index 0000000000..19addd6ad8
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptm/zryhax.mtx
@@ -0,0 +1,26 @@
+\relax
+
+\metrics
+
+% This metrics file is loaded after having read the cmsy glyphs.
+% We unset those glyphs that should be taken from Times or Symbol.
+
+\unsetglyph{infinity}
+\unsetglyph{proportional}
+
+\unsetglyph{emptysetstress}
+
+\unsetglyph{Rfraktur}
+\unsetglyph{Ifraktur}
+
+\unsetglyph{aleph}
+
+\unsetglyph{coproduct}
+\unsetglyph{gradient}
+
+\unsetglyph{section}
+\unsetglyph{dagger}
+\unsetglyph{daggerdbl}
+\unsetglyph{paragraph}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptmx/Makefile b/fonts/utilities/fontinst/examples/mathptmx/Makefile
new file mode 100644
index 0000000000..37a660e0cb
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/Makefile
@@ -0,0 +1,23 @@
+ZAP= cmex10.mtx cmr10.mtx cmmi10.mtx cmsy10.mtx \
+ rsfs10.mtx psyr.mtx psyr.pl psyro.mtx psyro.pl \
+ ptmr8a.mtx ptmr8a.pl ptmr8r.mtx ptmr8r.pl \
+ ptmri8a.mtx ptmri8a.pl ptmri8r.mtx ptmri8r.pl \
+ zptmcm7t.vpl zptmcm7m.vpl zptmcm7y.vpl zptmcm7v.vpl \
+ fontptcmx.log
+
+all: tex vfs
+
+tex:
+ tex fontptcmx
+
+vfs:
+ vptovf zptmcm7t.vpl zptmcm7t.vf zptmcm7t.tfm
+ vptovf zptmcm7m.vpl zptmcm7m.vf zptmcm7m.tfm
+ vptovf zptmcm7y.vpl zptmcm7y.vf zptmcm7y.tfm
+ vptovf zptmcm7v.vpl zptmcm7v.vf zptmcm7v.tfm
+
+clean:
+ -rm $(ZAP) *.log
+
+realclean: clean
+ -rm p*tfm z*.tfm *.vf *.fd
diff --git a/fonts/utilities/fontinst/examples/mathptmx/fontptcmx.tex b/fonts/utilities/fontinst/examples/mathptmx/fontptcmx.tex
new file mode 100644
index 0000000000..0f876ce345
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/fontptcmx.tex
@@ -0,0 +1,76 @@
+%%% ====================================================================
+%%% @TeX-file{
+%%% author = "Alan Jeffrey and Sebastian Rathz and
+%%% Ulrik Vieth",
+%%% version = "1.802",
+%%% date = "01 July 1998",
+%%% time = "10:57:48 MET DST",
+%%% filename = "fontzcmtmx.tex",
+%%% email = "vieth@thphy.uni-duesseldorf.de",
+%%% URL = "http://www.thphy.uni-duesseldorf.de/~vieth/",
+%%% checksum = "49508 76 251 3044",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "font installation example",
+%%% supported = "yes",
+%%% abstract = "This is an example program which uses
+%%% Adobe Times, Adobe Symbol and Computer
+%%% Modern fonts to build Times math fonts.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, ptmr8a.afm, ptmri8a.afm,
+%%% pzcmi8a.afm, psyr.afm, cmr10.pl,
+%%% cmmi10.pl, cmsy10.pl, cmex10.pl,
+%%% mathit.mtx, mathsy.mtx, mathex.mtx,
+%%% zrhax.mtx, zrmhax.mtx, zrvhax.mtx,
+%%% zrmkern.mtx, unsethum.mtx, unsetalf.mtx,
+%%% resetsy.mtx, kernoff.mtx, kernon.mtx",
+%%% }
+%%% ====================================================================
+
+% Math fonts built from Times, Symbol, RSFS and CM math.
+
+\input fontinst.sty
+
+\needsfontinstversion{1.800}
+
+\declareencoding{RAS SCRIPT}{rsfs}
+
+\installfonts
+ \transformfont{ptmr8r} {\reencodefont{8r}{\fromafm{ptmr8a}}}
+ \transformfont{ptmri8r}{\reencodefont{8r}{\fromafm{ptmri8a}}}
+ \transformfont{psyro} {\slantfont{167}{\fromafm{psyr}}}
+
+ % OT1: Latin and digits from Times-Roman, Greek from Symbol,
+ % accents and punctuation from Times, delimiters from cmr10
+ \installfamily{OT1}{ztmcm}{}
+ \installfont{zptmcm7t}
+ {ptmr8r,psyr,resetsy,latin,%
+ zrhax,kernoff,cmr10,kernon}
+ {OT1}{OT1}{ztmcm}{m}{n}{}
+
+ % OML: Latin from Times-Italic, Greek from Symbol (oblique),
+ % operators, delimiters and puctuation from cmmi10
+ \installfamily{OML}{ztmcm}{\skewchar\font=127}
+ \installfont{zptmcm7m}
+ {ptmri8r,unsetmu,psyro,resetsy,%
+ zrmhax,kernoff,cmmi10,kernon,%
+ mathit,zrmkernx}
+ {OML}{OML}{ztmcm}{m}{it}{}
+
+ % OMS: Humanist symbols from Times-Roman and Symbol,
+ % Script alphabet from Ralph Smith's Formal Script,
+ % operators, delimiters and arrows from cmsy10
+ \installfamily{OMS}{ztmcm}{\skewchar\font=48}
+ \installfont{zptmcm7y}
+ {kernoff,cmsy10,kernon,zryhax,ptmr8r,psyr,%
+ unsetalf,rsfs10,zrykernx,mathsy}
+ {OMS}{OMS}{ztmcm}{m}{n}{}
+
+ % OMX: summation and product from psyr, bigops from scaled cmex10,
+ % delimiters, radicals and arrows from cmex10
+ \installfamily{OMX}{ztmcm}{}
+ \installfont{zptmcm7v}
+ {cmex10,psyr,zrvhax,cmex10 scaled 900}
+ {OMX}{OMX}{ztmcm}{m}{n}{}
+
+\endinstallfonts
+\end
diff --git a/fonts/utilities/fontinst/examples/mathptmx/mathptmx.sty b/fonts/utilities/fontinst/examples/mathptmx/mathptmx.sty
new file mode 100644
index 0000000000..068bddd65c
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/mathptmx.sty
@@ -0,0 +1,42 @@
+\def\filedate{1998/06/30}
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{mathptmx}[\filedate\space
+ Times + math package from fontinst]
+\def\rmdefault{ptm}
+\DeclareSymbolFont{operators} {OT1}{ztmcm}{m}{n}
+\DeclareSymbolFont{letters} {OML}{ztmcm}{m}{it}
+\DeclareSymbolFont{symbols} {OMS}{ztmcm}{m}{n}
+\DeclareSymbolFont{largesymbols}{OMX}{ztmcm}{m}{n}
+\DeclareSymbolFont{bold} {OT1}{ptm}{bx}{n}
+\DeclareSymbolFont{italic} {OT1}{ptm}{m}{it}
+\@ifundefined{mathbf}{}{\DeclareMathAlphabet{\mathbf}{OT1}{ptm}{bx}{n}}
+\@ifundefined{mathit}{}{\DeclareMathAlphabet{\mathit}{OT1}{ptm}{m}{it}}
+\DeclareMathSymbol{\omicron}{0}{operators}{`\o}
+\thinmuskip=2mu
+\medmuskip=2.5mu plus 1mu minus 1mu
+\thickmuskip=4mu plus 1.5mu minus 1mu
+ \let\@tempa\version@elt
+ \def\version@elt#1{%
+ \ifx\mv@bold#1\else\noexpand\version@elt\noexpand#1\fi}
+ \edef\version@list{\version@list}
+ \let\version@elt\@tempa
+ \let\mv@bold\@undefined
+\def\boldmath{%
+ \PackageWarning{there is no bold Symbol font}%
+ \global\let\boldmath=\relax
+}
+\DeclareMathSizes{5}{5}{5}{5}
+\DeclareMathSizes{6}{6}{5}{5}
+\DeclareMathSizes{7}{7}{5}{5}
+\DeclareMathSizes{8}{8}{6}{5}
+\DeclareMathSizes{9}{9}{7}{5}
+\DeclareMathSizes{10}{10}{7.4}{6}
+\DeclareMathSizes{10.95}{10.95}{8}{6}
+\DeclareMathSizes{12}{12}{9}{7}
+\DeclareMathSizes{14.4}{14.4}{10.95}{8}
+\DeclareMathSizes{17.28}{17.28}{12}{10}
+\DeclareMathSizes{20.74}{20.74}{14.4}{12}
+\DeclareMathSizes{24.88}{24.88}{17.28}{14.4}
+\endinput
+%%
+%% End of file `mathptmx.sty'.
diff --git a/fonts/utilities/fontinst/examples/mathptmx/mathtestx.tex b/fonts/utilities/fontinst/examples/mathptmx/mathtestx.tex
new file mode 100644
index 0000000000..8f3342ea7c
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/mathtestx.tex
@@ -0,0 +1,643 @@
+\documentclass[fleqn]{article}
+\usepackage{mathptmx}
+
+\DeclareMathSymbol{\Gamma} {\mathalpha}{letters}{"00}
+\DeclareMathSymbol{\Delta} {\mathalpha}{letters}{"01}
+\DeclareMathSymbol{\Theta} {\mathalpha}{letters}{"02}
+\DeclareMathSymbol{\Lambda} {\mathalpha}{letters}{"03}
+\DeclareMathSymbol{\Xi} {\mathalpha}{letters}{"04}
+\DeclareMathSymbol{\Pi} {\mathalpha}{letters}{"05}
+\DeclareMathSymbol{\Sigma} {\mathalpha}{letters}{"06}
+\DeclareMathSymbol{\Upsilon}{\mathalpha}{letters}{"07}
+\DeclareMathSymbol{\Phi} {\mathalpha}{letters}{"08}
+\DeclareMathSymbol{\Psi} {\mathalpha}{letters}{"09}
+\DeclareMathSymbol{\Omega} {\mathalpha}{letters}{"0A}
+
+\DeclareMathSymbol{\alpha} {\mathalpha}{letters}{"0B}
+\DeclareMathSymbol{\beta} {\mathalpha}{letters}{"0C}
+\DeclareMathSymbol{\gamma} {\mathalpha}{letters}{"0D}
+\DeclareMathSymbol{\delta} {\mathalpha}{letters}{"0E}
+\DeclareMathSymbol{\epsilon}{\mathalpha}{letters}{"0F}
+\DeclareMathSymbol{\zeta} {\mathalpha}{letters}{"10}
+\DeclareMathSymbol{\eta} {\mathalpha}{letters}{"11}
+\DeclareMathSymbol{\theta} {\mathalpha}{letters}{"12}
+\DeclareMathSymbol{\iota} {\mathalpha}{letters}{"13}
+\DeclareMathSymbol{\kappa} {\mathalpha}{letters}{"14}
+\DeclareMathSymbol{\lambda} {\mathalpha}{letters}{"15}
+\DeclareMathSymbol{\mu} {\mathalpha}{letters}{"16}
+\DeclareMathSymbol{\nu} {\mathalpha}{letters}{"17}
+\DeclareMathSymbol{\xi} {\mathalpha}{letters}{"18}
+\DeclareMathSymbol{\pi} {\mathalpha}{letters}{"19}
+\DeclareMathSymbol{\rho} {\mathalpha}{letters}{"1A}
+\DeclareMathSymbol{\sigma} {\mathalpha}{letters}{"1B}
+\DeclareMathSymbol{\tau} {\mathalpha}{letters}{"1C}
+\DeclareMathSymbol{\upsilon}{\mathalpha}{letters}{"1D}
+\DeclareMathSymbol{\phi} {\mathalpha}{letters}{"1E}
+\DeclareMathSymbol{\chi} {\mathalpha}{letters}{"1F}
+\DeclareMathSymbol{\psi} {\mathalpha}{letters}{"20}
+\DeclareMathSymbol{\omega} {\mathalpha}{letters}{"21}
+\DeclareMathSymbol{\varepsilon} {\mathalpha}{letters}{"22}
+\DeclareMathSymbol{\vartheta} {\mathalpha}{letters}{"23}
+\DeclareMathSymbol{\varpi} {\mathalpha}{letters}{"24}
+\DeclareMathSymbol{\varrho} {\mathalpha}{letters}{"25}
+\DeclareMathSymbol{\varsigma} {\mathalpha}{letters}{"26}
+\DeclareMathSymbol{\varphi} {\mathalpha}{letters}{"27}
+
+\DeclareMathSymbol{\dit}{\mathord}{letters}{`d}
+\DeclareMathSymbol{\dup}{\mathord}{operators}{`d}
+
+\nofiles
+
+\parindent 0pt
+\mathindent 1em
+
+\def\test#1{#1}
+
+\def\testnums{%
+ \test 0 \test 1 \test 2 \test 3 \test 4 \test 5 \test 6 \test 7
+ \test 8 \test 9 }
+\def\testupperi{%
+ \test A \test B \test C \test D \test E \test F \test G \test H
+ \test I \test J \test K \test L \test M }
+\def\testupperii{%
+ \test N \test O \test P \test Q \test R \test S \test T \test U
+ \test V \test W \test X \test Y \test Z }
+\def\testupper{%
+ \testupperi\testupperii}
+
+\def\testloweri{%
+ \test a \test b \test c \test d \test e \test f \test g \test h
+ \test i \test j \test k \test l \test m }
+\def\testlowerii{%
+ \test n \test o \test p \test q \test r \test s \test t \test u
+ \test v \test w \test x \test y \test z
+ \test\imath \test\jmath }
+\def\testlower{%
+ \testloweri\testlowerii}
+
+\def\testupgreeki{%
+ \test A \test B \test\Gamma \test\Delta \test E \test Z \test H
+ \test\Theta \test I \test K \test\Lambda \test M }
+\def\testupgreekii{%
+ \test N \test\Xi \test O \test\Pi \test P \test\Sigma \test T
+ \test\Upsilon \test\Phi \test X \test\Psi \test\Omega
+ \test\nabla }
+\def\testupgreek{%
+ \testupgreeki\testupgreekii}
+
+\def\testlowgreeki{%
+ \test\alpha \test\beta \test\gamma \test\delta \test\epsilon
+ \test\zeta \test\eta \test\theta \test\iota \test\kappa \test\lambda
+ \test\mu }
+\def\testlowgreekii{%
+ \test\nu \test\xi \test o \test\pi \test\rho \test\sigma \test\tau
+ \test\upsilon \test\phi \test\chi \test\psi \test\omega }
+\def\testlowgreekiii{%
+ \test\varepsilon \test\vartheta \test\varpi \test\varrho
+ \test\varsigma \test\varphi}
+\def\testlowgreek{%
+ \testlowgreeki\testlowgreekii\testlowgreekiii}
+
+
+\begin{document}
+
+\section{Math Alphabets}
+
+Math Italic (\texttt{\string\mathnormal})
+\def\test#1{\mathnormal{#1},}
+\begin{eqnarray*}
+ && {\testnums}\\
+ && {\testupper}\\
+ && {\testlower}\\
+ && {\testupgreek}\\
+ && {\testlowgreek}
+\end{eqnarray*}%
+
+Math Roman (\texttt{\string\mathrm})
+\def\test#1{\mathrm{#1},}
+\begin{eqnarray*}
+ && {\testnums}\\
+ && {\testupper}\\
+ && {\testlower}\\
+ && {\testupgreek}
+\end{eqnarray*}%
+
+%Math Italic Bold
+%\def\test#1{\mathbm{#1},}
+%\begin{eqnarray*}
+% && {\testnums}\\
+% && {\testupper}\\
+% && {\testlower}\\
+% && {\testupgreek}\\
+% && {\testlowgreek}
+%\end{eqnarray*}%
+
+%Math Bold (\texttt{\string\mathbf})
+%\def\test#1{\mathbf{#1},}
+%\begin{eqnarray*}
+% && {\testnums}\\
+% && {\testupper}\\
+% && {\testlower}\\
+% && {\testupgreek}
+%\end{eqnarray*}%
+
+Caligraphic (\texttt{\string\mathcal})
+\def\test#1{\mathcal{#1},}
+\begin{eqnarray*}
+ && {\testupper}
+\end{eqnarray*}%
+
+%Script (\texttt{\string\mathscr})
+%\def\test#1{\mathscr{#1},}
+%\begin{eqnarray*}
+% && {\testupper}
+%\end{eqnarray*}%
+
+%Fraktur (\texttt{\string\mathfrak})
+%\def\test#1{\mathfrak{#1},}
+%\begin{eqnarray*}
+% && {\testupper}\\
+% && {\testlower}
+%\end{eqnarray*}%
+
+%Blackboard Bold (\texttt{\string\mathbb})
+%\def\test#1{\mathbb{#1},}
+%\begin{eqnarray*}
+% && {\testupper}
+%\end{eqnarray*}%
+
+
+\clearpage
+\section{Character Sidebearings}
+
+\def\test#1{|#1|+}
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}%
+%
+\def\test#1{|\mathrm{#1}|+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+%\def\test#1{|\mathbm{#1}|+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}\\
+% && {\testlowgreeki}\\
+% && {\testlowgreekii}\\
+% && {\testlowgreekiii}
+%\end{eqnarray*}%
+%%
+%\def\test#1{|\mathbf{#1}|+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}
+%\end{eqnarray*}%
+%
+\def\test#1{|\mathcal{#1}|+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Superscript positioning}
+
+\def\test#1{#1^{2}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}%
+%
+\def\test#1{\mathrm{#1}^{2}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+%\def\test#1{\mathbm{#1}^{2}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}\\
+% && {\testlowgreeki}\\
+% && {\testlowgreekii}\\
+% && {\testlowgreekiii}
+%\end{eqnarray*}%
+%
+%\def\test#1{\mathbf{#1}^{2}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}
+%\end{eqnarray*}
+%
+\def\test#1{\mathcal{#1}^{2}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Subscript positioning}
+
+\def\test#1{\mathnormal{#1}_{i}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}%
+%
+\def\test#1{\mathrm{#1}_{i}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+%\def\test#1{\mathbm{#1}_{i}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}\\
+% && {\testlowgreeki}\\
+% && {\testlowgreekii}\\
+% && {\testlowgreekiii}
+%\end{eqnarray*}
+%%
+%\def\test#1{\mathbf{#1}_{i}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}
+%\end{eqnarray*}%
+%
+\def\test#1{\mathcal{#1}_{i}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Accent positioning}
+
+\def\test#1{\hat{#1}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}%
+%
+\def\test#1{\hat{\mathrm{#1}}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+%\def\test#1{\hat{\mathbm{#1}}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}\\
+% && {\testlowgreeki}\\
+% && {\testlowgreekii}\\
+% && {\testlowgreekiii}
+%\end{eqnarray*}%
+%%
+%\def\test#1{\hat{\mathbf{#1}}+}%
+%\begin{eqnarray*}
+% && {\testupperi}\\
+% && {\testupperii}\\
+% && {\testloweri}\\
+% && {\testlowerii}\\
+% && {\testupgreeki}\\
+% && {\testupgreekii}
+%\end{eqnarray*}
+%
+\def\test#1{\hat{\mathcal{#1}}+}%
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Differentials}
+
+\begin{eqnarray*}
+\gdef\test#1{\dit #1+}%
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}\\
+\gdef\test#1{\dit \mathrm{#1}+}%
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+\begin{eqnarray*}
+\gdef\test#1{\dup #1+}%
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}\\
+\gdef\test#1{\dup \mathrm{#1}+}%
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+%
+\begin{eqnarray*}
+\gdef\test#1{\partial #1+}%
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}\\
+\gdef\test#1{\partial \mathrm{#1}+}%
+ && {\testupgreeki}\\
+ && {\testupgreekii}
+\end{eqnarray*}%
+
+
+\clearpage
+\section{Slash kerning}
+
+\def\test#1{1/#1+}
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}
+
+\def\test#1{#1/2+}
+\begin{eqnarray*}
+ && {\testupperi}\\
+ && {\testupperii}\\
+ && {\testloweri}\\
+ && {\testlowerii}\\
+ && {\testupgreeki}\\
+ && {\testupgreekii}\\
+ && {\testlowgreeki}\\
+ && {\testlowgreekii}\\
+ && {\testlowgreekiii}
+\end{eqnarray*}
+
+
+\clearpage
+\section{Big operators}
+
+\def\testop#1{#1_{i=1}^{n} x^{n} \quad}
+\begin{displaymath}
+ \testop\sum
+ \testop\prod
+ \testop\coprod
+ \testop\int
+ \testop\oint
+\end{displaymath}
+\begin{displaymath}
+ \testop\bigotimes
+ \testop\bigoplus
+ \testop\bigodot
+ \testop\bigwedge
+ \testop\bigvee
+ \testop\biguplus
+ \testop\bigcup
+ \testop\bigcap
+ \testop\bigsqcup
+% \testop\bigsqcap
+\end{displaymath}
+
+
+\section{Radicals}
+
+\begin{displaymath}
+ \sqrt{x+y} \qquad \sqrt{x^{2}+y^{2}} \qquad
+ \sqrt{x_{i}^{2}+y_{j}^{2}} \qquad
+ \sqrt{\left(\frac{\cos x}{2}\right)} \qquad
+ \sqrt{\left(\frac{\sin x}{2}\right)}
+\end{displaymath}
+
+\begingroup
+\delimitershortfall-1pt
+\begin{displaymath}
+ \sqrt{\sqrt{\sqrt{\sqrt{\sqrt{\sqrt{\sqrt{x+y}}}}}}}
+\end{displaymath}
+\endgroup % \delimitershortfall
+
+
+\section{Over- and underbraces}
+
+\begin{displaymath}
+ \overbrace{x} \quad
+ \overbrace{x+y} \quad
+ \overbrace{x^{2}+y^{2}} \quad
+ \overbrace{x_{i}^{2}+y_{j}^{2}} \quad
+ \underbrace{x} \quad
+ \underbrace{x+y} \quad
+ \underbrace{x_{i}+y_{j}} \quad
+ \underbrace{x_{i}^{2}+y_{j}^{2}} \quad
+\end{displaymath}
+
+
+\section{Normal and wide accents}
+
+\begin{displaymath}
+ \dot{x} \quad
+ \ddot{x} \quad
+ \vec{x} \quad
+ \bar{x} \quad
+ \overline{x} \quad
+ \overline{xx} \quad
+ \tilde{x} \quad
+ \widetilde{x} \quad
+ \widetilde{xx} \quad
+ \widetilde{xxx} \quad
+ \hat{x} \quad
+ \widehat{x} \quad
+ \widehat{xx} \quad
+ \widehat{xxx} \quad
+\end{displaymath}
+
+
+\section{Long arrows}
+
+\begin{displaymath}
+ \leftarrow \mathrel{-} \rightarrow \quad
+ \leftrightarrow \quad
+ \longleftarrow \quad
+ \longrightarrow \quad
+ \longleftrightarrow \quad
+ \Leftarrow = \Rightarrow \quad
+ \Leftrightarrow \quad
+ \Longleftarrow \quad
+ \Longrightarrow \quad
+ \Longleftrightarrow \quad
+\end{displaymath}
+
+
+\section{Left and right delimters}
+
+\def\testdelim#1#2{ - #1 f #2 - }
+\begin{displaymath}
+ \testdelim()
+ \testdelim[]
+ \testdelim\lfloor\rfloor
+ \testdelim\lceil\rceil
+ \testdelim\langle\rangle
+ \testdelim\{\}
+\end{displaymath}
+
+\def\testdelim#1#2{ - \left#1 f \right#2 - }
+\begin{displaymath}
+ \testdelim()
+ \testdelim[]
+ \testdelim\lfloor\rfloor
+ \testdelim\lceil\rceil
+ \testdelim\langle\rangle
+ \testdelim\{\}
+% \testdelim\lgroup\rgroup
+% \testdelim\lmoustache\rmoustache
+\end{displaymath}
+\begin{displaymath}
+ \testdelim)(
+ \testdelim][
+ \testdelim//
+ \testdelim\backslash\backslash
+ \testdelim/\backslash
+ \testdelim\backslash/
+\end{displaymath}
+
+
+\clearpage
+\section{Big-g-g delimters}
+
+\def\testdelim#1#2{%
+ - \left#1\left#1\left#1\left#1\left#1\left#1\left#1\left#1 -
+ \right#2\right#2\right#2\right#2\right#2\right#2\right#2\right#2 -}
+
+\begingroup
+\delimitershortfall-1pt
+\begin{displaymath}
+ \testdelim\lfloor\rfloor
+ \qquad
+ \testdelim()
+\end{displaymath}
+\begin{displaymath}
+ \testdelim\lceil\rceil
+ \qquad
+ \testdelim\{\}
+\end{displaymath}
+\begin{displaymath}
+ \testdelim[]
+ \qquad
+ \testdelim\lgroup\rgroup
+\end{displaymath}
+\begin{displaymath}
+ \testdelim\langle\rangle
+ \qquad
+ \testdelim\lmoustache\rmoustache
+\end{displaymath}
+\begin{displaymath}
+ \testdelim\uparrow\downarrow \quad
+ \testdelim\Uparrow\Downarrow \quad
+\end{displaymath}
+\endgroup % \delimitershortfall
+
+
+
+\end{document}
+
+%%% Local Variables:
+%%% mode: latex
+%%% TeX-master: t
+%%% End:
diff --git a/fonts/utilities/fontinst/examples/mathptmx/resetsy.mtx b/fonts/utilities/fontinst/examples/mathptmx/resetsy.mtx
new file mode 100644
index 0000000000..27da54c046
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/resetsy.mtx
@@ -0,0 +1,30 @@
+\relax
+
+\metrics
+
+\unsetglyph{Upsilon}
+\setglyph{Upsilon}
+ \glyph{Upsilon1}{1000}
+\endsetglyph
+
+\setglyph{pi1}
+ \glyph{omega1}{1000}
+\endsetglyph
+
+\setglyph{epsilon1}
+ \glyph{epsilon}{1000}
+\endsetglyph
+
+\setglyph{rho1}
+ \glyph{rho}{1000}
+\endsetglyph
+
+\setglyph{dotlessj}
+ \moveup{\neg{\depth{j}}}
+ \glyphrule{\width{j}}{\add{\depth{j}}{\height{dotlessi}}}
+ \resetitalic{\italic{dotlessi}}
+ \moveup{\depth{j}}
+ \glyphwarning{missing glyph `dotlessj'}
+\endsetglyph
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptmx/unsetmu.mtx b/fonts/utilities/fontinst/examples/mathptmx/unsetmu.mtx
new file mode 100644
index 0000000000..63b222ed9f
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/unsetmu.mtx
@@ -0,0 +1,7 @@
+\relax
+
+\metrics
+
+\unsetglyph{mu}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptmx/zrhax.mtx b/fonts/utilities/fontinst/examples/mathptmx/zrhax.mtx
new file mode 100644
index 0000000000..ce1bc5a281
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/zrhax.mtx
@@ -0,0 +1,15 @@
+\relax
+
+\metrics
+
+% This metrics file is loaded after having read the Times-Roman
+% glyphs. We unset those glyphs that should be taken from cmr.
+
+\unsetglyph{plus}
+\unsetglyph{equal}
+\unsetglyph{parenleft}
+\unsetglyph{parenright}
+\unsetglyph{bracketleft}
+\unsetglyph{bracketright}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptmx/zrmhax.mtx b/fonts/utilities/fontinst/examples/mathptmx/zrmhax.mtx
new file mode 100644
index 0000000000..141899c6dc
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/zrmhax.mtx
@@ -0,0 +1,14 @@
+\relax
+
+\metrics
+
+% This metrics file is loaded after having read the Times-Italic
+% glyphs. We unset those glyphs that should be taken from cmmi.
+
+\unsetglyph{period}
+\unsetglyph{comma}
+\unsetglyph{less}
+\unsetglyph{slash}
+\unsetglyph{greater}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptmx/zrmkernx.mtx b/fonts/utilities/fontinst/examples/mathptmx/zrmkernx.mtx
new file mode 100644
index 0000000000..f05a2f6867
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/zrmkernx.mtx
@@ -0,0 +1,239 @@
+\relax
+
+% The following adjustments (as proposed by Ulrik Vieth)
+% are tuned for Times-Italic and oblique Adobe Symbol.
+
+\metrics
+
+\needsfontinstversion{1.800}
+
+% \shiftglyph takes four parameters:
+%
+% #1 the name of the glyph
+% #2 the amount of extra space at the left
+% #3 the amount of extra space at the right
+% #4 the amount of extra space for subscripts
+
+\setcommand\shiftglyph#1#2#3#4{
+ \resetglyph{#1}
+ \movert{#2}
+ \glyph{#1}{1000}
+ \movert{#4}
+ \resetitalic{\add{\italic{#1}}{\sub{#3}{#4}}}
+ \endresetglyph
+}
+
+% \skewkern sets a skewchar kern, assuming that `tie'
+% is the skewchar.
+%
+% #1 the name of the glyph
+% #2 the amount of skewchar kerning
+
+\setcommand\skewkern#1#2{\setkern{#1}{tie}{#2}}
+
+
+%\shiftglyph{A}{}{}{}
+%\shiftglyph{B}{}{}{}
+\shiftglyph{C}{-50}{0}{-25}
+%\shiftglyph{D}{}{}{}
+\shiftglyph{E}{0}{50}{0}
+\shiftglyph{F}{0}{50}{-100}
+%\shiftglyph{G}{}{}{}
+\shiftglyph{H}{0}{25}{-25}
+\shiftglyph{I}{0}{0}{-25}
+\shiftglyph{J}{0}{0}{-25}
+\shiftglyph{K}{0}{0}{-25}
+%\shiftglyph{L}{}{}{}
+\shiftglyph{M}{0}{0}{-25}
+\shiftglyph{N}{0}{0}{-25}
+%\shiftglyph{O}{}{}{}
+\shiftglyph{P}{0}{0}{-125}
+%\shiftglyph{Q}{}{}{}
+%\shiftglyph{R}{}{}{}
+%\shiftglyph{S}{}{}{}
+\shiftglyph{T}{0}{50}{-75}
+\shiftglyph{U}{-50}{50}{-25}
+\shiftglyph{V}{-50}{50}{-50}
+\shiftglyph{W}{-50}{50}{-50}
+\shiftglyph{X}{0}{50}{-25}
+\shiftglyph{Y}{-50}{50}{-50}
+%\shiftglyph{Z}{}{}{}
+
+%\shiftglyph{a}{}{}{}
+\shiftglyph{b}{0}{-25}{0}
+%\shiftglyph{c}{}{}{}
+\shiftglyph{d}{0}{25}{0}
+%\shiftglyph{e}{}{}{}
+\shiftglyph{f}{150}{0}{25}
+\shiftglyph{g}{0}{-50}{0}
+%\shiftglyph{h}{}{}{}
+%\shiftglyph{i}{}{}{}
+\shiftglyph{j}{150}{25}{0}
+%\shiftglyph{k}{}{}{}
+\shiftglyph{l}{0}{50}{0}
+%\shiftglyph{m}{}{}{}
+%\shiftglyph{n}{}{}{}
+\shiftglyph{o}{0}{-50}{0}
+\shiftglyph{p}{75}{-25}{0}
+%\shiftglyph{q}{}{}{}
+%\shiftglyph{r}{}{}{}
+%\shiftglyph{s}{}{}{}
+\shiftglyph{t}{-25}{50}{0}
+%\shiftglyph{u}{}{}{}
+%\shiftglyph{v}{}{}{}
+%\shiftglyph{w}{}{}{}
+%\shiftglyph{x}{}{}{}
+%\shiftglyph{y}{}{}{}
+%\shiftglyph{z}{}{}{}
+
+\shiftglyph{Gamma}{-25}{50}{-125}
+\shiftglyph{Delta}{0}{0}{25}
+\shiftglyph{Theta}{-50}{0}{0}
+\shiftglyph{Lambda}{-25}{0}{0}
+\shiftglyph{Xi}{0}{0}{25}
+%\shiftglyph{Pi}{}{}{}
+\shiftglyph{Sigma}{0}{0}{25}
+\shiftglyph{Upsilon}{-75}{25}{-100}
+\shiftglyph{Phi}{0}{-25}{0}
+\shiftglyph{Psi}{-75}{0}{-100}
+\shiftglyph{Omega}{0}{0}{25}
+
+%\shiftglyph{alpha}{}{}{}
+%\shiftglyph{beta}{}{}{}
+%\shiftglyph{gamma}{}{}{}
+%\shiftglyph{delta}{}{}{}
+%\shiftglyph{epsilon1}{}{}{}
+%\shiftglyph{zeta}{}{}{}
+%\shiftglyph{theta}{}{}{}
+%\shiftglyph{iota}{}{}{}
+%\shiftglyph{kappa}{}{}{}
+%\shiftglyph{lambda}{}{}{}
+\shiftglyph{mu}{25}{0}{0}
+%\shiftglyph{nu}{}{}{}
+%\shiftglyph{xi}{}{}{}
+%\shiftglyph{omikron}{}{}{}
+%\shiftglyph{pi}{}{}{}
+%\shiftglyph{rho}{}{}{}
+\shiftglyph{sigma}{0}{25}{0}
+%\shiftglyph{tau}{}{}{}
+%\shiftglyph{upsilon}{}{}{}
+\shiftglyph{chi}{25}{0}{0}
+%\shiftglyph{phi}{}{}{}
+%\shiftglyph{psi}{}{}{}
+%\shiftglyph{omega}{}{}{}
+%\shiftglyph{epsilon}{}{}{}
+%\shiftglyph{theta1}{}{}{}
+%\shiftglyph{pi1}{}{}{}
+%\shiftglyph{rho1}{}{}{}
+\shiftglyph{sigma1}{0}{25}{0}
+%\shiftglyph{phi1}{}{}{}
+
+\shiftglyph{weierstrass}{-100}{-200}{-150}
+
+\skewkern{A}{75}
+\skewkern{B}{100}
+\skewkern{C}{100}
+\skewkern{D}{50}
+\skewkern{E}{75}
+\skewkern{F}{75}
+\skewkern{G}{100}
+\skewkern{H}{75}
+\skewkern{I}{100}
+\skewkern{J}{200}
+\skewkern{K}{75}
+%\skewkern{L}{}
+\skewkern{M}{100}
+\skewkern{N}{25}
+\skewkern{O}{100}
+\skewkern{P}{100}
+\skewkern{Q}{100}
+\skewkern{R}{100}
+\skewkern{S}{100}
+\skewkern{T}{50}
+\skewkern{U}{50}
+%\skewkern{V}{}
+%\skewkern{W}{}
+\skewkern{X}{50}
+%\skewkern{Y}{}
+\skewkern{Z}{50}
+
+\skewkern{a}{75}
+%\skewkern{b}{}
+\skewkern{c}{75}
+\skewkern{d}{200}
+\skewkern{e}{75}
+\skewkern{f}{150}
+\skewkern{g}{75}
+%\skewkern{h}{}
+\skewkern{i}{75}
+\skewkern{j}{150}
+%\skewkern{k}{}
+\skewkern{l}{100}
+\skewkern{m}{50}
+\skewkern{n}{50}
+\skewkern{o}{75}
+\skewkern{p}{100}
+\skewkern{q}{75}
+\skewkern{r}{50}
+\skewkern{s}{100}
+\skewkern{t}{50}
+\skewkern{u}{75}
+\skewkern{v}{75}
+\skewkern{w}{75}
+\skewkern{x}{75}
+\skewkern{y}{75}
+\skewkern{z}{50}
+\skewkern{dotlessi}{50}
+\skewkern{dotlessj}{50}
+
+\skewkern{Gamma}{75}
+\skewkern{Delta}{75}
+\skewkern{Theta}{50}
+\skewkern{Lambda}{50}
+\skewkern{Xi}{50}
+\skewkern{Pi}{75}
+\skewkern{Sigma}{50}
+\skewkern{Upsilon}{25}
+\skewkern{Phi}{75}
+\skewkern{Psi}{50}
+\skewkern{Omega}{50}
+
+%\skewkern{alpha}{}
+\skewkern{beta}{50}
+\skewkern{gamma}{75}
+\skewkern{delta}{50}
+%\skewkern{epsilon1}{}
+\skewkern{zeta}{50}
+\skewkern{theta}{50}
+%\skewkern{iota}{}
+\skewkern{kappa}{25}
+\skewkern{lambda}{-75}
+%\skewkern{mu}{}
+%\skewkern{nu}{}
+\skewkern{xi}{50}
+\skewkern{pi}{50}
+\skewkern{rho}{25}
+\skewkern{sigma}{25}
+\skewkern{tau}{50}
+\skewkern{upsilon}{50}
+\skewkern{chi}{25}
+\skewkern{phi}{75}
+\skewkern{psi}{50}
+\skewkern{omega}{50}
+%\skewkern{epsilon}{}
+\skewkern{theta1}{75}
+\skewkern{pi1}{50}
+\skewkern{rho1}{25}
+\skewkern{sigma1}{50}
+\skewkern{phi1}{50}
+
+\skewkern{weierstrass}{175}
+\skewkern{lscript}{125}
+
+\resetglyph{vector}
+ \movert{-100}
+ \glyph{vector}{1000}
+ \movert{100}
+\endresetglyph
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptmx/zrvhax.mtx b/fonts/utilities/fontinst/examples/mathptmx/zrvhax.mtx
new file mode 100644
index 0000000000..6270feb615
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/zrvhax.mtx
@@ -0,0 +1,73 @@
+\relax
+
+% This metrics file is loaded after having read the cmex glyps.
+% We unset the big operators that should be taken from Symbol
+% or from a scaled-down version of cmex.
+
+\metrics
+
+\setint{psy-textscale}{1000}
+\setint{psy-displayscale}{1440}
+
+\unsetglyph{circledotdisplay}
+\unsetglyph{circledottext}
+\unsetglyph{circlemultiplydisplay}
+\unsetglyph{circlemultiplytext}
+\unsetglyph{circleplusdisplay}
+\unsetglyph{circleplustext}
+\unsetglyph{contintegraldisplay}
+\unsetglyph{contintegraltext}
+\unsetglyph{integraldisplay}
+\unsetglyph{integraltext}
+\unsetglyph{intersectiondisplay}
+\unsetglyph{intersectiontext}
+\unsetglyph{logicalanddisplay}
+\unsetglyph{logicalandtext}
+\unsetglyph{logicalordisplay}
+\unsetglyph{logicalortext}
+\unsetglyph{uniondisplay}
+\unsetglyph{unionmultidisplay}
+\unsetglyph{unionmultitext}
+\unsetglyph{unionsqdisplay}
+\unsetglyph{unionsqtext}
+\unsetglyph{uniontext}
+
+\resetglyph{summationtext}
+ \glyph{summation}{\int{psy-textscale}}
+\endresetglyph
+
+\resetglyph{summationdisplay}
+ \glyph{summation}{\int{psy-displayscale}}
+\endresetglyph
+
+\resetglyph{producttext}
+ \glyph{product}{\int{psy-textscale}}
+\endresetglyph
+
+\resetglyph{productdisplay}
+ \glyph{product}{\int{psy-displayscale}}
+\endresetglyph
+
+\resetglyph{coproducttext}
+ \moveup{\neg{\depth{producttext}}}
+ \glyphrule{
+ \width{producttext}
+ }{
+ \add{\height{producttext}}{\depth{producttext}}
+ }
+ \moveup{\depth{producttext}}
+ \glyphwarning{missing glyph `coproducttext'}
+\endresetglyph
+
+\resetglyph{coproductdisplay}
+ \moveup{\neg{\depth{productdisplay}}}
+ \glyphrule{
+ \width{productdisplay}
+ }{
+ \add{\height{productdisplay}}{\depth{productdisplay}}
+ }
+ \moveup{\depth{productdisplay}}
+ \glyphwarning{missing glyph `coproductdisplay'}
+\endresetglyph
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptmx/zryhax.mtx b/fonts/utilities/fontinst/examples/mathptmx/zryhax.mtx
new file mode 100644
index 0000000000..19addd6ad8
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/zryhax.mtx
@@ -0,0 +1,26 @@
+\relax
+
+\metrics
+
+% This metrics file is loaded after having read the cmsy glyphs.
+% We unset those glyphs that should be taken from Times or Symbol.
+
+\unsetglyph{infinity}
+\unsetglyph{proportional}
+
+\unsetglyph{emptysetstress}
+
+\unsetglyph{Rfraktur}
+\unsetglyph{Ifraktur}
+
+\unsetglyph{aleph}
+
+\unsetglyph{coproduct}
+\unsetglyph{gradient}
+
+\unsetglyph{section}
+\unsetglyph{dagger}
+\unsetglyph{daggerdbl}
+\unsetglyph{paragraph}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/examples/mathptmx/zrykernx.mtx b/fonts/utilities/fontinst/examples/mathptmx/zrykernx.mtx
new file mode 100644
index 0000000000..249700156e
--- /dev/null
+++ b/fonts/utilities/fontinst/examples/mathptmx/zrykernx.mtx
@@ -0,0 +1,35 @@
+\relax
+
+% We reset the skewchar kerning for OMS (assuming skewchar=`prime')
+% using the original kern pairs for OML (assuming skewchar=`tie').
+
+\metrics
+
+\setkern{A}{prime}{\kerning{A}{tie}}
+\setkern{B}{prime}{\kerning{B}{tie}}
+\setkern{C}{prime}{\kerning{C}{tie}}
+\setkern{D}{prime}{\kerning{D}{tie}}
+\setkern{E}{prime}{\kerning{E}{tie}}
+\setkern{F}{prime}{\kerning{F}{tie}}
+\setkern{G}{prime}{\kerning{G}{tie}}
+\setkern{H}{prime}{\kerning{H}{tie}}
+\setkern{I}{prime}{\kerning{I}{tie}}
+\setkern{J}{prime}{\kerning{J}{tie}}
+\setkern{K}{prime}{\kerning{K}{tie}}
+\setkern{L}{prime}{\kerning{L}{tie}}
+\setkern{M}{prime}{\kerning{M}{tie}}
+\setkern{N}{prime}{\kerning{N}{tie}}
+\setkern{O}{prime}{\kerning{O}{tie}}
+\setkern{P}{prime}{\kerning{P}{tie}}
+\setkern{Q}{prime}{\kerning{Q}{tie}}
+\setkern{R}{prime}{\kerning{R}{tie}}
+\setkern{S}{prime}{\kerning{S}{tie}}
+\setkern{T}{prime}{\kerning{T}{tie}}
+\setkern{U}{prime}{\kerning{U}{tie}}
+\setkern{V}{prime}{\kerning{V}{tie}}
+\setkern{W}{prime}{\kerning{W}{tie}}
+\setkern{X}{prime}{\kerning{X}{tie}}
+\setkern{Y}{prime}{\kerning{Y}{tie}}
+\setkern{Z}{prime}{\kerning{Z}{tie}}
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/inputs/base/bbox.sty b/fonts/utilities/fontinst/inputs/base/bbox.sty
new file mode 100644
index 0000000000..d06bc8f47c
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/base/bbox.sty
@@ -0,0 +1,163 @@
+
+% bbox.sty -- bounding box extension for fontinst
+%
+% This file defines the following commands for setting, resetting,
+% and unsetting the bounding boxes of glyphs:
+%
+% \setglyphbb{GLYPH}{LEFT}{BOTTOM}{RIGHT}{TOP}
+% \resetglyphbb{GLYPH}{LEFT}{BOTTOM}{RIGHT}{TOP}
+% \unsetglyphbb{GLYPH}
+%
+% It also defines the following four integer expressions for
+% quering bounding box metrics:
+%
+% \bbleft{GLYPH}
+% \bbbottom{GLYPH}
+% \bbright{GLYPH}
+% \bbtop{GLYPH}
+%
+% For glyphs that do not have a bounding box set, they default
+% to using the "TeX box" of the glyph.
+%
+% Finally, the file changes AFM-to-MTX conversions so that bounding
+% box information is converted to \setglyphbb commands and augments
+% font transformation and reglyphing to preserve this information.
+
+
+\needsfontinstversion{1.927}
+
+\fontinstcc
+
+\def\resetglyphbb#1#2#3#4#5{
+ \eval_expr_to\a_count{#2}
+ \eval_expr_to\b_count{#3}
+ \eval_expr_to\c_count{#4}
+ \eval_expr_to\d_count{#5}
+ \x_cs\edef{gb-#1}{
+ {\the\a_count}{\the\b_count}{\the\c_count}{\the\d_count}
+ }
+}
+\def\setglyphbb#1#2#3#4#5{
+ \if_undefined{gb-\glyph_name_modifier{#1}}\then
+ \resetglyphbb{\glyph_name_modifier{#1}}{#2}{#3}{#4}{#5}
+ \fi
+}
+\def\unsetglyphbb#1{\x_cs\let{gb-#1}=\x_relax}
+
+\def\first_of_four#1#2#3#4{#1}
+\def\second_of_four#1#2#3#4{#2}
+\def\third_of_four#1#2#3#4{#3}
+\def\fourth_of_four#1#2#3#4{#4}
+
+\def\bbleft#1{
+ \if_defined{gb-#1}\then
+ \expandafter\expandafter \expandafter\first_of_four
+ \csname gb-#1\endcsname
+ \else
+ 0
+ \fi
+}
+\def\bbbottom#1{
+ \if_defined{gb-#1}\then
+ \expandafter\expandafter \expandafter\second_of_four
+ \csname gb-#1\endcsname
+ \else
+ \neg{\depth{#1}}
+ \fi
+}
+\def\bbright#1{
+ \if_defined{gb-#1}\then
+ \expandafter\expandafter \expandafter\third_of_four
+ \csname gb-#1\endcsname
+ \else
+ \width{#1}
+ \fi
+}
+\def\bbtop#1{
+ \if_defined{gb-#1}\then
+ \expandafter\expandafter \expandafter\fourth_of_four
+ \csname gb-#1\endcsname
+ \else
+ \height{#1}
+ \fi
+}
+
+
+% Make \afmtomtx generate \setglyphbb commands:
+\def\afm_char{
+ \a_count=-\bbox_lly
+ \eval_expr{
+ \italcorr_expression\x_width\bbox_llx\bbox_urx\bbox_lly\bbox_ury
+ }
+ \out_line{
+ \ifnum -1<\char_slot
+ \string\setrawglyph
+ \else
+ \string\setnotglyph
+ \fi
+ {\char_name}
+ {\raw_font_name}
+ {10pt}
+ {\the\char_slot}
+ {\the\x_width}
+ {\the\bbox_ury}
+ {\the\a_count}
+ {\the\result}
+ }
+ \out_line{
+ \string\setglyphbb{\char_name}
+ {\the\bbox_llx}{\the\bbox_lly}{\the\bbox_urx}{\the\bbox_ury}
+ }
+}
+
+
+% Make sure \setglyphbb is transformed OK.
+% Slanting of course cannot be done exactly when only the bbox
+% is known.
+\def\mtxtomtx_setglyphbb#1#2#3#4#5{
+ \eval_expr_to\a_count{\add{
+ \scale{#2}{\int{x-scale}}
+ }{
+ \scale{#3}{\int{slant-scale}}
+ }}
+ \eval_expr_to\b_count{\scale{#3}{\int{y-scale}}}
+ \eval_expr_to\c_count{\add{
+ \scale{#4}{\int{x-scale}}
+ }{
+ \scale{#5}{\int{slant-scale}}
+ }}
+ \eval_expr_to\d_count{\scale{#5}{\int{y-scale}}}
+ \out_line{
+ \string\setglyphbb{#1}
+ {\the\a_count}{\the\b_count}{\the\c_count}{\the\d_count}
+ }
+}
+
+\add_to\mtxtomtx_redefinitions{
+ \let\setglyphbb=\mtxtomtx_setglyphbb
+}
+
+% Finally, for completeness, the analogous thing for reglyphing.
+
+\def\reglyph_setglyphbb#1#2#3#4#5{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{
+ \string\setglyphbb{\glyphname}{#2}{#3}{#4}{#5}
+ }
+ \fi
+}
+
+\add_to\reglyph_redefinitions{
+ \let\setglyphbb=\reglyph_setglyphbb
+}
+
+
+\normalcc
+
+
+\endinput
+
+
diff --git a/fonts/utilities/fontinst/inputs/base/cfntinst.sty b/fonts/utilities/fontinst/inputs/base/cfntinst.sty
new file mode 100644
index 0000000000..033e21175d
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/base/cfntinst.sty
@@ -0,0 +1,3688 @@
+%%
+%% This is file `cfntinst.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% fibasics.dtx (with options: `pkg')
+%% ficommon.dtx (with options: `pkg')
+%% fimain.dtx (with options: `pkg,boundaryCompability')
+%% fitrig.dtx (with options: `pkg')
+%% ficonv.dtx (with options: `pkg')
+%% filtfam.dtx (with options: `pkg,textcomp,debug')
+%% fimapgen.dtx (with options: `pkg')
+%% fibasics.dtx (with options: `pkg2')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+%% maintenance team and any individual authors listed elsewhere in
+%% this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%%
+%%% From file: fibasics.dtx
+\catcode`\{=1
+\catcode`\}=2
+\catcode`\#=6
+\catcode`\^=7
+\def\fontinstversion{1.933}
+\ifx\ProvidesPackage\undefined
+ \def\NeedsTeXFormat#1{}
+ \def\ProvidesPackage#1[#2]{}
+\fi
+\ProvidesPackage{fontinst}
+[2007/01/23 v\fontinstversion\space
+ fontinst installation package]
+\def\a_macro#1{\catcode\number`#1=\the\catcode`#1 }
+\edef\normalcc{%
+ \a_macro{\ }\a_macro{\^^M}\a_macro{\@}\a_macro{\_}\a_macro{\~}
+}
+\def\fontinstcc{%
+ \catcode`\ =9%
+ \catcode`\^^M=9%
+ \catcode`\@=11%
+ \catcode`\_=11%
+ \catcode`\~=10
+}
+\fontinstcc
+\ifx\@ne\undefined_command
+ \input fontinst.ini\relax
+\fi
+\ifx\bye\undefined_command
+ \def\supereject{\par\penalty-\@MM}
+ \outer\expandafter\def \csname bye\endcsname
+ {\par\vfill\supereject\@@end}
+\fi
+\newcount\a_count
+\newcount\b_count
+\newcount\c_count
+\newcount\d_count
+\newcount\e_count
+\newcount\f_count
+\newcount\g_count
+\newdimen\a_dimen
+\newdimen\b_dimen
+\newdimen\c_dimen
+\newdimen\d_dimen
+\newtoks\a_toks
+\newtoks\b_toks
+\newtoks\c_toks
+\newif\if_a_
+\newwrite\out_file
+\mathchardef\one_thousand=1000
+\mathchardef\five_hundred=500
+\mathchardef\one_hundred=100
+\mathchardef\max_mathchardef="7FFF
+\mathchardef\two_thousand=2000
+\newdimen\half_point \half_point=0.5pt
+\def\x_cs#1#2{\expandafter#1\csname#2\endcsname}
+\let\x_relax=\relax
+\def\g_let{\global\let}
+\def\empty_command{}
+\def\gobble_one#1{}
+\def\gobble_two#1#2{}
+\def\gobble_three#1#2#3{}
+\def\identity_one#1{#1}
+\def\first_of_two#1#2{#1}
+\def\second_of_two#1#2{#2}
+\def\swap_two#1#2{#2#1}
+\def\first_of_three#1#2#3{#1}
+\bgroup
+ \catcode`\[=1
+ \catcode`\]=2
+ \catcode`\#=12
+ \catcode`\%=12
+ \catcode`\{=12
+ \catcode`\}=12
+ \gdef\hash_char[#]
+ \gdef\percent_char[%]
+ \gdef\left_brace_char[{]
+ \gdef\right_brace_char[}]
+\egroup
+\def\first_char#1#2={#1}
+\def\add_to#1#2{
+ \ifx#1\x_relax
+ \def#1{#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{#1#2}
+ \fi
+}
+\def\prep_to#1#2{
+ \ifx#1\x_relax
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2#1}
+ \fi
+}
+\def\never_do{\noexpand\do}
+\newif\if_extensions_warning_
+\_extensions_warning_false
+\ifx \eTeXversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\eTeX#1{
+ \if_extensions_warning_
+ \space/\space e-TeX\space version\space #1
+~ \else
+~ \ifdim \number\eTeXversion\eTeXrevision\p@ < #1\p@ \else
+~ \_a_true
+~ \fi
+ \fi
+}
+\catcode`\~=10
+\ifx \pdftexversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\pdfTeX#1#2{%
+ \if_extensions_warning_
+ \space/\space pdfTeX\space version\space
+ \ifnum #1<100\space
+ 0.\ifnum #1<10\space 0\fi
+ \else
+ \expandafter\swap_two \expandafter.
+ \fi
+ #1#2%
+~ \else
+~ \ifdim #1>\pdftexversion \else
+~ \ifnum \expandafter\expandafter \expandafter`
+~ \expandafter\first_char \pdftexrevision= <
+~ \expandafter` \first_char#2=
+~ \else \_a_true \fi
+~ \fi
+ \fi
+}
+\catcode`\~=10
+\def\needsTeXextension#1#2{
+ \_a_false
+ #1
+ \if_a_ \else
+ \_extensions_warning_true
+ \edef\a_macro{#1}
+ \_extensions_warning_false
+ \fontinstwarningnoline{#2}{
+ This~file~needs:\messagebreak
+ \expandafter\second_of_two\a_macro
+ \iffalse
+ <no~sufficient~extensions~were~listed!!>\if_false
+ \fi
+ \messagebreak
+ You~are~not~using~any~of~them.~This~is~likely~to~cause~errors
+ }
+ \fi
+}
+\def\open_out#1{
+ \immediate\openout\out_file=#1 \xdef\out_filename{#1}}
+\def\close_out#1{
+ \immediate\write16{#1~written~on~\out_filename.}
+ \immediate\closeout\out_file}
+\def\out_line#1{\immediate\write\out_file{#1}}
+\edef\out_lline#1{\noexpand\out_line{\space\space\space#1}}
+\edef\out_llline#1{
+ \noexpand\out_line{\space\space\space\space\space\space#1}
+}
+\def\TeX_terminal{\string\TeX\space terminal}
+\chardef\closed_stream=99
+\x_cs\let{out_filename-99}=\TeX_terminal
+\x_cs\def{out_filename--1}{\jobname.log}
+\def\allocate_stream{
+ \a_count=\m@ne
+ \b_count=\m@ne
+ \loop \ifnum \count17>\a_count
+ \advance \a_count \@ne
+ \x_cs\ifx{out_filename-\the\a_count}\TeX_terminal
+ \b_count=\a_count
+ \a_count=\count17
+ \fi
+ \repeat
+ \ifnum \b_count=\m@ne
+ \global\advance\count17by\@ne
+ \ifnum \count17<\sixt@@n
+ \b_count=\count17
+ \global\x_cs\let{out_filename-\the\b_count}\TeX_terminal
+ \wlog{\string\write\the\b_count\space allocated~to~the~pool.}
+ \else
+ \global\count17=\sixt@@n
+ \fi
+ \fi
+}
+\def\ch@ck#1#2#3{
+ \ifnum \count1#1<#2 \else
+ \errmessage{No~room~for~a~new~#3}
+ \global\count1#1=#2
+ \fi
+}
+\def\open_pout#1#2{
+ \allocate_stream
+ \ifnum \b_count=\m@ne
+ \immediate\write\sixt@@n{fontinst~is~out~of~output~streams.^^J
+ Output~file~#2~cannot~be~opened.^^J
+ Writes~will~be~redirected~to~the~log~file.
+ }
+ \gdef#1{\m@ne}
+ \else
+ \immediate\openout\b_count=#2\x_relax
+ \x_cs\xdef{out_filename-\the\b_count}{#2}
+ \global\chardef#1=\b_count
+ \fi
+}
+\def\close_pout#1#2{
+ \ifnum #1=\closed_stream
+ \errmessage{Output~file~\string#1~(#2)~not~closed,^^J
+ since~it~was~not~open}
+ \else
+ \immediate\write\sixt@@n{#2~written~on~
+ \csname out_filename-\the#1\endcsname.}
+ \ifnum #1=\m@ne \else
+ \immediate\closeout#1
+ \global\x_cs\let{out_filename-\the#1}=\TeX_terminal
+ \fi
+ \global\chardef#1=\closed_stream
+ \fi
+}
+\def\pout_line#1#2{\immediate\write#1{#2}}
+\edef\pout_lline#1#2{\noexpand\pout_line#1{\space\space\space#2}}
+\edef\pout_llline#1#2{
+ \noexpand\pout_line#1{\space\space\space\space\space\space#2}
+}
+\def\tempfileprefix#1{\def\temp_prefix{#1}}
+\tempfileprefix{}
+\let\then=\iffalse
+\def\if_false{\iffalse}
+\def\if_true{\iftrue}
+\_a_false\eTeX{2.0}
+\if_a_\else \catcode`\~=14\x_relax \fi
+~ \def\if_defined#1\then{
+~ \if
+~ \ifcsname#1\endcsname
+~ \expandafter\ifx \csname#1\endcsname \x_relax
+~ 0
+~ \else
+~ 1
+~ \fi
+~ \else
+~ 0
+~ \fi
+~ 1
+~ }
+~ \def\if_undefined{\expandafter\unless\if_defined}
+\catcode`\~=\if_a_ 14 \else 10 \fi \x_relax
+~ \def\if_defined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ \expandafter\if_false
+~ \else
+~ \expandafter\if_true
+~ \fi
+~ }
+~ \def\if_undefined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ }
+\catcode`\~=10\x_relax
+\def\gobble_if{\iftrue\else}
+\def\if_or#1\or_else#2\then{
+ #1\then
+ \expandafter\if_true
+ \else
+ #2\then
+ \expandafter\expandafter\expandafter\if_true
+ \else
+ \expandafter\expandafter\expandafter\if_false
+ \fi
+ \fi
+}
+\def\if_equal#1\then{\ifx#1}
+\def\if_file_exists#1\then{
+ \immediate\openin1=#1\x_relax
+ \ifeof1\x_relax
+ \immediate\closein1
+ \expandafter\if_false
+ \else
+ \immediate\closein1
+ \expandafter\if_true
+ \fi
+}
+\let\Else=\else
+\let\Fi=\fi
+\x_cs\ifx{@@input}\x_relax
+ \let\primitiveinput=\input
+\else
+ \let\primitiveinput=\@@input
+\fi
+\def\process_csep_list#1#2,{
+ \ifx\process_csep_list#2
+ \expandafter\gobble_one
+ \else
+ \expandafter\identity_one
+ \fi{
+ #1{#2}
+ \process_csep_list{#1}
+ }
+}
+\def\make_factor#1{
+ \ifnum #1<\z@
+ -\expandafter\make_factor_i\expandafter{\number-#1}
+ \else
+ \expandafter\make_factor_i\expandafter{\number#1}
+ \fi
+}
+\def\make_factor_i#1{
+ \ifnum #1<\one_thousand
+ \make_factor_ii{#1}
+ \else
+ \make_factor_iii #1
+ \fi
+ #1
+}
+\def\make_factor_ii#1{
+ 0.
+ \ifnum #1<\one_hundred
+ 0
+ \ifnum #1<10~ 0\fi
+ \fi
+}
+\def\make_factor_iii#1#2#3\fi#4{
+ \fi
+ #4
+ \ifnum 1#3<\one_thousand
+ .
+ \else
+ \make_factor_iii#2#3
+ \fi
+}
+{
+ \catcode`\p=12
+ \catcode`\t=12
+ \gdef\lose_measure#1pt{#1}
+}
+\def\format_hex_i#1#2{
+ \if #2i \else
+ \b_count=\a_count
+ \divide \a_count \sixt@@n
+ \c_count=\a_count
+ \multiply \c_count \sixt@@n
+ \advance \b_count -\c_count
+ \edef#1{
+ \ifcase\b_count 0\or 1\or 2\or 3\or 4\or 5\or 6\or 7\or 8\or
+ 9\or a\or b\or c\or d\or e\or f\fi
+ #1
+ }
+ \expandafter\format_hex_i \expandafter#1
+ \fi
+}
+\def\format_hex#1#2#3{
+ \a_count=#2
+ \let#1\empty_command
+ \expandafter\format_hex_i \expandafter#1 \romannumeral
+ \expandafter\identity_one\expandafter{\number#3}001~
+}
+\let\messagebreak\x_relax
+\def\generic_info#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\m@ne{#2\on_line.}
+ \endgroup
+}
+\def\generic_warning#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\closed_stream{^^J#2\on_line.^^J}
+ \endgroup
+}
+\def\generic_error#1#2#3#4{
+ \begingroup
+ \immediate\write\closed_stream{}
+ \def\messagebreak{^^J}
+ \edef\a_macro{{#4}}
+ \errhelp\a_macro
+ \def\messagebreak{^^J#1}
+ \errmessage{#2.^^J^^J#3
+ Type~\space H~<return>~\space for~immediate~help
+ }
+ \endgroup
+}
+\def\fontinsterror#1#2#3{
+ \generic_error{
+ \four_spaces\four_spaces
+ }{
+ #1~error:\messagebreak #2
+ }{
+ }{#3}
+}
+\def\fontinstwarning#1#2{
+ \generic_warning{
+ \four_spaces\four_spaces
+ }{
+ #1~warning:\messagebreak #2
+ }
+}
+\def\fontinstwarningnoline#1#2{
+ \fontinstwarning{#1}{#2\gobble_one}
+}
+\def\fontinstinfo#1#2{
+ \generic_info{
+ \four_spaces\four_spaces
+ }{
+ #1~info:\messagebreak #2
+ }
+}
+\def\on_line{~on~input~line~\the\inputlineno}
+\edef\four_spaces{\space\space\space\space}
+\gdef\error_help_a{
+ Your~command~was~ignored.\messagebreak
+ Type~\space I~<command>~<return>~\space to~replace~it~
+ with~another~command,\messagebreak
+ or~\space <return>~\space to~continue~without~it.}
+\gdef\error_help_c{
+ Try~typing~\space <return>~
+ \space to~proceed.\messagebreak
+ If~that~doesn't~work,~type~\space X~<return>~\space to~quit.}
+\gdef\error_help_d{
+ You're~in~trouble~here.~\space\error_help_c}
+\def\error_help_e#1{You~can~continue,~but~the~#1~wrong.}
+\newlinechar=`\^^J
+\errorcontextlines=999
+\tracinglostchars=1
+%%% From file: ficommon.dtx
+\def\str#1{\csname~s-#1\endcsname}
+\def\strint#1{\expandafter\identity_one\expandafter{\number\int{#1}}}
+\newcount\result
+\def\eval_expr#1{\global\result=#1\x_relax}
+\def\eval_expr_to#1#2{\eval_expr{#2}#1=\result}
+\def\g_eval_expr_to#1#2{\eval_expr{#2}\global#1=\result}
+\def\add#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\advance \result \a_count
+ \egroup
+}
+\def\sub#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \advance \a_count -\result
+ \global\result=\a_count
+ \egroup
+}
+\def\int#1{\csname i-#1 \endcsname}
+\def\neg#1{#1 \global\result=-\result}
+\def\mul#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \egroup
+}
+\def\div#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \divide \a_count \result
+ \global\result=\a_count
+ \egroup
+}
+\def\max#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count>\result \global\result=\a_count \fi
+ \egroup
+}
+\def\min#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count<\result \global\result=\a_count \fi
+ \egroup
+}
+\def\half#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\otherhalf#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \else \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\scale#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \rounded_thousandths
+ \egroup
+}
+\def\rounded_thousandths{
+ \global\divide \result \five_hundred
+ \ifodd \result
+ \global\advance \result by \ifnum 0>\result - \fi 1
+ \fi
+ \global\divide \result \tw@
+}
+\def\l_rounded_thousandths#1{
+ \divide #1 \five_hundred
+ \ifodd #1
+ \advance #1 by \ifnum 0>#1 - \fi\@ne
+ \fi
+ \divide #1 \tw@
+}
+\def\l_inv_scale#1#2{
+ \multiply #1 \two_thousand
+ \divide #1 #2\x_relax
+ \ifodd#1 \advance #1 \ifnum 0>#1 - \fi\@ne \fi
+ \divide #1 \tw@
+}
+\def\ifnumber#1#2#3\then{
+ \eval_expr_to\a_count{#1}
+ \eval_expr{#3}
+ \ifnum \a_count#2\result
+ \expandafter\if_true
+ \else
+ \expandafter\if_false
+ \fi
+}
+\let\setsomething_global=\x_relax
+\def\x_setint#1#2{
+ \x_cs\ifx{i-#1}\x_relax
+ \x_resetint{#1}{#2}
+ \fi
+}
+\let\setint=\x_setint
+\def\x_setstr#1#2{
+ \x_cs\ifx{s-#1}\x_relax
+ \setsomething_global\x_cs\edef{s-#1}{#2}
+ \fi
+}
+\let\setstr=\x_setstr
+\def\setdim#1#2{
+ \x_cs\ifx{d-#1}\x_relax
+ \a_dimen=#2\x_relax
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+ \fi
+}
+\def\setcommand#1{
+ \ifx#1\undefined_command
+ \setsomething_global \expandafter\def \expandafter#1
+ \else
+ \expandafter\def \expandafter\a_macro
+ \fi
+}
+\def\x_resetint#1#2{
+ \eval_expr{#2}
+ \setsomething_global
+ \ifnum\result<\max_mathchardef
+ \ifnum 0>\result
+ \x_cs\edef{i-#1}{\the\result}
+ \else
+ \x_cs\mathchardef{i-#1}=\result
+ \fi
+ \else
+ \x_cs\edef{i-#1}{\the\result}
+ \fi
+}
+\let\resetint=\x_resetint
+\def\resetstr#1#2{\setsomething_global\x_cs\edef{s-#1}{#2}}
+\def\resetdim#1#2{
+ \a_dimen=#2
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+}
+\def\resetcommand#1{\setsomething_global\def#1}
+\def\dim#1{\csname~d-#1\endcsname}
+\def\ifisint#1\then{\if_defined i-#1\then}
+\def\ifisstr#1\then{\if_defined s-#1\then}
+\def\ifisdim#1\then{\if_defined d-#1\then}
+\def\ifiscommand#1\then{
+ \ifx#1\undefined_command
+ \expandafter\if_false
+ \else
+ \expandafter\if_true
+ \fi
+}
+\def\unsetint#1{\setsomething_global\x_cs\let{i-#1}\x_relax}
+\def\unsetstr#1{\setsomething_global\x_cs\let{s-#1}\x_relax}
+\def\unsetdim#1{\setsomething_global\x_cs\let{d-#1}\x_relax}
+\def\unsetcommand#1{\setsomething_global\let#1=\undefined_command}
+\def\offcommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax
+ \setsomething_global\x_cs\let{saved-\string#1}#1
+ \x_cs\ifx{off-\string#1}\x_relax
+ \generate_off_command{#1}
+ \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname off-\string#1\endcsname
+ \fi
+ \fi
+}
+\def\oncommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname saved-\string#1\endcsname
+ \setsomething_global\x_cs\let{saved-\string#1}\x_relax
+ \fi
+}
+\def\generate_off_command#1{
+ \a_count=0
+ \let\next=\count_hashes
+ \expandafter\next\meaning#1~->\x_relax
+ \b_count=0
+ \a_toks={}
+ \loop \ifnum \b_count<\a_count
+ \advance \b_count 1
+ \a_toks=\expandafter{\the\expandafter\a_toks \expandafter####
+ \the\b_count}
+ \repeat
+ \setsomething_global \expandafter\def \expandafter#1 \the\a_toks {}
+}
+\def\count_hashes#1#2{
+ \if \hash_char#1
+ \advance \a_count 1
+ \else
+ \if -#1
+ \if >#2
+ \let\next=\gobble_to_xrelax
+ \fi\fi
+ \fi
+ \next#2
+}
+\def\gobble_to_xrelax#1\x_relax{}
+\def\for(#1)#2#3#4{
+ \eval_expr_to\a_count{#2}
+ \x_resetint{#1}{\a_count}
+ \eval_expr{#4}
+ \ifnum 0=\result \else
+ \c_count=\result
+ \eval_expr_to\b_count{#3}
+ \setsomething_global\x_cs\edef{for-#1}{
+ \the\c_count \x_relax
+ \noexpand\ifnum \gobble_one\fi
+ \the\b_count \ifnum 0>\c_count > \else < \fi
+ }
+ \def\next##1##2##3\endfor(#1){##2\for_i{##1}{##3}}
+ \next{#1}
+ \fi
+}
+\def\for_i#1#2{
+ \setsomething_global\x_cs\def{body-#1}{#2}
+ \ifnum \b_count \ifnum0>\c_count >\else<\fi \a_count
+ \expandafter\gobble_two
+ \else
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+\def\for_ii#1{
+ \a_count=\int{#1}
+ \advance \a_count \csname for-#1\endcsname \a_count
+ \expandafter\gobble_two
+ \else
+ \x_resetint{#1}\a_count
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+\def\endfor(#1){}
+\def\foreach(#1)#2{
+ \def\next##1\endfor(#1){
+ \setsomething_global\x_cs\def{body-#1}{##1}
+ \process_csep_list{\foreach_i{#1}}#2,\process_csep_list,
+ }
+ \next
+}
+\def\foreach_i#1#2{
+ \resetstr{#1}{#2}
+ \csname body-#1\endcsname
+}
+\let\comment=\gobble_one
+\let\begincomment=\iffalse
+\let\endcomment=\fi
+%%% From file: fimain.dtx
+\def\inputetx#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \slot_number=0
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\encoding=\fi
+ \primitiveinput \lowercase_file.etx\x_relax
+ \let\relax=\x_relax
+}
+\let\encoding=\relax
+\outer\def\endencoding{\endinput}
+\def\setslot#1{\edef\slot_name{#1}\do_slot}
+\def\endsetslot{\end_do_slot\advance\slot_number by 1\x_relax}
+\let\do_slot\empty_command
+\let\end_do_slot\empty_command
+\newcount\slot_number
+\def\nextslot#1{\eval_expr_to\slot_number{#1}}
+\def\skipslots#1{\eval_expr{#1} \advance\slot_number by \result}
+\def\setleftboundary#1{\edef\slot_name{#1}\do_boundary}
+\let\endsetleftboundary\x_relax
+\let\do_boundary\x_relax
+\def\setrightboundary#1{
+ \makerightboundary{#1}
+ \advance \slot_number 1\x_relax
+}
+\let\ligature=\gobble_three
+\def\Ligature{\ligature}
+\def\oddligature#1#2#3#4{}
+\let\nextlarger=\gobble_one
+\let\usedas=\gobble_two
+\let\makerightboundary=\gobble_one
+\let\Unicode=\gobble_two
+\let\charseq=\gobble_one
+\let\varchar=\empty_command
+\let\vartop=\gobble_one
+\let\varmid=\gobble_one
+\let\varbot=\gobble_one
+\let\varrep=\gobble_one
+\let\endvarchar=\empty_command
+\let\useexamplefont=\gobble_one
+\let\slotexample=\empty_command
+\let\setslotcomment=\gobble_one
+\let\resetslotcomment=\gobble_one
+\let\unsetslotcomment=\empty_command
+\def\setfontdimen#1#2{
+ \ifisint{#2}\then \setint{fontdimen(#1)}{\int{#2}} \fi
+}
+\let\label=\gobble_one
+\newif\ifdirect \directtrue
+\def\input_mtx_as_etx#1{
+ \def\setscaledrawglyph##1##2##3##4##5##6##7##8##9{
+ \nextslot{##5}
+ \setslot{##1}\endsetslot
+ }
+ \offcommand\setscalednotglyph
+ \let\setglyph=\gobble_glyph
+ \offcommand\setkern
+ \inputmtx{#1}
+}
+\def\inputmtx#1{
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\metrics=\fi
+ \primitiveinput #1.mtx\x_relax
+ \let\relax=\x_relax
+}
+\let\metrics=\x_relax
+\edef\endmetrics_text{\string\endmetrics}
+\outer\def\endmetrics{\endinput}
+\def\ProvidesMtxPackage#1{\x_cs\let{pack-#1}P}
+\def\usemtxpackage{\futurelet\next_token\test_UseMtxPkg_arguments}
+\def\test_UseMtxPkg_arguments{\ifx\next_token[
+ \expandafter\mtx_package_given_file
+ \else
+ \expandafter\mtx_package_separate_files
+ \fi
+}
+\def\mtx_package_given_file[#1]#2{
+ \_a_false
+ \process_csep_list\load_true_unless_loaded #2,\process_csep_list,
+ \if_a_ \inputmtx{#1} \fi
+}
+\def\load_true_unless_loaded#1{
+ \x_cs\ifx{pack-#1}P\else\_a_true\fi
+}
+\def\mtx_package_separate_files#1{
+ \process_csep_list\load_file_unless_loaded #1,\process_csep_list,
+}
+\def\load_file_unless_loaded#1{
+ \x_cs\ifx{pack-#1}P\else \inputmtx{#1} \fi
+}
+\let\glyph_name_modifier=\identity_one
+\def\setkern#1#2#3{
+ \x_cs\ifx{i-rawscale}\x_relax
+ \expandafter\set_kern
+ \csname~r-\glyph_name_modifier{#1}\expandafter\endcsname
+ \csname~l-\glyph_name_modifier{#2}\endcsname
+ {#3}
+ \else
+ \expandafter\set_kern
+ \csname~r-\glyph_name_modifier{#1}\expandafter\endcsname
+ \csname~l-\glyph_name_modifier{#2}\endcsname
+ {\scale{#3}{\int{rawscale}}}
+ \fi
+}
+\def\set_kern#1#2#3{
+ \eval_expr{#3}
+ \expandafter\set_kern_cs\csname\the\result\endcsname#1#2
+}
+\def\set_kern_cs#1#2#3{
+ \add_to#2{\k#3#1}
+ \add_to#3{\k#2#1}
+}
+\def\resetkern#1#2#3{
+ \x_cs\ifx{i-rawscale}\x_relax
+ \expandafter\reset_kern
+ \csname~r-#1\expandafter\endcsname
+ \csname~l-#2\endcsname{#3}
+ \else
+ \expandafter\reset_kern
+ \csname~r-#1\expandafter\endcsname
+ \csname~l-#2\endcsname{\scale{#3}{\int{rawscale}}}
+ \fi
+}
+\def\reset_kern#1#2#3{
+ \eval_expr{#3}
+ \expandafter\reset_kern_cs\csname\the\result\endcsname#1#2
+}
+\def\reset_kern_cs#1#2#3{
+ \prep_to#2{\k\expandafter#3\expandafter#1}
+ \prep_to#3{\k\expandafter#2\expandafter#1}
+}
+\def\setleftkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~l-#1\expandafter\endcsname
+ \csname~l-#2\endcsname
+}
+\def\setrightkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~r-#1\expandafter\endcsname
+ \csname~r-#2\endcsname
+}
+\def\setleftrightkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~l-#1\expandafter\endcsname
+ \csname~l-#2\endcsname
+ \expandafter\set_kerning
+ \csname~r-#1\expandafter\endcsname
+ \csname~r-#2\endcsname
+}
+\def\set_kerning#1#2{
+ \if\b_count=\one_thousand
+ \def\k##1##2{
+ \set_kern_cs##2##1#1
+ }
+ \else
+ \def\k##1##2{
+ \set_kern##1#1{
+ \scale\b_count{\expandafter\gobble_one\string##2}
+ }
+ }
+ \fi
+ #2
+}
+\def\kerning#1#2{0\x_relax
+ \def\k##1{\csname~set-\string##1\endcsname\gobble_one}
+ \bgroup
+ \x_cs\def{set-\string\l-#2}##1##2{
+ \global\result=\expandafter\gobble_one\string##2\egroup
+ }
+ \csname~r-#1\endcsname
+ \csname~set-\string\l-#2\endcsname\gobble_one{00}
+}
+\def\ifiskern#1#2\then{
+ \def\k##1##2{\ifx T##1 \let\k\gobble_two \fi}
+ \bgroup
+ \x_cs\let{l-#2}T
+ \csname r-#1\endcsname
+ \expandafter\egroup \ifx\k\gobble_two
+}
+\def\unsetkerns#1#2{
+ \let\k\k_unless_to_U
+ \process_csep_list\make_slots_U#1,\process_csep_list,
+ \def\do##1{\x_cs\main_remove_Us{l-##1}}
+ \process_csep_list\do#2,\process_csep_list,
+ \process_csep_list\make_slots_relax#1,\process_csep_list,
+ \process_csep_list\make_slots_U#2,\process_csep_list,
+ \def\do##1{\x_cs\main_remove_Us{r-##1}}
+ \process_csep_list\do#1,\process_csep_list,
+ \process_csep_list\make_slots_relax#2,\process_csep_list,
+}
+\def\make_slots_U#1{\x_cs\let{slots-#1}U}
+\def\make_slots_relax#1{\x_cs\let{slots-#1}\x_relax}
+\def\k_unless_to_U#1#2{
+ \x_cs\ifx{slots-\expandafter\gobble_three\string#1}U \else
+ \noexpand\k\noexpand#1\noexpand#2
+ \fi
+}
+\def\main_remove_Us#1{
+ \ifx#1\x_relax \else
+ \edef#1{#1}
+ \ifx#1\empty_command \let#1\x_relax \fi
+ \fi
+}
+\def\noleftkerning#1{\no_kerning{l}{#1}}
+\def\norightkerning#1{\no_kerning{r}{#1}}
+\def\noleftrightkerning#1{\no_kerning{l}{#1}\no_kerning{r}{#1}}
+\def\no_kerning#1#2{
+ \let\k\no_kerning_i
+ \def\do##1{\csname #1-##1\endcsname}
+ \bgroup
+ \aftergroup\def \aftergroup\a_macro \aftergroup{
+ \process_csep_list\do #2,\process_csep_list,
+ \aftergroup}
+ \egroup
+ \def\do##1{\expandafter\let \csname #1-##1\endcsname \x_relax}
+ \process_csep_list\do #2,\process_csep_list,
+ \let\k\no_kerning_ii
+ \def\do##1{\edef##1{##1}}
+ \a_macro
+}
+\def\no_kerning_i#1#2{
+ \ifx #1\x_relax \else
+ \aftergroup\do \aftergroup#1
+ \let #1\x_relax
+ \fi
+}
+\def\no_kerning_ii#1#2{
+ \ifx #1\x_relax \else \noexpand\k \noexpand#1 \noexpand#2 \fi
+}
+\def\width{\glyph_parameter\first_of_six}
+\def\height{\glyph_parameter\second_of_six}
+\def\depth{\glyph_parameter\third_of_six}
+\def\italic{\glyph_parameter\fourth_of_six}
+\def\mapcommands{\glyph_parameter\fifth_of_six}
+\def\mapfonts{\glyph_parameter\sixth_of_six}
+\def\glyph_parameter#1#2{
+ \expandafter\expandafter\expandafter
+ #1\csname g-#2\endcsname
+}
+\def\first_of_six#1#2#3#4#5#6{#1}
+\def\second_of_six#1#2#3#4#5#6{#2}
+\def\third_of_six#1#2#3#4#5#6{#3}
+\def\fourth_of_six#1#2#3#4#5#6{#4}
+\def\fifth_of_six#1#2#3#4#5#6{#5}
+\def\sixth_of_six#1#2#3#4#5#6{#6}
+\def\glyph_metrics#1#2#3#4#5#6{
+ \a_count=#1
+ \b_count=#2
+ \c_count=#3
+ \d_count=#4~
+}
+\let\saved_scale\x_relax
+\let\saved_mapfont\x_relax
+\let\saved_raw\x_relax
+\let\saved_rule\x_relax
+\let\saved_special\x_relax
+\let\saved_warning\x_relax
+\let\saved_movert\x_relax
+\let\saved_moveup\x_relax
+\let\saved_push\x_relax
+\let\saved_pop\x_relax
+\newcount\glyph_width
+\newcount\glyph_height
+\newcount\glyph_depth
+\newcount\glyph_italic
+\newtoks\glyph_map_commands
+\newtoks\glyph_map_fonts
+\newcount\glyph_voffset
+\newcount\glyph_maxhpos
+\def\setglyph#1{
+ \ifisglyph{\glyph_name_modifier{#1}}\then
+ \expandafter\gobble_glyph
+ \else
+ \x_cs\def{g-\glyph_name_modifier{#1}}{
+ {\the\glyph_width}{\the\glyph_height}
+ {\the\glyph_depth}{\the\glyph_italic}
+ {\the\glyph_map_commands}{\the\glyph_map_fonts}
+ }
+ \resetglyph{\glyph_name_modifier{#1}}
+ \fi
+}
+\long\def\gobble_glyph#1\endsetglyph{}
+\def\resetglyph#1{
+ \edef\glyphname{#1}
+ \glyph_width=0
+ \global\glyph_height=0
+ \global\glyph_depth=0
+ \global\glyph_italic=0
+ \glyph_voffset=0
+ \global\glyph_maxhpos=0
+ \global\glyph_map_commands={}
+ \global\glyph_map_fonts={}
+}
+\def\endsetglyph{
+ \x_cs\edef{g-\glyphname}
+ {{\the\glyph_width}{\the\glyph_height}
+ {\the\glyph_depth}{\the\glyph_italic}
+ {\the\glyph_map_commands}{\the\glyph_map_fonts}}
+}
+\let\endresetglyph=\endsetglyph
+\def\setrawglyph#1#2#3{
+ \setscaledrawglyph{#1}{#2}{#3}\one_thousand
+}
+\def\setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \if_undefined{g-\glyph_name_modifier{#1}}\then
+ \eval_expr{#4}
+ \ifnum \result=\one_thousand
+ \let\a_macro\identity_one
+ \else
+ \edef\a_macro##1{\saved_scale{\the\result}{##1}}
+ \fi
+ \eval_expr_to\a_count{#6}
+ \eval_expr_to\b_count{#7}
+ \eval_expr_to\c_count{#8}
+ \eval_expr_to\d_count{#9}
+ \ifisint{rawscale}\then
+ \e_count=\int{rawscale}
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \edef\a_macro##1{\saved_scale{\the\e_count}{\a_macro{##1}}}
+ \fi
+ \x_cs\edef{g-\glyph_name_modifier{#1}}{
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {\a_macro{\saved_raw{#2}{#5}{#1}}}
+ {\a_macro{\saved_mapfont{#2}{#3}}}
+ }
+ \fi
+}
+\def\setnotglyph#1#2#3{
+ \setscalednotglyph{#1}{#2}{#3}\one_thousand
+}
+\def\setscalednotglyph#1#2#3#4#5#6#7#8#9{
+ \if_undefined{g-\glyph_name_modifier{#1}-not}\then
+ \eval_expr_to\a_count{#6}
+ \eval_expr_to\b_count{#7}
+ \eval_expr_to\c_count{#8}
+ \eval_expr_to\d_count{#9}
+ \ifisint{rawscale}\then
+ \e_count=\int{rawscale}
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \fi
+ \x_cs\edef{g-\glyph_name_modifier{#1}-not}{
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {}{}
+ }
+ \fi
+}
+\def\unsetglyph#1{\x_cs\let{g-#1}\x_relax}
+\def\glyph#1#2{
+ \glyph_parameter\glyph_metrics{#1}
+ \eval_expr_to\e_count{#2}
+ \ifnum \e_count=\one_thousand
+ \edef\a_macro{\mapcommands{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \edef\a_macro{\mapfonts{#1}}
+ \else
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \edef\a_macro{\saved_scale{\the\e_count}{\mapcommands{#1}}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \edef\a_macro{\saved_scale{\the\e_count}{\mapfonts{#1}}}
+ \fi
+ \advance \glyph_width \a_count
+ \advance \b_count \glyph_voffset
+ \ifnum \glyph_height<\b_count \global\glyph_height=\b_count \fi
+ \advance \c_count -\glyph_voffset
+ \ifnum \glyph_depth<\c_count \global\glyph_depth=\c_count \fi
+ \global\glyph_italic=\d_count
+ \global\glyph_map_fonts\expandafter{
+ \the\expandafter\glyph_map_fonts \a_macro
+ }
+}
+\def\glyphrule#1#2{
+ \eval_expr_to\b_count{#1} \eval_expr_to\c_count{#2}
+ \advance\glyph_width by \b_count
+ \g_eval_expr_to\glyph_depth{\max\glyph_depth{-\glyph_voffset}}
+ \g_eval_expr_to\glyph_height{
+ \max\glyph_height{\add\glyph_voffset\c_count}
+ }
+ \global\glyph_italic=0
+ \edef\a_macro{\saved_rule{\the\b_count}{\the\c_count}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\glyphspecial#1{
+ \edef\a_macro{\saved_special{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\glyphwarning#1{
+ \edef\a_macro{\saved_warning{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\movert#1{
+ \eval_expr{#1}
+ \ifnum \glyph_maxhpos<\glyph_width
+ \global\glyph_maxhpos\glyph_width
+ \fi
+ \ifnum 0=\result \else
+ \advance\glyph_width by \result
+ \edef\a_macro{\saved_movert{\the\result}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \fi
+}
+\def\moveup#1{
+ \eval_expr{#1}
+ \ifnum\result=0\else
+ \advance\glyph_voffset by \result
+ \edef\a_macro{\saved_moveup{\the\result}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \fi
+}
+\def\push{
+ \bgroup
+ \global\glyph_map_commands\expandafter{
+ \the\glyph_map_commands \saved_push
+ }
+}
+\def\pop{
+ \ifnum \glyph_maxhpos<\glyph_width
+ \global\glyph_maxhpos\glyph_width
+ \fi
+ \egroup
+ \global\glyph_map_commands\expandafter{
+ \the\glyph_map_commands \saved_pop
+ }
+}
+\def\resetwidth#1{\movert{\sub{#1}\glyph_width}}
+\def\resetheight{\g_eval_expr_to\glyph_height}
+\def\resetdepth{\g_eval_expr_to\glyph_depth}
+\def\resetitalic{\g_eval_expr_to\glyph_italic}
+\def\glyphpcc#1#2#3{
+ \ifisglyph{\glyph_name_modifier{#1}}\then
+ \push
+ \movert{#2}
+ \moveup{#3}
+ \glyph{\glyph_name_modifier{#1}}{\one_thousand}
+ \pop
+ \else\ifisglyph{\glyph_name_modifier{#1}-not}\then
+ \fontinstwarning{\string\glyphpcc}{
+ Base~glyph~`\glyph_name_modifier{#1}'~not~appended,\messagebreak
+ because~it~is~so~far~unencoded~in~the~glyph~base
+ }
+ \else
+ \fontinsterror{\string\glyphpcc}{
+ Base~glyph~not~set.\messagebreak
+ This~could~be~a~sign~that~the~AFM~file~is~buggy
+ }\error_help_a
+ \fi\fi
+}
+\def\glyphbboxright{\max\glyph_width\glyph_maxhpos}
+\def\samesize#1{
+ \if_undefined{g-\glyph_name_modifier{#1}}\then
+ \resetwidth{\glyphbboxright}
+ \else
+ \expandafter\expandafter\expandafter
+ \same_size\csname g-\glyph_name_modifier{#1}\endcsname
+ \fi
+}
+\def\same_size#1#2#3#4#5#6{
+ \movert{\sub{#1}\glyph_width}
+ \global\glyph_height=#2
+ \global\glyph_depth=#3
+ \global\glyph_italic=#4
+}
+\def\ifisglyph#1\then{\if_defined{g-#1}\then}
+\def\ifareglyphs#1\then{
+ \process_csep_list{\if_is_glyph}#1,\process_csep_list,
+ \if_true
+}
+\def\if_is_glyph#1{
+ \if_undefined{g-#1}\then \expandafter\if_false \fi
+}
+\def\etxtovpl#1#2{{
+ \def\vpl_extension{vpl}
+ \def\vpl_title{COMMENT}
+ \def\vpl_font{virtual~font}
+ \def\vpl_Font{Virtual~font}
+ \def\vpl_call{\string\etxtovpl{#1}{#2}}
+ \def\vpl_to_vf##1{vptovf~##1.vpl~##1.vf~##1.tfm}
+ \a_toks={}
+ \process_csep_list\make_inputetx #1,\process_csep_list,
+ \expandafter\etx_to_font \expandafter{\the\a_toks}{#2}
+}}
+\def\etxtopl#1#2{{
+ \def\vpl_extension{pl}
+ \def\vpl_title{COMMENT}
+ \def\vpl_font{font}
+ \def\vpl_Font{Font}
+ \def\vpl_call{\string\etxtopl{#1}{#2}}
+ \def\vpl_to_vf##1{pltotf~##1.pl~##1.tfm}
+ \_including_map_false
+ \global\rawfont_scaling=-\p@
+ \a_toks={}
+ \process_csep_list\make_inputetx #1,\process_csep_list,
+ \expandafter\etx_to_font \expandafter{\the\a_toks}{#2}
+}}
+\newif\if_including_map_
+\_including_map_true
+\def\make_inputetx#1{
+ \def\a_macro{\noexpand\inputetx{\file_name}}
+ \get_file_name #1~{}~\par
+ \edef\a_macro{\a_macro}
+ \a_toks=\expandafter{ \the\expandafter\a_toks \a_macro}
+}
+\x_cs\def{IFKW-mtxasetx}{
+ \def\a_macro{\noexpand\input_mtx_as_etx{\file_name}}
+ \get_keyword
+}
+\def\etx_to_font#1#2{
+ \make_assignments{#1}
+ \open_out{#2.\vpl_extension}
+ \top_of_pl_hook
+ \out_line{(\vpl_title\space\vpl_font\space
+ #2~created~by~fontinst~v\fontinstversion)}
+ \out_line{}
+ \out_line{(COMMENT~Filename:~#2.\vpl_extension)}
+ \out_line{(COMMENT~Created~by:~tex~\jobname)}
+ \out_line{(COMMENT~Created~using:~\vpl_call)}
+ \out_line{}
+ \out_line{(COMMENT~This~file~can~be~turned~into~a~\vpl_font\space
+ with)}
+ \out_line{(COMMENT~\vpl_to_vf{#2})}
+ \out_line{}
+ \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)}
+ \out_line{}
+ \make_header{#1}
+ \if_including_map_ \make_mapfonts{#1} \fi
+ \make_fontdimens{#1}
+ \make_ligtable{#1}
+ \make_characters{#1}
+ \make_tidy{#1}
+ \out_line{}
+ \out_line{(COMMENT~END~OF~FILE~#2.\vpl_extension)}
+ \close_out{\vpl_Font}
+}
+\let\pre_first_etx_pass_hook\x_relax
+\let\pre_second_etx_pass_hook\x_relax
+\let\pre_third_etx_pass_hook\x_relax
+\let\pre_fourth_etx_pass_hook\x_relax
+\let\post_first_etx_pass_hook\x_relax
+\let\post_second_etx_pass_hook\x_relax
+\let\post_third_etx_pass_hook\x_relax
+\let\post_fourth_etx_pass_hook\x_relax
+\let\tidying_up_hook\x_relax
+\let\top_of_pl_hook\x_relax
+\def\make_assignments#1{
+ \let\do_slot=\assign_slot
+ \let\end_do_slot=\end_assign_slot
+ \def\do_boundary{\bgroup
+ \let\makerightboundary=\bad_makerightboundary
+ }
+ \let\endsetleftboundary=\egroup
+ \let\makerightboundary=\assign_rboundary
+ \pre_first_etx_pass_hook
+ #1
+ \post_first_etx_pass_hook
+ \let\end_do_slot=\empty_command
+ \let\do_boundary=\x_relax
+ \let\endsetleftboundary=\x_relax
+ \let\makerightboundary=\gobble_one
+}
+\def\assign_slot{\a_toks={\do}}
+\begingroup
+ \catcode0=12
+ \gdef\end_assign_slot{
+ \ifisglyph\slot_name\then
+ \lccode0=\slot_number
+ \lowercase{
+ \expandafter\add_to
+ \csname slots-\slot_name\expandafter\endcsname
+ \expandafter{\the\a_toks^^@}
+ }
+ \x_resetint\slot_name\slot_number
+ \fi
+ }
+ \gdef\assign_rboundary#1{
+ \lccode0=\slot_number
+ \lowercase{\x_cs\add_to{slots-#1}{\rboundary_do^^@}}
+ \x_setint{\percent_char boundarychar}\slot_number
+ \a_toks={\rbserver_do}
+ }
+\endgroup
+\def\bad_makerightboundary#1{
+ \errhelp={The~left~boundary~is~not~a~slot,~so~it~cannot~serve~
+ as~right~boundary.}
+ \errmessage{Incorrect~use~of~\string\makerightboundary}
+}
+\def\get_slot_num#1{
+ \ifisint{#1}\then
+ \global\result=\int{#1}
+ \else
+ \global\result=-1
+ \fi
+ \x_relax
+}
+\def\ifisinslot#1#2\then{
+ \ifx \makerightboundary\gobble_one
+ \eval_expr{#2}
+ \begingroup
+ \def\do##1{\ifnum `##1=\result \let\do=\gobble_one \fi}
+ \def\rbserver_do{\do}
+ \let\rboundary_do=\gobble_one
+ \csname slots-#1\endcsname
+ \expandafter\endgroup
+ \ifx \do\gobble_one
+ \expandafter\expandafter \expandafter\if_true
+ \else
+ \expandafter\expandafter \expandafter\if_false
+ \fi
+ \else
+ \expandafter\gobble_if
+ \fi
+}
+\newdimen\mapfont_scaling
+\mapfont_scaling=1pt
+\newdimen\rawfont_scaling
+\def\vpl_real#1{R~\expandafter\lose_measure\the#1}
+\def\vpl_int#1{D~\the#1}
+\newdimen\side_bearings
+\newdimen\curr_bearings
+\def\make_header#1{
+ \global\font_count=0
+ \setdim{designsize}{10pt}
+ \a_dimen=\dim{designsize}
+ \out_line{(DESIGNSIZE~\vpl_real\a_dimen)}
+ \x_setstr{codingscheme}{UNKNOWN}
+ \out_line{(CODINGSCHEME~\str{codingscheme})}
+ \ifisint{boundarychar}\then
+ \x_setint{\percent_char boundarychar}{\int{boundarychar}}
+ \immediate\write16{Please~use~\string\setleftboundary\space
+ and/or~\string\makerightboundary^^J
+ instead~of~setting~the~boundarychar~integer.}
+ \fi
+ \ifisint{\percent_char boundarychar}\then
+ \a_count=\int{\percent_char boundarychar}
+ \out_line{(BOUNDARYCHAR~\vpl_int\a_count)}
+ \fi
+ \x_setint{letterspacing}{0}
+ \side_bearings=\make_factor{\int{letterspacing}}\half_point
+ \x_setint{minimumkern}{0}
+ \minimum_kern=\int{minimumkern}
+ \out_line{}
+}
+\def\make_mapfonts#1{
+ \let\saved_scale\vpl_scale
+ \let\saved_mapfont\vpl_mapfont
+ \let\do_slot=\do_mapfont
+ \pre_second_etx_pass_hook
+ #1
+ \post_second_etx_pass_hook
+ \out_line{}
+}
+\def\do_mapfont{
+ \ifisglyph\slot_name\then
+ \mapfonts\slot_name
+ \fi
+}
+\def\vpl_scale#1#2{{
+ \mapfont_scaling=\make_factor{#1}\mapfont_scaling
+ #2
+}}
+\def\vpl_mapfont#1#2{
+ \a_dimen=#2
+ \if_undefined{\the\mapfont_scaling-#1}\then
+ \global\x_cs\mathchardef{\the\mapfont_scaling-#1}=\font_count
+ \x_cs\xdef{f-\the\font_count}{\the\mapfont_scaling-#1}
+ \out_line{(MAPFONT~\vpl_int\font_count\space
+ (FONTNAME~#1)~
+ (FONTDSIZE~\vpl_real\a_dimen)~
+ (FONTAT~\vpl_real\mapfont_scaling))}
+ \record_usage{#1}
+ \global\advance\font_count by 1
+ \fi
+}
+\def\pl_mapfont#1#2{\global\rawfont_scaling=\mapfont_scaling}
+\newcount\font_count
+\newcount\next_mapfont
+\newcount\prev_mapfont
+\def\make_fontdimens#1{
+ \out_line{(FONTDIMEN}
+ \a_count=1
+ \loop\ifnum 256>\a_count
+ \ifisint{fontdimen(\the\a_count)}\then
+ \out_lline{(PARAMETER~\vpl_int\a_count\space
+ R~\make_factor{\int{fontdimen(\the\a_count)}})}
+ \fi
+ \advance \a_count \@ne
+ \repeat
+ \out_lline{)}
+ \out_line{}
+}
+\def\make_ligtable#1{
+ \begingroup
+ \out_line{(LIGTABLE}
+ \def\do_slot{\bgroup
+ \ifisint{boundarychar}\then
+ \ifnum \int{boundarychar}=\slot_number
+ \def\vpl_liglabel{\out_liglabel\boundary_liglabel}
+ \fi
+ \fi
+ }
+ \let\end_do_slot=\vpl_kerning
+ \def\do_boundary{\bgroup \let\vpl_liglabel=\boundary_liglabel}
+ \let\endsetleftboundary=\vpl_kerning
+ \let\ligature=\vpl_ligature
+ \let\k=\vpl_kern
+ \let\rbserver_do=\vpl_rbserver_do
+ \let\rboundary_do=\vpl_rboundary_do
+ \pre_third_etx_pass_hook
+ #1
+ \post_third_etx_pass_hook
+ \out_lline{)}
+ \endgroup
+ \out_line{}
+}
+\def\vpl_rbserver_do#1{
+ \do{#1}
+ \let\rboundary_do=\wrn_rboundary_do
+}
+\def\vpl_rboundary_do#1{
+ \do{#1}
+ \let\rbserver_do=\wrn_rboundary_do
+}
+\def\wrn_rboundary_do#1{
+ \do{#1}
+ \immediate\write16{Boundarychar~slot~usage~collision~in~
+ `\slot_name'~ligkern~program.}
+}
+\def\vpl_ligature#1#2#3{
+ \get_slot_num{#3}
+ \ifnum -1=\result
+ \immediate\write16{Warning:~\string\ligature\space
+ for~unknown~slot~`#3'.}
+ \else
+ \x_cs\ifx{slots-#2}\x_relax
+ \immediate\write16{Warning:~\string\ligature\space
+ for~unknown~slot~`#2'.}
+ \else
+ \def\do##1{
+ \vpl_liglabel
+ \out_lline{(#1~D~\number`##1~\space\vpl_int\result)~
+ (COMMENT~#2~#3)}
+ }
+ \csname slots-#2\endcsname
+ \fi
+ \fi
+}
+\def\vpl_kerning{
+ \let\do=\vpl_kern_do
+ \csname~r-\slot_name\endcsname
+ \vpl_ligstop
+ \egroup
+}
+\def\vpl_kern#1#2{
+ \edef\a_macro{\expandafter\gobble_three\string#1}
+ \a_count=\expandafter\gobble_one\string#2\x_relax
+ \ifnum \ifnum -\a_count>\a_count - \fi\a_count>\minimum_kern
+ \edef\b_macro{~R~\make_factor\a_count}
+ \csname slots-\a_macro\endcsname
+ \fi
+ \x_cs\let{slots-\a_macro}=\x_relax
+}
+\def\vpl_kern_do#1{
+ \vpl_liglabel
+ \out_lline{
+ (KRN~D~\number`#1~\b_macro)~
+ (COMMENT~\a_macro)
+ }
+}
+\def\out_liglabel{
+ \out_lline{(LABEL~\vpl_int\slot_number)~(COMMENT~\slot_name)}
+ \let\vpl_liglabel=\x_relax
+ \let\vpl_ligstop=\out_ligstop
+}
+\def\boundary_liglabel{
+ \out_lline{(LABEL~BOUNDARYCHAR)~(COMMENT~\slot_name)}
+ \let\vpl_liglabel=\x_relax
+ \let\vpl_ligstop=\out_ligstop
+}
+\let\vpl_liglabel=\out_liglabel
+\def\out_ligstop{\out_lline{(STOP)}
+ \let\vpl_liglabel=\out_liglabel
+ \let\vpl_ligstop=\x_relax}
+\let\vpl_ligstop=\x_relax
+\def\make_characters#1{
+ \bgroup
+ \let\do_slot=\do_character
+ \let\end_do_slot=\end_do_character
+ \let\nextlarger=\vpl_nextlarger
+ \let\varchar=\vpl_varchar
+ \let\endvarchar=\end_vpl_varchar
+ \let\vartop=\vpl_vartop
+ \let\varmid=\vpl_varmid
+ \let\varbot=\vpl_varbot
+ \let\varrep=\vpl_varrep
+ \if_including_map_
+ \let\saved_raw\vpl_raw
+ \let\saved_rule\vpl_rule
+ \let\saved_special\vpl_special
+ \let\saved_warning\vpl_warning
+ \let\saved_movert\vpl_movert
+ \let\saved_moveup\vpl_moveup
+ \let\saved_push\vpl_push
+ \let\saved_pop\vpl_pop
+ \else
+ \def\do_character_map{
+ \ifdim \rawfont_scaling=-\p@
+ \mapfonts\slot_name
+ \else
+ \let\do_character_map=\x_relax
+ \fi
+ }
+ \let\saved_mapfont\pl_mapfont
+ \let\saved_scale\vpl_scale
+ \fi
+ \pre_fourth_etx_pass_hook
+ #1
+ \post_fourth_etx_pass_hook
+ \egroup
+}
+\def\do_character{
+ \if_undefined{g-\slot_name}\then
+ \ifisint{requireglyphs}\then
+ \fontinstwarning{ETX~to~(V)PL}{
+ Undefined~glyph~`\slot_name'~requested\message_break
+ for~slot~\the\slot_number\message_number}
+ \fi
+ \expandafter\gobble_setslot
+ \else
+ \ifx\slot_name\notdef_name\else
+ \out_line{(CHARACTER~\vpl_int\slot_number\space
+ (COMMENT~\slot_name)}
+ \glyph_parameter\glyph_metrics\slot_name
+ \a_dimen=\make_factor\a_count \p@
+ \do_character_sidebearings
+ \out_lline{(CHARWD~\vpl_real\a_dimen)}
+ \ifnum \z@=\b_count \else
+ \out_lline{(CHARHT~R~\make_factor\b_count)}
+ \fi
+ \ifnum \z@=\c_count \else
+ \out_lline{(CHARDP~R~\make_factor\c_count)}
+ \fi
+ \ifnum \z@=\d_count \else
+ \out_lline{(CHARIC~R~\make_factor\d_count)}
+ \fi
+ \do_character_map
+ \fi
+ \fi
+}
+\def\do_character_sidebearings{
+ \ifisint{\slot_name-spacing}\then
+ \curr_bearings=\make_factor{\int{\slot_name-spacing}}\half_point
+ \else
+ \curr_bearings=\side_bearings
+ \fi
+ \advance\a_dimen by 2\curr_bearings
+}
+\def\do_character_map{
+ \global\prev_mapfont=0
+ \out_lline{(MAP}
+ \ifdim 0pt=\curr_bearings
+ \mapcommands\slot_name
+ \else
+ \out_llline{(MOVERIGHT~\vpl_real\curr_bearings)}
+ \mapcommands\slot_name
+ \out_llline{(MOVERIGHT~\vpl_real\curr_bearings)}
+ \fi
+ \out_llline{)}
+}
+\long\def\gobble_setslot#1\endsetslot{\endsetslot}
+\def\end_do_character{
+ \ifisglyph\slot_name\then
+ \out_lline{)}
+ \fi
+}
+\def\notdef_name{.notdef}
+\def\vpl_nextlarger#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_lline{(NEXTLARGER~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\nextlarger\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varchar{\out_lline{(VARCHAR}}
+\def\end_vpl_varchar{\out_llline{)}}
+\def\vpl_vartop#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(TOP~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\vartop\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varmid#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(MID~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varmid\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varbot#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(BOT~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varbot\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varrep#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(REP~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varrep\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_raw#1#2#3{
+ \global\next_mapfont=\csname\the\mapfont_scaling-#1\endcsname
+ \ifnum \next_mapfont=\prev_mapfont \else
+ \out_llline{(SELECTFONT~\vpl_int\next_mapfont)~
+ (COMMENT~#1~at~
+ \expandafter\lose_measure \the\mapfont_scaling)}
+ \fi
+ \out_llline{(SETCHAR~D~#2)~(COMMENT~#3)}
+ \global\prev_mapfont=\next_mapfont
+}
+\def\vpl_rule#1#2{
+ \a_dimen=\make_factor{#2}\mapfont_scaling
+ \b_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(SETRULE~\vpl_real\a_dimen\space\vpl_real\b_dimen)}
+}
+\def\vpl_special#1{
+ \out_llline{(SPECIAL~#1)}}
+\def\vpl_warning#1{
+ \ifwarningspecials
+ \out_llline{(SPECIAL~Warning:~#1)}
+ \fi
+ \immediate\write16{Warning:~#1.}
+}
+\newif\ifwarningspecials
+\warningspecialstrue
+\def\vpl_movert#1{
+ \a_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(MOVERIGHT~\vpl_real\a_dimen)}
+}
+\def\vpl_moveup#1{
+ \a_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(MOVEUP~\vpl_real\a_dimen)}
+}
+\def\vpl_push{\out_llline{(PUSH)}}
+\def\vpl_pop{\out_llline{(POP)}}
+\def\make_tidy#1{
+ \tidying_up_hook
+ \if_including_map_
+ \a_count=0
+ \loop\ifnum \a_count<\font_count
+ \edef\a_macro{\csname~f-\the\a_count\endcsname}
+ \global\x_cs\let\a_macro\x_relax
+ \advance\a_count by 1
+ \repeat
+ \global\font_count=0
+ \else
+ \ifdim \rawfont_scaling<\z@
+ \fontinstwarning{ETX~to~(V)PL}{The~font~
+ \out_filename\space doesn't~contain~any~characters}
+ \global\rawfont_scaling=\p@
+ \fi
+ \ifdim \rawfont_scaling=\p@ \else
+ \out_line{(DESIGNUNITS~\vpl_real\rawfont_scaling)}
+ \fi
+ \fi
+}
+\newtoks\family_toks
+\def\installfonts{
+ \bgroup
+ \global\family_toks={}
+ \gdef\prev_file_list{}
+ \global\let\setsomething_global=\global
+}
+\def\installfamily#1#2#3{
+ \global\family_toks=
+ \expandafter{\the\family_toks\fd_family{#1}{#2}{#3}}
+ \global\x_cs\let{#1-#2}\empty_command
+}
+\def\installfont#1#2#3#4#5#6#7#8{
+ \global\let\setsomething_global=\x_relax
+ \input_metrics{}{#2}
+ \etxtovpl{#3}{#1}
+ \installfontas{#1}{#4}{#5}{#6}{#7}{#8}
+ \global\let\setsomething_global=\global
+}
+\def\installrawfont#1#2#3#4#5#6#7#8{
+ \global\let\setsomething_global=\x_relax
+ \xdef\out_filename{#1}
+ \input_metrics{\let\storemapdata=\installraw_storemap}{#2}
+ \let\storemapdata=\gobble_three
+ \etxtopl{#3}{#1}
+ \record_usage{#1}
+ \installfontas{
+ \ifdim \rawfont_scaling=\p@ \else
+ [\expandafter\lose_measure\the\rawfont_scaling]~
+ \fi #1
+ }{#4}{#5}{#6}{#7}{#8}
+ \global\let\setsomething_global=\global
+}
+\def\installraw_storemap#1#2#3{
+ \def\a_macro{#1}
+ \ifx \a_macro\out_filename \else
+ \record_transform{\out_filename}{\string\frommtx{#1}}{}\if_false
+ \fi
+}
+\def\input_metrics#1#2{
+ \let\metrics=\file_list_metrics
+ \xdef\curr_file_list{#2,}
+ \let\metrics=\x_relax
+ \ifx\prev_file_list\curr_file_list\else
+ \egroup\bgroup
+ #1
+ \expandafter\process_csep_list \expandafter\input_mtx_file
+ \curr_file_list\process_csep_list,
+ \global\let\prev_file_list=\curr_file_list
+ \fi
+}
+\def\file_list_metrics#1,{
+ \iffalse{\fi}
+ \a_toks=\expandafter{\curr_file_list\x_relax#1,}
+ \xdef\curr_file_list{\the\a_toks \iffalse}\fi
+}
+\def\installfontas#1#2#3#4#5#6{
+ \if_undefined{#2-#3-#4-#5}\then
+ \let\do_shape=\x_relax
+ \if_undefined{#2-#3}\then
+ \x_cs\let{#2-#3}\empty_command
+ \autoinstallfamily{#2}{#3}
+ \fi
+ \x_cs\xdef{#2-#3}{
+ \csname#2-#3\endcsname
+ \do_shape{#2}{#3}{#4}{#5}
+ }
+ \fi
+ \let\do_size=\x_relax
+ \x_cs\xdef{#2-#3-#4-#5}{
+ \if_defined{#2-#3-#4-#5}\then
+ \csname#2-#3-#4-#5\endcsname
+ \fi
+ \do_size{#6}{#1}
+ }
+}
+\def\autoinstallfamily#1#2{\installfamily{#1}{#2}{}}
+\def\endinstallfonts{
+ \global\let\setsomething_global=\x_relax
+ \let\do_shape=\fd_shape
+ \let\do_size=\fd_size
+ \the\family_toks
+ \global\family_toks{}
+ \egroup
+}
+\def\input_mtx_file#1{
+ \reset_modifiers_hook
+ \ifx\x_relax#1\x_relax
+ \else
+ \identity_one{\get_file_name #1~}~\par
+ \ifx \pl_encoding\empty_command
+ \fromany\file_name
+ \else
+ \metrics_given_encoding{\file_name}{\pl_encoding}
+ \fi
+ \ifisstr{afm-name}\then
+ \inputmtx{\str{afm-name}}
+ \else
+ \fontinsterror{\string\install...}{
+ Font/MTX~file~\file_name\space not~found
+ }{
+ You~can~insert~an~\string\inputmtx\space command~here
+ \messagebreak to~input~some~other~MTX~file~instead.
+ \ifisint{rawscale}\then \messagebreak
+ The~requested~raw~scaling~will~then~be~applied~on~that.
+ \fi
+ }
+ \fi
+ \fi
+}
+\def\metrics_given_encoding#1#2{
+ \x_cs\edef{s-afm-name}{#1-#2}
+ \if_file_exists{#1.pl}\then
+ \generalpltomtx{#1}{#1-#2}{pl}{#2}
+ \else
+ \if_file_exists{#1.vpl}\then
+ \generalpltomtx{#1}{#1-#2}{vpl}{#2}
+ \else
+ \unsetstr{afm-name}
+ \fi\fi
+}
+\def\reset_modifiers_hook{
+ \unsetint{rawscale}
+ \let\glyph_name_modifier\identity_one
+ \let\pl_encoding\empty_command
+ \let\list_of_options\empty_command
+}
+\def\get_file_name #1~{
+ \edef\file_name{#1}
+ \get_keyword
+}
+\def\get_keyword #1~{
+ \if_defined{IFKW-#1}\then
+ \csname IFKW-#1 \expandafter\endcsname
+ \else
+ \fontinsterror{\string\install...}{
+ `#1'~is~not~a~defined~keyword
+ }{
+ \error_help_a\messagebreak
+ Extra~tokens~will~be~flushed.
+ }
+ \expandafter\gobble_keywords
+ \fi
+}
+\def\gobble_keywords#1\par{}
+\x_cs\let{IFKW-}=\gobble_keywords
+\x_cs\def{IFKW-scaled}#1~{
+ \ifnum #1=\one_thousand
+ \unsetint{rawscale}
+ \else
+ \x_resetint{rawscale}{#1}
+ \fi
+ \get_keyword
+}
+\x_cs\def{IFKW-suffix}#1~{
+ \def\glyph_name_modifier##1{##1#1}
+ \get_keyword
+}
+\x_cs\def{IFKW-encoding}#1~{
+ \def\pl_encoding{#1}
+ \get_keyword
+}
+\let\pl_encoding=\empty_command
+\x_cs\def{IFKW-option}#1~{
+ \add_to\list_of_options{\do{#1}}
+}
+\def\ifoption#1\then{
+ \_a_false
+ \edef\a_macro{#1}
+ \def\do##1{
+ \if_a_ \else
+ \def\b_macro{##1}
+ \ifx \a_macro\b_macro \_a_true \fi
+ \fi
+ }
+ \list_of_options
+ \if_a_
+}
+\let\list_of_options\empty_command
+\def\fd_family#1#2#3{
+ \a_toks{#3}
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1#2.fd}}}
+ \lowercase_file
+ \open_out{\lowercase_file}
+ \out_line{\percent_char~Filename:~\lowercase_file}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using~fontinst~v\fontinstversion}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~SHOULD~BE~PUT~IN~A~TEX~INPUTS~
+ DIRECTORY}
+ \out_line{}
+ \out_line{\string\ProvidesFile{\lowercase_file}}
+ \out_lline{[
+ \the\year/
+ \ifnum10>\month0\fi\the\month/
+ \ifnum10>\day0\fi\the\day\space
+ Fontinst~v\fontinstversion\space
+ font~definitions~for~#1/#2.
+ ]}
+ \out_line{}
+ \out_line{\string\DeclareFontFamily{#1}{#2}{\the\a_toks}}
+ {
+ \csname #1-#2\endcsname
+ \out_line{}
+ \let\do_shape=\substitute_shape
+ \csname #1-#2\endcsname
+ \let\do_shape=\remove_shape
+ \csname #1-#2\endcsname
+ }
+ \x_cs\g_let{#1-#2}\x_relax
+ \out_line{}
+ \out_line{\string\endinput}
+ \close_out{Font~definitions}
+}
+\def\fd_shape#1#2#3#4{
+ \out_line{}
+ \out_line{\string\DeclareFontShape{#1}{#2}{#3}{#4}\left_brace_char}
+ \csname #1-#2-#3-#4\endcsname
+ \x_cs\g_let{#1-#2-#3-#4}\empty_command
+ \out_line{\right_brace_char{}}
+}
+\def\fd_size#1#2{
+ \x_cs\ifx{siz-#1}\x_relax
+ \out_lline{#1~#2}
+ \else
+ \out_lline{\csname siz-#1\endcsname\space #2}
+ \fi
+}
+\def\remove_shape#1#2#3#4{
+ \x_cs\g_let{#1-#2-#3-#4}\x_relax
+}
+\def\substitute_shape#1#2#3#4{
+ \edef\orig_shape{#4}
+ \substitute_series{#1}{#2}{#3}{\orig_shape}
+ \x_cs\ifx{sub-\orig_shape}\x_relax\else
+ \edef\subst_shape{\csname sub-\orig_shape\endcsname}
+ \x_cs\ifx{#1-#2-#3-\subst_shape}\x_relax
+ \out_line{
+ \string\DeclareFontShape{#1}{#2}{#3}{\subst_shape}{
+ <->\csname typ-\orig_shape\endcsname\space
+ *~#2/#3/\orig_shape
+ }{}
+ }
+ \x_cs\let{#1-#2-#3-\subst_shape}\empty_command
+ \substitute_shape{#1}{#2}{#3}{\subst_shape}
+ \fi
+ \fi
+}
+\def\substitute_series#1#2#3#4{
+ \edef\orig_series{#3}
+ \x_cs\ifx{sub-\orig_series}\x_relax\else
+ \edef\subst_series{\csname sub-\orig_series\endcsname}
+ \x_cs\ifx{#1-#2-\subst_series-#4}\x_relax
+ \out_line{
+ \string\DeclareFontShape{#1}{#2}{\subst_series}{#4}{
+ <->\csname typ-\orig_series\endcsname\space
+ *~#2/\orig_series/#4
+ }{}
+ }
+ \x_cs\let{#1-#2-\subst_series-#4}\empty_command
+ \substitute_series{#1}{#2}{\subst_series}{#4}
+ \fi
+ \fi
+}
+\def\substitute_generic#1#2#3{
+ \edef\a_macro{#2}
+ \edef\b_macro{#3}
+ \ifx \a_macro \b_macro
+ \x_cs\let{sub-#3}\undefined_command
+ \else
+ \x_cs\let{sub-#3}\a_macro
+ \x_cs\def{typ-#3}{#1}
+ \fi
+}
+\def\substitutesilent{\substitute_generic{ssub}}
+\def\substitutenoisy{\substitute_generic{sub}}
+\substitutesilent{bx}{b}
+\substitutesilent{b}{bx}
+\substitutesilent{b}{sb}
+\substitutesilent{b}{db}
+\substitutesilent{m}{mb}
+\substitutesilent{m}{l}
+\substitutenoisy{ui}{it}
+\substitutesilent{sl}{it}
+\substitutesilent{it}{sl}
+\def\declareencoding#1#2{\x_cs\edef{enc-#1}{#2}}
+\declareencoding{TEX~TEXT}{ot1}
+\declareencoding{TEX~TEXT~WITHOUT~F-LIGATURES}{ot1}
+\declareencoding{TEX~TYPEWRITER~TEXT}{ot1tt}
+\declareencoding{TEX~MATH~ITALIC}{oml}
+\declareencoding{TEX~MATH~SYMBOLS}{oms}
+\declareencoding{TEX~MATH~EXTENSION}{omx}
+\declareencoding{LATEX~SYMBOLS}{lasy}
+\declareencoding{TEX~TEXT~SUBSET}{eufrak}
+\declareencoding{TEX~MATH~ITALIC~SUBSET}{eurm}
+\declareencoding{TEX~MATH~SYMBOLS~SUBSET}{euscr}
+\declareencoding{EULER~SUBSTITUTIONS~ONLY}{euex}
+\declareencoding{EXTENDED~TEX~FONT~ENCODING~-~LATIN}{t1}
+\declareencoding{TEX~TEXT~COMPANION~SYMBOLS~1---TS1}{ts1}
+\declareencoding{TEXBASE1ENCODING}{8r}
+\declareencoding{TEX~TYPEWRITER~AND~WINDOWS~ANSI}{8y}
+\def\declaresize#1#2{\x_cs\edef{siz-#1}{#2}}
+\declaresize{}{<->}
+\declaresize{5}{<5>}
+\declaresize{6}{<6>}
+\declaresize{7}{<7>}
+\declaresize{8}{<8>}
+\declaresize{9}{<9>}
+\declaresize{10}{<10>}
+\declaresize{11}{<10.95>}
+\declaresize{12}{<12>}
+\declaresize{14}{<14.4>}
+\declaresize{17}{<17.28>}
+\declaresize{20}{<20.74>}
+\declaresize{25}{<24.88>}
+\def\NOFILES{
+ \def\transformfont##1##2{
+ \touch_file{##1.mtx}
+ \touch_file{##1.pl}
+ }
+ \def\reglyphfont##1##2{\touch_file{##1.mtx}}
+ \def\installfonts{}
+ \def\endinstallfonts{}
+ \def\installfont##1##2##3##4##5##6##7##8{
+ \touch_file{##1.vpl}
+ }
+ \def\installrawfont##1##2##3##4##5##6##7##8{
+ \touch_file{##1.pl}
+ }
+ \def\installfamily##1##2##3{\touch_file{##1##2.fd}}
+}
+\def\touch_file#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \open_out{\lowercase_file}
+ \out_line{\percent_char~TEST~FILE.}
+ \out_line{\percent_char~Created~whilst~debugging~fontinst.}
+ \close_out{Test~file}
+}
+%%% From file: fitrig.dtx
+\chardef\nin@ty=90
+\chardef\@clxxx=180
+\chardef\@lxxi=71
+\mathchardef\@mmmmlxviii=4068
+\chardef\@coeffz=72
+\chardef\@coefb=42
+\mathchardef\@coefc=840
+\mathchardef\@coefd=5040
+\def\TG@rem@pt#1{\expandafter\lose_measure\the#1\space}
+\def\TG@term#1{
+ \dimen@\@tempb\dimen@
+ \advance\dimen@ #1\p@
+}
+\def\TG@series{
+ \dimen@\@lxxi\dimen@
+ \divide \dimen@ \@mmmmlxviii
+ \edef\@tempa{\TG@rem@pt\dimen@}
+ \dimen@\@tempa\dimen@
+ \edef\@tempb{\TG@rem@pt\dimen@}
+ \divide\dimen@\@coeffz
+ \advance\dimen@\m@ne\p@
+ \TG@term\@coefb
+ \TG@term{-\@coefc}%
+ \TG@term\@coefd
+ \dimen@\@tempa\dimen@
+ \divide\dimen@ \@coefd
+}
+\def\CalculateSin#1{{%
+ \if_undefined{sin(\number#1)}\then
+ \dimen@=#1\p@
+ \TG@@sin
+ \x_cs\xdef{sin(\number#1)}{\TG@rem@pt\dimen@}
+ \fi
+}}
+\def\CalculateCos#1{{%
+ \if_undefined{cos(\number#1)}\then
+ \dimen@=\nin@ty\p@
+ \advance \dimen@ -#1\p@
+ \TG@@sin
+ \x_cs\xdef{cos(\number#1)}{\TG@rem@pt\dimen@}
+ \fi
+}}
+\def\TG@@sin{%
+ \ifdim\TG@reduce>+%
+ \else\ifdim\TG@reduce<-%
+ \else\TG@series\fi\fi
+}
+\def\TG@reduce#1#2{
+ \dimen@#1#2\nin@ty\p@
+ \advance\dimen@#2-\@clxxx\p@
+ \dimen@-\dimen@
+ \TG@@sin
+}
+\def\UseSin#1{\csname sin(\number#1)\endcsname}
+\def\UseCos#1{\csname cos(\number#1)\endcsname}
+\chardef\z@num\z@
+\x_cs\let{sin(0)} \z@num
+\x_cs\let{cos(0)} \@ne
+\x_cs\let{sin(90)} \@ne
+\x_cs\let{cos(90)} \z@num
+\x_cs\let{sin(-90)}\m@ne
+\x_cs\let{cos(-90)}\z@num
+\x_cs\let{sin(180)}\z@num
+\x_cs\let{cos(180)}\m@ne
+\def\CalculateTan#1{{%
+ \if_undefined{tan(\number#1)}\then
+ \CalculateSin{#1}%
+ \CalculateCos{#1}%
+ \a_dimen\UseCos{#1}\p@
+ \divide \a_dimen \@iv
+ \b_dimen\UseSin{#1}\p@
+ \b_dimen\two@fourteen\b_dimen
+ \divide\b_dimen\a_dimen
+ \x_cs\xdef{tan(\number#1)}{\TG@rem@pt\b_dimen}
+ \fi
+}}
+\def\UseTan#1{\csname tan(\number#1)\endcsname}
+\mathchardef\two@fourteen=16384
+\chardef\@iv=4
+\x_cs\def{tan(90)}{\errmessage{Infinite tan !}}
+\expandafter\let
+ \csname tan(-90)\expandafter\endcsname \csname tan(90)\endcsname
+%%% From file: ficonv.dtx
+\def\afmtomtx#1#2{{
+ \let\setsomething_global=\x_relax
+ \open_out{\temp_prefix#2.mtx}
+ \edef\raw_font_name{#2}
+ \edef\source_font_name{#1}
+ \x_resetint{italicslant}{0}
+ \let\italcorr_expression=\uprightitalcorr
+ \x_setint{minimumkern}{0}
+ \minimum_kern=\int{minimumkern}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\afmtomtx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.afm~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \catcode`\^^M=12
+ \catcode`\ =10
+ \expandafter\afm_line\primitiveinput #1.afm\x_relax
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Metrics}
+}}
+\newcount\minimum_kern
+\def\afm_length#1#2{
+ \a_dimen=#2\afm_unit_dimen
+ #1=\a_dimen
+ \divide #1 by \afm_unit_dimen
+ \advance \a_dimen by -#1\afm_unit_dimen
+ \ifdim \a_dimen>0.5\afm_unit_dimen
+ \advance #1 by 1
+ \else \ifdim \a_dimen<-0.5\afm_unit_dimen
+ \advance #1 by -1
+ \fi\fi
+ \x_relax
+}
+\newdimen\afm_unit_dimen
+\afm_unit_dimen=1000sp
+{\catcode`\^^M=12 \gdef\afm_line#1
+{\afm_command#1~\end_of_line\afm_line}}
+\def\afm_command#1~{\csname~afm-#1\endcsname\gobble_one_line}
+\def\gobble_one_line#1\end_of_line{}
+\x_cs\def{afm-EndFontMetrics}#1\afm_line{\endinput}
+\def\afm_def#1(#2)#3{
+ \x_cs\def{afm-#1}\gobble_one_line#2\end_of_line{#3}
+}
+\def\afm_let#1#2{
+ \expandafter\let \csname afm-#1\expandafter\endcsname
+ \csname afm-#2\endcsname
+}
+\afm_def{CharWidth}(#1){\afm_length\char_x_width{#1}}
+\afm_def{ItalicAngle}(#1~){\calculate_it_slant{#1}}
+\afm_def{XHeight}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{xheight}{\the\a_count}}}
+\afm_def{CapHeight}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{capheight}{\the\a_count}}}
+\afm_def{Ascender}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{ascender}{\the\a_count}}}
+\afm_def{Descender}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{descender_neg}{\the\a_count}}}
+\afm_def{UnderlineThickness}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{underlinethickness}{\the\a_count}}}
+\afm_def{FontBBox}(#1~#2~#3~#4){
+ \afm_length\a_count{#4}
+ \out_line{\string\setint{maxheight}{\the\a_count}}
+ \afm_length\a_count{#2}
+ \out_line{\string\setint{maxdepth_neg}{\the\a_count}}}
+\afm_def{StdVW}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{verticalstem}{\the\a_count}}}
+\afm_def{IsFixedPitch}(#1){
+ \if\first_char#1=f
+ \else\out_line{\string\setint{monowidth}{1}}
+ \fi
+}
+\afm_def{FontName}(#1~){
+ \record_transform{\raw_font_name}
+ {\string\fromafm{\source_font_name}{#1}}{}\iftrue
+}
+\afm_def{KP}(#1~#2~#3~#4){
+ \if\first_char#1=.\else
+ \if\first_char#2=.\else
+ \afm_length\a_count{#3}
+ \ifnum \a_count>\minimum_kern
+ \afm_write_setkern{#1}{#2}{\the\a_count}
+ \else\ifnum \a_count<-\minimum_kern
+ \afm_write_setkern{#1}{#2}{\the\a_count}
+ \fi\fi
+ \fi\fi
+}
+\afm_let{KPX}{KP}
+\def\afm_write_setkern#1#2#3{\out_line{\string\setkern{#1}{#2}{#3}}}
+\afm_def{C}(#1~;#2){\init_afm{#1}\do_list[#2]\afm_char}
+\afm_def{CH}(<#1>~;#2){\uppercase{\init_afm{"#1}}\do_list[#2]\afm_char}
+\afm_def{CC}(#1~#2~;#3){\init_cc{#1}\do_list[#3]\cc_char}
+\newcount\char_slot
+\newcount\char_x_width
+\newcount\x_width
+\newcount\bbox_llx
+\newcount\bbox_lly
+\newcount\bbox_urx
+\newcount\bbox_ury
+\let\char_name=\empty_command
+\def\init_afm#1{
+ \char_slot=#1\x_relax
+ \x_width=\char_x_width
+ \bbox_llx=0
+ \bbox_lly=0
+ \bbox_urx=0
+ \bbox_ury=0
+ \let\char_name=\empty_command
+}
+\def\afm_char{
+ \eval_expr{
+ \italcorr_expression\x_width\bbox_llx\bbox_urx\bbox_lly\bbox_ury
+ }
+ \out_line{
+ \ifnum -1<\char_slot
+ \string\setrawglyph
+ \else
+ \string\setnotglyph
+ \fi
+ {\char_name}
+ {\raw_font_name}
+ {10pt}
+ {\the\char_slot}
+ {\the\x_width}
+ {\the\bbox_ury}
+ {\number -\bbox_lly}
+ {\the\result}
+ }
+}
+\def\init_cc#1{%
+ \out_line{\string\setglyph{#1}}
+ \def\char_name{#1}
+}
+\def\cc_char{%
+ \out_lline{\string\samesize{\char_name-not}}
+ \out_line{\string\endsetglyph}
+}
+\def\uprightitalcorr#1#2#3#4#5{0}
+\def\slanteditalcorr#1#2#3#4#5{\max{\sub{#3}{#1}}{0}}
+\def\calculate_it_slant#1{
+ \edef\theangle{#1}
+ \CalculateTan{\theangle}
+ \a_dimen=-\one_thousand sp
+ \a_dimen=\UseTan{\theangle}\a_dimen
+ \a_count=\a_dimen
+ \out_line{\string\setint{italicslant}{\the\a_count}}
+ \x_resetint{italicslant}{\a_count}
+ \ifnum 0<\a_count
+ \let\italcorr_expression=\slanteditalcorr
+ \else
+ \let\italcorr_expression=\uprightitalcorr
+ \fi
+}
+\def\do_list[~#1~#2;~#3]{
+ \csname~list-#1\endcsname\gobble_one_semi#2;
+ \ifx\x_relax#3\x_relax\expandafter\gobble_one
+ \else\expandafter\identity_one\fi
+ {\do_list[~#3]}
+}
+\def\gobble_one_semi#1;{}
+\def\list_def#1(#2)#3{\x_cs\def{list-#1}\gobble_one_semi#2~;{#3}}
+\list_def{W}(#1~#2){\afm_length\x_width{#1}}
+\list_def{WX}(#1){\afm_length\x_width{#1}}
+\list_def{WY}(#1){}
+\list_def{N}(#1){\def\char_name{#1}}
+\list_def{B}(#1~#2~#3~#4){
+ \afm_length\bbox_llx{#1}
+ \afm_length\bbox_lly{#2}
+ \afm_length\bbox_urx{#3}
+ \afm_length\bbox_ury{#4}
+}
+\list_def{PCC}(#1~#2~#3){
+ \afm_length\a_count{#2}
+ \afm_length\b_count{#3}
+ \out_lline{\string\glyphpcc{#1}{\the\a_count}{\the\b_count}}
+}
+\def\definealias#1#2#3{
+ \expandafter\def \csname GN-#1 \expandafter\endcsname
+ \expandafter{ \csname g-#2 \expandafter\endcsname
+ \csname i-#3\endcsname}
+}
+\def\glyph_alias#1{
+ \expandafter\expandafter \expandafter\glyph_alias_i
+ \csname GN-#1\endcsname
+}
+\def\glyph_alias_i#1#2{
+ \expandafter\gobble_three \string#1
+}
+\let\charnameprefix\empty
+\def\charnamealias#1{
+ \if_defined{GN-\charnameprefix#1}\then
+ \glyph_alias{\charnameprefix#1}
+ \else\if_defined{GN-#1}\then
+ \glyph_alias{#1}
+ \else
+ #1
+ \fi\fi
+}
+\def\alias_incr#1{
+ \expandafter\expandafter \expandafter\alias_incr_i
+ \csname GN-#1\endcsname
+}
+\def\alias_incr_i#1#2{
+ \ifx#2\x_relax
+ \mathchardef#2=\@ne
+ \else
+ \a_count=#2
+ \advance\a_count\@ne
+ \mathchardef#2=\a_count
+ \fi
+}
+\def\alias_char_name#1{
+ \if_defined{GN-\charnameprefix#1}\then
+ \edef\char_name{
+ \string\aliased{#1}{\glyph_alias{\charnameprefix#1}}
+ }
+ \alias_incr{\charnameprefix#1}
+ \else\if_defined{GN-#1}\then
+ \edef\char_name{
+ \string\aliased{#1}{\glyph_alias{#1}}
+ }
+ \alias_incr{#1}
+ \else
+ \edef\char_name{#1}
+ \fi\fi
+}
+\def\autoaliasafm{
+ \begingroup
+ \list_def{N}(##1){\alias_char_name{##1}}
+ \def\afm_write_setkern##1##2##3{
+ \out_line{
+ \string\setkern{\charnamealias{##1}}{\charnamealias{##2}}{##3}
+ }
+ }
+ \def\init_cc##1{%
+ \edef\char_name{\charnamealias{##1}}
+ \out_line{\string\setglyph{\char_name}}
+ }
+ \list_def{PCC}(##1~##2~##3){
+ \afm_length\a_count{##2}
+ \afm_length\b_count{##3}
+ \out_lline{\string\glyphpcc
+ {\charnamealias{##1}}{\the\a_count}{\the\b_count}}
+ }
+}
+\def\endautoaliasafm{\endgroup}
+\def\generalpltomtx#1#2#3#4{{
+ \let\setsomething_global=\x_relax
+ \let\setfontdimen=\pl_setfontdimen
+ \if _#4_ \else
+ \def\do_slot{\x_cs\let{name-\the\slot_number}\slot_name}
+ \def\do_boundary{\x_cs\let{name-BOUNDARYCHAR}\slot_name}
+ \inputetx{#4}
+ \let\CODINGSCHEME=\ignore_parens
+ \fi
+ \pl_to_mtx{#1}{#2}{#3}{\string\generalpltomtx{#1}{#2}{#3}{#4}}
+}}
+\def\pltomtx#1#2{\generalpltomtx{#1}{#2}{pl}{}}
+\def\pl_to_mtx#1#2#3#4{
+ \edef\raw_font_name{#1}
+ \open_out{\temp_prefix#2.mtx}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~#4}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.#3~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \lowercase{
+ \record_transform{#2}{
+ \string\from#3 \x_cs\ifx{from#3}\frompl {#1} \fi
+ }{}\iftrue
+ }
+ \out_line{}
+ \catcode`\(=0 \catcode`\)=9
+ \let\/=\ignore_parens
+ \let\do_pl_glyph=\x_relax
+ \primitiveinput #1.#3\x_relax
+ \do_pl_glyph
+ \out_line{}
+ \ifisint{\percent_char boundarychar}\then
+ \f_count=\int{\percent_char boundarychar}
+ \x_cs\ifx{name-\the\f_count}\x_relax \else
+ \out_line{\string\setstr{rightboundary}
+ {\csname name-\the\f_count\endcsname}
+ }
+ \out_line{}
+ \fi
+ \fi
+ \out_line{\endmetrics_text}
+ \close_out{Metrics}
+}
+\def\ignore_parens{\bgroup\catcode`(=1 \catcode`)=2 \x_relax
+ \expandafter\expandafter\expandafter\gobble_parens
+ \iftrue\expandafter{\else}\fi}
+\def\gobble_parens#1{\egroup}
+\def\pl_real#1{\pl_realer(#1000)}
+\def\pl_realer(#1.#2#3#4#5){#1#2#3#4}
+\def\pl_rounded_real(#1.#2#3#4#5){
+ \global\result=#1#2#3#4\relax
+ \ifnum \first_char#5= >4
+ \global\advance \result
+ \if - \first_char#1= \m@ne \else \@ne \fi
+ \fi
+}
+\def\pl_int#1#2{
+ \ifx#1C `#2
+ \else\ifx#1D #2
+ \else\ifx#1O '#2
+ \else\ifx#1H "#2
+ \else -1\errmessage{Unknown~PL~number~prefix~`#1'}
+ \fi\fi\fi\fi
+}
+\let\FAMILY=\ignore_parens
+\let\FACE=\ignore_parens
+\let\CHECKSUM=\ignore_parens
+\def\HEADER~#1~#2~#3~#4~{}
+\def\SEVENBITSAFEFLAG~#1~{}
+\let\COMMENT=\ignore_parens
+\let\LIG=\ignore_parens
+\let\NEXTLARGER=\ignore_parens
+\let\VARCHAR=\ignore_parens
+\let\VTITLE=\ignore_parens
+\let\MAPFONT=\ignore_parens
+\let\MAP=\ignore_parens
+\def\CODINGSCHEME{\bgroup\catcode`\)=12\x_relax\CODINGSCHEME_cont}
+\def\CODINGSCHEME_cont#1){
+ \egroup
+ \if_undefined{enc-#1}\then
+ \errhelp{The~encoding~for~`#1'~has~not~been~declared.^^J
+ You~should~declare~it~with~
+ \string\declareencoding{#1}{ETXFILE}.^^J
+ Press~<RETURN>~to~carry~on~with~fingers~crossed,^^J
+ or~X~<RETURN>~to~exit.}
+ \errmessage{Undeclared~encoding~`#1'}
+ \else
+ \def\do_slot{\x_cs\let{name-\the\slot_number}\slot_name}
+ \def\do_boundary{\x_cs\let{name-BOUNDARYCHAR}\slot_name}
+ \catcode`\(=12 \catcode`\)=12
+ \x_cs\inputetx{enc-#1}\x_relax
+ \catcode`\(=0 \catcode`\)=9
+ \fi
+}
+\def\DESIGNSIZE~#1~#2~{
+ \a_dimen=#2pt
+ \out_line{\string\setdim{designsize}{\the\a_dimen}}
+}
+\def\DESIGNUNITS~#1~#2~{
+ \b_dimen=#2pt\x_relax
+ \ifdim 1pt=\b_dimen \else
+ \fontinsterror{PL-to-MTX}{Nondefault~unit~used~in~PL~file}
+ {You~may~continue,~but~the~metrics~for~this~font~will~be~wrong.}
+ \fi
+ \out_line{\string\setdim{designunits}{\the\b_dimen}}
+}
+\def\BOUNDARYCHAR~#1~#2~{
+ \x_setint{\percent_char boundarychar}{\pl_int{#1}{#2}}
+}
+\def\pl_setfontdimen#1#2{\x_cs\def{fdimen-#1}{#2}}
+\def\PARAMETER~#1~#2~R~#3~{
+ \f_count=\pl_int{#1}{#2}\x_relax
+ \if_defined{fdimen-\the\f_count}\then
+ \pl_rounded_real(#3 0000)
+ \out_line{\string\setint{\csname fdimen-\the\f_count\endcsname}
+ {\the\result}}
+ \fi
+}
+\let\FONTDIMEN=\x_relax
+\def\SLANT{\PARAMETER D~1~}
+\pl_setfontdimen{1}{italicslant}
+\def\SPACE{\PARAMETER D~2~}
+\pl_setfontdimen{2}{interword}
+\def\STRETCH{\PARAMETER D~3~}
+\pl_setfontdimen{3}{stretchword}
+\def\SHRINK{\PARAMETER D~4~}
+\pl_setfontdimen{4}{shrinkword}
+\def\XHEIGHT{\PARAMETER D~5~}
+\pl_setfontdimen{5}{xheight}
+\def\QUAD{\PARAMETER D~6~}
+\pl_setfontdimen{6}{quad}
+\def\EXTRASPACE{\PARAMETER D~7~}
+\pl_setfontdimen{7}{extraspace}
+\def\NUM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~8~#2~#3~
+ \or
+ \PARAMETER D~9~#2~#3~
+ \or
+ \PARAMETER D~10~#2~#3~
+ \fi
+}
+\def\DENOM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~11~#2~#3~
+ \or
+ \PARAMETER D~12~#2~#3~
+ \fi
+}
+\def\SUP#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~13~#2~#3~
+ \or
+ \PARAMETER D~14~#2~#3~
+ \or
+ \PARAMETER D~15~#2~#3~
+ \fi
+}
+\def\SUB#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~16~#2~#3~
+ \or
+ \PARAMETER D~17~#2~#3~
+ \fi
+}
+\def\SUPDROP{\PARAMETER D~18~}
+\def\SUBDROP{\PARAMETER D~19~}
+\def\AXISHEIGHT{\PARAMETER D~22~}
+\def\DELIM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~20~#2~#3~
+ \or
+ \PARAMETER D~21~#2~#3~
+ \fi
+}
+\def\DEFAULTRULETHICKNESS{\PARAMETER D~8~}
+\def\BIGOPSPACING#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~9~#2~#3~
+ \or
+ \PARAMETER D~10~#2~#3~
+ \or
+ \PARAMETER D~11~#2~#3~
+ \or
+ \PARAMETER D~12~#2~#3~
+ \or
+ \PARAMETER D~13~#2~#3~
+ \fi
+}
+\def\LABEL~#1{\ifx #1B
+ \expandafter\LABEL_boundarychar
+ \else
+ \expandafter\LABEL_slot \expandafter#1
+ \fi
+}
+\def\LABEL_slot #1~#2~{
+ \f_count=\pl_int{#1}{#2}
+ \edef\a_macro{\a_macro
+ \x_cs\do_if_defined{name-\the\f_count}
+ }
+}
+\def\LABEL_boundarychar OUNDARYCHAR{
+ \edef\a_macro{\a_macro
+ \x_cs\do_if_defined{name-BOUNDARYCHAR}
+ }
+}
+\def\do_if_defined#1{\ifx #1\x_relax \else \do{#1} \fi}
+\def\LIGTABLE{\let\do=\never_do\let\a_macro\empty_command}
+\def\STOP{\let\a_macro\empty_command}
+\def\SKIP~#1~#2~{\immediate\write16{Warning:~SKIP~instruction~ignored.}}
+\def\KRN~#1~#2~R~#3~{
+ \pl_rounded_real(#3 0000)
+ \edef\do{\noexpand\write_pl_krn{\pl_int{#1}{#2}}{\the\result}}
+ \a_macro
+ \let\do=\never_do
+}
+\def\write_pl_krn#1#2#3{
+ \f_count=#1\x_relax
+ \x_cs\ifx{name-\the\f_count}\x_relax \else
+ \out_line{\string\setkern{#3}
+ {\csname name-\the\f_count\endcsname}{#2}
+ }
+ \fi
+}
+\def\CHARWD~R~#1~{\pl_rounded_real(#1 0000) \b_count=\result}
+\def\CHARHT~R~#1~{\pl_rounded_real(#1 0000) \c_count=\result}
+\def\CHARDP~R~#1~{\pl_rounded_real(#1 0000) \d_count=\result}
+\def\CHARIC~R~#1~{\pl_rounded_real(#1 0000) \e_count=\result}
+\def\CHARACTER~#1~#2~{
+ \do_pl_glyph
+ \a_count=\pl_int{#1}{#2}
+ \b_count=0
+ \c_count=0
+ \d_count=0
+ \e_count=0
+ \let\do_pl_glyph=\write_pl_glyph
+}
+\def\write_pl_glyph{
+ \x_cs\ifx{name-\the\a_count}\x_relax\else
+ \out_line{\string\setrawglyph
+ {\csname~name-\the\a_count\endcsname}
+ {\raw_font_name}
+ {\the\a_dimen}
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {\the\e_count}}
+ \fi
+ }
+\def\mtxtopl#1#2{{
+ \let\setsomething_global=\x_relax
+ \open_out{#2.pl}
+ \top_of_pl_hook
+ \out_line{(COMMENT~raw~font~#2~created~by~fontinst~
+ v\fontinstversion)}
+ \out_line{}
+ \out_line{(COMMENT~Filename:~#2.pl)}
+ \out_line{(COMMENT~Created~by:~tex~\jobname)}
+ \out_line{(COMMENT~Created~using:~\string\mtxtopl{#1}{#2})}
+ \out_line{}
+ \out_line{(COMMENT~This~file~can~be~turned~into~
+ a~ligless~TeX~font~with)}
+ \out_line{(COMMENT~pltotf~#2.pl~#2.tfm)}
+ \out_line{}
+ \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)}
+ \out_line{}
+ \out_line{(DESIGNSIZE~R~10.0)}
+ \out_line{}
+ \let\setglyph=\iffalse
+ \let\endsetglyph=\fi
+ \let\setkern=\gobble_three
+ \let\setscaledrawglyph=\first_pl_raw_glyph
+ \def\setscalednotglyph##1##2##3##4##5##6##7##8##9{}
+ \inputmtx{#1}
+ \out_line{}
+ \out_line{(COMMENT~END~OF~FILE~#2.pl)}
+ \close_out{Raw~font}
+}}
+\def\first_pl_raw_glyph#1#2#3#4{
+ \out_line{(DESIGNUNITS~R~\make_factor{#4})}
+ \let\setscaledrawglyph=\pl_raw_glyph
+ \pl_raw_glyph{#1}{#2}{#3}{#4}
+}
+\def\pl_raw_glyph#1#2#3#4#5#6#7#8#9{
+ \out_line{(CHARACTER~D~\number#5~\space(COMMENT~#1)}
+ \out_lline{(CHARWD~R~\make_factor{#6})}
+ \out_lline{(CHARHT~R~\make_factor{#7})}
+ \out_lline{(CHARDP~R~\make_factor{#8})}
+ \out_lline{(CHARIC~R~\make_factor{#9})}
+ \out_lline{)}
+}
+\def\transformfont#1#2{{
+ \let\setsomething_global=\x_relax
+ \unsetstr{afm-name}
+ \unsetstr{etx-name}
+ \x_resetint{x-scale}{\one_thousand}
+ \x_resetint{y-scale}{\one_thousand}
+ \x_resetint{slant-scale}{0}
+ #2
+ \ifisstr{afm-name}\then
+ \mtxtomtx{\str{afm-name}}{#1}
+ \mtxtopl{#1}{#1}
+ \else
+ \fontinsterror{Transformfont}{
+ Failed~to~make~transformed~font~#1;\messagebreak
+ source~font~metrics~file~not~found
+ }\error_help_a
+ \fi
+}}
+\def\fromafm#1{
+ \if_file_exists{#1.afm}\then
+ \x_setstr{afm-name}{#1}
+ \afmtomtx{#1}{#1}
+ \mtxtopl{#1}{#1}
+ \fi
+}
+\def\frommtx#1{
+ \if_file_exists{#1.mtx}\then \x_setstr{afm-name}{#1} \fi
+}
+\def\frompl#1{
+ \if_file_exists{#1.pl}\then
+ \x_setstr{afm-name}{#1}
+ \generalpltomtx{#1}{#1}{pl}{}
+ \fi
+}
+\def\fromplgivenetx#1#2{
+ \if_file_exists{#1.pl}\then
+ \x_setstr{afm-name}{#1}
+ \generalpltomtx{#1}{#1}{pl}{#2}
+ \fi
+}
+\def\fromany#1{
+ \x_cs\edef{s-afm-name}{#1}
+ \if_file_exists{#1.mtx}\then\else
+ \if_file_exists{#1.pl}\then
+ \generalpltomtx{#1}{#1}{pl}{}
+ \else
+ \if_file_exists{#1.afm}\then
+ \afmtomtx{#1}{#1}
+ \mtxtopl{#1}{#1}
+ \else
+ \if_file_exists{#1.vpl}\then
+ \generalpltomtx{#1}{#1}{vpl}{}
+ \else
+ \unsetstr{afm-name}
+ \fi\fi\fi\fi
+}
+\def\scalefont#1#2{
+ \eval_expr_to\d_count{#1}
+ \x_resetint{x-scale}{\scale{\d_count}{\int{x-scale}}}
+ \x_resetint{y-scale}{\scale{\d_count}{\int{y-scale}}}
+ \x_resetint{slant-scale}{\scale{\d_count}{\int{slant-scale}}}
+ #2
+}
+\def\xscalefont#1#2{
+ \x_resetint{x-scale}{\scale{#1}{\int{x-scale}}}
+ #2
+}
+\def\yscalefont#1#2{
+ \eval_expr_to\d_count{#1}
+ \x_resetint{y-scale}{\scale{\d_count}{\int{y-scale}}}
+ \x_resetint{slant-scale}{\scale{\d_count}{\int{slant-scale}}}
+ #2
+}
+\def\slantfont#1#2{
+ \x_resetint{slant-scale}{
+ \add{\scale{#1}{\int{x-scale}}}{\int{slant-scale}}
+ }
+ #2
+}
+\def\reencodefont#1#2{
+ #2
+ \resetstr{etx-name}{#1}
+}
+\def\mtxtomtx#1#2{{
+ \let\a_macro=\empty_command
+ \_a_true
+ \ifnum \int{x-scale}=\int{y-scale}
+ \ifnum \int{slant-scale}=\z@
+ \_a_false
+ \fi \fi
+ \if_a_
+ \a_count=\int{x-scale}
+ \l_inv_scale\a_count{\int{y-scale}}
+ \b_count=\int{slant-scale}
+ \l_inv_scale\b_count{\int{y-scale}}
+ \edef\a_macro{\a_macro
+ \string\transformfont{\the\a_count}{\the\b_count}
+ }
+ \fi
+ \open_out{\temp_prefix#2.mtx}
+ \edef\raw_font_name{#2}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\mtxtomtx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \ifisstr{etx-name}\then
+ \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}}
+ \def\declarepsencoding##1##2##3{
+ \a_toks={{##1}{##2}{##3}}
+ \out_line{\string\providepsencoding\the\a_toks}
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file
+ {\string\providepsencoding\the\a_toks}
+ \fi
+ }
+ \directfalse
+ \inputetx{\str{etx-name}}
+ \edef\a_macro{\a_macro\string\reencodefont{\str{etx-name}}}
+ \fi
+ \record_transform{#2}{\string\frommtx{#1}}{\a_macro}\iftrue
+ \out_line{}
+ \mtxtomtx_redefinitions
+ \inputmtx{#1}
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Transformed~metrics}
+}}
+\def\mtxtomtx_redefinitions{
+ \let\setint=\mtxtomtx_setint
+ \let\setdim=\mtxtomtx_setdim
+ \let\setstr=\mtxtomtx_setstr
+ \let\setscaledrawglyph=\mtxtomtx_setscaledrawglyph
+ \let\setscalednotglyph=\mtxtomtx_setscaledrawglyph
+ \let\setkern=\mtxtomtx_setkern
+ \let\setglyph=\mtxtomtx_setglyph
+ \let\glyphpcc=\mtxtomtx_glyphpcc
+ \let\samesize=\mtxtomtx_samesize
+ \let\endsetglyph=\mtxtomtx_endsetglyph
+ \def\aliased{\string\aliased}
+}
+\let\aliased=\second_of_two
+\def\mtxtomtx_setint#1#2{
+ \def\a_macro{#1}
+ \ifx \a_macro\italicslant_name
+ \eval_expr{#2}
+ \global\multiply \result \int{x-scale}
+ \a_count=\int{slant-scale}
+ \multiply \a_count \one_thousand
+ \advance \a_count \result
+ \divide \a_count \int{y-scale}\x_relax
+ \else
+ \def\do##1{
+ \def\b_macro{##1}
+ \ifx \a_macro\b_macro \expandafter\if_false \fi
+ }
+ \gobble_one\iftrue \width_ints_list \if_true
+ \eval_expr_to\a_count{\scale{#2}{\int{y-scale}}}
+ \else
+ \eval_expr_to\a_count{\scale{#2}{\int{x-scale}}}
+ \fi
+ \fi
+ \out_line{\string\setint{#1}{\the\a_count}}
+}
+\def\italicslant_name{italicslant}
+\def\width_ints_list{
+ \do{interword}\do{stretchword}\do{shrinkword}\do{quad}
+ \do{extraspace}\do{digitwidth}\do{verticalstem}
+}
+\def\mtxtomtx_setdim#1#2{
+ \out_line{\string\setdim{#1}{#2}}
+}
+\def\mtxtomtx_setstr#1#2{
+ \out_line{\string\setstr{#1}{#2}}
+}
+\def\mtxtomtx_setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \eval_expr_to\a_count{\scale{#6}{\int{x-scale}}}
+ \eval_expr_to\b_count{\scale{#7}{\int{y-scale}}}
+ \eval_expr_to\c_count{\scale{#8}{\int{y-scale}}}
+ \eval_expr_to\d_count{#9} \eval_expr{#7}
+ \multiply \d_count \int{x-scale}
+ \global\multiply \result \int{slant-scale}
+ \global\advance \result \d_count
+ \rounded_thousandths
+ \d_count=\result
+ \eval_expr{\scale{#4}{\int{y-scale}}}
+ \ifisstr{etx-name}\then
+ \bgroup
+ \let\aliased=\first_of_two
+ \if_undefined{slots-#1}\then
+ \egroup \e_count=\m@ne
+ \else
+ \expandafter\egroup \expandafter\e_count
+ \csname slots-#1\endcsname
+ \fi
+ \else
+ \e_count=#5
+ \fi
+ \out_line{
+ \ifnum \e_count>\m@ne
+ \string\setscaledrawglyph
+ \else
+ \string\setscalednotglyph
+ \fi
+ {#1}{\raw_font_name}{#3}{\the\result}{\the\e_count}
+ {\the\a_count}{\the\b_count}{\the\c_count}{\the\d_count}
+ }
+}
+\def\mtxtomtx_setkern#1#2#3{
+ \eval_expr{\scale{\int{x-scale}}{#3}}
+ \out_line{\string\setkern{#1}{#2}{\the\result}}
+}
+\def\mtxtomtx_setglyph#1{\out_line{\string\setglyph{#1}}}
+\def\mtxtomtx_samesize#1{\out_lline{\string\samesize{#1}}}
+\def\mtxtomtx_endsetglyph{\out_line{\string\endsetglyph}}
+\def\mtxtomtx_glyphpcc#1#2#3{
+ \eval_expr_to\b_count{\scale{\int{y-scale}}{#3}}
+ \eval_expr_to\a_count{#2} \eval_expr{#3}
+ \multiply \a_count \int{x-scale}
+ \global\multiply \result \int{slant-scale}
+ \global\advance \result \a_count
+ \rounded_thousandths
+ \out_lline{\string\glyphpcc{#1}{\the\result}{\the\b_count}}
+}
+\def\reglyphfonts{
+ \begingroup
+ \let\setsomething_global=\x_relax
+ \x_setint{renameweight}{1}
+ \x_setint{killweight}{-10}
+ \setcommand\iftokeep##1\then{\ifnum -1<##1}
+}
+\def\endreglyphfonts{\endgroup}
+\def\offmtxcommand#1{
+ \x_cs\offcommand{reglyph_\expandafter\gobble_one\string#1}
+}
+\def\onmtxcommand#1{
+ \x_cs\oncommand{reglyph_\expandafter\gobble_one\string#1}
+}
+\begingroup
+ \catcode`\-=11
+ \gdef\renameglyph#1#2{
+ \x_cs\edef{slots-#2}{
+ \noexpand\rename_glyph{#1}\noexpand\i-renameweight
+ }
+ }
+\endgroup
+\def\renameglyphweighted#1#2#3{
+ \eval_expr{#3}
+ \x_cs\edef{slots-#2}{\noexpand\rename_glyph{#1}{\the\result}}
+}
+\begingroup
+ \catcode`\-=11
+ \gdef\killglyph#1{
+ \x_cs\def{slots-#1}{\kill_glyph\i-killweight}
+ }
+\endgroup
+\def\killglyphweighted#1#2{
+ \eval_expr{#2}
+ \x_cs\edef{slots-#1}{\noexpand\kill_glyph{\the\result}}
+}
+\def\reglyphfont#1#2{
+ \fromany{#2}
+ \ifisstr{afm-name}\then
+ \reglyph_font{#1}{#2}
+ \else
+ \fontinsterror{Reglyph}{Could~not~find~font~metrics~for~#2.}
+ \error_help_a
+ \fi
+}
+\def\reglyph_font#1#2{{
+ \open_out{\temp_prefix#1.mtx}
+ \out_line{\percent_char~Filename:~#1.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\reglyphfont{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \record_transform{#1}{\string\frommtx{#2}}{\string\reglyphfont}
+ \iftrue
+ \out_line{}
+ \reglyph_redefinitions
+ \inputmtx{#2}
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Reglyphed~metrics}
+}}
+\def\reglyph_redefinitions{
+ \let\setint=\reglyph_setint
+ \let\setdim=\reglyph_setdim
+ \let\setstr=\reglyph_setstr
+ \let\setscaledrawglyph=\reglyph_setscaledrawglyph
+ \let\setscalednotglyph=\reglyph_setscaledrawglyph
+ \let\setkern=\reglyph_setkern
+ \let\setglyph=\reglyph_setglyph
+ \let\glyphpcc=\reglyph_glyphpcc
+ \let\samesize=\reglyph_samesize
+ \let\endsetglyph=\reglyph_endsetglyph
+}
+\def\reglyph_setint#1#2{\out_line{\string\setint{#1}{#2}}}
+\def\reglyph_setdim#1#2{\out_line{\string\setdim{#1}{#2}}}
+\def\reglyph_setstr#1#2{\out_line{\string\setstr{#1}{#2}}}
+\newcount\command_survivance
+\def\rename_glyph#1{\def\glyphname{#1}\kill_glyph}
+\def\kill_glyph#1{\advance \command_survivance #1\x_relax}
+\def\reglyph_setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{
+ \ifnum #5<\z@
+ \string\setscalednotglyph
+ \else
+ \string\setscaledrawglyph
+ \fi
+ {\glyphname}{#2}{#3}{\number#4}{#5}{#6}{#7}{#8}{#9}
+ }
+ \fi
+}
+\def\reglyph_setkern#1#2#3{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \let\a_macro=\glyphname
+ \def\glyphname{#2}
+ \csname slots-#2\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{\string\setkern{\a_macro}{\glyphname}{#3}}
+ \fi
+}
+\def\reglyph_setglyph#1{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_line{\string\setglyph{\glyphname}}}
+ \a_toks=\expandafter{\a_macro}
+}
+\x_cs\def{off-\string\reglyph_setglyph}#1{\gobble_glyph}
+\def\reglyph_glyphpcc#1#2#3{
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_lline{
+ \string\glyphpcc{\glyphname}{#2}{#3}
+ }}
+ \a_toks=\expandafter{\the\expandafter\a_toks \a_macro}
+}
+\def\reglyph_samesize#1{
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_lline{
+ \string\samesize{\glyphname}
+ }}
+ \a_toks=\expandafter{\the\expandafter\a_toks \a_macro}
+}
+\def\reglyph_endsetglyph{
+ \iftokeep\command_survivance\then
+ \the\a_toks
+ \out_line{\string\endsetglyph}
+ \fi
+ \a_toks={}
+}
+%%% From file: filtfam.dtx
+\def\latinfamily#1#2{{
+ \edef\a_macro{#1}
+ \expandafter\parse_family\a_macro
+ \empty_command\empty_command\end_parse_family
+ \installfonts
+ \if_file_exists{\raw_encoding.mtx}\then
+ \installfamily{\raw_encoding}{\latex_family}{#2}
+ \fi
+ \installfamily{OT1}{\latex_family}{#2}
+ \installfamily{T1}{\latex_family}{#2}
+ \installfamily{TS1}{\latex_family}{#2}
+ \latin_weights
+ \endinstallfonts
+}}
+\def\parse_family #1#2#3#4#5\end_parse_family{
+ \gdef\font_family{#1#2#3}
+ \gdef\font_variant{#4#5}
+ \gdef\raw_variant{#4#5}
+ \gdef\latex_family{#1#2#3#4#5}
+ \_expert_false
+ \_oldstyle_false
+ \ifx#4x
+ \_expert_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1}
+ \else\ifx#4j
+ \_expert_true
+ \_oldstyle_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1oldstyle}
+ \else\ifx#49
+ \gdef\latex_family{#1#2#3j#5}
+ \_expert_true
+ \_oldstyle_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1oldstyle}
+ \else
+ \_expert_false
+ \_oldstyle_false
+ %\setcommand\digit##1{##1}
+ \fi\fi\fi
+ \if_oldstyle_
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#5>~(oldstyle)}
+ \else\if_expert_
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#5>~(expert)}
+ \else
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#4#5>}
+ \fi\fi
+}
+\newif\if_expert_
+\newif\if_oldstyle_
+\def\latin_weight#1#2{
+ \gdef\font_weight{#1}%
+ \gdef\latex_weight{#2}%
+ \latin_widths
+}
+\def\latin_width#1#2{
+ \gdef\font_width{#1}
+ \gdef\latex_width{#2}
+ \latin_shapes
+}
+\def\latin_shape#1#2#3#4#5{
+ \gdef\font_shape{#1}
+ \gdef\raw_shape{#2}
+ \gdef\encoding_shape{#3}
+ \if_oldstyle_
+ \gdef\encoding_shape{#3\oldstyle_shape}
+ \fi
+ \gdef\latex_shape{#4}
+ \gdef\encoding_switches{#5}
+ \immediate\write16{
+ INFO>~to~make~LaTeX~font~shape~<\latex_family,
+ \latex_weight,\latex_shape,\latex_width>~seek~
+ \font_family\font_weight\raw_shape
+ \raw_variant\raw_encoding\font_width.mtx}
+ \csname fake_width_\font_width\endcsname
+ \csname fake_shape_\raw_shape\endcsname
+ \if_file_exists{
+ \font_family\font_weight\raw_shape
+ \raw_variant\raw_encoding\font_width.mtx
+ }\then
+ \latin_encodings
+ \fi
+}
+\def\fake_shape_{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_raw_encoding
+ \fi
+ \if_expert_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.afm
+ }\then
+ \fake_shape_expert_encoding
+ \fi
+ \fi
+}
+\def\fake_shape_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width>
+ }
+ \transformfont{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \reencodefont{\raw_encoding}{
+ \fromafm{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+}
+\def\fake_shape_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \fromafm{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width
+ }
+ \fi
+}
+\def\fake_shape_c{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_
+ \else
+ % If real smallcaps font doesn't exist, fake it from the roman.
+ \gdef\raw_shape{}
+ \if_oldstyle_
+ \gdef\encoding_shape{cj}
+ \else
+ \gdef\encoding_shape{c}
+ \fi
+ \fake_shape_
+ \fi
+}
+\def\fake_shape_o{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_
+ \else
+ \fake_shape_o_raw_encoding
+ \if_expert_
+ \fake_shape_o_expert_encoding
+ \fi
+ \fi
+}
+\def\fake_shape_o_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_variant
+ \raw_encoding\font_width>~(faking~oblique)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+ \fi
+}
+\def\fake_shape_o_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width>~from~
+ <\font_family\font_weight\raw_variant
+ \expert_encoding\font_width>~(faking~oblique)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ \space from~
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width
+ }
+ }
+ }
+ \fi
+ \fi
+}
+\let\fake_shape_i\fake_shape_ % We must do this again!
+\newif\if_fake_narrow_
+\_fake_narrow_false
+\def\fakenarrow#1{
+ \_fake_narrow_true
+ \gdef\fake_narrow_width{#1}
+}
+\def\fake_width_{}
+\def\fake_width_c{}
+\def\fake_width_n{
+ \if_fake_narrow_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then % no action required
+ \else
+ \fake_width_n_raw_encoding
+ \if_expert_
+ \fake_width_n_expert_encoding
+ \fi
+ \fi
+ \fi
+}
+\def\fake_width_n_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding>~(faking~narrow)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~narrow~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \xscalefont{\fake_narrow_width}{
+ \frommtx{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+ \fi
+}
+\def\fake_width_n_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width>~from~
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding>~(faking~narrow)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~narrow~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ \space from~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ }{
+ \xscalefont{\fake_narrow_width}{
+ \frommtx{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding
+ }
+ }
+ }
+ \fi
+ \fi
+}
+\def\latin_encoding#1#2#3#4#5{
+ \gdef\latex_encoding{#4}
+ \gdef\latex_mtx{#5}
+ \if_oldstyle_
+ \gdef\font_encoding{#3}
+ \else\if_expert_
+ \gdef\font_encoding{#2}
+ \else
+ \gdef\font_encoding{#1}
+ \fi\fi
+ \gdef\expert_font{}
+ \gdef\oldstyle_font{}
+ \if_expert_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then
+ \gdef\expert_font{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width,
+ }
+ \fi
+ \fi
+ \immediate\write16{
+ INFO>~run~\string\installfont\space
+ <\font_family\font_weight\font_shape\font_variant
+ \font_encoding\font_width>
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \if_oldstyle_
+ \ifx\raw_shape\caps_shape
+ resetosf,
+ \fi
+ \fi
+ \expert_font
+ \oldstyle_font
+ \latex_mtx>
+ <\latex_encoding\encoding_shape>
+ <\latex_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installfont{
+ \font_family\font_weight\font_shape\font_variant
+ \font_encoding\font_width
+ }{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \if_oldstyle_
+ \ifx\raw_shape\caps_shape
+ resetosf,
+ \fi
+ \fi
+ \expert_font
+ \oldstyle_font
+ \latex_mtx
+ }{
+ \latex_encoding\encoding_shape
+ }{
+ \latex_encoding
+ }{
+ \latex_family
+ }{
+ \latex_weight\latex_width
+ }{
+ \latex_shape
+ }{}
+}
+\def\latin_weights{
+ \latin_weight{r}{m}
+ \latin_weight{k}{m}
+ \latin_weight{b}{b}
+ \latin_weight{s}{sb}
+ \latin_weight{d}{db} % was {d}{sb}, SPQR changed
+ \latin_weight{m}{mb} % was {m}{m}, UV changed
+ \latin_weight{c}{eb} % UV added
+ \latin_weight{h}{eb} % UV added
+ \latin_weight{x}{eb}
+ \latin_weight{u}{ub}
+ \latin_weight{l}{l}
+ %\latin_weight{j}{el}
+ %\latin_weight{a}{ul} % UV added
+}
+\def\latin_widths{
+ \latin_width{}{}
+ \latin_width{n}{c}
+ %latin_width{c}{c}
+ %latin_width{x}{x}
+}
+\def\latin_shapes{
+ \latin_shape{} {} {} {n} {\_textcomp_true }
+ \latin_shape{c}{c}{} {sc}{\_textcomp_false}
+ \latin_shape{o}{o}{} {sl}{\_textcomp_true }
+ \latin_shape{i}{i}{i}{it}{\_textcomp_true }
+}
+\def\latin_encodings{
+ \latin_encoding{7t}{9t}{9o}{OT1}{newlatin}
+ \latin_encoding{8t}{9e}{9d}{T1} {newlatin}
+ \encoding_switches
+ \if_textcomp_
+ \latin_encoding{8c}{9c}{9c}{TS1}{textcomp}
+ \fi
+}
+\newif\if_textcomp_
+
+\def\raw_encoding{8r}
+\def\adobe_encoding{8a}
+\def\expert_encoding{8x}
+
+\def\caps_shape{c}
+\def\oldstyle_shape{j}
+\def\SlantAmount{167}
+%%% From file: fimapgen.dtx
+\def\mapfrags_subsystem{Map~fragments~writer}
+\def\recordtransforms#1{\open_pout\transform_record_file{#1}}
+\def\endrecordtransforms{
+ \close_pout\transform_record_file{Font~transformation~records}
+}
+\chardef\transform_record_file=\closed_stream
+\let\storemapdata=\gobble_three
+\def\record_transform#1#2#3#4{
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file{\string\storemapdata{#1}{#2}{#3}}
+ \fi
+ #4 \out_line{\string\storemapdata{#1}{#2}{#3}} \fi
+}
+\def\record_usage#1{
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file{\string\makemapentry{#1}}
+ \fi
+}
+\let\declarepsencoding=\gobble_three
+\let\providepsencoding=\gobble_three
+%%% From file: fibasics.dtx
+\def\needsfontinstversion#1{{
+ \a_dimen=#1pt
+ \b_dimen=\fontinstversion~pt\x_relax
+ \ifnum\a_dimen>\b_dimen
+ \immediate\write16{}
+ \immediate\write16{Warning:~This~file~needs~fontinst~version~#1.}
+ \immediate\write16{Warning:~You~are~using~version~
+ \fontinstversion.}
+ \immediate\write16{Warning:~This~may~cause~errors.}
+ \immediate\write16{}
+ \fi
+}}
+\if_file_exists{fontinst.rc}\then
+ \primitiveinput fontinst.rc
+\else
+ \immediate\write16{No~file~fontinst.rc.}
+\fi
+\normalcc
+\endinput
+%%
+%% End of file `cfntinst.sty'.
diff --git a/fonts/utilities/fontinst/inputs/base/finstmsc.sty b/fonts/utilities/fontinst/inputs/base/finstmsc.sty
new file mode 100644
index 0000000000..d2fd613cef
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/base/finstmsc.sty
@@ -0,0 +1,1470 @@
+%%
+%% This is file `finstmsc.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% fibasics.dtx (with options: `pkg')
+%% ficommon.dtx (with options: `pkg')
+%% fimain.dtx (with options: `misc')
+%% ficonv.dtx (with options: `misc')
+%% fimapgen.dtx (with options: `map')
+%% fibasics.dtx (with options: `pkg2,misc')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+%% maintenance team and any individual authors listed elsewhere in
+%% this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%%
+%%% From file: fibasics.dtx
+\catcode`\{=1
+\catcode`\}=2
+\catcode`\#=6
+\catcode`\^=7
+\def\fontinstversion{1.933}
+\ifx\ProvidesPackage\undefined
+ \def\NeedsTeXFormat#1{}
+ \def\ProvidesPackage#1[#2]{}
+\fi
+\ProvidesPackage{fontinst}
+[2007/01/23 v\fontinstversion\space
+ fontinst installation package]
+\def\a_macro#1{\catcode\number`#1=\the\catcode`#1 }
+\edef\normalcc{%
+ \a_macro{\ }\a_macro{\^^M}\a_macro{\@}\a_macro{\_}\a_macro{\~}
+}
+\def\fontinstcc{%
+ \catcode`\ =9%
+ \catcode`\^^M=9%
+ \catcode`\@=11%
+ \catcode`\_=11%
+ \catcode`\~=10
+}
+\fontinstcc
+\ifx\@ne\undefined_command
+ \input fontinst.ini\relax
+\fi
+\ifx\bye\undefined_command
+ \def\supereject{\par\penalty-\@MM}
+ \outer\expandafter\def \csname bye\endcsname
+ {\par\vfill\supereject\@@end}
+\fi
+\newcount\a_count
+\newcount\b_count
+\newcount\c_count
+\newcount\d_count
+\newcount\e_count
+\newcount\f_count
+\newcount\g_count
+\newdimen\a_dimen
+\newdimen\b_dimen
+\newdimen\c_dimen
+\newdimen\d_dimen
+\newtoks\a_toks
+\newtoks\b_toks
+\newtoks\c_toks
+\newif\if_a_
+\newwrite\out_file
+\mathchardef\one_thousand=1000
+\mathchardef\five_hundred=500
+\mathchardef\one_hundred=100
+\mathchardef\max_mathchardef="7FFF
+\mathchardef\two_thousand=2000
+\newdimen\half_point \half_point=0.5pt
+\def\x_cs#1#2{\expandafter#1\csname#2\endcsname}
+\let\x_relax=\relax
+\def\g_let{\global\let}
+\def\empty_command{}
+\def\gobble_one#1{}
+\def\gobble_two#1#2{}
+\def\gobble_three#1#2#3{}
+\def\identity_one#1{#1}
+\def\first_of_two#1#2{#1}
+\def\second_of_two#1#2{#2}
+\def\swap_two#1#2{#2#1}
+\def\first_of_three#1#2#3{#1}
+\bgroup
+ \catcode`\[=1
+ \catcode`\]=2
+ \catcode`\#=12
+ \catcode`\%=12
+ \catcode`\{=12
+ \catcode`\}=12
+ \gdef\hash_char[#]
+ \gdef\percent_char[%]
+ \gdef\left_brace_char[{]
+ \gdef\right_brace_char[}]
+\egroup
+\def\first_char#1#2={#1}
+\def\add_to#1#2{
+ \ifx#1\x_relax
+ \def#1{#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{#1#2}
+ \fi
+}
+\def\prep_to#1#2{
+ \ifx#1\x_relax
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2#1}
+ \fi
+}
+\def\never_do{\noexpand\do}
+\newif\if_extensions_warning_
+\_extensions_warning_false
+\ifx \eTeXversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\eTeX#1{
+ \if_extensions_warning_
+ \space/\space e-TeX\space version\space #1
+~ \else
+~ \ifdim \number\eTeXversion\eTeXrevision\p@ < #1\p@ \else
+~ \_a_true
+~ \fi
+ \fi
+}
+\catcode`\~=10
+\ifx \pdftexversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\pdfTeX#1#2{%
+ \if_extensions_warning_
+ \space/\space pdfTeX\space version\space
+ \ifnum #1<100\space
+ 0.\ifnum #1<10\space 0\fi
+ \else
+ \expandafter\swap_two \expandafter.
+ \fi
+ #1#2%
+~ \else
+~ \ifdim #1>\pdftexversion \else
+~ \ifnum \expandafter\expandafter \expandafter`
+~ \expandafter\first_char \pdftexrevision= <
+~ \expandafter` \first_char#2=
+~ \else \_a_true \fi
+~ \fi
+ \fi
+}
+\catcode`\~=10
+\def\needsTeXextension#1#2{
+ \_a_false
+ #1
+ \if_a_ \else
+ \_extensions_warning_true
+ \edef\a_macro{#1}
+ \_extensions_warning_false
+ \fontinstwarningnoline{#2}{
+ This~file~needs:\messagebreak
+ \expandafter\second_of_two\a_macro
+ \iffalse
+ <no~sufficient~extensions~were~listed!!>\if_false
+ \fi
+ \messagebreak
+ You~are~not~using~any~of~them.~This~is~likely~to~cause~errors
+ }
+ \fi
+}
+\def\open_out#1{
+ \immediate\openout\out_file=#1 \xdef\out_filename{#1}}
+\def\close_out#1{
+ \immediate\write16{#1~written~on~\out_filename.}
+ \immediate\closeout\out_file}
+\def\out_line#1{\immediate\write\out_file{#1}}
+\edef\out_lline#1{\noexpand\out_line{\space\space\space#1}}
+\edef\out_llline#1{
+ \noexpand\out_line{\space\space\space\space\space\space#1}
+}
+\def\TeX_terminal{\string\TeX\space terminal}
+\chardef\closed_stream=99
+\x_cs\let{out_filename-99}=\TeX_terminal
+\x_cs\def{out_filename--1}{\jobname.log}
+\def\allocate_stream{
+ \a_count=\m@ne
+ \b_count=\m@ne
+ \loop \ifnum \count17>\a_count
+ \advance \a_count \@ne
+ \x_cs\ifx{out_filename-\the\a_count}\TeX_terminal
+ \b_count=\a_count
+ \a_count=\count17
+ \fi
+ \repeat
+ \ifnum \b_count=\m@ne
+ \global\advance\count17by\@ne
+ \ifnum \count17<\sixt@@n
+ \b_count=\count17
+ \global\x_cs\let{out_filename-\the\b_count}\TeX_terminal
+ \wlog{\string\write\the\b_count\space allocated~to~the~pool.}
+ \else
+ \global\count17=\sixt@@n
+ \fi
+ \fi
+}
+\def\ch@ck#1#2#3{
+ \ifnum \count1#1<#2 \else
+ \errmessage{No~room~for~a~new~#3}
+ \global\count1#1=#2
+ \fi
+}
+\def\open_pout#1#2{
+ \allocate_stream
+ \ifnum \b_count=\m@ne
+ \immediate\write\sixt@@n{fontinst~is~out~of~output~streams.^^J
+ Output~file~#2~cannot~be~opened.^^J
+ Writes~will~be~redirected~to~the~log~file.
+ }
+ \gdef#1{\m@ne}
+ \else
+ \immediate\openout\b_count=#2\x_relax
+ \x_cs\xdef{out_filename-\the\b_count}{#2}
+ \global\chardef#1=\b_count
+ \fi
+}
+\def\close_pout#1#2{
+ \ifnum #1=\closed_stream
+ \errmessage{Output~file~\string#1~(#2)~not~closed,^^J
+ since~it~was~not~open}
+ \else
+ \immediate\write\sixt@@n{#2~written~on~
+ \csname out_filename-\the#1\endcsname.}
+ \ifnum #1=\m@ne \else
+ \immediate\closeout#1
+ \global\x_cs\let{out_filename-\the#1}=\TeX_terminal
+ \fi
+ \global\chardef#1=\closed_stream
+ \fi
+}
+\def\pout_line#1#2{\immediate\write#1{#2}}
+\edef\pout_lline#1#2{\noexpand\pout_line#1{\space\space\space#2}}
+\edef\pout_llline#1#2{
+ \noexpand\pout_line#1{\space\space\space\space\space\space#2}
+}
+\def\tempfileprefix#1{\def\temp_prefix{#1}}
+\tempfileprefix{}
+\let\then=\iffalse
+\def\if_false{\iffalse}
+\def\if_true{\iftrue}
+\_a_false\eTeX{2.0}
+\if_a_\else \catcode`\~=14\x_relax \fi
+~ \def\if_defined#1\then{
+~ \if
+~ \ifcsname#1\endcsname
+~ \expandafter\ifx \csname#1\endcsname \x_relax
+~ 0
+~ \else
+~ 1
+~ \fi
+~ \else
+~ 0
+~ \fi
+~ 1
+~ }
+~ \def\if_undefined{\expandafter\unless\if_defined}
+\catcode`\~=\if_a_ 14 \else 10 \fi \x_relax
+~ \def\if_defined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ \expandafter\if_false
+~ \else
+~ \expandafter\if_true
+~ \fi
+~ }
+~ \def\if_undefined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ }
+\catcode`\~=10\x_relax
+\def\gobble_if{\iftrue\else}
+\def\if_or#1\or_else#2\then{
+ #1\then
+ \expandafter\if_true
+ \else
+ #2\then
+ \expandafter\expandafter\expandafter\if_true
+ \else
+ \expandafter\expandafter\expandafter\if_false
+ \fi
+ \fi
+}
+\def\if_equal#1\then{\ifx#1}
+\def\if_file_exists#1\then{
+ \immediate\openin1=#1\x_relax
+ \ifeof1\x_relax
+ \immediate\closein1
+ \expandafter\if_false
+ \else
+ \immediate\closein1
+ \expandafter\if_true
+ \fi
+}
+\let\Else=\else
+\let\Fi=\fi
+\x_cs\ifx{@@input}\x_relax
+ \let\primitiveinput=\input
+\else
+ \let\primitiveinput=\@@input
+\fi
+\def\process_csep_list#1#2,{
+ \ifx\process_csep_list#2
+ \expandafter\gobble_one
+ \else
+ \expandafter\identity_one
+ \fi{
+ #1{#2}
+ \process_csep_list{#1}
+ }
+}
+\def\make_factor#1{
+ \ifnum #1<\z@
+ -\expandafter\make_factor_i\expandafter{\number-#1}
+ \else
+ \expandafter\make_factor_i\expandafter{\number#1}
+ \fi
+}
+\def\make_factor_i#1{
+ \ifnum #1<\one_thousand
+ \make_factor_ii{#1}
+ \else
+ \make_factor_iii #1
+ \fi
+ #1
+}
+\def\make_factor_ii#1{
+ 0.
+ \ifnum #1<\one_hundred
+ 0
+ \ifnum #1<10~ 0\fi
+ \fi
+}
+\def\make_factor_iii#1#2#3\fi#4{
+ \fi
+ #4
+ \ifnum 1#3<\one_thousand
+ .
+ \else
+ \make_factor_iii#2#3
+ \fi
+}
+{
+ \catcode`\p=12
+ \catcode`\t=12
+ \gdef\lose_measure#1pt{#1}
+}
+\def\format_hex_i#1#2{
+ \if #2i \else
+ \b_count=\a_count
+ \divide \a_count \sixt@@n
+ \c_count=\a_count
+ \multiply \c_count \sixt@@n
+ \advance \b_count -\c_count
+ \edef#1{
+ \ifcase\b_count 0\or 1\or 2\or 3\or 4\or 5\or 6\or 7\or 8\or
+ 9\or a\or b\or c\or d\or e\or f\fi
+ #1
+ }
+ \expandafter\format_hex_i \expandafter#1
+ \fi
+}
+\def\format_hex#1#2#3{
+ \a_count=#2
+ \let#1\empty_command
+ \expandafter\format_hex_i \expandafter#1 \romannumeral
+ \expandafter\identity_one\expandafter{\number#3}001~
+}
+\let\messagebreak\x_relax
+\def\generic_info#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\m@ne{#2\on_line.}
+ \endgroup
+}
+\def\generic_warning#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\closed_stream{^^J#2\on_line.^^J}
+ \endgroup
+}
+\def\generic_error#1#2#3#4{
+ \begingroup
+ \immediate\write\closed_stream{}
+ \def\messagebreak{^^J}
+ \edef\a_macro{{#4}}
+ \errhelp\a_macro
+ \def\messagebreak{^^J#1}
+ \errmessage{#2.^^J^^J#3
+ Type~\space H~<return>~\space for~immediate~help
+ }
+ \endgroup
+}
+\def\fontinsterror#1#2#3{
+ \generic_error{
+ \four_spaces\four_spaces
+ }{
+ #1~error:\messagebreak #2
+ }{
+ }{#3}
+}
+\def\fontinstwarning#1#2{
+ \generic_warning{
+ \four_spaces\four_spaces
+ }{
+ #1~warning:\messagebreak #2
+ }
+}
+\def\fontinstwarningnoline#1#2{
+ \fontinstwarning{#1}{#2\gobble_one}
+}
+\def\fontinstinfo#1#2{
+ \generic_info{
+ \four_spaces\four_spaces
+ }{
+ #1~info:\messagebreak #2
+ }
+}
+\def\on_line{~on~input~line~\the\inputlineno}
+\edef\four_spaces{\space\space\space\space}
+\gdef\error_help_a{
+ Your~command~was~ignored.\messagebreak
+ Type~\space I~<command>~<return>~\space to~replace~it~
+ with~another~command,\messagebreak
+ or~\space <return>~\space to~continue~without~it.}
+\gdef\error_help_c{
+ Try~typing~\space <return>~
+ \space to~proceed.\messagebreak
+ If~that~doesn't~work,~type~\space X~<return>~\space to~quit.}
+\gdef\error_help_d{
+ You're~in~trouble~here.~\space\error_help_c}
+\def\error_help_e#1{You~can~continue,~but~the~#1~wrong.}
+\newlinechar=`\^^J
+\errorcontextlines=999
+\tracinglostchars=1
+%%% From file: ficommon.dtx
+\def\str#1{\csname~s-#1\endcsname}
+\def\strint#1{\expandafter\identity_one\expandafter{\number\int{#1}}}
+\newcount\result
+\def\eval_expr#1{\global\result=#1\x_relax}
+\def\eval_expr_to#1#2{\eval_expr{#2}#1=\result}
+\def\g_eval_expr_to#1#2{\eval_expr{#2}\global#1=\result}
+\def\add#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\advance \result \a_count
+ \egroup
+}
+\def\sub#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \advance \a_count -\result
+ \global\result=\a_count
+ \egroup
+}
+\def\int#1{\csname i-#1 \endcsname}
+\def\neg#1{#1 \global\result=-\result}
+\def\mul#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \egroup
+}
+\def\div#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \divide \a_count \result
+ \global\result=\a_count
+ \egroup
+}
+\def\max#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count>\result \global\result=\a_count \fi
+ \egroup
+}
+\def\min#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count<\result \global\result=\a_count \fi
+ \egroup
+}
+\def\half#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\otherhalf#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \else \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\scale#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \rounded_thousandths
+ \egroup
+}
+\def\rounded_thousandths{
+ \global\divide \result \five_hundred
+ \ifodd \result
+ \global\advance \result by \ifnum 0>\result - \fi 1
+ \fi
+ \global\divide \result \tw@
+}
+\def\l_rounded_thousandths#1{
+ \divide #1 \five_hundred
+ \ifodd #1
+ \advance #1 by \ifnum 0>#1 - \fi\@ne
+ \fi
+ \divide #1 \tw@
+}
+\def\l_inv_scale#1#2{
+ \multiply #1 \two_thousand
+ \divide #1 #2\x_relax
+ \ifodd#1 \advance #1 \ifnum 0>#1 - \fi\@ne \fi
+ \divide #1 \tw@
+}
+\def\ifnumber#1#2#3\then{
+ \eval_expr_to\a_count{#1}
+ \eval_expr{#3}
+ \ifnum \a_count#2\result
+ \expandafter\if_true
+ \else
+ \expandafter\if_false
+ \fi
+}
+\let\setsomething_global=\x_relax
+\def\x_setint#1#2{
+ \x_cs\ifx{i-#1}\x_relax
+ \x_resetint{#1}{#2}
+ \fi
+}
+\let\setint=\x_setint
+\def\x_setstr#1#2{
+ \x_cs\ifx{s-#1}\x_relax
+ \setsomething_global\x_cs\edef{s-#1}{#2}
+ \fi
+}
+\let\setstr=\x_setstr
+\def\setdim#1#2{
+ \x_cs\ifx{d-#1}\x_relax
+ \a_dimen=#2\x_relax
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+ \fi
+}
+\def\setcommand#1{
+ \ifx#1\undefined_command
+ \setsomething_global \expandafter\def \expandafter#1
+ \else
+ \expandafter\def \expandafter\a_macro
+ \fi
+}
+\def\x_resetint#1#2{
+ \eval_expr{#2}
+ \setsomething_global
+ \ifnum\result<\max_mathchardef
+ \ifnum 0>\result
+ \x_cs\edef{i-#1}{\the\result}
+ \else
+ \x_cs\mathchardef{i-#1}=\result
+ \fi
+ \else
+ \x_cs\edef{i-#1}{\the\result}
+ \fi
+}
+\let\resetint=\x_resetint
+\def\resetstr#1#2{\setsomething_global\x_cs\edef{s-#1}{#2}}
+\def\resetdim#1#2{
+ \a_dimen=#2
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+}
+\def\resetcommand#1{\setsomething_global\def#1}
+\def\dim#1{\csname~d-#1\endcsname}
+\def\ifisint#1\then{\if_defined i-#1\then}
+\def\ifisstr#1\then{\if_defined s-#1\then}
+\def\ifisdim#1\then{\if_defined d-#1\then}
+\def\ifiscommand#1\then{
+ \ifx#1\undefined_command
+ \expandafter\if_false
+ \else
+ \expandafter\if_true
+ \fi
+}
+\def\unsetint#1{\setsomething_global\x_cs\let{i-#1}\x_relax}
+\def\unsetstr#1{\setsomething_global\x_cs\let{s-#1}\x_relax}
+\def\unsetdim#1{\setsomething_global\x_cs\let{d-#1}\x_relax}
+\def\unsetcommand#1{\setsomething_global\let#1=\undefined_command}
+\def\offcommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax
+ \setsomething_global\x_cs\let{saved-\string#1}#1
+ \x_cs\ifx{off-\string#1}\x_relax
+ \generate_off_command{#1}
+ \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname off-\string#1\endcsname
+ \fi
+ \fi
+}
+\def\oncommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname saved-\string#1\endcsname
+ \setsomething_global\x_cs\let{saved-\string#1}\x_relax
+ \fi
+}
+\def\generate_off_command#1{
+ \a_count=0
+ \let\next=\count_hashes
+ \expandafter\next\meaning#1~->\x_relax
+ \b_count=0
+ \a_toks={}
+ \loop \ifnum \b_count<\a_count
+ \advance \b_count 1
+ \a_toks=\expandafter{\the\expandafter\a_toks \expandafter####
+ \the\b_count}
+ \repeat
+ \setsomething_global \expandafter\def \expandafter#1 \the\a_toks {}
+}
+\def\count_hashes#1#2{
+ \if \hash_char#1
+ \advance \a_count 1
+ \else
+ \if -#1
+ \if >#2
+ \let\next=\gobble_to_xrelax
+ \fi\fi
+ \fi
+ \next#2
+}
+\def\gobble_to_xrelax#1\x_relax{}
+\def\for(#1)#2#3#4{
+ \eval_expr_to\a_count{#2}
+ \x_resetint{#1}{\a_count}
+ \eval_expr{#4}
+ \ifnum 0=\result \else
+ \c_count=\result
+ \eval_expr_to\b_count{#3}
+ \setsomething_global\x_cs\edef{for-#1}{
+ \the\c_count \x_relax
+ \noexpand\ifnum \gobble_one\fi
+ \the\b_count \ifnum 0>\c_count > \else < \fi
+ }
+ \def\next##1##2##3\endfor(#1){##2\for_i{##1}{##3}}
+ \next{#1}
+ \fi
+}
+\def\for_i#1#2{
+ \setsomething_global\x_cs\def{body-#1}{#2}
+ \ifnum \b_count \ifnum0>\c_count >\else<\fi \a_count
+ \expandafter\gobble_two
+ \else
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+\def\for_ii#1{
+ \a_count=\int{#1}
+ \advance \a_count \csname for-#1\endcsname \a_count
+ \expandafter\gobble_two
+ \else
+ \x_resetint{#1}\a_count
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+\def\endfor(#1){}
+\def\foreach(#1)#2{
+ \def\next##1\endfor(#1){
+ \setsomething_global\x_cs\def{body-#1}{##1}
+ \process_csep_list{\foreach_i{#1}}#2,\process_csep_list,
+ }
+ \next
+}
+\def\foreach_i#1#2{
+ \resetstr{#1}{#2}
+ \csname body-#1\endcsname
+}
+\let\comment=\gobble_one
+\let\begincomment=\iffalse
+\let\endcomment=\fi
+%%% From file: fimain.dtx
+\def\inputetx#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \slot_number=0
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\encoding=\fi
+ \primitiveinput \lowercase_file.etx\x_relax
+ \let\relax=\x_relax
+}
+\let\encoding=\relax
+\outer\def\endencoding{\endinput}
+\def\setslot#1{\edef\slot_name{#1}\do_slot}
+\def\endsetslot{\end_do_slot\advance\slot_number by 1\x_relax}
+\let\do_slot\empty_command
+\let\end_do_slot\empty_command
+\newcount\slot_number
+\def\nextslot#1{\eval_expr_to\slot_number{#1}}
+\def\skipslots#1{\eval_expr{#1} \advance\slot_number by \result}
+\let\setleftboundary=\gobble_one
+\let\endsetleftboundary=\x_relax
+\def\setrightboundary#1{
+ \makerightboundary{#1}
+ \advance \slot_number 1\x_relax
+}
+\let\ligature=\gobble_three
+\def\Ligature{\ligature}
+\def\oddligature#1#2#3#4{}
+\let\nextlarger=\gobble_one
+\let\usedas=\gobble_two
+\let\makerightboundary=\gobble_one
+\let\Unicode=\gobble_two
+\let\charseq=\gobble_one
+\let\varchar=\empty_command
+\let\vartop=\gobble_one
+\let\varmid=\gobble_one
+\let\varbot=\gobble_one
+\let\varrep=\gobble_one
+\let\endvarchar=\empty_command
+\let\useexamplefont=\gobble_one
+\let\slotexample=\empty_command
+\let\setslotcomment=\gobble_one
+\let\resetslotcomment=\gobble_one
+\let\unsetslotcomment=\empty_command
+\let\setfontdimen\gobble_two
+\let\label=\gobble_one
+\newif\ifdirect \directtrue
+\def\input_mtx_as_etx#1{
+ \def\setscaledrawglyph##1##2##3##4##5##6##7##8##9{
+ \nextslot{##5}
+ \setslot{##1}\endsetslot
+ }
+ \offcommand\setscalednotglyph
+ \let\setglyph=\gobble_glyph
+ \offcommand\setkern
+ \inputmtx{#1}
+}
+\def\inputmtx#1{
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\metrics=\fi
+ \primitiveinput #1.mtx\x_relax
+ \let\relax=\x_relax
+}
+\let\metrics=\x_relax
+\edef\endmetrics_text{\string\endmetrics}
+\outer\def\endmetrics{\endinput}
+\let\setkern=\gobble_three
+\long\def\setglyph#1\endsetglyph{}
+\def\setrawglyph#1#2#3#4#5#6#7#8{}
+\def\setscaledrawglyph#1#2#3#4#5#6#7#8#9{}
+\let\setnotglyph=\setrawglyph
+\let\setscalednotglyph=\setscaledrawglyph
+\def\ifisglyph#1\then{\iffalse}
+\let\ifareglyphs=\ifisglyph
+%%% From file: ficonv.dtx
+\newif\ifmissingslots
+\x_cs\def{o-.notdef}#1{\global\missingslotstrue}
+{
+ \catcode`\/=\active
+ \catcode`\]=\active
+ \gdef\enctoetx#1#2{{
+ \catcode`\/=\active
+ \catcode`\]=\active
+ \def/##1[{
+ \encname_to_etx ##1~{#1}{#2}
+ \a_count=0
+ \global\missingslotsfalse
+ \let/=\encslot_to_etx
+ }
+ \def]~def{}
+ \make_etx{#1}{#2}
+ }}
+}
+\def\encname_to_etx#1~#2#3{
+ \out_line{\percent_char\space REMOVE~THE~FOLLOWING~LINE~IF~
+ THIS~FILE~IS~MODIFIED~OR~RENAMED.}
+ \out_line{\string\declarepsencoding{#3}{#1}{\string\download{#2.enc}}}
+ \out_line{}
+}
+\def\encslot_to_etx#1~{
+ \csname o-#1\endcsname{
+ \ifmissingslots
+ \out_line{\string\nextslot{\the\a_count}}
+ \fi
+ \global\missingslotsfalse
+ \out_line{\string\setslot{#1}}
+ \out_line{\string\endsetslot}
+ \out_line{}
+ }
+ \advance\a_count by 1
+}
+\def\make_etx#1#2{
+ \open_out{\temp_prefix#2.etx}
+ \out_line{\percent_char~Filename:~#2.etx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\enctoetx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.enc~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{}
+ \out_line{\string\documentclass[twocolumn]{article}}
+ \out_line{\string\usepackage{fontdoc}[2005/05/13]}
+ \out_line{}
+ \out_line{\string\begin{document}}
+ \out_line{}
+ \out_line{This~document~describes~the~#1~encoding.}
+ \out_line{It~was~automatically~generated~by~the}
+ \out_line{\string\texttt{fontinst}~package.}
+ \out_line{}
+ \out_line{\string\encoding}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \primitiveinput #1.enc\x_relax
+ \out_line{}
+ \out_line{\string\end encoding}
+ \out_line{}
+ \out_line{\string\end{document}}
+ \close_out{Encoding}
+}
+\def\notdef_name{.notdef}
+\def\etxtoenc#1#2{\begingroup
+ \a_count=\z@
+ \loop
+ \x_cs\let{name-\the\a_count}=\notdef_name
+ \ifnum \@cclv>\a_count
+ \advance \a_count \@ne
+ \repeat
+ \def\do_slot{
+ \x_cs\ifx{name-\the\slot_number}\notdef_name
+ \x_cs\edef{name-\the\slot_number}{\slot_name}
+ \fi
+ }
+ \process_csep_list\inputetx #1,\process_csep_list,
+ \make_enc{#1}{#2}
+\endgroup}
+\def\make_enc#1#2{
+ \setstr{encodingname}{fontinst-autoenc-#1}
+ \def\a_macro##1{
+ \add_to\b_macro{##1.etx}
+ \def\a_macro####1{
+ \add_to\b_macro{,~####1.etx}
+ }
+ }
+ \let\b_macro\empty_command
+ \process_csep_list\a_macro #1,\process_csep_list,
+ \open_out{#2.enc}
+ \out_line{\percent_char !PS-Adobe-3.0~Resource-Encoding}
+ \out_line{\percent_char\space @psencodingfile\left_brace_char}
+ \ref_to_sourcefile{author}\b_macro
+ \ref_to_sourcefile{version}\b_macro
+ \out_line{\percent_char\four_spaces date~=~"generated~
+ \the\year/
+ \ifnum10>\month0\fi\the\month/
+ \ifnum10>\day0\fi\the\day",}
+ \out_line{\percent_char\four_spaces filename~=~"\out_filename",}
+ \ref_to_sourcefile{email}\b_macro
+ \ifisstr{address}\then
+ \out_line{\percent_char\four_spaces address~=~\str{address}}
+ \fi
+ \out_line{\percent_char\four_spaces codetable~=~"ISO/ASCII",}
+ \out_line{\percent_char\four_spaces checksum~=~"",}
+ \out_line{\percent_char\four_spaces abstract~=~"
+ This~is~a~postscript~encoding~file,~automatically~
+ generated~by~fontinst~from~\b_macro."}
+ \out_line{\percent_char\space\right_brace_char}
+ \out_line{}
+ \out_line{\percent_char\space Created~by:~tex~\jobname}
+ \out_line{\percent_char\space Created~using:~
+ \string\etxtoenc{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char\space This~file~should~be~installed~
+ somewhere~that~your~DVI}
+ \out_line{\percent_char\space to~postscript~driver~looks~for~files.~
+ It~is~needed~for}
+ \out_line{\percent_char\space reencoding~some~font~you~have~
+ transformed.}
+ \out_line{}
+ \out_line{\percent_char\space After~installing~this~file,~you~
+ should~add~the~following}
+ \out_line{\percent_char\space line~(minus~\percent_char)~
+ to~your~finstmsc.rc~file:}
+ \out_line{\percent_char\space\string\declarepsencoding
+ {#1}{\str{encodingname}}{\string\download{\out_filename}}}
+ \edef\a_macro{
+ \noexpand\declarepsencoding{#1}{\str{encodingname}}
+ {\noexpand\download{\out_filename}}
+ }
+ \a_macro
+ \out_line{}
+ \out_line{\percent_char\percent_char BeginResource:~
+ encoding~\str{encodingname}}
+ \out_line{/\str{encodingname}\space[}
+ \b_count=8
+ \a_count=\z@
+ \loop
+ \ifnum 8=\b_count
+ \b_count=\z@
+ \out_line{\percent_char\space\the\a_count}
+ \fi
+ \out_line{/\csname name-\the\a_count \endcsname}
+ \ifnum \@cclv>\a_count
+ \advance \a_count \@ne
+ \advance \b_count \@ne
+ \repeat
+ \out_line{]~def}
+ \out_line{\percent_char\percent_char EndResource}
+ \out_line{}
+ \out_line{\percent_char\space End~of~file~\out_filename.}
+ \close_out{Encoding~vector}
+}
+\def\ref_to_sourcefile#1#2{
+ \ifisstr{#1}\then
+ \out_line{\percent_char\four_spaces #1~=~\str{#1},}
+ \else
+ \out_line{\percent_char\four_spaces #1~=~"See~file~#2",}
+ \fi
+}
+\def\write_cmap_body#1{
+ \out_line{1~begincodespacerange~<00>~<FF>~endcodespacerange}
+ \let\do_slot=\_a_true
+ \def\Unicode##1##2{\cmap_charseq{\cmap_codepoint{##1}{##2}}}
+ \let\charseq=\cmap_charseq
+ \inputetx{#1}
+}
+\def\cmap_codepoint#1#2{
+ \uppercase{\a_count="#1\x_relax}
+ \ifnum "10000>\a_count
+ \format_hex\b_macro{\a_count}{4}
+ \edef\a_macro{\a_macro \b_macro \space}
+ \else
+ \advance \a_count -"10000
+ \d_count=\a_count
+ \divide \a_count "400
+ \b_count=\a_count
+ \multiply \b_count "400
+ \advance \d_count -\b_count
+ \advance \a_count "D800
+ \advance \d_count "DC00~
+ \format_hex\b_macro{\a_count}{4}
+ \format_hex\c_macro{\d_count}{4}
+ \edef\a_macro{\a_macro \b_macro \c_macro \space}
+ \fi
+}
+\def\cmap_charseq#1{%
+ \if_a_
+ \bgroup
+ \let\Unicode=\cmap_codepoint
+ \let\a_macro=\empty_command
+ #1
+ \format_hex\b_macro{\slot_number}{2}
+ \out_line{1~beginbfchar~<\b_macro>~<~\a_macro>~endbfchar}
+ \egroup
+ \_a_false
+ \fi
+}
+\def\etxtocmap#1#2{\begingroup
+ \inputetx{#1}
+ \open_out{#2.cmap}
+ \out_line{\percent_char !PS-Adobe-3.0~Resource-CMap}
+ \out_line{\percent_char\percent_char
+ DocumentNeededResources:~procset~CIDInit}
+ \out_line{\percent_char\percent_char
+ IncludeResource:~procset~CIDInit}
+ \setstr{cmapname}{fontinst-#2}
+ \out_line{\percent_char\percent_char
+ BeginResource:~CMap~\str{cmapname}}
+ \out_line{/CIDInit~/ProcSet~findresource~begin}
+ \out_line{7~dict~begin}
+ \out_line{begincmap}
+ \out_line{/CMapName~/\str{cmapname}~def}
+ \out_line{/CMapType~2~def}
+ \write_cmap_body{#1}
+ \out_line{endcmap}
+ \out_line{CMapName~currentdict~/CMap~defineresource~pop}
+ \out_line{end}
+ \out_line{end}
+ \out_line{\percent_char\percent_char EndResource}
+ \out_line{\percent_char\percent_char EOF}
+ \close_out{ToUnicode~CMap}
+\endgroup}
+\let\aliased=\second_of_two
+%%% From file: fimapgen.dtx
+\def\mapfrags_subsystem{Map~fragments~writer}
+\newcount\process_generation
+\process_generation=0
+\def\process_generation_succ{1}
+\def\extract_font_generation#1{
+ \if_defined{Tf-#1}\then
+ \expandafter\expandafter \expandafter\first_of_three
+ \csname Tf-#1\endcsname
+ \else
+ \m@ne
+ \fi
+}
+\def\storemapdata#1#2#3{
+ \expandafter\def \expandafter\a_macro
+ \expandafter{ \expandafter{ \the\process_generation}{#2}{#3}}
+ \ifnum \extract_font_generation{#1}<\process_generation \else
+ \x_cs\ifx{Tf-#1}\a_macro
+ \fontinstinfo\mapfrags_subsystem
+ {Repeated~definition~of~font~#1}
+ \else
+ \fontinstwarning\mapfrags_subsystem
+ {Inconsistent~redefinition~of~font~#1}
+ \fi
+ \fi
+ \x_cs\let{Tf-#1}=\a_macro
+}
+\let\transformfont\x_relax
+\let\reencodefont\x_relax
+\let\reglyphfont\x_relax
+\def\makemapentry#1{\begingroup
+ \def\TeX_font_name{#1}
+ \ifnum \extract_font_generation{#1}<\process_generation
+ \if_file_exists{#1.mtx}\then
+ \inputmtx{#1}
+ \fi\fi
+ \ifnum \extract_font_generation{#1}<\process_generation
+ \from_unknown{#1}
+ \x_cs\xdef{Tf-#1}{
+ {\process_generation_succ}{\noexpand\from_unknown{#1}}{}
+ }
+ \else
+ \expandafter\expandafter \expandafter\make_map_entry
+ \csname Tf-#1\endcsname
+ \fi
+ \endgroup
+}
+\def\make_map_entry#1#2#3{
+ \ifnum #1=\process_generation
+ \def\font_transforms{#3}
+ #2
+ \_a_false
+ \let\transformfont\concat_transformfont
+ \let\reencodefont\concat_reencodefont
+ \let\reglyphfont\_a_true
+ \font_transforms
+ \if_a_
+ \fontinsterror\mapfrags_subsystem{
+ \string\makemapentry\space for~reglyphed~font
+ }{ No~entry~for~font~\TeX_font_name\space
+ can~be~written,\messagebreak
+ since~it~had~been~reglyphed!~\error_help_a
+ }
+ \else
+ \entry_makers_list
+ \fi
+ \expandafter\gdef \csname Tf-\TeX_font_name \expandafter\endcsname
+ \expandafter{\expandafter{\process_generation_succ}{#2}{#3}}
+ \fi
+}
+\def\fromafm#1#2{
+ \def\source_font_TeX_name{#1}
+ \def\PS_font_name{#2}
+}
+\def\frompl#1{
+ \def\source_font_TeX_name{#1}
+}
+\def\frommtx#1{%
+ \ifnum \extract_font_generation{#1}<\process_generation
+ \if_file_exists{#1.mtx}\then
+ \inputmtx{#1}
+ \fi\fi
+ \ifnum \extract_font_generation{#1}<\process_generation
+ \from_unknown{#1}
+ \x_cs\xdef{Tf-#1}{
+ {\the\process_generation}{\noexpand\from_unknown{#1}}{}
+ }
+ \else
+ \expandafter\expandafter \expandafter\from_mtx
+ \csname Tf-#1\endcsname
+ \fi
+}
+\def\from_mtx#1#2#3{
+ \edef\font_transforms{#3\font_transforms}
+ #2
+}
+\def\fromvpl{
+ \ifx \empty_command\font_transforms \else
+ \fontinsterror\mapfrags_subsystem{
+ Font~is~virtual,~it~cannot~be~transformed}{
+ No~entry~for~font~\TeX_font_name\space can~be~written.
+ \messagebreak\error_help_a
+ }
+ \fi
+ \let\maker_do\gobble_one
+}
+\def\AssumeMetafont{
+ \def\frompl{
+ \ifx \empty_command\font_transforms \else
+ \fontinsterror\mapfrags_subsystem{
+ A~Metafont~cannot~be~transformed}{
+ No~entry~for~font~\TeX_font_name\space can~be~written.
+ \messagebreak\error_help_a
+ }
+ \fi
+ \let\maker_do\gobble_one
+ }
+}
+\def\from_unknown#1{
+ \fontinstwarningnoline\mapfrags_subsystem{
+ No~map~data~stored~for~font~#1.\messagebreak
+ No~entry~for~\TeX_font_name\space will~be~written,\messagebreak
+ due~to~insufficient~information}
+ \includewarning\warn_unknown_source
+ \let\maker_do\gobble_one
+}
+\let\font_transforms\empty_command
+\newdimen\xscale_factor \newdimen\slant_factor
+\xscale_factor=\p@ \slant_factor=\z@
+\let\reencode_etx\empty_command
+\def\concat_transformfont#1#2{
+ \edef\a_macro{\make_factor{#1}}
+ \xscale_factor=\a_macro\xscale_factor
+ \slant_factor=\a_macro\slant_factor
+ \advance \slant_factor \make_factor{#2}\p@
+}
+\def\concat_reencodefont#1{\def\reencode_etx{#1}}
+\def\adddriver#1#2{
+ \x_cs\ifx{make_#1}\x_relax
+ \fontinsterror\mapfrags_subsystem
+ {There~is~no~entry~maker~for~#1}\error_help_a
+ \else
+ \x_cs\ifx{output_#1}\x_relax \_a_true \else
+ \x_cs\ifx{output_#1}\closed_stream \_a_true \else
+ \_a_false
+ \fi\fi
+ \if_a_
+ \x_cs\open_pout{output_#1}{#2}
+ \expandafter\add_to \expandafter\entry_makers_list
+ \expandafter{ \expandafter\maker_do
+ \csname make_#1\endcsname}
+ \fi
+ \fi
+}
+\let\entry_makers_list\empty_command
+\let\maker_do\x_relax
+\def\donedrivers{
+ \def\maker_do##1{
+ \x_cs\close_pout{output\expandafter\gobble_five\string##1}
+ {Map~file~fragments}
+ }
+ \entry_makers_list
+ \let\maker_do\x_relax
+ \let\entry_makers_list\empty_command
+ \errorstopmode
+ \reportwarnings
+ \advance \process_generation \thr@@
+ \edef\process_generation_succ{\the\process_generation}
+ \advance \process_generation \m@ne
+}
+\def\gobble_five#1#2#3#4#5{}
+\g_let\warnings_list=\empty_command
+\def\warning_do#1#2#3{
+ \noexpand\warning_do \noexpand#2
+ \ifx #1#2
+ \expandafter#3 \expandafter\x_relax
+ \else
+ \expandafter#3 \expandafter#1
+ \fi
+}
+\def\includewarning#1{
+ \xdef\warnings_list{
+ \expandafter\swap_two \expandafter#1 \warnings_list
+ \if_equal\x_relax\then \else
+ \noexpand\warning_do \noexpand#1
+ \fi
+ }
+}
+\def\reportwarnings{
+ \begingroup
+ \let\warning_do=\x_relax
+ \warnings_list
+ \endgroup
+ \g_let\warnings_list=\empty_command
+}
+\def\warn_unknown_source{
+ \fontinstwarningnoline\mapfrags_subsystem{
+ Some~font~is~missing~from~the~output~file(s),\messagebreak
+ since~its~source~is~unknown}
+}
+\def\warn_undecided_data{
+ \fontinstwarningnoline\mapfrags_subsystem{
+ Check~the~output~file(s)--some~data~could~not~be~determined}
+}
+\def\warn_uncertain_data{
+ \fontinstwarningnoline\mapfrags_subsystem{
+ Check~the~output~file(s)--some~data~was~considered~uncertain}
+}
+\def\declarepsencoding#1#2#3{\x_cs\gdef{pse-#1}{{#2}{#3}}}
+\def\providepsencoding#1#2#3{
+ \if_undefined{pse-#1}\then
+ \declarepsencoding{#1}{#2}{#3}
+ \fi
+}
+\let\download=\gobble_one
+\def\fulldownload#1{\download{#1}}
+\def\encodingdownload#1{\download{#1}}
+\declarepsencoding{8r}{TeXBase1Encoding}{\encodingdownload{8r.enc}}
+\declarepsencoding{8a}{StandardEncoding}{}
+\def\specifypsfont#1#2{\x_cs\def{psf-#1}{#2}}
+\def\AssumeLWFN{\let\get_PS_font_file\LWFN_get_PS_font_file}
+\def\unknown_str{?????}
+\edef\clueless_str{\unknown_str ?}
+\let\TeX_font_name\unknown_str
+\let\source_font_TeX_name\unknown_str
+\let\PS_font_name\unknown_str
+\def\get_PS_font_name{\let\PS_font_name\clueless_str}
+\def\AssumeAMSBSYY{\def\get_PS_font_name{
+ \uppercase \expandafter{ \expandafter\def
+ \expandafter\PS_font_name \expandafter{ \source_font_TeX_name}
+ }
+}}
+\def\AssumeBaKoMa{\def\get_PS_font_name{
+ \lowercase \expandafter{ \expandafter\def
+ \expandafter\PS_font_name \expandafter{ \source_font_TeX_name}
+ }
+}}
+\let\PS_font_file\unknown_str
+\resetstr{PSfontsuffix}{.pfa}
+\def\normal_get_PS_font_file{
+ \edef\PS_font_file{\source_font_TeX_name\str{PSfontsuffix}}
+}
+\let\get_PS_font_file=\normal_get_PS_font_file
+\def\LWFN_get_PS_font_file{
+ \ifx \PS_font_name\unknown_str \get_PS_font_name \fi
+ \ifx \PS_font_name\clueless_str
+ \normal_get_PS_font_file
+ \includewarning\warn_uncertain_data
+ \else
+ \begingroup
+ \aftergroup\def \aftergroup\PS_font_file
+ \aftergroup{
+ \a_count=4~
+ \expandafter\expandafter \expandafter\aftergroup
+ \expandafter\swap_two \expandafter\abbreviate_PS_font_name
+ \PS_font_name \x_relax
+ \aftergroup}
+ \endgroup
+ \fi
+}
+\def\abbreviate_PS_font_name#1{
+ \ifx \x_relax#1 \else
+ \ifnum \uccode`#1=`#1
+ \a_count=2
+ \aftergroup#1
+ \else\ifx -#1
+ \a_count=\z@
+ \else\ifnum \a_count>\z@
+ \advance \a_count \m@ne
+ \aftergroup#1
+ \fi\fi\fi
+ \expandafter\abbreviate_PS_font_name
+ \fi
+}
+\def\make_debug{
+ \pout_line\output_debug{Driver~data~for~font~\TeX_font_name:}
+ \pout_lline\output_debug{Source~font~TeX~name:~\source_font_TeX_name}
+ \ifx \reencode_etx\empty_command \else
+ \pout_lline\output_debug{Font~reencoded~using~\reencode_etx.etx.}
+ \fi
+ \ifdim \xscale_factor=\p@ \else
+ \pout_lline\output_debug{Font~x-scaled~by~
+ \expandafter\lose_measure\the\xscale_factor.
+ }
+ \fi
+ \ifdim \slant_factor=\z@ \else
+ \pout_lline\output_debug{Font~slanted~by~
+ \expandafter\lose_measure\the\slant_factor.
+ }
+ \fi
+ \debug_values_hook
+}
+\def\debug_value#1{
+ \ifx #1\unknown_str
+ \csname get_ \expandafter\gobble_one \string#1 \endcsname
+ \fi
+ \pout_lline\output_debug{\string#1:~#1}
+ \ifx #1\clueless_str \includewarning\warn_undecided_data \fi
+}
+\def\debugvalue#1{
+ \expandafter\add_to \expandafter\debug_values_hook
+ \expandafter{ \expandafter\debug_value \csname#1\endcsname}
+}
+\let\debug_values_hook\empty_command
+\debugvalue{PS_font_name}
+\newtoks\downloads_list
+\def\append_download#1#2{
+ \edef\a_macro{
+ \downloads_list =
+ \noexpand\expandafter{ \noexpand\the \downloads_list
+ \noexpand#1 {#2} }
+ }
+ \a_macro
+}
+\def\make_dvips{
+ \downloads_list={}
+ \let\postscript_code\empty_command
+ \def\download{\append_download\download}
+ \def\fulldownload{\append_download\fulldownload}
+ \def\encodingdownload{\append_download\encodingdownload}
+ \ifx \reencode_etx\empty_command \else
+ \if_undefined{pse-\reencode_etx}\then
+ \etxtoenc{\reencode_etx}{\reencode_etx}
+ \fi
+ \expandafter\expandafter \expandafter\second_of_two
+ \csname pse-\reencode_etx\endcsname
+ \edef\postscript_code{\postscript_code\space
+ \expandafter\expandafter \expandafter\first_of_two
+ \csname pse-\reencode_etx\endcsname
+ \space ReEncodeFont
+ }
+ \fi
+ \ifdim \xscale_factor=\p@ \else
+ \edef\postscript_code{\postscript_code
+ \space\expandafter\lose_measure\the\xscale_factor
+ \space ExtendFont
+ }
+ \fi
+ \ifdim \slant_factor=\z@ \else
+ \edef\postscript_code{\postscript_code
+ \space\expandafter\lose_measure\the\slant_factor
+ \space SlantFont
+ }
+ \fi
+ \ifx \PS_font_name\unknown_str \get_PS_font_name \fi
+ \ifx \PS_font_name\clueless_str
+ \includewarning\warn_undecided_data
+ \_a_true
+ \else
+ \if_undefined{psf-\PS_font_name}\then
+ \_a_true
+ \else
+ \csname psf-\PS_font_name \endcsname
+ \_a_false
+ \fi\fi
+ \if_a_
+ \ifx \PS_font_file\unknown_str \get_PS_font_file \fi
+ \append_download\download{\PS_font_file}
+ \ifx \PS_font_file\clueless_str
+ \includewarning\warn_undecided_data
+ \fi
+ \fi
+ \def\download##1{~<##1}
+ \def\fulldownload##1{~<<##1}
+ \def\encodingdownload##1{~<[##1}
+ \pout_line\output_dvips{
+ \TeX_font_name\space\PS_font_name
+ \expandafter\empty_command \the\downloads_list
+ \ifx \postscript_code\empty_command \else
+ \space"\postscript_code\space"
+ \fi
+ }
+}
+\def\make_dvipdfm{
+ \def\font_encoding{default}
+ \ifx \reencode_etx\empty_command \else
+ \if_undefined{pse-\reencode_etx}\then
+ \etxtoenc{\reencode_etx}{\reencode_etx}
+ \fi
+ \def\download##1{\def\font_encoding{##1}}
+ \expandafter\expandafter \expandafter\second_of_two
+ \csname pse-\reencode_etx\endcsname
+ \fi
+ \let\options_text\empty_command
+ \ifdim \xscale_factor=\p@ \else
+ \edef\options_text{\options_text\space
+ -e~\expandafter\lose_measure\the\xscale_factor
+ }
+ \fi
+ \ifdim \slant_factor=\z@ \else
+ \edef\options_text{\options_text\space
+ -s~\expandafter\lose_measure\the\slant_factor
+ }
+ \fi
+ \ifx \PS_font_name\unknown_str \get_PS_font_name \fi
+ \if_or \if_equal\PS_font_name\clueless_str \or_else
+ \if_undefined{psf-\PS_font_name}
+ \then
+ \ifx \PS_font_file\unknown_str \get_PS_font_file \fi
+ \ifx \PS_font_file\clueless_str
+ \includewarning\warn_undecided_data
+ \fi
+ \let\a_macro=\PS_font_file
+ \else
+ \let\a_macro=\PS_font_name
+ \def\download##1{\def\a_macro{##1}}
+ \csname psf-\PS_font_name \endcsname
+ \fi
+ \pout_line\output_dvipdfm{
+ \TeX_font_name\space\font_encoding\space\a_macro
+ \options_text
+ }
+}
+\def\make_pltotf{
+ \pout_line\output_pltotf{pltotf~\TeX_font_name.pl~
+ \ifisstr{TFMfileprefix}\then \str{TFMfileprefix}\fi
+ \TeX_font_name.tfm
+ }
+}
+%%% From file: fibasics.dtx
+\def\needsfontinstversion#1{{
+ \a_dimen=#1pt
+ \b_dimen=\fontinstversion~pt\x_relax
+ \ifnum\a_dimen>\b_dimen
+ \immediate\write16{}
+ \immediate\write16{Warning:~This~file~needs~fontinst~version~#1.}
+ \immediate\write16{Warning:~You~are~using~version~
+ \fontinstversion.}
+ \immediate\write16{Warning:~This~may~cause~errors.}
+ \immediate\write16{}
+ \fi
+}}
+\if_file_exists{finstmsc.rc}\then
+ \primitiveinput finstmsc.rc
+\else
+ \immediate\write16{No~file~finstmsc.rc.}
+\fi
+\normalcc
+\endinput
+%%
+%% End of file `finstmsc.sty'.
diff --git a/fonts/utilities/fontinst/inputs/base/fontinst.ini b/fonts/utilities/fontinst/inputs/base/fontinst.ini
new file mode 100644
index 0000000000..3769e47f6f
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/base/fontinst.ini
@@ -0,0 +1,97 @@
+%%
+%% This is file `fontinst.ini',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% fibasics.dtx (with options: `ini')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+%% maintenance team and any individual authors listed elsewhere in
+%% this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%%
+%%% From file: fibasics.dtx
+\chardef\active=13
+
+\chardef\@ne=1
+\chardef\tw@=2
+\chardef\thr@@=3
+\chardef\sixt@@n=16
+\chardef\@cclv=255
+\mathchardef\@cclvi=256
+\mathchardef\@m=1000
+\mathchardef\@M=10000
+\mathchardef\@MM=20000
+
+\count10=22 % allocates \count registers 23, 24, ...
+\count11=9 % allocates \dimen registers 10, 11, ...
+\count15=9 % allocates \toks registers 10, 11, ...
+\count16=-1 % allocates input streams 0, 1, ...
+\count17=-1 % allocates output streams 0, 1, ...
+\count20=255 % allocates insertions 254, 253, ...
+\countdef\insc@unt=20 % the insertion counter
+\countdef\allocationnumber=21 % the most recent allocation
+\countdef\m@ne=22 \m@ne=-1 % a handy constant
+\def\wlog{\immediate\write\m@ne} % write on log file (only)
+
+\countdef\count@=255
+\dimendef\dimen@=0
+
+\outer\def\newcount{\alloc@0\count\countdef\insc@unt}
+\outer\def\newdimen{\alloc@1\dimen\dimendef\insc@unt}
+\outer\def\newtoks{\alloc@5\toks\toksdef\@cclvi}
+\outer\def\newread{\alloc@6\read\chardef\sixt@@n}
+\outer\def\newwrite{\alloc@7\write\chardef\sixt@@n}
+
+\def\alloc@#1#2#3#4#5{\global\advance\count1#1by\@ne
+ \ch@ck#1#4#2% make sure there's still room
+ \allocationnumber=\count1#1%
+ \global#3#5=\allocationnumber
+ \wlog{\string#5=\string#2\the\allocationnumber}}
+\outer\def\newinsert#1{\global\advance\insc@unt by\m@ne
+ \ch@ck0\insc@unt\count
+ \ch@ck1\insc@unt\dimen
+ \ch@ck2\insc@unt\skip
+ \ch@ck4\insc@unt\box
+ \allocationnumber=\insc@unt
+ \global\chardef#1=\allocationnumber
+ \wlog{\string#1=\string\insert\the\allocationnumber}}
+\def\ch@ck#1#2#3{\ifnum\count1#1<#2%
+ \else\errmessage{No~room~for~a~new~#3}\fi}
+
+\outer\def\newif#1{\count@\escapechar \escapechar\m@ne
+ \expandafter\expandafter\expandafter
+ \edef\@if#1{true}{\let\noexpand#1=\noexpand\iftrue}%
+ \expandafter\expandafter\expandafter
+ \edef\@if#1{false}{\let\noexpand#1=\noexpand\iffalse}%
+ \@if#1{false}\escapechar\count@} % the condition starts out false
+\def\@if#1#2{\csname\expandafter\if@\string#1#2\endcsname}
+{\uccode`1=`i \uccode`2=`f \uppercase{\gdef\if@12{}}} % `if' is required
+
+\newdimen\p@ \p@=1pt % this saves macro space and time
+\newdimen\z@ \z@=0pt % can be used both for 0pt and 0
+
+\def\space{~}
+\let\bgroup={
+\let\egroup=}
+
+\def\loop#1\repeat{\def\body{#1}\iterate}
+\def\iterate{\body \let\next\iterate \else\let\next\relax\fi \next}
+\let\repeat=\fi % this makes \loop...\if...\repeat skippable
+
+\def\supereject{\par\penalty-\@MM}
+\outer\def\bye{\par\vfill\supereject\end}
+\endinput
+%%
+%% End of file `fontinst.ini'.
diff --git a/fonts/utilities/fontinst/inputs/base/fontinst.sty b/fonts/utilities/fontinst/inputs/base/fontinst.sty
new file mode 100644
index 0000000000..c19adcf838
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/base/fontinst.sty
@@ -0,0 +1,3676 @@
+%%
+%% This is file `fontinst.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% fibasics.dtx (with options: `pkg')
+%% ficommon.dtx (with options: `pkg')
+%% fimain.dtx (with options: `pkg')
+%% fitrig.dtx (with options: `pkg')
+%% ficonv.dtx (with options: `pkg')
+%% filtfam.dtx (with options: `pkg,textcomp,debug')
+%% fimapgen.dtx (with options: `pkg')
+%% fibasics.dtx (with options: `pkg2')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+%% maintenance team and any individual authors listed elsewhere in
+%% this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%%
+%%% From file: fibasics.dtx
+\catcode`\{=1
+\catcode`\}=2
+\catcode`\#=6
+\catcode`\^=7
+\def\fontinstversion{1.933}
+\ifx\ProvidesPackage\undefined
+ \def\NeedsTeXFormat#1{}
+ \def\ProvidesPackage#1[#2]{}
+\fi
+\ProvidesPackage{fontinst}
+[2007/01/23 v\fontinstversion\space
+ fontinst installation package]
+\def\a_macro#1{\catcode\number`#1=\the\catcode`#1 }
+\edef\normalcc{%
+ \a_macro{\ }\a_macro{\^^M}\a_macro{\@}\a_macro{\_}\a_macro{\~}
+}
+\def\fontinstcc{%
+ \catcode`\ =9%
+ \catcode`\^^M=9%
+ \catcode`\@=11%
+ \catcode`\_=11%
+ \catcode`\~=10
+}
+\fontinstcc
+\ifx\@ne\undefined_command
+ \input fontinst.ini\relax
+\fi
+\ifx\bye\undefined_command
+ \def\supereject{\par\penalty-\@MM}
+ \outer\expandafter\def \csname bye\endcsname
+ {\par\vfill\supereject\@@end}
+\fi
+\newcount\a_count
+\newcount\b_count
+\newcount\c_count
+\newcount\d_count
+\newcount\e_count
+\newcount\f_count
+\newcount\g_count
+\newdimen\a_dimen
+\newdimen\b_dimen
+\newdimen\c_dimen
+\newdimen\d_dimen
+\newtoks\a_toks
+\newtoks\b_toks
+\newtoks\c_toks
+\newif\if_a_
+\newwrite\out_file
+\mathchardef\one_thousand=1000
+\mathchardef\five_hundred=500
+\mathchardef\one_hundred=100
+\mathchardef\max_mathchardef="7FFF
+\mathchardef\two_thousand=2000
+\newdimen\half_point \half_point=0.5pt
+\def\x_cs#1#2{\expandafter#1\csname#2\endcsname}
+\let\x_relax=\relax
+\def\g_let{\global\let}
+\def\empty_command{}
+\def\gobble_one#1{}
+\def\gobble_two#1#2{}
+\def\gobble_three#1#2#3{}
+\def\identity_one#1{#1}
+\def\first_of_two#1#2{#1}
+\def\second_of_two#1#2{#2}
+\def\swap_two#1#2{#2#1}
+\def\first_of_three#1#2#3{#1}
+\bgroup
+ \catcode`\[=1
+ \catcode`\]=2
+ \catcode`\#=12
+ \catcode`\%=12
+ \catcode`\{=12
+ \catcode`\}=12
+ \gdef\hash_char[#]
+ \gdef\percent_char[%]
+ \gdef\left_brace_char[{]
+ \gdef\right_brace_char[}]
+\egroup
+\def\first_char#1#2={#1}
+\def\add_to#1#2{
+ \ifx#1\x_relax
+ \def#1{#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{#1#2}
+ \fi
+}
+\def\prep_to#1#2{
+ \ifx#1\x_relax
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2#1}
+ \fi
+}
+\def\never_do{\noexpand\do}
+\newif\if_extensions_warning_
+\_extensions_warning_false
+\ifx \eTeXversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\eTeX#1{
+ \if_extensions_warning_
+ \space/\space e-TeX\space version\space #1
+~ \else
+~ \ifdim \number\eTeXversion\eTeXrevision\p@ < #1\p@ \else
+~ \_a_true
+~ \fi
+ \fi
+}
+\catcode`\~=10
+\ifx \pdftexversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\pdfTeX#1#2{%
+ \if_extensions_warning_
+ \space/\space pdfTeX\space version\space
+ \ifnum #1<100\space
+ 0.\ifnum #1<10\space 0\fi
+ \else
+ \expandafter\swap_two \expandafter.
+ \fi
+ #1#2%
+~ \else
+~ \ifdim #1>\pdftexversion \else
+~ \ifnum \expandafter\expandafter \expandafter`
+~ \expandafter\first_char \pdftexrevision= <
+~ \expandafter` \first_char#2=
+~ \else \_a_true \fi
+~ \fi
+ \fi
+}
+\catcode`\~=10
+\def\needsTeXextension#1#2{
+ \_a_false
+ #1
+ \if_a_ \else
+ \_extensions_warning_true
+ \edef\a_macro{#1}
+ \_extensions_warning_false
+ \fontinstwarningnoline{#2}{
+ This~file~needs:\messagebreak
+ \expandafter\second_of_two\a_macro
+ \iffalse
+ <no~sufficient~extensions~were~listed!!>\if_false
+ \fi
+ \messagebreak
+ You~are~not~using~any~of~them.~This~is~likely~to~cause~errors
+ }
+ \fi
+}
+\def\open_out#1{
+ \immediate\openout\out_file=#1 \xdef\out_filename{#1}}
+\def\close_out#1{
+ \immediate\write16{#1~written~on~\out_filename.}
+ \immediate\closeout\out_file}
+\def\out_line#1{\immediate\write\out_file{#1}}
+\edef\out_lline#1{\noexpand\out_line{\space\space\space#1}}
+\edef\out_llline#1{
+ \noexpand\out_line{\space\space\space\space\space\space#1}
+}
+\def\TeX_terminal{\string\TeX\space terminal}
+\chardef\closed_stream=99
+\x_cs\let{out_filename-99}=\TeX_terminal
+\x_cs\def{out_filename--1}{\jobname.log}
+\def\allocate_stream{
+ \a_count=\m@ne
+ \b_count=\m@ne
+ \loop \ifnum \count17>\a_count
+ \advance \a_count \@ne
+ \x_cs\ifx{out_filename-\the\a_count}\TeX_terminal
+ \b_count=\a_count
+ \a_count=\count17
+ \fi
+ \repeat
+ \ifnum \b_count=\m@ne
+ \global\advance\count17by\@ne
+ \ifnum \count17<\sixt@@n
+ \b_count=\count17
+ \global\x_cs\let{out_filename-\the\b_count}\TeX_terminal
+ \wlog{\string\write\the\b_count\space allocated~to~the~pool.}
+ \else
+ \global\count17=\sixt@@n
+ \fi
+ \fi
+}
+\def\ch@ck#1#2#3{
+ \ifnum \count1#1<#2 \else
+ \errmessage{No~room~for~a~new~#3}
+ \global\count1#1=#2
+ \fi
+}
+\def\open_pout#1#2{
+ \allocate_stream
+ \ifnum \b_count=\m@ne
+ \immediate\write\sixt@@n{fontinst~is~out~of~output~streams.^^J
+ Output~file~#2~cannot~be~opened.^^J
+ Writes~will~be~redirected~to~the~log~file.
+ }
+ \gdef#1{\m@ne}
+ \else
+ \immediate\openout\b_count=#2\x_relax
+ \x_cs\xdef{out_filename-\the\b_count}{#2}
+ \global\chardef#1=\b_count
+ \fi
+}
+\def\close_pout#1#2{
+ \ifnum #1=\closed_stream
+ \errmessage{Output~file~\string#1~(#2)~not~closed,^^J
+ since~it~was~not~open}
+ \else
+ \immediate\write\sixt@@n{#2~written~on~
+ \csname out_filename-\the#1\endcsname.}
+ \ifnum #1=\m@ne \else
+ \immediate\closeout#1
+ \global\x_cs\let{out_filename-\the#1}=\TeX_terminal
+ \fi
+ \global\chardef#1=\closed_stream
+ \fi
+}
+\def\pout_line#1#2{\immediate\write#1{#2}}
+\edef\pout_lline#1#2{\noexpand\pout_line#1{\space\space\space#2}}
+\edef\pout_llline#1#2{
+ \noexpand\pout_line#1{\space\space\space\space\space\space#2}
+}
+\def\tempfileprefix#1{\def\temp_prefix{#1}}
+\tempfileprefix{}
+\let\then=\iffalse
+\def\if_false{\iffalse}
+\def\if_true{\iftrue}
+\_a_false\eTeX{2.0}
+\if_a_\else \catcode`\~=14\x_relax \fi
+~ \def\if_defined#1\then{
+~ \if
+~ \ifcsname#1\endcsname
+~ \expandafter\ifx \csname#1\endcsname \x_relax
+~ 0
+~ \else
+~ 1
+~ \fi
+~ \else
+~ 0
+~ \fi
+~ 1
+~ }
+~ \def\if_undefined{\expandafter\unless\if_defined}
+\catcode`\~=\if_a_ 14 \else 10 \fi \x_relax
+~ \def\if_defined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ \expandafter\if_false
+~ \else
+~ \expandafter\if_true
+~ \fi
+~ }
+~ \def\if_undefined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ }
+\catcode`\~=10\x_relax
+\def\gobble_if{\iftrue\else}
+\def\if_or#1\or_else#2\then{
+ #1\then
+ \expandafter\if_true
+ \else
+ #2\then
+ \expandafter\expandafter\expandafter\if_true
+ \else
+ \expandafter\expandafter\expandafter\if_false
+ \fi
+ \fi
+}
+\def\if_equal#1\then{\ifx#1}
+\def\if_file_exists#1\then{
+ \immediate\openin1=#1\x_relax
+ \ifeof1\x_relax
+ \immediate\closein1
+ \expandafter\if_false
+ \else
+ \immediate\closein1
+ \expandafter\if_true
+ \fi
+}
+\let\Else=\else
+\let\Fi=\fi
+\x_cs\ifx{@@input}\x_relax
+ \let\primitiveinput=\input
+\else
+ \let\primitiveinput=\@@input
+\fi
+\def\process_csep_list#1#2,{
+ \ifx\process_csep_list#2
+ \expandafter\gobble_one
+ \else
+ \expandafter\identity_one
+ \fi{
+ #1{#2}
+ \process_csep_list{#1}
+ }
+}
+\def\make_factor#1{
+ \ifnum #1<\z@
+ -\expandafter\make_factor_i\expandafter{\number-#1}
+ \else
+ \expandafter\make_factor_i\expandafter{\number#1}
+ \fi
+}
+\def\make_factor_i#1{
+ \ifnum #1<\one_thousand
+ \make_factor_ii{#1}
+ \else
+ \make_factor_iii #1
+ \fi
+ #1
+}
+\def\make_factor_ii#1{
+ 0.
+ \ifnum #1<\one_hundred
+ 0
+ \ifnum #1<10~ 0\fi
+ \fi
+}
+\def\make_factor_iii#1#2#3\fi#4{
+ \fi
+ #4
+ \ifnum 1#3<\one_thousand
+ .
+ \else
+ \make_factor_iii#2#3
+ \fi
+}
+{
+ \catcode`\p=12
+ \catcode`\t=12
+ \gdef\lose_measure#1pt{#1}
+}
+\def\format_hex_i#1#2{
+ \if #2i \else
+ \b_count=\a_count
+ \divide \a_count \sixt@@n
+ \c_count=\a_count
+ \multiply \c_count \sixt@@n
+ \advance \b_count -\c_count
+ \edef#1{
+ \ifcase\b_count 0\or 1\or 2\or 3\or 4\or 5\or 6\or 7\or 8\or
+ 9\or a\or b\or c\or d\or e\or f\fi
+ #1
+ }
+ \expandafter\format_hex_i \expandafter#1
+ \fi
+}
+\def\format_hex#1#2#3{
+ \a_count=#2
+ \let#1\empty_command
+ \expandafter\format_hex_i \expandafter#1 \romannumeral
+ \expandafter\identity_one\expandafter{\number#3}001~
+}
+\let\messagebreak\x_relax
+\def\generic_info#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\m@ne{#2\on_line.}
+ \endgroup
+}
+\def\generic_warning#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\closed_stream{^^J#2\on_line.^^J}
+ \endgroup
+}
+\def\generic_error#1#2#3#4{
+ \begingroup
+ \immediate\write\closed_stream{}
+ \def\messagebreak{^^J}
+ \edef\a_macro{{#4}}
+ \errhelp\a_macro
+ \def\messagebreak{^^J#1}
+ \errmessage{#2.^^J^^J#3
+ Type~\space H~<return>~\space for~immediate~help
+ }
+ \endgroup
+}
+\def\fontinsterror#1#2#3{
+ \generic_error{
+ \four_spaces\four_spaces
+ }{
+ #1~error:\messagebreak #2
+ }{
+ }{#3}
+}
+\def\fontinstwarning#1#2{
+ \generic_warning{
+ \four_spaces\four_spaces
+ }{
+ #1~warning:\messagebreak #2
+ }
+}
+\def\fontinstwarningnoline#1#2{
+ \fontinstwarning{#1}{#2\gobble_one}
+}
+\def\fontinstinfo#1#2{
+ \generic_info{
+ \four_spaces\four_spaces
+ }{
+ #1~info:\messagebreak #2
+ }
+}
+\def\on_line{~on~input~line~\the\inputlineno}
+\edef\four_spaces{\space\space\space\space}
+\gdef\error_help_a{
+ Your~command~was~ignored.\messagebreak
+ Type~\space I~<command>~<return>~\space to~replace~it~
+ with~another~command,\messagebreak
+ or~\space <return>~\space to~continue~without~it.}
+\gdef\error_help_c{
+ Try~typing~\space <return>~
+ \space to~proceed.\messagebreak
+ If~that~doesn't~work,~type~\space X~<return>~\space to~quit.}
+\gdef\error_help_d{
+ You're~in~trouble~here.~\space\error_help_c}
+\def\error_help_e#1{You~can~continue,~but~the~#1~wrong.}
+\newlinechar=`\^^J
+\errorcontextlines=999
+\tracinglostchars=1
+%%% From file: ficommon.dtx
+\def\str#1{\csname~s-#1\endcsname}
+\def\strint#1{\expandafter\identity_one\expandafter{\number\int{#1}}}
+\newcount\result
+\def\eval_expr#1{\global\result=#1\x_relax}
+\def\eval_expr_to#1#2{\eval_expr{#2}#1=\result}
+\def\g_eval_expr_to#1#2{\eval_expr{#2}\global#1=\result}
+\def\add#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\advance \result \a_count
+ \egroup
+}
+\def\sub#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \advance \a_count -\result
+ \global\result=\a_count
+ \egroup
+}
+\def\int#1{\csname i-#1 \endcsname}
+\def\neg#1{#1 \global\result=-\result}
+\def\mul#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \egroup
+}
+\def\div#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \divide \a_count \result
+ \global\result=\a_count
+ \egroup
+}
+\def\max#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count>\result \global\result=\a_count \fi
+ \egroup
+}
+\def\min#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count<\result \global\result=\a_count \fi
+ \egroup
+}
+\def\half#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\otherhalf#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \else \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\scale#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \rounded_thousandths
+ \egroup
+}
+\def\rounded_thousandths{
+ \global\divide \result \five_hundred
+ \ifodd \result
+ \global\advance \result by \ifnum 0>\result - \fi 1
+ \fi
+ \global\divide \result \tw@
+}
+\def\l_rounded_thousandths#1{
+ \divide #1 \five_hundred
+ \ifodd #1
+ \advance #1 by \ifnum 0>#1 - \fi\@ne
+ \fi
+ \divide #1 \tw@
+}
+\def\l_inv_scale#1#2{
+ \multiply #1 \two_thousand
+ \divide #1 #2\x_relax
+ \ifodd#1 \advance #1 \ifnum 0>#1 - \fi\@ne \fi
+ \divide #1 \tw@
+}
+\def\ifnumber#1#2#3\then{
+ \eval_expr_to\a_count{#1}
+ \eval_expr{#3}
+ \ifnum \a_count#2\result
+ \expandafter\if_true
+ \else
+ \expandafter\if_false
+ \fi
+}
+\let\setsomething_global=\x_relax
+\def\x_setint#1#2{
+ \x_cs\ifx{i-#1}\x_relax
+ \x_resetint{#1}{#2}
+ \fi
+}
+\let\setint=\x_setint
+\def\x_setstr#1#2{
+ \x_cs\ifx{s-#1}\x_relax
+ \setsomething_global\x_cs\edef{s-#1}{#2}
+ \fi
+}
+\let\setstr=\x_setstr
+\def\setdim#1#2{
+ \x_cs\ifx{d-#1}\x_relax
+ \a_dimen=#2\x_relax
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+ \fi
+}
+\def\setcommand#1{
+ \ifx#1\undefined_command
+ \setsomething_global \expandafter\def \expandafter#1
+ \else
+ \expandafter\def \expandafter\a_macro
+ \fi
+}
+\def\x_resetint#1#2{
+ \eval_expr{#2}
+ \setsomething_global
+ \ifnum\result<\max_mathchardef
+ \ifnum 0>\result
+ \x_cs\edef{i-#1}{\the\result}
+ \else
+ \x_cs\mathchardef{i-#1}=\result
+ \fi
+ \else
+ \x_cs\edef{i-#1}{\the\result}
+ \fi
+}
+\let\resetint=\x_resetint
+\def\resetstr#1#2{\setsomething_global\x_cs\edef{s-#1}{#2}}
+\def\resetdim#1#2{
+ \a_dimen=#2
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+}
+\def\resetcommand#1{\setsomething_global\def#1}
+\def\dim#1{\csname~d-#1\endcsname}
+\def\ifisint#1\then{\if_defined i-#1\then}
+\def\ifisstr#1\then{\if_defined s-#1\then}
+\def\ifisdim#1\then{\if_defined d-#1\then}
+\def\ifiscommand#1\then{
+ \ifx#1\undefined_command
+ \expandafter\if_false
+ \else
+ \expandafter\if_true
+ \fi
+}
+\def\unsetint#1{\setsomething_global\x_cs\let{i-#1}\x_relax}
+\def\unsetstr#1{\setsomething_global\x_cs\let{s-#1}\x_relax}
+\def\unsetdim#1{\setsomething_global\x_cs\let{d-#1}\x_relax}
+\def\unsetcommand#1{\setsomething_global\let#1=\undefined_command}
+\def\offcommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax
+ \setsomething_global\x_cs\let{saved-\string#1}#1
+ \x_cs\ifx{off-\string#1}\x_relax
+ \generate_off_command{#1}
+ \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname off-\string#1\endcsname
+ \fi
+ \fi
+}
+\def\oncommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname saved-\string#1\endcsname
+ \setsomething_global\x_cs\let{saved-\string#1}\x_relax
+ \fi
+}
+\def\generate_off_command#1{
+ \a_count=0
+ \let\next=\count_hashes
+ \expandafter\next\meaning#1~->\x_relax
+ \b_count=0
+ \a_toks={}
+ \loop \ifnum \b_count<\a_count
+ \advance \b_count 1
+ \a_toks=\expandafter{\the\expandafter\a_toks \expandafter####
+ \the\b_count}
+ \repeat
+ \setsomething_global \expandafter\def \expandafter#1 \the\a_toks {}
+}
+\def\count_hashes#1#2{
+ \if \hash_char#1
+ \advance \a_count 1
+ \else
+ \if -#1
+ \if >#2
+ \let\next=\gobble_to_xrelax
+ \fi\fi
+ \fi
+ \next#2
+}
+\def\gobble_to_xrelax#1\x_relax{}
+\def\for(#1)#2#3#4{
+ \eval_expr_to\a_count{#2}
+ \x_resetint{#1}{\a_count}
+ \eval_expr{#4}
+ \ifnum 0=\result \else
+ \c_count=\result
+ \eval_expr_to\b_count{#3}
+ \setsomething_global\x_cs\edef{for-#1}{
+ \the\c_count \x_relax
+ \noexpand\ifnum \gobble_one\fi
+ \the\b_count \ifnum 0>\c_count > \else < \fi
+ }
+ \def\next##1##2##3\endfor(#1){##2\for_i{##1}{##3}}
+ \next{#1}
+ \fi
+}
+\def\for_i#1#2{
+ \setsomething_global\x_cs\def{body-#1}{#2}
+ \ifnum \b_count \ifnum0>\c_count >\else<\fi \a_count
+ \expandafter\gobble_two
+ \else
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+\def\for_ii#1{
+ \a_count=\int{#1}
+ \advance \a_count \csname for-#1\endcsname \a_count
+ \expandafter\gobble_two
+ \else
+ \x_resetint{#1}\a_count
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+\def\endfor(#1){}
+\def\foreach(#1)#2{
+ \def\next##1\endfor(#1){
+ \setsomething_global\x_cs\def{body-#1}{##1}
+ \process_csep_list{\foreach_i{#1}}#2,\process_csep_list,
+ }
+ \next
+}
+\def\foreach_i#1#2{
+ \resetstr{#1}{#2}
+ \csname body-#1\endcsname
+}
+\let\comment=\gobble_one
+\let\begincomment=\iffalse
+\let\endcomment=\fi
+%%% From file: fimain.dtx
+\def\inputetx#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \slot_number=0
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\encoding=\fi
+ \primitiveinput \lowercase_file.etx\x_relax
+ \let\relax=\x_relax
+}
+\let\encoding=\relax
+\outer\def\endencoding{\endinput}
+\def\setslot#1{\edef\slot_name{#1}\do_slot}
+\def\endsetslot{\end_do_slot\advance\slot_number by 1\x_relax}
+\let\do_slot\empty_command
+\let\end_do_slot\empty_command
+\newcount\slot_number
+\def\nextslot#1{\eval_expr_to\slot_number{#1}}
+\def\skipslots#1{\eval_expr{#1} \advance\slot_number by \result}
+\def\setleftboundary#1{\edef\slot_name{#1}\do_boundary}
+\let\endsetleftboundary\x_relax
+\let\do_boundary\x_relax
+\def\setrightboundary#1{
+ \makerightboundary{#1}
+ \advance \slot_number 1\x_relax
+}
+\let\ligature=\gobble_three
+\def\Ligature{\ligature}
+\def\oddligature#1#2#3#4{}
+\let\nextlarger=\gobble_one
+\let\usedas=\gobble_two
+\let\makerightboundary=\gobble_one
+\let\Unicode=\gobble_two
+\let\charseq=\gobble_one
+\let\varchar=\empty_command
+\let\vartop=\gobble_one
+\let\varmid=\gobble_one
+\let\varbot=\gobble_one
+\let\varrep=\gobble_one
+\let\endvarchar=\empty_command
+\let\useexamplefont=\gobble_one
+\let\slotexample=\empty_command
+\let\setslotcomment=\gobble_one
+\let\resetslotcomment=\gobble_one
+\let\unsetslotcomment=\empty_command
+\def\setfontdimen#1#2{
+ \ifisint{#2}\then \setint{fontdimen(#1)}{\int{#2}} \fi
+}
+\let\label=\gobble_one
+\newif\ifdirect \directtrue
+\def\input_mtx_as_etx#1{
+ \def\setscaledrawglyph##1##2##3##4##5##6##7##8##9{
+ \nextslot{##5}
+ \setslot{##1}\endsetslot
+ }
+ \offcommand\setscalednotglyph
+ \let\setglyph=\gobble_glyph
+ \offcommand\setkern
+ \inputmtx{#1}
+}
+\def\inputmtx#1{
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\metrics=\fi
+ \primitiveinput #1.mtx\x_relax
+ \let\relax=\x_relax
+}
+\let\metrics=\x_relax
+\edef\endmetrics_text{\string\endmetrics}
+\outer\def\endmetrics{\endinput}
+\def\ProvidesMtxPackage#1{\x_cs\let{pack-#1}P}
+\def\usemtxpackage{\futurelet\next_token\test_UseMtxPkg_arguments}
+\def\test_UseMtxPkg_arguments{\ifx\next_token[
+ \expandafter\mtx_package_given_file
+ \else
+ \expandafter\mtx_package_separate_files
+ \fi
+}
+\def\mtx_package_given_file[#1]#2{
+ \_a_false
+ \process_csep_list\load_true_unless_loaded #2,\process_csep_list,
+ \if_a_ \inputmtx{#1} \fi
+}
+\def\load_true_unless_loaded#1{
+ \x_cs\ifx{pack-#1}P\else\_a_true\fi
+}
+\def\mtx_package_separate_files#1{
+ \process_csep_list\load_file_unless_loaded #1,\process_csep_list,
+}
+\def\load_file_unless_loaded#1{
+ \x_cs\ifx{pack-#1}P\else \inputmtx{#1} \fi
+}
+\let\glyph_name_modifier=\identity_one
+\def\setkern#1#2#3{
+ \x_cs\ifx{i-rawscale}\x_relax
+ \expandafter\set_kern
+ \csname~r-\glyph_name_modifier{#1}\expandafter\endcsname
+ \csname~l-\glyph_name_modifier{#2}\endcsname
+ {#3}
+ \else
+ \expandafter\set_kern
+ \csname~r-\glyph_name_modifier{#1}\expandafter\endcsname
+ \csname~l-\glyph_name_modifier{#2}\endcsname
+ {\scale{#3}{\int{rawscale}}}
+ \fi
+}
+\def\set_kern#1#2#3{
+ \eval_expr{#3}
+ \expandafter\set_kern_cs\csname\the\result\endcsname#1#2
+}
+\def\set_kern_cs#1#2#3{
+ \add_to#2{\k#3#1}
+ \add_to#3{\k#2#1}
+}
+\def\resetkern#1#2#3{
+ \x_cs\ifx{i-rawscale}\x_relax
+ \expandafter\reset_kern
+ \csname~r-#1\expandafter\endcsname
+ \csname~l-#2\endcsname{#3}
+ \else
+ \expandafter\reset_kern
+ \csname~r-#1\expandafter\endcsname
+ \csname~l-#2\endcsname{\scale{#3}{\int{rawscale}}}
+ \fi
+}
+\def\reset_kern#1#2#3{
+ \eval_expr{#3}
+ \expandafter\reset_kern_cs\csname\the\result\endcsname#1#2
+}
+\def\reset_kern_cs#1#2#3{
+ \prep_to#2{\k\expandafter#3\expandafter#1}
+ \prep_to#3{\k\expandafter#2\expandafter#1}
+}
+\def\setleftkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~l-#1\expandafter\endcsname
+ \csname~l-#2\endcsname
+}
+\def\setrightkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~r-#1\expandafter\endcsname
+ \csname~r-#2\endcsname
+}
+\def\setleftrightkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~l-#1\expandafter\endcsname
+ \csname~l-#2\endcsname
+ \expandafter\set_kerning
+ \csname~r-#1\expandafter\endcsname
+ \csname~r-#2\endcsname
+}
+\def\set_kerning#1#2{
+ \if\b_count=\one_thousand
+ \def\k##1##2{
+ \set_kern_cs##2##1#1
+ }
+ \else
+ \def\k##1##2{
+ \set_kern##1#1{
+ \scale\b_count{\expandafter\gobble_one\string##2}
+ }
+ }
+ \fi
+ #2
+}
+\def\kerning#1#2{0\x_relax
+ \def\k##1{\csname~set-\string##1\endcsname\gobble_one}
+ \bgroup
+ \x_cs\def{set-\string\l-#2}##1##2{
+ \global\result=\expandafter\gobble_one\string##2\egroup
+ }
+ \csname~r-#1\endcsname
+ \csname~set-\string\l-#2\endcsname\gobble_one{00}
+}
+\def\ifiskern#1#2\then{
+ \def\k##1##2{\ifx T##1 \let\k\gobble_two \fi}
+ \bgroup
+ \x_cs\let{l-#2}T
+ \csname r-#1\endcsname
+ \expandafter\egroup \ifx\k\gobble_two
+}
+\def\unsetkerns#1#2{
+ \let\k\k_unless_to_U
+ \process_csep_list\make_slots_U#1,\process_csep_list,
+ \def\do##1{\x_cs\main_remove_Us{l-##1}}
+ \process_csep_list\do#2,\process_csep_list,
+ \process_csep_list\make_slots_relax#1,\process_csep_list,
+ \process_csep_list\make_slots_U#2,\process_csep_list,
+ \def\do##1{\x_cs\main_remove_Us{r-##1}}
+ \process_csep_list\do#1,\process_csep_list,
+ \process_csep_list\make_slots_relax#2,\process_csep_list,
+}
+\def\make_slots_U#1{\x_cs\let{slots-#1}U}
+\def\make_slots_relax#1{\x_cs\let{slots-#1}\x_relax}
+\def\k_unless_to_U#1#2{
+ \x_cs\ifx{slots-\expandafter\gobble_three\string#1}U \else
+ \noexpand\k\noexpand#1\noexpand#2
+ \fi
+}
+\def\main_remove_Us#1{
+ \ifx#1\x_relax \else
+ \edef#1{#1}
+ \ifx#1\empty_command \let#1\x_relax \fi
+ \fi
+}
+\def\noleftkerning#1{\no_kerning{l}{#1}}
+\def\norightkerning#1{\no_kerning{r}{#1}}
+\def\noleftrightkerning#1{\no_kerning{l}{#1}\no_kerning{r}{#1}}
+\def\no_kerning#1#2{
+ \let\k\no_kerning_i
+ \def\do##1{\csname #1-##1\endcsname}
+ \bgroup
+ \aftergroup\def \aftergroup\a_macro \aftergroup{
+ \process_csep_list\do #2,\process_csep_list,
+ \aftergroup}
+ \egroup
+ \def\do##1{\expandafter\let \csname #1-##1\endcsname \x_relax}
+ \process_csep_list\do #2,\process_csep_list,
+ \let\k\no_kerning_ii
+ \def\do##1{\edef##1{##1}}
+ \a_macro
+}
+\def\no_kerning_i#1#2{
+ \ifx #1\x_relax \else
+ \aftergroup\do \aftergroup#1
+ \let #1\x_relax
+ \fi
+}
+\def\no_kerning_ii#1#2{
+ \ifx #1\x_relax \else \noexpand\k \noexpand#1 \noexpand#2 \fi
+}
+\def\width{\glyph_parameter\first_of_six}
+\def\height{\glyph_parameter\second_of_six}
+\def\depth{\glyph_parameter\third_of_six}
+\def\italic{\glyph_parameter\fourth_of_six}
+\def\mapcommands{\glyph_parameter\fifth_of_six}
+\def\mapfonts{\glyph_parameter\sixth_of_six}
+\def\glyph_parameter#1#2{
+ \expandafter\expandafter\expandafter
+ #1\csname g-#2\endcsname
+}
+\def\first_of_six#1#2#3#4#5#6{#1}
+\def\second_of_six#1#2#3#4#5#6{#2}
+\def\third_of_six#1#2#3#4#5#6{#3}
+\def\fourth_of_six#1#2#3#4#5#6{#4}
+\def\fifth_of_six#1#2#3#4#5#6{#5}
+\def\sixth_of_six#1#2#3#4#5#6{#6}
+\def\glyph_metrics#1#2#3#4#5#6{
+ \a_count=#1
+ \b_count=#2
+ \c_count=#3
+ \d_count=#4~
+}
+\let\saved_scale\x_relax
+\let\saved_mapfont\x_relax
+\let\saved_raw\x_relax
+\let\saved_rule\x_relax
+\let\saved_special\x_relax
+\let\saved_warning\x_relax
+\let\saved_movert\x_relax
+\let\saved_moveup\x_relax
+\let\saved_push\x_relax
+\let\saved_pop\x_relax
+\newcount\glyph_width
+\newcount\glyph_height
+\newcount\glyph_depth
+\newcount\glyph_italic
+\newtoks\glyph_map_commands
+\newtoks\glyph_map_fonts
+\newcount\glyph_voffset
+\newcount\glyph_maxhpos
+\def\setglyph#1{
+ \ifisglyph{\glyph_name_modifier{#1}}\then
+ \expandafter\gobble_glyph
+ \else
+ \x_cs\def{g-\glyph_name_modifier{#1}}{
+ {\the\glyph_width}{\the\glyph_height}
+ {\the\glyph_depth}{\the\glyph_italic}
+ {\the\glyph_map_commands}{\the\glyph_map_fonts}
+ }
+ \resetglyph{\glyph_name_modifier{#1}}
+ \fi
+}
+\long\def\gobble_glyph#1\endsetglyph{}
+\def\resetglyph#1{
+ \edef\glyphname{#1}
+ \glyph_width=0
+ \global\glyph_height=0
+ \global\glyph_depth=0
+ \global\glyph_italic=0
+ \glyph_voffset=0
+ \global\glyph_maxhpos=0
+ \global\glyph_map_commands={}
+ \global\glyph_map_fonts={}
+}
+\def\endsetglyph{
+ \x_cs\edef{g-\glyphname}
+ {{\the\glyph_width}{\the\glyph_height}
+ {\the\glyph_depth}{\the\glyph_italic}
+ {\the\glyph_map_commands}{\the\glyph_map_fonts}}
+}
+\let\endresetglyph=\endsetglyph
+\def\setrawglyph#1#2#3{
+ \setscaledrawglyph{#1}{#2}{#3}\one_thousand
+}
+\def\setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \if_undefined{g-\glyph_name_modifier{#1}}\then
+ \eval_expr{#4}
+ \ifnum \result=\one_thousand
+ \let\a_macro\identity_one
+ \else
+ \edef\a_macro##1{\saved_scale{\the\result}{##1}}
+ \fi
+ \eval_expr_to\a_count{#6}
+ \eval_expr_to\b_count{#7}
+ \eval_expr_to\c_count{#8}
+ \eval_expr_to\d_count{#9}
+ \ifisint{rawscale}\then
+ \e_count=\int{rawscale}
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \edef\a_macro##1{\saved_scale{\the\e_count}{\a_macro{##1}}}
+ \fi
+ \x_cs\edef{g-\glyph_name_modifier{#1}}{
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {\a_macro{\saved_raw{#2}{#5}{#1}}}
+ {\a_macro{\saved_mapfont{#2}{#3}}}
+ }
+ \fi
+}
+\def\setnotglyph#1#2#3{
+ \setscalednotglyph{#1}{#2}{#3}\one_thousand
+}
+\def\setscalednotglyph#1#2#3#4#5#6#7#8#9{
+ \if_undefined{g-\glyph_name_modifier{#1}-not}\then
+ \eval_expr_to\a_count{#6}
+ \eval_expr_to\b_count{#7}
+ \eval_expr_to\c_count{#8}
+ \eval_expr_to\d_count{#9}
+ \ifisint{rawscale}\then
+ \e_count=\int{rawscale}
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \fi
+ \x_cs\edef{g-\glyph_name_modifier{#1}-not}{
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {}{}
+ }
+ \fi
+}
+\def\unsetglyph#1{\x_cs\let{g-#1}\x_relax}
+\def\glyph#1#2{
+ \glyph_parameter\glyph_metrics{#1}
+ \eval_expr_to\e_count{#2}
+ \ifnum \e_count=\one_thousand
+ \edef\a_macro{\mapcommands{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \edef\a_macro{\mapfonts{#1}}
+ \else
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \edef\a_macro{\saved_scale{\the\e_count}{\mapcommands{#1}}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \edef\a_macro{\saved_scale{\the\e_count}{\mapfonts{#1}}}
+ \fi
+ \advance \glyph_width \a_count
+ \advance \b_count \glyph_voffset
+ \ifnum \glyph_height<\b_count \global\glyph_height=\b_count \fi
+ \advance \c_count -\glyph_voffset
+ \ifnum \glyph_depth<\c_count \global\glyph_depth=\c_count \fi
+ \global\glyph_italic=\d_count
+ \global\glyph_map_fonts\expandafter{
+ \the\expandafter\glyph_map_fonts \a_macro
+ }
+}
+\def\glyphrule#1#2{
+ \eval_expr_to\b_count{#1} \eval_expr_to\c_count{#2}
+ \advance\glyph_width by \b_count
+ \g_eval_expr_to\glyph_depth{\max\glyph_depth{-\glyph_voffset}}
+ \g_eval_expr_to\glyph_height{
+ \max\glyph_height{\add\glyph_voffset\c_count}
+ }
+ \global\glyph_italic=0
+ \edef\a_macro{\saved_rule{\the\b_count}{\the\c_count}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\glyphspecial#1{
+ \edef\a_macro{\saved_special{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\glyphwarning#1{
+ \edef\a_macro{\saved_warning{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\movert#1{
+ \eval_expr{#1}
+ \ifnum \glyph_maxhpos<\glyph_width
+ \global\glyph_maxhpos\glyph_width
+ \fi
+ \ifnum 0=\result \else
+ \advance\glyph_width by \result
+ \edef\a_macro{\saved_movert{\the\result}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \fi
+}
+\def\moveup#1{
+ \eval_expr{#1}
+ \ifnum\result=0\else
+ \advance\glyph_voffset by \result
+ \edef\a_macro{\saved_moveup{\the\result}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \fi
+}
+\def\push{
+ \bgroup
+ \global\glyph_map_commands\expandafter{
+ \the\glyph_map_commands \saved_push
+ }
+}
+\def\pop{
+ \ifnum \glyph_maxhpos<\glyph_width
+ \global\glyph_maxhpos\glyph_width
+ \fi
+ \egroup
+ \global\glyph_map_commands\expandafter{
+ \the\glyph_map_commands \saved_pop
+ }
+}
+\def\resetwidth#1{\movert{\sub{#1}\glyph_width}}
+\def\resetheight{\g_eval_expr_to\glyph_height}
+\def\resetdepth{\g_eval_expr_to\glyph_depth}
+\def\resetitalic{\g_eval_expr_to\glyph_italic}
+\def\glyphpcc#1#2#3{
+ \ifisglyph{\glyph_name_modifier{#1}}\then
+ \push
+ \movert{#2}
+ \moveup{#3}
+ \glyph{\glyph_name_modifier{#1}}{\one_thousand}
+ \pop
+ \else\ifisglyph{\glyph_name_modifier{#1}-not}\then
+ \fontinstwarning{\string\glyphpcc}{
+ Base~glyph~`\glyph_name_modifier{#1}'~not~appended,\messagebreak
+ because~it~is~so~far~unencoded~in~the~glyph~base
+ }
+ \else
+ \fontinsterror{\string\glyphpcc}{
+ Base~glyph~not~set.\messagebreak
+ This~could~be~a~sign~that~the~AFM~file~is~buggy
+ }\error_help_a
+ \fi\fi
+}
+\def\glyphbboxright{\max\glyph_width\glyph_maxhpos}
+\def\samesize#1{
+ \if_undefined{g-\glyph_name_modifier{#1}}\then
+ \resetwidth{\glyphbboxright}
+ \else
+ \expandafter\expandafter\expandafter
+ \same_size\csname g-\glyph_name_modifier{#1}\endcsname
+ \fi
+}
+\def\same_size#1#2#3#4#5#6{
+ \movert{\sub{#1}\glyph_width}
+ \global\glyph_height=#2
+ \global\glyph_depth=#3
+ \global\glyph_italic=#4
+}
+\def\ifisglyph#1\then{\if_defined{g-#1}\then}
+\def\ifareglyphs#1\then{
+ \process_csep_list{\if_is_glyph}#1,\process_csep_list,
+ \if_true
+}
+\def\if_is_glyph#1{
+ \if_undefined{g-#1}\then \expandafter\if_false \fi
+}
+\def\etxtovpl#1#2{{
+ \def\vpl_extension{vpl}
+ \def\vpl_title{COMMENT}
+ \def\vpl_font{virtual~font}
+ \def\vpl_Font{Virtual~font}
+ \def\vpl_call{\string\etxtovpl{#1}{#2}}
+ \def\vpl_to_vf##1{vptovf~##1.vpl~##1.vf~##1.tfm}
+ \a_toks={}
+ \process_csep_list\make_inputetx #1,\process_csep_list,
+ \expandafter\etx_to_font \expandafter{\the\a_toks}{#2}
+}}
+\def\etxtopl#1#2{{
+ \def\vpl_extension{pl}
+ \def\vpl_title{COMMENT}
+ \def\vpl_font{font}
+ \def\vpl_Font{Font}
+ \def\vpl_call{\string\etxtopl{#1}{#2}}
+ \def\vpl_to_vf##1{pltotf~##1.pl~##1.tfm}
+ \_including_map_false
+ \global\rawfont_scaling=-\p@
+ \a_toks={}
+ \process_csep_list\make_inputetx #1,\process_csep_list,
+ \expandafter\etx_to_font \expandafter{\the\a_toks}{#2}
+}}
+\newif\if_including_map_
+\_including_map_true
+\def\make_inputetx#1{
+ \def\a_macro{\noexpand\inputetx{\file_name}}
+ \get_file_name #1~{}~\par
+ \edef\a_macro{\a_macro}
+ \a_toks=\expandafter{ \the\expandafter\a_toks \a_macro}
+}
+\x_cs\def{IFKW-mtxasetx}{
+ \def\a_macro{\noexpand\input_mtx_as_etx{\file_name}}
+ \get_keyword
+}
+\def\etx_to_font#1#2{
+ \make_assignments{#1}
+ \open_out{#2.\vpl_extension}
+ \top_of_pl_hook
+ \out_line{(\vpl_title\space\vpl_font\space
+ #2~created~by~fontinst~v\fontinstversion)}
+ \out_line{}
+ \out_line{(COMMENT~Filename:~#2.\vpl_extension)}
+ \out_line{(COMMENT~Created~by:~tex~\jobname)}
+ \out_line{(COMMENT~Created~using:~\vpl_call)}
+ \out_line{}
+ \out_line{(COMMENT~This~file~can~be~turned~into~a~\vpl_font\space
+ with)}
+ \out_line{(COMMENT~\vpl_to_vf{#2})}
+ \out_line{}
+ \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)}
+ \out_line{}
+ \make_header{#1}
+ \if_including_map_ \make_mapfonts{#1} \fi
+ \make_fontdimens{#1}
+ \make_ligtable{#1}
+ \make_characters{#1}
+ \make_tidy{#1}
+ \out_line{}
+ \out_line{(COMMENT~END~OF~FILE~#2.\vpl_extension)}
+ \close_out{\vpl_Font}
+}
+\let\pre_first_etx_pass_hook\x_relax
+\let\pre_second_etx_pass_hook\x_relax
+\let\pre_third_etx_pass_hook\x_relax
+\let\pre_fourth_etx_pass_hook\x_relax
+\let\post_first_etx_pass_hook\x_relax
+\let\post_second_etx_pass_hook\x_relax
+\let\post_third_etx_pass_hook\x_relax
+\let\post_fourth_etx_pass_hook\x_relax
+\let\tidying_up_hook\x_relax
+\let\top_of_pl_hook\x_relax
+\def\make_assignments#1{
+ \let\do_slot=\assign_slot
+ \let\end_do_slot=\end_assign_slot
+ \def\do_boundary{\bgroup
+ \let\makerightboundary=\bad_makerightboundary
+ }
+ \let\endsetleftboundary=\egroup
+ \let\makerightboundary=\assign_rboundary
+ \pre_first_etx_pass_hook
+ #1
+ \post_first_etx_pass_hook
+ \let\end_do_slot=\empty_command
+ \let\do_boundary=\x_relax
+ \let\endsetleftboundary=\x_relax
+ \let\makerightboundary=\gobble_one
+}
+\def\assign_slot{\a_toks={\do}}
+\begingroup
+ \catcode0=12
+ \gdef\end_assign_slot{
+ \ifisglyph\slot_name\then
+ \lccode0=\slot_number
+ \lowercase{
+ \expandafter\add_to
+ \csname slots-\slot_name\expandafter\endcsname
+ \expandafter{\the\a_toks^^@}
+ }
+ \fi
+ }
+ \gdef\assign_rboundary#1{
+ \lccode0=\slot_number
+ \lowercase{\x_cs\add_to{slots-#1}{\rboundary_do^^@}}
+ \x_setint{\percent_char boundarychar}\slot_number
+ \a_toks={\rbserver_do}
+ }
+\endgroup
+\def\bad_makerightboundary#1{
+ \errhelp={The~left~boundary~is~not~a~slot,~so~it~cannot~serve~
+ as~right~boundary.}
+ \errmessage{Incorrect~use~of~\string\makerightboundary}
+}
+\def\get_slot_num#1{
+ \global\result=-1
+ \bgroup
+ \def\do{\global\result=`}
+ \let\rbserver_do=\do
+ \let\rboundary_do=\gobble_one
+ \csname slots-#1\endcsname
+ \egroup
+}
+\def\ifisinslot#1#2\then{
+ \ifx \makerightboundary\gobble_one
+ \eval_expr{#2}
+ \begingroup
+ \def\do##1{\ifnum `##1=\result \let\do=\gobble_one \fi}
+ \def\rbserver_do{\do}
+ \let\rboundary_do=\gobble_one
+ \csname slots-#1\endcsname
+ \expandafter\endgroup
+ \ifx \do\gobble_one
+ \expandafter\expandafter \expandafter\if_true
+ \else
+ \expandafter\expandafter \expandafter\if_false
+ \fi
+ \else
+ \expandafter\gobble_if
+ \fi
+}
+\newdimen\mapfont_scaling
+\mapfont_scaling=1pt
+\newdimen\rawfont_scaling
+\def\vpl_real#1{R~\expandafter\lose_measure\the#1}
+\def\vpl_int#1{D~\the#1}
+\newdimen\side_bearings
+\newdimen\curr_bearings
+\def\make_header#1{
+ \global\font_count=0
+ \setdim{designsize}{10pt}
+ \a_dimen=\dim{designsize}
+ \out_line{(DESIGNSIZE~\vpl_real\a_dimen)}
+ \x_setstr{codingscheme}{UNKNOWN}
+ \out_line{(CODINGSCHEME~\str{codingscheme})}
+ \ifisint{\percent_char boundarychar}\then
+ \a_count=\int{\percent_char boundarychar}
+ \out_line{(BOUNDARYCHAR~\vpl_int\a_count)}
+ \fi
+ \x_setint{letterspacing}{0}
+ \side_bearings=\make_factor{\int{letterspacing}}\half_point
+ \x_setint{minimumkern}{0}
+ \minimum_kern=\int{minimumkern}
+ \out_line{}
+}
+\def\make_mapfonts#1{
+ \let\saved_scale\vpl_scale
+ \let\saved_mapfont\vpl_mapfont
+ \let\do_slot=\do_mapfont
+ \pre_second_etx_pass_hook
+ #1
+ \post_second_etx_pass_hook
+ \out_line{}
+}
+\def\do_mapfont{
+ \ifisglyph\slot_name\then
+ \mapfonts\slot_name
+ \fi
+}
+\def\vpl_scale#1#2{{
+ \mapfont_scaling=\make_factor{#1}\mapfont_scaling
+ #2
+}}
+\def\vpl_mapfont#1#2{
+ \a_dimen=#2
+ \if_undefined{\the\mapfont_scaling-#1}\then
+ \global\x_cs\mathchardef{\the\mapfont_scaling-#1}=\font_count
+ \x_cs\xdef{f-\the\font_count}{\the\mapfont_scaling-#1}
+ \out_line{(MAPFONT~\vpl_int\font_count\space
+ (FONTNAME~#1)~
+ (FONTDSIZE~\vpl_real\a_dimen)~
+ (FONTAT~\vpl_real\mapfont_scaling))}
+ \record_usage{#1}
+ \global\advance\font_count by 1
+ \fi
+}
+\def\pl_mapfont#1#2{\global\rawfont_scaling=\mapfont_scaling}
+\newcount\font_count
+\newcount\next_mapfont
+\newcount\prev_mapfont
+\def\make_fontdimens#1{
+ \out_line{(FONTDIMEN}
+ \a_count=1
+ \loop\ifnum 256>\a_count
+ \ifisint{fontdimen(\the\a_count)}\then
+ \out_lline{(PARAMETER~\vpl_int\a_count\space
+ R~\make_factor{\int{fontdimen(\the\a_count)}})}
+ \fi
+ \advance \a_count \@ne
+ \repeat
+ \out_lline{)}
+ \out_line{}
+}
+\def\make_ligtable#1{
+ \begingroup
+ \out_line{(LIGTABLE}
+ \let\do_slot=\bgroup
+ \let\end_do_slot=\vpl_kerning
+ \def\do_boundary{\bgroup \let\vpl_liglabel=\boundary_liglabel}
+ \let\endsetleftboundary=\vpl_kerning
+ \let\ligature=\vpl_ligature
+ \let\k=\vpl_kern
+ \let\rbserver_do=\vpl_rbserver_do
+ \let\rboundary_do=\vpl_rboundary_do
+ \pre_third_etx_pass_hook
+ #1
+ \post_third_etx_pass_hook
+ \out_lline{)}
+ \endgroup
+ \out_line{}
+}
+\def\vpl_rbserver_do#1{
+ \do{#1}
+ \let\rboundary_do=\wrn_rboundary_do
+}
+\def\vpl_rboundary_do#1{
+ \do{#1}
+ \let\rbserver_do=\wrn_rboundary_do
+}
+\def\wrn_rboundary_do#1{
+ \do{#1}
+ \immediate\write16{Boundarychar~slot~usage~collision~in~
+ `\slot_name'~ligkern~program.}
+}
+\def\vpl_ligature#1#2#3{
+ \get_slot_num{#3}
+ \ifnum -1=\result
+ \immediate\write16{Warning:~\string\ligature\space
+ for~unknown~slot~`#3'.}
+ \else
+ \x_cs\ifx{slots-#2}\x_relax
+ \immediate\write16{Warning:~\string\ligature\space
+ for~unknown~slot~`#2'.}
+ \else
+ \def\do##1{
+ \vpl_liglabel
+ \out_lline{(#1~D~\number`##1~\space\vpl_int\result)~
+ (COMMENT~#2~#3)}
+ }
+ \csname slots-#2\endcsname
+ \fi
+ \fi
+}
+\def\vpl_kerning{
+ \let\do=\vpl_kern_do
+ \csname~r-\slot_name\endcsname
+ \vpl_ligstop
+ \egroup
+}
+\def\vpl_kern#1#2{
+ \edef\a_macro{\expandafter\gobble_three\string#1}
+ \a_count=\expandafter\gobble_one\string#2\x_relax
+ \ifnum \ifnum -\a_count>\a_count - \fi\a_count>\minimum_kern
+ \edef\b_macro{~R~\make_factor\a_count}
+ \csname slots-\a_macro\endcsname
+ \fi
+ \x_cs\let{slots-\a_macro}=\x_relax
+}
+\def\vpl_kern_do#1{
+ \vpl_liglabel
+ \out_lline{
+ (KRN~D~\number`#1~\b_macro)~
+ (COMMENT~\a_macro)
+ }
+}
+\def\out_liglabel{
+ \out_lline{(LABEL~\vpl_int\slot_number)~(COMMENT~\slot_name)}
+ \let\vpl_liglabel=\x_relax
+ \let\vpl_ligstop=\out_ligstop
+}
+\def\boundary_liglabel{
+ \out_lline{(LABEL~BOUNDARYCHAR)~(COMMENT~\slot_name)}
+ \let\vpl_liglabel=\x_relax
+ \let\vpl_ligstop=\out_ligstop
+}
+\let\vpl_liglabel=\out_liglabel
+\def\out_ligstop{\out_lline{(STOP)}
+ \let\vpl_liglabel=\out_liglabel
+ \let\vpl_ligstop=\x_relax}
+\let\vpl_ligstop=\x_relax
+\def\make_characters#1{
+ \bgroup
+ \let\do_slot=\do_character
+ \let\end_do_slot=\end_do_character
+ \let\nextlarger=\vpl_nextlarger
+ \let\varchar=\vpl_varchar
+ \let\endvarchar=\end_vpl_varchar
+ \let\vartop=\vpl_vartop
+ \let\varmid=\vpl_varmid
+ \let\varbot=\vpl_varbot
+ \let\varrep=\vpl_varrep
+ \if_including_map_
+ \let\saved_raw\vpl_raw
+ \let\saved_rule\vpl_rule
+ \let\saved_special\vpl_special
+ \let\saved_warning\vpl_warning
+ \let\saved_movert\vpl_movert
+ \let\saved_moveup\vpl_moveup
+ \let\saved_push\vpl_push
+ \let\saved_pop\vpl_pop
+ \else
+ \def\do_character_map{
+ \ifdim \rawfont_scaling=-\p@
+ \mapfonts\slot_name
+ \else
+ \let\do_character_map=\x_relax
+ \fi
+ }
+ \let\saved_mapfont\pl_mapfont
+ \let\saved_scale\vpl_scale
+ \fi
+ \pre_fourth_etx_pass_hook
+ #1
+ \post_fourth_etx_pass_hook
+ \egroup
+}
+\def\do_character{
+ \if_undefined{g-\slot_name}\then
+ \ifisint{requireglyphs}\then
+ \fontinstwarning{ETX~to~(V)PL}{
+ Undefined~glyph~`\slot_name'~requested\message_break
+ for~slot~\the\slot_number\message_number}
+ \fi
+ \expandafter\gobble_setslot
+ \else
+ \ifx\slot_name\notdef_name\else
+ \out_line{(CHARACTER~\vpl_int\slot_number\space
+ (COMMENT~\slot_name)}
+ \glyph_parameter\glyph_metrics\slot_name
+ \a_dimen=\make_factor\a_count \p@
+ \do_character_sidebearings
+ \out_lline{(CHARWD~\vpl_real\a_dimen)}
+ \ifnum \z@=\b_count \else
+ \out_lline{(CHARHT~R~\make_factor\b_count)}
+ \fi
+ \ifnum \z@=\c_count \else
+ \out_lline{(CHARDP~R~\make_factor\c_count)}
+ \fi
+ \ifnum \z@=\d_count \else
+ \out_lline{(CHARIC~R~\make_factor\d_count)}
+ \fi
+ \do_character_map
+ \fi
+ \fi
+}
+\def\do_character_sidebearings{
+ \ifisint{\slot_name-spacing}\then
+ \curr_bearings=\make_factor{\int{\slot_name-spacing}}\half_point
+ \else
+ \curr_bearings=\side_bearings
+ \fi
+ \advance\a_dimen by 2\curr_bearings
+}
+\def\do_character_map{
+ \global\prev_mapfont=0
+ \out_lline{(MAP}
+ \ifdim 0pt=\curr_bearings
+ \mapcommands\slot_name
+ \else
+ \out_llline{(MOVERIGHT~\vpl_real\curr_bearings)}
+ \mapcommands\slot_name
+ \out_llline{(MOVERIGHT~\vpl_real\curr_bearings)}
+ \fi
+ \out_llline{)}
+}
+\long\def\gobble_setslot#1\endsetslot{\endsetslot}
+\def\end_do_character{
+ \ifisglyph\slot_name\then
+ \out_lline{)}
+ \fi
+}
+\def\notdef_name{.notdef}
+\def\vpl_nextlarger#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_lline{(NEXTLARGER~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\nextlarger\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varchar{\out_lline{(VARCHAR}}
+\def\end_vpl_varchar{\out_llline{)}}
+\def\vpl_vartop#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(TOP~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\vartop\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varmid#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(MID~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varmid\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varbot#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(BOT~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varbot\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varrep#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(REP~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varrep\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_raw#1#2#3{
+ \global\next_mapfont=\csname\the\mapfont_scaling-#1\endcsname
+ \ifnum \next_mapfont=\prev_mapfont \else
+ \out_llline{(SELECTFONT~\vpl_int\next_mapfont)~
+ (COMMENT~#1~at~
+ \expandafter\lose_measure \the\mapfont_scaling)}
+ \fi
+ \out_llline{(SETCHAR~D~#2)~(COMMENT~#3)}
+ \global\prev_mapfont=\next_mapfont
+}
+\def\vpl_rule#1#2{
+ \a_dimen=\make_factor{#2}\mapfont_scaling
+ \b_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(SETRULE~\vpl_real\a_dimen\space\vpl_real\b_dimen)}
+}
+\def\vpl_special#1{
+ \out_llline{(SPECIAL~#1)}}
+\def\vpl_warning#1{
+ \ifwarningspecials
+ \out_llline{(SPECIAL~Warning:~#1)}
+ \fi
+ \immediate\write16{Warning:~#1.}
+}
+\newif\ifwarningspecials
+\warningspecialstrue
+\def\vpl_movert#1{
+ \a_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(MOVERIGHT~\vpl_real\a_dimen)}
+}
+\def\vpl_moveup#1{
+ \a_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(MOVEUP~\vpl_real\a_dimen)}
+}
+\def\vpl_push{\out_llline{(PUSH)}}
+\def\vpl_pop{\out_llline{(POP)}}
+\def\make_tidy#1{
+ \tidying_up_hook
+ \if_including_map_
+ \a_count=0
+ \loop\ifnum \a_count<\font_count
+ \edef\a_macro{\csname~f-\the\a_count\endcsname}
+ \global\x_cs\let\a_macro\x_relax
+ \advance\a_count by 1
+ \repeat
+ \global\font_count=0
+ \else
+ \ifdim \rawfont_scaling<\z@
+ \fontinstwarning{ETX~to~(V)PL}{The~font~
+ \out_filename\space doesn't~contain~any~characters}
+ \global\rawfont_scaling=\p@
+ \fi
+ \ifdim \rawfont_scaling=\p@ \else
+ \out_line{(DESIGNUNITS~\vpl_real\rawfont_scaling)}
+ \fi
+ \fi
+}
+\newtoks\family_toks
+\def\installfonts{
+ \bgroup
+ \global\family_toks={}
+ \gdef\prev_file_list{}
+ \global\let\setsomething_global=\global
+}
+\def\installfamily#1#2#3{
+ \global\family_toks=
+ \expandafter{\the\family_toks\fd_family{#1}{#2}{#3}}
+ \global\x_cs\let{#1-#2}\empty_command
+}
+\def\installfont#1#2#3#4#5#6#7#8{
+ \global\let\setsomething_global=\x_relax
+ \input_metrics{}{#2}
+ \etxtovpl{#3}{#1}
+ \installfontas{#1}{#4}{#5}{#6}{#7}{#8}
+ \global\let\setsomething_global=\global
+}
+\def\installrawfont#1#2#3#4#5#6#7#8{
+ \global\let\setsomething_global=\x_relax
+ \xdef\out_filename{#1}
+ \input_metrics{\let\storemapdata=\installraw_storemap}{#2}
+ \let\storemapdata=\gobble_three
+ \etxtopl{#3}{#1}
+ \record_usage{#1}
+ \installfontas{
+ \ifdim \rawfont_scaling=\p@ \else
+ [\expandafter\lose_measure\the\rawfont_scaling]~
+ \fi #1
+ }{#4}{#5}{#6}{#7}{#8}
+ \global\let\setsomething_global=\global
+}
+\def\installraw_storemap#1#2#3{
+ \def\a_macro{#1}
+ \ifx \a_macro\out_filename \else
+ \record_transform{\out_filename}{\string\frommtx{#1}}{}\if_false
+ \fi
+}
+\def\input_metrics#1#2{
+ \let\metrics=\file_list_metrics
+ \xdef\curr_file_list{#2,}
+ \let\metrics=\x_relax
+ \ifx\prev_file_list\curr_file_list\else
+ \egroup\bgroup
+ #1
+ \expandafter\process_csep_list \expandafter\input_mtx_file
+ \curr_file_list\process_csep_list,
+ \global\let\prev_file_list=\curr_file_list
+ \fi
+}
+\def\file_list_metrics#1,{
+ \iffalse{\fi}
+ \a_toks=\expandafter{\curr_file_list\x_relax#1,}
+ \xdef\curr_file_list{\the\a_toks \iffalse}\fi
+}
+\def\installfontas#1#2#3#4#5#6{
+ \if_undefined{#2-#3-#4-#5}\then
+ \let\do_shape=\x_relax
+ \if_undefined{#2-#3}\then
+ \x_cs\let{#2-#3}\empty_command
+ \autoinstallfamily{#2}{#3}
+ \fi
+ \x_cs\xdef{#2-#3}{
+ \csname#2-#3\endcsname
+ \do_shape{#2}{#3}{#4}{#5}
+ }
+ \fi
+ \let\do_size=\x_relax
+ \x_cs\xdef{#2-#3-#4-#5}{
+ \if_defined{#2-#3-#4-#5}\then
+ \csname#2-#3-#4-#5\endcsname
+ \fi
+ \do_size{#6}{#1}
+ }
+}
+\def\autoinstallfamily#1#2{\installfamily{#1}{#2}{}}
+\def\endinstallfonts{
+ \global\let\setsomething_global=\x_relax
+ \let\do_shape=\fd_shape
+ \let\do_size=\fd_size
+ \the\family_toks
+ \global\family_toks{}
+ \egroup
+}
+\def\input_mtx_file#1{
+ \reset_modifiers_hook
+ \ifx\x_relax#1\x_relax
+ \else
+ \identity_one{\get_file_name #1~}~\par
+ \ifx \pl_encoding\empty_command
+ \fromany\file_name
+ \else
+ \metrics_given_encoding{\file_name}{\pl_encoding}
+ \fi
+ \ifisstr{afm-name}\then
+ \inputmtx{\str{afm-name}}
+ \else
+ \fontinsterror{\string\install...}{
+ Font/MTX~file~\file_name\space not~found
+ }{
+ You~can~insert~an~\string\inputmtx\space command~here
+ \messagebreak to~input~some~other~MTX~file~instead.
+ \ifisint{rawscale}\then \messagebreak
+ The~requested~raw~scaling~will~then~be~applied~on~that.
+ \fi
+ }
+ \fi
+ \fi
+}
+\def\metrics_given_encoding#1#2{
+ \x_cs\edef{s-afm-name}{#1-#2}
+ \if_file_exists{#1.pl}\then
+ \generalpltomtx{#1}{#1-#2}{pl}{#2}
+ \else
+ \if_file_exists{#1.vpl}\then
+ \generalpltomtx{#1}{#1-#2}{vpl}{#2}
+ \else
+ \unsetstr{afm-name}
+ \fi\fi
+}
+\def\reset_modifiers_hook{
+ \unsetint{rawscale}
+ \let\glyph_name_modifier\identity_one
+ \let\pl_encoding\empty_command
+ \let\list_of_options\empty_command
+}
+\def\get_file_name #1~{
+ \edef\file_name{#1}
+ \get_keyword
+}
+\def\get_keyword #1~{
+ \if_defined{IFKW-#1}\then
+ \csname IFKW-#1 \expandafter\endcsname
+ \else
+ \fontinsterror{\string\install...}{
+ `#1'~is~not~a~defined~keyword
+ }{
+ \error_help_a\messagebreak
+ Extra~tokens~will~be~flushed.
+ }
+ \expandafter\gobble_keywords
+ \fi
+}
+\def\gobble_keywords#1\par{}
+\x_cs\let{IFKW-}=\gobble_keywords
+\x_cs\def{IFKW-scaled}#1~{
+ \ifnum #1=\one_thousand
+ \unsetint{rawscale}
+ \else
+ \x_resetint{rawscale}{#1}
+ \fi
+ \get_keyword
+}
+\x_cs\def{IFKW-suffix}#1~{
+ \def\glyph_name_modifier##1{##1#1}
+ \get_keyword
+}
+\x_cs\def{IFKW-encoding}#1~{
+ \def\pl_encoding{#1}
+ \get_keyword
+}
+\let\pl_encoding=\empty_command
+\x_cs\def{IFKW-option}#1~{
+ \add_to\list_of_options{\do{#1}}
+}
+\def\ifoption#1\then{
+ \_a_false
+ \edef\a_macro{#1}
+ \def\do##1{
+ \if_a_ \else
+ \def\b_macro{##1}
+ \ifx \a_macro\b_macro \_a_true \fi
+ \fi
+ }
+ \list_of_options
+ \if_a_
+}
+\let\list_of_options\empty_command
+\def\fd_family#1#2#3{
+ \a_toks{#3}
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1#2.fd}}}
+ \lowercase_file
+ \open_out{\lowercase_file}
+ \out_line{\percent_char~Filename:~\lowercase_file}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using~fontinst~v\fontinstversion}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~SHOULD~BE~PUT~IN~A~TEX~INPUTS~
+ DIRECTORY}
+ \out_line{}
+ \out_line{\string\ProvidesFile{\lowercase_file}}
+ \out_lline{[
+ \the\year/
+ \ifnum10>\month0\fi\the\month/
+ \ifnum10>\day0\fi\the\day\space
+ Fontinst~v\fontinstversion\space
+ font~definitions~for~#1/#2.
+ ]}
+ \out_line{}
+ \out_line{\string\DeclareFontFamily{#1}{#2}{\the\a_toks}}
+ {
+ \csname #1-#2\endcsname
+ \out_line{}
+ \let\do_shape=\substitute_shape
+ \csname #1-#2\endcsname
+ \let\do_shape=\remove_shape
+ \csname #1-#2\endcsname
+ }
+ \x_cs\g_let{#1-#2}\x_relax
+ \out_line{}
+ \out_line{\string\endinput}
+ \close_out{Font~definitions}
+}
+\def\fd_shape#1#2#3#4{
+ \out_line{}
+ \out_line{\string\DeclareFontShape{#1}{#2}{#3}{#4}\left_brace_char}
+ \csname #1-#2-#3-#4\endcsname
+ \x_cs\g_let{#1-#2-#3-#4}\empty_command
+ \out_line{\right_brace_char{}}
+}
+\def\fd_size#1#2{
+ \x_cs\ifx{siz-#1}\x_relax
+ \out_lline{#1~#2}
+ \else
+ \out_lline{\csname siz-#1\endcsname\space #2}
+ \fi
+}
+\def\remove_shape#1#2#3#4{
+ \x_cs\g_let{#1-#2-#3-#4}\x_relax
+}
+\def\substitute_shape#1#2#3#4{
+ \edef\orig_shape{#4}
+ \substitute_series{#1}{#2}{#3}{\orig_shape}
+ \x_cs\ifx{sub-\orig_shape}\x_relax\else
+ \edef\subst_shape{\csname sub-\orig_shape\endcsname}
+ \x_cs\ifx{#1-#2-#3-\subst_shape}\x_relax
+ \out_line{
+ \string\DeclareFontShape{#1}{#2}{#3}{\subst_shape}{
+ <->\csname typ-\orig_shape\endcsname\space
+ *~#2/#3/\orig_shape
+ }{}
+ }
+ \x_cs\let{#1-#2-#3-\subst_shape}\empty_command
+ \substitute_shape{#1}{#2}{#3}{\subst_shape}
+ \fi
+ \fi
+}
+\def\substitute_series#1#2#3#4{
+ \edef\orig_series{#3}
+ \x_cs\ifx{sub-\orig_series}\x_relax\else
+ \edef\subst_series{\csname sub-\orig_series\endcsname}
+ \x_cs\ifx{#1-#2-\subst_series-#4}\x_relax
+ \out_line{
+ \string\DeclareFontShape{#1}{#2}{\subst_series}{#4}{
+ <->\csname typ-\orig_series\endcsname\space
+ *~#2/\orig_series/#4
+ }{}
+ }
+ \x_cs\let{#1-#2-\subst_series-#4}\empty_command
+ \substitute_series{#1}{#2}{\subst_series}{#4}
+ \fi
+ \fi
+}
+\def\substitute_generic#1#2#3{
+ \edef\a_macro{#2}
+ \edef\b_macro{#3}
+ \ifx \a_macro \b_macro
+ \x_cs\let{sub-#3}\undefined_command
+ \else
+ \x_cs\let{sub-#3}\a_macro
+ \x_cs\def{typ-#3}{#1}
+ \fi
+}
+\def\substitutesilent{\substitute_generic{ssub}}
+\def\substitutenoisy{\substitute_generic{sub}}
+\substitutesilent{bx}{b}
+\substitutesilent{b}{bx}
+\substitutesilent{b}{sb}
+\substitutesilent{b}{db}
+\substitutesilent{m}{mb}
+\substitutesilent{m}{l}
+\substitutenoisy{ui}{it}
+\substitutesilent{sl}{it}
+\substitutesilent{it}{sl}
+\def\declareencoding#1#2{\x_cs\edef{enc-#1}{#2}}
+\declareencoding{TEX~TEXT}{ot1}
+\declareencoding{TEX~TEXT~WITHOUT~F-LIGATURES}{ot1}
+\declareencoding{TEX~TYPEWRITER~TEXT}{ot1tt}
+\declareencoding{TEX~MATH~ITALIC}{oml}
+\declareencoding{TEX~MATH~SYMBOLS}{oms}
+\declareencoding{TEX~MATH~EXTENSION}{omx}
+\declareencoding{LATEX~SYMBOLS}{lasy}
+\declareencoding{TEX~TEXT~SUBSET}{eufrak}
+\declareencoding{TEX~MATH~ITALIC~SUBSET}{eurm}
+\declareencoding{TEX~MATH~SYMBOLS~SUBSET}{euscr}
+\declareencoding{EULER~SUBSTITUTIONS~ONLY}{euex}
+\declareencoding{EXTENDED~TEX~FONT~ENCODING~-~LATIN}{t1}
+\declareencoding{TEX~TEXT~COMPANION~SYMBOLS~1---TS1}{ts1}
+\declareencoding{TEXBASE1ENCODING}{8r}
+\declareencoding{TEX~TYPEWRITER~AND~WINDOWS~ANSI}{8y}
+\def\declaresize#1#2{\x_cs\edef{siz-#1}{#2}}
+\declaresize{}{<->}
+\declaresize{5}{<5>}
+\declaresize{6}{<6>}
+\declaresize{7}{<7>}
+\declaresize{8}{<8>}
+\declaresize{9}{<9>}
+\declaresize{10}{<10>}
+\declaresize{11}{<10.95>}
+\declaresize{12}{<12>}
+\declaresize{14}{<14.4>}
+\declaresize{17}{<17.28>}
+\declaresize{20}{<20.74>}
+\declaresize{25}{<24.88>}
+\def\NOFILES{
+ \def\transformfont##1##2{
+ \touch_file{##1.mtx}
+ \touch_file{##1.pl}
+ }
+ \def\reglyphfont##1##2{\touch_file{##1.mtx}}
+ \def\installfonts{}
+ \def\endinstallfonts{}
+ \def\installfont##1##2##3##4##5##6##7##8{
+ \touch_file{##1.vpl}
+ }
+ \def\installrawfont##1##2##3##4##5##6##7##8{
+ \touch_file{##1.pl}
+ }
+ \def\installfamily##1##2##3{\touch_file{##1##2.fd}}
+}
+\def\touch_file#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \open_out{\lowercase_file}
+ \out_line{\percent_char~TEST~FILE.}
+ \out_line{\percent_char~Created~whilst~debugging~fontinst.}
+ \close_out{Test~file}
+}
+%%% From file: fitrig.dtx
+\chardef\nin@ty=90
+\chardef\@clxxx=180
+\chardef\@lxxi=71
+\mathchardef\@mmmmlxviii=4068
+\chardef\@coeffz=72
+\chardef\@coefb=42
+\mathchardef\@coefc=840
+\mathchardef\@coefd=5040
+\def\TG@rem@pt#1{\expandafter\lose_measure\the#1\space}
+\def\TG@term#1{
+ \dimen@\@tempb\dimen@
+ \advance\dimen@ #1\p@
+}
+\def\TG@series{
+ \dimen@\@lxxi\dimen@
+ \divide \dimen@ \@mmmmlxviii
+ \edef\@tempa{\TG@rem@pt\dimen@}
+ \dimen@\@tempa\dimen@
+ \edef\@tempb{\TG@rem@pt\dimen@}
+ \divide\dimen@\@coeffz
+ \advance\dimen@\m@ne\p@
+ \TG@term\@coefb
+ \TG@term{-\@coefc}%
+ \TG@term\@coefd
+ \dimen@\@tempa\dimen@
+ \divide\dimen@ \@coefd
+}
+\def\CalculateSin#1{{%
+ \if_undefined{sin(\number#1)}\then
+ \dimen@=#1\p@
+ \TG@@sin
+ \x_cs\xdef{sin(\number#1)}{\TG@rem@pt\dimen@}
+ \fi
+}}
+\def\CalculateCos#1{{%
+ \if_undefined{cos(\number#1)}\then
+ \dimen@=\nin@ty\p@
+ \advance \dimen@ -#1\p@
+ \TG@@sin
+ \x_cs\xdef{cos(\number#1)}{\TG@rem@pt\dimen@}
+ \fi
+}}
+\def\TG@@sin{%
+ \ifdim\TG@reduce>+%
+ \else\ifdim\TG@reduce<-%
+ \else\TG@series\fi\fi
+}
+\def\TG@reduce#1#2{
+ \dimen@#1#2\nin@ty\p@
+ \advance\dimen@#2-\@clxxx\p@
+ \dimen@-\dimen@
+ \TG@@sin
+}
+\def\UseSin#1{\csname sin(\number#1)\endcsname}
+\def\UseCos#1{\csname cos(\number#1)\endcsname}
+\chardef\z@num\z@
+\x_cs\let{sin(0)} \z@num
+\x_cs\let{cos(0)} \@ne
+\x_cs\let{sin(90)} \@ne
+\x_cs\let{cos(90)} \z@num
+\x_cs\let{sin(-90)}\m@ne
+\x_cs\let{cos(-90)}\z@num
+\x_cs\let{sin(180)}\z@num
+\x_cs\let{cos(180)}\m@ne
+\def\CalculateTan#1{{%
+ \if_undefined{tan(\number#1)}\then
+ \CalculateSin{#1}%
+ \CalculateCos{#1}%
+ \a_dimen\UseCos{#1}\p@
+ \divide \a_dimen \@iv
+ \b_dimen\UseSin{#1}\p@
+ \b_dimen\two@fourteen\b_dimen
+ \divide\b_dimen\a_dimen
+ \x_cs\xdef{tan(\number#1)}{\TG@rem@pt\b_dimen}
+ \fi
+}}
+\def\UseTan#1{\csname tan(\number#1)\endcsname}
+\mathchardef\two@fourteen=16384
+\chardef\@iv=4
+\x_cs\def{tan(90)}{\errmessage{Infinite tan !}}
+\expandafter\let
+ \csname tan(-90)\expandafter\endcsname \csname tan(90)\endcsname
+%%% From file: ficonv.dtx
+\def\afmtomtx#1#2{{
+ \let\setsomething_global=\x_relax
+ \open_out{\temp_prefix#2.mtx}
+ \edef\raw_font_name{#2}
+ \edef\source_font_name{#1}
+ \x_resetint{italicslant}{0}
+ \let\italcorr_expression=\uprightitalcorr
+ \x_setint{minimumkern}{0}
+ \minimum_kern=\int{minimumkern}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\afmtomtx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.afm~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \catcode`\^^M=12
+ \catcode`\ =10
+ \expandafter\afm_line\primitiveinput #1.afm\x_relax
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Metrics}
+}}
+\newcount\minimum_kern
+\def\afm_length#1#2{
+ \a_dimen=#2\afm_unit_dimen
+ #1=\a_dimen
+ \divide #1 by \afm_unit_dimen
+ \advance \a_dimen by -#1\afm_unit_dimen
+ \ifdim \a_dimen>0.5\afm_unit_dimen
+ \advance #1 by 1
+ \else \ifdim \a_dimen<-0.5\afm_unit_dimen
+ \advance #1 by -1
+ \fi\fi
+ \x_relax
+}
+\newdimen\afm_unit_dimen
+\afm_unit_dimen=1000sp
+{\catcode`\^^M=12 \gdef\afm_line#1
+{\afm_command#1~\end_of_line\afm_line}}
+\def\afm_command#1~{\csname~afm-#1\endcsname\gobble_one_line}
+\def\gobble_one_line#1\end_of_line{}
+\x_cs\def{afm-EndFontMetrics}#1\afm_line{\endinput}
+\def\afm_def#1(#2)#3{
+ \x_cs\def{afm-#1}\gobble_one_line#2\end_of_line{#3}
+}
+\def\afm_let#1#2{
+ \expandafter\let \csname afm-#1\expandafter\endcsname
+ \csname afm-#2\endcsname
+}
+\afm_def{CharWidth}(#1){\afm_length\char_x_width{#1}}
+\afm_def{ItalicAngle}(#1~){\calculate_it_slant{#1}}
+\afm_def{XHeight}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{xheight}{\the\a_count}}}
+\afm_def{CapHeight}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{capheight}{\the\a_count}}}
+\afm_def{Ascender}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{ascender}{\the\a_count}}}
+\afm_def{Descender}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{descender_neg}{\the\a_count}}}
+\afm_def{UnderlineThickness}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{underlinethickness}{\the\a_count}}}
+\afm_def{FontBBox}(#1~#2~#3~#4){
+ \afm_length\a_count{#4}
+ \out_line{\string\setint{maxheight}{\the\a_count}}
+ \afm_length\a_count{#2}
+ \out_line{\string\setint{maxdepth_neg}{\the\a_count}}}
+\afm_def{StdVW}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{verticalstem}{\the\a_count}}}
+\afm_def{IsFixedPitch}(#1){
+ \if\first_char#1=f
+ \else\out_line{\string\setint{monowidth}{1}}
+ \fi
+}
+\afm_def{FontName}(#1~){
+ \record_transform{\raw_font_name}
+ {\string\fromafm{\source_font_name}{#1}}{}\iftrue
+}
+\afm_def{KP}(#1~#2~#3~#4){
+ \if\first_char#1=.\else
+ \if\first_char#2=.\else
+ \afm_length\a_count{#3}
+ \ifnum \a_count>\minimum_kern
+ \afm_write_setkern{#1}{#2}{\the\a_count}
+ \else\ifnum \a_count<-\minimum_kern
+ \afm_write_setkern{#1}{#2}{\the\a_count}
+ \fi\fi
+ \fi\fi
+}
+\afm_let{KPX}{KP}
+\def\afm_write_setkern#1#2#3{\out_line{\string\setkern{#1}{#2}{#3}}}
+\afm_def{C}(#1~;#2){\init_afm{#1}\do_list[#2]\afm_char}
+\afm_def{CH}(<#1>~;#2){\uppercase{\init_afm{"#1}}\do_list[#2]\afm_char}
+\afm_def{CC}(#1~#2~;#3){\init_cc{#1}\do_list[#3]\cc_char}
+\newcount\char_slot
+\newcount\char_x_width
+\newcount\x_width
+\newcount\bbox_llx
+\newcount\bbox_lly
+\newcount\bbox_urx
+\newcount\bbox_ury
+\let\char_name=\empty_command
+\def\init_afm#1{
+ \char_slot=#1\x_relax
+ \x_width=\char_x_width
+ \bbox_llx=0
+ \bbox_lly=0
+ \bbox_urx=0
+ \bbox_ury=0
+ \let\char_name=\empty_command
+}
+\def\afm_char{
+ \eval_expr{
+ \italcorr_expression\x_width\bbox_llx\bbox_urx\bbox_lly\bbox_ury
+ }
+ \out_line{
+ \ifnum -1<\char_slot
+ \string\setrawglyph
+ \else
+ \string\setnotglyph
+ \fi
+ {\char_name}
+ {\raw_font_name}
+ {10pt}
+ {\the\char_slot}
+ {\the\x_width}
+ {\the\bbox_ury}
+ {\number -\bbox_lly}
+ {\the\result}
+ }
+}
+\def\init_cc#1{%
+ \out_line{\string\setglyph{#1}}
+ \def\char_name{#1}
+}
+\def\cc_char{%
+ \out_lline{\string\samesize{\char_name-not}}
+ \out_line{\string\endsetglyph}
+}
+\def\uprightitalcorr#1#2#3#4#5{0}
+\def\slanteditalcorr#1#2#3#4#5{\max{\sub{#3}{#1}}{0}}
+\def\calculate_it_slant#1{
+ \edef\theangle{#1}
+ \CalculateTan{\theangle}
+ \a_dimen=-\one_thousand sp
+ \a_dimen=\UseTan{\theangle}\a_dimen
+ \a_count=\a_dimen
+ \out_line{\string\setint{italicslant}{\the\a_count}}
+ \x_resetint{italicslant}{\a_count}
+ \ifnum 0<\a_count
+ \let\italcorr_expression=\slanteditalcorr
+ \else
+ \let\italcorr_expression=\uprightitalcorr
+ \fi
+}
+\def\do_list[~#1~#2;~#3]{
+ \csname~list-#1\endcsname\gobble_one_semi#2;
+ \ifx\x_relax#3\x_relax\expandafter\gobble_one
+ \else\expandafter\identity_one\fi
+ {\do_list[~#3]}
+}
+\def\gobble_one_semi#1;{}
+\def\list_def#1(#2)#3{\x_cs\def{list-#1}\gobble_one_semi#2~;{#3}}
+\list_def{W}(#1~#2){\afm_length\x_width{#1}}
+\list_def{WX}(#1){\afm_length\x_width{#1}}
+\list_def{WY}(#1){}
+\list_def{N}(#1){\def\char_name{#1}}
+\list_def{B}(#1~#2~#3~#4){
+ \afm_length\bbox_llx{#1}
+ \afm_length\bbox_lly{#2}
+ \afm_length\bbox_urx{#3}
+ \afm_length\bbox_ury{#4}
+}
+\list_def{PCC}(#1~#2~#3){
+ \afm_length\a_count{#2}
+ \afm_length\b_count{#3}
+ \out_lline{\string\glyphpcc{#1}{\the\a_count}{\the\b_count}}
+}
+\def\definealias#1#2#3{
+ \expandafter\def \csname GN-#1 \expandafter\endcsname
+ \expandafter{ \csname g-#2 \expandafter\endcsname
+ \csname i-#3\endcsname}
+}
+\def\glyph_alias#1{
+ \expandafter\expandafter \expandafter\glyph_alias_i
+ \csname GN-#1\endcsname
+}
+\def\glyph_alias_i#1#2{
+ \expandafter\gobble_three \string#1
+}
+\let\charnameprefix\empty
+\def\charnamealias#1{
+ \if_defined{GN-\charnameprefix#1}\then
+ \glyph_alias{\charnameprefix#1}
+ \else\if_defined{GN-#1}\then
+ \glyph_alias{#1}
+ \else
+ #1
+ \fi\fi
+}
+\def\alias_incr#1{
+ \expandafter\expandafter \expandafter\alias_incr_i
+ \csname GN-#1\endcsname
+}
+\def\alias_incr_i#1#2{
+ \ifx#2\x_relax
+ \mathchardef#2=\@ne
+ \else
+ \a_count=#2
+ \advance\a_count\@ne
+ \mathchardef#2=\a_count
+ \fi
+}
+\def\alias_char_name#1{
+ \if_defined{GN-\charnameprefix#1}\then
+ \edef\char_name{
+ \string\aliased{#1}{\glyph_alias{\charnameprefix#1}}
+ }
+ \alias_incr{\charnameprefix#1}
+ \else\if_defined{GN-#1}\then
+ \edef\char_name{
+ \string\aliased{#1}{\glyph_alias{#1}}
+ }
+ \alias_incr{#1}
+ \else
+ \edef\char_name{#1}
+ \fi\fi
+}
+\def\autoaliasafm{
+ \begingroup
+ \list_def{N}(##1){\alias_char_name{##1}}
+ \def\afm_write_setkern##1##2##3{
+ \out_line{
+ \string\setkern{\charnamealias{##1}}{\charnamealias{##2}}{##3}
+ }
+ }
+ \def\init_cc##1{%
+ \edef\char_name{\charnamealias{##1}}
+ \out_line{\string\setglyph{\char_name}}
+ }
+ \list_def{PCC}(##1~##2~##3){
+ \afm_length\a_count{##2}
+ \afm_length\b_count{##3}
+ \out_lline{\string\glyphpcc
+ {\charnamealias{##1}}{\the\a_count}{\the\b_count}}
+ }
+}
+\def\endautoaliasafm{\endgroup}
+\def\generalpltomtx#1#2#3#4{{
+ \let\setsomething_global=\x_relax
+ \let\setfontdimen=\pl_setfontdimen
+ \if _#4_ \else
+ \def\do_slot{\x_cs\let{name-\the\slot_number}\slot_name}
+ \def\do_boundary{\x_cs\let{name-BOUNDARYCHAR}\slot_name}
+ \inputetx{#4}
+ \let\CODINGSCHEME=\ignore_parens
+ \fi
+ \pl_to_mtx{#1}{#2}{#3}{\string\generalpltomtx{#1}{#2}{#3}{#4}}
+}}
+\def\pltomtx#1#2{\generalpltomtx{#1}{#2}{pl}{}}
+\def\pl_to_mtx#1#2#3#4{
+ \edef\raw_font_name{#1}
+ \open_out{\temp_prefix#2.mtx}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~#4}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.#3~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \lowercase{
+ \record_transform{#2}{
+ \string\from#3 \x_cs\ifx{from#3}\frompl {#1} \fi
+ }{}\iftrue
+ }
+ \out_line{}
+ \catcode`\(=0 \catcode`\)=9
+ \let\/=\ignore_parens
+ \let\do_pl_glyph=\x_relax
+ \primitiveinput #1.#3\x_relax
+ \do_pl_glyph
+ \out_line{}
+ \ifisint{\percent_char boundarychar}\then
+ \f_count=\int{\percent_char boundarychar}
+ \x_cs\ifx{name-\the\f_count}\x_relax \else
+ \out_line{\string\setstr{rightboundary}
+ {\csname name-\the\f_count\endcsname}
+ }
+ \out_line{}
+ \fi
+ \fi
+ \out_line{\endmetrics_text}
+ \close_out{Metrics}
+}
+\def\ignore_parens{\bgroup\catcode`(=1 \catcode`)=2 \x_relax
+ \expandafter\expandafter\expandafter\gobble_parens
+ \iftrue\expandafter{\else}\fi}
+\def\gobble_parens#1{\egroup}
+\def\pl_real#1{\pl_realer(#1000)}
+\def\pl_realer(#1.#2#3#4#5){#1#2#3#4}
+\def\pl_rounded_real(#1.#2#3#4#5){
+ \global\result=#1#2#3#4\relax
+ \ifnum \first_char#5= >4
+ \global\advance \result
+ \if - \first_char#1= \m@ne \else \@ne \fi
+ \fi
+}
+\def\pl_int#1#2{
+ \ifx#1C `#2
+ \else\ifx#1D #2
+ \else\ifx#1O '#2
+ \else\ifx#1H "#2
+ \else -1\errmessage{Unknown~PL~number~prefix~`#1'}
+ \fi\fi\fi\fi
+}
+\let\FAMILY=\ignore_parens
+\let\FACE=\ignore_parens
+\let\CHECKSUM=\ignore_parens
+\def\HEADER~#1~#2~#3~#4~{}
+\def\SEVENBITSAFEFLAG~#1~{}
+\let\COMMENT=\ignore_parens
+\let\LIG=\ignore_parens
+\let\NEXTLARGER=\ignore_parens
+\let\VARCHAR=\ignore_parens
+\let\VTITLE=\ignore_parens
+\let\MAPFONT=\ignore_parens
+\let\MAP=\ignore_parens
+\def\CODINGSCHEME{\bgroup\catcode`\)=12\x_relax\CODINGSCHEME_cont}
+\def\CODINGSCHEME_cont#1){
+ \egroup
+ \if_undefined{enc-#1}\then
+ \errhelp{The~encoding~for~`#1'~has~not~been~declared.^^J
+ You~should~declare~it~with~
+ \string\declareencoding{#1}{ETXFILE}.^^J
+ Press~<RETURN>~to~carry~on~with~fingers~crossed,^^J
+ or~X~<RETURN>~to~exit.}
+ \errmessage{Undeclared~encoding~`#1'}
+ \else
+ \def\do_slot{\x_cs\let{name-\the\slot_number}\slot_name}
+ \def\do_boundary{\x_cs\let{name-BOUNDARYCHAR}\slot_name}
+ \catcode`\(=12 \catcode`\)=12
+ \x_cs\inputetx{enc-#1}\x_relax
+ \catcode`\(=0 \catcode`\)=9
+ \fi
+}
+\def\DESIGNSIZE~#1~#2~{
+ \a_dimen=#2pt
+ \out_line{\string\setdim{designsize}{\the\a_dimen}}
+}
+\def\DESIGNUNITS~#1~#2~{
+ \b_dimen=#2pt\x_relax
+ \ifdim 1pt=\b_dimen \else
+ \fontinsterror{PL-to-MTX}{Nondefault~unit~used~in~PL~file}
+ {You~may~continue,~but~the~metrics~for~this~font~will~be~wrong.}
+ \fi
+ \out_line{\string\setdim{designunits}{\the\b_dimen}}
+}
+\def\BOUNDARYCHAR~#1~#2~{
+ \x_setint{\percent_char boundarychar}{\pl_int{#1}{#2}}
+}
+\def\pl_setfontdimen#1#2{\x_cs\def{fdimen-#1}{#2}}
+\def\PARAMETER~#1~#2~R~#3~{
+ \f_count=\pl_int{#1}{#2}\x_relax
+ \if_defined{fdimen-\the\f_count}\then
+ \pl_rounded_real(#3 0000)
+ \out_line{\string\setint{\csname fdimen-\the\f_count\endcsname}
+ {\the\result}}
+ \fi
+}
+\let\FONTDIMEN=\x_relax
+\def\SLANT{\PARAMETER D~1~}
+\pl_setfontdimen{1}{italicslant}
+\def\SPACE{\PARAMETER D~2~}
+\pl_setfontdimen{2}{interword}
+\def\STRETCH{\PARAMETER D~3~}
+\pl_setfontdimen{3}{stretchword}
+\def\SHRINK{\PARAMETER D~4~}
+\pl_setfontdimen{4}{shrinkword}
+\def\XHEIGHT{\PARAMETER D~5~}
+\pl_setfontdimen{5}{xheight}
+\def\QUAD{\PARAMETER D~6~}
+\pl_setfontdimen{6}{quad}
+\def\EXTRASPACE{\PARAMETER D~7~}
+\pl_setfontdimen{7}{extraspace}
+\def\NUM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~8~#2~#3~
+ \or
+ \PARAMETER D~9~#2~#3~
+ \or
+ \PARAMETER D~10~#2~#3~
+ \fi
+}
+\def\DENOM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~11~#2~#3~
+ \or
+ \PARAMETER D~12~#2~#3~
+ \fi
+}
+\def\SUP#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~13~#2~#3~
+ \or
+ \PARAMETER D~14~#2~#3~
+ \or
+ \PARAMETER D~15~#2~#3~
+ \fi
+}
+\def\SUB#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~16~#2~#3~
+ \or
+ \PARAMETER D~17~#2~#3~
+ \fi
+}
+\def\SUPDROP{\PARAMETER D~18~}
+\def\SUBDROP{\PARAMETER D~19~}
+\def\AXISHEIGHT{\PARAMETER D~22~}
+\def\DELIM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~20~#2~#3~
+ \or
+ \PARAMETER D~21~#2~#3~
+ \fi
+}
+\def\DEFAULTRULETHICKNESS{\PARAMETER D~8~}
+\def\BIGOPSPACING#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~9~#2~#3~
+ \or
+ \PARAMETER D~10~#2~#3~
+ \or
+ \PARAMETER D~11~#2~#3~
+ \or
+ \PARAMETER D~12~#2~#3~
+ \or
+ \PARAMETER D~13~#2~#3~
+ \fi
+}
+\def\LABEL~#1{\ifx #1B
+ \expandafter\LABEL_boundarychar
+ \else
+ \expandafter\LABEL_slot \expandafter#1
+ \fi
+}
+\def\LABEL_slot #1~#2~{
+ \f_count=\pl_int{#1}{#2}
+ \edef\a_macro{\a_macro
+ \x_cs\do_if_defined{name-\the\f_count}
+ }
+}
+\def\LABEL_boundarychar OUNDARYCHAR{
+ \edef\a_macro{\a_macro
+ \x_cs\do_if_defined{name-BOUNDARYCHAR}
+ }
+}
+\def\do_if_defined#1{\ifx #1\x_relax \else \do{#1} \fi}
+\def\LIGTABLE{\let\do=\never_do\let\a_macro\empty_command}
+\def\STOP{\let\a_macro\empty_command}
+\def\SKIP~#1~#2~{\immediate\write16{Warning:~SKIP~instruction~ignored.}}
+\def\KRN~#1~#2~R~#3~{
+ \pl_rounded_real(#3 0000)
+ \edef\do{\noexpand\write_pl_krn{\pl_int{#1}{#2}}{\the\result}}
+ \a_macro
+ \let\do=\never_do
+}
+\def\write_pl_krn#1#2#3{
+ \f_count=#1\x_relax
+ \x_cs\ifx{name-\the\f_count}\x_relax \else
+ \out_line{\string\setkern{#3}
+ {\csname name-\the\f_count\endcsname}{#2}
+ }
+ \fi
+}
+\def\CHARWD~R~#1~{\pl_rounded_real(#1 0000) \b_count=\result}
+\def\CHARHT~R~#1~{\pl_rounded_real(#1 0000) \c_count=\result}
+\def\CHARDP~R~#1~{\pl_rounded_real(#1 0000) \d_count=\result}
+\def\CHARIC~R~#1~{\pl_rounded_real(#1 0000) \e_count=\result}
+\def\CHARACTER~#1~#2~{
+ \do_pl_glyph
+ \a_count=\pl_int{#1}{#2}
+ \b_count=0
+ \c_count=0
+ \d_count=0
+ \e_count=0
+ \let\do_pl_glyph=\write_pl_glyph
+}
+\def\write_pl_glyph{
+ \x_cs\ifx{name-\the\a_count}\x_relax\else
+ \out_line{\string\setrawglyph
+ {\csname~name-\the\a_count\endcsname}
+ {\raw_font_name}
+ {\the\a_dimen}
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {\the\e_count}}
+ \fi
+ }
+\def\mtxtopl#1#2{{
+ \let\setsomething_global=\x_relax
+ \open_out{#2.pl}
+ \top_of_pl_hook
+ \out_line{(COMMENT~raw~font~#2~created~by~fontinst~
+ v\fontinstversion)}
+ \out_line{}
+ \out_line{(COMMENT~Filename:~#2.pl)}
+ \out_line{(COMMENT~Created~by:~tex~\jobname)}
+ \out_line{(COMMENT~Created~using:~\string\mtxtopl{#1}{#2})}
+ \out_line{}
+ \out_line{(COMMENT~This~file~can~be~turned~into~
+ a~ligless~TeX~font~with)}
+ \out_line{(COMMENT~pltotf~#2.pl~#2.tfm)}
+ \out_line{}
+ \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)}
+ \out_line{}
+ \out_line{(DESIGNSIZE~R~10.0)}
+ \out_line{}
+ \let\setglyph=\iffalse
+ \let\endsetglyph=\fi
+ \let\setkern=\gobble_three
+ \let\setscaledrawglyph=\first_pl_raw_glyph
+ \def\setscalednotglyph##1##2##3##4##5##6##7##8##9{}
+ \inputmtx{#1}
+ \out_line{}
+ \out_line{(COMMENT~END~OF~FILE~#2.pl)}
+ \close_out{Raw~font}
+}}
+\def\first_pl_raw_glyph#1#2#3#4{
+ \out_line{(DESIGNUNITS~R~\make_factor{#4})}
+ \let\setscaledrawglyph=\pl_raw_glyph
+ \pl_raw_glyph{#1}{#2}{#3}{#4}
+}
+\def\pl_raw_glyph#1#2#3#4#5#6#7#8#9{
+ \out_line{(CHARACTER~D~\number#5~\space(COMMENT~#1)}
+ \out_lline{(CHARWD~R~\make_factor{#6})}
+ \out_lline{(CHARHT~R~\make_factor{#7})}
+ \out_lline{(CHARDP~R~\make_factor{#8})}
+ \out_lline{(CHARIC~R~\make_factor{#9})}
+ \out_lline{)}
+}
+\def\transformfont#1#2{{
+ \let\setsomething_global=\x_relax
+ \unsetstr{afm-name}
+ \unsetstr{etx-name}
+ \x_resetint{x-scale}{\one_thousand}
+ \x_resetint{y-scale}{\one_thousand}
+ \x_resetint{slant-scale}{0}
+ #2
+ \ifisstr{afm-name}\then
+ \mtxtomtx{\str{afm-name}}{#1}
+ \mtxtopl{#1}{#1}
+ \else
+ \fontinsterror{Transformfont}{
+ Failed~to~make~transformed~font~#1;\messagebreak
+ source~font~metrics~file~not~found
+ }\error_help_a
+ \fi
+}}
+\def\fromafm#1{
+ \if_file_exists{#1.afm}\then
+ \x_setstr{afm-name}{#1}
+ \afmtomtx{#1}{#1}
+ \mtxtopl{#1}{#1}
+ \fi
+}
+\def\frommtx#1{
+ \if_file_exists{#1.mtx}\then \x_setstr{afm-name}{#1} \fi
+}
+\def\frompl#1{
+ \if_file_exists{#1.pl}\then
+ \x_setstr{afm-name}{#1}
+ \generalpltomtx{#1}{#1}{pl}{}
+ \fi
+}
+\def\fromplgivenetx#1#2{
+ \if_file_exists{#1.pl}\then
+ \x_setstr{afm-name}{#1}
+ \generalpltomtx{#1}{#1}{pl}{#2}
+ \fi
+}
+\def\fromany#1{
+ \x_cs\edef{s-afm-name}{#1}
+ \if_file_exists{#1.mtx}\then\else
+ \if_file_exists{#1.pl}\then
+ \generalpltomtx{#1}{#1}{pl}{}
+ \else
+ \if_file_exists{#1.afm}\then
+ \afmtomtx{#1}{#1}
+ \mtxtopl{#1}{#1}
+ \else
+ \if_file_exists{#1.vpl}\then
+ \generalpltomtx{#1}{#1}{vpl}{}
+ \else
+ \unsetstr{afm-name}
+ \fi\fi\fi\fi
+}
+\def\scalefont#1#2{
+ \eval_expr_to\d_count{#1}
+ \x_resetint{x-scale}{\scale{\d_count}{\int{x-scale}}}
+ \x_resetint{y-scale}{\scale{\d_count}{\int{y-scale}}}
+ \x_resetint{slant-scale}{\scale{\d_count}{\int{slant-scale}}}
+ #2
+}
+\def\xscalefont#1#2{
+ \x_resetint{x-scale}{\scale{#1}{\int{x-scale}}}
+ #2
+}
+\def\yscalefont#1#2{
+ \eval_expr_to\d_count{#1}
+ \x_resetint{y-scale}{\scale{\d_count}{\int{y-scale}}}
+ \x_resetint{slant-scale}{\scale{\d_count}{\int{slant-scale}}}
+ #2
+}
+\def\slantfont#1#2{
+ \x_resetint{slant-scale}{
+ \add{\scale{#1}{\int{x-scale}}}{\int{slant-scale}}
+ }
+ #2
+}
+\def\reencodefont#1#2{
+ #2
+ \resetstr{etx-name}{#1}
+}
+\def\mtxtomtx#1#2{{
+ \let\a_macro=\empty_command
+ \_a_true
+ \ifnum \int{x-scale}=\int{y-scale}
+ \ifnum \int{slant-scale}=\z@
+ \_a_false
+ \fi \fi
+ \if_a_
+ \a_count=\int{x-scale}
+ \l_inv_scale\a_count{\int{y-scale}}
+ \b_count=\int{slant-scale}
+ \l_inv_scale\b_count{\int{y-scale}}
+ \edef\a_macro{\a_macro
+ \string\transformfont{\the\a_count}{\the\b_count}
+ }
+ \fi
+ \open_out{\temp_prefix#2.mtx}
+ \edef\raw_font_name{#2}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\mtxtomtx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \ifisstr{etx-name}\then
+ \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}}
+ \def\declarepsencoding##1##2##3{
+ \a_toks={{##1}{##2}{##3}}
+ \out_line{\string\providepsencoding\the\a_toks}
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file
+ {\string\providepsencoding\the\a_toks}
+ \fi
+ }
+ \directfalse
+ \inputetx{\str{etx-name}}
+ \edef\a_macro{\a_macro\string\reencodefont{\str{etx-name}}}
+ \fi
+ \record_transform{#2}{\string\frommtx{#1}}{\a_macro}\iftrue
+ \out_line{}
+ \mtxtomtx_redefinitions
+ \inputmtx{#1}
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Transformed~metrics}
+}}
+\def\mtxtomtx_redefinitions{
+ \let\setint=\mtxtomtx_setint
+ \let\setdim=\mtxtomtx_setdim
+ \let\setstr=\mtxtomtx_setstr
+ \let\setscaledrawglyph=\mtxtomtx_setscaledrawglyph
+ \let\setscalednotglyph=\mtxtomtx_setscaledrawglyph
+ \let\setkern=\mtxtomtx_setkern
+ \let\setglyph=\mtxtomtx_setglyph
+ \let\glyphpcc=\mtxtomtx_glyphpcc
+ \let\samesize=\mtxtomtx_samesize
+ \let\endsetglyph=\mtxtomtx_endsetglyph
+ \def\aliased{\string\aliased}
+}
+\let\aliased=\second_of_two
+\def\mtxtomtx_setint#1#2{
+ \def\a_macro{#1}
+ \ifx \a_macro\italicslant_name
+ \eval_expr{#2}
+ \global\multiply \result \int{x-scale}
+ \a_count=\int{slant-scale}
+ \multiply \a_count \one_thousand
+ \advance \a_count \result
+ \divide \a_count \int{y-scale}\x_relax
+ \else
+ \def\do##1{
+ \def\b_macro{##1}
+ \ifx \a_macro\b_macro \expandafter\if_false \fi
+ }
+ \gobble_one\iftrue \width_ints_list \if_true
+ \eval_expr_to\a_count{\scale{#2}{\int{y-scale}}}
+ \else
+ \eval_expr_to\a_count{\scale{#2}{\int{x-scale}}}
+ \fi
+ \fi
+ \out_line{\string\setint{#1}{\the\a_count}}
+}
+\def\italicslant_name{italicslant}
+\def\width_ints_list{
+ \do{interword}\do{stretchword}\do{shrinkword}\do{quad}
+ \do{extraspace}\do{digitwidth}\do{verticalstem}
+}
+\def\mtxtomtx_setdim#1#2{
+ \out_line{\string\setdim{#1}{#2}}
+}
+\def\mtxtomtx_setstr#1#2{
+ \out_line{\string\setstr{#1}{#2}}
+}
+\def\mtxtomtx_setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \eval_expr_to\a_count{\scale{#6}{\int{x-scale}}}
+ \eval_expr_to\b_count{\scale{#7}{\int{y-scale}}}
+ \eval_expr_to\c_count{\scale{#8}{\int{y-scale}}}
+ \eval_expr_to\d_count{#9} \eval_expr{#7}
+ \multiply \d_count \int{x-scale}
+ \global\multiply \result \int{slant-scale}
+ \global\advance \result \d_count
+ \rounded_thousandths
+ \d_count=\result
+ \eval_expr{\scale{#4}{\int{y-scale}}}
+ \ifisstr{etx-name}\then
+ \bgroup
+ \let\aliased=\first_of_two
+ \if_undefined{slots-#1}\then
+ \egroup \e_count=\m@ne
+ \else
+ \expandafter\egroup \expandafter\e_count
+ \csname slots-#1\endcsname
+ \fi
+ \else
+ \e_count=#5
+ \fi
+ \out_line{
+ \ifnum \e_count>\m@ne
+ \string\setscaledrawglyph
+ \else
+ \string\setscalednotglyph
+ \fi
+ {#1}{\raw_font_name}{#3}{\the\result}{\the\e_count}
+ {\the\a_count}{\the\b_count}{\the\c_count}{\the\d_count}
+ }
+}
+\def\mtxtomtx_setkern#1#2#3{
+ \eval_expr{\scale{\int{x-scale}}{#3}}
+ \out_line{\string\setkern{#1}{#2}{\the\result}}
+}
+\def\mtxtomtx_setglyph#1{\out_line{\string\setglyph{#1}}}
+\def\mtxtomtx_samesize#1{\out_lline{\string\samesize{#1}}}
+\def\mtxtomtx_endsetglyph{\out_line{\string\endsetglyph}}
+\def\mtxtomtx_glyphpcc#1#2#3{
+ \eval_expr_to\b_count{\scale{\int{y-scale}}{#3}}
+ \eval_expr_to\a_count{#2} \eval_expr{#3}
+ \multiply \a_count \int{x-scale}
+ \global\multiply \result \int{slant-scale}
+ \global\advance \result \a_count
+ \rounded_thousandths
+ \out_lline{\string\glyphpcc{#1}{\the\result}{\the\b_count}}
+}
+\def\reglyphfonts{
+ \begingroup
+ \let\setsomething_global=\x_relax
+ \x_setint{renameweight}{1}
+ \x_setint{killweight}{-10}
+ \setcommand\iftokeep##1\then{\ifnum -1<##1}
+}
+\def\endreglyphfonts{\endgroup}
+\def\offmtxcommand#1{
+ \x_cs\offcommand{reglyph_\expandafter\gobble_one\string#1}
+}
+\def\onmtxcommand#1{
+ \x_cs\oncommand{reglyph_\expandafter\gobble_one\string#1}
+}
+\begingroup
+ \catcode`\-=11
+ \gdef\renameglyph#1#2{
+ \x_cs\edef{slots-#2}{
+ \noexpand\rename_glyph{#1}\noexpand\i-renameweight
+ }
+ }
+\endgroup
+\def\renameglyphweighted#1#2#3{
+ \eval_expr{#3}
+ \x_cs\edef{slots-#2}{\noexpand\rename_glyph{#1}{\the\result}}
+}
+\begingroup
+ \catcode`\-=11
+ \gdef\killglyph#1{
+ \x_cs\def{slots-#1}{\kill_glyph\i-killweight}
+ }
+\endgroup
+\def\killglyphweighted#1#2{
+ \eval_expr{#2}
+ \x_cs\edef{slots-#1}{\noexpand\kill_glyph{\the\result}}
+}
+\def\reglyphfont#1#2{
+ \fromany{#2}
+ \ifisstr{afm-name}\then
+ \reglyph_font{#1}{#2}
+ \else
+ \fontinsterror{Reglyph}{Could~not~find~font~metrics~for~#2.}
+ \error_help_a
+ \fi
+}
+\def\reglyph_font#1#2{{
+ \open_out{\temp_prefix#1.mtx}
+ \out_line{\percent_char~Filename:~#1.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\reglyphfont{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \record_transform{#1}{\string\frommtx{#2}}{\string\reglyphfont}
+ \iftrue
+ \out_line{}
+ \reglyph_redefinitions
+ \inputmtx{#2}
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Reglyphed~metrics}
+}}
+\def\reglyph_redefinitions{
+ \let\setint=\reglyph_setint
+ \let\setdim=\reglyph_setdim
+ \let\setstr=\reglyph_setstr
+ \let\setscaledrawglyph=\reglyph_setscaledrawglyph
+ \let\setscalednotglyph=\reglyph_setscaledrawglyph
+ \let\setkern=\reglyph_setkern
+ \let\setglyph=\reglyph_setglyph
+ \let\glyphpcc=\reglyph_glyphpcc
+ \let\samesize=\reglyph_samesize
+ \let\endsetglyph=\reglyph_endsetglyph
+}
+\def\reglyph_setint#1#2{\out_line{\string\setint{#1}{#2}}}
+\def\reglyph_setdim#1#2{\out_line{\string\setdim{#1}{#2}}}
+\def\reglyph_setstr#1#2{\out_line{\string\setstr{#1}{#2}}}
+\newcount\command_survivance
+\def\rename_glyph#1{\def\glyphname{#1}\kill_glyph}
+\def\kill_glyph#1{\advance \command_survivance #1\x_relax}
+\def\reglyph_setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{
+ \ifnum #5<\z@
+ \string\setscalednotglyph
+ \else
+ \string\setscaledrawglyph
+ \fi
+ {\glyphname}{#2}{#3}{\number#4}{#5}{#6}{#7}{#8}{#9}
+ }
+ \fi
+}
+\def\reglyph_setkern#1#2#3{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \let\a_macro=\glyphname
+ \def\glyphname{#2}
+ \csname slots-#2\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{\string\setkern{\a_macro}{\glyphname}{#3}}
+ \fi
+}
+\def\reglyph_setglyph#1{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_line{\string\setglyph{\glyphname}}}
+ \a_toks=\expandafter{\a_macro}
+}
+\x_cs\def{off-\string\reglyph_setglyph}#1{\gobble_glyph}
+\def\reglyph_glyphpcc#1#2#3{
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_lline{
+ \string\glyphpcc{\glyphname}{#2}{#3}
+ }}
+ \a_toks=\expandafter{\the\expandafter\a_toks \a_macro}
+}
+\def\reglyph_samesize#1{
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_lline{
+ \string\samesize{\glyphname}
+ }}
+ \a_toks=\expandafter{\the\expandafter\a_toks \a_macro}
+}
+\def\reglyph_endsetglyph{
+ \iftokeep\command_survivance\then
+ \the\a_toks
+ \out_line{\string\endsetglyph}
+ \fi
+ \a_toks={}
+}
+%%% From file: filtfam.dtx
+\def\latinfamily#1#2{{
+ \edef\a_macro{#1}
+ \expandafter\parse_family\a_macro
+ \empty_command\empty_command\end_parse_family
+ \installfonts
+ \if_file_exists{\raw_encoding.mtx}\then
+ \installfamily{\raw_encoding}{\latex_family}{#2}
+ \fi
+ \installfamily{OT1}{\latex_family}{#2}
+ \installfamily{T1}{\latex_family}{#2}
+ \installfamily{TS1}{\latex_family}{#2}
+ \latin_weights
+ \endinstallfonts
+}}
+\def\parse_family #1#2#3#4#5\end_parse_family{
+ \gdef\font_family{#1#2#3}
+ \gdef\font_variant{#4#5}
+ \gdef\raw_variant{#4#5}
+ \gdef\latex_family{#1#2#3#4#5}
+ \_expert_false
+ \_oldstyle_false
+ \ifx#4x
+ \_expert_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1}
+ \else\ifx#4j
+ \_expert_true
+ \_oldstyle_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1oldstyle}
+ \else\ifx#49
+ \gdef\latex_family{#1#2#3j#5}
+ \_expert_true
+ \_oldstyle_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1oldstyle}
+ \else
+ \_expert_false
+ \_oldstyle_false
+ %\setcommand\digit##1{##1}
+ \fi\fi\fi
+ \if_oldstyle_
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#5>~(oldstyle)}
+ \else\if_expert_
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#5>~(expert)}
+ \else
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#4#5>}
+ \fi\fi
+}
+\newif\if_expert_
+\newif\if_oldstyle_
+\def\latin_weight#1#2{
+ \gdef\font_weight{#1}%
+ \gdef\latex_weight{#2}%
+ \latin_widths
+}
+\def\latin_width#1#2{
+ \gdef\font_width{#1}
+ \gdef\latex_width{#2}
+ \latin_shapes
+}
+\def\latin_shape#1#2#3#4#5{
+ \gdef\font_shape{#1}
+ \gdef\raw_shape{#2}
+ \gdef\encoding_shape{#3}
+ \if_oldstyle_
+ \gdef\encoding_shape{#3\oldstyle_shape}
+ \fi
+ \gdef\latex_shape{#4}
+ \gdef\encoding_switches{#5}
+ \immediate\write16{
+ INFO>~to~make~LaTeX~font~shape~<\latex_family,
+ \latex_weight,\latex_shape,\latex_width>~seek~
+ \font_family\font_weight\raw_shape
+ \raw_variant\raw_encoding\font_width.mtx}
+ \csname fake_width_\font_width\endcsname
+ \csname fake_shape_\raw_shape\endcsname
+ \if_file_exists{
+ \font_family\font_weight\raw_shape
+ \raw_variant\raw_encoding\font_width.mtx
+ }\then
+ \latin_encodings
+ \fi
+}
+\def\fake_shape_{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_raw_encoding
+ \fi
+ \if_expert_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.afm
+ }\then
+ \fake_shape_expert_encoding
+ \fi
+ \fi
+}
+\def\fake_shape_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width>
+ }
+ \transformfont{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \reencodefont{\raw_encoding}{
+ \fromafm{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+}
+\def\fake_shape_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \fromafm{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width
+ }
+ \fi
+}
+\def\fake_shape_c{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_
+ \else
+ % If real smallcaps font doesn't exist, fake it from the roman.
+ \gdef\raw_shape{}
+ \if_oldstyle_
+ \gdef\encoding_shape{cj}
+ \else
+ \gdef\encoding_shape{c}
+ \fi
+ \fake_shape_
+ \fi
+}
+\def\fake_shape_o{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_
+ \else
+ \fake_shape_o_raw_encoding
+ \if_expert_
+ \fake_shape_o_expert_encoding
+ \fi
+ \fi
+}
+\def\fake_shape_o_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_variant
+ \raw_encoding\font_width>~(faking~oblique)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+ \fi
+}
+\def\fake_shape_o_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width>~from~
+ <\font_family\font_weight\raw_variant
+ \expert_encoding\font_width>~(faking~oblique)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ \space from~
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width
+ }
+ }
+ }
+ \fi
+ \fi
+}
+\let\fake_shape_i\fake_shape_ % We must do this again!
+\newif\if_fake_narrow_
+\_fake_narrow_false
+\def\fakenarrow#1{
+ \_fake_narrow_true
+ \gdef\fake_narrow_width{#1}
+}
+\def\fake_width_{}
+\def\fake_width_c{}
+\def\fake_width_n{
+ \if_fake_narrow_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then % no action required
+ \else
+ \fake_width_n_raw_encoding
+ \if_expert_
+ \fake_width_n_expert_encoding
+ \fi
+ \fi
+ \fi
+}
+\def\fake_width_n_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding>~(faking~narrow)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~narrow~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \xscalefont{\fake_narrow_width}{
+ \frommtx{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+ \fi
+}
+\def\fake_width_n_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width>~from~
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding>~(faking~narrow)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~narrow~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ \space from~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ }{
+ \xscalefont{\fake_narrow_width}{
+ \frommtx{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding
+ }
+ }
+ }
+ \fi
+ \fi
+}
+\def\latin_encoding#1#2#3#4#5{
+ \gdef\latex_encoding{#4}
+ \gdef\latex_mtx{#5}
+ \if_oldstyle_
+ \gdef\font_encoding{#3}
+ \else\if_expert_
+ \gdef\font_encoding{#2}
+ \else
+ \gdef\font_encoding{#1}
+ \fi\fi
+ \gdef\expert_font{}
+ \gdef\oldstyle_font{}
+ \if_expert_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then
+ \gdef\expert_font{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width,
+ }
+ \fi
+ \fi
+ \immediate\write16{
+ INFO>~run~\string\installfont\space
+ <\font_family\font_weight\font_shape\font_variant
+ \font_encoding\font_width>
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \if_oldstyle_
+ \ifx\raw_shape\caps_shape
+ resetosf,
+ \fi
+ \fi
+ \expert_font
+ \oldstyle_font
+ \latex_mtx>
+ <\latex_encoding\encoding_shape>
+ <\latex_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installfont{
+ \font_family\font_weight\font_shape\font_variant
+ \font_encoding\font_width
+ }{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \if_oldstyle_
+ \ifx\raw_shape\caps_shape
+ resetosf,
+ \fi
+ \fi
+ \expert_font
+ \oldstyle_font
+ \latex_mtx
+ }{
+ \latex_encoding\encoding_shape
+ }{
+ \latex_encoding
+ }{
+ \latex_family
+ }{
+ \latex_weight\latex_width
+ }{
+ \latex_shape
+ }{}
+}
+\def\latin_weights{
+ \latin_weight{r}{m}
+ \latin_weight{k}{m}
+ \latin_weight{b}{b}
+ \latin_weight{s}{sb}
+ \latin_weight{d}{db} % was {d}{sb}, SPQR changed
+ \latin_weight{m}{mb} % was {m}{m}, UV changed
+ \latin_weight{c}{eb} % UV added
+ \latin_weight{h}{eb} % UV added
+ \latin_weight{x}{eb}
+ \latin_weight{u}{ub}
+ \latin_weight{l}{l}
+ %\latin_weight{j}{el}
+ %\latin_weight{a}{ul} % UV added
+}
+\def\latin_widths{
+ \latin_width{}{}
+ \latin_width{n}{c}
+ %latin_width{c}{c}
+ %latin_width{x}{x}
+}
+\def\latin_shapes{
+ \latin_shape{} {} {} {n} {\_textcomp_true }
+ \latin_shape{c}{c}{} {sc}{\_textcomp_false}
+ \latin_shape{o}{o}{} {sl}{\_textcomp_true }
+ \latin_shape{i}{i}{i}{it}{\_textcomp_true }
+}
+\def\latin_encodings{
+ \latin_encoding{7t}{9t}{9o}{OT1}{newlatin}
+ \latin_encoding{8t}{9e}{9d}{T1} {newlatin}
+ \encoding_switches
+ \if_textcomp_
+ \latin_encoding{8c}{9c}{9c}{TS1}{textcomp}
+ \fi
+}
+\newif\if_textcomp_
+
+\def\raw_encoding{8r}
+\def\adobe_encoding{8a}
+\def\expert_encoding{8x}
+
+\def\caps_shape{c}
+\def\oldstyle_shape{j}
+\def\SlantAmount{167}
+%%% From file: fimapgen.dtx
+\def\mapfrags_subsystem{Map~fragments~writer}
+\def\recordtransforms#1{\open_pout\transform_record_file{#1}}
+\def\endrecordtransforms{
+ \close_pout\transform_record_file{Font~transformation~records}
+}
+\chardef\transform_record_file=\closed_stream
+\let\storemapdata=\gobble_three
+\def\record_transform#1#2#3#4{
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file{\string\storemapdata{#1}{#2}{#3}}
+ \fi
+ #4 \out_line{\string\storemapdata{#1}{#2}{#3}} \fi
+}
+\def\record_usage#1{
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file{\string\makemapentry{#1}}
+ \fi
+}
+\let\declarepsencoding=\gobble_three
+\let\providepsencoding=\gobble_three
+%%% From file: fibasics.dtx
+\def\needsfontinstversion#1{{
+ \a_dimen=#1pt
+ \b_dimen=\fontinstversion~pt\x_relax
+ \ifnum\a_dimen>\b_dimen
+ \immediate\write16{}
+ \immediate\write16{Warning:~This~file~needs~fontinst~version~#1.}
+ \immediate\write16{Warning:~You~are~using~version~
+ \fontinstversion.}
+ \immediate\write16{Warning:~This~may~cause~errors.}
+ \immediate\write16{}
+ \fi
+}}
+\if_file_exists{fontinst.rc}\then
+ \primitiveinput fontinst.rc
+\else
+ \immediate\write16{No~file~fontinst.rc.}
+\fi
+\normalcc
+\endinput
+%%
+%% End of file `fontinst.sty'.
diff --git a/fonts/utilities/fontinst/inputs/base/multislot.sty b/fonts/utilities/fontinst/inputs/base/multislot.sty
new file mode 100644
index 0000000000..fac7214405
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/base/multislot.sty
@@ -0,0 +1,234 @@
+% multislot.sty
+%
+% Second version
+
+
+\needsfontinstversion{1.900}
+% Relies heavily on _etx_pass_hook commands.
+
+
+%%%%%%%%%%%%%%% RESOURCES USED %%%%%%%%%%%%%%%
+%
+% The following classes of control sequences are used by the multislot
+% routines, in addition to the ones defined below and the ones fontinst
+% normally uses:
+%
+% \name-NUM
+%
+% where NUM is a number consisting of one, two, or three decimal digits.
+% These are also used by \pltomtx, so they probably already exist as
+% hash table entries.
+
+
+
+%%%%%%%%%%%%%%% SAVE CATCODES %%%%%%%%%%%%%%%
+%
+% Save the current values of the catcodes of space, @, NL, ~ and _.
+% _ and @ are made letters, ~ is a space, and space and NL are ignored.
+
+\edef\spacecatcode{\the\catcode`\ }
+\edef\atcatcode{\the\catcode`\@}
+\edef\nlcatcode{\the\catcode`\^^M}
+\edef\underscorecatcode{\the\catcode`\_}
+\edef\tildecatcode{\the\catcode`\~}
+
+\catcode`\ =9
+\catcode`\^^M=9
+\catcode`\@=11
+\catcode`\_=11
+\catcode`\~=10
+
+
+%%%%%%%%%%%%%%% MULTIPLE SLOT COMMANDS %%%%%%%%%%%%%%%
+%
+% The user-level commands are quite simple. As usual, you can write
+%
+% \setslot{NAME}
+% <slot commands>
+% \endsetslot
+%
+% to assign a glyph to a slot. The difference is that if there are
+% multiple \setslot commands for a slot, this will no longer cause
+% strange results. Instead, only the first \setslot-\endsetslot pair
+% for each slot will be used, the others are ignored.
+%
+% If you instead write
+%
+% \resetslot{NAME}
+% <slot commands>
+% \endsetslot
+%
+% then this will override any earlier occurences of \setslot or
+% \resetslot. Finally, there is the command
+%
+% \unsetslot{NUMBER}
+%
+% which makes fontinst forget any earlier occurences of \setslot
+% or \resetslot commands for that particular slot.
+
+
+% The way this works is that every \setslot or \resetslot command is
+% implicitly assigned an index, namely the number of such commands
+% perviously encountered since the start of the ETX pass. The count
+% register \slot_index is allocated to keep track of the current
+% index:
+
+\newcount\slot_index
+\def\clear_slot_index{\slot_index=\m@ne}
+\add_to\pre_first_etx_pass_hook{\clear_slot_index}
+\add_to\pre_second_etx_pass_hook{\clear_slot_index}
+\add_to\pre_third_etx_pass_hook{\clear_slot_index}
+\add_to\pre_fourth_etx_pass_hook{\clear_slot_index}
+
+% \setslot, \setleftboundary, and \setrightboundary increments the
+% counter just before checking it.
+
+
+
+% The point of maintaining the index is that the index of the
+% \setslot (or whatever) that actually sets a particular slot gets
+% stored in the \name-SLOT control sequence (which is \mathchardef'ed
+% to the index). After assignments are made, all a \setslot (or
+% whatever) needs to do is to check whether the stored index matches
+% the current one, and gobble itself if they don't.
+
+% The basic check is performed by the command \later_index_check.
+% This has the syntax
+%
+% \later_index_check{SLOT}{<else-code>}
+%
+% and expands to nothing if this \setslot will be active, but to
+% <else-code> if it will not.
+\def\later_index_check#1{
+ \x_cs\ifnum {name-#1}=\slot_index
+ \expandafter\gobble_one
+ \else
+ \expandafter\identity_one
+ \fi
+}
+% However, when deciding which \setslots will be active, the condition
+% to test is slightly different: is the control sequence in question
+% already defined to be a mathchar token? If it isn't, then this will
+% be the active \setslot.
+\def\setslot_index_check#1{\x_cs\setslot_index_check_i{name-#1}}
+\def\temp_command#1{
+ \def\setslot_index_check_ii##1#1##2\setslot_index_check_ii{##1}
+ \def\setslot_index_check_i##1{
+ \expandafter\setslot_index_check_ii \expandafter\ifx
+ \expandafter$ \meaning##1 #1 0 \setslot_index_check_ii $
+ \expandafter\identity_one
+ \else
+ \mathchardef##1=\slot_index
+ \expandafter\gobble_one
+ \fi
+ }
+}
+\expandafter\temp_command \expandafter{ \string\mathchar " }
+
+% The stated definition of \setslot_index_check should thus be in
+% force during the first etx pass, but after that the
+% \later_index_check definition should rule.
+\add_to\post_first_etx_pass_hook{
+ \let\setslot_index_check=\later_index_check
+}
+
+% The following is used to ignore a \setslot--\endsetslot or
+% \setleftboundary--\endsetleftboundary construction; the argument is
+% the command which marks the end. The reason not to use
+% \gobble_setslot is that it still executes \end_do_slot, which is
+% quite wrong for the kind of ignoring done here.
+\def\ignore_to_end#1{
+ \bgroup
+ \let#1=\fi
+ \expandafter
+ \egroup
+ \iffalse
+}
+
+
+% The \setslot, \setleftboundary, and \setrightboundary commands must
+% be equipped with checks at the start.
+\def\checked_setslot{
+ \advance \slot_index \@ne
+ \setslot_index_check{\the\slot_number}{
+ \advance \slot_number \@ne
+ \ignore_to_end\endsetslot
+ }
+ \unchecked_setslot
+}
+
+\def\checked_setleftboundary{
+ \advance \slot_index \@ne
+ \setslot_index_check{leftboundary}{\ignore_to_end\endsetleftboundary}
+ \unchecked_setleftboundary
+}
+
+\def\checked_setrightboundary#1{
+ \advance \slot_index \@ne
+ \setslot_index_check{\the\slot_number}{
+ \advance \slot_number \@ne
+ \gobble_two
+ }
+ \unchecked_setrightboundary{#1}
+}
+\add_to\pre_first_etx_pass_hook{
+ \let\unchecked_setslot=\setslot
+ \let\setslot=\checked_setslot
+ \let\unchecked_setleftboundary=\setleftboundary
+ \let\setleftboundary=\checked_setleftboundary
+ \let\unchecked_setrightboundary=\setrightboundary
+ \let\setrightboundary=\checked_setrightboundary
+}
+% But that's it, as far as the \set... commands are concerned.
+
+
+% What about \unsetslot? In principle, it _should_ just be a matter of
+\def\unsetslot#1{
+ \eval_expr{#1}
+ \x_cs\let{name-\the\result}\undefined_command
+}
+\add_to\post_first_etx_pass_hook{\let\unsetslot=\gobble_one}
+% given which \resetslot is simply
+\def\resetslot{\unsetslot\slot_number \setslot}
+% and this sort-of works, but not quite.
+%
+% The problem is that the ordinary slot assignment table, which is
+% used for ligature and kerning instructions, is not updated by
+% \unsetslot. Hence ligatures and kerns will be generated as if all
+% glyphs that have been set for a slot are present there; after
+%
+% \nextslot{108}
+% \setslot{l} \endsetslot
+%
+% \nextslot{108}
+% \resetslot{lambda} \endsetslot
+%
+% the effect will be as if one had given the command
+%
+% \setleftkerning{lambda}{l}{1000}
+%
+% and moreover the same happens for ligatures, so an f + l -> fl
+% ligature will also work as an f + lambda -> fl ligature.
+%
+% This is of course a BUG, and there doesn't seem to be any way
+% around it, short of adding another pass of reading ETX files. Doing
+% so would probably not be worth the effort, since the usefulness of
+% a \resetslot command is not clear; unlike \resetglyph, it cannot be
+% used to amend an existing \set..., but only to override it.
+
+
+
+%%%%%%%%%%%%%%% RESTORE CATCODES %%%%%%%%%%%%%%%
+%
+% Restore the catcodes that were changed.
+
+\catcode`\@=\atcatcode
+\catcode`\^^M=\nlcatcode
+\catcode`\ =\spacecatcode
+\catcode`\~=\tildecatcode
+\catcode`\_=\underscorecatcode
+
+%%%%%%%%%%%%%%% THE END %%%%%%%%%%%%%%%
+
+\endinput
+
diff --git a/fonts/utilities/fontinst/inputs/base/xfntinst.sty b/fonts/utilities/fontinst/inputs/base/xfntinst.sty
new file mode 100644
index 0000000000..d13e974623
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/base/xfntinst.sty
@@ -0,0 +1,3775 @@
+%%
+%% This is file `xfntinst.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% fibasics.dtx (with options: `pkg')
+%% ficommon.dtx (with options: `pkg')
+%% fimain.dtx (with options: `pkg')
+%% fitrig.dtx (with options: `pkg')
+%% ficonv.dtx (with options: `pkg')
+%% filtfam.dtx (with options: `pkg,textcomp,debug,oldstyle')
+%% fimapgen.dtx (with options: `pkg')
+%% fibasics.dtx (with options: `pkg2')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+%% maintenance team and any individual authors listed elsewhere in
+%% this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%%
+%%% From file: fibasics.dtx
+\catcode`\{=1
+\catcode`\}=2
+\catcode`\#=6
+\catcode`\^=7
+\def\fontinstversion{1.933}
+\ifx\ProvidesPackage\undefined
+ \def\NeedsTeXFormat#1{}
+ \def\ProvidesPackage#1[#2]{}
+\fi
+\ProvidesPackage{fontinst}
+[2007/01/23 v\fontinstversion\space
+ fontinst installation package]
+\def\a_macro#1{\catcode\number`#1=\the\catcode`#1 }
+\edef\normalcc{%
+ \a_macro{\ }\a_macro{\^^M}\a_macro{\@}\a_macro{\_}\a_macro{\~}
+}
+\def\fontinstcc{%
+ \catcode`\ =9%
+ \catcode`\^^M=9%
+ \catcode`\@=11%
+ \catcode`\_=11%
+ \catcode`\~=10
+}
+\fontinstcc
+\ifx\@ne\undefined_command
+ \input fontinst.ini\relax
+\fi
+\ifx\bye\undefined_command
+ \def\supereject{\par\penalty-\@MM}
+ \outer\expandafter\def \csname bye\endcsname
+ {\par\vfill\supereject\@@end}
+\fi
+\newcount\a_count
+\newcount\b_count
+\newcount\c_count
+\newcount\d_count
+\newcount\e_count
+\newcount\f_count
+\newcount\g_count
+\newdimen\a_dimen
+\newdimen\b_dimen
+\newdimen\c_dimen
+\newdimen\d_dimen
+\newtoks\a_toks
+\newtoks\b_toks
+\newtoks\c_toks
+\newif\if_a_
+\newwrite\out_file
+\mathchardef\one_thousand=1000
+\mathchardef\five_hundred=500
+\mathchardef\one_hundred=100
+\mathchardef\max_mathchardef="7FFF
+\mathchardef\two_thousand=2000
+\newdimen\half_point \half_point=0.5pt
+\def\x_cs#1#2{\expandafter#1\csname#2\endcsname}
+\let\x_relax=\relax
+\def\g_let{\global\let}
+\def\empty_command{}
+\def\gobble_one#1{}
+\def\gobble_two#1#2{}
+\def\gobble_three#1#2#3{}
+\def\identity_one#1{#1}
+\def\first_of_two#1#2{#1}
+\def\second_of_two#1#2{#2}
+\def\swap_two#1#2{#2#1}
+\def\first_of_three#1#2#3{#1}
+\bgroup
+ \catcode`\[=1
+ \catcode`\]=2
+ \catcode`\#=12
+ \catcode`\%=12
+ \catcode`\{=12
+ \catcode`\}=12
+ \gdef\hash_char[#]
+ \gdef\percent_char[%]
+ \gdef\left_brace_char[{]
+ \gdef\right_brace_char[}]
+\egroup
+\def\first_char#1#2={#1}
+\def\add_to#1#2{
+ \ifx#1\x_relax
+ \def#1{#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{#1#2}
+ \fi
+}
+\def\prep_to#1#2{
+ \ifx#1\x_relax
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2#1}
+ \fi
+}
+\def\never_do{\noexpand\do}
+\newif\if_extensions_warning_
+\_extensions_warning_false
+\ifx \eTeXversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\eTeX#1{
+ \if_extensions_warning_
+ \space/\space e-TeX\space version\space #1
+~ \else
+~ \ifdim \number\eTeXversion\eTeXrevision\p@ < #1\p@ \else
+~ \_a_true
+~ \fi
+ \fi
+}
+\catcode`\~=10
+\ifx \pdftexversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\pdfTeX#1#2{%
+ \if_extensions_warning_
+ \space/\space pdfTeX\space version\space
+ \ifnum #1<100\space
+ 0.\ifnum #1<10\space 0\fi
+ \else
+ \expandafter\swap_two \expandafter.
+ \fi
+ #1#2%
+~ \else
+~ \ifdim #1>\pdftexversion \else
+~ \ifnum \expandafter\expandafter \expandafter`
+~ \expandafter\first_char \pdftexrevision= <
+~ \expandafter` \first_char#2=
+~ \else \_a_true \fi
+~ \fi
+ \fi
+}
+\catcode`\~=10
+\def\needsTeXextension#1#2{
+ \_a_false
+ #1
+ \if_a_ \else
+ \_extensions_warning_true
+ \edef\a_macro{#1}
+ \_extensions_warning_false
+ \fontinstwarningnoline{#2}{
+ This~file~needs:\messagebreak
+ \expandafter\second_of_two\a_macro
+ \iffalse
+ <no~sufficient~extensions~were~listed!!>\if_false
+ \fi
+ \messagebreak
+ You~are~not~using~any~of~them.~This~is~likely~to~cause~errors
+ }
+ \fi
+}
+\def\open_out#1{
+ \immediate\openout\out_file=#1 \xdef\out_filename{#1}}
+\def\close_out#1{
+ \immediate\write16{#1~written~on~\out_filename.}
+ \immediate\closeout\out_file}
+\def\out_line#1{\immediate\write\out_file{#1}}
+\edef\out_lline#1{\noexpand\out_line{\space\space\space#1}}
+\edef\out_llline#1{
+ \noexpand\out_line{\space\space\space\space\space\space#1}
+}
+\def\TeX_terminal{\string\TeX\space terminal}
+\chardef\closed_stream=99
+\x_cs\let{out_filename-99}=\TeX_terminal
+\x_cs\def{out_filename--1}{\jobname.log}
+\def\allocate_stream{
+ \a_count=\m@ne
+ \b_count=\m@ne
+ \loop \ifnum \count17>\a_count
+ \advance \a_count \@ne
+ \x_cs\ifx{out_filename-\the\a_count}\TeX_terminal
+ \b_count=\a_count
+ \a_count=\count17
+ \fi
+ \repeat
+ \ifnum \b_count=\m@ne
+ \global\advance\count17by\@ne
+ \ifnum \count17<\sixt@@n
+ \b_count=\count17
+ \global\x_cs\let{out_filename-\the\b_count}\TeX_terminal
+ \wlog{\string\write\the\b_count\space allocated~to~the~pool.}
+ \else
+ \global\count17=\sixt@@n
+ \fi
+ \fi
+}
+\def\ch@ck#1#2#3{
+ \ifnum \count1#1<#2 \else
+ \errmessage{No~room~for~a~new~#3}
+ \global\count1#1=#2
+ \fi
+}
+\def\open_pout#1#2{
+ \allocate_stream
+ \ifnum \b_count=\m@ne
+ \immediate\write\sixt@@n{fontinst~is~out~of~output~streams.^^J
+ Output~file~#2~cannot~be~opened.^^J
+ Writes~will~be~redirected~to~the~log~file.
+ }
+ \gdef#1{\m@ne}
+ \else
+ \immediate\openout\b_count=#2\x_relax
+ \x_cs\xdef{out_filename-\the\b_count}{#2}
+ \global\chardef#1=\b_count
+ \fi
+}
+\def\close_pout#1#2{
+ \ifnum #1=\closed_stream
+ \errmessage{Output~file~\string#1~(#2)~not~closed,^^J
+ since~it~was~not~open}
+ \else
+ \immediate\write\sixt@@n{#2~written~on~
+ \csname out_filename-\the#1\endcsname.}
+ \ifnum #1=\m@ne \else
+ \immediate\closeout#1
+ \global\x_cs\let{out_filename-\the#1}=\TeX_terminal
+ \fi
+ \global\chardef#1=\closed_stream
+ \fi
+}
+\def\pout_line#1#2{\immediate\write#1{#2}}
+\edef\pout_lline#1#2{\noexpand\pout_line#1{\space\space\space#2}}
+\edef\pout_llline#1#2{
+ \noexpand\pout_line#1{\space\space\space\space\space\space#2}
+}
+\def\tempfileprefix#1{\def\temp_prefix{#1}}
+\tempfileprefix{}
+\let\then=\iffalse
+\def\if_false{\iffalse}
+\def\if_true{\iftrue}
+\_a_false\eTeX{2.0}
+\if_a_\else \catcode`\~=14\x_relax \fi
+~ \def\if_defined#1\then{
+~ \if
+~ \ifcsname#1\endcsname
+~ \expandafter\ifx \csname#1\endcsname \x_relax
+~ 0
+~ \else
+~ 1
+~ \fi
+~ \else
+~ 0
+~ \fi
+~ 1
+~ }
+~ \def\if_undefined{\expandafter\unless\if_defined}
+\catcode`\~=\if_a_ 14 \else 10 \fi \x_relax
+~ \def\if_defined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ \expandafter\if_false
+~ \else
+~ \expandafter\if_true
+~ \fi
+~ }
+~ \def\if_undefined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ }
+\catcode`\~=10\x_relax
+\def\gobble_if{\iftrue\else}
+\def\if_or#1\or_else#2\then{
+ #1\then
+ \expandafter\if_true
+ \else
+ #2\then
+ \expandafter\expandafter\expandafter\if_true
+ \else
+ \expandafter\expandafter\expandafter\if_false
+ \fi
+ \fi
+}
+\def\if_equal#1\then{\ifx#1}
+\def\if_file_exists#1\then{
+ \immediate\openin1=#1\x_relax
+ \ifeof1\x_relax
+ \immediate\closein1
+ \expandafter\if_false
+ \else
+ \immediate\closein1
+ \expandafter\if_true
+ \fi
+}
+\let\Else=\else
+\let\Fi=\fi
+\x_cs\ifx{@@input}\x_relax
+ \let\primitiveinput=\input
+\else
+ \let\primitiveinput=\@@input
+\fi
+\def\process_csep_list#1#2,{
+ \ifx\process_csep_list#2
+ \expandafter\gobble_one
+ \else
+ \expandafter\identity_one
+ \fi{
+ #1{#2}
+ \process_csep_list{#1}
+ }
+}
+\def\make_factor#1{
+ \ifnum #1<\z@
+ -\expandafter\make_factor_i\expandafter{\number-#1}
+ \else
+ \expandafter\make_factor_i\expandafter{\number#1}
+ \fi
+}
+\def\make_factor_i#1{
+ \ifnum #1<\one_thousand
+ \make_factor_ii{#1}
+ \else
+ \make_factor_iii #1
+ \fi
+ #1
+}
+\def\make_factor_ii#1{
+ 0.
+ \ifnum #1<\one_hundred
+ 0
+ \ifnum #1<10~ 0\fi
+ \fi
+}
+\def\make_factor_iii#1#2#3\fi#4{
+ \fi
+ #4
+ \ifnum 1#3<\one_thousand
+ .
+ \else
+ \make_factor_iii#2#3
+ \fi
+}
+{
+ \catcode`\p=12
+ \catcode`\t=12
+ \gdef\lose_measure#1pt{#1}
+}
+\def\format_hex_i#1#2{
+ \if #2i \else
+ \b_count=\a_count
+ \divide \a_count \sixt@@n
+ \c_count=\a_count
+ \multiply \c_count \sixt@@n
+ \advance \b_count -\c_count
+ \edef#1{
+ \ifcase\b_count 0\or 1\or 2\or 3\or 4\or 5\or 6\or 7\or 8\or
+ 9\or a\or b\or c\or d\or e\or f\fi
+ #1
+ }
+ \expandafter\format_hex_i \expandafter#1
+ \fi
+}
+\def\format_hex#1#2#3{
+ \a_count=#2
+ \let#1\empty_command
+ \expandafter\format_hex_i \expandafter#1 \romannumeral
+ \expandafter\identity_one\expandafter{\number#3}001~
+}
+\let\messagebreak\x_relax
+\def\generic_info#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\m@ne{#2\on_line.}
+ \endgroup
+}
+\def\generic_warning#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\closed_stream{^^J#2\on_line.^^J}
+ \endgroup
+}
+\def\generic_error#1#2#3#4{
+ \begingroup
+ \immediate\write\closed_stream{}
+ \def\messagebreak{^^J}
+ \edef\a_macro{{#4}}
+ \errhelp\a_macro
+ \def\messagebreak{^^J#1}
+ \errmessage{#2.^^J^^J#3
+ Type~\space H~<return>~\space for~immediate~help
+ }
+ \endgroup
+}
+\def\fontinsterror#1#2#3{
+ \generic_error{
+ \four_spaces\four_spaces
+ }{
+ #1~error:\messagebreak #2
+ }{
+ }{#3}
+}
+\def\fontinstwarning#1#2{
+ \generic_warning{
+ \four_spaces\four_spaces
+ }{
+ #1~warning:\messagebreak #2
+ }
+}
+\def\fontinstwarningnoline#1#2{
+ \fontinstwarning{#1}{#2\gobble_one}
+}
+\def\fontinstinfo#1#2{
+ \generic_info{
+ \four_spaces\four_spaces
+ }{
+ #1~info:\messagebreak #2
+ }
+}
+\def\on_line{~on~input~line~\the\inputlineno}
+\edef\four_spaces{\space\space\space\space}
+\gdef\error_help_a{
+ Your~command~was~ignored.\messagebreak
+ Type~\space I~<command>~<return>~\space to~replace~it~
+ with~another~command,\messagebreak
+ or~\space <return>~\space to~continue~without~it.}
+\gdef\error_help_c{
+ Try~typing~\space <return>~
+ \space to~proceed.\messagebreak
+ If~that~doesn't~work,~type~\space X~<return>~\space to~quit.}
+\gdef\error_help_d{
+ You're~in~trouble~here.~\space\error_help_c}
+\def\error_help_e#1{You~can~continue,~but~the~#1~wrong.}
+\newlinechar=`\^^J
+\errorcontextlines=999
+\tracinglostchars=1
+%%% From file: ficommon.dtx
+\def\str#1{\csname~s-#1\endcsname}
+\def\strint#1{\expandafter\identity_one\expandafter{\number\int{#1}}}
+\newcount\result
+\def\eval_expr#1{\global\result=#1\x_relax}
+\def\eval_expr_to#1#2{\eval_expr{#2}#1=\result}
+\def\g_eval_expr_to#1#2{\eval_expr{#2}\global#1=\result}
+\def\add#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\advance \result \a_count
+ \egroup
+}
+\def\sub#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \advance \a_count -\result
+ \global\result=\a_count
+ \egroup
+}
+\def\int#1{\csname i-#1 \endcsname}
+\def\neg#1{#1 \global\result=-\result}
+\def\mul#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \egroup
+}
+\def\div#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \divide \a_count \result
+ \global\result=\a_count
+ \egroup
+}
+\def\max#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count>\result \global\result=\a_count \fi
+ \egroup
+}
+\def\min#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count<\result \global\result=\a_count \fi
+ \egroup
+}
+\def\half#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\otherhalf#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \else \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\scale#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \rounded_thousandths
+ \egroup
+}
+\def\rounded_thousandths{
+ \global\divide \result \five_hundred
+ \ifodd \result
+ \global\advance \result by \ifnum 0>\result - \fi 1
+ \fi
+ \global\divide \result \tw@
+}
+\def\l_rounded_thousandths#1{
+ \divide #1 \five_hundred
+ \ifodd #1
+ \advance #1 by \ifnum 0>#1 - \fi\@ne
+ \fi
+ \divide #1 \tw@
+}
+\def\l_inv_scale#1#2{
+ \multiply #1 \two_thousand
+ \divide #1 #2\x_relax
+ \ifodd#1 \advance #1 \ifnum 0>#1 - \fi\@ne \fi
+ \divide #1 \tw@
+}
+\def\ifnumber#1#2#3\then{
+ \eval_expr_to\a_count{#1}
+ \eval_expr{#3}
+ \ifnum \a_count#2\result
+ \expandafter\if_true
+ \else
+ \expandafter\if_false
+ \fi
+}
+\let\setsomething_global=\x_relax
+\def\x_setint#1#2{
+ \x_cs\ifx{i-#1}\x_relax
+ \x_resetint{#1}{#2}
+ \fi
+}
+\let\setint=\x_setint
+\def\x_setstr#1#2{
+ \x_cs\ifx{s-#1}\x_relax
+ \setsomething_global\x_cs\edef{s-#1}{#2}
+ \fi
+}
+\let\setstr=\x_setstr
+\def\setdim#1#2{
+ \x_cs\ifx{d-#1}\x_relax
+ \a_dimen=#2\x_relax
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+ \fi
+}
+\def\setcommand#1{
+ \ifx#1\undefined_command
+ \setsomething_global \expandafter\def \expandafter#1
+ \else
+ \expandafter\def \expandafter\a_macro
+ \fi
+}
+\def\x_resetint#1#2{
+ \eval_expr{#2}
+ \setsomething_global
+ \ifnum\result<\max_mathchardef
+ \ifnum 0>\result
+ \x_cs\edef{i-#1}{\the\result}
+ \else
+ \x_cs\mathchardef{i-#1}=\result
+ \fi
+ \else
+ \x_cs\edef{i-#1}{\the\result}
+ \fi
+}
+\let\resetint=\x_resetint
+\def\resetstr#1#2{\setsomething_global\x_cs\edef{s-#1}{#2}}
+\def\resetdim#1#2{
+ \a_dimen=#2
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+}
+\def\resetcommand#1{\setsomething_global\def#1}
+\def\dim#1{\csname~d-#1\endcsname}
+\def\ifisint#1\then{\if_defined i-#1\then}
+\def\ifisstr#1\then{\if_defined s-#1\then}
+\def\ifisdim#1\then{\if_defined d-#1\then}
+\def\ifiscommand#1\then{
+ \ifx#1\undefined_command
+ \expandafter\if_false
+ \else
+ \expandafter\if_true
+ \fi
+}
+\def\unsetint#1{\setsomething_global\x_cs\let{i-#1}\x_relax}
+\def\unsetstr#1{\setsomething_global\x_cs\let{s-#1}\x_relax}
+\def\unsetdim#1{\setsomething_global\x_cs\let{d-#1}\x_relax}
+\def\unsetcommand#1{\setsomething_global\let#1=\undefined_command}
+\def\offcommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax
+ \setsomething_global\x_cs\let{saved-\string#1}#1
+ \x_cs\ifx{off-\string#1}\x_relax
+ \generate_off_command{#1}
+ \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname off-\string#1\endcsname
+ \fi
+ \fi
+}
+\def\oncommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname saved-\string#1\endcsname
+ \setsomething_global\x_cs\let{saved-\string#1}\x_relax
+ \fi
+}
+\def\generate_off_command#1{
+ \a_count=0
+ \let\next=\count_hashes
+ \expandafter\next\meaning#1~->\x_relax
+ \b_count=0
+ \a_toks={}
+ \loop \ifnum \b_count<\a_count
+ \advance \b_count 1
+ \a_toks=\expandafter{\the\expandafter\a_toks \expandafter####
+ \the\b_count}
+ \repeat
+ \setsomething_global \expandafter\def \expandafter#1 \the\a_toks {}
+}
+\def\count_hashes#1#2{
+ \if \hash_char#1
+ \advance \a_count 1
+ \else
+ \if -#1
+ \if >#2
+ \let\next=\gobble_to_xrelax
+ \fi\fi
+ \fi
+ \next#2
+}
+\def\gobble_to_xrelax#1\x_relax{}
+\def\for(#1)#2#3#4{
+ \eval_expr_to\a_count{#2}
+ \x_resetint{#1}{\a_count}
+ \eval_expr{#4}
+ \ifnum 0=\result \else
+ \c_count=\result
+ \eval_expr_to\b_count{#3}
+ \setsomething_global\x_cs\edef{for-#1}{
+ \the\c_count \x_relax
+ \noexpand\ifnum \gobble_one\fi
+ \the\b_count \ifnum 0>\c_count > \else < \fi
+ }
+ \def\next##1##2##3\endfor(#1){##2\for_i{##1}{##3}}
+ \next{#1}
+ \fi
+}
+\def\for_i#1#2{
+ \setsomething_global\x_cs\def{body-#1}{#2}
+ \ifnum \b_count \ifnum0>\c_count >\else<\fi \a_count
+ \expandafter\gobble_two
+ \else
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+\def\for_ii#1{
+ \a_count=\int{#1}
+ \advance \a_count \csname for-#1\endcsname \a_count
+ \expandafter\gobble_two
+ \else
+ \x_resetint{#1}\a_count
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+\def\endfor(#1){}
+\def\foreach(#1)#2{
+ \def\next##1\endfor(#1){
+ \setsomething_global\x_cs\def{body-#1}{##1}
+ \process_csep_list{\foreach_i{#1}}#2,\process_csep_list,
+ }
+ \next
+}
+\def\foreach_i#1#2{
+ \resetstr{#1}{#2}
+ \csname body-#1\endcsname
+}
+\let\comment=\gobble_one
+\let\begincomment=\iffalse
+\let\endcomment=\fi
+%%% From file: fimain.dtx
+\def\inputetx#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \slot_number=0
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\encoding=\fi
+ \primitiveinput \lowercase_file.etx\x_relax
+ \let\relax=\x_relax
+}
+\let\encoding=\relax
+\outer\def\endencoding{\endinput}
+\def\setslot#1{\edef\slot_name{#1}\do_slot}
+\def\endsetslot{\end_do_slot\advance\slot_number by 1\x_relax}
+\let\do_slot\empty_command
+\let\end_do_slot\empty_command
+\newcount\slot_number
+\def\nextslot#1{\eval_expr_to\slot_number{#1}}
+\def\skipslots#1{\eval_expr{#1} \advance\slot_number by \result}
+\def\setleftboundary#1{\edef\slot_name{#1}\do_boundary}
+\let\endsetleftboundary\x_relax
+\let\do_boundary\x_relax
+\def\setrightboundary#1{
+ \makerightboundary{#1}
+ \advance \slot_number 1\x_relax
+}
+\let\ligature=\gobble_three
+\def\Ligature{\ligature}
+\def\oddligature#1#2#3#4{}
+\let\nextlarger=\gobble_one
+\let\usedas=\gobble_two
+\let\makerightboundary=\gobble_one
+\let\Unicode=\gobble_two
+\let\charseq=\gobble_one
+\let\varchar=\empty_command
+\let\vartop=\gobble_one
+\let\varmid=\gobble_one
+\let\varbot=\gobble_one
+\let\varrep=\gobble_one
+\let\endvarchar=\empty_command
+\let\useexamplefont=\gobble_one
+\let\slotexample=\empty_command
+\let\setslotcomment=\gobble_one
+\let\resetslotcomment=\gobble_one
+\let\unsetslotcomment=\empty_command
+\def\setfontdimen#1#2{
+ \ifisint{#2}\then \setint{fontdimen(#1)}{\int{#2}} \fi
+}
+\let\label=\gobble_one
+\newif\ifdirect \directtrue
+\def\input_mtx_as_etx#1{
+ \def\setscaledrawglyph##1##2##3##4##5##6##7##8##9{
+ \nextslot{##5}
+ \setslot{##1}\endsetslot
+ }
+ \offcommand\setscalednotglyph
+ \let\setglyph=\gobble_glyph
+ \offcommand\setkern
+ \inputmtx{#1}
+}
+\def\inputmtx#1{
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\metrics=\fi
+ \primitiveinput #1.mtx\x_relax
+ \let\relax=\x_relax
+}
+\let\metrics=\x_relax
+\edef\endmetrics_text{\string\endmetrics}
+\outer\def\endmetrics{\endinput}
+\def\ProvidesMtxPackage#1{\x_cs\let{pack-#1}P}
+\def\usemtxpackage{\futurelet\next_token\test_UseMtxPkg_arguments}
+\def\test_UseMtxPkg_arguments{\ifx\next_token[
+ \expandafter\mtx_package_given_file
+ \else
+ \expandafter\mtx_package_separate_files
+ \fi
+}
+\def\mtx_package_given_file[#1]#2{
+ \_a_false
+ \process_csep_list\load_true_unless_loaded #2,\process_csep_list,
+ \if_a_ \inputmtx{#1} \fi
+}
+\def\load_true_unless_loaded#1{
+ \x_cs\ifx{pack-#1}P\else\_a_true\fi
+}
+\def\mtx_package_separate_files#1{
+ \process_csep_list\load_file_unless_loaded #1,\process_csep_list,
+}
+\def\load_file_unless_loaded#1{
+ \x_cs\ifx{pack-#1}P\else \inputmtx{#1} \fi
+}
+\let\glyph_name_modifier=\identity_one
+\def\setkern#1#2#3{
+ \x_cs\ifx{i-rawscale}\x_relax
+ \expandafter\set_kern
+ \csname~r-\glyph_name_modifier{#1}\expandafter\endcsname
+ \csname~l-\glyph_name_modifier{#2}\endcsname
+ {#3}
+ \else
+ \expandafter\set_kern
+ \csname~r-\glyph_name_modifier{#1}\expandafter\endcsname
+ \csname~l-\glyph_name_modifier{#2}\endcsname
+ {\scale{#3}{\int{rawscale}}}
+ \fi
+}
+\def\set_kern#1#2#3{
+ \eval_expr{#3}
+ \expandafter\set_kern_cs\csname\the\result\endcsname#1#2
+}
+\def\set_kern_cs#1#2#3{
+ \add_to#2{\k#3#1}
+ \add_to#3{\k#2#1}
+}
+\def\resetkern#1#2#3{
+ \x_cs\ifx{i-rawscale}\x_relax
+ \expandafter\reset_kern
+ \csname~r-#1\expandafter\endcsname
+ \csname~l-#2\endcsname{#3}
+ \else
+ \expandafter\reset_kern
+ \csname~r-#1\expandafter\endcsname
+ \csname~l-#2\endcsname{\scale{#3}{\int{rawscale}}}
+ \fi
+}
+\def\reset_kern#1#2#3{
+ \eval_expr{#3}
+ \expandafter\reset_kern_cs\csname\the\result\endcsname#1#2
+}
+\def\reset_kern_cs#1#2#3{
+ \prep_to#2{\k\expandafter#3\expandafter#1}
+ \prep_to#3{\k\expandafter#2\expandafter#1}
+}
+\def\setleftkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~l-#1\expandafter\endcsname
+ \csname~l-#2\endcsname
+}
+\def\setrightkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~r-#1\expandafter\endcsname
+ \csname~r-#2\endcsname
+}
+\def\setleftrightkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~l-#1\expandafter\endcsname
+ \csname~l-#2\endcsname
+ \expandafter\set_kerning
+ \csname~r-#1\expandafter\endcsname
+ \csname~r-#2\endcsname
+}
+\def\set_kerning#1#2{
+ \if\b_count=\one_thousand
+ \def\k##1##2{
+ \set_kern_cs##2##1#1
+ }
+ \else
+ \def\k##1##2{
+ \set_kern##1#1{
+ \scale\b_count{\expandafter\gobble_one\string##2}
+ }
+ }
+ \fi
+ #2
+}
+\def\kerning#1#2{0\x_relax
+ \def\k##1{\csname~set-\string##1\endcsname\gobble_one}
+ \bgroup
+ \x_cs\def{set-\string\l-#2}##1##2{
+ \global\result=\expandafter\gobble_one\string##2\egroup
+ }
+ \csname~r-#1\endcsname
+ \csname~set-\string\l-#2\endcsname\gobble_one{00}
+}
+\def\ifiskern#1#2\then{
+ \def\k##1##2{\ifx T##1 \let\k\gobble_two \fi}
+ \bgroup
+ \x_cs\let{l-#2}T
+ \csname r-#1\endcsname
+ \expandafter\egroup \ifx\k\gobble_two
+}
+\def\unsetkerns#1#2{
+ \let\k\k_unless_to_U
+ \process_csep_list\make_slots_U#1,\process_csep_list,
+ \def\do##1{\x_cs\main_remove_Us{l-##1}}
+ \process_csep_list\do#2,\process_csep_list,
+ \process_csep_list\make_slots_relax#1,\process_csep_list,
+ \process_csep_list\make_slots_U#2,\process_csep_list,
+ \def\do##1{\x_cs\main_remove_Us{r-##1}}
+ \process_csep_list\do#1,\process_csep_list,
+ \process_csep_list\make_slots_relax#2,\process_csep_list,
+}
+\def\make_slots_U#1{\x_cs\let{slots-#1}U}
+\def\make_slots_relax#1{\x_cs\let{slots-#1}\x_relax}
+\def\k_unless_to_U#1#2{
+ \x_cs\ifx{slots-\expandafter\gobble_three\string#1}U \else
+ \noexpand\k\noexpand#1\noexpand#2
+ \fi
+}
+\def\main_remove_Us#1{
+ \ifx#1\x_relax \else
+ \edef#1{#1}
+ \ifx#1\empty_command \let#1\x_relax \fi
+ \fi
+}
+\def\noleftkerning#1{\no_kerning{l}{#1}}
+\def\norightkerning#1{\no_kerning{r}{#1}}
+\def\noleftrightkerning#1{\no_kerning{l}{#1}\no_kerning{r}{#1}}
+\def\no_kerning#1#2{
+ \let\k\no_kerning_i
+ \def\do##1{\csname #1-##1\endcsname}
+ \bgroup
+ \aftergroup\def \aftergroup\a_macro \aftergroup{
+ \process_csep_list\do #2,\process_csep_list,
+ \aftergroup}
+ \egroup
+ \def\do##1{\expandafter\let \csname #1-##1\endcsname \x_relax}
+ \process_csep_list\do #2,\process_csep_list,
+ \let\k\no_kerning_ii
+ \def\do##1{\edef##1{##1}}
+ \a_macro
+}
+\def\no_kerning_i#1#2{
+ \ifx #1\x_relax \else
+ \aftergroup\do \aftergroup#1
+ \let #1\x_relax
+ \fi
+}
+\def\no_kerning_ii#1#2{
+ \ifx #1\x_relax \else \noexpand\k \noexpand#1 \noexpand#2 \fi
+}
+\def\width{\glyph_parameter\first_of_six}
+\def\height{\glyph_parameter\second_of_six}
+\def\depth{\glyph_parameter\third_of_six}
+\def\italic{\glyph_parameter\fourth_of_six}
+\def\mapcommands{\glyph_parameter\fifth_of_six}
+\def\mapfonts{\glyph_parameter\sixth_of_six}
+\def\glyph_parameter#1#2{
+ \expandafter\expandafter\expandafter
+ #1\csname g-#2\endcsname
+}
+\def\first_of_six#1#2#3#4#5#6{#1}
+\def\second_of_six#1#2#3#4#5#6{#2}
+\def\third_of_six#1#2#3#4#5#6{#3}
+\def\fourth_of_six#1#2#3#4#5#6{#4}
+\def\fifth_of_six#1#2#3#4#5#6{#5}
+\def\sixth_of_six#1#2#3#4#5#6{#6}
+\def\glyph_metrics#1#2#3#4#5#6{
+ \a_count=#1
+ \b_count=#2
+ \c_count=#3
+ \d_count=#4~
+}
+\let\saved_scale\x_relax
+\let\saved_mapfont\x_relax
+\let\saved_raw\x_relax
+\let\saved_rule\x_relax
+\let\saved_special\x_relax
+\let\saved_warning\x_relax
+\let\saved_movert\x_relax
+\let\saved_moveup\x_relax
+\let\saved_push\x_relax
+\let\saved_pop\x_relax
+\newcount\glyph_width
+\newcount\glyph_height
+\newcount\glyph_depth
+\newcount\glyph_italic
+\newtoks\glyph_map_commands
+\newtoks\glyph_map_fonts
+\newcount\glyph_voffset
+\newcount\glyph_maxhpos
+\def\setglyph#1{
+ \ifisglyph{\glyph_name_modifier{#1}}\then
+ \expandafter\gobble_glyph
+ \else
+ \x_cs\def{g-\glyph_name_modifier{#1}}{
+ {\the\glyph_width}{\the\glyph_height}
+ {\the\glyph_depth}{\the\glyph_italic}
+ {\the\glyph_map_commands}{\the\glyph_map_fonts}
+ }
+ \resetglyph{\glyph_name_modifier{#1}}
+ \fi
+}
+\long\def\gobble_glyph#1\endsetglyph{}
+\def\resetglyph#1{
+ \edef\glyphname{#1}
+ \glyph_width=0
+ \global\glyph_height=0
+ \global\glyph_depth=0
+ \global\glyph_italic=0
+ \glyph_voffset=0
+ \global\glyph_maxhpos=0
+ \global\glyph_map_commands={}
+ \global\glyph_map_fonts={}
+}
+\def\endsetglyph{
+ \x_cs\edef{g-\glyphname}
+ {{\the\glyph_width}{\the\glyph_height}
+ {\the\glyph_depth}{\the\glyph_italic}
+ {\the\glyph_map_commands}{\the\glyph_map_fonts}}
+}
+\let\endresetglyph=\endsetglyph
+\def\setrawglyph#1#2#3{
+ \setscaledrawglyph{#1}{#2}{#3}\one_thousand
+}
+\def\setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \if_undefined{g-\glyph_name_modifier{#1}}\then
+ \eval_expr{#4}
+ \ifnum \result=\one_thousand
+ \let\a_macro\identity_one
+ \else
+ \edef\a_macro##1{\saved_scale{\the\result}{##1}}
+ \fi
+ \eval_expr_to\a_count{#6}
+ \eval_expr_to\b_count{#7}
+ \eval_expr_to\c_count{#8}
+ \eval_expr_to\d_count{#9}
+ \ifisint{rawscale}\then
+ \e_count=\int{rawscale}
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \edef\a_macro##1{\saved_scale{\the\e_count}{\a_macro{##1}}}
+ \fi
+ \x_cs\edef{g-\glyph_name_modifier{#1}}{
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {\a_macro{\saved_raw{#2}{#5}{#1}}}
+ {\a_macro{\saved_mapfont{#2}{#3}}}
+ }
+ \fi
+}
+\def\setnotglyph#1#2#3{
+ \setscalednotglyph{#1}{#2}{#3}\one_thousand
+}
+\def\setscalednotglyph#1#2#3#4#5#6#7#8#9{
+ \if_undefined{g-\glyph_name_modifier{#1}-not}\then
+ \eval_expr_to\a_count{#6}
+ \eval_expr_to\b_count{#7}
+ \eval_expr_to\c_count{#8}
+ \eval_expr_to\d_count{#9}
+ \ifisint{rawscale}\then
+ \e_count=\int{rawscale}
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \fi
+ \x_cs\edef{g-\glyph_name_modifier{#1}-not}{
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {}{}
+ }
+ \fi
+}
+\def\unsetglyph#1{\x_cs\let{g-#1}\x_relax}
+\def\glyph#1#2{
+ \glyph_parameter\glyph_metrics{#1}
+ \eval_expr_to\e_count{#2}
+ \ifnum \e_count=\one_thousand
+ \edef\a_macro{\mapcommands{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \edef\a_macro{\mapfonts{#1}}
+ \else
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \edef\a_macro{\saved_scale{\the\e_count}{\mapcommands{#1}}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \edef\a_macro{\saved_scale{\the\e_count}{\mapfonts{#1}}}
+ \fi
+ \advance \glyph_width \a_count
+ \advance \b_count \glyph_voffset
+ \ifnum \glyph_height<\b_count \global\glyph_height=\b_count \fi
+ \advance \c_count -\glyph_voffset
+ \ifnum \glyph_depth<\c_count \global\glyph_depth=\c_count \fi
+ \global\glyph_italic=\d_count
+ \global\glyph_map_fonts\expandafter{
+ \the\expandafter\glyph_map_fonts \a_macro
+ }
+}
+\def\glyphrule#1#2{
+ \eval_expr_to\b_count{#1} \eval_expr_to\c_count{#2}
+ \advance\glyph_width by \b_count
+ \g_eval_expr_to\glyph_depth{\max\glyph_depth{-\glyph_voffset}}
+ \g_eval_expr_to\glyph_height{
+ \max\glyph_height{\add\glyph_voffset\c_count}
+ }
+ \global\glyph_italic=0
+ \edef\a_macro{\saved_rule{\the\b_count}{\the\c_count}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\glyphspecial#1{
+ \edef\a_macro{\saved_special{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\glyphwarning#1{
+ \edef\a_macro{\saved_warning{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\movert#1{
+ \eval_expr{#1}
+ \ifnum \glyph_maxhpos<\glyph_width
+ \global\glyph_maxhpos\glyph_width
+ \fi
+ \ifnum 0=\result \else
+ \advance\glyph_width by \result
+ \edef\a_macro{\saved_movert{\the\result}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \fi
+}
+\def\moveup#1{
+ \eval_expr{#1}
+ \ifnum\result=0\else
+ \advance\glyph_voffset by \result
+ \edef\a_macro{\saved_moveup{\the\result}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \fi
+}
+\def\push{
+ \bgroup
+ \global\glyph_map_commands\expandafter{
+ \the\glyph_map_commands \saved_push
+ }
+}
+\def\pop{
+ \ifnum \glyph_maxhpos<\glyph_width
+ \global\glyph_maxhpos\glyph_width
+ \fi
+ \egroup
+ \global\glyph_map_commands\expandafter{
+ \the\glyph_map_commands \saved_pop
+ }
+}
+\def\resetwidth#1{\movert{\sub{#1}\glyph_width}}
+\def\resetheight{\g_eval_expr_to\glyph_height}
+\def\resetdepth{\g_eval_expr_to\glyph_depth}
+\def\resetitalic{\g_eval_expr_to\glyph_italic}
+\def\glyphpcc#1#2#3{
+ \ifisglyph{\glyph_name_modifier{#1}}\then
+ \push
+ \movert{#2}
+ \moveup{#3}
+ \glyph{\glyph_name_modifier{#1}}{\one_thousand}
+ \pop
+ \else\ifisglyph{\glyph_name_modifier{#1}-not}\then
+ \fontinstwarning{\string\glyphpcc}{
+ Base~glyph~`\glyph_name_modifier{#1}'~not~appended,\messagebreak
+ because~it~is~so~far~unencoded~in~the~glyph~base
+ }
+ \else
+ \fontinsterror{\string\glyphpcc}{
+ Base~glyph~not~set.\messagebreak
+ This~could~be~a~sign~that~the~AFM~file~is~buggy
+ }\error_help_a
+ \fi\fi
+}
+\def\glyphbboxright{\max\glyph_width\glyph_maxhpos}
+\def\samesize#1{
+ \if_undefined{g-\glyph_name_modifier{#1}}\then
+ \resetwidth{\glyphbboxright}
+ \else
+ \expandafter\expandafter\expandafter
+ \same_size\csname g-\glyph_name_modifier{#1}\endcsname
+ \fi
+}
+\def\same_size#1#2#3#4#5#6{
+ \movert{\sub{#1}\glyph_width}
+ \global\glyph_height=#2
+ \global\glyph_depth=#3
+ \global\glyph_italic=#4
+}
+\def\ifisglyph#1\then{\if_defined{g-#1}\then}
+\def\ifareglyphs#1\then{
+ \process_csep_list{\if_is_glyph}#1,\process_csep_list,
+ \if_true
+}
+\def\if_is_glyph#1{
+ \if_undefined{g-#1}\then \expandafter\if_false \fi
+}
+\def\etxtovpl#1#2{{
+ \def\vpl_extension{vpl}
+ \def\vpl_title{COMMENT}
+ \def\vpl_font{virtual~font}
+ \def\vpl_Font{Virtual~font}
+ \def\vpl_call{\string\etxtovpl{#1}{#2}}
+ \def\vpl_to_vf##1{vptovf~##1.vpl~##1.vf~##1.tfm}
+ \a_toks={}
+ \process_csep_list\make_inputetx #1,\process_csep_list,
+ \expandafter\etx_to_font \expandafter{\the\a_toks}{#2}
+}}
+\def\etxtopl#1#2{{
+ \def\vpl_extension{pl}
+ \def\vpl_title{COMMENT}
+ \def\vpl_font{font}
+ \def\vpl_Font{Font}
+ \def\vpl_call{\string\etxtopl{#1}{#2}}
+ \def\vpl_to_vf##1{pltotf~##1.pl~##1.tfm}
+ \_including_map_false
+ \global\rawfont_scaling=-\p@
+ \a_toks={}
+ \process_csep_list\make_inputetx #1,\process_csep_list,
+ \expandafter\etx_to_font \expandafter{\the\a_toks}{#2}
+}}
+\newif\if_including_map_
+\_including_map_true
+\def\make_inputetx#1{
+ \def\a_macro{\noexpand\inputetx{\file_name}}
+ \get_file_name #1~{}~\par
+ \edef\a_macro{\a_macro}
+ \a_toks=\expandafter{ \the\expandafter\a_toks \a_macro}
+}
+\x_cs\def{IFKW-mtxasetx}{
+ \def\a_macro{\noexpand\input_mtx_as_etx{\file_name}}
+ \get_keyword
+}
+\def\etx_to_font#1#2{
+ \make_assignments{#1}
+ \open_out{#2.\vpl_extension}
+ \top_of_pl_hook
+ \out_line{(\vpl_title\space\vpl_font\space
+ #2~created~by~fontinst~v\fontinstversion)}
+ \out_line{}
+ \out_line{(COMMENT~Filename:~#2.\vpl_extension)}
+ \out_line{(COMMENT~Created~by:~tex~\jobname)}
+ \out_line{(COMMENT~Created~using:~\vpl_call)}
+ \out_line{}
+ \out_line{(COMMENT~This~file~can~be~turned~into~a~\vpl_font\space
+ with)}
+ \out_line{(COMMENT~\vpl_to_vf{#2})}
+ \out_line{}
+ \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)}
+ \out_line{}
+ \make_header{#1}
+ \if_including_map_ \make_mapfonts{#1} \fi
+ \make_fontdimens{#1}
+ \make_ligtable{#1}
+ \make_characters{#1}
+ \make_tidy{#1}
+ \out_line{}
+ \out_line{(COMMENT~END~OF~FILE~#2.\vpl_extension)}
+ \close_out{\vpl_Font}
+}
+\let\pre_first_etx_pass_hook\x_relax
+\let\pre_second_etx_pass_hook\x_relax
+\let\pre_third_etx_pass_hook\x_relax
+\let\pre_fourth_etx_pass_hook\x_relax
+\let\post_first_etx_pass_hook\x_relax
+\let\post_second_etx_pass_hook\x_relax
+\let\post_third_etx_pass_hook\x_relax
+\let\post_fourth_etx_pass_hook\x_relax
+\let\tidying_up_hook\x_relax
+\let\top_of_pl_hook\x_relax
+\def\make_assignments#1{
+ \let\do_slot=\assign_slot
+ \let\end_do_slot=\end_assign_slot
+ \def\do_boundary{\bgroup
+ \let\makerightboundary=\bad_makerightboundary
+ }
+ \let\endsetleftboundary=\egroup
+ \let\makerightboundary=\assign_rboundary
+ \pre_first_etx_pass_hook
+ #1
+ \post_first_etx_pass_hook
+ \let\end_do_slot=\empty_command
+ \let\do_boundary=\x_relax
+ \let\endsetleftboundary=\x_relax
+ \let\makerightboundary=\gobble_one
+}
+\def\assign_slot{\a_toks={\do}}
+\begingroup
+ \catcode0=12
+ \gdef\end_assign_slot{
+ \ifisglyph\slot_name\then
+ \lccode0=\slot_number
+ \lowercase{
+ \expandafter\add_to
+ \csname slots-\slot_name\expandafter\endcsname
+ \expandafter{\the\a_toks^^@}
+ }
+ \fi
+ }
+ \gdef\assign_rboundary#1{
+ \lccode0=\slot_number
+ \lowercase{\x_cs\add_to{slots-#1}{\rboundary_do^^@}}
+ \x_setint{\percent_char boundarychar}\slot_number
+ \a_toks={\rbserver_do}
+ }
+\endgroup
+\def\bad_makerightboundary#1{
+ \errhelp={The~left~boundary~is~not~a~slot,~so~it~cannot~serve~
+ as~right~boundary.}
+ \errmessage{Incorrect~use~of~\string\makerightboundary}
+}
+\def\get_slot_num#1{
+ \global\result=-1
+ \bgroup
+ \def\do{\global\result=`}
+ \let\rbserver_do=\do
+ \let\rboundary_do=\gobble_one
+ \csname slots-#1\endcsname
+ \egroup
+}
+\def\ifisinslot#1#2\then{
+ \ifx \makerightboundary\gobble_one
+ \eval_expr{#2}
+ \begingroup
+ \def\do##1{\ifnum `##1=\result \let\do=\gobble_one \fi}
+ \def\rbserver_do{\do}
+ \let\rboundary_do=\gobble_one
+ \csname slots-#1\endcsname
+ \expandafter\endgroup
+ \ifx \do\gobble_one
+ \expandafter\expandafter \expandafter\if_true
+ \else
+ \expandafter\expandafter \expandafter\if_false
+ \fi
+ \else
+ \expandafter\gobble_if
+ \fi
+}
+\newdimen\mapfont_scaling
+\mapfont_scaling=1pt
+\newdimen\rawfont_scaling
+\def\vpl_real#1{R~\expandafter\lose_measure\the#1}
+\def\vpl_int#1{D~\the#1}
+\newdimen\side_bearings
+\newdimen\curr_bearings
+\def\make_header#1{
+ \global\font_count=0
+ \setdim{designsize}{10pt}
+ \a_dimen=\dim{designsize}
+ \out_line{(DESIGNSIZE~\vpl_real\a_dimen)}
+ \x_setstr{codingscheme}{UNKNOWN}
+ \out_line{(CODINGSCHEME~\str{codingscheme})}
+ \ifisint{\percent_char boundarychar}\then
+ \a_count=\int{\percent_char boundarychar}
+ \out_line{(BOUNDARYCHAR~\vpl_int\a_count)}
+ \fi
+ \x_setint{letterspacing}{0}
+ \side_bearings=\make_factor{\int{letterspacing}}\half_point
+ \x_setint{minimumkern}{0}
+ \minimum_kern=\int{minimumkern}
+ \out_line{}
+}
+\def\make_mapfonts#1{
+ \let\saved_scale\vpl_scale
+ \let\saved_mapfont\vpl_mapfont
+ \let\do_slot=\do_mapfont
+ \pre_second_etx_pass_hook
+ #1
+ \post_second_etx_pass_hook
+ \out_line{}
+}
+\def\do_mapfont{
+ \ifisglyph\slot_name\then
+ \mapfonts\slot_name
+ \fi
+}
+\def\vpl_scale#1#2{{
+ \mapfont_scaling=\make_factor{#1}\mapfont_scaling
+ #2
+}}
+\def\vpl_mapfont#1#2{
+ \a_dimen=#2
+ \if_undefined{\the\mapfont_scaling-#1}\then
+ \global\x_cs\mathchardef{\the\mapfont_scaling-#1}=\font_count
+ \x_cs\xdef{f-\the\font_count}{\the\mapfont_scaling-#1}
+ \out_line{(MAPFONT~\vpl_int\font_count\space
+ (FONTNAME~#1)~
+ (FONTDSIZE~\vpl_real\a_dimen)~
+ (FONTAT~\vpl_real\mapfont_scaling))}
+ \record_usage{#1}
+ \global\advance\font_count by 1
+ \fi
+}
+\def\pl_mapfont#1#2{\global\rawfont_scaling=\mapfont_scaling}
+\newcount\font_count
+\newcount\next_mapfont
+\newcount\prev_mapfont
+\def\make_fontdimens#1{
+ \out_line{(FONTDIMEN}
+ \a_count=1
+ \loop\ifnum 256>\a_count
+ \ifisint{fontdimen(\the\a_count)}\then
+ \out_lline{(PARAMETER~\vpl_int\a_count\space
+ R~\make_factor{\int{fontdimen(\the\a_count)}})}
+ \fi
+ \advance \a_count \@ne
+ \repeat
+ \out_lline{)}
+ \out_line{}
+}
+\def\make_ligtable#1{
+ \begingroup
+ \out_line{(LIGTABLE}
+ \let\do_slot=\bgroup
+ \let\end_do_slot=\vpl_kerning
+ \def\do_boundary{\bgroup \let\vpl_liglabel=\boundary_liglabel}
+ \let\endsetleftboundary=\vpl_kerning
+ \let\ligature=\vpl_ligature
+ \let\k=\vpl_kern
+ \let\rbserver_do=\vpl_rbserver_do
+ \let\rboundary_do=\vpl_rboundary_do
+ \pre_third_etx_pass_hook
+ #1
+ \post_third_etx_pass_hook
+ \out_lline{)}
+ \endgroup
+ \out_line{}
+}
+\def\vpl_rbserver_do#1{
+ \do{#1}
+ \let\rboundary_do=\wrn_rboundary_do
+}
+\def\vpl_rboundary_do#1{
+ \do{#1}
+ \let\rbserver_do=\wrn_rboundary_do
+}
+\def\wrn_rboundary_do#1{
+ \do{#1}
+ \immediate\write16{Boundarychar~slot~usage~collision~in~
+ `\slot_name'~ligkern~program.}
+}
+\def\vpl_ligature#1#2#3{
+ \get_slot_num{#3}
+ \ifnum -1=\result
+ \immediate\write16{Warning:~\string\ligature\space
+ for~unknown~slot~`#3'.}
+ \else
+ \x_cs\ifx{slots-#2}\x_relax
+ \immediate\write16{Warning:~\string\ligature\space
+ for~unknown~slot~`#2'.}
+ \else
+ \def\do##1{
+ \vpl_liglabel
+ \out_lline{(#1~D~\number`##1~\space\vpl_int\result)~
+ (COMMENT~#2~#3)}
+ }
+ \csname slots-#2\endcsname
+ \fi
+ \fi
+}
+\def\vpl_kerning{
+ \let\do=\vpl_kern_do
+ \csname~r-\slot_name\endcsname
+ \vpl_ligstop
+ \egroup
+}
+\def\vpl_kern#1#2{
+ \edef\a_macro{\expandafter\gobble_three\string#1}
+ \a_count=\expandafter\gobble_one\string#2\x_relax
+ \ifnum \ifnum -\a_count>\a_count - \fi\a_count>\minimum_kern
+ \edef\b_macro{~R~\make_factor\a_count}
+ \csname slots-\a_macro\endcsname
+ \fi
+ \x_cs\let{slots-\a_macro}=\x_relax
+}
+\def\vpl_kern_do#1{
+ \vpl_liglabel
+ \out_lline{
+ (KRN~D~\number`#1~\b_macro)~
+ (COMMENT~\a_macro)
+ }
+}
+\def\out_liglabel{
+ \out_lline{(LABEL~\vpl_int\slot_number)~(COMMENT~\slot_name)}
+ \let\vpl_liglabel=\x_relax
+ \let\vpl_ligstop=\out_ligstop
+}
+\def\boundary_liglabel{
+ \out_lline{(LABEL~BOUNDARYCHAR)~(COMMENT~\slot_name)}
+ \let\vpl_liglabel=\x_relax
+ \let\vpl_ligstop=\out_ligstop
+}
+\let\vpl_liglabel=\out_liglabel
+\def\out_ligstop{\out_lline{(STOP)}
+ \let\vpl_liglabel=\out_liglabel
+ \let\vpl_ligstop=\x_relax}
+\let\vpl_ligstop=\x_relax
+\def\make_characters#1{
+ \bgroup
+ \let\do_slot=\do_character
+ \let\end_do_slot=\end_do_character
+ \let\nextlarger=\vpl_nextlarger
+ \let\varchar=\vpl_varchar
+ \let\endvarchar=\end_vpl_varchar
+ \let\vartop=\vpl_vartop
+ \let\varmid=\vpl_varmid
+ \let\varbot=\vpl_varbot
+ \let\varrep=\vpl_varrep
+ \if_including_map_
+ \let\saved_raw\vpl_raw
+ \let\saved_rule\vpl_rule
+ \let\saved_special\vpl_special
+ \let\saved_warning\vpl_warning
+ \let\saved_movert\vpl_movert
+ \let\saved_moveup\vpl_moveup
+ \let\saved_push\vpl_push
+ \let\saved_pop\vpl_pop
+ \else
+ \def\do_character_map{
+ \ifdim \rawfont_scaling=-\p@
+ \mapfonts\slot_name
+ \else
+ \let\do_character_map=\x_relax
+ \fi
+ }
+ \let\saved_mapfont\pl_mapfont
+ \let\saved_scale\vpl_scale
+ \fi
+ \pre_fourth_etx_pass_hook
+ #1
+ \post_fourth_etx_pass_hook
+ \egroup
+}
+\def\do_character{
+ \if_undefined{g-\slot_name}\then
+ \ifisint{requireglyphs}\then
+ \fontinstwarning{ETX~to~(V)PL}{
+ Undefined~glyph~`\slot_name'~requested\message_break
+ for~slot~\the\slot_number\message_number}
+ \fi
+ \expandafter\gobble_setslot
+ \else
+ \ifx\slot_name\notdef_name\else
+ \out_line{(CHARACTER~\vpl_int\slot_number\space
+ (COMMENT~\slot_name)}
+ \glyph_parameter\glyph_metrics\slot_name
+ \a_dimen=\make_factor\a_count \p@
+ \do_character_sidebearings
+ \out_lline{(CHARWD~\vpl_real\a_dimen)}
+ \ifnum \z@=\b_count \else
+ \out_lline{(CHARHT~R~\make_factor\b_count)}
+ \fi
+ \ifnum \z@=\c_count \else
+ \out_lline{(CHARDP~R~\make_factor\c_count)}
+ \fi
+ \ifnum \z@=\d_count \else
+ \out_lline{(CHARIC~R~\make_factor\d_count)}
+ \fi
+ \do_character_map
+ \fi
+ \fi
+}
+\def\do_character_sidebearings{
+ \ifisint{\slot_name-spacing}\then
+ \curr_bearings=\make_factor{\int{\slot_name-spacing}}\half_point
+ \else
+ \curr_bearings=\side_bearings
+ \fi
+ \advance\a_dimen by 2\curr_bearings
+}
+\def\do_character_map{
+ \global\prev_mapfont=0
+ \out_lline{(MAP}
+ \ifdim 0pt=\curr_bearings
+ \mapcommands\slot_name
+ \else
+ \out_llline{(MOVERIGHT~\vpl_real\curr_bearings)}
+ \mapcommands\slot_name
+ \out_llline{(MOVERIGHT~\vpl_real\curr_bearings)}
+ \fi
+ \out_llline{)}
+}
+\long\def\gobble_setslot#1\endsetslot{\endsetslot}
+\def\end_do_character{
+ \ifisglyph\slot_name\then
+ \out_lline{)}
+ \fi
+}
+\def\notdef_name{.notdef}
+\def\vpl_nextlarger#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_lline{(NEXTLARGER~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\nextlarger\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varchar{\out_lline{(VARCHAR}}
+\def\end_vpl_varchar{\out_llline{)}}
+\def\vpl_vartop#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(TOP~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\vartop\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varmid#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(MID~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varmid\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varbot#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(BOT~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varbot\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_varrep#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(REP~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varrep\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+\def\vpl_raw#1#2#3{
+ \global\next_mapfont=\csname\the\mapfont_scaling-#1\endcsname
+ \ifnum \next_mapfont=\prev_mapfont \else
+ \out_llline{(SELECTFONT~\vpl_int\next_mapfont)~
+ (COMMENT~#1~at~
+ \expandafter\lose_measure \the\mapfont_scaling)}
+ \fi
+ \out_llline{(SETCHAR~D~#2)~(COMMENT~#3)}
+ \global\prev_mapfont=\next_mapfont
+}
+\def\vpl_rule#1#2{
+ \a_dimen=\make_factor{#2}\mapfont_scaling
+ \b_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(SETRULE~\vpl_real\a_dimen\space\vpl_real\b_dimen)}
+}
+\def\vpl_special#1{
+ \out_llline{(SPECIAL~#1)}}
+\def\vpl_warning#1{
+ \ifwarningspecials
+ \out_llline{(SPECIAL~Warning:~#1)}
+ \fi
+ \immediate\write16{Warning:~#1.}
+}
+\newif\ifwarningspecials
+\warningspecialstrue
+\def\vpl_movert#1{
+ \a_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(MOVERIGHT~\vpl_real\a_dimen)}
+}
+\def\vpl_moveup#1{
+ \a_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(MOVEUP~\vpl_real\a_dimen)}
+}
+\def\vpl_push{\out_llline{(PUSH)}}
+\def\vpl_pop{\out_llline{(POP)}}
+\def\make_tidy#1{
+ \tidying_up_hook
+ \if_including_map_
+ \a_count=0
+ \loop\ifnum \a_count<\font_count
+ \edef\a_macro{\csname~f-\the\a_count\endcsname}
+ \global\x_cs\let\a_macro\x_relax
+ \advance\a_count by 1
+ \repeat
+ \global\font_count=0
+ \else
+ \ifdim \rawfont_scaling<\z@
+ \fontinstwarning{ETX~to~(V)PL}{The~font~
+ \out_filename\space doesn't~contain~any~characters}
+ \global\rawfont_scaling=\p@
+ \fi
+ \ifdim \rawfont_scaling=\p@ \else
+ \out_line{(DESIGNUNITS~\vpl_real\rawfont_scaling)}
+ \fi
+ \fi
+}
+\newtoks\family_toks
+\def\installfonts{
+ \bgroup
+ \global\family_toks={}
+ \gdef\prev_file_list{}
+ \global\let\setsomething_global=\global
+}
+\def\installfamily#1#2#3{
+ \global\family_toks=
+ \expandafter{\the\family_toks\fd_family{#1}{#2}{#3}}
+ \global\x_cs\let{#1-#2}\empty_command
+}
+\def\installfont#1#2#3#4#5#6#7#8{
+ \global\let\setsomething_global=\x_relax
+ \input_metrics{}{#2}
+ \etxtovpl{#3}{#1}
+ \installfontas{#1}{#4}{#5}{#6}{#7}{#8}
+ \global\let\setsomething_global=\global
+}
+\def\installrawfont#1#2#3#4#5#6#7#8{
+ \global\let\setsomething_global=\x_relax
+ \xdef\out_filename{#1}
+ \input_metrics{\let\storemapdata=\installraw_storemap}{#2}
+ \let\storemapdata=\gobble_three
+ \etxtopl{#3}{#1}
+ \record_usage{#1}
+ \installfontas{
+ \ifdim \rawfont_scaling=\p@ \else
+ [\expandafter\lose_measure\the\rawfont_scaling]~
+ \fi #1
+ }{#4}{#5}{#6}{#7}{#8}
+ \global\let\setsomething_global=\global
+}
+\def\installraw_storemap#1#2#3{
+ \def\a_macro{#1}
+ \ifx \a_macro\out_filename \else
+ \record_transform{\out_filename}{\string\frommtx{#1}}{}\if_false
+ \fi
+}
+\def\input_metrics#1#2{
+ \let\metrics=\file_list_metrics
+ \xdef\curr_file_list{#2,}
+ \let\metrics=\x_relax
+ \ifx\prev_file_list\curr_file_list\else
+ \egroup\bgroup
+ #1
+ \expandafter\process_csep_list \expandafter\input_mtx_file
+ \curr_file_list\process_csep_list,
+ \global\let\prev_file_list=\curr_file_list
+ \fi
+}
+\def\file_list_metrics#1,{
+ \iffalse{\fi}
+ \a_toks=\expandafter{\curr_file_list\x_relax#1,}
+ \xdef\curr_file_list{\the\a_toks \iffalse}\fi
+}
+\def\installfontas#1#2#3#4#5#6{
+ \if_undefined{#2-#3-#4-#5}\then
+ \let\do_shape=\x_relax
+ \if_undefined{#2-#3}\then
+ \x_cs\let{#2-#3}\empty_command
+ \autoinstallfamily{#2}{#3}
+ \fi
+ \x_cs\xdef{#2-#3}{
+ \csname#2-#3\endcsname
+ \do_shape{#2}{#3}{#4}{#5}
+ }
+ \fi
+ \let\do_size=\x_relax
+ \x_cs\xdef{#2-#3-#4-#5}{
+ \if_defined{#2-#3-#4-#5}\then
+ \csname#2-#3-#4-#5\endcsname
+ \fi
+ \do_size{#6}{#1}
+ }
+}
+\def\autoinstallfamily#1#2{\installfamily{#1}{#2}{}}
+\def\endinstallfonts{
+ \global\let\setsomething_global=\x_relax
+ \let\do_shape=\fd_shape
+ \let\do_size=\fd_size
+ \the\family_toks
+ \global\family_toks{}
+ \egroup
+}
+\def\input_mtx_file#1{
+ \reset_modifiers_hook
+ \ifx\x_relax#1\x_relax
+ \else
+ \identity_one{\get_file_name #1~}~\par
+ \ifx \pl_encoding\empty_command
+ \fromany\file_name
+ \else
+ \metrics_given_encoding{\file_name}{\pl_encoding}
+ \fi
+ \ifisstr{afm-name}\then
+ \inputmtx{\str{afm-name}}
+ \else
+ \fontinsterror{\string\install...}{
+ Font/MTX~file~\file_name\space not~found
+ }{
+ You~can~insert~an~\string\inputmtx\space command~here
+ \messagebreak to~input~some~other~MTX~file~instead.
+ \ifisint{rawscale}\then \messagebreak
+ The~requested~raw~scaling~will~then~be~applied~on~that.
+ \fi
+ }
+ \fi
+ \fi
+}
+\def\metrics_given_encoding#1#2{
+ \x_cs\edef{s-afm-name}{#1-#2}
+ \if_file_exists{#1.pl}\then
+ \generalpltomtx{#1}{#1-#2}{pl}{#2}
+ \else
+ \if_file_exists{#1.vpl}\then
+ \generalpltomtx{#1}{#1-#2}{vpl}{#2}
+ \else
+ \unsetstr{afm-name}
+ \fi\fi
+}
+\def\reset_modifiers_hook{
+ \unsetint{rawscale}
+ \let\glyph_name_modifier\identity_one
+ \let\pl_encoding\empty_command
+ \let\list_of_options\empty_command
+}
+\def\get_file_name #1~{
+ \edef\file_name{#1}
+ \get_keyword
+}
+\def\get_keyword #1~{
+ \if_defined{IFKW-#1}\then
+ \csname IFKW-#1 \expandafter\endcsname
+ \else
+ \fontinsterror{\string\install...}{
+ `#1'~is~not~a~defined~keyword
+ }{
+ \error_help_a\messagebreak
+ Extra~tokens~will~be~flushed.
+ }
+ \expandafter\gobble_keywords
+ \fi
+}
+\def\gobble_keywords#1\par{}
+\x_cs\let{IFKW-}=\gobble_keywords
+\x_cs\def{IFKW-scaled}#1~{
+ \ifnum #1=\one_thousand
+ \unsetint{rawscale}
+ \else
+ \x_resetint{rawscale}{#1}
+ \fi
+ \get_keyword
+}
+\x_cs\def{IFKW-suffix}#1~{
+ \def\glyph_name_modifier##1{##1#1}
+ \get_keyword
+}
+\x_cs\def{IFKW-encoding}#1~{
+ \def\pl_encoding{#1}
+ \get_keyword
+}
+\let\pl_encoding=\empty_command
+\x_cs\def{IFKW-option}#1~{
+ \add_to\list_of_options{\do{#1}}
+}
+\def\ifoption#1\then{
+ \_a_false
+ \edef\a_macro{#1}
+ \def\do##1{
+ \if_a_ \else
+ \def\b_macro{##1}
+ \ifx \a_macro\b_macro \_a_true \fi
+ \fi
+ }
+ \list_of_options
+ \if_a_
+}
+\let\list_of_options\empty_command
+\def\fd_family#1#2#3{
+ \a_toks{#3}
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1#2.fd}}}
+ \lowercase_file
+ \open_out{\lowercase_file}
+ \out_line{\percent_char~Filename:~\lowercase_file}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using~fontinst~v\fontinstversion}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~SHOULD~BE~PUT~IN~A~TEX~INPUTS~
+ DIRECTORY}
+ \out_line{}
+ \out_line{\string\ProvidesFile{\lowercase_file}}
+ \out_lline{[
+ \the\year/
+ \ifnum10>\month0\fi\the\month/
+ \ifnum10>\day0\fi\the\day\space
+ Fontinst~v\fontinstversion\space
+ font~definitions~for~#1/#2.
+ ]}
+ \out_line{}
+ \out_line{\string\DeclareFontFamily{#1}{#2}{\the\a_toks}}
+ {
+ \csname #1-#2\endcsname
+ \out_line{}
+ \let\do_shape=\substitute_shape
+ \csname #1-#2\endcsname
+ \let\do_shape=\remove_shape
+ \csname #1-#2\endcsname
+ }
+ \x_cs\g_let{#1-#2}\x_relax
+ \out_line{}
+ \out_line{\string\endinput}
+ \close_out{Font~definitions}
+}
+\def\fd_shape#1#2#3#4{
+ \out_line{}
+ \out_line{\string\DeclareFontShape{#1}{#2}{#3}{#4}\left_brace_char}
+ \csname #1-#2-#3-#4\endcsname
+ \x_cs\g_let{#1-#2-#3-#4}\empty_command
+ \out_line{\right_brace_char{}}
+}
+\def\fd_size#1#2{
+ \x_cs\ifx{siz-#1}\x_relax
+ \out_lline{#1~#2}
+ \else
+ \out_lline{\csname siz-#1\endcsname\space #2}
+ \fi
+}
+\def\remove_shape#1#2#3#4{
+ \x_cs\g_let{#1-#2-#3-#4}\x_relax
+}
+\def\substitute_shape#1#2#3#4{
+ \edef\orig_shape{#4}
+ \substitute_series{#1}{#2}{#3}{\orig_shape}
+ \x_cs\ifx{sub-\orig_shape}\x_relax\else
+ \edef\subst_shape{\csname sub-\orig_shape\endcsname}
+ \x_cs\ifx{#1-#2-#3-\subst_shape}\x_relax
+ \out_line{
+ \string\DeclareFontShape{#1}{#2}{#3}{\subst_shape}{
+ <->\csname typ-\orig_shape\endcsname\space
+ *~#2/#3/\orig_shape
+ }{}
+ }
+ \x_cs\let{#1-#2-#3-\subst_shape}\empty_command
+ \substitute_shape{#1}{#2}{#3}{\subst_shape}
+ \fi
+ \fi
+}
+\def\substitute_series#1#2#3#4{
+ \edef\orig_series{#3}
+ \x_cs\ifx{sub-\orig_series}\x_relax\else
+ \edef\subst_series{\csname sub-\orig_series\endcsname}
+ \x_cs\ifx{#1-#2-\subst_series-#4}\x_relax
+ \out_line{
+ \string\DeclareFontShape{#1}{#2}{\subst_series}{#4}{
+ <->\csname typ-\orig_series\endcsname\space
+ *~#2/\orig_series/#4
+ }{}
+ }
+ \x_cs\let{#1-#2-\subst_series-#4}\empty_command
+ \substitute_series{#1}{#2}{\subst_series}{#4}
+ \fi
+ \fi
+}
+\def\substitute_generic#1#2#3{
+ \edef\a_macro{#2}
+ \edef\b_macro{#3}
+ \ifx \a_macro \b_macro
+ \x_cs\let{sub-#3}\undefined_command
+ \else
+ \x_cs\let{sub-#3}\a_macro
+ \x_cs\def{typ-#3}{#1}
+ \fi
+}
+\def\substitutesilent{\substitute_generic{ssub}}
+\def\substitutenoisy{\substitute_generic{sub}}
+\substitutesilent{bx}{b}
+\substitutesilent{b}{bx}
+\substitutesilent{b}{sb}
+\substitutesilent{b}{db}
+\substitutesilent{m}{mb}
+\substitutesilent{m}{l}
+\substitutenoisy{ui}{it}
+\substitutesilent{sl}{it}
+\substitutesilent{it}{sl}
+\def\declareencoding#1#2{\x_cs\edef{enc-#1}{#2}}
+\declareencoding{TEX~TEXT}{ot1}
+\declareencoding{TEX~TEXT~WITHOUT~F-LIGATURES}{ot1}
+\declareencoding{TEX~TYPEWRITER~TEXT}{ot1tt}
+\declareencoding{TEX~MATH~ITALIC}{oml}
+\declareencoding{TEX~MATH~SYMBOLS}{oms}
+\declareencoding{TEX~MATH~EXTENSION}{omx}
+\declareencoding{LATEX~SYMBOLS}{lasy}
+\declareencoding{TEX~TEXT~SUBSET}{eufrak}
+\declareencoding{TEX~MATH~ITALIC~SUBSET}{eurm}
+\declareencoding{TEX~MATH~SYMBOLS~SUBSET}{euscr}
+\declareencoding{EULER~SUBSTITUTIONS~ONLY}{euex}
+\declareencoding{EXTENDED~TEX~FONT~ENCODING~-~LATIN}{t1}
+\declareencoding{TEX~TEXT~COMPANION~SYMBOLS~1---TS1}{ts1}
+\declareencoding{TEXBASE1ENCODING}{8r}
+\declareencoding{TEX~TYPEWRITER~AND~WINDOWS~ANSI}{8y}
+\def\declaresize#1#2{\x_cs\edef{siz-#1}{#2}}
+\declaresize{}{<->}
+\declaresize{5}{<5>}
+\declaresize{6}{<6>}
+\declaresize{7}{<7>}
+\declaresize{8}{<8>}
+\declaresize{9}{<9>}
+\declaresize{10}{<10>}
+\declaresize{11}{<10.95>}
+\declaresize{12}{<12>}
+\declaresize{14}{<14.4>}
+\declaresize{17}{<17.28>}
+\declaresize{20}{<20.74>}
+\declaresize{25}{<24.88>}
+\def\NOFILES{
+ \def\transformfont##1##2{
+ \touch_file{##1.mtx}
+ \touch_file{##1.pl}
+ }
+ \def\reglyphfont##1##2{\touch_file{##1.mtx}}
+ \def\installfonts{}
+ \def\endinstallfonts{}
+ \def\installfont##1##2##3##4##5##6##7##8{
+ \touch_file{##1.vpl}
+ }
+ \def\installrawfont##1##2##3##4##5##6##7##8{
+ \touch_file{##1.pl}
+ }
+ \def\installfamily##1##2##3{\touch_file{##1##2.fd}}
+}
+\def\touch_file#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \open_out{\lowercase_file}
+ \out_line{\percent_char~TEST~FILE.}
+ \out_line{\percent_char~Created~whilst~debugging~fontinst.}
+ \close_out{Test~file}
+}
+%%% From file: fitrig.dtx
+\chardef\nin@ty=90
+\chardef\@clxxx=180
+\chardef\@lxxi=71
+\mathchardef\@mmmmlxviii=4068
+\chardef\@coeffz=72
+\chardef\@coefb=42
+\mathchardef\@coefc=840
+\mathchardef\@coefd=5040
+\def\TG@rem@pt#1{\expandafter\lose_measure\the#1\space}
+\def\TG@term#1{
+ \dimen@\@tempb\dimen@
+ \advance\dimen@ #1\p@
+}
+\def\TG@series{
+ \dimen@\@lxxi\dimen@
+ \divide \dimen@ \@mmmmlxviii
+ \edef\@tempa{\TG@rem@pt\dimen@}
+ \dimen@\@tempa\dimen@
+ \edef\@tempb{\TG@rem@pt\dimen@}
+ \divide\dimen@\@coeffz
+ \advance\dimen@\m@ne\p@
+ \TG@term\@coefb
+ \TG@term{-\@coefc}%
+ \TG@term\@coefd
+ \dimen@\@tempa\dimen@
+ \divide\dimen@ \@coefd
+}
+\def\CalculateSin#1{{%
+ \if_undefined{sin(\number#1)}\then
+ \dimen@=#1\p@
+ \TG@@sin
+ \x_cs\xdef{sin(\number#1)}{\TG@rem@pt\dimen@}
+ \fi
+}}
+\def\CalculateCos#1{{%
+ \if_undefined{cos(\number#1)}\then
+ \dimen@=\nin@ty\p@
+ \advance \dimen@ -#1\p@
+ \TG@@sin
+ \x_cs\xdef{cos(\number#1)}{\TG@rem@pt\dimen@}
+ \fi
+}}
+\def\TG@@sin{%
+ \ifdim\TG@reduce>+%
+ \else\ifdim\TG@reduce<-%
+ \else\TG@series\fi\fi
+}
+\def\TG@reduce#1#2{
+ \dimen@#1#2\nin@ty\p@
+ \advance\dimen@#2-\@clxxx\p@
+ \dimen@-\dimen@
+ \TG@@sin
+}
+\def\UseSin#1{\csname sin(\number#1)\endcsname}
+\def\UseCos#1{\csname cos(\number#1)\endcsname}
+\chardef\z@num\z@
+\x_cs\let{sin(0)} \z@num
+\x_cs\let{cos(0)} \@ne
+\x_cs\let{sin(90)} \@ne
+\x_cs\let{cos(90)} \z@num
+\x_cs\let{sin(-90)}\m@ne
+\x_cs\let{cos(-90)}\z@num
+\x_cs\let{sin(180)}\z@num
+\x_cs\let{cos(180)}\m@ne
+\def\CalculateTan#1{{%
+ \if_undefined{tan(\number#1)}\then
+ \CalculateSin{#1}%
+ \CalculateCos{#1}%
+ \a_dimen\UseCos{#1}\p@
+ \divide \a_dimen \@iv
+ \b_dimen\UseSin{#1}\p@
+ \b_dimen\two@fourteen\b_dimen
+ \divide\b_dimen\a_dimen
+ \x_cs\xdef{tan(\number#1)}{\TG@rem@pt\b_dimen}
+ \fi
+}}
+\def\UseTan#1{\csname tan(\number#1)\endcsname}
+\mathchardef\two@fourteen=16384
+\chardef\@iv=4
+\x_cs\def{tan(90)}{\errmessage{Infinite tan !}}
+\expandafter\let
+ \csname tan(-90)\expandafter\endcsname \csname tan(90)\endcsname
+%%% From file: ficonv.dtx
+\def\afmtomtx#1#2{{
+ \let\setsomething_global=\x_relax
+ \open_out{\temp_prefix#2.mtx}
+ \edef\raw_font_name{#2}
+ \edef\source_font_name{#1}
+ \x_resetint{italicslant}{0}
+ \let\italcorr_expression=\uprightitalcorr
+ \x_setint{minimumkern}{0}
+ \minimum_kern=\int{minimumkern}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\afmtomtx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.afm~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \catcode`\^^M=12
+ \catcode`\ =10
+ \expandafter\afm_line\primitiveinput #1.afm\x_relax
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Metrics}
+}}
+\newcount\minimum_kern
+\def\afm_length#1#2{
+ \a_dimen=#2\afm_unit_dimen
+ #1=\a_dimen
+ \divide #1 by \afm_unit_dimen
+ \advance \a_dimen by -#1\afm_unit_dimen
+ \ifdim \a_dimen>0.5\afm_unit_dimen
+ \advance #1 by 1
+ \else \ifdim \a_dimen<-0.5\afm_unit_dimen
+ \advance #1 by -1
+ \fi\fi
+ \x_relax
+}
+\newdimen\afm_unit_dimen
+\afm_unit_dimen=1000sp
+{\catcode`\^^M=12 \gdef\afm_line#1
+{\afm_command#1~\end_of_line\afm_line}}
+\def\afm_command#1~{\csname~afm-#1\endcsname\gobble_one_line}
+\def\gobble_one_line#1\end_of_line{}
+\x_cs\def{afm-EndFontMetrics}#1\afm_line{\endinput}
+\def\afm_def#1(#2)#3{
+ \x_cs\def{afm-#1}\gobble_one_line#2\end_of_line{#3}
+}
+\def\afm_let#1#2{
+ \expandafter\let \csname afm-#1\expandafter\endcsname
+ \csname afm-#2\endcsname
+}
+\afm_def{CharWidth}(#1){\afm_length\char_x_width{#1}}
+\afm_def{ItalicAngle}(#1~){\calculate_it_slant{#1}}
+\afm_def{XHeight}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{xheight}{\the\a_count}}}
+\afm_def{CapHeight}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{capheight}{\the\a_count}}}
+\afm_def{Ascender}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{ascender}{\the\a_count}}}
+\afm_def{Descender}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{descender_neg}{\the\a_count}}}
+\afm_def{UnderlineThickness}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{underlinethickness}{\the\a_count}}}
+\afm_def{FontBBox}(#1~#2~#3~#4){
+ \afm_length\a_count{#4}
+ \out_line{\string\setint{maxheight}{\the\a_count}}
+ \afm_length\a_count{#2}
+ \out_line{\string\setint{maxdepth_neg}{\the\a_count}}}
+\afm_def{StdVW}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{verticalstem}{\the\a_count}}}
+\afm_def{IsFixedPitch}(#1){
+ \if\first_char#1=f
+ \else\out_line{\string\setint{monowidth}{1}}
+ \fi
+}
+\afm_def{FontName}(#1~){
+ \record_transform{\raw_font_name}
+ {\string\fromafm{\source_font_name}{#1}}{}\iftrue
+}
+\afm_def{KP}(#1~#2~#3~#4){
+ \if\first_char#1=.\else
+ \if\first_char#2=.\else
+ \afm_length\a_count{#3}
+ \ifnum \a_count>\minimum_kern
+ \afm_write_setkern{#1}{#2}{\the\a_count}
+ \else\ifnum \a_count<-\minimum_kern
+ \afm_write_setkern{#1}{#2}{\the\a_count}
+ \fi\fi
+ \fi\fi
+}
+\afm_let{KPX}{KP}
+\def\afm_write_setkern#1#2#3{\out_line{\string\setkern{#1}{#2}{#3}}}
+\afm_def{C}(#1~;#2){\init_afm{#1}\do_list[#2]\afm_char}
+\afm_def{CH}(<#1>~;#2){\uppercase{\init_afm{"#1}}\do_list[#2]\afm_char}
+\afm_def{CC}(#1~#2~;#3){\init_cc{#1}\do_list[#3]\cc_char}
+\newcount\char_slot
+\newcount\char_x_width
+\newcount\x_width
+\newcount\bbox_llx
+\newcount\bbox_lly
+\newcount\bbox_urx
+\newcount\bbox_ury
+\let\char_name=\empty_command
+\def\init_afm#1{
+ \char_slot=#1\x_relax
+ \x_width=\char_x_width
+ \bbox_llx=0
+ \bbox_lly=0
+ \bbox_urx=0
+ \bbox_ury=0
+ \let\char_name=\empty_command
+}
+\def\afm_char{
+ \eval_expr{
+ \italcorr_expression\x_width\bbox_llx\bbox_urx\bbox_lly\bbox_ury
+ }
+ \out_line{
+ \ifnum -1<\char_slot
+ \string\setrawglyph
+ \else
+ \string\setnotglyph
+ \fi
+ {\char_name}
+ {\raw_font_name}
+ {10pt}
+ {\the\char_slot}
+ {\the\x_width}
+ {\the\bbox_ury}
+ {\number -\bbox_lly}
+ {\the\result}
+ }
+}
+\def\init_cc#1{%
+ \out_line{\string\setglyph{#1}}
+ \def\char_name{#1}
+}
+\def\cc_char{%
+ \out_lline{\string\samesize{\char_name-not}}
+ \out_line{\string\endsetglyph}
+}
+\def\uprightitalcorr#1#2#3#4#5{0}
+\def\slanteditalcorr#1#2#3#4#5{\max{\sub{#3}{#1}}{0}}
+\def\calculate_it_slant#1{
+ \edef\theangle{#1}
+ \CalculateTan{\theangle}
+ \a_dimen=-\one_thousand sp
+ \a_dimen=\UseTan{\theangle}\a_dimen
+ \a_count=\a_dimen
+ \out_line{\string\setint{italicslant}{\the\a_count}}
+ \x_resetint{italicslant}{\a_count}
+ \ifnum 0<\a_count
+ \let\italcorr_expression=\slanteditalcorr
+ \else
+ \let\italcorr_expression=\uprightitalcorr
+ \fi
+}
+\def\do_list[~#1~#2;~#3]{
+ \csname~list-#1\endcsname\gobble_one_semi#2;
+ \ifx\x_relax#3\x_relax\expandafter\gobble_one
+ \else\expandafter\identity_one\fi
+ {\do_list[~#3]}
+}
+\def\gobble_one_semi#1;{}
+\def\list_def#1(#2)#3{\x_cs\def{list-#1}\gobble_one_semi#2~;{#3}}
+\list_def{W}(#1~#2){\afm_length\x_width{#1}}
+\list_def{WX}(#1){\afm_length\x_width{#1}}
+\list_def{WY}(#1){}
+\list_def{N}(#1){\def\char_name{#1}}
+\list_def{B}(#1~#2~#3~#4){
+ \afm_length\bbox_llx{#1}
+ \afm_length\bbox_lly{#2}
+ \afm_length\bbox_urx{#3}
+ \afm_length\bbox_ury{#4}
+}
+\list_def{PCC}(#1~#2~#3){
+ \afm_length\a_count{#2}
+ \afm_length\b_count{#3}
+ \out_lline{\string\glyphpcc{#1}{\the\a_count}{\the\b_count}}
+}
+\def\definealias#1#2#3{
+ \expandafter\def \csname GN-#1 \expandafter\endcsname
+ \expandafter{ \csname g-#2 \expandafter\endcsname
+ \csname i-#3\endcsname}
+}
+\def\glyph_alias#1{
+ \expandafter\expandafter \expandafter\glyph_alias_i
+ \csname GN-#1\endcsname
+}
+\def\glyph_alias_i#1#2{
+ \expandafter\gobble_three \string#1
+}
+\let\charnameprefix\empty
+\def\charnamealias#1{
+ \if_defined{GN-\charnameprefix#1}\then
+ \glyph_alias{\charnameprefix#1}
+ \else\if_defined{GN-#1}\then
+ \glyph_alias{#1}
+ \else
+ #1
+ \fi\fi
+}
+\def\alias_incr#1{
+ \expandafter\expandafter \expandafter\alias_incr_i
+ \csname GN-#1\endcsname
+}
+\def\alias_incr_i#1#2{
+ \ifx#2\x_relax
+ \mathchardef#2=\@ne
+ \else
+ \a_count=#2
+ \advance\a_count\@ne
+ \mathchardef#2=\a_count
+ \fi
+}
+\def\alias_char_name#1{
+ \if_defined{GN-\charnameprefix#1}\then
+ \edef\char_name{
+ \string\aliased{#1}{\glyph_alias{\charnameprefix#1}}
+ }
+ \alias_incr{\charnameprefix#1}
+ \else\if_defined{GN-#1}\then
+ \edef\char_name{
+ \string\aliased{#1}{\glyph_alias{#1}}
+ }
+ \alias_incr{#1}
+ \else
+ \edef\char_name{#1}
+ \fi\fi
+}
+\def\autoaliasafm{
+ \begingroup
+ \list_def{N}(##1){\alias_char_name{##1}}
+ \def\afm_write_setkern##1##2##3{
+ \out_line{
+ \string\setkern{\charnamealias{##1}}{\charnamealias{##2}}{##3}
+ }
+ }
+ \def\init_cc##1{%
+ \edef\char_name{\charnamealias{##1}}
+ \out_line{\string\setglyph{\char_name}}
+ }
+ \list_def{PCC}(##1~##2~##3){
+ \afm_length\a_count{##2}
+ \afm_length\b_count{##3}
+ \out_lline{\string\glyphpcc
+ {\charnamealias{##1}}{\the\a_count}{\the\b_count}}
+ }
+}
+\def\endautoaliasafm{\endgroup}
+\def\generalpltomtx#1#2#3#4{{
+ \let\setsomething_global=\x_relax
+ \let\setfontdimen=\pl_setfontdimen
+ \if _#4_ \else
+ \def\do_slot{\x_cs\let{name-\the\slot_number}\slot_name}
+ \def\do_boundary{\x_cs\let{name-BOUNDARYCHAR}\slot_name}
+ \inputetx{#4}
+ \let\CODINGSCHEME=\ignore_parens
+ \fi
+ \pl_to_mtx{#1}{#2}{#3}{\string\generalpltomtx{#1}{#2}{#3}{#4}}
+}}
+\def\pltomtx#1#2{\generalpltomtx{#1}{#2}{pl}{}}
+\def\pl_to_mtx#1#2#3#4{
+ \edef\raw_font_name{#1}
+ \open_out{\temp_prefix#2.mtx}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~#4}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.#3~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \lowercase{
+ \record_transform{#2}{
+ \string\from#3 \x_cs\ifx{from#3}\frompl {#1} \fi
+ }{}\iftrue
+ }
+ \out_line{}
+ \catcode`\(=0 \catcode`\)=9
+ \let\/=\ignore_parens
+ \let\do_pl_glyph=\x_relax
+ \primitiveinput #1.#3\x_relax
+ \do_pl_glyph
+ \out_line{}
+ \ifisint{\percent_char boundarychar}\then
+ \f_count=\int{\percent_char boundarychar}
+ \x_cs\ifx{name-\the\f_count}\x_relax \else
+ \out_line{\string\setstr{rightboundary}
+ {\csname name-\the\f_count\endcsname}
+ }
+ \out_line{}
+ \fi
+ \fi
+ \out_line{\endmetrics_text}
+ \close_out{Metrics}
+}
+\def\ignore_parens{\bgroup\catcode`(=1 \catcode`)=2 \x_relax
+ \expandafter\expandafter\expandafter\gobble_parens
+ \iftrue\expandafter{\else}\fi}
+\def\gobble_parens#1{\egroup}
+\def\pl_real#1{\pl_realer(#1000)}
+\def\pl_realer(#1.#2#3#4#5){#1#2#3#4}
+\def\pl_rounded_real(#1.#2#3#4#5){
+ \global\result=#1#2#3#4\relax
+ \ifnum \first_char#5= >4
+ \global\advance \result
+ \if - \first_char#1= \m@ne \else \@ne \fi
+ \fi
+}
+\def\pl_int#1#2{
+ \ifx#1C `#2
+ \else\ifx#1D #2
+ \else\ifx#1O '#2
+ \else\ifx#1H "#2
+ \else -1\errmessage{Unknown~PL~number~prefix~`#1'}
+ \fi\fi\fi\fi
+}
+\let\FAMILY=\ignore_parens
+\let\FACE=\ignore_parens
+\let\CHECKSUM=\ignore_parens
+\def\HEADER~#1~#2~#3~#4~{}
+\def\SEVENBITSAFEFLAG~#1~{}
+\let\COMMENT=\ignore_parens
+\let\LIG=\ignore_parens
+\let\NEXTLARGER=\ignore_parens
+\let\VARCHAR=\ignore_parens
+\let\VTITLE=\ignore_parens
+\let\MAPFONT=\ignore_parens
+\let\MAP=\ignore_parens
+\def\CODINGSCHEME{\bgroup\catcode`\)=12\x_relax\CODINGSCHEME_cont}
+\def\CODINGSCHEME_cont#1){
+ \egroup
+ \if_undefined{enc-#1}\then
+ \errhelp{The~encoding~for~`#1'~has~not~been~declared.^^J
+ You~should~declare~it~with~
+ \string\declareencoding{#1}{ETXFILE}.^^J
+ Press~<RETURN>~to~carry~on~with~fingers~crossed,^^J
+ or~X~<RETURN>~to~exit.}
+ \errmessage{Undeclared~encoding~`#1'}
+ \else
+ \def\do_slot{\x_cs\let{name-\the\slot_number}\slot_name}
+ \def\do_boundary{\x_cs\let{name-BOUNDARYCHAR}\slot_name}
+ \catcode`\(=12 \catcode`\)=12
+ \x_cs\inputetx{enc-#1}\x_relax
+ \catcode`\(=0 \catcode`\)=9
+ \fi
+}
+\def\DESIGNSIZE~#1~#2~{
+ \a_dimen=#2pt
+ \out_line{\string\setdim{designsize}{\the\a_dimen}}
+}
+\def\DESIGNUNITS~#1~#2~{
+ \b_dimen=#2pt\x_relax
+ \ifdim 1pt=\b_dimen \else
+ \fontinsterror{PL-to-MTX}{Nondefault~unit~used~in~PL~file}
+ {You~may~continue,~but~the~metrics~for~this~font~will~be~wrong.}
+ \fi
+ \out_line{\string\setdim{designunits}{\the\b_dimen}}
+}
+\def\BOUNDARYCHAR~#1~#2~{
+ \x_setint{\percent_char boundarychar}{\pl_int{#1}{#2}}
+}
+\def\pl_setfontdimen#1#2{\x_cs\def{fdimen-#1}{#2}}
+\def\PARAMETER~#1~#2~R~#3~{
+ \f_count=\pl_int{#1}{#2}\x_relax
+ \if_defined{fdimen-\the\f_count}\then
+ \pl_rounded_real(#3 0000)
+ \out_line{\string\setint{\csname fdimen-\the\f_count\endcsname}
+ {\the\result}}
+ \fi
+}
+\let\FONTDIMEN=\x_relax
+\def\SLANT{\PARAMETER D~1~}
+\pl_setfontdimen{1}{italicslant}
+\def\SPACE{\PARAMETER D~2~}
+\pl_setfontdimen{2}{interword}
+\def\STRETCH{\PARAMETER D~3~}
+\pl_setfontdimen{3}{stretchword}
+\def\SHRINK{\PARAMETER D~4~}
+\pl_setfontdimen{4}{shrinkword}
+\def\XHEIGHT{\PARAMETER D~5~}
+\pl_setfontdimen{5}{xheight}
+\def\QUAD{\PARAMETER D~6~}
+\pl_setfontdimen{6}{quad}
+\def\EXTRASPACE{\PARAMETER D~7~}
+\pl_setfontdimen{7}{extraspace}
+\def\NUM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~8~#2~#3~
+ \or
+ \PARAMETER D~9~#2~#3~
+ \or
+ \PARAMETER D~10~#2~#3~
+ \fi
+}
+\def\DENOM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~11~#2~#3~
+ \or
+ \PARAMETER D~12~#2~#3~
+ \fi
+}
+\def\SUP#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~13~#2~#3~
+ \or
+ \PARAMETER D~14~#2~#3~
+ \or
+ \PARAMETER D~15~#2~#3~
+ \fi
+}
+\def\SUB#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~16~#2~#3~
+ \or
+ \PARAMETER D~17~#2~#3~
+ \fi
+}
+\def\SUPDROP{\PARAMETER D~18~}
+\def\SUBDROP{\PARAMETER D~19~}
+\def\AXISHEIGHT{\PARAMETER D~22~}
+\def\DELIM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~20~#2~#3~
+ \or
+ \PARAMETER D~21~#2~#3~
+ \fi
+}
+\def\DEFAULTRULETHICKNESS{\PARAMETER D~8~}
+\def\BIGOPSPACING#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~9~#2~#3~
+ \or
+ \PARAMETER D~10~#2~#3~
+ \or
+ \PARAMETER D~11~#2~#3~
+ \or
+ \PARAMETER D~12~#2~#3~
+ \or
+ \PARAMETER D~13~#2~#3~
+ \fi
+}
+\def\LABEL~#1{\ifx #1B
+ \expandafter\LABEL_boundarychar
+ \else
+ \expandafter\LABEL_slot \expandafter#1
+ \fi
+}
+\def\LABEL_slot #1~#2~{
+ \f_count=\pl_int{#1}{#2}
+ \edef\a_macro{\a_macro
+ \x_cs\do_if_defined{name-\the\f_count}
+ }
+}
+\def\LABEL_boundarychar OUNDARYCHAR{
+ \edef\a_macro{\a_macro
+ \x_cs\do_if_defined{name-BOUNDARYCHAR}
+ }
+}
+\def\do_if_defined#1{\ifx #1\x_relax \else \do{#1} \fi}
+\def\LIGTABLE{\let\do=\never_do\let\a_macro\empty_command}
+\def\STOP{\let\a_macro\empty_command}
+\def\SKIP~#1~#2~{\immediate\write16{Warning:~SKIP~instruction~ignored.}}
+\def\KRN~#1~#2~R~#3~{
+ \pl_rounded_real(#3 0000)
+ \edef\do{\noexpand\write_pl_krn{\pl_int{#1}{#2}}{\the\result}}
+ \a_macro
+ \let\do=\never_do
+}
+\def\write_pl_krn#1#2#3{
+ \f_count=#1\x_relax
+ \x_cs\ifx{name-\the\f_count}\x_relax \else
+ \out_line{\string\setkern{#3}
+ {\csname name-\the\f_count\endcsname}{#2}
+ }
+ \fi
+}
+\def\CHARWD~R~#1~{\pl_rounded_real(#1 0000) \b_count=\result}
+\def\CHARHT~R~#1~{\pl_rounded_real(#1 0000) \c_count=\result}
+\def\CHARDP~R~#1~{\pl_rounded_real(#1 0000) \d_count=\result}
+\def\CHARIC~R~#1~{\pl_rounded_real(#1 0000) \e_count=\result}
+\def\CHARACTER~#1~#2~{
+ \do_pl_glyph
+ \a_count=\pl_int{#1}{#2}
+ \b_count=0
+ \c_count=0
+ \d_count=0
+ \e_count=0
+ \let\do_pl_glyph=\write_pl_glyph
+}
+\def\write_pl_glyph{
+ \x_cs\ifx{name-\the\a_count}\x_relax\else
+ \out_line{\string\setrawglyph
+ {\csname~name-\the\a_count\endcsname}
+ {\raw_font_name}
+ {\the\a_dimen}
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {\the\e_count}}
+ \fi
+ }
+\def\mtxtopl#1#2{{
+ \let\setsomething_global=\x_relax
+ \open_out{#2.pl}
+ \top_of_pl_hook
+ \out_line{(COMMENT~raw~font~#2~created~by~fontinst~
+ v\fontinstversion)}
+ \out_line{}
+ \out_line{(COMMENT~Filename:~#2.pl)}
+ \out_line{(COMMENT~Created~by:~tex~\jobname)}
+ \out_line{(COMMENT~Created~using:~\string\mtxtopl{#1}{#2})}
+ \out_line{}
+ \out_line{(COMMENT~This~file~can~be~turned~into~
+ a~ligless~TeX~font~with)}
+ \out_line{(COMMENT~pltotf~#2.pl~#2.tfm)}
+ \out_line{}
+ \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)}
+ \out_line{}
+ \out_line{(DESIGNSIZE~R~10.0)}
+ \out_line{}
+ \let\setglyph=\iffalse
+ \let\endsetglyph=\fi
+ \let\setkern=\gobble_three
+ \let\setscaledrawglyph=\first_pl_raw_glyph
+ \def\setscalednotglyph##1##2##3##4##5##6##7##8##9{}
+ \inputmtx{#1}
+ \out_line{}
+ \out_line{(COMMENT~END~OF~FILE~#2.pl)}
+ \close_out{Raw~font}
+}}
+\def\first_pl_raw_glyph#1#2#3#4{
+ \out_line{(DESIGNUNITS~R~\make_factor{#4})}
+ \let\setscaledrawglyph=\pl_raw_glyph
+ \pl_raw_glyph{#1}{#2}{#3}{#4}
+}
+\def\pl_raw_glyph#1#2#3#4#5#6#7#8#9{
+ \out_line{(CHARACTER~D~\number#5~\space(COMMENT~#1)}
+ \out_lline{(CHARWD~R~\make_factor{#6})}
+ \out_lline{(CHARHT~R~\make_factor{#7})}
+ \out_lline{(CHARDP~R~\make_factor{#8})}
+ \out_lline{(CHARIC~R~\make_factor{#9})}
+ \out_lline{)}
+}
+\def\transformfont#1#2{{
+ \let\setsomething_global=\x_relax
+ \unsetstr{afm-name}
+ \unsetstr{etx-name}
+ \x_resetint{x-scale}{\one_thousand}
+ \x_resetint{y-scale}{\one_thousand}
+ \x_resetint{slant-scale}{0}
+ #2
+ \ifisstr{afm-name}\then
+ \mtxtomtx{\str{afm-name}}{#1}
+ \mtxtopl{#1}{#1}
+ \else
+ \fontinsterror{Transformfont}{
+ Failed~to~make~transformed~font~#1;\messagebreak
+ source~font~metrics~file~not~found
+ }\error_help_a
+ \fi
+}}
+\def\fromafm#1{
+ \if_file_exists{#1.afm}\then
+ \x_setstr{afm-name}{#1}
+ \afmtomtx{#1}{#1}
+ \mtxtopl{#1}{#1}
+ \fi
+}
+\def\frommtx#1{
+ \if_file_exists{#1.mtx}\then \x_setstr{afm-name}{#1} \fi
+}
+\def\frompl#1{
+ \if_file_exists{#1.pl}\then
+ \x_setstr{afm-name}{#1}
+ \generalpltomtx{#1}{#1}{pl}{}
+ \fi
+}
+\def\fromplgivenetx#1#2{
+ \if_file_exists{#1.pl}\then
+ \x_setstr{afm-name}{#1}
+ \generalpltomtx{#1}{#1}{pl}{#2}
+ \fi
+}
+\def\fromany#1{
+ \x_cs\edef{s-afm-name}{#1}
+ \if_file_exists{#1.mtx}\then\else
+ \if_file_exists{#1.pl}\then
+ \generalpltomtx{#1}{#1}{pl}{}
+ \else
+ \if_file_exists{#1.afm}\then
+ \afmtomtx{#1}{#1}
+ \mtxtopl{#1}{#1}
+ \else
+ \if_file_exists{#1.vpl}\then
+ \generalpltomtx{#1}{#1}{vpl}{}
+ \else
+ \unsetstr{afm-name}
+ \fi\fi\fi\fi
+}
+\def\scalefont#1#2{
+ \eval_expr_to\d_count{#1}
+ \x_resetint{x-scale}{\scale{\d_count}{\int{x-scale}}}
+ \x_resetint{y-scale}{\scale{\d_count}{\int{y-scale}}}
+ \x_resetint{slant-scale}{\scale{\d_count}{\int{slant-scale}}}
+ #2
+}
+\def\xscalefont#1#2{
+ \x_resetint{x-scale}{\scale{#1}{\int{x-scale}}}
+ #2
+}
+\def\yscalefont#1#2{
+ \eval_expr_to\d_count{#1}
+ \x_resetint{y-scale}{\scale{\d_count}{\int{y-scale}}}
+ \x_resetint{slant-scale}{\scale{\d_count}{\int{slant-scale}}}
+ #2
+}
+\def\slantfont#1#2{
+ \x_resetint{slant-scale}{
+ \add{\scale{#1}{\int{x-scale}}}{\int{slant-scale}}
+ }
+ #2
+}
+\def\reencodefont#1#2{
+ #2
+ \resetstr{etx-name}{#1}
+}
+\def\mtxtomtx#1#2{{
+ \let\a_macro=\empty_command
+ \_a_true
+ \ifnum \int{x-scale}=\int{y-scale}
+ \ifnum \int{slant-scale}=\z@
+ \_a_false
+ \fi \fi
+ \if_a_
+ \a_count=\int{x-scale}
+ \l_inv_scale\a_count{\int{y-scale}}
+ \b_count=\int{slant-scale}
+ \l_inv_scale\b_count{\int{y-scale}}
+ \edef\a_macro{\a_macro
+ \string\transformfont{\the\a_count}{\the\b_count}
+ }
+ \fi
+ \open_out{\temp_prefix#2.mtx}
+ \edef\raw_font_name{#2}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\mtxtomtx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \ifisstr{etx-name}\then
+ \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}}
+ \def\declarepsencoding##1##2##3{
+ \a_toks={{##1}{##2}{##3}}
+ \out_line{\string\providepsencoding\the\a_toks}
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file
+ {\string\providepsencoding\the\a_toks}
+ \fi
+ }
+ \directfalse
+ \inputetx{\str{etx-name}}
+ \edef\a_macro{\a_macro\string\reencodefont{\str{etx-name}}}
+ \fi
+ \record_transform{#2}{\string\frommtx{#1}}{\a_macro}\iftrue
+ \out_line{}
+ \mtxtomtx_redefinitions
+ \inputmtx{#1}
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Transformed~metrics}
+}}
+\def\mtxtomtx_redefinitions{
+ \let\setint=\mtxtomtx_setint
+ \let\setdim=\mtxtomtx_setdim
+ \let\setstr=\mtxtomtx_setstr
+ \let\setscaledrawglyph=\mtxtomtx_setscaledrawglyph
+ \let\setscalednotglyph=\mtxtomtx_setscaledrawglyph
+ \let\setkern=\mtxtomtx_setkern
+ \let\setglyph=\mtxtomtx_setglyph
+ \let\glyphpcc=\mtxtomtx_glyphpcc
+ \let\samesize=\mtxtomtx_samesize
+ \let\endsetglyph=\mtxtomtx_endsetglyph
+ \def\aliased{\string\aliased}
+}
+\let\aliased=\second_of_two
+\def\mtxtomtx_setint#1#2{
+ \def\a_macro{#1}
+ \ifx \a_macro\italicslant_name
+ \eval_expr{#2}
+ \global\multiply \result \int{x-scale}
+ \a_count=\int{slant-scale}
+ \multiply \a_count \one_thousand
+ \advance \a_count \result
+ \divide \a_count \int{y-scale}\x_relax
+ \else
+ \def\do##1{
+ \def\b_macro{##1}
+ \ifx \a_macro\b_macro \expandafter\if_false \fi
+ }
+ \gobble_one\iftrue \width_ints_list \if_true
+ \eval_expr_to\a_count{\scale{#2}{\int{y-scale}}}
+ \else
+ \eval_expr_to\a_count{\scale{#2}{\int{x-scale}}}
+ \fi
+ \fi
+ \out_line{\string\setint{#1}{\the\a_count}}
+}
+\def\italicslant_name{italicslant}
+\def\width_ints_list{
+ \do{interword}\do{stretchword}\do{shrinkword}\do{quad}
+ \do{extraspace}\do{digitwidth}\do{verticalstem}
+}
+\def\mtxtomtx_setdim#1#2{
+ \out_line{\string\setdim{#1}{#2}}
+}
+\def\mtxtomtx_setstr#1#2{
+ \out_line{\string\setstr{#1}{#2}}
+}
+\def\mtxtomtx_setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \eval_expr_to\a_count{\scale{#6}{\int{x-scale}}}
+ \eval_expr_to\b_count{\scale{#7}{\int{y-scale}}}
+ \eval_expr_to\c_count{\scale{#8}{\int{y-scale}}}
+ \eval_expr_to\d_count{#9} \eval_expr{#7}
+ \multiply \d_count \int{x-scale}
+ \global\multiply \result \int{slant-scale}
+ \global\advance \result \d_count
+ \rounded_thousandths
+ \d_count=\result
+ \eval_expr{\scale{#4}{\int{y-scale}}}
+ \ifisstr{etx-name}\then
+ \bgroup
+ \let\aliased=\first_of_two
+ \if_undefined{slots-#1}\then
+ \egroup \e_count=\m@ne
+ \else
+ \expandafter\egroup \expandafter\e_count
+ \csname slots-#1\endcsname
+ \fi
+ \else
+ \e_count=#5
+ \fi
+ \out_line{
+ \ifnum \e_count>\m@ne
+ \string\setscaledrawglyph
+ \else
+ \string\setscalednotglyph
+ \fi
+ {#1}{\raw_font_name}{#3}{\the\result}{\the\e_count}
+ {\the\a_count}{\the\b_count}{\the\c_count}{\the\d_count}
+ }
+}
+\def\mtxtomtx_setkern#1#2#3{
+ \eval_expr{\scale{\int{x-scale}}{#3}}
+ \out_line{\string\setkern{#1}{#2}{\the\result}}
+}
+\def\mtxtomtx_setglyph#1{\out_line{\string\setglyph{#1}}}
+\def\mtxtomtx_samesize#1{\out_lline{\string\samesize{#1}}}
+\def\mtxtomtx_endsetglyph{\out_line{\string\endsetglyph}}
+\def\mtxtomtx_glyphpcc#1#2#3{
+ \eval_expr_to\b_count{\scale{\int{y-scale}}{#3}}
+ \eval_expr_to\a_count{#2} \eval_expr{#3}
+ \multiply \a_count \int{x-scale}
+ \global\multiply \result \int{slant-scale}
+ \global\advance \result \a_count
+ \rounded_thousandths
+ \out_lline{\string\glyphpcc{#1}{\the\result}{\the\b_count}}
+}
+\def\reglyphfonts{
+ \begingroup
+ \let\setsomething_global=\x_relax
+ \x_setint{renameweight}{1}
+ \x_setint{killweight}{-10}
+ \setcommand\iftokeep##1\then{\ifnum -1<##1}
+}
+\def\endreglyphfonts{\endgroup}
+\def\offmtxcommand#1{
+ \x_cs\offcommand{reglyph_\expandafter\gobble_one\string#1}
+}
+\def\onmtxcommand#1{
+ \x_cs\oncommand{reglyph_\expandafter\gobble_one\string#1}
+}
+\begingroup
+ \catcode`\-=11
+ \gdef\renameglyph#1#2{
+ \x_cs\edef{slots-#2}{
+ \noexpand\rename_glyph{#1}\noexpand\i-renameweight
+ }
+ }
+\endgroup
+\def\renameglyphweighted#1#2#3{
+ \eval_expr{#3}
+ \x_cs\edef{slots-#2}{\noexpand\rename_glyph{#1}{\the\result}}
+}
+\begingroup
+ \catcode`\-=11
+ \gdef\killglyph#1{
+ \x_cs\def{slots-#1}{\kill_glyph\i-killweight}
+ }
+\endgroup
+\def\killglyphweighted#1#2{
+ \eval_expr{#2}
+ \x_cs\edef{slots-#1}{\noexpand\kill_glyph{\the\result}}
+}
+\def\reglyphfont#1#2{
+ \fromany{#2}
+ \ifisstr{afm-name}\then
+ \reglyph_font{#1}{#2}
+ \else
+ \fontinsterror{Reglyph}{Could~not~find~font~metrics~for~#2.}
+ \error_help_a
+ \fi
+}
+\def\reglyph_font#1#2{{
+ \open_out{\temp_prefix#1.mtx}
+ \out_line{\percent_char~Filename:~#1.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\reglyphfont{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \record_transform{#1}{\string\frommtx{#2}}{\string\reglyphfont}
+ \iftrue
+ \out_line{}
+ \reglyph_redefinitions
+ \inputmtx{#2}
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Reglyphed~metrics}
+}}
+\def\reglyph_redefinitions{
+ \let\setint=\reglyph_setint
+ \let\setdim=\reglyph_setdim
+ \let\setstr=\reglyph_setstr
+ \let\setscaledrawglyph=\reglyph_setscaledrawglyph
+ \let\setscalednotglyph=\reglyph_setscaledrawglyph
+ \let\setkern=\reglyph_setkern
+ \let\setglyph=\reglyph_setglyph
+ \let\glyphpcc=\reglyph_glyphpcc
+ \let\samesize=\reglyph_samesize
+ \let\endsetglyph=\reglyph_endsetglyph
+}
+\def\reglyph_setint#1#2{\out_line{\string\setint{#1}{#2}}}
+\def\reglyph_setdim#1#2{\out_line{\string\setdim{#1}{#2}}}
+\def\reglyph_setstr#1#2{\out_line{\string\setstr{#1}{#2}}}
+\newcount\command_survivance
+\def\rename_glyph#1{\def\glyphname{#1}\kill_glyph}
+\def\kill_glyph#1{\advance \command_survivance #1\x_relax}
+\def\reglyph_setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{
+ \ifnum #5<\z@
+ \string\setscalednotglyph
+ \else
+ \string\setscaledrawglyph
+ \fi
+ {\glyphname}{#2}{#3}{\number#4}{#5}{#6}{#7}{#8}{#9}
+ }
+ \fi
+}
+\def\reglyph_setkern#1#2#3{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \let\a_macro=\glyphname
+ \def\glyphname{#2}
+ \csname slots-#2\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{\string\setkern{\a_macro}{\glyphname}{#3}}
+ \fi
+}
+\def\reglyph_setglyph#1{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_line{\string\setglyph{\glyphname}}}
+ \a_toks=\expandafter{\a_macro}
+}
+\x_cs\def{off-\string\reglyph_setglyph}#1{\gobble_glyph}
+\def\reglyph_glyphpcc#1#2#3{
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_lline{
+ \string\glyphpcc{\glyphname}{#2}{#3}
+ }}
+ \a_toks=\expandafter{\the\expandafter\a_toks \a_macro}
+}
+\def\reglyph_samesize#1{
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_lline{
+ \string\samesize{\glyphname}
+ }}
+ \a_toks=\expandafter{\the\expandafter\a_toks \a_macro}
+}
+\def\reglyph_endsetglyph{
+ \iftokeep\command_survivance\then
+ \the\a_toks
+ \out_line{\string\endsetglyph}
+ \fi
+ \a_toks={}
+}
+%%% From file: filtfam.dtx
+\def\latinfamily#1#2{{
+ \edef\a_macro{#1}
+ \expandafter\parse_family\a_macro
+ \empty_command\empty_command\end_parse_family
+ \installfonts
+ \if_file_exists{\raw_encoding.mtx}\then
+ \installfamily{\raw_encoding}{\latex_family}{#2}
+ \fi
+ \installfamily{OT1}{\latex_family}{#2}
+ \installfamily{T1}{\latex_family}{#2}
+ \installfamily{TS1}{\latex_family}{#2}
+ \latin_weights
+ \endinstallfonts
+}}
+\def\parse_family #1#2#3#4#5\end_parse_family{
+ \gdef\font_family{#1#2#3}
+ \gdef\font_variant{#4#5}
+ \gdef\raw_variant{#4#5}
+ \gdef\latex_family{#1#2#3#4#5}
+ \_expert_false
+ \_oldstyle_false
+ \ifx#4x
+ \_expert_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1}
+ \else\ifx#4j
+ \_expert_true
+ \_oldstyle_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1oldstyle}
+ \else\ifx#49
+ \gdef\latex_family{#1#2#3j#5}
+ \_expert_true
+ \_oldstyle_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1oldstyle}
+ \else
+ \_expert_false
+ \_oldstyle_false
+ %\setcommand\digit##1{##1}
+ \fi\fi\fi
+ \if_oldstyle_
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#5>~(oldstyle)}
+ \else\if_expert_
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#5>~(expert)}
+ \else
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#4#5>}
+ \fi\fi
+}
+\newif\if_expert_
+\newif\if_oldstyle_
+\def\latin_weight#1#2{
+ \gdef\font_weight{#1}%
+ \gdef\latex_weight{#2}%
+ \latin_widths
+}
+\def\latin_width#1#2{
+ \gdef\font_width{#1}
+ \gdef\latex_width{#2}
+ \latin_shapes
+}
+\def\latin_shape#1#2#3#4#5{
+ \gdef\font_shape{#1}
+ \gdef\raw_shape{#2}
+ \gdef\encoding_shape{#3}
+ \if_oldstyle_
+ \gdef\encoding_shape{#3\oldstyle_shape}
+ \fi
+ \gdef\latex_shape{#4}
+ \gdef\encoding_switches{#5}
+ \immediate\write16{
+ INFO>~to~make~LaTeX~font~shape~<\latex_family,
+ \latex_weight,\latex_shape,\latex_width>~seek~
+ \font_family\font_weight\raw_shape
+ \raw_variant\raw_encoding\font_width.mtx}
+ \csname fake_width_\font_width\endcsname
+ \csname fake_shape_\raw_shape\endcsname
+ \if_file_exists{
+ \font_family\font_weight\raw_shape
+ \raw_variant\raw_encoding\font_width.mtx
+ }\then
+ \latin_encodings
+ \fi
+}
+\def\fake_shape_{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_raw_encoding
+ \fi
+ \if_expert_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.afm
+ }\then
+ \fake_shape_expert_encoding
+ \fi
+ \fi
+ \if_oldstyle_
+ \gdef\oldstyle_variant{\oldstyle_shape}
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_oldstyle_encoding
+ \else
+ \gdef\oldstyle_variant{\caps_shape}
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_oldstyle_encoding
+ \fi
+ \fi
+ \fi
+}
+\def\fake_shape_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width>
+ }
+ \transformfont{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \reencodefont{\raw_encoding}{
+ \fromafm{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+}
+\def\fake_shape_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \fromafm{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width
+ }
+ \fi
+}
+\def\fake_shape_oldstyle_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\raw_shape\oldstyle_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width>
+ }
+ \transformfont{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \raw_encoding\font_width
+ }{
+ \reencodefont{\raw_encoding}{
+ \fromafm{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width
+ }
+ }
+ }
+ \fi
+}
+\def\fake_shape_c{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_
+ \else
+ % If real smallcaps font doesn't exist, fake it from the roman.
+ \gdef\raw_shape{}
+ \if_oldstyle_
+ \gdef\encoding_shape{cj}
+ \else
+ \gdef\encoding_shape{c}
+ \fi
+ \fake_shape_
+ \fi
+}
+\def\fake_shape_o{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_
+ \else
+ \fake_shape_o_raw_encoding
+ \if_expert_
+ \fake_shape_o_expert_encoding
+ \fi
+ \if_oldstyle_
+ \fake_shape_o_oldstyle_encoding
+ \fi
+ \fi
+}
+\def\fake_shape_o_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_variant
+ \raw_encoding\font_width>~(faking~oblique)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+ \fi
+}
+\def\fake_shape_o_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width>~from~
+ <\font_family\font_weight\raw_variant
+ \expert_encoding\font_width>~(faking~oblique)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ \space from~
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width
+ }
+ }
+ }
+ \fi
+ \fi
+}
+\def\fake_shape_o_oldstyle_encoding{
+ \if_file_exists{
+ \font_family\font_weight\oldstyle_variant
+ \raw_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\oldstyle_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\oldstyle_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\oldstyle_variant
+ \raw_encoding\font_width>~(faking~oblique)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\oldstyle_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\oldstyle_variant
+ \raw_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\oldstyle_variant
+ \raw_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\oldstyle_variant
+ \raw_encoding\font_width
+ }
+ }
+ }
+ \fi
+ \fi
+}
+\let\fake_shape_i\fake_shape_ % We must do this again!
+\newif\if_fake_narrow_
+\_fake_narrow_false
+\def\fakenarrow#1{
+ \_fake_narrow_true
+ \gdef\fake_narrow_width{#1}
+}
+\def\fake_width_{}
+\def\fake_width_c{}
+\def\fake_width_n{
+ \if_fake_narrow_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then % no action required
+ \else
+ \fake_width_n_raw_encoding
+ \if_expert_
+ \fake_width_n_expert_encoding
+ \fi
+ \fi
+ \fi
+}
+\def\fake_width_n_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding>~(faking~narrow)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~narrow~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \xscalefont{\fake_narrow_width}{
+ \frommtx{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installrawfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+ \fi
+}
+\def\fake_width_n_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width>~from~
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding>~(faking~narrow)
+ }
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~narrow~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ \space from~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ }{
+ \xscalefont{\fake_narrow_width}{
+ \frommtx{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding
+ }
+ }
+ }
+ \fi
+ \fi
+}
+\def\latin_encoding#1#2#3#4#5{
+ \gdef\latex_encoding{#4}
+ \gdef\latex_mtx{#5}
+ \if_oldstyle_
+ \gdef\font_encoding{#3}
+ \else\if_expert_
+ \gdef\font_encoding{#2}
+ \else
+ \gdef\font_encoding{#1}
+ \fi\fi
+ \gdef\expert_font{}
+ \gdef\oldstyle_font{}
+ \if_expert_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then
+ \gdef\expert_font{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width,
+ }
+ \fi
+ \fi
+ \if_oldstyle_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \raw_variant\raw_encoding\font_width.mtx
+ }\then
+ \gdef\oldstyle_font{
+ unsetnum,
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \raw_variant\raw_encoding\font_width,
+ resetosf,
+ }
+ \fi
+ \fi
+ \immediate\write16{
+ INFO>~run~\string\installfont\space
+ <\font_family\font_weight\font_shape\font_variant
+ \font_encoding\font_width>
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \if_oldstyle_
+ \ifx\raw_shape\caps_shape
+ resetosf,
+ \fi
+ \fi
+ \expert_font
+ \oldstyle_font
+ \latex_mtx>
+ <\latex_encoding\encoding_shape>
+ <\latex_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+ \installfont{
+ \font_family\font_weight\font_shape\font_variant
+ \font_encoding\font_width
+ }{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \if_oldstyle_
+ \ifx\raw_shape\caps_shape
+ resetosf,
+ \fi
+ \fi
+ \expert_font
+ \oldstyle_font
+ \latex_mtx
+ }{
+ \latex_encoding\encoding_shape
+ }{
+ \latex_encoding
+ }{
+ \latex_family
+ }{
+ \latex_weight\latex_width
+ }{
+ \latex_shape
+ }{}
+}
+\def\latin_weights{
+ \latin_weight{r}{m}
+ \latin_weight{k}{m}
+ \latin_weight{b}{b}
+ \latin_weight{s}{sb}
+ \latin_weight{d}{db} % was {d}{sb}, SPQR changed
+ \latin_weight{m}{mb} % was {m}{m}, UV changed
+ \latin_weight{c}{eb} % UV added
+ \latin_weight{h}{eb} % UV added
+ \latin_weight{x}{eb}
+ \latin_weight{u}{ub}
+ \latin_weight{l}{l}
+ %\latin_weight{j}{el}
+ %\latin_weight{a}{ul} % UV added
+}
+\def\latin_widths{
+ \latin_width{}{}
+ \latin_width{n}{c}
+ %latin_width{c}{c}
+ %latin_width{x}{x}
+}
+\def\latin_shapes{
+ \latin_shape{} {} {} {n} {\_textcomp_true }
+ \latin_shape{c}{c}{} {sc}{\_textcomp_false}
+ \latin_shape{o}{o}{} {sl}{\_textcomp_true }
+ \latin_shape{i}{i}{i}{it}{\_textcomp_true }
+}
+\def\latin_encodings{
+ \latin_encoding{7t}{9t}{9o}{OT1}{newlatin}
+ \latin_encoding{8t}{9e}{9d}{T1} {newlatin}
+ \encoding_switches
+ \if_textcomp_
+ \latin_encoding{8c}{9c}{9c}{TS1}{textcomp}
+ \fi
+}
+\newif\if_textcomp_
+
+\def\raw_encoding{8r}
+\def\adobe_encoding{8a}
+\def\expert_encoding{8x}
+
+\def\caps_shape{c}
+\def\oldstyle_shape{j}
+\def\SlantAmount{167}
+%%% From file: fimapgen.dtx
+\def\mapfrags_subsystem{Map~fragments~writer}
+\def\recordtransforms#1{\open_pout\transform_record_file{#1}}
+\def\endrecordtransforms{
+ \close_pout\transform_record_file{Font~transformation~records}
+}
+\chardef\transform_record_file=\closed_stream
+\let\storemapdata=\gobble_three
+\def\record_transform#1#2#3#4{
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file{\string\storemapdata{#1}{#2}{#3}}
+ \fi
+ #4 \out_line{\string\storemapdata{#1}{#2}{#3}} \fi
+}
+\def\record_usage#1{
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file{\string\makemapentry{#1}}
+ \fi
+}
+\let\declarepsencoding=\gobble_three
+\let\providepsencoding=\gobble_three
+%%% From file: fibasics.dtx
+\def\needsfontinstversion#1{{
+ \a_dimen=#1pt
+ \b_dimen=\fontinstversion~pt\x_relax
+ \ifnum\a_dimen>\b_dimen
+ \immediate\write16{}
+ \immediate\write16{Warning:~This~file~needs~fontinst~version~#1.}
+ \immediate\write16{Warning:~You~are~using~version~
+ \fontinstversion.}
+ \immediate\write16{Warning:~This~may~cause~errors.}
+ \immediate\write16{}
+ \fi
+}}
+\if_file_exists{fontinst.rc}\then
+ \primitiveinput fontinst.rc
+\else
+ \immediate\write16{No~file~fontinst.rc.}
+\fi
+\normalcc
+\endinput
+%%
+%% End of file `xfntinst.sty'.
diff --git a/fonts/utilities/fontinst/inputs/latinetx/8r.etx b/fonts/utilities/fontinst/inputs/latinetx/8r.etx
new file mode 100644
index 0000000000..c4592964f0
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/8r.etx
@@ -0,0 +1,1354 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Alan Jeffrey and Sebastian Rahtz and
+%%% Constantin Kahn and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m and Walter Schmidt
+%%% and Philipp Lehman",
+%%% version = "2.0",
+%%% date = "2003-02-09",
+%%% time = "17:13:33 +01:00",
+%%% filename = "8r.etx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, raw, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the 8r encoding as a TeX font encoding
+%%% file, for use with the fontinst utility.
+%%% It implements the TeX Base1 encoding.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage[TS1,T1]{fontenc}
+\usepackage{textcomp}
+\usepackage{fontdoc}[2001/03/16]
+\usepackage{amsfonts}
+
+\title{The \TeX\ Base~1 encoding vector}
+\author{Alan~Jeffrey\and Sebastian~Rahtz\and Constantin~Kahn\and
+ Ulrik~Vieth\and Lars~Hellstr\"om\and Walter~Schmidt\and
+ Philipp~Lehman}
+\date{9 February 2003\\Version 2.0}
+
+\showbranches
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the \TeX{}Base1 encoding vector, also known
+as the \texttt{8r} encoding.
+
+\encoding
+
+\needsfontinstversion{1.924}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lctop#1#2{#2}
+\setcommand\uctop#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\ifisglyph{space}\then
+ \setint{interword}{\width{space}}
+\Else\ifisglyph{i}\then
+ \setint{interword}{\width{i}}
+\Else
+ \setint{interword}{333}
+\Fi\Fi
+
+\ifisint{monowidth}\then
+ \setint{stretchword}{0}
+ \setint{shrinkword}{0}
+ \setint{extraspace}{\int{interword}}
+ \setint{ligaturing}{0}
+\Else
+ \setint{stretchword}{\scale{\int{interword}}{600}}
+ \setint{shrinkword}{\scale{\int{interword}}{240}}
+ \setint{extraspace}{\scale{\int{interword}}{240}}
+ \setint{ligaturing}{1}
+\Fi
+\setint{quad}{1000}
+
+
+\begincomment
+\section{Font parameters}
+\endcomment
+
+\setstr{codingscheme}{TEXBASE1ENCODING}
+
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+
+\begincomment
+\section{The encoding}
+
+\subsection{The ASCII control range}
+
+The layout of the first 32 slots is rather arbitrary, except
+that is was carefully chosen to avoid the potentially dangerous
+slots 0 (NUL), 10 (LF) and 13 (CR).
+\endcomment
+
+\nextslot{1}
+\setslot{dotaccent}
+ \comment{The dot accent `\.{}'.}
+\endsetslot
+
+\setslot{\lclig{FI}{fi}}
+ \comment{The `fi' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FL}{fl}}
+ \comment{The `fl' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{fraction}
+ \comment{The fraction slash `\textfractionsolidus'.}
+\endsetslot
+
+\setslot{hungarumlaut}
+ \comment{The long Hungarian umlaut `\H{}'.}
+\endsetslot
+
+\setslot{\uc{Lslash}{lslash}}
+ \comment{The letter `\L'.}
+\endsetslot
+
+\setslot{\lc{Lslash}{lslash}}
+ \comment{The letter `\l'.}
+\endsetslot
+
+\setslot{ogonek}
+ \comment{The ogonek accent `\k{}'.}
+\endsetslot
+
+\setslot{ring}
+ \comment{The ring accent `\r{}'.}
+\endsetslot
+
+\nextslot{11}
+\setslot{breve}
+ \comment{The breve accent `\u{}'.}
+\endsetslot
+
+\setslot{minus}
+ \comment{The subtraction sign `\textminus'.}
+\endsetslot
+
+\nextslot{14}
+\setslot{\uctop{Zcaron}{zcaron}}
+ \comment{The letter `\v Z'.}
+\endsetslot
+
+\setslot{\lctop{Zcaron}{zcaron}}
+ \comment{The letter `\v z'.}
+\endsetslot
+
+\setslot{caron}
+ \comment{The caron or h\'a\v cek accent `\v{}'.}
+\endsetslot
+
+\setslot{\lc{dotlessI}{dotlessi}}
+ \comment{A dotless i `\i', used to produce accented letters such as
+ `\=\i'.}
+\endsetslot
+
+\setslot{\lc{dotlessJ}{dotlessj}}
+ \comment{A dotless j `\j', used to produce accented letters such as
+ `\=\j'. Most non-\TeX\ fonts do not have this glyph.}
+\endsetslot
+
+\setslot{\lclig{FF}{ff}}
+ \comment{The `ff' ligature. It should be two characters wide in a
+ monowidth font.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{\lc{I}{i}}{\lclig{FFI}{ffi}}
+ \ligature{LIG}{\lc{L}{l}}{\lclig{FFL}{ffl}}
+ \Fi
+\endsetslot
+
+\setslot{\lclig{FFI}{ffi}}
+ \comment{The `ffi' ligature. It should be three characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FFL}{ffl}}
+ \comment{The `ffl' ligature. It should be three characters wide in a
+ monowidth font.}
+\endsetslot
+
+\begincomment
+ \begin{trivlist}\item
+ The following eight slots, 22--29, incorporate glyphs found in
+ MacRoman encoding, in no particular order.
+ \end{trivlist}
+\endcomment
+
+\setslot{notequal}
+ \comment{The `not equal to' symbol `$\neq$'.}
+\endsetslot
+
+\setslot{infinity}
+ \comment{The infinity symbol `$\infty$'.}
+\endsetslot
+
+\setslot{lessequal}
+ \comment{The `less-than or equal to' symbol `$\leq$'.}
+\endsetslot
+
+\setslot{greaterequal}
+ \comment{The `great-than or equal to' symbol `$\geq$'.}
+\endsetslot
+
+\setslot{partialdiff}
+ \comment{The partial differential symbol `$\partial$'.}
+\endsetslot
+
+\setslot{summation}
+ \comment{The $n$-ary summation symbol `$\Sigma$', similar to the greek
+ capital letter sigma.}
+\endsetslot
+
+\setslot{product}
+ \comment{The $n$-ary product symbol `$\Pi$', similar to the greek
+ capital letter pi.}
+\endsetslot
+
+\setslot{pi}
+ \comment{The mathematical constant `$\pi$'.}
+\endsetslot
+
+\setslot{grave}
+ \comment{The grave accent `\`{}'.}
+\endsetslot
+
+\setslot{quotesingle}
+ \comment{The `neutral' single quote mark `\,\textquotesingle\,',
+ included for use in monowidth fonts, or for setting computer
+ programs.}
+\endsetslot
+
+\begincomment
+\subsection{The visible ASCII range}
+The following 96 slots, 32--127, are based on standard ASCII (as
+interpreted in \textit{The \TeX book}).
+\endcomment
+
+\nextslot{32}
+\setslot{space}
+ \comment{The space character.}
+\endsetslot
+
+\setslot{exclam}
+ \comment{The exclamation mark `!'.}
+ \ligature{LIG}{quoteleft}{exclamdown}
+\endsetslot
+
+\setslot{quotedbl}
+ \comment{The `neutral' double quote mark `\,\textquotedbl\,',
+ included for use in monowidth fonts, or for setting computer
+ programs.}
+\endsetslot
+
+\setslot{numbersign}
+ \comment{The hash sign `\#'.}
+\endsetslot
+
+\setslot{dollar}
+ \comment{The dollar sign `\$'.}
+\endsetslot
+
+\setslot{percent}
+ \comment{The percent sign `\%'.}
+\endsetslot
+
+\setslot{ampersand}
+ \comment{The ampersand sign `\&'.}
+\endsetslot
+
+\setslot{quoteright}
+ \comment{The English closing quote mark `\,\textquoteright\,'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{quoteright}{quotedblright}
+ \Fi
+\endsetslot
+
+\setslot{parenleft}
+ \comment{The opening parenthesis `('.}
+\endsetslot
+
+\setslot{parenright}
+ \comment{The closing parenthesis `)'.}
+\endsetslot
+
+\setslot{asterisk}
+ \comment{The raised asterisk `*'.}
+\endsetslot
+
+\setslot{plus}
+ \comment{The addition sign `+'.}
+\endsetslot
+
+\setslot{comma}
+ \comment{The comma `,'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{comma}{quotedblbase}
+ \Fi
+\endsetslot
+
+\setslot{hyphen}
+ \comment{The hyphen `-'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{hyphen}{endash}
+ \Fi
+\endsetslot
+
+\setslot{period}
+ \comment{The period `.'.}
+\endsetslot
+
+\setslot{slash}
+ \comment{The forward oblique `/'.}
+\endsetslot
+
+\setslot{\digit{zero}}
+ \comment{The number `0'. This (and all the other numerals) may be
+ old style or ranging digits.}
+\endsetslot
+
+\setslot{\digit{one}}
+ \comment{The number `1'.}
+\endsetslot
+
+\setslot{\digit{two}}
+ \comment{The number `2'.}
+\endsetslot
+
+\setslot{\digit{three}}
+ \comment{The number `3'.}
+\endsetslot
+
+\setslot{\digit{four}}
+ \comment{The number `4'.}
+\endsetslot
+
+\setslot{\digit{five}}
+ \comment{The number `5'.}
+\endsetslot
+
+\setslot{\digit{six}}
+ \comment{The number `6'.}
+\endsetslot
+
+\setslot{\digit{seven}}
+ \comment{The number `7'.}
+\endsetslot
+
+\setslot{\digit{eight}}
+ \comment{The number `8'.}
+\endsetslot
+
+\setslot{\digit{nine}}
+ \comment{The number `9'.}
+\endsetslot
+
+\setslot{colon}
+ \comment{The colon `:'.}
+\endsetslot
+
+\setslot{semicolon}
+ \comment{The semi-colon `;'.}
+\endsetslot
+
+\setslot{less}
+ \comment{The less-than sign `\textless'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{less}{guillemotleft}
+ \Fi
+\endsetslot
+
+\setslot{equal}
+ \comment{The equals sign `='.}
+\endsetslot
+
+\setslot{greater}
+ \comment{The greater-than sign `\textgreater'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{greater}{guillemotright}
+ \Fi
+\endsetslot
+
+\setslot{question}
+ \comment{The question mark `?'.}
+ \ligature{LIG}{quoteleft}{questiondown}
+\endsetslot
+
+\setslot{at}
+ \comment{The at sign `@'.}
+\endsetslot
+
+\setslot{\uc{A}{a}}
+ \comment{The letter `A'.}
+\endsetslot
+
+\setslot{\uc{B}{b}}
+ \comment{The letter `B'.}
+\endsetslot
+
+\setslot{\uc{C}{c}}
+ \comment{The letter `C'.}
+\endsetslot
+
+\setslot{\uc{D}{d}}
+ \comment{The letter `D'.}
+\endsetslot
+
+\setslot{\uc{E}{e}}
+ \comment{The letter `E'.}
+\endsetslot
+
+\setslot{\uc{F}{f}}
+ \comment{The letter `F'.}
+\endsetslot
+
+\setslot{\uc{G}{g}}
+ \comment{The letter `G'.}
+\endsetslot
+
+\setslot{\uc{H}{h}}
+ \comment{The letter `H'.}
+\endsetslot
+
+\setslot{\uc{I}{i}}
+ \comment{The letter `I'.}
+\endsetslot
+
+\setslot{\uc{J}{j}}
+ \comment{The letter `J'.}
+\endsetslot
+
+\setslot{\uc{K}{k}}
+ \comment{The letter `K'.}
+\endsetslot
+
+\setslot{\uc{L}{l}}
+ \comment{The letter `L'.}
+\endsetslot
+
+\setslot{\uc{M}{m}}
+ \comment{The letter `M'.}
+\endsetslot
+
+\setslot{\uc{N}{n}}
+ \comment{The letter `N'.}
+\endsetslot
+
+\setslot{\uc{O}{o}}
+ \comment{The letter `O'.}
+\endsetslot
+
+\setslot{\uc{P}{p}}
+ \comment{The letter `P'.}
+\endsetslot
+
+\setslot{\uc{Q}{q}}
+ \comment{The letter `Q'.}
+\endsetslot
+
+\setslot{\uc{R}{r}}
+ \comment{The letter `R'.}
+\endsetslot
+
+\setslot{\uc{S}{s}}
+ \comment{The letter `S'.}
+\endsetslot
+
+\setslot{\uc{T}{t}}
+ \comment{The letter `T'.}
+\endsetslot
+
+\setslot{\uc{U}{u}}
+ \comment{The letter `U'.}
+\endsetslot
+
+\setslot{\uc{V}{v}}
+ \comment{The letter `V'.}
+\endsetslot
+
+\setslot{\uc{W}{w}}
+ \comment{The letter `W'.}
+\endsetslot
+
+\setslot{\uc{X}{x}}
+ \comment{The letter `X'.}
+\endsetslot
+
+\setslot{\uc{Y}{y}}
+ \comment{The letter `Y'.}
+\endsetslot
+
+\setslot{\uc{Z}{z}}
+ \comment{The letter `Z'.}
+\endsetslot
+
+\setslot{bracketleft}
+ \comment{The opening square bracket `['.}
+\endsetslot
+
+\setslot{backslash}
+ \comment{The backwards oblique `\textbackslash'.}
+\endsetslot
+
+\setslot{bracketright}
+ \comment{The closing square bracket `]'.}
+\endsetslot
+
+\setslot{asciicircum}
+ \comment{The ASCII upward-pointing arrow head `\textasciicircum'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{underscore}
+ \comment{The ASCII underline character `\textunderscore', usually
+ set on the baseline.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{quoteleft}
+ \comment{The English opening single quote mark `\,\textquoteleft\,'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{quoteleft}{quotedblleft}
+ \Fi
+\endsetslot
+
+\setslot{\lc{A}{a}}
+ \comment{The letter `a'.}
+\endsetslot
+
+\setslot{\lc{B}{b}}
+ \comment{The letter `b'.}
+\endsetslot
+
+\setslot{\lc{C}{c}}
+ \comment{The letter `c'.}
+\endsetslot
+
+\setslot{\lc{D}{d}}
+ \comment{The letter `d'.}
+\endsetslot
+
+\setslot{\lc{E}{e}}
+ \comment{The letter `e'.}
+\endsetslot
+
+\setslot{\lc{F}{f}}
+ \comment{The letter `f'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{\lc{I}{i}}{\lclig{FI}{fi}}
+ \ligature{LIG}{\lc{F}{f}}{\lclig{FF}{ff}}
+ \ligature{LIG}{\lc{L}{l}}{\lclig{FL}{fl}}
+ \Fi
+\endsetslot
+
+\setslot{\lc{G}{g}}
+ \comment{The letter `g'.}
+\endsetslot
+
+\setslot{\lc{H}{h}}
+ \comment{The letter `h'.}
+\endsetslot
+
+\setslot{\lc{I}{i}}
+ \comment{The letter `i'.}
+\endsetslot
+
+\setslot{\lc{J}{j}}
+ \comment{The letter `j'.}
+\endsetslot
+
+\setslot{\lc{K}{k}}
+ \comment{The letter `k'.}
+\endsetslot
+
+\setslot{\lc{L}{l}}
+ \comment{The letter `l'.}
+\endsetslot
+
+\setslot{\lc{M}{m}}
+ \comment{The letter `m'.}
+\endsetslot
+
+\setslot{\lc{N}{n}}
+ \comment{The letter `n'.}
+\endsetslot
+
+\setslot{\lc{O}{o}}
+ \comment{The letter `o'.}
+\endsetslot
+
+\setslot{\lc{P}{p}}
+ \comment{The letter `p'.}
+\endsetslot
+
+\setslot{\lc{Q}{q}}
+ \comment{The letter `q'.}
+\endsetslot
+
+\setslot{\lc{R}{r}}
+ \comment{The letter `r'.}
+\endsetslot
+
+\setslot{\lc{S}{s}}
+ \comment{The letter `s'.}
+\endsetslot
+
+\setslot{\lc{T}{t}}
+ \comment{The letter `t'.}
+\endsetslot
+
+\setslot{\lc{U}{u}}
+ \comment{The letter `u'.}
+\endsetslot
+
+\setslot{\lc{V}{v}}
+ \comment{The letter `v'.}
+\endsetslot
+
+\setslot{\lc{W}{w}}
+ \comment{The letter `w'.}
+\endsetslot
+
+\setslot{\lc{X}{x}}
+ \comment{The letter `x'.}
+\endsetslot
+
+\setslot{\lc{Y}{y}}
+ \comment{The letter `y'.}
+\endsetslot
+
+\setslot{\lc{Z}{z}}
+ \comment{The letter `z'.}
+\endsetslot
+
+\setslot{braceleft}
+ \comment{The opening curly brace `\textbraceleft'.}
+\endsetslot
+
+\setslot{bar}
+ \comment{The ASCII vertical bar `\textbar'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{braceright}
+ \comment{The closing curly brace `\textbraceright'.}
+\endsetslot
+
+\setslot{asciitilde}
+ \comment{The ASCII tilde `\textasciitilde'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\begincomment
+\subsection{The Windows ANSI range}
+The following 32 slots, 128--159, are mostly based on
+Windows ANSI. Slots 129, 141--143, and 157--158 incorporate glyphs
+found in MacRoman encoding, in no particular order.
+\endcomment
+
+\nextslot{128}
+\setslot{Euro}
+ \comment{The European currency sign `\texteuro'.}
+\endsetslot
+
+\setslot{integral}
+ \comment{The integral symbol.}
+\endsetslot
+
+\setslot{quotesinglbase}
+ \comment{A German single quote mark `\quotesinglbase' similar to a comma,
+ but with different sidebearings.}
+\endsetslot
+
+\setslot{florin}
+ \comment{The florin sign, similar to an italic letter `\textflorin'.}
+\endsetslot
+
+\setslot{quotedblbase}
+ \comment{A German double quote mark `\quotedblbase' similar to two commas,
+ but with tighter letterspacing and different sidebearings.}
+\endsetslot
+
+\setslot{ellipsis}
+ \comment{The ellipsis `\textellipsis'.}
+\endsetslot
+
+\setslot{dagger}
+ \comment{The single dagger `\textdagger'.}
+\endsetslot
+
+\setslot{daggerdbl}
+ \comment{The double dagger `\textdaggerdbl'.}
+\endsetslot
+
+\setslot{circumflex}
+ \comment{The circumflex accent `\^{}'.}
+\endsetslot
+
+\setslot{perthousand}
+ \comment{The perthousand sign `\textperthousand',
+ similar to `\%' with an extra zero.}
+\endsetslot
+
+\setslot{\uctop{Scaron}{scaron}}
+ \comment{The letter `\v S'.}
+\endsetslot
+
+\setslot{guilsinglleft}
+ \comment{A French single opening quote mark `\guilsinglleft',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\uc{OE}{oe}}
+ \comment{The letter `\OE'.
+ This is a single letter, and should not be faked with `OE'.}
+\endsetslot
+
+\setslot{Omega}
+ \comment{The greek capital letter omega, the Ohm sign `\textohm'.}
+\endsetslot
+
+\setslot{radical}
+ \comment{The radical sign `\textsurd'.}
+\endsetslot
+
+\setslot{approxequal}
+ \comment{The `approximately equal to' symbol `$\approx$'.}
+\endsetslot
+
+\iffalse
+\nextslot{145}
+\setslot{quoteleft-unused}
+ \comment{The English opening single quote mark `\,\textquoteleft\,'.}
+\endsetslot
+
+\setslot{quoteright-unused}
+ \comment{The English closing single quote mark `\,\textquoteright\,'.}
+\endsetslot
+\fi
+
+\nextslot{147}
+\setslot{quotedblleft}
+ \comment{The English opening double quote mark `\,\textquotedblleft\,'.}
+\endsetslot
+
+\setslot{quotedblright}
+ \comment{The English closing double quote mark `\,\textquotedblright\,'.}
+\endsetslot
+
+\setslot{bullet}
+ \comment{The centered bullet `\textbullet'.}
+\endsetslot
+
+\setslot{endash}
+ \comment{The en-dash `\textendash'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{hyphen}{emdash}
+ \Fi
+\endsetslot
+
+\setslot{emdash}
+ \comment{The em-dash `\textemdash'.}
+\endsetslot
+
+\setslot{tilde}
+ \comment{The tilde accent `\~{}'.}
+\endsetslot
+
+\setslot{trademark}
+ \comment{The trademark sign, similar to the raised letters `TM'.}
+\endsetslot
+
+\setslot{\lctop{Scaron}{scaron}}
+ \comment{The letter `\v s'.}
+\endsetslot
+
+\setslot{guilsinglright}
+ \comment{A French single closing quote mark `\guilsinglright',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lc{OE}{oe}}
+ \comment{The letter `\oe'.
+ This is a single letter, and should not be faked with `oe'.}
+\endsetslot
+
+\setslot{Delta}
+ \comment{The forward difference symbol `$\Delta$' similar to the
+ greek capital letter delta.}
+\endsetslot
+
+\setslot{lozenge}
+ \comment{The lozenge symbol `$\lozenge$'.}
+\endsetslot
+
+\setslot{\uctop{Ydieresis}{ydieresis}}
+ \comment{The letter `\"Y'.}
+\endsetslot
+
+\begincomment
+\subsection{The low ISO latin 1 range}
+The following 32 slots, 160--191, are based on ISO Latin~1,
+which is identical to Windows ANSI in this plane.
+\endcomment
+
+% % This is commented out since the \texttt{8r.enc} encoding vector
+% % does not (at least not currently) place any glyph in this slot.
+%
+% \ifdirect
+% \nextslot{160}
+% \setslot{space}
+% \comment{The (non-breaking) space character.}
+% \endsetslot
+% \Fi
+
+\nextslot{161}
+\setslot{exclamdown}
+ \comment{The Spanish punctuation mark `!`'.}
+\endsetslot
+
+\setslot{cent}
+ \comment{The cent sign `\textcent'.}
+\endsetslot
+
+\setslot{sterling}
+ \comment{The British currency sign, `\textsterling'.}
+\endsetslot
+
+\setslot{currency}
+ \comment{The international currency sign, `\textcurrency'.}
+\endsetslot
+
+\setslot{yen}
+ \comment{The Japanese currency sign, `\textyen'.}
+\endsetslot
+
+\setslot{brokenbar}
+ \comment{A broken vertical bar, `\textbrokenbar',
+ similar to `\textbar' with a gap through the middle.}
+\endsetslot
+
+\setslot{section}
+ \comment{The section mark `\textsection'.}
+\endsetslot
+
+\setslot{dieresis}
+ \comment{The umlaut or dieresis accent `\"{}'.}
+\endsetslot
+
+\setslot{copyright}
+ \comment{The copyright sign `\textcopyright',
+ similar to a small `C' enclosed by a circle.}
+\endsetslot
+
+\setslot{ordfeminine}
+ \comment{The raised letter `\textordfeminine'.}
+\endsetslot
+
+\setslot{guillemotleft}
+ \comment{A French double opening quote mark `\guillemotleft',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{logicalnot}
+ \comment{The logical not sign `\textlnot'.}
+\endsetslot
+
+\ifdirect
+
+\setslot{hyphen}
+ \comment{\texttt{8r.enc} puts \texttt{hyphen} in this slot as
+ well, because it is the position of the latin-1 ``soft
+ hyphen''.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{hyphen}{endash}
+ \Fi
+\endsetslot
+
+\Fi
+
+\nextslot{174}
+\setslot{registered}
+ \comment{The registered trademark sign `\textregistered',
+ similar to a small `R' enclosed by a circle.}
+\endsetslot
+
+\setslot{macron}
+ \comment{The macron accent `\={}'.}
+\endsetslot
+
+\setslot{degree}
+ \comment{The degree sign `\textdegree'.}
+\endsetslot
+
+\setslot{plusminus}
+ \comment{The plus or minus sign `\textpm'.}
+\endsetslot
+
+\setslot{twosuperior}
+ \comment{The raised digit `\texttwosuperior'.}
+\endsetslot
+
+\setslot{threesuperior}
+ \comment{The raised digit `\textthreesuperior'.}
+\endsetslot
+
+\setslot{acute}
+ \comment{The acute accent `\'{}'.}
+\endsetslot
+
+\setslot{mu}
+ \comment{The lowercase Greek letter `\textmu', intended
+ for use as a prefix `micro' in physical units.}
+\endsetslot
+
+\setslot{paragraph}
+ \comment{The paragraph mark `\textparagraph'.}
+\endsetslot
+
+\setslot{periodcentered}
+ \comment{The centered period `\textperiodcentered'.}
+\endsetslot
+
+\setslot{cedilla}
+ \comment{The cedilla accent `\c{}'.}
+\endsetslot
+
+\setslot{onesuperior}
+ \comment{The raised digit `\textonesuperior'.}
+\endsetslot
+
+\setslot{ordmasculine}
+ \comment{The raised letter `\textordmasculine'.}
+\endsetslot
+
+\setslot{guillemotright}
+ \comment{A French double closing quote mark `\guillemotright',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{onequarter}
+ \comment{The fraction `\textonequarter'.}
+\endsetslot
+
+\setslot{onehalf}
+ \comment{The fraction `\textonehalf'.}
+\endsetslot
+
+\setslot{threequarters}
+ \comment{The fraction `\textthreequarters'.}
+\endsetslot
+
+\setslot{questiondown}
+ \comment{The Spanish punctuation mark `?`'.}
+\endsetslot
+
+\begincomment
+\subsection{The high ISO latin 1 range}
+The remaining 64 slots, 192--255, are again based on ISO Latin~1.
+\endcomment
+
+\nextslot{192}
+\setslot{\uctop{Agrave}{agrave}}
+ \comment{The letter `\`A'.}
+\endsetslot
+
+\setslot{\uctop{Aacute}{aacute}}
+ \comment{The letter `\'A'.}
+\endsetslot
+
+\setslot{\uctop{Acircumflex}{acircumflex}}
+ \comment{The letter `\^A'.}
+\endsetslot
+
+\setslot{\uctop{Atilde}{atilde}}
+ \comment{The letter `\~A'.}
+\endsetslot
+
+\setslot{\uctop{Adieresis}{adieresis}}
+ \comment{The letter `\"A'.}
+\endsetslot
+
+\setslot{\uctop{Aring}{aring}}
+ \comment{The letter `\AA'.}
+\endsetslot
+
+\setslot{\uc{AE}{ae}}
+ \comment{The letter `\AE'.
+ This is a single letter, and should not be faked with `AE'.}
+\endsetslot
+
+\setslot{\uc{Ccedilla}{ccedilla}}
+ \comment{The letter `\c C'.}
+\endsetslot
+
+\setslot{\uctop{Egrave}{egrave}}
+ \comment{The letter `\`E'.}
+\endsetslot
+
+\setslot{\uctop{Eacute}{eacute}}
+ \comment{The letter `\'E'.}
+\endsetslot
+
+\setslot{\uctop{Ecircumflex}{ecircumflex}}
+ \comment{The letter `\^E'.}
+\endsetslot
+
+\setslot{\uctop{Edieresis}{edieresis}}
+ \comment{The letter `\"E'.}
+\endsetslot
+
+\setslot{\uctop{Igrave}{igrave}}
+ \comment{The letter `\`I'.}
+\endsetslot
+
+\setslot{\uctop{Iacute}{iacute}}
+ \comment{The letter `\'I'.}
+\endsetslot
+
+\setslot{\uctop{Icircumflex}{icircumflex}}
+ \comment{The letter `\^I'.}
+\endsetslot
+
+\setslot{\uctop{Idieresis}{idieresis}}
+ \comment{The letter `\"I'.}
+\endsetslot
+
+\setslot{\uc{Eth}{eth}}
+ \comment{The Icelandic capital letter `Eth' similar to a `D'
+ with a horizontal bar through the stem. It is unavailable
+ in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\uctop{Ntilde}{ntilde}}
+ \comment{The letter `\~N'.}
+\endsetslot
+
+\setslot{\uctop{Ograve}{ograve}}
+ \comment{The letter `\`O'.}
+\endsetslot
+
+\setslot{\uctop{Oacute}{oacute}}
+ \comment{The letter `\'O'.}
+\endsetslot
+
+\setslot{\uctop{Ocircumflex}{ocircumflex}}
+ \comment{The letter `\^O'.}
+\endsetslot
+
+\setslot{\uctop{Otilde}{otilde}}
+ \comment{The letter `\~O'.}
+\endsetslot
+
+\setslot{\uctop{Odieresis}{odieresis}}
+ \comment{The letter `\"O'.}
+\endsetslot
+
+\setslot{multiply}
+ \comment{The multiplication sign `\texttimes'.}
+\endsetslot
+
+\setslot{\uc{Oslash}{oslash}}
+ \comment{The letter `\O'.}
+\endsetslot
+
+\setslot{\uctop{Ugrave}{ugrave}}
+ \comment{The letter `\`U'.}
+\endsetslot
+
+\setslot{\uctop{Uacute}{uacute}}
+ \comment{The letter `\'U'.}
+\endsetslot
+
+\setslot{\uctop{Ucircumflex}{ucircumflex}}
+ \comment{The letter `\^U'.}
+\endsetslot
+
+\setslot{\uctop{Udieresis}{udieresis}}
+ \comment{The letter `\"U'.}
+\endsetslot
+
+\setslot{\uctop{Yacute}{yacute}}
+ \comment{The letter `\'Y'.}
+\endsetslot
+
+\setslot{\uc{Thorn}{thorn}}
+ \comment{The Icelandic capital letter `Thorn', similar to a `P'
+ with the bowl moved down. It is unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lc{SS}{germandbls}}
+ \comment{The letter `\ss'.}
+\endsetslot
+
+\setslot{\lctop{Agrave}{agrave}}
+ \comment{The letter `\`a'.}
+\endsetslot
+
+\setslot{\lctop{Aacute}{aacute}}
+ \comment{The letter `\'a'.}
+\endsetslot
+
+\setslot{\lctop{Acircumflex}{acircumflex}}
+ \comment{The letter `\^a'.}
+\endsetslot
+
+\setslot{\lctop{Atilde}{atilde}}
+ \comment{The letter `\~a'.}
+\endsetslot
+
+\setslot{\lctop{Adieresis}{adieresis}}
+ \comment{The letter `\"a'.}
+\endsetslot
+
+\setslot{\lctop{Aring}{aring}}
+ \comment{The letter `\aa'.}
+\endsetslot
+
+\setslot{\lc{AE}{ae}}
+ \comment{The letter `\ae'.
+ This is a single letter, and should not be faked with `ae'.}
+\endsetslot
+
+\setslot{\lc{Ccedilla}{ccedilla}}
+ \comment{The letter `\c c'.}
+\endsetslot
+
+\setslot{\lctop{Egrave}{egrave}}
+ \comment{The letter `\`e'.}
+\endsetslot
+
+\setslot{\lctop{Eacute}{eacute}}
+ \comment{The letter `\'e'.}
+\endsetslot
+
+\setslot{\lctop{Ecircumflex}{ecircumflex}}
+ \comment{The letter `\^e'.}
+\endsetslot
+
+\setslot{\lctop{Edieresis}{edieresis}}
+ \comment{The letter `\"e'.}
+\endsetslot
+
+\setslot{\lctop{Igrave}{igrave}}
+ \comment{The letter `\`\i'.}
+\endsetslot
+
+\setslot{\lctop{Iacute}{iacute}}
+ \comment{The letter `\'\i'.}
+\endsetslot
+
+\setslot{\lctop{Icircumflex}{icircumflex}}
+ \comment{The letter `\^\i'.}
+\endsetslot
+
+\setslot{\lctop{Idieresis}{idieresis}}
+ \comment{The letter `\"\i'.}
+\endsetslot
+
+\setslot{\lc{Eth}{eth}}
+ \comment{The Icelandic lowercase letter `eth' similar to a
+ `$\partial$' with an oblique bar through the stem. It is
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lctop{Ntilde}{ntilde}}
+ \comment{The letter `\~n'.}
+\endsetslot
+
+\setslot{\lctop{Ograve}{ograve}}
+ \comment{The letter `\`o'.}
+\endsetslot
+
+\setslot{\lctop{Oacute}{oacute}}
+ \comment{The letter `\'o'.}
+\endsetslot
+
+\setslot{\lctop{Ocircumflex}{ocircumflex}}
+ \comment{The letter `\^o'.}
+\endsetslot
+
+\setslot{\lctop{Otilde}{otilde}}
+ \comment{The letter `\~o'.}
+\endsetslot
+
+\setslot{\lctop{Odieresis}{odieresis}}
+ \comment{The letter `\"o'.}
+\endsetslot
+
+\setslot{divide}
+ \comment{The division sign `\textdiv'.}
+\endsetslot
+
+\setslot{\lc{Oslash}{oslash}}
+ \comment{The letter `\o'.}
+\endsetslot
+
+\setslot{\lctop{Ugrave}{ugrave}}
+ \comment{The letter `\`u'.}
+\endsetslot
+
+\setslot{\lctop{Uacute}{uacute}}
+ \comment{The letter `\'u'.}
+\endsetslot
+
+\setslot{\lctop{Ucircumflex}{ucircumflex}}
+ \comment{The letter `\^u'.}
+\endsetslot
+
+\setslot{\lctop{Udieresis}{udieresis}}
+ \comment{The letter `\"u'.}
+\endsetslot
+
+\setslot{\lctop{Yacute}{yacute}}
+ \comment{The letter `\'y'.}
+\endsetslot
+
+\setslot{\lc{Thorn}{thorn}}
+ \comment{The Icelandic lowercase letter `thorn', similar to a `p'
+ with an ascender rising from the stem. It is unavailable
+ in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lctop{Ydieresis}{ydieresis}}
+ \comment{The letter `\"y'.}
+\endsetslot
+
+\endencoding
+
+
+\section{The basis for the design of this encoding}
+
+The idea is to have all the characters normally included in Type 1 fonts
+available for typesetting. This is effectively the characters in Adobe
+Standard encoding, ISO Latin 1, Windows ANSI including the \texttt{euro}
+symbol, MacRoman, and some extra characters from Lucida.
+
+Character code assignments were made as follows:
+\begin{enumerate}
+ \item
+ the Windows ANSI characters are almost all in their Windows ANSI
+ positions, because some Windows users cannot easily reencode the
+ fonts, and it makes no difference on other systems. The only
+ Windows ANSI characters not available are those that make no sense
+ for typesetting---\texttt{rubout} (127~decimal),
+ \texttt{nobreakspace}~(160), \texttt{softhyphen}~(173).
+ \texttt{quotesingle} and \texttt{grave} are moved just because
+ it's such an irritation not having them in TeX positions.
+ \item
+ Remaining characters are assigned arbitrarily to the lower part
+ of the range, avoiding 0, 10 and 13 in case we meet dumb software.
+ \item
+ Y\&Y Lucida Bright includes some extra text characters; in the
+ hopes that other PostScript fonts, perhaps created for public
+ consumption, will include them, they are included starting at 0x12.
+ These are \texttt{dotlessj}, \texttt{ff}, \texttt{ffi},
+ \texttt{ffl}.
+ \item
+ \texttt{hyphen} appears twice for compatibility with both ASCII
+ and Windows.
+ \item
+ \texttt{Euro} was assigned to 128, as in Windows ANSI.
+ \item
+ Missing characters from MacRoman encoding incorporated as
+ follows:
+ \begin{center}
+ \small
+ \begin{tabular}{lrr}
+ \textbf{Glyph}& \textbf{MacRoman}& \textbf{TeXBase1}\\
+ \texttt{notequal}& 173& 22\\
+ \texttt{infinity}& 176& 23\\
+ \texttt{lessequal}& 178& 24\\
+ \texttt{greaterequal}& 179& 25\\
+ \texttt{partialdiff}& 182& 26\\
+ \texttt{summation}& 183& 27\\
+ \texttt{product}& 184& 28\\
+ \texttt{pi}& 185& 29\\
+ \texttt{integral}& 186& 129\\
+ \texttt{Omega}& 189& 141\\
+ \texttt{radical}& 195& 142\\
+ \texttt{approxequal}& 197& 143\\
+ \texttt{Delta}& 198& 157\\
+ \texttt{lozenge}& 215& 158
+ \end{tabular}
+ \end{center}
+\end{enumerate}
+
+
+
+\section{Changes}
+
+1995/03/19: The `\texttt{softhyphen}' is back; now called
+`\texttt{alternate-hyphen}' and has \verb|\ligature| commands. In
+`\texttt{hyphen}' slot \verb|\ligature| $\mapsto$ `\texttt{rangedash}'
+changed to `\texttt{endash}'. (ASAJ)
+
+1995/04/03: Changed around the order of some characters at start
+(to avoid 0, 10 and 13, and reposition \texttt{quoteleft} and
+\texttt{quoteright}). (ASAJ)
+
+1995/08/03: Interword stretch and shrink [again!]. (ASAJ)
+
+1998/06/29: Major update of comments and markup; made it a
+proper \LaTeXe\ document, using \texttt{T1} and \texttt{TS1} encoded
+fonts for giving examples of glyphs, and added descriptions for
+numerous slots. Lowercasified names of accents---removed uses of
+\verb|\lc| in \verb|\setslot|s for accents. (UV)
+
+2002/03/11: Added `\texttt{Euro}' in slot 128. (WaS)
+
+2002/10/30: New symbols incorporated from MacRoman. (Philipp Lehman)
+
+2002/11/12: Added \verb|\showbranches| markup. Modernised setting of
+fontdimens. (LH)
+
+2003/02/04: Introduced the \textit{ligaturing} integer for control of
+ whether ligatures are made. (LH)
+
+2003/02/09: Made use of \verb|\ifdirect| to clear up the situation
+ with \texttt{alternate-hyphen}. It is now included under the proper
+ name \texttt{hyphen}, but is ignored when reencoding. (LH)
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/latinetx/8y.etx b/fonts/utilities/fontinst/inputs/latinetx/8y.etx
new file mode 100644
index 0000000000..d84921a545
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/8y.etx
@@ -0,0 +1,1305 @@
+% Copyright 1998, 1999, 2003, 2004 the fontinst maintenance team
+% and any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Ulrik Vieth and Lars Hellstr{\"o}m",
+%%% version = "1.928",
+%%% date = "2004-09-24",
+%%% time = "21:21:00 +01:00",
+%%% filename = "8y.etx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, raw, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the 8y encoding as a TeX font encoding
+%%% file, for use with the fontinst utility.
+%%% It implements the TeXnANSI (or LY1) encoding
+%%% proposed and promoted by Y&Y.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+% Changes list at end of file.
+
+\documentclass[twocolumn]{article}
+\usepackage[TS1,T1]{fontenc}
+\usepackage{textcomp}
+\usepackage{fontdoc}[2003/02/09]
+
+\title{The \TeX'n'ANSI encoding vector}
+\author{Ulrik Vieth\and Lars Hellstr\"om}
+\date{13 September 2004\\Version 1.928}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the \TeX'n'ANSI encoding vector proposed
+by Y\&Y, which is represented by the \texttt{LY1} encoding in \LaTeXe.
+
+It is almost identical to the \TeX{}Base1 encoding (defined in
+\texttt{8r.etx}) in the range 32--126 and 161--255. It is similar
+to \texttt{8r.etx} in the range 127--160, but contains additional
+characters, which are stored elsewhere in \texttt{8r.etx}.
+
+\showbranches
+\encoding
+
+\needsfontinstversion{1.924}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lctop#1#2{#2}
+\setcommand\uctop#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\ifisglyph{space}\then
+ \setint{interword}{\width{space}}
+\Else\ifisglyph{i}\then
+ \setint{interword}{\width{i}}
+\Else
+ \setint{interword}{333}
+\Fi\Fi
+
+\ifisint{monowidth}\then
+ \setint{stretchword}{0}
+ \setint{shrinkword}{0}
+ \setint{extraspace}{\int{interword}}
+ \setint{ligaturing}{0}
+\Else
+ \setint{stretchword}{\scale{\int{interword}}{600}}
+ \setint{shrinkword}{\scale{\int{interword}}{240}}
+ \setint{extraspace}{\scale{\int{interword}}{240}}
+ \setint{ligaturing}{1}
+\Fi
+\setint{quad}{1000}
+
+
+\begincomment
+\section{Font parameters}
+\endcomment
+
+\setstr{codingscheme}{TEX TYPEWRITER AND WINDOWS ANSI}
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+
+\begincomment
+\section{The encoding}
+
+\subsection{Low ASCII control characters}
+
+The layout of the first 16 slots wase carefully chosen to avoid
+potentially dangerous slots 0 (NUL), 9 (HT), 10 (LF) and 13 (CR).
+\endcomment
+
+\nextslot{1}
+\setslot{Euro}
+ \comment{The Euro currency sign.}
+\endsetslot
+
+\nextslot{4}
+\setslot{fraction}
+ \comment{The fraction slash `\textfractionsolidus'.}
+\endsetslot
+
+\setslot{dotaccent}
+ \comment{The dot accent `\.{}'.}
+\endsetslot
+
+\setslot{hungarumlaut}
+ \comment{The long Hungarian umlaut `\H{}'.}
+\endsetslot
+
+\setslot{ogonek}
+ \comment{The ogonek accent `\k{}'.}
+\endsetslot
+
+\setslot{\lclig{FL}{fl}}
+ \comment{The `fl' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\nextslot{11}
+\setslot{\lclig{FF}{ff}}
+ \comment{The `ff' ligature. It should be two characters wide in a
+ monowidth font.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{\lc{I}{i}}{\lclig{FFI}{ffi}}
+ \ligature{LIG}{\lc{L}{l}}{\lclig{FFL}{ffl}}
+ \Fi
+\endsetslot
+
+\setslot{\lclig{FI}{fi}}
+ \comment{The `fi' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\nextslot{14}
+\setslot{\lclig{FFI}{ffi}}
+ \comment{The `ffi' ligature. It should be three characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FFL}{ffl}}
+ \comment{The `ffl' ligature. It should be three characters wide in a
+ monowidth font.}
+\endsetslot
+
+\begincomment
+\subsection{The \texttt{OT1} compatibility range}
+The following 16 slots share the same encoding as \texttt{OT1}.
+\endcomment
+
+\nextslot{16}
+\setslot{\lc{dotlessI}{dotlessi}}
+ \comment{A dotless i `\i', used to produce accented letters such as
+ `\=\i'.}
+\endsetslot
+
+\setslot{\lc{dotlessJ}{dotlessj}}
+ \comment{A dotless j `\j', used to produce accented letters such as
+ `\=\j'. Most non-\TeX\ fonts do not have this glyph.}
+\endsetslot
+
+\setslot{grave}
+ \comment{The grave accent `\`{}'.}
+\endsetslot
+
+\setslot{acute}
+ \comment{The acute accent `\'{}'.}
+\endsetslot
+
+\setslot{caron}
+ \comment{The caron or h\'a\v cek accent `\v {}'.}
+\endsetslot
+
+\setslot{breve}
+ \comment{The breve accent `\u{}'.}
+\endsetslot
+
+\setslot{macron}
+ \comment{The macron accent `\={}'.}
+\endsetslot
+
+\setslot{ring}
+ \comment{The ring accent `\r{}'.}
+\endsetslot
+
+\setslot{cedilla}
+ \comment{The cedilla accent `\c{}'.}
+\endsetslot
+
+\ifdirect
+
+\setslot{\lc{SS}{germandbls}}
+ \comment{The letter `\ss'.}
+\endsetslot
+
+\setslot{\lc{AE}{ae}}
+ \comment{The letter `\ae'.
+ This is a single letter, and should not be faked with `ae'.}
+\endsetslot
+
+\setslot{\lc{OE}{oe}}
+ \comment{The letter `\oe'.
+ This is a single letter, and should not be faked with `oe'.}
+\endsetslot
+
+\setslot{\lc{Oslash}{oslash}}
+ \comment{The letter `\o'.}
+\endsetslot
+
+\setslot{\uc{AE}{ae}}
+ \comment{The letter `\AE'.
+ This is a single letter, and should not be faked with `AE'.}
+\endsetslot
+
+\setslot{\uc{OE}{oe}}
+ \comment{The letter `\OE'.
+ This is a single letter, and should not be faked with `OE'.}
+\endsetslot
+
+\setslot{\uc{Oslash}{oslash}}
+ \comment{The letter `\O'.}
+\endsetslot
+
+\Fi
+
+\begincomment
+\subsection{The visible ASCII range}
+The following 96 slots, 32--127, are based on standard ASCII,
+except that `\texttt{asciicircum}', `\texttt{asciitilde}', and the
+empty slot 127 have been replaced by the `\texttt{circumflex}',
+`\texttt{tilde}' and `\texttt{dieresis}' as in \texttt{OT1}.
+\endcomment
+
+\nextslot{32}
+\setslot{space}
+ \comment{The space character.}
+\endsetslot
+
+\setslot{exclam}
+ \comment{The exclamation mark `!'.}
+ \ligature{LIG}{quoteleft}{exclamdown}
+\endsetslot
+
+\setslot{quotedbl}
+ \comment{The `neutral' double quote mark `\,\textquotedbl\,',
+ included for use in monowidth fonts, or for setting computer
+ programs.}
+\endsetslot
+
+\setslot{numbersign}
+ \comment{The hash sign `\#'.}
+\endsetslot
+
+\setslot{dollar}
+ \comment{The dollar sign `\$'.}
+\endsetslot
+
+\setslot{percent}
+ \comment{The percent sign `\%'.}
+\endsetslot
+
+\setslot{ampersand}
+ \comment{The ampersand sign `\&'.}
+\endsetslot
+
+\setslot{quoteright}
+ \comment{The English closing quote mark `\,\textquoteright\,'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{quoteright}{quotedblright}
+ \Fi
+\endsetslot
+
+\setslot{parenleft}
+ \comment{The opening parenthesis `('.}
+\endsetslot
+
+\setslot{parenright}
+ \comment{The closing parenthesis `)'.}
+\endsetslot
+
+\setslot{asterisk}
+ \comment{The raised asterisk `*'.}
+\endsetslot
+
+\setslot{plus}
+ \comment{The addition sign `+'.}
+\endsetslot
+
+\setslot{comma}
+ \comment{The comma `,'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{comma}{quotedblbase}
+ \Fi
+\endsetslot
+
+\setslot{hyphen}
+ \comment{The hyphen `-'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{hyphen}{endash}
+ \Fi
+\endsetslot
+
+\setslot{period}
+ \comment{The period `.'.}
+\endsetslot
+
+\setslot{slash}
+ \comment{The forward oblique `/'.}
+\endsetslot
+
+\setslot{\digit{zero}}
+ \comment{The number `0'. This (and all the other numerals) may be
+ old style or ranging digits.}
+\endsetslot
+
+\setslot{\digit{one}}
+ \comment{The number `1'.}
+\endsetslot
+
+\setslot{\digit{two}}
+ \comment{The number `2'.}
+\endsetslot
+
+\setslot{\digit{three}}
+ \comment{The number `3'.}
+\endsetslot
+
+\setslot{\digit{four}}
+ \comment{The number `4'.}
+\endsetslot
+
+\setslot{\digit{five}}
+ \comment{The number `5'.}
+\endsetslot
+
+\setslot{\digit{six}}
+ \comment{The number `6'.}
+\endsetslot
+
+\setslot{\digit{seven}}
+ \comment{The number `7'.}
+\endsetslot
+
+\setslot{\digit{eight}}
+ \comment{The number `8'.}
+\endsetslot
+
+\setslot{\digit{nine}}
+ \comment{The number `9'.}
+\endsetslot
+
+\setslot{colon}
+ \comment{The colon `:'.}
+\endsetslot
+
+\setslot{semicolon}
+ \comment{The semi-colon `;'.}
+\endsetslot
+
+\setslot{less}
+ \comment{The less-than sign `\textless'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{less}{guillemotleft}
+ \Fi
+\endsetslot
+
+\setslot{equal}
+ \comment{The equals sign `='.}
+\endsetslot
+
+\setslot{greater}
+ \comment{The greater-than sign `\textgreater'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{greater}{guillemotright}
+ \Fi
+\endsetslot
+
+\setslot{question}
+ \comment{The question mark `?'.}
+ \ligature{LIG}{quoteleft}{questiondown}
+\endsetslot
+
+\setslot{at}
+ \comment{The at sign `@'.}
+\endsetslot
+
+\setslot{\uc{A}{a}}
+ \comment{The letter `A'.}
+\endsetslot
+
+\setslot{\uc{B}{b}}
+ \comment{The letter `B'.}
+\endsetslot
+
+\setslot{\uc{C}{c}}
+ \comment{The letter `C'.}
+\endsetslot
+
+\setslot{\uc{D}{d}}
+ \comment{The letter `D'.}
+\endsetslot
+
+\setslot{\uc{E}{e}}
+ \comment{The letter `E'.}
+\endsetslot
+
+\setslot{\uc{F}{f}}
+ \comment{The letter `F'.}
+\endsetslot
+
+\setslot{\uc{G}{g}}
+ \comment{The letter `G'.}
+\endsetslot
+
+\setslot{\uc{H}{h}}
+ \comment{The letter `H'.}
+\endsetslot
+
+\setslot{\uc{I}{i}}
+ \comment{The letter `I'.}
+\endsetslot
+
+\setslot{\uc{J}{j}}
+ \comment{The letter `J'.}
+\endsetslot
+
+\setslot{\uc{K}{k}}
+ \comment{The letter `K'.}
+\endsetslot
+
+\setslot{\uc{L}{l}}
+ \comment{The letter `L'.}
+\endsetslot
+
+\setslot{\uc{M}{m}}
+ \comment{The letter `M'.}
+\endsetslot
+
+\setslot{\uc{N}{n}}
+ \comment{The letter `N'.}
+\endsetslot
+
+\setslot{\uc{O}{o}}
+ \comment{The letter `O'.}
+\endsetslot
+
+\setslot{\uc{P}{p}}
+ \comment{The letter `P'.}
+\endsetslot
+
+\setslot{\uc{Q}{q}}
+ \comment{The letter `Q'.}
+\endsetslot
+
+\setslot{\uc{R}{r}}
+ \comment{The letter `R'.}
+\endsetslot
+
+\setslot{\uc{S}{s}}
+ \comment{The letter `S'.}
+\endsetslot
+
+\setslot{\uc{T}{t}}
+ \comment{The letter `T'.}
+\endsetslot
+
+\setslot{\uc{U}{u}}
+ \comment{The letter `U'.}
+\endsetslot
+
+\setslot{\uc{V}{v}}
+ \comment{The letter `V'.}
+\endsetslot
+
+\setslot{\uc{W}{w}}
+ \comment{The letter `W'.}
+\endsetslot
+
+\setslot{\uc{X}{x}}
+ \comment{The letter `X'.}
+\endsetslot
+
+\setslot{\uc{Y}{y}}
+ \comment{The letter `Y'.}
+\endsetslot
+
+\setslot{\uc{Z}{z}}
+ \comment{The letter `Z'.}
+\endsetslot
+
+\setslot{bracketleft}
+ \comment{The opening square bracket `['.}
+\endsetslot
+
+\setslot{backslash}
+ \comment{The backwards oblique `\textbackslash'.}
+\endsetslot
+
+\setslot{bracketright}
+ \comment{The closing square bracket `]'.}
+\endsetslot
+
+\setslot{circumflex}
+ \comment{The circumflex accent `\^{}'.}
+\endsetslot
+
+\setslot{underscore}
+ \comment{The ASCII underline character `\textunderscore', usually
+ set on the baseline.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{quoteleft}
+ \comment{The English opening single quote mark `\,\textquoteleft\,'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{quoteleft}{quotedblleft}
+ \Fi
+\endsetslot
+
+\setslot{\lc{A}{a}}
+ \comment{The letter `a'.}
+\endsetslot
+
+\setslot{\lc{B}{b}}
+ \comment{The letter `b'.}
+\endsetslot
+
+\setslot{\lc{C}{c}}
+ \comment{The letter `c'.}
+\endsetslot
+
+\setslot{\lc{D}{d}}
+ \comment{The letter `d'.}
+\endsetslot
+
+\setslot{\lc{E}{e}}
+ \comment{The letter `e'.}
+\endsetslot
+
+\setslot{\lc{F}{f}}
+ \comment{The letter `f'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{\lc{I}{i}}{\lclig{FI}{fi}}
+ \ligature{LIG}{\lc{F}{f}}{\lclig{FF}{ff}}
+ \ligature{LIG}{\lc{L}{l}}{\lclig{FL}{fl}}
+ \Fi
+\endsetslot
+
+\setslot{\lc{G}{g}}
+ \comment{The letter `g'.}
+\endsetslot
+
+\setslot{\lc{H}{h}}
+ \comment{The letter `h'.}
+\endsetslot
+
+\setslot{\lc{I}{i}}
+ \comment{The letter `i'.}
+\endsetslot
+
+\setslot{\lc{J}{j}}
+ \comment{The letter `j'.}
+\endsetslot
+
+\setslot{\lc{K}{k}}
+ \comment{The letter `k'.}
+\endsetslot
+
+\setslot{\lc{L}{l}}
+ \comment{The letter `l'.}
+\endsetslot
+
+\setslot{\lc{M}{m}}
+ \comment{The letter `m'.}
+\endsetslot
+
+\setslot{\lc{N}{n}}
+ \comment{The letter `n'.}
+\endsetslot
+
+\setslot{\lc{O}{o}}
+ \comment{The letter `o'.}
+\endsetslot
+
+\setslot{\lc{P}{p}}
+ \comment{The letter `p'.}
+\endsetslot
+
+\setslot{\lc{Q}{q}}
+ \comment{The letter `q'.}
+\endsetslot
+
+\setslot{\lc{R}{r}}
+ \comment{The letter `r'.}
+\endsetslot
+
+\setslot{\lc{S}{s}}
+ \comment{The letter `s'.}
+\endsetslot
+
+\setslot{\lc{T}{t}}
+ \comment{The letter `t'.}
+\endsetslot
+
+\setslot{\lc{U}{u}}
+ \comment{The letter `u'.}
+\endsetslot
+
+\setslot{\lc{V}{v}}
+ \comment{The letter `v'.}
+\endsetslot
+
+\setslot{\lc{W}{w}}
+ \comment{The letter `w'.}
+\endsetslot
+
+\setslot{\lc{X}{x}}
+ \comment{The letter `x'.}
+\endsetslot
+
+\setslot{\lc{Y}{y}}
+ \comment{The letter `y'.}
+\endsetslot
+
+\setslot{\lc{Z}{z}}
+ \comment{The letter `z'.}
+\endsetslot
+
+\setslot{braceleft}
+ \comment{The opening curly brace `\textbraceleft'.}
+\endsetslot
+
+\setslot{bar}
+ \comment{The ASCII vertical bar `\textbar'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{braceright}
+ \comment{The closing curly brace `\textbraceright'.}
+\endsetslot
+
+\setslot{tilde}
+ \comment{The tilde accent `\~{}'.}
+\endsetslot
+
+\setslot{dieresis}
+ \comment{The umlaut or dieresis accent `\"{}'.}
+\endsetslot
+
+\begincomment
+\subsection{The Windows ANSI range}
+The following 32 slots, 128--159, are based on an extended
+version of Windows ANSI.
+\endcomment
+
+\nextslot{128}
+\setslot{\uc{Lslash}{lslash}}
+ \comment{The letter `\L'.}
+\endsetslot
+
+\setslot{quotesingle}
+ \comment{The `neutral' single quote mark `\,\textquotesingle\,',
+ included for use in monowidth fonts, or for setting computer
+ programs.}
+\endsetslot
+
+\setslot{quotesinglbase}
+ \comment{A German single quote mark `\quotesinglbase' similar to a comma,
+ but with different sidebearings.}
+\endsetslot
+
+\setslot{florin}
+ \comment{The florin sign, similar to an italic letter `\textflorin'.}
+\endsetslot
+
+\setslot{quotedblbase}
+ \comment{A German double quote mark `\quotedblbase' similar to two commas,
+ but with tighter letterspacing and different sidebearings.}
+\endsetslot
+
+\setslot{ellipsis}
+ \comment{The ellipsis `\textellipsis'.}
+\endsetslot
+
+\setslot{dagger}
+ \comment{The single dagger `\textdagger'.}
+\endsetslot
+
+\setslot{daggerdbl}
+ \comment{The double dagger `\textdaggerdbl'.}
+\endsetslot
+
+\setslot{circumflex}
+ \comment{The circumflex accent `\^{}'.}
+\endsetslot
+
+\setslot{perthousand}
+ \comment{The perthousand sign `\textperthousand',
+ similar to `\%' with an extra zero.}
+\endsetslot
+
+\setslot{\uctop{Scaron}{scaron}}
+ \comment{The letter `\v S'.}
+\endsetslot
+
+\setslot{guilsinglleft}
+ \comment{A French single opening quote mark `\guilsinglleft',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\uc{OE}{oe}}
+ \comment{The letter `\OE'.
+ This is a single letter, and should not be faked with `OE'.}
+\endsetslot
+
+\setslot{\uctop{Zcaron}{zcaron}}
+ \comment{The letter `\v Z'.}
+\endsetslot
+
+\setslot{asciicircum}
+ \comment{The ASCII upward-pointing arrow head `\textasciicircum'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{minus}
+ \comment{The subtraction sign `\textminus'.}
+\endsetslot
+
+\setslot{\lc{Lslash}{lslash}}
+ \comment{The letter `\l'.}
+\endsetslot
+
+\ifdirect
+
+\nextslot{145}
+\setslot{quoteleft}
+ \comment{The English opening single quote mark `\,\textquoteleft\,'.}
+\endsetslot
+
+\setslot{quoteright}
+ \comment{The English closing single quote mark `\,\textquoteright\,'.}
+\endsetslot
+
+\Fi
+
+\nextslot{147}
+\setslot{quotedblleft}
+ \comment{The English opening double quote mark `\,\textquotedblleft\,'.}
+\endsetslot
+
+\setslot{quotedblright}
+ \comment{The English closing double quote mark `\,\textquotedblright\,'.}
+\endsetslot
+
+\setslot{bullet}
+ \comment{The centered bullet `\textbullet'.}
+\endsetslot
+
+\setslot{endash}
+ \comment{The en-dash `\textendash'.}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{hyphen}{emdash}
+ \Fi
+\endsetslot
+
+\setslot{emdash}
+ \comment{The em-dash `\textemdash'.}
+\endsetslot
+
+\setslot{tilde}
+ \comment{The tilde accent `\~{}'.}
+\endsetslot
+
+\setslot{trademark}
+ \comment{The trademark sign, similar to the raised letters `TM'.}
+\endsetslot
+
+\setslot{\lctop{Scaron}{scaron}}
+ \comment{The letter `\v s'.}
+\endsetslot
+
+\setslot{guilsinglright}
+ \comment{A French single closing quote mark `\guilsinglright',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lc{OE}{oe}}
+ \comment{The letter `\oe'.
+ This is a single letter, and should not be faked with `oe'.}
+\endsetslot
+
+\setslot{\lctop{Zcaron}{zcaron}}
+ \comment{The letter `\v z'.}
+\endsetslot
+
+\setslot{asciitilde}
+ \comment{The ASCII tilde `\textasciitilde'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{\uctop{Ydieresis}{ydieresis}}
+ \comment{The letter `\"Y'.}
+\endsetslot
+
+\begincomment
+\subsection{The low ISO latin 1 range}
+The following 32 slots, 160--191, are based on ISO Latin~1,
+which is identical to Windows ANSI in this plane.
+\endcomment
+
+\ifdirect
+
+\nextslot{160}
+\setslot{space}
+ \comment{The (non-breaking) space character.}
+\endsetslot
+
+\Fi
+
+\nextslot{161}
+\setslot{exclamdown}
+ \comment{The Spanish punctuation mark `!`'.}
+\endsetslot
+
+\setslot{cent}
+ \comment{The cent sign `\textcent'.}
+\endsetslot
+
+\setslot{sterling}
+ \comment{The British currency sign, `\textsterling'.}
+\endsetslot
+
+\setslot{currency}
+ \comment{The international currency sign, `\textcurrency'.}
+\endsetslot
+
+\setslot{yen}
+ \comment{The Japanese currency sign, `\textyen'.}
+\endsetslot
+
+\setslot{brokenbar}
+ \comment{A broken vertical bar, `\textbrokenbar',
+ similar to `\textbar' with a gap through the middle.}
+\endsetslot
+
+\setslot{section}
+ \comment{The section mark `\textsection'.}
+\endsetslot
+
+\setslot{dieresis}
+ \comment{The umlaut or dieresis accent `\"{}'.}
+\endsetslot
+
+\setslot{copyright}
+ \comment{The copyright sign `\textcopyright',
+ similar to a small `C' enclosed by a circle.}
+\endsetslot
+
+\setslot{ordfeminine}
+ \comment{The raised letter `\textordfeminine'.}
+\endsetslot
+
+\setslot{guillemotleft}
+ \comment{A French double opening quote mark `\guillemotleft',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{logicalnot}
+ \comment{The logical not sign `\textlnot'.}
+\endsetslot
+
+\ifdirect
+
+\nextslot{173}
+\setslot{hyphen}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{hyphen}{endash}
+ \Fi
+\endsetslot
+
+\Fi
+
+\nextslot{174}
+\setslot{registered}
+ \comment{The registered trademark sign `\textregistered',
+ similar to a small `R' enclosed by a circle.}
+\endsetslot
+
+\setslot{macron}
+ \comment{The macron accent `\={}'.}
+\endsetslot
+
+\setslot{degree}
+ \comment{The degree sign `\textdegree'.}
+\endsetslot
+
+\setslot{plusminus}
+ \comment{The plus or minus sign `\textpm'.}
+\endsetslot
+
+\setslot{twosuperior}
+ \comment{The raised digit `\texttwosuperior'.}
+\endsetslot
+
+\setslot{threesuperior}
+ \comment{The raised digit `\textthreesuperior'.}
+\endsetslot
+
+\setslot{acute}
+ \comment{The acute accent `\'{}'.}
+\endsetslot
+
+\setslot{mu}
+ \comment{The lowercase Greek letter `\textmu', intended
+ for use as a prefix `micro' in physical units.}
+\endsetslot
+
+\setslot{paragraph}
+ \comment{The paragraph mark `\textparagraph'.}
+\endsetslot
+
+\setslot{periodcentered}
+ \comment{The centered period `\textperiodcentered'.}
+\endsetslot
+
+\setslot{cedilla}
+ \comment{The cedilla accent `\c{}'.}
+\endsetslot
+
+\setslot{onesuperior}
+ \comment{The raised digit `\textonesuperior'.}
+\endsetslot
+
+\setslot{ordmasculine}
+ \comment{The raised letter `\textordmasculine'.}
+\endsetslot
+
+\setslot{guillemotright}
+ \comment{A French double closing quote mark `\guillemotright',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{onequarter}
+ \comment{The fraction `\textonequarter'.}
+\endsetslot
+
+\setslot{onehalf}
+ \comment{The fraction `\textonehalf'.}
+\endsetslot
+
+\setslot{threequarters}
+ \comment{The fraction `\textthreequarters'.}
+\endsetslot
+
+\setslot{questiondown}
+ \comment{The Spanish punctuation mark `?`'.}
+\endsetslot
+
+\begincomment
+\subsection{The high ISO latin 1 range}
+The remaining 64 slots, 192--255, are again based on ISO Latin~1.
+\endcomment
+
+\nextslot{192}
+\setslot{\uctop{Agrave}{agrave}}
+ \comment{The letter `\`A'.}
+\endsetslot
+
+\setslot{\uctop{Aacute}{aacute}}
+ \comment{The letter `\'A'.}
+\endsetslot
+
+\setslot{\uctop{Acircumflex}{acircumflex}}
+ \comment{The letter `\^A'.}
+\endsetslot
+
+\setslot{\uctop{Atilde}{atilde}}
+ \comment{The letter `\~A'.}
+\endsetslot
+
+\setslot{\uctop{Adieresis}{adieresis}}
+ \comment{The letter `\"A'.}
+\endsetslot
+
+\setslot{\uctop{Aring}{aring}}
+ \comment{The letter `\AA'.}
+\endsetslot
+
+\setslot{\uc{AE}{ae}}
+ \comment{The letter `\AE'.
+ This is a single letter, and should not be faked with `AE'.}
+\endsetslot
+
+\setslot{\uc{Ccedilla}{ccedilla}}
+ \comment{The letter `\c C'.}
+\endsetslot
+
+\setslot{\uctop{Egrave}{egrave}}
+ \comment{The letter `\`E'.}
+\endsetslot
+
+\setslot{\uctop{Eacute}{eacute}}
+ \comment{The letter `\'E'.}
+\endsetslot
+
+\setslot{\uctop{Ecircumflex}{ecircumflex}}
+ \comment{The letter `\^E'.}
+\endsetslot
+
+\setslot{\uctop{Edieresis}{edieresis}}
+ \comment{The letter `\"E'.}
+\endsetslot
+
+\setslot{\uctop{Igrave}{igrave}}
+ \comment{The letter `\`I'.}
+\endsetslot
+
+\setslot{\uctop{Iacute}{iacute}}
+ \comment{The letter `\'I'.}
+\endsetslot
+
+\setslot{\uctop{Icircumflex}{icircumflex}}
+ \comment{The letter `\^I'.}
+\endsetslot
+
+\setslot{\uctop{Idieresis}{idieresis}}
+ \comment{The letter `\"I'.}
+\endsetslot
+
+\setslot{\uc{Eth}{eth}}
+ \comment{The Icelandic capital letter `Eth' similar to a `D'
+ with a horizontal bar through the stem. It is unavailable
+ in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\uctop{Ntilde}{ntilde}}
+ \comment{The letter `\~N'.}
+\endsetslot
+
+\setslot{\uctop{Ograve}{ograve}}
+ \comment{The letter `\`O'.}
+\endsetslot
+
+\setslot{\uctop{Oacute}{oacute}}
+ \comment{The letter `\'O'.}
+\endsetslot
+
+\setslot{\uctop{Ocircumflex}{ocircumflex}}
+ \comment{The letter `\^O'.}
+\endsetslot
+
+\setslot{\uctop{Otilde}{otilde}}
+ \comment{The letter `\~O'.}
+\endsetslot
+
+\setslot{\uctop{Odieresis}{odieresis}}
+ \comment{The letter `\"O'.}
+\endsetslot
+
+\setslot{multiply}
+ \comment{The multiplication sign `\texttimes'.}
+\endsetslot
+
+\setslot{\uc{Oslash}{oslash}}
+ \comment{The letter `\O'.}
+\endsetslot
+
+\setslot{\uctop{Ugrave}{ugrave}}
+ \comment{The letter `\`U'.}
+\endsetslot
+
+\setslot{\uctop{Uacute}{uacute}}
+ \comment{The letter `\'U'.}
+\endsetslot
+
+\setslot{\uctop{Ucircumflex}{ucircumflex}}
+ \comment{The letter `\^U'.}
+\endsetslot
+
+\setslot{\uctop{Udieresis}{udieresis}}
+ \comment{The letter `\"U'.}
+\endsetslot
+
+\setslot{\uctop{Yacute}{yacute}}
+ \comment{The letter `\'Y'.}
+\endsetslot
+
+\setslot{\uc{Thorn}{thorn}}
+ \comment{The Icelandic capital letter `Thorn', similar to a `P'
+ with the bowl moved down. It is unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lc{SS}{germandbls}}
+ \comment{The letter `\ss'.}
+\endsetslot
+
+\setslot{\lctop{Agrave}{agrave}}
+ \comment{The letter `\`a'.}
+\endsetslot
+
+\setslot{\lctop{Aacute}{aacute}}
+ \comment{The letter `\'a'.}
+\endsetslot
+
+\setslot{\lctop{Acircumflex}{acircumflex}}
+ \comment{The letter `\^a'.}
+\endsetslot
+
+\setslot{\lctop{Atilde}{atilde}}
+ \comment{The letter `\~a'.}
+\endsetslot
+
+\setslot{\lctop{Adieresis}{adieresis}}
+ \comment{The letter `\"a'.}
+\endsetslot
+
+\setslot{\lctop{Aring}{aring}}
+ \comment{The letter `\aa'.}
+\endsetslot
+
+\setslot{\lc{AE}{ae}}
+ \comment{The letter `\ae'.
+ This is a single letter, and should not be faked with `ae'.}
+\endsetslot
+
+\setslot{\lc{Ccedilla}{ccedilla}}
+ \comment{The letter `\c c'.}
+\endsetslot
+
+\setslot{\lctop{Egrave}{egrave}}
+ \comment{The letter `\`e'.}
+\endsetslot
+
+\setslot{\lctop{Eacute}{eacute}}
+ \comment{The letter `\'e'.}
+\endsetslot
+
+\setslot{\lctop{Ecircumflex}{ecircumflex}}
+ \comment{The letter `\^e'.}
+\endsetslot
+
+\setslot{\lctop{Edieresis}{edieresis}}
+ \comment{The letter `\"e'.}
+\endsetslot
+
+\setslot{\lctop{Igrave}{igrave}}
+ \comment{The letter `\`\i'.}
+\endsetslot
+
+\setslot{\lctop{Iacute}{iacute}}
+ \comment{The letter `\'\i'.}
+\endsetslot
+
+\setslot{\lctop{Icircumflex}{icircumflex}}
+ \comment{The letter `\^\i'.}
+\endsetslot
+
+\setslot{\lctop{Idieresis}{idieresis}}
+ \comment{The letter `\"\i'.}
+\endsetslot
+
+\setslot{\lc{Eth}{eth}}
+ \comment{The Icelandic lowercase letter `eth' similar to a
+ `$\partial$' with an oblique bar through the stem. It is
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lctop{Ntilde}{ntilde}}
+ \comment{The letter `\~n'.}
+\endsetslot
+
+\setslot{\lctop{Ograve}{ograve}}
+ \comment{The letter `\`o'.}
+\endsetslot
+
+\setslot{\lctop{Oacute}{oacute}}
+ \comment{The letter `\'o'.}
+\endsetslot
+
+\setslot{\lctop{Ocircumflex}{ocircumflex}}
+ \comment{The letter `\^o'.}
+\endsetslot
+
+\setslot{\lctop{Otilde}{otilde}}
+ \comment{The letter `\~o'.}
+\endsetslot
+
+\setslot{\lctop{Odieresis}{odieresis}}
+ \comment{The letter `\"o'.}
+\endsetslot
+
+\setslot{divide}
+ \comment{The division sign `\textdiv'.}
+\endsetslot
+
+\setslot{\lc{Oslash}{oslash}}
+ \comment{The letter `\o'.}
+\endsetslot
+
+\setslot{\lctop{Ugrave}{ugrave}}
+ \comment{The letter `\`u'.}
+\endsetslot
+
+\setslot{\lctop{Uacute}{uacute}}
+ \comment{The letter `\'u'.}
+\endsetslot
+
+\setslot{\lctop{Ucircumflex}{ucircumflex}}
+ \comment{The letter `\^u'.}
+\endsetslot
+
+\setslot{\lctop{Udieresis}{udieresis}}
+ \comment{The letter `\"u'.}
+\endsetslot
+
+\setslot{\lctop{Yacute}{yacute}}
+ \comment{The letter `\'y'.}
+\endsetslot
+
+\setslot{\lc{Thorn}{thorn}}
+ \comment{The Icelandic lowercase letter `thorn', similar to a `p'
+ with an ascender rising from the stem. It is unavailable
+ in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lctop{Ydieresis}{ydieresis}}
+ \comment{The letter `\"y'.}
+\endsetslot
+
+\endencoding
+
+
+\section{Changes}
+
+The noteworthy changes made to this document are as follows.
+
+1999/10/25:
+ Typos regarding \texttt{Lslash} and \texttt{lslash}
+ corrected. (UV\&LH)
+
+1999/11/11:
+ Added \verb|\showbranches| markup. Removed \texttt{-OT1}
+ suffix from some glyph names. (LH)
+
+2003/02/04:
+ Returned to the v\,1.801 version of this file, and
+ reintroduced the few later additions (see above) that made sense.
+ Modernized setting of font parameters. Tidied up some markup.
+ (LH)
+
+2003/02/09:
+ Unified the duplicate glyphs (again!), this time using
+ the new \verb|\ifdirect| switch.
+
+2003/12/08:
+ Fixed two typos (\verb|\setslot| where it should be
+ \verb|\nextslot|). (LH)
+
+2004/09/13:
+ Added \texttt{Euro} in slot 1, as that is in \texttt{texnansi.enc}.
+ (LH, following a mail from Peter Harmard)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1.etx
new file mode 100644
index 0000000000..d047de664d
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1.etx
@@ -0,0 +1,938 @@
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% copyright 1998, 1999, 2002 the fontinst maintenance team and
+% any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = {Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m},
+%%% version = "1.910",
+%%% date = "2002-07-31",
+%%% time = "21:45:37 +02:00",
+%%% filename = "ot1.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the old TeX text encoding as a TeX
+%%% font encoding file, for use with the fontinst
+%%% utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/03/16]
+
+\title{The \TeX\ text encoding vector}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{31 July 2002\\Version 1.921}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the \TeX\ text (\texttt{OT1}) encoding---or
+rather the \texttt{OT1} encodings, since the Computer Modern font
+family alone provide examples of no less than five different
+\texttt{OT1} encodings.
+
+The exact encoding of fonts produced using this file is controlled
+through the two integers \texttt{ligaturing} (relevant values are $0$,
+$1$, and $2$) and \texttt{italicizing} (relevant values are $0$ and
+$1$). \texttt{ligaturing} controls roughly how many ligature
+characters and ligaturing instructions there are in the font.
+\texttt{italicizing} controls whether the font contains a dollar or
+pound sign.
+
+This file also makes use of five macros in forming the names of
+glyphs, so that this can be configured.
+\begin{itemize}
+\item \verb|\lc{A}{a}| should return the name of a lower-case
+ glyph, for example `\texttt{a}' or `\texttt{Asmall}'.
+
+\item \verb|\uc{A}{a}| should return the name of an upper-case
+ glyph, for example `\texttt{A}' or `\texttt{Amedium}'.
+
+\item \verb|\lclig{FI}{fi}| should return the name of a lower-case
+ ligature, for example `\texttt{fi}' or `\texttt{FIsmall}'.
+
+\item \verb|\uclig{FI}{fi}| should return the name of an upper-case
+ ligature, for example `\texttt{FI}' or `\texttt{FImedium}'.
+
+\item \verb|\digit{zero}| should return the name of a digit, for
+ example `\texttt{zero}' or `\texttt{zerooldstyle}'.
+
+% \item \verb|\currency| should be the name of the currency glyph, either
+% `\texttt{sterling}' or `\texttt{dollar}'.
+\end{itemize}
+These should all expand in the mouth, otherwise you may get error
+messages!
+
+For example, to get the standard upper and lower case font, you should
+define:
+\begin{verbatim}
+ \setcommand\lc#1#2{#2}
+ \setcommand\uc#1#2{#1}
+ \setcommand\lclig#1#2{#2}
+ \setcommand\uclig#1#2{#1}
+ \setcommand\digit#1{#1}
+\end{verbatim}
+To get a caps and small caps font with old style digits and letter
+spacing, you should define:
+\begin{verbatim}
+ \setcommand\lc#1#2{#1small}
+ \setcommand\uc#1#2{#1}
+ \setcommand\lclig#1#2{#2small}
+ \setcommand\uclig#1#2{#1spaced}
+ \setcommand\digit#1{#1oldstyle}
+\end{verbatim}
+To get an all-caps font with medium-cap composite letters and letter
+spacing, you should define:
+\begin{verbatim}
+ \setcommand\lc#1#2{#1}
+ \setcommand\uc#1#2{#1}
+ \setcommand\lclig#1#2{#1spaced}
+ \setcommand\uclig#1#2{#1spaced}
+ \setcommand\digit#1{#1}
+\end{verbatim}
+This document describes the upper and lower case encoding.
+
+\showbranches
+
+\encoding
+
+\needsfontinstversion{1.917}
+
+
+\begincomment\section{Default values}\endcomment
+
+\comment{The \textit{ligaturing} default depends on whether
+ \textit{monowidth} is set mainly because that causes the default
+ installation of fonts to be slightly more intelligent.}
+\ifisint{monowidth}\then
+ \setint{ligaturing}{0}
+\Else
+ \setint{ligaturing}{2}
+\Fi
+
+\setint{italicizing}{0}
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+
+% \comment{The following trickery was introduced to make the change
+% from monowidth implying typewriter to monowidth not implying
+% typewriter less abrupt.}
+% \ifisint{monowidth}\then
+% \ifisint{typewriter}\then \Else
+% \ifnumber{\int{monowidth}}={9876}\then \Else
+% \fontinstwarningnoline{ot1.etx}{%
+% Set the typewriter integer to get a typewriter font,%
+% \messagebreak
+% set monowidth to 9876 to get a monowidth font,%
+% \messagebreak
+% or set both to get a monowidth typewriter font%
+% }
+% \setint{typewriter}{0}
+% \Fi
+% \Fi
+% \Fi
+
+
+\setint{italicslant}{0}
+
+\ifisglyph{space}\then
+ \setint{interword}{\width{space}}
+\Else\ifisglyph{i}\then
+ \setint{interword}{\width{i}}
+\Else
+ \setint{interword}{333}
+\Fi\Fi
+
+\ifisint{monowidth}\then
+ \setint{stretchword}{0}
+ \setint{shrinkword}{0}
+\Else
+ \setint{stretchword}{\scale{\int{interword}}{600}}
+ \setint{shrinkword}{\scale{\int{interword}}{240}}
+\Fi
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\setint{quad}{1000}
+
+\ifisint{monowidth}\then
+% \ifnumber{\int{ligaturing}}={0}\then
+% \setint{extraspace}{0}
+% \Else
+ \setint{extraspace}{\int{interword}}
+% \Fi
+\Else
+ \setint{extraspace}{\scale{\int{interword}}{240}}
+\Fi
+
+
+
+\begincomment
+\section{Font dimensions and coding scheme}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+
+\ifnumber{\int{ligaturing}}={2}\then
+
+\setstr{codingscheme}{TEX TEXT}
+
+\Else\ifnumber{\int{ligaturing}}={1}\then
+
+\setstr{codingscheme}{TEX TEXT WITHOUT F-LIGATURES}
+
+\Else
+
+\setstr{codingscheme}{TEX TYPEWRITER TEXT}
+
+\Fi\Fi
+
+
+
+\begincomment
+\section{The encoding}
+
+There are 130 glyphs in this encoding. 128 of these are in Knuth's CM
+encoding, and the other two are `\l' and `\L', which are composite
+letters in CM, but are single glyphs in almost every other font.
+\endcomment
+
+\setslot{Gamma}
+ \comment{The greek letter `$\Gamma$'.}
+\endsetslot
+
+\setslot{Delta}
+ \comment{The greek letter `$\Delta$'.}
+\endsetslot
+
+\setslot{Theta}
+ \comment{The greek letter `$\Theta$'.}
+\endsetslot
+
+\setslot{Lambda}
+ \comment{The greek letter `$\Lambda$'.}
+\endsetslot
+
+\setslot{Xi}
+ \comment{The greek letter `$\Xi$'.}
+\endsetslot
+
+\setslot{Pi}
+ \comment{The greek letter `$\Pi$'.}
+\endsetslot
+
+\setslot{Sigma}
+ \comment{The greek letter `$\Sigma$'.}
+\endsetslot
+
+\setslot{Upsilon}
+ \comment{The greek letter `$\Upsilon$' named `\texttt{Upsilon1}' by
+ Adobe.}
+\endsetslot
+
+\setslot{Phi}
+ \comment{The greek letter `$\Phi$'.}
+\endsetslot
+
+\setslot{Psi}
+ \comment{The greek letter `$\Psi$'.}
+\endsetslot
+
+\setslot{Omega}
+ \comment{The greek letter `$\Omega$'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{2}\then
+
+\setslot{arrowup}
+ \comment{An upwards-facing arrow `$\uparrow$'.}
+\endsetslot
+
+\setslot{arrowdown}
+ \comment{A downwards-facing arrow `$\downarrow$'.}
+\endsetslot
+
+\setslot{quotesingle}
+ \comment{The `neutral' single quotation mark `\texttt{\char`\'}',
+ for use with monowidth fonts.}
+\endsetslot
+
+\setslot{exclamdown}
+ \comment{The Spanish punctuation mark `!`'.}
+\endsetslot
+
+\setslot{questiondown}
+ \comment{The Spanish punctuation mark `?`'.}
+\endsetslot
+
+\Else
+
+\setslot{\lclig{FF}{ff}}
+ \ligature{LIG}{\lc{I}{i}}{\lclig{FFI}{ffi}}
+ \ligature{LIG}{\lc{L}{l}}{\lclig{FFL}{ffl}}
+ \comment{The `ff' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FI}{fi}}
+ \comment{The `fi' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FL}{fl}}
+ \comment{The `fl' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FFI}{ffi}}
+ \comment{The `ffi' ligature. It should be three characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FFL}{ffl}}
+ \comment{The `ffl' ligature. It should be three characters wide in a
+ monowidth font.}
+\endsetslot
+
+\Fi
+
+\setslot{\lc{dotlessI}{dotlessi}}
+ \comment{A dotless i `\i', used to produce accented letters such as
+ `\=\i'.}
+\endsetslot
+
+\setslot{\lc{dotlessJ}{dotlessj}}
+ \comment{A dotless j `\j', used to produce accented letters such as
+ `\=\j'. Most non-\TeX\ fonts do not have this glyph.}
+\endsetslot
+
+\setslot{grave}
+ \comment{The grave accent `\`a'.}
+\endsetslot
+
+\setslot{acute}
+ \comment{The acute accent `\'a'.}
+\endsetslot
+
+\setslot{caron}
+ \comment{The caron or h\'a\v cek accent `\v a'.}
+\endsetslot
+
+\setslot{breve}
+ \comment{The breve accent `\u a'.}
+\endsetslot
+
+\setslot{macron}
+ \comment{The macron accent `\=a'.}
+\endsetslot
+
+\setslot{ringfitted}
+ \comment{The ring accent `\aa', fitted to be the same width as an
+ upper case `A'.}
+\endsetslot
+
+\setslot{cedilla}
+ \comment{The cedilla accent `\c a'.}
+\endsetslot
+
+\setslot{\lc{SS}{germandbls}}
+ \comment{The letter `\ss'.}
+\endsetslot
+
+\setslot{\lc{AE}{ae}}
+ \comment{The letter `\ae'. This is a single letter, and should not be
+ faked with `ae'.}
+\endsetslot
+
+\setslot{\lc{OE}{oe}}
+ \comment{The letter `\oe'. This is a single letter, and should not be
+ faked with `oe'.}
+\endsetslot
+
+\setslot{\lc{Oslash}{oslash}}
+ \comment{The letter `\o'.}
+\endsetslot
+
+\setslot{\uc{AE}{ae}}
+ \comment{The letter `\AE'. This is a single letter, and should not be
+ faked with `AE'.}
+\endsetslot
+
+\setslot{\uc{OE}{oe}}
+ \comment{The letter `\OE'. This is a single letter, and should not be
+ faked with `OE'.}
+\endsetslot
+
+\setslot{\uc{Oslash}{oslash}}
+ \comment{The letter `\o'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{1}\then
+
+\setslot{visiblespace}
+ \comment{A visible space glyph `\texttt{\char`\ }'.}
+\endsetslot
+
+\Else
+
+\setslot{lslashslash}
+ \ligature{LIG}{\lc{L}{l}}{\lc{Lslash}{lslash}}
+ \ligature{LIG}{\uc{L}{l}}{\uc{Lslash}{lslash}}
+ \comment{The slash used to make `\l' and `\L'. Since most fonts do
+ not have a separate glyph for this, I've added ligatures to `\l'
+ and `\L'.}
+\endsetslot
+
+\Fi
+
+\setslot{exclam}
+ \ligature{LIG}{quoteleft}{exclamdown}
+ \comment{The exclamation mark `!'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{quotedblright}
+ \comment{An English double closing quote mark `\,''\,'.}
+\endsetslot
+
+\Else
+
+\setslot{quotedbl}
+ \comment{The `neutral' quotation mark `\texttt{\char`\"}', included
+ for use in monowidth fonts, or for setting computer programs.}
+\endsetslot
+
+\Fi
+
+\setslot{numbersign}
+ \comment{The hash sign `\#'.}
+\endsetslot
+
+\ifnumber{\int{italicizing}}={0}\then
+
+\setslot{dollar}
+ \comment{The dollar sign `\$'.}
+\endsetslot
+
+\Else
+
+\setslot{sterling}
+ \comment{The pound sign `\pounds'.}
+\endsetslot
+
+\Fi
+
+\setslot{percent}
+ \comment{The percent sign `\%'.}
+\endsetslot
+
+\setslot{ampersand}
+ \comment{The ampersand sign `\&'.}
+\endsetslot
+
+\setslot{quoteright}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{quoteright}{quotedblright}
+ \Fi
+ \comment{The English closing quotation mark `\,'\,'.}
+\endsetslot
+
+\setslot{parenleft}
+ \comment{The opening parenthesis `('.}
+\endsetslot
+
+\setslot{parenright}
+ \comment{The closing parenthesis `)'.}
+\endsetslot
+
+\setslot{asterisk}
+ \comment{The raised asterisk `*'.}
+\endsetslot
+
+\setslot{plus}
+ \comment{The addition sign `+'.}
+\endsetslot
+
+\setslot{comma}
+ \comment{The comma `,'.}
+\endsetslot
+
+\setslot{hyphen}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{hyphen}{rangedash}
+ \Fi
+ \comment{The hyphen `-'.}
+\endsetslot
+
+\setslot{period}
+ \comment{The full point `.'.}
+\endsetslot
+
+\setslot{slash}
+ \comment{The forward oblique `/'.}
+\endsetslot
+
+\setslot{\digit{zero}}
+ \comment{The number zero `0'. This (and all the other numerals) may be
+ old style or ranging digits.}
+\endsetslot
+
+\setslot{\digit{one}}
+ \comment{The number one `1'.}
+\endsetslot
+
+\setslot{\digit{two}}
+ \comment{The number two `2'.}
+\endsetslot
+
+\setslot{\digit{three}}
+ \comment{The number three `3'.}
+\endsetslot
+
+\setslot{\digit{four}}
+ \comment{The number four `4'.}
+\endsetslot
+
+\setslot{\digit{five}}
+ \comment{The number five `5'.}
+\endsetslot
+
+\setslot{\digit{six}}
+ \comment{The number six `6'.}
+\endsetslot
+
+\setslot{\digit{seven}}
+ \comment{The number seven `7'.}
+\endsetslot
+
+\setslot{\digit{eight}}
+ \comment{The number eight `8'.}
+\endsetslot
+
+\setslot{\digit{nine}}
+ \comment{The number nine `9'.}
+\endsetslot
+
+\setslot{colon}
+ \comment{The colon punctuation mark `:'.}
+\endsetslot
+
+\setslot{semicolon}
+ \comment{The semi-colon punctuation mark `;'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{2}\then
+
+\setslot{less}
+ \comment{The less-than sign `$<$'.}
+\endsetslot
+
+\setslot{equal}
+ \comment{The equals sign `='.}
+\endsetslot
+
+\setslot{greater}
+ \comment{The greater-than sign `$>$'.}
+\endsetslot
+
+\Else
+
+\setslot{exclamdown}
+ \comment{The Spanish punctuation mark `!`'.}
+\endsetslot
+
+\setslot{equal}
+ \comment{The equals sign `='.}
+\endsetslot
+
+\setslot{questiondown}
+ \comment{The Spanish punctuation mark `?`'.}
+\endsetslot
+
+\Fi
+
+\setslot{question}
+ \ligature{LIG}{quoteleft}{questiondown}
+ \comment{The question mark `?'.}
+\endsetslot
+
+\setslot{at}
+ \comment{The at sign `@'.}
+\endsetslot
+
+\setslot{\uc{A}{a}}
+ \comment{The letter `{A}'.}
+\endsetslot
+
+\setslot{\uc{B}{b}}
+ \comment{The letter `{B}'.}
+\endsetslot
+
+\setslot{\uc{C}{c}}
+ \comment{The letter `{C}'.}
+\endsetslot
+
+\setslot{\uc{D}{d}}
+ \comment{The letter `{D}'.}
+\endsetslot
+
+\setslot{\uc{E}{e}}
+ \comment{The letter `{E}'.}
+\endsetslot
+
+\setslot{\uc{F}{f}}
+ \comment{The letter `{F}'.}
+\endsetslot
+
+\setslot{\uc{G}{g}}
+ \comment{The letter `{G}'.}
+\endsetslot
+
+\setslot{\uc{H}{h}}
+ \comment{The letter `{H}'.}
+\endsetslot
+
+\setslot{\uc{I}{i}}
+ \comment{The letter `{I}'.}
+\endsetslot
+
+\setslot{\uc{J}{j}}
+ \comment{The letter `{J}'.}
+\endsetslot
+
+\setslot{\uc{K}{k}}
+ \comment{The letter `{K}'.}
+\endsetslot
+
+\setslot{\uc{L}{l}}
+ \comment{The letter `{L}'.}
+\endsetslot
+
+\setslot{\uc{M}{m}}
+ \comment{The letter `{M}'.}
+\endsetslot
+
+\setslot{\uc{N}{n}}
+ \comment{The letter `{N}'.}
+\endsetslot
+
+\setslot{\uc{O}{o}}
+ \comment{The letter `{O}'.}
+\endsetslot
+
+\setslot{\uc{P}{p}}
+ \comment{The letter `{P}'.}
+\endsetslot
+
+\setslot{\uc{Q}{q}}
+ \comment{The letter `{Q}'.}
+\endsetslot
+
+\setslot{\uc{R}{r}}
+ \comment{The letter `{R}'.}
+\endsetslot
+
+\setslot{\uc{S}{s}}
+ \comment{The letter `{S}'.}
+\endsetslot
+
+\setslot{\uc{T}{t}}
+ \comment{The letter `{T}'.}
+\endsetslot
+
+\setslot{\uc{U}{u}}
+ \comment{The letter `{U}'.}
+\endsetslot
+
+\setslot{\uc{V}{v}}
+ \comment{The letter `{V}'.}
+\endsetslot
+
+\setslot{\uc{W}{w}}
+ \comment{The letter `{W}'.}
+\endsetslot
+
+\setslot{\uc{X}{x}}
+ \comment{The letter `{X}'.}
+\endsetslot
+
+\setslot{\uc{Y}{y}}
+ \comment{The letter `{Y}'.}
+\endsetslot
+
+\setslot{\uc{Z}{z}}
+ \comment{The letter `{Z}'.}
+\endsetslot
+
+\setslot{bracketleft}
+ \comment{The opening square bracket `['.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{quotedblleft}
+ \comment{An English double opening quote mark `\,``\,'.}
+\endsetslot
+
+\Else
+
+\setslot{backslash}
+ \comment{The backwards oblique `$\backslash$'.}
+\endsetslot
+
+\Fi
+
+\setslot{bracketright}
+ \comment{The closing square bracket `]'.}
+\endsetslot
+
+\setslot{circumflex}
+ \comment{The circumflex accent `\^ a'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{dotaccent}
+ \comment{The dot accent `\.a'.}
+\endsetslot
+
+\Else
+
+\setslot{underscore}
+ \comment{The ASCII underline character `\texttt{\char`\_}', usually
+ set on the baseline.}
+\endsetslot
+
+\Fi
+
+\setslot{quoteleft}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{quoteleft}{quotedblleft}
+ \Fi
+ \comment{The English opening single quotation mark `\,`\,'.}
+\endsetslot
+
+\setslot{\lc{A}{a}}
+ \comment{The letter `{a}'.}
+\endsetslot
+
+\setslot{\lc{B}{b}}
+ \comment{The letter `{b}'.}
+\endsetslot
+
+\setslot{\lc{C}{c}}
+ \comment{The letter `{c}'.}
+\endsetslot
+
+\setslot{\lc{D}{d}}
+ \comment{The letter `{d}'.}
+\endsetslot
+
+\setslot{\lc{E}{e}}
+ \comment{The letter `{e}'.}
+\endsetslot
+
+\setslot{\lc{F}{f}}
+ \ifnumber{\int{ligaturing}}<{2}\then \Else
+ \ligature{LIG}{\lc{I}{i}}{\lclig{FI}{fi}}
+ \ligature{LIG}{\lc{F}{f}}{\lclig{FF}{ff}}
+ \ligature{LIG}{\lc{L}{l}}{\lclig{FL}{fl}}
+ \Fi
+ \comment{The letter `{f}'.}
+\endsetslot
+
+\setslot{\lc{G}{g}}
+ \comment{The letter `{g}'.}
+\endsetslot
+
+\setslot{\lc{H}{h}}
+ \comment{The letter `{h}'.}
+\endsetslot
+
+\setslot{\lc{I}{i}}
+ \comment{The letter `{i}'.}
+\endsetslot
+
+\setslot{\lc{J}{j}}
+ \comment{The letter `{j}'.}
+\endsetslot
+
+\setslot{\lc{K}{k}}
+ \comment{The letter `{k}'.}
+\endsetslot
+
+\setslot{\lc{L}{l}}
+ \comment{The letter `{l}'.}
+\endsetslot
+
+\setslot{\lc{M}{m}}
+ \comment{The letter `{m}'.}
+\endsetslot
+
+\setslot{\lc{N}{n}}
+ \comment{The letter `{n}'.}
+\endsetslot
+
+\setslot{\lc{O}{o}}
+ \comment{The letter `{o}'.}
+\endsetslot
+
+\setslot{\lc{P}{p}}
+ \comment{The letter `{p}'.}
+\endsetslot
+
+\setslot{\lc{Q}{q}}
+ \comment{The letter `{q}'.}
+\endsetslot
+
+\setslot{\lc{R}{r}}
+ \comment{The letter `{r}'.}
+\endsetslot
+
+\setslot{\lc{S}{s}}
+ \comment{The letter `{s}'.}
+\endsetslot
+
+\setslot{\lc{T}{t}}
+ \comment{The letter `{t}'.}
+\endsetslot
+
+\setslot{\lc{U}{u}}
+ \comment{The letter `{u}'.}
+\endsetslot
+
+\setslot{\lc{V}{v}}
+ \comment{The letter `{v}'.}
+\endsetslot
+
+\setslot{\lc{W}{w}}
+ \comment{The letter `{w}'.}
+\endsetslot
+
+\setslot{\lc{X}{x}}
+ \comment{The letter `{x}'.}
+\endsetslot
+
+\setslot{\lc{Y}{y}}
+ \comment{The letter `{y}'.}
+\endsetslot
+
+\setslot{\lc{Z}{z}}
+ \comment{The letter `{z}'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}>{0}\then
+
+\setslot{rangedash}
+ \ligature{LIG}{hyphen}{punctdash}
+ \comment{The number range dash `1--9'. In a monowidth font, this
+ might be set as `\texttt{1{-}9}'.}
+\endsetslot
+
+\setslot{punctdash}
+ \comment{The punctuation dash `Oh---boy.' In a monowidth font, this
+ might be set as `\texttt{Oh{-}{-}boy.}'}
+\endsetslot
+
+\setslot{hungarumlaut}
+ \comment{The long Hungarian umlaut `\H a'.}
+\endsetslot
+
+\Else
+
+\setslot{braceleft}
+ \comment{The opening curly brace `\{'.}
+\endsetslot
+
+\setslot{bar}
+ \comment{The ASCII vertical bar `$|$'. This is included
+ for compatibility with typewriter fonts used for computer
+ listings.}
+\endsetslot
+
+\setslot{braceright}
+ \comment{The closing curly brace `\}'.}
+\endsetslot
+
+\Fi
+
+\setslot{tilde}
+ \comment{The tilde accent `\~a'.}
+\endsetslot
+
+\setslot{dieresis}
+ \comment{The umlaut or dieresis accent `\"a'.}
+\endsetslot
+
+\begincomment
+\section{Non-standard ligatures}
+
+The `\l' and `\L' glyphs are not usually in the ot1 encoding, but
+they're needed for fonts which don't have a special `lslashslash' glyph.
+\endcomment
+
+\nextslot{"8A}
+
+\setslot{\uc{Lslash}{lslash}}
+ \comment{The letter `\L'.}
+\endsetslot
+
+\nextslot{"AA}
+
+\setslot{\lc{Lslash}{lslash}}
+ \comment{The letter `\l'.}
+\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+1999/10/18: Introduced the \texttt{typewriter} integer and made changes
+for \verb|\showbranches|. (LH)
+
+1999/11/07: Removed the ``if \texttt{typewriter} then
+\texttt{monowidth}'' implication. Changed \texttt{fontdimen(7)} to zero
+in monowidth typewriter fonts. (LH)
+
+2002/07/31: Major update. The \verb|\currency| and
+\textit{typewriter} parameters were removed---instead the
+\textit{ligaturing} and \textit{italicizing} parameters were added.
+\verb|\setfontdimen| interface used for setting fontdimens. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1c.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1c.etx
new file mode 100644
index 0000000000..4251562e56
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1c.etx
@@ -0,0 +1,92 @@
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% copyright 1998, 1999, 2002 the fontinst maintenance team and
+% any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/03/16]
+
+\title{The \texttt{OT1} encoding for small-caps fonts}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{See also the normal \texttt{OT1} encoding}
+
+\begin{document}
+\maketitle
+
+This file is used to install a small-caps font in which the small-caps
+glyphs are named as $\langle$\textit{full cap glyph name}$\rangle +{}$%
+\texttt{small}. It is mainly used to install faked small-caps fonts,
+but it is also used to install small-caps fonts where the small-caps
+glyphs are taken from an Expert font.
+
+\showbranches
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setcommand\lc#1#2{#1small}
+\setcommand\uc#1#2{#1}
+\setcommand\lclig#1#2{#1small}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+% \setcommand\currency{dollar}
+
+% \comment{The default letter spacing is 1/10 of the design size, with
+% small caps 80\% the size of full caps.}
+
+% \setint{smallcapsscale}{800}
+
+% \ifisglyph{space}\then
+% \setint{interword}{\width{space}}
+% \Else\ifisglyph{i}\then
+% \setint{interword}{\width{i}}
+% \Else
+% \setint{interword}{333}
+% \Fi\Fi
+
+% \ifisint{monowidth}\then
+% \setint{smallcapsextraspace}
+% {\div{\scale{\int{interword}}{\sub{1000}{\int{smallcapsscale}}}}{2}}
+% \setint{smallcapsspacing}{0}
+% \Else
+% \setint{smallcapsextraspace}{0}
+% \setint{smallcapsspacing}{50}
+% \Fi
+
+\ifisint{capspacing}\then
+ \setint{letterspacing}{\int{capspacing}}
+\Else\ifisint{smallcapsspacing}\then
+ \setint{letterspacing}{\int{smallcapsspacing}}
+\Fi\Fi
+
+\comment{Then we call \texttt{ot1.etx}.}
+
+\inputetx{ot1}
+
+\endencoding
+
+\section{Changes}
+
+1999/10/26: Added \textsf{fontdoc} markup, made changes for
+\verb|\showbranches|, and code for things that was moved from encoding
+to metric files ages ago commented out. (LH)
+
+2002/07/31: Minor fixes. (LH)
+
+\end{document}
+
+
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1cj.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1cj.etx
new file mode 100644
index 0000000000..9be75daafb
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1cj.etx
@@ -0,0 +1,69 @@
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% copyright 1998, 1999, 2002 the fontinst maintenance team
+% and any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/03/16]
+
+\title{The \texttt{OT1} encoding for small-caps and hanging figures fonts}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{See also the normal \texttt{OT1} encoding}
+
+\begin{document}
+\maketitle
+
+This file is used to install a small-caps and hanging (oldstyle)
+figures font in which the small-caps glyphs are named as
+$\langle$\textit{full cap glyph name}$\rangle +{}$\texttt{small} and
+the figures are named as $\langle$\textit{figure name}$\rangle + {}$%
+\texttt{oldstyle}. It is mainly used to install faked small-caps fonts,
+but it is also used to install small-caps fonts where the small-caps
+glyphs are taken from an Expert font.
+
+\showbranches
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setcommand\lc#1#2{#1small}
+\setcommand\uc#1#2{#1}
+\setcommand\lclig#1#2{#1small}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1oldstyle}
+% \setcommand\currency{dollar}
+
+\ifisint{capspacing}\then
+ \setint{letterspacing}{\int{capspacing}}
+\Else\ifisint{letterspacing}\then
+ \setint{letterspacing}{\int{smallcapsspacing}}
+\Fi\Fi
+
+\inputetx{ot1}
+
+\endencoding
+
+
+\section{Changes}
+
+1999/10/27: Added \textsf{fontdoc} markup, made changes for
+\verb|\showbranches|, and code for things that was moved from encoding
+to metric files ages ago was removed. (LH)
+
+2002/07/31: Minor fixes. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1ctt.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1ctt.etx
new file mode 100644
index 0000000000..4ed62672b3
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1ctt.etx
@@ -0,0 +1,63 @@
+% Copyright 1993 Alan Jeffrey,
+% copyright 1999, 2002 the fontinst maintenance team
+% and any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/03/16]
+
+\title{The \texttt{OT1} encoding for small-caps typewriter fonts}
+\author{Alan Jeffrey\and Lars Hellstr\"om}
+\date{See also the normal \texttt{OT1} encoding}
+
+\begin{document}
+\maketitle
+
+The main use for this file is conversion from PL to MTX format of the
+metrics for a small-caps font with the \texttt{TEX TYPEWRITER TEXT}
+codingscheme. It can also be used to install an \texttt{OT1}-%
+typewriter encoded font with small-caps in the places of the lower case.
+
+\errorcontextlines=999
+
+\showbranches
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setint{ligaturing}{0}
+
+\comment{Then we call \texttt{ot1c.etx}.}
+
+\inputetx{ot1c}
+
+\endencoding
+
+\section{Changes}
+
+1993/12/29: File created. (ASAJ)
+
+1999/11/04: Removed a lot of antiquated code (including two
+\verb|\setglyph| commands!!), updated for the v\,1.909 \texttt{ot1.etx},
+made the file call \texttt{ot1c.etx} rather than \texttt{ot1.etx}, and
+added \textsf{fontdoc} markup. (LH)
+
+2002/07/31: Minor fixes, after having updated \texttt{ot1.etx}. (LH)
+
+\end{document}
+
+
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1i.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1i.etx
new file mode 100644
index 0000000000..415d4826f8
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1i.etx
@@ -0,0 +1,56 @@
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% copyright 1998, 1999, 2002 the fontinst maintenance team
+% and any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/03/16]
+
+\title{The \texttt{OT1} encoding for italic fonts}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{See also the normal \texttt{OT1} encoding}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This file is used to install an italic \texttt{OT1}-encoded font. It
+is necessary to distinguish between roman and italic in \texttt{OT1},
+because the \texttt{sterling} and \texttt{dollar} glyphs share the
+same slot.
+
+\section{Default values}
+\showbranches
+\encoding
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+% \setcommand\currency{sterling}
+\setint{italicizing}{1}
+
+\inputetx{ot1}
+
+\endencoding
+
+\section{Changes}
+
+1999/10/27: Added \textsf{fontdoc} markup. (LH)
+
+2002/07/31:
+Minor update called for by changes in \texttt{ot1.etx}. (LH)
+
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1ij.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1ij.etx
new file mode 100644
index 0000000000..8564c3f50a
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1ij.etx
@@ -0,0 +1,56 @@
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% copyright 1998, 1999, 2002 the fontinst maintenance team
+% and any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/03/16]
+
+\title{The \texttt{OT1} encoding for italic fonts}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{See also the normal \texttt{OT1} encoding}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This file is used to install an italic \texttt{OT1}-encoded font with
+hanging (oldstyle) digits. It is necessary to distinguish between roman
+and italic in \texttt{OT1}, because the \texttt{sterling} and
+\texttt{dollar} glyphs share the same slot.
+
+\section{Default values}
+\showbranches
+\encoding
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1oldstyle}
+% \setcommand\currency{sterling}
+\setint{italicizing}{1}
+
+\inputetx{ot1}
+
+\endencoding
+
+\section{Changes}
+
+1999/10/27: Added \textsf{fontdoc} markup. (LH)
+
+2002/07/31:
+Minor update called for by changes in \texttt{ot1.etx}. (LH)
+
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1itt.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1itt.etx
new file mode 100644
index 0000000000..37e9c8e371
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1itt.etx
@@ -0,0 +1,70 @@
+% Copyright 1993 Alan Jeffrey,
+% copyright 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/10/16]
+
+\title{The \texttt{OT1} encoding for italic typewriter fonts}
+\author{Alan Jeffrey\and Lars Hellstr\"om}
+\date{See also the normal \texttt{OT1} encoding}
+
+\begin{document}
+\maketitle
+
+The main use for this file is conversion from PL to MTX format of the
+metrics for a font with the \texttt{TEX TYPEWRITER TEXT}
+codingscheme. It can also be used to install an \texttt{OT1}-%
+typewriter encoded font.
+
+\showbranches
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+% \setint{typewriter}{0}
+% \setcommand\currency{dollar}
+
+\setint{italicizing}{1}
+\setint{ligaturing}{0}
+
+\comment{Then we call \texttt{ot1.etx}.}
+
+\inputetx{ot1}
+
+\endencoding
+
+\section{Changes}
+
+1993/12/29: File created. (ASAJ)
+
+1999/11/04: Updated for v\,1.909 \texttt{ot1.etx} and added
+\textsf{fontdoc} markup. (LH)
+
+2002/07/31: Updated for v\,1.921 \texttt{ot1.etx} and corrected the
+name of the currency glyph. (LH)
+
+2004/11/24: Added ``italic'' to the document title. (LH)
+
+\end{document}
+
+
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1j.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1j.etx
new file mode 100644
index 0000000000..4fdd71bcad
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1j.etx
@@ -0,0 +1,52 @@
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% copyright 1998, 1999, 2002 the fontinst maintenance team
+% and any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/03/16]
+
+\title{The \texttt{OT1} encoding for italic fonts}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{See also the normal \texttt{OT1} encoding}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This file is used to install an \texttt{OT1}-encoded font with hanging
+(oldstyle) digits.
+
+\section{Default values}
+\showbranches
+\encoding
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1oldstyle}
+% \setcommand\currency{dollar}
+
+\inputetx{ot1}
+
+\endencoding
+
+\section{Changes}
+
+1999/10/27: Added \textsf{fontdoc} markup. (LH)
+
+2002/07/31: Minor fixes. (LH)
+
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/latinetx/ot1tt.etx b/fonts/utilities/fontinst/inputs/latinetx/ot1tt.etx
new file mode 100644
index 0000000000..23cbd66ac3
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/ot1tt.etx
@@ -0,0 +1,66 @@
+% Copyright 1993 Alan Jeffrey,
+% copyright 1999, 2002 the fontinst maintenance team
+% and any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/03/16]
+
+\title{The \texttt{OT1} encoding for typewriter fonts}
+\author{Alan Jeffrey\and Lars Hellstr\"om}
+\date{See also the normal \texttt{OT1} encoding}
+
+\begin{document}
+\maketitle
+
+The main use for this file is conversion from PL to MTX format of the
+metrics for a font with the \texttt{TEX TYPEWRITER TEXT}
+codingscheme. It can also be used to install an \texttt{OT1}-%
+encoded font with that codingscheme.
+
+\showbranches
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+% \setint{typewriter}{0}
+% \setcommand\currency{dollar}
+\setint{ligaturing}{0}
+
+\comment{Then we call \texttt{ot1.etx}.}
+
+\inputetx{ot1}
+
+\endencoding
+
+\section{Changes}
+
+1993/12/29: File created. (ASAJ)
+
+1999/11/04: Updated for v\,1.909 \texttt{ot1.etx} and added
+\textsf{fontdoc} markup. (LH)
+
+2002/07/31: Updated for v\,1.921 \texttt{ot1.etx}. (LH)
+
+\end{document}
+
+
diff --git a/fonts/utilities/fontinst/inputs/latinetx/t1.etx b/fonts/utilities/fontinst/inputs/latinetx/t1.etx
new file mode 100644
index 0000000000..e44ef1cdd1
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/t1.etx
@@ -0,0 +1,1478 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Alan Jeffrey and Sebastian Rahtz and
+%%% Ulrik Vieth and Lars Hellstr{\"o}m",
+%%% version = "1.932",
+%%% date = "2005-05-27",
+%%% time = "16:17:50 +02:00",
+%%% filename = "t1.etx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the T1 encoding as a TeX font encoding
+%%% file, for use with the fontinst utility.
+%%% It implements the TeX extended text encoding.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage[TS1,T1]{fontenc}
+\usepackage{textcomp}
+\usepackage{fontdoc}
+
+\showbranches
+
+\title{The \TeX\ extended text encoding vector}
+\author{Alan Jeffrey\and Sebastian Rahtz\and Ulrik Vieth\and
+ Lars Hellstr\"om}
+\date{26 October 2002\\Version 1.923}
+
+
+\begin{document}
+
+\maketitle
+
+\section{Introduction}
+
+This document describes the Cork (\texttt{T1}) text encoding.
+
+The following macros play an important role in this file, since they
+are involved in determining the names of most glyphs that will be put
+in some slot.
+\begin{itemize}
+\item
+ \verb|\lc{A}{a}| should return the name of a lower-case
+ glyph, for example `\texttt{a}' or `\texttt{Asmall}'.
+\item
+ \verb|\uc{A}{a}| should return the name of an upper-case
+ glyph, for example `\texttt{A}' or `\texttt{Amedium}'.
+\item
+ \verb|\lctop{Aacute}{aacute}| should return the name of a
+ lower-case composite glyph formed from putting a diacritical above
+ a letter, for example `\texttt{aacute}' or `\texttt{Aacutesmall}'.
+\item
+ \verb|\uctop{Aacute}{aacute}| should return the name of an
+ upper-case composite glyph formed from putting a diacritical above
+ a letter, for example `\texttt{Aacute}' or `\texttt{Aacutemedium}'.
+\item
+ \verb|\lclig{FI}{fi}| should return the name of a lower-case
+ ligature, for example `\texttt{fi}' or `\texttt{FIsmall}'.
+\item
+ \verb|\uclig{FI}{fi}| should return the name of an upper-case
+ ligature, for example `\texttt{FI}' or `\texttt{FImedium}'.
+\item
+ \verb|\digit{zero}| should return the name of a digit, for
+ example `\texttt{zero}' or `\texttt{zerooldstyle}'.
+\end{itemize}
+By explicitly defining them, the encoding can (to some extent) be
+customised. All these macros should expand in the mouth,
+otherwise you may get error messages!
+
+For example, to get the standard upper and lower case font (which is
+the default), you should define:
+\begin{verbatim}
+ \setcommand\lc#1#2{#2}
+ \setcommand\uc#1#2{#1}
+ \setcommand\lctop#1#2{#2}
+ \setcommand\uctop#1#2{#1}
+ \setcommand\lclig#1#2{#2}
+ \setcommand\uclig#1#2{#1}
+ \setcommand\digit#1{#1}
+\end{verbatim}
+To get a caps and small caps font with old style digits and letter
+spacing, you should define:
+\begin{verbatim}
+ \setcommand\lc#1#2{#1small}
+ \setcommand\uc#1#2{#1}
+ \setcommand\lctop#1#2{#1small}
+ \setcommand\uctop#1#2{#1}
+ \setcommand\lclig#1#2{#2small}
+ \setcommand\uclig#1#2{#1spaced}
+ \setcommand\digit#1{#1oldstyle}
+\end{verbatim}
+To get an all-caps font with medium-cap composite letters and letter
+spacing, you should define:
+\begin{verbatim}
+ \setcommand\lc#1#2{#1}
+ \setcommand\uc#1#2{#1}
+ \setcommand\lctop#1#2{#1medium}
+ \setcommand\uctop#1#2{#1medium}
+ \setcommand\lclig#1#2{#1spaced}
+ \setcommand\uclig#1#2{#1spaced}
+ \setcommand\digit#1{#1}
+\end{verbatim}
+In this document, the glyph names shown are for the upper and
+lower case variant.
+
+Another important parameter is the integer variable \textit{ligaturing},
+which controls to what extent (non-mandatory) ligatures are made. The
+value of this variable is interpreted as follows:
+\begin{enumerate}
+ \item[$1$]
+ All the standard ligature glyphs (\texttt{fi}, \texttt{fl},
+ \texttt{ff}, \texttt{ffi}, \texttt{ffl}, \texttt{IJ}, and
+ \texttt{ij}) are included and the normal ligaturing instructions
+ (those for the \texttt{f}-ligatures) are included.
+ \item[$0$]
+ All the standard ligature glyphs are included, but none of their
+ ligaturing instructions.
+ \item[$-1$]
+ The seven slots normally used for ligatures are left empty.
+ \item[$-2$]
+ The seven slots normally used for ligatures are left empty, as
+ are the slots normally used for \texttt{c}, \texttt{f},
+ \texttt{s}, \texttt{i}, and \texttt{I}.
+\end{enumerate}
+The default value is $0$ for monowidth or letterspaced fonts (because
+the ligature glyphs in such fonts are often useless, or at least not
+looking right) and $1$ otherwise. The negative values are useful when
+making fonts with a nonstandard set of ligatures; the idea is that
+some other (smaller) encoding file should set these remaining slots.
+
+
+\encoding
+
+\needsfontinstversion{1.910}
+
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lctop#1#2{#2}
+\setcommand\uctop#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\ifisint{letterspacing}\then
+ \ifnumber{\int{letterspacing}}={0}\then \Else
+ \setcommand\uclig#1#2{#1spaced}
+ \comment{Here we set \verb|\uclig#1#2| to \verb|#1spaced|, but
+ you can't see it as \verb|\setcommand| commands are invisible in
+ the typeset output.}
+ \Fi
+\Fi
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+
+
+\ifisint{monowidth}\then
+ \setint{ligaturing}{0}
+\Else
+ % The following empty line is *important* to get the formatting
+ % right here (sigh)! (Remember that it is a \par token.)
+
+ \ifisint{letterspacing}\then
+ \ifnumber{\int{letterspacing}}={0}\then \Else
+ \setint{ligaturing}{0}
+ \Fi
+ \Fi
+ \setint{ligaturing}{1}
+\Fi
+
+
+\comment{The remaining code in this section sets various metric
+parameters for the font. Ideally, all these parameters should already
+have been set; the values computed here are merely crude guesses
+about what might be the right value.}
+
+\setint{italicslant}{0}
+\setint{quad}{1000}
+\setint{baselineskip}{1200}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\ifisglyph{space}\then
+ \setint{interword}{\width{space}}
+\Else\ifisglyph{i}\then
+ \setint{interword}{\width{i}}
+\Else
+ \setint{interword}{333}
+\Fi\Fi
+
+\ifisint{monowidth}\then
+ \setint{stretchword}{0}
+ \setint{shrinkword}{0}
+ \setint{extraspace}{\int{interword}}
+\Else
+ \setint{stretchword}{\scale{\int{interword}}{600}}
+ \setint{shrinkword}{\scale{\int{interword}}{240}}
+ \setint{extraspace}{\scale{\int{interword}}{240}}
+\Fi
+
+% added by Thierry Bouche <Thierry.Bouche@ujf-grenoble.fr>
+% 1997/02/07 to calculate values for extra EC fontdimens
+% Amended by SPQR 1997/02/09
+\ifisglyph{X}\then
+ \setint{capheight}{\height{X}}
+\Else
+ \setint{capheight}{750}
+\Fi
+
+\ifisglyph{d}\then
+ \setint{ascender}{\height{d}}
+\Else\ifisint{capheight}\then
+ \setint{ascender}{\int{capheight}}
+\Else
+ \setint{ascender}{750}
+\Fi\Fi
+
+\ifisglyph{Aring}\then
+ \setint{acccapheight}{\height{Aring}}
+\Else
+ \setint{acccapheight}{999}
+\Fi
+
+\ifisint{descender_neg}\then
+ \setint{descender}{\neg{\int{descender_neg}}}
+\Else\ifisglyph{p}\then
+ \setint{descender}{\depth{p}}
+\Else
+ \setint{descender}{250}
+\Fi\Fi
+
+\ifisglyph{Aring}\then
+ \setint{maxheight}{\height{Aring}}
+\Else
+ \setint{maxheight}{1000}
+\Fi
+
+\ifisint{maxdepth_neg}\then
+ \setint{maxdepth}{\neg{\int{maxdepth_neg}}}
+\Else\ifisglyph{j}\then
+ \setint{maxdepth}{\depth{j}}
+\Else
+ \setint{maxdepth}{250}
+\Fi\Fi
+
+\ifisglyph{six}\then
+ \setint{digitwidth}{\width{six}}
+\Else
+ \setint{digitwidth}{500}
+\Fi
+
+\setint{capstem}{0} % not in AFM files
+% end changes by Thierry
+
+
+\begincomment
+\section{Font parameters}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+\setfontdimen{8}{capheight} % cap height
+\setfontdimen{9}{ascender} % ascender
+\setfontdimen{10}{acccapheight} % accented cap height
+\setfontdimen{11}{descender} % descender's depth
+\setfontdimen{12}{maxheight} % max height
+\setfontdimen{13}{maxdepth} % max depth
+\setfontdimen{14}{digitwidth} % digit width
+\setfontdimen{15}{verticalstem} % dominant width of verical stems
+\setfontdimen{16}{baselineskip} % baselineskip
+
+\ifnumber{\int{ligaturing}}<{0}\then
+ \comment{In this case, the codingscheme can be different from the
+ default, and therefore we refrain from setting it.}
+\Else
+ \setstr{codingscheme}{EXTENDED TEX FONT ENCODING - LATIN}
+\Fi
+
+
+
+\begincomment
+\section{The encoding}
+There are 256 glyphs in this encoding.
+\endcomment
+
+\setslot{\lc{Grave}{grave}}
+ \comment{The grave accent `\`{}'.}
+\endsetslot
+
+\setslot{\lc{Acute}{acute}}
+ \comment{The acute accent `\'{}'.}
+\endsetslot
+
+\setslot{\lc{Circumflex}{circumflex}}
+ \comment{The circumflex accent `\^{}'.}
+\endsetslot
+
+\setslot{\lc{Tilde}{tilde}}
+ \comment{The tilde accent `\~{}'.}
+\endsetslot
+
+\setslot{\lc{Dieresis}{dieresis}}
+ \comment{The umlaut or dieresis accent `\"{}'.}
+\endsetslot
+
+\setslot{\lc{Hungarumlaut}{hungarumlaut}}
+ \comment{The long Hungarian umlaut `\H{}'.}
+\endsetslot
+
+\setslot{\lc{Ring}{ring}}
+ \comment{The ring accent `\r{}'.}
+\endsetslot
+
+\setslot{\lc{Caron}{caron}}
+ \comment{The caron or h\'a\v cek accent `\v{}'.}
+\endsetslot
+
+\setslot{\lc{Breve}{breve}}
+ \comment{The breve accent `\u{}'.}
+\endsetslot
+
+\setslot{\lc{Macron}{macron}}
+ \comment{The macron accent `\={}'.}
+\endsetslot
+
+\setslot{\lc{Dotaccent}{dotaccent}}
+ \comment{The dot accent `\.{}'.}
+\endsetslot
+
+\setslot{\lc{Cedilla}{cedilla}}
+ \comment{The cedilla accent `\c {}'.}
+\endsetslot
+
+\setslot{\lc{Ogonek}{ogonek}}
+ \comment{The ogonek accent `\k {}'.}
+\endsetslot
+
+\setslot{quotesinglbase}
+ \comment{A German single quote mark `\quotesinglbase' similar to a comma,
+ but with different sidebearings.}
+\endsetslot
+
+\setslot{guilsinglleft}
+ \comment{A French single opening quote mark `\guilsinglleft',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{guilsinglright}
+ \comment{A French single closing quote mark `\guilsinglright',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{quotedblleft}
+ \comment{The English opening quote mark `\,\textquotedblleft\,'.}
+\endsetslot
+
+\setslot{quotedblright}
+ \comment{The English closing quote mark `\,\textquotedblright\,'.}
+\endsetslot
+
+\setslot{quotedblbase}
+ \comment{A German double quote mark `\quotedblbase' similar to two commas,
+ but with tighter letterspacing and different sidebearings.}
+\endsetslot
+
+\setslot{guillemotleft}
+ \comment{A French double opening quote mark `\guillemotleft',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{guillemotright}
+ \comment{A French closing opening quote mark `\guillemotright',
+ unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{rangedash}
+ \ligature{LIG}{hyphen}{punctdash}
+ \comment{The number range dash `1--9'. In a monowidth font, this
+ might be set as `\texttt{1{-}9}'.}
+\endsetslot
+
+\setslot{punctdash}
+ \comment{The punctuation dash `Oh---boy.' In a monowidth font, this
+ might be set as `\texttt{Oh{-}{-}boy.}'}
+\endsetslot
+
+\setslot{compwordmark}
+ \comment{An invisible glyph, with zero width and depth, but the
+ height of lowercase letters without ascenders.
+ It is used to stop ligaturing in words like `shelf{}ful'.}
+\endsetslot
+
+\setslot{perthousandzero}
+ \comment{A glyph which is placed after `\%' to produce a
+ `per-thousand', or twice to produce `per-ten-thousand'.
+ Your guess is as good as mine as to what this glyph should look
+ like in a monowidth font.}
+\endsetslot
+
+\setslot{\lc{dotlessI}{dotlessi}}
+ \comment{A dotless i `\i', used to produce accented letters such as
+ `\=\i'.}
+\endsetslot
+
+\setslot{\lc{dotlessJ}{dotlessj}}
+ \comment{A dotless j `\j', used to produce accented letters such as
+ `\=\j'. Most non-\TeX\ fonts do not have this glyph.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{0}\then \skipslots{5}\Else
+
+\setslot{\lclig{FF}{ff}}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{\lc{I}{i}}{\lclig{FFI}{ffi}}
+ \ligature{LIG}{\lc{L}{l}}{\lclig{FFL}{ffl}}
+ \Fi
+ \comment{The `ff' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FI}{fi}}
+ \comment{The `fi' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FL}{fl}}
+ \comment{The `fl' ligature. It should be two characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FFI}{ffi}}
+ \comment{The `ffi' ligature. It should be three characters wide in a
+ monowidth font.}
+\endsetslot
+
+\setslot{\lclig{FFL}{ffl}}
+ \comment{The `ffl' ligature. It should be three characters wide in a
+ monowidth font.}
+\endsetslot
+
+\Fi
+
+\setslot{visiblespace}
+ \comment{A visible space glyph `\textvisiblespace'.}
+\endsetslot
+
+\setslot{exclam}
+ \ligature{LIG}{quoteleft}{exclamdown}
+ \comment{The exclamation mark `!'.}
+\endsetslot
+
+\setslot{quotedbl}
+ \comment{The `neutral' double quotation mark `\,\textquotedbl\,',
+ included for use in monowidth fonts, or for setting computer
+ programs. Note that the inclusion of this glyph in this slot
+ means that \TeX\ documents which used `{\tt\char`\"}' as an
+ input character will no longer work.}
+\endsetslot
+
+\setslot{numbersign}
+ \comment{The hash sign `\#'.}
+\endsetslot
+
+\setslot{dollar}
+ \comment{The dollar sign `\$'.}
+\endsetslot
+
+\setslot{percent}
+ \comment{The percent sign `\%'.}
+\endsetslot
+
+\setslot{ampersand}
+ \comment{The ampersand sign `\&'.}
+\endsetslot
+
+\setslot{quoteright}
+ \ligature{LIG}{quoteright}{quotedblright}
+ \comment{The English closing single quote mark `\,\textquoteright\,'.}
+\endsetslot
+
+\setslot{parenleft}
+ \comment{The opening parenthesis `('.}
+\endsetslot
+
+\setslot{parenright}
+ \comment{The closing parenthesis `)'.}
+\endsetslot
+
+\setslot{asterisk}
+ \comment{The raised asterisk `*'.}
+\endsetslot
+
+\setslot{plus}
+ \comment{The addition sign `+'.}
+\endsetslot
+
+\setslot{comma}
+ \ligature{LIG}{comma}{quotedblbase}
+ \comment{The comma `,'.}
+\endsetslot
+
+\setslot{hyphen}
+ \ligature{LIG}{hyphen}{rangedash}
+ \ligature{LIG}{hyphenchar}{hyphenchar}
+ \comment{The hyphen `-'.}
+\endsetslot
+
+\setslot{period}
+ \comment{The period `.'.}
+\endsetslot
+
+\setslot{slash}
+ \comment{The forward oblique `/'.}
+\endsetslot
+
+\setslot{\digit{zero}}
+ \comment{The number `0'. This (and all the other numerals) may be
+ old style or ranging digits.}
+\endsetslot
+
+\setslot{\digit{one}}
+ \comment{The number `1'.}
+\endsetslot
+
+\setslot{\digit{two}}
+ \comment{The number `2'.}
+\endsetslot
+
+\setslot{\digit{three}}
+ \comment{The number `3'.}
+\endsetslot
+
+\setslot{\digit{four}}
+ \comment{The number `4'.}
+\endsetslot
+
+\setslot{\digit{five}}
+ \comment{The number `5'.}
+\endsetslot
+
+\setslot{\digit{six}}
+ \comment{The number `6'.}
+\endsetslot
+
+\setslot{\digit{seven}}
+ \comment{The number `7'.}
+\endsetslot
+
+\setslot{\digit{eight}}
+ \comment{The number `8'.}
+\endsetslot
+
+\setslot{\digit{nine}}
+ \comment{The number `9'.}
+\endsetslot
+
+\setslot{colon}
+ \comment{The colon punctuation mark `:'.}
+\endsetslot
+
+\setslot{semicolon}
+ \comment{The semi-colon punctuation mark `;'.}
+\endsetslot
+
+\setslot{less}
+ \ligature{LIG}{less}{guillemotleft}
+ \comment{The less-than sign `\textless'.}
+\endsetslot
+
+\setslot{equal}
+ \comment{The equals sign `='.}
+\endsetslot
+
+\setslot{greater}
+ \ligature{LIG}{greater}{guillemotright}
+ \comment{The greater-than sign `\textgreater'.}
+\endsetslot
+
+\setslot{question}
+ \ligature{LIG}{quoteleft}{questiondown}
+ \comment{The question mark `?'.}
+\endsetslot
+
+\setslot{at}
+ \comment{The at sign `@'.}
+\endsetslot
+
+\setslot{\uc{A}{a}}
+ \comment{The letter `{A}'.}
+\endsetslot
+
+\setslot{\uc{B}{b}}
+ \comment{The letter `{B}'.}
+\endsetslot
+
+\setslot{\uc{C}{c}}
+ \comment{The letter `{C}'.}
+\endsetslot
+
+\setslot{\uc{D}{d}}
+ \comment{The letter `{D}'.}
+\endsetslot
+
+\setslot{\uc{E}{e}}
+ \comment{The letter `{E}'.}
+\endsetslot
+
+\setslot{\uc{F}{f}}
+ \comment{The letter `{F}'.}
+\endsetslot
+
+\setslot{\uc{G}{g}}
+ \comment{The letter `{G}'.}
+\endsetslot
+
+\setslot{\uc{H}{h}}
+ \comment{The letter `{H}'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{-1}\then \skipslots{1}\Else
+
+\setslot{\uc{I}{i}}
+ \comment{The letter `{I}'.}
+\endsetslot
+
+\Fi
+
+\setslot{\uc{J}{j}}
+ \comment{The letter `{J}'.}
+\endsetslot
+
+\setslot{\uc{K}{k}}
+ \comment{The letter `{K}'.}
+\endsetslot
+
+\setslot{\uc{L}{l}}
+ \comment{The letter `{L}'.}
+\endsetslot
+
+\setslot{\uc{M}{m}}
+ \comment{The letter `{M}'.}
+\endsetslot
+
+\setslot{\uc{N}{n}}
+ \comment{The letter `{N}'.}
+\endsetslot
+
+\setslot{\uc{O}{o}}
+ \comment{The letter `{O}'.}
+\endsetslot
+
+\setslot{\uc{P}{p}}
+ \comment{The letter `{P}'.}
+\endsetslot
+
+\setslot{\uc{Q}{q}}
+ \comment{The letter `{Q}'.}
+\endsetslot
+
+\setslot{\uc{R}{r}}
+ \comment{The letter `{R}'.}
+\endsetslot
+
+\setslot{\uc{S}{s}}
+ \comment{The letter `{S}'.}
+\endsetslot
+
+\setslot{\uc{T}{t}}
+ \comment{The letter `{T}'.}
+\endsetslot
+
+\setslot{\uc{U}{u}}
+ \comment{The letter `{U}'.}
+\endsetslot
+
+\setslot{\uc{V}{v}}
+ \comment{The letter `{V}'.}
+\endsetslot
+
+\setslot{\uc{W}{w}}
+ \comment{The letter `{W}'.}
+\endsetslot
+
+\setslot{\uc{X}{x}}
+ \comment{The letter `{X}'.}
+\endsetslot
+
+\setslot{\uc{Y}{y}}
+ \comment{The letter `{Y}'.}
+\endsetslot
+
+\setslot{\uc{Z}{z}}
+ \comment{The letter `{Z}'.}
+\endsetslot
+
+\setslot{bracketleft}
+ \comment{The opening square bracket `['.}
+\endsetslot
+
+\setslot{backslash}
+ \comment{The backwards oblique `\textbackslash'.}
+\endsetslot
+
+\setslot{bracketright}
+ \comment{The closing square bracket `]'.}
+\endsetslot
+
+\setslot{asciicircum}
+ \comment{The ASCII upward-pointing arrow head `\textasciicircum'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{underscore}
+ \comment{The ASCII underline character `\textunderscore', usually
+ set on the baseline.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{quoteleft}
+ \ligature{LIG}{quoteleft}{quotedblleft}
+ \comment{The English opening single quote mark `\,\textquoteleft\,'.}
+\endsetslot
+
+\setslot{\lc{A}{a}}
+ \comment{The letter `{a}'.}
+\endsetslot
+
+\setslot{\lc{B}{b}}
+ \comment{The letter `{b}'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{-1}\then \skipslots{1}\Else
+
+ \setslot{\lc{C}{c}}
+ \comment{The letter `{c}'.}
+ \endsetslot
+
+\Fi
+
+\setslot{\lc{D}{d}}
+ \comment{The letter `{d}'.}
+\endsetslot
+
+\setslot{\lc{E}{e}}
+ \comment{The letter `{e}'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{-1}\then \skipslots{1}\Else
+
+ \setslot{\lc{F}{f}}
+ \ifnumber{\int{ligaturing}}>{0}\then
+ \ligature{LIG}{\lc{I}{i}}{\lclig{FI}{fi}}
+ \ligature{LIG}{\lc{F}{f}}{\lclig{FF}{ff}}
+ \ligature{LIG}{\lc{L}{l}}{\lclig{FL}{fl}}
+ \Fi
+ \comment{The letter `{f}'.}
+ \endsetslot
+
+\Fi
+
+\setslot{\lc{G}{g}}
+ \comment{The letter `{g}'.}
+\endsetslot
+
+\setslot{\lc{H}{h}}
+ \comment{The letter `{h}'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{-1}\then \skipslots{1}\Else
+
+ \setslot{\lc{I}{i}}
+ \comment{The letter `{i}'.}
+ \endsetslot
+
+\Fi
+
+\setslot{\lc{J}{j}}
+ \comment{The letter `{j}'.}
+\endsetslot
+
+\setslot{\lc{K}{k}}
+ \comment{The letter `{k}'.}
+\endsetslot
+
+\setslot{\lc{L}{l}}
+ \comment{The letter `{l}'.}
+\endsetslot
+
+\setslot{\lc{M}{m}}
+ \comment{The letter `{m}'.}
+\endsetslot
+
+\setslot{\lc{N}{n}}
+ \comment{The letter `{n}'.}
+\endsetslot
+
+\setslot{\lc{O}{o}}
+ \comment{The letter `{o}'.}
+\endsetslot
+
+\setslot{\lc{P}{p}}
+ \comment{The letter `{p}'.}
+\endsetslot
+
+\setslot{\lc{Q}{q}}
+ \comment{The letter `{q}'.}
+\endsetslot
+
+\setslot{\lc{R}{r}}
+ \comment{The letter `{r}'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{-1}\then \skipslots{1}\Else
+
+ \setslot{\lc{S}{s}}
+ \comment{The letter `{s}'.}
+ \endsetslot
+
+\Fi
+
+\setslot{\lc{T}{t}}
+ \comment{The letter `{t}'.}
+\endsetslot
+
+\setslot{\lc{U}{u}}
+ \comment{The letter `{u}'.}
+\endsetslot
+
+\setslot{\lc{V}{v}}
+ \comment{The letter `{v}'.}
+\endsetslot
+
+\setslot{\lc{W}{w}}
+ \comment{The letter `{w}'.}
+\endsetslot
+
+\setslot{\lc{X}{x}}
+ \comment{The letter `{x}'.}
+\endsetslot
+
+\setslot{\lc{Y}{y}}
+ \comment{The letter `{y}'.}
+\endsetslot
+
+\setslot{\lc{Z}{z}}
+ \comment{The letter `{z}'.}
+\endsetslot
+
+\setslot{braceleft}
+ \comment{The opening curly brace `\textbraceleft'.}
+\endsetslot
+
+\setslot{bar}
+ \comment{The ASCII vertical bar `\textbar'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{braceright}
+ \comment{The closing curly brace `\textbraceright'.}
+\endsetslot
+
+\setslot{asciitilde}
+ \comment{The ASCII tilde `\textasciitilde'.
+ This is included for compatibility with typewriter fonts used
+ for computer listings.}
+\endsetslot
+
+\setslot{hyphenchar}
+ \comment{The glyph used for hyphenation in this font, which will
+ almost always be the same as `hyphen'.}
+\endsetslot
+
+\setslot{\uctop{Abreve}{abreve}}
+ \comment{The letter `\u A'.}
+\endsetslot
+
+\setslot{\uc{Aogonek}{aogonek}}
+ \comment{The letter `\k A'.}
+\endsetslot
+
+\setslot{\uctop{Cacute}{cacute}}
+ \comment{The letter `\' C'.}
+\endsetslot
+
+\setslot{\uctop{Ccaron}{ccaron}}
+ \comment{The letter `\v C'.}
+\endsetslot
+
+\setslot{\uctop{Dcaron}{dcaron}}
+ \comment{The letter `\v D'.}
+\endsetslot
+
+\setslot{\uctop{Ecaron}{ecaron}}
+ \comment{The letter `\v E'.}
+\endsetslot
+
+\setslot{\uc{Eogonek}{eogonek}}
+ \comment{The letter `\k E'.}
+\endsetslot
+
+\setslot{\uctop{Gbreve}{gbreve}}
+ \comment{The letter `\u G'.}
+\endsetslot
+
+\setslot{\uctop{Lacute}{lacute}}
+ \comment{The letter `\' L'.}
+\endsetslot
+
+\setslot{\uc{Lcaron}{lcaron}}
+ \comment{The letter `\v L'.}
+\endsetslot
+
+\setslot{\uc{Lslash}{lslash}}
+ \comment{The letter `\L'.}
+\endsetslot
+
+\setslot{\uctop{Nacute}{nacute}}
+ \comment{The letter `\' N'.}
+\endsetslot
+
+\setslot{\uctop{Ncaron}{ncaron}}
+ \comment{The letter `\v N'.}
+\endsetslot
+
+\setslot{\uc{Ng}{ng}}
+ \comment{The Sami letter `\NG'. It is unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\uctop{Ohungarumlaut}{ohungarumlaut}}
+ \comment{The letter `\H O'.}
+\endsetslot
+
+\setslot{\uctop{Racute}{racute}}
+ \comment{The letter `\' R'.}
+\endsetslot
+
+\setslot{\uctop{Rcaron}{rcaron}}
+ \comment{The letter `\v R'.}
+\endsetslot
+
+\setslot{\uctop{Sacute}{sacute}}
+ \comment{The letter `\' S'.}
+\endsetslot
+
+\setslot{\uctop{Scaron}{scaron}}
+ \comment{The letter `\v S'.}
+\endsetslot
+
+\setslot{\uc{Scedilla}{scedilla}}
+ \comment{The letter `\c S'.}
+\endsetslot
+
+\setslot{\uctop{Tcaron}{tcaron}}
+ \comment{The letter `\v T'.}
+\endsetslot
+
+\setslot{\uc{Tcedilla}{tcedilla}}
+ \comment{The letter `\c T'.}
+\endsetslot
+
+\setslot{\uctop{Uhungarumlaut}{uhungarumlaut}}
+ \comment{The letter `\H U'.}
+\endsetslot
+
+\setslot{\uctop{Uring}{uring}}
+ \comment{The letter `\r U'.}
+\endsetslot
+
+\setslot{\uctop{Ydieresis}{ydieresis}}
+ \comment{The letter `\" Y'.}
+\endsetslot
+
+\setslot{\uctop{Zacute}{zacute}}
+ \comment{The letter `\' Z'.}
+\endsetslot
+
+\setslot{\uctop{Zcaron}{zcaron}}
+ \comment{The letter `\v Z'.}
+\endsetslot
+
+\setslot{\uctop{Zdotaccent}{zdotaccent}}
+ \comment{The letter `\. Z'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{0}\then \skipslots{1}\Else
+
+ \setslot{\uclig{IJ}{ij}}
+ \comment{The letter `IJ'. This is a single letter, and in a
+ monowidth font should ideally be one letter wide.}
+ \endsetslot
+
+\Fi
+
+\setslot{\uctop{Idotaccent}{idotaccent}}
+ \comment{The letter `\. I'.}
+\endsetslot
+
+\setslot{\lc{Dbar}{dbar}}
+ \comment{The letter `\dj'.}
+\endsetslot
+
+\setslot{section}
+ \comment{The section mark `\textsection'.}
+\endsetslot
+
+\setslot{\lctop{Abreve}{abreve}}
+ \comment{The letter `\u a'.}
+\endsetslot
+
+\setslot{\lc{Aogonek}{aogonek}}
+ \comment{The letter `\k a'.}
+\endsetslot
+
+\setslot{\lctop{Cacute}{cacute}}
+ \comment{The letter `\' c'.}
+\endsetslot
+
+\setslot{\lctop{Ccaron}{ccaron}}
+ \comment{The letter `\v c'.}
+\endsetslot
+
+\setslot{\lctop{Dcaron}{dcaron}}
+ \comment{The letter `\v d'.}
+\endsetslot
+
+\setslot{\lctop{Ecaron}{ecaron}}
+ \comment{The letter `\v e'.}
+\endsetslot
+
+\setslot{\lc{Eogonek}{eogonek}}
+ \comment{The letter `\k e'.}
+\endsetslot
+
+\setslot{\lctop{Gbreve}{gbreve}}
+ \comment{The letter `\u g'.}
+\endsetslot
+
+\setslot{\lctop{Lacute}{lacute}}
+ \comment{The letter `\' l'.}
+\endsetslot
+
+\setslot{\lc{Lcaron}{lcaron}}
+ \comment{The letter `\v l'.}
+\endsetslot
+
+\setslot{\lc{Lslash}{lslash}}
+ \comment{The letter `\l'.}
+\endsetslot
+
+\setslot{\lctop{Nacute}{nacute}}
+ \comment{The letter `\' n'.}
+\endsetslot
+
+\setslot{\lctop{Ncaron}{ncaron}}
+ \comment{The letter `\v n'.}
+\endsetslot
+
+\setslot{\lc{Ng}{ng}}
+ \comment{The Sami letter `\ng'. It is unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lctop{Ohungarumlaut}{ohungarumlaut}}
+ \comment{The letter `\H o'.}
+\endsetslot
+
+\setslot{\lctop{Racute}{racute}}
+ \comment{The letter `\' r'.}
+\endsetslot
+
+\setslot{\lctop{Rcaron}{rcaron}}
+ \comment{The letter `\v r'.}
+\endsetslot
+
+\setslot{\lctop{Sacute}{sacute}}
+ \comment{The letter `\' s'.}
+\endsetslot
+
+\setslot{\lctop{Scaron}{scaron}}
+ \comment{The letter `\v s'.}
+\endsetslot
+
+\setslot{\lc{Scedilla}{scedilla}}
+ \comment{The letter `\c s'.}
+\endsetslot
+
+\setslot{\lctop{Tcaron}{tcaron}}
+ \comment{The letter `\v t'.}
+\endsetslot
+
+\setslot{\lc{Tcedilla}{tcedilla}}
+ \comment{The letter `\c t'.}
+\endsetslot
+
+\setslot{\lctop{Uhungarumlaut}{uhungarumlaut}}
+ \comment{The letter `\H u'.}
+\endsetslot
+
+\setslot{\lctop{Uring}{uring}}
+ \comment{The letter `\r u'.}
+\endsetslot
+
+\setslot{\lctop{Ydieresis}{ydieresis}}
+ \comment{The letter `\" y'.}
+\endsetslot
+
+\setslot{\lctop{Zacute}{zacute}}
+ \comment{The letter `\' z'.}
+\endsetslot
+
+\setslot{\lctop{Zcaron}{zcaron}}
+ \comment{The letter `\v z'.}
+\endsetslot
+
+\setslot{\lctop{Zdotaccent}{zdotaccent}}
+ \comment{The letter `\. z'.}
+\endsetslot
+
+\ifnumber{\int{ligaturing}}<{0}\then \skipslots{1}\Else
+
+ \setslot{\lclig{IJ}{ij}}
+ \comment{The letter `ij'. This is a single letter, and in a
+ monowidth font should ideally be one letter wide.}
+ \endsetslot
+
+\Fi
+
+\setslot{exclamdown}
+ \comment{The Spanish punctuation mark `!`'.}
+\endsetslot
+
+\setslot{questiondown}
+ \comment{The Spanish punctuation mark `?`'.}
+\endsetslot
+
+\setslot{sterling}
+ \comment{The British currency mark `\textsterling'.}
+\endsetslot
+
+\setslot{\uctop{Agrave}{agrave}}
+ \comment{The letter `\` A'.}
+\endsetslot
+
+\setslot{\uctop{Aacute}{aacute}}
+ \comment{The letter `\' A'.}
+\endsetslot
+
+\setslot{\uctop{Acircumflex}{acircumflex}}
+ \comment{The letter `\^ A'.}
+\endsetslot
+
+\setslot{\uctop{Atilde}{atilde}}
+ \comment{The letter `\~ A'.}
+\endsetslot
+
+\setslot{\uctop{Adieresis}{adieresis}}
+ \comment{The letter `\" A'.}
+\endsetslot
+
+\setslot{\uctop{Aring}{aring}}
+ \comment{The letter `\r A'.}
+\endsetslot
+
+\setslot{\uc{AE}{ae}}
+ \comment{The letter `\AE'. This is a single letter, and should not be
+ faked with `AE'.}
+\endsetslot
+
+\setslot{\uc{Ccedilla}{ccedilla}}
+ \comment{The letter `\c C'.}
+\endsetslot
+
+\setslot{\uctop{Egrave}{egrave}}
+ \comment{The letter `\` E'.}
+\endsetslot
+
+\setslot{\uctop{Eacute}{eacute}}
+ \comment{The letter `\' E'.}
+\endsetslot
+
+\setslot{\uctop{Ecircumflex}{ecircumflex}}
+ \comment{The letter `\^ E'.}
+\endsetslot
+
+\setslot{\uctop{Edieresis}{edieresis}}
+ \comment{The letter `\" E'.}
+\endsetslot
+
+\setslot{\uctop{Igrave}{igrave}}
+ \comment{The letter `\` I'.}
+\endsetslot
+
+\setslot{\uctop{Iacute}{iacute}}
+ \comment{The letter `\' I'.}
+\endsetslot
+
+\setslot{\uctop{Icircumflex}{icircumflex}}
+ \comment{The letter `\^ I'.}
+\endsetslot
+
+\setslot{\uctop{Idieresis}{idieresis}}
+ \comment{The letter `\" I'.}
+\endsetslot
+
+\setslot{\uc{Eth}{eth}}
+ \comment{The uppercase Icelandic letter `Eth' similar to a `D'
+ with a horizontal bar through the stem. It is unavailable
+ in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\uctop{Ntilde}{ntilde}}
+ \comment{The letter `\~ N'.}
+\endsetslot
+
+\setslot{\uctop{Ograve}{ograve}}
+ \comment{The letter `\` O'.}
+\endsetslot
+
+\setslot{\uctop{Oacute}{oacute}}
+ \comment{The letter `\' O'.}
+\endsetslot
+
+\setslot{\uctop{Ocircumflex}{ocircumflex}}
+ \comment{The letter `\^ O'.}
+\endsetslot
+
+\setslot{\uctop{Otilde}{otilde}}
+ \comment{The letter `\~ O'.}
+\endsetslot
+
+\setslot{\uctop{Odieresis}{odieresis}}
+ \comment{The letter `\" O'.}
+\endsetslot
+
+\setslot{\uc{OE}{oe}}
+ \comment{The letter `\OE'. This is a single letter, and should not be
+ faked with `OE'.}
+\endsetslot
+
+\setslot{\uc{Oslash}{oslash}}
+ \comment{The letter `\O'.}
+\endsetslot
+
+\setslot{\uctop{Ugrave}{ugrave}}
+ \comment{The letter `\` U'.}
+\endsetslot
+
+\setslot{\uctop{Uacute}{uacute}}
+ \comment{The letter `\' U'.}
+\endsetslot
+
+\setslot{\uctop{Ucircumflex}{ucircumflex}}
+ \comment{The letter `\^ U'.}
+\endsetslot
+
+\setslot{\uctop{Udieresis}{udieresis}}
+ \comment{The letter `\" U'.}
+\endsetslot
+
+\setslot{\uctop{Yacute}{yacute}}
+ \comment{The letter `\' Y'.}
+\endsetslot
+
+\setslot{\uc{Thorn}{thorn}}
+ \comment{The Icelandic capital letter Thorn, similar to a `P'
+ with the bowl moved down. It is unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\uclig{SS}{germandbls}}
+ \comment{The ligature `SS', used to give an upper case `\ss'.
+ In a monowidth font it should be two letters wide.}
+\endsetslot
+
+\setslot{\lctop{Agrave}{agrave}}
+ \comment{The letter `\` a'.}
+\endsetslot
+
+\setslot{\lctop{Aacute}{aacute}}
+ \comment{The letter `\' a'.}
+\endsetslot
+
+\setslot{\lctop{Acircumflex}{acircumflex}}
+ \comment{The letter `\^ a'.}
+\endsetslot
+
+\setslot{\lctop{Atilde}{atilde}}
+ \comment{The letter `\~ a'.}
+\endsetslot
+
+\setslot{\lctop{Adieresis}{adieresis}}
+ \comment{The letter `\" a'.}
+\endsetslot
+
+\setslot{\lctop{Aring}{aring}}
+ \comment{The letter `\r a'.}
+\endsetslot
+
+\setslot{\lc{AE}{ae}}
+ \comment{The letter `\ae'. This is a single letter, and should not be
+ faked with `ae'.}
+\endsetslot
+
+\setslot{\lc{Ccedilla}{ccedilla}}
+ \comment{The letter `\c c'.}
+\endsetslot
+
+\setslot{\lctop{Egrave}{egrave}}
+ \comment{The letter `\` e'.}
+\endsetslot
+
+\setslot{\lctop{Eacute}{eacute}}
+ \comment{The letter `\' e'.}
+\endsetslot
+
+\setslot{\lctop{Ecircumflex}{ecircumflex}}
+ \comment{The letter `\^ e'.}
+\endsetslot
+
+\setslot{\lctop{Edieresis}{edieresis}}
+ \comment{The letter `\" e'.}
+\endsetslot
+
+\setslot{\lctop{Igrave}{igrave}}
+ \comment{The letter `\`\i'.}
+\endsetslot
+
+\setslot{\lctop{Iacute}{iacute}}
+ \comment{The letter `\'\i'.}
+\endsetslot
+
+\setslot{\lctop{Icircumflex}{icircumflex}}
+ \comment{The letter `\^\i'.}
+\endsetslot
+
+\setslot{\lctop{Idieresis}{idieresis}}
+ \comment{The letter `\"\i'.}
+\endsetslot
+
+\setslot{\lc{Eth}{eth}}
+ \comment{The Icelandic lowercase letter `eth' similar to
+ a `$\partial$' with an oblique bar through the stem.
+ It is unavailable in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lctop{Ntilde}{ntilde}}
+ \comment{The letter `\~ n'.}
+\endsetslot
+
+\setslot{\lctop{Ograve}{ograve}}
+ \comment{The letter `\` o'.}
+\endsetslot
+
+\setslot{\lctop{Oacute}{oacute}}
+ \comment{The letter `\' o'.}
+\endsetslot
+
+\setslot{\lctop{Ocircumflex}{ocircumflex}}
+ \comment{The letter `\^ o'.}
+\endsetslot
+
+\setslot{\lctop{Otilde}{otilde}}
+ \comment{The letter `\~ o'.}
+\endsetslot
+
+\setslot{\lctop{Odieresis}{odieresis}}
+ \comment{The letter `\" o'.}
+\endsetslot
+
+\setslot{\lc{OE}{oe}}
+ \comment{The letter `\oe'. This is a single letter, and should not be
+ faked with `oe'.}
+\endsetslot
+
+\setslot{\lc{Oslash}{oslash}}
+ \comment{The letter `\o'.}
+\endsetslot
+
+\setslot{\lctop{Ugrave}{ugrave}}
+ \comment{The letter `\` u'.}
+\endsetslot
+
+\setslot{\lctop{Uacute}{uacute}}
+ \comment{The letter `\' u'.}
+\endsetslot
+
+\setslot{\lctop{Ucircumflex}{ucircumflex}}
+ \comment{The letter `\^ u'.}
+\endsetslot
+
+\setslot{\lctop{Udieresis}{udieresis}}
+ \comment{The letter `\" u'.}
+\endsetslot
+
+\setslot{\lctop{Yacute}{yacute}}
+ \comment{The letter `\' y'.}
+\endsetslot
+
+\setslot{\lc{Thorn}{thorn}}
+ \comment{The Icelandic lowercase letter `thorn', similar to a `p'
+ with an ascender rising from the stem. It is unavailable
+ in \plain\ \TeX.}
+\endsetslot
+
+\setslot{\lc{SS}{germandbls}}
+ \comment{The letter `\ss'.}
+\endsetslot
+
+\endencoding
+
+
+\section{Changes}
+
+This is one of the files which have been with \textsf{fontinst}
+``forever'', so a lot of the early changes where probably never
+recorded. The following are from the \texttt{CHANGES} file.
+
+1994/06/01 (v\,1.327): Removed the f-ligatures for monowidth fonts.
+(ASAJ) Sebastian spotted that one.
+
+1994/11/29 (v\,1.401): Added \texttt{hyphen}${}*{}$\texttt{hyphenchar}%
+${}\rightarrow{}$\texttt{hyphenchar} ligature (so that foo-bar words
+can be hyphenated as foo$\langle\mbox{\textit{hyphenchar}}\rangle$bar)%
+---spotted by Frank Mittelbach. Made default stretch and shrink 50\%
+and 16.7\% of interword space respectively. (ASAJ)
+
+1996/01/23 (v\,1.504):
+Included some of Sebastian's changes: upped stretch and shrink to $.6$
+and $.24$ of space; reduced extra space after {.} to $.24$ of space;
+made \verb|\setslot{grave}| etc.\ into
+\verb|\setslot{\lc{Grave}{grave}}| etc. (ASAJ)
+
+\bigskip
+\noindent The following changes have been made after changes stopped
+being recorded in the \texttt{CHANGES} file.
+
+1997/02/07 (v\,1.7): Added code for calculating values for and setting
+the extra fontdimens found in the \texttt{ec} fonts. (Thierry Bouche)
+
+1998/06/29 (v\,1.8): Using \texttt{T1} encoding for character
+examples. (UV)
+
+2002/10/26 (v\,1.923): Added \TypesetIntegerExpression{\int{ligaturing}}
+parameter. Using \verb|\showbranches|. Using \verb|\setfontdimen|.
+Changed definition of fontdimen 15 slightly---from ``the width of
+capital vertical stems'' to ``the dominant width of vertical stems'',
+which is provided in AFM files. (LH)
+
+2005/05/27 (v\,1.932): Modified defaults for |\uclig| and
+$\TypesetIntegerExpression{\int{ligaturing}}$ in fonts with
+letterspacing, to use \texttt{spaced} glyphs and not make ligatures
+respectively. (LH) Rationale (from discussion with Philipp Lehman):
+The non-\texttt{spaced} and ready-made ligature glyphs are often
+unnaturally cramped in comparison with other letterspaced character
+sequences. The system is probably overly complicated, but can be kept
+for historical reasons.
+
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinetx/t1c.etx b/fonts/utilities/fontinst/inputs/latinetx/t1c.etx
new file mode 100644
index 0000000000..2805f64d46
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/t1c.etx
@@ -0,0 +1,63 @@
+\relax
+
+% t1c.etx -- install a T1-encoded faked small-caps font
+%
+% This is used to install expertized or faked small-caps fonts;
+% real small caps fonts built from fonts with variant c8r are
+% installed using the default t1.etx.
+
+\encoding
+
+% We define the parameters for t1.etx to produce a c&sc font.
+
+\setcommand\lc#1#2{#1small}
+\setcommand\uc#1#2{#1}
+\setcommand\lctop#1#2{#1small}
+\setcommand\uctop#1#2{#1}
+\setcommand\lclig#1#2{#1small}
+\setcommand\uclig#1#2{#1spaced}
+\setcommand\digit#1{#1}
+
+%%
+ % Commented out 2002/12/14, since t1.etx does this more carefully
+ % anyway. It could perhaps be useful to use the width of `Ismall'
+ % instead of `i', but even that is dubious. (LH)
+ %
+ % \ifisglyph{space}\then
+ % \setint{interword}{\width{space}}
+ % \else\ifisglyph{i}\then
+ % \setint{interword}{\width{i}}
+ % \else
+ % \setint{interword}{333}
+ % \fi\fi
+ %%
+
+%%
+ % Commented out 2002/12/14, since these parameters are anyway never used
+ % by t1.etx (they are used by latin.mtx, but by the time we get here, that
+ % file has already been processed). (LH)
+ %
+ % % The default letter spacing is 1/10 of the design size, with small
+ % % caps 80% the size of large caps.
+ %
+ % \setint{smallcapsscale}{800}
+ %
+ % \ifisint{monowidth}\then
+ % \setint{smallcapsextraspace}
+ % {\div{\scale{\int{interword}}{\sub{1000}{\int{smallcapsscale}}}}{2}}
+ % \setint{smallcapsspacing}{0}
+ % \else
+ % \setint{smallcapsextraspace}{50}
+ % \setint{smallcapsspacing}{50}
+ % \fi
+ %%
+
+\ifisint{capspacing}\then
+ \setint{letterspacing}{\int{capspacing}}
+\fi
+
+% Then we call t1.etx.
+
+\inputetx{t1}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/latinetx/t1cj.etx b/fonts/utilities/fontinst/inputs/latinetx/t1cj.etx
new file mode 100644
index 0000000000..2c80b3821b
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/t1cj.etx
@@ -0,0 +1,51 @@
+\relax
+
+% t1cj.etx -- install a T1-encoded faked small-caps & oldstyle font
+%
+% This is used to install expertized or faked small-caps fonts;
+% real small caps fonts built from fonts with variant c8r are
+% installed using the default t1.etx.
+
+\encoding
+
+% We define the parameters for t1.etx to produce a c&sc font.
+
+\setcommand\lc#1#2{#1small}
+\setcommand\uc#1#2{#1}
+\setcommand\lctop#1#2{#1small}
+\setcommand\uctop#1#2{#1}
+\setcommand\lclig#1#2{#1small}
+\setcommand\uclig#1#2{#1spaced}
+\setcommand\digit#1{#1oldstyle}
+
+% The default letter spacing is 1/10 of the design size, with small
+% caps 80% the size of large caps.
+
+\setint{smallcapsscale}{800}
+
+\ifisglyph{space}\then
+ \setint{interword}{\width{space}}
+\else\ifisglyph{i}\then
+ \setint{interword}{\width{i}}
+\else
+ \setint{interword}{333}
+\fi\fi
+
+\ifisint{monowidth}\then
+ \setint{smallcapsextraspace}
+ {\div{\scale{\int{interword}}{\sub{1000}{\int{smallcapsscale}}}}{2}}
+ \setint{smallcapsspacing}{0}
+\else
+ \setint{smallcapsextraspace}{50}
+ \setint{smallcapsspacing}{50}
+\fi
+
+\ifisint{capspacing}\then
+ \setint{letterspacing}{\int{capspacing}}
+\fi
+
+% Then we call t1.etx.
+
+\inputetx{t1}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/latinetx/t1i.etx b/fonts/utilities/fontinst/inputs/latinetx/t1i.etx
new file mode 100644
index 0000000000..99b9819b20
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/t1i.etx
@@ -0,0 +1,20 @@
+\relax
+
+% t1i.etx -- install a T1-encoded italic font
+%
+% We do not need to distinguish between roman and italic in T1,
+% hence we simply call t1.etx with default parameters.
+
+\encoding
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lctop#1#2{#2}
+\setcommand\uctop#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1}
+
+\inputetx{t1}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/latinetx/t1ij.etx b/fonts/utilities/fontinst/inputs/latinetx/t1ij.etx
new file mode 100644
index 0000000000..6eb3e28619
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/t1ij.etx
@@ -0,0 +1,20 @@
+\relax
+
+% t1ij.etx -- install a T1-encoded italic font with oldstyle digits
+%
+% We do not need to distinguish between roman and italic in T1,
+% hence we simply call t1.etx with oldstyle parameters.
+
+\encoding
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lctop#1#2{#2}
+\setcommand\uctop#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1oldstyle}
+
+\inputetx{t1}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/latinetx/t1j.etx b/fonts/utilities/fontinst/inputs/latinetx/t1j.etx
new file mode 100644
index 0000000000..b8e575968e
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/t1j.etx
@@ -0,0 +1,20 @@
+\relax
+
+% t1j.etx -- install a T1-encoded roman font with oldstyle digits
+%
+% We do not need to distinguish between roman and italic in T1,
+% hence we simply call t1.etx with oldstyle parameters.
+
+\encoding
+
+\setcommand\lc#1#2{#2}
+\setcommand\uc#1#2{#1}
+\setcommand\lctop#1#2{#2}
+\setcommand\uctop#1#2{#1}
+\setcommand\lclig#1#2{#2}
+\setcommand\uclig#1#2{#1}
+\setcommand\digit#1{#1oldstyle}
+
+\inputetx{t1}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/latinetx/txtfdmns.etx b/fonts/utilities/fontinst/inputs/latinetx/txtfdmns.etx
new file mode 100644
index 0000000000..a2242468b6
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinetx/txtfdmns.etx
@@ -0,0 +1,136 @@
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\begin{document}
+
+\title{\texttt{textfdim} --- text font dimensions}
+\author{Alan Jeffrey\and Thierry Bouche\and Sebastian Rahtz\and
+ Lars Hellstr\"om}
+\date{2002/10/25}
+\maketitle
+
+\begin{abstract}
+ This encoding file sets font dimensions 1--16 as for modern
+ (\texttt{T1}-encoded) text fonts. Much of the code comes from
+ \texttt{t1.etx}.
+\end{abstract}
+
+\showbranches
+
+\encoding
+
+\needsfontinstversion{1.917}
+
+\begincomment
+\section{Default values}
+
+This code tries to produce reasonable values for the font dimensions,
+in case the font metrics didn't specify them. Preferably, all the
+integers computed below should already be set.
+\endcomment
+
+
+\setint{italicslant}{0}
+\setint{quad}{1000}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\ifisglyph{space}\then
+ \setint{interword}{\width{space}}
+\Else\ifisglyph{i}\then
+ \setint{interword}{\width{i}}
+\Else
+ \setint{interword}{333}
+\Fi\Fi
+
+\ifisint{monowidth}\then
+ \setint{stretchword}{0}
+ \setint{shrinkword}{0}
+ \setint{extraspace}{\int{interword}}
+\Else
+ \setint{stretchword}{\scale{\int{interword}}{600}}
+ \setint{shrinkword}{\scale{\int{interword}}{240}}
+ \setint{extraspace}{\scale{\int{interword}}{240}}
+\Fi
+
+
+\ifisglyph{X}\then
+ \setint{capheight}{\height{X}}
+\Else
+ \setint{capheight}{750}
+\Fi
+
+\ifisglyph{d}\then
+ \setint{ascender}{\height{d}}
+\Else
+ \setint{ascender}{\int{capheight}}
+\Fi
+
+\ifisglyph{Aring}\then
+ \setint{acccapheight}{\height{Aring}}
+ \setint{maxheight}{\height{Aring}}
+\Else
+ \setint{acccapheight}{999}
+ \setint{maxheight}{1000}
+\Fi
+
+\ifisint{descender_neg}\then
+ \setint{descender}{\neg{\int{descender_neg}}}
+\Else\ifisglyph{p}\then
+ \setint{descender}{\depth{p}}
+\Else
+ \setint{descender}{250}
+\Fi\Fi
+
+
+\ifisint{maxdepth_neg}\then
+ \setint{maxdepth}{\neg{\int{maxdepth_neg}}}
+\Else\ifisglyph{j}\then
+ \setint{maxdepth}{\depth{j}}
+\Else
+ \setint{maxdepth}{250}
+\Fi\Fi
+
+\ifisglyph{six}\then
+ \setint{digitwidth}{\width{six}}
+\Else
+ \setint{digitwidth}{500}
+\Fi
+
+\setint{baselineskip}{1200}
+
+
+\begincomment
+\section{Defining font dimensions}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+\setfontdimen{8}{capheight} % cap height
+\setfontdimen{9}{ascender} % ascender
+\setfontdimen{10}{acccapheight} % accented cap height
+\setfontdimen{11}{descender} % descender's depth
+\setfontdimen{12}{maxheight} % max height
+\setfontdimen{13}{maxdepth} % max depth
+\setfontdimen{14}{digitwidth} % digit width
+\setfontdimen{15}{verticalstem} % dominant width of verical stems
+\setfontdimen{16}{baselineskip} % baselineskip
+
+\endencoding
+
+\section{Changes}
+
+This file was created 2002/10/25.
+
+\end{document} \ No newline at end of file
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/8r.mtx b/fonts/utilities/fontinst/inputs/latinmtx/8r.mtx
new file mode 100644
index 0000000000..b15d84069f
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/8r.mtx
@@ -0,0 +1,234 @@
+% Copyright 1994, 1995, 1996 Constantin Kahn, Sebastian Rathz, and
+% Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rathz,
+% copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Constantin Kahn and Sebastian Rathz and
+%%% Ulrik Vieth and Lars Hellstr{\"o}m",
+%%% version = "1.910",
+%%% date = "15 November 1999",
+%%% time = "21:54:57 CET",
+%%% filename = "8r.mtx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "26393 234 602 7162",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, raw, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the 8r metrics file, for use with the
+%%% fontinst utility. It is used to install raw
+%%% fonts using the 8r encoding.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+% List of changes now at end of file.
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/10/16]
+
+\title{The metric adjustments for ligful \texttt{8r}-encoded fonts}
+\author{Constantin Kahn\and Sebastian Rathz\and
+ Ulrik Vieth\and Lars Hellstr\"om}
+\date{15 November 1999 \\
+Version 1.910}
+
+\begin{document}
+\maketitle
+
+This file is just the part of \texttt{latin.mtx} that's needed for
+installing kern-and-ligful \texttt{8r} fonts.
+
+\showbranches
+
+\metrics
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Duplicating glyphs}
+
+This part has been commented out since as of v\,1.9 \textsf{fontinst}
+has no problem putting the same glyph in several slots (it used to
+cause some kerns and ligatures to be lost).
+\endcomment
+
+% Get a `space' into the `alternate-space' slot (nee `nbspace')
+%
+%\setglyph{alternate-space}
+% \glyph{space}{1000}
+%\endsetglyph
+
+
+% \setglyph{alternate-hyphen}
+% \glyph{hyphen}{1000}
+% \comment{Get a \texttt{hyphen} into the \texttt{alternate-hyphen}
+% slot (nee \texttt{softhyphen}).}
+% \endsetglyph
+
+% The LGC claims that `quoteleft' and `quoteright' appear twice,
+% which is not the case for 8r.enc, but does apply for texnansi.enc.
+% We prefer the ASCII position and mark the second one as unused.
+%
+%\setglyph{quoteleft-unused}
+% \glyph{quoteleft}{1000}
+%\endsetglyph
+%\setglyph{quoteright-unused}
+% \glyph{quoteright}{1000}
+%\endsetglyph
+
+
+\begincomment
+\section{Kerning}
+Kern accented characters the same way as their base characters.
+Characters are listed in the order in which they appear in
+\texttt{8r.enc}.
+\endcomment
+
+
+% 0-31, 128-159
+\setleftrightkerning{Lslash}{L}{1000}
+%\setleftrightkerning{lslash}{l}{1000}
+
+\setleftrightkerning{Zcaron}{Z}{1000}
+%\setleftrightkerning{zcaron}{z}{1000}
+
+\setleftrightkerning{Scaron}{S}{1000}
+%\setleftrightkerning{scaron}{s}{1000}
+
+\setleftrightkerning{Ydieresis}{Y}{1000}
+
+% 192-255
+\setleftrightkerning{Agrave}{A}{1000}
+\setleftrightkerning{Aacute}{A}{1000}
+\setleftrightkerning{Acircumflex}{A}{1000}
+\setleftrightkerning{Atilde}{A}{1000}
+\setleftrightkerning{Adieresis}{A}{1000}
+\setleftrightkerning{Aring}{A}{1000}
+
+\setleftrightkerning{Ccedilla}{C}{1000}
+
+\setleftrightkerning{Egrave}{E}{1000}
+\setleftrightkerning{Eacute}{E}{1000}
+\setleftrightkerning{Ecircumflex}{E}{1000}
+\setleftrightkerning{Edieresis}{E}{1000}
+
+\setleftrightkerning{Igrave}{I}{1000}
+\setleftrightkerning{Iacute}{I}{1000}
+\setleftrightkerning{Icircumflex}{I}{1000}
+\setleftrightkerning{Idieresis}{I}{1000}
+
+\setleftrightkerning{Ograve}{O}{1000}
+\setleftrightkerning{Oacute}{O}{1000}
+\setleftrightkerning{Ocircumflex}{O}{1000}
+\setleftrightkerning{Otilde}{O}{1000}
+\setleftrightkerning{Odieresis}{O}{1000}
+\setleftrightkerning{Oslash}{O}{1000}
+
+\setleftrightkerning{Ugrave}{U}{1000}
+\setleftrightkerning{Uacute}{U}{1000}
+\setleftrightkerning{Ucircumflex}{U}{1000}
+\setleftrightkerning{Udieresis}{U}{1000}
+
+\setleftrightkerning{Yacute}{Y}{1000}
+
+%\setleftrightkerning{agrave}{a}{1000}
+%\setleftrightkerning{aacute}{a}{1000}
+%\setleftrightkerning{acircumflex}{a}{1000}
+%\setleftrightkerning{atilde}{a}{1000}
+%\setleftrightkerning{adieresis}{a}{1000}
+%\setleftrightkerning{aring}{a}{1000}
+
+\setleftrightkerning{ccedilla}{c}{1000}
+
+%\setleftrightkerning{egrave}{e}{1000}
+%\setleftrightkerning{eacute}{e}{1000}
+%\setleftrightkerning{ecircumflex}{e}{1000}
+%\setleftrightkerning{edieresis}{e}{1000}
+
+%\setleftrightkerning{igrave}{i}{1000}
+%\setleftrightkerning{iacute}{i}{1000}
+%\setleftrightkerning{icircumflex}{i}{1000}
+%\setleftrightkerning{idieresis}{i}{1000}
+
+%\setleftrightkerning{ograve}{o}{1000}
+%\setleftrightkerning{oacute}{o}{1000}
+%\setleftrightkerning{ocircumflex}{o}{1000}
+%\setleftrightkerning{otilde}{o}{1000}
+%\setleftrightkerning{odieresis}{o}{1000}
+%\setleftrightkerning{oslash}{o}{1000}
+
+%\setleftrightkerning{ugrave}{u}{1000}
+%\setleftrightkerning{uacute}{u}{1000}
+%\setleftrightkerning{ucircumflex}{u}{1000}
+%\setleftrightkerning{udieresis}{u}{1000}
+
+%\setleftrightkerning{yacute}{y}{1000}
+%\setleftrightkerning{ydieresis}{y}{1000}
+
+\begincomment
+\section{Adjusting depth of accents}
+We copy the \verb|\zerodepth| stuff from \texttt{latin.mtx}:
+\endcomment
+
+\setcommand\zerodepth#1{
+ \ifisglyph{#1}\then
+ \resetglyph{#1}
+ \glyph{#1}{1000}
+ \resetdepth{0}
+ \endresetglyph
+ \Fi
+}
+\zerodepth{acute}
+\zerodepth{grave}
+\zerodepth{caron}
+\zerodepth{breve}
+\zerodepth{macron}
+\zerodepth{ring}
+\zerodepth{circumflex}
+\zerodepth{dotaccent}
+\zerodepth{tilde}
+\zerodepth{dieresis}
+
+\endmetrics
+
+\section{Changes}
+
+This file used to contains more kerning commands for lower case glyphs
+than \texttt{latin.mtx} but these were commented out February 1997
+after representation on \TeX-fonts list by Thierry Bouche and others.
+\global\parindent=1em
+
+It also adds a default for the \texttt{alternate-hyphen} glyph.
+
+1997/02/03: An \verb|\ifisglyph| test was added to \verb|\zerodepth|.
+(SPQR)
+
+1998/06/11: \verb|\needsfontinstversion| was updated (to v\,1.800) and
+the definition of \verb|\setleftrightkerning| was removed (now defined
+in \texttt{fontinst.sty}). (UV)
+
+1999/10/25: A typo regarding \texttt{quoteright-unused} (in code
+commented out) was corrected. (UV\&LH)
+
+1999/10/29: \textsf{fontdoc} markup was added and the
+\verb|\needsfontinstversion| was increased to v\,1.900. (LH)
+
+1999/11/10: Code setting \texttt{alternate-hyphen} commented out,
+adjustments made for \verb|\showbranches|, and
+\verb|\needsfontinstversion| was increased to v\,1.909. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/8y.mtx b/fonts/utilities/fontinst/inputs/latinmtx/8y.mtx
new file mode 100644
index 0000000000..aca2ea3b9f
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/8y.mtx
@@ -0,0 +1,251 @@
+% Copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Ulrik Vieth and Lars Hellstr{\"o}m",
+%%% version = "1.910",
+%%% date = "15 November 1999",
+%%% time = "21:55:14 CET",
+%%% filename = "8y.mtx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "",
+%%% checksum = "58019 251 594 7215",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, raw, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the 8y metrics file, for use with the
+%%% fontinst utility. It is used to install raw
+%%% fonts using the 8y encoding.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+% List of changes now at end of file.
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\title{The metric adjustments for ligful \texttt{8y}-encoded fonts}
+\author{Constantin Kahn\and
+ Sebastian Rathz\and
+ Ulrik Vieth\and
+ Lars Hellstr\"om}
+\date{15 November 1999 \\
+Version 1.910}
+
+\begin{document}
+\maketitle
+
+This file is just the part of \texttt{latin.mtx} that's needed for
+installing kern-and-ligful \texttt{8y} fonts.
+
+\metrics
+
+\needsfontinstversion{1.900}
+
+\begincomment
+\section{Duplicating glyphs}
+
+The code in this part has been commented out since glyph duplicates
+aren't needed anymore.
+\endcomment
+
+
+
+% \setglyph{alternate-space}
+% \glyph{space}{1000}
+% \comment{Get a \texttt{space} into the \texttt{alternate-space} slot
+% (nee \texttt{nbspace}).}
+% \endsetglyph
+
+
+% \setglyph{alternate-hyphen}
+% \glyph{hyphen}{1000}
+% \comment{Get a \texttt{hyphen} into the \texttt{alternate-hyphen} slot
+% (nee \texttt{softhyphen}).}
+% \endsetglyph
+
+
+% \setglyph{quoteleft-unused}
+% \glyph{quoteleft}{1000}
+% \comment{The LGC claims that \texttt{quoteleft} and \texttt{quoteright}
+% appear twice, which is not the case for \texttt{8r.enc}, but does
+% apply for \texttt{texnansi.enc}. We prefer the ASCII position and
+% mark the second one as unused.}
+% \endsetglyph
+% \setglyph{quoteright-unused}
+% \glyph{quoteright}{1000}
+% \comment{As for \texttt{quoteleft-unused}.}
+% \endsetglyph
+
+% \begincomment\medskip
+% Several special characters from \texttt{OT1} appear twice in
+% \texttt{texnansi.enc}, once in their \texttt{OT1} position (0--31) and
+% again in their Windows ANSI or Latin 1 position (128--255). We usually
+% prefer the second one.
+% \endcomment
+%
+% \setglyph{germandbls-OT1}
+% \glyph{germandbls}{1000}
+% \endsetglyph
+% \setglyph{ae-OT1}
+% \glyph{ae}{1000}
+% \endsetglyph
+% \setglyph{oe-OT1}
+% \glyph{oe}{1000}
+% \endsetglyph
+% \setglyph{oslash-OT1}
+% \glyph{oslash}{1000}
+% \endsetglyph
+% \setglyph{AE-OT1}
+% \glyph{AE}{1000}
+% \endsetglyph
+% \setglyph{OE-OT1}
+% \glyph{OE}{1000}
+% \endsetglyph
+% \setglyph{Oslash-OT1}
+% \glyph{Oslash}{1000}
+% \endsetglyph
+
+
+\begincomment
+\section{Kerning}
+Kern accented characters the same way as their base characters.
+Characters are listed in the order in which they appear in
+\texttt{8y.enc}.
+\endcomment
+
+% 128-159
+\setleftrightkerning{Lslash}{L}{1000}
+\setleftrightkerning{Scaron}{S}{1000}
+\setleftrightkerning{Zcaron}{Z}{1000}
+
+%\setleftrightkerning{lslash}{l}{1000}
+%\setleftrightkerning{scaron}{s}{1000}
+%\setleftrightkerning{zcaron}{z}{1000}
+
+\setleftrightkerning{Ydieresis}{Y}{1000}
+
+% 192-255
+\setleftrightkerning{Agrave}{A}{1000}
+\setleftrightkerning{Aacute}{A}{1000}
+\setleftrightkerning{Acircumflex}{A}{1000}
+\setleftrightkerning{Atilde}{A}{1000}
+\setleftrightkerning{Adieresis}{A}{1000}
+\setleftrightkerning{Aring}{A}{1000}
+
+\setleftrightkerning{Ccedilla}{C}{1000}
+
+\setleftrightkerning{Egrave}{E}{1000}
+\setleftrightkerning{Eacute}{E}{1000}
+\setleftrightkerning{Ecircumflex}{E}{1000}
+\setleftrightkerning{Edieresis}{E}{1000}
+
+\setleftrightkerning{Igrave}{I}{1000}
+\setleftrightkerning{Iacute}{I}{1000}
+\setleftrightkerning{Icircumflex}{I}{1000}
+\setleftrightkerning{Idieresis}{I}{1000}
+
+\setleftrightkerning{Ograve}{O}{1000}
+\setleftrightkerning{Oacute}{O}{1000}
+\setleftrightkerning{Ocircumflex}{O}{1000}
+\setleftrightkerning{Otilde}{O}{1000}
+\setleftrightkerning{Odieresis}{O}{1000}
+\setleftrightkerning{Oslash}{O}{1000}
+
+\setleftrightkerning{Ugrave}{U}{1000}
+\setleftrightkerning{Uacute}{U}{1000}
+\setleftrightkerning{Ucircumflex}{U}{1000}
+\setleftrightkerning{Udieresis}{U}{1000}
+
+\setleftrightkerning{Yacute}{Y}{1000}
+
+%\setleftrightkerning{agrave}{a}{1000}
+%\setleftrightkerning{aacute}{a}{1000}
+%\setleftrightkerning{acircumflex}{a}{1000}
+%\setleftrightkerning{atilde}{a}{1000}
+%\setleftrightkerning{adieresis}{a}{1000}
+%\setleftrightkerning{aring}{a}{1000}
+
+\setleftrightkerning{ccedilla}{c}{1000}
+
+%\setleftrightkerning{egrave}{e}{1000}
+%\setleftrightkerning{eacute}{e}{1000}
+%\setleftrightkerning{ecircumflex}{e}{1000}
+%\setleftrightkerning{edieresis}{e}{1000}
+
+%\setleftrightkerning{igrave}{i}{1000}
+%\setleftrightkerning{iacute}{i}{1000}
+%\setleftrightkerning{icircumflex}{i}{1000}
+%\setleftrightkerning{idieresis}{i}{1000}
+
+%\setleftrightkerning{ograve}{o}{1000}
+%\setleftrightkerning{oacute}{o}{1000}
+%\setleftrightkerning{ocircumflex}{o}{1000}
+%\setleftrightkerning{otilde}{o}{1000}
+%\setleftrightkerning{odieresis}{o}{1000}
+%\setleftrightkerning{oslash}{o}{1000}
+
+%\setleftrightkerning{ugrave}{u}{1000}
+%\setleftrightkerning{uacute}{u}{1000}
+%\setleftrightkerning{ucircumflex}{u}{1000}
+%\setleftrightkerning{udieresis}{u}{1000}
+
+%\setleftrightkerning{yacute}{y}{1000}
+%\setleftrightkerning{ydieresis}{y}{1000}
+
+
+\begincomment
+\section{Adjusting depth of accents}
+We copy the \verb|\zerodepth| stuff from \texttt{latin.mtx}:
+\endcomment
+
+\setcommand\zerodepth#1{
+ \ifisglyph{#1}\then
+ \resetglyph{#1}
+ \glyph{#1}{1000}
+ \resetdepth{0}
+ \endresetglyph
+ \fi
+}
+\zerodepth{acute}
+\zerodepth{grave}
+\zerodepth{caron}
+\zerodepth{breve}
+\zerodepth{macron}
+\zerodepth{ring}
+\zerodepth{circumflex}
+\zerodepth{dotaccent}
+\zerodepth{tilde}
+\zerodepth{dieresis}
+
+\endmetrics
+
+\section{Changes}
+
+See also the changes list for \texttt{8r.mtx}.
+
+1998/06/11: This file was created based on a copy of \texttt{8r.mtx}.
+The glyphs \texttt{alternate-space}, \texttt{quoteleft-unused}, and
+\texttt{quoteright-unused} were added. (UV)
+
+1999/10/25: A typo regarding \texttt{quoteright-unused} was corrected.
+(UV\&LH)
+
+1999/10/30: \textsf{fontdoc} markup was added and the
+\verb|\needsfontinstversion| was increased to v\,1.900. (LH)
+
+1999/11/13: Duplication of glyphs was commented out. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/latin.mtx b/fonts/utilities/fontinst/inputs/latinmtx/latin.mtx
new file mode 100644
index 0000000000..74692b4768
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/latin.mtx
@@ -0,0 +1,1791 @@
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and Walter Schmidt",
+%%% version = "1.916",
+%%% date = "18 March 2003",
+%%% time = "23:59 MESZ",
+%%% filename = "latin.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It provides the defaults
+%%% used to install the Latin glyphs.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\title{The \textsf{fontinst} latin glyphs}
+\author{Alan Jeffrey\and Ulrik Vieth\and Walter Schmidt}
+\date{18 March 2003 \\
+Version 1.916}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the glyphs used by the \textsf{fontinst} package
+when generating Latin fonts. This file, \texttt{latin.mtx}, is intended
+for use with normal fonts or with faked small caps fonts generated by
+scaling and applying some letterspacing. A special version of this
+file, \texttt{latinsc.mtx}, also exists, which may be more suitable for
+use with real small caps glyphs.
+
+\metrics
+
+\needsfontinstversion{1.800}
+
+% \unfakable is a glyph which can't be faked.
+
+\setcommand\unfakable#1{
+ \setglyph{#1}
+ \glyphrule{500}{500}
+ \glyphwarning{missing glyph `#1'}
+ \endsetglyph
+}
+
+% A top accent is set by placing the center of the accent at the given
+% position along the width of the letter, raised up by the difference
+% between the height of the letter and the xheight.
+
+\setcommand\topaccent#1#2#3{
+ \push
+ \moveup{\max{0}{\sub{\height{#1}}{\int{xheight}}}}
+ \movert{\add{\sub{\scale{\width{#1}}{#3}}{\scale{\width{#2}}{500}}}
+ {\scale{\sub{\height{#1}}{\int{xheight}}}{\int{italicslant}}}}
+ \glyph{#2}{1000}
+ \pop
+ \glyph{#1}{1000}
+}
+
+% A bottom accent is set by placing the center of the accent at the given
+% position along the width of the letter.
+
+\setcommand\botaccent#1#2#3{
+ \push
+ \movert{\sub{\scale{\width{#1}}{#3}}{\scale{\width{#2}}{500}}}
+ \glyph{#2}{1000}
+ \pop
+ \glyph{#1}{1000}
+}
+
+% A command to put an accent at the same height as the dot of the i. (WaS)
+
+\setcommand\itopaccent#1#2#3{
+ \push
+ \moveup{\max{0}{\sub{\height{i}}{\height{#2}}}}
+ \movert{\add{\sub{\scale{\width{#1}}{#3}}{\scale{\width{#2}}{500}}}
+ {\scale{\sub{\height{i}}{\height{#2}}}{\int{italicslant}}}} % <--- ???
+ \glyph{#2}{1000}
+ \pop
+ \glyph{#1}{1000}
+}
+
+% A c&sc glyph is created by shrinking the cap glyph, and adding extra
+% space.
+
+\setcommand\cscglyph#1{
+ \movert{\int{smallcapsextraspace}}
+ \glyph{#1}{\int{smallcapsscale}}
+ \movert{\int{smallcapsextraspace}}
+}
+
+% A c&sc top accent glyph is placed using the small glyphs if
+% available, and otherwise by shrinking the equivalent capital.
+
+\setcommand\csctopaccent#1#2#3{
+ \ifisglyph{#1small}\then
+ \topaccent{#1small}{#2small}{#3}
+ \else
+ \cscglyph{#1#2}
+ \fi
+}
+
+% A c&sc bot accent glyph is placed using the small glyphs if
+% available, and otherwise by shrinking the equivalent capital.
+
+\setcommand\cscbotaccent#1#2#3{
+ \ifisglyph{#1small}\then
+ \botaccent{#1small}{#2small}{#3}
+ \else
+ \cscglyph{#1#2}
+ \fi
+}
+
+% A c&sc accent is created by moving a shrunk accent up by the
+% difference between a scaled x and a scaled X.
+
+\setcommand\cscaccent#1{
+ \moveup{\scale{\int{xheight}}{\sub{1000}{\int{smallcapsscale}}}}
+ \cscglyph{#1}
+ \moveup{\scale{\int{xheight}}{\sub{\int{smallcapsscale}}{1000}}}
+}
+
+
+\comment{\section{Default values}}
+
+\setint{italicslant}{0}
+\setint{xheight}{\height{x}}
+\setint{capheight}{\height{A}}
+\setint{ascender}{\height{d}}
+\setint{descender}{\depth{g}}
+\setint{underlinethickness}{40}
+\setint{visiblespacedepth}{200}
+\setint{visiblespacewidth}{400}
+\setint{visiblespacesurround}{50}
+\setint{smallcapsscale}{800}
+\setint{smallcapskerning}{900}
+
+% Vertical symmetry axis. (WaS)
+\setint{vaxis}{\scale{\sub{\height{parenleft}}{\depth{parenleft}}}{500}}
+
+\ifisint{monowidth}\then
+ \setint{capspacing}{0}
+ \setint{smallcapsextraspace}
+ {\div{\scale{\width{x}}{\sub{1000}{\int{smallcapsscale}}}}{2}}
+\else
+ \setint{capspacing}{50}
+ \setint{smallcapsextraspace}{0}
+\fi
+
+\ifisint{visiblespace}\then
+ \setint{boundarychar}{\int{visiblespace}}
+\fi
+
+
+\comment{\section{Kerning}}
+
+\setleftrightkerning{visiblespace}{space}{1000}
+
+\setleftkerning{hyphenchar}{hyphen}{1000}
+
+\setleftrightkerning{Aacute}{A}{1000}
+\setleftrightkerning{Abreve}{A}{1000}
+\setleftrightkerning{Acircumflex}{A}{1000}
+\setleftrightkerning{Adieresis}{A}{1000}
+\setleftrightkerning{Agrave}{A}{1000}
+\setleftrightkerning{Aogonek}{A}{1000}
+\setleftrightkerning{Aring}{A}{1000}
+\setleftrightkerning{Atilde}{A}{1000}
+
+\setleftrightkerning{Cacute}{C}{1000}
+\setleftrightkerning{Ccaron}{C}{1000}
+\setleftrightkerning{Ccedilla}{C}{1000}
+
+\setleftrightkerning{Dcaron}{D}{1000}
+
+\setleftrightkerning{Eacute}{E}{1000}
+\setleftrightkerning{Ecaron}{E}{1000}
+\setleftrightkerning{Ecircumflex}{E}{1000}
+\setleftrightkerning{Edieresis}{E}{1000}
+\setleftrightkerning{Egrave}{E}{1000}
+\setleftrightkerning{Eogonek}{E}{1000}
+
+\setleftrightkerning{Gbreve}{G}{1000}
+
+\setleftkerning{IJ}{I}{1000}
+
+\setleftrightkerning{Iacute}{I}{1000}
+\setleftrightkerning{Icircumflex}{I}{1000}
+\setleftrightkerning{Idieresis}{I}{1000}
+\setleftrightkerning{Idotaccent}{I}{1000}
+\setleftrightkerning{Igrave}{I}{1000}
+
+\setrightkerning{IJ}{J}{1000}
+
+\setleftrightkerning{Lacute}{L}{1000}
+\setleftrightkerning{Lslash}{L}{1000}
+\setleftkerning{Lcaron}{L}{1000}
+
+\setleftrightkerning{Nacute}{N}{1000}
+\setleftrightkerning{Ncaron}{N}{1000}
+\setleftrightkerning{Ntilde}{N}{1000}
+
+\setleftkerning{Ng}{N}{1000}
+\setrightkerning{Ng}{J}{1000}
+
+\setleftrightkerning{Oacute}{O}{1000}
+\setleftrightkerning{Ocircumflex}{O}{1000}
+\setleftrightkerning{Odieresis}{O}{1000}
+\setleftrightkerning{Ograve}{O}{1000}
+\setleftrightkerning{Ohungarumlaut}{O}{1000}
+\setleftrightkerning{Oslash}{O}{1000}
+\setleftrightkerning{Otilde}{O}{1000}
+
+\setleftrightkerning{Rcaron}{R}{1000}
+\setleftrightkerning{Racute}{R}{1000}
+
+\setleftrightkerning{SS}{S}{1000}
+\setleftrightkerning{Sacute}{S}{1000}
+\setleftrightkerning{Scaron}{S}{1000}
+\setleftrightkerning{Scedilla}{S}{1000}
+
+\setleftrightkerning{Tcaron}{T}{1000}
+\setleftrightkerning{Tcedilla}{T}{1000}
+
+\setleftrightkerning{Uacute}{U}{1000}
+\setleftrightkerning{Ucircumflex}{U}{1000}
+\setleftrightkerning{Udieresis}{U}{1000}
+\setleftrightkerning{Ugrave}{U}{1000}
+\setleftrightkerning{Uhungarumlaut}{U}{1000}
+\setleftrightkerning{Uring}{U}{1000}
+
+\setleftrightkerning{Yacute}{Y}{1000}
+\setleftrightkerning{Ydieresis}{Y}{1000}
+
+\setleftrightkerning{Zacute}{Z}{1000}
+\setleftrightkerning{Zcaron}{Z}{1000}
+\setleftrightkerning{Zdotaccent}{Z}{1000}
+
+\setleftrightkerning{aogonek}{a}{1000}
+
+\setleftrightkerning{ccedilla}{c}{1000}
+
+\setleftrightkerning{eogonek}{e}{1000}
+
+\setleftkerning{ffi}{f}{1000}
+\setleftkerning{ffl}{f}{1000}
+\setleftrightkerning{ff}{f}{1000}
+\setleftkerning{fi}{f}{1000}
+\setleftkerning{fl}{f}{1000}
+
+\setleftkerning{ij}{i}{1000}
+
+\setrightkerning{fi}{i}{1000}
+\setrightkerning{ffi}{i}{1000}
+
+\setrightkerning{ij}{j}{1000}
+
+\setrightkerning{fl}{l}{1000}
+\setrightkerning{ffl}{l}{1000}
+
+\setleftkerning{ng}{n}{1000}
+\setrightkerning{ng}{j}{1000}
+
+\setleftkerning{oe}{o}{1000}
+\setrightkerning{oe}{e}{1000}
+\setleftrightkerning{oslash}{o}{1000}
+
+\setleftrightkerning{scedilla}{s}{1000}
+
+\setleftrightkerning{tcedilla}{t}{1000}
+
+
+\comment{\section{All-caps kerning}}
+
+\setleftrightkerning{dotlessI}{I}{1000}
+\setleftrightkerning{dotlessJ}{J}{1000}
+\setleftrightkerning{FFspaced}{F}{1000}
+\setleftkerning{FIspaced}{F}{1000}
+\setrightkerning{FIspaced}{I}{1000}
+\setleftkerning{FLspaced}{F}{1000}
+\setrightkerning{FLspaced}{L}{1000}
+\setleftkerning{FFIspaced}{F}{1000}
+\setrightkerning{FFIspaced}{I}{1000}
+\setleftkerning{FFLspaced}{F}{1000}
+\setrightkerning{FFLspaced}{L}{1000}
+\setleftrightkerning{Dbar}{Eth}{1000}
+\setleftkerning{IJspaced}{I}{1000}
+\setrightkerning{IJspaced}{J}{1000}
+\setleftrightkerning{SSspaced}{S}{1000}
+
+
+\comment{\section{Small caps kerning}}
+
+\setleftrightkerning{Asmall}{A}{\int{smallcapskerning}}
+\setleftrightkerning{Bsmall}{B}{\int{smallcapskerning}}
+\setleftrightkerning{Csmall}{C}{\int{smallcapskerning}}
+\setleftrightkerning{Dsmall}{D}{\int{smallcapskerning}}
+\setleftrightkerning{Esmall}{E}{\int{smallcapskerning}}
+\setleftrightkerning{Fsmall}{F}{\int{smallcapskerning}}
+\setleftrightkerning{Gsmall}{G}{\int{smallcapskerning}}
+\setleftrightkerning{Hsmall}{H}{\int{smallcapskerning}}
+\setleftrightkerning{Ismall}{I}{\int{smallcapskerning}}
+\setleftrightkerning{Jsmall}{J}{\int{smallcapskerning}}
+\setleftrightkerning{Ksmall}{K}{\int{smallcapskerning}}
+\setleftrightkerning{Lsmall}{L}{\int{smallcapskerning}}
+\setleftrightkerning{Msmall}{M}{\int{smallcapskerning}}
+\setleftrightkerning{Nsmall}{N}{\int{smallcapskerning}}
+\setleftrightkerning{Osmall}{O}{\int{smallcapskerning}}
+\setleftrightkerning{Psmall}{P}{\int{smallcapskerning}}
+\setleftrightkerning{Qsmall}{Q}{\int{smallcapskerning}}
+\setleftrightkerning{Rsmall}{R}{\int{smallcapskerning}}
+\setleftrightkerning{Ssmall}{S}{\int{smallcapskerning}}
+\setleftrightkerning{Tsmall}{T}{\int{smallcapskerning}}
+\setleftrightkerning{Usmall}{U}{\int{smallcapskerning}}
+\setleftrightkerning{Vsmall}{V}{\int{smallcapskerning}}
+\setleftrightkerning{Wsmall}{W}{\int{smallcapskerning}}
+\setleftrightkerning{Xsmall}{X}{\int{smallcapskerning}}
+\setleftrightkerning{Ysmall}{Y}{\int{smallcapskerning}}
+\setleftrightkerning{Zsmall}{Z}{\int{smallcapskerning}}
+\setleftrightkerning{Aacutesmall}{Aacute}{\int{smallcapskerning}}
+\setleftrightkerning{Abrevesmall}{Abreve}{\int{smallcapskerning}}
+\setleftrightkerning{Acircumflexsmall}{Acircumflex}{\int{smallcapskerning}}
+\setleftrightkerning{Adieresissmall}{Adieresis}{\int{smallcapskerning}}
+\setleftrightkerning{AEsmall}{AE}{\int{smallcapskerning}}
+\setleftrightkerning{Agravesmall}{Agrave}{\int{smallcapskerning}}
+\setleftrightkerning{Aogoneksmall}{Aogonek}{\int{smallcapskerning}}
+\setleftrightkerning{Aringsmall}{Aring}{\int{smallcapskerning}}
+\setleftrightkerning{Atildesmall}{Atilde}{\int{smallcapskerning}}
+\setleftrightkerning{Cacutesmall}{Cacute}{\int{smallcapskerning}}
+\setleftrightkerning{Ccaronsmall}{Ccaron}{\int{smallcapskerning}}
+\setleftrightkerning{Ccedillasmall}{Ccedilla}{\int{smallcapskerning}}
+\setleftrightkerning{Dbarsmall}{Dbar}{\int{smallcapskerning}}
+\setleftrightkerning{Dcaronsmall}{Dcaron}{\int{smallcapskerning}}
+\setleftrightkerning{Eacutesmall}{Eacute}{\int{smallcapskerning}}
+\setleftrightkerning{Ecaronsmall}{Ecaron}{\int{smallcapskerning}}
+\setleftrightkerning{Ecircumflexsmall}{Ecircumflex}{\int{smallcapskerning}}
+\setleftrightkerning{Edieresissmall}{Edieresis}{\int{smallcapskerning}}
+\setleftrightkerning{Egravesmall}{Egrave}{\int{smallcapskerning}}
+\setleftrightkerning{Eogoneksmall}{Eogonek}{\int{smallcapskerning}}
+\setleftrightkerning{Ethsmall}{Eth}{\int{smallcapskerning}}
+\setleftrightkerning{Gbrevesmall}{Gbreve}{\int{smallcapskerning}}
+\setleftrightkerning{IJsmall}{IJ}{\int{smallcapskerning}}
+\setleftrightkerning{Iacutesmall}{Iacute}{\int{smallcapskerning}}
+\setleftrightkerning{Icircumflexsmall}{Icircumflex}{\int{smallcapskerning}}
+\setleftrightkerning{Idieresissmall}{Idieresis}{\int{smallcapskerning}}
+\setleftrightkerning{Idotaccentsmall}{Idotaccent}{\int{smallcapskerning}}
+\setleftrightkerning{Igravesmall}{Igrave}{\int{smallcapskerning}}
+\setleftrightkerning{Lacutesmall}{Lacute}{\int{smallcapskerning}}
+\setleftrightkerning{Lcaronsmall}{Lcaron}{\int{smallcapskerning}}
+\setleftrightkerning{Lslashsmall}{Lslash}{\int{smallcapskerning}}
+\setleftrightkerning{Nacutesmall}{Nacute}{\int{smallcapskerning}}
+\setleftrightkerning{Ncaronsmall}{Ncaron}{\int{smallcapskerning}}
+\setleftrightkerning{Ngsmall}{Ng}{\int{smallcapskerning}}
+\setleftrightkerning{Ntildesmall}{Ntilde}{\int{smallcapskerning}}
+\setleftrightkerning{Oacutesmall}{Oacute}{\int{smallcapskerning}}
+\setleftrightkerning{Ocircumflexsmall}{Ocircumflex}{\int{smallcapskerning}}
+\setleftrightkerning{Odieresissmall}{Odieresis}{\int{smallcapskerning}}
+\setleftrightkerning{OEsmall}{OE}{\int{smallcapskerning}}
+\setleftrightkerning{Ogravesmall}{Ograve}{\int{smallcapskerning}}
+\setleftrightkerning{Ohungarumlautsmall}{Ohungarumlaut}{\int{smallcapskerning}}
+\setleftrightkerning{Oslashsmall}{Oslash}{\int{smallcapskerning}}
+\setleftrightkerning{Otildesmall}{Otilde}{\int{smallcapskerning}}
+\setleftrightkerning{Racutesmall}{Racute}{\int{smallcapskerning}}
+\setleftrightkerning{Rcaronsmall}{Rcaron}{\int{smallcapskerning}}
+\setleftrightkerning{SSsmall}{SS}{\int{smallcapskerning}}
+\setleftrightkerning{Sacutesmall}{Sacute}{\int{smallcapskerning}}
+\setleftrightkerning{Scaronsmall}{Scaron}{\int{smallcapskerning}}
+\setleftrightkerning{Scedillasmall}{Scedilla}{\int{smallcapskerning}}
+\setleftrightkerning{Tcaronsmall}{Tcaron}{\int{smallcapskerning}}
+\setleftrightkerning{Tcedillasmall}{Tcedilla}{\int{smallcapskerning}}
+\setleftrightkerning{Thornsmall}{Thorn}{\int{smallcapskerning}}
+\setleftrightkerning{Uacutesmall}{Uacute}{\int{smallcapskerning}}
+\setleftrightkerning{Ucircumflexsmall}{Ucircumflex}{\int{smallcapskerning}}
+\setleftrightkerning{Udieresissmall}{Udieresis}{\int{smallcapskerning}}
+\setleftrightkerning{Ugravesmall}{Ugrave}{\int{smallcapskerning}}
+\setleftrightkerning{Uhungarumlautsmall}{Uhungarumlaut}{\int{smallcapskerning}}
+\setleftrightkerning{Uringsmall}{Uring}{\int{smallcapskerning}}
+\setleftrightkerning{Yacutesmall}{Yacute}{\int{smallcapskerning}}
+\setleftrightkerning{Ydieresissmall}{Ydieresis}{\int{smallcapskerning}}
+\setleftrightkerning{Zacutesmall}{Zacute}{\int{smallcapskerning}}
+\setleftrightkerning{Zcaronsmall}{Zcaron}{\int{smallcapskerning}}
+\setleftrightkerning{Zdotaccentsmall}{Zdotaccent}{\int{smallcapskerning}}
+\setleftrightkerning{dotlessIsmall}{Ismall}{1000}
+\setleftrightkerning{dotlessJsmall}{Jsmall}{1000}
+
+
+\comment{\section{Unfakable glyphs}}
+
+\unfakable{Gamma}
+\unfakable{Delta}
+\unfakable{Theta}
+\unfakable{Lambda}
+\unfakable{Xi}
+\unfakable{Pi}
+\unfakable{Sigma}
+\unfakable{Upsilon}
+\unfakable{Upsilon1}
+\unfakable{Phi}
+\unfakable{Psi}
+\unfakable{Omega}
+
+\unfakable{grave}
+\unfakable{acute}
+\unfakable{circumflex}
+\unfakable{tilde}
+\unfakable{dieresis}
+\unfakable{hungarumlaut}
+\unfakable{ring}
+\unfakable{caron}
+\unfakable{breve}
+\unfakable{macron}
+\unfakable{dotaccent}
+\unfakable{cedilla}
+\unfakable{ogonek}
+\unfakable{guilsinglleft}
+\unfakable{guilsinglright}
+\unfakable{quotedblleft}
+\unfakable{quotedblright}
+\unfakable{quotedblbase}
+\unfakable{guillemotleft}
+\unfakable{guillemotright}
+\unfakable{endash}
+\unfakable{emdash}
+\unfakable{dotlessi}
+\unfakable{perthousandzero}
+\unfakable{exclam}
+\unfakable{quotedbl}
+\unfakable{numbersign}
+\unfakable{dollar}
+\unfakable{percent}
+\unfakable{ampersand}
+\unfakable{quoteright}
+\unfakable{parenleft}
+\unfakable{parenright}
+\unfakable{asterisk}
+\unfakable{plus}
+\unfakable{comma}
+\unfakable{hyphen}
+\unfakable{period}
+\unfakable{slash}
+\unfakable{zero}
+\unfakable{one}
+\unfakable{two}
+\unfakable{three}
+\unfakable{four}
+\unfakable{five}
+\unfakable{six}
+\unfakable{seven}
+\unfakable{eight}
+\unfakable{nine}
+\unfakable{zerooldstyle}
+\unfakable{oneoldstyle}
+\unfakable{twooldstyle}
+\unfakable{threeoldstyle}
+\unfakable{fouroldstyle}
+\unfakable{fiveoldstyle}
+\unfakable{sixoldstyle}
+\unfakable{sevenoldstyle}
+\unfakable{eightoldstyle}
+\unfakable{nineoldstyle}
+\unfakable{colon}
+\unfakable{semicolon}
+\unfakable{less}
+\unfakable{equal}
+\unfakable{greater}
+\unfakable{question}
+\unfakable{at}
+\unfakable{A}
+\unfakable{B}
+\unfakable{C}
+\unfakable{D}
+\unfakable{E}
+\unfakable{F}
+\unfakable{G}
+\unfakable{H}
+\unfakable{I}
+\unfakable{J}
+\unfakable{K}
+\unfakable{L}
+\unfakable{M}
+\unfakable{N}
+\unfakable{O}
+\unfakable{P}
+\unfakable{Q}
+\unfakable{R}
+\unfakable{S}
+\unfakable{T}
+\unfakable{U}
+\unfakable{V}
+\unfakable{W}
+\unfakable{X}
+\unfakable{Y}
+\unfakable{Z}
+\unfakable{bracketleft}
+\unfakable{backslash}
+\unfakable{bracketright}
+\unfakable{asciicircum}
+\unfakable{underscore}
+\unfakable{quoteleft}
+\unfakable{a}
+\unfakable{b}
+\unfakable{c}
+\unfakable{d}
+\unfakable{e}
+\unfakable{f}
+\unfakable{g}
+\unfakable{h}
+\unfakable{i}
+\unfakable{j}
+\unfakable{k}
+\unfakable{l}
+\unfakable{m}
+\unfakable{n}
+\unfakable{o}
+\unfakable{p}
+\unfakable{q}
+\unfakable{r}
+\unfakable{s}
+\unfakable{t}
+\unfakable{u}
+\unfakable{v}
+\unfakable{w}
+\unfakable{x}
+\unfakable{y}
+\unfakable{z}
+\unfakable{braceleft}
+\unfakable{bar}
+\unfakable{braceright}
+\unfakable{asciitilde}
+\unfakable{Eng}
+\unfakable{section}
+\unfakable{eng}
+\unfakable{exclamdown}
+\unfakable{questiondown}
+\unfakable{sterling}
+\unfakable{AE}
+\unfakable{Eth}
+\unfakable{OE}
+\unfakable{Oslash}
+\unfakable{Thorn}
+\unfakable{ae}
+\unfakable{eth}
+\unfakable{oe}
+\unfakable{oslash}
+\unfakable{thorn}
+\unfakable{germandbls}
+\unfakable{lslashslash}
+
+\setglyph{dotlessj}
+ \moveup{\neg{\depth{j}}}
+ \glyphrule{\width{j}}{\add{\depth{j}}{\height{dotlessi}}}
+ \resetitalic{\italic{dotlessi}}
+ \moveup{\depth{j}}
+ \glyphwarning{missing glyph `dotlessj'}
+\endsetglyph
+
+
+\comment{\section{Glyphs}}
+
+% only with monospaced fonts. (WaS)
+\ifisint{monowidth}\then
+\resetglyph{asterisk}
+ \moveup{\neg{\sub{\scale{\sub{\height{asterisk}}{\depth{asterisk}}}{500}}{\int{vaxis}}}}
+ \glyph{asterisk}{1000}
+ \resetdepth{0}
+\endresetglyph
+\fi
+
+\setglyph{space}
+ \ifisglyph{space-not}\then
+ \movert{\width{space-not}}
+ \else
+ \movert{\width{i}}
+ \fi
+\endsetglyph
+
+\setglyph{compwordmark}
+ \glyphrule{0}{\int{xheight}}
+\endsetglyph
+\setint{compwordmark-spacing}{0}
+
+\setglyph{quotesinglbase}
+ \glyph{comma}{1000}
+\endsetglyph
+
+\setglyph{fi}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{i}}
+ \glyph{i}{1000}
+\endsetglyph
+
+\setglyph{ff}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{f}}
+ \glyph{f}{1000}
+\endsetglyph
+
+\setglyph{fl}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{l}}
+ \glyph{l}{1000}
+\endsetglyph
+
+\setglyph{ffi}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{f}}
+ \glyph{fi}{1000}
+\endsetglyph
+
+\setglyph{ffl}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{f}}
+ \glyph{fl}{1000}
+\endsetglyph
+
+\setglyph{visiblespace}
+ \moveup{\neg{\int{visiblespacedepth}}}
+ \movert{\int{visiblespacesurround}}
+ \glyphrule
+ {\int{underlinethickness}}
+ {\int{visiblespacedepth}}
+ \glyphrule
+ {\int{visiblespacewidth}}
+ {\int{underlinethickness}}
+ \glyphrule
+ {\int{underlinethickness}}
+ {\int{visiblespacedepth}}
+ \movert{\int{visiblespacesurround}}
+ \moveup{\int{visiblespacedepth}}
+\endsetglyph
+
+\setglyph{rangedash}
+ \ifisint{monowidth}\then
+ \glyph{hyphen}{1000}
+ \else
+ \glyph{endash}{1000}
+ \fi
+\endsetglyph
+
+\setglyph{punctdash}
+ \ifisint{monowidth}\then
+ \glyph{hyphen}{1000}
+ \glyph{hyphen}{1000}
+ \else
+ \glyph{emdash}{1000}
+ \fi
+\endsetglyph
+
+\setglyph{hyphenchar}
+ \glyph{hyphen}{1000}
+\endsetglyph
+
+\setglyph{ringfitted}
+ \movert{\div{\sub{\width{A}}{\width{ring}}}{2}}
+ \glyph{ring}{1000}
+ \movert{\div{\sub{\width{A}}{\width{ring}}}{2}}
+\endsetglyph
+
+\setglyph{lslash}
+ \glyph{lslashslash}{1000}
+ \movert{\kerning{lslashslash}{l}}
+ \glyph{l}{1000}
+\endsetglyph
+
+\setglyph{Lslash}
+ \glyph{lslashslash}{1000}
+ \movert{\kerning{lslashslash}{L}}
+ \glyph{L}{1000}
+\endsetglyph
+
+\setglyph{Ng}
+ \glyph{Eng}{1000}
+\endsetglyph
+
+\setglyph{ng}
+ \glyph{eng}{1000}
+\endsetglyph
+
+\setglyph{Abreve}
+ \topaccent{A}{breve}{500}
+\endsetglyph
+
+\setglyph{Aogonek}
+ \botaccent{A}{ogonek}{900}
+\endsetglyph
+
+\setglyph{Cacute}
+ \topaccent{C}{acute}{500}
+\endsetglyph
+
+\setglyph{Ccaron}
+ \topaccent{C}{caron}{500}
+\endsetglyph
+
+\setglyph{Dcaron}
+ \topaccent{D}{caron}{450}
+\endsetglyph
+
+\setglyph{Ecaron}
+ \topaccent{E}{caron}{500}
+\endsetglyph
+
+\setglyph{Eogonek}
+ \botaccent{E}{ogonek}{850}
+\endsetglyph
+
+\setglyph{Gbreve}
+ \topaccent{G}{breve}{500}
+\endsetglyph
+
+\setglyph{Lacute}
+ \topaccent{L}{acute}{250}
+\endsetglyph
+
+\setglyph{Lcaron}
+ \glyph{L}{1000}
+ \ifisint{monowidth}\then\else
+ \movert{-200}
+ \fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+
+\setglyph{Nacute}
+ \topaccent{N}{acute}{500}
+\endsetglyph
+
+\setglyph{Ncaron}
+ \topaccent{N}{caron}{500}
+\endsetglyph
+
+\setglyph{Ohungarumlaut}
+ \topaccent{O}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Racute}
+ \topaccent{R}{acute}{500}
+\endsetglyph
+
+\setglyph{Rcaron}
+ \topaccent{R}{caron}{500}
+\endsetglyph
+
+\setglyph{Sacute}
+ \topaccent{S}{acute}{500}
+\endsetglyph
+
+\setglyph{Scaron}
+ \topaccent{S}{caron}{500}
+\endsetglyph
+
+\setglyph{Scedilla}
+ \botaccent{S}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Tcaron}
+ \topaccent{T}{caron}{500}
+\endsetglyph
+
+\setglyph{Tcedilla}
+ \botaccent{T}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Uhungarumlaut}
+ \topaccent{U}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Uring}
+ \topaccent{U}{ring}{500}
+\endsetglyph
+
+\setglyph{Ydieresis}
+ \topaccent{Y}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Zacute}
+ \topaccent{Z}{acute}{500}
+\endsetglyph
+
+\setglyph{Zcaron}
+ \topaccent{Z}{caron}{500}
+\endsetglyph
+
+\setglyph{Zdotaccent}
+ \topaccent{Z}{dotaccent}{500}
+\endsetglyph
+
+\setglyph{IJ}
+ \glyph{I}{1000}
+ \movert{\kerning{I}{J}}
+ \glyph{J}{1000}
+\endsetglyph
+
+\setglyph{Idotaccent}
+ \topaccent{I}{dotaccent}{500}
+\endsetglyph
+
+\setglyph{dbar}
+ \push
+ \movert{\sub{\width{d}}{\width{macron}}}
+ \moveup{
+ \sub{\scale{\add{\height{d}}{\int{xheight}}}{500}}
+ {\height{macron}}}
+ \glyph{macron}{1000}
+ \pop
+ \glyph{d}{1000}
+\endsetglyph
+
+\setglyph{abreve}
+ \topaccent{a}{breve}{500}
+\endsetglyph
+
+\setglyph{aogonek}
+ \botaccent{a}{ogonek}{850}
+\endsetglyph
+
+\setglyph{cacute}
+ \topaccent{c}{acute}{500}
+\endsetglyph
+
+\setglyph{ccaron}
+ \topaccent{c}{caron}{500}
+\endsetglyph
+
+\setglyph{dcaron}
+ \glyph{d}{1000}
+ \ifisint{monowidth}\then\else
+ \movert{-75}
+ \fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+
+\setglyph{ecaron}
+ \topaccent{e}{caron}{500}
+\endsetglyph
+
+\setglyph{eogonek}
+ \botaccent{e}{ogonek}{500}
+\endsetglyph
+
+\setglyph{gbreve}
+ \topaccent{g}{breve}{500}
+\endsetglyph
+
+\setglyph{lacute}
+ \topaccent{l}{acute}{500}
+\endsetglyph
+
+\setglyph{lcaron}
+ \glyph{l}{1000}
+ \ifisint{monowidth}\then\else
+ \movert{-100}
+ \fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+
+\setglyph{nacute}
+ \topaccent{n}{acute}{500}
+\endsetglyph
+
+\setglyph{ncaron}
+ \topaccent{n}{caron}{500}
+\endsetglyph
+
+\setglyph{ohungarumlaut}
+ \topaccent{o}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{racute}
+ \topaccent{r}{acute}{500}
+\endsetglyph
+
+\setglyph{rcaron}
+ \topaccent{r}{caron}{500}
+\endsetglyph
+
+\setglyph{sacute}
+ \topaccent{s}{acute}{500}
+\endsetglyph
+
+\setglyph{scaron}
+ \topaccent{s}{caron}{500}
+\endsetglyph
+
+\setglyph{scedilla}
+ \botaccent{s}{cedilla}{500}
+\endsetglyph
+
+\setglyph{tcaron}
+ \glyph{t}{1000}
+ \ifisint{monowidth}\then\else
+ \movert{-75}
+ \fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+
+\setglyph{tcedilla}
+ \botaccent{t}{cedilla}{500}
+\endsetglyph
+
+\setglyph{uhungarumlaut}
+ \topaccent{u}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{uring}
+ \topaccent{u}{ring}{500}
+\endsetglyph
+
+\setglyph{ydieresis}
+ \topaccent{y}{dieresis}{500}
+\endsetglyph
+
+\setglyph{zacute}
+ \topaccent{z}{acute}{500}
+\endsetglyph
+
+\setglyph{zcaron}
+ \topaccent{z}{caron}{500}
+\endsetglyph
+
+% make this glyph match the letter i. (WaS)
+\setglyph{zdotaccent}
+ \itopaccent{z}{dotaccent}{500}
+\endsetglyph
+
+\setglyph{ij}
+ \glyph{i}{1000}
+ \movert{\kerning{i}{j}}
+ \glyph{j}{1000}
+\endsetglyph
+
+\setglyph{Agrave}
+ \topaccent{A}{grave}{500}
+\endsetglyph
+
+\setglyph{Aacute}
+ \topaccent{A}{acute}{500}
+\endsetglyph
+
+\setglyph{Acircumflex}
+ \topaccent{A}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Atilde}
+ \topaccent{A}{tilde}{500}
+\endsetglyph
+
+\setglyph{Adieresis}
+ \topaccent{A}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Aring}
+ \topaccent{A}{ring}{500}
+\endsetglyph
+
+\setglyph{Ccedilla}
+ \botaccent{C}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Egrave}
+ \topaccent{E}{grave}{500}
+\endsetglyph
+
+\setglyph{Eacute}
+ \topaccent{E}{acute}{500}
+\endsetglyph
+
+\setglyph{Ecircumflex}
+ \topaccent{E}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Edieresis}
+ \topaccent{E}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Iacute}
+ \topaccent{I}{acute}{500}
+\endsetglyph
+
+\setglyph{Igrave}
+ \topaccent{I}{grave}{500}
+\endsetglyph
+
+\setglyph{Icircumflex}
+ \topaccent{I}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Idieresis}
+ \topaccent{I}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Ntilde}
+ \topaccent{N}{tilde}{500}
+\endsetglyph
+
+\setglyph{Ograve}
+ \topaccent{O}{grave}{500}
+\endsetglyph
+
+\setglyph{Oacute}
+ \topaccent{O}{acute}{500}
+\endsetglyph
+
+\setglyph{Ocircumflex}
+ \topaccent{O}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Otilde}
+ \topaccent{O}{tilde}{500}
+\endsetglyph
+
+\setglyph{Odieresis}
+ \topaccent{O}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Ugrave}
+ \topaccent{U}{grave}{500}
+\endsetglyph
+
+\setglyph{Uacute}
+ \topaccent{U}{acute}{500}
+\endsetglyph
+
+\setglyph{Ucircumflex}
+ \topaccent{U}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Udieresis}
+ \topaccent{U}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Yacute}
+ \topaccent{Y}{acute}{500}
+\endsetglyph
+
+\setglyph{SS}
+ \glyph{S}{1000}
+ \movert{\kerning{S}{S}}
+ \glyph{S}{1000}
+\endsetglyph
+
+\setglyph{agrave}
+ \topaccent{a}{grave}{500}
+\endsetglyph
+
+\setglyph{aacute}
+ \topaccent{a}{acute}{500}
+\endsetglyph
+
+\setglyph{acircumflex}
+ \topaccent{a}{circumflex}{500}
+\endsetglyph
+
+\setglyph{atilde}
+ \topaccent{a}{tilde}{500}
+\endsetglyph
+
+\setglyph{adieresis}
+ \topaccent{a}{dieresis}{500}
+\endsetglyph
+
+\setglyph{aring}
+ \topaccent{a}{ring}{500}
+\endsetglyph
+
+\setglyph{ccedilla}
+ \botaccent{c}{cedilla}{500}
+\endsetglyph
+
+\setglyph{egrave}
+ \topaccent{e}{grave}{500}
+\endsetglyph
+
+\setglyph{eacute}
+ \topaccent{e}{acute}{500}
+\endsetglyph
+
+\setglyph{ecircumflex}
+ \topaccent{e}{circumflex}{500}
+\endsetglyph
+
+\setglyph{edieresis}
+ \topaccent{e}{dieresis}{500}
+\endsetglyph
+
+\setglyph{igrave}
+ \topaccent{dotlessi}{grave}{500}
+\endsetglyph
+
+\setglyph{iacute}
+ \topaccent{dotlessi}{acute}{500}
+\endsetglyph
+
+\setglyph{icircumflex}
+ \topaccent{dotlessi}{circumflex}{500}
+\endsetglyph
+
+\setglyph{idieresis}
+ \topaccent{dotlessi}{dieresis}{500}
+\endsetglyph
+
+\setglyph{ntilde}
+ \topaccent{n}{tilde}{500}
+\endsetglyph
+
+\setglyph{ograve}
+ \topaccent{o}{grave}{500}
+\endsetglyph
+
+\setglyph{oacute}
+ \topaccent{o}{acute}{500}
+\endsetglyph
+
+\setglyph{ocircumflex}
+ \topaccent{o}{circumflex}{500}
+\endsetglyph
+
+\setglyph{otilde}
+ \topaccent{o}{tilde}{500}
+\endsetglyph
+
+\setglyph{odieresis}
+ \topaccent{o}{dieresis}{500}
+\endsetglyph
+
+\setglyph{ugrave}
+ \topaccent{u}{grave}{500}
+\endsetglyph
+
+\setglyph{uacute}
+ \topaccent{u}{acute}{500}
+\endsetglyph
+
+\setglyph{ucircumflex}
+ \topaccent{u}{circumflex}{500}
+\endsetglyph
+
+\setglyph{udieresis}
+ \topaccent{u}{dieresis}{500}
+\endsetglyph
+
+\setglyph{yacute}
+ \topaccent{y}{acute}{500}
+\endsetglyph
+
+
+\comment{\section{All-caps glyphs}}
+
+\setglyph{dotlessI}
+ \glyph{I}{1000}
+\endsetglyph
+
+\setglyph{dotlessJ}
+ \glyph{J}{1000}
+\endsetglyph
+
+\setglyph{FFspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{F}}
+ {\int{capspacing}}}
+ \glyph{F}{1000}
+\endsetglyph
+
+\setglyph{FIspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{I}}
+ {\int{capspacing}}}
+ \glyph{I}{1000}
+\endsetglyph
+
+\setglyph{FLspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{L}}
+ {\int{capspacing}}}
+ \glyph{L}{1000}
+\endsetglyph
+
+\setglyph{FFIspaced}
+ \glyph{FFspaced}{1000}
+ \movert{\add{\kerning{FFspaced}{I}}
+ {\int{capspacing}}}
+ \glyph{I}{1000}
+\endsetglyph
+
+\setglyph{FFLspaced}
+ \glyph{FFspaced}{1000}
+ \movert{\add{\kerning{FFspaced}{L}}
+ {\int{capspacing}}}
+ \glyph{L}{1000}
+\endsetglyph
+
+\setglyph{Dbar}
+ \glyph{Eth}{1000}
+\endsetglyph
+
+\setglyph{IJspaced}
+ \glyph{I}{1000}
+ \movert{\add{\kerning{I}{J}}{\int{capspacing}}}
+ \glyph{J}{1000}
+\endsetglyph
+
+\setglyph{SSspaced}
+ \glyph{S}{1000}
+ \movert{\add{\kerning{S}{S}}{\int{capspacing}}}
+ \glyph{S}{1000}
+\endsetglyph
+
+
+\comment{\section{Small caps glyphs}}
+
+\setglyph{Acutesmall}
+ \cscaccent{acute}
+\endsetglyph
+
+\setglyph{acutesmall}
+ \glyph{Acutesmall}{1000}
+\endsetglyph
+
+\setglyph{Gravesmall}
+ \cscaccent{grave}
+\endsetglyph
+
+\setglyph{gravesmall}
+ \glyph{Gravesmall}{1000}
+\endsetglyph
+
+\setglyph{Circumflexsmall}
+ \cscaccent{circumflex}
+\endsetglyph
+
+\setglyph{circumflexsmall}
+ \glyph{Circumflexsmall}{1000}
+\endsetglyph
+
+\setglyph{Tildesmall}
+ \cscaccent{tilde}
+\endsetglyph
+
+\setglyph{tildesmall}
+ \glyph{Tildesmall}{1000}
+\endsetglyph
+
+\setglyph{Dieresissmall}
+ \cscaccent{dieresis}
+\endsetglyph
+
+\setglyph{dieresissmall}
+ \glyph{Dieresissmall}{1000}
+\endsetglyph
+
+\setglyph{Brevesmall}
+ \cscaccent{breve}
+\endsetglyph
+
+\setglyph{brevesmall}
+ \glyph{Brevesmall}{1000}
+\endsetglyph
+
+\setglyph{Dotaccentsmall}
+ \cscaccent{dotaccent}
+\endsetglyph
+
+\setglyph{dotaccentsmall}
+ \glyph{Dotaccentsmall}{1000}
+\endsetglyph
+
+\setglyph{Caronsmall}
+ \cscaccent{caron}
+\endsetglyph
+
+\setglyph{caronsmall}
+ \glyph{Caronsmall}{1000}
+\endsetglyph
+
+\setglyph{Hungarumlautsmall}
+ \cscaccent{hungarumlaut}
+\endsetglyph
+
+\setglyph{hungarumlautsmall}
+ \glyph{Hungarumlautsmall}{1000}
+\endsetglyph
+
+\setglyph{Ringsmall}
+ \cscaccent{ring}
+\endsetglyph
+
+\setglyph{ringsmall}
+ \glyph{Ringsmall}{1000}
+\endsetglyph
+
+\setglyph{Macronsmall}
+ \cscaccent{macron}
+\endsetglyph
+
+\setglyph{macronsmall}
+ \glyph{Macronsmall}{1000}
+ \comment{It might be unnecessary to set this glyph. This should be
+ checked sometime. /LH}
+\endsetglyph
+
+\setglyph{Cedillasmall}
+ \cscglyph{cedilla}
+\endsetglyph
+
+\setglyph{cedillasmall}
+ \glyph{Cedillasmall}{1000}
+\endsetglyph
+
+\setglyph{Ogoneksmall}
+ \cscglyph{ogonek}
+\endsetglyph
+
+\setglyph{ogoneksmall}
+ \glyph{Ogoneksmall}{1000}
+\endsetglyph
+
+\setglyph{Idotaccentsmall}
+ \csctopaccent{I}{dotaccent}{500}
+\endsetglyph
+
+\setglyph{Abrevesmall}
+ \csctopaccent{A}{breve}{500}
+\endsetglyph
+
+\setglyph{Aogoneksmall}
+ \cscbotaccent{A}{ogonek}{900}
+\endsetglyph
+
+\setglyph{Cacutesmall}
+ \csctopaccent{C}{acute}{500}
+\endsetglyph
+
+\setglyph{Ccaronsmall}
+ \csctopaccent{C}{caron}{500}
+\endsetglyph
+
+\setglyph{Dcaronsmall}
+ \csctopaccent{D}{caron}{500}
+\endsetglyph
+
+\setglyph{Ecaronsmall}
+ \csctopaccent{E}{caron}{500}
+\endsetglyph
+
+\setglyph{Eogoneksmall}
+ \cscbotaccent{E}{ogonek}{850}
+\endsetglyph
+
+\setglyph{Gbrevesmall}
+ \csctopaccent{G}{breve}{500}
+\endsetglyph
+
+\setglyph{Lacutesmall}
+ \csctopaccent{L}{acute}{250}
+\endsetglyph
+
+\setglyph{Nacutesmall}
+ \csctopaccent{N}{acute}{500}
+\endsetglyph
+
+\setglyph{Ncaronsmall}
+ \csctopaccent{N}{caron}{500}
+\endsetglyph
+
+\setglyph{Ngsmall}
+ \cscglyph{Ng}
+\endsetglyph
+
+\setglyph{Ohungarumlautsmall}
+ \csctopaccent{O}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Racutesmall}
+ \csctopaccent{R}{acute}{500}
+\endsetglyph
+
+\setglyph{Rcaronsmall}
+ \csctopaccent{R}{caron}{500}
+\endsetglyph
+
+\setglyph{Sacutesmall}
+ \csctopaccent{S}{acute}{500}
+\endsetglyph
+
+\setglyph{Scaronsmall}
+ \csctopaccent{S}{caron}{500}
+\endsetglyph
+
+\setglyph{Scedillasmall}
+ \cscbotaccent{S}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Tcaronsmall}
+ \csctopaccent{T}{caron}{500}
+\endsetglyph
+
+\setglyph{Tcedillasmall}
+ \cscbotaccent{T}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Uhungarumlautsmall}
+ \csctopaccent{U}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Uringsmall}
+ \csctopaccent{U}{ring}{500}
+\endsetglyph
+
+\setglyph{Ydieresissmall}
+ \csctopaccent{Y}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Zacutesmall}
+ \csctopaccent{Z}{acute}{500}
+\endsetglyph
+
+\setglyph{Zcaronsmall}
+ \csctopaccent{Z}{caron}{500}
+\endsetglyph
+
+\setglyph{Zdotaccentsmall}
+ \csctopaccent{Z}{dotaccent}{500}
+\endsetglyph
+
+\setglyph{Agravesmall}
+ \csctopaccent{A}{grave}{500}
+\endsetglyph
+
+\setglyph{Aacutesmall}
+ \csctopaccent{A}{acute}{500}
+\endsetglyph
+
+\setglyph{Acircumflexsmall}
+ \csctopaccent{A}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Atildesmall}
+ \csctopaccent{A}{tilde}{500}
+\endsetglyph
+
+\setglyph{Adieresissmall}
+ \csctopaccent{A}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Aringsmall}
+ \csctopaccent{A}{ring}{500}
+\endsetglyph
+
+\setglyph{Ccedillasmall}
+ \csctopaccent{C}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Egravesmall}
+ \csctopaccent{E}{grave}{500}
+\endsetglyph
+
+\setglyph{Eacutesmall}
+ \csctopaccent{E}{acute}{500}
+\endsetglyph
+
+\setglyph{Ecircumflexsmall}
+ \csctopaccent{E}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Edieresissmall}
+ \csctopaccent{E}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Igravesmall}
+ \csctopaccent{I}{grave}{500}
+\endsetglyph
+
+\setglyph{Iacutesmall}
+ \csctopaccent{I}{acute}{500}
+\endsetglyph
+
+\setglyph{Icircumflexsmall}
+ \csctopaccent{I}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Idieresissmall}
+ \csctopaccent{I}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Ethsmall}
+ \cscglyph{Eth}
+\endsetglyph
+
+\setglyph{Dbarsmall}
+ \glyph{Ethsmall}{1000}
+\endsetglyph
+
+\setglyph{Ntildesmall}
+ \csctopaccent{N}{tilde}{500}
+\endsetglyph
+
+\setglyph{Ogravesmall}
+ \csctopaccent{O}{grave}{500}
+\endsetglyph
+
+\setglyph{Oacutesmall}
+ \csctopaccent{O}{acute}{500}
+\endsetglyph
+
+\setglyph{Ocircumflexsmall}
+ \csctopaccent{O}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Otildesmall}
+ \csctopaccent{O}{tilde}{500}
+\endsetglyph
+
+\setglyph{Odieresissmall}
+ \csctopaccent{O}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Ugravesmall}
+ \csctopaccent{U}{grave}{500}
+\endsetglyph
+
+\setglyph{Uacutesmall}
+ \csctopaccent{U}{acute}{500}
+\endsetglyph
+
+\setglyph{Ucircumflexsmall}
+ \csctopaccent{U}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Udieresissmall}
+ \csctopaccent{U}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Yacutesmall}
+ \csctopaccent{Y}{acute}{500}
+\endsetglyph
+
+\setglyph{Thornsmall}
+ \cscglyph{Thorn}
+\endsetglyph
+
+\setglyph{Asmall}
+ \cscglyph{A}
+\endsetglyph
+
+\setglyph{Bsmall}
+ \cscglyph{B}
+\endsetglyph
+
+\setglyph{Csmall}
+ \cscglyph{C}
+\endsetglyph
+
+\setglyph{Dsmall}
+ \cscglyph{D}
+\endsetglyph
+
+\setglyph{Esmall}
+ \cscglyph{E}
+\endsetglyph
+
+\setglyph{Fsmall}
+ \cscglyph{F}
+\endsetglyph
+
+\setglyph{Gsmall}
+ \cscglyph{G}
+\endsetglyph
+
+\setglyph{Hsmall}
+ \cscglyph{H}
+\endsetglyph
+
+\setglyph{Ismall}
+ \cscglyph{I}
+\endsetglyph
+
+\setglyph{Jsmall}
+ \cscglyph{J}
+\endsetglyph
+
+\setglyph{Ksmall}
+ \cscglyph{K}
+\endsetglyph
+
+\setglyph{Lsmall}
+ \cscglyph{L}
+\endsetglyph
+
+\setglyph{Msmall}
+ \cscglyph{M}
+\endsetglyph
+
+\setglyph{Nsmall}
+ \cscglyph{N}
+\endsetglyph
+
+\setglyph{Osmall}
+ \cscglyph{O}
+\endsetglyph
+
+\setglyph{Psmall}
+ \cscglyph{P}
+\endsetglyph
+
+\setglyph{Qsmall}
+ \cscglyph{Q}
+\endsetglyph
+
+\setglyph{Rsmall}
+ \cscglyph{R}
+\endsetglyph
+
+\setglyph{Ssmall}
+ \cscglyph{S}
+\endsetglyph
+
+\setglyph{Tsmall}
+ \cscglyph{T}
+\endsetglyph
+
+\setglyph{Usmall}
+ \cscglyph{U}
+\endsetglyph
+
+\setglyph{Vsmall}
+ \cscglyph{V}
+\endsetglyph
+
+\setglyph{Wsmall}
+ \cscglyph{W}
+\endsetglyph
+
+\setglyph{Xsmall}
+ \cscglyph{X}
+\endsetglyph
+
+\setglyph{Ysmall}
+ \cscglyph{Y}
+\endsetglyph
+
+\setglyph{Zsmall}
+ \cscglyph{Z}
+\endsetglyph
+
+\setglyph{Lslashsmall}
+ \cscglyph{Lslash}
+\endsetglyph
+
+\setglyph{AEsmall}
+ \cscglyph{AE}
+\endsetglyph
+
+\setglyph{OEsmall}
+ \cscglyph{OE}
+\endsetglyph
+
+\setglyph{Oslashsmall}
+ \cscglyph{Oslash}
+\endsetglyph
+
+\setglyph{dotlessIsmall}
+ \glyph{Ismall}{1000}
+\endsetglyph
+
+\setglyph{dotlessJsmall}
+ \glyph{Jsmall}{1000}
+\endsetglyph
+
+\setglyph{FFsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Fsmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Fsmall}{1000}
+\endsetglyph
+
+\setglyph{FIsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Ismall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Ismall}{1000}
+\endsetglyph
+
+\setglyph{FLsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Lsmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Lsmall}{1000}
+\endsetglyph
+
+\setglyph{FFIsmall}
+ \glyph{FFsmall}{1000}
+ \movert{\add{\kerning{FFsmall}{Ismall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Ismall}{1000}
+\endsetglyph
+
+\setglyph{FFLsmall}
+ \glyph{FFsmall}{1000}
+ \movert{\add{\kerning{FFsmall}{Lsmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Lsmall}{1000}
+\endsetglyph
+
+\setglyph{IJsmall}
+ \glyph{Ismall}{1000}
+ \movert{\add{\kerning{Ismall}{Jsmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Jsmall}{1000}
+\endsetglyph
+
+\setglyph{Lcaronsmall}
+ \glyph{Lsmall}{1000}
+ \ifisint{monowidth}\then\else
+ \movert{-100}
+ \fi
+ \glyph{quoteright}{\int{smallcapsscale}}
+\endsetglyph
+
+\setglyph{SSsmall}
+ \glyph{Ssmall}{1000}
+ \movert{\add{\kerning{Ssmall}{Ssmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Ssmall}{1000}
+\endsetglyph
+
+
+\comment{\section{Accents}
+ \TeX's math accent-positioning requires accents to have zero depth.}
+
+\setcommand\zerodepth#1{
+ \ifisglyph{#1}\then
+ \resetglyph{#1}
+ \glyph{#1}{1000}
+ \resetdepth{0}
+ \endresetglyph
+ \fi
+}
+\zerodepth{grave}
+\zerodepth{acute}
+\zerodepth{circumflex}
+\zerodepth{tilde}
+\zerodepth{dieresis}
+\zerodepth{hungarumlaut}
+\zerodepth{ring}
+\zerodepth{caron}
+\zerodepth{breve}
+\zerodepth{macron}
+\zerodepth{dotaccent}
+
+\endmetrics
+
+\section{Changes}
+
+2003/03/18: Added \texttt{vaxis} for the vertical symmetry axis
+Changed `\texttt{asterisk}', which is now vertically centered
+in monospaced fonts.
+New code to create `\texttt{zdotaccent}', making sure that the
+height of the dot matches the letter `\texttt{i}'. This requires
+a new macro \verb|\itopaccent|. (WaS)
+
+1999/10/25: Added \verb|\setglyphs| for \texttt{Macronsmall} and
+\texttt{macronsmall}. (LH)
+
+1999/10/25: Simplified definition of \verb|\unfakable|. (UV\&LH)
+Rationale: It is thoroughly confusing if the size of the black box
+created by \verb|\unfakable| depends on the metrics of an unencoded
+glyph that isn't accessible and therefore unavailable for all pratical
+purposes.
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/latinsc.mtx b/fonts/utilities/fontinst/inputs/latinmtx/latinsc.mtx
new file mode 100644
index 0000000000..272c4df97e
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/latinsc.mtx
@@ -0,0 +1,1324 @@
+% Copyright 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Sebastian Rahtz and Ulrik Vieth and Walter Schmidt",
+%%% version = "1.916",
+%%% date = "12 March 2003",
+%%% time = "23:59 MESZ",
+%%% filename = "latinsc.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It provides the defaults
+%%% used to install the Latin small caps glyphs.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\title{The \textsf{fontinst} latin small caps glyphs}
+\author{Sebastian Rahtz, Ulrik Vieth, Walter Schmidt}
+\date{12 March 2003 \\
+Version 1.916}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the glyphs used by the \textsf{fontinst} package
+when generating Latin fonts. This file, \texttt{latinsc.mtx}, is a
+special version of \texttt{latin.mtx}, intended for use with real small
+caps glyphs from expert fonts using `oldstyle' or `small' glyph names.
+
+\metrics
+
+\needsfontinstversion{1.800}
+
+% \unfakable is a glyph which can't be faked.
+
+\setcommand\unfakable#1{
+ \setglyph{#1}
+ \glyphrule{500}{500}
+ \glyphwarning{missing glyph `#1'}
+ \endsetglyph
+}
+
+% A top accent is set by placing the center of the accent at the given
+% position along the width of the letter, raised up by the difference
+% between the height of the letter and the xheight.
+
+\setcommand\topaccent#1#2#3{
+ \push
+ \moveup{\max{0}{\sub{\height{#1}}{\int{xheight}}}}
+ \movert{\add{\sub{\scale{\width{#1}}{#3}}{\scale{\width{#2}}{500}}}
+ {\scale{\sub{\height{#1}}{\int{xheight}}}{\int{italicslant}}}}
+ \glyph{#2}{1000}
+ \pop
+ \glyph{#1}{1000}
+}
+
+% A bottom accent is set by placing the center of the accent at the given
+% position along the width of the letter.
+
+\setcommand\botaccent#1#2#3{
+ \push
+ \movert{\sub{\scale{\width{#1}}{#3}}{\scale{\width{#2}}{500}}}
+ \glyph{#2}{1000}
+ \pop
+ \glyph{#1}{1000}
+}
+
+% A c&sc glyph is created by shrinking the cap glyph, and adding extra
+% space.
+
+\setcommand\cscglyph#1{
+ \ifisglyph{#1small}\then
+ \glyph{#1small}{1000}
+ \else
+ \movert{\int{smallcapsextraspace}}
+ \glyph{#1}{\int{smallcapsscale}}
+ \movert{\int{smallcapsextraspace}}
+ \fi
+}
+
+% A c&sc top accent glyph is placed using the small glyphs if
+% available, and otherwise by shrinking the equivalent capital.
+
+\setcommand\csctopaccent#1#2#3{
+ \ifisglyph{#1small}\then
+ \topaccent{#1small}{#2small}{#3}
+ \else
+ \cscglyph{#1#2}
+ \fi
+}
+
+% A c&sc bot accent glyph is placed using the small glyphs if
+% available, and otherwise by shrinking the equivalent capital.
+
+\setcommand\cscbotaccent#1#2#3{
+ \ifisglyph{#1small}\then
+ \botaccent{#1small}{#2small}{#3}
+ \else
+ \cscglyph{#1#2}
+ \fi
+}
+
+% A c&sc accent is created by moving a shrunk accent up by the
+% difference between a scaled x and a scaled X.
+
+\setcommand\cscaccent#1{
+ \moveup{\scale{\int{xheight}}{\sub{1000}{\int{smallcapsscale}}}}
+ \cscglyph{#1}
+ \moveup{\scale{\int{xheight}}{\sub{\int{smallcapsscale}}{1000}}}
+}
+
+
+\comment{\section{Default values}}
+
+\setint{italicslant}{0}
+\setint{xheight}{\height{x}}
+\setint{capheight}{\height{A}}
+\setint{ascender}{\height{d}}
+\setint{descender}{\depth{g}}
+\setint{underlinethickness}{40}
+\setint{visiblespacedepth}{200}
+\setint{visiblespacewidth}{400}
+\setint{visiblespacesurround}{50}
+\setint{smallcapsscale}{800}
+\setint{smallcapskerning}{900}
+
+% Vertical symmetry axis. (WaS)
+\setint{vaxis}{\scale{\sub{\height{parenleft}}{\depth{parenleft}}}{500}}
+
+\ifisint{monowidth}\then
+ \setint{capspacing}{0}
+ \setint{smallcapsextraspace}{0}
+\else
+ \setint{capspacing}{0}
+ \setint{smallcapsextraspace}{0}
+\fi
+
+\ifisint{visiblespace}\then
+ \setint{boundarychar}{\int{visiblespace}}
+\fi
+
+
+\comment{\section{Kerning}}
+
+\setleftrightkerning{visiblespace}{space}{1000}
+
+\setleftkerning{hyphenchar}{hyphen}{1000}
+
+\setleftrightkerning{Aacute}{A}{1000}
+\setleftrightkerning{Abreve}{A}{1000}
+\setleftrightkerning{Acircumflex}{A}{1000}
+\setleftrightkerning{Adieresis}{A}{1000}
+\setleftrightkerning{Agrave}{A}{1000}
+\setleftrightkerning{Aogonek}{A}{1000}
+\setleftrightkerning{Aring}{A}{1000}
+\setleftrightkerning{Atilde}{A}{1000}
+
+\setleftrightkerning{Cacute}{C}{1000}
+\setleftrightkerning{Ccaron}{C}{1000}
+\setleftrightkerning{Ccedilla}{C}{1000}
+
+\setleftrightkerning{Dcaron}{D}{1000}
+
+\setleftrightkerning{Eacute}{E}{1000}
+\setleftrightkerning{Ecaron}{E}{1000}
+\setleftrightkerning{Ecircumflex}{E}{1000}
+\setleftrightkerning{Edieresis}{E}{1000}
+\setleftrightkerning{Egrave}{E}{1000}
+\setleftrightkerning{Eogonek}{E}{1000}
+
+\setleftrightkerning{Gbreve}{G}{1000}
+
+\setleftkerning{IJ}{I}{1000}
+
+\setleftrightkerning{Iacute}{I}{1000}
+\setleftrightkerning{Icircumflex}{I}{1000}
+\setleftrightkerning{Idieresis}{I}{1000}
+\setleftrightkerning{Idotaccent}{I}{1000}
+\setleftrightkerning{Igrave}{I}{1000}
+
+\setrightkerning{IJ}{J}{1000}
+
+\setleftrightkerning{Lacute}{L}{1000}
+\setleftrightkerning{Lslash}{L}{1000}
+\setleftkerning{Lcaron}{L}{1000}
+
+\setleftrightkerning{Nacute}{N}{1000}
+\setleftrightkerning{Ncaron}{N}{1000}
+\setleftrightkerning{Ntilde}{N}{1000}
+
+%\setleftkerning{Ng}{N}{1000}
+%\setrightkerning{Ng}{J}{1000}
+
+\setleftrightkerning{Oacute}{O}{1000}
+\setleftrightkerning{Ocircumflex}{O}{1000}
+\setleftrightkerning{Odieresis}{O}{1000}
+\setleftrightkerning{Ograve}{O}{1000}
+\setleftrightkerning{Ohungarumlaut}{O}{1000}
+\setleftrightkerning{Oslash}{O}{1000}
+\setleftrightkerning{Otilde}{O}{1000}
+
+\setleftrightkerning{Rcaron}{R}{1000}
+\setleftrightkerning{Racute}{R}{1000}
+
+\setleftrightkerning{SS}{S}{1000}
+\setleftrightkerning{Sacute}{S}{1000}
+\setleftrightkerning{Scaron}{S}{1000}
+\setleftrightkerning{Scedilla}{S}{1000}
+
+\setleftrightkerning{Tcaron}{T}{1000}
+\setleftrightkerning{Tcedilla}{T}{1000}
+
+\setleftrightkerning{Uacute}{U}{1000}
+\setleftrightkerning{Ucircumflex}{U}{1000}
+\setleftrightkerning{Udieresis}{U}{1000}
+\setleftrightkerning{Ugrave}{U}{1000}
+\setleftrightkerning{Uhungarumlaut}{U}{1000}
+\setleftrightkerning{Uring}{U}{1000}
+
+\setleftrightkerning{Yacute}{Y}{1000}
+\setleftrightkerning{Ydieresis}{Y}{1000}
+
+\setleftrightkerning{Zacute}{Z}{1000}
+\setleftrightkerning{Zcaron}{Z}{1000}
+\setleftrightkerning{Zdotaccent}{Z}{1000}
+
+
+\setleftrightkerning{Aacutesmall}{Asmall}{1000}
+\setleftrightkerning{Abrevesmall}{Asmall}{1000}
+\setleftrightkerning{Acircumflexsmall}{Asmall}{1000}
+\setleftrightkerning{Adieresissmall}{Asmall}{1000}
+\setleftrightkerning{Agravesmall}{Asmall}{1000}
+\setleftrightkerning{Aogoneksmall}{Asmall}{1000}
+\setleftrightkerning{Aringsmall}{Asmall}{1000}
+\setleftrightkerning{Atildesmall}{Asmall}{1000}
+
+\setleftrightkerning{Cacutesmall}{Csmall}{1000}
+\setleftrightkerning{Ccaronsmall}{Csmall}{1000}
+\setleftrightkerning{Ccedillasmall}{Csmall}{1000}
+
+\setleftrightkerning{Dcaronsmall}{Dsmall}{1000}
+
+\setleftrightkerning{Eacutesmall}{Esmall}{1000}
+\setleftrightkerning{Ecaronsmall}{Esmall}{1000}
+\setleftrightkerning{Ecircumflexsmall}{Esmall}{1000}
+\setleftrightkerning{Edieresissmall}{Esmall}{1000}
+\setleftrightkerning{Egravesmall}{Esmall}{1000}
+\setleftrightkerning{Eogoneksmall}{Esmall}{1000}
+
+\setleftrightkerning{Gbrevesmall}{Gsmall}{1000}
+
+\setleftrightkerning{Iacutesmall}{Ismall}{1000}
+\setleftrightkerning{Icircumflexsmall}{Ismall}{1000}
+\setleftrightkerning{Idieresissmall}{Ismall}{1000}
+\setleftrightkerning{Idotaccentsmall}{Ismall}{1000}
+\setleftrightkerning{Igravesmall}{Ismall}{1000}
+
+\setleftrightkerning{Lacutesmall}{Lsmall}{1000}
+\setleftrightkerning{Lslashsmall}{Lsmall}{1000}
+\setleftkerning{Lcaronsmall}{Lsmall}{1000}
+
+\setleftrightkerning{Nacutesmall}{Nsmall}{1000}
+\setleftrightkerning{Ncaronsmall}{Nsmall}{1000}
+\setleftrightkerning{Ntildesmall}{Nsmall}{1000}
+
+%\setleftkerning{Ngsmall}{Nsmall}{1000}
+%\setrightkerning{Ngsmall}{Jsmall}{1000}
+
+\setleftrightkerning{Oacutesmall}{Osmall}{1000}
+\setleftrightkerning{Ocircumflexsmall}{Osmall}{1000}
+\setleftrightkerning{Odieresissmall}{Osmall}{1000}
+\setleftrightkerning{Ogravesmall}{Osmall}{1000}
+\setleftrightkerning{Ohungarumlautsmall}{Osmall}{1000}
+\setleftrightkerning{Oslashsmall}{Osmall}{1000}
+\setleftrightkerning{Otildesmall}{Osmall}{1000}
+
+\setleftrightkerning{Rcaronsmall}{Rsmall}{1000}
+\setleftrightkerning{Racutesmall}{Rsmall}{1000}
+
+\setleftrightkerning{SSsmall}{Ssmall}{1000}
+\setleftrightkerning{Sacutesmall}{Ssmall}{1000}
+\setleftrightkerning{Scaronsmall}{Ssmall}{1000}
+\setleftrightkerning{Scedillasmall}{Ssmall}{1000}
+
+\setleftrightkerning{Tcaronsmall}{Tsmall}{1000}
+\setleftrightkerning{Tcedillasmall}{Tsmall}{1000}
+
+\setleftrightkerning{Uacutesmall}{Usmall}{1000}
+\setleftrightkerning{Ucircumflexsmall}{Usmall}{1000}
+\setleftrightkerning{Udieresissmall}{Usmall}{1000}
+\setleftrightkerning{Ugravesmall}{Usmall}{1000}
+\setleftrightkerning{Uhungarumlautsmall}{Usmall}{1000}
+\setleftrightkerning{Uringsmall}{Usmall}{1000}
+
+\setleftrightkerning{Yacutesmall}{Ysmall}{1000}
+\setleftrightkerning{Ydieresissmall}{Ysmall}{1000}
+
+\setleftrightkerning{Zacutesmall}{Zsmall}{1000}
+\setleftrightkerning{Zcaronsmall}{Zsmall}{1000}
+\setleftrightkerning{Zdotaccentsmall}{Zsmall}{1000}
+
+
+\comment{\section{All-caps kerning}}
+
+\setleftrightkerning{dotlessI}{I}{1000}
+\setleftrightkerning{dotlessJ}{J}{1000}
+\setleftrightkerning{FFspaced}{F}{1000}
+\setleftkerning{FIspaced}{F}{1000}
+\setrightkerning{FIspaced}{I}{1000}
+\setleftkerning{FLspaced}{F}{1000}
+\setrightkerning{FLspaced}{L}{1000}
+\setleftkerning{FFIspaced}{F}{1000}
+\setrightkerning{FFIspaced}{I}{1000}
+\setleftkerning{FFLspaced}{F}{1000}
+\setrightkerning{FFLspaced}{L}{1000}
+\setleftrightkerning{Dbar}{Eth}{1000}
+\setleftkerning{IJspaced}{I}{1000}
+\setrightkerning{IJspaced}{J}{1000}
+\setleftrightkerning{SSspaced}{S}{1000}
+
+
+\comment{\section{Small caps kerning}}
+
+\setleftrightkerning{dotlessIsmall}{Ismall}{1000}
+\setleftrightkerning{dotlessJsmall}{Jsmall}{1000}
+
+
+\comment{\section{Unfakable glyphs}}
+
+\unfakable{Gamma}
+\unfakable{Delta}
+\unfakable{Theta}
+\unfakable{Lambda}
+\unfakable{Xi}
+\unfakable{Pi}
+\unfakable{Sigma}
+\unfakable{Upsilon}
+\unfakable{Upsilon1}
+\unfakable{Phi}
+\unfakable{Psi}
+\unfakable{Omega}
+
+\unfakable{grave}
+\unfakable{acute}
+\unfakable{circumflex}
+\unfakable{tilde}
+\unfakable{dieresis}
+\unfakable{hungarumlaut}
+\unfakable{ring}
+\unfakable{caron}
+\unfakable{breve}
+\unfakable{macron}
+\unfakable{dotaccent}
+\unfakable{cedilla}
+\unfakable{ogonek}
+\unfakable{guilsinglleft}
+\unfakable{guilsinglright}
+\unfakable{quotedblleft}
+\unfakable{quotedblright}
+\unfakable{quotedblbase}
+\unfakable{guillemotleft}
+\unfakable{guillemotright}
+\unfakable{endash}
+\unfakable{emdash}
+\unfakable{dotlessi}
+\unfakable{perthousandzero}
+\unfakable{exclam}
+\unfakable{quotedbl}
+\unfakable{numbersign}
+\unfakable{dollar}
+\unfakable{percent}
+\unfakable{ampersand}
+\unfakable{quoteright}
+\unfakable{parenleft}
+\unfakable{parenright}
+\unfakable{asterisk}
+\unfakable{plus}
+\unfakable{comma}
+\unfakable{hyphen}
+\unfakable{period}
+\unfakable{slash}
+\unfakable{zero}
+\unfakable{one}
+\unfakable{two}
+\unfakable{three}
+\unfakable{four}
+\unfakable{five}
+\unfakable{six}
+\unfakable{seven}
+\unfakable{eight}
+\unfakable{nine}
+\unfakable{zerooldstyle}
+\unfakable{oneoldstyle}
+\unfakable{twooldstyle}
+\unfakable{threeoldstyle}
+\unfakable{fouroldstyle}
+\unfakable{fiveoldstyle}
+\unfakable{sixoldstyle}
+\unfakable{sevenoldstyle}
+\unfakable{eightoldstyle}
+\unfakable{nineoldstyle}
+\unfakable{colon}
+\unfakable{semicolon}
+\unfakable{less}
+\unfakable{equal}
+\unfakable{greater}
+\unfakable{question}
+\unfakable{at}
+\unfakable{A}
+\unfakable{B}
+\unfakable{C}
+\unfakable{D}
+\unfakable{E}
+\unfakable{F}
+\unfakable{G}
+\unfakable{H}
+\unfakable{I}
+\unfakable{J}
+\unfakable{K}
+\unfakable{L}
+\unfakable{M}
+\unfakable{N}
+\unfakable{O}
+\unfakable{P}
+\unfakable{Q}
+\unfakable{R}
+\unfakable{S}
+\unfakable{T}
+\unfakable{U}
+\unfakable{V}
+\unfakable{W}
+\unfakable{X}
+\unfakable{Y}
+\unfakable{Z}
+\unfakable{bracketleft}
+\unfakable{backslash}
+\unfakable{bracketright}
+\unfakable{asciicircum}
+\unfakable{underscore}
+\unfakable{quoteleft}
+\unfakable{a}
+\unfakable{b}
+\unfakable{c}
+\unfakable{d}
+\unfakable{e}
+\unfakable{f}
+\unfakable{g}
+\unfakable{h}
+\unfakable{i}
+\unfakable{j}
+\unfakable{k}
+\unfakable{l}
+\unfakable{m}
+\unfakable{n}
+\unfakable{o}
+\unfakable{p}
+\unfakable{q}
+\unfakable{r}
+\unfakable{s}
+\unfakable{t}
+\unfakable{u}
+\unfakable{v}
+\unfakable{w}
+\unfakable{x}
+\unfakable{y}
+\unfakable{z}
+\unfakable{braceleft}
+\unfakable{bar}
+\unfakable{braceright}
+\unfakable{asciitilde}
+\unfakable{Eng}
+\unfakable{section}
+\unfakable{Engsmall}
+\unfakable{exclamdown}
+\unfakable{questiondown}
+\unfakable{sterling}
+\unfakable{AE}
+\unfakable{Eth}
+\unfakable{OE}
+\unfakable{Oslash}
+\unfakable{Thorn}
+\unfakable{AEsmall}
+\unfakable{Ethsmall}
+\unfakable{OEsmall}
+\unfakable{Oslashsmall}
+\unfakable{Thornsmall}
+\unfakable{germandbls}
+\unfakable{lslashslash}
+
+\setglyph{dotlessj}
+ \moveup{\neg{\depth{j}}}
+ \glyphrule{\width{j}}{\add{\depth{j}}{\height{dotlessi}}}
+ \resetitalic{\italic{dotlessi}}
+ \moveup{\depth{j}}
+ \glyphwarning{missing glyph `dotlessj'}
+\endsetglyph
+
+
+\comment{\section{Glyphs}}
+
+% only with monospaced fonts. (WaS)
+\ifisint{monowidth}\then
+\resetglyph{asterisk}
+ \moveup{\neg{\sub{\scale{\sub{\height{asterisk}}{\depth{asterisk}}}{500}}{\int{vaxis}}}}
+ \glyph{asterisk}{1000}
+ \resetdepth{0}
+\endresetglyph
+\fi
+
+\setglyph{space}
+ \ifisglyph{space-not}\then
+ \movert{\width{space-not}}
+ \else
+ \movert{\width{i}}
+ \fi
+\endsetglyph
+
+\setglyph{compwordmark}
+ \glyphrule{0}{\int{xheight}}
+\endsetglyph
+\setint{compwordmark-spacing}{0}
+
+\setglyph{quotesinglbase}
+ \glyph{comma}{1000}
+\endsetglyph
+
+\setglyph{visiblespace}
+ \moveup{\neg{\int{visiblespacedepth}}}
+ \movert{\int{visiblespacesurround}}
+ \glyphrule
+ {\int{underlinethickness}}
+ {\int{visiblespacedepth}}
+ \glyphrule
+ {\int{visiblespacewidth}}
+ {\int{underlinethickness}}
+ \glyphrule
+ {\int{underlinethickness}}
+ {\int{visiblespacedepth}}
+ \movert{\int{visiblespacesurround}}
+ \moveup{\int{visiblespacedepth}}
+\endsetglyph
+
+\setglyph{rangedash}
+ \ifisint{monowidth}\then
+ \glyph{hyphen}{1000}
+ \else
+ \glyph{endash}{1000}
+ \fi
+\endsetglyph
+
+\setglyph{punctdash}
+ \ifisint{monowidth}\then
+ \glyph{hyphen}{1000}
+ \glyph{hyphen}{1000}
+ \else
+ \glyph{emdash}{1000}
+ \fi
+\endsetglyph
+
+\setglyph{hyphenchar}
+ \glyph{hyphen}{1000}
+\endsetglyph
+
+\setglyph{ringfitted}
+ \movert{\div{\sub{\width{A}}{\width{ring}}}{2}}
+ \glyph{ring}{1000}
+ \movert{\div{\sub{\width{A}}{\width{ring}}}{2}}
+\endsetglyph
+
+%\setglyph{lslash}
+% \glyph{lslashslash}{1000}
+% \movert{\kerning{lslashslash}{l}}
+% \glyph{l}{1000}
+%\endsetglyph
+
+%\setglyph{Lslash}
+% \glyph{lslashslash}{1000}
+% \movert{\kerning{lslashslash}{L}}
+% \glyph{L}{1000}
+%\endsetglyph
+
+\setglyph{Ng}
+ \glyph{Eng}{1000}
+\endsetglyph
+
+\setglyph{Ngsmall}
+ \glyph{Engsmall}{1000}
+\endsetglyph
+
+\setglyph{Abreve}
+ \topaccent{A}{breve}{500}
+\endsetglyph
+
+\setglyph{Aogonek}
+ \botaccent{A}{ogonek}{900}
+\endsetglyph
+
+\setglyph{Cacute}
+ \topaccent{C}{acute}{500}
+\endsetglyph
+
+\setglyph{Ccaron}
+ \topaccent{C}{caron}{500}
+\endsetglyph
+
+\setglyph{Dcaron}
+ \topaccent{D}{caron}{450}
+\endsetglyph
+
+\setglyph{Ecaron}
+ \topaccent{E}{caron}{500}
+\endsetglyph
+
+\setglyph{Eogonek}
+ \botaccent{E}{ogonek}{850}
+\endsetglyph
+
+\setglyph{Gbreve}
+ \topaccent{G}{breve}{500}
+\endsetglyph
+
+\setglyph{Lacute}
+ \topaccent{L}{acute}{250}
+\endsetglyph
+
+\setglyph{Lcaron}
+ \glyph{L}{1000}
+ \ifisint{monowidth}\then\else
+ \movert{-200}
+ \fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+
+\setglyph{Nacute}
+ \topaccent{N}{acute}{500}
+\endsetglyph
+
+\setglyph{Ncaron}
+ \topaccent{N}{caron}{500}
+\endsetglyph
+
+\setglyph{Ohungarumlaut}
+ \topaccent{O}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Racute}
+ \topaccent{R}{acute}{500}
+\endsetglyph
+
+\setglyph{Rcaron}
+ \topaccent{R}{caron}{500}
+\endsetglyph
+
+\setglyph{Sacute}
+ \topaccent{S}{acute}{500}
+\endsetglyph
+
+\setglyph{Scaron}
+ \topaccent{S}{caron}{500}
+\endsetglyph
+
+\setglyph{Scedilla}
+ \botaccent{S}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Tcaron}
+ \topaccent{T}{caron}{500}
+\endsetglyph
+
+\setglyph{Tcedilla}
+ \botaccent{T}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Uhungarumlaut}
+ \topaccent{U}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Uring}
+ \topaccent{U}{ring}{500}
+\endsetglyph
+
+\setglyph{Ydieresis}
+ \topaccent{Y}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Zacute}
+ \topaccent{Z}{acute}{500}
+\endsetglyph
+
+\setglyph{Zcaron}
+ \topaccent{Z}{caron}{500}
+\endsetglyph
+
+\setglyph{Zdotaccent}
+ \topaccent{Z}{dotaccent}{500}
+\endsetglyph
+
+\setglyph{IJ}
+ \glyph{I}{1000}
+ \movert{\kerning{I}{J}}
+ \glyph{J}{1000}
+\endsetglyph
+
+\setglyph{Idotaccent}
+ \topaccent{I}{dotaccent}{500}
+\endsetglyph
+
+\setglyph{Agrave}
+ \topaccent{A}{grave}{500}
+\endsetglyph
+
+\setglyph{Aacute}
+ \topaccent{A}{acute}{500}
+\endsetglyph
+
+\setglyph{Acircumflex}
+ \topaccent{A}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Atilde}
+ \topaccent{A}{tilde}{500}
+\endsetglyph
+
+\setglyph{Adieresis}
+ \topaccent{A}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Aring}
+ \topaccent{A}{ring}{500}
+\endsetglyph
+
+\setglyph{Ccedilla}
+ \botaccent{C}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Egrave}
+ \topaccent{E}{grave}{500}
+\endsetglyph
+
+\setglyph{Eacute}
+ \topaccent{E}{acute}{500}
+\endsetglyph
+
+\setglyph{Ecircumflex}
+ \topaccent{E}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Edieresis}
+ \topaccent{E}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Iacute}
+ \topaccent{I}{acute}{500}
+\endsetglyph
+
+\setglyph{Igrave}
+ \topaccent{I}{grave}{500}
+\endsetglyph
+
+\setglyph{Icircumflex}
+ \topaccent{I}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Idieresis}
+ \topaccent{I}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Ntilde}
+ \topaccent{N}{tilde}{500}
+\endsetglyph
+
+\setglyph{Ograve}
+ \topaccent{O}{grave}{500}
+\endsetglyph
+
+\setglyph{Oacute}
+ \topaccent{O}{acute}{500}
+\endsetglyph
+
+\setglyph{Ocircumflex}
+ \topaccent{O}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Otilde}
+ \topaccent{O}{tilde}{500}
+\endsetglyph
+
+\setglyph{Odieresis}
+ \topaccent{O}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Ugrave}
+ \topaccent{U}{grave}{500}
+\endsetglyph
+
+\setglyph{Uacute}
+ \topaccent{U}{acute}{500}
+\endsetglyph
+
+\setglyph{Ucircumflex}
+ \topaccent{U}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Udieresis}
+ \topaccent{U}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Yacute}
+ \topaccent{Y}{acute}{500}
+\endsetglyph
+
+\setglyph{SS}
+ \glyph{S}{1000}
+ \movert{\kerning{S}{S}}
+ \glyph{S}{1000}
+\endsetglyph
+
+
+\comment{\section{All-caps glyphs}}
+
+\setglyph{dotlessI}
+ \glyph{I}{1000}
+\endsetglyph
+
+\setglyph{dotlessJ}
+ \glyph{J}{1000}
+\endsetglyph
+
+\setglyph{FFspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{F}}
+ {\int{capspacing}}}
+ \glyph{F}{1000}
+\endsetglyph
+
+\setglyph{FIspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{I}}
+ {\int{capspacing}}}
+ \glyph{I}{1000}
+\endsetglyph
+
+\setglyph{FLspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{L}}
+ {\int{capspacing}}}
+ \glyph{L}{1000}
+\endsetglyph
+
+\setglyph{FFIspaced}
+ \glyph{FFspaced}{1000}
+ \movert{\add{\kerning{FFspaced}{I}}
+ {\int{capspacing}}}
+ \glyph{I}{1000}
+\endsetglyph
+
+\setglyph{FFLspaced}
+ \glyph{FFspaced}{1000}
+ \movert{\add{\kerning{FFspaced}{L}}
+ {\int{capspacing}}}
+ \glyph{L}{1000}
+\endsetglyph
+
+\setglyph{Dbar}
+ \glyph{Eth}{1000}
+\endsetglyph
+
+\setglyph{IJspaced}
+ \glyph{I}{1000}
+ \movert{\add{\kerning{I}{J}}{\int{capspacing}}}
+ \glyph{J}{1000}
+\endsetglyph
+
+\setglyph{SSspaced}
+ \glyph{S}{1000}
+ \movert{\add{\kerning{S}{S}}{\int{capspacing}}}
+ \glyph{S}{1000}
+\endsetglyph
+
+
+\comment{\section{Small caps glyphs}}
+
+\setglyph{Acutesmall}
+ \cscaccent{acute}
+\endsetglyph
+
+\setglyph{acutesmall}
+ \glyph{Acutesmall}{1000}
+\endsetglyph
+
+\setglyph{Gravesmall}
+ \cscaccent{grave}
+\endsetglyph
+
+\setglyph{gravesmall}
+ \glyph{Gravesmall}{1000}
+\endsetglyph
+
+\setglyph{Circumflexsmall}
+ \cscaccent{circumflex}
+\endsetglyph
+
+\setglyph{circumflexsmall}
+ \glyph{Circumflexsmall}{1000}
+\endsetglyph
+
+\setglyph{Tildesmall}
+ \cscaccent{tilde}
+\endsetglyph
+
+\setglyph{tildesmall}
+ \glyph{Tildesmall}{1000}
+\endsetglyph
+
+\setglyph{Dieresissmall}
+ \cscaccent{dieresis}
+\endsetglyph
+
+\setglyph{dieresissmall}
+ \glyph{Dieresissmall}{1000}
+\endsetglyph
+
+\setglyph{Brevesmall}
+ \cscaccent{breve}
+\endsetglyph
+
+\setglyph{brevesmall}
+ \glyph{Brevesmall}{1000}
+\endsetglyph
+
+\setglyph{Dotaccentsmall}
+ \cscaccent{dotaccent}
+\endsetglyph
+
+\setglyph{dotaccentsmall}
+ \glyph{Dotaccentsmall}{1000}
+\endsetglyph
+
+\setglyph{Caronsmall}
+ \cscaccent{caron}
+\endsetglyph
+
+\setglyph{caronsmall}
+ \glyph{Caronsmall}{1000}
+\endsetglyph
+
+\setglyph{Hungarumlautsmall}
+ \cscaccent{hungarumlaut}
+\endsetglyph
+
+\setglyph{hungarumlautsmall}
+ \glyph{Hungarumlautsmall}{1000}
+\endsetglyph
+
+\setglyph{Ringsmall}
+ \cscaccent{ring}
+\endsetglyph
+
+\setglyph{ringsmall}
+ \glyph{Ringsmall}{1000}
+\endsetglyph
+
+\setglyph{Cedillasmall}
+ \cscglyph{cedilla}
+\endsetglyph
+
+\setglyph{cedillasmall}
+ \glyph{Cedillasmall}{1000}
+\endsetglyph
+
+\setglyph{Ogoneksmall}
+ \cscglyph{ogonek}
+\endsetglyph
+
+\setglyph{ogoneksmall}
+ \glyph{Ogoneksmall}{1000}
+\endsetglyph
+
+\setglyph{Abrevesmall}
+ \csctopaccent{A}{breve}{500}
+\endsetglyph
+
+\setglyph{Aogoneksmall}
+ \cscbotaccent{A}{ogonek}{900}
+\endsetglyph
+
+\setglyph{Cacutesmall}
+ \csctopaccent{C}{acute}{500}
+\endsetglyph
+
+\setglyph{Ccaronsmall}
+ \csctopaccent{C}{caron}{500}
+\endsetglyph
+
+\setglyph{Dcaronsmall}
+ \csctopaccent{D}{caron}{500}
+\endsetglyph
+
+\setglyph{Ecaronsmall}
+ \csctopaccent{E}{caron}{500}
+\endsetglyph
+
+\setglyph{Eogoneksmall}
+ \cscbotaccent{E}{ogonek}{850}
+\endsetglyph
+
+\setglyph{Gbrevesmall}
+ \csctopaccent{G}{breve}{500}
+\endsetglyph
+
+\setglyph{Lacutesmall}
+ \csctopaccent{L}{acute}{250}
+\endsetglyph
+
+\setglyph{Nacutesmall}
+ \csctopaccent{N}{acute}{500}
+\endsetglyph
+
+\setglyph{Ncaronsmall}
+ \csctopaccent{N}{caron}{500}
+\endsetglyph
+
+\setglyph{Ngsmall}
+ \cscglyph{Ng}
+\endsetglyph
+
+\setglyph{Ohungarumlautsmall}
+ \csctopaccent{O}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Racutesmall}
+ \csctopaccent{R}{acute}{500}
+\endsetglyph
+
+\setglyph{Rcaronsmall}
+ \csctopaccent{R}{caron}{500}
+\endsetglyph
+
+\setglyph{Sacutesmall}
+ \csctopaccent{S}{acute}{500}
+\endsetglyph
+
+\setglyph{Scaronsmall}
+ \csctopaccent{S}{caron}{500}
+\endsetglyph
+
+\setglyph{Scedillasmall}
+ \cscbotaccent{S}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Tcaronsmall}
+ \csctopaccent{T}{caron}{500}
+\endsetglyph
+
+\setglyph{Tcedillasmall}
+ \cscbotaccent{T}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Uhungarumlautsmall}
+ \csctopaccent{U}{hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Uringsmall}
+ \csctopaccent{U}{ring}{500}
+\endsetglyph
+
+\setglyph{Ydieresissmall}
+ \csctopaccent{Y}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Zacutesmall}
+ \csctopaccent{Z}{acute}{500}
+\endsetglyph
+
+\setglyph{Zcaronsmall}
+ \csctopaccent{Z}{caron}{500}
+\endsetglyph
+
+\setglyph{Zdotaccentsmall}
+ \csctopaccent{Z}{dotaccent}{500}
+\endsetglyph
+
+\setglyph{Agravesmall}
+ \csctopaccent{A}{grave}{500}
+\endsetglyph
+
+\setglyph{Aacutesmall}
+ \csctopaccent{A}{acute}{500}
+\endsetglyph
+
+\setglyph{Acircumflexsmall}
+ \csctopaccent{A}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Atildesmall}
+ \csctopaccent{A}{tilde}{500}
+\endsetglyph
+
+\setglyph{Adieresissmall}
+ \csctopaccent{A}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Aringsmall}
+ \csctopaccent{A}{ring}{500}
+\endsetglyph
+
+\setglyph{Ccedillasmall}
+ \csctopaccent{C}{cedilla}{500}
+\endsetglyph
+
+\setglyph{Egravesmall}
+ \csctopaccent{E}{grave}{500}
+\endsetglyph
+
+\setglyph{Eacutesmall}
+ \csctopaccent{E}{acute}{500}
+\endsetglyph
+
+\setglyph{Ecircumflexsmall}
+ \csctopaccent{E}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Edieresissmall}
+ \csctopaccent{E}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Igravesmall}
+ \csctopaccent{I}{grave}{500}
+\endsetglyph
+
+\setglyph{Iacutesmall}
+ \csctopaccent{I}{acute}{500}
+\endsetglyph
+
+\setglyph{Icircumflexsmall}
+ \csctopaccent{I}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Idieresissmall}
+ \csctopaccent{I}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Ethsmall}
+ \cscglyph{Eth}
+\endsetglyph
+
+\setglyph{Dbarsmall}
+ \glyph{Ethsmall}{1000}
+\endsetglyph
+
+\setglyph{Ntildesmall}
+ \csctopaccent{N}{tilde}{500}
+\endsetglyph
+
+\setglyph{Ogravesmall}
+ \csctopaccent{O}{grave}{500}
+\endsetglyph
+
+\setglyph{Oacutesmall}
+ \csctopaccent{O}{acute}{500}
+\endsetglyph
+
+\setglyph{Ocircumflexsmall}
+ \csctopaccent{O}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Otildesmall}
+ \csctopaccent{O}{tilde}{500}
+\endsetglyph
+
+\setglyph{Odieresissmall}
+ \csctopaccent{O}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Ugravesmall}
+ \csctopaccent{U}{grave}{500}
+\endsetglyph
+
+\setglyph{Uacutesmall}
+ \csctopaccent{U}{acute}{500}
+\endsetglyph
+
+\setglyph{Ucircumflexsmall}
+ \csctopaccent{U}{circumflex}{500}
+\endsetglyph
+
+\setglyph{Udieresissmall}
+ \csctopaccent{U}{dieresis}{500}
+\endsetglyph
+
+\setglyph{Yacutesmall}
+ \csctopaccent{Y}{acute}{500}
+\endsetglyph
+
+\setglyph{Thornsmall}
+ \cscglyph{Thorn}
+\endsetglyph
+
+\setglyph{dotlessIsmall}
+ \glyph{Ismall}{1000}
+\endsetglyph
+
+\setglyph{dotlessJsmall}
+ \glyph{Jsmall}{1000}
+\endsetglyph
+
+\setglyph{FFsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Fsmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Fsmall}{1000}
+\endsetglyph
+
+\setglyph{FIsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Ismall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Ismall}{1000}
+\endsetglyph
+
+\setglyph{FLsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Lsmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Lsmall}{1000}
+\endsetglyph
+
+\setglyph{FFIsmall}
+ \glyph{FFsmall}{1000}
+ \movert{\add{\kerning{FFsmall}{Ismall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Ismall}{1000}
+\endsetglyph
+
+\setglyph{FFLsmall}
+ \glyph{FFsmall}{1000}
+ \movert{\add{\kerning{FFsmall}{Lsmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Lsmall}{1000}
+\endsetglyph
+
+\setglyph{IJsmall}
+ \glyph{Ismall}{1000}
+ \movert{\add{\kerning{Ismall}{Jsmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Jsmall}{1000}
+\endsetglyph
+
+\setglyph{Lcaronsmall}
+ \glyph{Lsmall}{1000}
+ \ifisint{monowidth}\then\else
+ \movert{-100}
+ \fi
+ \glyph{quoteright}{\int{smallcapsscale}}
+\endsetglyph
+
+\setglyph{SSsmall}
+ \glyph{Ssmall}{1000}
+ \movert{\add{\kerning{Ssmall}{Ssmall}}
+ {\mul{2}{\int{smallcapsextraspace}}}}
+ \glyph{Ssmall}{1000}
+\endsetglyph
+
+
+\comment{\section{Accents}
+ \TeX's math accent-positioning requires accents to have zero depth.}
+
+\setcommand\zerodepth#1{
+ \ifisglyph{#1}\then
+ \resetglyph{#1}
+ \glyph{#1}{1000}
+ \resetdepth{0}
+ \endresetglyph
+ \fi
+}
+\zerodepth{Gravesmall}
+\zerodepth{Acutesmall}
+\zerodepth{Circumflexsmall}
+\zerodepth{Tildesmall}
+\zerodepth{Dieresissmall}
+\zerodepth{Hungarumlautsmall}
+\zerodepth{Ringsmall}
+\zerodepth{Caronsmall}
+\zerodepth{Brevesmall}
+\zerodepth{Macronsmall}
+\zerodepth{Dotaccentsmall}
+
+\endmetrics
+
+\section{Changes}
+
+2003/03/17: Added \texttt{vaxis} for the vertical symmetry axis.
+Changed `\texttt{asterisk}', which is now vertically centered
+in monospaced fonts. (WaS)
+
+1999/10/25: Simplified definition of \verb|\unfakable|. (UV\&LH)
+Rationale: It is thoroughly confusing if the size of the black box
+created by \verb|\unfakable| depends on the metrics of an unencoded
+glyph that isn't accessible and therefore unavailable for all
+pratical purposes.
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/llbuild.mtx b/fonts/utilities/fontinst/inputs/latinmtx/llbuild.mtx
new file mode 100644
index 0000000000..91306fbaf3
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/llbuild.mtx
@@ -0,0 +1,568 @@
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.923",
+%%% date = "2003-03-29",
+%%% time = "01:24:47 +01:00",
+%%% filename = "llbuild.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It builds upper case latin
+%%% letters.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}[2002/03/01]
+\showbranches
+
+\title{Building lower case}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{5 January 2002\\Version 1.923}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This file builds lower case (small, \texttt{l} case) latin letters,
+or more precisely, it makes sure that a set of glyphs is defined that
+cover the lower case letters used in European latin scripts.
+Even that is a slight exaggeration, because there are a couple of
+``exotic'' letters that are missing, but most people never try to use
+those anyway.
+
+For the glyphs set in this file to look anything like the letters they
+are supposed to be, it is necessary that the glyphs for unaccented
+letters and for accents already exist and look like they are supposed
+to. In that case, the commands below will manufacture decent
+substitutes for the missing glyphs by composing letters and accents.
+If some of these base glyphs are missing, then a ``missing glyph''
+substitute will be supplied for them. Such substitutes will show up in
+print as black squares, and most DVI drivers will emit a warning when
+producing them.
+
+The most common case encountered is that almost all unaccented letters
+and accents are available, but only about half of the accented
+letters. Then for the other half, quite decent substitutes are made,
+but a few letters only show up as ``missing glyph'' boxes.
+
+
+\metrics
+
+\needsfontinstversion{1.910}
+\usemtxpackage{ltcmds}
+
+\ProvidesMtxPackage{llbuild}
+
+\begincomment
+\section{Lower case base glyphs}
+
+\subsection{Unfakable glyphs}
+
+The following commands make sure all the unaccented letter glyphs and
+accent glyphs are set. If any of them are not already set at this
+point, then those will be set to ``missing glyph'' boxes.
+\endcomment
+
+\unfakable{a}
+\unfakable{ae}
+\unfakable{b}
+\unfakable{c}
+\unfakable{d}
+\unfakable{dotlessi}
+\unfakable{e}
+\unfakable{eng}
+\unfakable{eth}
+\unfakable{f}
+\unfakable{g}
+\unfakable{germandbls}
+\unfakable{h}
+\unfakable{i}
+\unfakable{j}
+\unfakable{k}
+\unfakable{l}
+\unfakable{m}
+\unfakable{n}
+\unfakable{o}
+\unfakable{oe}
+\unfakable{oslash}
+\unfakable{p}
+\unfakable{q}
+\unfakable{r}
+\unfakable{s}
+\unfakable{t}
+\unfakable{thorn}
+\unfakable{u}
+\unfakable{v}
+\unfakable{w}
+\unfakable{x}
+\unfakable{y}
+\unfakable{z}
+
+
+\unfakabletopaccent{acute}
+\unfakabletopaccent{breve}
+\unfakabletopaccent{caron}
+\unfakable{cedilla}
+\unfakabletopaccent{circumflex}
+\unfakabletopaccent{dieresis}
+\unfakabletopaccent{dotaccent}
+\unfakabletopaccent{grave}
+\unfakabletopaccent{hungarumlaut}
+\unfakable{lslashslash}
+\unfakabletopaccent{macron}
+\unfakable{ogonek}
+\unfakabletopaccent{quoteright}
+\unfakabletopaccent{ring}
+\unfakabletopaccent{tilde}
+
+\begincomment
+\subsection{Fakable lower case glyphs}
+\endcomment
+
+\ifisglyph{dcroat}\then
+ \setglyph{dbar}
+ \glyph{dcroat}{1000}
+ \endsetglyph
+\Else
+ \setglyph{dbar}
+ \push
+ \movert{\sub{\width{d}}{\width{macron}}}
+ \moveup{
+ \sub{\half{\add{\height{d}}{\int{xheight}}}}
+ {\height{macron}}}
+ \glyph{macron}{1000}
+ \pop
+ \glyph{d}{1000}
+ \endsetglyph
+\Fi
+\setleftrightkerning{dbar}{d}{1000}
+
+\setglyph{dotlessj}
+ \glyph{j}{1000}
+ \resetheight{\int{xheight}}
+ \comment{The reason \texttt{dotlessj} \emph{can} be faked using a
+ \texttt{j} is that it is not a distinct character. Unlike
+ \texttt{dotlessi}, which is in Turkish a letter distinct from
+ \texttt{i}, the only thing \texttt{dotlessj} is ever used for is
+ as the base glyph for accented j's.}
+\endsetglyph
+\setleftrightkerning{dotlessj}{j}{1000}
+
+
+\begincomment
+\subsection{Aliased lower case glyphs}
+\endcomment
+
+\setglyph{ng}
+ \glyph{eng}{1000}
+\endsetglyph
+\setleftkerning{ng}{n}{1000}
+\setrightkerning{ng}{j}{1000}
+
+
+\begincomment
+\subsection{Some extra kerning}
+\endcomment
+
+\setleftkerning{oe}{o}{1000}
+\setrightkerning{oe}{e}{1000}
+
+\setleftrightkerning{oslash}{o}{1000}
+
+
+
+\begincomment
+\section{Accented lower case glyphs}
+\endcomment
+
+\setglyph{aacute}
+ \topaccent{a}{acute}{500}
+\endsetglyph
+\setleftrightkerning{aacute}{a}{1000}
+
+\setglyph{abreve}
+ \topaccent{a}{breve}{500}
+\endsetglyph
+\setleftrightkerning{abreve}{a}{1000}
+
+\setglyph{acircumflex}
+ \topaccent{a}{circumflex}{500}
+\endsetglyph
+\setleftrightkerning{acircumflex}{a}{1000}
+
+\setglyph{adieresis}
+ \topaccent{a}{dieresis}{500}
+\endsetglyph
+\setleftrightkerning{adieresis}{a}{1000}
+
+\setglyph{agrave}
+ \topaccent{a}{grave}{500}
+\endsetglyph
+\setleftrightkerning{agrave}{a}{1000}
+
+\setglyph{aogonek}
+ \botaccent{a}{ogonek}{850}
+\endsetglyph
+\setleftrightkerning{aogonek}{a}{1000}
+
+\setglyph{aring}
+ \topaccent{a}{ring}{500}
+\endsetglyph
+\setleftrightkerning{aring}{a}{1000}
+
+\setglyph{atilde}
+ \topaccent{a}{tilde}{500}
+\endsetglyph
+\setleftrightkerning{atilde}{a}{1000}
+
+\setglyph{cacute}
+ \topaccent{c}{acute}{500}
+\endsetglyph
+\setleftrightkerning{cacute}{c}{1000}
+
+\setglyph{ccaron}
+ \topaccent{c}{caron}{500}
+\endsetglyph
+\setleftrightkerning{ccaron}{c}{1000}
+
+\setglyph{ccedilla}
+ \botaccent{c}{cedilla}{500}
+\endsetglyph
+\setleftrightkerning{ccedilla}{c}{1000}
+
+\setglyph{dcaron}
+ \glyph{d}{1000}
+ \ifisint{monowidth}\then\Else
+ \movert{-75}
+ \Fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+\setleftkerning{dcaron}{d}{1000}
+
+\setglyph{eacute}
+ \topaccent{e}{acute}{500}
+\endsetglyph
+\setleftrightkerning{eacute}{e}{1000}
+
+\setglyph{ecaron}
+ \topaccent{e}{caron}{500}
+\endsetglyph
+\setleftrightkerning{ecaron}{e}{1000}
+
+\setglyph{ecircumflex}
+ \topaccent{e}{circumflex}{500}
+\endsetglyph
+\setleftrightkerning{ecircumflex}{e}{1000}
+
+\setglyph{edieresis}
+ \topaccent{e}{dieresis}{500}
+\endsetglyph
+\setleftrightkerning{edieresis}{e}{1000}
+
+\setglyph{egrave}
+ \topaccent{e}{grave}{500}
+\endsetglyph
+\setleftrightkerning{egrave}{e}{1000}
+
+\setglyph{eogonek}
+ \botaccent{e}{ogonek}{500}
+\endsetglyph
+\setleftrightkerning{eogonek}{e}{1000}
+
+\setglyph{gbreve}
+ \topaccent{g}{breve}{500}
+\endsetglyph
+\setleftrightkerning{gbreve}{g}{1000}
+
+\setglyph{iacute}
+ \topaccent{dotlessi}{acute}{500}
+\endsetglyph
+\setleftrightkerning{iacute}{i}{1000}
+
+\setglyph{icircumflex}
+ \topaccent{dotlessi}{circumflex}{500}
+\endsetglyph
+\setleftrightkerning{icircumflex}{i}{1000}
+
+\setglyph{idieresis}
+ \topaccent{dotlessi}{dieresis}{500}
+\endsetglyph
+\setleftrightkerning{idieresis}{i}{1000}
+
+\setglyph{idotaccent}
+ \comment{This should be the normal `\texttt{i}', except in
+ smallcaps fonts.}
+ \ifnumber{\height{i}}>{\scale{\int{xheight}}{1050}}\then
+ \comment{Some quick statistics showed that the height of an
+ `\texttt{i}' with dot is usually around 140\% of the
+ x-height, but to be on the safe side we assume all
+ \texttt{i}s whose height exceed 105\% of the x-height to
+ be dotted.}
+ \glyph{i}{1000}
+ \Else
+ \topaccent{i}{dotaccent}{500}
+ \Fi
+\endsetglyph
+\setleftrightkerning{idotaccent}{i}{1000}
+
+\setglyph{igrave}
+ \topaccent{dotlessi}{grave}{500}
+\endsetglyph
+\setleftrightkerning{igrave}{i}{1000}
+
+\setglyph{lacute}
+ \topaccent{l}{acute}{500}
+\endsetglyph
+\setleftrightkerning{lacute}{l}{1000}
+
+\setglyph{lcaron}
+ \glyph{l}{1000}
+ \ifisint{monowidth}\then\Else
+ \movert{-100}
+ \Fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+\setleftkerning{lcaron}{l}{1000}
+
+\setglyph{lslash}
+ \glyph{lslashslash}{1000}
+ \movert{\kerning{lslashslash}{l}}
+ \glyph{l}{1000}
+\endsetglyph
+\comment{I'm not sure what this should kern like.}
+
+\setglyph{nacute}
+ \topaccent{n}{acute}{500}
+\endsetglyph
+\setleftrightkerning{nacute}{n}{1000}
+
+\setglyph{ncaron}
+ \topaccent{n}{caron}{500}
+\endsetglyph
+\setleftrightkerning{ncaron}{n}{1000}
+
+\setglyph{ntilde}
+ \topaccent{n}{tilde}{500}
+\endsetglyph
+\setleftrightkerning{ntilde}{n}{1000}
+
+\setglyph{oacute}
+ \topaccent{o}{acute}{500}
+\endsetglyph
+\setleftrightkerning{oacute}{o}{1000}
+
+\setglyph{ocircumflex}
+ \topaccent{o}{circumflex}{500}
+\endsetglyph
+\setleftrightkerning{ocircumflex}{o}{1000}
+
+\setglyph{odieresis}
+ \topaccent{o}{dieresis}{500}
+\endsetglyph
+\setleftrightkerning{odieresis}{o}{1000}
+
+\setglyph{ograve}
+ \topaccent{o}{grave}{500}
+\endsetglyph
+\setleftrightkerning{ograve}{o}{1000}
+
+\setglyph{ohungarumlaut}
+ \topaccent{o}{hungarumlaut}{500}
+\endsetglyph
+\setleftrightkerning{ohungarumlaut}{o}{1000}
+
+\setglyph{otilde}
+ \topaccent{o}{tilde}{500}
+\endsetglyph
+\setleftrightkerning{otilde}{o}{1000}
+
+\setglyph{racute}
+ \topaccent{r}{acute}{500}
+\endsetglyph
+\setleftrightkerning{racute}{r}{1000}
+
+\setglyph{rcaron}
+ \topaccent{r}{caron}{500}
+\endsetglyph
+\setleftrightkerning{rcaron}{r}{1000}
+
+\setglyph{sacute}
+ \topaccent{s}{acute}{500}
+\endsetglyph
+\setleftrightkerning{sacute}{s}{1000}
+
+\setglyph{scaron}
+ \topaccent{s}{caron}{500}
+\endsetglyph
+\setleftrightkerning{scaron}{s}{1000}
+
+\setglyph{scedilla}
+ \botaccent{s}{cedilla}{500}
+\endsetglyph
+\setleftrightkerning{scedilla}{s}{1000}
+
+\setglyph{tcaron}
+ \glyph{t}{1000}
+ \ifisint{monowidth}\then\Else
+ \movert{-75}
+ \Fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+\setleftkerning{tcaron}{t}{1000}
+\comment{I don't know what this should kern like on the right.}
+
+\setglyph{tcedilla}
+ \botaccent{t}{cedilla}{500}
+\endsetglyph
+\setleftrightkerning{tcedilla}{t}{1000}
+
+\setglyph{ugrave}
+ \topaccent{u}{grave}{500}
+\endsetglyph
+\setleftrightkerning{ugrave}{u}{1000}
+
+\setglyph{uacute}
+ \topaccent{u}{acute}{500}
+\endsetglyph
+\setleftrightkerning{uacute}{u}{1000}
+
+\setglyph{ucircumflex}
+ \topaccent{u}{circumflex}{500}
+\endsetglyph
+\setleftrightkerning{ucircumflex}{u}{1000}
+
+\setglyph{udieresis}
+ \topaccent{u}{dieresis}{500}
+\endsetglyph
+\setleftrightkerning{udieresis}{u}{1000}
+
+\setglyph{uhungarumlaut}
+ \topaccent{u}{hungarumlaut}{500}
+\endsetglyph
+\setleftrightkerning{uhungarumlaut}{u}{1000}
+
+\setglyph{uring}
+ \topaccent{u}{ring}{500}
+\endsetglyph
+\setleftrightkerning{uring}{u}{1000}
+
+\setglyph{yacute}
+ \topaccent{y}{acute}{500}
+\endsetglyph
+\setleftrightkerning{yacute}{y}{1000}
+
+\setglyph{ydieresis}
+ \topaccent{y}{dieresis}{500}
+\endsetglyph
+\setleftrightkerning{ydieresis}{y}{1000}
+
+\setglyph{zacute}
+ \topaccent{z}{acute}{500}
+\endsetglyph
+\setleftrightkerning{zacute}{z}{1000}
+
+\setglyph{zcaron}
+ \topaccent{z}{caron}{500}
+\endsetglyph
+\setleftrightkerning{zcaron}{z}{1000}
+
+\setglyph{zdotaccent}
+ \topaccentas{z}{dotaccent}{500}{idotaccent}
+\endsetglyph
+\setleftrightkerning{zdotaccent}{z}{1000}
+
+
+\begincomment
+\section{Lower case ligatures}
+\endcomment
+
+\setglyph{fi}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{i}}
+ \glyph{i}{1000}
+\endsetglyph
+\setleftkerning{fi}{f}{1000}
+\setrightkerning{fi}{i}{1000}
+
+\setglyph{ff}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{f}}
+ \glyph{f}{1000}
+\endsetglyph
+\setleftrightkerning{ff}{f}{1000}
+
+\setglyph{fl}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{l}}
+ \glyph{l}{1000}
+\endsetglyph
+\setleftkerning{fl}{f}{1000}
+\setrightkerning{fl}{l}{1000}
+
+\setglyph{ffi}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{f}}
+ \glyph{fi}{1000}
+\endsetglyph
+\setleftkerning{ffi}{f}{1000}
+\setrightkerning{ffi}{i}{1000}
+
+\setglyph{ffl}
+ \glyph{f}{1000}
+ \movert{\kerning{f}{f}}
+ \glyph{fl}{1000}
+\endsetglyph
+\setleftkerning{ffl}{f}{1000}
+\setrightkerning{ffl}{l}{1000}
+
+
+\setglyph{ij}
+ \glyph{i}{1000}
+ \movert{\kerning{i}{j}}
+ \glyph{j}{1000}
+\endsetglyph
+\setleftkerning{ij}{i}{1000}
+\setrightkerning{ij}{j}{1000}
+
+
+
+
+\endmetrics
+
+\section{Changes}
+
+The original version of this file was created in February 2003,
+although it is based on code from the traditional \texttt{latin.mtx}.
+The changes that have been made after that are as follows.
+
+2003/03/15: Using \verb|\unfakabletopaccent| for the accent
+characters. This should change the appearence of accented letters
+built using such a character from ``a black square'' to ``a letter
+with a black square above''. Neither is satisfactory, but the latter
+conveys more information. (LH)
+
+2003/03/15: Modified the construction of `\texttt{zdotaccent}' so that
+it always has the dot at the same vertical position as a dotted i, as
+requested by Walter Schmidt. Also added the `\texttt{idotaccent}'
+glyph to have something to compare with. (LH)
+
+2003/03/15: Added kerning for ligatures; it seems I had forgotten
+that. (LH)
+
+2003/03/29: Added some kerning for non-English unfakable letters. (LH)
+
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/lsbuild.mtx b/fonts/utilities/fontinst/inputs/latinmtx/lsbuild.mtx
new file mode 100644
index 0000000000..35220c773c
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/lsbuild.mtx
@@ -0,0 +1,260 @@
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Lars Hellstr{\"o}m",
+%%% date = "2003-03-29",
+%%% time = "16:16:56 +01:00",
+%%% filename = "lsbuild.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It builds less common
+%%% small caps letters from plain ones and
+%%% accents.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}[2002/03/01]
+\showbranches
+
+\title{Building latin smallcaps letters}
+\author{Lars Hellstr\"om}
+\date{3 January 2003}
+
+\begin{document}
+\maketitle
+
+This file contains commands that build some proper small capital
+glyphs from other small capital glyphs, but nothing is done is those
+base glyphs have not already been set.
+
+If you want to \emph{fake} small capitals using full capitals, then
+have a look at \texttt{lsfake.mtx} instead.
+
+\metrics
+
+\needsfontinstversion{1.917}
+
+\usemtxpackage{ltcmds}
+\ProvidesMtxPackage{lsbuild}
+
+\begincomment
+\section{Proper latin small capitals}
+
+\subsection{Some utility commands}
+\endcomment
+
+\setcommand\setcsctopglyph#1#2#3#4{
+ \ifareglyphs{#2small,#3}\then
+ \setglyph{#1}
+ \topaccent{#2small}{#3}{#4}
+ \endsetglyph
+ \setleftrightkerning{#1}{#2small}{1000}
+ \Fi
+}
+\setcommand\setcscbotglyph#1#2#3#4{
+ \ifareglyphs{#2small,#3}\then
+ \setglyph{#1}
+ \botaccent{#2small}{#3}{#4}
+ \endsetglyph
+ \setleftrightkerning{#1}{#2small}{1000}
+ \Fi
+}
+\begincomment\medskip
+A ``\textbf{Try: Set glyph}'' is an ordinary \textbf{Set glyph} which is
+conditional on that a set of glyphs (those used to construct the
+composite glyph) are available. Technically the command definitions
+are
+\begin{quotation}
+ \verb|\setcsctopglyph|\textit{\#1\#2\#3\#4} $\mapsto$\\
+ \setcsctopglyph{\macroparameter{1}}{\macroparameter{2}}%
+ {\macroparameter{3}}{\macroparameter{4}}
+ \par\medskip
+
+ \verb|\setcscbotglyph|\textit{\#1\#2\#3\#4} $\mapsto$\\
+ \setcscbotglyph{\macroparameter{1}}{\macroparameter{2}}%
+ {\macroparameter{3}}{\macroparameter{4}}\par
+\end{quotation}
+but in the list of commands below those two commands will
+be typeset as
+\resetcommand\setcsctopglyph#1#2#3#4{%
+ \Aheading{Try: Set glyph `\TypesetStringExpression{#1}'}
+ \topaccent{#2small}{#3}{#4}
+ \setleftrightkerning{#1}{#2small}{1000}
+}
+\resetcommand\setcscbotglyph#1#2#3#4{%
+ \Aheading{Try: Set glyph `\TypesetStringExpression{#1}'}
+ \botaccent{#2small}{#3}{#4}
+ \setleftrightkerning{#1}{#2small}{1000}
+}
+\begin{quotation}
+ \setcsctopglyph{\macroparameter{1}}{\macroparameter{2}}%
+ {\macroparameter{3}}{\macroparameter{4}}
+ \setcscbotglyph{\macroparameter{1}}{\macroparameter{2}}%
+ {\macroparameter{3}}{\macroparameter{4}}
+\end{quotation}
+\endcomment
+
+\begincomment
+\subsection{Getting the \textit{smallcapsscale} right}
+
+The \textit{smallcapsscale} integer is normally only used when
+faking smallcaps by shrinking capitals, but with one of the
+glyphs below (\texttt{Lcaron}) it is actually used for shrinking
+the right quote. Thus a suitable default value has to be assigned
+to it.
+\endcomment
+
+\ifareglyphs{L,Lsmall}\then
+ \setint{smallcapsscale}{
+ \div{\mul{1000}{\height{Lsmall}}}{\height{L}}
+ }
+\Else
+ \setint{smallcapsscale}{800}
+\Fi
+
+\begincomment
+\subsection{Accenting smallcaps glyphs}
+
+The commands below build accented smallcaps letters from existing
+smallcaps letters and normal accents. The accent positions are the
+ones traditionally used in \texttt{latin.mtx}.
+
+\endcomment
+
+
+\setcsctopglyph{Aacutesmall}{A}{acute}{500}
+\setcsctopglyph{Abrevesmall}{A}{breve}{500}
+\setcsctopglyph{Acircumflexsmall}{A}{circumflex}{500}
+\setcsctopglyph{Adieresissmall}{A}{dieresis}{500}
+\setcsctopglyph{Agravesmall}{A}{grave}{500}
+\setcscbotglyph{Aogoneksmall}{A}{ogonek}{900}
+\setcsctopglyph{Aringsmall}{A}{ring}{500}
+\setcsctopglyph{Atildesmall}{A}{tilde}{500}
+
+\setcsctopglyph{Cacutesmall}{C}{acute}{500}
+\setcsctopglyph{Ccaronsmall}{C}{caron}{500}
+\setcsctopglyph{Ccedillasmall}{C}{cedilla}{500}
+
+\setcsctopglyph{Dcaronsmall}{D}{caron}{500}
+
+\setcsctopglyph{Eacutesmall}{E}{acute}{500}
+\setcsctopglyph{Ecaronsmall}{E}{caron}{500}
+\setcsctopglyph{Ecircumflexsmall}{E}{circumflex}{500}
+\setcsctopglyph{Edieresissmall}{E}{dieresis}{500}
+\setcsctopglyph{Egravesmall}{E}{grave}{500}
+\setcscbotglyph{Eogoneksmall}{E}{ogonek}{850}
+
+\setcsctopglyph{Gbrevesmall}{G}{breve}{500}
+
+\setcsctopglyph{Iacutesmall}{I}{acute}{500}
+\setcsctopglyph{Icircumflexsmall}{I}{circumflex}{500}
+\setcsctopglyph{Idieresissmall}{I}{dieresis}{500}
+\setcsctopglyph{Idotaccentsmall}{I}{dotaccent}{500}
+\setcsctopglyph{Igravesmall}{I}{grave}{500}
+
+\setcsctopglyph{Lacutesmall}{L}{acute}{250}
+
+\ifareglyphs{Lsmall,quoteright}\then
+ \setglyph{Lcaronsmall}
+ \glyph{Lsmall}{1000}
+ \ifisint{monowidth}\then\Else \movert{-100} \Fi
+ \glyph{quoteright}{\int{smallcapsscale}}
+ \endsetglyph
+ \setleftkerning{Lcaronsmall}{Lsmall}{1000}
+\Fi
+
+\setcsctopglyph{Nacutesmall}{N}{acute}{500}
+\setcsctopglyph{Ncaronsmall}{N}{caron}{500}
+\setcsctopglyph{Ntildesmall}{N}{tilde}{500}
+
+\setcsctopglyph{Oacutesmall}{O}{acute}{500}
+\setcsctopglyph{Ocircumflexsmall}{O}{circumflex}{500}
+\setcsctopglyph{Odieresissmall}{O}{dieresis}{500}
+\setcsctopglyph{Ogravesmall}{O}{grave}{500}
+\setcsctopglyph{Ohungarumlautsmall}{O}{hungarumlaut}{500}
+\setcsctopglyph{Otildesmall}{O}{tilde}{500}
+
+\setcsctopglyph{Racutesmall}{R}{acute}{500}
+\setcsctopglyph{Rcaronsmall}{R}{caron}{500}
+
+\setcsctopglyph{Sacutesmall}{S}{acute}{500}
+\setcsctopglyph{Scaronsmall}{S}{caron}{500}
+\setcscbotglyph{Scedillasmall}{S}{cedilla}{500}
+
+\setcsctopglyph{Tcaronsmall}{T}{caron}{500}
+\setcscbotglyph{Tcedillasmall}{T}{cedilla}{500}
+
+\setcsctopglyph{Uacutesmall}{U}{acute}{500}
+\setcsctopglyph{Ucircumflexsmall}{U}{circumflex}{500}
+\setcsctopglyph{Udieresissmall}{U}{dieresis}{500}
+\setcsctopglyph{Ugravesmall}{U}{grave}{500}
+\setcsctopglyph{Uhungarumlautsmall}{U}{hungarumlaut}{500}
+\setcsctopglyph{Uringsmall}{U}{ring}{500}
+
+\setcsctopglyph{Yacutesmall}{Y}{acute}{500}
+\setcsctopglyph{Ydieresissmall}{Y}{dieresis}{500}
+
+\setcsctopglyph{Zacutesmall}{Z}{acute}{500}
+\setcsctopglyph{Zcaronsmall}{Z}{caron}{500}
+\setcsctopglyph{Zdotaccentsmall}{Z}{dotaccent}{500}
+
+
+\begincomment
+\subsection{Other glyphs that can be built}
+\endcomment
+
+\ifisglyph{Dcroatsmall}\then
+ \setglyph{Dbarsmall}
+ \glyph{Dcroatsmall}{1000}
+ \endsetglyph
+ \setleftrightkerning{Dbarsmall}{Dcroatsmall}{1000}
+\Else\ifisglyph{Ethsmall}\then
+ \setglyph{Dbarsmall}
+ \glyph{Ethsmall}{1000}
+ \endsetglyph
+ \setleftrightkerning{Dbarsmall}{Ethsmall}{1000}
+\Fi\Fi
+
+
+\endmetrics
+
+\texttt{Dbar} and \texttt{Dbarsmall} are old names for this glyph;
+nowadays the standard names are rather \texttt{Dcroat} and
+\texttt{Dcroatsmall}, but using those names throughout would require
+a coordinated change of the ETX files.
+It is probably possible to build a decent \texttt{Dbarsmall} from
+\texttt{Dsmall} and an \texttt{lslashslash} (or the like), similarly
+to the case with \texttt{dbar}, but that would require some
+experimentation.
+
+\section{Changes}
+
+This file was created 2003/01/02--05. It is loosely based on parts
+of \texttt{latin.mtx}. (LH)
+
+2003/02/06: Added setting of \textit{smallcapsscale}, and made
+\texttt{Lcaron} kern like \texttt{L} only on the left (not on the
+right). (LH)
+
+\end{document}
+
+% Copyright 2003 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/lsfake.mtx b/fonts/utilities/fontinst/inputs/latinmtx/lsfake.mtx
new file mode 100644
index 0000000000..9062e376a1
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/lsfake.mtx
@@ -0,0 +1,359 @@
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Lars Hellstr{\"o}m",
+%%% version = "1.923",
+%%% date = "2005-04-15",
+%%% time = "12:13:38 +02:00",
+%%% filename = "lsfake.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It fakes latin smallcaps.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty, lubuild.mtx",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}[2002/03/01]
+\showbranches
+
+\newcommand{\IEint}[1]{\ensuremath{\TypesetIntegerExpression{\int{#1}}}}
+
+\title{Faking smallcaps}
+\author{Lars Hellstr\"om}
+\date{5 January 2003\\Version 1.923}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This file is used to fake small capitals (the \texttt{s} case) for a
+font by shrinking the full capitals (the \texttt{u} case) by a
+certain factor (\IEint{smallcapsscale}). This effectively changes the
+weight of the font so that it becomes lighter, but that effect is
+(for scaling factors near the default value) not too large, even
+though it is quite visible.
+
+Optimal distance between two letters generally grows slower than the
+dimensions of the letters themself. Conversely, to linearly shrink a
+line of text usually places the letters a bit too close. To counteract
+that, the \textbf{Small glyph} commands used below insert a bit of
+extra space (\IEint{smallcapsextraspace}) before and after the actual
+glyph.
+
+Besides the letters, there is also manufactured a special set of
+diacritical marks (skrunk by the same factor as the letters), with
+names such as \texttt{Acutesmall}. These are meant to be used as
+accent characters in a font where the fake small capitals are used as
+small letters, so that clashes within a single character when \TeX's
+\verb|\accent| primitive is used can be less pronounced.
+\textsf{Fontinst} users should however be aware that this is not
+necessarily the right thing to do; some fonts might look better with
+the \texttt{acute} etc.\@ glyphs as \texttt{Acutesmall} and friends.
+
+
+\metrics
+
+\needsfontinstversion{1.910}
+\usemtxpackage{lubuild}
+
+\ProvidesMtxPackage{lsfake}
+
+
+\begincomment
+\section{Some commands and default values}
+
+\endcomment
+
+
+
+% A c&sc glyph is created by shrinking the cap glyph, and adding extra
+% space.
+
+\setcommand\cscglyph#1{
+ \movert{\int{smallcapsextraspace}}
+ \glyph{#1}{\int{smallcapsscale}}
+ \movert{\int{smallcapsextraspace}}
+}
+\begincomment
+A \textbf{Small glyph} is mainly the special case of a \textbf{Glyph}
+when the glyph is scaled
+$\TypesetIntegerExpression{\int{smallcapsscale}}$. This is used to
+fake smallcaps from full capitals. The exact meaning of
+``\textbf{Small glyph} `\#1'\,'' is
+\begin{quotation}\cscglyph{\macroparameter{1}}\end{quotation}
+
+\resetcommand\cscglyph#1{%
+ \Bheading{Small glyph} `\TypesetStringExpression{#1}'%
+}
+\endcomment
+
+\setcommand\fakecscglyph#1#2{
+ \setglyph{#1small}
+ \cscglyph{#2}
+ \setleftrightkerning{#1small}{#2}{\int{smallcapskerning}}
+ \endsetglyph
+}
+% If you supply a definition of \fakecscglyph which has #1medium
+% instead of #1small, then you can use this file to fake medium
+% capitals instead of small capitals.
+
+
+\setint{smallcapsscale}{800}
+\setint{smallcapskerning}{900}
+
+\ifisint{monowidth}\then
+ \setint{smallcapsextraspace}
+ {\half{\scale{\width{x}}{\sub{1000}{\int{smallcapsscale}}}}}
+\Else
+ \setint{smallcapsextraspace}{25}
+\Fi
+
+
+
+\begincomment
+\section{Unaccented letters}
+\endcomment
+
+\fakecscglyph{A}{A}
+\fakecscglyph{AE}{AE}
+\fakecscglyph{B}{B}
+\fakecscglyph{C}{C}
+\fakecscglyph{D}{D}
+\fakecscglyph{Eth}{Eth}
+\fakecscglyph{E}{E}
+\fakecscglyph{F}{F}
+\fakecscglyph{G}{G}
+\fakecscglyph{H}{H}
+\fakecscglyph{I}{I}
+\fakecscglyph{J}{J}
+\fakecscglyph{K}{K}
+\fakecscglyph{Lslash}{Lslash}
+\fakecscglyph{L}{L}
+\fakecscglyph{M}{M}
+\fakecscglyph{N}{N}
+\fakecscglyph{Ng}{Ng}
+\fakecscglyph{O}{O}
+\fakecscglyph{OE}{OE}
+\fakecscglyph{Oslash}{Oslash}
+\fakecscglyph{P}{P}
+\fakecscglyph{Q}{Q}
+\fakecscglyph{R}{R}
+\fakecscglyph{S}{S}
+\fakecscglyph{T}{T}
+\fakecscglyph{Thorn}{Thorn}
+\fakecscglyph{U}{U}
+\fakecscglyph{V}{V}
+\fakecscglyph{W}{W}
+\fakecscglyph{X}{X}
+\fakecscglyph{Y}{Y}
+\fakecscglyph{Z}{Z}
+
+\setglyph{Dbarsmall}
+ \glyph{Ethsmall}{1000}
+ \setleftrightkerning{Dbarsmall}{Ethsmall}{1000}
+\endsetglyph
+
+
+
+
+\begincomment
+\section{Accented letters}
+\endcomment
+
+
+\fakecscglyph{Aacute}{Aacute}
+\fakecscglyph{Abreve}{Abreve}
+\fakecscglyph{Acircumflex}{Acircumflex}
+\fakecscglyph{Adieresis}{Adieresis}
+\fakecscglyph{Agrave}{Agrave}
+\fakecscglyph{Aogonek}{Aogonek}
+\fakecscglyph{Aring}{Aring}
+\fakecscglyph{Atilde}{Atilde}
+\fakecscglyph{Cacute}{Cacute}
+\fakecscglyph{Ccaron}{Ccaron}
+\fakecscglyph{Ccedilla}{Ccedilla}
+\fakecscglyph{Dcaron}{Dcaron}
+\fakecscglyph{Eacute}{Eacute}
+\fakecscglyph{Ecaron}{Ecaron}
+\fakecscglyph{Ecircumflex}{Ecircumflex}
+\fakecscglyph{Edieresis}{Edieresis}
+\fakecscglyph{Egrave}{Egrave}
+\fakecscglyph{Eogonek}{Eogonek}
+\fakecscglyph{Gbreve}{Gbreve}
+\fakecscglyph{Iacute}{Iacute}
+\fakecscglyph{Icircumflex}{Icircumflex}
+\fakecscglyph{Idieresis}{Idieresis}
+\fakecscglyph{Idotaccent}{Idotaccent}
+\fakecscglyph{Igrave}{Igrave}
+\fakecscglyph{Lacute}{Lacute}
+\fakecscglyph{Lcaron}{Lcaron}
+\fakecscglyph{Nacute}{Nacute}
+\fakecscglyph{Ncaron}{Ncaron}
+\fakecscglyph{Ntilde}{Ntilde}
+\fakecscglyph{Oacute}{Oacute}
+\fakecscglyph{Ocircumflex}{Ocircumflex}
+\fakecscglyph{Odieresis}{Odieresis}
+\fakecscglyph{Ograve}{Ograve}
+\fakecscglyph{Ohungarumlaut}{Ohungarumlaut}
+\fakecscglyph{Otilde}{Otilde}
+\fakecscglyph{Racute}{Racute}
+\fakecscglyph{Rcaron}{Rcaron}
+\fakecscglyph{Sacute}{Sacute}
+\fakecscglyph{Scaron}{Scaron}
+\fakecscglyph{Scedilla}{Scedilla}
+\fakecscglyph{Tcaron}{Tcaron}
+\fakecscglyph{Tcedilla}{Tcedilla}
+\fakecscglyph{Uacute}{Uacute}
+\fakecscglyph{Ucircumflex}{Ucircumflex}
+\fakecscglyph{Udieresis}{Udieresis}
+\fakecscglyph{Ugrave}{Ugrave}
+\fakecscglyph{Uhungarumlaut}{Uhungarumlaut}
+\fakecscglyph{Uring}{Uring}
+\fakecscglyph{Yacute}{Yacute}
+\fakecscglyph{Ydieresis}{Ydieresis}
+\fakecscglyph{Zacute}{Zacute}
+\fakecscglyph{Zcaron}{Zcaron}
+\fakecscglyph{Zdotaccent}{Zdotaccent}
+
+
+\begincomment
+\section{Shrunk accents}
+\endcomment
+
+% A c&sc accent is created by moving a shrunk accent up by the
+% difference between a scaled x and a scaled X.
+
+\setcommand\cscaccent#1{
+ \moveup{\scale{\int{xheight}}{\sub{1000}{\int{smallcapsscale}}}}
+ \cscglyph{#1}
+ \moveup{\scale{\int{xheight}}{\sub{\int{smallcapsscale}}{1000}}}
+}
+\begincomment\medskip
+A \textbf{Shrunk accent} is a \textbf{Small glyph} whose vertical
+position has been adjusted so that the
+$\TypesetIntegerExpression{\int{xheight}}$ position of the original
+accent coincides with that of the shrunk accent. Without this
+adjustment, it would instead be the baselines that would coincide,
+but such an accent would be too low. The exact meaning of
+``\textbf{Shrunk accent} `\#1'\,'' is
+\begin{quotation}\cscaccent{\macroparameter{1}}\end{quotation}
+
+\resetcommand\cscaccent#1{%
+ \Bheading{Shrunk accent} `\TypesetStringExpression{#1}'%
+}
+\endcomment
+
+
+\setglyph{Acutesmall}
+ \cscaccent{Acute}
+\endsetglyph
+
+\setglyph{Gravesmall}
+ \cscaccent{Grave}
+\endsetglyph
+
+\setglyph{Circumflexsmall}
+ \cscaccent{Circumflex}
+\endsetglyph
+
+\setglyph{Tildesmall}
+ \cscaccent{Tilde}
+\endsetglyph
+
+\setglyph{Dieresissmall}
+ \cscaccent{Dieresis}
+\endsetglyph
+
+\setglyph{Brevesmall}
+ \cscaccent{Breve}
+\endsetglyph
+
+\setglyph{Dotaccentsmall}
+ \cscaccent{Dotaccent}
+\endsetglyph
+
+\setglyph{Caronsmall}
+ \cscaccent{Caron}
+\endsetglyph
+
+\setglyph{Hungarumlautsmall}
+ \cscaccent{Hungarumlaut}
+\endsetglyph
+
+\setglyph{Ringsmall}
+ \cscaccent{Ring}
+\endsetglyph
+
+\setglyph{Macronsmall}
+ \cscaccent{Macron}
+\endsetglyph
+
+\setglyph{Cedillasmall}
+ \cscglyph{Cedilla}
+\endsetglyph
+
+\setglyph{Ogoneksmall}
+ \cscglyph{Ogonek}
+\endsetglyph
+
+
+
+\endmetrics
+
+\section{Notes}
+
+An important, but rather obscure, difference between what is done by
+this file and what is done by the old \texttt{latin.mtx} concerns the
+manner in which the letters are spaced. In this file, spacing of
+smallcaps is consistently done using the \IEint{smallcapsextraspace}
+parameter, but \texttt{latin.mtx} only uses this mechanism in
+monowidth fonts. For proportional fonts, the default was instead to
+use the \IEint{letterspacing} parameter to space the entire
+font---the same amount for non-faked as for faked letters.
+
+
+\section{Changes}
+
+1999/10/25: Added \verb|\setglyphs| for \texttt{Macronsmall} and
+\texttt{macronsmall}. (LH)
+
+1999/10/25: Simplified definition of \verb|\unfakable|. (UV\&LH)
+Rationale: It is thoroughly confusing if the size of the black box
+created by \verb|\unfakable| depends on the metrics of an unencoded
+glyph that isn't accessible and therefore unavailable for all pratical
+purposes.
+
+2000/10/20: File split off from \texttt{latin.mtx}.
+
+2003/01/02--05: File heavily reorganised. (LH)
+
+2005/04/15: Removed section on \emph{Miscellaneous glyphs}, since
+that should be handled by \texttt{lsmisc.mtx}, and moreover prevented
+the code there from working correctly. (LH) Thanks to Michael Zedler
+for drawing my attention to this error.
+
+
+\end{document}
+
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/lsmisc.mtx b/fonts/utilities/fontinst/inputs/latinmtx/lsmisc.mtx
new file mode 100644
index 0000000000..d30ac97cfb
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/lsmisc.mtx
@@ -0,0 +1,194 @@
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.923",
+%%% date = "2003-03-29",
+%%% time = "16:18:07 +01:00",
+%%% filename = "lsmisc.mtx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It sets some miscellaneous
+%%% glyphs in latin smallcaps.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}[2002/03/01]
+\showbranches
+
+\title{Smallcaps miscellanea}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{5 January 2003\\Version 1.923}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This file sets some miscellaneous smallcaps glyphs, most of which
+serve mainly to complete some family of glyphs whose names are built
+according to some simple pattern. It should work just as well will
+real smallcaps as with faked smallcaps.
+
+\metrics
+
+\needsfontinstversion{1.917}
+
+\ProvidesMtxPackage{lsmisc}
+
+\begincomment
+\section{Miscellaneous smallcaps}
+
+\subsection{Some glyph aliases}
+
+The next few glyphs are usually available (if any smallcaps glyphs are),
+but may come under a name different from that which ETX files expect.
+\endcomment
+
+\ifisglyph{Ismall}\then
+ \setglyph{dotlessIsmall}
+ \glyph{Ismall}{1000}
+ \setleftrightkerning{dotlessIsmall}{Ismall}{1000}
+ \endsetglyph
+\Fi
+
+\ifisglyph{Jsmall}\then
+ \setglyph{dotlessJsmall}
+ \glyph{Jsmall}{1000}
+ \setleftrightkerning{dotlessJsmall}{Jsmall}{1000}
+ \endsetglyph
+\Fi
+
+
+\begincomment
+\subsection{Smallcap ligatures}
+
+Smallcap letters usually do not form ligatures, but many font encodings
+nonetheless reserve slots for them, and in particular many ETX files
+will try to put smallcap ligatures in the ligature slots. Hence there
+is some point in making these glyphs, even though they are only what
+one would get if there was no ligature.
+
+\medskip
+\endcomment
+
+\setint{smallcapsspacing}{0}
+\comment{In case some letterspacing will be applied to the smallcaps,
+ then that amount should also be added between the glyphs below.
+ In most cases however, such spacing should already have been
+ included in the base glyphs, and in that case, $0$ is the correct
+ value.}
+
+\ifisglyph{Fsmall}\then
+
+\setglyph{FFsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Fsmall}}{\int{smallcapsspacing}}}
+ \glyph{Fsmall}{1000}
+\endsetglyph
+\setrightkerning{FFsmall}{Fsmall}{1000}
+
+\ifisglyph{Ismall}\then
+ \setglyph{FIsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Ismall}}{\int{smallcapsspacing}}}
+ \glyph{Ismall}{1000}
+ \endsetglyph
+
+% \setleftkerning{FIsmall}{Fsmall}{1000}
+ \setrightkerning{FIsmall}{Ismall}{1000}
+
+ \setglyph{FFIsmall}
+ \glyph{FFsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Ismall}}{\int{smallcapsspacing}}}
+ \glyph{Ismall}{1000}
+ \endsetglyph
+
+% \setleftkerning{FFIsmall}{Fsmall}{1000}
+ \setrightkerning{FFIsmall}{Ismall}{1000}
+\Fi
+
+\ifisglyph{Lsmall}\then
+ \setglyph{FLsmall}
+ \glyph{Fsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Lsmall}}{\int{smallcapsspacing}}}
+ \glyph{Lsmall}{1000}
+ \endsetglyph
+
+% \setleftkerning{FLsmall}{Fsmall}{1000}
+ \setrightkerning{FLsmall}{Lsmall}{1000}
+
+ \setglyph{FFLsmall}
+ \glyph{FFsmall}{1000}
+ \movert{\add{\kerning{Fsmall}{Lsmall}}{\int{smallcapsspacing}}}
+ \glyph{Lsmall}{1000}
+ \endsetglyph
+
+% \setleftkerning{FFLsmall}{Fsmall}{1000}
+ \setrightkerning{FFLsmall}{Lsmall}{1000}
+\Fi
+\Fi % ifisglyph{Fsmall}
+
+
+\ifareglyphs{Ismall,Jsmall}\then
+ \setglyph{IJsmall}
+ \glyph{Ismall}{1000}
+ \movert{\add{\kerning{Ismall}{Jsmall}}{\int{smallcapsspacing}}}
+ \glyph{Jsmall}{1000}
+ \endsetglyph
+% \setleftkerning{IJsmall}{Ismall}{1000}
+ \setrightkerning{IJsmall}{Jsmall}{1000}
+\Fi
+
+\comment{That the above glyphs only kern on the right is deliberate.
+ Since they are only put in a horizontal list due to a ligature,
+ they will never occur as the right party when kerning is considered.
+ Not having any kerns on the left simplifies reusing ligature slots
+ as right boundary characters. \texttt{SSsmall} is however a
+ different matter, since that is (in a sense, and probably only if
+ some German spelling reforms are ignored) a proper letter.}
+
+\ifisglyph{Ssmall}\then
+ \setglyph{SSsmall}
+ \glyph{Ssmall}{1000}
+ \movert{\add{\kerning{Ssmall}{Ssmall}}{\int{smallcapsspacing}}}
+ \glyph{Ssmall}{1000}
+ \endsetglyph
+ \setleftrightkerning{SSsmall}{Ssmall}{1000}
+\Fi
+
+
+
+\endmetrics
+
+
+\section{Changes}
+
+This file was part of \texttt{latin.mtx} until 2000/10/20. Its was set
+up as a separate file 2003/01/02--05. (LH)
+
+\end{document}
+
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/ltcmds.mtx b/fonts/utilities/fontinst/inputs/latinmtx/ltcmds.mtx
new file mode 100644
index 0000000000..6e9f1455ba
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/ltcmds.mtx
@@ -0,0 +1,305 @@
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth",
+%%% version = "1.915",
+%%% date = "2003-03-29",
+%%% time = "16:07:18 +01:00",
+%%% filename = "ltcmds.mtx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It provides the defaults
+%%% used to install the Latin glyphs.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\title{The file \texttt{ltcmds.mtx}}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{20 October 2000\\Version 1.915}
+
+\showbranches
+
+\begin{document}
+\maketitle
+
+\metrics
+
+\needsfontinstversion{1.917}
+\ProvidesMtxPackage{ltcmds}
+
+\begincomment
+\section{Some commands for making latin glyphs}
+
+\endcomment
+
+% \unfakable is a glyph which can't be faked.
+\setcommand\unfakable#1{
+ \setglyph{#1}
+ \glyphrule{\int{xheight}}{\int{xheight}}
+ \glyphwarning{missing glyph `#1'}
+ \endsetglyph
+}
+\begincomment\medskip
+An \textbf{Unfakable} is a glyph which can't be faked. An
+``\textbf{Unfakable `\#1'}\,'' is equivalent to
+\begin{quotation}\unfakable{\macroparameter{1}}\end{quotation}
+
+\resetcommand\unfakable#1{%
+ \Aheading{Unfakable `\TypesetStringExpression{#1}'}%
+}
+\endcomment
+
+
+\setcommand\topaccent#1#2#3{
+ \push
+ \moveup{\max{0}{\sub{\height{#1}}{\int{xheight}}}}
+ \movert{\add{\sub{\scale{\width{#1}}{#3}}{\half{\width{#2}}}}
+ {\scale{\sub{\height{#1}}{\int{xheight}}}{\int{italicslant}}}}
+ \glyph{#2}{1000}
+ \pop
+ \glyph{#1}{1000}
+}
+\begincomment\medskip
+A \textbf{Top accent} is built by placing the center of the accent at
+the given position along the width of the letter, raised up by the
+difference between the height of the letter and the xheight. This is
+the algorithm used by the \TeX\ \verb|\accent| primitive.
+A ``\textbf{Top accent} `\#1' with `\#2' at \#3'' is equivalent to
+\begin{quotation}
+ \topaccent{\macroparameter{1}}{\macroparameter{2}}{\macroparameter{3}}
+\end{quotation}
+\resetcommand\topaccent#1#2#3{%
+ \Bheading{Top accent} `\TypesetStringExpression{#1}' with
+ `\TypesetStringExpression{#2}' at $\TypesetIntegerExpression{#3}$%
+}
+\endcomment
+
+
+\setcommand\topaccentas#1#2#3#4{
+ \push
+ \moveup{\sub{\height{#4}}{\height{#2}}}
+ \movert{\add{
+ \sub{\scale{\width{#1}}{#3}}{\half{\width{#2}}}
+ }{
+ \scale{\sub{\height{#4}}{\height{#2}}}{\int{italicslant}}
+ }}
+ \glyph{#2}{1000}
+ \pop
+ \glyph{#1}{1000}
+}
+\begincomment\medskip
+A \textbf{Top accent \dots\ as} is built by placing the center of the
+accent at the given position along the width of the letter, raised up
+by the difference between the height of the accent and the height of
+the model glyph. A ``\textbf{Top accent} `\#1' with `\#2' at \#3 as
+\#4'' is equivalent to
+\begin{quotation}
+ \topaccentas{\macroparameter{1}}{\macroparameter{2}}
+ {\macroparameter{3}}{\macroparameter{4}}
+\end{quotation}
+\resetcommand\topaccentas#1#2#3#4{%
+ \Bheading{Top accent} `\TypesetStringExpression{#1}' with
+ `\TypesetStringExpression{#2}' at $\TypesetIntegerExpression{#3}$
+ as `\TypesetStringExpression{#4}'%
+}
+\endcomment
+
+
+\setcommand\botaccent#1#2#3{
+ \push
+ \movert{\sub{\scale{\width{#1}}{#3}}{\half{\width{#2}}}}
+ \glyph{#2}{1000}
+ \pop
+ \glyph{#1}{1000}
+}
+\begincomment\medskip
+A \textbf{Bottom accent} is built by placing the center of the accent at
+the given position along the width of the letter. A ``\textbf{Bottom
+accent} `\#1' with `\#2' at \#3'' is equivalent to
+\begin{quotation}
+ \botaccent{\macroparameter{1}}{\macroparameter{2}}{\macroparameter{3}}
+\end{quotation}
+\resetcommand\botaccent#1#2#3{%
+ \Bheading{Bottom accent} `\TypesetStringExpression{#1}' with
+ `\TypesetStringExpression{#2}' at $\TypesetIntegerExpression{#3}$%
+}
+\endcomment
+
+
+\setcommand\unfakabletopaccent#1{
+ \setglyph{#1}
+ \moveup{\add{\int{xheight}}{50}}
+ \glyphrule{\half{\int{xheight}}}{\half{\int{xheight}}}
+ \glyphwarning{missing glyph `#1'}
+ \moveup{\neg{\add{\int{xheight}}{50}}}
+ \endsetglyph
+}
+\begincomment\medskip
+An \textbf{Unfakable top accent} is the same as an
+\textbf{Unfakable}, except that the rule is smaller and has a more
+accent-like position. An ``\textbf{Unfakable top accent `\#1'}\,''
+is equivalent to
+\begin{quotation}\unfakabletopaccent{\macroparameter{1}}\end{quotation}
+
+\resetcommand\unfakabletopaccent#1{%
+ \Aheading{Unfakable top accent `\TypesetStringExpression{#1}'}%
+}
+\endcomment
+
+
+
+% A c&sc top accent glyph is placed using the small glyphs if
+% available, and otherwise by shrinking the equivalent capital.
+
+\setcommand\csctopaccent#1#2#3{
+% \ifareglyphs{#1small,#2small}\then
+% \topaccent{#1small}{#2small}{#3}
+% \Else
+ \cscglyph{#1#2}
+% \Fi
+}
+
+% A c&sc bot accent glyph is placed using the small glyphs if
+% available, and otherwise by shrinking the equivalent capital.
+
+\setcommand\cscbotaccent#1#2#3{
+% \ifisglyph{#1small}\then
+% \botaccent{#1small}{#2small}{#3}
+% \Else
+ \cscglyph{#1#2}
+% \Fi
+}
+
+% A c&sc accent is created by moving a shrunk accent up by the
+% difference between a scaled x and a scaled X.
+
+\setcommand\cscaccent#1{
+ \moveup{\scale{\int{xheight}}{\sub{1000}{\int{smallcapsscale}}}}
+ \cscglyph{#1}
+ \moveup{\scale{\int{xheight}}{\sub{\int{smallcapsscale}}{1000}}}
+}
+
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\ifisglyph{A}\then
+ \setint{capheight}{\height{A}}
+ \comment{\texttt{t1.etx} has traditionally measured the capheight
+ on \texttt{X}, whereas \texttt{latin.mtx} measured it on
+ \texttt{A}. There is probably no good reason for this
+ difference.}
+\Else\ifisglyph{X}\then
+ \setint{capheight}{\height{X}}
+\Else
+ \setint{capheight}{750}
+\Fi\Fi
+
+\ifisglyph{d}\then
+ \setint{ascender}{\height{d}}
+\Else
+ \setint{ascender}{\int{capheight}}
+\Fi
+
+\ifisint{descender_neg}\then
+ \setint{descender}{\neg{\int{descender_neg}}}
+\Else\ifisglyph{g}\then
+ \setint{descender}{\depth{g}}
+ \comment{Similarly, \texttt{t1.etx} has traditionally measured
+ the descender depth on \texttt{p}, whereas \texttt{latin.mtx}
+ measured it on \texttt{g}.}
+\Else\ifisglyph{p}\then
+ \setint{descender}{\depth{p}}
+\Else
+ \setint{descender}{250}
+\Fi\Fi\Fi
+
+\setint{underlinethickness}{40}
+\setint{visiblespacedepth}{200}
+\setint{visiblespacewidth}{400}
+\setint{visiblespacesurround}{50}
+
+
+\ifisglyph{parenleft}\then
+ \setint{vaxis}{\half{\sub{\height{parenleft}}{\depth{parenleft}}}}
+\Else
+ \setint{vaxis}{\half{\int{xheight}}}
+\Fi
+
+
+\endmetrics
+
+
+
+
+
+\section{Changes}
+
+1999/10/25: Added \verb|\setglyphs| for \texttt{Macronsmall} and
+\texttt{macronsmall}. (LH)
+
+1999/10/25: Simplified definition of \verb|\unfakable|. (UV\&LH)
+Rationale: It is thoroughly confusing if the size of the black box
+created by \verb|\unfakable| depends on the metrics of an unencoded
+glyph that isn't accessible and therefore unavailable for all pratical
+purposes.
+
+2000/10/20--2003/03/15: File split off from \texttt{latin.mtx} and
+reorganised into a separate package. (LH) (It took until the last of
+these dates before all the useless code had been removed.) Also made
+special typeset definitions of many commands and modernized the
+conditionals.
+
+2003/03/15: Made the \verb|\unfakable| a square with side
+$\TypesetIntegerExpression{\int{xheight}}$ and added the
+\verb|\unfakabletopaccent| command. (LH) Rationale: That the glyph is
+unavailable doesn't mean the rule replacing it has to look bad. This
+should make them blend in better with any glyphs that are actually
+available.
+
+2003/03/15: Added \verb|\topaccentas|. (LH) It is based on a command
+|\idotaccent| defined by Walter Schmidt.
+
+2003/03/15: Added calculation of a vertical symmetry axis position
+$\TypesetIntegerExpression{\int{vaxis}}$. (LH) It is based on some
+code by Walter Schmidt.
+
+2004/08/07: Fixed typo in vertical symmetry axis code. (LH)
+
+2005/05/21: Moved default for
+$\TypesetIntegerExpression{\int{capspacing}}$ to \texttt{lubuild.mtx},
+which is where it is used. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/ltpunct.mtx b/fonts/utilities/fontinst/inputs/latinmtx/ltpunct.mtx
new file mode 100644
index 0000000000..223b2005f4
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/ltpunct.mtx
@@ -0,0 +1,247 @@
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.923",
+%%% date = "2003-03-29",
+%%% time = "16:25:58 +01:00",
+%%% filename = "ltpunct.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with
+%%% the fontinst utility. It deals with the
+%%% punctuation characters needed for the most
+%%% common latin font encodings.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}[2002/03/01]
+\showbranches
+
+\title{Latin punctuation}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{7 January 2003\\Version 1.923}
+
+\begin{document}
+\maketitle
+
+
+\metrics
+
+\needsfontinstversion{1.902}
+\usemtxpackage{ltcmds}
+\ProvidesMtxPackage{ltpunct}
+
+\begincomment
+\section{Punctuation}
+
+\subsection{Unfakable characters}
+\endcomment
+
+\unfakable{ampersand}
+\unfakable{asciicircum}
+\unfakable{asciitilde}
+\unfakable{asterisk}
+\unfakable{at}
+\unfakable{backslash}
+\unfakable{bar}
+\unfakable{braceleft}
+\unfakable{braceright}
+\unfakable{bracketleft}
+\unfakable{bracketright}
+\unfakable{colon}
+\unfakable{comma}
+\unfakable{dollar}
+\unfakable{emdash}
+\unfakable{endash}
+\unfakable{equal}
+\unfakable{exclamdown}
+\unfakable{exclam}
+\unfakable{greater}
+\unfakable{guillemotleft}
+\unfakable{guillemotright}
+\unfakable{guilsinglleft}
+\unfakable{guilsinglright}
+\unfakable{hyphen}
+\unfakable{less}
+\unfakable{numbersign}
+\unfakable{parenleft}
+\unfakable{parenright}
+\unfakable{percent}
+\unfakable{period}
+\unfakable{perthousandzero}
+\unfakable{plus}
+\unfakable{questiondown}
+\unfakable{question}
+\unfakable{quotedblbase}
+\unfakable{quotedblleft}
+\unfakable{quotedblright}
+\unfakable{quotedbl}
+\unfakable{quoteleft}
+\unfakable{quoteright}
+\unfakable{section}
+\unfakable{semicolon}
+\unfakable{slash}
+\unfakable{sterling}
+\unfakable{underscore}
+
+\begincomment
+\subsection{Fakable characters}
+\endcomment
+
+\setglyph{space}
+ \ifisglyph{space-not}\then
+ \movert{\width{space-not}}
+ \Else\ifisglyph{i}\then
+ \movert{\width{i}}
+ \Else
+ \movert{333}
+ \Fi\Fi
+\endsetglyph
+
+\setglyph{compwordmark}
+ \glyphrule{0}{\int{xheight}}
+\endsetglyph
+\setint{compwordmark-spacing}{0}
+
+\setglyph{quotesinglbase}
+ \glyph{comma}{1000}
+\endsetglyph
+
+
+\setglyph{visiblespace}
+ \moveup{\neg{\int{visiblespacedepth}}}
+ \movert{\int{visiblespacesurround}}
+ \glyphrule
+ {\int{underlinethickness}}
+ {\int{visiblespacedepth}}
+ \glyphrule
+ {\int{visiblespacewidth}}
+ {\int{underlinethickness}}
+ \glyphrule
+ {\int{underlinethickness}}
+ {\int{visiblespacedepth}}
+ \movert{\int{visiblespacesurround}}
+ \moveup{\int{visiblespacedepth}}
+\endsetglyph
+\setleftrightkerning{visiblespace}{space}{1000}
+\comment{The matter of whether a \texttt{visiblespace} should kern
+ like a \texttt{space} has never been satisfactory resolved.}
+
+
+
+\begincomment
+\subsection{Some special dashes}
+
+\texttt{rangedash} and \texttt{punctdash} are mostly two traditional
+aliases for \texttt{endash} and \texttt{emdash}. The problem with the
+latter two ``original'' glyphs is that they in monowidth fonts
+usually are much shorter than one would expect, whereas the hyphen
+combinations look quite good.
+\endcomment
+
+\setglyph{rangedash}
+ \ifisint{monowidth}\then
+ \glyph{hyphen}{1000}
+ \Else
+ \glyph{endash}{1000}
+ \Fi
+\endsetglyph
+
+\setglyph{punctdash}
+ \ifisint{monowidth}\then
+ \glyph{hyphen}{1000}
+ \glyph{hyphen}{1000}
+ \Else
+ \glyph{emdash}{1000}
+ \Fi
+\endsetglyph
+
+\setglyph{hyphenchar}
+ \glyph{hyphen}{1000}
+ \resetwidth{\half{\width{hyphen}}}
+ \comment{Unlike the normal \texttt{hyphen}, this glyph is only
+ meant to be used at the right end of a line of text. This means
+ it can be a ``hanging hyphen'' which significantly extends
+ outside the character box.}
+ \setleftkerning{hyphenchar}{hyphen}{1000}
+ \comment{\TeX\ does consider kerning (and ligatures) between a
+ hyphenchar and what preceeds it on the line, but there is
+ nothing after the hyphenchar.}
+\endsetglyph
+
+
+\begincomment
+\subsection{More monowidth specialities}
+\endcomment
+
+% only with monospaced fonts. (WaS)
+\ifisint{monowidth}\then
+ \resetglyph{asterisk}
+ \moveup{\sub{\int{vaxis}}{\half{\sub{\height{asterisk}}{\depth{asterisk}}}}}
+ \glyph{asterisk}{1000}
+ \resetdepth{0}
+ \endresetglyph
+\Fi
+
+
+
+\begincomment
+\section{Digits}
+
+The traditional coding here has been that all digits are considered to
+be unfakable. An obvious alternative is however to fake
+\texttt{zerooldstyle} with \texttt{zero}, \texttt{oneoldstyle} with
+\texttt{one}, etc., or vice versa.
+\endcomment
+
+
+\unfakable{zero}
+\unfakable{one}
+\unfakable{two}
+\unfakable{three}
+\unfakable{four}
+\unfakable{five}
+\unfakable{six}
+\unfakable{seven}
+\unfakable{eight}
+\unfakable{nine}
+
+\unfakable{zerooldstyle}
+\unfakable{oneoldstyle}
+\unfakable{twooldstyle}
+\unfakable{threeoldstyle}
+\unfakable{fouroldstyle}
+\unfakable{fiveoldstyle}
+\unfakable{sixoldstyle}
+\unfakable{sevenoldstyle}
+\unfakable{eightoldstyle}
+\unfakable{nineoldstyle}
+
+
+
+\endmetrics
+
+
+\section{Changes}
+
+The original version of this file was created in February 2003,
+although it is based on code from the traditional \texttt{latin.mtx}.
+The changes that have been made after that are as follows.
+
+2003/03/15: The asterisk in monowidth fonts is vertically centered,
+to make it more useful for computer listings. Suggested by Walter
+Schmidt.
+
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/lubuild.mtx b/fonts/utilities/fontinst/inputs/latinmtx/lubuild.mtx
new file mode 100644
index 0000000000..c9603104bb
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/lubuild.mtx
@@ -0,0 +1,656 @@
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.923",
+%%% date = "2003-03-29",
+%%% time = "16:12:42 +01:00",
+%%% filename = "lubuild.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It builds upper case latin
+%%% letters.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}[2002/03/01]
+\showbranches
+
+\title{Building upper case}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{4 January 2002\\Version 1.923}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This file builds upper case (full capitals, \texttt{u} case) latin
+letters, or more precisely, it makes sure that a set of glyphs is
+defined that cover the upper case letters used in European latin scripts.
+Even that is a slight exaggeration, because there are a couple of
+``exotic'' letters that are missing, but most people never try to use
+those anyway.
+
+For the glyphs set in this file to look anything like the letters they
+are supposed to be, it is necessary that the glyphs for unaccented
+letters and for accents already exist and look like they are supposed
+to. In that case, the commands below will manufacture decent
+substitutes for the missing glyphs by composing letters and accents.
+If some of these base glyphs are missing, then a ``missing glyph''
+substitute will be supplied for them. Such substitutes will show up in
+print as black squares, and most DVI drivers will emit a warning when
+producing them.
+
+The most common case encountered is that almost all unaccented letters
+and accents are available, but only about half of the accented
+letters. Then for the other half, quite decent substitutes are made,
+but a few letters only show up as ``missing glyph'' boxes.
+
+
+\metrics
+
+\needsfontinstversion{1.910}
+\usemtxpackage{ltcmds}
+
+\ProvidesMtxPackage{lubuild}
+
+\begincomment
+\section{Base upper case glyphs}
+
+The following commands make sure all the unaccented letter glyphs and
+accent glyphs are set. If any of them are not already set at this
+point, then those will be set to ``missing glyph'' boxes.
+
+\subsection{Letters}
+\endcomment
+
+\unfakable{A}
+\unfakable{AE}
+\unfakable{B}
+\unfakable{C}
+\unfakable{D}
+\unfakable{E}
+\unfakable{Eng}
+\unfakable{Eth}
+\unfakable{F}
+\unfakable{G}
+\unfakable{H}
+\unfakable{I}
+\unfakable{J}
+\unfakable{K}
+\unfakable{L}
+\unfakable{M}
+\unfakable{N}
+\unfakable{O}
+\unfakable{OE}
+\unfakable{Oslash}
+\unfakable{P}
+\unfakable{Q}
+\unfakable{R}
+\unfakable{S}
+\unfakable{T}
+\unfakable{Thorn}
+\unfakable{U}
+\unfakable{V}
+\unfakable{W}
+\unfakable{X}
+\unfakable{Y}
+\unfakable{Z}
+
+\begincomment
+\subsection{Accents}
+
+The accents on designed full capitals are often different from the
+accents on lower case letters: strokes are generally at a smaller
+angle to the horizontal, so that the accent is compressed in the
+vertical direction. Most fonts do not provide those accents as
+separate characters, but one should nonetheless try to use them
+whenever possible. The standard names appear (see for example the
+\emph{Adobe Glyph List}) to be the same as for the
+normal accents, but with the first letter in upper case.
+When these accents are not available, it is anyway
+possible to make do with the ordinary accents.
+\endcomment
+
+
+\unfakabletopaccent{grave}
+\unfakabletopaccent{acute}
+\unfakabletopaccent{circumflex}
+\unfakabletopaccent{tilde}
+\unfakabletopaccent{dieresis}
+\unfakabletopaccent{hungarumlaut}
+\unfakabletopaccent{ring}
+\unfakabletopaccent{caron}
+\unfakabletopaccent{breve}
+\unfakabletopaccent{macron}
+\unfakabletopaccent{dotaccent}
+\unfakable{cedilla}
+\unfakable{ogonek}
+\unfakable{quoteright}
+\unfakable{lslashslash}
+
+
+\setglyph{Acute}
+ \glyph{acute}{1000}
+\endsetglyph
+
+\setglyph{Grave}
+ \glyph{grave}{1000}
+\endsetglyph
+
+\setglyph{Circumflex}
+ \glyph{circumflex}{1000}
+\endsetglyph
+
+\setglyph{Tilde}
+ \glyph{tilde}{1000}
+\endsetglyph
+
+\setglyph{Dieresis}
+ \glyph{dieresis}{1000}
+\endsetglyph
+
+\setglyph{Breve}
+ \glyph{breve}{1000}
+\endsetglyph
+
+\setglyph{Dotaccent}
+ \glyph{dotaccent}{1000}
+\endsetglyph
+
+\setglyph{Caron}
+ \glyph{caron}{1000}
+\endsetglyph
+
+\setglyph{Hungarumlaut}
+ \glyph{hungarumlaut}{1000}
+\endsetglyph
+
+\setglyph{Ring}
+ \glyph{ring}{1000}
+\endsetglyph
+
+\setglyph{Macron}
+ \glyph{macron}{1000}
+\endsetglyph
+
+\setglyph{Cedilla}
+ \glyph{cedilla}{1000}
+\endsetglyph
+
+\setglyph{Ogonek}
+ \glyph{ogonek}{1000}
+\endsetglyph
+
+\begincomment
+Note that the \TeX\ accenting algorithm assumes that accents are
+positioned correctly for being placed on a letter whose height is the
+x-height. It might happen that a font with special upper case accents,
+made for use with some other typesetting engine, instead has these
+glyphs positioned correctly for being placed on a capital. In such a
+case, one would first have to adjust the accent positions before they
+can be used.
+\endcomment
+
+
+\begincomment
+\section{Building accented letters}
+\endcomment
+
+
+\setglyph{Aacute}
+ \topaccent{A}{Acute}{500}
+\endsetglyph
+
+\setglyph{Abreve}
+ \topaccent{A}{Breve}{500}
+\endsetglyph
+
+\setglyph{Acircumflex}
+ \topaccent{A}{Circumflex}{500}
+\endsetglyph
+
+\setglyph{Adieresis}
+ \topaccent{A}{Dieresis}{500}
+\endsetglyph
+
+\setglyph{Agrave}
+ \topaccent{A}{Grave}{500}
+\endsetglyph
+
+\setglyph{Aogonek}
+ \botaccent{A}{Ogonek}{900}
+\endsetglyph
+
+\setglyph{Aring}
+ \topaccent{A}{Ring}{500}
+\endsetglyph
+
+\setglyph{Atilde}
+ \topaccent{A}{Tilde}{500}
+\endsetglyph
+
+\setglyph{Cacute}
+ \topaccent{C}{Acute}{500}
+\endsetglyph
+
+\setglyph{Ccaron}
+ \topaccent{C}{Caron}{500}
+\endsetglyph
+
+\setglyph{Ccedilla}
+ \botaccent{C}{Cedilla}{500}
+\endsetglyph
+
+\setglyph{Dcaron}
+ \topaccent{D}{Caron}{450}
+\endsetglyph
+
+\setglyph{Eacute}
+ \topaccent{E}{Acute}{500}
+\endsetglyph
+
+\setglyph{Ecaron}
+ \topaccent{E}{Caron}{500}
+\endsetglyph
+
+\setglyph{Ecircumflex}
+ \topaccent{E}{Circumflex}{500}
+\endsetglyph
+
+\setglyph{Edieresis}
+ \topaccent{E}{Dieresis}{500}
+\endsetglyph
+
+\setglyph{Egrave}
+ \topaccent{E}{Grave}{500}
+\endsetglyph
+
+\setglyph{Eogonek}
+ \botaccent{E}{Ogonek}{850}
+\endsetglyph
+
+\setglyph{Gbreve}
+ \topaccent{G}{Breve}{500}
+\endsetglyph
+
+\setglyph{Iacute}
+ \topaccent{I}{Acute}{500}
+\endsetglyph
+
+\setglyph{Icircumflex}
+ \topaccent{I}{Circumflex}{500}
+\endsetglyph
+
+\setglyph{Idieresis}
+ \topaccent{I}{Dieresis}{500}
+\endsetglyph
+
+\setglyph{Idotaccent}
+ \topaccent{I}{Dotaccent}{500}
+\endsetglyph
+
+\setglyph{Igrave}
+ \topaccent{I}{Grave}{500}
+\endsetglyph
+
+\setglyph{Lacute}
+ \topaccent{L}{Acute}{250}
+\endsetglyph
+
+\setglyph{Lcaron}
+ \glyph{L}{1000}
+ \ifisint{monowidth}\then\Else
+ \movert{-200}
+ \Fi
+ \glyph{quoteright}{1000}
+\endsetglyph
+
+\setglyph{Nacute}
+ \topaccent{N}{Acute}{500}
+\endsetglyph
+
+\setglyph{Ncaron}
+ \topaccent{N}{Caron}{500}
+\endsetglyph
+
+\setglyph{Ntilde}
+ \topaccent{N}{Tilde}{500}
+\endsetglyph
+
+\setglyph{Oacute}
+ \topaccent{O}{Acute}{500}
+\endsetglyph
+
+\setglyph{Ocircumflex}
+ \topaccent{O}{Circumflex}{500}
+\endsetglyph
+
+\setglyph{Odieresis}
+ \topaccent{O}{Dieresis}{500}
+\endsetglyph
+
+\setglyph{Ograve}
+ \topaccent{O}{Grave}{500}
+\endsetglyph
+
+\setglyph{Ohungarumlaut}
+ \topaccent{O}{Hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Otilde}
+ \topaccent{O}{Tilde}{500}
+\endsetglyph
+
+\setglyph{Racute}
+ \topaccent{R}{Acute}{500}
+\endsetglyph
+
+\setglyph{Rcaron}
+ \topaccent{R}{Caron}{500}
+\endsetglyph
+
+\setglyph{Sacute}
+ \topaccent{S}{Acute}{500}
+\endsetglyph
+
+\setglyph{Scaron}
+ \topaccent{S}{Caron}{500}
+\endsetglyph
+
+\setglyph{Scedilla}
+ \botaccent{S}{Cedilla}{500}
+\endsetglyph
+
+\setglyph{Tcaron}
+ \topaccent{T}{Caron}{500}
+\endsetglyph
+
+\setglyph{Tcedilla}
+ \botaccent{T}{Cedilla}{500}
+\endsetglyph
+
+\setglyph{Uacute}
+ \topaccent{U}{Acute}{500}
+\endsetglyph
+
+\setglyph{Ucircumflex}
+ \topaccent{U}{Circumflex}{500}
+\endsetglyph
+
+\setglyph{Udieresis}
+ \topaccent{U}{Dieresis}{500}
+\endsetglyph
+
+\setglyph{Ugrave}
+ \topaccent{U}{Grave}{500}
+\endsetglyph
+
+\setglyph{Uhungarumlaut}
+ \topaccent{U}{Hungarumlaut}{500}
+\endsetglyph
+
+\setglyph{Uring}
+ \topaccent{U}{Ring}{500}
+\endsetglyph
+
+\setglyph{Yacute}
+ \topaccent{Y}{Acute}{500}
+\endsetglyph
+
+\setglyph{Ydieresis}
+ \topaccent{Y}{Dieresis}{500}
+\endsetglyph
+
+\setglyph{Zacute}
+ \topaccent{Z}{Acute}{500}
+\endsetglyph
+
+\setglyph{Zcaron}
+ \topaccent{Z}{Caron}{500}
+\endsetglyph
+
+\setglyph{Zdotaccent}
+ \topaccent{Z}{Dotaccent}{500}
+\endsetglyph
+
+
+\begincomment
+\section{Other glyphs that can be built}
+\endcomment
+
+\setglyph{Lslash}
+ \glyph{lslashslash}{1000}
+ \movert{\kerning{lslashslash}{L}}
+ \glyph{L}{1000}
+\endsetglyph
+
+\setglyph{Ng}
+ \glyph{Eng}{1000}
+ \comment{This is simply an alias.}
+\endsetglyph
+
+\setglyph{dotlessI}
+ \glyph{I}{1000}
+ \comment{This simplifies making all-caps fonts.}
+\endsetglyph
+
+\setglyph{dotlessJ}
+ \glyph{J}{1000}
+ \comment{This simplifies making all-caps fonts.}
+\endsetglyph
+
+
+\setglyph{IJ}
+ \glyph{I}{1000}
+ \movert{\kerning{I}{J}}
+ \glyph{J}{1000}
+\endsetglyph
+
+\setglyph{SS}
+ \glyph{S}{1000}
+ \movert{\kerning{S}{S}}
+ \glyph{S}{1000}
+\endsetglyph
+
+
+\begincomment
+\subsection{All-caps spaced digraphs}
+
+These glyphs are combinations of upper case letters in which the
+distances between them have been increased by
+$\TypesetIntegerExpression{\int{capspacing}}$. These are intended for
+use in all-caps fonts that are made with a nonzero
+$\TypesetIntegerExpression{\int{letterspacing}}$ equal to the
+$\TypesetIntegerExpression{\int{capspacing}}$.
+\endcomment
+
+\ifisint{letterspacing}\then
+ \setint{capspacing}{\int{letterspacing}}
+\Else
+ \setint{capspacing}{0}
+\Fi
+
+
+\setglyph{FFspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{F}}{\int{capspacing}}}
+ \glyph{F}{1000}
+\endsetglyph
+\setleftrightkerning{FFspaced}{F}{1000}
+\setleftrightkerning{Dbar}{Eth}{1000}
+
+
+\setglyph{FIspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{I}}{\int{capspacing}}}
+ \glyph{I}{1000}
+\endsetglyph
+\setleftkerning{FIspaced}{F}{1000}
+\setrightkerning{FIspaced}{I}{1000}
+
+\setglyph{FLspaced}
+ \glyph{F}{1000}
+ \movert{\add{\kerning{F}{L}}{\int{capspacing}}}
+ \glyph{L}{1000}
+\endsetglyph
+\setleftkerning{FLspaced}{F}{1000}
+\setrightkerning{FLspaced}{L}{1000}
+
+\setglyph{FFIspaced}
+ \glyph{FFspaced}{1000}
+ \movert{\add{\kerning{FFspaced}{I}}{\int{capspacing}}}
+ \glyph{I}{1000}
+\endsetglyph
+\setleftkerning{FFIspaced}{F}{1000}
+\setrightkerning{FFIspaced}{I}{1000}
+
+\setglyph{FFLspaced}
+ \glyph{FFspaced}{1000}
+ \movert{\add{\kerning{FFspaced}{L}}{\int{capspacing}}}
+ \glyph{L}{1000}
+\endsetglyph
+\setleftkerning{FFLspaced}{F}{1000}
+\setrightkerning{FFLspaced}{L}{1000}
+
+\setglyph{IJspaced}
+ \glyph{I}{1000}
+ \movert{\add{\kerning{I}{J}}{\int{capspacing}}}
+ \glyph{J}{1000}
+\endsetglyph
+\setleftkerning{IJspaced}{I}{1000}
+\setrightkerning{IJspaced}{J}{1000}
+
+\setglyph{SSspaced}
+ \glyph{S}{1000}
+ \movert{\add{\kerning{S}{S}}{\int{capspacing}}}
+ \glyph{S}{1000}
+\endsetglyph
+\setleftrightkerning{SSspaced}{S}{1000}
+
+
+
+
+\begincomment
+\section{All-caps kerning}
+\endcomment
+
+\setleftrightkerning{dotlessI}{I}{1000}
+\setleftrightkerning{dotlessJ}{J}{1000}
+
+
+\setleftrightkerning{Aacute}{A}{1000}
+\setleftrightkerning{Abreve}{A}{1000}
+\setleftrightkerning{Acircumflex}{A}{1000}
+\setleftrightkerning{Adieresis}{A}{1000}
+\setleftrightkerning{Agrave}{A}{1000}
+\setleftrightkerning{Aogonek}{A}{1000}
+\setleftrightkerning{Aring}{A}{1000}
+\setleftrightkerning{Atilde}{A}{1000}
+
+\setleftrightkerning{Cacute}{C}{1000}
+\setleftrightkerning{Ccaron}{C}{1000}
+\setleftrightkerning{Ccedilla}{C}{1000}
+
+\setleftrightkerning{Dcaron}{D}{1000}
+
+\setleftrightkerning{Eacute}{E}{1000}
+\setleftrightkerning{Ecaron}{E}{1000}
+\setleftrightkerning{Ecircumflex}{E}{1000}
+\setleftrightkerning{Edieresis}{E}{1000}
+\setleftrightkerning{Egrave}{E}{1000}
+\setleftrightkerning{Eogonek}{E}{1000}
+
+\setleftrightkerning{Gbreve}{G}{1000}
+
+\setleftkerning{IJ}{I}{1000}
+
+\setleftrightkerning{Iacute}{I}{1000}
+\setleftrightkerning{Icircumflex}{I}{1000}
+\setleftrightkerning{Idieresis}{I}{1000}
+\setleftrightkerning{Idotaccent}{I}{1000}
+\setleftrightkerning{Igrave}{I}{1000}
+
+\setrightkerning{IJ}{J}{1000}
+
+\setleftrightkerning{Lacute}{L}{1000}
+\setleftrightkerning{Lslash}{L}{1000}
+\setleftkerning{Lcaron}{L}{1000}
+
+\setleftrightkerning{Nacute}{N}{1000}
+\setleftrightkerning{Ncaron}{N}{1000}
+\setleftrightkerning{Ntilde}{N}{1000}
+
+\setleftkerning{Ng}{N}{1000}
+\setrightkerning{Ng}{J}{1000}
+
+\setleftrightkerning{Oacute}{O}{1000}
+\setleftrightkerning{Ocircumflex}{O}{1000}
+\setleftrightkerning{Odieresis}{O}{1000}
+\setleftrightkerning{Ograve}{O}{1000}
+\setleftrightkerning{Ohungarumlaut}{O}{1000}
+\setleftrightkerning{Oslash}{O}{1000}
+\setleftrightkerning{Otilde}{O}{1000}
+
+\setleftrightkerning{Rcaron}{R}{1000}
+\setleftrightkerning{Racute}{R}{1000}
+
+\setleftrightkerning{SS}{S}{1000}
+\setleftrightkerning{Sacute}{S}{1000}
+\setleftrightkerning{Scaron}{S}{1000}
+\setleftrightkerning{Scedilla}{S}{1000}
+
+\setleftrightkerning{Tcaron}{T}{1000}
+\setleftrightkerning{Tcedilla}{T}{1000}
+
+\setleftrightkerning{Uacute}{U}{1000}
+\setleftrightkerning{Ucircumflex}{U}{1000}
+\setleftrightkerning{Udieresis}{U}{1000}
+\setleftrightkerning{Ugrave}{U}{1000}
+\setleftrightkerning{Uhungarumlaut}{U}{1000}
+\setleftrightkerning{Uring}{U}{1000}
+
+\setleftrightkerning{Yacute}{Y}{1000}
+\setleftrightkerning{Ydieresis}{Y}{1000}
+
+\setleftrightkerning{Zacute}{Z}{1000}
+\setleftrightkerning{Zcaron}{Z}{1000}
+\setleftrightkerning{Zdotaccent}{Z}{1000}
+
+
+
+\endmetrics
+
+
+\section{Changes}
+
+The original version of this file was created in February 2003,
+although it is based on code from the traditional \texttt{latin.mtx}.
+The changes that have been made after that are as follows.
+
+2003/03/15: Using \verb|\unfakabletopaccent| for the accent
+characters. This should change the appearence of accented letters
+built using such a character from ``a black square'' to ``a letter
+with a black square above''. Neither is satisfactory, but the latter
+conveys more information. (LH)
+
+2003/03/29: Added some code (from \texttt{latin.mtx}) for all-caps
+glyphs that had been forgotten. (LH)
+
+2005/05/21: Improved default for
+$\TypesetIntegerExpression{\int{capspacing}}$. (LH)
+
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/newlatin.mtx b/fonts/utilities/fontinst/inputs/latinmtx/newlatin.mtx
new file mode 100644
index 0000000000..083dfe259b
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/newlatin.mtx
@@ -0,0 +1,190 @@
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.924",
+%%% date = "2003-03-29",
+%%% time = "16:28:28 +01:00",
+%%% filename = "newlatin.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It provides the defaults
+%%% used to install the Latin glyphs.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}[2003/02/09]
+\showbranches
+
+\title{The \textsf{fontinst} latin glyphs, modernized}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{16 February 2003}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document lists commands for the \textsf{fontinst} utility that
+will generate the glyphs needed to make a set of latin fonts. The
+intent is that this file should replace the old \texttt{latin.mtx}
+as the generic ``fixer'' for latin fonts---doing a decent job both
+when proper smallcaps is available and when it is not.
+
+Most of the actual commands are however to be found in other files,
+which this file uses. This modular design is meant to simplify tuning
+the process, for example by adjusting the accent positions to better
+suit particular fonts.
+
+
+\metrics
+
+\needsfontinstversion{1.924}
+
+\usemtxpackage{llbuild}
+
+\usemtxpackage{lubuild}
+
+\ifoption{nosc}\then \Else
+
+\usemtxpackage{lsbuild}
+\usemtxpackage{lsfake}
+\usemtxpackage{lsmisc}
+
+\Fi
+
+\usemtxpackage{ltpunct}
+
+\begincomment
+\section{\texttt{OT1} oddities}
+
+One important, although also deprecated, encoding for latin text
+fonts is the \texttt{OT1} encoding. Besides being a text font
+encoding, that makes double service as a math font encoding, and
+this imposes some extra restrictions.
+
+\subsection{Greek capitals}
+\endcomment
+
+\usemtxpackage{ltcmds}
+
+\unfakable{Gamma}
+\unfakable{Delta}
+\unfakable{Theta}
+\unfakable{Lambda}
+\unfakable{Xi}
+\unfakable{Pi}
+\unfakable{Sigma}
+\unfakable{Upsilon}
+\unfakable{Upsilon1}
+\unfakable{Phi}
+\unfakable{Psi}
+\unfakable{Omega}
+
+\begincomment
+\subsection{Math accents}
+
+\TeX's math accent-positioning requires accents to have zero depth.
+\endcomment
+
+\foreach(accent){grave,acute,circumflex,tilde,dieresis,hungarumlaut,%
+ ring,caron,breve,macron,dotaccent}
+ \ifisglyph{\str{accent}}\then
+ \resetglyph{\str{accent}}
+ \glyph{\str{accent}}{1000}
+ \resetdepth{0}
+ \endresetglyph
+ \Fi
+\endfor(accent)
+
+% \setcommand\zerodepth#1{
+% \ifisglyph{#1}\then
+% \resetglyph{#1}
+% \glyph{#1}{1000}
+% \resetdepth{0}
+% \endresetglyph
+% \Fi
+% }
+% \zerodepth{grave}
+% \zerodepth{acute}
+% \zerodepth{circumflex}
+% \zerodepth{tilde}
+% \zerodepth{dieresis}
+% \zerodepth{hungarumlaut}
+% \zerodepth{ring}
+% \zerodepth{caron}
+% \zerodepth{breve}
+% \zerodepth{macron}
+% \zerodepth{dotaccent}
+
+
+\begincomment
+\subsection{The ring accent}
+
+The \texttt{OT1} definition of \r{A} (that does not make use of
+\verb|\accent|) assumes that the ring accent glyph has the same width
+as \texttt{A}. Hence this special \texttt{ringfitted} glyph.
+\endcomment
+
+\setglyph{ringfitted}
+ \movert{\half{\sub{\width{A}}{\width{ring}}}}
+ \glyph{ring}{1000}
+ \movert{\otherhalf{\sub{\width{A}}{\width{ring}}}}
+\endsetglyph
+
+
+\begincomment
+\section{\texttt{T1} oddities}
+
+Even the modern \texttt{T1} encoding has some odd traits. The most
+notable is that the guillemet glyphs \texttt{guillemotleft} and
+\texttt{guillemotright} can be formed as ligatures from a pair of
+\texttt{less}s and \texttt{greater}s respectively. Then to get the
+right kerning on the left side of the two former glyphs, the two
+latter must kern like them!
+\endcomment
+
+\setleftkerning{less}{guillemotleft}{1000}
+\setleftkerning{greater}{guillemotright}{1000}
+
+
+\endmetrics
+
+
+\section{Changes}
+
+The original version of this file was created in February 2003,
+although it is based on code from the traditional \texttt{latin.mtx}.
+The changes that have been made after that are listed below, but see
+also the files containing the individual metric packages for any
+changes made to those files.
+
+
+\end{document}
+
+
+%
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999, 2000, 2003 the fontinst maintenance team and
+% any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/resetsc.mtx b/fonts/utilities/fontinst/inputs/latinmtx/resetsc.mtx
new file mode 100644
index 0000000000..445e737525
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/resetsc.mtx
@@ -0,0 +1,166 @@
+% Copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Ulrik Vieth",
+%%% version = "1.927",
+%%% date = "13 April 2004",
+%%% time = "23:01:07 CET",
+%%% filename = "resetsc.mtx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "07130 161 332 5005",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, raw, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a metrics file, for use with the
+%%% fontinst utility. It recodes glyph names
+%%% for small capitals read from AFM files
+%%% to glyph names with a `small' suffix.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\title{The \texttt{resetsc.mtx} metrics file}
+\author{Ulrik Vieth}
+\date{16 November 1999 \\
+Version 1.910}
+
+\begin{document}
+\maketitle
+
+This document describes the \texttt{resetsc.mtx} metrics file, which is
+used to recode raw glyph names for small capitals to glyph names with
+a `small' suffix.
+
+\metrics
+
+\setcommand\smallcapsglyph#1#2{
+ \ifisglyph{#2}\then
+ \setglyph{#1}\glyph{#2}{1000}
+ \endsetglyph
+ \fi
+}
+
+\setcommand\smallcapskerning#1#2{
+ \ifisglyph{#2}\then
+ \setleftrightkerning{#1}{#2}{1000}
+ \fi
+}
+
+% Renaming small caps glyphs.
+
+\smallcapsglyph{Asmall}{a}
+\smallcapsglyph{Bsmall}{b}
+\smallcapsglyph{Csmall}{c}
+\smallcapsglyph{Dsmall}{d}
+\smallcapsglyph{Esmall}{e}
+\smallcapsglyph{Fsmall}{f}
+\smallcapsglyph{Gsmall}{g}
+\smallcapsglyph{Hsmall}{h}
+\smallcapsglyph{Ismall}{i}
+\smallcapsglyph{Jsmall}{j}
+\smallcapsglyph{Ksmall}{k}
+\smallcapsglyph{Lsmall}{l}
+\smallcapsglyph{Msmall}{m}
+\smallcapsglyph{Nsmall}{n}
+\smallcapsglyph{Osmall}{o}
+\smallcapsglyph{Psmall}{p}
+\smallcapsglyph{Qsmall}{q}
+\smallcapsglyph{Rsmall}{r}
+\smallcapsglyph{Ssmall}{s}
+\smallcapsglyph{Tsmall}{t}
+\smallcapsglyph{Usmall}{u}
+\smallcapsglyph{Vsmall}{v}
+\smallcapsglyph{Wsmall}{w}
+\smallcapsglyph{Xsmall}{x}
+\smallcapsglyph{Ysmall}{y}
+\smallcapsglyph{Zsmall}{z}
+
+\smallcapsglyph{Lslashsmall}{lslash}
+\smallcapsglyph{Scaronsmall}{scaron}
+\smallcapsglyph{Zcaronsmall}{zcaron}
+
+\smallcapsglyph{Agravesmall}{agrave}
+\smallcapsglyph{Aacutesmall}{aacute}
+\smallcapsglyph{Acircumflexsmall}{acircumflex}
+\smallcapsglyph{Atildesmall}{atilde}
+\smallcapsglyph{Adieresissmall}{adieresis}
+\smallcapsglyph{Aringsmall}{aring}
+\smallcapsglyph{AEsmall}{ae}
+\smallcapsglyph{Ccedillasmall}{ccedilla}
+\smallcapsglyph{Egravesmall}{egrave}
+\smallcapsglyph{Eacutesmall}{eacute}
+\smallcapsglyph{Ecircumflexsmall}{ecircumflex}
+\smallcapsglyph{Edieresissmall}{edieresis}
+\smallcapsglyph{Igravesmall}{igrave}
+\smallcapsglyph{Iacutesmall}{iacute}
+\smallcapsglyph{Icircumflexsmall}{icircumflex}
+\smallcapsglyph{Idieresissmall}{idieresis}
+\smallcapsglyph{Ethsmall}{eth}
+\smallcapsglyph{Ntildesmall}{ntilde}
+\smallcapsglyph{Ogravesmall}{ograve}
+\smallcapsglyph{Oacutesmall}{oacute}
+\smallcapsglyph{Ocircumflexsmall}{ocircumflex}
+\smallcapsglyph{Otildesmall}{otilde}
+\smallcapsglyph{Odieresissmall}{odieresis}
+\smallcapsglyph{OEsmall}{oe}
+\smallcapsglyph{Oslashsmall}{oslash}
+\smallcapsglyph{Ugravesmall}{ugrave}
+\smallcapsglyph{Uacutesmall}{uacute}
+\smallcapsglyph{Ucircumflexsmall}{ucircumflex}
+\smallcapsglyph{Udieresissmall}{udieresis}
+\smallcapsglyph{Yacutesmall}{yacute}
+\smallcapsglyph{Thornsmall}{thorn}
+\smallcapsglyph{Ydieresissmall}{ydieresis}
+
+% Renaming small caps kern pairs.
+
+\smallcapskerning{Asmall}{a}
+\smallcapskerning{Bsmall}{b}
+\smallcapskerning{Csmall}{c}
+\smallcapskerning{Dsmall}{d}
+\smallcapskerning{Esmall}{e}
+\smallcapskerning{Fsmall}{f}
+\smallcapskerning{Gsmall}{g}
+\smallcapskerning{Hsmall}{h}
+\smallcapskerning{Ismall}{i}
+\smallcapskerning{Jsmall}{j}
+\smallcapskerning{Ksmall}{k}
+\smallcapskerning{Lsmall}{l}
+\smallcapskerning{Msmall}{m}
+\smallcapskerning{Nsmall}{n}
+\smallcapskerning{Osmall}{o}
+\smallcapskerning{Psmall}{p}
+\smallcapskerning{Qsmall}{q}
+\smallcapskerning{Rsmall}{r}
+\smallcapskerning{Ssmall}{s}
+\smallcapskerning{Tsmall}{t}
+\smallcapskerning{Usmall}{u}
+\smallcapskerning{Vsmall}{v}
+\smallcapskerning{Wsmall}{w}
+\smallcapskerning{Xsmall}{x}
+\smallcapskerning{Ysmall}{y}
+\smallcapskerning{Zsmall}{z}
+
+\endmetrics
+
+\section{Changes}
+
+2004/04/13: Fixed typo (\texttt{Xsmall} instead of \texttt{Ysmall}).
+(LH)
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/latinmtx/unsetalf.mtx b/fonts/utilities/fontinst/inputs/latinmtx/unsetalf.mtx
new file mode 100644
index 0000000000..cc6b792de0
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/latinmtx/unsetalf.mtx
@@ -0,0 +1,114 @@
+% Copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Ulrik Vieth",
+%%% version = "1.910",
+%%% date = "16 November 1999",
+%%% time = "23:02:32 CET",
+%%% filename = "unsetalf.mtx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "64950 114 264 2737",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, raw, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a metrics file, for use with the
+%%% fontinst utility. It makes glyph names
+%%% for alphabetic glyphs undefined.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\title{The \texttt{unsetalf.mtx} metrics file}
+\author{Ulrik Vieth}
+\date{16 November 1999 \\
+Version 1.910}
+
+\begin{document}
+\maketitle
+
+This document describes the \texttt{unsetalf.mtx} metrics file, which is
+used to make glyph names for alphabetic glyphs undefined.
+
+\metrics
+
+\unsetint{xheight}
+\unsetint{ascender}
+\unsetint{descender}
+\unsetint{capheight}
+\unsetint{italicslant}
+
+\unsetglyph{A}
+\unsetglyph{B}
+\unsetglyph{C}
+\unsetglyph{D}
+\unsetglyph{E}
+\unsetglyph{F}
+\unsetglyph{G}
+\unsetglyph{H}
+\unsetglyph{I}
+\unsetglyph{J}
+\unsetglyph{K}
+\unsetglyph{L}
+\unsetglyph{M}
+\unsetglyph{N}
+\unsetglyph{O}
+\unsetglyph{P}
+\unsetglyph{Q}
+\unsetglyph{R}
+\unsetglyph{S}
+\unsetglyph{T}
+\unsetglyph{U}
+\unsetglyph{V}
+\unsetglyph{W}
+\unsetglyph{X}
+\unsetglyph{Y}
+\unsetglyph{Z}
+
+\unsetglyph{a}
+\unsetglyph{b}
+\unsetglyph{c}
+\unsetglyph{d}
+\unsetglyph{e}
+\unsetglyph{f}
+\unsetglyph{g}
+\unsetglyph{h}
+\unsetglyph{i}
+\unsetglyph{j}
+\unsetglyph{k}
+\unsetglyph{l}
+\unsetglyph{m}
+\unsetglyph{n}
+\unsetglyph{o}
+\unsetglyph{p}
+\unsetglyph{q}
+\unsetglyph{r}
+\unsetglyph{s}
+\unsetglyph{t}
+\unsetglyph{u}
+\unsetglyph{v}
+\unsetglyph{w}
+\unsetglyph{x}
+\unsetglyph{y}
+\unsetglyph{z}
+
+\unsetglyph{dotlessi}
+\unsetglyph{dotlessj}
+
+\endmetrics
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathetx/euex.etx b/fonts/utilities/fontinst/inputs/mathetx/euex.etx
new file mode 100644
index 0000000000..1d33e7ac4b
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/euex.etx
@@ -0,0 +1,164 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Matthias Clasen and Ulrik Vieth",
+%%% version = "1.915",
+%%% date = "26 October 2000",
+%%% time = "11:28:00 CEST",
+%%% filename = "euex.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/index.html",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the Euler extension encoding as a TeX
+%%% font encoding file, for use with the fontinst
+%%% utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\useexamplefont{euex10}
+\showbranches
+
+\title{The AMS Euler Extension encoding vector}
+\author{Matthias Clasen and Ulrik Vieth}
+
+\begin{document}
+\maketitle
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{EULER SUBSTITUTIONS ONLY}
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\comment{The following font dimensions are taken from \texttt{euex10}.}
+
+\setint{defaultrulethickness}{40}
+\setint{bigopspacing1}{111}
+\setint{bigopspacing2}{167}
+\setint{bigopspacing3}{200}
+\setint{bigopspacing4}{600}
+\setint{bigopspacing5}{100}
+
+\begincomment
+\section{Default font dimensions}
+\endcomment
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{0} % interword space
+\setint{fontdimen(3)}{0} % interword stretch
+\setint{fontdimen(4)}{0} % interword shrink
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\setint{fontdimen(7)}{0} % extra space after .
+
+\setint{fontdimen(8)}{\int{defaultrulethickness}} % default rule thickness
+\setint{fontdimen(9)}{\int{bigopspacing1}} % bigopspacing 1
+\setint{fontdimen(10)}{\int{bigopspacing2}} % bigopspacing 2
+\setint{fontdimen(11)}{\int{bigopspacing3}} % bigopspacing 3
+\setint{fontdimen(12)}{\int{bigopspacing4}} % bigopspacing 4
+\setint{fontdimen(13)}{\int{bigopspacing5}} % bigopspacing 5
+
+
+\begincomment
+\section{The encoding}
+\endcomment
+
+\setslotcomment{The symbol `\slotexample'.}
+
+\nextslot{8}
+\setslot{braceleftbig}\endsetslot
+\setslot{bracerightbig}\endsetslot
+\setslot{braceleftBig}\endsetslot
+\setslot{bracerightBig}\endsetslot
+\setslot{braceleftbigg}\endsetslot
+\setslot{bracerightbigg}\endsetslot
+\setslot{braceleftBigg}\endsetslot
+\setslot{bracerightBigg}\endsetslot
+
+\nextslot{24}
+\setslot{arrowlefttophalf}\endsetslot
+\setslot{arrowleftbothalf}\endsetslot
+\setslot{arrowrighttophalf}\endsetslot
+\setslot{arrowrightbothalf}\endsetslot
+
+\nextslot{32}
+\setslot{arrowleft}\endsetslot
+\setslot{arrowright}\endsetslot
+\setslot{arrowup}\endsetslot
+\setslot{arrowdown}\endsetslot
+\setslot{arrowboth}\endsetslot
+\setslot{arrownortheast}\endsetslot
+\setslot{arrowsoutheast}\endsetslot
+
+\nextslot{40}
+\setslot{arrowdblleft}\endsetslot
+\setslot{arrowdblright}\endsetslot
+\setslot{arrowdblup}\endsetslot
+\setslot{arrowdbldown}\endsetslot
+\setslot{arrowdblboth}\endsetslot
+\setslot{arrownorthwest}\endsetslot
+\setslot{arrowsouthwest}\endsetslot
+
+\nextslot{49}
+\setslot{infinity}\endsetslot
+
+\nextslot{56}
+\setslot{bracelefttp}\endsetslot
+\setslot{bracerighttp}\endsetslot
+\setslot{braceleftbt}\endsetslot
+\setslot{bracerightbt}\endsetslot
+\setslot{braceleftmid}\endsetslot
+\setslot{bracerightmid}\endsetslot
+\setslot{braceex}\endsetslot
+
+\nextslot{72}
+\setslot{contintegraltext}\endsetslot
+\setslot{contintegraldisplay}\endsetslot
+
+\nextslot{80}
+\setslot{summationtext}\endsetslot
+\setslot{producttext}\endsetslot
+\setslot{integraltext}\endsetslot
+
+\nextslot{88}
+\setslot{summationdisplay}\endsetslot
+\setslot{productdisplay}\endsetslot
+\setslot{integraldisplay}\endsetslot
+
+\nextslot{96}
+\setslot{coproducttext}\endsetslot
+\setslot{coproductdisplay}\endsetslot
+
+\nextslot{122}
+\setslot{bracehtipdownleft}\endsetslot
+\setslot{bracehtipdownright}\endsetslot
+\setslot{bracehtipupleft}\endsetslot
+\setslot{bracehtipupright}\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+12 October 2000, v1\,1.915: Introduced intermediate variables for
+fontdimens 8--13. Updated markup. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathetx/eufrak.etx b/fonts/utilities/fontinst/inputs/mathetx/eufrak.etx
new file mode 100644
index 0000000000..edc289e80d
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/eufrak.etx
@@ -0,0 +1,238 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Matthias Clasen and Ulrik Vieth",
+%%% version = "1.915",
+%%% date = "26 October 2000",
+%%% time = "11:29:00 CEST",
+%%% filename = "eufrak.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/index.html",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the Euler Fraktur encoding as a TeX
+%%% font encoding file, for use with the fontinst
+%%% utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\useexamplefont{eufm10}
+\showbranches
+
+\title{The AMS Euler Fraktur encoding vector (\texttt{OT1}-subset)}
+\author{Matthias Clasen and Ulrik Vieth}
+
+\begin{document}
+\maketitle
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{TEX TEXT SUBSET}
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\comment{The following font dimensions are taken from \texttt{eufm10}.}
+
+\setint{num1}{378}
+\setint{num2}{270}
+\setint{num3}{297}
+\setint{denom1}{378}
+\setint{denom2}{162}
+\setint{sup1}{405}
+\setint{sup2}{378}
+\setint{sup3}{324}
+\setint{sub1}{189}
+\setint{sub2}{243}
+\setint{supdrop}{405}
+\setint{subdrop}{27}
+\setint{delim1}{2198}
+\setint{delim2}{1000}
+\setint{axisheight}{257}
+
+\begincomment
+\section{Font dimensions}
+\endcomment
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{0} % interword space
+\setint{fontdimen(3)}{0} % interword stretch
+\setint{fontdimen(4)}{0} % interword shrink
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\setint{fontdimen(7)}{0} % extra space after .
+
+\setint{fontdimen(8)}{\int{num1}} % num 1
+\setint{fontdimen(9)}{\int{num2}} % num 2
+\setint{fontdimen(10)}{\int{num3}} % num 3
+\setint{fontdimen(11)}{\int{denom1}} % denom 1
+\setint{fontdimen(12)}{\int{denom2}} % denom 2
+\setint{fontdimen(13)}{\int{sup1}} % sup 1
+\setint{fontdimen(14)}{\int{sup2}} % sup 2
+\setint{fontdimen(15)}{\int{sup3}} % sup 3
+\setint{fontdimen(16)}{\int{sub1}} % sub 1
+\setint{fontdimen(17)}{\int{sub2}} % sub 2
+\setint{fontdimen(18)}{\int{supdrop}} % supdrop
+\setint{fontdimen(19)}{\int{subdrop}} % subdrop
+\setint{fontdimen(20)}{\int{delim1}} % delim 1
+\setint{fontdimen(21)}{\int{delim2}} % delim 2
+\setint{fontdimen(22)}{\int{axisheight}} % math axis height
+
+
+\begincomment
+\section{The encoding}
+\endcomment
+
+\setslotcomment{The alternate letter `\slotexample'.}
+
+\setslot{d1frak}\endsetslot
+\setslot{d2frak}\endsetslot
+\setslot{f1frak}\endsetslot
+\setslot{f2frak}\endsetslot
+\setslot{g1frak}\endsetslot
+\setslot{t1frak}\endsetslot
+\setslot{t2frak}\endsetslot
+\setslot{u1frak}\endsetslot
+
+\resetslotcomment{The symbol `\slotexample'.}
+
+\nextslot{18}
+\setslot{quoteleft}\endsetslot
+\setslot{quoteright}\endsetslot
+
+\nextslot{33}
+\setslot{exclam}\endsetslot
+\skipslots{4}
+\setslot{ampersand}\endsetslot
+\setslot{quotesingle}\endsetslot
+\setslot{parenleft}\endsetslot
+\setslot{parenright}\endsetslot
+\setslot{asterisk}\endsetslot
+\setslot{plus}\endsetslot
+\setslot{comma}\endsetslot
+\setslot{minus}\endsetslot
+\setslot{period}\endsetslot
+\setslot{slash}\endsetslot
+
+\resetslotcomment{The Fraktur numeral `\slotexample'.}
+
+\nextslot{48}
+\setslot{zerofrak}\endsetslot
+\setslot{onefrak}\endsetslot
+\setslot{twofrak}\endsetslot
+\setslot{threefrak}\endsetslot
+\setslot{fourfrak}\endsetslot
+\setslot{fivefrak}\endsetslot
+\setslot{sixfrak}\endsetslot
+\setslot{sevenfrak}\endsetslot
+\setslot{eightfrak}\endsetslot
+\setslot{ninefrak}\endsetslot
+
+\resetslotcomment{The symbol `\slotexample'.}
+
+\setslot{colon}\endsetslot
+\setslot{semicolon}\endsetslot
+\skipslots{1}
+\setslot{equal}\endsetslot
+\skipslots{1}
+\setslot{question}\endsetslot
+
+\resetslotcomment{The Fraktur letter `\slotexample'.}
+
+\nextslot{65}
+\setslot{Afrak}\endsetslot
+\setslot{Bfrak}\endsetslot
+\setslot{Cfrak}\endsetslot
+\setslot{Dfrak}\endsetslot
+\setslot{Efrak}\endsetslot
+\setslot{Ffrak}\endsetslot
+\setslot{Gfrak}\endsetslot
+\setslot{Hfrak}\endsetslot
+\setslot{Ifrak}\endsetslot
+\setslot{Jfrak}\endsetslot
+\setslot{Kfrak}\endsetslot
+\setslot{Lfrak}\endsetslot
+\setslot{Mfrak}\endsetslot
+\setslot{Nfrak}\endsetslot
+\setslot{Ofrak}\endsetslot
+\setslot{Pfrak}\endsetslot
+\setslot{Qfrak}\endsetslot
+\setslot{Rfrak}\endsetslot
+\setslot{Sfrak}\endsetslot
+\setslot{Tfrak}\endsetslot
+\setslot{Ufrak}\endsetslot
+\setslot{Vfrak}\endsetslot
+\setslot{Wfrak}\endsetslot
+\setslot{Xfrak}\endsetslot
+\setslot{Yfrak}\endsetslot
+\setslot{Zfrak}\endsetslot
+
+\resetslotcomment{The symbol `\slotexample'.}
+
+\setslot{bracketleft}\endsetslot
+\skipslots{1}
+\setslot{bracketright}\endsetslot
+\setslot{asciicircum}\endsetslot
+
+\resetslotcomment{The Fraktur letter `\slotexample'.}
+
+\nextslot{97}
+\setslot{afrak}\endsetslot
+\setslot{bfrak}\endsetslot
+\setslot{cfrak}\endsetslot
+\setslot{dfrak}\endsetslot
+\setslot{efrak}\endsetslot
+\setslot{ffrak}\endsetslot
+\setslot{gfrak}\endsetslot
+\setslot{hfrak}\endsetslot
+\setslot{ifrak}\endsetslot
+\setslot{jfrak}\endsetslot
+\setslot{kfrak}\endsetslot
+\setslot{lfrak}\endsetslot
+\setslot{mfrak}\endsetslot
+\setslot{nfrak}\endsetslot
+\setslot{ofrak}\endsetslot
+\setslot{pfrak}\endsetslot
+\setslot{qfrak}\endsetslot
+\setslot{rfrak}\endsetslot
+\setslot{sfrak}\endsetslot
+\setslot{tfrak}\endsetslot
+\setslot{ufrak}\endsetslot
+\setslot{vfrak}\endsetslot
+\setslot{wfrak}\endsetslot
+\setslot{xfrak}\endsetslot
+\setslot{yfrak}\endsetslot
+\setslot{zfrak}\endsetslot
+
+\resetslotcomment{The symbol `\slotexample'.}
+
+\skipslots{2}
+\setslot{quotedbl}\endsetslot
+\skipslots{1}
+\setslot{onealtfrak}\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+12 October 2000, v\,1.915: Introduced intermediate variables for fontdimens
+8--22. Updated markup. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathetx/eurm.etx b/fonts/utilities/fontinst/inputs/mathetx/eurm.etx
new file mode 100644
index 0000000000..063137ad6f
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/eurm.etx
@@ -0,0 +1,239 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Matthias Clasen and Ulrik Vieth",
+%%% version = "1.915",
+%%% date = "26 October 2000",
+%%% time = "11:29:00 CEST",
+%%% filename = "eurm.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/index.html",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the Euler Roman encoding as a TeX
+%%% font encoding file, for use with the fontinst
+%%% utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\useexamplefont{eurm10}
+\showbranches
+
+\title{The AMS Euler Roman encoding vector (\texttt{OML}-subset)}
+\author{Matthias Clasen and Ulrik Vieth}
+
+\begin{document}
+\maketitle
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{TEX MATH ITALIC SUBSET}
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\comment{The following font dimensions are taken from \texttt{eurm10}.}
+
+\setint{num1}{378}
+\setint{num2}{270}
+\setint{num3}{297}
+\setint{denom1}{378}
+\setint{denom2}{162}
+\setint{sup1}{405}
+\setint{sup2}{378}
+\setint{sup3}{324}
+\setint{sub1}{189}
+\setint{sub2}{243}
+\setint{supdrop}{405}
+\setint{subdrop}{27}
+\setint{delim1}{2198}
+\setint{delim2}{1000}
+\setint{axisheight}{257}
+
+\begincomment
+\section{Font dimensions}
+\endcomment
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{0} % interword space
+\setint{fontdimen(3)}{0} % interword stretch
+\setint{fontdimen(4)}{0} % interword shrink
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\setint{fontdimen(7)}{0} % extra space after .
+
+\setint{fontdimen(8)}{\int{num1}} % num 1
+\setint{fontdimen(9)}{\int{num2}} % num 2
+\setint{fontdimen(10)}{\int{num3}} % num 3
+\setint{fontdimen(11)}{\int{denom1}} % denom 1
+\setint{fontdimen(12)}{\int{denom2}} % denom 2
+\setint{fontdimen(13)}{\int{sup1}} % sup 1
+\setint{fontdimen(14)}{\int{sup2}} % sup 2
+\setint{fontdimen(15)}{\int{sup3}} % sup 3
+\setint{fontdimen(16)}{\int{sub1}} % sub 1
+\setint{fontdimen(17)}{\int{sub2}} % sub 2
+\setint{fontdimen(18)}{\int{supdrop}} % supdrop
+\setint{fontdimen(19)}{\int{subdrop}} % subdrop
+\setint{fontdimen(20)}{\int{delim1}} % delim 1
+\setint{fontdimen(21)}{\int{delim2}} % delim 2
+\setint{fontdimen(22)}{\int{axisheight}} % math axis height
+
+
+\begincomment
+\section{The encoding}
+\endcomment
+
+\setslotcomment{The Greek letter `\slotexample'.}
+\setslot{Gammaupright}\endsetslot
+\setslot{Deltaupright}\endsetslot
+\setslot{Thetaupright}\endsetslot
+\setslot{Lambdaupright}\endsetslot
+\setslot{Xiupright}\endsetslot
+\setslot{Piupright}\endsetslot
+\setslot{Sigmaupright}\endsetslot
+\setslot{Upsilonupright}\endsetslot
+\setslot{Phiupright}\endsetslot
+\setslot{Psiupright}\endsetslot
+\setslot{Omegaupright}\endsetslot
+\setslot{alphaupright}\endsetslot
+\setslot{betaupright}\endsetslot
+\setslot{gammaupright}\endsetslot
+\setslot{deltaupright}\endsetslot
+\setslot{epsilonupright}\endsetslot
+\setslot{zetaupright}\endsetslot
+\setslot{etaupright}\endsetslot
+\setslot{thetaupright}\endsetslot
+\setslot{iotaupright}\endsetslot
+\setslot{kappaupright}\endsetslot
+\setslot{lambdaupright}\endsetslot
+\setslot{muupright}\endsetslot
+\setslot{nuupright}\endsetslot
+\setslot{xiupright}\endsetslot
+\setslot{piupright}\endsetslot
+\setslot{rhoupright}\endsetslot
+\setslot{sigmaupright}\endsetslot
+\setslot{tauupright}\endsetslot
+\setslot{upsilonupright}\endsetslot
+\setslot{phiupright}\endsetslot
+\setslot{chiupright}\endsetslot
+\setslot{psiupright}\endsetslot
+\setslot{omegaupright}\endsetslot
+\setslot{epsilon1upright}\endsetslot
+\setslot{theta1upright}\endsetslot
+\setslot{pi1upright}\endsetslot
+\skipslots{2}
+\setslot{phi1upright}\endsetslot
+
+\nextslot{48}
+
+\resetslotcomment{The numeral `\slotexample'.}
+\setslot{zeroupright}\endsetslot
+\setslot{oneupright}\endsetslot
+\setslot{twoupright}\endsetslot
+\setslot{threeupright}\endsetslot
+\setslot{fourupright}\endsetslot
+\setslot{fiveupright}\endsetslot
+\setslot{sixupright}\endsetslot
+\setslot{sevenupright}\endsetslot
+\setslot{eightupright}\endsetslot
+\setslot{nineupright}\endsetslot
+
+\resetslotcomment{The symbol `\slotexample'.}
+\setslot{period}\endsetslot
+\setslot{comma}\endsetslot
+\setslot{less}\endsetslot
+\setslot{slash}\endsetslot
+\setslot{greater}\endsetslot
+\skipslots{1}
+\setslot{partialdiffupright}\endsetslot
+
+\nextslot{65}
+
+\resetslotcomment{The letter `\slotexample'.}
+\setslot{A}\endsetslot
+\setslot{B}\endsetslot
+\setslot{C}\endsetslot
+\setslot{D}\endsetslot
+\setslot{E}\endsetslot
+\setslot{F}\endsetslot
+\setslot{G}\endsetslot
+\setslot{H}\endsetslot
+\setslot{I}\endsetslot
+\setslot{J}\endsetslot
+\setslot{K}\endsetslot
+\setslot{L}\endsetslot
+\setslot{M}\endsetslot
+\setslot{N}\endsetslot
+\setslot{O}\endsetslot
+\setslot{P}\endsetslot
+\setslot{Q}\endsetslot
+\setslot{R}\endsetslot
+\setslot{S}\endsetslot
+\setslot{T}\endsetslot
+\setslot{U}\endsetslot
+\setslot{V}\endsetslot
+\setslot{W}\endsetslot
+\setslot{X}\endsetslot
+\setslot{Y}\endsetslot
+\setslot{Z}\endsetslot
+\skipslots{5}
+
+\setslot{lscript}\endsetslot
+\setslot{a}\endsetslot
+\setslot{b}\endsetslot
+\setslot{c}\endsetslot
+\setslot{d}\endsetslot
+\setslot{e}\endsetslot
+\setslot{f}\endsetslot
+\setslot{g}\endsetslot
+\setslot{h}\endsetslot
+\setslot{i}\endsetslot
+\setslot{j}\endsetslot
+\setslot{k}\endsetslot
+\setslot{l}\endsetslot
+\setslot{m}\endsetslot
+\setslot{n}\endsetslot
+\setslot{o}\endsetslot
+\setslot{p}\endsetslot
+\setslot{q}\endsetslot
+\setslot{r}\endsetslot
+\setslot{s}\endsetslot
+\setslot{t}\endsetslot
+\setslot{u}\endsetslot
+\setslot{v}\endsetslot
+\setslot{w}\endsetslot
+\setslot{x}\endsetslot
+\setslot{y}\endsetslot
+\setslot{z}\endsetslot
+\setslot{dotlessi}\endsetslot
+\setslot{dotlessj}\endsetslot
+\setslot{weierstrass}\endsetslot
+
+\nextslot{127}
+\setslot{skewchar}\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+12 October 2000, v\,1.915: Introduced intermediate variables for fontdimens
+8--22. Updated markup. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathetx/euscr.etx b/fonts/utilities/fontinst/inputs/mathetx/euscr.etx
new file mode 100644
index 0000000000..c5811f646c
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/euscr.etx
@@ -0,0 +1,171 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Matthias Clasen and Ulrik Vieth",
+%%% version = "1.915",
+%%% date = "26 October 2000",
+%%% time = "11:30:00 CEST",
+%%% filename = "euscr.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/index.html",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the Euler Script encoding as a TeX
+%%% font encoding file, for use with the fontinst
+%%% utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\useexamplefont{eusm10}
+\showbranches
+
+\title{The AMS Euler Script encoding vector (\texttt{OMS}-subset)}
+\author{Matthias Clasen and Ulrik Vieth}
+
+\begin{document}
+\maketitle
+
+\encoding
+
+\needsfontinstversion{1.909}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{TEX MATH SYMBOLS SUBSET}
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\comment{The following font dimensions are taken from \texttt{eusm10}.}
+
+\setint{num1}{378}
+\setint{num2}{270}
+\setint{num3}{297}
+\setint{denom1}{378}
+\setint{denom2}{162}
+\setint{sup1}{405}
+\setint{sup2}{378}
+\setint{sup3}{324}
+\setint{sub1}{189}
+\setint{sub2}{243}
+\setint{supdrop}{405}
+\setint{subdrop}{27}
+\setint{delim1}{2198}
+\setint{delim2}{1000}
+\setint{axisheight}{257}
+
+\begincomment
+\section{Font dimensions}
+\endcomment
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{0} % interword space
+\setint{fontdimen(3)}{0} % interword stretch
+\setint{fontdimen(4)}{0} % interword shrink
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\setint{fontdimen(7)}{0} % extra space after .
+
+\setint{fontdimen(8)}{\int{num1}} % num 1
+\setint{fontdimen(9)}{\int{num2}} % num 2
+\setint{fontdimen(10)}{\int{num3}} % num 3
+\setint{fontdimen(11)}{\int{denom1}} % denom 1
+\setint{fontdimen(12)}{\int{denom2}} % denom 2
+\setint{fontdimen(13)}{\int{sup1}} % sup 1
+\setint{fontdimen(14)}{\int{sup2}} % sup 2
+\setint{fontdimen(15)}{\int{sup3}} % sup 3
+\setint{fontdimen(16)}{\int{sub1}} % sub 1
+\setint{fontdimen(17)}{\int{sub2}} % sub 2
+\setint{fontdimen(18)}{\int{supdrop}} % supdrop
+\setint{fontdimen(19)}{\int{subdrop}} % subdrop
+\setint{fontdimen(20)}{\int{delim1}} % delim 1
+\setint{fontdimen(21)}{\int{delim2}} % delim 2
+\setint{fontdimen(22)}{\int{axisheight}} % math axis height
+
+
+\begincomment
+\section{The encoding}
+\endcomment
+
+\setslotcomment{The symbol `\slotexample'.}
+
+\nextslot{24}
+\setslot{similar}\endsetslot
+
+\nextslot{48}
+\setslot{skewchar}\endsetslot
+
+\nextslot{58}
+\setslot{logicalnot}\endsetslot
+\nextslot{60}
+\setslot{Rfraktur}\endsetslot
+\setslot{Ifraktur}\endsetslot
+\nextslot{64}
+\setslot{aleph}\endsetslot
+
+\setslotcomment{The script letter `\slotexample'.}
+
+\nextslot{65}
+\setslot{Acal}\endsetslot
+\setslot{Bcal}\endsetslot
+\setslot{Ccal}\endsetslot
+\setslot{Dcal}\endsetslot
+\setslot{Ecal}\endsetslot
+\setslot{Fcal}\endsetslot
+\setslot{Gcal}\endsetslot
+\setslot{Hcal}\endsetslot
+\setslot{Ical}\endsetslot
+\setslot{Jcal}\endsetslot
+\setslot{Kcal}\endsetslot
+\setslot{Lcal}\endsetslot
+\setslot{Mcal}\endsetslot
+\setslot{Ncal}\endsetslot
+\setslot{Ocal}\endsetslot
+\setslot{Pcal}\endsetslot
+\setslot{Qcal}\endsetslot
+\setslot{Rcal}\endsetslot
+\setslot{Scal}\endsetslot
+\setslot{Tcal}\endsetslot
+\setslot{Ucal}\endsetslot
+\setslot{Vcal}\endsetslot
+\setslot{Wcal}\endsetslot
+\setslot{Xcal}\endsetslot
+\setslot{Ycal}\endsetslot
+\setslot{Zcal}\endsetslot
+
+\setslotcomment{The symbol `\slotexample'.}
+
+\nextslot{94}
+\setslot{logicaland}\endsetslot
+\setslot{logicalor}\endsetslot
+\nextslot{102}
+\setslot{braceleft}\endsetslot
+\setslot{braceright}\endsetslot
+\nextslot{106}
+\setslot{bar}\endsetslot
+\nextslot{110}
+\setslot{backslash}\endsetslot
+\nextslot{120}
+\setslot{section}\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+12 October 2000, v\,1.915: Introduced intermediate variables for fontdimens
+8--22. Updated markup. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathetx/msam.etx b/fonts/utilities/fontinst/inputs/mathetx/msam.etx
new file mode 100644
index 0000000000..89a38dedfb
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/msam.etx
@@ -0,0 +1,636 @@
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}
+\usepackage{amssymb}
+\usepackage{multicol}
+
+\title{The AMS \texttt{msam} symbol encoding vector}
+\author{Mattias Clasen, modifications by Ulrik Vieth}
+
+\begin{document}
+\onecolumn
+
+\maketitle
+
+\section{Introduction}
+
+This document describes the AMS \texttt{msam} symbol encoding, which
+is unfortunately called \texttt{TEX MATH SYMBOLS} in the \texttt{.tfm}
+files although it has nothing to do with the encoding of
+\texttt{cmsy}. To overcome this difficulty use e.g.\ \texttt{msam10}
+like
+\begin{quote}
+ \textellipsis
+ \verb|,\metrics\generalpltomtx{msam10}{msam10}{pl}{msam},msam10,|%
+ \textellipsis
+\end{quote}
+in the \textit{file list} argument of \verb+\installfont+, or generate
+the \texttt{.mtx} file at some point before the \verb|\installfont|
+command.
+
+Most glyph names were revised to match the names used in the
+\texttt{.afm} files of the BlueSky Type~1 fonts, except for a few
+cases where those glyph names were found to be confusing or
+misleading.
+
+\showbranches
+
+\begin{multicols}{2}
+
+\encoding
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{AMS Math Symbols, Part A}
+
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\comment{The following font dimension defaults are taken from
+\texttt{cmsy10}.}
+
+\setint{num1}{677}
+\setint{num2}{394}
+\setint{num3}{444}
+\setint{denom1}{686}
+\setint{denom2}{345}
+\setint{sup1}{413}
+\setint{sup2}{363}
+\setint{sup3}{289}
+\setint{sub1}{150}
+\setint{sub2}{247}
+\setint{supdrop}{386}
+\setint{subdrop}{50}
+\setint{delim1}{2390}
+\setint{delim2}{1010}
+\setint{axisheight}{250}
+
+
+\begincomment
+\section{Default font dimensions}
+\endcomment
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{0} % interword space
+\setint{fontdimen(3)}{0} % interword stretch
+\setint{fontdimen(4)}{0} % interword shrink
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\setint{fontdimen(7)}{0} % extra space after .
+
+\setint{fontdimen(8)}{\int{num1}} % num 1
+\setint{fontdimen(9)}{\int{num2}} % num 2
+\setint{fontdimen(10)}{\int{num3}} % num 3
+\setint{fontdimen(11)}{\int{denom1}} % denom 1
+\setint{fontdimen(12)}{\int{denom2}} % denom 2
+\setint{fontdimen(13)}{\int{sup1}} % sup 1
+\setint{fontdimen(14)}{\int{sup2}} % sup 2
+\setint{fontdimen(15)}{\int{sup3}} % sup 3
+\setint{fontdimen(16)}{\int{sub1}} % sub 1
+\setint{fontdimen(17)}{\int{sub2}} % sub 2
+\setint{fontdimen(18)}{\int{supdrop}} % supdrop
+\setint{fontdimen(19)}{\int{subdrop}} % subdrop
+\setint{fontdimen(20)}{\int{delim1}} % delim 1
+\setint{fontdimen(21)}{\int{delim2}} % delim 2
+\setint{fontdimen(22)}{\int{axisheight}} % math axis height
+
+
+\begincomment
+\section{The encoding}
+There are 128 glyphs in this encoding.
+\endcomment
+
+\setslot{squaredot}
+ \comment{The symbol `$\boxdot$'.}
+\endsetslot
+
+\setslot{squareplus}
+ \comment{The symbol `$\boxplus$'.}
+\endsetslot
+
+\setslot{squaremultiply}
+ \comment{The symbol `$\boxtimes$'.}
+\endsetslot
+
+\setslot{square}
+ \comment{The symbol `$\square$'.}
+\endsetslot
+
+\setslot{squaresolid}
+ \comment{The symbol `$\blacksquare$'.}
+\endsetslot
+
+\setslot{squaresmallsolid}
+ \comment{The symbol `$\centerdot$'.}
+\endsetslot
+
+\setslot{lozenge}
+ \comment{The symbol `$\lozenge$'.}
+\endsetslot
+
+\setslot{lozengesolid}
+ \comment{The symbol `$\blacklozenge$'.}
+\endsetslot
+
+\setslot{clockwise}
+ \comment{The symbol `$\circlearrowright$'.}
+\endsetslot
+
+\setslot{anticlockwise}
+ \comment{The symbol `$\circlearrowleft$'.}
+\endsetslot
+
+\setslot{harpoonleftright}
+ \comment{The symbol `$\rightleftharpoons$'.}
+\endsetslot
+
+\setslot{harpoonrightleft}
+ \comment{The symbol `$\leftrightharpoons$'.}
+\endsetslot
+
+\setslot{squareminus}
+ \comment{The symbol `$\boxminus$'.}
+\endsetslot
+
+\setslot{forces}
+ \comment{The symbol `$\Vdash$'.}
+\endsetslot
+
+\setslot{forcesbar}
+ \comment{The symbol `$\Vvdash$'.}
+\endsetslot
+
+\setslot{satisfies}
+ \comment{The symbol `$\vDash$'.}
+\endsetslot
+
+\setslot{dblarrowheadright}
+ \comment{The symbol `$\twoheadrightarrow$'.}
+\endsetslot
+
+\setslot{dblarrowheadleft}
+ \comment{The symbol `$\twoheadleftarrow$'.}
+\endsetslot
+
+\setslot{dblarrowleft}
+ \comment{The symbol `$\leftleftarrows$'.}
+\endsetslot
+
+\setslot{dblarrowright}
+ \comment{The symbol `$\rightrightarrows$'.}
+\endsetslot
+
+\setslot{dblarrowup}
+ \comment{The symbol `$\upuparrows$'.}
+\endsetslot
+
+\setslot{dblarrowdown}
+ \comment{The symbol `$\downdownarrows$'.}
+\endsetslot
+
+\setslot{harpoonupright}
+ \comment{The symbol `$\upharpoonright$'.}
+\endsetslot
+
+\setslot{harpoondownright}
+ \comment{The symbol `$\downharpoonright$'.}
+\endsetslot
+
+\setslot{harpoonupleft}
+ \comment{The symbol `$\upharpoonleft$'.}
+\endsetslot
+
+\setslot{harpoondownleft}
+ \comment{The symbol `$\downharpoonleft$'.}
+\endsetslot
+
+\setslot{arrowtailright}
+ \comment{The symbol `$\rightarrowtail$'.}
+\endsetslot
+
+\setslot{arrowtailleft}
+ \comment{The symbol `$\leftarrowtail$'.}
+\endsetslot
+
+\setslot{arrowparrleftright}
+ \comment{The symbol `$\leftrightarrows$'.}
+\endsetslot
+
+\setslot{arrowparrrightleft}
+ \comment{The symbol `$\rightleftarrows$'.}
+\endsetslot
+
+\setslot{shiftleft}
+ \comment{The symbol `$\Lsh$'.}
+\endsetslot
+
+\setslot{shiftright}
+ \comment{The symbol `$\Rsh$'.}
+\endsetslot
+
+\setslot{squiggleright}
+ \comment{The symbol `$\rightsquigarrow$'.}
+\endsetslot
+
+\setslot{squiggleleftright}
+ \comment{The symbol `$\leftrightsquigarrow$'.}
+\endsetslot
+
+\setslot{curlyleft}
+ \comment{The symbol `$\looparrowleft$'.}
+\endsetslot
+
+\setslot{curlyright}
+ \comment{The symbol `$\looparrowright$'.}
+\endsetslot
+
+\setslot{circleequal}
+ \comment{The symbol `$\circeq$'.}
+\endsetslot
+
+\setslot{followsorsimilar} % was: followsorequal
+ \comment{The symbol `$\succsim$'.}
+\endsetslot
+
+\setslot{greaterorsimilar}
+ \comment{The symbol `$\gtrsim$'.}
+\endsetslot
+
+\setslot{greaterorapproxeql}
+ \comment{The symbol `$\gtrapprox$'.}
+\endsetslot
+
+\setslot{multimap}
+ \comment{The symbol `$\multimap$'.}
+\endsetslot
+
+\setslot{therefore}
+ \comment{The symbol `$\therefore$'.}
+\endsetslot
+
+\setslot{because}
+ \comment{The symbol `$\because$'.}
+\endsetslot
+
+\setslot{equalsdots}
+ \comment{The symbol `$\doteqdot$'.}
+\endsetslot
+
+\setslot{defines}
+ \comment{The symbol `$\triangleq$'.}
+\endsetslot
+
+\setslot{precedesorsimilar} % was: precedesorequal
+ \comment{The symbol `$\precsim$'.}
+\endsetslot
+
+\setslot{lessorsimilar}
+ \comment{The symbol `$\lesssim$'.}
+\endsetslot
+
+\setslot{lessorapproxeql}
+ \comment{The symbol `$\lessapprox$'.}
+\endsetslot
+
+\setslot{equalslantorless} % was: equalorless
+ \comment{The symbol `$\eqslantless$'.}
+\endsetslot
+
+\setslot{equalslantorgreater} % was: equaulorgreater
+ \comment{The symbol `$\eqslantgtr$'.}
+\endsetslot
+
+\setslot{curlyorprecedes} % was: equalorprecedes
+ \comment{The symbol `$\curlyeqprec$'.}
+\endsetslot
+
+\setslot{curlyorfollows} % was: equalorfollows
+ \comment{The symbol `$\curlyeqsucc$'.}
+\endsetslot
+
+\setslot{precedesorcurly}
+ \comment{The symbol `$\preccurlyeq$'.}
+\endsetslot
+
+\setslot{lessdblequal}
+ \comment{The symbol `$\leqq$'.}
+\endsetslot
+
+\setslot{lessorequalslant}
+ \comment{The symbol `$\leqslant$'.}
+\endsetslot
+
+\setslot{lessorgreater}
+ \comment{The symbol `$\lessgtr$'.}
+\endsetslot
+
+\setslot{primereverse}
+ \comment{The symbol `$\backprime$'.}
+\endsetslot
+
+\setslot{arrowaxishorizex} % axisshort
+ \comment{The extension piece to construct dashed arrows.}
+\endsetslot
+
+\setslot{equaldotrightleft}
+ \comment{The symbol `$\risingdotseq$'.}
+\endsetslot
+
+\setslot{equaldotleftright}
+ \comment{The symbol `$\fallingdotseq$'.}
+\endsetslot
+
+\setslot{followsorcurly}
+ \comment{The symbol `$\succcurlyeq$'.}
+\endsetslot
+
+\setslot{greaterdblequal}
+ \comment{The symbol `$\geqq$'.}
+\endsetslot
+
+\setslot{greaterorequalslant}
+ \comment{The symbol `$\geqslant$'.}
+\endsetslot
+
+\setslot{greaterorless}
+ \comment{The symbol `$\gtrless$'.}
+\endsetslot
+
+\setslot{squareimage}
+ \comment{The symbol `$\sqsubset$'.}
+\endsetslot
+
+\setslot{squareoriginal}
+ \comment{The symbol `$\sqsupset$'.}
+\endsetslot
+
+\setslot{vartriangleright}
+ \comment{The symbol `$\vartriangleright$'.}
+\endsetslot
+
+\setslot{vartriangleleft}
+ \comment{The symbol `$\vartriangleleft$'.}
+\endsetslot
+
+\setslot{trianglerightequal}
+ \comment{The symbol `$\trianglerighteq$'.}
+\endsetslot
+
+\setslot{triangleleftequal}
+ \comment{The symbol `$\trianglelefteq$'.}
+\endsetslot
+
+\setslot{bigstar}
+ \comment{The symbol `$\bigstar$'.}
+\endsetslot
+
+\setslot{between}
+ \comment{The symbol `$\between$'.}
+\endsetslot
+
+\setslot{triangledownsld}
+ \comment{The symbol `$\blacktriangledown$'.}
+\endsetslot
+
+\setslot{trianglerightsld}
+ \comment{The symbol `$\blacktriangleright$'.}
+\endsetslot
+
+\setslot{triangleleftsld}
+ \comment{The symbol `$\blacktriangleleft$'.}
+\endsetslot
+
+\setslot{arrowaxisright}
+ \comment{The right arrowhead to construct dashed arrows.}
+\endsetslot
+
+\setslot{arrowaxisleft}
+ \comment{The left arrowhead to construct dashed arrows.}
+\endsetslot
+
+\setslot{triangleup}
+ \comment{The symbol `$\vartriangle$'.}
+\endsetslot
+
+\setslot{trianglesolid}
+ \comment{The symbol `$\blacktriangle$'.}
+\endsetslot
+
+\setslot{triangledown} % triangleinv ?
+ \comment{The symbol `$\triangledown$'.}
+\endsetslot
+
+\setslot{ringinequal}
+ \comment{The symbol `$\eqcirc$'.}
+\endsetslot
+
+\setslot{lessequalgreater}
+ \comment{The symbol `$\lesseqgtr$'.}
+\endsetslot
+
+\setslot{greaterequalless}
+ \comment{The symbol `$\gtreqless$'.}
+\endsetslot
+
+\setslot{lessdbleqlgreater}
+ \comment{The symbol `$\lesseqqgtr$'.}
+\endsetslot
+
+\setslot{greaterdbleqlless}
+ \comment{The symbol `$\gtreqqless$'.}
+\endsetslot
+
+\setslot{Yen}
+ \comment{The symbol `$\yen$'.}
+\endsetslot
+
+\setslot{arrowtripleright}
+ \comment{The symbol `$\Rrightarrow$'.}
+\endsetslot
+
+\setslot{arrowtripleleft}
+ \comment{The symbol `$\Lleftarrow$'.}
+\endsetslot
+
+\setslot{check}
+ \comment{The symbol `$\checkmark$'.}
+\endsetslot
+
+\setslot{orunderscore}
+ \comment{The symbol `$\veebar$'.}
+\endsetslot
+
+\setslot{nand}
+ \comment{The symbol `$\barwedge$'.}
+\endsetslot
+
+\setslot{perpcorrespond}
+ \comment{The symbol `$\doublebarwedge$'.}
+\endsetslot
+
+\setslot{angle}
+ \comment{The symbol `$\angle$'.}
+\endsetslot
+
+\setslot{measuredangle}
+ \comment{The symbol `$\measuredangle$'.}
+\endsetslot
+
+\setslot{sphericalangle}
+ \comment{The symbol `$\sphericalangle$'.}
+\endsetslot
+
+\setslot{proportional}
+ \comment{The symbol `$\varpropto$'.}
+\endsetslot
+
+\setslot{slurbelow} % smile ???
+ \comment{The symbol `$\smallsmile$'.}
+\endsetslot
+
+\setslot{slurabove} % frown ???
+ \comment{The symbol `$\smallfrown$'.}
+\endsetslot
+
+\setslot{subsetdbl}
+ \comment{The symbol `$\Subset$'.}
+\endsetslot
+
+\setslot{supersetdbl}
+ \comment{The symbol `$\Supset$'.}
+\endsetslot
+
+\setslot{uniondbl}
+ \comment{The symbol `$\Cup$'.}
+\endsetslot
+
+\setslot{intersectiondbl}
+ \comment{The symbol `$\Cap$'.}
+\endsetslot
+
+\setslot{uprise}
+ \comment{The symbol `$\curlywedge$'.}
+\endsetslot
+
+\setslot{downfall}
+ \comment{The symbol `$\curlyvee$'.}
+\endsetslot
+
+\setslot{multiopenleft}
+ \comment{The symbol `$\leftthreetimes$'.}
+\endsetslot
+
+\setslot{multiopenright}
+ \comment{The symbol `$\rightthreetimes$'.}
+\endsetslot
+
+\setslot{subsetdblequal}
+ \comment{The symbol `$\subseteqq$'.}
+\endsetslot
+
+\setslot{supersetdblequal}
+ \comment{The symbol `$\supseteqq$'.}
+\endsetslot
+
+\setslot{difference}
+ \comment{The symbol `$\bumpeq$'.}
+\endsetslot
+
+\setslot{geomequivalent}
+ \comment{The symbol `$\Bumpeq$'.}
+\endsetslot
+
+\setslot{muchless}
+ \comment{The symbol `$\lll$'.}
+\endsetslot
+
+\setslot{muchgreater}
+ \comment{The symbol `$\ggg$'.}
+\endsetslot
+
+\setslot{rightanglenw}
+ \comment{The symbol `$\ulcorner$'.}
+\endsetslot
+
+\setslot{rightanglene}
+ \comment{The symbol `$\urcorner$'.}
+\endsetslot
+
+\setslot{circledR} % circleR
+ \comment{The symbol `$\circledR$'.}
+\endsetslot
+
+\setslot{circledS} % circleS
+ \comment{The symbol `$\circledS$'.}
+\endsetslot
+
+\setslot{fork}
+ \comment{The symbol `$\pitchfork$'.}
+\endsetslot
+
+\setslot{dotplus}
+ \comment{The symbol `$\dotplus$'.}
+\endsetslot
+
+\setslot{revsimilar}
+ \comment{The symbol `$\backsim$'.}
+\endsetslot
+
+\setslot{revasymptequal}
+ \comment{The symbol `$\backsimeq$'.}
+\endsetslot
+
+\setslot{rightanglesw}
+ \comment{The symbol `$\llcorner$'.}
+\endsetslot
+
+\setslot{rightanglese}
+ \comment{The symbol `$\lrcorner$'.}
+\endsetslot
+
+\setslot{maltesecross}
+ \comment{The symbol `$\maltese$'.}
+\endsetslot
+
+\setslot{complement}
+ \comment{The symbol `$\complement$'.}
+\endsetslot
+
+\setslot{intercal}
+ \comment{The symbol `$\intercal$'.}
+\endsetslot
+
+\setslot{circlecirc} % circlering ???
+ \comment{The symbol `$\circledcirc$'.}
+\endsetslot
+
+\setslot{circleasterisk}
+ \comment{The symbol `$\circledast$'.}
+\endsetslot
+
+\setslot{circledash} % circleminus ???
+ \comment{The symbol `$\circleddash$'.}
+\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+2001/01/10: File added to \textsf{fontinst} distribution, description
+of workaround for codingscheme bug in \texttt{msam} fonts changed,
+intermediate variables for fontdimens 8--22 introduced, and some minor
+markup changes were made. (LH)
+
+\end{multicols}
+
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/mathetx/msbm.etx b/fonts/utilities/fontinst/inputs/mathetx/msbm.etx
new file mode 100644
index 0000000000..d58bd8cfb2
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/msbm.etx
@@ -0,0 +1,619 @@
+\relax
+
+\documentclass[twocolumn]{article}
+
+\usepackage{fontdoc}
+\usepackage{amssymb}
+\usepackage{multicol}
+
+\title{The AMS \texttt{msbm} symbol encoding vector}
+\author{Mattias Clasen, modifications by Ulrik Vieth}
+
+\begin{document}\onecolumn
+
+\maketitle
+
+\section{Introduction}
+
+This document describes the AMS \texttt{msbm} symbol encoding, which
+is unfortunately called \texttt{TEX MATH SYMBOLS} in the \texttt{.tfm}
+files although it has nothing to do with the encoding of
+\texttt{cmsy}. To overcome this difficulty use e.g.\ \texttt{msbm10}
+like
+\begin{quote}
+ \textellipsis
+ \verb|,\metrics\generalpltomtx{msbm10}{msbm10}{pl}{msbm},msbm10,|%
+ \textellipsis
+\end{quote}
+in the \textit{file list} argument of \verb+\installfont+, or generate
+the \texttt{.mtx} file at some point before the \verb|\installfont|
+command.
+
+Most glyph names were revised to match the names used in the
+\texttt{.afm} files of the BlueSky Type~1 fonts, except for a few
+cases where those glyph names were found to be confusing or
+misleading.
+
+\showbranches
+\begin{multicols}{2}
+
+\encoding
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{AMS Math Symbols, Part B}
+
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\comment{The following font dimension defaults are taken from
+\texttt{cmsy10}.}
+
+\setint{num1}{677}
+\setint{num2}{394}
+\setint{num3}{444}
+\setint{denom1}{686}
+\setint{denom2}{345}
+\setint{sup1}{413}
+\setint{sup2}{363}
+\setint{sup3}{289}
+\setint{sub1}{150}
+\setint{sub2}{247}
+\setint{supdrop}{386}
+\setint{subdrop}{50}
+\setint{delim1}{2390}
+\setint{delim2}{1010}
+\setint{axisheight}{250}
+
+
+\begincomment
+\section{Default font dimensions}
+\endcomment
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{0} % interword space
+\setint{fontdimen(3)}{0} % interword stretch
+\setint{fontdimen(4)}{0} % interword shrink
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\setint{fontdimen(7)}{0} % extra space after .
+
+\setint{fontdimen(8)}{\int{num1}} % num 1
+\setint{fontdimen(9)}{\int{num2}} % num 2
+\setint{fontdimen(10)}{\int{num3}} % num 3
+\setint{fontdimen(11)}{\int{denom1}} % denom 1
+\setint{fontdimen(12)}{\int{denom2}} % denom 2
+\setint{fontdimen(13)}{\int{sup1}} % sup 1
+\setint{fontdimen(14)}{\int{sup2}} % sup 2
+\setint{fontdimen(15)}{\int{sup3}} % sup 3
+\setint{fontdimen(16)}{\int{sub1}} % sub 1
+\setint{fontdimen(17)}{\int{sub2}} % sub 2
+\setint{fontdimen(18)}{\int{supdrop}} % supdrop
+\setint{fontdimen(19)}{\int{subdrop}} % subdrop
+\setint{fontdimen(20)}{\int{delim1}} % delim 1
+\setint{fontdimen(21)}{\int{delim2}} % delim 2
+\setint{fontdimen(22)}{\int{axisheight}} % math axis height
+
+
+\begincomment
+\section{The encoding}
+There are 128 glyphs in this encoding.
+\endcomment
+
+\setslot{lessnotvertequal} % lessornotequal
+ \comment{The symbol `$\lvertneqq$'.}
+\endsetslot
+
+\setslot{greaternotvertequal} % greaterornotequal
+ \comment{The symbol `$\gvertneqq$'.}
+\endsetslot
+
+\setslot{notlessequal}
+ \comment{The symbol `$\nleq$'.}
+\endsetslot
+
+\setslot{notgreaterequal}
+ \comment{The symbol `$\ngeq$'.}
+\endsetslot
+
+\setslot{notless}
+ \comment{The symbol `$\nless$'.}
+\endsetslot
+
+\setslot{notgreater}
+ \comment{The symbol `$\ngtr$'.}
+\endsetslot
+
+\setslot{notprecedes}
+ \comment{The symbol `$\nprec$'.}
+\endsetslot
+
+\setslot{notfollows}
+ \comment{The symbol `$\nsucc$'.}
+\endsetslot
+
+\setslot{lessornotdbleql}
+ \comment{The symbol `$\lneqq$'.}
+\endsetslot
+
+\setslot{greaterornotdbleql}
+ \comment{The symbol `$\gneqq$'.}
+\endsetslot
+
+\setslot{notlessorequalslant} % was: notlessorslnteql
+ \comment{The symbol `$\nleqslant$'.}
+\endsetslot
+
+\setslot{notgreaterorequalslant} % was: notgreaterorslnteql
+ \comment{The symbol `$\ngeqslant$'.}
+\endsetslot
+
+\setslot{lessnotequal}
+ \comment{The symbol `$\lneq$'.}
+\endsetslot
+
+\setslot{greaternotequal}
+ \comment{The symbol `$\gneq$'.}
+\endsetslot
+
+\setslot{notprecedesoreql}
+ \comment{The symbol `$\npreceq$'.}
+\endsetslot
+
+\setslot{notfollowsoreql}
+ \comment{The symbol `$\nsucceq$'.}
+\endsetslot
+
+\setslot{precedesornotsimilar} % was: precedesornoteqvlnt
+ \comment{The symbol `$\precnsim$'.}
+\endsetslot
+
+\setslot{followsornotsimilar} % was: followornoteqvlnt
+ \comment{The symbol `$\succnsim$'.}
+\endsetslot
+
+\setslot{lessornotsimilar}
+ \comment{The symbol `$\lnsim$'.}
+\endsetslot
+
+\setslot{greaterornotsimilar}
+ \comment{The symbol `$\gnsim$'.}
+\endsetslot
+
+\setslot{notlessdblequal}
+ \comment{The symbol `$\nleqq$'.}
+\endsetslot
+
+\setslot{notgreaterdblequal}
+ \comment{The symbol `$\ngeqq$'.}
+\endsetslot
+
+\setslot{precedesnotdbleql} % was: precedesnotslnteql
+ \comment{The symbol `$\precneqq$'.}
+\endsetslot
+
+\setslot{followsnotdbleql} % was: followsnotslnteql
+ \comment{The symbol `$\succneqq$'.}
+\endsetslot
+
+\setslot{precedesnotapproxeql} % was: precedesnotdbleqv
+ \comment{The symbol `$\precnapprox$'.}
+\endsetslot
+
+\setslot{followsnotapproxeql} % was: followsnotdbleqv
+ \comment{The symbol `$\succnapprox$'.}
+\endsetslot
+
+\setslot{lessnotapproxeql} % was: lessnotdblequal
+ \comment{The symbol `$\lnapprox$'.}
+\endsetslot
+
+\setslot{greaternotapproxeql} % was: greaternotdblequal
+ \comment{The symbol `$\gnapprox$'.}
+\endsetslot
+
+\setslot{notsimilar}
+ \comment{The symbol `$\nsim$'.}
+\endsetslot
+
+\setslot{notcongruent} % was: notapproxequual
+ \comment{The symbol `$\ncong$'.}
+\endsetslot
+
+\setslot{upslope}
+ \comment{The symbol `$\diagup$'.}
+\endsetslot
+
+\setslot{downslope}
+ \comment{The symbol `$\diagdown$'.}
+\endsetslot
+
+\setslot{notsubsetoreql}
+ \comment{The symbol `$\varsubsetneq$'.}
+\endsetslot
+
+\setslot{notsupersetoreql}
+ \comment{The symbol `$\varsupsetneq$'.}
+\endsetslot
+
+\setslot{notsubsetordbleql}
+ \comment{The symbol `$\nsubseteqq$'.}
+\endsetslot
+
+\setslot{notsupersetordbleql}
+ \comment{The symbol `$\nsupseteqq$'.}
+\endsetslot
+
+\setslot{subsetornoteql}
+ \comment{The symbol `$\varsubsetneqq$'.}
+\endsetslot
+
+\setslot{supersetornoteql}
+ \comment{The symbol `$\varsupsetneqq$'.}
+\endsetslot
+
+\setslot{subsetornotdbleql}
+ \comment{The symbol `$\subsetneqq$'.}
+\endsetslot
+
+\setslot{supersetornotdbleql}
+ \comment{The symbol `$\supsetneqq$'.}
+\endsetslot
+
+\setslot{subsetnoteql}
+ \comment{The symbol `$\subsetneq$'.}
+\endsetslot
+
+\setslot{supersetnoteql}
+ \comment{The symbol `$\supsetneq$'.}
+\endsetslot
+
+\setslot{notsubseteql}
+ \comment{The symbol `$\nsubseteq$'.}
+\endsetslot
+
+\setslot{notsuperseteql}
+ \comment{The symbol `$\nsupseteq$'.}
+\endsetslot
+
+\setslot{notparallel}
+ \comment{The symbol `$\nparallel$'.}
+\endsetslot
+
+\setslot{notbar}
+ \comment{The symbol `$\nmid$'.}
+\endsetslot
+
+\setslot{notshortbar}
+ \comment{The symbol `$\nshortmid$'.}
+\endsetslot
+
+\setslot{notshortparallel}
+ \comment{The symbol `$\nshortparallel$'.}
+\endsetslot
+
+\setslot{notturnstile}
+ \comment{The symbol `$\nvdash$'.}
+\endsetslot
+
+\setslot{notforces}
+ \comment{The symbol `$\nVdash$'.}
+\endsetslot
+
+\setslot{notsatisfies}
+ \comment{The symbol `$\nvDash$'.}
+\endsetslot
+
+\setslot{notforcesextra}
+ \comment{The symbol `$\nVDash$'.}
+\endsetslot
+
+\setslot{nottriangeqlright}
+ \comment{The symbol `$\ntrianglerighteq$'.}
+\endsetslot
+
+\setslot{nottriangeqlleft}
+ \comment{The symbol `$\ntrianglelefteq$'.}
+\endsetslot
+
+\setslot{nottriangleleft}
+ \comment{The symbol `$\ntriangleleft$'.}
+\endsetslot
+
+\setslot{nottriangleright}
+ \comment{The symbol `$\ntriangleright$'.}
+\endsetslot
+
+\setslot{notarrowleft}
+ \comment{The symbol `$\nleftarrow$'.}
+\endsetslot
+
+\setslot{notarrowright}
+ \comment{The symbol `$\nrightarrow$'.}
+\endsetslot
+
+\setslot{notdblarrowleft}
+ \comment{The symbol `$\nLeftarrow$'.}
+\endsetslot
+
+\setslot{notdblarrowright}
+ \comment{The symbol `$\nRightarrow$'.}
+\endsetslot
+
+\setslot{notdblarrowboth}
+ \comment{The symbol `$\nLeftrightarrow$'.}
+\endsetslot
+
+\setslot{notarrowboth}
+ \comment{The symbol `$\nleftrightarrow$'.}
+\endsetslot
+
+\setslot{dividemultiply}
+ \comment{The symbol `$\divideontimes$'.}
+\endsetslot
+
+\setslot{emptyset}
+ \comment{The symbol `$\varnothing$'.}
+\endsetslot
+
+\setslot{notexistential}
+ \comment{The symbol `$\nexists$'.}
+\endsetslot
+
+\setslot{Abbb}
+ \comment{The letter `$\mathbb{A}$'.}
+\endsetslot
+
+\setslot{Bbbb}
+ \comment{The letter `$\mathbb{B}$'.}
+\endsetslot
+
+\setslot{Cbbb}
+ \comment{The letter `$\mathbb{C}$'.}
+\endsetslot
+
+\setslot{Dbbb}
+ \comment{The letter `$\mathbb{D}$'.}
+\endsetslot
+
+\setslot{Ebbb}
+ \comment{The letter `$\mathbb{E}$'.}
+\endsetslot
+
+\setslot{Fbbb}
+ \comment{The letter `$\mathbb{F}$'.}
+\endsetslot
+
+\setslot{Gbbb}
+ \comment{The letter `$\mathbb{G}$'.}
+\endsetslot
+
+\setslot{Hbbb}
+ \comment{The letter `$\mathbb{H}$'.}
+\endsetslot
+
+\setslot{Ibbb}
+ \comment{The letter `$\mathbb{I}$'.}
+\endsetslot
+
+\setslot{Jbbb}
+ \comment{The letter `$\mathbb{J}$'.}
+\endsetslot
+
+\setslot{Kbbb}
+ \comment{The letter `$\mathbb{K}$'.}
+\endsetslot
+
+\setslot{Lbbb}
+ \comment{The letter `$\mathbb{L}$'.}
+\endsetslot
+
+\setslot{Mbbb}
+ \comment{The letter `$\mathbb{M}$'.}
+\endsetslot
+
+\setslot{Nbbb}
+ \comment{The letter `$\mathbb{N}$'.}
+\endsetslot
+
+\setslot{Obbb}
+ \comment{The letter `$\mathbb{O}$'.}
+\endsetslot
+
+\setslot{Pbbb}
+ \comment{The letter `$\mathbb{P}$'.}
+\endsetslot
+
+\setslot{Qbbb}
+ \comment{The letter `$\mathbb{Q}$'.}
+\endsetslot
+
+\setslot{Rbbb}
+ \comment{The letter `$\mathbb{R}$'.}
+\endsetslot
+
+\setslot{Sbbb}
+ \comment{The letter `$\mathbb{S}$'.}
+\endsetslot
+
+\setslot{Tbbb}
+ \comment{The letter `$\mathbb{T}$'.}
+\endsetslot
+
+\setslot{Ubbb}
+ \comment{The letter `$\mathbb{U}$'.}
+\endsetslot
+
+\setslot{Vbbb}
+ \comment{The letter `$\mathbb{V}$'.}
+\endsetslot
+
+\setslot{Wbbb}
+ \comment{The letter `$\mathbb{W}$'.}
+\endsetslot
+
+\setslot{Xbbb}
+ \comment{The letter `$\mathbb{X}$'.}
+\endsetslot
+
+\setslot{Ybbb}
+ \comment{The letter `$\mathbb{Y}$'.}
+\endsetslot
+
+\setslot{Zbbb}
+ \comment{The letter `$\mathbb{Z}$'.}
+\endsetslot
+
+\setslot{hatwide}
+ \nextlarger{hatwider}
+\endsetslot
+
+\setslot{hatwider}
+\endsetslot
+
+\setslot{tildewide}
+ \nextlarger{tildewider}
+\endsetslot
+
+\setslot{tildewider}
+\endsetslot
+
+\nextslot{96}
+
+\setslot{Finv}
+ \comment{The symbol `$\Finv$'.}
+\endsetslot
+
+\setslot{Gmir}
+ \comment{The symbol `$\Game$'.}
+\endsetslot
+
+\nextslot{102}
+
+\setslot{Omegainv}
+ \comment{The symbol `$\mho$'.}
+\endsetslot
+
+\setslot{eth}
+ \comment{The symbol `$\eth$'.}
+\endsetslot
+
+\setslot{equalorsimilar}
+ \comment{The symbol `$\eqsim$'.}
+\endsetslot
+
+\setslot{beth}
+ \comment{The symbol `$\beth$'.}
+\endsetslot
+
+\setslot{gimel}
+ \comment{The symbol `$\gimel$'.}
+\endsetslot
+
+\setslot{daleth}
+ \comment{The symbol `$\daleth$'.}
+\endsetslot
+
+\setslot{lessdot}
+ \comment{The symbol `$\lessdot$'.}
+\endsetslot
+
+\setslot{greaterdot}
+ \comment{The symbol `$\gtrdot$'.}
+\endsetslot
+
+\setslot{multicloseleft}
+ \comment{The symbol `$\ltimes$'.}
+\endsetslot
+
+\setslot{multicloseright}
+ \comment{The symbol `$\rtimes$'.}
+\endsetslot
+
+\setslot{shortbar} % was: barshort
+ \comment{The symbol `$\shortmid$'.}
+\endsetslot
+
+\setslot{shortparallel} % was: parallelshort
+ \comment{The symbol `$\shortparallel$'.}
+\endsetslot
+
+\setslot{integerdivide}
+ \comment{The symbol `$\smallsetminus$'.}
+\endsetslot
+
+\setslot{thicksimilar} % similar ???
+ \comment{The symbol `$\thicksim$'.}
+\endsetslot
+
+\setslot{thickapproxequal} % approxequal ???
+ \comment{The symbol `$\thickapprox$'.}
+\endsetslot
+
+\setslot{approxorequal}
+ \comment{The symbol `$\approxeq$'.}
+\endsetslot
+
+\setslot{followsorapproxeql} % was: followsorequal
+ \comment{The symbol `$\succapprox$'.}
+\endsetslot
+
+\setslot{precedesorapproxeql} % was: precedesorequal
+ \comment{The symbol `$\precapprox$'.}
+\endsetslot
+
+\setslot{archleftdown}
+ \comment{The symbol `$\curvearrowleft$'.}
+\endsetslot
+
+\setslot{archrightdown}
+ \comment{The symbol `$\curvearrowright$'.}
+\endsetslot
+
+\setslot{digamma}
+ \comment{The symbol `$\digamma$'.}
+\endsetslot
+
+\setslot{kappa1}
+ \comment{The symbol `$\varkappa$'.}
+\endsetslot
+
+\setslot{kbbb}
+ \comment{The symbol `$\Bbbk$'.}
+\endsetslot
+
+\setslot{hslash}
+ \comment{The symbol `$\hslash$'.}
+\endsetslot
+
+\setslot{hbar}
+ \comment{The symbol `$\hbar$'.}
+\endsetslot
+
+\setslot{suchthat} % was: epsiloninv
+ \comment{The symbol `$\backepsilon$'.}
+\endsetslot
+
+\endencoding
+
+
+\section{Changes}
+
+2001/01/10: File added to \textsf{fontinst} distribution, description
+of workaround for codingscheme bug in \texttt{msbm} fonts changed,
+intermediate variables for fontdimens 8--22 introduced, and some minor
+markup changes were made. (LH)
+
+\end{multicols}
+\end{document}
+
+
+
+
diff --git a/fonts/utilities/fontinst/inputs/mathetx/oml.etx b/fonts/utilities/fontinst/inputs/mathetx/oml.etx
new file mode 100644
index 0000000000..38ffb1f277
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/oml.etx
@@ -0,0 +1,627 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.921",
+%%% date = "2004-11-24",
+%%% time = "18:25:42 +01:00",
+%%% filename = "oml.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/index.html",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the old math italic encoding as a TeX
+%%% font encoding file, for use with the fontinst
+%%% utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\title{The \TeX\ math italic encoding vector}
+\author{Alan Jeffrey, Ulrik Vieth, Lars Hellstr\"om}
+\date{27 July 2002\\Version 1.921}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the \TeX\ math italic (OML) encoding.
+
+\showbranches
+\encoding
+
+\needsfontinstversion{1.917}
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{TEX MATH ITALIC}
+\setstr{encodingname}{TeXMathItalicEncoding}
+
+\setint{italicslant}{0}
+\setint{interword}{0} % interword space
+\setint{stretchword}{0} % interword stretch
+\setint{shrinkword}{0} % interword shrink
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+
+\setint{quad}{1000} % quad
+\setint{extraspace}{0} % extra space after .
+
+\begincomment
+\section{Font dimensions}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+
+
+\begincomment
+\section{The encoding}
+There are 128 glyphs in this encoding.
+\endcomment
+
+\setslot{Gamma}
+ \comment{The greek letter `$\Gamma$'.}
+\endsetslot
+
+\setslot{Delta}
+ \comment{The greek letter `$\Delta$'.}
+\endsetslot
+
+\setslot{Theta}
+ \comment{The greek letter `$\Theta$'.}
+\endsetslot
+
+\setslot{Lambda}
+ \comment{The greek letter `$\Lambda$'.}
+\endsetslot
+
+\setslot{Xi}
+ \comment{The greek letter `$\Xi$'.}
+\endsetslot
+
+\setslot{Pi}
+ \comment{The greek letter `$\Pi$'.}
+\endsetslot
+
+\setslot{Sigma}
+ \comment{The greek letter `$\Sigma$'.}
+\endsetslot
+
+\setslot{Upsilon}
+ \comment{The greek letter `$\Upsilon$' named `Upsilon1' by Adobe.}
+\endsetslot
+
+\setslot{Phi}
+ \comment{The greek letter `$\Phi$'.}
+\endsetslot
+
+\setslot{Psi}
+ \comment{The greek letter `$\Psi$'.}
+\endsetslot
+
+\setslot{Omega}
+ \comment{The greek letter `$\Omega$'.}
+\endsetslot
+
+\setslot{alpha}
+ \comment{The greek letter `$\alpha$'.}
+\endsetslot
+
+\setslot{beta}
+ \comment{The greek letter `$\beta$'.}
+\endsetslot
+
+\setslot{gamma}
+ \comment{The greek letter `$\gamma$'.}
+\endsetslot
+
+\setslot{delta}
+ \comment{The greek letter `$\delta$'.}
+\endsetslot
+
+\setslot{epsilon1}
+ \comment{The greek letter `$\epsilon$'.}
+\endsetslot
+
+\setslot{zeta}
+ \comment{The greek letter `$\zeta$'.}
+\endsetslot
+
+\setslot{eta}
+ \comment{The greek letter `$\eta$'.}
+\endsetslot
+
+\setslot{theta}
+ \comment{The greek letter `$\theta$'.}
+\endsetslot
+
+\setslot{iota}
+ \comment{The greek letter `$\iota$'.}
+\endsetslot
+
+\setslot{kappa}
+ \comment{The greek letter `$\kappa$'.}
+\endsetslot
+
+\setslot{lambda}
+ \comment{The greek letter `$\lambda$'.}
+\endsetslot
+
+\setslot{mu}
+ \comment{The greek letter `$\mu$'.}
+\endsetslot
+
+\setslot{nu}
+ \comment{The greek letter `$\nu$'.}
+\endsetslot
+
+\setslot{xi}
+ \comment{The greek letter `$\xi$'.}
+\endsetslot
+
+\setslot{pi}
+ \comment{The greek letter `$\pi$'.}
+\endsetslot
+
+\setslot{rho}
+ \comment{The greek letter `$\rho$'.}
+\endsetslot
+
+\setslot{sigma}
+ \comment{The greek letter `$\sigma$'.}
+\endsetslot
+
+\setslot{tau}
+ \comment{The greek letter `$\tau$'.}
+\endsetslot
+
+\setslot{upsilon}
+ \comment{The greek letter `$\upsilon$'.}
+\endsetslot
+
+\setslot{phi}
+ \comment{The greek letter `$\phi$'.}
+\endsetslot
+
+\setslot{chi}
+ \comment{The greek letter `$\chi$'.}
+\endsetslot
+
+\setslot{psi}
+ \comment{The greek letter `$\psi$'.}
+\endsetslot
+
+\setslot{omega}
+ \comment{The greek letter `$\omega$'.}
+\endsetslot
+
+\setslot{epsilon}
+ \comment{The greek letter `$\varepsilon$'.}
+\endsetslot
+
+\setslot{theta1}
+ \comment{The greek letter `$\vartheta$'.}
+\endsetslot
+
+\setslot{pi1}
+ \comment{The greek letter `$\varpi$', rather unfortunately named
+ `omega1' by Adobe.}
+\endsetslot
+
+\setslot{rho1}
+ \comment{The greek letter `$\varrho$'.}
+\endsetslot
+
+\setslot{sigma1}
+ \comment{The greek letter `$\varsigma$'.}
+\endsetslot
+
+\setslot{phi1}
+ \comment{The greek letter `$\varphi$'.}
+\endsetslot
+
+\setslot{harpoonleftup}
+ \comment{The harpoon symbol `$\leftharpoonup$',
+ named `arrowlefttophalf' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{harpoonleftdown}
+ \comment{The harpoon symbol `$\leftharpoondown$',
+ named `arrowleftbothalf' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{harpoonrightup}
+ \comment{The harpoon symbol `$\rightharpoonup$',
+ named `arrowrighttophalf' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{harpoonrightdown}
+ \comment{The harpoon symbol `$\rightharpoondown$',
+ named `arrowrightbothalf' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{hookrightchar}
+ \comment{The building block for `$\hookrightarrow$',
+ named `arrowhookleft' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{hookleftchar}
+ \comment{The building block for `$\hookleftarrow$',
+ named `arrowhookright' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{triangleright}
+ \comment{The triangle symbol `$\triangleright$'.}
+\endsetslot
+
+\setslot{triangleleft}
+ \comment{The triangle symbol `$\triangleleft$'.}
+\endsetslot
+
+\setslot{zerooldstyle}
+ \comment{The oldstyle digit zero `0'.}
+\endsetslot
+
+\setslot{oneoldstyle}
+ \comment{The oldstyle digit one `1'.}
+\endsetslot
+
+\setslot{twooldstyle}
+ \comment{The oldstyle digit two `2'.}
+\endsetslot
+
+\setslot{threeoldstyle}
+ \comment{The oldstyle digit three `3'.}
+\endsetslot
+
+\setslot{fouroldstyle}
+ \comment{The oldstyle digit four `4'.}
+\endsetslot
+
+\setslot{fiveoldstyle}
+ \comment{The oldstyle digit five `5'.}
+\endsetslot
+
+\setslot{sixoldstyle}
+ \comment{The oldstyle digit six `6'.}
+\endsetslot
+
+\setslot{sevenoldstyle}
+ \comment{The oldstyle digit seven `7'.}
+\endsetslot
+
+\setslot{eightoldstyle}
+ \comment{The oldstyle digit eight `8'.}
+\endsetslot
+
+\setslot{nineoldstyle}
+ \comment{The oldstyle digit nine `9'.}
+\endsetslot
+
+\setslot{period}
+ \comment{The period `$.$'.}
+\endsetslot
+
+\setslot{comma}
+ \comment{The comma `$,$'.}
+\endsetslot
+
+\setslot{less}
+ \comment{The less-than sign `$<$'.}
+\endsetslot
+
+\setslot{slash}
+ \comment{The forwards oblique `$/$'.}
+\endsetslot
+
+\setslot{greater}
+ \comment{The greater-than sign `$>$'.}
+\endsetslot
+
+\setslot{star}
+ \comment{The star symbol `$\star$'.}
+\endsetslot
+
+\setslot{partialdiff}
+ \comment{The partial differentiation symbol `$\partial$'.}
+\endsetslot
+
+\setslot{A}
+ \comment{The letter `$\mathnormal{A}$'.}
+\endsetslot
+
+\setslot{B}
+ \comment{The letter `$\mathnormal{B}$'.}
+\endsetslot
+
+\setslot{C}
+ \comment{The letter `$\mathnormal{C}$'.}
+\endsetslot
+
+\setslot{D}
+ \comment{The letter `$\mathnormal{D}$'.}
+\endsetslot
+
+\setslot{E}
+ \comment{The letter `$\mathnormal{E}$'.}
+\endsetslot
+
+\setslot{F}
+ \comment{The letter `$\mathnormal{F}$'.}
+\endsetslot
+
+\setslot{G}
+ \comment{The letter `$\mathnormal{G}$'.}
+\endsetslot
+
+\setslot{H}
+ \comment{The letter `$\mathnormal{H}$'.}
+\endsetslot
+
+\setslot{I}
+ \comment{The letter `$\mathnormal{I}$'.}
+\endsetslot
+
+\setslot{J}
+ \comment{The letter `$\mathnormal{J}$'.}
+\endsetslot
+
+\setslot{K}
+ \comment{The letter `$\mathnormal{K}$'.}
+\endsetslot
+
+\setslot{L}
+ \comment{The letter `$\mathnormal{L}$'.}
+\endsetslot
+
+\setslot{M}
+ \comment{The letter `$\mathnormal{M}$'.}
+\endsetslot
+
+\setslot{N}
+ \comment{The letter `$\mathnormal{N}$'.}
+\endsetslot
+
+\setslot{O}
+ \comment{The letter `$\mathnormal{O}$'.}
+\endsetslot
+
+\setslot{P}
+ \comment{The letter `$\mathnormal{P}$'.}
+\endsetslot
+
+\setslot{Q}
+ \comment{The letter `$\mathnormal{Q}$'.}
+\endsetslot
+
+\setslot{R}
+ \comment{The letter `$\mathnormal{R}$'.}
+\endsetslot
+
+\setslot{S}
+ \comment{The letter `$\mathnormal{S}$'.}
+\endsetslot
+
+\setslot{T}
+ \comment{The letter `$\mathnormal{T}$'.}
+\endsetslot
+
+\setslot{U}
+ \comment{The letter `$\mathnormal{U}$'.}
+\endsetslot
+
+\setslot{V}
+ \comment{The letter `$\mathnormal{V}$'.}
+\endsetslot
+
+\setslot{W}
+ \comment{The letter `$\mathnormal{W}$'.}
+\endsetslot
+
+\setslot{X}
+ \comment{The letter `$\mathnormal{X}$'.}
+\endsetslot
+
+\setslot{Y}
+ \comment{The letter `$\mathnormal{Y}$'.}
+\endsetslot
+
+\setslot{Z}
+ \comment{The letter `$\mathnormal{Z}$'.}
+\endsetslot
+
+\setslot{flat}
+ \comment{The flat musical symbol `$\flat$'.}
+\endsetslot
+
+\setslot{natural}
+ \comment{The natural musical symbol `$\natural$'.}
+\endsetslot
+
+\setslot{sharp}
+ \comment{The sharp musical symbol `$\sharp$'.}
+\endsetslot
+
+\setslot{slurbelow}
+ \comment{The slur symbol `$\smile$'.}
+\endsetslot
+
+\setslot{slurabove}
+ \comment{The slur symbol `$\frown$'.}
+\endsetslot
+
+\setslot{lscript}
+ \comment{The script letter `$\ell$'.}
+\endsetslot
+
+\setslot{a}
+ \comment{The letter `$\mathnormal{a}$'.}
+\endsetslot
+
+\setslot{b}
+ \comment{The letter `$\mathnormal{b}$'.}
+\endsetslot
+
+\setslot{c}
+ \comment{The letter `$\mathnormal{c}$'.}
+\endsetslot
+
+\setslot{d}
+ \comment{The letter `$\mathnormal{d}$'.}
+\endsetslot
+
+\setslot{e}
+ \comment{The letter `$\mathnormal{e}$'.}
+\endsetslot
+
+\setslot{f}
+ \comment{The letter `$\mathnormal{f}$'.}
+\endsetslot
+
+\setslot{g}
+ \comment{The letter `$\mathnormal{g}$'.}
+\endsetslot
+
+\setslot{h}
+ \comment{The letter `$\mathnormal{h}$'.}
+\endsetslot
+
+\setslot{i}
+ \comment{The letter `$\mathnormal{i}$'.}
+\endsetslot
+
+\setslot{j}
+ \comment{The letter `$\mathnormal{j}$'.}
+\endsetslot
+
+\setslot{k}
+ \comment{The letter `$\mathnormal{k}$'.}
+\endsetslot
+
+\setslot{l}
+ \comment{The letter `$\mathnormal{l}$'.}
+\endsetslot
+
+\setslot{m}
+ \comment{The letter `$\mathnormal{m}$'.}
+\endsetslot
+
+\setslot{n}
+ \comment{The letter `$\mathnormal{n}$'.}
+\endsetslot
+
+\setslot{o}
+ \comment{The letter `$\mathnormal{o}$'.}
+\endsetslot
+
+\setslot{p}
+ \comment{The letter `$\mathnormal{p}$'.}
+\endsetslot
+
+\setslot{q}
+ \comment{The letter `$\mathnormal{q}$'.}
+\endsetslot
+
+\setslot{r}
+ \comment{The letter `$\mathnormal{r}$'.}
+\endsetslot
+
+\setslot{s}
+ \comment{The letter `$\mathnormal{s}$'.}
+\endsetslot
+
+\setslot{t}
+ \comment{The letter `$\mathnormal{t}$'.}
+\endsetslot
+
+\setslot{u}
+ \comment{The letter `$\mathnormal{u}$'.}
+\endsetslot
+
+\setslot{v}
+ \comment{The letter `$\mathnormal{v}$'.}
+\endsetslot
+
+\setslot{w}
+ \comment{The letter `$\mathnormal{w}$'.}
+\endsetslot
+
+\setslot{x}
+ \comment{The letter `$\mathnormal{x}$'.}
+\endsetslot
+
+\setslot{y}
+ \comment{The letter `$\mathnormal{y}$'.}
+\endsetslot
+
+\setslot{z}
+ \comment{The letter `$\mathnormal{z}$'.}
+\endsetslot
+
+\setslot{dotlessi}
+ \comment{The dotless letter `$\imath$'.}
+\endsetslot
+
+\setslot{dotlessj}
+ \comment{The dotless letter `$\jmath$'.}
+\endsetslot
+
+\setslot{weierstrass}
+ \comment{The Weierstrass P symbol `$\wp$'.}
+\endsetslot
+
+\setslot{vector}
+ \comment{The vector accent symbol `$\vec{x}$'.}
+\endsetslot
+
+\setslot{tie}
+ \comment{The tie accent symbol `\t oo'.}
+\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+
+29 Dec 1993, v\,1.30: Created file.
+
+03 Jan 1994, v\,1.301: Moved from ltugboat class to article.
+
+09 Jan 1994, v\,1.305: Renamed some glyphs to use the same glyph names
+ as Lucida New Math.
+
+10 Jun 1998, v\,1.800: Really use the same names as Lucida New Math.
+ Correct ordering of `flat', `natural', `sharp'.
+
+03 Oct 2000, v\,1.915: Minor markup changes (LH).
+
+06 Oct 2000, v\,1.915: Added \texttt{encodingname} (same as in
+ \texttt{texmital.enc}). (LH)
+
+27 Jul 2002, v\,1.921: Using \verb"\setfontdimen" for specifying
+ fontdimens. (LH)
+
+24 Nov 2004: Corrected typo (extra right brace). (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathetx/oms.etx b/fonts/utilities/fontinst/inputs/mathetx/oms.etx
new file mode 100644
index 0000000000..9e139c1589
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/oms.etx
@@ -0,0 +1,678 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.929",
+%%% date = "2005-02-03",
+%%% time = "14:24:50 +01:00",
+%%% filename = "oms.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/index.html",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the old math symbol encoding as a TeX
+%%% font encoding file, for use with the fontinst
+%%% utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2004/11/24]
+
+\title{The \TeX\ math symbol encoding vector}
+\author{Alan Jeffrey, Ulrik Vieth}
+\date{3 February 2005\\Version 1.929}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the \TeX\ math symbol (OMS) encoding.
+
+\showbranches
+\encoding
+
+\needsfontinstversion{1.917}
+
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{TEX MATH SYMBOLS}
+\setstr{encodingname}{TeXMathSymbolEncoding}
+
+\setint{italicslant}{0}
+\setint{interword}{0}
+\setint{stretchword}{0}
+\setint{shrinkword}{0}
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+\setint{quad}{1000}
+\setint{extraspace}{0}
+
+
+\comment{The following font dimension defaults are taken from
+\texttt{cmsy10}.}
+
+\setint{num1}{677}
+\setint{num2}{394}
+\setint{num3}{444}
+\setint{denom1}{686}
+\setint{denom2}{345}
+\setint{sup1}{413}
+\setint{sup2}{363}
+\setint{sup3}{289}
+\setint{sub1}{150}
+\setint{sub2}{247}
+\setint{supdrop}{386}
+\setint{subdrop}{50}
+\setint{delim1}{2390}
+\setint{delim2}{1010}
+\setint{axisheight}{250}
+
+\begincomment
+\section{Font dimensions}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+\setfontdimen{8}{num1} % num 1
+\setfontdimen{9}{num2} % num 2
+\setfontdimen{10}{num3} % num 3
+\setfontdimen{11}{denom1} % denom 1
+\setfontdimen{12}{denom2} % denom 2
+\setfontdimen{13}{sup1} % sup 1
+\setfontdimen{14}{sup2} % sup 2
+\setfontdimen{15}{sup3} % sup 3
+\setfontdimen{16}{sub1} % sub 1
+\setfontdimen{17}{sub2} % sub 2
+\setfontdimen{18}{supdrop} % supdrop
+\setfontdimen{19}{subdrop} % subdrop
+\setfontdimen{20}{delim1} % delim 1
+\setfontdimen{21}{delim2} % delim 2
+\setfontdimen{22}{axisheight} % math axis height
+
+
+\begincomment
+\section{The encoding}
+There are 128 glyphs in this encoding.
+\endcomment
+
+\setslot{minus}
+ \comment{The subtraction symbol `$-$'.}
+\endsetslot
+
+\setslot{periodcentered}
+ \comment{The centered dot symbol `$\cdot$'.
+ It is called `dotmath' in Adobe Symbol.}
+\endsetslot
+
+\setslot{multiply}
+ \comment{The multiplication symbol `$\times$'.}
+\endsetslot
+
+\setslot{asteriskmath}
+ \comment{The centered asterisk symbol `$*$'.}
+\endsetslot
+
+\setslot{divide}
+ \comment{The division symbol `$\plaindiv$'.}
+\endsetslot
+
+\setslot{diamondmath}
+ \comment{The diamond symbol `$\diamond$'.}
+\endsetslot
+
+\setslot{plusminus}
+ \comment{The plus or minus symbol `$\pm$'.}
+\endsetslot
+
+\setslot{minusplus}
+ \comment{The minus or plus symbol `$\mp$'.}
+\endsetslot
+
+\setslot{circleplus}
+ \comment{The circled plus symbol `$\oplus$'.}
+\endsetslot
+
+\setslot{circleminus}
+ \comment{The circled minus symbol `$\ominus$'.}
+\endsetslot
+
+\setslot{circlemultiply}
+ \comment{The circled multiplication symbol `$\otimes$'.}
+\endsetslot
+
+\setslot{circledivide}
+ \comment{The circled oblique symbol `$\oslash$'.}
+\endsetslot
+
+\setslot{circledot}
+ \comment{The circled dot symbol `$\odot$'.}
+\endsetslot
+
+\setslot{circlecopyrt}
+ \comment{The large circle symbol `$\bigcirc$' used for building the
+ copyright symbol `\copyright'.}
+\endsetslot
+
+\setslot{openbullet}
+ \comment{The circle symbol `$\circ$'.}
+\endsetslot
+
+\setslot{bullet}
+ \comment{The bullet symbol `$\bullet$'.}
+\endsetslot
+
+\setslot{equivasymptotic}
+ \comment{The asymptotic equals symbol `$\asymp$'.}
+\endsetslot
+
+\setslot{equivalence}
+ \comment{The equivalence symbol `$\equiv$'.}
+\endsetslot
+
+\setslot{reflexsubset}
+ \comment{The subset or equals symbol `$\subseteq$'.}
+\endsetslot
+
+\setslot{reflexsuperset}
+ \comment{The superset or equals symbol `$\supseteq$'.}
+\endsetslot
+
+\setslot{lessequal}
+ \comment{The less or equals symbol `$\leq$'.}
+\endsetslot
+
+\setslot{greaterequal}
+ \comment{The greater or equals symbol `$\geq$'.}
+\endsetslot
+
+\setslot{precedesequal}
+ \comment{The precedes or equals symbol `$\preceq$'.}
+\endsetslot
+
+\setslot{followsequal}
+ \comment{The follows or equals symbol `$\succeq$'.}
+\endsetslot
+
+\setslot{similar}
+ \comment{The similar symbol `$\sim$'.}
+\endsetslot
+
+\setslot{approxequal}
+ \comment{The approximate equality symbol `$\approx$'.}
+\endsetslot
+
+\setslot{propersubset}
+ \comment{The subset symbol `$\subset$'.}
+\endsetslot
+
+\setslot{propersuperset}
+ \comment{The superset symbol `$\supset$'.}
+\endsetslot
+
+\setslot{lessmuch}
+ \comment{The much less symbol `$\ll$'.}
+\endsetslot
+
+\setslot{greatermuch}
+ \comment{The much greater symbol `$\gg$'.}
+\endsetslot
+
+\setslot{precedes} % was curlyless
+ \comment{The precedes symbol `$\prec$'.}
+\endsetslot
+
+\setslot{follows} % was curlygreater
+ \comment{The follows symbol `$\succ$'.}
+\endsetslot
+
+\setslot{arrowleft}
+ \comment{The left arrow symbol `$\leftarrow$'.}
+\endsetslot
+
+\setslot{arrowright}
+ \comment{The right arrow symbol `$\rightarrow$'.}
+\endsetslot
+
+\setslot{arrowup}
+ \comment{The up arrow symbol `$\uparrow$'.}
+\endsetslot
+
+\setslot{arrowdown}
+ \comment{The down arrow symbol `$\downarrow$'.}
+\endsetslot
+
+\setslot{arrowboth}
+ \comment{The horizontal arrow symbol `$\leftrightarrow$'.}
+\endsetslot
+
+\setslot{arrownortheast}
+ \comment{The north-east arrow symbol `$\nearrow$'.}
+\endsetslot
+
+\setslot{arrowsoutheast}
+ \comment{The south-east arrow symbol `$\searrow$'.}
+\endsetslot
+
+\setslot{similarequal}
+ \comment{The similar or equal symbol `$\simeq$'.}
+\endsetslot
+
+\setslot{arrowdblleft}
+ \comment{The double left arrow symbol `$\Leftarrow$'.}
+\endsetslot
+
+\setslot{arrowdblright}
+ \comment{The double right arrow symbol `$\Rightarrow$'.}
+\endsetslot
+
+\setslot{arrowdblup}
+ \comment{The double up arrow symbol `$\Uparrow$'.}
+\endsetslot
+
+\setslot{arrowdbldown}
+ \comment{The double down arrow symbol `$\Downarrow$'.}
+\endsetslot
+
+\setslot{arrowdblboth}
+ \comment{The double horizontal arrow symbol `$\Leftrightarrow$'.}
+\endsetslot
+
+\setslot{arrownorthwest}
+ \comment{The north-west arrow symbol `$\nwarrow$'.}
+\endsetslot
+
+\setslot{arrowsouthwest}
+ \comment{The south-west arrow symbol `$\swarrow$'.}
+\endsetslot
+
+\setslot{proportional}
+ \comment{The proportional symbol `$\propto$'.}
+\endsetslot
+
+\setslot{prime}
+ \comment{The prime symbol `$\prime$'.}
+\endsetslot
+
+\setslot{infinity}
+ \comment{The infinity symbol `$\infty$'.}
+\endsetslot
+
+\setslot{element}
+ \comment{The set membership symbol `$\in$'.}
+\endsetslot
+
+\setslot{owner}
+ \comment{The backwards set membership symbol `$\ni$'.}
+\endsetslot
+
+\setslot{triangle}
+ \comment{The upwards triangle symbol `$\bigtriangleup$'.}
+\endsetslot
+
+\setslot{triangleinv}
+ \comment{The downwards triangle symbol `$\bigtriangledown$'.}
+\endsetslot
+
+\setslot{negationslash}
+ \comment{The negation slash symbol, used to construct
+ negated relations or arrows such as `$\not=$'.}
+\endsetslot
+
+\setslot{mapstochar}
+ \comment{The maps to building block symbol `$\mapstochar$',
+ used to build `$\mapsto$'.}
+\endsetslot
+
+\setslot{universal}
+ \comment{The universal quantification symbol `$\forall$'.}
+\endsetslot
+
+\setslot{existential}
+ \comment{The existential quantification symbol `$\exists$'.}
+\endsetslot
+
+\setslot{logicalnot}
+ \comment{The negation symbol `$\plainneg$'.}
+\endsetslot
+
+\setslot{emptysetstress}
+ \comment{The `stressed' empty set symbol `$\emptyset$', which should
+ look like a zero with a slash. The `emptyset' symbol is a circle
+ with a slash.}
+\endsetslot
+
+\setslot{Rfraktur}
+ \comment{The upper case Fraktur R symbol `$\Re$'. It is called
+ `Rfractur' rather than `Rfraktur' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{Ifraktur}
+ \comment{The upper case Fraktur I symbol `$\Im$'. It is called
+ `Ifractur' rather than `Ifraktur' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{latticetop}
+ \comment{The inverted perpendicular symbol `$\top$'.}
+\endsetslot
+
+\setslot{perpendicular}
+ \comment{The perpendicular symbol `$\perp$'.}
+\endsetslot
+
+\setslot{aleph}
+ \comment{The aleph symbol `$\aleph$'.}
+\endsetslot
+
+\setslot{A}
+ \comment{The calligraphic letter `$\mathcal{A}$'.}
+\endsetslot
+
+\setslot{B}
+ \comment{The calligraphic letter `$\mathcal{B}$'.}
+\endsetslot
+
+\setslot{C}
+ \comment{The calligraphic letter `$\mathcal{C}$'.}
+\endsetslot
+
+\setslot{D}
+ \comment{The calligraphic letter `$\mathcal{D}$'.}
+\endsetslot
+
+\setslot{E}
+ \comment{The calligraphic letter `$\mathcal{E}$'.}
+\endsetslot
+
+\setslot{F}
+ \comment{The calligraphic letter `$\mathcal{F}$'.}
+\endsetslot
+
+\setslot{G}
+ \comment{The calligraphic letter `$\mathcal{G}$'.}
+\endsetslot
+
+\setslot{H}
+ \comment{The calligraphic letter `$\mathcal{H}$'.}
+\endsetslot
+
+\setslot{I}
+ \comment{The calligraphic letter `$\mathcal{I}$'.}
+\endsetslot
+
+\setslot{J}
+ \comment{The calligraphic letter `$\mathcal{J}$'.}
+\endsetslot
+
+\setslot{K}
+ \comment{The calligraphic letter `$\mathcal{K}$'.}
+\endsetslot
+
+\setslot{L}
+ \comment{The calligraphic letter `$\mathcal{L}$'.}
+\endsetslot
+
+\setslot{M}
+ \comment{The calligraphic letter `$\mathcal{M}$'.}
+\endsetslot
+
+\setslot{N}
+ \comment{The calligraphic letter `$\mathcal{N}$'.}
+\endsetslot
+
+\setslot{O}
+ \comment{The calligraphic letter `$\mathcal{O}$'.}
+\endsetslot
+
+\setslot{P}
+ \comment{The calligraphic letter `$\mathcal{P}$'.}
+\endsetslot
+
+\setslot{Q}
+ \comment{The calligraphic letter `$\mathcal{Q}$'.}
+\endsetslot
+
+\setslot{R}
+ \comment{The calligraphic letter `$\mathcal{R}$'.}
+\endsetslot
+
+\setslot{S}
+ \comment{The calligraphic letter `$\mathcal{S}$'.}
+\endsetslot
+
+\setslot{T}
+ \comment{The calligraphic letter `$\mathcal{T}$'.}
+\endsetslot
+
+\setslot{U}
+ \comment{The calligraphic letter `$\mathcal{U}$'.}
+\endsetslot
+
+\setslot{V}
+ \comment{The calligraphic letter `$\mathcal{V}$'.}
+\endsetslot
+
+\setslot{W}
+ \comment{The calligraphic letter `$\mathcal{W}$'.}
+\endsetslot
+
+\setslot{X}
+ \comment{The calligraphic letter `$\mathcal{X}$'.}
+\endsetslot
+
+\setslot{Y}
+ \comment{The calligraphic letter `$\mathcal{Y}$'.}
+\endsetslot
+
+\setslot{Z}
+ \comment{The calligraphic letter `$\mathcal{Z}$'.}
+\endsetslot
+
+\setslot{union}
+ \comment{The set union symbol `$\cup$'.}
+\endsetslot
+
+\setslot{intersection}
+ \comment{The set intersection symbol `$\cap$'.}
+\endsetslot
+
+\setslot{unionmulti}
+ \comment{The multiset union symbol `$\uplus$'.}
+\endsetslot
+
+\setslot{logicaland}
+ \comment{The meet symbol `$\wedge$'.}
+\endsetslot
+
+\setslot{logicalor}
+ \comment{The join symbol `$\vee$'.}
+\endsetslot
+
+\setslot{turnstileleft}
+ \comment{The turnstile symbol `$\vdash$'.}
+\endsetslot
+
+\setslot{turnstileright}
+ \comment{The backwards turnstile symbol `$\dashv$'.}
+\endsetslot
+
+\setslot{floorleft}
+ \comment{The left floor symbol `$\lfloor$'.}
+\endsetslot
+
+\setslot{floorright}
+ \comment{The right floor symbol `$\rfloor$'.}
+\endsetslot
+
+\setslot{ceilingleft}
+ \comment{The left ceiling symbol `$\lceil$'.}
+\endsetslot
+
+\setslot{ceilingright}
+ \comment{The right ceiling symbol `$\rceil$'.}
+\endsetslot
+
+\setslot{braceleft}
+ \comment{The left brace symbol `$\{$'.}
+\endsetslot
+
+\setslot{braceright}
+ \comment{The right brace symbol `$\}$'.}
+\endsetslot
+
+\setslot{angleleft}
+ \comment{The left angle bracket symbol `$\langle$'.
+ It is called `angbracketleft' in MathTime and Lucida,
+ but `angleleft' in Adobe Symbol.}
+\endsetslot
+
+\setslot{angleright}
+ \comment{The right angle bracket symbol `$\rangle$'.
+ It is called `angbracketright' in MathTime and Lucida,
+ but `angleleft' in Adobe Symbol.}
+\endsetslot
+
+\setslot{bar}
+ \comment{The vertical bar symbol `$|$'.}
+\endsetslot
+
+\setslot{bardbl}
+ \comment{The parallel vertical bars symbol `$\parallel$'.}
+\endsetslot
+
+\setslot{arrowbothv}
+ \comment{The vertical arrows symbol `$\updownarrow$'.}
+\endsetslot
+
+\setslot{arrowdblbothv}
+ \comment{The double vertical arrows symbol `$\Updownarrow$'.}
+\endsetslot
+
+\setslot{backslash}
+ \comment{The backwards oblique symbol `$\backslash$'.}
+\endsetslot
+
+\setslot{wreathproduct}
+ \comment{The Wreath product symbol `$\wr$'.}
+\endsetslot
+
+\setslot{radicallow}
+ \comment{The lowered radical symbol `$\surd$'.}
+\endsetslot
+
+\setslot{coproduct}
+ \comment{The textstyle coproduct symbol `$\coprod$'.}
+\endsetslot
+
+\setslot{gradient}
+ \comment{The inverted Delta symbol `$\nabla$'.
+ It is also called `gradient' in MathTime and Lucida,
+ but `gradient' in Adobe Symbol.}
+\endsetslot
+
+\setslot{integral}
+ \comment{The small integral symbol `$\plainint$'.}
+\endsetslot
+
+\setslot{unionsq}
+ \comment{The square union symbol `$\sqcup$'.}
+\endsetslot
+
+\setslot{intersectionsq}
+ \comment{The square intersection symbol `$\sqcap$'.}
+\endsetslot
+
+\setslot{subsetsqequal}
+ \comment{The square subset or equal symbol `$\sqsubseteq$'.}
+\endsetslot
+
+\setslot{supersetsqequal}
+ \comment{The square superset or equal symbol `$\sqsupseteq$'.}
+\endsetslot
+
+\setslot{section}
+ \comment{The section symbol `\S'.}
+\endsetslot
+
+\setslot{dagger}
+ \comment{The dagger symbol `\dag'.}
+\endsetslot
+
+\setslot{daggerdbl}
+ \comment{The double dagger symbol `\ddag'.}
+\endsetslot
+
+\setslot{paragraph}
+ \comment{The paragraph symbol `\P'.}
+\endsetslot
+
+\setslot{club}
+ \comment{The club suit symbol `$\clubsuit$'.}
+\endsetslot
+
+\setslot{diamond}
+ \comment{The diamond suit symbol `$\diamondsuit$'.}
+\endsetslot
+
+\setslot{heart}
+ \comment{The heart suit symbol `$\heartsuit$'.}
+\endsetslot
+
+\setslot{spade}
+ \comment{The spade suit symbol `$\spadesuit$'.}
+\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+29 Dec 1993, v1.30: Created file.
+
+03 Jan 1994, v1.301: Moved from ltugboat class to article.
+
+06 Jan 1994, v1.303: Corrected a fontdimen bug.
+
+08 Jan 1994, v1.304: Renamed radicallowered to radicallow and
+ perpendicularinverse to perpendicularinv.
+
+09 Jan 1994, v1.305: Renamed emptyset to emptysetstress, to distinguish
+ the geometric and the humanist emptyset symbols.
+ Renamed some glyphs to use the same glyph names
+ as Lucida New Math.
+
+10 Jun 1998, v1.800: Really use the same names as Lucida New Math.
+ `curlyless/greater' renamed to `precedes/follows'.
+
+06 Oct 2000, v1.915: Introduced intermediate variables for fontdimens
+ 8--22. Added \texttt{encodingname}. Updated markup.
+ (LH)
+
+27 Jul 2002, v1.921: Introduced intermediate variables also for
+ fontdimens 1--7. Switched to setting fontdimens
+ using \verb"\setfontdimen". (LH)
+
+24 Nov 2004, v1.928: Changed \verb"\neg" to \verb"\plainneg" for
+ `\texttt{logicalnot}'. (LH)
+
+3 Feb 2005, v1.929: Corrected typo in wreath product comment. (LH)
+ Pointed out by Giuseppe Toscano.
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathetx/omx.etx b/fonts/utilities/fontinst/inputs/mathetx/omx.etx
new file mode 100644
index 0000000000..52af52af6d
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/omx.etx
@@ -0,0 +1,731 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.921",
+%%% date = "2002-07-27",
+%%% time = "18:45:45 +02:00",
+%%% filename = "omx.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/index.html",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the old math extension encoding as
+%%% a TeX font encoding file, for use with the
+%%% fontinst utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2001/03/16]
+
+\title{The \TeX\ math extension encoding vector}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{27 July 2002\\Version 1.921}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the \TeX\ math extensions (\texttt{OMX})
+encoding.
+
+\showbranches
+\setslotcomment{The glyph `$\vcenter{\hbox{\slotexample}}$'.}
+\useexamplefont{cmex10}
+\encoding
+
+\needsfontinstversion{1.917}
+
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{TEX MATH EXTENSION}
+\setstr{encodingname}{TeXMathExtensionEncoding}
+
+\setint{italicslant}{0}
+\setint{interword}{0}
+\setint{stretchword}{0}
+\setint{shrinkword}{0}
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\Else
+ \setint{xheight}{500}
+\Fi
+\setint{quad}{1000}
+\setint{extraspace}{0}
+
+\comment{The following defaults are taken from \texttt{cmex10}.}
+
+\setint{defaultrulethickness}{40}
+\setint{bigopspacing1}{111}
+\setint{bigopspacing2}{167}
+\setint{bigopspacing3}{200}
+\setint{bigopspacing4}{600}
+\setint{bigopspacing5}{100}
+
+
+\begincomment
+\section{Font dimensions}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+\setfontdimen{8}{defaultrulethickness} % default rule thickness
+\setfontdimen{9}{bigopspacing1} % bigopspacing 1
+\setfontdimen{10}{bigopspacing2} % bigopspacing 2
+\setfontdimen{11}{bigopspacing3} % bigopspacing 3
+\setfontdimen{12}{bigopspacing4} % bigopspacing 4
+\setfontdimen{13}{bigopspacing5} % bigopspacing 5
+
+
+\begincomment
+\section{The encoding}
+There are 128 glyphs in this encoding.
+\endcomment
+
+\setslot{parenleftbig}
+ \nextlarger{parenleftBig}
+\endsetslot
+
+\setslot{parenrightbig}
+ \nextlarger{parenrightBig}
+\endsetslot
+
+\setslot{bracketleftbig}
+ \nextlarger{bracketleftBig}
+\endsetslot
+
+\setslot{bracketrightbig}
+ \nextlarger{bracketrightBig}
+\endsetslot
+
+\setslot{floorleftbig}
+ \nextlarger{floorleftBig}
+\endsetslot
+
+\setslot{floorrightbig}
+ \nextlarger{floorrightBig}
+\endsetslot
+
+\setslot{ceilingleftbig}
+ \nextlarger{ceilingleftBig}
+\endsetslot
+
+\setslot{ceilingrightbig}
+ \nextlarger{ceilingrightBig}
+\endsetslot
+
+\setslot{braceleftbig}
+ \nextlarger{braceleftBig}
+\endsetslot
+
+\setslot{bracerightbig}
+ \nextlarger{bracerightBig}
+\endsetslot
+
+\setslot{angleleftbig}
+ \nextlarger{angleleftBig}
+\endsetslot
+
+\setslot{anglerightbig}
+ \nextlarger{anglerightBig}
+\endsetslot
+
+\setslot{barex}
+ \varchar
+ \varrep{barex}
+ \endvarchar
+\endsetslot
+
+\setslot{bardblex}
+ \varchar
+ \varrep{bardblex}
+ \endvarchar
+\endsetslot
+
+\setslot{slashbig}
+ \nextlarger{slashBig}
+\endsetslot
+
+\setslot{backslashbig}
+ \nextlarger{backslashBig}
+\endsetslot
+
+\setslot{parenleftBig}
+ \nextlarger{parenleftbigg}
+\endsetslot
+
+\setslot{parenrightBig}
+ \nextlarger{parenrightbigg}
+\endsetslot
+
+\setslot{parenleftbigg}
+ \nextlarger{parenleftBigg}
+\endsetslot
+
+\setslot{parenrightbigg}
+ \nextlarger{parenrightBigg}
+\endsetslot
+
+\setslot{bracketleftbigg}
+ \nextlarger{bracketleftBigg}
+\endsetslot
+
+\setslot{bracketrightbigg}
+ \nextlarger{bracketrightBigg}
+\endsetslot
+
+\setslot{floorleftbigg}
+ \nextlarger{floorleftBigg}
+\endsetslot
+
+\setslot{floorrightbigg}
+ \nextlarger{floorrightBigg}
+\endsetslot
+
+\setslot{ceilingleftbigg}
+ \nextlarger{ceilingleftBigg}
+\endsetslot
+
+\setslot{ceilingrightbigg}
+ \nextlarger{ceilingrightBigg}
+\endsetslot
+
+\setslot{braceleftbigg}
+ \nextlarger{braceleftBigg}
+\endsetslot
+
+\setslot{bracerightbigg}
+ \nextlarger{bracerightBigg}
+\endsetslot
+
+\setslot{angleleftbigg}
+ \nextlarger{angleleftBigg}
+\endsetslot
+
+\setslot{anglerightbigg}
+ \nextlarger{anglerightBigg}
+\endsetslot
+
+\setslot{slashbigg}
+ \nextlarger{slashBigg}
+\endsetslot
+
+\setslot{backslashbigg}
+ \nextlarger{backslashBigg}
+\endsetslot
+
+\setslot{parenleftBigg}
+ \nextlarger{parenlefttp}
+\endsetslot
+
+\setslot{parenrightBigg}
+ \nextlarger{parenrighttp}
+\endsetslot
+
+\setslot{bracketleftBigg}
+ \nextlarger{bracketlefttp}
+\endsetslot
+
+\setslot{bracketrightBigg}
+ \nextlarger{bracketrighttp}
+\endsetslot
+
+\setslot{floorleftBigg}
+ \nextlarger{bracketleftbt}
+\endsetslot
+
+\setslot{floorrightBigg}
+ \nextlarger{bracketrightbt}
+\endsetslot
+
+\setslot{ceilingleftBigg}
+ \nextlarger{bracketleftex}
+\endsetslot
+
+\setslot{ceilingrightBigg}
+ \nextlarger{bracketrightex}
+\endsetslot
+
+\setslot{braceleftBigg}
+ \nextlarger{bracelefttp}
+\endsetslot
+
+\setslot{bracerightBigg}
+ \nextlarger{bracerighttp}
+\endsetslot
+
+\setslot{angleleftBigg}
+\endsetslot
+
+\setslot{anglerightBigg}
+\endsetslot
+
+\setslot{slashBigg}
+\endsetslot
+
+\setslot{backslashBigg}
+\endsetslot
+
+\setslot{slashBig}
+ \nextlarger{slashbigg}
+\endsetslot
+
+\setslot{backslashBig}
+ \nextlarger{backslashbigg}
+\endsetslot
+
+\setslot{parenlefttp}
+ \varchar
+ \vartop{parenlefttp}
+ \varbot{parenleftbt}
+ \varrep{parenleftex}
+ \endvarchar
+\endsetslot
+
+\setslot{parenrighttp}
+ \varchar
+ \vartop{parenrighttp}
+ \varbot{parenrightbt}
+ \varrep{parenrightex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketlefttp}
+ \varchar
+ \vartop{bracketlefttp}
+ \varbot{bracketleftbt}
+ \varrep{bracketleftex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketrighttp}
+ \varchar
+ \vartop{bracketrighttp}
+ \varbot{bracketrightbt}
+ \varrep{bracketrightex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketleftbt}
+ \varchar
+ \varbot{bracketleftbt}
+ \varrep{bracketleftex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketrightbt}
+ \varchar
+ \varbot{bracketrightbt}
+ \varrep{bracketrightex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketleftex}
+ \varchar
+ \vartop{bracketlefttp}
+ \varrep{bracketleftex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracketrightex}
+ \varchar
+ \vartop{bracketrighttp}
+ \varrep{bracketrightex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracelefttp}
+ \varchar
+ \vartop{bracelefttp}
+ \varmid{braceleftmid}
+ \varbot{braceleftbt}
+ \varrep{braceex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracerighttp}
+ \varchar
+ \vartop{bracerighttp}
+ \varmid{bracerightmid}
+ \varbot{bracerightbt}
+ \varrep{braceex}
+ \endvarchar
+\endsetslot
+
+\setslot{braceleftbt}
+ \varchar
+ \vartop{bracelefttp}
+ \varbot{braceleftbt}
+ \varrep{braceex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracerightbt}
+ \varchar
+ \vartop{bracerighttp}
+ \varbot{bracerightbt}
+ \varrep{braceex}
+ \endvarchar
+\endsetslot
+
+\setslot{braceleftmid}
+ \varchar
+ \varrep{arrowvertex}
+ \comment{This extensible entry has nothing to do with the
+ \texttt{braceleftmid} glyph; instead this slot is used as a
+ placeholder for the large form of the `\(\arrowvert\)'
+ delimiter.}
+ \endvarchar
+\endsetslot
+
+\setslot{bracerightmid}
+ \varchar
+ \varrep{arrowvertexdbl}
+ \comment{This extensible entry has nothing to do with the
+ \texttt{bracerightmid} glyph; instead this slot is used as a
+ placeholder for the large form of the `\(\Arrowvert\)'
+ delimiter.}
+ \endvarchar
+\endsetslot
+
+\setslot{braceex}
+ \varchar
+ \varrep{braceex}
+ \endvarchar
+\endsetslot
+
+\setslot{arrowvertex}
+ \varchar
+ \vartop{arrowtp}
+ \varbot{arrowbt}
+ \varrep{arrowvertex}
+ \endvarchar
+\endsetslot
+
+\setslot{parenleftbt}
+ \varchar
+ \vartop{bracelefttp}
+ \varbot{bracerightbt}
+ \varrep{braceex}
+ \endvarchar
+\endsetslot
+
+\setslot{parenrightbt}
+ \varchar
+ \vartop{bracerighttp}
+ \varbot{braceleftbt}
+ \varrep{braceex}
+ \endvarchar
+\endsetslot
+
+\setslot{parenleftex}
+ \varchar
+ \varrep{parenleftex}
+ \endvarchar
+\endsetslot
+
+\setslot{parenrightex}
+ \varchar
+ \varrep{parenrightex}
+ \endvarchar
+\endsetslot
+
+\setslot{angleleftBig}
+ \nextlarger{angleleftbigg}
+\endsetslot
+
+\setslot{anglerightBig}
+ \nextlarger{anglerightbigg}
+\endsetslot
+
+\setslot{unionsqtext}
+ \nextlarger{unionsqdisplay}
+\endsetslot
+
+\setslot{unionsqdisplay}
+\endsetslot
+
+\setslot{contintegraltext}
+ \nextlarger{contintegraldisplay}
+\endsetslot
+
+\setslot{contintegraldisplay}
+\endsetslot
+
+\setslot{circledottext}
+ \nextlarger{circledotdisplay}
+\endsetslot
+
+\setslot{circledotdisplay}
+\endsetslot
+
+\setslot{circleplustext}
+ \nextlarger{circleplusdisplay}
+\endsetslot
+
+\setslot{circleplusdisplay}
+\endsetslot
+
+\setslot{circlemultiplytext}
+ \nextlarger{circlemultiplydisplay}
+\endsetslot
+
+\setslot{circlemultiplydisplay}
+\endsetslot
+
+\setslot{summationtext}
+ \nextlarger{summationdisplay}
+\endsetslot
+
+\setslot{producttext}
+ \nextlarger{productdisplay}
+\endsetslot
+
+\setslot{integraltext}
+ \nextlarger{integraldisplay}
+\endsetslot
+
+\setslot{uniontext}
+ \nextlarger{uniondisplay}
+\endsetslot
+
+\setslot{intersectiontext}
+ \nextlarger{intersectiondisplay}
+\endsetslot
+
+\setslot{unionmultitext}
+ \nextlarger{unionmultidisplay}
+\endsetslot
+
+\setslot{logicalandtext}
+ \nextlarger{logicalanddisplay}
+\endsetslot
+
+\setslot{logicalortext}
+ \nextlarger{logicalordisplay}
+\endsetslot
+
+\setslot{summationdisplay}
+\endsetslot
+
+\setslot{productdisplay}
+\endsetslot
+
+\setslot{integraldisplay}
+\endsetslot
+
+\setslot{uniondisplay}
+\endsetslot
+
+\setslot{intersectiondisplay}
+\endsetslot
+
+\setslot{unionmultidisplay}
+\endsetslot
+
+\setslot{logicalanddisplay}
+\endsetslot
+
+\setslot{logicalordisplay}
+\endsetslot
+
+\setslot{coproducttext}
+ \nextlarger{coproductdisplay}
+\endsetslot
+
+\setslot{coproductdisplay}
+\endsetslot
+
+\setslot{hatwide}
+ \nextlarger{hatwider}
+\endsetslot
+
+\setslot{hatwider}
+ \nextlarger{hatwidest}
+\endsetslot
+
+\setslot{hatwidest}
+\endsetslot
+
+\setslot{tildewide}
+ \nextlarger{tildewider}
+\endsetslot
+
+\setslot{tildewider}
+ \nextlarger{tildewidest}
+\endsetslot
+
+\setslot{tildewidest}
+\endsetslot
+
+\setslot{bracketleftBig}
+ \nextlarger{bracketleftbigg}
+\endsetslot
+
+\setslot{bracketrightBig}
+ \nextlarger{bracketrightbigg}
+\endsetslot
+
+\setslot{floorleftBig}
+ \nextlarger{floorleftbigg}
+\endsetslot
+
+\setslot{floorrightBig}
+ \nextlarger{floorrightbigg}
+\endsetslot
+
+\setslot{ceilingleftBig}
+ \nextlarger{ceilingleftbigg}
+\endsetslot
+
+\setslot{ceilingrightBig}
+ \nextlarger{ceilingrightbigg}
+\endsetslot
+
+\setslot{braceleftBig}
+ \nextlarger{braceleftbigg}
+\endsetslot
+
+\setslot{bracerightBig}
+ \nextlarger{bracerightbigg}
+\endsetslot
+
+\setslot{radicalbig}
+ \nextlarger{radicalBig}
+\endsetslot
+
+\setslot{radicalBig}
+ \nextlarger{radicalbigg}
+\endsetslot
+
+\setslot{radicalbigg}
+ \nextlarger{radicalBigg}
+\endsetslot
+
+\setslot{radicalBigg}
+ \nextlarger{radicalbt}
+\endsetslot
+
+\setslot{radicalbt}
+ \varchar
+ \varbot{radicalbt}
+ \vartop{radicaltp}
+ \varrep{radicalvertex}
+ \endvarchar
+\endsetslot
+
+\setslot{radicalvertex}
+\endsetslot
+
+\setslot{radicaltp}
+\endsetslot
+
+\setslot{arrowvertexdbl}
+ \varchar
+ \vartop{arrowdbltp}
+ \varbot{arrowdblbt}
+ \varrep{arrowvertexdbl}
+ \endvarchar
+\endsetslot
+
+\setslot{arrowtp}
+ \varchar
+ \vartop{arrowtp}
+ \varrep{arrowvertex}
+ \endvarchar
+\endsetslot
+
+\setslot{arrowbt}
+ \varchar
+ \varbot{arrowbt}
+ \varrep{arrowvertex}
+ \endvarchar
+\endsetslot
+
+\setslot{bracehtipdownleft}
+\endsetslot
+
+\setslot{bracehtipdownright}
+\endsetslot
+
+\setslot{bracehtipupleft}
+\endsetslot
+
+\setslot{bracehtipupright}
+\endsetslot
+
+\setslot{arrowdbltp}
+ \varchar
+ \vartop{arrowdbltp}
+ \varrep{arrowvertexdbl}
+ \endvarchar
+\endsetslot
+
+\setslot{arrowdblbt}
+ \varchar
+ \varbot{arrowdblbt}
+ \varrep{arrowvertexdbl}
+ \endvarchar
+\endsetslot
+
+\endencoding
+
+
+\section{Changes}
+
+\parindent=1em
+
+29 Dec 1993, v1.30: Created file.
+
+03 Jan 1994, v1.301:
+Moved from \texttt{ltugboat} to \texttt{article} class.
+
+04 Jan 1994, v1.302:
+Renamed \texttt{loweredradical} to \texttt{radicallow}.
+
+06 Jan 1994, v1.303: Corrected a fontdimen bug.
+
+09 Jan 1994, v1.305: Changed some names to use the same glyph names
+ as Lucida New Math.
+
+10 Oct 1997, v1.306:
+Ulrik Vieth found a bug in the varchar recipe for the
+\texttt{parenrightbt} slot.
+
+10 October 2000, v\,1.915:
+Introduced intermediate variables for fontdimens 8--13.
+Added \texttt{encodingname}. Added glyph examples.
+Markup updates. (LH)
+
+20 November 2000, v\,1.915:
+Changed glyph names \texttt{arrowdblvertex}, \texttt{hatwiderr}, and
+\texttt{tildewiderr} to \texttt{arrowvertexdbl}, \texttt{hatwidest},
+and \texttt{tildewidest} respectively to really use the same names as
+\texttt{texmext.enc} and Lucida New Math. (LH) Reported by Alejandro
+L\'{o}pez-Valencia.
+
+22 November 2000, v\,1.915:
+Added explanations of the \verb|\varchar| entries for
+\texttt{braceleftmid} and \texttt{bracerightmid}. (LH)
+
+27 July 2002, v\,1.921:
+Introduced intermediate variables for fontdimens 1--7.
+Using \verb"\setfontdimen". (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathetx/rsfs.etx b/fonts/utilities/fontinst/inputs/mathetx/rsfs.etx
new file mode 100644
index 0000000000..adfd02dd20
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathetx/rsfs.etx
@@ -0,0 +1,92 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Ulrik Vieth",
+%%% version = "1.801",
+%%% date = "29 June 1998",
+%%% time = "23:57:31 CEST",
+%%% filename = "rsfs.etx",
+%%% email = "vieth@thphy.uni-duesseldorf.de",
+%%% URL = "http://www.thphy.uni-duesseldorf.de/~vieth/",
+%%% checksum = "22539 92 192 2580",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the encoding of Ralph Smith's Formal
+%%% Script font as a TeX font encoding file, for
+%%% use with the fontinst utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\useexamplefont{rsfs10}
+
+\title{Ralph Smith's Formal Script font encoding vector}
+\author{Ulrik Vieth}
+
+\begin{document}
+\maketitle
+
+\encoding
+
+\comment{\section{Default values}}
+
+\setstr{codingscheme}{RAS SCRIPT}
+\setint{italicslant}{707}
+\setint{xheight}{233}
+
+\comment{\section{Default font dimensions}}
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{0} % interword space
+\setint{fontdimen(3)}{0} % interword stretch
+\setint{fontdimen(4)}{0} % interword shrink
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\setint{fontdimen(7)}{0} % extra space after .
+
+\comment{\section{The encoding}}
+
+\nextslot{65}
+\setslotcomment{The Script letter `\slotexample'.}
+
+\setslot{A}\endsetslot
+\setslot{B}\endsetslot
+\setslot{C}\endsetslot
+\setslot{D}\endsetslot
+\setslot{E}\endsetslot
+\setslot{F}\endsetslot
+\setslot{G}\endsetslot
+\setslot{H}\endsetslot
+\setslot{I}\endsetslot
+\setslot{J}\endsetslot
+\setslot{K}\endsetslot
+\setslot{L}\endsetslot
+\setslot{M}\endsetslot
+\setslot{N}\endsetslot
+\setslot{O}\endsetslot
+\setslot{P}\endsetslot
+\setslot{Q}\endsetslot
+\setslot{R}\endsetslot
+\setslot{S}\endsetslot
+\setslot{T}\endsetslot
+\setslot{U}\endsetslot
+\setslot{V}\endsetslot
+\setslot{W}\endsetslot
+\setslot{X}\endsetslot
+\setslot{Y}\endsetslot
+\setslot{Z}\endsetslot
+
+\nextslot{127}
+\unsetslotcomment
+
+\setslot{tie}
+ \comment{The skewchar.}
+\endsetslot
+
+\endencoding
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathmtx/mathex.mtx b/fonts/utilities/fontinst/inputs/mathmtx/mathex.mtx
new file mode 100644
index 0000000000..73170fa7cf
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathmtx/mathex.mtx
@@ -0,0 +1,303 @@
+%%%========================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey and Lars Hellstr{\"o}m",
+%%% version = "1.915",
+%%% date = "20 November 2000",
+%%% time = "17:01:00 CEST",
+%%% filename = "mathex.mtx",
+%%% checksum = "",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "These are the extra glyphs needed for TeX
+%%% math fonts, used by the fontinst package.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%%========================================================================
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\title{The \texttt{fontinst} math symbol glyphs}
+\author{Alan Jeffrey\and Lars Hellstr\"om}
+\date{November 20, 2000}
+
+\showbranches
+
+\begin{document}
+
+\maketitle
+
+\section{Introduction}
+
+This document describes the glyphs used by the \texttt{fontinst}
+package when generating math symbol fonts.
+
+\metrics
+
+% Uses the fontinst package.
+
+\needsfontinstversion{1.900}
+
+
+% \unfakable is a glyph which can't be faked.
+\setcommand\unfakable#1{
+ \setglyph{#1}
+ \glyphrule{500}{500}
+ \glyphwarning{missing glyph `#1'}
+ \endsetglyph
+}
+\begincomment\medskip
+An \textbf{Unfakable} is a glyph which can't be faked. An
+``\textbf{Unfakable `\#1'}\,'' is equivalent to
+\begin{quotation}\unfakable{\#1}\end{quotation}
+
+\resetcommand\unfakable#1{\Aheading{Unfakable `#1'}}
+\endcomment
+
+
+% \extensible and \vextensible define a number of extensible glyphs.
+\setcommand\extensible#1{
+ \begincomment
+ \subsection{The `#1' extensible}%
+ \endcomment
+ \unfakable{#1}
+ \unfakable{#1tp}
+ \unfakable{#1mid}
+ \unfakable{#1bt}
+ \unfakable{#1ex}
+ \setglyph{#1big} \glyph{#1}{1000} \endsetglyph
+ \setglyph{#1Big} \glyph{#1big}{1000} \endsetglyph
+ \setglyph{#1bigg} \glyph{#1Big}{1000} \endsetglyph
+ \setglyph{#1Bigg} \glyph{#1bigg}{1000} \endsetglyph
+}
+
+\setcommand\vextensible#1{
+ \begincomment
+ \subsection{The `#1' extensible}%
+ \endcomment
+ \unfakable{#1}
+ \unfakable{#1tp}
+ \unfakable{#1mid}
+ \unfakable{#1bt}
+ \unfakable{#1vertex}
+ \setglyph{#1big} \glyph{#1}{1000} \endsetglyph
+ \setglyph{#1Big} \glyph{#1big}{1000} \endsetglyph
+ \setglyph{#1bigg} \glyph{#1Big}{1000} \endsetglyph
+ \setglyph{#1Bigg} \glyph{#1bigg}{1000} \endsetglyph
+}
+
+% \wideaccent defines a wide accent.
+\setcommand\wideaccent#1{
+ \begincomment
+ \subsection{The `#1' wide accents}%
+ \endcomment
+ \unfakable{#1}
+ \setglyph{#1wide} \glyph{#1}{1000} \endsetglyph
+ \setglyph{#1wider} \glyph{#1wide}{1000} \endsetglyph
+ \setglyph{#1widest} \glyph{#1wider}{1000} \endsetglyph
+}
+
+\comment{\textit{displayoperatorscale} is the difference in scale
+between a big and a display operator, exept for integrals, which have
+their own scale.}
+\setint{displayoperatorscale}{1200}
+\setint{integralscale}{1728}
+
+\ifisglyph{product}\then
+ \setint{textoperatorsize}{
+ \add{\height{product}}{\depth{product}}
+ }
+\Else
+ \setint{textoperatorsize}{1000}
+ % Default taken from cmex10.
+\Fi
+
+% \integral, \bigoperator and \biggoperator define operators.
+
+\setcommand\integral#1{
+ \begincomment
+ \subsection{The `#1' integrals}%
+ \endcomment
+ \unfakable{#1}
+ \setglyph{#1text} \glyph{#1}{1000} \endsetglyph
+ \setglyph{#1display} \glyph{#1text}{\int{integralscale}} \endsetglyph
+}
+
+\setcommand\bigoperator#1{
+ \begincomment
+ \subsection{The `#1' big operators}%
+ \endcomment
+ \unfakable{#1}
+ \setglyph{#1text} \glyph{#1}{1000} \endsetglyph
+ \setglyph{#1display} \glyph{#1text}{\int{displayoperatorscale}} \endsetglyph
+}
+
+\setcommand\biggoperator#1{
+ \begincomment
+ \subsection{The `#1' big operators}%
+ \endcomment
+ \unfakable{#1}
+ \setglyph{#1text}
+ \glyph{#1}{
+ \div{\mul{1000}{\int{textoperatorsize}}}
+ {\add{\height{#1}}{\depth{#1}}}
+ }
+ \endsetglyph
+ \setglyph{#1display}
+ \glyph{#1text}{\int{displayoperatorscale}}
+ \endsetglyph
+}
+
+
+\begincomment
+\section{Math extension glyphs}
+\endcomment
+
+\unfakable{bracketleftbt}
+\unfakable{bracketrightbt}
+\unfakable{bracketlefttp}
+\unfakable{bracketrighttp}
+
+\setglyph{floorleft}
+ \glyph{bracketleftbt}{1000}
+\endsetglyph
+
+\setglyph{floorright}
+ \glyph{bracketrightbt}{1000}
+\endsetglyph
+
+\setglyph{ceilingleft}
+ \glyph{bracketlefttp}{1000}
+\endsetglyph
+
+\setglyph{ceilingright}
+ \glyph{bracketrighttp}{1000}
+\endsetglyph
+
+\setglyph{bardbl}
+ \glyph{bar}{1000}
+ \glyph{bar}{1000}
+\endsetglyph
+
+\setglyph{barex}
+ \glyph{bar}{1000}
+\endsetglyph
+
+\setglyph{bardblex}
+ \glyph{bardbl}{1000}
+\endsetglyph
+
+\setglyph{arrowtp}
+ \glyph{arrowup}{1000}
+\endsetglyph
+
+\setglyph{arrowbt}
+ \glyph{arrowdown}{1000}
+\endsetglyph
+
+\setglyph{arrowdbltp}
+ \glyph{arrowdblup}{1000}
+\endsetglyph
+
+\setglyph{arrowdblbt}
+ \glyph{arrowdbldown}{1000}
+\endsetglyph
+
+\unfakable{tilde}
+
+\setglyph{hat}
+ \glyph{circumflex}{1000}
+\endsetglyph
+
+\unfakable{plus}
+\unfakable{union}
+
+\setglyph{unionmulti}
+ \push
+ \movert{\div{\sub{\width{union}}{\scale{\width{plus}}{700}}}{2}}
+ \moveup{\div{\width{plus}}{4}}
+ \glyph{plus}{700}
+ \pop
+ \glyph{union}{1000}
+\endsetglyph
+
+\extensible{parenleft}
+\extensible{parenright}
+\extensible{bracketleft}
+\extensible{bracketright}
+\extensible{braceleft}
+\extensible{braceright}
+\extensible{floorleft}
+\extensible{floorright}
+\extensible{ceilingleft}
+\extensible{ceilingright}
+\extensible{slash}
+\extensible{backslash}
+\extensible{angleleft}
+\extensible{angleright}
+
+\wideaccent{hat}
+\wideaccent{tilde}
+
+\vextensible{radical}
+\vextensible{arrow}
+\extensible{arrowdbl}
+\unfakable{arrowvertexdbl}
+
+\biggoperator{unionsq}
+\biggoperator{circledot}
+\biggoperator{circleplus}
+\biggoperator{circlemultiply}
+\biggoperator{unionmulti}
+\biggoperator{intersection}
+\biggoperator{union}
+\biggoperator{logicaland}
+\biggoperator{logicalor}
+
+\bigoperator{product}
+\bigoperator{summation}
+\bigoperator{coproduct}
+
+\integral{integral}
+\integral{contintegral}
+
+\begincomment
+\subsection{Horizontal braces}
+\endcomment
+
+\unfakable{bracehtipdownleft}
+\unfakable{bracehtipdownright}
+\unfakable{bracehtipupleft}
+\unfakable{bracehtipupright}
+
+\endmetrics
+
+
+\section{Changes}
+
+29 Dec 1993, v1.30: Created file.
+
+3 Jan 1994, v1.301: Renamed some of the glyphs, added fakes for
+\texttt{arrowverttp} and friends.
+
+8 Jan 1994, v1.304: Renamed \texttt{similareq} to \texttt{similarequal}.
+
+9 Jan 1994, v1.305: Renamed some glyphs to use the same names as Lucida
+New Math.
+
+16 October 2000, v\,1.915: Updated markup (made it a \LaTeXe\
+document!). (LH)
+
+20 November 2000, v\,1.915: Added test for whether the \texttt{product}
+glyph exists before setting the \textit{textoperatorsize}, using
+value corresponding to \texttt{cmex10} if it doesn't. Changed
+\verb|\wideaccent| to call the widest glyph \textellipsis\texttt{widest}
+instead of \textellipsis\texttt{widerr}. Changed glyph name
+\texttt{arrowdblvertex} to \texttt{arrowvertexdbl}. (LH) Reported by
+Alejandro L\'{o}pez-Valencia.
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/mathmtx/mathit.mtx b/fonts/utilities/fontinst/inputs/mathmtx/mathit.mtx
new file mode 100644
index 0000000000..67b7250378
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathmtx/mathit.mtx
@@ -0,0 +1,280 @@
+%%%========================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey",
+%%% version = "1.915",
+%%% date = "16 October 2000",
+%%% time = "17:30:00 CEST",
+%%% filename = "mathit.mtx",
+%%% checksum = "",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "These are the extra glyphs needed for TeX
+%%% math italic fonts, used by the fontinst package.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, ltugboat.sty",
+%%% }
+%%%========================================================================
+\relax
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\title{The \texttt{fontinst} math italic glyphs}
+\author{Alan Jeffrey}
+\date{9 January 1994}
+
+%\address{School of Cognitive and Computing Sciences \\
+% University of Sussex \\
+% Falmer \\
+% Brighton \\
+% BN1 9QH \\
+% UK}
+%\netaddress{alanje@cogs.susx.ac.uk}
+
+\begin{document}
+
+\maketitle
+
+\section{Introduction}
+
+This document describes the glyphs used by the \texttt{fontinst}
+package when generating math italic fonts.
+
+
+\metrics
+
+% Uses the fontinst package.
+
+\needsfontinstversion{1.30}
+
+% \unfakable is a glyph which can't be faked.
+
+\setcommand\unfakable#1{
+ \setglyph{#1}
+ \glyphrule{500}{500}
+ \glyphwarning{missing glyph `#1'}
+ \endsetglyph
+}
+
+\comment{\section{Math symbol glyphs}}
+
+\unfakable{Gamma}
+\unfakable{Delta}
+\unfakable{Theta}
+\unfakable{Lambda}
+\unfakable{Xi}
+\unfakable{Pi}
+\unfakable{Sigma}
+\unfakable{Phi}
+\unfakable{Psi}
+\unfakable{Omega}
+\unfakable{alpha}
+\unfakable{beta}
+\unfakable{gamma}
+\unfakable{delta}
+\unfakable{zeta}
+\unfakable{eta}
+\unfakable{theta}
+\unfakable{iota}
+\unfakable{kappa}
+\unfakable{lambda}
+\unfakable{mu}
+\unfakable{nu}
+\unfakable{xi}
+\unfakable{pi}
+\unfakable{rho}
+\unfakable{sigma}
+\unfakable{tau}
+\unfakable{upsilon}
+\unfakable{phi}
+\unfakable{chi}
+\unfakable{psi}
+\unfakable{omega}
+\unfakable{epsilon}
+\unfakable{harpoonleftup}
+\unfakable{harpoonleftdown}
+\unfakable{harpoonrightup}
+\unfakable{harpoonrightdown}
+\unfakable{hookrightchar}
+\unfakable{hookleftchar}
+\unfakable{triangleright}
+\unfakable{triangleleft}
+\unfakable{period}
+\unfakable{comma}
+\unfakable{less}
+\unfakable{slash}
+\unfakable{greater}
+\unfakable{star}
+\unfakable{partialdiff}
+\unfakable{A}
+\unfakable{B}
+\unfakable{C}
+\unfakable{D}
+\unfakable{E}
+\unfakable{F}
+\unfakable{G}
+\unfakable{H}
+\unfakable{I}
+\unfakable{J}
+\unfakable{K}
+\unfakable{L}
+\unfakable{M}
+\unfakable{N}
+\unfakable{O}
+\unfakable{P}
+\unfakable{Q}
+\unfakable{R}
+\unfakable{S}
+\unfakable{T}
+\unfakable{U}
+\unfakable{V}
+\unfakable{W}
+\unfakable{X}
+\unfakable{Y}
+\unfakable{Z}
+\unfakable{flat}
+\unfakable{sharp}
+\unfakable{natural}
+\unfakable{slurabove}
+\unfakable{slurbelow}
+\unfakable{lscript}
+\unfakable{a}
+\unfakable{b}
+\unfakable{c}
+\unfakable{d}
+\unfakable{e}
+\unfakable{f}
+\unfakable{g}
+\unfakable{h}
+\unfakable{i}
+\unfakable{j}
+\unfakable{k}
+\unfakable{l}
+\unfakable{m}
+\unfakable{n}
+\unfakable{o}
+\unfakable{p}
+\unfakable{q}
+\unfakable{r}
+\unfakable{s}
+\unfakable{t}
+\unfakable{u}
+\unfakable{v}
+\unfakable{w}
+\unfakable{x}
+\unfakable{y}
+\unfakable{z}
+\unfakable{dotlessi}
+\unfakable{dotlessj}
+\unfakable{weierstrass}
+\unfakable{tie}
+
+\unfakable{Upsilon}
+\setglyph{Upsilon1}
+ \glyph{Upsilon}{1000}
+\endsetglyph
+
+\setglyph{epsilon1}
+ \glyph{epsilon}{1000}
+\endsetglyph
+
+\setglyph{theta1}
+ \glyph{theta}{1000}
+\endsetglyph
+
+\setglyph{pi1}
+ \ifisglyph{omega1}\then
+ \glyph{omega1}{1000}
+ \else
+ \glyph{pi}{1000}
+ \fi
+\endsetglyph
+
+\setglyph{rho1}
+ \glyph{rho}{1000}
+\endsetglyph
+
+\setglyph{sigma1}
+ \glyph{sigma}{1000}
+\endsetglyph
+
+\setglyph{phi1}
+ \glyph{phi}{1000}
+\endsetglyph
+
+\unfakable{zero}
+\unfakable{one}
+\unfakable{two}
+\unfakable{three}
+\unfakable{four}
+\unfakable{five}
+\unfakable{six}
+\unfakable{seven}
+\unfakable{eight}
+\unfakable{nine}
+
+\setglyph{zerooldstyle}
+ \glyph{zero}{1000}
+\endsetglyph
+
+\setglyph{oneoldstyle}
+ \glyph{one}{1000}
+\endsetglyph
+
+\setglyph{twooldstyle}
+ \glyph{two}{1000}
+\endsetglyph
+
+\setglyph{threeoldstyle}
+ \glyph{three}{1000}
+\endsetglyph
+
+\setglyph{fouroldstyle}
+ \glyph{four}{1000}
+\endsetglyph
+
+\setglyph{fiveoldstyle}
+ \glyph{five}{1000}
+\endsetglyph
+
+\setglyph{sixoldstyle}
+ \glyph{six}{1000}
+\endsetglyph
+
+\setglyph{sevenoldstyle}
+ \glyph{seven}{1000}
+\endsetglyph
+
+\setglyph{eightoldstyle}
+ \glyph{eight}{1000}
+\endsetglyph
+
+\setglyph{nineoldstyle}
+ \glyph{nine}{1000}
+\endsetglyph
+
+\unfakable{arrowright}
+
+\setglyph{vector}
+ \moveup{\int{xheight}}
+ \glyph{arrowright}{500}
+ \moveup{\neg{\int{xheight}}}
+\endsetglyph
+
+\endmetrics
+
+
+\section{Changes}
+
+29 Dec 1993, v1.30: Created file.
+
+3 Jan 1994, v1.301: Renamed \texttt{neutral} to \texttt{natural}.
+
+9 Jan 1994, v1.305:
+Renamed some glyphs to use the same names as Lucida New Math.
+
+16 October 2000, v\,1.915:
+Updated markup (made it a \LaTeXe\ document!). (LH)
+
+\end{document} \ No newline at end of file
diff --git a/fonts/utilities/fontinst/inputs/mathmtx/mathsy.mtx b/fonts/utilities/fontinst/inputs/mathmtx/mathsy.mtx
new file mode 100644
index 0000000000..30737d2a07
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/mathmtx/mathsy.mtx
@@ -0,0 +1,313 @@
+%%%========================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Alan Jeffrey",
+%%% version = "1.915",
+%%% date = "26 October 2000",
+%%% time = "11:36:00 CEST",
+%%% filename = "mathex.mtx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "These are the extra glyphs needed for TeX
+%%% math extension fonts, used by the fontinst
+%%% package.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%%========================================================================
+\relax
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[1999/11/04]
+
+\title{The \texttt{fontinst} math symbol glyphs}
+\author{Alan Jeffrey}
+\date{January 10, 1994}
+% \address{School of Cognitive and Computing Sciences \\
+% University of Sussex \\
+% Falmer \\
+% Brighton \\
+% BN1 9QH \\
+% UK}
+% \netaddress{alanje@cogs.susx.ac.uk}
+
+\begin{document}
+
+\maketitle
+
+\section{Introduction}
+
+This document describes the glyphs used by the \texttt{fontinst}
+package when generating math symbol fonts.
+
+\raggedright
+
+\metrics
+
+% Uses the fontinst package.
+
+\needsfontinstversion{1.900}
+
+% \unfakable is a glyph which can't be faked.
+
+\setcommand\unfakable#1{
+ \setglyph{#1}
+ \glyphrule{500}{500}
+ \glyphwarning{missing glyph `#1'}
+ \endsetglyph
+}
+
+\begincomment
+\section{Math symbol glyphs}
+\endcomment
+
+\unfakable{minus}
+\unfakable{periodcentered}
+\unfakable{multiply}
+\unfakable{asteriskmath}
+\unfakable{divide}
+\unfakable{diamondmath}
+\unfakable{plusminus}
+\unfakable{minusplus}
+\unfakable{circleplus}
+\unfakable{circleminus}
+\unfakable{circlemultiply}
+\unfakable{circledivide}
+\unfakable{circledot}
+\unfakable{circlecopyrt}
+\unfakable{bullet}
+\unfakable{equivasymptotic}
+\unfakable{equivalence}
+\unfakable{reflexsubset}
+\unfakable{reflexsuperset}
+\unfakable{lessequal}
+\unfakable{greaterequal}
+\unfakable{precedesequal}
+\unfakable{followsequal}
+\unfakable{similar}
+\unfakable{approxequal}
+\unfakable{propersubset}
+\unfakable{propersuperset}
+\unfakable{curlyless}
+\unfakable{curlygreater}
+\unfakable{arrowleft}
+\unfakable{arrowright}
+\unfakable{arrowup}
+\unfakable{arrowdown}
+\unfakable{arrowboth}
+\unfakable{arrownortheast}
+\unfakable{arrowsoutheast}
+\unfakable{similarequal}
+\unfakable{arrowdblleft}
+\unfakable{arrowdblright}
+\unfakable{arrowdblup}
+\unfakable{arrowdbldown}
+\unfakable{arrowdblboth}
+\unfakable{arrownorthwest}
+\unfakable{arrowsouthwest}
+\unfakable{proportional}
+\unfakable{infinity}
+\unfakable{element}
+\unfakable{owner}
+\unfakable{triangle}
+\unfakable{triangleinv}
+\unfakable{slash}
+\unfakable{mapstochar}
+\unfakable{universal}
+\unfakable{existential}
+\unfakable{logicalnot}
+\unfakable{emptyset}
+\unfakable{Rfraktur}
+\unfakable{Ifraktur}
+\unfakable{perpendicular}
+\unfakable{latticetop}
+\unfakable{aleph}
+\unfakable{A}
+\unfakable{B}
+\unfakable{C}
+\unfakable{D}
+\unfakable{E}
+\unfakable{F}
+\unfakable{G}
+\unfakable{H}
+\unfakable{I}
+\unfakable{J}
+\unfakable{K}
+\unfakable{L}
+\unfakable{M}
+\unfakable{N}
+\unfakable{O}
+\unfakable{P}
+\unfakable{Q}
+\unfakable{R}
+\unfakable{S}
+\unfakable{T}
+\unfakable{U}
+\unfakable{V}
+\unfakable{W}
+\unfakable{X}
+\unfakable{Y}
+\unfakable{Z}
+\unfakable{union}
+\unfakable{intersection}
+\unfakable{logicaland}
+\unfakable{logicalor}
+\unfakable{turnstileleft}
+\unfakable{turnstileright}
+\unfakable{braceleft}
+\unfakable{braceright}
+\unfakable{angleleft}
+\unfakable{angleright}
+\unfakable{bar}
+\unfakable{arrowbothv}
+\unfakable{arrowdblbothv}
+\unfakable{backslash}
+\unfakable{wreathproduct}
+\unfakable{coproduct}
+\unfakable{gradient}
+\unfakable{integral}
+\unfakable{unionsq}
+\unfakable{intersectionsq}
+\unfakable{subsetsqequal}
+\unfakable{supersetsqequal}
+\unfakable{section}
+\unfakable{dagger}
+\unfakable{daggerdbl}
+\unfakable{paragraph}
+\unfakable{club}
+\unfakable{diamond}
+\unfakable{heart}
+\unfakable{spade}
+
+\unfakable{degree}
+
+\setglyph{largedegree}
+ \glyph{degree}{
+ \div{\mul{1000}{\width{bullet}}}{\width{degree}}
+ }
+\endsetglyph
+
+\setglyph{openbullet}
+ \moveup{\sub{\height{bullet}}{\height{largedegree}}}
+ \glyph{largedegree}{1000}
+ \moveup{\sub{\height{largedegree}}{\height{bullet}}}
+\endsetglyph
+
+\unfakable{minute}
+
+\setglyph{prime}
+ \moveup{\sub{\height{bullet}}{\height{largedegree}}}
+ \glyph{minute}{\div{\mul{1000}{\width{bullet}}}{\width{degree}}}
+ \moveup{\sub{\height{largedegree}}{\height{bullet}}}
+\endsetglyph
+
+\unfakable{less}
+\unfakable{greater}
+
+\setglyph{lessmuch}
+ \glyph{less}{1000}
+ \movert{\scale{\width{less}}{-400}}
+ \glyph{less}{1000}
+\endsetglyph
+
+\setglyph{greatermuch}
+ \glyph{greater}{1000}
+ \movert{\scale{\width{greater}}{-400}}
+ \glyph{greater}{1000}
+\endsetglyph
+
+\unfakable{zero}
+
+\setglyph{emptysetstress}
+ \push
+ \movert{
+ \div{\sub{\width{zero}}{\width{slash}}}{2}
+ }
+ \moveup{
+ \div{
+ \sub{
+ \add{\height{zero}}{\depth{slash}}
+ }{
+ \add{\height{slash}}{\depth{zero}}
+ }
+ }{2}
+ }
+ \glyph{slash}{1000}
+ \pop
+ \glyph{zero}{1000}
+\endsetglyph
+
+\setglyph{unionmulti}
+ \push
+ \movert{\div{\sub{\width{union}}{\scale{\width{plus}}{700}}}{2}}
+ \moveup{\div{\width{plus}}{4}}
+ \glyph{plus}{700}
+ \pop
+ \glyph{union}{1000}
+\endsetglyph
+
+\unfakable{bracketleftbt}
+\unfakable{bracketrightbt}
+\unfakable{bracketlefttp}
+\unfakable{bracketrighttp}
+
+\setglyph{floorleft}
+ \glyph{bracketleftbt}{1000}
+\endsetglyph
+
+\setglyph{floorright}
+ \glyph{bracketrightbt}{1000}
+\endsetglyph
+
+\setglyph{ceilingleft}
+ \glyph{bracketlefttp}{1000}
+\endsetglyph
+
+\setglyph{ceilingright}
+ \glyph{bracketrighttp}{1000}
+\endsetglyph
+
+\setglyph{bardbl}
+ \glyph{bar}{1000}
+ \glyph{bar}{1000}
+\endsetglyph
+
+\unfakable{radical}
+\unfakable{radicalex}
+
+\setglyph{radicallow}
+ \moveup{\sub{\add{\height{radicalex}}{\depth{radicalex}}}{\height{radical}}}
+ \glyph{radical}{1000}
+ \moveup{\sub{\height{radical}}{\int{underlinethickness}}}
+\endsetglyph
+
+\setglyph{negationslash}
+ \push
+ \movert{\div{\sub{\width{arrowright}}{\width{slash}}}{2}}
+ \glyph{slash}{1000}
+ \pop
+\endsetglyph
+
+\endmetrics
+
+\section{Changes}
+
+
+29 Dec 1993, v1.30: Created file.
+
+3 Jan 1994, v1.301: Renamed some of the glyphs, added fakes for
+\texttt{arrowverttp} and friends.
+
+8 Jan 1994, v1.304: Renamed \texttt{similareq} to \texttt{similarequal}.
+
+9 Jan 1994, v1.305:
+Renamed some glyphs to use the same names as Lucida New Math.
+
+10 Jan 1994, v1.306: Split \texttt{mathsym.mtx} into \texttt{mathsy.mtx}
+(math symbols) and \texttt{mathex.mtx} (math extensions).
+
+16 October 2000, v\,1.915: Updated markup (made it a \LaTeXe\
+document!). (LH)
+
+\end{document}
+
diff --git a/fonts/utilities/fontinst/inputs/misc/csc2x.tex b/fonts/utilities/fontinst/inputs/misc/csc2x.tex
new file mode 100644
index 0000000000..092840e00d
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/misc/csc2x.tex
@@ -0,0 +1,118 @@
+%%
+%% This is file `csc2x.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% ficonv.dtx (with options: `reglyphfigures,reglyphletters,glyphs')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+%% maintenance team and any individual authors listed elsewhere in
+%% this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%%
+%%% From file: ficonv.dtx
+\renameglyph{Asmall}{a}
+\renameglyph{Bsmall}{b}
+\renameglyph{Csmall}{c}
+\renameglyph{Dsmall}{d}
+\renameglyph{Esmall}{e}
+\renameglyph{Fsmall}{f}
+\renameglyph{Gsmall}{g}
+\renameglyph{Hsmall}{h}
+\renameglyph{Ismall}{i}
+\renameglyph{Jsmall}{j}
+\renameglyph{Ksmall}{k}
+\renameglyph{Lsmall}{l}
+\renameglyph{Msmall}{m}
+\renameglyph{Nsmall}{n}
+\renameglyph{Osmall}{o}
+\renameglyph{Psmall}{p}
+\renameglyph{Qsmall}{q}
+\renameglyph{Rsmall}{r}
+\renameglyph{Ssmall}{s}
+\renameglyph{Tsmall}{t}
+\renameglyph{Usmall}{u}
+\renameglyph{Vsmall}{v}
+\renameglyph{Wsmall}{w}
+\renameglyph{Xsmall}{x}
+\renameglyph{Ysmall}{y}
+\renameglyph{Zsmall}{z}
+\renameglyph{zerooldstyle}{zero}
+\renameglyph{oneoldstyle}{one}
+\renameglyph{twooldstyle}{two}
+\renameglyph{threeoldstyle}{three}
+\renameglyph{fouroldstyle}{four}
+\renameglyph{fiveoldstyle}{five}
+\renameglyph{sixoldstyle}{six}
+\renameglyph{sevenoldstyle}{seven}
+\renameglyph{eightoldstyle}{eight}
+\renameglyph{nineoldstyle}{nine}
+\renameglyph{Acutesmall}{acute}
+\renameglyph{Brevesmall}{breve}
+\renameglyph{Caronsmall}{caron}
+\renameglyph{Cedillasmall}{cedilla}
+\renameglyph{Circumflexsmall}{circumflex}
+\renameglyph{Dieresissmall}{dieresis}
+\renameglyph{Dotaccentsmall}{dotaccent}
+\renameglyph{Gravesmall}{grave}
+\renameglyph{Hungarumlautsmall}{hungarumlaut}
+\renameglyph{Macronsmall}{macron}
+\renameglyph{Ogoneksmall}{ogonek}
+\renameglyph{Ringsmall}{ring}
+\renameglyph{Tildesmall}{tilde}
+\renameglyph{ampersandsmall}{ampersand}
+\renameglyph{centoldstyle}{cent}
+\renameglyph{dollaroldstyle}{dollar}
+\renameglyph{AEsmall}{ae}
+\renameglyph{Ethsmall}{eth}
+\renameglyph{Lslashsmall}{lslash}
+\renameglyph{Oslashsmall}{oslash}
+\renameglyph{OEsmall}{oe}
+\renameglyph{Thornsmall}{thorn}
+\renameglyph{Agravesmall}{agrave}
+\renameglyph{Egravesmall}{egrave}
+\renameglyph{Igravesmall}{igrave}
+\renameglyph{Ogravesmall}{ograve}
+\renameglyph{Ugravesmall}{ugrave}
+\renameglyph{Aacutesmall}{aacute}
+\renameglyph{Eacutesmall}{eacute}
+\renameglyph{Iacutesmall}{iacute}
+\renameglyph{Oacutesmall}{oacute}
+\renameglyph{Uacutesmall}{uacute}
+\renameglyph{Yacutesmall}{yacute}
+\renameglyph{Acircumflexsmall}{acircumflex}
+\renameglyph{Ecircumflexsmall}{ecircumflex}
+\renameglyph{Icircumflexsmall}{icircumflex}
+\renameglyph{Ocircumflexsmall}{ocircumflex}
+\renameglyph{Ucircumflexsmall}{ucircumflex}
+\renameglyph{Atildesmall}{atilde}
+\renameglyph{Ntildesmall}{ntilde}
+\renameglyph{Otildesmall}{otilde}
+\renameglyph{Adieresissmall}{adieresis}
+\renameglyph{Edieresissmall}{edieresis}
+\renameglyph{Idieresissmall}{idieresis}
+\renameglyph{Odieresissmall}{odieresis}
+\renameglyph{Ydieresissmall}{ydieresis}
+\renameglyph{Udieresissmall}{udieresis}
+\renameglyph{Aringsmall}{aring}
+\renameglyph{Ccedillasmall}{ccedilla}
+\renameglyph{Scaronsmall}{scaron}
+\renameglyph{Zcaronsmall}{zcaron}
+\killglyph{dotlessi}
+\renameglyph{FIsmall}{fi}
+\renameglyph{FLsmall}{fl}
+\renameglyph{SSsmall}{germandbls}
+\endinput
+%%
+%% End of file `csc2x.tex'.
diff --git a/fonts/utilities/fontinst/inputs/misc/csckrn2x.tex b/fonts/utilities/fontinst/inputs/misc/csckrn2x.tex
new file mode 100644
index 0000000000..91428e1a4d
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/misc/csckrn2x.tex
@@ -0,0 +1,121 @@
+%%
+%% This is file `csckrn2x.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% ficonv.dtx (with options: `reglyphfigures,reglyphletters')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+%% maintenance team and any individual authors listed elsewhere in
+%% this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%%
+%%% From file: ficonv.dtx
+\renameglyph{Asmall}{a}
+\renameglyph{Bsmall}{b}
+\renameglyph{Csmall}{c}
+\renameglyph{Dsmall}{d}
+\renameglyph{Esmall}{e}
+\renameglyph{Fsmall}{f}
+\renameglyph{Gsmall}{g}
+\renameglyph{Hsmall}{h}
+\renameglyph{Ismall}{i}
+\renameglyph{Jsmall}{j}
+\renameglyph{Ksmall}{k}
+\renameglyph{Lsmall}{l}
+\renameglyph{Msmall}{m}
+\renameglyph{Nsmall}{n}
+\renameglyph{Osmall}{o}
+\renameglyph{Psmall}{p}
+\renameglyph{Qsmall}{q}
+\renameglyph{Rsmall}{r}
+\renameglyph{Ssmall}{s}
+\renameglyph{Tsmall}{t}
+\renameglyph{Usmall}{u}
+\renameglyph{Vsmall}{v}
+\renameglyph{Wsmall}{w}
+\renameglyph{Xsmall}{x}
+\renameglyph{Ysmall}{y}
+\renameglyph{Zsmall}{z}
+\renameglyph{zerooldstyle}{zero}
+\renameglyph{oneoldstyle}{one}
+\renameglyph{twooldstyle}{two}
+\renameglyph{threeoldstyle}{three}
+\renameglyph{fouroldstyle}{four}
+\renameglyph{fiveoldstyle}{five}
+\renameglyph{sixoldstyle}{six}
+\renameglyph{sevenoldstyle}{seven}
+\renameglyph{eightoldstyle}{eight}
+\renameglyph{nineoldstyle}{nine}
+\renameglyph{Acutesmall}{acute}
+\renameglyph{Brevesmall}{breve}
+\renameglyph{Caronsmall}{caron}
+\renameglyph{Cedillasmall}{cedilla}
+\renameglyph{Circumflexsmall}{circumflex}
+\renameglyph{Dieresissmall}{dieresis}
+\renameglyph{Dotaccentsmall}{dotaccent}
+\renameglyph{Gravesmall}{grave}
+\renameglyph{Hungarumlautsmall}{hungarumlaut}
+\renameglyph{Macronsmall}{macron}
+\renameglyph{Ogoneksmall}{ogonek}
+\renameglyph{Ringsmall}{ring}
+\renameglyph{Tildesmall}{tilde}
+\renameglyph{ampersandsmall}{ampersand}
+\renameglyph{centoldstyle}{cent}
+\renameglyph{dollaroldstyle}{dollar}
+\renameglyph{AEsmall}{ae}
+\renameglyph{Ethsmall}{eth}
+\renameglyph{Lslashsmall}{lslash}
+\renameglyph{Oslashsmall}{oslash}
+\renameglyph{OEsmall}{oe}
+\renameglyph{Thornsmall}{thorn}
+\renameglyph{Agravesmall}{agrave}
+\renameglyph{Egravesmall}{egrave}
+\renameglyph{Igravesmall}{igrave}
+\renameglyph{Ogravesmall}{ograve}
+\renameglyph{Ugravesmall}{ugrave}
+\renameglyph{Aacutesmall}{aacute}
+\renameglyph{Eacutesmall}{eacute}
+\renameglyph{Iacutesmall}{iacute}
+\renameglyph{Oacutesmall}{oacute}
+\renameglyph{Uacutesmall}{uacute}
+\renameglyph{Yacutesmall}{yacute}
+\renameglyph{Acircumflexsmall}{acircumflex}
+\renameglyph{Ecircumflexsmall}{ecircumflex}
+\renameglyph{Icircumflexsmall}{icircumflex}
+\renameglyph{Ocircumflexsmall}{ocircumflex}
+\renameglyph{Ucircumflexsmall}{ucircumflex}
+\renameglyph{Atildesmall}{atilde}
+\renameglyph{Ntildesmall}{ntilde}
+\renameglyph{Otildesmall}{otilde}
+\renameglyph{Adieresissmall}{adieresis}
+\renameglyph{Edieresissmall}{edieresis}
+\renameglyph{Idieresissmall}{idieresis}
+\renameglyph{Odieresissmall}{odieresis}
+\renameglyph{Ydieresissmall}{ydieresis}
+\renameglyph{Udieresissmall}{udieresis}
+\renameglyph{Aringsmall}{aring}
+\renameglyph{Ccedillasmall}{ccedilla}
+\renameglyph{Scaronsmall}{scaron}
+\renameglyph{Zcaronsmall}{zcaron}
+\killglyph{dotlessi}
+\killglyph{fi}
+\killglyph{fl}
+\killglyph{germandbls}
+\offmtxcommand\setscaledrawglyph
+\offmtxcommand\setglyph
+\resetcommand\iftokeep#1\then{\ifnum 0<#1}
+\endinput
+%%
+%% End of file `csckrn2x.tex'.
diff --git a/fonts/utilities/fontinst/inputs/misc/glyphbox.mtx b/fonts/utilities/fontinst/inputs/misc/glyphbox.mtx
new file mode 100644
index 0000000000..223504d54e
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/misc/glyphbox.mtx
@@ -0,0 +1,62 @@
+\relax
+
+\documentclass{article}
+\usepackage{fontdoc}
+
+\begin{document}
+
+\title{\texttt{glyphbox.mtx}: showing metric boxes of glyphs}
+\author{Lars Hellstr\"om}
+\date{July 2003}
+\maketitle
+
+\begin{abstract}
+ This file redefines the \verb|\setscaledrawglyph| command to make a
+ thin ($5$ AFM units) frame lining the inside of the metric box of
+ the glyph. This is can be useful when debugging commands for
+ building glyphs, as it gives graphic account of the glyph metrics.
+ Use \verb|\oncommand\setscaledrawglyph| or the \texttt{glyphon.mtx}
+ file to restore the normal command definition.
+\end{abstract}
+
+
+\begin{verbatim}
+
+\metrics
+
+\needsfontinstversion{1.914}
+
+
+\offcommand\setscaledrawglyph
+
+\resetcommand\setscaledrawglyph#1#2#3#4#5#6#7#8#9{%
+ \csname saved-\string\setscaledrawglyph\endcsname
+ {#1/raw}{#2}{#3}{#4}{#5}{#6}{#7}{#8}{#9}%
+ \setglyph{#1}%
+ \push
+ \moveup{\neg{#8}}%
+ \glyphrule{5}{\add{#7}{#8}}%
+ \push
+ \ifnumber{#9}{>}{0}\then
+ \moveup{\add{#7}{#8}}%
+ \glyphrule{\add{\sub{#6}{5}}{#9}}{5}%
+ \else
+ \moveup{\add{#7}{#8}}%
+ \glyphrule{\sub{#6}{10}}{5}%
+ \fi
+ \pop
+ \glyphrule{\sub{#6}{10}}{5}%
+ \glyphrule{5}{\add{#7}{#8}}%
+ \pop
+ \glyph{#1/raw}{1000}%
+ \endsetglyph
+}
+
+
+\endmetrics
+
+
+\end{verbatim}
+
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/misc/glyphoff.mtx b/fonts/utilities/fontinst/inputs/misc/glyphoff.mtx
new file mode 100644
index 0000000000..35c3a28716
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/misc/glyphoff.mtx
@@ -0,0 +1,8 @@
+\relax
+
+\metrics
+
+\offcommand\setscaledrawglyph
+\let\setscaledrawglyph\setscalednotglyph
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/inputs/misc/glyphon.mtx b/fonts/utilities/fontinst/inputs/misc/glyphon.mtx
new file mode 100644
index 0000000000..0746fd1298
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/misc/glyphon.mtx
@@ -0,0 +1,7 @@
+\relax
+
+\metrics
+
+\oncommand\setscaledrawglyph
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/inputs/misc/kernoff.mtx b/fonts/utilities/fontinst/inputs/misc/kernoff.mtx
new file mode 100644
index 0000000000..776011328c
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/misc/kernoff.mtx
@@ -0,0 +1,6 @@
+\relax
+\metrics
+
+\offcommand\setkern
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/inputs/misc/kernon.mtx b/fonts/utilities/fontinst/inputs/misc/kernon.mtx
new file mode 100644
index 0000000000..a864c14242
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/misc/kernon.mtx
@@ -0,0 +1,6 @@
+\relax
+\metrics
+
+\oncommand\setkern
+
+\endmetrics
diff --git a/fonts/utilities/fontinst/inputs/misc/osf2x.tex b/fonts/utilities/fontinst/inputs/misc/osf2x.tex
new file mode 100644
index 0000000000..a9ed8a9866
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/misc/osf2x.tex
@@ -0,0 +1,37 @@
+%%
+%% This is file `osf2x.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% ficonv.dtx (with options: `reglyphfigures,glyphs')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+%% maintenance team and any individual authors listed elsewhere in
+%% this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%%
+%%% From file: ficonv.dtx
+\renameglyph{zerooldstyle}{zero}
+\renameglyph{oneoldstyle}{one}
+\renameglyph{twooldstyle}{two}
+\renameglyph{threeoldstyle}{three}
+\renameglyph{fouroldstyle}{four}
+\renameglyph{fiveoldstyle}{five}
+\renameglyph{sixoldstyle}{six}
+\renameglyph{sevenoldstyle}{seven}
+\renameglyph{eightoldstyle}{eight}
+\renameglyph{nineoldstyle}{nine}
+\endinput
+%%
+%% End of file `osf2x.tex'.
diff --git a/fonts/utilities/fontinst/inputs/smbletx/digit2.etx b/fonts/utilities/fontinst/inputs/smbletx/digit2.etx
new file mode 100644
index 0000000000..4836285400
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/smbletx/digit2.etx
@@ -0,0 +1,10 @@
+\relax
+\encoding
+
+% digit2.etx - This ETX file defines the \digit commands through
+\setcommand\digit#1{#1/2}
+% so that it will append a suffix /2 to the glyph name given.
+% Use this with a "suffix /2" clause in \installfont to select
+% digits from a different font that most of the glyphs.
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/smbletx/ts1.etx b/fonts/utilities/fontinst/inputs/smbletx/ts1.etx
new file mode 100644
index 0000000000..4a28ab1460
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/smbletx/ts1.etx
@@ -0,0 +1,764 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Sebastian Rahtz and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.913",
+%%% date = "2005-05-24",
+%%% time = "15:45:46 +02:00",
+%%% filename = "ts1.etx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.thphy.uni-duesseldorf.de/~vieth/",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is the TS1 encoding as a TeX font encoding
+%%% file, for use with the fontinst utility.
+%%% It implements the TeX text companion encoding.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage[TS1,T1]{fontenc}
+\usepackage{textcomp}
+\usepackage{fontdoc}
+
+\title{The \TeX\ text companion font encoding vector}
+\author{Sebastian Rahtz, Ulrik Vieth}
+\date{29 June 1998 \\
+Version 1.801}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the \TeX{} text companion encoding vector.
+
+\encoding
+\comment{\section{Default values}}
+
+\setstr{codingscheme}{TEX TEXT COMPANION SYMBOLS 1---TS1}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\else
+ \setint{xheight}{500}
+\fi
+
+\ifisglyph{space}\then
+ \setint{interword}{\width{space}}
+\else\ifisglyph{i}\then
+ \setint{interword}{\width{i}}
+\else
+ \setint{interword}{333}
+\fi\fi
+
+\setint{italicslant}{0}
+
+\comment{\section{Default font dimensions}}
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{\int{interword}} % interword space
+\setint{fontdimen(3)}{0} % interword stretch
+\setint{fontdimen(4)}{0} % interword shrink
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\setint{fontdimen(7)}{\int{interword}} % extra space after .
+
+
+\comment{\section{The encoding}}
+
+\nextslot{0}
+\setslot{capitalgrave}
+ \comment{The grave accent `\capitalgrave{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\setslot{capitalacute}
+ \comment{The acute accent `\capitalacute{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\setslot{capitalcircumflex}
+ \comment{The circumflex accent `\capitalcircumflex{}', intended for
+ use with capital letters.}
+\endsetslot
+
+\setslot{capitaltilde}
+ \comment{The tilde accent `\capitaltilde{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\setslot{capitaldieresis}
+ \comment{The umlaut or dieresis accent `\capitaldieresis{}',
+ intended for use with capital letters.}
+\endsetslot
+
+\setslot{capitalhungarumlaut}
+ \comment{The long Hungarian umlaut `\capitalhungarumlaut{}',
+ intended for use with capital letters.}
+\endsetslot
+
+\setslot{capitalring}
+ \comment{The ring accent `\capitalring{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\setslot{capitalcaron}
+ \comment{The caron or h\'a\v cek accent `\capitalcaron{}', intended
+ for use with capital letters.}
+\endsetslot
+
+\setslot{capitalbreve}
+ \comment{The breve accent `\capitalbreve{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\setslot{capitalmacron}
+ \comment{The macron accent `\capitalmacron{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\setslot{capitaldotaccent}
+ \comment{The dot accent `\capitaldotaccent{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\setslot{cedilla}
+ \comment{The cedilla accent `\capitalcedilla{}', intended for use
+ with capital letters.}
+\endsetslot
+
+\setslot{ogonek}
+ \comment{The ogonek accent `\capitalogonek{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\nextslot{13}
+\setslot{quotesinglbase}
+ \comment{A straight single quote mark on the baseline,
+ `\textquotestraightbase'.}
+\endsetslot
+
+\nextslot{18}
+\setslot{quotedblbase}
+ \comment{A straight double quote mark on the baseline,
+ `\textquotestraightdblbase'.}
+\endsetslot
+
+\nextslot{21}
+\setslot{twelveudash}
+ \comment{A 2/3~em dash, `\texttwelveudash'.}
+\endsetslot
+
+\setslot{threequartersemdash}
+ \comment{A 3/4~em dash, `\textthreequartersemdash'.}
+\endsetslot
+
+\nextslot{23}
+\setslot{capitalcompwordmark}
+ \comment{An invisible glyph, with zero width and depth, but the
+ height of capital letters.
+ It is used to stop ligaturing in words like `shelf{}ful'.}
+\endsetslot
+
+\nextslot{24}
+\setslot{arrowleft}
+ \comment{A left pointing arrow, `\textleftarrow', unavailable in
+ most PostScript fonts.}
+\endsetslot
+
+\setslot{arrowright}
+ \comment{A right pointing arrow, `\textrightarrow', unavailable in
+ most PostScript fonts.}
+\endsetslot
+
+\nextslot{26}
+\setslot{tieaccentlowercase}
+ \comment{The original tie accent `\t{}', intended for use with
+ lowercase letters.}
+\endsetslot
+
+\setslot{tieaccentcapital}
+ \comment{The tie accent `\capitaltie{}', intended for use with
+ capital letters.}
+\endsetslot
+
+\setslot{newtieaccentlowercase}
+ \comment{A new tie accent `\newtie{}', intended for use with
+ lowercase letters.}
+\endsetslot
+
+\setslot{newtieaccentcapital}
+ \comment{A new tie accent `\capitalnewtie{}', intended for use
+ with capital letters.}
+\endsetslot
+
+\nextslot{31}
+\setslot{ascendercompwordmark}
+ \comment{An invisible glyph, with zero width and depth, but the
+ height of lowercase letters with ascenders.
+ It is used to stop ligaturing in words like `shelf{}ful'.}
+\endsetslot
+
+\nextslot{32}
+\setslot{blank}
+ \comment{The blank indicator `\textblank', similar to the letter `b'
+ with an oblique bar throgh the stem.}
+\endsetslot
+
+\nextslot{36}
+\setslot{dollar}
+ \comment{The dollar sign `\textdollar'.}
+\endsetslot
+
+\nextslot{39}
+\setslot{quotesingle}
+ \comment{A straight single quote mark, `\textquotesingle'.}
+\endsetslot
+
+\nextslot{42}
+\setslot{asteriskcentered}
+ \comment{The centered asterisk, `\textasteriskcentered'.}
+\endsetslot
+
+\nextslot{44}
+\setslot{comma}
+ \comment{The decimal comma `,'.}
+\endsetslot
+
+\nextslot{45}
+\setslot{hyphendbl}
+ \comment{An alternate double hyphen, `\textdblhyphen'.}
+\endsetslot
+
+\nextslot{46}
+\setslot{period}
+ \comment{The decimal point `.'.}
+\endsetslot
+
+\nextslot{47}
+\setslot{fraction}
+ \comment{The fraction slash `\textfractionsolidus'.}
+\endsetslot
+
+\nextslot{48}
+\setslot{zerooldstyle}
+ \comment{The oldstyle number `\oldstylenums{0}'.}
+\endsetslot
+
+\setslot{oneoldstyle}
+ \comment{The oldstyle number `\oldstylenums{1}'.}
+\endsetslot
+
+\setslot{twooldstyle}
+ \comment{The oldstyle number `\oldstylenums{2}'.}
+\endsetslot
+
+\setslot{threeoldstyle}
+ \comment{The oldstyle number `\oldstylenums{3}'.}
+\endsetslot
+
+\setslot{fouroldstyle}
+ \comment{The oldstyle number `\oldstylenums{4}'.}
+\endsetslot
+
+\setslot{fiveoldstyle}
+ \comment{The oldstyle number `\oldstylenums{5}'.}
+\endsetslot
+
+\setslot{sixoldstyle}
+ \comment{The oldstyle number `\oldstylenums{6}'.}
+\endsetslot
+
+\setslot{sevenoldstyle}
+ \comment{The oldstyle number `\oldstylenums{7}'.}
+\endsetslot
+
+\setslot{eightoldstyle}
+ \comment{The oldstyle number `\oldstylenums{8}'.}
+\endsetslot
+
+\setslot{nineoldstyle}
+ \comment{The oldstyle number `\oldstylenums{9}'.}
+\endsetslot
+
+\nextslot{60}
+\setslot{angbracketleft}
+ \comment{The opening angle bracket `\textlangle', unavailable in
+ most PostScript fonts.}
+\endsetslot
+
+\nextslot{61}
+\setslot{minus}
+ \comment{The subtraction sign `\textminus'.}
+\endsetslot
+
+\nextslot{62}
+\setslot{angbracketright}
+ \comment{The closing angle bracket `\textrangle', unavailable in
+ most PostScript fonts.}
+\endsetslot
+
+\nextslot{77}
+\setslot{Omegainv}
+ \comment{The inverted Ohm sign `\textmho', unavailable in most fonts.}
+\endsetslot
+
+\nextslot{79}
+\setslot{bigcircle}
+ \comment{A circle `\textbigcircle', big enough to enclose a letter
+ as in `\textcopyright' or `\textregistered'.}
+\endsetslot
+
+\nextslot{87}
+\setslot{Omega}
+ \comment{The upright Ohm sign `\textohm', unavailable in most fonts.
+ Even if it is available in Mac-encoded fonts, it isn't directly
+ accessible in the 8r or 8y encodings.}
+\endsetslot
+
+\nextslot{91}
+\setslot{openbracketleft}
+ \comment{The opening double square bracket `\textlbrackdbl',
+ unavailable in most PostScript fonts.}
+\endsetslot
+
+\nextslot{93}
+\setslot{openbracketright}
+ \comment{The closing double square bracket `\textrbrackdbl',
+ unavailable in most PostScript fonts.}
+\endsetslot
+
+\nextslot{94}
+\setslot{arrowup}
+ \comment{An upwards pointing arrow `\textuparrow', unavailable in
+ most PostScript fonts.}
+\endsetslot
+
+\nextslot{95}
+\setslot{arrowdown}
+ \comment{An downwards pointing arrow `\textdownarrow', unavailable
+ in most PostScript fonts.}
+\endsetslot
+
+\nextslot{96}
+\setslot{asciigrave}
+ \comment{An ASCII-style grave `\textasciigrave'. This is supposed
+ to be a character by itself rather than a combining accents.}
+\endsetslot
+
+\nextslot{98}
+\setslot{born}
+ \comment{The born symbol `\textborn', unavailable in most PostScript
+ fonts.}
+\endsetslot
+
+\nextslot{99}
+\setslot{divorced}
+ \comment{The divorced symbol `\textdivorced', unavailable in most
+ PostScript fonts.}
+\endsetslot
+
+\nextslot{100}
+\setslot{died}
+ \comment{The died symbol `\textdied', unavailable in most PostScript
+ fonts.}
+\endsetslot
+
+\nextslot{108}
+\setslot{leaf}
+ \comment{The leaf symbol `\textleaf', unavailable in most PostScript
+ fonts.}
+\endsetslot
+
+\nextslot{109}
+\setslot{married}
+ \comment{The married symbol `\textmarried', unavailable in most
+ PostScript fonts.}
+\endsetslot
+
+\nextslot{110}
+\setslot{musicalnote}
+ \comment{A musical note symbol `\textmusicalnote', unavailable in
+ most PostScript fonts.}
+\endsetslot
+
+\nextslot{126}
+\setslot{tildelow}
+ \comment{A lowered tilde `\texttildelow'. In most PostScript fonts
+ it can be substituted by `asciitilde', while `\textasciitilde'
+ is supposed to be a raised `tilde'.}
+\endsetslot
+
+\nextslot{127}
+\setslot{hyphendblchar}
+ \comment{The glyph used for hyphenation in this font, which will
+ almost always be the same as `hyphendbl'.}
+\endsetslot
+
+\nextslot{128}
+\setslot{asciibreve}
+ \comment{An ASCII-style breve `\textasciibreve'. This is supposed
+ to be a character by itself rather than a combining accents.}
+\endsetslot
+
+\setslot{asciicaron}
+ \comment{An ASCII-style caron `\textasciicaron'. This is supposed
+ to be a character by itself rather than a combining accents.}
+\endsetslot
+
+\setslot{asciiacutedbl}
+ \comment{An ASCII-style double tick mark, `\textacutedbl'.}
+\endsetslot
+
+\setslot{asciigravedbl}
+ \comment{An ASCII-style double backtick mark, `\textgravedbl'.}
+\endsetslot
+
+\setslot{dagger}
+ \comment{The single dagger `\textdagger'.}
+\endsetslot
+
+\setslot{daggerdbl}
+ \comment{The double dagger `\textdaggerdbl'.}
+\endsetslot
+
+\setslot{bardbl}
+ \comment{The double vertical bar `\textbardbl'.}
+\endsetslot
+
+\setslot{perthousand}
+ \comment{The perthousand sign `\textperthousand'.}
+\endsetslot
+
+\setslot{bullet}
+ \comment{The centered bullet `\textbullet'.}
+\endsetslot
+
+\setslot{centigrade}
+ \comment{The degree centigrade symbol `\textcelsius'.}
+\endsetslot
+
+\setslot{dollaroldstyle}
+ \comment{An oldstyle dollar sign `\textdollaroldstyle'.}
+\endsetslot
+
+\setslot{centoldstyle}
+ \comment{An oldstyle cent sign `\textcentoldstyle'.}
+\endsetslot
+
+\setslot{florin}
+ \comment{The florin sign `\textflorin'.}
+\endsetslot
+
+\setslot{colonmonetary}
+ \comment{The Colon currency sign `\textcolonmonetary', similar to
+ a capital `C' with a vertical bar through the middle.}
+\endsetslot
+
+\setslot{won}
+ \comment{The Won currency sign `\textwon', similar to a capital `W'
+ with two horizontal bars.}
+\endsetslot
+
+\setslot{naira}
+ \comment{The Naira currency sign `\textnaira', similar to a
+ capital `N' with two horizontal bars.}
+\endsetslot
+
+\setslot{guarani}
+ \comment{The Guarani currency sign `\textguarani', similar to
+ a capital `G' with a vertical bar through the middle.}
+\endsetslot
+
+\setslot{peso}
+ \comment{The Peso currency sign `\textpeso', similar to a capital `P'
+ with a horizontal bar through the bowl or below the bowl.}
+\endsetslot
+
+\setslot{lira}
+ \comment{The Lira currency sign `\textlira', similar to a sterling
+ sign `\textsterling' with two horizontal bars.}
+\endsetslot
+
+\setslot{recipe}
+ \comment{The recipe symbol `\textrecipe', similar to a capital `R'
+ with an oblique bar through the tail.}
+\endsetslot
+
+\setslot{interrobang}
+ \comment{The interrobang symbol `\textinterrobang', similar to
+ a combination of an exclamation mark and a question mark.}
+\endsetslot
+
+\setslot{interrobangdown}
+ \comment{The inverted interrobang symbol `\textinterrobangdown',
+ similar to a combination of an inverted exclamation mark
+ and an inverted question mark.}
+\endsetslot
+
+\setslot{dong}
+ \comment{The Dong currency sign `\textdong', similar to a lowercase
+ `d' with a horizontal bar through the stem and another bar below
+ the letter.}
+\endsetslot
+
+\setslot{trademark}
+ \comment{The trademark sign `\texttrademark', similar to the raised
+ letters `TM'.}
+\endsetslot
+
+\setslot{pertenthousand}
+ \comment{The pertenthousand sign `\textpertenthousand', unavailable
+ in most PostScript fonts.}
+\endsetslot
+
+\setslot{pilcrow}
+ \comment{The pilcrow mark `\textpilcrow', similar to a paragraph
+ mark `\textparagraph' with a single stem.}
+\endsetslot
+
+\setslot{baht}
+ \comment{The Baht currency sign `\textbaht', similar to a capital `B'
+ with a vertical bar through the middle.}
+\endsetslot
+
+\setslot{numero}
+ \comment{The numero sign `\textnumero', similar to the letter `N'
+ with a raised `o', unavailable in most PostScript fonts.}
+\endsetslot
+
+\setslot{discount}
+ \comment{The discount sign `\textdiscount', similar to a stylized
+ percent sign, unavailable in most PostScript fonts.}
+\endsetslot
+
+\setslot{estimated}
+ \comment{The estimated sign `\textestimated', similar to an enlarged
+ lowercase `e', unavailable in most PostScript fonts.}
+\endsetslot
+
+\setslot{openbullet}
+ \comment{The centered open bullet `\textopenbullet'', unavailable
+ in most PostScript fonts.}
+\endsetslot
+
+\setslot{servicemark}
+ \comment{The service mark sign `\textservicemark', similar to the
+ raised letters `SM', unavailable in most PostScript fonts.}
+\endsetslot
+
+\nextslot{160}
+\setslot{quillbracketleft}
+ \comment{The opening quill bracket `\textlquill', unavailable in
+ most PostScript fonts.}
+\endsetslot
+
+\setslot{quillbracketright}
+ \comment{The closing quill bracket `\textrquill', unavailable in
+ most PostScript fonts.}
+\endsetslot
+
+\setslot{cent}
+ \comment{The cent sign `\textcent'.}
+\endsetslot
+
+\setslot{sterling}
+ \comment{The British currency sign, `\textsterling'.}
+\endsetslot
+
+\setslot{currency}
+ \comment{The international currency sign, `\textcurrency'.}
+\endsetslot
+
+\setslot{yen}
+ \comment{The Japanese currency sign, `\textyen'.}
+\endsetslot
+
+\setslot{brokenbar}
+ \comment{A broken vertical bar, `\textbrokenbar', similar to
+ `\textbar' with a gap through the middle.}
+\endsetslot
+
+\setslot{section}
+ \comment{The section mark `\textsection'.}
+\endsetslot
+
+\setslot{asciidieresis}
+ \comment{An ASCII-style dieresis `\textasciidieresis'. This is
+ supposed to be character by itself rather than an accents.}
+\endsetslot
+
+\setslot{copyright}
+ \comment{The copyright sign `\textcopyright', similar to a small
+ letter `C' enclosed by a circle.}
+\endsetslot
+
+\setslot{ordfeminine}
+ \comment{The raised letter `\textordfeminine'.}
+\endsetslot
+
+\setslot{copyleft}
+ \comment{The reversed copyright sign `\textcopyleft', similar to
+ a small reversed `C' enclosed by a circle.}
+\endsetslot
+
+\setslot{logicalnot}
+ \comment{The logical not sign `\textlnot'.}
+\endsetslot
+
+\setslot{circledP}
+ \comment{A small letter `P' enclosed by a circle, `\textcircledP',
+ unavailable in most fonts.}
+\endsetslot
+
+\setslot{registered}
+ \comment{The registered trademark sign `\textregistered', similar to
+ a small letter `R' enclosed by a circle.}
+\endsetslot
+
+\setslot{asciimacron}
+ \comment{An ASCII-style macron `\textasciimacron'. This is supposed
+ to be a character by itself rather than a combining accents.}
+\endsetslot
+
+\setslot{degree}
+ \comment{The degree sign `\textdegree'.}
+\endsetslot
+
+\setslot{plusminus}
+ \comment{The plus or minus sign `\textpm'.}
+\endsetslot
+
+\setslot{twosuperior}
+ \comment{The raised digit `\texttwosuperior'.}
+\endsetslot
+
+\setslot{threesuperior}
+ \comment{The raised digit `\textthreesuperior'.}
+\endsetslot
+
+\setslot{asciiacute}
+ \comment{An ASCII-style acute `\textasciiacute'. This is supposed
+ to be a character by itself rather than a combining accents.}
+\endsetslot
+
+\setslot{mu}
+ \comment{The lowercase Greek letter `\textmu', intended for use as
+ a prefix `micro' in physical units.}
+\endsetslot
+
+\setslot{paragraph}
+ \comment{The paragraph mark `\textparagraph'.}
+\endsetslot
+
+\setslot{periodcentered}
+ \comment{The centered period `\textperiodcentered'.}
+\endsetslot
+
+\setslot{referencemark}
+ \comment{The reference mark `\textreferencemark', similar to
+ a combination of the `multiply' and `divide' symbols.}
+\endsetslot
+
+\setslot{onesuperior}
+ \comment{The raised digit `\textonesuperior'.}
+\endsetslot
+
+\setslot{ordmasculine}
+ \comment{The raised letter `\textordmasculine'.}
+\endsetslot
+
+\setslot{radical}
+ \comment{The radical sign `\textsurd', unavailable in most fonts.
+ Even if it is available in Mac-encoded fonts, it isn't directly
+ accessible in the 8r or 8y encodings.}
+\endsetslot
+
+\setslot{onequarter}
+ \comment{The fraction `\textonequarter'.}
+\endsetslot
+
+\setslot{onehalf}
+ \comment{The fraction `\textonehalf'.}
+\endsetslot
+
+\setslot{threequarters}
+ \comment{The fraction `\textthreequarters'.}
+\endsetslot
+
+\setslot{euro}
+ \comment{The European currency sign, similar to `\texteuro'.}
+\endsetslot
+
+
+\nextslot{214}
+\setslot{multiply}
+ \comment{The multiplication sign `\texttimes'.
+ This symbol was originally intended to be put into slot~215,
+ but ended up in this slot by mistake, at which time it was
+ considered too late to change it.}
+\endsetslot
+
+\nextslot{246}
+\setslot{divide}
+ \comment{The divison sign `\textdiv'.
+ This symbol was originally intended to be put into slot~247,
+ but ended up in this slot by mistake, at which time it was
+ onsidered too late to change it.}
+\endsetslot
+
+\endencoding
+
+\section{Notes on Euro fonts}
+
+The Euro$($Serif$\mid$Sans$\mid$Mono$)$ fonts downloadable from Adobe use
+the glyph name \texttt{Euro} (in slot 128) and the unencoded glyph
+\texttt{uni20AC}. It remains to be seen, what glyph names future
+releases of new fonts will be using.
+
+The proposed Latin 9 (ISO-8859-15) encoding uses the `\texttt{currency}'
+slot for the Euro sign, and changes a few other Latin 1 slots.
+
+
+\section{Changes}
+
+(UV, 1998/06/08):
+\begin{itemize}
+ \item brought up to symbol complement of EC/TC fonts 1.0,
+ adjusted symbol names to match LaTeX \texttt{ts1enc.def} v\,3.0.
+ \item added \texttt{capitalcompwordmark} and
+ \texttt{ascendercompwordmark}.
+ \item added new variant tie accents for lowercase and capitals.
+ \item added angle brackets and open square brackets
+ (glyph names based on Lucida New Math).
+ \item renamed \texttt{shortequals} to \texttt{hyphendbl} (in slot 42
+ and 127).
+ \item renamed \texttt{ohm} and \texttt{mho} to \texttt{Omega} and
+ \texttt{Omegainv}.
+ \item renamed \texttt{$($left$\mid$right$)$pointingarrow} to
+ \texttt{arrowleft} and \texttt{arrowright}.
+ \item added various symbols and currency signs, including
+ \texttt{euro}.
+\end{itemize}
+
+(LH, 2000/03/07):
+\begin{itemize}
+ \item
+ Added default setting of \texttt{italicslant} integer
+ (otherwise \texttt{ts1.etx} won't work with \verb|\generalpltomtx|).
+ \item
+ Moved changes list and some comments to end of file.
+\end{itemize}
+
+LH, 2000/11/12: Corrected command name, should be
+\verb|\textasciimacron|.
+
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/smbletx/ts1i.etx b/fonts/utilities/fontinst/inputs/smbletx/ts1i.etx
new file mode 100644
index 0000000000..1fee6defb7
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/smbletx/ts1i.etx
@@ -0,0 +1,7 @@
+\relax
+
+\encoding
+
+\inputetx{ts1}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/smbletx/ts1ij.etx b/fonts/utilities/fontinst/inputs/smbletx/ts1ij.etx
new file mode 100644
index 0000000000..1fee6defb7
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/smbletx/ts1ij.etx
@@ -0,0 +1,7 @@
+\relax
+
+\encoding
+
+\inputetx{ts1}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/smbletx/ts1j.etx b/fonts/utilities/fontinst/inputs/smbletx/ts1j.etx
new file mode 100644
index 0000000000..1fee6defb7
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/smbletx/ts1j.etx
@@ -0,0 +1,7 @@
+\relax
+
+\encoding
+
+\inputetx{ts1}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/inputs/smblmtx/resetosf.mtx b/fonts/utilities/fontinst/inputs/smblmtx/resetosf.mtx
new file mode 100644
index 0000000000..bde54d55d8
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/smblmtx/resetosf.mtx
@@ -0,0 +1,88 @@
+% Copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Ulrik Vieth",
+%%% version = "1.910",
+%%% date = "16 November 1999",
+%%% time = "23:01:44 CET",
+%%% filename = "resetosf.mtx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "04190 88 254 2588",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, raw, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a metrics file, for use with the
+%%% fontinst utility. It recodes glyph names
+%%% for oldstyle numerals read from AFM files
+%%% to glyph names with an `oldstyle' suffix.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\title{The \texttt{resetosf.mtx} metrics file}
+\author{Ulrik Vieth}
+\date{16 November 1999 \\
+Version 1.910}
+
+\begin{document}
+\maketitle
+
+This document describes the \texttt{resetosf.mtx} metrics file, which is
+used to recode raw glyph names for oldstyle numerals to glyph names
+with an `oldstyle' suffix.
+
+\metrics
+
+\setcommand\oldstyleglyph#1{
+ \ifisglyph{#1}\then
+ \setglyph{#1oldstyle}\glyph{#1}{1000}
+ \endsetglyph
+ \fi
+}
+
+\setcommand\oldstylekerning#1{
+ \ifisglyph{#1}\then
+ \setleftrightkerning{#1oldstyle}{#1}{1000}
+ \fi
+}
+
+\oldstyleglyph{zero}
+\oldstyleglyph{one}
+\oldstyleglyph{two}
+\oldstyleglyph{three}
+\oldstyleglyph{four}
+\oldstyleglyph{five}
+\oldstyleglyph{six}
+\oldstyleglyph{seven}
+\oldstyleglyph{eight}
+\oldstyleglyph{nine}
+
+\oldstylekerning{zero}
+\oldstylekerning{one}
+\oldstylekerning{two}
+\oldstylekerning{three}
+\oldstylekerning{four}
+\oldstylekerning{five}
+\oldstylekerning{six}
+\oldstylekerning{seven}
+\oldstylekerning{eight}
+\oldstylekerning{nine}
+
+\endmetrics
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/smblmtx/textcomp.mtx b/fonts/utilities/fontinst/inputs/smblmtx/textcomp.mtx
new file mode 100644
index 0000000000..c4c0a17f27
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/smblmtx/textcomp.mtx
@@ -0,0 +1,561 @@
+% Copyright 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999, 2003 the fontinst maintenance team and
+% any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Sebastian Rahtz and Ulrik Vieth and
+%%% Walter Schmidt and Lars Hellstr{\"o}m",
+%%% version = "1.926",
+%%% date = "2005-05-24",
+%%% time = "22:30:49 +02:00",
+%%% filename = "textcomp.mtx",
+%%% email = "w-a-schmidt@arcor.de",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a font metrics file, for use with the
+%%% fontinst utility. It provides the defaults
+%%% used to install the text companion glyphs.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}[2002/06/30] %Just guessing.
+
+\title{The \textsf{fontinst} text companion glyphs}
+\author{Sebastian Rahtz\and Ulrik Vieth\and Walter Schmidt\and
+ Lars Hellstr\"om}
+\date{Version 1.926}
+
+\showbranches
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the glyphs used by the \textsf{fontinst}
+package when generating \TeX{} text companion fonts.
+
+\metrics
+
+\needsfontinstversion{1.917}
+
+% \unfakable is a glyph which can't be faked.
+
+\setcommand\unfakable#1{
+ \setglyph{#1}
+ \glyphrule{500}{500}
+ \glyphwarning{missing glyph `#1'}
+ \endsetglyph
+}
+% \unfakableaccent is similar, but has an ``accent position''
+\setcommand\unfakableaccent#1{
+ \setglyph{#1}
+ \moveup{\add{\int{xheight}}{50}}
+ \movert{\scale{\add{\int{xheight}}{50}}{\int{italicslant}}}
+ \glyphrule{250}{\sub{\sub{\int{ascender}}{\int{xheight}}}{100}}
+ \movert{\neg{\scale{\add{\int{xheight}}{50}}{\int{italicslant}}}}
+ \glyphwarning{missing glyph `#1'}
+ \endsetglyph
+}
+
+% \fakeglyph replaces glyph #1 by #2, if it exists.
+
+\setcommand\fakeglyph#1#2{
+ \ifisglyph{#2}\then
+ \setglyph{#1}
+ \glyph{#2}{1000}
+ \endsetglyph
+ \Fi
+}
+
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setint{italicslant}{0}
+\setint{xheight}{\height{x}}
+\setint{capheight}{\height{A}}
+\setint{ascender}{\height{d}}
+\setint{descender}{\depth{g}}
+\setint{underlinethickness}{40}
+
+% Vertical symmetry axis. (WaS)
+\setint{vaxis}{\scale{\sub{\height{parenleft}}{\depth{parenleft}}}{500}}
+
+
+\begincomment
+\section{Oldstyle numerals}
+\endcomment
+
+\unfakable{zerooldstyle}
+\unfakable{oneoldstyle}
+\unfakable{twooldstyle}
+\unfakable{threeoldstyle}
+\unfakable{fouroldstyle}
+\unfakable{fiveoldstyle}
+\unfakable{sixoldstyle}
+\unfakable{sevenoldstyle}
+\unfakable{eightoldstyle}
+\unfakable{nineoldstyle}
+
+
+\begincomment
+\section{Capital accents}
+\endcomment
+
+\fakeglyph{capitalgrave}{grave}
+\fakeglyph{capitalacute}{acute}
+\fakeglyph{capitalcircumflex}{circumflex}
+\fakeglyph{capitaltilde}{tilde}
+\fakeglyph{capitaldieresis}{dieresis}
+\fakeglyph{capitalhungarumlaut}{hungarumlaut}
+\fakeglyph{capitalring}{ring}
+\fakeglyph{capitalcaron}{caron}
+\fakeglyph{capitalbreve}{breve}
+\fakeglyph{capitalmacron}{macron}
+\fakeglyph{capitaldotaccent}{dotaccent}
+\fakeglyph{capitalcedilla}{cedilla}
+\fakeglyph{capitalogonek}{ogonek}
+
+
+\begincomment
+\section{ASCII-style accents}
+\endcomment
+
+\ifisglyph{asciitilde}\then
+ \setglyph{tildelow}
+ \glyph{asciitilde}{1000}
+ \endsetglyph
+\Fi
+
+\ifisglyph{grave}\then
+ \setglyph{asciigrave}
+ \glyph{grave}{1000}
+ \endsetglyph
+\Fi
+
+\ifisglyph{breve}\then
+ \setglyph{asciibreve}
+ \glyph{breve}{1000}
+ \endsetglyph
+\Fi
+
+\ifisglyph{acute}\then
+ \setglyph{asciiacutedbl}
+ \ifisint{monowidth}\then
+ \glyph{acute}{1000}
+ \glyph{acute}{1000}
+ \Else
+ \glyph{acute}{1000}
+ \movert{\neg{\scale{\width{acute}}{333}}}
+ \glyph{acute}{1000}
+ \Fi
+ \endsetglyph
+\Fi
+
+\ifisglyph{grave}\then
+ \setglyph{asciigravedbl}
+ \ifisint{monowidth}\then
+ \glyph{grave}{1000}
+ \glyph{grave}{1000}
+ \Else
+ \glyph{grave}{1000}
+ \movert{\neg{\scale{\width{grave}}{333}}}
+ \glyph{grave}{1000}
+ \Fi
+ \endsetglyph
+\Fi
+
+\ifisglyph{caron}\then
+ \setglyph{asciicaron}
+ \glyph{caron}{1000}
+ \endsetglyph
+\Fi
+
+\ifisglyph{dieresis}\then
+ \setglyph{asciidieresis}
+ \glyph{dieresis}{1000}
+ \endsetglyph
+\Fi
+
+\ifisglyph{macron}\then
+ \setglyph{asciimacron}
+ \glyph{macron}{1000}
+ \endsetglyph
+\Fi
+
+\ifisglyph{acute}\then
+ \setglyph{asciiacute}
+ \glyph{acute}{1000}
+ \endsetglyph
+\Fi
+
+
+\begincomment
+\section{Glyphs}
+\endcomment
+
+\setglyph{capitalcompwordmark}
+ \glyphrule{0}{\int{capheight}}
+\endsetglyph
+\setint{capitalcompwordmark-spacing}{0}
+
+\setglyph{ascendercompwordmark}
+ \glyphrule{0}{\int{ascender}}
+\endsetglyph
+\setint{ascendercompwordmark-spacing}{0}
+
+% centers wrt/ vertical symmetry axis. (WaS)
+\ifisglyph{asterisk}\then
+ \resetglyph{asteriskcentered}
+ \moveup{\neg{\sub
+ {\scale{\sub{\height{asterisk}}{\depth{asterisk}}}{500}}
+ {\int{vaxis}}
+ }}
+ \glyph{asterisk}{1000}
+ \resetdepth{0}
+ \endresetglyph
+\Fi
+
+% assumes that 2/3em = 667 and \width{endash} about 500
+\ifisglyph{endash}\then
+ \setglyph{twelveudash}
+ \ifisint{monowidth}\then
+ \glyph{hyphen}{1000}
+ \glyph{hyphen}{1000}
+ \Else
+ \glyph{endash}{1000}
+ \movert{\sub{667}{\mul{2}{\width{endash}}}}
+ \glyph{endash}{1000}
+ \comment{This assumes that \(2/3\,\mathrm{em} = 667\) and
+ that the leading of the \texttt{endash} is less than
+ \(333/4\).}
+ \Fi
+ \endsetglyph
+\Fi
+
+% assumes that 3/4em = 750 and \width{endash} = 500
+\ifisglyph{endash}\then
+ \setglyph{threequartersemdash}
+ \ifisint{monowidth}\then
+ \glyph{hyphen}{1000}
+ \glyph{hyphen}{1000}
+ \Else
+ \glyph{endash}{1000}
+ \movert{\sub{750}{\mul{2}{\width{endash}}}}
+ \glyph{endash}{1000}
+ \comment{This assumes that the leading of the
+ \texttt{endash} is less than \(250/4\).}
+ \Fi
+ \endsetglyph
+\Fi
+
+% questionable fakery, doesn't really work with all fonts
+\ifisglyph{bracketleft}\then
+ \setglyph{openbracketleft}
+ \ifisint{monowidth}\then
+ \glyph{bracketleft}{1000}
+ \glyph{bracketleft}{1000}
+ \Else
+ \glyph{bracketleft}{1000}
+ \movert{\neg{\scale{\width{bracketleft}}{666}}}
+ \glyph{bracketleft}{1000}
+ \comment{This is questionable fakery, which doesn't
+ really work with all fonts.}
+ \Fi
+ \endsetglyph
+\Fi
+
+% questionable fakery, doesn't really work with all fonts
+\ifisglyph{bracketright}\then
+ \setglyph{openbracketright}
+ \ifisint{monowidth}\then
+ \glyph{bracketright}{1000}
+ \glyph{bracketright}{1000}
+ \Else
+ \glyph{bracketright}{1000}
+ \movert{\neg{\scale{\width{bracketright}}{666}}}
+ \glyph{bracketright}{1000}
+ \comment{This is questionable fakery, which doesn't
+ really work with all fonts.}
+ \Fi
+ \endsetglyph
+\Fi
+
+% questionable fakery, doesn't really work with all fonts
+\ifisglyph{bar}\then
+ \setglyph{bardbl}
+ \ifisint{monowidth}\then
+ \glyph{bar}{1000}
+ \glyph{bar}{1000}
+ \Else
+ \glyph{bar}{1000}
+ \movert{\neg{\scale{\width{bar}}{333}}}
+ \glyph{bar}{1000}
+ \comment{This is questionable fakery, which doesn't
+ really work with all fonts.}
+ \Fi
+ \endsetglyph
+\Fi
+
+\ifareglyphs{degree,C}\then
+ \setglyph{centigrade}
+ \glyph{degree}{1000}
+ \glyph{C}{1000}
+ \resetitalic{\italic{C}}
+ \endsetglyph
+\Fi
+
+\ifisglyph{Euro}\then
+ \setglyph{euro}
+ \glyph{Euro}{1000}
+ \endsetglyph
+\Else\ifisglyph{C}\then
+ \setglyph{euro}
+ \movert{50}
+ \push
+ \moveup{\half{\sub{\height{C}}{\depth{C}}}}
+ \movert{\scale
+ {\half{\sub{\height{C}}{\depth{C}}}}
+ {\int{italicslant}}
+ }
+ \push
+ \moveup{\scale{\int{underlinethickness}}{1500}}
+ \glyphrule{\scale{\width{C}}{750}}{\int{underlinethickness}}
+ \pop
+ \moveup{\scale{\int{underlinethickness}}{-1500}}
+ \glyphrule{\scale{\width{C}}{700}}{\int{underlinethickness}}
+ \comment{That this bar is slightly shorter than the previous
+ is deliberate. That the two bars are not quite centered
+ around the vertical midpoint is also deliberate.}
+ \pop
+ \movert{50}
+ \comment{This movement should be much larger for some fonts,
+ e.g. New Century Schoolbook Italic, but experiments indicate
+ that it is independent of the italic slant.}
+ \glyph{C}{1000}
+ \resetitalic{\italic{C}}
+ \endsetglyph
+\Fi\Fi
+
+\ifareglyphs{question,exclam}\then
+ \setglyph{interrobang}
+ \push
+ \movert{\add{\half{\sub{\width{question}}{\width{exclam}}}}{-50}}
+ \comment{The extra $-50$ serves to separate the exclamation mark
+ from the right side of the question mark.}
+ \glyph{exclam}{1000}
+ \pop
+ \glyph{question}{1000}
+ \endsetglyph
+\Fi
+\ifareglyphs{questiondown,exclamdown}\then
+ \setglyph{interrobangdown}
+ \push
+ \movert{\add
+ {\half{\sub{\width{questiondown}}{\width{exclamdown}}}}
+ {50}
+ }
+ \glyph{exclamdown}{1000}
+ \pop
+ \glyph{questiondown}{1000}
+ \endsetglyph
+\Fi
+
+
+\begincomment
+\section{Unfakable glyphs}
+In general, every glyph is unfakable unless we know how to fake it.
+\endcomment
+
+\unfakableaccent{capitalgrave} % 8r,8y
+\unfakableaccent{capitalacute} % 8r,8y
+\unfakableaccent{capitalcircumflex} % 8r,8y
+\unfakableaccent{capitaltilde} % 8r,8y
+\unfakableaccent{capitaldieresis} % 8r,8y
+\unfakableaccent{capitalhungarumlaut} % 8r,8y
+\unfakableaccent{capitalring} % 8r,8y
+\unfakableaccent{capitalcaron} % 8r,8y
+\unfakableaccent{capitalbreve} % 8r,8y
+\unfakableaccent{capitalmacron} % 8r,8y
+\unfakableaccent{capitaldotaccent} % 8r,8y
+\unfakable{capitalcedilla} % 8r,8y
+\unfakable{capitalogonek} % 8r,8y
+\unfakable{quotesinglbase} % 8r,8y
+\unfakable{quotedblbase} % 8r,8y
+\unfakable{twelveudash} % faked 8r,8x
+\unfakable{threequartersemdash} % 8x (Adobe)
+\unfakable{arrowleft}
+\unfakable{arrowright}
+\unfakableaccent{tieaccentlowercase}
+\unfakableaccent{tieaccentcapital}
+\unfakableaccent{newtieaccentlowercase}
+\unfakableaccent{newtieaccentcapital}
+\unfakable{blank}
+\unfakable{dollar} % 8r,8y
+\unfakable{quotesingle} % 8r,8y
+\unfakable{asteriskcentered} % faked 8r,8y
+\unfakable{comma} % 8r,8y
+\unfakable{hyphendbl}
+\unfakable{period} % 8r,8y
+\unfakable{fraction} % 8r,8y
+\unfakable{angbracketleft}
+\unfakable{minus} % 8r,8y
+\unfakable{angbracketright}
+\unfakable{Omegainv}
+\unfakable{bigcircle}
+\unfakable{Omega}
+\unfakable{openbracketleft} % faked 8r,8y
+\unfakable{openbracketright} % faked 8r,8y
+\unfakable{arrowup}
+\unfakable{arrowdown}
+\unfakable{asciigrave} % 8r,8y
+\unfakable{born}
+\unfakable{divorced}
+\unfakable{died}
+\unfakable{leaf}
+\unfakable{married}
+\unfakable{musicalnote}
+\unfakable{tildelow} % 8r,8y
+\unfakable{hyphendblchar}
+\unfakable{asciibreve} % 8r,8y
+\unfakable{asciicaron} % 8r,8y
+\unfakable{asciiacutedbl} % faked 8r,8y
+\unfakable{asciigravedbl} % faked 8r,8y
+\unfakable{dagger} % 8r,8y
+\unfakable{daggerdbl} % 8r,8y
+\unfakable{bardbl} % faked 8r,8y
+\unfakable{perthousand} % 8r,8y
+\unfakable{bullet} % 8r,8y
+\unfakable{centigrade} % faked 8r,8y
+\unfakable{dollaroldstyle} % 8x (Adobe)
+\unfakable{centoldstyle} % 8x (Adobe)
+\unfakable{florin} % 8r,8y
+\unfakable{colonmonetary} % 8x (Adobe)
+\unfakable{won}
+\unfakable{naira}
+\unfakable{guarani}
+\unfakable{peso}
+\unfakable{lira} % 8x (URW)
+\unfakable{recipe}
+\unfakable{interrobang}
+\unfakable{interrobangdown}
+\unfakable{dong}
+\unfakable{trademark} % 8r,8y
+\unfakable{pertenthousand} % faked 8x
+\unfakable{pilcrow}
+\unfakable{baht}
+\unfakable{numero}
+\unfakable{discount}
+\unfakable{estimated}
+\unfakable{openbullet}
+\unfakable{servicemark}
+\unfakable{quillbracketleft}
+\unfakable{quillbracketright}
+\unfakable{cent} % 8r,8y
+\unfakable{sterling} % 8r,8y
+\unfakable{currency} % 8r,8y
+\unfakable{yen} % 8r,8y
+\unfakable{brokenbar} % 8r,8y
+\unfakable{section} % 8r,8y
+\unfakable{asciidieresis} % 8r,8y
+\unfakable{copyright} % 8r,8y
+\unfakable{ordfeminine} % 8r,8y
+\unfakable{copyleft}
+\unfakable{logicalnot} % 8r,8y
+\unfakable{circledP}
+\unfakable{registered} % 8r,8y
+\unfakable{asciimacron} % 8r,8y
+\unfakable{degree} % 8r,8y
+\unfakable{plusminus} % 8r,8y
+\unfakable{twosuperior} % 8r,8y
+\unfakable{threesuperior} % 8r,8y
+\unfakable{asciiacute} % 8r,8y
+\unfakable{mu} % 8r,8y
+\unfakable{paragraph} % 8r,8y
+\unfakable{periodcentered} % 8r,8y
+\unfakable{referencemark}
+\unfakable{onesuperior} % 8r,8y
+\unfakable{ordmasculine} % 8r,8y
+\unfakable{radical}
+\unfakable{onequarter} % 8r,8y
+\unfakable{onehalf} % 8r,8y
+\unfakable{threequarters} % 8r,8y
+\unfakable{euro} % faked 8r,8y
+\unfakable{multiply} % 8r,8y
+\unfakable{divide} % 8r,8y
+
+
+% \begincomment
+% \section{Accents}
+% \TeX's math accent-positioning requires accents to have zero depth,
+% but is that really relevant for these accents?
+% \endcomment
+%
+% \setcommand\zerodepth#1{
+% \ifisglyph{#1}\then
+% \resetglyph{#1}
+% \glyph{#1}{1000}
+% \resetdepth{0}
+% \endresetglyph
+% \Fi
+% }
+% \zerodepth{capitalgrave}
+% \zerodepth{capitalacute}
+% \zerodepth{capitalcircumflex}
+% \zerodepth{capitaltilde}
+% \zerodepth{capitaldieresis}
+% \zerodepth{capitalhungarumlaut}
+% \zerodepth{capitalring}
+% \zerodepth{capitalcaron}
+% \zerodepth{capitalbreve}
+% \zerodepth{capitalmacron}
+% \zerodepth{capitaldotaccent}
+
+\endmetrics
+
+\section{Changes}
+
+1999/10/25: Definition of \verb|\unfakable| simplified. (UV\&LH)
+Rationale: It is thoroughly confusing if the size of the black box
+created by \verb|\unfakable| depends on the metrics of an unencoded
+glyph that isn't accessible and therefore unavailable for all
+pratical purposes.
+
+February--March 2003: Explicitly centering the
+\texttt{asteriskcentered}. Introduced the \textit{vaxis} integer. (WaS)
+
+2003/07/09:
+Making use of \verb|\showbranches|, \verb|\begincomment|, and
+\verb|\endcomment|. Make definitions of \texttt{twelveudash} and
+\texttt{threequartersemdash} less dependent on the exact width of
+\texttt{endash}. Added a fake definition of \texttt{euro}. (LH)
+
+2003/07/10:
+Commented out section on zero-depth accents. (LH) Rationale:
+\texttt{TS1}-encoded fonts are, to my knowledge, never used in math.
+
+2003/07/13:
+Added some \verb|\resetitalic| commands. Added fakes for
+\texttt{interrobang} and \texttt{interrobangdown}. Using an
+\verb|\unfakableaccent| for unfakable accents. (LH) Rationale:
+The result becomes much more readable.
+
+\end{document}
diff --git a/fonts/utilities/fontinst/inputs/smblmtx/unsetnum.mtx b/fonts/utilities/fontinst/inputs/smblmtx/unsetnum.mtx
new file mode 100644
index 0000000000..c9f89b9ea9
--- /dev/null
+++ b/fonts/utilities/fontinst/inputs/smblmtx/unsetnum.mtx
@@ -0,0 +1,62 @@
+% Copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% ====================================================================
+%%% @TeX-font-metrics-file{
+%%% author = "Ulrik Vieth",
+%%% version = "1.910",
+%%% date = "16 November 1999",
+%%% time = "23:02:47 CET",
+%%% filename = "unsetnum.mtx",
+%%% email = "fontinst@cogs.susx.ac.uk",
+%%% URL = "http://www.tug.org/applications/fontinst/",
+%%% checksum = "24513 62 213 1967",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "metrics, raw, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is a metrics file, for use with the
+%%% fontinst utility. It makes glyph names
+%%% for numerals undefined.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\title{The \texttt{unsetnum.mtx} metrics file}
+\author{Ulrik Vieth}
+\date{16 November 1999 \\
+Version 1.910}
+
+\begin{document}
+\maketitle
+
+This document describes the \texttt{unsetnum.mtx} metrics file, which is
+used to make glyph names for numerals undefined.
+
+\metrics
+
+\unsetglyph{zero}
+\unsetglyph{one}
+\unsetglyph{two}
+\unsetglyph{three}
+\unsetglyph{four}
+\unsetglyph{five}
+\unsetglyph{six}
+\unsetglyph{seven}
+\unsetglyph{eight}
+\unsetglyph{nine}
+
+\endmetrics
+\end{document}
diff --git a/fonts/utilities/fontinst/latex/fontdoc.sty b/fonts/utilities/fontinst/latex/fontdoc.sty
new file mode 100644
index 0000000000..01d8efa1e6
--- /dev/null
+++ b/fonts/utilities/fontinst/latex/fontdoc.sty
@@ -0,0 +1,1390 @@
+%%
+%% This is file `fontdoc.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% fibasics.dtx (with options: `doc')
+%% ficommon.dtx (with options: `doc')
+%% fimain.dtx (with options: `doc')
+%% fimapgen.dtx (with options: `doc')
+%%
+%% This is a generated file.
+%%
+%% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+%% hacked and maintained 1997, 1998 Sebastian Rahtz,
+%% copyright 1998, 1999, 2000, 2001 the fontinst maintenance team and any
+%% individual authors listed elsewhere in this file. All rights reserved.
+%%
+%% This file is part of the fontinst system version 1.9.
+%% -----------------------------------------------------
+%%
+%% It may be distributed under the terms of the LaTeX Project Public
+%% License, as described in lppl.txt in the base LaTeX distribution.
+%% Either version 1.1 or, at your option, any later version.
+%% This file may also be distributed by itself provided it is unchanged
+%% and accompanied by some prominent file which states the location of
+%% the sources for the fontinst system, from which this file was
+%% generated.
+%%
+%%% From file: fibasics.dtx
+\def\fontinstversion{1.933}
+\NeedsTeXFormat{LaTeX2e}[1995/06/01]
+\ProvidesPackage{fontdoc}
+[2007/01/23 v\fontinstversion\space
+ fontinst documentation package]
+\newcommand*\needsfontinstversion[1]{%
+ \ifFD@spec@
+ \comment{Automatic processing of this document as a data file
+ requires \textsf{fontinst} v\,#1 or higher.}%
+ \else
+ \Bheading{Needs fontinst v\thinspace#1}%
+ \fi
+}
+\newif\ifFD@spec@
+\FD@spec@false
+\DeclareOption{specification}{\FD@spec@true}
+\DeclareOption{hypertex}{
+ \providecommand*\FD@codepoint[1]{%
+ \uppercase{\edef\@tempa{#1}}%
+ \special{html:<a href="%
+ http://www.unicode.org/cgi-bin/refglyph?24-\@tempa
+ ">%
+ }%
+ \texttt{U+\@tempa}%
+ \special{html:</a>}%
+ }%
+}
+\DeclareOption{pdftex}{
+ \providecommand*\FD@codepoint[1]{%
+ \mbox{%
+ \uppercase{\edef\@tempa{#1}}%
+ \ifx \pdfstartlink\@undefined
+ \pdfannotlink
+ \else
+ \pdfstartlink
+ \fi attr {/Border [0 0 0]} user {%
+ /Subtype /Link /A <<%
+ /S /URI /URI (%
+ http://www.unicode.org/cgi-bin/refglyph?24-\@tempa
+ )%
+ >>}%
+ \textcolor{blue}{\texttt{U+\@tempa}}%
+ \pdfendlink
+ }%
+ }%
+ \AtEndOfPackage{\RequirePackage[pdftex]{color}}%
+}
+\InputIfFileExists{fontdoc.cfg}{%
+ \typeout{*************************************^^J%
+ * Local config file fontdoc.cfg used^^J%
+ *************************************}%
+}{}
+\ProcessOptions\relax
+\RequirePackage{amstext}
+\newcount\a@count
+\newcount\b@count
+\newdimen\a@dimen
+\def\x@cs#1#2{\expandafter#1\csname#2\endcsname}
+\def\FD@swap@two#1#2{#2#1}
+\newcommand\Aheading[1]{%
+ \par\pagebreak[1]\addvspace\medskipamount
+ \noindent\textbf{#1}\vadjust{\penalty200}\par
+}
+\newcommand\Bheading[1]{\par\noindent\textbf{#1}}
+\raggedbottom
+\ifdim 1sp>\lineskiplimit \lineskiplimit=0.5pt \fi
+\newcommand\plain{\texttt{plain}}
+\let\plainint=\int
+\let\plaindiv=\div
+\let\plainneg=\neg
+\let\plainmax=\max
+\let\plainmin=\min
+\newcount\list@item@counter
+\newcommand\TypesetList[8]{%
+ \begingroup
+ \list@item@counter=\z@
+ \def\do##1{\advance\list@item@counter\@ne}%
+ #8%
+ \ifcase \list@item@counter \or
+ \def\do##1{#1#7{##1}}%
+ \or
+ \def\do##1{%
+ \advance\list@item@counter\@ne
+ \ifnum \list@item@counter=\@ne #1\else #2\fi
+ #7{##1}%
+ }%
+ \else
+ \advance\list@item@counter\m@ne
+ \expandafter\def \expandafter\do \expandafter##\expandafter1%
+ \expandafter{\expandafter\ifnum \the\list@item@counter
+ =\list@item@counter
+ #4%
+ \else\ifnum \z@=\list@item@counter
+ #1%
+ \else
+ #3%
+ \fi\fi
+ \advance\list@item@counter\@ne
+ #7{##1}%
+ }%
+ \fi
+ \ifnum \z@=\list@item@counter
+ #6%
+ \else
+ \list@item@counter=\z@
+ #8%
+ #5%
+ \fi
+ \endgroup
+}
+\let\x@relax=\relax
+\def\eTeX#1{\do{\eTeXlogo\nolinebreak[3] v\,#1}}
+\def\eTeXlogo{\ensuremath{\varepsilon}-\kern-.125em\TeX}
+\def\pdfTeX#1#2{%
+ \do{pdf\TeX\nolinebreak[3] v\,%
+ \ifnum #1<100\space
+ 0.\ifnum #1<10\space 0\fi
+ \else
+ \expandafter\FD@swap@two \expandafter.%
+ \fi
+ #1#2%
+ }
+}
+\def\needsTeXextension#1#2{%
+ \Bheading{Needs
+ \TypesetList{}{ or }{, }{, or }{}{(unspecified)}{\@firstofone}{#1}}%
+}
+\let\then=\iffalse
+\let\Else=\else
+\let\Fi=\fi
+\def\generic@if#1{\iftrue}
+\newcommand\showbranches{%
+ \let\generic@if=\branches@if
+ \let\then=\x@relax
+ \let\Else=\branches@else
+ \let\Fi=\branches@fi
+}
+\newcount\saved@slot@number
+\def\branches@if#1{%
+ \ifnum \branches@type=\tw@
+ \begin{IfBranchDummy}%
+ \textit{ if #1 then}%
+ \else
+ \par
+ \ifFD@tight@\else \addvspace\medskipamount \fi
+ \noindent\textit{If #1 then}%
+ \fi
+ \saved@slot@number=\slot@number
+ \gdef\branches@type{0}%
+ \let\par=\branches@par
+}
+\def\branches@else{%
+ \ifnum \branches@type=\z@
+ \textit{ relax else}%
+ \gdef\branches@type{1}%
+ \else
+ \par
+ \end{IfBranch}%
+ \noindent\textit{Else}%
+ \gdef\branches@type{2}%
+ \fi
+ \global\slot@number=\saved@slot@number
+ \let\par=\branches@par
+}
+\def\branches@fi{%
+ \ifnum \branches@type=\thr@@
+ \expandafter\end \expandafter{\@currenvir}%
+ \expandafter\gdef \expandafter\FD@saved@fis
+ \expandafter{\FD@saved@fis \space fi}%
+ \else
+ \end{IfBranch}%
+ \gdef\FD@saved@fis{Fi}%
+ \fi
+ \gdef\branches@type{3}%
+ \let\par=\branches@par
+}
+\gdef\branches@type{4}
+\def\branches@par{%
+ \@restorepar
+ \ifnum \branches@type=\thr@@
+ \noindent\textit{\FD@saved@fis}\par
+ \else
+ \begin{IfBranch}%
+ \fi
+ \gdef\branches@type{4}%
+}
+\newif\ifFD@tight@
+\newenvironment{IfBranch}{%
+ \list{}{%
+ \ifFD@tight@
+ \setlength\topsep{\z@skip}%
+ \@beginparpenalty=\z@
+ \@endparpenalty=\z@
+ \setlength\leftmargin{1em}%
+ \else
+ \setlength\topsep{\medskipamount}%
+ \@beginparpenalty=-10%
+ \@endparpenalty=\@beginparpenalty
+ \setlength\leftmargin{\z@}%
+ \fi
+ \setlength\partopsep{\z@skip}%
+ \setlength\itemsep{\z@skip}%
+ \setlength\parsep{\z@ plus\p@}%
+ \setlength\rightmargin{\z@}%
+ \setlength\itemindent{\z@}%
+ }%
+ \item[]%
+}{\endlist}
+\newenvironment{IfBranchDummy}{}{}
+\begingroup
+ \catcode`\,=13
+ \gdef\print@csep@list#1#2{%
+ $%
+ \ifnum "8000=\mathcode`\,\else
+ \mathchardef\private@comma=\mathcode`\,%
+ \mathcode`\,="8000\x@relax
+ \fi
+ #1%
+ \let,=\active@comma
+ #2%
+ $%
+ }
+\endgroup
+\def\active@comma{\private@comma \penalty\binoppenalty}
+\let\messagebreak\space
+\def\fontinsterror#1#2#3{%
+ \Bheading{Error} observed by #1:%
+ \begin{quote}#2.\end{quote}%
+}
+\def\fontinstwarning#1#2{
+ \Bheading{Warning} from #1:%
+ \begin{quote}#2.\end{quote}%
+}
+\let\fontinstwarningnoline=\fontinstwarning
+\def\fontinstinfo#1#2{
+ \Bheading{Info} from #1:%
+ \begin{quote}#2.\end{quote}%
+}
+%%% From file: ficommon.dtx
+\DeclareRobustCommand\PrintChar[1]{%
+ \leavevmode
+ \begingroup
+ \count@=#1\relax
+ \ifnum \@xxxii>\count@
+ \advance \count@ 64%
+ \InvisibleCharPrefix
+ \PrintVisibleChar\count@
+ \InvisibleCharSuffix
+ \else\ifnum 127>\count@
+ \PrintVisibleChar\count@
+ \else
+ \InvisibleCharPrefix
+ \ifnum 127=\count@ \PrintVisibleChar{63}\else
+ \@tempcnta=\count@
+ \divide \count@ \sixt@@n
+ \@tempcntb=\count@
+ \multiply \count@ \sixt@@n
+ \advance \@tempcnta -\count@
+ \advance \@tempcntb \ifnum 9<\@tempcntb 87\else 48\fi
+ \advance \@tempcnta \ifnum 9<\@tempcnta 87\else 48\fi
+ \char\@tempcntb \char\@tempcnta
+ \fi
+ \InvisibleCharSuffix
+ \fi\fi
+ \endgroup
+}
+\newcommand\InvisibleCharPrefix{%
+ \/\em
+ \PrintVisibleChar{`\^}\PrintVisibleChar{`\^}%
+}
+\newcommand\InvisibleCharSuffix{\/}
+\newcommand\PrintVisibleChar[1]{%
+ \ifcase #1%
+ \or\or\or\or\or\or\or\or \or\or\or\or\or\or\or\or
+ \or\or\or\or\or\or\or\or \or\or\or\or\or\or\or\or
+ % "20
+ \textvisiblespace \or!\or\textquotedbl \or\#\or\textdollar
+ \or\%\or\&\or\textquoteright\or(\or)\or*\or+\or,\or-\or.\or/%
+ \or % "30
+ 0\or1\or2\or3\or4\or5\or6\or7\or8\or9\or:\or;\or
+ \textless\or=\or\textgreater\or?%
+ \or % "40
+ @\or A\or B\or C\or D\or E\or F\or G\or
+ H\or I\or J\or K\or L\or M\or N\or O%
+ \or % "50
+ P\or Q\or R\or S\or T\or U\or V\or W\or X\or Y\or Z\or [\or
+ \textbackslash \or]\or\textasciicircum \or\textunderscore
+ \or % "60
+ \textquoteleft \or a\or b\or c\or d\or e\or f\or g\or h\or
+ i\or j\or k\or l\or m\or n\or o%
+ \or % "70
+ p\or q\or r\or s\or t\or u\or v\or w\or x\or y\or z\or
+ \textbraceleft \or\textbar \or\textbraceright \or\textasciitilde
+ \fi
+}
+\DeclareTextCommandDefault{\textvisiblespace}{%
+ \makebox[\fontdimen\tw@\font]{%
+ \hfil
+ \vrule \@height.3ex%
+ \vbox{\hrule \@width .66\fontdimen\tw@\font}%
+ \vrule \@height.3ex%
+ \hfil
+ }%
+}
+\def\FD@quoted@PrintChar#1{"\number#1"}
+\count@=32
+\begingroup
+ \catcode\z@=12\relax
+ \@firstofone{%
+\endgroup
+ \loop
+ \if \ifnum 11=\catcode\count@ 1\else \ifnum 12=\catcode\count@
+ 1\else 0\fi\fi 1%
+ \uccode\z@=\count@
+ \uppercase{\def\@tempa{^^@}}%
+ \else
+ \edef\@tempa{\noexpand\PrintChar{\the\count@}}%
+ \fi
+ \x@cs\let{FD@printable@\the\count@}=\@tempa
+ \advance \count@ \@ne
+ \ifnum 127>\count@ \repeat
+}
+\@namedef{FD@printable@34}{\PrintChar{34}} % "
+\@namedef{FD@printable@60}{\PrintChar{60}} % <
+\@namedef{FD@printable@62}{\PrintChar{62}} % >
+\def\MakePrintable#1#2#3{%
+ \begingroup
+ \toks@={}%
+ \escapechar=`\\%
+ \@tempswafalse
+ \FD@printable@#3\protect\FD@printable@
+ \toks@=\expandafter{%
+ \expandafter\let \csname if#2\expandafter\endcsname
+ \csname if\if@tempswa false\else true\fi \expandafter\endcsname
+ \expandafter\def \expandafter#1\expandafter{\the\toks@}%
+ }%
+ \expandafter\endgroup \the\toks@
+}
+\def\FD@printable@iii{%
+ \expandafter\futurelet \expandafter\@let@token
+ \expandafter\FD@printable@iv \string
+}
+\def\FD@printable@iv{%
+ \ifx \@let@token\@sptoken
+ \expandafter\FD@printable@v
+ \else
+ \expandafter\FD@printable@vi
+ \fi
+}
+\begingroup
+ \catcode`3=\catcode`a
+ \catcode`2=\catcode`a
+ \@firstofone{\gdef\FD@printable@v} {%
+ \toks@=\expandafter{\the \expandafter\toks@ \FD@printable@32}%
+ \FD@printable@
+ }
+\endgroup
+\def\FD@printable@vi#1{%
+ \if \ifnum `#1<\@xxxii 1\else \ifnum `#1>126 1\else 0\fi\fi 1%
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\PrintChar \expandafter{\number`#1}%
+ }%
+ \else
+ \toks@=\expandafter{\the\expandafter\expandafter\expandafter\toks@
+ \csname FD@printable@\number`#1\endcsname}%
+ \fi
+ \FD@printable@
+}
+\def\FD@printable@{\futurelet\@let@token \FD@printable@i}
+\def\FD@printable@i{%
+ \csname FD@printable@%
+ \ifcat \noexpand\@let@token \noexpand\FD@printable@
+ \ifx \@let@token\protect ii\else vii\fi
+ \else iii\fi
+ \endcsname
+}
+\def\FD@printable@ii\protect#1{%
+ \@ifundefined{FD@printable\expandafter\zap@space\string#1 \@empty}{%
+ \PackageError{fontdoc}{Command \protect#1 not allowed in string}%
+ \@eha
+ }{\csname FD@printable\expandafter\zap@space\string#1 \@empty
+ \endcsname}%
+}
+\def\FD@printable@vii{\expandafter\FD@printable@vi \string}
+\expandafter\let
+ \csname FD@printable\string\FD@printable@\endcsname \@empty
+\@namedef{FD@printable\string\PrintChar}#1{%
+ \if \ifnum #1<\@xxxii 1\else \ifnum #1>126 1\else 0\fi\fi 1%
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\PrintChar \expandafter{\number#1}%
+ }%
+ \else
+ \toks@=\expandafter{\the\expandafter\expandafter\expandafter\toks@
+ \csname FD@printable@\number#1\endcsname}%
+ \fi
+ \FD@printable@
+}
+\newcommand*\ExpandAndMakePrintable[3]{%
+ \protected@edef\@tempa{{#2}{#3}}%
+ \expandafter\MakePrintable \expandafter#1\@tempa
+}
+\def\FD@string@func#1#2{%
+ \relax
+ \ifnum \spacefactor=\@ne $\mkern1mu\else$\fi
+ \mathrm{#1}($%
+ #2%
+ \ifnum \spacefactor=\@ne $\mkern-1mu\else $\fi)\mkern1mu$%
+ \spacefactor=\@ne
+}
+\newcommand\TypesetStringExpression[1]{%
+ \protected@edef\@tempa{%
+ \noexpand\MakePrintable \noexpand\@tempa {FD@swa}{#1}%
+ }%
+ \@tempa
+ \FD@typeset@string{\@tempa}%
+}
+\def\FD@typeset@string#1{%
+ \mbox{%
+ \normalfont\ttfamily
+ \spacefactor=\@ne
+ #1%
+ \ifnum \spacefactor=\@ne $\mkern-1mu\m@th$\fi
+ }%
+}
+\let\ifFD@swa\iffalse
+\DeclareRobustCommand\str[1]{\FD@string@func{s}{#1}}
+\@namedef{FD@printable\string\str}#1{%
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \begingroup
+ \let\PrintChar=\FD@quoted@PrintChar
+ \if \ifFD@swa \@ifundefined{FD@s-\@tempa}{0}{1}\else 0\fi 1%
+ \expandafter
+ \endgroup
+ \csname FD@s-\@tempa\endcsname
+ \else
+ \endgroup
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\str \expandafter{\@tempa}}%
+ \@tempswatrue
+ \fi
+ \FD@printable@
+}
+\DeclareRobustCommand\strint[1]{\FD@string@func{int}{#1}}
+\@namedef{FD@printable\string\strint}#1{%
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \protected@edef\@tempa{%
+ \ifFD@swa \protect\FD@simple@int \else \strint \fi{\@tempa}%
+ }
+ \toks@=\expandafter{\the\expandafter\toks@ \@tempa}%
+ \@tempswatrue
+ \FD@printable@
+}
+\DeclareRobustCommand\macroparameter[1]{%
+ \gdef\FD@expression{\text{\normalfont\itshape\##1}}%
+ \global\chardef\FD@priority=5%
+ \global\FD@bracket@level=\z@
+ \FD@evaluate@false
+}
+\@namedef{FD@printable\string\macroparameter}#1{%
+ \toks@=\expandafter{\the\toks@\textrm{\emph{\##1}}}%
+ \@tempswatrue
+ \FD@printable@
+}
+\newcommand\TypesetIntegerExpression[1]{%
+ \protected@edef\@tempa{#1}%
+ \expandafter\FD@eval@expr \expandafter{\@tempa}%
+ \FD@expression
+}
+\newcount\FD@result
+\newcount\FD@bracket@level
+\def\FD@evaluate@true{\global\let\ifFD@evaluate@\iftrue}
+\def\FD@evaluate@false{\global\let\ifFD@evaluate@\iffalse}
+\FD@evaluate@false
+\def\FD@eval@expr#1{%
+ \expandafter\expandafter \expandafter\ifx
+ \expandafter\@car#1\x@relax\@nil \protect
+ #1%
+ \else\ifcat \expandafter\noexpand \@car#1\x@relax\@nil 0%
+ \global\FD@result=#1\x@relax
+ \xdef\FD@expression{\the\FD@result}%
+ \global\chardef\FD@priority=\ifnum \FD@result<\z@ 4\else 6\fi
+ \global\FD@bracket@level=\z@
+ \else
+ \begingroup
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \global\FD@bracket@level=\ifFD@swa\z@\else\@ne\fi
+ \protected@xdef\FD@expression{\protect\mbox{\texttt{\@tempa}}}%
+ \endgroup
+ \global\chardef\FD@priority=5%
+ \FD@evaluate@false
+ \fi\fi
+}
+\DeclareRobustCommand\add[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \FD@eval@expr{#2}%
+ \protected@xdef\FD@expression{\@tempa+\FD@expression}%
+ \ifFD@evaluate@ \global\advance \FD@result \a@count \fi
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \global\chardef\FD@priority=\z@
+ \endgroup
+}
+\DeclareRobustCommand\sub[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \FD@eval@expr{#2}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \protected@xdef\FD@expression{\@tempa-\FD@expression}%
+ \ifFD@evaluate@
+ \advance \a@count -\FD@result
+ \global\FD@result=\a@count
+ \fi
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \global\chardef\FD@priority=\z@
+ \endgroup
+}
+\def\FD@subexpression#1{${%
+ \advance \binoppenalty \FD@commapenalty
+ \advance \relpenalty \FD@commapenalty
+ \advance \FD@commapenalty \FD@commapenalty
+ $#1$}$%
+}
+\newcount\FD@commapenalty
+\FD@commapenalty=\binoppenalty
+\advance \FD@commapenalty \relpenalty
+\def\FD@bracket@expression{%
+ \protected@xdef\FD@expression{%
+ \ifcase\FD@bracket@level \or \protect\bigl \or \protect\Bigl \or
+ \protect\biggl \else \protect\Biggl \fi (%
+ \protect\FD@subexpression{\FD@expression}%
+ \ifcase\FD@bracket@level \or \protect\bigr \or \protect\Bigr \or
+ \protect\biggr \else \protect\Biggr \fi )%
+ }%
+ \global\chardef\FD@priority=5%
+ \global\advance \FD@bracket@level \@ne
+}
+\DeclareRobustCommand\int[1]{%
+ \begingroup
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \protected@xdef\FD@expression{%
+ \ifFD@swa
+ \text{\protect\FD@simple@int{\@tempa}}%
+ \else
+ \protect\FD@integer@func{int}{\@tempa}%
+ \fi
+ }%
+ \global\chardef\FD@priority=5%
+ \global\FD@bracket@level=\ifFD@swa\z@\else\@ne\fi
+ \FD@evaluate@false
+ \endgroup
+}
+\def\FD@simple@int#1{{\normalfont\itshape #1\/}}
+\def\FD@integer@func#1#2{%
+ \mathop{\mathrm{#1}{}}(\text{\FD@typeset@string{#2}})%
+}
+\DeclareRobustCommand\neg[1]{%
+ \FD@eval@expr{#1}%
+ \ifnum 5>\FD@priority \FD@bracket@expression \fi
+ \protected@xdef\FD@expression{-\FD@expression}%
+ \global\chardef\FD@priority=4%
+ \ifFD@evaluate@ \global\FD@result=-\FD@result \fi
+}
+\DeclareRobustCommand\mul[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \let\FD@left@priority=\FD@priority
+ \FD@eval@expr{#2}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \protected@xdef\FD@expression{%
+ \@tempa
+ \if \ifnum \FD@left@priority=\@ne e%
+ \else\ifnum \FD@priority<\thr@@ e%
+ \else\ifodd \FD@priority i\else e\fi\fi\fi e%
+ \cdot
+ \fi
+ \FD@expression
+ }%
+ \ifFD@evaluate@ \global\multiply \FD@result \a@count \fi
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \a@count=%
+ \ifnum \FD@priority=\@ne 1%
+ \else\ifnum \FD@left@priority=\@ne 2%
+ \else\ifodd\FD@left@priority
+ \ifodd\FD@priority 5\else 3\fi
+ \else
+ \ifodd\FD@priority 4\else 2\fi
+ \fi\fi\fi
+ \global\chardef\FD@priority=\a@count
+ \endgroup
+}
+\DeclareRobustCommand\div[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \FD@eval@expr{#2}%
+ \ifnum 4>\FD@priority \FD@bracket@expression \fi
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \protected@xdef\FD@expression{%
+ \@tempa
+ \ifcase\FD@bracket@level \or \protect\big \or \protect\Big \or
+ \protect\bigg \else \protect\Bigg \fi /%
+ \FD@expression
+ }%
+ \ifFD@evaluate@
+ \divide \a@count \FD@result
+ \global\FD@result=\a@count
+ \fi
+ \global\chardef\FD@priority=\@ne
+ \endgroup
+}
+\def\FD@eval@spec@expr#1#2#3{%
+ \expandafter\ifx \@car#1\x@relax\@nil #2%
+ #3#1%
+ \else
+ \FD@eval@expr{#1}%
+ \fi
+}
+\DeclareRobustCommand\max[2]{%
+ \begingroup
+ \toks@={}%
+ \a@count=-\maxdimen
+ \b@count=\z@
+ \FD@eval@spec@expr{\max{#1}{#2}}{\max}{\FD@maxmin@comma}%
+ \ifnum \a@count>\FD@bracket@level
+ \global\FD@bracket@level=\a@count
+ \fi
+ \protected@xdef\FD@expression{%
+ \protect\plainmax
+ \ifcase\FD@bracket@level \protect\@firstofone \or \protect\bigl
+ \or \protect\Bigl \or \protect\biggl \else \protect\Biggl
+ \fi{\{}%
+ \the\toks@
+ \protect\FD@subexpression{\FD@expression}%
+ \ifcase\FD@bracket@level \protect\@firstofone \or \protect\bigl
+ \or \protect\Bigl \or \protect\biggl \else \protect\Biggl
+ \fi{\}}%
+ }%
+ \ifFD@evaluate@
+ \ifnum \a@count>\FD@result \global\FD@result=\a@count \fi
+ \fi
+ \global\chardef\FD@priority=5%
+ \global\advance \FD@bracket@level \@ne
+ \endgroup
+}
+\DeclareRobustCommand\min[2]{%
+ \begingroup
+ \toks@={}%
+ \a@count=\maxdimen
+ \b@count=\z@
+ \FD@eval@spec@expr{\min{#1}{#2}}{\min}{\FD@maxmin@comma}%
+ \ifnum \a@count>\FD@bracket@level
+ \global\FD@bracket@level=\a@count
+ \fi
+ \protected@xdef\FD@expression{%
+ \protect\plainmin
+ \ifcase\FD@bracket@level \protect\@firstofone \or \protect\bigl
+ \or \protect\Bigl \or \protect\biggl \else \protect\Biggl
+ \fi{\{}%
+ \the\toks@
+ \protect\FD@subexpression{\FD@expression}%
+ \ifcase\FD@bracket@level \protect\@firstofone \or \protect\bigl
+ \or \protect\Bigl \or \protect\biggl \else \protect\Biggl
+ \fi{\}}%
+ }%
+ \ifFD@evaluate@
+ \ifnum \a@count<\FD@result \global\FD@result=\a@count \fi
+ \fi
+ \global\chardef\FD@priority=5%
+ \global\advance \FD@bracket@level \@ne
+ \endgroup
+}
+\def\FD@maxmin@comma#1#2#3{%
+ \FD@eval@spec@expr{#2}{#1}{\FD@maxmin@comma}%
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\protect \expandafter\FD@subexpression
+ \expandafter{\FD@expression}%
+ ,\penalty\FD@commapenalty\,%
+ }
+ \ifFD@evaluate@
+ \ifnum \a@count \ifx\max#1<\else>\fi \FD@result
+ \a@count=\FD@result
+ \fi
+ \fi
+ \ifnum \b@count<\FD@bracket@level \b@count=\FD@bracket@level \fi
+ \FD@eval@spec@expr{#3}{#1}{\FD@maxmin@comma}%
+}
+\DeclareRobustCommand\half[1]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \a@count=%
+ \ifnum \FD@priority=\@ne 1%
+ \else\ifodd\FD@priority 5%
+ \else 3\fi\fi
+ \global\chardef\FD@priority=\a@count
+ \protected@xdef\FD@expression{%
+ \protect\frac{1}{2}%
+ \ifnum \FD@priority>\thr@@ \else \cdot \fi
+ \FD@expression
+ }%
+ \ifFD@evaluate@
+ \ifodd \FD@result
+ \global\advance \FD@result \@ne
+ \global\divide \FD@result \tw@
+ \ifodd\FD@result \global\advance \FD@result \m@ne \fi
+ \else
+ \global\divide \FD@result \tw@
+ \fi
+ \fi
+ \endgroup
+}
+\DeclareRobustCommand\otherhalf[1]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \a@count=%
+ \ifnum \FD@priority=\@ne 1%
+ \else\ifodd\FD@priority 5%
+ \else 3\fi\fi
+ \global\chardef\FD@priority=\a@count
+ \protected@xdef\FD@expression{%
+ \protect\frac{1}{2}%
+ \ifnum \FD@priority>\thr@@ \else \cdot \fi
+ \FD@expression
+ }%
+ \ifFD@evaluate@
+ \ifodd \FD@result
+ \global\advance \FD@result \@ne
+ \global\divide \FD@result \tw@
+ \ifodd\FD@result\else \global\advance \FD@result \m@ne \fi
+ \else
+ \global\divide \FD@result \tw@
+ \fi
+ \fi
+ \endgroup
+}
+\DeclareRobustCommand\scale[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \let\FD@left@priority=\FD@priority
+ \FD@eval@expr{#2}%
+ \if \ifnum \FD@bracket@level<\@ne \ifnum \FD@priority>\thr@@
+ 1\else 0\fi\else 0\fi 1%
+ \protected@xdef\FD@expression{%
+ \protect\frac{\FD@expression}{1000}%
+ \if \ifnum \FD@left@priority<\thr@@ e\else
+ \ifodd \FD@left@priority i\else e\fi\fi e%
+ \cdot
+ \fi
+ \@tempa
+ }
+ \global\chardef\FD@priority=%
+ \ifnum \FD@left@priority=\@ne 1\else
+ \ifodd\FD@left@priority 5\else 3\fi\fi
+ \global\FD@bracket@level=\b@count
+ \else
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \protected@xdef\FD@expression{%
+ \@tempa
+ \if \ifnum \FD@left@priority=\@ne e%
+ \else\ifnum \FD@priority<\thr@@ e%
+ \else\ifodd \FD@priority i\else e\fi\fi\fi e%
+ \cdot
+ \fi
+ \FD@expression
+ \ifcase\FD@bracket@level \or \protect\big \or \protect\Big
+ \or \protect\bigg \else \protect\Bigg \fi /1000%
+ }%
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \global\chardef\FD@priority=\@ne
+ \fi
+ \ifFD@evaluate@
+ \global\multiply \FD@result \a@count
+ \global\divide \FD@result 500
+ \ifodd \FD@result
+ \global\advance \FD@result \ifnum 0>\FD@result - \fi \@ne
+ \fi
+ \global\divide \FD@result \tw@
+ \fi
+ \endgroup
+}
+\def\ifnumber#1#2#3\then{%
+ \FD@evaluate@false
+ \generic@if{%
+ $\TypesetIntegerExpression{#1}#2\TypesetIntegerExpression{#3}$%
+ }%
+}
+\newcommand\setint[2]{%
+ \Bheading{Default} \(\TypesetIntegerExpression{\int{#1}}\) =
+ \(\TypesetIntegerExpression{#2}\)%
+}
+\newcommand\setstr[2]{%
+ \Bheading{Default} \TypesetStringExpression{\str{#1}} =
+ \TypesetStringExpression{#2}%
+}
+\newcommand\setdim[2]{%
+ \a@dimen=#2\relax
+ \Bheading{Default} \TypesetStringExpression{#1} dimen = \the\a@dimen
+}
+\def\setcommand#1{\ifx#1\undefined@command
+ \expandafter\gdef\expandafter#1\else
+ \expandafter\gdef\expandafter\a@command\fi}
+\newcommand\resetint[2]{%
+ \Bheading{Value} \(\TypesetIntegerExpression{\int{#1}}\) =
+ \(\TypesetIntegerExpression{#2}\)%
+}
+\newcommand\resetstr[2]{%
+ \Bheading{Value} \TypesetStringExpression{\str{#1}} =
+ \TypesetStringExpression{#2}%
+}
+\newcommand\resetdim[2]{%
+ \a@dimen=#2\relax
+ \Bheading{Value} \TypesetStringExpression{#1} dimen = \the\a@dimen
+}
+\def\resetcommand#1{\gdef#1}
+\def\ifisint#1\then{%
+ \generic@if{integer $\TypesetIntegerExpression{\int{#1}}$ set}%
+}
+\def\ifisstr#1\then{%
+ \generic@if{string \TypesetStringExpression{#1} set}%
+}
+\def\ifisdim#1\then{%
+ \generic@if{dimension \TypesetStringExpression{#1} set}%
+}
+\def\ifiscommand#1\then{%
+ \generic@if{command \normalfont{\ttfamily\string#1} set}%
+}
+\def\offcommand#1{\Bheading{Turn off} \texttt{\string#1}}
+\def\oncommand#1{\Bheading{Turn on} \texttt{\string#1}}
+\newcommand\SetStringVariable[2]{%
+ \protected@edef\@tempa{\noexpand\MakePrintable \noexpand\@tempa
+ {FD@swa}{#2}}%
+ \@tempa
+ \protected@edef\@tempa{%
+ \toks@=\noexpand\expandafter{\noexpand\the \toks@ \@tempa}%
+ \ifFD@swa \noexpand\@tempswatrue \fi
+ }%
+ \protected@edef\@tempb{\noexpand\MakePrintable \noexpand\@tempb
+ {FD@swa}{#1}}%
+ \@tempb
+ \ifFD@swa
+ \begingroup
+ \let\PrintChar=\FD@quoted@PrintChar
+ \global\expandafter\let \csname FD@s-\@tempb\endcsname \@tempa
+ \endgroup
+ \else
+ \PackageError{fontdoc}{Names of string variables must be
+ simple\MessageBreak if they are to be assigned values}\@eha
+ \fi
+}
+\def\foreach(#1)#2{%
+ \def\next##1\endfor(#1){%
+ \@for\@tempa:=#2\do{%
+ \SetStringVariable{#1}{\@tempa}%
+ ##1%
+ }%
+ }%
+ \next
+}
+\def\comment{\par\noindent}
+\let\begincomment=\iftrue
+\let\endcomment=\fi
+%%% From file: fimain.dtx
+\def\inputetx#1{%
+ \begingroup
+ \edef\lowercase@file{\lowercase{%
+ \edef\noexpand\lowercase@file{#1}%
+ }}%
+ \lowercase@file
+ \global\slot@number=0%
+ \FD@slot@known@true
+ \IfFileExists{\lowercase@file.etx}{%
+ \FD@relax@encoding@tricks
+ \@@input \@filef@und
+ \let\relax=\x@relax
+ }{%
+ \PackageError{fontdoc}{File #1.etx not found}%
+ {\@eha\MessageBreak You can \protect\inputetx\space
+ some other file now, if you want.}%
+ }
+ \endgroup
+}
+\def\FD@relax@encoding@tricks{%
+ \def\relax{\let\relax=\x@relax\iffalse}%
+ \let\encoding=\fi
+ \outer\x@cs\def{endencoding}{\endinput}%
+}
+\def\encoding{%
+ \par
+ \ifFD@spec@ \addvspace{\bigskipamount}\fi
+ \begin{flushleft}
+ \global\slot@number=\z@
+}
+\outer\def\endencoding{%
+ \end{flushleft}
+ \ifFD@spec@ \addvspace{\bigskipamount}\fi
+}
+\newcommand\setslot[1]{%
+ \protected@edef\slot@name{%
+ \noexpand\MakePrintable \noexpand\slot@name {FD@swa}{#1}%
+ }%
+ \slot@name
+ \FD@tight@true
+ \Aheading{Slot
+ \ifFD@slot@known@
+ \the\slot@number\space
+ \else
+ \(\FD@slot@expression + \the\slot@number\)
+ \fi
+ `\FD@typeset@string{\slot@name}'%
+ }%
+ \protected@edef\@currentlabel{%
+ \ifFD@slot@known@
+ \the\slot@number
+ \else
+ \protect\(%
+ \FD@slot@expression+\the\slot@number
+ \protect\)%
+ \fi
+ \space(\protect\FD@typeset@string{\slot@name})%
+ }%
+ \ifFD@slot@known@ \ifslot@comment@ \comment{\slot@comment}\fi\fi
+}
+\def\endsetslot{%
+ \global\advance \slot@number \@ne
+ \FD@tight@false
+}
+\newcount\slot@number
+\def\FD@slot@known@true{\global\let\ifFD@slot@known@\iftrue}
+\def\FD@slot@known@false{\global\let\ifFD@slot@known@\iffalse}
+\FD@slot@known@true
+\newcommand\nextslot[1]{%
+ \FD@evaluate@true
+ \FD@eval@expr{#1}%
+ \ifFD@evaluate@
+ \global\slot@number=\FD@result
+ \FD@slot@known@true
+ \else
+ \global\let\FD@slot@expression=\FD@expression
+ \global\slot@number=\z@
+ \FD@slot@known@false
+ \fi
+}
+\newcommand\skipslots[1]{%
+ \FD@evaluate@true
+ \FD@eval@expr{#1}%
+ \ifFD@evaluate@
+ \global\advance \slot@number \FD@result
+ \else
+ \ifFD@slot@known@
+ \global\let\FD@slot@expression=\FD@expression
+ \else
+ \protected@xdef\FD@slot@expression{%
+ \FD@slot@expression+\FD@expression
+ }%
+ \fi
+ \FD@slot@known@false
+ \fi
+}
+\newcommand\setleftboundary[1]{%
+ \protected@edef\slot@name{%
+ \noexpand\MakePrintable \noexpand\slot@name {FD@swa}{#1}%
+ }%
+ \slot@name
+ \FD@tight@true
+ \Aheading{Left boundary `\FD@typeset@string{\slot@name}'}%
+ \protected@edef\@currentlabel{%
+ left boundary (\protect\FD@typeset@string{\slot@name})%
+ }%
+}
+\let\endsetleftboundary=\FD@tight@false
+\newcommand\setrightboundary[1]{%
+ \Aheading{Right boundary slot
+ \ifFD@slot@known@
+ \the\slot@number\space
+ \else
+ \(\FD@slot@expression + \the\slot@number\)
+ \fi
+ `\TypesetStringExpression{#1}'%
+ }%
+ \global\advance \slot@number \@ne
+}
+\newcommand\ligature[3]{%
+ \Bheading{\ifFD@spec@ Ordinary ligature\else Ligature\fi}
+ \@nameuse{FD@lig-#1}{#2}{#3}%
+}
+\newcommand\Ligature[3]{%
+ \Bheading{\ifFD@spec@ Mandatory ligature\else Ligature\fi}
+ \@nameuse{FD@lig-#1}{#2}{#3}%
+}
+\newcommand\oddligature[4]{%
+ \Bheading{Odd\footnote{#1} ligature}
+ \@nameuse{FD@lig-#2}{#3}{#4}%
+}
+\x@cs\def{FD@lig-LIG}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$\typeset@glyph{#2}%
+}
+\x@cs\def{FD@lig-/LIG}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#2}%
+}
+\x@cs\def{FD@lig-LIG/}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \typeset@glyph{#2}${}*{}$\typeset@glyph{#1}%
+}
+\x@cs\def{FD@lig-/LIG/}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*{}$%
+ \typeset@glyph{#2}${}*{}$\typeset@glyph{#1}%
+}
+\x@cs\def{FD@lig-/LIG>}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*\lfloor$\typeset@glyph{#2}%
+}
+\x@cs\def{FD@lig-LIG/>}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \typeset@glyph{#2}${}*\lfloor$\typeset@glyph{#1}%
+}
+\x@cs\def{FD@lig-/LIG/>}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*\lfloor$%
+ \typeset@glyph{#2}${}*{}$\typeset@glyph{#1}%
+}
+\x@cs\def{FD@lig-/LIG/>>}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*{}$%
+ \typeset@glyph{#2}${}*\lfloor$\typeset@glyph{#1}%
+}
+\def\nextlarger#1{\Bheading{Next larger} \typeset@glyph{#1}}
+\def\makerightboundary#1{%
+ \Bheading{Right boundary marker slot} designation \typeset@glyph{#1}%
+}
+\newcommand*\Unicode[2]{%
+ \comment{%
+ \spaceskip=\fontdimen2\font minus 1.1\fontdimen4\font
+ Unicode character \FD@codepoint{#1}%
+ \ifx \par#2\par \else , \FD@charname{#2}\fi.%
+ \linepenalty=300\par
+ }%
+}
+\newcommand*\textunicode[2]{%
+ \FD@codepoint{#1} \ifx\par#2\par\else(\FD@charname{#2})\fi
+}
+\providecommand*\FD@codepoint[1]{\texttt{U+\uppercase{#1}}}
+\providecommand*\FD@charname[1]{\textsc{\lowercase{#1}}}
+\newcommand\charseq[1]{%
+ \comment{Unicode character sequence:}%
+ \begin{IfBranch}%
+ \def\Unicode##1##2{%
+ \noindent\FD@codepoint{##1}
+ \ifx\par##2\par\else(\FD@charname{##2})\fi
+ \par
+ }%
+ #1%
+ \end{IfBranch}%
+}
+\def\varchar{\Bheading{Extensible glyph:}}
+\def\vartop#1{\Bheading{Top} \typeset@glyph{#1}}
+\def\varmid#1{\Bheading{Middle} \typeset@glyph{#1}}
+\def\varbot#1{\Bheading{Bottom} \typeset@glyph{#1}}
+\def\varrep#1{\Bheading{Repeated} \typeset@glyph{#1}}
+\let\endvarchar\relax
+\newif\ifslot@comment@
+\slot@comment@false
+\def\slot@comment{}
+\newcommand\setslotcomment[1]{%
+ \slot@comment@true
+ \gdef\slot@comment{#1}%
+}
+\newcommand\resetslotcomment[1]{\gdef\slot@comment{#1}}
+\newcommand\unsetslotcomment{%
+ \slot@comment@false
+ \global\let\slot@comment\@empty
+}
+\let\slot@font=\nullfont
+\newcommand\useexamplefont[1]{\font\slot@font=#1 }
+\newcommand\slotexample{%
+ \ifFD@slot@known@{\slot@font\char\slot@number}\fi
+}
+\newcommand\setfontdimen[2]{%
+ \Bheading{Fontdimen} \TypesetStringExpression{#1} is
+ \(\TypesetIntegerExpression{\int{#2}}\)%
+}
+\newcommand\ifdirect{\generic@if{direct}}
+\def\inputmtx#1{%
+ \begingroup
+ \edef\lowercase@file{\lowercase{%
+ \edef\noexpand\lowercase@file{#1}%
+ }}%
+ \lowercase@file
+ \let\endmetrics@hook=\@empty
+ \IfFileExists{\lowercase@file.mtx}{%
+ \skip@mtx@preamble
+ \@@input \@filef@und
+ \let\relax=\x@relax
+ }{%
+ \PackageError{fontdoc}{File #1.mtx not found}%
+ {\@eha\MessageBreak You can \protect\inputmtx\space
+ some other file now, if you want.}%
+ }
+ \endmetrics@hook
+ \endgroup
+}
+\def\skip@mtx@preamble{%
+ \def\relax{\let\relax=\x@relax\iffalse}%
+ \let\metrics=\fi
+ \outer\x@cs\def{endmetrics}{\endinput}%
+}
+\def\metrics{%
+ \begin{flushleft}%
+ \let\endmetrics@hook=\@empty
+}
+\outer\def\endmetrics{%
+ \endmetrics@hook
+ \end{flushleft}%
+}
+\def\ProvidesMtxPackage#1{%
+ \endmetrics@hook
+ \announce@package{#1}%
+ \def\endmetrics@hook{\finish@package{#1}}
+ \global\x@cs\let{FD@pack-#1}\@empty
+}
+\def\announce@package#1{%
+ \Aheading{[Start of metric package \textsf{#1}.}%
+}
+\def\finish@package#1{%
+ \Aheading{End of metric package \textsf{#1}.]}%
+ \par\addvspace\medskipamount
+}
+\newcommand\usemtxpackage[2][\x@relax]{%
+ \ifx \x@relax#1%
+ \@for\@tempa:=#2\do{%
+ \x@cs\ifx{FD@pack-\@tempa}\@empty \else
+ \inputmtx{\@tempa}%
+ \fi
+ }%
+ \else
+ \@tempswafalse
+ \@for\@tempa:=#1\do{%
+ \x@cs\ifx{FD@pack-\@tempa}\@empty \else \@tempswatrue \fi
+ }%
+ \if@tempswa
+ \inputmtx{#2}%
+ \fi
+ \fi
+}
+\newcommand\setkern[3]{%
+ \Bheading{Kern} \typeset@glyph{#1}${{}+{}}$\typeset@glyph{#2}%
+ ${}\rightarrow \TypesetIntegerExpression{#3}$%
+}
+\newcommand\resetkern[3]{%
+ \Bheading{Override kern} \typeset@glyph{#1}${{}+{}}$\typeset@glyph{#2}%
+ ${}\rightarrow \TypesetIntegerExpression{#3}$%
+}
+\newcommand\setleftkerning[3]{%
+ \Bheading{Kern} \typeset@glyph{#1} on the left like
+ \typeset@glyph{#2} \ConditionallyScaled{#3}}
+\newcommand\setrightkerning[3]{%
+ \Bheading{Kern} \typeset@glyph{#1} on the right like
+ \typeset@glyph{#2} \ConditionallyScaled{#3}}
+\newcommand\setleftrightkerning[3]{%
+ \Bheading{Kern} \typeset@glyph{#1} on the left and right like
+ \typeset@glyph{#2} \ConditionallyScaled{#3}}
+\newcommand\ConditionallyScaled[1]{%
+ \FD@evaluate@true
+ \FD@eval@expr{#1}%
+ \@tempswatrue
+ \ifFD@evaluate@ \ifnum \FD@result=\@m \@tempswafalse \fi\fi
+ \FD@evaluate@false
+ \if@tempswa scaled \(\FD@expression\)\else \ignorespaces \fi
+}
+\DeclareRobustCommand\kerning[2]{%
+ \begingroup
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \MakePrintable\@tempb{FD@swa}{#2}%
+ \protected@xdef\FD@expression{%
+ \mathop{\protect\mathrm{k{}}}(%
+ \text{\protect\FD@typeset@string{\@tempa}}%
+ ,\penalty\FD@commapenalty
+ \text{\protect\FD@typeset@string{\@tempb}}%
+ )%
+ }%
+ \global\chardef\FD@priority=5%
+ \global\FD@bracket@level=\@ne
+ \FD@evaluate@false
+ \endgroup
+}
+\def\ifiskern#1#2\then{%
+ \generic@if{kern \typeset@glyph{#1}${}+{}$\typeset@glyph{#2} set}%
+}
+\newcommand\unsetkerns[2]{%
+ \Bheading{Remove} all kerning pairs in
+ \FD@typeset@string@set{#1}${}\times{}$\FD@typeset@string@set{#2}%
+}
+\def\FD@typeset@string@set#1{%
+ \toks@={}%
+ \@for\@tempa:=#1\do{%
+ \protected@edef\@tempa{%
+ \noexpand\MakePrintable \noexpand\@tempa {FD@swa}{\@tempa}%
+ }%
+ \@tempa
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\do \expandafter{\@tempa}}%
+ }%
+ \expandafter\FD@typeset@string@set@ \expandafter{\the\toks@}%
+}
+\def\FD@typeset@string@set@#1{%
+ \TypesetList{$\{$}{$,\penalty\FD@commapenalty{}$}%
+ {$,\penalty\FD@commapenalty{}$}{$,\penalty\FD@commapenalty{}$}%
+ {$\}$}{$\emptyset$}{\FD@typeset@string}{#1}%
+}
+\newcommand\noleftkerning[1]{%
+ \Bheading{Remove kerns} on the left of glyphs in
+ \FD@typeset@string@set{#1}.}
+\newcommand\norightkerning[1]{%
+ \Bheading{Remove kerns} on the right of glyphs in
+ \FD@typeset@string@set{#1}.}
+\newcommand\noleftrightkerning[1]{%
+ \Bheading{Remove kerns} on any side of glyphs in
+ \FD@typeset@string@set{#1}.}
+\let\typeset@glyph=\TypesetStringExpression
+\DeclareRobustCommand\width[1]{\FD@glyph@metric{w}{#1}}
+\DeclareRobustCommand\height[1]{\FD@glyph@metric{h}{#1}}
+\DeclareRobustCommand\depth[1]{\FD@glyph@metric{d}{#1}}
+\DeclareRobustCommand\italic[1]{\FD@glyph@metric{i}{#1}}
+\def\FD@glyph@metric#1#2{%
+ \begingroup
+ \MakePrintable\@tempa{FD@swa}{#2}%
+ \protected@xdef\FD@expression{%
+ \protect\FD@integer@func{#1}{\@tempa}%
+ }%
+ \global\chardef\FD@priority=5%
+ \global\FD@bracket@level=\@ne
+ \FD@evaluate@false
+ \endgroup
+}
+\newcommand\setglyph[1]{%
+ \FD@tight@true
+ \Aheading{Set glyph `\typeset@glyph{#1}'}%
+}
+\newcommand\resetglyph[1]{%
+ \FD@tight@true
+ \Aheading{Reset glyph `\typeset@glyph{#1}'}}
+\let\endsetglyph=\FD@tight@false
+\let\endresetglyph=\FD@tight@false
+\newcommand\setrawglyph[8]{%
+ \Aheading{Glyph `\typeset@glyph{#1}'}
+ \Bheading{Taken from} slot $\TypesetIntegerExpression{#4}$ in
+ font \TypesetStringExpression{#2}%
+}
+\newcommand\setscaledrawglyph[9]{%
+ \Aheading{Glyph `\typeset@glyph{#1}'}
+ \Bheading{Taken from} slot $\TypesetIntegerExpression{#5}$ in
+ font \TypesetStringExpression{#2} \ConditionallyScaled{#4}%
+}
+\newcommand\setnotglyph[8]{%
+ \Aheading{Pseudoglyph `\typeset@glyph{#1-not}'}%
+}
+\newcommand\setscalednotglyph[9]{%
+ \setnotglyph{#1}{#2}{#3}{#5}{#6}{#7}{#8}{#9}%
+}
+\newcommand\unsetglyph[1]{%
+ \Aheading{Unset glyph `\typeset@glyph{#1}'}}
+\newcommand\glyph[2]{%
+ \Bheading{Glyph} `\typeset@glyph{#1}' \ConditionallyScaled{#2}%
+}
+\newcommand\glyphrule[2]{%
+ \Bheading{Rule} $\TypesetIntegerExpression{#1}$ by
+ $\TypesetIntegerExpression{#2}$%
+}
+\newcommand\glyphspecial[1]{%
+ \Bheading{Special} `\TypesetStringExpression{#1}'}
+\newcommand\glyphwarning[1]{%
+ \Bheading{Warning} `\TypesetStringExpression{#1}'}
+\newcommand\movert[1]{\Bheading{Rt}~$\TypesetIntegerExpression{#1}$}
+\newcommand\moveup[1]{\Bheading{Up}~$\TypesetIntegerExpression{#1}$}
+\newcommand\push{\Bheading{Push}}
+\newcommand\pop{\Bheading{Pop}}
+\newcommand\resetwidth[1]{%
+ \Bheading{Reset width to $\TypesetIntegerExpression{#1}$}%
+}
+\newcommand\resetheight[1]{%
+ \Bheading{Reset height to $\TypesetIntegerExpression{#1}$}%
+}
+\newcommand\resetdepth[1]{%
+ \Bheading{Reset depth to $\TypesetIntegerExpression{#1}$}%
+}
+\newcommand\resetitalic[1]{%
+ \Bheading{Reset italic to $\TypesetIntegerExpression{#1}$}%
+}
+\def\glyphpcc#1#2#3{
+ \push
+ \movert{#2}
+ \moveup{#3}
+ \glyph{#1}{1000}
+ \pop
+}
+\DeclareRobustCommand\glyphbboxright{%
+ \gdef\FD@expression{\protect\mathrm{glyphbboxright}}
+ \global\chardef\FD@priority=\tw@
+ \global\FD@bracket@level=\z@
+ \FD@evaluate@false
+}
+\newcommand\samesize[1]{%
+ \Bheading{Reset dimensions to those of `\typeset@glyph{#1}'.}%
+}
+\def\ifisglyph#1\then{\generic@if{glyph \typeset@glyph{#1} set}}
+\def\ifareglyphs#1\then{%
+ \generic@if{all glyphs in \FD@typeset@string@set{#1} are set}%
+}
+\def\ifisinslot#1#2\then{%
+ \generic@if{glyph \typeset@glyph{#1} assigned to slot
+ $\TypesetIntegerExpression{#2}$}%
+}
+\def\ifoption#1\then{%
+ \generic@if{option \TypesetStringExpression{#1}}%
+}
+%%% From file: fimapgen.dtx
+\def\mapfrags_subsystem{Map~fragments~writer}
+\def\declarepsencoding#1#2#3{\comment{%
+ This file corresponds to the \FD@typeset@string{#2} encoding vector.}}
+\newcommand\providepsencoding[3]{}
+\endinput
+%%
+%% End of file `fontdoc.sty'.
diff --git a/fonts/utilities/fontinst/source/CHANGES b/fonts/utilities/fontinst/source/CHANGES
new file mode 100644
index 0000000000..1c6155ecb8
--- /dev/null
+++ b/fonts/utilities/fontinst/source/CHANGES
@@ -0,0 +1,648 @@
+--- CHANGES ---
+
+This is the old changes log for the fontinst font installation package.
+As of v1.9, changes in the core are recorded using the \changes
+mechanism of the doc package, and appear as a section in the typeset form
+of the source (fisource.dvi). Changes to supporting files are typically
+recorded in each file, at the end.
+
+Feb 4 1993, v0.01: Created the file, wrote an afm and enc parser,
+ started on a vpl writer.
+
+Feb 10 1993, v0.02: Rewrote the enc parser, generally hacked around,
+ imported trig.tex to convert Adobe's italic slope (expressed in
+ angles!) into a font dimension (expressed as a ratio!) grrrrrr...
+
+Feb 12 1993, v0.03: Tidied up the comments a bit, moved the
+ \fontlist out of \readafm, added \writepl (as well as \writevpl).
+ Replaced \fake{CHARACTER} by having the .fd file give default
+ definitions for \char-CHARACTER. Added the \map and
+ \ligtable entries to \char-CHARACTER. Redefined \ligtable,
+ \map and \codingscheme as token lists. Moved the \kernpair's
+ into \ligtable.
+
+Feb 16 1993, v0.04: Added FontName, FullName, UnderlineThickness and
+ Notice. Added the source font encodings, and MAPFONT.
+ Discovered a seriousish bug---if a character exists in the afm
+ file but is not in the source encoding, then the fake character
+ is still overwritten, since we don't know what the source
+ encoding is going to be until later. Fixed this by reading in
+ the source encoding first, and looking to see if there is a
+ character in the source encoding for the one in the afm file.
+ Added \topaccent.
+
+17 Feb 1993, v0.05: Added the visual centre parameter to \topaccent,
+ and added \botaccent and \doublechar. Fixed a bug where the
+ default \missingchar had a horizontal rather than a vertical
+ rule. Added \settoken.
+
+19 Feb 1993, v0.06: Fixed a bug whereby a character which was in the
+ source encoding but not in the afm file overwrote it's faked
+ version. Changed the default \missingchar to be independent of
+ the values parsed from the afm file (so it doesn't matter when
+ you set a \missingchar). Added \parameter and \ligatures. Added
+ \kernalikes and \copykern, which meant I had to split \ligtable
+ back into \ligtable and \kerntable, since when you say \copykern
+ you only want the \kerntable copied, not the \ligtable.
+ Redefined \map so that it's more portable---the contents of \map
+ are allowed to assume they start in font \startfont, should move
+ and should finish having moved right by \charwd and in font
+ \stopfont. This makes it possible to have composite characters
+ within composite characters---for example to make <ffi> out of
+ <f><fi> and <fi> is in turn made out of <f><i>.
+
+23 Feb 1993, v0.07: Introduced the \character token list (previously
+ all of the variables had been set by \char-FOO). \botaccent,
+ \topaccent, etc are now commands to be used inside \defchar, so
+ you can say something like \defchar{FOO}{\ifblah ... \botaccent
+ ... \else ... \topaccent ... \fi}. Added \cramchar. Added
+ the shift-left argument to \doublechar.
+
+24 Feb 1993, v0.08: Replaced \charic by \leftbearing and
+ \rightbearing. Made the assingments in a \char-FOO command
+ global, so we can protect local variables. Fixed a bug with
+ \getchar{FOO} which used to end up calling \the\character.
+ However, \the\character may contain other \getchar{BAZ} calls,
+ which will override the values of \kernalike, \source, \target,
+ etc. So \getchar can't call \the\character. Added \shrinkfont.
+ Made all the AFM variables counts rather than dimens. Added
+ \afmunits, and did all the conversion between AFM units and TeX
+ units as late as possible (which means we can alter \afmunits
+ locally and perform scaling). Added \getfont so fonts are now
+ loaded dynamically, and can be scaled. Added \shrinkchar for
+ producing c&sc fonts.
+
+3 Mar 1993, v0.09: Added \fractionchar, \inferiorchar and
+ \superiorchar. No character is produced for characters called
+ .notdef in the target encoding. Produced a first bash at a
+ complement encoding to Cork, containing the Adobe standard and
+ Expert characters missing from Cork.
+
+9 Mar 1993, v0.10: A major spring clean. Introduced ATX and ETX
+ files, so the parser for AFM files now reads an AFM file and writes
+ out the same information in a TeX-friendly fashion as an ATX file.
+ Similarly, an ETX file contains the same information as an ENC file.
+ Introduced \inputatx, \inputetx and \inputenc to input an ATX, ETX
+ or ENC file if it already exists and to make it otherwise.
+
+14 Mar 1993, v0.11: A continuation of the spring clean. Redefined
+ \getchars to define everything locally. Redefined \writechars to
+ read the encoding from a .etx file. Discovered I'd used the command
+ \afmchar twice(!) so I redefined one of them to be \rawchar.
+ Rewrote the LIGTABLE section.
+
+15 Mar 1993, v0.12: Finished the spring clean of the file generation.
+ Redid \writevpl and \writepl. Read the FUD file in after the ATX
+ files, so the FUD file can use the parameters read in by the ATX
+ file. Fixed a bug with \afmchar that wrote incorrect values
+ to \charactersize in the ATX file. Rewrote \fontdimens to write the
+ PARAMETERs out immediately (since we are now writing the VPL file
+ when reading the FUD file). Finished the LIGTABLE section, redid
+ \copykern.
+
+22 Mar 1993, v0.13: Rewrote the generation of ATX files, so kern table
+ information is gathered together as in a LIGTABLE. Renamed
+ \defchars to \readafm. Renamed \writevpl to \makevpl ... \endvpl,
+ and rewrote it to cope with the new syntax of ATX files.
+
+24 Mar 1993, v0.14: Added \lkern and \rkern entries to ATX files,
+ replacing \copykern. Added kern copying to LIGTABLEs.
+
+29 Mar 1993, v0.15: Added \boundarychar, \nextlarger and \varchar.
+ Fixed a bug with \lrkern.
+
+30 Mar 1993, v0.16: Fixed a bug whereby FONTDIMENS was being output
+ rather than FONTDIMEN. Also \writepl was generating a VPL file.
+ And I discovered a bug with dvips that means that fonts generated
+ with designsize and designunits R 9.9945 cause a rounding error
+ and dvips complains about a design size mismatch. Grr... Fixed
+ a bug with outputting ligatures for characters without
+ kernings---previously I output a LABEL without checking that
+ there were actually going to be any LIG instructions (which there
+ might not be if, for example, it was a monoweight font).
+
+4 Apr 1993, v0.17: Added the interactive prompt. Generated the .fd
+ file. \makevpl and \makepl don't overwrite files any
+ longer---they give a message saying `FILENAME.(v)pl already
+ exists.'
+
+17 Apr 1993, v0.18: Added \makefamily, \maketexfont and \makerawfont.
+
+27 Apr 1993, v0.19: Fixed a bug with \finishligs, which caused
+ multiple LABEL instructions to be put down (I had a \labelfalse
+ where I should have had a \labeltrue).
+
+4 Aug 1993, v1.00: Ripped it up and started again... v1.00 is going
+ to be a fairly complete rewrite from the ground up. I can keep:
+
+ * the AFM parser
+ * the ENC parser
+ * much of the VPL and PL writer
+
+ but the fud engine is going to be replaced by the notion of a
+ glyphbase. The idea will be that all of the information kept in
+ the ATX and FUD files will be put into one file called a
+ `glyphbase'. Then we'll have two utilities:
+
+ * \makerawfont{ENCODING}{AFMFILE}{FONTNAME}
+ will convert an AFM file into a glyphbase and a property list.
+
+ * \maketexfont{ENCODING}{GLYPHBASES}{FONTNAME}
+ will convert a collection of glyphbases into a virtual font.
+
+ For example:
+
+ \makerawfont{adobe}{Times-Roman}{ptmr0}
+ \maketexfont{T1ulc}{ptmr0,cork}{ptmrq}
+
+ makes the raw font ptmr0.pl, the glyphbase ptmr0.gly, and then
+ converts the glyphbases ptmr0 and cork into the font ptmrq. This
+ notion of glyphbase will also allow users to modify fonts easily,
+ for example you could write a little ptmhax glyphbase, which
+ would override the default cork glyphbase by saying:
+
+ \maketexfont{T1ulc}{ptmr0,ptmhax,cork}{ptmrq}
+
+ This will make it much easier to tweak fonts. I'll also specify
+ the glyphbase syntax, and do my best to make everything upwardly
+ compatible.
+
+ On the 4th of August I started on the above. I wrote
+ \makeglyphbase, which converts an AFM file into a glyphbase, and
+ I wrote the glyphbase commands to store the glyphbase information
+ in TeX. The main thing that's missing is the PL and VPL writers,
+ and the ligature, nextlarger and varchar entries.
+
+10 Aug 1993, v1.01: Edited trig.tex to remove uses of \then. Separated
+ \maketexfont into \inputglyphbase and \makevirtualfont. Added the
+ ability to write CHARACTER instructions, (OK, but not the MAPFONTs
+ yet).
+
+11 Aug 1993, v1.02: Only output CHARDP, CHARHT and CHARIC when they
+ are positive. Added the MAPFONT and \mapfont instructions.
+
+12 Aug 1993, v1.03: Corrected a bug where I was calling \inputetx
+ *after* an \openout\outfile, which caused the \outfile to be closed,
+ if the etx file had to be generated.
+
+22 Aug 1993, v1.04: Added the concept of variable and number expression.
+ Included trig.tex as part of this file. Changed design size to an
+ integer. Renamed `glyphbase' to `metric file', and changed the
+ syntax of ETX files. Only write out SELECTFONT instructions when
+ necessary.
+
+23 Aug 1993, v1.05: Added the font dimensions.
+
+24 Aug 1993, v1.06: Made the slot of each glyph an int variable like
+ any other. Added dim variables. Made designsize a dim variable,
+ which should cure a bug that was causing design sizes not to match
+ up. Added the LIGTABLE. Fixed a bug with \inputetx and \inputmtx
+ which caused the redefinition of \relax to survive past the
+ \inputFOO command. Fixed a bug with \vplrule, since I'd got the
+ arguments to SETRULE the wrong way round (again!).
+
+25 Aug 1993, v1.07: Added the VARCHAR and NEXTLARGER entries. Added
+ the encoding documentation commands. Renamed the file to
+ fontinst.sty.
+
+26 Aug 1993, v1.08: Added the documentation of MTX files.
+
+27 Aug 1993, v1.09: Corrected a bug with \comment. Added \tfmtomtx.
+ Removed the SCALE argument to \setrawglyph. Added \convertafm to
+ convert integer AFM units to a dimen, trying to minimize rounding
+ errors whilst avoiding rounding errors. Renamed \leftkerning and
+ \rightkerning to \setleftkerning and \setrightkerning.
+
+30 Aug 1993, v1.10: Added \resetwidth, \resetheight, \resetdepth and
+ \resetitalic. Added the ability to use \width{GLYPH} etc. inside
+ \setglyph{GLYPH}. Added everyglyph and everyendglyph.
+
+10 Sep 1993, v1.11: Discovered a bug with the VPL glyphs which was
+ causing it never to write out a SELECTFONT instruction.
+
+13 Sep 1993, v1.12: Added the \familyinst...\endfamilyinst commands.
+ Added commands to zero the fonts between calls of \makefont, so
+ one document can make a large number of fonts.
+
+14 Sep 1993, v1.13: FIRST ALPHA-RELEASE OF V1.
+ Changed the syntax of \useafm and \useetx to use
+ the same parameters as LaTeX NFSS. Removed the prefix f0 from
+ the beginning of the font names, in a pathetic attempt to fit
+ MS-DOS 8+3 filenames. Added the \tempfile command.
+
+4 Oct 1993, v1.14: Removed a spurious \let in \docnextslot. Thanks
+ to Damian Cugley for spotting that one. Added \usetfm to \familyinst.
+
+5 Oct 1993, v1.15: Fixed a bug with \dotfm, which was causing it to
+ generate a PL file, even though the font was already in TFM
+ format! Thanks again to Damian. Also changed
+ \let\Input=\@@input to a catcode hack, just in case fontinst.sty
+ is read in by LaTeX when @ isn't a letter. That one was spotted
+ by Paul Thompson.
+
+6 Oct 1993, v1.16: Replaced Phil Taylor's trig macros with David
+ Carlisle's. Added the PL parser. Fixed a bug with the bug fix
+ for \dotfm, where I'd removed an \inputmtx command that was
+ needed... And I fixed a bug which was causing the VPL files to
+ be generated once for each font that contributed to the VPL file.
+ Damian got those ones as well.
+
+11 Oct 1993, v1.17: Added the SIZE argument to \useafm and \usepl,
+ and redid the FD generation to use the size info. This should
+ allow fonts like Malvern to be generated at different design
+ sizes and still have a sensible FD file. NOTE: This means old
+ fontinst files will no longer work! I also made \pltomtx create
+ a \setdim{designsize} command.
+
+13 Oct 1993, v1.18: Fixed a bug with \calculateitslant which caused
+ it to bomb if the italic angle didn't have a decimal... this was
+ caused by allowing extraneous spaces at the end of the angle.
+ These have now been stripped away. Thanks to Paul Thompson for
+ spotting that one!
+
+15 Oct 1993, v1.19: Discovered a bug with \familyinst, which caused
+ only one ETX file to be loaded. This one was introduced when I
+ added the SIZE arguments, since I reorganized the main
+ \endfamilyinst loop. Serves me right! This is now fixed, but
+ I'm left with the problem that the sensible order to generate VPL
+ files is not the sensible order to generate FD lines in. FD
+ files need the SIZE parameter inside the SERIES and SHAPE,
+ whereas if a font is contributing to a number of SERIES and
+ SHAPEs but only one SIZE, then it's sensible to have it outside
+ the SERIES and SHAPE parameters. Oh dear...
+
+19 Oct 1993, v1.20: Added the glyph `missingglyph' which is produced
+ whenever a glyph is missing.
+
+3 Nov 1993, v1.21: Corrected a bug with \kerning, which was causing
+ \kerning{A}{V} to give the kerning between V and A! And I added
+ the PL names for the math font parameters NUM1--AXISHEIGHT.
+ Damian spotted those ones. Rewrote the main loop as I said I
+ would have to in the note on v1.19, so there's no useless
+ regeneration of fonts now.
+
+17 Nov 1993, v1.22: Restored the final parameter to
+ \DeclareFontShape which had disappeared somehow! Rob Hutchings
+ spotted this one. And I stopped trying to be clever about
+ checking to see if a glyph has been defined before using it.
+ This means you get a horrible error message if you try to use an
+ undeclared glyph, but hey ho. Trying to trap this has caused so
+ many problems with other things breaking that I think I'll give
+ up :-) Added the \glyphwarning command, and removed the
+ `missingglyph' glyph. Docstripped David's trig.doc into
+ trig.sty, so I don't have to worry about trig.doc generating the
+ trig.sty file. Saved the catcodes of ` ', `@', `~' `_' and NL so I
+ so I can use @ and _ for internal macro names, space and NL
+ for ignored white space, and ~ for `real' white space. Renamed
+ all the internal commands (apart from the documentation ones) to
+ have _ in their names.
+
+29 Nov 1993, v1.23: Added a check that a glyph exists before writing
+ it to a (V)PL file... this was causing fontinst to crash if there
+ was a glyph missing from an AFM file. Yannis Haralambous and Paul
+ Thompson spotted this one.
+
+23 Dec 1993, v1.24: Removed the \familyinst...\endfamilyinst interface,
+ and replaced it by \installfonts ... \endinstallfonts, which makes
+ it easier to generate FD files that look like standard LaTeX2e FD
+ files. Removed (I'm not sure if this is a great idea) the ability
+ to specify an encoding for an AFM file, since I'm not sure every
+ dvi-to-ps converter can re-encode raw fonts. I added the
+ \declarefamily command to specify which encoding string corresponds
+ to which ETX file.
+
+24 Dec 1993, v1.25: Redid the \declare... commands, and replaced
+ everyglyh and everyendglyph by sidebearings.
+
+25 Dec 1993, v1.26: Drank a lot.
+
+26 Dec 1993, v1.27: Added \setcommand, \resetcommand and \ifiscommand.
+
+27 Dec 1993, v1.28: Bug-fixes in \setcommand and \resetcommand. Redid
+ \pltomtx so that it can read the encoding from the CODINGSCHEME line
+ in the file. Moved the documentation and tables into fontdoc and
+ fonttab.tex.
+
+28 Dec 1993, v1.29: Removed the fd-commands argument from \makefont,
+ since the FD syntax is to allow FD-commands dependent on
+ encoding/family/series/shape but not on size. This means we can't
+ generate font-specific FD-commands, but I've never seen those used,
+ so I'm not too worried... Fixed a bug with the CC commands, which
+ was producing a glyph with a different width than its horizontal
+ escapement, and I'm not sure what every DVI driver would do with
+ that. Replaced \etxtopl with \mtxtopl. Replaced the GLYPH COMMAND
+ \rawglyph with the MTX COMMAND \setrawglyph.
+
+29 Dec 1993, v1.30: Fixed a bug with \setrawglyph, which wasn't
+ checking to see if the glyph was already defined. Added
+ \unsetglyph. Corrected the spelling of `\immedaite' (sic) in
+ \vpl_nextlarger.
+
+3 Jan 1994, v1.301: The glyph warning message is now only produced when
+ the glyph is used, rather than when it is defined. And I've moved
+ over to three-digit version numbers, since I was going through the
+ two-digit ones quite rapidly. Added \bye, so fontinst documents can
+ run under LaTeX as well as plain TeX. Added \unsetint, \unsetstr,
+ \unsetdim and \unsetcommand. Renamed \makefont and \makefamily to
+ \installfont and \installfamily.
+
+4 Jan 1994, v1.302: Fixed a bug with the definition of \bye.
+
+6 Jan 1994, v1.303: Added the FONTNAME argument to \installfont.
+ Actually got rid of everyglyph.
+
+8 Jan 1994, v1.304: Added minimumkern and \resetglyph. Fixed a bug
+ with \vpl_kerning, which was swapping the left- and right-kerns.
+ Surprising I never spotted this before...
+
+9 Jan 1994, v1.305: Worked on the MTX and ETX files.
+
+10 Jan 1994, v1.306: Worked on the MTX and ETX files.
+
+12 Jan 1994, v1.307: Edited the documentation.
+
+20 Jan 1994, v1.308: Added the rawscale integer variable, and the
+ \setnotglyph command. Redid the way that CC instructions are
+ processed, to use the dimensions stored in the glyph-not variables.
+ Set all of the saved VPL commands to \relax so that they can be
+ \edef'ed on without having to protect them. Replaced some \def\foo{}
+ by \let\foo\empty_command's. Replaced a large definition that was
+ being made by \CHARACTER (when parsing PL files) by a \let. Redid
+ the datatype used to store kerning so it uses control sequences as a
+ compact representation of glyph names. All in all, fontinst now runs
+ in 79% of the time and 77% of the space that it did last week.
+
+21 Jan 1994, v1.309: Saved some more time and space on the kern table.
+
+22 Jan 1994, v1.310: Added the `FONT scaled AMOUNT', made \setkern take
+ account of \int{rawscale}. Moved the change log into a separate
+ CHANGES file. Redid \samesize and \resetwidth so that the width is
+ adjusted by a MOVERIGHT, so the glyph will have the correct horizontal
+ escapement. Corrected a typo which had renamed \resetint to \setint
+ (oops!). Corrected a typo of `itslant' rather than `italicslant'.
+ Added the \transformfont command and \mtxtomtx. Changed the
+ definition of \unfakable{foo} in latin.mtx to look to see if there's a
+ glyph <foo-not> to get the dimensions for. Added a fake <space> and a
+ fake <dotlessj> which is a missing glyph rule with the dimensions
+ combined from <j> and <dotlessi>. Changed the default interword
+ stretch to be 1/3 of interword space, rather than zero. Removed the
+ checks for the existence of <space> and <x> in OT1.etx and T1.etx,
+ since these are now faked in latin.mtx. Renamed the PS/CM math fonts,
+ after a discussion with Karl Berry, added the OMS and OMX math fonts.
+ Added the Greek letters, digits and other humanists to unsetalf.mtx.
+ Added the DEFAULTRULETHICKNESS and BIGOPSPACING commands to the PL
+ parser. Fixed a bug I'd introduced by giving \vartop, \varmid,
+ \varrep and \varbot no parameters. Oops. Created timesmat.sty and
+ testmath.tex. All in all, a reasonable day's work...
+
+23 Jan 1994, v1.311: Added some more tests to testmath.tex. Added the
+ new math sizes to timesmat.sty. Fixed a bug with fontstnd.tex which
+ was causing it to generate the wrong FD entry for italic fonts. Fixed
+ a bug with CHARACTER parsing in \pltomtx which wasn't resetting the
+ values of WIDTH, HEIGHT, DEPTH and CHARIC between glyphs.
+
+24 Jan 1994, v1.312: Added the SEVENBITSSAFE command to the PL parser.
+
+25 Jan 1994, v1.313: Restored the catcode of ~, which I'd left as 10.
+ Made /, < and > in zptmcmrm come from cmmi rather than ptmri. Added
+ zptmcmr to fontptcm.tex, which is Adobe Times with +, =, (, ), [ and ]
+ taken from CMR. This means that [...] and (...) in text is different
+ from in math, but means that the delimiters are the right size for
+ math setting with CM symbols, and match the growing delimiters in cmex.
+ Moved the files ptmcmhax.mtx and psycmhax.mtx to zrmhax.mtx and
+ zrvhax.mtx.
+
+27 Jan 1994, v1.314: Took the textstyle and displaystyle big operators
+ in zpsycmrv from cmex8 rather than cmex10, since they are more
+ suitably sized for the <summation> and <product> from Adobe Symbol.
+ Made all the accents in latin.mtx zero depth (which TeX's math accent
+ placement requires). Discovered that cmex8 doesn't have a
+ CODINGSCHEME, so I added one by hand to the PL file.
+
+30 Jan 1994, v1.315: Replaced cmex8 in zpsycmrv by cmex9. Added
+ <epsilon1>, <pi1> and <rho1> to unsethum.mtx. Added the \skewchar
+ declaration for zptmcmrm. Fixed a bug which was causing negative
+ mathchardefs. Finished off the skewchar kerns for zptcmrm.
+ Renamed timesmat.sty to mathptm.sty, since there's already a
+ timesmat.sty.
+
+7 Feb 1994, v1.316: Fixed the \ProvidesPackage line in mathptm.sty.
+
+8 Feb 1994, v1.317: Fixed a bug with fontptcm.tex where I'd put the
+ \skewchar command in the wrong argument! Made the `size' argument
+ to \installfont an FD size specification. Added fakes for <lslash>
+ and <Lslash> built from <lslashslash> to latin.mtx. Added a check
+ that a ligature glyph exists before writing out the LIGTABLE entry.
+ Edited the documentation a bit---thanks to Karl Berry for comments.
+ Added the fontcmro example, inspired by Norman Walsh. Fixed a bug
+ with .fd file generation which caused multiple \DeclareFontShape
+ entries to be produced. Added \unfakable{endash} and
+ \unfakable{emdash} to latin.mtx. Sebastian spotted that one.
+
+10 Feb 1994, v1.318: Added \unfakable{dotlessi} to latin.mtx. Karl
+ Berry pointed that one out.
+
+1 Mar 1994, v1.319: Added the HEADER. Karl Berry pointed that one out
+ too.
+
+6 Apr 1994, v1.320: Write out a LABEL BOUNDARYCHAR ligable entry where
+ necessary. Alan Hoenig pointed that one out. Rewrote mathptm.sty
+ to remove some of the nastier hacks.
+
+7 Apr 1994, v1.321: Added the ability to generate font substitutions
+ in the FD files.
+
+8 Apr 1994, v1.322: Fixed a bug with font substitution which was
+ causing the font substitutions to be written out before the real
+ fonts. Moved the mathptm package to standing on its own.
+
+17 Apr 1994, v1.323: Added the top-level \latinfamily commands, and
+ updated the example files and documentation to use them. Added
+ OT1ci.etx. Made the list of files in an \installfont command
+ expanded before running along the list, so you can have a macro
+ which expands out to a list of files now. Added substitutions for
+ semibold and demibold, for upright italic, and for sc to nc. Added
+ OT19.etx, OT1c9.etx, OT1ci9.etx, OT1i9.etx, T19.etx and T1c9.etx.
+ Removed OT1o.etx.
+
+19 Apr 1994, v1.324: Removed italic and oblique small caps. Fixed a
+ bug which was causing the latin.mtx file to be read in inside a
+ group if a latin family without an expert font was created.
+
+25 Apr 1994, v1.325: Removed a bug which caused sc fonts to have the
+ same names as u&lc fonts. Fixed a bug which was causing oblique
+ fonts not to be generated properly. Fixed a bug with FD
+ generation which was producing too few arguments for
+ DeclareFontShape for substitutions.
+
+27 May 1994, v1.326: Made fontinst.tex a 2e document. Fixed a bug
+ with generating slant which was generating slant in design size per
+ point rather than points per point. Sigh. Ciar\'an \'O Duibh\'in
+ spotted that one. Declared this to be the first full release.
+
+1 Jun 1994, v1.327: Fixed bug with filename parsing which was losing
+ variants. Rewrote the encoding files to use the OT1 tt encoding
+ whenever monoweight is set. Removed the f-liagatures from the T1
+ encoding for monowidth fonts. Sebastian spotted that one.
+
+2 Jun 1994, v1.328: Fixed a bug with FD generation: I'd added the
+ extra argument for series substitutions but not shape
+ substitutions. Ta Sebastian again.
+
+3 Jun 1994, v1.329: Made Upsilon1 unfakable.
+
+15 Jun 1994, v1.330: Fixed a bug with font substitution which was
+ ignoring chains of substitutions such as bx -> b -> db. Added the
+ m->l substitution. Renamed the `mn' and `bn' series to `mc' and
+ 'bc'. Added the `k' and `m' series.
+
+16 Jun 1994, v1.331: Sebastian spotted another problem with
+ substitutions. If a font had both a series and a shape
+ substitution, the series was sometimes getting lost.
+ Steve Grathwohl pointed out that I'd forgotten to switch off
+ kerning before loading the math italic fonts in fontcmro.
+
+27 Jun 1994, v1.332: Added braces to \needsfontinstversion, which was
+ clobbering \a_dimen and \b_dimen. Fixed a bug with compwordmark
+ which was causing it to get letterspacing added to it. Added the
+ GLYPH-spacing variable to cope with this. These were
+ spotted by Constantin Kahn.
+
+29 Jun 1994, v1.333: Added \ProvidesFile line to the .fd files.
+
+16 Aug 1994, v1.334: Added \frompl, fixed bugs with \resetdim and
+ <ccedilla>---all reported by Constantin Kahn.
+
+9 Sep 1994, v1.335: Fixed a bug with NEXTLARGER and VARCHAR generation
+ which was causing the entries to be printed out for nonexistent
+ glyphs---spotted by Alan Hoenig. Updated the example installation
+ files for Times, Helvetica and Courier. Updated to a more recent
+ trig.sty, and added the hacks to allow trig.sty to be used outside
+ LaTeX2e. Made fontinst.sty initex processable, so you can save
+ memory by building your own fontinst format without plain. Fixed
+ the names of `narrow' fonts, which used to clobber the non-narrow
+ fonts---spotted by Peter Busk Laursen.
+
+12 Sep 1994, v1.336: Fixed a bug with fontcmro, which was listing the
+ 9pt font as being 10pt in the fd file---spotted by Steve Grathwohl.
+
+22 Sep 1994, v1.337: Corrected spelling mistake in \declareencoding in
+ error message of \CODINGSCHEME---spotted by Alan Hoenig.
+
+8 Oct 1994, v1.338: Corrected definition of \space in
+ fontinst.ini---spotted by Rob Hutchings.
+
+18 Nov 1994, v1.339: Added 8r.etx and 8r.enc from Sebastian.
+ Distributed a patched fontinst.rc file containing a reimplementation
+ of \latinfamily that uses the 8r encoding.
+
+21 Nov 1994, v1.400: Added missing \fi to 8r.etx---spotted by Steve
+ Grahthwohl. Added \mtxtopl for expert fonts in
+ \latinfamily---spotted by Rob Hutchings.
+
+29 Nov 1994, v1.401: Added hyphen+hyphenchar = hyphenchar lig to
+ T1.etx (so that foo-bar words can be hyphenated as foo<hyphenchar>
+ bar)---spotted by Frank Mittelbach. Made default stretch and
+ shrink 50% and 16.7% of <space> respectively. Added \everyjob to
+ fontinst.ini to load the fontinst.rc file---spotted by Rob
+ Hutchings.
+
+7 Dec 1994, v1.402: Corrected typos with 8r.etx---spotted by
+ Constantin Kahn.
+
+12 May 1995, v1.403: Mentioned the pl files in fontinst.tex, and added
+ the encoding TEX TEXT WITHOUT F-LIGATURES. Both spotted by John
+ Wells.
+
+16 Sep 1995, v1.500: Incorporated changes by SPQR and CK in their
+ fontinst.rc file. In detail... Added the \NOFILES debugging
+ option. Used SPQR and CK's complete reimplementation of
+ \latinfamily. Added the TEXBASE1ENCODING. Added \etxtopl and
+ \installrawfont. Added the setting of \errorcontextlines. Grabbed
+ T1i.etx from CTAN. Added the setting of \newlinechar (pointed out
+ by Constantin). Fixed bug with \resetcommand which stopped braces
+ around the csname from working (Contantin again). Removed the
+ contrib/zd directory at Constantin's request. Rewrote the
+ documentation. Added fontinst.cls.
+
+[16 Sep 1995, v1.500 on CTAN with fonts/psfonts/tools]
+
+21 Sep 1995, v1.501: Corrected some typos in the documentation.
+ Added kerns for ng, Ng and hyphenchar. Fixed spacing in faked
+ <FFsmall> and friends. Fixed kerning of <dotlessJ>. Raised the
+ <macron> in <dbar> to half-way between the xheight and the height of
+ <d>. Added fake <ng> -> <eng>. Made \cscbotaccent and
+ \csctopaccent look to see if both of the glyphs exist rather than just
+ the first. Thanks to Hilmar Schlegel for all these points.
+
+29 Sep 1995, v1.502: Renamed all the distributed afm files from
+ *0*.afm to *8a*.afm. Updated the file header on 8r.etx.
+ Renamed Karl's fontinst.rc to karl-fontinst.rc, to avoid it being
+ picked up by every punter.
+ All pointed out by Sebastian.
+
+24 Nov 1995, v1.503: Included Alan Hoenig's vfinst in contrib/vfinst.
+
+23 Jan 1996, v1.504: Included some of Sebastian's changes to OT1.etx:
+ upped stretch and shrink to .6 and .24 of space; reduced extra
+ space after . to .24 of space; removed <endash> + <hyphen> =
+ <emdash> ligature from OT1 monowidth; made \setslot{grave}
+ etc. into \setslot{\lc{Grave}{grave}} etc; fixed a bug with T1c
+ `monoweight' -> `monowidth' (!); implemented Rob's changes to
+ small caps and small accented caps; included fake kerning for
+ Udieresis; added hackery from spqr.rc for faking small caps and
+ faking widths.
+
+[28 Jan 1996, v1.504 on CTAN with:fonts/psfonts/tools]
+
+24 Jan 1996, v1.505: Updated fontptcm.tex to use ptmr8a rather than ptmr0.
+
+25 Jan 1996, v1.506: Added extra braces to \latinfamily to stop
+ setting of \digits in one run from affecting it in subsequent
+ runs. Spotted by Richard Walker.
+
+23 Feb 1996, v1.507: Replaced vpltovf by vptovf. Spotted by Sebastian.
+
+17 Jun 1996, v1.508: Added an \ifdim check to stop lots of MOVERIGHT R 0.0
+ instructions being generated. Spotted by Sebastian.
+
+18 Jun 1996, v1.509: Allow real numbers in .afm files. Spotted by
+ Gintautas Grigelionis. Made spaces before ; optional, in order to
+ parse v2.0 afm files (spaces before ; were made compulsory in v3.0).
+
+20 Jun 1996, v1.510: Added 9d and 9o encodings for fonts with
+ old-style digits.
+
+21 Jun 1996, v1.511: Removed \endinput from the end of .fd files, so
+ that additions can be made more easily.
+
+24 Jul 1996, v1.512: Updated version of trig.sty.
+
+7 Aug 1996, v1.513: Moved unfakable glyphs eariler in latin.mtx so
+ that all-caps fonts will work.
+
+6 Feb 1997, v1.514: Added a zero-width rule to cwm in latin.mtx (to
+ stop the MAP entry from being empty). Made cwm 1ex high.
+
+--- Copyright 1993, 1994, 1995, 1996 Alan Jeffrey ---
+
+11 Feb 1997, unofficial v1.6 SPQR on CTAN:fonts/psfonts/tools
+ Derived from v1.504 with minor hacks and fixes (not documented).
+
+29 May 1998, unofficial v1.7 SPQR on CTAN:fonts/psfonts/tools
+ Derived from v1.6 with fixes by UV. Corrected mapping of weights.
+ Added code for 8r-encoded AFM files (intended to cope with ttf2afm
+ limitations, but taken out again after ttf2afm was updated).
+
+22 Jun 1998, unofficial v1.8 UV
+ Derived from v1.7 and v1.511. Many .etx/.mtx files touched up.
+ fontinst.sty and fontdoc.sty now generated from fontinst.dtx.
+ \textcompfamily integrated into \latinfamily. Reintroduced
+ oldstyle encodings (from v1.511). 8y.etx/8y.mtx added as an
+ alternative to 8r.etx/8r.mtx. ts1.etx and textcomp.mtx revised.
+
+30 Jun 1998, unofficial v1.800 UV on CTAN:fonts/utilities/fontinst
+ Several changes to examples/mathptm and examples/mathptmx.
+
+07 Jun 1998, v1.801: Fixed a bug when oldstyle small-caps fonts
+ are generated from <font>8r + <font>8x instead of <font>c8r.
diff --git a/fonts/utilities/fontinst/source/fibasics.dtx b/fonts/utilities/fontinst/source/fibasics.dtx
new file mode 100644
index 0000000000..eb8bc1b7a1
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fibasics.dtx
@@ -0,0 +1,2345 @@
+% \CheckSum{1505}
+% \iffalse meta-comment
+%
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
+% the fontinst maintenance team and any individual authors listed
+% elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.1 or, at your option, any later version.
+%
+%%% From file: fibasics.dtx
+%
+%<*driver>
+\documentclass{ltxdoc}
+\title{The \package{fontinst} utility}
+\author{Alan Jeffrey\and Sebastian Rahtz\and Ulrik Vieth\and
+ Lars Hellstr\"om}
+\usepackage{fisource}
+\begin{document}
+\maketitle
+\DocInput{fibasics.dtx}
+\PrintIndex
+\end{document}
+%</driver>
+% \fi
+%
+% \StopEventually{}
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \begin{quote}
+% ``Can't say I've ever been too fond of beginnings, myself.
+% \emph{Messy} little things. Give me a good ending any time.
+% You know where you \emph{are} with an ending.''\relax
+% \nobreak\hskip 0pt plus 1fill\penalty0\hskip 2em\relax
+% \vadjust{}\nobreak\hskip 1em plus 1fill\textemdash
+% \ from \emph{The kindly ones} by \textsc{Neil Gaiman} et al.^^A
+% \nobreak\hskip-\parfillskip\vadjust{}
+% \end{quote}
+%
+%
+% \section{The first and the last}
+%
+% \subsection{Version numbers}
+%
+% We start by making some default catcode assignments, in case we are
+% using ini\TeX{}.
+% \begin{macrocode}
+%<*pkg>
+\catcode`\{=1
+\catcode`\}=2
+\catcode`\#=6
+\catcode`\^=7
+%</pkg>
+% \end{macrocode}
+%
+% \begin{macro}{\fontinstversion}
+% If we are running under ini\TeX{} we cannot put the identification
+% stuff any earlier than this. Note that |\fontinstversion| is not
+% just used for indentification but also in |\needsfontinstversion|.
+% \begin{macrocode}
+%<pkg|doc>\def\fontinstversion{1.933}
+% \end{macrocode}
+% \end{macro}
+%
+% If we are running under ini\TeX{} or \texttt{plain}, we have to get
+% around the \LaTeX{}-specific |\ProvidesPackage| stuff.
+%
+% \begin{macrocode}
+%<*pkg>
+\ifx\ProvidesPackage\undefined
+ \def\NeedsTeXFormat#1{}
+ \def\ProvidesPackage#1[#2]{}
+\fi
+%</pkg>
+% \end{macrocode}
+%
+% Now we can identify ourselves as usual.
+%
+% \begin{macrocode}
+%<doc>\NeedsTeXFormat{LaTeX2e}[1995/06/01]
+%<doc>\ProvidesPackage{fontdoc}
+%<pkg>\ProvidesPackage{fontinst}
+%<pkg|doc>[2007/01/23 v\fontinstversion\space
+%<doc> fontinst documentation package]
+%<pkg> fontinst installation package]
+% \end{macrocode}
+%
+% While we're at version numbers anyway, we might as well define the
+% command for testing them. Note however that the module name is not
+% \Module{pkg} as above, but \Module{pkg2}. Code in the latter module
+% ends up at the very end of \texttt{fontinst.sty}!
+%
+% \begin{macro}{\needsfontinstversion}
+% The macro:
+% \begin{quote}
+% |\needsfontinstversion|\marg{number}
+% \end{quote}
+% checks the version number.
+%
+% \begin{macrocode}
+%<*pkg2>
+\def\needsfontinstversion#1{{
+ \a_dimen=#1pt
+ \b_dimen=\fontinstversion~pt\x_relax
+ \ifnum\a_dimen>\b_dimen
+ \immediate\write16{}
+ \immediate\write16{Warning:~This~file~needs~fontinst~version~#1.}
+ \immediate\write16{Warning:~You~are~using~version~
+ \fontinstversion.}
+ \immediate\write16{Warning:~This~may~cause~errors.}
+ \immediate\write16{}
+ \fi
+}}
+%</pkg2>
+% \end{macrocode}
+%
+% In \package{fontdoc}, |\needsfontinstversion| is printed out as a
+% comment.
+% \changes{1.918}{2001/06/19}{Different formatting in encoding
+% specification files. (LH)}
+% \begin{macrocode}
+%<*doc>
+\newcommand*\needsfontinstversion[1]{%
+ \ifFD@spec@
+ \comment{Automatic processing of this document as a data file
+ requires \textsf{fontinst} v\,#1 or higher.}%
+ \else
+ \Bheading{Needs fontinst v\thinspace#1}%
+ \fi
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Special catcodes and configuration file}
+%
+% \package{fontinst} uses some unusual, but convenient, settings of
+% |\catcode|. |@| and |_| are made letters, |~| is made a space, and
+% space and newline are ignored. Before setting those however, we save
+% the current values of the catcodes, so that they can be restored at
+% the end of \texttt{fontinst.sty}.
+%
+% \begin{macro}{\normalcc}
+% \begin{macro}{\fontinstcc}
+% \multchanges{\cs{fontinstcc}\cs{normalcc}}{1.915}{2000/08/09}^^A
+% {Introduced commands for changing between \package{fontinst}
+% internal catcodes and normal catcodes, as suggested by
+% Karsten Tinnefeld. (LH)}
+% The |\fontinstcc| command changes the catcodes of certain characters
+% to what is used in the \package{fontinst} source and the |\normalcc|
+% command changes them back; their use is analogous to that of the
+% |\make|\-|at|\-|letter| and |\make|\-|at|\-|other| commands in
+% \LaTeX.
+%
+% If, for some reason, you use other ``normal'' catcodes than
+% \package{fontinst} does by default, you may have to redefine
+% |\fontinstcc| and |\normalcc|. The easiest way to do this is
+% probably to use the |\add_to| macro.
+%
+% \multchanges{\cs{spacecatcode}\cs{nlcatcode}\cs{atcatcode}^^A
+% \cs{underscorecatcode}\cs{tildecatcode}}{1.915}{2000/08/09}^^A
+% {Removed since the contents can just as well be stored in
+% \cs{normalcc}. (LH)}
+% \begin{macrocode}
+%<*pkg>
+\def\a_macro#1{\catcode\number`#1=\the\catcode`#1 }
+\edef\normalcc{%
+ \a_macro{\ }\a_macro{\^^M}\a_macro{\@}\a_macro{\_}\a_macro{\~}
+}
+% \end{macrocode}
+% The above definition makes the |\normalcc| macro end with a space.
+% This is deliberate; the space is used to terminate the last number
+% in the macro.
+%
+% \begin{macrocode}
+\def\fontinstcc{%
+ \catcode`\ =9%
+ \catcode`\^^M=9%
+ \catcode`\@=11%
+ \catcode`\_=11%
+ \catcode`\~=10
+}
+\fontinstcc
+%</pkg>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% We input the \texttt{fontinst.rc} file, if it exists.\relax
+% \changes{1.6}{1997/02/07}{\texttt{fontinst.rc} search order changed
+% (Thierry Bouche).}\relax
+% \SortIndex{fontinst.rc file}{\texttt{fontinst.rc} file}
+%
+% UV, 06/1998: What is this \texttt{fontinst.rc} file good for?
+% It turns out that you can use it to do |\def\raw_encoding{8y}|
+% if you prefer to install your fonts the other way.
+%
+% \begin{macrocode}
+%<*pkg2>
+%<*!misc>
+\if_file_exists{fontinst.rc}\then
+ \primitiveinput fontinst.rc
+\else
+ \immediate\write16{No~file~fontinst.rc.}
+\fi
+%</!misc>
+% \end{macrocode}
+% Use a different configuration file for \texttt{finstmsc.sty}.^^A
+% \changes{1.905}{1999/06/21}{Different config file for
+% \texttt{finstmsc.sty}. (LH)}
+% \begin{macrocode}
+%<*misc>
+\if_file_exists{finstmsc.rc}\then
+ \primitiveinput finstmsc.rc
+\else
+ \immediate\write16{No~file~finstmsc.rc.}
+\fi
+%</misc>
+% \end{macrocode}
+%
+% At the end of \texttt{fontinst.sty}, we restore the catcodes we
+% changed.
+% \changes{1.910}{1999/11/01}{Catcodes restored \emph{after} reading
+% \texttt{.rc} file. (LH\&UV)}
+%
+% \begin{macrocode}
+\normalcc
+%</pkg2>
+% \end{macrocode}
+%
+%
+% \subsection
+% {Plain \TeX{} macros from \texttt{fontinst.ini}}
+% ^^A \subsection{PlainTeX macros from fontinst.ini}
+%
+% If we're running in ini\TeX{} we input some definitions taken
+% from \texttt{plain}.
+%
+% \begin{macrocode}
+%<*pkg>
+\ifx\@ne\undefined_command
+ \input fontinst.ini\relax
+\fi
+%</pkg>
+% \end{macrocode}
+%
+% \begin{macrocode}
+%<*ini>
+\chardef\active=13
+
+\chardef\@ne=1
+\chardef\tw@=2
+\chardef\thr@@=3
+\chardef\sixt@@n=16
+\chardef\@cclv=255
+\mathchardef\@cclvi=256
+\mathchardef\@m=1000
+\mathchardef\@M=10000
+\mathchardef\@MM=20000
+
+\count10=22 % allocates \count registers 23, 24, ...
+\count11=9 % allocates \dimen registers 10, 11, ...
+\count15=9 % allocates \toks registers 10, 11, ...
+\count16=-1 % allocates input streams 0, 1, ...
+\count17=-1 % allocates output streams 0, 1, ...
+\count20=255 % allocates insertions 254, 253, ...
+\countdef\insc@unt=20 % the insertion counter
+\countdef\allocationnumber=21 % the most recent allocation
+\countdef\m@ne=22 \m@ne=-1 % a handy constant
+\def\wlog{\immediate\write\m@ne} % write on log file (only)
+
+\countdef\count@=255
+\dimendef\dimen@=0
+
+\outer\def\newcount{\alloc@0\count\countdef\insc@unt}
+\outer\def\newdimen{\alloc@1\dimen\dimendef\insc@unt}
+\outer\def\newtoks{\alloc@5\toks\toksdef\@cclvi}
+\outer\def\newread{\alloc@6\read\chardef\sixt@@n}
+\outer\def\newwrite{\alloc@7\write\chardef\sixt@@n}
+
+\def\alloc@#1#2#3#4#5{\global\advance\count1#1by\@ne
+ \ch@ck#1#4#2% make sure there's still room
+ \allocationnumber=\count1#1%
+ \global#3#5=\allocationnumber
+ \wlog{\string#5=\string#2\the\allocationnumber}}
+\outer\def\newinsert#1{\global\advance\insc@unt by\m@ne
+ \ch@ck0\insc@unt\count
+ \ch@ck1\insc@unt\dimen
+ \ch@ck2\insc@unt\skip
+ \ch@ck4\insc@unt\box
+ \allocationnumber=\insc@unt
+ \global\chardef#1=\allocationnumber
+ \wlog{\string#1=\string\insert\the\allocationnumber}}
+\def\ch@ck#1#2#3{\ifnum\count1#1<#2%
+ \else\errmessage{No~room~for~a~new~#3}\fi}
+
+\outer\def\newif#1{\count@\escapechar \escapechar\m@ne
+ \expandafter\expandafter\expandafter
+ \edef\@if#1{true}{\let\noexpand#1=\noexpand\iftrue}%
+ \expandafter\expandafter\expandafter
+ \edef\@if#1{false}{\let\noexpand#1=\noexpand\iffalse}%
+ \@if#1{false}\escapechar\count@} % the condition starts out false
+\def\@if#1#2{\csname\expandafter\if@\string#1#2\endcsname}
+{\uccode`1=`i \uccode`2=`f \uppercase{\gdef\if@12{}}} % `if' is required
+
+\newdimen\p@ \p@=1pt % this saves macro space and time
+\newdimen\z@ \z@=0pt % can be used both for 0pt and 0
+
+\def\space{~}
+\let\bgroup={
+\let\egroup=}
+
+\def\loop#1\repeat{\def\body{#1}\iterate}
+\def\iterate{\body \let\next\iterate \else\let\next\relax\fi \next}
+\let\repeat=\fi % this makes \loop...\if...\repeat skippable
+
+\def\supereject{\par\penalty-\@MM}
+\outer\def\bye{\par\vfill\supereject\end}
+%</ini>
+% \end{macrocode}
+% The two last commands above also need to be defined if we're
+% running under \LaTeX. In that case we need to be careful with |\bye|
+% however, as no |\if|\textellipsis\ can skip over code that explicitly
+% contains that control sequence, if it has been defined as above.
+% \begin{macrocode}
+%<*pkg>
+\ifx\bye\undefined_command
+ \def\supereject{\par\penalty-\@MM}
+ \outer\expandafter\def \csname bye\endcsname
+ {\par\vfill\supereject\@@end}
+\fi
+%</pkg>
+% \end{macrocode}
+%
+% \changes{1.910}{1999/11/01}{Make \cs{everyjob} code optional, and
+% simplify it a little. (LH\&UV)}
+% \begin{macrocode}
+%<*ini&everyjob>
+\everyjob{%
+ \if_file_exists{fontinst.rc}\then
+ \primitiveinput~fontinst.rc
+ \else
+ \immediate\write16{No~file~fontinst.rc.}
+ \fi
+}
+%</ini&everyjob>
+% \end{macrocode}
+%
+%
+% \section{Basic definitions}
+%
+% \subsection{Declaring variables and constants}
+%
+% Some temporary variables:
+%
+% \begin{macro}{\a_count}
+% \begin{macro}{\b_count}
+% \begin{macro}{\c_count}
+% \begin{macro}{\d_count}
+% \begin{macro}{\e_count}
+% \begin{macro}{\f_count}
+% \begin{macro}{\g_count}
+% \begin{macrocode}
+%<*pkg>
+\newcount\a_count
+\newcount\b_count
+\newcount\c_count
+\newcount\d_count
+\newcount\e_count
+\newcount\f_count
+\newcount\g_count
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}\end{macro}
+% \end{macro}
+% \begin{macro}{\a_dimen}
+% \begin{macro}{\b_dimen}
+% \begin{macro}{\c_dimen}
+% \begin{macro}{\d_dimen}
+% \begin{macrocode}
+\newdimen\a_dimen
+\newdimen\b_dimen
+\newdimen\c_dimen
+\newdimen\d_dimen
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+% \begin{macro}{\a_toks}
+% \begin{macro}{\b_toks}
+% \begin{macro}{\c_toks}
+% \begin{macrocode}
+\newtoks\a_toks
+\newtoks\b_toks
+\newtoks\c_toks
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% \begin{switch}{_a_}
+% \changes{1.901}{1999/03/07}{Temporary switch added. (LH)}
+% \begin{macrocode}
+\newif\if_a_
+% \end{macrocode}
+% \end{switch}
+%
+% \describecsfamily{\meta{letter}_macro}
+% Besides these temporary variables that have to be declared, the family
+% of control sequences with names of the form |\|\meta{letter}|_macro|,
+% such as |\a_macro|, |\b_macro|, etc., should be used as ``macro valued''
+% temporary variables.
+% \changes{1.903}{1999/05/13}{Introduced the
+% \cs{\meta{letter}_macro} temporary variables,
+% replaced \cs{temp_command}. (LH)}
+%
+% \begin{macro}{\out_file}
+% Some global variables:
+% \begin{macrocode}
+\newwrite\out_file
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\one_thousand}
+% \begin{macro}{\five_hundred}
+% \begin{macro}{\one_hundred}
+% \begin{macro}{\max_mathchardef}
+% \begin{macro}{\two_thousand}
+% \changes{1.913}{2000/03/11}{Constant added. (LH)}
+% \begin{macro}{\half_point}
+% \changes{1.913}{2000/03/04}{Constant added. (LH)}
+% Some constants:
+% \begin{macrocode}
+\mathchardef\one_thousand=1000
+\mathchardef\five_hundred=500
+\mathchardef\one_hundred=100
+\mathchardef\max_mathchardef="7FFF
+\mathchardef\two_thousand=2000
+\newdimen\half_point \half_point=0.5pt
+%</pkg>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}\end{macro}
+%
+%
+% \subsection{Trigonometry macros}
+%
+% Before v\,1.930, the file \texttt{trig.sty} used to be input at this
+% point. That is now inlined into the \package{fontinst} source proper
+% instead.
+%
+% \multchanges{\cs{@tempdima}\cs{@tempdimb}}{1.930}{2005/02/06}
+% {These aliases for \cs{a_dimen} and \cs{b_dimen} were removed,
+% since we may now hack them out of \cs{CalculateTan}. (LH)}
+%
+%
+% \subsection
+% {\package{fontdoc}-specific declarations}
+% ^^A \subsection{fontdoc-specific declarations}
+%
+% As of v\,1.917, \package{fontdoc} has options, so we better start
+% with declaration and processing of these.
+% \changes{1.917}{2001/03/31}{Option processing added. (LH)}
+%
+% \begin{option}{specification}
+% \begin{switch}{FD@spec@}
+% The \texttt{specification} option tells \package{fontdoc} that the
+% document is an encoding specification rather than a production
+% file---this changes some minor details in the typesetting. The
+% state of this option is recorded in the |FD@spec@| switch.
+% \begin{macrocode}
+%<*doc>
+\newif\ifFD@spec@
+\FD@spec@false
+\DeclareOption{specification}{\FD@spec@true}
+% \end{macrocode}
+% \end{switch}\end{option}
+%
+% \begin{option}{hypertex}
+% \changes{1.918}{2001/06/17}{Option added. (LH)}
+% \begin{option}{pdftex}
+% \changes{1.920}{2001/09/24}{Option added. (LH)}
+% \begin{macro}{\FD@codepoint}
+% The \texttt{hypertex} and \texttt{pdftex} options tell
+% \package{fontdoc} to include Hyper\TeX\ |\special|s and pdf\TeX\
+% annotations, in every code point number set using |\Unicode| or
+% |\textunicode|, for links to glyph images on the Unicode
+% consortium web site. The URLs to use are as follows:
+% \begin{quote}
+% \small
+% To access the reference glyph for any Unicode character,
+% you can use the new URL syntax like this:
+% \begin{quote}
+% \texttt{http://www.unicode.org/cgi-bin/refglyph?}^^A
+% \meta{XX}\texttt{-}\meta{nnnn}
+% \end{quote}
+% where \meta{XX} is the point size and \meta{nnnn} is the
+% hexadecimal codepoint. Please note however that only \texttt{24}
+% is supported as a size parameter at this time. (We are
+% reserving the possibility of providing other sizes in the
+% future.) Here is an example of usage for \texttt{U+4E78}:
+% \begin{quote}
+% \texttt{http://www.unicode.org/cgi-bin/refglyph?24-4E78}
+% \end{quote}
+% (This supports up to 6 hex digits, so it can also be used
+% with the supplementary characters.)
+% \end{quote}
+%
+% \iffalse
+% Documentation for a similar older service:
+% \begin{quotation}
+% \small
+% You may embed references to the glyph images on the Unicode site
+% in your own web pages. For example, to display a Euro sign
+% (\texttt{U+20AC}) you can use the following HTML:
+% \begin{quote}
+% |<IMG SRC="http://charts.unicode.org/Glyphs/20/U20AC.gif">|
+% \end{quote}
+% The subdirectory to use within the \texttt{Glyphs/} directory
+% is the first two hexadecimal digits of the Unicode code point.
+% The set of glyphs available covers all of Unicode 3.0 with the
+% exception of Han ideographs and Hangul syllables.
+%
+% However, you should only make occasional use of these glyphs.
+% If there is too much web traffic the Unicode
+% Consortium may be forced to discontinue this service.
+% \end{quotation}
+% \fi
+% Coding this for Hyper\TeX\ is pretty straightforward.
+% \begin{macrocode}
+\DeclareOption{hypertex}{
+ \providecommand*\FD@codepoint[1]{%
+ \uppercase{\edef\@tempa{#1}}%
+ \special{html:<a href="%
+ http://www.unicode.org/cgi-bin/refglyph?24-\@tempa
+ ">%
+ }%
+ \texttt{U+\@tempa}%
+ \special{html:</a>}%
+ }%
+}
+% \end{macrocode}
+% The pdf\TeX\ implementation is easy too, but there is one
+% complication: The key primitive is called |\pdfannotlink| in
+% v\,0.13, but |\pdfstartlink| in v\,0.14. My thanks goes to H\`an
+% Th\'{\^e} Th\`anh, who helped me sort that out.
+% \begin{macrocode}
+\DeclareOption{pdftex}{
+ \providecommand*\FD@codepoint[1]{%
+ \mbox{%
+ \uppercase{\edef\@tempa{#1}}%
+ \ifx \pdfstartlink\@undefined
+ \pdfannotlink
+ \else
+ \pdfstartlink
+ \fi attr {/Border [0 0 0]} user {%
+ /Subtype /Link /A <<%
+ /S /URI /URI (%
+ http://www.unicode.org/cgi-bin/refglyph?24-\@tempa
+ )%
+ >>}%
+ \textcolor{blue}{\texttt{U+\@tempa}}%
+ \pdfendlink
+ }%
+ }%
+ \AtEndOfPackage{\RequirePackage[pdftex]{color}}%
+}
+% \end{macrocode}
+% It would be quite possible to make these links according to some
+% other standard (e.g.~\LaTeX\-to\-HTML) instead by including a suitable
+% definition of |\FD@codepoint| in your \texttt{fontdoc.cfg} file.
+% I could include code for those standards as well if someone sends
+% it to me.
+%
+% I decided against using commands in the \package{hyperref} or
+% \package{hyper} packages for this as these packages do so much more
+% that I don't want. If some day a package providing a basic interface
+% for making hyperlinks is included in required \LaTeX\ then this
+% decision should certainly be reconsidered.
+% \end{macro}\end{option}\end{option}
+%
+% Input a local configuration file, if it exists.
+% \begin{macrocode}
+\InputIfFileExists{fontdoc.cfg}{%
+ \typeout{*************************************^^J%
+ * Local config file fontdoc.cfg used^^J%
+ *************************************}%
+}{}
+% \end{macrocode}
+%
+% Finally process the options.
+% \begin{macrocode}
+\ProcessOptions\relax
+% \end{macrocode}
+%
+%
+% The \package{amstext} package is required, since the |\text| command
+% is used in formatting some integer expressions.
+% \changes{1.916}{2001/01/02}{Requiring the \package{amstext} package
+% in \package{fontdoc}. (LH)}
+% \begin{macrocode}
+\RequirePackage{amstext}
+% \end{macrocode}
+%
+% \begin{macro}{\a@count}
+% \begin{macro}{\b@count}
+% \changes{1.916}{2001/01/02}{Variable added. (LH)}
+% \begin{macro}{\a@dimen}
+% Three private variables:
+% \begin{macrocode}
+\newcount\a@count
+\newcount\b@count
+\newdimen\a@dimen
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% Some useful macros and constrol structures:
+%
+% \begin{macrocode}
+\def\x@cs#1#2{\expandafter#1\csname#2\endcsname}
+\def\FD@swap@two#1#2{#2#1}
+% \end{macrocode}
+%
+% \begin{macro}{\Aheading}
+% \changes{1.909}{1999/10/18}{Use \cs{addvspace} to make space
+% above. (LH)}
+% \changes{1.909}{1999/10/20}{Insert a \cs{penalty} for pagebreaking
+% after an \cs{Aheading}. (LH)}
+% \changes{1.920}{2001/10/19}{Encouraged page breaks before an
+% \cs{Aheading}. (LH)}
+% \begin{macro}{\Bheading}
+% |\Aheading| and |\Bheading| are used to typeset various headings.
+% \begin{macrocode}
+\newcommand\Aheading[1]{%
+ \par\pagebreak[1]\addvspace\medskipamount
+ \noindent\textbf{#1}\vadjust{\penalty200}\par
+}
+\newcommand\Bheading[1]{\par\noindent\textbf{#1}}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% Some formating commands and a macro that comes in handy. It used to
+% say |\raggedright| at this point as well, but that functionality has
+% been moved into |\encoding| and |\metrics|.
+%
+% \definechange{raggedright}{1.920}{2001/09/16}{The body (between
+% \cs{metrics} and \cs{endmetrics}, and \cs{encoding} and
+% \cs{endencoding} respectively) of a \package{fontdoc} document is
+% now typeset in a \texttt{flushleft} environment. It used to be that
+% the entire document was typeset this way. (LH)}
+% \usechange{raggedright}
+% \changes{1.923}{2002/10/26}{Making sure \cs{lineskiplimit} is
+% positive. (LH)}
+%
+% \begin{macrocode}
+\raggedbottom
+\ifdim 1sp>\lineskiplimit \lineskiplimit=0.5pt \fi
+\newcommand\plain{\texttt{plain}}
+% \end{macrocode}
+%
+% \begin{macro}{\plainint}
+% \begin{macro}{\plaindiv}
+% \begin{macro}{\plainneg}
+% \changes{1.928}{2004/11/24}{Added \cs{plainneg}. That the
+% \protect\LaTeX\ \cs{neg} is taken over by \package{fontdoc} but
+% is needed in \texttt{oms.etx} had gone unnoticed for over ten
+% years!! (LH) Problem reported by Peter Dyballa.}
+% \begin{macro}{\plainmax}
+% \begin{macro}{\plainmin}
+% \package{fontdoc} saves away \LaTeX's |\int|, |\div|, |\neg|, |\max|,
+% and |\min| as |\plainint|, |\plaindiv|, |\plainneg|, |\plainmax|,
+% and |\plainmin| respectively, since these control sequences are going
+% to be used for other purposes.
+% \begin{macrocode}
+\let\plainint=\int
+\let\plaindiv=\div
+\let\plainneg=\neg
+\let\plainmax=\max
+\let\plainmin=\min
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\TypesetList}
+% \changes{1.914}{2000/05/13}{Macro added. (LH)}
+% \begin{macro}{\list@item@counter}
+% The |\TypesetList| command typesets the \meta{arg}s in a sequence of
+% |\do|\marg{arg} macros with separators depending on position in and
+% length of the sequence. It is loosely based on a description of a
+% similar command in the \package{amsref} package, but it has fewer
+% features, and I don't know if there is any similarity between the
+% implementations.
+%
+% The syntax is
+% \begin{isyntax}
+% |\TypesetList|\marg{left}\marg{onlysep}\marg{nonlastsep}\penalty0
+% \marg{lastsep}\penalty0\marg{right}\penalty0
+% \marg{empty}\penalty0\marg{wrap}\penalty0\marg{list}
+% \end{isyntax}
+% \meta{list} is the actual list of |\do|\marg{arg}s. If that is
+% empty then \meta{empty} is typeset. Otherwise the typeset text
+% begins with \meta{left}, ends with \meta{right}, and contains the
+% formatted forms of every \meta{arg} in the list of |\do|\marg{arg}s.
+% The formatting here consists of passing the \meta{arg} as the
+% argument to \meta{wrap}, which is typically a one-argument macro.
+% Between two ``formatted \meta{arg}s'' will \meta{onlysep},
+% \meta{nonlastsep}, or \meta{lastsep} be put, depending on the number
+% of \meta{arg}s in the list and the position in the list. If the list
+% has length two then \meta{onlysep} will be used for the only separator
+% needed. If the list has length greater than two then \meta{nonlastsep}
+% will be used for all separators but the last, and \meta{lastsep} will
+% be used for the last.
+%
+% All of the arguments of |\TypesetList| must survive being passed
+% through a |\def|.
+% \begin{macrocode}
+\newcount\list@item@counter
+\newcommand\TypesetList[8]{%
+ \begingroup
+ \list@item@counter=\z@
+ \def\do##1{\advance\list@item@counter\@ne}%
+ #8%
+ \ifcase \list@item@counter \or
+ \def\do##1{#1#7{##1}}%
+ \or
+ \def\do##1{%
+ \advance\list@item@counter\@ne
+ \ifnum \list@item@counter=\@ne #1\else #2\fi
+ #7{##1}%
+ }%
+ \else
+ \advance\list@item@counter\m@ne
+ \expandafter\def \expandafter\do \expandafter##\expandafter1%
+ \expandafter{\expandafter\ifnum \the\list@item@counter
+ =\list@item@counter
+ #4%
+ \else\ifnum \z@=\list@item@counter
+ #1%
+ \else
+ #3%
+ \fi\fi
+ \advance\list@item@counter\@ne
+ #7{##1}%
+ }%
+ \fi
+ \ifnum \z@=\list@item@counter
+ #6%
+ \else
+ \list@item@counter=\z@
+ #8%
+ #5%
+ \fi
+ \endgroup
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+%
+% \section
+% {\TeX{} hackery}
+% ^^A \section{TeX hackery}
+% \changes{1.902}{1999/05/01}{Moved Section \thesection\space to
+% \texttt{fibasics.dtx}. (LH)}
+%
+% \subsection{Utiltiy macros}
+%
+% \begin{macro}{\x_cs}
+% \begin{macro}{\x_relax}
+% \begin{macro}{\g_let}
+% \begin{macrocode}
+%<*pkg>
+\def\x_cs#1#2{\expandafter#1\csname#2\endcsname}
+\let\x_relax=\relax
+\def\g_let{\global\let}
+%</pkg>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+% \changes{1.900}{1999/02/07}{Replaced \cs{relax} by \cs{x_relax}. (LH)}
+%
+% \begin{macro}{\x@relax}
+% \begin{macrocode}
+%<doc>\let\x@relax=\relax
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\empty_command}
+% \begin{macro}{\gobble_one}
+% \begin{macro}{\gobble_two}
+% \begin{macro}{\gobble_three}
+% \begin{macro}{\identity_one}
+% \begin{macro}{\first_of_two}
+% \begin{macro}{\second_of_two}
+% \begin{macro}{\swap_two}
+% \changes{1.912}{2000/02/16}{Macro added. (LH)}
+% \begin{macro}{\first_of_three}
+% \changes{1.914}{2000/05/30}{Macro added. (LH)}
+% \begin{macrocode}
+%<*pkg>
+\def\empty_command{}
+\def\gobble_one#1{}
+\def\gobble_two#1#2{}
+\def\gobble_three#1#2#3{}
+\def\identity_one#1{#1}
+\def\first_of_two#1#2{#1}
+\def\second_of_two#1#2{#2}
+\def\swap_two#1#2{#2#1}
+\def\first_of_three#1#2#3{#1}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}\end{macro}
+% \end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\hash_char}
+% \begin{macro}{\percent_char}
+% \begin{macro}{\left_brace_char}
+% \begin{macro}{\right_brace_char}
+% \begin{macrocode}
+\bgroup
+ \catcode`\[=1
+ \catcode`\]=2
+ \catcode`\#=12
+ \catcode`\%=12
+ \catcode`\{=12
+ \catcode`\}=12
+ \gdef\hash_char[#]
+ \gdef\percent_char[%]
+ \gdef\left_brace_char[{]
+ \gdef\right_brace_char[}]
+\egroup
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\first_char}
+% Return the first character of a string.
+%
+% \begin{macrocode}
+\def\first_char#1#2={#1}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\add_to}
+% Append one or more tokens to the replacement text of a
+% parameterless macro.
+% \begin{macrocode}
+\def\add_to#1#2{
+ \ifx#1\x_relax
+ \def#1{#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{#1#2}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\prep_to}
+% Prepend one or more tokens to the replacement text of a
+% parameterless macro. Note that if more than one token is added then
+% the second parameter must contain an |\expandafter| between every
+% pair of tokens you actually mean to contribute. Thus if you want
+% to prepend |abc| to |\next|, you must write
+% \begin{quote}
+% |\prep_to\next{a\expandafter b\expandafter c}|
+% \end{quote}
+% Also note that the second argument must not be empty.
+% \begin{macrocode}
+\def\prep_to#1#2{
+ \ifx#1\x_relax
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2}
+ \else
+ \expandafter\def\expandafter#1\expandafter{\expandafter#2#1}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\never_do}
+% The command |\do|, protected from expansion.
+%
+% \begin{macrocode}
+\def\never_do{\noexpand\do}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Testing for \TeX\ extensions}
+% \changes{1.914}{2000/05/13}{Added commands for testing for
+% \protect\TeX\ extensions. (LH)}
+% Some tasks can be done better (and usually with simpler code) if
+% one can assume that certain features in some \TeX\ extensions, such as
+% \eTeX, is available. Unfortunately one cannot generally make this
+% assumption, but it is sometimes possible to provide two implementations
+% of a macro and at runtime choose the one which best utilizes the
+% available features. This subsection defines macros for making these
+% tests.
+%
+% There is also a command |\needsTeXextension| which is used like
+% |\needs|\-|fontinst|\-|version|, but which tests the \TeX\ rather than
+% the version of \package{fontinst}. This ought to be of use for ETX files
+% that describe 16 bit encodings,\footnote{At the time of writing, no
+% such ETX files exist that I know of, but \package{fontinst} should
+% not have any problem using them. /LH} as the current implementation
+% of the (V)PL writer in this case requires the underlying \TeX\ to
+% support 16 bit character codes.
+%
+% The normal operation of the extension-testing macros is to set the |_a_|
+% switch to true if the requested extension is present, and to leave the
+% switch as it was if it isn't present. This is so that one can easily
+% test for a feature that has been added to several different extensions
+% of \TeX\ simply by doing the tests in sequence. That, however, is what
+% the testing macros do if the switch |_extensions_warning_| is set to
+% false. When it is set to true they instead expand to a short piece of
+% text suitable for inclusion in a warning message about the absence of
+% a needed feature.
+%
+% \begin{switch}{_extensions_warning_}
+% This switch controls whether extension-testing macros should
+% actually do the test (false) or produce a warning (true).
+% \begin{macrocode}
+%<*pkg>
+\newif\if_extensions_warning_
+\_extensions_warning_false
+% \end{macrocode}
+% \end{switch}
+%
+%
+% \begin{macro}{\eTeX}
+% The |\eTeX| command has the syntax
+% \begin{quote}
+% |\eTeX|\marg{version number}
+% \end{quote}
+% where the \meta{version number} is the complete version number
+% (version number plus revision) of the \eTeX\ one wishes to test for.
+%
+% The code below is geared towards not letting unnecessary control
+% sequences get tokenized, as they will then always occupy a position
+% in \TeX's hash table, but it seems one cannot get around testing
+% whether |\eTeXversion| is defined, so we start with that and then
+% do a |\catcode| trick to prevent \TeX\ from seeing |\eTeXrevision|.
+% \begin{macrocode}
+\ifx \eTeXversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+\def\eTeX#1{
+ \if_extensions_warning_
+ \space/\space e-TeX\space version\space #1
+~ \else
+~ \ifdim \number\eTeXversion\eTeXrevision\p@ < #1\p@ \else
+~ \_a_true
+~ \fi
+ \fi
+}
+\catcode`\~=10
+%</pkg>
+% \end{macrocode}
+% \begin{macro}{\eTeXlogo}
+% The |\eTeXlogo| command prints the \eTeX\ logo.
+% \changes{1.923}{2002/10/20}{Added kern, to match
+% \package{ltugboat} definition. (LH)}
+% \begin{macrocode}
+%<*doc>
+\def\eTeX#1{\do{\eTeXlogo\nolinebreak[3] v\,#1}}
+\def\eTeXlogo{\ensuremath{\varepsilon}-\kern-.125em\TeX}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\pdfTeX}
+% The |\pdfTeX| command has the syntax
+% \begin{quote}
+% |\pdfTeX|\marg{version number}\marg{revision}
+% \end{quote}
+% where the \meta{version number} is the version number as returned
+% by |\pdftexversion|, i.e., 100 times what it would normally be
+% printed as, and the \meta{revision} is the revision code as returned
+% by |\pdftexrevision|. To test for pdf\TeX\ 0.13c or newer, one would
+% say |\pdfTeX{13}{c}|.
+%
+% The code below uses the same |\catcode| trick as that in |\eTeX|.
+% \begin{macrocode}
+%<*pkg>
+\ifx \pdftexversion\undefined_command
+ \catcode`\~=14 % 14=comment
+\fi
+%</pkg>
+%<*pkg|doc>
+\def\pdfTeX#1#2{%
+%<pkg> \if_extensions_warning_
+%<pkg> \space/\space pdfTeX\space version\space
+%<doc> \do{pdf\TeX\nolinebreak[3] v\,%
+ \ifnum #1<100\space
+ 0.\ifnum #1<10\space 0\fi
+ \else
+%<pkg> \expandafter\swap_two \expandafter.
+%<doc> \expandafter\FD@swap@two \expandafter.%
+ \fi
+ #1#2%
+%<doc> }
+%<doc>}
+%</pkg|doc>
+%<*pkg>
+% \end{macrocode}
+% The above is not ideal, but it will do for now.
+% \begin{macrocode}
+~ \else
+~ \ifdim #1>\pdftexversion \else
+~ \ifnum \expandafter\expandafter \expandafter`
+~ \expandafter\first_char \pdftexrevision= <
+~ \expandafter` \first_char#2=
+~ \else \_a_true \fi
+~ \fi
+ \fi
+}
+\catcode`\~=10
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\needsTeXextension}
+% The |\needsTeXextension| command has the syntax
+% \begin{quote}
+% |\needsTeXextension|\marg{extension tests}\marg{who}
+% \end{quote}
+% If none of the extension tests set the |_a_| switch to true, then
+% it prints a warning detailing the extensions tests which failed.
+% \meta{who} is what should be listed as the originator of this
+% message; it is typically the name of the file which contains the
+% |\needsTeXextension| command.
+%
+% An example (assuming that there will be an |\Omega| test as well
+% some time in the future; I haven't really looked into what that
+% should look like, so maybe the arguments should be different): The
+% command
+% \begin{quote}
+% |\needsTeXextension{\eTeX{1.2}\Omega{1.0}}{foobar.etx}|
+% \end{quote}
+% tests if the current \TeX\ is \eTeX\ verision 1.2 (or newer)
+% \emph{or} Omega version 1.0 (or newer). The implied conjunction
+% between the tests is always `or'.
+% \begin{macrocode}
+\def\needsTeXextension#1#2{
+ \_a_false
+ #1
+ \if_a_ \else
+ \_extensions_warning_true
+ \edef\a_macro{#1}
+ \_extensions_warning_false
+ \fontinstwarningnoline{#2}{
+ This~file~needs:\messagebreak
+ \expandafter\second_of_two\a_macro
+ \iffalse
+ <no~sufficient~extensions~were~listed!!>\if_false
+ \fi
+ \messagebreak
+ You~are~not~using~any~of~them.~This~is~likely~to~cause~errors
+ }
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\def\needsTeXextension#1#2{%
+ \Bheading{Needs
+ \TypesetList{}{ or }{, }{, or }{}{(unspecified)}{\@firstofone}{#1}}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \subsection{Writing to output files}
+%
+% \changes{1.901}{1999/03/04}{Pooled output file allocation added. (LH)}
+% As of v\,1.901, there are two different output file
+% models in \package{fontinst}. One has been along ``forever'' and is
+% for writing output to files which are only open for a short period of
+% time---every \package{fontinst} file command that opens a file in this
+% model must also close it---and it can only be used for one file at at
+% time. The other model offers pooled allocation of output files---as
+% long as there is an unused \TeX\ output stream to open, you may open a
+% new file, and it does not matter if files are not closed in the revese
+% order of that in which they were opened.
+%
+% \begin{macro}{\open_out}
+% \changes{1.901}{1999/03/04}
+% {\cs{xdef} instead of \cs{def} on \cs{out_filename}. (LH)}
+% \begin{macro}{\close_out}
+% \begin{macro}{\out_line}
+% \begin{macro}{\out_lline}
+% \changes{1.908}{1999/08/25}{\cs{edef}, to save macro expansions
+% later. (LH)}
+% \begin{macro}{\out_llline}
+% \changes{1.908}{1999/08/25}{\cs{edef} and don't use \cs{out_lline},
+% to save macro expansions later. (LH)}
+% These macros implement the classical output file commands.
+% \begin{macrocode}
+%<*pkg>
+\def\open_out#1{
+ \immediate\openout\out_file=#1 \xdef\out_filename{#1}}
+\def\close_out#1{
+ \immediate\write16{#1~written~on~\out_filename.}
+ \immediate\closeout\out_file}
+\def\out_line#1{\immediate\write\out_file{#1}}
+\edef\out_lline#1{\noexpand\out_line{\space\space\space#1}}
+\edef\out_llline#1{
+ \noexpand\out_line{\space\space\space\space\space\space#1}
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+%
+% In the new model, the basic writing command
+% \DescribeMacro{\pout_line}|\pout_line| takes two arguments: a file
+% identifier control sequence and the token sequence to write. Thus its
+% call looks like
+% \begin{quote}
+% |\pout_line|\meta{identifier}\marg{text}
+% \end{quote}
+% The \meta{identifier} is usually a chardef token whose number tells
+% which input stream is used, but if \TeX\ runs out of output streams
+% then it might be defined as a parameterless macro which expands to
+% |\m@ne|. This has the effect of making all output to that ``file'' go
+% to the log file, from which the data might be salvaged.
+%
+% The new model operates using the control sequence family
+% \describecsfamily{out_filename-\meta{stream}}^^A
+% |\out_filename-|\meta{stream}
+% both for storing the name of the output file and for handling
+% allocation of output streams.
+%
+% \begin{macro}{\TeX_terminal}
+% \begin{macro}{\closed_stream}
+% \begin{macro}{\out_filename-99}
+% \begin{macro}{\out_filename--1}
+% Output streams 16 and above always write to \TeX's terminal, and any
+% output file that gets closed gets its identifier set to 99 so that
+% any attempts to write to a closed file can be easily spotted. (99
+% is the character code for |c|.) Output stream --1 is the log file, and
+% if another output stream cannot be allocated then attempts to write to
+% the output file will be redirected to the log file.
+% \begin{macrocode}
+\def\TeX_terminal{\string\TeX\space terminal}
+\chardef\closed_stream=99
+\x_cs\let{out_filename-99}=\TeX_terminal
+\x_cs\def{out_filename--1}{\jobname.log}
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro} \end{macro}
+%
+% \begin{macro}{\allocate_stream}
+% \begin{macro}{\ch@ck}
+% \begin{macrocode}
+\def\allocate_stream{
+ \a_count=\m@ne
+ \b_count=\m@ne
+ \loop \ifnum \count17>\a_count
+% \end{macrocode}
+% While |\a_count|${}<$ the number of the last allocated output
+% stream \textellipsis
+% \begin{macrocode}
+ \advance \a_count \@ne
+ \x_cs\ifx{out_filename-\the\a_count}\TeX_terminal
+% \end{macrocode}
+% If |\out_filename-|\meta{stream}, where \meta{stream} is the value
+% of |\a_count|, is equal to |\TeX_terminal|, then output stream
+% |\a_count| is allocated to the pool but is not used for any
+% currently open file. Thus we've found a stream that can be used.
+% \begin{macrocode}
+ \b_count=\a_count
+ \a_count=\count17
+ \fi
+ \repeat
+ \ifnum \b_count=\m@ne
+% \end{macrocode}
+% In this case all streams allocated to the pool are currently in use,
+% so try to allocate a new one.
+% \begin{macrocode}
+ \global\advance\count17by\@ne
+ \ifnum \count17<\sixt@@n
+% \end{macrocode}
+% Then case: There was another output stream.
+% \begin{macrocode}
+ \b_count=\count17
+ \global\x_cs\let{out_filename-\the\b_count}\TeX_terminal
+ \wlog{\string\write\the\b_count\space allocated~to~the~pool.}
+ \else
+% \end{macrocode}
+% Else case: See to that the output stream allocation register holds
+% at 16.
+% \begin{macrocode}
+ \global\count17=\sixt@@n
+ \fi
+ \fi
+}
+% \end{macrocode}
+% By now, if a new stream could be allocated then the number of that
+% stream is in |\b_count|, and if it couldn't then |\b_count| is --1.
+%
+% All output streams up to and including that whose number is in
+% |\count17| is checked to see if it is available. Many unsuccessful
+% |\newwrite|s could therefore mean we have to do quite a lot of
+% checking. What's more, output stream 99 would incorrectly be
+% interpreted as being in the pool but not used. To guard against these
+% (improbable) errors, |\ch@ck| is redefined to stop allocation
+% |\count| registers at their limit value.
+% \begin{macrocode}
+\def\ch@ck#1#2#3{
+ \ifnum \count1#1<#2 \else
+ \errmessage{No~room~for~a~new~#3}
+ \global\count1#1=#2
+ \fi
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\open_pout}
+% \begin{macro}{\close_pout}
+% The syntax for |\open_pout| is
+% \begin{quote}
+% |\open_pout|\meta{identifier}\marg{name}
+% \end{quote}
+% \meta{name} is the name of the output file one wishes to open.
+% \meta{identifier} is a control sequence which will be redefined
+% (globally) to act as an identifier of the file.
+% \begin{macrocode}
+\def\open_pout#1#2{
+ \allocate_stream
+ \ifnum \b_count=\m@ne
+ \immediate\write\sixt@@n{fontinst~is~out~of~output~streams.^^J
+ Output~file~#2~cannot~be~opened.^^J
+ Writes~will~be~redirected~to~the~log~file.
+ }
+ \gdef#1{\m@ne}
+ \else
+ \immediate\openout\b_count=#2\x_relax
+ \x_cs\xdef{out_filename-\the\b_count}{#2}
+ \global\chardef#1=\b_count
+ \fi
+}
+% \end{macrocode}
+%
+% The syntax for |\close_pout| is
+% \begin{quote}
+% |\close_pout|\meta{identifier}\marg{what}
+% \end{quote}
+% \meta{identifier} is the output stream identifier which should have
+% been defined in an earlier call of |\open_pout|. \meta{what} is a
+% string which describes what has been written to the output file,
+% e.g.\ |Metrics| or |Raw~font|. It will be used to write a message on
+% the terminal.
+% \begin{macrocode}
+\def\close_pout#1#2{
+ \ifnum #1=\closed_stream
+ \errmessage{Output~file~\string#1~(#2)~not~closed,^^J
+ since~it~was~not~open}
+ \else
+ \immediate\write\sixt@@n{#2~written~on~
+ \csname out_filename-\the#1\endcsname.}
+ \ifnum #1=\m@ne \else
+ \immediate\closeout#1
+ \global\x_cs\let{out_filename-\the#1}=\TeX_terminal
+ \fi
+ \global\chardef#1=\closed_stream
+ \fi
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\pout_line}
+% The syntax for |\pout_line| is
+% \begin{quote}
+% |\pout_line|\meta{identifier}\marg{text}
+% \end{quote}
+% \meta{identifier} is the output stream identifier which should have
+% been defined in an earlier call to |\open_pout|. \meta{text} is
+% what will be written to the file.
+% \begin{macrocode}
+\def\pout_line#1#2{\immediate\write#1{#2}}
+% \end{macrocode}
+%
+% \begin{macro}{\pout_lline}
+% \changes{1.904}{1999/06/15}{Command added. (LH)}
+% \changes{1.908}{1999/08/25}{\cs{edef}, to save macro expansions
+% later. (LH)}
+% \begin{macro}{\pout_llline}
+% \changes{1.904}{1999/06/15}{Command added. (LH)}
+% \changes{1.908}{1999/08/25}{\cs{edef} and don't use \cs{pout_lline},
+% to save macro expansions later. (LH)}
+% There relate to |\pout_line| as |\out_lline| and |\out_llline| to
+% |\out_line|.
+% \begin{macrocode}
+\edef\pout_lline#1#2{\noexpand\pout_line#1{\space\space\space#2}}
+\edef\pout_llline#1#2{
+ \noexpand\pout_line#1{\space\space\space\space\space\space#2}
+}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+%
+% \begin{macro}{\tempfileprefix}
+% \begin{macro}{\temp_prefix}
+% Selecting the directory for temporary files.
+%
+% \begin{macrocode}
+\def\tempfileprefix#1{\def\temp_prefix{#1}}
+\tempfileprefix{}
+%</pkg>
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \subsection{Conditionals}
+%
+% \subsubsection{Conditionals in \package{fontinst}}
+%
+% \begin{macro}{\then}
+% \begin{macro}{\if_true}
+% \begin{macro}{\if_false}
+% In order to write macros that expand out to nested |\if|-statements,
+% I say:
+% \begin{quote}
+% |\ifblah| \textellipsis\ |\then| \textellipsis\ |\else|
+% \textellipsis\ |\fi|
+% \end{quote}
+% In order to match the |\fi|, |\then| has to be an |\if|.
+%
+% \begin{macrocode}
+%<pkg|doc>\let\then=\iffalse
+%<*pkg>
+\def\if_false{\iffalse}
+\def\if_true{\iftrue}
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro}
+%
+% \begin{macro}{\if_defined}
+% \begin{macro}{\if_undefined}
+% \multchanges{\cs{if_defined}\cs{if_undefined}}{1.912}
+% {2000/02/10}{Macro added. (LH)}
+% These two macros are used as
+% \begin{quote}
+% |\if_defined|\marg{control sequence name}|\then|\\
+% |\if_undefined|\marg{control sequence name}|\then|
+% \end{quote}
+% The latter is functionally equivalent to
+% \begin{quote}
+% |\x_cs\ifx|\marg{control sequence name}|\x_relax|
+% \end{quote}
+% but it is shorter (1--3 tokens, depending on whether the
+% unnecessary braces around \meta{control sequence name} are included
+% or not). The former tests the same thing, but has true and false
+% cases reversed.
+%
+% Apart from that it is shorter, another important reason for
+% introducing these macros is that the \eTeX\ primitives
+% |\ifcsname| and |\unless| provide a much better implementation than
+% what is possible in normal \TeX. Therefore it is desirable to use
+% these commands as much as possible, and by introducing these macros
+% one can achieve this without having double definitions for more
+% than these two macros.
+%
+% To avoid trouble with mismatched ifs and tokenizing control
+% sequences special for \eTeX, |~| is temporarily made a comment
+% character. I'm not sure |\ifcsname| and |\unless| weren't available
+% in \eTeX\ versions before 2.0, but that's the oldest version I have
+% a manual for.
+% \multchanges{\cs{if_defined}\cs{if_undefined}}{1.914}{2000/05/13}
+% {Automatically selecting between \protect\TeX\ and \eTeX\
+% definitions. (LH)}
+% \multchanges{\cs{if_defined}\cs{if_undefined}}{1.927}{2003/12/11}
+% {Modified \eTeX\ definitions to make them work with the
+% crufty old ``unset is \cs{let} to \cs{relax}'' tradition
+% of \package{fontinst} implementation. (LH) This was found
+% to be a show-stopper for using v\,1.926 with \eTeX;
+% Heiko Oberdiek found the cause of it.}
+% \changes{1.927}{2004/08/07}{Fixed problem with \cs{unless}. (LH)}
+% \begin{macrocode}
+\_a_false\eTeX{2.0}
+\if_a_\else \catcode`\~=14\x_relax \fi
+% \end{macrocode}
+% The following use of |\if| is a trick I learnt from the
+% implementation of \package{docstrip}. |\if| will expand any amount of
+% material until it has two unexpandable tokens to compare, hence one
+% can use it to evaluate arbitrary boolean expressions in a single
+% \TeX\ conditional, by expressing the expression as something which
+% expands in \TeX's mouth to the value of the expression (either |0|
+% or |1|). In this case the expression is ``the control sequence is
+% defined and that definition is not \cs{relax}''.
+% \begin{macrocode}
+~ \def\if_defined#1\then{
+~ \if
+~ \ifcsname#1\endcsname
+~ \expandafter\ifx \csname#1\endcsname \x_relax
+~ 0
+~ \else
+~ 1
+~ \fi
+~ \else
+~ 0
+~ \fi
+~ 1
+~ }
+~ \def\if_undefined{\expandafter\unless\if_defined}
+% \end{macrocode}
+% \begin{macrocode}
+\catcode`\~=\if_a_ 14 \else 10 \fi \x_relax
+% \end{macrocode}
+% \begin{macrocode}
+~ \def\if_defined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ \expandafter\if_false
+~ \else
+~ \expandafter\if_true
+~ \fi
+~ }
+~ \def\if_undefined#1\then{
+~ \expandafter\ifx \csname#1\endcsname\x_relax
+~ }
+% \end{macrocode}
+% \begin{macrocode}
+\catcode`\~=10\x_relax
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\gobble_if}
+% It is sometimes best to skip both the then-part and
+% the else-part of a conditional. |\gobble_if| does this by using the
+% fact that expanding |\else| skips everything until the next matching
+% |\fi| without looking for other |\else|s.
+% \changes{1.900}{1998/12/11}{Macro added. (LH)}
+% \changes{1.913}{2000/03/03}{Macro redefined; it now works entirely
+% in the mouth. (LH)}
+% \begin{macrocode}
+\def\gobble_if{\iftrue\else}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\if_or}
+% \begin{macro}{\or_else}
+% |\if_or| \textellipsis\ |\or_else| \textellipsis\ |\then| gives the
+% disjunction of two booleans.
+% \begin{macrocode}
+\def\if_or#1\or_else#2\then{
+ #1\then
+ \expandafter\if_true
+ \else
+ #2\then
+ \expandafter\expandafter\expandafter\if_true
+ \else
+ \expandafter\expandafter\expandafter\if_false
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\if_equal}
+% The |\if_equal| macro is a \textellipsis|\then|-style wrapper around the
+% |\ifx| primitive. Its calling syntax is
+% \begin{quote}
+% |\if_equal|\meta{token1}\meta{token2}|\then|
+% \end{quote}
+% \changes{1.912}{2000/02/23}{Macro added. (LH)}
+% \begin{macrocode}
+\def\if_equal#1\then{\ifx#1}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\if_file_exists}
+% |\if_file_exists| checks to see if a file exits, using |\openin|.
+%
+% \begin{macrocode}
+\def\if_file_exists#1\then{
+ \immediate\openin1=#1\x_relax
+ \ifeof1\x_relax
+ \immediate\closein1
+ \expandafter\if_false
+ \else
+ \immediate\closein1
+ \expandafter\if_true
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsubsection{Conditionals in \package{fontdoc}}
+%
+% \changes{1.909}{1999/10/16}{System for documenting both branches of
+% \texttt{if} statements in ETX and MTX files added. (LH)}
+% In order to get a reasonable documentation of branches in an ETX or
+% MTX file, the code in both branches must be typeset and the positions
+% of the if, the else, and the fi must be clearly marked. There seems to
+% be no reasonable way to achieve this if the standard names for the
+% else and fi are used. Therefore the alternative names |\Else| and
+% |\Fi| for |\else| and |\fi| have been introduced, to be used as in
+% for example
+% \begin{quote}
+% |\ifisint{monowidth}\then|\\
+% \vadjust{}\quad\meta{then-part}\\
+% |\Else|\\
+% \vadjust{}\quad\meta{else-part}\\
+% |\Fi|
+% \end{quote}
+%
+% \begin{macro}{\Else}
+% \begin{macro}{\Fi}
+% By default, these are identical to their lowercase counterparts.
+% \begin{macrocode}
+%<*pkg|doc>
+\let\Else=\else
+\let\Fi=\fi
+%</pkg|doc>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% The interesting part begins if the ETX or MTX file gives the command
+% |\showbranches|, since this means (i) that it wants the branches to be
+% shown and (ii) that it complies to a simple rule about where to use
+% |\Else| and |\Fi|. The rule is as follows: If an \texttt{if} statement
+% is of \package{fontinst} form (it uses |\then|), then it must be
+% terminated by |\Fi|, and a possible else in the statement must be an
+% |\Else|. If an \texttt{if} statement is \emph{not} of \package{fontinst}
+% form (it has no |\then|), then it must be terminated by |\fi|, and a
+% possible else in the statement must be an |\else|. Only the
+% \package{fontinst} form \texttt{if} statements are affected by
+% |\showbranches|.
+%
+% \begin{macro}{\showbranches}
+% \begin{macro}{\generic@if}
+% The |\showbranches| command changes the definitions of
+% |\generic@if|, |\then|, |\Else|, and |\Fi| so that the branches of
+% \texttt{if} statements will be made visible. |\generic@if| is used
+% to implement all the \package{fontinst} form \texttt{if} statements
+% in \package{fontdoc}. It is called as
+% \begin{quote}
+% |\generic@if|\marg{description}
+% \end{quote}
+% and this will by default expand to |\iftrue|, but after executing
+% |\showbranches| it will instead typeset
+% \begin{quote}
+% If \meta{description} then
+% \end{quote}
+% and do a bit of additional housekeeping.
+%
+% \begin{macrocode}
+%<*doc>
+\def\generic@if#1{\iftrue}
+% \end{macrocode}
+% \begin{macrocode}
+\newcommand\showbranches{%
+ \let\generic@if=\branches@if
+ \let\then=\x@relax
+ \let\Else=\branches@else
+ \let\Fi=\branches@fi
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\saved@slot@number}
+% The |\saved@slot@number| is used for storing the value of
+% |\slot@number| at the \texttt{if} until the |\Else|. Unlike
+% |\slot@number|, it is always set locally.
+% \begin{macrocode}
+\newcount\saved@slot@number
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\branches@if}
+% \begin{macro}{\branches@else}
+% \begin{macro}{\branches@fi}
+% \changes{1.916}{2001/01/25}{Commented out test which concatenates
+% consecutive \cs{Fi}s, since that doesn't work together with the
+% \texttt{IfBranch} environment. (LH)}
+% \begin{macro}{\branches@type}
+% \begin{macro}{\branches@par}
+% The macros |\branches@if|, |\branches@else|, and |\branches@fi|
+% contain the definitions of |\generic@if|, |\Else|, and |\Fi|
+% respectively that are used when branches are to be shown. Their
+% basic task is to typeset the texts |If #1 then|, |Else|, and |Fi| in
+% an appropriate style and with appropriate spacing around. A
+% complicating matter is however that |\slot@number| must have the
+% same value at the beginning of the \textit{else} part as at the
+% beginning of the \textit{then} part. To achieve this, the value of
+% |\slot@number| is saved in |\saved@slot@number| at the \textit{if}
+% and copied back at the \textit{else}. To make this work even with
+% nested \textit{if}s, both the \textit{then} branch and the
+% \textit{else} branch are enclosed in groups and
+% |\saved@slot@number| is assigned locally.
+%
+% There are still some formatting issues to solve, however. In some
+% cases it works best to put the text of adjacent \textit{if},
+% \textit{else}, or \textit{fi} in the same paragraph, and it must be
+% possible to recognize those cases. This is done by looking at the
+% macro |\branches@type|, which should expand to
+% \begin{enumerate}
+% \item[\texttt{0}] if the preceeding item was an \textit{if},
+% \item[\texttt{1}] if the preceeding item was an \textit{else}
+% preceeded by an \textit{if},
+% \item[\texttt{2}] if the preceeding item was an \textit{else}
+% not preceeded by an \textit{if},
+% \item[\texttt{3}] if the preceeding item was a \textit{fi},
+% \item[\texttt{4}] if it was anything else.
+% \end{enumerate}
+% |\branches@par| is used for resetting |\branches@type| to \texttt{4}.
+% It is an auto-resetting definition of |\par|.
+%
+% \begin{macrocode}
+\def\branches@if#1{%
+ \ifnum \branches@type=\tw@
+ \begin{IfBranchDummy}%
+ \textit{ if #1 then}%
+ \else
+ \par
+ \ifFD@tight@\else \addvspace\medskipamount \fi
+ \noindent\textit{If #1 then}%
+ \fi
+ \saved@slot@number=\slot@number
+ \gdef\branches@type{0}%
+ \let\par=\branches@par
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\branches@else{%
+ \ifnum \branches@type=\z@
+ \textit{ relax else}%
+ \gdef\branches@type{1}%
+ \else
+ \par
+ \end{IfBranch}%
+ \noindent\textit{Else}%
+ \gdef\branches@type{2}%
+ \fi
+ \global\slot@number=\saved@slot@number
+ \let\par=\branches@par
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\branches@fi{%
+ \ifnum \branches@type=\thr@@
+ \expandafter\end \expandafter{\@currenvir}%
+ \expandafter\gdef \expandafter\FD@saved@fis
+ \expandafter{\FD@saved@fis \space fi}%
+ \else
+ \end{IfBranch}%
+ \gdef\FD@saved@fis{Fi}%
+ \fi
+ \gdef\branches@type{3}%
+ \let\par=\branches@par
+}
+% \end{macrocode}
+% \begin{macrocode}
+\gdef\branches@type{4}
+% \end{macrocode}
+% \begin{macrocode}
+\def\branches@par{%
+ \@restorepar
+ \ifnum \branches@type=\thr@@
+ \noindent\textit{\FD@saved@fis}\par
+ \else
+ \begin{IfBranch}%
+ \fi
+ \gdef\branches@type{4}%
+}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{environment}{IfBranch}
+% \changes{1.916}{2001/01/09}{Environment added. (LH)}
+% \changes{1.920}{2001/09/16}{Removed assignment to \cs{listparindent}.
+% I don't know why it was there in the first place. (LH)}
+% \begin{switch}{FD@tight@}
+% \changes{1.916}{2001/01/09}{Switch added. (LH)}
+% The branches of a conditional that is being shown are put in an
+% \texttt{IfBranch} environment, to emphasize the branches as logical
+% units in the file. Depending on the value of the \texttt{FD@tight@}
+% switch, there are two different ways that the branches can be
+% distinguished. In the non-tight setting (\texttt{FD@tight@} false),
+% there is one |\medskip|\-|amount| of vertical space before and after
+% the branch, but no indentation. In the tight setting (which is used
+% for \meta{glyph commands} and \meta{slot commands}), there is no
+% extra vertical space around the branch, instead it is indented by
+% $1\,\mathrm{em}$.
+% \begin{macrocode}
+\newif\ifFD@tight@
+\newenvironment{IfBranch}{%
+ \list{}{%
+ \ifFD@tight@
+ \setlength\topsep{\z@skip}%
+ \@beginparpenalty=\z@
+ \@endparpenalty=\z@
+ \setlength\leftmargin{1em}%
+ \else
+ \setlength\topsep{\medskipamount}%
+ \@beginparpenalty=-10%
+ \@endparpenalty=\@beginparpenalty
+ \setlength\leftmargin{\z@}%
+ \fi
+ \setlength\partopsep{\z@skip}%
+ \setlength\itemsep{\z@skip}%
+ \setlength\parsep{\z@ plus\p@}%
+ \setlength\rightmargin{\z@}%
+ \setlength\itemindent{\z@}%
+ }%
+ \item[]%
+}{\endlist}
+% \end{macrocode}
+% \end{switch}\end{environment}
+%
+% \begin{environment}{IfBranchDummy}
+% \changes{1.916}{2001/01/25}{Environment added. (LH)}
+% In order to get the nesting right, each |\branches@else| command has
+% to |\begin| a new environment, but if it is immediately followed by
+% a |\branches@if| then that environment should not cause an
+% indentation. In these cases the \texttt{IfBranchDummy} environment
+% is used instead of \texttt{IfBranch}.
+% \begin{macrocode}
+\newenvironment{IfBranchDummy}{}{}
+%</doc>
+% \end{macrocode}
+% \end{environment}
+%
+%
+% \subsubsection{Miscellanea}
+%
+% \begin{macro}{\primitiveinput}
+%
+% If |\@@input| is defined, I'll assume it's the \LaTeX{} version
+% of the \TeX{} |\input| primitive. I need this so that I can say
+% |\expandafter\foo\primitiveinput|, which doesn't work with the
+% \LaTeX{} version of |\input|.
+%
+% \begin{macrocode}
+%<*pkg>
+\x_cs\ifx{@@input}\x_relax
+ \let\primitiveinput=\input
+\else
+ \let\primitiveinput=\@@input
+\fi
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \DescribeMacro{\process_csep_list}
+% The macro
+% \begin{quote}
+% |\process_csep_list|\marg{pretext}\meta{comma-sep~list}^^A
+% |,\process_csep_list,|
+% \end{quote}
+% executes \meta{pretext}\marg{item} for every item in the
+% \meta{comma-sep~list}.
+%
+% \begin{macro}{\process_csep_list}
+% \begin{macrocode}
+\def\process_csep_list#1#2,{
+ \ifx\process_csep_list#2
+ \expandafter\gobble_one
+ \else
+ \expandafter\identity_one
+ \fi{
+ #1{#2}
+ \process_csep_list{#1}
+ }
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\print@csep@list}
+% \textit{Use of this macro is now deprecated; use \cs{TypesetList}
+% instead wherever possible.} The macro call
+% \begin{quote}
+% |\print@csep@list|\marg{format}\marg{list}
+% \end{quote}
+% prints the comma-separated list \meta{list} in math mode.
+% \meta{format} can be used to set the style in which the list is
+% printed, since it is executed in the beginning of the same group as
+% in which the list is printed.
+%
+% The formating is based on changing the |\mathcode| of comma to
+% |"8000| so that the comma can be used as if it was an active character
+% without actually having to be one.
+% \begin{macrocode}
+%<*doc>
+\begingroup
+ \catcode`\,=13
+ \gdef\print@csep@list#1#2{%
+ $%
+ \ifnum "8000=\mathcode`\,\else
+ \mathchardef\private@comma=\mathcode`\,%
+ \mathcode`\,="8000\x@relax
+ \fi
+ #1%
+ \let,=\active@comma
+ #2%
+ $%
+ }
+\endgroup
+\def\active@comma{\private@comma \penalty\binoppenalty}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \subsection{Real numbers}
+%
+% \TeX's \meta{number}s are merely integers, but \package{fontinst}
+% needs to store and calculate with numerical entities (most of which
+% are lengths) that are intrinsically real numbers. Most of the time,
+% \package{fontinst} does this by using a representation of real numbers
+% by integers in which a real number $x$ is represented by the integer
+% that $1000x$ gets rounded to. This representation has proved
+% sufficiently precise for most purposes.
+%
+% There are however a few cases in which real numbers must be delt with
+% in a more general fashion. Generic routines for this appear in this
+% subsection.
+%
+% \begin{macro}{\make_factor}
+% \changes{1.903}{1999/05/13}{Macro added. (LH)}
+% The |\make_factor| macro is meant to be used in the context
+% \begin{quote}
+% |\make_factor|\marg{number}
+% \end{quote}
+% where \meta{number} can be any legal \TeX\ number. It expands to
+% the same number divided by 1000, with decimals, so that what it
+% expands to matches the regular expression
+% \begin{quote}
+% |-?[0-9]+\.[0-9][0-9][0-9]|
+% \end{quote}
+%
+% More specifically, |\make_factor| has two tasks to perform: it takes
+% care of the sign, so that its subsidary macros need only work with
+% unsigned numbers, and it converts the \meta{number} (which could
+% well be a countdef or mathchardef token) to a sequence of digits.
+% \begin{macrocode}
+%<*pkg>
+\def\make_factor#1{
+ \ifnum #1<\z@
+ -\expandafter\make_factor_i\expandafter{\number-#1}
+ \else
+ \expandafter\make_factor_i\expandafter{\number#1}
+ \fi
+}
+% \end{macrocode}
+%
+% \begin{macro}{\make_factor_i}
+% |\make_factor_i| distinguishes between the two main cases of
+% numbers that in absolute value are less than 1000 and numbers that
+% in absolute value are greater than or equal to 1000. In the former
+% case, zeros need to be inserted. In the latter case, some number
+% of digits need to be stepped over before the decimal point can be
+% inserted.
+% \begin{macrocode}
+\def\make_factor_i#1{
+ \ifnum #1<\one_thousand
+ \make_factor_ii{#1}
+ \else
+ \make_factor_iii #1
+ \fi
+ #1
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\make_factor_ii}
+% |\make_factor_ii| inserts extra zeros, in the extent it is
+% needed.
+% \begin{macrocode}
+\def\make_factor_ii#1{
+ 0.
+ \ifnum #1<\one_hundred
+ 0
+ \ifnum #1<10~ 0\fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\make_factor_iii}
+% |\make_factor_iii| steps over one digit and checks if this is the
+% correct position for the decimal point. Note that |#2#3| is
+% exactly the digits in the number that has not been stepped over.
+% Also note that comparision with |#2#3| would not work, since |#2|
+% can be |0|.
+% \begin{macrocode}
+\def\make_factor_iii#1#2#3\fi#4{
+ \fi
+ #4
+ \ifnum 1#3<\one_thousand
+ .
+ \else
+ \make_factor_iii#2#3
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% It also happens that real numbers are represented by dimens, in the
+% common way that the number 1 is represented by the dimen 1\,pt. For
+% those cases the following macro is indispensable.
+%
+% \begin{macro}{\lose_measure}
+% Get rid of a trailing |pt| when converting dimension.
+% \begin{macrocode}
+{
+ \catcode`\p=12
+ \catcode`\t=12
+ \gdef\lose_measure#1pt{#1}
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Hexadecimal numbers}
+%
+% Some of the file formats \package{fontinst} can generate requires
+% that some numbers are written in hexadecimal form rather than in
+% \TeX's default decimal form. This is somewhat awkward, as it would be
+% very hard to implement without using explicit arithmetic.
+%
+% \begin{macro}{\format_hex}
+% The |\format_hex| command formats a number as hexadecimal digits.
+% The syntax is
+% \begin{quote}
+% |\format_hex|\marg{command}\marg{value}\marg{digits}
+% \end{quote}
+% where \meta{command} will be |\def|ined to be the formatted number.
+% \meta{value} is the number to format; it must not be negative.
+% \meta{digits} is the number of digits to generate. If the
+% \meta{value} is greater than or equal to $16^{\mathit{digits}}$
+% then |\a_count| will be set to \meta{value} divided by this number
+% and the formatted value will be for the corresponding remainder.
+% \changes{1.928}{2004/11/28}{Macro added. (LH)}
+%
+% The macro overwrites |\a_count|, |\b_count|, and |\c_count|.
+%
+% \begin{macro}{\format_hex_i}
+% The |\format_hex_i| macro is the iterator for |\format_hex|.
+% It is used in the context
+% \begin{quote}
+% |\format_hex_i|\marg{command}\marg{control token}
+% \end{quote}
+% If the \meta{control token} is |i| then nothing is done.
+% Otherwise the quotient and remainder of |\a_count| with respect to
+% $16$ is computed, where the former is assigned to |\a_count| and
+% the latter is converted to hexadecimal and prepended to the
+% \meta{command}, after which the macro expands to
+% |\format_hex_i|\meta{command}.
+% \begin{macrocode}
+%<*pkg>
+\def\format_hex_i#1#2{
+ \if #2i \else
+ \b_count=\a_count
+ \divide \a_count \sixt@@n
+ \c_count=\a_count
+ \multiply \c_count \sixt@@n
+ \advance \b_count -\c_count
+ \edef#1{
+ \ifcase\b_count 0\or 1\or 2\or 3\or 4\or 5\or 6\or 7\or 8\or
+ 9\or a\or b\or c\or d\or e\or f\fi
+ #1
+ }
+ \expandafter\format_hex_i \expandafter#1
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% To get the loop to run the wanted number of times, one uses the
+% trick that |\romannumeral| can generate an arbitrary number of |m|s.
+% The |\identity_one| stuff is to prevent |\number| from processesing
+% the subsequent |001~|, which will be the last that |\romannumeral|
+% reads.
+% \begin{macrocode}
+\def\format_hex#1#2#3{
+ \a_count=#2
+ \let#1\empty_command
+ \expandafter\format_hex_i \expandafter#1 \romannumeral
+ \expandafter\identity_one\expandafter{\number#3}001~
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \subsection{Error, warning, and info messages}
+%
+% The code in this subsection is an adaptation of code from the
+% \LaTeX\ kernel---more precisely from the source file
+% \texttt{lterror.dtx}---and the same is true for some of the comments.
+% As authors of that code are listed Johannes Braams, David Carlisle,
+% Alan Jeffrey, Leslie Lamport, Frank Mittelbach, Chris Rowley, and
+% Rainer Sch\"opf. The original source can be found in the file
+% \texttt{lterror.dtx} in the \texttt{macros}\slash\texttt{latex}\slash
+% \texttt{base} directory in any of the Comprehensive \TeX\ Archive
+% Network FTP sites.\footnote{As if anyone who has managed to get this
+% far didn't already know that!}
+%
+% That should have fulfilled the conditions in the LPPL.^^A
+% \changes{1.906}{1999/07/23}{Adaptation of \LaTeX's message system
+% completed. (LH)}
+% \par\bigskip
+%
+%
+% \subsubsection{General commands}
+%
+% \begin{macro}{\messagebreak}
+% This command prints a new-line inside a message, followed by a
+% continuation whose exact appearence may depend on the context.
+% Normally this command is defined to be |\relax|, but inside messages
+% it gets redefined to a linebreak (|^^J|) followed by the appropriate
+% continuation.
+% \changes{1.909}{1999/10/16}{New name for \cs{message_break}. (LH)}
+% \begin{macrocode}
+%<pkg>\let\messagebreak\x_relax
+%<doc>\let\messagebreak\space
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\generic_info}
+% This takes two arguments: a continuation and a message, and sends
+% the result to the log file.
+% \begin{macrocode}
+%<*pkg>
+\def\generic_info#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\m@ne{#2\on_line.}
+ \endgroup
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\generic_warning}
+% This takes two arguments: a continuation and a message, and sends
+% the result to the screen.
+% \begin{macrocode}
+\def\generic_warning#1#2{
+ \begingroup
+ \def\messagebreak{^^J#1}
+ \immediate\write\closed_stream{^^J#2\on_line.^^J}
+ \endgroup
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\generic_error}
+% ``This macro takes four arguments: a continuation,
+% an error message, where to go for further information, and the help
+% information. It displays the error message, and sets the error help
+% (the result of typing |h| to the prompt), and does a horrible hack
+% to turn the last context line (which by default is the only context
+% line) into just three dots. This could be made more efficient.''
+%
+% Thus far the \LaTeX\ comments, but the horrible hack it mensions
+% has been removed since it just makes things look strange when
+% |\errorcontextlines| is larger than one.
+% ^^A What the hack actually does is that it turns
+% ^^A as much as possible of the topmost context line to spaces. It has
+% ^^A two ways of achieving this. The first is to make the context line
+% ^^A too long to display in full, by ending the argument of |\errmessage|
+% ^^A with the control sequence
+% ^^A \begin{quote}
+% ^^A \tiny\verb*+\@err@ +^^A
+% ^^A \verb*+ +
+% ^^A \end{quote}
+% ^^A As its name ends with a long sequence of spaces, it won't be visible;
+% ^^A the |@err@| appears in the |...| part of the line. The other method
+% ^^A it uses is to turn every token in the context line that is not part
+% ^^A of a control sequence name to spaces (as characters, not in
+% ^^A category) through a |\lowercase| trick. The only characters that
+% ^^A cannot be turned into spaces this way are the three continuation
+% ^^A dots.
+% The ``where to go for further information'' message is currently not
+% used (it is commented out in |\fontinsterror| below), since there
+% is no good place to refer to anyway. If the documentation is ever
+% improved in this respect, it would of course be best to reinsert
+% this message. Note however that unlike the case in \LaTeX, this
+% message should end with a |^^J|.
+%
+% A complication is that \TeX\ versions older than 3.141 have a bug
+% which causes |^^J| to not force a linebreak in |\message| and
+% |\errmessage| commands. So for these old \TeX's we use a |\write| to
+% produce the message, and then have an empty |\errmessage| command.
+% This causes an extra line of the form
+%\begin{verbatim}
+%! .
+%\end{verbatim}
+% to appear on the terminal, but if you do not like it, you can always
+% upgrade your \TeX!
+%
+% Since I don't think many \package{fontinst} users use such old
+% \TeX s, I removed \LaTeX's test for \TeX\ version at this point. The
+% code for old \TeX s is still there, but it lies in a \package{docstrip}
+% module of its own.
+%
+% First the `standard case'.
+% \begin{macrocode}
+%<*!oldTeX>
+\def\generic_error#1#2#3#4{
+ \begingroup
+ \immediate\write\closed_stream{}
+ \def\messagebreak{^^J}
+ \edef\a_macro{{#4}}
+ \errhelp\a_macro
+ \def\messagebreak{^^J#1}
+ \errmessage{#2.^^J^^J#3
+ Type~\space H~<return>~\space for~immediate~help
+ }
+ \endgroup
+}
+%</!oldTeX>
+% \end{macrocode}
+%
+% Secondly the version for old \TeX's.
+% \begin{macrocode}
+%<*oldTeX>
+\def\generic_error#1#2#3#4{%
+ \begingroup
+ \immediate\write\closed_stream{}
+ \def\messagebreak{^^J}
+ \edef\a_macro{{#4}}
+ \errhelp\a_macro
+ \def\messagebreak{^^J#1}
+ \immediate\write\closed_stream{!~#2.^^J^^J#3^^J
+ Type~\space H~<return>~\space for~immediate~help.
+ }
+ \errmessage{}
+ \endgroup
+}
+%</oldTeX>
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \begin{macro}{\fontinsterror}
+% \changes{1.909}{1999/10/16}{New name for \cs{fontinst_error}. (LH)}
+% \begin{macro}{\fontinstwarning}
+% \changes{1.909}{1999/10/16}{New name for \cs{fontinst_warning}. (LH)}
+% \begin{macro}{\fontinstwarningnoline}
+% \changes{1.909}{1999/10/16}{New name for
+% \cs{fontinst_warning_no_line}. (LH)}
+% \begin{macro}{\fontinstinfo}
+% \changes{1.909}{1999/10/16}{New name for \cs{fontinst_info}. (LH)}
+% These commands are intended for giving a uniformed, and for the
+% programmers hopefully simplified, form of error, warning, and info
+% messages. The syntax is:
+% \begin{quote}
+% |\fontinsterror|\marg{subsystem}\marg{error}\marg{help}\\
+% |\fontinstwarning|\marg{subsystem}\marg{warning}\\
+% |\fontinstwarningnoline|\marg{subsystem}\marg{warning}\\
+% |\fontinstinfo|\marg{subsystem}\marg{info}
+% \end{quote}
+% A \meta{subsystem} in this context is intended to be some piece of
+% text which identifies some functionally clearly defined part of
+% \package{fontinst}. Examples of \meta{subsystem}s could be
+% \texttt{PL to MTX converter}, \texttt{Ligful (V)PL writer}, and
+% \texttt{Latin family}.
+%
+% The |\fontinsterror| command prints the \meta{error} message, and
+% presents the interactive prompt; if the user types |h|, then the
+% \meta{help} information is displayed. The |\fontinstwarning|
+% command produces a warning but does not present the interactive
+% prompt. The |\fontinstwarningnoline| command does the same, but
+% doesn't print the input line number. The |\fontinstinfo| command
+% writes the message to the |log| file. Within the messages, the
+% command |\messagebreak| can be used to break a line and |\space| is
+% a space, for example:
+% \begin{verbatim}
+% \def\foo{FOO}
+% \fontinstwarning{Hungarian}{
+% Your~hovercraft~is~full~of~eels,\messagebreak
+% and~\string\foo\space is~\foo}
+% \end{verbatim}
+% produces:
+% \begin{verbatim}
+% Hungarian warning:
+% Your hovercraft is full of eels,
+% and \foo is FOO on input line 54.
+% \end{verbatim}
+%
+% \begin{macrocode}
+\def\fontinsterror#1#2#3{
+ \generic_error{
+ \four_spaces\four_spaces
+ }{
+ #1~error:\messagebreak #2
+ }{
+% See~the~#1~package~documentation~for~explanation.^^J
+ }{#3}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\fontinstwarning#1#2{
+ \generic_warning{
+ \four_spaces\four_spaces
+ }{
+ #1~warning:\messagebreak #2
+ }
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\fontinstwarningnoline#1#2{
+ \fontinstwarning{#1}{#2\gobble_one}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\fontinstinfo#1#2{
+ \generic_info{
+ \four_spaces\four_spaces
+ }{
+ #1~info:\messagebreak #2
+ }
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\def\fontinsterror#1#2#3{%
+ \Bheading{Error} observed by #1:%
+ \begin{quote}#2.\end{quote}%
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\fontinstwarning#1#2{
+ \Bheading{Warning} from #1:%
+ \begin{quote}#2.\end{quote}%
+}
+% \end{macrocode}
+% \begin{macrocode}
+\let\fontinstwarningnoline=\fontinstwarning
+% \end{macrocode}
+% \begin{macrocode}
+\def\fontinstinfo#1#2{
+ \Bheading{Info} from #1:%
+ \begin{quote}#2.\end{quote}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\on_line}
+% The message ` on input line~$n$'. \LaTeX\ has special code for
+% \TeX~2, but since \package{fontinst} has assumed the existence of
+% the |\errorcontextlines| parameter since v\,1.500, the removal of
+% that code shouldn't cause problems for anyone who wasn't already
+% having related problems.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\on_line{~on~input~line~\the\inputlineno}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\four_spaces}
+% Four spaces. Using |\edef| (rather than |\def| as in \LaTeX) to
+% save some macro expansions.
+% \begin{macrocode}
+\edef\four_spaces{\space\space\space\space}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsubsection{Specific errors}
+%
+% \begin{macro}{\error_help_a}
+% \begin{macro}{\error_help_c}
+% \begin{macro}{\error_help_d}
+% \begin{macro}{\error_help_e}
+% \changes{1.912}{2000/02/12}{Macro added. (LH)}
+% The more common error help messages. The first three are called
+% |\@eha|, |\@ehc|, and |\@ehd| in \LaTeX. |\@ehb| is of no use for
+% \package{fontinst}, so it has been omitted. |\error_help_e| is a
+% new one for \package{fontinst}.
+% \begin{macrocode}
+\gdef\error_help_a{
+ Your~command~was~ignored.\messagebreak
+ Type~\space I~<command>~<return>~\space to~replace~it~
+ with~another~command,\messagebreak
+ or~\space <return>~\space to~continue~without~it.}
+\gdef\error_help_c{
+ Try~typing~\space <return>~
+ \space to~proceed.\messagebreak
+ If~that~doesn't~work,~type~\space X~<return>~\space to~quit.}
+\gdef\error_help_d{
+ You're~in~trouble~here.~\space\error_help_c}
+\def\error_help_e#1{You~can~continue,~but~the~#1~wrong.}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+%
+% \subsubsection{\TeX\ parameters}
+%
+% \multchanges{\cs{newlinechar}\cs{errorcontextlines}}{1.914}
+% {2000/05/20}{Moved to error message subsection. (LH)}
+% \begin{macro}{\newlinechar}
+% Set |\newlinechar| for |\errhelp| messages.
+% \begin{macrocode}
+\newlinechar=`\^^J
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\errorcontextlines}
+% By default, show as much error info as you can.
+% (We assume \package{fontinst} users are \TeX{}perts.)
+% \begin{macrocode}
+\errorcontextlines=999
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\tracinglostchars}
+% \changes{1.915}{2000/07/31}{Added setting this parameter. (LH)}
+% Make |\tracinglostchars| positive---this will simplify catching
+% bugs, as many \package{fontinst} bugs show up in that output is
+% being generated, but that used to disappear silently when
+% \package{fontinst} was run under Ini\TeX.
+% \begin{macrocode}
+\tracinglostchars=1
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+% \Finale
+\endinput \ No newline at end of file
diff --git a/fonts/utilities/fontinst/source/ficommon.dtx b/fonts/utilities/fontinst/source/ficommon.dtx
new file mode 100644
index 0000000000..22348cd9ce
--- /dev/null
+++ b/fonts/utilities/fontinst/source/ficommon.dtx
@@ -0,0 +1,2416 @@
+% \CheckSum{2283}
+% \iffalse meta-comment
+%
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999, 2000, 2001 the fontinst maintenance team and
+% any individual authors listed elsewhere in this file.
+% All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.2 or, at your option, any later version.
+%
+%%% From file: ficommon.dtx
+%
+%<*driver>
+\documentclass{ltxdoc}
+\usepackage{fisource}
+\title{The \package{fontinst} utility}
+\author{Alan Jeffrey, Sebastian Rahtz, Ulrik Vieth, Lars Hellstr\"om}
+\begin{document}
+\maketitle
+\tableofcontents
+\DocInput{ficommon.dtx}
+\end{document}
+%</driver>
+% \fi
+%
+% \StopEventually{}
+%
+%
+% \section{General commands}
+% \changes{1.916}{2000/12/27}{Moved Section \thesection\ to
+% \texttt{ficommon.dtx}. (LH)}
+%
+% \changes{1.916}{2001/01/02}{\emph{Major} overhaul of \package{fontdoc}
+% mechanisms for integer and string expressions completed. (LH)}
+% There are roughly five types of arguments that \package{fontinst}
+% commands can take. These are
+% \begin{itemize}
+% \item integer expressions,
+% \item string expressions,
+% \item dimensions,
+% \item commands (i.e., \TeX\ control sequences), and
+% \item other (pretty much ``none of the above'').
+% \end{itemize}
+% The most common form of an integer expression is simply a \TeX\
+% \meta{number} and the most common form of a string expression is
+% simply a sequence of character tokens, but there are more complicated
+% forms. Dimensions are simply \TeX\ \meta{dimen}s; their use is rather
+% limited. Common to integer expressions, string expressions, and
+% dimensions is that these argument types get expanded during
+% evaluation (in the case of string expressions, this expansion
+% \emph{is} the evaluation), which means one can use macros in
+% arguments of these types.
+%
+% Command arguments do not get expanded---they are mainly used with
+% commands that modify the definitions of other commands. As for the
+% ``other'' arguments one cannot give any rules: they might get
+% expanded, but it could also happen that they won't.
+%
+%
+% \subsection{String expressions}
+%
+% The first problem with string expressions is to typeset the values.
+% The character strings that appear in ETX and MTX files usually consist
+% only of immediately printable characters, but there are a few
+% characters (such as underscore) which may be used even though they
+% aren't directly printable. This subsection defines commands which deal
+% with this problem by replacing non-printable characters by commands.
+% The implementation is based on the implementation of the
+% |\MakeHarmless| command in the \package{xdoc} package.
+%
+% \subsubsection{Typesetting problematic characters}
+%
+% \begin{macro}{\PrintChar}
+% \begin{macro}{\InvisibleCharPrefix}
+% \begin{macro}{\InvisibleCharSuffix}
+% The |\PrintChar| command has the syntax
+% \begin{quote}
+% |\PrintChar|\marg{8-bit number}
+% \end{quote}
+% where \meta{8-bit number} is a \TeX\ number in the range 0--255.
+% For arguments in the range 0--31, |\PrintChar| prints
+% `\textit{\ttfamily\string^\string^@}'--`\textit{\ttfamily
+% \string^\string^_}'. For an argument in the range 32--126,
+% |\PrintChar| calls |\Print|\-|Visible|\-|Char| which typesets the
+% corresponding ASCII character (similar to |\char|, but it takes the
+% path via the \LaTeX\ internal representation so that it works with
+% non-typewriter \texttt{OT1} fonts); in particular, |\PrintChar{32}|
+% prints a ``visible space'' character. |\PrintChar{127}| prints
+% `\textit{\ttfamily\string^\string^?}'. For arguments in the range
+% 128--255, |\PrintChar| prints
+% `\textit{\ttfamily\string^\string^80}'--`\textit{\ttfamily
+% \string^\string^ff}'.
+% The |\PrintChar| command is robust.
+%
+% The macros |\InvisibleCharPrefix| and |\InvisibleCharSuffix| begin
+% and end a |^^|-sequence. |\InvisibleCharPrefix| should print the
+% actual |^^|, but it may also for example select a new font for
+% the |^^|-sequence (such font changes are restored at the end of
+% |\PrintChar|).
+% \begin{macrocode}
+%<*doc>
+\DeclareRobustCommand\PrintChar[1]{%
+ \leavevmode
+ \begingroup
+ \count@=#1\relax
+ \ifnum \@xxxii>\count@
+ \advance \count@ 64%
+ \InvisibleCharPrefix
+ \PrintVisibleChar\count@
+ \InvisibleCharSuffix
+ \else\ifnum 127>\count@
+ \PrintVisibleChar\count@
+ \else
+ \InvisibleCharPrefix
+ \ifnum 127=\count@ \PrintVisibleChar{63}\else
+ \@tempcnta=\count@
+ \divide \count@ \sixt@@n
+ \@tempcntb=\count@
+ \multiply \count@ \sixt@@n
+ \advance \@tempcnta -\count@
+ \advance \@tempcntb \ifnum 9<\@tempcntb 87\else 48\fi
+ \advance \@tempcnta \ifnum 9<\@tempcnta 87\else 48\fi
+ \char\@tempcntb \char\@tempcnta
+ \fi
+ \InvisibleCharSuffix
+ \fi\fi
+ \endgroup
+}
+% \end{macrocode}
+% \begin{macrocode}
+\newcommand\InvisibleCharPrefix{%
+ \/\em
+ \PrintVisibleChar{`\^}\PrintVisibleChar{`\^}%
+}
+\newcommand\InvisibleCharSuffix{\/}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\PrintVisibleChar}
+% The |\PrintVisibleChar| command should print the visible ASCII
+% character whose character code is given in the argument. The
+% definition given here translates every character code to the
+% corresponding \LaTeX\ internal representation, which is necessary
+% if the current font is e.g.\ an \texttt{OT1}-encoded non-typewriter
+% font. If the current font is known to be \texttt{T1}-encoded then
+% one can do just as well with |\char#1 | as the replacement text.
+% \begin{macrocode}
+\newcommand\PrintVisibleChar[1]{%
+ \ifcase #1%
+ \or\or\or\or\or\or\or\or \or\or\or\or\or\or\or\or
+ \or\or\or\or\or\or\or\or \or\or\or\or\or\or\or\or
+ % "20
+ \textvisiblespace \or!\or\textquotedbl \or\#\or\textdollar
+ \or\%\or\&\or\textquoteright\or(\or)\or*\or+\or,\or-\or.\or/%
+ \or % "30
+ 0\or1\or2\or3\or4\or5\or6\or7\or8\or9\or:\or;\or
+ \textless\or=\or\textgreater\or?%
+ \or % "40
+ @\or A\or B\or C\or D\or E\or F\or G\or
+ H\or I\or J\or K\or L\or M\or N\or O%
+ \or % "50
+ P\or Q\or R\or S\or T\or U\or V\or W\or X\or Y\or Z\or [\or
+ \textbackslash \or]\or\textasciicircum \or\textunderscore
+ \or % "60
+ \textquoteleft \or a\or b\or c\or d\or e\or f\or g\or h\or
+ i\or j\or k\or l\or m\or n\or o%
+ \or % "70
+ p\or q\or r\or s\or t\or u\or v\or w\or x\or y\or z\or
+ \textbraceleft \or\textbar \or\textbraceright \or\textasciitilde
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\textvisiblespace}
+% The |\textvisiblespace| command, which is heavily used in names of
+% coding schemes, unfortunately has a default definition which lacks
+% leading on the right side. This redefinition attempts to improve
+% things.
+% \changes{1.921}{2002/03/27}{Redefinition added. (LH)}
+% \begin{macrocode}
+\DeclareTextCommandDefault{\textvisiblespace}{%
+ \makebox[\fontdimen\tw@\font]{%
+ \hfil
+ \vrule \@height.3ex%
+ \vbox{\hrule \@width .66\fontdimen\tw@\font}%
+ \vrule \@height.3ex%
+ \hfil
+ }%
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\FD@quoted@PrintChar}
+% One sometimes wants to use a printable character string as part of a
+% control sequence name. If the normal definition of |\PrintChar| is
+% in force at such times then each |\PrintChar| in the string would
+% produce lots of errors, which is why |\FD@quoted@PrintChar| has
+% been defined. This macro is an alternative definition of
+% |\PrintChar| which expands to |"|\meta{number}|"|, which can be part
+% of a macro name.
+% \begin{macrocode}
+\def\FD@quoted@PrintChar#1{"\number#1"}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsubsection{Converting character strings}
+%
+% Replacing all problematic characters with |\PrintChar| calls certainly
+% makes the strings easier to manage, but actually making those
+% replacements is a rather complicated task. This subsubsection
+% contains the macros necessary for doing these replacements.
+%
+% The first problem is how to efficiently recognise the problematic
+% characters. One might think that it is sufficient to look at their
+% |\catcode|, but that will fail for characters like |<| whose normal
+% catcode is 12 but do not appear in the \texttt{OT1} encoding. Because
+% of this, I have chosen a brute strength solution: build a table
+% (indexed by character code) that gives the printable form of
+% every character. This table is stored in the
+% \describecsfamily{FD@printable@\meta{code}}^^A
+% |\FD@printable@|\meta{code} family of control sequences, where the
+% \meta{code} is in the range |32|--|126|. The printable form of
+% characters outside this range is always the |\PrintChar| form.
+% \begin{macrocode}
+\count@=32
+\begingroup
+ \catcode\z@=12\relax
+ \@firstofone{%
+\endgroup
+ \loop
+ \if \ifnum 11=\catcode\count@ 1\else \ifnum 12=\catcode\count@
+ 1\else 0\fi\fi 1%
+ \uccode\z@=\count@
+ \uppercase{\def\@tempa{^^@}}%
+ \else
+ \edef\@tempa{\noexpand\PrintChar{\the\count@}}%
+ \fi
+ \x@cs\let{FD@printable@\the\count@}=\@tempa
+ \advance \count@ \@ne
+ \ifnum 127>\count@ \repeat
+}
+% \end{macrocode}
+% This loop hasn't caught all non-printable characters, so a few
+% entries have to be set explicitly.
+% \begin{macrocode}
+\@namedef{FD@printable@34}{\PrintChar{34}} % "
+\@namedef{FD@printable@60}{\PrintChar{60}} % <
+\@namedef{FD@printable@62}{\PrintChar{62}} % >
+% \end{macrocode}
+%
+%
+% \begin{macro}{\MakePrintable}
+% To render a character string harmless, you do
+% \begin{quote}
+% |\MakePrintable|\marg{macro}\marg{flag}\marg{string}
+% \end{quote}
+% This locally assigns to \meta{macro} the printable character string
+% which corresponds to \meta{string}. Furthermore the control sequence
+% |\if|\meta{flag} is locally let to |\iftrue| or |\iffalse|
+% depending on whether the printable string is simple (only consists
+% of character tokens and |\PrintChar| commands) or not.
+%
+% During the conversion the converted part of the string is stored in
+% |\toks@| and the |@tempswa| switch keeps track of whether the string
+% so far is simple (yes when |false|), but those are both local to
+% |\MakePrintable|.
+% \begin{macrocode}
+\def\MakePrintable#1#2#3{%
+ \begingroup
+ \toks@={}%
+ \escapechar=`\\%
+ \@tempswafalse
+ \FD@printable@#3\protect\FD@printable@
+ \toks@=\expandafter{%
+ \expandafter\let \csname if#2\expandafter\endcsname
+ \csname if\if@tempswa false\else true\fi \expandafter\endcsname
+ \expandafter\def \expandafter#1\expandafter{\the\toks@}%
+ }%
+ \expandafter\endgroup \the\toks@
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\FD@printable@iii}
+% \begin{macro}{\FD@printable@iv}
+% \begin{macro}{\FD@printable@v}
+% \begin{macro}{\FD@printable@vi}
+% What one has to be most careful about when making strings printable
+% are the space tokens, since many of \TeX's primitives gladly
+% snatches an extra space (or more) where you don't want them to in
+% this case. Macro parameters can be particularly dangerous, as \TeX\
+% will skip any number of spaces while looking for the replacement
+% text for an undelimited macro argument. Therefore the algorithm for
+% rendering a character token harmless consists begins
+% (|\FD@printable@iii|) with |\string|ing the next token in the
+% string---this preserves the character code and sets the category to
+% 12 for all characters except the ASCII space, which gets category 10
+% (space)---and then |\futurelet| is used to peek at the next token. If
+% it is a space token (|\FD@printable@iv|) then the character code
+% is 32 and the actual space can be gobbled (|\FD@printable@v|), and
+% if it isn't then the next token can be grabbed in a undelimited macro
+% argument (|\FD@printable@vi|). In either case, the harmless form
+% is given by the |\FD@printable@|\meta{code} table entry
+% (in |\FD@printable@v| or |\FD@printable@vi|).
+% \begin{macrocode}
+\def\FD@printable@iii{%
+ \expandafter\futurelet \expandafter\@let@token
+ \expandafter\FD@printable@iv \string
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\FD@printable@iv{%
+ \ifx \@let@token\@sptoken
+ \expandafter\FD@printable@v
+ \else
+ \expandafter\FD@printable@vi
+ \fi
+}
+% \end{macrocode}
+% ^^A Hack:
+% \begingroup
+% \expandafter\def \expandafter\MakePrivateLetters \expandafter{^^A
+% \MakePrivateLetters
+% \catcode`3=11
+% \catcode`2=11
+% }
+% \begin{macrocode}
+\begingroup
+ \catcode`3=\catcode`a
+ \catcode`2=\catcode`a
+ \@firstofone{\gdef\FD@printable@v} {%
+ \toks@=\expandafter{\the \expandafter\toks@ \FD@printable@32}%
+ \FD@printable@
+ }
+\endgroup
+% \end{macrocode}
+% \endgroup
+% \begin{macrocode}
+\def\FD@printable@vi#1{%
+ \if \ifnum `#1<\@xxxii 1\else \ifnum `#1>126 1\else 0\fi\fi 1%
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\PrintChar \expandafter{\number`#1}%
+ }%
+ \else
+ \toks@=\expandafter{\the\expandafter\expandafter\expandafter\toks@
+ \csname FD@printable@\number`#1\endcsname}%
+ \fi
+ \FD@printable@
+}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\FD@printable@}
+% \begin{macro}{\FD@printable@i}
+% \begin{macro}{\FD@printable@ii}
+% \begin{macro}{\FD@printable@vii}
+% But that is not all |\MakePrintable| can do. One must also deal
+% with things in the string that are not simply characters, but more
+% complex items (for example |\str| and |\strint| constructions). When
+% control sequences that start such complex items are fed to
+% |\MakePrintable| they must be preceeded by a |\protect| (they will
+% be if the original command is defined using \LaTeX's
+% |\Declare|\-|Robust|\-|Command| command and the string has been fed
+% through a |\protected@edef|, which happens to be the case); this
+% |\protect| is taken as a signal that the next token should get
+% special processing. Control sequences that are not preceeded by a
+% |\protect| are simply |\string|ed.
+%
+% To accommodate for this, |\FD@printable@| (which is the first step
+% in converting a token) always begins by checking (in |\FD@|\-^^A
+% |printable@i|) whether the next token is a control sequence. If it
+% is and that control sequence is |\protect| then it is checked (in
+% |\FD@printable@ii|) whether the control sequence
+% \describecsfamily{FD@printable\PrintChar{`\\}\meta{cs-name}}^^A
+% |\FD@printable\|\meta{cs-name}, where \meta{cs-name} is the name
+% without |\| (and with any spaces removed) of the control sequence
+% encountered, is defined. If it is defined then control is handed
+% over to |\FD@printable\|\meta{cs-name} which should process the
+% arguments (if any) of |\|\meta{cs-name} and add a suitable
+% representation to |\toks@|, but if |\FD@printable\|\meta{cs-name}
+% isn't defined then this is considered to be an error.
+%
+% If the next token isn't a control sequence then control is handed
+% over to |\FD@printable@ii|. If the next token is a control sequence
+% but not |\protect| then that token is |\string|ed (in
+% |\FD@printable@vii|) and control is handed over to
+% |\FD@printable@vi|.
+% \begin{macrocode}
+\def\FD@printable@{\futurelet\@let@token \FD@printable@i}
+% \end{macrocode}
+% \begin{macrocode}
+\def\FD@printable@i{%
+ \csname FD@printable@%
+ \ifcat \noexpand\@let@token \noexpand\FD@printable@
+ \ifx \@let@token\protect ii\else vii\fi
+ \else iii\fi
+ \endcsname
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\FD@printable@ii\protect#1{%
+ \@ifundefined{FD@printable\expandafter\zap@space\string#1 \@empty}{%
+ \PackageError{fontdoc}{Command \protect#1 not allowed in string}%
+ \@eha
+ }{\csname FD@printable\expandafter\zap@space\string#1 \@empty
+ \endcsname}%
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\FD@printable@vii{\expandafter\FD@printable@vi \string}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\FD@printable\FD@printable@}
+% A control sequence |\FD@printable\|\meta{cs-name} is responsible for
+% interpreting the string item that begins with the control sequence
+% |\|\meta{cs-name} and appending a printable representation of it to
+% |\toks@|. Normal |\FD@printable\|\meta{cs-name} control sequences
+% must also end by inserting |\FD@printable@| in front of what remains
+% of the string after the complex string item has been removed. This
+% sees to that the rest of the string is also made printable. The only
+% such control sequence which does not insert |\FD@printable@| is
+% |\FD@printable\FD@printable@|, but that is as it should be since
+% |\MakePrintable| itself appends a |\FD@printable@| to every character
+% string it should convert to mark the end of it.
+% \begin{macrocode}
+\expandafter\let
+ \csname FD@printable\string\FD@printable@\endcsname \@empty
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\FD@printable\PrintChar}
+% It is occasionally convenient to use a |\PrintChar| command as part
+% of a string that is to be made harmless instead of using the raw
+% character. The definition is very similar to that of
+% |\FD@printable@vi|.
+% \begin{macrocode}
+\@namedef{FD@printable\string\PrintChar}#1{%
+ \if \ifnum #1<\@xxxii 1\else \ifnum #1>126 1\else 0\fi\fi 1%
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\PrintChar \expandafter{\number#1}%
+ }%
+ \else
+ \toks@=\expandafter{\the\expandafter\expandafter\expandafter\toks@
+ \csname FD@printable@\number#1\endcsname}%
+ \fi
+ \FD@printable@
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\ExpandAndMakePrintable}
+% The |\ExpandAndMakePrintable| command is an abbreviation for a
+% common use of |\MakePrintable|, namely to first feed the string
+% through a |\protected@edef| to get rid of all the simple macros.
+% \begin{macrocode}
+\newcommand*\ExpandAndMakePrintable[3]{%
+ \protected@edef\@tempa{{#2}{#3}}%
+ \expandafter\MakePrintable \expandafter#1\@tempa
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsubsection{Evaluating string expressions}
+%
+% In string expressions, the only available operation is juxtaposition
+% (fancy name for putting things next to each other) and thus the
+% syntax for a string expression is
+% \begin{quote}
+% \meta{string expression} \(\longrightarrow\) $\emptyset \mid$
+% \meta{string atom}\meta{string expression}
+% \end{quote}
+% where $\emptyset$ denotes the empty string. A \meta{string atom} is
+% one of
+% \begin{quote}
+% \meta{character token}\\
+% |\str|\marg{string expression}\\
+% |\strint|\marg{string expression}
+% \end{quote}
+% The meaning of a \meta{character token} is explained
+% in~\cite{TeXbook}. The |\str| and |\strint| forms of
+% \marg{string atom} refer to the respective values of the string and
+% integer variables (see Subsection~\ref{Ssec:Variables}) whose names
+% are given in the argument of |\str| or |\strint| respectively. Since
+% the names of variables are themselves string expressions, |\str| and
+% |\strint| may themselves be used in names of variables.
+%
+% It should be noted that most of \package{fontinst}'s string
+% expressions sooner or later end up between a |\csname| and the
+% corresponding |\endcsname|. This places significant restrictions on
+% what may occur in string expressions.
+%
+% \begin{macro}{\str}
+% \begin{macro}{\strint}
+% \changes{1.909}{1999/10/19}{Change to stop it from gobbling a
+% following space if the integer is stored in a macro. (LH)}
+% In \package{fontinst} the only macros needed for dealing with string
+% expressions are |\str| and |\strint|.
+% \begin{macrocode}
+%<*pkg>
+\def\str#1{\csname~s-#1\endcsname}
+\def\strint#1{\expandafter\identity_one\expandafter{\number\int{#1}}}
+%</pkg>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \package{fontdoc} mainly uses \TeX's text mode for typesetting string
+% expressions because not all characters are available in math mode;
+% it's easier to switch to text mode than to augment the math setup. One
+% kind of material is however typeset in math mode, namely
+% ``string-valued functions'': the name and functional parenthesis of
+% such material is typeset in math mode to get a mathematical look.
+%
+% \begin{macro}{\FD@string@func}
+% The |\FD@string@func| macro has the syntax
+% \begin{quote}
+% |\FD@string@func|\marg{name}\marg{argument}
+% \end{quote}
+% It is used for typesetting the \meta{name}$($\meta{argument}$)$ of a
+% string-valued function (e.g.\ the value-of-string-variable function
+% $\mathrm{s}$). It should only be used in horizontal mode.
+%
+% |\FD@string@func| includes a bit of extra spacing around the typeset
+% text, but not at the beginning or end of a string and neither
+% between two string-valued functions. As a flag for this is used
+% that the value of |\spacefactor| is 1; when it is one should proceed
+% as if this extra spacing is already present.
+% \begin{macrocode}
+%<*doc>
+\def\FD@string@func#1#2{%
+ \relax
+ \ifnum \spacefactor=\@ne $\mkern1mu\else$\fi
+ \mathrm{#1}($%
+ #2%
+ \ifnum \spacefactor=\@ne $\mkern-1mu\else $\fi)\mkern1mu$%
+ \spacefactor=\@ne
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\TypesetStringExpression}
+% \begin{macro}{\FD@typeset@string}
+% \begin{macro}{\ifFD@swa}
+% In \package{fontdoc} the string expressions must be typeset, and
+% that is not trivial due to that (i) not all character tokens have
+% catcode 11 or 12 and (ii) not all characters are available in all
+% fonts. Furthermore the non-character string atoms should be given
+% special treatment in character strings!
+%
+% Because of this, string expressions that are to be typeset are
+% handed to a special command |\TypesetStringExpression|, which takes
+% the string to typeset as its only argument. This string may contain
+% user-defined macros.
+% \begin{macrocode}
+\newcommand\TypesetStringExpression[1]{%
+ \protected@edef\@tempa{%
+ \noexpand\MakePrintable \noexpand\@tempa {FD@swa}{#1}%
+ }%
+ \@tempa
+ \FD@typeset@string{\@tempa}%
+}
+% \end{macrocode}
+% Actually typesetting the string is handled in |\FD@typeset@string|,
+% but strings handed to this macro must be preprocessed by a full
+% protected expansion and a |\MakeHarmless|.
+% \begin{macrocode}
+\def\FD@typeset@string#1{%
+ \mbox{%
+ \normalfont\ttfamily
+ \spacefactor=\@ne
+ #1%
+ \ifnum \spacefactor=\@ne $\mkern-1mu\m@th$\fi
+ }%
+}
+% \end{macrocode}
+% The |\ifFD@swa| control sequence is often |\let| to |\iftrue| or
+% |\iffalse| by |\Make|\-|Printable|, and then it is used as a
+% conditional. Since that assignment sometimes takes place in
+% conditional text however, one must make sure that |\ifFD@swa|
+% always is some conditional.
+% \begin{macrocode}
+\let\ifFD@swa\iffalse
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\str}
+% \begin{macro}{\FD@printable\str}
+% The processing of the |\str| macro in \package{fontdoc} is far from
+% straightforward. |\str| has to be robust, but apart from that its
+% defintion has no effect on how its argument is processed. That is
+% instead controlled by |\FD@printable\str|, which happens to use
+% |\str| as an auxiliary formatting macro.
+%
+% Most of the complexity below is however due to the processing
+% needed to determine whether the string variable accessed has been
+% assigned a value. See |\Set|\-|String|\-|Variable| for more
+% information.
+% \begin{macrocode}
+\DeclareRobustCommand\str[1]{\FD@string@func{s}{#1}}
+\@namedef{FD@printable\string\str}#1{%
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \begingroup
+ \let\PrintChar=\FD@quoted@PrintChar
+ \if \ifFD@swa \@ifundefined{FD@s-\@tempa}{0}{1}\else 0\fi 1%
+ \expandafter
+ \endgroup
+ \csname FD@s-\@tempa\endcsname
+ \else
+ \endgroup
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\str \expandafter{\@tempa}}%
+ \@tempswatrue
+ \fi
+ \FD@printable@
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\strint}
+% \begin{macro}{\FD@printable\strint}
+% |\strint| is handled similarly to |\str|.
+% \begin{macrocode}
+\DeclareRobustCommand\strint[1]{\FD@string@func{int}{#1}}
+\@namedef{FD@printable\string\strint}#1{%
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \protected@edef\@tempa{%
+ \ifFD@swa \protect\FD@simple@int \else \strint \fi{\@tempa}%
+ }
+ \toks@=\expandafter{\the\expandafter\toks@ \@tempa}%
+ \@tempswatrue
+ \FD@printable@
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\macroparameter}
+% \changes{1.916}{2001/01/06}{Command added. (LH)}
+% \begin{macro}{\FD@printable\macroparameter}
+% The |\macroparameter| command can be used in string and integer
+% expressions as a sort of ``macro parameter placeholder''. It is not
+% defined in \package{fontinst}, but in \package{fontdoc} one
+% occationally writes comments which say things like ``XXX is short
+% for ASDFSKADN'', and in those cases one can use |\macroparameter|
+% as a placeholder for an argument. The syntax is
+% \begin{quote}
+% |\macroparameter|\marg{digit}
+% \end{quote}
+% where \meta{digit} should be a decimal digit between |1| and |9|
+% inclusive.
+%
+% The definition in |\macroparameter| handles uses of the command in
+% integer expressions, whereas |\FD@printable\macroparameter| takes
+% care of uses in string expressions.
+% \begin{macrocode}
+\DeclareRobustCommand\macroparameter[1]{%
+ \gdef\FD@expression{\text{\normalfont\itshape\##1}}%
+ \global\chardef\FD@priority=5%
+ \global\FD@bracket@level=\z@
+ \FD@evaluate@false
+}
+\@namedef{FD@printable\string\macroparameter}#1{%
+ \toks@=\expandafter{\the\toks@\textrm{\emph{\##1}}}%
+ \@tempswatrue
+ \FD@printable@
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+%
+% \subsection{Integer expressions}
+%
+% An \meta{integer expression} is one of the following:
+% \begin{quote}
+% \meta{number}\\
+% |\int|\marg{string expression}\\
+% |\neg|\marg{integer expression}\\
+% |\add|\marg{integer expression}\marg{integer expression}\\
+% |\sub|\marg{integer expression}\marg{integer expression}\\
+% |\max|\marg{integer expression}\marg{integer expression}\\
+% |\min|\marg{integer expression}\marg{integer expression}\\
+% |\mul|\marg{integer expression}\marg{integer expression}\\
+% |\div|\marg{integer expression}\marg{integer expression}\\
+% |\half|\marg{integer expression}\\
+% |\otherhalf|\marg{integer expression}\\
+% |\scale|\marg{integer expression}\marg{integer expression}\\
+% |\width|\marg{string expression}\\
+% |\height|\marg{string expression}\\
+% |\depth|\marg{string expression}\\
+% |\italic|\marg{string expression}\\
+% |\kerning|\marg{string expression}\marg{string expression}
+% \end{quote}
+% \meta{number} is any \TeX\ number, as defined in~\cite{TeXbook}. The
+% \meta{string expression} in the argument of |\int| must be the name of
+% an integer variable which is currently set, i.e., the condition
+% \begin{quote}
+% |\ifisint|\marg{string expression}|\then|
+% \end{quote}
+% must evaluate to true. Likewise the \meta{string expression} in the
+% argument of |\width|, |\height|, |\depth|, and |\italic| must be the
+% name of a glyph which is currently set, i.e., the condition
+% \begin{quote}
+% |\ifisglyph|\marg{string expression}|\then|
+% \end{quote}
+% must evaluate to true.
+%
+% \begin{macro}{\eval_expr}
+% \begin{macro}{\eval_expr_to}
+% \begin{macro}{\g_eval_expr_to}
+% \begin{macro}{\result}
+% The only thing \package{fontinst} does with integer expressions is
+% evaluating them. The macro
+% \begin{quote}
+% |\eval_expr|\marg{integer expression}
+% \end{quote}
+% globally assigns |\result| to the value of
+% \meta{integer expression}, and changes the value of no other
+% counters.
+%
+% The macro
+% \begin{quote}
+% |\eval_expr_to|\marg{\TeX\ integer variable}^^A
+% \marg{integer expression}
+% \end{quote}
+% locally assigns the value of \meta{integer expression} to
+% \meta{\TeX\ integer variable} (which is an integer variable as
+% defined in~\cite{TeXbook}).
+% |\g_eval_expr_to| does the same globally.
+%
+% \begin{macrocode}
+%<*pkg>
+\newcount\result
+\def\eval_expr#1{\global\result=#1\x_relax}
+\def\eval_expr_to#1#2{\eval_expr{#2}#1=\result}
+\def\g_eval_expr_to#1#2{\eval_expr{#2}\global#1=\result}
+%</pkg>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+%
+% \begin{macro}{\TypesetIntegerExpression}
+% In \package{fontdoc} the main task is instead to typeset the
+% expression as a mathematical formula, but in some cases one wants to
+% know its value as well (if possible). Therefore things get a bit
+% more complex in that context. The top-level command there is
+% \begin{quote}
+% |\TypesetIntegerExpression|\marg{integer expression}
+% \end{quote}
+% which typesets the \meta{integer expression} by first forming (in the
+% |\FD@expression| macro) code for typesetting the integer expression.
+% |\Typeset|\-|Integer|\-|Expression| should be only be used in math
+% mode.
+%
+% Most of the work in |\TypesetIntegerExpression| is carried out by
+% the |\FD@eval@expr| macro and hence |\TypesetIntegerExpression| sets
+% a couple of other variables as explained below. Apart from the fact
+% that |\FD@eval@expr| doesn't actually typeset anything, the main
+% difference between it and |\Typeset|\-|Integer|\-|Expression| is that
+% the latter also accepts code that after expansion will become integer
+% expressions, whereas the former requires that all such macros have
+% first been expanded.
+% \begin{macrocode}
+%<*doc>
+\newcommand\TypesetIntegerExpression[1]{%
+ \protected@edef\@tempa{#1}%
+ \expandafter\FD@eval@expr \expandafter{\@tempa}%
+ \FD@expression
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\FD@expression}
+% \begin{macro}{\FD@result}
+% \begin{macro}{\FD@priority}
+% \begin{macro}{\FD@bracket@level}
+% \begin{switch}{FD@evaluate@}
+% The |\FD@expression| macro, |\FD@result| and |\FD@bracket@level|
+% count registers, the |\FD@priority| chardef token, and the
+% |FD@evaluate@| switch are used by \package{fontdoc} when formatting
+% and evaluating an integer expression. They are all assigned globally.
+%
+% The |\FD@expression| macro contains code for typesetting an
+% expression. |\FD@priority| is a chardef token whose numerical value
+% specifies the priority of the outermost operation in
+% |\FD@expression| according to the following table:
+% \begin{enumerate}
+% \item[0]
+% Outermost operation is $+$ or $-$.
+% \item[1]
+% Outermost operation is explicit multiplication ($\cdot$) or
+% division $/$. If it is one of the factors in a product then
+% that multiplication must be explicit.
+% \item[2]
+% Outermost operation is explicit multiplication. If it is to be
+% the right factor in a product, then the multiplication must be
+% made explicit too.
+% \item[3]
+% Outermost operation is explicit multiplication. It
+% does not need to be explicitly multiplied.
+% \item[4]
+% Outermost operation is implicit multiplication (juxtaposition),
+% unary prefix (unary $-$) or something which is bracketed anyway.
+% If it is to be the right factor in a product, then that
+% multiplication should be made explicit too. A typical example
+% of this kind of thing is an explicit negative number.
+% \item[5]
+% Outermost operation is implicit multiplication (juxtaposition)
+% or something which is bracketed anyway. It does not need to be
+% explicitly multiplied.
+% \item[6]
+% The expression is an explicit non-negative number. If it is to
+% be the right factor in a product, then the multiplication
+% should be made explicit.
+% \end{enumerate}
+% |\FD@bracket@level| keeps track of what parenthesis size one must
+% use to cover the expression in |\FD@expression|: 0 is the normal
+% size, 1 is |\big| size, 2 is |\Big| size, etc. The |FD@evaluate@|
+% switch specifies whether |\FD@eval@expr| should try to (upon entry)
+% or managed to (after it is completed) evaluate the integer
+% expression (true is evaluate, false is don't bother). When the value
+% has been evaluated, it is returned in |\FD@result|.
+% \begin{macrocode}
+\newcount\FD@result
+\newcount\FD@bracket@level
+\def\FD@evaluate@true{\global\let\ifFD@evaluate@\iftrue}
+\def\FD@evaluate@false{\global\let\ifFD@evaluate@\iffalse}
+\FD@evaluate@false
+% \end{macrocode}
+% \end{switch}\end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\FD@eval@expr}
+% The |\FD@eval@expr| macro has the syntax
+% \begin{quote}
+% |\FD@eval@expr|\marg{integer expression}
+% \end{quote}
+% It puts code for typesetting the \meta{integer expression} in the
+% |\FD@expression| macro, sets |\FD@bracket@level| to the
+% corresponding value, and if |FD@evaluate@| is true it also tries to
+% evaluate the expression and put the result in |\FD@result|.
+%
+% More precisely, |\FD@eval@expr| only handles the \meta{\TeX~number}
+% cases of integer expression. In the other cases the first token in
+% the integer expression is a robust command which should take care of
+% building the expression as needed.
+% \begin{macrocode}
+\def\FD@eval@expr#1{%
+ \expandafter\expandafter \expandafter\ifx
+ \expandafter\@car#1\x@relax\@nil \protect
+ #1%
+ \else\ifcat \expandafter\noexpand \@car#1\x@relax\@nil 0%
+ \global\FD@result=#1\x@relax
+ \xdef\FD@expression{\the\FD@result}%
+ \global\chardef\FD@priority=\ifnum \FD@result<\z@ 4\else 6\fi
+ \global\FD@bracket@level=\z@
+ \else
+ \begingroup
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \global\FD@bracket@level=\ifFD@swa\z@\else\@ne\fi
+ \protected@xdef\FD@expression{\protect\mbox{\texttt{\@tempa}}}%
+ \endgroup
+ \global\chardef\FD@priority=5%
+ \FD@evaluate@false
+ \fi\fi
+}
+%</doc>
+% \end{macrocode}
+% Note: It is important that all groups that are started or ended
+% during the evaluation of an integer expression are of |\begingroup|
+% type, since |\bgroup| groups affect spacing in math mode.
+% \end{macro}
+%
+% \begin{macro}{\add}
+% The |\add| command has the syntax
+% \begin{quote}
+% |\add|\marg{integer expression}\marg{integer expression}
+% \end{quote}
+% It represents the sum of the two \meta{integer expression}s.
+% \begin{macrocode}
+%<*pkg>
+\def\add#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\advance \result \a_count
+ \egroup
+}
+%</pkg>
+%<*doc>
+\DeclareRobustCommand\add[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \FD@eval@expr{#2}%
+ \protected@xdef\FD@expression{\@tempa+\FD@expression}%
+ \ifFD@evaluate@ \global\advance \FD@result \a@count \fi
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \global\chardef\FD@priority=\z@
+ \endgroup
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\sub}
+% The |\sub| command has the syntax
+% \begin{quote}
+% |\sub|\marg{integer expression}\marg{integer expression}
+% \end{quote}
+% It represents the difference between the two \meta{integer
+% expression}s.
+% \begin{macrocode}
+%<*pkg>
+\def\sub#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \advance \a_count -\result
+ \global\result=\a_count
+ \egroup
+}
+%</pkg>
+%<*doc>
+\DeclareRobustCommand\sub[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \FD@eval@expr{#2}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \protected@xdef\FD@expression{\@tempa-\FD@expression}%
+ \ifFD@evaluate@
+ \advance \a@count -\FD@result
+ \global\FD@result=\a@count
+ \fi
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \global\chardef\FD@priority=\z@
+ \endgroup
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\FD@subexpression}
+% \begin{macro}{\FD@commapenalty}
+% The |\FD@subexpression| macro has the syntax
+% \begin{quote}
+% |\FD@subexpression|\marg{math mode material}
+% \end{quote}
+% It should only be used in math mode and produces results very
+% similar to \meta{math mode material}, but it locally increases all
+% the math-related penalties by |\FD@commapenalty| for when the math
+% mode material is converted to a horizontal list. This allows
+% linebreaking to take notice of logical nesting in expressions.
+%
+% |\FD@commapenalty| is used as a companion of |\relpenalty| and
+% |\binoppenalty|, but which is used after commas (where \TeX\ doesn't
+% insert penalties automatically).
+% \begin{macrocode}
+\def\FD@subexpression#1{${%
+ \advance \binoppenalty \FD@commapenalty
+ \advance \relpenalty \FD@commapenalty
+ \advance \FD@commapenalty \FD@commapenalty
+ $#1$}$%
+}
+\newcount\FD@commapenalty
+\FD@commapenalty=\binoppenalty
+\advance \FD@commapenalty \relpenalty
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\FD@bracket@expression}
+% The |\FD@bracket@expression| brackets the expression currently in
+% |\FD@expression| by the suitable size of parentheses and updates
+% |\FD@bracket@level| and |\FD@priority| accordingly.
+% \begin{macrocode}
+\def\FD@bracket@expression{%
+ \protected@xdef\FD@expression{%
+ \ifcase\FD@bracket@level \or \protect\bigl \or \protect\Bigl \or
+ \protect\biggl \else \protect\Biggl \fi (%
+ \protect\FD@subexpression{\FD@expression}%
+ \ifcase\FD@bracket@level \or \protect\bigr \or \protect\Bigr \or
+ \protect\biggr \else \protect\Biggr \fi )%
+ }%
+ \global\chardef\FD@priority=5%
+ \global\advance \FD@bracket@level \@ne
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\int}
+% \changes{1.909}{1999/10/19}{\package{fontdoc} implementation
+% changed to using \cs{typeset@integer}. (LH)}
+% \begin{macro}{\FD@simple@int}
+% The |\int| command has the syntax
+% \begin{quote}
+% |\int|\marg{string expression}
+% \end{quote}
+% It is used to represent the value of the \package{fontinst} integer
+% whose name is the value of the \meta{string expression} in integer
+% expressions.
+%
+% The |\FD@simple@int| macro take the printable string form of the
+% name of an integer variable as its argument and typesets the
+% printed representation of this integer, but it should only be used
+% when the argument is a simple string expression. When the argument
+% is not a simple string expression, |\FD@integer@func| should be
+% used instead. |\FD@simple@int| should only be called in horizontal
+% mode.
+% \begin{macrocode}
+%<pkg>\def\int#1{\csname i-#1 \endcsname}
+%<*doc>
+\DeclareRobustCommand\int[1]{%
+ \begingroup
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \protected@xdef\FD@expression{%
+ \ifFD@swa
+ \text{\protect\FD@simple@int{\@tempa}}%
+ \else
+ \protect\FD@integer@func{int}{\@tempa}%
+ \fi
+ }%
+ \global\chardef\FD@priority=5%
+ \global\FD@bracket@level=\ifFD@swa\z@\else\@ne\fi
+ \FD@evaluate@false
+ \endgroup
+}
+\def\FD@simple@int#1{{\normalfont\itshape #1\/}}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\FD@integer@func}
+% The |\FD@integer@func| macro has the syntax
+% \begin{quote}
+% |\FD@integer@func|\marg{name}\marg{argument}
+% \end{quote}
+% It is used for typesetting the \meta{name}$($\meta{argument}$)$
+% of an integer-valued function which takes a string expression as
+% argument (e.g.\ the width-of-glyph function $\mathrm{w}$). It
+% should only be used in math mode.
+%
+% The empty group in the argument of |\mathop| is there to ensure
+% that the nucleus of the mathop atom isn't simply a symbol, since
+% \TeX\ in that case centers it vertically.
+% \begin{macrocode}
+\def\FD@integer@func#1#2{%
+ \mathop{\mathrm{#1}{}}(\text{\FD@typeset@string{#2}})%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\neg}
+% The |\neg| command has the syntax
+% \begin{quote}
+% |\neg|\marg{integer expression}
+% \end{quote}
+% It represents the negative of the \meta{integer expression}.
+% \begin{macrocode}
+%<pkg>\def\neg#1{#1 \global\result=-\result}
+%<*doc>
+\DeclareRobustCommand\neg[1]{%
+ \FD@eval@expr{#1}%
+ \ifnum 5>\FD@priority \FD@bracket@expression \fi
+ \protected@xdef\FD@expression{-\FD@expression}%
+ \global\chardef\FD@priority=4%
+ \ifFD@evaluate@ \global\FD@result=-\FD@result \fi
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\mul}
+% The |\mul| command has the syntax
+% \begin{quote}
+% |\mul|\marg{integer expression}\marg{integer expression}
+% \end{quote}
+% It represents the product of the two \meta{integer expression}s.
+% \begin{macrocode}
+%<*pkg>
+\def\mul#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \egroup
+}
+%</pkg>
+% \end{macrocode}
+%
+% The main problem in the \package{fontdoc} definition of |\mul| is
+% to determine whether the multiplication should be made explicit or
+% not, and what priority code the resulting expression should be
+% given. It turns out that if the right factor has priority 1 (it is
+% a quotient or a product that ends with a quotient) then the
+% combined expression will be too, whereas if it isn't but the left
+% factor has priority 1 then the combined expression will get
+% priority 2. The remaining cases will be explicit or implicit
+% depending on the parity of the priority of the right expression, and
+% priority will be odd or even depending on the parity of the priority
+% of the left expression.
+% \begin{macrocode}
+%<*doc>
+\DeclareRobustCommand\mul[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \let\FD@left@priority=\FD@priority
+ \FD@eval@expr{#2}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \protected@xdef\FD@expression{%
+ \@tempa
+ \if \ifnum \FD@left@priority=\@ne e%
+ \else\ifnum \FD@priority<\thr@@ e%
+ \else\ifodd \FD@priority i\else e\fi\fi\fi e%
+ \cdot
+ \fi
+ \FD@expression
+ }%
+ \ifFD@evaluate@ \global\multiply \FD@result \a@count \fi
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \a@count=%
+ \ifnum \FD@priority=\@ne 1%
+ \else\ifnum \FD@left@priority=\@ne 2%
+ \else\ifodd\FD@left@priority
+ \ifodd\FD@priority 5\else 3\fi
+ \else
+ \ifodd\FD@priority 4\else 2\fi
+ \fi\fi\fi
+ \global\chardef\FD@priority=\a@count
+ \endgroup
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\div}
+% The |\div| command has the syntax
+% \begin{quote}
+% |\div|\marg{integer expression}\marg{integer expression}
+% \end{quote}
+% It represents the quotient of the two \meta{integer expression}s, as
+% computed by \TeX's |\divide| command: non-integer quotients are
+% rounded towards zero.
+% \begin{macrocode}
+%<*pkg>
+\def\div#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \divide \a_count \result
+ \global\result=\a_count
+ \egroup
+}
+%</pkg>
+%<*doc>
+\DeclareRobustCommand\div[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \FD@eval@expr{#2}%
+ \ifnum 4>\FD@priority \FD@bracket@expression \fi
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \protected@xdef\FD@expression{%
+ \@tempa
+ \ifcase\FD@bracket@level \or \protect\big \or \protect\Big \or
+ \protect\bigg \else \protect\Bigg \fi /%
+ \FD@expression
+ }%
+ \ifFD@evaluate@
+ \divide \a@count \FD@result
+ \global\FD@result=\a@count
+ \fi
+ \global\chardef\FD@priority=\@ne
+ \endgroup
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\FD@eval@spec@expr}
+% The |\FD@eval@spec@expr| macro has the syntax
+% \begin{isyntax}
+% |\FD@eval@spec@expr|\marg{integer expression}^^A
+% \discretionary{}{}{}\marg{spec-command}^^A
+% \discretionary{}{}{}\marg{rep-command}
+% \end{isyntax}
+% It does pretty much the same thing as |\FD@eval@expr|, but if the
+% first token in the \meta{integer expression} is the
+% \meta{spec-command} then it will do
+% \begin{quote}
+% \meta{rep-command}\meta{integer expression}
+% \end{quote}
+% instead of the normal activities. This is useful for operations that
+% are normally denoted as $n$-ary operations rather that binary ones,
+% i.e., for |\max| and |\min|.
+% \begin{macrocode}
+\def\FD@eval@spec@expr#1#2#3{%
+ \expandafter\ifx \@car#1\x@relax\@nil #2%
+ #3#1%
+ \else
+ \FD@eval@expr{#1}%
+ \fi
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\max}
+% The |\max| command has the syntax
+% \begin{quote}
+% |\max|\marg{integer expression}\marg{integer expression}
+% \end{quote}
+% It represents the maximum of the two \meta{integer expression}s.
+% \begin{macrocode}
+%<*pkg>
+\def\max#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count>\result \global\result=\a_count \fi
+ \egroup
+}
+%</pkg>
+%<*doc>
+\DeclareRobustCommand\max[2]{%
+ \begingroup
+ \toks@={}%
+ \a@count=-\maxdimen
+ \b@count=\z@
+ \FD@eval@spec@expr{\max{#1}{#2}}{\max}{\FD@maxmin@comma}%
+ \ifnum \a@count>\FD@bracket@level
+ \global\FD@bracket@level=\a@count
+ \fi
+ \protected@xdef\FD@expression{%
+ \protect\plainmax
+ \ifcase\FD@bracket@level \protect\@firstofone \or \protect\bigl
+ \or \protect\Bigl \or \protect\biggl \else \protect\Biggl
+ \fi{\{}%
+ \the\toks@
+ \protect\FD@subexpression{\FD@expression}%
+ \ifcase\FD@bracket@level \protect\@firstofone \or \protect\bigl
+ \or \protect\Bigl \or \protect\biggl \else \protect\Biggl
+ \fi{\}}%
+ }%
+ \ifFD@evaluate@
+ \ifnum \a@count>\FD@result \global\FD@result=\a@count \fi
+ \fi
+ \global\chardef\FD@priority=5%
+ \global\advance \FD@bracket@level \@ne
+ \endgroup
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\min}
+% The |\min| command has the syntax
+% \begin{quote}
+% |\min|\marg{integer expression}\marg{integer expression}
+% \end{quote}
+% It represents the minimum of the two \meta{integer expression}s.
+% \begin{macrocode}
+%<*pkg>
+\def\min#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \ifnum \a_count<\result \global\result=\a_count \fi
+ \egroup
+}
+%</pkg>
+%<*doc>
+\DeclareRobustCommand\min[2]{%
+ \begingroup
+ \toks@={}%
+ \a@count=\maxdimen
+ \b@count=\z@
+ \FD@eval@spec@expr{\min{#1}{#2}}{\min}{\FD@maxmin@comma}%
+ \ifnum \a@count>\FD@bracket@level
+ \global\FD@bracket@level=\a@count
+ \fi
+ \protected@xdef\FD@expression{%
+ \protect\plainmin
+ \ifcase\FD@bracket@level \protect\@firstofone \or \protect\bigl
+ \or \protect\Bigl \or \protect\biggl \else \protect\Biggl
+ \fi{\{}%
+ \the\toks@
+ \protect\FD@subexpression{\FD@expression}%
+ \ifcase\FD@bracket@level \protect\@firstofone \or \protect\bigl
+ \or \protect\Bigl \or \protect\biggl \else \protect\Biggl
+ \fi{\}}%
+ }%
+ \ifFD@evaluate@
+ \ifnum \a@count<\FD@result \global\FD@result=\a@count \fi
+ \fi
+ \global\chardef\FD@priority=5%
+ \global\advance \FD@bracket@level \@ne
+ \endgroup
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\FD@maxmin@comma}
+% The |\FD@maxmin@comma| macro does most of the work for |\max| and
+% |\min| in \package{fontdoc}. In some sense it inserts the commas
+% between the operands, but it also takes care of evaluating the
+% maximum\slash minimum and determining the proper bracketing level.
+%
+% The sequence of arguments (separated by commas) is compiled in
+% |\toks@|. The greatest\slash least value of an argument found so
+% far is kept in |\a@count|, and the greatest bracketing level found
+% is kept in |\b@count|.
+% \begin{macrocode}
+\def\FD@maxmin@comma#1#2#3{%
+ \FD@eval@spec@expr{#2}{#1}{\FD@maxmin@comma}%
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\protect \expandafter\FD@subexpression
+ \expandafter{\FD@expression}%
+ ,\penalty\FD@commapenalty\,%
+ }
+ \ifFD@evaluate@
+ \ifnum \a@count \ifx\max#1<\else>\fi \FD@result
+ \a@count=\FD@result
+ \fi
+ \fi
+ \ifnum \b@count<\FD@bracket@level \b@count=\FD@bracket@level \fi
+ \FD@eval@spec@expr{#3}{#1}{\FD@maxmin@comma}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\half}
+% \begin{macro}{\otherhalf}
+% \multchanges{\cs{half}\cs{otherhalf}}{1.916}{2000/12/31}{Macros
+% added. (LH)}
+% The |\half| and |\otherhalf| macros have the syntaxes
+% \begin{quote}
+% |\half|\marg{integer expression}\\
+% |\otherhalf|\marg{integer expression}
+% \end{quote}
+% They both represent one half of the \meta{integer expression}, but
+% they don't round it the same way. |\half| does rounding as
+% specified in~\cite[p.~237]{TAOCP2} (towards even integers) whereas
+% |\otherhalf| does it the other way (towards odd integers). This
+% means that
+% \begin{quote}
+% |\add{\half{|\meta{IE}|}}{\otherhalf{|\meta{IE}|}}|
+% \end{quote}
+% will always sum up to precisely the same as the \meta{IE} integer
+% expression.
+% \begin{macrocode}
+%<*pkg>
+\def\half#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+\def\otherhalf#1{
+ #1\x_relax
+ \ifodd\result
+ \global\advance \result \@ne
+ \global\divide \result \tw@
+ \ifodd\result \else \global\advance \result \m@ne \fi
+ \else
+ \global\divide \result \tw@
+ \fi
+}
+%</pkg>
+%<*doc>
+\DeclareRobustCommand\half[1]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \a@count=%
+ \ifnum \FD@priority=\@ne 1%
+ \else\ifodd\FD@priority 5%
+ \else 3\fi\fi
+ \global\chardef\FD@priority=\a@count
+ \protected@xdef\FD@expression{%
+ \protect\frac{1}{2}%
+ \ifnum \FD@priority>\thr@@ \else \cdot \fi
+ \FD@expression
+ }%
+ \ifFD@evaluate@
+ \ifodd \FD@result
+ \global\advance \FD@result \@ne
+ \global\divide \FD@result \tw@
+ \ifodd\FD@result \global\advance \FD@result \m@ne \fi
+ \else
+ \global\divide \FD@result \tw@
+ \fi
+ \fi
+ \endgroup
+}
+\DeclareRobustCommand\otherhalf[1]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \a@count=%
+ \ifnum \FD@priority=\@ne 1%
+ \else\ifodd\FD@priority 5%
+ \else 3\fi\fi
+ \global\chardef\FD@priority=\a@count
+ \protected@xdef\FD@expression{%
+ \protect\frac{1}{2}%
+ \ifnum \FD@priority>\thr@@ \else \cdot \fi
+ \FD@expression
+ }%
+ \ifFD@evaluate@
+ \ifodd \FD@result
+ \global\advance \FD@result \@ne
+ \global\divide \FD@result \tw@
+ \ifodd\FD@result\else \global\advance \FD@result \m@ne \fi
+ \else
+ \global\divide \FD@result \tw@
+ \fi
+ \fi
+ \endgroup
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\scale}
+% The |\scale| command has the syntax
+% \begin{quote}
+% |\scale|\marg{integer expression}\marg{integer expression}
+% \end{quote}
+% It represents the result of multiplying the first \meta{integer
+% expression} by as many thousands as is specified by the second
+% \meta{integer expression}. In practice, |\scale|\marg{ie1}\marg{ie2}
+% is very similar to
+% \begin{quote}
+% |\div{\mul|\marg{ie1}\marg{ie2}|}{1000}|
+% \end{quote}
+% but |\scale| also tries to do proper rounding (note however that
+% |\scale|ing by 500 is not rounded properly; use |\half| instead).
+% \begin{macrocode}
+%<*pkg>
+\def\scale#1#2{
+ #1
+ \bgroup
+ \a_count=\result
+ \eval_expr{#2}
+ \global\multiply \result \a_count
+ \rounded_thousandths
+ \egroup
+}
+%</pkg>
+% \end{macrocode}
+%
+% The second (scaling factor) argument of |\scale| is usually very
+% simple, and in that case the |\scale| will be formatted as a
+% fraction (containing the second argument) multiplied by the first
+% argument.
+% \begin{macrocode}
+%<*doc>
+\DeclareRobustCommand\scale[2]{%
+ \begingroup
+ \FD@eval@expr{#1}%
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \let\@tempa=\FD@expression
+ \ifFD@evaluate@ \a@count=\FD@result \fi
+ \b@count=\FD@bracket@level
+ \let\FD@left@priority=\FD@priority
+ \FD@eval@expr{#2}%
+ \if \ifnum \FD@bracket@level<\@ne \ifnum \FD@priority>\thr@@
+ 1\else 0\fi\else 0\fi 1%
+ \protected@xdef\FD@expression{%
+ \protect\frac{\FD@expression}{1000}%
+ \if \ifnum \FD@left@priority<\thr@@ e\else
+ \ifodd \FD@left@priority i\else e\fi\fi e%
+ \cdot
+ \fi
+ \@tempa
+ }
+ \global\chardef\FD@priority=%
+ \ifnum \FD@left@priority=\@ne 1\else
+ \ifodd\FD@left@priority 5\else 3\fi\fi
+ \global\FD@bracket@level=\b@count
+ \else
+ \ifnum \FD@priority<\@ne \FD@bracket@expression \fi
+ \protected@xdef\FD@expression{%
+ \@tempa
+ \if \ifnum \FD@left@priority=\@ne e%
+ \else\ifnum \FD@priority<\thr@@ e%
+ \else\ifodd \FD@priority i\else e\fi\fi\fi e%
+ \cdot
+ \fi
+ \FD@expression
+ \ifcase\FD@bracket@level \or \protect\big \or \protect\Big
+ \or \protect\bigg \else \protect\Bigg \fi /1000%
+ }%
+ \ifnum \FD@bracket@level<\b@count
+ \global\FD@bracket@level=\b@count
+ \fi
+ \global\chardef\FD@priority=\@ne
+ \fi
+ \ifFD@evaluate@
+ \global\multiply \FD@result \a@count
+ \global\divide \FD@result 500
+ \ifodd \FD@result
+ \global\advance \FD@result \ifnum 0>\FD@result - \fi \@ne
+ \fi
+ \global\divide \FD@result \tw@
+ \fi
+ \endgroup
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\rounded_thousandths}
+% \changes{1.901}{1999/03/06}{Macro added. \cs{scale} changed to
+% use it. (LH)}
+% \begin{macro}{\l_rounded_thousandths}
+% The |\rounded_thousandths| macro divides |\result|
+% by 1000 and rounds the result to the nearest integer. This is
+% different from
+% \begin{quote}
+% |\global\divide \result \one_thousand|
+% \end{quote}
+% since the latter always rounds positive numbers downwards and
+% negative numbers upwards.
+%
+% |\l_rounded_thousandths| does the same thing, but to the register
+% passed as parameter \#1 and is assigned locally.
+% \changes{1.913}{2000/03/04}{Macro added. (LH)}
+% \begin{macrocode}
+%<*pkg>
+\def\rounded_thousandths{
+ \global\divide \result \five_hundred
+ \ifodd \result
+ \global\advance \result by \ifnum 0>\result - \fi 1
+ \fi
+ \global\divide \result \tw@
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\l_rounded_thousandths#1{
+ \divide #1 \five_hundred
+ \ifodd #1
+ \advance #1 by \ifnum 0>#1 - \fi\@ne
+ \fi
+ \divide #1 \tw@
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\l_inv_scale}
+% \changes{1.913}{2000/03/11}{Macro added. (LH)}
+% The |\l_inv_scale| takes two arguments: as \#1 a count register,
+% and as \#2 a \TeX\ number. |\l_inv_scale| scales \#1 by the inverse
+% of \#2, if the value in \#1 is $n$ and the value in \#2 is $m$ then
+% |\l_inv_scale| computes
+% $$
+% \left[ \frac{1000n}{m} \right] \mbox{,}
+% $$
+% where the brackets denote rounding to the nearest integer, and
+% assigns this number to \#1 locally.
+% \begin{macrocode}
+\def\l_inv_scale#1#2{
+ \multiply #1 \two_thousand
+ \divide #1 #2\x_relax
+ \ifodd#1 \advance #1 \ifnum 0>#1 - \fi\@ne \fi
+ \divide #1 \tw@
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \multchanges{\cs{priority}}{1.909}{1999/10/20}{Changed condition for
+% \cs{ifnum}, so that expressions with equal priority will not get
+% bracketed when nested. (LH)}
+% \multchanges{\cs{expression}\cs{priority}\cs{identity}^^A
+% \cs{bracket}}{1.916}{2001/01/01}{Macros removed. (LH)}
+%
+% \begin{macro}{\ifnumber}
+% \changes{1.900}{1999/02/15}{Command added. (LH)}
+% The call
+% \begin{quote}
+% |\ifnumber|\marg{integer expression}\meta{rel}^^A
+% \marg{integer expression}|\then|
+% \end{quote}
+% can be used to compare the two integer expressions. \meta{rel} may
+% be |<|, |=|, or |>|.
+% \begin{macrocode}
+\def\ifnumber#1#2#3\then{
+ \eval_expr_to\a_count{#1}
+ \eval_expr{#3}
+ \ifnum \a_count#2\result
+ \expandafter\if_true
+ \else
+ \expandafter\if_false
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+%
+% Like the other conditionals, |\ifnumber| is treated as being true by
+% \package{fontdoc}.
+% \begin{macrocode}
+%<*doc>
+\def\ifnumber#1#2#3\then{%
+ \FD@evaluate@false
+ \generic@if{%
+ $\TypesetIntegerExpression{#1}#2\TypesetIntegerExpression{#3}$%
+ }%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \subsection{Setting variables}
+% \label{Ssec:Variables}
+%
+% \meta{int}, \meta{str}, and \meta{dim} below are string expressions.
+% \meta{command} can be any control sequence.
+%
+% \DescribeMacro{\setint}
+% \DescribeMacro{\setstr}
+% \DescribeMacro{\setdim}
+% \DescribeMacro{\setcommand}
+% The macros:
+% \begin{quote}
+% |\setint|\marg{int}\marg{integer expression}\\
+% |\setstr|\marg{str}\marg{string}\\
+% |\setdim|\marg{dim}\marg{dimension}\\
+% |\setcommand|\meta{command}\meta{definition}
+% \end{quote}
+% define new macros
+% \describecsfamily{i-\meta{int}}|\i-|\meta{int},
+% \describecsfamily{s-\meta{str}}|\s-|\meta{str},
+% \describecsfamily{d-\meta{dim}}|\d-|\meta{dim}, or
+% \meta{command}.
+%
+% \DescribeMacro{\resetint}
+% \DescribeMacro{\resetstr}
+% \DescribeMacro{\resetdim}
+% \DescribeMacro{\resetcommand}
+% The macros:
+% \begin{quote}
+% |\resetint|\marg{int}\marg{integer expression}\\
+% |\resetstr|\marg{str}\marg{string}\\
+% |\resetdim|\marg{dim}\marg{dimension}\\
+% |\resetcommand|\meta{command}\meta{definition}
+% \end{quote}
+% redefine the macros |\i-|\meta{int}, |\s-|\meta{str}, |\d-|\meta{dim} or
+% \meta{command}.
+%
+% \DescribeMacro{\int}
+% \DescribeMacro{\str}
+% \DescribeMacro{\dim}
+% The macros:
+% \begin{quote}
+% |\int|\marg{int}\\
+% |\str|\marg{str}\\
+% |\dim|\marg{dim}\\
+% \meta{command}
+% \end{quote}
+% return the values of |\i-|\meta{int}, |\s-|\meta{str}, |\d-|\meta{dim},
+% or \meta{command}.
+%
+% \DescribeMacro{\strint}
+% The macro
+% \begin{quote}
+% |\strint|\marg{int}
+% \end{quote}
+% returns the value of |\i-|\meta{int} as a string.
+%
+% \DescribeMacro{\ifisint}
+% \DescribeMacro{\ifisstr}
+% \DescribeMacro{\ifisdim}
+% \DescribeMacro{\ifiscommand}
+% The macros:
+% \begin{quote}
+% |\ifisint|\marg{int}|\then|\\
+% |\ifisstr|\marg{str}|\then|\\
+% |\ifisdim|\marg{dim}|\then|\\
+% |\ifiscommand|\meta{command}|\then|
+% \end{quote}
+% return |\if_true| if |\i-|\meta{int}, |\s-|\meta{str},
+% |\d-|\meta{dim}, or \meta{command} respectively have been defined,
+% and |\if_false| otherwise.
+%
+% \DescribeMacro{\unsetint}
+% \DescribeMacro{\unsetstr}
+% \DescribeMacro{\unsetdim}
+% \DescribeMacro{\unsetcommand}
+% The macros:
+% \begin{quote}
+% |\unsetint|\marg{int}\\
+% |\unsetstr|\marg{str}\\
+% |\unsetdim|\marg{dim}\\
+% |\unsetcommand|\meta{command}
+% \end{quote}
+% undefine |\i-|\meta{int}, |\s-|\meta{str}, |\d-|\meta{dim}, or
+% \meta{command}.
+%
+% \DescribeMacro{\x_setint}
+% \DescribeMacro{\x_resetint}
+% \DescribeMacro{\x_setstr}
+% The macros |\x_setint|, |\x_resetint|, and |\x_setstr| are ``private''
+% versions of |\setint|, |\resetint|, and |\setstr| respectively. They
+% have been included to reduce the problems in case a user turns off one
+% of these commands and forgets to turn it on again.
+%
+% \changes{1.900}{1999/02/07}{Replaced internal \cs{setint},
+% \cs{resetint}, and \cs{setstr} by \cs{x_setint}, \cs{x_resetint},
+% and \cs{x_setstr} respectively, to make the public versions
+% possible to turn off. (LH)}
+%
+% Integers are kept as |\mathchardef|s if possible; a comparision of
+% doing this versus not doing this appears in
+% Subsection~\ref{Ssec: ASAJ tests}.
+%
+% \begin{macro}{\setsomething_global}
+% The |\setsomething_global| control sequence should be either
+% |\relax| or |\global|. It appears before the central assignments in
+% all the |\set|\textellipsis, |\reset|\textellipsis, and
+% |\unset|\textellipsis\ commands. The normal value is |\relax|, so
+% that these assignments are local.
+%
+% When there is counter-intuitive grouping, and it could seem that
+% \TeX\ should not be inside a group at all---i.e., between
+% |\installfonts| and |\endinstallfonts|---one can make the basic
+% assignment commands act more logical by setting
+% |\setsomething_global| to |\global|.
+%
+% \changes{1.912}{2000/01/15}{Control sequence introduced and added
+% to all \cs{set}\dots, \cs{reset}\dots, and \cs{unset}\dots\
+% commands, as well as \cs{offcommand} and \cs{oncommand}. (LH)}
+% \begin{macrocode}
+%<*pkg>
+\let\setsomething_global=\x_relax
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\x_setint}
+% \begin{macro}{\setint}
+% \begin{macro}{\x_setstr}
+% \begin{macro}{\setstr}
+% \begin{macro}{\setdim}
+% \begin{macro}{\setcommand}
+% \changes{1.909}{1999/10/17}{Since \package{fontdoc} adds some
+% grouping, \cs{setcommand} must set its argument globally there.
+% (LH)}
+% \changes{1.912}{2000/01/15}{Settings of a command already defined
+% is diverted to \cs{a_macro}; it used to be \cs{a_command}. Saves
+% one hash table position. (LH)}
+%
+% \begin{macrocode}
+\def\x_setint#1#2{
+ \x_cs\ifx{i-#1}\x_relax
+ \x_resetint{#1}{#2}
+ \fi
+}
+\let\setint=\x_setint
+\def\x_setstr#1#2{
+ \x_cs\ifx{s-#1}\x_relax
+ \setsomething_global\x_cs\edef{s-#1}{#2}
+ \fi
+}
+\let\setstr=\x_setstr
+\def\setdim#1#2{
+ \x_cs\ifx{d-#1}\x_relax
+ \a_dimen=#2\x_relax
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+ \fi
+}
+\def\setcommand#1{
+ \ifx#1\undefined_command
+ \setsomething_global \expandafter\def \expandafter#1
+ \else
+ \expandafter\def \expandafter\a_macro
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+%
+% In \package{fontdoc}, |\setint|, |\setstr|, and |\setdim| print
+% headings. There is no need for the private forms |\x_setint| and
+% |\x_setstr|. |\setcommand|, finally, does the same thing as in
+% \package{fontinst}; the assignment is global because of grouping
+% not present in \package{fontinst}.
+% \begin{macrocode}
+%<*doc>
+\newcommand\setint[2]{%
+ \Bheading{Default} \(\TypesetIntegerExpression{\int{#1}}\) =
+ \(\TypesetIntegerExpression{#2}\)%
+}
+\newcommand\setstr[2]{%
+ \Bheading{Default} \TypesetStringExpression{\str{#1}} =
+ \TypesetStringExpression{#2}%
+}
+\newcommand\setdim[2]{%
+ \a@dimen=#2\relax
+ \Bheading{Default} \TypesetStringExpression{#1} dimen = \the\a@dimen
+}
+\def\setcommand#1{\ifx#1\undefined@command
+ \expandafter\gdef\expandafter#1\else
+ \expandafter\gdef\expandafter\a@command\fi}
+%</doc>
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\x_resetint}
+% \begin{macro}{\resetint}
+% \begin{macro}{\resetstr}
+% \begin{macro}{\resetdim}
+% \begin{macro}{\resetcommand}
+% \changes{1.909}{1999/10/17}{Since \package{fontdoc} adds some
+% grouping, \cs{resetcommand} must set its argument globally there.
+% (LH)}
+% \begin{macrocode}
+%<*pkg>
+\def\x_resetint#1#2{
+ \eval_expr{#2}
+ \setsomething_global
+ \ifnum\result<\max_mathchardef
+ \ifnum 0>\result
+ \x_cs\edef{i-#1}{\the\result}
+ \else
+ \x_cs\mathchardef{i-#1}=\result
+ \fi
+ \else
+ \x_cs\edef{i-#1}{\the\result}
+ \fi
+}
+\let\resetint=\x_resetint
+\def\resetstr#1#2{\setsomething_global\x_cs\edef{s-#1}{#2}}
+\def\resetdim#1#2{
+ \a_dimen=#2
+ \setsomething_global\x_cs\edef{d-#1}{\the\a_dimen}
+}
+\def\resetcommand#1{\setsomething_global\def#1}
+%</pkg>
+% \end{macrocode}
+%
+% In \package{fontdoc}, |\resetint|, |\resetstr|, and |\resetdim|
+% print headings. There is no need for the private form |\x_resetint|.
+% |\resetcommand|, finally, does the same thing as in
+% \package{fontinst}.
+%
+% \begin{macrocode}
+%<*doc>
+\newcommand\resetint[2]{%
+ \Bheading{Value} \(\TypesetIntegerExpression{\int{#1}}\) =
+ \(\TypesetIntegerExpression{#2}\)%
+}
+\newcommand\resetstr[2]{%
+ \Bheading{Value} \TypesetStringExpression{\str{#1}} =
+ \TypesetStringExpression{#2}%
+}
+\newcommand\resetdim[2]{%
+ \a@dimen=#2\relax
+ \Bheading{Value} \TypesetStringExpression{#1} dimen = \the\a@dimen
+}
+\def\resetcommand#1{\gdef#1}
+%</doc>
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\dim}
+% \begin{macrocode}
+%<pkg>\def\dim#1{\csname~d-#1\endcsname}
+% \end{macrocode}
+% \missing{doc}{\dim}
+% \end{macro}
+%
+% \multchanges{\cs{typeset@integer}\cs{typeset@string}^^A
+% \cs{typeset@dimen}}{1.916}{2000/01/02}{Macros removed. (LH)}
+%
+% \begin{macro}{\ifisint}
+% \begin{macro}{\ifisstr}
+% \begin{macro}{\ifisdim}
+% \multchanges{\cs{ifisint}\cs{ifisstr}\cs{ifisdim}}{1.912}
+% {2000/02/10}{Reimplemented using \cs{if_defined}. (LH)}
+% \begin{macro}{\ifiscommand}
+% \begin{macrocode}
+%<*pkg>
+\def\ifisint#1\then{\if_defined i-#1\then}
+\def\ifisstr#1\then{\if_defined s-#1\then}
+\def\ifisdim#1\then{\if_defined d-#1\then}
+\def\ifiscommand#1\then{
+ \ifx#1\undefined_command
+ \expandafter\if_false
+ \else
+ \expandafter\if_true
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+%
+% In \package{fontdoc}, all conditionals are handled through
+% |\generic@if|, which by default expands to |\iftrue|.
+% \changes{1.909}{1999/10/17}{Changed one fontdoc definition of
+% \cs{ifisglyph} to a definition of \cs{ifiscommand}, which was
+% missing from fontdoc.}
+% \begin{macrocode}
+%<*doc>
+\def\ifisint#1\then{%
+ \generic@if{integer $\TypesetIntegerExpression{\int{#1}}$ set}%
+}
+\def\ifisstr#1\then{%
+ \generic@if{string \TypesetStringExpression{#1} set}%
+}
+\def\ifisdim#1\then{%
+ \generic@if{dimension \TypesetStringExpression{#1} set}%
+}
+\def\ifiscommand#1\then{%
+ \generic@if{command \normalfont{\ttfamily\string#1} set}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\unsetint}
+% \begin{macro}{\unsetstr}
+% \begin{macro}{\unsetdim}
+% \begin{macro}{\unsetcommand}
+% \begin{macrocode}
+%<*pkg>
+\def\unsetint#1{\setsomething_global\x_cs\let{i-#1}\x_relax}
+\def\unsetstr#1{\setsomething_global\x_cs\let{s-#1}\x_relax}
+\def\unsetdim#1{\setsomething_global\x_cs\let{d-#1}\x_relax}
+\def\unsetcommand#1{\setsomething_global\let#1=\undefined_command}
+%</pkg>
+% \end{macrocode}
+% \missing{doc}{\unsetint}
+% \missing{doc}{\unsetstr}
+% \missing{doc}{\unsetdim}
+% \missing{doc}{\unsetcommand}
+% \begin{macrocode}
+%<*doc>
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\offcommand}
+% \begin{macro}{\oncommand}
+% \multchanges{\cs{offcommand}\cs{oncommand}}{1.900}{1999/02/07}
+% {Commands added. (LH)}
+% The calls
+% \begin{quote}
+% |\offcommand|\meta{command}\\
+% |\oncommand|\meta{command}
+% \end{quote}
+% can be used to turn a command off (make it simply absorb its
+% arguments but expand to nothing) or on (return it to normal)
+% respectively. Their primary use is for ignoring some of the
+% commands in \texttt{.mtx} files that \package{fontinst} generates
+% from \texttt{.afm}, \texttt{.pl}, or other \texttt{.mtx} files.
+%
+% \describecsfamily{saved-\meta{\textbackslash command}}
+% The normal definition of a command that has been turned off
+% is saved as the control sequence |\saved-|\meta{command}. If the
+% syntax of a command is tricky---not all arguments are read by the
+% base command or its parameter text contains tokens that are not
+% parameters---or if simply making it do nothing is not the expected
+% `off' behaviour, then the automatic off-turning may not work. In such
+% cases a handtooled off definition of the command \meta{command}
+% may be provided as the control sequence |\off-|\meta{command}.^^A
+% \describecsfamily{off-\meta{\textbackslash command}}
+%
+% Nothing happens if |\offcommand| is called for a command that is
+% not on. Nothing happens if |\oncommand| is called for a command
+% that is not off.
+% \begin{macrocode}
+%<*pkg>
+\def\offcommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax
+ \setsomething_global\x_cs\let{saved-\string#1}#1
+ \x_cs\ifx{off-\string#1}\x_relax
+ \generate_off_command{#1}
+ \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname off-\string#1\endcsname
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\oncommand#1{
+ \x_cs\ifx{saved-\string#1}\x_relax \else
+ \setsomething_global \expandafter\let \expandafter#1
+ \csname saved-\string#1\endcsname
+ \setsomething_global\x_cs\let{saved-\string#1}\x_relax
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \multchanges{\cs{offcommand}\cs{oncommand}}{1.914}{2000/05/28}
+% {\package{fontdoc} definitions added. (LH)}
+% \begin{macrocode}
+%<*doc>
+\def\offcommand#1{\Bheading{Turn off} \texttt{\string#1}}
+\def\oncommand#1{\Bheading{Turn on} \texttt{\string#1}}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\generate_off_command}
+% \begin{macro}{\count_hashes}
+% \begin{macro}{\gobble_to_xrelax}
+% |\generate_off_command|\meta{command} converts \meta{command} to
+% an ``off'' version of itself by counting the number of arguments
+% and defining it to gobble that many arguments. It cannot cope with
+% commands whose parameter texts are not simply of the type
+% \begin{quote}
+% |#1#2|\textellipsis|#|$n$
+% \end{quote}
+% \begin{macrocode}
+%<*pkg>
+\def\generate_off_command#1{
+ \a_count=0
+ \let\next=\count_hashes
+ \expandafter\next\meaning#1~->\x_relax
+ \b_count=0
+ \a_toks={}
+ \loop \ifnum \b_count<\a_count
+ \advance \b_count 1
+ \a_toks=\expandafter{\the\expandafter\a_toks \expandafter####
+ \the\b_count}
+ \repeat
+ \setsomething_global \expandafter\def \expandafter#1 \the\a_toks {}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\count_hashes#1#2{
+ \if \hash_char#1
+ \advance \a_count 1
+ \else
+ \if -#1
+ \if >#2
+ \let\next=\gobble_to_xrelax
+ \fi\fi
+ \fi
+ \next#2
+}
+\def\gobble_to_xrelax#1\x_relax{}
+%</pkg>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+%
+% Control sequences of the form
+% \begin{quote}
+% \describecsfamily{FD@s-\meta{name}}|\FD@s-|\meta{name}
+% \end{quote}
+% are used by \package{fontdoc} to store the values of string variables
+% which have been assigned values; \meta{name} is the name of the string
+% variable. Unlike the case in \package{fontinst}, the
+% \package{fontdoc} |\setstr| command does not assign values to string
+% variables, but |\SetStringVariable| does.
+%
+% The contents of the |\FD@s-|\meta{name} macros aren't really the
+% string values, but code that will append the printable form of the
+% corresponding string expression to |\toks@| and update other variables
+% used by |\MakePrintable| accordingly. Typically it might look
+% something like
+% \begin{quote}
+% |\toks@=\expandafter{\the\toks@ ab}|
+% \end{quote}
+% when the value of the string is |ab|.
+%
+% \begin{macro}{\SetStringVariable}
+% \changes{1.916}{2001/01/24}{Command added. (LH)}
+% The |\SetStringVariable| command has the syntax
+% \begin{quote}
+% |\SetStringVariable|\marg{variable name}\marg{new value}
+% \end{quote}
+% where \meta{variable name} and \meta{new value} are both string
+% expressions. The \meta{variable name} must furthermore be a simple
+% string expression. The command globally defines the corresponding
+% |\FD@s-|\meta{name} control sequence to add the printable form of
+% the \marg{new value} string to the |\toks@| token list register and,
+% in case the \meta{new value} string is non-simple, sets the |@tempswa|
+% switch to true.
+%
+% The control sequence |\@tempa| can be used as part of \meta{new
+% value}, but not in the \meta{variable name}.
+% \begin{macrocode}
+%<*doc>
+\newcommand\SetStringVariable[2]{%
+ \protected@edef\@tempa{\noexpand\MakePrintable \noexpand\@tempa
+ {FD@swa}{#2}}%
+ \@tempa
+ \protected@edef\@tempa{%
+ \toks@=\noexpand\expandafter{\noexpand\the \toks@ \@tempa}%
+ \ifFD@swa \noexpand\@tempswatrue \fi
+ }%
+ \protected@edef\@tempb{\noexpand\MakePrintable \noexpand\@tempb
+ {FD@swa}{#1}}%
+ \@tempb
+ \ifFD@swa
+ \begingroup
+ \let\PrintChar=\FD@quoted@PrintChar
+ \global\expandafter\let \csname FD@s-\@tempb\endcsname \@tempa
+ \endgroup
+ \else
+ \PackageError{fontdoc}{Names of string variables must be
+ simple\MessageBreak if they are to be assigned values}\@eha
+ \fi
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+%
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \subsection{For loops}
+%
+%
+% \begin{macro}{\for}
+% \begin{macro}{\endfor}
+% \multchanges{\cs{for}\cs{endfor}}{1.900}{1999/02/16}{Commands
+% added. (LH)}
+% The command sequence
+% \begin{quote}
+% |\for|\parg{name}\marg{start}\marg{stop}\marg{step}\\
+% \vadjust{}\quad\meta{body code}\\
+% |\endfor|\parg{name}
+% \end{quote}
+% will cause the \meta{body code} to be repeated some number of times.
+% How many depends on the values of \meta{start}, \meta{stop}, and
+% \meta{step}, which are integer expressions.
+%
+% As a precaution, the \meta{body code} is not allowed to contain any
+% empty lines (|\par| tokens). If you want to have the visual
+% separation (for sakes of legibility or otherwise), put a |%|
+% somewhere on the line---that makes it nonempty.
+%
+% \meta{name} is used as the name of an integer variable. This
+% variable gets reset to the value of \meta{start} before the first
+% repetition of \meta{body code}. After each repetition but the last,
+% it is incremented by \meta{step}. \meta{body code} gets repeated if
+% the value of \meta{name} has not gotten past that of \meta{stop}. To
+% get past means to be bigger if \meta{step} is positive and to be
+% smaller if \meta{step} is negative. In the case that \meta{step} is
+% zero, the entire construction above will be equivalent to
+% \begin{quote}
+% |\resetint|\marg{name}\marg{start}\\
+% \meta{body code}
+% \end{quote}
+%
+% |\for| \textellipsis\ |\endfor| constructions can be nested.
+% \meta{name} is used by |\for| to identify its matching |\endfor|, so
+% they need to be identical in |\for| and |\endfor|.
+%
+% \multchanges{\cs{for}\cs{for_i}\cs{foreach}}{1.914}{2000/05/21}
+% {\cs{setsomething_global} added to assignments of the
+% \cs{for-\meta{name}} and \cs{body-\meta{name}} control
+% sequences. (LH)}
+% \begin{macrocode}
+%<*pkg>
+\def\for(#1)#2#3#4{
+ \eval_expr_to\a_count{#2}
+ \x_resetint{#1}{\a_count}
+ \eval_expr{#4}
+ \ifnum 0=\result \else
+ \c_count=\result
+ \eval_expr_to\b_count{#3}
+ \setsomething_global\x_cs\edef{for-#1}{
+ \the\c_count \x_relax
+ \noexpand\ifnum \gobble_one\fi
+ \the\b_count \ifnum 0>\c_count > \else < \fi
+ }
+ \def\next##1##2##3\endfor(#1){##2\for_i{##1}{##3}}
+ \next{#1}
+ \fi
+}
+% \end{macrocode}
+%
+% The macro \describecsfamily{for-\meta{name}}|\for-|\meta{name}
+% will contain
+% \begin{quote}
+% \meta{step}|\x_relax\ifnum|\meta{stop}\meta{rel}
+% \end{quote}
+% \meta{step} is the value of the \meta{step} parameter of |\for|,
+% computed when the loop was entered and now expressed in digits.
+% \meta{stop} is likewise for the \meta{stop} parameter. \meta{rel}
+% is |>| or |<|, depending on whether \meta{step} is positive or
+% negative respectively. The reason for this curious definition will
+% be appearent in the light of the definition of |\for_ii|.
+%
+% |\for_i| is expanded in the context
+% \begin{quote}
+% |\for_i|\marg{name}\marg{body code}
+% \end{quote}
+% Also remember, when reading the definition below, that |\ifnum|
+% keeps on expanding tokens until it has found a
+% \begin{quote}
+% \meta{number}\meta{relation}\meta{number}
+% \end{quote}
+% structure. It is therefore possible to nest |\ifnum|s like this!
+%
+% \begin{macrocode}
+\def\for_i#1#2{
+ \setsomething_global\x_cs\def{body-#1}{#2}
+ \ifnum \b_count \ifnum0>\c_count >\else<\fi \a_count
+ \expandafter\gobble_two
+ \else
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+% \end{macrocode}
+%
+% The macro \describecsfamily{body-\meta{name}}|\body-|\meta{name}
+% expands to the \meta{body code}.
+%
+% |\for_ii| executes the following code:
+% \begin{quote}
+% |\a_count=\int|\marg{name}\\
+% |\advance \a_count |\meta{step}|\x_relax|\\
+% |\ifnum |\meta{stop}\meta{rel}|\a_count|\\
+% | \expandafter\gobble_two|\\
+% |\else|\\
+% | \resetint|\marg{name}|\a_count|\\
+% | \csname body-|\meta{name}| \expandafter\endcsname|\\
+% |\fi|\\
+% |\for_ii|\marg{name}
+% \end{quote}
+% \meta{step}, \meta{stop}, and \meta{rel} are in |\for-|\meta{name},
+% and since there only are two other tokens between \meta{step} and
+% \meta{rel} in the above, one might as well include them in
+% |\for-|\meta{name} as well. Doing that requires that a matching
+% hole---that will be filled in by |\for-|\meta{name}---is made in the
+% definition of |\for_ii| and that is the reason for its somewhat
+% curious definition.
+%
+% \begin{macrocode}
+\def\for_ii#1{
+ \a_count=\int{#1}
+ \advance \a_count \csname for-#1\endcsname \a_count
+ \expandafter\gobble_two
+ \else
+ \x_resetint{#1}\a_count
+ \csname body-#1 \expandafter\endcsname
+ \fi
+ \for_ii{#1}
+}
+% \end{macrocode}
+%
+% |\endfor| just gobbles its argument, so that the \meta{step}${}=0$
+% case will work right.
+%
+% \begin{macrocode}
+\def\endfor(#1){}
+%</pkg>
+% \end{macrocode}
+% \missing{doc}{\for}
+% \missing{doc}{\endfor}
+% \begin{macrocode}
+%<*doc>
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\foreach}
+% \changes{1.901}{1999/03/07}{Command added. (LH)}
+% \changes{1.916}{2001/01/24}{\package{fontdoc} definition added. (LH)}
+% \begin{macro}{\foreach_i}
+% The command sequence
+% \begin{quote}
+% |\foreach|\parg{name}\marg{csep-list}\\
+% \vadjust{}\quad\meta{body code}\\
+% |\endfor|\parg{name}
+% \end{quote}
+% will cause the \meta{body code} to be repeated one time for each item
+% in the \meta{csep-list}. \meta{csep-list} is a comma-separated list
+% of strings.
+%
+% As a precaution, the \meta{body code} is not allowed to contain any
+% empty lines (|\par| tokens). If you want to have the visual
+% separation (for sakes of legibility or otherwise), put a |%|
+% somewhere on the line---that makes it nonempty.
+%
+% \meta{name} is used as the name of a string variable. Before each
+% repetition of the \meta{body code}, this variable will get reset to
+% the next item in the \meta{csep-list}.
+%
+% |\foreach|\textellipsis\ |\endfor| constructions can be nested.
+% \meta{name} is used by |\foreach| to identify its matching |\endfor|,
+% so they need to be identical in |\foreach| and |\endfor|.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\foreach(#1)#2{
+ \def\next##1\endfor(#1){
+ \setsomething_global\x_cs\def{body-#1}{##1}
+ \process_csep_list{\foreach_i{#1}}#2,\process_csep_list,
+ }
+ \next
+}
+\def\foreach_i#1#2{
+ \resetstr{#1}{#2}
+ \csname body-#1\endcsname
+}
+%</pkg>
+%<*doc>
+\def\foreach(#1)#2{%
+ \def\next##1\endfor(#1){%
+ \@for\@tempa:=#2\do{%
+ \SetStringVariable{#1}{\@tempa}%
+ ##1%
+ }%
+ }%
+ \next
+}
+%</doc>
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+%
+% \subsection{Comments}
+%
+% \changes{1.911}{1999/11/30}{Comment commands included in
+% \texttt{finstmsc.sty}. (LH)}
+%
+% \begin{macro}{\comment}
+% In \package{fontinst}, |\comment| simply gobbles its argument.
+% \begin{macrocode}
+%<pkg>\let\comment=\gobble_one
+% \end{macrocode}
+%
+% In \package{fontdoc}, |\comment| starts a new text paragraph and
+% leaves the argument to be typeset. Note that the argument group
+% thus survives; some commands make use of this fact.
+% \begin{macrocode}
+%<*doc>
+\def\comment{\par\noindent}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\begincomment}
+% \changes{1.900}{1999/02/07}{Command added. (LH)}
+% \begin{macro}{\endcomment}
+% \changes{1.900}{1999/02/07}{Command added. (LH)}
+% Since |\comment| cannot be used for a comment longer than one
+% paragraph, we also provide the means of introducing longer comments,
+% by writing
+% \begin{quote}
+% |\begincomment| \meta{any amount of text} |\endcomment|
+% \end{quote}
+% The names are admittedly not nice from a \LaTeX\ point of view, but
+% it is hardly worth the cost to implement some kind of environment
+% processing in \package{fontinst}, just for the sake of this command.
+% \begin{macrocode}
+%<pkg>\let\begincomment=\iffalse
+%<doc>\let\begincomment=\iftrue
+%<pkg|doc>\let\endcomment=\fi
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+% \Finale
+%
+\endinput
diff --git a/fonts/utilities/fontinst/source/ficonv.dtx b/fonts/utilities/fontinst/source/ficonv.dtx
new file mode 100644
index 0000000000..4281142ea1
--- /dev/null
+++ b/fonts/utilities/fontinst/source/ficonv.dtx
@@ -0,0 +1,3169 @@
+% \CheckSum{2502}
+% \iffalse meta-comment
+%
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999, 2000 the fontinst maintenance team and any
+% individual authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.1 or, at your option, any later version.
+%
+%%% From file: ficonv.dtx
+%
+%<*driver>
+\documentclass{ltxdoc}
+\usepackage{fisource}
+\title{The \package{fontinst} utility}
+\author{Alan Jeffrey, Sebastian Rahtz, Ulrik Vieth, Lars Hellstr\"om}
+\begin{document}
+\maketitle
+\tableofcontents
+\DocInput{ficonv.dtx}
+\end{document}
+%</driver>
+% \fi
+%
+% \StopEventually{}
+%
+% \section{Basic file format conversions}
+% \label{Sec:Conv. input}
+% \changes{1.902}{1999/05/01}{Collected the material in Section
+% \thesection\space and moved it to \texttt{ficonv.dtx}. (LH)}
+% \changes{1.926}{2003/07/12}{Added some missing \textasciitilde's
+% at ends of lines. (LH)}
+%
+% \subsection{Converting an ENC file to an ETX file}
+%
+% \DescribeMacro{\enctoetx}
+% The macro
+% \begin{quote}
+% |\enctoetx|\marg{encfile}\marg{etxfile}
+% \end{quote}
+% reads \meta{encfile}|.enc| and writes the same information to
+% \meta{etxfile}|.etx|, in a format \TeX{} can read more easily.
+%
+%
+% \begin{macrocode}
+%<*misc>
+\newif\ifmissingslots
+\x_cs\def{o-.notdef}#1{\global\missingslotstrue}
+% \end{macrocode}
+%
+% \begin{macro}{\enctoetx}
+% For every |/|\meta{glyph} command, the command |\o-|\meta{glyph}
+% gets passed code which writes the corresponding
+% |\setslot|\marg{glyph} \textellipsis\ |\endslot| statement.
+% Normally that constrol sequence is undefined, hence equivalent to
+% |\relax|, and thus the code gets executed. However |\o-.notdef| will
+% instead gobble this argument and set |missingslots| to true.
+% \begin{macrocode}
+{
+ \catcode`\/=\active
+ \catcode`\]=\active
+ \gdef\enctoetx#1#2{{
+ \catcode`\/=\active
+ \catcode`\]=\active
+ \def/##1[{
+ \encname_to_etx ##1~{#1}{#2}
+ \a_count=0
+ \global\missingslotsfalse
+ \let/=\encslot_to_etx
+ }
+ \def]~def{}
+ \make_etx{#1}{#2}
+ }}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\encname_to_etx}
+% This macro recieves the encoding vector name, the ENC file name,
+% and the ETX file name when converting an ENC file to an ETX file.
+% The call syntax is
+% \begin{quote}
+% |\encname_to_etx|\meta{vectorname}\textvisiblespace
+% \marg{enc}\marg{etx}
+% \end{quote}
+% (making the first argument space-delimited but the second
+% undelimited is a trick to gobble any space that may be present at
+% the end of that which the caller thinks is the vector name).
+%
+% The command outputs a |\declarepsencoding| command to the
+% generated ETX file.
+% \changes{1.931}{2005/05/13}{Macro added, to support caching
+% original ENC names in autogenerated ETX files. (LH)
+% Thanks to Alexej Kryukov for the inspiration for this.}
+% \begin{macrocode}
+\def\encname_to_etx#1~#2#3{
+ \out_line{\percent_char\space REMOVE~THE~FOLLOWING~LINE~IF~
+ THIS~FILE~IS~MODIFIED~OR~RENAMED.}
+ \out_line{\string\declarepsencoding{#3}{#1}{\string\download{#2.enc}}}
+ \out_line{}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\encslot_to_etx}
+% This macro grabs everything up to the next space and writes a
+% |\setslot| entry with the grabbed material as glyph name. It is
+% used as the definition of |/| (active character) when parsing
+% elements of an encoding vector.
+% \changes{1.931}{2005/05/13}{Macro added (separated from
+% \cs{enctoetx}). (LH)}
+% \begin{macrocode}
+\def\encslot_to_etx#1~{
+ \csname o-#1\endcsname{
+ \ifmissingslots
+ \out_line{\string\nextslot{\the\a_count}}
+ \fi
+ \global\missingslotsfalse
+ \out_line{\string\setslot{#1}}
+ \out_line{\string\endsetslot}
+ \out_line{}
+ }
+ \advance\a_count by 1
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\make_etx}
+% |\make_etx| does the stuff that |\enctoetx| does not; it handles
+% writing the preamble and postamble of the ETX file, but also does
+% the actual |\input| of the ENC file to convert.
+% \changes{1.931}{2005/05/13}{Now requiring a particular
+% \package{fontdoc} version. (LH)}
+% \begin{macrocode}
+\def\make_etx#1#2{
+ \open_out{\temp_prefix#2.etx}
+ \out_line{\percent_char~Filename:~#2.etx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\enctoetx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.enc~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{}
+ \out_line{\string\documentclass[twocolumn]{article}}
+ \out_line{\string\usepackage{fontdoc}[2005/05/13]}
+ \out_line{}
+ \out_line{\string\begin{document}}
+ \out_line{}
+ \out_line{This~document~describes~the~#1~encoding.}
+ \out_line{It~was~automatically~generated~by~the}
+ \out_line{\string\texttt{fontinst}~package.}
+ \out_line{}
+ \out_line{\string\encoding}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \primitiveinput #1.enc\x_relax
+ \out_line{}
+ \out_line{\string\end encoding}
+ \out_line{}
+ \out_line{\string\end{document}}
+ \close_out{Encoding}
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Converting an ETX file to an ENC file}
+% \changes{1.911}{1999/11/21}{ETX to ENC converter added. (LH)}
+%
+% \DescribeMacro{\etxtoenc}
+% The command
+% \begin{quote}
+% |\etxtoenc|\marg{etxfile}\marg{encfile}
+% \end{quote}
+% reads \meta{etxfile}|.etx| and generates a postscript encoding file
+% \meta{encfile}|.enc| that specifies the same encoding vector.
+%
+%
+% \begin{macro}{\notdef_name}
+% This macro holds the name of the \texttt{.notdef} glyph, which must
+% be put in all encoding positions where there is no other glyph.
+% \begin{macrocode}
+\def\notdef_name{.notdef}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\etxtoenc}
+% The conversion has three steps. First the \texttt{.notdef} glyph is
+% assigned to every slot in the encoding, then the ETX file is read
+% and the assignments are changed for the slots which are not
+% unassigned in the encoding, and finally the ENC file is written.
+% The first two steps are carried out by |\etxtoenc|, but the final
+% step is handled by |\make_enc|.
+% \changes{1.927}{2004/07/12}{Made the \meta{etxfile} argument a
+% comma-separated list of ETX files. Changed \cs{do_slot} definition
+% to get set rather than reset semantics. (LH) Feature requested
+% by Werner Lemberg.}
+% \begin{macrocode}
+\def\etxtoenc#1#2{\begingroup
+ \a_count=\z@
+ \loop
+ \x_cs\let{name-\the\a_count}=\notdef_name
+ \ifnum \@cclv>\a_count
+ \advance \a_count \@ne
+ \repeat
+ \def\do_slot{
+ \x_cs\ifx{name-\the\slot_number}\notdef_name
+ \x_cs\edef{name-\the\slot_number}{\slot_name}
+ \fi
+ }
+ \process_csep_list\inputetx #1,\process_csep_list,
+ \make_enc{#1}{#2}
+\endgroup}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\make_enc}
+% The command
+% \begin{quote}
+% |\make_enc|\marg{etxfiles}\marg{encfile}
+% \end{quote}
+% creates the file \meta{encfile}|.enc| and writes to that file the
+% definition of the postscript encoding vector which corresponds to
+% the encoding currently stored in the |\name-|\meta{slot} family of
+% macros. That encoding is assumed to be defined by the files listed
+% in the \meta{etxfiles}.
+%
+% \changes{1.911}{1999/12/02}{Storing encoding name in string
+% \texttt{encodingname}, thus allowing the ETX file to override
+% the default. (LH)}
+% \changes{1.912}{2000/02/12}{Also calling \cs{declarepsencoding}
+% once the encoding file has been written. (LH)}
+% \changes{1.914}{2000/05/14}{Not writing an \texttt{address} entry
+% if that string isn't set. (LH)}
+% \changes{1.919}{2001/08/02}{Added DSC comments. (LH)}
+% \changes{1.927}{2004/07/12}{Modified to handle a comma-separated
+% list of ETX files. (LH)}
+% \begin{macrocode}
+\def\make_enc#1#2{
+ \setstr{encodingname}{fontinst-autoenc-#1}
+ \def\a_macro##1{
+ \add_to\b_macro{##1.etx}
+ \def\a_macro####1{
+ \add_to\b_macro{,~####1.etx}
+ }
+ }
+ \let\b_macro\empty_command
+ \process_csep_list\a_macro #1,\process_csep_list,
+ \open_out{#2.enc}
+ \out_line{\percent_char !PS-Adobe-3.0~Resource-Encoding}
+ \out_line{\percent_char\space @psencodingfile\left_brace_char}
+ \ref_to_sourcefile{author}\b_macro
+ \ref_to_sourcefile{version}\b_macro
+ \out_line{\percent_char\four_spaces date~=~"generated~
+ \the\year/
+ \ifnum10>\month0\fi\the\month/
+ \ifnum10>\day0\fi\the\day",}
+ \out_line{\percent_char\four_spaces filename~=~"\out_filename",}
+ \ref_to_sourcefile{email}\b_macro
+ \ifisstr{address}\then
+ \out_line{\percent_char\four_spaces address~=~\str{address}}
+ \fi
+ \out_line{\percent_char\four_spaces codetable~=~"ISO/ASCII",}
+ \out_line{\percent_char\four_spaces checksum~=~"",}
+ \out_line{\percent_char\four_spaces abstract~=~"
+ This~is~a~postscript~encoding~file,~automatically~
+ generated~by~fontinst~from~\b_macro."}
+ \out_line{\percent_char\space\right_brace_char}
+ \out_line{}
+ \out_line{\percent_char\space Created~by:~tex~\jobname}
+ \out_line{\percent_char\space Created~using:~
+ \string\etxtoenc{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char\space This~file~should~be~installed~
+ somewhere~that~your~DVI}
+ \out_line{\percent_char\space to~postscript~driver~looks~for~files.~
+ It~is~needed~for}
+ \out_line{\percent_char\space reencoding~some~font~you~have~
+ transformed.}
+ \out_line{}
+ \out_line{\percent_char\space After~installing~this~file,~you~
+ should~add~the~following}
+ \out_line{\percent_char\space line~(minus~\percent_char)~
+ to~your~finstmsc.rc~file:}
+ \out_line{\percent_char\space\string\declarepsencoding
+ {#1}{\str{encodingname}}{\string\download{\out_filename}}}
+ \edef\a_macro{
+ \noexpand\declarepsencoding{#1}{\str{encodingname}}
+ {\noexpand\download{\out_filename}}
+ }
+ \a_macro
+ \out_line{}
+ \out_line{\percent_char\percent_char BeginResource:~
+ encoding~\str{encodingname}}
+ \out_line{/\str{encodingname}\space[}
+ \b_count=8
+ \a_count=\z@
+ \loop
+ \ifnum 8=\b_count
+ \b_count=\z@
+ \out_line{\percent_char\space\the\a_count}
+ \fi
+ \out_line{/\csname name-\the\a_count \endcsname}
+ \ifnum \@cclv>\a_count
+ \advance \a_count \@ne
+ \advance \b_count \@ne
+ \repeat
+ \out_line{]~def}
+ \out_line{\percent_char\percent_char EndResource}
+ \out_line{}
+ \out_line{\percent_char\space End~of~file~\out_filename.}
+ \close_out{Encoding~vector}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\ref_to_sourcefile}
+% The command
+% \begin{quote}
+% |\ref_to_sourcefile|\marg{field}\marg{sourcefile}
+% \end{quote}
+% writes a \meta{field} field of a \BibTeX-style header to the
+% current main output file. If the string named \meta{field} is set
+% then the value for this field will be that string, and if it isn't
+% set then the value will be the string \texttt{"See file }^^A
+% \meta{sourcefile}\texttt{"}. Note that the string \#1 is not
+% quoted, so it must contain the quotes if it isn't simply an integer.
+% \begin{macrocode}
+\def\ref_to_sourcefile#1#2{
+ \ifisstr{#1}\then
+ \out_line{\percent_char\four_spaces #1~=~\str{#1},}
+ \else
+ \out_line{\percent_char\four_spaces #1~=~"See~file~#2",}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Converting an ETX file to CMAP file}
+% \changes{1.928}{2004/11/28}{ETX to CMAP converter added. (LH)}
+%
+% \DescribeMacro{\etxtocmap}
+% The command
+% \begin{quote}
+% |\etxtocmap|\marg{etxfile}\marg{cmapfile}
+% \end{quote}
+% reads \meta{etxfile}|.etx| and generates a ToUnicode CMap file
+% \meta{cmapfile}|.cmap| that maps slots to Unicode strings as
+% specified by the \meta{etxfile}.
+%
+% \begin{macro}{\write_cmap_body}
+% The |\write_cmap_body| command writes the actual CMap
+% data\footnote{As opposed to silly stuff that is requested by the
+% file format specification but probably isn't of any use for
+% anything, which is written by \cs{ref_to_sourcefile}.} to the
+% current output file. The syntax is
+% \begin{quote}
+% |\write_cmap_body|\marg{etxfile}
+% \end{quote}
+%
+% More precisely, what this command writes is the codespace range
+% specification and the mappings. The latter are all encoded using
+% \texttt{bfchar} operators.
+% \begin{macrocode}
+\def\write_cmap_body#1{
+ \out_line{1~begincodespacerange~<00>~<FF>~endcodespacerange}
+ \let\do_slot=\_a_true
+ \def\Unicode##1##2{\cmap_charseq{\cmap_codepoint{##1}{##2}}}
+ \let\charseq=\cmap_charseq
+ \inputetx{#1}
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\cmap_codepoint}
+% This is what |\Unicode| is inside a |\charseq|. It appends a
+% UTF-16BE character in hexadecimal notation (either four hex
+% digits for a character in the BMP, or eight hex digits for
+% a surrogate pair) to |\a_macro|, and also appends a space for
+% grouping the digits for easier reading.
+% \changes{1.928}{2004/12/05}{Added \cs{uppercase} to ensure case
+% independence. (LH)}
+% \begin{macrocode}
+\def\cmap_codepoint#1#2{
+ \uppercase{\a_count="#1\x_relax}
+ \ifnum "10000>\a_count
+ \format_hex\b_macro{\a_count}{4}
+ \edef\a_macro{\a_macro \b_macro \space}
+ \else
+ \advance \a_count -"10000
+ \d_count=\a_count
+ \divide \a_count "400
+ \b_count=\a_count
+ \multiply \b_count "400
+ \advance \d_count -\b_count
+ \advance \a_count "D800
+ \advance \d_count "DC00~
+ \format_hex\b_macro{\a_count}{4}
+ \format_hex\c_macro{\d_count}{4}
+ \edef\a_macro{\a_macro \b_macro \c_macro \space}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\cmap_charseq}
+% This macro is what |\charseq| is when generating a CMap; all
+% writing of CMap entries is routed through it. Only the first
+% character equivalent of each slot should get written to file, so
+% the |_a_| switch is used for keeping track of whether this would be
+% the first.
+%
+% \begin{macrocode}
+\def\cmap_charseq#1{%
+ \if_a_
+ \bgroup
+ \let\Unicode=\cmap_codepoint
+ \let\a_macro=\empty_command
+ #1
+ \format_hex\b_macro{\slot_number}{2}
+ \out_line{1~beginbfchar~<\b_macro>~<~\a_macro>~endbfchar}
+ \egroup
+ \_a_false
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+%
+% \begin{macro}{\etxtocmap}
+% As usual for macros with this kind of name, this is the user
+% level command to call to generate a CMAP from an ETX. The
+% arguments are file names (not including extensions).
+% \begin{macrocode}
+\def\etxtocmap#1#2{\begingroup
+ \inputetx{#1}
+ \open_out{#2.cmap}
+ \out_line{\percent_char !PS-Adobe-3.0~Resource-CMap}
+ \out_line{\percent_char\percent_char
+ DocumentNeededResources:~procset~CIDInit}
+ \out_line{\percent_char\percent_char
+ IncludeResource:~procset~CIDInit}
+% \end{macrocode}
+% Here comes the first problem: the CMap must have a name. If the ETX
+% file sets the string variable \texttt{cmapname} then that is used
+% as name, but otherwise |fontinst-|\meta{cmapfile} is used as name.
+% Note that this is different from the pattern in |\etxtoenc|, which
+% instead uses the \meta{etxname}.
+% \begin{macrocode}
+ \setstr{cmapname}{fontinst-#2}
+ \out_line{\percent_char\percent_char
+ BeginResource:~CMap~\str{cmapname}}
+% \end{macrocode}
+% The next problem is whether one should bother with the quite
+% extensive version control junk that Adobe has specified. I prefer
+% not to, because it is very much geared towards using CMaps with
+% CIDFonts, which is not the case here.
+%
+% Thus it is time for the actual PS code.
+% \begin{macrocode}
+ \out_line{/CIDInit~/ProcSet~findresource~begin}
+ \out_line{7~dict~begin}
+ \out_line{begincmap}
+ \out_line{/CMapName~/\str{cmapname}~def}
+ \out_line{/CMapType~2~def}
+ \write_cmap_body{#1}
+ \out_line{endcmap}
+ \out_line{CMapName~currentdict~/CMap~defineresource~pop}
+ \out_line{end}
+ \out_line{end}
+ \out_line{\percent_char\percent_char EndResource}
+ \out_line{\percent_char\percent_char EOF}
+ \close_out{ToUnicode~CMap}
+\endgroup}
+%</misc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \subsection{Converting an AFM file to an MTX file}
+%
+% \DescribeMacro{\afmtomtx}
+% The macro
+% \begin{quote}
+% |\afmtomtx|\marg{afmfile}\marg{mtxfile}
+% \end{quote}
+% reads \meta{afmfile}|.afm|, and writes the same information out to
+% \meta{mtxfile}|.mtx|.
+%
+% \begin{macro}{\afmtomtx}
+% \changes{1.911}{1999/11/18}{Changed setting of \cs{raw_font_name}
+% to \cs{edef} and added setting of \cs{source_font_name}. (LH)}
+% \changes{1.917}{2001/03/13}{Added resetting of
+% \cs{setsomething_global}---assignments made here must be
+% local. (LH)}
+% \begin{macrocode}
+%<*pkg>
+\def\afmtomtx#1#2{{
+ \let\setsomething_global=\x_relax
+ \open_out{\temp_prefix#2.mtx}
+ \edef\raw_font_name{#2}
+ \edef\source_font_name{#1}
+ \x_resetint{italicslant}{0}
+ \let\italcorr_expression=\uprightitalcorr
+ \x_setint{minimumkern}{0}
+ \minimum_kern=\int{minimumkern}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\afmtomtx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.afm~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \catcode`\^^M=12
+ \catcode`\ =10
+ \expandafter\afm_line\primitiveinput #1.afm\x_relax
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Metrics}
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% Kerns below this value are ignored.
+%
+% \begin{macrocode}
+\newcount\minimum_kern
+% \end{macrocode}
+%
+%
+% \begin{macro}{\afm_length}
+% \changes{1.900}{1998/12/28}{Macro added, other macros modified to
+% use it. (LH)}
+% \begin{macro}{\afm_unit_dimen}
+% The call |\afm_length|\meta{count}\marg{real}
+% interprets the \meta{real} as a real number, rounds it to the
+% nearest integer, and sets the \meta{count} (a |\count| register)
+% to that integer. In this process, |\a_dimen| is used as a temporary
+% storage.
+% \begin{macrocode}
+\def\afm_length#1#2{
+ \a_dimen=#2\afm_unit_dimen
+ #1=\a_dimen
+ \divide #1 by \afm_unit_dimen
+ \advance \a_dimen by -#1\afm_unit_dimen
+ \ifdim \a_dimen>0.5\afm_unit_dimen
+ \advance #1 by 1
+ \else \ifdim \a_dimen<-0.5\afm_unit_dimen
+ \advance #1 by -1
+ \fi\fi
+ \x_relax
+}
+% \end{macrocode}
+% The dimen |\afm_unit_dimen| is used to keep track of how long an AFM
+% unit is interpreted as being in this routine. Lowering its value
+% makes |\afm_length| capable of handling greater lengths but looses
+% some very slight precision in the rounding, increasing the value
+% has the opposite effects. The current value of 1000\thinspace sp
+% means it reads lengths with three decimals accuracy (not very much
+% use for them though as the number is rounded to zero decimals
+% accuracy anyway, but it does make a difference when deciding how
+% a \meta{real} like |0.502| should be rounded) and can handle lengths
+% of an absolute value of a good million AFM units. This should be
+% adequate in most cases. It is, by the way, probably wisest to keep
+% it a power of ten scaled points in all cases, as this should reduce
+% the rounding errors caused by various base conversions.
+% \begin{macrocode}
+\newdimen\afm_unit_dimen
+\afm_unit_dimen=1000sp
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% The command |\afm_line| reads to the end of the line, calls
+% |\afm_command| on that line, then calls |\afm_line| again.
+%
+% \begin{macrocode}
+{\catcode`\^^M=12 \gdef\afm_line#1
+{\afm_command#1~\end_of_line\afm_line}}
+% \end{macrocode}
+%
+% The command |\afm_command| reads the first word \meta{FOO}, and
+% calls |\afm-|\meta{FOO}\describecsfamily{afm-\meta{key}}. If this
+% does not exist, then |\gobble_one_line| will
+% eat up the rest of the line.
+%
+% \begin{macrocode}
+\def\afm_command#1~{\csname~afm-#1\endcsname\gobble_one_line}
+\def\gobble_one_line#1\end_of_line{}
+% \end{macrocode}
+%
+% This all stops when we reach the command |EndFontMetrics|.
+%
+% \begin{macrocode}
+\x_cs\def{afm-EndFontMetrics}#1\afm_line{\endinput}
+% \end{macrocode}
+%
+% \begin{macro}{\afm_def}
+% To define an AFM command, you say |\afm_def|\marg{command}^^A
+% \parg{pattern}\marg{result}
+% \begin{macrocode}
+\def\afm_def#1(#2)#3{
+ \x_cs\def{afm-#1}\gobble_one_line#2\end_of_line{#3}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\afm_let}
+% Saying |\afm_let|\marg{dest-command}\marg{source-command} copies
+% the definition of one AFM command to another.
+% \begin{macrocode}
+\def\afm_let#1#2{
+ \expandafter\let \csname afm-#1\expandafter\endcsname
+ \csname afm-#2\endcsname
+}
+% \end{macrocode}
+% \end{macro}
+%
+% For example, we can define the following AFM commands:
+% \changes{1.6}{1997/02/07}{AFM commands fixed, to get fontdimens
+% comparable to EC fonts. (Thierry Bouche)}
+% ^^A (Fixed by Thierry Bouche
+% ^^A 1997/02/07, to get fontdimens comparable to EC fonts.)
+% \changes{1.912}{2000/02/20}{AFM command \texttt{StdVW} now
+% interpreted: generates \cs{setint} for integer
+% \texttt{verticalstem}. (LH)}
+%
+% \begin{macrocode}
+\afm_def{CharWidth}(#1){\afm_length\char_x_width{#1}}
+\afm_def{ItalicAngle}(#1~){\calculate_it_slant{#1}}
+\afm_def{XHeight}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{xheight}{\the\a_count}}}
+\afm_def{CapHeight}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{capheight}{\the\a_count}}}
+\afm_def{Ascender}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{ascender}{\the\a_count}}}
+\afm_def{Descender}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{descender_neg}{\the\a_count}}}
+\afm_def{UnderlineThickness}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{underlinethickness}{\the\a_count}}}
+\afm_def{FontBBox}(#1~#2~#3~#4){
+ \afm_length\a_count{#4}
+ \out_line{\string\setint{maxheight}{\the\a_count}}
+ \afm_length\a_count{#2}
+ \out_line{\string\setint{maxdepth_neg}{\the\a_count}}}
+\afm_def{StdVW}(#1){
+ \afm_length\a_count{#1}
+ \out_line{\string\setint{verticalstem}{\the\a_count}}}
+\afm_def{IsFixedPitch}(#1){
+ \if\first_char#1=f
+ \else\out_line{\string\setint{monowidth}{1}}
+ \fi
+}
+% \end{macrocode}
+%
+% \multchanges{\cs{afm_font_name}}{1.901}{1999/03/06}{Macro added. (LH)}
+% \multchanges{\cs{afm_font_name}}{1.911}{1999/11/18}{Macro removed,
+% since no longer needed. (LH)}
+%
+% \begin{macro}{\afm-FontName}
+% The |FontName| of a font is needed for the |\storemapdata| command,
+% so it is when that is encountered that this is written. This
+% information is of no use when making TFMs and VFs, but it is likely
+% to be of use for generation of map files, so it will be included in
+% a file of recorded transforms, if such a file is being generated.
+% \begin{macrocode}
+\afm_def{FontName}(#1~){
+ \record_transform{\raw_font_name}
+ {\string\fromafm{\source_font_name}{#1}}{}\iftrue
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\afm-KPX}
+% \begin{macro}{\afm-KP}
+% Processing kern pairs. If one of the glyph name starts with
+% a dot as in |.notdef| or |.null| the kern pair is ignored.
+% The pair is also ignored if the absolute value of the kern
+% amount is |\minimum_kern| or less.
+%
+% That \texttt{KPX} can have the same definition as \texttt{KP} is
+% due to an edge case in the processing of AFM lines: |\afm_line|
+% inserts an extra space at the end of a line. For \texttt{KPX}
+% which really only has three arguments this extra space matches
+% the space in |#3~#4|, whereas for \texttt{KP} which has four
+% arguments this extra space appears at the end of |#4|.
+%
+% \begin{macrocode}
+\afm_def{KP}(#1~#2~#3~#4){
+ \if\first_char#1=.\else
+ \if\first_char#2=.\else
+ \afm_length\a_count{#3}
+ \ifnum \a_count>\minimum_kern
+ \afm_write_setkern{#1}{#2}{\the\a_count}
+ \else\ifnum \a_count<-\minimum_kern
+ \afm_write_setkern{#1}{#2}{\the\a_count}
+ \fi\fi
+ \fi\fi
+}
+\afm_let{KPX}{KP}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\afm_write_setkern}
+% This macro is a hook for the auto-aliasing mechanism to redefine.
+% In this plain form, it just outputs a |\setkern| command with the
+% given three arguments.
+% \changes{1.933}{2007/01/23}{Macro added. (LH)}
+% \begin{macrocode}
+\def\afm_write_setkern#1#2#3{\out_line{\string\setkern{#1}{#2}{#3}}}
+% \end{macrocode}
+% \end{macro}
+%
+% Processing char metrics.
+%
+% \begin{macrocode}
+\afm_def{C}(#1~;#2){\init_afm{#1}\do_list[#2]\afm_char}
+% \end{macrocode}
+%
+% \begin{macro}{\afm-CH}
+% The |CH| keyword is like |C|, but signals that the following
+% character code is given in hexadecimal.
+% \changes{1.933}{2007/01/22}{Proper definition, that parses the
+% following hexadecimal value. (LH) Since noone has complained
+% about this before, it's probably not very common.}
+% \begin{macrocode}
+\afm_def{CH}(<#1>~;#2){\uppercase{\init_afm{"#1}}\do_list[#2]\afm_char}
+% \end{macrocode}
+% \end{macro}
+%
+% Processing composite chars.
+%
+% \begin{macrocode}
+\afm_def{CC}(#1~#2~;#3){\init_cc{#1}\do_list[#3]\cc_char}
+% \end{macrocode}
+%
+% When parsing a character, we set the values of the following
+% variables:
+%
+% \begin{macrocode}
+\newcount\char_slot
+\newcount\char_x_width
+\newcount\x_width
+\newcount\bbox_llx
+\newcount\bbox_lly
+\newcount\bbox_urx
+\newcount\bbox_ury
+\let\char_name=\empty_command
+% \end{macrocode}
+%
+% \begin{macro}{\init_afm}
+% |\init_afm| initializes the variables the AFM character list
+% writes to.
+% \begin{macrocode}
+\def\init_afm#1{
+ \char_slot=#1\x_relax
+ \x_width=\char_x_width
+ \bbox_llx=0
+ \bbox_lly=0
+ \bbox_urx=0
+ \bbox_ury=0
+ \let\char_name=\empty_command
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\afm_char}
+% This command is executed at the end of processing a \texttt{C}
+% (or \texttt{CH}) line. It outputs the corresponding
+% |\setrawglyph| or |\setnotglyph| command, based on information
+% stored into registers when processing that line.
+% \changes{1.933}{2007/01/23}{Negating \cs{bbox_lly} using
+% \cs{number} instead of an assignment to \cs{a_count}. (LH)}
+% \begin{macrocode}
+\def\afm_char{
+ \eval_expr{
+ \italcorr_expression\x_width\bbox_llx\bbox_urx\bbox_lly\bbox_ury
+ }
+ \out_line{
+ \ifnum -1<\char_slot
+ \string\setrawglyph
+ \else
+ \string\setnotglyph
+ \fi
+ {\char_name}
+ {\raw_font_name}
+ {10pt}
+ {\the\char_slot}
+ {\the\x_width}
+ {\the\bbox_ury}
+ {\number -\bbox_lly}
+ {\the\result}
+ }
+}
+% \end{macrocode}
+% \end{macro}
+%
+% |\init_cc| and |\cc_char| write out a composite character glyph.
+%
+% \begin{macrocode}
+\def\init_cc#1{%
+ \out_line{\string\setglyph{#1}}
+ \def\char_name{#1}
+}
+\def\cc_char{%
+ \out_lline{\string\samesize{\char_name-not}}
+ \out_line{\string\endsetglyph}
+}
+% \end{macrocode}
+%
+%
+% \changes{1.900}{1998/12/28}{Method of computing italic corrections
+% changed to using an integer expression. (LH)}
+% \DescribeMacro{\italcorr_expression}
+% The way the italic correction is computed has been changed
+% quite a bit, although the computed values are still the same.
+% The point is that it is much simpler to modify the formula according
+% to which the value is computed using this method than using the
+% previous method.
+%
+% The call
+% \begin{quote}
+% |\italcorr_expression|\marg{width}\marg{left}^^A
+% \marg{right}\marg{bottom}\marg{top},
+% \end{quote}
+% where the arguments are \TeX\ \meta{number}s, should expand to an
+% integer expression. The value of that expression will be taken as the
+% italic correction of the current character.
+%
+% \meta{width} is the width of the character. \meta{left},
+% \meta{right}, \meta{bottom}, and \meta{top} are the respective
+% coordinates of the sides of the bounding box of the character. A
+% quantity which is not given as an argument, but which nontheless
+% might be of interest for a calculation of italic correction, is the
+% italic slant of the font. This quantity can be found in the fontinst
+% integer \texttt{italicslant}. (The MTX file written will also set
+% the integer \texttt{italicslant} to this value.)
+%
+% \begin{macro}{\uprightitalcorr}
+% \begin{macro}{\slanteditalcorr}
+% These two commands are what |\italcorr_expression| will get set
+% to---the slanted version is used if the italic slant is positive and
+% the upright version is used otherwise. The default definitions
+% compute the same values as in fontinst v\,1.8, but the definitions
+% can easily be modified using |\resetcommand|.
+% \begin{macrocode}
+\def\uprightitalcorr#1#2#3#4#5{0}
+\def\slanteditalcorr#1#2#3#4#5{\max{\sub{#3}{#1}}{0}}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\calculate_it_slant}
+% To set the italic angle, we need to calculate the tangent of the
+% angle that the |.afm| file contains. This is done with David
+% Carlisle's \package{trig} macros. Note that the \package{trig}
+% macros don't like a space at the end of their argument.
+%
+% \changes{1.911}{1999/11/18}{Stripping off the space in
+% \cs{afm-ItalicAngle}. (LH)}
+% ^^A\question{\cs{afm_line} always inserts a space at the end of the line.}
+% ^^ACould we therefore save us a bit of trouble by simply changing the
+% ^^Apattern for |\ItalicAngle| to |(#1~)|? /LH
+%
+% \begin{macrocode}
+\def\calculate_it_slant#1{
+ \edef\theangle{#1}
+ \CalculateTan{\theangle}
+ \a_dimen=-\one_thousand sp
+ \a_dimen=\UseTan{\theangle}\a_dimen
+ \a_count=\a_dimen
+ \out_line{\string\setint{italicslant}{\the\a_count}}
+ \x_resetint{italicslant}{\a_count}
+ \ifnum 0<\a_count
+ \let\italcorr_expression=\slanteditalcorr
+ \else
+ \let\italcorr_expression=\uprightitalcorr
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+% \def\strip_spaces#1~#2\end_strip_spaces{#1}
+% \end{macrocode}
+% \end{macro}
+%
+% To process a list of commands separated by semi-colons, we call
+% |\do_list[LIST]|. This works in a similar way to |\afm_line|, but
+% the control sequence family used for decoding is
+% \describecsfamily{list-\meta{key}}|\list-|\meta{keyword} rather
+% than |\afm-|\meta{keyword}.
+%
+% \begin{macrocode}
+\def\do_list[~#1~#2;~#3]{
+ \csname~list-#1\endcsname\gobble_one_semi#2;
+ \ifx\x_relax#3\x_relax\expandafter\gobble_one
+ \else\expandafter\identity_one\fi
+ {\do_list[~#3]}
+}
+\def\gobble_one_semi#1;{}
+% \end{macrocode}
+%
+% There is an analagous |\list_def| for defining commands to be used
+% inside lists.
+%
+% \begin{macrocode}
+\def\list_def#1(#2)#3{\x_cs\def{list-#1}\gobble_one_semi#2~;{#3}}
+% \end{macrocode}
+%
+% For example, these are the commands that are used in giving
+% character metrics:
+%
+% \begin{macrocode}
+\list_def{W}(#1~#2){\afm_length\x_width{#1}}
+\list_def{WX}(#1){\afm_length\x_width{#1}}
+\list_def{WY}(#1){}
+\list_def{N}(#1){\def\char_name{#1}}
+\list_def{B}(#1~#2~#3~#4){
+ \afm_length\bbox_llx{#1}
+ \afm_length\bbox_lly{#2}
+ \afm_length\bbox_urx{#3}
+ \afm_length\bbox_ury{#4}
+}
+\list_def{PCC}(#1~#2~#3){
+ \afm_length\a_count{#2}
+ \afm_length\b_count{#3}
+ \out_lline{\string\glyphpcc{#1}{\the\a_count}{\the\b_count}}
+}
+% \end{macrocode}
+%
+% \begin{macro}{\definealias}
+% The |\definealias| command can be used to define a glyph name
+% alias, for generation of |\aliased| clauses in glyph names. The
+% syntax is
+% \begin{quote}
+% |\definealias|\marg{alias name}\marg{font's name}\marg{int}
+% \end{quote}
+% where \meta{font's name} is the glyph name that if found in an
+% AFM file should be converted to an |\aliased| clause using the
+% \meta{alias name}. The \meta{int} is the name of an integer which
+% will be incremented every time this alias applies to a glyph
+% definition; this mechanism is meant to help higher level code
+% pick an ETX file that fits the font's glyph names.
+%
+% \changes{1.933}{2007/01/22}{Command added. (LH)}
+%
+% Defined aliases are stored in the
+% \describecsfamily{GN-\meta{font's name}}|\GN-|\meta{font's name}
+% family of control sequences. These control sequences are defined
+% to be macros expanding to the two tokens
+% \begin{quote}
+% |\g-|\meta{alias name}\,|\i-|\meta{int}
+% \end{quote}
+% In the case of |\g-|\meta{alias name}, this is purely a trick to
+% save memory (it is very likely that these control sequences will
+% anyway occur during the fontmaking part of the processing).
+% \begin{macrocode}
+\def\definealias#1#2#3{
+ \expandafter\def \csname GN-#1 \expandafter\endcsname
+ \expandafter{ \csname g-#2 \expandafter\endcsname
+ \csname i-#3\endcsname}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\glyph_alias}
+% \begin{macro}{\glyph_alias_i}
+% The |\glyph_alias| macro has the syntax
+% \begin{quote}
+% |\glyph_alias|\marg{font's name}
+% \end{quote}
+% It expands to the \meta{alias name} corresponding to the
+% \meta{font's name}, that had previously been set up using
+% |\definealias|. Where this macro is used, it must already have
+% been checked that |\GN-|\meta{font's name} is defined.
+% \begin{macrocode}
+\def\glyph_alias#1{
+ \expandafter\expandafter \expandafter\glyph_alias_i
+ \csname GN-#1\endcsname
+}
+\def\glyph_alias_i#1#2{
+ \expandafter\gobble_three \string#1
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macrocode}
+\let\charnameprefix\empty
+\def\charnamealias#1{
+ \if_defined{GN-\charnameprefix#1}\then
+ \glyph_alias{\charnameprefix#1}
+ \else\if_defined{GN-#1}\then
+ \glyph_alias{#1}
+ \else
+ #1
+ \fi\fi
+}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\def\alias_incr#1{
+ \expandafter\expandafter \expandafter\alias_incr_i
+ \csname GN-#1\endcsname
+}
+\def\alias_incr_i#1#2{
+ \ifx#2\x_relax
+ \mathchardef#2=\@ne
+ \else
+ \a_count=#2
+ \advance\a_count\@ne
+ \mathchardef#2=\a_count
+ \fi
+}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\def\alias_char_name#1{
+ \if_defined{GN-\charnameprefix#1}\then
+ \edef\char_name{
+ \string\aliased{#1}{\glyph_alias{\charnameprefix#1}}
+ }
+ \alias_incr{\charnameprefix#1}
+ \else\if_defined{GN-#1}\then
+ \edef\char_name{
+ \string\aliased{#1}{\glyph_alias{#1}}
+ }
+ \alias_incr{#1}
+ \else
+ \edef\char_name{#1}
+ \fi\fi
+}
+\def\autoaliasafm{
+ \begingroup
+ \list_def{N}(##1){\alias_char_name{##1}}
+ \def\afm_write_setkern##1##2##3{
+ \out_line{
+ \string\setkern{\charnamealias{##1}}{\charnamealias{##2}}{##3}
+ }
+ }
+ \def\init_cc##1{%
+ \edef\char_name{\charnamealias{##1}}
+ \out_line{\string\setglyph{\char_name}}
+ }
+ \list_def{PCC}(##1~##2~##3){
+ \afm_length\a_count{##2}
+ \afm_length\b_count{##3}
+ \out_lline{\string\glyphpcc
+ {\charnamealias{##1}}{\the\a_count}{\the\b_count}}
+ }
+}
+\def\endautoaliasafm{\endgroup}
+% \end{macrocode}
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \subsection{Converting a PL file to an MTX file}
+%
+% \DescribeMacro{\generalpltomtx}The macro
+% \begin{quote}
+% |\generalpltomtx|\marg{plfile}\marg{mtxfile}\marg{plsuffix}\relax
+% \marg{opt-enc}
+% \end{quote}
+% reads \meta{plfile}|.|\meta{plsuffix}, interprets it as having the
+% encoding specified by the file \meta{opt-enc}|.etx|, and writes the
+% same metric information out to \meta{mtxfile}|.mtx|. In case
+% \meta{opt-enc} is empty, the encoding will be determined using the
+% |CODINGSCHEME| property of the file being read.
+% \DescribeMacro{\pltomtx}The macro
+% \begin{quote}
+% |\pltomtx|\marg{plfile}\marg{mtxfile}
+% \end{quote}
+% reads \meta{plfile}|.pl|, uses the |CODINGSCHEME| property in that
+% file to determine its encoding, and writes the same metric information
+% out to \meta{mtxfile}|.mtx|.
+%
+% None of these commands can cope with |SKIP| properties in the (V)PL
+% file.
+%
+% \begin{macro}{\generalpltomtx}
+% \changes{1.902}{1999/05/01}{Command added, removed
+% \cs{pltomtxgivenetx}. (LH)}
+% \changes{1.910}{1999/11/01}{Made this command the standard one,
+% which \cs{pltomtx} calls. (UV\&LH)}
+% \changes{1.917}{2001/03/13}{Added resetting of
+% \cs{setsomething_global}---assignments made here must be
+% local. (LH)}
+% \changes{1.923}{2002/12/03}{Changed test of fourth argument to
+% instead of \cs{ifx} use \cs{if}. This is more versatile. (LH)}
+% \begin{macrocode}
+\def\generalpltomtx#1#2#3#4{{
+ \let\setsomething_global=\x_relax
+ \let\setfontdimen=\pl_setfontdimen
+ \if _#4_ \else
+ \def\do_slot{\x_cs\let{name-\the\slot_number}\slot_name}
+ \def\do_boundary{\x_cs\let{name-BOUNDARYCHAR}\slot_name}
+ \inputetx{#4}
+ \let\CODINGSCHEME=\ignore_parens
+ \fi
+ \pl_to_mtx{#1}{#2}{#3}{\string\generalpltomtx{#1}{#2}{#3}{#4}}
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\pltomtx}
+% \begin{macrocode}
+\def\pltomtx#1#2{\generalpltomtx{#1}{#2}{pl}{}}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\pl_to_mtx}
+% \changes{1.911}{1999/11/19}{\cs{edef}ing \cs{raw_font_name}. (LH)}
+% The |\pl_to_mtx| macro contains all code that was common to
+% |\pltomtx| and |\general|\-|pltomtx| before the former was redefined
+% to a call of the latter. The structure of a call of |\pl_to_mtx| is
+% \begin{quote}
+% |\pl_to_mtx|\marg{plfile}\marg{mtxfile}\marg{plsuffix}\marg{call}
+% \end{quote}
+% \meta{call} is what should be written in the ``Created using:''
+% comment at the top of the MTX file written.
+% \changes{1.921}{2002/07/27}{\cs{fromvpl} in \cs{storemapdata} does
+% not have an argument. Fixed a bug that produced such an argument
+% anyway. (LH)}
+% \begin{macrocode}
+\def\pl_to_mtx#1#2#3#4{
+ \edef\raw_font_name{#1}
+ \open_out{\temp_prefix#2.mtx}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~#4}
+ \out_line{}
+ \out_line{\percent_char~This~file~contains~the~
+ information~of~#1.#3~in~a~form}
+ \out_line{\percent_char~more~easily~read~by~TeX.~
+ It~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \lowercase{
+ \record_transform{#2}{
+ \string\from#3 \x_cs\ifx{from#3}\frompl {#1} \fi
+ }{}\iftrue
+ }
+ \out_line{}
+ \catcode`\(=0 \catcode`\)=9
+ \let\/=\ignore_parens
+ \let\do_pl_glyph=\x_relax
+ \primitiveinput #1.#3\x_relax
+ \do_pl_glyph
+ \out_line{}
+ \ifisint{\percent_char boundarychar}\then
+ \f_count=\int{\percent_char boundarychar}
+ \x_cs\ifx{name-\the\f_count}\x_relax \else
+ \out_line{\string\setstr{rightboundary}
+ {\csname name-\the\f_count\endcsname}
+ }
+ \out_line{}
+ \fi
+ \fi
+ \out_line{\endmetrics_text}
+ \close_out{Metrics}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% To parse a |.pl| file, we first make |(| the escape character, make |)|
+% ignored, then define the various PL commands as \TeX\ control sequences.
+% We can ignore a parenthesis matched string by making |(| and |)| the
+% group delimiters, then gobbling them up.
+%
+% \begin{macrocode}
+\def\ignore_parens{\bgroup\catcode`(=1 \catcode`)=2 \x_relax
+ \expandafter\expandafter\expandafter\gobble_parens
+ \iftrue\expandafter{\else}\fi}
+\def\gobble_parens#1{\egroup}
+% \end{macrocode}
+%
+% \begin{macro}{\pl_real}
+% \begin{macro}{\pl_realer}
+% Convert a PL real to an AFM unit, assuming it contains a decimal point.
+% \begin{macrocode}
+\def\pl_real#1{\pl_realer(#1000)}
+\def\pl_realer(#1.#2#3#4#5){#1#2#3#4}
+% \end{macrocode}
+% \cs{pl_real} only works if the \texttt{DESIGNUNITS}
+% setting is at the default value 1. Luckily, this is what
+% \package{TFtoPL} and \package{VFtoVP} use in all (V)PL files they
+% create, so you can always get a (V)PL file that will work by
+% converting first to TFM (+\,VF) and then back again. As of v\,1.913,
+% that is also the value \package{fontinst} uses for all VPL files it
+% generates, so the problem isn't particularly important.
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\pl_rounded_real}
+% \changes{1.921}{2002/07/26}{Macro added and is used instead of
+% \cs{pl_real}. (LH)}
+% The |\pl_rounded_real| macro is like |\pl_realer| in that it converts
+% a PL unit containing a decimal point to an AFM unit. The difference
+% is (i) that it rounds the number rather than truncating it and (ii)
+% that it stores the result in |\result| rather than expanding to it.
+% Note that the actual real (character string) to convert must be
+% followed by at least four zeros for the conversion to work
+% correctly in all cases.
+% \begin{macrocode}
+\def\pl_rounded_real(#1.#2#3#4#5){
+ \global\result=#1#2#3#4\relax
+ \ifnum \first_char#5= >4
+ \global\advance \result
+ \if - \first_char#1= \m@ne \else \@ne \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\pl_int}
+% Convert a PL int to a \TeX{} int, assuming it's prefixed
+% by |C|, |D|, |O|, or |H|.
+% \begin{macrocode}
+\def\pl_int#1#2{
+ \ifx#1C `#2
+ \else\ifx#1D #2
+ \else\ifx#1O '#2
+ \else\ifx#1H "#2
+ \else -1\errmessage{Unknown~PL~number~prefix~`#1'}
+ \fi\fi\fi\fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% Many of the PL commands are ignored, and I'm assuming the |R|s are in
+% the places \texttt{tftopl} puts them, which is a bit naughty of me.
+%
+% \begin{PLproperty}{FAMILY}
+% \begin{PLproperty}{FACE}
+% \begin{PLproperty}{CHECKSUM}
+% \begin{PLproperty}{HEADER}
+% \begin{PLproperty}{SEVENBITSAFEFLAG}
+% \begin{macrocode}
+\let\FAMILY=\ignore_parens
+\let\FACE=\ignore_parens
+\let\CHECKSUM=\ignore_parens
+\def\HEADER~#1~#2~#3~#4~{}
+\def\SEVENBITSAFEFLAG~#1~{}
+% \end{macrocode}
+% \end{PLproperty}\end{PLproperty}\end{PLproperty}\end{PLproperty}
+% \end{PLproperty}
+%
+% \begin{PLproperty}{COMMENT}
+% \begin{PLproperty}{LIG}
+% \begin{PLproperty}{NEXTLARGER}
+% \begin{PLproperty}{VARCHAR}
+% \begin{macrocode}
+\let\COMMENT=\ignore_parens
+\let\LIG=\ignore_parens
+\let\NEXTLARGER=\ignore_parens
+\let\VARCHAR=\ignore_parens
+% \end{macrocode}
+% \end{PLproperty}\end{PLproperty}\end{PLproperty}\end{PLproperty}
+%
+%
+% \begin{PLproperty}{VTITLE}
+% \begin{PLproperty}{MAPFONT}
+% \begin{PLproperty}{MAP}
+% \begin{flushleft}
+% ^^A Flushed left since the paragraph is so hard to break
+% ^^A correctly.
+% \changes{1.900}{1998/12/04}{VPL-specific properties added to
+% those which are ignored by \cs{pltomtx}. (LH)}
+% The properties which are unique for VPL files---|VTITLE|,
+% |MAPFONT|, |MAP|, |FONTNAME|, |FONTAREA|, |FONTCHECKSUM|,
+% |FONTAT|, |FONTDSIZE|, |SELECTFONT|, |SETCHAR|, |SETRULE|,
+% |MOVERIGHT|, |MOVELEFT|, |MOVEUP|, |MOVEDOWN|, |PUSH|, |POP|,
+% |SPECIAL|, and |SPECIALHEX|---should also be ignored, but it is
+% actually sufficient to ignore the first three since the others
+% are only allowed inside |MAP| or |MAPFONT| property lists.
+% \end{flushleft}
+%
+% \begin{macrocode}
+\let\VTITLE=\ignore_parens
+\let\MAPFONT=\ignore_parens
+\let\MAP=\ignore_parens
+% \end{macrocode}
+% \end{PLproperty}\end{PLproperty}\end{PLproperty}
+%
+%
+% \begin{PLproperty}{CODINGSCHEME}
+% \begin{macro}{\CODINGSCHEME_cont}
+% When we reach a |CODINGSCHEME| instruction, we read the coding string,
+% and read in the corresponding \meta{encoding}|.etx| file.
+%
+% The corresponding \meta{encoding} is specified by |\declareencoding|
+% statements (see below). Each |\declare_encoding| defines a macro
+% |\enc-|\meta{codingscheme} which expands to \meta{encoding}.
+%
+% If the PL file is converted using the |\generalpltomtx| command with
+% a nonempty \meta{opt-enc} argument then the |CODINGSCHEME| instruction
+% is ignored since an encoding file has already been read in.
+%
+% \begin{macrocode}
+\def\CODINGSCHEME{\bgroup\catcode`\)=12\x_relax\CODINGSCHEME_cont}
+\def\CODINGSCHEME_cont#1){
+ \egroup
+ \if_undefined{enc-#1}\then
+ \errhelp{The~encoding~for~`#1'~has~not~been~declared.^^J
+ You~should~declare~it~with~
+ \string\declareencoding{#1}{ETXFILE}.^^J
+ Press~<RETURN>~to~carry~on~with~fingers~crossed,^^J
+ or~X~<RETURN>~to~exit.}
+ \errmessage{Undeclared~encoding~`#1'}
+ \else
+ \def\do_slot{\x_cs\let{name-\the\slot_number}\slot_name}
+ \def\do_boundary{\x_cs\let{name-BOUNDARYCHAR}\slot_name}
+ \catcode`\(=12 \catcode`\)=12
+ \x_cs\inputetx{enc-#1}\x_relax
+ \catcode`\(=0 \catcode`\)=9
+ \fi
+}
+% \end{macrocode}
+% \end{macro}\end{PLproperty}
+%
+% \begin{PLproperty}{DESIGNSIZE}
+% The |DESIGNSIZE| is needed because the |FONTDSIZE| specified in a
+% |MAPFONT| property list has to be the same as the |DESIGNSIZE| of
+% the corresponding base font.
+% \begin{macrocode}
+\def\DESIGNSIZE~#1~#2~{
+ \a_dimen=#2pt
+ \out_line{\string\setdim{designsize}{\the\a_dimen}}
+}
+% \end{macrocode}
+% \end{PLproperty}
+%
+% \begin{PLproperty}{DESIGNUNITS}
+% \changes{1.905}{1999/06/30}{Error message added. (LH)}
+% \changes{1.912}{2000/02/20}{Store designunits value in
+% \cs{b_dimen} rather than \cs{a_dimen}. \cs{a_dimen} holds the
+% design size throughout PL-to-MTX. (LH)}
+% The PL to MTX converter assumes that the (V)PL files to convert
+% look like the ones created by \texttt{TFtoPL}\slash\texttt{VFtoVP},
+% and the interpretation of the \texttt{DESIGNUNITS} property is one
+% thing specifically affected by this. The TFM file format does not
+% store the \texttt{DESIGNUNITS} value used, so the two above
+% programs always generate (V)PL files with the default setting of
+% design unit equal to the design size. Hence any occurence of the
+% \texttt{DESIGNUNITS} property with a nondefault value is an
+% indication of an error.
+%
+% The incorrect metrics can be corrected by scaling by a suitable
+% amount (1000 divided by the \texttt{designunits} dimen), but it is
+% much simpler to convert the PL to a TFM and then convert it back,
+% that will also fix the units.
+%
+% \begin{macrocode}
+\def\DESIGNUNITS~#1~#2~{
+ \b_dimen=#2pt\x_relax
+ \ifdim 1pt=\b_dimen \else
+ \fontinsterror{PL-to-MTX}{Nondefault~unit~used~in~PL~file}
+ {You~may~continue,~but~the~metrics~for~this~font~will~be~wrong.}
+ \fi
+ \out_line{\string\setdim{designunits}{\the\b_dimen}}
+}
+% \end{macrocode}
+% \end{PLproperty}
+%
+% \begin{PLproperty}{BOUNDARYCHAR}
+% \begin{macrocode}
+\def\BOUNDARYCHAR~#1~#2~{
+ \x_setint{\percent_char boundarychar}{\pl_int{#1}{#2}}
+}
+% \end{macrocode}
+% \end{PLproperty}
+%
+% \changes{1.917}{2001/03/16}{Rewrote the fontdimen part of the
+% (V)PL-to-MTX converter so that the ETX can specify the
+% fontdimens. (LH)}
+%
+% Declared fontdimens are converted to |\setint| commands in the MTX
+% file. A fontdimen declaration for fontdimen $n$ is stored in the
+% control sequence \describecsfamily{fdimen-\meta{n}}|\fdimen-|$n$; if
+% this control sequence is undefined then the fontdimen is not declared
+% and if it is set then it is a macro which expands to the name of the
+% corresponding integer variable.
+%
+% \begin{macro}{\pl_setfontdimen}
+% Fontdimens are declared by the |\pl_setfontdimen| macro, which is a
+% definition of |\setfontdimen| that is used during (V)PL-to-MTX
+% conversion.
+% \begin{macrocode}
+\def\pl_setfontdimen#1#2{\x_cs\def{fdimen-#1}{#2}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{PLproperty}{PARAMETER}
+% The |PARAMETER| property is the generic specifier of fontdimens in
+% (V)PL files. It takes two arguments: the fontdimen number (integer)
+% and value (real).
+% \begin{macrocode}
+\def\PARAMETER~#1~#2~R~#3~{
+ \f_count=\pl_int{#1}{#2}\x_relax
+ \if_defined{fdimen-\the\f_count}\then
+ \pl_rounded_real(#3 0000)
+ \out_line{\string\setint{\csname fdimen-\the\f_count\endcsname}
+ {\the\result}}
+ \fi
+}
+% \end{macrocode}
+% \end{PLproperty}
+%
+% \begin{PLproperty}{FONTDIMEN}
+% No special processing is required for the |FONTDIMEN| property.
+% \begin{macrocode}
+\let\FONTDIMEN=\x_relax
+% \end{macrocode}
+% \end{PLproperty}
+%
+% \begin{PLproperty}{SLANT}
+% \begin{PLproperty}{SPACE}
+% \begin{PLproperty}{STRETCH}
+% \begin{PLproperty}{SHRINK}
+% \begin{PLproperty}{XHEIGHT}
+% \begin{PLproperty}{QUAD}
+% \begin{PLproperty}{EXTRASPACE}
+% The properties for the seven mandatory fontdimens are converted
+% to the corresponding |PARAMETER| properties but their meanings are
+% predeclared. The effect of these predeclarations is that even ETX
+% files that don't use |\setfontdimen| to set the fontdimens have
+% these fontdimens converted to |\setint|s.
+%
+% A scan shows that the current (2001/03/17) MTX and ETX files aren't
+% using the integers \texttt{stretchword}, \texttt{shrinkword},
+% \texttt{quad}, and \texttt{extraspace}. They probably should.
+% \begin{macrocode}
+\def\SLANT{\PARAMETER D~1~}
+\pl_setfontdimen{1}{italicslant}
+\def\SPACE{\PARAMETER D~2~}
+\pl_setfontdimen{2}{interword}
+\def\STRETCH{\PARAMETER D~3~}
+\pl_setfontdimen{3}{stretchword}
+\def\SHRINK{\PARAMETER D~4~}
+\pl_setfontdimen{4}{shrinkword}
+\def\XHEIGHT{\PARAMETER D~5~}
+\pl_setfontdimen{5}{xheight}
+\def\QUAD{\PARAMETER D~6~}
+\pl_setfontdimen{6}{quad}
+\def\EXTRASPACE{\PARAMETER D~7~}
+\pl_setfontdimen{7}{extraspace}
+% \end{macrocode}
+% \end{PLproperty}\end{PLproperty}\end{PLproperty}\end{PLproperty}
+% \end{PLproperty}\end{PLproperty}\end{PLproperty}
+%
+% \begin{numPLproperty}{NUM}{1,2,3}
+% \begin{numPLproperty}{DENOM}{1,2}
+% The |NUM|$*$ and |DENOM|$*$ properties are for fontdimens 8--10
+% and 11--12. They have to do with positioning numerator and
+% denominator in fractions.
+% \begin{macrocode}
+\def\NUM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~8~#2~#3~
+ \or
+ \PARAMETER D~9~#2~#3~
+ \or
+ \PARAMETER D~10~#2~#3~
+ \fi
+}
+\def\DENOM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~11~#2~#3~
+ \or
+ \PARAMETER D~12~#2~#3~
+ \fi
+}
+% \end{macrocode}
+% \end{numPLproperty}\end{numPLproperty}
+%
+% \begin{numPLproperty}{SUP}{1,2,3}
+% \begin{numPLproperty}{SUB}{1,2}
+% The |SUP|$*$ and |SUB|$*$ properties are for fontdimens 13--15
+% and 16--17. They have to do with positioning superscripts and
+% subscripts.
+% \begin{macrocode}
+\def\SUP#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~13~#2~#3~
+ \or
+ \PARAMETER D~14~#2~#3~
+ \or
+ \PARAMETER D~15~#2~#3~
+ \fi
+}
+\def\SUB#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~16~#2~#3~
+ \or
+ \PARAMETER D~17~#2~#3~
+ \fi
+}
+% \end{macrocode}
+% \end{numPLproperty}\end{numPLproperty}
+%
+% \begin{PLproperty}{SUPDROP}
+% \begin{PLproperty}{SUBDROP}
+% \begin{PLproperty}{AXISHEIGHT}
+% These are fontdimens 18, 19, and 22.
+% \begin{macrocode}
+\def\SUPDROP{\PARAMETER D~18~}
+\def\SUBDROP{\PARAMETER D~19~}
+\def\AXISHEIGHT{\PARAMETER D~22~}
+% \end{macrocode}
+% \end{PLproperty}\end{PLproperty}\end{PLproperty}
+%
+% \begin{numPLproperty}{DELIM}{1,2}
+% The |DELIM|$*$ fondimens have number 20 and 21. They have to do with
+% the size of delimiters put around a generalised fraction.
+% \begin{macrocode}
+\def\DELIM#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~20~#2~#3~
+ \or
+ \PARAMETER D~21~#2~#3~
+ \fi
+}
+% \end{macrocode}
+% \end{numPLproperty}
+%
+% \begin{PLproperty}{DEFAULTRULETHICKNESS}
+% \begin{numPLproperty}{BIGOPSPACING}{1,2,3,4,5}
+% The fontdimen properties that are special for math extension fonts
+% are |DEFAULT|\-|RULE|\-|THICKNESS| and the various
+% |BIG|\-|OP|\-|SPACING|$*$.
+% \begin{macrocode}
+\def\DEFAULTRULETHICKNESS{\PARAMETER D~8~}
+\def\BIGOPSPACING#1~#2~#3~{
+ \ifcase #1\or
+ \PARAMETER D~9~#2~#3~
+ \or
+ \PARAMETER D~10~#2~#3~
+ \or
+ \PARAMETER D~11~#2~#3~
+ \or
+ \PARAMETER D~12~#2~#3~
+ \or
+ \PARAMETER D~13~#2~#3~
+ \fi
+}
+% \end{macrocode}
+% This is the old definition of |\DEFAULTRULETHICKNESS| for historical
+% references (since its behaviour has changed).
+% \begin{macrocode}
+% \def\DEFAULTRULETHICKNESS~R~#1~{
+% \out_line{\string\setint{underlinethickness}{\pl_real{#1}}}
+% }
+% \end{macrocode}
+% \end{numPLproperty}\end{PLproperty}
+%
+%
+% \begin{PLproperty}{LABEL}
+% \begin{macro}{\LABEL_slot}
+% \begin{macro}{\LABEL_boundarychar}
+% \begin{macro}{\do_if_defined}
+% The most complicated part of the processing of the |LIGTABLE|
+% property list is that it has to keep track of which glyphs the
+% current ligature\slash kerning program applies to. This stored as
+% a |\do|\marg{glyph} list in |\a_macro| and building this list
+% is the job of the |LABEL| property.
+%
+% It is assumed that |\do| is |\never_do| whenever some element is
+% added to |\a_macro|.
+% \begin{macrocode}
+\def\LABEL~#1{\ifx #1B
+ \expandafter\LABEL_boundarychar
+ \else
+ \expandafter\LABEL_slot \expandafter#1
+ \fi
+}
+\def\LABEL_slot #1~#2~{
+ \f_count=\pl_int{#1}{#2}
+ \edef\a_macro{\a_macro
+ \x_cs\do_if_defined{name-\the\f_count}
+ }
+}
+\def\LABEL_boundarychar OUNDARYCHAR{
+ \edef\a_macro{\a_macro
+ \x_cs\do_if_defined{name-BOUNDARYCHAR}
+ }
+}
+\def\do_if_defined#1{\ifx #1\x_relax \else \do{#1} \fi}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{PLproperty}
+%
+%
+% \begin{PLproperty}{LIGTABLE}
+% \begin{PLproperty}{STOP}
+% \begin{PLproperty}{SKIP}
+% The |LIGTABLE|, |STOP|, and |SKIP| properties are the remaining
+% properties involved in managing the |\a_macro| list. |SKIP|
+% properties are \emph{not} processed.
+% \begin{macrocode}
+\def\LIGTABLE{\let\do=\never_do\let\a_macro\empty_command}
+\def\STOP{\let\a_macro\empty_command}
+\def\SKIP~#1~#2~{\immediate\write16{Warning:~SKIP~instruction~ignored.}}
+% \end{macrocode}
+% \end{PLproperty}\end{PLproperty}\end{PLproperty}
+%
+% \begin{PLproperty}{KRN}
+% \begin{macro}{\write_pl_krn}
+% |KRN| properties are converted to |\setkern| instructions.
+% \begin{macrocode}
+\def\KRN~#1~#2~R~#3~{
+ \pl_rounded_real(#3 0000)
+ \edef\do{\noexpand\write_pl_krn{\pl_int{#1}{#2}}{\the\result}}
+ \a_macro
+ \let\do=\never_do
+}
+\def\write_pl_krn#1#2#3{
+ \f_count=#1\x_relax
+ \x_cs\ifx{name-\the\f_count}\x_relax \else
+ \out_line{\string\setkern{#3}
+ {\csname name-\the\f_count\endcsname}{#2}
+ }
+ \fi
+}
+% \end{macrocode}
+% \end{macro}\end{PLproperty}
+%
+% \begin{PLproperty}{CHARACTER}
+% \begin{PLproperty}{CHARWD}
+% \begin{PLproperty}{CHARHT}
+% \begin{PLproperty}{CHARDP}
+% \begin{PLproperty}{CHARIC}
+% The character metrics that are processed are |CHARWD|, |CHARHT|,
+% |CHARDP|, and |CHARIC|. The |CHARACTER| property takes care of
+% writing the information to the MTX file, but note that each new
+% |CHARACTER| property writes the information from the preceeding
+% |CHARACTER| property.
+% \begin{macrocode}
+\def\CHARWD~R~#1~{\pl_rounded_real(#1 0000) \b_count=\result}
+\def\CHARHT~R~#1~{\pl_rounded_real(#1 0000) \c_count=\result}
+\def\CHARDP~R~#1~{\pl_rounded_real(#1 0000) \d_count=\result}
+\def\CHARIC~R~#1~{\pl_rounded_real(#1 0000) \e_count=\result}
+\def\CHARACTER~#1~#2~{
+ \do_pl_glyph
+ \a_count=\pl_int{#1}{#2}
+ \b_count=0
+ \c_count=0
+ \d_count=0
+ \e_count=0
+ \let\do_pl_glyph=\write_pl_glyph
+}
+% \end{macrocode}
+% \end{PLproperty}\end{PLproperty}\end{PLproperty}\end{PLproperty}
+% \end{PLproperty}
+%
+% \begin{macro}{\write_pl_glyph}
+% The |\write_pl_glyph| actually writes the information contained in
+% a |CHARACTER| property list to the MTX file as a |\setrawglyph|
+% command.
+% \begin{macrocode}
+\def\write_pl_glyph{
+ \x_cs\ifx{name-\the\a_count}\x_relax\else
+ \out_line{\string\setrawglyph
+ {\csname~name-\the\a_count\endcsname}
+ {\raw_font_name}
+ {\the\a_dimen}
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {\the\e_count}}
+ \fi
+ }
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Converting an MTX file to a PL file}
+%
+% \DescribeMacro{\mtxtopl}
+% The macro
+% \begin{quote}
+% |\mtxtopl|\marg{mtxfile}\marg{plfile}
+% \end{quote}
+% writes a font from the |\setrawglyph| instructions in \meta{mtxfile}
+% to \meta{plfile}. It ignores any font dimensions and kerning, so the
+% resulting font is only useful for generating virtual fonts from.
+% (This macro is called by |\transformfont|.)
+%
+% \begin{macro}{\mtxtopl}
+% \changes{1.911}{1999/11/19}{Added `ligless' to one of the comment
+% lines. (LH) Clarification requested by Walter Schmidt.}
+% \changes{1.917}{2001/03/13}{Added resetting of
+% \cs{setsomething_global}---assignments made here must be
+% local. (LH)}
+% \changes{1.929}{2005/02/05}{Corrected `\texttt{pltotf}' in
+% comment. (LH)}
+% \begin{macrocode}
+\def\mtxtopl#1#2{{
+ \let\setsomething_global=\x_relax
+ \open_out{#2.pl}
+ \top_of_pl_hook
+ \out_line{(COMMENT~raw~font~#2~created~by~fontinst~
+ v\fontinstversion)}
+ \out_line{}
+ \out_line{(COMMENT~Filename:~#2.pl)}
+ \out_line{(COMMENT~Created~by:~tex~\jobname)}
+ \out_line{(COMMENT~Created~using:~\string\mtxtopl{#1}{#2})}
+ \out_line{}
+ \out_line{(COMMENT~This~file~can~be~turned~into~
+ a~ligless~TeX~font~with)}
+ \out_line{(COMMENT~pltotf~#2.pl~#2.tfm)}
+ \out_line{}
+ \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)}
+ \out_line{}
+ \out_line{(DESIGNSIZE~R~10.0)}
+ \out_line{}
+ \let\setglyph=\iffalse
+ \let\endsetglyph=\fi
+ \let\setkern=\gobble_three
+ \let\setscaledrawglyph=\first_pl_raw_glyph
+ \def\setscalednotglyph##1##2##3##4##5##6##7##8##9{}
+ \inputmtx{#1}
+ \out_line{}
+ \out_line{(COMMENT~END~OF~FILE~#2.pl)}
+ \close_out{Raw~font}
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\first_pl_raw_glyph}
+% The |\first_pl_raw_glyph| writes the \texttt{DESIGNUNITS} property
+% for the font when the first |\setscaledrawglyph| is encountered.
+% This is to undo the scaling that has already been applied to the
+% metrics, so that the metrics will match the actual font.
+% \begin{macrocode}
+\def\first_pl_raw_glyph#1#2#3#4{
+ \out_line{(DESIGNUNITS~R~\make_factor{#4})}
+ \let\setscaledrawglyph=\pl_raw_glyph
+ \pl_raw_glyph{#1}{#2}{#3}{#4}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\pl_raw_glyph}
+% \begin{macrocode}
+\def\pl_raw_glyph#1#2#3#4#5#6#7#8#9{
+ \out_line{(CHARACTER~D~\number#5~\space(COMMENT~#1)}
+ \out_lline{(CHARWD~R~\make_factor{#6})}
+ \out_lline{(CHARHT~R~\make_factor{#7})}
+ \out_lline{(CHARDP~R~\make_factor{#8})}
+ \out_lline{(CHARIC~R~\make_factor{#9})}
+ \out_lline{)}
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \section{Font transformations}
+% \label{Sec:Font.trans}
+% \changes{1.902}{1999/05/01}{Moved Section \thesection\space to
+% \texttt{ficonv.dtx}. (LH)}
+%
+% \subsection{Transformable metric files}
+% \label{Ssec:TransMTX}
+%
+% \changes{1.901}{1999/02/28}{Definition of transformable metric file
+% added. (LH)}
+% \changes{1.913}{2000/03/10}{Definition of transformable metric file
+% changed to include the \cs{setscaledrawglyph} and
+% \cs{setscalednotglyph} commands. (LH)}
+% \changes{1.915}{2000/09/09}{Added description of \cs{aliased} macro
+% to the definition of transformable metric files. (LH)}
+% A \emph{transformable metric file} is a metric file
+% which complies with certain restrictions in its syntax. The only
+% metric commands allowed are
+% \begin{isyntax}
+% |\setscaledrawglyph|\marg{glyph}\marg{font}\marg{size}^^A
+% \marg{scale}\marg{slot}\marg{width}\penalty0
+% \marg{height}\penalty0\marg{depth}\penalty0\marg{italic}\\
+% |\setrawglyph|\marg{glyph}\marg{font}\marg{size}\marg{slot}^^A
+% \marg{width}\marg{height}\penalty0\marg{depth}\penalty0
+% \marg{italic}\\
+% |\setscalednotglyph|\marg{glyph}\marg{font}\marg{size}^^A
+% \marg{scale}\marg{slot}\marg{width}\penalty0
+% \marg{height}\penalty0\marg{depth}\penalty0\marg{italic}\\
+% |\setnotglyph|\marg{glyph}\marg{font}\marg{size}\marg{slot}^^A
+% \marg{width}\marg{height}\penalty0\marg{depth}\penalty0
+% \marg{italic}\\
+% |\setkern|\marg{glyph1}\marg{glyph2}\marg{amount}\\
+% |\setglyph|\marg{glyph} \meta{glyph commands} |\endsetglyph|
+% \end{isyntax}
+% where \meta{glyph}, \meta{glyph1}, \meta{glyph2}, and \meta{font} are
+% strings without any variable references (no |\str| or |\strint| are
+% allowed), \meta{scale}, \meta{slot}, \meta{width}, \meta{height},
+% \meta{depth}, \meta{italic}, and \meta{amount} are \TeX\ numbers, and
+% \meta{size} is a \TeX\ dimen. (More accurately, all dimens in a
+% transformable metric file should be on the form \meta{optional
+% signs}\penalty0 \meta{decimal constant}\penalty0 \meta{physical unit},
+% but that's at the ``dangerous bend'' level.) The \meta{glyph}s may be
+% of the form
+% \begin{quote}
+% |\aliased|\marg{font's name}\marg{alias name}
+% \end{quote}
+% Such \meta{glyph}s are interpreted as \meta{alias name} for all
+% purposes except reencoding, when they are interpreted as \meta{font's
+% name}. \meta{glyph}s of this form are furthermore copied as they are
+% to MTX files created by |\transform|\-|font| (|\mtxtomtx|).
+%
+% The only \meta{glyph commands} allowed are
+% \begin{quote}
+% |\samesize|\marg{glyph}\\
+% |\glyphpcc|\marg{glyph}\marg{xoffset}\marg{yoffset}
+% \end{quote}
+% where \meta{glyph} is as above, and \meta{xoffset} and \meta{yoffset}
+% are \TeX\ numbers.
+%
+% The only general commands allowed are
+% \begin{quote}
+% |\needsfontinstversion|\marg{version}\\
+% |\setint|\marg{name}\marg{number}\\
+% |\setdim|\marg{name}\marg{dimen}\\
+% |\setstr|\marg{name}\marg{string}\\
+% |\storemapdata|\marg{font}\marg{source}\marg{transformations}
+% \end{quote}
+% where \meta{name} and \meta{string} are strings without variable
+% references, \meta{number} is a \TeX\ number, and \meta{dimen} is a
+% \TeX\ dimen. The arguments of |\needs|\-|fontinst|\-|version| and
+% |\store|\-|map|\-|data| are as usual, but these commands do not get
+% copied in a font transformation.
+%
+% The metric files produced by |\afmtomtx| and |\generalpltomtx| are
+% meant to be transformable. If they are not then there is a bug
+% somewhere.
+%
+% The name of the integer in |\setint| commands is interpreted. This
+% name is used to determine how the number should be transformed, see
+% the implementation of |\mtxtomtx_setint| below.
+%
+%
+% \subsection{Making font transformations}
+%
+% \changes{1.911}{1999/11/19}{Recording of transformations moved to the
+% macros that actually write the MTX files. (LH)}
+% \changes{1.911}{1999/11/19}{Flag for that source font wasn't found
+% changed to \texttt{afm-name}. \texttt{transform-source} string
+% completely removed. (LH)}
+% \changes{1.913}{2000/03/11}{New implementation of \cs{scalefont} and
+% \cs{yscalefont}, using the new \cs{setscaledrawglyph} and
+% \cs{setscalednotglyph} commands. (LH)}
+% \changes{1.913}{2000/03/12}{Using \cs{slots-}\meta{glyph} control
+% sequences for storing encoding positions of glyphs in reencoded
+% fonts. (LH)}
+%
+% \DescribeMacro{\transformfont}
+% The macro:
+% \begin{quote}
+% |\transformfont|\marg{font-name}\marg{transformed font}
+% \end{quote}
+% transforms the metrics of a raw font. As far as \TeX\ is concerned,
+% \meta{font-name} will be a new font. Actually doing the
+% transformation and providing the transformed font (as opposed to the
+% metrics of the transformed font) is for most transforms up to some
+% other piece of software, in most cases the DVI driver, but
+% \package{fontinst} will handle isotropic scaling itself.
+%
+% The easiest way to find out which transformations need to be carried
+% out is to generate a map file for the \texttt{debug} ``driver'' (see
+% Section~\ref{Sec:Mapfiles}). Of course, if \package{fontinst} can
+% generate a mapfile for the target driver then you probably don't need
+% to find out which transformations were necessary\,\textellipsis
+% \spacefactor=\sfcode`\.\space\space
+% In any case, the arguments of |\storemapdata| in the MTX file
+% generated will tell which transformations of this |\transformfont|
+% command that must be performed by some other software.
+%
+% \DescribeMacro{\fromafm}
+% \DescribeMacro{\frommtx}
+% \DescribeMacro{\frompl}
+% \DescribeMacro{\scalefont}
+% \DescribeMacro{\xscalefont}
+% \DescribeMacro{\yscalefont}
+% \DescribeMacro{\slantfont}
+% \DescribeMacro{\reencodefont}
+% The \meta{transformed font} commands are:
+% \begin{quote}
+% |\fromafm|\marg{AFM file}\\
+% |\frompl|\marg{PL file}\\
+% |\fromplgivenetx|\marg{PL file}\marg{etx}\\
+% |\frommtx|\marg{MTX file}\\
+% |\fromany|\marg{file}\\
+% |\scalefont|\marg{integer expression}\marg{transformed font}\\
+% |\xscalefont|\marg{integer expression}\marg{transformed font}\\
+% |\yscalefont|\marg{integer expression}\marg{transformed font}\\
+% |\slantfont|\marg{integer expression}\marg{transformed font}\\
+% |\reencodefont|\marg{etx}\marg{transformed font}
+% \end{quote}
+%
+% Each |\transformfont| command generates an |.mtx| file for
+% \meta{font-name} and a corresponding raw |.pl| file, which is written
+% out by |\mtxtopl|.
+%
+% Each |\fromafm|, |\frompl|, or |\fromplgivenetx| command also generates
+% an |.mtx| file for the source font, which is written out by |\afmtomtx|
+% or |\generalpltomtx|. In addition, |\fromafm| also uses |\mtxtopl|
+% to generate a corresponding raw |.pl| file.
+%
+% |\fromany| reads an MTX, PL, AFM, or VPL file depending on what it can
+% find. It tries them in the order first MTX, then PL, then AFM, and
+% last VPL.
+%
+% \begin{macro}{\transformfont}
+% \changes{1.912}{2000/01/15}{Added local resetting of
+% \cs{setsomething_global} to \cs{relax}, since \cs{transformfont}
+% assumes such assignments are local. (LH)}
+% \begin{macrocode}
+\def\transformfont#1#2{{
+ \let\setsomething_global=\x_relax
+ \unsetstr{afm-name}
+ \unsetstr{etx-name}
+ \x_resetint{x-scale}{\one_thousand}
+ \x_resetint{y-scale}{\one_thousand}
+ \x_resetint{slant-scale}{0}
+ #2
+% \end{macrocode}
+% \changes{1.903}{1999/06/01}{Added behaviour for the case source file
+% not found. (LH)}
+% \changes{1.921}{2002/07/31}{Corrected an error message that tried
+% to use a variable that wasn't set! (LH)}
+% \begin{macrocode}
+ \ifisstr{afm-name}\then
+ \mtxtomtx{\str{afm-name}}{#1}
+ \mtxtopl{#1}{#1}
+ \else
+ \fontinsterror{Transformfont}{
+ Failed~to~make~transformed~font~#1;\messagebreak
+ source~font~metrics~file~not~found
+ }\error_help_a
+ \fi
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fromafm}
+% \changes{1.904}{1999/06/17}{Added call of \cs{record_transform}. (LH)}
+% \changes{1.911}{1999/11/19}{Added test for file existence. (LH)}
+% \begin{macrocode}
+\def\fromafm#1{
+ \if_file_exists{#1.afm}\then
+ \x_setstr{afm-name}{#1}
+ \afmtomtx{#1}{#1}
+ \mtxtopl{#1}{#1}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+% \begin{macro}{\frommtx}
+% \changes{1.911}{1999/11/19}{Added test for file existence. (LH)}
+% \begin{macrocode}
+\def\frommtx#1{
+ \if_file_exists{#1.mtx}\then \x_setstr{afm-name}{#1} \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\frompl}
+% \changes{1.904}{1999/06/17}{Added call of \cs{record_transform}. (LH)}
+% \changes{1.911}{1999/11/19}{Added test for file existence. (LH)}
+% \begin{macro}{\fromplgivenetx}
+% \changes{1.902}{1999/05/02}{Command added. (LH)}
+% \changes{1.904}{1999/06/17}{Added call of \cs{record_transform}. (LH)}
+% \changes{1.911}{1999/11/19}{Added test for file existence. (LH)}
+% \begin{macrocode}
+\def\frompl#1{
+ \if_file_exists{#1.pl}\then
+ \x_setstr{afm-name}{#1}
+ \generalpltomtx{#1}{#1}{pl}{}
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\fromplgivenetx#1#2{
+ \if_file_exists{#1.pl}\then
+ \x_setstr{afm-name}{#1}
+ \generalpltomtx{#1}{#1}{pl}{#2}
+ \fi
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+% \multchanges{\cs{fromvpl}\cs{fromvplgivenetx}}{1.902}{1999/05/02}
+% {Commands added. (LH)}
+% \multchanges{\cs{fromvpl}\cs{fromvplgivenetx}}{1.904}{1999/06/16}
+% {Commands removed. (LH)}
+% Regarding \cs{fromvpl} and \cs{fromvplgivenetx}: I realized that
+% there isn't any point in reading metrics for a font that is to be
+% transformed from a VPL file, since no driver I know of can transform
+% virtual fonts. If someone has a problem with this then I suppose he
+% or she should send word about it. /LH
+%
+%
+% \begin{macro}{\fromany}
+% \changes{1.903}{1999/05/20}{Command added. (LH) Based on a
+% suggestion by Vladimir Volovich.}
+% \changes{1.903}{1999/06/01}{Added behaviour for AFM not found case.
+% (LH)}
+% \changes{1.904}{1999/06/16}{Added search for VPL file and calls to
+% \cs{record_transform}. (LH)}
+% \changes{1.923}{2002/12/03}{Added \cs{pl_encoding}. (LH)}
+% \changes{1.926}{2003/07/10}{Removed \cs{pl_encoding}; it is better
+% to provide that functionality in a separate macro. (LH)}
+% \changes{1.926}{2003/07/10}{Has to reset the \texttt{afm-name}
+% string, since \cs{input_mtx_file} now uses the value. (LH)}
+% The |\fromany| transformed font command searches for font metrics
+% for \#1 by looking for, in turn, the files \#1|.mtx|, \#1|.pl|,
+% \#1|.afm|, and \#1|.vpl|. If an MTX file doesn't exist, it is
+% generated, and if the MTX is generated from an AFM then a
+% corresponding (non-ligful) PL file is generated as well. |\fromany|
+% also sets the fontinst string \texttt{afm-name} according
+% to what kind of font it found. If none of the fonts existed then
+% |afm-name| is unset.
+% \begin{macrocode}
+\def\fromany#1{
+ \x_cs\edef{s-afm-name}{#1}
+ \if_file_exists{#1.mtx}\then\else
+% \end{macrocode}
+%
+% \changes{1.6}{1997/01/15}{Search order changed to PL before AFM.
+% (SPQR) The code wasn't in \cs{fromany} back then, though.}
+% 1997/01/15 SPQR changed the below search order to |.pl| before |.afm|
+% because of the |cmr*.afm| files found in the |TEXMF|\slash
+% |fonts|\slash|afm| hierarchy.
+% \begin{macrocode}
+ \if_file_exists{#1.pl}\then
+ \generalpltomtx{#1}{#1}{pl}{}
+ \else
+ \if_file_exists{#1.afm}\then
+ \afmtomtx{#1}{#1}
+ \mtxtopl{#1}{#1}
+ \else
+ \if_file_exists{#1.vpl}\then
+ \generalpltomtx{#1}{#1}{vpl}{}
+ \else
+ \unsetstr{afm-name}
+ \fi\fi\fi\fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsubsection*{The mathematical basis for the metric font transformations}
+%
+% Mathematically, all the metric font transformations (|\scale|\-|font|,
+% |\xscale|\-|font|, |\yscale|\-|font|, and |\slant|\-|font|) are linear
+% mappings of the real plane onto itself. All quantities in a
+% transformable metric file are interpreted as being determined by some
+% point in this plane and hence their transformation depends on how that
+% point would be moved by the metric font transformations performed.
+% This is usually simpler than it sounds, since all quantities except
+% |italicslant| are interpreted as either the $x$- or the $y$-coordinate
+% of some point. |italicslant| is interpreted as the quotient
+% $\frac{x}{y}$ for a point.
+%
+% The best way to describe a linear mapping of the real plane to itself
+% is by a \(2 \times 2\) matrix whose components are real numbers. Since
+% true real numbers are not available in \TeX, integers are used instead,
+% with the convention that they are in units of thousandths. In a
+% concrete form this means that $0$ represents $0$, $500$ represents
+% $\frac{1}{2}$, $1000$ represents $1$, etc. This works just as for the
+% scaling factors used in |\scale|. It also means that the matrix
+% $$
+% \left(\begin{array}{cc} 1000 & 0 \\ 0 & 1000 \end{array}\right)
+% $$
+% represents the identity mapping (the mapping taking everything to
+% itself).
+%
+% Thinking of points as column vectors (\(2 \times 1\) matrices) with
+% the $x$-coordinate in the first component and the $y$-coordinate in
+% the second, the respective elementary metric font transformations
+% correspond to the following matrices:
+% \begin{eqnarray*}
+% \mbox{\cs{scalefont}\marg{n}} & \mbox{is} &
+% \left( \begin{array}{cc}
+% \mbox{\meta{n}}& 0 \\
+% 0 & \mbox{\meta{n}}
+% \end{array} \right) \\
+% \mbox{\cs{xscalefont}\marg{n}} & \mbox{is} &
+% \left( \begin{array}{cc}
+% \mbox{\meta{n}}& 0 \\
+% 0 & 1000
+% \end{array} \right) \\
+% \mbox{\cs{yscalefont}\marg{n}} & \mbox{is} &
+% \left( \begin{array}{cc}
+% 1000 & 0 \\
+% 0 & \mbox{\meta{n}}
+% \end{array} \right) \\
+% \mbox{\cs{slantfont}\marg{n}} & \mbox{is} &
+% \left( \begin{array}{cc}
+% 1000 & \mbox{\meta{n}} \\
+% 0 & 1000
+% \end{array} \right)
+% \end{eqnarray*}
+% Since all these matrices are upper triangular, all products of such
+% matrices (corresponding to compositions of the linear mappings) will be
+% upper triangular as well. It is therefore unnecessary to store the
+% subdiagonal component anywhere (it is always zero), and hence
+% \package{fontinst} represents an arbitrary metric transform by the
+% matrix
+% $$
+% \left( \begin{array}{cc}
+% \mbox{\texttt{x-scale}} & \mbox{\texttt{slant-scale}} \\
+% 0 & \mbox{\texttt{y-scale}}
+% \end{array} \right)
+% $$
+% where \texttt{x-scale}, \texttt{y-scale}, and \texttt{slant-scale}
+% are fontinst integers.
+%
+% The reason there is a representation of arbitrary metric transforms
+% is that all the elementary metric transforms listed in the second
+% argument of |\transformfont| are concatenated before the actual font
+% file conversion is made. This reduces the amount of calculations
+% performed in case there are many transformations of the font.
+%
+% Why do we only consider transformations that correspond to upper
+% triangular matrices? Well, a transformation corresponds to an upper
+% triangular matrix if and only if it leaves horizontal lines horizontal.
+% Since in particular the baseline must always be horizontal in \TeX,
+% there is no point in considering other linear transformations.
+%
+% \begin{macro}{\scalefont}
+% \begin{macro}{\xscalefont}
+% \begin{macro}{\yscalefont}
+% \begin{macro}{\slantfont}
+% \begin{macro}{\reencodefont}
+% \begin{macrocode}
+\def\scalefont#1#2{
+ \eval_expr_to\d_count{#1}
+ \x_resetint{x-scale}{\scale{\d_count}{\int{x-scale}}}
+ \x_resetint{y-scale}{\scale{\d_count}{\int{y-scale}}}
+ \x_resetint{slant-scale}{\scale{\d_count}{\int{slant-scale}}}
+ #2
+}
+\def\xscalefont#1#2{
+ \x_resetint{x-scale}{\scale{#1}{\int{x-scale}}}
+ #2
+}
+\def\yscalefont#1#2{
+ \eval_expr_to\d_count{#1}
+ \x_resetint{y-scale}{\scale{\d_count}{\int{y-scale}}}
+ \x_resetint{slant-scale}{\scale{\d_count}{\int{slant-scale}}}
+ #2
+}
+\def\slantfont#1#2{
+ \x_resetint{slant-scale}{
+ \add{\scale{#1}{\int{x-scale}}}{\int{slant-scale}}
+ }
+ #2
+}
+\def\reencodefont#1#2{
+ #2
+ \resetstr{etx-name}{#1}
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% That's only half the story, however. It is true that the transformation
+% matrix, as computed by |\scalefont|, |\slantfont|, |\xscalefont|, and
+% |\yscalefont| above, is used for transforming the font metrics, but it
+% is not directly used for transforming the font itself. Instead it is
+% factorized as
+% $$
+% \left( \begin{array}{cc}
+% x & s \\ 0 & y
+% \end{array} \right) =
+% y \left( \begin{array}{cc}
+% x/y & s/y \\ 0 & 1
+% \end{array} \right)
+% $$
+% Here the scalar factor $y$ will be used to scale the \meta{scale}
+% argument of |\set|\-|scaled|\-|raw|\-|glyph| and
+% |\set|\-|scaled|\-|not|\-|glyph| commands, whereas the matrix
+% factor will be put in the third argument of |\store|\-|map|\-|data|
+% in the MTX file written. Thus \package{fontinst} will handle the
+% scalar factor of the transformation itself, but leave the matrix
+% factor for some other software to take care of.
+%
+% \bigskip
+%
+%
+% \DescribeMacro{\mtxtomtx}
+% The macro:
+% \begin{quote}
+% |\mtxtomtx|\marg{source MTX}\marg{destination MTX}
+% \end{quote}
+% converts the first |.mtx| file to the second, using the current values
+% of |\int{x-scale}|, |\int{y-scale}|, |\int{slant-scale}|, and
+% |\str{etx-name}|.
+%
+% NOTE: this doesn't convert arbitrary |.mtx| files, just the
+% transformable ones.
+%
+% \begin{macro}{\mtxtomtx}
+% \changes{1.911}{1999/11/19}{\cs{edef}ing \cs{raw_font_name}. (LH)}
+% \changes{1.915}{2000/09/09}{Locally redefining \cs{aliased}. (LH)}
+% \changes{1.924}{2003/02/08}{Added \cs{directfalse}. (LH)}
+% \changes{1.931}{2005/05/13}{Placed ETX processing after
+% \cs{needsfontinstversion} had been written, so that ETX commands
+% can write data directly to the output MTX file. (LH)}
+% \changes{1.931}{2005/05/13}{Copying \cs{declarepsencoding} data to
+% generated MTX file as a \cs{setpsencoding} command. (LH)}
+% \begin{macrocode}
+\def\mtxtomtx#1#2{{
+ \let\a_macro=\empty_command
+ \_a_true
+ \ifnum \int{x-scale}=\int{y-scale}
+ \ifnum \int{slant-scale}=\z@
+ \_a_false
+ \fi \fi
+ \if_a_
+ \a_count=\int{x-scale}
+ \l_inv_scale\a_count{\int{y-scale}}
+ \b_count=\int{slant-scale}
+ \l_inv_scale\b_count{\int{y-scale}}
+ \edef\a_macro{\a_macro
+ \string\transformfont{\the\a_count}{\the\b_count}
+ }
+ \fi
+ \open_out{\temp_prefix#2.mtx}
+ \edef\raw_font_name{#2}
+ \out_line{\percent_char~Filename:~#2.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\mtxtomtx{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \ifisstr{etx-name}\then
+ \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}}
+ \def\declarepsencoding##1##2##3{
+ \a_toks={{##1}{##2}{##3}}
+ \out_line{\string\providepsencoding\the\a_toks}
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file
+ {\string\providepsencoding\the\a_toks}
+ \fi
+ }
+ \directfalse
+ \inputetx{\str{etx-name}}
+ \edef\a_macro{\a_macro\string\reencodefont{\str{etx-name}}}
+ \fi
+ \record_transform{#2}{\string\frommtx{#1}}{\a_macro}\iftrue
+ \out_line{}
+ \mtxtomtx_redefinitions
+ \inputmtx{#1}
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Transformed~metrics}
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\mtxtomtx_redefinitions}
+% This macro serves as a hook. One can make additional commands
+% transformable by appending suitable redefenitions of them to this
+% macro.
+% \changes{1.927}{2003/12/08}{Macro added. The code used to be in
+% \cs{mtxtomtx}. (LH)}
+% \begin{macrocode}
+\def\mtxtomtx_redefinitions{
+ \let\setint=\mtxtomtx_setint
+ \let\setdim=\mtxtomtx_setdim
+ \let\setstr=\mtxtomtx_setstr
+ \let\setscaledrawglyph=\mtxtomtx_setscaledrawglyph
+ \let\setscalednotglyph=\mtxtomtx_setscaledrawglyph
+ \let\setkern=\mtxtomtx_setkern
+ \let\setglyph=\mtxtomtx_setglyph
+ \let\glyphpcc=\mtxtomtx_glyphpcc
+ \let\samesize=\mtxtomtx_samesize
+ \let\endsetglyph=\mtxtomtx_endsetglyph
+ \def\aliased{\string\aliased}
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\aliased}
+% \changes{1.915}{2000/09/09}{Macro added. (LH)}
+% The |\aliased| macro has the syntax
+% \begin{quote}
+% |\aliased|\marg{font's name}\marg{alias name}
+% \end{quote}
+% This normally expands to \meta{alias name}, but in |\mtxtomtx| it
+% normally expands to
+% \begin{quote}
+% |\string\aliased|\marg{font's name}\marg{alias name}
+% \end{quote}
+% and when |\mtxtomtx_setscaledrawglyph| is reencoding it uses
+% \meta{font's name} to determine the new slot position.
+% \begin{macrocode}
+%<pkg|misc>\let\aliased=\second_of_two
+%<doc>\let\aliased=\@secondoftwo
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\mtxtomtx_setint}
+% \changes{1.917}{2001/03/24}{Redefined to allow an extensible list
+% \cs{width_ints_list} of integers that should be transformed as
+% widths. (LH)}
+% \begin{macro}{\italicslant_name}
+% \begin{macro}{\width_ints_list}
+% \changes{1.917}{2001/03/24}{Macro added. \cs{verticalstem_name}
+% removed. (LH)}
+% Most integers are transformed as if they are the $y$-coordinates of
+% some points, but |italicslant| and the integers in the
+% |\width_ints_list| are treated differently. |italicslant| is
+% interpreted as the quotient $\frac{x}{y}$ for a point $(x,y)$, but
+% represented as a real number (i.e., the \TeX\ number is really a
+% thousand times the actual quotient). The integers in the
+% |\width_ints_list| are transformed as if they are the
+% $x$-coordinates of some points on the baseline.
+%
+% The |\width_ints_list| macro is an ordinary |\do|-type list where
+% each |\do| has precisely one argument. These arguments are the names
+% of the integers which should be transformed as widths. Elements can
+% be added to the list using the |\add_to| macro.
+%
+% The test for whether a specific integer is in the |\width_ints_list|
+% exploits that |\if_true| and |\if_false| only matter in |\if|--|\fi|
+% matching after they have been expanded, whereas
+% |\gobble_one|\,|\iftrue| only matters before it is expanded.
+% \begin{macrocode}
+%<*pkg>
+\def\mtxtomtx_setint#1#2{
+ \def\a_macro{#1}
+ \ifx \a_macro\italicslant_name
+ \eval_expr{#2}
+ \global\multiply \result \int{x-scale}
+ \a_count=\int{slant-scale}
+ \multiply \a_count \one_thousand
+ \advance \a_count \result
+ \divide \a_count \int{y-scale}\x_relax
+ \else
+ \def\do##1{
+ \def\b_macro{##1}
+ \ifx \a_macro\b_macro \expandafter\if_false \fi
+ }
+ \gobble_one\iftrue \width_ints_list \if_true
+ \eval_expr_to\a_count{\scale{#2}{\int{y-scale}}}
+ \else
+ \eval_expr_to\a_count{\scale{#2}{\int{x-scale}}}
+ \fi
+ \fi
+ \out_line{\string\setint{#1}{\the\a_count}}
+}
+\def\italicslant_name{italicslant}
+\def\width_ints_list{
+ \do{interword}\do{stretchword}\do{shrinkword}\do{quad}
+ \do{extraspace}\do{digitwidth}\do{verticalstem}
+}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\mtxtomtx_setdim}
+% \begin{macro}{\mtxtomtx_setstr}
+% Strings and dimens are not affected by the |\mtxtomtx| transforms.
+% \begin{macrocode}
+\def\mtxtomtx_setdim#1#2{
+ \out_line{\string\setdim{#1}{#2}}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\mtxtomtx_setstr#1#2{
+ \out_line{\string\setstr{#1}{#2}}
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+% \begin{macro}{\mtxtomtx_setscaledrawglyph}
+% \changes{1.915}{2000/09/09}{Added local redefinition of
+% \cs{aliased}. (LH)}
+% |#6| (the width) is transformed as the $x$-coordinate of a point on
+% the baseline. |#7| and |#8| (the height and depth respectively) are
+% transformed as $y$-coordinates. The depth should probably really have
+% been transformed as the negative of a $y$-coordinate, but it comes
+% out the same in the end anyway. |#9| (the italic correction) is
+% transformed as the $x$-coordinate of a point whose $y$-coordinate
+% equals the height of the character. |#4| (the scaling) is
+% transformed as a $y$-coordinate.
+%
+% If the italic slant of the font is negative then the italic
+% correction should possibly be transformed as the $x$-coordinate of
+% a point whose $y$-coordinate equals the negative of the depth
+% instead (as that is the part of the box that is sticking out to the
+% right), but it is hard to say for sure how that case should be
+% treated.
+%
+% \begin{macrocode}
+\def\mtxtomtx_setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \eval_expr_to\a_count{\scale{#6}{\int{x-scale}}}
+ \eval_expr_to\b_count{\scale{#7}{\int{y-scale}}}
+ \eval_expr_to\c_count{\scale{#8}{\int{y-scale}}}
+ \eval_expr_to\d_count{#9} \eval_expr{#7}
+ \multiply \d_count \int{x-scale}
+ \global\multiply \result \int{slant-scale}
+ \global\advance \result \d_count
+ \rounded_thousandths
+ \d_count=\result
+ \eval_expr{\scale{#4}{\int{y-scale}}}
+ \ifisstr{etx-name}\then
+ \bgroup
+ \let\aliased=\first_of_two
+ \if_undefined{slots-#1}\then
+ \egroup \e_count=\m@ne
+ \else
+ \expandafter\egroup \expandafter\e_count
+ \csname slots-#1\endcsname
+ \fi
+ \else
+ \e_count=#5
+ \fi
+ \out_line{
+ \ifnum \e_count>\m@ne
+ \string\setscaledrawglyph
+ \else
+ \string\setscalednotglyph
+ \fi
+ {#1}{\raw_font_name}{#3}{\the\result}{\the\e_count}
+ {\the\a_count}{\the\b_count}{\the\c_count}{\the\d_count}
+ }
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\mtxtomtx_setkern}
+% Kerns are transformed as the $x$-coordinate of a point on the
+% baseline.
+%
+% \begin{macrocode}
+\def\mtxtomtx_setkern#1#2#3{
+ \eval_expr{\scale{\int{x-scale}}{#3}}
+ \out_line{\string\setkern{#1}{#2}{\the\result}}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\mtxtomtx_setglyph}
+% \begin{macro}{\mtxtomtx_samesize}
+% \begin{macro}{\mtxtomtx_endsetglyph}
+% \begin{macrocode}
+\def\mtxtomtx_setglyph#1{\out_line{\string\setglyph{#1}}}
+\def\mtxtomtx_samesize#1{\out_lline{\string\samesize{#1}}}
+\def\mtxtomtx_endsetglyph{\out_line{\string\endsetglyph}}
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro}
+%
+% \begin{macro}{\mtxtomtx_glyphpcc}
+% |#2| is transformed as the $x$-coordinate and |#3| is transformed
+% as the $y$-coordinate of a point---the same point for both
+% parameters.
+%
+% \begin{macrocode}
+\def\mtxtomtx_glyphpcc#1#2#3{
+ \eval_expr_to\b_count{\scale{\int{y-scale}}{#3}}
+ \eval_expr_to\a_count{#2} \eval_expr{#3}
+ \multiply \a_count \int{x-scale}
+ \global\multiply \result \int{slant-scale}
+ \global\advance \result \a_count
+ \rounded_thousandths
+ \out_lline{\string\glyphpcc{#1}{\the\result}{\the\b_count}}
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Changing glyph names}
+% \label{Ssec:Reglyph}
+%
+% \package{fontinst} uses names to identify glyphs, and if for example
+% the font in question is a postscript font, then names will also be used
+% to identify glyphs in the printer. Between those two points however,
+% and in particular inside \TeX\ itself, glyphs are represented with
+% numbers (slots). Therefore there is no real need for the glyph names
+% used within \package{fontinst} and the glyph names used in the printer
+% (the names gotten from the AFM file) to be equal, but they usually are.
+% There are some cases though where the glyph names of a font are
+% unsuitable for use with \package{fontinst}---mainly because
+% \package{fontinst} can mix glyphs from different printer fonts---and
+% therefore \package{fontinst} also offers the ability to automatically
+% change the names of glyphs in transformable metric files.
+%
+% \begin{macro}{\reglyphfonts}
+% \changes{1.912}{2000/01/15}{Added local resetting of
+% \cs{setsomething_global} to \cs{relax}. It shouldn't be needed,
+% since \cs{reglyphfonts} should not occur between \cs{installfonts}
+% and \cs{endinstallfonts}, but I bet someone will try. (LH)}
+% \begin{macro}{\endreglyphfonts}
+% \begin{quote}
+% |\reglyphfonts| \meta{reglyphing commands} |\endreglyphfonts|
+% \end{quote}
+% \begin{macrocode}
+\def\reglyphfonts{
+ \begingroup
+ \let\setsomething_global=\x_relax
+ \x_setint{renameweight}{1}
+ \x_setint{killweight}{-10}
+ \setcommand\iftokeep##1\then{\ifnum -1<##1}
+}
+\def\endreglyphfonts{\endgroup}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% The \meta{reglyphing commands} are
+% \begin{quote}
+% |\renameglyph|\marg{to}\marg{from}\\
+% |\renameglyphweighted|\marg{to}\marg{from}\marg{weight}\\
+% |\killglyph|\marg{glyph}\\
+% |\killglyphweighted|\marg{glyph}\marg{weight}\\
+% |\offmtxcommand|\marg{command}\\
+% |\onmtxcommand|\marg{command}\\
+% |\reglyphfont|\marg{destination font}\marg{source font}
+% \end{quote}
+% The only reglyphing command that actually convert the names of any
+% glyphs is \DescribeMacro{\reglyphfont}|\reglyph|\-|font|; it reads a font
+% \meta{source font} (which may be of type MTX, PL, AFM, or VPL) and
+% writes another font \meta{destination font} in which the names of
+% glyphs have been converted. All the other commands control \emph{how}
+% this conversion should be made, and these settings get cleared at the
+% closing |\endreglyphfonts|.
+%
+% The conversion works in two ways. First of all, the names of the
+% glyphs can be changed. This works as a general mapping and is
+% controlled by the \DescribeMacro{\renameglyph}|\renameglyph| and
+% \DescribeMacro{\renameglyphweighted}|\renameglyphweighted|
+% commands. Any mensioning of the glyph \meta{from} in a command will be
+% converted to a mensioning of the glyph \meta{to}, if that command
+% survives the conversion. The other way the conversion works is that it
+% can selectively kill---refrain from including in \meta{destination
+% font}---commands in the metric file. This part weighs in several
+% factors.
+%
+% For one thing, one can specify that all metric commands of a certain
+% type should be killed, and this is done with the
+% \DescribeMacro{\offmtxcommand}|\offmtxcommand| command. For example,
+% one can see to that all kerning commands are killed by
+% \begin{quote}
+% |\offmtxcommand{\setkern}|
+% \end{quote}
+% The effect is the same as that of saying
+% \begin{quote}
+% |offkern,|\meta{destination font}|,onkern|
+% \end{quote}
+% rather than just \meta{destination font} in the second argument to
+% |\installfont|, but it is somewhat faster since less text is written
+% to and subsequently read from the \meta{destination font}|.mtx| file.
+% The effect of a previous |\offmtxcommand| can be canceled by a call to
+% \DescribeMacro{\onmtxcommand}|\onmtxcommand|, just like with
+% |\offcommand| and |\oncommand|.
+%
+% The survivance of a command is also affected by the glyphs it refers to.
+% Each glyph has a \emph{weight} associated with it and the sum of the
+% weights for all glyphs mensioned by a command is also used to decide
+% whether that command should survive. The test here is performed by the
+% macro \DescribeMacro{\iftokeep}|\iftokeep|, whose parameter text
+% must be |#1\then|, where |#1| will be a |\count| register. This
+% macro must eventually expand to an if of some sort and that if
+% evaluating to true is interpreted as that the command should be kept.
+% The default replacement text is |\ifnum -1<#1|, which causes a command
+% to be killed (not kept) iff the sum of weights for it is negative.
+%
+% The weight of a glyph is set by |\rename|\-|glyph|,
+% |\rename|\-|glyph|\-|weighted|,
+% \DescribeMacro{\killglyph}|\kill|\-|glyph|, and
+% \DescribeMacro{\killglyphweighted}|\kill|\-|glyph|\-|weighted|. The
+% |\rename|\textellipsis\ commands also set a new name for the glyph if
+% it survives, whereas the |\kill|\textellipsis\ commands will keep the
+% old name. Since the standard settings are that a
+% |\rename|\textellipsis\ weight is small and positive and a
+% |\kill|\textellipsis\ weight is large and negative, glyphs for which
+% a |\kill|\textellipsis\ has been done will usually not survive.
+%
+% Any one of |\rename|\-|glyph|, |\rename|\-|glyph|\-|weighted|,
+% |\kill|\-|glyph|, and |\kill|\-|glyph|\-|weighted| for a glyph will
+% override all previous settings
+% by any of these four commands for that glyph. The equivalent of the
+% neutral state for a glyph (no settings by any of these commands have
+% been made for that glyph) is achieved by the command
+% \begin{quote}
+% |\killglyphweighted|\marg{glyph}|{0}|
+% \end{quote}
+%
+%
+% \begin{macro}{\offmtxcommand}
+% \begin{macro}{\onmtxcommand}
+% These two are just special forms of |\offcommand| and |\oncommand|.
+% \begin{macrocode}
+\def\offmtxcommand#1{
+ \x_cs\offcommand{reglyph_\expandafter\gobble_one\string#1}
+}
+\def\onmtxcommand#1{
+ \x_cs\oncommand{reglyph_\expandafter\gobble_one\string#1}
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \describecsfamily{slots-\meta{glyph}}Inside a |\reglyphfonts|
+% \textellipsis\ |\endreglyphfonts| block, the family
+% |\slots-|\meta{glyph} of control sequences is used to store the
+% information about how glyph \meta{glyph} should be converted. These
+% control sequences are either undefined or parameterless macros
+% whose replacement texts are of one of the forms
+% \begin{quote}
+% |\rename_glyph|\marg{to}\marg{weight}\\
+% |\rename_glyph|\marg{to}|\i-renameweight|\\
+% |\kill_glyph|\marg{weight}\\
+% |\kill_glyph\i-killweight|
+% \end{quote}
+% \meta{to} is what the glyph will be renamed to and \meta{weight} is
+% the associated weight. These four different forms are generated by
+% the four different commands |\renameglyphweighted|, |\renameglyph|,
+% |\killglyphweighted|, and |\killglyph| respectively.
+%
+% \begin{macro}{\renameglyph}
+% \begin{macro}{\renameglyphweighted}
+% The difference between the commands |\renameglyphweighted| and
+% |\renameglyph| is that the former lets one specify the weight exactly
+% while the latter will use the value of the integer |renameweight|
+% \emph{at the time of conversion}. By changing the value of
+% |renameweight| between two conversions, one changes the weights
+% used for all glyph renamings declared using |\renameglyph|.
+% \begin{macrocode}
+\begingroup
+ \catcode`\-=11
+ \gdef\renameglyph#1#2{
+ \x_cs\edef{slots-#2}{
+ \noexpand\rename_glyph{#1}\noexpand\i-renameweight
+ }
+ }
+\endgroup
+% \end{macrocode}
+% \begin{macrocode}
+\def\renameglyphweighted#1#2#3{
+ \eval_expr{#3}
+ \x_cs\edef{slots-#2}{\noexpand\rename_glyph{#1}{\the\result}}
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+% \begin{macro}{\killglyph}
+% \begin{macro}{\killglyphweighted}
+% The difference between the commands |\killglyphweighted| and
+% |\killglyph| is that the former lets one specify the weight exactly
+% while the latter will use the value of the integer |killweight|
+% \emph{at the time of conversion}. By changing the value of
+% |killweight| between two conversions, one changes the weights
+% used for all glyph killings declared using |\killglyph|.
+% \begin{macrocode}
+\begingroup
+ \catcode`\-=11
+ \gdef\killglyph#1{
+ \x_cs\def{slots-#1}{\kill_glyph\i-killweight}
+ }
+\endgroup
+% \end{macrocode}
+% \begin{macrocode}
+\def\killglyphweighted#1#2{
+ \eval_expr{#2}
+ \x_cs\edef{slots-#1}{\noexpand\kill_glyph{\the\result}}
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\reglyphfont}
+% The command
+% \begin{quote}
+% |\reglyphfont|\marg{destination font}\marg{source font}
+% \end{quote}
+% reads the font metric file \meta{source font}|.mtx| (which must be
+% transformable), \meta{source font}|.pl|, or \meta{source font}|.afm|
+% (the possibilities are tried in that order) and writes out a font
+% metric file \meta{destination font}|.mtx| that is the converted (as
+% described above) form of the source font.
+%
+% \meta{destination font} and \meta{source font} may not be equal.
+% \changes{1.903}{1999/06/01}{Using \cs{fromany} for locating font.
+% (LH)}
+% \changes{1.904}{1999/06/16}{Added \cs{record_transform}. (LH)}
+% \begin{macrocode}
+\def\reglyphfont#1#2{
+ \fromany{#2}
+ \ifisstr{afm-name}\then
+ \reglyph_font{#1}{#2}
+ \else
+ \fontinsterror{Reglyph}{Could~not~find~font~metrics~for~#2.}
+ \error_help_a
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\reglyph_font}
+% This macro does the actual conversion.
+% \begin{macrocode}
+\def\reglyph_font#1#2{{
+ \open_out{\temp_prefix#1.mtx}
+ \out_line{\percent_char~Filename:~#1.mtx}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using:~\string\reglyphfont{#1}{#2}}
+ \out_line{}
+ \out_line{\percent_char~This~file~is~used~by~the~fontinst~package.}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~CAN~BE~DELETED.}
+ \out_line{}
+ \out_line{\string\relax}
+ \out_line{\string\metrics}
+ \out_line{}
+ \out_line{\string\needsfontinstversion{\fontinstversion}}
+ \out_line{}
+ \record_transform{#1}{\string\frommtx{#2}}{\string\reglyphfont}
+ \iftrue
+ \out_line{}
+ \reglyph_redefinitions
+ \inputmtx{#2}
+ \out_line{}
+ \out_line{\endmetrics_text}
+ \close_out{Reglyphed~metrics}
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\reglyph_redefinitions}
+% This macro serves as a hook. One can make additional commands
+% transformable by appending suitable redefenitions of them to this
+% macro.
+% \changes{1.927}{2003/12/08}{Macro added. The code used to be in
+% \cs{reglyph_font}. (LH)}
+% \begin{macrocode}
+\def\reglyph_redefinitions{
+ \let\setint=\reglyph_setint
+ \let\setdim=\reglyph_setdim
+ \let\setstr=\reglyph_setstr
+ \let\setscaledrawglyph=\reglyph_setscaledrawglyph
+ \let\setscalednotglyph=\reglyph_setscaledrawglyph
+ \let\setkern=\reglyph_setkern
+ \let\setglyph=\reglyph_setglyph
+ \let\glyphpcc=\reglyph_glyphpcc
+ \let\samesize=\reglyph_samesize
+ \let\endsetglyph=\reglyph_endsetglyph
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\reglyph_setint}
+% \begin{macro}{\reglyph_setdim}
+% \begin{macro}{\reglyph_setstr}
+% These are just copied to the file generated.
+% \begin{macrocode}
+\def\reglyph_setint#1#2{\out_line{\string\setint{#1}{#2}}}
+\def\reglyph_setdim#1#2{\out_line{\string\setdim{#1}{#2}}}
+\def\reglyph_setstr#1#2{\out_line{\string\setstr{#1}{#2}}}
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro}
+%
+% \begin{macro}{\command_survivance}
+% This |\count| register stores the sum of the weights associated
+% with the glyphs considered so far. It is updated by |\rename_glyph|
+% and |\kill_glyph|.
+% \begin{macrocode}
+\newcount\command_survivance
+% \end{macrocode}
+% \end{macro}
+%
+% The macro \DescribeMacro{\glyphname}|\glyphname| holds the name of
+% the glyph currently under consideration. It is altered by
+% |\rename_glyph|.
+%
+% \begin{macro}{\rename_glyph}
+% \begin{macro}{\kill_glyph}
+% \begin{macrocode}
+\def\rename_glyph#1{\def\glyphname{#1}\kill_glyph}
+\def\kill_glyph#1{\advance \command_survivance #1\x_relax}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\reglyph_setscaledrawglyph}
+% \changes{1.915}{2000/06/25}{Corrected bug in the \cs{ifnum}: it
+% should test argument \#5, not \#4. (LH) Encountered by Thierry
+% Bouche.}
+% The |\reglyph_|\-|setscaled|\-|rawglyph| macro is straightforward.
+% Whether it writes a |\setscaled|\-|rawglyph| or a |\setscaled|\-^^A
+% |notglyph| command depends on the fifth parameter, just like with
+% |\mtxtomtx_|\-|setscaled|\-|rawglyph|.
+% \begin{macrocode}
+\def\reglyph_setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{
+ \ifnum #5<\z@
+ \string\setscalednotglyph
+ \else
+ \string\setscaledrawglyph
+ \fi
+ {\glyphname}{#2}{#3}{\number#4}{#5}{#6}{#7}{#8}{#9}
+ }
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\reglyph_setkern}
+% \begin{macrocode}
+\def\reglyph_setkern#1#2#3{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \let\a_macro=\glyphname
+ \def\glyphname{#2}
+ \csname slots-#2\endcsname
+ \iftokeep\command_survivance\then
+ \out_line{\string\setkern{\a_macro}{\glyphname}{#3}}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\reglyph_setglyph}
+% \multchanges{\cs{reglyph_glyphpcc}\cs{reglyph_samesize}^^A
+% \cs{reglyph_setglyph}}{1.911}{1999/12/10}{\cs{string}
+% which should be \cs{noexpand} corrected. (LH) Reported by
+% Rolf Lindgren.}
+% \begin{macro}{\off-\reglyph_setglyph}
+% \begin{macro}{\reglyph_glyphpcc}
+% \changes{1.911}{1999/12/10}{Typo corrected. (LH) Spotted by Rolf
+% Lindgren.}
+% \begin{macro}{\reglyph_samesize}
+% \begin{macro}{\reglyph_endsetglyph}
+% In |\setglyph| \textellipsis\ |\endsetglyph| constructions (which
+% are written for composite characters in AFM files), the decision of
+% whether to write a command or not due to glyph weights is done
+% only once for the entire construction. This means that the commands
+% must be saved until the |\endsetglyph| where the result is finally
+% known. The token list register |\a_toks| is used for this purpose.
+% \begin{macrocode}
+\def\reglyph_setglyph#1{
+ \command_survivance=0
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_line{\string\setglyph{\glyphname}}}
+ \a_toks=\expandafter{\a_macro}
+}
+\x_cs\def{off-\string\reglyph_setglyph}#1{\gobble_glyph}
+% \end{macrocode}
+% \begin{macrocode}
+\def\reglyph_glyphpcc#1#2#3{
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_lline{
+ \string\glyphpcc{\glyphname}{#2}{#3}
+ }}
+ \a_toks=\expandafter{\the\expandafter\a_toks \a_macro}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\reglyph_samesize#1{
+ \def\glyphname{#1}
+ \csname slots-#1\endcsname
+ \edef\a_macro{\noexpand\out_lline{
+ \string\samesize{\glyphname}
+ }}
+ \a_toks=\expandafter{\the\expandafter\a_toks \a_macro}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\reglyph_endsetglyph{
+ \iftokeep\command_survivance\then
+ \the\a_toks
+ \out_line{\string\endsetglyph}
+ \fi
+ \a_toks={}
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+%
+%
+% \subsubsection*{Three common reglyphing schemes}
+%
+% As is mensioned elsewhere, the most common reglyphing operation is to
+% take a caps and small caps font produced by some major foundry and
+% change the glyph names so that they agree with the glyph names used in
+% expert fonts. The following code contains the modifying reglyphing
+% commands to set up this reglyphing, in two different variants.
+%
+% The commands are currently based on a comparision of Adobe Garamond
+% Small Caps \& Oldstyle Figures (\texttt{padrc8a} in the Berry
+% scheme) with Adobe Garamond Regular Expert (\texttt{padr8x} in the
+% Berry scheme), so they should be correct for a fair amount of Adobe
+% font families, but it is also highly probable that there are lots of
+% fonts out there for which it doesn't work quite right. In case you do
+% find such a font, please write to tell the \package{fontinst} mailing
+% list about it---it would be rather easy to add various alternative
+% set-up schemes, controlled by switches, to these files. Just make sure
+% first (by checking the newest version of \package{fontinst}) that the
+% alternative setting you have found hasn't already been included.
+%
+% As mentioned, there are two different reglyphing schemes that are set
+% up by the code below---one has \package{docstrip} guard \Module{glyphs},
+% the other has guard \Module{!glyphs}---but they both change SC names
+% to Expert names. The difference lies instead in what information is
+% copied from source font to destination font: the \Module{glyphs}
+% variant copies everything, whereas the \Module{!glyphs} variant
+% doesn't copy |\setrawglyph| commands, |\setnotglyph| commands,
+% |\setscaledrawglyph| commands, |\setscalednotglyph| commands or
+% |\setglyph| constructions. The \Module{!glyphs} variant also
+% suppresses kerns between two glyphs that doesn't change name.
+%
+% The motive for having such a curious set-up naturally lies in how the
+% files are meant to be used. If you have SC fonts, but no Expert
+% fonts, then you should definitely use the \Module{glyphs} variant. If
+% on the other hand you have both SC and Expert fonts for a family,
+% then it is worth considering using the \Module{!glyphs} variant instead.
+% The observation this is based on is that within a triad of the
+% corresponding regular, expert, and SC fonts, almost all glyphs present
+% in the SC font can also be found in either the regular or the expert
+% font; furthermore the only missing glyphs were \texttt{FIsmall},
+% \texttt{FLsmall}, and \texttt{SSsmall}, which (i) were included in the
+% SC font only to complete the \texttt{8a} encoding vector and (ii) are
+% identical to \package{fontinst}'s fakes for them.
+%
+% Thus by constructing the \texttt{sc} shape fonts from the regular and
+% expert variants, instead of the SC variant, one can get away with
+% using one raw font less, thus reducing the time needed for downloading
+% the fonts to the printer and the size of the corresponding postscript
+% file. One thing not found in either of the regular or expert font in
+% the triad is however the kerns between capitals and small capitals, but
+% these can be extracted from the metrics of the SC font, and doing this
+% is the primary objective for the \Module{!glyphs} variant.
+%
+% \bigskip
+% \changes{1.906}{1999/08/01}{Reglyphing settings files added. (LH)}
+%
+% First there is the English alphabet:
+% \begin{macrocode}
+%<*reglyphletters>
+\renameglyph{Asmall}{a}
+\renameglyph{Bsmall}{b}
+\renameglyph{Csmall}{c}
+\renameglyph{Dsmall}{d}
+\renameglyph{Esmall}{e}
+\renameglyph{Fsmall}{f}
+\renameglyph{Gsmall}{g}
+\renameglyph{Hsmall}{h}
+\renameglyph{Ismall}{i}
+\renameglyph{Jsmall}{j}
+\renameglyph{Ksmall}{k}
+\renameglyph{Lsmall}{l}
+\renameglyph{Msmall}{m}
+\renameglyph{Nsmall}{n}
+\renameglyph{Osmall}{o}
+\renameglyph{Psmall}{p}
+\renameglyph{Qsmall}{q}
+\renameglyph{Rsmall}{r}
+\renameglyph{Ssmall}{s}
+\renameglyph{Tsmall}{t}
+\renameglyph{Usmall}{u}
+\renameglyph{Vsmall}{v}
+\renameglyph{Wsmall}{w}
+\renameglyph{Xsmall}{x}
+\renameglyph{Ysmall}{y}
+\renameglyph{Zsmall}{z}
+%</reglyphletters>
+% \end{macrocode}
+%
+% Then there are the figures:
+% \multchanges{\notcs{Reglyphing}}{1.911}{1999/12/10}
+% {\texttt{eightoldstyle} typo corrected. (LH) Spotted by
+% Rolf Lindgren.}
+% \multchanges{\notcs{Reglyphing}}{1.927}{2004/07/12}
+% {Placed commands for letters and figures in separate modules,
+% so that they can be separated in generation. (LH)}
+% \begin{macrocode}
+%<*reglyphfigures>
+\renameglyph{zerooldstyle}{zero}
+\renameglyph{oneoldstyle}{one}
+\renameglyph{twooldstyle}{two}
+\renameglyph{threeoldstyle}{three}
+\renameglyph{fouroldstyle}{four}
+\renameglyph{fiveoldstyle}{five}
+\renameglyph{sixoldstyle}{six}
+\renameglyph{sevenoldstyle}{seven}
+\renameglyph{eightoldstyle}{eight}
+\renameglyph{nineoldstyle}{nine}
+%</reglyphfigures>
+% \end{macrocode}
+%
+% Then there are the accents and a couple of miscellaneous symbols. You
+% might want to check these carefully, as there might not always be a
+% distinction.
+% \changes{1.925}{2003/05/13}{Added \cs{renameglyph} for
+% \texttt{Hungarumlautsmall}. Walter Schmidt noticed it was missing.
+% (LH)}
+% \begin{macrocode}
+%<*reglyphletters>
+\renameglyph{Acutesmall}{acute}
+\renameglyph{Brevesmall}{breve}
+\renameglyph{Caronsmall}{caron}
+\renameglyph{Cedillasmall}{cedilla}
+\renameglyph{Circumflexsmall}{circumflex}
+\renameglyph{Dieresissmall}{dieresis}
+\renameglyph{Dotaccentsmall}{dotaccent}
+\renameglyph{Gravesmall}{grave}
+\renameglyph{Hungarumlautsmall}{hungarumlaut}
+\renameglyph{Macronsmall}{macron}
+\renameglyph{Ogoneksmall}{ogonek}
+\renameglyph{Ringsmall}{ring}
+\renameglyph{Tildesmall}{tilde}
+\renameglyph{ampersandsmall}{ampersand}
+\renameglyph{centoldstyle}{cent}
+\renameglyph{dollaroldstyle}{dollar}
+% \end{macrocode}
+%
+% There are also all the non-English letters:
+% \begin{macrocode}
+\renameglyph{AEsmall}{ae}
+\renameglyph{Ethsmall}{eth}
+\renameglyph{Lslashsmall}{lslash}
+\renameglyph{Oslashsmall}{oslash}
+\renameglyph{OEsmall}{oe}
+\renameglyph{Thornsmall}{thorn}
+% \end{macrocode}
+% \begin{macrocode}
+\renameglyph{Agravesmall}{agrave}
+\renameglyph{Egravesmall}{egrave}
+\renameglyph{Igravesmall}{igrave}
+\renameglyph{Ogravesmall}{ograve}
+\renameglyph{Ugravesmall}{ugrave}
+% \end{macrocode}
+% \begin{macrocode}
+\renameglyph{Aacutesmall}{aacute}
+\renameglyph{Eacutesmall}{eacute}
+\renameglyph{Iacutesmall}{iacute}
+\renameglyph{Oacutesmall}{oacute}
+\renameglyph{Uacutesmall}{uacute}
+\renameglyph{Yacutesmall}{yacute}
+% \end{macrocode}
+% \begin{macrocode}
+\renameglyph{Acircumflexsmall}{acircumflex}
+\renameglyph{Ecircumflexsmall}{ecircumflex}
+\renameglyph{Icircumflexsmall}{icircumflex}
+\renameglyph{Ocircumflexsmall}{ocircumflex}
+\renameglyph{Ucircumflexsmall}{ucircumflex}
+% \end{macrocode}
+% \begin{macrocode}
+\renameglyph{Atildesmall}{atilde}
+\renameglyph{Ntildesmall}{ntilde}
+\renameglyph{Otildesmall}{otilde}
+% \end{macrocode}
+% \begin{macrocode}
+\renameglyph{Adieresissmall}{adieresis}
+\renameglyph{Edieresissmall}{edieresis}
+\renameglyph{Idieresissmall}{idieresis}
+\renameglyph{Odieresissmall}{odieresis}
+\renameglyph{Ydieresissmall}{ydieresis}
+\renameglyph{Udieresissmall}{udieresis}
+% \end{macrocode}
+% \begin{macrocode}
+\renameglyph{Aringsmall}{aring}
+\renameglyph{Ccedillasmall}{ccedilla}
+\renameglyph{Scaronsmall}{scaron}
+\renameglyph{Zcaronsmall}{zcaron}
+% \end{macrocode}
+%
+% The following four glyphs aren't really necessary, since they are
+% usually identical to another glyph or to their fakes.
+% \begin{macrocode}
+\killglyph{dotlessi}
+%<*glyphs>
+\renameglyph{FIsmall}{fi}
+\renameglyph{FLsmall}{fl}
+\renameglyph{SSsmall}{germandbls}
+%</glyphs>
+%<*!glyphs>
+\killglyph{fi}
+\killglyph{fl}
+\killglyph{germandbls}
+%</!glyphs>
+%</reglyphletters>
+% \end{macrocode}
+%
+% The \Module{!glyphs} settings have no need for |\setrawglyph|,
+% |\setscaledrawglyph|, or |\setglyph| commands, and no need for the
+% kerns between capitals either, since these are already known from the
+% regular variant. Note that it is pointless to say |\offmtxcommand|^^A
+% \penalty0|\setrawglyph| as of v\,1.913 since |\setrawglyph| is now
+% simply syntactic sugar for the equivalent |\set|\-|scaled|\-|raw|\-^^A
+% |glyph|.
+% \begin{macrocode}
+%<*(reglyphletters|reglyphfigures)&!glyphs>
+\offmtxcommand\setscaledrawglyph
+\offmtxcommand\setglyph
+\resetcommand\iftokeep#1\then{\ifnum 0<#1}
+%</(reglyphletters|reglyphfigures)&!glyphs>
+% \end{macrocode}
+%
+%
+% \changes{1.904}{1999/06/13}{Font transformation recordings moved to
+% \texttt{fimapgen.dtx}, so that the interface will be specified
+% in a single place. (LH)}
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \Finale
+\endinput \ No newline at end of file
diff --git a/fonts/utilities/fontinst/source/filtfam.dtx b/fonts/utilities/fontinst/source/filtfam.dtx
new file mode 100644
index 0000000000..1cfcf6c1f0
--- /dev/null
+++ b/fonts/utilities/fontinst/source/filtfam.dtx
@@ -0,0 +1,1187 @@
+% \CheckSum{1041}
+% \iffalse meta-comment
+%
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% From file: filtfam.dtx
+%
+%<*driver>
+\documentclass{ltxdoc}
+\usepackage{fisource}
+\GetFileInfo{filtfam.dtx}
+\title{The \package{fontinst} utility}
+\author{Alan Jeffrey, Sebastian Rahtz, Ulrik Vieth}
+\begin{document}
+\maketitle
+\DocInput{filtfam.dtx}
+\end{document}
+%</driver>
+% \fi
+%
+% \section{Installing Latin families}
+%
+% \changes{1.800}{1998/06/22}{\cs{textcompfamily} integrated into
+% \cs{latinfamily}. (UV)}
+%
+% \begin{macro}{\latinfamily}
+% The macro:
+% \begin{quote}
+% |\latinfamily|\marg{family}\marg{commands}
+% \end{quote}
+% installs a Latin font family.
+%
+% \StopEventually{}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\latinfamily#1#2{{
+ \edef\a_macro{#1}
+ \expandafter\parse_family\a_macro
+ \empty_command\empty_command\end_parse_family
+ \installfonts
+ \if_file_exists{\raw_encoding.mtx}\then
+ \installfamily{\raw_encoding}{\latex_family}{#2}
+ \fi
+ \installfamily{OT1}{\latex_family}{#2}
+ \installfamily{T1}{\latex_family}{#2}
+%<*textcomp>
+ \installfamily{TS1}{\latex_family}{#2}
+%</textcomp>
+ \latin_weights
+ \endinstallfonts
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\parse_family}
+% \begin{macro}{\font_family}
+% \begin{macro}{\font_variant}
+% \begin{macro}{\raw_variant}
+% \begin{macro}{\latex_variant}
+% |\parse_family FAMILY\end_parse_family|
+%
+% Intializes |\latex_family| to |FAMILY|, |\font_family| to first
+% three characters of |FAMILY|, |\font_variant| and |\raw_variant|
+% to fourth and fifth character (if present).
+%
+% SPQR 02/95: If the fourth parameter is |x| or |9|, then its an expert
+% indication, not a variant. So initialy set |\raw_variant| to |#4|,
+% but unset it if the expert test succeeds. When |#4| is used for a
+% real variant, it passes through.
+%
+% SPQR 05/95: If it \emph{is} an expert font, then the variantness
+% is expressed by the encoding, not a variant letter, so unset
+% |\font_variant|.
+%
+% UV 06/98: Added |\if_oldstyle_| code from Alan's v~1.511 beta.
+% If the fourth parameter is |9|, treat it as if |j| was given.
+%
+% Note that instead of using |\setcommand\digit|, we now use separate
+% encoding files for |T1j.etx|, etc.
+%
+% \begin{macrocode}
+\def\parse_family #1#2#3#4#5\end_parse_family{
+ \gdef\font_family{#1#2#3}
+ \gdef\font_variant{#4#5}
+ \gdef\raw_variant{#4#5}
+ \gdef\latex_family{#1#2#3#4#5}
+ \_expert_false
+ \_oldstyle_false
+ \ifx#4x
+ \_expert_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1}
+ \else\ifx#4j
+ \_expert_true
+ \_oldstyle_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1oldstyle}
+ \else\ifx#49
+ \gdef\latex_family{#1#2#3j#5}
+ \_expert_true
+ \_oldstyle_true
+ \gdef\raw_variant{#5}
+ \gdef\font_variant{#5}
+ %\setcommand\digit##1{##1oldstyle}
+ \else
+ \_expert_false
+ \_oldstyle_false
+ %\setcommand\digit##1{##1}
+ \fi\fi\fi
+%<*debug>
+ \if_oldstyle_
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#5>~(oldstyle)}
+ \else\if_expert_
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#5>~(expert)}
+ \else
+ \immediate\write16{INFO>~parse~family~<#1#2#3><#4#5>}
+ \fi\fi
+%</debug>
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\if_expert_}
+% \begin{macro}{\if_oldstyle_}
+% \begin{macrocode}
+\newif\if_expert_
+\newif\if_oldstyle_
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+%
+% \subsection{Processing a list of weights, widths and shapes}
+%
+% \begin{macro}{\latin_weight}
+% \begin{macro}{\font_weight}
+% \begin{macro}{\latex_weight}
+% |\latin_weight{FONTWEIGHT}{LATEXWEIGHT}|
+%
+% \begin{macrocode}
+\def\latin_weight#1#2{
+ \gdef\font_weight{#1}%
+ \gdef\latex_weight{#2}%
+ \latin_widths
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\latin_width}
+% \begin{macro}{\font_width}
+% \begin{macro}{\latex_width}
+% |\latin_width{FONTWIDTH}{LATEXWIDTH}|
+%
+% \begin{macrocode}
+\def\latin_width#1#2{
+ \gdef\font_width{#1}
+ \gdef\latex_width{#2}
+ \latin_shapes
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\latin_shape}
+% \begin{macro}{\font_shape}
+% \begin{macro}{\raw_shape}
+% \begin{macro}{\encoding_shape}
+% \begin{macro}{\latex_shape}
+% \begin{macro}{\encoding_switches}
+% |\latin_shape{FONTSHAPE}{RAWSHAPE}{ENCODINGSHAPE}{LATEXSHAPE}{SWITCHES}|
+%
+% Calls |\fake_width_WIDTH| and |\fake_shape_SHAPE| to generate an
+% |8r|-reencoded |.mtx| file. If successful, calls |\latin_encodings|.
+%
+% UV 06/98: Added a fifth argument |SWITCHES|, which may be used
+% to set |\if_textcomp_| before it is evaluated in |\latin_encodings|.
+%
+% \begin{macrocode}
+\def\latin_shape#1#2#3#4#5{
+ \gdef\font_shape{#1}
+ \gdef\raw_shape{#2}
+ \gdef\encoding_shape{#3}
+ \if_oldstyle_
+ \gdef\encoding_shape{#3\oldstyle_shape}
+ \fi
+ \gdef\latex_shape{#4}
+ \gdef\encoding_switches{#5}
+%<*debug>
+ \immediate\write16{
+ INFO>~to~make~LaTeX~font~shape~<\latex_family,
+ \latex_weight,\latex_shape,\latex_width>~seek~
+ \font_family\font_weight\raw_shape
+ \raw_variant\raw_encoding\font_width.mtx}
+%</debug>
+ \csname fake_width_\font_width\endcsname
+ \csname fake_shape_\raw_shape\endcsname
+ \if_file_exists{
+ \font_family\font_weight\raw_shape
+ \raw_variant\raw_encoding\font_width.mtx
+ }\then
+ \latin_encodings
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+%
+% \subsection{Faking font shapes}
+%
+% (CK) changed font faking code; based on SPQR's code (still in this
+% file). I am not sure that know what I am doing here; let's hope
+% I won't be caught. Also changed: Order of |\font_width| and
+% |\font_encoding| in MANY places. Also added tests which prevent
+% multiple calls to the same font faking routine. (Seems to be
+% necessary in some cases and can't hurt.) --- (ASAJ) I think CK
+% knows more about what he's doing than he's letting on.
+%
+% \begin{macro}{\fake_shape_}
+% Check if an |8a|-encoded |.afm| file exists for current combination
+% of font attributes, and, if so, call |\fake_shape_raw_encoding|.
+% For expert fonts, also check if an |8x|-encoded |.afm| file exists,
+% and call |\fake_shape_expert_encoding|, if approporiate.
+%
+% UV, 06/98: Cut down lengthy |\fake_shape_| routine into several
+% subroutines |\fake_shape_raw_encoding| and optionally
+% |\fake_shape_expert_encoding| and |\fake_shape_oldstyle_encoding|.
+%
+% UV, 06/98: Added experimental code to install OsF or SC\&OsF fonts.
+%
+% \begin{macrocode}
+\def\fake_shape_{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_raw_encoding
+ \fi
+ \if_expert_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.afm
+ }\then
+ \fake_shape_expert_encoding
+ \fi
+ \fi
+%<*oldstyle>
+ \if_oldstyle_
+ \gdef\oldstyle_variant{\oldstyle_shape}
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_oldstyle_encoding
+ \else
+ \gdef\oldstyle_variant{\caps_shape}
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_oldstyle_encoding
+ \fi
+ \fi
+ \fi
+%</oldstyle>
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_shape_raw_encoding}
+% Called from |\fake_shape_| if an |8a|-encoded |.afm| file was found.
+% Invokes
+% \begin{quote}
+% |\transformfont{<FONT>8r}|\\
+% | {\reencodefont{8r}{\fromafm{<FONT>8a}}}|
+% \end{quote}
+% to generate an |8r|-reencoded |.mtx| file (and a raw |.pl| file),
+% followed by
+% \begin{quote}
+% |\installrawfont{<FONT>8r}{<FONT>8r,8r}{8r}...|
+% \end{quote}
+% to install a ligfull |.pl| file.
+%
+% \begin{macrocode}
+\def\fake_shape_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width>
+ }
+%</debug>
+ \transformfont{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \reencodefont{\raw_encoding}{
+ \fromafm{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+%</debug>
+ \installrawfont{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_shape_expert_encoding}
+% Called from |\fake_shape_| if an |8x|-encoded |.afm| file was found.
+% Invokes
+% \begin{quote}
+% |\fromafm{<FONT>8x}|
+% \end{quote}
+% to generate an |8x|-encoded |.mtx| file (and a raw |.pl| file).
+%
+% \begin{macrocode}
+\def\fake_shape_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+ \fromafm{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width
+ }
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_shape_oldstyle_encoding}
+% Called from |\fake_shape_| if an OsF or SC\&OsF variant of an
+% |8a|-encoded |.afm| file was found. Invokes
+% \begin{quote}
+% |\transformfont{<FONT>j8r}|\\
+% | {\reencodefont{8r}{\fromafm{<FONT>j8a}}}|
+% \end{quote}
+% to generate an |8r|-reencoded |.mtx| file (and a raw |.pl| file).
+%
+% \begin{macrocode}
+%<*oldstyle>
+\def\fake_shape_oldstyle_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width.mtx
+ }\then % no action required
+ \else
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\raw_shape\oldstyle_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width>
+ }
+%</debug>
+ \transformfont{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \raw_encoding\font_width
+ }{
+ \reencodefont{\raw_encoding}{
+ \fromafm{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \adobe_encoding\font_width
+ }
+ }
+ }
+ \fi
+}
+%</oldstyle>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\fake_shape_c}
+% Check if an |8a|-encoded |.afm| file exists for the small caps shape.
+% If so, call |\fake_shape_| to generate an |8r|-reencoded MTX
+% file and to install a ligfull |.pl| file. If not, reset |\raw_shape|
+% to the default shape and |\encoding_shape| to small caps before
+% calling |\fake_shape_| to install a faked small caps font.
+%
+% \begin{macrocode}
+\def\fake_shape_c{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_
+ \else
+ % If real smallcaps font doesn't exist, fake it from the roman.
+ \gdef\raw_shape{}
+ \if_oldstyle_
+ \gdef\encoding_shape{cj}
+ \else
+ \gdef\encoding_shape{c}
+ \fi
+ \fake_shape_
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\fake_shape_o}
+% Check if an |8a|-encoded |.afm| file exists for the oblique shape.
+% If so, call |\fake_shape_| to generate an |8r|-reencoded MTX
+% file and to install a ligfull |.pl| file. If not, call macros
+% to fake a oblique fonts.
+%
+% \begin{macrocode}
+\def\fake_shape_o{
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then
+ \fake_shape_
+ \else
+ \fake_shape_o_raw_encoding
+ \if_expert_
+ \fake_shape_o_expert_encoding
+ \fi
+%<*oldstyle>
+ \if_oldstyle_
+ \fake_shape_o_oldstyle_encoding
+ \fi
+%</oldstyle>
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_shape_o_raw_encoding}
+% Called from |\fake_shape_o| if the oblique shape needs to be faked.
+% Invokes
+% \begin{quote}
+% |\transformfont{<FONT>o8r}|\\
+% | {\slantfont{SLANT}{\frommtx{<FONT>8r}}}|
+% \end{quote}
+% to generate an |8r|-reencoded |.mtx| file (and a raw |.pl| file),
+% followed by
+% \begin{quote}
+% |\installrawfont{<FONT>o8r}{<FONT>o8r,8r}{8r}...|
+% \end{quote}
+% to install a ligfull |.pl| file.
+%
+% \begin{macrocode}
+\def\fake_shape_o_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\raw_variant
+ \raw_encoding\font_width>~(faking~oblique)
+ }
+%</debug>
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\raw_variant
+ \raw_encoding\font_width
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+%</debug>
+ \installrawfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_shape_o_expert_encoding}
+% Called from |\fake_shape_o| if the oblique shape needs to be faked.
+% Invokes
+% \begin{quote}
+% |\transformfont{<FONT>o8x}|\\
+% | {\slantfont{SLANT}{\frommtx{<FONT>8x}}}|
+% \end{quote}
+% to generate an |8x|-reencoded |.mtx| file (and a raw |.pl| file).
+%
+% \begin{macrocode}
+\def\fake_shape_o_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width>~from~
+ <\font_family\font_weight\raw_variant
+ \expert_encoding\font_width>~(faking~oblique)
+ }
+%</debug>
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ \space from~
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\raw_variant
+ \expert_encoding\font_width
+ }
+ }
+ }
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_shape_o_oldstyle_encoding}
+% Called from |\fake_shape_o| if the oblique shape needs to be faked.
+% Invokes
+% \begin{quote}
+% |\transformfont{<FONT>oj8r}|\\
+% | {\slantfont{SLANT}{\frommtx{<FONT>j8r}}}|
+% \end{quote}
+% to generate an |8r|-reencoded |.mtx| file (and a raw |.pl| file).
+%
+% \begin{macrocode}
+%<*oldstyle>
+\def\fake_shape_o_oldstyle_encoding{
+ \if_file_exists{
+ \font_family\font_weight\oldstyle_variant
+ \raw_encoding\font_width.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\oldstyle_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\oldstyle_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\oldstyle_variant
+ \raw_encoding\font_width>~(faking~oblique)
+ }
+%</debug>
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~oblique~font~
+ \font_family\font_weight\font_shape\oldstyle_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\oldstyle_variant
+ \raw_encoding\font_width
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\oldstyle_variant
+ \raw_encoding\font_width
+ }{
+ \slantfont{\SlantAmount}{
+ \frommtx{
+ \font_family\font_weight\oldstyle_variant
+ \raw_encoding\font_width
+ }
+ }
+ }
+ \fi
+ \fi
+}
+%</oldstyle>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\fake_shape_i}
+% Call |\fake_shape_| to generate an |8r|-reencoded |.mtx| file and a
+% ligfull |.pl| file, if a corresponding |8a|-encoded |.afm| file exists.
+% Otherwise, do nothing, since an italic shape can't be faked.
+%
+% \begin{macrocode}
+\let\fake_shape_i\fake_shape_ % We must do this again!
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Faking font widths}
+%
+% \begin{macro}{\if_fake_narrow_}
+% \begin{macrocode}
+\newif\if_fake_narrow_
+\_fake_narrow_false
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fakenarrow}
+% |\fakenarrow{WIDTH}|
+%
+% Sets the expansion factor used to generate faked narrow fonts.
+% If it isn't set, do not attempt to install faked narrow fonts.
+% \begin{macrocode}
+\def\fakenarrow#1{
+ \_fake_narrow_true
+ \gdef\fake_narrow_width{#1}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_width_}
+% Do nothing for the default width or the condensed width.
+% \begin{macrocode}
+\def\fake_width_{}
+\def\fake_width_c{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_width_n}
+% If we are faking narrow fonts, check if an |8a|-encoded |.afm| file
+% exists for the current shape in narrow width, and if not call
+% |\fake_shape_n_raw_encoding| and |\fake_shape_n_expert_encoding|.
+%
+% \begin{macrocode}
+\def\fake_width_n{
+ \if_fake_narrow_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \adobe_encoding\font_width.afm
+ }\then % no action required
+ \else
+ \fake_width_n_raw_encoding
+ \if_expert_
+ \fake_width_n_expert_encoding
+ \fi
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_width_n_raw_encoding}
+% Called from |\fake_width_n| if the narrow width needs to be faked.
+% Invokes
+% \begin{quote}
+% |\transformfont{<FONT>8rn}|\\
+% | {\xscalefont{WIDTH}{\frommtx{<FONT>8r}}}|
+% \end{quote}
+% to generate an |8r|-encoded |.mtx| file for a faked narrow font,
+% followed by
+% \begin{quote}
+% |\installrawfont{<FONT>8rn}{<FONT>8rn,8r}{8r}...|
+% \end{quote}
+% to install a ligfull |.pl| file.
+%
+% \begin{macrocode}
+\def\fake_width_n_raw_encoding{
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width.mtx
+ }\then % no action required
+ \else
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>~from~
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding>~(faking~narrow)
+ }
+%</debug>
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~narrow~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ \space from~
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{
+ \xscalefont{\fake_narrow_width}{
+ \frommtx{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding
+ }
+ }
+ }
+ \if_file_exists{ \raw_encoding.mtx }\then
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\installrawfont\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width>
+ <\font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding>
+ <\raw_encoding>
+ <\raw_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+%</debug>
+ \installrawfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width
+ }{ \font_family\font_weight\font_shape\raw_variant
+ \raw_encoding\font_width,
+ \raw_encoding
+ }{ \raw_encoding
+ }{ \raw_encoding
+ }{ \latex_family
+ }{ \latex_weight\latex_width
+ }{ \latex_shape
+ }{}
+ \fi
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fake_width_n_expert_encoding}
+% Called from |\fake_width_n| if the narrow width needs to be faked.
+% Invokes
+% \begin{quote}
+% |\transformfont{<FONT>8xn}|\\
+% | {\xscalefont{WIDTH}{\frommtx{<FONT>8x}}}|
+% \end{quote}
+% to generate an |8x|-encoded |.mtx| file for a faked narrow font.
+%
+% \begin{macrocode}
+\def\fake_width_n_expert_encoding{
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding.mtx
+ }\then
+ \if_file_exists{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then % no action required
+ \else
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\transformfont\space\space
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width>~from~
+ <\font_family\font_weight\font_shape\raw_variant
+ \expert_encoding>~(faking~narrow)
+ }
+%</debug>
+ %%% WARNING: famtool.pl relies on this message format!!!
+ \immediate\write16{
+ Faking~narrow~font~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ \space from~
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding
+ }
+ \transformfont{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding\font_width
+ }{
+ \xscalefont{\fake_narrow_width}{
+ \frommtx{
+ \font_family\font_weight\font_shape\raw_variant
+ \expert_encoding
+ }
+ }
+ }
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Installing reencoded fonts}
+%
+% \begin{macro}{\latin_encoding}
+% \begin{macro}{\font_encoding}
+% \begin{macro}{\latex_encoding}
+% \begin{macro}{\latex_mtx}
+%
+% |\latin_encoding{FONTENC}{EXPERTISED-ENC}{OLDSTYLE-ENC}|
+% |{LATEXENC}{LATEXMTX}|
+%
+% If this is an expertised family |EXPERTISED-ENC| is used instead
+% of |FONTENC|. If this is an expertised family with oldstyle
+% digits |OLDSTYLE-ENC| is used instead of |EXPERTISED-ENC|.
+%
+% UV 06/98: Added code for oldstyle encodings from Alan's v~1.511.
+% The |\font_encoding| is changed when |\if_oldstyle_| is true.
+%
+% UV 06/98: Added anonther parameter for the default metrics file
+% (which is usually either |latin.mtx| or |textcomp.mtx|).
+%
+% UV 06/98: Added experimental code for OsF or SC\&OsF fonts.
+%
+% \begin{macrocode}
+\def\latin_encoding#1#2#3#4#5{
+ \gdef\latex_encoding{#4}
+ \gdef\latex_mtx{#5}
+ \if_oldstyle_
+ \gdef\font_encoding{#3}
+ \else\if_expert_
+ \gdef\font_encoding{#2}
+ \else
+ \gdef\font_encoding{#1}
+ \fi\fi
+ \gdef\expert_font{}
+ \gdef\oldstyle_font{}
+ \if_expert_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width.mtx
+ }\then
+ \gdef\expert_font{
+ \font_family\font_weight\raw_shape\raw_variant
+ \expert_encoding\font_width,
+ }
+ \fi
+ \fi
+%<*oldstyle>
+ \if_oldstyle_
+ \if_file_exists{
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \raw_variant\raw_encoding\font_width.mtx
+ }\then
+ \gdef\oldstyle_font{
+ unsetnum,
+ \font_family\font_weight\raw_shape\oldstyle_variant
+ \raw_variant\raw_encoding\font_width,
+ resetosf,
+ }
+ \fi
+ \fi
+%</oldstyle>
+%<*debug>
+ \immediate\write16{
+ INFO>~run~\string\installfont\space
+ <\font_family\font_weight\font_shape\font_variant
+ \font_encoding\font_width>
+ <\font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \if_oldstyle_
+ \ifx\raw_shape\caps_shape
+ resetosf,
+ \fi
+ \fi
+ \expert_font
+ \oldstyle_font
+ \latex_mtx>
+ <\latex_encoding\encoding_shape>
+ <\latex_encoding>
+ <\latex_family>
+ <\latex_weight\latex_width>
+ <\latex_shape>}
+%</debug>
+ \installfont{
+ \font_family\font_weight\font_shape\font_variant
+ \font_encoding\font_width
+ }{
+ \font_family\font_weight\raw_shape\raw_variant
+ \raw_encoding\font_width,
+ \if_oldstyle_
+ \ifx\raw_shape\caps_shape
+ resetosf,
+ \fi
+ \fi
+ \expert_font
+ \oldstyle_font
+ \latex_mtx
+ }{
+ \latex_encoding\encoding_shape
+ }{
+ \latex_encoding
+ }{
+ \latex_family
+ }{
+ \latex_weight\latex_width
+ }{
+ \latex_shape
+ }{}
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \subsection{Default weights, widths and shapes}
+%
+% \begin{center}
+% \begin{tabular}{llll}
+% \hline
+% \multicolumn{2}{l}{Fontname: \texttt{weight.map}} &
+% \multicolumn{2}{l}{NFSS: \emph{\LaTeX\ Companion}, p.~190} \\
+% \hline
+% |a| & Thin Hairline & |ul| & Ultra Light \\
+% |j| & ExtraLight & |el| & Extra Light \\
+% |l| & Light & |l| & Light \\
+% |r| & Regular Roman & |m| & Medium \\
+% |k| & Book & |m| & Medium \\
+% |m| & Medium & |mb| & (was: |m|) \\
+% |d| & Demi & |db| & (was: |sb|) \\
+% |s| & Semibold & |sb| & Semibold \\
+% |b| & Bold & |b| & Bold \\
+% |h| & Heavy Heavyface & |eb| & (was missing) \\
+% |c| & Black & |eb| & (was missing) \\
+% |x| & ExtraBold ExtraBlack & |eb| & Extra Bold \\
+% |u| & Ultra UltraBlack & |ub| & Ultra Bold \\
+% |p| & Poster & & (still missing) \\
+% \hline
+% \end{tabular}
+% \end{center}
+%
+% \begin{macro}{\latin_weights}
+% Each call to |\latin_weight| maps a Fontname weight code
+% (|\font_weight|) to a \LaTeX{} weight code (|\latex_weight|).
+% Non-existing weights are ignored (or substituted when the
+% |.fd| files are written out by |\endinstallfont|).
+%
+% The standard values are given in the table. They may be changed,
+% but you'd better know what you're doing.
+%
+% UV, 04/98: Changed the processing order: Do the most common
+% shapes first. Added new mappings for |c| and |h|, changed
+% mapping for |m| to newly invented \LaTeX{} weight |mb|.
+%
+% \begin{macrocode}
+\def\latin_weights{
+ \latin_weight{r}{m}
+ \latin_weight{k}{m}
+ \latin_weight{b}{b}
+ \latin_weight{s}{sb}
+ \latin_weight{d}{db} % was {d}{sb}, SPQR changed
+ \latin_weight{m}{mb} % was {m}{m}, UV changed
+ \latin_weight{c}{eb} % UV added
+ \latin_weight{h}{eb} % UV added
+ \latin_weight{x}{eb}
+ \latin_weight{u}{ub}
+ \latin_weight{l}{l}
+ %\latin_weight{j}{el}
+ %\latin_weight{a}{ul} % UV added
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{center}
+% \begin{tabular}{llll}
+% \hline
+% \multicolumn{2}{l}{Fontname: \texttt{width.map}} &
+% \multicolumn{2}{l}{NFSS: \emph{\LaTeX\ Companion}, p.~190} \\
+% \hline
+% |t| & Thin & -- & -- \\
+% |o| & Ultra Condensed & |uc| & Ultra Condensed \\
+% |u| & Ultra Compressed & |uc| & . . \\
+% |q| & Extra Compressed & |ec| & Extra Condensed \\
+% |c| & Condensed & |c| & Condensed \\
+% |p| & Compressed & |c| & . . \\
+% |n| & Narrow & |c| & . . \\
+% -- & -- & |sc| & Semi Condensed \\
+% |r| & Normal, Medium, Regular & |m| & Medium \\
+% -- & -- & |sx| & Semi Expanded \\
+% |e| & Expanded & |x| & Expanded \\
+% |x| & Extended & |x| & . . \\
+% |v| & Extra Expanded & |ex| & Extra Expanded \\
+% -- & -- & |ux| & Ultra Expanded \\
+% |w| & Wide & -- & -- \\
+% \hline
+% \end{tabular}
+% \end{center}
+%
+% \begin{macro}{\latin_widths}
+% Each call to |\latin_width| maps a Fontname width code
+% (|\font_width|) to a \LaTeX{} width code (|\latex_width|).
+% Non-existing narrow fonts are faked only if |\fakenarrow|
+% is specifically called for.
+%
+% \begin{macrocode}
+\def\latin_widths{
+ \latin_width{}{}
+ \latin_width{n}{c}
+ %latin_width{c}{c}
+ %latin_width{x}{x}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\latin_shapes}
+% The fifth argument of |\latin_shape| is stored in the variable
+% |\encoding_switches|.
+% \begin{macrocode}
+\def\latin_shapes{
+ \latin_shape{} {} {} {n} {\_textcomp_true }
+ \latin_shape{c}{c}{} {sc}{\_textcomp_false}
+ \latin_shape{o}{o}{} {sl}{\_textcomp_true }
+ \latin_shape{i}{i}{i}{it}{\_textcomp_true }
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\latin_encodings}
+% |\encoding_switches| is evaluated immediatley before the
+% |\if_textcomp_| test to set it as appropriate for the curent shape.
+% \changes{1.925}{2003/03/31}{Changed from using \texttt{latin.mtx} to
+% \texttt{newlatin.mtx}. (LH)}
+% \begin{macrocode}
+\def\latin_encodings{
+ \latin_encoding{7t}{9t}{9o}{OT1}{newlatin}
+ \latin_encoding{8t}{9e}{9d}{T1} {newlatin}
+%<*textcomp>
+ \encoding_switches
+ \if_textcomp_
+ \latin_encoding{8c}{9c}{9c}{TS1}{textcomp}
+ \fi
+%</textcomp>
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\if_textcomp_}
+% Switch to control whether or not to install a text companion
+% encoding. It is set or unset for each shape by |\latin_shapes|
+% and evaluated in |\latin_encodings|.
+%
+% \begin{macrocode}
+\newif\if_textcomp_
+% \end{macrocode}
+% \end{macro}
+
+%
+% \begin{macro}{\raw_encoding}
+% \begin{macro}{\adobe_encoding}
+% \begin{macro}{\expert_encoding}
+% \begin{macrocode}
+\def\raw_encoding{8r}
+\def\adobe_encoding{8a}
+\def\expert_encoding{8x}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+
+% \begin{macro}{\caps_shape}
+% \begin{macro}{\oldstyle_shape}
+% \begin{macrocode}
+\def\caps_shape{c}
+\def\oldstyle_shape{j}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\SlantAmount}
+% \begin{macrocode}
+\def\SlantAmount{167}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+% \Finale
+\endinput \ No newline at end of file
diff --git a/fonts/utilities/fontinst/source/fimain.dtx b/fonts/utilities/fontinst/source/fimain.dtx
new file mode 100644
index 0000000000..8fe61d23a7
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fimain.dtx
@@ -0,0 +1,4965 @@
+% \CheckSum{4056}
+% \iffalse meta-comment
+%
+% Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+% hacked and maintained 1997, 1998 Sebastian Rahtz,
+% copyright 1998, 1999, 2000 the fontinst maintenance team and any
+% individual authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.1 or, at your option, any later version.
+%
+%%% From file: fimain.dtx
+%
+%<*driver>
+\documentclass{ltxdoc}
+\usepackage{fisource}
+\title{The \package{fontinst} utility}
+\author{Alan Jeffrey, Sebastian Rahtz, Ulrik Vieth, Lars Hellstr\"om}
+\begin{document}
+\maketitle
+\tableofcontents
+\DocInput{fimain.dtx}
+\end{document}
+%</driver>
+% \fi
+%
+% \StopEventually{}
+%
+%
+% \section{Encoding files}
+%
+% \changes{1.911}{1999/11/21}{Definitions of encoding file commands
+% added to \protect\protect\protect\Module{misc}. (LH)}
+%
+% \DescribeMacro{\inputetx}
+% The macro
+% \begin{quote}
+% |\inputetx|\marg{filename}
+% \end{quote}
+% inputs \meta{filename}|.etx|, ignoring anything between |\relax|
+% and |\encoding|, and anything after |\endencoding|.
+%
+% The file name is transformed to lowercase before opening.
+%
+% \begin{macro}{\inputetx}
+% \begin{macro}{\encoding}
+% \changes{1.900}{1999/02/07}
+% {Changed group in fontdoc to \cs{begingroup} type. (LH)}
+% \usechange{raggedright}
+% \begin{macro}{\endencoding}
+% \changes{1.900}{1999/02/07}{Made it outer. (LH)}
+% \usechange{raggedright}
+% \begin{macrocode}
+%<*pkg|misc>
+\def\inputetx#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \slot_number=0
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\encoding=\fi
+ \primitiveinput \lowercase_file.etx\x_relax
+ \let\relax=\x_relax
+}
+\let\encoding=\relax
+\outer\def\endencoding{\endinput}
+%</pkg|misc>
+% \end{macrocode}
+%
+% Things are a bit more complicated in \package{fontdoc}, since the
+% |\relax| \textellipsis\ |\encoding| \textellipsis\ |\endencoding|
+% markup must be able to work in two different ways. In the main file
+% only |\encoding| actually does anything---it sets |\slot@number| to
+% zero. In a file that is being |\inputetx|ed, they must work as with
+% \package{fontinst}: Everything between |\relax| and |\encoding|,
+% and everything after |\endencoding| must be ignored.
+% \multchanges{\cs{inputetx}\cs{inputmtx}}{1.914}{2000/05/27}
+% {New \package{fontdoc} definition, using \cs{IfFileExists}. (LH)}
+% \multchanges{\cs{encoding}\cs{endencoding}}{1.918}{2001/06/19}
+% {Added \cs{par} and \cs{addvspace} to \package{fontdoc}
+% definitions. (LH)}
+% \multchanges{\cs{endencoding}}{1.919}{2001/09/01}
+% {Added setting of \cs{parindent} to 1\,em to \package{fontdoc}
+% definition. (LH)}
+% \begin{macrocode}
+%<*doc>
+\def\inputetx#1{%
+ \begingroup
+ \edef\lowercase@file{\lowercase{%
+ \edef\noexpand\lowercase@file{#1}%
+ }}%
+ \lowercase@file
+ \global\slot@number=0%
+ \FD@slot@known@true
+ \IfFileExists{\lowercase@file.etx}{%
+ \FD@relax@encoding@tricks
+ \@@input \@filef@und
+ \let\relax=\x@relax
+ }{%
+ \PackageError{fontdoc}{File #1.etx not found}%
+ {\@eha\MessageBreak You can \protect\inputetx\space
+ some other file now, if you want.}%
+ }
+ \endgroup
+}
+% \end{macrocode}
+% \begin{macro}{\FD@relax@encoding@tricks}
+% There is a problem with |\if| \dots\ |\fi| nesting in the
+% redefinition of |\relax| and |\encoding|, which interacts badly
+% with |\IfFileExists|. To work around that, these redefinitions
+% are hidden in the |\FD@relax@encoding@tricks| macro.
+% \changes{1.928}{2004/11/24}{Macro added, to fix bug reported by
+% Peter Dyballa. (LH)}
+% \begin{macrocode}
+\def\FD@relax@encoding@tricks{%
+ \def\relax{\let\relax=\x@relax\iffalse}%
+ \let\encoding=\fi
+ \outer\x@cs\def{endencoding}{\endinput}%
+}
+% \end{macrocode}
+% \end{macro}
+% \begin{macrocode}
+\def\encoding{%
+ \par
+ \ifFD@spec@ \addvspace{\bigskipamount}\fi
+ \begin{flushleft}
+ \global\slot@number=\z@
+}
+\outer\def\endencoding{%
+ \end{flushleft}
+ \ifFD@spec@ \addvspace{\bigskipamount}\fi
+}
+%</doc>
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\setslot}
+% \changes{1.917}{2001/03/23}{Made slots referencable using
+% \cs{label}. (LH)}
+% \begin{macro}{\endsetslot}
+% \begin{macro}{\slot_name}
+% |\setslot|\marg{name} \meta{slot commands} |\endsetslot|
+%
+% In \package{fontinst}, this sets |\slot_name| to \meta{name} and
+% calls |\do_slot| at the beginning of the slot and it calls
+% |\end_do_slot| and increments |\slot_number| by one at the end.
+% By default, |\do_slot| and |\end_do_slot| do nothing, but this is
+% over-ridden later.
+%
+% \begin{macrocode}
+%<*pkg|misc>
+\def\setslot#1{\edef\slot_name{#1}\do_slot}
+\def\endsetslot{\end_do_slot\advance\slot_number by 1\x_relax}
+%</pkg|misc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\slot@name}
+% \changes{1.917}{2001/03/23}{Now storing the printable form of the
+% name, rather than the raw code. (LH)}
+% In \package{fontdoc}, the same code converts \meta{name} to a
+% printable string and stores the result in |\slot@name|, prints an
+% |\Aheading| heading for the slot which show the name and number
+% of the slot, and prints the current automatic slot comment (if
+% one has been set) at the beginning of the slot. At the end of
+% the slot, it simply increments |\slot@number| by one.
+%
+% \begin{macrocode}
+%<*doc>
+\newcommand\setslot[1]{%
+ \protected@edef\slot@name{%
+ \noexpand\MakePrintable \noexpand\slot@name {FD@swa}{#1}%
+ }%
+ \slot@name
+ \FD@tight@true
+ \Aheading{Slot
+ \ifFD@slot@known@
+ \the\slot@number\space
+ \else
+ \(\FD@slot@expression + \the\slot@number\)
+ \fi
+ `\FD@typeset@string{\slot@name}'%
+ }%
+ \protected@edef\@currentlabel{%
+ \ifFD@slot@known@
+ \the\slot@number
+ \else
+ \protect\(%
+ \FD@slot@expression+\the\slot@number
+ \protect\)%
+ \fi
+ \space(\protect\FD@typeset@string{\slot@name})%
+ }%
+ \ifFD@slot@known@ \ifslot@comment@ \comment{\slot@comment}\fi\fi
+}
+\def\endsetslot{%
+ \global\advance \slot@number \@ne
+ \FD@tight@false
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\do_slot}
+% \begin{macro}{\end_do_slot}
+% \begin{macrocode}
+%<*pkg|misc>
+\let\do_slot\empty_command
+\let\end_do_slot\empty_command
+% \end{macrocode}
+% \end{macro} \end{macro}
+% \multchanges{\cs{do_new_slot}}{1.910}{1999/11/01}{Macro removed. (LH)}
+%
+% \begin{macro}{\nextslot}
+% \begin{macro}{\skipslots}
+% \begin{macro}{\slot_number}
+% \begin{macro}{\slot@number}
+% \begin{switch}{FD@slot@known@}
+% \begin{macro}{\FD@slot@expression}
+% |\nextslot|\marg{integer expression}\\
+% |\skipslots|\marg{integer expression}
+%
+% In \package{fontinst}, |\nextslot| sets the |\slot_number| and
+% |\skipslots| addvances the |\slot_number|.
+%
+% \begin{macrocode}
+\newcount\slot_number
+\def\nextslot#1{\eval_expr_to\slot_number{#1}}
+\def\skipslots#1{\eval_expr{#1} \advance\slot_number by \result}
+%</pkg|misc>
+% \end{macrocode}
+%
+% The commands do the same in \package{fontdoc} as in
+% \package{fontinst}, although they do it to |\slot@number| instead of
+% |\slot_number|.
+%
+% \begin{macrocode}
+%<*doc>
+\newcount\slot@number
+\def\FD@slot@known@true{\global\let\ifFD@slot@known@\iftrue}
+\def\FD@slot@known@false{\global\let\ifFD@slot@known@\iffalse}
+\FD@slot@known@true
+\newcommand\nextslot[1]{%
+ \FD@evaluate@true
+ \FD@eval@expr{#1}%
+ \ifFD@evaluate@
+ \global\slot@number=\FD@result
+ \FD@slot@known@true
+ \else
+ \global\let\FD@slot@expression=\FD@expression
+ \global\slot@number=\z@
+ \FD@slot@known@false
+ \fi
+}
+\newcommand\skipslots[1]{%
+ \FD@evaluate@true
+ \FD@eval@expr{#1}%
+ \ifFD@evaluate@
+ \global\advance \slot@number \FD@result
+ \else
+ \ifFD@slot@known@
+ \global\let\FD@slot@expression=\FD@expression
+ \else
+ \protected@xdef\FD@slot@expression{%
+ \FD@slot@expression+\FD@expression
+ }%
+ \fi
+ \FD@slot@known@false
+ \fi
+}
+%</doc>
+% \end{macrocode}
+%
+% There has been some ambiguity concerning what is allowed as
+% arguments of \cs{nextslot} and \cs{skipslots}. At least since
+% v\,1.335 the comments in the source has said it was an integer
+% expression, but the implementation was for a \TeX\ number.
+% Alan's v\,1.5 manual and Rowland's v\,1.8 manual both say the
+% arguments must be numbers. Allowing arbitrary integer
+% expressions with \package{fontinst} is trivial, the above
+% implementation copes with that, but \package{fontdoc} gets in
+% trouble, so what should we do about it? /LH
+%
+% AFAIK, all instances of |\nextslot| or |\skipslots| appearing in
+% present |*.etx| files are explicit numbers, no fancy constructs. /UV
+%
+% No, but if a |\setslot| command appears in a |\for| loop then the
+% slot number in that command will depend on the values of various
+% integer expressions anyway, so we might as well deal with it. /LH
+%
+% The matter was finally resolved when \package{fontdoc} was
+% augmented to handle (and typeset) arbtrary integer expressions.
+%
+% \multchanges{\cs{nextslot}\cs{skipslots}}{1.900}{1999/02/07}^^A
+% {Made changes of \cs{slot@number} global. (LH)}
+% \end{macro}\end{switch}\end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\setleftboundary}
+% \multchanges{\cs{setleftboundary}\cs{endsetleftboundary}}^^A
+% {1.909}{1999/10/19}{\package{fontdoc} definition added. (LH)}
+% \changes{1.917}{2001/03/23}{Made the left boundary referencable
+% using \cs{label}. (LH)}
+% \begin{macro}{\endsetleftboundary}
+% \begin{macro}{\do_boundary}
+% |\setleftboundary|\marg{glyph} \meta{slot commands}
+% |\endsetleftboundary|
+%
+% These macros are like |\setslot| and |\endsetslot|, but they merely
+% set the left boundary ligkern program, they do not cause any
+% |CHARACTER| property list to be written. Thus the only metric
+% information connected to the \meta{glyph} argument that is ever used
+% is the kerns with this glyph on the left.
+%
+% |\do_boundary| and |\endsetleftboundary| are initally |\relax|, but
+% are later redefined.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\setleftboundary#1{\edef\slot_name{#1}\do_boundary}
+\let\endsetleftboundary\x_relax
+\let\do_boundary\x_relax
+%</pkg>
+%<*doc>
+\newcommand\setleftboundary[1]{%
+ \protected@edef\slot@name{%
+ \noexpand\MakePrintable \noexpand\slot@name {FD@swa}{#1}%
+ }%
+ \slot@name
+ \FD@tight@true
+ \Aheading{Left boundary `\FD@typeset@string{\slot@name}'}%
+ \protected@edef\@currentlabel{%
+ left boundary (\protect\FD@typeset@string{\slot@name})%
+ }%
+}
+\let\endsetleftboundary=\FD@tight@false
+%</doc>
+%<*misc>
+\let\setleftboundary=\gobble_one
+\let\endsetleftboundary=\x_relax
+%</misc>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+%
+% \begin{macro}{\setrightboundary}
+% |\setrightboundary|\marg{glyph}
+%
+% The |\setrightboundary| macro should be used to set which slot in
+% the font is used as right boundary marker if that slot is empty. It
+% advances |\slot_number| just like a |\setslot| \textellipsis\
+% |\endsetslot| pair, but since the slot will be left empty, there is
+% no need for any \meta{slot commands}, and hence there is no need for
+% a closing |\endset|\textellipsis\ command either.
+%
+% If the right boundary marker slot is not to be left empty (often
+% unavoidable), then one should use the slot command
+% |\makerightboundary| instead.
+%
+% \changes{1.909}{1999/10/19}{doc definition added. (LH)}
+% \begin{macrocode}
+%<*pkg|misc>
+\def\setrightboundary#1{
+ \makerightboundary{#1}
+ \advance \slot_number 1\x_relax
+}
+%</pkg|misc>
+%<*doc>
+\newcommand\setrightboundary[1]{%
+ \Aheading{Right boundary slot
+ \ifFD@slot@known@
+ \the\slot@number\space
+ \else
+ \(\FD@slot@expression + \the\slot@number\)
+ \fi
+ `\TypesetStringExpression{#1}'%
+ }%
+ \global\advance \slot@number \@ne
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \DescribeMacro{\ligature}
+% \DescribeMacro{\Ligature}
+% \DescribeMacro{\oddligature}
+% \DescribeMacro{\nextlarger}
+% \DescribeMacro{\varchar}
+% \DescribeMacro{\endvarchar}
+% \DescribeMacro{\usedas}
+% \DescribeMacro{\makerightboundary}
+% \DescribeMacro{\Unicode}
+% The \meta{slot commands} are:
+% \begin{quote}
+% |\ligature|\marg{lig}\marg{glyph}\marg{glyph}\\
+% |\Ligature|\marg{lig}\marg{glyph}\marg{glyph}\\
+% |\oddligature|\marg{note}\marg{lig}\marg{glyph}\marg{glyph}\\
+% |\nextlarger|\marg{glyph}\\
+% |\varchar| \meta{varchar commands} |\endvarchar|\\
+% |\usedas|\marg{command}\marg{type}\\
+% |\makerightboundary|\marg{glyph}\\
+% |\Unicode|\marg{code point}\marg{name}
+% \end{quote}
+% By default, these do nothing in \package{fontinst}, but most of
+% those defaults are overridden locally in those situations where one
+% wants them to do something. Exceptions are \cs{usedas},
+% which is never used at all AFAIK,\footnote{It was intended to be
+% used for math font encodings, but that never got off the
+% \texttt{TODO} list. /LH} and |\oddligature| and |\Unicode|,
+% which are purely documentation commands. In \package{fontdoc},
+% they generate descriptive headings.
+%
+% \begin{macro}{\ligature}
+% \begin{macro}{\Ligature}
+% \changes{1.917}{2001/03/31}{Command added. (LH)}
+% \begin{macro}{\oddligature}
+% \changes{1.918}{2001/05/31}{Command added. (LH)}
+% The |\ligature| and |\Ligature| commands have the same syntax and
+% meaning to \package{fontinst}, but \package{fontdoc} can give them
+% slightly different treatment. In a specification ETX file, the
+% |\Ligature| command gets the heading ``Mandatory ligature'', whereas
+% the |\ligature| command gets the heading ``Ordinary ligature''.
+%
+% The |\oddligature| command takes a fourth argument which contains a
+% short note on when the ligature might be appropriate. The entire
+% command is always ignored by \package{fontinst}.
+% \begin{macrocode}
+%<pkg|misc>\let\ligature=\gobble_three
+%<pkg|misc>\def\Ligature{\ligature}
+%<pkg|misc>\def\oddligature#1#2#3#4{}
+%<*doc>
+\newcommand\ligature[3]{%
+ \Bheading{\ifFD@spec@ Ordinary ligature\else Ligature\fi}
+ \@nameuse{FD@lig-#1}{#2}{#3}%
+}
+\newcommand\Ligature[3]{%
+ \Bheading{\ifFD@spec@ Mandatory ligature\else Ligature\fi}
+ \@nameuse{FD@lig-#1}{#2}{#3}%
+}
+\newcommand\oddligature[4]{%
+ \Bheading{Odd\footnote{#1} ligature}
+ \@nameuse{FD@lig-#2}{#3}{#4}%
+}
+% \end{macrocode}
+%
+% Symbolic typesetting of |\ligature| programs requires
+% special processing.\describecsfamily{FD@lig-\meta{lig}}
+% \multchanges{\cs{FD@lig-/LIG\PrintChar{`>}}\cs
+% {FD@lig-LIG/\PrintChar{`>}}\cs{FD@lig-/LIG/\PrintChar{`>}}\cs
+% {FD@lig-/LIG/\PrintChar{`>}\PrintChar{`>}}}{1.917}
+% {2001/03/31}{Changed how \package{fontdoc} marks the current
+% position after a ligature instruction, from $+$ to
+% $*\lfloor$. (LH)}
+% \multchanges{\cs{FD@lig-/LIG}}{1.927}
+% {2004/06/21}{Fixed a typo. (LH) Reported by Werner Lemberg.}
+% \multchanges{\cs{FD@lig-/LIG/\PrintChar{`>}\PrintChar{`>}}}{1.927}
+% {2004/06/24}{Fixed a typo. (LH) Reported by Werner Lemberg.}
+%
+% \begin{macrocode}
+\x@cs\def{FD@lig-LIG}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$\typeset@glyph{#2}%
+}
+\x@cs\def{FD@lig-/LIG}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#2}%
+}
+\x@cs\def{FD@lig-LIG/}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \typeset@glyph{#2}${}*{}$\typeset@glyph{#1}%
+}
+\x@cs\def{FD@lig-/LIG/}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*{}$%
+ \typeset@glyph{#2}${}*{}$\typeset@glyph{#1}%
+}
+\x@cs\def{FD@lig-/LIG>}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*\lfloor$\typeset@glyph{#2}%
+}
+\x@cs\def{FD@lig-LIG/>}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \typeset@glyph{#2}${}*\lfloor$\typeset@glyph{#1}%
+}
+\x@cs\def{FD@lig-/LIG/>}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*\lfloor$%
+ \typeset@glyph{#2}${}*{}$\typeset@glyph{#1}%
+}
+\x@cs\def{FD@lig-/LIG/>>}#1#2{%
+ \FD@typeset@string{\slot@name}${}*{}$\typeset@glyph{#1}%
+ ${}\rightarrow{}$%
+ \FD@typeset@string{\slot@name}${}*{}$%
+ \typeset@glyph{#2}${}*\lfloor$\typeset@glyph{#1}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+%
+% \begin{macro}{\nextlarger}
+% \begin{macro}{\usedas}
+% \begin{macro}{\makerightboundary}
+% \begin{macrocode}
+%<*pkg|misc>
+\let\nextlarger=\gobble_one
+\let\usedas=\gobble_two
+\let\makerightboundary=\gobble_one
+%</pkg|misc>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\def\nextlarger#1{\Bheading{Next larger} \typeset@glyph{#1}}
+\def\makerightboundary#1{%
+ \Bheading{Right boundary marker slot} designation \typeset@glyph{#1}%
+}
+%</doc>
+% \end{macrocode}
+% \missing{doc}{\usedas}
+% \end{macro} \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\Unicode}
+% \changes{1.917}{2001/03/13}{Command added. (LH)}
+% \changes{1.917}{2001/03/31}{Added setting of \cs{linepenalty} and
+% \cs{spaceskip}. (LH)}
+% \begin{macro}{\textunicode}
+% \changes{1.918}{2001/06/17}{Command added. (LH)}
+% \begin{macro}{\FD@codepoint}
+% \changes{1.918}{2001/06/17}{Macro added. (LH)}
+% \begin{macro}{\FD@charname}
+% \changes{1.918}{2001/06/17}{Macro added. (LH)}
+% Since ISO\,10646\slash Unicode has become the primary reference for
+% identifying characters, we provide a special comment command for
+% specifying which Unicode character corresponds to a particular slot
+% in an encoding. \label{Unicode} The syntax is
+% \begin{quote}
+% |\Unicode|\marg{code point}\marg{name}
+% \end{quote}
+% where the \meta{code point} is the four hexadecimal digits that
+% identify the code point of the character and \meta{name} is the
+% name of the character. An example is
+% \begin{quote}
+% |\Unicode{0041}{LATIN CAPITAL LETTER A}|
+% \end{quote}
+% which is typeset as
+% \begin{quote}
+% Unicode character \texttt{U+0041}, \textsc{latin capital letter a}.
+% \end{quote}
+% The \meta{name} field may be left empty.
+%
+% The |\Unicode| command makes a whole |\comment|, but it is also
+% useful to have a similar command for writing such data as part of a
+% longer paragraph. The |\textunicode| command, which has the same
+% argument structure as |\Unicode|, is provided for this. If you write
+% \begin{quote}
+% |see also \textunicode{0041}{LATIN CAPITAL LETTER A} for|
+% \end{quote}
+% then this is typeset as
+% \begin{quote}
+% see also \texttt{U+0041} (\textsc{latin capital letter a}) for
+% \end{quote}
+%
+% As case is not significant in the character names and they
+% furthermore usually seem to be written in capitals, I have chosen
+% to typeset them using small capitals only. This is done by
+% |\FD@charname|. The |\FD@codepoint| macro similarly handles
+% typesetting of code points. See also the \texttt{hypertex} option
+% to the \package{fontdoc} package.
+%
+% The \package{fontinst} and \package{finstmsc} definitions of
+% |\Unicode| are to gobble the arguments.
+% \begin{macrocode}
+%<pkg|misc>\let\Unicode=\gobble_two
+%<*doc>
+\newcommand*\Unicode[2]{%
+ \comment{%
+ \spaceskip=\fontdimen2\font minus 1.1\fontdimen4\font
+ Unicode character \FD@codepoint{#1}%
+ \ifx \par#2\par \else , \FD@charname{#2}\fi.%
+ \linepenalty=300\par
+ }%
+}
+\newcommand*\textunicode[2]{%
+ \FD@codepoint{#1} \ifx\par#2\par\else(\FD@charname{#2})\fi
+}
+\providecommand*\FD@codepoint[1]{\texttt{U+\uppercase{#1}}}
+\providecommand*\FD@charname[1]{\textsc{\lowercase{#1}}}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\charseq}
+% Most commonly occurring glyphs correspond to one |\Unicode|
+% character, but this is not at all true in general---in fact there
+% may even be letters which cannot be encoded as single characters,
+% as they do not exist in precomposed form but have to be expressed
+% with a base letter and combining diacritical mark. Reasonable
+% compliance with the standard requires supporting character
+% sequences as well as individual characters.
+% \changes{1.928}{2004/11/27}{Command added. (LH)}
+% \changes{1.928}{2004/12/16}{Typeset form changed, from paragraph to
+% a one-item-per-line list. (LH)}
+%
+% In \package{fontinst}, the |\charseq| command is used to specify
+% such a character sequence. The syntax is
+% \begin{quote}
+% |\charseq|\marg{\cs{Unicode} commands}
+% \end{quote}
+% where the \meta{\cs{Unicode} commands} is one or several |\Unicode|
+% commands. This means the sequence of those characters. For example
+% \begin{quote}
+% |\charseq{|\\
+% | \Unicode{0066}{LATIN SMALL LETTER F}|\\
+% | \Unicode{0069}{LATIN SMALL LETTER I}|\\
+% |}|
+% \end{quote}
+% is typeset as
+% \begin{quote}
+% Unicode character sequence:\\
+% \vadjust{}\quad\texttt{U+0066} (\textsc{latin small letter f})\\
+% \vadjust{}\quad\texttt{U+0069} (\textsc{latin small letter i})
+% \end{quote}
+% This indentation is made using the \texttt{IfBranch} environment,
+% which could be considered a bit hackish.
+%
+% |\charseq| is gobbled in \Module{pkg} and \Module{misc}, but in the
+% latter case it might get redefined.
+% \begin{macrocode}
+%<pkg|misc>\let\charseq=\gobble_one
+% \end{macrocode}
+% Note how the environment group restores the definition
+% of |\Unicode|.
+% \begin{macrocode}
+%<*doc>
+\newcommand\charseq[1]{%
+ \comment{Unicode character sequence:}%
+ \begin{IfBranch}%
+ \def\Unicode##1##2{%
+ \noindent\FD@codepoint{##1}
+ \ifx\par##2\par\else(\FD@charname{##2})\fi
+ \par
+ }%
+ #1%
+ \end{IfBranch}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \DescribeMacro{\vartop}
+% \DescribeMacro{\varmid}
+% \DescribeMacro{\varbot}
+% \DescribeMacro{\varrep}
+% The \meta{varchar commands} are:
+% \begin{quote}
+% |\vartop|\marg{glyph}\\
+% |\varmid|\marg{glyph}\\
+% |\varbot|\marg{glyph}\\
+% |\varrep|\marg{glyph}
+% \end{quote}
+% These too do by default, which is overridden later, nothing in
+% \package{fontinst} but typeset descriptive headings in \package{fontdoc}.
+%
+% \begin{macro}{\varchar}
+% \begin{macro}{\vartop}
+% \begin{macro}{\varmid}
+% \begin{macro}{\varbot}
+% \begin{macro}{\varrep}
+% \begin{macro}{\endvarchar}
+% \begin{macrocode}
+%<*pkg|misc>
+\let\varchar=\empty_command
+\let\vartop=\gobble_one
+\let\varmid=\gobble_one
+\let\varbot=\gobble_one
+\let\varrep=\gobble_one
+\let\endvarchar=\empty_command
+%</pkg|misc>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\def\varchar{\Bheading{Extensible glyph:}}
+\def\vartop#1{\Bheading{Top} \typeset@glyph{#1}}
+\def\varmid#1{\Bheading{Middle} \typeset@glyph{#1}}
+\def\varbot#1{\Bheading{Bottom} \typeset@glyph{#1}}
+\def\varrep#1{\Bheading{Repeated} \typeset@glyph{#1}}
+\let\endvarchar\relax
+%</doc>
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\useexamplefont}
+% \begin{macro}{\slotexample}
+% \begin{macro}{\setslotcomment}
+% \begin{macro}{\resetslotcomment}
+% \begin{macro}{\unsetslotcomment}
+% \begin{macro}{\slot@comment}
+% \begin{macro}{\slot@font}
+% As of v\,1.8 of \package{fontinst}, we have added an interface
+% for automatic documentation of encoding files, which has been
+% developed by Matthias Clasen as part of his work on math fonts.
+% The implementation was slightly modified and integrated into
+% this version by Ulrik Vieth.
+%
+% |\setslotcomment| defines a default slot comment, stored in the
+% variable |\slot@comment|, which is subsequently used to annotate
+% all |\setslot| commands. The slot comment can be changed by
+% |\resetslotcomment| or turned off by |\unsetslotcomment|.
+%
+% |\useexamplefont| defines a default font, |\slot@font|, which
+% may be referenced by calling |\slotexample| in slot comments to
+% display the character or symbol allocated to the current slot.
+%
+% Taking advantage of this mechanism, it is possible to write:
+% \begin{quote}
+% |\useexamplefont{FONT}|\\[0.5\baselineskip]
+% |\setslotcomment{The symbol `\slotexample'.}|\\
+% |\setslot{FOO}\endsetslot|\\
+% |\setslot{BAR}\endsetslot|\\
+% |\resetslotcomment{The character `\slotexample'.}|\\
+% |\setslot{BAZ}\endsetslot|
+% \end{quote}
+% instead of having to write:
+% \begin{quote}
+% |\usepackage{PACKAGE-to-use-symbols-from-FONT}|\\[0.5\baselineskip]
+% |\setslot{FOO}\comment{The symbol `\foo'.}\endsetslot|\\
+% |\setslot{BAR}\comment{The symbol `\bar'.}\endsetslot|\\
+% |\setslot{BAZ}\comment{The character `\baz'.}\endsetslot|
+% \end{quote}
+%
+% These macros never do anything in \package{fontinst}, they just
+% gobble their arguments.
+% \begin{macrocode}
+%<*pkg|misc>
+\let\useexamplefont=\gobble_one
+\let\slotexample=\empty_command
+\let\setslotcomment=\gobble_one
+\let\resetslotcomment=\gobble_one
+\let\unsetslotcomment=\empty_command
+%</pkg|misc>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newif\ifslot@comment@
+\slot@comment@false
+\def\slot@comment{}
+\newcommand\setslotcomment[1]{%
+ \slot@comment@true
+ \gdef\slot@comment{#1}%
+}
+\newcommand\resetslotcomment[1]{\gdef\slot@comment{#1}}
+\newcommand\unsetslotcomment{%
+ \slot@comment@false
+ \global\let\slot@comment\@empty
+}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\let\slot@font=\nullfont
+\newcommand\useexamplefont[1]{\font\slot@font=#1 }
+\newcommand\slotexample{%
+ \ifFD@slot@known@{\slot@font\char\slot@number}\fi
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\setfontdimen}
+% \changes{1.917}{2001/03/16}{Command added. (LH)}
+% The |\setfontdimen| command is used in an ETX file to set a font
+% dimen. The syntax is
+% \begin{quote}
+% |\setfontdimen|\marg{fontdimen no.}\marg{integer}
+% \end{quote}
+% where \meta{fontdimen no.} and \meta{integer} are \emph{string}
+% expressions. \meta{fontdimen no.} specifies the fontdimen to set.
+% \meta{integer} is the name of the integer variable to whose value
+% the fontdimen will be set.
+%
+% When used in font installation, the above |\setfontdimen| command
+% is equivalent to
+% \changes{1.923}{2002/10/25}{Leave the fontdimen unset when the
+% integer variable has not been set. (LH)}
+% \begin{quote}
+% |\ifisint|\marg{integer}|\then|\\
+% | \setint{fontdimen(|\meta{fontdimen no.}|)}{\int{|^^A
+% \meta{integer}|}}|\\
+% |\fi|
+% \end{quote}
+% but |\setfontdimen| is also understood by the (V)PL-to-MTX
+% converter as declaring an integer that the generated MTX file
+% should set to the value of the fontdimen in the (V)PL.
+% \begin{macrocode}
+%<*pkg>
+\def\setfontdimen#1#2{
+ \ifisint{#2}\then \setint{fontdimen(#1)}{\int{#2}} \fi
+}
+%</pkg>
+%<misc>\let\setfontdimen\gobble_two
+%<*doc>
+\newcommand\setfontdimen[2]{%
+ \Bheading{Fontdimen} \TypesetStringExpression{#1} is
+ \(\TypesetIntegerExpression{\int{#2}}\)%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\label}
+% \changes{1.917}{2001/03/23}{Macro added. (LH)}
+% \package{fontinst} and \package{finstmsc} defines the \LaTeX\
+% |\label| command to gobble its argument, so that one can use it to
+% reference slots.
+% \begin{macrocode}
+%<pkg|misc>\let\label=\gobble_one
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{switch}{direct}
+% The encoding aspect of a font can to a large extent be understood
+% as a mapping from the set of slots to the set of glyphs---such
+% mappings are for example realised by PostScript encoding vectors
+% (mapping slots to glyph names) and virtual fonts (mapping slots to
+% DVI commands for drawing a glyph). In some cases however, encodings
+% are rather used to specify an inverse mapping going the opposite
+% way. Since encodings are in general many-to-one, this means there
+% need not be a proper inverse to a given encoding; instead the
+% inverse image of a glyph is in practice chosen randomly\footnote{In
+% the sense: according to a very deterministic (but not particularly
+% useful) rule which depends completely on details in the
+% implementation, and therefore should not be relied upon anyway.}
+% among the slots that are mapped to it. This is not always desirable.
+%
+% The \texttt{direct} switch can be used to check whether an encoding
+% is interpreted in the direct (slots to glyphs) or inverse (glyphs to
+% slots) manner. If those |\setslot| commands which are undesirable
+% under the inverse interpretation are put inside an |\ifdirect|
+% \dots\ |\Fi| construction, then these will be ignored in that
+% circumstance, thus allowing the programmer to exactly specify both
+% the direct and the inverse mappings.
+% \changes{1.924}{2003/02/08}{Command added. (LH)}
+%
+% In \package{fontinst}, this command is a switch, which is usually
+% true.
+% \begin{macrocode}
+%<pkg|misc>\newif\ifdirect \directtrue
+% \end{macrocode}
+% In \package{fontdoc}, this is a conditional that will be typeset
+% if |\showbranches| is being used.
+% \begin{macrocode}
+%<doc>\newcommand\ifdirect{\generic@if{direct}}
+% \end{macrocode}
+% \end{switch}
+%
+% \begin{macro}{\input_mtx_as_etx}
+% The |\input_mtx_as_etx| command is syntactically similar to the
+% |\inputetx| command, but it inputs an MTX file instead of an ETX
+% file and redefines |\setscaledrawglyph| so that it expands to a
+% |\nextslot| followed by a |\setslot| \dots\ |\endsetslot|. This is
+% useful when making proofs of fonts with nonstandard encodings, as
+% the MTX of a font can be used to specify ``the default encoding''
+% of that font.
+%
+% \textbf{Warning:} Since this macro redefines a lot of the metric
+% commands, you'll probably only want to call it inside a group.
+% \changes{1.923}{2002/10/24}{Macro added. (LH)}
+% \begin{macrocode}
+%<*pkg|misc>
+\def\input_mtx_as_etx#1{
+ \def\setscaledrawglyph##1##2##3##4##5##6##7##8##9{
+ \nextslot{##5}
+ \setslot{##1}\endsetslot
+ }
+ \offcommand\setscalednotglyph
+ \let\setglyph=\gobble_glyph
+ \offcommand\setkern
+ \inputmtx{#1}
+}
+%</pkg|misc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \section{Metric files}
+% \label{Sec:Metric files}
+%
+% \changes{1.911}{1999/11/17}{Definitions of metric file commands
+% added to \protect\protect\protect\Module{misc}. (LH)}
+%
+% \DescribeMacro{\inputmtx}
+% The macro
+% \begin{quote}
+% |\inputmtx|\marg{filename}
+% \end{quote}
+% inputs \meta{filename}|.mtx|, ignoring anything between |\relax| and
+% |\metrics|, and anything after |\endmetrics|.
+%
+% \begin{macro}{\inputmtx}
+% \begin{macro}{\metrics}
+% \changes{1.914}{2000/05/26}{Fixed typo: \cs{x@relax} instead of
+% \cs{x_relax}. (LH)}
+% \usechange{raggedright}
+% \begin{macro}{\endmetrics}
+% \changes{1.900}{1999/02/08}{Made it outer. (LH)}
+% \usechange{raggedright}
+% \begin{macro}{\endmetrics_text}
+% \begin{macro}{\endmetrics@hook}
+% The |\endmetrics_text| macro expands to |\endmetrics| (eleven
+% `other' tokens, not one control sequence token). It is used instead
+% of |\string\endmetrics|, which does not work since |\endmetrics| is
+% outer.
+% \begin{macrocode}
+%<*pkg|misc>
+\def\inputmtx#1{
+ \def\relax{\let\relax=\x_relax\iffalse}
+ \let\metrics=\fi
+ \primitiveinput #1.mtx\x_relax
+ \let\relax=\x_relax
+}
+\let\metrics=\x_relax
+\edef\endmetrics_text{\string\endmetrics}
+\outer\def\endmetrics{\endinput}
+%</pkg|misc>
+% \end{macrocode}
+% |\inputmtx| used to set |\a_count|, but we haven't been able to
+% find a reason for this, so it was removed.
+%
+% In \package{fontdoc}, the |\metrics| and |\endmetrics| macros
+% initially just define a group, but |\inputmtx| redefines them to
+% work as they do in \package{fontinst}. |\endmetrics@hook| is a
+% macro that gets executed just before the |\endgroup| in
+% |\endmetrics|; it is normally |\@empty|, and it is set to this value
+% at each |\metrics|, but the metric package system redefines it.
+% \multchanges{\cs{endmetrics_hook}}{1.914}{2000/05/27}{Macro added.
+% (LH)}
+% \multchanges{\cs{inputetx}\cs{inputmtx}}{1.914}{2000/05/27}
+% {New \package{fontdoc} definition, using \cs{IfFileExists}. (LH)}
+% \begin{macrocode}
+%<*doc>
+\def\inputmtx#1{%
+ \begingroup
+ \edef\lowercase@file{\lowercase{%
+ \edef\noexpand\lowercase@file{#1}%
+ }}%
+ \lowercase@file
+ \let\endmetrics@hook=\@empty
+ \IfFileExists{\lowercase@file.mtx}{%
+ \skip@mtx@preamble
+ \@@input \@filef@und
+ \let\relax=\x@relax
+ }{%
+ \PackageError{fontdoc}{File #1.mtx not found}%
+ {\@eha\MessageBreak You can \protect\inputmtx\space
+ some other file now, if you want.}%
+ }
+ \endmetrics@hook
+ \endgroup
+}
+\def\skip@mtx@preamble{%
+ \def\relax{\let\relax=\x@relax\iffalse}%
+ \let\metrics=\fi
+ \outer\x@cs\def{endmetrics}{\endinput}%
+}
+\def\metrics{%
+ \begin{flushleft}%
+ \let\endmetrics@hook=\@empty
+}
+\outer\def\endmetrics{%
+ \endmetrics@hook
+ \end{flushleft}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}
+%
+%
+% \begin{macro}{\ProvidesMtxPackage}
+% \changes{1.923}{2003/01/05}{Redesigned the headings for metric
+% packages, since they interact poorly with \cs{section} headings.
+% (LH)}
+% \begin{switch}{@mtxpackage@headed@}
+% \begin{macro}{\announce@package}
+% \begin{macro}{\finish@package}
+% \multchanges{\cs{ProvidesMtxPackage}\cs{usemtxpackage}}{1.914}
+% {2000/05/27}{New \package{fontdoc} implementation---the packages
+% are actually loaded (they have to, since they can define
+% commands). Multiple loading is prevented as in
+% \package{fontinst}. (LH)}
+% The call
+% \begin{quote}
+% |\ProvidesMtxPackage|\marg{package~name}
+% \end{quote}
+% signals to the package managing system that there is no need to load
+% this package again.
+% \begin{macrocode}
+%<pkg>\def\ProvidesMtxPackage#1{\x_cs\let{pack-#1}P}
+%<*doc>
+\def\ProvidesMtxPackage#1{%
+ \endmetrics@hook
+% \@mtxpackage@headed@false
+% \everypar={
+ \announce@package{#1}%
+% }%
+ \def\endmetrics@hook{\finish@package{#1}}
+ \global\x@cs\let{FD@pack-#1}\@empty
+}
+% \end{macrocode}
+% \begin{macrocode}
+% \newif\if@mtxpackage@headed@
+% \end{macrocode}
+% \begin{macrocode}
+\def\announce@package#1{%
+% \everypar={}%
+% \@mtxpackage@headed@true
+ \Aheading{[Start of metric package \textsf{#1}.}%
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\finish@package#1{%
+% \if@mtxpackage@headed@
+ \Aheading{End of metric package \textsf{#1}.]}%
+% \else
+% \everypar={}%
+% \Aheading{(Metric package \textsf{#1}.)}%
+% \fi
+ \par\addvspace\medskipamount
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{switch}\end{macro}
+%
+%
+% \begin{macro}{\usemtxpackage}
+% The call
+% \begin{quote}
+% |\usemtxpackage|\marg{package~list}
+% \end{quote}
+% inputs those of the packages in the list that have not been loaded
+% yet (i.e., those for which no |\ProvidesMtxPackage| has been made).
+% Each package is assumed to reside in the metric file that
+% |\inputmtx| loads when given the name of the package as argument.
+%
+% The call
+% \begin{quote}
+% |\usemtxpackage|\oarg{filename}\marg{package~list}
+% \end{quote}
+% inputs the packages in the list if at least one of them has not been
+% loaded yet. In this case, all the packages are assumed to reside in
+% the single metric file that |\inputmtx| loads when given
+% \meta{filename} as argument.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\usemtxpackage{\futurelet\next_token\test_UseMtxPkg_arguments}
+\def\test_UseMtxPkg_arguments{\ifx\next_token[
+ \expandafter\mtx_package_given_file
+ \else
+ \expandafter\mtx_package_separate_files
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\mtx_package_given_file[#1]#2{
+ \_a_false
+ \process_csep_list\load_true_unless_loaded #2,\process_csep_list,
+ \if_a_ \inputmtx{#1} \fi
+}
+\def\load_true_unless_loaded#1{
+ \x_cs\ifx{pack-#1}P\else\_a_true\fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\mtx_package_separate_files#1{
+ \process_csep_list\load_file_unless_loaded #1,\process_csep_list,
+}
+\def\load_file_unless_loaded#1{
+ \x_cs\ifx{pack-#1}P\else \inputmtx{#1} \fi
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\usemtxpackage[2][\x@relax]{%
+ \ifx \x@relax#1%
+ \@for\@tempa:=#2\do{%
+ \x@cs\ifx{FD@pack-\@tempa}\@empty \else
+ \inputmtx{\@tempa}%
+ \fi
+ }%
+ \else
+ \@tempswafalse
+ \@for\@tempa:=#1\do{%
+ \x@cs\ifx{FD@pack-\@tempa}\@empty \else \@tempswatrue \fi
+ }%
+ \if@tempswa
+ \inputmtx{#2}%
+ \fi
+ \fi
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\glyph_name_modifier}
+% The |\glyph_name_modifier| macro is applied to all glyph names
+% supplied to commands that are allowed in transformable MTX files
+% (see Subsection~\ref{Ssec:TransMTX}). The syntax is
+% \begin{quote}
+% |\glyph_name_modifier|\marg{glyph name}
+% \end{quote}
+% and the above must expand fully to a valid glyph name in \TeX's
+% mouth.
+%
+% \changes{1.923}{2002/10/20}{Macro added. (LH)}
+% The normal definition is to simply expand to the \meta{glyph name},
+% i.e.,
+% \begin{macrocode}
+%<pkg>\let\glyph_name_modifier=\identity_one
+% \end{macrocode}
+% but the command may expand to any sequence of character tokens. It
+% was introduced to support (simple) automatic renaming of glyphs
+% in cases where the |\reglyphfont| command would not be appropriate,
+% such as when the wanted renaming is simply to add a short suffix to
+% the glyph names.
+%
+% The reason it only affects the commands allowed in transformable
+% MTX files is that the macro isn't meant as a generic override for
+% metric commands.
+% \end{macro}
+%
+%
+% \subsection{Kerning information}
+%
+% The kerning information is kept in the macros
+% \describecsfamily{l-\meta{name}}|\l-|\meta{name} and
+% \describecsfamily{r-\meta{name}}|\r-|\meta{name}, containing
+% information about how \meta{name} kerns on the left and on the right,
+% respectively. The |\l-|\meta{name} macro should expand out to a
+% series of
+% \begin{quote}
+% \DescribeMacro{\k}|\k|\,|\r-|\meta{name}\,|\|\meta{amount}
+% \end{quote}
+% control sequences, and vice versa. Examples of
+% \describecsfamily{\meta{amount}} |\|\meta{amount}
+% control sequences are: |\0|, |\1|, |\1000|, |\-50|, |\33|; these
+% corresponds to the kern amounts $0$, $1$, $1000$ (which would be
+% a very large kern), $-50$, and $33$ respectively.
+%
+%
+% \begin{macro}{\setkern}
+% |\setkern|\marg{glyph1}\marg{glyph2}\marg{integer expression}
+%
+% Sets a kern pair between \meta{glyph1} and \meta{glyph2} to the
+% specified value, which is typically a value returned by
+% |\kerning|\marg{glyph3}\marg{glyph4}. If there already is a kern
+% set between \meta{glyph1} and \meta{glyph2} then this will not affect
+% the output, but it will use up another 3 units of token memory.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\setkern#1#2#3{
+ \x_cs\ifx{i-rawscale}\x_relax
+ \expandafter\set_kern
+ \csname~r-\glyph_name_modifier{#1}\expandafter\endcsname
+ \csname~l-\glyph_name_modifier{#2}\endcsname
+ {#3}
+ \else
+ \expandafter\set_kern
+ \csname~r-\glyph_name_modifier{#1}\expandafter\endcsname
+ \csname~l-\glyph_name_modifier{#2}\endcsname
+ {\scale{#3}{\int{rawscale}}}
+ \fi
+}
+\def\set_kern#1#2#3{
+ \eval_expr{#3}
+ \expandafter\set_kern_cs\csname\the\result\endcsname#1#2
+}
+\def\set_kern_cs#1#2#3{
+ \add_to#2{\k#3#1}
+ \add_to#3{\k#2#1}
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\setkern[3]{%
+ \Bheading{Kern} \typeset@glyph{#1}${{}+{}}$\typeset@glyph{#2}%
+ ${}\rightarrow \TypesetIntegerExpression{#3}$%
+}
+%</doc>
+%<misc>\let\setkern=\gobble_three
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\resetkern}
+% |\resetkern|\marg{glyph1}\marg{glyph2}\marg{integer expression}
+%
+% Resets the kern pair between \meta{glyph1} and \meta{glyph2} to
+% the specified value. Note however that this does not relieve \TeX\
+% of the burden to remember the previous kerning pair between these
+% two glyphs (if there was one).
+%
+% \begin{macrocode}
+%<*pkg>
+\def\resetkern#1#2#3{
+ \x_cs\ifx{i-rawscale}\x_relax
+ \expandafter\reset_kern
+ \csname~r-#1\expandafter\endcsname
+ \csname~l-#2\endcsname{#3}
+ \else
+ \expandafter\reset_kern
+ \csname~r-#1\expandafter\endcsname
+ \csname~l-#2\endcsname{\scale{#3}{\int{rawscale}}}
+ \fi
+}
+\def\reset_kern#1#2#3{
+ \eval_expr{#3}
+ \expandafter\reset_kern_cs\csname\the\result\endcsname#1#2
+}
+\def\reset_kern_cs#1#2#3{
+ \prep_to#2{\k\expandafter#3\expandafter#1}
+ \prep_to#3{\k\expandafter#2\expandafter#1}
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\resetkern[3]{%
+ \Bheading{Override kern} \typeset@glyph{#1}${{}+{}}$\typeset@glyph{#2}%
+ ${}\rightarrow \TypesetIntegerExpression{#3}$%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\setleftkerning}
+% \begin{macro}{\setrightkerning}
+% \begin{macro}{\setleftrightkerning}
+% |\setleftkerning|\marg{glyph1}\marg{glyph2}\marg{scaled}\\
+% |\setrightkerning|\marg{glyph1}\marg{glyph2}\marg{scaled}\\
+% |\setleftrightkerning|\marg{glyph1}\marg{glyph2}\marg{scaled}
+%
+% Sets left or right kerning of \meta{glyph1} to that of \meta{glyph2}
+% scaled by \meta{scaled} (which is an integer expression).
+% |\setleftrightkerning| does both.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\setleftkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~l-#1\expandafter\endcsname
+ \csname~l-#2\endcsname
+}
+\def\setrightkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~r-#1\expandafter\endcsname
+ \csname~r-#2\endcsname
+}
+\def\setleftrightkerning#1#2#3{
+ \eval_expr_to\b_count{#3}
+ \expandafter\set_kerning
+ \csname~l-#1\expandafter\endcsname
+ \csname~l-#2\endcsname
+ \expandafter\set_kerning
+ \csname~r-#1\expandafter\endcsname
+ \csname~r-#2\endcsname
+}
+\def\set_kerning#1#2{
+ \if\b_count=\one_thousand
+ \def\k##1##2{
+ \set_kern_cs##2##1#1
+ }
+ \else
+ \def\k##1##2{
+ \set_kern##1#1{
+ \scale\b_count{\expandafter\gobble_one\string##2}
+ }
+ }
+ \fi
+ #2
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\setleftkerning[3]{%
+ \Bheading{Kern} \typeset@glyph{#1} on the left like
+ \typeset@glyph{#2} \ConditionallyScaled{#3}}
+\newcommand\setrightkerning[3]{%
+ \Bheading{Kern} \typeset@glyph{#1} on the right like
+ \typeset@glyph{#2} \ConditionallyScaled{#3}}
+\newcommand\setleftrightkerning[3]{%
+ \Bheading{Kern} \typeset@glyph{#1} on the left and right like
+ \typeset@glyph{#2} \ConditionallyScaled{#3}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\ConditionallyScaled}
+% \changes{1.916}{2001/01/06}{Command added. (LH)}
+% Several metric commands have take a scaling factor argument which is
+% rendered by \package{fontdoc} as ``scaled \meta{argument}''. The by
+% far most common value for this argument is however the constant
+% number 1000 (no scaling), and in those cases the ``scaled
+% \textellipsis'' feels a bit long-winded. The cure for this is the
+% |\Conditionally|\-|Scaled| command, which takes an integer expression
+% as its argument and typesets the ``scaled \meta{integer expression}''
+% \emph{unless} that expression evaluates to 1000, in which case
+% |\Conditionally|\-|Scaled| simply gobbles any spaces following it.
+% \begin{macrocode}
+\newcommand\ConditionallyScaled[1]{%
+ \FD@evaluate@true
+ \FD@eval@expr{#1}%
+ \@tempswatrue
+ \ifFD@evaluate@ \ifnum \FD@result=\@m \@tempswafalse \fi\fi
+ \FD@evaluate@false
+ \if@tempswa scaled \(\FD@expression\)\else \ignorespaces \fi
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\kerning}
+% |\kerning|\marg{glyph1}\marg{glyph2}
+%
+% Returns the value of kern pair between \meta{glyph1} and
+% \meta{glyph2} as an integer. Returns a value of zero if such a kern
+% pair doesn't exist.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\kerning#1#2{0\x_relax
+ \def\k##1{\csname~set-\string##1\endcsname\gobble_one}
+ \bgroup
+ \x_cs\def{set-\string\l-#2}##1##2{
+ \global\result=\expandafter\gobble_one\string##2\egroup
+ }
+ \csname~r-#1\endcsname
+ \csname~set-\string\l-#2\endcsname\gobble_one{00}
+}
+%</pkg>
+% \end{macrocode}
+% \changes{1.909}{1999/10/19}{A use of \#1 where it should have
+% been \#2 was corrected. (LH)}
+% \begin{macrocode}
+%<*doc>
+\DeclareRobustCommand\kerning[2]{%
+ \begingroup
+ \MakePrintable\@tempa{FD@swa}{#1}%
+ \MakePrintable\@tempb{FD@swa}{#2}%
+ \protected@xdef\FD@expression{%
+ \mathop{\protect\mathrm{k{}}}(%
+ \text{\protect\FD@typeset@string{\@tempa}}%
+ ,\penalty\FD@commapenalty
+ \text{\protect\FD@typeset@string{\@tempb}}%
+ )%
+ }%
+ \global\chardef\FD@priority=5%
+ \global\FD@bracket@level=\@ne
+ \FD@evaluate@false
+ \endgroup
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\ifiskern}
+% |\ifiskern|\marg{glyph1}\marg{glyph2}|\then|
+%
+% This command tests if there is a kern pair between \meta{glyph1} and
+% \meta{glyph2}. It's hard to say if there is a use for it, but it is
+% included for symmetry.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\ifiskern#1#2\then{
+ \def\k##1##2{\ifx T##1 \let\k\gobble_two \fi}
+ \bgroup
+ \x_cs\let{l-#2}T
+ \csname r-#1\endcsname
+ \expandafter\egroup \ifx\k\gobble_two
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\def\ifiskern#1#2\then{%
+ \generic@if{kern \typeset@glyph{#1}${}+{}$\typeset@glyph{#2} set}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\unsetkerns}
+% |\unsetkerns|\marg{left~glyph~list}\marg{right~glyph~list}
+%
+% This command unsets all kerns with a glyph in the \meta{left~glyph~list}
+% on the left and a glyph in the \meta{right~glyph~list} on the right.
+% The lists themselves are ordinary comma-separated lists. Unlike
+% |\setkern| and |\resetkern|, |\unsetkerns| actually removes the
+% kerning pairs from \TeX's memory.
+%
+% The implementation itself simply goes through |\r-|\meta{left~glyph}
+% for each element \meta{left~glyph} in \meta{left~glyph~list} and
+% |\l-|\meta{right~glyph} for each element \meta{right~glyph} in
+% \meta{right~glyph~list}, removing each |\k|\meta{token}\meta{token}
+% tripple that refers to a glyph from the opposite list as it goes
+% along. To make this test reasonably fast, the routine first ``marks''
+% the glyphs in the other list by setting the control sequences
+% |\slots-|\meta{glyph} to |U| (the letter token U). This mark is
+% later removed when the |\r-|\meta{glyph} or |\l-|\meta{glyph}
+% respectively control sequences have been gone through; the
+% |\slots-|\meta{glyph} control sequences are then set to |\relax|.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\unsetkerns#1#2{
+ \let\k\k_unless_to_U
+ \process_csep_list\make_slots_U#1,\process_csep_list,
+ \def\do##1{\x_cs\main_remove_Us{l-##1}}
+ \process_csep_list\do#2,\process_csep_list,
+ \process_csep_list\make_slots_relax#1,\process_csep_list,
+ \process_csep_list\make_slots_U#2,\process_csep_list,
+ \def\do##1{\x_cs\main_remove_Us{r-##1}}
+ \process_csep_list\do#1,\process_csep_list,
+ \process_csep_list\make_slots_relax#2,\process_csep_list,
+}
+\def\make_slots_U#1{\x_cs\let{slots-#1}U}
+\def\make_slots_relax#1{\x_cs\let{slots-#1}\x_relax}
+\def\k_unless_to_U#1#2{
+ \x_cs\ifx{slots-\expandafter\gobble_three\string#1}U \else
+ \noexpand\k\noexpand#1\noexpand#2
+ \fi
+}
+\def\main_remove_Us#1{
+ \ifx#1\x_relax \else
+ \edef#1{#1}
+ \ifx#1\empty_command \let#1\x_relax \fi
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\unsetkerns[2]{%
+ \Bheading{Remove} all kerning pairs in
+ \FD@typeset@string@set{#1}${}\times{}$\FD@typeset@string@set{#2}%
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\FD@typeset@string@set}
+% \begin{macro}{\FD@typeset@string@set@}
+% \multchanges{\cs{FD@typeset@string@set}^^A
+% \cs{FD@typeset@string@set@}}{1.916}{2001/01/02}{Macros added.
+% \cs{FD@typeset@string@set} should be used instead of
+% \cs{print@csep@list} in most occations. (LH)}
+% The |\FD@typeset@string@set| macro takes a comma-separated list of
+% string expressions as argument and typesets that list as elements of
+% a set, e.g.
+% \begin{quote}
+% |\FD@typeset@string@set{a,b,\str{c}}|
+% \end{quote}
+% is typeset as
+% \begin{quote}
+% $\{$\texttt{a}$,{}$\texttt{b}$,\mathrm{s}($\texttt{c}$)\}$
+% \end{quote}
+% \begin{macrocode}
+\def\FD@typeset@string@set#1{%
+ \toks@={}%
+ \@for\@tempa:=#1\do{%
+ \protected@edef\@tempa{%
+ \noexpand\MakePrintable \noexpand\@tempa {FD@swa}{\@tempa}%
+ }%
+ \@tempa
+ \toks@=\expandafter{\the\expandafter\toks@
+ \expandafter\do \expandafter{\@tempa}}%
+ }%
+ \expandafter\FD@typeset@string@set@ \expandafter{\the\toks@}%
+}
+\def\FD@typeset@string@set@#1{%
+ \TypesetList{$\{$}{$,\penalty\FD@commapenalty{}$}%
+ {$,\penalty\FD@commapenalty{}$}{$,\penalty\FD@commapenalty{}$}%
+ {$\}$}{$\emptyset$}{\FD@typeset@string}{#1}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\noleftkerning}
+% \changes{1.906}{1999/07/30}{Macro added. (LH)}
+% \begin{macro}{\norightkerning}
+% \changes{1.906}{1999/07/30}{Macro added. (LH)}
+% \begin{macro}{\noleftrightkerning}
+% \changes{1.906}{1999/07/30}{Macro added. (LH)}
+% The argument of these commands is the name of a glyph. The commands
+% removes all kerns on the left, on the right, and on both sides
+% respectively, of this glyph.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\noleftkerning#1{\no_kerning{l}{#1}}
+\def\norightkerning#1{\no_kerning{r}{#1}}
+\def\noleftrightkerning#1{\no_kerning{l}{#1}\no_kerning{r}{#1}}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\noleftkerning[1]{%
+ \Bheading{Remove kerns} on the left of glyphs in
+ \FD@typeset@string@set{#1}.}
+\newcommand\norightkerning[1]{%
+ \Bheading{Remove kerns} on the right of glyphs in
+ \FD@typeset@string@set{#1}.}
+\newcommand\noleftrightkerning[1]{%
+ \Bheading{Remove kerns} on any side of glyphs in
+ \FD@typeset@string@set{#1}.}
+%</doc>
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\no_kerning}
+% \changes{1.906}{1999/07/30}{Macro added. (LH)}^^A
+% \changes{1.906}{1999/08/01}{Macro thoroughly rewritten. (LH)}^^A
+% This macro is called as
+% \begin{quote}
+% |\no_kerning|\marg{side}\marg{glyph list}
+% \end{quote}
+% where \meta{side} is |l| or |r|, and \meta{glyph list} is a
+% comma-separated list of glyph names. The macro unsets all kerns on
+% the \meta{side} side of the glyphs in the \meta{glyph list}.
+%
+% \begin{macrocode}
+%<*pkg>
+\def\no_kerning#1#2{
+ \let\k\no_kerning_i
+ \def\do##1{\csname #1-##1\endcsname}
+ \bgroup
+ \aftergroup\def \aftergroup\a_macro \aftergroup{
+ \process_csep_list\do #2,\process_csep_list,
+ \aftergroup}
+ \egroup
+ \def\do##1{\expandafter\let \csname #1-##1\endcsname \x_relax}
+ \process_csep_list\do #2,\process_csep_list,
+ \let\k\no_kerning_ii
+ \def\do##1{\edef##1{##1}}
+ \a_macro
+}
+% \end{macrocode}
+% \begin{macro}{\no_kerning_i}
+% The |\no_kerning_i| macro is used by |\no_kerning| in constructing
+% a list of all glyphs that a glyph in the \meta{glyph list} has a
+% \meta{side} kern to, while avoiding repetitions.
+% \begin{macrocode}
+\def\no_kerning_i#1#2{
+ \ifx #1\x_relax \else
+ \aftergroup\do \aftergroup#1
+ \let #1\x_relax
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+% \begin{macro}{\no_kerning_ii}
+% The |\no_kerning_ii| macro is similar to the |\k_unless_to_U|
+% macro.
+% \begin{macrocode}
+\def\no_kerning_ii#1#2{
+ \ifx #1\x_relax \else \noexpand\k \noexpand#1 \noexpand#2 \fi
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+%
+%
+% \subsection{Glyph information}
+% \label{Ssec:Glyph-info}
+%
+% The glyph information is kept in the macros
+% \describecsfamily{g-\meta{name}}|\g-|\meta{name}, which expands
+% out to:
+% \begin{quote}
+% \marg{width}\marg{height}\marg{depth}\marg{italic}^^A
+% \marg{mapcommands}\marg{mapfonts}
+% \end{quote}
+% where the \meta{mapcommands} will write out VPL |MAP| fragments to a
+% |.vpl| file, and the \meta{mapfonts} will produce any |MAPFONT|
+% instructions that are needed.
+%
+%
+% \begin{macro}{\typeset@glyph}
+% \changes{1.909}{1999/10/20}{Macro added, and most commands that
+% print a glyph name changed to use this macro. (LH)}
+% \changes{1.916}{2001/01/02}{Macro redefined (made synonymous to
+% \cs{Typeset\-String\-Expression}). (LH)}
+% The |\typeset@glyph| macro takes a string expression and typesets
+% that as the name of a glyph. Currently names of glyphs are formatted
+% precisely the same as any other string expression.
+% \begin{macrocode}
+%<doc>\let\typeset@glyph=\TypesetStringExpression
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\width}
+% \begin{macro}{\height}
+% \begin{macro}{\depth}
+% \begin{macro}{\italic}
+% |\width|\marg{glyph}\\
+% |\height|\marg{glyph}\\
+% |\depth|\marg{glyph}\\
+% |\italic|\marg{glyph}
+%
+% In \package{fontinst}, these macros return the width, height,
+% depth, and italic correction of \meta{glyph} as an integer.
+% \begin{macrocode}
+%<*pkg>
+\def\width{\glyph_parameter\first_of_six}
+\def\height{\glyph_parameter\second_of_six}
+\def\depth{\glyph_parameter\third_of_six}
+\def\italic{\glyph_parameter\fourth_of_six}
+%</pkg>
+% \end{macrocode}
+%
+% In \package{fontdoc}, they print symbolic representations for the
+% corresponding integer expressions.
+% \begin{macrocode}
+%<*doc>
+\DeclareRobustCommand\width[1]{\FD@glyph@metric{w}{#1}}
+\DeclareRobustCommand\height[1]{\FD@glyph@metric{h}{#1}}
+\DeclareRobustCommand\depth[1]{\FD@glyph@metric{d}{#1}}
+\DeclareRobustCommand\italic[1]{\FD@glyph@metric{i}{#1}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\FD@glyph@metric}
+% The |\FD@glyph@metric| macro is a convenient shorthand to use when
+% defining integer-valued functions which represents some glyph
+% metric (e.g.\ \cs{height}). Its syntax is
+% \begin{quote}
+% |\FD@glyph@metric|\marg{func-name}\marg{string expression}
+% \end{quote}
+% The \meta{string expression} must be expanded.
+% \begin{macrocode}
+\def\FD@glyph@metric#1#2{%
+ \begingroup
+ \MakePrintable\@tempa{FD@swa}{#2}%
+ \protected@xdef\FD@expression{%
+ \protect\FD@integer@func{#1}{\@tempa}%
+ }%
+ \global\chardef\FD@priority=5%
+ \global\FD@bracket@level=\@ne
+ \FD@evaluate@false
+ \endgroup
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \begin{macro}{\mapcommands}
+% \begin{macro}{\mapfonts}
+% These are similar to |\width| and its companions, but they are not
+% user level commands.
+% \begin{macrocode}
+%<*pkg>
+\def\mapcommands{\glyph_parameter\fifth_of_six}
+\def\mapfonts{\glyph_parameter\sixth_of_six}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\glyph_parameter}
+% \begin{macro}{\first_of_six}
+% \begin{macro}{\second_of_six}
+% \begin{macro}{\third_of_six}
+% \begin{macro}{\fourth_of_six}
+% \begin{macro}{\fifth_of_six}
+% \begin{macro}{\sixth_of_six}
+% \begin{macro}{\glyph_metrics}
+% These macros are used to define |\width| and its friends.
+% |\glyph_parameter| takes one of the other seven for its first
+% argument and a glyph name for its second argument. The
+% |\glyph_metrics| macro can be used if one wants to get all the
+% metric variables at once.
+% \begin{macrocode}
+%<*pkg>
+\def\glyph_parameter#1#2{
+ \expandafter\expandafter\expandafter
+ #1\csname g-#2\endcsname
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\first_of_six#1#2#3#4#5#6{#1}
+\def\second_of_six#1#2#3#4#5#6{#2}
+\def\third_of_six#1#2#3#4#5#6{#3}
+\def\fourth_of_six#1#2#3#4#5#6{#4}
+\def\fifth_of_six#1#2#3#4#5#6{#5}
+\def\sixth_of_six#1#2#3#4#5#6{#6}
+% \end{macrocode}
+% \begin{macrocode}
+\def\glyph_metrics#1#2#3#4#5#6{
+ \a_count=#1
+ \b_count=#2
+ \c_count=#3
+ \d_count=#4~
+}
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+% \end{macro} \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\saved_scale}
+% \begin{macro}{\saved_mapfont}
+% \begin{macro}{\saved_raw}
+% \begin{macro}{\saved_rule}
+% \begin{macro}{\saved_special}
+% \begin{macro}{\saved_warning}
+% \begin{macro}{\saved_movert}
+% \begin{macro}{\saved_moveup}
+% \begin{macro}{\saved_push}
+% \begin{macro}{\saved_pop}
+% These are the commands allowed inside a glyph. They are initally
+% set to |\relax|, so we can |\edef| with them safely.
+% \begin{macrocode}
+\let\saved_scale\x_relax
+\let\saved_mapfont\x_relax
+\let\saved_raw\x_relax
+\let\saved_rule\x_relax
+\let\saved_special\x_relax
+\let\saved_warning\x_relax
+\let\saved_movert\x_relax
+\let\saved_moveup\x_relax
+\let\saved_push\x_relax
+\let\saved_pop\x_relax
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+%
+% When the glyph is being constructed by
+% \begin{quote}
+% |\setglyph|\marg{glyph} \meta{glyph commands} |\endsetglyph|
+% \end{quote}
+% the values of each of these parameters are kept in the following
+% variables. Except for |\glyph_width|, these are kept globally,
+% so they survive through |\push| \textellipsis\ |\pop| pairs. In
+% addition, the current vertical offset is kept locally in
+% |\glyph_voffset|. The |\glyph_maxhpos| variable globally keeps track
+% of the largest horizontal offset position reached so far (with the
+% possible exception of the current position, i.e.\ width, which may
+% well be larger).
+%
+%
+% \begin{macro}{\glyph_width}
+% \begin{macro}{\glyph_height}
+% \begin{macro}{\glyph_depth}
+% \begin{macro}{\glyph_italic}
+% \begin{macro}{\glyph_map_commands}
+% \begin{macro}{\glyph_map_fonts}
+% \begin{macro}{\glyph_voffset}
+% \begin{macro}{\glyph_maxhpos}
+% \changes{1.903}{1999/05/20}{Variable added. (LH)}
+% \begin{macrocode}
+\newcount\glyph_width
+\newcount\glyph_height
+\newcount\glyph_depth
+\newcount\glyph_italic
+\newtoks\glyph_map_commands
+\newtoks\glyph_map_fonts
+\newcount\glyph_voffset
+\newcount\glyph_maxhpos
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+% \end{macro} \end{macro} \end{macro}
+%
+% \begin{macro}{\setglyph}
+% \changes{1.916}{2001/01/06}{Added `set' to \package{fontdoc} text.
+% (LH)}
+% \begin{macro}{\gobble_glyph}
+% The |\setglyph|\marg{name} command defines |\g-|\meta{name},
+% unless |\g-|\meta{name} has already been defined.
+%
+% The reason |\g-|\meta{name} is defined before calling |\resetglyph|
+% is to make it possible to refer to ``the glyph constructed so far''
+% using |\width|\marg{name}, |\height|\marg{name}, etc.
+% \begin{macrocode}
+\def\setglyph#1{
+ \ifisglyph{\glyph_name_modifier{#1}}\then
+ \expandafter\gobble_glyph
+ \else
+ \x_cs\def{g-\glyph_name_modifier{#1}}{
+ {\the\glyph_width}{\the\glyph_height}
+ {\the\glyph_depth}{\the\glyph_italic}
+ {\the\glyph_map_commands}{\the\glyph_map_fonts}
+ }
+ \resetglyph{\glyph_name_modifier{#1}}
+ \fi
+}
+\long\def\gobble_glyph#1\endsetglyph{}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\setglyph[1]{%
+ \FD@tight@true
+ \Aheading{Set glyph `\typeset@glyph{#1}'}%
+}
+%</doc>
+%<misc>\long\def\setglyph#1\endsetglyph{}
+% \end{macrocode}
+%
+% LH 2003/01/05: A very useful trick, which unfortunately used to be
+% undocumented, is to put kerning or variable assignment commands
+% between |\setglyph| and the corresponding |\endsetglyph|. These
+% commands will then only be executed if the glyph is being set by
+% that |\setglyph|. Typical application: If \texttt{Aacutesmall}
+% is being made by skrinking \texttt{Aacute}, then it is reasonable
+% to make \texttt{Aacutesmall} kern like \texttt{Aacute} (modulo
+% some scaling factor). If on the other hand \texttt{Aacutesmall}
+% has already been set then there is less reason to believe
+% \texttt{Aacutesmall} should kern like \texttt{Aacute} (a more
+% probable guess is that it should kern like \texttt{Asmall}).
+% \end{macro} \end{macro}
+%
+% \begin{macro}{\resetglyph}
+% The |\resetglyph|\marg{name} command redefines |\g-|\meta{name},
+% regardless of whether |\g-|\meta{name} has already been defined.
+% \changes{1.923}{2002/10/20}{\cs{edef}ing \cs{glyphname}, for
+% consistency with \cs{setslot}. In principle, this could break
+% MTX files, but I doubt that it will. (LH)}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\resetglyph#1{
+ \edef\glyphname{#1}
+ \glyph_width=0
+ \global\glyph_height=0
+ \global\glyph_depth=0
+ \global\glyph_italic=0
+ \glyph_voffset=0
+ \global\glyph_maxhpos=0
+ \global\glyph_map_commands={}
+ \global\glyph_map_fonts={}
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\resetglyph[1]{%
+ \FD@tight@true
+ \Aheading{Reset glyph `\typeset@glyph{#1}'}}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\endsetglyph}
+% \begin{macro}{\endresetglyph}
+% \begin{macrocode}
+%<*pkg>
+\def\endsetglyph{
+ \x_cs\edef{g-\glyphname}
+ {{\the\glyph_width}{\the\glyph_height}
+ {\the\glyph_depth}{\the\glyph_italic}
+ {\the\glyph_map_commands}{\the\glyph_map_fonts}}
+}
+\let\endresetglyph=\endsetglyph
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\let\endsetglyph=\FD@tight@false
+\let\endresetglyph=\FD@tight@false
+%</doc>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\setscaledrawglyph}
+% \changes{1.922}{2002/09/07}{Corrected typo: should test whether the
+% \texttt{rawscale} integer exists, not whether the
+% \texttt{i-rawscale} integer exists. (LH)}
+% \begin{macro}{\setrawglyph}
+% The |\setscaledrawglyph| has the syntax
+% \begin{isyntax}
+% |\setscaledrawglyph|\marg{glyph}\marg{font}\marg{design size}^^A
+% \marg{scale}\penalty0\marg{slot}\penalty0\marg{width}\penalty0
+% \marg{height}\penalty0\marg{depth}\penalty0\marg{italic}
+% \end{isyntax}
+% It is a generalized form of the old |\setrawglyph| command, which
+% has the syntax
+% \begin{isyntax}
+% |\setrawglyph|\marg{glyph}\marg{font}\marg{design size}^^A
+% \marg{slot}\penalty0\marg{width}\penalty0
+% \marg{height}\penalty0\marg{depth}\penalty0\marg{italic}
+% \end{isyntax}
+% |\setrawglyph| is now syntactic sugar for the equivalent call of
+% |\set|\-|scaled|\-|raw|\-|glyph|.
+% \begin{macrocode}
+%<*pkg>
+\def\setrawglyph#1#2#3{
+ \setscaledrawglyph{#1}{#2}{#3}\one_thousand
+}
+% \end{macrocode}
+%
+% These commands are generated automatically, when an |.mtx| file is
+% written out by |\afmtomtx|, |\pltomtx|, or |\mtxtomtx|.
+%
+% To illustrate the difference between |\setrawglyph| and the new
+% |\set|\-|scaled|\-|raw|\-|glyph|, note that
+% \begin{quote}
+% |\setscaledrawglyph{fscaled}{xfont}{10pt}{800}{102}%|\\
+% | {300}{600}{300}{40}|
+% \end{quote}
+% produces the same \texttt{fscaled} glyph as
+% \begin{quote}
+% |\setrawglyph{f}{xfont}{10pt}{102}{375}{750}{375}{50}|\\
+% |\setglyph{fscaled} \glyph{f}{800} \endsetglyph|
+% \end{quote}
+%
+% \begin{macrocode}
+\def\setscaledrawglyph#1#2#3#4#5#6#7#8#9{
+ \if_undefined{g-\glyph_name_modifier{#1}}\then
+ \eval_expr{#4}
+ \ifnum \result=\one_thousand
+ \let\a_macro\identity_one
+ \else
+ \edef\a_macro##1{\saved_scale{\the\result}{##1}}
+ \fi
+ \eval_expr_to\a_count{#6}
+ \eval_expr_to\b_count{#7}
+ \eval_expr_to\c_count{#8}
+ \eval_expr_to\d_count{#9}
+ \ifisint{rawscale}\then
+ \e_count=\int{rawscale}
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \edef\a_macro##1{\saved_scale{\the\e_count}{\a_macro{##1}}}
+ \fi
+ \x_cs\edef{g-\glyph_name_modifier{#1}}{
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {\a_macro{\saved_raw{#2}{#5}{#1}}}
+ {\a_macro{\saved_mapfont{#2}{#3}}}
+ }
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\setrawglyph[8]{%
+ \Aheading{Glyph `\typeset@glyph{#1}'}
+ \Bheading{Taken from} slot $\TypesetIntegerExpression{#4}$ in
+ font \TypesetStringExpression{#2}%
+}
+\newcommand\setscaledrawglyph[9]{%
+ \Aheading{Glyph `\typeset@glyph{#1}'}
+ \Bheading{Taken from} slot $\TypesetIntegerExpression{#5}$ in
+ font \TypesetStringExpression{#2} \ConditionallyScaled{#4}%
+}
+%</doc>
+%<misc>\def\setrawglyph#1#2#3#4#5#6#7#8{}
+%<misc>\def\setscaledrawglyph#1#2#3#4#5#6#7#8#9{}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\setscalednotglyph}
+% \changes{1.917}{2001/03/13}{This macro should set
+% \cs{g-\meta{glyph}-not}, not \cs{g-\meta{glyph}}. (LH)}
+% \changes{1.922}{2002/09/07}{Corrected typo: should test whether
+% the \texttt{rawscale} integer exists, not whether the
+% \texttt{i-rawscale} integer exists. (LH)}
+% \begin{macro}{\setnotglyph}
+% The |\setscalednotglyph| command has the same syntax as the
+% |\set|\-|scaled|\-|raw|\-|glyph| command, i.e.,
+% \begin{isyntax}
+% |\setscalednotglyph|\marg{glyph}\marg{font}\marg{design size}^^A
+% \marg{scale}\penalty0\marg{slot}\penalty0\marg{width}\penalty0
+% \marg{height}\penalty0\marg{depth}\penalty0\marg{italic}
+% \end{isyntax}
+% It is a generalized form of the old |\setnotglyph| command, which
+% has the syntax
+% \begin{isyntax}
+% |\setnotglyph|\marg{glyph}\marg{font}\marg{design size}^^A
+% \marg{slot}\penalty0\marg{width}\penalty0\marg{height}\penalty0
+% \marg{depth}\penalty0\marg{italic}
+% \end{isyntax}
+% |\setnotglyph| is now syntactic sugar for the equivalent call of
+% |\set|\-|scaled|\-|not|\-|glyph|.
+% \begin{macrocode}
+%<*pkg>
+\def\setnotglyph#1#2#3{
+ \setscalednotglyph{#1}{#2}{#3}\one_thousand
+}
+% \end{macrocode}
+%
+% Note that only the \meta{glyph}, \meta{width}, \meta{height},
+% \meta{depth}, and \meta{italic} parameters are used. The reason for
+% having the other parameters is that |\set|\-|scaled|\-|not|\-^^A
+% |glyph| commands can be converted to |\set|\-|scaled|\-|raw|\-^^A
+% |glyph| commands when a font is reencoded. Therefore all the
+% information must be present, even if it is not used by the main
+% definition.
+%
+% To think about (LH 2000/03/02): Perhaps the \meta{mapcommands} field
+% of a \texttt{-not}-glyph should contain a |\glyphwarning|, just in
+% case anyone tries to use one?
+% \begin{macrocode}
+\def\setscalednotglyph#1#2#3#4#5#6#7#8#9{
+ \if_undefined{g-\glyph_name_modifier{#1}-not}\then
+ \eval_expr_to\a_count{#6}
+ \eval_expr_to\b_count{#7}
+ \eval_expr_to\c_count{#8}
+ \eval_expr_to\d_count{#9}
+ \ifisint{rawscale}\then
+ \e_count=\int{rawscale}
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \fi
+ \x_cs\edef{g-\glyph_name_modifier{#1}-not}{
+ {\the\a_count}
+ {\the\b_count}
+ {\the\c_count}
+ {\the\d_count}
+ {}{}
+ }
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\setnotglyph[8]{%
+ \Aheading{Pseudoglyph `\typeset@glyph{#1-not}'}%
+}
+\newcommand\setscalednotglyph[9]{%
+ \setnotglyph{#1}{#2}{#3}{#5}{#6}{#7}{#8}{#9}%
+}
+%</doc>
+%<misc>\let\setnotglyph=\setrawglyph
+%<misc>\let\setscalednotglyph=\setscaledrawglyph
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\unsetglyph}
+% The |\unsetglyph|\marg{name} command makes |\g-|\meta{name}
+% undefined.
+%
+% \begin{macrocode}
+%<pkg>\def\unsetglyph#1{\x_cs\let{g-#1}\x_relax}
+%<doc>\newcommand\unsetglyph[1]{%
+%<doc> \Aheading{Unset glyph `\typeset@glyph{#1}'}}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Glyph commands}
+%
+% The \meta{glyph commands} are:
+% \changes{1.908}{1999/08/22}{Glyph commands avoid \cs{edef}ing old
+% contents of \cs{glyph_map_commands} and \cs{glyph_map_fonts}. (LH)}
+% \begin{macro}{\glyph}
+% |\glyph|\marg{glyph}\marg{scale}
+% \changes{1.900}{1999/02/08}{Avoids scaling by 1000. (LH)}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\glyph#1#2{
+ \glyph_parameter\glyph_metrics{#1}
+ \eval_expr_to\e_count{#2}
+ \ifnum \e_count=\one_thousand
+ \edef\a_macro{\mapcommands{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \edef\a_macro{\mapfonts{#1}}
+ \else
+ \multiply \a_count \e_count \l_rounded_thousandths\a_count
+ \multiply \b_count \e_count \l_rounded_thousandths\b_count
+ \multiply \c_count \e_count \l_rounded_thousandths\c_count
+ \multiply \d_count \e_count \l_rounded_thousandths\d_count
+ \edef\a_macro{\saved_scale{\the\e_count}{\mapcommands{#1}}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \edef\a_macro{\saved_scale{\the\e_count}{\mapfonts{#1}}}
+ \fi
+ \advance \glyph_width \a_count
+ \advance \b_count \glyph_voffset
+ \ifnum \glyph_height<\b_count \global\glyph_height=\b_count \fi
+ \advance \c_count -\glyph_voffset
+ \ifnum \glyph_depth<\c_count \global\glyph_depth=\c_count \fi
+ \global\glyph_italic=\d_count
+ \global\glyph_map_fonts\expandafter{
+ \the\expandafter\glyph_map_fonts \a_macro
+ }
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\glyph[2]{%
+ \Bheading{Glyph} `\typeset@glyph{#1}' \ConditionallyScaled{#2}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\glyphrule}
+% |\glyphrule|\marg{width}\marg{height}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\glyphrule#1#2{
+ \eval_expr_to\b_count{#1} \eval_expr_to\c_count{#2}
+ \advance\glyph_width by \b_count
+ \g_eval_expr_to\glyph_depth{\max\glyph_depth{-\glyph_voffset}}
+ \g_eval_expr_to\glyph_height{
+ \max\glyph_height{\add\glyph_voffset\c_count}
+ }
+ \global\glyph_italic=0
+ \edef\a_macro{\saved_rule{\the\b_count}{\the\c_count}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\glyphrule[2]{%
+ \Bheading{Rule} $\TypesetIntegerExpression{#1}$ by
+ $\TypesetIntegerExpression{#2}$%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\glyphspecial}
+% \begin{macro}{\glyphwarning}
+% |\glyphspecial|\marg{string}\\
+% |\glyphwarning|\marg{string}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\glyphspecial#1{
+ \edef\a_macro{\saved_special{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+\def\glyphwarning#1{
+ \edef\a_macro{\saved_warning{#1}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\glyphspecial[1]{%
+ \Bheading{Special} `\TypesetStringExpression{#1}'}
+\newcommand\glyphwarning[1]{%
+ \Bheading{Warning} `\TypesetStringExpression{#1}'}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\movert}
+% \changes{1.903}{1999/05/20}{Added update of \cs{glyph_maxhpos}. (LH)}
+% \begin{macro}{\moveup}
+% |\movert|\marg{xoffset}\\
+% |\moveup|\marg{yoffset}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\movert#1{
+ \eval_expr{#1}
+ \ifnum \glyph_maxhpos<\glyph_width
+ \global\glyph_maxhpos\glyph_width
+ \fi
+ \ifnum 0=\result \else
+ \advance\glyph_width by \result
+ \edef\a_macro{\saved_movert{\the\result}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\moveup#1{
+ \eval_expr{#1}
+ \ifnum\result=0\else
+ \advance\glyph_voffset by \result
+ \edef\a_macro{\saved_moveup{\the\result}}
+ \global\glyph_map_commands\expandafter{
+ \the\expandafter\glyph_map_commands \a_macro
+ }
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\movert[1]{\Bheading{Rt}~$\TypesetIntegerExpression{#1}$}
+\newcommand\moveup[1]{\Bheading{Up}~$\TypesetIntegerExpression{#1}$}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\push}
+% \changes{1.907}{1999/08/02}{Removed the \cs{edef}. (LH)}
+% \begin{macro}{\pop}
+% \changes{1.903}{1999/05/20}{Added update of \cs{glyph_maxhpos}. (LH)}
+% \changes{1.907}{1999/08/02}{Removed the \cs{edef}. (LH)}
+% \begin{macrocode}
+%<*pkg>
+\def\push{
+ \bgroup
+ \global\glyph_map_commands\expandafter{
+ \the\glyph_map_commands \saved_push
+ }
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\pop{
+ \ifnum \glyph_maxhpos<\glyph_width
+ \global\glyph_maxhpos\glyph_width
+ \fi
+ \egroup
+ \global\glyph_map_commands\expandafter{
+ \the\glyph_map_commands \saved_pop
+ }
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\push{\Bheading{Push}}
+\newcommand\pop{\Bheading{Pop}}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\resetwidth}
+% \begin{macro}{\resetheight}
+% \begin{macro}{\resetdepth}
+% \begin{macro}{\resetitalic}
+% |\resetwidth|\marg{width}\\
+% |\resetheight|\marg{height}\\
+% |\resetdepth|\marg{depth}\\
+% |\resetitalic|\marg{italic}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\resetwidth#1{\movert{\sub{#1}\glyph_width}}
+\def\resetheight{\g_eval_expr_to\glyph_height}
+\def\resetdepth{\g_eval_expr_to\glyph_depth}
+\def\resetitalic{\g_eval_expr_to\glyph_italic}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\resetwidth[1]{%
+ \Bheading{Reset width to $\TypesetIntegerExpression{#1}$}%
+}
+\newcommand\resetheight[1]{%
+ \Bheading{Reset height to $\TypesetIntegerExpression{#1}$}%
+}
+\newcommand\resetdepth[1]{%
+ \Bheading{Reset depth to $\TypesetIntegerExpression{#1}$}%
+}
+\newcommand\resetitalic[1]{%
+ \Bheading{Reset italic to $\TypesetIntegerExpression{#1}$}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\glyphpcc}
+% Some syntactic sugar: |\glyphpcc| could do with optimization.
+% \begin{quote}
+% |\glyphpcc|\marg{glyph}\marg{xoffset}\marg{yoffset}
+% \end{quote}
+% \changes{1.925}{2003/05/28}{Added check that the glyph used is
+% defined; we get an ugly error if it isn't. (LH)}
+% \changes{1.932}{2005/06/17}{Changed error message to warning when a
+% corresponding notglyph exists. (LH) This deals with an issue
+% regarding composites in fonts which have been reencoded to
+% something not a superset of \texttt{8a}.}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\glyphpcc#1#2#3{
+ \ifisglyph{\glyph_name_modifier{#1}}\then
+ \push
+ \movert{#2}
+ \moveup{#3}
+ \glyph{\glyph_name_modifier{#1}}{\one_thousand}
+ \pop
+ \else\ifisglyph{\glyph_name_modifier{#1}-not}\then
+ \fontinstwarning{\string\glyphpcc}{
+ Base~glyph~`\glyph_name_modifier{#1}'~not~appended,\messagebreak
+ because~it~is~so~far~unencoded~in~the~glyph~base
+ }
+ \else
+ \fontinsterror{\string\glyphpcc}{
+ Base~glyph~not~set.\messagebreak
+ This~could~be~a~sign~that~the~AFM~file~is~buggy
+ }\error_help_a
+ \fi\fi
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\def\glyphpcc#1#2#3{
+ \push
+ \movert{#2}
+ \moveup{#3}
+ \glyph{#1}{1000}
+ \pop
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\glyphbboxright}
+% \changes{1.903}{1999/05/20}{Macro added. (LH)}
+% The |\glyphbboxright| command is a valid integer expression, but
+% its value is only meaningful inside a |\setglyph| \textellipsis\
+% |\endsetglyph| or |\resetglyph| \textellipsis\ |\endresetglyph|
+% structure. There its value is almost the horizontal position of
+% the right edge of the bounding box for the glyph constructed so
+% far---in reality it is the greatest horizontal offset reached so
+% far.
+%
+% \begin{macrocode}
+%<pkg>\def\glyphbboxright{\max\glyph_width\glyph_maxhpos}
+%<*doc>
+\DeclareRobustCommand\glyphbboxright{%
+ \gdef\FD@expression{\protect\mathrm{glyphbboxright}}
+ \global\chardef\FD@priority=\tw@
+ \global\FD@bracket@level=\z@
+ \FD@evaluate@false
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\samesize}
+% \changes{1.903}{1999/05/20}{Added behaviour for nonexistent glyph
+% (based on a suggestion from Hilmar Schlegel) and fixed typo in
+% \package{fontdoc}. (LH)}
+% |\samesize|\marg{glyph}
+%
+% \begin{macrocode}
+%<*pkg>
+\def\samesize#1{
+ \if_undefined{g-\glyph_name_modifier{#1}}\then
+ \resetwidth{\glyphbboxright}
+ \else
+ \expandafter\expandafter\expandafter
+ \same_size\csname g-\glyph_name_modifier{#1}\endcsname
+ \fi
+}
+\def\same_size#1#2#3#4#5#6{
+ \movert{\sub{#1}\glyph_width}
+ \global\glyph_height=#2
+ \global\glyph_depth=#3
+ \global\glyph_italic=#4
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\newcommand\samesize[1]{%
+ \Bheading{Reset dimensions to those of `\typeset@glyph{#1}'.}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\ifisglyph}
+% The control flow command:
+% \changes{1.923}{2002/10/20}{Using \cs{if_defined}. (LH)}
+% \begin{macrocode}
+%<pkg>\def\ifisglyph#1\then{\if_defined{g-#1}\then}
+% \end{macrocode}
+% \changes{1.911}{1999/11/30}{\protect\protect\protect\Module{misc}
+% definition added. (LH)}
+% |\ifisglyph| evaluates to false in \Module{misc}, since this avoids
+% uses of various metric integer expressions (such as |\width|,
+% |\height|, etc.) that are not defined there.
+% \begin{macrocode}
+%<doc>\def\ifisglyph#1\then{\generic@if{glyph \typeset@glyph{#1} set}}
+%<misc>\def\ifisglyph#1\then{\iffalse}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\ifareglyphs}
+% \changes{1.917}{2001/03/17}{Macro added. (LH)}
+% The |\ifareglyphs| command test if all glyphs in a comma-separeted
+% list of glyphs are set. The syntax is
+% \begin{quote}
+% |\ifareglyphs|\marg{glyph list}|\then|
+% \end{quote}
+% The implementation relies on that |\if_true| and |\if_false| do not
+% count when \TeX\ is skipping text that is balanced with respect to
+% |\if|s and |\fi|s.
+% \begin{macrocode}
+%<*pkg>
+\def\ifareglyphs#1\then{
+ \process_csep_list{\if_is_glyph}#1,\process_csep_list,
+ \if_true
+}
+\def\if_is_glyph#1{
+ \if_undefined{g-#1}\then \expandafter\if_false \fi
+}
+%</pkg>
+%<misc>\let\ifareglyphs=\ifisglyph
+%<*doc>
+\def\ifareglyphs#1\then{%
+ \generic@if{all glyphs in \FD@typeset@string@set{#1} are set}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \section{Converting an ETX file to a (V)PL file}
+%
+% \subsection{Lowest-level user interface}
+%
+% \DescribeMacro{\etxtovpl}
+% The macro:
+% \begin{quote}
+% |\etxtovpl|\marg{encoding list}\marg{vplfile}
+% \end{quote}
+% writes a virtual font (as a virtual property list) with the
+% encoding specified by the items in the \meta{encoding list},
+% which typically are names of ETX files.
+% (This macro is called by |\installfont|.)
+%
+% \DescribeMacro{\etxtopl}
+% The macro:
+% \begin{quote}
+% |\etxtopl|\marg{encoding list}\marg{plfile}
+% \end{quote}
+% writes a font (as a property list) with the encoding
+% specified by the items in the \meta{encoding list},
+% which typically are names of ETX files.
+% (This macro is called by |\installrawfont|.)
+%
+% \multchanges{\cs{etxtovpl}\cs{etxtopl}}{1.923}{2002/10/24}{The
+% first argument of these macros is now a comma-separated list
+% of ETX files, and the items may be subjected to modifier
+% clauses. (LH)}
+%
+% \begin{macro}{\etxtovpl}
+% \changes{1.923}{2002/10/25}{The program is called \texttt{vptovf},
+% not \texttt{vpltovf}. (LH)}
+% \begin{macro}{\etxtopl}
+% \begin{macrocode}
+%<*pkg>
+\def\etxtovpl#1#2{{
+ \def\vpl_extension{vpl}
+ \def\vpl_title{COMMENT}
+ \def\vpl_font{virtual~font}
+ \def\vpl_Font{Virtual~font}
+ \def\vpl_call{\string\etxtovpl{#1}{#2}}
+ \def\vpl_to_vf##1{vptovf~##1.vpl~##1.vf~##1.tfm}
+ \a_toks={}
+ \process_csep_list\make_inputetx #1,\process_csep_list,
+ \expandafter\etx_to_font \expandafter{\the\a_toks}{#2}
+}}
+\def\etxtopl#1#2{{
+ \def\vpl_extension{pl}
+ \def\vpl_title{COMMENT}
+ \def\vpl_font{font}
+ \def\vpl_Font{Font}
+ \def\vpl_call{\string\etxtopl{#1}{#2}}
+ \def\vpl_to_vf##1{pltotf~##1.pl~##1.tfm}
+ \_including_map_false
+ \global\rawfont_scaling=-\p@
+ \a_toks={}
+ \process_csep_list\make_inputetx #1,\process_csep_list,
+ \expandafter\etx_to_font \expandafter{\the\a_toks}{#2}
+}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{switch}{_including_map_}
+% \changes{1.900}{1998/10/02}{New switch that can inhibit writing of
+% VPL-specific properties. (LH)}
+% The v\,1.5 method of controlling whether \texttt{MAP} and
+% \texttt{MAPFONT} properties should be written requires that some
+% code is put in an awkward place (in |\make_mapfonts| rather than
+% |\make_characters|). As the code was being reorganised anyway, it
+% seemed best to let a switch control this instead. If
+% |\if_including_map_| is true, \texttt{MAP} and \texttt{MAPFONT}
+% properties are written to the file (which should be a VPL), if it is
+% false then they are not written to the file (which is then a normal
+% PL).
+% \begin{macrocode}
+\newif\if_including_map_
+\_including_map_true
+% \end{macrocode}
+% \end{switch}
+%
+% \begin{macro}{\make_inputetx}
+% The |\make_inputetx| macro takes a single argument that should have
+% the form
+% \begin{quote}
+% \meta{file name root}\meta{optional modifiers}
+% \end{quote}
+% as explained in the comments to |\input_mtx_file|. The effect of
+% this macro is to append some commands (usually
+% |\inputetx|\marg{file name root}) to |\a_toks|. This may however
+% change if some clause in the \meta{optional modifiers} redefines
+% |\a_macro|.
+% \changes{1.923}{2002/10/24}{Macro added. (LH)}
+% \begin{macrocode}
+\def\make_inputetx#1{
+ \def\a_macro{\noexpand\inputetx{\file_name}}
+ \get_file_name #1~{}~\par
+ \edef\a_macro{\a_macro}
+ \a_toks=\expandafter{ \the\expandafter\a_toks \a_macro}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\IFKW-mtxasetx}
+% The \texttt{mtxasetx} modifier clause causes the \meta{encoding
+% list} item in question to be input using |\input_mtx_as_etx| rather
+% than |\inputetx|. This makes it possible to use the |\setrawglyph|
+% and |\setscaledrawglyph| commands in an MTX file as a poor
+% substitute for a proper ETX file. This is sometimes useful for
+% making proofs.
+% \changes{1.923}{2002/10/24}{Macro added. (LH)}
+% \begin{macrocode}
+\x_cs\def{IFKW-mtxasetx}{
+ \def\a_macro{\noexpand\input_mtx_as_etx{\file_name}}
+ \get_keyword
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\etx_to_font}
+% |\etx_to_font|\marg{encoding commands}\marg{fontfile} makes
+% a (V)PL file whose encoding is specified by the \meta{encoding
+% commands}. These are usually just one or a few |\inputetx|
+% commands, as the specification of an encoding usually requires much
+% more code than is convenient to provide as an argument.
+% \changes{1.923}{2002/10/24}{Made the first argument a list of
+% commands. Renamed \cs{vpl_caller} to \cs{vpl_call}; it is now
+% assumed to contain the arguments as well. (LH)}
+% \begin{macrocode}
+\def\etx_to_font#1#2{
+ \make_assignments{#1}
+ \open_out{#2.\vpl_extension}
+ \top_of_pl_hook
+ \out_line{(\vpl_title\space\vpl_font\space
+ #2~created~by~fontinst~v\fontinstversion)}
+ \out_line{}
+ \out_line{(COMMENT~Filename:~#2.\vpl_extension)}
+ \out_line{(COMMENT~Created~by:~tex~\jobname)}
+ \out_line{(COMMENT~Created~using:~\vpl_call)}
+ \out_line{}
+ \out_line{(COMMENT~This~file~can~be~turned~into~a~\vpl_font\space
+ with)}
+ \out_line{(COMMENT~\vpl_to_vf{#2})}
+ \out_line{}
+ \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)}
+ \out_line{}
+ \make_header{#1}
+ \if_including_map_ \make_mapfonts{#1} \fi
+ \make_fontdimens{#1}
+ \make_ligtable{#1}
+ \make_characters{#1}
+ \make_tidy{#1}
+ \out_line{}
+ \out_line{(COMMENT~END~OF~FILE~#2.\vpl_extension)}
+ \close_out{\vpl_Font}
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\pre_first_etx_pass_hook}
+% \begin{macro}{\pre_second_etx_pass_hook}
+% \begin{macro}{\pre_third_etx_pass_hook}
+% \begin{macro}{\pre_fourth_etx_pass_hook}
+% \begin{macro}{\post_first_etx_pass_hook}
+% \begin{macro}{\post_second_etx_pass_hook}
+% \begin{macro}{\post_third_etx_pass_hook}
+% \begin{macro}{\post_fourth_etx_pass_hook}
+% \begin{macro}{\tidying_up_hook}
+% \multchanges{\cs{pre_first_etx_pass_hook}^^A
+% \cs{pre_second_etx_pass_hook}\cs{pre_third_etx_pass_hook}^^A
+% \cs{pre_fourth_etx_pass_hook}\cs{post_first_etx_pass_hook}^^A
+% \cs{post_second_etx_pass_hook}\cs{post_third_etx_pass_hook}^^A
+% \cs{post_fourth_etx_pass_hook}\cs{tidying_up_hook}}{1.900}^^A
+% {1998/09/30}{ETX-to-VPL hooks added. (LH)}
+% \begin{macro}{\top_of_pl_hook}
+% \changes{1.912}{2000/01/29}{Property list hook added. (LH)}
+% As the |\etxtovpl| and |\etxtopl| macros are the
+% lowest-level interfaces to what they do that are available in
+% \package{fontinst} and as the amount of code they execute is really
+% quite large, I suspect that users may occationally have need of
+% some robust mechanism for inserting extra code at well specified
+% positions. Such a mechanism is provided by the following hooks:
+% \begin{macrocode}
+\let\pre_first_etx_pass_hook\x_relax
+\let\pre_second_etx_pass_hook\x_relax
+\let\pre_third_etx_pass_hook\x_relax
+\let\pre_fourth_etx_pass_hook\x_relax
+\let\post_first_etx_pass_hook\x_relax
+\let\post_second_etx_pass_hook\x_relax
+\let\post_third_etx_pass_hook\x_relax
+\let\post_fourth_etx_pass_hook\x_relax
+\let\tidying_up_hook\x_relax
+\let\top_of_pl_hook\x_relax
+% \end{macrocode}
+% The first nine are executed at the positions of the ETX-to-VPL
+% file generation that their name indicate. |\top_of_pl_hook| is
+% slightly different---it is executed right after a PL or VPL file
+% is opened for writing. Thus it is also used by the MTX-to-PL system.
+%
+% To include code in one of them, one should write things like
+% \begin{quote}
+% |\add_to\pre_first_etx_pass_hook|\marg{extra code}
+% \end{quote}
+% I (LH) have the following in my \texttt{fontinst.rc} file\relax
+% \SortIndex{fontinst.rc file}{\texttt{fontinst.rc} file}
+% \begin{quote}
+% |\add_to\top_of_pl_hook{\out_line{(COMMENT~-*-Text-*-)}}|
+% \end{quote}
+% Without it, my text editor annoys me by assuming that \texttt{.pl}
+% stands for Perl.
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+% \end{macro} \end{macro} \end{macro} \end{macro} \end{macro}
+%
+%
+% \subsection{Glyph to slot assignments}
+%
+% \changes{1.900}{1998/12/06}{New method of storing slot assignments.
+% (LH)}
+% The way \package{fontinst} has traditionally kept track
+% of which glyph goes to which slot---information which is needed when
+% writing the |LIGTABLE| in a (V)PL, for |\nextlarger|, and for the
+% varchar commands---is by storing the slot number in the integer
+% whose name is the name of the glyph. There are two main problems with
+% this implementation: (i)~If a user sets an integer which happens to
+% have the same name as a glyph that is not assigned to any slot, then
+% kerns for that unused glyph might be written to the file, accidentally
+% creating a kerning pair where there should be none. (ii)~It is only
+% possible to store one slot number per glyph, so if one uses the same
+% glyph for several slots then \package{fontinst} can only write kerns
+% (and ligatures) for one of the occurences, despite the fact that all
+% occurences have the same typographical need for them. These problems
+% do only occur for glyphs on the right side of a ligature/kerning
+% pair, but they are still serious enough. This part of
+% \package{fontinst} has therefore been reimplemented.
+%
+% \changes{1.910}{1999/11/04}{Changed the way slot numbers are stored
+% in \cs{slots-}\meta{glyph} control sequences. (LH)}
+% The new implementation does not use integers, instead it uses a new
+% family of macros with names on the form |\slots-|\meta{glyph}^^A
+% \describecsfamily{slots-\meta{glyph}}. These macros expand to
+% sequences of |\do|\thinspace\meta{character}, where \meta{character}
+% is a category 12 (other) token whose character code equals the slot
+% number.
+%
+% In the entire space of such names, each slot should be mentioned
+% at most once, with one exception, namely the slot which serves as
+% right boundary marker, which may occur twice (once for the glyph
+% which actually is assigned to the slot and once for the right boundary
+% marker glyph). To detect whether there is a collision between these two
+% uses of the slot, the right boundary marker glyph uses |\rboundary_do|
+% instead of |\do| and the glyph whose slot serves as boundarychar uses
+% |\rbserver_do| instead of |\do|. By redefining these two control
+% sequences to generate a warning message when appropriate, the occurence
+% of such a collision can be brought to the user's attention.
+%
+% \changes{1.900}{1998/12/11}{Added compability code for the old
+% interface for boundary ligatures and kerns. (LH)}
+% As it turned out to not be such a big deal, some extra code (protected
+% by a \package{docstrip} switch called \Module{boundaryCompability})
+% that makes \package{fontinst} compatible with the previous syntax for
+% boundary handling has been included. I don't recommend using
+% it though, since it makes \package{fontinst} store almost all slot
+% numbers in two places.
+%
+%
+% \begin{macro}{\make_assignments}
+% \begin{macrocode}
+\def\make_assignments#1{
+ \let\do_slot=\assign_slot
+ \let\end_do_slot=\end_assign_slot
+ \def\do_boundary{\bgroup
+ \let\makerightboundary=\bad_makerightboundary
+ }
+ \let\endsetleftboundary=\egroup
+ \let\makerightboundary=\assign_rboundary
+ \pre_first_etx_pass_hook
+ #1
+ \post_first_etx_pass_hook
+ \let\end_do_slot=\empty_command
+ \let\do_boundary=\x_relax
+ \let\endsetleftboundary=\x_relax
+ \let\makerightboundary=\gobble_one
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\assign_slot}
+% \begin{macro}{\end_assign_slot}
+% \changes{1.907}{1999/08/20}{Slots are not assigned to glyphs that
+% do not exist. (LH)}
+% |\assign_slot| begins the assignment of a slot to a glyph.
+% |\end_assign_slot| completes it. In the time between these two,
+% some information is stored in |\a_toks|, so that it can be
+% modified by an intervening |\makerightboundary| (which is then
+% |\assign_rboundary|).
+%
+% Note that the code below will not reset |\lccode0|. The value of
+% this register should be considered uncertain while a ligful PL
+% or VPL file is written, i.e., in ETX files.
+% \SortIndex{lccode0}{\cs{lccode\,0} register\encapchar usage}
+% \begin{macrocode}
+\def\assign_slot{\a_toks={\do}}
+\begingroup
+ \catcode0=12
+ \gdef\end_assign_slot{
+ \ifisglyph\slot_name\then
+ \lccode0=\slot_number
+ \lowercase{
+ \expandafter\add_to
+ \csname slots-\slot_name\expandafter\endcsname
+ \expandafter{\the\a_toks^^@}
+ }
+%<boundaryCompability> \x_resetint\slot_name\slot_number
+ \fi
+ }
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\assign_rboundary}
+% \begin{macro}{\bad_makerightboundary}
+% |\assign_rboundary| is what |\makerightboundary| is when it is
+% assigning a slot to act as right boundary marker.
+%
+% |\bad_makerightboundary| is what |\makerightboundary| temporarily
+% gets set to between |\setleftboundary| and |\endsetleftboundary|.
+% \begin{macrocode}
+ \gdef\assign_rboundary#1{
+ \lccode0=\slot_number
+ \lowercase{\x_cs\add_to{slots-#1}{\rboundary_do^^@}}
+ \x_setint{\percent_char boundarychar}\slot_number
+ \a_toks={\rbserver_do}
+ }
+\endgroup
+\def\bad_makerightboundary#1{
+ \errhelp={The~left~boundary~is~not~a~slot,~so~it~cannot~serve~
+ as~right~boundary.}
+ \errmessage{Incorrect~use~of~\string\makerightboundary}
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+% \begin{macro}{\get_slot_num}
+% \changes{1.910}{1999/11/04}{Removed redefinition of \cs{do} to
+% \cs{gobble_one} from temporary definition of \cs{do}, since a
+% \cs{slots-} list usually contains only one or two elements
+% anyway. (LH)}
+% It is sometimes necessary to get the number of an arbitrary slot
+% given only the name of the glyph which has been assigned to the
+% slot. In such situations, the call
+% \begin{quote}
+% |\get_slot_num{|\meta{glyph}|}|
+% \end{quote}
+% will set |\result| to the number of one such slot if the glyph has
+% been assigned to some slot, or set |\result| to minus one if the glyph
+% has not been assigned to a slot.
+% \begin{macrocode}
+\def\get_slot_num#1{
+%<*!boundaryCompability>
+ \global\result=-1
+ \bgroup
+ \def\do{\global\result=`}
+ \let\rbserver_do=\do
+ \let\rboundary_do=\gobble_one
+ \csname slots-#1\endcsname
+ \egroup
+%</!boundaryCompability>
+%<*boundaryCompability>
+ \ifisint{#1}\then
+ \global\result=\int{#1}
+ \else
+ \global\result=-1
+ \fi
+ \x_relax
+%</boundaryCompability>
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\ifisinslot}
+% The call |\ifisinslot|\marg{glyph}\marg{slot}|\then| can be used to
+% test whether glyph \meta{glyph} has been assigned to slot \meta{slot}.
+% Both then-part and else-part of the conditional will however be
+% ignored when the ETX file is read the first time, since the
+% assignment of glyph to slots need not have been completed yet.
+% \begin{macrocode}
+\def\ifisinslot#1#2\then{
+ \ifx \makerightboundary\gobble_one
+% \end{macrocode}
+% This is used to test if the ETX file is being read in for the first
+% time. It is a bit hacky, but it is efficient.
+% \begin{macrocode}
+ \eval_expr{#2}
+ \begingroup
+ \def\do##1{\ifnum `##1=\result \let\do=\gobble_one \fi}
+ \def\rbserver_do{\do}
+ \let\rboundary_do=\gobble_one
+ \csname slots-#1\endcsname
+ \expandafter\endgroup
+ \ifx \do\gobble_one
+ \expandafter\expandafter \expandafter\if_true
+ \else
+ \expandafter\expandafter \expandafter\if_false
+ \fi
+ \else
+ \expandafter\gobble_if
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \begin{macrocode}
+%<*doc>
+\def\ifisinslot#1#2\then{%
+ \generic@if{glyph \typeset@glyph{#1} assigned to slot
+ $\TypesetIntegerExpression{#2}$}%
+}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{The header, mapfonts, and fontdimens}
+%
+% \changes{1.913}{2000/02/26}{Using \cs{make_factor} for making PL
+% reals, rather than \cs{afm_convert}+\cs{vpl_real}.
+% \cs{scaled_design_size} replaced by new dimen \cs{mapfont_scaling} for
+% determining mapfont atsize. (LH)}
+%
+% \begin{macro}{\mapfont_scaling}
+% The |\mapfont_scaling| dimen is used for calculating how much a mapfont
+% has been scaled, for use in \texttt{FONTAT} properties, and for
+% selecting the correct mapfont. It is initialized to $1$.
+% \begin{macrocode}
+%<*pkg>
+\newdimen\mapfont_scaling
+\mapfont_scaling=1pt
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\rawfont_scaling}
+% The |\rawfont_scaling| dimen is used for communicating the scaling
+% that has been applied to a raw font---a font being installed using
+% |\install|\-|rawfont|\penalty0---out to that macro. |\rawfont_|\-^^A
+% |scaling| should always be globally assigned.
+% \changes{1.913}{2000/03/21}{Dimen added. (LH)}
+% \begin{macrocode}
+\newdimen\rawfont_scaling
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\scaled_design_size}
+% \begin{macro}{\afm_convert}
+% The call
+% \begin{quote}
+% |\afm_convert|\meta{dimen}|=|\meta{integer expression}|;|
+% \end{quote}
+% converts a count into a dimen, assuming the count is a number
+% of AFM units. I'll assume that the largest dimension I'll have
+% to deal with is 131\,pt, to try to minimize rounding errors.
+%
+% \begin{macrocode}
+% \newdimen\scaled_design_size
+% \end{macrocode}
+% \begin{macrocode}
+% \def\afm_convert#1=#2;{
+% \eval_expr{#2}
+% #1=\scaled_design_size
+% \divide#1 by 8
+% \multiply #1 by \result
+% \divide #1 by \one_thousand
+% \multiply#1 by 8
+% }
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+% \begin{macro}{\vpl_real}
+% \begin{macro}{\vpl_int}
+% The commands |\vpl_real|\meta{dimen} and |\vpl_int|\meta{count} print
+% a dimension and integer respectively in (V)PL syntax.
+%
+% \begin{macrocode}
+\def\vpl_real#1{R~\expandafter\lose_measure\the#1}
+\def\vpl_int#1{D~\the#1}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% The count register |\boundary_char| has been removed, since
+% the reimplementation of the left and right boundaries have drastically
+% decreased the need to check which slot serves as the right boundary.
+% Instead the integer |%boundarychar| (whose name cannot normally be typed)
+% is used to store the number of this slot, but the user need never (and
+% should not) access this integer directly. If the integer is not set
+% then no slot serves as boundarychar.
+% \changes{1.900}{1998/12/04}{\cs{boundary_char} count register
+% removed. Right boundary slot number is now stored in the
+% \texttt{\%boundarychar} integer instead. (LH)}
+%
+% \begin{macro}{\side_bearings}
+% \begin{macro}{\curr_bearings}
+% These two dimens are used by the letterspacing mechanism.
+% \begin{macrocode}
+\newdimen\side_bearings
+\newdimen\curr_bearings
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+% \begin{macro}{\make_header}
+% \begin{macrocode}
+\def\make_header#1{
+ \global\font_count=0
+ \setdim{designsize}{10pt}
+ \a_dimen=\dim{designsize}
+ \out_line{(DESIGNSIZE~\vpl_real\a_dimen)}
+ \x_setstr{codingscheme}{UNKNOWN}
+ \out_line{(CODINGSCHEME~\str{codingscheme})}
+%<*boundaryCompability>
+ \ifisint{boundarychar}\then
+ \x_setint{\percent_char boundarychar}{\int{boundarychar}}
+ \immediate\write16{Please~use~\string\setleftboundary\space
+ and/or~\string\makerightboundary^^J
+ instead~of~setting~the~boundarychar~integer.}
+ \fi
+%</boundaryCompability>
+ \ifisint{\percent_char boundarychar}\then
+ \a_count=\int{\percent_char boundarychar}
+ \out_line{(BOUNDARYCHAR~\vpl_int\a_count)}
+ \fi
+ \x_setint{letterspacing}{0}
+ \side_bearings=\make_factor{\int{letterspacing}}\half_point
+ \x_setint{minimumkern}{0}
+ \minimum_kern=\int{minimumkern}
+ \out_line{}
+}
+% \end{macrocode}
+% \changes{1.900}{1999/01/20}{Removed test for no letterspacing. (LH)}
+% \changes{1.900}{1999/01/20}{Made integer expression \cs{div} a
+% dimen \cs{divide}. (LH)}
+% \end{macro}
+%
+%
+% \begin{macro}{\make_mapfonts}
+% \begin{macrocode}
+\def\make_mapfonts#1{
+ \let\saved_scale\vpl_scale
+ \let\saved_mapfont\vpl_mapfont
+ \let\do_slot=\do_mapfont
+ \pre_second_etx_pass_hook
+ #1
+ \post_second_etx_pass_hook
+ \out_line{}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\do_mapfont}
+% |\do_mapfont| produces a |MAPFONT| entry for each font used by
+% glyph |\slot_name|.
+% \begin{macrocode}
+\def\do_mapfont{
+ \ifisglyph\slot_name\then
+ \mapfonts\slot_name
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% The following commands can be used in the \meta{mapfonts} glyph
+% parameter.
+%
+% \begin{macro}{\vpl_scale}
+% \begin{macrocode}
+\def\vpl_scale#1#2{{
+ \mapfont_scaling=\make_factor{#1}\mapfont_scaling
+ #2
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_mapfont}
+% \changes{1.904}{1999/06/16}{Added \cs{record_usage}. (LH)}
+% \changes{1.913}{2000/02/26}{Mapfont number control sequences are
+% named \cs{\meta{scaling factor}pt-\meta{font}} instead of
+% \cs{\meta{font}-\meta{scaling factor}pt}. They are also made
+% \cs{mathchardef}s. (LH)}
+% \begin{macrocode}
+\def\vpl_mapfont#1#2{
+ \a_dimen=#2
+ \if_undefined{\the\mapfont_scaling-#1}\then
+ \global\x_cs\mathchardef{\the\mapfont_scaling-#1}=\font_count
+ \x_cs\xdef{f-\the\font_count}{\the\mapfont_scaling-#1}
+ \out_line{(MAPFONT~\vpl_int\font_count\space
+ (FONTNAME~#1)~
+ (FONTDSIZE~\vpl_real\a_dimen)~
+ (FONTAT~\vpl_real\mapfont_scaling))}
+ \record_usage{#1}
+ \global\advance\font_count by 1
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\pl_mapfont}
+% As PL files have no \texttt{MAPFONT} properties, the |\pl_mapfont|
+% macro only needs to do one thing: copy the current value of
+% |\mapfont_|\-|scaling| to |\rawfont_|\-|scaling|. This is necessary
+% since if the raw font for which a ligful PL is being written has
+% been scaled, then that scaling factor must be put in the appropriate
+% place in the FD file entry, and the simplest way to determine this
+% scaling factor is to execute the |\mapfonts| of some glyph in the
+% font.
+%
+% Due to the fact that the second ETX file pass (that during which the
+% \texttt{MAPFONT} properties are written) is skipped when a PL file
+% is being written, the |\mapfonts| get executed during the fourth ETX
+% file pass instead of the second. This works fine since the
+% |\mapcommands| that are executed at that time when a VPL file is
+% being written aren't needed for PL files.
+% \changes{1.913}{2000/03/21}{Macro added. (LH)}
+% \begin{macrocode}
+\def\pl_mapfont#1#2{\global\rawfont_scaling=\mapfont_scaling}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\font_count}
+% \begin{macro}{\next_mapfont}
+% \begin{macro}{\prev_mapfont}
+% \begin{macrocode}
+\newcount\font_count
+\newcount\next_mapfont
+\newcount\prev_mapfont
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\make_fontdimens}
+% This macro writes the \texttt{FONTDIMEN} property list. Note that
+% there is a difference between fontdimen 1 and the others, in that
+% fontdimen 1 is always in \texttt{pt}, not in the atsize-relative
+% \texttt{FONTUNITS} unit that the others are. Nonetheless, they can
+% both be treated the same here. This relies on (i) that 1000 denotes
+% the factor 1, and (ii) that 1000 AFM units equals 1 fontunit.
+% \begin{macrocode}
+\def\make_fontdimens#1{
+ \out_line{(FONTDIMEN}
+ \a_count=1
+ \loop\ifnum 256>\a_count
+ \ifisint{fontdimen(\the\a_count)}\then
+ \out_lline{(PARAMETER~\vpl_int\a_count\space
+ R~\make_factor{\int{fontdimen(\the\a_count)}})}
+ \fi
+ \advance \a_count \@ne
+ \repeat
+ \out_lline{)}
+ \out_line{}
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{The ligtable}
+%
+% \begin{macro}{\make_ligtable}
+% \changes{1.927}{2003/12/08}{Changed the surrounding group to
+% \cs{begingroup} type. This helps contain errors that arise when
+% the \cs{setslot}s and \cs{endsetslot}s aren't properly balanced.
+% (LH)}
+% \begin{macrocode}
+\def\make_ligtable#1{
+ \begingroup
+ \out_line{(LIGTABLE}
+%<!boundaryCompability> \let\do_slot=\bgroup
+%<*boundaryCompability>
+ \def\do_slot{\bgroup
+ \ifisint{boundarychar}\then
+ \ifnum \int{boundarychar}=\slot_number
+ \def\vpl_liglabel{\out_liglabel\boundary_liglabel}
+ \fi
+ \fi
+ }
+%</boundaryCompability>
+ \let\end_do_slot=\vpl_kerning
+ \def\do_boundary{\bgroup \let\vpl_liglabel=\boundary_liglabel}
+ \let\endsetleftboundary=\vpl_kerning
+ \let\ligature=\vpl_ligature
+ \let\k=\vpl_kern
+ \let\rbserver_do=\vpl_rbserver_do
+ \let\rboundary_do=\vpl_rboundary_do
+ \pre_third_etx_pass_hook
+ #1
+ \post_third_etx_pass_hook
+ \out_lline{)}
+ \endgroup
+ \out_line{}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_rbserver_do}
+% \begin{macro}{\vpl_rboundary_do}
+% \begin{macro}{\wrn_rboundary_do}
+% |\vpl_rbserver_do| and |\vpl_rboundary_do| are what |\rbserver_do|
+% and |\rboundary_do| respectively are when a ligkern program is being
+% written and no entry has yet been written for the boundarychar
+% slot. |\wrn_rboundary_do| is what one of them will get set to
+% afterwards, so that warnings are written when collisions between
+% using the slot as a right boundary marker and using the slot for
+% the actual glyph occur.
+% \begin{macrocode}
+\def\vpl_rbserver_do#1{
+ \do{#1}
+ \let\rboundary_do=\wrn_rboundary_do
+}
+\def\vpl_rboundary_do#1{
+ \do{#1}
+ \let\rbserver_do=\wrn_rboundary_do
+}
+\def\wrn_rboundary_do#1{
+ \do{#1}
+ \immediate\write16{Boundarychar~slot~usage~collision~in~
+ `\slot_name'~ligkern~program.}
+}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+%
+% \begin{macro}{\vpl_ligature}
+% |\vpl_ligature{|\meta{type}|}{|\meta{glyph}|}{|\meta{glyph}|}|
+% produces a ligtable entry for glyph |\slot_name|.
+%
+% The double spaces in the |\out_lline| statement below might look
+% strange, but |\number| will always gobble the first one.
+% \begin{macrocode}
+\def\vpl_ligature#1#2#3{
+ \get_slot_num{#3}
+ \ifnum -1=\result
+ \immediate\write16{Warning:~\string\ligature\space
+ for~unknown~slot~`#3'.}
+ \else
+ \x_cs\ifx{slots-#2}\x_relax
+ \immediate\write16{Warning:~\string\ligature\space
+ for~unknown~slot~`#2'.}
+ \else
+ \def\do##1{
+ \vpl_liglabel
+ \out_lline{(#1~D~\number`##1~\space\vpl_int\result)~
+ (COMMENT~#2~#3)}
+ }
+ \csname slots-#2\endcsname
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \begin{macro}{\vpl_kerning}
+% |\vpl_kerning| writes out kerning instructions.
+% \begin{macrocode}
+\def\vpl_kerning{
+ \let\do=\vpl_kern_do
+ \csname~r-\slot_name\endcsname
+ \vpl_ligstop
+ \egroup
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_kern}
+% |\vpl_kern|\,|\l-|\meta{name}\,|\|\meta{amount} writes out a |KRN|
+% instruction.
+%
+% \changes{1.900}{1998/10/02}{Macro modified to avoid duplicate kerns.
+% (LH)}
+% |\vpl_kern| has been modified so that at most one
+% \texttt{KRN} instruction is written for each (ordered) pair of
+% characters. The idea is basically to make \package{fontinst} forget,
+% until the end of |\vpl_kerning|, that the glyph for which |\vpl_kern|
+% is being called has been assigned a slot, as this stops any more
+% \texttt{KRN} instructions for that particular glyph from being
+% written. |\vpl_kern| has also been modified so that it will not write
+% out any \texttt{KRN} instructions for kerns whose absolute value is
+% less than or equal to |\minimum_kern|. |\minimum_kern| gets set to
+% the value of the integer \texttt{minimumkern} in |\make_header|. If
+% the user has not set \texttt{minimumkern}, a default value of 0 will
+% be supplied by \package{fontinst}.
+%
+% \changes{1.900}{1998/12/07}{Much of the code from \cs{vpl_kern} has
+% been moved to \cs{vpl_kern_do}. (LH)}
+% \changes{1.913}{2000/02/26}{Using a nested \cs{ifnum} construct to
+% test the condition $\left\protect\vert
+% \protect\mbox{\cs{a_count}}\right\protect\vert \quotechar >
+% \protect\mbox{\cs{minimum_kern}}$. (LH)}
+% \begin{macrocode}
+\def\vpl_kern#1#2{
+ \edef\a_macro{\expandafter\gobble_three\string#1}
+ \a_count=\expandafter\gobble_one\string#2\x_relax
+ \ifnum \ifnum -\a_count>\a_count - \fi\a_count>\minimum_kern
+ \edef\b_macro{~R~\make_factor\a_count}
+ \csname slots-\a_macro\endcsname
+ \fi
+ \x_cs\let{slots-\a_macro}=\x_relax
+}
+% \end{macrocode}
+% Observation (LH 1999/03/16): The above construction has the
+% side-effect that a direct contradiction between a right boundary
+% glyph and a glyph in the |%boundarychar| slot won't be detected if
+% one of the items in contradiction is a kern less than or equal to
+% |\minimum_kern|. Perhaps this should be changed (letting |\do| equal
+% to |\gobble_one| would let the dectection mechanism work, but |\do|
+% would have to be restored afterwards and it is doubtful if it is
+% worth it).
+% \end{macro}
+%
+%
+% \begin{macro}{\vpl_kern_do}
+% |\vpl_kern_do| is what |\do| is defined to be when kerns are written.
+% \begin{macrocode}
+\def\vpl_kern_do#1{
+ \vpl_liglabel
+ \out_lline{
+ (KRN~D~\number`#1~\b_macro)~
+ (COMMENT~\a_macro)
+ }
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\out_liglabel}
+% \begin{macro}{\boundary_liglabel}
+% \begin{macro}{\vpl_liglabel}
+% |\out_liglabel| writes out a |LIGLABEL| instruction for a slot.
+% |\boundary_liglabel| writes out a |LIGLABEL| instruction for the
+% |BOUNDARYCHAR| ligkern program. |\vpl_liglabel| writes out the
+% correct |LIGLABEL| instruction for the current ligkern program, if it
+% is approriate.
+%
+% \begin{macrocode}
+\def\out_liglabel{
+ \out_lline{(LABEL~\vpl_int\slot_number)~(COMMENT~\slot_name)}
+ \let\vpl_liglabel=\x_relax
+ \let\vpl_ligstop=\out_ligstop
+}
+\def\boundary_liglabel{
+ \out_lline{(LABEL~BOUNDARYCHAR)~(COMMENT~\slot_name)}
+ \let\vpl_liglabel=\x_relax
+ \let\vpl_ligstop=\out_ligstop
+}
+\let\vpl_liglabel=\out_liglabel
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\out_ligstop}
+% \begin{macro}{\vpl_ligstop}
+% |\vpl_ligstop| writes out a |LIGSTOP| instruction if appropriate.
+% \begin{macrocode}
+\def\out_ligstop{\out_lline{(STOP)}
+ \let\vpl_liglabel=\out_liglabel
+ \let\vpl_ligstop=\x_relax}
+\let\vpl_ligstop=\x_relax
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \subsection{The characters}
+%
+% \begin{macro}{\make_characters}
+% \begin{macrocode}
+\def\make_characters#1{
+ \bgroup
+ \let\do_slot=\do_character
+ \let\end_do_slot=\end_do_character
+ \let\nextlarger=\vpl_nextlarger
+ \let\varchar=\vpl_varchar
+ \let\endvarchar=\end_vpl_varchar
+ \let\vartop=\vpl_vartop
+ \let\varmid=\vpl_varmid
+ \let\varbot=\vpl_varbot
+ \let\varrep=\vpl_varrep
+ \if_including_map_
+ \let\saved_raw\vpl_raw
+ \let\saved_rule\vpl_rule
+ \let\saved_special\vpl_special
+ \let\saved_warning\vpl_warning
+ \let\saved_movert\vpl_movert
+ \let\saved_moveup\vpl_moveup
+ \let\saved_push\vpl_push
+ \let\saved_pop\vpl_pop
+ \else
+ \def\do_character_map{
+ \ifdim \rawfont_scaling=-\p@
+ \mapfonts\slot_name
+ \else
+ \let\do_character_map=\x_relax
+ \fi
+ }
+ \let\saved_mapfont\pl_mapfont
+ \let\saved_scale\vpl_scale
+ \fi
+ \pre_fourth_etx_pass_hook
+ #1
+ \post_fourth_etx_pass_hook
+ \egroup
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\do_character}
+% \changes{1.913}{2000/03/10}{Negative italic corrections \emph{are}
+% written to the (V)PL being generated. (LH)}
+% \changes{1.927}{2004/07/13}{Added flag for emitting warning message
+% when a glyph is missing. (LH) Requested by Werner Lemberg.}
+% |\do_character| produces a character entry for glyph |\slot_name| in
+% slot |\slot_number|.
+%
+% \begin{macrocode}
+\def\do_character{
+ \if_undefined{g-\slot_name}\then
+ \ifisint{requireglyphs}\then
+ \fontinstwarning{ETX~to~(V)PL}{
+ Undefined~glyph~`\slot_name'~requested\message_break
+ for~slot~\the\slot_number\message_number}
+ \fi
+ \expandafter\gobble_setslot
+ \else
+ \ifx\slot_name\notdef_name\else
+ \out_line{(CHARACTER~\vpl_int\slot_number\space
+ (COMMENT~\slot_name)}
+ \glyph_parameter\glyph_metrics\slot_name
+ \a_dimen=\make_factor\a_count \p@
+ \do_character_sidebearings
+ \out_lline{(CHARWD~\vpl_real\a_dimen)}
+ \ifnum \z@=\b_count \else
+ \out_lline{(CHARHT~R~\make_factor\b_count)}
+ \fi
+ \ifnum \z@=\c_count \else
+ \out_lline{(CHARDP~R~\make_factor\c_count)}
+ \fi
+ \ifnum \z@=\d_count \else
+ \out_lline{(CHARIC~R~\make_factor\d_count)}
+ \fi
+ \do_character_map
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\do_character_sidebearings}
+% \begin{macrocode}
+\def\do_character_sidebearings{
+ \ifisint{\slot_name-spacing}\then
+ \curr_bearings=\make_factor{\int{\slot_name-spacing}}\half_point
+ \else
+ \curr_bearings=\side_bearings
+ \fi
+ \advance\a_dimen by 2\curr_bearings
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\do_character_map}
+% \begin{macrocode}
+\def\do_character_map{
+ \global\prev_mapfont=0
+ \out_lline{(MAP}
+ \ifdim 0pt=\curr_bearings
+ \mapcommands\slot_name
+ \else
+ \out_llline{(MOVERIGHT~\vpl_real\curr_bearings)}
+ \mapcommands\slot_name
+ \out_llline{(MOVERIGHT~\vpl_real\curr_bearings)}
+ \fi
+ \out_llline{)}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\do_character_no_letterspacing}
+% LH 1999/03/27: This is an alternative version of |\do_character|
+% which I think is now antiquated. It used to have an advantage over
+% |\do_character| in that it did not do any letterspacing (in v\,1.5,
+% that was good since |\do_character| used to write code for
+% letterspacing to the VPL regardless of whether is was needed or
+% not), but that advantage is gone since |\do_character_map| is now
+% a bit less stupid than it used to be.
+%
+% For the record, I don't think there ever was a user interface for
+% using this macro instead of |\do_character|, but I suspect there
+% are plenty of people around who have hacked it into being used.
+%
+% With v\,1.913 I commented it out completely, since I didn't feel
+% like updating the calls to |\afm_convert|.
+% \begin{macrocode}
+%<*obsolete>
+% \def\do_character_no_letterspacing{
+% \x_cs\ifx{g-\slot_name}\x_relax
+% \expandafter\gobble_setslot
+% \else
+% \ifx\slot_name\notdef_name\else
+% \out_line{(CHARACTER~\vpl_int\slot_number\space
+% (COMMENT~\slot_name)}
+% \afm_convert\a_dimen=\width\slot_name;
+% \out_lline{(CHARWD~\vpl_real\a_dimen)}
+% \afm_convert\a_dimen=\height\slot_name;
+% \out_lline{(CHARHT~\vpl_real\a_dimen)}
+% \afm_convert\a_dimen=\depth\slot_name;
+% \out_lline{(CHARDP~\vpl_real\a_dimen)}
+% \afm_convert\a_dimen=\italic\slot_name;
+% \ifnum\a_dimen>0 \out_lline{(CHARIC~\vpl_real\a_dimen)} \fi
+% \global\prev_mapfont=0 \out_lline{(MAP}
+% \mapcommands\slot_name
+% \out_llline{)}
+% \fi
+% \fi
+% }
+%</obsolete>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\gobble_setslot}
+% \begin{macrocode}
+\long\def\gobble_setslot#1\endsetslot{\endsetslot}
+% \end{macrocode}
+% \changes{1.901}{1999/03/27}{Made \cs{gobble_setslot} a \cs{long}
+% macro. (LH)}
+% \end{macro}
+%
+% \begin{macro}{\end_do_character}
+% \begin{macrocode}
+\def\end_do_character{
+ \ifisglyph\slot_name\then
+ \out_lline{)}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\notdef_name}
+% \begin{macrocode}
+\def\notdef_name{.notdef}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Slot commands that put things in a character property list}
+%
+% Here follows the active definitions for those slot commands that
+% causes things to be put in |CHARACTER| property lists.
+%
+% \begin{macro}{\vpl_nextlarger}
+% |\vpl_nextlarger|\marg{name} produces a |NEXTLARGER| entry.
+% \begin{macrocode}
+\def\vpl_nextlarger#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_lline{(NEXTLARGER~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\nextlarger\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_varchar}
+% \begin{macro}{\end_vpl_varchar}
+% |\vpl_varchar| \meta{varchar commands} |\end_vpl_varchar| produces
+% a |VARCHAR| entry.
+%
+% \begin{macrocode}
+\def\vpl_varchar{\out_lline{(VARCHAR}}
+% \end{macrocode}
+% \begin{macrocode}
+\def\end_vpl_varchar{\out_llline{)}}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\vpl_vartop}
+% \begin{macrocode}
+\def\vpl_vartop#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(TOP~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\vartop\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_varmid}
+% \begin{macrocode}
+\def\vpl_varmid#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(MID~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varmid\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_varbot}
+% \begin{macrocode}
+\def\vpl_varbot#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(BOT~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varbot\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_varrep}
+% \begin{macrocode}
+\def\vpl_varrep#1{
+ \get_slot_num{#1}
+ \ifnum -1<\result
+ \out_llline{(REP~D~\the\result)~(COMMENT~#1)}
+ \else
+ \immediate\write16{Warning:~\string\varrep\space
+ for~unknown~slot~`#1'}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{Saved map commands}
+%
+% The following commands (and |\vpl_scale|, which is defined above) can
+% be used in the \meta{mapcommands} glyph parameter.
+%
+% \begin{macro}{\vpl_raw}
+% This macro writes the entries in a \texttt{MAP} that are needed for
+% the given raw character. Note that the `at' comment below gives the
+% scaling relative to the atsize of the virtual font, not the physical
+% atsize.
+% \IndexEntry{\LevelSame{PL properties:}^^A
+% \LevelSorted{SELECTFONT}{\texttt{SELECTFONT}}^^A
+% }{usage}{\thepage}
+% \begin{macrocode}
+\def\vpl_raw#1#2#3{
+ \global\next_mapfont=\csname\the\mapfont_scaling-#1\endcsname
+ \ifnum \next_mapfont=\prev_mapfont \else
+ \out_llline{(SELECTFONT~\vpl_int\next_mapfont)~
+ (COMMENT~#1~at~
+ \expandafter\lose_measure \the\mapfont_scaling)}
+ \fi
+ \out_llline{(SETCHAR~D~#2)~(COMMENT~#3)}
+ \global\prev_mapfont=\next_mapfont
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_rule}
+% \begin{macrocode}
+\def\vpl_rule#1#2{
+ \a_dimen=\make_factor{#2}\mapfont_scaling
+ \b_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(SETRULE~\vpl_real\a_dimen\space\vpl_real\b_dimen)}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\vpl_special}
+% \begin{macro}{\vpl_warning}
+% \begin{switch}{warningspecials}
+% \changes{1.913}{2000/02/26}{Switch controlling whether
+% \cs{glyphwarning}s should put \texttt{SPECIALS} in the VPL was
+% added. (LH)}
+% \begin{macrocode}
+\def\vpl_special#1{
+ \out_llline{(SPECIAL~#1)}}
+% \end{macrocode}
+% \begin{macrocode}
+\def\vpl_warning#1{
+ \ifwarningspecials
+ \out_llline{(SPECIAL~Warning:~#1)}
+ \fi
+ \immediate\write16{Warning:~#1.}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\newif\ifwarningspecials
+\warningspecialstrue
+% \end{macrocode}
+% \end{switch}\end{macro}\end{macro}
+%
+% \begin{macro}{\vpl_movert}
+% \begin{macro}{\vpl_moveup}
+% \begin{macrocode}
+\def\vpl_movert#1{
+ \a_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(MOVERIGHT~\vpl_real\a_dimen)}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\vpl_moveup#1{
+ \a_dimen=\make_factor{#1}\mapfont_scaling
+ \out_llline{(MOVEUP~\vpl_real\a_dimen)}
+}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+% \begin{macro}{\vpl_push}
+% \begin{macro}{\vpl_pop}
+% \begin{macrocode}
+\def\vpl_push{\out_llline{(PUSH)}}
+% \end{macrocode}
+% \begin{macrocode}
+\def\vpl_pop{\out_llline{(POP)}}
+% \end{macrocode}
+% \end{macro} \end{macro}
+%
+%
+% \subsection{Tidying up}
+%
+% \begin{macro}{\make_tidy}
+% If a VPL file was written, the tidying up consists of clearing the
+% list of mapfont numbers, since that is stored globally. If a PL
+% file was written, the tidying up consists of writing a
+% \texttt{DESIGNUNITS} property for those fonts which need one.
+% \begin{macrocode}
+\def\make_tidy#1{
+ \tidying_up_hook
+ \if_including_map_
+ \a_count=0
+ \loop\ifnum \a_count<\font_count
+ \edef\a_macro{\csname~f-\the\a_count\endcsname}
+ \global\x_cs\let\a_macro\x_relax
+ \advance\a_count by 1
+ \repeat
+ \global\font_count=0
+ \else
+ \ifdim \rawfont_scaling<\z@
+ \fontinstwarning{ETX~to~(V)PL}{The~font~
+ \out_filename\space doesn't~contain~any~characters}
+ \global\rawfont_scaling=\p@
+ \fi
+ \ifdim \rawfont_scaling=\p@ \else
+ \out_line{(DESIGNUNITS~\vpl_real\rawfont_scaling)}
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \section{Font installation commands and \texttt{.fd} files}
+%
+% \DescribeMacro{\installfonts}
+% \DescribeMacro{\endinstallfonts}
+% The call
+% \begin{quote}
+% |\installfonts| \meta{install commands} |\endinstallfonts|
+% \end{quote}
+% is the top-level interface for installing a number of fonts
+% and creating |.fd| files for them.
+%
+% \DescribeMacro{\installfamily}
+% \DescribeMacro{\installfont}
+% \DescribeMacro{\installrawfont}
+% The \meta{install commands} are:
+% \begin{isyntax}
+% |\installfamily|\marg{encoding}\marg{family}\marg{FD-commmands}\\
+% |\installfont|\marg{font-name}\marg{file-list}\marg{etx}\penalty0
+% \marg{encoding}\marg{family}\marg{series}\marg{shape}\marg{size}\\
+% |\installrawfont|\marg{font-name}\marg{file-list}\marg{etx}^^A
+% \penalty0
+% \marg{encoding}\marg{family}\marg{series}\marg{shape}\marg{size}\\
+% |\installfontas|\marg{font-name}\penalty0\marg{encoding}^^A
+% \marg{family}\marg{series}\marg{shape}\marg{size}
+% \end{isyntax}
+%
+% Each |\installfamily| command causes the generation of an |.fd| file
+% for \meta{encoding} and \meta{family}, which is writen out by the time
+% |\endinstallfonts| is processed.
+%
+% Each |\installfont| generates a |.vpl| font by calling |\etxtovpl|
+% and adds an |.fd| entry.
+% Each |\installrawfont| generates a ligfull |.pl| font by calling
+% |\etxtopl| and adds an |.fd| entry. (Raw |.pl| fonts, containing only
+% the glyph metrics without any ligaturing or kerning information,
+% are also generated by |\mtxtopl| called from |\transformfont|
+% statements.)
+%
+% \changes{1.912}{2000/01/15}{\cs{install}\dots\ commands updated to
+% set \cs{setsomething_global} to \cs{global} around themselves. This
+% reduces problems with assignments ``not working'' due to the
+% unintuitive grouping. (LH) Problem pointed out by Hilmar
+% Schlegel, , and others.}
+%
+% \begin{macro}{\installfonts}
+% Initializes the |\family_toks| token register, which is used to store
+% the information which is written out to |.fd| files at the end of the
+% job.
+%
+% \begin{macrocode}
+\newtoks\family_toks
+\def\installfonts{
+ \bgroup
+ \global\family_toks={}
+ \gdef\prev_file_list{}
+ \global\let\setsomething_global=\global
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\installfamily}
+% |\installfamily|\marg{encoding}\marg{family}\marg{FD-commmands}
+%
+% Adds the command
+% \begin{quote}
+% |\fd_family|\marg{encoding}\marg{family}\marg{FD-commmands}
+% \end{quote}
+% to the token list |\family_toks| and defines a macro
+% |\|\meta{encoding}|-|\meta{family}.^^A
+% \describecsfamily{\meta{encoding}-\meta{family}}
+%
+% \begin{macrocode}
+\def\installfamily#1#2#3{
+ \global\family_toks=
+ \expandafter{\the\family_toks\fd_family{#1}{#2}{#3}}
+ \global\x_cs\let{#1-#2}\empty_command
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\installfont}
+% \begin{macro}{\installrawfont}
+% \changes{1.904}{1999/06/16}{Added \cs{record_usage}. (LH)}
+% \multchanges{\cs{installfont}\cs{installrawfont}}{1.913}{2000/03/21}
+% {Moved some code from \cs{install_font} to these commands. (LH)}
+% |\installfont|\marg{font-name}\marg{file-list}\marg{etx}\\
+% \vadjust{}\qquad \marg{encoding}\marg{family}\marg{series}^^A
+% \marg{shape}\marg{size}\\
+% |\installrawfont|\marg{font-name}\marg{file-list}\marg{etx}\\
+% \vadjust{}\qquad \marg{encoding}\marg{family}\marg{series}^^A
+% \marg{shape}\marg{size}
+%
+% \begin{macrocode}
+\def\installfont#1#2#3#4#5#6#7#8{
+ \global\let\setsomething_global=\x_relax
+ \input_metrics{}{#2}
+ \etxtovpl{#3}{#1}
+ \installfontas{#1}{#4}{#5}{#6}{#7}{#8}
+ \global\let\setsomething_global=\global
+}
+\def\installrawfont#1#2#3#4#5#6#7#8{
+ \global\let\setsomething_global=\x_relax
+ \xdef\out_filename{#1}
+ \input_metrics{\let\storemapdata=\installraw_storemap}{#2}
+ \let\storemapdata=\gobble_three
+ \etxtopl{#3}{#1}
+ \record_usage{#1}
+ \installfontas{
+ \ifdim \rawfont_scaling=\p@ \else
+ [\expandafter\lose_measure\the\rawfont_scaling]~
+ \fi #1
+ }{#4}{#5}{#6}{#7}{#8}
+ \global\let\setsomething_global=\global
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\installraw_storemap}
+% The |\installraw_storemap| macro is a definition of |\storemapdata|
+% that is used when the metrics for a ligful PL file is being inputed.
+% Its job is to write a |\storemapdata| command for this PL to the
+% transforms record file if the PL being written does not have the
+% same name as the MTX that the metrics are taken from (the
+% information is already stored if both files have the same name).
+% |\out_filename| is prematurely set by |\installrawfont| (i.e., long
+% before the PL file is actually opened) so that it can be used in
+% comparing the file names.
+% \changes{1.913}{1999/03/23}{Macro added. (LH)}
+% \begin{macrocode}
+\def\installraw_storemap#1#2#3{
+ \def\a_macro{#1}
+ \ifx \a_macro\out_filename \else
+ \record_transform{\out_filename}{\string\frommtx{#1}}{}\if_false
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\input_metrics}
+% The |\input_metrics| macro takes a comma-separated list of metric
+% files as its second argument and sees to that exactly these metrics
+% are loaded. If the list is identical to that used in the last call
+% to |\input_metrics|, then this is already the case and
+% |\input_metrics| simply refrains from flushing those previous
+% metrics from \TeX's memory. Otherwise it closes a group (flushing
+% the metrics from a previous call), opens a group (so that these
+% metrics can be flushed at the next |\installfont| or
+% |\installrawfont| command, if necessary), and starts inputting the
+% metrics files in question.
+%
+% The first argument consists of code that will be executed after the
+% group has been closed and opened, but before any metrics is inputed.
+% \changes{1.900}{1999/02/13}
+% {Use \cs{process_csep_list} for file-list. (LH)}
+% \changes{1.914}{2000/05/26}{Redefined to suite \cs{file_list_metrics}.
+% In particular, there will now be a comma at the end of
+% \cs{curr_file_list} and \cs{prev_file_list}. (LH)}
+% \begin{macrocode}
+\def\input_metrics#1#2{
+ \let\metrics=\file_list_metrics
+ \xdef\curr_file_list{#2,}
+ \let\metrics=\x_relax
+ \ifx\prev_file_list\curr_file_list\else
+ \egroup\bgroup
+ #1
+ \expandafter\process_csep_list \expandafter\input_mtx_file
+ \curr_file_list\process_csep_list,
+ \global\let\prev_file_list=\curr_file_list
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\file_list_metrics}
+% The |\file_list_metrics| macro is a definition of |\metrics| that
+% is used in the \meta{file-list} argument of |\install|\-|font| and
+% |\install|\-|raw|\-|font| when that is |\xdef|ed by |\input_metrics|.
+% This special definition prevents the succeeding \meta{metric
+% commands} from getting expanded.
+% \changes{1.914}{2000/05/26}{Macro added. (LH)}
+% \begin{macrocode}
+\def\file_list_metrics#1,{
+ \iffalse{\fi}
+ \a_toks=\expandafter{\curr_file_list\x_relax#1,}
+ \xdef\curr_file_list{\the\a_toks \iffalse}\fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\installfontas}
+% The |\installfontas| command has the syntax
+% \begin{isyntax}
+% |\installfontas|\marg{font-info}\marg{encoding}\marg{family}^^A
+% \penalty0\marg{series}\penalty0\marg{shape}\penalty0\marg{size}
+% \end{isyntax}
+% The precise definition of a \meta{font-info} can be found in
+% \cite[Sec.~4]{fntguide}, here it suffices to say that a font name
+% (name of (V)PL file) is a valid \meta{font-info}. The |\installfontas|
+% command adds an entry for the \meta{font-info} font to a font
+% definition file, giving it the NFSS attributes \meta{encoding}^^A
+% \texttt{/}\nolinebreak[1]\meta{family}\texttt{/}\nolinebreak[1]^^A
+% \meta{series}\texttt{/}\nolinebreak[1]\meta{shape}\texttt{/}^^A
+% \nolinebreak[1]\meta{size}. The substitution mechanism will act on
+% \meta{series} and \meta{shape}, and it is therefore possible that
+% \meta{font-info} will appear in more than one |\Declare|\-|Font|\-^^A
+% |Shape| command. \meta{size} can be either some \meta{size-infos},
+% as defined in \cite[Sec.~4]{fntguide}, or a \package{fontinst}
+% shorthand for a such, declared using |\declaresize|.
+% \changes{1.912}{2000/01/16}{Command added. (LH)}
+% \changes{1.913}{2000/03/02}{Specification changed to allow
+% arbitrary \meta{font-info}s as first argument. (LH)}
+% \changes{1.921}{2002/03/27}{Automatically doing an
+% \cs{installfamily} if that has not been done. (LH) Suggested
+% by Rowland McDonnell.}
+% \begin{macrocode}
+\def\installfontas#1#2#3#4#5#6{
+ \if_undefined{#2-#3-#4-#5}\then
+ \let\do_shape=\x_relax
+ \if_undefined{#2-#3}\then
+ \x_cs\let{#2-#3}\empty_command
+ \autoinstallfamily{#2}{#3}
+ \fi
+ \x_cs\xdef{#2-#3}{
+ \csname#2-#3\endcsname
+ \do_shape{#2}{#3}{#4}{#5}
+ }
+ \fi
+ \let\do_size=\x_relax
+ \x_cs\xdef{#2-#3-#4-#5}{
+ \if_defined{#2-#3-#4-#5}\then
+ \csname#2-#3-#4-#5\endcsname
+ \fi
+ \do_size{#6}{#1}
+ }
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\autoinstallfamily}
+% This command is called by |\installfontas| when it is asked to
+% install a font for which no |\installfamily| has been given. The
+% syntax is
+% \begin{quote}
+% |\autoinstallfamily|\marg{encoding}\marg{family}
+% \end{quote}
+% It defaults to calling |\installfamily| in the obvious way, but
+% it can be redefined if the user wants something different.
+% \changes{1.924}{2003/02/08}{Macro added. (LH)}
+% \begin{macrocode}
+\def\autoinstallfamily#1#2{\installfamily{#1}{#2}{}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\endinstallfonts}
+% Finish the installation by processing the |\family_toks|
+% token register, which contains the accumulated information
+% to be written out to |.fd| files.
+%
+% \begin{macrocode}
+\def\endinstallfonts{
+ \global\let\setsomething_global=\x_relax
+ \let\do_shape=\fd_shape
+ \let\do_size=\fd_size
+ \the\family_toks
+ \global\family_toks{}
+ \egroup
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% The |\installfont| command has traditionally allowed that names of
+% base fonts (MTX files) are suffixed by a
+% \verb*" scaled "\meta{factor} that would cause the \texttt{rawscale}
+% integer to be set and thereby scale everything that was in that base
+% font by the said \meta{factor}. There is now a more general approach
+% to this. If the control sequence
+% \describecsfamily{IFKW-\meta{keyword}}|IFKW-|\meta{keyword} is
+% defined then \meta{keyword} may be used as \texttt{scaled} is above;
+% this control sequence should grab all the ``arguments'' of the
+% keyword, process them as necessary, and end with the |\get_keyword|
+% macro so that another keyword may be processed. As a rule, the
+% arguments and keywords are delimited from each other by single spaces.
+% A macro grabbing an argument grabs also the space after it. The
+% \texttt{IFKW} is for \texttt{I}nstall\texttt{F}ont
+% \texttt{K}ey\texttt{W}ord.
+%
+% \changes{1.923}{2002/10/09}{Added support for keywords other than
+% \texttt{scaled} in the second argument of \cs{installfont} and
+% such. (LH)}
+%
+% \begin{macro}{\input_mtx_file}
+% The |\input_mtx_macro| takes one undelimited argument. It
+% interprets this argument as if it was one item in the \meta{file-list}
+% argument of |\install|\-|font| or |\install|\-|rawfont|, and does
+% the corresponding processing. The argument should be one of the
+% following three things:
+% \begin{quote}
+% \meta{font}\meta{optional modifiers}\\
+% |\metrics| \meta{metric commands}\\
+% \meta{nothing}
+% \end{quote}
+% If, in the first case, an MTX file for \meta{font} does not
+% exist then it is generated on the fly from a corresponding |.pl|,
+% |.afm|, or |.vpl| file in the call to |\fromany|. In the second
+% case, the \meta{metric commands} simply get executed. In the third
+% case, nothing happens.
+%
+% The \meta{optional modifiers} is either empty or has the form
+% \meta{modifier clause}\meta{optional modifiers}. A \meta{modifier
+% clause} generally has the form
+% \begin{quote}
+% \verb*" "\meta{keyword}\verb*" "\meta{argument(s)}
+% \end{quote}
+% e.g.,
+% \begin{quote}
+% \verb*| scaled |\meta{rawscale factor}
+% \end{quote}
+%
+% \changes{1.904}{1999/06/16}{Now using \cs{fromany} to make an MTX
+% file when necessary. Furthermore testing for empty argument using
+% \cs{ifx} rather than \cs{if}. (LH)}
+% \changes{1.912}{2000/01/15}{Added error message. (LH) Suggested by
+% Alexei Kostin.}
+% \changes{1.914}{2000/05/26}{Can now accept arbitrary metric
+% commands in argument. (LH)}
+% \begin{macrocode}
+\def\input_mtx_file#1{
+ \reset_modifiers_hook
+ \ifx\x_relax#1\x_relax
+% \end{macrocode}
+% This tests for an empty argument, but it also lets explicit metric
+% commands be executed.
+% \begin{macrocode}
+ \else
+ \identity_one{\get_file_name #1~}~\par
+% \end{macrocode}
+% The two spaces have the effect of putting an empty keyword modifier
+% last in the \meta{optional modifiers}. If everything is all right
+% then this will gobble the |\par|. However, if the user forgot some
+% argument of the last keyword then there will be an error message
+% when |\get_keyword| will try to grab the next keyword.
+%
+% If an encoding has been specified then the source file must be a PL
+% or VPL file (since these are the only ones for which it makes sense
+% to specify an encoding), otherwise we rely on |\fromany| to find a
+% font metrics file.
+% \changes{1.926}{2003/07/10}{Only looking for PL and VPL files when
+% an encoding is specified. (LH)}
+% \changes{1.929}{2005/01/13}{Missing space in message inserted. (LH)
+% Pointed out by Peter Dyballa.}
+% \begin{macrocode}
+ \ifx \pl_encoding\empty_command
+ \fromany\file_name
+ \else
+ \metrics_given_encoding{\file_name}{\pl_encoding}
+ \fi
+ \ifisstr{afm-name}\then
+ \inputmtx{\str{afm-name}}
+ \else
+ \fontinsterror{\string\install...}{
+ Font/MTX~file~\file_name\space not~found
+ }{
+ You~can~insert~an~\string\inputmtx\space command~here
+ \messagebreak to~input~some~other~MTX~file~instead.
+ \ifisint{rawscale}\then \messagebreak
+ The~requested~raw~scaling~will~then~be~applied~on~that.
+ \fi
+ }
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\metrics_given_encoding}
+% This macro is a cousin of |\fromany|, for the case that metrics are
+% taken from a (V)PL file that furthermore is assigned nonstandard
+% metrics. The syntax is
+% \begin{quote}
+% |\metrics_given_encoding|\marg{font}\marg{etx}
+% \end{quote}
+% and the generated MTX file is named
+% \meta{font}\texttt{-}\meta{etx}\texttt{.mtx} to avoid that it is
+% picked up by |\fromany| by mistake.
+% \changes{1.929}{2005/01/12}{The \texttt{afm-name} string usually has
+% a value at this point, so it is necessary to reset it. (LH,
+% sighing because he knows this isn't the first time this problem
+% occurred) First to be hit by this bug was Michael Zedler.}
+% \begin{macrocode}
+\def\metrics_given_encoding#1#2{
+ \x_cs\edef{s-afm-name}{#1-#2}
+ \if_file_exists{#1.pl}\then
+ \generalpltomtx{#1}{#1-#2}{pl}{#2}
+ \else
+ \if_file_exists{#1.vpl}\then
+ \generalpltomtx{#1}{#1-#2}{vpl}{#2}
+ \else
+ \unsetstr{afm-name}
+ \fi\fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \definechange{option-keyword}{1.924}{2002/02/16}{Added mechanism
+% for passing options to MTX and ETX files. (LH)}
+%
+% \begin{macro}{\reset_modifiers_hook}
+% The |\reset_modifiers_hook| macro contains code that initialises
+% all parameters that are modified by some \meta{modifier clause} to
+% their default values. If you need to add some initialisations due
+% to that you define additional keywords then you should append
+% these initialisations to this macro.
+% \usechange{option-keyword}
+% \begin{macrocode}
+\def\reset_modifiers_hook{
+ \unsetint{rawscale}
+ \let\glyph_name_modifier\identity_one
+ \let\pl_encoding\empty_command
+ \let\list_of_options\empty_command
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\get_file_name}
+% The macro |\get_file_name| grabs the base font (or other MTX file)
+% name and starts the processing of the \meta{optional modifiers}.
+% \begin{macrocode}
+\def\get_file_name #1~{
+ \edef\file_name{#1}
+ \get_keyword
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\get_keyword}
+% \begin{macro}{\gobble_keywords}
+% The |\get_keyword| macro expects to be expanded in the context
+% \begin{quote}
+% |\get_keyword|\,\meta{keyword}\verb*" "
+% \end{quote}
+% where the \meta{keyword} is a possible keyword. If
+% |\IFKW-|\meta{keyword} is defined then the above expands to it,
+% otherwise the above expands to an error message followed by a
+% |\gobble_keywords|, which will gobble the rest of the list of
+% keywords and arguments.
+% \begin{macrocode}
+\def\get_keyword #1~{
+ \if_defined{IFKW-#1}\then
+ \csname IFKW-#1 \expandafter\endcsname
+ \else
+ \fontinsterror{\string\install...}{
+ `#1'~is~not~a~defined~keyword
+ }{
+ \error_help_a\messagebreak
+ Extra~tokens~will~be~flushed.
+ }
+ \expandafter\gobble_keywords
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\gobble_keywords#1\par{}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\IFKW-}
+% The empty keyword is used to flag the end of the \meta{optional
+% modifiers}.
+% \begin{macrocode}
+\x_cs\let{IFKW-}=\gobble_keywords
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\IFKW-scaled}
+% This macro handles grabbing the argument of the traditional
+% \texttt{scaled} keyword.
+% \changes{1.900}{1999/02/05}{Changed \cs{setint} to \cs{resetint}.
+% (LH)}
+% \begin{macrocode}
+\x_cs\def{IFKW-scaled}#1~{
+ \ifnum #1=\one_thousand
+ \unsetint{rawscale}
+ \else
+ \x_resetint{rawscale}{#1}
+ \fi
+ \get_keyword
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\IFKW-suffix}
+% This macro handles grabbing the argument of the \texttt{suffix}
+% keyword. The effect of `\texttt{suffix} \meta{suffix}' is that
+% \meta{suffix} will be appended to the name of every glyph defined
+% by the next MTX file to be read in.
+% \begin{macrocode}
+\x_cs\def{IFKW-suffix}#1~{
+ \def\glyph_name_modifier##1{##1#1}
+ \get_keyword
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\IFKW-encoding}
+% \begin{macro}{\pl_encoding}
+% This macro handles grabbing the argument of the \texttt{encoding}
+% keyword. The effect of `\texttt{encoding} \meta{etx}' is that
+% \meta{etx} will be used as encoding when converting a PL or VPL
+% file to MTX. |\pl_encoding| is used for storing the argument
+% value. Its expansion is normally empty, which means |\fromafm|
+% handles locating the metrics file and the encoding used for a PL
+% or VPL is determined by its codingscheme.
+% \begin{macrocode}
+\x_cs\def{IFKW-encoding}#1~{
+ \def\pl_encoding{#1}
+ \get_keyword
+}
+\let\pl_encoding=\empty_command
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\IFKW-option}
+% This macro handles grabbing the argument of the \texttt{option}
+% keyword. One can test using |\ifoption| whether a particular option
+% was specified.
+% \usechange{option-keyword}
+% \begin{macrocode}
+\x_cs\def{IFKW-option}#1~{
+ \add_to\list_of_options{\do{#1}}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\ifoption}
+% \usechange{option-keyword}
+% \begin{macro}{\list_of_options}
+% \usechange{option-keyword}
+% The |\ifoption| command is used to test whether a particular option
+% is present on the list of options. The syntax is
+% \begin{quote}
+% |\ifoption|\marg{string}|\then|
+% \end{quote}
+% and it is tested whether the \meta{string} was one of the options
+% given. Like strings in general, the \meta{string} is expanded
+% before it is compared to the options listed in |\list_of_options|.
+%
+% The |\list_of_options| is a sequence of items on the form
+% \begin{quote}
+% |\do|\marg{option}
+% \end{quote}
+% where each \meta{option} is an already expanded string of
+% characters.
+% \begin{macrocode}
+\def\ifoption#1\then{
+ \_a_false
+ \edef\a_macro{#1}
+ \def\do##1{
+ \if_a_ \else
+ \def\b_macro{##1}
+ \ifx \a_macro\b_macro \_a_true \fi
+ \fi
+ }
+ \list_of_options
+ \if_a_
+}
+%</pkg>
+%<*doc>
+\def\ifoption#1\then{%
+ \generic@if{option \TypesetStringExpression{#1}}%
+}
+%</doc>
+%<*pkg>
+\let\list_of_options\empty_command
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \subsection{Writing font definition files}
+%
+% \begin{macro}{\fd_family}
+% |\fd_family{ENCODING}{FAMILY}{FD-COMMANDS}|
+%
+% Writes out an |.fd| file for the specified |ENCODING| and |FAMILY|
+% processing the accumulated information and default substitutions.
+%
+% \begin{macrocode}
+\def\fd_family#1#2#3{
+ \a_toks{#3}
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1#2.fd}}}
+ \lowercase_file
+ \open_out{\lowercase_file}
+ \out_line{\percent_char~Filename:~\lowercase_file}
+ \out_line{\percent_char~Created~by:~tex~\jobname}
+ \out_line{\percent_char~Created~using~fontinst~v\fontinstversion}
+ \out_line{}
+ \out_line{\percent_char~THIS~FILE~SHOULD~BE~PUT~IN~A~TEX~INPUTS~
+ DIRECTORY}
+ \out_line{}
+ \out_line{\string\ProvidesFile{\lowercase_file}}
+ \out_lline{[
+ \the\year/
+ \ifnum10>\month0\fi\the\month/
+ \ifnum10>\day0\fi\the\day\space
+ Fontinst~v\fontinstversion\space
+ font~definitions~for~#1/#2.
+ ]}
+ \out_line{}
+ \out_line{\string\DeclareFontFamily{#1}{#2}{\the\a_toks}}
+ {
+ \csname #1-#2\endcsname
+ \out_line{}
+ \let\do_shape=\substitute_shape
+ \csname #1-#2\endcsname
+ \let\do_shape=\remove_shape
+ \csname #1-#2\endcsname
+ }
+ \x_cs\g_let{#1-#2}\x_relax
+ \out_line{}
+ \out_line{\string\endinput}
+ \close_out{Font~definitions}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fd_shape}
+% |\fd_shape{ENCODING}{FAMILY}{SERIES}{SHAPE}|
+%
+% \begin{macrocode}
+\def\fd_shape#1#2#3#4{
+ \out_line{}
+ \out_line{\string\DeclareFontShape{#1}{#2}{#3}{#4}\left_brace_char}
+ \csname #1-#2-#3-#4\endcsname
+ \x_cs\g_let{#1-#2-#3-#4}\empty_command
+ \out_line{\right_brace_char{}}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fd_size}
+% |\fd_size{SIZE}{FONT-NAME}|
+%
+% \begin{macrocode}
+\def\fd_size#1#2{
+ \x_cs\ifx{siz-#1}\x_relax
+ \out_lline{#1~#2}
+ \else
+ \out_lline{\csname siz-#1\endcsname\space #2}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\remove_shape}
+% |\remove_shape{ENCODING}{FAMILY}{SERIES}{SHAPE}|
+%
+% \begin{macrocode}
+\def\remove_shape#1#2#3#4{
+ \x_cs\g_let{#1-#2-#3-#4}\x_relax
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\substitute_shape}
+% |\substitute_shape{ENCODING}{FAMILY}{SERIES}{SHAPE}|
+%
+% \begin{macrocode}
+\def\substitute_shape#1#2#3#4{
+ \edef\orig_shape{#4}
+ \substitute_series{#1}{#2}{#3}{\orig_shape}
+ \x_cs\ifx{sub-\orig_shape}\x_relax\else
+ \edef\subst_shape{\csname sub-\orig_shape\endcsname}
+ \x_cs\ifx{#1-#2-#3-\subst_shape}\x_relax
+ \out_line{
+ \string\DeclareFontShape{#1}{#2}{#3}{\subst_shape}{
+ <->\csname typ-\orig_shape\endcsname\space
+ *~#2/#3/\orig_shape
+ }{}
+ }
+ \x_cs\let{#1-#2-#3-\subst_shape}\empty_command
+ \substitute_shape{#1}{#2}{#3}{\subst_shape}
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\substitute_series}
+% |\substitute_series{ENCODING}{FAMILY}{SERIES}{SHAPE}|
+%
+% \begin{macrocode}
+\def\substitute_series#1#2#3#4{
+ \edef\orig_series{#3}
+ \x_cs\ifx{sub-\orig_series}\x_relax\else
+ \edef\subst_series{\csname sub-\orig_series\endcsname}
+ \x_cs\ifx{#1-#2-\subst_series-#4}\x_relax
+ \out_line{
+ \string\DeclareFontShape{#1}{#2}{\subst_series}{#4}{
+ <->\csname typ-\orig_series\endcsname\space
+ *~#2/\orig_series/#4
+ }{}
+ }
+ \x_cs\let{#1-#2-\subst_series-#4}\empty_command
+ \substitute_series{#1}{#2}{\subst_series}{#4}
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\substitutesilent}
+% \begin{macro}{\substitutenoisy}
+% These commands specify a default substitution for series or shape
+% \meta{to}, which points to the series or shape \meta{from}.
+% \begin{quote}
+% |\substitutesilent|\marg{to}\marg{from}\\
+% |\substitutenoisy|\marg{to}\marg{from}
+% \end{quote}
+% There can be at most one \meta{to} for every \meta{from}; later
+% substitutions will override previous ones. If \meta{to} and
+% \meta{from} are equal, then any existing substitution from
+% \meta{from} is disabled.
+%
+% The way this is implemented is that if a font has been installed
+% with shape or series \meta{from}, but no entry for \meta{to} has
+% been written, then write an entry also for \meta{to} consisting of
+% a substitution by \meta{from}. (After doing that, an entry has been
+% written also for \meta{to}, so the process may repeat itself with
+% the old \meta{to} as a new \meta{from}.)
+%
+% \begin{macro}{\substitute_generic}
+% This is the common part of |\substitutesilent| and
+% |\substitutenoisy|. The syntax is
+% \begin{quote}
+% |\substitute_generic|\marg{type}\marg{to}\marg{from}
+% \end{quote}
+% where \meta{type} is |ssub| or |sub| respectively.
+% \changes{1.931}{2005/05/12}{Macro added, to support explicit
+% disabling of substitutions. (LH)}
+% \begin{macrocode}
+\def\substitute_generic#1#2#3{
+ \edef\a_macro{#2}
+ \edef\b_macro{#3}
+ \ifx \a_macro \b_macro
+ \x_cs\let{sub-#3}\undefined_command
+ \else
+ \x_cs\let{sub-#3}\a_macro
+ \x_cs\def{typ-#3}{#1}
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+% \begin{macrocode}
+\def\substitutesilent{\substitute_generic{ssub}}
+\def\substitutenoisy{\substitute_generic{sub}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macrocode}
+\substitutesilent{bx}{b}
+\substitutesilent{b}{bx}
+\substitutesilent{b}{sb}
+\substitutesilent{b}{db}
+\substitutesilent{m}{mb}
+\substitutesilent{m}{l}
+% \end{macrocode}
+% \begin{macrocode}
+\substitutenoisy{ui}{it}
+% \end{macrocode}
+%
+% I don't think we want these since in OT1 encoding it will
+% cause the old |<sterling>| vs |<dollar>| problem. (ASAJ)
+% --- Oh yes we do. (SPQR)
+%
+% \begin{macrocode}
+\substitutesilent{sl}{it}
+\substitutesilent{it}{sl}
+% \end{macrocode}
+%
+%
+% \subsection{New font substitution mechanism}
+%
+% \textbf{Note:} This subsection contains (part of) a new implementation
+% of the font substitution mechanism, but it is uncertain whether it
+% will ever be completed.
+% \begin{macrocode}
+%<*underconstruction>
+% \end{macrocode}
+%
+%
+% \subsubsection{The substitution graph}
+%
+% Which substitutions are performed are determined by the substitution
+% graph. The vertices of this graph are all combinations of a series and
+% a shape. The arcs (directed edges) of this graph are the substitutions
+% that can be made. Each arc has a wheight---a real number in the range
+% $[0,1]$---that describes how much of the quality of the font that is
+% preserved with this substitution.
+%
+% As an example, consider the case that there is an arc from \texttt{m/it}
+% to \texttt{m/sl} and that the wheight of this arc is $0.5$. This means
+% that it is OK to substitute the medium italic (\texttt{m/it}) font as a
+% medium slanted (\texttt{m/sl}) font if there is no medium slanted font,
+% but that the medium italic font is only considered as being half
+% ($0.5$) as good a medium slanted font as it is a medium italic font.
+%
+% The main problem the substitution mechanism has to solve in this
+% context is to find the best possible way of substituting a font, given
+% the real fonts which has actually been installed (using |\installfont|
+% or |\installrawfont|). The solution to this problem is computed by a
+% brute force approach---all possible substitution paths are followed
+% and during this process the best solution so far, for each vertex
+% separately, is stored.
+% \medskip
+%
+% In practice, the substitution graph $G$ is constructed as the cartesian
+% product of one graph $G\sb{1}$ of series substitutions and one graph
+% $G\sb{2}$ of shape substitutions, with the option of adding some
+% additional arcs to this product. The reason for this is that one
+% usually wants to make the same shape substitutions in all series and
+% vice versa, so by only storing the $G\sb{1}$ and $G\sb{2}$ graphs, plus
+% perhaps a handfull of extra edges, one gets away with using fewer
+% tokens.
+% The wheights of the arcs are stored as integers in the range 0--1000,
+% where 0 means the real number $0$ and 1000 means the real number $1$.
+% \medskip
+%
+% \DescribeMacro\do_arc
+% The |\do_arc| macro is probably the most common in the data
+% structures that constitute the substitution graph. Its syntax is
+% always
+% \begin{quote}
+% |\do_arc|\marg{series}\marg{shape}\marg{wheight}
+% \end{quote}
+% but it is meant to be redefined whenever one needs to do something
+% ``for all arcs'' (usually all arcs at a given vertex or so). There are
+% three families of macros which consist of |\do_arc| lists, namely
+% \begin{quote}
+% |\sub1-|\meta{series}\\
+% |\sub2-|\meta{shape}\\
+% |\sub-|\meta{series}|-|\meta{shape}
+% \end{quote}
+% These macros store arcs going out from a vertex. The
+% |\sub1-|\meta{series} macross store the arcs incident with the vertex
+% \meta{series} in the series substitution graph $G\sb{1}$. The
+% |\sub2-|\meta{shape} macros store the arcs incident with the vertex
+% \meta{shape} in the shape substitution graph $G\sb{2}$. The
+% |\sub-|\meta{series}|-|\meta{shape} macros store the arcs of $G$ that
+% are incident with the vertex \meta{series}|/|\meta{shape} but do
+% \emph{not} appear in the cartesian product $G\sb{1} \times G\sb{2}$.
+%
+% The \meta{series} and \meta{shape} arguments of |\do_arc| tells which
+% vertex the arc goes to, hence for example |\do_arc{b}{it}{600}| in the
+% macro |\sub-db-sl| corresponds to an arc going from the |db/sl| vertex
+% to the |b/it| vertex and having a wheight of $0.6$.
+%
+% \DescribeMacro\curr_series
+% \DescribeMacro\curr_shape
+% The above omits one important detail, namely that the \meta{shape}
+% argument for a |\do_arc| in a |\sub1-|\textellipsis\ must be able to
+% be \emph{all} shapes since the shape is not determined for arcs in
+% $G\sb{1}$ and the series is likewise for arcs in $G\sb{2}$. To make things
+% work anyway, there are two macros |\curr_series| and |\curr_shape|
+% which contain this missing information. Furthermore, a |\do_arc| item
+% for an arc in $G\sb{1}$ will always have the structure
+% \begin{quote}
+% |\do_arc|\marg{series}|\curr_shape|\marg{wheight}
+% \end{quote}
+% and a |\do_arc| item for an arc in $G\sb{2}$ will have the structure
+% \begin{quote}
+% |\do_arc\curr_series|\marg{shape}\marg{wheight}
+% \end{quote}
+%
+%
+% \begin{macro}{\substituteshape}
+% \begin{macro}{\substituteseries}
+% \begin{macro}{\substituteseriesshape}
+% |\substituteshape|\marg{to}\marg{from}\marg{wheight}\\
+% |\substituteseries|\marg{to}\marg{from}\marg{wheight}\\
+% |\substituteseriesshape|\marg{toseries}\marg{toshape}^^A
+% \marg{fromseries}\marg{fromshape}\marg{wheight}
+%
+% \begin{macrocode}
+\def\substituteshape#1#2#3{
+ \round_wheight{#3}
+ \edef\temp_command{#1}
+ \edef\sub_suffix{#2}
+ \ifx \temp_command\sub_suffix \else
+ \def\sub_suffix##1##2{2-##2}
+ \def\do_arc##1##2##3{
+ \x_cs\ifx{sub2-##2}R \else
+ \noexpand\do_arc\noexpand\curr_series{##2}{##3}
+ \fi
+ }
+ \update_do_arc_list{}{#2}{}{#1}{\noexpand\curr_series{#1}}
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\substituteseries#1#2#3{
+ \round_wheight{#3}
+ \edef\temp_command{#1}
+ \edef\sub_suffix{#2}
+ \ifx \temp_command\sub_suffix \else
+ \def\sub_suffix##1##2{1-##1}
+ \def\do_arc##1##2##3{
+ \x_cs\ifx{sub1-##1}R \else
+ \noexpand\do_arc{##1}\noexpand\curr_shape{##3}
+ \fi
+ }
+ \update_do_arc_list{#2}{}{#1}{}{{#1}\noexpand\curr_shape}
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\substituteseriesshape#1#2#3#4#5{
+ \round_wheight{#5}
+ \edef\temp_command{#1-#2}
+ \edef\sub_suffix{#3-#4}
+ \ifx \temp_command\sub_suffix \else
+ \def\sub_suffix##1##2{-##1-##2}
+ \def\do_arc##1##2##3{
+ \x_cs\ifx{sub-##1-##2}R \else
+ \noexpand\do_arc{##1}{##2}{##3}
+ \fi
+ }
+ \update_do_arc_list{#3}{#4}{#1}{#2}{{#1}{#2}}
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\round_wheight#1{
+ \eval_expr{#1}
+ \ifnum \one_thousand<\result
+ \result=\one_thousand
+ \else \ifnum 0>\result
+ \result=\z@
+ \fi\fi
+}
+% \end{macrocode}
+%
+% |\update_do_arc_list|\marg{update-series}\marg{update-shape}^^A
+% \allowbreak\marg{tag-series}\allowbreak\marg{tag-shape}^^A
+% \allowbreak\marg{inserted series+shape}
+%
+% \begin{macrocode}
+\def\update_do_arc_list#1#2#3#4#5{
+ \bgroup
+ \edef\temp_command{sub\sub_suffix{#1}{#2}}
+ \x_cs\let{sub\sub_suffix{#3}{#4}}=R
+ \x_cs\xdef\temp_command{
+ \x_cs\ifx\temp_command\relax \else
+ \csname\temp_command\endcsname
+ \fi
+ \ifnum 0<\result
+ \noexpand\do_arc #5{\the\result}
+ \fi
+ }
+ \egroup
+}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+%
+%
+% \begin{macro}{\substitutesilent}
+% \begin{macro}{\substitutenoisy}
+% |\substitutesilent{TO}{FROM}|\\
+% |\substitutenoisy{TO}{FROM}|
+%
+% Specifies a default substitution for family or shape |TO|,
+% which is substituted by family or shape |FROM|.
+%
+% \begin{macrocode}
+\def\substitutesilent#1#2{
+ \substituteseries{#1}{#2}{900}
+ \substituteshape{#1}{#2}{900}
+}
+\def\substitutenoisy#1#2{
+ \substituteseries{#1}{#2}{500}
+ \substituteshape{#1}{#2}{500}
+}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macrocode}
+\a_count=900 % Silent substitution wheight
+\b_count=500 % Noisy substitution wheight
+\substituteseries{bx}{b}{\a_count}
+\substituteseries{b}{bx}{\a_count}
+\substituteseries{b}{sb}{\a_count}
+\substituteseries{b}{db}{\a_count}
+\substituteseries{m}{mb}{\a_count}
+\substituteseries{m}{l}{\a_count}
+% \end{macrocode}
+% \begin{macrocode}
+\substituteshape{ui}{it}{\b_count}
+% \end{macrocode}
+%
+% I don't think we want these since in OT1 encoding it will
+% cause the old |<sterling>| vs |<dollar>| problem. (ASAJ)
+% --- Oh yes we do. (SPQR)
+%
+% \begin{macrocode}
+\substituteshape{sl}{it}{\a_count}
+\substituteshape{it}{sl}{\a_count}
+% \end{macrocode}
+%
+%
+% \subsubsection{Listing reachable vertices}
+%
+% While determining the optimal substitutions, there is a need to store
+% some---more or less temporary---information for each vertex. Such
+% information will be called a \emph{property} of the vertex and it is
+% stored in the |\v-|\meta{series}|-|\meta{shape} family of macros.
+%
+% The following are the basic properties:
+% \begin{list}{}{^^A
+% ^^A How does one make the label go on a line of its own??
+% }
+% \item[\cs{real_font}\marg{quality}]
+% This expresses that this vertex corresponds to a font that has
+% actually been installed with a nominal quality of \meta{quality}.
+% \item[\cs{subs_font}\marg{series}\marg{shape}\marg{quality}]
+% This expresses that this vertex corresponds to a font for which
+% the font \meta{series}|/|\meta{shape} has been substituted.
+% \meta{quality} is the quality this substitution is considered to
+% have.
+% \item
+% \end{list}
+%
+%
+% There will also be some lists of vertices. These will consist of simple
+% |\do|\marg{series}\marg{shape} triples.
+%
+% \begin{macrocode}
+\def\list_subs_vertices{
+ \def\subs_vertex_list{}
+ \let\do_arc=\subs_do_arc
+ \let\do=\never_do
+ \def\real_font##1{\c_count=\@MM}
+ \def\subs_font##1##2##3{\c_count=##3\relax}
+ \real_vertex_list
+}
+\def\subs_do_arc#1#2#3{
+ \b_count=#3
+ \multiply \b_count \a_count
+ \divide \b_count \one_thousand
+ \c_count=-\max_mathchardef
+ \csname v-#1-#2\endcsname
+ \ifnum \c_count<\b_count
+ \ifnum \c_count=-\max_mathchardef
+ \edef\subs_vertex_list{\subs_vertex_list\do{#1}{#2}}
+ \fi
+ \x_cs\edef{v-#1-#2}{\noexpand\subs_font{\subs_series}
+ {\subs_shape}{\the\b_count}}
+ \toks_a=\expandafter{\the\a_toks \do_subs{#1}{#2}}
+ \fi
+}
+\def\do_subs#1#2{
+ \edef\curr_series{#1}
+ \edef\curr_shape{#2}
+ \csname v-#1-#2\endcsname
+ \a_count=\c_count
+ \a_toks={}
+ \csname sub-#1-#2\endcsname
+ \csname sub1-#1\endcsname
+ \csname sub2-#2\endcsname
+ \the\a_toks
+}
+\def\start_subs_at#1#2{
+ \edef\subs_series{#1} \let\curr_series=\subs_series
+ \edef\subs_shape{#2} \let\curr_shape=\subs_shape
+ \a_count=\x_cs\second_of_two{v-#1-#2}
+ \a_toks={}
+ \csname sub-#1-#2\endcsname
+ \csname sub1-#1\endcsname
+ \csname sub2-#2\endcsname
+ \the\a_toks
+}
+% \end{macrocode}
+%
+%
+% \begin{macrocode}
+%</underconstruction>
+% \end{macrocode}
+%
+%
+% \subsection{Default encodings and font sizes}
+%
+% \begin{macro}{\declareencoding}
+% |\declareencoding{CODINGSCHEME}{ENCODING}|
+%
+% Declare a macro |\enc-CODINGSCHEME| which expands to |ENCODING|.
+% This is used to determine the encoding in |\pltomtx|.
+% \changes{1.927}{2004/07/31}{Lowercased encoding file names. (LH)}
+%
+% \begin{macrocode}
+\def\declareencoding#1#2{\x_cs\edef{enc-#1}{#2}}
+% \end{macrocode}
+% \end{macro}
+%
+% Old \TeX{} text font encodings.
+% \begin{macrocode}
+\declareencoding{TEX~TEXT}{ot1}
+\declareencoding{TEX~TEXT~WITHOUT~F-LIGATURES}{ot1}
+\declareencoding{TEX~TYPEWRITER~TEXT}{ot1tt}
+% \end{macrocode}
+%
+% Old \TeX{} math font encodings.
+% \begin{macrocode}
+\declareencoding{TEX~MATH~ITALIC}{oml}
+\declareencoding{TEX~MATH~SYMBOLS}{oms}
+\declareencoding{TEX~MATH~EXTENSION}{omx}
+\declareencoding{LATEX~SYMBOLS}{lasy}
+% \end{macrocode}
+%
+% Euler math font encodings.
+% \begin{macrocode}
+\declareencoding{TEX~TEXT~SUBSET}{eufrak}
+\declareencoding{TEX~MATH~ITALIC~SUBSET}{eurm}
+\declareencoding{TEX~MATH~SYMBOLS~SUBSET}{euscr}
+\declareencoding{EULER~SUBSTITUTIONS~ONLY}{euex}
+% \end{macrocode}
+%
+% New \TeX{} text font encodings.
+% \begin{macrocode}
+\declareencoding{EXTENDED~TEX~FONT~ENCODING~-~LATIN}{t1}
+\declareencoding{TEX~TEXT~COMPANION~SYMBOLS~1---TS1}{ts1}
+% \end{macrocode}
+%
+% Rencoded PostScript font encdings.
+% \begin{macrocode}
+\declareencoding{TEXBASE1ENCODING}{8r}
+\declareencoding{TEX~TYPEWRITER~AND~WINDOWS~ANSI}{8y}
+% \end{macrocode}
+%
+% \begin{macro}{\declaresize}
+% |\declaresize{FONTSIZE}{LATEXSIZE}|
+%
+% \begin{macrocode}
+\def\declaresize#1#2{\x_cs\edef{siz-#1}{#2}}
+% \end{macrocode}
+% \end{macro}
+%
+% Default sizes. An empty size argument is equivalent to |<->|,
+% for use with scalable fonts.
+%
+% \begin{macrocode}
+\declaresize{}{<->}
+\declaresize{5}{<5>}
+\declaresize{6}{<6>}
+\declaresize{7}{<7>}
+\declaresize{8}{<8>}
+\declaresize{9}{<9>}
+\declaresize{10}{<10>}
+\declaresize{11}{<10.95>}
+\declaresize{12}{<12>}
+\declaresize{14}{<14.4>}
+\declaresize{17}{<17.28>}
+\declaresize{20}{<20.74>}
+\declaresize{25}{<24.88>}
+% \end{macrocode}
+%
+%
+% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% \section{Debugging}
+%
+% \begin{macro}{\NOFILES}
+% |\NOFILES| switches off file generation, and causes
+% \package{fontinst} to only generate empty files. It only affects the
+% user level commands, so it is primarily of use when debugging
+% commands that build on these, such as for example the
+% |\latin|\-|family| command.
+% \changes{1.914}{2000/05/20}{Added \cs{reglyphfont}. (LH)}
+% \begin{macrocode}
+\def\NOFILES{
+ \def\transformfont##1##2{
+ \touch_file{##1.mtx}
+ \touch_file{##1.pl}
+ }
+ \def\reglyphfont##1##2{\touch_file{##1.mtx}}
+ \def\installfonts{}
+ \def\endinstallfonts{}
+ \def\installfont##1##2##3##4##5##6##7##8{
+ \touch_file{##1.vpl}
+ }
+ \def\installrawfont##1##2##3##4##5##6##7##8{
+ \touch_file{##1.pl}
+ }
+ \def\installfamily##1##2##3{\touch_file{##1##2.fd}}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\touch_file}
+% \begin{macrocode}
+\def\touch_file#1{
+ \edef\lowercase_file{\lowercase{
+ \edef\noexpand\lowercase_file{#1}}}
+ \lowercase_file
+ \open_out{\lowercase_file}
+ \out_line{\percent_char~TEST~FILE.}
+ \out_line{\percent_char~Created~whilst~debugging~fontinst.}
+ \close_out{Test~file}
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+% \Finale
+\endinput
diff --git a/fonts/utilities/fontinst/source/fimapgen.dtx b/fonts/utilities/fontinst/source/fimapgen.dtx
new file mode 100644
index 0000000000..0ebd1fe7d7
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fimapgen.dtx
@@ -0,0 +1,1607 @@
+% \CheckSum{916}
+% \iffalse meta-comment
+%
+% Copyright 1999 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+%%% From file: fimapgen.dtx
+%
+%<*driver>
+\documentclass{ltxdoc}
+\usepackage{fisource}
+
+\title{\texttt{fimapgen.dtx}}
+\author{Lars Hellstr\"om}
+\begin{document}
+\maketitle
+
+\DocInput{fimapgen.dtx}
+
+\end{document}
+%</driver>
+% \fi
+%
+%
+% \section{Generating map file fragments}
+% \label{Sec:Mapfiles}
+% \changes{1.904}{1999/06/15}{Completed rudimentary map file fragment
+% generator, made it part of \texttt{finstmsc.sty}. (LH)}
+% \newcommand\OzTeX{O\kern-.03em z\kern-.15em\TeX}
+%
+% A \emph{map file} is a file which is used by some DVI driver to link
+% various kinds of font information to each other, as is needed for the
+% driver's operation. Examples of such files are the file
+% \texttt{psfonts.map} used by \texttt{dvips} and the config files of
+% \OzTeX. There are however many other such files around in the \TeX\
+% world.
+%
+% Not all of a map file need to be related to linking specific kinds of
+% font information to each other. \OzTeX\ config files can for example
+% be used to set the values of \TeX\ implementation parameters\footnote
+% {The kind of things that were Pascal constants in the original \Web\
+% sources for \TeX.} and there need not be any font-related information
+% at all in them. The important thing is however that there can be map
+% information in them---that information could be automatically written
+% by the routines described here.
+%
+% Since there may be other kinds of information in these files (and often
+% enough need to be for everthing to work right), the routines described
+% here will only generate map file \emph{fragments}. These fragments
+% will then have to be inserted in the final map files somehow, usually
+% through manual editing. The purpose of the routines described here is
+% only to save the user a good deal of (often quite boring) typing, not
+% to actually install everything where it needs to be.
+%
+% \StopEventually{}
+%
+% \begin{macro}{\mapfrags_subsystem}
+% This macro holds the name of the automatic map file fragments
+% writer subsystem of \package{fontinst}, as it appears in error
+% messages.
+% \begin{macrocode}
+\def\mapfrags_subsystem{Map~fragments~writer}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{Interface to main \package{fontinst}}
+% \label{Ssec:interface}
+%
+% The automatic generation of map file fragments is based on the two
+% commands |\storemapdata| and |\makemapentry|. Their respective
+% syntaxes are
+% \begin{quote}
+% |\storemapdata|\marg{\TeX\ font name}\marg{source}^^A
+% \marg{transforms}\\
+% |\makemapentry|\marg{\TeX\ font name}
+% \end{quote}
+%
+% \DescribeMacro{\storemapdata}|\storemapdata| commands are written when
+% a metric file \meta{\TeX\ font name}|.mtx| is generated. The purpose
+% of these commands is to record where the data for that file came from,
+% and what was done to these data. The source of the data is specified
+% in the \meta{source} argument, which can contain one of
+% \begin{quote}
+% |\fromafm|\marg{AFM name}\marg{PS name}\\
+% |\frompl|\marg{PL name}\\
+% |\frommtx|\marg{MTX name}\\
+% |\fromvpl|
+% \end{quote}
+% The only real difference between |\fromafm| and |\frompl| at this
+% stage is that the former specifies the PS name of the font, but the
+% latter does not. If you write a |\store|\-|map|\-|data| command yourself
+% and want to supply the PS name then you should use |\fromafm| even if
+% you took the font metrics from a PL.
+% There is an important difference between |\fromvpl| and the first three
+% in that virtual fonts need no map file entry (and hence there should
+% not be any either). Besides some error checking, |\fromvpl| causes a
+% |\makemapentry| to do essentially nothing.
+%
+% What was done to the data is specified by the \meta{transforms}
+% argument, which is a possibly empty sequence of commands, in which
+% each item is one of
+% \begin{isyntax}
+% |\transformfont|\marg{x-scale}\marg{slant-scale}\\
+% |\reencodefont|\marg{etx}\\
+% |\reglyphfont|
+% \end{isyntax}
+% The order is interpreted so that the thing done first appear first in
+% the sequence. In normal cases there is at most one of each, and then
+% the order is not important. \meta{x-scale}, \meta{slant-scale}, and
+% \meta{y-scale} are the values of these variables used for the
+% transformation, as \TeX\ numbers. \meta{etx} is the name of the ETX
+% file used for the font reencoding.
+% |\reglyphfont| is an error marker. It will not be encountered (but
+% it may well get stored in some table) unless a metric font transform
+% is applied to a font that has been reglyphed, which is illegal.
+%
+% \changes{1.911}{1999/11/17}{\cs{storemapdata} commands are also
+% written to metric files when they are generated. (LH)}
+% In addition to being written to a transforms record file (if one is
+% open), |\storemapdata| commands are also written to the actual metric
+% file. This makes it possible to find out where the data for a file
+% comes from even if the file was made on a previous \package{fontinst}
+% run, but since it requires reading an additional file just to find one
+% command, it will be slower than if the |\storemapdata| appeared in a
+% transforms records file.
+%
+% \DescribeMacro{\makemapentry}|\makemapentry| commands are written when
+% a VPL that uses or a ligfull PL for a font is generated. These
+% commands are the ones which actually cause the map file fragment
+% generator to write an entry, but entries are only written if they
+% haven't been written before. |\makemapentry| uses information that
+% was stored by a previous call to |\storemapdata|.
+%
+% |\storemapdata| stores its arguments in one of the control sequences
+% \describecsfamily{Tf-\meta{font}}|\Tf-|\meta{font}, where \meta{font}
+% is the same thing as \meta{\TeX\ font name} above. |Tf| stands for
+% ``\TeX\ font''. The control sequences in this family are paramterless
+% macros whose replacement texts have the following form:
+% \changes{1.914}{2000/05/30}{Contents of \cs{Tf-\meta{font}} control
+% sequences changed to allow processing the same file of recorded
+% transformations several times on the same run. (LH)}
+% \begin{quote}
+% \marg{made}\marg{source}\marg{transforms}
+% \end{quote}
+% Here \meta{source} and \meta{transforms} are exactly as above.
+% \meta{made} is a number which describes the current status of this font.
+% If \meta{made} is even then the font has been defined but no entry for
+% it has subsequently been written to the map file, whereas if it is odd
+% then an entry for it has been written to the map file. If the value of
+% \meta{made} is less than |\process_generation| then the data in the
+% other two arguments is from a previous run and should be ignored.
+% The |\Tf-|\meta{font} control sequences should always be set globally.
+%
+% \begin{macro}{\process_generation}
+% \begin{macro}{\process_generation_succ}
+% |\process_generation| is a counter which stores the number of the
+% current ``entry generation''. It starts at 0 and is increased by
+% two at each |\donedrivers|. |\process_generation_succ| is a macro
+% which expands to a number one larger than that in |\process_generation|.
+% \multchanges{\cs{process_generation}\cs{process_generation_succ}}
+% {1.914}{2000/05/30}{Control sequences added. (LH)}
+% \begin{macrocode}
+%<*map>
+\newcount\process_generation
+\process_generation=0
+\def\process_generation_succ{1}
+%</map>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\recordtransforms}
+% \begin{macro}{\endrecordtransforms}
+% \begin{macro}{\transform_record_file}
+% In main \package{fontinst}, the command
+% \begin{quote}
+% |\recordtransforms|\marg{filename}
+% \end{quote}
+% starts a block of code within which font transforms will be recorded
+% in the file \meta{filename}. |\endrecordtransforms| ends such a block.
+% \begin{macrocode}
+%<*pkg>
+\def\recordtransforms#1{\open_pout\transform_record_file{#1}}
+\def\endrecordtransforms{
+ \close_pout\transform_record_file{Font~transformation~records}
+}
+\chardef\transform_record_file=\closed_stream
+%</pkg>
+% \end{macrocode}
+% \end{macro} \end{macro} \end{macro}
+%
+%
+% \begin{macro}{\extract_font_generation}
+% The |\extract_font_generation| macro takes the name of a font and
+% returns the \meta{made} component from the |\Tf-|\meta{font} macro
+% for that font, or minus one if that macro hasn't been defined.
+% \changes{1.914}{2000/05/30}{Macro added. (LH)}
+% \begin{macrocode}
+%<*map>
+\def\extract_font_generation#1{
+ \if_defined{Tf-#1}\then
+ \expandafter\expandafter \expandafter\first_of_three
+ \csname Tf-#1\endcsname
+ \else
+ \m@ne
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\storemapdata}
+% There should not be two |\storemapdata| for the same font, hence
+% the check below. (Note that a `font' in this case is an MTX file.
+% It is quite possible (and legal) to generate the PL file for that
+% MTX file more than once.)
+% \changes{1.927}{2004/07/12}{Improved wording of warning message
+% and downgraded it to an info in the case when the two
+% definitions are the same. (LH)}
+% \begin{macrocode}
+\def\storemapdata#1#2#3{
+ \expandafter\def \expandafter\a_macro
+ \expandafter{ \expandafter{ \the\process_generation}{#2}{#3}}
+ \ifnum \extract_font_generation{#1}<\process_generation \else
+ \x_cs\ifx{Tf-#1}\a_macro
+ \fontinstinfo\mapfrags_subsystem
+ {Repeated~definition~of~font~#1}
+ \else
+ \fontinstwarning\mapfrags_subsystem
+ {Inconsistent~redefinition~of~font~#1}
+ \fi
+ \fi
+ \x_cs\let{Tf-#1}=\a_macro
+}
+%</map>
+% \end{macrocode}
+% In main \package{fontinst}, |\storemapdata| should be a noop so
+% that it can appear in metric files.
+% \begin{macrocode}
+%<pkg>\let\storemapdata=\gobble_three
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\record_transform}
+% \changes{1.911}{1999/11/18}{\cs{storemapdata} lines are optionally
+% written to the main output file as well. (LH)}
+% In main \package{fontinst}, the call
+% \begin{quote}
+% |\record_transform|\marg{TFM name}\marg{source}^^A
+% \marg{transforms}\marg{if}
+% \end{quote}
+% writes
+% \begin{quote}
+% |\storemapdata|\marg{TFM name}\marg{source}\marg{transforms}
+% \end{quote}
+% to the transformation recordings file (if font transforms are being
+% recorded) and to the main output file (if the \meta{if} evaluates
+% to true). Note that the caller of |\record_transform| must see to
+% that macros in \meta{source} and \meta{transforms} are written
+% correctly to the file (this is usually accomplished by adding
+% |\string| in suitable places of these arguments during their
+% construction).
+%
+% \begin{macrocode}
+%<*pkg>
+\def\record_transform#1#2#3#4{
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file{\string\storemapdata{#1}{#2}{#3}}
+ \fi
+ #4 \out_line{\string\storemapdata{#1}{#2}{#3}} \fi
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\transformfont}
+% \changes{1.913}{2000/03/11}{Third argument removed, since it isn't
+% used anymore. This change is harmless, since the worst thing
+% that can happen to this argument is that it is typeset. (LH)}
+% \begin{macro}{\reencodefont}
+% \begin{macro}{\reglyphfont}
+% These are initially |\relax|, so they can be |\edef|ed with safely.
+% \begin{macrocode}
+%<*map>
+\let\transformfont\x_relax
+\let\reencodefont\x_relax
+\let\reglyphfont\x_relax
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+%
+% \changes{1.914}{2000/05/30}{The total transform applied for a font is
+% determined before the entry makers are called. (LH)}
+% \begin{macro}{\makemapentry}
+% |\makemapentry| sets |\TeX_font_name|, checks if any map data have
+% been stored for the font in question, and passes them on to
+% |\make_map_entry| if they have; otherwise it raises an error. There
+% is also a group which is begun and ended by |\makemapentry|, to stop
+% values deduced for one entry to interfere with the deduction of values
+% in the following.
+% \changes{1.911}{1999/11/20}{When map data are not known, try to
+% get them from the MTX file before declaring the source unknown.
+% (LH)}
+% \begin{macrocode}
+\def\makemapentry#1{\begingroup
+ \def\TeX_font_name{#1}
+ \ifnum \extract_font_generation{#1}<\process_generation
+ \if_file_exists{#1.mtx}\then
+ \inputmtx{#1}
+ \fi\fi
+ \ifnum \extract_font_generation{#1}<\process_generation
+ \from_unknown{#1}
+ \x_cs\xdef{Tf-#1}{
+ {\process_generation_succ}{\noexpand\from_unknown{#1}}{}
+ }
+ \else
+ \expandafter\expandafter \expandafter\make_map_entry
+ \csname Tf-#1\endcsname
+ \fi
+ \endgroup
+}
+% \end{macrocode}
+%
+% \begin{macro}{\make_map_entry}
+% |\make_map_entry| oversees the interpretation of the
+% \meta{source} part of the map data, something which sets
+% |\source_font_TeX_name| and possibly |\PS_font_name|. It also
+% collects the transforms applied in |\font_transforms|,
+% concatenates them, and calls a list macro |\entry_makers_list| which
+% causes the actual entries to be written, and records in
+% |\Tf-|\meta{\TeX\ font name} that the entries have been written.
+% \begin{macrocode}
+\def\make_map_entry#1#2#3{
+ \ifnum #1=\process_generation
+ \def\font_transforms{#3}
+ #2
+ \_a_false
+ \let\transformfont\concat_transformfont
+ \let\reencodefont\concat_reencodefont
+ \let\reglyphfont\_a_true
+ \font_transforms
+ \if_a_
+ \fontinsterror\mapfrags_subsystem{
+ \string\makemapentry\space for~reglyphed~font
+ }{ No~entry~for~font~\TeX_font_name\space
+ can~be~written,\messagebreak
+ since~it~had~been~reglyphed!~\error_help_a
+ }
+ \else
+ \entry_makers_list
+ \fi
+ \expandafter\gdef \csname Tf-\TeX_font_name \expandafter\endcsname
+ \expandafter{\expandafter{\process_generation_succ}{#2}{#3}}
+ \fi
+}
+%</map>
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\record_usage}
+% In main \package{fontinst}, the call
+% \begin{quote}
+% |\record_usage|\marg{TFM name}
+% \end{quote}
+% writes
+% \begin{quote}
+% |\makemapentry|\marg{TFM name}
+% \end{quote}
+% to the transformation recordings file, if font transforms are being
+% recorded. The |\record_usage| command is, roughly speaking, only used
+% by |\installfont| and |\installrawfont|.
+% \begin{macrocode}
+%<*pkg>
+\def\record_usage#1{
+ \ifnum \transform_record_file=\closed_stream \else
+ \pout_line\transform_record_file{\string\makemapentry{#1}}
+ \fi
+}
+%</pkg>
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\fromafm}
+% |\fromafm| saves its two arguments in the suitable string macros.
+% \begin{macrocode}
+%<*map>
+\def\fromafm#1#2{
+ \def\source_font_TeX_name{#1}
+ \def\PS_font_name{#2}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\frompl}
+% |\frompl| saves its argument in the suitable string macro.
+% \begin{macrocode}
+\def\frompl#1{
+ \def\source_font_TeX_name{#1}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\frommtx}
+% This one is tricky, since it will have to work recursively,
+% fetching data that were stored for some other font. If it cannot
+% find those data in memory, then it tries to get them from the
+% metric file itself.
+% \changes{1.911}{1999/11/17}{When map data are not known, try to
+% get them from the MTX file before declaring the source unknown.
+% (LH)}
+% \begin{macrocode}
+\def\frommtx#1{%
+ \ifnum \extract_font_generation{#1}<\process_generation
+ \if_file_exists{#1.mtx}\then
+ \inputmtx{#1}
+ \fi\fi
+ \ifnum \extract_font_generation{#1}<\process_generation
+ \from_unknown{#1}
+ \x_cs\xdef{Tf-#1}{
+ {\the\process_generation}{\noexpand\from_unknown{#1}}{}
+ }
+ \else
+ \expandafter\expandafter \expandafter\from_mtx
+ \csname Tf-#1\endcsname
+ \fi
+}
+% \end{macrocode}
+% \begin{macro}{\from_mtx}
+% \begin{macrocode}
+\def\from_mtx#1#2#3{
+ \edef\font_transforms{#3\font_transforms}
+ #2
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\fromvpl}
+% The |\fromvpl| command checks if |\font_transforms| is empty. If it
+% is then everything is fine, but no entry should be written for this
+% font. If it isn't then someone has tried to make a transformation of
+% a virtual font, which doesn't work.
+% \begin{macrocode}
+\def\fromvpl{
+ \ifx \empty_command\font_transforms \else
+ \fontinsterror\mapfrags_subsystem{
+ Font~is~virtual,~it~cannot~be~transformed}{
+ No~entry~for~font~\TeX_font_name\space can~be~written.
+ \messagebreak\error_help_a
+ }
+ \fi
+ \let\maker_do\gobble_one
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\AssumeMetafont}
+% The |\AssumeMetafont| general settings command makes |\frompl|
+% behave like |\fromvpl|.
+% \begin{macrocode}
+\def\AssumeMetafont{
+ \def\frompl{
+ \ifx \empty_command\font_transforms \else
+ \fontinsterror\mapfrags_subsystem{
+ A~Metafont~cannot~be~transformed}{
+ No~entry~for~font~\TeX_font_name\space can~be~written.
+ \messagebreak\error_help_a
+ }
+ \fi
+ \let\maker_do\gobble_one
+ }
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\from_unknown}
+% This special value for \meta{source} is used for fonts that are
+% referenced by some |\frommtx| but which have no |\storemapdata|
+% themselves.
+% \begin{macrocode}
+\def\from_unknown#1{
+ \fontinstwarningnoline\mapfrags_subsystem{
+ No~map~data~stored~for~font~#1.\messagebreak
+ No~entry~for~\TeX_font_name\space will~be~written,\messagebreak
+ due~to~insufficient~information}
+ \includewarning\warn_unknown_source
+ \let\maker_do\gobble_one
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\font_transforms}
+% This macro is used to collect all transformations that have been
+% applied to a font in, before they are concatenated.
+% \begin{macrocode}
+\let\font_transforms\empty_command
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\xscale_factor}
+% \begin{macro}{\slant_factor}
+% \begin{macro}{\reencode_etx}
+% |\xscale_factor| and |\slant_factor| are dimens which the entry
+% makers can inspect to check the amount of horizontal scaling and
+% slanting should be applied to the current font. 1\,pt equals the
+% factor~1.
+% \begin{quote}
+% |\expandafter\lose_measure\the\xscale_factor|
+% \end{quote}
+% will produce the corresponding factor.
+%
+% |\reencode_etx| is a macro which contains the name of the (last)
+% ETX file used to reencode the font; it is empty if the font hasn't
+% been reencoded.
+% \multchanges{\cs{xscale_factor}\cs{slant_factor}\cs{reencode_etx}}
+% {1.914}{2000/05/30}{Control sequences added. (LH)}
+% \begin{macrocode}
+\newdimen\xscale_factor \newdimen\slant_factor
+\xscale_factor=\p@ \slant_factor=\z@
+\let\reencode_etx\empty_command
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+% \multchanges{\cs{concat_transformfont}\cs{concat_reencodefont}}
+% {1.914}{2000/05/30}{Macros added. (LH)}
+% \begin{macro}{\concat_transformfont}
+% The |\concat_transformfont| macro is a definition of |\transformfont|
+% which concatenates the transformation expressed by the arguments
+% with the one in |\xscale_factor| and |\slant_factor|.
+% Mathematically, it performs the multiplication
+% $$
+% \left( \begin{array}{cc} f(\#1)& f(\#2)\\ 0& 1 \end{array} \right)
+% \left( \begin{array}{cc}
+% \mbox{\cs{xscale_factor}}& \mbox{\cs{slant_factor}} \\
+% 0& 1
+% \end{array} \right)
+% $$
+% where $f$ stands for |\make_factor|.
+% \begin{macrocode}
+\def\concat_transformfont#1#2{
+ \edef\a_macro{\make_factor{#1}}
+ \xscale_factor=\a_macro\xscale_factor
+ \slant_factor=\a_macro\slant_factor
+ \advance \slant_factor \make_factor{#2}\p@
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\concat_reencodefont}
+% The |\concat_reencodefont| macro is a definition of |\reencodefont|
+% which concatenates the reencoding expressed by the argument with
+% the one in |\reencode_etx|. Since reencoding ignores the previous
+% encoding, concatenating is the same thing as remembering the last
+% reencoding.
+% \begin{macrocode}
+\def\concat_reencodefont#1{\def\reencode_etx{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsection{User interface}
+%
+% The basic usage of the automatic map file fragment generator consists
+% of specifying for which driver(s) entries should be generated,
+% |\input|ing a file of recorded transformations generated by main
+% \package{fontinst}, and signaling that there isn't anything more to
+% write. This can be done with the commands
+% \begin{quote}
+% |\adddriver|\marg{driver name}\marg{fragment file name}\\
+% \meta{possible additional \cs{adddriver} commands}\\
+% |\input |\meta{recorded transforms file}\\
+% |\donedrivers|\\
+% |\bye|
+% \end{quote}
+% It should however be noted that this is the \emph{basic} usage. The
+% map fragments that work for one \TeX\ system need not work for
+% another (even if the driver is the same), and therefore it is
+% necessary to make the whole process of writing map file fragments
+% configurable. A few examples of things you may have to inform the map
+% fragment writer about are (and these are for \package{dvips} alone;
+% that's the driver I know best):
+% \begin{itemize}
+% \item
+% Is the font resident on the printer or must it be downloaded?
+% \item
+% If the font must be downloaded, what is the name of the file it
+% is in? Here one must take into account not only the possibility
+% that the font file might have to be shared with some other
+% software (such as a GUI) and thus cannot be named according to
+% the Berry scheme---even if it is named according to the Berry
+% scheme one still has the question of its extension: \texttt{.pfa},
+% \texttt{.pfb}, or something else? For instances of Multiple Master
+% fonts, you (at least sometimes) have to download more than one file.
+% \item
+% Again if the font must be downloaded, can/should it be partially
+% downloaded?
+% \item
+% In case the font has been reencoded, what is the name of the file
+% which defines this encoding, and by what name does that file make
+% the encoding known to the postscript interpreter?
+% \end{itemize}
+% The mechanisms available for such configuration are described in
+% Subsection~\ref{Sssec:Config-interface}.
+% Note that map files for DVI viewers are on average more likely to need
+% various platform-specific information about the fonts than map files
+% for DVI printer drivers are, and hence once can expect that
+% generation of these will need more extensive configuration than that
+% for the printer drivers.
+%
+%
+% \subsubsection{Interface for basic usage}
+%
+% An \emph{entry maker} is a group of macros which write the entry for
+% the font currently under consideration to a map fragments file each
+% time they are called. The macro to call must have a name of the form
+% \describecsfamily{make_\meta{driver}}|\make_|\meta{driver} for
+% |\adddriver| to recognise it. Each entry maker has a separate output
+% file (opened using |\open_pout|) and the identifier connected to that
+% file is called \describecsfamily{output_\meta{driver}}\relax
+% |\output_|\meta{driver}.
+%
+% A list of all entry makers currently active is maintined in the macro
+% |\entry_makers_list|. Each item in this list has the form
+% \begin{quote}
+% |\maker_do|\,|\make_|\meta{driver}
+% \end{quote}
+% |\maker_do| is usually |\relax|, but it does occationally get set to
+% other values.
+% \par\bigskip
+%
+%
+% \begin{macro}{\adddriver}
+% The |\adddriver| command adds the named driver to the list of
+% drivers to write entries for and opens an output file where the
+% entries for that particular driver will go. Repeated calls to
+% |\adddriver| for the same driver have no effect.
+% \begin{macrocode}
+\def\adddriver#1#2{
+ \x_cs\ifx{make_#1}\x_relax
+ \fontinsterror\mapfrags_subsystem
+ {There~is~no~entry~maker~for~#1}\error_help_a
+ \else
+ \x_cs\ifx{output_#1}\x_relax \_a_true \else
+ \x_cs\ifx{output_#1}\closed_stream \_a_true \else
+ \_a_false
+ \fi\fi
+ \if_a_
+ \x_cs\open_pout{output_#1}{#2}
+ \expandafter\add_to \expandafter\entry_makers_list
+ \expandafter{ \expandafter\maker_do
+ \csname make_#1\endcsname}
+ \fi
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\entry_makers_list}
+% \begin{macro}{\maker_do}
+% \begin{macrocode}
+\let\entry_makers_list\empty_command
+\let\maker_do\x_relax
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\donedrivers}
+% The main function performed by the |\donedrivers| command is to
+% close all the open output files. It might also print some warning
+% messages.
+% \begin{macrocode}
+\def\donedrivers{
+ \def\maker_do##1{
+ \x_cs\close_pout{output\expandafter\gobble_five\string##1}
+ {Map~file~fragments}
+ }
+ \entry_makers_list
+ \let\maker_do\x_relax
+ \let\entry_makers_list\empty_command
+ \errorstopmode
+ \reportwarnings
+ \advance \process_generation \thr@@
+ \edef\process_generation_succ{\the\process_generation}
+ \advance \process_generation \m@ne
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\gobble_five}
+% \begin{macrocode}
+\def\gobble_five#1#2#3#4#5{}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% It is appropriate that the map file writer writes a summary of the
+% kinds of risky things which happened when it is done writing data to
+% files. To simplify implementing such things, there is a command
+% \DescribeMacro{\includewarning}|\includewarning| that takes care of
+% the bookkeeping involved. After the call
+% \begin{quote}
+% |\includewarning|\meta{command}
+% \end{quote}
+% the \meta{command} will be executed exactly once the next time
+% |\reportwarnings| is executed. The \meta{command} usually expands to
+% something like
+% \begin{quote}
+% \small|\fontinstwarningnoline\mapfrags_subsystem{|\\
+% | Check~the~output~file(s)--some~data~was~considered~uncertain}|
+% \end{quote}
+%
+% \begin{macro}{\warnings_list}
+% The |\warnings_list| macro contains a list of all warnings that
+% should be made. It expands to a sequence of
+% \begin{quote}
+% |\warning_do|\meta{command}
+% \end{quote}
+% |\warnings_list| is always assigned globally.
+% \begin{macrocode}
+\g_let\warnings_list=\empty_command
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\includewarning}
+% \begin{macro}{\warning_do}
+% The |\includewarning| command adds an entry for its argument to the
+% |\warnings_list| list, provided there wasn't already such an entry.
+% |\includewarning| is based on the macro |\warning_do|, which does
+% most of the bookkeeping for making sure the list contains at most
+% one entry of each kind. |\warning_do| normally expects to be
+% expanded in the context
+% \begin{quote}
+% |\warning_do|\meta{new command}\meta{old command}\meta{next}
+% \end{quote}
+% The \meta{new command} is the command that is being added to the
+% list, and the \meta{old command} is a command that is already in the
+% list. \meta{next} is the first token in the next item in the
+% list---in most cases another |\warning_do|. If \meta{new command}
+% and \meta{old command} are not equal, this should expand to
+% \begin{quote}
+% |\noexpand\warning_do|\,|\noexpand|\meta{old command}\,^^A
+% \meta{next}\,\meta{new command}
+% \end{quote}
+% If on the other hand they are equal, this should expand to
+% \begin{quote}
+% |\noexpand\warning_do|\,|\noexpand|\meta{old command}\,^^A
+% \meta{next}\,|\x_relax|
+% \end{quote}
+% The reason for this is that the last \meta{next} will not be a
+% |\warning_do|, but an |\ifx| which tests whether a new item should
+% be added to the list.
+% \begin{macrocode}
+\def\warning_do#1#2#3{
+ \noexpand\warning_do \noexpand#2
+ \ifx #1#2
+ \expandafter#3 \expandafter\x_relax
+ \else
+ \expandafter#3 \expandafter#1
+ \fi
+}
+\def\includewarning#1{
+ \xdef\warnings_list{
+ \expandafter\swap_two \expandafter#1 \warnings_list
+ \if_equal\x_relax\then \else
+ \noexpand\warning_do \noexpand#1
+ \fi
+ }
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\reportwarnings}
+% The |\reportwarnings| command reports all the warnings and empties
+% the |\warnings_list|.
+% \begin{macrocode}
+\def\reportwarnings{
+ \begingroup
+ \let\warning_do=\x_relax
+ \warnings_list
+ \endgroup
+ \g_let\warnings_list=\empty_command
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\warn_unknown_source}
+% \begin{macro}{\warn_undecided_data}
+% \begin{macro}{\warn_uncertain_data}
+% These macros are used to output warnings at the |\reportwarnings| at
+% the end of |\donedrivers|.
+% \begin{macrocode}
+\def\warn_unknown_source{
+ \fontinstwarningnoline\mapfrags_subsystem{
+ Some~font~is~missing~from~the~output~file(s),\messagebreak
+ since~its~source~is~unknown}
+}
+\def\warn_undecided_data{
+ \fontinstwarningnoline\mapfrags_subsystem{
+ Check~the~output~file(s)--some~data~could~not~be~determined}
+}
+\def\warn_uncertain_data{
+ \fontinstwarningnoline\mapfrags_subsystem{
+ Check~the~output~file(s)--some~data~was~considered~uncertain}
+}
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}
+%
+%
+%
+% \subsubsection{Configuration interface}
+% \label{Sssec:Config-interface}
+%
+% To correctly format reencodings, the map file writer must know what
+% the ETX encodings correspond to. In the case of drivers which
+% generate postscript output, this information is stored in the
+% \describecsfamily{pse-\meta{etx}}|\pse-|\meta{etx} family of macros.
+% \meta{etx} is the name (suffix excluded) of the ETX file that the
+% information pertains to. The expansion of these macros are of the form
+% \begin{quote}
+% \marg{postscript name}\marg{action}
+% \end{quote}
+% \meta{postscript name} is the name by which the encoding is known to
+% the postscript interpreter, and \meta{action} lists any additional
+% action that must be taken before the encoding can be used.
+% ^^A So far the only actions known is
+% ^^A \DescribeMacro{\download}|\download|\marg{file},
+% ^^A which will cause code for downloading the file by the name
+% ^^A \meta{file} (suffix included) to be inserted in the output.
+%
+% \begin{macro}{\declarepsencoding}
+% Data is entered in a |\pse-|\meta{etx} macro using the
+% |\declare|\-|ps|\-|encoding| command. Its syntax is
+% \begin{quote}
+% |\declarepsencoding|\marg{etx}\marg{postscript name}\marg{action}
+% \end{quote}
+% \begin{macrocode}
+\def\declarepsencoding#1#2#3{\x_cs\gdef{pse-#1}{{#2}{#3}}}
+%</map>
+% \end{macrocode}
+% In main \package{fontinst}, |\declarepsencoding| should be a noop so
+% that it can appear in encoding files. It's probably a good idea to
+% show it when typesetting as well.
+% \changes{1.931}{2005/05/13}{Added main \package{fontinst} and
+% \package{fontdoc} definitions. (LH)}
+% \begin{macrocode}
+%<pkg>\let\declarepsencoding=\gobble_three
+%<*doc>
+\def\declarepsencoding#1#2#3{\comment{%
+ This file corresponds to the \FD@typeset@string{#2} encoding vector.}}
+%</doc>
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\providepsencoding}
+% This command is basically the same as |\declarepsencoding|, but it
+% checks whether the encoding has already been set and does nothing
+% if that is the case. It is used for autogenerated declarations, to
+% allow the user to override the setting.
+% \changes{1.931}{2005/05/13}{Command added. (LH)}
+% \begin{macrocode}
+%<*map>
+\def\providepsencoding#1#2#3{
+ \if_undefined{pse-#1}\then
+ \declarepsencoding{#1}{#2}{#3}
+ \fi
+}
+%</map>
+%<pkg>\let\providepsencoding=\gobble_three
+%<doc>\newcommand\providepsencoding[3]{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\download}
+% By default |\download| gobbles its argument. It should be redefined
+% when that is not the desired effect.
+% \begin{macrocode}
+%<*map>
+\let\download=\gobble_one
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\fulldownload}
+% By default this defaults to being a synonym of |\download|, to
+% simplify matters for drivers where the distinction is not relevant.
+% They should be redefined when that is not the desired effect.
+% \changes{1.928}{2004/12/13}{Command added. (LH)}
+% \begin{macrocode}
+\def\fulldownload#1{\download{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\encodingdownload}
+% By default this defaults to being a synonym of |\download|, to
+% simplify matters for drivers where the distinction is not relevant.
+% They should be redefined when that is not the desired effect.
+% \changes{1.931}{2005/05/04}{Command added. (LH)}
+% \begin{macrocode}
+\def\encodingdownload#1{\download{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% Some encodings seem to always be present, so they can be declared here.
+% \begin{macrocode}
+\declarepsencoding{8r}{TeXBase1Encoding}{\encodingdownload{8r.enc}}
+\declarepsencoding{8a}{StandardEncoding}{}
+% \end{macrocode}
+% \package{fontinst} must be told about other postscript encodings (if you
+% have them installed). The \texttt{finstmsc.rc} file is the right place
+% for these declarations.\relax
+% \SortIndex{finstmsc.rc file}{\texttt{finstmsc.rc} file}
+%
+% Next we have the cofiguration for fonts, which works in a similar
+% fashion. The main problem here seems to be to determine which files (if
+% any) should be downloaded to the printer, and this can be specified
+% using |\download| commands as for the encodings. The family
+% \describecsfamily{psf-\meta{PS font name}}|\psf-|\meta{PS font name}
+% of macros expand to a sequence of \meta{actions} as for the encodings.
+% If there is such a macro for a font then the instructions found there
+% should be followed.
+%
+% It is recommended that the contents of a |\psf-|\meta{PS font name}
+% macro is executed before the map file entry is written, and that
+% commands like |\download| are temporarily redefined to build the text
+% for the entry, rather than having the |\write| in |\pout_line| expand
+% the contents of |\psf-|\meta{PS font name}.
+%
+% \begin{macro}{\specifypsfont}
+% The |\specifypsfont| command is used as
+% \begin{quote}
+% |\specifypsfont|\marg{PS font name}\marg{actions}
+% \end{quote}
+% It can be used to specify the actions that should be done to make a
+% Postscript font known to the printer, when the automatic guessing
+% would not be right.
+% \begin{macrocode}
+\def\specifypsfont#1#2{\x_cs\def{psf-#1}{#2}}
+% \end{macrocode}
+% \end{macro}
+%
+% Examples of cases where |\specifypsfont| would be needed are:
+% \begin{itemize}
+% \item Fonts which are resident on the printer. In this case the
+% \meta{actions} argument should be empty, e.g.
+% \begin{quote}
+% |\specifypsfont{Times-Roman}{}|
+% \end{quote}
+% \item Instances of multiple master fonts. In this case one must
+% download both the multiple master font and the stub file that
+% defines the instance.
+%
+% Subsection~10.6.1 in The \LaTeX\ graphics companion~\cite
+% {LaTeX-graph-comp} contains an example with an instance of the
+% \texttt{MinionMM} multiple master font. Both the \TeX\ and
+% (what is of interest here) the PS name for this instance is
+% \texttt{zmnl8ac6}, the base multiple master font is stored in the
+% file \texttt{MinionMM.pfb}, and the stub file is called
+% \texttt{zmnl8ac6.pro}. The |\specifypsfont| command for this is
+% \begin{quote}
+% |\specifypsfont{zmnl8ac6}{%|\\
+% | \download{MinionMM.pfb}\download{zmnl8ac6.pro}%|\\
+% |}|
+% \end{quote}
+% (It should probably be remarked that the most common method of
+% defining a multiple master font instance is not to explicitly
+% create it as in this example, but to simply use it as any ordinary
+% PS font and then rely on the PS \textsf{findfont} operator to
+% automagically create it for you. This requires using a special
+% naming scheme for instances of multiple master fonts.)
+% \item Fonts which do not fit any of the general naming schemes.
+% \end{itemize}
+%
+%
+% \begin{macro}{\AssumeLWFN}
+% This command makes \mbox{MacOS} \texttt{LWFN} style abbreviated
+% Postscript font names the default for fonts that have no
+% |\psf-| entry.
+% \begin{macrocode}
+\def\AssumeLWFN{\let\get_PS_font_file\LWFN_get_PS_font_file}
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \subsection{Deducing values for the map file entries}
+%
+%
+% \subsubsection{Basic principles}
+%
+% The automatic generation of map file fragments mainly consists of
+% determining various text strings and writing these to a file as the
+% format of the map file being written requires. The complicated part is
+% usually to determine what these text strings should be, since the only
+% restriction imposed by the output format often is that the strings
+% should be written in the right order and with separating whitespace.
+%
+% It is furthermore the case that some of these text strings seem to be
+% hard to deduce from the information primarily given in the command to
+% write the entry, but somewhat easier to deduce from some other deduced
+% text string.
+%
+% Therefore the following model seems appropriate. For each text string
+% that may need to be deduced, there is one macro which is used to store
+% the string (if it has been deduced) and one macro which can be called
+% to set the former macro to an appropriate value. Thus there is one
+% macro |\PS_font_name| which stores the postscript name for the font
+% currently in question and one macro
+% \describecsfamily{get_\meta{string name}}|\get_PS_font_name| which
+% determines the proper value for |\PS_font_name|. There is also a macro
+% \DescribeMacro{\unknown_str}|\unknown_str| to which all the
+% string storing macros should initially be |\let|, so that it can be
+% easily tested whether a string storing macro has been given its proper
+% value or not.
+%
+% Typically, if |\PS_font_name| is used somewhere, one would first have
+% a piece of code that says
+% \begin{quote}
+% \small
+% |\ifx\PS_font_name\unknown_str|\\
+% | \get_PS_font_name|\\
+% |\fi|
+% \end{quote}
+% to ensure that it is known when it is used.
+%
+% \begin{macro}{\unknown_str}
+% A suitable value for this macro seems to be |?????|.
+% \begin{macrocode}
+\def\unknown_str{?????}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\clueless_str}
+% To further support this model, there is also a macro |\clueless_str|
+% which a string storing macro should be |\let| equal to if its proper
+% value could not be determined. This distinction is useful for the
+% |\get_|\textellipsis\ macros, since if |\get_|$A$ can determine the
+% correct value of $A$ from $B$, but also from $C$, then it helps if
+% |\get_|$A$ can easily check whether it has previously turned out to
+% be impossible to determine the value of $B$, because then it can
+% simply deduce $A$ from $C$ instead.
+%
+% \begin{macrocode}
+\edef\clueless_str{\unknown_str ?}
+% \end{macrocode}
+% \end{macro}
+%
+% An example of how |\clueless_str| should be used is the following
+% skeleton of a |\get_|$A$ macro:
+% \begin{quote}\small
+% |\def\get_|$A$|{|\\
+% | \ifx\unknown_str\|$B$| \get_|$B$| \fi|\\
+% | \ifx\clueless_str\|$B$\\
+% | \ifx\unknown_str\|$C$| \get_|$C$| \fi|\\
+% | \ifx\clueless_str\|$C$\\
+% | \let\|$A$|\clueless_str|\\
+% | \else|\\
+% | |\meta{Deduce $A$ from $C$}\\
+% | \fi|\\
+% | \else|\\
+% | |\meta{Deduce $A$ from $B$}\\
+% | \fi|\\
+% |}|
+% \end{quote}
+%
+%
+% \subsubsection{Implementation}
+%
+% \begin{macro}{\TeX_font_name}
+% This is the name (as appearing in a DVI or VF file) of the font for
+% which an entry should be made. It is set by |\makemapentry|, so no
+% |\get_|\textellipsis\ macro is needed.
+% \begin{macrocode}
+\let\TeX_font_name\unknown_str
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\source_font_TeX_name}
+% This is the name (as AFM or PL) of the font whose metrics were
+% used by \package{fontinst}. It is set by |\fromafm| or |\frompl|,
+% so no |\get_|\textellipsis\ macro is needed.
+% \begin{macrocode}
+\let\source_font_TeX_name\unknown_str
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\PS_font_name}
+% This is the name (as FontName entry in an AFM or correspondingly) of
+% the font in question.
+% \begin{macrocode}
+\let\PS_font_name\unknown_str
+% \end{macrocode}
+% \begin{macro}{\get_PS_font_name}
+% I expect this to become one of the central macros in the map file
+% generation (at least when entries are generated for postscript
+% fonts), but for the moment it does the closest thing to nothing a
+% |\get_|\textellipsis\ macro is allowed to do; it admits it hasn't
+% got a clue about what the proper value is.
+% \begin{macrocode}
+\def\get_PS_font_name{\let\PS_font_name\clueless_str}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\AssumeAMSBSYY}
+% \begin{macro}{\AssumeBaKoMa}
+% These commands redefine |\get_PS_font_name| so that it returns the
+% PS name this font would have if it was part of the AMS\slash
+% Blue~Sky\slash Y\&Y and BaKoMa respectively distribution of the
+% Computer Modern fonts---the \TeX\ font name in all upper case and
+% all lower case respectively.
+% \begin{macrocode}
+\def\AssumeAMSBSYY{\def\get_PS_font_name{
+ \uppercase \expandafter{ \expandafter\def
+ \expandafter\PS_font_name \expandafter{ \source_font_TeX_name}
+ }
+}}
+% \end{macrocode}
+% \begin{macrocode}
+\def\AssumeBaKoMa{\def\get_PS_font_name{
+ \lowercase \expandafter{ \expandafter\def
+ \expandafter\PS_font_name \expandafter{ \source_font_TeX_name}
+ }
+}}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\PS_font_file}
+% This is the name of the file (suffix included) in which the PS font
+% is expected to be found.
+% \begin{macrocode}
+\let\PS_font_file\unknown_str
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\get_PS_font_file}
+% \begin{macro}{\normal_get_PS_font_file}
+% \begin{fistring}{PSfontsuffix}
+% The macro |\normal_get_PS_font_file| is (hardly surprisingly) the
+% normal |\get_PS_font_file|. It simply uses |\source_font_TeX_name|
+% plus the suffix specified by the |PSfontsuffix| string.
+% \begin{macrocode}
+\resetstr{PSfontsuffix}{.pfa}
+\def\normal_get_PS_font_file{
+ \edef\PS_font_file{\source_font_TeX_name\str{PSfontsuffix}}
+}
+\let\get_PS_font_file=\normal_get_PS_font_file
+% \end{macrocode}
+% \end{fistring}\end{macro}\end{macro}
+%
+% \begin{macro}{\LWFN_get_PS_font_file}
+% \begin{macro}{\abbreviate_PS_font_name}
+% In MacOS, Postscript fonts file names are usually abbreviated forms of
+% the Postscript font names, formed using the so called
+% \(5+3+3+\cdots\) rule---keep the first five letters of the first
+% subword, keep the first three letters of all following subwords. The
+% |\LWFN_get_PS_font_file| macro uses this scheme if the Postscript
+% name for the font is known, otherwise it calls the
+% |\normal_get_PS_font_file|. The LWFN in the macro name is the type
+% code for such files.
+%
+% The algorithm is based on using |\aftergroup| to construct the
+% wanted |\def| statement, only |\aftergroup|ing the letters that are
+% not to be removed in the abbreviation. |\a_count| is used as a
+% counter of how many more letters in the current subword should be
+% kept.
+% \begin{macrocode}
+\def\LWFN_get_PS_font_file{
+ \ifx \PS_font_name\unknown_str \get_PS_font_name \fi
+ \ifx \PS_font_name\clueless_str
+ \normal_get_PS_font_file
+ \includewarning\warn_uncertain_data
+ \else
+ \begingroup
+ \aftergroup\def \aftergroup\PS_font_file
+ \aftergroup{
+ \a_count=4~
+ \expandafter\expandafter \expandafter\aftergroup
+ \expandafter\swap_two \expandafter\abbreviate_PS_font_name
+ \PS_font_name \x_relax
+ \aftergroup}
+ \endgroup
+ \fi
+}
+% \end{macrocode}
+% \begin{macrocode}
+\def\abbreviate_PS_font_name#1{
+ \ifx \x_relax#1 \else
+ \ifnum \uccode`#1=`#1
+ \a_count=2
+ \aftergroup#1
+ \else\ifx -#1
+ \a_count=\z@
+ \else\ifnum \a_count>\z@
+ \advance \a_count \m@ne
+ \aftergroup#1
+ \fi\fi\fi
+ \expandafter\abbreviate_PS_font_name
+ \fi
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+%
+% \subsection{Driver makers}
+%
+% This subsection contains the definitions of macros that makes up the
+% driver makers.
+%
+%
+% \subsubsection{The \texttt{debug} driver}
+%
+% The \texttt{debug} driver maker doesn't really generate entries for
+% any DVI driver map file, it just prints the data that was available.
+% It is mainly intended for debugging purposes, but it might also serve
+% as a basic model for other driver makers.
+%
+% \begin{macro}{\make_debug}
+% \begin{macrocode}
+\def\make_debug{
+ \pout_line\output_debug{Driver~data~for~font~\TeX_font_name:}
+ \pout_lline\output_debug{Source~font~TeX~name:~\source_font_TeX_name}
+ \ifx \reencode_etx\empty_command \else
+ \pout_lline\output_debug{Font~reencoded~using~\reencode_etx.etx.}
+ \fi
+ \ifdim \xscale_factor=\p@ \else
+ \pout_lline\output_debug{Font~x-scaled~by~
+ \expandafter\lose_measure\the\xscale_factor.
+ }
+ \fi
+ \ifdim \slant_factor=\z@ \else
+ \pout_lline\output_debug{Font~slanted~by~
+ \expandafter\lose_measure\the\slant_factor.
+ }
+ \fi
+ \debug_values_hook
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \begin{macro}{\debug_value}
+% The |\debug_value| macro can be used to print the name and contents
+% of an arbitrary value macro in the |debug| driver. It is called with
+% the value macro as argument, e.g.
+% \begin{quote}
+% |\debug_value\PS_font_name|
+% \end{quote}
+%
+% \begin{macrocode}
+\def\debug_value#1{
+ \ifx #1\unknown_str
+ \csname get_ \expandafter\gobble_one \string#1 \endcsname
+ \fi
+ \pout_lline\output_debug{\string#1:~#1}
+ \ifx #1\clueless_str \includewarning\warn_undecided_data \fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\debugvalue}
+% \begin{macro}{\debug_values_hook}
+% The |\debugvalue| command is a user level interface for adding
+% value macros to the list of those that are displayed by the
+% \texttt{debug} driver. The argument is the name of the value in
+% question, e.g.
+% \begin{quote}
+% |\debugvalue{PS_font_name}|
+% \end{quote}
+% Note that the name given to |\debugvalue| is not the control
+% sequence in which the name is stored.
+% \begin{macrocode}
+\def\debugvalue#1{
+ \expandafter\add_to \expandafter\debug_values_hook
+ \expandafter{ \expandafter\debug_value \csname#1\endcsname}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\let\debug_values_hook\empty_command
+\debugvalue{PS_font_name}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \subsubsection{The \texttt{dvips} driver}
+%
+% \changes{1.912}{2000/02/19}{\texttt{dvips} mapfile fragments writer
+% added. (LH)}
+% Before constructing an entry for a \package{dvips} mapfile, it should
+% be sorted out how such an entry should look. The \package{dvips}
+% manual says
+% \begin{quotation}
+% The parsing of the \texttt{psfonts.map} file should be explained to
+% eliminate all confusion. If a line is empty or begins with a space,
+% asterisk, semicolon, or hash mark, it is ignored. Each remaining
+% line is separated into words, where words are separated by spaces or
+% tabs. If a word begins with a double quote, it extends until the
+% next double quote or the end of the line. If a word starts with a
+% less than character, it is treated as a font header file (or a
+% downloaded PostScript font). There can be more than one such header
+% for a given font. If a word starts with a double quote, it is a
+% special instruction for generating that font. Otherwise it is a
+% name. The first such name is always the name \TeX\ uses for the
+% font and is also the name of the raw \texttt{tfm} file. If there is
+% another name word, that name is used as the PostScript name; if
+% there is only one name word, it is used for both the \TeX\ name and
+% the PostScript name.
+% \end{quotation}
+%
+% A \package{fontinst}-generated map file entry for the \texttt{dvips}
+% driver has the following structure:
+% \begin{isyntax}
+% \meta{\TeX{} font name} \meta{PS font name} \meta{downloads}
+% \meta{font transformations}
+% \end{isyntax}
+% \meta{\TeX{} font name} is simply the value of |\TeX_font_name| and
+% \meta{PS font name} is simply the value of |\PS_font_name|.
+% \meta{downloads} is a possibly empty sequence in which each item
+% has the form
+% \begin{quote}
+% \meta{prefix}\meta{filename}
+% \end{quote}
+% The \meta{prefix} values I've came across are empty,\footnote{I think
+% this is only used for files that \package{dvips} should ignore, but
+% which certain other programs that read the same \texttt{psfonts.map}
+% need.} |<|, |<<|, and |<[|. Currently |<| is always used.
+% \meta{filename} is a filename with suffix. \meta{font transformations}
+% is either empty or has the form
+% \begin{quote}
+% |"| \meta{Postscript code} |"|
+% \end{quote}
+%
+% Should support for the |<<| or |<[| prefixes be needed, then this
+% should be done by adding some new variant of the |\download|
+% command---|\fullldownload|, maybe---rather than adding the extra
+% character to the \meta{filename}. To simplify matters for other drivers,
+% such new variants should by default expand to |\download|, rather than
+% |\gobble_one|.
+%
+%
+% \begin{macro}{\downloads_list}
+% \begin{macro}{\append_download}
+% The |\downloads_list| is a token list register which is especially
+% used for accumulating |\download| commands. Each driver maker which
+% uses it should begin by emptying it. The command
+% \begin{quote}
+% |\append_download|\marg{cseq}\marg{string expression}
+% \end{quote}
+% \changes{1.931}{2005/05/10}{New syntax (two arguments)! The second
+% is expanded, whereas the first is protected by a \cs{noexpand}.
+% (LH)}
+% appends
+% \begin{quote}
+% \meta{cseq}\marg{expanded string expression}
+% \end{quote}
+% to |\downloads_list|. It overwrites |\a_macro|.
+% \begin{macrocode}
+\newtoks\downloads_list
+\def\append_download#1#2{
+ \edef\a_macro{
+ \downloads_list =
+ \noexpand\expandafter{ \noexpand\the \downloads_list
+ \noexpand#1 {#2} }
+ }
+ \a_macro
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+%
+% \begin{macro}{\make_dvips}
+% This macro gathers the information for a \texttt{dvips} driver entry
+% and writes it to the corresponding output file. As a \texttt{dvips}
+% mapfile entry is on one line, the entire entry is written at once.
+% The \meta{font transformations} is collected as explicit text in the
+% macro |\postscript_code|. The \meta{downloads} is collected as a
+% sequence of |\|\dots|download| commands in the |\downloads_list|
+% token register.
+% \changes{1.931}{2005/05/10}{Supporting \cs{fulldownload} and
+% \cs{encodingdownload}. (LH)}
+% \begin{macrocode}
+\def\make_dvips{
+ \downloads_list={}
+ \let\postscript_code\empty_command
+ \def\download{\append_download\download}
+ \def\fulldownload{\append_download\fulldownload}
+ \def\encodingdownload{\append_download\encodingdownload}
+ \ifx \reencode_etx\empty_command \else
+ \if_undefined{pse-\reencode_etx}\then
+ \etxtoenc{\reencode_etx}{\reencode_etx}
+ \fi
+ \expandafter\expandafter \expandafter\second_of_two
+ \csname pse-\reencode_etx\endcsname
+ \edef\postscript_code{\postscript_code\space
+ \expandafter\expandafter \expandafter\first_of_two
+ \csname pse-\reencode_etx\endcsname
+ \space ReEncodeFont
+ }
+ \fi
+ \ifdim \xscale_factor=\p@ \else
+ \edef\postscript_code{\postscript_code
+ \space\expandafter\lose_measure\the\xscale_factor
+ \space ExtendFont
+ }
+ \fi
+ \ifdim \slant_factor=\z@ \else
+ \edef\postscript_code{\postscript_code
+ \space\expandafter\lose_measure\the\slant_factor
+ \space SlantFont
+ }
+ \fi
+% \end{macrocode}
+% After constructing the \meta{Postscript code} and having appended
+% the necessary download (if any) for that code, the next problem is
+% to determine the actual \meta{PS font name} and append the downloads
+% needed to actually define the font to the Postscript interpreter. If
+% there is no special entry for this font in the |\psf-|\meta{PS font
+% name} table, or if its \meta{PS font name} is unknown, then it is
+% assumed that exactly one file should be downloaded. As the name of
+% that file is taken the value of |\PS_font_file|.
+% \begin{macrocode}
+ \ifx \PS_font_name\unknown_str \get_PS_font_name \fi
+ \ifx \PS_font_name\clueless_str
+ \includewarning\warn_undecided_data
+ \_a_true
+ \else
+ \if_undefined{psf-\PS_font_name}\then
+ \_a_true
+ \else
+ \csname psf-\PS_font_name \endcsname
+ \_a_false
+ \fi\fi
+ \if_a_
+ \ifx \PS_font_file\unknown_str \get_PS_font_file \fi
+ \append_download\download{\PS_font_file}
+ \ifx \PS_font_file\clueless_str
+ \includewarning\warn_undecided_data
+ \fi
+ \fi
+% \end{macrocode}
+% Finally, the entire entry is written to the file. The point with
+% expanding past an empty command is that \TeX\ in a |\write| normally
+% jumps past the expansion of a |\the|\meta{token list register}
+% without expanding it further, but this effect can be prevented by
+% expanding the |\the| with an |\expandafter|.
+% \begin{macrocode}
+ \def\download##1{~<##1}
+ \def\fulldownload##1{~<<##1}
+ \def\encodingdownload##1{~<[##1}
+ \pout_line\output_dvips{
+ \TeX_font_name\space\PS_font_name
+ \expandafter\empty_command \the\downloads_list
+ \ifx \postscript_code\empty_command \else
+ \space"\postscript_code\space"
+ \fi
+ }
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+%
+% \subsubsection{The \texttt{dvipdfm} driver}
+%
+% \changes{1.912}{2000/02/22}{\texttt{dvipdfm} mapfile fragments writer
+% added. (LH)}
+%
+% A mapfile entry for the \texttt{dvipdfm} driver has the following
+% structure:
+% \begin{isyntax}
+% \meta{\TeX{} font name} \meta{encoding} \meta{PS font}
+% \meta{options}
+% \end{isyntax}
+% \meta{\TeX{} font name} is simply the value of |\TeX_font_name|.
+% \meta{encoding} is the name of the encoding file which should be used
+% to reencode the font, or \texttt{default} if there is none. \meta{PS
+% font} is the value of |\PS_font_name| for the standard 35 fonts
+% (i.e., fonts which will not be included in the PDF generated), but for
+% other fonts it is the name of the file which contains the
+% font.\footnote{The documentation seems to say that \texttt{dvipdfm}
+% can only understand fonts in PFB format; I have chosen to ignore this
+% potential problem.} \meta{options}, finally, is a possibly empty
+% sequence of space-separated options. Each option is one of the
+% following
+% \begin{quote}
+% |-e |\meta{number}\\
+% |-s |\meta{number}\\
+% |-r|
+% \end{quote}
+% The |-e| and |-s| options extend and slant by the given amounts. The
+% |-r| option is a workaround for some Acrobat bugs; it is currently not
+% generated by \package{fontinst}.
+%
+% \begin{macro}{\make_dvipdfm}
+% This macro gathers the information for a \texttt{dvipdfm} driver entry
+% and writes it to the corresponding output file. As a \texttt{dvipdfm}
+% mapfile entry is on one line, the entire entry is written at once.
+% The \meta{options} text is collected as explicit text in the
+% macro |\options_text|. The \meta{downloads} is collected as a
+% sequence of |\download| commands in the |\downloads_list| token
+% register.
+% \begin{macrocode}
+\def\make_dvipdfm{
+ \def\font_encoding{default}
+ \ifx \reencode_etx\empty_command \else
+ \if_undefined{pse-\reencode_etx}\then
+ \etxtoenc{\reencode_etx}{\reencode_etx}
+ \fi
+ \def\download##1{\def\font_encoding{##1}}
+ \expandafter\expandafter \expandafter\second_of_two
+ \csname pse-\reencode_etx\endcsname
+ \fi
+ \let\options_text\empty_command
+ \ifdim \xscale_factor=\p@ \else
+ \edef\options_text{\options_text\space
+ -e~\expandafter\lose_measure\the\xscale_factor
+ }
+ \fi
+ \ifdim \slant_factor=\z@ \else
+ \edef\options_text{\options_text\space
+ -s~\expandafter\lose_measure\the\slant_factor
+ }
+ \fi
+% \end{macrocode}
+% After constructing the \meta{options} and having determined
+% \meta{encoding}, the next problem is to determine the actual
+% \meta{PS font}, which will be put in |\a_macro|. If there is no
+% special entry for this font in the |\psf-|\meta{PS font name} table,
+% or if its \meta{PS font name} is unknown, then it is assumed that
+% exactly one file should be downloaded. As the name of that file is
+% taken the value of |\PS_font_file|.
+% \begin{macrocode}
+ \ifx \PS_font_name\unknown_str \get_PS_font_name \fi
+ \if_or \if_equal\PS_font_name\clueless_str \or_else
+ \if_undefined{psf-\PS_font_name}
+ \then
+ \ifx \PS_font_file\unknown_str \get_PS_font_file \fi
+ \ifx \PS_font_file\clueless_str
+ \includewarning\warn_undecided_data
+ \fi
+ \let\a_macro=\PS_font_file
+ \else
+ \let\a_macro=\PS_font_name
+ \def\download##1{\def\a_macro{##1}}
+ \csname psf-\PS_font_name \endcsname
+ \fi
+% \end{macrocode}
+% Finally, the entire entry is written to the file.
+% \begin{macrocode}
+ \pout_line\output_dvipdfm{
+ \TeX_font_name\space\font_encoding\space\a_macro
+ \options_text
+ }
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
+% \subsubsection{The \texttt{pltotf} ``driver''}
+% \changes{1.915}{2000/06/27}{\texttt{pltotf} ``driver'' support
+% added. (LH)}
+%
+% It can sometimes be hard to determine which of all the PL files that
+% \package{fontinst} creates need to be converted to TFM files. In most
+% cases no \texttt{8a}-encoded PLs need to be converted as they aren't
+% used as base fonts or installed in an FD file, but to automatically
+% exclude them isn't a trivial task (even though it probably could be
+% done by a regular expression filter for fonts named according to the
+% \texttt{fontname} scheme). There furthermore seems to be some systems
+% on which it for various reasons isn't easy to convert all PLs in a
+% directory. The \texttt{pltotf} ``driver'' support is meant to help with
+% both these problems, as the ``map file'' it creates really is a shell
+% script (batch file) for converting precisely those PL files that need
+% a map file entry to TFM format. I believe the shell script will work
+% both for UNIX and DOS systems.
+%
+% \begin{macro}{\make_pltotf}
+% \begin{fistring}{TFMfileprefix}
+% |\make_pltotf| writes a \package{PLtoTF} command for converting the
+% current font's PL file to a TFM file. If set, the string
+% \texttt{TFMfileprefix} will be prepended to the TFM file name---this
+% could be used for putting the TFMs in some directory other than the
+% current.
+% \begin{macrocode}
+\def\make_pltotf{
+ \pout_line\output_pltotf{pltotf~\TeX_font_name.pl~
+ \ifisstr{TFMfileprefix}\then \str{TFMfileprefix}\fi
+ \TeX_font_name.tfm
+ }
+}
+% \end{macrocode}
+% \end{fistring}\end{macro}
+%
+%
+% \begin{macrocode}
+%</map>
+% \end{macrocode}
+% \Finale
+\endinput
+
diff --git a/fonts/utilities/fontinst/source/fisource.dvi b/fonts/utilities/fontinst/source/fisource.dvi
new file mode 100644
index 0000000000..0a564d8141
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fisource.dvi
Binary files differ
diff --git a/fonts/utilities/fontinst/source/fisource.ist b/fonts/utilities/fontinst/source/fisource.ist
new file mode 100644
index 0000000000..a7f22dde29
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fisource.ist
@@ -0,0 +1,47 @@
+%%
+%% This is file `docindex.ist',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% docindex.dtx (with options: `ist')
+%%
+%% This file may be distributed and/or modified under the conditions
+%% of the LaTeX Project Public License, either version 1.2 of this
+%% license or (at your option) any later version. The latest version
+%% of this license is in
+%% http://www.latex-project.org/lppl.txt
+%% and version 1.2 or later is part of all distributions of LaTeX
+%% version 1999/12/01 or later.
+%%
+%% This file may only be distributed together with a copy of the source
+%% file from which it was generated. You may distribute that source file
+%% without this generated file.
+%%
+item_0 "}{1}\n\\indexitem{1}{"
+item_1 "}{2}\n \\indexitem{2}{"
+item_01 "}{2}\n \\indexitem{2}{"
+item_x1 "}{2}\n \\indexitem{2}{"
+item_2 "}{3}\n \\indexitem{3}{"
+item_12 "}{3}\n \\indexitem{3}{"
+item_x2 "}{3}\n \\indexitem{3}{"
+delim_0 "}{9}{"
+delim_1 "}{9}{"
+delim_2 "}{9}{"
+delim_n ", "
+delim_r "--"
+group_skip "}{0}\n%^^A\n\\indexnewletter{0}{"
+heading_prefix ""
+heading_suffix ""
+headings_flag 1
+actual '='
+quote '!'
+level '>'
+page_precedence "naArR"
+keyword "\\xdocindexentry"
+page_compositor "\\+"
+preamble "\\docindexguard{\\endinput}\n%^^A\n\\indexnewletter{1}{"
+postamble "}{0}\n\\endinput"
+%%
+%%
+%% End of file `docindex.ist'.
diff --git a/fonts/utilities/fontinst/source/fisource.sty b/fonts/utilities/fontinst/source/fisource.sty
new file mode 100644
index 0000000000..35ae65d39f
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fisource.sty
@@ -0,0 +1,691 @@
+% \iffalse
+%
+% Copyright 1999, 2000 the fontinst maintenance team and any individual
+% authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.1 or, at your option, any later version.
+%
+% \fi
+%
+% \title{The \package{fisource} package}
+% \author{Lars Hellstr\"om}
+% \maketitle
+%
+% \begin{macrocode}
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{fisource}%
+ [2003/03/29 v2.16 Fontinst source documentation commands]
+% \end{macrocode}
+%
+% \section{Option processing}
+%
+% \begin{option}{warnfinale}
+% \changes{2.01}{2000/07/06}{Option added. (LH)}
+% Under development I find it quite a nuisance that |\Finale| raises
+% an error if the checksum isn't correct; a warning feels more
+% appropriate. Therefore the \texttt{warnfinale} option redefines
+% |\check@checksum| to emit a warning instead.
+% \begin{macrocode}
+\DeclareOption{warnfinale}{%
+ \@ifpackageloaded{doc}\@firstofone\AtEndOfPackage {%
+ \def\check@checksum{\relax
+ \ifnum\check@sum=\z@
+ \typeout{**********************************}%
+ \typeout{* This macro file has no checksum!}%
+ \typeout{* The checksum should be \the\bslash@cnt!}%
+ \typeout{**********************************}%
+ \else\ifnum \check@sum=\bslash@cnt
+ \typeout{*******************}%
+ \typeout{* Checksum passed *}%
+ \typeout{*******************}%
+ \else
+ \PackageWarning{doc}{Checksum not passed
+ (\the\check@sum<>\the\bslash@cnt)}%
+ \fi\fi
+ \global\check@sum\z@
+ }%
+ }%
+}
+% \end{macrocode}
+% \end{option}
+%
+% All other options are passed on to \package{xdoc}.
+% \begin{macrocode}
+\DeclareOption*{\PassOptionsToPackage{\CurrentOption}{xdoc2}}
+\ProcessOptions\relax
+% \end{macrocode}
+%
+% \changes{2.00}{2000/07/06}{Use \package{xdoc1}. (LH)}
+% \changes{2.02}{2000/07/15}{Use \package{xdoc2}. (LH)}
+% \changes{2.10}{2001/02/27}{Use \package{docidx2e}. (LH)}
+% \begin{macrocode}
+\RequirePackage{xdoc2,docidx2e}
+% \end{macrocode}
+%
+% \section{Miscellanea}
+%
+% \begin{macrocode}
+\CodelineIndex
+\setcounter{IndexColumns}{2}
+\setcounter{tocdepth}{2}
+\DeclareRobustCommand\package[1]{\textsf{#1}}
+\DeclareRobustCommand\eTeX{\(\varepsilon\)-\kern-.125em\TeX}
+% \end{macrocode}
+%
+% \begin{macro}{\AllTeX}
+% \changes{2.13}{2001/08/26}{Command added. (LH)}
+% \begin{macro}{\La}
+% The |\AllTeX| command is for writing `(La)TeX' (but nicer). The
+% definition is taken from \texttt{tugboat.dtx}.
+% \begin{macrocode}
+\newcommand{\La}{%
+ L\kern-.36em
+ {%
+ \setbox0\hbox{T}%
+ \vbox to\ht0{\hbox{%
+ $\m@th$\csname S@\f@size\endcsname
+ \fontsize\sf@size\z@\math@fontsfalse\selectfont
+ A%
+ }\vss}%
+ }%
+}
+\DeclareRobustCommand\AllTeX{(\La\kern-.075em)\kern-.075em\TeX}
+% \end{macrocode}
+% \end{macro}\end{macro}
+%
+% \begin{macro}{\missing}
+% \changes{2.10}{2001/02/27}{Redefined using
+% \cs{NewDescribeCommand}. (LH)}
+% \begin{macrocode}
+\NewDescribeCommand\missing{%
+ \XD@grab@marg\XD@grab@harmless@cs
+}{2}{%
+ \GenericDescribePrint{\small Not in \texttt{#1}:
+ \texttt{\Bslash#2}}%
+ \MakeSortKey\@tempa{#2}{}%
+ \IndexEntry{%
+ \LevelSorted{Not in #1:}{Not in \texttt{#1}:}%
+ \LevelSorted{\@tempa}{\texttt{\Bslash#2}}%
+ }{usage}{\thepage}%
+}
+% \newcommand\missing[2]{%
+% \marginpar{%
+% \raggedleft\leavevmode\strut
+% Not in \texttt{#1}: \texttt{\string#2}\strut
+% \index{Not in #1\actualchar Not in \string\texttt{#1}\levelchar
+% \string#2\actualchar\string\verb\verbatimchar
+% \string#2\verbatimchar\encapchar usage}%
+% }%
+% }
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macrocode}
+\newcommand\ambiguity[1]{\leavevmode
+ \textbf{#1\index{Ambiguity\encapchar usage}}%
+ \marginpar{\raggedleft\textbf{\huge A}}%
+}
+\newcommand\question[1]{\leavevmode
+ \textbf{#1\index{Question\encapchar usage}}%
+ \marginpar{\raggedleft\textbf{\huge ?}}%
+}
+\AtBeginDocument{\catcode`\_=11}
+\def\MakePrivateLetters{\catcode`\_=11\makeatletter}
+
+% \end{macrocode}
+%
+% \multchanges{\cs{meta}}{1.30}{2000/01/02}{\cs{Meta} command (robust
+% wrapper around \package{doc}'s \cs{meta}) added. (LH)}
+% \multchanges{\cs{meta}}{1.31}{2000/02/10}{Command redefined so that
+% it is robust itself. \cs{Meta} removed. (LH)}
+% \multchanges{\cs{meta@font@select}}{1.33}{2000/02/26}{Macro added.
+% (LH)}
+% \multchanges{\cs{meta}}{1.35}{2000/03/25}{Don't make \cs{setlanguage}
+% whatsits in restricted horizontal mode. (LH)}
+% \multchanges{\cs{meta}}{2.00}{2000/07/06}{Command definition removed,
+% since the command is already defined by \package{doc} or
+% \package{xdoc}. (LH)}
+%
+% \begin{macro}{\cs}
+% This is \package{ltxdoc}'s normal |\cs|, but with a twist to make
+% |\meta| produce better results when used in the argument.
+% \changes{1.33}{2000/02/26}{Redefinition added. (LH)}
+% \changes{2.00}{2000/07/06}{Use \cs{MetaNormalfont} and
+% \cs{PrintVisibleChar}. (LH)}
+% \begin{macrocode}
+\DeclareRobustCommand\cs[1]{%
+ \texttt{\MetaNormalfont\PrintVisibleChar{`\\}#1}%
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{environment}{isyntax}
+% |isyntax| is for ``informal'' syntax specifications, such as
+% \begin{quote}
+% A \meta{varchar command} can be one of\\
+% \begin{quote}
+% |\vartop|\marg{glyph}\\
+% |\varmid|\marg{glyph}\\
+% |\varbot|\marg{glyph}\\
+% |\varrep|\marg{glyph}
+% \end{quote}
+% \end{quote}
+% The implementation is based on that of the \texttt{verse}
+% environment.It usually works just as fine with \texttt{quote}, but
+% \texttt{isyntax} handles breaking long lines better (and more
+% elegantly).
+% \changes{1.37}{2000/05/14}{Increased \cs{rightskip} stretchability
+% and added setting of \cs{linepenalty}. (LH)}
+% \begin{macrocode}
+\newenvironment{isyntax}{%
+ \let\\\@centercr
+ \list{}{%
+ \itemsep \z@
+ \itemindent -1.5em%
+ \listparindent \itemindent
+ \advance \leftmargin 1.5em%
+ }%
+ \advance \rightskip \z@\@plus0.7\linewidth \relax
+ \linepenalty=100\relax
+ \item\relax
+}{\endlist}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{obsoletemacro}
+% \changes{2.00}{2000/07/06}{Environment removed since obsolete. (LH)}
+% The \texttt{obsoletemacro} environment is for getting the right
+% heading on |\changes| comments that refer to macros which have been
+% removed. It only updates the |\saved@macroname|.
+% \begin{macrocode}
+% \newenvironment{obsoletemacro}{\begingroup
+% \catcode`\\12
+% \MakePrivateLetters
+% \obsolete@macro
+% }{}
+% \def\obsolete@macro#1{\endgroup
+% \edef\saved@macroname{\string#1}%
+% }
+% \end{macrocode}
+% \end{environment}
+%
+%
+% \section{\texttt{macro}-like environments}
+%
+% This subsection contains the definitions of a couple of environments
+% that, like \package{doc}'s \texttt{environment}, are for marking up the
+% document (what is defined and where). The definitions of these
+% environments are identical to that of \texttt{environment}, except
+% that the index entry texts are a little different.
+%
+% This section got a lot shorter in v\,2.00 thanks to \package{xdoc}.
+%
+% \begin{environment}{fiinteger}
+% \begin{environment}{fistring}
+% \multchanges{\notcs{\texttt{fiinteger} environment}^^A
+% \notcs{\texttt{fistring} environment}}{2.03}{2000/07/24}^^A
+% {Swapped last two arguments of \cs{NewMacroEnvironment} call
+% since \package{xdoc} changed.}
+% \begin{macrocode}
+\NewMacroEnvironment{fiinteger}{\XD@grab@harmless\relax}{1}%
+ {\MacroFont#1 \normalfont integer}%
+ {\XDMainIndex{\levelsorted{#1 I}{\texttt{#1} (integer)}}%
+ \XDMainIndex{\levelsame{integers:}\levelsorted{#1}{\texttt{#1}}}}%
+ {{#1}{\texttt{#1} integer}}{}
+% \end{macrocode}
+% \begin{macrocode}
+\NewMacroEnvironment{fistring}{\XD@grab@harmless\relax}{1}%
+ {\MacroFont#1 \normalfont string}%
+ {\XDMainIndex{\levelsorted{#1 S}{\texttt{#1} (string)}}%
+ \XDMainIndex{\levelsame{strings:}\levelsorted{#1}{\texttt{#1}}}}%
+ {{#1}{\texttt{#1} string}}{}
+% \end{macrocode}
+% \end{environment}\end{environment}
+%
+% \begin{environment}{PLproperty}
+% \changes{2.04}{2000/11/03}{Environment added. (LH)}
+% \changes{2.11}{2001/03/16}{Added \cs{DoNotIndexHarmless}. (LH)}
+% The \texttt{PLproperty} environment is for marking up definitions
+% of macros for interpreting properties in (V)PL files.
+% \begin{macrocode}
+\NewMacroEnvironment{PLproperty}{\XD@grab@harmless\relax}{1}%
+ {\MacroFont#1 \normalfont property}%
+ {\XDMainIndex{\levelsorted{#1}{\texttt{\Bslash#1}}}%
+ \XDMainIndex{%
+ \levelsame{PL properties:}\levelsorted{#1}{\texttt{#1}}%
+ }}%
+ {{#1}{\texttt{\Bslash#1}}}%
+ {\DoNotIndexHarmless{#1}}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{numPLproperty}
+% \changes{2.11}{2001/03/17}{Environment added. (LH)}
+% The \texttt{numPLproperty} environment is for marking up definitions
+% of macros that interpret a numbered family of (V)PL file properties,
+% such as \texttt{NUM} for \texttt{NUM1}, \texttt{NUM2}, and
+% \texttt{NUM3}. The syntax is
+% \begin{quote}
+% |\begin{numPLproperty}|\marg{base}\marg{num-list}
+% \end{quote}
+% In the above case the \meta{base} would be \texttt{NUM}. The
+% \meta{num-list} is a comma-separated list of digits (no existing
+% family of numbered properties have more than 5 members) that
+% specify what members of the family are handled by the macro being
+% defined.
+% \begin{macrocode}
+\NewMacroEnvironment{numPLproperty}{%
+ \XD@grab@harmless\relax\XD@grab@marg
+}{2}%
+ {\MacroFont#1$*$ \normalfont properties}%
+ {\XDMainIndex{\levelsorted{#1}{\texttt{\Bslash#1}}}%
+ \@for\@tempa:=#2\do{%
+ \XDMainIndex{%
+ \levelsame{PL properties:}%
+ \levelsorted{#1\@tempa}{\texttt{#1\@tempa}}%
+ }%
+ }}%
+ {{#1}{\texttt{\Bslash#1}}}%
+ {\DoNotIndexHarmless{#1}}
+% \end{macrocode}
+% \end{environment}
+%
+%
+% \multchanges{\notcs{\texttt{switch} environment}}{2.00}{2000/07/06}
+% {Removed since defined in \package{xdoc}. (LH)}
+%
+%
+% \section{Changes of change history formating}
+%
+% \multchanges{\cs{@changes}}{2.00}{2000/07/06}{Redefinition removed
+% since already done in \package{xdoc}. (LH)}
+%
+% \begin{macro}{\multchanges}
+% \changes{1.32}{2000/02/22}{\cs{flushleftspace} between \cs{cs}
+% items when typeset, instead of space. (LH)}
+% \changes{1.34}{2000/03/11}{\cs{notcs} marker allowed in
+% \meta{commands}. (LH)}
+% \changes{2.16}{2003/03/29}{Modified macro so that it is based on
+% \cs{changes@}. This means it is now compatible with \cs{uintver}.
+% (LH)}
+% The |\multchanges| commands is used to record a change to several
+% macros. Its syntax is
+% \begin{quote}
+% |\multchanges|\marg{commands}\marg{version}\marg{date}^^A
+% \marg{description}
+% \end{quote}
+% The three last arguments are as the arguments of |\changes|. The
+% \meta{commands} should be a nonempty sequence of commands, each
+% command either a |\cs| or a |\notcs|, and each command with one
+% argument. The change history entry generated by a
+% |\multchanges| will be for all the macros (or whatever) listed in
+% the first argument. |\cs| items will be typeset in typewriter font
+% with a leading backslash, whereas |\notcs| items will receive no
+% such special formatting.
+%
+% This method may have problems with active characters (since I've
+% ignored some things the standard |\changes| do to accomodate these),
+% but luckily \package{fontinst} hardly uses active characters
+% anyway. Furthermore I don't think the \package{doc} way of dealing
+% with them would be the right way here. Perhaps an active character
+% should rather be entered in the \meta{commands} argument as
+% |\active|\marg{code} or something?
+% \begin{macrocode}
+\newcommand*\multchanges[4]{%
+ \@bsphack
+ \begingroup
+ \begingroup
+ \def\cs##1{,\space##1}%
+ \let\notcs=\cs
+ \protected@xdef\@gtempa{%
+ \expandafter\@gobbletwo#1\@empty\@empty\@empty
+ }%
+ \edef\cs{,\noexpand\flushleftspace
+ \noexpand\protect
+ \expandafter\noexpand\csname cs \endcsname
+ }%
+ \def\notcs##1{,\noexpand\flushleftspace ##1}%
+ \protected@xdef\@gtempa{%
+ {\@gtempa}%
+ {\expandafter\@gobbletwo#1\@empty\@empty\@empty}%
+ }%
+ \endgroup
+ \let\saved@macroname=\@gtempa
+ \changes@{#2}{#3}{#4}%
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\flushleftspace}
+% The |\flushleftspace| command should typeset something which looks
+% like a space when not broken at, and as an \texttt{3em plus 1fil}
+% space when broken at. It also have to survive its use in
+% |\multchanges|.
+% \changes{1.32}{2000/02/22}{Command added. (LH)}
+% \changes{1.38}{2000/06/05}{Modified finite penalty. (LH)}
+% \begin{macrocode}
+\DeclareRobustCommand\flushleftspace{%
+ \nobreak \hskip 3em\@plus 1fil%
+ \penalty\@m \hskip -3em\@plus -1fil\ %
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\labelednumber}
+% This \package{xdoc} macro is redefined to put a ``filbreak''
+% space before every page number labelled with a macro name.
+% \changes{2.16}{2003/03/29}{Redefinition added. (LH)}
+% \begin{macrocode}
+\renewcommand*\labelednumber[2]{%
+ \hskip -1em\@plus -8em%
+ \vadjust{}\hskip 1em\@plus 8em%
+ #2\nolinebreak[2] (#1)%
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{environment}{theglossary}
+% \begin{macrocode}
+% \ifhave@multicol
+% \renewenvironment{theglossary}{%
+% \begin{multicols}\c@GlossaryColumns
+% [\glossary@prologue][\GlossaryMin]%
+% \GlossaryParms \def\item{\@idxitem v\,}\ignorespaces}%
+% {\end{multicols}}
+% \else
+% \renewenvironment{theglossary}{%
+% \@restonecoltrue\if@twocolumn\@restonecolfalse\fi
+% \columnseprule \z@ \columnsep 35\p@
+% \twocolumn[\glossary@prologue]%
+% \GlossaryParms \def\item{\@idxitem v\,}\ignorespaces}
+% {\if@restonecol\onecolumn\else\clearpage\fi}
+% \fi
+% \end{macrocode}
+%
+% If we want to use the glossary for some other information as well
+% (here I am thinking primarily on collecting |\missing| notices) then
+% perhaps we should insert the |v\,| in |\changes| instead. I would
+% guess the 64 character limit isn't at all as usual as it was when
+% the doc package documentation was written.
+%
+% \begin{macrocode}
+% \renewenvironment{theglossary}{%
+% % \penalty\z@\vskip\GlossaryMin\@plus\z@\@minus\GlossaryMin
+% % \penalty\z@\vskip-\GlossaryMin\@plus\z@\@minus-\GlossaryMin
+% \glossary@prologue
+% \GlossaryParms \let\item\@idxitem \ignorespaces
+% }{\par\bigskip}
+% \end{macrocode}
+% On second thoughts, the changes should be printed in one column.
+% They're usually very hard to linebreak in narrow columns.
+% \end{environment}
+%
+% \begin{macro}{\firstsubsubitem}
+% The idea with |\firstsubsubitem| is that it should be like |\efill|
+% |\subsubitem| if the paragraph is ended by a |\subsubitem| and like
+% \verb*"\ " if it isn't. This is achieved by grabbing the paragraph
+% into a macro and then prepend some suitable material to it when
+% typesetting.
+% \changes{1.36}{2000/04/10}{Grabbing paragraph as list of tokens,
+% rather than typeset text. (LH)}
+% \begin{macrocode}
+% \newcommand\firstsubsubitem{%
+% \begingroup
+% \let\par\@fssi@par
+% \let\subsubitem\@fssi@subsubitem
+% \protected@edef\@tempa{\iffalse}\fi
+% }
+% \end{macrocode}
+% \begin{macrocode}
+% \def\@fssi@subsubitem{%
+% \iffalse{\fi}%
+% \nobreak\hfill\vadjust{\nobreak}%
+% \penalty-\@M\vadjust{\penalty\@m}\nobreak\hskip -5pt\relax
+% \@tempa
+% \endgroup
+% \subsubitem
+% }
+% \end{macrocode}
+% \multchanges{\cs{@fssi@par}}{2000/06/05}{1.38}{Replaced simple space
+% by a more complicated sequence of penalties, vadjusts, and glue,
+% to make it more like \cs{flushleftspace}. (LH)}
+% \begin{macrocode}
+% \def\@fssi@par{%
+% \iffalse{\fi}%
+% \nobreak \hskip \z@ \@plus 0.4\linewidth
+% \vadjust{\nobreak}%
+% \penalty500\hskip \z@ \@plus -0.4\linewidth\hskip 5pt\relax
+% \penalty\z@\ \vadjust{\penalty\@m}%
+% \nobreak\hskip -5pt\relax
+% \@tempa
+% \endgroup
+% \par
+% }
+% \end{macrocode}
+% \end{macro}
+% \begin{macro}{\GlossaryParms}
+% \begin{macrocode}
+% \def\GlossaryParms{%
+% \parindent \z@
+% \columnsep 15pt
+% \parskip 0pt plus 1pt
+% \rightskip 15pt plus 15pt
+% \mathsurround \z@
+% \parfillskip=-\rightskip
+% \pretolerance=\tolerance
+% \small
+% \def\@idxitem{\par\hangindent 30pt v\,}%
+% \def\subitem{\par\hangindent 30pt\hspace*{15pt}}%
+% \def\subsubitem{\par\hangindent 30pt\hspace*{25pt}}%
+% \def\indexspace{\par\vspace{10pt plus 2pt minus 3pt}}%
+% }
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{instance}{docindex}{changes}
+% \changes{2.10}{2001/02/27}{Redefining it. (LH)}
+% \changes{2.12}{2001/03/25}{Modified in the same way as the
+% \package{docindex} default was with v\,1.00. (LH)}
+% \changes{2.15}{2003/02/19}{Rewrote this redefinition. Something
+% was wrong with the old one, but it seems to have worked to
+% start again from the definition in \package{docindex}. (LH)}
+% \changes{2.16}{2003/03/29}{Added an insertion of `\texttt{v}\cs{,}'
+% to the version number headings. The way it is done is however a
+% hack; I should define a separate instance explicitly instead.
+% (LH)}
+%
+% Typesetting the list of changes is annoyingly slow. It should be
+% examined what takes all that time, but I suspect it is the
+% paragraph breaking (the parameters involved are rather absurd). I
+% suspect that in particular the |\multchanges| complicates things
+% more than they really need to. --- LH, 2004/12/15.
+% \begin{macrocode}
+\setcounter{GlossaryColumns}{1}
+\@namedef{TP@I{}{docindex}{changes}}#1#2{%
+ \begingroup
+ \def\DI@indexitem@i##1##2##3##4{%
+ \UseInstance{indexitem}{fixed1}{##1}{##2}{v\,##3}{##4}%
+ }%
+ \@letinstance\DI@indexitem@ii{indexitem}{fixed-r2a-nocomma}%
+ \@letinstance\DI@indexitem@iii{indexitem}{aloneaccept3}%
+ \columnsep=10pt%
+ \parskip=0pt plus 1pt%
+ \def\DI@letter@skip{\z@skip}%
+ \let\DI@letter@format\@gobble
+ \def\+{-}%
+ \IfFileExists{\jobname.gls}{%
+ \ifnum \c@GlossaryColumns>\@ne
+ \begin{multicols}{\c@GlossaryColumns}[#1][\GlossaryMin]%
+ \else
+ \enough@room{\GlossaryMin}%
+ #1\par
+ \addvspace\multicolsep
+ \fi
+ \small
+ \makeatletter
+ \hbadness=\@M
+ \hfuzz=\maxdimen
+ \pretolerance=\m@ne
+ \tolerance=9999%
+ \emergencystretch=5em
+ \@nobreakfalse
+ \DI@ind@setup
+ \input{\jobname.gls}%
+ \DI@item@nojoin
+ \ifnum \c@GlossaryColumns>\@ne
+ \end{multicols}%
+ \else
+ \enough@room\postmulticols
+ \addvspace\multicolsep
+ \fi
+ \normalsize #2\par
+ }{\typeout{No file \jobname.gls.}}
+ \endgroup
+}
+% \@namedef{TP@I{}{docindex}{changes}}#1#2{%
+% \begingroup
+% \@letinstance\DI@indexitem@i{indexitem}{fixed1}%
+% \@letinstance\DI@indexitem@ii{indexitem}{fixed-r2a-nocomma}%
+% \@letinstance\DI@indexitem@iii{indexitem}{aloneaccept3}%
+% \columnsep=10pt%
+% \parskip=0pt plus 1pt%
+% \def\DI@letter@skip{\z@skip}%
+% \let\DI@letter@format\@gobble
+% % \ifnum \c@GlossaryColumns>\@ne
+% % \begin{multicols}{\c@GlossaryColumns}[#1][\GlossaryMin]%
+% % \else
+% \enough@room{\GlossaryMin}%
+% #1\par
+% \addvspace\multicolsep
+% % \fi
+% \small
+% \emergencystretch=5em
+% \@nobreakfalse
+% \DI@ind@setup
+% \@input@{\jobname.gls}%
+% \DI@item@nojoin
+% % \ifnum \c@GlossaryColumns>\@ne
+% % \end{multicols}%
+% % \else
+% \enough@room\postmulticols
+% \addvspace\multicolsep
+% % \fi
+% \normalsize #2\par
+% \endgroup
+% }
+% \end{macrocode}
+% \end{instance}
+%
+%
+%
+% \section{Hack for removing ``Marginpar moved'' warning messages}
+%
+% Check if the definition matches the known. To be on the safe
+% side, only the known definition will be changed.
+%
+% \begin{macrocode}
+\def\@tempa{\@next\@marbox\@currlist{\@cons\@freelist\@marbox
+ \@cons\@freelist\@currbox}\@latexbug\@tempcnta\@ne
+ \if@twocolumn
+ \if@firstcolumn \@tempcnta\m@ne \fi
+ \else
+ \if@mparswitch
+ \ifodd\c@page \else\@tempcnta\m@ne \fi
+ \fi
+ \if@reversemargin \@tempcnta -\@tempcnta \fi
+ \fi
+ \ifnum\@tempcnta <\z@ \global\setbox\@marbox\box\@currbox \fi
+ \@tempdima\@mparbottom
+ \advance\@tempdima -\@pageht
+ \advance\@tempdima\ht\@marbox
+ \ifdim\@tempdima >\z@
+ \@latex@warning@no@line {Marginpar on page \thepage\space moved}%
+ \else
+ \@tempdima\z@
+ \fi
+ \global\@mparbottom\@pageht
+ \global\advance\@mparbottom\@tempdima
+ \global\advance\@mparbottom\dp\@marbox
+ \global\advance\@mparbottom\marginparpush
+ \advance\@tempdima -\ht\@marbox
+ \global\setbox \@marbox
+ \vbox {\vskip \@tempdima
+ \box \@marbox}%
+ \global \ht\@marbox \z@
+ \global \dp\@marbox \z@
+ \kern -\@pagedp
+ \nointerlineskip
+ \hb@xt@\columnwidth
+ {\ifnum \@tempcnta >\z@
+ \hskip\columnwidth \hskip\marginparsep
+ \else
+ \hskip -\marginparsep \hskip -\marginparwidth
+ \fi
+ \box\@marbox \hss}%
+ \nointerlineskip
+ \hbox{\vrule \@height\z@ \@width\z@ \@depth\@pagedp}}
+\ifx \@addmarginpar\@tempa
+% \end{macrocode}
+% It matched.
+% \begin{macrocode}
+ \def\@addmarginpar{\@next\@marbox\@currlist{\@cons\@freelist\@marbox
+ \@cons\@freelist\@currbox}\@latexbug\@tempcnta\@ne
+ \if@twocolumn
+ \if@firstcolumn \@tempcnta\m@ne \fi
+ \else
+ \if@mparswitch
+ \ifodd\c@page \else\@tempcnta\m@ne \fi
+ \fi
+ \if@reversemargin \@tempcnta -\@tempcnta \fi
+ \fi
+ \ifnum\@tempcnta <\z@ \global\setbox\@marbox\box\@currbox \fi
+ \@tempdima\@mparbottom
+ \advance\@tempdima -\@pageht
+ \advance\@tempdima\ht\@marbox
+ \ifdim \@tempdima<\z@ \@tempdima\z@ \fi % Modification
+ \global\@mparbottom\@pageht
+ \global\advance\@mparbottom\@tempdima
+ \global\advance\@mparbottom\dp\@marbox
+ \global\advance\@mparbottom\marginparpush
+ \advance\@tempdima -\ht\@marbox
+ \global\setbox \@marbox
+ \vbox {\vskip \@tempdima
+ \box \@marbox}%
+ \global \ht\@marbox \z@
+ \global \dp\@marbox \z@
+ \kern -\@pagedp
+ \nointerlineskip
+ \hb@xt@\columnwidth
+ {\ifnum \@tempcnta >\z@
+ \hskip\columnwidth \hskip\marginparsep
+ \else
+ \hskip -\marginparsep \hskip -\marginparwidth
+ \fi
+ \box\@marbox \hss}%
+ \nointerlineskip
+ \hbox{\vrule \@height\z@ \@width\z@ \@depth\@pagedp}}
+\else
+% \end{macrocode}
+% It didn't match. Inform the user of what is to come.
+% \begin{macrocode}
+ \typeout{Expect a lot of ``Marginpar moved'' warnings.}
+\fi
+\let\@tempa=\relax
+% \end{macrocode}
+%
+%
+% \section{Things not to index}
+%
+% \begin{macrocode}
+\DoNotIndex{\def,\let,\else,\fi,\then,\x_cs,\x_relax}
+\DoNotIndex{\csname,\endcsname,\string,\the,\expandafter,\noexpand}
+\DoNotIndexBy{@@}\DoNotIndexBy{@}\DoNotIndexBy{_}\DoNotIndexBy{FD@}
+% \end{macrocode}
+%
+\endinput
+
diff --git a/fonts/utilities/fontinst/source/fisource.tex b/fonts/utilities/fontinst/source/fisource.tex
new file mode 100644
index 0000000000..39f29a7f17
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fisource.tex
@@ -0,0 +1,3037 @@
+%
+% Copyright 1998, 1999, 2000 the fontinst maintenance team and any
+% individual authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.0 or, at your option, any later version.
+%
+\documentclass{ltxdoc}
+\usepackage[dolayout,fileispart]{fisource}
+
+\usepackage{longtable}
+
+\RecordChanges
+\EnableCrossrefs
+
+\IndexPrologue{%
+ \section*{Index}%
+ \addcontentsline{toc}{section}{Index}%
+ \markboth{Index}{Index}%
+ Compound numbers (numbers with a hyphen) refer to a code line, and
+ the letter that is the first part of such a number specifies the
+ source file the code line is in, as explained by the file key below.
+ Simple numbers refer to pages. Numbers written in italics refer to
+ places where the corresponding entry is described, the ones
+ underlined to where it is defined, and the rest to where it is used.
+}
+\GlossaryPrologue{%
+ \section*{Change History}%
+ \addcontentsline{toc}{section}{Change History}%
+ \markboth{Change History}{Change History}%
+}
+
+
+\makeatletter
+\newcommand{\offindex}{\let\index\@gobble}
+
+\newcommand{\consumption}{%
+ \begingroup
+ \endlinechar=`\&\relax
+ \expandafter\endgroup\consumption@i
+}
+\def\consumption@i#1#2{%
+ \ifhmode{\parskip=\z@\@plus\p@\relax\par}\fi
+ Time elapsed: #1\,s\par
+ \tabskip=\leftmargin \advance \tabskip 1em\relax
+ \halign{&\hfil##\ \tabskip=\z@skip&##\hfil\tabskip=1em\cr
+ \omit\span \textbf{Stacks}&\omit\span \textbf{Others}\cr
+ \consumption@ii#2\@nil
+ }%
+}
+% #1 = number of strings used
+% #3 = string characters used
+% #5 = words of memory used
+% #7 = number of multiletter control sequences used
+% Other parameters are garbage.
+\def\consumption@ii#1 #2&#3 #4&#5 #6&#7 #8&#9&{%
+ \consumption@iii{{#1}{#3}}{{#5}{#7}}%
+}
+\def\consumption@iii#1#2#3&#4i,#5n,#6p,#7b,#8s#9\@nil{%
+ #4& input sources& \@secondoftwo#2& multiletter control
+ sequences\cr
+ #6& parameters& \@firstoftwo#1& strings\cr
+ #7& buffer characters& \@secondoftwo#1& string characters\cr
+ #8& saved values& \@firstoftwo#2& main memory words\cr
+}
+\makeatother
+
+\newenvironment{smalldes}{%
+ \list{}{%
+ \setlength\labelwidth{0pt}%
+ \setlength\itemindent{-\leftmargin}%
+ \setlength\listparindent{1em}%
+ \setlength\parsep{0pt}%
+ \setlength\itemsep{0pt plus 1pt}%
+ \setlength\topsep{\itemsep}%
+ \let\makelabel\descriptionlabel
+ }%
+}{\endlist}
+
+% \includeonly{}
+\iffalse
+\MakeShortVerb{\|}
+\fi
+
+\title{The \package{fontinst} utility}
+\author{Alan Jeffrey\and David Carlisle\and Sebastian Rahtz\and
+ Ulrik Vieth\and Lars Hellstr\"om}
+
+\begin{document}
+\maketitle
+\tableofcontents
+\clearpage
+
+\part*{About the \package{fontinst} package}
+\addcontentsline{toc}{part}{The \package{fontinst} documentation}
+
+This document implements and describes version~1.9 of
+\package{fontinst}.
+
+
+
+\section{Files}
+
+\subsection{Source files}
+
+The source for \package{fontinst} is currently split on the seven
+source files \texttt{fibasics.dtx} (basic \TeX\ initialisation and
+hackery), \texttt{ficommon.dtx} (commands for variables, integer
+expressions, and the like), \texttt{fimain.dtx} (actually making
+fonts), \texttt{fitrig.dtx} (trigonometry), \texttt{ficonv.dtx}
+(conversions between file formats, font transformations),
+\texttt{filtfam.dtx} (the \cs{latinfamily} command), and
+\texttt{fimapgen.dtx} (mapfile generation).
+
+
+\subsection{Generated files}
+
+By running the \package{docstrip} installation script
+\texttt{fontinst.ins}, the following files are generated:
+\begin{description}
+ \item[\texttt{fontinst.sty}] This is the executable file that
+ contains all the commands that set up the \package{fontinst}
+ utility for use.
+ \item[\texttt{xfntinst.sty}] This is a variant of
+ \texttt{fontinst.sty} in which the |\latin|\-|family| command
+ behaves differently with respect to from which fonts the digits
+ are picked (see below).
+ \item[\texttt{cfntinst.sty}] This is a variant of
+ \texttt{fontinst.sty} which supports the old way of selecting
+ boundarychar for fonts (i.e., by setting the integer
+ |boundarychar|). It requires a bit more memory than
+ \texttt{fontinst.sty} does.
+ \item[\texttt{fontinst.ini}] This file contains some very basic
+ initialization code. It is used in case \package{fontinst} is used
+ under ini\TeX\ without a preloaded format.
+ \item[\texttt{finstmsc.sty}] This file contains the routines for
+ automatic map file generation, which can now generate map files
+ for the \package{dvips} and \package{dvipdfm} drivers. The system
+ is extendable, so users interested in generating map files for
+ other drivers can extend the mapfile writer's capabilities by
+ adding code to their \texttt{finstmsc.rc} files. \emph{Contributions
+ of such code is welcome}. This file also contains some seldom-used
+ code (the ENC to ETX conversion) that has been broken off from
+ the main \package{fontinst} utility, as it almost always just sat
+ there and used up space for no good reason.
+ \item[\texttt{fontdoc.sty}] This file contains the \package{fontdoc}
+ package, which can be used to typeset encoding and metric files.
+ \item[\texttt{csc2x.tex}] This file contains the reglyphing commands
+ that set up the common caps-and-small-caps to expert names
+ conversion. See Subsections~\ref{Ssec:Des:Reglyph}
+ and~\ref{Ssec:Reglyph} for details.
+ \item[\texttt{csckrn2x.tex}] This file is a variant of
+ \texttt{csc2x.tex}, which doesn't copy the commands that actually
+ set glyphs.
+ \item[\texttt{osf2x.tex}] This file is a variant of
+ \texttt{csc2x.tex}, which only changes the names of digits.
+\end{description}
+
+\changes{1.914}{2000/05/14}{Generating \texttt{trig.sty} from
+ source. (LH)}
+
+
+\subsection{Modules}
+
+The source is split up on the following \package{docstrip} modules:
+\begin{description}
+ \item[\Module{boundaryCompability}, \texttt{fimain}]
+ Guards code that is needed for \package{fontinst} to be compatible
+ with the old interface for boundary ligatures and kerns.
+ \item[\Module{!boundaryCompability}, \texttt{fimain}]
+ Guards code that is used when \package{fontinst} is not to be
+ compatible with the old interface for boundary ligatures and kerns.
+ \item[\Module{debug}, \texttt{filtfam}]
+ Guards code in the |\latinfamily| section that writes \texttt{INFO>}
+ messages.
+ \item[\Module{doc}, \texttt{fibasics}, \texttt{ficommon},
+ \texttt{fimain}, and \texttt{fimapgen}]
+ Guards code that is to go into \texttt{fontdoc.sty}.
+ \item[\Module{driver}, all files]
+ Guards the driver code---the short piece of \LaTeX\ code in the
+ beginning of each file that makes it possible to typeset as a
+ \LaTeX\ document. \texttt{docstrip.ins} doesn't extract this
+ code, but it is possible to write a script that makes
+ \package{docstrip} extract this code if one wants to write a
+ modified driver. It's not usual, though.
+ \item[\Module{everyjob}, \texttt{fibasics}]
+ Guards the code setting |\everyjob| for fontinst formats (by
+ default not used).
+ \item[\Module{!glyphs}, \texttt{ficonv}]
+ Guards reglyphing setup code that is relevant when commands that
+ set glyphs are not to be copied.
+ \item[\Module{glyphs}, \texttt{ficonv}]
+ Guards reglyphing setup code that is relevant when commands that
+ set glyphs are to be copied.
+ \item[\Module{ini}, \texttt{fibasics}]
+ Guards the code for \texttt{fontinst.ini}.
+ \item[\Module{map}, \texttt{fimapgen}]
+ Guards the code for the automatic map file generation.
+ \item[\Module{misc}, \texttt{fibasics}, \texttt{fimain}, and
+ \texttt{ficonv}]
+ Guards code that is only to go into \texttt{finstmsc.sty}.
+ \item[\Module{!misc}, \texttt{fibasics}]
+ Guards code that is not to go into \texttt{finstmsc.sty}.
+ \item[\Module{obsolete}, \texttt{ficommon} and \texttt{fimain}]
+ Guards miscellaneous pieces of code that are considered obsolete.
+ \item[\Module{oldstyle}, \texttt{filtfam}]
+ Guards code in the |\latinfamily| section. The purpose of that
+ code is described in more detail in Section~\ref{Sec:NotesOnUsing}.
+ \item[\Module{oldTeX}, \texttt{fibasics}]
+ Guards code that copes with a bug in \TeX\ versions before 3.141.
+ \item[\Module{!oldTeX}, \texttt{fibasics}]
+ Guards normal code that wouldn't work satisfactory for
+ \TeX\ versions before 3.141 due to a bug in those \TeX s.
+ \item[\Module{pkg}, all files]
+ Guards code that is to go into \texttt{fontinst.sty} (and its
+ variants).
+ \item[\Module{pkg2}, \texttt{fibasics}]
+ A special variant of \Module{pkg} that is used for code that is
+ to end up at the very end of \texttt{fontinst.sty}.
+ \item[\Module{reglyphletters}, \texttt{ficonv}]
+ Guards code that sets up for changing lower case letter names to
+ corresponding smallcaps names. Used for \texttt{csc2x.tex} and
+ \texttt{csckrn2x.tex}.
+ \item[\Module{reglyphfigures}, \texttt{ficonv}]
+ Guards code that sets up for changing ordinary figure names to
+ corresponding \texttt{oldstyle} names. Used for
+ \texttt{osf2x.tex}, \texttt{csc2x.tex}, and
+ \texttt{csckrn2x.tex}.
+ \item[\Module{reglyph}, \texttt{ficonv}]
+ Guards code that is to go to the reglyphing setup files
+ \texttt{csc2x.tex} and \texttt{csckrn2x.tex}.
+ \item[\Module{textcomp}, \texttt{filtfam}]
+ Guards code in the |\latinfamily| section that generates text symbol
+ (\texttt{TS1}\slash ``text companion'') fonts.
+ \item[\Module{underconstruction}, \texttt{fimain}]
+ Guards some code that is ``under construction''.
+\end{description}
+
+
+
+\section{About previous \package{fontinst} releases}
+
+\subsection{Pre-\package{doc} fontinst releases}
+
+The following is a choice of some \package{fontinst} versions and some
+comments about them. The complete list of versions in the range
+v\,0.01--1.7 can be found in the file \texttt{CHANGES}.
+\begin{description}
+\item[v\,0.01]
+ was begun by Alan Jeffrey in February 1993. This was the
+ very first version recorded in the \texttt{CHANGES} file.
+%
+\item[v\,0.19]
+ was completed in April 1993 and presented at the TUG~'93
+ conference in July 1993. It is described in the proceedings
+ in \emph{TUGboat}~14\#3 and represents one of the earliest
+ release versions, in which the user interface was still
+ subject to change.
+%
+\item[v\,1.0]
+ was begun in August 1993 right after the conference and
+ represents the beginning of a complete re-write from scratch.
+%
+\item[v\,1.333]
+ was presented one year later at the TUG~'94 conference and
+ is described in the proceedings in \emph{TUGboat}~15\#3.
+ It uses a different user interface, which is largely the same
+ as in the present version, although the internals of the
+ implementation have subsequently changed quite a bit.
+%
+\item[v\,1.335]
+ was released in September 1994 and was the last ``official''
+ release version by Alan Jeffrey. Until the summer of 1998 this was
+ still the version to be found in the \texttt{fonts}\slash
+ \texttt{utilities}\slash\texttt{fontinst} directory on CTAN.
+ It is considered obsolete and should not be used any longer.
+%
+\item[v\,1.400]
+ was prepared in November 1994 and was the first version which
+ used |8r|-encoded raw fonts as a basis for virtual fonts.
+%
+\item[v\,1.500]
+ appeared on CTAN in \texttt{fonts}\slash\texttt{psfonts}\slash
+ \texttt{tools} in September~1995 together with Sebastian Rahtz's
+ Unix shell scripts to automate the installation. This version
+ included a completely revised implementation of |\latinfamily| and
+ added the |\installrawfont| command to install ligful raw fonts.
+%
+\item[v\,1.504]
+ appeared on CTAN in \texttt{fonts}\slash\texttt{psfonts}\slash
+ \texttt{tools} in January~1996. It added code to install (real or
+ faked) small caps fonts and to fake narrow fonts, if they don't
+ exist.
+%
+\item[v\,1.511]
+ was one of the last beta versions by Alan Jeffrey which dates back
+ to June~1996, but for some reason was never released. It uses
+ the encodings |9o| and~|9d| instead of |9t| and~|9e| to install
+ expertized oldstyle fonts, but this change never found its way
+ into subsequent ``unofficial'' releases until v\,1.8.
+%
+\item[v\,1.6]
+ appeared on CTAN in \texttt{fonts}\slash\texttt{psfonts}\slash
+ \texttt{tools} in February~1997 and was the first ``unofficial''
+ version of \package{fontinst} maintained by Sebastian Rahtz. It
+ contains only minor changes compared to v\,1.504, such as switching
+ to lowercase file names, searching for |.pl| files before |.afm|
+ files, and adding the \texttt{textcomp} installation to the
+ distribution.
+%
+\item[v\,1.6]
+ was re-issued on CTAN in September~1997, when the Unix shell
+ scripts were replaced by Perl scripts. The \package{fontinst}
+ package itself didn't change apart from minor changes of the
+ debugging messages.
+%
+\item[v\,1.7]
+ is the latest ``unofficial version'', which was released on CTAN
+ in May~1998. It includes some changes to the mapping between
+ \texttt{fontname} and \LaTeX{} weight codes proposed by Ulrik
+ Vieth, as well as some code to support the use of |8r|-encoded
+ |.afm| files generated by |ttf2afm|.
+%
+\end{description}
+%
+
+\subsection{About fontinst v\,1.8}
+
+Version~1.8 of the \package{fontinst} utility was the first to have
+been converted to \package{docstrip} format (this was made by Ulrik
+Vieth) and it was first released in June~1998. It is based on
+Sebastian Rahtz's ``unofficial'' \package{fontinst} releases v\,1.6
+and~1.7 as of February~1997 and May~1998, which, in turn, are based
+on Alan Jeffrey's versions v\,1.500 and~1.504 of September~1995
+and January~1996. In addition, version v\,1.8 also incorporated
+some code from Alan Jeffrey's last beta version, v\,1.511,
+which dates back to June~1996, but was never released to the
+general public for some reason.
+
+% It should be noted that all these versions differ significantly
+% from the previous ``official'' version v\,1.335 as of September~1994,
+% which was the only one to be found in the \texttt{fontinst} directory
+% on CTAN until the summer of 1998. Version v\,1.335 is now obsolete.
+
+Version~1.8 was agreed upon by the \package{fontinst} hacker community,
+as represented on the \package{fontinst} mailing list, as the new
+officially endorsed version, on which all further additions and
+enhancements can be based.
+
+
+\section{About this \package{fontinst} release}
+
+Versions 1.9xx of \package{fontinst} represent a more-or-less
+continuous evolution from 1999 to the present. Several improvements,
+the extents of which are perhaps not clearly represented in the version
+number increments, have been made in this series---sometimes as fixes
+to old bugs, but more often to introduce new features. The most
+important are:
+\begin{itemize}
+ \item The old multiple |\setkern| bug, which resulted in pointless
+ |KRN| instructions being written to (V)PL files have been fixed.
+ In addition, it is now possible to reset kerns (using
+ |\resetkern|) and unset kerns (using |\unsetkerns|,
+ |\noleftkerning|, |\norightkerning|, or |\noleftrightkerning|).
+ \item A bug which resulted in too few kerns being written to a font
+ if the same glyph is used in more than one slot (this occurs if
+ you make an all-caps font from an encoding definition file which
+ sets |\lc|, |\lctop|, and |\lclig| to the same to their
+ |\uc|\textellipsis\ counterparts) has been fixed. A consequence of
+ this fix is that you cannot access the number of the slot that
+ glyph \meta{glyph} has been assigned to as |\int|\marg{glyph}
+ (unless you are using \texttt{cfntinst.sty}), but there really is
+ no need for you to do so either.
+ \item There is now a proper interface for using left and right
+ boundaries which, in contrast to the old setting of the integer
+ \texttt{boundarychar}, can make use of the full generality of the
+ PL format. (The old interface is still available if you use
+ \texttt{cfntinst.sty}.)
+ \item \package{fontinst} can now interpret AFM files which contain
+ non-integer dimensions. There is also a user-level interface for
+ changing the formula according to which the italic corrections of
+ glyphs are computed.
+ \item The PL to MTX converter can now cope with the VPL-unique
+ property lists |VTITLE|, |MAP|, and |MAPFONT|, which means that it
+ can now convert VPL files as well. In addition to this, there are
+ a couple of minor bugfixes and improvements in the PL to MTX
+ conversion.
+ \item There is now a way of overriding the PL to MTX converter's
+ automatic choice of encoding definition file made based on the
+ |CODINGSCHEME| property of a PL file. The command |\generalpltomtx|
+ lets you select which encoding definition file you want to use, as
+ does the new |\fromplgivenetx| transformed font command.
+ \item Several \package{fontinst} commands that were previously
+ missing have been added to the \package{fontdoc} package. The
+ most significant are probably |\inputmtx| and |\inputetx|.
+ \item There is now a way of automatically changing the names of
+ glyphs in metric files generated from AFM files.
+ % See Subsection~\ref{Ssec:Reglyph} for further details.
+ \item The implementation of font metrics transformations, as done by
+ |\transformfont|, has been rewritten and \package{fontinst} now
+ handles uniform scaling internally; the driver only needs to do
+ $x$-scaling and slanting. This can result in different font metrics,
+ but we think only in that it comes out more like one would expect.
+ The user interface is the same.
+ \item There is now a new transformed font command |\fromany| which
+ searches for a font metric file in any of the four formats MTX,
+ PL, AFM, and VPL; converting it to MTX format and possibly
+ generating a PL as well if necessary. This command is also used by
+ |\installfont|, |\installrawfont|, and |\reglyphfont| to search
+ for font metric files, so these can now take VPL files as a
+ source for font metric data.
+ \item There is now a mechanism for generating the necessary map files
+ automatically. So far it knows how to generate map files for the
+ \package{dvips} and \package{dvipdfm} drivers, but the system can
+ easily be extended by adding code in the \texttt{finstmsc.rc} file.
+ \item There are two new commands |\setscaled|\-|rawglyph| and
+ |\setscaled|\-|notglyph| which generalize the |\setraw|\-|glyph|
+ and |\setnot|\-|glyph| commands. These commands are described in
+ Subsection~\ref{Ssec:Glyph-info}.
+ \item The routines for converting metrics to (V)PL format have
+ changed. As a result of this the metrics of fonts are likely to
+ change (slightly), but the conversion is now more accurate than it
+ used to be. A side-effect is that VPL files generated by
+ \package{fontinst} can now be used directly as a base for other
+ fonts (it used to be necessary to convert them to binary format and
+ back to get the metrics right).
+ \item \texttt{finstmsc.sty} now contains a new command which
+ generates a Postscript encoding (\texttt{.enc}) file from an ETX
+ file. The syntax of this command is
+ \begin{quote}
+ |\etxtoenc|\marg{etxfile}\marg{encfile}
+ \end{quote}
+ Usually you don't need to use this command, since the routines
+ which generate map files will call it when the encoding used in a
+ |\reencodefont| isn't known.
+ \item The new command
+ \begin{isyntax}
+ |\installfontas|\marg{font}\marg{encoding}\marg{family}%
+ \penalty0\marg{series}\penalty0\marg{shape}\penalty0\marg{size}
+ \end{isyntax}
+ adds an entry for \meta{font} with the given NFSS parameters to
+ the corresponding FD file.
+ \item The |\set|\textellipsis, |\reset|\textellipsis, and
+ |\unset|\textellipsis\ commands now behaves as one would expect
+ even when they occur between |\install|\-|fonts| and |\end|\-%
+ |install|\-|fonts|---the assignments they make are no longer
+ subject to the grouping around the metrics of individual fonts.
+ Assignments made by these commands when they occur in MTX and ETX
+ files \emph{are} however still subject to this grouping, so that
+ behaves as usual.
+ \item There are two control flow commands |\for| and |\foreach|
+ which repeatedly execute a given sequence of commands---just like
+ a normal programming language \texttt{for} loop. With |\for| the
+ loop variable is an integer that is incremented or decremented by
+ an amount that is specified in the beginning of the loop. With
+ |\foreach| the loop variable is a string which assumes all the
+ values given in a comma-separated list.
+ \item The command |\offcommand| turns a command `off', i.e., makes
+ it gobble its arguments and do nothing. The command |\oncommand|
+ turns a command back on, i.e., restores the original definition of
+ a command that had been turned off. Turning a command off or on
+ when it is already off or on respectively has no effect.
+ \item If you begin an item in the file-list argument (\#2) of
+ |\install|\-|font| or |\install|\-|raw|\-|font| with the command
+ |\metrics|, then that item (everything up till the next comma
+ that is not inside a group) will be interpreted as explicit metric
+ commands that are executed after the previous font was loaded and
+ before the next is. Thus you can do e.g.
+ \begin{quote}
+ |\installfont{|\textellipsis|}{a,\metrics\unsetint{xheight},b,|%
+ \textellipsis
+ \end{quote}
+ if you want font \texttt{a} to be loaded before font \texttt{b},
+ but want to use the \texttt{xheight} value of font \texttt{b},
+ and you don't want to bother writing an MTX file that simply
+ contains the command |\unsetint{xheight}|.
+ \item There is now a command |\fontinstcc| which switches to the
+ catcodes that are in force for most of the time that
+ \texttt{fontinst.sty} is read (|@| and |_| are letters, |~| is a
+ space, and spaces and newlines are ignored). This makes it simpler
+ to redefine internal control sequences. To switch back to the
+ normal catcodes, there is the |\normalcc| command. Neither
+ command has any arguments.
+ \item The |\Unicode| command may be used to specify what
+ ISO\,10646\slash Unicode character a slot corresponds to. See
+ page~\pageref{Unicode} for details.
+ \item The third arguments of the |\installfont| and
+ |\install|\-|raw|\-|font| commands can now be a comma-separated
+ list of ETX files.
+ \item File names in the second and third arguments of
+ |\install|\-|font| and |\install|\-|raw|\-|font| may now be
+ suffixed by zero or more \emph{modifier clauses} that can change
+ the interpretation of a file by e.g.~assigning special values to
+ some variables while the file is read in. This is described in
+ Subsection~\ref{Ssec:FontInstCmds} below.
+ \item The |\setfontdimen| command allows an ETX file to declare
+ which integer variables correspond to font dimensions in a (V)PL
+ file. This correspondence is used both when generating a ligful
+ (V)PL file and when a (V)PL file is converted to an MTX file.
+ \item \texttt{finstmsc.sty} now contains a new command which
+ generates a ToUnicode CMap file from an ETX file. The syntax of
+ this command is
+ \begin{quote}
+ |\etxtocmap|\marg{etxfile}\marg{cmapfile}
+ \end{quote}
+ \item Unicode equivalents of slots need no longer be single
+ characters. To specify a multiple-character equivalent of a
+ slot, use the |\charseq| command and place the individual
+ characters as |\Unicode| commands in its arguments. For a
+ \texttt{fi} slot, one would say
+ \begin{quote}
+ |\charseq{|\\
+ | \Unicode{0066}{LATIN SMALL LETTER F}|\\
+ | \Unicode{0069}{LATIN SMALL LETTER I}|\\
+ |}|
+ \end{quote}
+ \item
+ There are now three `actions' for files needed for a font:
+ |\download|, |\fulldownload|, and |\encodingdownload|;
+ corresponding to the prefixes |<|, |<<|, and |<[| respectively
+ in a \package{dvips} map file.
+ \item
+ There is a documented way of turning off default substitutions:
+ Make a |\substitutesilent| or |\substitutenoisy| with the
+ \meta{from} argument also as \meta{to}.
+ \item
+ When ETX files are generated using |\enctoetx| then the original
+ encoding names (as PS object and as file) are recorded and this
+ information is made available to the map file writer when
+ necessary.
+\end{itemize}
+
+
+\subsection{Metric packages}
+
+\package{fontinst} has traditionally come with a collection of MTX
+files that complement the MTX files generated from base font metrics,
+in that they build glyphs that may be missing from the base fonts or
+in some other way needs to be improved. The most well-known of these
+is the \texttt{latin.mtx} file; other examples include
+\texttt{textcomp.mtx}, \texttt{mathit.mtx}, and \texttt{latinsc.mtx}.
+A problem with these is however that they cannot produce optimal
+results for all fonts simply because there are irregular differences
+in how fonts are set up by the foundries. Most glyphs come out alright,
+but there are usually a few for which the parameters used are more or
+less wrong. Therefore most high quality font installations are made
+with modified versions of these files, where the parameters have been
+tuned to the specific font design.
+
+Modifying in particular \texttt{latin.mtx} is however not an entirely
+easy task, because this is a rather large file (with plenty of
+archaic pieces of code in curious places). Doing it once is no big
+problem, but if one has to do it several times (maybe because some
+errors are discovered in the original \texttt{latin.mtx}) then it is
+probably no fun anymore. Furthermore, if one has two or three
+modified copies of this file because one has made high quality
+installations of that many different fonts then even a trivial bugfix
+might start to feel like entirely too much work.
+
+If one has to make modifications then it is usually easier to deal
+with several small files (many of which can be used unchanged) than
+one big file. Thus it would be better if these big files were split up
+into several smaller ones.
+The main problem with splitting up something like \texttt{latin.mtx}
+is that there are some commands which are defined at the top and
+which are then used in almost all sections of the file. One must make
+certain that these commands are always loaded, which makes the metric
+files somewhat harder to use (especially if the one who tries to use
+them is not the one who wrote them).
+
+One strategy is to include all definitions needed for a metric file in
+it. This has the slight disadvantage that the commands will have to be
+defined several times. What is worse however, is that the command
+definitions will appear in several files, so if one finds a bug in one
+of them, one cannot simply correct this bug in one place. As the number
+of files can soon become quite large, correcting such bugs can become
+a boring procedure indeed.
+
+Another strategy is to put all the command definitions in one file
+and then explicitly include it in the \meta{file-list} argument of
+|\installfont|. This eliminates the repeated bug fixing problem, but
+requires the user to do something that the computer can actually do
+just as well.
+
+A third strategy is to put the command definitions in one or several
+files and then in each metric file the user explicitly mentions load
+the command definitions needed for that particular file. Metric
+packages uses an improved version of this strategy, since they also
+make it possible for fontinst to remember which packages (i.e., sets
+of command definitions) that have already been loaded, so that they
+are not unnecessarily loaded again. The \texttt{newlatin.mtx} file is
+an alternative to \texttt{latin.mtx} that implements this strategy.
+Most of the actual code is located in the following metric packages:
+\begin{longtable}{l p{0.7\linewidth}}
+ \texttt{ltcmds.mtx}& Defines some common commands used by the other
+ files.\\
+ \texttt{llbuild.mtx}& Builds the latin lower case alphabet
+ (unaccented letters are `unfakable', the rest are constructed if
+ not present in the base fonts).\\
+ \texttt{lubuild.mtx}& Builds the latin upper case alphabet.\\
+ \texttt{lsbuild.mtx}& Builds accented letters in the latin
+ smallcaps alphabet, but only if there are unaccented letters to
+ build them from in the base fonts.\\
+ \texttt{lsfake.mtx}& Fakes a latin smallcaps alphabet by shrinking
+ the upper case alphabet, but only if the glyph had not already
+ been manufactured.\\
+ \texttt{lsmisc.mtx}& Make some miscellaneous smallcaps glyphs
+ (mostly ``smallcaps f-ligatures'').\\
+ \texttt{ltpunct.mtx}& Makes digits, punctuation marks, and other
+ symbols (mostly by marking as ``unfakable'').
+\end{longtable}
+\noindent All of these are easy to use as components of equivalents
+of a modified \texttt{latin.mtx} files, and all dependencies of one
+package upon another are handled via explicit |\usemtxpackage|
+commands.
+
+For information on the syntax etcetera of commands related to metric
+packages, see Section~\ref{Sec:Metric files}.
+
+
+\subsection{Word boundary ligatures and kerns}
+
+One of the new features added in \TeX~3 was that of ligatures and
+kerns with word boundaries.\footnote{For purposes of ligatures and
+kerning, a `word' is a consecutive string of characters from a
+single font. These words thus typically include punctuation marks,
+unlike the `words' considered in hyphenation.}
+\package{fontinst} has had an interface
+for making such ligatures and kerns, but it has been completely
+redesigned in v\,1.9 and the old interface (setting the integer
+|boundarychar|) is no longer recognized by \package{fontinst}. Files
+which use the old interface can still be processed with
+\texttt{cfntinst.sty}, though.
+
+Before considering the new commands, it is suitable to define the
+concepts of proper glyph and pseudoglyph. A \emph{proper glyph} has
+been set using one of the commands |\setrawglyph|,
+|\set|\-|scaled|\-|raw|\-|glyph|, |\setglyph|, and
+|\reset|\-|glyph|. A pseudoglyph is any name used in the context of a
+glyph name which does not denote a proper glyph. If a pseudoglyph
+|g-not| was set using the |\setnotglyph| command, then
+|\ifisglyph{g-not}\then| will evaluate to true, but something can be
+a pseudoglyph even if an |\ifisglyph| test evaluates to false. The
+interesting point about pseudoglyphs when considering word boundaries
+however, is that a pseudoglyph can have ligatures and kerns.
+
+Kerns and ligatures at the left word boundary (beginning of word) are
+specified using the commands |\setleftboundary| and
+|\endsetleftboundary|, which are syntactically identical to
+|\setslot| and |\endsetslot| respectively. One important difference is
+however that the argument to |\setslot| must be a proper glyph, while
+the argument to |\setleftboundary| may be any glyph, hence a
+pseudoglyph will do just fine.
+
+|\ligature| commands between |\setleftboundary| and
+|\endsetleftboundary| will generate beginning of word ligatures. Kerns
+on the right of the glyph specified in |\setleftboundary| will become
+beginning of word kerns.
+
+Kerns and ligatures at the right word boundary (end of word) are
+trickier, due to the asymmetrical nature of the ligkern table in a PL
+file. What a font can do is to specify that the right word boundary,
+for purposes of kerning and ligatures, should be interpreted as
+character $n$. By including a kern or ligature with character $n$ on
+the right, that kern or ligature will be used at the end of a word,
+but it will also be used each time the next character is character
+$n$. Because of this, one usually wants the slot $n$, which the right
+word boundary is interpreted as being, to be empty whenever the
+encoding allows this.
+
+The command
+\begin{quote}
+ |\setrightboundary|\marg{glyph}
+\end{quote}
+will mark the current slot as used to denote the right word boundary,
+and leave the slot empty, increasing the current slot number by one
+just like a |\setslot| \textellipsis\ |\endsetslot| block does. Kerns on
+the left of \meta{glyph} will be end of word kerns and |\ligature|
+commands with \meta{glyph} as the second argument will be for the end
+of a word.
+
+The command
+\begin{quote}
+ |\makerightboundary|\marg{glyph}
+\end{quote}
+is similar to |\setrightboundary|, but it is a slot command which may
+only be used between a |\setslot| and the matching |\endsetslot|. Like
+|\setrightboundary|, it marks the current slot as used to denote the
+right word boundary, but the glyph specified in the enclosing |\setslot|
+will be written to that slot. Ligatures for the glyph specified by the
+|\setslot| and ligatures for the glyph specified by the
+|\makerightboundary| will both be for this single slot. Kerns on the
+right of the |\setslot| glyph and the |\makerightboundary| glyph will
+similarly both be for this single slot. The idea is that the |\setslot|
+glyph should be used when making a kern or ligature for that glyph,
+while the |\makerightboundary| glyph should be used when making a kern
+or ligature for the end of a word. \package{fontinst} will warn you if
+these two uses of the slot directly contradict each other.
+
+
+\subsection{Changing the names of glyphs}
+\label{Ssec:Des:Reglyph}
+
+Sometimes, primarily when making a virtual font from more than one raw
+font and two of the raw fonts contain different glyphs with the same
+name, it becomes necessary to change the names of some glyphs to make
+some sense out of it. The main source of this kind of trouble is the
+``caps and small caps'' (SC) and ``oldstyle figures'' (OsF) fonts
+within many commercial font families. The typical problem is that what
+is typographically different glyphs---such as the lowercase `a'
+(\texttt{a}, for \package{fontinst}) and the smallcaps `\textsc{a}'
+(\texttt{Asmall}, for \package{fontinst})---are given the same name by
+the foundry.
+
+One way to get round this is to say for example
+\begin{quote}
+ |\setglyph{Asmall} \glyph{a}{1000} \endsetglyph|\\
+ |\setleftrightkerning{Asmall}{a}{1000}|\\
+ |\unsetglyph{a}|\\
+ |\noleftrightkerning{a}|
+\end{quote}
+and continuing like that for all the duplicate glyph names. This is
+however a rather prolix method and if the number of glyphs is large
+then it is usually simpler to use the |\reglyphfont| command.
+
+To reglyph one or several fonts, one writes
+\begin{quote}
+ |\reglyphfonts|\\
+ \vadjust{}\quad \meta{reglyphing commands}\\
+ |\endreglyphfonts|
+\end{quote}
+There are two types of reglyphing commands: the |\reglyphfont|
+command, and the commands that modify what |\reglyphfont| will do to
+the fonts it operates on. The syntax of |\reglyphfont| is
+\begin{quote}
+ |\reglyphfont|\marg{destination font}\marg{source font}
+\end{quote}
+The \meta{source font} font here is the name (suffix not included, of
+course) of the font metric file one wants to change the glyph names in.
+This font metric file can be in any of the formats MTX, PL, AFM, and
+VPL, and it will be converted to MTX format if it isn't already in
+that format (this happens just as for files listed in the second
+argument of |\installfont|). \meta{destination font} (which must be
+different from \meta{source font}) will be taken as the name for a
+new \texttt{.mtx} file that will be generated. The destination font
+can differ from the source font only in two ways: the names of some
+glyphs in the source font might be changed, and some of the commands
+from the source font might not have been copied to the destination
+font. To what extent the fonts are different is determined by what
+modifying commands have been executed; when no modifying commands
+have been executed, the source and destination font are equal.
+
+The modifying reglyphing commands are
+\begin{quote}
+ |\renameglyph|\marg{to}\marg{from}\\
+ |\renameglyphweighted|\marg{to}\marg{from}\marg{weight}\\
+ |\killglyph|\marg{glyph}\\
+ |\killglyphweighted|\marg{glyph}\marg{weight}\\
+ |\offmtxcommand|\marg{command}\\
+ |\onmtxcommand|\marg{command}
+\end{quote}
+|\renameglyph| simply declares that occurrences of the glyph name
+\meta{from} should be replaced by the glyph name \meta{to}. To each
+glyph name is also assigned a \emph{weight}, which is used by a
+mechanism which conditions copying of commands from the source font to
+the destination font by the set of glyphs that command mentions. The
+details of this mechanism are however somewhat tricky, so those
+interested in the full generality should go to Subsection~\ref
+{Ssec:Reglyph}. Here it needs only be noted that if one applies
+|\killglyph| to a glyph name, then (under most circumstances) commands
+that refer to that glyph name will not be copied to the destination
+font.
+
+|\offmtxcommand| and |\onmtxcommand| also control whether commands are
+copied to the destination font, but they look at the actual command
+rather than the glyphs it refers to. For example, after the command
+\begin{quote}
+ |\offmtxcommand{\setkern}|
+\end{quote}
+no |\setkern| commands will be copied. By using |\offmtxcommand|, it
+is possible to achieve effects similar to those of the files
+\texttt{kernoff.mtx} and \texttt{glyphoff.mtx}---the difference is
+that with |\offmtxcommand|, it happens at an earlier stage of the font
+generation. As expected, |\onmtxcommand| undoes the effect of
+|\offmtxcommand|.
+
+A special rule pertains to the |\set|\-|raw|\-|glyph|,
+|\set|\-|not|\-|glyph|, |\set|\-|scaled|\-|raw|\-|glyph|, and
+|\set|\-|scaled|\-|not|\-|glyph| commands, since |\transformfont|
+doesn't care what something was in the source font when it generates
+the transformed font. To turn these commands off while reglyphing,
+you use |\offmtx|\-|command| on |\set|\-|scaled|\-|raw|\-|glyph|.
+
+The effects of modifying reglyphing commands are delimited by
+|\reglyphfonts| and |\endreglyphfonts|, which starts and ends a group
+respectively.
+
+As we expect the most common reglyphing operation will be to go from SC
+glyph names to expert glyph names, there is a file \texttt{csc2x.tex}
+in the \package{fontinst} distribution which contains the modifying
+reglyphing commands needed for setting up that conversion. Thus you
+can write for example
+\begin{quote}
+ |\reglyphfonts|\\
+ | \input csc2x|\\
+ | \reglyphfont{padrcx8r}{padrc8r}|\\
+ | \reglyphfont{padscx8r}{padsc8r}|\\
+ |\endreglyphfonts|
+\end{quote}
+to alter the glyph names in the SC fonts in the Adobe Garamond
+(\texttt{pad}) family.
+Note that the names of the destination fonts here really are rather
+arbitrary, since they will only exist as \texttt{.mtx} files, and
+thus only need to work within your local file system. In particular,
+all the |\setrawglyph| commands in the destination font files still
+refer to the source font, so it is that font which the drivers need
+to know about.
+
+
+\subsection{Making map file fragments}
+
+A \emph{map file fragment} is the lines\footnote{Not in general an
+entire map file, hence the word \emph{fragment}.} of a map file that
+the corresponding driver would need for handling some set of fonts.
+When told to, \package{fontinst} can (in a fairly automatic way) create
+the map file fragment which is needed for the set of raw fonts
+\package{fontinst} has (i) installed directly (using |\installrawfont|)
+or (ii) used as a base font for some installed virtual font (generated
+by |\installfont|). \package{fontinst} does not support the map file
+syntaxes of every existing driver, but the system is designed to be
+extendable and contributions that extend its capabilities are welcome.
+Nor can \package{fontinst} examine your \TeX\ system and
+determine every piece of information needed to make the correct map
+file fragments, but you can tell it roughly how your installation
+looks, it can make guesses which work most of the time, and you can
+specify most things explicitly if the guesses turn out to be wrong.
+Should the available options for configuring the process turn out to
+be inadequate for your needs, then please write to the
+\package{fontinst} mailing list about this---there is probably a way
+to improve the system so that your needs can be met.
+
+Now what does one have to do to use this map file fragment writer,
+then? First you need to tell \package{fontinst} to record the
+information the map file fragment writer needs. You do this by giving
+the command
+\begin{quote}
+ |\recordtransforms{whatever.tex}|
+\end{quote}
+at the beginning of the run. Here \texttt{whatever.tex} is the name of
+a file that will be created, so you can use some other name if you
+like. After that you do all the calls to |\transform|\-|font|,
+|\install|\-|font|, |\install|\-|raw|\-|font|, |\latin|\-|family|,
+etc.\ you need to make the fonts you want. When you're done, you give
+the command
+\begin{quote}
+ |\endrecordtransforms|
+\end{quote}
+and end the run (say |\bye|). The file \texttt{whatever.tex} will now
+contain the information about which fonts were used and what needs to
+be done with them.
+
+The second step is to actually run the map file fragment writer.
+Observe that it is located in the file \texttt{finstmsc.sty}, not
+\texttt{fontinst.sty}! The commands you need to give it can be so few
+that you can type them in at \TeX's \texttt{*} prompt, but if you are
+writing a command file then it should typically have the following
+structure (comments not necessary, of course):
+\begin{quote}
+ \begin{tabular}{ll}
+ |\input finstmsc.sty|& |%| Input command definitions\\
+ \meta{general settings} & |%| See below\\
+ |\adddriver|\marg{driver name}\marg{output file}&
+ |%| Open output file\\
+ |\input whatever.tex|& |%| Write to output file\\
+ |\donedrivers|& |%| Close output file(s), tidy up\\
+ |\bye|& |%| Quit
+ \end{tabular}
+\end{quote}
+The |\adddriver| command gives the order ``write map file entries for
+the \meta{driver name} DVI driver to the file \meta{output file}.'' The
+plan is that it should be possible to use the name of just about any
+major driver (\texttt{dvips}, \texttt{xdvi},
+\texttt{pdftex},\footnote{pdf\TeX\ can read
+the map files generated for \texttt{dvips}, but a separate driver is
+desirable because the formats are not completely identical.}
+\texttt{OzTeX}, etc.) here and get suitable map file entries for that
+driver as output, but for the moment only the \texttt{dvips} and
+\texttt{dvipdfm}\footnote{Whose support I made very much to illustrate
+that you \emph{don't} have to be a big and ancient driver like
+\texttt{dvips} to have supporting code put into \package{fontinst}.
+(The fact that I just happened to have printed out the documentation and
+that is was easy to read also helped, of course.) Note, however, that
+there won't be any support for a driver unless someone sits down and
+writes the code for it! Don't assume I will. /LH} drivers are supported.
+You may also use \texttt{debug} for \meta{driver name}; the entries in
+the file for that ``DVI driver'' simply contain all the available
+information about each font (hence it should come handy for debugging
+code writing entries for real drivers) in a format that should be easy
+to interpret for a human. It could be the right choice if you're going
+to write the map file manually.
+
+The file \texttt{whatever.tex} in the above example contains the
+commands (|\makemapentry| commands) that actually cause entries to be
+written to the output file. It also contains a number of |\storemapdata|
+commands---these describe how some given font was made. If some
+metric file you have used contains |\setrawglyph| commands that were
+not automatically generated by \package{fontinst}, then there might
+not be a |\storemapdata| for the font they refer to in
+\texttt{whatever.tex}, so you will have to include such a command
+yourself somewhere. This can for example be done in the \meta{general
+settings} part of the above example file. The syntax of the
+|\storemapdata| command is described in Subsection~\ref{Ssec:interface}.
+
+Another class of things that will typically appear in the
+\meta{general settings} part above is commands that will inform the
+routines actually writing output about your \TeX\ system, about the set
+of fonts you are using on this run, or about something else that might
+be useful. Some such commands are of a general nature and affect what
+assumptions \package{fontinst} will make in certain conditions when no
+specific information is available. For the moment there commands are:
+\begin{description}
+ \item[\cs{AssumeMetafont}] Assume all fonts with PL metrics are
+ bitmaps generated by Metafont, and therefore make no entries for
+ them.
+ \item[\cs{AssumeAMSBSYY}] Assume all fonts with PL metrics have their
+ \TeX\ names in all upper case as postscript names---just like the
+ Computer Modern fonts in the AMS\slash Blue~Sky\slash Y\&Y
+ distribution.
+ \item[\cs{AssumeBaKoMa}] Assume all fonts with PL metrics have their
+ \TeX\ names in all lower case as postscript names---just like the
+ Computer Modern fonts in the BaKoMa distribution.
+\end{description}
+Otherwise the default action of the routine for finding out the
+postscript name of a font simply is to observe that it hasn't got a clue
+about what the right value is when the metrics were taken from a PL
+file, and therefore it writes `\texttt{??????}' for the postscript name.
+\begin{description}
+ \item[\cs{AssumeLWFN}] Assume postscript fonts for which nothing
+ else has been specified are stored in files which are named
+ according to the \mbox{MacOS} scheme for
+ \texttt{LWFN}s.%\footnote{LaserWriter FoNt}
+\end{description}
+Otherwise the default action is to use the name of the AFM or PL from
+which the metrics was originally taken, and add the file suffix stored
+in the string \texttt{PSfontsuffix}. The default value of this string
+is \texttt{.pfa}, but it can be changed using |\resetstr|.
+
+If neither the default nor the LWFN scheme produce correct results
+then you may use the more specific \DescribeMacro\specifypsfont
+|\specifypsfont| command, which describes exactly which file (or files,
+if any) a given font is stored in. For syntax and examples of usage,
+see Subsubsection~\ref{Sssec:Config-interface}. (I consider the
+semantics of this command to still be under development, but in order
+to know how to develop it further I need to know in which cases it is
+insufficient.)
+
+Finally, there is the |\declarepsencoding| command which is used to
+link ETX files to postscript encodings. If no postscript encoding has
+been linked to a given ETX file then \package{fontinst} will
+automatically create a postscript encoding (\texttt{.enc}) file for
+that encoding, and use this file for all reencoding commands. Again,
+see Subsubsection~\ref{Sssec:Config-interface} for syntax and examples
+of usage. The \texttt{8r} encoding is predeclared, and it doesn't
+matter if an encoding is undeclared if you never use it to reencode
+fonts, but there is potentially a problem with not having declared
+encodings you have installed and use for reencoding, as you may then
+find yourself having two files with identical names that define
+encodings that do not have the same name (as far as postscript is
+concerned).
+
+
+\subsection{On verbatim, typewriter, and monowidth fonts}
+
+The verbatim, typewriter, and monowidth concepts are common sources
+of confusion for those who use \package{fontinst} to install fonts
+with \AllTeX;\footnote{Myself \emph{not} excepted. /LH} in particular
+there are many misconceptions about the relation between them. The
+official view (of which not much has actually been brought forward)
+is that these concepts are really about three quite different things.
+
+A font is a \emph{monowidth} (monospaced, fixed-pitch) font if all
+glyphs in it have exactly the same width. Some font formats make
+special provisions for such fonts; the most notable example is the
+AFM format, where a single \texttt{CharWidth} keyword specifies the
+width for all glyphs in the font. \package{fontinst} responds to this
+by including the command
+\begin{quote}
+ |\setint{monowidth}{1}|
+\end{quote}
+in the MTX file generated from an AFM, but that is everything that is
+hard-wired into the program. That a font is monowidth is however
+something that one should take note of when installing it for \TeX,
+as it means many of the glyphs in it have such a strange appearance
+that they are (pretty much) useless. The \texttt{endash} is for
+example usually only half as long as the \texttt{hyphen} and the
+letters in ligature glyphs are only half as wide as normal letters.
+Many of the ETX and MTX files that come with \package{fontinst}
+contain special commands to avoid making use of such degenerate
+glyphs.
+
+That a font is a \emph{typewriter} font really only means that it has
+a typewriterish look about it. The two most familiar typewriter fonts
+are probably Computer Modern Typewriter (\texttt{cmtt}) and Courier.
+Both of these fonts are monowidth, but there is no absolute rule about
+this. One of the standard \TeX\ fonts is for example Computer Modern
+Variable-width Typewriter (\texttt{cmvtt}), which is not a monowidth
+font, as Figure~\ref{Fig:TTvsVTT} shows.
+\begin{figure}
+ \begin{tabular}{ll}
+ \texttt{cmtt}:& \fontfamily{cmtt}\selectfont
+ The quick brown fox jumps over the lazy dog.\\
+ \texttt{cmvtt}:& \fontfamily{cmvtt}\selectfont
+ The quick brown fox jumps over the lazy dog.
+ \end{tabular}
+ \caption{Two typewriter fonts}
+ \label{Fig:TTvsVTT}
+\end{figure}
+
+The verbatim concept has very little to do with fonts at all; in
+\LaTeX\ it is considered to be a property of the environment
+(\texttt{verbatim}, \texttt{macrocode}, etc.) rather than a property
+of the font. The connection there is with fonts is that the encoding
+of the font must contain visible ASCII (as defined in Appendix~C
+of \emph{The \TeX book}~\cite{TeXbook}) as a subset for the text to
+be rendered correctly. The \texttt{cmtt} family is the only one amongst
+the original Computer Modern fonts which meets this criterium and
+that is the primary grounds for the idea that these three concepts
+should be connected. Today that reason is at best a very weak one, as
+all \texttt{T1}-encoded fonts also meet the criterium of containing
+visible ASCII as a subset.
+
+A circumstance which has probably added to the confusion is that
+\texttt{OT1} is usually claimed to be an encoding. In reality the
+Computer Modern fonts that are declared in \LaTeX\ as being
+\texttt{OT1} display as many as five different encodings, as shown in
+Table~\ref{Tab:OT1-fonts}.
+\begin{table}
+ \begin{tabular}{lccc}
+ & \texttt{TEX TEXT}&
+ \begin{tabular}[b]{c}\texttt{TEX TEXT WITHOUT}\\
+ \texttt{F-LIGATURES}\end{tabular}&
+ \texttt{TEX TYPEWRITER TEXT}\\
+ \noalign{\medskip}
+ non-italic&
+ \begin{tabular}{l}
+ \texttt{cmb10}\\
+ \texttt{cmbx5}--\texttt{12}\\
+ \texttt{cmbxsl10}\\
+ \texttt{cmdunh10}\\
+ \texttt{cmff10}\\
+ \texttt{cmfib8}\\
+ \texttt{cmr6}--\texttt{17}\\
+ \texttt{cmsl8}--\texttt{12}\\
+ \texttt{cmss8}--\texttt{17}\\
+ \texttt{cmssbx10}\\
+ \texttt{cmssdc10}\\
+ \texttt{cmssi8}--\texttt{17}\\
+ \texttt{cmssq8}\\
+ \texttt{cmssqi8}\\
+ \texttt{cmvtt10}
+ \end{tabular}&
+ \begin{tabular}{l}
+ \texttt{cmcsc8}--\texttt{10}\\
+ \texttt{cmr5}
+ \end{tabular}&
+ \begin{tabular}{l}
+ \texttt{cmsltt10}\\
+ \texttt{cmtcsc10}\\
+ \texttt{cmtt8}--\texttt{12}
+ \end{tabular}\\
+ \noalign{\medskip}
+ italic&
+ \begin{tabular}{l}
+ \texttt{cmbxti10}\\
+ \texttt{cmfi10}\\
+ \texttt{cmti7}--\texttt{12}\\
+ \texttt{cmu10}
+ \end{tabular}&&
+ \begin{tabular}{l}
+ \texttt{cmitt10}
+ \end{tabular}
+ \end{tabular}
+ \caption{``\texttt{OT1}-encoded'' Computer Modern fonts, collected
+ according to the actual font encoding}
+ \label{Tab:OT1-fonts}
+\end{table}
+Since most monowidth fonts are only used for setting verbatim text,
+there is some code in \texttt{ot1.etx} which automatically chooses a
+\texttt{TEX TYPEWRITER TEXT} encoding for the font when the
+\texttt{monowidth} integer is set. The only reason for this is the
+guess that this is what the user wanted.
+
+
+\subsection{Tuning accent positions---an application of loops}
+
+The accent placements made by \texttt{latin.mtx} certainly aren't
+perfect for all fonts, and the only way to find out where they should
+be put is through trying in text the accented letters you get for a
+couple of values for the position parameter and deciding which one
+works best. Since to try one parameter value you need to (i) edit it
+into an MTX file, (ii) run \package{fontinst}, (iii) run
+\package{VPtoVF}, (iv) run \TeX\ on some test text, and (v) print that
+text, trying one parameter value can take annoyingly much time.
+Repeating the same procedure ten times to test ten values is not
+something one does without being bored (unless one scripts it, of
+course), but it is possible to try ten parameter values in a single
+virtual font, and without doing very much typing.
+
+Say you're not too happy with how \texttt{latin.mtx} positions the
+accent in the \texttt{ohungarumlaut} glyph:
+\begin{quote}
+ |\setglyph{ohungarumlaut}|\\
+ | \topaccent{o}{hungarumlaut}{500}|\\
+ |\endsetglyph|
+\end{quote}
+The |500| is the horizontal position (in thousandths of the width of
+the \texttt{o}) that the center of \texttt{hungarumlaut} in the glyph
+constructed will have, so that is the position parameter value that
+you want to change. Create an MTX file containing the code
+\begin{quote}
+ |\for(pos){250}{750}{50}|\\
+ | \setglyph{ohungarumlaut\strint{pos}}|\\
+ | \topaccent{o}{hungarumlaut}{\int{pos}}|\\
+ | \endsetglyph|\\
+ | \setleftrightkerning{ohungarumlaut\strint{pos}}|\\
+ | {ohungarumlaut}{1000}|\\
+ |\endfor(pos)|
+\end{quote}
+This will set eleven glyphs \texttt{ohungarumlaut250},
+\texttt{ohungarumlaut300}, \texttt{ohungarumlaut350}, \textellipsis\,,
+\texttt{ohungarumlaut750}, each being an Hungarianly umlauted `o'
+(i.e., an `\H{o}') but all having that umlaut in slightly different
+positions. In order to put them in a font, you also need to make an
+encoding that contains them. Therefore create an ETX file which
+contains the code
+\begin{quote}
+ |\relax\encoding|\\
+ |\nextslot{"C0}|\\
+ |\for(pos){250}{750}{50}|\\
+ | \setslot{ohungarumlaut\strint{pos}}|\\
+ | \endsetslot|\\
+ |\endfor(pos)|\\
+ |\endencoding|
+\end{quote}
+The command for installing this experiment font would be something like
+\begin{isyntax}
+ |\installfont|\marg{some name}|{|\meta{the normal list of metrics}%
+ |,|\penalty0\meta{the new MTX}|}|\penalty0
+ |{ot1,|\meta{the new ETX}|}|\penalty0|{OT1}|\textellipsis
+\end{isyntax}
+The reason for including \texttt{ot1} in the third argument above is
+that you'll need letters other than `\H{o}' against which you can
+compare the experimental glyphs. It would not have been possible to
+use \texttt{t1} instead of \texttt{ot1} (even though that has more
+Hungarian letters) since that would set all slots in the font and
+leave none for these experimental \texttt{ohungarumlaut}s.
+
+It is even possible to use a loop for making the test text. The
+\LaTeX\ macros
+\begin{verbatim}
+\newcount\slotcount
+\newcommand\testtext[3]{%
+ \slotcount=#1\relax
+ \begin{description}%
+ \loop\item[\the\slotcount]#3%
+ \ifnum #2>\slotcount \advance \slotcount 1 \repeat
+ \end{description}%
+}
+\DeclareTextCompositeCommand{\H}{OT1}{o}{\char\slotcount}
+\end{verbatim}
+will let you write
+\begin{quote}
+ |\testtext|\marg{first}\marg{last}\marg{text}
+\end{quote}
+to get the text \meta{text} typeset once for each slot from
+\meta{first} to \meta{last} inclusive, with |\H{o}| ranging through the
+glyphs in this interval. Thus in this case
+|\testtext|\penalty\hyphenpenalty|{"C0}|\penalty\hyphenpenalty|{"CA}|%
+\penalty\hyphenpenalty|{Erd\H{o}s}| would be a trivial test.
+
+
+\subsection{Font installation commands}
+\label{Ssec:FontInstCmds}
+
+The |\installfont|, |\installrawfont|, and |\installfontas| commands
+have the respective syntaxes
+\begin{isyntax}
+ |\installfont|\marg{font-name}\marg{metrics}\marg{etx-list}\penalty0
+ \marg{encoding}\marg{family}\marg{series}\marg{shape}\marg{size}\\
+ |\installrawfont|\marg{font-name}\marg{metrics}\marg{etx-list}^^A
+ \penalty0
+ \marg{encoding}\marg{family}\marg{series}\marg{shape}\marg{size}\\
+ |\installfontas|\marg{font-name}\penalty0\marg{encoding}^^A
+ \marg{family}\marg{series}\marg{shape}\marg{size}
+\end{isyntax}
+The \meta{font-name} argument and the last five arguments are common
+to all these commands. The first argument is the name of a \TeX\ font
+to install. The last five arguments are the NFSS attributes under which
+that font will be declared to \LaTeX---encoding, family, series, shape,
+and size. It is worth observing that encoding names are usually in
+upper case, whereas the family, series, and shape are usually in lower
+case. The size argument is either a shorthand (declared using
+\DescribeMacro{\declaresize}|\declaresize|) for a particular font
+size (or range of font sizes), or an explicit list of font sizes or
+ranges of sizes, which is copied directly to the font declaration.
+The most common case is to let the size argument be empty, as that is
+declared as a shorthand for ``any size''.
+
+The |\installfontas| command does not itself create the font, it just
+makes a note that the specified font declaration should be written to
+the proper FD file at |\end|\-|install|\-|fonts|. The
+|\install|\-|font| and |\install|\-|raw|\-|font| commands do however
+produce the font, in the sense that they write a VPL and PL
+respectively file for the font. It depends solely on the \meta{metrics}
+and \meta{etx-list} arguments what this font will contain. Many
+features of these arguments are new with \package{fontinst} v\,1.9;
+therefore the complete syntaxes are described below.
+
+Both arguments are comma-separated lists of basically file names (not
+including an extension). The files listed in the \meta{metrics} are
+font metric files which together build up a \emph{glyph base}
+(definitions of glyphs and metrics related to one or several glyphs),
+whereas the files listed in the \meta{etx-list} are encoding definition
+files that select a subset of the glyph base for turning into a
+\TeX\ font. The font metrics can be in either of the four formats
+MTX, PL, AFM, and VPL, which are considered in that order. If the
+metrics are not originally in MTX format then they will be converted
+to this format (a new file will be created) before they are used.
+The encoding definitions must be in ETX format. The files actually
+read will have a suffix \texttt{.mtx}, \texttt{.pl}, \texttt{.afm},
+\texttt{.vpl}, or \texttt{.etx} appended to the name given, depending
+on which format is expected.
+
+Within each element of the comma-separated list, the actual file name
+is followed by zero or more \emph{modifier clause}s. A \meta{modifier
+clause} consists of a \emph{keyword} followed by some number (usually
+one) of \emph{arguments}, separated by spaces. The whole thing looks
+a lot like the \meta{rule specifications} of e.g.\ the |\vrule|
+command, but here the spaces are mandatory. The currently defined
+\meta{modifier clause}s are
+\begin{description}
+ \item[\mdseries\textvisiblespace\texttt{option}\textvisiblespace
+ \meta{string}]
+ Available for metric and encoding files. This adds \meta{string}
+ to the list of options for this file, which may affect what code
+ the file executes. The file can then test, using the |\ifoption|
+ command, whether a specific string is one of the options it was
+ given.
+ \item[\mdseries\textvisiblespace\texttt{scaled}\textvisiblespace
+ \meta{factor}]
+ Available for metric files. Causes the \texttt{rawscale} integer
+ variable to be set to the \meta{factor} (an integer expression)
+ while the file is being read. This scales glyphs and kerns that
+ are added to the glyph base by the \meta{factor}.
+ \item[\mdseries\textvisiblespace\texttt{suffix}\textvisiblespace
+ \meta{suffix}]
+ Available for metric files. Causes \meta{suffix} to be appended
+ to every glyph name appearing in a glyph or kern that file adds
+ to the glyph base. Thus ``\texttt{suffix /2}'' effectively
+ changes a
+ \begin{quote}
+ |\setrawglyph{a}|\dots
+ \end{quote}
+ to a
+ \begin{quote}
+ |\setrawglyph{a/2}|\dots
+ \end{quote}
+ \item[\mdseries\textvisiblespace\texttt{encoding}\textvisiblespace
+ \meta{etx-name}]
+ Available for metric files, and forces \package{fontinst} to
+ only consider the PL and VPL formats for this font.
+ As these file formats do not contain glyph names, an ETX file
+ is used to assign glyph names to the slots in the font.
+ This ETX file is usually selected according to the
+ \texttt{CODINGSCHEME} property of the PL or VPL (using the
+ correspondances set up via the |\declare|\-|encoding| command),
+ but that information is not always as one would want it (there
+ are even fonts for which it is quite wrong). An \texttt{encoding}
+ clause bypasses this automatic mechanism, so that the file
+ \meta{etx-name}\texttt{.etx} is used instead.
+
+% % The following is no longer true as of v1.926:
+% \textbf{Note:} The first time that a file in PL or VPL format is
+% used in a \meta{metrics} argument, a corresponding MTX file is
+% generated. This means that if the same file reference is used
+% another time then the reference will be to the MTX file, not to
+% the original PL or VPL, and thus \texttt{encoding} clauses on
+% subsequent uses will have no effect. Each font only has one
+% encoding, so it usually makes no sense to switch the ETX file
+% used to interpret a font, but since MTX files are not
+% automatically deleted between runs there is a risk that this
+% takes away the intended effect of an \texttt{encoding} clause.
+
+ \item[\mdseries\textvisiblespace\texttt{mtxasetx}]
+ This is available for files in the \meta{etx-list}. The actual
+ function of a
+ \begin{quote}
+ \meta{file-name} \texttt{mtxasetx}
+ \end{quote}
+ item in the \meta{etx-list} is that the file
+ \meta{file-name}\texttt{.mtx} is inputted (\emph{not}
+ \meta{file-name}\texttt{.etx}) and that the correspondance
+ between glyph names and slot numbers set up in
+ |\set|\-|raw|\-|glyph| or |\set|\-|scaled|\-|raw|\-|glyph|
+ commands in this file is treated as if it had been set up by
+ |\setslot| commands in an ETX file. Provided the MTX file is
+ transformable, the glyph base will be unaffected.
+
+ The purpose of this feature is to simplify quick and dirty
+ installations of odd fonts for which no suitable ETX file is
+ available. This can be useful in early stages of the design of
+ a new font, but is inferior to installation using proper ETX
+ files since one for example cannot specify any ligatures in
+ MTX files.
+\end{description}
+Furthermore there is a special exception for the \meta{metrics}: if
+the first token in one of the list items is the control sequence
+|\metrics|, then the rest of that item is interpreted as explicit
+metric commands to execute.
+
+If the \meta{metrics} of two subsequent |\install|\-|font|
+or |\install|\-|raw|\-|font| commands are identical then the glyph
+bases will be identical as well. This creates an opportunity for
+optimization, which \package{fontinst} makes use of by caching glyph
+bases from one installation command to the next so that the glyph
+base does not have to be rebuilt in these cases. A side-effect of
+this caching is that local assignments made between two font
+installation commands are cleared out with the glyph base, but
+|\setint| and similar \package{fontinst} commands make global
+assignments when used in such positions.
+
+Some examples might be in order. The first is an adaptation of an
+installation command from \texttt{mfnt-0.59}~\cite{mfnt} by
+Matthias Clasen and Ulrik Vieth: the installation command for the
+8-bit math font \texttt{xma1000} (which can be thought of as being
+to \texttt{cmmi10} sort of as \texttt{ecrm1000} is to \texttt{cmr10}).
+The first three \texttt{encoding} clauses are more fine-tuning---without
+them, a few glyphs would get incorrect names---but the last two are
+quite essential, as the \texttt{msam10} and \texttt{msbm10} fonts
+incorrectly claim to have the coding scheme \texttt{TEX MATH
+SYMBOLS}.
+\begin{verbatim}
+ \installfont{xma1000}{%
+ yma1000 encoding mcin,%
+ cmr10 encoding ot1upright,%
+ cmmi10,%
+ cmsy10 encoding omscal,%
+ msam10 encoding msam,%
+ msbm10 encoding msbm,%
+ mccmhax,mccmkern,mcmissing,%
+ cmsy10-base,cmsy10-extra%
+ }{mc}{MC}{cm}{m}{n}{<10->}
+\end{verbatim}
+Also note the explicit \LaTeX\ size specification for the range
+``10\,pt and up''.
+
+The second example makes use of a \texttt{suffix} clause to combine
+the letters from one font with the digits from another.
+\begin{verbatim}
+ \installfont{msbrj8t}{msbr8r,msbrc8r suffix /2,latin}{digit2,t1}
+ {T1}{msbj}{m}{n}{}
+\end{verbatim}
+In this case, the glyph base contains the glyphs of Monotype Sabon
+(SabonMT)---under names such as \texttt{A} for `A', \texttt{a} for
+`a', and \texttt{one} for a lining digit one---as well as the
+glyphs of Monotype Sabon Small Caps and Oldstyle Figures
+(SabonMT-SCOSF)---under names such as \texttt{A/2} for `A',
+\texttt{a/2} for `\textsc{a}', and \texttt{one/2} for a hanging
+digit one. The \texttt{digit2.etx} file simply makes the definition
+\begin{verbatim}
+ \setcommand\digit#1{#1/2}
+\end{verbatim}
+which causes \texttt{t1.etx} to put \texttt{zero/2} in slot 48 (digit
+zero), \texttt{one/2} in slot 49 etc., instead of as it normally
+would \texttt{zero} in slot 48, \texttt{one} in slot 49 and so on.
+The net effect is that the digits in the generated \texttt{msbrj8t}
+is from \texttt{msbrc8r} (SabonMT-SCOSF) but everything else is from
+\texttt{msbr8r} (SabonMT).
+
+The third example makes use of an \texttt{mtxasetx} clause to install
+(with its default encoding) a font for which creating an appropriate
+ETX file seems not worth the trouble.
+\begin{verbatim}
+ \installrawfont{psyr}{psyr,\metrics
+ \setint{xheight}{\height{alpha}}
+ }{txtfdmns,psyr mtxasetx}{U}{psy}{m}{n}{}
+\end{verbatim}
+The effect of the second \texttt{psyr} is that \texttt{psyr.mtx} is
+read (in case there was no \texttt{psyr.mtx} then it is created from
+(hopefully) \texttt{psyr.afm}) and the information in it will form
+the glyph base. Because of the |\metrics| control sequence, the rest
+of that item will be interpreted as explicit metric commands
+modifying the glyph base, and thus the |\setint| command can provide
+a value for the \texttt{xheight} variable (there doesn't seem to be
+such a value in the AFM). Once the glyph base is completed, the
+|\install|\-|raw|\-|font| starts writing the file \texttt{psyr.pl}
+(that's for the first \texttt{psyr}). The encoding of that font will,
+because of the \texttt{psyr mtxasetx}, be the same as that used in
+\texttt{psyr.mtx}. Finally, the \texttt{txtfdmns} is for
+\texttt{txtfdmns.etx}, an ETX file which sets fontdimens 1--16 as for
+a \texttt{T1} encoded font but does not set any slots. Since
+\texttt{psyr.mtx} reinterpreted as an ETX file sets slots but no
+fontdimens, these complement each other nicely.
+
+
+
+\begingroup
+\renewcommand\thesubsection{\thesection.\ensuremath{\infty}}
+
+\subsection{Coming attractions}
+
+We\footnote{Well, perhaps it's just me. /LH} have some new features
+which we have pretty much sorted out how they should work and how they
+should be implemented, but didn't want to introduce in this version as
+the large modifications in core systems would require another
+pre-release version before the proper release. Instead these features
+will probably appear in the first pre-release of \package{fontinst}
+v\,2.0.
+
+
+\subsubsection{Bounding boxes}
+
+Han The Thanh has created an implementation of bounding box support
+for \package{fontinst}, and it is a modified form of that support
+that will make it into \package{fontinst} v\,2.0. One important
+characteristic of this implementation is that the dimensions of the
+bounding box are not bundled into the same data structure (the
+|\g-|\meta{glyph} macros) as the glyph's width, height, depth, and
+italic correction are, but stored in a separate data structure (the
+|\gb-|\meta{glyph} macros). A glyph doesn't need to have its bounding
+box set, it is simply a piece of information that \package{fontinst}
+will store if you tell it to and which you can later retrieve.
+
+The bounding box will be stored as coordinates of the sides in the
+normal AFM coordinate system. The commands for retrieving these
+coordinates will probably be
+\begin{center}
+ \begin{tabular}{ll}
+ \textbf{Command}& \textbf{Side}\\
+ |\bbtop|\marg{glyph}& top ($y$-coordinate)\\
+ |\bbbottom|\marg{glyph}& bottom ($y$-coordinate)\\
+ |\bbleft|\marg{glyph}& left ($x$-coordinate)\\
+ |\bbright|\marg{glyph}& right ($x$-coordinate)
+ \end{tabular}
+\end{center}
+In Thanh's implementation the command names are |\ury|, |\lly|,
+|\llx|, and |\urx| respectively instead, but I think the former are
+easier to remember. If no bounding box has been set for a glyph then
+the above commands will instead report the corresponding coordinate of
+the glyph's \TeX\ box (i.e.\ |\height|\marg{glyph},
+|\neg{\depth|\marg{glyph}|}|, |0|, and |\width|\marg{glyph}
+respectively).
+
+The command for setting the bounding box of a glyph will be
+\begin{quote}
+ |\setglyphbb|\marg{glyph}\marg{left}\marg{bottom}\marg{right}^^A
+ \marg{top}
+\end{quote}
+
+
+
+\endgroup
+
+
+\section{Notes on using \package{fontinst}}
+\label{Sec:NotesOnUsing}
+
+The primary purpose of \package{fontinst} is to simplify the
+installation of PostScript or TrueType text fonts.
+
+
+\subsection{General notes}
+
+Leaving aside unusual variants which require special attention such
+as alternate or swash fonts, almost all standard font families can
+be installed automatically using the |\latinfamily| command,
+optionally making use of the corresponding expert fonts as well.
+
+Depending on what kind of fonts you have and want to install,
+|\latinfamily| supports three different modes of operation:
+
+|\latinfamily|\marg{fam}|{}| installs a normal font family using
+|8a|-encoded standard fonts (reencoded to |8r|) and nothing else.
+It installs |.fd| files for the \LaTeX{} families \texttt{8r}\meta{fam},
+\texttt{OT1}/\meta{fam}, \texttt{T1}/\meta{fam} and
+\texttt{TS1}/\meta{fam}, and generates virtual fonts for the |7t|,
+|8t|, and |8c| encodings. This is the only option available for most
+typefaces which do not have an expert set.
+
+|\latinfamily{|\meta{fam}|x}{}| installs an expertized font family using
+|8a|-encoded standard fonts (reencoded to |8r|) and |8x|-encoded
+expert fonts. It installs |.fd| files for the \LaTeX{} families,
+\texttt{OT1}/\meta{fam}\texttt{x}, \texttt{T1}/\meta{fam}\texttt{x} and
+\texttt{TS1}/\meta{fam}\texttt{x}, and generates virtual fonts for the
+|9t|, |9e| and |9c| encodings.
+
+|\latinfamily{|\meta{fam}|j}{}| installs an expertized font family with
+oldstyle digits using |8a|-encoded standard fonts (reencoded to
+|8r|) and |8x|-encoded expert fonts. It installs |.fd| files for
+the \LaTeX{} families, |OT1|/\meta{fam}|j|, |T1|/\meta{fam}|j| and
+|TS1|/\meta{fam}|j|, and generates virtual fonts for the |9o|, |9d| and
+|9c| encodings. Since \texttt{TS1} has oldstyle digits by default, the
+|9c|-encoded fonts should be the same as in the previous case. Finally,
+|\latinfamily{|\meta{fam}|9}{}| is also supported as an alternative to
+|\latinfamily{|\meta{fam}|j}{}| for backwards compatibility.
+
+The whole installation process relies on certain assumptions about
+the symbol complement of Adobe's expert fonts. In particular, it is
+assumed that the expert fonts include the oldstyle digits and a
+complete set of small caps glyphs, which is an assumption that's not
+always satisfied for expert fonts by other suppliers. If these
+glyphs are not included in the expert fonts, the only way to get
+them is from real small caps fonts, but this requires some
+reshuffling of glyph names.
+
+To support such unusual cases, this source file contains some
+optional code embedded between \Module{*oldstyle} \dots\
+\Module{/oldstyle},
+which extends the behaviour of |\latinfamily| for expertized
+encodings with oldstyle digits. Instead of relying only on the
+glyphs of the |8r|-reencoded raw font and the |8x|-encoded expert
+font, this version also looks for corresponding OsF or SC\&OsF fonts
+and uses the default digits from those fonts as oldstyle digits.
+
+
+\subsection{Notes on small caps and oldstyle fonts}
+
+The |\latinfamily| command is supposed to do a reasonably good job
+of installing a complete font family based on all the |.afm| files
+it can find. If it doesn't find a suitable font shape, it is
+sometimes possible to fake it by default substitutions. However, in
+the case of small caps fonts, there are several options which may
+require some clarification.
+
+For the majority of typefaces, a font family typically consists only
+of of roman and italic fonts in several weights. Since real small
+caps fonts are not included, they have to be faked from the roman
+fonts, which is implemented by setting |\encoding_shape| to `|c|',
+so that different encoding files |OT1c.etx| or |T1c.etx| are used.
+Since these files call for glyph names such as `|Asmall|' which are
+not found in the roman font, the default substitutions in
+|latin.mtx| are eventually used to approximate fake small caps
+glyphs by scaling and letterspacing. The outcome is just an
+approximation for a small caps font, but it is better than nothing.
+
+For a small number of typefaces, the standard fonts are complemented
+by an expert collection, which usually includes two sets of fonts.
+First, for each standard font there is a corresponding expert font
+containing additional glyphs such as extra ligatures and symbols,
+oldstyle digits and small capital letters. For Adobe expert fonts
+this set is sufficient to build a complete small caps font from the
+standard and expert glyphs. Furthermore, the expert collection
+usually also contains a number of real small caps font corresponding
+to the roman fonts and some OsF fonts corresponding to the italic
+fonts. If these fonts are available, there are several options how
+to install small caps fonts.
+
+By default, |\latinfamily| first tries to find a real small caps
+font. If it is found, it is installed using the default encoding
+files and metric files, just like any roman or slanted font.
+However, once |\latinfamily| has taken this choice, it will fail to
+find a corresponding expert font, since it is actually looking for
+an expert font in small caps shape which doesn't exist. (In fact,
+it would be an error to substitute an expert font in normal shape.)
+The outcome will be a virtual font based only on glyphs from the
+real small caps raw font, which implies ending up with oldstyle
+digits as the default set of digits, but allows to inherit the
+kerning information of the real small caps font.
+
+Another option for an expertized installation would be to make the
+real small caps fonts unavailable, so that |\latinfamily| will
+attempt to fake a small caps font using glyphs from the standard and
+expert fonts in normal shape. This means that |\encoding_shape| is
+again set to `|c|', so that |OT1c.etx| and |T1c.etx| are used, but
+this time a glyph named `|Asmall|' does exist in the expert font and
+will be used instead of faked one generated by scaling. The outcome
+will be a font based on normal and small caps glyphs from the
+standard and expert fonts. The oldstyle digits will only be used if
+they are called for, otherwise the default digits from the roman
+font are used. The only drawback of this approach is that the
+kerning around small capital letters will be based on the scaled
+kern amounts of the capital letters rather than on the kern pairs
+from the real small caps font.
+
+Finally, the most promising approach of all these options would be
+to combine the glyphs from standard and expert fonts with kern pairs
+from the real small caps fonts. The current version of |\latinfamily|
+does not implement this, but it would be a worthwhile approach, and
+advanced \package{fontinst} users are encouraged to attempt it. The
+file \texttt{csckrn2x.tex} (a variant of \texttt{csc2x.tex}, which is
+mentioned in Subsection~\ref{Ssec:Des:Reglyph}) should come in handy
+for this.
+
+
+\subsection{\package{fontinst} variables}
+
+The following is a list of the \package{fontinst} variables that are
+accessible for the user through the |\set|\textellipsis,
+|\reset|\textellipsis, |\unset|\textellipsis, etc.\ commands. You may
+of course set or use other variables in the MTX and ETX files you
+write yourself, as does for example the standard MTX file
+\texttt{latin.mtx}, but all variables that \package{fontinst} commands
+implicitly use or set are listed below.
+
+\begin{list}{}{%
+ \setlength\labelwidth{0pt}%
+ \setlength\itemindent{-\leftmargin}%
+ \setlength\parsep{0pt}
+ \def\makelabel#1{\hspace\labelsep \normalfont\ttfamily #1}%
+}
+ \item[acccapheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The height of accented full capitals.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[address] (string)
+ \begin{smalldes}
+ \item[Description] Snailmail address put in \BibTeX-style file
+ header of automatically generated ENC files. No
+ \texttt{address} field is written unless the \texttt{address}
+ string is set. Quotes are not automatically inserted around
+ the \texttt{address} string.
+ \item[Set by] ETX files.
+ \item[Used by] The ETX-to-ENC converter.
+ \end{smalldes}
+ \item[afm-name] (string)
+ \begin{smalldes}
+ \item[Description] Name of source font. Internal variable.
+ \item[Set by] |\from|\dots\ commands.
+ \item[Used by] The |\transform|\-|font|, |\install|\-|font|,
+ |\install|\-|raw|\-|font|, and |\reglyph|\-|font| commands.
+ \end{smalldes}
+ \item[ascender] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The ascender height of the font.
+ \item[Set by] MTX files. The AFM-to-MTX converter usually writes
+ |\setint| commands for this integer.
+ \item[Used by] Some MTX and ETX files.
+ \end{smalldes}
+ \item[author] (string)
+ \begin{smalldes}
+ \item[Description] Author name(s) put in \BibTeX-style file
+ header of automatically generated ENC files. See the macro
+ |\ref_to_sourcefile| for more details.
+ \item[Set by] ETX files.
+ \item[Used by] The ETX-to-ENC converter. When not set, the
+ value \texttt{"See file }\meta{etx name}\texttt{"} is used
+ instead.
+ \end{smalldes}
+ \item[\cs{autoinstallfamily}] (command)
+ \begin{smalldes}
+ \item[Description] Command called by the font installation
+ commands, as
+ \begin{quote}
+ |\autoinstallfamily|\marg{encoding}\marg{family}
+ \end{quote}
+ when they are asked to install a font with a combination of
+ \meta{encoding} and \meta{family} that has not been seen
+ before (there was no explicit |\installfamily|).
+ \item[Set by] Explicit commands. Defaults to calling
+ |\installfamily|.
+ \item[Used by] Font installation commands.
+ \end{smalldes}
+ \item[axisheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{22}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[baselineskip] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The font designer's recommendation for natural length of the
+ \TeX\ parameter |\baselineskip|.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[bigopspacing1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{9}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[bigopspacing2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{10}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[bigopspacing3] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{11}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[bigopspacing4] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{12}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[bigopspacing5] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{13}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[capheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The height of the font's full capitals.
+ \item[Set by] MTX files. The AFM-to-MTX converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some MTX and ETX files.
+ \end{smalldes}
+ \item[cmapname] (string)
+ \begin{smalldes}
+ \item[Description] The name given to the CMap generated from
+ an ETX file.
+ \item[Set by] ETX files.
+ \item[Used by] The ETX-to-CMap converter. When not set, the
+ value |fontinst-|\nolinebreak[1]\meta{cmap file name} is
+ used instead.
+ \end{smalldes}
+ \item[codingscheme] (string)
+ \begin{smalldes}
+ \item[Description] The codingscheme name.
+ \item[Set by] ETX files.
+ \item[Used by] The (V)PL writer. When not set, the
+ value \texttt{UNKNOWN} is used instead.
+ \end{smalldes}
+ \item[defaultrulethickness] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\xi\sb{8}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[delim1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{20}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[delim2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{21}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[denom1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{11}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[denom2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{12}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[descender] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The depth of lower case letters with descenders.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[descender_neg] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The vertical position of the descender line
+ of the font, i.e., the negative of the font's descender depth.
+ \item[Set by] MTX files. The AFM-to-MTX converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some MTX and ETX files.
+ \end{smalldes}
+ \item[designsize] (dimension)
+ \begin{smalldes}
+ \item[Description] The design size of the font.
+ \item[Set by] MTX files. The (V)PL-to-MTX converter usually writes
+ |\setdim| commands for this variable.
+ \item[Used by] The (V)PL writer. The design size defaults to
+ $10\,\mathrm{pt}$ if this variable is not set.
+ \item[Note] The value of this variable has no effect on how
+ the font is declared to \LaTeX.
+ \end{smalldes}
+ \item[designunits] (dimension denoting a real number)
+ \begin{smalldes}
+ \item[Description] The design size of a font expressed in the
+ design unit used in a (V)PL file.
+ \item[Set by] MTX files. The (V)PL-to-MTX converter usually writes
+ |\setdim| commands for this variable.
+ \item[Used by] Nothing. If this variable is set, but to any
+ value other than $1\,\mathrm{pt}$, then some metrics are most
+ likely wrong.
+ \end{smalldes}
+ \item[digitwidth] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The median width of the digits in the font.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[email] (string)
+ \begin{smalldes}
+ \item[Description] Email address put in \BibTeX-style file
+ header of automatically generated ENC files. See the macro
+ |\ref_to_sourcefile| for more details.
+ \item[Set by] ETX files.
+ \item[Used by] The ETX-to-ENC converter. When not set, the
+ value \texttt{"See file }\meta{etx name}\texttt{"} is used
+ instead.
+ \end{smalldes}
+ \item[encodingname] (string)
+ \begin{smalldes}
+ \item[Description] The name by which the encoding in question is
+ made known to a Postscript interpreter.
+ \item[Set by] ETX files.
+ \item[Used by] The ETX-to-ENC converter. When not set, the
+ value |fontinst-|\nolinebreak[1]|autoenc-|\nolinebreak[1]%
+ \meta{etx name} is used instead.
+ \end{smalldes}
+ \item[etx-name] (string)
+ \begin{smalldes}
+ \item[Description] Name of ETX file. Internal variable in
+ |\transform|\-|font|.
+ \item[Set by] The |\reencodefont| command.
+ \item[Used by] The |\mtxtomtx| command.
+ \end{smalldes}
+ \item[extraspace] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The natural width of extra interword glue at the end of a
+ sentence.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[fontdimen($n$)] (integer)
+ \begin{smalldes}
+ \item[Description] Family of semi-internal variables that store
+ the values to use for font dimension $n$. It is preferred
+ that the newer |\set|\-|font|\-|dimen| interface is used for
+ setting these values.
+ \item[Set by] ETX files.
+ \item[Used by] The (V)PL writer.
+ \end{smalldes}
+ \item[\cs{iftokeep}] (macro)
+ \begin{smalldes}
+ \item[Description] |\iftokeep|\,\#1\,|\then|, where \#1 will
+ be a \meta{number}, behaves like a switch and decides whether
+ a glyph is kept or not while reglyphing.
+ \item[Set by] Explicit commands. Defaults to
+ $$
+ \mbox{\cs{iftokeep}\,\#1\,\cs{then}} \mapsto
+ \mbox{\cs{ifnum}\,\texttt{-1<}\#1}
+ $$
+ \item[Used by] The |\reglyphfont| command.
+ \end{smalldes}
+ \item[interword] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The natural width of interword glue (spaces).
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[italicslant] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] The italic slant of a font.
+ \item[Set by] MTX files generated from AFM or (V)PL files. MTX
+ files generated by |\transformfont|. Locally in the AFM-to-MTX
+ converter for possible use in |\uprightitalcorr| or
+ |\slanteditalcorr|.
+ \item[Used by] MTX files (\texttt{latin.mtx} and the like). ETX
+ files (for determining \texttt{fontdimen(1)}).
+ \end{smalldes}
+ \item[killweight] (integer)
+ \begin{smalldes}
+ \item[Description] Weight for glyphs that are killed.
+ \item[Set by] Explicit commands. Defaults to $-10$ if not set.
+ \item[Used by] The |\kill|\-|glyph| command; indirectly
+ the |\reglyphfont| command.
+ \end{smalldes}
+ \item[letterspacing] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Extra width added to all glyphs of a font.
+ \item[Set by] ETX or MTX files.
+ \item[Used by] The (V)PL writer. Defaults to $0$ if not set.
+ \end{smalldes}
+ \item[maxdepth] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The maximal depth over all slots in the font.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[maxdepth_neg] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The negative of the maximal depth of a glyph in
+ the font.
+ \item[Set by] MTX files. The AFM-to-MTX converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[maxheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The maximal height of a glyph in the font.
+ \item[Set by] MTX files. The AFM-to-MTX converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[minimumkern] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Kerns whose size in absolute value is less
+ than or equal to this variable are ignored.
+ \item[Set by] \package{fontinst} command files or MTX files.
+ \item[Used by] The AFM-to-MTX converter and the (V)PL file
+ generator. When not set, the value $0$ is used instead.
+ \end{smalldes}
+ \item[monowidth] (flag integer)
+ \begin{smalldes}
+ \item[Description] Set if this font is monowidth, unset otherwise.
+ \item[Set by] MTX files. The AFM-to-MTX converter writes a
+ |\setint| command for this variable if the AFM specifies
+ \texttt{IsFixedPitch true}.
+ \item[Used by] Some MTX files (\texttt{latin.mtx} and the like),
+ ETX files.
+ \end{smalldes}
+ \item[num1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{8}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[num2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{9}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[num3] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{10}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[quad] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The quad width of the font, normally approximately equal to
+ the font size and\slash or the width of an `M'.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[PSfontsuffix] (string)
+ \begin{smalldes}
+ \item[Description] Suffix added to font names to form name of
+ file to download to include font.
+ \item[Set by] Explicit commands in \textsf{finstmsc} command
+ files. Defaults to `\texttt{.pfa}'.
+ \item[Used by] The map file fragments writer.
+ \end{smalldes}
+ \item[rawscale] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] Scaling factor applied to raw glyphs.
+ \item[Set by] The |\installfont| command (\texttt{scaled}
+ clauses in argument \#2). Unset for metric files listed
+ without a \texttt{scaled} clause.
+ \item[Used by] The |\set|\-|raw|\-|glyph|,
+ |\set|\-|not|\-|glyph|, |\set|\-|scaled|\-|raw|\-|glyph|,
+ |\set|\-|scaled|\-|not|\-|glyph|, |\set|\-|kern|, and
+ |\reset|\-|kern| commands.
+ \end{smalldes}
+ \item[renameweight] (integer)
+ \begin{smalldes}
+ \item[Description] Weight for glyphs that are renamed.
+ \item[Set by] Explicit commands. Defaults to $1$ if not set.
+ \item[Used by] The |\rename|\-|glyph| command; indirectly
+ the |\reglyphfont| command.
+ \end{smalldes}
+ \item[requireglyphs] (flag integer)
+ \begin{smalldes}
+ \item[Description] Set if warnings are to be generated for
+ glyphs listed in ETX files but not present in the glyph
+ base.
+ \item[Set by] Explicit commands. By defaults not set.
+ \item[Used by] The (V)PL file generator.
+ \end{smalldes}
+ \item[rightboundary] (string)
+ \begin{smalldes}
+ \item[Description] The name of a glyph with the property that
+ kerns on the left may be intended as right word boundary kerns.
+ \item[Set by] MTX files. The (V)PL-to-MTX converter can write
+ |\setstr| commands for this variable.
+ \item[Used by] Some MTX files.
+ \end{smalldes}
+ \item[shrinkword] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The (finite) shrink component of interword glue.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[slant-scale] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] Factor to slant by.
+ Internal variable in |\transform|\-|font|.
+ \item[Set by] The |\slant|\-|font|, |\xscale|\-|font|, and
+ |\scale|\-|font| commands.
+ \item[Used by] The |\mtxtomtx| command.
+ \end{smalldes}
+ \item[\cs{SlantAmount}] (macro expanding to an integer expression)
+ \begin{smalldes}
+ \item[Description] Slant factor used for faking oblique shape.
+ \item[Set by] Explicit commands. Defaults to \texttt{167}.
+ \item[Used by] The |\latinfamily| command.
+ \end{smalldes}
+ \item[\cs{slanteditalcorr}]
+ (macro expanding to an integer expression)
+ \begin{smalldes}
+ \item[Description] The integer expression used to calculate a
+ guess for the italic correction of glyphs in a font with
+ positive slant. It has the syntax
+ \begin{quote}
+ \cs{slanteditalcorr}\marg{width}\marg{left}\marg{right}^^A
+ \marg{bottom}\marg{top}
+ \end{quote}
+ where \meta{width} is the glyph's advance width, and the
+ remaining arguments are coordinates of sides of the glyph's
+ bounding box. The \texttt{italicslant} integer provides the
+ italic slant of the font.
+ \item[Set by] Explicit commands in \textsf{fontinst} command
+ files. Defaults to
+ $$
+ \max\{0, \mathit{right}-\mathit{width}\}.
+ $$
+ \item[Used by] The AFM-to-MTX converter.
+ \end{smalldes}
+ \item[stretchword] (integer denoting length)
+ \begin{smalldes}
+ \item[Description]
+ The (finite) stretch component of interword glue.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[sub1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{16}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[sub2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{17}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[subdrop] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{19}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[sup1] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{13}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[sup2] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{14}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[sup3] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{15}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[supdrop] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Math formula parameter $\sigma\sb{18}$.
+ \item[Set by] MTX files.
+ \item[Used by] Some ETX and MTX files.
+ \end{smalldes}
+ \item[TFMfileprefix] (string)
+ \begin{smalldes}
+ \item[Description] Prefix (typically a path) added to names of
+ TFM files.
+ \item[Set by] Explicit commands in \textsf{finstmsc} command
+ files. By default not set, which is equivalent to being empty.
+ \item[Used by] The \textsf{PLtoTF} ``map file fragments writer''.
+ \end{smalldes}
+ \item[underlinethickness] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The recommended thickness of an underlining
+ rule.
+ \item[Set by] MTX files. The AFM-to-MTX converter usually writes
+ |\setint| commands for this variable.
+ \item[Used by] Some MTX files (\texttt{latin.mtx} and the like).
+ \end{smalldes}
+ \item[\cs{uprightitalcorr}]
+ (macro expanding to an integer expression)
+ \begin{smalldes}
+ \item[Description] The integer expression used to calculate a
+ guess for the italic correction of glyphs in a font with
+ non-positive slant. It has the syntax
+ \begin{quote}
+ \cs{uprightitalcorr}\marg{width}\marg{left}\marg{right}^^A
+ \marg{bottom}\marg{top}
+ \end{quote}
+ where \meta{width} is the glyph's advance width, and the
+ remaining arguments are coordinates of sides of the glyph's
+ bounding box. The \texttt{italicslant} integer provides the
+ italic slant of the font.
+ \item[Set by] Explicit commands in \textsf{fontinst} command
+ files. Defaults to $0$.
+ \item[Used by] The AFM-to-MTX converter.
+ \end{smalldes}
+ \item[version] (string)
+ \begin{smalldes}
+ \item[Description] Version number put in \BibTeX-style file
+ header of automatically generated ENC files. See the macro
+ |\ref_to_sourcefile| for more details.
+ \item[Set by] ETX files.
+ \item[Used by] The ETX-to-ENC converter. When not set, the
+ value \texttt{"See file }\meta{etx name}\texttt{"} is used
+ instead.
+ \end{smalldes}
+ \item[verticalstem] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The dominant width of vertical stems
+ (usually the width of stems of lower case letters).
+ \item[Set by] MTX files. The AFM-to-MTX converter writes
+ |\setint| commands for this variable if the AFM file specifies
+ \texttt{StdVW}.
+ \item[Used by] Currently nothing.
+ \end{smalldes}
+ \item[\texttt{warningspecials}] (switch)
+ \begin{smalldes}
+ \item[Description] Controls whether |\glyphwarning| commands
+ will generate VPL \texttt{SPECIAL}s. Defaults to `true'.
+ \item[Set by] Explicit commands (|\warningspecialstrue| and
+ |\warningspecialsfalse|).
+ \item[Used by] The (V)PL file generator.
+ \end{smalldes}
+ \item[x-scale] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] Horizontal scaling factor.
+ Internal variable in |\transform|\-|font|.
+ \item[Set by] The |\xscale|\-|font| and |\scale|\-|font| commands.
+ \item[Used by] The |\mtxtomtx| command.
+ \end{smalldes}
+ \item[xheight] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] The x-height of the font.
+ \item[Set by] MTX files. The AFM-to-MTX and (V)PL-to-MTX
+ converters usually write |\setint| commands for this variable.
+ \item[Used by] MTX files, and ETX files (for determining
+ \texttt{fontdimen(5)}).
+ \end{smalldes}
+ \item[y-scale] (integer denoting factor)
+ \begin{smalldes}
+ \item[Description] Vertical scaling factor.
+ Internal variable in |\transform|\-|font|.
+ \item[Set by] The |\yscale|\-|font| and |\scale|\-|font| commands.
+ \item[Used by] The |\mtxtomtx| command.
+ \end{smalldes}
+ \item[\meta{\rmfamily glyph}-spacing] (integer denoting length)
+ \begin{smalldes}
+ \item[Description] Glyph-specific override for
+ \texttt{letterspacing}; extra width added to the glyph
+ \meta{glyph} as part of the process of writing a VPL
+ file.
+ \item[Set by] ETX or MTX files.
+ \item[Used by] The (V)PL writer. Defaults to $0$ if not set.
+ \end{smalldes}
+\end{list}
+Besides these, the |\latinfamily| command provides a whole range of
+parameters that are often used somewhat like variables. That subject
+does however deserve to be treated separately.
+
+
+\section{\package{fontdoc} package overview}
+
+The purpose of the \package{fontdoc} package is to support
+typesetting of \texttt{.etx} and \texttt{.mtx} files intended
+for use with \package{fontinst}.
+The typical format of these files looks something like this:
+\begin{quote}
+ |\relax|\\
+ |\documentclass[twocolumn]{article}|\\
+ |\usepackage{fontdoc}|\\[0.5\baselineskip]
+ |\begin{document}|\\
+ {}~~\textit{\LaTeX\ commands}\\
+ |\encoding| or |\metrics| \\
+ {}~~\textit{\package{fontinst} commands}\\
+ |\endencoding| or |\endmetrics|\\
+ {}~~\textit{\LaTeX\ commands}\\
+ |\end{document}|
+\end{quote}
+To make it work, \package{fontdoc} has to define all the user-level
+\package{fontinst} commands in terms of typesetting instructions. This
+goal is currently only partially achieved, but the percentage of
+\package{fontinst} commands covered by \package{fontdoc} is still
+fairly large, so it is our impression that problems with commands not
+covered occur only very rarely.
+
+
+\subsection{Some \package{fontdoc} commands that \package{fontinst}
+ doesn't know}
+
+Some of the commands defined by \package{fontdoc} are not defined by
+\package{fontinst} because they have no meaning in that context.
+Most of these commands are lower-level commands that are used in the
+implementations of commands common to \package{fontinst} and
+\package{fontdoc}, but a few are simply only meant to be used in the
+parts of ETX and MTX files that \package{fontinst} never executes.
+
+With v\,1.916 the mechanism for formatting integer expressions changed
+dramatically. The new base command to use is
+\DescribeMacro{\TypesetIntegerExpression}|\Typeset|\-|Integer|\-%
+|Expression|, which takes as its only argument the integer expression
+to format and typesets it. |\Typeset|\-|Integer|\-|Expression| expects
+to be used in math mode only. A similar command is
+\DescribeMacro{\TypesetStringExpression}|\Typeset|\-|String|\-%
+|Expression|, which takes a string expression as argument, formats,
+and typesets it. |\Typeset|\-|String|\-|Expression| can be used in any
+mode.
+
+The \DescribeMacro{\macroparameter}|\macroparameter| command is (in
+integer and string expressions) understood as a ``placeholder for a
+macro parameter''. This is primarily useful in comments that describe
+a user-defined macro; see \texttt{ltcmds.mtx} for examples.
+
+
+
+% \part*{Implementation}
+% \addcontentsline{toc}{part}{Implementation}
+
+\changes{1.800}{1998/06/22}{\texttt{fontinst.sty} and
+ \texttt{fontdoc.sty} now generated from \texttt{fontinst.dtx}. (UV)}
+\changes{1.900}{1999/02/05}{\texttt{fontinst.dtx} split into several
+ source files. (LH)}
+\changes{1.902}{1999/04/18}{Fixed some silly markup. (LH)}
+
+\DocInclude{fibasics}
+\DocInclude{ficommon}
+\DocInclude{fimain}
+\DocInclude{fitrig}
+\DocInclude{ficonv}
+\DocInclude{filtfam}
+\DocInclude{fimapgen}
+
+\PrintIndex
+\pagestyle{plain}\tracingmacros=2\tracingcommands=2
+\PrintChanges
+\tracingcommands=0\tracingmacros=0
+
+\clearpage
+\appendix
+\part*{Internal notes}
+\addcontentsline{toc}{part}{Internal notes}
+
+
+\section{Typographic treatment}
+
+\begin{itemize}
+ \item
+ I have been following \emph{The \LaTeX\ Companion} in that I have
+ set all names of packages and the like---\package{fontinst},
+ \package{fontdoc}, \package{trig}, \package{doc}, and
+ \package{docstrip} (I might have forgotten some)---in sans serif
+ type. Actually, I have defined a command |\package| in
+ \texttt{fisource.sty} (or is that \package{fisource}?) which does
+ this, so if we decide on some other formatting, we can just change
+ that. /LH
+ \item
+ It seems to me that there should indeed be some space between the
+ `v' and the digits in a version number when it is typeset, but I
+ also think a full space is too much, so I have been using thin
+ spaces. These are unbreakable and under \LaTeX\ you can simply use
+ |\,| to get one (while you are not in math mode, that is). /LH
+ \item
+ While I went through (some of) the code, I came across a few
+ inconsistencies. \ambiguity{I have marked them out like this%
+ \offindex}---some boldfaced text in a paragraph and a large A
+ in the margin. I defined a command |\ambiguity| for doing this. /LH
+ \item
+ There is also a similar command |\question| which is intended for
+ situations where there isn't really an error, but something seems
+ like it should be taken care of in some other way. \question{The
+ \cs{question} command puts a question mark in the margin.%
+ \offindex}
+ \item
+ I also noticed that there are several \package{fontinst} commands,
+ not all of which are new, which are not defined in \package{fontdoc}.
+ {\offindex\missing{doc}{\foo}}To mark out such things, I have
+ written things like the one shown in the margin by this paragraph.
+ I defined a command |\missing| for doing this. /LH
+\end{itemize}
+
+
+\section{Planning topics}
+
+This section lists items in the larger design of \package{fontinst}
+which need to be resolved in one way or another. Debates about these
+items on the fontinst mailing list are welcome.
+
+
+\subsection{Reorganisation of the source}
+
+At the moment, all the ideas suggested have been realized.
+% \begin{itemize}
+% \item
+% How about moving the first section of \texttt{fimain.dtx} to
+% \texttt{fibasics.dtx}? /LH
+% \item
+% How about extracting the code which has to do with file
+% conversions (Sections~\ref{Sec:Conv. input},
+% \ref{Sec:Font.trans}, and Subsection~\ref{Ssec:MTX->PL}) from
+% \texttt{fimain.dtx} and put it in a file of its own
+% (\texttt{ficonv.dtx}, say)? /LH
+% \end{itemize}
+
+
+\subsection{Files}
+
+Which files should be considered temporary and placed in the location
+specified with |\tempfileprefix|? Should files be explicitly be looked
+for at this location or should it be assumed that fontinst users
+include that location in their \TeX\ input file search path? In the
+former case, \emph{which} files should be looked for in that
+location? Should files be looked for in the temporary location before
+they are looked for without a specified location, or should it be the
+other way round?
+
+
+
+
+
+\section{Contributors}
+
+[The \package{fontinst} source has been pretty inconsistent in how
+people are credited for what they have done---some appear only as
+acronyms while others appear as rather striking e-mail addresses---so
+I thought it best that this is shaped up a bit. My suggestion is that
+we use names or acronyms in the source and move everything else here.
+I also thought it could be interesting with a short description of
+what each person has done and is doing, so I have started ever so
+slightly on something along those lines. Feel free to add things! /LH]
+
+\medskip
+
+The following people have contributed substantial amounts of code or
+documentation to \package{fontinst}. They are listed in strict
+alphabetical order.
+
+\begin{description}
+ \item[Thierry Bouche]
+ Thierry saw to that the \texttt{T1} encoded fonts got font
+ dimensions comparable to the \texttt{ec} fonts. Thierry is also
+ the author of several papers (published in the \textit{Cahiers
+ GUTenberg} and \textit{TUGboat}) which deal with non-trivial
+ applications of \package{fontinst}, such as creating metrics for
+ Adobe Minion Multiple Master fonts and developing a corresponding
+ math font setup.
+
+ E-mail: \texttt{Thierry.Bouche@ujf-grenoble.fr}
+
+ \item[Lars Hellstr\"om (LH)]
+ Lars is responsible for most of the things in v\,1.9 that were
+ not there in v\,1.8.
+
+ Lars is currently a member of the \package{fontinst}
+ maintenance team. He is also a Ph.D.\ in mathematics looking for
+ employment.
+
+ \item[Alan Jeffrey (ASAJ)]
+ Alan is the original author of \package{fontinst}. He is not
+ currently on the development team, but he is still managing the
+ \package{fontinst} mailing list.
+
+ E-mail (\package{fontinst} mailing list subscriptions):%
+ \nobreak\hfill\penalty0\hskip -2em plus -1fill\ \relax
+ \vadjust{}\nobreak\hskip 2em\relax
+ \texttt{fontinst-request@cogs.susx.ac.uk}.
+
+ \item[Constantin Kahn (CK)]
+ Constantin is one (Sebastian is the other) of the original coauthors
+ of the current |\latinfamily| command.
+ % \footnote{Am I right about this? It's a bit before my time,
+ % I've just read \texttt{CHANGES}. /LH}
+
+ \item[Rowland McDonnell]
+ Rowland rewrote Alan's old v\,1.5 documentation for
+ \package{fontinst} and updated it for v\,1.8.
+
+ \item[Sebastian Rahtz (SPQR)]
+ Sebastian is one (Constantin is the other) of the original coauthors
+ of the current |\latinfamily| command. He has also contributed
+ numerous ETX files and made the ``unofficial'' v\,1.6 and v\,1.7,
+ which included the first \package{fontinst} support for making
+ \texttt{TS1} encoded files.
+
+ \item[Ulrik Vieth (UV)]
+ Ulrik converted \texttt{fontinst.sty} to \package{doc}\slash
+ \package{docstrip} format, reunited Alan's v\,1.511 and
+ Sebastian's v\,1.7, and made the first official release of
+ \package{fontinst} (v\,1.8) for more than two years.
+
+ Ulrik is currently a member of the \package{fontinst}
+ maintenance team. He is also involved in the Joint TUG\slash
+ \LaTeX~3 Project Working Group on extended math font encodings.
+
+ \item[\textellipsis]
+\end{description}
+Anyone else?
+
+
+\section{To do}
+
+This section is based on the \texttt{TODO} file from \package{fontinst}
+v\,1.504, but a couple of new entries have been added and some have
+been equipped with comments.
+
+\subsection{Things to do in the ``near'' future}
+
+\begin{itemize}
+ \item
+ Update documentation. (Lars, knowing he isn't saying anything new)
+
+ \item
+ Rewrite the entire substitution mechanism from scratch! The main
+ problem with the current mechanism is that it only allows one
+ substitution per shape and one per series. One cannot substitute
+ the |it| shape for both the |sl| and the |ui| shapes since each
+ new |\substitute|(|noisy|\textbar|silent|) with |it| in the
+ \meta{from} argument will overwrite the setting made by the
+ previous;
+ \begin{quote}
+ |\substitutenoisy{ui}{it}|\\
+ |\substitutesilent{sl}{it}|
+ \end{quote}
+ is effectively the same as
+ \begin{quote}
+ |\substitutesilent{sl}{it}|
+ \end{quote}
+ Another big problem is that it isn't well defined what the
+ substitution mechanism should do. (Lars)
+
+ I've got a sketch for a new substitution mechanism, but I'm not
+ at all sure it will make it into any v\,1.9xx. /LH
+ (The code that was written is now in \texttt{fimain.dtx}, but
+ it's not included in any of the generated files.)
+
+ An alternative to substitutions is to use explicit
+ |\installfontas| commands. This provides complete control. /LH
+
+ \item
+ Consider removing the following unreliable fakes from
+ \texttt{textcomp.mtx}:
+ \begin{quote}
+ \texttt{asciiacutedbl}, \texttt{asciigravedbl},
+ \texttt{bardbl}, \texttt{openbracketleft}, and
+ \texttt{openbracketright}
+ \end{quote}
+ and consider adding fakes for the following unavailable glyphs:
+ \begin{quote}
+ \texttt{dollaroldstyle} (use \texttt{dollar}),
+ \texttt{centoldstyle} (use \texttt{cent}), \texttt{lira} (use
+ \texttt{sterling}), and \texttt{pilcrow} (use
+ \texttt{paragraph})
+ \end{quote}
+ These suggestions are of course open for debate. (Ulrik)
+
+ \item
+ One thing I miss in [the typeset form of an encoding
+ specification] is a simple hex/octal/decimal chart showing all
+ the character names in their positions (and ideally even an
+ example of the printed character, although I know that would be
+ harder). (Karl Berry)
+
+\end{itemize}
+
+
+\subsection{Things that probably won't be done in the near future}
+
+\begin{itemize}
+ \item
+ Find a way to automatically generate math fonts. (Alan)
+
+ I doubt that this will ever be possible to do automatically.
+ \package{mathptm} and \package{mathptmx} are already hackish enough,
+ not to mention the prototype implementations for new math font
+ encodings. /UV
+
+ \item
+ Investigate using Alternate sets. (Alan)
+
+ AFAIK, Thierry Bouche has done some work with alternate sets
+ for AGaramond, ACaslon and Minion, but this implies a lot of
+ manual work to compose the proper calls to \package{fontinst}. /UV
+
+ \item
+ Create \LaTeX\ packages? In fact, rethink the whole package
+ interface \textellipsis\ (Alan)
+
+ Sebastian's Perl front-end to \package{fontinst} does create trivial
+ \LaTeX\ packages automatically for the CTAN fonts. /UV
+
+ \item
+ Worry about excessive kern tables in \texttt{T1} fonts. (Alan)
+
+ I think the best way to get at this would be to write a program
+ that can optimize (for size) kern tables by making use of the |SKIP|
+ instruction. There's often room for quite a lot of compression.
+ Such a program would however have to be written in some compiling
+ language, otherwise it wouldn't be fast enough. /LH
+
+ \item
+ Consider making |\set|(|left|\textbar|right|)|kerning| parameterized
+ by the size of the other glyph, eg so that faking |<Asmall><T>| can
+ be different from |<Aacutesmall><T>|. Suggested by Hilmar Schlegel.
+
+\end{itemize}
+
+
+\subsection{Things that have been done}
+
+\begin{itemize}
+ \item
+ Update documentation (comments from Karl and Damian).
+
+ Rowland has meritoriously done the update requested here. On the
+ other hand, it needs to be updated again, since many new features
+ have been added. /LH
+
+ \item
+ Investigate using raw SC fonts. (Alan)
+
+ This problem comes up on the mailing list from time to time.
+ The problem is that \package{fontinst}'s |\latinfamily| command
+ is geared towards fonts that come with standard and expert font
+ sets (as with Adobe and Monotype fonts) rather than fonts that
+ come with standard and small caps (as with Linotype fonts).
+ I'm afraid it would be to complicated to handle both cases
+ in the same |\latinfamily| procedure. /UV
+
+ \item
+ Investigate problems with duplicate kerns appearing in VPL files
+ (Hilmar Schlegel).
+
+ The problem has been investigated and is solved with v\,1.9. /LH
+
+ \item
+ Find out why, if you have a font with both medium and light variants
+ but no italic, you get |m|/|it| $\mapsto$ |l|/|it| $\mapsto$
+ |l|/|sl| rather than |m|/|it| $\mapsto$ |m|/|sl|.
+ (Sebastian).
+
+ Because for every shape that \package{fontinst} is allowed to use
+ a given font for, it will perform all possible series substitutions.
+ If the |\installfont| for |l|/|sl| came before the |\installfont| for
+ |m|/|sl|, then substitutions will be as described above. See also
+ item about the substitution mechanism. /LH
+
+ \item
+ AFM files can contain real units, not just integers. (Gintautas
+ Grigelionis).
+
+ This is fixed with v\,1.9. /LH
+
+ \item
+ Make \texttt{fontdoc.sty} and co.\ use PS fonts. (Alan)
+
+ I think |\useexamplefont| and friends (introduced with v\,1.8)
+ pretty much do what was intended here. /LH
+
+ \item
+ \texttt{latin.mtx} uses \package{fontinst} rather than
+ \package{fontdoc}! (Rob Hutchings).
+
+ \item
+ Allow |.vpl| files to be read as |.pl| files. (Constantin)
+
+ \item
+ Richard Walker reports that if you say
+ \begin{quote}
+ |\latinfamily{mbvx}{}|\\
+ |\latinfamily{mbv9}{}|
+ \end{quote}
+ then the 2nd run doesn't use old-style digits, because the 1st run
+ has already defined |\digit|. If so, this is because |\latinfamily|
+ is missing a bracing level. I should investigate.
+
+ I think it is best to do oldstyle and non-oldstyle variants in two
+ separate fontinst runs, i.e. don't use |\latinfamily| more than once
+ in a single run. (IIRC, grouping doesn't work properly since
+ every single font closes and reopens a |\begingroup|-|\endgroup|
+ pair to encapsulate the kerning info\footnote{And glyph metrics
+ info, and glyph mapcommands info \textellipsis /LH} or something
+ like that.) /UV
+
+ \item
+ Consider writing an |\installfontas| command which doesn't
+ generate a (V)PL but makes an entry in the FD file.
+ Typical usage: Install an \texttt{sc} shape of a \texttt{TS1}
+ font family by using the font made for the \texttt{n} shape.
+ (Lars)
+
+ Done. The described installation for the \texttt{m} series of the
+ \texttt{ptm} font family can be done through
+ \begin{quote}
+ |\installfontas{ptmr8c}{TS1}{ptm}{m}{sc}{}|
+ \end{quote}
+ Note however that you need to do it in each series explicitly. /LH
+
+ \item
+ Use the \texttt{StdVW} property from AFM 4.0 files instead of the
+ width of \textit{I} for standard stem fontdimen. Pointed out by
+ Hilmar Schlegel.
+
+ Partially done. |\afmtomtx| writes a
+ |\setint{verticalstem}|\marg{value} when it encounters a
+ \texttt{StdVW} property. The ETX files have not yet (2000/05/30)
+ been changed to use this value. /LH
+
+ \item
+ \package{fontdoc} has a problem with glyph, integer, string,
+ etc.\ names that contains underscores, since these will cause
+ \TeX\ to jump to math mode when one tries to typeset these things.
+ Unfortunately \package{fontinst} itself writes two such integers:
+ \texttt{descender_neg} and \texttt{maxdepth_neg}. There are at
+ least three solutions to this. The first is to make underscore an
+ `other' character throughout, but this might break some comments in
+ MTX and ETX files. The second is to temporarily change the catcode
+ in the arguments of the commands, but that will complicate the
+ definitions of almost all \package{fontdoc} commands dramatically.
+ The third is to declare this as unsupported by \package{fontdoc} and
+ change \package{fontinst} so that the troublesome integers are
+ renamed, e.g.\ \texttt{descender-neg} and \texttt{maxdepth-neg}, but
+ this can break people's code. (Lars)
+
+ After thinking about it for a couple of months, I realized that
+ none of the above is the right solution. That is instead to use
+ something similar to the harmless character strings of the
+ \package{xdoc} package when typesetting names of variables etc.\
+ in \package{fontdoc}. This got implemented in v\,1.916. /LH
+
+ \item
+ Modify the (V)PL-to-MTX converter so that |\setint|\discretionary
+ {}{}{}|{fontdimen(|\meta{n}|)}|\discretionary{}{}{}|{\int|%
+ \marg{name}|}| commands in the ETX file declare that
+ \texttt{PARAMETER} (or equivalent) properties for fontdimen
+ \meta{n} should be converted to |\setint| commands for the integer
+ \meta{name}. This ought to be particularly useful for math fonts.
+ (Lars)
+
+ Done with v\,1.917, but only for the new \cs{setfontdimen}
+ command. /LH
+
+ \item
+ Update \texttt{fontdoc.sty} and co.\ for \LaTeXe. (Alan)
+
+ \texttt{fontdoc.sty} underwent a major overhaul from v\,1.916 on,
+ so I suspect this can be said to have been done now. The basic
+ vertical spacing put in by \cs{Aheading} and \cs{Bheading} may
+ however need more work; sometimes it doesn't come out as one
+ would want it to. /LH
+
+ \item
+ \texttt{latin.mtx} fakes composite SC glyphs [kerning?] from the
+ composite glyph, eg.
+ \begin{quote}
+ |\setleftrightkerning{Aacutesmall}{Aacute}{900}|,
+ \end{quote}
+ rather than from the SC non-composite, eg.
+ \begin{quote}
+ |\setleftrightkerning{Aacutesmall}{Asmall}{1000}|
+ \end{quote}
+ This may cause problems with SC fonts with explicit SC--C kerns,
+ eg.
+ \begin{quote}
+ |\setkern{V}{Asmall}{100}|
+ \end{quote}
+ This needs to be thought about. Pointed out by Hilmar Schlegel.
+
+ \texttt{newlatin.mtx} does this right; shrunk glyphs get shrunk
+ kerning, whereas constructed glyphs get kerning from the base
+ letter. /LH
+
+\end{itemize}
+
+
+\subsection{Other notes}
+
+Alan's \texttt{TODO} file also contains some items regarding
+\package{mathptm}, but that seems to have migrated out of
+\package{fontinst} (if it ever really was a part). The problem is that
+\package{mathptm} cannot be changed any more for the sake of checksum
+consistency and backwards compatibility. A new variant called
+\package{mathptmx} tries to do a little better, but there may still be
+room for improvements.
+
+
+
+\section{Efficiency}
+
+This section records the results of some (rather simple) test runs
+that have been made to test the efficiency of \package{fontinst},
+primarily to see how changes in the implementation affect efficiency
+by comparing the time and space used by different \package{fontinst}
+versions to complete the same task.
+
+
+\subsection{Alan Jeffrey's tests}
+\label{Ssec: ASAJ tests}
+
+I compared the version where you try to keep ints as |\mathchardef|s
+with the version where you don't bother, and for a sample font without
+|\mathchardef|s I got:
+\begin{quote}
+ 114673 words of memory out of 150001\\
+ Time elapsed: 135.0 seconds
+\end{quote}
+and with, I got:
+\begin{quote}
+ 114050 words of memory out of 150001\\
+ Time elapsed: 134.5 seconds
+\end{quote}
+so I've saved a little memory and time. Not brilliant, but I may as
+well keep it in.
+
+Where possible, we avoid re-scaling kerns, which saves a bit of time
+and memory. With a sample font, the version where we didn't avoid
+re-scaling used:
+\begin{quote}
+ 114050 words of memory out of 150001\\
+ Time elapsed: 134.5 seconds
+\end{quote}
+whereas the version where we do avoid it used:
+\begin{quote}
+ 113786 words of memory out of 150001\\
+ Time elapsed: 124.9 seconds
+\end{quote}
+
+We keep the names of the glyphs to kern with as |\l-|\meta{name} and
+|\r-|\meta{name} to save on token space, and this got the resources
+used down to:
+\begin{quote}
+ 88574 words of memory out of 150001\\
+ Time elapsed: 106.1 seconds
+\end{quote}
+Keeping track of the kern amounts as |\|\meta{amount} got the resources
+used down to:
+\begin{quote}
+ 75424 words of memory out of 150001\\
+ Time elapsed: 97.2 seconds
+\end{quote}
+Mind you, I then added all the |\transformfont| stuff, and it went
+back to:
+\begin{quote}
+ 77079 words of memory out of 150001\\
+ Time elapsed: 97.7 seconds
+\end{quote}
+
+
+
+\subsection{Current tests}
+
+The setup for this test is that \TeX\ is run on a \texttt{.tex} file
+consisting of the following commands.
+\begin{quote}
+ |\batchmode|\\
+ |\input fontinst.sty|\\
+ |\latinfamily{pad}{}|\\
+ |\tracingstats=1\bye|
+\end{quote}
+All the font metrics are generated from the AFM files; temporary MTX,
+PL, and VPL files are deleted between test runs. The format used was
+generated by typing |\dump| at ini\TeX's |**| prompt; thus there is no
+overhead from a typesetting format in the space requirements.
+
+[It appears the exact data from these tests will have to wait, since
+I haven't been able to get access to any computer with reliable
+process timing. For the next release perhaps \textellipsis\ /LH]
+
+% The \TeX\ version used is \TeX~3.14159. The \TeX\ implementation used
+% is te\TeX~0.9 (Web2C~7.2), running on a
+%
+% The \emph{input sources} figure lists how many items are used on
+% \TeX's stack for simultaneous input sources. As an input source in
+% this context is considered not only input files, but also (and mainly)
+% various token lists. Most of these token lists are replacement texts
+% and parameters of macros, but token list items on this stack also come
+% from expansions of |\the| (not only when applied to a |\toks| register)
+% and the like. The input source stack sizes of normal \TeX\
+% implementations are usually several times larger than what
+% \package{fontinst} uses, so this particular resource shouldn't cause
+% any trouble.
+%
+% The \emph{parameter} figure is the maximal number of macro parameters that
+% \TeX\ has to remember at any one time. The reason this number is
+% greater than 9 is that it counts parameters in \emph{all} macros that
+% are on the input sources stack, not just those in the top one. The
+% same remark about the likelyhood of \TeX\ running out of this resource
+% during a \package{fontinst} run as for input sources applies for
+% parameters.
+%
+% The \emph{buffer characters} stack holds lines read from input files that
+% are partially tokenized (if several files are on the input sources
+% stack then \TeX\ must remember the last line read from each of them) and
+% characters for |\csname| \textellipsis |\endcsname| constructions that
+% are being expanded. This shouldn't cause any trouble either.
+%
+% The \emph{save values} figure is the maximum number of items on \TeX's
+% save stack at any time. \package{fontinst} uses massive amounts of
+% space here (compared to normal \TeX\ documents), but there isn't much
+% that can be done about this since \package{fontinst} uses \TeX's
+% grouping mechanism to clear data for one font from memory before
+% processing begins with the next.
+%
+% The \emph{multiletter control sequences} figure is exactly
+% that---the number of control sequences whose names consist of more than
+% one character. When these become too many, \TeX\ complains that its
+% hash table is full. Some of these control sequences are macros that
+% \package{fontinst} uses in a procedure-like manner, but many of them are
+% rather used as data tables. As a comparision of the figure I might
+% mension that my \LaTeX\ used 3748 multiletter control sequences for
+% typesetting this document, so \package{fontinst} rather average in
+% this respect (perhaps a bit above, but not much).
+%
+% The \emph{strings} figure tells how many items \TeX\ put in its string
+% pool and the \emph{string characters} figure tells how many characters
+% these contain altogether. There are two main categories of things that
+% occur here: names of multiletter control sequences and \TeX's builtin
+% error messages. One thing which certainly doesn't occur here is the
+% texts you save using \package{fontinst}'s |\setstr| command; these will
+% instead become token lists and occupy main memory space (the \emph{names}
+% of string variables will however become part of a control sequence name,
+% so that will be stored as a string). Unlike some other \TeX\
+% implementations however, the Web2C \TeX\ seems to only report new
+% entries in the string pool, so the \emph{strings} and \emph{string
+% characters} figures below do not include the builtin error messages.
+% On the other hand, they don't include the names of the 322 primitive
+% multiletter control sequences either, which is why the figures below
+% report more control sequences than strings.
+%
+% The \emph{main memory}, finally, is where \TeX\ stores almost
+% everything else (I've skipped some of the memory categories \TeX\
+% reports since they are ``only'' used for typesetting), most notably
+% tokens. Each token occupies one word of memory. I don't think
+% \package{fontinst}'s consumption of main memory is that high (in
+% comparision with normal \LaTeX\ jobs) since \package{fontinst} doesn't
+% have to store any boxes here and thus frees space for more tokens.
+%
+% \begin{description}
+% \item[v\,1.801]
+% \consumption{126.68}{%954.9
+% % 5261 strings out of 8681
+% % 54607 string characters out of 136047
+% % 112422 words of memory out of 200001
+% % 3814 multiletter control sequences out of 10000
+% % 8 words of font info for 0 fonts, out of 180000 for 256
+% % 0 hyphenation exceptions out of 2551
+% % 30i,0n,42p,220b,1696s stack positions out of 600i,150n,200p,3000b,4094s
+% 3903 strings out of 13688
+% 42612 string characters out of 101822
+% 112422 words of memory out of 263001
+% 3961 multiletter control sequences out of 10000+0
+% 7 words of font info for 0 fonts, out of 200000 for 1000
+% 0 hyphenation exceptions out of 1000
+% 30i,0n,42p,220b,1770s stack positions out of 300i,100n,500p,30000b,4000s
+% }% Compulsory comment; TeX inserts a & at the end of this line
+% % as a side-effect of the implementation of \consumption.
+% \item[v\,1.902]
+% \consumption{139.59}{%997.4
+% % 6196 strings out of 8681
+% % 69530 string characters out of 136047
+% % 112617 words of memory out of 200001
+% % 4749 multiletter control sequences out of 10000
+% % 8 words of font info for 0 fonts, out of 180000 for 256
+% % 0 hyphenation exceptions out of 2551
+% % 28i,0n,42p,220b,2004s stack positions out of 600i,150n,200p,3000b,4094s
+% 4690 strings out of 13688
+% 52734 string characters out of 101822
+% 112613 words of memory out of 263001
+% 4748 multiletter control sequences out of 10000+0
+% 7 words of font info for 0 fonts, out of 200000 for 1000
+% 0 hyphenation exceptions out of 1000
+% 28i,0n,42p,220b,2000s stack positions out of 300i,100n,500p,30000b,4000s
+% }%
+% Comparing the figures for v\,1.902 with those of v\,1.801, there
+% are mainly three things which are of interest. The first is that
+% the number of items on the save stack have increased quite a lot.
+% Most of this is due to the mechanism by which \package{fontinst}
+% avoids writing multiple kerns to (V)PL files. The second thing to
+% notice is that the number of control sequences has increased quite
+% dramatically (over 20\%). This is to be expected, as a number of
+% new features have been added and the implementation of these
+% features requires many new macros.
+%
+% Some 200 of these new control sequences are however not there
+% because of new features, but because of a silly implementation of
+% how slot numbers for glyphs are stored. In an attempt to save
+% tokens, I (LH) stored these numbers as control sequence names
+% rather than token sequences, just like kern amounts have been
+% stored for some time now. One notable feature of kern
+% amounts is however that although these may assume just about any
+% value you can think of, within any given font family they tend to
+% assume only a handful of values. This means that the number of
+% hash positions occupied by such control sequences is never very
+% large and the storage is efficient. On the other hand, the set of
+% slot numbers that occur usually consists of all integers in the
+% range 0--255, with each slot number occuring in at most one
+% position. This means that the storage method, although efficient
+% in the number of tokens, really squanders space in the hash table.
+% A much better method (which should be implemented, once I get round
+% to it) is to store slot numbers in the character codes of `ordinary'
+% tokens.
+%
+% The third noticable thing is that although the number of macros
+% has grown quite a lot, the amount of main memory used has hardly
+% increased at all! Some of this is probably due to that the ENC to
+% ETX converter was moved to \texttt{finstmsc.sty}, since this
+% consists of only two macros but lots of tokens. Another factor
+% that has probably helped is that |\glyph| now avoids rescaling a
+% glyph by one thousand; this saves 9 tokens for each time
+% |\glyph|\marg{name}|{1000}| gets executed.
+% \item[v\,1.907]
+% \consumption{138.88}{%1019.9
+% % 6226 strings out of 8681
+% % 69918 string characters out of 136047
+% % 113820 words of memory out of 200001
+% % 4779 multiletter control sequences out of 10000
+% % 8 words of font info for 0 fonts, out of 180000 for 256
+% % 0 hyphenation exceptions out of 2551
+% % 28i,0n,42p,220b,2006s stack positions out of 600i,150n,200p,3000b,4094s
+% % 6225 strings out of 8681
+% 4719 strings out of 13688
+% 53105 string characters out of 101822
+% 113814 words of memory out of 263001
+% 4777 multiletter control sequences out of 10000+0
+% 7 words of font info for 0 fonts, out of 200000 for 1000
+% 0 hyphenation exceptions out of 1000
+% 28i,0n,42p,220b,2002s stack positions out of 300i,100n,500p,30000b,4000s
+% }%
+% This is pretty much what could be expected. A couple of new
+% features have been added, so naturally some of the numbers have
+% grown a little.
+% \item[v\,1.908]
+% This version is devoted to optimizing \package{fontinst}.
+%
+% The first idea was to avoid moving the contents of
+% |\glyph_map_commands| and |\glyph_map_fonts| to a macro and back
+% again each time these are updated. This changed the numbers to
+% \consumption{135.64}{%
+% 4719 strings out of 13688
+% 53105 string characters out of 101822
+% 113810 words of memory out of 263001
+% 4777 multiletter control sequences out of 10000+0
+% 7 words of font info for 0 fonts, out of 200000 for 1000
+% 0 hyphenation exceptions out of 1000
+% 28i,0n,42p,220b,2002s stack positions out of 300i,100n,500p,30000b,4000s
+% }%
+% Hence I've earned a few seconds.
+%
+% The next idea is to expand the |\space|s in |\out_lline| and
+% friends when these are defined, instead of expanding them anew
+% each time an output line is written.
+% \item[v\,1.909]
+% \consumption{}{%1159.8 % Ow! It's getting worse.
+% % 6155 strings out of 8681
+% % 68824 string characters out of 136047
+% % 113918 words of memory out of 200001
+% % 4708 multiletter control sequences out of 10000
+% % 8 words of font info for 0 fonts, out of 180000 for 256
+% % 0 hyphenation exceptions out of 2551
+% % 28i,0n,42p,220b,1982s stack positions out of 600i,150n,200p,3000b,4094s
+% }
+% \item[v\,1.910]
+% \consumption{}{%1031.6 % Perhaps not ...
+% % 5949 strings out of 8681
+% % 68261 string characters out of 136047
+% % 113840 words of memory out of 200001
+% % 4502 multiletter control sequences out of 10000
+% % 8 words of font info for 0 fonts, out of 180000 for 256
+% % 0 hyphenation exceptions out of 2551
+% % 28i,0n,42p,220b,1756s stack positions out of 600i,150n,200p,3000b,4094s
+% }
+% \end{description}
+%
+
+
+\begin{thebibliography}{99}
+\bibitem{Fontname}
+ Karl Berry: \textit{Fontname}, CTAN:\discretionary{}{}{}%
+ \texttt{info}\slash \texttt{fontname}\slash \texttt{fontname.texi}
+ (and most of the other files in that directory as well).
+\bibitem{mfnt}
+ Matthias Clasen and Ulrik Vieth:
+ \texttt{mfnt} (their ``work with math fonts''), 1997--8,
+ see \textsc{http}:/\slash \texttt{www.tug.org}\slash
+ \texttt{twg}\slash \texttt{mfg}\slash\texttt{archives}/.
+\bibitem{LaTeX-companion}
+ Michel Goossens, Frank Mittelbach, Alexander Samarin:
+ \textit{The \LaTeX\ Companion},
+ Ad\-di\-son-Wes\-ley, Reading, MA, USA, 1994.
+ % Addison and Wesley are names of two persons, but they
+ % should be joined by a hyphen since Addison-Wesley is
+ % a company name. Tricky that.
+\bibitem{LaTeX-graph-comp}
+ Michel Goossens, Sebastian Rahtz, Frank Mittelbach:
+ \textit{The \LaTeX\ Graphics Companion: Illustrating Documents with
+ \TeX\ and PostScript},
+ Ad\-di\-son-Wes\-ley, Reading, MA, USA, 1997;
+ ISBN~0-201-85469-4.
+\bibitem{TAOCP2}
+ Donald E.\ Knuth: \textit{The art of computer programming},
+ vol.~2 (\textit{Seminumerical algorithms}), 3rd ed.,
+ Ad\-di\-son-Wes\-ley, 1997.
+\bibitem{TeXbook}
+ Donald E.\ Knuth, Duane Bibby (illustrations):
+ \textit{The \TeX book},
+ Ad\-di\-son-Wes\-ley, 1991, ISBN~0-201-13448-9;
+ also volume A of \textit{Computers and typesetting},
+ ISBN~0-201-13447-0.
+\bibitem{fntguide}
+ \LaTeX3 Project Team: \textit{\LaTeXe{} font selection},
+ CTAN: \texttt{macros}\slash
+ \texttt{latex}\slash\texttt{base}\slash\texttt{fntguide.tex}.
+\end{thebibliography}
+
+
+\end{document}
diff --git a/fonts/utilities/fontinst/source/fitrig.dtx b/fonts/utilities/fontinst/source/fitrig.dtx
new file mode 100644
index 0000000000..9d369b3772
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fitrig.dtx
@@ -0,0 +1,326 @@
+% \CheckSum{209}
+% \iffalse meta-comment
+%
+% trig.dtx Copyright (C) 1993 1994 1995 1996 1997 1999 David Carlisle
+% Inlined as fitrig.dtc 2005 Lars Hellstr"om
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.1 or, at your option, any later version.
+%
+%%% From file: fitrig.dtx
+%
+%<*driver>
+\documentclass{ltxdoc}
+\usepackage{fisource}
+\title{The \textsf{trig} package inlined into \package{fontinst}}
+\author{David Carlisle\\Edited by Lars Hellstr\"om}
+\begin{document}
+\maketitle
+\DocInput{fitrig.dtx}
+\end{document}
+%</driver>
+% \fi
+%
+%
+% The predecessor of this file is v\,1.09 of \texttt{trig.dtx}, the
+% source for the \package{trig} package in the standard \LaTeX\
+% ``graphics'' bundle. It has been inlined into the \package{fontinst}
+% source mainly because archive maintainers never seem to tire of
+% questioning the need to provide \texttt{trig.sty} with
+% \package{fontinst}.
+%
+% \changes{1.930}{2005/02/06}{Inlined the \package{trig} package into
+% \texttt{fontinst.sty} and friends. (LH)}
+%
+%
+% \section{Trigonometrical functions}
+%
+% These macros implement the trigonometric functions, sin, cos and tan.
+% In each case two commands are defined. For instance the command
+% |\CalculateSin{33}| may be isued at some point, and then anywhere
+% later in the document, the command |\UseSin{33}| will return the
+% decimal expansion of $\sin(33^\circ)$.
+%
+% The arguments to these macros do not have to be whole numbers,
+% although in the case of whole numbers, \LaTeX\ or plain \TeX\ counters
+% may be used. In \TeX{}Book syntax, arguments must be of type:
+% \meta{optional signs}\meta{factor}
+%
+% Some other examples are:\\
+% |\CalculateSin{22.5}|, |\UseTan{\int{myvar}}|,
+% |\UseCos{\count@}|.
+%
+% Note that unlike the psfig macros, these save all previously
+% computed values. This could easily be changed, but I thought that in
+% many applications one would want many instances of the
+% same value. (eg rotating all the headings of a table by the
+% \emph{same} amount).
+%
+% I don't really like this need to pre-calculate the values, I
+% originally implemented |\UseSin| so that it automatically calculated
+% the value if it was not pre-stored. This worked fine in testing, until
+% I remembered why one needs these values. You want to be able to say
+% |\dimen2=\UseSin{30}\dimen0|. Which means that |\UseSin| must
+% \emph{expand} to a \meta{factor}.
+%
+% \StopEventually{}
+%
+%
+% \subsection{The Macros}
+%
+% \begin{macrocode}
+%<*pkg>
+% \end{macrocode}
+%
+% \begin{macro}{\nin@ty}\begin{macro}{\@clxxx}
+% \changes{1.930}{2005/02/06}{Renamed this constant. There should be
+% three \texttt{x}s in \cs{romannumeral} 180, but \package{trig}
+% only had two. (LH)}
+% \begin{macro}{\@lxxi}\begin{macro}{\@mmmmlxviii}
+% Some useful constants for converting between degrees and radians.
+% $$
+% \frac{\pi}{180}\simeq\frac{355}{113\times180}=\frac{71}{4068}
+% $$
+% \begin{macrocode}
+\chardef\nin@ty=90
+\chardef\@clxxx=180
+\chardef\@lxxi=71
+\mathchardef\@mmmmlxviii=4068
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+% The approximation to $\sin$. I experimented with various
+% approximations based on Tchebicheff polynomials, and also some
+% approximations from a SIAM handbook `Computer Approximations' However
+% the standard Taylor series seems sufficiently accurate, and used by
+% far the fewest \TeX\ tokens, as the coefficients are all rational.
+% \begin{eqnarray*}
+% \sin(x)& \simeq&
+% x - (1/3!)x^3 + (1/5!)x^5 - (1/7!)x^7 + (1/9!)x^9\\
+% &\simeq&
+% \frac{((((7!/9!x^2-7!/7!)x^2+7!/5!)x^2 +7!/3!)x^2+7!/1!)x}{7!}\\
+% &=& \frac{ ((((1/72x^2-1)x^2+42)x^2 +840)x^2+5040)x }{5040}
+% \end{eqnarray*}
+% The nested form used above reduces the number of operations required.
+% In order to further reduce the number of operations, and more
+% importantly reduce the number of tokens used, we can precompute the
+% coefficients. Note that we cannot use $9!$ as the denominator as
+% this would cause overflow of \TeX's arithmetic.
+%
+% \begin{macro}{\@coeffz}
+% \begin{macro}{\@coeffa}
+% \begin{macro}{\@coeffb}
+% \begin{macro}{\@coeffc}
+% \begin{macro}{\@coeffd}
+% Save the coefficients as |\|(|math|)|char|s.
+% \begin{macrocode}
+\chardef\@coeffz=72
+%\chardef\@coefa=1
+\chardef\@coefb=42
+\mathchardef\@coefc=840
+\mathchardef\@coefd=5040
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\TG@rem@pt}
+% The standard trick of getting a real number out of a \meta{dimen}.
+% This gives a maximum accuracy of approx.\ 5 decimal places, which
+% should be sufficient. It puts a space after the number, perhaps it
+% shouldn't.
+% \changes{1.930}{2005/02/06}{Using \cs{lose_measure}. (LH)}
+% \begin{macrocode}
+\def\TG@rem@pt#1{\expandafter\lose_measure\the#1\space}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\TG@term}
+% Compute one term of the above nested series. Multiply the previous
+% sum by $x^2$ (stored in |\@tempb|, then add the next coefficient,
+% |#1|.
+% \begin{macrocode}
+\def\TG@term#1{
+ \dimen@\@tempb\dimen@
+ \advance\dimen@ #1\p@
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\TG@series}
+% Compute the above series. The value in degrees will be in
+% |\dimen@| before this is called.
+% \begin{macrocode}
+\def\TG@series{
+ \dimen@\@lxxi\dimen@
+ \divide \dimen@ \@mmmmlxviii
+% \end{macrocode}
+% |\dimen@| now contains the angle in radians, as a \meta{dimen}.
+% We need to remove the units, so store the same value as a
+% \meta{factor} in |\@tempa|.
+% \begin{macrocode}
+ \edef\@tempa{\TG@rem@pt\dimen@}
+% \end{macrocode}
+% Now put $x^2$ in |\dimen@| and |\@tempb|.
+% \begin{macrocode}
+ \dimen@\@tempa\dimen@
+ \edef\@tempb{\TG@rem@pt\dimen@}
+% \end{macrocode}
+% The first coefficient is $1/72$.
+% \begin{macrocode}
+ \divide\dimen@\@coeffz
+ \advance\dimen@\m@ne\p@
+ \TG@term\@coefb
+ \TG@term{-\@coefc}%
+ \TG@term\@coefd
+% \end{macrocode}
+% Now the cubic in $x^2$ is completed, so we need to multiply by
+% $x$ and divide by $7!$.
+% \begin{macrocode}
+ \dimen@\@tempa\dimen@
+ \divide\dimen@ \@coefd
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \changes{1.930}{2005/02/06}{Use \cs{x_cs} and \cs{if_undefined} where
+% appropriate. (LH)}
+%
+% \begin{macro}{\CalculateSin}
+% If this angle has already been computed, do nothing, else store
+% the angle, and call |\TG@@sin|. Computed sines are stored in
+% control sequences with names of the form
+% \describecsfamily{sin(\meta{number})}|\sin(|\meta{number}|)|.
+% \begin{macrocode}
+\def\CalculateSin#1{{%
+ \if_undefined{sin(\number#1)}\then
+ \dimen@=#1\p@
+ \TG@@sin
+ \x_cs\xdef{sin(\number#1)}{\TG@rem@pt\dimen@}
+ \fi
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\CalculateCos}
+% As above, but use the relation $\cos(x) = \sin(90-x)$. Computed
+% cosines are stored in control sequences with names of the form
+% \describecsfamily{cos(\meta{number})}|\cos(|\meta{number}|)|.
+% \begin{macrocode}
+\def\CalculateCos#1{{%
+ \if_undefined{cos(\number#1)}\then
+ \dimen@=\nin@ty\p@
+ \advance \dimen@ -#1\p@
+ \TG@@sin
+ \x_cs\xdef{cos(\number#1)}{\TG@rem@pt\dimen@}
+ \fi
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\TG@@sin}
+% Repeatedly use one of the the relatations
+% $\sin(x)=\sin(180-x)=\sin(-180-x)$ to get $x$ in the range
+% $-90 \leq x\leq 90$. Then call |\TG@series|.
+% \begin{macrocode}
+\def\TG@@sin{%
+ \ifdim\TG@reduce>+%
+ \else\ifdim\TG@reduce<-%
+ \else\TG@series\fi\fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\TG@reduce}
+% Slightly cryptic, but it seems to work\ldots\space
+% The first line is the condition for an |\ifdim|, the remaining
+% lines constitutes the `then' branch of that conditional.
+% \begin{macrocode}
+\def\TG@reduce#1#2{
+ \dimen@#1#2\nin@ty\p@
+ \advance\dimen@#2-\@clxxx\p@
+ \dimen@-\dimen@
+ \TG@@sin
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\UseSin}
+% \begin{macro}{\UseCos}
+% Use a pre-computed value.
+% \begin{macrocode}
+\def\UseSin#1{\csname sin(\number#1)\endcsname}
+\def\UseCos#1{\csname cos(\number#1)\endcsname}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% A few shortcuts to save space.
+% \begin{macrocode}
+\chardef\z@num\z@
+\x_cs\let{sin(0)} \z@num
+\x_cs\let{cos(0)} \@ne
+\x_cs\let{sin(90)} \@ne
+\x_cs\let{cos(90)} \z@num
+\x_cs\let{sin(-90)}\m@ne
+\x_cs\let{cos(-90)}\z@num
+\x_cs\let{sin(180)}\z@num
+\x_cs\let{cos(180)}\m@ne
+% \end{macrocode}
+%
+% \begin{macro}{\CalculateTan}
+% Originally I coded the Taylor series for tan, but it seems to
+% be more accurate to just take the ratio of the sine and cosine.
+% This is accurate to 4 decimal places for angles up to
+% $50^\circ$, after that the accuracy tails off, giving
+% $57.47894$ instead of $57.2900$ for $89^\circ$.
+%
+% Computed tangents are stored in control sequences with names of the
+% form \describecsfamily{tan(\meta{number})}|\tan(|\meta{number}|)|.
+% \begin{macrocode}
+\def\CalculateTan#1{{%
+ \if_undefined{tan(\number#1)}\then
+ \CalculateSin{#1}%
+ \CalculateCos{#1}%
+ \a_dimen\UseCos{#1}\p@
+ \divide \a_dimen \@iv
+ \b_dimen\UseSin{#1}\p@
+ \b_dimen\two@fourteen\b_dimen
+ \divide\b_dimen\a_dimen
+ \x_cs\xdef{tan(\number#1)}{\TG@rem@pt\b_dimen}
+ \fi
+}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\UseTan}
+% Just like |\UseSin|.
+% \begin{macrocode}
+\def\UseTan#1{\csname tan(\number#1)\endcsname}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\two@fourteen}
+% \begin{macro}{\@iv}
+% Two constants needed to keep the division within \TeX's range.
+% \begin{macrocode}
+\mathchardef\two@fourteen=16384
+\chardef\@iv=4
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% Predefine $\tan(\pm90)$ to be an error.
+% \begin{macrocode}
+\x_cs\def{tan(90)}{\errmessage{Infinite tan !}}
+\expandafter\let
+ \csname tan(-90)\expandafter\endcsname \csname tan(90)\endcsname
+%</pkg>
+% \end{macrocode}
+%
+% \Finale
+%
+\endinput
+
diff --git a/fonts/utilities/fontinst/source/fontinst.ins b/fonts/utilities/fontinst/source/fontinst.ins
new file mode 100644
index 0000000000..fbde286b9d
--- /dev/null
+++ b/fonts/utilities/fontinst/source/fontinst.ins
@@ -0,0 +1,135 @@
+%
+% Copyright 1998, 1999, 2000, 2001 the fontinst maintenance team and any
+% individual authors listed elsewhere in this file. All rights reserved.
+%
+% This file is part of the fontinst system version 1.9.
+% -----------------------------------------------------
+%
+% It may be distributed under the terms of the LaTeX Project Public
+% License, as described in lppl.txt in the base LaTeX distribution.
+% Either version 1.1 or, at your option, any later version.
+%
+% This file may only be modified if (i) it is given another name and
+% (ii) all files the modified file generates using a nonempty subset
+% of the files listed in the arguments of \from commands below are
+% given the same preamble as that listed between \preamble and
+% \endpreamble below.
+%
+\input docstrip.tex
+\keepsilent
+
+\preamble
+
+This is a generated file.
+
+Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+hacked and maintained 1997, 1998 Sebastian Rahtz,
+copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 the fontinst
+maintenance team and any individual authors listed elsewhere in
+this file. All rights reserved.
+
+This file is part of the fontinst system version 1.9.
+-----------------------------------------------------
+
+It may be distributed under the terms of the LaTeX Project Public
+License, as described in lppl.txt in the base LaTeX distribution.
+Either version 1.1 or, at your option, any later version.
+
+\endpreamble
+
+\declarepreamble\docpreamble
+
+This is a generated file.
+
+Copyright 1993, 1994, 1995, 1996 Alan Jeffrey,
+hacked and maintained 1997, 1998 Sebastian Rahtz,
+copyright 1998, 1999, 2000, 2001 the fontinst maintenance team and any
+individual authors listed elsewhere in this file. All rights reserved.
+
+This file is part of the fontinst system version 1.9.
+-----------------------------------------------------
+
+It may be distributed under the terms of the LaTeX Project Public
+License, as described in lppl.txt in the base LaTeX distribution.
+Either version 1.1 or, at your option, any later version.
+This file may also be distributed by itself provided it is unchanged
+and accompanied by some prominent file which states the location of
+the sources for the fontinst system, from which this file was
+generated.
+
+\endpreamble
+
+
+
+
+
+\generate{%
+ \usedir{tex/fontinst/base}
+ \file{fontinst.sty}{%
+ \from{fibasics.dtx}{pkg}%
+ \from{ficommon.dtx}{pkg}%
+ \from{fimain.dtx}{pkg}%
+ \from{fitrig.dtx}{pkg}%
+ \from{ficonv.dtx}{pkg}%
+ \from{filtfam.dtx}{pkg,textcomp,debug}%
+ \from{fimapgen.dtx}{pkg}%
+ \from{fibasics.dtx}{pkg2}%
+ }%
+ \file{cfntinst.sty}{%
+ \from{fibasics.dtx}{pkg}%
+ \from{ficommon.dtx}{pkg}%
+ \from{fimain.dtx}{pkg,boundaryCompability}%
+ \from{fitrig.dtx}{pkg}%
+ \from{ficonv.dtx}{pkg}%
+ \from{filtfam.dtx}{pkg,textcomp,debug}%
+ \from{fimapgen.dtx}{pkg}%
+ \from{fibasics.dtx}{pkg2}%
+ }%
+ \file{xfntinst.sty}{%
+ \from{fibasics.dtx}{pkg}%
+ \from{ficommon.dtx}{pkg}%
+ \from{fimain.dtx}{pkg}%
+ \from{fitrig.dtx}{pkg}%
+ \from{ficonv.dtx}{pkg}%
+ \from{filtfam.dtx}{pkg,textcomp,debug,oldstyle}%
+ \from{fimapgen.dtx}{pkg}%
+ \from{fibasics.dtx}{pkg2}%
+ }%
+ \file{finstmsc.sty}{%
+ \from{fibasics.dtx}{pkg}%
+ \from{ficommon.dtx}{pkg}%
+ \from{fimain.dtx}{misc}%
+ \from{ficonv.dtx}{misc}%
+ \from{fimapgen.dtx}{map}%
+ \from{fibasics.dtx}{pkg2,misc}%
+ }%
+ \file{fontinst.ini}{\from{fibasics.dtx}{ini}}%
+ \usedir{tex/fontinst/misc}%
+ \file{csc2x.tex}{\from{ficonv.dtx}{reglyphfigures,reglyphletters,glyphs}}%
+ \file{csckrn2x.tex}{\from{ficonv.dtx}{reglyphfigures,reglyphletters}}%
+ \file{osf2x.tex}{\from{ficonv.dtx}{reglyphfigures,glyphs}}%
+ \usedir{tex/latex/misc}%
+ \usepreamble\docpreamble
+ \file{fontdoc.sty}{%
+ \from{fibasics.dtx}{doc}%
+ \from{ficommon.dtx}{doc}%
+ \from{fimain.dtx}{doc}%
+ \from{fimapgen.dtx}{doc}%
+ }%
+}
+
+% \OriginalAsk\answer{Do you wish to install trig.sty with fontinst? [y/n] }
+% \ifx \answer\y \let\answer\yes \fi
+% \ifx \answer\yes
+%
+% \usedir{tex/fontinst/base}
+% % From graphics.ins:
+% \preamble
+% \endpreamble
+%
+% \generate{\file{trig.sty}{\from{trig.dtx}{package}}}
+%
+% \fi
+
+\endbatchfile
+\endinput
diff --git a/fonts/utilities/fontinst/test/cc-pl.enc b/fonts/utilities/fontinst/test/cc-pl.enc
new file mode 100644
index 0000000000..161fe4345b
--- /dev/null
+++ b/fonts/utilities/fontinst/test/cc-pl.enc
@@ -0,0 +1,258 @@
+/encpcr [
+/Gamma
+/Delta
+/Theta
+/Lambda
+/Xi
+/Pi
+/Sigma
+/Upsilon
+/Phi
+/Psi
+/Omega
+/ff
+/fi
+/fl
+/ffi
+/ffl
+/dotlessi
+/dotlessj
+/grave
+/acute
+/caron
+/breve
+/macron
+/ring
+/cedilla
+/germandbls
+/ae
+/oe
+/oslash
+/AE
+/OE
+/Oslash
+/suppress
+/exclam
+/quotedblright
+/numbersign
+/dollar
+/percent
+/ampersand
+/quoteright
+/parenleft
+/parenright
+/asterisk
+/plus
+/comma
+/hyphen
+/period
+/slash
+/zero
+/one
+/two
+/three
+/four
+/five
+/six
+/seven
+/eight
+/nine
+/colon
+/semicolon
+/exclamdown
+/equal
+/questiondown
+/question
+/at
+/A
+/B
+/C
+/D
+/E
+/F
+/G
+/H
+/I
+/J
+/K
+/L
+/M
+/N
+/O
+/P
+/Q
+/R
+/S
+/T
+/U
+/V
+/W
+/X
+/Y
+/Z
+/bracketleft
+/quotedblleft
+/bracketright
+/circumflex
+/dotaccent
+/quoteleft
+/a
+/b
+/c
+/d
+/e
+/f
+/g
+/h
+/i
+/j
+/k
+/l
+/m
+/n
+/o
+/p
+/q
+/r
+/s
+/t
+/u
+/v
+/w
+/x
+/y
+/z
+/endash
+/emdash
+/hungarumlaut
+/tilde
+/dieresis
+/.notdef
+/Aogonek
+/Cacute
+/.notdef
+/.notdef
+/.notdef
+/Eogonek
+/.notdef
+/.notdef
+/.notdef
+/Lslash
+/Nacute
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/Sacute
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/Zacute
+/.notdef
+/Zdotaccent
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/aogonek
+/cacute
+/.notdef
+/.notdef
+/.notdef
+/eogonek
+/.notdef
+/.notdef
+/.notdef
+/lslash
+/nacute
+/.notdef
+/.notdef
+/guillemotleft
+/guillemotright
+/.notdef
+/sacute
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/zacute
+/.notdef
+/zdotaccent
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/Oacute
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/oacute
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/.notdef
+/quotedblbase
+] def
diff --git a/fonts/utilities/fontinst/test/comparemetrics.sty b/fonts/utilities/fontinst/test/comparemetrics.sty
new file mode 100644
index 0000000000..7864da8973
--- /dev/null
+++ b/fonts/utilities/fontinst/test/comparemetrics.sty
@@ -0,0 +1,941 @@
+% We start by making some default catcode assignments, in case we are
+% using ini\TeX{}.
+% \begin{macrocode}
+%<*pkg>
+\catcode`\{=1
+\catcode`\}=2
+\catcode`\#=6
+\catcode`\^=7
+%</pkg>
+% \end{macrocode}
+%
+% \package{fontinst} uses some unusual, but convenient, settings of
+% |\catcode|. |@| and |_| are made letters, |~| is made a space, and
+% space and newline are ignored. Before setting those however, we save
+% the current values of the catcodes, so that they can be restored at
+% the end of \texttt{fontinst.sty}.
+%
+% \begin{macrocode}
+%<*pkg>
+\edef\spacecatcode{\the\catcode`\ }
+\edef\nlcatcode{\the\catcode`\^^M}
+\edef\atcatcode{\the\catcode`\@}
+\edef\underscorecatcode{\the\catcode`\_}
+\edef\tildecatcode{\the\catcode`\~}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\catcode`\ =9
+\catcode`\^^M=9
+\catcode`\@=11
+\catcode`\_=11
+\catcode`\~=10
+%</pkg>
+% \end{macrocode}
+%
+
+
+\newlinechar=`\^^J
+
+% \begin{macro}{\a_read}
+% \begin{macro}{\b_read}
+% \begin{macro}{\a_filelineno}
+% \begin{macro}{\b_filelineno}
+% These control sequences are used for keeping track of the ``physical''
+% side of the two input files. |\a_read| and |\b_read| are the stream
+% numbers. |\a_filelineno| and |\b_filelineno| are the respective
+% line numbers of the lines most recently read from these files.
+% \begin{macrocode}
+\newread\a_read
+\newread\b_read
+\newcount\a_filelineno
+\newcount\b_filelineno
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}
+%
+% \begin{macro}{\a_lineno}
+% \begin{macro}{\b_lineno}
+% \begin{macro}{\a_bufbase}
+% \begin{macro}{\b_bufbase}
+% \begin{macro}{\a_bufmid}
+% \begin{macro}{\b_bufmid}
+% \begin{macro}{\a_buftop}
+% \begin{macro}{\b_buftop}
+% These count registers are used for managing the buffert of lines
+% that are read from the input files when a match between lines is
+% being looked for. This buffert consists of lines which are saved in
+% the macros
+% \begin{quote}
+% |\|\meta{letter}|_saved-|\meta{ofs}
+% \end{quote}
+% where \meta{letter} is |a| or |b| and \meta{ofs} is an integer,
+% being the index into the buffert. |\a_bufbase| and |\b_bufbase|
+% contain the \meta{ofs} of the first line currently in the buffert,
+% whereas |\a_buftop| and |\b_buftop| contain the \meta{ofs} of the
+% last such line. |\a_bufmid| and |\b_bufmid| hold the buffert
+% positions of the lines which are currently considered the next by
+% |\get_next_line|. If \(\mathtt{buftop}<\mathtt{bufmid}\) then the
+% buffert is empty. |\a_lineno| and |\b_lineno| are the respective
+% line numbers of the |\a_bufbase| and |\b_bufbase| lines.
+%
+% All these registers should be set globally.
+% \begin{macrocode}
+\newcount\a_lineno \newcount\b_lineno
+\newcount\a_bufbase \newcount\b_bufbase
+\newcount\a_bufmid \newcount\b_bufmid
+\newcount\a_buftop \newcount\b_buftop
+% \end{macrocode}
+% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}\end{macro}
+% \end{macro}\end{macro}
+
+
+% \begin{macro}{\get_next_line}
+% The |\get_next_line| macro is called as
+% \begin{quote}
+% |\get_next_line|\marg{letter}
+% \end{quote}
+% where \meta{letter} is |a| or |b|. This sets the
+% |\|\meta{letter}|_line| macro to the next line of that file and
+% updates the value of |\|\meta{letter}|_lineno|.
+%
+% The ``next line'' is normally read from input stream
+% |\|\meta{letter}|_read|, but if a line mismatch recently occured
+% then it might happen that the next line has already been read from
+% the file, and in that case it is taken from one of the
+% |\|\meta{letter}|_saved-|\meta{ofs} macros.
+% \begin{macrocode}
+\def\get_next_line#1{
+ \ifnum \csname#1_buftop\endcsname<\csname#1_bufmid\endcsname
+ \ifeof \csname#1_read\endcsname
+ \x_cs\let{#1_line}\end_of_file_line
+ \else
+ \read\csname#1_read\endcsname t\x_cs{o}{#1_line}
+ \global\advance \csname#1_filelineno\endcsname \@ne
+ \fi
+ \else
+ \expandafter\let \csname#1_line\expandafter\endcsname
+ \csname#1_saved-\the\csname#1_bufmid\endcsname\endcsname
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+
+% \begin{macro}{\end_of_file_line}
+% This macro expands to the text \verb*|(ENDOFFILE) | with the
+% catcodes it would have if read from an input file. It is used as an
+% end-of-file marker.
+% \begin{macrocode}
+\begingroup
+ \catcode`\(=13
+ \catcode`\)=13
+ \gdef\end_of_file_line{(ENDOFFILE)~}
+\endgroup
+% \end{macrocode}
+% \end{macro}
+
+% \begin{macro}{\the_line}
+% The |\the_line| macro is called as
+% \begin{quote}
+% |\the_line|\marg{letter}\marg{ofs}
+% \end{quote}
+% where \meta{letter} is |a| or |b|, and \meta{ofs} is a \TeX\ number.
+% It expands to the control sequence |\|\meta{letter}|_saved-|^^A
+% \meta{ofs}.
+% \begin{macrocode}
+\def\the_line#1#2{\csname#1_saved-\number#2\endcsname}
+% \end{macrocode}
+% \end{macro}
+
+% \begin{macro}{\initialise_search}
+% The |\initialise_search| macro sets everything up for a search for
+% a match between lines.
+%
+% \begin{macrocode}
+\def\initialise_search{
+ \global\a_bufbase=\a_bufmid
+ \global\b_bufbase=\b_bufmid
+ \add_to_buffert{a}
+ \add_to_buffert{b}
+ \global\advance \a_bufmid \@ne
+ \global\advance \b_bufmid \@ne
+}
+% \end{macrocode}
+% \end{macro}
+
+% \begin{macro}{\add_to_buffert}
+% The |\add_to_buffert| macro is called as
+% \begin{quote}
+% |\add_to_buffert|\marg{letter}
+% \end{quote}
+% It adds the line returned by |\get_next_line| to the corresponding
+% buffert (if it wasn't already there) and updates the counters for
+% that buffert. After this, the line following the line being put into
+% the buffert will be the line that |\get_next_line| returns.
+% \begin{macrocode}
+\def\add_to_buffert#1{
+ \ifnum \csname#1_buftop\endcsname<\csname#1_bufmid\endcsname
+ \expandafter\let
+ \csname#1_saved-\the\csname#1_bufmid\endcsname
+ \expandafter\endcsname
+ \csname#1_line\endcsname
+ \global\advance \csname#1_buftop\endcsname \@ne
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+
+
+
+\newcount\first_integer
+\newcount\second_integer
+
+% \begin{macro}{\match_lines}
+% The |\match_lines| macro tests if two lines can be considered the
+% same (up to metrics changes, which need not be small). It is called as
+% \begin{quote}
+% |\match_lines|\marg{line a}\marg{line b}
+% \end{quote}
+% \meta{line a} and \meta{line b} may be any amount of text which
+% eventually expands to the lines in question. |\match_lines| returns
+% its answer by setting the |_a_| switch to |false| (if the lines
+% match) or |true| (if the lines don't match).
+%
+% |\match_lines| also causes the |\first_dimen| and |\second_dimen|
+% registers, as well as the |_histogram_dimen_| switch to be updated,
+% so it can be immediately followed by a test of the metrics.
+% \begin{macrocode}
+\def\match_lines#1#2{
+ \first_integer=\z@
+ \second_integer=\z@
+ \first_dimen=\z@
+ \second_dimen=\z@
+ \x_cs\let{string-+}\empty_command
+ \x_cs\let{string--}\empty_command
+% \end{macrocode}
+% \begin{macrocode}
+ \def\sign{+}
+ #1\line_stop
+ \def\sign{-}
+ #2\line_stop
+% \end{macrocode}
+% \begin{macrocode}
+ \_a_false
+ \expandafter\ifx \csname cmd-+ \expandafter\endcsname
+ \csname cmd--\endcsname
+ \else \_a_true \fi
+ \ifnum \first_integer=\z@ \else \_a_true \fi
+ \ifnum \second_integer=\z@ \else \_a_true \fi
+ \expandafter\ifx \csname string-+ \expandafter\endcsname
+ \csname string--\endcsname
+ \else \_a_true \fi
+}
+% \end{macrocode}
+% \end{macro}
+
+% \begin{macro}{\try_matching}
+% \begin{macro}{\a_bufP}
+% \begin{macro}{\b_bufP}
+% The |\try_matching| descends through the buffert until the |_a_|
+% switch gets |false| or it has tried the bottommost lines in the
+% buffert. Since |\body| is already defined by the |\loop| in
+% |\process_lines|, |\try_matching| uses an explicit end recursion to
+% make the loop.
+% \begin{macrocode}
+\newcount\a_bufP
+\newcount\b_bufP
+\def\try_matching{
+ \global\advance \a_bufP \m@ne
+ \global\advance \b_bufP \m@ne
+% % Begin debug
+% \wlog{a_bufbase:~\the\a_bufbase\space\space\space
+% b_bufbase:~\the\b_bufbase}
+% \wlog{a_bufmid:~\the\a_bufmid\space\space\space
+% b_bufmid:~\the\b_bufmid}
+% \wlog{a_buftop:~\the\a_buftop\space\space\space
+% b_buftop:~\the\b_buftop}
+% \wlog{a_bufP:~\the\a_bufP\space\space\space
+% b_bufP:~\the\b_bufP}
+% \begingroup
+% \def\do_left_paren{(}\def\do_right_paren{)}
+% \wlog{a_line:~\a_line}
+% \wlog{b_buf_line:~\the_line{b}{\b_bufP}}
+% \wlog{b_line:~\b_line}
+% \wlog{a_buf_line:~\the_line{a}{\a_bufP}^^J}
+% \endgroup
+% % End debug
+ \match_lines{\a_line}{\the_line{b}{\b_bufP}}
+ \if_a_
+ \match_lines{\the_line{a}{\a_bufP}}{\b_line}
+ \if_a_ \else
+ \global\a_bufmid=\a_bufP
+ \fi
+ \else
+ \global\b_bufmid=\b_bufP
+ \fi
+ \ifnum \a_bufP>\a_bufbase \if_a_
+ \expandafter\expandafter\expandafter\try_matching
+ \fi \fi
+}
+% \end{macrocode}
+% \end{macro}
+
+% \begin{macro}{\report_mismatch}
+% The |\report_mismatch| macro does precisely what it says. It also increases
+% the \texttt{bufbase} and \texttt{lineno} registers to point at the
+% matching lines.
+% \begin{macrocode}
+\def\report_mismatch{
+ \begingroup
+ \def\do_left_paren{(}
+ \def\do_right_paren{)}
+ \wlog{Mismatch~in~first~file~(at~\the\a_lineno):}
+ \loop
+ \wlog{\the_line{a}{\a_bufbase}}
+ \ifnum \a_bufbase<\a_bufmid
+ \global\advance \a_bufbase \@ne
+ \global\advance \a_lineno \@ne
+ \repeat
+ \wlog{Match~found~at~line~\the\a_lineno.}
+ \wlog{Mismatch~in~second~file~(at~\the\b_lineno):}
+ \loop
+ \wlog{\the_line{b}{\b_bufbase}}
+ \ifnum \b_bufbase<\b_bufmid
+ \global\advance \b_bufbase \@ne
+ \global\advance \b_lineno \@ne
+ \repeat
+ \wlog{Match~found~at~line~\the\b_lineno.}
+ \endgroup
+ \glyphified_location
+ \ifnum 4>\compared_status
+ \global\chardef\compared_status=4
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+
+\def\glyphified_location{
+ \ifx \encoding_name\empty_command
+ \ifnum \m@ne<\last_character
+ \wlog{This~is~related~to~slot~\the\last_character.^^J}
+ \else
+ \wlog{This~is~in~the~header.^^J}
+ \fi
+ \else
+ \if_undefined{name-\encoding_name-\the\last_character}\then
+ \ifnum \last_character=\m@ne
+ \wlog{This~is~in~the~header.^^J}
+ \else
+ \wlog{This~is~related~to~slot~\the\last_character\space
+ (unencoded).^^J}
+ \fi
+ \else
+ \wlog{This~is~related~to~the~glyph~
+ \csname name-\encoding_name-\the\last_character\endcsname
+ .^^J}
+ \fi
+ \fi
+}
+% \begin{macro}{\compared_status}
+% |\compared_status| is a \meta{chardef token} which stores the
+% current status of the comparision, according to the following table
+% \begin{enumerate}
+% \item[0] The property lists are equal---there may be checksum
+% differences, but nothing else.
+% \item[1] The property lists are almost equal---there are
+% differences in the metrics, but these are within the |\tolerance|
+% level.
+% \item[2] The property lists are essentially equal---there are
+% differences in the metrics, but these are within the |\tolerance|
+% level, with the exception of some \texttt{CHARHT},
+% \texttt{CHARDP}, and \texttt{CHARIC} values.
+% \item[3] The property lists have metric differences---there are
+% metric differences not with category 2.
+% \item[4] The property lists are not completely matched.
+% \end{enumerate}
+% \end{macro}
+
+% \begin{macro}{\step_linenos}
+% The |\step_linenos| macro increments the |_lineno| line numbers. If
+% the current line was fetched from the buffert, then it also
+% increments the |_bufmid| and |_bufbase| registers, and checks
+% whether the buffert ended (in which case it is normalized to its
+% starting position, to conserve hash table space).
+% \begin{macrocode}
+\def\step_linenos{
+ \global\advance \a_lineno \@ne
+ \ifnum \a_bufmid=\a_buftop
+ \global\a_bufbase=\z@
+ \global\a_bufmid=\z@
+ \global\a_buftop=\m@ne
+ \else\ifnum \a_bufmid<\a_buftop
+ \global\advance \a_bufmid \@ne
+ \global\advance \a_bufbase \@ne
+ \fi\fi
+ \global\advance \b_lineno \@ne
+ \ifnum \b_bufmid=\b_buftop
+ \global\b_bufbase=\z@
+ \global\b_bufmid=\z@
+ \global\b_buftop=\m@ne
+ \else\ifnum \b_bufmid<\b_buftop
+ \global\advance \b_bufmid \@ne
+ \global\advance \b_bufbase \@ne
+ \fi\fi
+}
+% \end{macrocode}
+% \end{macro}
+
+
+\newdimen\first_dimen
+\newdimen\second_dimen
+\newcount\ht_hist_i
+\newcount\ht_hist_ii
+\newcount\ht_hist_iii
+\newcount\ht_hist_iv
+\newcount\dp_hist_i
+\newcount\dp_hist_ii
+\newcount\dp_hist_iii
+\newcount\dp_hist_iv
+\newcount\ic_hist_i
+\newcount\ic_hist_ii
+\newcount\ic_hist_iii
+\newcount\ic_hist_iv
+
+% \begin{macro}{\clear_histograms}
+% This macro clears all the histograms.
+% \begin{macrocode}
+\def\clear_histograms{
+ \global\ht_hist_i=\z@
+ \global\ht_hist_ii=\z@
+ \global\ht_hist_iii=\z@
+ \global\ht_hist_iv=\z@
+ \global\dp_hist_i=\z@
+ \global\dp_hist_ii=\z@
+ \global\dp_hist_iii=\z@
+ \global\dp_hist_iv=\z@
+ \global\ic_hist_i=\z@
+ \global\ic_hist_ii=\z@
+ \global\ic_hist_iii=\z@
+ \global\ic_hist_iv=\z@
+}
+% \enc{macrocode}
+% \end{macro}
+
+% \begin{macro}{\present_histograms}
+% This macro writes the histogram data to the log file.
+% \begin{macrocode}
+\def\present_histograms{
+ \wlog{\string\tolerance*~\space CHARHT~\space CHARDP~\space CHARIC}
+ \wlog{~\space\space 1--~\space\space 10\hist_to_eight{ht}{i}
+ \hist_to_eight{dp}{i}\hist_to_eight{ic}{i}}
+ \wlog{~\space 10--~\space 100\hist_to_eight{ht}{ii}
+ \hist_to_eight{dp}{ii}\hist_to_eight{ic}{ii}}
+ \wlog{~100--~1000\hist_to_eight{ht}{iii}\hist_to_eight{dp}{iii}
+ \hist_to_eight{ic}{iii}}
+ \wlog{1000--10000\hist_to_eight{ht}{iv}\hist_to_eight{dp}{iv}
+ \hist_to_eight{ic}{iv}}
+}
+\def\hist_to_eight#1#2{\x_cs\hist_to_eight_i{#1_hist_#2}}
+\def\hist_to_eight_i#1{
+ \ifnum #1<\@M
+ \four_spaces
+ \ifnum #1<\one_hundred
+ \space\space
+ \ifnum 10>#1 ~\fi
+ \else \ifnum #1<\one_thousand \space\fi \fi
+ \else
+ \ifnum 1000000>#1
+ \space\space
+ \ifnum 100000>#1 ~\fi
+ \else \ifnum 1000000>#1 ~\fi \fi
+ \fi
+ \the#1
+}
+% \end{macrocode}
+% \end{macro}
+
+
+% \begin{macro}{\metric_statistics}
+% \begin{macro}{\metric_origin}
+% The |\metric_statistics| macro takes care of comparing the metrics
+% by inspecting the values of |\first_dimen| and |\second_dimen|. It
+% has four classes of differences, which are represented by
+% |\compared_status| values 0--3: no difference, tolerable (almost no)
+% difference, histogrammed (essentially no) difference, and
+% non-tolerable difference. If a non-tolerable difference is found,
+% then the current lines are written to the log file. Histogrammed
+% differences causes the corresponding
+% |\|\meta{type}|_hist_|\meta{group} register to be incremented, and
+% tolerable differences only affect the value of |\compared_status|.
+%
+% The |\metric_origin| macro contains the \meta{type} of the metric
+% data. It is usually empty, but PL properties with metrics that have
+% histograms set it so that the correct histogram is updated.
+%
+% \begin{macrocode}
+\def\metric_statistics{
+ \_a_false
+ %
+ \ifdim \first_dimen<\z@ \first_dimen=-\first_dimen \fi
+ \ifdim \first_dimen=\z@
+ \else\ifdim \first_dimen<\tolerance
+ \ifnum 1>\compared_status
+ \global\chardef\compared_status=1
+ \fi
+ \else\ifx \metric_origin\empty_command
+ \_a_true
+ \else
+ \a_count=\@ne
+ \def\a_macro{10}
+ \loop\ifdim \a_macro\tolerance<\first_dimen
+ \edef\a_macro{\a_macro 0}
+ \advance \a_count \@ne
+ \repeat
+ \if_undefined{\metric_origin _hist_ \romannumeral\a_count}\then
+ \_a_true
+ \else
+ \global\advance \csname \metric_origin _hist_
+ \romannumeral\a_count \endcsname \@ne
+ \ifnum 2>\compared_status
+ \global\chardef\compared_status=2
+ \fi
+ \fi
+ \fi\fi\fi
+ %
+ \ifdim \second_dimen<\z@ \second_dimen=-\second_dimen \fi
+ \ifdim \second_dimen=\z@
+ \else\ifdim \second_dimen<\tolerance
+ \ifnum 1>\compared_status
+ \global\chardef\compared_status=1
+ \fi
+ \else\ifx \metric_origin\empty_command
+ \_a_true
+ \else
+ \a_count=\@ne
+ \def\a_macro{10}
+ \loop\ifdim \a_macro\tolerance<\second_dimen
+ \edef\a_macro{\a_macro 0}
+ \advance \a_count \@ne
+ \repeat
+ \if_undefined{\metric_origin _hist_ \romannumeral\a_count}\then
+ \_a_true
+ \else
+ \global\advance \csname \metric_origin _hist_
+ \romannumeral\a_count \endcsname \@ne
+ \ifnum 2>\compared_status
+ \global\chardef\compared_status=2
+ \fi
+ \fi
+ \fi\fi\fi
+ %
+ \if_a_
+ \ifnum 3>\compared_status
+ \global\chardef\compared_status=3
+ \fi
+ \begingroup
+ \def\do_left_paren{(}
+ \def\do_right_paren{)}
+ \wlog{Metric~differences~at~lines~\the\a_lineno\space
+ and~\the\b_lineno\space respectively:}
+ \wlog{\a_line}
+ \wlog{\b_line}
+ \endgroup
+ \glyphified_location
+ \fi
+}
+% \end{macrocode}
+% \end{macro}\end{macro}
+
+
+
+
+\newif\if_b_
+
+% \begin{macro}{\process_lines}
+% The |\process_lines| macro is the cheif executive in the comparision.
+% Its normal mode of operation is to retrive the next two lines from
+% the input files, match them, and update the metric differences
+% statistics. If the lines do not match, however, it starts building a
+% buffert of lines in which it searches for two matching lines. When
+% these two lines are found the mismatching portions of the files are
+% written to the log file, and the metric difference statistics are
+% updated for the two lines that matched.
+%
+% \begin{macrocode}
+\def\process_lines{
+ \get_next_line{a}
+ \get_next_line{b}
+ \match_lines{\a_line}{\b_line}
+ \if_a_
+% \end{macrocode}
+% Now the process of trying to find a match begins. At each step of
+% the search for a match, it tries all possible matches with the
+% lines read so far that haven't been tried at an earlier step.
+% \begin{macrocode}
+% \tracingmacros=\@ne\tracingcommands=\tw@ % DEBUG
+ \initialise_search
+ \loop
+ \get_next_line{a}
+ \get_next_line{b}
+ \add_to_buffert{a}
+ \add_to_buffert{b}
+ \match_lines{\a_line}{\b_line}
+ \if_a_
+ \global\a_bufP=\a_bufmid
+ \global\b_bufP=\b_bufmid
+ \try_matching
+ \fi
+ \if_a_
+ \global\advance \a_bufmid \@ne
+ \global\advance \b_bufmid \@ne
+ \ifnum \a_bufmid>\sixt@@n
+ \errmessage{Big~buffert.~\the\a_lineno[\the\a_filelineno]:
+ \the\b_lineno[\the\b_filelineno]}
+ \fi % DEBUG
+ \repeat
+ \report_mismatch
+% \tracingcommands=\z@\tracingmacros=\z@ % DEBUG
+% \end{macrocode}
+% \begin{macrocode}
+ \fi
+ \metric_statistics
+ \step_linenos
+ \par % DEBUG
+ \if \ifx \a_line\end_of_file_line
+ \ifx \b_line\end_of_file_line 1\else 0\fi\else 0\fi 0
+ % then
+ \expandafter\process_lines
+ \fi
+}
+% \end{macrocode}
+% \end{macro}
+
+\def\loadencoding#1{{
+ \def\do_slot{\x_cs\xdef{name-#1-\the\slot_number}{\slot_name}}
+ \inputetx{#1}
+}}
+
+% \begin{macro}{\comparePLs}
+% The |\comparePLs| command compares two property lists files. It is
+% geared against verifying that two different such files are as good
+% as equal, and it might take a very long time before it gives up on
+% trying to find any resemblance between them. It is furthermore only
+% meant to be used on (V)PL files generated by \package{TFtoPL} or
+% \package{VFtoVP}, because it assumes the property lists follow a
+% stricter syntax than \package{PLtoTF} and \package{VPtoVF} requires
+% them to. Finally it needs to be said that the comparision is rather
+% stupid in many respects, as it is completely line-oriented and
+% takes no notice of what kind of property list it is reading. This
+% may in some cases cause it to find ``matches'' between lines which
+% for syntactical reasons alone cannot match.
+%
+% |\comparePLs| is called as
+% \begin{quote}
+% |\comparePLs|\marg{first PL}\marg{second PL}\marg{encoding}
+% \end{quote}
+% where \meta{first PL} and \meta{second PL} are the complete names
+% (including extensions) of the files to compare. \meta{encoding} is
+% the name of the encoding to use when translating slots to glyph
+% names; leave it empty if you don't want to specify one. (One could
+% use the \texttt{CODINGSCHEME} property to determine the encoding in
+% that case, but this is not currently done). The slot to glyph
+% translation is only done to make it easier to locate the position of
+% some mismatch; it has not effect on the actual comparision.
+% \begin{macrocode}
+\newcount\last_character
+\def\comparePLs#1#2#3{{
+ \def\encoding_name{#3}
+ \last_character=\m@ne
+ \openin\a_read=#1\x_relax
+ \openin\b_read=#2\x_relax
+ \immediate\write\sixt@@n{#1~and^^J #2}
+ \pl_catcodes
+ \let\do_left_paren=\do_property
+ \let\do_right_paren=\empty_command
+ \global\chardef\compared_status=\z@
+ \clear_histograms
+ \global\a_filelineno=\@ne
+ \global\b_filelineno=\@ne
+ \global\a_lineno=\@ne
+ \global\b_lineno=\@ne
+ \global\a_bufbase=\z@
+ \global\b_bufbase=\z@
+ \global\a_bufmid=\z@
+ \global\b_bufmid=\z@
+ \global\a_buftop=\m@ne
+ \global\b_buftop=\m@ne
+ \process_lines
+ \closein\a_read
+ \closein\b_read
+ \ifcase \compared_status
+ \immediate\write\sixt@@n{are~equal.^^J}
+ \or
+ \immediate\write\sixt@@n{are~almost~equal.^^J}
+ \or
+ \immediate\write\sixt@@n{are~essentially~equal.}
+ \or
+ \immediate\write\sixt@@n{have~non-tolerated~metric~differences.}
+ \or
+ \immediate\write\sixt@@n{do~not~completely~match.}
+ \else
+ \immediate\write\sixt@@n{could~not~be~matched!}
+ \fi
+ \ifnum 1<\compared_status
+ \immediate\write\sixt@@n{See~log~file~for~specification.}
+ \present_histograms
+ \immediate\write\sixt@@n{}
+ \fi
+}}
+% \end{macrocode}
+% \end{macro}
+
+
+\begingroup
+ \catcode`\(=13 \catcode`\)=13
+ \gdef\pl_catcodes{
+ \catcode`\(=13 \def({\do_left_paren}
+ \catcode`\)=13 \def){\do_right_paren}
+ }
+\endgroup
+
+\def\do_property#1~{
+ \x_cs\edef{cmd-\sign}{#1}
+ \let\metric_origin=\empty_command
+ \x_cs\ifx{pl-#1}\x_relax
+ \expandafter\ignore_parens
+ \else
+ \csname pl-#1 \expandafter\endcsname
+ \fi
+}
+\def\pl_def_s#1(#2){\x_cs\def{pl-#1}#2~}
+\begingroup
+ \catcode`\!=13\lccode`\!=`\)
+\lowercase{\endgroup
+ \def\pl_def_p#1(#2){\x_cs\def{pl-#1}#2!}
+}
+\def\pl_let#1#2{
+ \expandafter\let
+ \csname pl-#1 \expandafter\endcsname \csname pl-#2 \endcsname
+}
+
+
+
+\newdimen\tolerance \tolerance=110sp
+
+% The following is for gobbling to the next unmatched right parenthesis.
+% The |\catcode| trick used by the PL-to-MTX converter's
+% |\ignore_parens| cannot be used since the characters are already
+% tokenized, but one can do something similar with an |\edef| since one
+% does not have to worry about the PL files containing material which
+% expands in an undesirable way.
+%
+% The |\line_stop| is so that linebreaks in the parenthesis being
+% gobbled will not cause total havok (although the parenthesis won't be
+% gobbled completely). It inserts end-of-group tokens until the |\edef|
+% is terminated, and then the |\afterassignment| token will close the
+% group and restore the normal definition.
+
+\def\ignore_parens{
+ \begingroup
+ \def\do_left_paren{{\iffalse}\fi}
+ \def\do_right_paren{\iffalse{\fi}}
+ \def\line_stop{\do_right_paren\line_stop}
+ \afterassignment\endgroup
+ \edef\a_macro{\iffalse}\fi
+}
+\def\line_stop{\x_relax}
+% \end{macrocode}
+%
+\begingroup
+ \catcode`\(=1
+ \catcode`\)=2
+ \gdef\pl_string{
+ \begingroup
+ \def\do_left_paren{(\iffalse)\fi}
+ \def\do_right_paren{\iffalse(\fi)}
+ \def\line_stop{\iffalse{\fi}\line_stop}
+ \afterassignment\pl_string_i
+ \edef\a_macro{\iffalse}\fi
+ }
+\endgroup
+\def\pl_string_i{
+ \expandafter\endgroup \expandafter\def
+ \csname string-\sign \expandafter\endcsname
+ \expandafter{\a_macro}
+}
+
+\def\pl_real#1{\sign#1\hundred_pt}
+\newdimen\hundred_pt \hundred_pt=100pt
+
+% Convert a PL int to a \TeX{} int, assuming it's prefixed
+% by |C|, |D|, |O|, or |H|.
+%
+% \begin{macrocode}
+\def\pl_int#1#2{
+ \sign \ifx#1C `#2
+ \else\ifx#1D #2
+ \else\ifx#1O '#2
+ \else\ifx#1H "#2
+ \else -1\errmessage{Unknown~PL~number~prefix~`#1'}
+ \fi\fi\fi\fi
+}
+% \end{macrocode}
+
+
+% \begin{macrocode}
+\pl_def_p{NEXTLARGER}(#1~#2){\advance \first_integer \pl_int{#1}{#2}}
+\pl_let{BOUNDARYCHAR}{NEXTLARGER}
+% \end{macrocode}
+%
+%
+% \begin{macrocode}
+\x_cs\let{pl-VTITLE}=\pl_string
+\pl_let{FONTNAME}{VTITLE}
+\pl_let{FONTAREA}{VTITLE}
+% \pl_let{CHECKSUM}{VTITLE}
+% % Not really a string, but unsigned numbers can become too large for TeX.
+% \pl_let{FONTCHECKSUM}{CHECKSUM}
+% Commented out since checksums vary too much.
+\pl_def_p{FONTAT}(R~#1){\advance \first_dimen \pl_real{#1}}
+\pl_let{FONTDSIZE}{FONTAT}
+\pl_let{SELECTFONT}{NEXTLARGER}
+\pl_let{SETCHAR}{NEXTLARGER}
+\pl_def_p{SETRULE}(R~#1~R~#2){
+ \advance \first_dimen \pl_real{#1}
+ \advance \second_dimen \pl_real{#2}
+}
+\x_cs\let{pl-POP}\empty_command
+\pl_let{PUSH}{POP}
+\pl_let{MOVERIGHT}{FONTAT}
+\pl_let{MOVELEFT}{FONTAT}
+\pl_let{MOVEUP}{FONTAT}
+\pl_let{MOVEDOWN}{FONTAT}
+\pl_let{SPECIAL}{VTITLE}
+\pl_let{SPECIALHEX}{VTITLE}
+% \end{macrocode}
+%
+%
+
+\pl_let{CODINGSCHEME}{VTITLE}
+\pl_let{DESIGNSIZE}{FONTAT}
+
+\def\pl_parameter#1#2#3{
+ \advance \first_integer \pl_int{#1}{#2}
+ \advance \first_dimen \pl_real{#3}
+}
+
+\pl_def_p{PARAMETER}(#1~#2~R~#3){\pl_parameter{#1}{#2}{#3}}
+
+\pl_def_p{SLANT}(R~#1){\pl_parameter{D}{1}{#1}}
+\pl_def_p{SPACE}(R~#1){\pl_parameter{D}{2}{#1}}
+\pl_def_p{STRETCH}(R~#1){\pl_parameter{D}{3}{#1}}
+\pl_def_p{SHRINK}(R~#1){\pl_parameter{D}{4}{#1}}
+\pl_def_p{XHEIGHT}(R~#1){\pl_parameter{D}{5}{#1}}
+\pl_def_p{QUAD}(R~#1){\pl_parameter{D}{6}{#1}}
+\pl_def_p{EXTRASPACE}(R~#1){\pl_parameter{D}{7}{#1}}
+
+\pl_def_p{NUM1}(R~#1){\pl_parameter{D}{8}{#1}}
+\pl_def_p{NUM2}(R~#1){\pl_parameter{D}{9}{#1}}
+\pl_def_p{NUM3}(R~#1){\pl_parameter{D}{10}{#1}}
+\pl_def_p{DENOM1}(R~#1){\pl_parameter{D}{11}{#1}}
+\pl_def_p{DENOM2}(R~#1){\pl_parameter{D}{12}{#1}}
+\pl_def_p{SUP1}(R~#1){\pl_parameter{D}{13}{#1}}
+\pl_def_p{SUP2}(R~#1){\pl_parameter{D}{14}{#1}}
+\pl_def_p{SUP3}(R~#1){\pl_parameter{D}{15}{#1}}
+\pl_def_p{SUB1}(R~#1){\pl_parameter{D}{16}{#1}}
+\pl_def_p{SUB2}(R~#1){\pl_parameter{D}{17}{#1}}
+\pl_def_p{SUPDROP}(R~#1){\pl_parameter{D}{18}{#1}}
+\pl_def_p{SUBDROP}(R~#1){\pl_parameter{D}{19}{#1}}
+\pl_def_p{DELIM1}(R~#1){\pl_parameter{D}{20}{#1}}
+\pl_def_p{DELIM2}(R~#1){\pl_parameter{D}{21}{#1}}
+\pl_def_p{AXISHEIGHT}(R~#1){\pl_parameter{D}{22}{#1}}
+
+\pl_let{DEFAULTRULETHICKNESS}{NUM1}
+\pl_let{BIGOPSPACING1}{NUM2}
+\pl_let{BIGOPSPACING2}{NUM3}
+\pl_let{BIGOPSPACING3}{DENOM1}
+\pl_let{BIGOPSPACING4}{DENOM2}
+\pl_let{BIGOPSPACING5}{SUP1}
+
+\def\boundarychar_name{BOUNDARYCHAR}
+\pl_def_s{LABEL}(#1){
+ \def\a_macro{#1}
+ \ifx \a_macro\boundarychar_name
+ \x_cs\let{string-\sign}\a_macro
+ \else
+ \def\a_macro{\csname pl-LABEL(i\endcsname #1~}
+ \expandafter\a_macro
+ \fi
+}
+\pl_def_p{LABEL(i}(#1~#2){
+ \last_character=\first_integer
+ \advance \first_integer \pl_int{#1}{#2}
+}
+\pl_def_p{LIG}(#1~#2~#3~#4){
+ \advance \first_integer \pl_int{#1}{#2}
+ \advance \second_integer \pl_int{#3}{#4}
+}
+\pl_let{/LIG}{LIG}
+\pl_let{/LIG>}{LIG}
+\pl_let{LIG/}{LIG}
+\pl_let{LIG/>}{LIG}
+\pl_let{/LIG/}{LIG}
+\pl_let{/LIG/>}{LIG}
+\pl_let{/LIG/>>}{LIG}
+
+\pl_let{HEADER}{LIG}
+
+% \def\pl_lig#1~#2~#3~#4~#5~{
+% \x_cs\def{string-\sign}{#1}
+% \def\LIG#1~{
+% \if\ifx #1C 0
+% \else\ifx #1D 0
+% \else\ifx #1H 0
+% \else\ifx #1O 0 \else 1\fi\fi\fi\fi 0
+% % then
+% \expandafter\both_of_two
+% \else
+% \expandafter\first_of_two
+% \fi{\pl_lig LIG}{~}#1~
+% }
+% \def\/{\pl_lig/}
+
+\pl_let{KRN}{PARAMETER}
+\pl_let{SKIP}{NEXTLARGER}
+
+\pl_def_s{CHARACTER}(#1~#2){
+ \last_character=\first_integer
+ \advance \first_integer \pl_int{#1}{#2}
+}
+\pl_let{CHARWD}{FONTAT}
+\pl_def_p{CHARHT}(R~#1){
+ \def\metric_origin{ht}
+ \advance \first_dimen \pl_real{#1}
+}
+\pl_def_p{CHARDP}(R~#1){
+ \def\metric_origin{dp}
+ \advance \first_dimen \pl_real{#1}
+}
+\pl_def_p{CHARIC}(R~#1){
+ \def\metric_origin{ic}
+ \advance \first_dimen \pl_real{#1}
+}
+
+\pl_let{TOP}{NEXTLARGER}
+\pl_let{MID}{NEXTLARGER}
+\pl_let{BOT}{NEXTLARGER}
+\pl_let{REP}{NEXTLARGER}
+
+\pl_let{FONTDIMEN}{POP}
+\pl_let{LIGTABLE}{POP}
+\pl_let{VARCHAR}{POP}
+\pl_def_s{MAPFONT}(#1~#2){\advance \first_integer \pl_int{#1}{#2}}
+\pl_let{MAP}{POP}
+
+
+% \begin{macrocode}
+\catcode`\@=\atcatcode
+\catcode`\^^M=\nlcatcode
+\catcode`\ =\spacecatcode
+\catcode`\~=\tildecatcode
+\catcode`\_=\underscorecatcode
+% \end{macrocode}
diff --git a/fonts/utilities/fontinst/test/comparepls.tex b/fonts/utilities/fontinst/test/comparepls.tex
new file mode 100644
index 0000000000..a735a34ed7
--- /dev/null
+++ b/fonts/utilities/fontinst/test/comparepls.tex
@@ -0,0 +1,73 @@
+\input fontinst.sty
+\input comparemetrics.sty
+
+% % \tracingmacros=1\tracingcommands=2
+% \comparePLs{cmr5.pl}{cmr5.pl}
+%
+% \bye
+
+\tracingstats=1
+
+\def\oldf{::efficiency:saved:v1.912:}
+\def\newf{::efficiency:saved:v1.913:}
+
+\loadencoding{t1}
+\loadencoding{ot1}
+\loadencoding{ts1}
+\loadencoding{8r}
+
+\comparePLs{\oldf padb7t.vpl}{\newf padb7t.vpl}{ot1} %OK 11sp
+\comparePLs{\oldf padb8c.vpl}{\newf padb8c.vpl}{ts1} %OK 11sp
+\comparePLs{\oldf padb8t.vpl}{\newf padb8t.vpl}{t1} %OK 11sp
+\comparePLs{\oldf padbc7t.vpl}{\newf padbc7t.vpl}{ot1} %OK 11sp
+\comparePLs{\oldf padbc8t.vpl}{\newf padbc8t.vpl}{t1}
+\comparePLs{\oldf padbi7t.vpl}{\newf padbi7t.vpl}{ot1}
+\comparePLs{\oldf padbi8c.vpl}{\newf padbi8c.vpl}{ts1}
+\comparePLs{\oldf padbi8t.vpl}{\newf padbi8t.vpl}{t1}
+\comparePLs{\oldf padbo7t.vpl}{\newf padbo7t.vpl}{ot1} %OK 11sp
+\comparePLs{\oldf padbo8c.vpl}{\newf padbo8c.vpl}{ts1} %OK 11sp
+\comparePLs{\oldf padbo8t.vpl}{\newf padbo8t.vpl}{t1}
+\comparePLs{\oldf padr7t.vpl}{\newf padr7t.vpl}{ot1} %OK 11sp
+\comparePLs{\oldf padr8c.vpl}{\newf padr8c.vpl}{ts1} %OK 11sp
+\comparePLs{\oldf padr8t.vpl}{\newf padr8t.vpl}{t1} %OK 11sp
+\comparePLs{\oldf padrc7t.vpl}{\newf padrc7t.vpl}{ot1} %OK 11sp
+\comparePLs{\oldf padrc8t.vpl}{\newf padrc8t.vpl}{t1} %OK 11sp
+\comparePLs{\oldf padri7t.vpl}{\newf padri7t.vpl}{ot1}
+\comparePLs{\oldf padri8c.vpl}{\newf padri8c.vpl}{ts1} %OK 11sp
+\comparePLs{\oldf padri8t.vpl}{\newf padri8t.vpl}{t1}
+\comparePLs{\oldf padro7t.vpl}{\newf padro7t.vpl}{ot1} %OK 11sp
+\comparePLs{\oldf padro8c.vpl}{\newf padro8c.vpl}{ts1} %OK 11sp
+\comparePLs{\oldf padro8t.vpl}{\newf padro8t.vpl}{t1}
+\comparePLs{\oldf pads7t.vpl}{\newf pads7t.vpl}{ot1}
+\comparePLs{\oldf pads8c.vpl}{\newf pads8c.vpl}{ts1}
+\comparePLs{\oldf pads8t.vpl}{\newf pads8t.vpl}{t1}
+\comparePLs{\oldf padsc7t.vpl}{\newf padsc7t.vpl}{ot1}
+\comparePLs{\oldf padsc8t.vpl}{\newf padsc8t.vpl}{t1} %OK 11sp
+\comparePLs{\oldf padsi7t.vpl}{\newf padsi7t.vpl}{ot1}
+\comparePLs{\oldf padsi8c.vpl}{\newf padsi8c.vpl}{ts1} %OK 11sp
+\comparePLs{\oldf padsi8t.vpl}{\newf padsi8t.vpl}{t1}
+\comparePLs{\oldf padso7t.vpl}{\newf padso7t.vpl}{ot1}
+\comparePLs{\oldf padso8c.vpl}{\newf padso8c.vpl}{ts1}
+\comparePLs{\oldf padso8t.vpl}{\newf padso8t.vpl}{t1}
+
+\comparePLs{\oldf padb8a.pl}{\newf padb8a.pl}{}
+\comparePLs{\oldf padb8r.pl}{\newf padb8r.pl}{8r}
+\comparePLs{\oldf padbi8a.pl}{\newf padbi8a.pl}{}
+\comparePLs{\oldf padbi8r.pl}{\newf padbi8r.pl}{8r}
+\comparePLs{\oldf padbo8r.pl}{\newf padbo8r.pl}{8r}
+\comparePLs{\oldf padr8a.pl}{\newf padr8a.pl}{}
+\comparePLs{\oldf padr8r.pl}{\newf padr8r.pl}{8r}
+\comparePLs{\oldf padrc8a.pl}{\newf padrc8a.pl}{}
+\comparePLs{\oldf padrc8r.pl}{\newf padrc8r.pl}{8r}
+\comparePLs{\oldf padri8a.pl}{\newf padri8a.pl}{}
+\comparePLs{\oldf padri8r.pl}{\newf padri8r.pl}{8r}
+\comparePLs{\oldf padro8r.pl}{\newf padro8r.pl}{8r}
+\comparePLs{\oldf pads8a.pl}{\newf pads8a.pl}{}
+\comparePLs{\oldf pads8r.pl}{\newf pads8r.pl}{8r}
+\comparePLs{\oldf padsc8a.pl}{\newf padsc8a.pl}{}
+\comparePLs{\oldf padsc8r.pl}{\newf padsc8r.pl}{8r}
+\comparePLs{\oldf padsi8a.pl}{\newf padsi8a.pl}{}
+\comparePLs{\oldf padsi8r.pl}{\newf padsi8r.pl}{8r}
+\comparePLs{\oldf padso8r.pl}{\newf padso8r.pl}{8r}
+
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/fadrr.mtx b/fonts/utilities/fontinst/test/fadrr.mtx
new file mode 100644
index 0000000000..e9ce1b2e58
--- /dev/null
+++ b/fonts/utilities/fontinst/test/fadrr.mtx
@@ -0,0 +1,51 @@
+% Filename: fadrr.mtx
+% Created by: tclsh pstofont Knuth:MPtoType1:Test:fadrr
+% Created using: pstofont::write_MTX Knuth:MPtoType1:Test:fadrr.mtx
+%
+% This file contains the metric information about the font
+% AGaramondAdditions-Regular, in a format used by fontinst.
+
+\relax
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+\begin{document}
+\title{The \textit{AGaramondAdditions-Regular} font metrics}
+\date{2002-08-05 13.22.05}
+\maketitle
+
+\begin{abstract}
+ The AGaramond Additions family of fonts is free software;
+ you can redistribute it and/or modify it under the terms
+ of the Design Science License.
+ As a special exception, permission is granted to include
+ this font program in a Postscript, PDF, or similar file
+ that consists of a document that contains text to be
+ displayed or printed using this font, regardless of the
+ conditions or license applying to the document itself.
+\end{abstract}
+
+\metrics
+\needsfontinstversion{1.333}
+\setcommand\storemapdata#1#2#3{}
+\setcommand\setglyphbb#1#2#3#4#5{}
+\storemapdata{fadrr}{\fromafm{fadrr}{AGaramondAdditions-Regular}}{}
+\setint{ascender}{715}
+\setint{capheight}{660}
+\setint{descender_neg}{-258}
+\setint{xheight}{397}
+\setint{maxheight}{664}
+\setint{maxdepth}{4}
+\setint{italicslant}{0}
+\setnotglyph{.notdef}{fadrr}{10pt}{-1}{400}{0}{0}{0}
+\setglyphbb{.notdef}{0}{0}{0}{0}
+\setrawglyph{Gamma}{fadrr}{10pt}{71}{538}{660}{0}{0}
+\setglyphbb{Gamma}{40}{-4}{493}{664}
+\setrawglyph{I}{fadrr}{10pt}{73}{338}{660}{0}{0}
+\setglyphbb{I}{41}{-4}{297}{664}
+\setrawglyph{Pi}{fadrr}{10pt}{80}{806}{660}{0}{0}
+\setglyphbb{Pi}{40}{-4}{766}{664}
+\setrawglyph{uni0428}{fadrr}{10pt}{87}{962}{660}{0}{0}
+\setglyphbb{uni0428}{40}{-4}{922}{664}
+
+\endmetrics
+\end{document}
diff --git a/fonts/utilities/fontinst/test/multislot-test.tex b/fonts/utilities/fontinst/test/multislot-test.tex
new file mode 100644
index 0000000000..f557b47aa2
--- /dev/null
+++ b/fonts/utilities/fontinst/test/multislot-test.tex
@@ -0,0 +1,16 @@
+\input fontinst.sty
+\input multislot.sty
+
+\mathchardef\apa=0
+\catcode`\_=11
+\add_to\pre_second_etx_pass_hook{\mathchardef\apa=1}
+\catcode`\_=\underscorecatcode
+
+\transformfont{ptmr8r}{\reencodefont{8r}{\fromafm{ptmr8a}}}
+
+\installfonts
+ \installfamily{XX}{ptm}{}
+ \installfont{ptmr5z}{ptmr8r,psyr,latin}{multislot} {XX}{ptm}{m}{n}{}
+\endinstallfonts
+
+\bye
diff --git a/fonts/utilities/fontinst/test/multislot.etx b/fonts/utilities/fontinst/test/multislot.etx
new file mode 100644
index 0000000000..962080bff8
--- /dev/null
+++ b/fonts/utilities/fontinst/test/multislot.etx
@@ -0,0 +1,54 @@
+\relax
+\encoding
+\immediate\write16{\the\csname slot_number\endcsname,\the\csname
+slot_index\endcsname}
+% \ifnum 1=\apa
+% \expandafter\show \csname name-0\endcsname
+% % \tracingmacros=1
+% % \tracingcommands=2
+% \fi
+\inputetx{ot1}
+\immediate\write16{\the\csname slot_number\endcsname,\the\csname
+slot_index\endcsname}
+
+% \tracingmacros=1
+% \tracingcommands=2
+
+\nextslot{32}
+\setrightboundary{space}
+
+\nextslot{172}
+\setrightboundary{omega}
+
+\setleftboundary{space}
+\endsetleftboundary
+
+% \tracingcommands=0
+% \tracingmacros=0
+
+
+\immediate\write16{\the\csname slot_number\endcsname,\the\csname
+slot_index\endcsname}
+
+
+\inputetx{t1}
+
+\immediate\write16{\the\csname slot_number\endcsname,\the\csname
+slot_index\endcsname}
+
+
+\setleftboundary{compwordmark}
+\endsetleftboundary
+
+
+\setcommand\resetslot#1\endsetslot{}
+
+\nextslot{`l}
+\resetslot{lambda}
+ \comment{The letter `$\lambda$'.}
+\endsetslot
+
+\immediate\write16{\the\csname slot_number\endcsname,\the\csname
+slot_index\endcsname}
+
+\endencoding
diff --git a/fonts/utilities/fontinst/test/omsdraft.etx b/fonts/utilities/fontinst/test/omsdraft.etx
new file mode 100644
index 0000000000..3e60ee0a56
--- /dev/null
+++ b/fonts/utilities/fontinst/test/omsdraft.etx
@@ -0,0 +1,871 @@
+%%% ====================================================================
+%%% @TeX-font-encoding-file{
+%%% author = "Alan Jeffrey and Ulrik Vieth and
+%%% Lars Hellstr{\"o}m",
+%%% version = "1.928",
+%%% date = "2004-11-30",
+%%% time = "14:45:29 +01:00",
+%%% filename = "oms.etx",
+%%% email = "fontinst@tug.org",
+%%% URL = "http://www.tug.org/applications/fontinst/index.html",
+%%% checksum = "",
+%%% codetable = "ISO/ASCII",
+%%% keywords = "encoding, math, TeX, PostScript",
+%%% supported = "yes",
+%%% abstract = "This is (an incomplete) specification of the
+%%% old math symbol encoding as a TeX font encoding
+%%% file, for use with the fontinst utility.",
+%%% package = "fontinst",
+%%% dependencies = "fontinst.sty, fontdoc.sty",
+%%% }
+%%% ====================================================================
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage[specification]{fontdoc}[2004/11/24]
+
+\title{The \TeX\ math symbol encoding vector}
+\author{Alan Jeffrey\and Ulrik Vieth\and Lars Hellstr\"om}
+\date{24 November 2004\\Version 1.928}
+
+\begin{document}
+\maketitle
+
+\section{Introduction}
+
+This document describes the \TeX\ math symbol (OMS) encoding.
+\emph{Or rather, it describes part of that encoding---a part which
+includes some characters beyond the Basic Multilingual Plane. The
+primary purpose of creating this file was to test that case of the
+ETX-to-CMap converter.}
+
+\showbranches
+\encoding
+
+\needsfontinstversion{1.928}
+
+
+\begincomment
+\section{Ordinary characters}
+There are 128 ordinary characters in this encoding.
+\endcomment
+
+
+\begincomment
+\subsection{Operations}
+\endcomment
+
+
+\nextslot{0}
+\setslot{minus}
+ \Unicode{2212}{MINUS SIGN}
+\endsetslot
+
+\setslot{periodcentered}
+ \Unicode{22C5}{DOT OPERATOR}
+ \comment{This is called `\texttt{dotmath}' in Adobe Symbol.}
+\endsetslot
+
+\setslot{multiply}
+ \Unicode{00D7}{MULTIPLICATION SIGN}
+\endsetslot
+
+\setslot{asteriskmath}
+ \Unicode{2217}{ASTERISK OPERATOR}
+\endsetslot
+
+\setslot{divide}
+ \Unicode{00F7}{DIVISION SIGN}
+\endsetslot
+
+\setslot{diamondmath}
+ \Unicode{22C4}{DIAMOND OPERATOR}
+\endsetslot
+
+\setslot{plusminus}
+ \Unicode{00B1}{PLUS-MINUS SIGN}
+\endsetslot
+
+\setslot{minusplus}
+ \Unicode{2213}{MINUS-OR-PLUS SIGN}
+\endsetslot
+
+\setslot{circleplus}
+ \Unicode{2295}{CIRCLED PLUS}
+\endsetslot
+
+\setslot{circleminus}
+ \Unicode{2296}{CIRCLED MINUS}
+\endsetslot
+
+\setslot{circlemultiply}
+ \Unicode{2297}{CIRCLED TIMES}
+\endsetslot
+
+\setslot{circledivide}
+ \Unicode{2298}{CIRCLED DIVISION SLASH}
+\endsetslot
+
+\setslot{circledot}
+ \Unicode{2299}{CIRCLED DOT OPERATOR}
+\endsetslot
+
+\setslot{circlecopyrt}
+ \Unicode{25CB}{WHITE CIRCLE}
+ \Unicode{20DD}{COMBINING ENCLOSING CIRCLE}
+ \comment{The large circle symbol `$\bigcirc$', also used for building
+ the copyright symbol `\copyright'.}
+\endsetslot
+
+\setslot{openbullet}
+ \Unicode{2218}{RING OPERATOR}
+\endsetslot
+
+\setslot{bullet}
+ \Unicode{2219}{BULLET OPERATOR}
+\endsetslot
+
+
+\begincomment
+\subsection{Calligraphic alphabet}
+\endcomment
+
+\nextslot{65}
+\setslot{A}
+ \Unicode{1D49C}{MATHEMATICAL SCRIPT CAPITAL A}
+\endsetslot
+
+\setslot{B}
+ \Unicode{212C}{SCRIPT CAPITAL B}
+\endsetslot
+
+\setslot{C}
+ \Unicode{1D49E}{MATHEMATICAL SCRIPT CAPITAL C}
+\endsetslot
+
+\setslot{D}
+ \Unicode{1D49F}{MATHEMATICAL SCRIPT CAPITAL D}
+\endsetslot
+
+\setslot{E}
+ \Unicode{2130}{SCRIPT CAPITAL E}
+\endsetslot
+
+\setslot{F}
+ \Unicode{2131}{SCRIPT CAPITAL F}
+\endsetslot
+
+\setslot{G}
+ \Unicode{1D4A2}{MATHEMATICAL SCRIPT CAPITAL G}
+\endsetslot
+
+\setslot{H}
+ \Unicode{210B}{SCRIPT CAPITAL H}
+\endsetslot
+
+\setslot{I}
+ \Unicode{2110}{SCRIPT CAPITAL I}
+\endsetslot
+
+\setslot{J}
+ \Unicode{1D4A5}{MATHEMATICAL SCRIPT CAPITAL J}
+\endsetslot
+
+\setslot{K}
+ \Unicode{1D4A6}{MATHEMATICAL SCRIPT CAPITAL K}
+\endsetslot
+
+\setslot{L}
+ \Unicode{2112}{SCRIPT CAPITAL L}
+\endsetslot
+
+\setslot{M}
+ \Unicode{2133}{SCRIPT CAPITAL M}
+\endsetslot
+
+\setslot{N}
+ \Unicode{1D4A9}{MATHEMATICAL SCRIPT CAPITAL N}
+\endsetslot
+
+\setslot{O}
+ \Unicode{1D4AA}{MATHEMATICAL SCRIPT CAPITAL O}
+\endsetslot
+
+\setslot{P}
+ \Unicode{1D4AB}{MATHEMATICAL SCRIPT CAPITAL P}
+\endsetslot
+
+\setslot{Q}
+ \Unicode{1D4AC}{MATHEMATICAL SCRIPT CAPITAL Q}
+\endsetslot
+
+\setslot{R}
+ \Unicode{211B}{SCRIPT CAPITAL R}
+\endsetslot
+
+\setslot{S}
+ \Unicode{1D4AE}{MATHEMATICAL SCRIPT CAPITAL S}
+\endsetslot
+
+\setslot{T}
+ \Unicode{1D4AF}{MATHEMATICAL SCRIPT CAPITAL T}
+\endsetslot
+
+\setslot{U}
+ \Unicode{1D4B0}{MATHEMATICAL SCRIPT CAPITAL U}
+\endsetslot
+
+\setslot{V}
+ \Unicode{1D4B1}{MATHEMATICAL SCRIPT CAPITAL V}
+\endsetslot
+
+\setslot{W}
+ \Unicode{1D4B2}{MATHEMATICAL SCRIPT CAPITAL W}
+\endsetslot
+
+\setslot{X}
+ \Unicode{1D4B3}{MATHEMATICAL SCRIPT CAPITAL X}
+\endsetslot
+
+\setslot{Y}
+ \Unicode{1D4B4}{MATHEMATICAL SCRIPT CAPITAL Y}
+\endsetslot
+
+\setslot{Z}
+ \Unicode{1D4B5}{MATHEMATICAL SCRIPT CAPITAL Z}
+\endsetslot
+
+
+
+\begincomment
+\subsection{Card suits}
+\endcomment
+
+\nextslot{124}
+\setslot{club}
+ \Unicode{2663}{BLACK CLUB SUIT}
+\endsetslot
+
+\setslot{diamond}
+ \Unicode{2662}{WHITE DIAMOND SUIT}
+\endsetslot
+
+\setslot{heart}
+ \Unicode{2661}{WHITE HEART SUIT}
+\endsetslot
+
+\setslot{spade}
+ \Unicode{2660}{BLACK SPADE SUIT}
+\endsetslot
+
+
+
+\begincomment
+\section{Font dimensions}
+\endcomment
+
+\setfontdimen{1}{italicslant} % italic slant
+\setfontdimen{2}{interword} % interword space
+\setfontdimen{3}{stretchword} % interword stretch
+\setfontdimen{4}{shrinkword} % interword shrink
+\setfontdimen{5}{xheight} % x-height
+\setfontdimen{6}{quad} % quad
+\setfontdimen{7}{extraspace} % extra space after .
+
+\setfontdimen{8}{num1} % num 1
+\setfontdimen{9}{num2} % num 2
+\setfontdimen{10}{num3} % num 3
+\setfontdimen{11}{denom1} % denom 1
+\setfontdimen{12}{denom2} % denom 2
+\setfontdimen{13}{sup1} % sup 1
+\setfontdimen{14}{sup2} % sup 2
+\setfontdimen{15}{sup3} % sup 3
+\setfontdimen{16}{sub1} % sub 1
+\setfontdimen{17}{sub2} % sub 2
+\setfontdimen{18}{supdrop} % supdrop
+\setfontdimen{19}{subdrop} % subdrop
+\setfontdimen{20}{delim1} % delim 1
+\setfontdimen{21}{delim2} % delim 2
+\setfontdimen{22}{axisheight} % math axis height
+
+
+
+\begincomment
+\section{Default values}
+\endcomment
+
+\setstr{codingscheme}{TEX MATH SYMBOLS}
+\setstr{encodingname}{TeXMathSymbolEncoding}
+
+
+\endencoding
+
+
+
+\end{document}
+
+%%%%% Old stuff:
+
+\begincomment
+\section{The encoding}
+\endcomment
+
+\setslot{minus}
+ \comment{The subtraction symbol `$-$'.}
+\endsetslot
+
+\setslot{periodcentered}
+ \comment{The centered dot symbol `$\cdot$'.
+ It is called `dotmath' in Adobe Symbol.}
+\endsetslot
+
+\setslot{multiply}
+ \comment{The multiplication symbol `$\times$'.}
+\endsetslot
+
+\setslot{asteriskmath}
+ \comment{The centered asterisk symbol `$*$'.}
+\endsetslot
+
+\setslot{divide}
+ \comment{The division symbol `$\plaindiv$'.}
+\endsetslot
+
+\setslot{diamondmath}
+ \comment{The diamond symbol `$\diamond$'.}
+\endsetslot
+
+\setslot{plusminus}
+ \comment{The plus or minus symbol `$\pm$'.}
+\endsetslot
+
+\setslot{minusplus}
+ \comment{The minus or plus symbol `$\mp$'.}
+\endsetslot
+
+\setslot{circleplus}
+ \comment{The circled plus symbol `$\oplus$'.}
+\endsetslot
+
+\setslot{circleminus}
+ \comment{The circled minus symbol `$\ominus$'.}
+\endsetslot
+
+\setslot{circlemultiply}
+ \comment{The circled multiplication symbol `$\otimes$'.}
+\endsetslot
+
+\setslot{circledivide}
+ \comment{The circled oblique symbol `$\oslash$'.}
+\endsetslot
+
+\setslot{circledot}
+ \comment{The circled dot symbol `$\odot$'.}
+\endsetslot
+
+\setslot{circlecopyrt}
+ \comment{The large circle symbol `$\bigcirc$' used for building the
+ copyright symbol `\copyright'.}
+\endsetslot
+
+\setslot{openbullet}
+ \comment{The circle symbol `$\circ$'.}
+\endsetslot
+
+\setslot{bullet}
+ \comment{The bullet symbol `$\bullet$'.}
+\endsetslot
+
+\setslot{equivasymptotic}
+ \comment{The asymptotic equals symbol `$\asymp$'.}
+\endsetslot
+
+\setslot{equivalence}
+ \comment{The equivalence symbol `$\equiv$'.}
+\endsetslot
+
+\setslot{reflexsubset}
+ \comment{The subset or equals symbol `$\subseteq$'.}
+\endsetslot
+
+\setslot{reflexsuperset}
+ \comment{The superset or equals symbol `$\supseteq$'.}
+\endsetslot
+
+\setslot{lessequal}
+ \comment{The less or equals symbol `$\leq$'.}
+\endsetslot
+
+\setslot{greaterequal}
+ \comment{The greater or equals symbol `$\geq$'.}
+\endsetslot
+
+\setslot{precedesequal}
+ \comment{The precedes or equals symbol `$\preceq$'.}
+\endsetslot
+
+\setslot{followsequal}
+ \comment{The follows or equals symbol `$\succeq$'.}
+\endsetslot
+
+\setslot{similar}
+ \comment{The similar symbol `$\sim$'.}
+\endsetslot
+
+\setslot{approxequal}
+ \comment{The approximate equality symbol `$\approx$'.}
+\endsetslot
+
+\setslot{propersubset}
+ \comment{The subset symbol `$\subset$'.}
+\endsetslot
+
+\setslot{propersuperset}
+ \comment{The superset symbol `$\supset$'.}
+\endsetslot
+
+\setslot{lessmuch}
+ \comment{The much less symbol `$\ll$'.}
+\endsetslot
+
+\setslot{greatermuch}
+ \comment{The much greater symbol `$\gg$'.}
+\endsetslot
+
+\setslot{precedes} % was curlyless
+ \comment{The precedes symbol `$\prec$'.}
+\endsetslot
+
+\setslot{follows} % was curlygreater
+ \comment{The follows symbol `$\succ$'.}
+\endsetslot
+
+\setslot{arrowleft}
+ \comment{The left arrow symbol `$\leftarrow$'.}
+\endsetslot
+
+\setslot{arrowright}
+ \comment{The right arrow symbol `$\rightarrow$'.}
+\endsetslot
+
+\setslot{arrowup}
+ \comment{The up arrow symbol `$\uparrow$'.}
+\endsetslot
+
+\setslot{arrowdown}
+ \comment{The down arrow symbol `$\downarrow$'.}
+\endsetslot
+
+\setslot{arrowboth}
+ \comment{The horizontal arrow symbol `$\leftrightarrow$'.}
+\endsetslot
+
+\setslot{arrownortheast}
+ \comment{The north-east arrow symbol `$\nearrow$'.}
+\endsetslot
+
+\setslot{arrowsoutheast}
+ \comment{The south-east arrow symbol `$\searrow$'.}
+\endsetslot
+
+\setslot{similarequal}
+ \comment{The similar or equal symbol `$\simeq$'.}
+\endsetslot
+
+\setslot{arrowdblleft}
+ \comment{The double left arrow symbol `$\Leftarrow$'.}
+\endsetslot
+
+\setslot{arrowdblright}
+ \comment{The double right arrow symbol `$\Rightarrow$'.}
+\endsetslot
+
+\setslot{arrowdblup}
+ \comment{The double up arrow symbol `$\Uparrow$'.}
+\endsetslot
+
+\setslot{arrowdbldown}
+ \comment{The double down arrow symbol `$\Downarrow$'.}
+\endsetslot
+
+\setslot{arrowdblboth}
+ \comment{The double horizontal arrow symbol `$\Leftrightarrow$'.}
+\endsetslot
+
+\setslot{arrownorthwest}
+ \comment{The north-west arrow symbol `$\nwarrow$'.}
+\endsetslot
+
+\setslot{arrowsouthwest}
+ \comment{The south-west arrow symbol `$\swarrow$'.}
+\endsetslot
+
+\setslot{proportional}
+ \comment{The proportional symbol `$\propto$'.}
+\endsetslot
+
+\setslot{prime}
+ \comment{The prime symbol `$\prime$'.}
+\endsetslot
+
+\setslot{infinity}
+ \comment{The infinity symbol `$\infty$'.}
+\endsetslot
+
+\setslot{element}
+ \comment{The set membership symbol `$\in$'.}
+\endsetslot
+
+\setslot{owner}
+ \comment{The backwards set membership symbol `$\ni$'.}
+\endsetslot
+
+\setslot{triangle}
+ \comment{The upwards triangle symbol `$\bigtriangleup$'.}
+\endsetslot
+
+\setslot{triangleinv}
+ \comment{The downwards triangle symbol `$\bigtriangledown$'.}
+\endsetslot
+
+\setslot{negationslash}
+ \comment{The negation slash symbol, used to construct
+ negated relations or arrows such as `$\not=$'.}
+\endsetslot
+
+\setslot{mapstochar}
+ \comment{The maps to building block symbol `$\mapstochar$',
+ used to build `$\mapsto$'.}
+\endsetslot
+
+\setslot{universal}
+ \comment{The universal quantification symbol `$\forall$'.}
+\endsetslot
+
+\setslot{existential}
+ \comment{The existential quantification symbol `$\exists$'.}
+\endsetslot
+
+\setslot{logicalnot}
+ \comment{The negation symbol `$\plainneg$'.}
+\endsetslot
+
+\setslot{emptysetstress}
+ \comment{The `stressed' empty set symbol `$\emptyset$', which should
+ look like a zero with a slash. The `emptyset' symbol is a circle
+ with a slash.}
+\endsetslot
+
+\setslot{Rfraktur}
+ \comment{The upper case Fraktur R symbol `$\Re$'. It is called
+ `Rfractur' rather than `Rfraktur' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{Ifraktur}
+ \comment{The upper case Fraktur I symbol `$\Im$'. It is called
+ `Ifractur' rather than `Ifraktur' in MathTime and Lucida New Math.}
+\endsetslot
+
+\setslot{latticetop}
+ \comment{The inverted perpendicular symbol `$\top$'.}
+\endsetslot
+
+\setslot{perpendicular}
+ \comment{The perpendicular symbol `$\perp$'.}
+\endsetslot
+
+\setslot{aleph}
+ \comment{The aleph symbol `$\aleph$'.}
+\endsetslot
+
+\setslot{A}
+ \comment{The calligraphic letter `$\mathcal{A}$'.}
+\endsetslot
+
+\setslot{B}
+ \comment{The calligraphic letter `$\mathcal{B}$'.}
+\endsetslot
+
+\setslot{C}
+ \comment{The calligraphic letter `$\mathcal{C}$'.}
+\endsetslot
+
+\setslot{D}
+ \comment{The calligraphic letter `$\mathcal{D}$'.}
+\endsetslot
+
+\setslot{E}
+ \comment{The calligraphic letter `$\mathcal{E}$'.}
+\endsetslot
+
+\setslot{F}
+ \comment{The calligraphic letter `$\mathcal{F}$'.}
+\endsetslot
+
+\setslot{G}
+ \comment{The calligraphic letter `$\mathcal{G}$'.}
+\endsetslot
+
+\setslot{H}
+ \comment{The calligraphic letter `$\mathcal{H}$'.}
+\endsetslot
+
+\setslot{I}
+ \comment{The calligraphic letter `$\mathcal{I}$'.}
+\endsetslot
+
+\setslot{J}
+ \comment{The calligraphic letter `$\mathcal{J}$'.}
+\endsetslot
+
+\setslot{K}
+ \comment{The calligraphic letter `$\mathcal{K}$'.}
+\endsetslot
+
+\setslot{L}
+ \comment{The calligraphic letter `$\mathcal{L}$'.}
+\endsetslot
+
+\setslot{M}
+ \comment{The calligraphic letter `$\mathcal{M}$'.}
+\endsetslot
+
+\setslot{N}
+ \comment{The calligraphic letter `$\mathcal{N}$'.}
+\endsetslot
+
+\setslot{O}
+ \comment{The calligraphic letter `$\mathcal{O}$'.}
+\endsetslot
+
+\setslot{P}
+ \comment{The calligraphic letter `$\mathcal{P}$'.}
+\endsetslot
+
+\setslot{Q}
+ \comment{The calligraphic letter `$\mathcal{Q}$'.}
+\endsetslot
+
+\setslot{R}
+ \comment{The calligraphic letter `$\mathcal{R}$'.}
+\endsetslot
+
+\setslot{S}
+ \comment{The calligraphic letter `$\mathcal{S}$'.}
+\endsetslot
+
+\setslot{T}
+ \comment{The calligraphic letter `$\mathcal{T}$'.}
+\endsetslot
+
+\setslot{U}
+ \comment{The calligraphic letter `$\mathcal{U}$'.}
+\endsetslot
+
+\setslot{V}
+ \comment{The calligraphic letter `$\mathcal{V}$'.}
+\endsetslot
+
+\setslot{W}
+ \comment{The calligraphic letter `$\mathcal{W}$'.}
+\endsetslot
+
+\setslot{X}
+ \comment{The calligraphic letter `$\mathcal{X}$'.}
+\endsetslot
+
+\setslot{Y}
+ \comment{The calligraphic letter `$\mathcal{Y}$'.}
+\endsetslot
+
+\setslot{Z}
+ \comment{The calligraphic letter `$\mathcal{Z}$'.}
+\endsetslot
+
+\setslot{union}
+ \comment{The set union symbol `$\cup$'.}
+\endsetslot
+
+\setslot{intersection}
+ \comment{The set intersection symbol `$\cap$'.}
+\endsetslot
+
+\setslot{unionmulti}
+ \comment{The multiset union symbol `$\uplus$'.}
+\endsetslot
+
+\setslot{logicaland}
+ \comment{The meet symbol `$\wedge$'.}
+\endsetslot
+
+\setslot{logicalor}
+ \comment{The join symbol `$\vee$'.}
+\endsetslot
+
+\setslot{turnstileleft}
+ \comment{The turnstile symbol `$\vdash$'.}
+\endsetslot
+
+\setslot{turnstileright}
+ \comment{The backwards turnstile symbol `$\dashv$'.}
+\endsetslot
+
+\setslot{floorleft}
+ \comment{The left floor symbol `$\lfloor$'.}
+\endsetslot
+
+\setslot{floorright}
+ \comment{The right floor symbol `$\rfloor$'.}
+\endsetslot
+
+\setslot{ceilingleft}
+ \comment{The left ceiling symbol `$\lceil$'.}
+\endsetslot
+
+\setslot{ceilingright}
+ \comment{The right ceiling symbol `$\rceil$'.}
+\endsetslot
+
+\setslot{braceleft}
+ \comment{The left brace symbol `$\{$'.}
+\endsetslot
+
+\setslot{braceright}
+ \comment{The right brace symbol `$\}$'.}
+\endsetslot
+
+\setslot{angleleft}
+ \comment{The left angle bracket symbol `$\langle$'.
+ It is called `angbracketleft' in MathTime and Lucida,
+ but `angleleft' in Adobe Symbol.}
+\endsetslot
+
+\setslot{angleright}
+ \comment{The right angle bracket symbol `$\rangle$'.
+ It is called `angbracketright' in MathTime and Lucida,
+ but `angleleft' in Adobe Symbol.}
+\endsetslot
+
+\setslot{bar}
+ \comment{The vertical bar symbol `$|$'.}
+\endsetslot
+
+\setslot{bardbl}
+ \comment{The parallel vertical bars symbol `$\parallel$'.}
+\endsetslot
+
+\setslot{arrowbothv}
+ \comment{The vertical arrows symbol `$\updownarrow$'.}
+\endsetslot
+
+\setslot{arrowdblbothv}
+ \comment{The double vertical arrows symbol `$\Updownarrow$'.}
+\endsetslot
+
+\setslot{backslash}
+ \comment{The backwards oblique symbol `$\backslash$'.}
+\endsetslot
+
+\setslot{wreathproduct}
+ \comment{The Wreath product symbol `$\wp$'.}
+\endsetslot
+
+\setslot{radicallow}
+ \comment{The lowered radical symbol `$\surd$'.}
+\endsetslot
+
+\setslot{coproduct}
+ \comment{The textstyle coproduct symbol `$\coprod$'.}
+\endsetslot
+
+\setslot{gradient}
+ \comment{The inverted Delta symbol `$\nabla$'.
+ It is also called `gradient' in MathTime and Lucida,
+ but `gradient' in Adobe Symbol.}
+\endsetslot
+
+\setslot{integral}
+ \comment{The small integral symbol `$\plainint$'.}
+\endsetslot
+
+\setslot{unionsq}
+ \comment{The square union symbol `$\sqcup$'.}
+\endsetslot
+
+\setslot{intersectionsq}
+ \comment{The square intersection symbol `$\sqcap$'.}
+\endsetslot
+
+\setslot{subsetsqequal}
+ \comment{The square subset or equal symbol `$\sqsubseteq$'.}
+\endsetslot
+
+\setslot{supersetsqequal}
+ \comment{The square superset or equal symbol `$\sqsupseteq$'.}
+\endsetslot
+
+\setslot{section}
+ \comment{The section symbol `\S'.}
+\endsetslot
+
+\setslot{dagger}
+ \comment{The dagger symbol `\dag'.}
+\endsetslot
+
+\setslot{daggerdbl}
+ \comment{The double dagger symbol `\ddag'.}
+\endsetslot
+
+\setslot{paragraph}
+ \comment{The paragraph symbol `\P'.}
+\endsetslot
+
+\setslot{club}
+ \comment{The club suit symbol `$\clubsuit$'.}
+\endsetslot
+
+\setslot{diamond}
+ \comment{The diamond suit symbol `$\diamondsuit$'.}
+\endsetslot
+
+\setslot{heart}
+ \comment{The heart suit symbol `$\heartsuit$'.}
+\endsetslot
+
+\setslot{spade}
+ \comment{The spade suit symbol `$\spadesuit$'.}
+\endsetslot
+
+\endencoding
+
+\section{Changes}
+
+29 Dec 1993, v1.30: Created file.
+
+03 Jan 1994, v1.301: Moved from ltugboat class to article.
+
+06 Jan 1994, v1.303: Corrected a fontdimen bug.
+
+08 Jan 1994, v1.304: Renamed radicallowered to radicallow and
+ perpendicularinverse to perpendicularinv.
+
+09 Jan 1994, v1.305: Renamed emptyset to emptysetstress, to distinguish
+ the geometric and the humanist emptyset symbols.
+ Renamed some glyphs to use the same glyph names
+ as Lucida New Math.
+
+10 Jun 1998, v1.800: Really use the same names as Lucida New Math.
+ `curlyless/greater' renamed to `precedes/follows'.
+
+06 Oct 2000, v1.915: Introduced intermediate variables for fontdimens
+ 8--22. Added \texttt{encodingname}. Updated markup.
+ (LH)
+
+27 Jul 2002, v1.921: Introduced intermediate variables also for
+ fontdimens 1--7. Switched to setting fontdimens
+ using \verb"\setfontdimen". (LH)
+
+24 Nov 2004, v1.928: Changed \verb"\neg" to \verb"\plainneg" for
+ `\texttt{logicalnot}'. (LH)
+
+\end{document}
diff --git a/fonts/utilities/fontinst/test/testsc.tex b/fonts/utilities/fontinst/test/testsc.tex
new file mode 100644
index 0000000000..c54452d45e
--- /dev/null
+++ b/fonts/utilities/fontinst/test/testsc.tex
@@ -0,0 +1,41 @@
+\input fontinst.sty
+
+\transformfont{padr8r} {\reencodefont{8r}{\fromafm{padr8a}}}
+\transformfont{padrc8r}{\reencodefont{8r}{\fromafm{padrc8a}}}
+\transformfont{pads8r} {\reencodefont{8r}{\fromafm{pads8a}}}
+\transformfont{padsc8r}{\reencodefont{8r}{\fromafm{padsc8a}}}
+\fromafm{padr8x}
+\fromafm{pads8x}
+
+\installfonts
+
+\installfamily{T1}{pad} {}
+\installfamily{T1}{padx}{}
+\installfamily{T1}{padj}{}
+
+\installfont{padrc8t}{padrc8r,latin}
+ {T1}{T1}{pad}{m}{sc}{}
+\installfont{padrc9e}
+ {kernoff,padr8r,padr8x,kernon,glyphoff,padrc8r,glyphon,
+ resetsc,latinsc}
+ {T1c}{T1}{padx}{m}{sc}{}
+\installfont{padrc9d}
+ {kernoff,padr8r,padr8x,kernon,glyphoff,padrc8r,glyphon,
+ resetosf,resetsc,latinsc}
+ {T1cj}{T1}{padj}{m}{sc}{}
+
+\installfont{padsc8t}{padsc8r,latin}
+ {T1}{T1}{pad}{m}{sc}{}
+\installfont{padsc9e}
+ {kernoff,pads8r,pads8x,kernon,glyphoff,padsc8r,glyphon,
+ resetsc,latinsc}
+ {T1c}{T1}{padx}{sb}{sc}{}
+\installfont{padsc9d}
+ {kernoff,pads8r,pads8x,kernon,glyphoff,padrc8r,glyphon,
+ resetosf,resetsc,latinsc}
+ {T1cj}{T1}{padj}{sb}{sc}{}
+
+\endinstallfonts
+\bye
+
+
diff --git a/fonts/utilities/fontinst/test/v1901test.mtx b/fonts/utilities/fontinst/test/v1901test.mtx
new file mode 100644
index 0000000000..624a39bf81
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1901test.mtx
@@ -0,0 +1,22 @@
+\relax
+
+% This is a test MTX file for the new implementation of
+% the \transformfont stuff.
+
+\metrics
+
+\setint{italicslant}{0}
+\setint{italicslant}{100}
+\setint{xheight}{400}
+
+\setrawglyph{a}{v1901test}{10.95pt}{10} {500}{400}{0}{40}
+\setrawglyph{g}{v1901test}{10.95pt}{10} {500}{400}{-300}{40}
+
+\setkern{a}{g}{100}
+
+\setglyph{ag}
+ \glyphpcc{a}{0}{500}
+ \glyphpcc{g}{500}{0}
+\endsetglyph
+
+\endmetrics \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/v1901test.tex b/fonts/utilities/fontinst/test/v1901test.tex
new file mode 100644
index 0000000000..81a6218f67
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1901test.tex
@@ -0,0 +1,214 @@
+% Test of fontinst v1.901.
+% Started 1999/03/13.
+\input fontinst.sty
+
+% Part one---test of pooled file allocation.
+\catcode`\_=11
+\catcode`\@=11
+
+\def\show_out_filenames{%
+ \immediate\write16{\string\count17=\the\count17}%
+ \for(i){-1}{16}{1}%
+ \immediate\write16{Stream \strint{i}:
+ \x_cs\meaning{out_filename-\strint{i}}%
+ }%
+ \endfor(i)%
+}
+
+% %1 Standard usage
+% \show_out_filenames
+% \open_pout\tF{\jobname.out}
+% \show_out_filenames
+% \pout_line\tF{Hello world!}
+% \close_pout\tF{Test output}
+% \show_out_filenames
+% % Seems to work fine.
+
+% %2 Allocating LOTS of files.
+% \newcount\j_count
+% \newcount\k_count
+% \j_count=0
+% \k_count=1
+% \for(o){1}{48}{1}
+% \x_cs\open_pout{F-\strint{o}}{\jobname.\strint{o}}%
+% \ifodd \int{o} \else
+% \x_cs\pout_line{F-\the\k_count}{%
+% open=\strint{o} close=\the\j_count\space write=\the\k_count
+% }%
+% \multiply \k_count \thr@@
+% \advance \k_count \@ne
+% \d_count=\k_count
+% \divide \d_count \int{o}%
+% \multiply \d_count \int{o}%
+% \advance \k_count -\d_count
+% \advance \k_count \@ne
+% \advance \j_count \@ne
+% \x_cs\close_pout{F-\the\j_count}{Test data}%
+% \fi
+% \d_count=\int{o}%
+% \divide \d_count 8%
+% \multiply \d_count 8%
+% \advance \d_count -\int{o}%
+% \ifnum 0=\d_count \show_out_filenames \fi
+% \endfor(o)
+% % Seems to work fine as well.
+
+
+%% Part two---test of reimplemented \transformfont stuff
+%% Part two B---test of \recordtransforms stuff
+
+\recordtransforms{mapfrags.tex}
+\transformfont{v1901test1}{
+ \xscalefont{2000}{\reencodefont{t1c}{\frommtx{v1901test}}}
+}
+\transformfont{v1901test2}{
+ \yscalefont{500}{\xscalefont{2000}{\frommtx{v1901test}}}
+}
+\transformfont{v1901test3}{
+ \reencodefont{t1}{\slantfont{100}{\frommtx{v1901test}}}
+}
+\endrecordtransforms
+
+
+\bye
+
+%% Part three---test of reglyphing
+
+\reglyphfonts
+ \resetcommand\iftokeep#1\then{\ifnum 0<#1}
+ % This means that an AFM command will survive the conversion only if
+ % it refers to at least one renamed glyph and not refer to any killed
+ % glyph.
+
+% \offmtxcommand\setrawglyph
+% \offmtxcommand\setglyph
+% % This reglyphing file is inteded for extracting information from the
+% % AFM file of a Caps, Small caps, and Oldstyle figures fonts--with the
+% % intention to build a corresponding virtual font with glyphs that are
+% % present in the Regular and Expert Regular variants instead. Hence
+% % there is no need for \setrawglyph or \setglyph commands (the
+% % dimensions of the characters are known from the Reg. and Exp.Reg.
+% % AFM's), but the \setkern commands are most interesting (since 8x
+% % fonts don't contain any upper case letters, and hence has no kerning
+% % pairs between these and the small caps either).
+
+
+ \renameglyph{dollaroldstyle}{dollar}
+ \renameglyph{ampersandsmall}{ampersand}
+
+ \renameglyph{zerooldstyle}{zero}
+ \renameglyph{oneoldstyle}{one}
+ \renameglyph{twooldstyle}{two}
+ \renameglyph{threeoldstyle}{three}
+ \renameglyph{fouroldstyle}{four}
+ \renameglyph{fiveoldstyle}{five}
+ \renameglyph{sixoldstyle}{six}
+ \renameglyph{sevenoldstyle}{seven}
+ \renameglyph{eigtholdstyle}{eight}
+ \renameglyph{nineoldstyle}{nine}
+
+ \renameglyph{Asmall}{a}
+ \renameglyph{Bsmall}{b}
+ \renameglyph{Csmall}{c}
+ \renameglyph{Dsmall}{d}
+ \renameglyph{Esmall}{e}
+ \renameglyph{Fsmall}{f}
+ \renameglyph{Gsmall}{g}
+ \renameglyph{Hsmall}{h}
+ \renameglyph{Ismall}{i}
+ \renameglyph{Jsmall}{j}
+ \renameglyph{Ksmall}{k}
+ \renameglyph{Lsmall}{l}
+ \renameglyph{Msmall}{m}
+ \renameglyph{Nsmall}{n}
+ \renameglyph{Osmall}{o}
+ \renameglyph{Psmall}{p}
+ \renameglyph{Qsmall}{q}
+ \renameglyph{Rsmall}{r}
+ \renameglyph{Ssmall}{s}
+ \renameglyph{Tsmall}{t}
+ \renameglyph{Usmall}{u}
+ \renameglyph{Vsmall}{v}
+ \renameglyph{Wsmall}{w}
+ \renameglyph{Xsmall}{x}
+ \renameglyph{Ysmall}{y}
+ \renameglyph{Zsmall}{z}
+
+ \renameglyph{centoldstyle}{cent}
+
+ % \renameglyph{FIsmall}{fi}
+ % \renameglyph{FLsmall}{fl}
+ % These two aren't really necessary, since the ligature `fi' looks
+ % exactly as the letters `f'`i' next to each others.
+ \killglyph{fi}
+ \killglyph{fl}
+
+ \renameglyph{Gravesmall}{grave}
+ \renameglyph{Acutesmall}{acute}
+ \renameglyph{Circumflexsmall}{circumflex}
+ \renameglyph{Tildesmall}{tilde}
+ \renameglyph{Macronsmall}{macron}
+ \renameglyph{Brevesmall}{breve}
+ \renameglyph{Dotaccentsmall}{dotaccent}
+ \renameglyph{Dieresissmall}{dieresis}
+ \renameglyph{Ringsmall}{ring}
+ \renameglyph{Cedillasmall}{cedilla}
+ \renameglyph{Ogoneksmall}{ogonek}
+ \renameglyph{Caronsmall}{caron}
+
+ \renameglyph{AEsmall}{ae}
+ \renameglyph{dotlessIsmall}{dotlessi}
+ \renameglyph{Lslashsmall}{lslash}
+ \renameglyph{Oslashsmall}{oslash}
+ \renameglyph{OEsmall}{oe}
+ % \renameglyph{SSsmall}{germandbls}
+ % This isn't really needed in the AGaramond font family, since `SSsmall'
+ % looks exactly like `Ssmall'`Ssmall'
+ \killglyph{germandbls}
+
+ \renameglyph{Oacutesmall}{oacute}
+ \renameglyph{Odieresissmall}{odieresis}
+ \renameglyph{Ucircumflexsmall}{ucircumflex}
+
+ \renameglyph{Uacutesmall}{uacute}
+ \renameglyph{Eacutesmall}{eacute}
+ \renameglyph{Iacutesmall}{iacute}
+ \renameglyph{Icircumflexsmall}{icircumflex}
+
+ \renameglyph{Thornsmall}{thorn}
+ \renameglyph{Yacutesmall}{yacute}
+
+ \renameglyph{Ocircumflexsmall}{ocircumflex}
+ \renameglyph{Otildesmall}{otilde}
+ \renameglyph{Ntildesmall}{ntilde}
+ \renameglyph{Ydieresissmall}{ydieresis}
+ \renameglyph{Ethsmall}{eth}
+ \renameglyph{Acircumflexsmall}{acircumflex}
+ \renameglyph{Aringsmall}{aring}
+ \renameglyph{Ccedillasmall}{ccedilla}
+
+ \renameglyph{Ugravesmall}{ugrave}
+ \renameglyph{Zcaronsmall}{zcaron}
+ \renameglyph{Idieresissmall}{idieresis}
+ \renameglyph{Agravesmall}{agrave}
+
+ \renameglyph{Ogravesmall}{ograve}
+
+ \renameglyph{Udieresissmall}{udieresis}
+ \renameglyph{Edieresissmall}{edieresis}
+ \renameglyph{Aacutesmall}{aacute}
+ \renameglyph{Igravesmall}{igrave}
+ \renameglyph{Idieresissmall}{idieresis}
+ \renameglyph{Adieresissmall}{adieresis}
+
+ \renameglyph{Scaronsmall}{scaron}
+ \renameglyph{Egravesmall}{egrave}
+ \renameglyph{Atildesmall}{atilde}
+ \renameglyph{Ecircumflexsmall}{ecircumflex}
+
+ \reglyphfont{K-padrc}{gdsc}
+ \reglyphfont{K-padsc}{padsc8a}
+\endreglyphfonts
+
+
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/v1902test.tex b/fonts/utilities/fontinst/test/v1902test.tex
new file mode 100644
index 0000000000..7274fb7659
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1902test.tex
@@ -0,0 +1,11 @@
+\input fontinst.sty
+
+\generalpltomtx{cmr5}{cmr5;1}{pl}{OT1}
+\generalpltomtx{padr9d}{padr9d;1}{vpl}{}
+\generalpltomtx{padr9d}{padr9d;2}{vpl}{OT1}
+
+\transformfont{cmr5;2}{\fromplgivenetx{cmr5}{OT1}}
+\transformfont{padr9d;3}{\fromvpl{padr9d}}
+\transformfont{padr9d;4}{\fromvplgivenetx{padr9d}{OT1}}
+
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/v1905test.tex b/fonts/utilities/fontinst/test/v1905test.tex
new file mode 100644
index 0000000000..47117acc5f
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1905test.tex
@@ -0,0 +1,22 @@
+\input fontinst.sty
+\catcode`\_=11\catcode`\ =9\catcode`\^^M=9
+\catcode`\~=10\catcode`\@=11
+
+\fontinst_error{Hungarian}{
+ I~will~not~buy~this~record,\message_break
+ it~is~scratched
+}\error_help_a
+
+\fontinst_warning{Hungarian}{Your~hovercraft~is~full~of~eels}
+
+\fontinst_info{Hungarian}{That~will~be~six~pence,~please}
+
+\fontinst_warning_no_line{Hungarian}{
+ Do~you~want~to~come~home~to~my~place\message_break
+ and~pantsy~pantsy?
+}
+
+
+
+
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/v1906test.etx b/fonts/utilities/fontinst/test/v1906test.etx
new file mode 100644
index 0000000000..072cdfdf68
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1906test.etx
@@ -0,0 +1,128 @@
+\relax
+% Test1.etx
+
+
+
+\encoding
+
+\setint{italicslant}{0}
+
+\ifisglyph{x}\then
+ \setint{xheight}{\height{x}}
+\else
+ \setint{xheight}{500}
+\fi
+
+\ifisglyph{space}\then
+ \setint{interword}{\width{space}}
+\else\ifisglyph{i}\then
+ \setint{interword}{\width{i}}
+\else
+ \setint{interword}{333}
+\fi\fi
+
+% added by Thierry Bouche <Thierry.Bouche@ujf-grenoble.fr>
+% 1997/02/07 to calculate values for extra EC fontdimens
+% Amended by SPQR 1997/02/09
+\ifisglyph{X}\then
+ \setint{capheight}{\height{X}}
+\else
+ \setint{capheight}{750}
+\fi
+
+\ifisglyph{d}\then
+ \setint{ascender}{\height{d}}
+\else
+ \ifisint{capheight}\then
+ \setint{ascender}{\int{capheight}}
+ \else
+ \setint{ascender}{750}
+\fi\fi
+
+\ifisglyph{Aring}\then
+ \setint{acccapheight}{\height{Aring}}
+\else
+ \setint{acccapheight}{999}
+\fi
+
+\ifisint{descender_neg}\then
+ \setint{descender}{\neg{\int{descender_neg}}}
+ \else
+ \ifisglyph{p}\then
+ \setint{descender}{\depth{p}}
+ \else
+ \setint{descender}{250}
+ \fi
+\fi
+
+\ifisglyph{Aring}\then
+ \setint{maxheight}{\height{Aring}}
+\else
+ \setint{maxheight}{1000}
+\fi
+
+\ifisint{maxdepth_neg}\then
+ \setint{maxdepth}{\neg{\int{maxdepth_neg}}}
+\else
+ \ifisglyph{j}\then
+ \setint{maxdepth}{\depth{j}}
+ \else
+ \setint{maxdepth}{250}
+ \fi
+\fi
+
+\ifisglyph{six}\then
+ \setint{digitwidth}{\width{six}}
+\else
+ \setint{digitwidth}{500}
+\fi
+
+\setint{capstem}{0} % not in AFM files
+\setint{baselineskip}{1200}
+% end changes by Thierry
+
+
+\comment{\section{Default font dimensions}}
+
+\setint{fontdimen(1)}{\int{italicslant}} % italic slant
+\setint{fontdimen(2)}{\int{interword}} % interword space
+\ifisint{monowidth}\then
+ \setint{fontdimen(3)}{0} % interword stretch
+ \setint{fontdimen(4)}{0} % interword shrink
+\else
+ \setint{fontdimen(3)}{\scale{\int{interword}}{600}}% interword stretch
+ \setint{fontdimen(4)}{\scale{\int{interword}}{240}}% interword shrink
+\fi
+\setint{fontdimen(5)}{\int{xheight}} % x-height
+\setint{fontdimen(6)}{1000} % quad
+\ifisint{monowidth}\then
+ \setint{fontdimen(7)}{\int{interword}} % extra space after .
+\else
+ \setint{fontdimen(7)}{\scale{\int{interword}}{240}}% extra space after .
+\fi
+% added by Thierry Bouche <Thierry.Bouche@ujf-grenoble.fr> 1997/02/07
+\setint{fontdimen(8)}{\int{capheight}} % cap height
+\setint{fontdimen(9)}{\int{ascender}} % ascender
+\setint{fontdimen(10)}{\int{acccapheight}} % accented cap height
+\setint{fontdimen(11)}{\int{descender}} % descender's depth
+\setint{fontdimen(12)}{\int{maxheight}} % max height
+\setint{fontdimen(13)}{\int{maxdepth}} % max depth
+\setint{fontdimen(14)}{\int{digitwidth}} % digit width
+\setint{fontdimen(15)}{\int{capstem}} % cap_stem
+\setint{fontdimen(16)}{\int{baselineskip}} % baselineskip
+
+
+\comment{\section{The encoding}}
+
+\for(i){0}{20}{1}
+ \setslot{c\strint{i}}
+ \comment{The `c\strint{i}' test glyph.}
+ \endsetslot
+\endfor(i)
+
+\setslot{d}
+\endsetslot
+
+
+
+\endencoding
diff --git a/fonts/utilities/fontinst/test/v1906test.mtx b/fonts/utilities/fontinst/test/v1906test.mtx
new file mode 100644
index 0000000000..94306a07b3
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1906test.mtx
@@ -0,0 +1,64 @@
+\relax
+% v1906test.mtx
+%
+% A test of the nokerning commands and the \glyphbboxright IE.
+
+
+\metrics
+
+\for(i){0}{20}{1}
+ \setglyph{c\strint{i}}
+ \glyphrule{20}{\mul{\add{\int{i}}{1}}{20}}
+ \movert{\mul{20}{\int{i}}}
+ \endsetglyph
+\endfor(i)
+
+
+\setglyph{d}
+ \for(i){5}{10}{1}
+ \glyphpcc{c\strint{i}}{\int{i}}{\int{i}}
+ \endfor(i)
+ \resetint{j}{\glyphbboxright}
+ \immediate\write16{\string\glyphbboxright=\strint{j}}
+ \glyph{c20}{1000}
+ \resetint{j}{\glyphbboxright}
+ \immediate\write16{\string\glyphbboxright=\strint{j}}
+\endsetglyph
+
+
+\for(i){0}{20}{1}
+ \for(j){0}{20}{1}
+ \setkern{c\strint{i}}{c\strint{j}}{\mul{\int{i}}{\int{j}}}
+ \endfor(j)
+\endfor(i)
+
+\noleftkerning{c1,c3,c5,c7,c9,c11,c13,c15,c17,c19}
+\immediate\write16{\expandafter\meaning\csname a_macro\endcsname}
+\norightkerning{c1,c3,c5,c7,c9}
+
+% \resetint{i}{0}
+% \loop
+% \setkern{c\strint{i}}{c\strint{i}}{-50}
+% \resetint{j}{\sub{20}{\int{i}}}
+% \resetkern{c\strint{i}}{c\strint{j}}{-100}
+% \ifnum 20>\int{i}
+% \resetint{i}{\add{\int{i}}{1}}
+% \repeat
+
+
+% \resetint{i}{0}
+% \loop
+% \ifiskern{c3}{c\strint{i}}\then
+% \resetint{T}{\kerning{c3}{c\strint{i}}}
+% \message{c3:c\strint{i} has kern \strint{T} units^^J}
+% \else
+% \message{c3:c\strint{i} no kern^^J}
+% \fi
+% \ifnum 20>\int{i}
+% \resetint{i}{\add{\int{i}}{1}}
+% \repeat
+
+
+
+\endmetrics
+
diff --git a/fonts/utilities/fontinst/test/v1906test.tex b/fonts/utilities/fontinst/test/v1906test.tex
new file mode 100644
index 0000000000..92ed628119
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1906test.tex
@@ -0,0 +1,12 @@
+%&Plain
+% Test of fontinst v1.906.
+% Begun 1999/08/01.
+\input fontinst.sty
+
+\installfonts
+ \installfamily{U}{ztest1}{}
+ \installfont{v1906test}{v1906test}{v1906test}{U}{ztest1}{m}{n}{}
+\endinstallfonts
+
+\bye
+
diff --git a/fonts/utilities/fontinst/test/v1913test.tex b/fonts/utilities/fontinst/test/v1913test.tex
new file mode 100644
index 0000000000..b9382cdf89
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1913test.tex
@@ -0,0 +1,21 @@
+\input fontinst.sty
+
+\recordtransforms{v1913test.recs}
+
+\transformfont{padr8r}{\reencodefont{8r}{\fromafm{padr8a}}}
+\transformfont{padr8r-ys}{\yscalefont{\div{397000}{663}}{\frommtx{padr8r}}}
+\reglyphfonts
+ \renameglyph{oneoldstyle}{one}
+ \reglyphfont{padr8r-ys2}{padr8r-ys}
+\endreglyphfonts
+
+\installfonts
+ \installfamily{T1}{pad}{}
+ \installfamily{8r}{pad}{}
+ \installfont{padr9d}{padr8r,padr8r-ys2,padr8x,latin}{t1j}{T1}{pad}{m}{n}{}
+ \installrawfont{padr8r2}{padr8r-ys}{8r}{8r}{pad}{m}{n}{}
+\endinstallfonts
+
+\endrecordtransforms
+
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/v1914test.tex b/fonts/utilities/fontinst/test/v1914test.tex
new file mode 100644
index 0000000000..73b271b986
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1914test.tex
@@ -0,0 +1,50 @@
+\input fontinst.sty
+
+%1
+\recordtransforms{v1914test.recs}
+
+\transformfont{padr8r}{\reencodefont{8r}{\fromafm{padr8a}}}
+\for(x){0}{2}{1}
+ \for(y){0}{2}{1}
+ \transformfont{p-ad-rr--8r--\strint{x}=\strint{y}}{
+ \xscalefont{\add{\mul{\int{x}}{300}}{700}}{
+ \yscalefont{\add{\mul{\int{y}}{300}}{700}}{
+ \frommtx{padr8r}}}}
+ \endfor(y)
+\endfor(x)
+
+\installfonts
+ \installfamily{T1}{padxy}{}
+ \installfamily{8r}{padxy}{}
+ \for(x){0}{2}{1}
+ \for(y){0}{2}{1}
+ \installfont{p-ad-rr--8t--\strint{x}=\strint{y}}
+ {p-ad-rr--8r--\strint{x}=\strint{y},latin}
+ {t1}{T1}{padxy}{m\strint{x}\strint{y}}{n}{}
+ \installrawfont{p-ad-rr--8r--\strint{x}=\strint{y}}
+ {p-ad-rr--8r--\strint{x}=\strint{y},8r}
+ {8r}{8r}{padxy}{m\strint{x}\strint{y}}{n}{}
+ \endfor(y)
+ \endfor(x)
+\endinstallfonts
+
+\endrecordtransforms
+
+% % \tracingmacros=1\tracingcommands=2
+% %2
+% \installfonts
+% \installrawfont{cmr5}{cmr5,\metrics
+% \resetint{xheight}{\mul{\int{xheight}}{2}},kernoff}{ot1}{OT1}
+% {cmr}{m}{n}{5}
+% \installfont{padr18t}{padr8r scaled 856,%
+% \metrics \message{%
+% \ifisint{rawscale}\then\strint{rawscale}\else None\fi
+% }%
+% \expandafter\show \csname g-A\endcsname
+% ,latin,%
+% \metrics \message{%
+% \ifisint{rawscale}\then\strint{rawscale}\else None\fi
+% }}{t1}{T1}{pad}{m}{ns}{}
+% \endinstallfonts
+
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/v1914testmap.tex b/fonts/utilities/fontinst/test/v1914testmap.tex
new file mode 100644
index 0000000000..9b1921bbc8
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1914testmap.tex
@@ -0,0 +1,17 @@
+\input finstmsc.sty
+
+\resetstr{PSfontsuffix}{.pfb}
+\adddriver{dvipdfm}{v1914test.dvipdfm}
+\adddriver{pltotf}{v1914test.sh} % v1.915 feature, actually
+\input v1914test.recs
+\donedrivers
+
+\AssumeLWFN
+\adddriver{dvips}{v1914test.map}
+\adddriver{debug}{v1914test.debug}
+\debugvalue{PS_font_file}
+\input v1914test.recs
+\donedrivers
+
+
+\bye
diff --git a/fonts/utilities/fontinst/test/v1914testshow.tex b/fonts/utilities/fontinst/test/v1914testshow.tex
new file mode 100644
index 0000000000..bd7a957b0a
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1914testshow.tex
@@ -0,0 +1,22 @@
+\documentclass{article}
+
+
+\newcommand\fontxy[2]{%
+ \usefont{T1}{padxy}{m#1#2}{n}%
+ Flygande b\"ackasiner s\"oka hwila p\r{a} mjuka tuvor%
+}
+
+
+\begin{document}
+
+$$
+ \hss
+ \begin{tabular}{lll}
+ \fontxy00& \fontxy10& \fontxy20\\
+ \fontxy01& \fontxy11& \fontxy21\\
+ \fontxy02& \fontxy12& \fontxy22
+ \end{tabular}
+ \hss
+$$
+\end{document}
+
diff --git a/fonts/utilities/fontinst/test/v1915test.tex b/fonts/utilities/fontinst/test/v1915test.tex
new file mode 100644
index 0000000000..c889464e44
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1915test.tex
@@ -0,0 +1,25 @@
+\input fontinst.sty
+
+% %1: Catcodes
+% \def\do#1{Catcode of `\string#1 = \the\catcode`#1 ^^J}
+% \def\showcatcodes{\message{\do{\ }\do{\^^M}\do{\@}\do{\_}\do{\~}}}
+%
+% \showcatcodes
+% \show\fontinstcc
+% \fontinstcc
+% \showcatcodes
+% \show\normalcc
+% \normalcc
+% \showcatcodes
+
+%2: Aliased glyphs
+\input Knuth:fontinst:New.fontinst:cyrfinst:etc:fnstcorr.tex
+\transformfont{padsc8r}{\reencodefont{8r}{\fromafm{padsc8a}}}
+\def\renameglyph#1#2{\galias{#1}{#2}}
+\input csc2x.tex
+\transformfont{padscx8r}{\reencodefont{8r}{\fromafm{padsc8a}}}
+% När glyfnamnen har tagits bort från de omkodade PL-filerna så är
+% de i allt väsentligt lika. Sålunda tycks det fungera!
+
+
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/v1915testmap.tex b/fonts/utilities/fontinst/test/v1915testmap.tex
new file mode 100644
index 0000000000..7e83526cd4
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1915testmap.tex
@@ -0,0 +1,9 @@
+\input finstmsc.sty
+\adddriver{pltotf}{v1915test.sh}
+\input v1914test.recs
+\donedrivers
+\setstr{TFMfileprefix}{:a:b:c:}
+\adddriver{pltotf}{v1915test.sh2}
+\input v1913test.recs
+\donedrivers
+\bye
diff --git a/fonts/utilities/fontinst/test/v1916test.mtx b/fonts/utilities/fontinst/test/v1916test.mtx
new file mode 100644
index 0000000000..1829c79d02
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1916test.mtx
@@ -0,0 +1,23 @@
+\relax
+
+\documentclass[twocolumn]{article}
+\usepackage{fontdoc}
+
+\errorcontextlines=999
+
+\begin{document}
+
+\metrics
+
+\foreach(glyph){a,b,c,d,tilde,\strint{a},db\str{a}ef,AB\str{glyph}CD}
+ \resetglyph{\str{glyph}}
+ \glyph{\str{glyph}}{1000}
+ \resetitalic{0}
+ \endresetglyph
+\endfor(glyph)
+
+
+\endmetrics
+
+
+\end{document}
diff --git a/fonts/utilities/fontinst/test/v1916test.tex b/fonts/utilities/fontinst/test/v1916test.tex
new file mode 100644
index 0000000000..56f26a51b0
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1916test.tex
@@ -0,0 +1,14 @@
+% v1916test.tex
+
+\input fontinst.sty
+
+% \half and \otherhalf
+\fontinstcc
+\for(i){-5}{5}{1}
+ \eval_expr_to\b_count{\half{\int{i}}}
+ \eval_expr{\otherhalf{\int{i}}}
+ \immediate\write16{\strint{i}:~\the\b_count \space+~ \the\result}
+\endfor(i)
+\normalcc
+
+\bye
diff --git a/fonts/utilities/fontinst/test/v1916test2.tex b/fonts/utilities/fontinst/test/v1916test2.tex
new file mode 100644
index 0000000000..8cc954f261
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1916test2.tex
@@ -0,0 +1,27 @@
+%&Plain
+\input fontinst.sty
+
+% %1 \ifareglyphs
+%
+% \setrawglyph{f}{xfont}{10pt}{102}{375}{750}{375}{50}
+% \setrawglyph{g}{xfont}{10pt}{102}{375}{750}{375}{50}
+% \setrawglyph{h}{xfont}{10pt}{102}{375}{750}{375}{50}
+%
+% \ifareglyphs{}\then True \else False \fi
+% \ifareglyphs{a}\then True \else False \fi
+% \ifareglyphs{f}\then True \else False \fi
+% \ifareglyphs{f,a}\then True \else False \fi
+% \ifareglyphs{a,f}\then True \else False \fi
+% \ifareglyphs{f,g}\then True \else False \fi
+% \ifareglyphs{f,g,a}\then True \else False \fi
+
+%2 \setfontdimen
+\generalpltomtx{ecrm1000}{ecrm1000}{pl}{t1draft}
+\generalpltomtx{ecss1000}{ecss1000}{pl}{t1draft}
+\transformfont{ecdh-shrunk}{%
+ \yscalefont{500}{\fromplgivenetx{ecdh1000}{t1draft}}%
+}
+
+\bye
+
+
diff --git a/fonts/utilities/fontinst/test/v1923test.tex b/fonts/utilities/fontinst/test/v1923test.tex
new file mode 100644
index 0000000000..ede00d9044
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1923test.tex
@@ -0,0 +1,47 @@
+%&Plain
+
+\input fontinst.sty
+
+% %1
+% \transformfont{padr8r}{\reencodefont{8r}{\fromafm{padr8a}}}
+% \transformfont{padri8r}{\reencodefont{8r}{\fromafm{padri8a}}}
+%
+% \installfonts
+% \installfamily{T1}{pad2}{}
+% \installfont{zpad2i8t}{padri8r scaled 1009,%
+% padr8r scaled 999 suffix -upright scaled 1009,\metrics
+% % \expandafter\show \csname r-T-upright\endcsname
+% \unsetglyph{parenleft}
+% \setglyph{parenleft}
+% \glyph{parenleft-upright}{1000}
+% \endsetglyph
+% \resetglyph{parenright}
+% \glyph{parenright-upright}{1000}
+% \endresetglyph,latin}{t1}{T1}{pad2}{m}{it}{}
+% \endinstallfonts
+
+% %2
+%
+% \installfonts
+% \installfamily{U}{fad}{}
+% \installfont{fadrr}{fadrr}{textfdim,fadrr mtxasetx}{U}{fad}{m}{n}{}
+% \endinstallfonts
+
+% %3
+% \transformfont{pagk8r}{\reencodefont{8r}{\fromafm{pagk8a}}}
+% \installfonts
+% \installfont{pagk8t}{pagk8r,newlatin}{t1}{T1}{pag}{m}{n}{}
+% \endinstallfonts
+
+%4
+\installfonts
+ \installfont{test}{rsfs10 encoding rsfs,cmsy10}{oms}{OMS}{xxx}{m}{n}{}
+\endinstallfonts
+% %4b
+% \installfonts
+% \installfont{test}{cmsy10,rsfs10 encoding rsfs}{oms}{OMS}{xxx}{m}{n}{}
+% \endinstallfonts
+
+
+\bye
+
diff --git a/fonts/utilities/fontinst/test/v1927test.tex b/fonts/utilities/fontinst/test/v1927test.tex
new file mode 100644
index 0000000000..b21f16bf60
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1927test.tex
@@ -0,0 +1,18 @@
+%&Plain
+
+\input finstmsc.sty
+
+% %1
+% \etxtoenc{ot1}{temp}
+
+%2
+\storemapdata{a}{\fromafm{a}{XX}}{}
+\storemapdata{a}{\fromafm{a}{XX}}{}
+\storemapdata{a}{\fromafm{a}{XY}}{}
+\storemapdata{a}{\fromafm{a}{XX}}{}
+\storemapdata{a}{\fromafm{a}{XX}}{\reencodefont{8r}}
+
+
+
+\bye
+
diff --git a/fonts/utilities/fontinst/test/v1928test.tex b/fonts/utilities/fontinst/test/v1928test.tex
new file mode 100644
index 0000000000..8242cc3438
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1928test.tex
@@ -0,0 +1,13 @@
+%&Plain
+
+\input finstmsc.sty
+
+%1
+\etxtocmap{t1draft}{temp}
+\etxtocmap{ot1draft}{ot1}
+\etxtocmap{omsdraft}{oms}
+
+
+
+\bye
+
diff --git a/fonts/utilities/fontinst/test/v1928test2.tex b/fonts/utilities/fontinst/test/v1928test2.tex
new file mode 100644
index 0000000000..c9b099e643
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1928test2.tex
@@ -0,0 +1,32 @@
+\documentclass{article}
+
+
+
+
+\def\FontWithCMap#1#2#3{%
+ \font#1=#2\relax
+ \immediate\pdfobj stream file {#3}%
+ \pdffontattr#1{/ToUnicode \the\pdflastobj\space 0 R}%
+}
+\def\AddCMapToFont#1#2{%
+ \immediate\pdfobj stream file {#2}%
+ \pdffontattr#1{/ToUnicode \the\pdflastobj\space 0 R}%
+}
+
+
+\begin{document}
+
+
+\FontWithCMap\test{cmr12}{ot1.cmap}
+\test abcdef ghijkl mnopqr stuvwx yz fi fl ffi ffl
+
+
+\begin{math}
+ a
+ \AddCMapToFont{\textfont2}{oms.cmap}
+ \mathcal{A} - \mathcal{B} + \mathcal{C} * \mathcal{D} \cdot
+ \mathcal{E} \bullet \mathcal{F} \spadesuit
+\end{math}
+
+
+\end{document}
diff --git a/fonts/utilities/fontinst/test/v1930test.tex b/fonts/utilities/fontinst/test/v1930test.tex
new file mode 100644
index 0000000000..5fbc46b0d5
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1930test.tex
@@ -0,0 +1,16 @@
+%&Plain
+
+\input fontinst.sty
+
+
+%1
+\CalculateTan{30}
+\message{sin 30 = \UseSin{30}}
+\message{cos 30 = \UseCos{30}}
+\message{tan 30 = \UseTan{30}}
+
+
+
+\bye
+
+
diff --git a/fonts/utilities/fontinst/test/v1931test0.tex b/fonts/utilities/fontinst/test/v1931test0.tex
new file mode 100644
index 0000000000..edee5cf3b5
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1931test0.tex
@@ -0,0 +1,8 @@
+% Test fontinst v1.931
+%
+
+\input finstmsc.sty
+
+\enctoetx{cc-pl}{cc-pl-test}
+
+\bye \ No newline at end of file
diff --git a/fonts/utilities/fontinst/test/v1931test1.tex b/fonts/utilities/fontinst/test/v1931test1.tex
new file mode 100644
index 0000000000..d6c7052d5b
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1931test1.tex
@@ -0,0 +1,50 @@
+% fontinst v1.931 test
+
+\input fontinst.sty
+
+\recordtransforms{v1931test.recs}
+
+
+\transformfont{padr6z}{\reencodefont{cc-pl-test}{\fromafm{padr8a}}}
+\transformfont{padro6z}{\slantfont{250}{\frommtx{padr6z}}}
+
+\substitutesilent{sl}{sl}
+
+
+\installfonts
+ \installfont{padr8d}{padr6z,newlatin option nosc}{t1} {T1}{pad}{m}{n}{}
+ \installfont{padro8d}{padro6z,newlatin option nosc}{t1} {T1}{pad}{m}{sl}{}
+\endinstallfonts
+
+\endrecordtransforms
+
+\bye
+
+
+% Expected t1pad.fd contents:
+%
+% %Filename: t1pad.fd
+% %Created by: tex v1931test1
+% %Created using fontinst v1.931
+%
+% %THIS FILE SHOULD BE PUT IN A TEX INPUTS DIRECTORY
+%
+% \ProvidesFile{t1pad.fd}
+% [2005/05/14 Fontinst v1.931 font definitions for T1/pad.]
+%
+% \DeclareFontFamily{T1}{pad}{}
+%
+% \DeclareFontShape{T1}{pad}{m}{n}{
+% <-> padr8d
+% }{}
+%
+% \DeclareFontShape{T1}{pad}{m}{sl}{
+% <-> padro8d
+% }{}
+%
+%
+% \endinput
+%
+% The notable feature is that there is no {T1}{pad}{m}{it} entry,
+% since that substitution was turned off.
+
diff --git a/fonts/utilities/fontinst/test/v1931test2.tex b/fonts/utilities/fontinst/test/v1931test2.tex
new file mode 100644
index 0000000000..8fecddca18
--- /dev/null
+++ b/fonts/utilities/fontinst/test/v1931test2.tex
@@ -0,0 +1,35 @@
+% fontinst v1.931 test
+
+\input finstmsc.sty
+
+
+% %1
+%
+% \adddriver{dvips}{v1931test.map}
+% \input v1931test.recs
+% \donedrivers
+%
+% % Expected results in v1931test.map:
+% %
+% % padr6z AGaramond-Regular <cc-pl.enc <padr8a.pfa " encpcr ReEncodeFont "
+% % padro6z AGaramond-Regular <cc-pl.enc <padr8a.pfa " encpcr ReEncodeFont 0.25 SlantFont "
+
+
+%2
+
+\specifypsfont{AGaramond-Regular}{\fulldownload{gdrg____.pfb}}
+\declarepsencoding{cc-pl-test}{encpcr}{\encodingdownload{cc-pl.enc}}
+
+\adddriver{dvips}{v1931test.map}
+\input v1931test.recs
+\donedrivers
+
+% Expected results in v1931test.map:
+%
+% padr6z AGaramond-Regular <[cc-pl.enc <<gdrg____.pfb " encpcr ReEncodeFont "
+% padro6z AGaramond-Regular <[cc-pl.enc <<gdrg____.pfb " encpcr ReEncodeFont 0.25 SlantFont "
+
+
+
+\bye
+