groff
[Top][All Lists]
Advanced

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

[Groff] First round of cleabnup patches


From: Eric S. Raymond
Subject: [Groff] First round of cleabnup patches
Date: Sat, 13 Jan 2007 02:52:08 -0500
User-agent: Mutt/1.4.2.2i

This is my first set of cleanup patches for the groff man pages.  

All new macros defined in these changes have two-character names,
but I have not shortened longnames on old macros.  In one or two
files that I did early on (before the portability target was settled)
I eliminated use of \*[] in favor of the older \*( form; I have not
tried to revert this change, as it does no harm.

You should also find enclosed a new file, an-ext.tmac, to go in the
tmac subdirectory.  It contains definitions of .SY, .OP, .YS, and .TQ.
All instances of .TP++ in the files touched by this patch now use the
.TQ name.  I have not embedded an inclusion of an-ext.tmac in
an-old.tmac because the file contains some policy -- see the font
remappings near the front.

.SY/.YS need to be hacked to properly save/restore adjustment, even when
.SY/.YS calls are not balanced.

I have, however, added a definition of .EX/.EE to an-ext.tmac, as
several of the cleaned-up files make use of it.  Somebody with better
macro-coding skills than I have should upgrade .EX to take an
optional relative-indent argument.  (I now understand troff macros 
quite well, but I still don't speak them fluently...)

A definition of .DS/.DE (unfilled display with optional relative
indent) should also be added.  If it is possible to get "keep"
behavior without too much pain, this macro pair should do that.
Also, it should be possible to nest these with the indents (if any)
stacking.

This patch set is self-contained but not complete.  More pages still
need to be cleaned up.  .EX/.EE needs to be documented in groff_man(7).

Status of the files after patching:

contrib/chem.man
contrib/pdfroff.man,
man/ditroff.man
man/groff_diff.man
man/roff.man
src/roff/groff/groff.man
src/roff/grog/grog.man
src/roff/nroff/nroff.man
tmac/groff_me.man
tmac/groff_trace.man
   Now doclifter-portable.  Almost certainly viewer-portable as well,
   but I'll have to run more tests to check that. These were simple.

groff_out.man:
   This one is nasty.  I have it in a doclifter-portable state now, but
   the complex macros doclifter handles OK are certain to break viewers.
   They'll need to be simplified and unrolled further. 

tmac/an-old.tmac:
   .EX/.EE added.

tmac/Makefile.sub:
    Added an-ext.tmac to the installation targets.

-- 
                <a href="http://www.catb.org/~esr/";>Eric S. Raymond</a>

Attachment: PATCH
Description: Text document

Attachment: an-ext.tmac
Description: Text document


reply via email to

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