groff
[Top][All Lists]
Advanced

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

Re: groff_mdoc(7): Document .Lk and .Mt macros.


From: Ingo Schwarze
Subject: Re: groff_mdoc(7): Document .Lk and .Mt macros.
Date: Sun, 20 Dec 2020 17:08:22 +0100

Hi Branden,

G. Branden Robinson wrote on Sun, Dec 20, 2020 at 03:38:54AM -0500:

> gbranden pushed a commit to branch master
> in repository groff.
> 
> commit 11301d8bd374bf1d4db3ac43c9e8e9ca45836a45
> Author: G. Branden Robinson <g.branden.robinson@gmail.com>
> AuthorDate: Sun Dec 20 14:29:21 2020 +1100
> 
>     groff_mdoc(7): Document .Lk and .Mt macros.
>     
>     ...tersely.
> ---
>  tmac/groff_mdoc.7.man | 14 ++++++++++++--
>  1 file changed, 12 insertions(+), 2 deletions(-)
> 
> diff --git a/tmac/groff_mdoc.7.man b/tmac/groff_mdoc.7.man
> index bd4132c..dedc65a 100644
> --- a/tmac/groff_mdoc.7.man
> +++ b/tmac/groff_mdoc.7.man
> @@ -4054,7 +4054,12 @@ followed by the file name, then the contents of
>  It is neither callable nor parsed.
>  .
>  .It Li .Lk
> -To be written.
> +Embed hyperlink.
> +.
> +.
> +.Pp
> +.Dl Usage: .Lk Ao url link-text Ac

I think this is incorrect.

Empty .Lk prints nothing and mandoc even warns about it:

  mandoc: tmp.mdoc:9:2: WARNING: skipping empty macro: Lk

So i think the first argument isn't optional.

But the second argument definitely is optional.

Correct markup would be:

  .D1 Usage: Pf . Ic \&Lk Ar uri Op Ar link-text

I know the groff_mdoc(7) manual violates mdoc markup conventions
throughout in very ugly ways, and at some point, that should be fixed.
The use of .Ao is disgusting in particular and clashes with the semantic
markup paradigm that is fundamental to mdoc.

But at least the manual should not mislead as to which arguments are
mandatory and which are optional.

> +.
>  .
>  .It Li .Me
>  Exact usage unknown.
> @@ -4066,7 +4071,12 @@ source file describes it as a macro for
>  Its default width is 6n.
>  .
>  .It Li .Mt
> -To be written.
> +Embed email address.
> +.
> +.
> +.Pp
> +.Dl Usage: .Mt email-address
> +.

Except for the missing markup, the content of this part seems correct.

Yours,
  Ingo



reply via email to

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