groff: update vendor branch to v1.20.1
[dragonfly.git] / contrib / groff / src / utils / tfmtodit / tfmtodit.man
CommitLineData
92d0a6a6 1.ig
4d3e9548
JL
2Copyright (C) 1989-2000, 2001, 2002, 2009
3 Free Software Foundation, Inc.
92d0a6a6
JR
4
5Permission is granted to make and distribute verbatim copies of
6this manual provided the copyright notice and this permission notice
7are preserved on all copies.
8
9Permission is granted to copy and distribute modified versions of this
10manual under the conditions for verbatim copying, provided that the
11entire resulting derived work is distributed under the terms of a
12permission notice identical to this one.
13
14Permission is granted to copy and distribute translations of this
15manual into another language, under the above conditions for modified
16versions, except that this permission notice may be included in
17translations approved by the Free Software Foundation instead of in
18the original English.
19..
20.ie t .ds tx T\h'-.1667m'\v'.224m'E\v'-.224m'\h'-.125m'X
21.el .ds tx TeX
22.\" Like TP, but if specified indent is more than half
23.\" the current line-length - indent, use the default indent.
24.de Tp
25.ie \\n(.$=0:((0\\$1)*2u>(\\n(.lu-\\n(.iu)) .TP
26.el .TP "\\$1"
27..
28.TH TFMTODIT @MAN1EXT@ "@MDATE@" "Groff Version @VERSION@"
29.SH NAME
30tfmtodit \- create font files for use with groff \-Tdvi
31.SH SYNOPSIS
32.nr a \n(.j
33.ad l
34.nr i \n(.i
35.in +\w'\fBtfmtodit 'u
36.ti \niu
37.B tfmtodit
38.de OP
39.ie \\n(.$-1 .RI "[\ \fB\\$1\fP" "\\$2" "\ ]"
40.el .RB "[\ " "\\$1" "\ ]"
41..
42.OP \-sv
43.OP \-g gf_file
44.OP \-k skewchar
45.I tfm_file
46.I map_file
47.I font
48.br
49.ad \na
50.PP
51It is possible to have whitespace between a command line option and its
52parameter.
53.SH DESCRIPTION
54.B tfmtodit
55creates a font file for use with
56.B
57groff \-Tdvi\fR.
58.I tfm_file
59is the name of the \*(tx font metric file for the font.
60.I map_file
61is a file giving the groff names for characters in the font;
62this file should consist of a sequence of lines of the form:
63.IP
64.I
65n c1 c2 \fR.\|.\|.
66.LP
67where
68.I n
69is a decimal integer giving the position of the character in the font,
70and
71.IR c1 ,
72.IR c2 ,.\|.\|.
73are the groff names of the character.
74If a character has no groff names but exists in the tfm file,
75then it will be put in the groff font file as an unnamed character.
76.I font
77is the name of the groff font file.
78The groff font file is written to
79.IR font .
80.LP
81The
82.B \-s
83option should be given if the font is special
84(a font is
85.I special
86if
87.B troff
88should search it whenever
89a character is not found in the current font.)
90If the font is special,
91it should be listed in the
92.B fonts
93command in the DESC file;
94if it is not special, there is no need to list it, since
95.B troff
96can automatically mount it when it's first used.
97.LP
98To do a good job of math typesetting, groff requires
99font metric information not present in the tfm file.
100The reason for this is that \*(tx has separate math italic fonts
101whereas groff uses normal italic fonts for math.
102The additional information required by groff is given by the
103two arguments to the
104.B math_fit
105macro in the Metafont programs for the Computer Modern fonts.
106In a text font (a font for which
107.B math_fitting
108is false), Metafont normally ignores these two arguments.
109Metafont can be made to put this information in the gf file
110by loading the following definition after
111.B cmbase
112when creating
113.BR cm.base :
114.IP
115.nf
116.ft B
117def ignore_math_fit(expr left_adjustment,right_adjustment) =
118 special "adjustment";
119 numspecial left_adjustment*16/designsize;
120 numspecial right_adjustment*16/designsize;
121 enddef;
122.fi
123.ft R
124.LP
125For the EC font family, load the following definition after
126.B exbase
127(it is probably easiest to patch
128.B exbase.mf
129locally):
130.IP
131.nf
132.ft B
133def ignore_math_fit(expr left_adjustment,right_adjustment) =
134 ori_special "adjustment";
135 ori_numspecial left_adjustment*16/designsize;
136 ori_numspecial right_adjustment*16/designsize;
137 enddef;
138.fi
139.ft R
140.LP
141The gf file created using this modified
142.B cm.base
143or
144.B exbase
145should be specified with the
146.B \-g
147option.
148The
149.B \-g
150option should not be given for a font for which
151.B math_fitting
152is true.
153.SH OPTIONS
154.TP
155.B \-v
156Print the version number.
157.TP
158.B \-s
159The font is special.
160The effect of this option is to add the
161.B special
162command to the font file.
163.TP
164.BI \-k n
165The skewchar of this font is at position
166.IR n .
167.I n
168should be an integer;
169it may be given in decimal,
170or with a leading
171.B 0
172in octal,
173or with a leading
174.B 0x
175in hexadecimal.
176The effect of this option is to ignore any kerns whose second component
177is the specified character.
178.TP
179.BI \-g gf_file
180.I gf_file
181is a gf file produced by Metafont containing special and numspecial
182commands giving additional font metric information.
183.SH FILES
184.Tp \w'\fB@FONTDIR@/devdvi/DESC'u+2n
185.B @FONTDIR@/devdvi/DESC
186Device description file.
187.TP
188.BI @FONTDIR@/devdvi/ F
189Font description file for font
190.IR F .
191.SH "SEE ALSO"
192.BR groff (@MAN1EXT@),
193.BR grodvi (@MAN1EXT@),
194.BR groff_font (@MAN5EXT@)
195.
196.\" Local Variables:
197.\" mode: nroff
198.\" End: