[Top][All Lists]

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

Re: groff man(7) `B` macro behavior with `\c`, and input traps

From: G. Branden Robinson
Subject: Re: groff man(7) `B` macro behavior with `\c`, and input traps
Date: Fri, 10 Jun 2022 08:07:06 -0500

Hi Ingo!

At 2022-06-06T09:18:01+0200, Ingo Schwarze wrote:
> So since .B uses .itc, and that appears to match Heirloom behaviour
> according to your research, it might be unwise to change that now.

I've changed it anyway.  I now regard Heirloom's man(7) as buggy in this
respect.  If I run Heirloom nroff with V7's, then the input

.TH foo 1
.B bar\c

results in a bold "bar" and a roman "baz".

I've also confirmed Unix V7 troff (yes, troff) behavior thanks to John
Gardner's cat2dit tool, which he helped me get working without having to
screw with npm at all.  See attachment.  It will look weird; be warned
that the C/A/T printed boustrophedonically.  But it's enough to confirm
that the font is selected three times; roman (mount position 1) to start
with, then bold (3) after 'zab' (right-to-left "baz") is printed, then
roman again after 'rab'.

> Still, i wonder whether choosing that behaviour was a good decision.
> From the user perspective, this feel asymmetric, in particular for
> users who dislike traps and don't want to think about them:
>   .BI command arg\c
>   text
> sets "text" in Roman font but
>   .I arg\c
>   text
> sets "text" in italics?  Isn't that really surprising from the
> user perspective?  No argument about .TP, but wouldn't it have
> been better for .B and .I to use .it rather than .itc for symmetry
> with .BI?

I think you're right.

> For now, i have added this entry to
> :
>   - the man(7) single-font macros (e.g. .B) use .itc,
>     so ".B foo\c" followed by "bar" prints "bar" in bold
>     gbranden@ Sun, 5 Jun 2022 18:08:46 -0500

Hmm, yes, I don't think preserving Heirloom compatibility is beneficial
here, since Heirloom has itself diverged from earlier AT&T troff.

(All that said, I have never been offered any reason to believe that
clean-room reimplementing a troff macro package is easy.)

What ever will become of my reputation for never changing my mind?  ;-)


Description: application/dit

Attachment: signature.asc
Description: PGP signature

reply via email to

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