groff
[Top][All Lists]
Advanced

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

Re: [Groff] Re: Bug#472903: Acknowledgement (scons: badly formatted manp


From: Werner LEMBERG
Subject: Re: [Groff] Re: Bug#472903: Acknowledgement (scons: badly formatted manpage)
Date: Tue, 01 Apr 2008 15:44:48 +0200 (CEST)

> .de does nothing if the macro you're trying to define already
> exists,

This is not correct.  .de simply overwrites a previous definition
without notice, similar to TeX.

> One is to simply rename your macro to something else.  I'm not sure
> if there's a recommended way to avoid this problem in future,
> though, and I recognise that that's a problem; I'm CCing the groff
> list in case they have any suggestions.

In general, the user shouldn't define *any* macro within a man page --
many man2xxx converters understand only the limited set of man macros
(and probably a few raw troff commands).  The next groff version will
contain an-ext.man, which defines a bunch of useful macros currently
missing in most man macro packages.

All man macros are uppercase.  If Joe User really want to define
something, I strongly recommend to use mixed-case macro names, for
example <uppercase><lowercase> -- only the `Tm' string register is
defined in the man package (and its extension).

> The other is to move your preamble below .TH (so that it comes after
> the point where an-ext.tmac is sourced), and to remove the existing
> macros before defining your own. The attached patch does this.

Yes.  Defining macros before .TH is always problematic since .TH is
often defined to switch between `man' and `mdoc' (redefining .TH
afterwards).


    Werner




reply via email to

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