groff
[Top][All Lists]
Advanced

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

Re: [groff] 05/07: [mdoc]: Align header/footer spacing with man(7).


From: Ingo Schwarze
Subject: Re: [groff] 05/07: [mdoc]: Align header/footer spacing with man(7).
Date: Thu, 20 May 2021 16:09:59 +0200
User-agent: Mutt/1.12.2 (2019-09-21)

Hi Branden,

G. Branden Robinson wrote on Thu, May 20, 2021 at 01:23:18AM -0400:

> commit bf4b3dde3ba442a0cf52e986d2549f1dc47f43c5
> Author: G. Branden Robinson <g.branden.robinson@gmail.com>
> AuthorDate: Thu May 20 11:45:10 2021 +1000
> 
>     [mdoc]: Align header/footer spacing with man(7).
>     
>     * tmac/mdoc/doc-common-u (doc-end-macro): When continuously rendering,
>       increase page length by same amount we vertically space after flushing
>       a pending output line, for symmetry with other spacing requests (and
>       to prevent nasty surprises analogous to those in Savannah #60611).
>     
>       (doc-header): Put 3 vees of space after the header in continuous
>       rendering mode, not 1 (and increase page length accordingly).

I very strongly object.  Please revert all recent commits manipulating
mdoc(7) vertical spacing before and after header and footer lines
(i think there was at least one other during the last one or two
days).

For nroff output, in the (default) continuous rendering mode, there
has never been additional vertical whitespace after the header line
or before the footer line in mdoc(7).  I checked Cynthia's Version 2
mdoc from 4.3BSD-Reno (1990-06), Cynthia's Version 3 mdoc from
4.3BSD-Net/2 (1991-08-20), the oldest version in our groff git
(1992-09-01), the oldest Version imported into NetBSD (1993-03-21)
and Cynthias final version from 4.4BSD-Lite/2 (1995-06-23) - they
are all consistent about this.

Also, this additional whitespace makes nothing better, it merely
wastes screen real estate and looks ugly.

Not wasting that space apparently was a conscious and reasonable
choice, as still witnessed by the "Test for crt" comment in the
doc-old.tmac-u file in our own git, and has never been called into
question as far as i'm aware.

I would not oppose making this consistent with man(7) in the opposite
way, by deleting the spurious blank lines from -man terminal output,
even though that would break with tradition.  Note that AT&T Version 3
UNIX (1973-02) had no additional blank lines in these places, Version 4
to Version 6 (1975-05) had two blank lines, and Version 7 (1979-01)
had half an inch of whitespace here, so that tradition is less
consistent.  Well, it probably has been consistent since 1979.
Either way, i don't feel strongly about what may be decided about
the legacy V7-UNIX man(7) format in this respect.

Yours,
  Ingo


> ---
>  ChangeLog              |  7 ++++++-
>  tmac/mdoc/doc-common-u | 10 +++++-----
>  2 files changed, 11 insertions(+), 6 deletions(-)
> 
> diff --git a/ChangeLog b/ChangeLog
> index aa1dd69..980ae18 100644
> --- a/ChangeLog
> +++ b/ChangeLog
> @@ -3,7 +3,12 @@
>       * tmac/mdoc/doc-common-u (doc-end-macro): When continuously
>       rendering and after flushing the last line of the body text of a
>       page, vertically space by 3 vees instead of 1, for consistency
> -     with our man(7) implementation.
> +     with our man(7) implementation.  Also increase page length by
> +     same amount _after_ flushing a pending output line, for symmetry
> +     with other spacing requests (and to prevent nasty surprises
> +     analogous to those in Savannah #60611).
> +     (doc-header): Put 3 vees of space after the header in continuous
> +     rendering mode, not 1 (and increase page length accordingly).
>  
>  2021-05-20  G. Branden Robinson <g.branden.robinson@gmail.com>
>  
> diff --git a/tmac/mdoc/doc-common-u b/tmac/mdoc/doc-common-u
> index 3d6cfb5..571f979 100644
> --- a/tmac/mdoc/doc-common-u
> +++ b/tmac/mdoc/doc-common-u
> @@ -955,8 +955,10 @@
>  .  tl 
> \*[doc-caption-font]\*[doc-header-string]\f[]\*[doc-caption-font2]\*[doc-volume]\f[]\*[doc-caption-font]\*[doc-header-string]\f[]
>  .  ie !\n[cR] \
>  .    sp \n[doc-header-space]u
> -.  el \
> -.    sp 1v
> +.  el \{\
> +.    pl +3v
> +.    sp 3v
> +.  \}
>  .  ev
>  .  ns
>  ..
> @@ -1017,13 +1019,11 @@
>  .  \" footer.  So we fudge the page length to make sure that the last
>  .  \" page is never ejected until we want it to be.
>  .
> -.  if \n[cR] \
> -.    pl +3v
>  .  fl
> -.
>  .  doc-check-depth
>  .
>  .  if \n[cR] \{\
> +.    pl +3v
>  .    sp 3v
>  .    tl 
> \*[doc-caption-font]\*[doc-operating-system]\f[]\*[doc-caption-font2]\*[doc-date-string]\f[]\*[doc-caption-font]\*[doc-operating-system]\f[]
>  .    \" suppress empty lines after the footer



reply via email to

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