Merge branch 'topic/sync-to-go-2'
[s-roff.git] / man / ute-afmtodit.1.in
blob67961267c2d63d8e4ddfa1df19064e664bd6008d
1 .ig
2 @ @L_AFMTODIT@.1
4 Copyright (c) 2014 - 2017 Steffen (Daode) Nurpmeso <steffen@sdaoden.eu>.
6 Copyright (C) 1989 - 2003, 2005, 2006, 2008
7   Free Software Foundation, Inc.
9 Permission is granted to make and distribute verbatim copies of
10 this manual provided the copyright notice and this permission notice
11 are preserved on all copies.
13 Permission is granted to copy and distribute modified versions of this
14 manual under the conditions for verbatim copying, provided that the
15 entire resulting derived work is distributed under the terms of a
16 permission notice identical to this one.
18 Permission is granted to copy and distribute translations of this
19 manual into another language, under the above conditions for modified
20 versions, except that this permission notice may be included in
21 translations approved by the Free Software Foundation instead of in
22 the original English.
26 .\" Like TP, but if specified indent is more than half
27 .\" the current line-length - indent, use the default indent.
28 .de Tp
29 .  ie \\n(.$=0:((0\\$1)*2u>(\\n(.lu-\\n(.iu)) .TP
30 .  el .TP "\\$1"
33 .de OP
34 .  ie \\n(.$-1 .RI "[\ \fB\\$1\fP\ " "\\$2" "\ ]"
35 .  el .RB "[\ " "\\$1" "\ ]"
39 .TH @U_AFMTODIT@ @MAN1EXT@ "@MDATE@" "@T_ROFF@ v@VERSION@"
42 .SH NAME
43 @L_AFMTODIT@ \- create font files for use with @L_ROFF@ \-Tps
46 .SH SYNOPSIS
47 .nr a \n(.j
48 .ad l
49 .nr i \n(.i
50 .in +\w'\fB@L_AFMTODIT@ 'u
51 .ti \niu
52 .B @L_AFMTODIT@
53 .OP \-ckmnsvx
54 .OP \-a n
55 .OP \-d desc_file
56 .OP \-e enc_file
57 .OP \-f internal_name
58 .OP \-i n
59 .OP \-o output_file
60 .I afm_file
61 .I map_file
62 .I font
63 .br
64 .ad \na
66 .LP
67 The whitespace between a command line option and its argument is optional.
69 .SH DESCRIPTION
70 .B @L_AFMTODIT@
71 creates a font file for use with @L_ROFF@ and
72 .BR @L_D_PS@ .
74 .B @L_AFMTODIT@
75 is written in perl;
76 you must have perl version 5.004 or newer installed in order to run it.
78 .LP
79 .I afm_file
80 is the AFM (Adobe Font Metric) file for the font.
82 .LP
83 .I map_file
84 is a file that says which groff character names map onto
85 each PostScript character name;
86 this file should contain a sequence of lines of the form
87 .IP
89 ps_char roff_char
90 .LP
91 where
92 .I ps_char
93 is the PostScript name of the character
94 and
95 .I roff_char
96 is the @L_ROFF@ name of the character (as used in the @L_ROFF@ font file).
98 The same
99 .I ps_char
100 can occur multiple times in the file;
101 each
102 .I roff_char
103 must occur at most once.
105 Lines starting with
106 .B #
107 and blank lines are ignored.
109 If the file isn't found in the current directory, it is searched in
110 the `dev-ps/generate' subdirectory of the default font directory.
113 If a PostScript character is not mentioned in
114 .IR map_file ,
115 and a generic @L_ROFF@ glyph name can't be deduced using the
116 Adobe Glyph List (AGL, built into
117 .BR @L_AFMTODIT@ ),
118 then
119 .B @L_AFMTODIT@
120 puts the PostScript character into the @L_ROFF@ font file as an unnamed
121 character which can only be accessed by the
122 .B \eN
123 escape sequence in
124 .BR @L_TROFF@ .
125 In particular, this is true for glyph variants like `foo.bar'; all glyph
126 names containing one or more periods are mapped to unnamed entities.
128 If option
129 .B \-e
130 is not specified, the encoding defined in the AFM file (i.e., entries
131 with non-negative character codes) is used.
133 Please refer to section `Using Symbols' in the @L_ROFF@ manual which
134 describes how groff glyph names are constructed.
137 Characters not encoded in the AFM file (i.e., entries which have \-1 as
138 the character code) are still available in @L_ROFF@; they get glyph index
139 values greater than 255 (or greater than the biggest character code used
140 in the AFM file in the unlikely case that it is greater than 255) in the
141 @L_ROFF@ font file.
143 Glyph indices of unencoded characters don't have a specific order; it
144 is best to access them with glyph names only.
147 The @L_ROFF@ font file will be written to a file named
148 .IR font
149 unless a name has been specified with the
150 .B \-o
151 option.
154 If there is a downloadable font file for the font, it may be listed in
155 the file
156 .BR @FONTDIR@/dev-ps/download ;
158 .BR @L_D_PS@ (@MAN1EXT@).
161 If the
162 .B \-i
163 option is used,
164 .B @L_AFMTODIT@
165 will automatically generate an italic correction,
166 a left italic correction and a subscript correction
167 for each character
168 (the significance of these parameters is explained in
169 .BR @L_ROFF@-font (@MAN5EXT@));
170 these parameters may be specified for individual characters by
171 adding to the
172 .I afm_file
173 lines of the form:
175 .BI italicCorrection\  ps_char\ n
177 .BI leftItalicCorrection\  ps_char\ n
179 .BI subscriptCorrection\  ps_char\ n
181 where
182 .I ps_char
183 is the PostScript name of the character,
185 .I n
186 is the desired value of the corresponding parameter in thousandths of an em.
188 These parameters are normally needed only for italic (or oblique) fonts.
191 .SH OPTIONS
193 .BI \-a n
195 .I n
196 as the slant parameter in the font file;
197 this is used in the positioning of accents.
199 By default the negative of the ItalicAngle specified in the afm file is
200 used; with true italic fonts it is sometimes desirable to use
201 a slant that is less than this.
203 If you find that characters from an italic font have accents
204 placed too far to the right over them,
205 then use the
206 .B \-a
207 option to give the font a smaller slant.
210 .B \-c
211 Include comments in the font file in order to identify the PS font.
214 .BI \-d desc_file
215 The device description file is
216 .I desc_file
217 rather than the default
218 .BR DESC .
220 If not found in the current directory, the `dev-ps' subdirectory of the
221 default font directory is searched (this is true for both the default
222 device description file and a file given with option
223 .BR \-d ).
226 .BI \-e enc_file
227 The PostScript font should be reencoded to use the encoding described
228 in enc_file.
230 The format of
231 .I enc_file
232 is described in
233 .BR @L_D_PS@ (@MAN1EXT@).
235 If not found in the current directory, the `dev-ps' subdirectory of the
236 default font directory is searched.
239 .BI \-f name
240 The internal name of the @L_ROFF@ font is set to
241 .IR name .
244 .BI \-i n
245 Generate an italic correction for each character so that
246 the character's width plus the character's italic correction
247 is equal to
248 .I n
249 thousandths of an em
250 plus the amount by which the right edge of the character's bounding box
251 is to the right of the character's origin.
253 If this would result in a negative italic correction, use a zero
254 italic correction instead.
257 Also generate a subscript correction equal to the
258 product of the tangent of the slant of the font and
259 four fifths of the x-height of the font.
261 If this would result in a subscript correction greater than the italic
262 correction, use a subscript correction equal to the italic correction
263 instead.
266 Also generate a left italic correction for each character
267 equal to
268 .I n
269 thousandths of an em
270 plus the amount by which the left edge of the character's bounding box
271 is to the left of the character's origin.
273 The left italic correction may be negative unless option
274 .B \-m
275 is given.
278 This option is normally needed only with italic (or oblique) fonts.
280 The font files distributed with groff were created using an option of
281 .B \-i50
282 for italic fonts.
285 .B \-k
286 Omit any kerning data from the font.
287 This should be used only for mono-spaced fonts.
290 .B \-m
291 Prevent negative left italic correction values.
293 Roman font files distributed with @L_ROFF@ were created with
294 .B \-i0\ \-m
295 to improve spacing with
296 .BR @L_P_EQN@ (@MAN1EXT@).
299 .B \-n
300 Don't output a
301 .B ligatures
302 command for this font.
304 Use this with constant-width fonts.
307 .BI \-o output_file
308 The output will be written to
309 .I output_file
310 instead of
311 .IR font .
316 .B \-s
317 The font is special.
319 The effect of this option is to add the
320 .B special
321 command to the font file.
324 .B \-v
325 Print version.
328 .B \-x
329 Don't use the built-in Adobe Glyph List.
332 .SH FILES
333 .Tp \w'\fB@FONTDIR@/dev-ps/download'u+2n
334 .B @FONTDIR@/dev-ps/DESC
335 Device description file.
338 .BI @FONTDIR@/dev-ps/ F
339 Font description file for font
340 .IR F .
343 .B @FONTDIR@/dev-ps/download
344 List of downloadable fonts.
347 .B @FONTDIR@/dev-ps/text.enc
348 Encoding used for text fonts.
351 .B @FONTDIR@/dev-ps/generate/textmap
352 Standard mapping.
355 .SH "SEE ALSO"
356 .BR @L_ROFF@ (@MAN1EXT@),
357 .BR @L_D_PS@ (@MAN1EXT@),
358 .BR perl (1) ,
359 .BR @L_ROFF@-font (@MAN5EXT@)
361 .\" s-ts-mode