[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Milestone reached: hyperlinked mdoc(7) documents in PDF
From: |
G. Branden Robinson |
Subject: |
Re: Milestone reached: hyperlinked mdoc(7) documents in PDF |
Date: |
Mon, 18 Mar 2024 14:53:12 -0500 |
At 2024-03-18T12:56:45-0500, G. Branden Robinson wrote:
> ...and in fact when I change line 9:
>
> -.No Ar
> +.No \&Ar
>
> ...the applicable warnings from groff mdoc _and_ mandoc go away, and
> the text formats as you would expect.
The foregoing can be mostly disregarded. I forgot that mdoc(7)'s `Ar`
macro supplies its own "default arguments" in the absence of explicit
ones, so it's okay to call it with none.
Here's the fix.
diff --git a/tmac/doc.tmac b/tmac/doc.tmac
index b299349ed..a8cd55efd 100644
--- a/tmac/doc.tmac
+++ b/tmac/doc.tmac
@@ -831,7 +831,7 @@ .de Ar
. nr doc-arg-ptr +1
. doc-print-prefixes
. ie (\n[doc-arg-count] < \n[doc-arg-ptr]) \{\
-. nop \)\*[doc-str-Ar-default]\&\f[]\c
+. nop \)\*[doc-str-Ar-default]\&\c
. doc-print-and-reset
. \}
. el \{\
Thanks, Lennart!
This fix will be in my next push, along with another important mdoc one
(Savannah #65480).
Do you find the attached "groffed" mandoc collection an improvement?
(It still seems a little weird to me to follow `No` with `Ar`, but
having just embarrassed myself with my mdoc(7) inexpertise, I'll
withhold further opinion...)
Regards,
Branden
mandoc-groffed-v2.pdf
Description: mandoc-groffed-v2.pdf
signature.asc
Description: PGP signature
Re: Milestone reached: hyperlinked mdoc(7) documents in PDF, Lennart Jablonka, 2024/03/17
- Re: Milestone reached: hyperlinked mdoc(7) documents in PDF, G. Branden Robinson, 2024/03/18
- Re: Milestone reached: hyperlinked mdoc(7) documents in PDF,
G. Branden Robinson <=
- Re: Milestone reached: hyperlinked mdoc(7) documents in PDF, Lennart Jablonka, 2024/03/18
- mandoc(1)'s man pages, groffed, and Project KIC (was: Milestone reached: hyperlinked mdoc(7) documents in PDF), G. Branden Robinson, 2024/03/18
- Re: mandoc(1)'s man pages, groffed, and Project KIC (was: Milestone reached: hyperlinked mdoc(7) documents in PDF), Lennart Jablonka, 2024/03/19
- Re: mandoc(1)'s man pages, groffed, and Project KIC (was: Milestone reached: hyperlinked mdoc(7) documents in PDF), Dave Kemper, 2024/03/19
- Re: mandoc(1)'s man pages, groffed, and Project KIC (was: Milestone reached: hyperlinked mdoc(7) documents in PDF), Lennart Jablonka, 2024/03/19
- the Courier font family and nroff history (was: mandoc(1)'s man pages, groffed, and Project KIC), G. Branden Robinson, 2024/03/22
- Re: the Courier font family and nroff history (was: mandoc(1)'s man pages, groffed, and Project KIC), G. Branden Robinson, 2024/03/22
- Re: the Courier font family and nroff history (was: mandoc(1)'s man pages, groffed, and Project KIC), Lennart Jablonka, 2024/03/22
- Re: the Courier font family and nroff history (was: mandoc(1)'s man pages, groffed, and Project KIC), G. Branden Robinson, 2024/03/22
- Re: the Courier font family and nroff history, Russ Allbery, 2024/03/22