afm2pl.1: Some remarks and a patch with editorial changes for this man page
Bjarni Ingi Gislason <[email protected]> Sun, 31 May 2026 23:08:44 +0000
| Newsgroups | gmane.linux.debian.devel.tetex |
|---|---|
| Message-ID | <178026732773.7637.17059878268276671033.reportbug@kassi.invalid.is> |
Package: texlive-binaries
Version: 2026.20260303.78225+ds-4
Severity: minor
Tags: patch
Dear Maintainer,
>From "/usr/share/doc/debian/bug-reporting.txt.gz":
Don't file bugs upstream
If you file a bug in Debian, don't send a copy to the upstream software
maintainers yourself, as it is possible that the bug exists only in
Debian. If necessary, the maintainer of the package will forward the
bug upstream.
-.-
For forwarding bug reports to upstream see:
https://www.debian.org/Bugs/Developer#forward
-.-
"Handling bug reports" in
http://people.debian.org/~enrico/dcg/ch03s02.html
-.-
I do not send reports upstream if I have to get an account there.
The Debian maintainers have one already.
If I get a negative (or no) response from upstream, I send henceforth
bugs to Debian.
-.-
* What led up to the situation?
Checking for defects with a new version
test-[g|n]roff -mandoc -t -K utf8 -rF0 -rHY=0 -rCHECKSTYLE=0 -ww -z < "man page"
[Use
grep -n -e ' $' -e '\\~$' -e ' \\f.$' -e ' \\"' <file>
to find (most) trailing spaces.]
["test-groff" is a script in the repository for "groff"; is not shipped]
(local copy and "troff" slightly changed by me).
[The fate of "test-nroff" was decided in groff bug #55941.]
* What was the outcome of this action?
chk_manuals: No error from groff found in manual afm2pl.1
* What outcome did you expect instead?
No output (no warnings).
-.-
General remarks and further material, if a diff-file exist, are in the
attachments.
-- System Information:
Debian Release: forky/sid
APT prefers testing
APT policy: (500, 'testing')
Architecture: amd64 (x86_64)
Kernel: Linux 7.0.9+deb14-amd64 (SMP w/2 CPU threads; PREEMPT)
Locale: LANG=is_IS.iso88591, LC_CTYPE=is_IS.iso88591 (charmap=ISO-8859-1), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: sysvinit (via /sbin/init)
Versions of packages texlive-binaries depends on:
ii libc6 2.42-16
ii libcairo2 1.18.4-3+b1
ii libfontconfig1 2.17.1-5
ii libfreetype6 2.14.3+dfsg-1
ii libgcc-s1 16.1.0-1
ii libgraphite2-3 1.3.14-13
ii libharfbuzz-subset0 12.3.2-2+b2
ii libharfbuzz0b 12.3.2-2+b2
ii libicu78 78.3-2
ii libkpathsea6 2026.20260303.78225+ds-4
ii libmpfi0 1.5.4+ds-5
ii libmpfr6 4.2.2-3
ii libpaper2 2.2.5-0.4
ii libpixman-1-0 0.46.4-1+b2
ii libpng16-16t64 1.6.58-1
ii libpotrace0 1.16-2+b3
ii libptexenc1 2026.20260303.78225+ds-4
ii libstdc++6 16.1.0-1
ii libsynctex2 2026.20260303.78225+ds-4
ii libteckit0 2.5.13+ds-1+b1
ii libtexlua53-5 2026.20260303.78225+ds-4
ii libx11-6 2:1.8.13-1
ii libxaw7 2:1.0.16-1+b2
ii libxi6 2:1.8.2-2+b1
ii libxmu6 2:1.1.3-4+b1
ii libxpm4 1:3.5.19-1
ii libxt6t64 1:1.2.1-1.3+b2
ii libzzip-0-13t64 0.13.78+dfsg.1-0.2+b1
ii perl 5.40.1-7+b1
ii t1utils 1.41-4
ii tex-common 6.20
ii zlib1g 1:1.3.dfsg+really1.3.2-3
Versions of packages texlive-binaries recommends:
pn dvisvgm <none>
ii texlive-base 2026.20260328-4
Versions of packages texlive-binaries suggests:
pn hintview <none>
pn texlive-binaries-sse2 <none>
Versions of packages tex-common depends on:
ii bzip2 1.0.8-6+b2
ii ucf 3.0053
Versions of packages tex-common suggests:
pn debhelper <none>
Versions of packages texlive-binaries is related to:
ii tex-common 6.20
ii texlive-base 2026.20260328-4
-- no debconf information
chk_man.err.afm2pl.1
(text/plain, 6 KB)
Input file is afm2pl.1
Output from "mandoc -T lint afm2pl.1": (shortened list)
42 STYLE: input text line longer than 80 bytes
3 STYLE: input text line longer than 80 bytes:
2 STYLE: whitespace at end of input line
10 WARNING: skipping paragraph macro
Find most trailing spaces with:
grep -n -e ' $' -e ' \\f.$' -e ' \\"' <man page>
-.-.
Show if docman-to-man created this.
A patch to a generated man page is to show where the generator
failed to make a "clean" man page rendering (that is without warnings) and
sometimes to show a better format for it.
Generated man pages can produce long lines, which make patches much
bigger than necessary, see the attachment "general.bugs".
3:.\" Generator: DocBook XSL Stylesheets v1.73.2 <http://docbook.sf.net/>
-.-.
Remove space characters (whitespace) at the end of lines.
Use "git apply ... --whitespace=fix" to fix extra space issues, or use
global configuration "core.whitespace".
Number of lines affected is
2
See more information in the attachment "trailing.whitespace".
-.-.
Find a repeated word
! 80 --> l
! 80 --> l
! 81 --> l
! 81 --> l
! 81 --> l
! 82 --> l
! 82 --> l
! 82 --> l
! 83 --> l
! 83 --> l
! 83 --> l
! 84 --> l
! 84 --> l
! 125 --> lB
! 134 --> l
! 134 --> l
! 135 --> l
! 135 --> l
! 135 --> l
! 136 --> l
! 136 --> l
! 136 --> l
! 137 --> l
! 137 --> l
! 137 --> l
! 138 --> l
! 138 --> l
-.-.
Wrong distance (not two spaces, not a new line character (\n)) between
sentences in the input file.
Separate the sentences and subordinate clauses; each begins on a new
line. See man-pages(7) ("Conventions for source file layout") and
"info groff" ("Input Conventions").
The best procedure is to always start a new sentence on a new line,
at least, if you are typing on a computer.
Remember coding: Only one command ("sentence") on each (logical) line.
E-mail: Easier to quote exactly the relevant lines.
Generally: Easier to edit the sentence.
Patches: Less unaffected text.
Search for two adjacent words is easier, when they belong to the same line,
and the same phrase.
The amount of space between sentences in the output can then be
controlled with the ".ss" request.
Mark a final abbreviation point as such by suffixing it with "\&".
Some sentences (etc.) do not begin on a new line.
Split (sometimes) lines after a punctuation mark; before a conjunction.
Lines with only one (or two) space(s) between sentences could be split,
so latter sentences begin on a new line.
Use
#!/usr/bin/sh
sed -e '/^\./n' \
-e 's/\([[:alpha:]]\)\. */\1.\n/g' $1
to split lines after a sentence period.
Check result with the difference between the formatted outputs.
See also the attachment "general.bugs"
[List of affected lines removed.]
-.-
Split lines longer than 80 characters (fill completely
an A4 sized page line on a terminal)
into two or more lines.
Appropriate break points are the end of a sentence and a subordinate
clause; after punctuation marks.
[List of affected lines removed.]
Longest line is number 238 with 358 characters
The ligatures and kerns present in the afm file can be modified in various ways\&. Default, the encoding file is scanned for extra ligkern specifications, whose format will be described below\&. If there are no ligkern specifications in the encoding file, then extra ligkern specifications will be read from a file [afm2pl\-]default\&.lig\&. A value of 0 for
-.-.
Add a zero (0) in front of a decimal fraction that begins with a period
(.)
459:Except that arguably a narrowed Courier is less jarring than a full-width Courier, when used in combination with a normal proportional font. For Courier, choose .833 to match the width of cmtt. Better yet, don't use Courier at all; most TeX distributions offer various good replacements.
-.-.
Put a parenthetical sentence, phrase on a separate line,
if not part of a code.
See man-pages(7), item "semantic newline".
[List of affected lines removed.]
-.-.
Use a character "\(->" instead of plain "->" or "\->", if not typeset with
a constant width font.
403:\eDeclareFontShape{LY1}{ptm}{m}{upp}{<\-> ptmup8y}{}}
-.-.
No need for '\&' to be in front of a period (.),
if there is a character in front of it.
Remove with "sed -e 's/\(.\)\\&\./\1./g'".
The number of lines with such use is 84
-.-.
Only one space character is after a possible end of sentence
(after a punctuation, that can end a sentence).
[List of affected lines removed.]
-.-.
Remove quotes when there is a printable
but no space character between them
and the quotes are not for emphasis (markup),
for example as an argument to a macro.
afm2pl.1:8:.TH "AFM2PL" "1" "30 August 2022" "" "afm2pl"
afm2pl.1:13:.SH "NAME"
afm2pl.1:15:.SH "SYNOPSIS"
afm2pl.1:20:.SH "DESCRIPTION"
afm2pl.1:35:.SH "OPTIONS"
afm2pl.1:447:.SH "URLS"
afm2pl.1:457:.SH "NOTES"
-.-.
Remove excessive "\&" when it has no functional purpose.
55:\fIextend_factor\fR\&. Default is 1\&.0 (natural width)\&. Not recommended\&[1]\&.
453:\fIFont installation the shallow way\fR\&[2]
455:\fITUGboat\fR\&[3]
-.-.
Use "\-" instead of "-" (rendered as a hyphen (u2010) in UTF-8 encoding)
in web addresses.
463:\%https://tug.org/TUGboat/tb27-1/tb86kroonenberg-fonts.pdf
-.-.
Change comment lines of type '.\" ====', '.\" ---', and an empty
'.\"' line) to a single period, as they contain no information and waste
work each time they are processed.
7:.\"
-.-.
The first line of the man page should only contain information about the
preprocessing of tables, see man(1), chapter "DEFAULTS".
1: .\" Title: afm2pl
-.-.
Spelling (codespell):
afm2pl.1.new:434: useable ==> usable
-.-
Generally:
Split (sometimes) lines after a punctuation mark; before a conjunction.
-.-
Tables:
Use the preprocessor 'tbl' to make tables.
Put data, that are wider than the header in the (centered) last column,
in a "T{...\nT}" block(, when the table gets wider than the output line).
Table headings, that are wider than any data in the corresponding
column, do not need to be centered, so left adjustment (l, L) is
sufficient.
afm2pl.1.diff
(text/plain, 8.1 KB)
--- afm2pl.1 2026-05-31 21:52:41.173058161 +0000
+++ afm2pl.1.new 2026-05-31 22:17:46.899646490 +0000
@@ -1,24 +1,24 @@
+'\" t
.\" Title: afm2pl
-.\" Author:
+.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.73.2 <http://docbook.sf.net/>
.\" Date: May 2009
.\" Manual: afm2pl
-.\" Source:
-.\"
-.TH "AFM2PL" "1" "30 August 2022" "" "afm2pl"
+.\" Source:
+.
+.TH AFM2PL 1 "30 August 2022" "" afm2pl
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
-.SH "NAME"
+.SH NAME
afm2pl \- convert AFM font metrics to TeX pl font metrics
-.SH "SYNOPSIS"
+.SH SYNOPSIS
.HP 7
\fBafm2pl\fR [\fB\-p\fR\ \fIencoding_file\fR] [\fB\-o\fR] [\fB\-e\fR\ \fIextension_factor\fR] [\fB\-s\fR\ \fIslant_factor\fR] [\fB\-f\fR\ \fIfont_dimensions\fR] [\fB\-k\fR] [\fB\-m\fR\ \fIletter_spacing\fR] [\fB\-l\fR\ \fIligkern_spec\fR] [\fB\-L\fR\ \fIligkern_spec\fR] [\fB\-n\fR] \fIinput_file[\&.afm]\fR [\fIoutput_file[\&.pl]\fR]
.HP 7
\fBafm2pl\fR [\-\-help] | [\-\-version]
-.SH "DESCRIPTION"
-.PP
+.SH DESCRIPTION
afm2pl converts an afm (Adobe Font Metric) file into a pl (Property List) file, which in its turn can be converted to a tfm (TeX Font Metric) file\&. It normally preserves kerns and ligatures, but also offers additional control over them\&.
.PP
afm2pl is meant to be a partial replacement for afm2tfm, on which it is based\&. With afm2tfm, preserving kerns and ligatures is possible only in a roundabout way, and handling of them is hard\-wired\&.
@@ -32,8 +32,7 @@ check your mapfiles
if you have old afm2pl\-generated fonts using these\&.
.PP
Return value: 0 if no error; a negative number indicating the number of missing glyphs if conversion was otherwise successful but glyphs are missing, and 1 in case of error\&.
-.SH "OPTIONS"
-.PP
+.SH OPTIONS
\fB\-p\fR \fIencoding_file\fR
.RS 4
The default is the encoding specified in the afm file, which had better match the encoding in the fontfile (pfa or pfb)\&. If
@@ -52,7 +51,7 @@ Use octal for all character codes in the
\fB\-e\fR \fIextend_factor\fR
.RS 4
Widen or narrow characters by
-\fIextend_factor\fR\&. Default is 1\&.0 (natural width)\&. Not recommended\&[1]\&.
+\fIextend_factor\fR. Default is 1.0 (natural width). Not recommended\&[1].
.RE
.PP
\fB\-s\fR \fIslant_factor\fR
@@ -77,10 +76,6 @@ T}:T{
Afm2tfm value
T}
.T&
-l l l
-l l l
-l l l
-l l l
l l l.
T{
\fIstretch\fR
@@ -131,10 +126,6 @@ T}:T{
Afm2tfm value
T}
.T&
-l l l
-l l l
-l l l
-l l l
l l l.
T{
\fIstretch\fR
@@ -222,7 +213,6 @@ Display a short usage message\&.
Display the version number of afm2pl\&.
.RE
.SH "MAPFILE ENTRIES"
-.PP
afm2pl writes a mapfile entry to a file with the same basename as the pl output file, but with extension \&.map\&. It can be used for the dvips mapfile and for the pdftex mapfile\&. It is assumed that the pfb file has the same basename as the afm file and must be downloaded\&.
\fIYou may have to hand\-edit this entry\&.\fR
.PP
@@ -232,7 +222,6 @@ You can configure dvips and pdftex to re
To reduce the likelihood of name conflicts, the \&.enc\- files which are part of afm2pl (ot1, ot1csc, ot1ital, ot1tt, texnanlc and texnanuc) have now been prepended with
afm2pl\-\&. The \&.enc files are referenced in mapfiles\&. If you have old afm2pl\-generated \&.tfm files using these, then you should update their mapfile fragments and rerun updmap or updmap\-sys\&. Or you can copy the relevant enc files to your personal or local texmf tree under their previous non\-prefixed names\&.
.SH "EXTRA LIGKERN INFO"
-.PP
\fIMost users are well\-advised to leave this mess alone and to accept the default behavior\&.\fR
.PP
The ligatures and kerns present in the afm file can be modified in various ways\&. Default, the encoding file is scanned for extra ligkern specifications, whose format will be described below\&. If there are no ligkern specifications in the encoding file, then extra ligkern specifications will be read from a file [afm2pl\-]default\&.lig\&. A value of 0 for
@@ -334,7 +323,6 @@ one {} * ; * {} one ; two {} * ; * {} tw
Lines with ligkern specifications inside an encoding file should start with
% LIGKERN\&. Ligkern specifications in a lig file may optionally start this way\&.
.SH "LETTERSPACING AND EXTRA LIGKERN INFO"
-.PP
Letterspacing has various side\-effects for ligkern info\&. Instead of simply applying the extra ligkern info (see previous section), the following is done:
.sp
.IP 1.
@@ -366,7 +354,6 @@ texnansi encoding\&. With other encoding
additional kerning pairs\&.
.SH "FONT-BASED UPPER- AND LOWERCASING"
-.PP
The distribution includes encoding vectors texnanuc\&.enc and texnanlc\&.enc which produce all\-uppercase and all\-lowercase fonts
.PP
The principal uses for an all\-uppercase font are page headers and section heads\&. If these contain math, then macro\-based uppercasing would create unpleasant complications\&. Example:
@@ -414,7 +401,6 @@ Note that
upp
is simply a newly made\-up shape name\&.
.SS "The sz ligature \(ss"
-.PP
Note that the texnanuc encoding provides no glyph for the sz ligature \(ss; you\'ll either have to substitute ss or provide a macro\-based solution\&. The following code uses either the usual glyph or substitutes the letters ss, depending on whether the glyph exists in the current font:
.sp
.RS 4
@@ -433,34 +419,31 @@ In LaTeX, this code appears to work well
\eDeclareFontShape
macro, but I failed to get that to work\&.
.SH "AFM2PL, FONTINST AND ARTIFICIAL SMALLCAPS"
-.PP
Afm2pl doesn\'t do virtual fonts\&. That means that for things such as artificial smallcaps you have to turn elsewhere, e\&.g\&. to the fontinst package, which is part of any mainstream TeX distribution\&.
.PP
Look under texmf/tex/fontinst for fontinst support files, which allow you to generate a smallcaps font (tfm and vf files) from an afm2pl\-generated tfm file\&. This package only supports texnansi encoding\&.
.PP
-There should be no real problem in doing the same for OT1 encoding\&. However, there are several variations of the OT1 encoding to take care of\&. Also, there are as far as I know no officially sanctioned PostScript names for all the variations of the OT1 encoding; the fontinst names contain spaces and are therefore not useable as PostScript names\&.
+There should be no real problem in doing the same for OT1 encoding\&. However, there are several variations of the OT1 encoding to take care of\&. Also, there are as far as I know no officially sanctioned PostScript names for all the variations of the OT1 encoding; the fontinst names contain spaces and are therefore not usable as PostScript names\&.
.SH "CHANGED IN VERSION 0.7.1"
-.PP
In order to avoid name conflicts, the \&.enc\- and \&.lig files distributed with afm2pl got
afm2pl\-
prepended to their name\&. The program itself now first searches for the thus prepended name\&. If the \&.enc\- or \&.lig file is not found it will look for the original filename\&. The renaming of the afm2pl \&.enc files may require modification of some mapfiles\&.
-.SH "URLS"
-.PP
+.SH URLS
The afm2pl homepage is
\fIhttp://tex\&.aanhet\&.net/afm2pl/\fR\&.
.PP
The paper
-\fIFont installation the shallow way\fR\&[2]
+\fIFont installation the shallow way\fR[2]
(EuroTeX 2006 Proceedings, published as
-\fITUGboat\fR\&[3]
+\fITUGboat\fR[3]
issue 27\&.1) illustrates the use of afm2pl\&.
-.SH "NOTES"
+.SH NOTES
.IP " 1." 4
-Except that arguably a narrowed Courier is less jarring than a full-width Courier, when used in combination with a normal proportional font. For Courier, choose .833 to match the width of cmtt. Better yet, don't use Courier at all; most TeX distributions offer various good replacements.
+Except that arguably a narrowed Courier is less jarring than a full-width Courier, when used in combination with a normal proportional font. For Courier, choose 0.833 to match the width of cmtt. Better yet, don't use Courier at all; most TeX distributions offer various good replacements.
.IP " 2." 4
Font installation the shallow way
.RS 4
-\%https://tug.org/TUGboat/tb27-1/tb86kroonenberg-fonts.pdf
+\%https://tug.org/TUGboat/tb27\-1/tb86kroonenberg\-fonts.pdf
.RE
afm2pl is maintained as part of TeX Live.
general.bugs
(text/plain, 2.2 KB)
Check the output from "lintian" in the Debian distribution. Any program (person), that produces man pages, should check the output for defects by using (both groff and nroff) [gn]roff -mandoc -t -ww -b -z -K utf8 <man page> To find most trailing spaces use grep -n -e ' $' -e ' \\f.$' -e ' \\"' <man page> The same goes for man pages that are used as an input. -.- For a style guide use mandoc -T lint -.- For general input conventions consult the man page "nroff(7)" (item "Input conventions") or the Texinfo manual about the same item. -.- Any "autogenerator" should check its products with the above mentioned 'groff', 'mandoc', and additionally with 'nroff ...'. It should also check its input files for too long (> 80) lines. This is just a simple quality control measure. The "autogenerator" may have to be corrected to get a better man page, the source file may, and any additional file may. -.- Common defects: Not removing trailing spaces (in in- and output). The reason for these trailing spaces should be found and eliminated. "git" has a "tool" to point out whitespace, see for example "git-apply(1)" and git-config(1)") -.- Not beginning each input sentence on a new line. Line length and patch size should thus be reduced when that has been fixed. The script "reportbug" uses 'quoted-printable' encoding when a line is longer than 1024 characters in an 'ascii' file. See man-pages(7), item "semantic newline". -.- The difference between the formatted output of the original and patched file can be seen with: nroff -mandoc <file1> > <out1> nroff -mandoc <file2> > <out2> diff -d -u <out1> <out2> and for groff, using \"printf '%s\n%s\n' '.kern 0' '.ss 12 0' | groff -mandoc -Z - \" instead of 'nroff -mandoc' Add the option '-t', if the file contains a table. Read the output from 'diff -d -u ...' with 'less -R' or similar. -.-. If 'man' (man-db) is used to check the manual for warnings, the following must be set: The option "-warnings=w" The environmental variable: export MAN_KEEP_STDERR=yes (or any non-empty value) or (produce only warnings): export MANROFFOPT="-ww -b -z" export MAN_KEEP_STDERR=yes (or any non-empty value) -.-
trailing.whitespace
(message/rfc822, 452 B) - not displayed