[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Groff] ASCII Minus Sign in man Pages

From: Ralph Corderoy
Subject: Re: [Groff] ASCII Minus Sign in man Pages
Date: Wed, 03 May 2017 15:51:24 +0100

Hi Mike,

> Stable, to me, implies not changing much over time, and most changes
> should be backward compatible.
> Backward compatible means that all code written to the existing
> definitions should turn out the same results as in the past when
> submitted to new assemblers.  (I have nroff documents and C code from
> the 1970s that still work.)


> Thus when we have pieces of documented definitions that contradict
> each other the problem becomes which definition to change.  The
> definitions for
>       -   \-   \(mi   \(hy   \(em   \(en   (others?)

\N'45' ?

    -       A hyphen for text, e.g. beer-flavoured ice-cream.
    \-      A minus sign in the current font.
    \(mi    A minus sign in the special font.
    \(hy    Another name for plain `-', so a hyphen for text.
    \N'45'  Glyph 45 in the current font.

> To my mind  -  in groff should always default to the ASCII, 7-bit,
> undistinguished character.

But it's always meant hyphen in pre-groff troff because it's a lot more
common to want a hyphen in writing than a minus sign.  Then Unicode
decided ASCII minus had too many meanings and couldn't be used for any
of them so created U+2010 for hyphen, and U+2212 for minus sign, and
groff switched to producing those for the hyphen and minus sign, leaving
ASCII minus unreproducible apart from \N'45'.

man pages that were and are considered correctly written have used \-
for a command-line minus sign, e.g. `wc \-l'.  (Incorrect man pages that
wrote `wc -l' can be ignored for the discussion;  there seems to be the
will to fix them.)  For that to paste from a man page, viewed as UTF-8
TTY, PostScript, PDF, browser, ..., it needs to be character 45.
Writing «wc \N'45'l» isn't going to gain support.  :-)  How to produce
it is the issue.

Cheers, Ralph.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]