hpftodit(1) — Linux manual page

Name | Synopsis | Description | Options | Files | See also | COLOPHON

hpftodit(1)              General Commands Manual             hpftodit(1)

Name         top

       hpftodit - create font description files for use with groff and
       grolj4

Synopsis         top

       hpftodit [-aqs] [-i n] tfm-file map-file font-description

       hpftodit -d tfm-file [map-file]

       hpftodit --help

       hpftodit -v

       hpftodit --version

Description         top

       hpftodit creates a font description file for use with a Hewlett-
       Packard LaserJet 4-series (or newer) printer with the grolj4(1)
       output driver of groff(1), using data from an HP tagged font
       metric (TFM) file.  tfm-file is the name of the font's TFM file;
       Intellifont and TrueType TFM files are supported, but symbol set
       TFM files are not.  map-file is a file giving the groff special
       character identifiers for glyphs in the font; this file should
       consist of a sequence of lines of the form
              m u c1 c2 ... [# comment]
       where m is a decimal integer giving the glyph's MSL (Master
       Symbol List) number, u is a hexadecimal integer giving its
       Unicode character code, and c1, c2, ...  are its groff glyph
       names (see groff_char(7) for a list).  The values can be
       separated by any number of spaces and/or tabs.  The Unicode value
       must use uppercase hexadecimal digits A–F, and must lack a
       leading “0x”, “u”, or “U+”.  Unicode values corresponding to
       composite glyphs are decomposed; that is “u00C0” becomes
       “u0041_0300”.  A glyph without a groff special character
       identifier may be named uXXXX if the glyph corresponds to a
       Unicode value, or as an unnamed glyph “---”.  If the given
       Unicode value is in the Private Use Area (PUA) (0xE000–0xF8FF),
       the glyph is included as an unnamed glyph.  Refer to
       groff_diff(1) for additional information about unnamed glyphs and
       how to access them.

       Blank lines and lines beginning with “#” are ignored.  A “#”
       following one or more groff names begins a comment.  Because “#”
       is a valid groff name, it must appear first in a list of groff
       names if a comment is included, as in
              3   0023   #   # number sign
       or
              3   0023   # sh   # number sign
       whereas in
              3   0023   sh #   # number sign
       the first “#” is interpreted as the beginning of the comment.

       hpftodit writes output to font-description, a file named for the
       intended groff font name; if this operand is “-”, hpftodit writes
       to the standard output stream.  The -i option directs hpftodit to
       automatically generate an italic correction, a left italic
       correction, and a subscript correction for each glyph.  See
       groff_font(5).

Options         top

       --help displays a usage message, while -v and --version show
       version information; all exit afterward.

       -a     Include glyphs in the TFM file that are not included in
              map-file.  A glyph with corresponding Unicode value is
              given the name uXXXX; a glyph without a Unicode value is
              included as an unnamed glyph “---”.  A glyph with a
              Unicode value in the Private Use Area (0xE000–0xF8FF) is
              also included as an unnamed glyph.

              This option provides a simple means of adding Unicode-
              named and unnamed glyphs to a font without including them
              in the map file, but it affords little control over which
              glyphs are placed in a regular font and which are placed
              in a special font.  The presence or absence of the -s
              option has some effect on which glyphs are included:
              without it, only the “text” symbol sets are searched for
              matching glyphs; with it, only the “mathematical” symbol
              sets are searched.  Nonetheless, restricting the symbol
              sets searched isn't very selective—many glyphs are placed
              in both regular and special fonts.  Normally, -a should be
              used only as a last resort.

       -d     Dump information about the TFM file to the standard output
              stream; use this to ensure that a TFM file is a proper
              match for a font, and that its contents are suitable.  The
              information includes the values of important TFM tags and
              a listing (by MSL number for Intellifont TFM files or by
              Unicode value for TrueType TFM files) of the glyphs
              included in the TFM file.  The unit of measure “DU” for
              some tags indicates design units; there are 8782 design
              units per em for Intellifont fonts, and 2048 design units
              per em for TrueType fonts.  Note that the accessibility of
              a glyph depends on its inclusion in a symbol set; some TFM
              files list many glyphs but only a few symbol sets.

              The glyph listing includes the glyph index within the TFM
              file, the MSL or Unicode value, and the symbol set and
              character code that will be used to print the glyph.  If
              map-file is given, groff names are given for matching
              glyphs.  If only the glyph index and MSL or Unicode value
              are given, the glyph does not appear in any supported
              symbol set and cannot be printed.

              With the -d option, map-file is optional, and output-font
              is ignored if given.

       -i n   Generate an italic correction for each glyph so that its
              width plus its italic correction is equal to n thousandths
              of an em plus the amount by which the right edge of the
              glyphs's bounding box is to the right of its origin.  The
              minimum value hpftodit will write is zero.

              Also generate a subscript correction equal to the product
              of the tangent of the slant of the font and four fifths of
              the x-height of the font.  If a subscript correction
              greater than the italic correction would result, use a
              subscript correction equal to the italic correction
              instead.

              Also generate a left italic correction for each glyph
              equal to n thousandths of an em plus the amount by which
              the left edge of the glyphs's bounding box is to the left
              of its origin.  The left italic correction may be
              negative.

              This option normally is needed only with italic or oblique
              fonts; a value of 50 (0.05 em) usually is a reasonable
              choice.

       -q     Suppress warnings about glyphs in the map file that were
              not found in the TFM file.  Warnings never are given for
              unnamed glyphs or by glyphs named by their Unicode values.
              This option is useful when sending the output of hpftodit
              to the standard output stream.

       -s     Add the special directive to the font description file,
              affecting the order in which HP symbol sets are searched
              for each glyph.  Without this option, the “text” sets are
              searched before the “mathematical” symbol sets.  With it,
              the search order is reversed.

Files         top

       /usr/local/share/groff/1.23.0/font/devlj4/DESC
              describes the lj4 output device.

       /usr/local/share/groff/1.23.0/font/devlj4/F
              describes the font known as F on device lj4.

       /usr/local/share/groff/1.23.0/font/devlj4/generate/Makefile
              is a make(1) script that uses hpftodit(1) to prepare the
              groff font description files above from HP TFM data; it
              can be used to regenerate them in the event the TFM files
              are updated.

       /usr/local/share/groff/1.23.0/font/devlj4/generate/special.awk
              is an awk(1) script that corrects the Intellifont-based
              height metrics for several glyphs in the S (special) font
              for TrueType CG Times used in the HP LaserJet 4000 and
              later.

       /usr/local/share/groff/1.23.0/font/devlj4/generate/special.map
       /usr/local/share/groff/1.23.0/font/devlj4/generate/symbol.map
       /usr/local/share/groff/1.23.0/font/devlj4/generate/text.map
       /usr/local/share/groff/1.23.0/font/devlj4/generate/wingdings.map
              map MSL indices and HP Unicode PUA assignments to groff
              special character identifiers.

See also         top

       groff(1), groff_diff(1), grolj4(1), groff_font(5)

COLOPHON         top

       This page is part of the groff (GNU troff) project.  Information
       about the project can be found at 
       ⟨http://www.gnu.org/software/groff/⟩.  If you have a bug report
       for this manual page, see ⟨http://www.gnu.org/software/groff/⟩.
       This page was obtained from the project's upstream Git repository
       ⟨https://git.savannah.gnu.org/git/groff.git⟩ on 2024-06-14.  (At
       that time, the date of the most recent commit that was found in
       the repository was 2024-06-10.)  If you discover any rendering
       problems in this HTML version of the page, or you believe there
       is a better or more up-to-date source for the page, or you have
       corrections or improvements to the information in this COLOPHON
       (which is not part of the original manual page), send a mail to
       man-pages@man7.org

groff 1.23.0.1273-9d53-dirty   6 June 2024                   hpftodit(1)