summaryrefslogtreecommitdiff
path: root/info/fontname/html/Name-mapping-file.html
blob: 79e0b52fbb4a42f8d943d92f9b406de62e488210 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<!-- This document is in the public domain and may be used freely. -->
<!-- Created by GNU Texinfo 6.0, http://www.gnu.org/software/texinfo/ -->
<head>
<title>Filenames for TeX fonts: Name mapping file</title>

<meta name="description" content="Filenames for TeX fonts: Name mapping file">
<meta name="keywords" content="Filenames for TeX fonts: Name mapping file">
<meta name="resource-type" content="document">
<meta name="distribution" content="global">
<meta name="Generator" content="makeinfo">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link href="index.html#Top" rel="start" title="Top">
<link href="General-index.html#General-index" rel="index" title="General index">
<link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
<link href="Long-names.html#Long-names" rel="up" title="Long names">
<link href="Long-naming-scheme.html#Long-naming-scheme" rel="next" title="Long naming scheme">
<link href="Long-names.html#Long-names" rel="prev" title="Long names">
<style type="text/css">
<!--
a.summary-letter {text-decoration: none}
blockquote.indentedblock {margin-right: 0em}
blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
blockquote.smallquotation {font-size: smaller}
div.display {margin-left: 3.2em}
div.example {margin-left: 3.2em}
div.lisp {margin-left: 3.2em}
div.smalldisplay {margin-left: 3.2em}
div.smallexample {margin-left: 3.2em}
div.smalllisp {margin-left: 3.2em}
kbd {font-style: oblique}
pre.display {font-family: inherit}
pre.format {font-family: inherit}
pre.menu-comment {font-family: serif}
pre.menu-preformatted {font-family: serif}
pre.smalldisplay {font-family: inherit; font-size: smaller}
pre.smallexample {font-size: smaller}
pre.smallformat {font-family: inherit; font-size: smaller}
pre.smalllisp {font-size: smaller}
span.nocodebreak {white-space: nowrap}
span.nolinebreak {white-space: nowrap}
span.roman {font-family: serif; font-weight: normal}
span.sansserif {font-family: sans-serif; font-weight: normal}
ul.no-bullet {list-style: none}
-->
</style>


</head>

<body lang="en">
<a name="Name-mapping-file"></a>
<div class="header">
<p>
Next: <a href="Long-naming-scheme.html#Long-naming-scheme" accesskey="n" rel="next">Long naming scheme</a>, Up: <a href="Long-names.html#Long-names" accesskey="u" rel="up">Long names</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="General-index.html#General-index" title="Index" rel="index">Index</a>]</p>
</div>
<hr>
<a name="A-fontname-mapping-file"></a>
<h3 class="section">3.1 A fontname mapping file</h3>

<a name="index-fontname-mapping-file"></a>
<a name="index-mapping-file"></a>

<p>At the moment, most implementations of TeX look up a TFM file (as
part of the <code>\font</code> command), by searching for a file with the name
given by the user (possibly in any of series of directories).  But if we
also looked TFM names up in <em>another</em> file (or set of files), which
specifies the actual filename, the fontname given in the TeX source
file could be almost anything at all, of any length.
</p>
<a name="index-texfonts_002emap"></a>
<p>In version 5.851d of Web2c, I implemented this mapping file.  Each file
<samp>texfonts.map</samp> in a search path is read for abbreviations. The file
has a straightforward format: each line specifies the filename and the
TeX name for one font, separated by whitespace.  Extra information on
the line is ignored; then more information could be specified for the
benefit of DVI-reading programs in the same file.  Comments start with
<code>%</code> and continue to the end of the line.
</p>
<p>Besides allowing long names, this sort of mapping file has other
benefits.  TeX source or DVI files can be more easily transported,
because the font names in a particular file can be made to work on every
system.  Also, when combined with a consistent naming scheme, macros
could be written to access any of a number of fonts.  Right now, each
font family has to have specialized macros written to deal with it.
</p>
<a name="index-Knuth_002c-Donald-E_002e"></a>
<p>Incidentally, Professor Knuth has approved this as a legitimate
&ldquo;system-dependent&rdquo; extension; a TeX with such a feature can still
be called &ldquo;TeX&rdquo;.
</p>




</body>
</html>