[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [tz] Doubts about a typo fix
From: |
G. Branden Robinson |
Subject: |
Re: [tz] Doubts about a typo fix |
Date: |
Sat, 26 Nov 2022 17:23:34 -0600 |
[dropping everyone but Russ and the groff list]
Hi Russ,
It's my lucky day! I've been meaning to buttonhole you for quite some
time regarding my man(7) reforms and pod2man's output.
I had notions of trying to get you into a sort of informal summit
meeting at DebConf 20 but a lot of people got sick. That's how we know
that God Himself didn't want that conference to be held in Israel.
At 2022-11-25T19:20:37-0800, Russ Allbery wrote:
> \fBsomething\fP \f(CW-\fP something else
>
> you will discover that "something else" is in bold because the second
> \fP reverts to the "previous" font, which nroff thinks is \fB becuase
> \f(CW was ignored. (Just tested now on a Solaris 10 host.) Pod::Man
> has fairly elaborate workarounds for this bug.
For what it's worth, groff and Heirloom doctools nroff don't print
"something else" in bold (this is true even in Heirloom's default, _not_
groff compatibility, mode), and DWB 3.3 nroff does.
> Just be warned that \f(CR is not a valid font name in all *roff
> implementations,
Even if it's a valid font name in an _implementation_, it may not be for
any particular output device. Because CW is a popular name, groff
aliases it to an available font on most of its output devices.
And, in case anyone was wondering, "CW" and "CWI" are bona fide
typefaces on groff's "dvi" device, because TeX's Computer Modern font
collection has them. But there's no "CWB" or "CWBI", so groff (Git)
remaps those to CW faces of normal weight.
If I could legislate matters for the *roff universe I'd say every
implementation needs to recognize the 12 text faces of PostScript Level
1. That's the Cartesian product of the families T, C, and H ("Times",
"Courier", and "Helvetica"[1]) and the styles roman, italic, bold, and
bold-italic, and do a best-effort rendering in a serif, monospaced, or
sans serif typeface (respectively) if you're a typesetter, and just the
style if you're not. Practically speaking, man pages can even do
without sans serif, but *roff is for more than just man pages. And if
you're fond of certain of Kernighan's old books you might like to see a
bold sans serif face for (sub)section headings anyway.[2]
Any other fonts, a document needs to test for and be programmed
defensively regarding.[3] (It's okay to give up with ".ab".)
> which is why Pod::Man uses \f(CW by default. Not sure how much you
> care. (And, to be honest, not sure how much anyone should care about
> any implementations other than groff and mandoc these days.)
Speaking of mandoc, has anyone seen Ingo lately?
Regards,
Branden
[1] Trademark holders didn't see me write those.
[2] About 20 years ago groff tried to add a feature for this, a "header
font" string, HF, but it didn't work because it unconditionally set
HF to "B" instead of only doing so if HF was not already defined.
But it will work in the next release: "groff -dHF=HB -man". In
groff 1.23 you'll even get bold italics in a bold section heading if
you ask for italics.
[3] This would be tedious in AT&T troff but--this is Sparta!--you could
write a macro for it. The idea is to copy the .f register, select
the new face, and then see if .f changed. If it didn't, the font
is not available. (You might as well work around DWB/Solaris
troff's previous-font clobberific behavior while you're copying .f.)
In groff, naturally, you can ".if F fontname".
signature.asc
Description: PGP signature
- Re: Doubts about a typo fix, (continued)
- Re: Doubts about a typo fix, Deri, 2022/11/26
- Re: Doubts about a typo fix, Paul Eggert, 2022/11/26
- Re: Doubts about a typo fix, G. Branden Robinson, 2022/11/26
- Re: Doubts about a typo fix, Deri, 2022/11/26
- Re: Doubts about a typo fix, Paul Eggert, 2022/11/26
- Re: Doubts about a typo fix, Steffen Nurpmeso, 2022/11/26
- Re: Doubts about a typo fix, G. Branden Robinson, 2022/11/26
- Re: [tz] Doubts about a typo fix, Russ Allbery, 2022/11/25
- Re: [tz] Doubts about a typo fix, Paul Eggert, 2022/11/25
- Re: [tz] Doubts about a typo fix, G. Branden Robinson, 2022/11/26
- Re: [tz] Doubts about a typo fix,
G. Branden Robinson <=
- Re: [tz] Doubts about a typo fix, Russ Allbery, 2022/11/26
- Re: [tz] Doubts about a typo fix, Russ Allbery, 2022/11/26
Re: [tz] Doubts about a typo fix, Russ Allbery, 2022/11/28