groff
[Top][All Lists]
Advanced

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

Re: thin_space causes collateral damage in eqn


From: G. Branden Robinson
Subject: Re: thin_space causes collateral damage in eqn
Date: Tue, 16 May 2023 22:56:33 -0500

Hi Doug,

At 2023-05-16T23:15:42-0400, Douglas McIlroy wrote:
> man eqn says
>          set thin_space n
> causes n/100 em space to be "automatically inserted after punctuation
> characters", which are vaguely defined as "characters such as ',' "

On a minor point, I have some mitigating news.  The term "punctuation
characters" _is_ defined under the description of the GNU "chartype"
primitive.

    chartype t text
        Each (unquoted) character in text is assigned type t,
        persistently.  If t is “letter” or “digit”, chartype also
        assigns a typeface to each character in text.  See subsection
        “Fonts” below.  As an example, the default spacing for some
        punctuation characters is set up as if by the following eqn
        command.

            chartype "punctuation" .,;:

(That's forthcoming 1.23.0 eqn(1) wording, but 1.22.4 is similar.)

Possibly some cross references could be added where punctuation is
otherwise mentioned.  The fact that GNU eqn's man page is a delta
against an expert's understanding of AT&T eqn again serves us poorly.

> I used thin_space 0 to take away automatic space after . in formulas.
> To my surprise it also took away intentional spaces represented by ^.

I would not have predicted that either, but I am still in the process of
learning _eqn_[1].

> The loss of ^ threw away a lot of carefully crafted spaces, and even
> threw away spaces in some sporadic cases where I wanted to override
> thin_space 0.
> 
> Another parameter, thick_space, has the same effect on ~.
> 
> Apparently thin_space serves double duty--to control automatic spacing
> and to set the width of ^.
> 
> This coupling of function strikes me as a bug. One thinks of ^ and ~
> as groff keywords,

Well, eqn keywords, anyway.  ~ is used copiously in Kernighan & Cherry's
"Typesetting Mathematics"; both ^ and ~ are described in §4 of that
document.[2]

> not characters. And even if they are characters, they represent white
> space placed deliberately, not "automatically inserted".

Insofar as I understand eqn--which isn't saying much--your reasoning
makes sense to me.

I'll give this thread a day or two to attract further comment, and then
turn it into a Savannah ticket if no one can refute your position.

Regards,
Branden

[1] Happily, I've rescued my copy of George Grätzer's _Math into LaTeX_
    (3rd edition) from storage, and I expect to consult it when digging
    more deeply into GNU eqn.

[2] I'm attaching my re-typeset version for convenience, and to flog it,
    since it still hasn't shown up on troff.org.

Attachment: signature.asc
Description: PGP signature


reply via email to

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