linux-man.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "G. Branden Robinson" <g.branden.robinson@gmail.com>
To: mtk.manpages@gmail.com, linux-man@vger.kernel.org,
	Ian Hunter <ian@ianhunter.me>
Subject: Re: Error in read.1p
Date: Fri, 27 Sep 2019 06:45:02 +1000	[thread overview]
Message-ID: <20190926204500.yywdgn3dnxnkzigu@localhost.localdomain> (raw)
In-Reply-To: <20190926181754.GA15754@comp.lan> <20190926182357.GA20390@comp.lan>

[-- Attachment #1: Type: text/plain, Size: 2670 bytes --]

Hi Ian & Arkadiusz,

There are a few issues here.

At 2019-09-26T20:17:54+0200, Arkadiusz Drabczyk wrote:
> On Wed, Sep 25, 2019 at 09:41:30PM -0500, Ian Hunter wrote:
> > Hello,
> > 
> > The man page for read.1p incorrectly uses a unicode minus ("−")
> > instead of a hyphen ("-") in places where flags are being used or
> > described.

First is that the above pages are not maintained by the Linux man-pages
project.  They are maintained by the Austin Group, the folks behind the
POSIX standard.  They have an issue reporting site[1].

I believe you will have to register on the site to actually file a
report, however.  (Issues can be _viewed_ anonymously.)

> A quick ag '\(mi' done in man-pages-posix-2013-a.tar.xz shows that
> a lot of manpages in this tarball have this problem.

Yes.  Using the character escape for "minus" is a bad idea in prose
contexts.  The nroff and troff of the 1970s defined this to be a minus
in the "special font", i.e., one used for equation displays, which may
not have the same metrics as the so-calld normal fonts used to typeset
prose.

Long story short, writers of man pages and *roff documents generally
should use the escape sequence "\-" when they require the hybrid
"hyphen-minus" character that is used in programming languages, the Unix
command line, and for similar purposes.  The hyphens used in phrases
like "mother-in-law" can be typed as-is (i.e., ASCII 45).

I invite readers to the groff mailing list[2] if they wish to know more
about the complexities of typesetting, the myriad variety of dashes and
dash-like symbols available, their semantics, the reasons why the *roff
authors made the choices they did for the input language, why these
choices are sometimes surprising to or frustrating for man page writers,
and related issues.

At 2019-09-26T20:23:57+0200, Arkadiusz Drabczyk wrote:
> ... but it can be solved by setting non-UTF LANG:
> 
> $ LANG=en_US  man ./read.1p

That solution gives up a lot of output glyps ("man groff_char" to see a
large list).  There are better ways to get these hyphens to output as
ASCII 45 characters without having to patch every (or even any) man
page.

For instance, adding the line:

.char \- \N'45'

to an appropriate configuration file (like /etc/groff/man.local) could
do the trick, but this is a crude fix and I think I can come up with
better solutions if I know a little bit more.

What *roff implementation are you using (Ian, Arkadiusz)?  If you don't
know how to ask the system, try "troff -v" at the shell prompt.

Regards,
Branden

[1] http://austingroupbugs.net/main_page.php
[2] groff@gnu.org

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2019-09-26 20:45 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-26  2:41 Error in read.1p Ian Hunter
2019-09-26 18:17 ` Arkadiusz Drabczyk
2019-09-26 18:23   ` Arkadiusz Drabczyk
2019-09-26 20:45     ` G. Branden Robinson [this message]
2019-09-27 12:27       ` Arkadiusz Drabczyk
2019-09-27 17:45         ` G. Branden Robinson
2019-09-28 19:35           ` Arkadiusz Drabczyk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190926204500.yywdgn3dnxnkzigu@localhost.localdomain \
    --to=g.branden.robinson@gmail.com \
    --cc=ian@ianhunter.me \
    --cc=linux-man@vger.kernel.org \
    --cc=mtk.manpages@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).