Debian Codegraph @

upstream/debian-trixie/man1/hpftodit.1

raw
1 .TH hpftodit 1 "3 June 2025" "groff 1.23.0"
2 .SH Name
3 hpftodit \- create font description files for use with
4 .I groff
5 and
6 .I grolj4
7 .
8 .
9 .\" ====================================================================
10 .\" Legal Terms
11 .\" ====================================================================
12 .\"
13 .\" Copyright (C) 1994-2020 Free Software Foundation, Inc.
14 .\"
15 .\" Permission is granted to make and distribute verbatim copies of this
16 .\" manual provided the copyright notice and this permission notice are
17 .\" preserved on all copies.
18 .\"
19 .\" Permission is granted to copy and distribute modified versions of
20 .\" this manual under the conditions for verbatim copying, provided that
21 .\" the entire resulting derived work is distributed under the terms of
22 .\" a permission notice identical to this one.
23 .\"
24 .\" Permission is granted to copy and distribute translations of this
25 .\" manual into another language, under the above conditions for
26 .\" modified versions, except that this permission notice may be
27 .\" included in translations approved by the Free Software Foundation
28 .\" instead of in the original English.
29 .
30 .
31 .\" Save and disable compatibility mode (for, e.g., Solaris 10/11).
32 .do nr *groff_hpftodit_1_man_C \n[.cp]
33 .cp 0
34 .
35 .\" Define fallback for groff 1.23's MR macro if the system lacks it.
36 .nr do-fallback 0
37 .if !\n(.f .nr do-fallback 1 \" mandoc
38 .if \n(.g .if !d MR .nr do-fallback 1 \" older groff
39 .if !\n(.g .nr do-fallback 1 \" non-groff *roff
40 .if \n[do-fallback] \{\
41 . de MR
42 . ie \\n(.$=1 \
43 . I \%\\$1
44 . el \
45 . IR \%\\$1 (\\$2)\\$3
46 . .
47 .\}
48 .rr do-fallback
49 .
50 .
51 .\" ====================================================================
52 .SH Synopsis
53 .\" ====================================================================
54 .
55 .SY hpftodit
56 .RB [ \-aqs ]
57 .RB [ \-i\~\c
58 .IR n ]
59 .I tfm-file
60 .I map-file
61 .I font-description
62 .YS
63 .
64 .
65 .SY hpftodit
66 .B \-d
67 .I tfm-file
68 .RI [ map-file ]
69 .YS
70 .
71 .
72 .SY hpftodit
73 .B \-\-help
74 .YS
75 .
76 .
77 .SY hpftodit
78 .B \-v
79 .
80 .SY hpftodit
81 .B \-\-version
82 .YS
83 .
84 .
85 .\" ====================================================================
86 .SH Description
87 .\" ====================================================================
88 .
89 .I hpftodit
90 creates a font description file for use with a Hewlett-Packard
91 LaserJet\~4-\%series
92 (or newer)
93 printer with the
94 .MR grolj4 1
95 output driver of
96 .MR groff 1 ,
97 using data from an HP tagged font metric (TFM) file.
98 .
99 .I tfm-file
100 is the name of the font's TFM file;
101 Intellifont and TrueType TFM files are supported,
102 but symbol set TFM files are not.
103 .
104 .I map-file
105 is a file giving the
106 .I groff
107 special character identifiers for glyphs in the font;
108 this file should consist of a sequence of lines of the form
109 .RS
110 .EX
111 .IR "m u c1 c2 " "\&.\|.\|.\& [#" " comment" "]"
112 .EE
113 .RE
114 where
115 .I m
116 is a decimal integer giving the glyph's MSL
117 (Master Symbol List)
118 number,
119 .I u
120 is a hexadecimal integer giving its Unicode character code,
121 and
122 .IR c1 ,
123 .IR c2 ", .\|.\|."
124 are its
125 .I groff
126 glyph names
127 (see
128 .MR groff_char 7
129 for a list).
130 .
131 The values can be separated by any number of spaces and/or tabs.
132 .
133 The Unicode value must use uppercase hexadecimal digits A\^\[en]\^F,
134 and must lack a leading
135 .RB \[lq] 0x \[rq],
136 .RB \[lq] u \[rq],
137 or
138 .RB \[lq] U+ \[rq].
139 .
140 Unicode values corresponding to composite glyphs are decomposed;
141 that is
142 .RB \[lq] u00C0 \[rq]
143 becomes
144 .RB \[lq] u0041_0300 \[rq].
145 .
146 A glyph without a
147 .I groff
148 special character identifier may be named
149 .BI u XXXX
150 if the glyph corresponds to a Unicode value,
151 or as an unnamed glyph
152 .RB \[lq] \-\-\- \[rq].
153 .
154 If the given Unicode value is in the Private Use Area (PUA)
155 (0xE000\^\[en]\^0xF8FF),
156 the glyph is included as an unnamed glyph.
157 .
158 Refer to
159 .MR groff_diff 1
160 for additional information about unnamed glyphs and how to access them.
161 .
162 .
163 .P
164 Blank lines and lines beginning with
165 .RB \[lq] # \[rq]
166 are ignored.
167 .
168 A
169 .RB \[lq] # \[rq]
170 following one or more
171 .I groff
172 names begins a comment.
173 .
174 Because
175 .RB \[lq] # \[rq]
176 is a valid
177 .I groff
178 name,
179 it must appear first in a list of
180 .I groff
181 names if a comment is included,
182 as in
183 .
184 .RS
185 .EX
186 3 0023 # # number sign
187 .EE
188 .RE
189 .
190 or
191 .
192 .RS
193 .EX
194 3 0023 # sh # number sign
195 .EE
196 .RE
197 .
198 whereas in
199 .
200 .RS
201 .EX
202 3 0023 sh # # number sign
203 .EE
204 .RE
205 .
206 the first
207 .RB \[lq] # \[rq]
208 is interpreted as the beginning of the comment.
209 .
210 .
211 .P
212 Output is written in
213 .MR groff_font 5
214 format to
215 .I font-description,
216 a file named for the intended
217 .I groff
218 font name;
219 if this operand is
220 .RB \[lq] \- \[rq],
221 the font description is written to the standard output stream.
222 .
223 .
224 .LP
225 If the
226 .B \-i
227 option is used,
228 .I hpftodit
229 automatically will generate an italic correction,
230 a left italic correction,
231 and a subscript correction for each glyph
232 (the significance of these parameters is explained in
233 .MR groff_font 5 ).
234 .
235 .
236 .\" ====================================================================
237 .SH Options
238 .\" ====================================================================
239 .
240 .B \-\-help
241 displays a usage message,
242 while
243 .B \-v
244 and
245 .B \-\-version
246 show version information;
247 all exit afterward.
248 .
249 .
250 .TP
251 .B \-a
252 Include glyphs in the TFM file that are not included in
253 .IR map-file .
254 .
255 A glyph with corresponding Unicode value is given the name
256 .RI u XXXX ;
257 a glyph without a Unicode value is included as an unnamed glyph
258 \[lq]\-\^\-\^\-\[rq].
259 .
260 A glyph with a Unicode value in the Private Use Area
261 (0xE000\^\[en]\^0xF8FF)
262 is also included as an unnamed glyph.
263 .
264 .
265 .IP
266 This option provides a simple means of adding Unicode-named and
267 unnamed glyphs to a font without including them in the map file,
268 but it affords little control over which glyphs are placed in a regular
269 font and which are placed in a special font.
270 .
271 The presence or absence of the
272 .B \-s
273 option has some effect on which glyphs are included:
274 without it,
275 only the \[lq]text\[rq] symbol sets are searched for matching glyphs;
276 with it,
277 only the \[lq]mathematical\[rq] symbol sets are searched.
278 .
279 Nonetheless,
280 restricting the symbol sets searched isn't very selective\[em]many
281 glyphs are placed in both regular and special fonts.
282 .
283 Normally,
284 .B \-a
285 should be used only as a last resort.
286 .
287 .
288 .TP
289 .B \-d
290 Dump information about the TFM file to the standard output stream;
291 use this to ensure that a TFM file is a proper match for a font,
292 and that its contents are suitable.
293 .
294 The information includes the values of important TFM tags and a listing
295 (by MSL number for Intellifont TFM files or by Unicode value for
296 TrueType TFM files)
297 of the glyphs included in the TFM file.
298 .
299 The unit of measure \[lq]DU\[rq] for some tags indicates design units;
300 there are 8782\~design units per em for Intellifont fonts,
301 and 2048\~design units per em for TrueType fonts.
302 .
303 Note that the accessibility of a glyph depends on its inclusion in a
304 symbol set;
305 some TFM files list many glyphs but only a few symbol sets.
306 .
307 .
308 .IP
309 The glyph listing includes the glyph index within the TFM file,
310 the MSL or Unicode value,
311 and the symbol set and character code that will be used to print the
312 glyph.
313 .
314 If
315 .I map-file
316 is given,
317 .I groff
318 names are given for matching glyphs.
319 .
320 If only the glyph index and MSL or Unicode value are given,
321 the glyph does not appear in any supported symbol set and cannot be
322 printed.
323 .
324 .
325 .IP
326 With the
327 .B \-d
328 option,
329 .I map-file
330 is optional,
331 and
332 .I output-font
333 is ignored if given.
334 .
335 .
336 .TP
337 .BI \-i\~ n
338 Generate an italic correction for each glyph so that its width plus its
339 italic correction is equal to
340 .I n
341 thousandths of an em plus the amount by which the right edge of the
342 glyphs's bounding box is to the right of its origin.
343 .
344 If a negative italic correction would result,
345 use a zero italic correction instead.
346 .
347 .
348 .IP
349 Also generate a subscript correction equal to the product of the tangent
350 of the slant of the font and four fifths of the x-height of the font.
351 .
352 If a subscript correction greater than the italic correction would
353 result,
354 use a subscript correction equal to the italic correction instead.
355 .
356 .
357 .IP
358 Also generate a left italic correction for each glyph equal to
359 .I n
360 thousandths of an em plus the amount by which the left edge of the
361 glyphs's bounding box is to the left of its origin.
362 .
363 The left italic correction may be negative.
364 .
365 .
366 .IP
367 This option normally is needed only with italic or oblique fonts;
368 a value of 50
369 (0.05\~em)
370 usually is a reasonable choice.
371 .
372 .
373 .TP
374 .B \-q
375 Suppress warnings about glyphs in the map file that were not found in
376 the TFM file.
377 .
378 Warnings never are given for unnamed glyphs or by glyphs named by their
379 Unicode values.
380 .
381 This option is useful when sending the output of
382 .I hpftodit
383 to the standard output stream.
384 .
385 .
386 .TP
387 .B \-s
388 Add the
389 .B special
390 directive to the font description file,
391 affecting the order in which HP symbol sets are searched for each glyph.
392 .
393 Without this option,
394 the \[lq]text\[rq] sets are searched before the \[lq]mathematical\[rq]
395 symbol sets.
396 .
397 With it,
398 the search order is reversed.
399 .
400 .
401 .\" ====================================================================
402 .SH Files
403 .\" ====================================================================
404 .
405 .TP
406 .I /usr/\:\%share/\:\%groff/\:\%1.23.0/\:\%font/\:\%devlj4/\:DESC
407 describes the
408 .B lj4
409 output device.
410 .
411 .
412 .TP
413 .IR /usr/\:\%share/\:\%groff/\:\%1.23.0/\:\%font/\:\%devlj4/ F
414 describes the font known
415 .RI as\~ F
416 on device
417 .BR lj4 .
418 .
419 .
420 .TP
421 .I /usr/\:\%share/\:\%groff/\:\%1.23.0/\:\%font/\:\%devlj4/\:\%generate/\:\%Makefile
422 is a
423 .MR make 1
424 script that uses
425 .MR hpftodit 1
426 to prepare the
427 .I groff
428 font description files above from HP TFM data;
429 in can be used to regenerate them in the event the TFM files are
430 updated.
431 .
432 .
433 .TP
434 .I /usr/\:\%share/\:\%groff/\:\%1.23.0/\:\%font/\:\%devlj4/\:\%generate/\:\%special\:.awk
435 is an
436 .MR awk 1
437 script that corrects the Intellifont-based height metrics for several
438 glyphs in the
439 .B S
440 (special) font for TrueType CG Times used in the HP LaserJet\~4000 and
441 later.
442 .
443 .
444 .TP
445 .I /usr/\:\%share/\:\%groff/\:\%1.23.0/\:\%font/\:\%devlj4/\:\%generate/\:\%special\:.map
446 .TQ
447 .I /usr/\:\%share/\:\%groff/\:\%1.23.0/\:\%font/\:\%devlj4/\:\%generate/\:\%symbol\:.map
448 .TQ
449 .I /usr/\:\%share/\:\%groff/\:\%1.23.0/\:\%font/\:\%devlj4/\:\%generate/\:text\:.map
450 .TQ
451 .I /usr/\:\%share/\:\%groff/\:\%1.23.0/\:\%font/\:\%devlj4/\:\%generate/\:\%wingdings.map
452 map MSL indices and HP Unicode PUA assignments to
453 .I groff
454 special character identifiers.
455 .
456 .
457 .\" ====================================================================
458 .SH "See also"
459 .\" ====================================================================
460 .
461 .MR groff 1 ,
462 .MR groff_diff 1 ,
463 .MR grolj4 1 ,
464 .MR groff_font 5
465 .
466 .
467 .\" Restore compatibility mode (for, e.g., Solaris 10/11).
468 .cp \n[*groff_hpftodit_1_man_C]
469 .do rr *groff_hpftodit_1_man_C
470 .
471 .
472 .\" Local Variables:
473 .\" fill-column: 72
474 .\" mode: nroff
475 .\" End:
476 .\" vim: set filetype=groff textwidth=72: