groff-commit
[Top][All Lists]
Advanced

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

[Groff-commit] groff/contrib/mom BUGS ChangeLog Makefile.sub N...


From: Peter Schaffter
Subject: [Groff-commit] groff/contrib/mom BUGS ChangeLog Makefile.sub N...
Date: Fri, 31 Aug 2012 22:50:01 +0000

CVSROOT:        /sources/groff
Module name:    groff
Changes by:     Peter Schaffter <PTPi>  12/08/31 22:50:00

Modified files:
        contrib/mom    : BUGS ChangeLog Makefile.sub NEWS TODO copyright 
                         groff_mom.man om.tmac 
        contrib/mom/examples: README.txt elvis_syntax.new letter.mom 
                              mom.vim sample_docs.mom typesetting.mom 
        contrib/mom/momdoc: appendices.html color.html cover.html 
                            definitions.html docelement.html 
                            docprocessing.html goodies.html 
                            graphical.html headfootpage.html images.html 
                            inlines.html intro.html letters.html 
                            macrolist.html rectoverso.html refer.html 
                            reserved.html stylesheet.css 
                            tables-of-contents.html toc.html 
                            typesetting.html using.html 
Added files:
        contrib/mom/examples: mom-pdf.mom penguin.pdf 
        contrib/mom/momdoc: version-2.html 

Log message:
        o Version 2.0 (gropdf integration) release

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/BUGS?cvsroot=groff&r1=1.49&r2=1.50
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/ChangeLog?cvsroot=groff&r1=1.73&r2=1.74
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/Makefile.sub?cvsroot=groff&r1=1.28&r2=1.29
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/NEWS?cvsroot=groff&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/TODO?cvsroot=groff&r1=1.15&r2=1.16
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/copyright?cvsroot=groff&r1=1.11&r2=1.12
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/groff_mom.man?cvsroot=groff&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/om.tmac?cvsroot=groff&r1=1.65&r2=1.66
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/examples/README.txt?cvsroot=groff&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/examples/elvis_syntax.new?cvsroot=groff&r1=1.11&r2=1.12
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/examples/letter.mom?cvsroot=groff&r1=1.4&r2=1.5
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/examples/mom.vim?cvsroot=groff&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/examples/sample_docs.mom?cvsroot=groff&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/examples/typesetting.mom?cvsroot=groff&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/examples/mom-pdf.mom?cvsroot=groff&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/examples/penguin.pdf?cvsroot=groff&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/appendices.html?cvsroot=groff&r1=1.22&r2=1.23
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/color.html?cvsroot=groff&r1=1.14&r2=1.15
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/cover.html?cvsroot=groff&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/definitions.html?cvsroot=groff&r1=1.19&r2=1.20
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/docelement.html?cvsroot=groff&r1=1.38&r2=1.39
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/docprocessing.html?cvsroot=groff&r1=1.40&r2=1.41
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/goodies.html?cvsroot=groff&r1=1.29&r2=1.30
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/graphical.html?cvsroot=groff&r1=1.8&r2=1.9
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/headfootpage.html?cvsroot=groff&r1=1.23&r2=1.24
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/images.html?cvsroot=groff&r1=1.2&r2=1.3
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/inlines.html?cvsroot=groff&r1=1.26&r2=1.27
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/intro.html?cvsroot=groff&r1=1.21&r2=1.22
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/letters.html?cvsroot=groff&r1=1.17&r2=1.18
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/macrolist.html?cvsroot=groff&r1=1.19&r2=1.20
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/rectoverso.html?cvsroot=groff&r1=1.15&r2=1.16
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/refer.html?cvsroot=groff&r1=1.13&r2=1.14
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/reserved.html?cvsroot=groff&r1=1.42&r2=1.43
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/stylesheet.css?cvsroot=groff&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/tables-of-contents.html?cvsroot=groff&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/toc.html?cvsroot=groff&r1=1.40&r2=1.41
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/typesetting.html?cvsroot=groff&r1=1.29&r2=1.30
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/using.html?cvsroot=groff&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/groff/contrib/mom/momdoc/version-2.html?cvsroot=groff&rev=1.1

Patches:
Index: BUGS
===================================================================
RCS file: /sources/groff/groff/contrib/mom/BUGS,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -b -r1.49 -r1.50
--- BUGS        8 Sep 2011 18:30:42 -0000       1.49
+++ BUGS        31 Aug 2012 22:49:57 -0000      1.50
@@ -1,4 +1,4 @@
-    Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
+    Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
       Free Software Foundation, Inc.
 
     Copying and distribution of this file, with or without modification,
@@ -20,10 +20,20 @@
 
 --Peter Schaffter
 
-========================================================================
+====================================================================
+
+Version 2.0
+===========
+
+====================================================================
+
 Version 6-a
 ===========
 
+Footnotes on last page of columnar docs before a TOC getting printed
+at bottom of last column, not current column.
+--Fixed---
+
 HEADER_RULE OFF turning off headers completely.
 ---Fixed---
 

Index: ChangeLog
===================================================================
RCS file: /sources/groff/groff/contrib/mom/ChangeLog,v
retrieving revision 1.73
retrieving revision 1.74
diff -u -b -r1.73 -r1.74
--- ChangeLog   21 Feb 2012 21:14:19 -0000      1.73
+++ ChangeLog   31 Aug 2012 22:49:57 -0000      1.74
@@ -1,3 +1,10 @@
+* Fri Aug 31 2012
+
+o Version 2.0 release.  Changes documented in version-2.html in
+  the html documentation.
+
+o Added new documentation, Producing PDFs with groff and mom.
+
 * Sat Feb 18 2012
 
 o Added choice to have DOCTYPE NAMED <name> underscored or not when

Index: Makefile.sub
===================================================================
RCS file: /sources/groff/groff/contrib/mom/Makefile.sub,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -b -r1.28 -r1.29
--- Makefile.sub        24 Aug 2010 16:18:34 -0000      1.28
+++ Makefile.sub        31 Aug 2012 22:49:57 -0000      1.29
@@ -20,11 +20,13 @@
 # These may be overridden if cross-compiling.
 GROFFBIN=$(top_builddir)/src/roff/groff/groff
 GROFF_BIN_PATH=`echo $(groff_bin_dirs) | sed -e 's|  *|$(SH_SEP)|g'`
+PDFMOMBIN=$(top_builddir)/src/devices/gropdf/pdfmom
 
 groff_bin_dirs=\
   $(top_builddir)/src/roff/groff \
   $(top_builddir)/src/roff/troff \
-  $(top_builddir)/src/devices/grops
+  $(top_builddir)/src/devices/grops \
+  $(top_builddir)/src/devices/gropdf
 
 FFLAG=-F$(top_builddir)/font -F$(top_srcdir)/font
 TFLAG=-M$(top_builddir)/tmac -M$(top_srcdir)/tmac -M$(srcdir)
@@ -35,6 +37,12 @@
       export GROFF_BIN_PATH; \
       $(GROFFBIN) $(FFLAG) $(TFLAG)
 
+PDFMOM=GROFF_COMMAND_PREFIX=''; \
+      export GROFF_COMMAND_PREFIX; \
+      PDFMOM_BIN_PATH=$(top_builddir)/src/devices/gropdf; \
+      export PDFMOM_BIN_PATH; \
+      $(PDFMOMBIN) $(FFLAG) $(TFLAG)
+
 MAN7=\
   groff_mom.n
 
@@ -67,44 +75,56 @@
   momdoc/tables-of-contents.html \
   momdoc/toc.html \
   momdoc/typesetting.html \
-  momdoc/using.html
+  momdoc/using.html \
+  momdoc/version-2.html
 
 EXAMPLEFILES=\
   examples/letter.mom \
+  examples/mom-pdf.mom \
   examples/sample_docs.mom \
   examples/typesetting.mom \
   examples/README.txt \
   examples/elvis_syntax \
   examples/elvis_syntax.new \
-  examples/penguin.ps
+  examples/penguin.ps \
+  examples/penguin.pdf \
+  examples/mom.vim
 
 PROCESSEDEXAMPLEFILES=\
-  examples/letter.ps \
-  examples/sample_docs.ps \
-  examples/typesetting.ps
+  examples/letter.pdf \
+  examples/mom-pdf.pdf \
+  examples/sample_docs.pdf \
+  examples/typesetting.pdf
 
 HTMLDOCFILES_=`echo $(HTMLDOCFILES) | sed 's|momdoc/||g'`
 EXAMPLEFILES_=`echo $(EXAMPLEFILES) | sed 's|examples/||g'`
 PROCESSEDEXAMPLEFILES_=`echo $(PROCESSEDEXAMPLEFILES) | sed 's|examples/||g'`
+PDFDOCFILE=mom-pdf.pdf
 
 MOSTLYCLEANADD=\
   stamp-strip \
   penguin.ps \
+  penguin.pdf \
   $(PROCESSEDEXAMPLEFILES) \
   examples/stamp \
   om.tmac-s
 
-.SUFFIXES: .mom .ps
-.mom.ps:
-       $(GROFF) -Tps -mom $< >$@
-
+#.SUFFIXES: .mom .ps
+#.mom.ps:
+#      $(GROFF) -Tps -mom $< >$@
+
+.SUFFIXES: .mom .pdf
+.mom.pdf:
+       $(PDFMOM) $< >$@
 
 all: stamp-strip $(PROCESSEDEXAMPLEFILES)
 
-$(PROCESSEDEXAMPLEFILES): penguin.ps examples/stamp
+$(PROCESSEDEXAMPLEFILES): penguin.ps penguin.pdf examples/stamp
 
 penguin.ps:
        cp $(srcdir)/examples/penguin.ps .
+penguin.pdf:
+       cp $(srcdir)/examples/penguin.pdf .
 
 examples/stamp:
        test -d examples || $(mkinstalldirs) examples
@@ -139,6 +159,10 @@
          rm -f $(DESTDIR)$(exampledir)/mom/$$f; \
          $(INSTALL_DATA) examples/$$f $(DESTDIR)$(exampledir)/mom/$$f; \
        done
+       for f in $(PDFDOCFILE); do \
+         rm -f $(DESTDIR)$(pdfdocdir)/$$f; \
+         ln -s $(DESTDIR)$(exampledir)/mom/$$f $(DESTDIR)$(pdfdocdir)/$$f; \
+       done
 
 stamp-strip: $(STRIPFILES)
        for f in $(STRIPFILES); do \
@@ -158,4 +182,7 @@
        -for f in $(EXAMPLEFILES_) $(PROCESSEDEXAMPLEFILES_); do \
          rm -f $(DESTDIR)$(exampledir)/mom/$$f; \
        done
+       -for f in $(PDFDOCFILE); do \
+         rm -f $(DESTDIR)$(pdfdocdir)/$$f; \
+       done
        -rmdir $(DESTDIR)$(exampledir)/mom

Index: NEWS
===================================================================
RCS file: /sources/groff/groff/contrib/mom/NEWS,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -b -r1.34 -r1.35
--- NEWS        22 Feb 2011 19:42:29 -0000      1.34
+++ NEWS        31 Aug 2012 22:49:57 -0000      1.35
@@ -1,10 +1,48 @@
-    Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
+    Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
       Free Software Foundation, Inc.
 
     Copying and distribution of this file, with or without modification,
     are permitted in any medium without royalty provided the copyright
     notice and this notice are preserved.
 
+Release 2.0
+-----------
+Full integration with gropdf.  Mom's focus now is on the generation
+of PDF output.  PDF outlines and PDF links (internal and external)
+fully supported.
+
+New management of nested heading levels via HEADING <level>,
+replacing HEAD, SUBHEAD, SUBSUBHEAD and PARAHEAD.
+
+"NAMED <id>" argument to HEADING <level> creates PDF target at the
+heading.
+
+Use of "oldstyle" headings preserved, allowing the continued use of HEAD,
+SUBHEAD, etc.  
+
+PARAHEAD removed; replaced by HEADING <level> PARAHEAD.
+
+New management of head styling.
+
+New management of TOC, mostly transparent to user.
+
+New management of TOC title and entry styling.
+
+Overhaul of TOC default style; greater flexibility in numbering
+entries, improved indenting, improved spacing.
+
+FLOAT macro added.
+
+MN_INIT wrapper re-written such that each argument must be preceded
+by a flag.
+
+New perl script, pdfmom, to facilitate generation of PDF output.
+
+Additional documentation in the form of a PDF manual, which covers
+mom/PDF/groff usage.
+
+====================================================================
+
 Release 1.6-a
 -------------
 Support for sub-subheads added.

Index: TODO
===================================================================
RCS file: /sources/groff/groff/contrib/mom/TODO,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -b -r1.15 -r1.16
--- TODO        3 Oct 2010 23:26:29 -0000       1.15
+++ TODO        31 Aug 2012 22:49:57 -0000      1.16
@@ -1,26 +1,10 @@
-    Copyright 2004, 2005, 2006, 2007, 2008, 2009
+    Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
       Free Software Foundation, Inc.
 
     Copying and distribution of this file, with or without modification,
     are permitted in any medium without royalty provided the copyright
     notice and this notice are preserved.
 
-As of version 1.2, the items on this TODO list will only be dealt
-with if users request they be implemented.
+Version 2.0
 
-CROSS-REFERENCING
------------------
-
-TOC
----
-Capability of generating a separate file for TOCs, for collating
-and processing with gs/ps2pdf.
-
-NUMBERED HEADS, SUBHEADS and PARAHEADS
---------------------------------------
-Macros to set numbering style (roman, arabic, alpha, etc)?
-
-FOOTNOTES
----------
-In columnar docs, maybe give user the choice of gathering all
-footnotes at the bottom of the last column?
+(nothing yet)

Index: copyright
===================================================================
RCS file: /sources/groff/groff/contrib/mom/copyright,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -b -r1.11 -r1.12
--- copyright   18 Aug 2010 22:48:33 -0000      1.11
+++ copyright   31 Aug 2012 22:49:57 -0000      1.12
@@ -7,8 +7,8 @@
 ========================================================================
 
 The groff macro file om.tmac and the html documentation pertaining
-to it are copyright (c) 2004, 2005, 2006, 2007, 2008, 2009, 2010
-  Peter Schaffter.
+to it are copyright (c) 2004, 2005, 2006, 2007, 2008, 2009, 2010,
+2011, 2012 Peter Schaffter.
 
 om.tmac is issued under the GNU General Public License, a full copy of
 which can be had at

Index: groff_mom.man
===================================================================
RCS file: /sources/groff/groff/contrib/mom/groff_mom.man,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- groff_mom.man       7 Jul 2012 20:49:08 -0000       1.16
+++ groff_mom.man       31 Aug 2012 22:49:57 -0000      1.17
@@ -1,9 +1,10 @@
 .ig
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2002, 2003, 2005, 2008, 2009, 2011
+Copyright (C) 2002, 2003, 2005, 2008, 2009, 2011, 2012
   Free Software Foundation, Inc.
 written by Werner Lemberg <address@hidden>
+revised 2012 by Peter Schaffter <address@hidden>
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -34,37 +35,78 @@
 .
 .SH SYNOPSIS
 .
-.B groff
-.B \-mom
-[
-.IR files .\|.\|.\&
-]
-.br
-.B groff
-.B \-m\ mom
-[
-.IR files .\|.\|.\&
-]
-.
+.SY pdfmom
+.OP \-Tps "\fR[pdfroff options]"
+[groff options]
+.I files .\|.\|.
+.YS
+.
+.SY groff
+.OP \-mom
+.I files .\|.\|.
+.YS
+.
+.SY groff
+.OP "\-m mom"
+.I files .\|.\|.
+.YS
 .
 .SH DESCRIPTION
 .
 .B mom
-(\[lq]my own macros\[rq], \[lq]my other macros\[rq], \[lq]maximum
-overdrive macros\[rq], .\|.\|.\&) is a macro set for groff, designed
-primarily to format documents for PostScript output.
-.PP
+is a macro set for groff, designed primarily to format documents for
+PDF and PostScript output.
+.P
 .B mom
-provides two categories of macros: macros for typesetting and macros
-for document processing.
-The typesetting macros provide access to groff's typesetting power in
-ways that are simpler to master and to use than groff's primitives.
-The document processing macros provide customizable markup
-\[lq]tags\[rq] that allow the user to design and output
-professional-looking documents with a minimum of typesetting
-intervention.
-.PP
-mom comes with her own (very) complete documentation in HTML format.
+provides two categories of macros: macros for typesetting, and
+macros for document processing.
+The typesetting macros provide access to groff's typesetting
+capabilities in ways that are simpler to master than groff's
+primitives.
+The document processing macros provide highly customizable markup
+tags that allow the user to design and output professional-looking
+documents with a minimum of typesetting intervention.
+.P
+Files processed with
+.B pdfmom
+(man(@MAN1EXT@)
+.BR pdfmom\c
+), with or without the
+.RI -T ps
+option, produce PDF documents.
+The documents include a PDF outline that appears in the
+\[oq]Contents\[cq] panel of document viewers, and may contain
+clickable internal and external links.
+.P
+When
+.RI -T ps
+is absent,
+.B groff's
+native PDF driver,
+.B gropdf\c
+, is used to generate the output.
+When given, the output is still PDF, but processing is passed over to
+.B pdfroff\c
+, which uses
+.B groff's
+PostScript driver,
+.B grops\c
+\&.
+Not all PDF features are available when
+.RI -T ps
+is given; its primary use is to allow processing of files with
+embedded PostScript images.
+.P
+Files processed with
+.B groff -mom
+(or
+.BI "-m " mom
+) produce PostScript output by default.
+.P
+mom comes with her own very complete documentation in HTML format.
+A separate PDF manual,
+.I Producing PDFs with groff and mom\c
+, covers full mom/PDF usage.
 .
 .SH FILES
 .TP
@@ -75,10 +117,16 @@
 \[en] a wrapper file that calls om.tmac directly.
 .
 .TP
-.URL @HTMLDOCDIR@/\:mom/\:toc.html
+.UR address@hidden@/\:mom/\:toc.html
+.UE
 \[en] entry point to the HTML documentation
 .
 .TP
+.BR address@hidden@/\:mom-pdf.pdf
+\[en] the PDF manual,
+.I Producing PDFs with groff and mom
+.
+.TP
 .B @EXAMPLEDIR@/mom/*.mom
 \[en] example files using mom
 .
@@ -90,11 +138,17 @@
 .MT address@hidden
 Peter Schaffter
 .ME .
+.br
+PDF support was provided by
+.MT address@hidden
+Deri James
+.ME .
+.sp
 Please send bug reports to the
 .MT address@hidden
-groff bug mailing list
+groff-bug mailing list
 .ME
-or directly to the author at the address, above.
+or directly to the authors.
 .
 .cp \n[groff_mom_C]
 .

Index: om.tmac
===================================================================
RCS file: /sources/groff/groff/contrib/mom/om.tmac,v
retrieving revision 1.65
retrieving revision 1.66
diff -u -b -r1.65 -r1.66
--- om.tmac     21 Feb 2012 21:14:20 -0000      1.65
+++ om.tmac     31 Aug 2012 22:49:57 -0000      1.66
@@ -2,15 +2,17 @@
 .ig
 Mom -- a typesetting/document-processing macro set for groff.
 
-Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
-  Free Software Foundation, Inc.
-     Written by Peter Schaffter (address@hidden)
+Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
+2011, 2012
+Free Software Foundation, Inc.
+ Written by Peter Schaffter <address@hidden>
+ PDF integration contributed by Deri James <address@hidden>
 
 This file is part of groff.
 
-groff is free software; you can redistribute it and/or modify it under
-the terms of the GNU General Public License as published by the Free
-Software Foundation, either version 3 of the License, or
+groff is free software; you can redistribute it and/or modify it
+under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
 (at your option) any later version.
 
 groff is distributed in the hope that it will be useful, but WITHOUT ANY
@@ -21,28 +23,25 @@
 You should have received a copy of the GNU General Public License
 along with this program. If not, see <http://www.gnu.org/licenses/>.
 
-Version 1.6-a
--------------
+Version 2.0
+-----------
 Antoine de St-Exupéry asserted that elegance in engineering is
 achieved not when there is nothing left to add, but when there is
 nothing left to take away.
 
 By those standards, mom is a Rube Goldberg contraption.  She was
 created over the years while groff, and my understanding of it,
-changed and evolved.  However, I'm a firm believer in "if it
-ain't broke, don't fix it," so I'm leaving any major clean-up
-of redundancies and whatnot for a rainy day.
-
-Inasmuch as possible, macros that turn a feature on or off follow
-a similar style.  Invoking the macro without an argument turns
-the feature on.  Invoking it with any other argument turns it off.
-Use of the argument OFF is recommended, but not required; users
-may find other conventions preferable (e.g. NO, X, END, QUIT, etc.).
+changed and evolved.  However, I'm a firm believer in "if it ain't
+broke, don't fix it."  Version 2.0 removes some of the redundancies
+and cruft, but mom still needs some nip and tuck.
 
 "<anything>" in the description of arguments that can be passed
 to a macro means that any argument turns the feature off.
 
-Thanks to everyone who has contributed suggestions and patches.
+Thanks to everyone who has contributed suggestions and patches, and
+to those whose GPL'd work has been plundered.  Special thanks to
+Werner Lemberg (margin notes), Tadziu Hoffman (underlining), and
+Deri James (pdf integration).
 ..
 .\" %beginstrip%
 \#
@@ -54,46 +53,123 @@
 \# Check that GNU troff is being run
 .if !\n[.g]=1 \
 .   ab [mom]: The mom macros require that you be running GNU troff.
-.if \n(.C \
+.if \n[.C] \
 .   ab [mom]: The groff mom macros do not work in compatibility mode.
 \# Add supplementary styles
+.sty \n[.fp] UL      \"  Ultra Light
+.sty \n[.fp] ULI     \"  Ultra Light Italic
+.sty \n[.fp] ULCD    \"  Ultra Light Condensed
+.sty \n[.fp] ULCDI   \"  Ultra Light Condensed Italic
+.sty \n[.fp] ULEX    \"  Ultra Light Extended
+.sty \n[.fp] ULEXI   \"  Ultra Light Extended Italic
+\#
+.sty \n[.fp] XL      \"  Extra Light
+.sty \n[.fp] XLI     \"  Extra Light Italic
+.sty \n[.fp] XLCD    \"  Extra Light Condensed
+.sty \n[.fp] XLCDI   \"  Extra Light Condensed Italic
+.sty \n[.fp] XLEX    \"  Extra Light Extended
+.sty \n[.fp] XLEXI   \"  Extra Light Extended Italic
+\#
+.sty \n[.fp] TH      \"  Thin
+.sty \n[.fp] THI     \"  Thin Italic
+.sty \n[.fp] THCD    \"  Thin Condensed
+.sty \n[.fp] THCDI   \"  Thin Condensed Italic
+.sty \n[.fp] THEX    \"  Thin Extended
+.sty \n[.fp] THEXI   \"  Thin Extended Italic
+\#
 .sty \n[.fp] L       \"  Light Roman
 .sty \n[.fp] LI      \"  Light Italic
-.sty \n[.fp] LCD     \"  Light Condensed Roman
+.sty \n[.fp] LCD     \"  Light Condensed
 .sty \n[.fp] LCDI    \"  Light Condensed Italic
-.sty \n[.fp] LEX     \"  Light Extended Roman
+.sty \n[.fp] LEX     \"  Light Extended
 .sty \n[.fp] LEXI    \"  Light Extended Italic
-.sty \n[.fp] CD      \"  Medium/Book Condensed Roman
-.sty \n[.fp] CDI     \"  Medium/Book Condensed Italic
-.sty \n[.fp] EX      \"  Medium/Book Extended Roman
-.sty \n[.fp] EXI     \"  Medium/Book Extended Italic
+\#
+.sty \n[.fp] BK      \"  Book Roman
+.sty \n[.fp] BKI     \"  Book Italic
+.sty \n[.fp] BKCD    \"  Book Condensed
+.sty \n[.fp] BKCDI   \"  Book Condensed Italic
+.sty \n[.fp] BKEX    \"  Book Extended
+.sty \n[.fp] BKEXI   \"  Book Extended Italic
+\#
+.sty \n[.fp] CD      \"  Medium Condensed
+.sty \n[.fp] CDI     \"  Medium Condensed Italic
+.sty \n[.fp] EX      \"  Medium Extended
+.sty \n[.fp] EXI     \"  Medium Extended Italic
+\#
 .sty \n[.fp] DB      \"  DemiBold Roman
 .sty \n[.fp] DBI     \"  DemiBold Italic
-.sty \n[.fp] BCD     \"  Bold Condensed Roman
+.sty \n[.fp] DBCD    \"  DemiBold Condensed
+.sty \n[.fp] DBCDI   \"  DemiBold Condensed Italic
+.sty \n[.fp] DBEX    \"  DemiBold Extended
+.sty \n[.fp] DBEXI   \"  DemiBold Extended Italic
+\#
+.sty \n[.fp] SB      \"  SemiBold Roman
+.sty \n[.fp] SBI     \"  SemiBold Italic
+.sty \n[.fp] SBCD    \"  SemiBold Condensed
+.sty \n[.fp] SBCDI   \"  SemiBold Condensed Italic
+.sty \n[.fp] SBEX    \"  SemiBold Extended
+.sty \n[.fp] SBEXI   \"  SemiBold Extended Italic
+\#
+.sty \n[.fp] BCD     \"  Bold Condensed
 .sty \n[.fp] BCDI    \"  Bold Condensed Italic
-.sty \n[.fp] BEX     \"  Bold Extended Roman
+.sty \n[.fp] BEX     \"  Bold Extended
 .sty \n[.fp] BEXI    \"  Bold Extended Italic
-.sty \n[.fp] HV      \"  Heavy Roman
+.sty \n[.fp] BO      \"  Bold Outline
+\#
+.sty \n[.fp] XB      \"  Extra Bold
+.sty \n[.fp] XBI     \"  Extra Bold Italic
+.sty \n[.fp] XBCD    \"  Extra Bold Condensed
+.sty \n[.fp] XBCDI   \"  Extra Bold Condensed Italic
+.sty \n[.fp] XBEX    \"  Extra Bold Extended
+.sty \n[.fp] XBEXI   \"  Extra Bold Extended Italic
+\#
+.sty \n[.fp] UB      \"  Ultra Bold
+.sty \n[.fp] UBI     \"  Ultra Bold Italic
+.sty \n[.fp] UBCD    \"  Ultra Bold Condensed
+.sty \n[.fp] UBCDI   \"  Ultra Bold Condensed Italic
+.sty \n[.fp] UBEX    \"  Ultra Bold Extended
+.sty \n[.fp] UBEXI   \"  Ultra Bold Extended Italic
+\#
+.sty \n[.fp] HV      \"  Heavy
 .sty \n[.fp] HVI     \"  Heavy Italic
-.sty \n[.fp] HVCD    \"  Heavy Condensed Roman
+.sty \n[.fp] HVCD    \"  Heavy Condensed
 .sty \n[.fp] HVCDI   \"  Heavy Condensed Italic
-.sty \n[.fp] HVEX    \"  Heavy Extended Roman
+.sty \n[.fp] HVEX    \"  Heavy Extended
 .sty \n[.fp] HVEXI   \"  Heavy Extended Italic
-.sty \n[.fp] BL      \"  Black Roman
+\#
+.sty \n[.fp] BL      \"  Black
 .sty \n[.fp] BLI     \"  Black Italic
-.sty \n[.fp] BLCD    \"  Black Condensed Roman
+.sty \n[.fp] BLCD    \"  Black Condensed
 .sty \n[.fp] BLCDI   \"  Black Condensed Italic
-.sty \n[.fp] BLEX    \"  Black Extended Roman
+.sty \n[.fp] BLEX    \"  Black Extended
 .sty \n[.fp] BLEXI   \"  Black Extended Italic
-.sty \n[.fp] UBL     \"  Ultra-Black Roman
-.sty \n[.fp] UBLI    \"  Ultra-Black Italic
+.sty \n[.fp] BLO     \"  Black Outline
+\#
+.sty \n[.fp] XBL     \"  Extra Black
+.sty \n[.fp] XBLI    \"  Extra Black Italic
+.sty \n[.fp] XBLCD   \"  Extra Black
+.sty \n[.fp] XBLCDI  \"  Extra Black
+.sty \n[.fp] XBLEX   \"  Extra Black Italic
+.sty \n[.fp] XBLEXI  \"  Extra Black Italic
+\#
+.sty \n[.fp] UBL     \"  Ultra Black
+.sty \n[.fp] UBLI    \"  Ultra Black Italic
+.sty \n[.fp] UBLCD   \"  Ultra Black Condensed
+.sty \n[.fp] UBLCDI  \"  Ultra Black Condensed Italic
+.sty \n[.fp] UBLEX   \"  Ultra Black Exteneded
+.sty \n[.fp] UBLEXI  \"  Ultra Black Extended Italic
+\#
+.sty \n[.fp] SC      \"  Small Caps Roman
+.sty \n[.fp] SCI     \"  Small Caps Italic
+.sty \n[.fp] SCDB    \"  Small Caps Demibold
+.sty \n[.fp] SCDBI   \"  Small Caps Demibold Italic
+.sty \n[.fp] SCSB    \"  Small Caps Semibold
+.sty \n[.fp] SCSBI   \"  Small Caps Semibold Italic
 \#
 \# Instruct grops to use square linecaps and joins.
 \# This instruction is also executed in DO_B_MARGIN, NEWPAGE, and HEADER
 \#
-.if !n \{\
-\X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap'
-.\}
+.if !n \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap'
 \#
 \# The following PostScript, provided by Tadziu Hoffmann, permits
 \# no-fail underlining
@@ -134,9 +210,11 @@
 /T { moveto 0 exch 0 SC 5 2 roll X awidthshow Y } def
 end
 ..
-.if !n \{\
-\Y[ul*ps]
-.\}
+\#
+.if !n \Y[ul*ps]
+.if n .color 0
+.nr TOC.RELOCATE 0 \" TOC.RELOCATE is off by default
+.ds PDFHREF.TEXTCOL.DEFAULT 0.0 0.3 0.9
 \#
 \# ====================================================================
 \#
@@ -150,14 +228,11 @@
 .als      ALIAS           als
 .als      ALIASN          aln
 \#
-\#
 \# ALIASES FOR GROFF REQUESTS
 \# --------------------------
 \#
 .ALIAS    MAC             de
 .ALIAS    BR              br
-.ALIAS    SP              sp
-.ALIAS    PAGELENGTH      pl
 .ALIAS    SPREAD          brp
 .ALIAS    ESC_CHAR        ec
 .ALIAS    STRING          ds
@@ -170,7 +245,7 @@
 .ALIASN  #DIVER_DEPTH     dn    \"diversion depth
 .ALIASN  #DIVER_WIDTH     dl    \"diversion width
 .ALIASN  #TRAP_DISTANCE  .t     \"distance to next trap
-.ALIASN  #LEAD           .v     \"line space (.vs, not .ls)
+.ALIASN  #LEAD           .v     \"line space
 .ALIASN  #PAGE_LENGTH    .p     \"page length
 .ALIASN  #NUM_ARGS       .$     \"number of arguments passed to a macro
 .ALIASN  #INDENT         .i     \"value of current indent
@@ -179,32 +254,8 @@
 \#
 \# MISCELLANEOUS
 \# =============
-.nr #L_MARGIN \n(.o  \" Tabs, etc require #L_MARGIN
-.cflags 4 /\(en      \" So slash and en-dashes get broken
-.warn 8192
-\#
-\# About the warn level
-\# --------------------
-\# 
-\# There's a lot of testing for the presence of number registers and
-\# strings in this macro file.  Many of the registers and strings
-\# pop into and out of existence on the fly.  For convenience, I
-\# often use
-\# 
-\#     .if \\n[whatever]    and    .if !\\n[whatever]
-\# 
-\# to test "if the register exists and is (not) empty."  Groff,
-\# encountering such tests when called with the -ww options, emits
-\# 
-\#     warning: number register whatever not defined.
-\# 
-\# Groff also warns about strings similarly tested for.
-\# 
-\# The warn level, above, is high in order to shut off those
-\# warnings.  If you're futzing in this file and need more verbose
-\# warnings, either comment out ".warn 8192" or set the warnlevel
-\# to the one you need (but be ready for lots of what I've just
-\# described).
+.nr #L_MARGIN \n[.o]  \" Tabs, etc require #L_MARGIN
+.cflags 4 /\[en]      \" So slash and en-dashes get broken
 \#
 \# ====================================================================
 \#
@@ -226,11 +277,11 @@
 .MAC PAGEWIDTH END
 .    br
 .    nr #PAGE_WIDTH \\$1
-.    if !r#L_MARGIN \{ .L_MARGIN \\n(.o \}
-.    if !r#R_MARGIN \{ .R_MARGIN 1i \}
+.    if !r#L_MARGIN .L_MARGIN \\n[.o]
+.    if !r#R_MARGIN .R_MARGIN 1i
+.    if '\\*[.T]'pdf' \X'papersize=\\n[#PAGE_WIDTH]z,\\n[#PAGE_LENGTH]z'
 .END
 \#
-\#
 \# L_MARGIN
 \# --------
 \# *Argument:
@@ -247,7 +298,6 @@
 .    po \\n[#L_MARGIN]u
 .END
 \#
-\#
 \# R_MARGIN
 \# --------
 \# *Argument:
@@ -267,11 +317,10 @@
 .    br
 .    nr #R_MARGIN (\\$1)
 .    ll \\n[#PAGE_WIDTH]u-\\n[#L_MARGIN]u-\\n[#R_MARGIN]u
-.    ta \\n(.lu
-.    nr #L_LENGTH \\n(.l
+.    ta \\n[.l]u
+.    nr #L_LENGTH \\n[.l]
 .END
 \#
-\#
 \# T_MARGIN
 \# --------
 \# *Argument:
@@ -285,13 +334,10 @@
 .MAC T_MARGIN END
 .    nr #T_MARGIN (\\$1)
 .    nr #TOP 1
-.    if !\\n[#DOCS] \{\
-.       sp |\\n[#T_MARGIN]u-1v
-.    \}
+.    if !\\n[#DOCS] .sp |\\n[#T_MARGIN]u-1v
 .    wh 0i DO_T_MARGIN
 .END
 \#
-\#
 \# B_MARGIN
 \# --------
 \# *Argument:
@@ -309,7 +355,6 @@
 .    wh -\\n[#B_MARGIN]u DO_B_MARGIN
 .END
 \#
-\#
 \# PAGE
 \# ----
 \# *Arguments:
@@ -328,12 +373,19 @@
 .    br
 .    PAGEWIDTH   \\$1
 .    PAGELENGTH  \\$2
-.    ie '\\$3''  \{ .L_MARGIN \\n(.o  \}
-.    el          \{ .L_MARGIN \\$3    \}
-.    ie '\\$4''  \{ .R_MARGIN 1i      \}
-.    el          \{ .R_MARGIN \\$4    \}
-.    if !'\\$5'' \{ .T_MARGIN \\$5    \}
-.    if !'\\$6'' \{ .B_MARGIN \\$6    \}
+.    ie '\\$3''  .L_MARGIN \\n[.o]
+.    el          .L_MARGIN \\$3
+.    ie '\\$4''  .R_MARGIN 1i
+.    el          .R_MARGIN \\$4
+.    if !'\\$5'' .T_MARGIN \\$5
+.    if !'\\$6'' .B_MARGIN \\$6
+.END
+\#
+\# gropdf: pass pagelength to postprocessor; no need for -P-p
+\#
+.MAC PAGELENGTH END
+.    pl \\$*
+.    if '\\*[.T]'pdf' \X'papersize=\\n[#PAGE_WIDTH]z,\\n[#PAGE_LENGTH]z'
 .END
 \#
 \# =====================================================================
@@ -359,7 +411,6 @@
 .    sp -\\n[#T_MARGIN_LEAD_ADJ]u
 .END
 \#
-\#
 \# DO_B_MARGIN
 \# -----------
 \# *Argument:
@@ -373,11 +424,10 @@
 .    nr #T_MARGIN_LEAD_ADJ \\n[#LEAD]-12000
 .    ev B_MARGIN
 .    bp
-.    if !n \{ .nop \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap' \}
+.    if !n .nop \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap'
 .    ev
 .END
 \#
-\#
 \# NEWPAGE
 \# -------
 \# *Argument:
@@ -393,42 +443,32 @@
 '       br
 .       rr #NO_BREAK
 .    \}
-.    el \{\
-.       br
-.    \}
+.    el .br
 .    nr #NEWPAGE 1
 .    ie \\n[#B_MARGIN_SET]=1 \{\
 .       ie !\\n[#DOCS]=1 \{\
 .          ev NP
 .          bp
-.          if !n \{ .nop \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap' \}
+.          if !n .nop \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap'
 .          ev
 .       \}
 .       el \{\
-.          if \\n[#COLUMNS]=1 \{ .nr #COL_NUM \\n[#NUM_COLS] \}
+.          if \\n[#COLUMNS]=1 .nr #COL_NUM \\n[#NUM_COLS]
 .          ie !\\n[#FN_DEPTH] \{\
 .             ch FN_OVERFLOW_TRAP
-.             DO_B_MARGIN
+.             bp
 .             wh -(\\n[#FN_OVERFLOW_TRAP_POS]u) FN_OVERFLOW_TRAP
 .          \}
-.          el \{\
-.             DO_B_MARGIN
-.          \}
+.          el .bp
 .       \}
 .    \}
-.    el \{\
-.       DO_B_MARGIN
-.    \}
+.    el .DO_B_MARGIN
 .END
 \#
 \# =====================================================================
 \#
 \# +++GENERAL STYLE MACROS+++
 \#
-\# Macros that are likely to appear together to define general
-\# type style: line length, family, font, point size, and line
-\# spacing.
-\#
 \# LINE LENGTH
 \# -----------
 \# *Argument:
@@ -442,11 +482,10 @@
 .MAC LL END
 .    nr #USER_SET_L_LENGTH 1
 .    ll \\$1
-.    nr #L_LENGTH \\n(.l
-.    ta \\n(.lu
+.    nr #L_LENGTH \\n[.l]
+.    ta \\n[.l]u
 .END
 \#
-\#
 \# +++FAMILY AND FONT+++
 \#
 \# FALLBACK FONT
@@ -468,20 +507,18 @@
 \#
 .MAC FALLBACK_FONT END
 .    if \\n[#NUM_ARGS]=1 \{\
-.       if '\\$1'ABORT' \{ .nr #ABORT_FT_ERRORS 1 \}
+.       if '\\$1'ABORT' .nr #ABORT_FT_ERRORS 1
 .       if '\\$1'WARN' \{\
-.          if r#ABORT_FT_ERRORS \{ .nr #ABORT_FT_ERRORS 0 \}
+.          if r #ABORT_FT_ERRORS .nr #ABORT_FT_ERRORS 0
 .       \}
 .       if !'\\$1'ABORT' \{\
-.          if !'\\$1'WARN' \{\
-.             fp 0 dummy \\$1
-.          \}
+.          if !'\\$1'WARN' .fp 0 dummy \\$1
 .       \}
 .    \}
 .    if \\n[#NUM_ARGS]=2 \{\
 .       fp 0 dummy \\$1
-.       if '\\$2'ABORT' \{ .nr #ABORT_FT_ERRORS 1 \}
-.       if '\\$2'WARN'  \{ .nr #ABORT_FT_ERRORS 0 \}
+.       if '\\$2'ABORT' .nr #ABORT_FT_ERRORS 1
+.       if '\\$2'WARN'  .nr #ABORT_FT_ERRORS 0
 .    \}
 .END
 \#
@@ -505,26 +542,21 @@
 .       fam \\*[$TYPEWRITER_FAM]
 .       return
 .    \}
-.    if (\\n[.x]\\n[.y]\\n[.Y] >= 1192) \{\
-.       ds $SAVED_STYLE \\n[.sty]
-.    \}
+.    if (\\n[.x]\\n[.y]\\n[.Y] >= 1192) .ds $SAVED_STYLE \\n[.sty]
 .    ft 0
 .    fam \\*[$FAMILY]
 .    if (\\n[.x]\\n[.y]\\n[.Y] >= 1192) \{\
 .       ft \\*[$SAVED_STYLE]
-.       if !F\\n[.fn] \{\
-.          ft 0
-.       \}
+.       if !F\\n[.fn] .ft 0
 .    \}
-.    ie \\n[#PRE_COLLATE]=1 \{ . \}
+.    ie \\n[#PRE_COLLATE]=1 .
 .    el \{\
 .       if \\n[#COLLATE]=1 \{\
-.          if !r#START \{ .DOC_FAM \\*[$FAMILY] \}
+.          if !r#START .DOC_FAM \\*[$FAMILY]
 .       \}
 .    \}
 .END
 \#
-\#
 \# FONT
 \# ----
 \# *Argument:
@@ -547,9 +579,7 @@
 .          \}
 .       \}
 .       el \{\
-.          ev 1
 .          UNDERLINE OFF
-.          ev
 .       \}
 .       return
 .    \}
@@ -559,26 +589,25 @@
 .       if '\\n[.sty]'' \{\
 .          if !F\\n[.fn] \{\
 .             if !S\\*[$FONT] \{\
-.                tm1 "[mom]: Font style "\\*[$FONT]" at line \\n(.c has not 
been registered.
+.                tm1 "[mom]: Font style "\\*[$FONT]" at line \\n[.c] has not 
been registered.
 .                ie \\n[#ABORT_FT_ERRORS]=0 \{\
 .                   tm1 "       Continuing to process using fallback font.
 .                \}
-.                el .ab Aborting.
+.                el .ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
 .             \}
 .             if \\n[.f]=0 \{\
-.                tm1 "[mom]: Either font style "\\*[$FONT]" at line \\n(.c 
does not exist in family "\\n[.fam]",
-.                tm1 "       or family "\\n[.fam]" has not been installed in 
font/devps.
+.                tm1 "[mom]: Either font style "\\*[$FONT]" at line \\n[.c] 
does not exist in family "\\n[.fam]",
+.                tm1 "       or family "\\n[.fam]" has not been installed.
 .                ie \\n[#ABORT_FT_ERRORS]=0 \{\
 .                   tm1 "       Continuing to process using fallback font.
 .                \}
-.                el .ab Aborting.
+.                el .ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
 .             \}
 .          \}
 .       \}
 .    \}
 .END
 \#
-\#
 \# POINT SIZE
 \# ----------
 \# *Arguments:
@@ -590,18 +619,17 @@
 \#   Must NOT use a unit of measure.
 \#
 .MAC PT_SIZE END
-.    if \\n[#PRINT_STYLE]=1 \{ .return \}
-.    if \\n[#IGNORE]        \{ .return \}
+.    if \\n[#PRINT_STYLE]=1 .return
+.    if \\n[#IGNORE] .return
 .    nr #PT_SIZE_SET 1
 .    ps \\$1
 .    if \\n[#AUTO_LEAD] \{\
-.       ie \\n[#AUTOLEAD_FACTOR] \{ .vs 
\\n[#PT_SIZE]u*\\n[#AUTOLEAD_VALUE]u/1000u \}
-.       el \{ .vs \\n[#PT_SIZE]u+\\n[#AUTOLEAD_VALUE]u \}
+.       ie \\n[#AUTOLEAD_FACTOR] .vs \\n[#PT_SIZE]u*\\n[#AUTOLEAD_VALUE]u/1000u
+.       el .vs \\n[#PT_SIZE]u+\\n[#AUTOLEAD_VALUE]u
 .    \}
 .    nr #PT_SIZE_IN_UNITS \\n[.ps]
 .END
 \#
-\#
 \# SIZE (inline)
 \# -------------
 \# *Arguments:
@@ -617,7 +645,6 @@
 .ps \\$1
 .END
 \#
-\#
 \# LEADING
 \# -------
 \# *Argument:
@@ -630,16 +657,16 @@
 \#
 .MAC LS END
 .    br
-.    nr #OLD_LEAD \\n(.v
-.    if \\n[#PRINT_STYLE]=1 \{ .return \}
-.    if \\n[#IGNORE]        \{ .return \}
+.    nr #OLD_LEAD \\n[.v]
+.    if \\n[#PRINT_STYLE]=1 .return
+.    if \\n[#IGNORE] .return
 .    if \\n[#AUTO_LEAD] \{\
 .       rr #AUTO_LEAD
 .       rr #AUTOLEAD_FACTOR
 .    \}
 .    vs \\$1
 .    if \\n[#TOP] \{\
-.       nr #TOP_BASELINE_ADJ \\n(.v-\\n[#OLD_LEAD]
+.       nr #TOP_BASELINE_ADJ \\n[.v]-\\n[#OLD_LEAD]
 .       sp -\\n[#TOP_BASELINE_ADJ]u
 .       rr #TOP
 .       rr #TOP_BASELINE_ADJ
@@ -651,7 +678,6 @@
 .    ch RESET_LEAD
 .END
 \#
-\#
 \# AUTOLEAD
 \# --------
 \# *Argument:
@@ -667,10 +693,10 @@
 \#   together.
 \#
 .MAC AUTOLEAD END
-.    if \\n[#PRINT_STYLE]=1 \{ .return \}
-.    if \\n[#IGNORE]        \{ .return \}
+.    if \\n[#PRINT_STYLE]=1 .return
+.    if \\n[#IGNORE] .return
 .    nr #AUTO_LEAD 1
-.    nr #OLD_LEAD \\n(.v
+.    nr #OLD_LEAD \\n[.v]
 .    nr #AUTOLEAD_VALUE (p;\\$1)
 .    ie \\n[#NUM_ARGS]=2 \{\
 .       if '\\$2'FACTOR' \{\
@@ -678,24 +704,21 @@
 .          vs \\n[#PT_SIZE]u*\\n[#AUTOLEAD_VALUE]u/1000u
 .       \}
 .    \}
-.    el \{\
-.       vs \\n[#PT_SIZE]u+\\n[#AUTOLEAD_VALUE]u
-.    \}
+.    el .vs \\n[#PT_SIZE]u+\\n[#AUTOLEAD_VALUE]u
 .    if \\n[#TOP] \{\
-.       nr #TOP_BASELINE_ADJ \\n(.v-\\n[#OLD_LEAD]
+.       nr #TOP_BASELINE_ADJ \\n[.v]-\\n[#OLD_LEAD]
 .       sp -\\n[#TOP_BASELINE_ADJ]u
 .       rr #TOP
 .       rr #TOP_BASELINE_ADJ
 .    \}
 .END
 \#
-\#
 \# STRINGS FOR INLINE CONTROL OF GENERAL TYPE STYLE
 \# ------------------------------------------------
-.ds ROM  \EfR
-.ds IT   \EfI
-.ds BD   \EfB
-.ds BDI  \Ef(BI
+.ds ROM  \Ef[R]
+.ds IT   \Ef[I]
+.ds BD   \Ef[B]
+.ds BDI  \Ef[BI]
 .ds PREV \Ef[]
 .ds S    \Es
 \#
@@ -721,35 +744,23 @@
 .    \}
 .END
 \#
-\#
 \# INLINE KERNING AND HORIZONTAL MOVEMENT
 \# --------------------------------------
-\# Kerning
 \# 
-\# Inline kerning provides a simple method for users to adjust the
-\# amount of space between any two letters.  It's predicated on a
-\# unit of measure "U", which is 1/36 of the current point size as
-\# returned by \n[.ps].  E.g., if the current point size is 18,
-\# \n[.ps] returns 18000u, therefore U=500u.  Since U remains
-\# proportional relative to the current point size, the amount
-\# of kerning between two letters as expressed in Us remains
-\# visually similar regardless of changes in point size.
+\# Inline kerning provides a simple way to adjust the amount of
+\# space between any two letters.  It's predicated on a unit of
+\# measure "U", which is 1/36 of the current point size as returned
+\# by \n[.ps].  E.g., if the current point size is 18, \n[.ps]
+\# returns 18000u, therefore U=500u.  Since U remains proportional
+\# relative to the current point size, the amount of kerning
+\# between two letters as expressed in Us remains visually similar
+\# regardless of changes in point size.
 \# 
 \# N.B.--the amount of inline kerning supplied by \*[BU<n>] or
 \# \*[FU<n>] is added to or subtracted from any kerning that already
 \# takes place between two characters when automatic kerning is
 \# turned on.
 \# 
-\# In groff v. 1.17.2, it was not possible to pass arguments to macros that
-\# were called with inline escapes, nor thence to evaluate conditional
-\# expressions.  Consequently, each pseudo-escape \[BU<n>] had to be defined
-\# separately with ".char".
-\# 
-\# As of v. 1.18, one can pass arguments to inline strings/macros,
-\# hence it is now possible to do \*[BU n] where n, inline, is the desired
-\# number of kern units.  The original .char definitions have been left in
-\# for backward compatibility with documents created prior to mom-1.1.3c.
-\#
 .nr #KERN_UNIT 36
 .ds BU   \h'-(\En[#PT_SIZE]u/\n[#KERN_UNIT]u*\\$1u)'
 .ds FU   \h'(\En[#PT_SIZE]u/\n[#KERN_UNIT]u*\\$1u)'
@@ -772,10 +783,6 @@
 \# BP1...12.75 and FP1...12.75 move backwards or forwards inline by the
 \# specified number of points.
 \#
-\# Left in for backward compatibility with mom-1.1.3c, the
-\# preferred methods for inline horizontal movements are now
-\# \*[BCK <n><unit>] and \*[FWD <n><unit>].
-\#
 .ds BCK  \h'-\\$1'
 .ds FWD  \h'\\$1'
 \#
@@ -883,16 +890,10 @@
 .ds FP12.5   \h'12.5p'
 .ds FP12.75  \h'12.75p'
 \#
-\#
-\# WHOLE LINE KERNING (RW and EW)
-\# -----------------------------
-\# The line kerning macros are special instances of track kerning,
-\# used where a complete line needs to be tightened (or relaxed) in
-\# order to accomodate or remove one or two more characters
-\# than the default justification permits.
-\#
+\# WHOLE LINE (TRACK) KERNING
+\# --------------------------
 \# *Argument:
-\#   <amount of overall "kerning" (letter spacing) to apply to the line>
+\#   <amount of track kerning>
 \# *Function:
 \#   Invokes .tkf (track kerning) for the current font with
 \#   1 as both the upper and lower point size limits, so that
@@ -903,49 +904,39 @@
 \# *Notes:
 \#   Decimal values are acceptable.
 \#
-\# The groff documentation is a tad confusing about what unit of
-\# measure is used in track kerning, only that the width of each
-\# character is increased or decreased by the amount(s) passed as
-\# arguments to .tkf, and something about linear function of point
-\# size.  In fact, with the way I've put this macro together, it
-\# doesn't matter.  All the user needs to know is that a value of
-\# one will produce an unacceptably tight or loose line at most text
-\# point sizes; therefore, effective use of RW and EW is in the
-\# fractional range below 1 (e.g. .25, .5).  Given that RW and EW
-\# are for massaging type, a certain amount of experimentation and
-\# previewing is expected and necessary.
+\# A value of 1 will produce an unacceptably tight or loose line
+\# at most text point sizes; therefore, effective use of RW and
+\# EW is in the fractional range below 1.
 \# 
-\# \n(.f holds the current font number, which is acceptable to .tkf.
+\# \n[.f] holds the current font number, which is acceptable to .tkf.
 \# 
 \# RW and EW must be reset to 0 to cancel their effect on subsequent
 \# output lines.
 \#
 .MAC RW END
 .    if \\n[#BR_AT_LINE_KERN] \{\
-.       ie \\n[#JUSTIFY]=1 \{ .brp \}
-.       el \{ .br \}
+.       ie \\n[#JUSTIFY]=1 .brp
+.       el .br
 .    \}
 .    rr #EW
 .    rm $EW
 .    nr #RW 1
 .    ds $RW \\$1
-.    tkf \\n(.f 1 -\\$1 1 -\\$1
+.    tkf \\n[.f] 1 -\\$1 1 -\\$1
 .END
 \#
-\#
 .MAC EW END
 .    if \\n[#BR_AT_LINE_KERN] \{\
-.       ie \\n[#JUSTIFY]=1 \{ .brp \}
-.       el \{ .br \}
+.       ie \\n[#JUSTIFY]=1 .brp
+.       el .br
 .    \}
 .    rr #RW
 .    rm $RW
 .    nr #EW 1
 .    ds $EW \\$1
-.    tkf \\n(.f 1 \\$1 1 \\$1
+.    tkf \\n[.f] 1 \\$1 1 \\$1
 .END
 \#
-\#
 \# BREAK AT LINE KERN
 \# ------------------
 \# *Arguments:
@@ -958,8 +949,8 @@
 \#   default and must be invoked explicitly.
 \#
 .MAC BR_AT_LINE_KERN END
-.    ie '\\$1'' \{ .nr #BR_AT_LINE_KERN  1 \}
-.    el         \{ .rr #BR_AT_LINE_KERN \}
+.    ie '\\$1'' .nr #BR_AT_LINE_KERN  1
+.    el .rr #BR_AT_LINE_KERN
 .END
 \#
 \# =====================================================================
@@ -1017,9 +1008,9 @@
 .          nh
 .          nr #HYPHENATE 0
 .       \}
-.       if '\\$1'LINES'   \{ .hlm \\$2 \}
-.       if '\\$1'MARGIN'  \{ .hym \\$2 \}
-.       if '\\$1'SPACE'   \{ .hys \\$2 \}
+.       if '\\$1'LINES'  .hlm \\$2
+.       if '\\$1'MARGIN' .hym \\$2
+.       if '\\$1'SPACE'  .hys \\$2
 .       if '\\$1'DEFAULT' \{\
 .          hlm -1
 .          hym 0
@@ -1028,7 +1019,6 @@
 .    \}
 .END
 \#
-\#
 \# HYPHENATION PARAMETERS
 \# ----------------------
 \# *Arguments:
@@ -1058,25 +1048,26 @@
 \#   Requires a unit of measure.
 \#
 .MAC ALD END
-.    if \\n(nl=0 \{ .nr #TOP 1 \}
+.    br
+.    if \\n[nl]=0 .nr #TOP 1
 .    if '\\$0'ALD' \{\
 .       nr #ALD (\\$1)
 .       sp \\n[#ALD]u
 .    \}
 .    if '\\$0'ADD_SPACE' \{\
+.       vpt 0
 .       nr #ALD (\\$1)
 .       rs
-.       sp \\n[#ALD]u
-.    \}
-.    if '\\$0'SPACE' \{\
-.       sp \\$1
-.    \}
-.    if '\\$0'SP' \{\
-.       sp \\$1
+.       nop \&
+.       sp |\\n[#T_MARGIN]u-1v+\\n[#ALD]u
+.       rr @TOP
+.       nr #SPACE_ADDED 1
+.       vpt
 .    \}
+.    if '\\$0'SPACE' .sp \\$1
+.    if '\\$0'SP'    .sp \\$1
 .END
 \#
-\#
 \# REVERSE LEAD
 \# ------------
 \# *Argument:
@@ -1088,6 +1079,7 @@
 \#   Requires a unit of measure.
 \#
 .MAC RLD END
+.    br
 .    nr #RLD (\\$1)
 .    sp -\\n[#RLD]u
 .END
@@ -1218,7 +1210,7 @@
 \# *Function:
 \#   Turns automatic ligature generation on or off.
 \# *Notes:
-\#   Ligatures may be supplied manually with \(fi, \(fl, etc.
+\#   Ligatures may be supplied manually with \[fi], \[fl], etc.
 \#
 .MAC LIGATURES END
 .    ie '\\$1'' \{\
@@ -1231,7 +1223,6 @@
 .    \}
 .END
 \#
-\#
 \# SMARTQUOTES
 \# -----------
 \# *Arguments:
@@ -1246,8 +1237,6 @@
 \#   processed.  The strings for open/close ($QUOTE<n>) are then
 \#   defined in the macro.
 \#
-\#   (Note to myself: code for " is \N'34'.)
-\#
 .char " \\*[$QUOTE\\n[#OPEN_CLOSE]]\R'#OPEN_CLOSE (1-\\n[#OPEN_CLOSE])'
 \#
 .MAC SMARTQUOTES END
@@ -1355,8 +1344,8 @@
 \#
 \# Strings for foot and inch marks
 \#
-.ds FOOT \(fm
-.ds INCH \(fm\(fm
+.ds FOOT \[fm]
+.ds INCH \[fm]\[fm]
 \#
 \# =====================================================================
 \#
@@ -1384,9 +1373,10 @@
 .    TRAP
 .END
 \#
-\# An inline escape to accomplish the same thing.  Actually
-\# preferable, since it works with filled and non-filled copy and
-\# doesn't require the user to remember to use (or not use) the \c.
+\# An inline escape to accomplish the same thing.
+\# Preferable, since it works with filled and non-filled copy and
+\# doesn't require the user to remember whether to use (or not use)
+\# \c.
 \#
 .ds B \h'|0'\R'#NO_ADVANCE 1'\c
 \#
@@ -1410,11 +1400,10 @@
 .    \}
 '    ce 0
 .    QUAD J
-.    if \\n[#PRINT_STYLE]=1 \{ .QUAD L \}
+.    if \\n[#PRINT_STYLE]=1 .QUAD L
 .    nr #PSEUDO_FILL 0
 .END
 \#
-\#
 \# QUAD
 \# ----
 \# *Arguments:
@@ -1475,16 +1464,15 @@
 .    nr #PSEUDO_FILL 0
 .END
 \#
-\#
 \# LEFT, RIGHT, AND CENTER
 \# -----------------------
-\# The purpose of these macros is to allow the user to enter lines of
-\# text that will be quadded LRC *without* the user having to enter .BR
-\# or .br between lines.  For the sake of consistency, all three appear
-\# to behave similarly (from the point of view of the user), although
-\# the underlying primitives don't.  For this reason, LEFT, RIGHT, and
-\# CENTER must be followed by .QUAD [L R C J] or .JUSTIFY to restore
-\# text to groff fill mode.
+\# The purpose of these macros is to allow the user to enter lines
+\# of text that will be quadded LRC having to stick .BR or .br
+\# between lines.  For the sake of consistency, all three appear to
+\# behave similarly (from the point of view of the user), although
+\# the underlying primitives don't.  For this reason, LEFT, RIGHT,
+\# and CENTER must be followed by .QUAD [L R C J] or .JUSTIFY to
+\# restore text to fill mode.
 \#
 \# LEFT
 \# ----
@@ -1494,10 +1482,9 @@
 \#   Turns fill mode off.  Allows user to quad lines left without
 \#   requiring the .BR or .br macro.
 \# *Notes:
-\#   LEFT simply turns fill off.  Lines that exceed the current LL will
-\#   not be broken, just continued (indefinitely) until a return is
-\#   encountered.  Note that this behaviour differs from the RIGHT and
-\#   CENTER macros.
+\#   LEFT simply turns fill off.  Lines that exceed the current LL
+\#   will not be broken.  Note that this behaviour differs from the
+\#   RIGHT and CENTER macros.
 \#
 .MAC LEFT END
 .    if \\n[#TAB_ACTIVE]=0 \{\
@@ -1508,10 +1495,9 @@
 .    nf
 .    nr #PSEUDO_FILL 1
 .\" Fix for a little conflict with DOCTYPE LETTER
-.    if '\\n(.z'LETTERHEAD1' \{ .rr #DATE_FIRST \}
+.    if '\\n[.z]'LETTERHEAD1' .rr #DATE_FIRST
 .END
 \#
-\#
 \# RIGHT
 \# -----
 \# *Argument:
@@ -1533,7 +1519,6 @@
 .    nr #PSEUDO_FILL 1
 .END
 \#
-\#
 \# CENTER
 \# ------
 \# *Argument:
@@ -1559,8 +1544,8 @@
 \#
 \# +++TABS+++
 \#
-\# There are two different kinds of tabs available: typesetting tabs
-\# and string tabs.
+\# There are two different kinds of tabs: typesetting tabs and
+\# string tabs.
 \# 
 \# Typesetting tabs are set with TAB_SET, which requires a tab number,
 \# an indent (offset) from the left margin and a length (optionally
@@ -1585,8 +1570,6 @@
 \# optionally passes quad information to it.  That done, string tabs
 \# can be called just like typesetting tabs.
 \# 
-\# String tabs don't preview properly with gxditview.  Use gv instead.
-\#
 \# Strings for string tab inlines
 \# ------------------------------
 \# Initialize string tab markers numbered 1 to 19.
@@ -1602,14 +1585,12 @@
 .\}
 .rr #LOOP
 \#
-\#
 \# These are reserved ST numbers for internal use
 .ds ST100  \Ek[#ST100_OFFSET]
 .ds ST100X \Ek[#ST100_MARK]
 .ds ST101  \Ek[#ST101_OFFSET]
 .ds ST101X \Ek[#ST101_MARK]
 \#
-\#
 \# QUAD AND SET STRING TABS
 \# ------------------------
 \# *Arguments:
@@ -1625,19 +1606,16 @@
 \#
 .MAC ST END
 .    ds $ST\\$1_QUAD_DIR \\$2
-.    if \\n[#NUM_ARGS]=3 \{\
-.       ds $ST\\$1_FILL QUAD
-.    \}
+.    if \\n[#NUM_ARGS]=3 .ds $ST\\$1_FILL QUAD
 .    nr #ST\\$1_LENGTH \\n[#ST\\$1_MARK]-\\n[#ST\\$1_OFFSET]
-.    ie \\n[#IN_TAB] \{\
-.       TAB_SET \\$1 \\n[#ST\\$1_OFFSET]u+\\n[#ST_OFFSET]u 
\\n[#ST\\$1_LENGTH]u \\*[$ST\\$1_QUAD_DIR] \\*[$ST\\$1_FILL]
-.    \}
-.    el \{\
-.       TAB_SET \\$1 \\n[#ST\\$1_OFFSET]u \\n[#ST\\$1_LENGTH]u 
\\*[$ST\\$1_QUAD_DIR] \\*[$ST\\$1_FILL]
-.    \}
+.    ie \\n[#IN_TAB] \
+.       TAB_SET \\$1 \\n[#ST\\$1_OFFSET]u+\\n[#ST_OFFSET]u \
+          \\n[#ST\\$1_LENGTH]u \\*[$ST\\$1_QUAD_DIR] \\*[$ST\\$1_FILL]
+.    el \
+.       TAB_SET \\$1 \\n[#ST\\$1_OFFSET]u \\n[#ST\\$1_LENGTH]u \
+          \\*[$ST\\$1_QUAD_DIR] \\*[$ST\\$1_FILL]
 .END
 \#
-\#
 \# TAB SET
 \# -------
 \# *Arguments:
@@ -1661,41 +1639,16 @@
 \#
 \#   N.B. -- indents *must* be turned off before setting tabs
 \#
-\# Examples:
-\# --------
-\# 
-\# .TAB_SET 1 2P+6p 12P C
-\# 
-\# means "create a tab numbered 1 that starts 2 picas and 6 points from
-\# the left margin, is 12 picas long, and centre each input line."
-\# 
-\# .TAB_SET 1 2P+6P 12P C QUAD
-\# 
-\# means exactly the same thing, except that input lines are joined and
-\# the area delimted by the tab filled with centered text.
-\# 
-\# TAB n can be called at any time after being set.
-\# 
-\# Tabs are NOT columnar in behaviour.  If the text inside a
-\# tab runs to several lines, when you call the next tab a break
-\# occurs, meaning that the new tab starts one line below the last
-\# line in the previous tab.  For columnar behaviour, you must
-\# use the multi-column macros in addition to tabs.
-\# 
-\# If you want tabs to line up bottom-line to bottom-line (most likely
-\# single line tabs), use .TN (provided the tabs are numbered sequentially).
-\# Otherwise, you must use .EL then .TAB <n> if you want them to align.
-\# 
-\# If you want to reset tabs, you must use .TQ before .TAB_SET.
+\# Tabs are not columnar in behaviour.  .TN and \*[TB+] permit
+\# bottom-line to bottom-line tab movement.
 \# 
-\# Note that indents are turned off automatically whenever a new
-\# tab is called with TAB <n>.
+\# When resetting tabs, .TQ must be invoked before .TAB_SET.
 \# 
-\# Tabs themselves are user-invoked using the TAB macro with a numeric
-\# argument, e.g. TAB 1.
+\# Indents are turned off automatically whenever a new tab is called
+\# with TAB <n>.
 \# 
-\# Generally, in order not to get confused, it's a good idea
-\# to make sure all indents are off before setting tabs.
+\# Generally, it's a good idea to make sure all indents are off
+\# before setting tabs.
 \#
 .MAC TAB_SET END
 .    br
@@ -1703,8 +1656,8 @@
 .    ds $CURRENT_TAB \\n[#TAB_NUMBER]
 .    nr #TAB_OFFSET (\\$2)
 .    nr #TAB_LENGTH (\\$3)
-.    MAC TAB\\n[#TAB_NUMBER] DONE \"Define TAB macro
-.        if !\\\\n[#TB+]=1 \{ .br \}
+.    MAC TAB\\n[#TAB_NUMBER]
+.        if !\\\\n[#TB+]=1 .br
 .        if \\\\n[#TB+]=1 \{\
 .           EL
 .           vpt 0
@@ -1718,29 +1671,28 @@
 .        nr #ST_OFFSET \\n[#TAB_OFFSET]
 .        po \\\\n[#L_MARGIN]u+\\\\n[#TAB_OFFSET\\\\*[$CURRENT_TAB]]u
 .        ll \\n[#TAB_LENGTH]u
-.        ta \En(.lu
+.        ta \En[.l]u
 .        ie '\\$5'QUAD' \{\
-.           if '\\$4'L' \{ .QUAD L  \}
-.           if '\\$4'R' \{ .QUAD R  \}
-.           if '\\$4'C' \{ .QUAD C  \}
-.           if '\\$4'J' \{ .JUSTIFY \}
+.           if '\\$4'L' .QUAD L
+.           if '\\$4'R' .QUAD R
+.           if '\\$4'C' .QUAD C
+.           if '\\$4'J' .JUSTIFY
 .        \}
 .        el \{\
-.           if '\\$4''  \{ .LEFT    \}
-.           if '\\$4'L' \{ .LEFT    \}
-.           if '\\$4'R' \{ .RIGHT   \}
-.           if '\\$4'C' \{ .CENTER  \}
-.           if '\\$4'J' \{ .JUSTIFY \}
+.           if '\\$4''  .LEFT
+.           if '\\$4'L' .LEFT
+.           if '\\$4'R' .RIGHT
+.           if '\\$4'C' .CENTER
+.           if '\\$4'J' .JUSTIFY
 .        \}
 .        if \\\\n[#TN]=1 \{\
 .           TRAP
 .           rr #TN
 .        \}
-.DONE
+..
 .    rr #TAB_ACTIVE
 .END
 \#
-\#
 \# TAB
 \# ---
 \# *Arguments:
@@ -1754,7 +1706,6 @@
 .    nr #IN_TAB 1
 .END
 \#
-\#
 \# TAB NEXT
 \# --------
 \# *Argument:
@@ -1775,11 +1726,12 @@
 .    TRAP
 .END
 \#
-\# An inline escape to accomplish the same thing.  Actually
-\# preferable, since it works with filled and non-filled copy and
-\# doesn't require the user to remember to use (or not use) the \c.
+\# An inline escape to accomplish the same thing.  Preferable, since
+\# it works with filled and non-filled copy and doesn't require the
+\# user to remember to use (or not use) the \c.
 \#
-.ds TB+ "\c\\R'#TB+ 1'\\R'#TN 1'\\R'#NEXT_TAB 
\\n[#CURRENT_TAB]+1'\\*[TAB\\n[#NEXT_TAB]]\c
+.ds TB+ \
+"\c\R'#TB+ 1'\R'#TN 1'\R'#NEXT_TAB \\n[#CURRENT_TAB]+1'\\*[TAB\\n[#NEXT_TAB]]\c
 \#
 \# TAB QUIT
 \# --------
@@ -1794,10 +1746,9 @@
 \#   Resets QUAD [ L|R|C ], LEFT, RIGHT, CENTER, or JUSTIFY
 \#   in effect prior to tabs.
 \# *Notes:
-\#   TQ *must* come before setting any new tabs if you want the
-\#   tabs' indents measured from page left.  Otherwise, the tabs'
-\#   indents are measured from the left margin of the tab you're
-\#   currently in.
+\#   TQ must precede setting new tabs to get the tabs' indents
+\#   measured from page left.  Otherwise, the tabs' indents are
+\#   measured from the left margin of the currently active tab.
 \#
 .MAC TQ END
 .    br
@@ -1806,19 +1757,19 @@
 .    nr #LOOP 0 1
 .    while \\n+[#LOOP]<20 \{\
 .       rm $ST\\n[#LOOP]_FILL
-.\}
+.    \}
 .    rr #LOOP
 .    po \\n[#L_MARGIN]u
 .    ll \\n[#L_LENGTH]u
-.    ta \\n(.lu
+.    ta \\n[.l]u
 .    ie \\n[#QUAD] \{\
-.       ie '\\*[$RESTORE_QUAD_VALUE]'J' \{ .JUSTIFY \}
-.       el                              \{ .QUAD \\*[$RESTORE_QUAD_VALUE] \}
+.       ie '\\*[$RESTORE_QUAD_VALUE]'J' .JUSTIFY
+.       el .QUAD \\*[$RESTORE_QUAD_VALUE]
 .    \}
 .    el \{\
-.       if '\\*[$RESTORE_QUAD_VALUE]'LEFT'   \{ .LEFT \}
-.       if '\\*[$RESTORE_QUAD_VALUE]'RIGHT'  \{ .RIGHT \}
-.       if '\\*[$RESTORE_QUAD_VALUE]'CENTER' \{ .CENTER \}
+.       if '\\*[$RESTORE_QUAD_VALUE]'LEFT' .LEFT
+.       if '\\*[$RESTORE_QUAD_VALUE]'RIGHT' .RIGHT
+.       if '\\*[$RESTORE_QUAD_VALUE]'CENTER' .CENTER
 .    \}
 .END
 \#
@@ -1836,14 +1787,13 @@
 \#   as a macro.
 \#
 .MAC COLOR END
-.ie \\n(.u=1 \{\
+.    ie \\n[.u]=1 \{\
 \c
 \\*[\\$1]\c
-.\}
-.el \{ \\*[\\$1] \}
+.    \}
+.    el \\*[\\$1]
 .END
 \#
-\#
 \# NEWCOLOR
 \# --------
 \# *Arguments:
@@ -1875,7 +1825,6 @@
 .    ds \\$1 \\m[\\$1]
 .END
 \#
-\#
 \# XCOLOR
 \# ------
 \# *Arguments:
@@ -1893,6 +1842,7 @@
 .    if \\n[#NUM_ARGS]=2 \{\
 .       ds \\$2 \m[\\$1]
 .       ds $\\$2_FILL \\$1
+.       ds COLAL_\\$2 \\$1
 .    \}
 .END
 \#
@@ -1921,9 +1871,9 @@
 .nr _d 1250
 \#
 .MAC UNDERLINE_SPECS END
-.    ie \B'\\$1' \{ .nr _w (u;\\$1) \}
+.    ie \B'\\$1' .nr _w (u;\\$1)
 .    el \{\
-.       ie '\\$1'DEFAULT' \{ .nr _w 500 \}
+.       ie '\\$1'DEFAULT' .nr _w 500
 .       el \{\
 .          nr _w 500
 .          tm1 "[mom]: The first argument to \\$0 must be a numeric
@@ -1932,9 +1882,9 @@
 .       \}
 .    \}
 .    shift
-.    ie \B'\\$1' \{ .nr _d (u;\\$1) \}
+.    ie \B'\\$1' .nr _d (u;\\$1)
 .    el \{\
-.       ie '\\$1'DEFAULT' \{ .nr _d 1250 \}
+.       ie '\\$1'DEFAULT' .nr _d 1250
 .       el \{\
 .          nr _d 1250
 .          tm1 "[mom]: The second argument to \\$0 must be a numeric
@@ -1950,22 +1900,17 @@
 .    ie '\\$1'' \{\
 .       nr #UNDERLINE_ON 1
 .       ss \\n[.ss] (\\n[.ss]-\\n[.ss])
-.       ie !n \{\
-.          nop \X'ps: exec \\n[_w] \\n[_d] decorline'\c
-.       \}
-.       el \{ .ul 1000 \}
+.       ie !n .nop \X'ps: exec \\n[_w] \\n[_d] decorline'\c
+.       el .ul 1000
 .    \}
 .    el \{\
 .       nr #UNDERLINE_ON 0
 .       SS \\*[$SAVED_SS_VAR]
-.       ie !n \{\
-.          nop \X'ps: exec decornone'\c
-.       \}
-.       el \{ .ul 0 \}
+.       ie !n .nop \X'ps: exec decornone'\c
+.       el .ul 0
 .    \}
 .END
 \#
-\#
 \# UL/ULX
 \# ------
 \# *Arguments:
@@ -1980,31 +1925,29 @@
 \c
 .    ds $SAVED_SS_VAR \\*[$SS_VAR]
 .    ss \\n[.ss] (\\n[.ss]-\\n[.ss])
-.    ie !'\\n[.z]'' 
+.    ie !'\\n[.z]'' \{\
 \c
 .       ie !n \{\
-\?\h'-\w'\\n[.ss]'u'\?
+.if !\\n[.k]=0 \?\h'-\w'\\n[.ss]'u'\?
 \?\R'#UNDERLINE_ON 1'\X'ps: exec \\n[_w] \\n[_d] decorline'\?\c
 .       \}
 .       el \{\
 \?\R'#UNDERLINE_ON 1'\?\c
 .          ul 1000
 .       \}
+.    \}
 .    el \{\
 .       ie !n \{\
-\h'-\w'\\n[.ss]'u'
 .          nr #UNDERLINE_ON 1
 .          nop \X'ps: exec \\n[_w] \\n[_d] decorline'\c
 .       \}
 .       el \{\
-\h'-\w'\\n[.ss]'u'
-.          nr #UNDERLINE_ON 1
+\R'#UNDERLINE_ON 1'\c
 .          ul 1000
 .       \}
 .    \}
 .END
 \#
-\#
 .MAC ULX END
 \c
 .    SS \\*[$SAVED_SS_VAR]
@@ -2031,7 +1974,6 @@
 .    \}
 .END
 \#
-\#
 \# UNDERSCORE
 \# ----------
 \# *Arguments:
@@ -2048,16 +1990,11 @@
 \#         or
 \#      .UNDERSCORE 2p "Text to be underscored
 \#
-\#   All text is underscored (including punctuation and spaces).
-\#   This is the primary difference between UNDERLINE and
-\#   UNDERSCORE, aside from the fact the UNDERLINE only works with
-\#   fixed width fonts.
-\#
-\#   UNDERSCORE does not work across line breaks.  Each line of
-\#   text must be entered separately with UNDERSCORE.  If the
-\#   UNDERSCORE begins in the middle of a line and crosses over a
-\#   break, the portion before the break must be entered in its own
-\#   UNDERSCORE, as must the portion that comes after the break.
+\#   UNDERSCORE does not work across line breaks.  Each line of text
+\#   must be entered separately.  If the UNDERSCORE begins in the
+\#   middle of a line and crosses over a break, the portion before
+\#   the break and the portion afterwards must be entered
+\#   separately.
 \#
 .MAC UNDERSCORE END
 .    nr #SAVED_UNDERSCORE_WEIGHT     \\n[#UNDERSCORE_WEIGHT]
@@ -2074,20 +2011,15 @@
 .       ds $UNDERSCORE_GAP        \\*[$COVER_UNDERLINE_GAP]
 .    \}
 .    if \\n[#FROM_DOC_COVER]=1 \{\
-.       nr #UNDERSCORE_WEIGHT     \\n[#DOCCOVER_UNDERLINE_WEIGHT]
-.       nr #UNDERSCORE_WEIGHT_ADJ \\n[#DOCCOVER_UNDERLINE_WEIGHT_ADJ]
-.       ds $UNDERSCORE_GAP        \\*[$DOCCOVER_UNDERLINE_GAP]
+.       nr #UNDERSCORE_WEIGHT        \\n[#DOC_COVER_UNDERLINE_WEIGHT]
+.       nr #UNDERSCORE_WEIGHT_ADJ    \\n[#DOC_COVER_UNDERLINE_WEIGHT_ADJ]
+.       ds $UNDERSCORE_GAP           \\*[$DOC_COVER_UNDERLINE_GAP]
 .    \}
 .    if \\n[#FROM_DOCTYPE]=1 \{\
 .       nr #UNDERSCORE_WEIGHT     \\n[#DOCTYPE_UNDERLINE_WEIGHT]
 .       nr #UNDERSCORE_WEIGHT_ADJ \\n[#DOCTYPE_UNDERLINE_WEIGHT_ADJ]
 .       ds $UNDERSCORE_GAP        \\*[$DOCTYPE_UNDERLINE_GAP]
 .    \}
-.    if \\n[#FROM_HEAD]=1 \{\
-.       nr #UNDERSCORE_WEIGHT     \\n[#HEAD_UNDERLINE_WEIGHT]
-.       nr #UNDERSCORE_WEIGHT_ADJ \\n[#HEAD_UNDERLINE_WEIGHT_ADJ]
-.       ds $UNDERSCORE_GAP        \\*[$HEAD_UNDERLINE_GAP]
-.    \}
 .    if \\n[#FROM_EN_STRING]=1 \{\
 .       nr #UNDERSCORE_WEIGHT     \\n[#EN_STRING_UNDERLINE_WEIGHT]
 .       nr #UNDERSCORE_WEIGHT_ADJ \\n[#EN_STRING_UNDERLINE_WEIGHT_ADJ]
@@ -2128,7 +2060,6 @@
 .    rm $SAVED_UNDERSCORE_GAP
 .END
 \#
-\#
 \# DOUBLE UNDERSCORE
 \# -----------------
 \# *Arguments:
@@ -2139,7 +2070,6 @@
 \# *Notes:
 \#   The same double-quote requirement as UNDERSCORE.
 \#
-\#
 .MAC UNDERSCORE2 END
 .    nr #SAVED_UNDERSCORE_WEIGHT     \\n[#UNDERSCORE_WEIGHT]
 .    nr #SAVED_UNDERSCORE_WEIGHT_ADJ \\n[#UNDERSCORE_WEIGHT_ADJ]
@@ -2220,16 +2150,14 @@
 .ds $BIB_STRING_UNDERLINE_GAP 2p
 .ds $BIB_STRING_RULE_GAP      2p
 .ds $COVER_UNDERLINE_GAP      2p
-.ds $DOCCOVER_UNDERLINE_GAP   2p
+.ds $DOC_COVER_UNDERLINE_GAP  2p
 .ds $DOCTYPE_UNDERLINE_GAP    2p
 .ds $EN_STRING_UNDERLINE_GAP  2p
 .ds $EN_STRING_RULE_GAP       2p
 .ds $EN_TITLE_UNDERLINE_GAP   2p
-.ds $HEAD_UNDERLINE_GAP       2p
 .ds $RULE_GAP                 2p
 .ds $UNDERSCORE_GAP           2p
 \#
-\#
 \# SUPERSCRIPT
 \# -----------
 \# *Function:
@@ -2279,7 +2207,6 @@
 \#
 .ds EXTSUPX \s[\En[#PT_SIZE_IN_UNITS]u]\E*[$SUP_LOWER]\E*[EXT]
 \#
-\#
 \# SLANT
 \# -----
 \#
@@ -2311,21 +2238,20 @@
 .    ie '\\$1'RESET' \{\
 .       nr #DEGREES 15
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          if \\n[#UNDERLINE_SLANT] \{ .return \}
+.          if \\n[#UNDERLINE_SLANT] .return
 .       \}
 .       ds SLANT \ER'#SLANT_ON 1'\ES'\En[#DEGREES]'
 .    \}
 .    el \{\
 .       nr #DEGREES \\$1
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          if \\n[#UNDERLINE_SLANT] \{ .return \}
+.          if \\n[#UNDERLINE_SLANT] .return
 .       \}
 .       ds SLANT \ER'#SLANT_ON 1'\ES'\En[#DEGREES]'
 .    \}
 .    ds SLANTX \ER'#SLANT_ON 0'\ES'0'
 .END
 \#
-\#
 \# BOLDER
 \# ------
 \#
@@ -2346,21 +2272,19 @@
 .nr #BOLDER_UNITS 700
 \#
 .MAC SETBOLDER END
-.    if \\n[#IGNORE]=1 \{ .return \}
-.    ie '\\$1'RESET' \{ .nr #BOLDER_UNITS 700 \}
-.    el \{ .nr #BOLDER_UNITS \\$1 \}
+.    if \\n[#IGNORE]=1 .return
+.    ie '\\$1'RESET' .nr #BOLDER_UNITS 700
+.    el              .nr #BOLDER_UNITS \\$1
 .END
 \#
-\#
 .MAC BOLDER END
 \c
-.bd \\n(.f \\n[#BOLDER_UNITS]
+.bd \\n[.f] \\n[#BOLDER_UNITS]
 .END
 \#
-\#
 .MAC BOLDERX END
 \c
-.bd \\n(.f
+.bd \\n[.f]
 .END
 \#
 \# +++CONDENSE/EXTEND+++
@@ -2423,9 +2347,10 @@
 .    \}
 .END
 \#
-.ds CONDX \ER'#CONDENSE 0'\Es0\R'#PT_SIZE_IN_UNITS 
\En[.ps]'\H'\En[#PT_SIZE_IN_UNITS]u'
-.ds EXTX  \ER'#EXTEND   0'\Es0\R'#PT_SIZE_IN_UNITS 
\En[.ps]'\H'\En[#PT_SIZE_IN_UNITS]u'
-\#
+.ds CONDX \
+\ER'#CONDENSE 0'\Es[0]\R'#PT_SIZE_IN_UNITS \En[.ps]'\H'\En[#PT_SIZE_IN_UNITS]u'
+.ds EXTX  \
+\ER'#EXTEND   0'\Es[0]\R'#PT_SIZE_IN_UNITS \En[.ps]'\H'\En[#PT_SIZE_IN_UNITS]u'
 \#
 \# +++PAD LINES+++ (insert space)
 \#
@@ -2442,29 +2367,28 @@
 .    ds $PAD_MARKER \\$1
 .END
 \#
-\#
 \# PAD
 \# ---
 \# *Argments:
 \#   "<string of text with padding markers inserted>"
+\#   "<id of bookmark created by .PDF_BOOKMARK>"
 \# *Function:
 \#   Defines and redefines padding character (default=pound sign
 \#   unless padding character has been set with PAD_MARKER)
 \#   several times so that when the string is output at the end
 \#   of the macro, every # has been converted to an equal-sized
-\#   amount of padding (blank space) on a line. # is equivalent to
-\#   CompuGraphic's old <IS>.
+\#   amount of padding (blank space) on a line.
 \# *Notes:
 \#   String tabs may be marked off during PAD.
 \#
 .MAC PAD END
-.    if \\n(.u=1 \{ .nr #FILL_MODE 1 \}
+.    if \\n[.u]=1 .nr #FILL_MODE 1
 .    nf
 .    if !d$PAD_MARKER .ds $PAD_MARKER #
 .    char \\*[$PAD_MARKER] \R'#PAD_COUNT \En[#PAD_COUNT]+1'
 .    ds $FAMILY_FOR_PAD \\n[.fam]
-.    if !n \{ .fp \\n[.fp] \\n[.sty] \}
-.    ds $FONT_FOR_PAD   \\*[$FONT]
+.\" .if !n .fp \\n[.fp] \\n[.sty]
+.    ds $FONT_FOR_PAD   \\n[.sty]
 .    nr #SIZE_FOR_PAD   \\n[.ps]
 .    ds $PAD_STRING \\$1
 .    as $PAD_STRING \Ekp
@@ -2473,25 +2397,24 @@
 \\f[\\*[$FONT_FOR_PAD]]\\s[\\n[#SIZE_FOR_PAD]u]\\*[$PAD_STRING]
 .    br
 .    di
-.    char \\*[$PAD_MARKER] \R'#SPACE_TO_END \En(.l-\Enp'\R'#PAD_SPACE 
\En[#SPACE_TO_END]/\En[#PAD_COUNT]'
+.    char \\*[$PAD_MARKER] \
+\R'#SPACE_TO_END \En[.l]-\En[p]'\R'#PAD_SPACE 
\En[#SPACE_TO_END]/\En[#PAD_COUNT]'
 .    di PAD_STRING
 .    fam \\*[$FAMILY_FOR_PAD]
 \\f[\\*[$FONT_FOR_PAD]]\\s[\\n[#SIZE_FOR_PAD]u]\\*[$PAD_STRING]
 .    br
 .    di
 .    char \\*[$PAD_MARKER] \h'\En[#PAD_SPACE]u'
-.    ie \\n[#SILENT] \{\
-.       SILENT
+.    if \\n[#SILENT] .SILENT
 .       fam \\*[$FAMILY_FOR_PAD]
-\\f[\\*[$FONT_FOR_PAD]]\\s[\\n[#SIZE_FOR_PAD]u]\\*[$PAD_STRING]
-.       br
-.       SILENT OFF
-.    \}
+\\f[\\*[$FONT_FOR_PAD]]\\s[\\n[#SIZE_FOR_PAD]u]
+.    ie '\\$2'' .nop \\*[$PAD_STRING]
 .    el \{\
-.       fam \\*[$FAMILY_FOR_PAD]
-\\f[\\*[$FONT_FOR_PAD]]\\s[\\n[#SIZE_FOR_PAD]u]\\*[$PAD_STRING]
-.       br
+.       ie !'\\$2'NOBREAK' .pdfhref L -D "\\$2" -E -- \&\\*[$PAD_STRING]
+.       el .nop \\*[$PAD_STRING]
 .    \}
+.    if \\n[#SILENT] .SILENT OFF
+.    br
 .    if \\n[#FILL_MODE]=1 \{\
 .       fi
 .       rr #FILL_MODE
@@ -2509,7 +2432,6 @@
 .    \}
 .END
 \#
-\#
 \# +++LEADERS+++
 \#
 \# The leader mechanism is primitive, but it works.  Basically, every
@@ -2546,7 +2468,6 @@
 .    ds $DC_FAM \\$1
 .END
 \#
-\#
 \# DROP CAP FONT
 \# -------------
 \# *Argument:
@@ -2558,7 +2479,6 @@
 .    ds $DC_FT \\$1
 .END
 \#
-\#
 \# DROPCAP COLOR
 \# -------------
 \# *Arguments:
@@ -2570,12 +2490,11 @@
 \#   DC_COLOR.
 \#
 .MAC DROPCAP_COLOR END
-.    if \\n[#PRINT_STYLE]=1 \{ .return \}
+.    if \\n[#PRINT_STYLE]=1 .return
 .    nr #DC_COLOR 1
 .    ds $DC_COLOR \\$1
 .END
 \#
-\#
 \# DROP CAP GUTTER
 \# ---------------
 \# *Argument:
@@ -2589,7 +2508,6 @@
 .    nr #DC_GUT (\\$1)
 .END
 \#
-\#
 \# DROP CAP ADJUST
 \# ---------------
 \# *Argument:
@@ -2608,7 +2526,6 @@
 .    ds $DC_ADJUST \\$1
 .END
 \#
-\#
 \# DROP CAP
 \# --------
 \# *Arguments:
@@ -2620,8 +2537,6 @@
 \#   to bottom of dropcap, then resets indent to left margin (plus
 \#   any indent that was in effect prior to invoking DROPCAP).
 \# *Notes:
-\#   Drop caps put a strain on on resource-challenged systems.
-\#
 \#   Drop caps when using the doc processing macro PP only work with
 \#   initial paragraphs (i.e. at doc start, or after heads), only when
 \#   DROPCAPS comes immediately after PP, and only when the PRINTSTYLE
@@ -2671,43 +2586,67 @@
 \\*[EXTX]
 .       nr #EXTEND_WAS_ON 1
 .    \}
-.    if '\\$3'COND'      \{ .CONDENSE \\$4 \}
-.    if '\\$3'EXT'       \{ .EXTEND \\$4 \}
-.    if !r#DC_GUT        \{ .nr #DC_GUT (3p) \}
-.    ds $RESTORE_FAM     \\n[.fam]
-.    ds $RESTORE_FT      \\*[$FONT]
+.    if '\\$3'COND' .CONDENSE \\$4
+.    if '\\$3'EXT' .EXTEND \\$4
+.    if !r#DC_GUT .nr #DC_GUT (3p)
+.    ie \\n[#DOCS] .ds $RESTORE_FAM \\*[$DOC_FAM]
+.    el .ds $RESTORE_FAM \\n[.fam]
+.    ie \\n[#DOCS] .ds $RESTORE_FT  \\*[$PP_FT]
+.    el .ds $RESTORE_FT  \\*[$FONT]
 .    nr #RESTORE_PT_SIZE \\n[#PT_SIZE]
-.    nr #RESTORE_INDENT  \\n(.i
+.    nr #RESTORE_INDENT  \\n[.i]
 .    SIZESPECS
 .    nr #DC_HEIGHT \\n[#DC_LINES]*\\n[#LEAD]+\\n[#CAP_HEIGHT]
-.    ie !d$DC_FAM \{ .FAM \\n[.fam] \}
-.    el \{ .FAM \\*[$DC_FAM] \}
-.    ie !d$DC_FT \{ .FT \\*[$FONT] \}
-.    el \{ .FT \\*[$DC_FT] \}
+.    ie !d$DC_FAM .FAM \\n[.fam]
+.    el .FAM \\*[$DC_FAM]
+.    ie !d$DC_FT .FT \\*[$FONT]
+.    el .FT \\*[$DC_FT]
 .    while \\n[#GET_DC_HEIGHT]<\\n[#DC_HEIGHT] \{\
 .       ps \\n[#PT_SIZE]u+100u
 .       SIZESPECS
 .       nr #GET_DC_HEIGHT \\n[#CAP_HEIGHT]
-.\}
-.    if d$DC_ADJUST \{ .ps \\*[$DC_ADJUST]p \}
+.    \}
+.    if d$DC_ADJUST .ps \\*[$DC_ADJUST]p
 .    nr #DC_LINES +1
+.    if \\n[#DC_LINES]v>\\n[.t] \{\
+.       nr pgnum \\n%+\\n[#PAGE_NUM_ADJ] 1
+.       tm1 "[mom]: Dropcap at line \\n[.c] does not fit on page 
\\n[#PAGENUMBER].
+.       tm1 "       Shifting paragraph to top of page \\n+[pgnum].
+.       bp
+.    \}
 .    ie \\n[#DC_COLOR]=1 \{\
 .       ie !'\\$3'' \{\
-.          ie '\\$3'COND' \{ .PRINT \\*[DOWN 
\\n[#DC_LINES]v]\m[\\*[$DC_COLOR]]\\*[COND]\\*[$DROPCAP]\\*[CONDX]\m[]\\*[UP 
\\n[#DC_LINES]v] \}
-.          el \{ .PRINT \\*[DOWN 
\\n[#DC_LINES]v]\m[\\*[$DC_COLOR]]\\*[EXT]\\*[$DROPCAP]\\*[EXTX]\m[]\\*[UP 
\\n[#DC_LINES]v] \}
-.       \}
-.       el \{ .PRINT \\*[DOWN 
\\n[#DC_LINES]v]\m[\\*[$DC_COLOR]]\\*[$DROPCAP]\m[]\\*[UP \\n[#DC_LINES]v] \}
+.          ie '\\$3'COND' \
+.             PRINT \
+\\*[DOWN \\n[#DC_LINES]v]\
+\m[\\*[$DC_COLOR]]\\*[COND]\\*[$DROPCAP]\\*[CONDX]\m[]\\*[UP \\n[#DC_LINES]v]
+.          el \
+.             PRINT \
+\\*[DOWN \\n[#DC_LINES]v]\
+\m[\\*[$DC_COLOR]]\\*[EXT]\\*[$DROPCAP]\\*[EXTX]\m[]\\*[UP \\n[#DC_LINES]v]
+.       \}
+.       el .PRINT \
+\\*[DOWN \\n[#DC_LINES]v]\
+\m[\\*[$DC_COLOR]]\\*[$DROPCAP]\m[]\\*[UP \\n[#DC_LINES]v]
 .    \}
 .    el \{\
 .       ie !'\\$3'' \{\
-.          ie '\\$3'COND' \{ .PRINT \\*[DOWN 
\\n[#DC_LINES]v]\\*[COND]\\*[$DROPCAP]\\*[CONDX]\\*[UP \\n[#DC_LINES]v] \}
-.          el \{ .PRINT \\*[DOWN 
\\n[#DC_LINES]v]\\*[EXT]\\*[$DROPCAP]\\*[EXTX]\\*[UP \\n[#DC_LINES]v] \}
-.       \}
-.       el \{ .PRINT \\*[DOWN 
\\n[#DC_LINES]v]\m[\\*[$DC_COLOR]]\\*[$DROPCAP]\m[]\\*[UP \\n[#DC_LINES]v] \}
-.    \}
-.    if '\\$3'COND' \{ \E*[COND] \}
-.    if '\\$3'EXT'  \{ \E*[EXT]  \}
-.    ie \\n(.i \{\
+.          ie '\\$3'COND' \
+.             PRINT \
+\\*[DOWN \\n[#DC_LINES]v]\
+\\*[COND]\\*[$DROPCAP]\\*[CONDX]\\*[UP \\n[#DC_LINES]v]
+.          el \
+.             PRINT \
+\\*[DOWN \\n[#DC_LINES]v]\
+\\*[EXT]\\*[$DROPCAP]\\*[EXTX]\\*[UP \\n[#DC_LINES]v]
+.       \}
+.       el .PRINT \
+\\*[DOWN \\n[#DC_LINES]v]\
+\m[\\*[$DC_COLOR]]\\*[$DROPCAP]\m[]\\*[UP \\n[#DC_LINES]v]
+.    \}
+.    if '\\$3'COND' \E*[COND]
+.    if '\\$3'EXT' \E*[EXT]
+.    ie \\n[.i] \{\
 .       vs 0
 .       br
 .       in +\w'\\*[$DROPCAP]'u+\\n[#DC_GUT]u
@@ -2719,8 +2658,8 @@
 .       in \w'\\*[$DROPCAP]'u+\\n[#DC_GUT]u
 .       vs
 .    \}
-.    if '\\$3'COND' \{ \E*[CONDX]\c \}
-.    if '\\$3'EXT'  \{ \E*[EXTX]\c \}
+.    if '\\$3'COND' \E*[CONDX]\c
+.    if '\\$3'EXT' \E*[EXTX]\c
 .    FAM \\*[$RESTORE_FAM]
 .    FT  \\*[$RESTORE_FT]
 .    ps \\n[#RESTORE_PT_SIZE]u
@@ -2732,8 +2671,8 @@
 .       EXTEND \\*[$RESTORE_EXT]
 \\*[EXT]\c
 .    \}
-.    ie \\n(.u \{ .wh \\n(.du+\\n[#DC_HEIGHT]u-1v DROPCAP_OFF \}
-.    el \{ .wh \\n(.du+\\n[#DC_HEIGHT]u DROPCAP_OFF \}
+.    ie \\n[.u] .wh \\n[.d]u+\\n[#DC_HEIGHT]u-1v DROPCAP_OFF
+.    el .wh \\n[.d]u+\\n[#DC_HEIGHT]u DROPCAP_OFF
 .    rr #CONDENSE_WAS_ON
 .    rr #EXTEND_WAS_ON
 .    rm $DROPCAP
@@ -2777,19 +2716,19 @@
 .       vpt 0
 .       nr #RESTORE_TRAP 1
 .    \}
-.    ie !\\n[#NO_ADVANCE]=1 \{ .br \}
+.    ie !\\n[#NO_ADVANCE]=1 .br
 .    el \{\
 .       sp -1v
 .       rr #NO_ADVANCE
 .    \}
-.    ie \\n(.u=1 \{\
+.    ie \\n[.u]=1 \{\
 .       nr #FILLED 1
-.       nr #FILL_MODE \\n(.j
+.       nr #FILL_MODE \\n[.j]
 .    \}
 .    el \{\
 .       nr #NOFILL 1
-.       if \\n[.ce]>0 \{ .nr #NOFILL_MODE 3 \}
-.       if \\n[.rj]>0 \{ .nr #NOFILL_MODE 5 \}
+.       if \\n[.ce]>0 .nr #NOFILL_MODE 3
+.       if \\n[.rj]>0 .nr #NOFILL_MODE 5
 .       ce 0
 .       rj 0
 .    \}
@@ -2797,27 +2736,23 @@
 .    ds $RL_WEIGHT \\$1
 .    ds $RL_INDENT \\$2
 .    ds $RL_LENGTH \\$3
-.    ie !'\\$4'' \{\
-.       ds $RL_COLOR  \\$4
-.    \}
-.    el \{\
-.       ds $RL_COLOR default
-.    \}
+.    ie !'\\$4'' .ds $RL_COLOR  \\$4
+.    el          .ds $RL_COLOR default
 .    nr #SAVED_WEIGHT     \\n[#RULE_WEIGHT]
 .    nr #SAVED_WEIGHT_ADJ \\n[#RULE_WEIGHT_ADJ]
 .    di NULL
-.       if \\n[#NUM_ARGS]>=1 \{ .RULE_WEIGHT \\*[$RL_WEIGHT] \}
+.       if \\n[#NUM_ARGS]>=1 .RULE_WEIGHT \\*[$RL_WEIGHT]
 .    di
 .    gcolor \\*[$RL_COLOR]
 .    ie \\n[#NUM_ARGS]=0 \{\
 .       ie \\n[#INDENT_ACTIVE] \{\
-.          nr #RESTORE_L_LENGTH \\n(.l
-.          if \\n[#INDENT_BOTH_ACTIVE] \{ .ll \\n(.lu-\\n[#BL_INDENT]u \}
-.          if \\n[#INDENT_LEFT_ACTIVE] \{ .ll \\n(.lu-\\n[#L_INDENT]u \}
+.          nr #RESTORE_L_LENGTH \\n[.l]
+.          if \\n[#INDENT_BOTH_ACTIVE] .ll \\n[.l]u-\\n[#BL_INDENT]u
+.          if \\n[#INDENT_LEFT_ACTIVE] .ll \\n[.l]u-\\n[#L_INDENT]u
 \D't \\n[#RULE_WEIGHT]'\
 \h'\\*[$RL_INDENT]-\\n[#RULE_WEIGHT]u'\
 \v'\\n[#RULE_WEIGHT_ADJ]u'\
-\D'l \En(.lu 0'\v'-\\n[#RULE_WEIGHT_ADJ]u'\
+\D'l \En[.l]u 0'\v'-\\n[#RULE_WEIGHT_ADJ]u'\
 \v'-\\n[#RULE_WEIGHT_ADJ]u'\
 \D't \\n[#SAVED_RULE_WEIGHT]'
 .          ll \\n[#RESTORE_L_LENGTH]u
@@ -2827,7 +2762,7 @@
 \D't \\n[#RULE_WEIGHT]'\
 \h'\\*[$RL_INDENT]-\\n[#RULE_WEIGHT]u'\
 \v'\\n[#RULE_WEIGHT_ADJ]u'\
-\D'l \En(.lu 0'\v'-\\n[#RULE_WEIGHT_ADJ]u'\
+\D'l \En[.l]u 0'\v'-\\n[#RULE_WEIGHT_ADJ]u'\
 \v'-\\n[#RULE_WEIGHT_ADJ]u'\
 \D't \\n[#SAVED_RULE_WEIGHT]'
 .       \}
@@ -2841,16 +2776,16 @@
 \D't \\n[#SAVED_RULE_WEIGHT]'
 .    \}
 .    if \\n[#FILLED]=1 \{\
-.       if \\n[#FILL_MODE]=0 \{ .QUAD LEFT   \}
-.       if \\n[#FILL_MODE]=1 \{ .JUSTIFY     \}
-.       if \\n[#FILL_MODE]=3 \{ .QUAD CENTER \}
-.       if \\n[#FILL_MODE]=5 \{ .QUAD RIGHT  \}
+.       if \\n[#FILL_MODE]=0 .QUAD LEFT
+.       if \\n[#FILL_MODE]=1 .JUSTIFY
+.       if \\n[#FILL_MODE]=3 .QUAD CENTER
+.       if \\n[#FILL_MODE]=5 .QUAD RIGHT
 .       rr #FILLED
 .    \}
 .    sp -1v
 .    if \\n[#NOFILL]=1 \{\
-.       if \\n[#NOFILL_MODE]=3 \{ .CENTER \}
-.       if \\n[#NOFILL_MODE]=5 \{ .RIGHT  \}
+.       if \\n[#NOFILL_MODE]=3 .CENTER
+.       if \\n[#NOFILL_MODE]=5 .RIGHT
 .    \}
 .    gcolor
 .    nr #RULE_WEIGHT     \\n[#SAVED_WEIGHT]
@@ -2863,7 +2798,6 @@
 .    \}
 .END
 \#
-\#
 \# RULE
 \# ----
 \# *Argument:
@@ -2871,26 +2805,30 @@
 \# *Function:
 \#   Draws a rule the length of the current measure.
 \# *Notes:
-\#   A convenience macro.  DRV does the same thing.  Kept in for
-\#   backward compatibility.
+\#   A convenience macro.  DRH with no argument does the same thing.
+\#   Kept in for backward compatibility.
 \#
 .MAC RULE END
-.    if \\n(.u=1 \{\
+.    if \\n[.u]=1 \{\
 .       nr #FILLED 1
 .       ds $CURRENT_QUAD \\*[$QUAD_VALUE]
 .       nf
 .    \}
 .    ie \\n[#INDENT_ACTIVE] \{\
-.       if \\n[#INDENT_BOTH_ACTIVE] \{ .ll \\n(.lu-\\n[#BL_INDENT]u \}
-.       if \\n[#INDENT_LEFT_ACTIVE] \{ .ll \\n(.lu-\\n[#L_INDENT]u \}
-.       PRINT \D't \\n[#RULE_WEIGHT]'\v'\\n[#RULE_WEIGHT_ADJ]u'\D'l \En(.lu 
0'\v'-\\n[#RULE_WEIGHT_ADJ]u'\h'|0'\c
+.       if \\n[#INDENT_BOTH_ACTIVE] .ll \\n[.l]u-\\n[#BL_INDENT]u
+.       if \\n[#INDENT_LEFT_ACTIVE] .ll \\n[.l]u-\\n[#L_INDENT]u
+.       PRINT \
+\D't \\n[#RULE_WEIGHT]'\v'\\n[#RULE_WEIGHT_ADJ]u'\
+\D'l \En[.l]u 0'\v'-\\n[#RULE_WEIGHT_ADJ]u'\h'|0'\c
 .       ll
 .       rr #RESTORE_L_LENGTH
 .    \}
 .    el \{\
-.       PRINT \D't \\n[#RULE_WEIGHT]'\v'\\n[#RULE_WEIGHT_ADJ]u'\D'l \En(.lu 
0'\v'-\\n[#RULE_WEIGHT_ADJ]u'\h'|0'\c
+.       PRINT \
+\D't \\n[#RULE_WEIGHT]'\v'\\n[#RULE_WEIGHT_ADJ]u'\
+\D'l \En[.l]u 0'\v'-\\n[#RULE_WEIGHT_ADJ]u'\h'|0'\c
 .    \}
-.    if r#FILLED \{\
+.    if r #FILLED \{\
 .       fi
 .       rr #FILLED
 .       QUAD \\*[$CURRENT_QUAD]
@@ -2899,7 +2837,6 @@
 .    EOL
 .END
 \#
-\#
 \# VERTICAL RULE - DRV
 \# -------------------
 \# *Arguments:
@@ -2917,19 +2854,19 @@
 .       vpt 0
 .       nr #RESTORE_TRAP 1
 .    \}
-.    ie !\\n[#NO_ADVANCE]=1 \{ .br \}
+.    ie !\\n[#NO_ADVANCE]=1 .br
 .    el \{\
 .       sp -1v
 .       rr #NO_ADVANCE
 .    \}
-.    ie \\n(.u=1 \{\
+.    ie \\n[.u]=1 \{\
 .       nr #FILLED 1
-.       nr #FILL_MODE \\n(.j
+.       nr #FILL_MODE \\n[.j]
 .    \}
 .    el \{\
 .       nr #NOFILL 1
-.       if \\n[.ce]>0 \{ .nr #NOFILL_MODE 3 \}
-.       if \\n[.rj]>0 \{ .nr #NOFILL_MODE 5 \}
+.       if \\n[.ce]>0 .nr #NOFILL_MODE 3
+.       if \\n[.rj]>0 .nr #NOFILL_MODE 5
 .       ce 0
 .       rj 0
 .    \}
@@ -2945,25 +2882,23 @@
 .    \}
 .    nr #SAVED_WEIGHT     \\n[#RULE_WEIGHT]
 .    nr #SAVED_WEIGHT_ADJ \\n[#RULE_WEIGHT_ADJ]
-.    di NULL
 .       RULE_WEIGHT \\*[$RL_WEIGHT]
-.    di
 .    gcolor \\*[$RL_COLOR]
 \D't \\n[#RULE_WEIGHT]'\
 \h'\\*[$RL_INDENT]-\\n[#RULE_WEIGHT_ADJ]u'\
 \D'l 0 \\*[$RL_DEPTH]'\
 \D't \\n[#SAVED_RULE_WEIGHT]'
 .    if \\n[#FILLED]=1 \{\
-.       if \\n[#FILL_MODE]=0 \{ .QUAD LEFT   \}
-.       if \\n[#FILL_MODE]=1 \{ .JUSTIFY     \}
-.       if \\n[#FILL_MODE]=3 \{ .QUAD CENTER \}
-.       if \\n[#FILL_MODE]=5 \{ .QUAD RIGHT  \}
+.       if \\n[#FILL_MODE]=0 .QUAD LEFT
+.       if \\n[#FILL_MODE]=1 .JUSTIFY
+.       if \\n[#FILL_MODE]=3 .QUAD CENTER
+.       if \\n[#FILL_MODE]=5 .QUAD RIGHT
 .       rr #FILLED
 .    \}
 .    sp -1v
 .    if \\n[#NOFILL]=1 \{\
-.       if \\n[#NOFILL_MODE]=3 \{ .CENTER \}
-.       if \\n[#NOFILL_MODE]=5 \{ .RIGHT  \}
+.       if \\n[#NOFILL_MODE]=3 .CENTER
+.       if \\n[#NOFILL_MODE]=5 .RIGHT
 .    \}
 .    gcolor
 .    nr #RULE_WEIGHT     \\n[#SAVED_WEIGHT]
@@ -2972,6 +2907,9 @@
 .       vpt 1
 .       rr #RESTORE_TRAP
 .    \}
+.    if '\\n[.z]'FLOAT*DIV' \{\
+.       if !(\\n[.d]+\\*[$RL_DEPTH])<\\n[D-float] .nr D-float 
\\n[.d]+\\*[$RL_DEPTH]
+.    \}
 .END
 \#
 \# BOXES - DBX
@@ -2992,49 +2930,37 @@
 .       vpt 0
 .       nr #RESTORE_TRAP 1
 .    \}
-.    ie !\\n[#NO_ADVANCE]=1 \{ .br \}
+.    ie !\\n[#NO_ADVANCE]=1 .br
 .    el \{\
 .       sp -1v
 .       rr #NO_ADVANCE
 .    \}
-.    ie \\n(.u=1 \{\
+.    ie \\n[.u]=1 \{\
 .       nr #FILLED 1
-.       nr #FILL_MODE \\n(.j
+.       nr #FILL_MODE \\n[.j]
 .    \}
 .    el \{\
 .       nr #NOFILL 1
-.       if \\n[.ce]>0 \{ .nr #NOFILL_MODE 3 \}
-.       if \\n[.rj]>0 \{ .nr #NOFILL_MODE 5 \}
+.       if \\n[.ce]>0 .nr #NOFILL_MODE 3
+.       if \\n[.rj]>0 .nr #NOFILL_MODE 5
 .       ce 0
 .       rj 0
 .    \}
 .    nf
-.    ie '\\$1'SOLID' \{\
-.       nr #BX_SOLID 1
-.    \}
-.    el \{\
-.       ds $BX_WEIGHT \\$1
-.    \}
+.    ie '\\$1'SOLID' .nr #BX_SOLID 1
+.    el              .ds $BX_WEIGHT \\$1
 .    ds $BX_INDENT \\$2
 .    ds $BX_WIDTH \\$3
 .    ds $BX_DEPTH  \\$4
 .    ie !'\\$5'' \{\
-.       ie d$\\$5_FILL \{\
-.          ds $BX_COLOR \\*[$\\$5_FILL]
-.       \}
-.       el \{\
-.          ds $BX_COLOR \\$5
-.       \}
-.    \}
-.    el \{\
-.       ds $BX_COLOR default
+.       ie d$\\$5_FILL .ds $BX_COLOR \\*[$\\$5_FILL]
+.       el             .ds $BX_COLOR \\$5
 .    \}
+.    el .ds $BX_COLOR default
 .    nr #SAVED_WEIGHT     \\n[#RULE_WEIGHT]
 .    nr #SAVED_WEIGHT_ADJ \\n[#WEIGHT_ADJ]
 .    if !'\\$1'SOLID' \{\
-.       di NULL
 .          RULE_WEIGHT \\*[$BX_WEIGHT]
-.       di
 .    \}
 .    ds $BX_INDENT \\*[$BX_INDENT]-\\n[#WEIGHT_ADJ]u
 .    ie \\n[#BX_SOLID]=1 \{\
@@ -3056,15 +2982,15 @@
 .    \}
 .    sp -1v
 .    if \\n[#FILLED]=1 \{\
-.       if \\n[#FILL_MODE]=0 \{ .QUAD LEFT   \}
-.       if \\n[#FILL_MODE]=1 \{ .JUSTIFY     \}
-.       if \\n[#FILL_MODE]=3 \{ .QUAD CENTER \}
-.       if \\n[#FILL_MODE]=5 \{ .QUAD RIGHT  \}
+.       if \\n[#FILL_MODE]=0 .QUAD LEFT
+.       if \\n[#FILL_MODE]=1 .JUSTIFY
+.       if \\n[#FILL_MODE]=3 .QUAD CENTER
+.       if \\n[#FILL_MODE]=5 .QUAD RIGHT
 .       rr #FILLED
 .    \}
 .    if \\n[#NOFILL]=1 \{\
-.       if \\n[#NOFILL_MODE]=3 \{ .CENTER \}
-.       if \\n[#NOFILL_MODE]=5 \{ .RIGHT  \}
+.       if \\n[#NOFILL_MODE]=3 .CENTER
+.       if \\n[#NOFILL_MODE]=5 .RIGHT
 .    \}
 .    nr #RULE_WEIGHT \\n[#SAVED_WEIGHT]
 .    nr #WEIGHT_ADJ  \\n[#SAVED_WEIGHT_ADJ]
@@ -3074,9 +3000,11 @@
 .       vpt 1
 .       rr #RESTORE_TRAP
 .    \}
+.    if '\\n[.z]'FLOAT*DIV' \{\
+.       if !(\\n[.d]+\\*[$BX_DEPTH])<\\n[D-float] .nr D-float 
\\n[.d]+\\*[$BX_DEPTH]
+.    \}
 .END
 \#
-\#
 \# ELLIPSES - DCL
 \# --------------
 \# *Arguments:
@@ -3096,49 +3024,37 @@
 .       vpt 0
 .       nr #RESTORE_TRAP 1
 .    \}
-.    ie !\\n[#NO_ADVANCE]=1 \{ .br \}
+.    ie !\\n[#NO_ADVANCE]=1 .br
 .    el \{\
 .       sp -1v
 .       rr #NO_ADVANCE
 .    \}
-.    ie \\n(.u=1 \{\
+.    ie \\n[.u]=1 \{\
 .       nr #FILLED 1
-.       nr #FILL_MODE \\n(.j
+.       nr #FILL_MODE \\n[.j]
 .    \}
 .    el \{\
 .       nr #NOFILL 1
-.       if \\n[.ce]>0 \{ .nr #NOFILL_MODE 3 \}
-.       if \\n[.rj]>0 \{ .nr #NOFILL_MODE 5 \}
+.       if \\n[.ce]>0 .nr #NOFILL_MODE 3
+.       if \\n[.rj]>0 .nr #NOFILL_MODE 5
 .       ce 0
 .       rj 0
 .    \}
 .    nf
-.    ie '\\$1'SOLID' \{\
-.       nr #CL_SOLID 1
-.    \}
-.    el \{\
-.       ds $CL_WEIGHT \\$1
-.    \}
+.    ie '\\$1'SOLID' .nr #CL_SOLID 1
+.    el              .ds $CL_WEIGHT \\$1
 .    ds $CL_INDENT \\$2
 .    ds $CL_WIDTH  \\$3
 .    ds $CL_DEPTH  \\$4
 .    ie !'\\$5'' \{\
-.       ie d$\\$5_FILL \{\
-.          ds $CL_COLOR \\*[$\\$5_FILL]
-.       \}
-.       el \{\
-.          ds $CL_COLOR \\$5
-.       \}
-.    \}
-.    el \{\
-.       ds $CL_COLOR default
+.       ie d$\\$5_FILL .ds $CL_COLOR \\*[$\\$5_FILL]
+.       el             .ds $CL_COLOR \\$5
 .    \}
+.    el .ds $CL_COLOR default
 .    nr #SAVED_WEIGHT     \\n[#RULE_WEIGHT]
 .    nr #SAVED_WEIGHT_ADJ \\n[#WEIGHT_ADJ]
 .    if !'\\$1'SOLID' \{\
-.       di NULL
 .          RULE_WEIGHT \\*[$CL_WEIGHT]
-.       di
 .    \}
 .    ds $CL_INDENT \\*[$CL_INDENT]-\\n[#WEIGHT_ADJ]u
 .    ie \\n[#CL_SOLID]=1 \{\
@@ -3162,15 +3078,15 @@
 .    \}
 .    sp -1v
 .    if \\n[#FILLED]=1 \{\
-.       if \\n[#FILL_MODE]=0 \{ .QUAD LEFT   \}
-.       if \\n[#FILL_MODE]=1 \{ .JUSTIFY     \}
-.       if \\n[#FILL_MODE]=3 \{ .QUAD CENTER \}
-.       if \\n[#FILL_MODE]=5 \{ .QUAD RIGHT  \}
+.       if \\n[#FILL_MODE]=0 .QUAD LEFT
+.       if \\n[#FILL_MODE]=1 .JUSTIFY
+.       if \\n[#FILL_MODE]=3 .QUAD CENTER
+.       if \\n[#FILL_MODE]=5 .QUAD RIGHT
 .       rr #FILLED
 .    \}
 .    if \\n[#NOFILL]=1 \{\
-.       if \\n[#NOFILL_MODE]=3 \{ .CENTER \}
-.       if \\n[#NOFILL_MODE]=5 \{ .RIGHT  \}
+.       if \\n[#NOFILL_MODE]=3 .CENTER
+.       if \\n[#NOFILL_MODE]=5 .RIGHT
 .    \}
 .    nr #RULE_WEIGHT \\n[#SAVED_WEIGHT]
 .    nr #WEIGHT_ADJ  \\n[#SAVED_WEIGHT_ADJ]
@@ -3180,9 +3096,11 @@
 .       vpt 1
 .       rr #RESTORE_TRAP
 .    \}
+.    if '\\n[.z]'FLOAT*DIV' \{\
+.       if !(\\n[.d]+\\*[$CL_DEPTH])<\\n[D-float] .nr D-float 
\\n[.d]+\\*[$CL_DEPTH]
+.    \}
 .END
 \#
-\#
 \# RULE WEIGHT
 \# -----------
 \# *Argument:
@@ -3191,7 +3109,7 @@
 \#   Sets \D't <n>' to the correct number of machine units for the
 \#   argument given in points.
 \# *Notes:
-\#   Decimal fractions are allowed.  Rule weight must be > 100.
+\#   Decimal fractions are allowed.  Rule weight must be < 100.
 \#
 .MAC RULE_WEIGHT END
 .    di NULL \" Diverted so there's no problem with breaks, spacing, etc.
@@ -3199,7 +3117,7 @@
 .       substring $ARG -1
 .       if !\B'\\*[$ARG]' \{\
 .             tm1 "[mom]: The argument to \\$0 must not have a unit of measure 
appended.
-.             ab Aborting at \\$0, line \\n[.c].
+.          ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
 .       \}
 .       length #STR_LENGTH \\$1
 .       ds $ARG \\$1
@@ -3212,7 +3130,7 @@
 .              while (\\n[#WEIGHT]>=1000) \{\
 .                  nr #WEIGHT \\n[#WEIGHT]/10
 .   \}
-        \}
+.          \}
 .       \}
 .       el \{\
 .          ds $ARG \\$1
@@ -3230,15 +3148,13 @@
 .             \}
 .          \}
 .          el \{\
-.             ie \\n[#STR_LENGTH]<=2 \{\
-.                nr #WEIGHT \\$1*1000
-.             \}
+.             ie \\n[#STR_LENGTH]<=2 .nr #WEIGHT \\$1*1000
 .             el \{\
 .                ds $ARG \\$1
 .                substring $ARG 2 2
 .                ie !'\\*[$ARG]'.' \{\
 .                   tm1 "[mom]: Invalid argument given to macro \\$0 at line 
\\n[.c].
-.                   tm1 "       Rule weight must be > 100 points.
+.                   tm1 "       Rule weight must be < 100 points.
 .                   tm1 "       Falling back to default weight .5 points.
 .                   nr #WEIGHT 500
 .                \}
@@ -3266,9 +3182,9 @@
 .          nr #COVER_UNDERLINE_WEIGHT     \\n[#WEIGHT]
 .          nr #COVER_UNDERLINE_WEIGHT_ADJ \\n[#WEIGHT_ADJ]
 .       \}
-.       if '\\$0'DOCCOVER_UNDERLINE_WEIGHT' \{\
-.          nr #DOCCOVER_UNDERLINE_WEIGHT     \\n[#WEIGHT]
-.          nr #DOCCOVER_UNDERLINE_WEIGHT_ADJ \\n[#WEIGHT_ADJ]
+.       if '\\$0'DOC_COVER_UNDERLINE_WEIGHT' \{\
+.          nr #DOC_COVER_UNDERLINE_WEIGHT     \\n[#WEIGHT]
+.          nr #DOC_COVER_UNDERLINE_WEIGHT_ADJ \\n[#WEIGHT_ADJ]
 .       \}
 .       if '\\$0'DOCTYPE_UNDERLINE_WEIGHT' \{\
 .          nr #DOCTYPE_UNDERLINE_WEIGHT     \\n[#WEIGHT]
@@ -3290,10 +3206,6 @@
 .          nr #FN_RULE_WEIGHT     \\n[#WEIGHT]
 .          nr #FN_RULE_WEIGHT_ADJ \\n[#WEIGHT_ADJ]
 .       \}
-.       if '\\$0'HEAD_UNDERLINE_WEIGHT' \{\
-.          nr #HEAD_UNDERLINE_WEIGHT     \\n[#WEIGHT]
-.          nr #HEAD_UNDERLINE_WEIGHT_ADJ \\n[#WEIGHT_ADJ]
-.       \}
 .       if '\\$0'HEADER_RULE_WEIGHT' \{\
 .          nr #HEADER_RULE_WEIGHT     \\n[#WEIGHT]
 .          nr #HEADER_RULE_WEIGHT_ADJ \\n[#WEIGHT_ADJ]
@@ -3310,16 +3222,15 @@
 .END
 \#
 \# Aliases
-\# ~~~~~~~
+\# 
 .ALIAS BIBLIOGRAPHY_STRING_UNDERLINE_WEIGHT RULE_WEIGHT
 .ALIAS COVER_UNDERLINE_WEIGHT               RULE_WEIGHT
-.ALIAS DOCCOVER_UNDERLINE_WEIGHT            RULE_WEIGHT
+.ALIAS DOC_COVER_UNDERLINE_WEIGHT           RULE_WEIGHT
 .ALIAS DOCTYPE_UNDERLINE_WEIGHT             RULE_WEIGHT
 .ALIAS ENDNOTE_STRING_UNDERLINE_WEIGHT      RULE_WEIGHT
 .ALIAS ENDNOTE_TITLE_UNDERLINE_WEIGHT       RULE_WEIGHT
 .ALIAS FOOTER_RULE_WEIGHT                   RULE_WEIGHT
 .ALIAS FOOTNOTE_RULE_WEIGHT                 RULE_WEIGHT
-.ALIAS HEAD_UNDERLINE_WEIGHT                RULE_WEIGHT
 .ALIAS HEADER_RULE_WEIGHT                   RULE_WEIGHT
 .ALIAS UNDERSCORE_WEIGHT                    RULE_WEIGHT
 \#
@@ -3327,29 +3238,27 @@
 \# ~~~~~~~~~~~~~~~~~~~~
 .nr #BIB_STRING_UNDERLINE_WEIGHT 500
 .nr #COVER_UNDERLINE_WEIGHT      500
-.nr #DOCCOVER_UNDERLINE_WEIGHT   500
+.nr #DOC_COVER_UNDERLINE_WEIGHT  500
 .nr #DOCTYPE_UNDERLINE_WEIGHT    500
 .nr #EN_STRING_UNDERLINE_WEIGHT  500
 .nr #EN_TITLE_UNDERLINE_WEIGHT   500
 .nr #FN_RULE_WEIGHT              500
 .nr #FOOTER_RULE_WEIGHT          500
-.nr #HEAD_UNDERLINE_WEIGHT       500
 .nr #HEADER_RULE_WEIGHT          500
 .nr #RULE_WEIGHT                 500
 .nr #UNDERSCORE_WEIGHT           500
 \#
-.nr #BIB_STRING_UNDERLINE_WEIGHT_ADJ \\n[#BIB_STRING_UNDERLINE_WEIGHT]/2
-.nr #COVER_UNDERLINE_WEIGHT_ADJ      \\n[#DOCTYPE_UNDERLINE_WEIGHT]/2
-.nr #DOCCOVER_UNDERLINE_WEIGHT_ADJ   \\n[#DOCTYPE_RULE_WEIGHT]/2
-.nr #DOCTYPE_UNDERLINE_WEIGHT_ADJ    \\n[#DOCTYPE_RULE_WEIGHT]/2
-.nr #EN_STRING_UNDERLINE_WEIGHT_ADJ  \\n[#EN_STRING_UNDERLINE_WEIGHT]/2
-.nr #EN_TITLE_UNDERLINE_WEIGHT_ADJ   \\n[#EN_STRING_UNDERLINE_WEIGHT]/2
-.nr #FOOTER_RULE_WEIGHT_ADJ          \\n[#FOOTER_RULE_WEIGHT]/2
-.nr #FN_RULE_WEIGHT_ADJ              \\n[#FN_RULE_WEIGHT]/2
-.nr #HEAD_UNDERLINE_WEIGHT_ADJ       \\n[#HEAD_UNDERLINE_WEIGHT]/2
-.nr #HEADER_RULE_WEIGHT_ADJ          \\n[#HEADER_RULE_WEIGHT]/2
-.nr #RULE_WEIGHT_ADJ                 \\n[#RULE_WEIGHT]/2
-.nr #UNDERSCORE_WEIGHT_ADJ           \\n[#UNDERSCORE_WEIGHT]/2
+.nr #BIB_STRING_UNDERLINE_WEIGHT_ADJ \n[#BIB_STRING_UNDERLINE_WEIGHT]/2
+.nr #COVER_UNDERLINE_WEIGHT_ADJ      \n[#DOCTYPE_UNDERLINE_WEIGHT]/2
+.nr #DOC_COVER_UNDERLINE_WEIGHT_ADJ  \n[#DOCTYPE_RULE_WEIGHT]/2
+.nr #DOCTYPE_UNDERLINE_WEIGHT_ADJ    \n[#DOCTYPE_RULE_WEIGHT]/2
+.nr #EN_STRING_UNDERLINE_WEIGHT_ADJ  \n[#EN_STRING_UNDERLINE_WEIGHT]/2
+.nr #EN_TITLE_UNDERLINE_WEIGHT_ADJ   \n[#EN_STRING_UNDERLINE_WEIGHT]/2
+.nr #FOOTER_RULE_WEIGHT_ADJ          \n[#FOOTER_RULE_WEIGHT]/2
+.nr #FN_RULE_WEIGHT_ADJ              \n[#FN_RULE_WEIGHT]/2
+.nr #HEADER_RULE_WEIGHT_ADJ          \n[#HEADER_RULE_WEIGHT]/2
+.nr #RULE_WEIGHT_ADJ                 \n[#RULE_WEIGHT]/2
+.nr #UNDERSCORE_WEIGHT_ADJ           \n[#UNDERSCORE_WEIGHT]/2
 \#
 \# Set default rule weight
 \#
@@ -3373,9 +3282,6 @@
 \#   $WS_VAR is the user supplied amount by which to in/decrease word space.
 \#   $WS is a concatenation of WS_CONSTANT and WS_VAR.
 \#
-\#   Because the user supplied value requires a literal + or - sign,
-\#   the macro argument is stored in a string.
-\#
 \#   \n[.sss] holds the current sentence space value.
 \#
 .MAC WS END
@@ -3383,14 +3289,13 @@
 .    ds $WS_VAR \\$1
 .    ie '\\$1'DEFAULT' .ds $WS_VAR +0
 .    el                .ds $WS (\\*[$WS_CONSTANT]\\*[$WS_VAR])
-.    ie \\n[.sss]=12   \{ .ss \\*[$WS] 12 \}
+.    ie \\n[.sss]=12 .ss \\*[$WS] 12
 .    el \{\
 .       ss \\*[$WS] (\\*[$WS]\\*[$SS_VAR])
 .       SS \\*[$SS_VAR]
 .    \}
 .END
 \#
-\#
 \# SENTENCE SPACE CONTROL
 \# ----------------------
 \# *Argument:
@@ -3413,162 +3318,76 @@
 \#
 .MAC SS END
 .    ds $SS_VAR \\$1
-.    ie '\\$1'0' \{ .ss \\n[.ss] (\\n[.ss]-\\n[.ss]) \}
+.    ie '\\$1'0' .ss \\n[.ss] (\\n[.ss]-\\n[.ss])
 .    el \{\
-.       ie '\\$1'DEFAULT' \{ .ss \\n[.ss] \}
-.       el \{\
-.          ss \\n[.ss] (0\\*[$SS_VAR])
-.       \}
+.       ie '\\$1'DEFAULT' .ss \\n[.ss]
+.       el                .ss \\n[.ss] (0\\*[$SS_VAR])
 .    \}
 .END
 \#
-\#
 \# =====================================================================
 \#
-\# +++INDENTS+++
-\#
-\# There are five styles of indents: left, right, both, temporary,
-\# and hanging.  Each is set/invoked with a different macro.
-\# Indent macros begin with the letter "I", hence .IL means "indent left,"
-\# .IR means "indent right," and so on.
-\# 
-\# The first time any of the indent macros is used, it requires an
-\# argument--the size of the indent (with a unit of measure).  The
-\# size may also be entered using the \w escape--very useful
-\# for numbered lists using HI.  The unit of measure is required.
-\# Subsequent invocations don't require the argument; the indent
-\# measure remains the same until it's changed by invoking the macro
-\# with an argument again.
-\# 
-\# If no indents are in effect, the arguments passed to indent macros are
-\# measured from the left and right margins of the page.  If a left indent
-\# or a right indent is already in effect, the arguments passed to
-\# the indent macros are calculated from the current values; in other words,
-\# the arguments are additive.  If you quit an indent and later return
-\# to it, its value will be the value last in effect, unless you pass
-\# it an argument.  If you do pass an argument, it is added to the last
-\# value in effect, unless you cleared the indent with one of
-\# .I<LRB>X/Q macros.
-\# 
-\# Example
+\# INDENTS
 \# -------
 \# 
-\# .IL 2P
-\# ...some text...
-\# .IL 2P
-\# ...some text...
-\# .IQ
-\# ...some text...
-\# .IL
-\# ...some text...
-\# 
-\# The first .IL 2P indents text 2P from the left margin.  The second
-\# .IL 2P indents text by an additional 2P, i.e. 4P from the left margin.
-\# .IQ turns the indent off.  The last .IL (which has no argument)
-\# takes its value from the total of all arguments passed to .IL (in
-\# this case, 2P and 2P), therefore it indents 2P+2P from the left
-\# margin, i.e. 4P.  If you wanted the last .IL to indent just 2P,
-\# you'd either have to reset the .IL prior to .IQ (.IL -2P), or pass
-\# the last .IL the argument 2P.
-\# 
-\# To reverse the sense of an indent added to an indent, you may use
-\# negative values.
-\# 
-\# Indents can be turned off individually with ILX, IRX, and IBX.
-\# LEFT and RIGHT indents may be combined and manipulated
-\# separately, (e.g. you can have an IL of 2P and an IR of 4P
-\# operative at the same time, and then change, say, the IL to
-\# 4P--thereby left indenting 6P--while the IR remains at 4P.
-\# 
-\# IB automatically turns off IL and IR.  They have to be reinvoked
-\# again when needed. IL and IR automatically turn IB off; it, too,
-\# has to be reinvoked with needed.
-\# 
-\# All indents can be turned off at once with IQ.  The ILX, IRX, IBX,
-\# and IQ macros simply turn the indents off; the values stored in
-\# the respective indent macros (IL, IR, IB) remain in effect.  If
-\# the user wishes to clear the values, the I<LRB>X macros should be
-\# invoked with the single argument CLEAR.  IQ CLEAR clears out
-\# the values stored for all indent styles.
-\# 
-\# Indents *must* be turned off before settting string tabs
-\# inside PAD.  Generally, in order not to get confused, it's a
-\# good idea to turn all indents off before setting any tabs.
-\# 
-\# TI and HI are special cases.  There's no need to turn them off,
-\# since they affect only one line--the first after their
-\# invocation.  Like the other indent styles, the first time
-\# they're invoked, they require a value in iPpcm; each subsequent
-\# invocation without an argument will use the same value.  To
-\# change the value, simply pass a new value.  Values for TI and HI
-\# are *not* additive.
-\# 
-\# HI presupposes that you already have a left or both indent on.
-\# HI will never hang a line outside the left margin of a document
-\# or column.  In other words, you must have IL or IB on before you
-\# can use HI.
-\#
-\# INDENT LEFT
-\# -----------
+\# +++INDENT LEFT+++
 \#
 .MAC IL END
-.    if \\n[#INDENT_STYLE_BOTH] \{ .IBX \}
+.    if \\n[#INDENT_STYLE_BOTH] .IBX
 .    nr #INDENT_STYLE_LEFT  1
 .    nr #INDENT_ACTIVE      1
 .    nr #INDENT_LEFT_ACTIVE 1
 .    ie '\\$1'' \{\
 .       br
 .       in \\n[#L_INDENT]u
-.       ta \\n(.lu-\\n[#L_INDENT]u
+.       ta \\n[.l]u-\\n[#L_INDENT]u
 .    \}
 .    el \{\
 .       br
 .       nr #L_INDENT +(\\$1)
 .       in \\n[#L_INDENT]u
-.       ta \\n(.lu-\\n[#L_INDENT]u
+.       ta \\n[.l]u-\\n[#L_INDENT]u
 .    \}
 .    if \\n[#IN_ITEM] .nr #IN_ITEM_L_INDENT +(\\$1)
 .END
 \#
-\#
 \# +++INDENT RIGHT+++
 \#
 .MAC IR END
-.    if \\n[#INDENT_STYLE_BOTH] \{ .IBX \}
+.    if \\n[#INDENT_STYLE_BOTH] .IBX
 .    nr #INDENT_STYLE_RIGHT   1
 .    nr #INDENT_ACTIVE        1
 .    nr #INDENT_RIGHT_ACTIVE  1
 .    ie '\\$1'' \{\
 .       br
 .       ie \\n[#TAB_ACTIVE] \{\
-.          ll \\n(.lu-\\n[#R_INDENT]u
-.          ta \\n(.lu-\\n[#L_INDENT]u
+.          ll \\n[.l]u-\\n[#R_INDENT]u
+.          ta \\n[.l]u-\\n[#L_INDENT]u
 .       \}
 .       el \{\
 .          ll \\n[#L_LENGTH]u-\\n[#R_INDENT]u
-.          ta \\n(.lu-\\n[#L_INDENT]u
+.          ta \\n[.l]u-\\n[#L_INDENT]u
 .       \}
 .    \}
 .    el \{\
 .       br
 .       nr #R_INDENT +(\\$1)
 .       ie \\n[#TAB_ACTIVE] \{\
-.          ll \\n(.lu-\\n[#R_INDENT]u
-.          ta \\n(.lu-\\n[#L_INDENT]u
+.          ll \\n[.l]u-\\n[#R_INDENT]u
+.          ta \\n[.l]u-\\n[#L_INDENT]u
 .       \}
 .       el \{\
 .          ll \\n[#L_LENGTH]u-\\n[#R_INDENT]u
-.          ta \\n(.lu-\\n[#L_INDENT]u
+.          ta \\n[.l]u-\\n[#L_INDENT]u
 .       \}
 .    \}
 .END
 \#
-\#
 \# +++INDENT BOTH+++
 \#
 .MAC IB END
-.    if \\n[#INDENT_STYLE_LEFT]  \{ .ILX \}
-.    if \\n[#INDENT_STYLE_RIGHT] \{ .IRX \}
+.    if \\n[#INDENT_STYLE_LEFT] .ILX
+.    if \\n[#INDENT_STYLE_RIGHT] .IRX
 .    nr #INDENT_STYLE_BOTH  1
 .    nr #INDENT_ACTIVE      1
 .    nr #INDENT_BOTH_ACTIVE 1
@@ -3576,45 +3395,40 @@
 .       br
 .       in \\n[#BL_INDENT]u
 .       ie \\n[#TAB_ACTIVE] \{\
-.          ll \\n(.lu-\\n[#BR_INDENT]u
-.          ta \\n(.lu-\\n[#BR_INDENT]u
+.          ll \\n[.l]u-\\n[#BR_INDENT]u
+.          ta \\n[.l]u-\\n[#BR_INDENT]u
 .       \}
 .       el \{\
 .          ll \\n[#L_LENGTH]u-\\n[#BR_INDENT]u
-.          ta \\n(.lu-\\n[#BR_INDENT]u
+.          ta \\n[.l]u-\\n[#BR_INDENT]u
 .       \}
 .    \}
 .    el \{\
 .       br
 .       nr #BL_INDENT (\\n[#INDENT]+\\$1)
-.       ie \\n[#NUM_ARGS]=2 \{ .nr #BR_INDENT +(\\$2) \}
-.       el                  \{ .nr #BR_INDENT \\n[#BL_INDENT] \}
+.       ie \\n[#NUM_ARGS]=2 .nr #BR_INDENT +(\\$2)
+.       el .nr #BR_INDENT \\n[#BL_INDENT]
 .       ie \\n[#TAB_ACTIVE] \{\
 .          in \\n[#BL_INDENT]u
-.          ll \\n(.lu-\\n[#BR_INDENT]u
-.          ta \\n(.lu-\\n[#BL_INDENT]u
+.          ll \\n[.l]u-\\n[#BR_INDENT]u
+.          ta \\n[.l]u-\\n[#BL_INDENT]u
 .       \}
 .       el \{\
 .          in \\n[#BL_INDENT]u
 .          ll \\n[#L_LENGTH]u-\\n[#BR_INDENT]u
-.          ta \\n(.lu-\\n[#BR_INDENT]u
+.          ta \\n[.l]u-\\n[#BR_INDENT]u
 .       \}
 .    \}
 .END
 \#
-\#
 \# +++TEMPORARY INDENT+++
 \#
 .MAC TI END
 .    br
 .    ie '\\$1'' \{\
 .       ti \\n[#T_INDENT]u
-.       if \\n[#INDENT_LEFT_ACTIVE] \{\
-.          ti \\n[#T_INDENT]u+\\n[#L_INDENT]u
-.       \}
-.       if \\n[#INDENT_BOTH_ACTIVE] \{\
-.          ti \\n[#T_INDENT]u+\\n[#BL_INDENT]u
-.       \}
+.       if \\n[#INDENT_LEFT_ACTIVE] .ti \\n[#T_INDENT]u+\\n[#L_INDENT]u
+.       if \\n[#INDENT_BOTH_ACTIVE] .ti \\n[#T_INDENT]u+\\n[#BL_INDENT]u
 .    \}
 .    el \{\
 .       nr #T_INDENT (\\$1)
@@ -3622,22 +3436,20 @@
 .    \}
 .END
 \#
-\#
 \# +++HANGING INDENT+++
 \#
 .MAC HI END
-.    ie '\\$1'' \{ .ti -\\n[#HL_INDENT]u \}
+.    ie '\\$1'' .ti -\\n[#HL_INDENT]u
 .    el \{\
 .       nr #HL_INDENT (\\$1)
 .       ti -\\n[#HL_INDENT]u
 .    \}
 .END
 \#
-\#
 \# +++INDENTS OFF+++
 \#
 .MAC ILX END
-.    ie \\n[#IN_ITEM] \{ .nr #L_INDENT -\\n[#IN_ITEM_L_INDENT] \}
+.    ie \\n[#IN_ITEM] .nr #L_INDENT -\\n[#IN_ITEM_L_INDENT]
 .    el \{\
 .       br
 .       in 0
@@ -3649,19 +3461,18 @@
 .    \}
 .END
 \#
-\#
 .MAC IRX END
 .    br
 .    rr #INDENT_RIGHT_ACTIVE
-.    ie \\n[#TAB_ACTIVE] \{ .TAB\\n[#CURRENT_TAB] \}
+.    ie \\n[#TAB_ACTIVE] .TAB\\n[#CURRENT_TAB]
 .    el \{\
 .       ie \\n[#COLUMNS] \{\
 .          ll \\n[#COL_L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .       el \{\
 .          ll \\n[#L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .    \}
 .    if '\\$1'CLEAR' \{\
@@ -3670,20 +3481,19 @@
 .    \}
 .END
 \#
-\#
 .MAC IBX END
 .    br
 .    in 0
 .    rr #INDENT_BOTH_ACTIVE
-.    ie \\n[#TAB_ACTIVE] \{ .TAB\\n[#CURRENT_TAB] \}
+.    ie \\n[#TAB_ACTIVE] .TAB\\n[#CURRENT_TAB]
 .    el \{\
 .       ie \\n[#COLUMNS] \{\
 .          ll \\n[#COL_L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .       el \{\
 .          ll \\n[#L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .    \}
 .    if '\\$1'CLEAR' \{\
@@ -3693,11 +3503,10 @@
 .    \}
 .END
 \#
-\#
 .MAC IX END
 .    if '\\$0'IX' \{\
 .       if !\\n[#IX_WARN] \{\
-.          tm1 "[mom]: Use of .IX is now deprecated.  Use .IQ instead.
+.          tm1 "[mom]: Use of .IX is deprecated.  Use .IQ instead.
 .          tm1 "      .IX will continue to behave as before, but to
 .          tm1 "       avoid this message, please update your document.
 .          nr #IX_WARN 1
@@ -3709,55 +3518,55 @@
 .    rr #INDENT_RIGHT_ACTIVE
 .    rr #INDENT_BOTH_ACTIVE
 .    if \\n[#INDENT_STYLE_RIGHT] \{\
-.       ie \\n[#TAB_ACTIVE] \{ .TAB\\n[#CURRENT_TAB] \}
+.       ie \\n[#TAB_ACTIVE] .TAB\\n[#CURRENT_TAB]
 .       el \{\
 .          ie \\n[#COLUMNS] \{\
 .             ll \\n[#COL_L_LENGTH]u
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .          el \{\
 .             ll \\n[#L_LENGTH]u
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .       \}
 .    \}
 .    if \\n[#INDENT_STYLE_BOTH] \{\
-.       ie \\n[#TAB_ACTIVE] \{ .TAB\\n[#CURRENT_TAB] \}
+.       ie \\n[#TAB_ACTIVE] .TAB\\n[#CURRENT_TAB]
 .       el \{\
 .          ie \\n[#COLUMNS] \{\
 .             ll \\n[#COL_L_LENGTH]u
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .          el \{\
 .             ll \\n[#L_LENGTH]u
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .       \}
 .    \}
 .    if '\\$1'CLEAR' \{\
 .       if \\n[#INDENT_STYLE_RIGHT] \{\
-.          ie \\n[#TAB_ACTIVE] \{ .TAB\\n[#CURRENT_TAB] \}
+.          ie \\n[#TAB_ACTIVE] .TAB\\n[#CURRENT_TAB]
 .          el \{\
 .             ie \\n[#COLUMNS] \{\
 .                ll \\n[#COL_L_LENGTH]u
-.                ta \\n(.lu
+.                ta \\n[.l]u
 .             \}
 .             el \{\
 .                ll \\n[#L_LENGTH]u
-.                ta \\n(.lu
+.                ta \\n[.l]u
 .             \}
 .          \}
 .       \}
 .       if \\n[#INDENT_STYLE_BOTH] \{\
-.          ie \\n[#TAB_ACTIVE] \{ .TAB\\n[#CURRENT_TAB] \}
+.          ie \\n[#TAB_ACTIVE] .TAB\\n[#CURRENT_TAB]
 .          el \{\
 .             ie \\n[#COLUMNS] \{\
 .                ll \\n[#COL_L_LENGTH]u
-.                ta \\n(.lu
+.                ta \\n[.l]u
 .             \}
 .             el \{\
 .                ll \\n[#L_LENGTH]u
-.                ta \\n(.lu
+.                ta \\n[.l]u
 .             \}
 .          \}
 .       \}
@@ -3786,7 +3595,7 @@
 \#   Marks the top of a column set
 \#
 .MAC MCO END
-.mk c
+.    mk c
 .END
 \#
 \# MULTIPLE COLUMN RETURN
@@ -3798,7 +3607,7 @@
 \#
 .MAC MCR END
 .    TRAP OFF
-.    sp |\\ncu
+.    sp |\\n[c]u
 .    TRAP
 .END
 \#
@@ -3819,13 +3628,13 @@
 .    TRAP OFF
 .    ie '\\$1'' \{\
 .       TQ
-.       sp |\\n(.hu
+.       sp |\\n[.h]u
 .    \}
 .    el \{\
 .       nr #MCX_ALD (\\$1)
 .       TQ
-.       ie \\n[#MCX_ALD]=0 \{ .sp |\\n(.hu-1v \}
-.       el \{ .sp |\\n(.hu+\\n[#MCX_ALD]u \}
+.       ie \\n[#MCX_ALD]=0 .sp |\\n[.h]u-1v
+.       el .sp |\\n[.h]u+\\n[#MCX_ALD]u
 .       rr #MCX_ALD
 .    \}
 .    TRAP
@@ -3849,11 +3658,10 @@
 \#   The user simply enloses the offending lines in TRAP OFF/TRAP.
 \#
 .MAC TRAP END
-.    ie '\\$1'' \{ .vpt 1 \}
-.    el \{ .vpt 0 \}
+.    ie '\\$1'' .vpt 1
+.    el         .vpt 0
 .END
 \#
-\#
 \# SILENT
 \# ------
 \# *Arguments:
@@ -3869,8 +3677,8 @@
 \#
 .MAC SILENT END
 .    nr #SILENT 1
-.    if \\n[#QUAD] \{ .br \}
-.    ie '\\$1'' \{ .di NO_FLASH \}
+.    if \\n[#QUAD] .br
+.    ie '\\$1'' .di NO_FLASH
 .    el \{\
 .       br
 .       di
@@ -3879,7 +3687,6 @@
 .    \}
 .END
 \#
-\#
 \# PRINT
 \# -----
 \# *Function:
@@ -3889,7 +3696,6 @@
 .    nop \\$*
 .END
 \#
-\#
 \# CAPS
 \# ----
 \# *Arguments:
@@ -4058,6 +3864,9 @@
 \#   The routine is diverted so it remains invisible to output.
 \#
 .MAC SIZESPECS END
+.    if '\\n[.z]'FLOAT*DIV' \{\
+.       if \\n[dn] .nr saved-dn \\n[dn]
+.    \}
 .    di TYPESIZE
 E\\R'#CAP_HEIGHT \\n[.cht]'
 e\\R'#X_HEIGHT \\n[.cht]'
@@ -4067,6 +3876,9 @@
 .    ds $X_HEIGHT \\n[#X_HEIGHT]u
 .    ds $DESCENDER \\n[#DESCENDER]u
 .    di
+.    if '\\n[.z]'FLOAT*DIV' \{\
+.       nr dn \\n[saved-dn]
+.    \}
 .END
 \#
 \# =====================================================================
@@ -4097,7 +3909,8 @@
 .ALIAS    TB              TAB
 .ALIAS    UNDERSCORE_2    UNDERSCORE2
 .ALIAS    XCOLOUR         XCOLOR
-\#
+.ALIAS    PDF_LINK_COLOUR PDF_LINK_COLOR
+.ALIAS    AUTO_TOC_RELOCATE AUTO_RELOCATE_TOC
 \#
 \# ====================================================================
 \#
@@ -4171,11 +3984,10 @@
 .       PAGEWIDTH  501p
 .       PAGELENGTH 709p
 .    \}
-.    if !r#L_MARGIN \{ .L_MARGIN \\n(.o \}
-.    if !r#R_MARGIN \{ .R_MARGIN 1i \}
+.    if !r#L_MARGIN .L_MARGIN \\n[.o]
+.    if !r#R_MARGIN .R_MARGIN 1i
 .END
 \#
-\#
 \# ====================================================================
 \#
 \# +++PRINTSTYLE -- TYPEWRITE OR TYPESET+++
@@ -4191,11 +4003,11 @@
 \#
 .MAC PRINTSTYLE END
 .    if !\\n[#COLLATE]=1 \{\
-.       if !d$PAPER \{ .PAPER LETTER \}
+.       if !d$PAPER .PAPER LETTER
 .       if '\\$1'TYPEWRITE' \{\
 .          nr #PRINT_STYLE 1
-.          if !\\n[#DOC_TYPE]=4 \{ .L_MARGIN 6P \}
-.          if !\\n[#DOC_TYPE]=4 \{ .R_MARGIN 6P \}
+.          if !\\n[#DOC_TYPE]=4 .L_MARGIN 6P
+.          if !\\n[#DOC_TYPE]=4 .R_MARGIN 6P
 .          ds $TYPEWRITER_FAM     C
 .          ds $TYPEWRITER_PS      12
 .          TYPEWRITER
@@ -4203,47 +4015,42 @@
 .          ie '\\$2'SINGLESPACE' \{\
 .             nr #SINGLE_SPACE 1
 .             vs 12
-.             nr #ORIGINAL_DOC_LEAD \\n(.v
+.             nr #ORIGINAL_DOC_LEAD \\n[.v]
 .          \}
 .          el \{\
 .             vs 24
-.             nr #ORIGINAL_DOC_LEAD \\n(.v
+.             nr #ORIGINAL_DOC_LEAD \\n[.v]
 .          \}
 .          QUAD    L
 .          HY      OFF
 .          SMARTQUOTES OFF
-.          if !\\n[#PP_INDENT] \{\
-.             in 3P                 \"Set indent
-.             nr #PP_INDENT \\n(.i  \"Read into #PP_INDENT
-.             in 0                  \"Remove indent
-.          \}
+.          if !\\n[#PP_INDENT] .nr #PP_INDENT 3P
 .          HDRFTR_RIGHT_CAPS
 .          nr #BOLDER_UNITS 0
 .          nr #CONDENSE 0
 .          nr #EXTEND 0
-.          if !\\n[#ITALIC_MEANS_ITALIC]  \{ .rm IT \}
+.          if !\\n[#ITALIC_MEANS_ITALIC] .rm IT
 .          rm BD
 .          rm BDI
-.          if !\\n[#ITALIC_MEANS_ITALIC] \{ .rm PREV          \}
-.          if !\\n[#SLANT_MEANS_SLANT]   \{ .UNDERLINE_SLANT  \}
-.          if !\\n[#ITALIC_MEANS_ITALIC] \{ .UNDERLINE_ITALIC \}
-.          if !\\n[#UNDERLINE_QUOTES]    \{ .UNDERLINE_QUOTES \}
+.          if !\\n[#ITALIC_MEANS_ITALIC] .rm PREV
+.          if !\\n[#SLANT_MEANS_SLANT]   .UNDERLINE_SLANT
+.          if !\\n[#ITALIC_MEANS_ITALIC] .UNDERLINE_ITALIC
+.          if !\\n[#UNDERLINE_QUOTES]    .UNDERLINE_QUOTES
 .          nr #IGNORE_COLUMNS 1
 .          nr #RULE_WEIGHT 500
-.          nr #HEAD_UNDERLINE_WEIGHT 500
-.          char \(em --
+.          char \[em] --
 .          tr `'
-.          tr \(lq"
-.          tr \(rq"
+.          tr \[lq]"
+.          tr \[rq]"
 .       \}
 .       if '\\$1'TYPESET' \{\
 .          nr #PRINT_STYLE 2
-.          if !\\n[#DOC_TYPE]=4 \{ .L_MARGIN 6P \}
-.          if !\\n[#DOC_TYPE]=4 \{ .R_MARGIN 6P \}
+.          if !\\n[#DOC_TYPE]=4 .L_MARGIN 6P
+.          if !\\n[#DOC_TYPE]=4 .R_MARGIN 6P
 .          FAMILY  T
 .          FT      R
-.          if !\\n[#DOC_TYPE]=4 \{ .PT_SIZE 12.5 \}
-.          if !\\n[#DOC_TYPE]=4 \{ .LS 16 \}
+.          if !\\n[#DOC_TYPE]=4 .PT_SIZE 12.5
+.          if !\\n[#DOC_TYPE]=4 .LS 16
 .          JUSTIFY
 .          HY
 .          HY_SET 2 36p 1p
@@ -4253,16 +4060,43 @@
 .          SMARTQUOTES
 .          if !\\n[#PP_INDENT] \{\
 .             in 2m                 \"Set indent
-.             nr #PP_INDENT \\n(.i  \"Read into #PP_INDENT
+.             nr #PP_INDENT \\n[.i] \"Read into #PP_INDENT
 .             in 0                  \"Remove indent
 .          \}
 .          HDRFTR_RIGHT_CAPS
 .          rr #IGNORE_COLUMNS
 .       \}
+.\" Set up default style for nine levels of headings
+.       nr #HD_LEVEL 0 1 \" loop step
+.       nr #LOOP 9       \" loop count
+.       while \\n+[#HD_LEVEL]<=\\n[#LOOP] \{\
+.           HEADING_STYLE \\n[#HD_LEVEL] \
+            FONT   B \
+            SIZE  +0 \
+            QUAD   L \
+            COLOR  black
+.\"  Set up default style for nine levels of TOC headings
+.           TOC_ENTRY_STYLE \\n[#HD_LEVEL] \
+            FONT   R \
+            SIZE  +0 \
+            COLOR  black
+.       \}
+.\" Set up decreasing sizes for headings levels 1 - 3, starting at +3
+.       nr #HD_LEVEL 0 1 \" loop step
+.       nr #LOOP 3       \" loop count
+.       nr #HD_SIZE 4 1
+.       while \\n+[#HD_LEVEL]<=\\n[#LOOP] \{\
+.          nr #HD_SIZE_CHANGE \\n-[#HD_SIZE]
+.          ds $HEAD_\\n[#HD_LEVEL]_SIZE +\\n[#HD_SIZE_CHANGE]
+.       \}
+.\" Set up TOC title style
+.       TOC_TITLE_STYLE \
+            FONT   R \
+            SIZE  +0 \
+            INDENT 0
 .    \}
 .END
 \#
-\#
 \# PRINTSTYLE TYPEWRITE control.
 \#
 .MAC TYPEWRITER_FAMILY END
@@ -4281,7 +4115,6 @@
 .    ps  \\*[$TYPEWRITER_PS]
 .END
 \#
-\#
 \# ITALIC MEANS ITALIC
 \# -------------------
 \# *Argument:
@@ -4300,13 +4133,12 @@
 .       rm ROM
 .       rm IT
 .       rm PREV
-.       ds ROM  \EfR
-.       ds IT   \EfI
+.       ds ROM  \Ef[R]
+.       ds IT   \Ef[I]
 .       ds PREV \Ef[]
 .    \}
 .END
 \#
-\#
 \# UNDERLINE ITALIC
 \# ----------------
 \# *Argument:
@@ -4333,7 +4165,6 @@
 .    \}
 .END
 \#
-\#
 \# UNDERLINE SLANT
 \# ---------------
 \# *Arguments:
@@ -4363,7 +4194,6 @@
 .    \}
 .END
 \#
-\#
 .MAC SLANT_MEANS_SLANT END
 .    if \\n[#PRINT_STYLE]=1 \{\
 .       rr #UNDERLINE_SLANT
@@ -4375,12 +4205,10 @@
 .    \}
 .END
 \#
-\#
 .MAC IGNORE_COLUMNS END
-.    if \\n[#PRINT_STYLE]=1 \{ .nr #NO_COLUMNS 1 \}
+.    if \\n[#PRINT_STYLE]=1 .nr #NO_COLUMNS 1
 .END
 \#
-\#
 \# ====================================================================
 \#
 \# +++COPY STYLE -- DRAFT OR FINAL+++
@@ -4399,21 +4227,19 @@
 .    ds $COPY_STYLE \\$1
 .    if '\\*[$COPY_STYLE]'DRAFT' \{\
 .       nr #COPY_STYLE 1
-.       if !d$DRAFT \{ .DRAFT 1 \}
+.       if !d$DRAFT .DRAFT 1
 .    \}
-.    if '\\*[$COPY_STYLE]'FINAL' \{ .nr #COPY_STYLE 2         \}
-.    if !d$CHAPTER_STRING        \{ .CHAPTER_STRING "Chapter" \}
-.    if !d$DRAFT_STRING          \{ .DRAFT_STRING "Draft"     \}
-.    if !d$REVISION_STRING       \{ .REVISION_STRING "Rev."   \}
+.    if '\\*[$COPY_STYLE]'FINAL' .nr #COPY_STYLE 2
+.    if !d$CHAPTER_STRING  .CHAPTER_STRING "Chapter"
+.    if !d$DRAFT_STRING    .DRAFT_STRING "Draft"
+.    if !d$REVISION_STRING .REVISION_STRING "Rev."
 .\" Default
 .    if \\n[#DOC_TYPE]=1 \{\
 .       ie \\n[#COPY_STYLE]=1 \{\
-.          ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] \}
-.          el \{ .PAGENUM_STYLE roman \}
+.          ie \\n[#PAGENUM_STYLE_SET] .PAGENUM_STYLE \\*[$PAGENUM_STYLE]
+.          el .PAGENUM_STYLE roman
 .          if \\n[#USER_DEF_HDRFTR_CENTER]=0 \{\
-.             ie \\n[#DRAFT_WITH_PAGENUM] \{\
-.                ds $HDRFTR_CENTER
-.             \}
+.             ie \\n[#DRAFT_WITH_PAGENUM] .ds $HDRFTR_CENTER
 .             el \{\
 .                ie '\\*[$REVISION]'' \{\
 .                   ds $HDRFTR_CENTER \
@@ -4428,9 +4254,9 @@
 .          \}
 .       \}
 .       el \{\
-.          ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] \}
-.          el \{ .PAGENUM_STYLE DIGIT \}
-.          if r#DRAFT_WITH_PAGENUM \{ .rr #DRAFT_WITH_PAGENUM \}
+.          ie \\n[#PAGENUM_STYLE_SET] .PAGENUM_STYLE \\*[$PAGENUM_STYLE]
+.          el                         .PAGENUM_STYLE DIGIT
+.          if \\n[#DRAFT_WITH_PAGENUM] .rr #DRAFT_WITH_PAGENUM
 .          if \\n[#USER_DEF_HDRFTR_CENTER]=0 \{\
 .             ds $HDRFTR_CENTER
 .             rr #USER_DEF_HDRFTR_CENTER
@@ -4441,20 +4267,20 @@
 .    if \\n[#DOC_TYPE]=2 \{\
 .\" Copystyle DRAFT
 .       ie \\n[#COPY_STYLE]=1 \{\
-.          ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] \}
-.          el \{ .PAGENUM_STYLE roman \}
+.          ie \\n[#PAGENUM_STYLE_SET] \
+.             PAGENUM_STYLE \\*[$PAGENUM_STYLE]
+.          el \
+.             PAGENUM_STYLE roman
 .          if \\n[#USER_DEF_HDRFTR_CENTER]=0 \{\
 .             ie \\n[#DRAFT_WITH_PAGENUM] \{\
 .                ie '\\*[$CHAPTER]'' \{\
-.                   ie !'\\*[$CHAPTER_TITLE_1]'' \{\
+.                   ie !'\\*[$CHAPTER_TITLE_1]'' \
 .                      ds $HDRFTR_CENTER \\*[$CHAPTER_TITLE]
-.                   \}
 .                   el .ds $HDRFTR_CENTER \\*[$CHAPTER_STRING]
 .                \}
 .                el \{\
-.                   ie !'\\*[$CHAPTER_TITLE_1]'' \{\
+.                   ie !'\\*[$CHAPTER_TITLE_1]'' \
 .                      ds $HDRFTR_CENTER \\*[$CHAPTER_TITLE]
-.                   \}
 .                   el .ds $HDRFTR_CENTER \\*[$CHAPTER_STRING] \\*[$CHAPTER]
 .                \}
 .             \}
@@ -4462,9 +4288,8 @@
 .                ie '\\*[$REVISION]'' \{\
 .                   ie '\\*[$CHAPTER]'' \{\
 .                      ie !'\\*[$CHAPTER_TITLE_1]'' \{\
-.                         ie '\\*[$DRAFT]'' \{\
+.                         ie '\\*[$DRAFT]'' \
 .                            ds $HDRFTR_CENTER \\*[$CHAPTER_TITLE]
-.                         \}
 .                         el \{\
 .                            ds $HDRFTR_CENTER \
                              \\*[$CHAPTER_TITLE], \
@@ -4485,9 +4310,8 @@
 .                   \}
 .                   el \{\
 .                      ie !'\\*[$CHAPTER_TITLE_1]'' \{\
-.                         ie '\\*[$DRAFT]'' \{\
+.                         ie '\\*[$DRAFT]'' \
 .                            ds $HDRFTR_CENTER \\*[$CHAPTER_TITLE]
-.                         \}
 .                         el \{\
 .                            ds $HDRFTR_CENTER \
                              \\*[$CHAPTER_TITLE_1], \
@@ -4570,43 +4394,38 @@
 .       \}
 .\" Copystyle FINAL
 .       el \{\
-.          if r#DRAFT_WITH_PAGENUM \{ .rr #DRAFT_WITH_PAGENUM \}
+.          if \\n[#DRAFT_WITH_PAGENUM] .rr #DRAFT_WITH_PAGENUM
 .          if \\n[#USER_DEF_HDRFTR_CENTER]=0 \{\
-.             ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] 
\}
-.             el \{ .PAGENUM_STYLE DIGIT \}
+.             ie \\n[#PAGENUM_STYLE_SET] \
+.                PAGENUM_STYLE \\*[$PAGENUM_STYLE]
+.             el .PAGENUM_STYLE DIGIT
 .             ie '\\*[$CHAPTER]'' \{\
-.                ie !'\\*[$CHAPTER_TITLE_1]'' \{\
+.                ie !'\\*[$CHAPTER_TITLE_1]'' \
 .                   ds $HDRFTR_CENTER \\*[$CHAPTER_TITLE]
-.                \}
-.                el \{\
+.                el \
 .                   ds $HDRFTR_CENTER \\*[$CHAPTER_STRING]
 .                \}
-.             \}
 .             el \{\
-.                ie !'\\*[$CHAPTER_TITLE_1]'' \{\
+.                ie !'\\*[$CHAPTER_TITLE_1]'' \
 .                   ds $HDRFTR_CENTER \\*[$CHAPTER_TITLE]
-.                \}
-.                el \{\
+.                el \
 .                   ds $HDRFTR_CENTER \\*[$CHAPTER_STRING] \\*[$CHAPTER]
 .                \}
 .             \}
 .          \}
 .       \}
-.    \}
 .\" Named
 .    if \\n[#DOC_TYPE]=3 \{\
 .       ie \\n[#COPY_STYLE]=1 \{\
-.          ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] \}
-.          el \{ .PAGENUM_STYLE roman \}
-.          ie \\n[#DRAFT_WITH_PAGENUM] \{\
+.          ie \\n[#PAGENUM_STYLE_SET] .PAGENUM_STYLE \\*[$PAGENUM_STYLE]
+.          el                         .PAGENUM_STYLE roman
+.          ie \\n[#DRAFT_WITH_PAGENUM] \
 .             ds $HDRFTR_CENTER \\*[$DOC_TYPE]
-.          \}
 .          el \{\
 .             if \\n[#USER_DEF_HDRFTR_CENTER]=0 \{\
 .                ie '\\*[$REVISION]'' \{\
-.                   ie '\\*[$DRAFT]'' \{\
+.                   ie '\\*[$DRAFT]'' \
 .                      ds $HDRFTR_CENTER \\*[$DOC_TYPE]
-.                   \}
 .                   el \{\
 .                      ds $HDRFTR_CENTER \
                        \\*[$DOC_TYPE], \
@@ -4630,10 +4449,10 @@
 .          \}
 .       \}
 .       el \{\
-.          if r#DRAFT_WITH_PAGENUM \{ .rr #DRAFT_WITH_PAGENUM \}
+.          if \\n[#DRAFT_WITH_PAGENUM] .rr #DRAFT_WITH_PAGENUM
 .          if \\n[#USER_DEF_HDRFTR_CENTER]=0 \{\
-.             ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] 
\}
-.             el \{ .PAGENUM_STYLE DIGIT \}
+.             ie \\n[#PAGENUM_STYLE_SET] .PAGENUM_STYLE \\*[$PAGENUM_STYLE]
+.             el .PAGENUM_STYLE DIGIT
 .             ds $HDRFTR_CENTER \\*[$DOC_TYPE]
 .          \}
 .       \}
@@ -4649,14 +4468,14 @@
 \# *Function:
 \#   Collect information about documents.
 \#
-\#
 .MAC DOCTITLE END
 .    rr #DOCTITLE_NUM
 .    nr #DOCTITLE_NUM 0 1
 .    while \\n[#NUM_ARGS]>\\n[#DOCTITLE_NUM] \{\
 .       ds $DOC_TITLE_\\n+[#DOCTITLE_NUM] \\$\\n[#DOCTITLE_NUM]
-.\}
+.    \}
 .    ds $DOC_TITLE \\$*
+.    PDF_TITLE \\*[$DOC_TITLE]
 .END
 \#
 .MAC TITLE END \"Document title
@@ -4665,7 +4484,7 @@
 .          nr #ITEM 0 1
 .          while \\n[#TITLE_NUM]>\\n[#ITEM] \{\
 .             rm $TITLE_\\n+[#ITEM]
-.\}
+.          \}
 .          rr #TITLE_NUM
 .       \}
 .    \}
@@ -4673,19 +4492,18 @@
 .       nr #TITLE_NUM 0 1
 .       while \\n[#NUM_ARGS]>\\n[#TITLE_NUM] \{\
 .          ds $TITLE_\\n+[#TITLE_NUM] \\$\\n[#TITLE_NUM]
-.\}
+.       \}
 .       ds $TITLE \\$*
 .    \}
 .END
 \#
-\#
 .MAC SUBTITLE END \"Document sub-title
 .    ie \\n[#NUM_ARGS]=0 \{\
 .       if \\n[#SUBTITLE_NUM] \{\
 .          nr #ITEM 0 1
 .          while \\n[#SUBTITLE_NUM]>\\n[#ITEM] \{\
 .             rm $SUBTITLE_\\n+[#ITEM]
-.\}
+.          \}
 .          rr #SUBTITLE_NUM
 .          rm $SUBTITLE
 .       \}
@@ -4693,47 +4511,45 @@
 .    el \{\
 .    if '\\$1'DOC_COVER' \{\
 .       shift
-.       nr #SUBTITLE_DOCCOVER_NUM 0 1
-.       while \\n[#NUM_ARGS]>\\n[#SUBTITLE_DOCCOVER_NUM] \{\
-.           ds $SUBTITLE_DOCCOVER_\\n+[#SUBTITLE_DOCCOVER_NUM] 
\\$\\n[#SUBTITLE_DOCCOVER_NUM]
-.\}
+.          nr #SUBTITLE_DOC_COVER_NUM 0 1
+.          while \\n[#NUM_ARGS]>\\n[#SUBTITLE_DOC_COVER_NUM] \{\
+.              ds $SUBTITLE_DOC_COVER_\\n+[#SUBTITLE_DOC_COVER_NUM] \
+\\$\\n[#SUBTITLE_DOC_COVER_NUM]
+.          \}
 .       return
 .    \}
 .    if '\\$1'COVER' \{\
 .       shift
 .       nr #SUBTITLE_COVER_NUM 0 1
 .       while \\n[#NUM_ARGS]>\\n[#SUBTITLE_COVER_NUM] \{\
-.           ds $SUBTITLE_COVER_\\n+[#SUBTITLE_COVER_NUM] 
\\$\\n[#SUBTITLE_COVER_NUM]
-.\}
+.              ds $SUBTITLE_COVER_\\n+[#SUBTITLE_COVER_NUM] \
+\\$\\n[#SUBTITLE_COVER_NUM]
+.          \}
 .       return
 .    \}
 .       nr #SUBTITLE_NUM 0 1
 .       while \\n[#NUM_ARGS]>\\n[#SUBTITLE_NUM] \{\
 .          ds $SUBTITLE_\\n+[#SUBTITLE_NUM] \\$\\n[#SUBTITLE_NUM]
-.\}
+.       \}
 .       ds $SUBTITLE \\$*
 .    \}
 .END
 \#
-\#
 .MAC CHAPTER END \"If document is a chapter, the chapter number
 .    nr #CHAPTER_CALLED 1
 .    ds $CHAPTER \\$1
-.    if r#CH_NUM \{\
-.       if \B'\\*[$CHAPTER]' \{\
-.          nr #CH_NUM \\*[$CHAPTER]
-.       \}
+.    if r #CH_NUM \{\
+.       if \B'\\*[$CHAPTER]' .nr #CH_NUM \\*[$CHAPTER]
 .    \}
 .END
 \#
-\#
 .MAC CHAPTER_TITLE END \" This defines what comes after Chapter #
 .    ie \\n[#NUM_ARGS]=0 \{\
 .       if \\n[#CHAPTER_TITLE_NUM] \{\
 .          nr #ITEM 0 1
 .          while \\n[#CHAPTER_TITLE_NUM]>\\n[#ITEM] \{\
 .             rm $CHAPTER_TITLE_\\n+[#ITEM]
-.\}
+.          \}
 .          rr #CHAPTER_TITLE_NUM
 .          rm $CHAPTER_TITLE
 .       \}
@@ -4742,36 +4558,34 @@
 .       rr #CHAPTER_TITLE_NUM
 .       nr #CHAPTER_TITLE_NUM 0 1
 .       while \\n[#NUM_ARGS]>\\n[#CHAPTER_TITLE_NUM] \{\
-.          ds $CHAPTER_TITLE_\\n+[#CHAPTER_TITLE_NUM] 
\\$\\n[#CHAPTER_TITLE_NUM]
-.\}
+.          ds $CHAPTER_TITLE_\\n+[#CHAPTER_TITLE_NUM] \
+\\$\\n[#CHAPTER_TITLE_NUM]
+.       \}
 .       ds $CHAPTER_TITLE \\$*
 .    \}
 .END
 \#
-\#
 .MAC DRAFT END \"Draft number
 .    ie '\\$1'' .ds $DRAFT 
 .    el         .ds $DRAFT " \\$1
 .END
 \#
-\#
 .MAC REVISION END \"Revision number
 .    ds $REVISION \\$1
 .END
 \#
-\#
 .MAC DRAFT_WITH_PAGENUMBER END \"Attach draft/revision strings to page number
 .    nr #DRAFT_WITH_PAGENUM 1
 .END
 \#
-\#
 .MAC AUTHOR END \"Author.  Enclose all args fully in double quotes.
 .    if '\\$1'DOC_COVER' \{\
 .       shift
 .       nr #AUTHOR_DOCCOVER_NUM 0 1
 .       while \\n[#NUM_ARGS]>\\n[#AUTHOR_DOCCOVER_NUM] \{\
-.           ds $AUTHOR_DOCCOVER_\\n+[#AUTHOR_DOCCOVER_NUM] 
\\$\\n[#AUTHOR_DOCCOVER_NUM]
-.\}
+.           ds $AUTHOR_DOCCOVER_\\n+[#AUTHOR_DOCCOVER_NUM] \
+\\$\\n[#AUTHOR_DOCCOVER_NUM]
+.       \}
 .       return
 .    \}
 .    if '\\$1'COVER' \{\
@@ -4779,7 +4593,7 @@
 .       nr #AUTHOR_COVER_NUM 0 1
 .           while \\n[#NUM_ARGS]>\\n[#AUTHOR_COVER_NUM] \{\
 .       ds $AUTHOR_COVER_\\n+[#AUTHOR_COVER_NUM] \\$\\n[#AUTHOR_COVER_NUM]
-.\}
+.           \}
 .       return
 .    \}
 .    nr #AUTHOR_NUM 0 1
@@ -4787,9 +4601,12 @@
 .    while \\n[#NUM_ARGS]>\\n[#AUTHOR_NUM] \{\
 .       ds $AUTHOR_\\n+[#AUTHOR_NUM] \\$\\n[#AUTHOR_NUM]
 .       as $AUTHORS \\*[$AUTHOR_\\n[#AUTHOR_NUM]], \"
-.\}
+.    \}
 .    substring $AUTHORS 0 -3
-.    ds $AUTHOR \\*[$AUTHOR_1]
+.    ds PDF_AUTHORS \\*[$AUTHORS]
+.    pdfmomclean PDF_AUTHORS
+\#.    pdfinfo /Author \\*[PDF_AUTHORS]
+.    nop \!x X ps:exec [/Author (\\*[PDF_AUTHORS]) /DOCINFO pdfmark
 .END
 \#
 .ALIAS EDITOR AUTHOR
@@ -4801,78 +4618,73 @@
 .       rm $COPYRIGHT_COVER
 .    \}
 .    el \{\
-.       if '\\$1'DOC_COVER' \{\
-.          ds $COPYRIGHT_DOCCOVER \[co]\\$2
-.       \}
-.       if '\\$1'COVER' \{\
-.          ds $COPYRIGHT_COVER \[co]\\$2
-.       \}
+.       if '\\$1'DOC_COVER' .ds $COPYRIGHT_DOCCOVER \[co]\\$2
+.       if '\\$1'COVER'     .ds $COPYRIGHT_COVER \[co]\\$2
 .    \}
 .END
 \#
-\#
 .MAC MISC END \"For use on cover pages only; enclose all args in double quotes
 .    ie \\n[#NUM_ARGS]=0 \{\
 .       if \\n[#MISC_NUM] \{\
 .          nr #ITEM 0 1
 .          while \\n[#MISC_NUM]>\\n[#ITEM] \{\
 .             rm $MISC_\\n+[#ITEM]
-.\}
+.          \}
 .          rr #MISC_NUM
 .          rr #NUM_MISCS
 .       \}
-.       if \\n[#MISC_DOCCOVER_NUM] \{\
+.       if \\n[#MISC_DOC_COVER_NUM] \{\
 .          nr #ITEM 0 1
-.          while \\n[#MISC_DOCCOVER_NUM]>\\n[#ITEM] \{\
-.             rm $MISC_DOCCOVER_\\n+[#ITEM]
-.\}
-.          rr #MISC_DOCCOVER_NUM
+.          while \\n[#MISC_DOC_COVER_NUM]>\\n[#ITEM] \{\
+.             rm $MISC_DOC_COVER_\\n+[#ITEM]
+.          \}
+.          rr #MISC_DOC_COVER_NUM
 .          rr #NUM_MISCS
 .       \}
 .       if \\n[#MISC_COVER_NUM] \{\
 .          nr #ITEM 0 1
 .          while \\n[#MISC_COVER_NUM]>\\n[#ITEM] \{\
 .             rm $MISC_COVER_\\n+[#ITEM]
-.\}
+.          \}
 .          rr #MISC_COVER_NUM
 .          rr #NUM_MISCS
 .       \}
 .    \}
 .    el \{\
 .       if !'\\$1'DOC_COVER' \{\
-.         if !'\\$1'COVER' \{ .nr #NEITHER 1 \}
+.         if !'\\$1'COVER' .nr #NEITHER 1
 .       \}
 .       if !'\\$1'COVER' \{\
-.          if !'\\$1'DOC_COVER'\{ .nr #NEITHER 1 \}
+.          if !'\\$1'DOC_COVER' .nr #NEITHER 1
 .       \}
 .       if '\\$1'DOC_COVER' \{\
 .          shift
-.          nr #MISC_DOCCOVER_NUM 0 1
-.          while \\n[#NUM_ARGS]>\\n[#MISC_DOCCOVER_NUM] \{\
-.          ds $MISC_DOCCOVER_\\n+[#MISC_DOCCOVER_NUM] 
\\$\\n[#MISC_DOCCOVER_NUM]
-.\}
+.          nr #MISC_DOC_COVER_NUM 0 1
+.          while \\n[#NUM_ARGS]>\\n[#MISC_DOC_COVER_NUM] \{\
+.             ds $MISC_DOC_COVER_\\n+[#MISC_DOC_COVER_NUM] \
+\\$[\\n[#MISC_DOC_COVER_NUM]]
+.          \}
 .          nr #NUM_MISCS_DOCCOVER \\n[#NUM_ARGS]
 .       \}
 .       if '\\$1'COVER' \{\
 .          shift
 .          nr #MISC_COVER_NUM 0 1
 .          while \\n[#NUM_ARGS]>\\n[#MISC_COVER_NUM] \{\
-.          ds $MISC_COVER_\\n+[#MISC_COVER_NUM] \\$\\n[#MISC_COVER_NUM]
-.\}
+.             ds $MISC_COVER_\\n+[#MISC_COVER_NUM] \\$[\\n[#MISC_COVER_NUM]]
+.          \}
 .          nr #NUM_MISCS_COVER \\n[#NUM_ARGS]
 .       \}
 .       if \\n[#NEITHER]=1 \{\
 .          nr #MISC_NUM 0 1
 .          while \\n[#NUM_ARGS]>\\n[#MISC_NUM] \{\
-.             ds $MISC_\\n+[#MISC_NUM] \\$\\n[#MISC_NUM]
-.\}
+.             ds $MISC_\\n+[#MISC_NUM] \\$[\\n[#MISC_NUM]]
+.          \}
 .          nr #NUM_MISCS \\n[#NUM_ARGS]
 .          rr #NEITHER
 .       \}
 .   \}
 .END
 \#
-\#
 .MAC PAGENUMBER END \"Page # that appears on page one.
 .    nr #n%_AT_PAGENUM_SET \\n%
 .    nr #PAGE_NUM_ADJ \\$1-\\n[#n%_AT_PAGENUM_SET]
@@ -4894,12 +4706,8 @@
 \#   Number registers: DEFAULT=1, CHAPTER=2, NAMED=3, LETTER=4
 \#
 .MAC DOCTYPE END
-.    if '\\$1'DEFAULT' \{\
-.       nr #DOC_TYPE 1
-.    \}
-.    if '\\$1'CHAPTER' \{\
-.       nr #DOC_TYPE 2
-.    \}
+.    if '\\$1'DEFAULT' .nr #DOC_TYPE 1
+.    if '\\$1'CHAPTER' .nr #DOC_TYPE 2
 .    if '\\$1'NAMED' \{\
 .       ds $DOC_TYPE \\$2
 .       nr #DOC_TYPE 3
@@ -4944,18 +4752,15 @@
 \#   LETTERHEAD<n>
 \#
 .MAC DATE END
-.    if !'\\n(.z'' \{ .di \}
+.    if !'\\n[.z]'' .di
 .    di LETTERHEAD\\n+[#FIELD]
 .    ie \\n[#FIELD]=1 \{\
 .       nr #DATE_FIRST 1
 .       RIGHT
 .    \}
-.    el \{\
-.       LEFT
-.    \}
+.    el .LEFT
 .END
 \#
-\#
 \# TO
 \# --
 \# *Arguments:
@@ -4965,12 +4770,11 @@
 \#   diversion LETTERHEAD<n>
 \#
 .MAC TO END
-.    if !'\\n(.z'' \{ .di \}
+.    if !'\\n[.z]'' .di
 .    di LETTERHEAD\\n+[#FIELD]
 .    LEFT
 .END
 \#
-\#
 \# FROM
 \# ----
 \# *Arguments:
@@ -4980,12 +4784,11 @@
 \#   diversion LETTERHEAD<n>
 \#
 .MAC FROM END
-.    if !'\\n(.z'' \{ .di \}
+.    if !'\\n[.z]'' .di
 .    di LETTERHEAD\\n+[#FIELD]
 .    LEFT
 .END
 \#
-\#
 \# GREETING
 \# --------
 \# *Arguments:
@@ -4995,12 +4798,11 @@
 \#   diversion LETTERHEAD<n>
 \#
 .MAC GREETING END
-.    if !'\\n(.z'' \{ .di \}
+.    if !'\\n[.z]'' .di
 .    di LETTERHEAD\\n+[#FIELD]
 .    LEFT
 .END
 \#
-\#
 \# CLOSING
 \# -------
 \# *Arguments:
@@ -5009,9 +4811,17 @@
 \#   Stores greeting in diversion CLOSING.
 \#
 .MAC CLOSING END
+.    if '\\*[$SIG_SPACE]'' .ds $SIG_SPACE 3v
+.    ie ( (2v+\\*[$SIG_SPACE]) > \\n[.t] ) \{\
+.       ch HEADER
+.       ch FOOTER
 .    br
+.       tm1 "[mom]: Insufficient room for \\$0 and signature line.
+.       ab Aborting '\\n[.F]'.
+.    \}
+.    el .br
 .    nr #CLOSING 1
-.    di CLOSING
+.    di CLOSING_TEXT
 .END
 \#
 \# CLOSING INDENT
@@ -5062,173 +4872,264 @@
 \# the macro whose style is to be changed.
 \#
 .MAC _FAMILY END
-.    if '\\$0'AUTHOR_FAMILY'                  .ds $AUTHOR_FAM \\$1
-.    if '\\$0'BIBLIOGRAPHY_FAMILY'            .ds $BIB_FAM \\$1
-.    if '\\$0'BIBLIOGRAPHY_STRING_FAMILY'     .ds $BIB_STRING_FAM \\$1
-.    if '\\$0'BLOCKQUOTE_FAMILY'              .ds $BQUOTE_FAM \\$1
-.    if '\\$0'CITATION_FAMILY'                .ds $BQUOTE_FAM \\$1
-.    if '\\$0'CITE_FAMILY'                    .ds $BQUOTE_FAM \\$1
-.    if '\\$0'CHAPTER_TITLE_FAMILY'           .ds $CHAPTER_TITLE_FAM \\$1
-.    if '\\$0'COVER_AUTHOR_FAMILY'            .ds $COVER_AUTHOR_FAM \\$1
-.    if '\\$0'COVER_CHAPTER_TITLE_FAMILY'     .ds $COVER_CHAPTER_TITLE_FAM \\$1
-.    if '\\$0'COVER_COPYRIGHT_FAMILY'         .ds $COVER_COPYRIGHT_FAM \\$1
-.    if '\\$0'COVER_DOCTYPE_FAMILY'           .ds $COVER_DOCTYPE_FAM \\$1
-.    if '\\$0'COVER_FAMILY'                   .ds $COVER_FAM \\$1
-.    if '\\$0'COVER_MISC_FAMILY'              .ds $COVER_MISC_FAM \\$1
-.    if '\\$0'COVER_SUBTITLE_FAMILY'          .ds $COVER_SUBTITLE_FAM \\$1
-.    if '\\$0'COVER_TITLE_FAMILY'             .ds $COVER_TITLE_FAM \\$1
-.    if '\\$0'DOC_COVER_AUTHOR_FAMILY'        .ds $DOC_COVER_AUTHOR_FAM \\$1
-.    if '\\$0'DOC_COVER_CHAPTER_TITLE_FAMILY' .ds $DOC_COVER_CHAPTER_TITLE_FAM 
\\$1
-.    if '\\$0'DOC_COVER_COPYRIGHT_FAMILY'     .ds $DOC_COVER_COPYRIGHT_FAM \\$1
-.    if '\\$0'DOC_COVER_DOCTYPE_FAMILY'       .ds $DOC_COVER_DOCTYPE_FAM \\$1
-.    if '\\$0'DOC_COVER_FAMILY'               .ds $DOC_COVER_FAM \\$1
-.    if '\\$0'DOC_COVER_MISC_FAMILY'          .ds $DOC_COVER_MISC_FAM \\$1
-.    if '\\$0'DOC_COVER_SUBTITLE_FAMILY'      .ds $DOC_COVER_SUBTITLE_FAM \\$1
-.    if '\\$0'DOC_COVER_TITLE_FAMILY'         .ds $DOC_COVER_TITLE_FAM \\$1
-.    if '\\$0'DOCHEADER_FAMILY'               .ds $DOCHEADER_FAM \\$1
-.    if '\\$0'DOCTYPE_FAMILY'                 .ds $DOCTYPE_FAM \\$1
-.    if '\\$0'ENDNOTE_FAMILY'                 .ds $EN_FAM \\$1
-.    if '\\$0'ENDNOTE_NUMBER_FAMILY'          .ds $EN_NUMBER_FAM \\$1
-.    if '\\$0'ENDNOTE_LINENUMBER_FAMILY'      .ds $EN_LN_FAM \\$1
-.    if '\\$0'ENDNOTE_STRING_FAMILY'          .ds $EN_STRING_FAM \\$1
-.    if '\\$0'ENDNOTE_TITLE_FAMILY'           .ds $EN_TITLE_FAM \\$1
-.    if '\\$0'EPIGRAPH_FAMILY'                .ds $EPI_FAM \\$1
-.    if '\\$0'FOOTNOTE_FAMILY'                .ds $FN_FAM \\$1
-.    if '\\$0'HDRFTR_CENTER_FAMILY'           .ds $HDRFTR_CENTER_FAM \\$1
+.    if '\\$0'AUTHOR_FAMILY' \
+.       ds $AUTHOR_FAM \\$1
+.    if '\\$0'BIBLIOGRAPHY_FAMILY' \
+.       ds $BIB_FAM \\$1
+.    if '\\$0'BIBLIOGRAPHY_STRING_FAMILY' \
+.       ds $BIB_STRING_FAM \\$1
+.    if '\\$0'BLOCKQUOTE_FAMILY' \
+.       ds $BQUOTE_FAM \\$1
+.    if '\\$0'CITATION_FAMILY' \
+.       ds $BQUOTE_FAM \\$1
+.    if '\\$0'CITE_FAMILY' \
+.       ds $BQUOTE_FAM \\$1
+.    if '\\$0'CHAPTER_TITLE_FAMILY' \
+.       ds $CHAPTER_TITLE_FAM \\$1
+.    if '\\$0'COVER_AUTHOR_FAMILY' \
+.       ds $COVER_AUTHOR_FAM \\$1
+.    if '\\$0'COVER_CHAPTER_TITLE_FAMILY' \
+.       ds $COVER_CHAPTER_TITLE_FAM \\$1
+.    if '\\$0'COVER_COPYRIGHT_FAMILY' \
+.       ds $COVER_COPYRIGHT_FAM \\$1
+.    if '\\$0'COVER_DOCTYPE_FAMILY' \
+.       ds $COVER_DOCTYPE_FAM \\$1
+.    if '\\$0'COVER_FAMILY' \
+.       ds $COVER_FAM \\$1
+.    if '\\$0'COVER_MISC_FAMILY' \
+.       ds $COVER_MISC_FAM \\$1
+.    if '\\$0'COVER_SUBTITLE_FAMILY' \
+.       ds $COVER_SUBTITLE_FAM \\$1
+.    if '\\$0'COVER_TITLE_FAMILY' \
+.       ds $COVER_TITLE_FAM \\$1
+.    if '\\$0'DOC_COVER_AUTHOR_FAMILY' \
+.       ds $DOC_COVER_AUTHOR_FAM \\$1
+.    if '\\$0'DOC_COVER_CHAPTER_TITLE_FAMILY' \
+.       ds $DOC_COVER_CHAPTER_TITLE_FAM \\$1
+.    if '\\$0'DOC_COVER_COPYRIGHT_FAMILY' \
+.       ds $DOC_COVER_COPYRIGHT_FAM \\$1
+.    if '\\$0'DOC_COVER_DOCTYPE_FAMILY' \
+.       ds $DOC_COVER_DOCTYPE_FAM \\$1
+.    if '\\$0'DOC_COVER_FAMILY' \
+.       ds $DOC_COVER_FAM \\$1
+.    if '\\$0'DOC_COVER_MISC_FAMILY' \
+.       ds $DOC_COVER_MISC_FAM \\$1
+.    if '\\$0'DOC_COVER_SUBTITLE_FAMILY' \
+.       ds $DOC_COVER_SUBTITLE_FAM \\$1
+.    if '\\$0'DOC_COVER_TITLE_FAMILY' \
+.       ds $DOC_COVER_TITLE_FAM \\$1
+.    if '\\$0'DOCHEADER_FAMILY' \
+.       ds $DOCHEADER_FAM \\$1
+.    if '\\$0'DOCTYPE_FAMILY' \
+.       ds $DOCTYPE_FAM \\$1
+.    if '\\$0'ENDNOTE_FAMILY' \
+.       ds $EN_FAM \\$1
+.    if '\\$0'ENDNOTE_NUMBER_FAMILY' \
+.       ds $EN_NUMBER_FAM \\$1
+.    if '\\$0'ENDNOTE_LINENUMBER_FAMILY' \
+.       ds $EN_LN_FAM \\$1
+.    if '\\$0'ENDNOTE_STRING_FAMILY' \
+.       ds $EN_STRING_FAM \\$1
+.    if '\\$0'ENDNOTE_TITLE_FAMILY' \
+.       ds $EN_TITLE_FAM \\$1
+.    if '\\$0'EPIGRAPH_FAMILY' \
+.       ds $EPI_FAM \\$1
+.    if '\\$0'FOOTNOTE_FAMILY' \
+.       ds $FN_FAM \\$1
+.    if '\\$0'HDRFTR_CENTER_FAMILY' \
+.       ds $HDRFTR_CENTER_FAM \\$1
 .    if '\\$0'HDRFTR_FAMILY' \{\
 .       ds $HDRFTR_FAM        \\$1
 .       ds $HDRFTR_LEFT_FAM   \\$1
 .       ds $HDRFTR_CENTER_FAM \\$1
 .       ds $HDRFTR_RIGHT_FAM  \\$1
 .    \}
-.    if '\\$0'HDRFTR_LEFT_FAMILY'             .ds $HDRFTR_LEFT_FAM \\$1
-.    if '\\$0'HDRFTR_RIGHT_FAMILY'            .ds $HDRFTR_RIGHT_FAM \\$1
-.    if '\\$0'HEAD_FAMILY'                    .ds $HEAD_FAM \\$1
-.    if '\\$0'LINENUMBER_FAMILY'              .ds $LN_FAM \\$1
-.    if '\\$0'PAGENUM_FAMILY'                 .ds $PAGE_NUM_FAM \\$1
-.    if '\\$0'PARAHEAD_FAMILY'                .ds $PH_FAM \\$1
-.    if '\\$0'QUOTE_FAMILY'                   .ds $QUOTE_FAM \\$1
-.    if '\\$0'SUBHEAD_FAMILY'                 .ds $SH_FAM \\$1
-.    if '\\$0'SUBSUBHEAD_FAMILY'              .ds $SSH_FAM \\$1
-.    if '\\$0'SUBTITLE_FAMILY'                .ds $SUBTITLE_FAM \\$1
-.    if '\\$0'TITLE_FAMILY'                   .ds $TITLE_FAM \\$1
-.    if '\\$0'TOC_FAMILY'                     .ds $TOC_FAM \\$1
-.    if '\\$0'TOC_FAM'                        .ds $TOC_FAM \\$1
-.    if '\\$0'TOC_HEADER_FAMILY'              .ds $TOC_HEADER_FAM \\$1
-.    if '\\$0'TOC_HEAD_FAMILY'                .ds $TOC_HEAD_FAM \\$1
-.    if '\\$0'TOC_PARAHEAD_FAMILY'            .ds $TOC_PH_FAM \\$1
-.    if '\\$0'TOC_PN_FAMILY'                  .ds $TOC_PN_FAM \\$1
-.    if '\\$0'TOC_SUBHEAD_FAMILY'             .ds $TOC_SH_FAM \\$1
-.    if '\\$0'TOC_SUBSUBHEAD_FAMILY'          .ds $TOC_SSH_FAM \\$1
-.    if '\\$0'TOC_TITLE_FAMILY'               .ds $TOC_TITLE_FAM \\$1
+.    if '\\$0'HDRFTR_LEFT_FAMILY' \
+.       ds $HDRFTR_LEFT_FAM \\$1
+.    if '\\$0'HDRFTR_RIGHT_FAMILY' \
+.       ds $HDRFTR_RIGHT_FAM \\$1
+.    if '\\$0'LINENUMBER_FAMILY' \
+.       ds $LN_FAM \\$1
+.    if '\\$0'PAGENUM_FAMILY' \
+.       ds $PAGE_NUM_FAM \\$1
+.    if '\\$0'QUOTE_FAMILY' \
+.       ds $QUOTE_FAM \\$1
+.    if '\\$0'SUBTITLE_FAMILY' \
+.       ds $SUBTITLE_FAM \\$1
+.    if '\\$0'TITLE_FAMILY' \
+.       ds $TITLE_FAM \\$1
+.    if '\\$0'TOC_FAMILY' \
+.       ds $TOC_FAM \\$1
+.    if '\\$0'TOC_FAM' \
+.       ds $TOC_FAM \\$1
+.    if '\\$0'TOC_HEADER_FAMILY' \
+.       ds $TOC_HEADER_FAM \\$1
+.    if '\\$0'TOC_PN_FAMILY' \
+.       ds $TOC_PN_FAM \\$1
 .END
 \#
-\#
 .MAC _FONT END
-.    if '\\$0'AUTHOR_FONT'                  .ds $AUTHOR_FT \\$1
-.    if '\\$0'BIBLIOGRAPHY_FONT'            .ds $BIB_FT \\$1
-.    if '\\$0'BIBLIOGRAPHY_STRING_FONT'     .ds $BIB_STRING_FT \\$1
-.    if '\\$0'BLOCKQUOTE_FONT'              .ds $BQUOTE_FT \\$1
-.    if '\\$0'CITATION_FONT'                .ds $BQUOTE_FT \\$1
-.    if '\\$0'CITE_FONT'                    .ds $BQUOTE_FT \\$1
-.    if '\\$0'CHAPTER_TITLE_FONT'           .ds $CHAPTER_TITLE_FT \\$1
-.    if '\\$0'COVER_AUTHOR_FONT'            .ds $COVER_AUTHOR_FT \\$1
-.    if '\\$0'COVER_CHAPTER_TITLE_FONT'     .ds $COVER_CHAPTER_TITLE_FT \\$1
-.    if '\\$0'COVER_COPYRIGHT_FONT'         .ds $COVER_COPYRIGHT_FT \\$1
-.    if '\\$0'COVER_DOCTYPE_FONT'           .ds $COVER_DOCTYPE_FT \\$1
-.    if '\\$0'COVER_MISC_FONT'              .ds $COVER_MISC_FT \\$1
-.    if '\\$0'COVER_SUBTITLE_FONT'          .ds $COVER_SUBTITLE_FT \\$1
-.    if '\\$0'COVER_TITLE_FONT'             .ds $COVER_TITLE_FT \\$1
-.    if '\\$0'DOC_COVER_AUTHOR_FONT'        .ds $DOC_COVER_AUTHOR_FT \\$1
-.    if '\\$0'DOC_COVER_CHAPTER_TITLE_FONT' .ds $DOC_COVER_CHAPTER_TITLE_FT 
\\$1
-.    if '\\$0'DOC_COVER_COPYRIGHT_FONT'     .ds $DOC_COVER_COPYRIGHT_FT \\$1
-.    if '\\$0'DOC_COVER_DOCTYPE_FONT'       .ds $DOC_COVER_DOCTYPE_FT \\$1
-.    if '\\$0'DOC_COVER_MISC_FONT'          .ds $DOC_COVER_MISC_FT \\$1
-.    if '\\$0'DOC_COVER_SUBTITLE_FONT'      .ds $DOC_COVER_SUBTITLE_FT \\$1
-.    if '\\$0'DOC_COVER_TITLE_FONT'         .ds $DOC_COVER_TITLE_FT \\$1
-.    if '\\$0'DOCTYPE_FONT'                 .ds $DOCTYPE_FT \\$1
-.    if '\\$0'ENDNOTE_FONT'                 .ds $EN_FT \\$1
-.    if '\\$0'ENDNOTE_NUMBER_FONT'          .ds $EN_NUMBER_FT \\$1
-.    if '\\$0'ENDNOTE_LINENUMBER_FONT'      .ds $EN_LN_FT \\$1
-.    if '\\$0'ENDNOTE_STRING_FONT'          .ds $EN_STRING_FT \\$1
-.    if '\\$0'ENDNOTE_TITLE_FONT'           .ds $EN_TITLE_FT \\$1
-.    if '\\$0'EPIGRAPH_FONT'                .ds $EPI_FT \\$1
-.    if '\\$0'FOOTNOTE_FONT'                .ds $FN_FT \\$1
-.    if '\\$0'HDRFTR_CENTER_FONT'           .ds $HDRFTR_CENTER_FT \\$1
-.    if '\\$0'HDRFTR_LEFT_FONT'             .ds $HDRFTR_LEFT_FT \\$1
-.    if '\\$0'HDRFTR_RIGHT_FONT'            .ds $HDRFTR_RIGHT_FT \\$1
-.    if '\\$0'HEAD_FONT'                    .ds $HEAD_FT \\$1
-.    if '\\$0'LINENUMBER_FONT'              .ds $LN_FT \\$1
-.    if '\\$0'PAGENUM_FONT'                 .ds $PAGE_NUM_FT \\$1
-.    if '\\$0'PARAHEAD_FONT'                .ds $PH_FT \\$1
-.    if '\\$0'QUOTE_FONT'                   .ds $QUOTE_FT \\$1
-.    if '\\$0'SUBHEAD_FONT'                 .ds $SH_FT \\$1
-.    if '\\$0'SUBSUBHEAD_FONT'              .ds $SSH_FT \\$1
-.    if '\\$0'SUBTITLE_FONT'                .ds $SUBTITLE_FT \\$1
-.    if '\\$0'TITLE_FONT'                   .ds $TITLE_FT \\$1
-.    if '\\$0'TOC_HEADER_FONT'              .ds $TOC_HEADER_FT \\$1
-.    if '\\$0'TOC_HEAD_FONT'                .ds $TOC_HEAD_FT \\$1
-.    if '\\$0'TOC_PARAHEAD_FONT'            .ds $TOC_PH_FT \\$1
-.    if '\\$0'TOC_PN_FONT'                  .ds $TOC_PN_FT \\$1
-.    if '\\$0'TOC_SUBHEAD_FONT'             .ds $TOC_SH_FT \\$1
-.    if '\\$0'TOC_SUBSUBHEAD_FONT'          .ds $TOC_SSH_FT \\$1
-.    if '\\$0'TOC_TITLE_FONT'               .ds $TOC_TITLE_FT \\$1
+.    if '\\$0'AUTHOR_FONT' \
+.       ds $AUTHOR_FT \\$1
+.    if '\\$0'BIBLIOGRAPHY_FONT' \
+.       ds $BIB_FT \\$1
+.    if '\\$0'BIBLIOGRAPHY_STRING_FONT' \
+.       ds $BIB_STRING_FT \\$1
+.    if '\\$0'BLOCKQUOTE_FONT' \
+.       ds $BQUOTE_FT \\$1
+.    if '\\$0'CITATION_FONT' \
+.       ds $BQUOTE_FT \\$1
+.    if '\\$0'CITE_FONT' \
+.       ds $BQUOTE_FT \\$1
+.    if '\\$0'CHAPTER_TITLE_FONT' \
+.       ds $CHAPTER_TITLE_FT \\$1
+.    if '\\$0'COVER_AUTHOR_FONT' \
+.       ds $COVER_AUTHOR_FT \\$1
+.    if '\\$0'COVER_CHAPTER_TITLE_FONT' \
+.       ds $COVER_CHAPTER_TITLE_FT \\$1
+.    if '\\$0'COVER_COPYRIGHT_FONT' \
+.       ds $COVER_COPYRIGHT_FT \\$1
+.    if '\\$0'COVER_DOCTYPE_FONT' \
+.       ds $COVER_DOCTYPE_FT \\$1
+.    if '\\$0'COVER_MISC_FONT' \
+.       ds $COVER_MISC_FT \\$1
+.    if '\\$0'COVER_SUBTITLE_FONT' \
+.       ds $COVER_SUBTITLE_FT \\$1
+.    if '\\$0'COVER_TITLE_FONT' \
+.       ds $COVER_TITLE_FT \\$1
+.    if '\\$0'DOC_COVER_AUTHOR_FONT' \
+.       ds $DOC_COVER_AUTHOR_FT \\$1
+.    if '\\$0'DOC_COVER_CHAPTER_TITLE_FONT' \
+.       ds $DOC_COVER_CHAPTER_TITLE_FT \\$1
+.    if '\\$0'DOC_COVER_COPYRIGHT_FONT' \
+.       ds $DOC_COVER_COPYRIGHT_FT \\$1
+.    if '\\$0'DOC_COVER_DOCTYPE_FONT' \
+.       ds $DOC_COVER_DOCTYPE_FT \\$1
+.    if '\\$0'DOC_COVER_MISC_FONT' \
+.       ds $DOC_COVER_MISC_FT \\$1
+.    if '\\$0'DOC_COVER_SUBTITLE_FONT' \
+.       ds $DOC_COVER_SUBTITLE_FT \\$1
+.    if '\\$0'DOC_COVER_TITLE_FONT' \
+.       ds $DOC_COVER_TITLE_FT \\$1
+.    if '\\$0'DOCTYPE_FONT' \
+.       ds $DOCTYPE_FT \\$1
+.    if '\\$0'ENDNOTE_FONT' \
+.       ds $EN_FT \\$1
+.    if '\\$0'ENDNOTE_NUMBER_FONT' \
+.       ds $EN_NUMBER_FT \\$1
+.    if '\\$0'ENDNOTE_LINENUMBER_FONT' \
+.       ds $EN_LN_FT \\$1
+.    if '\\$0'ENDNOTE_STRING_FONT' \
+.       ds $EN_STRING_FT \\$1
+.    if '\\$0'ENDNOTE_TITLE_FONT' \
+.       ds $EN_TITLE_FT \\$1
+.    if '\\$0'EPIGRAPH_FONT' \
+.       ds $EPI_FT \\$1
+.    if '\\$0'FOOTNOTE_FONT' \
+.       ds $FN_FT \\$1
+.    if '\\$0'HDRFTR_CENTER_FONT' \
+.       ds $HDRFTR_CENTER_FT \\$1
+.    if '\\$0'HDRFTR_LEFT_FONT' \
+.       ds $HDRFTR_LEFT_FT \\$1
+.    if '\\$0'HDRFTR_RIGHT_FONT' \
+.       ds $HDRFTR_RIGHT_FT \\$1
+.    if '\\$0'LINENUMBER_FONT' \
+.       ds $LN_FT \\$1
+.    if '\\$0'PAGENUM_FONT' \
+.       ds $PAGE_NUM_FT \\$1
+.    if '\\$0'QUOTE_FONT' \
+.       ds $QUOTE_FT \\$1
+.    if '\\$0'SUBTITLE_FONT' \
+.       ds $SUBTITLE_FT \\$1
+.    if '\\$0'TITLE_FONT' \
+.       ds $TITLE_FT \\$1
+.    if '\\$0'TOC_HEADER_FONT' \
+.       ds $TOC_HEADER_FT \\$1
+.    if '\\$0'TOC_PN_FONT' \
+.       ds $TOC_PN_FT \\$1
 .END
 \#
-\#
 .MAC _SIZE END
-.    if '\\$0'AUTHOR_SIZE'                  .ds $AUTHOR_SIZE_CHANGE \\$1
-.    if '\\$0'BIBLIOGRAPHY_STRING_SIZE'     .ds $BIB_STRING_SIZE_CHANGE \\$1
-.    if '\\$0'BLOCKQUOTE_SIZE'              .ds $BQUOTE_SIZE_CHANGE \\$1
-.    if '\\$0'CITATION_SIZE'                .ds $BQUOTE_SIZE_CHANGE \\$1
-.    if '\\$0'CITE_SIZE'                    .ds $BQUOTE_SIZE_CHANGE \\$1
-.    if '\\$0'CHAPTER_TITLE_SIZE'           .ds $CHAPTER_TITLE_SIZE_CHANGE \\$1
-.    if '\\$0'COVER_AUTHOR_SIZE'            .ds $COVER_AUTHOR_SIZE_CHANGE \\$1
-.    if '\\$0'COVER_CHAPTER_TITLE_SIZE'     .ds 
$COVER_CHAPTER_TITLE_SIZE_CHANGE \\$1
-.    if '\\$0'COVER_COPYRIGHT_SIZE'         .ds $COVER_COPYRIGHT_SIZE_CHANGE 
\\$1
-.    if '\\$0'COVER_DOCTYPE_SIZE'           .ds $COVER_DOCTYPE_SIZE_CHANGE \\$1
-.    if '\\$0'COVER_MISC_SIZE'              .ds $COVER_MISC_SIZE_CHANGE \\$1
-.    if '\\$0'COVER_SUBTITLE_SIZE'          .ds $COVER_SUBTITLE_SIZE_CHANGE 
\\$1
-.    if '\\$0'COVER_TITLE_SIZE'             .ds $COVER_TITLE_SIZE_CHANGE \\$1
-.    if '\\$0'DOC_COVER_AUTHOR_SIZE'        .ds $DOC_COVER_AUTHOR_SIZE_CHANGE 
\\$1
-.    if '\\$0'DOC_COVER_CHAPTER_TITLE_SIZE' .ds 
$DOC_COVER_CHAPTER_TITLE_SIZE_CHANGE \\$1
-.    if '\\$0'DOC_COVER_COPYRIGHT_SIZE'     .ds 
$DOC_COVER_COPYRIGHT_SIZE_CHANGE \\$1
-.    if '\\$0'DOC_COVER_DOCTYPE_SIZE'       .ds $DOC_COVER_DOCTYPE_SIZE_CHANGE 
\\$1
-.    if '\\$0'DOC_COVER_MISC_SIZE'          .ds $DOC_COVER_MISC_SIZE_CHANGE 
\\$1
-.    if '\\$0'DOC_COVER_SUBTITLE_SIZE'      .ds 
$DOC_COVER_SUBTITLE_SIZE_CHANGE \\$1
-.    if '\\$0'DOC_COVER_TITLE_SIZE'         .ds $DOC_COVER_TITLE_SIZE_CHANGE 
\\$1
-.    if '\\$0'DOCTYPE_SIZE'                 .ds $DOCTYPE_SIZE_CHANGE \\$1
-.    if '\\$0'ENDNOTE_NUMBER_SIZE'          .ds $EN_NUMBER_SIZE_CHANGE \\$1
-.    if '\\$0'ENDNOTE_LINENUMBER_SIZE'      .ds $EN_LN_SIZE_CHANGE \\$1
-.    if '\\$0'ENDNOTE_STRING_SIZE'          .ds $EN_STRING_SIZE_CHANGE \\$1
-.    if '\\$0'ENDNOTE_TITLE_SIZE'           .ds $EN_TITLE_SIZE_CHANGE \\$1
-.    if '\\$0'EPIGRAPH_SIZE'                .ds $EPI_SIZE_CHANGE \\$1
-.    if '\\$0'FOOTNOTE_SIZE'                .ds $FN_SIZE_CHANGE \\$1
-.    if '\\$0'HDRFTR_CENTER_SIZE'           .ds $HDRFTR_CENTER_SIZE_CHANGE \\$1
-.    if '\\$0'HDRFTR_LEFT_SIZE'             .ds $HDRFTR_LEFT_SIZE_CHANGE \\$1
-.    if '\\$0'HDRFTR_RIGHT_SIZE'            .ds $HDRFTR_RIGHT_SIZE_CHANGE \\$1
-.    if '\\$0'HDRFTR_SIZE'                  .ds $HDRFTR_SIZE_CHANGE \\$1
-.    if '\\$0'HEAD_SIZE'                    .ds $HEAD_SIZE_CHANGE \\$1
-.    if '\\$0'LINENUMBER_SIZE'              .ds $LN_SIZE_CHANGE \\$1
-.    if '\\$0'PAGENUM_SIZE'                 .ds $PAGE_NUM_SIZE_CHANGE \\$1
-.    if '\\$0'PARAHEAD_SIZE'                .ds $PH_SIZE_CHANGE \\$1
-.    if '\\$0'QUOTE_SIZE'                   .ds $QUOTE_SIZE_CHANGE \\$1
-.    if '\\$0'SUBHEAD_SIZE'                 .ds $SH_SIZE_CHANGE \\$1
-.    if '\\$0'SUBSUBHEAD_SIZE'              .ds $SSH_SIZE_CHANGE \\$1
-.    if '\\$0'SUBTITLE_SIZE'                .ds $SUBTITLE_SIZE_CHANGE \\$1
-.    if '\\$0'TITLE_SIZE'                   .ds $TITLE_SIZE_CHANGE \\$1
-.    if '\\$0'TOC_HEADER_SIZE'              .ds $TOC_HEADER_SIZE_CHANGE \\$1
-.    if '\\$0'TOC_HEAD_SIZE'                .ds $TOC_HEAD_SIZE_CHANGE \\$1
-.    if '\\$0'TOC_PARAHEAD_SIZE'            .ds $TOC_PH_SIZE_CHANGE \\$1
-.    if '\\$0'TOC_PN_SIZE'                  .ds $TOC_PN_SIZE_CHANGE \\$1
-.    if '\\$0'TOC_SUBHEAD_SIZE'             .ds $TOC_SH_SIZE_CHANGE \\$1
-.    if '\\$0'TOC_SUBSUBHEAD_SIZE'          .ds $TOC_SSH_SIZE_CHANGE \\$1
-.    if '\\$0'TOC_TITLE_SIZE'               .ds $TOC_TITLE_SIZE_CHANGE \\$1
+.    if '\\$0'AUTHOR_SIZE' \
+.       ds $AUTHOR_SIZE_CHANGE \\$1
+.    if '\\$0'BIBLIOGRAPHY_STRING_SIZE' \
+.       ds $BIB_STRING_SIZE_CHANGE \\$1
+.    if '\\$0'BLOCKQUOTE_SIZE' \
+.       ds $BQUOTE_SIZE_CHANGE \\$1
+.    if '\\$0'CITATION_SIZE' \
+.       ds $BQUOTE_SIZE_CHANGE \\$1
+.    if '\\$0'CITE_SIZE' \
+.       ds $BQUOTE_SIZE_CHANGE \\$1
+.    if '\\$0'CHAPTER_TITLE_SIZE' \
+.       ds $CHAPTER_TITLE_SIZE_CHANGE \\$1
+.    if '\\$0'COVER_AUTHOR_SIZE' \
+.       ds $COVER_AUTHOR_SIZE_CHANGE \\$1
+.    if '\\$0'COVER_CHAPTER_TITLE_SIZE' \
+.       ds $COVER_CHAPTER_TITLE_SIZE_CHANGE \\$1
+.    if '\\$0'COVER_COPYRIGHT_SIZE' \
+.       ds $COVER_COPYRIGHT_SIZE_CHANGE \\$1
+.    if '\\$0'COVER_DOCTYPE_SIZE' \
+.       ds $COVER_DOCTYPE_SIZE_CHANGE \\$1
+.    if '\\$0'COVER_MISC_SIZE' \
+.       ds $COVER_MISC_SIZE_CHANGE \\$1
+.    if '\\$0'COVER_SUBTITLE_SIZE' \
+.       ds $COVER_SUBTITLE_SIZE_CHANGE \\$1
+.    if '\\$0'COVER_TITLE_SIZE' \
+.       ds $COVER_TITLE_SIZE_CHANGE \\$1
+.    if '\\$0'DOC_COVER_AUTHOR_SIZE' \
+.       ds $DOC_COVER_AUTHOR_SIZE_CHANGE \\$1
+.    if '\\$0'DOC_COVER_CHAPTER_TITLE_SIZE' \
+.       ds $DOC_COVER_CHAPTER_TITLE_SIZE_CHANGE \\$1
+.    if '\\$0'DOC_COVER_COPYRIGHT_SIZE' \
+.       ds $DOC_COVER_COPYRIGHT_SIZE_CHANGE \\$1
+.    if '\\$0'DOC_COVER_DOCTYPE_SIZE' \
+.       ds $DOC_COVER_DOCTYPE_SIZE_CHANGE \\$1
+.    if '\\$0'DOC_COVER_MISC_SIZE' \
+.       ds $DOC_COVER_MISC_SIZE_CHANGE \\$1
+.    if '\\$0'DOC_COVER_SUBTITLE_SIZE' \
+.       ds $DOC_COVER_SUBTITLE_SIZE_CHANGE \\$1
+.    if '\\$0'DOC_COVER_TITLE_SIZE' \
+.       ds $DOC_COVER_TITLE_SIZE_CHANGE \\$1
+.    if '\\$0'DOCTYPE_SIZE' \
+.       ds $DOCTYPE_SIZE_CHANGE \\$1
+.    if '\\$0'ENDNOTE_NUMBER_SIZE' \
+.       ds $EN_NUMBER_SIZE_CHANGE \\$1
+.    if '\\$0'ENDNOTE_LINENUMBER_SIZE' \
+.       ds $EN_LN_SIZE_CHANGE \\$1
+.    if '\\$0'ENDNOTE_STRING_SIZE' \
+.       ds $EN_STRING_SIZE_CHANGE \\$1
+.    if '\\$0'ENDNOTE_TITLE_SIZE' \
+.       ds $EN_TITLE_SIZE_CHANGE \\$1
+.    if '\\$0'EPIGRAPH_SIZE' \
+.       ds $EPI_SIZE_CHANGE \\$1
+.    if '\\$0'FOOTNOTE_SIZE' \
+.       ds $FN_SIZE_CHANGE \\$1
+.    if '\\$0'HDRFTR_CENTER_SIZE' \
+.       ds $HDRFTR_CENTER_SIZE_CHANGE \\$1
+.    if '\\$0'HDRFTR_LEFT_SIZE' \
+.       ds $HDRFTR_LEFT_SIZE_CHANGE \\$1
+.    if '\\$0'HDRFTR_RIGHT_SIZE' \
+.       ds $HDRFTR_RIGHT_SIZE_CHANGE \\$1
+.    if '\\$0'HDRFTR_SIZE' \
+.       ds $HDRFTR_SIZE_CHANGE \\$1
+.    if '\\$0'LINENUMBER_SIZE' \
+.       ds $LN_SIZE_CHANGE \\$1
+.    if '\\$0'PAGENUM_SIZE' \
+.       ds $PAGE_NUM_SIZE_CHANGE \\$1
+.    if '\\$0'QUOTE_SIZE' \
+.       ds $QUOTE_SIZE_CHANGE \\$1
+.    if '\\$0'SUBTITLE_SIZE' \
+.       ds $SUBTITLE_SIZE_CHANGE \\$1
+.    if '\\$0'TITLE_SIZE' \
+.       ds $TITLE_SIZE_CHANGE \\$1
+.    if '\\$0'TOC_HEADER_SIZE' \
+.       ds $TOC_HEADER_SIZE_CHANGE \\$1
+.    if '\\$0'TOC_PN_SIZE' \
+.       ds $TOC_PN_SIZE_CHANGE \\$1
 .END
 \#
-\#
 .MAC _COLOR END
-.    if \\n[#PRINT_STYLE]=1 \{ .return \}
+.    if \\n[#PRINT_STYLE]=1 .return
 .    if '\\$0'ATTRIBUTE_COLOR' \{\
 .       nr #ATTRIBUTE_COLOR 1
 .       ds $ATTRIBUTE_COLOR \\$1
@@ -5373,10 +5274,6 @@
 .       nr #HDRFTR_RULE_COLOR 1
 .       ds $HDRFTR_RULE_COLOR \\$1
 .    \}
-.    if '\\$0'HEAD_COLOR' \{\
-.       nr #HEAD_COLOR 1
-.       ds $HEAD_COLOR \\$1
-.    \}
 .    if '\\$0'LINEBREAK_COLOR' \{\
 .       nr #LINEBREAK_COLOR 1
 .       ds $LINEBREAK_COLOR \\$1
@@ -5389,10 +5286,6 @@
 .       nr #PAGE_NUM_COLOR 1
 .       ds $PAGENUM_COLOR \\$1
 .    \}
-.    if '\\$0'PARAHEAD_COLOR' \{\
-.       nr #PH_COLOR 1
-.       ds $PH_COLOR \\$1
-.    \}
 .    if '\\$0'QUOTE_COLOR' \{\
 .       nr #QUOTE_COLOR 1
 .       ds $QUOTE_COLOR \\$1
@@ -5401,14 +5294,6 @@
 .       nr #LINEBREAK_COLOR 1
 .       ds $LINEBREAK_COLOR \\$1
 .    \}
-.    if '\\$0'SUBHEAD_COLOR' \{\
-.       nr #SH_COLOR 1
-.       ds $SH_COLOR \\$1
-.    \}
-.    if '\\$0'SUBSUBHEAD_COLOR' \{\
-.       nr #SSH_COLOR 1
-.       ds $SSH_COLOR \\$1
-.    \}
 .    if '\\$0'SUBTITLE_COLOR' \{\
 .       nr #SUBTITLE_COLOR 1
 .       ds $SUBTITLE_COLOR \\$1
@@ -5419,44 +5304,59 @@
 .    \}
 .END
 \#
-\#
 .MAC _QUAD END
 .    if '\\$0'BIBLIOGRAPHY_QUAD' \{\
 .       ds $BIB_QUAD \\$1
-.       if '\\*[$BIB_QUAD]'R' .ab Fatal error: \\$0 must be set to either L or 
J
-.       if '\\*[$BIB_QUAD]'C' .ab Fatal error: \\$0 must be set to either L or 
J
-.    \}
-.    if '\\$0'BIBLIOGRAPHY_STRING_QUAD' .ds $BIB_STRING_QUAD \\$1
-.    if '\\$0'BLOCKQUOTE_QUAD'          .ds $BQUOTE_QUAD \\$1
-.    if '\\$0'CITATION_QUAD'            .ds $BQUOTE_QUAD \\$1
-.    if '\\$0'CITE_QUAD'                .ds $BQUOTE_QUAD \\$1
-.    if '\\$0'COVER_COPYRIGHT_QUAD'     .ds $COVER_COPYRIGHT_QUAD \\$1
-.    if '\\$0'COVER_MISC_QUAD'          .ds $COVER_MISC_QUAD \\$1
-.    if '\\$0'COVER_QUAD'               .ds $COVER_QUAD \\$1
-.    if '\\$0'DOC_COVER_COPYRIGHT_QUAD' .ds $DOC_COVER_COPYRIGHT_QUAD \\$1
-.    if '\\$0'DOC_COVER_MISC_QUAD'      .ds $DOC_COVER_MISC_QUAD \\$1
-.    if '\\$0'DOC_COVER_QUAD'           .ds $DOC_COVER_QUAD \\$1
-.    if '\\$0'DOCHEADER_QUAD'           .ds $DOCHEADER_QUAD \\$1
+.       if '\\*[$BIB_QUAD]'R' \
+.ab \\$0 at line \\n[.c] must be set to either L or J.  Aborting \\n'[.F]'.
+.       if '\\*[$BIB_QUAD]'C' \
+.ab \\$0 at line \\n[.c] must be set to either L or J.  Aborting \\n'[.F]'.
+.    \}
+.    if '\\$0'BIBLIOGRAPHY_STRING_QUAD' \
+.       ds $BIB_STRING_QUAD \\$1
+.    if '\\$0'BLOCKQUOTE_QUAD' \
+.       ds $BQUOTE_QUAD \\$1
+.    if '\\$0'CITATION_QUAD' \
+.       ds $BQUOTE_QUAD \\$1
+.    if '\\$0'CITE_QUAD' \
+.       ds $BQUOTE_QUAD \\$1
+.    if '\\$0'COVER_COPYRIGHT_QUAD' \
+.       ds $COVER_COPYRIGHT_QUAD \\$1
+.    if '\\$0'COVER_MISC_QUAD' \
+.       ds $COVER_MISC_QUAD \\$1
+.    if '\\$0'COVER_QUAD' \
+.       ds $COVER_QUAD \\$1
+.    if '\\$0'DOC_COVER_COPYRIGHT_QUAD' \
+.       ds $DOC_COVER_COPYRIGHT_QUAD \\$1
+.    if '\\$0'DOC_COVER_MISC_QUAD' \
+.       ds $DOC_COVER_MISC_QUAD \\$1
+.    if '\\$0'DOC_COVER_QUAD' \
+.       ds $DOC_COVER_QUAD \\$1
+.    if '\\$0'DOCHEADER_QUAD' \
+.       ds $DOCHEADER_QUAD \\$1
 .    if '\\$0'DOC_QUAD' \{\
 .        ds $DOC_QUAD \\$1
 .        QUAD \\*[$DOC_QUAD]
 .    \}
 .    if '\\$0'ENDNOTE_QUAD' \{\
 .       ds $EN_QUAD \\$1
-.       if '\\*[$EN_QUAD]'R' .ab Fatal error: \\$0 must be set to either L or J
-.       if '\\*[$EN_QUAD]'C' .ab Fatal error: \\$0 must be set to either L or J
-.    \}
-.    if '\\$0'ENDNOTE_STRING_QUAD'      .ds $EN_STRING_QUAD \\$1
-.    if '\\$0'ENDNOTE_TITLE_QUAD'       .ds $EN_TITLE_QUAD \\$1
-.    if '\\$0'EPIGRAPH_QUAD'            .ds $EPI_QUAD \\$1
-.    if '\\$0'FOOTNOTE_QUAD'            .ds $FN_QUAD \\$1
-.    if '\\$0'SUBSUBHEAD_QUAD'          .ds $SSH_QUAD \\$1
-.    if '\\$0'HEAD_QUAD'                .ds $HEAD_QUAD \\$1
-.    if '\\$0'SUBHEAD_QUAD'             .ds $SH_QUAD \\$1
-.    if '\\$0'TOC_HEADER_QUAD'          .ds $TOC_HEADER_QUAD \\$1
+.       if '\\*[$EN_QUAD]'R' \
+.ab \\$0 at line \\n[.c] must be set to either L or J.  Aborting \\n'[.F]'.
+.       if '\\*[$EN_QUAD]'C' \
+.ab \\$0 at line \\n[.c] must be set to either L or J.  Aborting \\n'[.F]'.
+.    \}
+.    if '\\$0'ENDNOTE_STRING_QUAD' \
+.       ds $EN_STRING_QUAD \\$1
+.    if '\\$0'ENDNOTE_TITLE_QUAD' \
+.       ds $EN_TITLE_QUAD \\$1
+.    if '\\$0'EPIGRAPH_QUAD' \
+.       ds $EPI_QUAD \\$1
+.    if '\\$0'FOOTNOTE_QUAD' \
+.       ds $FN_QUAD \\$1
+.    if '\\$0'TOC_HEADER_QUAD' \
+.       ds $TOC_HEADER_QUAD \\$1
 .END
 \#
-\#
 \# DEFAULTS
 \# --------
 \# *Arguments:
@@ -5468,179 +5368,176 @@
 \#   $REVISION_STRING are in the COPYSTYLE macro.
 \#
 .MAC DEFAULTS END
-.    if !d$PAPER \{ .PAPER LETTER \}
-.    if !\\n[#DOC_TYPE]   \{ .DOCTYPE DEFAULT \}
-.    ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] \}
+.    if !d $PAPER .PAPER LETTER
+.    if !\\n[#DOC_TYPE] .DOCTYPE DEFAULT
+.    ie \\n[#PAGENUM_STYLE_SET] .PAGENUM_STYLE \\*[$PAGENUM_STYLE]
 .    el \{\
-.       if !\\n[#COPY_STYLE]=1 \{ .PAGENUM_STYLE DIGIT \}
+.       if !\\n[#COPY_STYLE]=1 .PAGENUM_STYLE DIGIT
 .    \}
-.    if !\\n[#COPY_STYLE] \{ .COPYSTYLE FINAL \}
-.    if \\n[#DRAFT_WITH_PAGENUM] \{ .COPYSTYLE \\*[$COPY_STYLE] \}
+.    if !\\n[#COPY_STYLE] .COPYSTYLE FINAL
+.    if \\n[#DRAFT_WITH_PAGENUM] .COPYSTYLE \\*[$COPY_STYLE]
 .    if \\n[#DOC_TYPE]=4 \{\
 .       if !\\n[#USER_SET_L_LENGTH] \{\
 .          R_MARGIN \\n[#R_MARGIN]u
 .          rr #USER_SET_L_LENGTH
 .       \}
-.       if \\n[#PRINT_STYLE]=1 \{ .PRINTSTYLE TYPEWRITE SINGLESPACE \}
+.       if \\n[#PRINT_STYLE]=1 .PRINTSTYLE TYPEWRITE SINGLESPACE
 .    \}
 .    if \\n[#COPY_STYLE]=1 \{\
 .       COPYSTYLE DRAFT
 .       PAGENUMBER 1
 .    \}
-.    if !r#DOC_HEADER \{ .DOCHEADER  \}
-.    if !r#HEADERS_ON \{ .HEADERS    \}
-.    if !r#PAGINATE   \{ .PAGINATE   \}
+.    if !r #DOC_HEADER .DOCHEADER
+.    if !r #HEADERS_ON .HEADERS
+.    if !r #PAGINATE   .PAGINATE
 .    if \\n[#FOOTERS_ON] \{\
 .       HEADERS OFF
-.       if \\n[#PAGE_NUM_POS_SET]=0 \{ .PAGENUM_POS TOP CENTER \}
+.       if \\n[#PAGE_NUM_POS_SET]=0 .PAGENUM_POS TOP CENTER
 .    \}
-.    if !r#HEADER_MARGIN \{ .HEADER_MARGIN 4P+6p \}
-.    if !r#HEADER_GAP    \{ .HEADER_GAP    3P    \}
+.    if !r #HEADER_MARGIN .HEADER_MARGIN 4P+6p
+.    if !r #HEADER_GAP    .HEADER_GAP 3P
 .    if \\n[#FOOTERS_ON] \{\
-.       if \\n[#PAGINATE]=0 \{\
-.          if !r#T_MARGIN \{ .T_MARGIN 6P \}
+.       if \\n![#PAGINATE] \{\
+.          if !\\n[#T_MARGIN] .T_MARGIN 6P
 .       \}
 .    \}
-.    if \\n[#HEADERS_ON]=0    \{\
-.       if \\n[#FOOTERS_ON]=0 \{\
-.          if !r#T_MARGIN \{ .T_MARGIN 6P \}
+.    if !\\n[#HEADERS_ON] \{\
+.       if !\\n[#FOOTERS_ON] \{\
+.          if !r #T_MARGIN .T_MARGIN 6P
 .       \}
 .    \}
-.    if !r#T_MARGIN          \{ .T_MARGIN \\n[#HEADER_MARGIN]+\\n[#HEADER_GAP] 
\}
-.    if !r#DOCHEADER_ADVANCE \{ .nr #DOCHEADER_ADVANCE \\n[#T_MARGIN] \}
-.    if !r#FOOTER_MARGIN     \{ .FOOTER_MARGIN 3P \}
-.    if !r#FOOTER_GAP        \{ .FOOTER_GAP    3P \}
-.    if !r#B_MARGIN          \{ .B_MARGIN 
\\n[#FOOTER_MARGIN]u+\\n[#FOOTER_GAP]u \}
-.    if (\\n[#FOOTER_MARGIN]+\\n[.v]>=\\n[#B_MARGIN] \{\
+.    if !r #T_MARGIN          .T_MARGIN \\n[#HEADER_MARGIN]+\\n[#HEADER_GAP]
+.    if !r #DOCHEADER_ADVANCE .nr #DOCHEADER_ADVANCE \\n[#T_MARGIN]
+.    if !r #FOOTER_MARGIN     .FOOTER_MARGIN 3P
+.    if !r #FOOTER_GAP        .FOOTER_GAP 3P
+.    if !r #B_MARGIN          .B_MARGIN \\n[#FOOTER_MARGIN]u+\\n[#FOOTER_GAP]u
+.    if (\\n[#FOOTER_MARGIN]+\\n[.v]>=\\n[#B_MARGIN]) \{\
 .       tm1 "[mom]: Your chosen bottom margin for running text is too close to 
the footer margin.
 .       tm1 "       No footers or bottom-of-page page numbers will be printed.
 .       tm1 "       Please reset B_MARGIN or FOOTER_MARGIN to allow enough 
space.
 .       tm1 "       If no footers or bottom-of-page page numbers are required,
-.       tm1 "       type in .FOOTER_MARGIN 0 before .START
+.       tm1 "       invoke .FOOTER_MARGIN 0 before .START
 .    \}
-.    if !r#HEADER_RULE_GAP   \{ .HEADER_RULE_GAP 4p \}
-.    if !r#FOOTER_RULE_GAP   \{ .FOOTER_RULE_GAP 4p \}
-.    if !r#HDRFTR_RULE       \{ .HDRFTR_RULE        \}
-.    if !r#PAGE_NUM_SET      \{ .PAGENUMBER 1       \}
+.    if !r #HEADER_RULE_GAP .HEADER_RULE_GAP 4p
+.    if !r #FOOTER_RULE_GAP .FOOTER_RULE_GAP 4p
+.    if !r #HDRFTR_RULE     .HDRFTR_RULE
+.    if !r #PAGE_NUM_SET    .PAGENUMBER 1
 .\" Read in number registers and strings for type parameters
 .    nr #DOC_L_MARGIN \\n[#L_MARGIN]
 .    nr #DOC_L_LENGTH \\n[#L_LENGTH]
 .    nr #DOC_R_MARGIN \\n[#PAGE_WIDTH]-(\\n[#DOC_L_MARGIN]+\\n[#L_LENGTH])
 .    ds $DOC_FAM      \\*[$FAMILY]
 .    nr #DOC_PT_SIZE  \\n[#PT_SIZE]
+.\"
+.    if \\n[#TOC]          .nr #DOC_PT_SIZE \\n[#TOC_PS]
+.    if \\n[#ENDNOTES]     .nr #DOC_PT_SIZE \\n[#EN_PS]
+.    if \\n[#BIBLIOGRAPHY] .nr #DOC_PT_SIZE \\n[#BIB_PS]
+.\"
 .    nr #DOC_LEAD     \\n[#LEAD]
+.    nr address@hidden     \\n[#DOC_LEAD]
 .\" #SAVED_DOC_LEAD is set in COLLATE
-.    if r#SAVED_DOC_LEAD \{\
-.       if !\\n[#DOC_LEAD]=\\n[#SAVED_DOC_LEAD] \{ .nr #RERUN_TRAPS 1 \}
+.    if \\n[#SAVED_DOC_LEAD] \{\
+.       if !\\n[#TOC] \{\
+.          if !\\n[#DOC_LEAD]=\\n[#SAVED_DOC_LEAD] .nr #RERUN_TRAPS 1
 .    \}
-.    ie \\n[#ADJ_DOC_LEAD]=1 \{ . \}
-.    el \{\
-.       if !\\n[#DOC_LEAD_ADJUST_OFF] \{\
-.          DOC_LEAD_ADJUST
 .       \}
+.    ie \\n[#ADJ_DOC_LEAD]=1 .
+.    el \{\
+.       if !\\n[#DOC_LEAD_ADJUST_OFF] .DOC_LEAD_ADJUST
 .    \}
 .    ds $DOC_QUAD      \\*[$QUAD_VALUE]
-.    if '\\*[$FONT]''  \{ .FT R \}
-.    if '\\*[$PP_FT]'' \{\
-.       ds $PP_FT \\*[$FONT]
-.    \}
-.    if !'\\*[$PP_FT]'' \{\
-.       ds $PP_FT \\*[$FONT]
-.    \}
+.    if '\\*[$FONT]''   .FT R
+.    if '\\*[$PP_FT]''  .ds $PP_FT \\*[$FONT]
+.    if !'\\*[$PP_FT]'' .ds $PP_FT \\*[$FONT]
 .\" Counters
 .    nr #PP 0
 .    nr #FN_NUMBER 0 1
 .    nr #EN_NUMBER 0 1
 .    nr #FN_COUNT_FOR_COLS 0 1
 .    nr #DONE_ONCE 0 1
-.    RESET_HEAD_NUMBER
-.    RESET_SUBHEAD_NUMBER
-.    RESET_SUBSUBHEAD_NUMBER
-.    RESET_PARAHEAD_NUMBER
+.\" Enable shimming if user hasn't turned it off
+.    if \\n[#NO_SHIM]=2    .rr #NO_SHIM
 .\" General style defaults for both PRINTSTYLEs
 .    nr #PP_STYLE 1
 .    PARA_INDENT \\n[#PP_INDENT]u
-.    if !d$HDRFTR_FAM           \{ .HDRFTR_FAMILY  \\*[$DOC_FAM] \}
-.    if !d$HDRFTR_SIZE_CHANGE   \{ .HDRFTR_SIZE    +0            \}
-.    if !d$PAGE_NUM_FAM         \{ .PAGENUM_FAMILY \\*[$DOC_FAM] \}
-.    if !d$PAGE_NUM_FT          \{ .PAGENUM_FONT   R             \}
-.    if !d$PAGE_NUM_SIZE_CHANGE \{ .PAGENUM_SIZE   +0            \}
-.    if !r#PAGE_NUM_POS_SET     \{ .PAGENUM_POS BOTTOM CENTER    \}
+.    if !d $HDRFTR_FAM               .HDRFTR_FAMILY \\*[$DOC_FAM]
+.    if !d $HDRFTR_SIZE_CHANGE       .HDRFTR_SIZE +0
+.    if !d $PAGE_NUM_FAM             .PAGENUM_FAMILY \\*[$DOC_FAM]
+.    if !d $PAGE_NUM_FT              .PAGENUM_FONT R
+.    if !d $PAGE_NUM_SIZE_CHANGE     .PAGENUM_SIZE +0
+.    if !r #PAGE_NUM_POS_SET         .PAGENUM_POS BOTTOM CENTER
 .    ie \\n[#PAGE_NUM_HYPHENS_SET] \{\
-.       if \\n[#PAGE_NUM_HYPHENS]=0  \{ .PAGENUM_HYPHENS OFF \}
-.       if \\n[#PAGE_NUM_HYPHENS]=1  \{ .PAGENUM_HYPHENS     \}
+.       if \\n[#PAGE_NUM_HYPHENS]=0  .PAGENUM_HYPHENS OFF
+.       if \\n[#PAGE_NUM_HYPHENS]=1  .PAGENUM_HYPHENS
 .    \}
-.    el \{ .PAGENUM_HYPHENS \}
-.    if !d$HEAD_QUAD         \{ .HEAD_QUAD CENTER  \}
-.    if !r#HEAD_CAPS         \{ .HEAD_CAPS         \}
-.    if !r#HEAD_UNDERLINE    \{ .HEAD_UNDERLINE    \}
-.    if !d$SH_QUAD           \{ .SUBHEAD_QUAD LEFT \}
-.    if !d$SSH_QUAD          \{ .SUBSUBHEAD_QUAD LEFT \}
-.    if !r#HDRFTR_RIGHT_CAPS \{ .HDRFTR_RIGHT_CAPS \}
+.    el .PAGENUM_HYPHENS
+.    if !\\n[#HDRFTR_RIGHT_CAPS] .HDRFTR_RIGHT_CAPS
 .    if \\n[#HDRFTR_RIGHT_CAPS]=0 \{\
-.       if !d$HDRFTR_RIGHT_SIZE_CHANGE \{ .HDRFTR_RIGHT_SIZE +0 \}
+.       if !d $HDRFTR_RIGHT_SIZE_CHANGE .HDRFTR_RIGHT_SIZE +0
 .    \}
-.    if !d$FN_FAM                 \{ .FOOTNOTE_FAMILY \\*[$DOC_FAM]   \}
-.    if !d$FN_FT                  \{ .FOOTNOTE_FONT R                 \}
-.    if !d$FN_QUAD                \{ .FOOTNOTE_QUAD \\*[$DOC_QUAD]    \}
-.    if !r#FN_RULE                \{ .FOOTNOTE_RULE                   \}
-.    if !r#FN_MARKERS             \{ .FOOTNOTE_MARKERS                \}
+.    if !d $FN_FAM        .FOOTNOTE_FAMILY \\*[$DOC_FAM]
+.    if !d $FN_FT         .FOOTNOTE_FONT R
+.    if !d $FN_QUAD       .FOOTNOTE_QUAD \\*[$DOC_QUAD]
+.    if !r #FN_RULE       .FOOTNOTE_RULE
+.    if !r #FN_MARKERS    .FOOTNOTE_MARKERS
 .    if \\n[#FN_MARKERS]=1 \{\
 .       if \\n[#FN_REF]=1 \{\
-.          if !\\n[#FN_MARKER_STYLE] \{ .FOOTNOTE_MARKER_STYLE NUMBER \}
+.          if !\\n[#FN_MARKER_STYLE] .FOOTNOTE_MARKER_STYLE NUMBER
 .       \}
-.       if !\\n[#FN_MARKER_STYLE] \{ .FOOTNOTE_MARKER_STYLE STAR      \}
+.       if !\\n[#FN_MARKER_STYLE] .FOOTNOTE_MARKER_STYLE STAR
 .    \}
-.    if !r#EN_MARKER_STYLE      \{ .ENDNOTE_MARKER_STYLE SUPERSCRIPT   \}
-.    if !d$EN_PN_STYLE          \{ .ENDNOTES_PAGENUM_STYLE digit       \}
-.    if !d$EN_FAM               \{ .ENDNOTE_FAMILY \\*[$DOC_FAM]       \}
-.    if !d$EN_FT                \{ .ENDNOTE_FONT R                     \}
-.    if !d$EN_QUAD              \{ .ENDNOTE_QUAD \\*[$DOC_QUAD]        \}
-.    if !d$EN_STRING            \{ .ENDNOTE_STRING "Endnotes"          \}
-.    if !d$EN_STRING_FAM        \{ .ENDNOTE_STRING_FAMILY \\*[$EN_FAM] \}
-.    if !d$EN_STRING_QUAD       \{ .ENDNOTE_STRING_QUAD CENTER         \}
-.    if !r#EN_STRING_UNDERLINE  \{ .nr #EN_STRING_UNDERLINE 2          \}
-.    if !r#EN_STRING_CAPS       \{ .ENDNOTE_STRING_CAPS                \}
-.    if !d$EN_TITLE \{\
+.    if !r #EN_MARKER_STYLE     .ENDNOTE_MARKER_STYLE SUPERSCRIPT
+.    if !d $EN_PN_STYLE         .ENDNOTES_PAGENUM_STYLE digit
+.    if !d $EN_FAM              .ENDNOTE_FAMILY \\*[$DOC_FAM]
+.    if !d $EN_FT               .ENDNOTE_FONT R
+.    if !d $EN_QUAD             .ENDNOTE_QUAD \\*[$DOC_QUAD]
+.    if !d $EN_STRING           .ENDNOTE_STRING "Endnotes"
+.    if !d $EN_STRING_FAM       .ENDNOTE_STRING_FAMILY \\*[$EN_FAM]
+.    if !d $EN_STRING_QUAD      .ENDNOTE_STRING_QUAD CENTER
+.    if !r #EN_STRING_UNDERLINE .nr #EN_STRING_UNDERLINE 2
+.    if !r #EN_STRING_CAPS      .ENDNOTE_STRING_CAPS
+.    if !d $EN_TITLE \{\
 .       ie \\n[#DOC_TYPE]=2 \{\
 .          ie !'\\*[$CHAPTER_TITLE_1]'' \{\
-.             ie '\\*[$CHAPTER]'' \{ .ENDNOTE_TITLE "\\*[$CHAPTER_TITLE]" \}
-.             el \{ .ENDNOTE_TITLE "\\*[$CHAPTER_STRING] \\*[$CHAPTER]: 
\\*[$CHAPTER_TITLE]" \}
-.          \}
-.             el \{\
-.                ie '\\*[$CHAPTER]'' \{ .ENDNOTE_TITLE "\\*[$CHAPTER_STRING]" 
\}
-.                el \{ .ENDNOTE_TITLE "\\*[$CHAPTER_STRING] \\*[$CHAPTER]"    
\}
-.             \}
-.          \}
-.       el \{ .ENDNOTE_TITLE "\\*[$TITLE]" \}
-.    \}
-.    if !d$EN_TITLE_FAM          \{ .ENDNOTE_TITLE_FAMILY \\*[$EN_FAM]        
\}
-.    if !d$EN_TITLE_QUAD         \{ .ENDNOTE_TITLE_QUAD LEFT                  
\}
-.    if !r#EN_TITLE_UNDERLINE    \{ .nr #EN_TITLE_UNDERLINE 1                 
\}
-.    if !d$EN_NUMBER_FAM         \{ .ENDNOTE_NUMBER_FAMILY \\*[$EN_FAM]       
\}
-.    if !d$EN_LN_FAM             \{ .ENDNOTE_LINENUMBER_FAMILY \\*[$EN_FAM]   
\}
-.    if !r#EN_NUMBERS_ALIGN_LEFT \{\
-.       if !r#EN_NUMBERS_ALIGN_RIGHT \{\
-.          ie !\\n[#EN_MARKER_STYLE]=2  \{ .ENDNOTE_NUMBERS_ALIGN RIGHT 2 \}
-.          el \{ .ENDNOTE_NUMBERS_ALIGN RIGHT 4 \}
-.       \}
-.    \}
-.    if !r#EN_LN_GAP             \{ .ENDNOTE_LINENUMBER_GAP 1n                
\}
-.    if !r#EN_ALLOWS_HEADERS     \{ .ENDNOTES_ALLOWS_HEADERS                  
\}
-.    if !d$BIB_PN_STYLE          \{ .BIBLIOGRAPHY_PAGENUM_STYLE digit         
\}
-.    if !d$BIB_FAM               \{ .BIBLIOGRAPHY_FAMILY \\*[$DOC_FAM]        
\}
-.    if !d$BIB_FT                \{ .BIBLIOGRAPHY_FONT R                      
\}
-.    if !d$BIB_QUAD              \{ .BIBLIOGRAPHY_QUAD \\*[$DOC_QUAD]         
\}
-.    if !d$BIB_STRING            \{ .BIBLIOGRAPHY_STRING "Bibliography"       
\}
-.    if !d$BIB_STRING_FAM        \{ .BIBLIOGRAPHY_STRING_FAMILY \\*[$BIB_FAM] 
\}
-.    if !d$BIB_STRING_QUAD       \{ .BIBLIOGRAPHY_STRING_QUAD CENTER          
\}
-.    if !r#BIB_STRING_UNDERLINE  \{ .nr #BIB_STRING_UNDERLINE 2               
\}
-.    if !r#BIB_STRING_CAPS       \{ .BIBLIOGRAPHY_STRING_CAPS                 
\}
-.    if !d$TOC_HEADER_STRING     \{ .TOC_HEADER_STRING "Contents"  \}
-.    if !d$TOC_HEADER_QUAD       \{ .TOC_HEADER_QUAD LEFT          \}
-.    if !d$TOC_PN_STYLE          \{ .TOC_PAGENUM_STYLE roman       \}
-.    if !r#TOC_PN_PADDING        \{ .TOC_PADDING   3               \}
-.    if !r#TOC_TITLE_INDENT      \{ .TOC_TITLE_INDENT    0         \}
+.             ie '\\*[$CHAPTER]'' .ENDNOTE_TITLE "\\*[$CHAPTER_TITLE]"
+.             el .ENDNOTE_TITLE \
+"\\*[$CHAPTER_STRING] \\*[$CHAPTER]: \\*[$CHAPTER_TITLE]"
+.          \}
+.             el \{\
+.                ie '\\*[$CHAPTER]'' .ENDNOTE_TITLE "\\*[$CHAPTER_STRING]"
+.                el .ENDNOTE_TITLE "\\*[$CHAPTER_STRING] \\*[$CHAPTER]"
+.             \}
+.          \}
+.       el .ENDNOTE_TITLE "\\*[$TITLE]"
+.    \}
+.    if !d $EN_TITLE_FAM          .ENDNOTE_TITLE_FAMILY \\*[$EN_FAM]
+.    if !d $EN_TITLE_QUAD         .ENDNOTE_TITLE_QUAD LEFT
+.    if !r #EN_TITLE_UNDERLINE    .nr #EN_TITLE_UNDERLINE 1
+.    if !d $EN_NUMBER_FAM         .ENDNOTE_NUMBER_FAMILY \\*[$EN_FAM]
+.    if !d $EN_LN_FAM             .ENDNOTE_LINENUMBER_FAMILY \\*[$EN_FAM]
+.    if !r #EN_NUMBERS_ALIGN_LEFT \{\
+.       if !r #EN_NUMBERS_ALIGN_RIGHT \{\
+.          ie !\\n[#EN_MARKER_STYLE]=2 .ENDNOTE_NUMBERS_ALIGN RIGHT 2
+.          el .ENDNOTE_NUMBERS_ALIGN RIGHT 4
+.       \}
+.    \}
+.    if !r #EN_LN_GAP            .ENDNOTE_LINENUMBER_GAP 1m
+.    if !r #EN_ALLOWS_HEADERS    .ENDNOTES_ALLOWS_HEADERS
+.    if !d $BIB_PN_STYLE         .BIBLIOGRAPHY_PAGENUM_STYLE digit
+.    if !d $BIB_FAM              .BIBLIOGRAPHY_FAMILY \\*[$DOC_FAM]
+.    if !d $BIB_FT               .BIBLIOGRAPHY_FONT R
+.    if !d $BIB_QUAD             .BIBLIOGRAPHY_QUAD \\*[$DOC_QUAD]
+.    if !d $BIB_STRING           .BIBLIOGRAPHY_STRING "Bibliography"
+.    if !d $BIB_STRING_FAM       .BIBLIOGRAPHY_STRING_FAMILY \\*[$BIB_FAM]
+.    if !d $BIB_STRING_QUAD      .BIBLIOGRAPHY_STRING_QUAD CENTER
+.    if !r #BIB_STRING_UNDERLINE .nr #BIB_STRING_UNDERLINE 2
+.    if !r #BIB_STRING_CAPS      .BIBLIOGRAPHY_STRING_CAPS
+.    if !d $TOC_HEADER_STRING    .TOC_HEADER_STRING "Contents"
+.    if !d $TOC_HEADER_QUAD      .TOC_HEADER_QUAD LEFT
+.    if !d $TOC_PN_STYLE         .TOC_PAGENUM_STYLE roman
+.    if !r #TOC_PN_PADDING       .TOC_PADDING 3
+.\" PDF link colour
+.    if !\\n[PDFHREF_COLOR_SET] .PDF_LINK_COLOR 0.0 0.3 0.9
 .\" String defaults for both PRINTSTYLEs
 .    ie \\n[#DOC_TYPE]=1 \{\
 .       ie '\\*[$DOC_TITLE]'' \{\
@@ -5648,7 +5545,7 @@
 .          if \\n[#USER_DEF_HDRFTR_RIGHT]=0 .ds $HDRFTR_RIGHT \\*[$TITLE]
 .       \}
 .       el \{\
-.          if \\n[#COPY_STYLE]=1 \{ .DRAFT_WITH_PAGENUMBER \}
+.          if \\n[#COPY_STYLE]=1             .DRAFT_WITH_PAGENUMBER
 .          if \\n[#USER_DEF_HDRFTR_LEFT]=0   .ds $HDRFTR_LEFT \\*[$AUTHOR_1]
 .          if \\n[#USER_DEF_HDRFTR_CENTER]=0 .ds $HDRFTR_CENTER \\*[$TITLE]
 .          if \\n[#USER_DEF_HDRFTR_RIGHT]=0  .ds $HDRFTR_RIGHT \\*[$DOC_TITLE]
@@ -5658,354 +5555,300 @@
 .       if \\n[#USER_DEF_HDRFTR_LEFT]=0  .ds $HDRFTR_LEFT \\*[$AUTHOR_1]
 .       if \\n[#USER_DEF_HDRFTR_RIGHT]=0 .ds $HDRFTR_RIGHT \\*[$TITLE]
 .    \}
-.    if !d$ATTRIBUTE_STRING .ds $ATTRIBUTE_STRING by
-.    if !d$FINIS_STRING      \{ .FINIS_STRING "End"       \}
-.    if !r#FINIS_STRING_CAPS \{ .nr #FINIS_STRING_CAPS 1  \}
+.    if !d $ATTRIBUTE_STRING     .ds $ATTRIBUTE_STRING by
+.    if !d $FINIS_STRING         .FINIS_STRING "End"
+.    if !r #FINIS_STRING_CAPS    .nr #FINIS_STRING_CAPS 1
 .\" Covers
-.    if !r#DOC_COVERS_OFF           \{ .nr #DOC_COVERS 1           \}
-.    if !r#COVERS_OFF               \{ .nr #COVERS 1               \}
-.    if !d$COVER_COPYRIGHT_QUAD     \{ .COVER_COPYRIGHT_QUAD R     \}
-.    if !d$COVER_MISC_QUAD          \{ .COVER_MISC_QUAD L          \}
-.    if !d$DOC_COVER_COPYRIGHT_QUAD \{ .DOC_COVER_COPYRIGHT_QUAD R \}
-.    if !d$DOC_COVER_MISC_QUAD      \{ .DOC_COVER_MISC_QUAD L      \}
-.    if !r#DOCCOVER_UNDERLINE       \{ .DOC_COVER_UNDERLINE        \}
-.    if !r#COVER_UNDERLINE          \{ .COVER_UNDERLINE            \}
+.    if !r #DOC_COVERS_OFF           .nr #DOC_COVERS 1
+.    if !r #COVERS_OFF               .nr #COVERS 1
+.    if !d $COVER_COPYRIGHT_QUAD     .COVER_COPYRIGHT_QUAD R
+.    if !d $COVER_MISC_QUAD          .COVER_MISC_QUAD L
+.    if !d $DOC_COVER_COPYRIGHT_QUAD .DOC_COVER_COPYRIGHT_QUAD R
+.    if !d $DOC_COVER_MISC_QUAD      .DOC_COVER_MISC_QUAD L
+.    if !r #DOC_COVER_UNDERLINE      .DOC_COVER_UNDERLINE
+.    if !r #COVER_UNDERLINE          .COVER_UNDERLINE
 .\" Defaults for printstyle TYPEWRITE
 .    if \\n[#PRINT_STYLE]=1 \{\
 .       SS DEFAULT
-.       if \\n[#UNDERLINE_QUOTES]=1 \{ .UNDERLINE_QUOTES         \}
-.       if \\n[#UNDERLINE_QUOTES]=0 \{ .UNDERLINE_QUOTES OFF     \}
+.       if \\n[#UNDERLINE_QUOTES]=1 .UNDERLINE_QUOTES
+.       if \\n[#UNDERLINE_QUOTES]=0 .UNDERLINE_QUOTES OFF
 .\" +Doctype underlining (if NAMED)
-.       if !r#DOCTYPE_UNDERLINE \{ .nr #DOCTYPE_UNDERLINE 1 \}
+.       if !r #DOCTYPE_UNDERLINE .nr #DOCTYPE_UNDERLINE 1
 .\" +Quotes and blockquotes
-.       if !r#Q_OFFSET_VALUE \{\
-.          if '\\*[$Q_OFFSET_VALUE]'' \{ .QUOTE_INDENT 1 \}
+.       if !r #Q_OFFSET_VALUE \{\
+.          if '\\*[$Q_OFFSET_VALUE]'' .QUOTE_INDENT 1
 .       \}
 .\" +Epigraphs
-.       if !r#EPI_OFFSET_VALUE \{\
-.          if '\\*[$EPI_OFFSET_VALUE]'' \{ .EPIGRAPH_INDENT 2 \}
+.       if !r #EPI_OFFSET_VALUE \{\
+.          if '\\*[$EPI_OFFSET_VALUE]'' .EPIGRAPH_INDENT 2
 .       \}
 .\" +Linebreaks
-.       if !d$LINEBREAK_CHAR        \{ .LINEBREAK_CHAR    * 3 2p \}
+.       if !d $LINEBREAK_CHAR .LINEBREAK_CHAR * 3 2p
 .\" +Footnotes
-.       if !d$FN_SIZE_CHANGE        \{ .FOOTNOTE_SIZE     +0     \}
-.       if !r#FN_RULE_LENGTH        \{ .FOOTNOTE_RULE_LENGTH 2i  \}
-.\" +Subheads
-.       if !r#SH_BASELINE_ADJ  \{ .SUBHEAD_BASELINE_ADJUST \\n[#LEAD]u/5    \}
-.\" +Subsubheads
-.       if !r#SSH_BASELINE_ADJ \{ .SUBSUBHEAD_BASELINE_ADJUST \\n[#LEAD]u/5 \}
-.\" +Paragraph heads
-.       if !r#PH_INDENT    \{ .PARAHEAD_INDENT \\n[#PP_INDENT]u/2u \}
+.       if !d $FN_SIZE_CHANGE    .FOOTNOTE_SIZE +0
+.       if !r #FN_RULE_LENGTH    .FOOTNOTE_RULE_LENGTH 2i
 .\" +Endnotes
-.       if !r#EN_PP_INDENT \{ .ENDNOTE_PARA_INDENT \\n[#PP_INDENT] \}
+.       if !r #EN_PP_INDENT .ENDNOTE_PARA_INDENT \\n[#PP_INDENT]
 .\" +Footnotes
-.       if !r#FN_RULE_ADJ  \{ .FOOTNOTE_RULE_ADJ  6p \}
+.       if !r #FN_RULE_ADJ  .FOOTNOTE_RULE_ADJ 6p
 .\" +Slant stuff
-.       if !r#SLANT_MEANS_SLANT \{\
-.          ie \\n[#UNDERLINE_SLANT]=1 \{ .UNDERLINE_SLANT \}
-.          el \{ .UNDERLINE_SLANT OFF \}
+.       if !r #SLANT_MEANS_SLANT \{\
+.          ie \\n[#UNDERLINE_SLANT]=1 .UNDERLINE_SLANT
+.          el .UNDERLINE_SLANT OFF
 .       \}
 .    \}
 .\" Defaults for printstyle TYPESET
 .    if \\n[#PRINT_STYLE]=2 \{\
-.       if !d$DOCHEADER_LEAD_ADJ \{ .DOCHEADER_LEAD +0 \}
+.       if !d $DOCHEADER_LEAD_ADJ .DOCHEADER_LEAD +0
 .\" +Cover
-.       if !d$COVER_LEAD_ADJ \{ .COVER_LEAD +0 \}
-.       if !d$COVER_FAM \{ .COVER_FAMILY \\*[$DOC_FAM] \}
+.       if !d $COVER_LEAD_ADJ .COVER_LEAD +0
+.       if !d $COVER_FAM      .COVER_FAMILY \\*[$DOC_FAM]
 .\" (title)
-.       if !d$COVER_TITLE_FAM \{\
-.          ie !d$COVER_FAM \{ .COVER_TITLE_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .COVER_TITLE_FAMILY \\*[$COVER_FAM] \}
+.       if !d $COVER_TITLE_FAM \{\
+.          ie !d $COVER_FAM .COVER_TITLE_FAMILY \\*[$DOC_FAM]
+.          el .COVER_TITLE_FAMILY \\*[$COVER_FAM]
 .       \}
-.       if !d$COVER_TITLE_FT          \{ .COVER_TITLE_FONT B    \}
-.       if !d$COVER_TITLE_SIZE_CHANGE \{ .COVER_TITLE_SIZE +3.5 \}
+.       if !d $COVER_TITLE_FT .COVER_TITLE_FONT B
+.       if !d $COVER_TITLE_SIZE_CHANGE .COVER_TITLE_SIZE +3.5
 .\" (chapter title)
-.       if !d$COVER_CHAPTER_TITLE_FAM \{\
-.          ie !d$COVER_FAM \{ .COVER_CHAPTER_TITLE_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .COVER_CHAPTER_TITLE_FAMILY \\*[$COVER_FAM] \}
+.       if !d $COVER_CHAPTER_TITLE_FAM \{\
+.          ie !d $COVER_FAM .COVER_CHAPTER_TITLE_FAMILY \\*[$DOC_FAM]
+.          el .COVER_CHAPTER_TITLE_FAMILY \\*[$COVER_FAM]
 .       \}
-.       if !d$COVER_CHAPTER_TITLE_FT          \{ .COVER_CHAPTER_TITLE_FONT BI 
\}
-.       if !d$COVER_CHAPTER_TITLE_SIZE_CHANGE \{ .COVER_CHAPTER_TITLE_SIZE +4 
\}
+.       if !d $COVER_CHAPTER_TITLE_FT .COVER_CHAPTER_TITLE_FONT BI
+.       if !d $COVER_CHAPTER_TITLE_SIZE_CHANGE .COVER_CHAPTER_TITLE_SIZE +4
 .\" (subtitle)
-.       if !d$COVER_SUBTITLE_FAM \{\
-.          ie !d$COVER_FAM \{ .COVER_SUBTITLE_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .COVER_SUBTITLE_FAMILY \\*[$COVER_FAM] \}
+.       if !d $COVER_SUBTITLE_FAM \{\
+.          ie !d $COVER_FAM .COVER_SUBTITLE_FAMILY \\*[$DOC_FAM]
+.          el .COVER_SUBTITLE_FAMILY \\*[$COVER_FAM]
 .       \}
-.       if !d$COVER_SUBTITLE_FT          \{ .COVER_SUBTITLE_FONT R  \}
-.       if !d$COVER_SUBTITLE_SIZE_CHANGE \{ .COVER_SUBTITLE_SIZE +0 \}
+.       if !d $COVER_SUBTITLE_FT .COVER_SUBTITLE_FONT R
+.       if !d $COVER_SUBTITLE_SIZE_CHANGE .COVER_SUBTITLE_SIZE +0
 .\" (attribution and author[s])
-.       if !d$COVER_AUTHOR_FAM \{\
-.          ie !d$COVER_FAM \{ .COVER_AUTHOR_FAMILY \\*[$DOC_FAM] \}
-.          el      \{ .COVER_AUTHOR_FAMILY \\*[$COVER_FAM] \}
+.       if !d $COVER_AUTHOR_FAM \{\
+.          ie !d $COVER_FAM .COVER_AUTHOR_FAMILY \\*[$DOC_FAM]
+.          el .COVER_AUTHOR_FAMILY \\*[$COVER_FAM]
 .       \}
-.       if !d$COVER_AUTHOR_FT          \{ .COVER_AUTHOR_FONT I  \}
-.       if !d$COVER_AUTHOR_SIZE_CHANGE \{ .COVER_AUTHOR_SIZE +0 \}
+.       if !d $COVER_AUTHOR_FT .COVER_AUTHOR_FONT I
+.       if !d $COVER_AUTHOR_SIZE_CHANGE .COVER_AUTHOR_SIZE +0
 .\" (doctype if "named")
-.       if !d$COVER_DOCTYPE_FAM \{\
-.          ie !d$COVER_FAM \{ .COVER_DOCTYPE_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .COVER_DOCTYPE_FAMILY \\*[$COVER_FAM] \}
+.       if !d $COVER_DOCTYPE_FAM \{\
+.          ie !d $COVER_FAM .COVER_DOCTYPE_FAMILY \\*[$DOC_FAM]
+.          el .COVER_DOCTYPE_FAMILY \\*[$COVER_FAM]
 .       \}
-.       if !d$COVER_DOCTYPE_FT          \{ .COVER_DOCTYPE_FONT BI \}
-.       if !d$COVER_DOCTYPE_SIZE_CHANGE \{ .COVER_DOCTYPE_SIZE +3 \}
+.       if !d $COVER_DOCTYPE_FT .COVER_DOCTYPE_FONT BI
+.       if !d $COVER_DOCTYPE_SIZE_CHANGE .COVER_DOCTYPE_SIZE +3
 .\" (copyright)
-.       if !d$COVER_COPYRIGHT_FAM \{\
-.          ie !d$COVER_FAM \{ .COVER_COPYRIGHT_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .COVER_COPYRIGHT_FAMILY \\*[$COVER_FAM] \}
+.       if !d $COVER_COPYRIGHT_FAM \{\
+.          ie !d $COVER_FAM .COVER_COPYRIGHT_FAMILY \\*[$DOC_FAM]
+.          el .COVER_COPYRIGHT_FAMILY \\*[$COVER_FAM]
 .       \}
-.       if !d$COVER_COPYRIGHT_FT          \{ .COVER_COPYRIGHT_FONT R  \}
-.       if !d$COVER_COPYRIGHT_SIZE_CHANGE \{ .COVER_COPYRIGHT_SIZE -2 \}
+.       if !d $COVER_COPYRIGHT_FT .COVER_COPYRIGHT_FONT R
+.       if !d $COVER_COPYRIGHT_SIZE_CHANGE .COVER_COPYRIGHT_SIZE -2
 .\" (misc)
-.       if !d$COVER_MISC_FAM         \{ .COVER_MISC_FAMILY \\*[$DOC_FAM] \}
-.       if !d$COVER_MISC_FT          \{ .COVER_MISC_FONT R               \}
-.       if !d$COVER_MISC_SIZE_CHANGE \{ .COVER_MISC_SIZE -2              \}
-.       if !r#COVER_MISC_AUTOLEAD    \{ .COVER_MISC_AUTOLEAD 2           \}
+.       if !d $COVER_MISC_FAM         .COVER_MISC_FAMILY \\*[$DOC_FAM]
+.       if !d $COVER_MISC_FT          .COVER_MISC_FONT R
+.       if !d $COVER_MISC_SIZE_CHANGE .COVER_MISC_SIZE -2
+.       if !r #COVER_MISC_AUTOLEAD    .COVER_MISC_AUTOLEAD 2
 .\" +Doc cover
-.       if !d$DOC_COVER_LEAD_ADJ \{ .DOC_COVER_LEAD +0              \}
-.       if !d$DOC_COVER_FAM      \{ .DOC_COVER_FAMILY \\*[$DOC_FAM] \}
+.       if !d $DOC_COVER_LEAD_ADJ .DOC_COVER_LEAD +0
+.       if !d $DOC_COVER_FAM      .DOC_COVER_FAMILY \\*[$DOC_FAM]
 .\" (title)
-.       if !d$DOC_COVER_TITLE_FAM \{\
-.          ie !d$DOC_COVER_FAM \{ .DOC_COVER_TITLE_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .DOC_COVER_TITLE_FAMILY \\*[$DOC_COVER_FAM] \}
+.       if !d $DOC_COVER_TITLE_FAM \{\
+.          ie !d $DOC_COVER_FAM .DOC_COVER_TITLE_FAMILY \\*[$DOC_FAM]
+.          el .DOC_COVER_TITLE_FAMILY \\*[$DOC_COVER_FAM]
 .       \}
-.       if !d$DOC_COVER_TITLE_FT          \{ .DOC_COVER_TITLE_FONT B    \}
-.       if !d$DOC_COVER_TITLE_SIZE_CHANGE \{ .DOC_COVER_TITLE_SIZE +3.5 \}
+.       if !d $DOC_COVER_TITLE_FT          .DOC_COVER_TITLE_FONT B
+.       if !d $DOC_COVER_TITLE_SIZE_CHANGE .DOC_COVER_TITLE_SIZE +3.5
 .\" (chapter title)
-.       if !d$DOC_COVER_CHAPTER_TITLE_FAM \{\
-.          ie !d$DOC_COVER_FAM \{ .DOC_COVER_CHAPTER_TITLE_FAMILY 
\\*[$DOC_FAM] \}
-.          el            \{ .DOC_COVER_CHAPTER_TITLE_FAMILY 
\\*[$DOC_COVER_FAM] \}
+.       if !d $DOC_COVER_CHAPTER_TITLE_FAM \{\
+.          ie !d $DOC_COVER_FAM .DOC_COVER_CHAPTER_TITLE_FAMILY \\*[$DOC_FAM]
+.          el .DOC_COVER_CHAPTER_TITLE_FAMILY \\*[$DOC_COVER_FAM]
 .       \}
-.       if !d$DOC_COVER_CHAPTER_TITLE_FT          \{ 
.DOC_COVER_CHAPTER_TITLE_FONT BI \}
-.       if !d$DOC_COVER_CHAPTER_TITLE_SIZE_CHANGE \{ 
.DOC_COVER_CHAPTER_TITLE_SIZE +4 \}
+.       if !d $DOC_COVER_CHAPTER_TITLE_FT .DOC_COVER_CHAPTER_TITLE_FONT BI
+.       if !d $DOC_COVER_CHAPTER_TITLE_SIZE_CHANGE 
.DOC_COVER_CHAPTER_TITLE_SIZE +4
 .\" (subtitle)
-.       if !d$DOC_COVER_SUBTITLE_FAM \{\
-.          ie !d$DOC_COVER_FAM \{ .DOC_COVER_SUBTITLE_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .DOC_COVER_SUBTITLE_FAMILY \\*[$DOC_COVER_FAM] \}
+.       if !d $DOC_COVER_SUBTITLE_FAM \{\
+.          ie !d $DOC_COVER_FAM .DOC_COVER_SUBTITLE_FAMILY \\*[$DOC_FAM]
+.          el .DOC_COVER_SUBTITLE_FAMILY \\*[$DOC_COVER_FAM]
 .       \}
-.       if !d$DOC_COVER_SUBTITLE_FT          \{ .DOC_COVER_SUBTITLE_FONT R  \}
-.       if !d$DOC_COVER_SUBTITLE_SIZE_CHANGE \{ .DOC_COVER_SUBTITLE_SIZE +0 \}
+.       if !d $DOC_COVER_SUBTITLE_FT .DOC_COVER_SUBTITLE_FONT R
+.       if !d $DOC_COVER_SUBTITLE_SIZE_CHANGE .DOC_COVER_SUBTITLE_SIZE +0
 .\" (attribution and author[s])
-.       if !d$DOC_COVER_AUTHOR_FAM \{\
-.          ie !d$DOC_COVER_FAM \{ .DOC_COVER_AUTHOR_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .DOC_COVER_AUTHOR_FAMILY \\*[$DOC_COVER_FAM] \}
+.       if !d $DOC_COVER_AUTHOR_FAM \{\
+.          ie !d $DOC_COVER_FAM .DOC_COVER_AUTHOR_FAMILY \\*[$DOC_FAM]
+.          el .DOC_COVER_AUTHOR_FAMILY \\*[$DOC_COVER_FAM]
 .       \}
-.       if !d$DOC_COVER_AUTHOR_FT          \{ .DOC_COVER_AUTHOR_FONT I  \}
-.       if !d$DOC_COVER_AUTHOR_SIZE_CHANGE \{ .DOC_COVER_AUTHOR_SIZE +0 \}
+.       if !d $DOC_COVER_AUTHOR_FT .DOC_COVER_AUTHOR_FONT I
+.       if !d $DOC_COVER_AUTHOR_SIZE_CHANGE .DOC_COVER_AUTHOR_SIZE +0
 .\" (doctype if "named")
-.       if !d$DOC_COVER_DOCTYPE_FAM \{\
-.          ie !d$DOC_COVER_FAM \{ .DOC_COVER_DOCTYPE_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .DOC_COVER_DOCTYPE_FAMILY \\*[$DOC_COVER_FAM] \}
+.       if !d $DOC_COVER_DOCTYPE_FAM \{\
+.          ie !d $DOC_COVER_FAM .DOC_COVER_DOCTYPE_FAMILY \\*[$DOC_FAM]
+.          el .DOC_COVER_DOCTYPE_FAMILY \\*[$DOC_COVER_FAM]
 .       \}
-.       if !d$DOC_COVER_DOCTYPE_FT          \{ .DOC_COVER_DOCTYPE_FONT BI \}
-.       if !d$DOC_COVER_DOCTYPE_SIZE_CHANGE \{ .DOC_COVER_DOCTYPE_SIZE +3 \}
+.       if !d $DOC_COVER_DOCTYPE_FT .DOC_COVER_DOCTYPE_FONT BI
+.       if !d $DOC_COVER_DOCTYPE_SIZE_CHANGE .DOC_COVER_DOCTYPE_SIZE +3
 .\" (copyright)
-.       if !d$DOC_COVER_COPYRIGHT_FAM \{\
-.          ie !d$DOC_COVER_FAM \{ .DOC_COVER_COPYRIGHT_FAMILY \\*[$DOC_FAM] \}
-.          el            \{ .DOC_COVER_COPYRIGHT_FAMILY \\*[$DOC_COVER_FAM] \}
+.       if !d $DOC_COVER_COPYRIGHT_FAM \{\
+.          ie !d $DOC_COVER_FAM .DOC_COVER_COPYRIGHT_FAMILY \\*[$DOC_FAM]
+.          el .DOC_COVER_COPYRIGHT_FAMILY \\*[$DOC_COVER_FAM]
 .       \}
-.       if !d$DOC_COVER_COPYRIGHT_FT          \{ .DOC_COVER_COPYRIGHT_FONT R  
\}
-.       if !d$DOC_COVER_COPYRIGHT_SIZE_CHANGE \{ .DOC_COVER_COPYRIGHT_SIZE -2 
\}
+.       if !d $DOC_COVER_COPYRIGHT_FT .DOC_COVER_COPYRIGHT_FONT R
+.       if !d $DOC_COVER_COPYRIGHT_SIZE_CHANGE .DOC_COVER_COPYRIGHT_SIZE -2
 .\" (misc)
-.       if !d$DOC_COVER_MISC_FAM         \{ .DOC_COVER_MISC_FAMILY 
\\*[$DOC_FAM] \}
-.       if !d$DOC_COVER_MISC_FT          \{ .DOC_COVER_MISC_FONT R             
  \}
-.       if !d$DOC_COVER_MISC_SIZE_CHANGE \{ .DOC_COVER_MISC_SIZE -2            
  \}
-.       if !r#DOC_COVER_MISC_AUTOLEAD    \{ .DOC_COVER_MISC_AUTOLEAD 2         
  \}
+.       if !d $DOC_COVER_MISC_FAM         .DOC_COVER_MISC_FAMILY \\*[$DOC_FAM]
+.       if !d $DOC_COVER_MISC_FT          .DOC_COVER_MISC_FONT R
+.       if !d $DOC_COVER_MISC_SIZE_CHANGE .DOC_COVER_MISC_SIZE -2
+.       if !r #DOC_COVER_MISC_AUTOLEAD    .DOC_COVER_MISC_AUTOLEAD 2
 .\" +Docheader
-.       if !d$DOCHEADER_FAM \{ .DOCHEADER_FAMILY \\*[$DOC_FAM] \}
-.       if !d$TITLE_FAM \{\
-.          ie !d$DOCHEADER_FAM \{ .TITLE_FAMILY \\*[$DOC_FAM]       \}
-.          el                  \{ .TITLE_FAMILY \\*[$DOCHEADER_FAM] \}
-.       \}
-.       if !d$TITLE_FT \{ .TITLE_FONT B \}
-.       if !d$TITLE_SIZE_CHANGE \{\
-.          ie \\n[#DOC_TYPE]=2 \{ .TITLE_SIZE +4 \}
-.          el \{ .TITLE_SIZE +3.5 \}
-.       \}
-.       if !d$CHAPTER_TITLE_FAM \{\
-.          ie !d$DOCHEADER_FAM \{ .CHAPTER_TITLE_FAMILY \\*[$DOC_FAM]       \}
-.          el                  \{ .CHAPTER_TITLE_FAMILY \\*[$DOCHEADER_FAM] \}
-.       \}
-.       if !d$CHAPTER_TITLE_FT          \{ .CHAPTER_TITLE_FONT   BI \}
-.       if !d$CHAPTER_TITLE_SIZE_CHANGE \{ .CHAPTER_TITLE_SIZE  +4  \}
-.       if !d$SUBTITLE_FAM \{\
-.          ie !d$DOCHEADER_FAM \{ .SUBTITLE_FAMILY \\*[$DOC_FAM]       \}
-.          el                  \{ .SUBTITLE_FAMILY \\*[$DOCHEADER_FAM] \}
-.       \}
-.       if !d$SUBTITLE_FT          \{ .SUBTITLE_FONT      R  \}
-.       if !d$SUBTITLE_SIZE_CHANGE \{ .SUBTITLE_SIZE     +0  \}
-.       if !d$AUTHOR_FAM \{\
-.          ie !d$DOCHEADER_FAM \{ .AUTHOR_FAMILY \\*[$DOC_FAM]       \}
-.          el                  \{ .AUTHOR_FAMILY \\*[$DOCHEADER_FAM] \}
-.       \}
-.       if !d$AUTHOR_FT          \{ .AUTHOR_FONT  I \}
-.       if !d$AUTHOR_SIZE_CHANGE \{ .AUTHOR_SIZE +0 \}
-.       if !d$DOCTYPE_FAM \{\
-.          ie !d$DOCHEADER_FAM \{ .DOCTYPE_FAMILY \\*[$DOC_FAM]       \}
-.          el                  \{ .DOCTYPE_FAMILY \\*[$DOCHEADER_FAM] \}
-.       \}
-.       if !d$DOCTYPE_FT           \{ .DOCTYPE_FONT      BI \}
-.       if !d$DOCTYPE_SIZE_CHANGE  \{ .DOCTYPE_SIZE      +3 \}
-.       if !r#DOCTYPE_UNDERLINE    \{ .DOCTYPE_UNDERLINE    \}
+.       if !d $DOCHEADER_FAM .DOCHEADER_FAMILY \\*[$DOC_FAM]
+.       if !d $TITLE_FAM \{\
+.          ie !d $DOCHEADER_FAM .TITLE_FAMILY \\*[$DOC_FAM]
+.          el .TITLE_FAMILY \\*[$DOCHEADER_FAM]
+.       \}
+.       if !d $TITLE_FT .TITLE_FONT B
+.       if !d $TITLE_SIZE_CHANGE \{\
+.          ie \\n[#DOC_TYPE]=2 .TITLE_SIZE +4
+.          el .TITLE_SIZE +3.5
+.       \}
+.       if !d $CHAPTER_TITLE_FAM \{\
+.          ie !d $DOCHEADER_FAM .CHAPTER_TITLE_FAMILY \\*[$DOC_FAM]
+.          el .CHAPTER_TITLE_FAMILY \\*[$DOCHEADER_FAM]
+.       \}
+.       if !d $CHAPTER_TITLE_FT          .CHAPTER_TITLE_FONT BI
+.       if !d $CHAPTER_TITLE_SIZE_CHANGE .CHAPTER_TITLE_SIZE +4
+.       if !d $SUBTITLE_FAM \{\
+.          ie !d $DOCHEADER_FAM .SUBTITLE_FAMILY \\*[$DOC_FAM]
+.          el .SUBTITLE_FAMILY \\*[$DOCHEADER_FAM]
+.       \}
+.       if !d $SUBTITLE_FT          .SUBTITLE_FONT R
+.       if !d $SUBTITLE_SIZE_CHANGE .SUBTITLE_SIZE +0
+.       if !d $AUTHOR_FAM \{\
+.          ie !d $DOCHEADER_FAM .AUTHOR_FAMILY \\*[$DOC_FAM]
+.          el .AUTHOR_FAMILY \\*[$DOCHEADER_FAM]
+.       \}
+.       if !d $AUTHOR_FT          .AUTHOR_FONT I
+.       if !d $AUTHOR_SIZE_CHANGE .AUTHOR_SIZE +0
+.       if !d $DOCTYPE_FAM \{\
+.          ie !d $DOCHEADER_FAM .DOCTYPE_FAMILY \\*[$DOC_FAM]
+.          el .DOCTYPE_FAMILY \\*[$DOCHEADER_FAM]
+.       \}
+.       if !d $DOCTYPE_FT           .DOCTYPE_FONT BI
+.       if !d $DOCTYPE_SIZE_CHANGE  .DOCTYPE_SIZE +3
+.       if !r #DOCTYPE_UNDERLINE    .DOCTYPE_UNDERLINE
 .\" +Headers and footers
-.       if !d$HDRFTR_LEFT_FAM      \{ .HDRFTR_LEFT_FAMILY \\*[$DOC_FAM] \}
-.       if !d$HDRFTR_LEFT_FT       \{ .HDRFTR_LEFT_FONT R               \}
+.       if !d $HDRFTR_LEFT_FAM              .HDRFTR_LEFT_FAMILY \\*[$DOC_FAM]
+.       if !d $HDRFTR_LEFT_FT               .HDRFTR_LEFT_FONT R
 .       if \\n[#HDRFTR_LEFT_CAPS]  \{\
-.          if !d$HDRFTR_LEFT_SIZE_CHANGE \{ .HDRFTR_LEFT_SIZE  -2 \}
+.          if !d $HDRFTR_LEFT_SIZE_CHANGE   .HDRFTR_LEFT_SIZE -2
 .       \}
-.       if !d$HDRFTR_LEFT_SIZE_CHANGE \{ .HDRFTR_LEFT_SIZE     -.5           \}
-.       if !d$HDRFTR_CENTER_FAM       \{ .HDRFTR_CENTER_FAMILY \\*[$DOC_FAM] \}
-.       if !d$HDRFTR_CENTER_FT        \{ .HDRFTR_CENTER_FONT   I             \}
+.       if !d $HDRFTR_LEFT_SIZE_CHANGE      .HDRFTR_LEFT_SIZE -.5
+.       if !d $HDRFTR_CENTER_FAM            .HDRFTR_CENTER_FAMILY \\*[$DOC_FAM]
+.       if !d $HDRFTR_CENTER_FT             .HDRFTR_CENTER_FONT I
 .       if \\n[#HDRFTR_CENTER_CAPS] \{\
-.          if !d$HDRFTR_CENTER_SIZE_CHANGE \{ .HDRFTR_CENTER_SIZE -2 \}
+.          if !d $HDRFTR_CENTER_SIZE_CHANGE .HDRFTR_CENTER_SIZE -2
 .       \}
-.       if !d$HDRFTR_CENTER_SIZE_CHANGE \{ .HDRFTR_CENTER_SIZE -.5            
\}
-.       if !d$HDRFTR_RIGHT_FAM          \{ .HDRFTR_RIGHT_FAMILY \\*[$DOC_FAM] 
\}
-.       if !d$HDRFTR_RIGHT_FT           \{ .HDRFTR_RIGHT_FONT   R             
\}
+.       if !d $HDRFTR_CENTER_SIZE_CHANGE    .HDRFTR_CENTER_SIZE -.5
+.       if !d $HDRFTR_RIGHT_FAM             .HDRFTR_RIGHT_FAMILY \\*[$DOC_FAM]
+.       if !d $HDRFTR_RIGHT_FT              .HDRFTR_RIGHT_FONT R
 .       if \\n[#HDRFTR_RIGHT_CAPS] \{\
-.          if !d$HDRFTR_RIGHT_SIZE_CHANGE \{ .HDRFTR_RIGHT_SIZE -2 \}
+.          if !d $HDRFTR_RIGHT_SIZE_CHANGE  .HDRFTR_RIGHT_SIZE -2
 .       \}
-.       if !d$HDRFTR_RIGHT_SIZE_CHANGE  \{ .HDRFTR_RIGHT_SIZE  -.5             
   \}
-.\" +Heads
-.       if !d$HEAD_FAM                  \{ .HEAD_FAMILY        \\*[$DOC_FAM]   
   \}
-.       if !d$HEAD_FT                   \{ .HEAD_FONT          B               
   \}
-.       if !d$HEAD_SIZE_CHANGE          \{ .HEAD_SIZE          +1              
   \}
-.       if !r#HEAD_SPACE                \{ .HEAD_SPACE                         
   \}
-.\" +Subheads
-.       if !d$SH_FAM                    \{ .SUBHEAD_FAMILY     \\*[$DOC_FAM]   
   \}
-.       if !d$SH_FT                     \{ .SUBHEAD_FONT       B               
   \}
-.       if !d$SH_SIZE_CHANGE            \{ .SUBHEAD_SIZE       +.5             
   \}
-.       if !r#SH_BASELINE_ADJ           \{ .SUBHEAD_BASELINE_ADJUST 
\\n[#LEAD]u/8 \}
-.\" +SubSubheads
-.       if !d$SSH_FAM                   \{ .SUBSUBHEAD_FAMILY  \\*[$DOC_FAM]   
      \}
-.       if !d$SSH_FT                    \{ .SUBSUBHEAD_FONT    I               
      \}
-.       if !d$SSH_SIZE_CHANGE           \{ .SUBSUBHEAD_SIZE    +.5             
      \}
-.       if !r#SSH_BASELINE_ADJ          \{ .SUBSUBHEAD_BASELINE_ADJUST 
\\n[#LEAD]u/8 \}
-.\" +Paragraph heads
-.       if !d$PH_FAM                    \{ .PARAHEAD_FAMILY    \\*[$DOC_FAM]   
   \}
-.       if !d$PH_FT                     \{ .PARAHEAD_FONT      BI              
   \}
-.       if !d$PH_SIZE_CHANGE            \{ .PARAHEAD_SIZE      -.25            
   \}
-.       if !r#PH_INDENT                 \{ .PARAHEAD_INDENT 
\\n[#PP_INDENT]u/2u   \}
-.       if !d$PH_SPACE                  \{ .PARAHEAD_SPACE .6m                 
   \}
+.       if !d $HDRFTR_RIGHT_SIZE_CHANGE     .HDRFTR_RIGHT_SIZE -.5
 .\" +Quotes
-.       if !d$QUOTE_FAM                 \{ .QUOTE_FAMILY       \\*[$DOC_FAM]   
   \}
-.       if !d$QUOTE_FT                  \{ .QUOTE_FONT         I               
   \}
-.       if !d$QUOTE_SIZE_CHANGE         \{ .QUOTE_SIZE         +0              
   \}
-.       if !r#Q_OFFSET_VALUE \{\
-.          if '\\*[$Q_OFFSET_VALUE]''   \{ .QUOTE_INDENT 3 \}
+.       if !d $QUOTE_FAM         .QUOTE_FAMILY \\*[$DOC_FAM]
+.       if !d $QUOTE_FT          .QUOTE_FONT I
+.       if !d $QUOTE_SIZE_CHANGE .QUOTE_SIZE+0
+.       if !r #Q_OFFSET_VALUE \{\
+.          if '\\*[$Q_OFFSET_VALUE]'' .QUOTE_INDENT 3
 .       \}
 .\" +Blockquotes
 .\"  Note: the leading for quotes and blockquotes is set after .DEFAULTS in 
START
-.       if !d$BQUOTE_FAM                \{ .BLOCKQUOTE_FAMILY  \\*[$DOC_FAM]   
 \}
-.       if !d$BQUOTE_FT                 \{ .BLOCKQUOTE_FONT    R               
 \}
-.       if !d$BQUOTE_SIZE_CHANGE        \{ .BLOCKQUOTE_SIZE    -1              
 \}
-.       if !d$BQUOTE_QUAD               \{ .BLOCKQUOTE_QUAD    LEFT            
 \}
+.       if !d $BQUOTE_FAM         .BLOCKQUOTE_FAMILY \\*[$DOC_FAM]
+.       if !d $BQUOTE_FT          .BLOCKQUOTE_FONT R
+.       if !d $BQUOTE_SIZE_CHANGE .BLOCKQUOTE_SIZE -1
+.       if !d $BQUOTE_QUAD        .BLOCKQUOTE_QUAD LEFT
 .\" +Epigraphs
-.       if !d$EPI_FAM                   \{ .EPIGRAPH_FAMILY    \\*[$DOC_FAM]   
 \}
-.       if !d$EPI_FT                    \{ .EPIGRAPH_FONT      R               
 \}
-.       if !d$EPI_SIZE_CHANGE           \{ .EPIGRAPH_SIZE      -1.5            
 \}
-.       if !r#EPI_AUTOLEAD              \{ .EPIGRAPH_AUTOLEAD  2               
 \}
-.       if !d$EPI_QUAD                  \{ .EPIGRAPH_QUAD      \\*[$DOC_QUAD]  
 \}
-.       if !r#EPI_OFFSET_VALUE \{\
-.          if '\\*[$EPI_OFFSET_VALUE]'' \{ .EPIGRAPH_INDENT 3 \}
+.       if !d $EPI_FAM         .EPIGRAPH_FAMILY \\*[$DOC_FAM]
+.       if !d $EPI_FT          .EPIGRAPH_FONT R
+.       if !d $EPI_SIZE_CHANGE .EPIGRAPH_SIZE -1.5
+.       if !r #EPI_AUTOLEAD    .EPIGRAPH_AUTOLEAD 2
+.       if !d $EPI_QUAD        .EPIGRAPH_QUAD \\*[$DOC_QUAD]
+.       if !\\n[#EPI_OFFSET_VALUE] \{\
+.          if '\\*[$EPI_OFFSET_VALUE]'' .EPIGRAPH_INDENT 3
 .       \}
 .\" +Linebreaks
-.       if !d$LINEBREAK_CHAR            \{ .LINEBREAK_CHAR * 3 3p              
 \}
-.       if !d$LINEBREAK_COLOR           \{ .LINEBREAK_COLOR black              
 \}
+.       if !d $LINEBREAK_CHAR  .LINEBREAK_CHAR * 3 3p
+.       if !d $LINEBREAK_COLOR .LINEBREAK_COLOR black
 .\" +Footnotes
-.       if !r#FN_RULE_LENGTH            \{ .FOOTNOTE_RULE_LENGTH 4P            
 \}
-.       if !r#FN_RULE_ADJ               \{ .FOOTNOTE_RULE_ADJ  3p              
 \}
-.       if !d$FN_SIZE_CHANGE            \{ .FOOTNOTE_SIZE      -2              
 \}
-.       if !r#FN_AUTOLEAD               \{ .FOOTNOTE_AUTOLEAD  2               
 \}
+.       if !r #FN_RULE_LENGTH .FOOTNOTE_RULE_LENGTH 4P
+.       if !r #FN_RULE_ADJ    .FOOTNOTE_RULE_ADJ 3p
+.       if !d $FN_SIZE_CHANGE .FOOTNOTE_SIZE -2
+.       if !r #FN_AUTOLEAD    .FOOTNOTE_AUTOLEAD 2
 .\" +Endnotes
-.       if !r#EN_PS                     \{ .ENDNOTE_PT_SIZE 
(\\n[#DOC_PT_SIZE]u) \}
-.       if !d$EN_STRING_FT              \{ .ENDNOTE_STRING_FONT B              
  \}
-.       if !d$EN_STRING_SIZE_CHANGE     \{ .ENDNOTE_STRING_SIZE +1             
  \}
-.       if !d$EN_TITLE_FT               \{ .ENDNOTE_TITLE_FONT  B              
  \}
-.       if !d$EN_TITLE_SIZE_CHANGE      \{ .ENDNOTE_TITLE_SIZE  +0             
  \}
-.       if !d$EN_NUMBER_FT              \{ .ENDNOTE_NUMBER_FONT B              
  \}
-.       if !d$EN_LN_FT                  \{ .ENDNOTE_LINENUMBER_FONT R          
  \}
-.       if !d$EN_NUMBER_SIZE_CHANGE     \{ .ENDNOTE_NUMBER_SIZE +0             
  \}
-.       if !d$EN_LN_SIZE_CHANGE         \{ .ENDNOTE_LINENUMBER_SIZE +0         
  \}
-.       if !r#EN_PP_INDENT              \{ .ENDNOTE_PARA_INDENT 1.5m           
  \}
-.       if !d$EN_SPACE                  \{ .ENDNOTE_SPACING 0                  
  \}
+.       if !r #EN_PS                 .ENDNOTE_PT_SIZE (\\n[#DOC_PT_SIZE]u)
+.       if !d $EN_STRING_FT          .ENDNOTE_STRING_FONT B
+.       if !d $EN_STRING_SIZE_CHANGE .ENDNOTE_STRING_SIZE +1
+.       if !d $EN_TITLE_FT           .ENDNOTE_TITLE_FONT B
+.       if !d $EN_TITLE_SIZE_CHANGE  .ENDNOTE_TITLE_SIZE +0
+.       if !d $EN_NUMBER_FT          .ENDNOTE_NUMBER_FONT B
+.       if !d $EN_LN_FT              .ENDNOTE_LINENUMBER_FONT R
+.       if !d $EN_NUMBER_SIZE_CHANGE .ENDNOTE_NUMBER_SIZE +0
+.       if !d $EN_LN_SIZE_CHANGE     .ENDNOTE_LINENUMBER_SIZE +0
+.       if !r #EN_PP_INDENT          .ENDNOTE_PARA_INDENT 1.5m
+.       if !d $EN_SPACE              .ENDNOTE_SPACING 0
 .\" +Bibliography
-.       if !r#BIB_LIST                  \{ .BIBLIOGRAPHY_TYPE LIST .           
       \}
-.       if !r#BIB_PS                    \{ .BIBLIOGRAPHY_PT_SIZE 
(\\n[#DOC_PT_SIZE]u) \}
-.       if !d$BIB_STRING_FT             \{ .BIBLIOGRAPHY_STRING_FONT B         
       \}
-.       if !d$BIB_STRING_SIZE_CHANGE    \{ .BIBLIOGRAPHY_STRING_SIZE +1        
       \}
+.       if !r #BIB_LIST               .BIBLIOGRAPHY_TYPE LIST .
+.       if !r #BIB_PS                 .BIBLIOGRAPHY_PT_SIZE 
(\\n[#DOC_PT_SIZE]u)
+.       if !d $BIB_STRING_FT          .BIBLIOGRAPHY_STRING_FONT B
+.       if !d $BIB_STRING_SIZE_CHANGE .BIBLIOGRAPHY_STRING_SIZE +1
 .\" +Table of contents
-.       if !d$TOC_FAM                   \{ .TOC_FAMILY  \\*[$DOC_FAM]          
  \}
-.       if !r#TOC_PS                    \{ .TOC_PT_SIZE (\\n[#DOC_PT_SIZE]u)   
  \}
-.       if !d$TOC_LEAD                  \{ .TOC_LEAD \\n[#DOC_LEAD]u ADJUST    
  \}
-.       if !d$TOC_HEADER_FAM            \{ .TOC_HEADER_FAMILY \\*[$TOC_FAM]    
  \}
-.       if !d$TOC_HEADER_SIZE_CHANGE    \{ .TOC_HEADER_SIZE +4                 
  \}
-.       if !d$TOC_HEADER_FT             \{ .TOC_HEADER_FONT  B                 
  \}
-.       if !d$TOC_TITLE_FAM             \{ .TOC_TITLE_FAMILY \\*[$TOC_FAM]     
  \}
-.       if !d$TOC_PN_FAM                \{ .TOC_PN_FAMILY    \\*[$TOC_FAM]     
  \}
-.       if !d$TOC_HEAD_FAM              \{ .TOC_HEAD_FAMILY  \\*[$TOC_FAM]     
  \}
-.       if !d$TOC_SH_FAM                \{ .TOC_SUBHEAD_FAMILY  \\*[$TOC_FAM]  
  \}
-.       if !d$TOC_SSH_FAM               \{ .TOC_SUBSUBHEAD_FAMILY  
\\*[$TOC_FAM] \}
-.       if !d$TOC_PH_FAM                \{ .TOC_PARAHEAD_FAMILY \\*[$TOC_FAM]  
  \}
-.       if !d$TOC_TITLE_FT              \{ .TOC_TITLE_FONT    BI               
  \}
-.       if !d$TOC_PN_FT                 \{ .TOC_PN_FONT       R                
  \}
-.       if !d$TOC_HEAD_FT               \{ .TOC_HEAD_FONT     B                
  \}
-.       if !d$TOC_SH_FT                 \{ .TOC_SUBHEAD_FONT  R                
  \}
-.       if !d$TOC_SSH_FT                \{ .TOC_SUBSUBHEAD_FONT  I             
  \}
-.       if !d$TOC_PH_FT                 \{ .TOC_PARAHEAD_FONT BI               
  \}
-.       if !d$TOC_TITLE_SIZE_CHANGE     \{ .TOC_TITLE_SIZE    +1.5             
  \}
-.       if !d$TOC_PN_SIZE_CHANGE        \{ .TOC_PN_SIZE       +0               
  \}
-.       if !d$TOC_HEAD_SIZE_CHANGE      \{ .TOC_HEAD_SIZE     +.5              
  \}
-.       if !d$TOC_SH_SIZE_CHANGE        \{ .TOC_SUBHEAD_SIZE  +0               
  \}
-.       if !d$TOC_SSH_SIZE_CHANGE       \{ .TOC_SUBSUBHEAD_SIZE  +0            
  \}
-.       if !d$TOC_PH_SIZE_CHANGE        \{ .TOC_PARAHEAD_SIZE +0               
  \}
-.       ps \\n[#TOC_PS]u\\*[$TOC_TITLE_SIZE_CHANGE]
-.       if !r#TOC_HEAD_INDENT           \{ .TOC_HEAD_INDENT \w'\0\0.'          
  \}
-.       ps
-.       ps \\n[#TOC_PS]u\\*[$TOC_HEAD_SIZE_CHANGE]
-.       if !r#TOC_SH_INDENT             \{ .TOC_SUBHEAD_INDENT 
\\n[#TOC_HEAD_INDENT]+\w'\0\0.'  \}
-.       ps
-.       ps \\n[#TOC_PS]u\\*[$TOC_SH_SIZE_CHANGE]
-.       if !r#TOC_SSH_INDENT            \{ .TOC_SUBSUBHEAD_INDENT 
\\n[#TOC_SH_INDENT]+\w'\0\0.' \}
-.       ps
-.       ps \\n[#TOC_PS]u\\*[$TOC_SSH_SIZE_CHANGE]
-.       if !r#TOC_PH_INDENT             \{ .TOC_PARAHEAD_INDENT 
\\n[#TOC_SSH_INDENT]+\w'\0\0.'  \}
-.       ps
+.       if !d $TOC_FAM                .TOC_FAMILY \\*[$DOC_FAM]
+.       if !r #TOC_PS                 .TOC_PT_SIZE (\\n[#DOC_PT_SIZE]u)
+.       if '\\*[$TOC_LEAD]''          .TOC_LEAD address@hidden ADJUST
+.       if !d $TOC_HEADER_FAM         .TOC_HEADER_FAMILY \\*[$TOC_FAM]
+.       if !d $TOC_HEADER_SIZE_CHANGE .TOC_HEADER_SIZE +4
+.       if !d $TOC_HEADER_FT          .TOC_HEADER_FONT B
+.       if !d $TOC_PN_FAM             .TOC_PN_FAMILY \\*[$TOC_FAM]
+.       if !d $TOC_PN_FT              .TOC_PN_FONT R
+.       if !d $TOC_PN_SIZE_CHANGE     .TOC_PN_SIZE +0
 .    \}
 .\" +Refer support
-.    if !r#EN_REF \{ .nr #FN_REF 1 \}
-.    if !d$REF_FN_INDENT \{\
-.       if \\n[#PRINT_STYLE]=1 \{ .INDENT_REFS FOOTNOTE .5i \}
-.       if \\n[#PRINT_STYLE]=2 \{ .INDENT_REFS FOOTNOTE 2m  \}
-.    \}
-.    if !d$REF_EN_INDENT \{\
-.       if \\n[#PRINT_STYLE]=1 \{ .INDENT_REFS ENDNOTE .5i  \}
-.       if \\n[#PRINT_STYLE]=2 \{ .INDENT_REFS ENDNOTE 2m   \}
-.    \}
-.    if !d$REF_BIB_INDENT \{\
-.       if \\n[#PRINT_STYLE]=1 \{ .INDENT_REFS BIBLIO .5i   \}
-.       if \\n[#PRINT_STYLE]=2 \{ .INDENT_REFS BIBLIO 2m    \}
+.    if !r #EN_REF .nr #FN_REF 1
+.    if !d $REF_FN_INDENT \{\
+.       if \\n[#PRINT_STYLE]=1 .INDENT_REFS FOOTNOTE .5i
+.       if \\n[#PRINT_STYLE]=2 .INDENT_REFS FOOTNOTE 2m
+.    \}
+.    if !d $REF_EN_INDENT \{\
+.       if \\n[#PRINT_STYLE]=1 .INDENT_REFS ENDNOTE .5i
+.       if \\n[#PRINT_STYLE]=2 .INDENT_REFS ENDNOTE 2m
+.    \}
+.    if !d $REF_BIB_INDENT \{\
+.       if \\n[#PRINT_STYLE]=1 .INDENT_REFS BIBLIO .5i
+.       if \\n[#PRINT_STYLE]=2 .INDENT_REFS BIBLIO 2m
 .    \}
 .\" Define strings for idem entries
 .    if \\n[#PRINT_STYLE]=1 .char \[idem] \[hy]\[hy]\[hy]
 .    if \\n[#PRINT_STYLE]=2 .char \[idem] \v'-.3m'\l'3m'\v'.3m'
 .\" Adjust doc leading for PRINTSTYLE TYPESET
 .    if \\n[#PRINT_STYLE]=2 \{\
-.       ie \\n[#ADJ_DOC_LEAD]=1 \{ .DOC_LEAD_ADJUST \}
-.       el \{ . \}
+.       ie \\n[#ADJ_DOC_LEAD]=1 .DOC_LEAD_ADJUST
+.       el .
 .    \}
 .\" This diversion is to get a value for #FN_AUTOLEAD
 .    di NULL
 .       ev NULL
 .       if \\n[#PRINT_STYLE]=1 \{\
 .          ps \\*[$TYPEWRITER_PS]
-.          ie \\n[#SINGLE_SPACE]=1 \{ .vs \\n[#ORIGINAL_DOC_LEAD]u \}
-.          el \{ .vs \\n[#ORIGINAL_DOC_LEAD]u/2u \}
+.          ie \\n[#SINGLE_SPACE]=1 .vs \\n[#ORIGINAL_DOC_LEAD]u
+.          el .vs \\n[#ORIGINAL_DOC_LEAD]u/2u
 .       \}
 .       if \\n[#PRINT_STYLE]=2 \{\
 .          PT_SIZE  \\n[#DOC_PT_SIZE]u\\*[$FN_SIZE_CHANGE]
 .          AUTOLEAD \\n[#FN_AUTOLEAD]
 .       \}
 .       nr #FN_LEAD \\n[#LEAD]
-.       if \\n[#PRINT_STYLE]=2 \{ .LS \\n[#DOC_LEAD]u \}
+.       if \\n[#PRINT_STYLE]=2 .LS \\n[#DOC_LEAD]u
 .       ev
 .    di
 .    ie !\\n[#COLLATE] \{\
@@ -6013,7 +5856,7 @@
 .       TRAPS
 .\" Endnote, bibliography and toc leading
 .       nr #OK_PROCESS_LEAD 1
-.       nr #RESTORE_DOC_LEAD \\n(.v
+.       nr #RESTORE_DOC_LEAD \\n[.v]
 .       nr #RESTORE_B_MARGIN \\n[#B_MARGIN]
 .       if \\n[#PRINT_STYLE]=1 \{\
 .          ie \\n[#SINGLE_SPACE] \{\
@@ -6028,14 +5871,14 @@
 .          \}
 .       \}
 .       if \\n[#PRINT_STYLE]=2 \{\
-.          ie !d$EN_LEAD .ENDNOTE_LEAD \\n[#UNADJUSTED_DOC_LEAD]u ADJUST
+.          ie !d $EN_LEAD  .ENDNOTE_LEAD \\n[#UNADJUSTED_DOC_LEAD]u ADJUST
 .          el .ENDNOTE_LEAD \\*[$EN_LEAD] \\*[$ADJUST_EN_LEAD]
-.          ie !d$BIB_LEAD .BIBLIOGRAPHY_LEAD \\n[#UNADJUSTED_DOC_LEAD]u ADJUST
+.          ie !d $BIB_LEAD .BIBLIOGRAPHY_LEAD \\n[#UNADJUSTED_DOC_LEAD]u ADJUST
 .          el .BIBLIOGRAPHY_LEAD \\*[$BIB_LEAD] \\*[$ADJUST_BIB_LEAD]
-.          ie !d$TOC_LEAD .TOC_LEAD \\n[#UNADJUSTED_DOC_LEAD]u 
\\*[$ADJUST_TOC_LEAD]
+.          ie !d $TOC_LEAD .TOC_LEAD \\n[#UNADJUSTED_DOC_LEAD]u 
\\*[$ADJUST_TOC_LEAD]
 .          el .TOC_LEAD \\*[$TOC_LEAD] \\*[$ADJUST_TOC_LEAD]
 .       \}
-.       ie !d$BIB_SPACE \{ .BIBLIOGRAPHY_SPACING 0 \}
+.       ie !d $BIB_SPACE .BIBLIOGRAPHY_SPACING 0
 .       el \{\
 .          if \\n[#DEFER_BIB_SPACING]=1 \{\
 .             BIBLIOGRAPHY_SPACING \\*[$BIB_SPACE]
@@ -6055,7 +5898,28 @@
 .          \}
 .       \}
 .    \}
-.    if \\n[#PRINT_STYLE]=1 \{ .nr #IGNORE 1 \}
+.\" Set default heading and toc-entry family if not done already
+.    nr #HD_LEVEL 0 1 \" loop step
+.    nr #LOOP 9       \" loop count
+.    while \\n+[#HD_LEVEL]<=\\n[#LOOP] \{\
+.       if '\\*[$HEAD_\\n[#HD_LEVEL]_FAM]'' \
+.           ds $HEAD_\\n[#HD_LEVEL]_FAM \\*[$DOC_FAM]
+.       if '\\*[$HEAD_\\n[#HD_LEVEL]_BASELINE_ADJ]'' \
+.           ds $HEAD_\\n[#HD_LEVEL]_BASELINE_ADJ \\n[.v]/10
+.       if '\\*[$TOC_HEAD_\\n[#HD_LEVEL]_FAM]'' \
+.           ds $TOC_HEAD_\\n[#HD_LEVEL]_FAM \\*[$DOC_FAM]
+.    \}
+.    if '\\*[$TOC_TITLE_FAM]'' .ds $TOC_TITLE_FAM \\*[$DOC_FAM]
+.\" Re-run MNinit to capture strings and registers set in DEFAULTS.
+.    if !'\\*[$MN-arg1]'' \{\
+.       MNinit \
+\\*[$MN-arg1] \\*[$MN-arg2] \
+\\*[$MN-arg3] \\*[$MN-arg4] \
+\\*[$MN-arg5] \\*[$MN-arg6] \
+\\*[$MN-arg7] \\*[$MN-arg8] \
+\\*[$MN-arg9]
+.    \}
+.    if \\n[#PRINT_STYLE]=1 .nr #IGNORE 1
 .END
 \#
 \# ====================================================================
@@ -6067,7 +5931,7 @@
 \# *Arguments:
 \#   <none>
 \# *Function:
-\#   Reads in default document style parameters and any parameter
+\#   Reads in default document style parameters and any parameters
 \#   the user has changed before issuing START.
 \#   Using the information gathered in the opening macros,
 \#   prints appropriate title (or chapter #), subtitle, author
@@ -6083,28 +5947,49 @@
 \#  First, define some strings for point sizes
 \#
 \# Doc cover
-.ds $DOC_COVER_AUTHOR_PT_SIZE        
\\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_AUTHOR_SIZE_CHANGE]
-.ds $DOC_COVER_CHAPTER_TITLE_PT_SIZE 
\\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_CHAPTER_TITLE_SIZE_CHANGE]
-.ds $DOC_COVER_COPYRIGHT_PT_SIZE     
\\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_COPYRIGHT_SIZE_CHANGE]
-.ds $DOC_COVER_DOCTYPE_PT_SIZE       
\\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_DOCTYPE_SIZE_CHANGE]
-.ds $DOC_COVER_MISC_PT_SIZE          
\\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_MISC_SIZE_CHANGE]
-.ds $DOC_COVER_SUBTITLE_PT_SIZE      
\\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_SUBTITLE_SIZE_CHANGE]
-.ds $DOC_COVER_TITLE_PT_SIZE         
\\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_TITLE_SIZE_CHANGE]
+\#
+.ds $DOC_COVER_AUTHOR_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_AUTHOR_SIZE_CHANGE]
+.ds $DOC_COVER_CHAPTER_TITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_CHAPTER_TITLE_SIZE_CHANGE]
+.ds $DOC_COVER_COPYRIGHT_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_COPYRIGHT_SIZE_CHANGE]
+.ds $DOC_COVER_DOCTYPE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_DOCTYPE_SIZE_CHANGE]
+.ds $DOC_COVER_MISC_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_MISC_SIZE_CHANGE]
+.ds $DOC_COVER_SUBTITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_SUBTITLE_SIZE_CHANGE]
+.ds $DOC_COVER_TITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$DOC_COVER_TITLE_SIZE_CHANGE]
 \# Cover
-.ds $COVER_AUTHOR_PT_SIZE        
\\n[#DOC_PT_SIZE]u\\*[$COVER_AUTHOR_SIZE_CHANGE]
-.ds $COVER_CHAPTER_TITLE_PT_SIZE 
\\n[#DOC_PT_SIZE]u\\*[$COVER_CHAPTER_TITLE_SIZE_CHANGE]
-.ds $COVER_COPYRIGHT_PT_SIZE     
\\n[#DOC_PT_SIZE]u\\*[$COVER_COPYRIGHT_SIZE_CHANGE]
-.ds $COVER_DOCTYPE_PT_SIZE       
\\n[#DOC_PT_SIZE]u\\*[$COVER_DOCTYPE_SIZE_CHANGE]
-.ds $COVER_MISC_PT_SIZE          \\n[#DOC_PT_SIZE]u\\*[$COVER_MISC_SIZE_CHANGE]
-.ds $COVER_SUBTITLE_PT_SIZE      
\\n[#DOC_PT_SIZE]u\\*[$COVER_SUBTITLE_SIZE_CHANGE]
-.ds $COVER_TITLE_PT_SIZE         
\\n[#DOC_PT_SIZE]u\\*[$COVER_TITLE_SIZE_CHANGE]
+.ds $COVER_AUTHOR_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$COVER_AUTHOR_SIZE_CHANGE]
+.ds $COVER_CHAPTER_TITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$COVER_CHAPTER_TITLE_SIZE_CHANGE]
+.ds $COVER_COPYRIGHT_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$COVER_COPYRIGHT_SIZE_CHANGE]
+.ds $COVER_DOCTYPE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$COVER_DOCTYPE_SIZE_CHANGE]
+.ds $COVER_MISC_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$COVER_MISC_SIZE_CHANGE]
+.ds $COVER_SUBTITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$COVER_SUBTITLE_SIZE_CHANGE]
+.ds $COVER_TITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$COVER_TITLE_SIZE_CHANGE]
 \# Docheader
-.ds $AUTHOR_PT_SIZE         \\n[#DOC_PT_SIZE]u\\*[$AUTHOR_SIZE_CHANGE]
-.ds $CHAPTER_TITLE_PT_SIZE  \\n[#DOC_PT_SIZE]u\\*[$CHAPTER_TITLE_SIZE_CHANGE]
-.ds $COPYRIGHT_PT_SIZE      \\n[#DOC_PT_SIZE]u\\*[$COPYRIGHT_SIZE_CHANGE]
-.ds $DOCTYPE_PT_SIZE        \\n[#DOC_PT_SIZE]u\\*[$DOCTYPE_SIZE_CHANGE]
-.ds $SUBTITLE_PT_SIZE       \\n[#DOC_PT_SIZE]u\\*[$SUBTITLE_SIZE_CHANGE]
-.ds $TITLE_PT_SIZE          \\n[#DOC_PT_SIZE]u\\*[$TITLE_SIZE_CHANGE]
+.ds $AUTHOR_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$AUTHOR_SIZE_CHANGE]
+.ds $CHAPTER_TITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$CHAPTER_TITLE_SIZE_CHANGE]
+.ds $COPYRIGHT_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$COPYRIGHT_SIZE_CHANGE]
+.ds $DOCTYPE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$DOCTYPE_SIZE_CHANGE]
+.ds $SUBTITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$SUBTITLE_SIZE_CHANGE]
+.ds $TITLE_PT_SIZE \
+    \\n[#DOC_PT_SIZE]u\\*[$TITLE_SIZE_CHANGE]
 \#
 \# Next, some utility macros for various routines to prevent repetition
 \#
@@ -6113,15 +5998,15 @@
 .    if '\\$0'COVER_H_POS'     .ds $CALLING_MACRO COVER
 .    if '\\$0'DOC_COVER_H_POS' .ds $CALLING_MACRO DOC_COVER
 .    ie !'\\*[$\\*[$CALLING_MACRO]_QUAD]'' \{\
-.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'L'      \{ .LEFT   \}
-.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'LEFT'   \{ .LEFT   \}
-.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'R'      \{ .RIGHT  \}
-.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'RIGHT'  \{ .RIGHT  \}
-.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'C'      \{ .RIGHT  \}
-.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'CENTER' \{ .CENTER \}
-.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'CENTRE' \{ .CENTER \}
+.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'L'      .LEFT
+.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'LEFT'   .LEFT
+.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'R'      .RIGHT
+.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'RIGHT'  .RIGHT
+.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'C'      .RIGHT
+.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'CENTER' .CENTER
+.       if '\\*[$\\*[$CALLING_MACRO]_QUAD]'CENTRE' .CENTER
 .    \}
-.    el \{ .CENTER \}
+.    el .CENTER
 .END
 \#
 \# Aliases for DOC_HEADER_QUAD
@@ -6136,21 +6021,21 @@
 .             nr #AUTHORS \\n[#AUTHOR_DOCCOVER_NUM]
 .             nr #NEXT_AUTHOR 0 1
 .             while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\
-.                ie \\n[#DOC_COVER_AUTHOR_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$DOC_COVER_AUTHOR_COLOR]]\\*[$AUTHOR_DOCCOVER_\\n+[#NEXT_AUTHOR]]\m[]
+.                ie \\n[#DOC_COVER_AUTHOR_COLOR]=1 \
+.                   PRINT \
+\m[\\*[$DOC_COVER_AUTHOR_COLOR]]\\*[$AUTHOR_DOCCOVER_\\n+[#NEXT_AUTHOR]]\m[]
+.                el .PRINT \\*[$AUTHOR_DOCCOVER_\\n+[#NEXT_AUTHOR]]
 .                \}
-.                el \{ .PRINT \\*[$AUTHOR_DOCCOVER_\\n+[#NEXT_AUTHOR]] \}
-.\}
 .          \}
 .          el \{\
 .             nr #AUTHORS \\n[#AUTHOR_NUM]
 .             nr #NEXT_AUTHOR 0 1
 .             while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\
-.                ie \\n[#DOC_COVER_AUTHOR_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$DOC_COVER_AUTHOR_COLOR]]\\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]\m[]
+.                ie \\n[#DOC_COVER_AUTHOR_COLOR]=1 \
+.                   PRINT \
+\m[\\*[$DOC_COVER_AUTHOR_COLOR]]\\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]\m[]
+.                el .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]
 .                \}
-.                el \{ .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]] \}
-.\}
 .          \}
 .          return
 .       \}
@@ -6159,21 +6044,21 @@
 .             nr #AUTHORS \\n[#AUTHOR_COVER_NUM]
 .             nr #NEXT_AUTHOR 0 1
 .             while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\
-.                ie \\n[#COVER_AUTHOR_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$COVER_AUTHOR_COLOR]]\\*[$AUTHOR_COVER_\\n+[#NEXT_AUTHOR]]\m[]
+.                ie \\n[#COVER_AUTHOR_COLOR]=1 \
+.                   PRINT \
+\m[\\*[$COVER_AUTHOR_COLOR]]\\*[$AUTHOR_COVER_\\n+[#NEXT_AUTHOR]]\m[]
+.                el .PRINT \\*[$AUTHOR_COVER_\\n+[#NEXT_AUTHOR]]
 .                \}
-.                el \{ .PRINT \\*[$AUTHOR_COVER_\\n+[#NEXT_AUTHOR]] \}
-.\}
 .          \}
 .          el \{\
 .             nr #AUTHORS \\n[#AUTHOR_NUM]
 .             nr #NEXT_AUTHOR 0 1
 .             while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\
-.                ie \\n[#COVER_AUTHOR_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$COVER_AUTHOR_COLOR]]\\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]\m[]
+.                ie \\n[#COVER_AUTHOR_COLOR]=1 \
+.                   PRINT \
+\m[\\*[$COVER_AUTHOR_COLOR]]\\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]\m[]
+.                el .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]
 .                \}
-.                el \{ .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]] \}
-.\}
 .          \}
 .          return
 .       \}
@@ -6182,11 +6067,10 @@
 .       nr #AUTHORS \\n[#AUTHOR_NUM]
 .       nr #NEXT_AUTHOR 0 1
 .       while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\
-.          ie \\n[#AUTHOR_COLOR]=1 \{\
+.          ie \\n[#AUTHOR_COLOR]=1 \
 .             PRINT \m[\\*[$AUTHOR_COLOR]]\\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]\m[]
+.          el .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]
 .          \}
-.          el \{ .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]] \}
-.\}
 .    \}
 .END
 \#
@@ -6199,13 +6083,10 @@
 .       LS      \\n[#DOCHEADER_LEAD]u
 .       nr #ARG_NUM 0 1
 .       while \\n[#TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.          ie \\n[#TITLE_COLOR]=1 \{\
+.          ie \\n[#TITLE_COLOR]=1 \
 .             PRINT "\m[\\*[$TITLE_COLOR]]\\*[$TITLE_\\n[#ARG_NUM]]\m[]
+.          el .PRINT "\\*[$TITLE_\\n[#ARG_NUM]]
 .          \}
-.          el \{\
-.             PRINT "\\*[$TITLE_\\n[#ARG_NUM]]
-.          \}
-.\}
 .    \}
 .    if !'\\*[$SUBTITLE_1]'' \{\
 .       FAMILY  \\*[$SUBTITLE_FAM]
@@ -6213,29 +6094,24 @@
 .       PT_SIZE \\*[$SUBTITLE_PT_SIZE]
 .       nr #ARG_NUM 0 1
 .       while \\n[#SUBTITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.          ie \\n[#SUBTITLE_COLOR]=1 \{\
+.          ie \\n[#SUBTITLE_COLOR]=1 \
 .             PRINT "\m[\\*[$SUBTITLE_COLOR]]\\*[$SUBTITLE_\\n[#ARG_NUM]]\m[]
+.          el .PRINT "\\*[$SUBTITLE_\\n[#ARG_NUM]]
 .          \}
-.          el \{\
-.             PRINT "\\*[$SUBTITLE_\\n[#ARG_NUM]]
-.          \}
-.\}
 .    \}
 .    if !'\\*[$AUTHOR_1]'' \{\
 .       FAMILY  \\*[$AUTHOR_FAM]
 .       FT      \\*[$AUTHOR_FT]
 .       PT_SIZE \\*[$AUTHOR_PT_SIZE]
-.       ie \\n[#ATTRIBUTE_COLOR]=1 \{\
+.       ie \\n[#ATTRIBUTE_COLOR]=1 \
 .          PRINT \&\m[\\*[$ATTRIBUTE_COLOR]]\\*[$ATTRIBUTE_STRING]\m[]
-.       \}
-.       el \{ .PRINT \&\\*[$ATTRIBUTE_STRING] \}
+.       el .PRINT \&\\*[$ATTRIBUTE_STRING]
 .       PRINT_AUTHORS
 .    \}
 .    FAMILY \\*[$DOC_FAM]
 .    FT R
 .END
 \#
-\#
 .MAC CHAPTER_DOCHEADER END
 .    DOC_HEADER_QUAD
 .    FAMILY  \\*[$TITLE_FAM]
@@ -6253,40 +6129,38 @@
 .          \}
 .          nr #ARG_NUM 0 1
 .          while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#TITLE_COLOR]=1 \{\
-.                PRINT 
\m[\\*[$TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
+.             ie \\n[#TITLE_COLOR]=1 \
+.                PRINT \
+\m[\\*[$TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
+.             el .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]
 .             \}
-.             el \{ .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]] \}
-.\}
 .       \}
 .       el \{\
-.          ie \\n[#TITLE_COLOR]=1 \{\
+.          ie \\n[#TITLE_COLOR]=1 \
 .             PRINT \m[\\*[$TITLE_COLOR]]\\*[$CHAPTER_STRING]\m[]
-.          \}
-.          el \{ .PRINT \\*[$CHAPTER_STRING] \}
+.          el .PRINT \\*[$CHAPTER_STRING]
 .       \}
 .    \}
 .\" Chapter string, possibly with a chapter title
 .    el \{\
-.       ie \\n[#TITLE_COLOR]=1 \{\
+.       ie \\n[#TITLE_COLOR]=1 \
 .          PRINT \m[\\*[$TITLE_COLOR]]\\*[$CHAPTER_STRING] \\*[$CHAPTER]\m[]
-.       \}
-.       el \{ .PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER] \}
+.       el .PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER]
 .       if !'\\*[$CHAPTER_TITLE_1]'' \{\
 .          if \\n[#PRINT_STYLE]=2 \{\
 .             FAMILY  \\*[$CHAPTER_TITLE_FAM]
 .             FT      \\*[$CHAPTER_TITLE_FT]
 .             PT_SIZE \\*[$CHAPTER_TITLE_PT_SIZE]
 .             LS      \\n[#DOCHEADER_LEAD]u
-.             ALD \\n[.v]u/4u \"Put a little space before the chapter title
+.             ALD     \\n[.v]u/4u \" Put a little space before the chapter 
title
 .          \}
 .          nr #ARG_NUM 0 1
 .          while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#CHAPTER_TITLE_COLOR]=1 \{\
-.                PRINT 
\m[\\*[$CHAPTER_TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
+.             ie \\n[#CHAPTER_TITLE_COLOR]=1 \
+.                PRINT \
+\m[\\*[$CHAPTER_TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
+.             el .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]
 .             \}
-.          el \{ .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]] \}
-.\}
 .          RLD \\n[#DOC_LEAD]u \" Just looks better this way
 .       \}
 .    \}
@@ -6294,7 +6168,6 @@
 .    FT R
 .END
 \#
-\#
 .MAC NAMED_DOCHEADER END
 .    DOC_HEADER_QUAD
 .    FAMILY  \\*[$TITLE_FAM]
@@ -6304,13 +6177,10 @@
 .    if !'\\*[$TITLE_1]'' \{\
 .       nr #ARG_NUM 0 1
 .       while \\n[#TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.          ie \\n[#TITLE_COLOR]=1 \{\
+.          ie \\n[#TITLE_COLOR]=1 \
 .             PRINT "\m[\\*[$TITLE_COLOR]]\\*[$TITLE_\\n[#ARG_NUM]]\m[]
+.          el .PRINT "\\*[$TITLE_\\n[#ARG_NUM]]
 .          \}
-.          el \{\
-.             PRINT "\\*[$TITLE_\\n[#ARG_NUM]]
-.          \}
-.\}
 .    \}
 .    if !'\\*[$SUBTITLE]'' \{\
 .       FAMILY  \\*[$SUBTITLE_FAM]
@@ -6318,22 +6188,18 @@
 .       PT_SIZE \\*[$SUBTITLE_PT_SIZE]
 .       nr #ARG_NUM 0 1
 .       while \\n[#SUBTITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.          ie \\n[#SUBTITLE_COLOR]=1 \{\
+.          ie \\n[#SUBTITLE_COLOR]=1 \
 .             PRINT "\m[\\*[$SUBTITLE_COLOR]]\\*[$SUBTITLE_\\n[#ARG_NUM]]\m[]
+.          el .PRINT "\\*[$SUBTITLE_\\n[#ARG_NUM]]
 .          \}
-.          el \{\
-.             PRINT "\\*[$SUBTITLE_\\n[#ARG_NUM]]
-.          \}
-.\}
 .    \}
 .    if !'\\*[$AUTHOR_1]'' \{\
 .       FAMILY  \\*[$AUTHOR_FAM]
 .       FT      \\*[$AUTHOR_FT]
 .       PT_SIZE \\*[$AUTHOR_PT_SIZE]
-.       ie \\n[#ATTRIBUTE_COLOR]=1 \{\
+.       ie \\n[#ATTRIBUTE_COLOR]=1 \
 .          PRINT \&\m[\\*[$ATTRIBUTE_COLOR]]\\*[$ATTRIBUTE_STRING]\m[]
-.       \}
-.       el \{ .PRINT \&\\*[$ATTRIBUTE_STRING] \}
+.       el .PRINT \&\\*[$ATTRIBUTE_STRING]
 .       PRINT_AUTHORS
 .    \}
 .    FAMILY  \\*[$DOCTYPE_FAM]
@@ -6342,94 +6208,99 @@
 .    LS      \\n[#DOCHEADER_LEAD]u
 .    ALD     \\n[#DOCHEADER_LEAD]u
 .    nr #FROM_DOCTYPE 1
-.    if \\n[#DOCTYPE_COLOR]=1 \{\
-.       COLOR \\*[$DOCTYPE_COLOR]
-.    \}
-.    ie \\n[#DOCTYPE_UNDERLINE]=1 \{\
+.    if \\n[#DOCTYPE_COLOR]=1 .COLOR \\*[$DOCTYPE_COLOR]
+.    ie \\n[#DOCTYPE_UNDERLINE]=1 \
 .       UNDERSCORE \\*[$DOCTYPE_UNDERLINE_GAP] "\\*[$DOC_TYPE]"
-.     \}
-.    el \{\
-.       PRINT "\\*[$DOC_TYPE]"
-.    \}
+.    el .PRINT "\\*[$DOC_TYPE]"
 .    COLOR black
 .    FAMILY \\*[$DOC_FAM]
 .    FT R
 .    rr #FROM_DOCTYPE
 .END
 \#
-\#
 \# COVER PAGE
 \# ----------
 \# *Arguments:
-\#   TITLE | DOCTITLE | CHAPTER | CHAPTER_TITLE | CHAPTER+TITLE | COVERTITLE 
...
-\#   ... [ SUBTITLE AUTHOR DOCTYPE COPYRIGHT MISC BLANKPAGE ]
+\#   TITLE | DOCTITLE | CHAPTER | CHAPTER_TITLE | CHAPTER+TITLE | COVERTITLE \
+\#   [ SUBTITLE AUTHOR DOCTYPE COPYRIGHT MISC BLANKPAGE ]
 \# *Function:
 \#   Toggles the number register for each cover page element
 \#   passed as an argument.
 \# *Notes:
 \#   TITLE, DOCTITLE, CHAPTER, CHAPTER_TITLE or CHAPTER+TITLE must
 \#   be supplied.  After that, users may enter as many or as few of
-\#   the arguments as they like; however, the arguments must appear
-\#   in the order given above.  BLANKPAGE, as the final argument,
-\#   inserts a blank page after the cover.
+\#   the arguments as they like.  BLANKPAGE inserts a blank page
+\#   after the cover.
 \#
 \#   If called as DOC_COVER, performs the same operations, but
 \#   applies everything to a doc cover.
 \#
 .MAC COVER END
 .    ie '\\$0'DOC_COVER' \{\
-.       if '\\$\\n[#NUM_ARGS]'BLANKPAGE' \{ .nr #DOCCOVER_BLANKPAGE 1 \}
 .       nr #DOC_COVER 1
-.       if '\\$1'TITLE'         \{ .nr #DOC_COVER_TITLE     1 \}
-.       if '\\$1'DOCTITLE'      \{ .nr #DOC_COVER_TITLE     2 \}
-.       if '\\$1'CHAPTER'       \{ .nr #DOC_COVER_TITLE     3 \}
-.       if '\\$1'CHAPTER_TITLE' \{ .nr #DOC_COVER_TITLE     4 \}
-.       if '\\$1'CHAPTER+TITLE' \{ .nr #DOC_COVER_TITLE     5 \}
-.       if '\\$1'COVERTITLE'    \{ .nr #DOC_COVER_TITLE     6 \}
-.       if '\\$2'SUBTITLE'      \{ .nr #DOC_COVER_SUBTITLE  1 \}
-.       if '\\$2'AUTHOR'        \{ .nr #DOC_COVER_AUTHOR    1 \}
-.       if '\\$2'DOCTYPE'       \{ .nr #DOC_COVER_DOCTYPE   1 \}
-.       if '\\$2'COPYRIGHT'     \{ .nr #DOC_COVER_COPYRIGHT 1 \}
-.       if '\\$2'MISC'          \{ .nr #DOC_COVER_MISC      1 \}
-.       if '\\$3'AUTHOR'        \{ .nr #DOC_COVER_AUTHOR    1 \}
-.       if '\\$3'DOCTYPE'       \{ .nr #DOC_COVER_DOCTYPE   1 \}
-.       if '\\$3'COPYRIGHT'     \{ .nr #DOC_COVER_COPYRIGHT 1 \}
-.       if '\\$3'MISC'          \{ .nr #DOC_COVER_MISC      1 \}
-.       if '\\$4'DOCTYPE'       \{ .nr #DOC_COVER_DOCTYPE   1 \}
-.       if '\\$4'COPYRIGHT'     \{ .nr #DOC_COVER_COPYRIGHT 1 \}
-.       if '\\$4'MISC'          \{ .nr #DOC_COVER_MISC      1 \}
-.       if '\\$5'COPYRIGHT'     \{ .nr #DOC_COVER_COPYRIGHT 1 \}
-.       if '\\$5'MISC'          \{ .nr #DOC_COVER_MISC      1 \}
-.       if '\\$6'MISC'          \{ .nr #DOC_COVER_MISC      1 \}
-.    \}
-.    el \{\
-.       if '\\$\\n[#NUM_ARGS]'BLANKPAGE' \{ .nr #COVER_BLANKPAGE 1 \}
-.       nr #COVER 1
-.       if '\\$1'TITLE'         \{ .nr #COVER_TITLE     1 \}
-.       if '\\$1'DOCTITLE'      \{ .nr #COVER_TITLE     2 \}
-.       if '\\$1'CHAPTER'       \{ .nr #COVER_TITLE     3 \}
-.       if '\\$1'CHAPTER_TITLE' \{ .nr #COVER_TITLE     4 \}
-.       if '\\$1'CHAPTER+TITLE' \{ .nr #COVER_TITLE     5 \}
-.       if '\\$1'COVERTITLE'    \{ .nr #COVER_TITLE     6 \}
-.       if '\\$2'SUBTITLE'      \{ .nr #COVER_SUBTITLE  1 \}
-.       if '\\$2'AUTHOR'        \{ .nr #COVER_AUTHOR    1 \}
-.       if '\\$2'DOCTYPE'       \{ .nr #COVER_DOCTYPE   1 \}
-.       if '\\$2'COPYRIGHT'     \{ .nr #COVER_COPYRIGHT 1 \}
-.       if '\\$2'MISC'          \{ .nr #COVER_MISC      1 \}
-.       if '\\$3'AUTHOR'        \{ .nr #COVER_AUTHOR    1 \}
-.       if '\\$3'DOCTYPE'       \{ .nr #COVER_DOCTYPE   1 \}
-.       if '\\$3'COPYRIGHT'     \{ .nr #COVER_COPYRIGHT 1 \}
-.       if '\\$3'MISC'          \{ .nr #COVER_MISC      1 \}
-.       if '\\$4'DOCTYPE'       \{ .nr #COVER_DOCTYPE   1 \}
-.       if '\\$4'COPYRIGHT'     \{ .nr #COVER_COPYRIGHT 1 \}
-.       if '\\$4'MISC'          \{ .nr #COVER_MISC      1 \}
-.       if '\\$5'COPYRIGHT'     \{ .nr #COVER_COPYRIGHT 1 \}
-.       if '\\$5'MISC'          \{ .nr #COVER_MISC      1 \}
-.       if '\\$6'MISC'          \{ .nr #COVER_MISC      1 \}
+.       ds DOC_ DOC_
+.    \}
+.    el .nr #COVER 1
+.    nr #ARG_NUM 0 1
+.    nr #COVER_ITEM \\n[#NUM_ARGS]  \"loop count
+.    while \\n+[#ARG_NUM]<=\\n[#COVER_ITEM] \{\
+.       if '\\$1'TITLE' \{\
+.          nr #\\*[DOC_]COVER_TITLE 1
+.          shift
+.       \}
+.       if '\\$1'DOCTITLE' \{\
+.          nr #\\*[DOC_]COVER_TITLE 2
+.          shift
+.       \}
+.       if '\\$1'CHAPTER' \{\
+.          nr #\\*[DOC_]COVER_TITLE 3
+.          shift
+.       \}
+.       if '\\$1'CHAPTER_TITLE' \{\
+.          nr #\\*[DOC_]COVER_TITLE 4
+.          shift
+.       \}
+.       if '\\$1'CHAPTER+TITLE' \{\
+.          nr #\\*[DOC_]COVER_TITLE 5
+.          shift
+.       \}
+.       if '\\$1'\\*[DOC_]COVERTITLE' \{\
+.          nr #\\*[DOC_]COVER_TITLE 6
+.          shift
+.       \}
+.       if '\\$1'SUBTITLE' \{\
+.          nr #\\*[DOC_]COVER_SUBTITLE 1
+.          shift
+.       \}
+.       if '\\$1'AUTHOR' \{\
+.          nr #\\*[DOC_]COVER_AUTHOR 1
+.          shift
+.       \}
+.       if '\\$1'DOCTYPE' \{\
+.          nr #\\*[DOC_]COVER_DOCTYPE 1
+.          shift
+.       \}
+.       if '\\$1'COPYRIGHT' \{\
+.          nr #\\*[DOC_]COVER_COPYRIGHT 1
+.          shift
+.       \}
+.       if '\\$1'MISC' \{\
+.          nr #\\*[DOC_]COVER_MISC 1
+.          shift
+.       \}
+.       if '\\$1'PDF_OUTLINE_LABEL' \{\
+.          shift
+.          ds $PDF_\\*[DOC_]COVER_LABEL \\$1
+.          shift
+.       \}
+.       if '\\$1'BLANKPAGE' \{\
+.          nr #\\*[DOC_]COVER_BLANKPAGE 1
+.          shift
 .    \}
+.    \}
+.    if '\\$0'DOC_COVER' .rm DOC_
 .END
 \#
-\#
 .MAC COVERTITLE END
 .    ie '\\$0'DOC_COVERTITLE' \{\ 
 .       ie \\n[#NUM_ARGS]=0 \{\
@@ -6437,7 +6308,7 @@
 .             nr #ITEM 0 1
 .             while \\n[#DOC_COVER_TITLE_NUM]>\\n[#ITEM] \{\
 .                rm $DOC_COVER_TITLE_\\n+[#ITEM]
-.\}
+.             \}
 .             rr #DOC_COVER_TITLE_NUM
 .             rm $DOC_COVER_TITLE
 .          \}
@@ -6445,8 +6316,9 @@
 .       el \{\
 .          nr #DOC_COVER_TITLE_NUM 0 1
 .          while \\n[#NUM_ARGS]>\\n[#DOC_COVER_TITLE_NUM] \{\
-.             ds $DOC_COVER_TITLE_\\n+[#DOC_COVER_TITLE_NUM] 
\\$\\n[#DOC_COVER_TITLE_NUM]
-.\}
+.             ds \
+$DOC_COVER_TITLE_\\n+[#DOC_COVER_TITLE_NUM] \\$\\n[#DOC_COVER_TITLE_NUM]
+.          \}
 .          ds $DOC_COVER_TITLE \\$*
 .       \}
 .    \}
@@ -6456,7 +6328,7 @@
 .             nr #ITEM 0 1
 .             while \\n[#COVER_TITLE_NUM]>\\n[#ITEM] \{\
 .                rm $COVER_TITLE_\\n+[#ITEM]
-.\}
+.             \}
 .             rr #COVER_TITLE_NUM
 .             rm $COVER_TITLE
 .          \}
@@ -6465,13 +6337,13 @@
 .          nr #COVER_TITLE_NUM 0 1
 .          while \\n[#NUM_ARGS]>\\n[#COVER_TITLE_NUM] \{\
 .             ds $COVER_TITLE_\\n+[#COVER_TITLE_NUM] \\$\\n[#COVER_TITLE_NUM]
-.\}
+.          \}
 .          ds $COVER_TITLE \\$*
+.\" .          if \\n[#DOCTITLE_NUM]=0 .PDF_TITLE \\*[$COVER_TITLE]
 .       \}
 .    \}
 .END
 \#
-\#
 \# COVER PAGE LEADING
 \# ------------------
 \# *Arguments:
@@ -6485,26 +6357,21 @@
 \#   Default is +0, i.e. same as DOC_LEAD.
 \#
 .MAC COVER_LEAD END
-.    ie '\\$0'DOC_COVER_LEAD' \{\
-.       ds $DOC_COVER_LEAD_ADJ \\$1
-.    \}
-.    el \{\
-.       ds $COVER_LEAD_ADJ \\$1
-.    \}
+.    ie '\\$0'DOC_COVER_LEAD' .ds $DOC_COVER_LEAD_ADJ \\$1
+.    el .ds $COVER_LEAD_ADJ \\$1
 .END
 \#
 \# MISCs get treated similarly to QUOTEs and BLOCKQUOTEs with respect to
 \# leading
 \#
 .MAC MISC_AUTOLEAD END
-.    if '\\$0'DOC_COVER_MISC_AUTOLEAD' \{ .nr #DOC_COVER_MISC_AUTOLEAD \\$1 \}
-.    if '\\$0'COVER_MISC_AUTOLEAD'     \{ .nr #COVER_MISC_AUTOLEAD \\$1 \}
+.    if '\\$0'DOC_COVER_MISC_AUTOLEAD' .nr #DOC_COVER_MISC_AUTOLEAD \\$1
+.    if '\\$0'COVER_MISC_AUTOLEAD'     .nr #COVER_MISC_AUTOLEAD \\$1
 .END
 \#
 .ALIAS DOC_COVER_MISC_AUTOLEAD  MISC_AUTOLEAD
 .ALIAS COVER_MISC_AUTOLEAD      MISC_AUTOLEAD
 \#
-\#
 \# COVER PAGE START POSITION
 \# -------------------------
 \# *Arguments:
@@ -6520,15 +6387,10 @@
 \#   down the page (setup in DO_COVER).
 \#
 .MAC COVER_ADVANCE END
-.    ie '\\$0'DOC_COVER_ADVANCE' \{\
-.       nr #DOC_COVER_START_POS (\\$1)
-.    \}
-.    el \{\
-.       nr #COVER_START_POS (\\$1)
-.    \}
+.    ie '\\$0'DOC_COVER_ADVANCE' .nr #DOC_COVER_START_POS (\\$1)
+.    el .nr #COVER_START_POS (\\$1)
 .END
 \#
-\#
 \# UNDERLINE CONTROL
 \# -----------------
 \# *Arguments:
@@ -6543,17 +6405,24 @@
 \#
 .MAC _UNDERLINE END
 .    ie '\\$1'' \{\
-.       if '\\$0'BIBLIOGRAPHY_STRING_UNDERLINE'  \{ .nr #BIB_STRING_UNDERLINE 
1 \}
-.       if '\\$0'BIBLIOGRAPHY_STRING_UNDERSCORE' \{ .nr #BIB_STRING_UNDERLINE 
1 \}
-.       if '\\$0'COVER_UNDERLINE'                \{ .nr #COVER_UNDERLINE      
1 \}
-.       if '\\$0'DOC_COVER_UNDERLINE'            \{ .nr #DOCCOVER_UNDERLINE   
1 \}
-.       if '\\$0'DOCTYPE_UNDERLINE'              \{ .nr #DOCTYPE_UNDERLINE    
1 \}
-.       if '\\$0'HEAD_UNDERLINE'                 \{ .nr #HEAD_UNDERLINE       
1 \}
-.       if '\\$0'HEAD_UNDERSCORE'                \{ .nr #HEAD_UNDERLINE       
1 \}
-.       if '\\$0'ENDNOTE_STRING_UNDERLINE'       \{ .nr #EN_STRING_UNDERLINE  
1 \}
-.       if '\\$0'ENDNOTE_STRING_UNDERSCORE'      \{ .nr #EN_STRING_UNDERLINE  
1 \}
-.       if '\\$0'ENDNOTE_TITLE_UNDERLINE'        \{ .nr #EN_TITLE_UNDERLINE   
1 \}
-.       if '\\$0'ENDNOTE_TITLE_UNDERSCORE'       \{ .nr #EN_TITLE_UNDERLINE   
1 \}
+.       if '\\$0'BIBLIOGRAPHY_STRING_UNDERLINE' \
+.          nr #BIB_STRING_UNDERLINE 1
+.       if '\\$0'BIBLIOGRAPHY_STRING_UNDERSCORE' \
+.          nr #BIB_STRING_UNDERLINE 1
+.       if '\\$0'COVER_UNDERLINE' \
+.          nr #COVER_UNDERLINE 1
+.       if '\\$0'DOC_COVER_UNDERLINE' \
+.          nr #DOC_COVER_UNDERLINE 1
+.       if '\\$0'DOCTYPE_UNDERLINE' \
+.          nr #DOCTYPE_UNDERLINE 1
+.       if '\\$0'ENDNOTE_STRING_UNDERLINE' \
+.          nr #EN_STRING_UNDERLINE 1
+.       if '\\$0'ENDNOTE_STRING_UNDERSCORE' \
+.          nr #EN_STRING_UNDERLINE 1
+.       if '\\$0'ENDNOTE_TITLE_UNDERLINE' \
+.          nr #EN_TITLE_UNDERLINE 1
+.       if '\\$0'ENDNOTE_TITLE_UNDERSCORE' \
+.          nr #EN_TITLE_UNDERLINE 1
 .    \}
 .    el \{\
 .       ie \\n[#NUM_ARGS]=1 \{\
@@ -6561,40 +6430,45 @@
 .          substring $ARG -1
 .          ie \B'\\*[$ARG]' \{\
 .             if !\\n[#PRINT_STYLE]=1 \{\
-.                if '\\$0'BIBLIOGRAPHY_STRING_UNDERLINE'  \{ 
.BIBLIOGRAPHY_STRING_UNDERLINE_WEIGHT \\$1 \}
-.                if '\\$0'BIBLIOGRAPHY_STRING_UNDERSCORE' \{ 
.BIBLIOGRAPHY_STRING_UNDERLINE_WEIGHT \\$1 \}
-.                if '\\$0'COVER_UNDERLINE'                \{ 
.COVER_UNDERLINE_WEIGHT               \\$1 \}
-.                if '\\$0'DOC_COVER_UNDERLINE'            \{ 
.DOCCOVER_UNDERLINE_WEIGHT            \\$1 \}
-.                if '\\$0'DOCTYPE_UNDERLINE'              \{ 
.DOCTYPE_UNDERLINE_WEIGHT             \\$1 \}
-.                if '\\$0'HEAD_UNDERLINE'                 \{ 
.HEAD_UNDERLINE_WEIGHT                \\$1 \}
-.                if '\\$0'HEAD_UNDERSCORE'                \{ 
.HEAD_UNDERLINE_WEIGHT                \\$1 \}
-.                if '\\$0'ENDNOTE_STRING_UNDERLINE'       \{ 
.ENDNOTE_STRING_UNDERLINE_WEIGHT      \\$1 \}
-.                if '\\$0'ENDNOTE_STRING_UNDERSCORE'      \{ 
.ENDNOTE_STRING_UNDERLINE_WEIGHT      \\$1 \}
-.                if '\\$0'ENDNOTE_TITLE_UNDERLINE'        \{ 
.ENDNOTE_TITLE_UNDERLINE_WEIGHT       \\$1 \}
-.                if '\\$0'ENDNOTE_TITLE_UNDERSCORE'       \{ 
.ENDNOTE_TITLE_UNDERLINE_WEIGHT       \\$1 \}
+.                if '\\$0'BIBLIOGRAPHY_STRING_UNDERLINE' \
+.                   BIBLIOGRAPHY_STRING_UNDERLINE_WEIGHT \\$1
+.                if '\\$0'BIBLIOGRAPHY_STRING_UNDERSCORE' \
+.                   BIBLIOGRAPHY_STRING_UNDERLINE_WEIGHT \\$1
+.                if '\\$0'COVER_UNDERLINE' \
+.                   COVER_UNDERLINE_WEIGHT \\$1
+.                if '\\$0'DOC_COVER_UNDERLINE' \
+.                   DOC_COVER_UNDERLINE_WEIGHT \\$1
+.                if '\\$0'DOCTYPE_UNDERLINE' \
+.                   DOCTYPE_UNDERLINE_WEIGHT \\$1
+.                if '\\$0'ENDNOTE_STRING_UNDERLINE' \
+.                   ENDNOTE_STRING_UNDERLINE_WEIGHT \\$1
+.                if '\\$0'ENDNOTE_STRING_UNDERSCORE' \
+.                   ENDNOTE_STRING_UNDERLINE_WEIGHT \\$1
+.                if '\\$0'ENDNOTE_TITLE_UNDERLINE' \
+.                   ENDNOTE_TITLE_UNDERLINE_WEIGHT \\$1
+.                if '\\$0'ENDNOTE_TITLE_UNDERSCORE' \
+.                   ENDNOTE_TITLE_UNDERLINE_WEIGHT \\$1
 .             \}
 .          \}
 .          el \{\
 .             if '\\$0'BIBLIOGRAPHY_STRING_UNDERLINE' \{\
-.                ie '\\$1'DOUBLE' \{ .nr #BIB_STRING_UNDERLINE 2 \}
-.                el \{ .nr #BIB_STRING_UNDERLINE 0 \}
+.                ie '\\$1'DOUBLE' .nr #BIB_STRING_UNDERLINE 2
+.                el .nr #BIB_STRING_UNDERLINE 0
 .             \}
 .             if '\\$0'BIBLIOGRAPHY_STRING_UNDERSCORE' \{\
-.                ie '\\$1'DOUBLE' \{ .nr #BIB_STRING_UNDERLINE 2 \}
-.                el \{ .nr #BIB_STRING_UNDERLINE 0 \}
+.                ie '\\$1'DOUBLE' .nr #BIB_STRING_UNDERLINE 2
+.                el .nr #BIB_STRING_UNDERLINE 0
 .             \}
-.             if '\\$0'COVER_UNDERLINE'          \{ .nr #COVER_UNDERLINE     0 
\}
-.             if '\\$0'DOC_COVER_UNDERLINE'      \{ .nr #DOCCOVER_UNDERLINE  0 
\}
-.             if '\\$0'DOCTYPE_UNDERLINE'        \{ .nr #DOCTYPE_UNDERLINE   0 
\}
-.             if '\\$0'HEAD_UNDERLINE'           \{ .nr #HEAD_UNDERLINE      0 
\}
-.             if '\\$0'HEAD_UNDERSCORE'          \{ .nr #HEAD_UNDERLINE      0 
\}
+.             if '\\$0'COVER_UNDERLINE'     .nr #COVER_UNDERLINE 0
+.             if '\\$0'DOC_COVER_UNDERLINE' .nr #DOC_COVER_UNDERLINE 0
+.             if '\\$0'DOCTYPE_UNDERLINE'   .nr #DOCTYPE_UNDERLINE 0
 .             if '\\$0'ENDNOTE_STRING_UNDERLINE' \{\
-.                ie '\\$1'DOUBLE' \{ .nr #EN_STRING_UNDERLINE 2 \}
-.                el \{ .nr #EN_STRING_UNDERLINE 0 \}
+.                ie '\\$1'DOUBLE' .nr #EN_STRING_UNDERLINE 2
+.                el .nr #EN_STRING_UNDERLINE 0
 .             \}
 .             if '\\$0'ENDNOTE_STRING_UNDERSCORE' \{\
-.                ie '\\$1'DOUBLE' \{ .nr #EN_STRING_UNDERLINE 2 \}
-.                el \{ .nr #EN_STRING_UNDERLINE 0 \}
+.                ie '\\$1'DOUBLE' .nr #EN_STRING_UNDERLINE 2
+.                el .nr #EN_STRING_UNDERLINE 0
 .             \}
 .          \}
 .       \}
@@ -6621,12 +6495,8 @@
 .                   shift
 .                \}
 .                BIBLIOGRAPHY_STRING_UNDERLINE_WEIGHT \\$1
-.                if !'\\$2'' \{\
-.                   ds $BIB_STRING_UNDERLINE_GAP \\$2
-.                \}
-.                if !'\\$3'' \{\
-.                   ds $BIB_STRING_RULE_GAP \\$3
-.                \}
+.                if !'\\$2'' .ds $BIB_STRING_UNDERLINE_GAP \\$2
+.                if !'\\$3'' .ds $BIB_STRING_RULE_GAP \\$3
 .             \}
 .             if '\\$0'COVER_UNDERLINE' \{\
 .                nr #COVER_UNDERLINE 1
@@ -6634,27 +6504,17 @@
 .                ds $COVER_UNDERLINE_GAP \\$2
 .             \}
 .             if '\\$0'DOC_COVER_UNDERLINE' \{\
-.                nr #DOCCOVER_UNDERLINE 1
-.                DOCCOVER_UNDERLINE_WEIGHT  \\$1
-.                ds $DOCCOVER_UNDERLINE_GAP \\$2
+.                nr #DOC_COVER_UNDERLINE 1
+.                DOC_COVER_UNDERLINE_WEIGHT \\$1
+.                ds $DOC_COVER_UNDERLINE_GAP \\$2
 .             \}
 .             if '\\$0'DOCTYPE_UNDERLINE' \{\
 .                nr #DOCTYPE_UNDERLINE 1
 .                DOCTYPE_UNDERLINE_WEIGHT  \\$1
 .                ds $DOCTYPE_UNDERLINE_GAP \\$2
 .             \}
-.             if '\\$0'HEAD_UNDERLINE' \{\
-.                nr #HEAD_UNDERLINE 1
-.                HEAD_UNDERLINE_WEIGHT  \\$1
-.                ds $HEAD_UNDERLINE_GAP \\$2
-.             \}
-.             if '\\$0'HEAD_UNDERSCORE' \{\
-.                nr #HEAD_UNDERLINE 1
-.                HEAD_UNDERLINE_WEIGHT  \\$1
-.                ds $HEAD_UNDERLINE_GAP \\$2
-.             \}
-\# ENDNOTE_STRING_UNDERLINE and ENDNOTE_STRING_UNDERSCORE are identical;
-\# the _UNDERSCORE version is left in for backward compatibility.
+.\" ENDNOTE_STRING_UNDERLINE and ENDNOTE_STRING_UNDERSCORE are identical;
+.\" _UNDERSCORE left in for backward compatibility.
 .             if '\\$0'ENDNOTE_STRING_UNDERLINE' \{\
 .                nr #EN_STRING_UNDERLINE 1
 .                if '\\$1'DOUBLE' \{\
@@ -6662,12 +6522,8 @@
 .                   shift
 .                \}
 .                ENDNOTE_STRING_UNDERLINE_WEIGHT \\$1
-.                if !'\\$2'' \{\
-.                   ds $EN_STRING_UNDERLINE_GAP \\$2
-.                \}
-.                if !'\\$3'' \{\
-.                   ds $EN_STRING_RULE_GAP \\$3
-.                \}
+.                if !'\\$2'' .ds $EN_STRING_UNDERLINE_GAP \\$2
+.                if !'\\$3'' .ds $EN_STRING_RULE_GAP \\$3
 .             \}
 .             if '\\$0'ENDNOTE_STRING_UNDERSCORE' \{\ 
 .                nr #EN_STRING_UNDERLINE 1
@@ -6676,15 +6532,11 @@
 .                   shift
 .                \}
 .                ENDNOTE_STRING_UNDERLINE_WEIGHT \\$1
-.                if !'\\$2'' \{\
-.                   ds $EN_STRING_UNDERLINE_GAP \\$2
-.                \}
-.                if !'\\$3'' \{\
-.                   ds $EN_STRING_RULE_GAP \\$3
-.                \}
+.                if !'\\$2'' .ds $EN_STRING_UNDERLINE_GAP \\$2
+.                if !'\\$3'' .ds $EN_STRING_RULE_GAP \\$3
 .             \}
-\# ENDNOTE_TITLE_UNDERLINE and ENDNOTE_TITLE_UNDERSCORE are identical;
-\# the _UNDERSCORE version is left in for backward compatibility.
+.\" ENDNOTE_TITLE_UNDERLINE and ENDNOTE_TITLE_UNDERSCORE are identical;
+.\" _UNDERSCORE version left in for backward compatibility.
 .             if '\\$0'ENDNOTE_TITLE_UNDERLINE' \{\
 .                nr #ENDNOTE_TITLE_UNDERLINE 1
 .                ENDNOTE_TITLE_UNDERLINE_WEIGHT  \\$1
@@ -6705,14 +6557,11 @@
 .ALIAS COVER_UNDERLINE                _UNDERLINE
 .ALIAS DOC_COVER_UNDERLINE            _UNDERLINE
 .ALIAS DOCTYPE_UNDERLINE              _UNDERLINE
-.ALIAS HEAD_UNDERLINE                 _UNDERLINE
-.ALIAS HEAD_UNDERSCORE                _UNDERLINE
 .ALIAS ENDNOTE_STRING_UNDERLINE       _UNDERLINE
 .ALIAS ENDNOTE_STRING_UNDERSCORE      _UNDERLINE
 .ALIAS ENDNOTE_TITLE_UNDERLINE        _UNDERLINE
 .ALIAS ENDNOTE_TITLE_UNDERSCORE       _UNDERLINE
 \#
-\#
 \# COVERS - WHETHER TO PRINT
 \# -------------------------
 \# *Arguments:
@@ -6744,7 +6593,6 @@
 .    \}
 .END
 \#
-\#
 \# COVER_COUNTS_PAGES
 \# ------------------
 \# *Arguments:
@@ -6756,18 +6604,17 @@
 \#
 .MAC COVER_COUNTS_PAGES END
 .    if '\\$0'DOC_COVER_COUNTS_PAGES' \{\
-.       ie '\\$1'' \{ .nr #DOCCOVERS_COUNT 1 \}
-.       el \{ .rr #DOCCOVERS_COUNT \}
+.       ie '\\$1'' .nr #DOCCOVERS_COUNT 1
+.       el .rr #DOCCOVERS_COUNT
 .       return
 .    \}
 .    if '\\$0'COVER_COUNTS_PAGES' \{\
-.       ie '\\$1'' \{ .nr #COVERS_COUNT 1 \}
-.       el \{ .rr #COVERS_COUNT \}
+.       ie '\\$1'' .nr #COVERS_COUNT 1
+.       el .rr #COVERS_COUNT
 .       return
 .    \}
 .END
 \#
-\#
 .MAC DO_COVER END
 .    nr #DOING_COVER 1
 .    ev COVER
@@ -6789,665 +6636,432 @@
 .       nr #COLUMNS_WERE_ON 1
 .       rr #COLUMNS
 .    \}
-.\" Doc cover
+.    ds PDF_BM
 .    ie '\\$0'DO_DOC_COVER' \{\
-.       if !r#DOC_COVER_START_POS \{\
-.          nr #DOC_COVER_START_POS \\n[#PAGE_LENGTH]/3
+.       ds  DOC_  DOC_
+.       nr #DOC_COVER_DONE 1
+.       if '\\*[$PDF_DOC_COVER_LABEL]'' \
+.          ds $PDF_DOC_COVER_LABEL Cover:
+.    \}
+.    el \{\
+.       if '\\*[$PDF_COVER_LABEL]'' .ds $PDF_COVER_LABEL Title Page:
 .       \}
+.    if !r#\\*[DOC_]COVER_START_POS \
+.       nr #\\*[DOC_]COVER_START_POS \\n[#PAGE_LENGTH]/3
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          ie \\n[#SINGLE_SPACE]=1 \{ .vs \\n[#DOC_LEAD]u*2u \}
-.          el \{ .vs \\n[#DOC_LEAD]u \}
+.       ie \\n[#SINGLE_SPACE]=1 .vs \\n[#DOC_LEAD]u*2u
+.       el .vs \\n[#DOC_LEAD]u
 .       \}
 .       if \\n[#PRINT_STYLE]=2 \{\
-.          LS \\n[#DOC_LEAD]u\\*[$DOC_COVER_LEAD_ADJ]
-.          nr #DOC_COVER_LEAD \\n[#LEAD]
+.       LS \\n[#DOC_LEAD]u\\*[$\\*[DOC_]COVER_LEAD_ADJ]
+.       nr #\\*[DOC_]COVER_LEAD \\n[#LEAD]
 .       \}
-.       PRINT \&
-.       sp |\\n[#DOC_COVER_START_POS]u-1v
-.       if \\n[#DOC_COVER_COLOR]=1 \{\
+.    if \\n[.ns] .rs
+.    if '\\$0'DO_COVER' \{\
+.       if \\n[TOC.RELOCATE]==5 \{\
+.          if !rTOC_BH .TOC_BEFORE_HERE
+.       \}
+.    \}
+.    if '\\$0'DO_DOC_COVER' \{\
+.       if \\n[TOC.RELOCATE]==3 \{\
+.          if !rTOC_BH .TOC_BEFORE_HERE
+.       \}
+.    \}
+.    RV_HARD_SET_MARGINS
+.    sp |\\n[#\\*[DOC_]COVER_START_POS]u-1v
+.    if \\n[#\\*[DOC_]COVER_COLOR]=1 \{\
 .          nf
-\m[\\*[$DOC_COVER_COLOR]]
+\m[\\*[$\\*[DOC_]COVER_COLOR]]
 .          EOL
 .       \}
-.       DOC_COVER_H_POS
-.       FAMILY  \\*[$DOC_COVER_TITLE_FAM]
-.       FT      \\*[$DOC_COVER_TITLE_FT]
-.       PT_SIZE \\*[$DOC_COVER_TITLE_PT_SIZE]
-.       LS      \\n[#DOC_COVER_LEAD]u
-.       if \\n[#PRINT_STYLE]=1 \{ .TYPEWRITER \}
-.       if \\n[#DOC_COVER_TITLE]=1 \{\
+.    \\*[DOC_]COVER_H_POS
+.    fam \\*[$\\*[DOC_]COVER_TITLE_FAM]
+.    ft  \\*[$\\*[DOC_]COVER_TITLE_FT]
+.    ps  \\*[$\\*[DOC_]COVER_TITLE_PT_SIZE]
+.    ie \\n[#PRINT_STYLE]=1 \{\
+.       ie \\n[#SINGLE_SPACE]=1 \{ .vs \\n[#DOC_LEAD]u*2u \}
+.       el \{ .vs \\n[#DOC_LEAD]u \}
+.    \}
+.    el .vs \\n[#\\*[DOC_]COVER_LEAD]u
+.    if \\n[#PRINT_STYLE]=1 .TYPEWRITER
+.    if \\n[#\\*[DOC_]COVER_TITLE] \{\
+.       nr PDFHREF.VIEW.LEADING.H \\n[PDFHREF.VIEW.LEADING]
+.       nr PDFHREF.VIEW.LEADING   \\n[nl]u-1v-1000u
+.    \}
+.    if \\n[#\\*[DOC_]COVER_TITLE]=1 \{\
 .          ie \\n[#PRINT_STYLE]=1 \{\
 .             CAPS
 .             nr #ARG_NUM 0 1
 .             while \\n[#TITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                UNDERSCORE "\\*[$TITLE_\\n[#ARG_NUM]]"
-.\}
+.             if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.             as PDF_BM \\*[$TITLE_\\n[#ARG_NUM]]
+.          \}
 .             CAPS OFF
 .          \}
 .          el \{\
 .          nr #ARG_NUM 0 1
 .          while \\n[#TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                PRINT 
"\m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$TITLE_\\n[#ARG_NUM]]\m[]
-.             \}
-.             el \{\
+.             ie \\n[#\\*[DOC_]COVER_TITLE_COLOR]=1 \
+.                PRINT \
+\m[\\*[$\\*[DOC_]COVER_TITLE_COLOR]]\\*[$TITLE_\\n[#ARG_NUM]]\m[]
+.             el \
 .                PRINT "\\*[$TITLE_\\n[#ARG_NUM]]
+.             if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.             as PDF_BM \\*[$TITLE_\\n[#ARG_NUM]]
 .             \}
-.\}
 .          \}
+.       PDF_BOOKMARK 1 \\*[$PDF_\\*[DOC_]COVER_LABEL] \\*[PDF_BM]
+.\" .          PDF_TITLE \\*[PDF_BM]
 .       \}
-.       if \\n[#DOC_COVER_TITLE]=2 \{\
+.    if \\n[#\\*[DOC_]COVER_TITLE]=2 \{\
 .          ie \\n[#PRINT_STYLE]=1 \{\
 .             CAPS
 .             nr #ARG_NUM 0 1
 .             while \\n[#DOCTITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                UNDERSCORE "\\*[$DOC_TITLE_\\n[#ARG_NUM]]"
-.\}
+.             UNDERSCORE "\\*[$\\*[DOC_]TITLE_\\n[#ARG_NUM]]"
+.             if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.             as PDF_BM \\*[$\\*[DOC_]TITLE_\\n[#ARG_NUM]]
+.          \}
 .             CAPS OFF
 .          \}
 .          el \{\
 .          nr #ARG_NUM 0 1
 .          while \\n[#DOCTITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                PRINT 
\m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$DOC_TITLE_\\n[#ARG_NUM]]\m[]
+.             ie \\n[#\\*[DOC_]COVER_TITLE_COLOR]=1 \
+.                PRINT \
+\m[\\*[$\\*[DOC_]COVER_TITLE_COLOR]]\\*[$\\*[DOC_]TITLE_\\n[#ARG_NUM]]\m[]
+.             el .PRINT \\*[$\\*[DOC_]TITLE_\\n[#ARG_NUM]]
+.             if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.             as PDF_BM \\*[$\\*[DOC_]TITLE_\\n[#ARG_NUM]]
 .             \}
-.             el \{ .PRINT \\*[$DOC_TITLE_\\n[#ARG_NUM]] \}
-.\}
 .          \}
+.       PDF_BOOKMARK 1 \\*[$PDF_\\*[DOC_]COVER_LABEL] \\*[PDF_BM]
+.\" .          PDF_TITLE \\*[PDF_BM]
 .       \}
-.       if \\n[#DOC_COVER_TITLE]=3 \{\
+.    if \\n[#\\*[DOC_]COVER_TITLE]=3 \{\
 .          ie \\n[#PRINT_STYLE]=1 \{\
 .             CAPS
 .             PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER]
 .             CAPS OFF
 .          \}
 .          el \{\
-.             ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                PRINT \m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$CHAPTER_STRING] 
\\*[$CHAPTER]\m[]
-.             \}
-.             el \{ .PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER] \}
-.          \}
+.          ie \\n[#\\*[DOC_]COVER_TITLE_COLOR]=1 \
+.             PRINT \
+\m[\\*[$\\*[DOC_]COVER_TITLE_COLOR]]\\*[$CHAPTER_STRING] \\*[$CHAPTER]\m[]
+.          el .PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER]
+.       \}
+.       PDF_BOOKMARK 1 \
+\\*[$PDF_\\*[DOC_]COVER_LABEL] \\*[$CHAPTER_STRING] \\*[$CHAPTER]
+.\" .          PDF_TITLE \\*[$CHAPTER_STRING] \\*[$CHAPTER]
 .       \}
-.       if \\n[#DOC_COVER_TITLE]=4 \{\
+.    if \\n[#\\*[DOC_]COVER_TITLE]=4 \{\
 .          ie \\n[#PRINT_STYLE]=1 \{\
 .             CAPS
 .             nr #ARG_NUM 0 1
-.                ie \\n[#SINGLE_SPACE]=0 \{\
-.                   vs \\n[#DOC_LEAD]u/2u
-.                \}
-.                el \{\
-.                   vs \\n[#DOC_LEAD]u
-.                \}
+.             ie \\n[#SINGLE_SPACE]=0 .vs \\n[#DOC_LEAD]u/2u
+.             el .vs \\n[#DOC_LEAD]u
 .                sp
 .             while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                UNDERSCORE "\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]"
-.\}
+.             if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.             as PDF_BM \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]
+.          \}
 .             CAPS OFF
-.             if \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u \}
+.          if \\n[#SINGLE_SPACE]=0 .vs \\n[#DOC_LEAD]u
 .          \}
 .          el \{\
 .          nr #ARG_NUM 0 1
 .          while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                PRINT 
\m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
+.             ie \\n[#\\*[DOC_]COVER_TITLE_COLOR]=1 \
+.                PRINT \
+\m[\\*[$\\*[DOC_]COVER_TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
+.             el .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]
+.             if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.             as PDF_BM \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]
 .             \}
-.             el \{ .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]] \}
-.\}
 .          \}
+.       PDF_BOOKMARK 1 \\*[$PDF_\\*[DOC_]COVER_LABEL] \\*[PDF_BM]
+.\" .          PDF_TITLE \\*[PDF_BM]
 .       \}
-.       if \\n[#DOC_COVER_TITLE]=5 \{\
+.    if \\n[#\\*[DOC_]COVER_TITLE]=5 \{\
 .          ie \\n[#PRINT_STYLE]=1 \{\
 .             CAPS
 .             PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER]
 .             CAPS OFF
 .          \}
 .          el \{\
-.             ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                PRINT \m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$CHAPTER_STRING] 
\\*[$CHAPTER]\m[]
-.             \}
-.             el \{ .PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER] \}
+.          ie \\n[#\\*[DOC_]COVER_TITLE_COLOR]=1 \
+.             PRINT \
+\m[\\*[$\\*[DOC_]COVER_TITLE_COLOR]]\\*[$CHAPTER_STRING] \\*[$CHAPTER]\m[]
+.          el .PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER]
 .          \}
 .          if !'\\*[$CHAPTER_TITLE_1]'' \{\
 .             ie \\n[#PRINT_STYLE]=1 \{\
-.                ie \\n[#SINGLE_SPACE]=0 \{\
-.                   vs \\n[#DOC_LEAD]u/2u
-.                \}
-.                el \{\
-.                   vs \\n[#DOC_LEAD]u
-.                \}
+.             ie \\n[#SINGLE_SPACE]=0 .vs \\n[#DOC_LEAD]u/2u
+.             el .vs \\n[#DOC_LEAD]u
 .                sp
 .                nr #ARG_NUM 0 1
 .                while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                   UNDERSCORE "\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]"
-.\}
-.                if \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u \}
+.                if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.                as PDF_BM \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]
+.             \}
+.             if \\n[#SINGLE_SPACE]=0 .vs \\n[#DOC_LEAD]u
 .             \}
 .             el \{\
-.                fam \\*[$DOC_COVER_CHAPTER_TITLE_FAM]
-.                ft  \\*[$DOC_COVER_CHAPTER_TITLE_FT]
-.                ps  \\*[$DOC_COVER_CHAPTER_TITLE_PT_SIZE]
-.                nr #ARG_NUM 0 1
+.             fam \\*[$\\*[DOC_]COVER_CHAPTER_TITLE_FAM]
+.             ft  \\*[$\\*[DOC_]COVER_CHAPTER_TITLE_FT]
+.             ps  \\*[$\\*[DOC_]COVER_CHAPTER_TITLE_PT_SIZE]
 .                ALD \\n[.v]u/4u \"Put a little space before the chapter title
+.             nr #ARG_NUM 0 1
 .                while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                   ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                      PRINT 
\m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
+.                ie \\n[#\\*[DOC_]COVER_TITLE_COLOR]=1 \
+.                   PRINT \
+\m[\\*[$\\*[DOC_]COVER_TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
+.                el .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]
+.                if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.                as PDF_BM \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]
 .                   \}
-.                   el \{ .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]] \}
-.\}
 .             \}
 .          \}
+.       PDF_BOOKMARK 1 \\*[$PDF_\\*[DOC_]COVER_LABEL] \\*[PDF_BM]
+.\" .          PDF_TITLE \\*[PDF_BM]
 .       \}
-.       if \\n[#DOC_COVER_TITLE]=6 \{\
+.    if \\n[#\\*[DOC_]COVER_TITLE]=6 \{\
 .          ie \\n[#PRINT_STYLE]=1 \{\
 .             CAPS
 .             nr #ARG_NUM 0 1
-.             while \\n[#DOC_COVER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                UNDERSCORE "\\*[$DOC_COVER_TITLE_\\n[#ARG_NUM]]"
-.\}
+.          while \\n[#\\*[DOC_]COVER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
+.             UNDERSCORE "\\*[$\\*[DOC_]COVER_TITLE_\\n[#ARG_NUM]]"
+.                if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.                as PDF_BM \\*[$\\*[DOC_]COVER_TITLE_\\n[#ARG_NUM]]
+.          \}
 .             CAPS OFF
 .          \}
 .          el \{\
 .             nr #ARG_NUM 0 1
-.             while \\n[#DOC_COVER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                PRINT 
\m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$DOC_COVER_TITLE_\\n[#ARG_NUM]]\m[]
-.             \}
-.             el \{ .PRINT \\*[$DOC_COVER_TITLE_\\n[#ARG_NUM]] \}
-.\}
-.          \}
+.          while \\n[#\\*[DOC_]COVER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
+.             ie \\n[#\\*[DOC_]COVER_TITLE_COLOR]=1 \
+.                PRINT \
+\m[\\*[$\\*[DOC_]COVER_TITLE_COLOR]]\
+\\*[$\\*[DOC_]COVER_TITLE_\\n[#ARG_NUM]]\m[]
+.             el .PRINT \\*[$\\*[DOC_]COVER_TITLE_\\n[#ARG_NUM]]
+.             if \\n[#ARG_NUM]>1 .as PDF_BM " \"
+.             as PDF_BM \\*[$\\*[DOC_]COVER_TITLE_\\n[#ARG_NUM]]
+.          \}
+.       \}
+.       PDF_BOOKMARK 1 \\*[$PDF_\\*[DOC_]COVER_LABEL] \\*[PDF_BM]
+.\" .          PDF_TITLE \\*[PDF_BM]
+.    \}
+.    if \\n[#\\*[DOC_]COVER_TITLE] \{\
+.      nr PDFHREF.VIEW.LEADING \\n[PDFHREF.VIEW.LEADING.H]
+.      rr PDFHREF.VIEW.LEADING.H
 .       \}
 .       if !\\n[#DOC_TYPE]=2 \{\
-.          if \\n[#DOC_COVER_SUBTITLE]=1 \{\
-.             fam \\*[$DOC_COVER_SUBTITLE_FAM]
-.             ft  \\*[$DOC_COVER_SUBTITLE_FT]
-.             ps  \\*[$DOC_COVER_SUBTITLE_PT_SIZE]
+.       if \\n[#\\*[DOC_]COVER_SUBTITLE]=1 \{\
+.          fam \\*[$\\*[DOC_]COVER_SUBTITLE_FAM]
+.          ft  \\*[$\\*[DOC_]COVER_SUBTITLE_FT]
+.          ps  \\*[$\\*[DOC_]COVER_SUBTITLE_PT_SIZE]
 .             if \\n[#PRINT_STYLE]=1 \{\
 .                TYPEWRITER
-.                ie \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u/2u \}
-.                el \{ .vs \\n[#DOC_LEAD]u \}
+.             ie \\n[#SINGLE_SPACE]=0 .vs \\n[#DOC_LEAD]u/2u
+.             el .vs \\n[#DOC_LEAD]u
 .                sp
 .             \}
-.       if \\n[#DOC_COVER]=1 \{\
-.          ie !'\\*[$SUBTITLE_DOCCOVER_1]'' \{\
-.             nr #SUBTITLES \\n[#SUBTITLE_DOCCOVER_NUM]
+.          if \\n[#\\*[DOC_]COVER]=1 \{\
+.             ie !'\\*[$SUBTITLE_\\*[DOC_]COVER_1]'' \{\
+.                nr #SUBTITLES \\n[#SUBTITLE_\\*[DOC_]COVER_NUM]
 .             nr #NEXT_SUBTITLE 0 1
 .             while \\n[#SUBTITLES]>\\n[#NEXT_SUBTITLE] \{\
-.                ie \\n[#DOC_COVER_SUBTITLE_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$DOC_COVER_SUBTITLE_COLOR]]\\*[$SUBTITLE_DOCCOVER_\\n+[#NEXT_SUBTITLE]]\m[]
+.                   ie \\n[#\\*[DOC_]COVER_SUBTITLE_COLOR]=1 \
+.                      PRINT \
+\m[\\*[$\\*[DOC_]COVER_SUBTITLE_COLOR]]\
+\\*[$SUBTITLE_\\*[DOC_]COVER_\\n+[#NEXT_SUBTITLE]]\m[]
+.                   el .PRINT \
+\\*[$SUBTITLE_\\*[DOC_]COVER_\\n+[#NEXT_SUBTITLE]]
 .                \}
-.                el \{ .PRINT \\*[$SUBTITLE_DOCCOVER_\\n+[#NEXT_SUBTITLE]] \}
-.\}
 .          \}
 .          el \{\
 .             nr #SUBTITLES \\n[#SUBTITLE_NUM]
 .             nr #NEXT_SUBTITLE 0 1
 .             while \\n[#SUBTITLES]>\\n[#NEXT_SUBTITLE] \{\
-.                ie \\n[#DOC_COVER_SUBTITLE_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$DOC_COVER_SUBTITLE_COLOR]]\\*[$SUBTITLE_\\n+[#NEXT_SUBTITLE]]\m[]
+.                   ie \\n[#\\*[DOC_]COVER_SUBTITLE_COLOR]=1 \
+.                      PRINT \
+\m[\\*[$\\*[DOC_]COVER_SUBTITLE_COLOR]]\\*[$SUBTITLE_\\n+[#NEXT_SUBTITLE]]\m[]
+.                   el .PRINT \\*[$SUBTITLE_\\n+[#NEXT_SUBTITLE]]
 .                \}
-.                el \{ .PRINT \\*[$SUBTITLE_\\n+[#NEXT_SUBTITLE]] \}
-.\}
 .          \}
 .       \}
 .             if \\n[#PRINT_STYLE]=1 \{\
-.                if \\n[#SINGLE_SPACE]=0 \{ .vs \}
+.             if \\n[#SINGLE_SPACE]=0 .vs
 .             \}
 .          \}
 .          if \\n[#PRINT_STYLE]=1 \{\
-.             if !r#DOC_COVER_SUBTITLE \{ .sp \}
+.          if !r#\\*[DOC_]COVER_SUBTITLE .sp
 .          \}
 .       \}
-.       if \\n[#DOC_COVER_AUTHOR]=1 \{\
-.          fam \\*[$DOC_COVER_AUTHOR_FAM]
-.          ft  \\*[$DOC_COVER_AUTHOR_FT]
-.          ps  \\*[$DOC_COVER_AUTHOR_PT_SIZE]
+.    if \\n[#\\*[DOC_]COVER_AUTHOR]=1 \{\
+.       fam \\*[$\\*[DOC_]COVER_AUTHOR_FAM]
+.       ft  \\*[$\\*[DOC_]COVER_AUTHOR_FT]
+.       ps  \\*[$\\*[DOC_]COVER_AUTHOR_PT_SIZE]
 .          if \\n[#PRINT_STYLE]=1 \{\
 .             TYPEWRITER
-.             ie \\n[#SINGLE_SPACE]=1 \{ .vs \\n[#DOC_LEAD]u \}
-.             el \{ .vs \\n[#DOC_LEAD]u/2u \}
+.          ie \\n[#SINGLE_SPACE]=1 .vs \\n[#DOC_LEAD]u
+.          el .vs \\n[#DOC_LEAD]u/2u
 .             sp
 .          \}
-.          ie d$ATTRIBUTE_STRING_DOCCOVER \{\
-.             ie \\n[#DOC_COVER_ATTRIBUTE_COLOR]=1 \{\
-.                PRINT 
\&\m[\\*[$DOC_COVER_ATTRIBUTE_COLOR]]\\*[$ATTRIBUTE_STRING_DOCCOVER]\m[]
-.             \}
-.             el \{ .PRINT \&\\*[$ATTRIBUTE_STRING_DOCCOVER] \}
+.       ie d$ATTRIBUTE_STRING_DO_CCOVER \{\
+.          ie \\n[#\\*[DOC_]COVER_ATTRIBUTE_COLOR]=1 \
+.             PRINT \
+\&\m[\\*[$\\*[DOC_]COVER_ATTRIBUTE_COLOR]]\
+\\*[$ATTRIBUTE_STRING_\\*[DOC_]COVER]\m[]
+.          el .PRINT \&\\*[$ATTRIBUTE_STRING_\\*[DOC_]COVER]
 .          \}
 .          el \{\
 .             if d$ATTRIBUTE_STRING \{\
-.                ie \\n[#DOC_COVER_ATTRIBUTE_COLOR]=1 \{\
-.                   PRINT 
\&\m[\\*[$DOC_COVER_ATTRIBUTE_COLOR]]\\*[$ATTRIBUTE_STRING]\m[]
-.                \}
-.                el \{ .PRINT \&\\*[$ATTRIBUTE_STRING] \}
+.             ie \\n[#\\*[DOC_]COVER_ATTRIBUTE_COLOR]=1 \
+.                PRINT \
+\&\m[\\*[$\\*[DOC_]COVER_ATTRIBUTE_COLOR]]\\*[$ATTRIBUTE_STRING]\m[]
+.             el .PRINT \&\\*[$ATTRIBUTE_STRING]
 .             \}
 .          \}
 .          PRINT_AUTHORS
 .       \}
-.       fam \\*[$DOC_COVER_DOCTYPE_FAM]
-.       ft  \\*[$DOC_COVER_DOCTYPE_FT]
-.       ps  \\*[$DOC_COVER_DOCTYPE_PT_SIZE]
+.    fam \\*[$\\*[DOC_]COVER_DOCTYPE_FAM]
+.    ft  \\*[$\\*[DOC_]COVER_DOCTYPE_FT]
+.    ps  \\*[$\\*[DOC_]COVER_DOCTYPE_PT_SIZE]
 .       SP
 .       if \\n[#DOC_TYPE]=3 \{\
-.          if \\n[#DOC_COVER_DOCTYPE]=1 \{\
+.       if \\n[#\\*[DOC_]COVER_DOCTYPE]=1 \{\
 .             ie \\n[#PRINT_STYLE]=1 \{\
 .                TYPEWRITER
 .                vs \\n[#DOC_LEAD]u
 .                UNDERSCORE2 "\\*[$DOC_TYPE]"
 .             \}
 .             el \{\
-.                nr #FROM_DOC_COVER 1
-.                ie \\n[#DOC_COVER_DOCTYPE_COLOR]=1 \{\
-.                   COLOR \\*[$DOC_COVER_DOCTYPE_COLOR]
-.                   ie \\n[#DOCCOVER_UNDERLINE]= 1 \{ .UNDERSCORE 
\\*[$DOCCOVER_UNDERLINE_GAP] "\\*[$DOC_TYPE]" \}
-.                   el \{ .PRINT "\\*[$DOC_TYPE]" \}
+.             nr #FROM_\\*[DOC_]COVER 1
+.             ie \\n[#\\*[DOC_]COVER_DOCTYPE_COLOR]=1 \{\
+.                COLOR \\*[$\\*[DOC_]COVER_DOCTYPE_COLOR]
+.                ie \\n[#\\*[DOC_]COVER_UNDERLINE]=1 \
+.                   UNDERSCORE \\*[$\\*[DOC_]COVER_UNDERLINE_GAP] 
"\\*[$DOC_TYPE]"
+.                el .PRINT "\\*[$DOC_TYPE]"
 .                \}
 .                el \{\
-.                   ie \\n[#DOCCOVER_UNDERLINE]=1 \{ .UNDERSCORE 
\\*[$DOCCOVER_UNDERLINE_GAP] "\\*[$DOC_TYPE]" \}
-.                   el \{ .PRINT "\\*[$DOC_TYPE]" \}
+.                ie \\n[#\\*[DOC_]COVER_UNDERLINE]=1 \
+.                   UNDERSCORE \
+\\*[$\\*[DOC_]COVER_UNDERLINE_GAP] "\\*[$DOC_TYPE]"
+.                el .PRINT "\\*[$DOC_TYPE]"
 .                \}
-.                rr #FROM_DOC_COVER
+.             rr #FROM_\\*[DOC_]COVER
 .             \}
 .          \}
 .       \}
-.       sp |\\n[#VISUAL_B_MARGIN]u+\\n[#DOC_LEAD]u
+.    sp |\\n[#VISUAL_B_MARGIN]u
 .       ie \\n[#PRINT_STYLE]=1 \{\
 .          TYPEWRITER
-.          ie \\n[#SINGLE_SPACE]=1 \{ .vs \\n[#DOC_LEAD]u \}
-.          el \{ .vs \\n[#DOC_LEAD]u/2u \}
+.       ie \\n[#SINGLE_SPACE]=1 .vs \\n[#DOC_LEAD]u
+.       el .vs \\n[#DOC_LEAD]u/2u
+.       sp
 .       \}
 .       el \{\
-.          fam \\*[$DOC_COVER_COPYRIGHT_FAM]
-.          ft  \\*[$DOC_COVER_COPYRIGHT_FT]
-.          PT_SIZE \\*[$DOC_COVER_COPYRIGHT_PT_SIZE]
-.          AUTOLEAD \\n[#DOC_COVER_MISC_AUTOLEAD]
+.       fam \\*[$\\*[DOC_]COVER_COPYRIGHT_FAM]
+.       ft  \\*[$\\*[DOC_]COVER_COPYRIGHT_FT]
+.       PT_SIZE \\*[$\\*[DOC_]COVER_COPYRIGHT_PT_SIZE]
+.       AUTOLEAD \\n[#\\*[DOC_]COVER_MISC_AUTOLEAD]
+.       nr #COPYRIGHT_V_ADJ \\n[#DOC_LEAD]-\\n[.v]
+.       sp \\n[#COPYRIGHT_V_ADJ]u
+.       rr #COPYRIGHT_V_ADJ
 .       \}
-.       if \\n[#DOC_COVER_COPYRIGHT]=1 \{\
+.    if \\n[#\\*[DOC_]COVER_COPYRIGHT]=1 \{\
 .          if !'\\*[$COPYRIGHT_DOCCOVER]'' \{\
 .             ds $SAVED_COPYRIGHT \\*[$COPYRIGHT]
 .             ds $COPYRIGHT \\*[$COPYRIGHT_DOCCOVER]
 .          \}
-.          QUAD \\*[$DOC_COVER_COPYRIGHT_QUAD]
-.          ie \\n[#DOC_COVER_COPYRIGHT_COLOR]=1 \{\
-.             PRINT \m[\\*[$DOC_COVER_COPYRIGHT_COLOR]]\\*[$COPYRIGHT]\m[]
-.          \}
-.          el \{ .PRINT \\*[$COPYRIGHT] \}
-.          ds $COPYRIGHT \\*[$SAVED_COPYRIGHT]
+.       QUAD \\*[$\\*[DOC_]COVER_COPYRIGHT_QUAD]
+.       ie \\n[#\\*[DOC_]COVER_COPYRIGHT_COLOR]=1 \
+.          PRINT \m[\\*[$\\*[DOC_]COVER_COPYRIGHT_COLOR]]\\*[$COPYRIGHT]\m[]
+.       el .PRINT \\*[$COPYRIGHT]
+.       if d$SAVED_COPYRIGHT .ds $COPYRIGHT \\*[$SAVED_COPYRIGHT]
 .       \}
 .       br
-.       if \\n[#DOC_COVER_MISC]=1 \{\
+.    if \\n[#\\*[DOC_]COVER_MISC]=1 \{\
 .          if \\n[#PRINT_STYLE]=2 \{\
-.             fam \\*[$DOC_COVER_MISC_FAM]
-.             ft  \\*[$DOC_COVER_MISC_FT]
-.             PT_SIZE \\*[$DOC_COVER_MISC_PT_SIZE]
-.          \}
-.          QUAD \\*[$DOC_COVER_MISC_QUAD]
-.          ie !'\\*[$MISC_DOCCOVER_1]'' \{\
-.             nr #MISCS \\n[#MISC_DOCCOVER_NUM]
-.             sp -\\n[#MISCS]
+.          fam \\*[$\\*[DOC_]COVER_MISC_FAM]
+.          ft  \\*[$\\*[DOC_]COVER_MISC_FT]
+.          PT_SIZE \\*[$\\*[DOC_]COVER_MISC_PT_SIZE]
+.       \}
+.       QUAD \\*[$\\*[DOC_]COVER_MISC_QUAD]
+.       ie !'\\*[$MISC_\\*[DOC_]COVER_1]'' \{\
+.          nr #MISCS \\n[#MISC_\\*[DOC_]COVER_NUM]
 .             nr #NEXT_MISC 0 1
 .             while \\n[#MISCS]>\\n[#NEXT_MISC] \{\
-.                ie \\n[#DOC_COVER_MISC_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$DOC_COVER_MISC_COLOR]]\\*[$MISC_DOCCOVER_\\n+[#NEXT_MISC]]\m[]
-.                   rm $MISC_DOCCOVER_\\n[#NEXT_MISC]
-.                   rm $MISC_\\n[#NEXT_MISC]
+.             ie \\n[#\\*[DOC_]COVER_MISC_COLOR]=1 \{\
+.                da MISC_DIV
+.                PRINT \
+\m[\\*[$\\*[DOC_]COVER_MISC_COLOR]]\\*[$MISC_\\*[DOC_]COVER_\\n+[#NEXT_MISC]]\m[]
 .                   br
+.                da
+.                rm $MISC_\\*[DOC_]COVER_\\n[#NEXT_MISC]
+.                rm $MISC_\\n[#NEXT_MISC]
 .                \}
 .                el \{\
-.                   PRINT \\*[$MISC_DOCCOVER_\\n+[#NEXT_MISC]]
-.                   rm $MISC_DOCCOVER_\\n[#NEXT_MISC]
-.                   rm $MISC_\\n[#NEXT_MISC]
+.                da MISC_DIV
+.                PRINT \\*[$MISC_\\*[DOC_]COVER_\\n+[#NEXT_MISC]]
 .                   br
+.                da
+.                rm $MISC_\\*[DOC_]COVER_\\n[#NEXT_MISC]
+.                rm $MISC_\\n[#NEXT_MISC]
+.             \}
 .                \}
-.\}
 .                rm $MISC_\\n+[#NEXT_MISC]
 .          \}
 .          el \{\
 .             nr #MISCS \\n[#MISC_NUM]
-.             sp -\\n[#MISCS]
 .             nr #NEXT_MISC 0 1
 .             while \\n[#MISCS]>\\n[#NEXT_MISC] \{\
-.                ie \\n[#DOC_COVER_MISC_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$DOC_COVER_MISC_COLOR]]\\*[$MISC_\\n+[#NEXT_MISC]]\m[]
+.             ie \\n[#\\*[DOC_]COVER_MISC_COLOR]=1 \{\
+.                da MISC_DIV
+.                PRINT \
+\m[\\*[$\\*[DOC_]COVER_MISC_COLOR]]\\*[$MISC_\\n+[#NEXT_MISC]]\m[]
 .                   br
+.                da
 .                \}
 .                el \{\
+.                da MISC_DIV
 .                   PRINT \\*[$MISC_\\n+[#NEXT_MISC]]
 .                   br
+.                da
 .                \}
-.\}
-.          \}
-.       \}
-.       nr #DOCCOVER_END 1
-.       END_COVER
-.    \}
-.\" Cover
-.    el \{\
-.       if !r#COVER_START_POS \{\
-.          nr #COVER_START_POS \\n[#PAGE_LENGTH]/3
-.       \}
-.       if \\n[#PRINT_STYLE]=1 \{\
-.          ie \\n[#SINGLE_SPACE]=1 \{ .vs \\n[#DOC_LEAD]u*2u \}
-.          el \{ .vs \\n[#DOC_LEAD]u \}
+.             nr #MISC_DEPTH +\\n[dn]
 .       \}
-.       if \\n[#PRINT_STYLE]=2 \{\
-.          LS \\n[#DOC_LEAD]u\\*[$COVER_LEAD_ADJ]
-.          nr #COVER_LEAD \\n[#LEAD]
 .       \}
-.       PRINT \&
-.       sp |\\n[#COVER_START_POS]u-1v
-.       if \\n[#COVER_COLOR]=1 \{\
+.    nr #MISC_DEPTH -\\n[#DOC_LEAD]
+.    sp |\\n[#VISUAL_B_MARGIN]u-\\n[#MISC_DEPTH]u
 .          nf
-\m[\\*[$COVER_COLOR]]
-.       \}
-.       COVER_H_POS
-.       fam \\*[$COVER_TITLE_FAM]
-.       ft  \\*[$COVER_TITLE_FT]
-.       ps  \\*[$COVER_TITLE_PT_SIZE]
-.       vs      \\n[#COVER_LEAD]u
-.       if \\n[#PRINT_STYLE]=1 \{ .TYPEWRITER \}
-.       if \\n[#COVER_TITLE]=1 \{\
-.          ie \\n[#PRINT_STYLE]=1 \{\
-.             CAPS
-.             nr #ARG_NUM 0 1
-.             while \\n[#TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                UNDERSCORE "\\*[$TITLE_\\n[#ARG_NUM]]"
-.\}
-.             CAPS OFF
-.          \}
-.          el \{\
-.          nr #ARG_NUM 0 1
-.          while \\n[#TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#COVER_TITLE_COLOR]=1 \{\
-.                PRINT 
"\m[\\*[$COVER_TITLE_COLOR]]\\*[$TITLE_\\n[#ARG_NUM]]\m[]
-.             \}
-.             el \{\
-.                PRINT "\\*[$TITLE_\\n[#ARG_NUM]]
-.             \}
-.\}
-.          \}
-.       \}
-.       if \\n[#COVER_TITLE]=2 \{\
-.          ie \\n[#PRINT_STYLE]=1 \{\
-.             CAPS
-.             nr #ARG_NUM 0 1
-.             while \\n[#DOCTITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                UNDERSCORE "\\*[$DOC_TITLE_\\n[#ARG_NUM]]"
-.\}
-.             CAPS OFF
-.          \}
-.          el \{\
-.          nr #ARG_NUM 0 1
-.          while \\n[#DOCTITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                PRINT 
\m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$DOC_TITLE_\\n[#ARG_NUM]]\m[]
-.             \}
-.             el \{ .PRINT \\*[$DOC_TITLE_\\n[#ARG_NUM]] \}
-.\}
-.          \}
-.       \}
-.       if \\n[#COVER_TITLE]=3 \{\
-.          ie \\n[#PRINT_STYLE]=1 \{\
-.             CAPS
-.             PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER]
-.             CAPS OFF
-.          \}
-.          el \{\
-.             ie \\n[#COVER_TITLE_COLOR]=1 \{\
-.                PRINT \m[\\*[$COVER_TITLE_COLOR]]\\*[$CHAPTER_STRING] 
\\*[$CHAPTER]\m[]
-.             \}
-.             el \{ .PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER] \}
-.          \}
-.       \}
-.       if \\n[#COVER_TITLE]=4 \{\
-.          ie \\n[#PRINT_STYLE]=1 \{\
-.                ie \\n[#SINGLE_SPACE]=0 \{\
-.                   vs \\n[#DOC_LEAD]u/2u
-.                \}
-.                el \{\
-.                   vs \\n[#DOC_LEAD]u
-.                \}
-.                sp
-.             CAPS
-.             nr #ARG_NUM 0 1
-.             while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                UNDERSCORE "\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]"
-.\}
-.             CAPS OFF
-.             if \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u \}
-.          \}
-.          el \{\
-.          nr #ARG_NUM 0 1
-.          while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                PRINT 
\m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
-.             \}
-.             el \{ .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]] \}
-.\}
-.          \}
-.       \}
-.       if \\n[#COVER_TITLE]=5 \{\
-.          ie \\n[#PRINT_STYLE]=1 \{\
-.             CAPS
-.             PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER]
-.             CAPS OFF
-.          \}
-.          el \{\
-.             ie \\n[#COVER_TITLE_COLOR]=1 \{\
-.                PRINT \m[\\*[$COVER_TITLE_COLOR]]\\*[$CHAPTER_STRING] 
\\*[$CHAPTER]\m[]
-.             \}
-.             el \{ .PRINT \\*[$CHAPTER_STRING] \\*[$CHAPTER] \}
-.          \}
-.          if !'\\*[$CHAPTER_TITLE_1]'' \{\
-.             ie \\n[#PRINT_STYLE]=1 \{\
-.                ie \\n[#SINGLE_SPACE]=0 \{\
-.                   vs \\n[#DOC_LEAD]u/2u
-.                \}
-.                el \{\
-.                   vs \\n[#DOC_LEAD]u
-.                \}
-.                sp
-.                nr #ARG_NUM 0 1
-.                while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                   UNDERSCORE "\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]"
-.\}
-.                if \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u \}
-.             \}
-.             el \{\
-.                fam \\*[$COVER_CHAPTER_TITLE_FAM]
-.                ft  \\*[$COVER_CHAPTER_TITLE_FT]
-.                ps  \\*[$COVER_CHAPTER_TITLE_PT_SIZE]
-.                ALD \\n[.v]u/4u \"Put a little space before the chapter title
-.                nr #ARG_NUM 0 1
-.                while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                   ie \\n[#DOC_COVER_TITLE_COLOR]=1 \{\
-.                      PRINT 
\m[\\*[$DOC_COVER_TITLE_COLOR]]\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]\m[]
-.                   \}
-.                   el \{ .PRINT \\*[$CHAPTER_TITLE_\\n[#ARG_NUM]] \}
-.\}
+.    MISC_DIV
+.    rm MISC_DIV
+.    rr #MISC_DEPTH
 .             \}
+.    if '\\$0'DO_COVER'     .nr #COVER_END 1
+.    if '\\$0'DO_DOC_COVER' .nr #DOC_COVER_END 1
+.    if \\n[TOC.RELOCATE]==1 \{\
+.       if !\\n[#COVER_BLANKPAGE] \{\
+.          if !rTOC_BH .TOC_AFTER_HERE
 .          \}
 .       \}
-.       if \\n[#COVER_TITLE]=6 \{\
-.          ie \\n[#PRINT_STYLE]=1 \{\
-.             CAPS
-.             nr #ARG_NUM 0 1
-.             while \\n[#COVER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.                UNDERSCORE "\\*[$COVER_TITLE_\\n[#ARG_NUM]]"
-.\}
-.             CAPS OFF
-.          \}
-.          el \{\
-.             nr #ARG_NUM 0 1
-.             while \\n[#COVER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
-.             ie \\n[#COVER_TITLE_COLOR]=1 \{\
-.                PRINT 
\m[\\*[$COVER_TITLE_COLOR]]\\*[$COVER_TITLE_\\n[#ARG_NUM]]\m[]
-.             \}
-.             el \{ .PRINT \\*[$COVER_TITLE_\\n[#ARG_NUM]] \}
-.\}
-.          \}
-.       \}
-.       if !\\n[#DOC_TYPE]=2 \{\
-.          if \\n[#COVER_SUBTITLE]=1 \{\
-.             fam \\*[$COVER_SUBTITLE_FAM]
-.             ft  \\*[$COVER_SUBTITLE_FT]
-.             ps  \\*[$COVER_SUBTITLE_PT_SIZE]
-.             if \\n[#PRINT_STYLE]=1 \{\
-.                TYPEWRITER
-.                if \\n[#PRINT_STYLE]=1 \{\
-.                   TYPEWRITER
-.                   ie \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u/2u \}
-.                   el \{ .vs \\n[#DOC_LEAD]u \}
-.                   sp
-.                \}
-.             \}
-.       if \\n[#COVER]=1 \{\
-.          ie !'\\*[$SUBTITLE_COVER_1]'' \{\
-.             nr #SUBTITLES \\n[#SUBTITLE_COVER_NUM]
-.             nr #NEXT_SUBTITLE 0 1
-.             while \\n[#SUBTITLES]>\\n[#NEXT_SUBTITLE] \{\
-.                ie \\n[#COVER_SUBTITLE_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$COVER_SUBTITLE_COLOR]]\\*[$SUBTITLE_COVER_\\n+[#NEXT_SUBTITLE]]\m[]
-.                \}
-.                el \{ .PRINT \\*[$SUBTITLE_COVER_\\n+[#NEXT_SUBTITLE]] \}
-.\}
-.          \}
-.          el \{\
-.             nr #SUBTITLES \\n[#SUBTITLE_NUM]
-.             nr #NEXT_SUBTITLE 0 1
-.             while \\n[#SUBTITLES]>\\n[#NEXT_SUBTITLE] \{\
-.                ie \\n[#COVER_SUBTITLE_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$COVER_SUBTITLE_COLOR]]\\*[$SUBTITLE_\\n+[#NEXT_SUBTITLE]]\m[]
-.                \}
-.                el \{ .PRINT \\*[$SUBTITLE_\\n+[#NEXT_SUBTITLE]] \}
-.\}
-.          \}
-.       \}
-.             if \\n[#PRINT_STYLE]=1 \{\
-.                if \\n[#SINGLE_SPACE]=0 \{ .vs \}
-.             \}
-.          \}
-.          if \\n[#PRINT_STYLE]=1 \{\
-.             if !r#COVER_SUBTITLE \{ .sp \}
-.          \}
-.       \}
-.       if \\n[#COVER_AUTHOR]=1 \{\
-.          fam \\*[$COVER_AUTHOR_FAM]
-.          ft  \\*[$COVER_AUTHOR_FT]
-.          ps  \\*[$COVER_AUTHOR_PT_SIZE]
-.          if \\n[#PRINT_STYLE]=1 \{\
-.             TYPEWRITER
-.             ie \\n[#SINGLE_SPACE]=1 \{ .vs \\n[#DOC_LEAD]u \}
-.             el \{ .vs \\n[#DOC_LEAD]u/2u \}
-.             sp
-.          \}
-.          ie d$ATTRIBUTE_STRING_COVER \{\
-.             ie \\n[#COVER_ATTRIBUTE_COLOR]=1 \{\
-.                PRINT 
\&\m[\\*[$COVER_ATTRIBUTE_COLOR]]\\*[$ATTRIBUTE_STRING_COVER]\m[]
-.             \}
-.             el \{ .PRINT \&\\*[$ATTRIBUTE_STRING_COVER] \}
-.          \}
-.          el \{\
-.             if d$ATTRIBUTE_STRING \{\
-.                ie \\n[#COVER_ATTRIBUTE_COLOR]=1 \{\
-.                   PRINT 
\&\m[\\*[$COVER_ATTRIBUTE_COLOR]]\\*[$ATTRIBUTE_STRING]\m[]
-.                \}
-.                el \{ .PRINT \&\\*[$ATTRIBUTE_STRING] \}
-.             \}
-.          \}
-.          PRINT_AUTHORS
-.       \}
-.       fam \\*[$COVER_DOCTYPE_FAM]
-.       ft  \\*[$COVER_DOCTYPE_FT]
-.       ps  \\*[$COVER_DOCTYPE_PT_SIZE]
-.       SP
-.       if \\n[#DOC_TYPE]=3 \{\
-.          if \\n[#COVER_DOCTYPE]=1 \{\
-.             ie \\n[#PRINT_STYLE]=1 \{\
-.                TYPEWRITER
-.                vs \\n[#DOC_LEAD]u
-.                UNDERSCORE2 "\\*[$DOC_TYPE]"
-.             \}
-.             el \{\
-.                nr #FROM_COVER 1
-.                ie \\n[#COVER_DOCTYPE_COLOR]=1 \{\
-.                   COLOR \\*[$COVER_DOCTYPE_COLOR]
-.                   ie \\n[#COVER_UNDERLINE]= 1 \{ .UNDERSCORE 
\\*[$COVER_UNDERLINE_GAP] "\\*[$DOC_TYPE]" \}
-.                   el \{ .PRINT "\\*[$DOC_TYPE] \}
-.                \}
-.                el \{\
-.                   ie \\n[#COVER_UNDERLINE]=1 \{ .UNDERSCORE 
\\*[$COVER_UNDERLINE_GAP] "\\*[$DOC_TYPE]" \}
-.                   el \{ .PRINT "\\*[$DOC_TYPE]" \}
+.    if '\\$0'DO_COVER' \{\
+.       if \\n[TOC.RELOCATE]==6 \{\
+.          if !rTOC_BH .TOC_AFTER_HERE
 .                \}
-.                rr #FROM_COVER
 .             \}
+.    if '\\$0'DO_DOC_COVER' \{\
+.       if \\n[TOC.RELOCATE]==4 \{\
+.          if !rTOC_BH .TOC_AFTER_HERE
 .          \}
 .       \}
-.       sp |\\n[#VISUAL_B_MARGIN]u+\\n[#DOC_LEAD]u
-.       ie \\n[#PRINT_STYLE]=1 \{\
-.          TYPEWRITER
-.          ie \\n[#SINGLE_SPACE]=1 \{ .vs \\n[#DOC_LEAD]u \}
-.          el \{ .vs \\n[#DOC_LEAD]u/2u \}
-.       \}
-.       el \{\
-.          fam  \\*[$COVER_COPYRIGHT_FAM]
-.          ft      \\*[$COVER_COPYRIGHT_FT]
-.          PT_SIZE \\*[$COVER_COPYRIGHT_PT_SIZE]
-.          AUTOLEAD \\n[#COVER_MISC_AUTOLEAD]
-.       \}
-.       if \\n[#COVER_COPYRIGHT]=1 \{\
-.          if !'\\*[$COPYRIGHT_COVER]'' \{\
-.             ds $SAVED_COPYRIGHT \\*[$COPYRIGHT]
-.             ds $COPYRIGHT \\*[$COPYRIGHT_COVER]
-.          \}
-.          QUAD \\*[$COVER_COPYRIGHT_QUAD]
-.          ie \\n[#COVER_COPYRIGHT_COLOR]=1 \{\
-.             PRINT \m[\\*[$COVER_COPYRIGHT_COLOR]]\\*[$COPYRIGHT]\m[]
-.          \}
-.          el \{ .PRINT \\*[$COPYRIGHT] \}
-.          ds $COPYRIGHT \\*[$SAVED_COPYRIGHT]
-.       \}
-.       br
-.       if \\n[#COVER_MISC]=1 \{\
-.          QUAD \\*[$COVER_MISC_QUAD]
-.          if \\n[#PRINT_STYLE]=2 \{\
-.             fam \\*[$COVER_MISC_FAM]
-.             ft  \\*[$COVER_MISC_FT]
-.             PT_SIZE \\*[$COVER_MISC_PT_SIZE]
-.          \}
-.          ie !'\\*[$MISC_COVER_1]'' \{\
-.             nr #MISCS \\n[#MISC_COVER_NUM]
-.             sp -\\n[#MISCS]
-.             nr #NEXT_MISC 0 1
-.             while \\n[#MISCS]>\\n[#NEXT_MISC] \{\
-.                ie \\n[#COVER_MISC_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$COVER_MISC_COLOR]]\\*[$MISC_COVER_\\n+[#NEXT_MISC]]\m[]
-.                   br
-.                \}
-.                el \{\
-.                   PRINT \\*[$MISC_COVER_\\n+[#NEXT_MISC]]
-.                   br
-.                \}
-.\}
-.          \}
-.          el \{\
-.             nr #MISCS \\n[#MISC_NUM]
-.             sp -\\n[#MISCS]
-.             nr #NEXT_MISC 0 1
-.             while \\n[#MISCS]>\\n[#NEXT_MISC] \{\
-.                ie \\n[#COVER_MISC_COLOR]=1 \{\
-.                   PRINT 
\m[\\*[$COVER_MISC_COLOR]]\\*[$MISC_\\n+[#NEXT_MISC]]\m[]
-.                   br
-.                \}
-.                el \{\
-.                   PRINT \\*[$MISC_\\n+[#NEXT_MISC]]
-.                   br
-.                \}
-.\}
-.          \}
-.       \}
-.       nr #COVER_END 1
+.    if '\\$0'DO_DOC_COVER' .rm DOC_
 .       END_COVER
-.    \}
 .END
 \#
 \# Macro to terminate (doc)cover processing
@@ -7456,26 +7070,32 @@
 .    EOL
 .    TRAP
 .    NEWPAGE
-.    if \\n[#PAGINATION_WAS_ON]=1 \{ .nr % +1 \}
-.    if \\n[#DOCCOVER_END]=1 \{\
-.       ie \\n[#DOCCOVER_BLANKPAGE]=1 \{\
+.    if \\n[#PAGINATION_WAS_ON]=1 .nr % +1
+.    if \\n[#DOC_COVER_END]=1 \{\
+.       ie \\n[#DOC_COVER_BLANKPAGE]=1 \{\
+.          if \\n[TOC.RELOCATE] \{\
+.             if !\\n[#TOC_BH] .TOC_AFTER_HERE
+.          \}
 .          NEWPAGE
-.          rr #DOCCOVER_BLANKPAGE
-.          if !\\n[#DOCCOVERS_COUNT]=1 \{ .nr % -2 \}
+.          rr #DOC_COVER_BLANKPAGE
+.          if !\\n[#DOCCOVERS_COUNT]=1 .nr % -2
 .       \}
 .       el \{\
-.          if !\\n[#DOCCOVERS_COUNT]=1 \{ .nr #PAGE_NUM_ADJ -1 \}
+.          if !\\n[#DOCCOVERS_COUNT]=1 .nr #PAGE_NUM_ADJ -1
 .       \}
-.       rr #DOCCOVER_END
+.       rr #DOC_COVER_END
 .    \}
 .    if \\n[#COVER_END]=1 \{\
 .       ie \\n[#COVER_BLANKPAGE]=1 \{\
+.          if \\n[TOC.RELOCATE] \{\
+.             if !\\n[TOC_BH] .TOC_AFTER_HERE
+.          \}
 .          NEWPAGE
 .          rr #COVER_BLANKPAGE
-.          if !\\n[#COVERS_COUNT]=1 \{ .nr % -2 \}
+.          if !\\n[#COVERS_COUNT]=1 .nr % -2
 .       \}
 .       el \{\
-.          if !\\n[#COVERS_COUNT]=1 \{ .nr #PAGE_NUM_ADJ -1 \}
+.          if !\\n[#COVERS_COUNT]=1 .nr #PAGE_NUM_ADJ -1
 .       \}
 .       rr #COVER_END
 .    \}
@@ -7498,23 +7118,28 @@
 .       nr #COLUMNS 1
 .    \}
 .    rr #DOING_COVER
+.    if \\n[.ns] .nop \&
+.    if \\n[#RECTO_VERSO] .nr #RV_POST_COVER 1
 .END
 \#
 \# Macro to begin document processing
 \#
 .MAC START END
-.    if !n \{ .nop \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap' \}
+.    if \\n[TOC.RELOCATE]==2 \{\
+.       if !\\n[TOC_BH] .TOC_BEFORE_HERE
+.    \}
+.    if !n .nop \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap'
 .    if !\\n[#PRINT_STYLE] \{\
 .       PRINTSTYLE TYPEWRITE
 .       PRINT \&
 .       po 6P
 .       ll 39P
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .       sp |1i-1v
 .       CENTER
 .       PRINT "You neglected to enter a PRINTSTYLE"
 .       fl
-.       ab [mom]: PRINTSTYLE missing.  Aborting.
+.       ab [mom]: PRINTSTYLE missing.  Aborting '\\n[.F]'.
 .    \}
 .    nr #DOCS 1
 .    if \\n[#LINENUMBERS]=1 \{\
@@ -7524,8 +7149,7 @@
 .    if \\n[#COLLATE] \{\
 .       COPYSTYLE \\*[$COPY_STYLE]
 .       nr #HEADERS_ON \\n[#HEADER_STATE]
-.       if \\n[#PAGE_NUM_V_POS]=1 \{ .nr #PAGINATE \\n[#PAGINATION_STATE] \}
-.       sp |\\n[#HEADER_MARGIN]u
+.       if \\n[#PAGE_NUM_V_POS]=1 .nr #PAGINATE \\n[#PAGINATION_STATE]
 .       PRINT \&
 .       if !'\\*[$RESTORE_PAGENUM_STYLE]'' \{\
 .          PAGENUM_STYLE \\*[$RESTORE_PAGENUM_STYLE]
@@ -7535,10 +7159,13 @@
 .    DEFAULTS
 .\" Quote and blockquote default leads are the same as #DOC_LEAD, so
 .\" they have to be set after DEFAULTS (where DOC_LEAD is finalized)
-.    if !r#Q_AUTOLEAD     \{ .nr #Q_LEAD \\n[#DOC_LEAD]    \}
-.    if !r#BQ_AUTOLEAD    \{ .nr #BQ_LEAD \\n[#DOC_LEAD]   \}
-.    if !r#EN_Q_AUTOLEAD  \{ .nr #EN_Q_LEAD \\n[#EN_LEAD]  \}
-.    if !r#EN_BQ_AUTOLEAD \{ .nr #EN_BQ_LEAD \\n[#EN_LEAD] \}
+.    if !r#Q_AUTOLEAD     .nr #Q_LEAD \\n[#DOC_LEAD]
+.    if !r#BQ_AUTOLEAD    .nr #BQ_LEAD \\n[#DOC_LEAD]
+.    if !r#EN_Q_AUTOLEAD  .nr #EN_Q_LEAD \\n[#EN_LEAD]
+.    if !r#EN_BQ_AUTOLEAD .nr #EN_BQ_LEAD \\n[#EN_LEAD]
+.\"  TOC/recto-verso stuff
+.    if address@hidden .nr @L_MARGIN \\n[#DOC_L_MARGIN]
+.    if address@hidden .nr @R_MARGIN \\n[#DOC_R_MARGIN]
 .\" Covers and doc covers
 .    if \\n[#DOC_COVERS]=1 \{\
 .       if \\n[#DOC_COVER]=1 \{\
@@ -7564,91 +7191,56 @@
 .          rr #COVER_MISC
 .       \}
 .    \}
-.\" Collate related stuff
-.    ie \\n[#COLLATED_DOC]=1 \{\
+.    if !\\n[#TOC] .RV_HARD_SET_MARGINS
+.    if \\n[#COLUMNS] .COLUMNS \\n[#NUM_COLS] \\n[#GUTTER]u
 .\" Collect TITLE for TOC.
+.    if !\\n[#TOC]=1 \{\
 .       nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ]
 .       af #TOC_ENTRY_PN \\g[#PAGENUMBER]
 .       ie \\n[#USER_SET_TITLE_ITEM] \{\
-.          ds $TOC_TITLE_ITEM \\*[$USER_SET_TITLE_ITEM]\\|
+.          ds $TOC_TITLE_ITEM \\*[$USER_SET_TITLE_ITEM]
 .          rr #USER_SET_TITLE_ITEM
 .          rm $USER_SET_TITLE_ITEM
 .       \}
 .       el \{\
 .          ie \\n[#DOC_TYPE]=2 \{\
-.             ie '\\*[$CHAPTER_TITLE]'' \{\
-.                ds $TOC_TITLE_ITEM \\*[$CHAPTER_STRING] \\*[$CHAPTER]\\|
-.             \}
-.             el \{\
-.                ie '\\*[$CHAPTER]'' \{\
-.                   ds $TOC_TITLE_ITEM \\*[$CHAPTER_TITLE]\\|
-.                \}
+.             ie '\\*[$CHAPTER_TITLE]'' \
+.                ds $TOC_TITLE_ITEM \\*[$CHAPTER_STRING] \\*[$CHAPTER]
 .                el \{\
-.                   ds $TOC_TITLE_ITEM \\*[$CHAPTER_STRING] \\*[$CHAPTER]: 
\\*[$CHAPTER_TITLE]\\|
-.                \}
-.             \}
+.                ie '\\*[$CHAPTER]'' \
+.                   ds $TOC_TITLE_ITEM \\*[$CHAPTER_TITLE]
+.                el \
+.                   ds $TOC_TITLE_ITEM \
+\\*[$CHAPTER_STRING] \\*[$CHAPTER]: \\*[$CHAPTER_TITLE]
 .          \}
-.          el \{\
-.             ds $TOC_TITLE_ITEM \\*[$TITLE]\\|
 .          \}
+.          el \
+.             ds $TOC_TITLE_ITEM \\*[$TITLE]
 .       \}
 .       if \\n[#TOC_AUTHORS]=1 \{\
-.          ie '\\*[$TOC_AUTHORS]'' \{\
-.             as $TOC_TITLE_ITEM /\\|\\*[$AUTHOR_1]\\|
-.          \}
+.          ie '\\*[$TOC_AUTHORS]'' \
+.             as $TOC_TITLE_ITEM / \\*[$AUTHOR_1]
 .          el \{\
-.             as $TOC_TITLE_ITEM /\\|\\*[$TOC_AUTHORS]\\|
+.             as $TOC_TITLE_ITEM / \\*[$TOC_AUTHORS]
 .             rm $TOC_AUTHORS
 .          \}
 .       \}
-.\" Note the use of \!, which transparently embeds the macros used
-.\" in the TOC_ENTRIES diversion.  The elements they control must be
-.\" processed literally when the diversion is output.
-.       ev TOC_EV
-.       da TOC_ENTRIES
-.       if \\n[#PRINT_STYLE]=1 \{\
-\!.        fam \\*[$TYPEWRITER_FAM]
-\!.        ft  R
-\!.        ps  \\*[$TYPEWRITER_PS]
-.       \}
-.       if \\n[#PRINT_STYLE]=2 \{\
-\!.        FAMILY  \\*[$TOC_TITLE_FAM]
-\!.        FT      \\*[$TOC_TITLE_FT]
-\!.        PT_SIZE \\n[#TOC_PS]u\\*[$TOC_TITLE_SIZE_CHANGE]
-.       \}
-\!.     TRAP OFF
-\!.     PAD_MARKER ^
-.       ie \\n[#PRINT_STYLE]=1 \{\
-\!.        PAD "\\*[$TOC_TITLE_ITEM]\\*[$TOC_PN_TYPEWRITE]"
+.       nop
+.       sp |\\n[#DOCHEADER_ADVANCE]u-1v
+.       PDF_BOOKMARK 1 \\*[$TOC_TITLE_ITEM]
+.       as $TOC_TITLE_ITEM \|
+.       if \\n[#PREFIX_CH_NUM] \{\
+.          rn $TOC_TITLE_ITEM $TOC_TITLE_ITEM_OLD
+.          ds $TOC_CH_NUM \\n[#CH_NUM].\[toc-hd-num-spacer]
+.          ds $TOC_TITLE_ITEM \\*[$TOC_CH_NUM]\\*[$TOC_TITLE_ITEM_OLD]
+.          rm $TOC_TITLE_ITEM_OLD
 .       \}
-.       el \{\
-\!.        PAD "\\h'\\n[#TOC_TITLE_INDENT]u'\\*[$TOC_TITLE_ITEM]\\*[$TOC_PN]"
-.       \}
-\!.     PAD_MARKER #
-\!.    EOL
-\!.    ST 100 L
-\!.    ST 101 R
-.      if \\n[#PRINT_STYLE]=2 \{\
-\!.       FAMILY  \\*[$TOC_PN_FAM]
-\!.       FT      \\*[$TOC_PN_FT]
-\!.       PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
-.      \}
-\!.    TAB 100
-\!.    PRINT \\*[LEADER]
-\!.    TN
-\!.    TRAP
-\!.    PRINT \\n[#TOC_ENTRY_PN]
-\!.    TQ
-.      di
-.      ev
-.    \}
-.    el \{\
-.       nr #FIRST_DOC_TITLE_PN \\n%+\\n[#PAGE_NUM_ADJ]
-.       af #FIRST_DOC_TITLE_PN \\g[#PAGENUMBER]
-.       nr #FIRST_DOC_TOC_PN_PADDING \\n[#TOC_PN_PADDING]
+.       TITLE_TO_TOC
 .    \}
+.    if !\\n[#TOC] .nr #POST_TOP 1
 .\" End TITLE collection
 .    if \\n[#PRINT_PAGENUM_ON_PAGE_1] \{\
+.       br
 .       sp |\\n[#HEADER_MARGIN]u
 .       PRINT_PAGE_NUMBER
 .    \}
@@ -7656,9 +7248,9 @@
 .    rr #PAGINATION_STATE
 .\" End collate stuff
 .    ie \\n[#DOC_HEADER]=0 \{\
-.       PRINT \&
+.       if \\n[.ns] .rs
 .       if \\n[#DOC_TYPE]=4 \{\
-.          if !'\\n(.z'' \{ .di \}
+.          if !'\\n[.z]'' .di
 .       \}
 .       nr #STORED_PP_INDENT \\n[#PP_INDENT]
 .       PARA_INDENT 0
@@ -7666,26 +7258,29 @@
 .       PARA_INDENT \\n[#STORED_PP_INDENT]u
 .       rr #STORED_PP_INDENT
 .       ie r#ADVANCE_FROM_TOP \{\
+.          br
 .          sp |\\n[#ADVANCE_FROM_TOP]u-1v
-.          if \\n[#ADJ_DOC_LEAD]=1 \{ .SHIM \}
+.          if \\n[#ADJ_DOC_LEAD]=1 .SHIM
+.       \}
+.       el \{\
+.          br
+.          sp |\\n[#T_MARGIN]u-1v
 .       \}
-.       el \{ .sp |\\n[#T_MARGIN]u-1v \}
 .       if \\n[#COLUMNS] \{\
 .          mk dc
 .          nr #COL_NUM 0 1
 .          po \\n[#COL_\\n+[#COL_NUM]_L_MARGIN]u
-.          nr #L_MARGIN \\n(.o
+.          nr #L_MARGIN \\n[.o]
 .          ll \\n[#COL_L_LENGTH]u
 .       \}
 .       nr #PP 0
 .    \}
 .    el \{\
-.       if \\n[#PRINT_STYLE]=2 \{ .LS \\n[#DOC_LEAD]u\\*[$DOCHEADER_LEAD_ADJ] 
\}
+.       if \\n[#PRINT_STYLE]=2 .LS \\n[#DOC_LEAD]u\\*[$DOCHEADER_LEAD_ADJ]
 .       nr #DOCHEADER_LEAD \\n[#LEAD]
-.\" Default
+.\" Default doctype
 .       if \\n[#DOC_TYPE]=1 \{\
-.          PRINT \&
-.          sp |\\n[#DOCHEADER_ADVANCE]u-1v
+.          if \\n[.ns] .rs
 .          ev DOCHEADER
 .          if \\n[#DOCHEADER_COLOR]=1 \{\
 .             nf
@@ -7694,17 +7289,17 @@
 .          \}
 .          L_MARGIN \\n[#DOC_L_MARGIN]u
 .          LL       \\n[#DOC_L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .          if \\n[#PRINT_STYLE]=1 \{\
 .             CENTER
 .             TYPEWRITER
-.             if \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u/2u \}
+.             if !\\n[#SINGLE_SPACE] .vs \\n[#DOC_LEAD]u/2u
 .             if !'\\*[$TITLE_1]'' \{\
 .                CAPS
 .                nr #ARG_NUM 0 1
 .                while \\n[#TITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                   UNDERSCORE 4p "\\*[$TITLE_\\n[#ARG_NUM]]"
-.\}
+.                \}
 .                CAPS OFF
 .             \}
 .             if !'\\*[$SUBTITLE]'' \{\
@@ -7712,16 +7307,17 @@
 .                nr #ARG_NUM 0 1
 .                while \\n[#SUBTITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                   UNDERSCORE 4p "\\*[$SUBTITLE_\\n[#ARG_NUM]]"
-.\}
+.                \}
 .             \}
 .             if !'\\*[$AUTHOR_1]'' \{\
 .                sp
 .                PRINT \&\\*[$ATTRIBUTE_STRING]
 .                nr #AUTHORS \\n[#AUTHOR_NUM]
 .                nr #NEXT_AUTHOR 0 1
+.                if !\\n[#SINGLE_SPACE] .vs \\n[#DOC_LEAD]u/2u
 .                while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\
 .                   PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]
-.\}
+.                \}
 .             \}
 .          \}
 .          if \\n[#PRINT_STYLE]=2 \{\
@@ -7729,10 +7325,9 @@
 .          \}
 .          ev
 .       \}
-.\" Chapter
+.\" Chapter doctype
 .       if \\n[#DOC_TYPE]=2 \{\
-.          PRINT \&
-.          sp |\\n[#DOCHEADER_ADVANCE]u-1v
+.          if \\n[.ns] .rs
 .          ev DOCHEADER
 .          if \\n[#DOCHEADER_COLOR]=1 \{\
 .             nf
@@ -7741,19 +7336,19 @@
 .          \}
 .          L_MARGIN \\n[#DOC_L_MARGIN]u
 .          LL       \\n[#DOC_L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .          if \\n[#PRINT_STYLE]=1 \{\
 .             CENTER
 .             TYPEWRITER
 .             vs \\n[#DOC_LEAD]u
-.             if \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u/2u \}
+.             if !\\n[#SINGLE_SPACE]=1 .vs \\n[#DOC_LEAD]u/2u
 .             ie '\\*[$CHAPTER]'' \{\
 .                CAPS
 .                ie !'\\*[$CHAPTER_TITLE]'' \{\
 .                   nr #ARG_NUM 0 1
 .                   while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                      UNDERSCORE 4p "\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]"
-.\}
+.                   \}
 .                \}
 .                el \{\
 .                   CAPS
@@ -7771,11 +7366,12 @@
 .                   nr #ARG_NUM 0 1
 .                   while \\n[#CHAPTER_TITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                      UNDERSCORE 4p "\\*[$CHAPTER_TITLE_\\n[#ARG_NUM]]"
-.\}
+.                   \}
 .                \}
 .                RLD 1v
 .             \}
-.             if \\n[#SINGLE_SPACE] \{ .ALD 2v \}
+.             vs \\n[#DOC_LEAD]u
+.             if \\n[#SINGLE_SPACE] .ALD 2v
 .          \}
 .          if \\n[#PRINT_STYLE]=2 \{\
 .             CHAPTER_DOCHEADER
@@ -7784,7 +7380,7 @@
 .             CHAPTER_DOCHEADER      \" docheader
 .             br
 .             di
-.             nr #DOCHEADER_DEPTH \\n(dn-\\n[#DOCHEADER_LEAD] \" Storing the 
depth (height) of the diversion
+.             nr #DOCHEADER_DEPTH \\n[dn]-\\n[#DOCHEADER_LEAD] \" Storing the 
depth (height) of the diversion
 .                                                             \" in 
#DOCHEADER_DEPTH
 .             rm DOCHEADER_DIVERSION                          \" Removing the 
diversion macro
 .          \}
@@ -7792,8 +7388,7 @@
 .       \}
 .\" Named
 .       if \\n[#DOC_TYPE]=3 \{\
-.          PRINT \&
-.          sp |\\n[#DOCHEADER_ADVANCE]u-1v
+.          if \\n[.ns] .rs
 .          ev DOCHEADER
 .          if \\n[#DOCHEADER_COLOR]=1 \{\
 .             nf
@@ -7802,17 +7397,17 @@
 .          \}
 .          L_MARGIN \\n[#DOC_L_MARGIN]u
 .          LL       \\n[#DOC_L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .          if \\n[#PRINT_STYLE]=1 \{\
 .             CENTER
 .             TYPEWRITER
-.             if \\n[#SINGLE_SPACE]=0 \{ .vs \\n[#DOC_LEAD]u/2u \}
+.             if !\\n[#SINGLE_SPACE] .vs \\n[#DOC_LEAD]u/2u
 .             CAPS
 .             if !'\\*[$TITLE]'' \{\
 .                nr #ARG_NUM 0 1
 .                while \\n[#TITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                   UNDERSCORE 4p "\\*[$TITLE_\\n[#ARG_NUM]]"
-.\}
+.                \}
 .             \}
 .             CAPS OFF
 .             if !'\\*[$SUBTITLE]'' \{\
@@ -7820,86 +7415,79 @@
 .                nr #ARG_NUM 0 1
 .                while \\n[#SUBTITLE_NUM]>=\\n+[#ARG_NUM] \{\
 .                   UNDERSCORE 4p "\\*[$SUBTITLE_\\n[#ARG_NUM]]"
-.\}
+.                \}
 .             \}
 .             if !'\\*[$AUTHOR_1]'' \{\
 .                sp
 .                PRINT \&\\*[$ATTRIBUTE_STRING]
 .                nr #AUTHORS \\n[#AUTHOR_NUM]
 .                nr #NEXT_AUTHOR 0 1
+.                if !\\n[#SINGLE_SPACE] .vs \\n[#DOC_LEAD]u/2u
 .                while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\
 .                   PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]
-.\}
 .             \}
-.             ie \\n[#SINGLE_SPACE]=0 \{ .sp 2 \}
-.             el \{ .sp \}
+.             \}
+.             ie !\\n[#SINGLE_SPACE] .sp 2
+.             el .sp
 .             ie \\n[#DOCTYPE_UNDERLINE] \{\
 .                UNDERSCORE2 4p "\\*[$DOC_TYPE]"
 .             \}
 .             el \{\
 .                PRINT "\\*[$DOC_TYPE]"
 .             \}
-.             if \\n[#SINGLE_SPACE]=1 \{ .sp \}
-.          \}
-.          if \\n[#PRINT_STYLE]=2 \{\
-.             NAMED_DOCHEADER
+.             if \\n[#SINGLE_SPACE]=1 .sp
 .          \}
+.          if \\n[#PRINT_STYLE]=2 .NAMED_DOCHEADER
 .          ev
 .       \}
 .       if !\\n[#DOC_TYPE]=4 \{\
-.          if \\n[#PRINT_STYLE]=1 \{\
-.             sp
-.          \}
-.          if \\n[#PRINT_STYLE]=2 \{ .ALD \\n[#DOC_LEAD]u*2u \}
+.          if \\n[#PRINT_STYLE]=1 .sp
+.          if \\n[#PRINT_STYLE]=2 .ALD \\n[#DOC_LEAD]u*2u
 .          if \\n[#COLUMNS] \{\
 .             nr #COL_NUM 0 1
 .             nr #L_LENGTH_FOR_EPI \\n[#L_LENGTH]
+.             ie \\n[#RV_POST_COVER] \{\
+.                nr #COL_\\n+[#COL_NUM]_L_MARGIN \\n[#DOC_L_MARGIN]
+.                po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
+.                nr #L_MARGIN \\n[.o]
+.                rr #RV_POST_COVER
+.             \}
+.             el \{\
 .             po \\n[#COL_\\n+[#COL_NUM]_L_MARGIN]u
-.             nr #L_MARGIN \\n(.o
+.                nr #L_MARGIN \\n[.o]
+.             \}
 .             LL \\n[#COL_L_LENGTH]u
-.             ta \\n(.lu
-.             mk dc
+.             ta \\n[.l]u
 .          \}
 .       \}
 .    \}
 .    LS \\n[#DOC_LEAD]u
 .    if \\n[#ADJ_DOC_LEAD]=1 \{\
 .       ie !r#ADVANCE_FROM_TOP \{\
-.          if \\n[#DOC_HEADER]=1 \{ .SHIM \}
+.          if \\n[#DOC_HEADER]=1 .SHIM
 .       \}
-.       el \{ .rr #ADVANCE_FROM_TOP \}
+.       el .rr #ADVANCE_FROM_TOP
 .    \}
+.    mk dc
 .    QUAD \\*[$DOC_QUAD]
 .    CLEANUP_DEFAULTS
 .    nr #START_FOR_FOOTERS 1
-.    if \\n[#COLLATED_DOC]=1 \{\
-.       if !\\n[MNinit_DEFERRED]=1 \{\
-.          MN_INIT rerun
-.       \}
-.    \}
-.    if \\n[#MNinit_DEFERRED]=1 \{\
-.       rr #MNinit_DEFERRED
-.       nr #START_FOR_MNinit 1
-.       MN_INIT \\*[$MN-arg1] \\*[$MN-arg2] \\*[$MN-arg3] \\*[$MN-arg4] 
\\*[$MN-arg5] \\*[$MN-arg6] \\*[$MN-arg7] \\*[$MN-arg8] \\*[$MN-arg9]
-.    \}
-.    nr #START_FOR_MNinit 2
-.    if !\\n[#DOC_TYPE]=4 \{ .em TERMINATE \}
+.    if !\\n[#DOC_TYPE]=4 .em TERMINATE
 .    if \\n[#LINENUMBERS]=2 \{\
 .       NUMBER_LINES RESUME
 .       nr #LINENUMBERS 1
 .    \}
 .    if \\n[#RUN_ON]=1 \{\
-.       if \\n[#FN_MARKER_STYLE]=1 \{ .RUNON_WARNING \}
-.       if \\n[#FN_MARKER_STYLE]=2 \{ .RUNON_WARNING \}
+.       if \\n[#FN_MARKER_STYLE]=1 .RUNON_WARNING
+.       if \\n[#FN_MARKER_STYLE]=2 .RUNON_WARNING
 .    \}
 .END
 \#
 .MAC CLEANUP_DEFAULTS END
 .    nr #START 1
+.    if \\n[#DOC_HEADER]=1 .nr #DOC_HEADER 2
 .    rm $TOC_TITLE_ITEM
 .    rm $DOCHEADER_LEAD_ADJ
-.\" Various registers
-.    if \\n[#DOC_HEADER]=1 \{ .nr #DOC_HEADER 2 \}
 .    rr #MISC_NUM
 .    rr #MISCS
 .    rr #NEXT_AUTHOR
@@ -7915,23 +7503,23 @@
 \# *Argument:
 \#   <none> | <anything> [distance to advance from top of page]
 \# *Function:
-\#   Turns printing of document header on or off.  If a second argument
-\#   in units of measure is given, advances that distance from the
-\#   top of the page without printing the document header.
+\#   Turns printing of document header on or off.  If a second
+\#   numeric argument with units of measure is given, advances that
+\#   distance from the top of the page without printing the document
+\#   header.
 \# *Notes:
 \#   Default is on.  If the 1st argument is <anything> (which turns
 \#   document headers off), the optional 2nd argument may be given
 \#   (with a unit of measure).
 \#
 .MAC DOCHEADER END
-.    ie '\\$1'' \{ .nr #DOC_HEADER 1 \}
+.    ie '\\$1'' .nr #DOC_HEADER 1
 .    el \{\
-.       if !'\\$2'' \{ .nr #ADVANCE_FROM_TOP (\\$2) \}
+.       if !'\\$2'' .nr #ADVANCE_FROM_TOP (\\$2)
 .       nr #DOC_HEADER 0
 .    \}
 .END
 \#
-\#
 \# DOCUMENT HEADER LEADING
 \# -----------------------
 \# *Arguments:
@@ -7946,7 +7534,6 @@
 .    ds $DOCHEADER_LEAD_ADJ \\$1
 .END
 \#
-\#
 \# DOCHEADER ADVANCE
 \# -----------------
 \# *Arguments:
@@ -7961,7 +7548,6 @@
 .    nr #DOCHEADER_ADVANCE (\\$1)
 .END
 \#
-\#
 \# DOCUMENT LEFT MARGIN
 \# --------------------
 \# *Argument:
@@ -7969,7 +7555,7 @@
 \# *Function:
 \#   Creates or modifies register #DOC_L_MARGIN.
 \# *Notes:
-\#   Affects EVERYTHING on the page.
+\#   Affects everything on the page.
 \#
 .MAC DOC_LEFT_MARGIN END
 .    br
@@ -7977,7 +7563,6 @@
 .    L_MARGIN \\n[#DOC_L_MARGIN]u
 .END
 \#
-\#
 \# DOCUMENT RIGHT MARGIN
 \# ---------------------
 \# *Argument:
@@ -7985,7 +7570,7 @@
 \# *Function:
 \#   Creates or modifies register #DOC_R_MARGIN.
 \# *Notes:
-\#   Affects EVERYTHING on the page.
+\#   Affects everything on the page.
 \#
 .MAC DOC_RIGHT_MARGIN END
 .    br
@@ -7994,24 +7579,22 @@
 .    nr #DOC_L_LENGTH \\n[#L_LENGTH]
 .END
 \#
-\#
 \# DOCUMENT LINE LENGTH
 \# --------------------
 \# *Argument:
 \#   <line length of document>
 \# *Function:
-\#   Creates or modifies string $DOC_L_LENGTH.
+\#   Creates or modifies register #DOC_L_LENGTH.
 \# *Notes:
-\#   Affects EVERYTHING on the page.
+\#   Affects everything on the page.
 \#
 .MAC DOC_LINE_LENGTH END
 .    br
 .    nr #DOC_L_LENGTH (\\$1)
 .    LL \\n[#DOC_L_LENGTH]u
-.    ta \\n(.lu
+.    ta \\n[.l]u
 .END
 \#
-\#
 \# DOCUMENT FAMILY
 \# ---------------
 \# *Argument:
@@ -8019,7 +7602,7 @@
 \# *Function:
 \#   Creates or modifies string $DOC_FAM.
 \# *Notes:
-\#   Affects everything EXCEPT headers and footers.
+\#   Affects everything except headers and footers.
 \#
 .MAC DOC_FAMILY END
 .    br
@@ -8032,17 +7615,12 @@
 .    EPIGRAPH_FAMILY   \\*[$DOC_FAM]
 .    FOOTNOTE_FAMILY   \\*[$DOC_FAM]
 .    HDRFTR_FAMILY     \\*[$DOC_FAM]
-.    HEAD_FAMILY       \\*[$DOC_FAM]
 .    LINENUMBER_FAMILY \\*[$DOC_FAM]
-.    PARAHEAD_FAMILY   \\*[$DOC_FAM]
 .    QUOTE_FAMILY      \\*[$DOC_FAM]
-.    SUBHEAD_FAMILY    \\*[$DOC_FAM]
-.    SUBSUBHEAD_FAMILY \\*[$DOC_FAM]
 .    SUBTITLE_FAMILY   \\*[$DOC_FAM]
 .    TITLE_FAMILY      \\*[$DOC_FAM]
 .END
 \#
-\#
 \# DOCUMENT POINT SIZE
 \# -------------------
 \# *Argument:
@@ -8051,16 +7629,15 @@
 \#   Creates or modifies register #DOC_PT_SIZE.
 \# *Notes:
 \#   DOC_PT_SIZE is the basis for calculating all type sizes in
-\#   a document.
+\#   a document.  Ignored if PRINTSTYLE TYPEWRITE.
 \#
 .MAC DOC_PT_SIZE END
-.    if \\n[#IGNORE] \{ .return \}
+.    if \\n[#IGNORE] .return
 .    br
 .    PT_SIZE \\$1
 .    nr #DOC_PT_SIZE \\n[#PT_SIZE]
 .END
 \#
-\#
 \# DOCUMENT LEAD
 \# -------------
 \# *Argument:
@@ -8077,17 +7654,16 @@
 \#   on the overall document lead supplied by the register #DOC_LEAD,
 \#   DOC_LEAD, in the body of a document, should always be associated
 \#   with the start of a new page (in other words, just before or
-\#   just after a manual NEWPAGE).
+\#   just after a manual NEWPAGE).  Ignored if PRINTSTYLE TYPEWRITE.
 \#
 .MAC DOC_LEAD END
-.    if \\n[#IGNORE] \{ .return \}
+.    if \\n[#IGNORE] .return
 .    br
 .    vs \\$1
 .    nr #DOC_LEAD \\n[#LEAD]
-.    if '\\$2'ADJUST' \{ .TRAPS \}
+.    if '\\$2'ADJUST' .TRAPS
 .END
 \#
-\#
 \# ADJUST DOCUMENT LEAD
 \# --------------------
 \# *Arguments:
@@ -8107,7 +7683,6 @@
 .    \}
 .END
 \#
-\#
 \# SHIM
 \# ----
 \# *Argument:
@@ -8125,28 +7700,29 @@
 .MAC PROCESS_SHIM END
 .    while \\n+[#VALID_BASELINE]<\\n[#CURRENT_V_POS] \{\
 .
-.\}
+.    \}
 .    nr #SHIM \\n[#VALID_BASELINE]-\\n[#CURRENT_V_POS]
 .END
 \#
-\# And a macro to disable SHIM (useful sometimes with QUOTE and
-\# BLOCKQUOTE)
+\# And a macro to disable SHIM
 \#
 .MAC NO_SHIM END
-.    ie '\\$1'' \{ .nr #NO_SHIM 1 \}
-.    el         \{ .rr #NO_SHIM   \}
+.    ie '\\$1'' .nr #NO_SHIM 1
+.    el .rr #NO_SHIM
 .END
 \#
+.nr #NO_SHIM 2 \" Restored to 1 in DEFAULTS.
+\#
 .MAC SHIM END
-.    ie r#NO_SHIM \{ .return \}
+.    ie \\n[#NO_SHIM] .return
 .    el \{\
 .       nr #VALID_BASELINE \\n[#T_MARGIN]-1v \\n[#DOC_LEAD]
-.       if !r#CURRENT_V_POS \{ .nr #CURRENT_V_POS \\n(.d \}
+.       if !r#CURRENT_V_POS .nr #CURRENT_V_POS \\n[.d]
 .       ie r#ADVANCE_FROM_TOP \{\
 .          ie \\n[#CURRENT_V_POS]<(\\n[#T_MARGIN]-1v) \{\
 .             while \\n-[#VALID_BASELINE]>\\n[#CURRENT_V_POS] \{\
 .
-.\}
+.             \}
 .             nr #VALID_BASELINE +\\n[#DOC_LEAD]
 .             nr #SHIM \\n[#VALID_BASELINE]-\\n[#CURRENT_V_POS]
 .          \}
@@ -8162,8 +7738,6 @@
 .    \}
 .END
 \#
-\#
-\#
 \# ====================================================================
 \#
 \# +++INTERNATIONALIZATION+++
@@ -8176,17 +7750,17 @@
 \#   Creates or modifies string $ATTRIBUTE_STRING.
 \# *Notes:
 \#   Default is "by".  A blank string ("") may be used if no
-\#   attribution is desired.
+\#   attribution is desired.  Blank line results.
 \#
 .MAC ATTRIBUTE_STRING END
 .    if !'\\$1'DOC_COVER' \{\
-.       if !'\\$1'COVER' \{ .nr #NEITHER 1 \}
+.       if !'\\$1'COVER' .nr #NEITHER 1
 .    \}
 .    if !'\\$1'COVER' \{\
-.       if !'\\$1'DOC_COVER' \{ .nr #NEITHER 1 \}
+.       if !'\\$1'DOC_COVER' .nr #NEITHER 1
 .    \}
 .    if '\\$1'DOC_COVER' \{\
-.       ds $ATTRIBUTE_STRING_DOCCOVER \\$2
+.       ds $ATTRIBUTE_STRING_DOC_COVER \\$2
 .    \}
 .    if '\\$1'COVER' \{\
 .       ds $ATTRIBUTE_STRING_COVER \\$2
@@ -8197,7 +7771,6 @@
 .    \}
 .END
 \#
-\#
 \# CHAPTER STRING
 \# --------------
 \# *Argument:
@@ -8211,7 +7784,6 @@
 .    ds $CHAPTER_STRING \\$1
 .END
 \#
-\#
 \# DRAFT STRING
 \# ------------
 \# *Argument:
@@ -8225,7 +7797,6 @@
 .    ds $DRAFT_STRING \\$1
 .END
 \#
-\#
 \# REVISION STRING
 \# ---------------
 \# *Argument:
@@ -8239,7 +7810,6 @@
 .    ds $REVISION_STRING \\$1
 .END
 \#
-\#
 \# FINIS STRING
 \# ------------
 \# *Argument:
@@ -8254,8 +7824,8 @@
 .END
 \#
 .MAC FINIS_STRING_CAPS END
-.    ie '\\$1'' \{ .nr #FINIS_STRING_CAPS 1 \}
-.    el \{ .nr #FINIS_STRING_CAPS 0 \}
+.    ie '\\$1'' .nr #FINIS_STRING_CAPS 1
+.    el .nr #FINIS_STRING_CAPS 0
 .END
 \#
 \# ====================================================================
@@ -8275,8 +7845,20 @@
 \#   Default is OFF.
 \#
 .MAC RECTO_VERSO END
-.    ie '\\$1'' \{ .nr #RECTO_VERSO 1 \}
-.    el \{ .nr #RECTO_VERSO 0 \}
+.    ie '\\$1'' .nr #RECTO_VERSO 1
+.    el .nr #RECTO_VERSO 0
+.END
+\#
+\# FORCE RECTO
+\# -----------
+\# *Function:
+\#   Forces doccover and cover pages to recto
+\#
+.MAC RV_HARD_SET_MARGINS END
+.    DOC_LEFT_MARGIN  address@hidden
+.    DOC_RIGHT_MARGIN address@hidden
+.    po \\n[#DOC_L_MARGIN]u
+.    LL \\n[#DOC_L_LENGTH]u
 .END
 \#
 \# ====================================================================
@@ -8293,20 +7875,15 @@
 \#   Default is 2 for TYPEWRITE, 3 for TYPESET.
 \#
 .MAC EPIGRAPH_INDENT END
-.    if r#EPI_OFFSET_VALUE        \{ .rr #EPI_OFFSET_VALUE \}
-.    if !'\\*[$EPI_OFFSET_VALUE]'' \{ .rm $EPI_OFFSET_VALUE \}
+.    if \\n[#EPI_OFFSET_VALUE] .rr #EPI_OFFSET_VALUE
+.    if !'\\*[$EPI_OFFSET_VALUE]'' .rm $EPI_OFFSET_VALUE
 .    ds $EVAL_EI_ARG \\$1
 .    substring $EVAL_EI_ARG -1
-.    ie \B'\\*[$EVAL_EI_ARG]' \{\
-.       nr #EPI_OFFSET_VALUE \\$1
-.    \}
-.    el \{\
-.       ds $EPI_OFFSET_VALUE \\$1
-.    \}
+.    ie \B'\\*[$EVAL_EI_ARG]' .nr #EPI_OFFSET_VALUE \\$1
+.    el .ds $EPI_OFFSET_VALUE \\$1
 .    rm $EVAL_EI_ARG
 .END
 \#
-\#
 \# EPIGRAPH AUTOLEAD
 \# -----------------
 \# *Argument:
@@ -8320,7 +7897,6 @@
 .    nr #EPI_AUTOLEAD \\$1
 .END
 \#
-\#
 \# EPIGRAPH
 \# --------
 \# *Arguments:
@@ -8348,7 +7924,7 @@
 .    \}
 .    if \\n[#START] \{\
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          if \\n[#AUTHOR_LINES]=1 \{ .ALD \\n[#DOC_LEAD]u \}
+.          if \\n[#AUTHOR_LINES]=1 .ALD \\n[#DOC_LEAD]u
 .       \}
 .    \}
 .    ie '\\$1'' \{\
@@ -8356,28 +7932,26 @@
 .       ev EPIGRAPH
 .       nr #IN_DIVER 1
 .       ll \\n[#L_LENGTH]u
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .       CHECK_INDENT
 .       if \\n[#COLUMNS] \{\
 .          ie \\n[#START] \{\
 .              ll \\n[#DOC_L_LENGTH]u
-.              ta \\n(.lu
+.              ta \\n[.l]u
 .          \}
 .          el \{\
 .             ll \\n[#COL_L_LENGTH]u
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .       \}
 .       CENTER
 .       if \\n[#PRINT_STYLE]=1 \{\
 .          fam \\*[$TYPEWRITER_FAM]
 .          ft  R
-.          if '\\*[$EPI_FT]'I' \{\
-.             FT I
-.          \}
+.          if '\\*[$EPI_FT]'I' .FT I
 .          ps  \\*[$TYPEWRITER_PS]
-.          ie \\n[#SINGLE_SPACE] \{ .vs \\n[#DOC_LEAD]u \}
-.          el \{ .vs  \\n[#DOC_LEAD]u/2u \}
+.          ie \\n[#SINGLE_SPACE] .vs \\n[#DOC_LEAD]u
+.          el .vs \\n[#DOC_LEAD]u/2u
 .          nr #EPI_LEAD      \\n[#LEAD]
 .          nr #EPI_LEAD_DIFF \\n[#DOC_LEAD]-\\n[#EPI_LEAD]
 .       \}
@@ -8406,52 +7980,47 @@
 .          ev EPIGRAPH
 .          ie \\n[#START] \{\
 .             ie \\n[#COLUMNS] \{\
-.                ie r#EPI_OFFSET_VALUE \{\
-.                   ll 
\\n[#L_LENGTH_FOR_EPI]u-(\\n[#PP_INDENT]u*(\\n[#EPI_OFFSET_VALUE]u*2u))
-.                \}
-.                el \{\
-.                   ll \\n[#L_LENGTH_FOR_EPI]u-(\\*[$EPI_OFFSET_VALUE]u*2u)
-.                \}
-.                ta \\n(.lu
-.             \}
-.             el \{\
-.                ie r#EPI_OFFSET_VALUE \{\
-.                   ll 
\\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#EPI_OFFSET_VALUE]u*2u))
+.                ie r#EPI_OFFSET_VALUE \
+.                   ll \
+\\n[#L_LENGTH_FOR_EPI]u-(\\n[#PP_INDENT]u*(\\n[#EPI_OFFSET_VALUE]u*2u))
+.                el \
+.                   ll \
+\\n[#L_LENGTH_FOR_EPI]u-(\\*[$EPI_OFFSET_VALUE]u*2u)
+.                ta \\n[.l]u
 .                \}
 .                el \{\
+.                ie r#EPI_OFFSET_VALUE \
+.                   ll \
+\\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#EPI_OFFSET_VALUE]u*2u))
+.                el \
 .                   ll \\n[#L_LENGTH]u-(\\*[$EPI_OFFSET_VALUE]*2u)
+.                ta \\n[.l]u
 .                \}
-.                ta \\n(.lu
-.             \}
-.          \}
-.          el \{\
-.             ie r#EPI_OFFSET_VALUE \{\
-.                ll 
\\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#EPI_OFFSET_VALUE]u*2u))
 .             \}
 .             el \{\
+.             ie r#EPI_OFFSET_VALUE \
+.                ll \
+\\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#EPI_OFFSET_VALUE]u*2u))
+.             el \
 .                ll \\n[#L_LENGTH]u-(\\*[$EPI_OFFSET_VALUE]*2u)
-.             \}
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .             if \\n[#COLUMNS] \{\
-.                ie r#EPI_OFFSET_VALUE \{\
-.                   ll 
\\n[#COL_L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#EPI_OFFSET_VALUE]u*2u))
-.                \}
-.                el \{\
+.                ie r#EPI_OFFSET_VALUE \
+.                   ll \
+\\n[#COL_L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#EPI_OFFSET_VALUE]u*2u))
+.                el \
 .                   ll \\n[#COL_L_LENGTH]u-(\\*[$EPI_OFFSET_VALUE]*2u)
-.                \}
-.                ta \\n(.lu
+.                ta \\n[.l]u
 .             \}
 .             CHECK_INDENT
 .          \}
 .          if \\n[#PRINT_STYLE]=1 \{\
 .             fam \\*[$TYPEWRITER_FAM]
 .             ft  R
-.             if '\\*[$EPI_FT]'I' \{\
-.                FT I
-.             \}
+.             if '\\*[$EPI_FT]'I' .FT I
 .             ps  \\*[$TYPEWRITER_PS]
-.             ie \\n[#SINGLE_SPACE] \{ .vs \\n[#DOC_LEAD]u \}
-.             el \{ .vs  \\n[#DOC_LEAD]u/2u \}
+.             ie \\n[#SINGLE_SPACE] .vs \\n[#DOC_LEAD]u
+.             el .vs \\n[#DOC_LEAD]u/2u
 .             QUAD LEFT
 .             HY OFF
 .             nr #EPI_LEAD \\n[#LEAD]
@@ -8485,7 +8054,6 @@
 .    \}
 .END
 \#
-\#
 \# DO EPIGRAPH
 \# -----------
 \# *Arguments:
@@ -8522,24 +8090,23 @@
 .       nr #EPI_WHITESPACE (\\n[#DOC_LEAD]*\\n[#EPI_LINES])-\\n[#EPI_DEPTH]
 .       while \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
 .             nr #EPI_WHITESPACE -\\n[#DOC_LEAD]
-.\}
+.       \}
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          if !\\n[#SINGLE_SPACE]=1 \{ .ALD \\n[#DOC_LEAD]u \}
+.          if !\\n[#SINGLE_SPACE]=1 .ALD \\n[#DOC_LEAD]u
 .       \}
 .       if \\n[#PRINT_STYLE]=2 \{\
-.          ie !\\n[#DOC_TYPE]=2 \{ .RLD \\n[#DOC_LEAD]u \}
+.          ie !\\n[#DOC_TYPE]=2 .RLD \\n[#DOC_LEAD]u
 .          el \{\
-.             ie '\\*[$CHAPTER_TITLE]'' \{ .RLD \\n[#DOC_LEAD]u \}
+.             ie '\\*[$CHAPTER_TITLE]'' .RLD \\n[#DOC_LEAD]u
 .             el \{\
-.                if '\\*[$CHAPTER]'' \{ .RLD \\n[#DOC_LEAD]u \}
+.                if '\\*[$CHAPTER]''    .RLD \\n[#DOC_LEAD]u
 .             \}
 .          \}
-.          if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \{\
+.          if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \
 .             ALD \\n[#EPI_LEAD_DIFF]u+(\\n[#EPI_WHITESPACE]u/2u)
-.          \}
-.          if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
-.             ALD 
\\n[#EPI_LEAD_DIFF]u+(\\n[#EPI_WHITESPACE]u/2u)-\\n[#DOC_LEAD]u
-.          \}
+.          if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \
+.             ALD \
+\\n[#EPI_LEAD_DIFF]u+(\\n[#EPI_WHITESPACE]u/2u)-\\n[#DOC_LEAD]u
 .       \}
 .    \}
 .    el \{\
@@ -8548,51 +8115,56 @@
 .          nr #EPI_WHITESPACE (\\n[#DOC_LEAD]*\\n[#EPI_LINES])-\\n[#EPI_DEPTH]
 .          while \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
 .                nr #EPI_WHITESPACE -\\n[#DOC_LEAD]
-.\}
+.          \}
 .          ie \\n[#PRINT_STYLE]=1 \{\
-.             if \\n[#EPI_WHITESPACE]=\\n[#DOC_LEAD] \{ .ALD 
\\n[#EPI_WHITESPACE]u/2u \}
+.             if \\n[#EPI_WHITESPACE]=\\n[#DOC_LEAD] \
+.                ALD \\n[#EPI_WHITESPACE]u/2u
 .          \}
 .          el \{\
-.             if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \{\
-.                ALD \\n[#EPI_LEAD_DIFF]u+(\\n[#EPI_WHITESPACE]u/2u)
-.             \}
-.             if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
-.                ALD 
\\n[#EPI_LEAD_DIFF]u+(\\n[#EPI_WHITESPACE]u/2u)-\\n[#DOC_LEAD]u
+.             if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \
+.                ALD \
+\\n[#EPI_LEAD_DIFF]u+(\\n[#EPI_WHITESPACE]u/2u)
+.             if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \
+.                ALD \
+\\n[#EPI_LEAD_DIFF]u+(\\n[#EPI_WHITESPACE]u/2u)-\\n[#DOC_LEAD]u
 .             \}
-.          \}
-.          if \\n[#DIVER_FN]=2 \{ .rr #DIVER_FN \}
+.          if \\n[#DIVER_FN]=2 .rr #DIVER_FN
 .       \}
 .       el \{\
 .          nr #EPI_LINES_TO_TRAP 0 1
 .          while \\n[#EPI_LEAD]*\\n+[#EPI_LINES_TO_TRAP]<\\n[#TRAP_DISTANCE] 
\{\
 .                nr #LOOP 1
-.\}
+.          \}
 .          nr #EPI_LINES_TO_TRAP -1
-.          nr #EPI_WHITESPACE 
(\\n[#EPI_LINES_TO_TRAP]*\\n[#DOC_LEAD])-(\\n[#EPI_LINES_TO_TRAP]*\\n[#EPI_LEAD])
+.          nr #EPI_WHITESPACE \
+(\\n[#EPI_LINES_TO_TRAP]*\\n[#DOC_LEAD])-(\\n[#EPI_LINES_TO_TRAP]*\\n[#EPI_LEAD])
 .          while \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
 .                nr #EPI_WHITESPACE -\\n[#DOC_LEAD]
-.\}
-.          if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \{ .ALD 
\\n[#EPI_WHITESPACE]u \}
-.          if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{ .ALD 
\\n[#EPI_WHITESPACE]u-\\n[#DOC_LEAD]u \}
+.          \}
+.          if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \
+.             ALD \\n[#EPI_WHITESPACE]u
+.          if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \
+.             ALD \\n[#EPI_WHITESPACE]u-\\n[#DOC_LEAD]u
 .      \}
 .    \}
 .    if \\n[#EPIGRAPH]=1 \{\
 .       po \\n[#L_MARGIN]u
 .       if \\n[#COLUMNS] \{\
 .          po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
-.          nr #L_MARGIN \\n(.o
+.          nr #L_MARGIN \\n[.o]
 .       \}
 .    \}
 .    if \\n[#EPIGRAPH]=2 \{\
-.       ie r#EPI_OFFSET_VALUE \{\
-.          nr #EPI_OFFSET 
\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
-.       \}
-.       el \{ .nr #EPI_OFFSET \\n[#L_MARGIN]+\\*[$EPI_OFFSET_VALUE] \}
+.       ie r#EPI_OFFSET_VALUE \
+.          nr #EPI_OFFSET \
+\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
+.       el .nr #EPI_OFFSET \\n[#L_MARGIN]+\\*[$EPI_OFFSET_VALUE]
 .       if \\n[#COLUMNS] \{\
-.          ie r#EPI_OFFSET_VALUE \{\
-.             nr #EPI_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
-.          \}
-.          el \{ .nr #EPI_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$EPI_OFFSET_VALUE] \}
+.          ie r#EPI_OFFSET_VALUE \
+.             nr #EPI_OFFSET \
+\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
+.          el .nr #EPI_OFFSET \
+\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$EPI_OFFSET_VALUE]
 .       \}
 .       po \\n[#EPI_OFFSET]u
 .    \}
@@ -8600,16 +8172,12 @@
 .    EPI_TEXT
 .    br
 .    ie \\n[#START] \{\
-.       if \\n[#PRINT_STYLE]=1 \{\
-.          SHIM
-.       \}
+.       if \\n[#PRINT_STYLE]=1 .SHIM
 .       if \\n[#PRINT_STYLE]=2 \{\
-.          if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \{\
+.          if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \
 .             ALD \\n[#EPI_WHITESPACE]u/2u
-.          \}
-.          if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
+.          if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \
 .             ALD (\\n[#EPI_WHITESPACE]u/2u)-\\n[#DOC_LEAD]u
-.          \}
 .          SHIM
 .       \}
 .    \}
@@ -8618,40 +8186,41 @@
 .       ie \\n[#EPI_FITS] \{\
 .          ie \\n[#FN_FOR_EPI] \{\
 .             nr #EPI_LINES_TO_END 1
-.             nr #EPI_WHITESPACE 
(\\n[#EPI_LINES_TO_END]*\\n[#DOC_LEAD])-(\\n[#EPI_LINES_TO_END]*\\n[#EPI_LEAD])
+.             nr #EPI_WHITESPACE \
+(\\n[#EPI_LINES_TO_END]*\\n[#DOC_LEAD])-(\\n[#EPI_LINES_TO_END]*\\n[#EPI_LEAD])
 .             while \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
 .                   nr #EPI_WHITESPACE -\\n[#DOC_LEAD]
-.\}
+.             \}
 .             ALD \\n[#EPI_WHITESPACE]u-(\\n[#DOC_LEAD]u-\\n[#EPI_LEAD]u)
 .          \}
 .          el \{\
 .             ie \\n[#PRINT_STYLE]=1 \{\
-.                if \\n[#EPI_WHITESPACE]=\\n[#DOC_LEAD] \{ .ALD 
\\n[#EPI_WHITESPACE]u \}
+.                if \\n[#EPI_WHITESPACE]=\\n[#DOC_LEAD] \
+.                   ALD \\n[#EPI_WHITESPACE]u
 .             \}
 .             el \{\
-.                if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \{\
+.                if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \
 .                   ALD \\n[#EPI_WHITESPACE]u/2u
-.                \}
-.                if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
+.                if \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \
 .                   ALD (\\n[#EPI_WHITESPACE]u/2u)-\\n[#DOC_LEAD]u
 .                \}
 .             \}
 .          \}
-.       \}
 .       el \{\
 .          nr #EPI_LINES_TO_END \\n[#EPI_LINES]-\\n[#EPI_LINES_TO_TRAP]
-.          if \\n[#LOOP] \{ .nr #EPI_LINES_TO_END +1 \}
+.          if \\n[#LOOP] .nr #EPI_LINES_TO_END +1
 .          rr #LOOP
-.          nr #EPI_WHITESPACE 
(\\n[#EPI_LINES_TO_END]*\\n[#DOC_LEAD])-(\\n[#EPI_LINES_TO_END]*\\n[#EPI_LEAD])
+.          nr #EPI_WHITESPACE \
+(\\n[#EPI_LINES_TO_END]*\\n[#DOC_LEAD])-(\\n[#EPI_LINES_TO_END]*\\n[#EPI_LEAD])
 .          while \\n[#EPI_WHITESPACE]>\\n[#DOC_LEAD] \{\
 .                nr #EPI_WHITESPACE -\\n[#DOC_LEAD]
-.\}
+.          \}
 .          ALD \\n[#EPI_WHITESPACE]u-(\\n[#DOC_LEAD]u-\\n[#EPI_LEAD]u)
 .          if \\n[#PRINT_STYLE]=1 \{\
 .             if !\\n[#SINGLE_SPACE] \{\
 .                nr #EPI_LINES_EVEN \\n[#EPI_LINES_TO_END]%2
-.                ie \\n[#EPI_LINES_EVEN] \{ .ALD .5v \}
-.                el \{ .RLD .5v \}
+.                ie \\n[#EPI_LINES_EVEN] .ALD .5v
+.                el .RLD .5v
 .                rr #EPI_LINES_EVEN
 .             \}
 .          \}
@@ -8664,12 +8233,12 @@
 .    po \\n[#L_MARGIN]u
 .    if \\n[#COLUMNS] \{\
 .       po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
-.       nr #L_MARGIN \\n(.o
+.       nr #L_MARGIN \\n[.o]
 .    \}
 .    if \\n[#START] \{\
 .       if \\n[#COLUMNS] \{\
 .          po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
-.          nr #L_MARGIN \\n(.o
+.          nr #L_MARGIN \\n[.o]
 .          mk dc
 .       \}
 .    \}
@@ -8692,27 +8261,37 @@
 \#
 .MAC FINIS END
 .    br
+.    if address@hidden \{\
+.       if \\n[.t]<=1v \{\
+.          tm1 "[mom]: Insufficient room to print \\$0 on last page.
+.          return
+.       \}
+.    \}
 .    ev FINIS
 .    evc 0
-.    if \\n[#TAB_ACTIVE] \{ .TQ \}
-.    if \\n[#INDENT_ACTIVE] \{ .IQ CLEAR \}
+.    if \\n[#TAB_ACTIVE] .TQ
+.    if \\n[#INDENT_ACTIVE] .IQ CLEAR
 .    nr #EM_ADJUST (1m/8)
 .    if \\n[#COLUMNS] \{\
 .       po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
-.       nr #L_MARGIN \\n(.o
+.       nr #L_MARGIN \\n[.o]
 .    \}
 .    ALD \\n[#DOC_LEAD]u
 .    CENTER
-.    if \\n[#FINIS_STRING_CAPS]=1 \{ .CAPS \}
-.    if \\n[#PRINT_STYLE]=1 \{ .PRINT "--\\*[$FINIS_STRING]--\}
+.    if \\n[#FINIS_STRING_CAPS]=1 .CAPS
+.    if \\n[#PRINT_STYLE]=1 .PRINT "--\\*[$FINIS_STRING]--
 .    if \\n[#PRINT_STYLE]=2 \{\
-.       ie \\n[#FINIS_COLOR] \{\
-.          PRINT 
"\m[\\*[$FINIS_COLOR]]\v'-\\n[#EM_ADJUST]u'\(em\v'+\\n[#EM_ADJUST]u'\\*[$FINIS_STRING]\v'-\\n[#EM_ADJUST]u'\*[FU1]\(em\m[]
-.       \}
-.       el \{ .PRINT 
\v'-\\n[#EM_ADJUST]u'\(em\v'+\\n[#EM_ADJUST]u'\\*[$FINIS_STRING]\v'-\\n[#EM_ADJUST]u'\*[FU1]\(em\m[]
 \}
+.       ie \\n[#FINIS_COLOR] \
+.          PRINT \
+\m[\\*[$FINIS_COLOR]]\v'-\\n[#EM_ADJUST]u'\[em]\v'+\\n[#EM_ADJUST]u'\
+\\*[$FINIS_STRING]\v'-\\n[#EM_ADJUST]u'\*[FU1]\[em]\m[]
+.       el .PRINT \
+\v'-\\n[#EM_ADJUST]u'\[em]\v'+\\n[#EM_ADJUST]u'\
+\\*[$FINIS_STRING]\v'-\\n[#EM_ADJUST]u'\*[FU1]\[em]\m[]
 .    \}
-.    if \\n[#FINIS_STRING_CAPS]=1 \{ .CAPS OFF \}
+.    if \\n[#FINIS_STRING_CAPS]=1 .CAPS OFF
 .    ev
+.    pdfsync
 .END
 \#
 \# ====================================================================
@@ -8725,7 +8304,6 @@
 \#
 .ds PAGE# \En[#PAGENUMBER]
 \#
-\#
 \# HDRFTR RULE GAP
 \# ---------------
 \# *Argument:
@@ -8740,15 +8318,14 @@
 .    nr #HDRFTR_RULE_GAP (\\$1)
 .    if '\\$0'HEADER_RULE_GAP' \{\
 .       nr #HEADER_RULE_GAP \\n[#HDRFTR_RULE_GAP]
-.       if r#FOOTER_RULE_GAP \{ .nr #FOOTER_RULE_GAP \\n[#FOOTER_RULE_GAP] \}
+.       if r #FOOTER_RULE_GAP .nr #FOOTER_RULE_GAP \\n[#FOOTER_RULE_GAP]
 .    \}
 .    if '\\$0'FOOTER_RULE_GAP' \{\
 .       nr #FOOTER_RULE_GAP \\n[#HDRFTR_RULE_GAP]
-.       if r#HEADER_RULE_GAP \{ .nr #HEADER_RULE_GAP \\n[#HEADER_RULE_GAP] \}
+.       if r #HEADER_RULE_GAP .nr #HEADER_RULE_GAP \\n[#HEADER_RULE_GAP]
 .    \}
 .END
 \#
-\#
 \# HDRFTR LEFT
 \# -----------
 \# *Argument:
@@ -8766,7 +8343,7 @@
 \#   If the argument is the # character, simply prints the current
 \#   page number.
 \#
-\#   If the user wants to *incorporate* the page number into the string,
+\#   If the user wants to incorporate the page number into the string,
 \#   \*[PAGE#] must be used.  For example, if the user wants to put
 \#   an elipsis before the page number in the string, s/he should use
 \#   ...\*[PAGE#], not ...#
@@ -8776,7 +8353,6 @@
 .    ds $HDRFTR_LEFT \\$1
 .END
 \#
-\#
 \# HDRFTR LEFT CAPS
 \# ----------------
 \# *Argument:
@@ -8788,16 +8364,13 @@
 \#   Default is on.
 \#
 .MAC HDRFTR_LEFT_CAPS END
-.    ie '\\$1'' \{\
-.        nr #HDRFTR_LEFT_CAPS 1
-.    \}
+.    ie '\\$1'' .nr #HDRFTR_LEFT_CAPS 1
 .    el \{\
 .       nr #HDRFTR_LEFT_CAPS 0
 .       ds $HDRFTR_LEFT_SIZE_CHANGE +0
 .    \}
 .END
 \#
-\#
 \# HDRFTR CENTER
 \# -------------
 \# *Argument:
@@ -8814,7 +8387,7 @@
 \#   If the argument is the # character, simply prints the current
 \#   page number.
 \#
-\#   If the user wants to *incorporate* the page number into the string,
+\#   If the user wants to incorporate the page number into the string,
 \#   \*[PAGE#] must be used.  For example, if the user wants to put
 \#   an elipsis before the page number in the string, s/he should use
 \#   ...\*[PAGE#], not ...#
@@ -8832,7 +8405,6 @@
 .    ds $HDRFTR_CENTER \\$1
 .END
 \#
-\#
 \# HDRFTR CENTER CAPS
 \# ------------------
 \# *Argument:
@@ -8844,16 +8416,13 @@
 \#   Default is on.
 \#
 .MAC HDRFTR_CENTER_CAPS END
-.    ie '\\$1'' \{\
-.       nr #HDRFTR_CENTER_CAPS 1
-.    \}
+.    ie '\\$1'' .nr #HDRFTR_CENTER_CAPS 1
 .    el \{\
 .       nr #HDRFTR_CENTER_CAPS 0
 .       ds $HDRFTR_CENTER_SIZE_CHANGE +0
 .    \}
 .END
 \#
-\#
 \# HDRFTR CENTER PADDING
 \# ---------------------
 \# *Argument:
@@ -8867,20 +8436,15 @@
 \#   line length.  Long titles or long author names can screw up
 \#   visual centering, or create overprints.  This macro allows the
 \#   user to pad the center string by the specified amount of space
-\#   to fix these problems.  Use only one of LEFT or RIGHT.
+\#   to fix these problems.
 \#
 \#   A unit of measure is required.
 \#
 .MAC HDRFTR_CENTER_PAD END
-.    if '\\$1'LEFT' \{\
-.       nr #HDRFTR_CTR_PAD_LEFT (\\$2)
-.    \}
-.    if '\\$1'RIGHT' \{\
-.       nr #HDRFTR_CTR_PAD_RIGHT (\\$2)
-.    \}
+.    if '\\$1'LEFT'  .nr #HDRFTR_CTR_PAD_LEFT (\\$2)
+.    if '\\$1'RIGHT' .nr #HDRFTR_CTR_PAD_RIGHT (\\$2)
 .END
 \#
-\#
 \# SWITCH HDRFTR CENTER PADDING SIDE - support macro
 \# --------------------------------
 \# *Argument:
@@ -8897,7 +8461,6 @@
 .    HDRFTR_CENTER_PAD RIGHT \\n[#HDRFTR_CTR_PAD_TMP]u
 .END
 \#
-\#
 \# HDRFTR RIGHT
 \# ------------
 \# *Argument:
@@ -8913,7 +8476,7 @@
 \#   If the argument is the # character, simply prints the current
 \#   page number.
 \#
-\#   If the user wants to *incorporate* the page number into the string,
+\#   If the user wants to incorporate the page number into the string,
 \#   \*[PAGE#] must be used.  For example, if the user wants to put
 \#   an elipsis before the page number in the string, s/he should use
 \#   ...\*[PAGE#], not ...#
@@ -8923,7 +8486,6 @@
 .    ds $HDRFTR_RIGHT \\$1
 .END
 \#
-\#
 \# HDRFTR RIGHT CAPS
 \# -----------------
 \# *Argument:
@@ -8935,16 +8497,13 @@
 \#   Default is on.
 \#
 .MAC HDRFTR_RIGHT_CAPS END
-.    ie '\\$1'' \{\
-.       nr #HDRFTR_RIGHT_CAPS 1
-.    \}
+.    ie '\\$1'' .nr #HDRFTR_RIGHT_CAPS 1
 .    el \{\
 .       nr #HDRFTR_RIGHT_CAPS 0
 .       ds $HDRFTR_RIGHT_SIZE_CHANGE +0
 .    \}
 .END
 \#
-\#
 \# HDRFTR RULE
 \# -----------
 \# *Arguments:
@@ -8954,25 +8513,26 @@
 \#   under the header/over the footer.  Otherwise, turns HDRFTR_RULE
 \#   on or off.
 \#
-.MAC HDRFTR_RULE END   \"To print rule under header/over footer.
-.    if r#HEADERS_ON \{\
-.       if \\n[#HEADERS_ON]=1 \{ .nr #HDRFTR_RULE_GAP \\n[#HEADER_RULE_GAP] \}
+.MAC HDRFTR_RULE END
+.    if r #HEADERS_ON \{\
+.       if \\n[#HEADERS_ON]=1 .nr #HDRFTR_RULE_GAP \\n[#HEADER_RULE_GAP]
 .    \}
-.    if r#FOOTERS_ON \{\
-.       if \\n[#FOOTERS_ON]=1 \{ .nr #HDRFTR_RULE_GAP \\n[#FOOTER_RULE_GAP] \}
+.    if r #FOOTERS_ON \{\
+.       if \\n[#FOOTERS_ON]=1 .nr #HDRFTR_RULE_GAP \\n[#FOOTER_RULE_GAP]
 .    \}
 .    if '\\$0'HDRFTR_RULE_INTERNAL' \{\
 .       ie \\n[#USERDEF_HDRFTR] \{\
 .          nr #CAP_HEIGHT_ADJUST \\n[#HDRFTR_HEIGHT]
 .          if \\n[#HEADERS_ON] \{\
-.             rt \\nyu
+.             rt \\n[y]u
 .             ALD \\n[#HDRFTR_RULE_GAP]u
 .             nr #HDRFTR_RULE_WEIGHT     \\n[#HEADER_RULE_WEIGHT]
 .             nr #HDRFTR_RULE_WEIGHT_ADJ \\n[#HEADER_RULE_WEIGHT_ADJ]
 .          \}
 .          if \\n[#FOOTERS_ON] \{\
-.             rt \\nyu
-.             RLD 
\\n[#HDRFTR_RULE_GAP]u+\\n[#CAP_HEIGHT_ADJUST]u+\\n[#FOOTER_RULE_WEIGHT]u
+.             rt \\n[y]u
+.             RLD \
+\\n[#HDRFTR_RULE_GAP]u+\\n[#CAP_HEIGHT_ADJUST]u+\\n[#FOOTER_RULE_WEIGHT]u
 .             nr #HDRFTR_RULE_WEIGHT     \\n[#FOOTER_RULE_WEIGHT]
 .             nr #HDRFTR_RULE_WEIGHT_ADJ \\n[#FOOTER_RULE_WEIGHT_ADJ]
 .          \}
@@ -8997,28 +8557,25 @@
 .          br
 .       \}
 .       el \{\
-.          if \\n[#PRINT_STYLE]=1 \{\
-.             nr #CAP_HEIGHT_ADJUST \\n[#CAP_HEIGHT]
-.          \}
+.          if \\n[#PRINT_STYLE]=1 .nr #CAP_HEIGHT_ADJUST \\n[#CAP_HEIGHT]
 .          if \\n[#PRINT_STYLE]=2 \{\
-.             ie \\n[#LEFT_CAP_HEIGHT]>\\n[#CENTER_CAP_HEIGHT] \{\
+.             ie \\n[#LEFT_CAP_HEIGHT]>\\n[#CENTER_CAP_HEIGHT] \
 .                nr #CAP_HEIGHT_ADJUST \\n[#LEFT_CAP_HEIGHT]
-.             \}
-.             el \{ .nr #CAP_HEIGHT_ADJUST \\n[#CENTER_CAP_HEIGHT] \}
-.             ie \\n[#CAP_HEIGHT_ADJUST]>\\n[#RIGHT_CAP_HEIGHT] \{\
+.             el .nr #CAP_HEIGHT_ADJUST \\n[#CENTER_CAP_HEIGHT]
+.             ie \\n[#CAP_HEIGHT_ADJUST]>\\n[#RIGHT_CAP_HEIGHT] \
 .                nr #CAP_HEIGHT_ADJUST \\n[#CAP_HEIGHT_ADJUST]
-.             \}
-.             el \{ .nr #CAP_HEIGHT_ADJUST \\n[#RIGHT_CAP_HEIGHT] \}
+.             el .nr #CAP_HEIGHT_ADJUST \\n[#RIGHT_CAP_HEIGHT]
 .          \}
 .          if \\n[#HEADERS_ON] \{\
-.             rt \\nyu
+.             rt \\n[y]u
 .             ALD \\n[#HDRFTR_RULE_GAP]u
 .             nr #HDRFTR_RULE_WEIGHT     \\n[#HEADER_RULE_WEIGHT]
 .             nr #HDRFTR_RULE_WEIGHT_ADJ \\n[#HEADER_RULE_WEIGHT_ADJ]
 .          \}
 .          if \\n[#FOOTERS_ON] \{\
-.             rt \\nyu
-.             RLD 
\\n[#HDRFTR_RULE_GAP]u+\\n[#CAP_HEIGHT_ADJUST]u+\\n[#FOOTER_RULE_WEIGHT]u
+.             rt \\n[y]u
+.             RLD \
+\\n[#HDRFTR_RULE_GAP]u+\\n[#CAP_HEIGHT_ADJUST]u+\\n[#FOOTER_RULE_WEIGHT]u
 .             nr #HDRFTR_RULE_WEIGHT     \\n[#FOOTER_RULE_WEIGHT]
 .             nr #HDRFTR_RULE_WEIGHT_ADJ \\n[#FOOTER_RULE_WEIGHT_ADJ]
 .          \}
@@ -9064,15 +8621,13 @@
 .       \}
 .    \}
 .    if '\\$0'HDRFTR_RULE' \{\
-.       ie '\\$1'' \{ .nr #HDRFTR_RULE 1 \}
-.       el         \{ .nr #HDRFTR_RULE 0 \}
+.       ie '\\$1'' .nr #HDRFTR_RULE 1
+.       el .nr #HDRFTR_RULE 0
 .    \}
 .END
 \#
-\#
 .ALIAS HDRFTR_RULE_INTERNAL HDRFTR_RULE
 \#
-\#
 \# HDRFTR PLAIN
 \# ------------
 \# *Arguments:
@@ -9099,7 +8654,6 @@
 .    HDRFTR_RIGHT_CAPS    OFF
 .END
 \#
-\#
 \# SWITCH HDRFTR
 \# -------------
 \# *Arguments:
@@ -9124,11 +8678,10 @@
 \# desired string in the desired place on the desired recto/verso page.
 \# 
 .MAC SWITCH_HDRFTR END
-.    ie '\\$1'' \{ .nr #SWITCH_HDRFTR 1 \}
-.    el \{ .nr #SWITCH_HDRFTR 0 \}
+.    ie '\\$1'' .nr #SWITCH_HDRFTR 1
+.    el .nr #SWITCH_HDRFTR 0
 .END
 \#
-\#
 \# USER DEFINED HDRFTR RECTO
 \# -------------------------
 \# *Arguments:
@@ -9145,24 +8698,21 @@
 \#
 .MAC HDRFTR_RECTO END
 .    nr #USERDEF_HDRFTR 1
-.    if '\\$1'L'      \{ .nr #USERDEF_HDRFTR_RECTO_QUAD 1 \}
-.    if '\\$1'LEFT'   \{ .nr #USERDEF_HDRFTR_RECTO_QUAD 1 \}
-.    if '\\$1'C'      \{ .nr #USERDEF_HDRFTR_RECTO_QUAD 2 \}
-.    if '\\$1'CENTER' \{ .nr #USERDEF_HDRFTR_RECTO_QUAD 2 \}
-.    if '\\$1'CENTRE' \{ .nr #USERDEF_HDRFTR_RECTO_QUAD 2 \}
-.    if '\\$1'R'      \{ .nr #USERDEF_HDRFTR_RECTO_QUAD 3 \}
-.    if '\\$1'RIGHT'  \{ .nr #USERDEF_HDRFTR_RECTO_QUAD 3 \}
+.    if '\\$1'L'      .nr #USERDEF_HDRFTR_RECTO_QUAD 1
+.    if '\\$1'LEFT'   .nr #USERDEF_HDRFTR_RECTO_QUAD 1
+.    if '\\$1'C'      .nr #USERDEF_HDRFTR_RECTO_QUAD 2
+.    if '\\$1'CENTER' .nr #USERDEF_HDRFTR_RECTO_QUAD 2
+.    if '\\$1'CENTRE' .nr #USERDEF_HDRFTR_RECTO_QUAD 2
+.    if '\\$1'R'      .nr #USERDEF_HDRFTR_RECTO_QUAD 3
+.    if '\\$1'RIGHT'  .nr #USERDEF_HDRFTR_RECTO_QUAD 3
 .    shift
 .    ie '\\$1'CAPS' \{\
 .       nr #HDRFTR_RECTO_CAPS 1
 .       ds $USERDEF_HDRFTR_RECTO \\$2
 .    \}
-.    el \{\
-.       ds $USERDEF_HDRFTR_RECTO \\$1
-.    \}
+.    el .ds $USERDEF_HDRFTR_RECTO \\$1
 .END
 \#
-\#
 \# USER DEFINED HDRFTR VERSO
 \# -------------------------
 \# *Arguments:
@@ -9177,21 +8727,19 @@
 \#
 .MAC HDRFTR_VERSO END
 .    nr #USERDEF_HDRFTR 1
-.    if '\\$1'L'      \{ .nr #USERDEF_HDRFTR_VERSO_QUAD 1 \}
-.    if '\\$1'LEFT'   \{ .nr #USERDEF_HDRFTR_VERSO_QUAD 1 \}
-.    if '\\$1'C'      \{ .nr #USERDEF_HDRFTR_VERSO_QUAD 2 \}
-.    if '\\$1'CENTER' \{ .nr #USERDEF_HDRFTR_VERSO_QUAD 2 \}
-.    if '\\$1'CENTRE' \{ .nr #USERDEF_HDRFTR_VERSO_QUAD 2 \}
-.    if '\\$1'R'      \{ .nr #USERDEF_HDRFTR_VERSO_QUAD 3 \}
-.    if '\\$1'RIGHT'  \{ .nr #USERDEF_HDRFTR_VERSO_QUAD 3 \}
+.    if '\\$1'L'      .nr #USERDEF_HDRFTR_VERSO_QUAD 1
+.    if '\\$1'LEFT'   .nr #USERDEF_HDRFTR_VERSO_QUAD 1
+.    if '\\$1'C'      .nr #USERDEF_HDRFTR_VERSO_QUAD 2
+.    if '\\$1'CENTER' .nr #USERDEF_HDRFTR_VERSO_QUAD 2
+.    if '\\$1'CENTRE' .nr #USERDEF_HDRFTR_VERSO_QUAD 2
+.    if '\\$1'R'      .nr #USERDEF_HDRFTR_VERSO_QUAD 3
+.    if '\\$1'RIGHT'  .nr #USERDEF_HDRFTR_VERSO_QUAD 3
 .    shift
 .    ie '\\$1'CAPS' \{\
 .       nr #HDRFTR_VERSO_CAPS 1
 .       ds $USERDEF_HDRFTR_VERSO \\$2
 .    \}
-.   el \{\
-.      ds $USERDEF_HDRFTR_VERSO \\$1
-.   \}
+.    el .ds $USERDEF_HDRFTR_VERSO \\$1
 .END
 \#
 \# PRINT FOOTER ON FIRST PAGE
@@ -9205,11 +8753,10 @@
 \#   page of doc.
 \#
 .MAC FOOTER_ON_FIRST_PAGE END
-.    ie '\\$1'' \{ .nr #PRINT_FOOTER_ON_PAGE_1 1 \}
-.    el \{ .rr #PRINT_FOOTER_ON_PAGE_1 \}
+.    ie '\\$1'' .nr #PRINT_FOOTER_ON_PAGE_1 1
+.    el .rr #PRINT_FOOTER_ON_PAGE_1
 .END
 \#
-\#
 \# PRINT PAGE NUMBER ON FIRST PAGE
 \# -------------------------------
 \# *Arguments:
@@ -9222,11 +8769,10 @@
 \#   has been user set at top of page.
 \#
 .MAC PAGENUM_ON_FIRST_PAGE END
-.    ie '\\$1'' \{ .nr #PRINT_PAGENUM_ON_PAGE_1 1 \}
-.    el \{ .rr #PRINT_PAGENUM_ON_PAGE_1 \}
+.    ie '\\$1'' .nr #PRINT_PAGENUM_ON_PAGE_1 1
+.    el .rr #PRINT_PAGENUM_ON_PAGE_1
 .END
 \#
-\#
 \# PRINT HEADER/FOOTER
 \# -------------------
 \# *Arguments:
@@ -9245,12 +8791,12 @@
 .       if \\n[#START_FOR_FOOTERS] \{\
 .          rr #START_FOR_FOOTERS
 .          if !\\n[#PRINT_FOOTER_ON_PAGE_1] \{\
-.             ie !\\n[#HDRFTR_BOTH] \{ .return \}
+.             ie !\\n[#HDRFTR_BOTH] .return
 .             el \{\
 .                rr #FOOTERS_ON
 .                nr #HEADERS_ON 1
-.                ie \\n[#HEADER_RULE]=1 \{ .HEADER_RULE \}
-.                el \{ .HEADER_RULE OFF \}
+.                ie \\n[#HEADER_RULE]=1 .HEADER_RULE
+.                el .HEADER_RULE OFF
 .                HEADER_RECTO \\*[$HDR_RECTO_QUAD] "\\*[$HDR_RECTO_STRING]"
 .                return
 .             \}
@@ -9281,7 +8827,7 @@
 .       nr #SWITCH_HDRFTR 0
 .    \}
 .    nr #PAGENUMBER \\n%+\\n[#PAGE_NUM_ADJ]
-.    if \\n[#ENDNOTES] \{ .PAGENUM_STYLE \\*[$EN_PN_STYLE] \}
+.    if \\n[#ENDNOTES] .PAGENUM_STYLE \\*[$EN_PN_STYLE]
 .    if \\n[#PRINT_STYLE]=1 \{\
 .       if \\n[#FOOTERS_ON] \{\
 .          di NULL
@@ -9289,42 +8835,40 @@
 .          nr #LEFT_CAP_HEIGHT \\n[#CAP_HEIGHT]
 .          di
 .       \}
-.       if o                        \{ .RIGHT \}
-.       if e                        \{ .LEFT  \}
-.       if \\n[#RECTO_VERSO]=0      \{ .LEFT  \}
-.       if \\n[#HDRFTR_LEFT_CAPS]   \{ .CAPS  \}
+.       if o .RIGHT
+.       if e .LEFT
+.       if \\n[#RECTO_VERSO]=0    .LEFT
+.       if \\n[#HDRFTR_LEFT_CAPS] .CAPS
 .       ie '\\*[$HDRFTR_LEFT]'#' \{\
 .           PRINT \\n[#PAGENUMBER]
 .       \}
 .       el \{\
-.          ie !'\\*[$HDRFTR_LEFT]'' \{ . PRINT \\*[$HDRFTR_LEFT] \}
-.          el \{ .PRINT \& \}
+.          ie !'\\*[$HDRFTR_LEFT]'' .PRINT \\*[$HDRFTR_LEFT]
+.          el .PRINT \&
 .       \}
-.       if \\n[#HDRFTR_LEFT_CAPS] \{ .CAPS OFF \}
+.       if \\n[#HDRFTR_LEFT_CAPS]   .CAPS OFF
 .       CENTER
-.       if \\n[#HDRFTR_CENTER_CAPS] \{ .CAPS \}
-.       rt \\nyu
-.       ie '\\*[$HDRFTR_CENTER]'#' \{\
-.           PRINT 
\\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\\n[#PAGENUMBER]\\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'
-.       \}
-.       el \{\
-.          ie !'\\*[$HDRFTR_CENTER]'' \{ .PRINT 
\\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\\*[$HDRFTR_CENTER]\\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'
 \}
-.          el \{ .PRINT \& \}
-.       \}
-.       if \\n[#HDRFTR_CENTER_CAPS] \{ .CAPS OFF \}
-.       if o                        \{ .LEFT  \}
-.       if e                        \{ .RIGHT \}
-.       if \\n[#RECTO_VERSO]=0      \{ .RIGHT \}
-.       if \\n[#HDRFTR_RIGHT_CAPS]  \{ .CAPS  \}
-.       rt \\nyu
-.       ie '\\*[$HDRFTR_RIGHT]'#' \{\
-.           PRINT \\n[#PAGENUMBER]
-.       \}
+.       if \\n[#HDRFTR_CENTER_CAPS] .CAPS
+.       rt \\n[y]u
+.       ie '\\*[$HDRFTR_CENTER]'#' .PRINT \
+\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\\n[#PAGENUMBER]\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'
+.       el \{\
+.          ie !'\\*[$HDRFTR_CENTER]'' .PRINT \
+\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\\*[$HDRFTR_CENTER]\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'
+.          el .PRINT \&
+.       \}
+.       if \\n[#HDRFTR_CENTER_CAPS] .CAPS OFF
+.       if o .LEFT
+.       if e .RIGHT
+.       if \\n[#RECTO_VERSO]=0     .RIGHT
+.       if \\n[#HDRFTR_RIGHT_CAPS] .CAPS
+.       rt \\n[y]u
+.       ie '\\*[$HDRFTR_RIGHT]'#' .PRINT \\n[#PAGENUMBER]
 .       el \{\
-.          ie !'\\*[$HDRFTR_RIGHT]'' \{ .PRINT \\*[$HDRFTR_RIGHT] \}
-.          el \{ .PRINT \& \}
+.          ie !'\\*[$HDRFTR_RIGHT]'' .PRINT \\*[$HDRFTR_RIGHT]
+.          el .PRINT \&
 .       \}
-.       if \\n[#HDRFTR_RIGHT_CAPS] \{ .CAPS OFF \}
+.       if \\n[#HDRFTR_RIGHT_CAPS] .CAPS OFF
 .    \}
 .    if \\n[#PRINT_STYLE]=2 \{\
 .       if \\n[#HDRFTR_COLOR]=1 \{\
@@ -9341,30 +8885,26 @@
 .          nr #LEFT_CAP_HEIGHT \\n[#CAP_HEIGHT]
 .          di
 .       \}
-.       if o                      \{ .LEFT  \}
-.       if e                      \{ .RIGHT \}
-.       if \\n[#RECTO_VERSO]=0    \{ .LEFT  \}
-.       if \\n[#HDRFTR_LEFT_CAPS] \{ .CAPS  \}
+.       if o .LEFT
+.       if e .RIGHT
+.       if \\n[#RECTO_VERSO]=0 .LEFT
+.       if \\n[#HDRFTR_LEFT_CAPS] .CAPS
 .       ie '\\*[$HDRFTR_LEFT]'#' \{\
-.          ie \\n[#HDRFTR_LEFT_COLOR]=1 \{\
+.          ie \\n[#HDRFTR_LEFT_COLOR]=1 \
 .             PRINT \m[\\*[$HDRFTR_LEFT_COLOR]]\\n[#PAGENUMBER]\m[]
-.          \}
-.          el \{\
+.          el \
 .             PRINT \\n[#PAGENUMBER]
 .          \}
-.       \}
 .       el \{\
 .          ie !'\\*[$HDRFTR_LEFT]'' \{\
-.             ie \\n[#HDRFTR_LEFT_COLOR]=1 \{\
+.             ie \\n[#HDRFTR_LEFT_COLOR]=1 \
 .                 PRINT \m[\\*[$HDRFTR_LEFT_COLOR]]\\*[$HDRFTR_LEFT]\m[]
-.             \}
-.             el \{\
+.             el \
 .                 PRINT \\*[$HDRFTR_LEFT]
 .             \}
+.          el .PRINT \&
 .          \}
-.          el \{ .PRINT \& \}
-.       \}
-.       if \\n[#HDRFTR_LEFT_CAPS] \{ .CAPS OFF \}
+.       if \\n[#HDRFTR_LEFT_CAPS] .CAPS OFF
 .       fam     \\*[$HDRFTR_CENTER_FAM]
 .       ft      \\*[$HDRFTR_CENTER_FT]
 .       ps      \\n[#HDRFTR_PT_SIZE]u\\*[$HDRFTR_CENTER_SIZE_CHANGE]
@@ -9376,28 +8916,26 @@
 .          di
 .       \}
 .       CENTER
-.       if \\n[#HDRFTR_CENTER_CAPS] \{ .CAPS \}
-.       rt \\nyu
+.       if \\n[#HDRFTR_CENTER_CAPS] .CAPS
+.       rt \\n[y]u
 .       ie '\\*[$HDRFTR_CENTER]'#' \{\
-.           ie \\n[#HDRFTR_CENTER_COLOR]=1 \{\
-.              PRINT 
\\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\m[\\*[$HDRFTR_CENTER_COLOR]]\\n[#PAGENUMBER]\\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'\m[]
-.           \}
-.           el \{\
-.              PRINT 
\\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\\n[#PAGENUMBER]\\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'
-.           \}
+.          ie \\n[#HDRFTR_CENTER_COLOR]=1 .PRINT \
+\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\m[\\*[$HDRFTR_CENTER_COLOR]]\
+\\n[#PAGENUMBER]\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'\m[]
+.          el .PRINT \
+\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\\n[#PAGENUMBER]\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'
 .       \}
 .       el \{\
 .          ie !'\\*[$HDRFTR_CENTER]'' \{\
-.             ie \\n[#HDRFTR_CENTER_COLOR]=1 \{\
-.                PRINT 
\\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\m[\\*[$HDRFTR_CENTER_COLOR]]\\*[$HDRFTR_CENTER]\\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'\m[]
-.             \}
-.             el \{\
-.                PRINT 
\\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\\*[$HDRFTR_CENTER]\\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'
-.             \}
+.             ie \\n[#HDRFTR_CENTER_COLOR]=1 .PRINT \
+\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\m[\\*[$HDRFTR_CENTER_COLOR]]\
+\\*[$HDRFTR_CENTER]\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'\m[]
+.             el .PRINT \
+\h'\\n[#HDRFTR_CTR_PAD_LEFT]u'\\*[$HDRFTR_CENTER]\h'\\n[#HDRFTR_CTR_PAD_RIGHT]u'
 .          \}
-.          el \{ .PRINT \& \}
+.          el .PRINT \&
 .       \}
-.       if \\n[#HDRFTR_CENTER_CAPS] \{ .CAPS OFF \}
+.       if \\n[#HDRFTR_CENTER_CAPS] .CAPS OFF
 .       fam     \\*[$HDRFTR_RIGHT_FAM]
 .       ft      \\*[$HDRFTR_RIGHT_FT]
 .       ps      \\n[#HDRFTR_PT_SIZE]u\\*[$HDRFTR_RIGHT_SIZE_CHANGE]
@@ -9408,31 +8946,27 @@
 .          nr #RIGHT_CAP_HEIGHT \\n[#CAP_HEIGHT]
 .          di
 .       \}
-.       if o                       \{ .RIGHT \}
-.       if e                       \{ .LEFT  \}
-.       if \\n[#RECTO_VERSO]=0     \{ .RIGHT \}
-.       if \\n[#HDRFTR_RIGHT_CAPS] \{ .CAPS  \}
-.       rt \\nyu
+.       if o .RIGHT
+.       if e .LEFT
+.       if \\n[#RECTO_VERSO]=0 .RIGHT
+.       if \\n[#HDRFTR_RIGHT_CAPS] .CAPS
+.       rt \\n[y]u
 .       ie '\\*[$HDRFTR_RIGHT]'#' \{\
-.          ie \\n[#HDRFTR_RIGHT_COLOR]=1 \{\
+.          ie \\n[#HDRFTR_RIGHT_COLOR]=1 \
 .             PRINT \m[\\*[$HDRFTR_RIGHT_COLOR]]\\n[#PAGENUMBER]\m[]
-.          \}
-.          el \{\
+.          el \
 .             PRINT \\n[#PAGENUMBER]
 .          \}
-.       \}
 .       el \{\
 .          ie !'\\*[$HDRFTR_RIGHT]'' \{\
-.             ie \\n[#HDRFTR_RIGHT_COLOR]=1 \{\
+.             ie \\n[#HDRFTR_RIGHT_COLOR]=1 \
 .                PRINT \m[\\*[$HDRFTR_RIGHT_COLOR]]\\*[$HDRFTR_RIGHT]\m[]
-.             \}
-.             el \{\
+.             el \
 .                PRINT \\*[$HDRFTR_RIGHT]
 .             \}
+.          el .PRINT \&
 .          \}
-.          el \{ .PRINT \& \}
-.       \}
-.       if \\n[#HDRFTR_RIGHT_CAPS] \{ .CAPS OFF \}
+.       if \\n[#HDRFTR_RIGHT_CAPS] .CAPS OFF
 .    \}
 .    if \\n[#HDRFTR_RULE] \{\
 .       HDRFTR_RULE_INTERNAL
@@ -9440,7 +8974,6 @@
 .    br
 .END
 \#
-\#
 \# PRINT USER DEFINED HEADER/FOOTER
 \# --------------------------------
 \# *Arguments:
@@ -9465,12 +8998,12 @@
 .    \}
 .    ie \\n[#RECTO_VERSO] \{\
 .       if o \{\
-.          if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=1 \{ .LEFT   \}
-.          if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=2 \{ .CENTER \}
-.          if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=3 \{ .RIGHT  \}
-.          if \\n[#HDRFTR_RECTO_CAPS]=1 \{ .CAPS \}
+.          if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=1 .LEFT
+.          if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=2 .CENTER
+.          if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=3 .RIGHT
+.          if \\n[#HDRFTR_RECTO_CAPS]=1 .CAPS
 .          PRINT \\*[$USERDEF_HDRFTR_RECTO]
-.          if \\n[#HDRFTR_RECTO_CAPS]=1 \{ .CAPS OFF \}
+.          if \\n[#HDRFTR_RECTO_CAPS]=1 .CAPS OFF
 .          EOL
 .          if \\n[#FOOTERS_ON] \{\
 .             di NULL
@@ -9481,12 +9014,12 @@
 .       \}
 .       if e \{\
 .          ie !'\\*[$USERDEF_HDRFTR_VERSO]'' \{\
-.             if \\n[#USERDEF_HDRFTR_VERSO_QUAD]=1 \{ .LEFT   \}
-.             if \\n[#USERDEF_HDRFTR_VERSO_QUAD]=2 \{ .CENTER \}
-.             if \\n[#USERDEF_HDRFTR_VERSO_QUAD]=3 \{ .RIGHT  \}
-.             if \\n[#HDRFTR_VERSO_CAPS]=1 \{ .CAPS \}
+.             if \\n[#USERDEF_HDRFTR_VERSO_QUAD]=1 .LEFT
+.             if \\n[#USERDEF_HDRFTR_VERSO_QUAD]=2 .CENTER
+.             if \\n[#USERDEF_HDRFTR_VERSO_QUAD]=3 .RIGHT
+.             if \\n[#HDRFTR_VERSO_CAPS]=1 .CAPS
 .             PRINT \\*[$USERDEF_HDRFTR_VERSO]
-.             if \\n[#HDRFTR_VERSO_CAPS]=1 \{ .CAPS OFF \}
+.             if \\n[#HDRFTR_VERSO_CAPS]=1 .CAPS OFF
 .             EOL
 .             if \\n[#FOOTERS_ON] \{\
 .                di NULL
@@ -9496,12 +9029,12 @@
 .             \}
 .          \}
 .          el \{\
-.             if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=1 \{ .LEFT   \}
-.             if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=2 \{ .CENTER \}
-.             if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=3 \{ .RIGHT  \}
-.             if \\n[#HDRFTR_RECTO_CAPS]=1 \{ .CAPS \}
+.             if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=1 .LEFT
+.             if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=2 .CENTER
+.             if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=3 .RIGHT
+.             if \\n[#HDRFTR_RECTO_CAPS]=1 .CAPS
 .             PRINT \\*[$USERDEF_HDRFTR_RECTO]
-.             if \\n[#HDRFTR_RECTO_CAPS]=1 \{ .CAPS OFF \}
+.             if \\n[#HDRFTR_RECTO_CAPS]=1 .CAPS OFF
 .             EOL
 .             if \\n[#FOOTERS_ON] \{\
 .                di NULL
@@ -9513,12 +9046,12 @@
 .       \}
 .    \}
 .    el \{\
-.       if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=1 \{ .LEFT   \}
-.       if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=2 \{ .CENTER \}
-.       if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=3 \{ .RIGHT  \}
-.       if \\n[#HDRFTR_RECTO_CAPS]=1 \{ .CAPS \}
+.       if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=1 .LEFT
+.       if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=2 .CENTER
+.       if \\n[#USERDEF_HDRFTR_RECTO_QUAD]=3 .RIGHT
+.       if \\n[#HDRFTR_RECTO_CAPS]=1 .CAPS
 .       PRINT \\*[$USERDEF_HDRFTR_RECTO]
-.       if \\n[#HDRFTR_RECTO_CAPS]=1 \{ .CAPS OFF \}
+.       if \\n[#HDRFTR_RECTO_CAPS]=1 .CAPS OFF
 .       EOL
 .       if \\n[#FOOTERS_ON] \{\
 .          di NULL
@@ -9537,7 +9070,6 @@
 .    \}
 .END
 \#
-\#
 \# +++HEADERS+++
 \#
 \# HEADERS (off or on)
@@ -9550,11 +9082,10 @@
 \#   Default is on.
 \#
 .MAC HEADERS END
-.    ie '\\$1'' \{ .nr #HEADERS_ON 1 \}
-.    el \{ .nr #HEADERS_ON 0 \}
+.    ie '\\$1'' .nr #HEADERS_ON 1
+.    el .nr #HEADERS_ON 0
 .END
 \#
-\#
 \# HEADER MARGIN
 \# -------------
 \# *Argument:
@@ -9570,7 +9101,6 @@
 .    nr #HEADER_MARGIN (\\$1)
 .END
 \#
-\#
 \# HEADER GAP
 \# ----------
 \# *Argument:
@@ -9585,7 +9115,6 @@
 .    nr #HEADER_GAP (\\$1)
 .END
 \#
-\#
 \# HEADER
 \# ------
 \# *Arguments:
@@ -9593,39 +9122,37 @@
 \# *Function:
 \#   Prints header appropriate to DOC_TYPE, PRINTSTYLE, and COPYSTYLE.
 \# *Notes:
-\#   In order to convert the title string to caps in the header (in the
-\#   event that the user enters .TITLE in caps/lc), I've used
-\#   quad left, quad centre, and quad right to arrange the three bits
-\#   of the header, rather than .tl.  This allows the use of the CAPS macro.
-\#   The downside is that I have to add \\v'-(\\n[#LEAD]u*<n>) in order
-\#   for -Tlatin1 output to align the header/footer strings on the baseline.
-\#   The console output still isn't brilliant, but at least it's
-\#   comprehensible.
+\#   In order to convert the title string to caps in the header
+\#   (in the event that the user enters .TITLE in caps/lc), I've
+\#   used quad left, quad centre, and quad right to arrange the
+\#   three bits of the header, rather than .tl.  This allows the
+\#   use of the CAPS macro.  The downside is that I have to add
+\#   \\v'-(\\n[#LEAD]u*<n>) in order for -Tlatin1 output to align
+\#   the header/footer strings on the baseline.  The console output
+\#   still isn't brilliant, but at least it's comprehensible.
 \#
 .MAC HEADER END
 .    MNtop
 .    rr #FROM_FOOTER
 .    nr #FROM_HEADER 1
 .    nr #LAST_FN_COUNT_FOR_COLS \\n[#FN_COUNT_FOR_COLS]
-.    if \\n[#FN_DEPTH] \{ .PROCESS_FN_LEFTOVER \}
+.    if \\n[#FN_DEPTH] .PROCESS_FN_LEFTOVER
 .    rr #RULED
-.    if \\n[#RESET_FN_NUMBER] \{ .nr #FN_NUMBER 0 1 \}
+.    if \\n[#RESET_FN_NUMBER] .nr #FN_NUMBER 0 1
 .    po \\n[#DOC_L_MARGIN]u
 .    if \\n[#RECTO_VERSO] \{\
-.       if !\\n[#TOC_RV_SWITCH] \{\
 .          nr #DOC_LR_MARGIN_TMP \\n[#DOC_L_MARGIN]
 .          DOC_LEFT_MARGIN  \\n[#DOC_R_MARGIN]u
 .          DOC_RIGHT_MARGIN \\n[#DOC_LR_MARGIN_TMP]u
 .          SWITCH_HDRFTR_CENTER_PAD
 .       \}
-.       rr #TOC_RV_SWITCH
 .    \}
 .    ev HEADER
-.    if \\n[#PAGE_NUM_V_POS]=1 \{ .vs 0 \}
+.    if \\n[#PAGE_NUM_V_POS]=1 .vs 0
 .    sp |\\n[#HEADER_MARGIN]u-1v
 .    mk y
 .    ll \\n[#DOC_L_LENGTH]u
-.    ta \\n(.lu
+.    ta \\n[.l]u
 .    if \\n[#PRINT_STYLE]=1 \{\
 .       fam \\*[$TYPEWRITER_FAM]
 .       ft  R
@@ -9651,8 +9178,8 @@
 .          \}
 .       \}
 .    \}
-.    if !n \{ .nop \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap' \}
-.    RLD 1v
+.    if !n .nop \X'ps: exec 0 setlinejoin'\X'ps: exec 0 setlinecap'
+.    sp -1v
 .    ie \\n[#HEADERS_ON] \{\
 .       PRINT_HDRFTR
 .       sp |\\n[#T_MARGIN]u-\\n[#DOC_LEAD]u
@@ -9663,9 +9190,9 @@
 .             PRINT_PAGE_NUMBER
 .             sp |\\n[#T_MARGIN]u-\\n[#DOC_LEAD]u
 .          \}
-.          el \{ .sp |\\n[#T_MARGIN]u-\\n[#DOC_LEAD]u \}
+.          el .sp |\\n[#T_MARGIN]u-\\n[#DOC_LEAD]u
 .       \}
-.       el \{ .sp |\\n[#T_MARGIN]u-\\n[#DOC_LEAD]u \}
+.       el .sp |\\n[#T_MARGIN]u-\\n[#DOC_LEAD]u
 .    \}
 .    if \\n[#PRINT_STYLE]=1 \{\
 .       if \\n[#ENDNOTES]=1 \{\
@@ -9675,39 +9202,33 @@
 .          \}
 .       \}
 .    \}
-.    nr #PAGE_TOP \\n(nl
+.    nr #PAGE_TOP \\n[nl]
 .    ev
 .    po \\n[#L_MARGIN]u
-.    if \\n[#RECTO_VERSO] \{\
-.       nr #L_MARGIN +\\n[#L_MARGIN_DIFF]
-.    \}
+.    if \\n[#RECTO_VERSO] .nr #L_MARGIN +\\n[#L_MARGIN_DIFF]
 .    if \\n[#CAPS_WAS_ON] \{\
 .       CAPS
 .       rr #CAPS_WAS_ON
 .    \}
-.    if \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \}
+.    if \\n[#TAB_ACTIVE] .TAB \\n[#CURRENT_TAB]
 .    if \\n[#QUOTE] \{\
-.       ie \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \}
-.       el \{\
-.          ie r#Q_OFFSET_VALUE \{\
-.             nr #Q_OFFSET 
\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
-.          \}
+.       ie \\n[#TAB_ACTIVE] .TAB \\n[#CURRENT_TAB]
 .          el \{\
-.             nr #Q_OFFSET \\n[#L_MARGIN]+\\*[$Q_OFFSET_VALUE]
-.          \}
+.          ie \\n[#Q_OFFSET_VALUE] .nr #Q_OFFSET \
+\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
+.          el .nr #Q_OFFSET \\n[#L_MARGIN]+\\*[$Q_OFFSET_VALUE]
 .          po \\n[#Q_OFFSET]u
 .       \}
-.       if \\n[#PRINT_STYLE]=2 \{ .ALD \\n[#Q_LEAD_DIFF]u \}
+\#.       if \\n[#PRINT_STYLE]=2 .ALD \\n[#Q_LEAD_DIFF]u
 .    \}
 .    if \\n[#EPIGRAPH] \{\
-.       ie \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \}
-.       el \{\
-.          ie r#EPI_OFFSET_VALUE \{\
-.             nr #EPI_OFFSET 
\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
-.          \}
+.       ie \\n[#TAB_ACTIVE] .TAB \\n[#CURRENT_TAB]
 .          el \{\
+.          ie r#EPI_OFFSET_VALUE \
+.             nr #EPI_OFFSET \
+\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
+.          el \
 .             nr #EPI_OFFSET \\n[#L_MARGIN]+\\*[$EPI_OFFSET_VALUE]
-.          \}
 .          po \\n[#EPI_OFFSET]u
 .       \}
 .    \}
@@ -9717,38 +9238,37 @@
 .          rr #EPI_ACTIVE
 .       \}
 .       el \{\
-.          ie \\n[#EPI_FITS] \{ .ns \}
-.          el \{ .ALD \\n[#DOC_LEAD]u-\\n[#EPI_LEAD]u \}
+.          ie \\n[#EPI_FITS] .ns
+.          el .ALD \\n[#DOC_LEAD]u-\\n[#EPI_LEAD]u
 .       \}
 .    \}
-.    el \{ .ns \}
+.    el .ns
 .    ns
 .    if \\n[#COLUMNS] \{\
 .       nr #FN_COUNT_FOR_COLS 0 1
 .       nr #L_MARGIN \\n[#DOC_L_MARGIN]
-.       if \\n[#RECTO_VERSO] \{ .COLUMNS \\n[#NUM_COLS] \\n[#GUTTER]u \}
+.       if \\n[#RECTO_VERSO] .COLUMNS \\n[#NUM_COLS] \\n[#GUTTER]u
 .       nr #COL_NUM 0 1
 .       mk dc
 .       po \\n[#COL_\\n+[#COL_NUM]_L_MARGIN]u
-.       nr #L_MARGIN \\n(.o
-.       if \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \}
+.       nr #L_MARGIN \\n[.o]
+.       if \\n[#TAB_ACTIVE] .TAB \\n[#CURRENT_TAB]
 .       ll \\n[#COL_L_LENGTH]u
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .       if \\n[#QUOTE] \{\
-.          ie r#Q_OFFSET_VALUE \{\
+.          ie \\n[#Q_OFFSET_VALUE] \
 .             po +(\\n[#PP_INDENT]u*\\n[#Q_OFFSET_VALUE]u)
-.          \}
-.          el \{\
+.          el \
 .             po +\\*[$Q_OFFSET_VALUE]
 .          \}
-.       \}
 .       if \\n[#EPIGRAPH] \{\
 .          if \\n[#EPI_ACTIVE] \{\
-.             ie \\n[#EPI_FITS] \{ . \}
-.             el \{ .nr dc -\\n[#EPI_LEAD_DIFF] \}
+.             ie \\n[#EPI_FITS] .
+.             el .nr dc -\\n[#EPI_LEAD_DIFF]
 .          \}
 .          ie r#EPI_OFFSET_VALUE \{\
-.             po 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]u+(\\n[#PP_INDENT]u*\\n[#EPI_OFFSET_VALUE]u)
+.             po \
+\\n[#COL_\\n[#COL_NUM]_L_MARGIN]u+(\\n[#PP_INDENT]u*\\n[#EPI_OFFSET_VALUE]u)
 .          \}
 .          el \{\
 .             po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u+\\*[$EPI_OFFSET_VALUE]
@@ -9759,16 +9279,16 @@
 .       rr #RESET_FN_COUNTERS
 .       PROCESS_FN_IN_DIVER
 .       nr #FN_COUNT \\n[#SAVED_FN_COUNT] 1
-.       if \\n[#COLUMNS]=1 \{ .nr #FN_COUNT_FOR_COLS 
\\n[#SAVED_FN_COUNT_FOR_COLS] 1 \}
-.       ie \\n[#RESET_FN_NUMBER]=1 \{ .nr #FN_NUMBER \\n[#SAVED_FN_NUMBER] 1 \}
-.       el \{ .nr #FN_NUMBER \\n[#FN_NUMBER] 1 \}
+.       if \\n[#COLUMNS]=1 .nr #FN_COUNT_FOR_COLS 
\\n[#SAVED_FN_COUNT_FOR_COLS] 1
+.       ie \\n[#RESET_FN_NUMBER]=1 .nr #FN_NUMBER \\n[#SAVED_FN_NUMBER] 1
+.       el .nr #FN_NUMBER \\n[#FN_NUMBER] 1
 .       rm FN_IN_DIVER
-.       if dRUNON_FN_IN_DIVER \{ .rm RUNON_FN_IN_DIVER \}
+.       if dRUNON_FN_IN_DIVER .rm RUNON_FN_IN_DIVER
 .    \}
 .    rr #FROM_HEADER
 .    rr #DEFER_SPACE_ADDED
 .    if !\\n[#FN_DEPTH] \{\
-.       if r#DIVERTED \{ .rr #DIVERTED \}
+.       if r #DIVERTED .rr #DIVERTED
 .    \}
 .    if \\n[#MN_OVERFLOW_LEFT]=1 \{\
 .       MN LEFT
@@ -9788,29 +9308,62 @@
 .    rm MN_OVERFLOW_RIGHT
 .    rr #MN_OVERFLOW_RIGHT
 .    rr #no-repeat-MN-right
-.    if \\n[#PRE_COLLATE]=1 \{ .rr #PRE_COLLATE \}
+.    if \\n[#PRE_COLLATE]=1 .rr #PRE_COLLATE
 .    if \\n[#UNDERLINE_WAS_ON]=1 \{\
 .       vs 0
-.       ie !n \{\
+.       ie !n \
 .          nop \R'#UNDERLINE_ON 1'\X'ps: exec \\n[_w] \\n[_d] decorline'
-.       \}
-.       el \{\
-.          ul 1000
-.       \}
-.          rr #UNDERLINE_WAS_ON
+.       el .ul 1000
 .       br
+.       ns
+.       rr #UNDERLINE_WAS_ON
 .    \}
 .   if \\n[#RESTORE_PAGINATION] \{\
 .      PAGINATE
 .      rr #RESTORE_PAGINATION
 .   \}
-.END
-\#
-\# ====================================================================
-\#
-\# +++FOOTERS+++
-\#
-\# FOOTERS (off or on)
+.    ch address@hidden
+.    wh \\n[nl]u+1u address@hidden
+.    if d PDF*IMAGE \{\
+.       rs
+.       nf
+.       PDF*IMAGE
+.       sp \\n[pdf-img:depth]u
+.       PDF_IMAGE_CLEAN
+.    \}
+.    if \\n[defer] \{\
+.       rs
+.       sp |\\n[#T_MARGIN]u-\\n[.v]u
+.       ev protect
+.       nf
+.       nr defer-count   \\n[defer]
+.       nr loop-count     0 1
+.       while \\n+[loop-count]<=\\n[defer-count] \{\
+.          FLOAT*DIV:\\n[loop-count]
+.          if \\n[D-float:\\n[loop-count]] \{\
+.             sp \
+-\\n[float-depth:\\n[loop-count]]u+\\n[D-float:\\n[loop-count]]u+\\n[#DOC_LEAD]u
+.             rr D-float:\\n[loop-count]
+.          \}
+.          rm FLOAT*DIV:\\n[loop-count]
+.          rr float-depth:\\n[loop-count]
+.       \}
+.       ev
+.       SHIM
+.       rr defer
+.       rr loop-count
+.       rr defer-count
+.       rm float-adj
+.       rm float-adj:top
+.       rm float-adj:bottom
+.    \}
+.END
+\#
+\# ====================================================================
+\#
+\# +++FOOTERS+++
+\#
+\# FOOTERS (off or on)
 \# -------------------
 \# *Arguments:
 \#   <none> | <anything>
@@ -9827,10 +9380,9 @@
 .       nr #FOOTERS_ON 1
 .       PAGENUM_POS TOP CENTER
 .    \}
-.    el \{ .nr #FOOTERS_ON 0 \}
+.    el .nr #FOOTERS_ON 0
 .END
 \#
-\#
 \# FOOTER MARGIN
 \# -------------
 \# *Argument:
@@ -9843,11 +9395,10 @@
 \#   Unit of measure required.  Default is 3P.
 \#
 .MAC FOOTER_MARGIN END
-.    ie \\n%>0 \{ .nr #FOOTER_MARGIN (\\$1) \}
-.    el \{ . \}
+.    ie \\n%>0 .nr #FOOTER_MARGIN (\\$1)
+.    el .
 .END
 \#
-\#
 \# FOOTER GAP
 \# ----------
 \# *Argument:
@@ -9860,11 +9411,10 @@
 \#   baseline.
 \#
 .MAC FOOTER_GAP END
-.    ie \\n%>0 \{ .nr #FOOTER_GAP (\\$1) \}
-.    el \{ . \}
+.    ie \\n%>0 .nr #FOOTER_GAP (\\$1)
+.    el .
 .END
 \#
-\#
 \# FOOTER
 \# ------
 \# *Arguments:
@@ -9877,10 +9427,13 @@
 \#   FINAL respects PAGENUMBER.
 \#
 .MAC FOOTER END
-.    nr #SAVED_LEAD \\n(.v
+.    rr #LB_4_HD
+.    rr #QUOTE_4_HD
+.    nr #SAVED_LEAD \\n[.v]
 .    ev PAGE_TRANSITION
-.    ie !n \{ .nop \X'ps: exec decornone' \}
-.    el \{ .ul 0 \}
+.    pdfmarksuspend
+.    ie !n .nop \X'ps: exec decornone'
+.    el .ul 0
 .    br
 .    if \\n[#UNDERLINE_ON]=1 \{\
 .       nr #UNDERLINE_WAS_ON 1
@@ -9890,7 +9443,7 @@
 .          MNbottom-left
 .          nr #no-repeat-MN-left 1
 .       \}
-.       if '\\n(.z'MN_OVERFLOW_LEFT' \{\
+.       if '\\n[.z]'MN_OVERFLOW_LEFT' \{\
 .          di
 .          nr #MN_OVERFLOW_LEFT 1
 .          rr #OVERFLOW_LEFT
@@ -9898,11 +9451,9 @@
 .    \}
 .    if \\n[MN-right]>0 \{\
 .       if (\\n[MN-right] > 0) \{\
-.          if !\\n[#no-repeat-MN-right]=1 \{\
-.             MNbottom-right
+.          if !\\n[#no-repeat-MN-right]=1 .MNbottom-right
 .          \}
-.       \}
-.       if '\\n(.z'MN_OVERFLOW_RIGHT' \{\
+.       if '\\n[.z]'MN_OVERFLOW_RIGHT' \{\
 .          di
 .          nr #MN_OVERFLOW_RIGHT 1
 .          rr #OVERFLOW_RIGHT
@@ -9913,50 +9464,52 @@
 .    if !\\n[#FN_DEFER] \{\
 .       nr #DIVER_DEPTH 0
 .       if \\n[#FN_DEPTH] \{\
-.          if \\n[#DIVERTED]=3 \{ .nr #FN_DEPTH +\\n[#VFP_DIFF] \}
+.          if \\n[#DIVERTED]=3 .nr #FN_DEPTH +\\n[#VFP_DIFF]
 .          vpt 0
-.          sp 
|\\n[#PAGE_LENGTH]u-(\\n[#B_MARGIN]u+\\n[#FN_DEPTH]u-\\n[#DOC_LEAD]u)
+.          sp \
+|\\n[#PAGE_LENGTH]u-(\\n[#B_MARGIN]u+\\n[#FN_DEPTH]u-\\n[#DOC_LEAD]u)
 .          vpt 1
 .          po \\n[#DOC_L_MARGIN]u
 .          if \\n[#COLUMNS] \{\
 .             po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
-.             nr #L_MARGIN \\n(.o
+.             nr #L_MARGIN \\n[.o]
 .             nr #FROM_FOOTER 1
 .          \}
 .          nf
 .          FOOTNOTES
 .          rm FOOTNOTES
-.          if d RUNON_FOOTNOTES \{ .rm RUNON_FOOTNOTES \}
-.          if \\n[#PRINT_STYLE]=1 \{ .vs \\n[#SAVED_LEAD]u \}
-.          if \\n[#PRINT_STYLE]=2 \{ .LS \\n[#SAVED_LEAD]u \}
-.          if '\\n(.z'FN_OVERFLOW' \{\
+.          if d RUNON_FOOTNOTES    .rm RUNON_FOOTNOTES
+.          if \\n[#PRINT_STYLE]=1 .vs \\n[#SAVED_LEAD]u
+.          if \\n[#PRINT_STYLE]=2 .LS \\n[#SAVED_LEAD]u
+.          if '\\n[.z]'FN_OVERFLOW' \{\
 .              di
 .              nr #FN_OVERFLOW_DEPTH \\n[#DIVER_DEPTH]
 .          \}
 .          nr #FN_COUNT_AT_FOOTER \\n[#FN_COUNT]
 .          nr #FN_COUNT 0
 .          if \\n[#COL_NEXT] \{\
-.             ie !\\n[#COL_NUM]=\\n[#NUM_COLS] \{ .nr #COL_NUM \\n-[#COL_NUM] 
\}
-.             el \{ .nr #COL_NUM \\n[#NUM_COLS] 1 \}
+.             ie !\\n[#COL_NUM]=\\n[#NUM_COLS] .nr #COL_NUM \\n-[#COL_NUM]
+.             el .nr #COL_NUM \\n[#NUM_COLS] 1
 .          \}
 .       \}
 .       rr #DIVERTED
 .    \}
+.    nr @TOP 1
 .    ie \\n[#COLUMNS]=1 \{\
-.       ie \\n[#COL_NUM]=\\n[#NUM_COLS] \{ .DO_FOOTER \}
+.       ie \\n[#COL_NUM]=\\n[#NUM_COLS] .DO_FOOTER
 .       el \{\
-.          ie \\n[#ENDNOTES] \{ .sp |\\n(ecu-\\n[#EN_LEAD]u \}
-.          el \{ .sp |\\n(dcu \}
+.          ie \\n[#ENDNOTES] .sp |\\n[ec]u-\\n[#EN_LEAD]u
+.          el .sp |\\n[dc]u
 .          po \\n[#COL_\\n+[#COL_NUM]_L_MARGIN]u
-.          nr #L_MARGIN \\n(.o
-.          if \\n[#FN_DEPTH] \{ .PROCESS_FN_LEFTOVER \}
+.          nr #L_MARGIN \\n[.o]
+.          if \\n[#FN_DEPTH] .PROCESS_FN_LEFTOVER
 .          LS \\n[#SAVED_LEAD]u
 .          if \\n[#PREV_FN_DEFERRED] \{\
 .             nr #PREV_FN_DEFERRED 2
 .          \}
 .          rr #RULED
-.          if !\\n[#EPIGRAPH] \{ .rr #COL_NEXT \}
-.          if !\\n[#QUOTE]    \{ .rr #COL_NEXT \}
+.          if !\\n[#EPIGRAPH] .rr #COL_NEXT
+.          if !\\n[#QUOTE] .rr #COL_NEXT
 .          if \\n[#RESET_FN_COUNTERS]=1 \{\
 .             rr #RESET_FN_COUNTERS
 .             PROCESS_FN_IN_DIVER
@@ -9964,46 +9517,39 @@
 .             nr #FN_COUNT \\n[#FN_COUNT] 1
 .             nr #FN_COUNT_FOR_COLS \\n[#FN_COUNT_FOR_COLS] 1
 .             rm FN_IN_DIVER
-.             if dRUNON_FN_IN_DIVER \{ .rm RUNON_FN_IN_DIVER \}
+.             if dRUNON_FN_IN_DIVER .rm RUNON_FN_IN_DIVER
 .          \}
 .          rr #DEFER_SPACE_ADDED
-.          if \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \}
+.          if \\n[#TAB_ACTIVE] .TAB \\n[#CURRENT_TAB]
 .          if \\n[#QUOTE] \{\
-.             ie \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \}
-.             el \{\
-.                ie r#Q_OFFSET_VALUE \{\
-.                   nr #Q_OFFSET 
\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
-.                \}
+.             ie \\n[#TAB_ACTIVE] .TAB \\n[#CURRENT_TAB]
 .                el \{\
+.                ie \\n[#Q_OFFSET_VALUE] \
+.                   nr #Q_OFFSET \
+\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
+.                el \
 .                   nr #Q_OFFSET \\n[#L_MARGIN]+\\*[$Q_OFFSET_VALUE]
-.                \}
 .                if \\n[#COLUMNS] \{\
-.                   ie r#Q_OFFSET_VALUE \{\
-.                      nr #Q_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
-.                   \}
-.                   el \{\
-.                      nr #Q_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$Q_OFFSET_VALUE]
-.                   \}
+.                   ie \\n[#Q_OFFSET_VALUE] .nr #Q_OFFSET \
+\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
+.                   el .nr #Q_OFFSET \
+\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$Q_OFFSET_VALUE]
 .                \}
 .                po \\n[#Q_OFFSET]u
 .             \}
 .          \}
 .          if \\n[#EPIGRAPH] \{\
-.             ie \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \}
-.             el \{\
-.                ie r#EPI_OFFSET_VALUE \{\
-.                   nr #EPI_OFFSET 
\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
-.                \}
+.             ie \\n[#TAB_ACTIVE] .TAB \\n[#CURRENT_TAB]
 .                el \{\
-.                   nr #EPI_OFFSET \\n[#L_MARGIN]+\\*[$EPI_OFFSET_VALUE]
-.                \}
+.                ie r#EPI_OFFSET_VALUE .nr #EPI_OFFSET \
+\\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
+.                el .nr #EPI_OFFSET \
+\\n[#L_MARGIN]+\\*[$EPI_OFFSET_VALUE]
 .                if \\n[#COLUMNS] \{\
-.                   ie r#EPI_OFFSET_VALUE \{\
-.                      nr #EPI_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
-.                   \}
-.                   el \{\
-.                      nr #EPI_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$EPI_OFFSET_VALUE]
-.                   \}
+.                   ie r#EPI_OFFSET_VALUE .nr #EPI_OFFSET \
+\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#EPI_OFFSET_VALUE])
+.                   el .nr #EPI_OFFSET \
+\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$EPI_OFFSET_VALUE]
 .                \}
 .                po \\n[#EPI_OFFSET]u
 .             \}
@@ -10014,22 +9560,22 @@
 .                rr #EPI_ACTIVE
 .             \}
 .             el \{\
-.                sp |\\n(dcu+(\\n[#DOC_LEAD]u-\\n[#EPI_LEAD]u)
+.                sp |\\n[dc]u+(\\n[#DOC_LEAD]u-\\n[#EPI_LEAD]u)
 .                rr #EPI_ACTIVE
 .             \}
 .          \}
-.          el \{ .ns \}
+.          el .ns
 .          ev
 .       \}
 .       ns
 .       rr #DIVERTED
+.       ch address@hidden
+.       wh \\n[nl]u+1u address@hidden
 .    \}
-.    el \{\
-.       DO_FOOTER
-.    \}
+.    el .DO_FOOTER
+.    pdfmarkrestart
 .END
 \#
-\#
 \# PROCESS FOOTER
 \# --------------
 \# *Arguments:
@@ -10057,25 +9603,20 @@
 .\" Have to change position of FN_OVERFLOW_TRAP or it screws up the
 .\" placement of page numbers (or footers).  It's reset to its original
 .\" position at the end of the macro.
-.    if r#SAVED_FOOTER_POS \{ .ch FOOTER \\n[#SAVED_FOOTER_POS]u \}
+.    if r #SAVED_FOOTER_POS .ch FOOTER \\n[#SAVED_FOOTER_POS]u
 .    rr #SAVED_FOOTER_POS
-.    ie (\\n[#FOOTER_MARGIN]+\\n[.v]>\\n[#B_MARGIN] \{\
-.       nr #SKIP_FOOTER 1
-.    \}
+.    ie (\\n[#FOOTER_MARGIN]+\\n[.v]>\\n[#B_MARGIN]) .nr #SKIP_FOOTER 1
 .    el \{\
 .       ev FOOTER
 .       vpt 0
-.       vs  12
-.       sp |\\n[#PAGE_LENGTH]u-\\n[#FOOTER_MARGIN]u-1v
+.       sp |\\n[#PAGE_LENGTH]u-\\n[#FOOTER_MARGIN]u-\\n[#UNADJUSTED_DOC_LEAD]u
 .       mk y
 .    \}
 .    UNDERLINE OFF
 .    po \\n[#DOC_L_MARGIN]u
 .    ll \\n[#DOC_L_LENGTH]u
-.    ta \\n(.lu
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       TYPEWRITER
-.    \}
+.    ta \\n[.l]u
+.    if \\n[#PRINT_STYLE]=1 .TYPEWRITER
 .    if \\n[#PRINT_STYLE]=2 \{\
 .       fam  \\*[$HDRFTR_FAM]
 .       ft      R
@@ -10087,12 +9628,12 @@
 .       CAPS OFF
 .    \}
 .    ie \\n[#FOOTERS_ON] \{\
-.       if !\\n[#SKIP_FOOTER]=1 \{ .PRINT_HDRFTR \}
+.       if !\\n[#SKIP_FOOTER]=1 .PRINT_HDRFTR
 .    \}
 .    el \{\
 .       if \\n[#PAGINATE] \{\
 .          if \\n[#PAGE_NUM_V_POS]=2 \{\
-.             if !\\n[#SKIP_FOOTER]=1 \{ .PRINT_PAGE_NUMBER \}
+.             if !\\n[#SKIP_FOOTER]=1 .PRINT_PAGE_NUMBER
 .          \}
 .       \}
 .    \}
@@ -10102,7 +9643,6 @@
 .       rr #CAPS_WAS_ON
 .    \}
 .    ev
-.    rr #SAVED_LEAD
 .    vpt 1
 .END
 \#
@@ -10155,11 +9695,11 @@
 .   if \\\\n[#HDRFTR_BOTH]=1 \{\
 .      FOOTER_RECTO \\*[$FTR_RECTO_QUAD] "\\*[$FTR_RECTO_STRING]"
 .      FOOTER_VERSO \\*[$FTR_VERSO_QUAD] "\\*[$FTR_VERSO_STRING]"
-.      if \\\\n[#HEADER_RULE]=1 \{ .HEADER_RULE \}
-.      ie \\\\n[#FOOTER_RULE]=1 \{ .FOOTER_RULE \}
-.      el \{ .FOOTER_RULE OFF \}
-.      if r#PAGINATE .rr #PAGINATE
-.      if r#PAGE_NUM_V_POS .rr #PAGE_NUM_V_POS
+.      if \\\\n[#HEADER_RULE]=1 .HEADER_RULE
+.      ie \\\\n[#FOOTER_RULE]=1 .FOOTER_RULE
+.      el .FOOTER_RULE OFF
+.      if r #PAGINATE .rr #PAGINATE
+.      if r #PAGE_NUM_V_POS .rr #PAGE_NUM_V_POS
 .\}
 .DONE
 .am PRINT_USERDEF_HDRFTR DONE
@@ -10170,8 +9710,8 @@
 .            HEADER_VERSO \\*[$HDR_VERSO_QUAD] "\\*[$HDR_VERSO_STRING]"
 .            rr #FOOTERS_ON
 .            nr #HEADERS_ON 1
-.            ie \\\\n[#HEADER_RULE]=1 \{ .HEADER_RULE \}
-.            el \{ .HEADER_RULE OFF \}
+.            ie \\\\n[#HEADER_RULE]=1 .HEADER_RULE
+.            el .HEADER_RULE OFF
 .         \}
 .      \}
 .      if \\n[#HEADERS_ON]=1 \{\
@@ -10182,13 +9722,13 @@
 .DONE
 .am HEADER DONE
 .   if \\\\n[#HDRFTR_BOTH]=1 \{\
-.      if r#START_FOR_FOOTERS .rr #START_FOR_FOOTERS
+.      if r #START_FOR_FOOTERS .rr #START_FOR_FOOTERS
 .      rr #HEADERS_ON
 .      nr #FOOTERS_ON 1
 .      FOOTER_RECTO \\*[$FTR_RECTO_QUAD] "\\*[$FTR_RECTO_STRING]"
 .      FOOTER_VERSO \\*[$FTR_VERSO_QUAD] "\\*[$FTR_VERSO_STRING]"
-.      ie \\\\n[#FOOTER_RULE]=1 \{ .FOOTER_RULE \}
-.      el \{ .FOOTER_RULE OFF \}
+.      ie \\\\n[#FOOTER_RULE]=1 .FOOTER_RULE
+.      el .FOOTER_RULE OFF
 .   \}
 .DONE
 .    \}
@@ -10213,1216 +9753,776 @@
 \#
 \# +++HEADS+++
 \#
-\# ---Head numbers---
+.char \[hd-num-spacer]     \0
+.char \[parahead-spacer]   \~\~
+.char \[toc-hd-num-spacer] \h'\w'\[en]'u'
+.ds toc-word-space \ \" ie an unbreakable space
 \#
-\# NUMBER HEADS
-\# ------------
+\# HEADING
+\# -------
 \# *Arguments:
-\#   <none> | <anything>
+\#   <heading level> [PARAHEAD] [NAMED <pdf-id>] <heading text>
 \# *Function:
-\#   Toggles register #NUMBER_HEAD; sets incrementing register #HEAD_NUM.
-\# *Notes:
-\#   Default is OFF.
-\#
-.MAC NUMBER_HEADS END
-.    ie '\\$1'' \{\
-.       nr #NUMBER_HEAD 1
-.       if !\\n[#HEAD_NUM] \{ .nr #HEAD_NUM 0 1 \}
+\#   Assigns a heading level to the heading text and prints heading
+\#   in the style set up for that level.  If PARAHEAD given, the
+\#   heading is attached to the body of the paragraph.  If NAMED
+\#   given, creates a target for pdf links.  Collects the heading
+\#   for the TOC and sets TOC indenting appropriate for the level.
+\# *Notes:
+\#   If PARAHEAD given, HEADING must come after PP.
+\#
+.MAC HEADING END
+.    if !\B'\\$1' \{\
+.       tm1 "[mom]: The first argument to \\$0 must be a numeric heading level.
+.       ab Aborting \\n[.F] at \\$0, line \\n[.c].
+.    \}
+.    if r #QUOTE     .rr #QUOTE
+.    if r #END_QUOTE .rr #END_QUOTE
+.    if r #EPIGRAPH  .rr #EPIGRAPH
+.    if \\$1<\\n[#LEVEL] \
+.       nr #ACTIVE_LEVELS \\n[#LEVEL] \" loop count for resetting numbering 
registers
+.    nr #LAST_LEVEL \\n[#LEVEL]       \" used during TOC collection, if 
SPACE_TOC_ITEMS
+.    nr #LEVEL \\$1                   \" reset #LEVEL to arg
+.    shift
+.    nr #ARG_NUM 0 1
+.    while \\n+[#ARG_NUM]<=2 \{\
+.      if '\\$1'NAMED' \{\
+.         ds PDF_NM "\\$1 \\$2
+.         shift 2 \" \\$1 is now heading text
 .    \}
-.    el \{ .rr #NUMBER_HEAD \}
-.END
-\#
-\#
-\# RESET HEAD NUMBER
-\# -----------------
-\# *Arguments:
-\#   <none> | <desired head number>
-\# *Function:
-\#   Resets incrementing register #HEAD_NUM to 1 or, if there's
-\#   an argument, to user supplied number.
-\# *Notes:
-\#   Also resets subhead and parahead numbers.  If this is not
-\#   desired, subhead and parahead numbers may be reset individually.
-\#
-.MAC RESET_HEAD_NUMBER END
-.    ie '\\$1'' \{\
-.       nr #HEAD_NUM 0 1
-.       nr #SH_NUM   0 1
-.       nr #SSH_NUM  0 1
-.       nr #PH_NUM   0 1
+.      if '\\$1'PARAHEAD' \{\
+.         nr #PARAHEAD 1
+.         shift \" \\$1 is now NAMED, if we have it; otherwise heading text
+.      \}
+.    \}
+.\" Spacing
+.    if \\n[#Q_LEAD_DIFF_CHECK] .sp -1v
+.    ie \\n[#PARAHEAD] 'br
+.    el .br
+.    ie !\\n[#PARAHEAD] \{\
+.       if address@hidden \{\
+.          nr #HEAD 1
+.          ie \\n[#HEAD_\\n[#LEVEL]_SPACE_AFTER] .ne \\n[#NUM_ARGS]+2
+.          el .ne \\n[#NUM_ARGS]+1
+.          vpt 0
+.          ie !\\n[#START] \{\
+.             if !\\n[#SPACE_ADDED] .if !\\n[#LINEBREAK] .sp
 .    \}
 .    el \{\
-.       nr #HEAD_NUM \\$1-1 1
-.       nr #SH_NUM   0 1
-.       nr #SSH_NUM  0 1
-.       nr #PH_NUM   0 1
+.             ie !\\n[#PP] \{\
+.                rr #START
 .    \}
-.END
-\#
-\#
-\# NUMBER SUBHEADS
-\# ---------------
-\# *Arguments:
-\#   <none> | <anything>
-\# *Function:
-\#   Toggles register #NUMBER_SH; sets incrementing register #SH_NUM.
-\# *Notes:
-\#   Default is OFF.
-\#
-.MAC NUMBER_SUBHEADS END
-.    ie '\\$1'' \{\
-.       nr #NUMBER_SH 1
-.       if !\\n[#SH_NUM] \{ .nr #SH_NUM 0 1 \}
+.             el .sp
+.          \}
+.          if \\n[#EPIGRAPH] \{\
+.             if \\n[#SINGLE_SPACE] .sp
+.          \}
+.       \}
+.       if \\n[#PP_SPACE] \{\
+.          if \\n[#QUOTE_4_HD] .sp .5v
+.       \}
+.       if !\\n[#SPACE_ADDED] .SHIM
+.       if \\n[#SPACE_ADDED] .rr #SPACE_ADDED
 .    \}
-.    el \{ .rr #NUMBER_SH \}
-.END
-\#
-\#
-\# RESET SUBHEAD NUMBER
-\# --------------------
-\# *Arguments:
-\#   <none> | <desired subhead number>
-\# *Function:
-\#   Resets incrementing register #SH_NUM to 1 or, if there's
-\#   an argument, to user supplied number.
-\# *Notes:
-\#   When the subhead number is reset, it resets the subsubhead and
-\#   parahead numbers as well.  If this behaviour is not what's
-\#   wanted, RESET_SUBSUBHEAD_NUMBER and RESET_PARAHEAD_NUMBER
-\#   allow the user to set the subsubhead and parahead number(s) to
-\#   whatever s/he desires.
-\#
-.MAC RESET_SUBHEAD_NUMBER END
-.    ie '\\$1'' \{ .nr #SH_NUM 0 1 \}
 .    el \{\
-.       nr #SH_NUM  \\$1-1 1
-.       nr #SSH_NUM 0 1
-.       nr #PH_NUM  0 1
+.       if \\n[#NUM_ARGS]>1 \{\
+.          tm1 "[mom]: Error at line \\n[.c], \\$0.
+.          tm1 "       PARAHEAD may not be given more than 1 line of text.
+.          ab  Aborting \\n[.F] at \\$0, line \\n[.c].
 .       \}
-.END
-\#
-\#
-\# NUMBER SUBSUBHEADS
-\# ---------------
-\# *Arguments:
-\#   <none> | <anything>
-\# *Function:
-\#   Toggles register #NUMBER_SSH; sets incrementing register #SSH_NUM.
-\# *Notes:
-\#   Default is OFF.
-\#
-.MAC NUMBER_SUBSUBHEADS END
-.    ie '\\$1'' \{\
-.       nr #NUMBER_SSH 1
-.       if !\\n[#SSH_NUM] \{ .nr #SSH_NUM 0 1 \}
+.       vpt 0
+.       if !(\\n[#PRINT_STYLE]=1)&(\\n[#SINGLE_SPACE]=1) .sp -1v
+.       if \\n[#QUOTE_4_HD] \{\
+.          sp -1v
+.          if \\n[#PP_SPACE] \{\
+.             sp .5v
+.             SHIM
+.         \}
+.       \}
+.       if (\\n[#QUOTE_4_HD]=0)&(\\n[#LB_4_HD]=0)&(\\n[#START]=0) \{\
+.          if !\\n[#LB_4_PARAHEAD] .sp -1v
+.       \}
+.    \}
+.    ev HEADING
+.    evc 0
+.\" Style
+.    if \\n[#PRINT_STYLE]=2 \{\
+.       fam \\*[$HEAD_\\n[#LEVEL]_FAM]
+.       ft  \\*[$HEAD_\\n[#LEVEL]_FT]
+.       ps  \\*[$HEAD_\\n[#LEVEL]_SIZE]
+.       nf
+.    \}
+.\" Numbering
+.    ds $TOC_HD_NUM_PREV \\*[$TOC_HD_NUM]
+.    rm $TOC_HD_NUM
+.    rm $PDF_HD_NUM
+.    ie \\n[#NUMBER_HEAD_\\n[#LEVEL]] \{\
+.       if \\n[#PREFIX_CH_NUM] .ds $HD_NUM \\n[#CH_NUM].
+.       nr #HEAD_\\n[#LEVEL]_NUM +1       \" incremented manually here; still 
auto-increments
+.\" Reset numbering registers for headings beneath current level
+.       nr @LEVEL \\n[#LEVEL] 1           \" loop step
+.       nr #LOOP \\n[#ACTIVE_LEVELS]      \" loop count
+.       while address@hidden<=\\n[#LOOP] \
+.          if address@hidden \
+.             nr address@hidden 0 1
+.\" Build numbering strings for body and toc
+.       nr @LEVEL 0 1                     \" loop step
+.       nr #LOOP \\n[#LEVEL]              \" loop count
+.       while address@hidden<=\\n[#LOOP] \
+.          if address@hidden \
+.             as $HD_NUM address@hidden
+.       ie \\n[#TRUNC_TOC_HD_NUM] \
+.          ds $TOC_HD_NUM \\n[#HEAD_\\n[#LEVEL]_NUM].
+.       el .ds $TOC_HD_NUM \\*[$HD_NUM]
+.       if \\n[#LEVEL]=1 \
+.          ds $TOC_HD_NUM_PREV \\*[$TOC_HD_NUM]
+.       if \\n[#TOC_NO_HD_NUM] .rm $TOC_HD_NUM
+.       if !\\n[#HEAD_\\n[#LEVEL]_NUM]] .rm $TOC_HD_NUM
+.       as $HD_NUM \[hd-num-spacer]
+.       ds $PDF_HD_NUM \\*[$TOC_HD_NUM]
+.       if !'\\*[$TOC_HD_NUM]'' .as $TOC_HD_NUM \[toc-hd-num-spacer]
+.       if !'\\*[$PDF_HD_NUM]'' .as $PDF_HD_NUM " "
+.    \}
+.    el .nr @LEVEL \\n[#LEVEL] 1
+.\" TOC collection and formatting
+.    nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ]
+.    af #TOC_ENTRY_PN \\g[#PAGENUMBER]
+.    nr #ARG_NUM 0 1
+.    while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
+.       as $TOC_HEAD_\\n[#LEVEL]_ITEM "\\$[\\n+[#ARG_NUM]]
+.       if \\n[#NUM_ARGS]>\\n[#ARG_NUM] \
+.          as $TOC_HEAD_\\n[#LEVEL]_ITEM "\\*[toc-word-space]
+.    \}
+.    PDF_BOOKMARK \
+        \\*[PDF_NM] \\n[#LEVEL]+1 \
+        \\*[$PDF_HD_NUM] \\*[$TOC_HEAD_\\n[#LEVEL]_ITEM]
+.    rm PDF_NM
+.    rm $PDF_HD_NUM
+.    ev TOC_EV
+.    ie \\n[#PRINT_STYLE]=1 \{\
+.       fam \\*[$TYPEWRITER_FAM]
+.       ft  R
+.       ps  \\*[$TYPEWRITER_PS]
 .    \}
-.    el \{ .rr #NUMBER_SSH \}
-.END
-\#
-\#
-\# RESET SUBSUBHEAD NUMBER
-\# --------------------
-\# *Arguments:
-\#   <none> | <desired subsubhead number>
-\# *Function:
-\#   Resets incrementing register #SSH_NUM to 1 or, if there's
-\#   an argument, to user supplied number.
-\# *Notes:
-\#   When the subsubhead number is reset, it resets the parahead number as
-\#   well.  If this behaviour is not what's wanted, RESET_PARAHEAD_NUMBER
-\#   allows the user to set the parahead number to whatever s/he desires.
-\#
-.MAC RESET_SUBSUBHEAD_NUMBER END
-.    ie '\\$1'' \{ .nr #SSH_NUM 0 1 \}
 .    el \{\
-.       nr #SSH_NUM \\$1-1 1
-.       nr #PH_NUM 0 1
+.       FAMILY  \\*[$TOC_HEAD_\\n[#LEVEL]_FAM]
+.       FT      \\*[$TOC_HEAD_\\n[#LEVEL]_FT]
+.       PT_SIZE \\n[#TOC_PS]u\\*[$TOC_HEAD_\\n[#LEVEL]_SIZE]
+.    \}
+.\" Indents for TOC heading levels.
+.\" First, numbered heads.  @LEVEL here is #LEVEL+1
+.    ie \\n[#NUMBER_HEAD_\\n[#LEVEL]] \{\
+.       ie !\\n[#TOC_NO_HD_NUM] \{\
+.          ie \\n[#TRUNC_TOC_HD_NUM] \{\
+.             if address@hidden \{\
+.                ie address@hidden \{\
+.                   ie address@hidden \
+.                      nr address@hidden \
address@hidden'\\*[$TOC_HD_NUM]'+1.5m
+.                   el \
+.                      nr address@hidden \
address@hidden'\\*[$TOC_HD_NUM]'
 .    \}
-.END
-\#
-\# NUMBER PARAHEADS
-\# ----------------
-\# *Arguments:
-\#   <none> | <anything>
-\# *Function:
-\#   Toggles register #NUMBER_PH; sets incrementing register #PH_NUM.
-\# *Notes:
-\#   Default is OFF.
-\#
-.MAC NUMBER_PARAHEADS END
-.    ie '\\$1'' \{\
-.       nr #NUMBER_PH 1
-.       if !\\n[#PH_NUM] \{ .nr #PH_NUM 0 1 \}
+.                el \
+.                   nr address@hidden \
+                      address@hidden
 .    \}
-.    el \{ .rr #NUMBER_PH \}
-.END
-\#
-\#
-\# RESET PARAHEAD NUMBER
-\# ---------------------
-\# *Arguments:
-\#   <none> | <desired parahead number>
-\# *Function:
-\#   Resets incrementing register #PH_NUM to 1 or, if there's
-\#   an argument, to user supplied number.
-\# *Notes:
-\#   Resetting the parahead number resets the parahead number
-\#   only.
-\#
-.MAC RESET_PARAHEAD_NUMBER END
-.    ie '\\$1'' \{ .nr #PH_NUM 0 1 \}
-.    el \{ .nr #SH_NUM \\$1-1 1 \}
-.END
-\#
-\#
-\# PREFIX CHAPTER NUMBERS TO NUMBERED HEADS, SUBHEADS AND PARAHEADS
-\# ----------------------------------------------------------------
-\# *Arguments:
-\#   <none> | <chapter number> | <anything>
-\# *Function:
-\#   Toggles register #PREFIX_CH_NUM. Sets register #CH_NUM from
-\#   string $CHAPTER if $CHAPTER is a digit; if <chapter number> arg
-\#   given, sets #CH_NUM to arg.
-\# *Notes:
-\#   Default is OFF.
-\#
-.MAC PREFIX_CHAPTER_NUMBER END
-.    ie '\\$1'' \{\
-.       ie r#CH_NUM \{\
-.          nr #PREFIX_CH_NUM 1
-.          if \\n[#CHAPTER_CALLED] \{\
-.             ie \B'\\*[$CHAPTER]' \{\
-.                nr #CH_NUM \\*[$CHAPTER]
 .             \}
 .             el \{\
-.                PREFIX_CH_NUM_WARNING
+.             if address@hidden \{\
+.                ie address@hidden \{\
+.                   ie address@hidden \{\
+.                      ie address@hidden \
+.                         nr address@hidden \
address@hidden'\\*[$TOC_HD_NUM_PREV]'+1.5m
+.                      el \
+.                         nr address@hidden \
address@hidden'.\[toc-hd-num-spacer]'
+.                   \}
+.                   el \
+.                      nr address@hidden \
address@hidden'\\n[#TOC_HD_NUM].'
+.                   ie \\n[#LEVEL]=1 \
+.                      nr address@hidden +\w'\0'
+.                   el \{\
+.                      if address@hidden \{\
+.                         nr @LEVEL address@hidden 1
+.                         nr address@hidden +\w'\0'
+.                      \}
+.                   \}
+.                \}
+.                el \
+.                   nr address@hidden \
address@hidden@LEVEL]_INDENT]
+.             \}
+.             if \\n[#LEVEL]=1 \{\
+.                if address@hidden \{\
+.                   if \\n[#PREFIX_CH_NUM] \
+.                      nr address@hidden \w'\\*[$TOC_HD_NUM]'
+.                \}
 .             \}
-.             rr #CHAPTER_CALLED
 .          \}
 .       \}
 .       el \{\
-.          ie \B'\\*[$CHAPTER]' \{\
-.             nr #PREFIX_CH_NUM 1
-.             nr #CH_NUM \\*[$CHAPTER]
+.          ie address@hidden \{\
+.             if address@hidden \
+.                nr address@hidden \
+                    address@hidden
 .          \}
 .          el \{\
-.             PREFIX_CH_NUM_WARNING
+.             if address@hidden \
+.                nr address@hidden \
address@hidden@LEVEL]_INDENT]
 .          \}
 .       \}
 .    \}
+.\" Non-numbered heads
 .    el \{\
-.       ie \B'\\$1' \{\
-.          nr #CH_NUM \\$1
-.          nr #PREFIX_CH_NUM 1
+.       nr @LEVEL \\n[#LEVEL] 1
+.       ie address@hidden \{\    \" increments @LEVEL even if false
+.          if address@hidden \{\
+.             nr address@hidden \
address@hidden
+.             if !\\n[#LEVEL]=\\n[#LAST_LEVEL] \{\
+.                if address@hidden \
+.                   nr #TOC_HEAD_\\n[#LEVEL]_INDENT \
address@hidden'\\*[$TOC_HD_NUM_PREV]'
+.             \}
+.          \}
 .       \}
 .       el \{\
-.          rr #PREFIX_CH_NUM
+.          nr address@hidden \
+              address@hidden
+.          if \\n[#LEVEL]=1 \{\
+.             if !\\n[#FROM_STYLE_1] \
+.                nr #TOC_HEAD_1_INDENT 0
 .       \}
 .    \}
-.END
-\#
-.MAC PREFIX_CH_NUM_WARNING END
-.    tm1 "[mom]: PREFIX_CHAPTER_NUMBER cannot determine a chapter number.
-.    tm1 "       Please enter the current chapter number as a digit after
-.    tm1 "       PREFIX_CHAPTER_NUMBER.
-.    ab Aborting on PREFIX_CHAPTER_NUMBER at line \\n(.c.
-.END
-\#
-\#
-\# ---Main heads---
-\#
-\# HEAD CAPS
-\# ---------
-\# *Arguments:
-\#   <none> | <anything>
-\# *Function:
-\#   Creates or modifies register #HEAD_CAPS.
-\# *Notes:
-\#   Default is on.
-\#
-.MAC HEAD_CAPS END
-.    ie '\\$1'' \{ .nr #HEAD_CAPS 1 \}
-.    el \{ .nr #HEAD_CAPS 0 \}
-.END
-\#
-\#
-\# HEAD SPACE
-\# ----------
-\# *Arguments:
-\#   <none> | <anything>
-\# *Function:
-\#   Creates register #HEAD_SPACE, which toggles whether the space
-\#   before heads is 1 extra line space ("off") or 2 ("on").  Used only
-\#   in PRINTSTYLE TYPESET.
-\# *Notes:
-\#   Default is on.
-\#
-.MAC HEAD_SPACE END
-.    ie '\\$1'' \{ .nr #HEAD_SPACE 1 \}
-.    el \{ .nr #HEAD_SPACE 0 \}
-.END
-\#
-\#
-\# MAIN HEAD
-\# ---------
-\# *Arguments:
-\#   "text of main head" ["text of main head"] ...
-\# *Function:
-\#   In TYPEWRITE, prints main heads centered, all caps, underlined.
-\#   In TYPESET, prints bold main heads 1 point larger than running
-\#   text, all caps, underlined.
-\# *Notes:
-\#   The HEAD macro requires that double-quotes (") surround
-\#   each line of text.
-\#
-.MAC HEAD END
-.    if \\n[#UNDERLINE_ON]=1 .UNDERLINE OFF
-.    br
-.    if \\n[#PRINT_STYLE]=1 \{ .ne \\n[#NUM_ARGS]+2 \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       ie \\n[#HEAD_SPACE] \{ .ne \\n[#NUM_ARGS]+3 \}
-.       el \{ .ne \\n[#NUM_ARGS]+2 \}
 .    \}
-.\" Collect head for TOC.
+.    nr address@hidden 1
+.    HD_TO_TOC
+.    rm $TOC_HEAD_\\n[#LEVEL]_ITEM
+.\" Print heading
+.    if !\\n[#PARAHEAD] .\\*[$HEAD_\\n[#LEVEL]_QUAD]
+.    if \\n[#CAPS_ON] \{\
+.       CAPS OFF
+.       nr #CAPS_RESTORE 1
+.    \}
+.    if \\n[#HEAD_\\n[#LEVEL]_CAPS] \{\
+.       CAPS 
+.       nr #CAPS_OFF 1
+.    \}
+.    if !'\\*[$HEAD_\\n[#LEVEL]_COLOR]'' \
+.       COLOR \\*[$HEAD_\\n[#LEVEL]_COLOR]
+.    nop \X'ps: exec decornone'\c
 .    nr #ARG_NUM 0 1
-.    nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ]
-.    af #TOC_ENTRY_PN \\g[#PAGENUMBER]
-.    while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.       ie \\n[#ARG_NUM]=\\n[#NUM_ARGS] \{\
-.          as $TOC_HEAD_ITEM \\$[\\n+[#ARG_NUM]]\\|
+.    while \\n+[#ARG_NUM]<=\\n[#NUM_ARGS] \{\
+.       if \\n[#PARAHEAD] \
+.          nr #PP_TEXT_OFFSET \
+              \w'\\*[$HD_NUM]\\$[\\n[#ARG_NUM]]'+\w'\[parahead-spacer]'
+.       if 
(\\n[#HEAD_\\n[#LEVEL]_UNDERSCORE]=0)&(\\n[#HEAD_\\n[#LEVEL]_UNDERSCORE2]=0) \{\
+.          ie \\n[#HD_NUM_INDENT] \{\
+.             if !'\\*[$HEAD_\\n[#LEVEL]_QUAD]'CENTER' \
+.                ti \\n[#HD_NUM_INDENT]u 
+.             PRINT \
+"\v'-\\*[$HEAD_\\n[#LEVEL]_BASELINE_ADJ]'\\$[\\n[#ARG_NUM]]
+.             br
 .       \}
 .       el \{\
-.\" Note that in the .as lines, below, \ at the end has a literal
-.\" space after it.
-.          ie \\n[#NUMBER_HEAD] \{\
-.             ie \\n[#ARG_NUM]=0 \{\
-.                as $TOC_HEAD_ITEM \\n+[#HEAD_NUM].\0\\$[\\n+[#ARG_NUM]]\ \"
-.                nr #HEAD_NUM \\n-[#HEAD_NUM]
+.             ie !\\n[#PARAHEAD] \{\
+.                PRINT \
+"\v'-\\*[$HEAD_\\n[#LEVEL]_BASELINE_ADJ]'\\*[$HD_NUM]\\$[\\n[#ARG_NUM]]
+.                br
 .             \}
 .             el \{\
-.                as $TOC_HEAD_ITEM \\$[\\n+[#ARG_NUM]]\ \"
+.                if (\\n[#PP]>0):(\\n[#INDENT_FIRST_PARAS]) \{\
+.                   if !\\n[#LB_4_PARAHEAD] \{\
+.                      if !\\n[#START] \{\
+.                         if \\n[#PP_ACTIVE] \{\
+.                            ie \\n[#PP]=1 .br
+.                            el \{\
+.                               nr #PP_TEXT_OFFSET +\\n[#PP_INDENT]
+.                               ti \\n[#PP_INDENT]u
 .             \}
 .          \}
-.          el \{\
-.             as $TOC_HEAD_ITEM \\$[\\n+[#ARG_NUM]]\ \"
 .          \}
 .       \}
-.\}
-.\" Note the use of \!, which transparently embeds the macros used
-.\" in the TOC_ENTRIES diversion.  The elements they control must be
-.\" processed literally when the diversion is output.
-.    ev TOC_EV
-.    da TOC_ENTRIES
-.    if \\n[#PRINT_STYLE]=1 \{\
-\!.     fam \\*[$TYPEWRITER_FAM]
-\!.     ft  R
-\!.     ps  \\*[$TYPEWRITER_PS]
-.    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_HEAD_FAM]
-\!.     FT      \\*[$TOC_HEAD_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_HEAD_SIZE_CHANGE]
-.    \}
-\!.  TRAP OFF
-\!.  PAD_MARKER ^
-.    ie \\n[#PRINT_STYLE]=1 \{\
-\!.     PAD "\\h'\w'\0\0.'u'\\*[$TOC_HEAD_ITEM]\\*[$TOC_PN_TYPEWRITE]"
-.    \}
-.    el \{\
-\!.     PAD "\\h'\\n[#TOC_HEAD_INDENT]u'\\*[$TOC_HEAD_ITEM]\\*[$TOC_PN]"
-.    \}
-\!.  PAD_MARKER #
-\!.  EOL
-\!.  ST 100 L
-\!.  ST 101 R
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_PN_FAM]
-\!.     FT      \\*[$TOC_PN_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
-.    \}
-\!.  TAB 100
-\!.  PRINT \\*[LEADER]
-\!.  TN
-\!.  TRAP
-\!.  PRINT \\n[#TOC_ENTRY_PN]
-\!.  TQ
-.    di
-.    ev
-.\" End collection of head for TOC
-.\" Process head
-.    nr #HEAD 1
-.    ev HEAD
-.    ll \\n[#L_LENGTH]u
-.    ta \\n(.lu
-.    if \\n[#COLUMNS] \{\
-.       ll \\n[#COL_L_LENGTH]u
-.       ta \\n(.lu
-.    \}
-.    CHECK_INDENT
-.    QUAD \\*[$HEAD_QUAD]
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       TYPEWRITER
-.       vs  \\n[#DOC_LEAD]u
-.    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       FAMILY  \\*[$HEAD_FAM]
-.       FT      \\*[$HEAD_FT]
-.       PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$HEAD_SIZE_CHANGE]
-.       LS      \\n[#DOC_LEAD]u
-.    \}
-.    if r#QUOTE             \{ .rr #QUOTE \}
-.    if r#EPIGRAPH          \{ .rr #EPIGRAPH \}
-.    ie \\n[#START] \{\
-.       if \\n[#DOC_HEADER]=0 \{ .RLD 1v \}
-.    \}
-.    el \{\
-.       if \\n[#PRINT_STYLE]=1 \{\
-.          if !\\n[#LINEBREAK] \{\
-.             ALD \\n[#DOC_LEAD]u
-.             if \\n[#SINGLE_SPACE] \{ .ALD \\n[#DOC_LEAD]u \}
-.          \}
-.       \}
-.       if \\n[#PRINT_STYLE]=2 \{\
-.          ie \\n[#PP_SPACE] \{\
-.             ie \\n[#END_QUOTE] \{ . \}
-.             el \{\
-.                if !\\n[#LINEBREAK] \{\
-.                   if \\n[#HEAD_SPACE] \{ .ALD \\n[#DOC_LEAD]u \}
-.                \}
-.             \}
-.          \}
-.          el \{\
-.             ie \\n[#HEAD_SPACE] \{ .ALD \\n[#DOC_LEAD]u*2u \}
-.             el \{ .ALD \\n[#DOC_LEAD]u \}
-.          \}
-.          if \\n[#END_QUOTE] \{\
-.             if !\\n[#Q_FITS] \{\
-.                RLD \\n[#DOC_LEAD]u
-.                if \\n[#PP_ACTIVE] \{ .ALD \\n[#DOC_LEAD]u \}
-.             \}
-.             if \\n[#Q_AT_TOP] \{\
-.                RLD \\n[#DOC_LEAD]u
-.                if \\n[#Q_AT_TOP] \{ .ALD \\n[#DOC_LEAD]u \}
-.             \}
-.          \}
-.          if \\n[#LINEBREAK] \{\
-.             if \\n[#HEAD_SPACE] \{ .RLD \\n[#DOC_LEAD]u \}
-.          \}
-.       \}
-.    \}
-.\" Print head
-.    nr #ARG_NUM 0 1
-.    nr #FROM_HEAD 1
-.    if \\n[#HEAD_CAPS] \{ .CAPS \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       if \\n[#HEAD_COLOR]=1 \{\
-.          TRAP OFF
-.          COLOR \\*[$HEAD_COLOR]
-.          EOL
-.          TRAP
-.       \}
-.    \}
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       ie \\n[#HEAD_CAPS]=1 \{\
-.          ds $HEAD_UNDERLINE_GAP 2p
-.       \}
-.       el \{\
-.          ds $HEAD_UNDERLINE_GAP 4p
-.       \}
-.    \}
-.    while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.       ie \\n[#NUMBER_HEAD] \{\
-.          ie \\n[#ARG_NUM]=0 \{\
-.             ie \\n[#PREFIX_CH_NUM]=1 \{\
-.                ds $CH_NUM \\n[#CH_NUM].
-.             \}
-.             el \{\
-.                rm $CH_NUM
-.             \}
-.             br
-.             ie \\n[#HEAD_UNDERLINE]=0 \{\
-.                PRINT "\\*[$CH_NUM]\\n+[#HEAD_NUM].\0\\$[\\n+[#ARG_NUM]]"
-.             \}
-.             el \{\
-.                UNDERSCORE \\*[$HEAD_UNDERLINE_GAP] 
"\\*[$CH_NUM]\\n+[#HEAD_NUM].\0\\$[\\n+[#ARG_NUM]]"
-.             \}
-.             br
-.          \}
-.          el \{\
-.             br
-.             ie \\n[#HEAD_UNDERLINE]=0 \{\
-.                PRINT "\\$[\\n+[#ARG_NUM]]"
-.             \}
-.             el \{\
-.                UNDERSCORE \\*[$HEAD_UNDERLINE_GAP] "\\$[\\n+[#ARG_NUM]]"
-.             \}
-.             br
-.          \}
-.       \}
-.       el \{\
-.          br
-.          ie \\n[#HEAD_UNDERLINE]=0 \{\
-.             PRINT "\\$[\\n+[#ARG_NUM]]"
-.          \}
-.          el \{\
-.             UNDERSCORE \\*[$HEAD_UNDERLINE_GAP] "\\$[\\n+[#ARG_NUM]]"
-.          \}
-.          br
-.       \}
-.\}
-.    REMOVE_INDENT
-.    CAPS OFF
-.    ev
-.    ALD \\n[#DOC_LEAD]u
-.    if \\n[#NUMBER_HEAD] \{ .RESET_SUBHEAD_NUMBER    \}
-.    if \\n[#NUMBER_SH]   \{ .RESET_SUBSUBHEAD_NUMBER \}
-.    if \\n[#NUMBER_SSH]  \{ .RESET_PARAHEAD_NUMBER   \}
-.    if r#START      \{ .rr #START     \}
-.    if r#EPIGRAPH   \{ .rr #EPIGRAPH  \}
-.    if r#QUOTE      \{ .rr #QUOTE     \}
-.    if r#Q_FITS     \{ .rr #Q_FITS    \}
-.    if r#END_QUOTE  \{ .rr #END_QUOTE \}
-.    if r#LINEBREAK  \{ .rr #LINEBREAK \}
-.    if r#Q_AT_TOP   \{ .rr #Q_AT_TOP  \}
-.    if r#PP_ACTIVE  \{ .rr #PP_ACTIVE \}
-.    rr #ARG_NUM
-.    rr #FROM_HEAD
-.    rm $TOC_HEAD_ITEM
-.    nr #PP 0
-.END
-\#
-\#
-\# ---Subheads---
-\#
-\# SUBHEAD BASELINE ADJUSTMENT
-\# ---------------------------
-\# *Arguments:
-\#   <amount to raise subhead>
-\# *Function:
-\#   Creates or modifies register #SH_BASELINE_ADJ
-\#
-.MAC SUBHEAD_BASELINE_ADJUST END
-.    nr #SH_BASELINE_ADJ \\$1
-.END
-\#
-\# SUBHEAD
-\# -------
-\# *Arguments:
-\#   "text of subhead" ["text of subhead"] ...
-\# *Function:
-\#   In TYPEWRITE, prints subheads underlined.
-\#   In TYPESET, prints subheads bold, .5 points larger than running
-\#   text.
-\#   In both styles, a line space precedes the subhead, and a small
-\#   amount of lead comes after.
-\# *Notes:
-\#   As with the HEAD macro, double-quotes (") must surround
-\#   each line of text.
-\#
-.MAC SUBHEAD END
-.    if \\n[#UNDERLINE_ON]=1 .UNDERLINE OFF
-.    br
-.    ne \\n[#NUM_ARGS]+2
-.\" Collect subhead for TOC.
-.    nr #ARG_NUM 0 1
-.    nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ]
-.    while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.       ie \\n[#ARG_NUM]=\\n[#NUM_ARGS] \{\
-.          as $TOC_SH_ITEM \\$[\\n+[#ARG_NUM]]\\|
-.       \}
-.       el \{\
-.\" Note that in the .as lines, below, \ at the end has a literal
-.\" space after it.
-.          ie \\n[#NUMBER_SH] \{\
-.             ie \\n[#ARG_NUM]=0 \{\
-.                as $TOC_SH_ITEM \\n+[#SH_NUM].\0\\$[\\n+[#ARG_NUM]]\ \"
-.                nr #SH_NUM \\n-[#SH_NUM]
-.             \}
-.             el \{\
-.                as $TOC_SH_ITEM \\$[\\n+[#ARG_NUM]]\ \"
-.             \}
-.          \}
-.          el \{\
-.             as $TOC_SH_ITEM \\$[\\n+[#ARG_NUM]]\ \"
-.          \}
-.       \}
-.\}
-.\" Note the use of \!, which transparently embeds the macros used
-.\" in the TOC_ENTRIES diversion.  The elements they control must be
-.\" processed literally when the diversion is output.
-.    ev TOC_EV
-.    da TOC_ENTRIES
-.    if \\n[#PRINT_STYLE]=1 \{\
-\!.     fam \\*[$TYPEWRITER_FAM]
-\!.     ft  R
-\!.     ps  \\*[$TYPEWRITER_PS]
-.    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_SH_FAM]
-\!.     FT      \\*[$TOC_SH_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_SH_SIZE_CHANGE]
-.    \}
-\!.  TRAP OFF
-\!.  PAD_MARKER ^
-.    ie \\n[#PRINT_STYLE]=1 \{\
-\!.     PAD "\\h'\w'\0\0.'u*2u'\\*[$TOC_SH_ITEM]\\*[$TOC_PN_TYPEWRITE]"
-.    \}
-.    el \{\
-\!.     PAD "\\h'\\n[#TOC_SH_INDENT]u'\\*[$TOC_SH_ITEM]\\*[$TOC_PN]"
-.    \}
-\!.  PAD_MARKER #
-\!.  EOL
-\!.  ST 100 L
-\!.  ST 101 R
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_PN_FAM]
-\!.     FT      \\*[$TOC_PN_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
-.    \}
-\!.  TAB 100
-\!.  PRINT \\*[LEADER]
-\!.  TN
-\!.  TRAP
-\!.  PRINT \\n[#TOC_ENTRY_PN]
-\!.  TQ
-.    di
-.    ev
-.\" End collection of subhead for TOC
-.\" Process subhead
-.    nr #ARG_NUM 0 1
-.    if r#QUOTE    \{ .rr #QUOTE    \}
-.    if r#Q_AT_TOP \{ .rr #Q_AT_TOP \}
-.    nr #SUBHEAD 1
-.    ev SUBHEAD
-.    ll \\n[#L_LENGTH]u
-.    ta \\n(.lu
-.    if \\n[#COLUMNS] \{\
-.       ll \\n[#COL_L_LENGTH]u
-.       ta \\n(.lu
-.    \}
-.    CHECK_INDENT
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       TYPEWRITER
-.       vs  \\n[#DOC_LEAD]u
-.       QUAD   \\*[$SH_QUAD]
-.    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       FAMILY  \\*[$SH_FAM]
-.       FT      \\*[$SH_FT]
-.       PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$SH_SIZE_CHANGE]
-.       LS      \\n[#DOC_LEAD]u
-.       QUAD    \\*[$SH_QUAD]
-.    \}
-.    ie \\n[#START] \{ .RLD 1v \}
-.    el \{\
-.       ie \\n[#HEAD]=1 \{ . \}
-.       el \{\
-.          if \\n[#PRINT_STYLE]=1 \{\
-.             if !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
-.          \}
-.          if \\n[#PRINT_STYLE]=2 \{\
-.             ie \\n[#PP_SPACE]=1 \{\
-.                ie !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
-.                el \{ .RLD \\n[#DOC_LEAD]u \}
-.             \}
-.             el \{\
-.                if !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
-.             \}
-.          \}
-.       \}
-.    \}
-.\" Print subhead
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.          ie \\n[#NUMBER_SH] \{\
-.             ie \\n[#ARG_NUM]=0 \{\
-.                ie \\n[#PREFIX_CH_NUM]=1 \{\
-.                   ds $CH_NUM \\n[#CH_NUM].
-.                \}
-.                el \{\
-.                   rm $CH_NUM
-.                \}
-.                ie \\n[#NUMBER_HEAD] \{\
-.                   br
-.                   UNDERSCORE 
"\v'-\\n[#SH_BASELINE_ADJ]u'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n+[#SH_NUM].\0\\$[\\n+[#ARG_NUM]]"
-.                   br
-.                \}
-.                el \{\
-.                   br
-.                   UNDERSCORE 
"\v'-\\n[#SH_BASELINE_ADJ]u'\\*[$CH_NUM]\\n+[#SH_NUM].\0\\$[\\n+[#ARG_NUM]]"
-.                   br
-.                \}
-.             \}
-.             el \{\
-.                br
-.                UNDERSCORE "\v'-\\n[#SH_BASELINE_ADJ]u'\\$[\\n+[#ARG_NUM]]"
-.                br
-.             \}
-.          \}
-.          el \{\
-.             br
-.             UNDERSCORE "\v'-\\n[#SH_BASELINE_ADJ]u'\\$[\\n+[#ARG_NUM]]"
-.             br
-.          \}
-.\}
-.    \}
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       if \\n[#SINGLE_SPACE] \{ .ALD \\n[#DOC_LEAD]u \}
-.    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       if \\n[#SH_COLOR]=1 \{ .COLOR \\*[$SH_COLOR] \}
-.       ie \\n[#PP_SPACE]=0 \{\
-.          while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.             ie \\n[#NUMBER_SH] \{\
-.                ie \\n[#ARG_NUM]=0 \{\
-.                   ie \\n[#PREFIX_CH_NUM]=1 \{\
-.                      ds $CH_NUM \\n[#CH_NUM].
-.                   \}
-.                   el \{\
-.                      rm $CH_NUM
-.                   \}
-.                   ie \\n[#NUMBER_HEAD] \{\
-.                      br
-.                      PRINT 
"\v'-\\n[#SH_BASELINE_ADJ]u'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n+[#SH_NUM].\0\\$[\\n+[#ARG_NUM]]
-.                      br
-.                   \}
-.                   el \{\
-.                      br
-.                      PRINT 
"\v'-\\n[#SH_BASELINE_ADJ]u'\\*[$CH_NUM]\\n+[#SH_NUM].\0\\$[\\n+[#ARG_NUM]]
-.                      br
-.                   \}
-.                \}
-.                el \{\
-.                   br
-.                   PRINT "\v'-\\n[#SH_BASELINE_ADJ]u'\\$[\\n+[#ARG_NUM]]
-.                   br
-.                \}
-.             \}
-.             el \{\
-.                br
-.                PRINT "\v'-\\n[#SH_BASELINE_ADJ]u'\\$[\\n+[#ARG_NUM]]
-.                br
-.             \}
-.\}
-.       \}
-.       el \{\
-.          ALD \\n[#DOC_LEAD]u
-.          if \\n[#HEAD]=1      \{ .RLD \\n[#DOC_LEAD]u \}
-.          if \\n[#END_QUOTE]   \{ .RLD \\n[#DOC_LEAD]u \}
-.          if \\n[#EPIGRAPH]    \{ .RLD \\n[#DOC_LEAD]u \}
-.          while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.             ie \\n[#NUMBER_SH] \{\
-.                ie \\n[#ARG_NUM]=0 \{\
-.                   ie \\n[#PREFIX_CH_NUM]=1 \{\
-.                      ds $CH_NUM \\n[#CH_NUM].
-.                   \}
-.                   el \{\
-.                      rm $CH_NUM
-.                   \}
-.                   ie \\n[#NUMBER_HEAD] \{\
-.                      br
-.                      PRINT 
"\v'-\\n[#SH_LEAD_ADJUST]u'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n+[#SH_NUM]\0\\$[\\n+[#ARG_NUM]]
-.                      br
-.                   \}
-.                   el \{\
-.                      br
-.                      PRINT 
"\v'-\\n[#SH_LEAD_ADJUST]u'\\*[$CH_NUM]\\n+[#SH_NUM].\0\\$[\\n+[#ARG_NUM]]
-.                      br
-.                   \}
-.                \}
-.                el \{\
-.                   br
-.                   PRINT "\v'-\\n[#SH_LEAD_ADJUST]u'\\$[\\n+[#ARG_NUM]]
-.                   br
-.                \}
-.             \}
-.             el \{\
-.                br
-.                PRINT "\v'-\\n[#SH_LEAD_ADJUST]u'\\$[\\n+[#ARG_NUM]]
-.                br
-.             \}
-.\}
-.          ALD \\n[#DOC_LEAD]u
-.       \}
-.    \}
-.    REMOVE_INDENT
-.    ev
-.    if \\n[#NUMBER_SH] \{ .RESET_PARAHEAD_NUMBER \}
-.    if r#START     \{ .rr #START     \}
-.    if r#EPIGRAPH  \{ .rr #EPIGRAPH  \}
-.    if r#Q_FITS    \{ .rr #Q_FITS    \}
-.    if r#END_QUOTE \{ .rr #END_QUOTE \}
-.    if r#LINEBREAK \{ .rr #LINEBREAK \}
-.    rm $TOC_SH_ITEM
-.    nr #PP 0
-.    nr #HEAD 2
-.END
-\#
-\# ---Subsubheads---
-\#
-\#
-\# SUBSUBHEAD BASELINE ADJUSTMENT
-\# ------------------------------
-\# *Arguments:
-\#   <amount to raise subsubhead>
-\# *Function:
-\#   Creates or modifies register #SSH_BASELINE_ADJ
-\#
-.MAC SUBSUBHEAD_BASELINE_ADJUST END
-.    nr #SSH_BASELINE_ADJ \\$1
-.END
-\#
-\# SUBSUBHEAD
-\# -------
-\# *Arguments:
-\#   "text of subsubhead" ["text of subsubhead"] ...
-\# *Function:
-\#   In TYPEWRITE, prints subsubheads underlined.
-\#   In TYPESET, prints subsubheads bold, .5 points larger than running
-\#   text.
-\#   In both styles, a line space precedes the subsubhead, and a small
-\#   amount of lead comes after.
-\# *Notes:
-\#   As with the HEAD macro, double-quotes (") must surround
-\#   each line of text.
-\#
-.MAC SUBSUBHEAD END
-.    if \\n[#UNDERLINE_ON]=1 .UNDERLINE OFF
-.    br
-.    ne \\n[#NUM_ARGS]+2
-.\" Collect subsubhead for TOC.
-.    nr #ARG_NUM 0 1
-.    nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ]
-.    while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.       ie \\n[#ARG_NUM]=\\n[#NUM_ARGS] \{\
-.          as $TOC_SSH_ITEM \\$[\\n+[#ARG_NUM]]\\|
-.       \}
-.       el \{\
-.\" Note that in the .as lines, below, \ at the end has a literal
-.\" space after it.
-.          ie \\n[#NUMBER_SSH] \{\
-.             ie \\n[#ARG_NUM]=0 \{\
-.                as $TOC_SSH_ITEM \\n+[#SSH_NUM].\0\\$[\\n+[#ARG_NUM]]\ \"
-.                nr #SSH_NUM \\n-[#SSH_NUM]
-.             \}
-.             el \{\
-.                as $TOC_SSH_ITEM \\$[\\n+[#ARG_NUM]]\ \"
-.             \}
-.          \}
-.          el \{\
-.             as $TOC_SSH_ITEM \\$[\\n+[#ARG_NUM]]\ \"
-.          \}
-.       \}
-.\}
-.\" Note the use of \!, which transparently embeds the macros used
-.\" in the TOC_ENTRIES diversion.  The elements they control must be
-.\" processed literally when the diversion is output.
-.    ev TOC_EV
-.    da TOC_ENTRIES
-.    if \\n[#PRINT_STYLE]=1 \{\
-\!.     fam \\*[$TYPEWRITER_FAM]
-\!.     ft  R
-\!.     ps  \\*[$TYPEWRITER_PS]
-.    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_SSH_FAM]
-\!.     FT      \\*[$TOC_SSH_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_SSH_SIZE_CHANGE]
-.    \}
-\!.  TRAP OFF
-\!.  PAD_MARKER ^
-.    ie \\n[#PRINT_STYLE]=1 \{\
-\!.     PAD "\\h'\w'\0\0.'u*3u'\\*[$TOC_SSH_ITEM]\\*[$TOC_PN_TYPEWRITE]"
-.    \}
-.    el \{\
-\!.     PAD "\\h'\\n[#TOC_SSH_INDENT]u'\\*[$TOC_SSH_ITEM]\\*[$TOC_PN]"
-.    \}
-\!.  PAD_MARKER #
-\!.  EOL
-\!.  ST 100 L
-\!.  ST 101 R
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_PN_FAM]
-\!.     FT      \\*[$TOC_PN_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
-.    \}
-\!.  TAB 100
-\!.  PRINT \\*[LEADER]
-\!.  TN
-\!.  TRAP
-\!.  PRINT \\n[#TOC_ENTRY_PN]
-\!.  TQ
-.    di
-.    ev
-.\" End collection of subsubhead for TOC
-.\" Process subsubhead
-.    nr #ARG_NUM 0 1
-.    if r#QUOTE    \{ .rr #QUOTE    \}
-.    if r#Q_AT_TOP \{ .rr #Q_AT_TOP \}
-.    ev SUBSUBHEAD
-.    ll \\n[#L_LENGTH]u
-.    ta \\n(.lu
-.    if \\n[#COLUMNS] \{\
-.       ll \\n[#COL_L_LENGTH]u
-.       ta \\n(.lu
-.    \}
-.    CHECK_INDENT
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       TYPEWRITER
-.       vs  \\n[#DOC_LEAD]u
-.       QUAD   \\*[$SSH_QUAD]
-.    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       FAMILY  \\*[$SSH_FAM]
-.       FT      \\*[$SSH_FT]
-.       PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$SSH_SIZE_CHANGE]
-.       LS      \\n[#DOC_LEAD]u
-.       QUAD    \\*[$SSH_QUAD]
-.    \}
-.    if \\n[#PRINT_STYLE]=1 \{ .nr #SSH_LEAD_ADJUST \\n[#LEAD]/5 \}
-.    if \\n[#PRINT_STYLE]=2 \{ .nr #SSH_LEAD_ADJUST \\n[#LEAD]/8 \}
-.    ie \\n[#START] \{ .RLD 1v \}
-.    el \{\
-.       ie \\n[#SUBHEAD]=1 \{ . \}
-.       el \{\
-.          if \\n[#PRINT_STYLE]=1 \{\
-.             if !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
-.          \}
-.          if \\n[#PRINT_STYLE]=2 \{\
-.             ie \\n[#PP_SPACE]=1 \{\
-.                ie !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
-.                el \{ .RLD \\n[#DOC_LEAD]u \}
-.             \}
-.             el \{\
-.                if !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
 .             \}
+.                ie \\n[#PRINT_STYLE]=1 \
+.                   PRINT "\\*[UL]\\*[$HD_NUM]\\$[\\n[#ARG_NUM]]\\*[ULX]
+.                el .PRINT "\\*[$HD_NUM]\\$[\\n[#ARG_NUM]]
+.                rr #LB_4_PARAHEAD
+.                sp -1v
 .          \}
 .       \}
 .    \}
-.\" Print subsubhead
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.          ie \\n[#NUMBER_SSH] \{\
-.             ie \\n[#ARG_NUM]=0 \{\
-.                ie \\n[#PREFIX_CH_NUM]=1 \{\
-.                   ds $CH_NUM \\n[#CH_NUM].
-.                \}
-.                el \{\
-.                   rm $CH_NUM
-.                \}
-.                ie \\n[#NUMBER_HEAD] \{\
-.                   br
-.                   PRINT 
"\v'-\\n[#SSH_BASELINE_ADJ]u'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n[#SH_NUM].\\n+[#SSH_NUM].\0\\$[\\n+[#ARG_NUM]]"
+.       if \\n[#HEAD_\\n[#LEVEL]_UNDERSCORE] \{\
+.          nr #SAVED_UL_WEIGHT \\n[#UNDERSCORE_WEIGHT]
+.          UNDERSCORE_WEIGHT \\*[$HEAD_\\n[#LEVEL]_UL_WEIGHT]
+.          ie \\n[#HD_NUM_INDENT] \{\
+.             if !'\\*[$HEAD_\\n[#LEVEL]_QUAD]'CENTER' \
+.                ti \\n[#HD_NUM_INDENT]u 
+.             UNDERSCORE \\*[$HEAD_\\n[#LEVEL]_UL_GAP] \
+                "\v'-\\*[$HEAD_\\n[#LEVEL]_BASELINE_ADJ]'\\$[\\n[#ARG_NUM]]
 .                   br
 .                \}
 .                el \{\
+.             ie !\\n[#PARAHEAD] \{\
+.                UNDERSCORE \\*[$HEAD_\\n[#LEVEL]_UL_GAP] \
+"\v'-\\*[$HEAD_\\n[#LEVEL]_BASELINE_ADJ]'\\*[$HD_NUM]\\$[\\n[#ARG_NUM]]
 .                   br
-.                   PRINT 
"\v'-\\n[#SSH_BASELINE_ADJ]u'\\*[$CH_NUM]\\n+[#SSH_NUM].\0\\$[\\n+[#ARG_NUM]]"
-.                   br
-.                \}
 .             \}
 .             el \{\
-.                br
-.                PRINT "\v'-\\n[#SSH_BASELINE_ADJ]u'\\$[\\n+[#ARG_NUM]]"
-.                br
+.                if (\\n[#PP]>0):(\\n[#INDENT_FIRST_PARAS]) \{\
+.                   if !\\n[#LB_4_HD] \{\
+.                      if !\\n[#START] \{\
+.                         if \\n[#PP_ACTIVE] \{\
+.                   nr #PP_TEXT_OFFSET +\\n[#PP_INDENT]
+.                   if (\\n[#PRINT_STYLE]=1)&(\\n[#SINGLE_SPACE]=1) .sp -1v
+.                   ti \\n[#PP_INDENT]u
 .             \}
 .          \}
-.          el \{\
-.             br
-.             PRINT "\v'-\\n[#SSH_BASELINE_ADJ]u'\\$[\\n+[#ARG_NUM]]"
-.             br
-.          \}
-.\}
 .    \}
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       if \\n[#SINGLE_SPACE] \{ .ALD \\n[#DOC_LEAD]u \}
 .    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       if \\n[#SSH_COLOR]=1 \{ .COLOR \\*[$SSH_COLOR] \}
-.       ie \\n[#PP_SPACE]=0 \{\
-.          while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.             ie \\n[#NUMBER_SH] \{\
-.                ie \\n[#ARG_NUM]=0 \{\
-.                   ie \\n[#PREFIX_CH_NUM]=1 \{\
-.                      ds $CH_NUM \\n[#CH_NUM].
+.                UNDERSCORE \\*[$HEAD_\\n[#LEVEL]_UL_GAP] \
+                   "\\*[$HD_NUM]\\$[\\n[#ARG_NUM]]
+.                sp -1v
 .                   \}
-.                   el \{\
-.                      rm $CH_NUM
 .                   \}
-.                   ie \\n[#NUMBER_HEAD] \{\
-.                      br
-.                      PRINT 
"\v'-\\n[#SSH_BASELINE_ADJ]u'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n[#SH_NUM].\\n+[#SSH_NUM].\0\\$[\\n+[#ARG_NUM]]
-.                      br
+.          nr #UNDERSCORE_WEIGHT \\n[#SAVED_UL_WEIGHT]
 .                   \}
-.                   el \{\
-.                      br
-.                      PRINT 
"\v'-\\n[#SSH_BASELINE_ADJ]u'\\*[$CH_NUM]\\n+[#SSH_NUM].\0\\$[\\n+[#ARG_NUM]]
+.       if \\n[#HEAD_\\n[#LEVEL]_UNDERSCORE2] \{\
+.          nr #SAVED_UL2_WEIGHT \\n[#UNDERSCORE_WEIGHT]
+.          UNDERSCORE_WEIGHT \\*[$HEAD_\\n[#LEVEL]_UL2_WEIGHT]
+.          ie \\n[#HD_NUM_INDENT] \{\
+.             if !'\\*[$HEAD_\\n[#LEVEL]_QUAD]'CENTER' \
+.                ti \\n[#HD_NUM_INDENT]u 
+.             UNDERSCORE2 \\*[$HEAD_\\n[#LEVEL]_UL2_GAP_1] \
+                \\*[$HEAD_\\n[#LEVEL]_UL2_GAP_2] \
+                "\v'-\\*[$HEAD_\\n[#LEVEL]_BASELINE_ADJ]'\\$[\\n[#ARG_NUM]]
 .                      br
 .                   \}
-.                \}
 .                el \{\
-.                   br
-.                   PRINT "\v'-\\n[#SSH_BASELINE_ADJ]u'\\$[\\n+[#ARG_NUM]]
+.             ie !\\n[#PARAHEAD] \{\
+.                UNDERSCORE2 \\*[$HEAD_\\n[#LEVEL]_UL2_GAP_1] \
+                   \\*[$HEAD_\\n[#LEVEL]_UL2_GAP_2] \
+"\v'-\\*[$HEAD_\\n[#LEVEL]_BASELINE_ADJ]'\\*[$HD_NUM]\\$[\\n[#ARG_NUM]]
 .                   br
 .                \}
-.             \}
 .             el \{\
-.                br
-.                PRINT "\v'-\\n[#SSH_BASELINE_ADJ]u'\\$[\\n+[#ARG_NUM]]
-.                br
-.             \}
-.\}
+.                if (\\n[#PP]>0):(\\n[#INDENT_FIRST_PARAS]) \{\
+.                   if !\\n[#LB_4_HD] \{\
+.                      if !\\n[#START] \{\
+.                         if \\n[#PP_ACTIVE] \{\
+.                            nr #PP_TEXT_OFFSET +\\n[#PP_INDENT]
+.                            if (\\n[#PRINT_STYLE]=1)&(\\n[#SINGLE_SPACE]=1) \
+.                               sp -1v
+.                            ti \\n[#PP_INDENT]u
 .       \}
-.       el \{\
-.          ALD \\n[#DOC_LEAD]u
-.          if \\n[#HEAD]=1      \{ .RLD \\n[#DOC_LEAD]u \}
-.          if \\n[#END_QUOTE]   \{ .RLD \\n[#DOC_LEAD]u \}
-.          if \\n[#EPIGRAPH]    \{ .RLD \\n[#DOC_LEAD]u \}
-.          while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\
-.             ie \\n[#NUMBER_SH] \{\
-.                ie \\n[#ARG_NUM]=0 \{\
-.                   ie \\n[#PREFIX_CH_NUM]=1 \{\
-.                      ds $CH_NUM \\n[#CH_NUM].
 .                   \}
-.                   el \{\
-.                      rm $CH_NUM
 .                   \}
-.                   ie \\n[#NUMBER_HEAD] \{\
-.                      br
-.                      PRINT 
"\v'-\\n[#SSH_LEAD_ADJUST]u'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n[#SH_NUM].\\n+[#SSH_NUM]\0\\$[\\n+[#ARG_NUM]]
-.                      br
 .                   \}
-.                   el \{\
-.                      br
-.                      PRINT 
"\v'-\\n[#SSH_LEAD_ADJUST]u'\\*[$CH_NUM]\\n+[#SSH_NUM].\0\\$[\\n+[#ARG_NUM]]
-.                      br
+.                UNDERSCORE2 \\*[$HEAD_\\n[#LEVEL]_UL2_GAP_1] \
+\\*[$HEAD_\\n[#LEVEL]_UL2_GAP_2] "\\*[$HD_NUM]\\$[\\n[#ARG_NUM]]
+.                sp -1v
 .                   \}
 .                \}
-.                el \{\
-.                   br
-.                   PRINT "\v'-\\n[#SSH_LEAD_ADJUST]u'\\$[\\n+[#ARG_NUM]]
-.                   br
+.          nr #UNDERSCORE_WEIGHT \\n[#SAVED_UL2_WEIGHT]
 .                \}
+.       if !\\n[#HD_NUM_INDENT] .nr #HD_NUM_INDENT \w'\\*[$HD_NUM]'
 .             \}
-.             el \{\
-.                br
-.                PRINT "\v'-\\n[#SSH_LEAD_ADJUST]u'\\$[\\n+[#ARG_NUM]]
-.                br
+.    if !\\n[#PARAHEAD] \{\
+.       if \\n[#HEAD_\\n[#LEVEL]_SPACE_AFTER] .sp
 .             \}
-.\}
-.          ALD \\n[#DOC_LEAD]u
+.    if \\n[#CAPS_OFF] \{\
+.       CAPS OFF
+.       rr #CAPS_OFF
 .       \}
+.    if \\n[#CAPS_RESTORE] \{\
+.       CAPS
+.       rr #CAPS_RESTORE
 .    \}
-.    REMOVE_INDENT
 .    ev
-.    if \\n[#NUMBER_SH] \{ .RESET_PARAHEAD_NUMBER \}
-.    if r#START     \{ .rr #START     \}
-.    if r#EPIGRAPH  \{ .rr #EPIGRAPH  \}
-.    if r#Q_FITS    \{ .rr #Q_FITS    \}
-.    if r#END_QUOTE \{ .rr #END_QUOTE \}
-.    if r#LINEBREAK \{ .rr #LINEBREAK \}
-.    rm $TOC_SSH_ITEM
-.    nr #PP 0
-.    nr #HEAD 2
-.END
-\#
-\# ---Paragraph heads---
-\#
-\# PARAHEAD INDENT
-\# ---------------
-\# *Argument:
-\#   <size of indent>
-\# *Function:
-\#   Creates or modifies register #PH_INDENT.
-\# *Notes:
-\#   Default is 1/2 #PP_INDENT for TYPESET and TYPEWRITE.
-\#
-.MAC PARAHEAD_INDENT END
-.    nr #PH_INDENT (\\$1)
-.END
-\#
-\# PARAHEAD SPACE
-\# --------------
-\# *Argument:
-\#   <amount of horizontal space between parahead and paragraph text>
-\# *Function:
-\#   Creates or modifies string $PH_SPACE.
-\# *Notes:
-\#   Default is .6m for TYPESET and \0 (1 digit space) for TYPEWRITE.
-\#
-.MAC PARAHEAD_SPACE END
-.    ds $PH_SPACE \\$1
+.    rm $HD_NUM
+.    rr #HD_NUM_INDENT
+.    if \\n[#PARAHEAD]   .ti \\n[#PP_TEXT_OFFSET]u
+.    if !\\n[#PARAHEAD]  .nr #PP 0
+.    rr #PARAHEAD
+.    if \\n[#LB_4_HD]    .rr #LB_4_HD
+.    if \\n[#QUOTE_4_HD] .rr #QUOTE_4_HD
+.    if address@hidden \{\
+.       ch address@hidden
+.       wh \\n[nl]u+1u address@hidden
+.       ns
+.    \}
+.    vpt
 .END
 \#
-\#
-\# PARAHEAD
-\# --------
+\# HEADING_STYLE
+\# -------------
 \# *Arguments:
-\#   "<para head>"
-\# *Function:
-\#   Deposits a paragraph head at the start and into the body of a
-\#   paragraph.
-\# *Notes:
-\#   PARAHEAD *must* come after PP.
-\#
-.MAC PARAHEAD END
-.    if \\n[#UNDERLINE_ON]=1 .UNDERLINE OFF
-.    if \\n[#LINENUMBERS] .nm
-.\" Collect parahead for TOC.
-.    nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ]
-.    ie \\n[#NUMBER_PH] \{\
-.       ds $TOC_PH_ITEM \\n+[#PH_NUM].\0\\$1\\|
-.       nr #PH_NUM \\n-[#PH_NUM]
+\#   <level>
+\#   FAMILY <family>
+\#   FONT   <font>
+\#   SIZE   <+|-n>
+\#   COLOR  <color>
+\#   CAPS | NO_CAPS
+\#---when called as HEADING_STYLE, these are also available---
+\#   QUAD   <direction>
+\#   NUMBER | NO_NUMBER
+\#   SPACE_AFTER | NO_SPACE_AFTER
+\#   UNDERSCORE <weight> <gap> | UNDERSCORE2 <weight> <gap1> <gap2> 
+\#   NO_UNDERSCORE | NO_UNDERSCORE2
+\#   BASELINE_ADJUST
+\#---when called as TOC_ENTRY_STYLE this is also available---
+\#   INDENT
+\# *Function:
+\#   Sets up complete style parameters for HEADING <level>.  If
+\#   invoked as TOC_ENTRY_STYLE, sets up parameters for the
+\#   corresponding TOC entry at <level>.
+\# *Notes:
+\#   Arguments may be given in any order.  Any not given retain
+\#   their current values.  Defaults for an initial 9 levels of
+\#   heading are set up in PRINTSTYLE.
+\#
+\#   NUMBER indicates that hierarchic numbering of <level> should be
+\#   prepended to heading text.  If invoked as TOC_ENTRY_STYLE,
+\#   prepend numbering to TOC entries at <level> (only works if
+\#   NUMBER is given to the corresponding HEADING <level>).
+\#
+\#   INDENT refers to the indent for <level> in the TOC.  It is
+\#   measured from the left offset of the entry level above it
+\#   (including numbering, if present).  TOC entry levels beneath
+\#   <level> will have their indents adjusted accordingly.
+\#
+.MAC HEADING_STYLE END
+.    if !\B'\\$1' \{\
+.       tm1 "[mom]: The first argument to \\$0 must be a numeric heading level.
+.       ab Aborting \\n[.F] at \\$0, line \\n[.c].
 .    \}
-.    el \{\
-.       ds $TOC_PH_ITEM \\$1\\|
+.    nr #LEVEL \\$1
+.    if \\n[#FROM_OLDSTYLE] .nr #LEVEL_\\n[#LEVEL]_SET 1
+.    shift
+.\" Prepend TOC_ to style strings if called as TOC_ENTRY_STYLE
+.    if '\\$0'TOC_ENTRY_STYLE' .ds $TOC TOC_
+.    nr #ARG_NUM 0 1
+.    nr #ATTRIB \\n[#NUM_ARGS]
+.    while \\n+[#ARG_NUM]<=\\n[#ATTRIB] \{\
+.       if '\\$1'UNDERSCORE' \{\
+.          nr #HEAD_\\n[#LEVEL]_UNDERSCORE 1
+.          shift
+.          ds $HEAD_\\n[#LEVEL]_UL_WEIGHT \\$1
+.          shift
+.          ds $HEAD_\\n[#LEVEL]_UL_GAP    \\$1
+.          shift
 .    \}
-.    ev TOC_EV
-.    da TOC_ENTRIES
-.    if \\n[#PRINT_STYLE]=1 \{\
-\!.       fam \\*[$TYPEWRITER_FAM]
-\!.       ft  R
-\!.       ps  \\*[$TYPEWRITER_PS]
+.       if '\\$1'NO_UNDERSCORE' \{\
+.          rr #HEAD_\\n[#LEVEL]_UNDERSCORE
+.          shift
 .    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_PH_FAM]
-\!.     FT      \\*[$TOC_PH_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PH_SIZE_CHANGE]
+.       if '\\$1'UNDERSCORE2' \{\
+.          nr #HEAD_\\n[#LEVEL]_UNDERSCORE2 1
+.          shift
+.          ds $HEAD_\\n[#LEVEL]_UL2_WEIGHT \\$1
+.          shift
+.          ds $HEAD_\\n[#LEVEL]_UL2_GAP_1  \\$1
+.          shift
+.          ds $HEAD_\\n[#LEVEL]_UL2_GAP_2  \\$1
+.          shift
 .    \}
-\!.  TRAP OFF
-\!.  PAD_MARKER ^
-.    ie \\n[#PRINT_STYLE]=1 \{\
-\!.     PAD "\\h'\w'\0\0.'u*4u'\\*[$TOC_PH_ITEM]\\*[$TOC_PN_TYPEWRITE]"
+.       if '\\$1'NO_UNDERSCORE2' \{\
+.          rr #HEAD_\\n[#LEVEL]_UNDERSCORE2
 .    \}
-.    el \{\
-\!.     PAD "\\h'\\n[#TOC_PH_INDENT]u'\\*[$TOC_PH_ITEM]\\*[$TOC_PN]"
+.       if '\\$1'SPACE_AFTER' \{\
+.          nr #HEAD_\\n[#LEVEL]_SPACE_AFTER 1
+.          shift
 .    \}
-\!.  PAD_MARKER #
-\!.  EOL
-\!.  ST 100 L
-\!.  ST 101 R
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_PN_FAM]
-\!.     FT      \\*[$TOC_PN_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
+.       if '\\$1'NO_SPACE_AFTER' \{\
+.          rr #HEAD_\\n[#LEVEL]_SPACE_AFTER
+.          shift
 .    \}
-\!.  TAB 100
-\!.  PRINT \\*[LEADER]
-\!.  TN
-\!.  TRAP
-\!.  PRINT \\n[#TOC_ENTRY_PN]
-\!.  TQ
-.    di
-.    ev
-.\" End collection of parahead for TOC
-.\" Process parahead
-.    if \\n[#SLANT_ON] \{\
-.       nr #SLANT_WAS_ON 1
-\E*[SLANTX]
+.       if '\\$1'FAMILY' \{\
+.          shift
+.          ds $\\*[$TOC]HEAD_\\n[#LEVEL]_FAM  \\$1
+.          shift
 .    \}
-.    vpt 0
-.    sp -1v
-.    ie \\n[#PP]=1 \{\
-.       if \\n[#INDENT_FIRST_PARAS] \{\
-.          ti \\n[#PH_INDENT]u
+.       if '\\$1'FONT' \{\
+.          shift
+.          ds $\\*[$TOC]HEAD_\\n[#LEVEL]_FT   \\$1
+.          shift
 .       \}
+.       if '\\$1'SIZE' \{\
+.          shift
+.          ds $\\*[$TOC]HEAD_\\n[#LEVEL]_SIZE \\$1
+.          shift
 .    \}
-.    el \{\
-.       ti \\n[#PH_INDENT]u
+.       if '\\$1'QUAD' \{\
+.          shift
+.          if '\\$1'L'      .ds $HEAD_\\n[#LEVEL]_QUAD LEFT
+.          if '\\$1'LEFT'   .ds $HEAD_\\n[#LEVEL]_QUAD LEFT
+.          if '\\$1'C'      .ds $HEAD_\\n[#LEVEL]_QUAD CENTER
+.          if '\\$1'CENTRE' .ds $HEAD_\\n[#LEVEL]_QUAD CENTER
+.          if '\\$1'CENTER' .ds $HEAD_\\n[#LEVEL]_QUAD CENTER
+.          if '\\$1'R'      .ds $HEAD_\\n[#LEVEL]_QUAD RIGHT
+.          if '\\$1'RIGHT'  .ds $HEAD_\\n[#LEVEL]_QUAD RIGHT
+.          shift
 .    \}
-.       vpt
-.    ie \\n[#PREFIX_CH_NUM]=1 \{\
-.       ds $CH_NUM \\n[#CH_NUM].
+.       if '\\$1'COLOR' \{\
+.          shift
+.          ds $\\*[$TOC]HEAD_\\n[#LEVEL]_COLOR \\$1
+.          shift
 .    \}
-.    el \{\
-.       rm $CH_NUM
+.       if '\\$1'BASELINE_ADJUST' \{\
+.          shift
+.          ds $HEAD_\\n[#LEVEL]_BASELINE_ADJ \\$1
+.          shift
 .    \}
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       TYPEWRITER
-.       ie \\n[#NUMBER_PH] \{\
-.          if \\n[#NUMBER_HEAD] \{\
-.             ie \\n[#NUMBER_SH] \{\
-.                UNDERSCORE "\R'#NUMBERED 
1'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n[#SH_NUM].\\n[#SSH_NUM].\\n+[#PH_NUM].\\ \\$1"
-\0
+.       if '\\$1'CAPS' \{\
+.          nr #\\*[$TOC]HEAD_\\n[#LEVEL]_CAPS 1
+.          shift
 .             \}
-.             el \{\
-.                UNDERSCORE "\R'#NUMBERED 
1'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n+[#PH_NUM].\\ \\$1"
-\0
+.       if '\\$1'NO_CAPS' \{\
+.          rr #HEAD_\\n[#LEVEL]_CAPS
+.          shift
 .             \}
+.       if '\\$1'NUMBER' \{\
+.          nr #NUMBER_HEAD_\\n[#LEVEL] 1
+.          nr #HEAD_\\n[#LEVEL]_NUM 0 1
+.          shift
 .          \}
-.          ie \\n[#NUMBER_SH] \{\
-.             if !\\n[#NUMBERED] \{\
-.                UNDERSCORE "\\*[$CH_NUM]\\n[#SH_NUM].\\n+[#PH_NUM].\\ \\$1"
-\0
+.       if '\\$1'NO_NUMBER' \{\
+.          rr #NUMBER_HEAD_\\n[#LEVEL]
+.          shift
 .             \}
+.       if '\\$1'INDENT' \{\
+.          shift
+.          nr #TOC_HEAD_\\n[#LEVEL]_INDENT \\$1
+.          nr #FROM_STYLE_\\n[#LEVEL] 1
+.          shift
 .          \}
-.          el \{\
-.             if !\\n[#NUMBERED] \{\
-.                UNDERSCORE "\\*[$CH_NUM]\\n+[#PH_NUM].\\ \\$1"
-\0
 .             \}
+.    rr #LEVEL
+.    if d$TOC .rm $TOC
+.END
+\#
+.ALIAS TOC_ENTRY_STYLE HEADING_STYLE
+\#
+\# OLDSTYLE HEADINGS
+\# -----------------
+\# *Arguments:
+\#   None.
+\# *Function:
+\#   Called from HEAD, SUBHEAD, and SUBSUBHEAD, sets style
+\#   parameters for HEADINGs 1-3 to former mom defaults for those macros.
+\#   Any styles already assigned to those levels are retained.
+\#
+\#   Called by user with no argument, allows use of old style HEAD,
+\#   SUBHEAD, and SUBSUBHEAD without generating the deprecated msg.
+\# *Notes:
+\#   For backward compatibility, and to ease the transition to
+\#   the HEADING scheme for heads.
+\#
+\#   Paraheads must be set with .HEADING <level> PARAHEAD; attempts
+\#   to call PARAHEAD abort with an instructive message.
+\#
+.MAC OLDSTYLE_HEADINGS END
+.    if '\\$1'' .nr #SKIP_MSG 1
+.    nr #FROM_OLDSTYLE 1 \" Used in HEADING
+.    if \\n[#PRINT_STYLE]=1 \{\
+.       if !\\n[#LEVEL_1_SET] \{\
+.          HEADING_STYLE 1 \
+             FONT R \
+             SIZE +0 \
+             QUAD C \
+             CAPS \
+             UNDERSCORE .5 2p \
+             BASELINE_ADJUST 0 \
+             SPACE_AFTER
+.            nr #OLDSTYLE_HD 1
+.            return
 .          \}
+.       if !\\n[#LEVEL_2_SET] \{\
+.          HEADING_STYLE 2 \
+             FONT R \
+             SIZE +0 \
+             UNDERSCORE .5 2p \
+             BASELINE_ADJUST \\n[.v]/8
+.            nr #OLDSTYLE_SH 1
+.            return
 .       \}
-.       el \{\
-.          UNDERSCORE "\\$1"
-\0
+.       if !\\n[#LEVEL_3_SET] \{\
+.          HEADING_STYLE 3 \
+             FONT R \
+             SIZE +0 \
+             BASELINE_ADJUST \\n[.v]/8
+.            nr #OLDSTYLE_SSH 1
+.            return
 .       \}
-.       if \\n[#SLANT_WAS_ON] \{\
-.          if \\n[#UNDERLINE_SLANT] \{ .UNDERLINE \}
-.          if \\n[#SLANT_MEANS_SLANT] \{\
-\E*[SLANT]\c
 .          \}
-.          rr #SLANT_WAS_ON
+.    if \\n[#PRINT_STYLE]=2 \{\
+.       if !\\n[#LEVEL_1_SET] \{\
+.          HEADING_STYLE 1 \
+             FAMILY \E*[$DOC_FAM] \
+             FONT B \
+             SIZE +1 \
+             QUAD C \
+             CAPS \
+             UNDERSCORE .5 2p \
+             BASELINE_ADJUST 0 \
+             SPACE_AFTER
+.            nr #OLDSTYLE_HD 1
+.            return
 .       \}
+.       if !\\n[#LEVEL_2_SET] \{\
+.          HEADING_STYLE 2 \
+             FAMILY \E*[$DOC_FAM] \
+             FONT B \
+             SIZE +.5 \
+             BASELINE_ADJUST \\n[.v]/8
+.            nr #OLDSTYLE_SH 1
+.            return
 .    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       FAM     \\*[$PH_FAM]
-.       FT      \\*[$PH_FT]
-.       PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$PH_SIZE_CHANGE]
-.       if \\n[#PH_COLOR]=1 \{ .COLOR \\*[$PH_COLOR] \}
-.          ie \\n[#NUMBER_PH] \{\
-.             ie \\n[#PREFIX_CH_NUM]=1 \{\
-.                ds $CH_NUM \\n[#CH_NUM].
+.       if !\\n[#LEVEL_3_SET] \{\
+.          HEADING_STYLE 3 \
+             FAMILY \E*[$DOC_FAM] \
+             FONT I \
+             SIZE +.5 \
+             BASELINE_ADJUST \\n[.v]/8
+.            nr #OLDSTYLE_SSH 1
+.            return
 .             \}
-.             el \{\
-.                rm $CH_NUM
 .             \}
-.             if \\n[#NUMBER_HEAD] \{\
-.                ie \\n[#NUMBER_SH] \{\
-.                   PRINT "\R'#NUMBERED 
1'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n[#SH_NUM].\\n[#SSH_NUM].\\n+[#PH_NUM].\0\\$1\h'\\*[$PH_SPACE]'\c"
+.    rr #FROM_OLDSTYLE
+.END
+\#
+\# "Deprecated" message
+\#
+.MAC DEPRECATED END
+.    if !\\n[#SKIP_MSG] \{\
+.       tm1 "[mom]: Macro '\\$1' at line \\n[.c] is deprecated.
+.       tm1 "       Invoking HEADING \\$2 instead and assigning style defaults
+.       tm1 "          from former \\$1 as described in the documentation.
+.       tm1 "       If another style is desired, use HEADING_STYLE \\$2 to
+.       tm1 "          create it (see docs).
+.       tm1 "       Further warnings will not be emitted for \\$1.
+.       tm1 "       To avoid this message when using the deprecated HEAD,
+.       tm1 "          SUBHEAD, and SUBSUBHEAD macros, add '.OLDSTYLE_HEADINGS'
+.       tm1 "          after PRINTSTYLE before START.
+.       rm $MACRO
 .                \}
-.                el \{\
-.                   PRINT "\R'#NUMBERED 
1'\\*[$CH_NUM]\\n[#HEAD_NUM].\\n+[#PH_NUM].\0\\$1\h'\\*[$PH_SPACE]'\c"
+.END
+\#
+\# Wrappers around old-style headings.
+\#
+.MAC HEAD END
+.    if !\\n[#OLDSTYLE_HD] \{\
+.       DEPRECATED HEAD 1
+.       OLDSTYLE_HEADINGS HEAD
+.    \}
+.    HEADING 1 \\$@
+.END
+\#
+.MAC SUBHEAD END
+.    if !\\n[#OLDSTYLE_SH] \{\
+.       DEPRECATED SUBHEAD 2
+.       OLDSTYLE_HEADINGS SUBHEAD
+.    \}
+.     HEADING 2 \\$@
+.END
+\#
+.MAC SUBSUBHEAD END
+.    if !\\n[#OLDSTYLE_SSH] \{\
+.       DEPRECATED SUBSUBHEAD 3
+.       OLDSTYLE_HEADINGS SUBSUBHEAD
 .                \}
+.    HEADING 3 \\$@
+.END
+\#
+.MAC PARAHEAD END
+.    tm1 "[mom]: \\$0 is no longer a valid macro.
+.    tm1 "       Use 'HEADING <level> PARAHEAD <text>' instead.
+.    tm1 "       You will probably want to invoke HEADING_STYLE to set
+.    tm1 "       the type parameters for the parahead.  See docs.
+.    ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
+.END
+\#
+\# Wrapper macro for oldstyle NUMBER_HEADS, NUMBER_SUBHEADS...
+\#
+.MAC HEADING_NUMBERS END
+.    if '\\$0'NUMBER_PARAHEADS' \{\
+.       tm1 "[mom]: \\$0 is no longer a valid macro.
+.       tm1 "       Use 'HEADING_STYLE <level> NUMBER' instead.  See docs.
+.       ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
+.       return
 .             \}
-.             ie \\n[#NUMBER_SH] \{\
-.                if !\\n[#NUMBERED] \{\
-.                   PRINT 
"\\*[$CH_NUM]\\n[#SH_NUM].\\n+[#PH_NUM].\0\\$1\h'\\*[$PH_SPACE]'\c"
+.    if '\\$0'NUMBER_HEADS'       .nr level 1
+.    if '\\$0'NUMBER_SUBHEADS'    .nr level 2
+.    if '\\$0'NUMBER_SUBSUBHEADS' .nr level 3
+.    ds mom "[mom]:\"
+.    ie '\\$1'' .ds $PARAM NUMBER
+.    el \{\
+.       ds $PARAM NO_NUMBER
+.       ds $SWITCH " \\$1
+.    \}
+.    HEADING_STYLE \\n[level] \\*[$PARAM]
+.    if (\\n[#OLDSTYLE_HD]=1):(\\n[#OLDSTYLE_SH]=1):(\\n[#OLDSTYLE_SSH]=1) \{\
+.       tm1 "\\*[mom] OLDSTYLE_HEADINGS detected.
+.       ds mom "      \"
+.    \}
+.    tm1 "\\*[mom] Setting HEADING_STYLE \\n[level] to '\\*[$PARAM]' at 
'\\$0\\*[$SWITCH]', line \\n[.c].
+.    rm $PARAM
+.    rm $SWITCH
+.END
+\#
+.ALIAS NUMBER_HEADS       HEADING_NUMBERS
+.ALIAS NUMBER_SUBHEADS    HEADING_NUMBERS
+.ALIAS NUMBER_SUBSUBHEADS HEADING_NUMBERS
+.ALIAS NUMBER_PARAHEADS   HEADING_NUMBERS
+\#
+\# PREFIX CHAPTER NUMBERS TO HEADINGS/TOC ENTRIES
+\# ----------------------------------------------------------------
+\# *Arguments:
+\#   <none> | <chapter number> | <anything>
+\# *Function:
+\#   Toggles register #PREFIX_CH_NUM. Sets register #CH_NUM from
+\#   string $CHAPTER if $CHAPTER is a digit; if <chapter number> arg
+\#   given, sets #CH_NUM to arg.
+\# *Notes:
+\#   Default is OFF.
+\#
+.MAC PREFIX_CHAPTER_NUMBER END
+.    ie '\\$1'' \{\
+.       ie r#CH_NUM \{\
+.          nr #PREFIX_CH_NUM 1
+.          if \\n[#CHAPTER_CALLED] \{\
+.             ie \B'\\*[$CHAPTER]' .nr #CH_NUM \\*[$CHAPTER]
+.             el .PREFIX_CH_NUM_WARNING
+.             rr #CHAPTER_CALLED
 .                \}
 .             \}
 .             el \{\
-.                if !\\n[#NUMBERED] \{\
-.                   PRINT 
"\\*[$CH_NUM]\\n+[#PH_NUM].\0\\$1\h'\\*[$PH_SPACE]'\c"
+.          ie \B'\\*[$CHAPTER]' \{\
+.             nr #PREFIX_CH_NUM 1
+.             nr #CH_NUM \\*[$CHAPTER]
 .                \}
+.          el .PREFIX_CH_NUM_WARNING
 .             \}
 .          \}
 .          el \{\
-.             PRINT "\\$1\h'\\*[$PH_SPACE]'\c"
-.          \}
+.       ie \B'\\$1' \{\
+.          nr #CH_NUM \\$1
+.          nr #PREFIX_CH_NUM 1
 .       \}
-.    FAMILY  \\*[$DOC_FAM]
-.    FT      \\*[$PP_FT]
-.    PT_SIZE \\n[#DOC_PT_SIZE]u
-.    if \\n[#PH_COLOR]=1 \m[]\c
-.    if \\n[#SLANT_WAS_ON] \{\
-.       rr #SLANT_WAS_ON
-\E*[SLANT]\c
+.       el .rr #PREFIX_CH_NUM
 .    \}
-.    rr #NUMBERED
-.    rm $TOC_PH_ITEM
-.    if \\n[#LINENUMBERS] .nm +0
 .END
 \#
+.MAC PREFIX_CH_NUM_WARNING END
+.    tm1 "[mom]: PREFIX_CHAPTER_NUMBER cannot determine a chapter number.
+.    tm1 "       Please enter the current chapter number as a digit after
+.    tm1 "       PREFIX_CHAPTER_NUMBER.
+.    ab Aborting '\\n[.F]' at PREFIX_CHAPTER_NUMBER, line \\n[.c].
+.END
 \#
 \# ====================================================================
 \#
@@ -11445,17 +10545,14 @@
 .    nr #REPEAT 1
 .    ds $LINEBREAK_CHAR \\$1
 .    ds $LINEBREAK_CHAR_V_ADJ \\$3
-.    if '\\*[$LINEBREAK_CHAR_V_ADJ]'' \{\
-.       ds $LINEBREAK_CHAR_V_ADJ +0
-.    \}
+.    if '\\*[$LINEBREAK_CHAR_V_ADJ]'' .ds $LINEBREAK_CHAR_V_ADJ +0
 .    while \\$2>\\n[#REPEAT] \{\
 .       as $LINEBREAK_CHAR "\\ \\$1
 .       nr #REPEAT \\n[#REPEAT]+1
-.\}
+.   \}
 .   rr #REPEAT
 .END
 \#
-\#
 \# LINE BREAK
 \# ----------
 \# *Arguments:
@@ -11466,31 +10563,35 @@
 \#   If $LINEBREAK_CHAR is blank, simply advances 2 line spaces.
 \#
 .MAC LINEBREAK END
-.    if r#Q_AT_TOP \{ .rr #Q_AT_TOP \}
+.    if r #Q_AT_TOP .rr #Q_AT_TOP
 .    po \\n[#DOC_L_MARGIN]u
-.    ie  '\\*[$LINEBREAK_CHAR]'' \{ .ALD \\n[#DOC_LEAD]u*2 \}
+.    ie  '\\*[$LINEBREAK_CHAR]'' .ALD \\n[#DOC_LEAD]u*2
 .    el \{\
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          ie \\n[#END_QUOTE] \{ . \}
-.          el \{ .ALD \\n[#DOC_LEAD]u \}
+.          ie \\n[#END_QUOTE] .
+.          el .ALD \\n[#DOC_LEAD]u
 .       \}
 .       if \\n[#PRINT_STYLE]=2 \{\
-.          ie \\n[#END_QUOTE] \{ . \}
-.          el \{ .ALD \\n[#DOC_LEAD]u \}
+.          ie \\n[#END_QUOTE] .
+.          el .ALD \\n[#DOC_LEAD]u
 .       \}
 .       ev LINEBREAK
 .       evc 0
 .       CENTER
-.       PRINT 
\m[\\*[$LINEBREAK_COLOR]]\\v'\\*[$LINEBREAK_CHAR_V_ADJ]'\\*[$LINEBREAK_CHAR]\\v'\\*[$LINEBREAK_CHAR_V_ADJ]'\m[]
-.       if \\n[#PRINT_STYLE]=1 \{ .ALD \\n[#DOC_LEAD]u \}
-.       if \\n[#PRINT_STYLE]=2 \{ .ALD \\n[#DOC_LEAD]u \}
+.       PRINT \
+\m[\\*[$LINEBREAK_COLOR]]\\v'\\*[$LINEBREAK_CHAR_V_ADJ]'\
+\\*[$LINEBREAK_CHAR]\\v'\\*[$LINEBREAK_CHAR_V_ADJ]'\m[]
+.       if \\n[#PRINT_STYLE]=1 .ALD \\n[#DOC_LEAD]u
+.       if \\n[#PRINT_STYLE]=2 .ALD \\n[#DOC_LEAD]u
 .       ev
 .       QUAD \\*[$DOC_QUAD]
 .    \}
 .    nr #LINEBREAK 1
-.    if r#QUOTE     \{ .rr #QUOTE     \}
-.    if r#END_QUOTE \{ .rr #END_QUOTE \}
+.    if r #QUOTE .rr #QUOTE
+.    if r #END_QUOTE .rr #END_QUOTE
 .    nr #PP 0
+.    nr #LB_4_HD       1
+.    nr #LB_4_PARAHEAD 1
 .END
 \#
 \# ====================================================================
@@ -11508,17 +10609,16 @@
 \#
 .MAC PP_FONT END
 .    if \\n[#PRINT_STYLE]=1 \{\
-.       ie \\n[#ITALIC_MEANS_ITALIC] \{ .nop \}
-.       el \{ .return \}
+.       ie \\n[#ITALIC_MEANS_ITALIC] .nop
+.       el .return
 .    \}
 .    if \\n[#COLLATE]=1 \{\
-.       if !'\\*[$SAVED_PP_FT]'' \{ .rm $SAVED_PP_FT \}
+.       if !'\\*[$SAVED_PP_FT]'' .rm $SAVED_PP_FT
 .    \}
 .    ds $PP_FT \\$1
 .    FT \\*[$PP_FT]
 .END
 \#
-\#
 \# PARAGRAPH INDENT
 \# ----------------
 \# *Argument:
@@ -11532,10 +10632,22 @@
 \#   PRINTSTYLE, not DEFAULTS.
 \#
 .MAC PARA_INDENT END
+.    ie \B'\\$1' \{\
 .    nr #PP_INDENT (\\$1)
+.       nr #SAVED_PP_INDENT \\n[#PP_INDENT]
+.    \}
+.    el \{\
+.       ie '\\$1'' \{\
+.          nr #PP_INDENT \\n[#SAVED_PP_INDENT]
+.          rr #SAVED_PP_INDENT
+.       \}
+.       el \{\
+.          nr #SAVED_PP_INDENT \\n[#PP_INDENT]
+.          rr #PP_INDENT
+.       \}
+.    \}
 .END
 \#
-\#
 \# INDENT FIRST PARAGRAPHS
 \# -----------------------
 \# *Arguments:
@@ -11548,11 +10660,10 @@
 \#   Default is OFF.
 \#
 .MAC INDENT_FIRST_PARAS END
-.    ie '\\$1'' \{ .nr #INDENT_FIRST_PARAS 1 \}
-.    el \{ .rr #INDENT_FIRST_PARAS   \}
+.    ie '\\$1'' .nr #INDENT_FIRST_PARAS 1
+.    el .rr #INDENT_FIRST_PARAS
 .END
 \#
-\#
 \# INTER-PARAGRAPH SPACING
 \# -----------------------
 \# *Arguments:
@@ -11561,15 +10672,14 @@
 \#   Adds a line space between paragraphs in body text.  Block quotes
 \#   are unaffected.
 \# *Notes:
-\#   Default is OFF.  PARA_SPACE ON is not recommended for use
-\#   with PRINTSTYLE TYPEWRITE.
+\#   Default is OFF.  PARA_SPACE is not recommended for use with
+\#   PRINTSTYLE TYPEWRITE without SINGLESPACE.
 \#
 .MAC PARA_SPACE END
-.    ie '\\$1'' \{ .nr #PP_SPACE 1 \}
-.    el \{ .rr #PP_SPACE   \}
+.    ie '\\$1'' .nr #PP_SPACE 1
+.    el .rr #PP_SPACE
 .END
 \#
-\#
 \# PARAGRAPH
 \# ---------
 \# *Arguments:
@@ -11577,12 +10687,6 @@
 \# *Function:
 \#   Figures out what to do with paragraphs under differing conditions.
 \# *Notes:
-\#   For the time being, there's no automatic widow/orphan control.
-\#   Controlling them isn't just a matter of establishing an arbitrary
-\#   number of lines needed for a para, since groff doesn't then
-\#   handle single line paragraphs gracefully.  Usually, the whole
-\#   page needs to be tweaked.
-\#
 \#   Note the use of transparent line break (\!.br) to get
 \#   PP to work within blockquotes and epigraphs.
 \#
@@ -11591,7 +10695,7 @@
 .MAC PP END
 .    br
 .    if \\n[#DOC_TYPE]=4 \{\
-.       if !'\\n(.z'' \{ .di \}
+.       if !'\\n[.z]'' .di
 .       nr #TOTAL_FIELDS \\n[#FIELD]
 .       nr #FIELD        0 1
 .       nr #NUM_FIELDS   0 1
@@ -11601,42 +10705,42 @@
 .             LETTERHEAD\\n+[#FIELD]
 .             QUAD \\*[$DOC_QUAD]
 .             ALD \\n[#DOC_LEAD]u
-.             if \\n[#DATE_FIRST]=1 \{ .ALD \\n[#DOC_LEAD]u \}
+.             if \\n[#DATE_FIRST]=1 .ALD \\n[#DOC_LEAD]u
 .             rr #DATE_FIRST
 .             rm LETTERHEAD\\n[#FIELD]
-.\}
+.          \}
 .          rr #FIELD
 .          rr #NUM_FIELDS
 .          rr #TOTAL_FIELDS
 .       \}
 .    \}
 .    rr #PP_ACTIVE
-.    if r#Q_AT_TOP \{ .rr #Q_AT_TOP \}
+.    if r #Q_AT_TOP .rr #Q_AT_TOP
 .    if \\n[#PP_STYLE]=1 \{\
 .       if \\n[#ENDNOTE] \{\
 .          nr #RESET_PARA_SPACE \\n[#PP_SPACE]
-.          ie \\n[#EN_PP_SPACE] \{ .PARA_SPACE \}
-.          el \{ .PARA_SPACE OFF \}
+.          ie \\n[#EN_PP_SPACE] .PARA_SPACE
+.          el .PARA_SPACE OFF
 .       \}
 .       br
-.       if !\\n[#ENDNOTE] \{ .po \\n[#L_MARGIN]u \}
+.       if !\\n[#ENDNOTE] .po \\n[#L_MARGIN]u
 .       if \\n[#COLUMNS] \{\
 .          if !\\n[#ENDNOTE] \{\
 .             po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
-.             nr #L_MARGIN \\n(.o
+.             nr #L_MARGIN \\n[.o]
 .          \}
 .       \}
-.       if \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \}
+.       if \\n[#TAB_ACTIVE] .TAB \\n[#CURRENT_TAB]
 .       ie \\n[#PRINT_STYLE]=1 \{\
 .          TYPEWRITER
-.          ie \\n[#ENDNOTE] \{ .vs \\n[#EN_LEAD]u \}
-.          el \{ .vs \\n[#DOC_LEAD]u \}
+.          ie \\n[#ENDNOTE] .vs \\n[#EN_LEAD]u
+.          el .vs \\n[#DOC_LEAD]u
 .          QUAD \\*[$DOC_QUAD]
 .          if \\n[#SLANT_ON] \{\
-.             if \\n[#UNDERLINE_SLANT] \{ .UNDERLINE \}
+.             if \\n[#UNDERLINE_SLANT] .UNDERLINE
 .          \}
 .          if '\\*[$PP_FT]'I' \{\
-.             if \\n[#ITALIC_MEANS_ITALIC] \{ .FT I \}
+.             if \\n[#ITALIC_MEANS_ITALIC] .FT I
 .          \}
 .       \}
 .       el \{\
@@ -11661,62 +10765,57 @@
 .       \}
 .       ie \\n[#PP]=0 \{\
 .          if \\n[#INDENT_FIRST_PARAS] \{\
-.             ie \\n[#INDENT_ACTIVE] \{ .ti \\n[#INDENT]u+\\n[#PP_INDENT]u \}
-.             el \{ .ti \\n[#PP_INDENT]u \}
-.             if '\\n(.z'END_NOTES' \{\
+.             ie \\n[#INDENT_ACTIVE] .ti \\n[#INDENT]u+\\n[#PP_INDENT]u
+.             el .ti \\n[#PP_INDENT]u
+.             if '\\n[.z]'END_NOTES' \
 .                ti \\n[#EN_PP_INDENT]u+\\n[#EN_TEXT_INDENT]u
 .             \}
-.          \}
-.          if r#END_QUOTE \{\
+.          if r #END_QUOTE \{\
 .             if \\n[#END_QUOTE] \{\
 .                if !\\n[#LINEBREAK] \{\
-.                   ie \\n[#INDENT_ACTIVE] \{ .ti 
\\n[#INDENT]u+\\n[#PP_INDENT]u \}
-.                   el \{ .ti \\n[#PP_INDENT]u \}
-.                   if '\\n(.z'END_NOTES' \{\
+.                   ie \\n[#INDENT_ACTIVE] .ti \\n[#INDENT]u+\\n[#PP_INDENT]u
+.                   el .ti \\n[#PP_INDENT]u
+.                   if '\\n[.z]'END_NOTES' \
 .                      ti \\n[#EN_PP_INDENT]u+\\n[#EN_TEXT_INDENT]u
 .                   \}
 .                \}
 .             \}
 .          \}
-.       \}
 .       el \{\
 .          br
 .          if \\n[#PP_SPACE] \{\
-.             if \\n[#PRINT_STYLE]=2 \{\
 .                ie \\n[#END_QUOTE] \{\
 .                   ALD \\n[#DOC_LEAD]u
 .                   rr #END_QUOTE
 .                   nr #NO_SPACE 1
-.                   nr #BASELINE_MARK \\n(nl
+.                nr #BASELINE_MARK \\n[nl]
 .                \}
 .                el \{\
-.                   if \\n[#NO_SPACE]=1 \{\
-.                      rr #NO_SPACE
-.                   \}
-.                   if !\\n(nl=\\n[#BASELINE_MARK] \{\
+.                if \\n[#NO_SPACE]=1 .rr #NO_SPACE
+.                if !\\n[nl]=\\n[#BASELINE_MARK] \{\
 .                      ALD \\n[#DOC_LEAD]u
 .                      rr #BASELINE_MARK
 .                   \}
 .                \}
 .             \}
-.          \}
-.          ie \\n[#INDENT_ACTIVE] \{ .ti \\n[#INDENT]u+\\n[#PP_INDENT]u \}
-.          el \{ .ti \\n[#PP_INDENT]u \}
-.          if '\\n(.z'END_NOTES' \{\
+.          ie \\n[#INDENT_ACTIVE] .ti \\n[#INDENT]u+\\n[#PP_INDENT]u
+.          el .ti \\n[#PP_INDENT]u
+.          if '\\n[.z]'END_NOTES' \
 .             ti \\n[#EN_PP_INDENT]u+\\n[#EN_TEXT_INDENT]u
 .          \}
+.       if !\\n[#PP]=0 \{\
+.          if r #START  .rr #START
 .       \}
-.       if r#START     \{ .rr #START     \}
-.       if r#QUOTE     \{ .rr #QUOTE     \}
-.       if r#END_QUOTE \{ .rr #END_QUOTE \}
-.       if r#HEAD      \{ .rr #HEAD      \}
-.       if r#SUBHEAD   \{ .rr #SUBHEAD   \}
-.       if r#EPIGRAPH  \{ .rr #EPIGRAPH  \}
-.       if r#Q_FITS    \{ .rr #Q_FITS    \}
-.       if r#LINEBREAK \{ .rr #LINEBREAK \}
+.       if r #QUOTE     .rr #QUOTE
+.       if r #END_QUOTE .rr #END_QUOTE
+.       if r #HEAD      .rr #HEAD
+.       if r #SUBHEAD   .rr #SUBHEAD
+.       if r #EPIGRAPH  .rr #EPIGRAPH
+.       if r #Q_FITS    .rr #Q_FITS
+.       if r #LINEBREAK .rr #LINEBREAK
 .       if \\n[#ENDNOTE] \{\
-.          ie \\n[#RESET_PARA_SPACE] \{ .PARA_SPACE \}
-.          el \{ .PARA_SPACE OFF \}
+.          ie \\n[#RESET_PARA_SPACE] .PARA_SPACE
+.          el .PARA_SPACE OFF
 .       \}
 .       if \\n[#CONDENSE] \{\
 \E*[COND]\c
@@ -11729,22 +10828,21 @@
 .    if \\n[#PP_STYLE]=2 \{\
 \!.     br
 .       if \\n[#BROKEN_QUOTE] \{\
-.          ie \\n(nl=\\n[#PAGE_TOP] \{ .nr #Q_PP 1 \}
-.          el \{ .nr #Q_PP 0 \}
+.          ie \\n[nl]=\\n[#PAGE_TOP] .nr #Q_PP 1
+.          el .nr #Q_PP 0
 .          rr #BROKEN_QUOTE
 .       \}
 .       ie \\n[#Q_PP]=0 \{\
-.          if \\n[#INDENT_FIRST_PARAS] \{\
+.          if \\n[#INDENT_FIRST_PARAS] \
 .             ti \\n[#PP_INDENT]u/2u
-.          \}
 .          if \\n[#ENDNOTE] \{\
-.             ie \\n[#INDENT_FIRSTS] \{ .ti \\n[#PP_INDENT]u/2u \}
-.             el \{ .ti 0 \}
+.             ie \\n[#INDENT_FIRSTS] .ti \\n[#PP_INDENT]u/2u
+.             el .ti 0
 .          \}
 .       \}
 .       el \{\
 .          ti \\n[#PP_INDENT]u/2u
-.          if \\n[#PP_SPACE]=1 \{ .ALD \\n[#DOC_LEAD]u \}
+.          if \\n[#PP_SPACE]=1 .ALD \\n[#DOC_LEAD]u
 .       \}
 .       if \\n[#CONDENSE] \{\
 \E*[COND]\c
@@ -11757,13 +10855,12 @@
 .\" This takes care of multi-paragraph dialogue, where each para
 .\" is introduced by an open quote whereas the previous para has
 .\" no close quote.
-.    if \\n[#OPEN_CLOSE]=1 \{\
-.       nr #OPEN_CLOSE 0
-.    \}
+.    if \\n[#OPEN_CLOSE]=1 .nr #OPEN_CLOSE 0
 .    nr #PP_ACTIVE 1
 .    UNDERLINE OFF
+.    if r #QUOTE_4_HD .rr #QUOTE_4_HD
+.    if r #LB_4_HD .rr #LB_4_HD
 .END
-\#
 \# ====================================================================
 \#
 \# +++QUOTES+++
@@ -11782,17 +10879,17 @@
 \#   Default is ON for printstyle TYPEWRITE.
 \#
 .MAC UNDERLINE_QUOTES END
-.    ie '\\$1'' \{ .nr #UNDERLINE_QUOTES 1 \}
-.    el \{ .rr #UNDERLINE_QUOTES \}
+.    ie '\\$1'' .nr #UNDERLINE_QUOTES 1
+.    el .rr #UNDERLINE_QUOTES
 .END
 \#
-\#
 \# QUOTE INDENT
 \# ------------
 \# *Argument:
 \#   <integer> | <integer with unit of measure appended>
 \# *Function:
-\#   Creates or modifies register #Q_OFFSET_VALUE.
+\#   Creates or modifies register #Q_OFFSET_VALUE or string
+\#   $Q_OFFSET_VALUE.
 \# *Notes:
 \#   If just an integer given, value by which to multiply PARA_INDENT
 \#   to get quote indent.  If integer with a unit of measure appended,
@@ -11801,20 +10898,15 @@
 \#  Default is 3 for typeset; 2 for typewrite.
 \#
 .MAC QUOTE_INDENT END
-.    if r#Q_OFFSET_VALUE         \{ .rr #Q_OFFSET_VALUE \}
-.    if !'\\*[$Q_OFFSET_VALUE]'' \{ .rm $Q_OFFSET_VALUE \}
+.    rr #Q_OFFSET_VALUE
+.    rm $Q_OFFSET_VALUE
 .    ds $EVAL_QI_ARG \\$1
 .    substring $EVAL_QI_ARG -1
-.    ie \B'\\*[$EVAL_QI_ARG]' \{\
-.       nr #Q_OFFSET_VALUE \\$1
-.    \}
-.    el \{\
-.       ds $Q_OFFSET_VALUE \\$1
-.    \}
+.    ie \B'\\*[$EVAL_QI_ARG]' .nr #Q_OFFSET_VALUE \\$1
+.    el .ds $Q_OFFSET_VALUE \\$1
 .    rm $EVAL_QI_ARG
 .END
 \#
-\#
 \# QUOTE_AUTOLEAD
 \# --------------
 \# *Arguments:
@@ -11823,10 +10915,14 @@
 \#   Sets autolead for quotes and/or blockquotes.
 \#
 .MAC QUOTE_AUTOLEAD END
-.    if '\\$0'QUOTE_AUTOLEAD'      \{ .nr #Q_AUTOLEAD \\$1 \}
-.    if '\\$0'BLOCKQUOTE_AUTOLEAD' \{ .nr #BQ_AUTOLEAD \\$1 \}
-.    if '\\$0'ENDNOTE_QUOTE_AUTOLEAD'      \{ .nr #EN_Q_AUTOLEAD \\$1 \}
-.    if '\\$0'ENDNOTE_BLOCKQUOTE_AUTOLEAD' \{ .nr #EN_BQ_AUTOLEAD \\$1 \}
+.    ie '\\$1'DEFAULT' .nr #\\$0_DEFAULT 1
+.    el \{\
+.       rr #\\$0_DEFAULT
+.       if '\\$0'QUOTE_AUTOLEAD'              .nr #Q_AUTOLEAD \\$1
+.       if '\\$0'BLOCKQUOTE_AUTOLEAD'         .nr #BQ_AUTOLEAD \\$1
+.       if '\\$0'ENDNOTE_QUOTE_AUTOLEAD'      .nr #EN_Q_AUTOLEAD \\$1
+.       if '\\$0'ENDNOTE_BLOCKQUOTE_AUTOLEAD' .nr #EN_BQ_AUTOLEAD \\$1
+.    \}
 .END
 \#
 .ALIAS BLOCKQUOTE_AUTOLEAD         QUOTE_AUTOLEAD
@@ -11844,11 +10940,10 @@
 \#   quotes, s/he can turn it off here.  Has no effect in TYPEWRITE.
 \#
 .MAC ALWAYS_FULLSPACE_QUOTES END
-.    if '\\$1'' \{ .nr #FULLSPACE_QUOTES 1 \}
-.    el \{ .rr #FULLSPACE_QUOTES \}
+.    if '\\$1'' .nr #FULLSPACE_QUOTES 1
+.    el .rr #FULLSPACE_QUOTES
 .END
 \#
-\#
 \# QUOTE
 \# -----
 \# *Arguments:
@@ -11875,35 +10970,30 @@
 .    br
 .    if \\n[#LINENUMBERS]=1 \{\
 .       nr #LINENUMBERS 2
-.       nr #NEXT_LN \\n(ln
+.       nr #NEXT_LN \\n[ln]
 .       nm
 .    \}
 .    ie '\\$1'' \{\
 .       ev QUOTE
+.       evc 0
 .       if \\n[#LINENUMBERS]=2 \{\
-.          if \\n[#SILENT_QUOTE_LN]=1 \{ .nm \\n[#NEXT_LN] 1000 -4 \}
+.          if \\n[#SILENT_QUOTE_LN]=1 .nm \\n[#NEXT_LN] 1000 -4
 .       \}
 .       nr #IN_DIVER 1
 .       nr #QUOTE 1
 .       di P_QUOTE
-.       ie r#Q_OFFSET_VALUE \{\
-.          ll \\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*\\n[#Q_OFFSET_VALUE]u)
-.       \}
-.       el \{ .ll \\n[#L_LENGTH]u-\\*[$Q_OFFSET_VALUE] \}
+.       ie !'\\*[$Q_OFFSET_VALUE]'' .ll 
\\n[#L_LENGTH]u-(\\*[$Q_OFFSET_VALUE]*2u)
+.       el .ll \\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
 .       if \\n[#LINENUMBERS]=2 \{\
-.          if \\n[#QUOTE_LN]=1 \{\
-.             nm \\n(ln "" \\*[$Q_LN_GUTTER] -3-\\*[$Q_LN_GUTTER]
+.          if \\n[#QUOTE_LN]=1 \
+.             nm \\n[ln] "" \\*[$Q_LN_GUTTER] -3-\\*[$Q_LN_GUTTER]
 .          \}
-.       \}
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .       if \\n[#COLUMNS] \{\
-.          ie r#Q_OFFSET_VALUE \{\
+.          ie \\n[#Q_OFFSET_VALUE] \
 .             ll \\n[#COL_L_LENGTH]u-(\\n[#PP_INDENT]u*\\n[#Q_OFFSET_VALUE]u)
-.          \}
-.          el \{\
-.             ll \\n[#COL_L_LENGTH]u-\\*[$Q_OFFSET_VALUE]
-.          \}
-.          ta \\n(.lu
+.          el .ll \\n[#COL_L_LENGTH]u-\\*[$Q_OFFSET_VALUE]
+.          ta \\n[.l]u
 .       \}
 .       if \\n[#PRINT_STYLE]=1 \{\
 .          TYPEWRITER
@@ -11914,20 +11004,22 @@
 .          FAMILY  \\*[$QUOTE_FAM]
 .          FT      \\*[$QUOTE_FT]
 .          PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$QUOTE_SIZE_CHANGE]
-.          ie !r#Q_AUTOLEAD  \{ .LS \\n[#Q_LEAD]u \}
+.          ie !r #Q_AUTOLEAD .LS \\n[#Q_LEAD]u
 .          el \{\
 .             AUTOLEAD \\n[#Q_AUTOLEAD]
-.             nr #Q_LEAD \\n(.v
+.             if r #QUOTE_AUTOLEAD_DEFAULT .LS \\n[#DOC_LEAD]u
+.             nr #Q_LEAD \\n[.v]
 .          \}
 .          if \\n[#ENDNOTE] \{\
 .             PT_SIZE \\n[#EN_PS]u\\*[$QUOTE_SIZE_CHANGE]
-.             ie !r#EN_Q_AUTOLEAD  \{ .LS \\n[#EN_Q_LEAD]u \}
+.             ie !r #EN_Q_AUTOLEAD .LS \\n[#EN_Q_LEAD]u
 .             el \{\
 .                AUTOLEAD \\n[#EN_Q_AUTOLEAD]
-.                nr #EN_Q_LEAD \\n(.v
+.                if r #ENDNOTE_QUOTE_AUTOLEAD_DEFAULT .LS \\n[#DOC_LEAD]u
+.                nr #EN_Q_LEAD \\n[.v]
 .             \}
 .          \}
-.          nr #Q_LEAD_REAL \\n(.v
+.          nr #Q_LEAD_REAL \\n[.v]
 .          LEFT
 .          if \\n[#QUOTE_COLOR]=1 \{\
 .             nf
@@ -11938,27 +11030,26 @@
 .       if \\n[#LINENUMBERS]=2 \{\
 .          ie \\n[#QUOTE_LN]=1 \{\
 .             if '\\*[$Q_LN_GUTTER]'' .ds $Q_LN_GUTTER \\*[$LN_GUTTER]
-.             nm \\n(ln "" \\*[$Q_LN_GUTTER] -3-\\*[$Q_LN_GUTTER]
+.             nm \\n[ln] "" \\*[$Q_LN_GUTTER] -3-\\*[$Q_LN_GUTTER]
 .          \}
 .          el \{\
-.             if !\\n[#SILENT_QUOTE_LN] \{ .NUMBER_LINES OFF \}
+.             if !\\n[#SILENT_QUOTE_LN] .NUMBER_LINES OFF
 .          \}
 .       \}
-.       nr #Q_TOP \\n(nl
+.       nr #Q_TOP \\n[nl]
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          if \\n[#UNDERLINE_QUOTES] \{\
-.               FT I
+.          if \\n[#UNDERLINE_QUOTES] .FT I
 .          \}
 .       \}
-.    \}
-.    el \{ .DO_QUOTE \}
+.    el .DO_QUOTE
 .END
 \#
-\#
 \# CODE
 \# ----
 \# *Arguments:
-\#   <none [ BR | BREAK | SPREAD ]> | <anything [ BR | BREAK | SPREAD ]>
+\#   <none> [ BR | BREAK | SPREAD ]
+\#    or
+\#   <anything> [ BR | BREAK | SPREAD ]
 \# *Function:
 \#   Takes care of administrivia associated with setting code snippets.
 \#
@@ -11979,7 +11070,7 @@
 .    ie '\\$1'' \{\
 .       ie \\n[#PRINT_STYLE]=1 \{\
 .          CODE_FAMILY C
-.          ie \\n[#CODE_FT]=1 \{ .ft \\*[$CODE_FT] \}
+.          ie \\n[#CODE_FT]=1 .ft \\*[$CODE_FT]
 .          el \{\
 .             CODE_FONT R
 .             ft R
@@ -11993,12 +11084,12 @@
 .          \}
 .       \}
 .       el \{\
-.          ie \\n[#CODE_FAM]=1 \{ .fam \\*[$CODE_FAM] \}
+.          ie \\n[#CODE_FAM]=1 .fam \\*[$CODE_FAM]
 .          el \{\
 .             CODE_FAMILY C
 .             fam \\*[$CODE_FAM]
 .          \}
-.          ie \\n[#CODE_FT]=1 \{ .ft \\*[$CODE_FT] \}
+.          ie \\n[#CODE_FT]=1 .ft \\*[$CODE_FT]
 .          el \{\
 .             CODE_FONT R
 .             ft \\*[CODE_FT]
@@ -12019,9 +11110,9 @@
 .    el \{\
 .       fam
 .       ft
-.       ps
+.       if !\\n[#CODE_SIZE_ADJ]=0 .ps
 .       rchar '
-.       gcolor
+.       if \\n[#CODE_COLOR]=1 .gcolor
 .       if \\n[#RESTORE_UNDERLINE]=1 \{\
 .          rr #RESTORE_UNDERLINE
 .          UNDERLINE_QUOTES
@@ -12030,12 +11121,12 @@
 .          rr #SQ_WAS_ON
 .          SMARTQUOTES
 .       \}
-.       if \\n[#QUOTE] \{ .RLD 1v \}
+.       if \\n[#QUOTE] .RLD 1v
 .    \}
 .    if \\n[#NUM_ARGS]=2 \{\
-.       if '\\$2'BR'     \{ .br  \}
-.       if '\\$2'BREAK'  \{ .br  \}
-.       if '\\$2'SPREAK' \{ .brp \}
+.       if '\\$2'BR' .br
+.       if '\\$2'BREAK' .br
+.       if '\\$2'SPREAK' .brp
 .    \}
 .END
 \#
@@ -12075,7 +11166,6 @@
 . nr #CODE_SIZE_ADJ \\$1
 .END
 \#
-\#
 \# ---Blockquotes---
 \#
 \# BLOCKQUOTE
@@ -12097,69 +11187,64 @@
 .    br
 .    if \\n[#LINENUMBERS]=1 \{\
 .       nr #LINENUMBERS 2
-.       nr #NEXT_LN \\n(ln
+.       nr #NEXT_LN \\n[ln]
 .       nm
 .    \}
 .    ie '\\$1'' \{\
 .       ev BLOCKQUOTE
+.       evc 0
 .       if \\n[#LINENUMBERS]=2 \{\
-.          if \\n[#SILENT_BQUOTE_LN]=1 \{ .nm \\n[#NEXT_LN] 1000 -4 \}
+.          if \\n[#SILENT_BQUOTE_LN]=1 .nm \\n[#NEXT_LN] 1000 -4
 .       \}
 .       nr #IN_DIVER 1
 .       nr #QUOTE    2
 .       nr #PP_STYLE 2
 .       nr #Q_PP     0
 .       di B_QUOTE
-.       ie r#Q_OFFSET_VALUE \{\
-.          ll \\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
-.       \}
-.       el \{ .ll \\n[#L_LENGTH]u-(\\*[$Q_OFFSET_VALUE]*2u) \}
+.       ie !'\\*[$Q_OFFSET_VALUE]'' .ll 
\\n[#L_LENGTH]u-(\\*[$Q_OFFSET_VALUE]*2u)
+.       el .ll \\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
 .       if \\n[#ENDNOTE] \{\
 .          if \\n[#EN_NUMBERS_ALIGN_RIGHT] \{\
-.             ie r#Q_OFFSET_VALUE \{\
-.                ll 
\\n[#RESET_L_LENGTH]u-\\n[#EN_TEXT_INDENT]u-(\\n[#EN_PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
-.             \}
-.             el \{\
-.                ll 
\\n[#RESET_L_LENGTH]u-\\n[#EN_TEXT_INDENT]u-(\\*[$Q_OFFSET_VALUE]*2u)
-.             \}
+.             ie r#Q_OFFSET_VALUE \
+.                ll \
+\\n[#RESET_L_LENGTH]u-\\n[#EN_TEXT_INDENT]u-(\\n[#EN_PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
+.             el \
+.                ll \
+\\n[#RESET_L_LENGTH]u-\\n[#EN_TEXT_INDENT]u-(\\*[$Q_OFFSET_VALUE]*2u)
 .          \}
 .          if \\n[#EN_NUMBERS_ALIGN_LEFT] \{\
-.             ie r#Q_OFFSET_VALUE \{\
+.             ie r#Q_OFFSET_VALUE \
 .                ll 
\\n[#L_LENGTH]u-(\\n[#EN_PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
-.             \}
-.             el \{\
+.             el \
 .                ll \\n[#L_LENGTH]u-(\\*[$Q_OFFSET_VALUE]u*2u)
 .             \}
 .          \}
-.       \}
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .       CHECK_INDENT
 .       if \\n[#COLUMNS] \{\
-.          ie r#Q_OFFSET_VALUE \{\
-.             ll 
\\n[#COL_L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
-.          \}
-.          el \{\
+.          ie r#Q_OFFSET_VALUE \
+.             ll \
+\\n[#COL_L_LENGTH]u-(\\n[#PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
+.          el \
 .             ll \\n[#COL_L_LENGTH]u-(\\*[$Q_OFFSET_VALUE]*2u)
-.          \}
 .          if \\n[#ENDNOTE] \{\
 .             if \\n[#EN_NUMBERS_ALIGN_RIGHT] \{\
-.                ie r#Q_OFFSET_VALUE \{\
-.                   ll 
\\n[#RESET_L_LENGTH]u-\\n[#EN_TEXT_INDENT]u-(\\n[#EN_PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
-.                \}
-.                el \{\
-.                   ll 
\\n[#RESET_L_LENGTH]u-\\n[#EN_TEXT_INDENT]u-(\\*[$Q_OFFSET_VALUE]*2u)
-.                \}
+.                ie r#Q_OFFSET_VALUE \
+.                   ll \
+\\n[#RESET_L_LENGTH]u-\\n[#EN_TEXT_INDENT]u-(\\n[#EN_PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
+.                el \
+.                   ll \
+\\n[#RESET_L_LENGTH]u-\\n[#EN_TEXT_INDENT]u-(\\*[$Q_OFFSET_VALUE]*2u)
 .             \}
 .             if \\n[#EN_NUMBERS_ALIGN_LEFT] \{\
-.                ie r#Q_OFFSET_VALUE \{\
-.                   ll 
\\n[#COL_L_LENGTH]u-(\\n[#EN_PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
-.                \}
-.                el \{\
+.                ie r#Q_OFFSET_VALUE \
+.                   ll \
+\\n[#COL_L_LENGTH]u-(\\n[#EN_PP_INDENT]u*(\\n[#Q_OFFSET_VALUE]u*2u))
+.                el \
 .                   ll \\n[#COL_L_LENGTH]u-(\\*[$Q_OFFSET_VALUE]*2u)
 .                \}
 .             \}
-.          \}
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .       if \\n[#PRINT_STYLE]=1 \{\
 .          TYPEWRITER
@@ -12171,20 +11256,22 @@
 .          FAMILY  \\*[$BQUOTE_FAM]
 .          FT      \\*[$BQUOTE_FT]
 .          PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$BQUOTE_SIZE_CHANGE]
-.          ie !\\n[#BQ_AUTOLEAD] \{ .LS \\n[#BQ_LEAD]u \}
+.          ie !r #BQ_AUTOLEAD .LS \\n[#BQ_LEAD]u
 .          el \{\
 .             AUTOLEAD \\n[#BQ_AUTOLEAD]
-.             nr #BQ_LEAD \\n(.v
+.             if r #BLOCKQUOTE_AUTOLEAD_DEFAULT .LS \\n[#DOC_LEAD]u
+.             nr #BQ_LEAD \\n[.v]
 .          \}
 .          if \\n[#ENDNOTE] \{\
 .             PT_SIZE \\n[#EN_PS]u\\*[$BQUOTE_SIZE_CHANGE]
-.             ie !r#EN_BQ_AUTOLEAD  \{ .LS \\n[#EN_BQ_LEAD]u \}
+.             ie !r#EN_BQ_AUTOLEAD .LS \\n[#EN_BQ_LEAD]u
 .             el \{\
 .                AUTOLEAD \\n[#EN_BQ_AUTOLEAD]
-.                nr #EN_BQ_LEAD \\n(.v
+.                if r #ENDNOTE_BLOCKQUOTE_AUTOLEAD_DEFAULT .LS \\n[#DOC_LEAD]u
+.                nr #EN_BQ_LEAD \\n[.v]
 .             \}
 .          \}
-.          nr #Q_LEAD_REAL \\n(.v
+.          nr #Q_LEAD_REAL \\n[.v]
 .          if \\n[#BQUOTE_COLOR]=1 \{\
 .             nf
 \m[\\*[$BQUOTE_COLOR]]
@@ -12198,30 +11285,29 @@
 .       if \\n[#LINENUMBERS]=2 \{\
 .          ie \\n[#BQUOTE_LN]=1 \{\
 .             if '\\*[$BQ_LN_GUTTER]'' .ds $BQ_LN_GUTTER \\*[$LN_GUTTER]
-.             nm \\n(ln "" \\*[$BQ_LN_GUTTER] -3-\\*[$BQ_LN_GUTTER]
+.             nm \\n[ln] "" \\*[$BQ_LN_GUTTER] -3-\\*[$BQ_LN_GUTTER]
 .          \}
 .          el \{\
-.             if !\\n[#SILENT_BQUOTE_LN] \{ .NUMBER_LINES OFF \}
+.             if !\\n[#SILENT_BQUOTE_LN] .NUMBER_LINES OFF
 .          \}
 .       \}
-.       nr #Q_TOP \\n(nl
+.       nr #Q_TOP \\n[nl]
 .       if \\n[#INDENT_FIRST_PARAS] \{\
 .          ie !\\n[#ENDNOTE] \{\
-.             if \\n[#PRINT_STYLE]=1 \{ .ti \\n[#PP_INDENT]u/2u \}
-.             if \\n[#PRINT_STYLE]=2 \{ .ti \\n[#PP_INDENT]u/2u \}
+.             if \\n[#PRINT_STYLE]=1 .ti \\n[#PP_INDENT]u/2u
+.             if \\n[#PRINT_STYLE]=2 .ti \\n[#PP_INDENT]u/2u
 .          \}
 .          el \{\
 .             if \\n[#INDENT_FIRSTS]=1 \{\
-.                if \\n[#PRINT_STYLE]=1 \{ .ti \\n[#EN_PP_INDENT]u/2u \}
-.                if \\n[#PRINT_STYLE]=2 \{ .ti \\n[#EN_PP_INDENT]u/2u \}
+.                if \\n[#PRINT_STYLE]=1 .ti \\n[#EN_PP_INDENT]u/2u
+.                if \\n[#PRINT_STYLE]=2 .ti \\n[#EN_PP_INDENT]u/2u
 .             \}
 .          \}
 .       \}
 .    \}
-.    el \{ .DO_QUOTE \}
+.    el .DO_QUOTE
 .END
 \#
-\#
 \# DO QUOTE
 \# --------
 \# *Arguments:
@@ -12255,91 +11341,98 @@
 .    nr #DONE_ONCE 0 1
 .    REMOVE_INDENT
 .    ev
-.    nr #Q_DEPTH (\\n[#DIVER_DEPTH]-\\n[#Q_LEAD_REAL])+\\n[#LEAD]
+.    nr #Q_DEPTH (\\n[#DIVER_DEPTH]-\\n[#Q_LEAD_REAL])
 .    nr #Q_LEAD_DIFF \\n[#LEAD]-\\n[#Q_LEAD_REAL]
+.    if !\\n[.v]=\\n[#Q_LEAD_REAL] \{\
 .    SILENT
 .    br
 .    nf
-.    nr #CURRENT_V_POS 
\\n(nl+\\n[#Q_LEAD_DIFF]+(\\n[#DIVER_DEPTH]-\\n[#Q_DEPTH_REAL])
+.       nr #CURRENT_V_POS \
+\\n[nl]+\\n[#Q_LEAD_DIFF]+(\\n[#DIVER_DEPTH]-\\n[#Q_DEPTH_REAL])
 .    SHIM
 .    SILENT OFF
 .    nr #Q_SPACE_ADJ \\n[#SHIM]/2
-.    nr #TRAP \\n(.t-1
+.       nr #TRAP \\n[.t]-1
+.    \}
 .    if \\n[#ENDNOTE] \{\
 .       nr #RESET_QUOTE_SPACING \\n[#FULLSPACE_QUOTES]
 .       ALWAYS_FULLSPACE_QUOTES
 .    \}
 .    if \\n[#PRINT_STYLE]=1 \{\
-.       if \\n[#START]=1 \{ . \}
+.       if \\n[#START]=1 .
 .       if \\n[#START]=0 \{\
-.          if !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
+.          if !\\n[#LINEBREAK] .ALD \\n[#DOC_LEAD]u
 .       \}
 .       if \\n[#HEAD] \{\
-.          if \\n[#HEAD]=1 \{ .RLD \\n[#DOC_LEAD]u \}
+.          if \\n[#HEAD]=1 .RLD \\n[#DOC_LEAD]u
 .       \}
 .    \}
 .    if \\n[#PRINT_STYLE]=2 \{\
 .       ie \\n[#PP_SPACE] \{\
-.          ie \\n[#HEAD]>0 \{ . \}
+.          ie \\n[#HEAD] .
 .          el \{\
-.             ie \\n[#START] \{ . \}
-.             el \{ .ALD \\n[#DOC_LEAD]u \}
+.             ie \\n[#START] .
+.             el .ALD \\n[#DOC_LEAD]u/2u
 .          \}
 .       \}
 .       el \{\
 .          ie \\n[#Q_DEPTH]<(\\n[#TRAP_DISTANCE]-1) \{\
-.             ie (\\n[#TRAP_DISTANCE]-1)-\\n[#Q_DEPTH]<\\n[#DOC_LEAD] \{\
+.             ie ((\\n[#TRAP_DISTANCE]-1)-\\n[#Q_DEPTH])<\\n[#DOC_LEAD] \
 .                Q_NOFIT
-.             \}
 .             el \{\
-.                Q_FITS
+.                ie (\\n[#TRAP_DISTANCE]-\\n[#DOC_LEAD])<\\n[#DOC_LEAD] 
.Q_NOFIT
+.                el \{\
+.                   ie (\\n[#Q_DEPTH]+\\n[.v])=(\\n[#TRAP_DISTANCE]-1) .Q_NOFIT
+.                   el .Q_FITS
 .             \}
 .          \}
+.          \}
+.          el .Q_NOFIT
+.       \}
+.       if \\n[#LINEBREAK] \{\
+.          ie address@hidden .RLD \\n[#DOC_LEAD]u
 .          el \{\
-.             Q_NOFIT
+.             nop
+.             sp |\\n[#T_MARGIN]u-\\n[#BQ_LEAD]u
 .          \}
 .       \}
 .    \}
-.    ie r#Q_OFFSET_VALUE \{\
+.    ie !'\\*[$Q_OFFSET_VALUE]'' .nr #Q_OFFSET 
\\n[#L_MARGIN]+\\*[$Q_OFFSET_VALUE]
+.    el \
 .       nr #Q_OFFSET \\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
-.    \}
-.    el \{ .nr #Q_OFFSET \\n[#L_MARGIN]+\\*[$Q_OFFSET_VALUE] \}
 .    if \\n[#COLUMNS] \{\
-.       ie r#Q_OFFSET_VALUE \{\
-.          nr #Q_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
+.       ie r#Q_OFFSET_VALUE \
+.          nr #Q_OFFSET \
+\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
+.       el .nr #Q_OFFSET \\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$Q_OFFSET_VALUE]
 .       \}
-.       el \{ .nr #Q_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$Q_OFFSET_VALUE] \}
-.    \}
-.    if !\\n[#ENDNOTE] \{ .po \\n[#Q_OFFSET]u \}
+.    if !\\n[#ENDNOTE] .po \\n[#Q_OFFSET]u
 .    if \\n[#ENDNOTE] \{\
-.       ie r#Q_OFFSET_VALUE \{ .in +\\n[#EN_PP_INDENT]u*\\n[#Q_OFFSET_VALUE]u 
\}
-.       el \{ .in +\\*[$Q_OFFSET_VALUE] \}
+.       ie \\n[#Q_OFFSET_VALUE] .in +\\n[#EN_PP_INDENT]u*\\n[#Q_OFFSET_VALUE]u
+.       el .in +\\*[$Q_OFFSET_VALUE]
 .    \}
 .    ie \\n[#START]=1 \{\
-.       ie !\\n[#Q_LEAD_DIFF]<0 \{ .ALD \\n[#Q_SPACE_ADJ]u \}
-.       el \{ .RLD 0-\\n[#Q_LEAD_DIFF]u \}
+.       ie !\\n[#Q_LEAD_DIFF]<0 .ALD \\n[#Q_SPACE_ADJ]u
+.       el .RLD 0-\\n[#Q_LEAD_DIFF]u
 .    \}
 .    el \{\
-.       if \\n[#PRINT_STYLE]=2 \{ .ALD \\n[#Q_SPACE_ADJ]u \}
+.       if \\n[#PRINT_STYLE]=2 \{\
+.           if !\\n[.v]=\\n[#Q_LEAD] .ALD \\n[#Q_SPACE_ADJ]u
+.       \}
 .    \}
 .    if \\n[#QUOTE]=1 \{\
 .       nf
 .       P_QUOTE
-.       if !\\n[#START] \{ .rr #QUOTE \}
+.       br
+.       if !\\n[#START] .rr #QUOTE
 .    \}
 .    if \\n[#QUOTE]=2 \{\
 .       nf
 .       B_QUOTE
-.    \}
-.    if \\n[#UNDERLINE_ON] \{\
-.       vpt 0
-.       sp -1v
-.       UNDERLINE OFF
-.       vpt
+.       br
 .    \}
 .    if \\n[#PRINT_STYLE]=1 \{\
-.       ALD \\n[#DOC_LEAD]u
-.       if !\\n[.v]=\\n[#DOC_LEAD] \{ .SHIM \}
+.       if !\\n[.v]=\\n[#DOC_LEAD] .SHIM
 .    \}
 .    if \\n[#PRINT_STYLE]=2 \{\
 .       ie \\n[#START] \{\
@@ -12352,7 +11445,7 @@
 .          \}
 .       \}
 .       el \{\
-.          ie \\n[#PP_SPACE] \{ . \}
+.          ie \\n[#PP_SPACE] .
 .          el \{\
 .             ie \\n[#HEAD]=1 \{\
 .                ALD \\n[#DOC_LEAD]u
@@ -12360,95 +11453,95 @@
 .             \}
 .             el \{\
 .                ie \\n[#FULLSPACE_QUOTES] \{\
-.                   ie \\n[#ENDNOTE] \{ .ALD \\n[#EN_LEAD]u \}
-.                   el \{ .ALD \\n[#DOC_LEAD]u \}
+.                   ie \\n[#ENDNOTE] .ALD \\n[#EN_LEAD]u
+.                   el .ALD \\n[#DOC_LEAD]u
 .                \}
-.                el \{ .ALD (\\n[#DOC_LEAD]u/2u) \}
+.                el .ALD (\\n[#DOC_LEAD]/2)u
 .                ie \\n[#Q_FITS] \{\
-.                   ie \\n[#Q_TOP]=\\n[#PAGE_TOP] \{\
+.                   ie (\\n[#Q_TOP]=\\n[#PAGE_TOP]):(address@hidden) \{\
 .                      nr #Q_AT_TOP 1
 .                      nr #DELAY_SHIM 1
 .                   \}
-.                   el \{ .SHIM \}
+.                   el \{\
+.                      if !\\n[.v]=\\n[#Q_LEAD_REAL] .SHIM
+.                   \}
 .                \}
 .                el \{\
 .                   SHIM
 .\" Make sure that Q_LEAD_DIFF is not added to the first line of
 .\" normal text at the top of any page following output of a quote
 .\" whose last line falls on B_MARGIN of the previous page.
-.                   if 
\\n(nl=(\\n[#T_MARGIN]-\\n[#DOC_LEAD]+\\n[#Q_LEAD_DIFF]) \{\
+.                   if \\n[#Q_LEAD_DIFF] \{\
+.                      if 
\\n[nl]=(\\n[#T_MARGIN]-\\n[#DOC_LEAD]+\\n[#Q_LEAD_DIFF]) \{\
 .                      PRINT \&
 .                      br
 .                      sp -1v-\\n[#Q_LEAD_DIFF]u
+.                         nr #Q_LEAD_DIFF_CHECK 1
+.                      \}
 .                   \}
 .                \}
 .             \}
 .          \}
 .       \}
 .    \}
+.    rr #Q_SPACE_ADJ
 .    if \\n[#LINENUMBERS]=2 \{\
 .       nr #LINENUMBERS 1
 .       if !\\n[#ENDNOTE] \{\
-.          ie \\n[#RESTORE_LN_NUM]=1 \{ .nm \\n[#NEXT_LN] \}
-.          el \{ .nm +0 \}
+.          ie \\n[#RESTORE_LN_NUM]=1 .nm \\n[#NEXT_LN]
+.          el .nm +0
 .       \}
 .    \}
-.    if \\n[#ENDNOTE] \{ .nr #FULLSPACE_QUOTES \\n[#RESET_QUOTE_SPACING] \}
-.    if r#HEAD        \{ .rr #HEAD     \}
-.    if r#EPIGRAPH    \{ .rr #EPIGRAPH \}
+.    if \\n[#ENDNOTE] .nr #FULLSPACE_QUOTES \\n[#RESET_QUOTE_SPACING]
+.    if r #HEAD .rr #HEAD
+.    if r #EPIGRAPH .rr #EPIGRAPH
 .    rr #Q_PP
 .    rr #LINEBREAK
 .    nr #PP_STYLE  1
 .    nr #END_QUOTE 1
-.    if !\\n[#ENDNOTE] \{ .po \\n[#L_MARGIN]u \}
-.    if \\n[#ENDNOTE] \{\
-.       in \\n[#EN_TEXT_INDENT]u
-.    \}
+.    if !\\n[#ENDNOTE] .po \\n[#L_MARGIN]u
+.    if \\n[#ENDNOTE]  .in \\n[#EN_TEXT_INDENT]u
 .    if \\n[#COLUMNS] \{\
 .       if !\\n[#ENDNOTE] \{\
 .          po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
-.          nr #L_MARGIN \\n(.o
-.       \}
-.       if \\n[#ENDNOTE] \{\
-.          in \\n[#EN_TEXT_INDENT]u
-.       \}
-.    \}
-.    ie !\\n[#ENDNOTE] \{\
-.       QUAD \\*[$DOC_QUAD]
+.          nr #L_MARGIN \\n[.o]
 .    \}
-.    el \{\
-.       QUAD \\*[EN_QUAD]
+.       if \\n[#ENDNOTE] .in \\n[#EN_TEXT_INDENT]u
 .    \}
-.    if r#DELAY_SHIM \{\
+.    ie !\\n[#ENDNOTE] .QUAD \\*[$DOC_QUAD]
+.    el .QUAD \\*[EN_QUAD]
+.    if r #DELAY_SHIM \{\
 .       SHIM
 .       rr #DELAY_SHIM
 .    \}
+.    if \\n[#PRINT_STYLE]=1 \{\
+.       if \\n[#UNDERLINE_QUOTES] .FT R
+.    \}
+.    nr #QUOTE_4_HD 1
 .END
 \#
-\#
 \# Utility macros for DO_QUOTE
 \# ---------------------------
 \#
 .MAC Q_FITS END
 .    nr #Q_FITS 1
-.    ie \\n[#HEAD]=1 \{\
-.       ALD \\n[#Q_LEAD_DIFF]u
-.    \}
+.    ie \\n[#HEAD]=1 .ALD \\n[#Q_LEAD_DIFF]u
 .    el \{\
-.       ie \\n[#START] \{ . \}
+.       ie \\n[#START] .
 .       el \{\
 .          ie \\n[#FULLSPACE_QUOTES] \{\
-.             ie \\n[#ENDNOTE] \{ .ALD \\n[#EN_LEAD]u+\\n[#Q_LEAD_DIFF]u \}
-.             el \{ .ALD \\n[#DOC_LEAD]u+\\n[#Q_LEAD_DIFF]u \}
+.             ie \\n[#ENDNOTE] .ALD \\n[#EN_LEAD]u+\\n[#Q_LEAD_DIFF]u
+.             el .ALD \\n[#DOC_LEAD]u+\\n[#Q_LEAD_DIFF]u
 .          \}
 .          el \{\
-.\" This seems to be the only way to get the baseline of quotes that start
-.\" at the top of the page to fall on the first line of the "grid" (i.e on
-.\" the first valid baseline of the page).
+.\" This seems to be the only way to get the baseline of quotes that
+.\" start at the top of the page to fall on the first line of the
+.\" grid (ie. on the first valid baseline of the page).
 .             ie \\n[#Q_TOP]=\\n[#PAGE_TOP] \{\
 .                if \\n[#QUOTE]=1 \{\
 .                   rn P_QUOTE Q_TEMP
 .                   di P_QUOTE
+.                   nf
 .                   vs \\n[#Q_LEAD]u
 .                   PRINT \&
 .                   sp -1v+\\n[#Q_LEAD_DIFF]u
@@ -12458,6 +11551,7 @@
 .                if \\n[#QUOTE]=2 \{\
 .                   rn B_QUOTE Q_TEMP
 .                   di B_QUOTE
+.                   nf
 .                   vs \\n[#BQ_LEAD]u
 .                   PRINT \&
 .                   sp -1v+\\n[#Q_LEAD_DIFF]u
@@ -12467,131 +11561,50 @@
 .                rm Q_TEMP
 .             \}
 .             el \{\
-.                ALD (\\n[#DOC_LEAD]u/2u)+\\n[#Q_LEAD_DIFF]u
+.                ALD (\\n[#DOC_LEAD]u/2u)+\\n[#Q_SPACE_ADJ]u
 .             \}
 .          \}
 .       \}
-.       if \\n[#DIVER_FN]=2 \{ .rr #DIVER_FN \}
+.       if \\n[#DIVER_FN]=2 .rr #DIVER_FN
 .    \}
 .END
 \#
 .MAC Q_NOFIT END
 .    rr #Q_FITS
 .    ie r#HEAD \{\
-.       if \\n[#HEAD]=1 \{ . \}
+.       if \\n[#HEAD]=1 .
 .    \}
 .    el \{\
+.       if \\n[#Q_DEPTH]=0 \{\
+.          if \\n[.ns] .rs
+.       \}
 .       ie \\n[#FULLSPACE_QUOTES] \{\
-.          ie \\n[#ENDNOTE] \{ .ALD \\n[#EN_LEAD]u+\\n[#Q_LEAD_DIFF]u \}
-.          el \{ .ALD \\n[#DOC_LEAD]u+\\n[#Q_LEAD_DIFF]u \}
+.          ie \\n[#ENDNOTE] .ALD \\n[#EN_LEAD]u+\\n[#Q_LEAD_DIFF]u
+.          el .ALD \\n[#DOC_LEAD]u+\\n[#Q_LEAD_DIFF]u
+.       \}
+.       el \{\
+.          ALD \\n[#DOC_LEAD]u+\\n[#Q_LEAD_DIFF]
+.          if address@hidden .rs
 .       \}
-.       el \{ .ALD (\\n[#DOC_LEAD]u/2u)+\\n[#Q_LEAD_DIFF]u \}
 .       nr #Q_PARTIAL_DEPTH 0 \\n[#Q_LEAD_REAL]
 .       while \\n+[#Q_PARTIAL_DEPTH]<(\\n[#TRAP_DISTANCE]-1) \{\
 .
-.\}
+.       \}
 .       nr #Q_PARTIAL_DEPTH -\\n[#Q_LEAD_REAL]
-.       nr #Q_SPACE_ADJ 
(\\n[#TRAP_DISTANCE]-1)-\\n[#Q_PARTIAL_DEPTH]+\\n[#Q_LEAD_DIFF]u
+.       nr #Q_SPACE_ADJ \
+(\\n[#TRAP_DISTANCE]-1)-\\n[#Q_PARTIAL_DEPTH]+\\n[#Q_LEAD_DIFF]u
+.       if \\n[#FN_COUNT]>0 .nr #Q_SPACE_ADJ (\\n[#Q_SPACE_ADJ] / 2u)
 .\" Hack to deal with the fact that even though the above routine
 .\" makes the bottom line of the quote fall exactly on the bottom
 .\" margin when traps are disabled, it refuses to do so when traps
 .\" are on.  The difference by which it's off is #Q_LEAD_DIFF
 .\" (the +\\n[#Q_LEAD_DIFF] at the end of the line, above).  Hack
 .\" solution: temporarily lower the FOOTER trap position.
+.       if !\\n[#Q_DEPTH]=0 \{\
 .       nr #SAVED_FOOTER_POS \\n[#VARIABLE_FOOTER_POS]
 .       ch FOOTER \\n[#VARIABLE_FOOTER_POS]u+.25v
 .    \}
-.END
-\#
-\# ====================================================================
-\#
-\# BREAK QUOTE
-\# -----------
-\# *Arguments:
-\#   <none>
-\# *Function:
-\#   Ends the diversion P_QUOTE or B_QUOTE, breaks to a new
-\#   page, and reinvokes BLOCKQUOTE.
-\# *Notes:
-\#   Because quotes go into a diversion before they're output,
-\#   footnotes in quotes that cross pages behave erratically.  The footnote
-\#   isn't processed until the diversion ends, hence the footnote
-\#   marker in the quote isn't always correct for the new page (it's
-\#   picked up from the old one).  BREAK_QUOTE is a workaround for
-\#   this problem.
-\#
-.MAC BREAK_QUOTE END
-.    br
-.    di
-.    nr #BROKEN_QUOTE 1
-.    REMOVE_INDENT
-.    ev
-.    nr #Q_DEPTH \\n[#DIVER_DEPTH]+\\n[#LEAD]
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       if !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
-.       if \\n[#HEAD] \{\
-.          if \\n[#HEAD]=1 \{ .RLD \\n[#DOC_LEAD]u \}
-.       \}
 .    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       ie \\n[#PP_SPACE] \{\
-.          ie \\n[#HEAD]=1 \{ . \}
-.          el \{\
-.             if !\\n[#LINEBREAK] \{ .ALD \\n[#DOC_LEAD]u \}
-.          \}
-.       \}
-.       el \{\
-.          rr #Q_FITS
-.          ie r#HEAD \{\
-.             if \\n[#HEAD]=1 \{ . \}
-.          \}
-.          el \{ .ALD \\n[#DOC_LEAD]u \}
-.       \}
-.    \}
-.    ie r#Q_OFFSET_VALUE \{\
-.       nr #Q_OFFSET \\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
-.    \}
-.    el \{\
-.       nr #Q_OFFSET \\n[#L_MARGIN]+\\*[$Q_OFFSET_VALUE]
-.    \}
-.    if \\n[#COLUMNS] \{\
-.       ie r#Q_OFFSET_VALUE \{\
-.          nr #Q_OFFSET 
\\n[#COL_\\n[#COL_NUM]_L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE])
-.       \}
-.       el \{\
-.          nr #Q_OFFSET \\n[#COL_\\n[#COL_NUM]_L_MARGIN]+\\*[$Q_OFFSET_VALUE]
-.       \}
-.    \}
-.    po \\n[#Q_OFFSET]u
-.    if \\n[#QUOTE]=1 \{\
-.       nf
-.       P_QUOTE
-.    \}
-.    if \\n[#QUOTE]=2 \{\
-.       nf
-.       B_QUOTE
-.    \}
-.    if r#HEAD     \{ .rr #HEAD     \}
-.    if r#EPIGRAPH \{ .rr #EPIGRAPH \}
-.    rr #Q_PP
-.    rr #LINEBREAK
-.    nr #PP_STYLE  1
-.    nr #END_QUOTE 1
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       if \\n[#UNDERLINE_QUOTES] \{\
-.          ev 1
-.          UNDERLINE OFF
-.          ev
-.       \}
-.    \}
-.    po \\n[#L_MARGIN]u
-.    if \\n[#COLUMNS] \{\
-.       po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u
-.       nr #L_MARGIN \\n(.o
-.    \}
-.    QUAD \\*[$DOC_QUAD]
-.    sp |\\n[#PAGE_LENGTH]u  \" To trip footer/header
-.    BLOCKQUOTE
 .END
 \#
 \# ====================================================================
@@ -12608,15 +11621,17 @@
 \#   Default is on.
 \#
 .MAC PAGINATE END
-.    ie '\\$1'' \{ .nr #PAGINATE 1 \}
-.    el \{ .nr #PAGINATE 0 \}
+.    ie '\\$1'' .nr #PAGINATE 1
+.    el \{\
+.      nr #PAGINATE 0
+.      rr #PAGE_NUM_V_POS
+.    \}
 .    if \\n[#HF_OFF]=1 \{\
 .       rr #PAGINATION_STATE
 .       rr #HF_OFF
 .    \}
 .END
 \#
-\#
 \# SUSPEND PAGINATION (before ENDNOTES)
 \# ------------------
 \# *Argument:
@@ -12642,11 +11657,10 @@
 \#
 .MAC RESTORE_PAGINATION END
 .    rr #SUSPEND_PAGINATION
-.    if \\n[#PAGE_NUM_V_POS]=1 \{ .PAGINATE \}
-.    if \\n[#PAGE_NUM_V_POS]=2 \{ .nr #DEFER_PAGINATION 1 \}
+.    if \\n[#PAGE_NUM_V_POS]=1 .PAGINATE
+.    if \\n[#PAGE_NUM_V_POS]=2 .nr #DEFER_PAGINATION 1
 .END
 \#
-\#
 \# PAGE NUMBER FORMAT
 \# ------------------
 \# *Arguments:
@@ -12678,7 +11692,6 @@
 .    \}
 .END
 \#
-\#
 \# HYPHENS AROUND PAGE NUMBERS
 \# ---------------------------
 \# *Arguments:
@@ -12691,11 +11704,10 @@
 \#
 .MAC PAGENUM_HYPHENS END
 .    nr #PAGE_NUM_HYPHENS_SET 1
-.    ie '\\$1'' \{ .nr #PAGE_NUM_HYPHENS 1 \}
-.    el \{ .rr #PAGE_NUM_HYPHENS   \}
+.    ie '\\$1'' .nr #PAGE_NUM_HYPHENS 1
+.    el .rr #PAGE_NUM_HYPHENS
 .END
 \#
-\#
 \# PAGENUMBER POSITION
 \# -------------------
 \# *Arguments:
@@ -12708,23 +11720,34 @@
 \#
 .MAC PAGENUM_POS END
 .    nr #PAGE_NUM_POS_SET 1
-.    if '\\$1'TOP'    \{ .nr #PAGE_NUM_V_POS 1 \}
-.    if '\\$1'BOTTOM' \{ .nr #PAGE_NUM_V_POS 2 \}
-.    if '\\$2'LEFT'   \{ .nr #PAGE_NUM_H_POS 1 \}
-.    if '\\$2'CENTER' \{ .nr #PAGE_NUM_H_POS 2 \}
-.    if '\\$2'CENTRE' \{ .nr #PAGE_NUM_H_POS 2 \}
-.    if '\\$2'RIGHT'  \{ .nr #PAGE_NUM_H_POS 3 \}
+.    if '\\$1'TOP'    .nr #PAGE_NUM_V_POS 1
+.    if '\\$1'BOTTOM' .nr #PAGE_NUM_V_POS 2
+.    if '\\$2'LEFT'   .nr #PAGE_NUM_H_POS 1
+.    if '\\$2'CENTER' .nr #PAGE_NUM_H_POS 2
+.    if '\\$2'CENTRE' .nr #PAGE_NUM_H_POS 2
+.    if '\\$2'RIGHT'  .nr #PAGE_NUM_H_POS 3
 .END
 \#
-\#
 .MAC PN_WITH_HYPHENS END
 .    nr #HYPHEN_ADJ \\n[#CAP_HEIGHT]/12
 .    ds $HYPHEN \v'-\En[#HYPHEN_ADJ]u'-\v'\En[#HYPHEN_ADJ]u'
-.    PRINT \m[\\*[$PAGENUM_COLOR]]\\*[$HYPHEN]\|\\n[#PAGENUMBER]\|\\*[$HYPHEN]
+.    ds $PN_FOR_KN \\n[#PAGENUMBER]
+.\"  Check for initial or terminal 1's or 7's, and apply a little kerning
+.    substring $PN_FOR_KN 0 0 \" 1st digit
+.    if '\\*[$PN_FOR_KN]'1' .ds $PRE_HY_KN \*[BU3]
+.    if '\\*[$PN_FOR_KN]'7' .ds $PRE_HY_KN \*[BU3]
+.    ds $PN_FOR_KN \\n[#PAGENUMBER]
+.    substring $PN_FOR_KN -1 -1 \" last digit
+.    if '\\*[$PN_FOR_KN]'1' .ds $POST_HY_KN \*[BU3]
+.    if '\\*[$PN_FOR_KN]'7' .ds $POST_HY_KN \*[BU3]
+.    PRINT \
+\m[\\*[$PAGENUM_COLOR]]\
+\\*[$HYPHEN]\|\\*[$PRE_HY_KN]\\n[#PAGENUMBER]\\*[$POST_HY_KN]\|\\*[$HYPHEN]
 .    br
+.    rm $PRE_HY_KERN
+.    rm $POST_HY_KERN
 .END
 \#
-\#
 \# PRINT PAGE NUMBER
 \# -----------------
 \# *Arguments:
@@ -12735,38 +11758,37 @@
 .MAC PRINT_PAGE_NUMBER END
 .    ev PAGENUMBER
 .    nf
-.    na
 .    po \\n[#DOC_L_MARGIN]u
 .    ll \\n[#DOC_L_LENGTH]u
-.    ta \\n(.lu
+.    ta \\n[.l]u
 .    FAMILY  \\*[$PAGE_NUM_FAM]
 .    FT      \\*[$PAGE_NUM_FT]
 .    PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$PAGE_NUM_SIZE_CHANGE]
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       TYPEWRITER
-.    \}
-.    if \\n[#PAGE_NUM_V_POS]=1 \{ .vs 0 \}
+\#.    if \\n[#TOC] .ab \\n[.ps]
+\#.    if \\n[#TOC] .tm \\n[#TOC_PS]\\*[$TOC_PN_SIZE_CHANGE]
+.    if \\n[#PRINT_STYLE]=1 .TYPEWRITER
+.    if \\n[#PAGE_NUM_V_POS]=1 .vs 0
 .    if o \{\
-.       ie \\n[#PAGE_NUM_H_POS]=1 \{ .LEFT  \}
-.       el                        \{ .RIGHT \}
+.       ie \\n[#PAGE_NUM_H_POS]=1 .LEFT
+.       el .RIGHT
 .    \}
 .    if e \{\
-.       ie \\n[#PAGE_NUM_H_POS]=1 \{ .RIGHT  \}
-.       el                        \{ .LEFT   \}
+.       ie \\n[#PAGE_NUM_H_POS]=1 .RIGHT
+.       el .LEFT
 .    \}
-.    if \\n[#PAGE_NUM_H_POS]=2    \{ .CENTER \}
+.    if \\n[#PAGE_NUM_H_POS]=2 .CENTER
 .    if \\n[#RECTO_VERSO]=0 \{\
-.       if \\n[#PAGE_NUM_H_POS]=1 \{ .LEFT   \}
-.       if \\n[#PAGE_NUM_H_POS]=2 \{ .CENTER \}
-.       if \\n[#PAGE_NUM_H_POS]=3 \{ .RIGHT  \}
+.       if \\n[#PAGE_NUM_H_POS]=1 .LEFT
+.       if \\n[#PAGE_NUM_H_POS]=2 .CENTER
+.       if \\n[#PAGE_NUM_H_POS]=3 .RIGHT
 .    \}
 .    nr #PAGENUMBER \\n%+\\n[#PAGE_NUM_ADJ]
 .    if \\n[#EN_FIRST_PAGE] \{\
-.       if \\n[#EN_FIRST_PN] \{ .PAGENUMBER \\n[#EN_FIRST_PN] \}
+.       if \\n[#EN_FIRST_PN] .PAGENUMBER \\n[#EN_FIRST_PN]
 .       rr #EN_FIRST_PAGE
 .    \}
 .    if \\n[#BIB_FIRST_PAGE] \{\
-.       if \\n[#BIB_FIRST_PN] \{ .PAGENUMBER \\n[#BIB_FIRST_PN] \}
+.       if \\n[#BIB_FIRST_PN] .PAGENUMBER \\n[#BIB_FIRST_PN]
 .       rr #BIB_FIRST_PAGE
 .    \}
 .    if \\n[#TOC_FIRST_PAGE] \{\
@@ -12774,16 +11796,15 @@
 .       rr #TOC_FIRST_PAGE
 .    \}
 .    ie \\n[#DRAFT_WITH_PAGENUM] \{\
-.       ie '\\*[$REVISION]'' \{\
+.       ie '\\*[$REVISION]'' \
 .          PRINT "\\*[$DRAFT_STRING]\\*[$DRAFT] / \\n[#PAGENUMBER]"
-.       \}
 .       el \{\
-.          ie '\\*[$DRAFT]'' \{\
+.          ie '\\*[$DRAFT]'' \
 .             PRINT "\\*[$REVISION_STRING] \\*[$REVISION] / \\n[#PAGENUMBER]"
-.          \}
-.          el \{\
-.             PRINT "\\*[$DRAFT_STRING]\\*[$DRAFT], \\*[$REVISION_STRING] 
\\*[$REVISION] / \\n[#PAGENUMBER]"
-.          \}
+.          el \
+.             PRINT \
+"\\*[$DRAFT_STRING]\\*[$DRAFT], \\*[$REVISION_STRING] \\*[$REVISION] / \
+\\n[#PAGENUMBER]"
 .       \}
 .    \}
 .    el \{\
@@ -12806,14 +11827,12 @@
 .             di
 .             PN_WITH_HYPHENS
 .          \}
-.          if '\\*[$PAGENUM_STYLE]'roman' \{\
+.          if '\\*[$PAGENUM_STYLE]'roman' \
+.             PRINT \m[\\*[$PAGENUM_COLOR]]-\|\\n[#PAGENUMBER]\|-
+.          if '\\*[$PAGENUM_STYLE]'alpha' \
 .             PRINT \m[\\*[$PAGENUM_COLOR]]-\|\\n[#PAGENUMBER]\|-
 .          \}
-.          if '\\*[$PAGENUM_STYLE]'alpha' \{\
-.             PRINT "\m[\\*[$PAGENUM_COLOR]]-\|\\n[#PAGENUMBER]\|-"
-.          \}
-.       \}
-.       el \{ .PRINT "\m[\\*[$PAGENUM_COLOR]]\\n[#PAGENUMBER]" \}
+.       el .PRINT \m[\\*[$PAGENUM_COLOR]]\\n[#PAGENUMBER]
 .    \}
 .    ev
 .    nr #DIVER_DEPTH 0
@@ -12826,7 +11845,7 @@
 \# Mom's footnote handling is baroque, to say the least.  There are
 \# redundancies in a number of the macros involved, as well as some
 \# registers that probably don't get used anymore.  The baggage is left
-\# in in case some new footnote oddity/challenge gets thrown my way.
+\# in in case some new footnote oddity/challenge gets thrown at her.
 \# 
 \# The macros are heavily commented.
 \#
@@ -12843,7 +11862,6 @@
 .    nr #FN_AUTOLEAD \\$1
 .END
 \#
-\#
 \# FOOTNOTE MARKERS
 \# ----------------
 \# *Arguments:
@@ -12854,11 +11872,10 @@
 \#   Default is on.
 \#
 .MAC FOOTNOTE_MARKERS END
-.    ie '\\$1'' \{ .nr #FN_MARKERS 1 \}
-.    el \{ .nr #FN_MARKERS 0 \}
+.    ie '\\$1'' .nr #FN_MARKERS 1
+.    el .nr #FN_MARKERS 0
 .END
 \#
-\#
 \# FOOTNOTE MARKER STYLE
 \# ---------------------
 \# *Arguments:
@@ -12877,17 +11894,17 @@
 .             tm1 "[mom]: Your current FOOTNOTE_MARKER STYLE is LINE.
 .             tm1 "       You cannot change footnote marker style without
 .             tm1 "       first breaking to a new page with NEWPAGE.
-.             tm1 "       Ignoring request FOOTNOTE_MARKER_STYLE STAR at line 
\\n(.c.
+.             tm1 "       Ignoring request FOOTNOTE_MARKER_STYLE STAR at line 
\\n[.c].
 .             return
 .          \}
 .       \}
 .       if \\n[#RUN_ON]=1 \{\
-.          tm1 "[mom]: FOOTNOTE_MARKER_STYLE STAR at line \\n(.c is 
incompatible
+.          tm1 "[mom]: FOOTNOTE_MARKER_STYLE STAR at line \\n[.c] is 
incompatible
 .          tm1 "       with RUN_ON footnotes.  Ignoring request.
 .          return
 .       \}
 .       nr #FN_MARKER_STYLE 1
-.       if \\n[#NEWPAGE]=1 \{ .rr #NEWPAGE \}
+.       if \\n[#NEWPAGE]=1 .rr #NEWPAGE
 .       FOOTNOTE_MARKERS
 .    \}
 .    if '\\$1'NUMBER' \{\
@@ -12896,31 +11913,30 @@
 .             tm1 "[mom]: Your current FOOTNOTE_MARKER STYLE is NUMBER.
 .             tm1 "       You cannot change footnote marker style without
 .             tm1 "       first breaking to a new page with NEWPAGE.
-.             tm1 "       Ignoring request FOOTNOTE_MARKER_STYLE NUMBER at 
line \\n(.c.
+.             tm1 "       Ignoring request FOOTNOTE_MARKER_STYLE NUMBER at 
line \\n[.c].
 .             return
 .          \}
 .       \}
 .       if \\n[#RUN_ON]=1 \{\
-.          tm1 "[mom]: FOOTNOTE_MARKER_STYLE NUMBER at line \\n(.c is 
incompatible
+.          tm1 "[mom]: FOOTNOTE_MARKER_STYLE NUMBER at line \\n[.c] is 
incompatible
 .          tm1 "       with RUN_ON footnotes.  Ignoring request.
 .          return
 .       \}
 .       nr #FN_MARKER_STYLE 2
 .       shift
-.       if '\\$1'NO_SUPERSCRIPT' \{ .nr #NO_SUPERSCRIPT 1 \}
-.       if \\n[#NEWPAGE]=1 \{ .rr #NEWPAGE \}
+.       if '\\$1'NO_SUPERSCRIPT' .nr #NO_SUPERSCRIPT 1
+.       if \\n[#NEWPAGE]=1 .rr #NEWPAGE
 .       FOOTNOTE_MARKERS
 .    \}
 .    if '\\$1'LINE' \{\
 .       nr #FN_MARKER_STYLE 3
 .       FOOTNOTE_MARKERS OFF
 .       if !\\n[#FN_LN_SEP] \{\
-.          if !\\n[#FN_LN_BRACKETS] \{ .FOOTNOTE_LINENUMBER_BRACKETS SQUARE \}
+.          if !\\n[#FN_LN_BRACKETS] .FOOTNOTE_LINENUMBER_BRACKETS SQUARE
 .       \}
 .    \}
 .END
 \#
-\#
 \# FOOTNOTE NUMBER PLACEHOLDERS
 \# ----------------------------
 \# *Argument:
@@ -12936,15 +11952,13 @@
 .    nr #FN_NUMBER_PLACEHOLDERS \\$1
 .END
 \#   
-\#   
 \# FOOTNOTE LINENUMBER MARK
 \# ------------------------
 \# *Function:
 \#   This string, when called inline, stores the current output line
 \#   number in register #FN_MARK for use with FOOTNOTE.
 \#
-.ds FN_MARK \R'#FN_MARK \En(ln'
-\#
+.ds FN_MARK \R'#FN_MARK \En[ln]'
 \#
 \# FOOTNOTE LINENUMBER SEPARATOR
 \# -----------------------------
@@ -12963,7 +11977,6 @@
 .    ds $FN_LN_SEP "\\$1
 .END
 \#
-\#
 \# FOOTNOTE LINENUMBER BRACKETS
 \# ----------------------------
 \# *Argument:
@@ -13002,7 +12015,6 @@
 .    \}
 .END
 \#
-\#
 \# RESET FOOTNOTE NUMBER
 \# ---------------------
 \# *Arguments:
@@ -13013,11 +12025,10 @@
 \#   numbered footnotes on every page start at 1.
 \#
 .MAC RESET_FOOTNOTE_NUMBER END
-.    ie '\\$1'' \{ .nr #FN_NUMBER 0 1 \}
-.    el \{ .nr #RESET_FN_NUMBER 1 \}
+.    ie '\\$1'' .nr #FN_NUMBER 0 1
+.    el .nr #RESET_FN_NUMBER 1
 .END
 \#
-\#
 \# FOOTNOTE RULE LENGTH
 \# --------------------
 \# *Arguments:
@@ -13032,7 +12043,6 @@
 .    nr #FN_RULE_LENGTH (\\$1)
 .END
 \#
-\#
 \# FOOTNOTE_RULE_ADJ
 \# -----------------
 \# *Arguments:
@@ -13048,7 +12058,6 @@
 .    nr #FN_RULE_ADJ (\\$1)
 .END
 \#
-\#
 \# FOOTNOTE RULE
 \# -------------
 \# *Arguments:
@@ -13064,7 +12073,7 @@
 \#
 .MAC FOOTNOTE_RULE END
 .    ie '\\$0'PRINT_FOOTNOTE_RULE' \{\
-.       if \\n[#FN_RULE]=0 \{ .RLD 1v \}
+.       if \\n[#FN_RULE]=0 .RLD 1v
 .       RLD 1v
 .       LEFT
 \v'-\\n[#FN_RULE_ADJ]u-\\n[#FN_RULE_WEIGHT_ADJ]u'\
@@ -13076,12 +12085,11 @@
 .       QUAD \\*[$FN_QUAD]
 .    \}
 .    el \{\
-.       ie '\\$1'' \{ .nr #FN_RULE 1 \}
-.       el \{ .nr #FN_RULE 0 \}
+.       ie '\\$1'' .nr #FN_RULE 1
+.       el .nr #FN_RULE 0
 .    \}
 .END
 \#
-\#
 \# FOOTNOTE SPACING
 \# ----------------
 \# *Arguments:
@@ -13093,10 +12101,9 @@
 \#
 .MAC FOOTNOTE_SPACING END
 .    ie \B'\\$1' .ds $FN_SPACE \\$1
-.    el \{ .rm $FN_SPACE \}
+.    el .rm $FN_SPACE
 .END
 \#
-\#
 \# RUN ON FOOTNOTES
 \# ----------------
 \# *Arguments:
@@ -13107,20 +12114,20 @@
 .MAC FOOTNOTES_RUN_ON END
 .    ie '\\$1'' \{\
 .       if \\n[#FN_COUNT]>0 \{\
-.          tm1 "[mom]: Switching to run-on footnotes at line \\n(.c will cause
+.          tm1 "[mom]: Switching to run-on footnotes at line \\n[.c] will cause
 .          tm1 "       you to loose footnotes already formatted for this page.
 .          tm1 "       Ignoring request FOOTNOTES_RUN_ON.
 .          rr #RUN_ON
 .          return
 .       \}
 .       nr #RUN_ON 1
-.       if \\n[#FN_MARKER_STYLE]=1 \{ .RUNON_WARNING \}
-.       if \\n[#FN_MARKER_STYLE]=2 \{ .RUNON_WARNING \}
+.       if \\n[#FN_MARKER_STYLE]=1 .RUNON_WARNING
+.       if \\n[#FN_MARKER_STYLE]=2 .RUNON_WARNING
 .    \}
 .    el \{\
 .       if \\n[#FN_COUNT]>0 \{\
 .          if \\n[#RUN_ON]=1 \{\
-.             tm1 "[mom]: Switching off run-on footnotes at line \\n(.c will 
cause
+.             tm1 "[mom]: Switching off run-on footnotes at line \\n[.c] will 
cause
 .             tm1 "       you to loose footnotes already formatted for this 
page.
 .             tm1 "       Ignoring request FOOTNOTES_RUN_ON \\$1.
 .             return
@@ -13130,17 +12137,16 @@
 .    \}
 .END
 \#
-\#
 .MAC RUNON_WARNING END
 .    if \\n[#FN_MARKER_STYLE]=1 \{\
-.       tm1 "[mom]: The footnote marker style active at line \\n(.c is STAR,
+.       tm1 "[mom]: The footnote marker style active at line \\n[.c] is STAR,
 .       tm1 "       which is incompatible with run-on footnotes.  Please change
 .       tm1 "       the footnote marker style to LINE.  Continuing to process,
 .       tm1 "       but ignoring request FOOTNOTES_RUN_ON.
 .       rr #RUN_ON
 .    \}
 .    if \\n[#FN_MARKER_STYLE]=2 \{\
-.       tm1 "[mom]: The footnote marker style active at line \\n(.c is NUMBER,
+.       tm1 "[mom]: The footnote marker style active at line \\n[.c] is NUMBER,
 .       tm1 "       which is incompatible with run-on footnotes.  Please change
 .       tm1 "       the footnote marker style to LINE.  Continuing to process,
 .       tm1 "       but ignoring request FOOTNOTES_RUN_ON.
@@ -13176,31 +12182,31 @@
 .          if !\\n[#LINENUMBERS] \{\
 .             tm1 "[mom]: Line numbering must be enabled with NUMBER_LINES when
 .             tm1 "       FOOTNOTE_MARKER_STYLE is LINE.
-.             ab Aborting on FOOTNOTE at line \\n(.c.
+.             ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
 .          \}
-.          if \\n[#FN_MARK]=0 \{ .nr #FN_MARK \\n(ln \}
-.          nr #FN_MARK_2 \\n(ln
-.          if '\\n(.z'P_QUOTE' \{\
+.          if \\n[#FN_MARK]=0 .nr #FN_MARK \\n[ln]
+.          nr #FN_MARK_2 \\n[ln]
+.          if '\\n[.z]'P_QUOTE' \{\
 .             nr #FN_MARK -1
 .             nr #FN_MARK_2 -1
 .          \}
 .          if \\n[#IN_DIVER]=1 \{\
-.             if '\\n(.z'P_QUOTE' \{\
+.             if '\\n[.z]'P_QUOTE' \{\
 .                if !\\n[#QUOTE_LN]=1 \{\
 .                   if !\\n[#SILENT_QUOTE_LN]=1 \{\
 .                      tm1 "[mom]: You have requested a line-numbered footnote 
inside a
-.                      tm1 "       QUOTE at line \\n(.c, but line-numbering 
has not been enabled
+.                      tm1 "       QUOTE at line \\n[.c], but line-numbering 
has not been enabled
 .                      tm1 "       for QUOTES.  Printing footnote with label 
"0".
 .                      rr #FN_MARK
 .                      rr #FN_MARK_2
 .                   \}
 .                \}
 .             \}
-.             if '\\n(.z'B_QUOTE' \{\
+.             if '\\n[.z]'B_QUOTE' \{\
 .                if !\\n[#BQUOTE_LN]=1 \{\
 .                   if !\\n[#SILENT_BQUOTE_LN]=1 \{\
 .                      tm1 "[mom]: You have requested a line-numbered footnote 
inside a
-.                      tm1 "       BLOCKQUOTE at line \\n(.c, but 
line-numbering has not been enabled
+.                      tm1 "       BLOCKQUOTE at line \\n[.c], but 
line-numbering has not been enabled
 .                      tm1 "       for BLOCKQUOTES.  Printing footnote with 
label "0".
 .                      rr #FN_MARK
 .                      rr #FN_MARK_2
@@ -13212,34 +12218,31 @@
 .\" Begin processing footnotes that occur inside QUOTE, BLOCKQUOTE
 .\" or EPIGRAPH.
 .       if \\n[#IN_DIVER]=1 \{\
-.          nr #PAGE_POS \\n(nl+\\n(.d+\\n[#DOC_LEAD]
+.          nr #PAGE_POS \\n[nl]+\\n[.d]+\\n[#DOC_LEAD]
 .          nr #FOOTER_POS \\n[#PAGE_LENGTH]+(\\n[#VARIABLE_FOOTER_POS]-1)
 .          nr #SPACE_TO_FOOTER \\n[#FOOTER_POS]-\\n[#PAGE_POS]
 .\" Are we on a "defer" line?  If so, defer the text of the footnote.
-.          ie \\n[#SPACE_TO_FOOTER]=\\n[#DOC_LEAD]:\\n[#SPACE_TO_FOOTER]=0 \{\
+.          ie \\n[#SPACE_TO_FOOTER]=\\n[#DOC_LEAD]:\\n[#SPACE_TO_FOOTER]=0 \
 .             nr #DIVER_FN 2 \" treat like a normal deferred footnote
-.          \}
-.          el \{\
+.          el \
 .             nr #DIVER_FN 2 \" treat like a normal footnote
-.          \}
-.          if \\n[#PAGE_POS]>\\n[#FOOTER_POS] \{\
+.          if \\n[#PAGE_POS]>\\n[#FOOTER_POS] \
 .             nr #DIVER_FN 1 \" move this footnote
-.          \}
 .\" Test for situation where, because a final line of QUOTE, BLOCKQUOTE
 .\" or EPIGRAPH isn't yet adjusted at this point, the last word on the
 .\" line may *seem* to belong to the final line of the page, but will,
 .\" in fact, become the first word of the subsequent page.  In such
 .\" circumstances, we want the the footnote to be treated as a "moved"
 .\" diversion footnote.
-.          if \\n(.k>\\n(.l \{ .nr #DIVER_FN 1 \}
-.          if r#DIVER_FN \{\
-.             if !\\n[#DIVER_FN]=2 \{ .\\n+[#DONE_ONCE] \}
+.          if \\n[.k]>\\n[.l] .nr #DIVER_FN 1
+.          if r #DIVER_FN \{\
+.             if !\\n[#DIVER_FN]=2 .\\n+[#DONE_ONCE]
 .\" A footnote inside a diversion will become the 1st footnote on the
 .\" following page/column.
-.             if \\n[#DIVER_FN]=1 \{ .DIVER_FN_1_PRE \}
+.             if \\n[#DIVER_FN]=1 .DIVER_FN_1_PRE
 .\" A footnote inside a diversion that should be treated like a
 .\" normal footnote (including defers.)
-.             if \\n[#DIVER_FN]=2 \{ .DIVER_FN_2_PRE \}
+.             if \\n[#DIVER_FN]=2 .DIVER_FN_2_PRE
 .          \}
 .          nr #SAVED_FN_COUNT \\n[#FN_COUNT]+1
 .          nr #SAVED_FN_COUNT_FOR_COLS \\n[#FN_COUNT_FOR_COLS]+1
@@ -13253,13 +12256,11 @@
 .\" fact, become the first word of the subsequent page.  In such
 .\" circumstances, we want the the footnote marker in running text to
 .\" be the correct one for the 1st footnote on the page.
-.       if \\n(.k>\\n(.l \{\
-.          if 
(\\n(nl+\\n[#DOC_LEAD])>(\\n[#PAGE_LENGTH]+\\n[#VARIABLE_FOOTER_POS]) \{\
+.       if \\n[.k]>\\n[.l] \{\
+.          if 
(\\n[nl]+\\n[#DOC_LEAD])>(\\n[#PAGE_LENGTH]+\\n[#VARIABLE_FOOTER_POS]) \{\
 .             ie \\n[#COLUMNS]=1 \{\
 .                if \\n[#COL_NUM]=\\n[#NUM_COLS] \{\
-.                   if \\n[#FN_MARKER_STYLE]=1 \{\
-.                      nr #FN_COUNT_FOR_COLS 0 1
-.                   \}
+.                   if \\n[#FN_MARKER_STYLE]=1 .nr #FN_COUNT_FOR_COLS 0 1
 .                   if \\n[#FN_MARKER_STYLE]=2 \{\
 .                      if \\n[#RESET_FN_NUMBER] \{\
 .                         nr #FN_NUMBER 0 1
@@ -13269,9 +12270,7 @@
 .                \}
 .             \}
 .             el \{\
-.                if \\n[#FN_MARKER_STYLE]=1 \{\
-.                   nr #FN_COUNT 0 1
-.                \}
+.                if \\n[#FN_MARKER_STYLE]=1 .nr #FN_COUNT 0 1
 .                if \\n[#FN_MARKER_STYLE]=2 \{\
 .                   if \\n[#RESET_FN_NUMBER] \{\
 .                      nr #FN_NUMBER 0 1
@@ -13283,8 +12282,8 @@
 .       \}
 .       if \\n[#FN_MARKERS] \{\
 .\" Housekeeping
-.          if \\n[#CONDENSE] \{ \*[CONDX]\c \}
-.          if \\n[#EXTEND]   \{ \*[EXTX]\c  \}
+.          if \\n[#CONDENSE] \*[CONDX]\c
+.          if \\n[#EXTEND] \*[EXTX]\c
 .\" Add footnote markers to running text...
 .          if !\\n[#NO_FN_MARKER] \{\
 .\" ...but not if TERMINATE has not been called
@@ -13297,34 +12296,38 @@
 .\" above footnotes (in addition to keeping track of the footnote
 .\" count in non-columnar docs).
 .                   ie \\n[#COLUMNS]=1 \{\
-.                      if \\n[#FN_COUNT_FOR_COLS]=0 \{ .PRINT \*[BU2]*\c       
     \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=1 \{ .PRINT \*[BU1]\(dg\c    
     \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=2 \{ .PRINT \(dd\c           
     \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=3 \{ .PRINT \*[BU2]**\c      
     \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=4 \{ .PRINT 
\*[BU1]\(dg\(dg\c     \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=5 \{ .PRINT \(dd\(dd\c       
     \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=6 \{ .PRINT \*[BU2]***\c     
     \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=7 \{ .PRINT 
\*[BU1]\(dg\(dg\(dg\c \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=8 \{ .PRINT \(dd\(dd\(dd\c   
     \}
-.                      if \\n[#FN_COUNT_FOR_COLS]=9 \{ .PRINT \*[BU2]****\c    
     \}
-.                   \}
-.                   el \{\
-.                      if \\n[#FN_COUNT]=0 \{ .PRINT \*[BU2]*\c            \}
-.                      if \\n[#FN_COUNT]=1 \{ .PRINT \*[BU1]\(dg\c         \}
-.                      if \\n[#FN_COUNT]=2 \{ .PRINT \(dd\c                \}
-.                      if \\n[#FN_COUNT]=3 \{ .PRINT \*[BU2]**\c           \}
-.                      if \\n[#FN_COUNT]=4 \{ .PRINT \*[BU1]\(dg\(dg\c     \}
-.                      if \\n[#FN_COUNT]=5 \{ .PRINT \(dd\(dd\c            \}
-.                      if \\n[#FN_COUNT]=6 \{ .PRINT \*[BU2]***\c          \}
-.                      if \\n[#FN_COUNT]=7 \{ .PRINT \*[BU1]\(dg\(dg\(dg\c \}
-.                      if \\n[#FN_COUNT]=8 \{ .PRINT \(dd\(dd\(dd\c        \}
-.                      if \\n[#FN_COUNT]=9 \{ .PRINT \*[BU2]****\c         \}
+.                      if \\n[#FN_COUNT_FOR_COLS]=0 .PRINT \*[BU2]*\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=1 .PRINT \*[BU1]\[dg]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=2 .PRINT \[dd]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=3 .PRINT \*[BU2]**\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=4 .PRINT \*[BU1]\[dg]\[dg]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=5 .PRINT \[dd]\[dd]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=6 .PRINT \*[BU2]***\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=7 .PRINT 
\*[BU1]\[dg]\[dg]\[dg]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=8 .PRINT \[dd]\[dd]\[dd]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=9 .PRINT \*[BU2]****\c
+.                   \}
+.                   el \{\
+.                      if \\n[#FN_COUNT]=0 .PRINT \*[BU2]*\c
+.                      if \\n[#FN_COUNT]=1 .PRINT \*[BU1]\[dg]\c
+.                      if \\n[#FN_COUNT]=2 .PRINT \[dd]\c
+.                      if \\n[#FN_COUNT]=3 .PRINT \*[BU2]**\c
+.                      if \\n[#FN_COUNT]=4 .PRINT \*[BU1]\[dg]\[dg]\c
+.                      if \\n[#FN_COUNT]=5 .PRINT \[dd]\[dd]\c
+.                      if \\n[#FN_COUNT]=6 .PRINT \*[BU2]***\c
+.                      if \\n[#FN_COUNT]=7 .PRINT \*[BU1]\[dg]\[dg]\[dg]\c
+.                      if \\n[#FN_COUNT]=8 .PRINT \[dd]\[dd]\[dd]\c
+.                      if \\n[#FN_COUNT]=9 .PRINT \*[BU2]****\c
 .                   \}
 .                \}
 .\" Marker style superscript numbers
 .                if \\n[#FN_MARKER_STYLE]=2 \{\
-.                   if \\n[#PRINT_STYLE]=1 \{ .PRINT 
"\s-2\v'-\\n[#DOC_LEAD]u/5u'\\n+[#FN_NUMBER]\v'+\\n[#DOC_LEAD]u/5u'\s+2\c" \}
-.                   if \\n[#PRINT_STYLE]=2 \{ .PRINT 
"\*[SUP]\\n+[#FN_NUMBER]\*[SUPX]\c" \}
+.                   if \\n[#PRINT_STYLE]=1 \
+.                      PRINT \
+"\s-2\v'-\\n[#DOC_LEAD]u/5u'\\n+[#FN_NUMBER]\v'+\\n[#DOC_LEAD]u/5u'\s+2\c"
+.                   if \\n[#PRINT_STYLE]=2 \
+.                      PRINT \
+"\*[SUP]\\n+[#FN_NUMBER]\*[SUPX]\c"
 .                \}
 .             \}
 .          \}
@@ -13335,35 +12338,33 @@
 .\" on the page and the bottom margin.  It's used to determine whether
 .\" or not the footnote will overflow, and how many lines of
 .\" footnotes will fit on the page if some have to overflow.
-.       ie \\n[#DIVER_FN]=2 \{\
+.       ie \\n[#DIVER_FN]=2 \
 .          nr #SPACE_REMAINING 
(\\n[#PAGE_LENGTH]-\\n[#B_MARGIN])-(\\n[#PAGE_POS])
-.       \}
-.       el \{\
-.          nr #SPACE_REMAINING (\\n[#PAGE_LENGTH]-\\n[#B_MARGIN])-\\n(nl
-.       \}
+.       el \
+.          nr #SPACE_REMAINING (\\n[#PAGE_LENGTH]-\\n[#B_MARGIN])-\\n[nl]
 .       if \\n[#FROM_DIVERT_FN]=1 \{\
 .          nr #SPACE_REMAINING \\n[#PAGE_LENGTH]-\\n[#B_MARGIN]
 .          rr #FROM_DIVERT_FN
 .       \}
 .       nr #PP_STYLE_PREV \\n[#PP_STYLE]
 .       nr #PP_STYLE 2
-.       if \\n[#INDENT_FIRST_PARAS] \{ .nr #INDENT_FIRSTS 1 \}
+.       if \\n[#INDENT_FIRST_PARAS] .nr #INDENT_FIRSTS 1
 .       INDENT_FIRST_PARAS
 .\" Prepare FOOTNOTE to receive footnote text.
 .       ev FOOTNOTES
 .       ll \\n[#DOC_L_LENGTH]u
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .       if \\n[#COLUMNS]=1 \{\
 .          ll \\n[#COL_L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .       if \\n[#FN_R_INDENT]  \{\
 .          ll -\\n[#FN_R_INDENT]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .       if \\n[#FN_BR_INDENT] \{\
 .          ll -\\n[#FN_BR_INDENT]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .       FAMILY   \\*[$FN_FAM]
 .       FT       \\*[$FN_FT]
@@ -13372,8 +12373,8 @@
 .       QUAD     \\*[$FN_QUAD]
 .       if \\n[#PRINT_STYLE]=1 \{\
 .          TYPEWRITER
-.          ie \\n[#SINGLE_SPACE] \{ .vs \\n[#ORIGINAL_DOC_LEAD]u \}
-.          el \{ .vs \\n[#ORIGINAL_DOC_LEAD]u/2u \}
+.          ie \\n[#SINGLE_SPACE] .vs \\n[#ORIGINAL_DOC_LEAD]u
+.          el .vs \\n[#ORIGINAL_DOC_LEAD]u/2u
 .          QUAD LEFT
 .          HY OFF
 .       \}
@@ -13385,14 +12386,14 @@
 .                di RUNON_FN_IN_DIVER
 .                nr #RUNON_FN_IN_DIVER 1
 .             \}
-.             el \{ .di FN_IN_DIVER \}
+.             el .di FN_IN_DIVER
 .          \}
 .          el \{\
 .             ie \\n[#RUN_ON] \{\
 .                da RUNON_FN_IN_DIVER
 .                nr #RUNON_FN_IN_DIVER 1
 .             \}
-.             el \{ .da FN_IN_DIVER \}
+.             el .da FN_IN_DIVER
 .          \}
 .       \\n+[#DONE_ONCE]
 .       \}
@@ -13401,7 +12402,7 @@
 .             da RUNON_FOOTNOTES
 .             nr #RUNON_FOOTNOTES 1
 .          \}
-.          el \{ .da FOOTNOTES \}
+.          el .da FOOTNOTES
 .       \}
 .       if \\n[#FOOTNOTE_COLOR]=1 \{\
 .          TRAP OFF
@@ -13411,7 +12412,7 @@
 .          fi
 .          TRAP
 .       \}
-.       if \\n[#EPIGRAPH] \{ .nr #FN_FOR_EPI 1 \}
+.       if \\n[#EPIGRAPH] .nr #FN_FOR_EPI 1
 .\" When a deferred footnote is also the 1st footnote on the page,
 .\" and when the page it's output on also has footnotes, some
 .\" whitespace is needed between the deferred footnote and the
@@ -13426,8 +12427,8 @@
 .\" ...and not if the footnote count the last time we checked for
 .\" a defer situation inside a diversion is greater than 1.
 .                if !\\n[#SAVED_DIVER_FN_COUNT]>1 \{\
-.                   if \\n[#FN_MARKER_STYLE]=1 \{ .ALD 1v \}
-.                   if \\n[#RESET_FN_NUMBER] \{ .ALD 1v \}
+.                   if \\n[#FN_MARKER_STYLE]=1 .ALD 1v
+.                   if \\n[#RESET_FN_NUMBER] .ALD 1v
 .                   nr #DEFER_SPACE_ADDED 1
 .                \}
 .             \}
@@ -13450,16 +12451,16 @@
 .          if !\\n[#DONT_RULE_ME]=1 \{\
 .             if !\\n[#FN_DEPTH] \{\
 .                if \\n[#PRINT_STYLE]=1 \{\
-.                   if !\\n[#RUN_ON] \{ .sp \\n[#DOC_LEAD]u \}
+.                   if !\\n[#RUN_ON] .sp \\n[#DOC_LEAD]u
 .                \}
 .                ie \\n[#FN_RULE]=1 \{\
 .                   if !\\n[#RUN_ON] \{\
-.                      if \\n[#SINGLE_SPACE] \{ .sp \\n[#DOC_LEAD]u \}
+.                      if \\n[#SINGLE_SPACE] .sp \\n[#DOC_LEAD]u
 .                      PRINT_FOOTNOTE_RULE
-.                      if !'\\*[$FN_SPACE]'' \{ .sp -\\*[$FN_SPACE] \}
+.                      if !'\\*[$FN_SPACE]'' .sp -\\*[$FN_SPACE]
 .                   \}
 .                \}
-.                el \{ .sp 1v \}
+.                el .sp 1v
 .                nr #RULED 1
 .             \}
 .          \}
@@ -13484,28 +12485,28 @@
 .                if \\n[#FN_MARKER_STYLE]=1 \{\
 .                   ie \\n[#COLUMNS]=1 \{\
 .                      \\n+[#FN_COUNT_FOR_COLS]
-.                      if \\n[#FN_COUNT_FOR_COLS]=1  \{ .PRINT *\c            
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=2  \{ .PRINT \(dg\c         
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=3  \{ .PRINT \(dd\c         
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=4  \{ .PRINT **\c           
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=5  \{ .PRINT \(dg\(dg\c     
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=6  \{ .PRINT \(dd\(dd\c     
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=7  \{ .PRINT ***\c          
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=8  \{ .PRINT \(dg\(dg\(dg\c 
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=9  \{ .PRINT \(dd\(dd\(dd\c 
\}
-.                      if \\n[#FN_COUNT_FOR_COLS]=10 \{ .PRINT ****\c         
\}
-.                   \}
-.                   el \{\
-.                      if \\n[#FN_COUNT]=1  \{ .PRINT *\c            \}
-.                      if \\n[#FN_COUNT]=2  \{ .PRINT \(dg\c         \}
-.                      if \\n[#FN_COUNT]=3  \{ .PRINT \(dd\c         \}
-.                      if \\n[#FN_COUNT]=4  \{ .PRINT **\c           \}
-.                      if \\n[#FN_COUNT]=5  \{ .PRINT \(dg\(dg\c     \}
-.                      if \\n[#FN_COUNT]=6  \{ .PRINT \(dd\(dd\c     \}
-.                      if \\n[#FN_COUNT]=7  \{ .PRINT ***\c          \}
-.                      if \\n[#FN_COUNT]=8  \{ .PRINT \(dg\(dg\(dg\c \}
-.                      if \\n[#FN_COUNT]=9  \{ .PRINT \(dd\(dd\(dd\c \}
-.                      if \\n[#FN_COUNT]=10 \{ .PRINT ****\c         \}
+.                      if \\n[#FN_COUNT_FOR_COLS]=1 .PRINT *\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=2 .PRINT \[dg]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=3 .PRINT \[dd]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=4 .PRINT **\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=5 .PRINT \[dg]\[dg]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=6 .PRINT \[dd]\[dd]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=7 .PRINT ***\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=8 .PRINT \[dg]\[dg]\[dg]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=9 .PRINT \[dd]\[dd]\[dd]\c
+.                      if \\n[#FN_COUNT_FOR_COLS]=10 .PRINT ****\c
+.                   \}
+.                   el \{\
+.                      if \\n[#FN_COUNT]=1 .PRINT *\c
+.                      if \\n[#FN_COUNT]=2 .PRINT \[dg]\c
+.                      if \\n[#FN_COUNT]=3 .PRINT \[dd]\c
+.                      if \\n[#FN_COUNT]=4 .PRINT **\c
+.                      if \\n[#FN_COUNT]=5 .PRINT \[dg]\[dg]\c
+.                      if \\n[#FN_COUNT]=6 .PRINT \[dd]\[dd]\c
+.                      if \\n[#FN_COUNT]=7 .PRINT ***\c
+.                      if \\n[#FN_COUNT]=8 .PRINT \[dg]\[dg]\[dg]\c
+.                      if \\n[#FN_COUNT]=9 .PRINT \[dd]\[dd]\[dd]\c
+.                      if \\n[#FN_COUNT]=10 .PRINT ****\c
 .                   \}
 .                \}
 .                if \\n[#FN_MARKER_STYLE]=2 \{\
@@ -13520,42 +12521,36 @@
 .                   \}
 .                   if \\n[#PRINT_STYLE]=1 \{\
 .                      ie \\n[#NO_SUPERSCRIPT] \{\
-.                         ie 
\\n[#FN_NUMBER_LENGTH]<\\n[#FN_NUMBER_PLACEHOLDERS] \{\
+.                         ie 
\\n[#FN_NUMBER_LENGTH]<\\n[#FN_NUMBER_PLACEHOLDERS] \
 .                            PRINT "\0(\\n[#FN_NUMBER])\|\c"
-.                         \}
-.                         el \{\
+.                         el \
 .                            PRINT "(\\n[#FN_NUMBER])\|\c"
 .                         \}
-.                      \}
-.                      el \{\
-.                         ie 
\\n[#FN_NUMBER_LENGTH]<\\n[#FN_NUMBER_PLACEHOLDERS] \{\
-.                            PRINT 
"\s-2\v'-\\n[.v]u/5u'\0\\n[#FN_NUMBER]\|\v'+\\n[.v]u/5u'\s+2\|\c"
-.                         \}
 .                         el \{\
-.                            PRINT 
"\s-2\v'-\\n[.v]u/5u'\\n[#FN_NUMBER]\|\v'+\\n[.v]u/5u'\s+2\|\c"
-.                         \}
+.                         ie 
\\n[#FN_NUMBER_LENGTH]<\\n[#FN_NUMBER_PLACEHOLDERS] \
+.                            PRINT \
+"\s-2\v'-\\n[.v]u/5u'\0\\n[#FN_NUMBER]\|\v'+\\n[.v]u/5u'\s+2\|\c"
+.                         el \
+.                            PRINT \
+"\s-2\v'-\\n[.v]u/5u'\\n[#FN_NUMBER]\|\v'+\\n[.v]u/5u'\s+2\|\c"
 .                      \}
 .                   \}
 .                   if \\n[#PRINT_STYLE]=2 \{\
-.                      ie \\n[#FN_NUMBER_LENGTH]<\\n[#FN_NUMBER_PLACEHOLDERS] 
\{\
+.                      ie \\n[#FN_NUMBER_LENGTH]<\\n[#FN_NUMBER_PLACEHOLDERS] \
 .                         PRINT "\*[SUP]\0\\n[#FN_NUMBER]\*[SUPX]\*[FU 3]\c"
-.                      \}
-.                      el \{\
+.                      el \
 .                         PRINT "\*[SUP]\\n[#FN_NUMBER]\*[SUPX]\*[FU 3]\c"
 .                      \}
 .                   \}
 .                \}
 .             \}
 .          \}
-.       \}
 .       el \{\
 .\" Line-numbered footnotes handling
 .          if \\n[#FN_MARKER_STYLE]=3 \{\
 .             if \\n[#FN_SPACE]>0 \{\
 .                if !\\n[#RUN_ON]=1 \{\
-.                   if \\n[#FN_COUNT]>0 \{\
-.                      ALD \\n[#FN_SPACE]u
-.                   \}
+.                   if \\n[#FN_COUNT]>0 .ALD \\n[#FN_SPACE]u
 .                \}
 .             \}
 .             if \\n[#REF]=1 \{\
@@ -13565,24 +12560,24 @@
 .             \}
 .             ie \\n[#FN_LN_BRACKETS]=1 \{\
 .                ds $FN_LINENUMBER \v'-.085m'\\*[$FN_OPEN_BRACKET]\v'.085m'
-.                ie \\n[#FN_MARK_2]=\\n[#FN_MARK] \{\
-.                   as $FN_LINENUMBER 
\\n[#FN_MARK]\v'-.085m'\\*[$FN_CLOSE_BRACKET]\v'.085m'\h'.25m'
-.                \}
-.                el \{\
-.                   as $FN_LINENUMBER 
\\n[#FN_MARK]\v'-.1m'-\v'.1m'\\n[#FN_MARK_2]\v'-.085m'\\*[$FN_CLOSE_BRACKET]\v'.085m'\h'.25m'
-.                \}
+.                ie \\n[#FN_MARK_2]=\\n[#FN_MARK] \
+.                   as $FN_LINENUMBER \
+\\n[#FN_MARK]\v'-.085m'\\*[$FN_CLOSE_BRACKET]\v'.085m'\h'.25m'
+.                el \
+.                   as $FN_LINENUMBER \
+\\n[#FN_MARK]\v'-.1m'-\v'.1m'\\n[#FN_MARK_2]\v'-.085m'\
+\\*[$FN_CLOSE_BRACKET]\v'.085m'\h'.25m'
 .             \}
 .             el \{\
-.                ie \\n[#FN_MARK_2]=\\n[#FN_MARK] \{\
+.                ie \\n[#FN_MARK_2]=\\n[#FN_MARK] \
 .                   ds $FN_LINENUMBER \\n[#FN_MARK]\\*[$FN_LN_SEP]
-.                \}
-.                el \{\
-.                   ds $FN_LINENUMBER 
\\n[#FN_MARK]\v'-.1m'-\v'.1m'\\n[#FN_MARK_2]\\*[$FN_LN_SEP]
+.                el \
+.                   ds $FN_LINENUMBER \
+\\n[#FN_MARK]\v'-.1m'-\v'.1m'\\n[#FN_MARK_2]\\*[$FN_LN_SEP]
 .                \}
 .             \}
-.             if !\\n[#NO_FN_MARKER] \{\
+.             if !\\n[#NO_FN_MARKER] \
 .                PRINT \\*[$FN_LINENUMBER]\c
-.             \}
 .             rm $FN_LINENUMBER
 .             nr #FN_MARK 0
 .          \}
@@ -13592,20 +12587,20 @@
 .\" If INDENT arg is passed to FOOTNOTE, calculate the indent...
 .       ie '\\$1'INDENT' \{\
 .          ev FOOTNOTES
-.          if '\\$2'L'     \{ .in (\\$3)  \}
-.          if '\\$2'LEFT'  \{ .in (\\$3)  \}
-.          if '\\$2'R'     \{ .nr #FN_R_INDENT (\\$3) \}
-.          if '\\$2'RIGHT' \{ .nr #FN_R_INDENT (\\$3) \}
+.          if '\\$2'L' .in (\\$3)
+.          if '\\$2'LEFT' .in (\\$3)
+.          if '\\$2'R' .nr #FN_R_INDENT (\\$3)
+.          if '\\$2'RIGHT' .nr #FN_R_INDENT (\\$3)
 .          if '\\$2'B' \{\
 .             nr #FN_BL_INDENT (\\$3)
-.             ie '\\$4'' \{ .nr #FN_BR_INDENT \\n[#FN_BL_INDENT] \}
-.             el \{ .nr #FN_BR_INDENT (\\$4) \}
+.             ie '\\$4'' .nr #FN_BR_INDENT \\n[#FN_BL_INDENT]
+.             el .nr #FN_BR_INDENT (\\$4)
 .             in \\n[#FN_BL_INDENT]u
 .          \}
 .          if '\\$2'BOTH' \{\
 .             nr #FN_BL_INDENT (\\$3)
-.             ie '\\$4'' \{ .nr #FN_BR_INDENT \\n[#FN_BL_INDENT] \}
-.             el \{ .nr #FN_BR_INDENT (\\$4) \}
+.             ie '\\$4'' .nr #FN_BR_INDENT \\n[#FN_BL_INDENT]
+.             el .nr #FN_BR_INDENT (\\$4)
 .             in \\n[#FN_BL_INDENT]u
 .          \}
 .          ev
@@ -13619,8 +12614,8 @@
 .\" footnote but it's really an overflow).
 .          if \\n[#DIVERTED] \{\
 .             if \\n[#PREV_FN_DEFERRED]=1 \{\
-.                if \\n[#FN_MARKER_STYLE]=1 \{ .ALD \\n[#FN_LEAD]u \}
-.                if \\n[#RESET_FN_NUMBER] \{ .ALD \\n[#FN_LEAD]u \}
+.                if \\n[#FN_MARKER_STYLE]=1 .ALD \\n[#FN_LEAD]u
+.                if \\n[#RESET_FN_NUMBER] .ALD \\n[#FN_LEAD]u
 .                nr #PREV_FN_DEFERRED 2
 .             \}
 .          \}
@@ -13641,21 +12636,19 @@
 .          \}
 .\" Restore sentence spacing
 .          if \\n[#PRINT_STYLE]=2 \{\
-.             if d $RESTORE_SS_VAR \{ .SS \\*[$RESTORE_SS_VAR] \}
+.             if d $RESTORE_SS_VAR    .SS \\*[$RESTORE_SS_VAR]
 .             rm $RESTORE_SS_VAR
 .          \}
 .          rr #FN_R_INDENT
 .          rr #FN_BR_INDENT
 .          nr #PP_STYLE \\n[#PP_STYLE_PREV]
-.          if !\\n[#INDENT_FIRSTS] \{ .INDENT_FIRST_PARAS OFF \}
+.          if !\\n[#INDENT_FIRSTS] .INDENT_FIRST_PARAS OFF
 .          rr #INDENT_FIRSTS
 .\" Calculate footnote depth, but not if #COUNTERS_RESET (created in
 .\" DIVER_FN_1_PRE) to instruct FOOTNOTES to skip this step for now
 .\" (it's taken care of when FN_IN_DIVER is output into FOOTNOTES in
 .\" PROCESS_FN_IN_DIVER).
-.          ie r#COUNTERS_RESET \{\
-.             rr #COUNTERS_RESET
-.          \}
+.          ie r#COUNTERS_RESET .rr #COUNTERS_RESET
 .          el \{\
 .             nr #GET_DEPTH 1
 .\" If the footnote is the 1st on the page and it falls too close
@@ -13685,17 +12678,13 @@
 .                nr #FN_DEPTH +\\n[#DIVER_DEPTH]
 .\" Special handling for run-on footnotes
 .                if \\n[#RUN_ON]=1 \{\
-.                   if \\n[#RUNON_FOOTNOTES] \{\
-.                      unformat RUNON_FOOTNOTES
-.                   \}
-.                   if \\n[#RUNON_FN_IN_DIVER] \{\
-.                      unformat RUNON_FN_IN_DIVER
-.                   \}
+.                   if \\n[#RUNON_FOOTNOTES]   .unformat RUNON_FOOTNOTES
+.                   if \\n[#RUNON_FN_IN_DIVER] .unformat RUNON_FN_IN_DIVER
 .                   ev FOOTNOTES
 .\" Recreate FOOTNOTES with rule followed by text of unformatted
 .\" run-on footnotes.
 .                   di FOOTNOTES
-.                   ie \\n[#FN_RULE]=0 \{ .RLD 1v \}
+.                   ie \\n[#FN_RULE]=0 .RLD 1v
 .                   el \{\
 \v'-\\n[#FN_RULE_ADJ]u-\\n[#FN_RULE_WEIGHT_ADJ]u'\
 \D't \\n[#FN_RULE_WEIGHT]'\
@@ -13727,14 +12716,12 @@
 .                   if \\n[#FN_COUNT]=2 \{\
 .                      ie \\n[#COLUMNS] \{\
 .                         if !\\n[#FROM_FOOTER] \{\
-.                            if \\n[#FN_DEFER]=1 \{ .nr #FN_DEFER_SPACE 1 \}
-.                            if \\n[#FN_COUNT_FOR_COLS]>=1 \{ .rr 
#FN_DEFER_SPACE \}
-.                            if \\n[#FROM_HEADER] \{ .nr #FN_DEFER_SPACE 1 \}
+.                            if \\n[#FN_DEFER]=1 .nr #FN_DEFER_SPACE 1
+.                            if \\n[#FN_COUNT_FOR_COLS]>=1 .rr #FN_DEFER_SPACE
+.                            if \\n[#FROM_HEADER] .nr #FN_DEFER_SPACE 1
 .                         \}
 .                      \}
-.                      el \{\
-.                         nr #FN_DEFER_SPACE 1
-.                      \}
+.                      el .nr #FN_DEFER_SPACE 1
 .                   \}
 .                   rr #FN_DEFER
 .                \}
@@ -13745,7 +12732,7 @@
 .                   nr #FN_LINES 0 1
 .                   while 
(\\n+[#FN_LINES]*\\n[#FN_LEAD])<\\n[#SPACE_REMAINING] \{\
 .                      nr #FN_DEPTH (\\n[#FN_LINES]*\\n[#FN_LEAD])
-.\}
+.                   \}
 .                   nr #VFP_DIFF \\n[#FN_DEPTH]-\\n[#SAVED_FN_DEPTH_1]
 .                   nr #OVERFLOW 1
 .\" Very occasionally, #VFP_DIFF, on a 1st footnote that isn't to
@@ -13776,38 +12763,32 @@
 .                               ie \\n[#FROM_FOOTER] \{\
 .                                  ie \\n[#FN_COUNT_FOR_COLS]>1 \{\
 .                                     nr #FN_DEPTH -\\n[#FN_DEPTH]
-.                                     if \\n[#DIVERTED]=1 \{ .nr #DIVERTED 3 \}
+.                                     if \\n[#DIVERTED]=1 .nr #DIVERTED 3
 .                                     if !\\n[#PREV_FN_DEFERRED]=1 \{\
 .                                        nr #FN_DEPTH -\\n[#VFP_DIFF]
 .                                     \}
 .                                  \}
 .                                  el \{\
 .                                     nr #VARIABLE_FOOTER_POS -\\n[#FN_DEPTH]
-.                                     if \\n[#DIVERTED]=1 \{ .nr #DIVERTED 3 \}
+.                                     if \\n[#DIVERTED]=1 .nr #DIVERTED 3
 .                                  \}
 .                               \}
-.                               el \{\
-.                                  nr #VARIABLE_FOOTER_POS -(\\n[#FN_DEPTH])
-.                               \}
-.                            \}
-.                            el \{\
-.                               nr #VARIABLE_FOOTER_POS -(\\n[#FN_DEPTH])
+.                               el .nr #VARIABLE_FOOTER_POS -(\\n[#FN_DEPTH])
 .                            \}
+.                            el .nr #VARIABLE_FOOTER_POS -(\\n[#FN_DEPTH])
 .                         \}
-.                         el \{ .nr #VARIABLE_FOOTER_POS -(\\n[#FN_DEPTH]) \}
+.                         el .nr #VARIABLE_FOOTER_POS -(\\n[#FN_DEPTH])
 .                      \}
 .                      el \{\
 .                         nr #VARIABLE_FOOTER_POS -\\n[#VFP_DIFF]
-.                         if \\n[#DIVERTED]=1 \{ .nr #DIVERTED 3 \}
+.                         if \\n[#DIVERTED]=1 .nr #DIVERTED 3
 .                         if !\\n[#PREV_FN_DEFERRED]=1 \{\
 .                            ie \\n[#COLUMNS]=1 \{\
 .                               if !\\n[#FROM_FOOTER] \{\
 .
 .                               \}
 .                            \}
-.                            el \{\
-.                               nr #FN_DEPTH -\\n[#VFP_DIFF]
-.                            \}
+.                            el .nr #FN_DEPTH -\\n[#VFP_DIFF]
 .                         \}
 .                         if \\n[#DIVERTED]=3 \{\
 .                            if !\\n[#PREV_FN_DEFERRED] \{\
@@ -13830,12 +12811,6 @@
 .                            \}
 .                         \}
 .                      \}
-.\" Not sure what I was thinking with this next line.  As is, it
-.\" moves the already established VFP trap for footnote 1 higher up
-.\" the page, resulting in a VFP that's higher on the page than the
-.\" current page position.  Leaving it in anyway, commented out, in
-.\" case the logic and the conditions under which it should
-.\" apply reveal themselves.
 .                      nr #FN_DEPTH \\n[#SAVED_FN_DEPTH_1]+\\n[#VFP_DIFF]
 .                   \}
 .                   el \{\
@@ -13865,13 +12840,6 @@
 .             \}
 .          \}
 .          ch FOOTER \\n[#VARIABLE_FOOTER_POS]u
-.\" See VFP_CHECK for an explanation of the next lines.
-.\" The trap has to be removed, prior to setting it, each time
-.\" FOOTNOTE is run.
-.          if \\n[#PRINT_STYLE]=2 \{\
-.             ch VFP_CHECK
-.             wh \\n[#VARIABLE_FOOTER_POS]u-\\n[#DOC_LEAD]u VFP_CHECK
-.          \}
 .\" If we have a footnote whose text has to be deferred to the next
 .\" page, reset the FOOTER trap to its original location.
 .          if \\n[#FN_DEFER] \{\
@@ -13882,8 +12850,8 @@
 .       nr #NO_FN_MARKER 0
 .    \}
 .    if \\n[#NUM_ARGS]=2 \{\
-.       if '\\$2'BREAK' \{ .BR \}
-.       if '\\$2'BR' \{ .BR \}
+.       if '\\$2'BREAK' .BR
+.       if '\\$2'BR' .BR
 .    \}
 .END
 \#
@@ -13906,25 +12874,21 @@
 .       if \\n[#FN_DEFER] \{\
 .          if \\n[#SAVED_DIVER_FN_COUNT]=1 \{\
 .             ie \\n[#COLUMNS]=1 \{\
-.                if \\n[#COL_NUM]=\\n[#NUM_COLS] \{ .nr #FN_DEFER_SPACE 1 \}
-.             \}
-.             el \{\
-.                nr #FN_DEFER_SPACE 1
+.                if \\n[#COL_NUM]=\\n[#NUM_COLS] .nr #FN_DEFER_SPACE 1
 .             \}
+.             el .nr #FN_DEFER_SPACE 1
 .          \}
 .       \}
 .       if \\n[#FN_MARKER_STYLE]=1 \{\
-.          if \\n[#FN_COUNT]>0 \{ .nr #FN_COUNT 0 1 \}
+.          if \\n[#FN_COUNT]>0 .nr #FN_COUNT 0 1
 .          if \\n[#COLUMNS]=1 \{\
-.             if \\n[#COL_NUM]=\\n[#NUM_COLS] \{\
-.                nr #FN_COUNT_FOR_COLS 0 1
-.             \}
+.             if \\n[#COL_NUM]=\\n[#NUM_COLS] .nr #FN_COUNT_FOR_COLS 0 1
 .          \}
 .       \}
 .       if \\n[#FN_MARKER_STYLE]=2 \{\
 .          if \\n[#RESET_FN_NUMBER]=1 \{\
 .             ie \\n[#COLUMNS]=1 \{\
-.                if \\n[#COL_NUM]=\\n[#NUM_COLS] \{ .nr #FN_NUMBER 0 1 \}
+.                if \\n[#COL_NUM]=\\n[#NUM_COLS] .nr #FN_NUMBER 0 1
 .             \}
 .             el \{\
 .                nr #FN_NUMBER 0 1
@@ -13950,32 +12914,22 @@
 .MAC DIVER_FN_2_POST END
 .    if \\n[#DONE_ONCE]=1 \{\
 .       if \\n[#FN_MARKER_STYLE]=1 \{\
-.          if \\n[#FN_COUNT]=0 \{\
-.             nr #DONT_RULE_ME 1
-.          \}
-.          if \\n[#FN_COUNT]>0 \{\
-.             nr #FN_COUNT 0 1
-.          \}
+.          if \\n[#FN_COUNT]=0 .nr #DONT_RULE_ME 1
+.          if \\n[#FN_COUNT]>0 .nr #FN_COUNT 0 1
 .          if \\n[#COLUMNS]=1 \{\
-.             if \\n[#COL_NUM]=\\n[#NUM_COLS] \{ .nr #FN_COUNT_FOR_COLS 0 1 \}
+.             if \\n[#COL_NUM]=\\n[#NUM_COLS] .nr #FN_COUNT_FOR_COLS 0 1
 .             if !\\n[#COL_NUM]=\\n[#NUM_COLS] \{\
 .             \}
 .          \}
 .       \}
 .       if \\n[#FN_MARKER_STYLE]=2 \{\
-.          if \\n[#FN_COUNT]=0 \{\
-.             nr #DONT_RULE_ME 1
-.          \}
-.          if \\n[#FN_COUNT]>0 \{\
-.             nr #FN_COUNT 0 1
-.          \}
+.          if \\n[#FN_COUNT]=0 .nr #DONT_RULE_ME 1
+.          if \\n[#FN_COUNT]>0 .nr #FN_COUNT 0 1
 .          if \\n[#RESET_FN_NUMBER]=1 \{\
 .             ie \\n[#COLUMNS]=1 \{\
-.                if \\n[#COL_NUM]=\\n[#NUM_COLS] \{ .nr #FN_NUMBER 0 1 \}
-.             \}
-.             el \{\
-.                nr #FN_NUMBER 0 1
+.                if \\n[#COL_NUM]=\\n[#NUM_COLS] .nr #FN_NUMBER 0 1
 .             \}
+.             el .nr #FN_NUMBER 0 1
 .          \}
 .       \}
 .    \}
@@ -13983,49 +12937,6 @@
 \#
 \# The main macros that handle footnote processing.
 \# -----------------------------------------------
-\# Sometimes, #VARIABLE_FOOTER_POS sets FOOTER at a location that gives
-\# the impression another line of running text could fit on the page.
-\# VFP_CHECK is always set to the line just above the one where FOOTER
-\# will be sprung, and checks for this condition.  If it exists, FOOTER
-\# is set one line lower on the page, thus squeezing in an extra line
-\# of running text.  This is a judgment call on my part, but seems to
-\# work well.  If there are problems (e.g. footnotes really do look
-\# jammed), the user should probably adjust FOOTNOTE_AUTOLEAD and/or
-\# FOOTNOTE_RULE_ADJ.
-\# 
-\# The macro has to be run in its own environment, otherwise the first
-\# word of the last line before the footnotes gets chopped.
-\#
-.MAC VFP_CHECK END
-.    ev VFP_CHECK
-.\" The trap also has to be removed each time VFP_CHECK is run
-.    if \\n[#PRINT_STYLE]=2 \{\
-.       ch VFP_CHECK
-.       SIZESPECS
-.       ie !\\n[#IN_DIVER] \{ .nr #PAGE_POS \\n(nl \}
-.       el \{ .nr #PAGE_POS \\n(nl+\\n(.d+(\\n[#DOC_LEAD]) \}
-.       nr #FOOTER_POS \\n[#PAGE_LENGTH]+(\\n[#VARIABLE_FOOTER_POS])
-.       nr #SPACE_TO_FOOTER \\n[#FOOTER_POS]-\\n[#PAGE_POS]
-.       nr #FN_GAP \\n[#SPACE_TO_FOOTER]%\\n[#DOC_LEAD]
-.       if !\\n[#FN_GAP]<0 \{\
-.          if \\n[#FN_GAP]<\\n[#DOC_LEAD] \{\
-.             ie 
(\\n[#PAGE_POS]+(\\n[#FN_DEPTH]+\\n[#FN_GAP]))>(\\n[#VISUAL_B_MARGIN]) \{\
-.                nr #VARIABLE_FOOTER_POS 0+\\n[#VARIABLE_FOOTER_POS]
-.             \}
-.             el \{\
-.                ie \\n[#DOC_LEAD]-\\n[#FN_GAP]<\\n[#DESCENDER] \{\
-.                   nr #VARIABLE_FOOTER_POS +\\n[#DOC_LEAD]
-.                   ch FOOTER \\n[#VARIABLE_FOOTER_POS]u
-.                \}
-.                el \{\
-.                   nr #VARIABLE_FOOTER_POS 0+\\n[#VARIABLE_FOOTER_POS]
-.                \}
-.             \}
-.          \}
-.       \}
-.    \}
-.    ev
-.END
 \#
 \# FN_OVERFLOW_TRAP starts off "underneath" FOOTER, but is revealed
 \# as #VARIABLE_FOOTER_POSITION changes the position of FOOTER.
@@ -14042,11 +12953,10 @@
 .             ie \\n[#COLUMNS]=1 \{\
 .                if \\n[#FROM_FOOTER] \{\
 .                   if \\n[#PREV_FN_DEFERRED] \{\
-.                      if !\\n[#COL_NUM]=\\n[#NUM_COLS] \{\
+.                      if !\\n[#COL_NUM]=\\n[#NUM_COLS] \
 .                      rr #PREV_FN_DEFERRED
 .                      \}
 .                   \}
-.                \}
 .                if !\\n[#FROM_FOOTER] \{\
 .                   if !\\n[#COL_NUM]=\\n[#NUM_COLS] \{\
 .                      if !\\n[#LAST_FN_COUNT_FOR_COLS]>1 \{\
@@ -14080,17 +12990,15 @@
 \#
 .MAC PROCESS_FN_LEFTOVER END
 .    if \\n[#PREV_FN_DEFERRED]=2 \{\
-.       if \\n[#FN_COUNT_AT_FOOTER]>1 \{ .rr #PREV_FN_DEFERRED \}
+.       if \\n[#FN_COUNT_AT_FOOTER]>1 .rr #PREV_FN_DEFERRED
 .    \}
 .    if !\\n[#FN_DEFER] \{\
 .       nr #FN_COUNT 0 1
 .       nr #FN_DEPTH 0
 .       nr #VARIABLE_FOOTER_POS 0-\\n[#B_MARGIN]
 .    \}
-.    if r#FN_DEFER \{\
-.       if \\n[#FN_DEFER]=1 \{\
-.          nr #VARIABLE_FOOTER_POS -\\n[#FN_DEPTH]
-.       \}
+.    if r #FN_DEFER \{\
+.       if \\n[#FN_DEFER]=1 .nr #VARIABLE_FOOTER_POS -\\n[#FN_DEPTH]
 .       if \\n[#FN_DEFER]=2 \{\
 .          nr #FN_DEPTH 0
 .          nr #VARIABLE_FOOTER_POS 0-\\n[#B_MARGIN]
@@ -14106,24 +13014,22 @@
 .       ie \\n[#COLUMNS]=1 \{\
 .          if \\n[#COL_NUM]=\\n[#NUM_COLS] \{\
 .             if !\\n[#FROM_FOOTER] \{\
-.                if \\n[#FN_COUNT_FOR_COLS]=1 \{ .nr #PREV_FN_DEFERRED 1 \}
+.                if \\n[#FN_COUNT_FOR_COLS]=1 .nr #PREV_FN_DEFERRED 1
 .             \}
 .          \}
 .       \}
-.       el \{ .nr #PREV_FN_DEFERRED 1 \}
+.       el .nr #PREV_FN_DEFERRED 1
 .    \}
 .    if !\\n[#FN_DEFER] \{\
-.       if \\n[#FN_OVERFLOW_DEPTH] \{\
-.          DIVERT_FN_LEFTOVER
-.       \}
+.       if \\n[#FN_OVERFLOW_DEPTH] .DIVERT_FN_LEFTOVER
 .    \}
 .    ie \\n[#COLUMNS]=1 \{\
 .       if \\n[#COL_NUM]>1 \{\
-.          if \\n[#COL_NUM]=\\n[#NUM_COLS] \{ .nr #FN_COUNT 0 1 \}
+.          if \\n[#COL_NUM]=\\n[#NUM_COLS] .nr #FN_COUNT 0 1
 .       \}
 .    \}
-.    el \{ .nr #FN_COUNT 0 1 \}
-.    if \\n[#DIVER_FN]=2 \{ .rr #DIVER_FN \}
+.    el .nr #FN_COUNT 0 1
+.    if \\n[#DIVER_FN]=2 .rr #DIVER_FN
 .    rr #FROM_DIVERT_FN
 .END
 \#
@@ -14159,11 +13065,9 @@
 .    nr #SPACE_REMAINING 0
 .    ch FOOTER -\\n[#B_MARGIN]u
 .    nr #NO_FN_MARKER 1
-.    if !\\n[#RESET_FN_COUNTERS]=2 \{\
-.       rr #RESET_FN_COUNTERS
-.    \}
+.    if !\\n[#RESET_FN_COUNTERS]=2 .rr #RESET_FN_COUNTERS
 .    FOOTNOTE
-.    if \\n[#FN_OVERFLOW_DEPTH] \{ .nf \}
+.    if \\n[#FN_OVERFLOW_DEPTH] .nf
 .    ie dRUNON_FN_IN_DIVER \{\
 .       RUNON_FN_IN_DIVER
 .       rm RUNON_FN_IN_DIVER
@@ -14218,7 +13122,6 @@
 .    nr #EN_PS (p;\\$1)
 .END
 \#
-\#
 \# ENDNOTES, BIBLIOGRAPHY and TOC LEADING
 \# --------------------------------------
 \# *Argument:
@@ -14237,13 +13140,11 @@
 .    if '\\$0'TOC_LEAD'          .ds $SECTION TOC
 .    ds $\\*[$SECTION]_LEAD \\$1
 .    ds $ADJUST_\\*[$SECTION]_LEAD \\$2
-.    if !\\n[#OK_PROCESS_LEAD] \{\
-.       return
-.    \}
+.    if !\\n[#OK_PROCESS_LEAD] .return
 .    nr #\\*[$SECTION]_LEAD (p;\\$1)
 .    rr #ADJ_\\*[$SECTION]_LEAD
 .    if '\\$2'ADJUST' \{\
-.       nr #ORIG_DOC_LEAD \\n[#DOC_LEAD]
+.       nr #ORIG_DOC_LEAD \\n[#UNADJUSTED_DOC_LEAD]
 .       nr #RESTORE_ADJ_DOC_LEAD \\n[#ADJ_DOC_LEAD]
 .       nr #ADJ_DOC_LEAD 1
 .       nr #ADJ_\\*[$SECTION]_LEAD 1
@@ -14272,10 +13173,9 @@
 \#
 .MAC ENDNOTE_SPACING END
 .    ie \B'\\$1' .ds $EN_SPACE \\$1
-.    el \{ .rm $EN_SPACE \}
+.    el .rm $EN_SPACE
 .END
 \#
-\#
 \# ENDNOTES_HDRFTR_CENTER
 \# ----------------------
 \# *Argument:
@@ -14289,11 +13189,10 @@
 \#   Default is OFF
 \#
 .MAC ENDNOTES_HDRFTR_CENTER END
-.    ie '\\$1'' \{ .nr #EN_HDRFTR_CENTER 1 \}
-.    el         \{ .rr #EN_HDRFTR_CENTER   \}
+.    ie '\\$1'' .nr #EN_HDRFTR_CENTER 1
+.    el .rr #EN_HDRFTR_CENTER
 .END
 \#
-\#
 \# ENDNOTE STRING
 \# --------------
 \# *Argument:
@@ -14307,12 +13206,10 @@
 .    ds $EN_STRING \\$1
 .END
 \#
-\#
 .MAC ENDNOTE_STRING_ADVANCE END
 .    nr #EN_STRING_ADVANCE (\\$1)
 .END
 \#
-\#
 \# ENDNOTE STRING CAPS
 \# -------------------
 \# *Arguments:
@@ -14329,11 +13226,10 @@
 \#   Default is on.
 \#
 .MAC ENDNOTE_STRING_CAPS END
-.   ie '\\$1'' \{ .nr #EN_STRING_CAPS 1 \}
-.   el \{ .nr #EN_STRING_CAPS 0 \}
+.   ie '\\$1'' .nr #EN_STRING_CAPS 1
+.   el .nr #EN_STRING_CAPS 0
 .END
 \#
-\#
 \# ENDNOTE TITLE
 \# -------------
 \# *Argument:
@@ -14347,7 +13243,6 @@
 .    ds $EN_TITLE \\$1
 .END
 \#
-\#
 \# ENDNOTE MARKER STYLE
 \# --------------------
 \# *Arguments:
@@ -14360,25 +13255,23 @@
 \#   Default is NUMBER.
 \#
 .MAC ENDNOTE_MARKER_STYLE END
-.    if '\\$1'NUMBER' \{ .nr #EN_MARKER_STYLE 1 \}
+.    if '\\$1'NUMBER' .nr #EN_MARKER_STYLE 1
 .    if '\\$1'LINE' \{\
 .       nr #EN_MARKER_STYLE 2
 .       if !\\n[#EN_LN_SEP] \{\
-.          if !\\n[#EN_LN_BRACKETS] \{ .ENDNOTE_LINENUMBER_BRACKETS SQUARE \}
+.          if !\\n[#EN_LN_BRACKETS] .ENDNOTE_LINENUMBER_BRACKETS SQUARE
 .       \}
 .    \}
-.    if '\\$1'SUPERSCRIPT' \{ .nr #EN_MARKER_STYLE 3 \}
+.    if '\\$1'SUPERSCRIPT' .nr #EN_MARKER_STYLE 3
 .END
 \#
-\#
 \# ENDNOTE LINENUMBER MARK
 \# -----------------------
 \# *Function:
 \#   This string, when called inline, stores the current output line
 \#   number in register #EN_MARK for use with ENDNOTE.
 \#
-.ds EN_MARK \R'#EN_MARK \En(ln'
-\#
+.ds EN_MARK \R'#EN_MARK \En[ln]'
 \#
 \# ENDNOTE LINENUMBER SEPARATOR
 \# ----------------------------
@@ -14397,7 +13290,6 @@
 .    ds $EN_LN_SEP "\\$1
 .END
 \#
-\#
 \# ENDNOTE LINENUMBER BRACKETS
 \# ---------------------------
 \# *Argument:
@@ -14435,7 +13327,6 @@
 .    \}
 .END
 \#
-\#
 \# ENDNOTE LINENUMBER GAP
 \# ----------------------
 \# *Argument:
@@ -14448,7 +13339,6 @@
 .    nr #EN_LN_GAP (u;\\$1)
 .END
 \#
-\#
 \# ENDNOTE NUMBERS ALIGNMENT
 \# -------------------------
 \# *Argument:
@@ -14471,7 +13361,6 @@
 .    nr #EN_NUMBER_PLACEHOLDERS \\$2
 .END
 \#
-\#
 \# ENDNOTE PARAGRAPH INDENT
 \# ------------------------
 \# *Argument:
@@ -14487,7 +13376,6 @@
 .    nr #EN_PP_INDENT (\\$1)
 .END
 \#
-\#
 \# TURN OFF COLUMN MODE FOR ENDNOTES
 \# ---------------------------------
 \# *Argument:
@@ -14499,11 +13387,10 @@
 \#   documents in columns.  Default is to set endnotes in columns.
 \#
 .MAC ENDNOTES_NO_COLUMNS END
-.    ie '\\$1'' \{ .nr #EN_NO_COLS 1 \}
-.    el \{ .rr #EN_NO_COLS \}
+.    ie '\\$1'' .nr #EN_NO_COLS 1
+.    el .rr #EN_NO_COLS
 .END
 \#
-\#
 \# NO FIRST PAGE NUMBER ON ENDNOTES FIRST PAGE
 \# -------------------------------------------
 \# *Argument:
@@ -14517,11 +13404,10 @@
 \#   endnotes page when footers are on.
 \#
 .MAC ENDNOTES_NO_FIRST_PAGENUM END
-.    ie '\\$1'' \{ .nr #EN_NO_FIRST_PN 1 \}
-.    el \{ .rr #EN_NO_FIRST_PN \}
+.    ie '\\$1'' .nr #EN_NO_FIRST_PN 1
+.    el .rr #EN_NO_FIRST_PN
 .END
 \#
-\#
 \# PAGE HEADERS ON ENDNOTES PAGES
 \# ------------------------------
 \# *Argument:
@@ -14537,7 +13423,7 @@
 \#   page header on the first page as well.
 \#
 .MAC ENDNOTES_ALLOWS_HEADERS END
-.    ie '\\$1'' \{ .nr #EN_ALLOWS_HEADERS 1 \}
+.    ie '\\$1'' .nr #EN_ALLOWS_HEADERS 1
 .    el \{\
 .       ie '\\$1'ALL' \{\
 .          nr #EN_ALLOWS_HEADERS 1
@@ -14550,7 +13436,6 @@
 .    \}
 .END
 \#
-\#
 \# ENDNOTES PAGES PAGE NUMBERING STYLE
 \# -----------------------------------
 \# *Argument:
@@ -14568,7 +13453,6 @@
 .    ds $EN_PN_STYLE \\$1
 .END
 \#
-\#
 \# FIRST PAGE NUMBER FOR ENDNOTES
 \# ------------------------------
 \# *Argument:
@@ -14625,7 +13509,6 @@
 .    \}
 .END
 \#
-\#
 \# ENDNOTE PARAGRAPH SPACE
 \# -----------------------
 \# *Argument:
@@ -14636,11 +13519,10 @@
 \#   Like PARA_SPACE.  Default is not to space endnote paras.
 \#
 .MAC ENDNOTE_PARA_SPACE END
-.    ie '\\$1'' \{ .nr #EN_PP_SPACE 1 \}
-.    el \{ .rr #EN_PP_SPACE \}
+.    ie '\\$1'' .nr #EN_PP_SPACE 1
+.    el .rr #EN_PP_SPACE
 .END
 \#
-\#
 \# ENDNOTE
 \# -------
 \# *Argument:
@@ -14656,8 +13538,8 @@
 .    ie '\\$1'' \{\
 .       nr #ENDNOTE 1
 .       ie !\\n[#EN_MARKER_STYLE]=2 \{\
-.          if \\n[#CONDENSE] \{ .nop \*[CONDX]\c \}
-.          if \\n[#EXTEND]   \{ .nop \*[EXTX]\c  \}
+.          if \\n[#CONDENSE] .nop \*[CONDX]\c
+.          if \\n[#EXTEND] .nop \*[EXTX]\c
 .             if \\n[#UNDERLINE_ON] \{\
 .                nr #UNDERLINE_WAS_ON 1
 .                UNDERLINE OFF
@@ -14669,22 +13551,21 @@
 .             \}
 .\" Vertical raise amount here is more than when the same string is printed in
 .\" the endnotes so bottom of number aligns with top of bowl.
-.             PRINT 
"\s-2\v'-\\n[#DOC_LEAD]u/5u'\\n+[#EN_NUMBER]\v'+\\n[#DOC_LEAD]u/5u'\s+2\c"
-.          \}
-.          if \\n[#PRINT_STYLE]=2 \{\
-.             PRINT \*[SUP]\\n+[#EN_NUMBER]\*[SUPX]\c
+.             PRINT \
+"\s-2\v'-\\n[#DOC_LEAD]u/5u'\\n+[#EN_NUMBER]\v'+\\n[#DOC_LEAD]u/5u'\s+2\c"
 .          \}
+.          if \\n[#PRINT_STYLE]=2 .PRINT \*[SUP]\\n+[#EN_NUMBER]\*[SUPX]\c
 .       \}
 .       el \{\
-.          ie r#EN_NUMBER \{ .nr #EN_NUMBER \\n[#EN_NUMBER]+1 \}
-.          el \{ .nr #EN_NUMBER 1 1 \}
+.          ie r#EN_NUMBER .nr #EN_NUMBER \\n[#EN_NUMBER]+1
+.          el .nr #EN_NUMBER 1 1
 .          if !\\n[#LINENUMBERS] \{\
 .             tm1 "[mom]: Line numbering must be enabled with NUMBER_LINES when
 .             tm1 "       ENDNOTE_MARKER_STYLE is LINE.
-.             ab Aborting on ENDNOTE at line \\n(.c.
+.             ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
 .          \}
-.          if \\n[#EN_MARK]=0 \{ .nr #EN_MARK \\n(ln \}
-.          nr #EN_MARK_2 \\n(ln
+.          if \\n[#EN_MARK]=0 .nr #EN_MARK \\n[ln]
+.          nr #EN_MARK_2 \\n[ln]
 .          if '\\n[.z]'P_QUOTE' \{\
 .             nr #EN_MARK -1
 .             nr #EN_MARK_2 -1
@@ -14692,24 +13573,22 @@
 .       \}
 .       nr #PP_STYLE_PREV \\n[#PP_STYLE]
 .       nr #PP_STYLE 1
-.       if \\n[#INDENT_FIRST_PARAS] \{ .nr #INDENT_FIRSTS 1 \}
+.       if \\n[#INDENT_FIRST_PARAS] .nr #INDENT_FIRSTS 1
 .       INDENT_FIRST_PARAS
 .       ev EN
 .       da END_NOTES
 .       LL \\n[#DOC_L_LENGTH]u
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .       if \\n[#COLUMNS] \{\
-.          ie \\n[#EN_NO_COLS] \{ .LL \\n[#DOC_L_LENGTH]u \}
-.          el \{ .LL \\n[#COL_L_LENGTH]u \}
-.          ta \\n(.lu
+.          ie \\n[#EN_NO_COLS] .LL \\n[#DOC_L_LENGTH]u
+.          el .LL \\n[#COL_L_LENGTH]u
+.          ta \\n[.l]u
 .       \}
 .       ENDNOTE_LEAD \\*[$EN_LEAD] \\*[$ADJUST_EN_LEAD]
 .       vs \\n[#EN_LEAD]u
 .\" Print page header title
 .       if \\n[#EN_NUMBER]=1 \{\
-.          if \\n[#PRINT_STYLE]=1 \{\
-.             TYPEWRITER
-.          \}
+.          if \\n[#PRINT_STYLE]=1 .TYPEWRITER
 .          if \\n[#PRINT_STYLE]=2 \{\
 .             FAMILY  \\*[$EN_TITLE_FAM]
 .             FT      \\*[$EN_TITLE_FT]
@@ -14717,21 +13596,19 @@
 .          \}
 .          sp
 .          if !'\\*[$EN_TITLE]'' \{\
-.             if '\\*[$EN_TITLE_QUAD]'L'      \{ .LEFT   \}
-.             if '\\*[$EN_TITLE_QUAD]'LEFT'   \{ .LEFT   \}
-.             if '\\*[$EN_TITLE_QUAD]'C'      \{ .CENTER \}
-.             if '\\*[$EN_TITLE_QUAD]'CENTER' \{ .CENTER \}
-.             if '\\*[$EN_TITLE_QUAD]'CENTRE' \{ .CENTER \}
-.             if '\\*[$EN_TITLE_QUAD]'R'      \{ .RIGHT  \}
-.             if '\\*[$EN_TITLE_QUAD]'RIGHT'  \{ .RIGHT  \}
+.             if '\\*[$EN_TITLE_QUAD]'L'      .LEFT
+.             if '\\*[$EN_TITLE_QUAD]'LEFT'   .LEFT
+.             if '\\*[$EN_TITLE_QUAD]'C'      .CENTER
+.             if '\\*[$EN_TITLE_QUAD]'CENTER' .CENTER
+.             if '\\*[$EN_TITLE_QUAD]'CENTRE' .CENTER
+.             if '\\*[$EN_TITLE_QUAD]'R'      .RIGHT
+.             if '\\*[$EN_TITLE_QUAD]'RIGHT'  .RIGHT
 .             ie \\n[#EN_TITLE_UNDERLINE] \{\
 .                nr #FROM_EN_TITLE 1
 .                UNDERSCORE "\\*[$EN_TITLE]"
 .                rr #FROM_EN_TITLE
 .             \}
-.             el \{\
-.                PRINT "\\*[$EN_TITLE]"
-.             \}
+.             el .PRINT "\\*[$EN_TITLE]"
 .          \}
 .       \}
 .\" Get indent from endnotes point size; convert string to reg in
@@ -14740,12 +13617,12 @@
 .       nr #REF_EN_INDENT (u;\\*[$REF_EN_INDENT])
 .       if \\n[#PRINT_STYLE]=1 \{\
 .          TYPEWRITER
-.          if \\n[#EN_NUMBER]=1 \{ .sp \}
-.          if \\n[#EN_MARKER_STYLE]=3 \{ .PT_SIZE -2 \}
+.          if \\n[#EN_NUMBER]=1 .sp
+.          if \\n[#EN_MARKER_STYLE]=3 .PT_SIZE -2
 .       \}
 .       if \\n[#PRINT_STYLE]=2 \{\
 .          if \\n[#EN_NUMBER]=1 \{\
-.             if !'\\*[$EN_TITLE]'' \{ .sp \}
+.             if !'\\*[$EN_TITLE]'' .sp
 .          \}
 .          if \\n[#EN_MARKER_STYLE]=1 \{\
 .             FAMILY  \\*[$EN_NUMBER_FAM]
@@ -14767,44 +13644,44 @@
 .       if \\n[#EN_MARKER_STYLE]=2 \{\
 .          ie \\n[#EN_LN_BRACKETS]=1 \{\
 .             ds $EN_LINENUMBER \v'-.085m'\\*[$EN_OPEN_BRACKET]\v'.085m'
-.             ie \\n[#EN_MARK_2]=\\n[#EN_MARK] \{\
-.                as $EN_LINENUMBER 
\\n[#EN_MARK]\v'-.085m'\\*[$EN_CLOSE_BRACKET]\v'.085m'\"
-.             \}
-.             el \{\
-.                as $EN_LINENUMBER 
\\n[#EN_MARK]\v'-.1m'-\v'.1m'\\n[#EN_MARK_2]\v'-.085m'\\*[$EN_CLOSE_BRACKET]\v'.085m'\"
-.             \}
-.          \}
-.          el \{\
-.             ie \\n[#EN_MARK_2]=\\n[#EN_MARK] \{\
-.                ds $EN_LINENUMBER \\n[#EN_MARK]\\*[$EN_LN_SEP]
+.             ie \\n[#EN_MARK_2]=\\n[#EN_MARK] .as $EN_LINENUMBER \
+\\n[#EN_MARK]\v'-.085m'\\*[$EN_CLOSE_BRACKET]\v'.085m'\"
+.             el .as $EN_LINENUMBER \
+\\n[#EN_MARK]\v'-.1m'-\v'.1m'\\n[#EN_MARK_2]\v'-.085m'\
+\\*[$EN_CLOSE_BRACKET]\v'.085m'\"
 .             \}
 .             el \{\
-.                ds $EN_LINENUMBER 
\\n[#EN_MARK]\v'-.1m'-\v'.1m'\\n[#EN_MARK_2]\\*[$EN_LN_SEP]
-.             \}
+.             ie \\n[#EN_MARK_2]=\\n[#EN_MARK] \
+.                ds $EN_LINENUMBER \
+\\n[#EN_MARK]\\*[$EN_LN_SEP]
+.             el \
+.                ds $EN_LINENUMBER \
+\\n[#EN_MARK]\v'-.1m'-\v'.1m'\\n[#EN_MARK_2]\\*[$EN_LN_SEP]
 .          \}
 .          nr #EN_MARK 0
 .       \}
 \!.     TRAP OFF
-.       ie \\n[#EN_NUMBERS_ALIGN_RIGHT] \{ .RIGHT \}
-.       el \{ .LEFT \}
-.       if \\n[#EN_MARKER_STYLE]=1 \{\
+.       ie \\n[#EN_NUMBERS_ALIGN_RIGHT] .RIGHT
+.       el .LEFT
+.       if \\n[#EN_MARKER_STYLE]=1 \
 .          nr #EN_NUMBER_L_LENGTH \w'\0'*\\n[#EN_NUMBER_PLACEHOLDERS]+\w'.'
-.       \}
 .       if \\n[#EN_MARKER_STYLE]=2 \{\
-.          ie \\n[#EN_LN_BRACKETS]=1 \{ .nr #EN_NUMBER_L_LENGTH 
(\w'\0'*(\\n[#EN_NUMBER_PLACEHOLDERS]*2))+\w'-[]' \}
-.          el \{ .nr #EN_NUMBER_L_LENGTH 
(\w'\0'*(\\n[#EN_NUMBER_PLACEHOLDERS]*2))+\w'-\\*[$EN_LN_SEP]' \}
+.          ie \\n[#EN_LN_BRACKETS]=1 .nr #EN_NUMBER_L_LENGTH \
+(\w'\0'*(\\n[#EN_NUMBER_PLACEHOLDERS]*2))+\w'-[]'
+.          el .nr #EN_NUMBER_L_LENGTH \
+(\w'\0'*(\\n[#EN_NUMBER_PLACEHOLDERS]*2))+\w'-\\*[$EN_LN_SEP]'
 .          RIGHT
 .       \}
 .       if \\n[#EN_MARKER_STYLE]=3 \{\
-.          nr #EN_NUMBER_L_LENGTH \w'\0'*\\n[#EN_NUMBER_PLACEHOLDERS]
+.          nr #EN_NUMBER_L_LENGTH \
+\w'\0'*\\n[#EN_NUMBER_PLACEHOLDERS]+.15m
 .          RIGHT
 .       \}
-.       ie \\n[#REF]=1 \{\
+.       ie \\n[#REF]=1 \
 .          ll \\n[#EN_NUMBER_L_LENGTH]u+\\n[#REF_EN_INDENT]u
-.       \}
-.       el \{ .ll \\n[#EN_NUMBER_L_LENGTH]u \}
+.       el .ll \\n[#EN_NUMBER_L_LENGTH]u
 .       if \\n[#EN_MARKER_STYLE]=1 \{\
-.          if \\n[#REF]=1 \{ .ti \\n[#REF_EN_INDENT]u \}
+.          if \\n[#REF]=1 .ti \\n[#REF_EN_INDENT]u
 .          nop \En[#EN_NUMBER].
 .       \}
 .       if \\n[#EN_MARKER_STYLE]=2 \{\
@@ -14816,27 +13693,34 @@
 .          ie \\n[#PRINT_STYLE]=1 \{\
 .\" Vertical raise amount here is less than when the same string is printed in
 .\" the body of the text because number precedes a cap.
-.             nop 
\s-2\v'-\\n[#DOC_LEAD]u/7u'\\n[#EN_NUMBER]\|\v'+\\n[#DOC_LEAD]u/7u'\s+2
+.             nop \
+\s-2\v'-\\n[#DOC_LEAD]u/7u'\\n[#EN_NUMBER]\|\v'+\\n[#DOC_LEAD]u/7u'\s+2
 .          \}
-.          el \{ .nop \E*[SUP]\\n[#EN_NUMBER]\E*[SUPX] \}
+.          el .nop \E*[SUP]\\n[#EN_NUMBER]\E*[SUPX]\h'.15m'
 .       \}
 .       EOL
 \!.     TRAP OFF
 .       ll
 .       nr #EN_FIGURE_SPACE \w'\0'
 .       if \\n[#EN_MARKER_STYLE]=1 \{\
-.          ie \\n[#REF]=1 \{ .ti 
\\n[#EN_NUMBER_L_LENGTH]u+\\n[#REF_EN_INDENT]u+\\n[#EN_FIGURE_SPACE]u \}
-.          el \{ .in \\n[#EN_NUMBER_L_LENGTH]u+\\n[#EN_FIGURE_SPACE]u \}
+.          ie \\n[#REF]=1 .ti \
+\\n[#EN_NUMBER_L_LENGTH]u+\\n[#REF_EN_INDENT]u+\\n[#EN_FIGURE_SPACE]u
+.          el .in \
+\\n[#EN_NUMBER_L_LENGTH]u+\\n[#EN_FIGURE_SPACE]u
 .       \}
 .       if \\n[#EN_MARKER_STYLE]=2 \{\
-.          ie \\n[#REF]=1 \{ .ti 
\\n[#EN_NUMBER_L_LENGTH]u+\\n[#REF_EN_INDENT]u+\\n[#EN_LN_GAP]u \}
-.          el \{ .ti \\n[#EN_NUMBER_L_LENGTH]u+\\n[#EN_LN_GAP]u \}
+.          ie \\n[#REF]=1 .ti \
+\\n[#EN_NUMBER_L_LENGTH]u+\\n[#REF_EN_INDENT]u+\\n[#EN_LN_GAP]u
+.          el .ti \
+\\n[#EN_NUMBER_L_LENGTH]u+\\n[#EN_LN_GAP]u
 .       \}
 .       if \\n[#EN_MARKER_STYLE]=3 \{\
-.          ie \\n[#REF]=1 \{ .ti 
\\n[#EN_NUMBER_L_LENGTH]u+\\n[#REF_EN_INDENT]u+\w'\|'u \}
-.          el \{ .in \\n[#EN_NUMBER_L_LENGTH]u \}
+.          ie \\n[#REF]=1 .ti \
+\\n[#EN_NUMBER_L_LENGTH]u+\\n[#REF_EN_INDENT]u+\w'\|'u
+.          el .in \
+\\n[#EN_NUMBER_L_LENGTH]u
 .       \}
-.       nr #EN_TEXT_INDENT \\n(.i
+.       nr #EN_TEXT_INDENT \\n[.i]
 .       QUAD \\*[$EN_QUAD]
 \!.     TRAP
 .       if \\n[#PRINT_STYLE]=1 \{\
@@ -14849,8 +13733,8 @@
 .       \}
 .    \}
 .    el \{\
-\!.     ie \\n[#EN_NUMBER]=\\\\n[#LAST_EN] \{ .vpt 0 \}
-\!.     el \{ .br \}
+\!.     ie \\n[#EN_NUMBER]=\\\\n[#LAST_EN] .vpt 0
+\!.     el .br
 .       ALD \\*[$EN_SPACE]
 .       in 0
 .       if \\n[#EN_MARKER_STYLE]=2 \{\
@@ -14859,13 +13743,13 @@
 .       da
 .\" Restore sentence spacing
 .       if \\n[#PRINT_STYLE]=2 \{\
-.          if d$RESTORE_SS_VAR \{ .SS \\*[$RESTORE_SS_VAR] \}
+.          if d$RESTORE_SS_VAR .SS \\*[$RESTORE_SS_VAR]
 .          rm $RESTORE_SS_VAR
 .       \}
 .       ev
 .\" Restore lead -- need 
 .       nr #PP_STYLE \\n[#PP_STYLE_PREV]
-.       if !\\n[#INDENT_FIRSTS] \{ .INDENT_FIRST_PARAS OFF \}
+.       if !\\n[#INDENT_FIRSTS] .INDENT_FIRST_PARAS OFF
 .       rr #INDENT_FIRSTS
 .       rr #ENDNOTE
 .       if \\n[#UNDERLINE_WAS_ON] \{\
@@ -14878,12 +13762,11 @@
 .       \}
 .    \}
 .    if \\n[#NUM_ARGS]=2 \{\
-.       if '\\$2'BREAK' \{ .BR \}
-.       if '\\$2'BR' \{ .BR \}
+.       if '\\$2'BREAK' .BR
+.       if '\\$2'BR' .BR
 .    \}
 .END
 \#
-\#
 \# ENDNOTES
 \# --------
 \# *Arguments:
@@ -14904,27 +13787,28 @@
 .       nr #LINENUMBERS 2
 .    \}
 .    if \\n[#HEADERS_ON]=1 \{\
-.       if !\\n[#EN_ALLOWS_HEADERS_ALL] \{ .HEADERS OFF \}
+.       if !\\n[#EN_ALLOWS_HEADERS_ALL] .HEADERS OFF
 .    \}
 .    if \\n[#HEADER_STATE]=1 \{\
-.       ie \\n[#EN_HDRFTR_CENTER]=1 \{ . \}
-.       el \{ .rm $HDRFTR_CENTER  \}
+.       ie \\n[#EN_HDRFTR_CENTER]=1 .
+.       el .rm $HDRFTR_CENTER
 .    \}
 .    ie !\\n[#SUSPEND_PAGINATION] \{\
 .       if \\n[#PAGINATE]=1 \{\
 .          if \\n[#PAGE_NUM_V_POS]=1 \{\
 .             PAGENUM_STYLE \\*[$EN_PN_STYLE]
-.             if \\n[#EN_FIRST_PN] \{ .PAGENUMBER \\n[#EN_FIRST_PN]-1 \}
-.             if r#EN_NO_FIRST_PN \{ .nr #PAGINATE 0 \}
+.             if \\n[#EN_FIRST_PN] .PAGENUMBER \\n[#EN_FIRST_PN]-1
+.             if r #EN_NO_FIRST_PN .nr #PAGINATE 0
 .          \}
 .       \}
 .    \}
 .    el \{\
-.       ie \\n[#PAGE_NUM_V_POS]=2 \{ .nr #PAGINATE 1 \}
-.       el \{ .nr #PAGINATE 0 \}
+.       ie \\n[#PAGE_NUM_V_POS]=2 .nr #PAGINATE 1
+.       el .nr #PAGINATE 0
 .    \}
 .    if \\n[#FOOTERS_ON]=1 \{\
-.       if !'\\*[$HDRFTR_CENTER_OLD]'' .ds $HDRFTR_CENTER 
\\*[$HDRFTR_CENTER_OLD]
+.       if !'\\*[$HDRFTR_CENTER_OLD]'' \
+.          ds $HDRFTR_CENTER \\*[$HDRFTR_CENTER_OLD]
 .    \}
 .    NEWPAGE
 .    if \\n[#FOOTERS_ON]=1 \{\
@@ -14934,82 +13818,46 @@
 .    \}
 .    ie !\\n[#SUSPEND_PAGINATION] \{\
 .       if \\n[#PAGE_NUM_V_POS]=1 \{\
-.          if r#EN_NO_FIRST_PN \{\
-.             if \\n[#PAGINATION_STATE]=1 \{\
-.                nr #PAGINATE 1
-.             \}
+.          if r #EN_NO_FIRST_PN \{\
+.             if \\n[#PAGINATION_STATE]=1 .nr #PAGINATE 1
 .          \}
 .       \}
 .    \}
 .    el \{\
-.       if \\n[#PAGE_NUM_V_POS]=2 \{ .nr #PAGINATE 0 \}
+.       if \\n[#PAGE_NUM_V_POS]=2 .nr #PAGINATE 0
 .    \}
 .    rr #PAGINATION_STATE
 .    PAGENUM_STYLE \\*[$EN_PN_STYLE]
-.    if \\n[#EN_FIRST_PN] \{ .PAGENUMBER \\n[#EN_FIRST_PN] \}
+.    if \\n[#EN_FIRST_PN] .PAGENUMBER \\n[#EN_FIRST_PN]
 .    if \\n[#HEADER_STATE]=1 \{\
-.       if \\n[#EN_ALLOWS_HEADERS] \{ .HEADERS \}
+.       if \\n[#EN_ALLOWS_HEADERS] .HEADERS
 .    \}
 .\" Collect endnotes title string for TOC
 .    nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ]
 .    af #TOC_ENTRY_PN \\g[#PAGENUMBER]
 .    ds $TOC_TITLE_ITEM \\*[$EN_STRING]\\|
-.    ev TOC_EV
-.    da TOC_ENTRIES
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       TYPEWRITER
-.    \}
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_TITLE_FAM]
-\!.     FT      \\*[$TOC_TITLE_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_TITLE_SIZE_CHANGE]
-.    \}
-\!.  TRAP OFF
-\!.  PAD_MARKER ^
-.    ie \\n[#PRINT_STYLE]=1 \{\
-\!.     PAD "\\*[$TOC_TITLE_ITEM]\\*[$TOC_PN_TYPEWRITE]"
-.    \}
-.    el \{\
-\!.     PAD "\\h'\\n[#TOC_TITLE_INDENT]u'\\*[$TOC_TITLE_ITEM]\\*[$TOC_PN]"
-.    \}
-\!.  PAD_MARKER #
-\!.  EOL
-\!.  ST 100 L
-\!.  ST 101 R
-.    if \\n[#PRINT_STYLE]=2 \{\
-\!.     FAMILY  \\*[$TOC_PN_FAM]
-\!.     FT      \\*[$TOC_PN_FT]
-\!.     PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
-.    \}
-\!.  TAB 100
-\!.  PRINT \\*[LEADER]
-\!.  TN
-\!.  TRAP
-\!.  PRINT \\n[#TOC_ENTRY_PN]
-\!.  TQ
-.    di
-.    ev
+.    PDF_BOOKMARK 1 \\*[$EN_STRING]
+.    TITLE_TO_TOC
 .\" End collection of endnotes title string for TOC
 .\" Process endnotes
-.    if \\n[#PRINT_STYLE]=1 \{ .vs \\n[#EN_LEAD]u \}
+.    if \\n[#PRINT_STYLE]=1 .vs \\n[#EN_LEAD]u
 .    if \\n[#PRINT_STYLE]=2 \{\
 .       if \\n[#EN_NO_COLS] \{\
-.          if \\n[#COLUMNS] \{ .nr #COLUMNS_WERE_ON 1 \}
+.          if \\n[#COLUMNS] .nr #COLUMNS_WERE_ON 1
 .          nr #COLUMNS 0
 .       \}
 .       nr #RESTORE_DOC_LEAD \\n[#DOC_LEAD]
-.       ie \\n[#ADJ_EN_LEAD] \{\
-.          nr #DOC_LEAD \\n[#EN_LEAD]
-.       \}
-.       el \{ .DOC_LEAD \\n[#EN_LEAD]u \}
+.       ie \\n[#ADJ_EN_LEAD] .nr #DOC_LEAD \\n[#EN_LEAD]
+.       el .DOC_LEAD \\n[#EN_LEAD]u
 .    \}
 .    PRINT \&
-.    ie r#EN_STRING_ADVANCE \{ .sp |\\n[#EN_STRING_ADVANCE]u \}
-.    el \{ .sp |\\n[#T_MARGIN]u \}
+.    ie r#EN_STRING_ADVANCE .sp |\\n[#EN_STRING_ADVANCE]u
+.    el .sp |\\n[#T_MARGIN]u
 .    mk ec
 .    if \\n[#SLANT_ON] \{\
 \*[SLANTX]\c
 .    \}
+.    sp
 .    ev ENDNOTES
 .    if !'\\*[$EN_STRING]'' \{\
 .       if \\n[#PRINT_STYLE]=1 \{\
@@ -15018,11 +13866,11 @@
 .       \}
 .       if \\n[#PRINT_STYLE]=2 \{\
 .          LL \\n[#DOC_L_LENGTH]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .          if \\n[#COLUMNS] \{\
-.             ie \\n[#EN_NO_COLS] \{ .LL \\n[#DOC_L_LENGTH]u \}
-.             el \{ .LL \\n[#COL_L_LENGTH]u \}
-.             ta \\n(.lu
+.             ie \\n[#EN_NO_COLS] .LL \\n[#DOC_L_LENGTH]u
+.             el .LL \\n[#COL_L_LENGTH]u
+.             ta \\n[.l]u
 .          \}
 .          FAMILY  \\*[$EN_STRING_FAM]
 .          FT      \\*[$EN_STRING_FT]
@@ -15035,60 +13883,49 @@
 .             TRAP
 .          \}
 .       \}
-.       if '\\*[$EN_STRING_QUAD]'L'      \{ .LEFT   \}
-.       if '\\*[$EN_STRING_QUAD]'LEFT'   \{ .LEFT   \}
-.       if '\\*[$EN_STRING_QUAD]'C'      \{ .CENTER \}
-.       if '\\*[$EN_STRING_QUAD]'CENTER' \{ .CENTER \}
-.       if '\\*[$EN_STRING_QUAD]'CENTRE' \{ .CENTER \}
-.       if '\\*[$EN_STRING_QUAD]'R'      \{ .RIGHT  \}
-.       if '\\*[$EN_STRING_QUAD]'RIGHT'  \{ .RIGHT  \}
+.       if '\\*[$EN_STRING_QUAD]'L'      .LEFT
+.       if '\\*[$EN_STRING_QUAD]'LEFT'   .LEFT
+.       if '\\*[$EN_STRING_QUAD]'C'      .CENTER
+.       if '\\*[$EN_STRING_QUAD]'CENTER' .CENTER
+.       if '\\*[$EN_STRING_QUAD]'CENTRE' .CENTER
+.       if '\\*[$EN_STRING_QUAD]'R'      .RIGHT
+.       if '\\*[$EN_STRING_QUAD]'RIGHT'  .RIGHT
 .       EOL
-.       if \\n[#EN_STRING_CAPS] \{ .CAPS \}
+.       if \\n[#EN_STRING_CAPS] .CAPS
 .       ie \\n[#EN_STRING_UNDERLINE] \{\
 .          nr #FROM_EN_STRING 1
-.          ie \\n[#EN_STRING_UNDERLINE]=2 \{\
+.          ie \\n[#EN_STRING_UNDERLINE]=2 \
 .             UNDERSCORE2 \\*[$EN_UNDERLINE_GAP] \\*[$EN_RULE_GAP] 
"\\*[$EN_STRING]"
 .          \}
-.          el \{\
-.             UNDERSCORE "\\*[$EN_STRING]"
-.          \}
+.          el .UNDERSCORE "\\*[$EN_STRING]"
 .          rr #FROM_EN_STRING
 .       \}
-.       el \{\
-.          PRINT "\\*[$EN_STRING]
-.       \}
+.       el .PRINT "\\*[$EN_STRING]
 .    \}
 .    CAPS OFF
 .    if \\n[#PRINT_STYLE]=1 \{\
-.       ie \\n[#SINGLE_SPACE]=1 \{\
-.          sp
-.       \}
-.       el \{\
-.          ie \\n[#EN_SINGLESPACE]=1 \{\
-.             sp
-.          \}
+.       ie \\n[#SINGLE_SPACE]=1 .sp
 .          el \{\
-.
-.          \}
+.          ie \\n[#EN_SINGLESPACE]=1 .sp
+.          el .
 .       \}
 .    \}
-.    if \\n[#PRINT_STYLE]=2 \{ .ALD \\n[#EN_LEAD]u \}
+.    if \\n[#PRINT_STYLE]=2 .ALD \\n[#EN_LEAD]u
 .    QUAD \\*[$EN_QUAD]
 .    chop END_NOTES
 .    nf
 .    END_NOTES
 .    ev
 .    rm END_NOTES
-.    if \\n[#PRINT_STYLE]=1 \{ .vs \\n[#DOC_LEAD]u \}
+.    if \\n[#PRINT_STYLE]=1 .vs \\n[#DOC_LEAD]u
 .    if \\n[#PRINT_STYLE]=2 \{\
-.       ie \\n[#ADJ_EN_LEAD] \{\
+.       ie \\n[#ADJ_EN_LEAD] \
 .          nr #DOC_LEAD \\n[#RESTORE_DOC_LEAD]
-.       \}
-.       el \{ .DOC_LEAD \\n[#RESTORE_DOC_LEAD]u \}
+.       el .DOC_LEAD \\n[#RESTORE_DOC_LEAD]u
 .       rr #RESTORE_DOC_LEAD
 .    \}
-.    if \\n[#COLUMNS_WERE_ON] \{ .nr #COLUMNS 1 \}
-.    if \\n[#HEADER_STATE]=1 \{ .HEADERS \}
+.    if \\n[#COLUMNS_WERE_ON] .nr #COLUMNS 1
+.    if \\n[#HEADER_STATE]=1 .HEADERS
 .    if \\n[#LINENUMBERS]=2 \{\
 .       NUMBER_LINES RESUME
 .       nr #LINENUMBERS 1
@@ -15109,15 +13946,8 @@
 \# commands.
 \# 
 \# All of the bibliography control macros have their exact
-\# counterparts in the endnotes control macros.  It was tempting to do
-\# fancy stuff with aliases to avoid the repetition, but for reasons
-\# of my own sanity, and for the benefit of anyone wanting to play
-\# around with the bibliography control macros, I decided to keep them
-\# separate.
-\# 
-\# Because the bibliography control macros all have endnotes
-\# equivalents, refer to the appropriate, similar endnote macro for
-\# Arguments, Function and Notes.
+\# counterparts in the endnotes control macros.  See, therefore,
+\# Arguments, Functions, and Notes in the Endnotes section.
 \#
 \# Bibliography control macros
 \#
@@ -15126,8 +13956,8 @@
 .END
 \#
 .MAC BIBLIOGRAPHY_HDRFTR_CENTER END
-.    ie '\\$1'' \{ .nr #BIB_HDRFTR_CENTER 1 \}
-.    el         \{ .rr #BIB_HDRFTR_CENTER   \}
+.    ie '\\$1'' .nr #BIB_HDRFTR_CENTER 1
+.    el .rr #BIB_HDRFTR_CENTER
 .END
 \#
 .MAC BIBLIOGRAPHY_STRING END
@@ -15139,22 +13969,22 @@
 .END
 \#
 .MAC BIBLIOGRAPHY_STRING_CAPS END
-.   ie '\\$1'' \{ .nr #BIB_STRING_CAPS 1 \}
-.   el \{ .nr #BIB_STRING_CAPS 0 \}
+.   ie '\\$1'' .nr #BIB_STRING_CAPS 1
+.   el .nr #BIB_STRING_CAPS 0
 .END
 \#
 .MAC BIBLIOGRAPHY_NO_COLUMNS END
-.    ie '\\$1'' \{ .nr #BIB_NO_COLS 1 \}
-.    el \{ .rr #BIB_NO_COLS \}
+.    ie '\\$1'' .nr #BIB_NO_COLS 1
+.    el .rr #BIB_NO_COLS
 .END
 \#
 .MAC BIBLIOGRAPHY_NO_FIRST_PAGENUM END
-.    ie '\\$1'' \{ .nr #BIB_NO_FIRST_PN 1 \}
-.    el \{ .rr #BIB_NO_FIRST_PN \}
+.    ie '\\$1'' .nr #BIB_NO_FIRST_PN 1
+.    el .rr #BIB_NO_FIRST_PN
 .END
 \#
 .MAC BIBLIOGRAPHY_ALLOWS_HEADERS END
-.    ie '\\$1'' \{ .nr #BIB_ALLOWS_HEADERS 1 \}
+.    ie '\\$1'' .nr #BIB_ALLOWS_HEADERS 1
 .    el \{\
 .       ie '\\$1'ALL' \{\
 .          nr #BIB_ALLOWS_HEADERS 1
@@ -15206,7 +14036,6 @@
 .    \}
 .END
 \#
-\#
 \# Style for outputting collected bibliographic references
 \# -------------------------------------------------------
 \# *Argument:
@@ -15231,7 +14060,7 @@
 .       ie '\\$3'' .ds $BIB_LIST_PREFIX
 .       el .ds $BIB_LIST_PREFIX \\$3
 .    \}
-.    el \{ .nr #BIB_LIST 0 \}
+.    el .nr #BIB_LIST 0
 .END
 \#
 \# Spacing between items in bibliographies
@@ -15255,9 +14084,7 @@
 .       substring $BIB_SPACE 0 0
 .       nr #BIB_SPACE \\n[#BIB_LEAD]*\\*[$BIB_SPACE]
 .    \}
-.    el \{\
-.       nr #BIB_SPACE (\\$1)
-.    \}
+.    el .nr #BIB_SPACE (\\$1)
 .END
 \#
 \# Set up bibliography page
@@ -15282,27 +14109,28 @@
 .          nr #LINENUMBERS 2
 .       \}
 .       if \\n[#HEADERS_ON]=1 \{\
-.          if !\\n[#BIB_ALLOWS_HEADERS_ALL] \{ .HEADERS OFF \}
+.          if !\\n[#BIB_ALLOWS_HEADERS_ALL] .HEADERS OFF
 .       \}
 .       if \\n[#HEADER_STATE]=1 \{\
-.          ie \\n[#BIB_HDRFTR_CENTER]=1 \{ . \}
-.          el \{ .rm $HDRFTR_CENTER  \}
+.          ie \\n[#BIB_HDRFTR_CENTER]=1 .
+.          el .rm $HDRFTR_CENTER
 .       \}
 .       ie !\\n[#SUSPEND_PAGINATION] \{\
 .          if \\n[#PAGINATE]=1 \{\
 .             if \\n[#PAGE_NUM_V_POS]=1 \{\
 .                PAGENUM_STYLE \\*[$BIB_PN_STYLE]
-.                if \\n[#BIB_FIRST_PN] \{ .PAGENUMBER \\n[#BIB_FIRST_PN]-1 \}
-.                if r#BIB_NO_FIRST_PN \{ .nr #PAGINATE 0 \}
+.                if \\n[#BIB_FIRST_PN] .PAGENUMBER \\n[#BIB_FIRST_PN]-1
+.                if r #BIB_NO_FIRST_PN .nr #PAGINATE 0
 .             \}
 .          \}
 .       \}
 .       el \{\
-.          ie \\n[#PAGE_NUM_V_POS]=2 \{ .nr #PAGINATE 1 \}
-.          el \{ .nr #PAGINATE 0 \}
+.          ie \\n[#PAGE_NUM_V_POS]=2 .nr #PAGINATE 1
+.          el .nr #PAGINATE 0
 .       \}
 .       if \\n[#FOOTERS_ON]=1 \{\
-.          if !'\\*[$HDRFTR_CENTER_OLD]'' .ds $HDRFTR_CENTER 
\\*[$HDRFTR_CENTER_OLD]
+.          if !'\\*[$HDRFTR_CENTER_OLD]'' \
+.             ds $HDRFTR_CENTER \\*[$HDRFTR_CENTER_OLD]
 .       \}
 .       BIBLIOGRAPHY_LEAD \\*[$BIB_LEAD] \\*[$ADJUST_BIB_LEAD]
 .       DOC_LEAD \\n[#BIB_LEAD]u
@@ -15314,7 +14142,7 @@
 .       \}
 .       ie !\\n[#SUSPEND_PAGINATION] \{\
 .          if \\n[#PAGE_NUM_V_POS]=1 \{\
-.             if r#BIB_NO_FIRST_PN \{\
+.             if r #BIB_NO_FIRST_PN \{\
 .                if \\n[#PAGINATION_STATE]=1 \{\
 .                   nr #PAGINATE 1
 .                \}
@@ -15322,74 +14150,40 @@
 .          \}
 .       \}
 .       el \{\
-.          if \\n[#PAGE_NUM_V_POS]=2 \{ .nr #PAGINATE 0 \}
+.          if \\n[#PAGE_NUM_V_POS]=2 .nr #PAGINATE 0
 .       \}
 .       rr #PAGINATION_STATE
 .       PAGENUM_STYLE \\*[$BIB_PN_STYLE]
-.       if \\n[#BIB_FIRST_PN] \{ .PAGENUMBER \\n[#BIB_FIRST_PN] \}
+.       if \\n[#BIB_FIRST_PN] .PAGENUMBER \\n[#BIB_FIRST_PN]
 .       if \\n[#HEADER_STATE]=1 \{\
-.          if \\n[#BIB_ALLOWS_HEADERS] \{ .HEADERS \}
+.          if \\n[#BIB_ALLOWS_HEADERS] .HEADERS
 .       \}
 .\" Collect bibliography title string for TOC
 .       nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ]
 .       af #TOC_ENTRY_PN \\g[#PAGENUMBER]
 .       ds $TOC_TITLE_ITEM \\*[$BIB_STRING]\\|
-.       ev TOC_EV
-.       da TOC_ENTRIES
-.       if \\n[#PRINT_STYLE]=1 \{\
-.          TYPEWRITER
-.       \}
-.       if \\n[#PRINT_STYLE]=2 \{\
-\!.        FAMILY  \\*[$TOC_TITLE_FAM]
-\!.        FT      \\*[$TOC_TITLE_FT]
-\!.        PT_SIZE \\n[#TOC_PS]u\\*[$TOC_TITLE_SIZE_CHANGE]
-.       \}
-\!.     TRAP OFF
-\!.     PAD_MARKER ^
-.       ie \\n[#PRINT_STYLE]=1 \{\
-\!.        PAD "\\*[$TOC_TITLE_ITEM]\\*[$TOC_PN_TYPEWRITE]"
-.       \}
-.       el \{\
-\!.        PAD "\\h'\\n[#TOC_TITLE_INDENT]u'\\*[$TOC_TITLE_ITEM]\\*[$TOC_PN]"
-.       \}
-\!.     PAD_MARKER #
-\!.     EOL
-\!.     ST 100 L
-\!.     ST 101 R
-.       if \\n[#PRINT_STYLE]=2 \{\
-\!.        FAMILY  \\*[$TOC_PN_FAM]
-\!.        FT      \\*[$TOC_PN_FT]
-\!.        PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
-.       \}
-\!.     TAB 100
-\!.     PRINT \\*[LEADER]
-\!.     TN
-\!.     TRAP
-\!.     PRINT \\n[#TOC_ENTRY_PN]
-\!.     TQ
-.       di
-.       ev
+.       PDF_BOOKMARK 1 \\*[$BIB_STRING]
+.       TITLE_TO_TOC
 .\" End collection of bibliography title string for TOC
 .\" Process bibliography
-.       if \\n[#PRINT_STYLE]=1 \{ .vs \\n[#BIB_LEAD]u \}
+.       if \\n[#PRINT_STYLE]=1 .vs \\n[#BIB_LEAD]u
 .       if \\n[#PRINT_STYLE]=2 \{\
 .          if \\n[#BIB_NO_COLS] \{\
-.             if \\n[#COLUMNS] \{ .nr #COLUMNS_WERE_ON 1 \}
+.             if \\n[#COLUMNS] .nr #COLUMNS_WERE_ON 1
 .             nr #COLUMNS 0
 .          \}
 .          nr #RESTORE_DOC_LEAD \\n[#DOC_LEAD]
-.          ie \\n[#ADJ_BIB_LEAD] \{\
-.             nr #DOC_LEAD \\n[#BIB_LEAD]
-.          \}
-.          el \{ .DOC_LEAD \\n[#BIB_LEAD]u \}
+.          ie \\n[#ADJ_BIB_LEAD] .nr #DOC_LEAD \\n[#BIB_LEAD]
+.          el .DOC_LEAD \\n[#BIB_LEAD]u
 .       \}
 .       PRINT \&
-.       ie r#BIB_STRING_ADVANCE \{ .sp |\\n[#BIB_STRING_ADVANCE]u \}
-.       el \{ .sp |\\n[#T_MARGIN]u \}
+.       ie r#BIB_STRING_ADVANCE .sp |\\n[#BIB_STRING_ADVANCE]u
+.       el .sp |\\n[#T_MARGIN]u
 .       mk ec
 .       if \\n[#SLANT_ON] \{\
 \*[SLANTX]\c
 .       \}
+.       sp
 .       if !'\\*[$BIB_STRING]'' \{\
 .          if \\n[#PRINT_STYLE]=1 \{\
 .             TYPEWRITER
@@ -15397,106 +14191,273 @@
 .          \}
 .          if \\n[#PRINT_STYLE]=2 \{\
 .             LL \\n[#DOC_L_LENGTH]u
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .             if \\n[#COLUMNS] \{\
-.                ie \\n[#BIB_NO_COLS] \{ .LL \\n[#DOC_L_LENGTH]u \}
-.                el \{ .LL \\n[#COL_L_LENGTH]u \}
-.                ta \\n(.lu
+.                ie \\n[#BIB_NO_COLS] .LL \\n[#DOC_L_LENGTH]u
+.                el .LL \\n[#COL_L_LENGTH]u
+.                ta \\n[.l]u
 .             \}
 .             FAMILY  \\*[$BIB_STRING_FAM]
 .             FT      \\*[$BIB_STRING_FT]
 .             PT_SIZE \\n[#BIB_PS]u\\*[$BIB_STRING_SIZE_CHANGE]
 .             vs      \\n[#BIB_LEAD]u
 .          \}
-.          if '\\*[$BIB_STRING_QUAD]'L'      \{ .LEFT   \}
-.          if '\\*[$BIB_STRING_QUAD]'LEFT'   \{ .LEFT   \}
-.          if '\\*[$BIB_STRING_QUAD]'C'      \{ .CENTER \}
-.          if '\\*[$BIB_STRING_QUAD]'CENTER' \{ .CENTER \}
-.          if '\\*[$BIB_STRING_QUAD]'CENTRE' \{ .CENTER \}
-.          if '\\*[$BIB_STRING_QUAD]'R'      \{ .RIGHT  \}
-.          if '\\*[$BIB_STRING_QUAD]'RIGHT'  \{ .RIGHT  \}
+.          if '\\*[$BIB_STRING_QUAD]'L'      .LEFT
+.          if '\\*[$BIB_STRING_QUAD]'LEFT'   .LEFT
+.          if '\\*[$BIB_STRING_QUAD]'C'      .CENTER
+.          if '\\*[$BIB_STRING_QUAD]'CENTER' .CENTER
+.          if '\\*[$BIB_STRING_QUAD]'CENTRE' .CENTER
+.          if '\\*[$BIB_STRING_QUAD]'R'      .RIGHT
+.          if '\\*[$BIB_STRING_QUAD]'RIGHT'  .RIGHT
 .          EOL
-.          if \\n[#BIB_STRING_CAPS] \{ .CAPS \}
+.          if \\n[#BIB_STRING_CAPS] .CAPS
 .          ie \\n[#BIB_STRING_UNDERLINE] \{\
 .             nr #FROM_BIB_STRING 1
-.             ie \\n[#BIB_STRING_UNDERLINE]=2 \{\
+.             ie \\n[#BIB_STRING_UNDERLINE]=2 \
 .                UNDERSCORE2 "\\*[$BIB_STRING]"
-.             \}
-.             el \{\
+.             el \
 .                UNDERSCORE "\\*[$BIB_STRING]"
-.             \}
 .             rr #FROM_BIB_STRING
 .          \}
-.          el \{\
-.             PRINT "\\*[$BIB_STRING]"
-.          \}
+.          el .PRINT "\\*[$BIB_STRING]"
 .       \}
 .       CAPS OFF
 .       FAMILY \\*[$BIB_FAMILY]
 .       FT \\*[$BIB_FT]
 .       PT_SIZE -\\*[$BIB_STRING_SIZE_CHANGE]
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          ie \\n[#SINGLE_SPACE]=1 \{\
-.             ALD \\n[#BIB_LEAD]*3u
-.          \}
+.          ie \\n[#SINGLE_SPACE]=1 .ALD \\n[#BIB_LEAD]*3u
 .          el \{\
-.             ie \\n[#BIB_SINGLESPACE]=1 \{\
-.                ALD \\n[#BIB_LEAD]u*3u
+.             ie \\n[#BIB_SINGLESPACE]=1 .ALD \\n[#BIB_LEAD]u*3u
+.             el .ALD \\n[#BIB_LEAD]u
+.          \}
 .             \}
+.       if \\n[#PRINT_STYLE]=2 .ALD \\n[#BIB_LEAD]u*2u
+.       QUAD \\*[$BIB_QUAD]
+.       if \\n[#PRINT_STYLE]=1 \{\
+.          ie \\n[#SINGLE_SPACE]=1 .vs \\n[#BIB_LEAD]u
 .             el \{\
-.                ALD \\n[#BIB_LEAD]u
+.             ie \\n[#BIB_SINGLESPACE]=1 .vs \\n[#BIB_LEAD]u
+.             el .vs \\n[#BIB_LEAD]u
 .             \}
 .          \}
+.       if \\n[#PRINT_STYLE]=2 \{\
+.          ie \\n[#ADJ_BIB_LEAD] \
+.             nr #DOC_LEAD \\n[#RESTORE_DOC_LEAD]
+.          el .DOC_LEAD \\n[#RESTORE_DOC_LEAD]u
+.          rr #RESTORE_DOC_LEAD
 .       \}
-.       if \\n[#PRINT_STYLE]=2 \{ .ALD \\n[#BIB_LEAD]u*2u \}
-.       QUAD \\*[$BIB_QUAD]
+.       if \\n[#COLUMNS_WERE_ON] .nr #COLUMNS 1
+.       if \\n[#HEADER_STATE]=1 .HEADERS
+.       if \\n[#LINENUMBERS]=2 \{\
+.          NUMBER_LINES RESUME
+.          nr #LINENUMBERS 1
+.       \}
+.       di BIB
+.    \}
+.    el \{\
+.       br
+.       di
+.\" Part of workaround for refer spitting out a blank page if the
+.\" last ref falls on the bottom line.
+.       nr num*refs \\n[ref*num*first-pass]
+.       nf
+.       BIB
+.    \}
+.END
+\#
+\# ====================================================================
+\#
+\# +++TABLE OF CONTENTS+++
+\#
+\# Strings to allocate space for leaders and entry page numbers
+\#
+.ds $TOC_PN \\*[ST100]\F[\\*[$TOC_PN_FAM]]\f[\\*[$TOC_PN_FT]]\
+\s[\\n[#TOC_PS]u]^\\*[ST100X]\\*[ST101]\s[\\*[$TOC_PN_SIZE_CHANGE]]\|\
+\h'\w'0'u*\\n[#TOC_PN_PADDING]u'\*[ST101X]
+\#
+.ds $TOC_PN_TYPEWRITE \\*[ST100]^\\*[ST100X]\\*[ST101]\|\
+\h'\w'0'u*\\n[#TOC_PN_PADDING]u'\\*[ST101X]
+\#
+\# TOC collector
+\#
+.MAC TITLE_TO_TOC END
+.    if !'\\n[.ev]'TOC_EV' .ev TOC_EV
+.    nr #TOC_CH_NUM_INDENT \w'\\*[$TOC_CH_NUM]'
+.    da TOC_ENTRIES
+\!.  ie \\\\n[#SKIP_ENTRY]=1 \{\
+.     rr #SKIP_ENTRY
+\!.  \}
+\!.  el \{\
+.       br
 .       if \\n[#PRINT_STYLE]=1 \{\
-.          ie \\n[#SINGLE_SPACE]=1 \{\
-.             vs \\n[#BIB_LEAD]u
+\!.        fam \\*[$TYPEWRITER_FAM]
+\!.        ft  R
+\!.        ps \\*[$TYPEWRITER_PS]
+.          ds _TYPEWRITE _TYPEWRITE
+.       \}
+.       if \\n[#PRINT_STYLE]=2 \{\
+.          ie '\\$0'HD_TO_TOC' \{\
+\!.           PT_SIZE \\n[#TOC_PS]u\\*[$TOC_HEAD_\\n[#LEVEL]_SIZE]
 .          \}
 .          el \{\
-.             ie \\n[#BIB_SINGLESPACE]=1 \{\
-.                vs \\n[#BIB_LEAD]u
+\!.           FAMILY  \\*[$TOC_TITLE_FAM]
+\!.           FT      \\*[$TOC_TITLE_FT]
+\!.           PT_SIZE \\n[#TOC_PS]u\\*[$TOC_TITLE_SIZE]
+.          \}
+.       \}
+.       if \\n[#PRINT_STYLE]=2 \{\
+.          rm _TYPEWRITE
+.          if \\n[#SPACE_TOC_ITEMS] \{\
+.             if \\n[#POST_TOP]=1 \{\
+.                ie !\\n[#LEVEL]=\\n[#LAST_LEVEL] \{\
+.                   ie \\n[#LEVEL]>\\n[#LAST_LEVEL] \!.sp .2v
+.                   el \!.sp .4v
 .             \}
 .             el \{\
-.                vs \\n[#BIB_LEAD]u
+.                   if \\n[#COLLATED_DOC] \
+.                      if '\\$0'TITLE_TO_TOC' \!.sp .4v
+.                \}
+.             \}
+.          \}
+.       \}
+\!.     ne 1
+\!.     PAD_MARKER ^
+.       if !'\\$0'HD_TO_TOC' \{\
+\!.        if \\n[#TOC_TITLE_CAPS]=1 .CAPS
+.       \}
+.       if '\\$0'HD_TO_TOC' \{\
+.          nr #POST_TOP 1
+\!.        if \\n[#TOC_HEAD_\\n[#LEVEL]_CAPS]=1 .CAPS
+.       \}
+\!.     vpt 0
+.       ie '\\$0'HD_TO_TOC' \{\
+\!.        PAD \
+"\\f[\\*[$TOC_HEAD_\\n[#LEVEL]_FAM]\
+\\*[$TOC_HEAD_\\n[#LEVEL]_FT]]\
+\h'\\\\n[#TOC_INDENT_ADJ]u'\h'\\n[#TOC_HEAD_\\n[#LEVEL]_INDENT]u'\
+\\*[$TOC_HD_NUM]\\*[$TOC_HEAD_\\n[#LEVEL]_ITEM]\\*[$TOC_PN\\*[_TYPEWRITE]]" \
+"\\*[PDFBOOKMARK.NAME]"
+.       \}
+.       el \{\
+\!.        PAD \
+"\\f[\\*[$TOC_TITLE_FAM]\\*[$TOC_TITLE_FT]]\
+\h'\\n[#TOC_TITLE_INDENT]u'\\*[$TOC_TITLE_ITEM]\\*[$TOC_PN\\*[_TYPEWRITE]]" \
+"\\*[PDFBOOKMARK.NAME]"
+.       \}
+.       if '\\$0'HD_TO_TOC' \{\
+\!.        if \\n[#TOC_HEAD_\\n[#LEVEL]_CAPS]=1 .CAPS OFF
+.       \}
+.       if !'\\$0'HD_TO_TOC' \{\
+\!.        if \\n[#TOC_TITLE_CAPS]=1 .CAPS OFF
+.       \}
+\!.     PAD_MARKER #
+\!.     EOL
+\!.     ST 100 L
+\!.     ST 101 R
+.       if \\n[#PRINT_STYLE]=2 \{\
+\!.        FAMILY  \\*[$TOC_PN_FAM]
+\!.        FT      \\*[$TOC_PN_FT]
+\!.        PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
 .             \}
+\!.     TAB 100
+\!.     PRINT \\*[LEADER]\c
+\!.     TN
+\!.     PRINT \\n[#TOC_ENTRY_PN]
+\!.     TQ
+\!.     vpt
+\!. \}
+.   da
+.   ev
+.END
+\#
+.ALIAS HD_TO_TOC TITLE_TO_TOC
+\#
+\# Control macros for toc
+\# ----------------------
+\#
+\# TOC TITLE STYLE
+\# ---------------
+\# *Arguments:
+\#   FAMILY <family>
+\#   FONT   <font>
+\#   SIZE   <+|-n>
+\#   COLOR  <color>
+\#   CAPS
+\#   INDENT
+\# *Function:
+\#   Assigns complete style parameters to TITLEs (doc titles,
+\#   chapter titles, etc) in the TOC.
+\# *Notes:
+\#   TITLEs are not headings, therefore they require their own style
+\#   macro.  Otherwise, the same as TOC_ENTRY_STYLE.
+\#
+.MAC TOC_TITLE_STYLE END
+.    nr #ARG_NUM 0 1
+.    nr #ATTRIB \\n[#NUM_ARGS]
+.    while \\n+[#ARG_NUM]<=\\n[#ATTRIB] \{\
+.       if '\\$1'FAMILY' \{\
+.          shift
+.          ds $TOC_TITLE_FAM  \\$1
+.          shift
 .          \}
+.       if '\\$1'FONT' \{\
+.          shift
+.          ds $TOC_TITLE_FT   \\$1
+.          shift
 .       \}
-.       if \\n[#PRINT_STYLE]=2 \{\
-.          ie \\n[#ADJ_BIB_LEAD] \{\
-.             nr #DOC_LEAD \\n[#RESTORE_DOC_LEAD]
+.       if '\\$1'SIZE' \{\
+.          shift
+.          ds $TOC_TITLE_SIZE \\$1
+.          shift
 .          \}
-.          el \{ .DOC_LEAD \\n[#RESTORE_DOC_LEAD]u \}
-.          rr #RESTORE_DOC_LEAD
+.       if '\\$1'CAPS' \{\
+.          nr #TOC_TITLE_CAPS 1
+.          shift
 .       \}
-.       if \\n[#COLUMNS_WERE_ON] \{ .nr #COLUMNS 1 \}
-.       if \\n[#HEADER_STATE]=1 \{ .HEADERS \}
-.       if \\n[#LINENUMBERS]=2 \{\
-.          NUMBER_LINES RESUME
-.          nr #LINENUMBERS 1
+.       if '\\$1'NO_CAPS' \{\
+.          rr #TOC_TITLE_CAPS
+.          shift
 .       \}
-.       di BIB
+.       if '\\$1'INDENT' \{\
+.          shift
+.          nr #TOC_TITLE_INDENT \\$1
+.          shift
 .    \}
-.    el \{\
-.       br
-.       di
-.\" Part of workaround for refer spitting out a blank page if the
-.\" last ref falls on the bottom line.
-.       nr num*refs \\n[ref*num*first-pass]
-.       nf
-.       BIB
 .    \}
 .END
 \#
-\# ====================================================================
+\# TOC HEADER STRING
+\# -----------------
+\# *Argument:
+\#   <string for "doc header" of first toc page>
+\# *Function:
+\#   Creates or modifies string $TOC_HEADER_STRING
+\# *Notes:
+\#   Default is "Contents".
 \#
-\# +++TABLE OF CONTENTS+++
+.MAC TOC_HEADER_STRING END
+.    ds $TOC_HEADER_STRING \\$1
+.END
 \#
-\# Strings to allocate space for leaders and entry page numbers
+\# TOC POINT SIZE
+\# --------------
+\# *Argument:
+\#   <base point size for toc pages>
+\# *Function:
+\#   Creates or modifies register #TOC_PS.
+\# *Notes:
+\#   This size control macro differs from other size control macros
+\#   in that it sets an absolute point size, not a relative one.
+\#   See notes for ENDNOTE_PT_SIZE for explanation.  No unit of
+\#   measure required.
+\#
+\#   No unit of measure required (points assumed).  Default is 12.5
+\#   for TYPESET.
 \#
-.ds $TOC_PN 
\\*[ST100]\\F[\\*[$TOC_PN_FAM]]\\f[\\*[$TOC_PN_FT]]\\s[\\n[#TOC_PS]u]^\\*[ST100X]\\*[ST101]\\s[\\*[$TOC_PN_SIZE_CHANGE]]\\|\\h'\\w'0'u*\\n[#TOC_PN_PADDING]u'\*[ST101X]
-.ds $TOC_PN_TYPEWRITE 
\\*[ST100]^\\*[ST100X]\\*[ST101]\\|\\h'\\w'0'u*\\n[#TOC_PN_PADDING]u'\\*[ST101X]
+.MAC TOC_PT_SIZE END
+.    nr #TOC_PS (p;\\$1)
+.END
 \#
 \# TOC ENTRIES PAGE NUMBERS PADDING
 \# --------------------------------
@@ -15514,7 +14475,6 @@
 .    nr #TOC_PN_PADDING \\$1
 .END
 \#
-\#
 \# PAGINATE TOC
 \# ------------
 \# *Argument:
@@ -15525,32 +14485,10 @@
 \#   Default is to paginate toc.
 \#
 .MAC PAGINATE_TOC END
-.    ie '\\$1'' \{ .nr #PAGINATE_TOC 1 \}
-.    el \{ .nr #PAGINATE_TOC 0 \}
-.END
-\#
-\#
-\# TOC POINT SIZE
-\# --------------
-\# *Argument:
-\#   <base point size for toc pages>
-\# *Function:
-\#   Creates or modifies register #TOC_PS.
-\# *Notes:
-\#   This size control macro differs from other size control macros
-\#   in that it sets an absolute point size, not a relative one.
-\#   See notes for ENDNOTE_PT_SIZE for explanation.  No unit of
-\#   measure required.
-\#
-\#   No unit of measure required (points assumed).  Default is 12.5
-\#   for TYPESET.
-\#
-.MAC TOC_PT_SIZE END
-.    nr #TOC_PS (p;\\$1)
+.    ie '\\$1'' .nr #PAGINATE_TOC 1
+.    el .nr #PAGINATE_TOC 0
 .END
 \#
-\#
-\#
 \# TOC PAGES PAGE-NUMBERING STYLE
 \# ------------------------------
 \# *Argument:
@@ -15567,7 +14505,6 @@
 .    ds $TOC_PN_STYLE \\$1
 .END
 \#
-\#
 \# TOC RECTO_VERSO SWITCH
 \# ----------------------
 \# *Argument:
@@ -15579,50 +14516,56 @@
 \#   the first toc page happens to fall the wrong way
 \#
 .MAC TOC_RV_SWITCH END
-.    ie '\\$1'' \{ .nr #TOC_RV_SWITCH 1 \}
-.    el \{ .rr #TOC_RV_SWITCH \}
+.    ie '\\$1'' .nr #TOC_RV_SWITCH 1
+.    el .rr #TOC_RV_SWITCH
 .END
 \#
-\# - for TOC "doc header" (i.e. "Contents")
-\#
-\# TOC HEADER STRING
+\# TOC ENTRY SPACING
 \# -----------------
-\# *Argument:
-\#   <string for "doc header" of first toc page>
+\# *Arguments:
+\#   <none> | <anything>
 \# *Function:
-\#   Creates or modifies string $TOC_HEADER_STRING
-\# *Notes:
-\#   Default is "Contents".
+\#   Toggles whether a small amount of space is inserted between TOC
+\#   entries for greater legibility.
 \#
-.MAC TOC_HEADER_STRING END
-.    ds $TOC_HEADER_STRING \\$1
+.MAC SPACE_TOC_ITEMS END
+.    ie !'\\$1'' .rr #SPACE_TOC_ITEMS
+.    el .nr #SPACE_TOC_ITEMS 1
 .END
 \#
-\# - for TOC entries page number numerals
-\#
-\# Control macros for toc doc titles, heads, subheads and paraheads
-\# ----------------------------------------------------------------
+\# NUMBERING OF TOC ENTRIES
+\# ------------------------
+\# *Arguments:
+\#   FULL | TRUNCATE | NONE
+\# *Function:
+\#   Determines how, or whether, to prepend heading numbers to TOC
+\#   entries.
+\# *Notes:
+\#   FULL means the complete numbering string (default).
 \#
-\# All these control macros behave the same way, setting the family,
-\# font, point size and indent from the left margin of the different
-\# kinds of entries that can appear in the toc.  The way they
-\# operate is identical to all other _FAMILY, _FONT and _SIZE
-\# control macros.  _INDENT takes an absolute value.
-\# TOC_APPENDS_AUTHORS is unique in this section.
+\#   TRUNCATE means prepend a single digit sufficient to identify
+\#   an entry's place in the numbering scheme with reference to the
+\#   level above it.  Thus, if a HEADING 1 is the second HEADING 1
+\#   and therefore numbered "2.", a HEADING 2 beneath it (in the TOC)
+\#   will have only "1." prepended to the entry; TOC indenting makes it
+\#   evident under which level the HEADING 2 belongs.
 \#
-\# - for title entries
+\#   Note that TRUNCATE also removes chapter numbers, if
+\#   PREFIX_CHAPTER_NUMBER is on.
 \#
-.MAC TOC_TITLE_INDENT END
-.    nr #TOC_TITLE_INDENT (\\$1)
+.MAC TOC_ENTRY_NUMBERS END
+.    if '\\$1'TRUNCATE' .nr #TRUNC_TOC_HD_NUM 1
+.    if '\\$1'FULL'     .nr #TRUNC_TOC_HD_NUM 0
+.    if '\\$1'NONE'     .nr #TOC_NO_HD_NUM 1
 .END
 \#
+\# User defined TITLE entry string
 \#
 .MAC TOC_TITLE_ENTRY END
 .    nr #USER_SET_TITLE_ITEM 1
 .    ds $USER_SET_TITLE_ITEM \\$1
 .END
 \#
-\#
 \# APPEND AUTHOR(S) TO TOC DOC TITLE ENTRIES
 \# -----------------------------------------
 \# *Argument:
@@ -15642,42 +14585,36 @@
 \#
 .MAC TOC_APPENDS_AUTHOR END
 .    nr #TOC_AUTHORS 1
-.    if !'\\$1'' \{\
-.       ds $TOC_AUTHORS \\$1
-.    \}
-.END
-\#
-\# - for head entries
-\#
-.MAC TOC_HEAD_INDENT END
-.    nr #TOC_HEAD_INDENT (\\$1)
-.END
-\#
-\# - for subhead entries
-\#
-.MAC TOC_SUBHEAD_INDENT END
-.    nr #TOC_SH_INDENT (\\$1)
-.END
-\#
-\# - for subsubhead entries
-\#
-.MAC TOC_SUBSUBHEAD_INDENT END
-.    nr #TOC_SSH_INDENT (\\$1)
-.END
-\#
-\# - for parahead entries
-\#
-.MAC TOC_PARAHEAD_INDENT END
-.    nr #TOC_PH_INDENT (\\$1)
+.    if !'\\$1'' .ds $TOC_AUTHORS \\$1
 .END
 \#
+\# TABLE OF CONTENTS
+\# -----------------
+\# *Arguments:
+\#   none
+\# *Function:
+\#   Takes care of the administrivia of setting up the TOC as if
+\#   it's a collated doc, then outputs the formatted TOC_ENTRIES
+\#   diversion.
 \#
 .MAC TOC END
+.    char \[leader] " .
+.    LEADER_CHARACTER \[leader]
+.    ie \\n[#COLLATED_DOC] \{\
+.       nr #TOC_INDENT_ADJ 1.5m
+.       if \\n[#PREFIX_CH_NUM] .nr #TOC_INDENT_ADJ \\n[#TOC_CH_NUM_INDENT]
+.    \}
+.    el \{\
+.       nr #SKIP_ENTRY 1
+.       nr #TOC_INDENT_ADJ 0
+.    \}
+.    nr #TOC 1
+.    nr TOC.RELOCATE 0
 .    if \\n[#LINENUMBERS]=1 \{\
 .       NUMBER_LINES OFF
 .       nr #LINENUMBERS 2
 .    \}
-.    if !r#PAGINATE_TOC \{ .PAGINATE_TOC \}
+.    if !r #PAGINATE_TOC .PAGINATE_TOC
 .    nr #TOC_FIRST_PAGE 1
 .    if \\n[#FINIS] \{\
 .       if \\n[#FOOTERS_WERE_ON] \{\
@@ -15686,26 +14623,22 @@
 .    \}
 .    if \\n[#FOOTERS_ON]=1 \{\
 .       if !'\\*[$HDRFTR_CENTER_OLD]'' .ds $HDRFTR_CENTER 
\\*[$HDRFTR_CENTER_OLD]
-.       ie \\n[#PAGINATE_TOC]=1 \{ .PAGINATE \}
-.       el \{ .PAGINATION OFF \}
+.       ie \\n[#PAGINATE_TOC]=1 .PAGINATE
+.       el .PAGINATION OFF
 .    \}
-.    if \\n[#FOOTERS_WERE_ON] \{ .FOOTERS OFF \} \" But have to turn FOOTERS 
off again so they don't print when FINIS was called
+.    if \\n[#FOOTERS_WERE_ON] .FOOTERS OFF  \" But have to turn FOOTERS off 
again so they don't print when FINIS was called
+.    rr #COLUMNS
 .    COLLATE
 .    if \\n[#PRINT_STYLE]=1 \{\
 .       rr #IGNORE
-.       DOC_LEAD 24 ADJUST
+.       LS 24
 .       nr #IGNORE 1
 .    \}
 .    if \\n[#PRINT_STYLE]=2 \{\
-.       ie r#ADJ_TOC_LEAD \{\
-.          nr #NO_TRAP_RESET 1
-.          DOC_LEAD \\n[#TOC_LEAD]u ADJUST
-.          rr #NO_TRAP_RESET
-.       \}
-.       el \{ .DOC_LEAD \\n[#TOC_LEAD]u \}
+.          LS \\n[#TOC_LEAD]u
 .    \}
 .    if \\n[#FINIS] \{\
-.       if \\n[#FOOTERS_WERE_ON] \{ .FOOTERS \} \" Finally, turn footers on if 
they were on
+.       if \\n[#FOOTERS_WERE_ON] .FOOTERS  \" Finally, turn footers on if they 
were on
 .       rr #FOOTERS_WERE_ON
 .       if \\n[#PAGINATION_WAS_ON] \{\
 .          nr #PAGINATE 1
@@ -15713,91 +14646,56 @@
 .       \}
 .       rr #FINIS
 .    \}
-.    ie \\n[#PAGINATE_TOC]=1 \{ .PAGINATE \}
-.    el \{ .PAGINATION OFF \}
+.    ie \\n[#PAGINATE_TOC]=1 .PAGINATE
+.    el .PAGINATION OFF
 .    if \\n[#FOOTERS_ON]=1 \{\
 .       ds $HDRFTR_CENTER \\*[$HDRFTR_CENTER_NEW]
 .       rm $HDRFTR_CENTER_OLD
 .       rm $HDRFTR_CENTER_NEW
 .    \}
 .    rr #COLLATED_DOC
-.    DOCHEADER OFF
+.    DOCHEADER OFF \\n[#T_MARGIN]u-\\n[#DOC_LEAD]
 .    PAGENUMBER 1
-.    if \\n[#LINENUMBERS]=2 \{ .nr #LINENUMBERS 3 \}
+.    if \\n[#LINENUMBERS]=2 .nr #LINENUMBERS 3
+.    L_MARGIN   \\n[#DOC_L_MARGIN]u
+.    LL         \\n[#DOC_L_LENGTH]u
 .    START
-.    PP
+.    nop
 .    nr #COLUMNS 0
-.    sp |\\n[#T_MARGIN]u-\\n[#DOC_LEAD]u
 .    if \\n[#SLANT_ON] \{\
 \*[SLANTX]\c
 .    \}
 .    DOC_LINE_LENGTH \\n[#DOC_L_LENGTH]u
-.    QUAD \\*[$TOC_HEADER_QUAD]
+.    \\*[$TOC_HEADER_QUAD]
 .    PAGENUM_STYLE \\*[$TOC_PN_STYLE]
-.    if \\n[#PRINT_STYLE]=1 \{\
-.       TYPEWRITER
-.    \}
+.    PDF_BOOKMARK 1 \\*[$TOC_HEADER_STRING]
+.    if \\n[#PRINT_STYLE]=1 .TYPEWRITER
 .    if \\n[#PRINT_STYLE]=2 \{\
 .       FAMILY  \\*[$TOC_HEADER_FAM]
 .       FT      \\*[$TOC_HEADER_FT]
 .       PT_SIZE \\n[#TOC_PS]u\\*[$TOC_HEADER_SIZE_CHANGE]
 .    \}
+.    nr #TOC_PS
 .    ie \\n[#PRINT_STYLE]=1 \{\
 .       CAPS
 .       UNDERLINE
-.       PRINT "\\*[$TOC_HEADER_STRING]"
+.       PRINT \\*[$TOC_HEADER_STRING]
 .       UNDERLINE OFF
 .       CAPS      OFF
 .    \}
-.    el \{\
-.       PRINT "\\*[$TOC_HEADER_STRING]"
-.    \}
-.    LEFT
-.    SP
-.\" In collated docs, this bit inserts the first doc's title
-.\" underneath the TOC header, before the TOC_ENTRIES diversion
-.\" gets output.
-.    nf
-.    if d$FIRST_DOC_TITLE \{\
-.    nr #RESTORE_TOC_PN_PADDING \\n[#TOC_PN_PADDING]
-.    TOC_PADDING \\n[#FIRST_DOC_TOC_PN_PADDING]
-.       if \\n[#PRINT_STYLE]=2 \{\
-.          FAMILY  \\*[$TOC_TITLE_FAM]
-.          FT      \\*[$TOC_TITLE_FT]
-.          PT_SIZE \\n[#TOC_PS]u\\*[$TOC_TITLE_SIZE_CHANGE]
-.       \}
-.       PAD_MARKER ^
-.       ie \\n[#PRINT_STYLE]=1 \{\
-.          PAD "\\*[$FIRST_DOC_TITLE]\\*[$TOC_PN_TYPEWRITE]"
-.       \}
-.       el \{\
-.          PAD "\\h'\\n[#TOC_TITLE_INDENT]u'\\*[$FIRST_DOC_TITLE]\\*[$TOC_PN]"
-.       \}
-.       PAD_MARKER #
-.       EOL
-.       ST 100 L
-.       ST 101 R
-.       if \\n[#PRINT_STYLE]=2 \{\
-.          FAMILY  \\*[$TOC_PN_FAM]
-.          FT      \\*[$TOC_PN_FT]
-.          PT_SIZE \\n[#TOC_PS]u\\*[$TOC_PN_SIZE_CHANGE]
-.       \}
-.       TAB 100
-.       PRINT \\*[LEADER]
-.       TN
-.       PRINT \\n[#FIRST_DOC_TITLE_PN]
-.       TQ
+.    el .PRINT \\*[$TOC_HEADER_STRING]
+.    if !\\n[#PRINT_STYLE]=1 \{\
+.       sp
 .    \}
-.    TOC_PADDING \\n[#RESTORE_TOC_PN_PADDING]
 .    nf
 .    TOC_ENTRIES
-.    br
 .    rr #TOC
 .    if \\n[#LINENUMBERS]=3 \{\
 .       NUMBER_LINES RESUME
 .       nr #LINENUMBERS 1
 .       nn 1
 .    \}
+.    pdfsync
 .END
 \#
 \# ====================================================================
@@ -15815,7 +14713,7 @@
 \#   COLUMNS, if used, s/b the last macro invoked before START.
 \#
 .MAC COLUMNS END
-.    if \\n[#IGNORE_COLUMNS]=1 \{ .return \}
+.    if \\n[#IGNORE_COLUMNS]=1 .return
 .    nr #COLUMNS 1
 .    nr #NUM_COLS \\$1
 .    nr #GUTTER (\\$2)
@@ -15825,15 +14723,14 @@
 .    while !\\n[#COL_NUM]=\\n[#NUM_COLS] \{\
 .       nr #COL_\\n+[#COL_NUM]_L_MARGIN \\n[#L_MARGIN]+\\n[#COL_TOTAL]
 .       nr #COL_TOTAL \\n+[#COL_TOTAL]
-.\}
+.    \}
 .    if \\n[#NUM_COLS]=1 \{\
-.       if !\\n[#COLLATE]=1 \{ .MN_INIT \}
+.       if !\\n[#COLLATE]=1 .MN_INIT
 .    \}
 .    rr #COL_TOTAL
 .    rr #COL_NUM
 .END
 \#
-\#
 \# NEXT COLUMN
 \# -----------
 \# *Arguments:
@@ -15846,15 +14743,13 @@
 .MAC COL_NEXT END
 .    if \\n[#COLUMNS] \{\
 .       nr #COL_NEXT 1
-.       ie '\\$0'COL_NEXT' \{ .br  \}
+.       ie '\\$0'COL_NEXT' .br
 .       el \{\
 .          brp
 .          RLD 1v
 .       \}
-.       ie \\n[#COL_NUM]=\\n[#NUM_COLS] \{\
-.          bp
-.       \}
-.       el \{ .FOOTER \}
+.       ie \\n[#COL_NUM]=\\n[#NUM_COLS] .bp
+.       el .FOOTER
 .    \}
 .END
 \#
@@ -15865,7 +14760,8 @@
 \# LIST
 \# ----
 \# *Arguments:
-\#   [ BULLET | DASH | DIGIT | alpha | ALPHA | roman | ROMAN | USER ] [ 
<separator> | NONE ] [ <prefix> ] [ <anything> ]
+\#   [ BULLET | DASH | DIGIT | alpha | ALPHA | roman | ROMAN | USER ] \
+\#   [ <separator> | NONE ] [ <prefix> ] [ <anything> ]
 \# *Function:
 \#   Stores indent information in effect prior to invocation and
 \#   initializes a list with the supplied enumerator (and separator).
@@ -15895,16 +14791,16 @@
 .             LIST OFF
 .             return
 .          \}
-.          tm1 "[mom]: You must append a number to the \\$1 argument to LIST 
at line \\n(.c.
+.          tm1 "[mom]: You must append a number to the \\$1 argument to LIST 
at line \\n[.c].
 .          tm1 "       The number should be the total number of items in this 
list.
 .          tm1 "       See the documentation.
-.          ab Aborting LIST
+.          ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
 .       \}
 .       ds $ROMAN_WIDTH \\$1
 .          substring $ROMAN_WIDTH 1
 .       while !\B'\\*[$ROMAN_WIDTH]' \{\
 .          substring $ROMAN_WIDTH 1
-.\}
+.       \}
 .       length #ROMAN_LENGTH \\*[$ROMAN_WIDTH]
 .       ds $LIST_ARG_1 \\$1
 .       substring $LIST_ARG_1 0 -(\\n[#ROMAN_LENGTH]+1)
@@ -15915,7 +14811,7 @@
 .    if !r#DEPTH \{\
 .       nr #STORED_HL_INDENT \\n[#HL_INDENT]
 .       nr #STORED_T_INDENT  \\n[#T_INDENT]
-.       nr #CURRENT_L_LENGTH \\n(.l
+.       nr #CURRENT_L_LENGTH \\n[.l]
 .       nr #DEPTH 0 1
 .       if \\n[#INDENT_ACTIVE]=1 \{\
 .          if \\n[#INDENT_LEFT_ACTIVE]=1 \{\
@@ -15926,23 +14822,23 @@
 .             nr #STORED_BL_INDENT \\n[#BL_INDENT]
 .             nr #STORED_BR_INDENT \\n[#BR_INDENT]
 .             IBX
-.             nr #ORIG_L_LENGTH \\n(.l
+.             nr #ORIG_L_LENGTH \\n[.l]
 .             IB
 .             nr #RESTORE_PREV_INDENT 2
 .          \}
 .          if \\n[#INDENT_RIGHT_ACTIVE]=1 \{\
 .             nr #STORED_R_INDENT \\n[#R_INDENT]
 .             IRX
-.             nr #ORIG_L_LENGTH \\n(.l
+.             nr #ORIG_L_LENGTH \\n[.l]
 .             IR
 .             nr #RESTORE_PREV_INDENT 3
-.             if \\n[#INDENT_LEFT_ACTIVE]=1 \{ .nr #RESTORE_PREV_INDENT 4 \}
+.             if \\n[#INDENT_LEFT_ACTIVE]=1 .nr #RESTORE_PREV_INDENT 4
 .          \}
 .       \}
 .    \}
 .    if \\n[#NUM_ARGS]=0 \{\
 .       nr #ARGS_TO_LIST 1 \" So default behaves as if LIST BULLET
-.       ds $ENUMERATOR\\n+[#DEPTH] \(bu
+.       ds $ENUMERATOR\\n+[#DEPTH] \[bu]
 .       ds $ENUMERATOR_TYPE\\n[#DEPTH] other
 .       ds $SEPARATOR
 .    \}
@@ -15950,13 +14846,13 @@
 .       rr #ARGS_TO_LIST \" Clear this before processing arg 1.
 .       if '\\*[$LIST_ARG_1]'DASH'   \{\
 .          nr #ARGS_TO_LIST 1
-.          ds $ENUMERATOR\\n+[#DEPTH] \(en
+.          ds $ENUMERATOR\\n+[#DEPTH] \[en]
 .          ds $ENUMERATOR_TYPE\\n[#DEPTH] other
 .          ds $SEPARATOR\\n[#DEPTH]
 .       \}
 .       if '\\*[$LIST_ARG_1]'BULLET' \{\
 .          nr #ARGS_TO_LIST 1
-.          ds $ENUMERATOR\\n+[#DEPTH] \(bu
+.          ds $ENUMERATOR\\n+[#DEPTH] \[bu]
 .          ds $ENUMERATOR_TYPE\\n[#DEPTH] other
 .          ds $SEPARATOR\\n[#DEPTH]
 .       \}
@@ -15969,9 +14865,7 @@
 .          if \\n[#NUM_ARGS]>=2 \{\
 .             ie '\\$2'NONE' .ds $SEPARATOR\\n[#DEPTH]
 .             el             .ds $SEPARATOR\\n[#DEPTH] \\$2
-.             if \\n[#NUM_ARGS]=3 \{\
-.                ds $PREFIX\\n[#DEPTH] \\$3
-.             \}
+.             if \\n[#NUM_ARGS]=3 .ds $PREFIX\\n[#DEPTH] \\$3
 .          \}
 .       \}
 .       if '\\*[$LIST_ARG_1]'alpha'  \{\
@@ -15984,9 +14878,7 @@
 .          if \\n[#NUM_ARGS]>=2 \{\
 .             ie '\\$2'NONE' .ds $SEPARATOR\\n[#DEPTH]
 .             el             .ds $SEPARATOR\\n[#DEPTH] \\$2
-.             if \\n[#NUM_ARGS]=3 \{\
-.                ds $PREFIX\\n[#DEPTH] \\$3
-.             \}
+.             if \\n[#NUM_ARGS]=3 .ds $PREFIX\\n[#DEPTH] \\$3
 .          \}
 .       \}
 .       if '\\*[$LIST_ARG_1]'ALPHA'  \{\
@@ -16007,21 +14899,15 @@
 .       if '\\*[$1ST_LETTER]'R'  \{\
 .          nr #ARGS_TO_LIST 1
 .          nr #ENUMERATOR\\n+[#DEPTH] 0 1
-.          if '\\*[$LIST_ARG_1]'roman' \{\
-.             af #ENUMERATOR\\n[#DEPTH] i
-.          \}
-.          if '\\*[$LIST_ARG_1]'ROMAN' \{\
-.             af #ENUMERATOR\\n[#DEPTH] I
-.          \}
+.          if '\\*[$LIST_ARG_1]'roman' .af #ENUMERATOR\\n[#DEPTH] i
+.          if '\\*[$LIST_ARG_1]'ROMAN' .af #ENUMERATOR\\n[#DEPTH] I
 .          ds $ENUMERATOR_TYPE\\n[#DEPTH] roman
 .          ds $SEPARATOR\\n[#DEPTH] )
 .          ds $PREFIX\\n[#DEPTH]
 .          if \\n[#NUM_ARGS]>=2 \{\
 .             ie '\\$2'NONE' .ds $SEPARATOR\\n[#DEPTH]
 .             el             .ds $SEPARATOR\\n[#DEPTH] \\$2
-.             if \\n[#NUM_ARGS]=3 \{\
-.                ds $PREFIX\\n[#DEPTH] \\$3
-.             \}
+.             if \\n[#NUM_ARGS]=3 .ds $PREFIX\\n[#DEPTH] \\$3
 .          \}
 .       \}
 .       if '\\*[$LIST_ARG_1]'USER'   \{\
@@ -16056,14 +14942,13 @@
 .    \}
 .    nr #TOTAL_LISTS \\n[#DEPTH]
 .    if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'register' \{\
-.       nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]m\\*[$SEPARATOR\\n[#DEPTH]]\ '
-.       if '\\*[$LIST_ARG_1]'ALPHA'\{\
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]M\\*[$SEPARATOR\\n[#DEPTH]]\ '
-.       \}
+.       nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]m\\*[$SEPARATOR\\n[#DEPTH]]\ '
+.       if '\\*[$LIST_ARG_1]'ALPHA' nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]M\\*[$SEPARATOR\\n[#DEPTH]]\ '
 .    \}
-.    if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'roman' \{\
+.    if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'roman' \
 .       GET_ROMAN_INDENT
-.    \}
 .    if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'other' \{\
 .       nr #LIST_INDENT\\n[#DEPTH] \w'\\*[$ENUMERATOR\\n[#DEPTH]]\0'
 .    \}
@@ -16101,7 +14986,6 @@
 .    \}
 .END
 \#
-\#
 \# ITEM
 \# ----
 \# *Arguments:
@@ -16111,7 +14995,7 @@
 \#   receive the text of an item.
 \#
 .MAC ITEM END
-.    if !r#DEPTH \{ .return \}
+.    if !r#DEPTH .return
 .    if \\n[#LINENUMBERS]=1 \{\
 .       NUMBER_LINES OFF
 .       nr #LINENUMBERS 2
@@ -16126,25 +15010,24 @@
 .    ll \\n[#CURRENT_L_LENGTH]u \" Set ll again because IL turns IB off.
 .    TRAP OFF
 .    HI \\n[#HL_INDENT\\n[#DEPTH]]u
-.    if '\\*[$SEPARATOR\\n[#DEPTH]]')' \{ .nr #SEP_TYPE 1 \}
-.    if '\\*[$SEPARATOR\\n[#DEPTH]]']' \{ .nr #SEP_TYPE 1 \}
-.    if '\\*[$SEPARATOR\\n[#DEPTH]]'}' \{ .nr #SEP_TYPE 1 \}
+.    if '\\*[$SEPARATOR\\n[#DEPTH]]')' .nr #SEP_TYPE 1
+.    if '\\*[$SEPARATOR\\n[#DEPTH]]']' .nr #SEP_TYPE 1
+.    if '\\*[$SEPARATOR\\n[#DEPTH]]'}' .nr #SEP_TYPE 1
 .    ie \\n[#IN_BIB_LIST]=1 \{\
 .       ie \\n[#ENUMERATOR\\n[#DEPTH]]<9 \{\
-.          ie \\n[#SEP_TYPE]=1 \{\
-.             PRINT 
\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
-.          \}
-.          el \{\
-.             PRINT 
\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.          \}
+.          ie \\n[#SEP_TYPE]=1 .PRINT \
+\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\
+\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
+.          el .PRINT \
+\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .       \}
 .       el \{\
-.          ie \\n[#SEP_TYPE]=1 \{\
-.             PRINT 
\h'-\w'\0'u'\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
-.          \}
-.          el \{\
-.             PRINT 
\h'-\w'\0'u'\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.          \}
+.          ie \\n[#SEP_TYPE]=1 .PRINT \
+\h'-\w'\0'u'\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\
+\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
+.          el .PRINT \
+\h'-\w'\0'u'\
+\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .       \}
 .    \}
 .    el \{\
@@ -16153,84 +15036,81 @@
 .          ie '\\g[#ENUMERATOR\\n[#DEPTH]]'0' \{\
 .             ie \\n[#PAD_LIST_DIGITS\\n[#DEPTH]]=1 \{\
 .                ie \\n[#ENUMERATOR\\n[#DEPTH]]<9 \{\
-.                   ie \\n[#SEP_TYPE]=1 \{\
-.                      PRINT 
\0\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
-.                   \}
-.                   el \{\
-.                      PRINT 
\0\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.                   \}
-.                \}
-.                el \{\
-.                   ie \\n[#SEP_TYPE]=1 \{\
-.                      PRINT 
\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
-.                   \}
-.                   el \{\
-.                      PRINT 
\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.                   \}
-.                \}
+.                   ie \\n[#SEP_TYPE]=1 .PRINT \
+\0\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\
+\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
+.                   el .PRINT \
+\0\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
+.                \}
+.                el \{\
+.                   ie \\n[#SEP_TYPE]=1 .PRINT \
+\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\
+\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
+.                   el .PRINT \
+\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .             \}
-.             el \{\
-.                ie \\n[#SEP_TYPE]=1 \{\
-.                   PRINT 
\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
 .                \}
 .                el \{\
-.                   PRINT 
\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.                \}
+.                ie \\n[#SEP_TYPE]=1 .PRINT \
+\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\
+\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
+.                el .PRINT \
+\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .             \}
 .          \}
 .          el \{\
 .\" ALPHA
 .             ie '\\g[#ENUMERATOR\\n[#DEPTH]]'A' \{\
-.                ie \\n[#SEP_TYPE]=1 \{\
-.                   PRINT 
\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
-.                \}
-.                el \{\
-.                   PRINT 
\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.                \}
+.                ie \\n[#SEP_TYPE]=1 .PRINT \
+\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\
+\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
+.                el .PRINT \
+\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .             \}
 .\" alpha
-.             el \{\
-.                PRINT 
\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.             \}
+.             el .PRINT \
+\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .          \}
 .       \}
 .       if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'roman' \{\
 .          ie \\n[#PAD_LIST_DIGITS\\n[#DEPTH]]=1 \{\
 .\" ROMAN I, padded
 .             ie '\\g[#ENUMERATOR\\n[#DEPTH]]'I' \{\
-.                ie \\n[#SEP_TYPE]=1 \{\
-.                   PRINT 
"\h'\\n[#HL_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]\0'u'\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
-.                \}
-.                el \{\
-.                   PRINT 
"\h'\\n[#HL_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]\0'u'\\*[$PREFIX\\n[#DEPTH]]\\n[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.                \}
+.                ie \\n[#SEP_TYPE]=1 .PRINT \
+\h'\\n[#HL_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\
+\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]\0'u'\
+\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n[#ENUMERATOR\\n[#DEPTH]]\
+\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
+.                el .PRINT \
+\h'\\n[#HL_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\
+\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]\
+\0'u'\\*[$PREFIX\\n[#DEPTH]]\\n[#ENUMERATOR\\n[#DEPTH]]\
+\\*[$SEPARATOR\\n[#DEPTH]]
 .             \}
 .\" roman i, padded
-.             el \{\
-.                PRINT 
"\h'\\n[#HL_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]\0'u'\\*[$PREFIX\\n[#DEPTH]]\\n[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.             \}
+.             el .PRINT \
+\h'\\n[#HL_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\
+\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]\0'u'\
+\\*[$PREFIX\\n[#DEPTH]]\\n[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .          \}
 .\" No pad
 .          el \{\
 .\" ROMAN I, no pad
 .             ie '\\g[#ENUMERATOR\\n[#DEPTH]]'I' \{\
-.                ie \\n[#SEP_TYPE]=1 \{\
-.                   PRINT 
\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
-.                \}
-.                el \{\
-.                   PRINT 
\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
-.                \}
+.                ie \\n[#SEP_TYPE]=1 .PRINT \
+\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n+[#ENUMERATOR\\n[#DEPTH]]\
+\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m'
+.                el .PRINT \
+\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .             \}
 .\" roman i, no pad
-.             el \{\
-.                PRINT 
\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
+.             el .PRINT \
+\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .             \}
 .          \}
-.       \}
-.       if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'other' \{\
+.       if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'other' \
 .          PRINT \\*[$ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]]
 .       \}
-.    \}
 .    rr #SEP_TYPE
 .    EOL
 .    if \\n[#REF]=1 \{\
@@ -16257,165 +15137,205 @@
 .    if '\\*[$LIST_ARG_1]'roman' \{\
 .       if '\\*[$ROMAN_WIDTH]'1'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 1
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]i\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]i\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'2'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 2
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]ii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]ii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'3'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 3
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]iii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]iii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'4'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 4
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]iii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]iii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'5'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 5
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]iii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]iii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'6'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 6
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]iii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]iii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'7'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 7
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]vii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]vii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'8'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 8
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'9'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 9
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'10'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 10
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'11'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 11
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'12'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 12
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]viii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'13'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 13
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]xiii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]xiii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'14'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 14
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]xiii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]xiii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'15'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 15
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]xiii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]xiii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'16'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 16
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]xiii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]xiii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'17'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 17
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]xvii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]xvii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'18'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 18
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]xviii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]xviii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'19'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 19
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]xviii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]xviii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'20'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 20
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]xviii\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]xviii\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .    \}
 .    if '\\*[$LIST_ARG_1]'ROMAN' \{\
 .       if '\\*[$ROMAN_WIDTH]'1'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 1
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]I\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]I\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'2'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 2
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]II\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]II\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'3'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 3
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]III\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]III\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'4'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 4
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]IV\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]IV\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'5'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 5
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]IV\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]IV\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'6'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 6
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]IV\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]IV\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'7'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 7
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]VII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]VII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'8'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 8
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'9'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 9
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'10'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 10
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'11'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 11
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'12'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 12
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]VIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'13'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 13
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]XIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]XIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'14'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 14
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]XIV\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]XIV\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'15'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 15
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]XIV\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]XIV\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'16'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 16
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]XIV\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]XIV\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'17'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 17
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]XVII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]XVII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'18'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 18
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]XVIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]XVIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'19'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 19
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]XVIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]XVIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .       if '\\*[$ROMAN_WIDTH]'20'  \{\
 .          ds $ROMAN_WIDTH\\n[#DEPTH] 20
-.          nr #LIST_INDENT\\n[#DEPTH] 
\w'\\*[$PREFIX\\n[#DEPTH]]XVIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
+.          nr #LIST_INDENT\\n[#DEPTH] \
+\w'\\*[$PREFIX\\n[#DEPTH]]XVIII\\*[$SEPARATOR\\n[#DEPTH]]\0'
 .       \}
 .    \}
 .END
@@ -16434,7 +15354,6 @@
 .       nr #L_INDENT +\\n[#SHIFT_LIST\\n[#DEPTH]]
 .END
 \#
-\#
 \# PAD LIST DIGITS
 \# ---------------
 \# *Arguments:
@@ -16448,17 +15367,16 @@
 .       nr #LIST_INDENT\\n[#DEPTH] +\\w'\\0'
 .       nr #L_INDENT \\n[#LIST_INDENT\\n[#DEPTH]]+\\n[#LIST_INDENT\\n-[#DEPTH]]
 .       nr #HL_INDENT\\n+[#DEPTH] +\\w'\\n[#ENUMERATOR\\n[#DEPTH]]'
-.       if '\\$1'LEFT' \{ .nr #PAD_LIST_DIGITS\\n[#DEPTH] 1 \}
+.       if '\\$1'LEFT' .nr #PAD_LIST_DIGITS\\n[#DEPTH] 1
 .    \}
 .    if '\\g[#ENUMERATOR\\n[#DEPTH]]'i' \{\
-.       if '\\$1'LEFT' \{ .nr #PAD_LIST_DIGITS\\n[#DEPTH] 1 \}
+.       if '\\$1'LEFT' .nr #PAD_LIST_DIGITS\\n[#DEPTH] 1
 .    \}
 .    if '\\g[#ENUMERATOR\\n[#DEPTH]]'I' \{\
-.       if '\\$1'LEFT' \{ .nr #PAD_LIST_DIGITS\\n[#DEPTH] 1 \}
+.       if '\\$1'LEFT' .nr #PAD_LIST_DIGITS\\n[#DEPTH] 1
 .    \}
 .END
 \#
-\#
 \# RESET LIST
 \# ----------
 \# *Arguments:
@@ -16467,11 +15385,10 @@
 \#   Resets register enumerators to 1 or a.
 \#
 .MAC RESET_LIST END
-.    ie '\\$1'' \{ .nr #ENUMERATOR\\n[#DEPTH] 0 1 \}
-.    el \{ .nr #ENUMERATOR\\n[#DEPTH] \\$1-1 1 \}
+.    ie '\\$1'' .nr #ENUMERATOR\\n[#DEPTH] 0 1
+.    el .nr #ENUMERATOR\\n[#DEPTH] \\$1-1 1
 .END
 \#
-\#
 \# QUIT LISTS
 \# ----------
 \# *Arguments:
@@ -16522,7 +15439,7 @@
 .      rm $SEPARATOR\\n[#REMOVE]
 .      rm $ENUMERATOR_TYPE\\n[#REMOVE]
 .      rr #PAD_LIST_DIGITS\\n[#REMOVE]
-.\}
+.   \}
 .   rr #REMOVE
 .   rr #TOTAL_LISTS
 .   rr #QUIT
@@ -16535,7 +15452,6 @@
 .   rr #IN_ITEM_L_INDENT
 .END
 \#
-\#
 \# SET LIST INDENT
 \# ---------------
 \# *Arguments:
@@ -16569,63 +15485,30 @@
 \# *Notes:
 \#   COLLATE exists primarily to allow putting multiple chapters in
 \#   a single file, although it can be used for any document type.  After
-\#   COLLATE, any of the macros that normally precede START may be
-\#   used, and should behave as expected.
-\#
-\#   N.B.--the START macro *must* be used after COLLATE (and any other
-\#   macros that alter mom's behaviour).
-\#
-.MAC COLLATE END
-.    if ( (\\n[.t]-1) <= \\n[.v] ) \{ .nr #NO_BREAK 1 \}
-.    ds $SAVED_PP_FT \\*[$PP_FT]
-.    nr #COLLATE 1
-.    nr #PRE_COLLATE 1
-.    nr #HEADER_STATE \\n[#HEADERS_ON]
-.    HEADERS OFF
-.    if \\n[#DOC_HEADER]=2 \{ .nr #DOC_HEADER 1 \}
-.    if \\n[#PAGE_NUM_V_POS]=1 \{\
-.       nr #PAGINATION_STATE \\n[#PAGINATE]
-.       PAGINATION OFF
-.    \}
-.    IQ CLEAR
-.    TQ
-.\" Collect first doc's title for TOC
-.    if \\n[#COLLATED_DOC]=0 \{\
-.       ie \\n[#USER_SET_TITLE_ITEM] \{\
-.          ds $FIRST_DOC_TITLE \\*[$USER_SET_TITLE_ITEM]\\|
-.          rr #USER_SET_TITLE_ITEM
-.          rm $USER_SET_TITLE_ITEM
-.       \}
-.       el \{\
-.          ie \\n[#DOC_TYPE]=2 \{\
-.             ie '\\*[$CHAPTER_TITLE]'' \{\
-.                ds $FIRST_DOC_TITLE \\*[$CHAPTER_STRING] \\*[$CHAPTER]\\|
-.             \}
-.             el \{\
-.                ie '\\*[$CHAPTER]'' \{\
-.                   ds $FIRST_DOC_TITLE \\*[$CHAPTER_TITLE]\\|
-.                \}
-.                el \{\
-.                   ds $FIRST_DOC_TITLE \\*[$CHAPTER_STRING] \\*[$CHAPTER]: 
\\*[$CHAPTER_TITLE]\\|
-.                \}
-.             \}
-.          \}
-.          el \{\
-.             ds $FIRST_DOC_TITLE \\*[$TITLE]\\|
-.          \}
-.       \}
-.       if \\n[#TOC_AUTHORS]=1 \{\
-.          ie '\\*[$TOC_AUTHORS]'' \{\
-.             as $FIRST_DOC_TITLE /\\|\\*[$AUTHOR_1]\\|
-.          \}
-.          el \{\
-.             as $FIRST_DOC_TITLE /\\|\\*[$TOC_AUTHORS]\\|
-.             rm $TOC_AUTHORS
-.          \}
-.       \}
+\#   COLLATE, any of the macros that normally precede START may be
+\#   used, and should behave as expected.
+\#
+\#   N.B.--the START macro must be used after every COLLATE
+\#
+.MAC COLLATE END
 .       nr #COLLATED_DOC 1
+.    if ( (\\n[.t]-1) <= \\n[.v] ) .nr #NO_BREAK 1
+.    ds $SAVED_PP_FT \\*[$PP_FT]
+.    nr #COLLATE 1
+.    nr #PRE_COLLATE 1
+.    nr #HEADER_STATE \\n[#HEADERS_ON]
+.    nr #POST_TOP 1
+.    nr #ARG_NUM 0 1
+.    nr #LOOP \\n[#ACTIVE_LEVELS]      \" loop count                           
        
+.    nr #HEAD_1_NUM 0 1
+.    HEADERS OFF
+.    if \\n[#DOC_HEADER]=2 .nr #DOC_HEADER 1
+.    if \\n[#PAGE_NUM_V_POS]=1 \{\
+.       nr #PAGINATION_STATE \\n[#PAGINATE]
+.       PAGINATION OFF
 .    \}
-.\" End title collection for TOC
+.    IQ CLEAR
+.    TQ
 .    LL \\n[#DOC_L_LENGTH]u
 .    QUAD $DOC_QUAD
 .    nr #SAVED_DOC_LEAD \\n[#DOC_LEAD]
@@ -16633,13 +15516,17 @@
 \*[SLANTX]
 \*[CONDX]
 \*[EXTX]
+.    if \\n[#TOC] \{\
+.       if \\n[TOC_BH]=1 .pdfswitchtopage before MOM:TOC
+.       if \\n[TOC_BH]=2 .pdfswitchtopage after MOM:TOC
+.    \}
 '    NEWPAGE
-.    if \\n[#DEFER_PAGINATION] \{ .PAGINATE \}
+.    if \\n[#DEFER_PAGINATION] .PAGINATE
 .    if !'\\*[$RESTORE_PAGENUM_STYLE]'' \{\
 .       PAGENUM_STYLE \\*[$RESTORE_PAGENUM_STYLE]
 .       rm $RESTORE_PAGENUM_STYLE
 .    \}
-.    if \\n[#CH_NUM] \{ .nr #CH_NUM +1 \}
+.    if \\n[#CH_NUM] .nr #CH_NUM +1
 .    rm $EN_TITLE
 .    COVERTITLE
 .    DOCCOVERTITLE
@@ -16651,9 +15538,10 @@
 .    rr #PAGENUM_STYLE_SET
 .    rr #DOC_COVER
 .    rr #COVER
+.    rr #LAST_LEVEL
+.    rr #LEVEL
 .END
 \#
-\#
 \# NUMBER_LINES
 \# ------------
 \# *Arguments:
@@ -16665,18 +15553,18 @@
 \#
 .MAC NUMBER_LINES END
 .    br
-.    if '\\n(.z'EPI_TEXT' \{ .return \}
+.    if '\\n[.z]'EPI_TEXT' .return
 .    if '\\$1'' \{\
-.       tm1 "[mom]: NUMBER_LINES at line \\n(.c has no argument.
+.       tm1 "[mom]: NUMBER_LINES at line \\n[.c] has no argument.
 .       tm1 "       Most likely, you have forgotten to give it a starting line 
number.
-.       ab Aborting on NUMBER_LINES.
+.       ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
 .    \}
-.    if !\\n[#LINENUMBERS]=2 \{ .nr #LINENUMBERS 1 \}
+.    if !\\n[#LINENUMBERS]=2 .nr #LINENUMBERS 1
 .\" Test whether the first arg is a digit.
 .    if \B'\\$1' \{\
 .       nr #LN \\$1
 .       ds $LN_NUM \\$1
-.       if !'\\n(.z'' \{ .nr #RESTORE_LN_NUM 1 \}
+.       if !'\\n[.z]'' .nr #RESTORE_LN_NUM 1
 .       ie '\\$2'' \{\
 .          if '\\*[$LN_INC]'' .ds $LN_INC 1
 .       \}
@@ -16704,7 +15592,7 @@
 .          ft
 .          ps
 .          gcolor
-.          if !\\n[#LINENUMBERS]=2 \{ .rr #LINENUMBERS \}
+.          if !\\n[#LINENUMBERS]=2 .rr #LINENUMBERS
 .       \}
 .    \}
 .    el \{\
@@ -16714,12 +15602,11 @@
 .       ft
 .       ps
 .       gcolor
-.       if !'\\n(.z'' \{ .nr #DIVER_LN_OFF 1 \}
+.       if !'\\n[.z]'' .nr #DIVER_LN_OFF 1
 .    \}
 .    rr #LN
 .END
 \#
-\#
 \# LINENUMBER STYLE PARAMETERS
 \# ---------------------------
 \# *Arguments:
@@ -16733,17 +15620,16 @@
 \#   to their former values, stay at those values.)
 \#
 .MAC LN_PARAMS END
-.    ie d$LN_FAM          \{ .fam \\*[$LN_FAM] \}
-.    el                   \{ .fam \\n[.fam]    \}
-.    ie d$LN_FT           \{ .ft \\*[$LN_FT]   \}
-.    el                   \{ .ft \\n[.sty]     \}
-.    ie d$LN_SIZE_CHANGE  \{ .ps \\*[$LN_SIZE_CHANGE] \}
-.    el                   \{ .ps \\n[.s] \}
-.    ie d$LN_COLOR        \{ .gcolor \\*[$LN_COLOR] \}
-.    el                   \{ .gcolor \\n[.m] \}
+.    ie d$LN_FAM .fam \\*[$LN_FAM]
+.    el .fam \\n[.fam]
+.    ie d$LN_FT .ft \\*[$LN_FT]
+.    el .ft \\n[.sty]
+.    ie d$LN_SIZE_CHANGE .ps \\*[$LN_SIZE_CHANGE]
+.    el .ps \\n[.s]
+.    ie d$LN_COLOR .gcolor \\*[$LN_COLOR]
+.    el .gcolor \\n[.m]
 .END
 \#
-\#
 \# NUMBER QUOTE AND BLOCKQUOTE LINES AS PART OF RUNNING TEXT
 \# ---------------------------------------------------------
 \# *Argument:
@@ -16758,14 +15644,14 @@
 \#   the one used for line numbers in running text.
 \#
 .MAC NUMBER_QUOTE_LINES END
-.    ie \\n[#NUM_ARGS]=0 \{ .nr #QUOTE_LN 1 \}
+.    ie \\n[#NUM_ARGS]=0 .nr #QUOTE_LN 1
 .    el \{\
 .       ie \B'\\$1' \{\
 .          nr #QUOTE_LN 1
 .          ds $Q_LN_GUTTER \\$1
 .       \}
 .       el \{\
-.          ie '\\$1'SILENT' \{ .nr #SILENT_QUOTE_LN 1 \}
+.          ie '\\$1'SILENT' .nr #SILENT_QUOTE_LN 1
 .          el \{\
 .             rr #QUOTE_LN
 .             rr #SILENT_QUOTE_LN
@@ -16774,16 +15660,15 @@
 .    \}
 .END
 \#
-\#
 .MAC NUMBER_BLOCKQUOTE_LINES END
-.    ie \\n[#NUM_ARGS]=0 \{ .nr #BQUOTE_LN 1 \}
+.    ie \\n[#NUM_ARGS]=0 .nr #BQUOTE_LN 1
 .    el \{\
 .       ie \B'\\$1' \{\
 .          nr #BQUOTE_LN 1
 .          ds $BQ_LN_GUTTER \\$1
 .       \}
 .       el \{\
-.          ie '\\$1'SILENT' \{ .nr #SILENT_BQUOTE_LN 1 \}
+.          ie '\\$1'SILENT' .nr #SILENT_BQUOTE_LN 1
 .          el \{\
 .             rr #BQUOTE_LN
 .             rr #SILENT_BQUOTE_LN
@@ -16818,7 +15703,7 @@
 .          HEADERS OFF
 .       \}
 .       if \\n[#PAGE_NUM_V_POS]=1 \{\
-.          if \\n[#PAGINATE]=1 \{ .nr #PAGINATE_WAS_ON 1 \}
+.          if \\n[#PAGINATE]=1 .nr #PAGINATE_WAS_ON 1
 .          PAGINATION OFF
 .       \}
 .       NEWPAGE
@@ -16828,51 +15713,157 @@
 .          FOOTERS OFF
 .       \}
 .       if \\n[#PAGE_NUM_V_POS]=2 \{\
-.          if \\n[#PAGINATE]=1 \{ .nr #PAGINATE_WAS_ON 1 \}
+.          if \\n[#PAGINATE]=1 .nr #PAGINATE_WAS_ON 1
 .          PAGINATION OFF
 .       \}
-.       if \\n[#HEADERS_WERE_ON] \{ .HEADERS \}
+.       if \\n[#HEADERS_WERE_ON] .HEADERS
 .       if \\n[#PAGE_NUM_V_POS]=1 \{\
-.          if \\n[#PAGINATE_WAS_ON] \{ .PAGINATE \}
+.          if \\n[#PAGINATE_WAS_ON] .PAGINATE
+.       \}
 .       \}
-.\}
 .    shift
 .    ie '\\$1'DIVIDER' \{\
-.       if \\n[#FOOTERS_WERE_ON] \{ .FOOTERS \}
+.       if \\n[#FOOTERS_WERE_ON] .FOOTERS
 .       if \\n[#PAGE_NUM_V_POS]=2 \{\
 .          if \\n[#PAGINATE_WAS_ON] \{\
 .             nr #RESTORE_PAGINATION 1
 .          \}
 .       \}
 .       shift
-.       if '\\$1'NULL' \{ .nr #PAGE_NUM_ADJ -\\n[#HOW_MANY] \}
+.       if '\\$1'NULL' .nr #PAGE_NUM_ADJ -\\n[#HOW_MANY]
 .    \}
 .    el \{\
 .       if '\\$1'' \{\
 .          NEWPAGE
-.          if \\n[#FOOTERS_WERE_ON] \{ .FOOTERS \}
+.          if \\n[#FOOTERS_WERE_ON] .FOOTERS
 .          if \\n[#PAGE_NUM_V_POS]=2 \{\
-.             if \\n[#PAGINATE_WAS_ON] \{ .PAGINATE \}
+.             if \\n[#PAGINATE_WAS_ON] .PAGINATE
 .          \}
 .       \}
 .       if '\\$1'NULL' \{\
 .          NEWPAGE
-.          if \\n[#FOOTERS_WERE_ON] \{ .FOOTERS \}
+.          if \\n[#FOOTERS_WERE_ON] .FOOTERS
 .          if \\n[#PAGE_NUM_V_POS]=2 \{\
-.             if \\n[#PAGINATE_WAS_ON] \{ .PAGINATE \}
+.             if \\n[#PAGINATE_WAS_ON] .PAGINATE
 .          \}
 .       \}
 .    \}
 .    if \\n[#PAGINATE]=1 \{\
-.       if '\\$1'NULL' \{ .nr #PAGE_NUM_ADJ -\\n[#HOW_MANY] \}
+.       if '\\$1'NULL' .nr #PAGE_NUM_ADJ -\\n[#HOW_MANY]
 .    \}
-.    if \\n[#LINENUMBERS_WERE_ON] \{ .NUMBER_LINES RESUME \}
+.    if \\n[#LINENUMBERS_WERE_ON] .NUMBER_LINES RESUME
 .    rr #HOW_MANY
 .    rr #HEADERS_WERE_ON
 .    rr #FOOTERS_WERE_ON
 .    rr #PAGINATE_WAS_ON
 .END
 \#
+\# FLOATS
+\# ------
+\#
+.am PSPIC \" Need to do this for PSPIC inside a float
+.  vpt 0
+\h'(\\n[ps-offset]u + \\n[ps-deswid]u)'
+.  sp -1
+.  vpt 1
+..
+\# Boxed tables don't play nice with vertical spacing.
+\# Compensation is applied in FLOAT.
+.MAC TS END
+.    if '\\n[.z]'FLOAT*DIV' \{\
+.    if '\\$1'BOXED' \{\
+.       if !\\n[.d] .nr boxed-table 1
+.    \}
+.END
+.
+.MAC TE END
+.    if '\\n[.z]'FLOAT*DIV' .nr bx-tbl-depth \\n[.d]
+.END
+\#
+\# FLOAT
+\# -----
+\# *Arguments:
+\#   [ ADJUST +|-<amount> ] | <anything>
+\# *Function:
+\#   Captures input in a diversion, which is output immediately if
+\#   there's room on the page; otherwise outputs diversion at top of
+\#   next page.
+\# *Notes:
+\#   ADJUST allows for raising or lowering the contents of
+\#   the diversion within the space allotted.
+\#
+.MAC FLOAT END
+.    br
+.\" Clear .ns when a single line of running text precededs float
+.\" at the top of the page.
+.    if \\n[nl]=\\n[#T_MARGIN] \{\
+.       vpt 0
+.       sp -1v
+.       sp
+.       vpt
+.    \}
+.    rr #ARG_NUM
+.    nr #ARG_NUM 0 1
+.    nr #OPTS \\n[#NUM_ARGS]
+.    if '\\$1'ADJUST' \{\
+.       shift
+.       ds float-adj:top \\$1
+.       substring float-adj:top 0 0
+.       ds float-adj \\$1
+.       substring float-adj 1
+.       shift
+.       if '\\*[float-adj:top]'+' .ds float-adj:bottom -
+.       if '\\*[float-adj:top]'-' .ds float-adj:bottom +
+.    \}
+.    ie '\\$1'' \{\
+.       ev FLOAT
+.       evc 0
+.       di FLOAT*DIV
+.       nf
+.    \}
+.    el \{\
+.       br
+.       di
+.       ev
+.       if (\\n[dn]>\\n[.t]):(\\n[D-float]>\\n[.t]) \{\
+.          ie address@hidden \{\
+.             rs
+.             sp
+.          \}
+.          el \{\
+.             if !\\n[defer] .nr defer 0 1
+.             rn FLOAT*DIV FLOAT*DIV:\\n+[defer]
+.             if \\n[D-float] .nr D-float:\\n[defer] \\n[D-float]
+.             nr float-depth:\\n[defer] \\n[dn]
+.             return \" output div after header
+.          \}
+.       \}
+.       sp 0\\*[float-adj:top]\\*[float-adj]
+.       if \\n[boxed-table] .sp 1-.35v
+.       if \\n[.u] .nr #RESTORE_FILL 1
+.       nf
+.       FLOAT*DIV
+.       if \\n[boxed-table] \{\
+.          if \\n[dn]=\\n[bx-tbl-depth] .sp .35v
+.          rr boxed-table
+.          rr bx-tbl-depth
+.       \}
+.       if \\n[D-float] \{\
+.          sp -\\n[dn]u+\\n[#DOC_LEAD]u+\\n[D-float]u
+.       \}
+.       if \\n[#RESTORE_FILL] \{\
+.          fi
+.          rr #RESTORE_FILL
+.       \}
+.       rm FLOAT*DIV
+.       sp 0\\*[float-adj:bottom]\\*[float-adj]
+.       SHIM
+.       rr D-float
+.       rm float-adj
+.       rm float-adj:top
+.       rm float-adj:bottom
+.    \}
+.END
 \#
 \# SET TRAPS FOR HEADERS/FOOTERS/FOOTNOTES
 \# ---------------------------------------
@@ -16887,6 +15878,10 @@
 \#   adjusts #DOC_LEAD so that the last line of text on a page falls
 \#   exactly on #B_MARGIN.
 \#
+.MAC address@hidden END \" Trap-invoked after first line of text on a new page
+.    rr @TOP
+.END
+\#
 .MAC TRAPS END
 .    nr #UNADJUSTED_DOC_LEAD \\n[#DOC_LEAD]
 .\" Remove all header/footer traps
@@ -16903,20 +15898,20 @@
 .    ie \\n[#ADJ_DOC_LEAD]=1 \{\
 .       nr #LINES_PER_PAGE 0 1
 .       nr #DOC_LEAD_ADJ 0 1
-.       nr #DEPTH_TO_B_MARGIN \\n[#PAGE_LENGTH]-\\n[#ORIGINAL_B_MARGIN]-\\n[.v]
+.       nr #DEPTH_TO_B_MARGIN 
\\n[#PAGE_LENGTH]-\\n[#ORIGINAL_B_MARGIN]-\\n[#DOC_LEAD]
 .\" Get the number of unadjusted lines that fit on the page; always a
 .\" bit short of the bottom margin
 .       while 
\\n[#T_MARGIN]+(\\n[#DOC_LEAD]*\\n+[#LINES_PER_PAGE])<\\n[#DEPTH_TO_B_MARGIN] 
\{\
 .
-.\}
+.       \}
 .       nr #LINES_PER_PAGE -1
 .\" Add machine units, 1 at a time, increasing the leading until the
 .\" new leading fills the page properly
 .       while 
\\n[#T_MARGIN]+(\\n[#DOC_LEAD]+\\n+[#DOC_LEAD_ADJ]*\\n[#LINES_PER_PAGE])<=\\n[#DEPTH_TO_B_MARGIN]
 \{\
 .
-.\}
+.       \}
 .       DOC_LEAD \\n[#DOC_LEAD]u+\\n[#DOC_LEAD_ADJ]u
-.\" The "visual" bottom margin is what \n(nl would report on the
+.\" The "visual" bottom margin is what \n[nl] would report on the
 .\" last line before the FOOTER trap is sprung
 .       nr #VISUAL_B_MARGIN 
\\n[#T_MARGIN]+(\\n[#LINES_PER_PAGE]*\\n[#DOC_LEAD])
 .\" Get the difference between #B_MARGIN and #VISUAL_B_MARGIN
@@ -16931,11 +15926,11 @@
 .\" on the page.
 .    el \{\
 .       nr #LINES_PER_PAGE 0 1
-.       nr #DEPTH_TO_B_MARGIN \\n[#PAGE_LENGTH]-\\n[#B_MARGIN]-1v
+.       nr #DEPTH_TO_B_MARGIN \\n[#PAGE_LENGTH]-\\n[#B_MARGIN]
 .       while 
\\n[#T_MARGIN]+(\\n[#DOC_LEAD]*\\n+[#LINES_PER_PAGE])<\\n[#DEPTH_TO_B_MARGIN] 
\{\
 .
-.\}
-.       nr #VISUAL_B_MARGIN 
\\n[#T_MARGIN]+(\\n[#LINES_PER_PAGE]*\\n[#DOC_LEAD]-1v)
+.       \}
+.       nr #VISUAL_B_MARGIN 
\\n[#T_MARGIN]+(\\n[#LINES_PER_PAGE]*\\n[#DOC_LEAD]-\\n[#DOC_LEAD])
 .       nr #FOOTER_DIFF 
(\\n[#PAGE_LENGTH]-\\n[#B_MARGIN])-\\n[#VISUAL_B_MARGIN]
 .       nr #B_MARGIN \\n[#B_MARGIN]+(\\n[#FOOTER_DIFF]-1)
 .       nr #FN_OVERFLOW_TRAP_POS \\n[#B_MARGIN]u-\\n[#FN_LEAD]
@@ -16946,13 +15941,12 @@
 .       nr #SPACE_REMAINING 0
 .       nr #FN_DEPTH 0
 .       nr #VARIABLE_FOOTER_POS 0-\\n[#B_MARGIN]u
-.       wh \\n(.pu FOOTER
+.       wh \\n[.p]u FOOTER
 .       wh -(\\n[#FN_OVERFLOW_TRAP_POS]u) FN_OVERFLOW_TRAP
 .       ch FOOTER -\\n[#B_MARGIN]u
 .    \}
 .END
 \#
-\#
 \# CHECK INDENT
 \# ------------
 \# *Arguments:
@@ -16967,48 +15961,47 @@
 .       if \\n[#QUOTE] \{\
 .          in -\\n[#L_INDENT]u \"Because you added an indent in 2nd line of 
macro
 .          ll -\\n[#L_INDENT]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .       if \\n[#EPIGRAPH] \{\
 .          in -\\n[#L_INDENT]u
 .          ll -\\n[#L_INDENT]u
-.          ta \\n(.lu
+.          ta \\n[.l]u
 .       \}
 .    \}
 .    if \\n[#INDENT_RIGHT_ACTIVE] \{\
 .       ll -\\n[#R_INDENT]u
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .    \}
 .    if \\n[#INDENT_BOTH_ACTIVE] \{\
 .       in \\n[#BL_INDENT]u
 .       ll -\\n[#BR_INDENT]u
-.       ta \\n(.lu
+.       ta \\n[.l]u
 .       if \\n[#QUOTE] \{\
 .          in -\\n[#BL_INDENT]u
 .          ie \\n[#BR_INDENT]=\\n[#BL_INDENT] \{\
 .             ll -\\n[#BR_INDENT]u
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .          el \{\
 .             ll -(\\n[#BR_INDENT]u/2u)
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .       \}
 .       if \\n[#EPIGRAPH] \{\
 .          in -\\n[#BL_INDENT]u
 .          ie \\n[#BR_INDENT]=\\n[#BL_INDENT] \{\
 .             ll -\\n[#BR_INDENT]u
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .          el \{\
 .             ll -(\\n[#BR_INDENT]u/2u)
-.             ta \\n(.lu
+.             ta \\n[.l]u
 .          \}
 .       \}
 .    \}
 .END
 \#
-\#
 \# REMOVE INDENT
 \# -------------
 \# *Arguments:
@@ -17020,15 +16013,15 @@
 .MAC REMOVE_INDENT END
 .    in 0
 .    ll \\n[#L_LENGTH]u
-.    ta \\n(.lu
+.    ta \\n[.l]u
 .END
 \#
-\#
 \# This .em (for all DOC_TYPEs, except 4 [LETTER]) ensures that
 \# deferred footnotes that happen on the 2nd to last page get
 \# output.
 \#
 .MAC TERMINATE END
+\c
 .    ie \\n[#FN_DEPTH] \{\
 .       ie \\n[#FN_DEFER] \{\
 .          br
@@ -17060,25 +16053,25 @@
 \#   (indented with the author's name underneath).
 \#
 .MAC ALL_DONE END
+.    ch FOOTER
+.    ch HEADER
 .    br
-.    FOOTERS OFF
-.    PAGINATION OFF
 .    if \\n[#DOC_TYPE]=4 \{\
-.       if !'\\n(.z'' \{\
+.       if !'\\n[.z]'' \{\
 .          br
+.          ALD \\*[$SIG_SPACE]
 .          di
 .       \}
 .       IQ CLEAR
 .       TQ
-.       ie !'\\*[$CLOSE_INDENT]'' \{ .IL \\*[$CLOSE_INDENT] \}
-.       el \{ .IL \\n[#DOC_L_LENGTH]u/2u \}
+.       LEFT
+.       ie !'\\*[$CLOSE_INDENT]'' .IL \\*[$CLOSE_INDENT]
+.       el .IL \\n[#DOC_L_LENGTH]u/2u
 .       SP
 .       if \\n[#CLOSING] \{\
-.          CLOSING
+.          CLOSING_TEXT
 .          br
 .       \}
-.       ie !'\\*[$SIG_SPACE]'' \{ .ALD \\*[$SIG_SPACE] \}
-.       el \{ .SP 3v \}
 .       PRINT \\*[$AUTHOR_1]
 .    \}
 .END
@@ -17132,7 +16125,7 @@
 \# identically, and the type-style macros (_<type parameter>) all
 \# require the correct name of the calling macro, it's necessary
 \# to create HEADER_ and FOOTER_ macros here.  They're basically
-\# "aliases" of HDRFTR_, but required because you can't alias an
+\# aliases of HDRFTR_, but required because you can't alias an
 \# alias.
 \#
 .MAC FOOTER_CENTER_COLOR END
@@ -17521,24 +16514,15 @@
 .ALIAS   HDRFTR_FAMILY                    _FAMILY
 .ALIAS   HDRFTR_LEFT_FAMILY               _FAMILY
 .ALIAS   HDRFTR_RIGHT_FAMILY              _FAMILY
-.ALIAS   HEAD_FAMILY                      _FAMILY
 .ALIAS   LINENUMBER_FAMILY                _FAMILY
 .ALIAS   PAGENUM_FAMILY                   _FAMILY
-.ALIAS   PARAHEAD_FAMILY                  _FAMILY
 .ALIAS   QUOTE_FAMILY                     _FAMILY
-.ALIAS   SUBHEAD_FAMILY                   _FAMILY
-.ALIAS   SUBSUBHEAD_FAMILY                _FAMILY
 .ALIAS   SUBTITLE_FAMILY                  _FAMILY
 .ALIAS   TITLE_FAMILY                     _FAMILY
 .ALIAS   TOC_FAM                          _FAMILY
 .ALIAS   TOC_FAMILY                       _FAMILY
 .ALIAS   TOC_HEADER_FAMILY                _FAMILY
-.ALIAS   TOC_HEAD_FAMILY                  _FAMILY
-.ALIAS   TOC_PARAHEAD_FAMILY              _FAMILY
 .ALIAS   TOC_PN_FAMILY                    _FAMILY
-.ALIAS   TOC_SUBHEAD_FAMILY               _FAMILY
-.ALIAS   TOC_SUBSUBHEAD_FAMILY            _FAMILY
-.ALIAS   TOC_TITLE_FAMILY                 _FAMILY
 \#
 .ALIAS   AUTHOR_FONT                    _FONT
 .ALIAS   BIBLIOGRAPHY_STRING_FONT       _FONT
@@ -17570,22 +16554,13 @@
 .ALIAS   HDRFTR_CENTER_FONT             _FONT
 .ALIAS   HDRFTR_LEFT_FONT               _FONT
 .ALIAS   HDRFTR_RIGHT_FONT              _FONT
-.ALIAS   HEAD_FONT                      _FONT
 .ALIAS   LINENUMBER_FONT                _FONT
 .ALIAS   PAGENUM_FONT                   _FONT
-.ALIAS   PARAHEAD_FONT                  _FONT
 .ALIAS   QUOTE_FONT                     _FONT
-.ALIAS   SUBHEAD_FONT                   _FONT
-.ALIAS   SUBSUBHEAD_FONT                _FONT
 .ALIAS   SUBTITLE_FONT                  _FONT
 .ALIAS   TITLE_FONT                     _FONT
 .ALIAS   TOC_HEADER_FONT                _FONT
-.ALIAS   TOC_HEAD_FONT                  _FONT
-.ALIAS   TOC_PARAHEAD_FONT              _FONT
 .ALIAS   TOC_PN_FONT                    _FONT
-.ALIAS   TOC_SUBHEAD_FONT               _FONT
-.ALIAS   TOC_SUBSUBHEAD_FONT            _FONT
-.ALIAS   TOC_TITLE_FONT                 _FONT
 \#
 .ALIAS   AUTHOR_SIZE                    _SIZE
 .ALIAS   BIBLIOGRAPHY_STRING_SIZE       _SIZE
@@ -17616,22 +16591,13 @@
 .ALIAS   HDRFTR_LEFT_SIZE               _SIZE
 .ALIAS   HDRFTR_RIGHT_SIZE              _SIZE
 .ALIAS   HDRFTR_SIZE                    _SIZE
-.ALIAS   HEAD_SIZE                      _SIZE
 .ALIAS   LINENUMBER_SIZE                _SIZE
 .ALIAS   PAGENUM_SIZE                   _SIZE
-.ALIAS   PARAHEAD_SIZE                  _SIZE
 .ALIAS   QUOTE_SIZE                     _SIZE
-.ALIAS   SUBHEAD_SIZE                   _SIZE
-.ALIAS   SUBSUBHEAD_SIZE                _SIZE
 .ALIAS   SUBTITLE_SIZE                  _SIZE
 .ALIAS   TITLE_SIZE                     _SIZE
 .ALIAS   TOC_HEADER_SIZE                _SIZE
-.ALIAS   TOC_HEAD_SIZE                  _SIZE
-.ALIAS   TOC_PARAHEAD_SIZE              _SIZE
 .ALIAS   TOC_PN_SIZE                    _SIZE
-.ALIAS   TOC_SUBHEAD_SIZE               _SIZE
-.ALIAS   TOC_SUBSUBHEAD_SIZE            _SIZE
-.ALIAS   TOC_TITLE_SIZE                 _SIZE
 \#
 .ALIAS   ATTRIBUTE_COLOR                 _COLOR
 .ALIAS   AUTHOR_COLOR                    _COLOR
@@ -17667,15 +16633,11 @@
 .ALIAS   HDRFTR_LEFT_COLOR               _COLOR
 .ALIAS   HDRFTR_RIGHT_COLOR              _COLOR
 .ALIAS   HDRFTR_RULE_COLOR               _COLOR
-.ALIAS   HEAD_COLOR                      _COLOR
 .ALIAS   LINEBREAK_COLOR                 _COLOR
 .ALIAS   LINENUMBER_COLOR                _COLOR
 .ALIAS   PAGENUM_COLOR                   _COLOR
-.ALIAS   PARAHEAD_COLOR                  _COLOR
 .ALIAS   QUOTE_COLOR                     _COLOR
 .ALIAS   SECTION_COLOR                   _COLOR
-.ALIAS   SUBHEAD_COLOR                   _COLOR
-.ALIAS   SUBSUBHEAD_COLOR                _COLOR
 .ALIAS   SUBTITLE_COLOR                  _COLOR
 .ALIAS   TITLE_COLOR                     _COLOR
 \#
@@ -17695,9 +16657,6 @@
 .ALIAS   ENDNOTE_TITLE_QUAD         _QUAD
 .ALIAS   EPIGRAPH_QUAD              _QUAD
 .ALIAS   FOOTNOTE_QUAD              _QUAD
-.ALIAS   HEAD_QUAD                  _QUAD
-.ALIAS   SUBHEAD_QUAD               _QUAD
-.ALIAS   SUBSUBHEAD_QUAD            _QUAD
 .ALIAS   TOC_HEADER_QUAD            _QUAD
 \#
 \# Support aliases
@@ -17722,13 +16681,19 @@
 \# As of 1.1.9, EL and TN got changed to make TRAP...TRAP OFF
 \# unnecessary for users.  However, I used both macros extensively
 \# throughout this file (in conjunction with TRAP...TRAP OFF).
-\# EOL is the "old" EL, for the personal use of om.tmac
+\# EOL is the old EL; used only in om.tmac.
 \#
 .MAC EOL END
-.    TRAP OFF
+.    if \\n[.vpt] \{\
+.       vpt 0
+.       nr #RESTORE_TRAP 1
+.    \}
 .    br
 .    sp -1v
-.    TRAP
+.    if \\n[#RESTORE_TRAP] \{\
+.       vpt
+.       rr #RESTORE_TRAP
+.    \}
 .END
 \#
 \# REFER SUPPORT
@@ -17740,9 +16705,9 @@
 \#   Instruct REF to put references in footnotes.
 \#
 .MAC FOOTNOTE_REFS END
-.    ie !'\\$1'' \{ .rr #FN_REF \}
+.    ie !'\\$1'' .rr #FN_REF
 .    el \{\
-.       if r#EN_REF \{ .rr #EN_REF \}
+.       if r #EN_REF .rr #EN_REF
 .       nr #FN_REF 1
 .    \}
 .    REF_STYLE NOTE
@@ -17754,11 +16719,11 @@
 \#   Instruct REF to collect references for endnotes output.
 \#
 .MAC ENDNOTE_REFS END
-.    ie !'\\$1'' \{ .rr #EN_REF \}
+.    ie !'\\$1'' .rr #EN_REF
 .    el \{\
-.       if r#FN_REF \{ .rr #FN_REF \}
+.       if r #FN_REF .rr #FN_REF
 .       nr #EN_REF 1
-.       if !r#EN_MARKER_STYLE \{ .ENDNOTE_MARKER_STYLE SUPERSCRIPT \}
+.       if !r#EN_MARKER_STYLE .ENDNOTE_MARKER_STYLE SUPERSCRIPT
 .    \}
 .    REF_STYLE NOTE
 .END
@@ -17780,7 +16745,7 @@
 .MAC REF END
 .    ie \\n[#FN_REF]+\\n[#EN_REF]=0 \{\
 .       if !\\n[#REF_WARNING]=1 \{\
-.          tm1 "[mom]: Before REF at line \\n(.c, neither FOOTNOTE_REFS nor 
ENDNOTE_REFS
+.          tm1 "[mom]: Before REF at line \\n[.c], neither FOOTNOTE_REFS nor 
ENDNOTE_REFS
 .          tm1 "       has been selected.  If "sort" and "accumulate" are in 
your refer
 .          tm1 "       commands, references will be collected for later output 
with $LIST$.
 .          tm1 "       Otherwise, they will disappear.
@@ -17789,15 +16754,15 @@
 .    \}
 .    el \{\
 .       ie \\n[#REF]=1 \{\
-.          if \\n[#FN_REF]=1 \{ .FOOTNOTE OFF \}
-.          if \\n[#EN_REF]=1 \{ .ENDNOTE OFF  \}
+.          if \\n[#FN_REF]=1 .FOOTNOTE OFF
+.          if \\n[#EN_REF]=1 .ENDNOTE OFF
 .          rr #REF
 .       \}
 .       el \{\
 .          rr #REF_WARNING
 .          nr #REF 1
-.          if \\n[#FN_REF]=1 \{ .FOOTNOTE \\$1 \\$2 \\$3 \}
-.          if \\n[#EN_REF]=1 \{ .ENDNOTE  \}
+.          if \\n[#FN_REF]=1 .FOOTNOTE \\$1 \\$2 \\$3
+.          if \\n[#EN_REF]=1 .ENDNOTE
 .       \}
 .    \}
 .END
@@ -17806,8 +16771,8 @@
 \# -------------------------------------------
 \#
 .MAC REF_BRACKETS_START END
-.    if \\n[#FN_REF]=1 \{ .nr #FN_REF 2 \}
-.    if \\n[#EN_REF]=1 \{ .nr #EN_REF 2 \}
+.    if \\n[#FN_REF]=1 .nr #FN_REF 2
+.    if \\n[#EN_REF]=1 .nr #EN_REF 2
 .    ds $CURRENT_EV \\n[.ev]
 .    ev REFERENCE
 .    evc  \\*[$CURRENT_EV]
@@ -17820,12 +16785,12 @@
 .    ev
 .    chop REFERENCE
 .    unformat REFERENCE
-.    if '\\$0'REF)' \{ .nop (\\*[REFERENCE]) \}
-.    if '\\$0'REF]' \{ .nop [\\*[REFERENCE]] \}
-.    if '\\$0'REF}' \{ .nop {\\*[REFERENCE]} \}
-.    if '\\$0'REF>' \{ .nop <\\*[REFERENCE]> \}
-.    if \\n[#FN_REF]=2 \{ .nr #FN_REF 1 \}
-.    if \\n[#EN_REF]=2 \{ .nr #EN_REF 1 \}
+.    if '\\$0'REF)' .nop (\\*[REFERENCE])
+.    if '\\$0'REF]' .nop [\\*[REFERENCE]]
+.    if '\\$0'REF}' .nop {\\*[REFERENCE]}
+.    if '\\$0'REF>' .nop <\\*[REFERENCE]>
+.    if \\n[#FN_REF]=2 .nr #FN_REF 1
+.    if \\n[#EN_REF]=2 .nr #EN_REF 1
 .END
 \#
 \# These four pairs of aliases allow users to embed references in
@@ -17844,12 +16809,8 @@
 .ALIAS REF> REF_BRACKETS_END
 \#
 .MAC REF_STYLE END
-.    if '\\$1'NOTE' \{\
-.       ds $REF_STYLE NOTE
-.    \}
-.    if '\\$1'BIBLIO' \{\
-.       ds $REF_STYLE BIBLIO
-.    \}
+.    if '\\$1'NOTE'   .ds $REF_STYLE NOTE
+.    if '\\$1'BIBLIO' .ds $REF_STYLE BIBLIO
 .END
 \#
 \# Refer indenting
@@ -17877,9 +16838,9 @@
 \#   Sets register #REF_HY
 \#
 .MAC HYPHENATE_REFS END
-.    ie '\\$1'' \{ .nr #REF_HY 1 \}
+.    ie '\\$1'' .nr #REF_HY 1
 .    el \{\
-.       if r#REF_HY \{ .rr #REF_HY \}
+.       if r #REF_HY .rr #REF_HY
 .    \}
 .END
 \#
@@ -17887,7 +16848,7 @@
 \# versions of the definitions found in the refer module of s.tmac.
 \#
 .de @error
-.tm \\n(.F:\\n(.c: macro error: \\$*
+.tm \\n[.F]:\\n[.c]: macro error: \\$*
 ..
 \#
 \# Underlining unavoidably turns off sentence spacing.
@@ -18656,39 +17617,80 @@
 \#
 \# MARGIN NOTES
 \# ------------
-\# This is a wrapper for MNinit.
 \#
-\# I could use a 'while' loop to assign args to strings, but too many
-\# 'while' loops are slowing things down.
+\# Wrapper for MNinit.
 \#
 .MAC MN_INIT END
-.    if !'\\$1'rerun' \{\
+.    if \B'\\$2' \{\
+.       tm1 "[mom]: 1.x-style \\$0 detected, but you are using v2.x.
+.       tm1 "       v2.x requires flags before arguments to \\$0.
+.       tm1 "       Please read docelement.html#mn-init and update your file.
+.       ab Aborting '\\n[.F]' at \\$0, line \\n[.c].
+.    \}
+.    nr #ARGS  0 1
+.    nr #COUNT 9
+.    while \\n+[#ARGS]<=\\n[#COUNT] \{\
+.      ds $MN-arg\\n[#ARGS] @
+.    \}
+.    nr #FLAG 0 1
+.    nr #COUNT \\n[#NUM_ARGS]
+.    while \\n+[#FLAG]<=\\n[#COUNT] \{\
+.       if '\\$1'RAGGED' \{\
 .       ds $MN-arg1 \\$1
-.       ie '\\$2'' .ds $MN-arg2 @
-.       el .ds $MN-arg2 \\$2
-.       ie '\\$3'' .ds $MN-arg3 @
-.       el .ds $MN-arg3 \\$3
-.       ie '\\$4'' .ds $MN-arg4 @
-.       el .ds $MN-arg4 \\$4
-.       ie '\\$5'' .ds $MN-arg5 @
-.       el .ds $MN-arg5 \\$5
-.       ie '\\$6'' .ds $MN-arg6 @
-.       el .ds $MN-arg6 \\$6
-.       ie '\\$7'' .ds $MN-arg7 @
-.       el .ds $MN-arg7 \\$7
-.       ie '\\$8'' .ds $MN-arg8 @
-.       el .ds $MN-arg8 \\$8
-.       ie '\\$9'' .ds $MN-arg9 @
-.       el .ds $MN-arg9 \\$9
-.    \}
-.    ie \\n[#START_FOR_MNinit]=0 \{\
-.       nr #MNinit_DEFERRED 1
-.       nr #START_FOR_MNinit 1
-.       return
+.       shift
+.       \}
+.       if '\\$1'SYMMETRIC' \{\
+.          ds $MN-arg1 \\$1
+.          shift
+.       \}
+.       if '\\$1'L_WIDTH' \{\
+.          shift
+.          ds $MN-arg2 \\$1
+.          shift
+.       \}
+.       if '\\$1'R_WIDTH' \{\
+.          shift
+.          ds $MN-arg3 \\$1
+.          shift
+.       \}
+.       if '\\$1'GUTTER' \{\
+.          shift
+.          ds $MN-arg4 \\$1
+.          shift
+.       \}
+.       if '\\$1'FONTSTYLE' \{\
+.          shift
+.          ds $MN-arg5 \\$1
+.          shift
+.       \}
+.       if '\\$1'SIZE' \{\
+.          shift
+.          ds $MN-arg6 \\$1
+.          shift
+.       \}
+.       if '\\$1'LEAD' \{\
+.          shift
+.          ds $MN-arg7 \\$1
+.          shift
+.       \}
+.       if '\\$1'COLOR' \{\
+.          shift
+.          ds $MN-arg8 \\$1
+.          shift
+.       \}
+.       if '\\$1'HY' \{\
+.          shift
+.          ds $MN-arg9 \\$1
+.          shift
 .    \}
-.    el \{\
-.       MNinit \\*[$MN-arg1] \\*[$MN-arg2] \\*[$MN-arg3] \\*[$MN-arg4] 
\\*[$MN-arg5] \\*[$MN-arg6] \\*[$MN-arg7] \\*[$MN-arg8] \\*[$MN-arg9]
 .    \}
+.    if '\\*[$MN-arg5]'@' .ds $MN-arg5 \E*[$DOC_FAM]R
+.    MNinit \
+\\*[$MN-arg1] \\*[$MN-arg2] \
+\\*[$MN-arg3] \\*[$MN-arg4] \
+\\*[$MN-arg5] \\*[$MN-arg6] \
+\\*[$MN-arg7] \\*[$MN-arg8] \
+\\*[$MN-arg9]
 .END
 \#
 .MAC MN_OVERFLOW_TRAP END
@@ -18722,11 +17724,11 @@
 \# margin notes ragged-right.  If omitted, margin notes are left
 \# and right adjusted.
 \#
-\#
 .de MNinit
 .  nr #MNinit 1
 .  ds MN-left-ad b\"
 .  ds MN-right-ad b\"
+.  if '\\$1'@' .shift
 .  if '\\$1'RAGGED' \{\
 .    ds MN-left-ad l\"
 .    ds MN-right-ad l\"
@@ -18737,10 +17739,8 @@
 .    ds MN-right-ad l\"
 .    shift
 .  \}
-.  ie \B'\\$3' \
-.    nr MN-sep (n;\\$3)
-.  el \
-.    nr MN-sep 1m
+.  ie \B'\\$3' .nr MN-sep (n;\\$3)
+.  el .nr MN-sep 1m
 .  if ((\\n[.o] - \\n[MN-sep]) < 1n) \
 .    ab MN: Left margin too small (<1n) for requested margin notes separation.
 .  ie \B'\\$1' \{\
@@ -18796,31 +17796,23 @@
 .  \}
 .  ie \B'\\$6' \{\
 '    vs \\$6
-.    nr MN-spacing \\n(.v
+.    nr MN-spacing \\n[.v]
 '    vs
-.    if '\\$6'DOC' \{ .nr MN-spacing \\n[#DOC_LEAD] \}
 .    if \\n[#PRINT_STYLE]=1 \{\
 .       nr MN-spacing \\n[#DOC_LEAD]
 .    \}
 .  \}
-.  el \{\
-.    nr MN-spacing \\n[#DOC_LEAD]
-.  \}
+.  el .nr MN-spacing \\n[#DOC_LEAD]
 .  ie \A'\\$7' \
 .    if !\\n[#PRINT_STYLE]=1 .ds MN-color \\$7\"
 .  el \
 .    if !\\n[#PRINT_STYLE]=1 .ds MN-color
-.  ie \B'\\$8' \
-.    nr MN-hy \\$8
-.  el \
-.    nr MN-hy \\n[.hy]
+.  ie \B'\\$8' .nr MN-hy \\$8
+.  el .nr MN-hy \\n[.hy]
 .  ev MNbottom-left-env
-.  if \A'\\*[MN-font]' \
-.    ft \\*[MN-font]
-.  if \\n[MN-size] \
-.    ps \\n[MN-size]u
-.  if \\n[MN-spacing] \
-.    vs \\n[MN-spacing]u
+.  if \A'\\*[MN-font]' .ft \\*[MN-font]
+.  if \\n[MN-size] .ps \\n[MN-size]u
+.  if \\n[MN-spacing] .vs \\n[MN-spacing]u
 .  ll \\n[MN-left-width]u
 .  ad \\*[MN-left-ad]
 .  hy \\n[MN-hy]
@@ -18828,12 +17820,9 @@
 .  nop \m[\\*[MN-color]]\c
 .  ev
 .  ev MNbottom-right-env
-.  if \A'\\*[MN-font]' \
-.    ft \\*[MN-font]
-.  if \\n[MN-size] \
-.    ps \\n[MN-size]u
-.  if \\n[MN-spacing] \
-.    vs \\n[MN-spacing]u
+.  if \A'\\*[MN-font]' .ft \\*[MN-font]
+.  if \\n[MN-size] .ps \\n[MN-size]u
+.  if \\n[MN-spacing] .vs \\n[MN-spacing]u
 .  ll \\n[MN-right-width]u
 .  ad \\*[MN-right-ad]
 .  hy \\n[MN-hy]
@@ -18874,11 +17863,11 @@
 .\}
 .  if !\\n[#MNinit]=1 \{\
 .    tm [mom]: Macro MN: You must set parameters with MN_INIT before using MN.
-.    ab Aborting
+.    ab Aborting '\\n[.F]' at MN, line \\n[.c].
 .  \}
 .  ie !'\\$1'' \{\
 .    if \\n[MN-active] \{\
-.      tm [mom]: Macro MN: Can't handle nested margin notes.
+.      tm [mom]: Macro MN: Can't handle nested margin notes, line \\n[.c].
 .      return
 .    \}
 .    nr MN-active 1
@@ -18909,7 +17898,7 @@
 .    if \\n[MN-active] \{\
 .      br
 .      di
-.      nr MN-div-\\*[MN-curr]-depth \\n(dn
+.      nr MN-div-\\*[MN-curr]-depth \\n[dn]
 .      ev
 .    \}
 .    nr MN-active 0
@@ -18952,10 +17941,11 @@
 .      sp 1v
 .      SHIM
 .      if \\n[#SHIM]>\\n[MN-spacing] .sp -(1v+\\n[MN-lead-adj]u)
-.      tm [mom]: Macro MN: Warning: Left margin note #\\n[MN-curr] on page 
\\n[#P] shifted down.
+.      tm \
+[mom]: Macro MN: Warning: Left margin note #\\n[MN-curr] on page \\n[#P] 
shifted down.
 .    \}
 .\" If last margin note doesn't fit
-.    if ( (\\n(nl+\\n[MN-div-l-\\n[MN-curr]-depth]) > 
(\\n(.p+\\n[#VARIABLE_FOOTER_POS]-1) ) \{\
+.    if ( (\\n[nl]+\\n[MN-div-l-\\n[MN-curr]-depth]) > 
(\\n[.p]+\\n[#VARIABLE_FOOTER_POS]-1) ) \{\
 .      if \\n[MN-shifted]=1 \{\
 .        sp -(1v+\\n[#SHIM]u)
 .        rm MN-div-l-\\n[MN-curr]
@@ -18966,7 +17956,7 @@
 .      nr #no-repeat-MN-left 1
 .      nr #OVERFLOW_LEFT 1
 .      ie \\n[#FN_COUNT]=0 \{\
-.        ch FOOTER \\n(.pu
+.        ch FOOTER \\n[.p]u
 .        wh \\n[#VARIABLE_FOOTER_POS]u+\\n[MN-lead-adj]u+1u MN_OVERFLOW_TRAP
 .      \}
 .      el \{\
@@ -19008,21 +17998,23 @@
 .      sp 1v
 .      SHIM
 .      if \\n[#SHIM]>\\n[MN-spacing] .sp -(1v+\\n[MN-lead-adj]u)
-.      tm [mom]: Macro MN: Warning: Right margin note #\\n[MN-curr] on page 
\\n[#P] shifted down.
+.      tm [mom]: \
+Macro MN: Warning: Right margin note #\\n[MN-curr] on page \\n[#P] shifted 
down.
 .    \}
 .\" If last margin note doesn't fit
-.    if ( (\\n(nl+\\n[MN-div-r-\\n[MN-curr]-depth]) > 
(\\n(.p+\\n[#VARIABLE_FOOTER_POS]-1) ) \{\
+.    if ( (\\n[nl]+\\n[MN-div-r-\\n[MN-curr]-depth]) > 
(\\n[.p]+\\n[#VARIABLE_FOOTER_POS]-1) ) \{\
 .      if \\n[MN-shifted]=1 \{\
 .        sp -(1v+\\n[#SHIM]u)
 .        rm MN-div-r-\\n[MN-curr]
-.        tm1 "[mom]: No room to start right margin note #\\n[MN-curr] on page 
\\n[#P] on page \\n[#P].
+.        tm1 \
+[mom]: No room to start right margin note #\\n[MN-curr] on page \\n[#P] on 
page \\n[#P].
 .        tm1 "       Ignoring margin note.
 .        rr MN-shifted
 .      \}
 .      nr #no-repeat-MN-right 1
 .      nr #OVERFLOW_RIGHT 1
 .      ie \\n[#FN_COUNT]=0 \{\
-.        ch FOOTER \\n(.pu
+.        ch FOOTER \\n[.p]u
 .        wh \\n[#VARIABLE_FOOTER_POS]u+\\n[MN-lead-adj]u+1u MN_OVERFLOW_TRAP
 .      \}
 .      el \{\
@@ -19041,4 +18033,429 @@
 .  if !\\n[#no-repeat-MN-right]=1 .vpt 1
 ..
 \#
+\# PDF initial setup
+\# =================
+\#
+.nr CURRENT_LEVEL 0
+.nr VIRTUAL_LEVEL 0
+.nr #PDF_BOOKMARKS 1
+.nr #PDF_BOOKMARKS_OPEN 1
+.pdfview /PageMode /UseOutlines
+\#
+\# TOC_BEFORE_HERE
+\# ---------------
+\#
+\# Call this and the TOC will be placed preceding this page
+\#
+.MAC TOC_BEFORE_HERE END
+.    nr TOC_BH 1
+.    pdfpagename MOM:TOC
+.END
+\#
+\# TOC_AFTER_HERE
+\# ---------------
+\#
+\# Call this and the TOC will be placed after this page
+\#
+.MAC TOC_AFTER_HERE END
+.    nr TOC_BH 2
+.    pdfpagename MOM:TOC
+.END
+\#
+\# PDF_LINK_COLOR
+\# -----------------
+\#
+\# Arguments:-
+\#    <name defined by previous call to XCOLOR or NEWCOLOR> or
+\#    <red> <green> <blue> all 0.0 -> 1.0
+\# Notes
+\#   Should be called before START but can also be called at any time to 
change colour
+\#   The colour assigned at the end of the document is used for all links in 
the TOC
+\#
+.MAC PDF_LINK_COLOR END
+.    ie \\n[.$]==3 \{\
+.       ds PDFHREF.COLOUR \\$*
+.       if !(\B'\\$1' & \B'\\$2' & \B'\\$3') \{\
+.          tm1 "[mom]: All three arguments to \\$0 at line \\n[.c] must be 
decimal.
+.          tm1 "       Continuing to process using default link color.
+.          ds PDFHREF.COLOUR 0.0 0.3 0.9
+.       \}
+.       defcolor pdf:href.colour rgb \\*[PDFHREF.COLOUR]
+.       ds PDFHREF.TEXT.COLOUR pdf:href.colour
+.    \}
+.    el \{\
+.       ie \\n[.$]==0 \{\
+.          if dPDFHREF.TEXTCOL.DEFAULT \
+.             PDF_LINK_COLOR \\*[PDFHREF.TEXTCOL.DEFAULT]
+.       \}
+.       el \{\
+.          ds ARG_1 \\$1
+.          substring ARG_1 0 0
+.          ie '\\*[ARG_1]'#' \{\
+.             defcolor pdf:href.colour rgb \\$1
+.             ds PDFHREF.TEXT.COLOUR pdf:href.colour
+.          \}
+.          el \{\
+.             ie dCOLAL_\\$1 .ds PDFHREF.TEXT.COLOUR \\*[COLAL_\\$1]
+.             el .ds PDFHREF.TEXT.COLOUR \\$1
+.          \}
+.       \}
+.    \}
+.    if !\\n[PDFHREF_COLOR_SET]=1 \{\
+.       nr PDFHREF_COLOR_SET 1
+.    \}
+.END
+\#
+\# AUTO_RELOCATE_TOC
+\# -----------------
+\#
+\# Call before START to have TOC automatically relocated to after the
+\# DOC COVER (if there is one) or the COVER if there isn't
+\#
+.MAC AUTO_RELOCATE_TOC END
+.    if '\\$1''                .nr TOC.RELOCATE 1
+.    if '\\$1'TOP'             .nr TOC.RELOCATE 2
+.    if '\\$1'BEFORE_DOCCOVER' .nr TOC.RELOCATE 3 \" Same as TOP unless no 
DOCCOVER
+.    if '\\$1'AFTER_DOCCOVER'  .nr TOC.RELOCATE 4
+.    if '\\$1'BEFORE_COVER'    .nr TOC.RELOCATE 5
+.    if '\\$1'AFTER_COVER'     .nr TOC.RELOCATE 6
+.END
+\#
+\# PDF_BOOKMARK
+\# ------------
+\# *Argument:
+\#   Hierarchy Level
+\#   Bookmark Text
+\# *Function:
+\#   Creates a bookmark using the given text
+\#   The level controls the hierarchy of the bookmarks
+\# *Notes
+\#   Bookmarks can be turned off (will not be added to document outline) by 
calling
+\#   "PDF_BOOKMARKS NO" and turned on with "PDF_BOOKMARKS".
+\#
+\#   Bookmarks can be open or closed by calling PDF_BOOKMARKS_OPEN
+\#
+.MAC PDF_BOOKMARK END
+.    if \\n[#PDF_BOOKMARKS] \{\
+.       ie '\\$1'NAMED' \{\
+.          ds PDF_NM -T \\$2
+.          ds PDF_NM2 \\$2
+.          shift 2
+.       \}
+.       el .ds PDF_NM
+.       nr LEVEL_REQ \\$1
+.       shift
+.       ie \\n[LEVEL_REQ]>\\n[VIRTUAL_LEVEL] \{\
+.          nr VIRTUAL_LEVEL \\n[LEVEL_REQ]
+.          nr LEVEL_REQ \\n[CURRENT_LEVEL]+1
+.       \}
+.       el \{\
+.          ie \\n[LEVEL_REQ]<\\n[VIRTUAL_LEVEL] \{\
+.             nr VIRTUAL_DIFF \\n[VIRTUAL_LEVEL]-\\n[LEVEL_REQ]
+.             nr VIRTUAL_LEVEL \\n[LEVEL_REQ]
+.             nr LEVEL_REQ (\\n[CURRENT_LEVEL]-\\n[VIRTUAL_DIFF])>?1
+.          \}
+.          el .nr LEVEL_REQ \\n[CURRENT_LEVEL]
+.       \}
+.       ds PDF_TX \\$*
+\#.       asciify PDF_TX
+.       pdfmomclean PDF_TX
+.\" .       ev protect
+.       nr PDF_LEV (\\n[LEVEL_REQ]*\\n[#PDF_BOOKMARKS_OPEN])
+.       ie '\\*[.T]'ps' \{\
+.           if !'\\*[PDF_NM]'' \{\
+.              pdfhref M -N \\*[PDF_NM2] -- \\*[PDF_TX]
+.              if !dpdf:href.map .tm gropdf-info:href \\*[PDF_NM2] \\*[PDF_TX]
+.           \}
+.           pdfbookmark \\n[PDF_LEV] \\*[PDF_TX]
+.       \}
+.       el .pdfbookmark \\*[PDF_NM] \\n[PDF_LEV] \\$*
+.\" .       ev
+.       nr CURRENT_LEVEL \\n[LEVEL_REQ]
+.       rr LEVEL_REQ
+.       rr PDF_LEV
+.       rr VIRTUAL_DIFF
+.       rm PDF_NM
+.    \}
+.END
+\#
+\# PDF_TITLE
+\# ---------
+\# *Argument:
+\#   Title Text
+\# *Function
+\#   Set the PDF title (this is often used by PDF readers to title the main 
window)
+\#
+.MAC PDF_TITLE END
+.    ds pdftitle \\$*
+.    pdfmomclean pdftitle
+\#.    pdfinfo /Title \\*[pdftitle]
+.    nop \!x X ps:exec [/Title (\\*[pdftitle]) /DOCINFO pdfmark
+.END
+\#
+\# PDF_BOOKMARKS
+\# -------------
+\# *Argument:
+\#   <nothing> | <anything>
+\# *Function:
+\#   With no parameter turns on outline bookmarks
+\#   With any parameter turns off outline bookmarks
+\#
+.MAC PDF_BOOKMARKS END
+.    ie '\\$1'' .nr #PDF_BOOKMARKS 1
+.    el .nr #PDF_BOOKMARKS 0
+.END
+\#
+\# PDF_BOOKMARKS_OPEN
+\# ------------------
+\# *Argument:
+\#   <number> | <nothing> | <text>
+\# *Function:
+\#   If arg is numeric all Bookmark levels > arg are closed
+\#   If arg is empty all bookmarks are open
+\#   If arg is any text then any following bookmarks are closed
+\#
+.MAC PDF_BOOKMARKS_OPEN END
+.    ie \B'\\$1' \{\
+.       nr PDFOUTLINE.FOLDLEVEL \\$1
+.       nr #PDF_BOOKMARKS_OPEN 1
+.    \}
+.    el .if '\\*[.T]'pdf' \{\
+.       nr PDFOUTLINE.FOLDLEVEL 10000
+.       ie '\\$1'' .nr #PDF_BOOKMARKS_OPEN 1
+.       el .nr #PDF_BOOKMARKS_OPEN 0-1
+.    \}
+.END
+\#
+\# PDF_LINK
+\# --------
+\# *Arguments:
+\#    $1 = named link
+\#    [PREFIX text] : text to prefix link
+\#    [SUFFIX text] : text after link
+\#    text
+\#
+\# *Notes
+\#    Text is output as a hotspot link to named destination.
+\#    If text has final '*' it is replaced with the text associated with the 
link
+\#
+.MAC PDF_LINK END
+.    ds PDF_NM \\$1
+.    shift
+.    ie '\\$1'PREFIX' \{\
+.       ds PDF_PRE -P "\&\\$2"
+.       shift 2
+.    \}
+.    el .ds PDF_PRE
+.    ie '\\$1'SUFFIX' \{\
+.       ds PDF_POST -A "\\$2"
+.       shift 2
+.    \}
+.    el .ds PDF_POST
+.    ds PDF_AST_Q
+.    ds PDF_TXT \&\\$1
+.    ds PDF_AST \\*[PDF_TXT]
+.    substring PDF_AST -1 -1
+.    if '\\*[PDF_AST]'+' \{\
+.       ds PDF_AST *
+.       ds PDF_AST_Q ""
+.    \}
+.    if '\\*[PDF_AST]'*' \{\
+.        chop PDF_TXT
+.        ie '\\*[.T]'pdf' \{\
+.           ie d pdf:look(\\*[PDF_NM]) \
+.               as PDF_TXT 
\&\\*[PDF_AST_Q]\\*[pdf:look(\\*[PDF_NM])]\\*[PDF_AST_Q]
+.           el \{\
+.               as PDF_TXT Unknown
+.               if !rPDF_UNKNOWN .tm \
+\\n[.F]:\\n[.c]: forward reference detected (please run using 'pdfmom')
+.               nr PDF_UNKNOWN 1
+.           \}
+.        \}
+.        el \{\
+.            ie d pdf:href(\\*[PDF_NM]).info \
+.               as PDF_TXT 
\&\\*[PDF_AST_Q]\\*[pdf:href(\\*[PDF_NM]).info]\\*[PDF_AST_Q]
+.            el .as PDF_TXT Unknown
+.       \}
+.    \}
+.    pdfhref L \\*[PDF_PRE] \\*[PDF_POST] -D \\*[PDF_NM] -- \\*[PDF_TXT]
+.    rm PDF_NM
+.    rm PDF_PRE
+.    rm PDF_POST
+.    rm PDF_TXT
+.    rm PDF_AST
+.    rm PDF_AST_Q
+.END
+\#
+.MAC PDF_WWW_LINK END
+.    ds PDF_NM \\$1
+.    shift
+.    ie '\\$1'PREFIX' \{\
+.       ds PDF_PRE -P "\\$2"
+.       shift 2
+.    \}
+.    el .ds PDF_PRE
+.    ie '\\$1'SUFFIX' \{\
+.       ds PDF_POST -A "\\$2"
+.       shift 2
+.    \}
+.    el .ds PDF_POST
+.    ds PDF_AST_Q
+.    ds PDF_TXT \\$1
+.    ds PDF_AST \\*[PDF_TXT]
+.    substring PDF_AST -1 -1
+.    if '\\*[PDF_AST]'+' \{\
+.       ds PDF_AST *
+.       ds PDF_AST_Q ""
+.    \}
+.    if '\\*[PDF_AST]'*' \{\
+.       chop PDF_TXT
+.       as PDF_TXT \&\\*[PDF_AST_Q]\\*[PDF_NM]\\*[PDF_AST_Q]
+.    \}
+.    if '\\*[PDF_TXT]'' .ds PDF_TXT \\*[PDF_NM]
+.    pdfhref W -D "\\*[PDF_NM]" \\*[PDF_PRE] \\*[PDF_POST] -- \\*[PDF_TXT]
+.    rm PDF_NM
+.    rm PDF_PRE
+.    rm PDF_POST
+.    rm PDF_TXT
+.    rm PDF_AST PDF_AST_Q
+.END
+\#
+.MAC PDF_TARGET END
+.    ds  ARG_1 \\$1
+.    shift
+.    pdfhref M -N \\*[ARG_1] -- \\$*
+.    if '\\*[.T]'ps' .if !dpdf:href.map .tm gropdf-info:href \\*[ARG_1] \\$*
+.END
+\#
+\# PDF_IMAGE
+\# ---------
+\# *Arguments:
+\#   [ -L -| -R | -C | -I <indent> ] \
+\#     <image file> <width> <height> \
+\#     [ SCALE <factor> ] [ ADJUST +|-<vertical shift> ]
+\# *Function:
+\#   Allows embedding of PDF images with the same arguments as PSPIC
+\#   plus SCALE and ADJUST options.
+\# *Notes:
+\#   <image file> <width> <height> are required.
+\#
+.MAC PDF_IMAGE END
+.    br
+.    ev IMG  \" Protect fill mode of running text
+.    evc 0
+.    ds pos:tmp \\$1
+.    substring pos:tmp 0 0
+.    ie !'\\*[pos:tmp]'-' .ds pdf-img:pos -C
+.    el \{\
+.       ie '\\$1'-I' \{\
+.          shift
+.          ds pdf-img:ind \\$1
+.          ds pdf-img:pos -L
+.          shift
+.       \}
+.       el \{\
+.          ds pdf-img:pos \\$1
+.          shift
+.       \}
+.    \}
+.    ds pdf-img:file \\$1
+.    ds address@hidden \\$1
+.    substring address@hidden -1 -3
+.    if !'address@hidden'pdf' \{\
+.       tm1 "[mom]: Image file at line \\n[.c] not found, or not a PDF image.
+.       ab Aborting.
+.    \}
+.    nr pdf-img:width \\$2
+.    nr pdf-img:depth \\$3
+.    shift 3
+.    nr loop-counter \\n[#NUM_ARGS]
+.    nr loop-count 0 1
+.    while \\n+[loop-count]<=\\n[loop-counter] \{\
+.       if '\\$1'SCALE' \{\
+.          shift
+.          nr pdf-img:scale \\$1
+.          shift
+.          nr pdf-img:width \\n[pdf-img:width]*\\n[pdf-img:scale]/100
+.          nr pdf-img:depth \\n[pdf-img:depth]*\\n[pdf-img:scale]/100
+.       \}
+.       if '\\$1'ADJUST' \{\
+.         shift
+.         ds address@hidden \\$1
+.         substring address@hidden 0 0
+.         ie 'address@hidden'+' \{\
+.            ds pdf-img:top     +
+.            ds pdf-img:bottom  -
+.         \}
+.         el \{\
+.            ds pdf-img:top     -
+.            ds pdf-img:bottom  +
+.         \}
+.         ds address@hidden \\$1
+.         substring address@hidden 1
+.         ds pdf-img:adj address@hidden
+.         rm address@hidden
+.         shift
+.       \}
+.    \}
+.    if '\\*[pdf-img:adj]'' \{\
+.       ds pdf-img:adj    0
+.       ds pdf-img:bottom +
+.    \}
+.    di PDF*IMAGE
+.    nf
+.    if d pdf-img:ind .ti \\*[pdf-img:ind]
+.    nop \X'pdf: pdfpic \\*[pdf-img:file] \\*[pdf-img:pos] \\n[pdf-img:width]z 
\\n[pdf-img:depth]z \\n[.ll]z'
+.    di
+.    nr dn +\\n[pdf-img:depth]-1v
+.    nr pdf-img 1
+.    if \\n[pdf-img:depth]>\\n[.t] \{\
+.       ie address@hidden .rs
+.       el \{\
+.          nr pgnum \\n%+\\n[#PAGE_NUM_ADJ] 1
+.          tm1 "[mom]: Image \\*[pdf-img:file] at line \\n[.c] does not fit on 
output page \\n[pgnum].
+.          tm1 "       Shifting to top of page \\n+[pgnum].
+.          ev
+.          return
+.       \}
+.    \}
+.    sp \\*[pdf-img:top]\\*[pdf-img:adj]
+.    PDF*IMAGE
+.    rm PDF*IMAGE
+.    sp \\n[pdf-img:depth]u
+.    PDF_IMAGE_CLEAN
+.    ev
+.END
+\#
+.MAC PDF_IMAGE_CLEAN END
+.    if !'\\n[.z]'FLOAT*DIV' .SHIM  \" Get ourselves back on the baseline grid
+.    rm pdf-img:adj
+.    rm pdf-img:bottom
+.    rm pdf-img:file
+.    rm pdf-img:ind
+.    rm pdf-img:top
+.    rr pdf-img:depth
+.    rr pdf-img:scale
+.    rr pdf-img:width
+.END
+\#
+.de pdfmomclean
+.   ie '\\n[.z]'' \{\
+.      ds pdfcleaned \\$*
+.      ev pdfcln
+.      tr \[em]-
+.      nf
+.      box pdf:clean
+.      nop \\*[\\*[pdfcleaned]]
+.      fl
+.      box
+.      chop pdf:clean
+.      asciify pdf:clean
+.      ev
+.      ds \\*[pdfcleaned] "\\*[pdf:clean]
+.      rm pdf:clean
+.      tr \[em]\[em]
+.    \}
+.    el .nop \!.pdfmomclean \\$@
+..
 \# vim: ft=groff: encoding=latin1: fileencoding=latin1: nomodified:

Index: examples/README.txt
===================================================================
RCS file: /sources/groff/groff/contrib/mom/examples/README.txt,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -b -r1.5 -r1.6
--- examples/README.txt 5 Jan 2009 20:10:47 -0000       1.5
+++ examples/README.txt 31 Aug 2012 22:49:58 -0000      1.6
@@ -1,48 +1,33 @@
-    Copyright 2004, 2005, 2006, 2009
+    Copyright 2004, 2005, 2006, 2009, 2010, 2011, 2012
       Free Software Foundation, Inc.
 
     Copying and distribution of this file, with or without modification,
     are permitted in any medium without royalty provided the copyright
     notice and this notice are preserved.
 
+========================================================================
+
 The files in this directory show mom in action.
 
 If you have downloaded and untarrred a version of mom from her
 homepage, you'll see that none of the example files come with
-corresponding PostScript (.ps) files, as they do with pre-compiled
+corresponding PDF (.pdf) files, as they do with pre-compiled
 versions of groff, or groff built from source.
 
-I haven't included the PostScript output because I want to
-keep the mom archive as lean as possible.  To view the PostScript
-output, process the files with groff and either
-
-    a) send the output to a separate file for previewing with a
-       PostScript viewer such as gv (ghostview), or
-
-    b) to your printer.
-
-Using the file sample_docs.mom as an example, you would
-accomplish a) like this:
-
-    groff -mom -Tps sample_docs.mom > sample_docs.ps
-    gv sample_docs.ps
-
-Accomplishing b) depends on your printer setup, but a fairly
-standard way to do it would be
-
-    groff -mom -Tps sample_docs.mom | lpr
-
-                  or
-
-    groff -mom -Tps -l sample_docs.mom
-
-Note: I don't recommend previewing with gxditview because it doesn't
-render some of mom's effects properly.
+I haven't included the PDF output because I want to keep the mom
+archive as lean as possible.  To view the PDF output, process the
+files with pdfmom(1).
+
+    pdfmom letter.mom > letter.pdf
+    pdfmom mom-pdf.mom > mom-pdf.pdf
+    pdfmom sample_docs.mom > sample_docs.pdf
+    pdfmom typesetting.mom > typesetting.pdf
 
 The files themselves
 --------------------
 
-All are set up for 8.5x11 inch paper (US letter).
+All are set up for US letter papersize except mom-pdf.mom, which
+uses A4.
 
 ***typesetting.mom**
 
@@ -51,72 +36,53 @@
 as well as some of the refinements and fine-tuning available via
 macros and inline escapes.
 
-Because the file also demonstrates a "cutaround" using a small
-picture (of everybody's favourite mascot, Tux), the PostScript file,
-penguin.ps has been included in the directory.
+Because the file also demonstrates a cutaround using a small picture
+of everybody's favourite mascot, Tux, the PDF file, penguin.pdf has
+been included in the directory.
 
 ***sample_docs.mom***
 
 The file, sample_docs.mom, shows examples of three of the document
 styles available with the mom's document processing macros, as well
-as demonstrating the use of COLLATE.
+as demonstrating the use of COLLATE.  It also shows off some of
+mom's PDF features, including a PDF outline and clickable links in
+the printable Table of Contents.
+
+The last sample, set in 2 columns, demonstrates mom's flexibility
+when it comes to designing documents.
 
 The PRINTSTYLE of this file is TYPESET, to give you an idea of mom's
 default behaviour when typesetting a document.
 
-The last sample, set in 2 columns, shows off mom's flexibility
-when it comes to designing documents.
-
 If you'd like to see how mom handles exactly the same file when the
-PRINTSTYLE is TYPEWRITE (i.e. typewritten, double-spaced), simply
-change
-
-    .PRINTSTYLE TYPESET
-
-to
-
-    .PRINTSTYLE TYPEWRITE
-
-near the top of the file. 
+PRINTSTYLE is TYPEWRITE (ie typewritten, double-spaced), simply
+change .PRINTSTYLE TYPESET to .PRINTSTYLE TYPEWRITE near the top of
+the file.
 
 ***letter.mom***
 
 This is just the tutorial example from the momdocs, ready for
 previewing.
 
-***elvis_syntax.new***
-
-For those who use the vi clone, elvis, you can paste this file into
-your elvis.syn.  Provided your mom documents have the extension
-.mom, they'll come out with colorized syntax highlighting.  The
-rules in elvis_syntax aren't exhaustive, but they go a LONG way to
-making mom files more readable.
-
-The file elvis_syntax (for pre-2.2h versions of elvis) is no longer
-being maintained.  Users are encouraged to update to elvis 2.2h or
-higher, and to use elvis_syntax.new for mom highlighting.
+***mom-pdf.mom***
 
-I'll be very happy if someone decides to send me syntax highlighting
-rules for emacs. :)
+The manual, Producing PDFs with mom and groff.
 
 ***mom.vim***
 
-Christian V. J. Brüssow has kindly contributed a set of mom syntax
-highlighting rules for use with vim.  Copy the file to your
-~/.vim/syntax directory, then, if your vim isn't already set up to
+The vim syntax highlighting rules are based on those provided by
+Christian V. J. Brüssow (address@hidden).  Copy mom.vim file to your
+~/.vim/syntax directory; then, if your vim isn't already set up to
 do so, enable mom syntax highlighting with
 
     :syntax enable
-
 or
-
     :syntax on
 
-Please note: I don't use vim, so I won't be making changes to this
-file myself.  Christian Brüssow is the maintainer of the ruleset,
-which is available on the Web at
-
-    http://www.cvjb.de/comp/vim/mom.vim
+***elvis_syntax.new***
 
-Contact Christian (address@hidden) if you have any suggestions or
-requests.
+For those who use the vi clone, elvis, you can paste this file into
+your elvis.syn.  Provided your mom documents have the extension
+.mom, they'll come out with colorized syntax highlighting.  The
+rules in elvis_syntax aren't exhaustive, but they go a long way to
+making mom files more readable.

Index: examples/elvis_syntax.new
===================================================================
RCS file: /sources/groff/groff/contrib/mom/examples/elvis_syntax.new,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -b -r1.11 -r1.12
--- examples/elvis_syntax.new   5 Jan 2009 20:10:47 -0000       1.11
+++ examples/elvis_syntax.new   31 Aug 2012 22:49:58 -0000      1.12
@@ -1,4 +1,4 @@
-" Copyright 2004, 2005, 2006, 2009
+" Copyright 2004, 2005, 2006, 2009, 2010, 2011, 2012
 " Free Software Foundation, Inc.
 "
 " Copying and distribution of this file, with or without modification,

Index: examples/letter.mom
===================================================================
RCS file: /sources/groff/groff/contrib/mom/examples/letter.mom,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -b -r1.4 -r1.5
--- examples/letter.mom 3 Oct 2010 23:26:29 -0000       1.4
+++ examples/letter.mom 31 Aug 2012 22:49:58 -0000      1.5
@@ -1,4 +1,4 @@
-\# Copyright 2004, 2005, 2006, 2009
+\# Copyright 2004, 2005, 2006, 2009, 2010, 2011, 2012
 \# Free Software Foundation, Inc.
 \#
 \# Copying and distribution of this file, with or without modification,
@@ -10,7 +10,7 @@
 .PRINTSTYLE TYPESET
 .START
 .DATE
-August 25, 2010
+August 25, 2012
 .TO
 GUILLAUME BARRIÈRES
 Minidoux Corporation

Index: examples/mom.vim
===================================================================
RCS file: /sources/groff/groff/contrib/mom/examples/mom.vim,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- examples/mom.vim    5 Jan 2009 20:10:47 -0000       1.3
+++ examples/mom.vim    31 Aug 2012 22:49:58 -0000      1.4
@@ -1,4 +1,4 @@
-" Copyright 2004, 2005, 2006, 2009
+" Copyright 2012
 " Free Software Foundation, Inc.
 "
 " Copying and distribution of this file, with or without modification,
@@ -7,7 +7,7 @@
 
 " Vim syntax file
 " Language:    mom
-" Maintainer:  Christian V. J. Brüssow <address@hidden>
+" Maintainer:  Peter Schaffter (address@hidden)
 " Last Change: So 06 Mär 2005 17:28:13 CET
 " Filenames:   *.mom
 " URL:         http://www.cvjb.de/comp/vim/mom.vim
@@ -33,71 +33,75 @@
 
 " Characters allowed in keywords
 if version >= 600
-       setlocal iskeyword=@,#,$,%,48-57,.,@-@,_,192-255
+       setlocal iskeyword=@,#,$,%,48-57,.,@-@,_,\\,{,},192-255
 else
-       set iskeyword=@,#,$,%,48-57,.,@-@,_,192-255
+       set iskeyword=@,#,$,%,48-57,.,@-@,_,\\,{,},192-255
 endif
 
-" Some special keywords
-syn keyword momTodo contained TODO FIXME
-syn keyword momDefine .de .. .ALIAS .ALIASN
-
-" Preprocessor keywords
-syn keyword momPreprocessor .EQ .EN .GS .GE .GF .PS .PE .R1 .R2 .TS .TE .TH
-syn keyword momPreprocessor .G1 .G2 .IS .IE .cstart .cend
+" mom/groff macros and requests (the initial dot or single-quote)
+"
+" Highlighting carries through to EOL; macro names, requests and
+" arguments are contained
+syn match startRequest /^\s*\(\.\|'\)\s*.*$/ 
contains=momMacro,groffCommentLine,groffRequest,momRegister,groffNoLineBreak,momInteger,groffUnit,momString,momSpecialParam,groffDelimiter,groffRegister,groffPreprocessor,groffBraces
+
+" mom macros
+syn region momMacro start=/^\s*\(\.\|'\)\s*\zs[A-Z0-9_(){}\[\]]\+/ 
end=/\s\+\|$/
+
+" mom registers and strings
+syn match momRegister /\(\$\|#\)[A-Za-z][_0-9A-Za-z]*/ 
contains=momRegisterStart
+
+syn match momRegisterStart /#\|\$/ contained
+
+" mom comment region
+syn region momCommentRegion matchgroup=startRequest 
start='\<\.\(COMMENT\)\|\(SILENT\)\>' 
end='\<\.\(COMMENT\s\+OFF\)\|\(SILENT\s\+OFF\)\>' skip='$'
+
+" groff requests
+syn match groffRequest /^\s*\(\.\|'\)\s*\zs[a-z0-9]\+/
+
+" groff comment region
+syn region groffCommentLine start='\(\\!\)\|\(\\"\)\|\(\\#\)' end='$' 
contains=momTodo
+syn region groffCommentRegion start="^\s*\.\s*ig" matchgroup=startRequest 
end="^\.\.$" contains=startRequest
 
-" Number Registers
-syn match momNumberReg '\.#[A-Za-z][_0-9A-Za-z]*'
+" Preprocessor requests
+syn match groffPreprocessor 
/[^A-Z]\zs\(EQ\s*$\|EN\s*$\|GS\s*$\|GE\s*$\|GF\s*$\|PS\s*$\|PE\s*$\|R1\s*$\|R2\s*$\|TS\s*$\|TE\s*$\|TH\s*$\)/
 contained
+syn match groffPreprocessor 
/[^A-Z]\zs\(G1\s*$\|G2\s*$\|IS\s*$\|IE\s*$\|cstart\s*$\|cend\s*$\)/ contained
 
-" String Registers
-syn match momStringReg '\.\$[A-Za-z][_0-9A-Za-z]*'
+" Preprocessor requests for refer
+syn match groffPreprocessor /\(\[\s*$\|\]\s*$\)/ contained
 
-" Strings
-syn region momString start='"' end='"' 
contains=momNoLineBreak,momGreek,momInteger,momFloatEN,momFloatDE,momBracketRegion,momBracketError,momSpecialMove
+" Quoted strings
+syn region momString matchgroup=startRequest start='"\zs' end='"\|$' 
contains=groffNoLineBreak,groffGreek,groffSpecialChar,momInteger,momFloatEN,momFloatDE,momBracketRegion,momBracketError,momSpecialMove
 contained
 
 " Special characters
-syn match momSpecialChar '\\([-+A-Za-z0-9*<>=~!]\+'
+syn match groffSpecialChar '\\\((\|\[\)[-+A-Za-z0-9*<>=~!\/]\+\]*'
 
 " Greek symbols
-syn match momGreek '\\(\*[A-Za-z]\+'
+syn match groffGreek '\\(\*[A-Za-z]\+'
 
 " Hyphenation marks
-syn match momHyphenation '\\%'
+syn match groffHyphenation '\\%'
 
 " Masking of line breaks
-syn match momNoLineBreak '\\\s*$'
+syn match groffNoLineBreak /\\\s*$/ contains=groffBraces
 
-" Numbers (with optional units)
-syn match momInteger '[-+]\=[0-9]\+[iPpv]\='
-syn match momFloatEN '[-+]\=[0-9]*\.[0-9]\+[iPpv]\='
-syn match momFloatDE '[-+]\=[0-9]\+,[0-9]\+'
-
-" Mom Macros
-syn match momKeyword '\(^\|\s\+\)\.[A-Za-z][_0-9A-Za-z]*'
-syn match momKeywordParam '\(^\|\s\+\)\.[A-Za-z][_0-9A-Za-z]*\s\+[^-\\"]\+' 
contains=momInteger,momFloatEN,momString,momSpecialParam
-syn keyword momSpecialParam contained ON OFF T H C R I B L J N QUAD CLEAR 
NAMED DRAFT FINAL DEFAULT TYPESET TYPEWRITE CHAPTER BLOCK
-
-" Brackets
-syn match momBrackets '[[]]'
-syn match momBracketError '\]'
-syn region momBracketRegion transparent matchgroup=Delimiter start='\[' 
matchgroup=Delimiter end='\]' contains=ALLBUT,momBracketError
-
-" Special movements, e.g. \*[BU<#>] or \*[BP<#>]
-syn region momSpecialMove matchgroup=Delimiter start='\\\*\[' 
matchgroup=Delimiter end='\]' contains=ALLBUT,momBracketError
-
-" Quotes
-syn region momQuote matchgroup=momKeyword start='\<\.QUOTE\>' 
matchgroup=momKeyword end='\<\.QUOTE\s\+OFF\>' skip='$' contains=ALL
-syn region momBlockQuote matchgroup=momKeyword start='\<\.BLOCKQUOTE\>' 
matchgroup=momKeyword end='\<\.BLOCKQUOTE\s\+OFF\>' skip='$' contains=ALL
-syn keyword momBreakQuote .BREAK_QUOTE'
-
-" Footnotes
-syn region momFootnote matchgroup=momKeyword start='\<\.FOOTNOTE\>' 
matchgroup=momKeyword end='\<\.FOOTNOTE\s\+OFF\>' skip='$' contains=ALL
-
-" Comments
-syn region momCommentLine start='\(\\!\)\|\(\\"\)\|\(\\#\)' end='$' 
contains=momTodo
-syn region momCommentRegion matchgroup=momKeyword 
start='\<\.\(COMMENT\)\|\(SILENT\)\>' matchgroup=momKeyword 
end='\<\.\(COMMENT\s\+OFF\)\|\(SILENT\s\+OFF\)\>' skip='$'
+" groff number and string register delimiters
+syn region groffDelimiter start=/\\*\\\(n+*\|\*\)\((\|\[\)\</ 
end=/\(\s\|\]\|$\)/ contains=momRegister,groffRegister,groffOperators
+
+" groff registers
+syn match groffRegister /\\\((\|\[\)\zs\.*[a-z]\+/
+
+" groff operators
+syn match groffOperators /\(+\|-\|\/\|\*[^[]\)/ contained
+
+" Units (of measure)
+syn match groffUnit '[-+]\=\([0-9]\|]\)\+\zs[icPpvusfz]\=' contained
+
+" Braces
+syn match groffBraces /\(\\{\|\\}\)/ contained
+
+" Error
+syn match groffError '\\\[ \+[[:print:]]\+ \+[[:print:]]\+\]'
 
-" Define the default highlighting.
 " For version 5.7 and earlier: only when not done already
 " For version 5.8 and later: only when an item doesn't have highlighting yet
 if version >= 508 || !exists("did_mom_syn_inits")
@@ -108,40 +112,27 @@
                command -nargs=+ HiLink hi def link <args>
        endif
 
-       " The default methods for highlighting. Can be overrriden later.
-       HiLink momTodo Todo
-       HiLink momDefine Define
-       HiLink momPreprocessor PreProc
-       HiLink momNumberReg Special
-       HiLink momStringReg Special
-       HiLink momCommentLine Comment
-       HiLink momCommentRegion Comment
-       HiLink momInteger Number
-       HiLink momFloatEN Number
-       HiLink momFloatDE Number
-       HiLink momString String
-       HiLink momHyphenation Tag
-       HiLink momNoLineBreak Special
-       HiLink momKeyword Keyword
-       HiLink momSpecialParam Special
-       HiLink momKeywordParam Keyword
-
-       HiLink momBracketError Error
-       HiLink momBrackets Delimiter
-
-       hi momNormal term=none cterm=none gui=none
-       hi momItalic term=italic cterm=italic gui=italic
-       hi momBoldItalic term=bold,italic cterm=bold,italic gui=bold,italic
-       HiLink momGreek momBoldItalic
-       HiLink momSpecialChar momItalic
-       HiLink momSpecialMove momBoldItalic
-       
-       HiLink momQuote momBoldItalic
-       HiLink momBlockQuote momBoldItalic
-       HiLink momBreakQuote momNormal
-       
-       HiLink momFootnote momItalic
-       
+HiLink groffError               Error
+HiLink groffBraces              darkmagenta
+HiLink groffCommentLine                darkcyan
+HiLink groffCommentRegion      cyan
+HiLink groffDelimiter          cyan
+HiLink groffGreek              cyan
+HiLink groffHyphenation                cyan
+HiLink groffNoLineBreak                cyan
+HiLink groffOperators          white
+HiLink groffPreprocessor       brown
+HiLink groffRegister           darkgreen
+HiLink groffRequest            magenta
+HiLink groffSpecialChar                darkcyan
+HiLink groffUnit               brown
+HiLink momCommentRegion                darkcyan
+HiLink momMacro                        red
+HiLink momRegister             green
+HiLink momRegisterStart         magenta
+HiLink momSpecialParam         red
+HiLink momString               white
+HiLink startRequest            yellow
        delcommand HiLink
 endif
 

Index: examples/sample_docs.mom
===================================================================
RCS file: /sources/groff/groff/contrib/mom/examples/sample_docs.mom,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- examples/sample_docs.mom    3 Oct 2010 23:26:29 -0000       1.6
+++ examples/sample_docs.mom    31 Aug 2012 22:49:58 -0000      1.7
@@ -1,4 +1,4 @@
-\# Copyright 2004, 2005, 2006, 2009
+\# Copyright 2004, 2005, 2006, 2009, 2010, 2011, 2012
 \# Free Software Foundation, Inc.
 \#
 \# Copying and distribution of this file, with or without modification,
@@ -21,46 +21,56 @@
 \#
 \# The PRINTSTYLE is TYPESET.  If you'd like to see what mom does
 \# with the documents when the PRINTSTYLE is TYPEWRITE, change
-\# PRINTSTYLE TYPESET, below, to PRINTSTYLE TYPEWRITE.  Also, in the
-\# third example, comment out PARA_INDENT and QUOTE_INDENT (lines
-\# 332 and 333).
+\# PRINTSTYLE TYPESET, below, to PRINTSTYLE TYPEWRITE and re-run with
+\#
+\#  pdfmom -Tps sample_docs.mom > sample_docs.pdf 
 \#
 \# ===================================================================
 \#
-\# First, a sample "NAMED" document--in this case, an outline.
-\# A novelist wouldn't normally write an outline with numbered heads,
+\# First, a sample NAMED document--in this case, an outline.
+\# A novelist wouldn't normally write an outline with numbered
 \# subheads and paraheads.  I've turned the feature on merely to
 \# demonstrate it.
 \#
-\# Reference macros
+\# Reference macros (metadata)
 \#
 .TITLE     "Lake Attica's Shores"
 .SUBTITLE  "A Romance Novel"
 .AUTHOR    "Rosemary Winspeare"
-.DRAFT      1  \" Ignored because COPYSTYLE is FINAL
-.REVISION   2  \" Ignored because COPYSTYLE is FINAL
-.COPYRIGHT "2004 Alma Podborski
+.COPYRIGHT "2004 Alma Podborski"
+.PDF_TITLE "Sample mom documents"
 \#
-\# Reference macros for the document cover
+\# Additional information, for the cover
 \#
 .DOC_COVERTITLE "Sample mom Documents"
 .MISC "Three types of mom documents" "assembled and collated by mom's author"
 \#
-\# Docstyle macros
+\# Docstyle macros (templates)
 \#
 .DOCTYPE    NAMED "Outline"
 .PRINTSTYLE TYPESET \" Or TYPEWRITE to preview "typewritten, double-spaced"
+.PAPER      LETTER
+\#
+\# What to put on the cover and first title page
 \#
-.DOC_COVER COVERTITLE MISC
+.DOC_COVER DOC_COVERTITLE MISC 
 .COVER     TITLE AUTHOR DOCTYPE COPYRIGHT
 \#
-\# Additional setup macros
+\# Style for nested heading levels
+\#
+\# The first two instances of level-1 headings will be paragraph heads
+\# so we set the paragraph head style here, then change it when
+\# level-1 headings become main heads.
 \#
-.NUMBER_PARAHEADS
+.HEADING_STYLE 1 FONT BI SIZE +.25
+.HEADING_STYLE 2 FONT B SIZE +.5 BASELINE_ADJUST \n[.v]/8 \" ie 1/8 the leading
+\#
+.AUTO_RELOCATE_TOC
+.SPACE_TOC_ITEMS
 \#
 .START
 .PP
-.PARAHEAD "A note on the setting"
+.HEADING 1 PARAHEAD "A note on the setting"
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam
 nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna ali\%quyam erat,
 sed diam voluptua. Stet clita kasd gubergren, no sea takimata sanctus est.
@@ -77,7 +87,7 @@
 sadipscing elitr, sed diam nonumy.
 .LINEBREAK
 .PP
-.PARAHEAD "About historical personnages"
+.HEADING 1 PARAHEAD "About historical personnages"
 At vero eos et accusam et justo duo do\%lo\%res et ea rebum.  Stet clita
 kasd gubergren, no sea takimata sanctus est.  Tempor invidunt ut
 labore et do\%lo\%re magna ali\%quyam erat, sed diam voluptua.
@@ -87,10 +97,15 @@
 sed diam voluptua.  Consetetur sadipscing elitr, sed diam nonumy
 eirmod tempor invidunt ut labore et do\%lo\%re magna.  Tempor invidunt
 ut labore et do\%lo\%re magna ali\%quyam erat, sed diam voluptua.
-.NUMBER_HEADS
-.NUMBER_SUBHEADS
-.HEAD "Part One"
-.SUBHEAD "Chapter 1"
+\#
+\# Change level-1 style and add numbering to levels 1 and 2
+\#
+.HEADING_STYLE 1 FONT B SIZE +1.5 CAPS UNDERSCORE .5 2p QUAD C \
+  NO_SPACE_AFTER BASELINE_ADJUST +0 NUMBER
+.HEADING_STYLE 2 NUMBER
+\#
+.HEADING 1 "Part One"
+.HEADING 2 "Chapter 1"
 .PP
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
 sed diam nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna
@@ -102,7 +117,7 @@
 amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor
 invidunt ut labore et do\%lo\%re magna ali\%quyam erat, sed diam voluptua.
 Stet clita kasd gubergren, no sea takimata sanctus est.
-.SUBHEAD "Chapter 2"
+.HEADING 2 "Chapter 2"
 .PP
 Stet clita kasd gubergren, no sea takimata sanctus est.  Lorem ipsum
 dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod
@@ -112,7 +127,7 @@
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
 sed diam nonumy eirmod tempor invidunt.  Ut labore et do\%lo\%re magna
 ali\%quyam erat, sed diam voluptua at vero.
-.SUBHEAD "Chapter 3"
+.HEADING 2 "Chapter 3"
 .PP
 Eos et accusam et justo duo do\%lo\%res et ea rebum.  Stet clita kasd
 gubergren, no sea takimata sanctus est lorem ipsum dolor sit amet.
@@ -120,8 +135,8 @@
 nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna ali\%quyam erat,
 sed diam voluptua.  At vero eos et accusam et justo duo do\%lo\%res et
 ea rebum.
-.HEAD "Part Two"
-.SUBHEAD "Chapter 4"
+.HEADING 1 "Part Two"
+.HEADING 2 "Chapter 4"
 .PP
 Stet clita kasd gubergren, no sea takimata sanctus est
 lorem ipsum dolor sit amet.  Lorem ipsum dolor sit amet, consetetur
@@ -139,7 +154,7 @@
 duo do\%lo\%res et ea rebum.  Stet clita kasd gubergren, no sea takimata
 sanctus est lorem ipsum dolor sit amet.  Consetetur sadipscing elitr,
 sed diam nonumy eirmod tempor invidunt. 
-.SUBHEAD "Chapter 5"
+.HEADING 2 "Chapter 5"
 .PP
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed
 diam nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna
@@ -168,10 +183,7 @@
 \# has already deposited one there, COLLATE can't undo it.
 \#
 \# Normally, this isn't necessary; here we require it because the
-\# line falls right at the bottom of the page, and would therefore
-\# normally spring the page trap.  Sorry for the fussiness, but at
-\# least now you know what to do if you ever encounter the problem
-\# of a page header printing at the top of a collated document.
+\# line falls right at the bottom of the page.
 \#
 \# Please notice, too, the use of "\&" before "..."  Whenever an
 \# input line begins with either a period, an apostrophe or a space,
@@ -181,15 +193,13 @@
 \#
 \# =====================================================================
 \#
-\# Next, two pages of a chapter, set in DRAFT style, showing
-\# the use of the EPIGRAPH BLOCK macro and the QUOTE macro.
+\# Next, two pages of a chapter, set in DRAFT style, showing the use
+\# of the EPIGRAPH BLOCK macro and the QUOTE macro.
 \#
 \# You'll notice that the starting page number of this "draft" is 1 (in
 \# roman numerals).  COPYSTYLE DRAFT always numbers the first page of a
 \# document 1.
 \#
-\# Reference macros
-\#
 .TITLE         "Lake Attica's Shores"
 .SUBTITLE      "A Romance Novel"
 .AUTHOR        "Rosemary Winspeare"
@@ -199,17 +209,14 @@
 .REVISION       2
 .MISC          "Draft 1, 2nd revision"
 \#
-\# Docstyle macros
-\#
 .DOCTYPE    CHAPTER
 .COPYSTYLE  DRAFT
 \#
-\# Additional style macros
-\#
 .EPIGRAPH_FONT I       \" Epigraphs are normally set in roman
 .DRAFT_WITH_PAGENUMBER \" Draft/revision info usually goes in the header
-.COVER_MISC_QUAD RIGHT \" Change default position of the cover "misc" line
 \#
+.COVER_MISC_FAMILY H
+.COVER_MISC_QUAD  RIGHT
 .COVER CHAPTER+TITLE MISC
 \#
 .START
@@ -218,7 +225,12 @@
 nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna ali\%quyam erat,
 sed diam voluptua.
 .RIGHT
-\*[ROM]\(emJoseph E. Blough
+\#
+\# If running PRINTSTYLE TYPEWRITE, add space before citation
+\#
+.if \n[#PRINT_STYLE]=1 .sp
+\#
+\*[ROM]\[em]Joseph E. Blough
 .EPIGRAPH OFF
 .PP
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam
@@ -289,23 +301,22 @@
 no sea takimata sanctus est.  At vero eos et accusam et justo duo
 do\%lo\%res et ea rebum.
 .RIGHT
-\*[BD]\&...end of sample chapter
+\*[BD]\&...end of sample chapter\c
+.EL
 .COLLATE
 \#
 \# =====================================================================
 \#
-\# Finally, a sample academic article, set in two columns with a
+\# Finally, a sample journal article, set in two columns with a
 \# 1.5-pica gutter between them.  This example also uses QUOTES,
 \# BLOCKQUOTES and FOOTNOTES. In addition, it's set RECTO_VERSO,
 \# with differing left and right margins that alternate from page to
 \# page.  (The header also flips from right to left, which you can
 \# see on the 2nd and 3rd pages).
 \#
-\# In order to accomodate the narrow measure of the columns, there's also
-\# a demonstration of things you can change with both the typesetting
-\# macros and the document processing "control" macros.
-\#
-\# Reference macros
+\# The primary purpose of this sample is to demonstrate how to
+\# create a stylesheet, along with some of the control macros that
+\# can be used.
 \#
 .TITLE     "CONTROL EQUALS CHAOS"
 .SUBTITLE  "\*[ALD1]The Psychological and Auditory \
@@ -314,38 +325,53 @@
 .COPYRIGHT "2004 J. Chang, B.H. Connors
 .MISC      "Submitted June 3, 2004" "\*[IT]Piano Quarterly\*[PREV]"
 \#
-\# Docstyle macros
-\#
 .DOCTYPE    DEFAULT
 .COPYSTYLE  FINAL
 \#
-\# Additional style macros -- general type parameters
-\#
 .L_MARGIN     6P
 .R_MARGIN     4P+6p
 .PT_SIZE      10
 .AUTOLEAD     1.5
 \#
-\# Additional style macros -- change mom's default behaviour
+.AUTHOR_SIZE   +.5
+.SUBTITLE_SIZE +1
 \#
 .RECTO_VERSO
 .PAGENUM           1
+\#
 .HEADER_LEFT      "Chang, Connors"  \" Because we have two authors
-.COLUMNS           2 1P+6p
-.SUBTITLE_SIZE     +1.5
-.AUTHOR_SIZE       +.5
-.DOCHEADER_LEAD    +2p
 .HEADER_SIZE       +1
-.PARA_INDENT       1P \" Comment this out if previewing PRINTSTYLE TYPEWRITE
-.QUOTE_INDENT      2  \" Comment this out if previewing PRINTSTYLE TYPEWRITE
-.SUBHEAD_SIZE      +0
+\#
+.DOCHEADER_ADVANCE 1.75i
+.DOCHEADER_LEAD    +2p
+\#
+\# When PRINTSTYLE is TYPESET, these indents need to be smaller than
+\# the default
+\#
+.if \n[#PRINT_STYLE]=2 \{\
+. PARA_INDENT  1P
+. QUOTE_INDENT 2
+.\}
+\#
+.HEADING_STYLE 1 QUAD L SIZE +0 NO_NUMBER NO_CAPS NO_UNDERSCORE \
+  NO_SPACE_AFTER BASELINE_ADJUST \n[.v]/8 \" ie 1/8 of the leading
+\#
 .BLOCKQUOTE_FAMILY H
 .BLOCKQUOTE_SIZE   -2
-.NUMBER_HEADS      OFF  \" Because we turned them on in the first example
-.NUMBER_SUBHEADS   OFF  \" Ibid
+.BLOCKQUOTE_AUTOLEAD 2
+\#
+.COVERTITLE "\*[UP 3p]\E*[$TITLE]" \" Use $TITLE, but raise 3 points
+\#
+.COVER_LEAD           +2
+.COVER_AUTHOR_SIZE    +1.5
+.COVER_MISC_FAMILY    T
+.COVER_MISC_QUAD      L
+.COVER_MISC_SIZE      +0
+.COVER_COPYRIGHT_SIZE +0
 \#
-.COVER_MISC_QUAD   L    \" Because we set it to R earlier
-.COVER TITLE AUTHOR COPYRIGHT MISC
+.COVER COVERTITLE AUTHOR COPYRIGHT MISC
+\#
+.COLUMNS 2 1P+6p
 \#
 .START
 .PP
@@ -390,7 +416,7 @@
 magna ali\%quyam erat, sed diam voluptua.  At vero eos et accusam et
 justo duo do\%lo\%res et ea rebum.  Stet clita kasd gubergren no sea.
 \#
-.SUBHEAD "Schoenberg\(em" "The Origins of Serial Pitch Organization"
+.HEADING 1 "Schoenberg \[em]" "The Origins of Serial Pitch Organization"
 \#
 .PP
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam
@@ -409,7 +435,7 @@
 Amet consetetur sadipscing elitr sed diam nonumy eirmod.  Tempor
 invidunt ut labore.  Et dolor\%e magna ali\%quyam erat, sed diam voluptua,
 at vero.  Eos et accusam et justo duo do\%lo\%res et ea rebum.  Stet clita
-kasd gubergren.
+kasd gubergren sed diam voluptua.
 .PP
 No sea takimata\c
 .FOOTNOTE
@@ -422,22 +448,24 @@
 accusam et justo duo do\%lo\%res et ea rebum amet.  Consetetur sadipscing
 elitr sed diam nonumy eirmod tempor invidunt ut labore, et do\%lo\%re
 magna ali\%quyam erat.  Sed diam voluptua, at vero, eos et accusam et
-justo duo do\%lo\%res et ea rebum.
+justo duo do\%lo\%res et ea rebum qua certiore.
 \#
-.SUBHEAD "Messiaen to Stockhausen\(em" "The Quest for Absolute Control"
+.HEADING 1 "Messiaen to Stockhausen \[em]" "The Quest for Absolute Control"
 \#
 .PP
 Vero eos et accusam et justo duo do\%lo\%res et ea rebum amet:
+\#
 .QUOTE
 Eirmod tempor invidunt
 Ut labore et do\%lo\%re magna ali\%quyam erat
 Sed diam voluptua
 At vero eos et accusam et justo duo do\%lo\%res.
 .QUOTE OFF
+\#
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr
 sed diam.  Nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna.
 Aliquyam erat, sed diam voluptua at vero eos et accusam.  Et
-justo duo do\%lo\%res et ea rebum stet.
+justo duo do\%lo\%res et rebum.
 .PP
 Elitr sed diam nonumy eirmod tempor.  Invidunt ut labore et do\%lo\%re
 magna ali\%quyam erat sed.  Diam voluptua at vero eos et accusam et
@@ -470,7 +498,7 @@
 At vero eos et accusam et justo duo do\%lo\%res et ea rebum.
 Stet clita kasd gubergren no sea.  Ali\%quyam erat, sed diam voluptua.
 \#
-.SUBHEAD "John Cage\(em" "Leaving It All to Chance"
+.HEADING 1 "John Cage \[em]" "Leaving It All to Chance"
 \#
 .PP
 Sit amet, consetetur sadipscing elitr, sed diam nonumy.  Eirmod tempor
@@ -507,12 +535,6 @@
 voluptua at vero eos et accusam.  Et justo duo do\%lo\%res et ea rebum,
 stet clita kasd gubergren, no sea takimata.
 .PP
-Sanctus est lorem ipsum.  Dolor sit amet consetetur sadipscing
-elitr.  Sed diam nonumy eirmod tempor invidunt ut labore.  Et
-do\%lo\%re magna ali\%quyam erat, sed diam voluptua.  At vero eos et
-accusam et justo duo.  Dolores et ea rebum stet clita kasd gubergren
-no sea.
-.PP
 Takimata lorem ipsum dolor sit amet consetetur sadipscing elitr.
 Sed diam, nonumy eirmod tempor, invidunt ut labore et do\%lo\%re magna.
 Aliquyam erat sed diam voluptua.  At vero eos et accusam et
@@ -535,7 +557,7 @@
 accusam et justo duo dolores et ea rebum.  Stet clita kasd gubergren,
 no sea takimata sanctus est.
 \#
-.SUBHEAD "Beyond Cage\(em" "Catching the Midnight Train"
+.HEADING 1 "Beyond Cage \[em]" "Catching the Midnight Train"
 \#
 .PP
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr.  Sed diam
@@ -580,3 +602,5 @@
 .RIGHT
 \*[BD]\&...end of sample article\*[PREV]
 .FINIS
+.TOC_RV_SWITCH
+.TOC

Index: examples/typesetting.mom
===================================================================
RCS file: /sources/groff/groff/contrib/mom/examples/typesetting.mom,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- examples/typesetting.mom    5 Jan 2009 20:10:48 -0000       1.3
+++ examples/typesetting.mom    31 Aug 2012 22:49:58 -0000      1.4
@@ -1,4 +1,4 @@
-\# Copyright 2004, 2005, 2006, 2009
+\# Copyright 2004, 2005, 2006, 2009, 2010, 2011, 2012
 \# Free Software Foundation, Inc.
 \#
 \# Copying and distribution of this file, with or without modification,
@@ -8,16 +8,14 @@
 \# Most mom users rely on mom's document processing macros to format
 \# their work.  The doc processing macros take care of all things
 \# typographic and are simple, clear and easy to learn.  The kind of
-\# "by hand" typesetting this file shows off is really geared toward
+\# "by hand" typesetting this file demonstrates is geared towards
 \# professional typographers.  Bear in mind, though, that the full
-\# power of mom's typesetting capabilities can be brought to bear
-\# on document processing as well.
+\# power of mom's typesetting capabilities can be brought to bear on
+\# document processing as well.
 \#
 \# Basic page setup
 \#
-.PAGE 8.5i 11i \" Printer sheet size
-.L_MARGIN 1i   \" Left margin 1 inch
-.R_MARGIN 1i   \" Right margin 1 inch (calculates the line length)
+.PAGE 8.5i 11i 1i 1i 1i \" Page size, margins
 \#
 \# Basic type parameters
 \#
@@ -35,7 +33,7 @@
 .SMARTQUOTES   \" Enable smartquotes
 .SS 0          \" No extra space between sentences
 \#
-.ALD 1i-1v     \" Advance 1 inch from top of paper to first baseline
+.SP |1i-1v     \" Advance 1 inch from top of paper to first baseline
 Example 1\*[BU 2]:
 .ALD .25v      \" Advance an extra 1/4 linespace
 .UNDERSCORE 3.75p "T\*[BU 4]asting notes using padding, string tabs \
@@ -52,12 +50,14 @@
 \# the full line length.
 \# 
 .SILENT        \" Don't print the next line
-.PAD "\*[ST1]VIN#\*[ST1X]\*[FWD 1P]\*[ST2]ROBE#\*[ST2X]\*[FWD 
1P]\*[ST3]NEZ#\*[ST3X]\*[FWD 1P]\*[ST4]BOUCHE#\*[ST4X]\*[FWD 
1P]\*[ST5]COMMENTAIRES\*[ST5X]"
+.PAD "\*[ST1]VIN#\*[ST1X]\*[FWD 1P]\*[ST2]ROBE#\*[ST2X]\
+\*[FWD 1P]\*[ST3]NEZ#\*[ST3X]\*[FWD 1P]\*[ST4]BOUCHE#\*[ST4X]\
+\*[FWD 1P]\*[ST5]COMMENTAIRES\*[ST5X]"
 .SILENT OFF    \" Resume normal printing of text
 \#
 \# Now that the string tabs have been marked off, we "set" them.
 \#
-.ST 1 L        \" First string tab flush left, nofill mode (no need for .BR's 
between input lines)
+.ST 1 L        \" First string tab flush left, nofill (line-for-line) mode
 .ST 2 L QUAD   \" Remaining tabs are flush left/rag right, fill mode
 .ST 3 L QUAD
 .ST 4 L QUAD
@@ -150,18 +150,18 @@
 \#
 .IL \w'*'+2p   
 \#
-\# Now, set the hanging indent equal to the left indent, effectively pulling
-\# the first line of the following text back to the new left margin.
-\# Subsequent output lines will be indented by the .IL amount.
-\# Notice that when using the \w inline escape, there's no need to append
-\# a unit of measure to it.
+\# Now, set the hanging indent equal to the left indent, effectively
+\# pulling the first line of the following text back to the new left
+\# margin.  Subsequent output lines will be indented by the .IL
+\# amount.  Notice that when using the \w inline escape, there's no
+\# need to append a unit of measure.
 \#
 .HI \w'*'+2p
 *\*[FWD 1p]The term "Band-Aid" means the slightly sweet, vaguely chemical
 smell associated with medical-grade plastics.  It is often found in
 wines from terroirs in South America.  Provided a wine has a sufficient
 concentration of fruit
-.RW .04   \" Kern the whole next line slightly, so "lipstick" doesn't 
hyphenate.
+.RW .04   \" Tighten the next line slightly, so "lipstick" doesn't hyphenate.
 aromas and complex tertiary characteristics, Band-Aid is a Good Thing.
 Otherwise, it smells like cheap lipstick.
 .RW 0     \" Reset kerning to 0
@@ -186,14 +186,14 @@
 Example 2:
 .ALD .25v
 \#
-.COMMENT       \" COMMENT lets you enter comments without using \# or \"
+.COMMENT
 In the next line, because the string to be underscored must be
 enclosed in double-quotes, you can't use the double-quote character
 itself around the word "Massaging".  We circumvent this by using the
-groff inline escapes \(lq and \(rq (leftquote and rightquote).
-.COMMENT OFF   \" Remember to turn COMMENT off!
+groff inline escapes \[lq] and \[rq] (leftquote and rightquote).
+.COMMENT OFF
 \#
-.UNDERSCORE 3.75p "\(lqMassaging\(rq \*[BCK 1p]a passage of rag right text"
+.UNDERSCORE 3.75p "\[lq]Massaging\[rq] \*[BCK 1p]a passage of rag right text"
 .SP            \" Add an extra linespace
 \#
 .PT_SIZE 12.5
@@ -211,7 +211,7 @@
 but when he ventured upon insult, I vowed revenge.  You, who so well
 know the nature of my soul, will not suppose, however, that I gave
 utterance to a threat.  \*[IT]At length\*[PREV] I would be
-avenged; this was a point definitively settled\(embut the very
+avenged; this was a point definitively settled\[em]but the very
 definitiveness with which it was resolved, precluded the idea of
 risk.  I must not only punish, but punish with impunity.  A
 wrong is unredressed when retribution overtakes its redresser.
@@ -223,7 +223,7 @@
 \# than the preceding text (using the \*[SIZE <n>] inline escape.
 \#
 .RIGHT
-\*[SIZE -.5]\(emEdgar Allen Poe, \*[IT]The Cask of Amontillado\*[PREV]\*[SIZE 
+.5]
+\*[SIZE -.5]\[em]Edgar Allen Poe, \*[IT]The Cask of Amontillado\*[PREV]\*[SIZE 
+.5]
 .SP            \" Extra linespace
 .IBQ           \" Disable "indent both"
 \#
@@ -244,7 +244,7 @@
 .FT       B
 .PT_SIZE -1
 .LEFT
-The same passage, \*[BU 4]"massaged"
+The same passage, \*[BU4]"massaged"
 \#
 .ALD .5v
 \#
@@ -252,40 +252,40 @@
 .PT_SIZE +1 
 .QUAD     LEFT
 .HY OFF           \" Turn automatic hyphenation off
-.BR_AT_LINE_KERN  \" Automatically insert a line break (.BR) with each 
invocation of .RW and .EW 
+.BR_AT_LINE_KERN  \" Automatically insert a line break (.BR) at each .RW and 
.EW 
 .WS +1            \" Increase word space slightly
 .IB               \" Turn "indent both" back on; values are the same as before
 \#
-The thousand injuries of Fortunato I had borne as I best could; but
-when he ventured upon insult, I \*[BU 2]vowed revenge.  \*[BU 4]Y\*[BU 6]ou,
-\*[BU 4]who so \*[BU 2]well know the nature
+The thousand injuries of Fortunato I had borne as I best could;
+but when he ventured upon insult, I \*[BU2]vowed revenge.
+\*[BU4]Y\*[BU6]ou, \*[BU4]who so \*[BU2]well know the nature
 .EW .2
-of my soul, \*[BU 2]will not suppose, however, that I gave utterance to
-a threat.  \*[IT]At
+of my soul, \*[BU2]will not suppose, however, that I gave utterance
+to a threat.  \*[IT]At
 .EW .2
 length\*[PREV] I would be avenged; this was a point definitively
-settled\(embut the
+settled\[em]but the
 .EW .2
-v\*[BU 1]ery definitiveness with which it was resolved, precluded the idea
-of risk.
+v\*[BU1]ery definitiveness with which it was resolved, precluded the
+idea of risk.
 .EW 0
-I must not only punish, but punish with impunity.  A \*[BCK 1p]wrong is
-unredressed
+I must not only punish, but punish with impunity.  A \*[BCK 1p]wrong
+is unredressed
 .EW .1
 when retribution overtakes its redresser.  It is equally unredressed
 when the
 .RW .1
-avenger fails to make himself felt as such to him \*[BU 2]who has done
-the wrong.
+avenger fails to make himself felt as such to him \*[BU 2]who has
+done the wrong.
 .RW  0         \" Restore normal kerning
 .WS  +0        \" Restore normal wordspacing
 .ALD 6p
 .PT_SIZE -.5
 .RIGHT
-\*[UP 1.5p]\(em\*[DOWN 1.5p]\*[BCK 1p]Edgar \*[BCK 1p]Allen Poe, \*[IT]The 
Cask of Amontillado\*[PREV]
+\*[UP 1.5p]\[em]\*[DOWN 1.5p]\*[BCK 1p]Edgar \*[BCK 1p]Allen Poe, \
+\*[IT]The Cask of Amontillado\*[PREV]
 .IQ CLEAR      \" Cancel and clear stored values of all indents
 \#
-\#
 .NEWPAGE       \" Start a new page
 .T_MARGIN 1i   \" Set top margin to 1i (approx. equivalent to .ALD 1i-1v above)
 \#
@@ -297,7 +297,7 @@
 \#
 Example 3:
 .ALD .25v
-.UNDERSCORE 3.75p "A \*[BU 2]recipe for enumerated lists using indents"
+.UNDERSCORE 3.75p "A \*[BU2]recipe for enumerated lists using indents"
 .SP .5v        \" Add an extra half line space
 .FAM      N    \" New Century Schoolbook family
 .FT       R
@@ -309,72 +309,76 @@
 simple enumerated lists.  Nested lists are possible, as the example
 shows; however, the more complex the nesting, the wiser it becomes
 to use (string) tabs, as seen in Example 4.
-.TI 1.5m
+.RLD .5v                  \" Move upwards 1/2 linespace
+.DBX .5 0 \n[.l]u 2P+9p   \" Draw box; \n[.l]u means "the current line length"
+.IB 6p                    \" Indent from both left and right margins
+.ALD 14p
 \*[BD]Please note: mom\*[PREV] has macros that allow you to set
 enumerated lists automatically.  These examples merely show hanging
 indents and string tabs in use.
 \#
+.ALD 6p
 .JUSTIFY       \" Justify text
-.IL \w'\0.\0'  \" Establish a left indent equal to the width of 2 figure 
spaces plus a period.
-.HI \w'\0.\0'  \" Establish a hanging indent equal to the size of the left 
indent.
+.IL \w'\0.\0'  \" Establish a left indent equal to 2 figure spaces plus a 
period.
+.HI \w'\0.\0'  \" Establish a hanging indent equal to the left indent.
 .ALD 6p
 \#
 \#
-1.\0This is the first item in the list.  N\*[BU 2]otice how the first line
+1.\0This is the first item in the list.  N\*[BU2]otice how the first line
 "hangs" back from the remaining text, which is otherwise
 indented by the width of by two figure-spaces (digit-width
 spaces) and a period.
 .BR
-.HI            \" Notice that HI doesn't require an argument once the value's 
been set
+.HI            \" Notice that HI doesn't require an argument once the value's 
set
 .ALD 6p
 2.\0This is the second item in the list.  As with the above item,
-notice the use of the \*[BU 8]\\0 escape sequence in the input text.  It's
-there to ensure that the space after the number/period combination
-always remains the same (i.e. doesn't stretch when the line is
-justified).  That way, the text of each item always lines up perfectly.
+notice the use of the \*[BU8]\\0 escape sequence in the input
+text.  It's there to ensure that the space after the number/period
+combination always remains the same (i.e. doesn't stretch when the
+line is justified).  That way, the text of each item always lines up
+perfectly.
 \#
 .COMMENT
 Now we're going to set a bullet-point list, indented from the text
 above by 1 pica.  IL arguments are always added to whatever value
 is in already effect for IL, hence all we have to do is tell mom to
 indent (from the current left indent) 1 pica plus the width of the
-bullet character ( \(bu ).  \*[FWD 3p] puts three points of space after
+bullet character, \[bu].  \*[FWD 3p] puts three points of space after
 the bullet so that the bullet and the text are visually separated.
 .COMMENT OFF
 \#
 \#
-.IL 1P+\w'\(bu\*[FWD 3p]'
+.IL 1P+\w'\[bu]\*[FWD 3p]'
 \#
 \# Hanging indents are always relative to the current left indent.
 \# The additional 1-pica indent, above, already having been taken
-\# care of, we only want to hang the first lines of bullet list items
-\# back by the width of the bullet character plus its 3 extra
+\# care of, we only want to hang the first lines of bullet list
+\# items back by the width of the bullet character plus its 3 extra
 \# points of space.
 \#
 .ALD 6p
-.HI \w'\(bu\*[FWD 3p]'
-\*[DOWN 1p]\(bu\*[UP 1p]\*[FWD 3p]This is the first line of a sublist with 
bullets.
-N\*[BU 2]otice how the first line (the one with the bullet) is indented
-exactly one pica from the text of the list item above it, while the
-remaining lines align with the left indent we set above.
+.HI \w'\[bu]\*[FWD 3p]'
+\*[DOWN 1p]\[bu]\*[UP 1p]\*[FWD 3p]This is the first line of a
+sublist with bullets.  N\*[BU2]otice how the first line (the one
+with the bullet) is indented exactly one pica from the text of the
+list item above it, while the remaining lines align with the left
+indent we set above.
 .ALD 6p
 .HI
-\*[DOWN 1p]\(bu\*[UP 1p]\*[FWD 3p]This is the second item of the sublist with 
bullets.  \*[BU 4]We
-could go on indefinitely, but let's go back to the top level (numbered)
-list...
-\#
-\# The easiest way to return to a previous indent value is by subtraction.
-\# The argument to IL, above, was 1P+\w'\(bu\*[FWD 3p]', so we just reverse
-\# it by putting a minus sign in front.  The parentheses are required
-\# for groff to evaluate the expression properly.
+\*[DOWN 1p]\[bu]\*[UP 1p]\*[FWD 3p]This is the second item of the
+sublist with bullets.  \*[BU4]We could go on indefinitely, but let's
+go back to the top level (numbered) list...
+\#
+\# The easiest way to return to a previous indent value is by
+\# subtraction.  The argument to IL, above, was 1P+\w'[bu]\*[FWD
+\# 3p]', so we just reverse it by putting a minus sign in front.
+\# The parentheses are required for groff to evaluate the expression
+\# properly.
 \#
-.IL -(1P+\w'\(bu\*[FWD 3p]')
+.IL -(1P+\w'\[bu]\*[FWD 3p]')
 .HI \w'\0.\0'  \" Reset hanging indent for use with numbered items.
 .ALD 6p
 3.\0...and here we are.
-.HI            \" Again, notice that once HI has been set, you don't have to 
keep passing it an argument.
-.ALD 6p
-4.\0In order not to make the example too long, we'll stop here.
 .IQ CLEAR      \" Don't forget to cancel and/or clear indents!
 \#
 .FAM T
@@ -394,13 +398,14 @@
 .LS  13
 .JUSTIFY
 Although setting up string tabs is a bit more complex than setting
-up indents, it's \*[BU 3]well worth the effort, especially for nested lists.
+up indents, it's \*[BU 3]well worth the effort, especially for
+nested lists.
 .ALD 6p
 \#
 .COMMENT
-The PAD line, below, sets up two string tabs.  The first (ST1)
-is exactly the length of two figure spaces and a period.  The
-second (ST2) is simply "the remainder of the line."
+The PAD line, below, sets up two string tabs.  The first (ST1) is
+exactly the length of two figure spaces and a period.  The second
+(ST2) is simply "the remainder of the line."
 .COMMENT OFF
 \#
 .SILENT        \" Don't print any of this
@@ -410,19 +415,20 @@
 .SILENT OFF    \" Restore printing
 \#
 .TB 1
-1.
-.TN    \" Use .TN here so text stays on the same baseline as the number in tab 
1
-This is the first item in the list.  N\*[BU 2]otice how, just as in Example 3,
-the first line hangs back from the remaining text, which is otherwise
+1.\c
+.TN    \" Use .TN so text stays on the same baseline
+This is the first item in the list.  N\*[BU 2]otice how, just as in
+Example 3, the first line hangs back from the remaining text, which
+is otherwise
 indented.
 .ALD 6p
 .TB  1
-2.
+2.\c
 .TN
-This is the second item in the list.  N\*[BU 2]otice that when setting "lists"
-with tabs, there's no need to use the \*[BU 8]\\0 escape sequence after
-the number/period combination in the input text.
-.ALD 6p
+This is the second item in the list.  N\*[BU 2]otice that when
+setting "lists" with tabs, there's no need to use the \*[BU 8]\\0
+escape sequence after the number/period combination in the input
+text.
 \#
 .COMMENT
 Now, set up the indented bullet-point sublist.  The PAD line
@@ -433,57 +439,59 @@
 .COMMENT OFF
 \#
 .SILENT
-.PAD "\*[FWD 12p]\*[ST3]\(bu\*[ST3X]\*[FWD 3p]\*[ST4]#\*[ST4X]"
+.PAD "\*[FWD 12p]\*[ST3]\[bu]\*[ST3X]\*[FWD 3p]\*[ST4]#\*[ST4X]"
 .ST 3 L
 .ST 4 J
 .SILENT OFF
 .ALD 6p
 .TB  3
-\*[DOWN 1p]\(bu\*[UP 1p]
+\*[DOWN 1p]\[bu]\*[UP 1p]\c
 .TN
-This is the first line of a sublist with bullets.  N\*[BU 2]otice how the
-bullets and the text line up exactly the same as in Example 3.
+This is the first line of a sublist with bullets.  N\*[BU2]otice
+how the bullets and the text line up exactly the same as in Example
+3.
 .ALD 6p
 .TB  3
-\*[DOWN 1p]\(bu\*[UP 1p]
+\*[DOWN 1p]\[bu]\*[UP 1p]\c
 .TN
 This is the second item of the sublist with bullets.  For the fun of
 it, lets add in an
 .SPREAD
 en-dashed sub-sublist.
-.BR  \" We're in a fill mode right now, so you *must* terminate the line with 
BR
+.BR  \" We're in fill mode right now, so you must terminate the line with BR
 \#
 .SILENT
-.PAD "\*[FWD 12p]\*[ST5]\(en\*[ST5X]\*[FWD 4p]\*[ST6]#\*[ST6X]"
+.PAD "\*[FWD 12p]\*[ST5]\[en]\*[ST5X]\*[FWD 4p]\*[ST6]#\*[ST6X]"
 .ST 5 L
 .ST 6 J
 .SILENT OFF
 .ALD 6p
 .TB  5
-\*[UP .75p]\(en\*[DOWN .75p]
+\*[UP .75p]\[en]\*[DOWN .75p]\c
 .TN
 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam
-nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat,
-sed diam voluptua.
+nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam
+erat, sed diam voluptua.
 .ALD 6p
 .TB  5
-\*[UP .75p]\(en\*[DOWN .75p]
+\*[UP .75p]\[en]\*[DOWN .75p]\c
 .TN
-At \*[BU 3]vero eos et accusam et justo duo dolores et ea rebum.  Stet clita
-kasd gubergren, no sea takimata sanctus est lorem ipsum dolor sit amet.
+At \*[BU 3]vero eos et accusam et justo duo dolores et ea rebum.
+Stet clita kasd gubergren, no sea takimata sanctus est lorem ipsum
+dolor sit amet.
 .ALD 6p
 .TB  1
-3.
+3.\c
 .TN
 And here we are, back at the top-level numbered list with a minimum
 of muss and fuss,
 .ALD 6p
 .TB  1
-4.
+4.\c
 .TN
 Generally speaking, once you get the hang of string tabs and the
-\*[BD]PAD\*[PREV] macro, you'll find setting up complex nested lists
-(or anything similar to them) easier than with hanging indents.
+\*[BD]PAD\*[PREV] macro, you'll find setting up complex indenting
+structures easier than with the indent macros.
 .TQ
 \#
 .NEWPAGE
@@ -501,32 +509,32 @@
 .PT_SIZE 11
 .LS  14
 \#
-\# The "label" lines for the following are set in Helvetica bold, one
-\# point smaller than the examples themselves.  This demonstrates the
-\# use of the groff inline escape \f[...] to change both family and
-\# font inline.  It also shows using the mom inline \*S[...], which is
-\# an alternate form of the inline, \*[SIZE <n>]
+\# The "label" lines for the following are set in Helvetica
+\# bold, one point smaller than the examples themselves.  This
+\# demonstrates the use of the groff inline escape \f[...] to change
+\# both family and font inline.  It also shows using the mom inline
+\# \*S[...], which is an alternate form of the inline, \*[SIZE <n>]
 \#
 \f[HB]\*S[-1]Normal word spacing\*S[+1]\*[PREV]
 .FT R
-N\*[BU 1]o\*[BU 1]w \*[BU 1]is the time for all good men to come to the aid of 
the party.
+N\*[BU1]o\*[BU1]w \*[BU1]is the time for all good men to come to the aid of 
the party.
 .ALD 4p
-\f[HB]\*S[-1]Word spacing adjusted by \*[UP 1p]\*[BU 3]+\*[DOWN 1p]\*[BU 
1]2\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Word spacing adjusted by \*[UP 1p]\*[BU3]+\*[DOWN 
1p]\*[BU1]2\*S[+1]\*[PREV]
 .FT R
 .WS +2
-N\*[BU 1]o\*[BU 1]w \*[BU 1]is the time for all good men to come to the aid of 
the party.
+N\*[BU1]o\*[BU1]w \*[BU1]is the time for all good men to come to the aid of 
the party.
 .WS  +0
 .ALD 4p
-\f[HB]\*S[-1]Word spacing adjusted by \*[UP 1p]\*[BU 3]+\*[DOWN 
1p]4\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Word spacing adjusted by \*[UP 1p]\*[BU3]+\*[DOWN 
1p]4\*S[+1]\*[PREV]
 .FT R
 .WS +4
-N\*[BU 1]o\*[BU 1]w \*[BU 1]is the time for all good men to come to the aid of 
the party.
+N\*[BU1]o\*[BU1]w \*[BU1]is the time for all good men to come to the aid of 
the party.
 .WS  +0
 .ALD 4p
-\f[HB]\*S[-1]Word spacing adjusted by \*[UP 1p]\*[BU 3]+\*[DOWN 
1p]6\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Word spacing adjusted by \*[UP 1p]\*[BU3]+\*[DOWN 
1p]6\*S[+1]\*[PREV]
 .FT R
 .WS +6
-N\*[BU 1]o\*[BU 1]w \*[BU 1]is the time for all good men to come to the aid of 
the party.
+N\*[BU1]o\*[BU1]w \*[BU1]is the time for all good men to come to the aid of 
the party.
 .WS +0
 .SP 1.5v
 \#
@@ -556,7 +564,7 @@
 .FT R
 "But this is \*[IT]important!\/"\*[PREV]she exclaimed.
 .ALD 4p
-\f[HB]\*S[-1]Line "tightened" \(en .RW .1\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Line "tightened" \[en] .RW .1\*S[+1]\*[PREV]
 .RW .1
 "But this is \*[IT]important!\/"\*[PREV]she exclaimed.
 .ALD 4p
@@ -564,11 +572,11 @@
 \# In the next line, notice that because it uses a different family
 \# (Helvetica instead of Palatino), the RW macro doesn't affect it.
 \#
-\f[HB]\*S[-1]Line "tightened" \(en .RW .2\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Line "tightened" \[en] .RW .2\*S[+1]\*[PREV]
 .RW .2
 "But this is \*[IT]important!\/"\*[PREV]she exclaimed.
 .ALD 4p
-\f[HB]\*S[-1]Line "tightened" \(en .RW .3\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Line "tightened" \[en] .RW .3\*S[+1]\*[PREV]
 .RW .3
 "But this is \*[IT]important!\/"\*[PREV]she exclaimed.
 .MCR
@@ -576,15 +584,15 @@
 \f[HB]\*S[-1]Unkerned line\*S[+1]\*[PREV]
 "But this is \*[IT]important!\/"\*[PREV]she exclaimed.
 .ALD 4p
-\f[HB]\*S[-1]Line "loosened" \(en .EW .1\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Line "loosened" \[en] .EW .1\*S[+1]\*[PREV]
 .EW .1
 "But this is \*[IT]important!\/"\*[PREV]she exclaimed.
 .ALD 4p
-\f[HB]\*S[-1]Line "loosened" \(en .EW .2\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Line "loosened" \[en] .EW .2\*S[+1]\*[PREV]
 .EW .2
 "But this is \*[IT]important!\/"\*[PREV]she exclaimed.
 .ALD 4p
-\f[HB]\*S[-1]Line "loosened" \(en .EW .3\*S[+1]\*[PREV]
+\f[HB]\*S[-1]Line "loosened" \[en] .EW .3\*S[+1]\*[PREV]
 .EW .3
 "But this is \*[IT]important!\/"\*[PREV]she exclaimed.
 .MCX 1.5v
@@ -597,8 +605,8 @@
 \#
 Example 7:
 .ALD .25v
-.UNDERSCORE 3.75p "Cutaround using left\*[FU 2]/right indents, multi columns \
-and a dropcap"
+.UNDERSCORE 3.75p "Cutaround using left\*[FU 2]/right indents, \
+multi columns and a dropcap"
 .SP
 \#
 .FT R
@@ -613,7 +621,8 @@
 \#
 \# The little picture of tux.
 \#
-.PSPIC penguin.ps
+.if '\*[.T]'pdf' .PDF_IMAGE penguin.pdf 81p 96p 
+.if '\*[.T]'ps' .PSPIC penguin.ps 81p 96p 
 .MCR
 .TAB 1
 .XCOLOR        red   \" Initialize the X11 color, red
@@ -622,21 +631,21 @@
 .DROPCAP L 3 COND 80 \" i.e. the letter L dropped 3 lines, condensed to 80% of 
its normal width
 .EW .2
 orem ipsum dolor sit amet, consetetur sa\%dip\%scing elitr, sed diam
-nonumy eir\%mod tempor invidunt ut labore et dolore magna aliquyam erat,
-sed diam voluptua.
+nonumy eir\%mod tempor invidunt ut labore et dolore magna aliquyam
+erat, sed diam voluptua.
 .EW 0
 .TI 1P
 At vero eos et accusam et justo duo dolores et ea rebum.  Stet clita
 kasd gubergren, no sea taki-
 .SPREAD              \" Force justify preceding line before starting indent
 .IR 3.5P
-kimata sanctus est lorem ipsum dolor sit amet.
-Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam
-nonumy eirmod tempor.
+kimata sanctus est lorem ipsum dolor sit amet.  Lorem ipsum dolor
+sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod
+tempor.
 .EW .2
 .TI
-Invidunt ut labore et dolore magna ali\%qu\%yam erat, sed diam voluptua.
-At
+Invidunt ut labore et dolore magna ali\%qu\%yam erat, sed diam
+voluptua.  At
 .EW 0
 vero eos et accusam et justo duo dolores et ea rebum.
 .TI
@@ -645,8 +654,8 @@
 .IRQ
 kimata sanctus est lorem ipsum dolor sit amet.  Lorem ipsum dolor
 sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor
-in\%vi\%dunt ut labore et dolore magna aliquyam erat.  Sed diam voluptua,
-at vero eos et accusam et justo duo
+in\%vi\%dunt ut labore et dolore magna aliquyam erat.  Sed diam
+voluptua, at vero eos et accusam et justo duo
 .SPREAD
 .EW .3
 dolores et ea rebum.  Stet clita no kasd guber-
@@ -658,20 +667,20 @@
 dolor sit amet.  Consetetur sadipscing elitr, sed diam nonumy eirmod
 tempor invidunt ut labore et dolore.
 .TI
-Magna aliquyam erat, sed diam voluptua, at vero eos et accusam.
-Et justo duo dolores et ea
+Magna aliquyam erat, sed diam voluptua, at vero eos et accusam.  Et
+justo duo dolores et ea
 .SPREAD
 .IL 3.5P
-rebum, stet clita kasd gubergren.  No sea
-takimata sanctus est, lorem ipsum dolor sit amet.
+rebum, stet clita kasd gubergren.  No sea takimata sanctus est,
+lorem ipsum dolor sit amet.
 .TI
-Sit amet, consetetur sadipscing elitr, sed diam.  Nonumy eirmod tempor
-in\%vi-
+Sit amet, consetetur sadipscing elitr, sed diam.  Nonumy eirmod
+tempor in\%vi-
 .EW .3
 dunt ut labore et dolore magna.  Ali-
 .EW 0
-quyam erat sed diam voluptua.
-At vero eos et accusam et justo duo dolores et ea rebum stet.
+quyam erat sed diam voluptua.  At vero eos et accusam et justo duo
+dolores et ea rebum stet.
 .ILQ
 .TI
 Dolores et ea rebum stet clita kasd gubergren, no sea takimata

Index: momdoc/appendices.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/appendices.html,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -b -r1.22 -r1.23
--- momdoc/appendices.html      13 Apr 2011 20:00:27 -0000      1.22
+++ momdoc/appendices.html      31 Aug 2012 22:49:58 -0000      1.23
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -33,18 +35,22 @@
 <table style="width: 100%;">
 <tr>
   <td><a href="toc.html">Back to Table of Contents</a></td>
-  <td style="text-align: right;"><a href="reserved.html#top">Next: Reserved 
words</a></td>
 </tr>
 </table>
 
 <h1 id="appendices" class="docs">Appendices</h1>
 
-<div style="width: 54%; margin: auto;">
+<div style="width: 68%; margin: auto;">
 <ul class="no-enumerator">
-  <li><a href="#moredoc">Notes on the documentation</a></li>
-  <li><a href="#fonts">Adding PostScript fonts to groff</a>
-  <ul style="margin-left: -.5em;">
-    <li><a href="#howto">How to create a PostScript font for use with 
groff</a></li>
+  <li><a href="#fonts">Adding fonts to groff</a>
+  <ul style="margin-left: -.5em; list-style-type: disc">
+    <li><a href="#extending">Extending groff families / adding new families 
and fonts</a>
+    <ul style="margin-left: -.5em; list-style-type: circle">
+      <li><a href="#traditional">The traditional approach</a></li>
+      <li><a href="#simpler">The simpler way with mom</a></li>
+    </ul></li>
+    <li><a href="#steps">Step-by-step instructions</a></li>
+    <li><a href="#install-font">Automate the whole process &ndash; the 
install-font script</a></li>
   </ul></li>
   <li><a href="#codenotes">Some reflections on mom</a></li>
   <li><a href="#contact">Contact the author</a></li>
@@ -53,59 +59,35 @@
 
 <div class="rule-medium"><hr/></div>
 
-<h2 id="moredoc" class="docs">Notes on the documentation</h2>
-
-<p>
-Some mom users are sure to ask: &#8220;Why is the documentation in
-html?  If mom&#8217;s so great, why not pdfs to show her off?  And
-if groff&#8217;s so great, why not write a man page?&#8221;
-</p>
-
-<p>
-Valid questions, to be sure, and mom has answers.  (Okay&mdash;I
-have answers, but I speak for mom.)
-</p>
-
-<p>
-The documentation is in html because I still find it the best tool
-for navigating lengthy manuals.  Html, with its anchors and links,
-came into being precisely so people could do something they&#8217;d
-never been able to with the printed word: instantly track down
-internal and external references in a document.
-</p>
-
-<p>
-It&#8217;s essential that people reading mom&#8217;s documentation
-never have difficulty finding precisely the macro they need for a
-particular task.  Equally, when reading up on a macro, they should
-never be presented with terms or other macro names for which they
-cannot instantly find accurate explanations.  Short of having
-written the documentation in TeX for the info browser (and TeX bloat
-is one of the reasons I prefer to typeset with groff), I can think
-of no better way to achieve the kind of truly useful documentation I
-wanted than html.
-</p>
-
-<div class="rule-medium"><hr/></div>
-
-<!-- ===================================================================== -->
-
-<h2 id="fonts" class="docs">Adding PostScript fonts to groff</h2>
+<h2 id="fonts" class="docs">Adding fonts to groff</h2>
 
 <div id="small-note" class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-The term <kbd>&lt;prefix&gt;</kbd> in this section refers
+<p class="tip-top">
+<kbd>&lt;prefix&gt;</kbd>, in this section, refers
 to the directory in which groff is installed, typically
-something like <kbd>/usr/share/groff/&lt;version&gt;</kbd>
+<br/>
+<span class="pre-in-pp">
+  /usr/share/groff/
+</span>
 (for distro-specific, pre-compiled groff packages) or
-<kbd>/usr/local/share/groff/&lt;version&gt;</kbd> (if you&#8217;ve
-built groff from source).
+<br/>
+<span class="pre-in-pp">
+  /usr/local/share/groff/
+</span>
+(if you&#8217;ve built groff from source).
+<p class="tip-bottom">
+<kbd>&lt;version&gt;</kbd> refers to the groff version number, which
+can be found, if necessary, by typing
+<br/>
+<span class="pre-in-pp">
+  groff -v
+</span>
+at the command line.
 </p>
 </div>
 
 <p>
-Groff comes with a small library of PostScript
+Groff comes with a small library of 
 <a href="definitions.html#family">families</a>
 (see the
 <a href="typesetting.html#family">FAMILY</a>
@@ -122,48 +104,51 @@
   B  (Bold, usually Roman shape) and
   BI (Bold Italic)
 </span>
-If you work with mom a lot, you&#8217;ll find, sooner or later, that these
+If you work with mom a lot, sooner or later you&#8217;ll find that these
 families and their associated fonts aren&#8217;t sufficient.  You&#8217;ll
 want to supplement them, either with more fonts for the families
 already provided&mdash;<i>Damn!  I need Helvetica Bold Condensed
-Italic!</i>&mdash;or with entire new families.
+Italic</i>&mdash;or with entire new families.
 </p>
 
-<p>
-Without going into the gory details (yet), while it&#8217;s true
-that adding fonts to groff is a relatively straightforward process,
-extending existing families or adding new ones requires some
-planning.
-</p>
+<h3 id="extending" class="docs">Extending groff families / adding new families 
and fonts</h3>
+
+<h4 id="traditional" class="docs">The traditional approach</h4>
 
 <p>
-The traditional approach to extending groff families has been to
-create new families for non-default weights and shapes (e.g.  Light,
-which is a weight; Condensed, which is a shape), then to associate
-them with groff&#8217;s predefined <b>R, I, B</b> and <b>BI</b> font
-styles.  An example of this can be seen in the groff PostScript
-font library itself (&lt;prefix&gt;/font/devps/): there&#8217;s one
-&#8220;family&#8221; for Helvetica (<b>HR</b>, <b>HI</b>, <b>HB</b>,
-<b>HBI</b>) and another for Helvetica Narrow (<b>HNR</b>,
-<b>HNI</b>, <b>HNB</b>, <b>HNBI</b>).
+The traditional approach to extending groff families has been
+to create new families for non-default weights and shapes (e.g.
+<b>Light</b>, which is a
+<a href="definitions.html#weight">weight</a>,
+or <b>Condensed</b>, which is a
+<a href="definitions.html#shape">shape</a>),
+then to associate them with groff&#8217;s predefined <b>R,
+I, B</b> and <b>BI</b> font styles.  An example of this
+can be seen in the groff PostScript font library itself, which is
+found in
+</br>
+<span class="pre-in-pp">
+  &lt;prefix&gt;/&lt;version&gt;/font/devps/
+</span>
+There&#8217;s one &#8220;family&#8221; for Helvetica (<b>HR</b>,
+<b>HI</b>, <b>HB</b>, <b>HBI</b>) and another for Helvetica Narrow
+(<b>HNR</b>, <b>HNI</b>, <b>HNB</b>, <b>HNBI</b>).
 </p>
 
 <p>
 The difficulty with this approach is that typographers tend to
 think of families as referring to the entire set of font weights
-and shapes associated with a particular family name.  For example,
-when a typesetter says &#8220;the Helvetica family&#8221;, s/he is
-including the
-<a href="definitions.html#weight">weights</a>
-Helvetica Thin, Helvetic Light, Helvetica Regular, Helvetica Bold,
-Helvetica Heavy, etc, and all their associated
-<a href="definitions.html#shape">shapes</a>
-(Roman, Italic, Condensed, Narrow, Extended, Outline, etc).
+and shapes associated with a family name.  For example, when
+a typesetter says &#8220;the Helvetica family&#8221;, s/he is
+including the weights Helvetica Thin, Helvetica Light, Helvetica
+Regular, Helvetica Bold, Helvetica Heavy, etc, and all their
+associated shapes (Roman, Italic, Condensed, Narrow, Extended,
+Outline, etc).
 </p>
 
 <p>
 Thus, intuitively, when a typesetter gives mom a
-<kbd>.FAM(ILY)&nbsp;H</kbd> directive, s/he reasonably expects that
+<kbd>.FAMILY&nbsp;H</kbd> directive, s/he reasonably expects that
 any subsequent <kbd>.FT</kbd> directive will access the desired font
 from the Helvetica family&mdash;without the need to state explicitly
 both family and font to <kbd>.FT</kbd>, as it is explained one can
@@ -175,18 +160,29 @@
 </p>
 
 <p>
-If one had, say, the fonts, Helvetica Light Roman and Helvetica
-Light Italic as well as Helvetica Light Condensed Roman and
-Helvetica Light Condensed Italic, the established groff approach
-would require two &#8220;partial&#8221; families: HLR/HLI and
-HLCDR/HLCDI.  Accessing these family/font combos routinely
-throughout a document would then require changing family
-(with <kbd>.FAM(ILY)</kbd>) and selecting the desired font
+If one had, say, Helvetica Light Roman and Helvetica Light Italic
+as well as Helvetica Light Condensed Roman and Helvetica Light
+Condensed Italic, the established groff approach would require two
+&#8220;partial&#8221; families, <b>HL</b> (for Helvetica Light)
+and <b>HLCD</b> (for Helvetica Light Condensed), with <b>R</b> and
+<b>I</b> fonts for both:
+</br>
+<span class="pre-in-pp">
+  HLR
+  HLI
+  HLCDR
+  HLCDI
+</span>
+Accessing these family/font combos routinely
+throughout a document would then require changing the family
+(with <kbd>.FAMILY</kbd>) and selecting the desired font
 (with <kbd>.FT&nbsp;R</kbd> or <kbd>.FT&nbsp;I</kbd>), or
 passing <kbd>.FT</kbd> the lengthy family+fontname (.e.g.
 <kbd>.FT&nbsp;HLCDI</kbd>).
 </p>
 
+<h4 id="simpler" class="docs">The simpler way with mom</h4>
+
 <p>
 Fortunately, groff provides a mechanism whereby it&#8217;s possible
 to extend the basic <b>R</b>, <b>I</b>, <b>B</b> and <b>BI</b> fonts
@@ -197,50 +193,128 @@
 
 <p>
 Mom uses this mechanism to offer, in addition to groff&#8217;s
-default PostScript font styles, the following:
+default font styles, the following:
 </p>
 
 <div class="examples-container" style="padding-bottom: 1em;">
-<div id="style-extensions" style="width: 53%; float: left;">
-<span class="pre">
+<div id="style-extensions" style="width: 50%; float: left;">
+<span class="pre" style="font-size: 85%">
+UL     =  Ultra Light
+ULI    =  Ultra Light Italic
+ULCD   =  Ultra Light Condensed
+ULCDI  =  Ultra Light Condensed Italic
+ULEX   =  Ultra Light Extended
+ULEXI  =  Ultra Light Extended Italic
+
+XL     =  Extra Light
+XLI    =  Extra Light Italic
+XLCD   =  Extra Light Condensed
+XLCDI  =  Extra Light Condensed Italic
+XLEX   =  Extra Light Extended
+XLEXI  =  Extra Light Extended Italic
+
+TH     =  Thin
+THI    =  Thin Italic
+THCD   =  Thin Condensed
+THCDI  =  Thin Condensed Italic
+THEX   =  Thin Extended
+THEXI  =  Thin Extended Italic
+
 L     =  Light Roman
 LI    =  Light Italic
-LCD   =  Light Condensed Roman
+LCD    =  Light Condensed
 LCDI  =  Light Condensed Italic
-LEX   =  Light Extended Roman
+LEX    =  Light Extended
 LEXI  =  Light Extended Italic
-CD    =  Medium/Book Condensed Roman
-CDI   =  Medium/Book Condensed Italic
-EX    =  Medium/Book Extended Roman
-EXI   =  Medium/Book Extended Italic
+
+BK     =  Book Roman
+BKI    =  Book Italic
+BKCD   =  Book Condensed
+BKCDI  =  Book Condensed Italic
+BKEX   =  Book Extended
+BKEXI  =  Book Extended Italic
+
+CD     =  Medium Condensed
+CDI    =  Medium Condensed Italic
+EX     =  Medium Extended
+EXI    =  Medium Extended Italic
+
 DB    =  DemiBold Roman
 DBI   =  DemiBold Italic
-BCD   =  Bold Condensed Roman
-BCDI  =  Bold Condensed Italic
-BEX   =  Bold Extended Roman
+DBCD   =  DemiBold Condensed
+DBCDI  =  DemiBold Condensed Italic
+DBEX   =  DemiBold Extended
+DBEXI  =  DemiBold Extended Italic
+
+SB     =  SemiBold Roman
+SBI    =  SemiBold Italic
+SBCD   =  SemiBold Condensed
+SBCDI  =  SemiBold Condensed Italic
+SBEX   =  SemiBold Extended
+SBEXI  =  SemiBold Extended Italic
 </span>
 </div>
-<span class="pre">
+<span class="pre" style="font-size: 85%">
+BCD    =  Bold Condensed
+BCDI   =  Bold Condensed Italic
+BEX    =  Bold Extended
 BEXI   =  Bold Extended Italic
-HV     =  Heavy Roman
+BO     =  Bold Outline
+
+XB     =  Extra Bold
+XBI    =  Extra Bold Italic
+XBCD   =  Extra Bold Condensed
+XBCDI  =  Extra Bold Condensed Italic
+XBEX   =  Extra Bold Extended
+XBEXI  =  Extra Bold Extended Italic
+
+UB     =  Ultra Bold
+UBI    =  Ultra Bold Italic
+UBCD   =  Ultra Bold Condensed
+UBCDI  =  Ultra Bold Condensed Italic
+UBEX   =  Ultra Bold Extended
+UBEXI  =  Ultra Bold Extended Italic
+
+HV     =  Heavy
 HVI    =  Heavy Italic
-HVCD   =  Heavy Condensed Roman
+HVCD   =  Heavy Condensed
 HVCDI  =  Heavy Condensed Italic
-HVEX   =  Heavy Extended Roman
+HVEX   =  Heavy Extended
 HVEXI  =  Heavy Extended Italic
-BL     =  Black Roman
+
+BL     =  Black
 BLI    =  Black Italic
-BLCD   =  Black Condensed Roman
+BLCD   =  Black Condensed
 BLCDI  =  Black Condensed Italic
-BLEX   =  Black Extended Roman
+BLEX   =  Black Extended
 BLEXI  =  Black Extended Italic
-UBL    =  Ultra-Black Roman
-UBLI   =  Ultra-Black Italic
+BLO    =  Black Outline
+
+XBL    =  Extra Black
+XBLI   =  Extra Black Italic
+XBLCD  =  Extra Black
+XBLCDI =  Extra Black
+XBLEX  =  Extra Black Italic
+XBLEXI =  Extra Black Italic
+
+UBL    =  Ultra Black
+UBLI   =  Ultra Black Italic
+UBLCD  =  Ultra Black Condensed
+UBLCDI =  Ultra Black Condensed Italic
+UBLEX  =  Ultra Black Exteneded
+UBLEXI =  Ultra Black Extended Italic
+
+SC     =  Small Caps Roman
+SCI    =  Small Caps Italic
+SCDB   =  Small Caps Demibold
+SCDBI  =  Small Caps Demibold Italic
+SCSB   =  Small Caps Semibold
+SCSBI  =  Small Caps Semibold Italic
 </span>
 </div>
 
 <p style="clear: both;">
-Thus, with mom, if you&#8217;ve installed, say, some extra
+Thus, with mom, if you&#8217;ve installed some extra
 Helvetica fonts and named them according to the convention
 <kbd>&lt;F&gt;&lt;S&gt;</kbd> (where <kbd>&lt;F&gt;</kbd> means
 family and <kbd>&lt;S&gt;</kbd> means font style), once having
@@ -249,22 +323,14 @@
 <span class="pre-in-pp" style="margin-bottom: -1em;">
   .FAMILY H
 </span>
-or
-<span class="pre-in-pp" style="margin-top: -.5em;">
-  .FAM H
-</span>
-you can access any of those Helvetica fonts simply by passing the
-correct argument to
-<a href="typesetting.html#font">FT</a>.
-from the list, above.
-</p>
-
-<p>
-For example, if you were working in Medium Roman
-(<kbd>.FT&nbsp;R</kbd>) and you needed Medium Condensed Italic for a
-while (assuming it&#8217;s installed), you&#8217;d just type
+you can access any of the extra Helvetica fonts simply by passing
+the correct argument to
+<a href="typesetting.html#font">FT</a>
+from the list, above.  For example, if you were working in Medium
+Roman (<kbd>.FT&nbsp;R</kbd>) and you needed Medium Condensed Italic
+for a while (assuming it&#8217;s installed), you&#8217;d just type
 <br/>
-<span class="pre-in-pp">
+<span class="pre-in-pp" style="margin-bottom: -1em;">
   .FT CDI
 </span>
 to access the Medium Condensed Italic font from the Helvetica
@@ -273,43 +339,36 @@
 
 <p>
 Mom&#8217;s list of font styles doesn&#8217;t pretend to be
-exhaustive, but rather tries to cover the basic weight/shape
-combinations likely to be found in any reasonably complete type
-family.
-</p>
-
-<p>
-The actual extension names are arbitrary and can be used in a
+exhaustive.  The extension names are arbitrary and can be used in a
 flexible manner.  For example, if you create a family that has a
-DemiBold font (<b>DB</b>) but no Bold font (<b>B</b>), you might
-find it more convenient to give the DemiBold font the extension
-&#8220;<b>B</b>&#8221;.  Equally, if the family has an ExtraBold
-font, you might find it more convenient to use the extension
-&#8220;<b>HV</b>&#8221; (Heavy).
+Demibold font (<b>DB</b>) but no Bold font (<b>B</b>), you might
+find it more convenient to give the Demibold font the extension
+&#8220;<b>B</b>&#8221;.
 </p>
 
 <p id="register-style">
-However, you may, at needs, want to add to mom&#8217;s list of font
-styles.  You can do this by editing the file, om.tmac (typical
-location: <kbd>&lt;prefix&gt;tmac/om.tmac</kbd>).  Near the top,
-you&#8217;ll see lines of the form
+You may, at needs, want to add to mom&#8217;s list of font styles.
+You can do this by editing the file, om.tmac (typical location:
+<kbd>&lt;prefix&gt;/&lt;version&gt;/tmac/om.tmac</kbd>).  Near the
+top, you&#8217;ll see lines of the form
 <br/>
 <span class="pre-in-pp">
+  .sty \n[.fp] XL      \" Extra Light
   .sty \n[.fp] L       \" Light Roman
   .sty \n[.fp] LI      \" Light Italic
   .sty \n[.fp] LCD     \" Light Condensed Roman
 </span>
 Simply add your new font style by imitating what you see, above,
-and plugging in your new font style (having, of course, first
-created the font, correctly named, in groff&#8217;s PostScript font
+and plugging in your new font style (having, of course, 
+added the font to groff, correctly named).
 directory; see
-<a href="#howto">How to create a PostScript font for use with groff</a>).
+<a href="#steps">Step-by-step instructions</a>).
 </p>
 
 <p>
 For example, if you already have some fonts from the Univers family
-installed and have called the family <b>UN</b>, you might decide at
-some point to add the Bold Outline font (<b>UNBO</b>).  In which
+installed and have called the family <b>Univers</b>, you might decide at
+some point to add the Bold Outline font (<b>UniversBO</b>).  In which
 case, you&#8217;d add
 <br/>
 <span class="pre-in-pp">
@@ -319,6 +378,19 @@
 in om.tmac.
 </p>
 
+<div class="box-tip">
+<p class="tip">
+<span class="note">Note:</span>
+Mom&#8217;s font extensions are not &#8220;user-space&#8221;
+controllable via a macro.  If you&#8217;ve been using groff for
+a long time, and have already rolled your own solution to adding
+families and fonts to groff, you may find that mom&#8217;s font
+extensions conflict with your own scheme.  Should that be the case,
+comment out the <kbd>.sty&nbsp;\n[.fp] &lt;font style&gt;</kbd>
+lines found near the top of the <kbd>om.tmac</kbd> file.
+</p>
+</div>
+
 <div class="box-important">
 <p class="tip">
 <span class="important">Important:</span>
@@ -328,337 +400,370 @@
 <b>CI</b>, <b>CB</b>, <b>CI</b>).  Were you to create a font
 style &#8220;<b>C</b>&#8221;, thinking that <kbd>.FT&nbsp;C</kbd>
 would give you access to font style once you&#8217;d given a
-<kbd>.FAM(ILY)</kbd> directive, you&#8217;d get a nasty surprise:
+<kbd>.FAMILY</kbd> directive, you&#8217;d get a nasty surprise:
 your type would come out in Courier Roman!
 </p>
 </div>
 
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-Mom&#8217;s font extensions are not &#8220;user-space&#8221;
-controllable via a macro.  If you&#8217;ve been using groff for
-a long time, and have already rolled your own solution to adding
-PostScript families, fonts, weights, shapes, etc. to groff, you may
-find that mom&#8217;s font extensions conflict with your own scheme.
-Should that be the case, comment out the <kbd>.sty&nbsp;\n[.fp] &lt;font
-style&gt;</kbd> lines found near the top of the <kbd>om.tmac</kbd>
-file.
-</p>
-</div>
-
 <div class="rule-medium"><hr/></div>
 
-<h2 id="howto" class="docs">How to create a PostScript font for use with 
groff</h2>
+<h2 id="steps" class="docs">Step-by-step instructions</h2>
+
+<div>
+<ul class="no-enumerator" style="margin-left: -1.5em;">
+  <li><a href="#need">What you need before you start</a></li>
+  <li><a href="#preparation">Initial preparation</a></li>
+  <li><a href="#step-1">1. Acquire the font</a></li>
+  <li><a href="#step-2">2. Prepare to convert the font to the correct 
format</a>
+  <ul style="margin-left: -.5em">
+    <li><a href="#ttf">TTF fonts</a></li>
+    <li><a href="#type1">Type 1 fonts</a></li>
+  </ul></li>
+  <li><a href="#step-3">3. Convert the font and put it in the right 
place</a></li>
+  <li><a href="#step-4">4. Update the download file</a>
+  <ul style="margin-left: -.5em">
+    <li><a href="#internal">Get the internal font name</a></li>
+    <li><a href="#add">Add the font to the download file</a></li>
+    <li><a href="#gropdf-download">Updating the gropdf download file</a></li>
+  </ul></li>
+  <li><a href="#groff-font-names">Naming groff fonts</a>
+  <li><a href="#install-font">Automate the whole process &ndash; the 
install-font script</a>
+  </ul></li>
+</ul>
+</div>
+
 
 <p>
-These instructions aren&#8217;t meant to cover all possibilities, merely
-to present one way of making PostScript families/fonts available to
-groff and mom.
+There are a number of ways to approach making fonts available
+to groff.  These instructions aren&#8217;t meant to cover all
+possibilities, merely one.
 </p>
 
 <p>
-GNU/Linux distributions being what they are, directory locations may
-differ and the presence of some executables can&#8217;t be guaranteed.
-I run a Debian system.  The instructions reflect that.  Users of
-other distros will have to interpret them according to the way their
-distro operates.
+GNU/Linux distributions being what they are, directory locations
+may differ and the presence of some executables can&#8217;t be
+guaranteed.  I run a Debian-based system.  The instructions reflect
+that.  Users of other distros may have to interpret them according
+to the way their distro operates.
 </p>
 
-<h3 class="docs appendices">1. What you need before you start</h3>
+<h3 id="need" class="docs appendices">What you need before you start</h3>
 
 <ul style="margin-top: 1em; margin-left: -.5em;">
   <li>groff, version 1.18 or higher<br/>
       (Debian package: groff)
   </li>
-  <li>a full installation of ghostscript and associated tools<br/>
-      (suggested Debian package: ghostscript-x)
-  </li>
-  <li>a library of PostScript fonts<br/>
-      (suggest Debian packages: gsfonts, gsfonts-x11, gsfonts-other)
+  <li>ghostscript<br/>
+      (Debian package: ghostscript or ghostscript-x)
   </li>
-  <li>a utility for converting TrueType fonts to Type1 fonts<br/>
-      (Debian package: ttf2pt1)
-  </li>
-  <li>a font manager<br/>
-      (Debian packages: defoma, psfontmgr)
-  </li>
-  <li>perl<br/>
-      (Debian package: perl)
+  <li>fontforge<br/>
+      (Debian package: fontforge)
    </li>
 </ul>
 
-<p style="margin-top: -.5em;">
-A reasonably complete installation of any major GNU/Linux distro
-should already have these on your system, except perhaps for the
-utility to convert TrueType fonts to Type1 fonts (<b>ttf2pt2</b>).
-</p>
+<h3 id="preparation" class="docs appendices">Initial preparation (you only 
need do this once)</h3>
 
-<h3 class="docs appendices">2. Initial preparation (you only need do this 
once)</h3>
-
-<ol style="margin-left: -.5em;">
-  <li>If you don&#8217;t already have one, create a directory in
-      your home directory to hold new fonts.  Any directory name
-      will do.  I use <kbd>~/Fonts</kbd>, with subdirectories for
-      <kbd>Type1</kbd>, <kbd>TrueType</kbd> and <kbd>Groff</kbd>
-      fonts. Thus,
-      <br/>
-      <span class="pre-in-pp">
-  ~/Fonts/Type1
-  ~/Fonts/TrueType
-  ~/Fonts/Groff
-      </span>
-  </li>
-  <li id="site-font" style="margin-top: -2em;">Locate the groff
-      directory, <kbd>site-font</kbd>.  The exact location is
+<ol id="site-font" style="margin-left: -1em;">
+  <li>
+    Locate the groff directory,
+    <kbd>site-font</kbd>.  The exact location is
       difficult to predict, owing to differences between distros and
       whether you&#8217;re using a pre-packaged groff or have built
       it from source.  Some typical locations are:
       <br/>
       <span class="pre-in-pp" style="margin-bottom: -2em;">
-  /usr/share/groff
-  /usr/local/share/groff
-  /etc/groff
+      /usr/share/groff/
+      /usr/local/share/groff/
+      /etc/groff/
       </span>
       If you can&#8217;t find the site-font directory, locate
-      groff&#8217;s <kbd>site-tmac</kbd> directory, and, as
-      root, create site-font in the same directory as the
-      one that holds site-tmac.  E.g., if you find site-tmac
-      in <kbd>/usr/share/groff</kbd>, create site-font in
-      <kbd>/usr/share/groff</kbd>.
-  </li>
-  <li style="margin-top: .5em;">Locate the file
-      <kbd>&lt;prefix&gt;/font/devps/generate/textmap</kbd> and
-      symlink it to the name <kbd>textmap</kbd> in the directory
-      that contains your personal collection of PostScript fonts.
-      (See the
-      <a href="#small-note">note</a>,
-      above, for the meaning of <kbd>&lt;prefix&gt;</kbd>).  On my
-      system, at the time of writing, <kbd>&lt;prefix&gt;</kbd>
-      is
+    groff&#8217;s <kbd>site-tmac</kbd> directory, and, as root,
+    create site-font in the same directory.  Eg, if you find
+    site-tmac in <kbd>/usr/share/groff/</kbd>, create site-font in
+    <kbd>/usr/share/groff/</kbd>
       <br/>
       <span class="pre-in-pp" style="margin-bottom: -2em;">
-  /usr/local/share/groff/1.20.1/
-      </span>
-      therefore, I symlink it in <kbd>~/Fonts/Type1/</kbd> with
-      <br/>
-      <span class="pre-in-pp">
- ln -s /usr/local/share/groff/1.20.1/font/devps/generate/textmap textmap
+      sudo mkdir site-font
       </span>
   </li>
-  <li style="margin-top: -2em;">Locate the file
-      <kbd>&lt;prefix&gt;/font/devps/text.enc</kbd> and
-      symlink it to the name <kbd>text.enc</kbd> in your personal
-      font directory.  On my system, in <kbd>~/Fonts/Type1/</kbd>
+  <li>
+    Create two files, generate-t42.pe and generate-pfa.pe,
+    as you see them below.  Place them in a convenient and
+    easily-remembered location, like your home directory.
       <br/>
-      <span class="pre-in-pp">
-  ln -s /usr/local/share/groff/1.19.2/font/devps/text.enc text.enc
-      </span>
-  </li>
-  <li style="margin-top: -2em;">Make sure you know which
-      directory holds your PostScript fonts.  You&#8217;ll need the
-      information later.  On a Debian box, a typical location is
-      <kbd>/usr/share/fonts/type1/gsfonts</kbd>
-  </li>
-</ol>
+    <span class="examples" style="font-size: 95%; display: block; margin-top: 
.5em;">generate-t42.pe</span>
 
-<h3 class="docs appendices">3. Font creation/installation</h3>
+    <div class="examples-container" style="margin-top: 0; margin-bottom: -1em; 
padding-bottom: 1em;">
+<span class="pre">
+# generate-t42.pe
 
-<ol style="margin-left: -.5em/">
-  <li>Acquire the font as either Type1 (.pfb) or TrueType (.ttf).</li>
-  <li style="margin-top: .5em;">Place the font in your personal font 
directory; for me,
-      that&#8217;s
-      <br/>
-      <span class="pre-in-pp" style="margin-bottom: -2.5em;">
-  ~/Fonts/Type1
-      </span>
-      or
-      <br/>
-      <span class="pre-in-pp" style="margin-top: -.5em; margin-bottom: -2em;">
-  ~/Fonts/TrueType
-      </span>
-  </li>
-  <li>In your personal font directory, run one of the following.
-  <ul style="margin-left: -1.5em;">
-    <li style="margin-top: .5em;">for <b>Type1 fonts</b>:
-        <br/>
-        <span class="pre-in-pp" style="margin-bottom: -2em;">
-  getafm fontfilename.pfb | gsnd - > fontfilename.afm
-        </span>
-       <i>(This generates something called
-       an .afm (Adobe Font Metrics) file from the .pfb file, which is required 
to
-       create PostScript fonts for groff.)</i>
-      </li>
-      <li style="margin-top: .5em;">for <b>TrueType fonts</b>:
-        <br/>
-        <span class="pre-in-pp" style="margin-bottom: -2em;">
-  ttf2pt1 \-b fontfilename.ttf
-        </span>
-        <i>(For TrueType fonts, this generates a PostScript .pfb file
-         as well as an .afm file.)</i>
-      </li>
-  </ul></li>
-  <li style="margin-top: .5em;">Still in your personal font directory, run
+Open($1);
+Generate($fontname + ".pfa");
+Generate($fontname + ".t42");
+</span>
+    </div>
       <br/>
-      <span class="pre-in-pp" style="margin-bottom: -2em;">
-  afmtodit -e text.enc fontfilename.afm textmap &lt;GROFF_FONTNAME&gt;
-      </span>
-      <p id="groff-font-name" style="margin-top: .25em;">
-      Q: <i>How do I choose a</i> <kbd>GROFF_FONTNAME</kbd><i>?</i>
-      </p>
-
-      <p>
-      A: Start by considering the
-      <a href="definitions.html#family">family</a>
-      to which the font belongs.  If you&#8217;re adding to a family
-      that already exists in groff&#8217;s
-      <kbd>&lt;prefix&gt;/font/devps</kbd> directory, that will be
-      the first part of the font name.  (See
-      <a href="typesetting.html#family">here</a>
-      for a list of families already installed, along with their
-      groff names.)  Add to that name the appropriate weight/style
-      extension, listed
-      <a href="#style-extensions">here</a>.
-      </p>
-      
-      <p>
-      For example, if you&#8217;re adding Helvetica Light Roman,
-      your <kbd>GROFF_FONTNAME</kbd> would be <kbd>HL</kbd>.
-      If you&#8217;re adding Helvetica Light Italic, your
-      <kbd>GROFF_FONTNAME</kbd> would be <kbd>HLI</kbd>.
-      </p>
-
-      <p>
-      If you&#8217;re adding a font not already in groff&#8217;s
-      PostScript families, first choose a meaningful name for the
-      <a href="definitions.html#family">family</a>
-      to which the font belongs.  The name can be anything you like.
-      If, for example, the family is Garamond, you could choose
-      <kbd>GARAMOND</kbd>, <kbd>GARA</kbd>, <kbd>GD</kbd>, or even
-      just plain G as the family name.  Then tack on the appropriate
-      style/weight extension.  Thus, if you were installing Garamond
-      Bold Condensed Italic and had chosen <kbd>GD</kbd> as the
-      family name for Garamond, your <kbd>GROFF_FONTNAME</kbd> would
-      be <kbd>GDBCDI</kbd>.
-      </p>
-
-      <p>
-      In mom, you can then access the Garamond family with
-      <kbd>.FAM GD</kbd>, and the Bold Condensed Italic font wth
-      <kbd>.FT&nbsp;BCDI</kbd>.
-      </p>
-
-      <div class="box-tip">
-      <p class="tip">
-      <span class="note">Note:</span>
-      The family name need not be in upper case, and there&#8217;s
-      no limit to the length of the name.  &#8220;Garamond&#8221;,
-      for example, could be the name you give the Garamond
-      family.  In fact, you might find it preferable, since a) you
-      wouldn&#8217;t have to remember how you&#8217;d named the
-      family, and b) should you be scanning your
-      <a href="#site-font">site-font directory</a>,
-      something like GaramondBCDI will be more meaningful than,
-      say, GDBCDI.
-      </p>
+    <span class="examples" style="font-size: 95%; display: block; margin-top: 
.5em;">generate-pfa.pe</span>
+    <div class="examples-container" style="margin-top: 0; padding-bottom: 
1em;">
+<span class="pre">
+# generate-pfa.pe
+
+Open($1);
+Generate($fontname + ".pfa");
+</span>
       </div>
   </li>
-  <li>Copy or move <kbd>GROFF_FONTNAME</kbd> to your
-      <a href="#site-font">site-font directory</a>,
-      or change to the site-font directory and make a symlink to
-      <kbd>GROFF_FONTNAME</kbd> in your personal directory.
-  </li>
-  <li style="margin-top: .5em;">Copy or move the .pfb file to the directory 
that
-      holds your PostScript fonts, or change to that directory and
-      make a symlink to the .pfb file in your personal directory.
-  </li>
 </ol>
 
+<h3 id="step-1" class="docs appendices">Step 1: Acquire the font</h3>
+
+<p class="top">
+The two most commonly available types of fonts are PostScript Type1
+(extension .pfb) and TrueType (extension .ttf).  Either can be made
+available to groff.  There are many websites holding collections of
+both.
+</p>
+
+<h3 id="step-2" class="docs appendices">Step 2: Prepare to convert the font to 
the correct format</h3>
+
+<p class="top">
+Change into the directory holding the new font.
+</p>
+
 <p>
-Written out in full, adding fonts looks like a lot of work.  It
-isn&#8217;t.  Basically, it&#8217;s just:
+For convenience in the next step, make a symbolic link to 
+the file 'textmap':
+<br/>
+<span class="pre-in-pp">
+  ln -s &lt;prefix&gt;/&lt;version&gt;/font/devps/generate/textmap .
+</span>
+See
+<a href="#small-note">here</a>
+for an explanation of &lt;prefix&gt;
+and &lt;version&gt;.
 </p>
-<ul style="margin-top: -.5em;">
-  <li>generate an .afm (and .pfb if the font is TrueType)</li>
-  <li>create the groff font</li>
-  <li>put the groff font in<kbd> &lt;prefix&gt;/font/devps</kbd></li>
-  <li>put the .pfb file (the actual font) with your other PostScript fonts</li>
-</ul>
 
 <p>
-After you&#8217;ve done it a couple of times, it all makes sense
-and is really quite easy.  Not to mention that once you understand
-the process, you can write a bash script to automate the process.
-Here&#8217;s an example, which you can adapt to your own needs.
-The script, for installing TrueType fonts, requires an argument (the
-.ttf filename), then prompts for a family directory name (e.g.
-AmericanTypewriter or Futura) and a name to give the groff font
-(see
-<a href="#groff-font-name">here</a>
-for suggestions concerning groff font naming.)  The script assumes a
-<kbd>~/Font</kbd> directory with subdirectories <kbd>Type1</kbd>,
-<kbd>TrueType</kbd> and <kbd>Groff</kbd>.
-</p>
-
-<div class="examples" style="margin-bottom: 0px;">Code:</div> 
-<div class="box-code" style="width: 726px; max-width: 726px; height: 400px; 
overflow: auto;">
-<span class="pre" style="color: #302419;">
-#!/bin/sh
-#
-# Converts .ttf file to .pfb and generates .afm
-# Moves the .afm and .pfb to $HOME/Fonts/Type1
-# Generates a groff font from the .afm file and installs it
-# in $HOME/Fonts/Groff
-# Symlinks the groff font to groff's site-font/devps directory
-# Symlinks the .afm and .pfb to /usr/share/fonts/type1/gsfonts
-#
-
-FONT=`basename $1 .ttf`
-FONTDIR="$HOME/Fonts/TrueType"
-T1_FONTDIR="$HOME/Fonts/Type1"
-GS_FONTDIR="/usr/share/fonts/type1/gsfonts"
-GROFF_SITE_FONTDIR="/usr/local/share/groff/site-font/devps"
-GROFF_FONTS="$HOME/Fonts/Groff"
-TEXTMAP="$T1_FONTDIR/textmap"
-TEXTENC="$T1_FONTDIR/text.enc"
-
-echo -n "Family directory name: "
-read FAMILYDIR
-
-if [ ! -d "$T1_FONTDIR/$FAMILYDIR" ] ; then
-  echo "Creating $FAMILYDIR in $T1_FONTDIR"
-  mkdir $T1_FONTDIR/$FAMILYDIR
-fi
-
-echo -n "Groff name for this font: "
-read FONTNAME
-
-echo "Creating .pfb and .afm files from $FONT.ttf"
-(ttf2pt1 \-b $FONT.ttf)
-
-echo "Moving .afm and .pfb file to $T1_FONTDIR/$FAMILYDIR.."
-mv $FONT.afm $T1_FONTDIR/$FAMILYDIR
-mv $FONT.pfb $T1_FONTDIR/$FAMILYDIR
-
-echo "Changing to $T1_FONTDIR/$FAMILYDIR.."
-cd $T1_FONTDIR/$FAMILYDIR
-
-echo "Creating $FONTNAME.."
-afmtodit -e $TEXTENC $T1_FONTDIR/$FAMILYDIR/$FONT.afm $TEXTMAP $FONTNAME
-mv -i $FONTNAME $GROFF_FONTS
-echo "Linking $FONTNAME in $GROFF_SITE_FONTDIR.."
-sudo ln -s $GROFF_FONTS/$FONTNAME $GROFF_SITE_FONTDIR/$FONTNAME
-
-echo "Linking $FONT.pfb and $FONT.afm in $GS_FONTDIR.."
-cd $GS_FONTDIR
-sudo ln -s $T1_FONTDIR/$FAMILYDIR/$FONT.afm $FONT.afm
-sudo ln -s $T1_FONTDIR/$FAMILYDIR/$FONT.pfb $FONT.pfb
+In addition, unless you're installing fonts from your home
+directory, make links to the files 'generate-t42.pe' and
+'generate-pfa.pe'.
+<br/>
+<span class="pre-in-pp">
+  ln -s $HOME/generate-t42.pe .
+  ln -s $HOME/generate-pfa.pe .
+</p>
+
+<h3 id="step-3" class="docs appendices">Step 3: Convert the font and put it in 
the right place</h3>
+
+<p class="top">
+TrueType fonts (.ttf) need to be converted to .t42.  Type 1 fonts
+(.pfb) need to be converted to .pfa.
+</p>
 
-echo "Font installation complete"
+<h4 id="ttf" class="docs" style="font-size: 90%; text-transform: 
uppercase;">&nbsp;&bullet;&nbsp;TTF Fonts</h4>
 
-exit 0
+<p class="top" style="margin-top: .5em;">
+For .ttf fonts, run
+<br/>
+<span class="pre-in-pp">
+  fontforge -script generate-t42.pe &lt;file&gt;.ttf
 </span>
-</div>
+This will create three new files with the extensions .t42, .pfa, and
+.afm.  Next, run
+<br/>
+<span class="pre-in-pp">
+  afmtodit &lt;afm file&gt; textmap &lt;groff font&gt;
+</span>
+This will create a groff font with the name you give.  (See
+<a href="#groff-font-names">here</a>
+for advice on naming groff fonts.)
+</p>
+
+<p>
+Move the .t42 and groff font files to
+<kbd>&lt;prefix&gt;/site-font/devps/</kbd>.
+</p>
+
+<p>
+If you're running a recent version of groff that includes
+the native pdf device (gropdf), move the .pfa file to
+<kbd>&lt;prefix&gt;/&lt;version&gt;/font/devpdf/</kbd>.  If not, you
+may safely remove it.  You may also safely remove the .afm file.
+</p>
+
+<h4 id="type1" class="docs" style="font-size: 90%; text-transform: 
uppercase;">&nbsp;&bullet;&nbsp;Type1 Fonts</h4>
+
+<p class="top" style="margin-top: .5em;">
+For .pfb fonts, run
+<br/>
+<span class="pre-in-pp">
+  fontforge -script generate-pfa.pe &lt;file&gt;.ttf
+</span>
+This will create two new files with the extensions .pfa, and .afm.
+Next, run
+<br/>
+<span class="pre-in-pp">
+  afmtodit &lt;afm file&gt; textmap &lt;groff font&gt;
+</span>
+Move the .pfa and groff font files to
+<kbd>&lt;prefix&gt;/&lt;site-font&gt;/devps/</kbd>.
+(See
+<a href="#groff-font-names">here</a>
+for advice on naming groff fonts.)
+</p>
+
+<p>
+If you're running a recent version of groff that includes the
+native pdf device (gropdf), link the .pfa and groff font files,
+now in <kbd>&lt;prefix&gt;/&lt;site-font&gt;/devps/</kbd>,
+to the devpdf directory</kbd>.  Start by changing into the
+<kbd>&lt;prefix&gt;/&lt;version&gt;/font/devpdf/</kbd> directory,
+then:
+<br/>
+<span class="pre-in-pp">
+  ln -s &lt;prefix&gt;/&lt;version&gt;/font/devps/&lt;file&gt;.pfa .
+  ln -s &lt;prefix&gt;/&lt;version&gt;/font/devps/&lt;groff font&gt; .
+</span>
+You may safely remove the .afm file.
+</p>
+
+<h3 id="step-4" class="docs appendices">Step 4: Update the download file</h3>
+
+<h4 id="internal" class="docs" style="font-size: 90%; text-transform: 
uppercase;">&nbsp;&bullet;&nbsp;Get the internal font name</h4>
+
+<p class="top" style="margin-top: .5em;">
+Inspect your new groff font file.  Near the top, you will see a line
+of the form
+<br/>
+<span class="pre-in-pp">
+  internalname &lt;name&gt;
+</span>
+Usually, the internal name is helpfully descriptive, eg,
+<br/>
+<span class="pre-in-pp">
+  internalname Optima-Bold
+</span>
+Make a note of the internal name.
+</p>
+
+<h4 id="add" class="docs" style="font-size: 90%; text-transform: 
uppercase;">&nbsp;&bullet;&nbsp;Add the font to the download file</h4>
+
+<p class="top" style="margin-top: .5em;">
+Open the file <kbd>&lt;prefix&gt;/&lt;version&gt;/font/devps/download</kbd>.
+In it you will see lines of the form
+<br/>
+<span class="pre-in-pp">
+  Symbol-Slanted       symbolsl.pfa
+  ZapfDingbats-Reverse zapfdr.pfa
+  FreeEuro             freeeuro.pfa
+</span>
+where the spaces are the tab character from the keyboard, not
+literal spaces.  Thus,
+<br/>
+<span class="pre-in-pp">
+  Symbol-Slanted       symbolsl.pfa
+</span>
+is really
+<br/>
+<span class="pre-in-pp">
+  Symbol-Slanted&lt;tab&gt;symbolsl.pfa
+</span>
+</p>
+
+<p>
+The download file maps the internal names used by groff to the
+actual fonts.  To add your new font to the download file, append a
+line containing the internal name, followed by a tab (make sure your
+text editor is inserting the tab character, not spaces), followed by
+the .t42 or .pfa font to which the internal name refers.
+</p>
+
+<p>
+For example, if the internal name is Optima-Bold and the font is a
+.pfa file called Optima-Bold.pfa, your updated download file will
+contain
+<br/>
+<span class="pre-in-pp">
+  Optima-Bold&lt;tab&gt;Optima-Bold.pfa
+</span>
+</p>
+
+<h4 id="gropdf-download" class="docs" style="font-size: 90%; text-transform: 
uppercase;">&nbsp;&bullet;&nbsp;Updating the gropdf download file</h4>
+
+<p class="top" style="margin-top: .5em;">
+If you're running a recent version of groff that includes the
+native pdf device (gropdf), you must update its download file as
+well, which is found in <kbd>&lt;prefix&gt;/&lt;version&gt;/font/devpdf/</kbd>.
+The instructions are identical to those above, but with one important
+difference: all lines must begin with a tab character.  Thus, using
+our Optima example, your devpdf download line for the same font is
+<br/>
+<span class="pre-in-pp">
+  &lt;tab&gt;Optima-Bold&lt;tab&gt;Optima-Bold.pfa
+</span>
+</p>
+
+<h3 id="groff-font-names" class="docs appendices">Naming groff fonts</h3>
+ 
+<p class="top">
+For convenience when using mom, and to keep your font collection
+organized, choose meaningful groff font names following the scheme
+&lt;Family&gt;&lt;FONT&gt;, where Family is something
+like Optima or Univers or Clarendon, and FONT is either
+<br/>
+<span style="display: block; margin-left: 2em;">
+<kbd>R&nbsp;&nbsp;</kbd>(roman/regular)
+<br/>
+<kbd>I&nbsp;&nbsp;</kbd>(italic)
+<br/>
+<kbd>B&nbsp;&nbsp;</kbd>(bold)
+<br/>
+<kbd>BI&nbsp;</kbd>(bold italic)
+</span>
+or one of the 1&ndash;5 character fontstyles listed
+<a href="#style-extensions">here</a>.
+Thus, for the fonts Optima Light Italic and Optima Extra Black, your font 
names would be
+<br/>
+<span class="pre-in-pp">
+  OptimaLI
+  OptimaXBL
+</span>
+This scheme allows you to enter <kbd>.FAMILY&nbsp;Optima</kbd> to make
+Optima the current family, and <kbd>.FT&nbsp;LI</kbd> or 
<kbd>.FT&nbsp;XBL</kbd>
+when you need the fonts Light Italic or Extra Black.
+</p>
+
+<p>
+Groff font names are, in fact, arbitrary; you can call your fonts
+anything you like, provided the
+<a href="#internal">internal name</a>
+in the
+<a href="#add">download file</a>
+matches the internal name found in the groff font file.  When
+calling a font that does not follow the recommended naming convention,
+you must pass the full font name to <kbd>.FT</kbd> whenever you wish
+to use it.
+</p>
+
+<p>
+For example, the font, Goudy Stout, isn't really part of the
+Goudy family, and while "stout" describes it, Stout is not a
+recognized font style.  Therefore, its groff name could simply be
+GoudyStout, and whenever you needed it, you could call it with
+<kbd>.FT&nbsp;GoudyStout</kbd>.
+</p>
+
+<h3 id="install-font" class="docs appendices">Automate the whole process 
&ndash; the install-font script</h3>
+
+<p>
+A bash script to make the entire process of installing fonts a
+painless no-brainer has been posted online at
+<a 
href="http://www.schaffter.ca/mom/install-font";>http://www.schaffter.ca/mom/install-font</a>.
+Be sure to make the script executable
+(<kbd>chmod 755 install-font</kbd>)
+after you download it, then type <kbd>./install-font -H</kbd> for
+usage.
+</p>
 
 <div class="rule-medium" style="margin-top: 2em;"><hr/></div>
 
@@ -708,7 +813,7 @@
 
 <p>
 However, groff has always had a liability: it&#8217;s incredibly geeky.
-Owing to its very long history, it&mdash;and its &#8220;power users&#8221;
+Owing to its very long history, it&mdash;and its power users
 &mdash;seem to have remained stuck in a time warp.  The canonical  macro 
packages
 still look as they did back in those decades when memory was exorbitantly
 expensive and every byte mattered.
@@ -741,11 +846,11 @@
 
 <div class="box-tip">
 <p class="tip">
-<span class="note">Addendum:</span>
-As of version 1.4-a, the main macro file, om.tmac, is now stripped
-of comments when groff is built from sources. om.tmac in the sources
-themselves still contains the comments, as do the tarballs posted on
-mom&#8217;s homepage.
+<span class="note">Note:</span>
+The main macro file, <strong>om.tmac</strong>, is stripped of
+comments when groff is built from sources. <strong>om.tmac</strong>,
+in the sources themselves, still contains the comments, as do the
+tarballs posted on mom&#8217;s homepage.
 </p>
 </div>
 
@@ -760,15 +865,15 @@
 make, criticisms to offer, or bugs to report, use the groff mailing
 list (subscription information available
 <a href="http://www.gnu.org/software/groff/groff.html";>here</a>)
-or contact me, Peter Schaffter,  directly at of the following
+or contact me, Peter Schaffter,  directly at the following
 address:
 <br/>
 <span class="pre-in-pp">
   
&#112;&#101;&#116;&#101;&#114;&#64;&#115;&#99;&#104;&#97;&#102;&#102;&#116;&#101;&#114;&#46;&#99;&#97;
 </span>
 Please include the word &#8220;mom&#8221; or &#8220;groff&#8221; in
-the Subject: line of any message sent to my personal address, or you
-risk the wrath of my implacable spam filters. :)
+the Subject line of any message sent to my personal address or you
+risk the wrath of my implacable spam filters.
 </p>
 
 <p>
@@ -788,8 +893,7 @@
 <table style="width: 100%; margin-top: 12px;">
 <tr>
   <td style="width: 33%;"><a href="toc.html">Back to Table of Contents</a></td>
-  <td style="width: 33%; text-align: center;"><a href="#top">Top</a></td>
-  <td style="width: 33%; text-align: right;"><a href="reserved.html">Next: 
Reserved words</a></td>
+  <td style="width: 100%; text-align: right;"><a href="#top">Top</a></td>
 </tr>
 </table>
 

Index: momdoc/color.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/color.html,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -b -r1.14 -r1.15
--- momdoc/color.html   22 Feb 2011 19:42:29 -0000      1.14
+++ momdoc/color.html   31 Aug 2012 22:49:58 -0000      1.15
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 

Index: momdoc/cover.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/cover.html,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- momdoc/cover.html   22 Feb 2011 19:42:29 -0000      1.16
+++ momdoc/cover.html   31 Aug 2012 22:49:58 -0000      1.17
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -70,9 +72,8 @@
 
 <p>
 Though identical in treatment, mom provides two kinds of cover
-pages: section cover pages (which I shall refer to simply as
-cover pages) and document cover pages (&#8221;doc
-covers&#8221;).
+pages: document cover pages (&#8221;doc covers&#8221;), and section
+cover pages (which I shall refer to simply as cover pages).
 </p>
 
 <p>
@@ -86,7 +87,7 @@
 
 <p>
 A cover is what you&#8217;d use for pages that separate sections
-of a collated document, i.e. title pages.  A cover page (but not a
+of a collated document, ie title pages.  A cover page (but not a
 doc cover) in a collated document could, for example, simply read:
 &#8221;PART 1&#8221;.
 </p>
@@ -137,7 +138,7 @@
 and/or
 <a href="#cover">DOC_COVER</a>.
 Provided you have already given mom the appropriate reference macros
-(e.g.
+(eg
 <a href="docprocessing.html#title">TITLE</a>
 or
 <a href="docprocessing.html#author">AUTHOR</a>),
@@ -238,16 +239,17 @@
 </div>
 
 <div style="margin-top: .5em; padding-bottom: 3px; white-space: nowrap; 
overflow: auto;">
-<b><a href="#optional-args">Optional arguments:</a></b> <kbd 
class="macro-args">[ SUBTITLE AUTHOR DOCTYPE COPYRIGHT MISC BLANKPAGE ]</kbd>
+<b><a href="#optional-args">Optional arguments:</a></b> <kbd 
class="macro-args">[ SUBTITLE AUTHOR DOCTYPE COPYRIGHT MISC BLANKPAGE 
PDF_OUTLINE_LABEL &lt;label&gt; ]</kbd>
 </div>
 
 <div class="box-tip">
 <p class="tip">
 <span class="note">Note:</span>
-These macros should be placed in the
-&#8220;style-sheet&#8221; section of your document setup (see
+These macros should be placed in the style sheet section of your
+document setup (see
 <a href="docprocessing.html#docprocessing-tut">Tutorial &ndash; Setting up a 
mom document</a>),
-i.e. after PRINTSTYLE (and/or DOCTYPE and/or COPYSTYLE), but before START.
+ie after PRINTSTYLE (and/or DOCTYPE and/or COPYSTYLE), but before
+START.
 </p>
 </div>
 
@@ -275,7 +277,7 @@
 <p>
 Both COVER and DOC_COVER, whenever invoked, require a first
 argument, as listed above.  This first argument will become the
-first bit of information mom prints on the cover or doc cover (i.e.
+first bit of information mom prints on the cover or doc cover (ie
 the title).
 </p>
 
@@ -377,27 +379,8 @@
 DOC_COVER are optional.  They refer specifically to
 the information you gave the
 <a href="docprocessing.html#reference-macros">reference macros</a>
-bearing the same name as the arguments.
-</p>
-
-<p>
-You may enter as many or as few as you would like to see on your
-cover or doc cover.  The only hitch is&mdash;pay attention,
-class&mdash;they must be entered in the order given above.
-For example, if you want <kbd>TITLE</kbd>, <kbd>AUTHOR</kbd>,
-<kbd>COPYRIGHT</kbd> and <kbd>MISC</kbd>
-<br/>
-<span class="pre-in-pp">
-    .COVER TITLE AUTHOR COPYRIGHT MISC
-</span>
-
-is correct, while
-<br/>
-<span class="pre-in-pp">
-    .COVER TITLE AUTHOR MISC COPYRIGHT
-</span>
-
-is not.
+bearing the same name as the arguments.  You may enter as many or as
+few as you like, in any order.
 </p>
 
 <h5 id="doctype" class="docs" style="text-transform: none; margin-top: 
-.5em;">What the DOCTYPE argument means</h5>
@@ -438,6 +421,16 @@
 invisible to mom's pagination.
 </p>
 
+<h5 id="pdf-label" class="docs" style="text-transform: none; margin-top: 
-.5em;">What the PDF_OUTLINE_LABEL argument means</h5>
+
+<p>
+By default, mom identifies doccovers in the outline panel of PDF
+viewers with the prepended string, &#8220;Cover:&#8221;, and covers
+with the string &#8220;Title Page:&#8221;.  If you would like
+to change the strings, pass the <kbd>PDF_OUTLINE_LABEL</kbd>
+argument to COVER or DOCCOVER, along with the new string.
+</p>
+
 <!-- -ENABLING/DISABLING- -->
 
 <div class="macro-id-overline">

Index: momdoc/definitions.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/definitions.html,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -b -r1.19 -r1.20
--- momdoc/definitions.html     22 Feb 2011 19:42:29 -0000      1.19
+++ momdoc/definitions.html     31 Aug 2012 22:49:58 -0000      1.20
@@ -2,8 +2,8 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011, 2012 Free Software 
Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +14,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -131,9 +132,10 @@
         <a href="#header">Header</a><br/>
         <a href="#linebreak">Linebreak</a><br/>
         <a href="#parahead">Paragraph head</a><br/>
+        <a href="#pdflink">PDF link</a><br/>
+        <a href="#pdfoutline">PDF outline</a><br/>
         <a href="#quote">Quote</a><br/>
         <a href="#running">Running text</a><br/>
-        <a href="#subhead">Subhead</a><br/>
         <a href="#toggle">Toggle</a><br/>
       </td>
     </tr>
@@ -193,10 +195,7 @@
   Discretionary hyphens make sure it does.  In the event that the
   word doesn&#8217;t need to be hyphenated at all, groff leaves them
   alone.  In groff, the discretionary hyphen is entered with
-  
-  <span class="pre" style="margin-bottom: -2em;">
-  \%  (backslash followed by a percent)
-  </span>
+  <kbd>\%</kbd> (ie, a backslash followed by the percent sign).
   </dd>
   
   <dt id="dropcap">Drop cap</dt>
@@ -219,7 +218,7 @@
   <a href="#font">font</a>.
   Since most Ms are designed square, an em is usually (but
   sometimes erroneously) considered to be the same size as the
-  current point size (i.e. if the point size of the type is 12,
+  current point size (ie if the point size of the type is 12,
   one em equals 12 points).  An en is equal to the width of a
   letter N (historically 2/3 of an em, although groff treats an en
   as 1/2 of an em).  Typically, ems and ens are used to measure
@@ -230,7 +229,7 @@
   <dd>
   The collective name by which a collection of
   <a href="#font">fonts</a>
-  are known, e.g.  Helvetica, Times Roman, Garamond.
+  are known, eg Helvetica, Times Roman, Garamond.
   </dd>
   
   <dt id="figurespace">Figure space/Digit space</dt>
@@ -239,11 +238,7 @@
   <a href="#fixedwidthspace">fixed width space</a>
   that has the width of one digit.  Used for aligning numerals in,
   say, columns or numbered lists.  In groff, the figure space is
-  entered with
-  
-  <span class="pre" style="margin-bottom: -2em;">
-  \0  (backslash followed by a zero)
-  </span>
+  entered with <kbd>\0</kbd> (ie a backslash followed by a zero)
   </dd>
   
   <dt id="fixedwidthfont">Fixed width font</dt>
@@ -260,9 +255,7 @@
   but does not expand or contract when text is
   <a href="#just">justified</a>.
   In groff, fixed width space is entered with
-  
-  <span class="pre" style="margin-bottom: -2em;">
-  \&lt;space&gt; (backslash followed by hitting the spacebar)
+  <kbd>\&lt;space&gt;</kbd> (ie a backslash followed by a space)
   </span>
   </dd>
   
@@ -274,7 +267,7 @@
   <a href="#shape">shape</a>
   of type within a
   <a href="#family">family</a>,
-  e.g. light, medium, bold (which are weights), and roman, italic,
+  eg light, medium, bold (which are weights), and roman, italic,
   condensed (which are shapes).  By default, groff knows of four
   fonts within its default set of families: R (medium roman), I
   (medium italic), B (bold roman) and BI (bold italic).
@@ -436,13 +429,13 @@
   </p>
 
   <ul style="margin-top: -.5em; margin-bottom: -.5em">
-      <li>&#8220;Roman&#8221;, which has no slant, and has letterforms of
+      <li>Roman, which has no slant, and has letterforms of
           average width</li>
-      <li>&#8220;Italic&#8221;, which is slanted, and has letterforms
+      <li>Italic, which is slanted, and has letterforms
           of average width</li>
-      <li>&#8220;Condensed&#8221;, which has no slant, but has
+      <li>Condensed, which has no slant, but has
           letterforms narrower than the average represented by Roman</li>
-      <li>&#8220;Condensed Italic&#8221;, which is slanted, with letterforms 
narrower
+      <li>Condensed Italic, which is slanted, with letterforms narrower
           than average</li>
   </ul>
 
@@ -460,7 +453,7 @@
   <dd>
   When no
   <a href="#leading">lead</a>
-  is added between lines of type (i.e. the
+  is added between lines of type (ie the
   <a href="#ps">point size</a>
   and linespacing are the same), the lines are said to be &#8220;set
   solid.&#8221;
@@ -484,11 +477,8 @@
   kept together on the same line.  Expands and contracts like word
   space.  Useful for proper names, which one should, whenever
   possible, avoid splitting onto two lines.  In groff, unbreakable
-  space is entered with
-  
-  <span class="pre" style="margin-bottom: -2em;">
-   \~  (backslash followed by a tilde)
-  </span>
+  space is entered with <kbd>\~</kbd> (ie a backslash followed by a
+  tilde)
   </dd>
   
   <dt id="weight">Weight</dt>
@@ -499,7 +489,7 @@
   strokes slightly thinner than Medium or Book, but is still
   acceptable for most text.  Semibold, Bold, Heavy and Black all
   have strokes of increasing thickness, making them suitable for
-  heads, subheads, headlines and the like.
+  headings and the like.
   </dd>
   
   <dt id="wordspace">Word space</dt>
@@ -561,14 +551,10 @@
   <dt id="commentlines">Comment Lines</dt>
   <dd>
   <a href="#inputline">Input lines</a>
-  introduced with the comment character
-  
-  <span class="pre" style="margin-bottom: -2em;">
-  \#  (backslash followed by the pound sign)
-  </span>
-  
-  When processing output, groff silently ignores everything on a
-  line that begins with the comment character.
+  introduced with the comment character <kbd>\#</kbd> (ie a
+  backslash followed by the pound sign).  When processing output,
+  groff silently ignores everything on a line that begins with the
+  comment character.
   </dd>
   
   <dt id="controllines">Control Lines</dt>
@@ -764,7 +750,7 @@
 
   <p style="margin-top: -1em;">
   Units of measure must come immediately after the numeric
-  argument (i.e. with no space between the argument and the unit
+  argument (ie with no space between the argument and the unit
   of measure), like this:
   
   <span class="pre" style="margin-bottom: -2em;">
@@ -793,7 +779,7 @@
   
   <p>
   You can enter decimal values for any unit of measure.  Different
-  units may be combined by adding them together (e.g. 1.5i+2m,
+  units may be combined by adding them together (eg 1.5i+2m,
   which gives a measure of 1-1/2 inches plus 2 ems).
   </p>
   
@@ -821,7 +807,7 @@
   It looks like this:
   
   <span class="pre" style="margin-bottom: -2em;">
-  \&amp; (backslash followed by an ampersand)
+  \&amp; (ie a backslash followed by an ampersand)
   </span>
   
   Normally, groff interprets a period (or an apostrophe) at the
@@ -830,7 +816,7 @@
   In fill modes, groff treats a space at the beginning of an input
   line as meaning &#8220;start a new line and put a space at the
   beginning of it.&#8221; If you want groff to interpret periods
-  and apostrophes at the beginning of input lines literally (i.e.
+  and apostrophes at the beginning of input lines literally (ie
   print them), or spaces at the beginning of input lines as just
   garden variety word spaces, you must start the line with the
   zero-width character.
@@ -852,8 +838,8 @@
   <dd>
   Macros used in
   <a href="docprocessing.html#docprocessing">document processing</a>
-  to control/alter the appearance of document elements (e.g.
-  heads, quotes, footnotes,
+  to control/alter the appearance of document elements (eg
+  headings, quotes, footnotes,
   <a href="#header">headers</a>,
   etc.).
   </dd>
@@ -873,20 +859,22 @@
   <dt id="footer">Footer/page footer</dt>
   <dd>
   Document information (frequently author and title) output in
-  the bottom margin of pages <em>after</em> page one.  Not to be
+  the bottom margin of pages after page one.  Not to be
   confused with footnotes, which are considered part of
   <a href="#running">running text</a>.
   </dd>
   
-  <dt id="head">Head</dt>
+  <dt id="head">Heading</dt>
   <dd>
-  A title that introduces a major section of a document.
+  The title used to identify a section of a document.  Headings
+  are hierarchic, corresponding to the notion of head, subhead,
+  subsubhead, etc.
   </dd>
   
   <dt id="header">Header/page header</dt>
   <dd>
   Document information (frequently author and title) output in the
-  top margin of pages <em>after</em> page one.
+  top margin of pages after page one.
   
   <div class="box-tip" style="margin-right: 2.5em;">
     <p class="tip">
@@ -907,21 +895,34 @@
   <a href="#running">running text</a>,
   frequently set off by typographic symbols such as asterisks or
   daggers.  Used to indicate a shift in the content of a document
-  (e.g. a scene change in a short story).  Also commonly called a
+  (eg a scene change in a short story).  Also commonly called a
   scene break or a section break.
   </dd>
   
   <dt id="parahead">Paragraph head</dt>
   <dd>
-  A title joined to the body of a paragraph; hierarchically one
-  level beneath
-  <a href="#subhead">subheads</a>.
+  A heading joined to the body of a paragraph.
+  </dd>
+  
+  <dt id="pdflink">PDF link</dt>
+  <dd>
+  A portion of text that, when clicked on in a PDF viewer,
+  navigates to a bookmarked location in a document, generally but not
+  exclusively a heading.  PDF links are usually coloured to make
+  them stand out from the surrounding text.
+  </dd>
+
+  <dt id="pdfoutline">PDF outline</dt>
+  <dd>
+  The hierarchically-arranged navigation outline provided by most PDF
+  viewers (eg Okular, Evince), typically in a panel to the left of
+  the document window, and usually labeled &#8220;Contents&#8221;.
   </dd>
   
   <dt id="quote">Quote</dt>
   <dd>
   A quote, to mom, is a line-for-line setting
-  of quoted material (e.g. poetry, song lyrics, or a snippet of
+  of quoted material (eg poetry, song lyrics, or a snippet of
   programming code).  You don&#8217;t have to use
   <a href="typesetting.html#br"><kbd>BR</kbd></a>
   with quotes.
@@ -931,20 +932,13 @@
   <dd>
   In a document formatted with mom, running
   text means text that forms the body of the document, including
-  elements such as heads and subheads.
+  elements such as headings.
   <a href="#docheader">Docheaders</a>,
   <a href="#header">headers</a>,
   <a href="#footer">footers</a>
   and page numbers are not part of running text.
   </dd>
   
-  <dt id="subhead">Subhead</dt>
-  <dd>
-  A title used to introduce secondary sections of a document;
-  hierarchically one level beneath sections introduced by
-  <a href="#head">heads</a>.
-  </dd>
-  
   <dt id="toggle">Toggle</dt>
   <dd>
   A macro or tag that, when invoked without an argument, begins

Index: momdoc/docelement.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/docelement.html,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -b -r1.38 -r1.39
--- momdoc/docelement.html      22 Feb 2011 19:42:29 -0000      1.38
+++ momdoc/docelement.html      31 Aug 2012 22:49:58 -0000      1.39
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -72,25 +74,11 @@
   <li><a href="#pp">PP</a></li>
   <li><a href="#pp-control">Paragraph control</a></li>
 </ul>
-<h3 class="toc toc-docproc-header"><a class="header-link" 
href="#head-intro">Main heads</a></h3>
-<ul class="toc-docproc" style="margin-top: .5em;">
-  <li><a href="#head">HEAD</a></li>
-  <li><a href="#head-control">Head control</a></li>
-</ul>
-<h3 class="toc toc-docproc-header"><a class="header-link" 
href="#subhead-intro">Subheads</a></h3>
+<h3 class="toc toc-docproc-header"><a class="header-link" 
href="#heading-intro">Headings</a></h3>
 <ul class="toc-docproc" style="margin-top: .5em;">
-  <li><a href="#subhead">SUBHEAD</a></li>
-  <li><a href="#subhead-control">Subhead control</a></li>
-</ul>
-<h3 class="toc toc-docproc-header"><a class="header-link" 
href="#subsubhead-intro">Subsubheads</a></h3>
-<ul class="toc-docproc" style="margin-top: .5em;">
-  <li><a href="#subsubhead">SUBSUBHEAD</a></li>
-  <li><a href="#subsubhead-control">Subsubhead control</a></li>
-</ul>
-<h3 class="toc toc-docproc-header"><a class="header-link" 
href="#parahead-intro">Paragraph heads</a></h3>
-<ul class="toc-docproc" style="margin-top: .5em;">
-  <li><a href="#parahead">PARAHEAD</a></li>
-  <li><a href="#parahead-control">Parahead control</a></li>
+  <li><a href="#heading">HEADING</a></li>
+  <li><a href="#heading-control">Heading control</a></li>
+  <li><a href="#oldstyle-headings-intro">Oldstyle headings</a></li>
 </ul>
 <h3 class="toc toc-docproc-header"><a class="header-link" 
href="#linebreak-intro">Linebreaks (section breaks)</a></h3>
 <ul class="toc-docproc" style="margin-top: .5em;">
@@ -107,13 +95,13 @@
   <li><a href="#blockquote">BLOCKQUOTE</a></li>
   <li><a href="#blockquote-control">Blockquote control</a></li>
 </ul>
-</div>
-<div class="mini-toc-col-2" style="margin-top: 1.5em;">
 <h3 class="toc toc-docproc-header"><a class="header-link" 
href="#code-intro">Inserting code snippets</a></h3>
 <ul class="toc-docproc" style="margin-top: .5em;">
   <li><a href="#code">CODE</a></li>
   <li><a href="#code-control">Code control</a></li>
 </ul>
+</div>
+<div class="mini-toc-col-2" style="margin-top: 1.5em;">
 <h3 class="toc toc-docproc-header"><a class="header-link" 
href="#list-intro">Nested lists</a></h3>
 <ul class="toc-docproc" style="margin-top: .5em;">
   <li><a href="#list">LIST</a></li>
@@ -137,9 +125,8 @@
 </ul>
 <h3 class="toc toc-docproc-header"><a class="header-link" 
href="#margin-notes-intro">Margin notes</a></h3>
 <ul class="toc-docproc" style="margin-top: .5em;">
-  <li><a href="#mn-init">MN_INIT</a></li>
+  <li><a href="#mn-init">MN_INIT (set margin notes parameters)</a></li>
   <li><a href="#mn">MN</a></li>
-  <li><a href="#margin-notes-control">Margin notes control</a></li>
 </ul>
 <h3 class="toc toc-docproc-header"><a class="header-link" 
href="#finis-intro">Document termination string</a></h3>
 <ul class="toc-docproc" style="margin-top: .5em;">
@@ -158,23 +145,16 @@
 <a href="docprocessing.html#docprocessing-tut">Setting up a mom document</a>),
 formatting it is a snap.  Simply invoke the appropriate tag for
 each document element as you need it.  The tags are macros that
-tell mom: &#8220;This is a paragraph; this is a subhead; this is a
+tell mom: &#8220;This is a paragraph; this is a heading; this is a
 footnote,&#8221; and so on.
 </p>
 
 <p>
-The list of tags is actually quite small&mdash;ideal for the users
-mom brought herself into being for (see
-<a href="intro.html#intro-intro">Who mom is meant for</a>).
-However, the list of macros that control the appearance of the tags
-upon output is extensive.  Generally, for each tag, there are
+Generally, for each tag, there are
 <a href="definitions.html#controlmacro">control macros</a>
 for the tag&#8217;s family, font and point size.  Where appropriate,
 there are macros to control leading, indents, quad and special
 features as well.
-</p>
-
-<p>
 Mom has tasteful defaults for all the tags, hence you only use the
 control macros when you want to change the way she does things.
 This is usually done prior to
@@ -203,7 +183,7 @@
 
 <p>
 The control macros may be used at any time during the course of a
-document (i.e. before or after
+document (ie before or after
 <a href="docprocessing.html#start">START</a>).
 The changes you make alter all subsequent invocations of the
 affected tag until you make another change, either by passing new
@@ -244,8 +224,7 @@
 The family, font, point size, colour and leading control macros have
 no effect in
 <a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>,
-which sets everything in Courier roman, 12/24 (i.e. 12-point type on
-a linespace of 24 points).
+except where noted throughout this documentation.
 </p>
 
 <p class="tip-bottom">
@@ -276,11 +255,11 @@
 &lt;n&gt; is the number of
 <a href="definitions.html#picaspoints">points</a>
 larger (+) or smaller (-) than the point size of paragraphs
-you want the document element to be.  For example, to change
-subheads to 1-1/2 points larger than the type in paragraphs, do
+you want the document element to be.  For example, to set
+blockquotes 2 points smaller than the type in paragraphs, do
 <br/>
 <span class="pre-in-pp">
-  .SUBHEAD_SIZE +1.5
+  .BLOCKQUOTE_SIZE -2
 </span>
 There&#8217;s no need for a
 <a href="definitions.html#unitofmeasure">unit of measure</a>
@@ -295,13 +274,14 @@
 <a href="color.html#newcolor">NEWCOLOR</a>
 or
 <a href="color.html#xcolor">XCOLOR</a>.
-For example, if you want your heads to be red, once you&#8217;ve defined
-or initialized the color, red,
+For example, if you want your
+<a href="#linebreak">author linebreaks</a>
+to be red, once you&#8217;ve defined or initialized the colour, red,
 <br/>
 <span class="pre-in-pp">
-  .HEAD_COLOR red
+  .LINEBREAK_COLOR red
 </span>
-will turn your heads red.
+will turn them red.
 </p>
 
 <h4 id="lead" class="docs" style="margin-top: -.5em; margin-bottom: 
-.75em;">Lead/linespacing</h4>
@@ -318,7 +298,7 @@
 <span class="pre-in-pp">
   .FOOTNOTE_AUTOLEAD 0
 </span>
-To set footnotes with a 1-point lead (i.e. with the line spacing
+To set footnotes with a 1-point lead (ie with the line spacing
 one point greater than the footnote&#8217;s point size), do
 <br/>
 <span class="pre-in-pp">
@@ -357,8 +337,8 @@
   .PARA_INDENT       2m
   .BLOCKQUOTE_INDENT 2
 </span>
-means that blockquotes will be indented from the left margin by
-twice the size of the paragraph indent, or 4
+means that blockquotes will be indented from the left and right
+margins by twice the size of the paragraph indent, or 4
 <a href="definitions.html#em">ems</a>.
 </p>
 
@@ -396,7 +376,7 @@
 <p>
 Page elements that are separated from
 <a href="definitions.html#running">running text</a>
-by a rule (i.e. page headers, page footers and footnotes) are
+by a rule (ie page headers, page footers and footnotes) are
 controlled by macros that end in _RULE_WEIGHT.
 </p>
 
@@ -467,8 +447,8 @@
 
 <p>
 If a block-style epigraph runs to more than one paragraph (unlikely,
-but conceivable), you <i>must</i> introduce every
-paragraph&mdash;including the first&mdash;with the
+but conceivable), you must introduce every paragraph&mdash;including
+the first&mdash;with the
 <a href="#pp">PP</a>
 tag.
 </p>
@@ -476,19 +456,38 @@
 <div class="box-tip">
 <p class="tip">
 <span class="note">Note:</span>
-EPIGRAPH should only be used at the top of a document (i.e. just
+EPIGRAPH should only be used at the top of a document (ie just
 after
 <a href="docprocessing.html#start">START</a>)
-or after
-<a href="#head-intro">heads</a>.
-The latter is not especially recommended, but it does work.  In all
-other places where you want quotes or cited text, use
+or after headings.  The latter is not especially recommended, but it
+does work.  In all other places where you want quotes or cited text,
+use
 <a href="#quote">QUOTE</a>
 or
 <a href="#blockquote">BLOCKQUOTE</a>.
 </p>
 </div>
 
+<div class="box-tip">
+<p class="tip">
+<span class="tip">Tip:</span>
+If you&#8217;re setting a document in
+<a href="docprocessing.html#columns">columns</a>
+and you&#8217;d like to add or subtract space after the epigraph,
+the place to do it is inside the epigraph, like this:
+<br/>
+<span class="pre-in-pp">
+  .EPIGRAPH
+  A notable quote.
+  .SP 1v
+  .EPIGRAPH OFF
+</span>
+If you were to add the <kbd>.SP 1v</kbd> outside the epigraph, the
+space would be added to the top of the leftmost column only,
+resulting in unbalanced columns.
+</p>
+</div>
+
 <div class="defaults-container" style="padding-bottom: 8px;">
 <h3 id="epigraph-control" class="docs defaults" style="margin-top: 
-.25em;">EPIGRAPH control macros and defaults</h3>
 
@@ -518,27 +517,16 @@
 <h3 id="epigraph-indent" class="docs notes" style="margin-bottom: 
-.75em;">Note on EPIGRAPH_INDENT</h3>
 
 <p style="margin-top: .5em;">
-Prior to version 1.4-b, mom allowed only the passing of an integer
-to the macro, EPIGRAPH_INDENT.  The integer represented the amount
-by which to multiply the argument passed to
-<a href="#para-indent">PARA_INDENT</a>
-to arrive at an indent for block style epigraphs.
-</p>
-
-<p>
-As of version 1.4-b, you can now append a
-<a href="definitions.html#unitofmeasure">unit of measure</a>
-to the argument passed to EPIGRAPH_INDENT, thus setting an absolute
-indent, relative to nothing.  The old behaviour is still respected,
-though; in other words, if you pass EPIGRAPH_INDENT an integer with
-no unit of measure appended, the integer represents the amount by
-which to multiply PARA_INDENT to arrive at an indent for block style
-epigraphs.
+If you pass EPIGRAPH_INDENT an integer with no unit of measure
+appended, the integer represents the amount by which to multiply
+PARA_INDENT to arrive at an indent for block style epigraphs.  If
+you append a unit of measure to the argument, the indent will be
+precisely the amount specified.
 </p>
 
 <p>
-Please also note that if your PARA_INDENT is <kbd>0</kbd> (i.e. no
-indenting of the first line of paragraphs), you <i>must</i> set an
+Please also note that if your PARA_INDENT is <kbd>0</kbd> (ie
+no indenting of the first line of paragraphs), you must set an
 EPIGRAPH_INDENT yourself, with a unit of measure appended to the
 argument. Mom has no default for EPIGRAPH_INDENT if paragraph first
 lines are not being indented.
@@ -574,29 +562,48 @@
 
 <p>
 By default, mom does not indent the first paragraph of a document,
-nor paragraphs that fall immediately after
-<a href="#head-intro">heads</a>
-or
-<a href="#subhead-intro">subheads</a>.
-The first paragraphs of blockquotes and block-style epigraphs are
-also not indented.  This behaviour can be changed with the control
-macro
+nor paragraphs that fall immediately after headings.  The first
+paragraphs of blockquotes and block-style epigraphs are also not
+indented.  This behaviour can be changed with the control macro
 <kbd><a href="#para-indent-first">INDENT_FIRST_PARAS</a></kbd>.
 </p>
 
 <p>
-In contrast to some other macro sets, mom does not deposit a blank
-line between paragraphs.  If you want her to do so, use the control
-macro PARA_SPACE.  (I don&#8217;t recommend using this macro with
+Mom does not deposit a blank line between paragraphs.  If you want
+her to do so, use the control macro
+<a href="#pp-space">PARA_SPACE</a>.
+(I don&#8217;t recommend using this macro with
 <a href="typesetting.html#printstyle">PRINTSTYLE TYPEWRITE</a>.)
 </p>
 
+<div class="box-tip">
+<p class="tip">
+<span class="tip">Tip:</span>
+If you'd like to add a small amount of space between paragraphs,
+less than the full linespace provided by PARA_SPACE, 
+you can create a macro that adds it automatically, like this:
+<br/>
+<span class="pre-in-pp">
+  .MAC PP2 END
+  .    ALD .25v
+  .    PP
+  .END
+</span>
+Introducing a paragraph with <kbd>.PP2</kbd> will add a space equal
+to one-quarter of the prevailing linespace before the start of the
+paragraph.  Initial paragraphs, ie those at the start of a document,
+or after a heading or
+<a href="#linebreak-intro">linebreak</a>,
+should still be introduced with
+<kbd>.PP</kbd>.
+</div>
+
 <p>
-Note that mom does not provide &#8220;orphan control&#8221; for
-paragraphs (i.e. even if only one line of a paragraph fits at the
+Note that mom does not provide widow or orphan control for
+paragraphs (ie even if only one line of a paragraph fits at the
 bottom of a page, she will set it on that page).  The reason for
 this is that writers of fiction often have single-line paragraphs
-(e.g. in dialogue).  Groff&#8217;s simplistic orphan control will
+(eg in dialogue).  Groff&#8217;s simplistic orphan control will
 break these one-liners&mdash;if they fall at the bottom of the
 page&mdash;to a new page, which is not what you want.
 </p>
@@ -652,7 +659,8 @@
 for more details.  In addition to regular text paragraphs, you can
 use PP in
 <a href="#epigraph-intro">epigraphs</a>,
-<a href="#blockquote-intro">blockquotes</a>
+<a href="#blockquote-intro">blockquotes</a>,
+<a href="#endnote-intro">endnotes</a>
 and
 <a href="#footnote-intro">footnotes</a>.
 </p>
@@ -674,7 +682,7 @@
   <li><a href="#pp-just-quad">Justification/quad control</a></li>
   <li><a href="#para-indent">First-line indent control</a></li>
   <li><a href="#para-indent-first">Initial paragraphs indent control</a></li>
-  <li><a href="#pp-space">Paragraph spacing control</a></li>
+  <li><a href="#pp-space">Inter-paragraph spacing</a></li>
 </ol>
 </div>
 
@@ -697,7 +705,13 @@
 If you wish to change the family for regular text paragraphs only,
 invoke <kbd>.FAMILY</kbd> immediately after <kbd>.PP</kbd> in every
 paragraph whose family you wish to differ from the prevailing
-document family.
+document family.  Alternatively, set the family and font for
+paragraphs with PP_FONT, giving it a complete family+font name, eg
+<br/>
+<span class="pre-in-pp">
+  PP_FONT TI
+</span>
+which would make the font used in paragraphs Times Roman Italic.
 </p>
 
 <p>
@@ -724,7 +738,8 @@
 <a href="docprocessing.html#start">START</a>.
 Only regular text paragraphs are affected; paragraphs in
 <a href="#epigraph-intro">epigraphs</a>,
-<a href="#blockquote-intro">blockquotes</a>
+<a href="#blockquote-intro">blockquotes</a>,
+<a href="#endnote-intro">endnotes</a>,
 and
 <a href="#footnote-intro">footnotes</a>
 remain at their default setting (medium roman) unless you change
@@ -758,7 +773,7 @@
 <a href="color.html#color">COLOR</a>,
 or the
 <a href="definitions.html#inline">inline escape</a>,
-<a href="color.html#color-inline"><kbd>\*[&lt;colorname&gt;]</kbd></a>,
+<a href="color.html#color-inline"><kbd>\*[&lt;colourname&gt;]</kbd></a>,
 <i>after</i> <kbd>.PP</kbd>.  The colour must be one pre-defined (or
 &#8220;initialized&#8221;) with
 <a href="color.html#newcolor">NEWCOLOR</a>
@@ -791,23 +806,6 @@
 paragraph will be in blue.
 </p>
 
-<p>
-The one document element that is affected by changing the colour of
-paragraphs is
-<a href="#parahead">paraheads</a>,
-since paraheads are attached directly to the body of paragraphs.
-In other words, if you change the colour of a paragraph and do not
-reset the paragraph colour back to its default, subsequent paraheads
-will appear in the same colour as your paragraphs unless you have
-explicitly told mom you want a pre-defined (or
-&#8220;initialized&#8221;) color (usually black) for your paraheads.
-</p>
-
-<p>
-See the footnote to
-<a href="#parahead-color">PARAHEAD_COLOR</a>.
-</p>
-
 <h4 id="pp-leading" class="docs" style="margin-top: -.25em;">4. Leading</h4>
 
 <p>
@@ -853,7 +851,7 @@
 <h4 id="pp-just-quad" class="docs" style="margin-top: -.25em;">5. 
Justification/quad</h4>
 
 <p>
-The justification/quad-direction of regular text paragraphs (i.e.
+The justification/quad-direction of regular text paragraphs (ie
 <a href="definitions.html#just">justified</a>,
 or
 <a href="definitions.html#filled">filled</a>
@@ -873,9 +871,10 @@
 <p>
 Please note that either method of setting the paragraph
 justification/quad-direction also affects
-<a href="#epigraph-intro">epigraphs</a>
-and
+<a href="#epigraph-intro">epigraphs</a>,
 <a href="#footnote-intro">footnotes</a>,
+and
+<a href="#endnote-intro">endnotes</a>,
 but not
 <a href="#blockquote-intro">blockquotes</a>
 (whose default is quad left unless you change it with
@@ -948,10 +947,12 @@
 
 <p>
 By default, mom does not indent the first paragraph of a document,
-nor the first paragraph after a head or subhead, nor the first
-paragraphs of
+nor the first paragraph after a heading or
+<a href="#linebreak-intro">linebreak</a>,
+nor the first paragraphs of
 <a href="#epigraph-intro">epigraphs</a>,
-<a href="#blockquote-intro">blockquotes</a>
+<a href="#blockquote-intro">blockquotes</a>,
+<a href="#endnote-intro">endnotes</a>
 or
 <a href="#footnote-intro">footnotes</a>
 that run to more than one paragraph.
@@ -967,7 +968,7 @@
 that first paragraphs will once again not be indented.
 </p>
 
-<h4 id="pp-space" class="docs">8. Spacing paragraphs</h4>
+<h4 id="pp-space" class="docs">8. Inter-paragraph spacing</h4>
 
 <p>
 By default, mom does not insert a blank line between
@@ -979,16 +980,21 @@
 paragraphs will once again not be separated by a blank line.
 </p>
 
+<p>
+PARA_SPACE is not recommended for use with PRINTSTYLE TYPEWRITE
+unless you give PRINTSTYLE the <kbd>SINGLESPACE</kbd> option.
+</p>
+
 <div class="box-tip">
 <p class="tip-top">
 <span class="note">Note:</span>
 If PARA_SPACE is on, mom spaces only those paragraphs that come
 after an initial paragraph.  Initial paragraphs are those that come
 immediately after the
-<a href="definitions.html#docheader">docheader</a>,
+<a href="definitions.html#docheader">docheader</a>
+(ie the start of a document),
 <a href="#epigraph-intro">epigraphs</a>,
-<a href="#head-intro">heads</a>,
-<a href="#subhead-intro">subheads</a>
+<a href="#heading-intro">headings</a>,
 and
 <a href="#linebreak-intro">linebreaks</a>.
 (The first paragraph after these document elements requires no
@@ -1005,1047 +1011,743 @@
 </p>
 </div>
 
-<div class="rule-short"><hr/></div>
-
-<!-- ==================================================================== -->
-
-<h2 id="head-intro" class="macro-group">Main heads</h2>
-
-<ul style="margin-left: -.5em;">
-  <li><a href="#head">Tag: HEAD</a></li>
-  <li><a href="#head-control">Head control macros and defaults</a></li>
-</ul>
-
 <p>
-Main heads&mdash;or, in this documentation, just
-&#8220;heads&#8221;&mdash;should be used any place you want titles
-to introduce major sections of a document.  If you wish, mom can
-number your heads for you.  Head numbers can also be included
-hierarchically in numbered
-<a href="#subhead-intro">subheads</a>
-and
-<a href="#parahead-intro">paraheads</a>.
+If you would like to space paragraphs by less than a full linespace,
+the way to do it is by creating a wrapper macro around PP that adds
+space before each paragraph, like this,
+<br/>
+<span class="pre-in-pp">
+  .MAC PP2 END
+  .  ALD 6p
+  .  PP
+  .END
+</span>
+which inserts 6
+<a href="definitions.html#picaspoints">points</a>
+of space before each paragraph.  Initial paragraphs, as described
+above, should still be introduced with <kbd>PP</kbd>; only subsequent
+ones require <kbd>.PP2</kbd>.
 </p>
 
 <p>
-By default, heads are centred on the page, underlined, all in caps.
-A double linespace precedes each head.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
-heads are bold, slightly larger than paragraph text.
+If you would like the extra space to be a fraction of the current
+<a href="definitions.html#leading">leading</a>,
+use the groff number register, <kbd>\n[.v]</kbd> and divide it by
+the fraction you want.  For example, <kbd>.ALD \n[.v]/4</kbd> inserts
+1/4 linespacing between paragraphs.
 </p>
 
 <p>
-If these defaults don&#8217;t suit you, you can change them with the
-head control macros.
+You may write the macro, above, in low-level groff if you wish:
+<br/>
+<span class="pre-in-pp">
+  .de PP2
+  . sp 6p
+  . PP
+  ..
+</span>
 </p>
 
-<!-- -HEAD- -->
+<div class="rule-short"><hr/></div>
 
-<div class="macro-id-overline">
-<h3 id="head" class="macro-id">HEAD</h3>
-</div>
+<!-- ==================================================================== -->
 
-<div class="box-macro-args">
-Macro: <b>HEAD</b> <kbd class="macro-args">&quot;&lt;text of head&gt;&quot; [ 
&quot;&lt;2nd line&gt;&quot; [ &quot;&lt;3rd line&gt;&quot; ... ] ]</kbd>
-</div>
+<h2 id="heading-intro" class="macro-group">Headings</h2>
+
+<ul style="margin-left: -.5em;">
+  <li><a href="#heading">Tag: HEADING</a></li>
+  <li><a href="#head-spacing-notes">Spacing of headings</a></li>
+  <li><a href="#heading-control">Heading control macros and defaults</a></li>
+  <li><a href="#prefix-chapter-number">Prefixing chapter numbers</a></li>
+  <li><a href="#oldstyle-headings">Oldstyle headings</a>
+  <ul style="list-style-type: circle; margin-left: -1.25em">
+    <li><a href="#parahead">Important information about PARAHEAD</a>
+    <ul style="list-style-type: square; margin-left: -1.25em">
+      <li><a href="#parahead-usage">Correct usage of paraheads</a></li>
+    </ul></li>
+  </ul></li>
+</ul>
 
 <p>
-The argument to HEAD is the text of the head, surrounded by
-double-quotes.  If you need additional lines for a head, simply
-surround each line with double-quotes.
+Heads, subheads, and deeper levels of section headings are handled by 
+a single macro, HEADING, to which you pass an argument stating the
+desired level.  <kbd>.HEADING 1 &quot;&lt;text&gt;&quot;</kbd>, for
+example, would be a main head; <kbd>.HEADING 2
+&quot;&lt;text&gt;&quot;</kbd> would be a subhead; etc.
 </p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-If a head falls near the bottom of an output page and mom is unable
-to fit the head <i>plus at least one line of text underneath it</i>,
-she will set the head at the top of the next page.
+<p>
+In addition to printing headings in the body of your document,
+HEADING collects the heading as an entry for the Table of Contents,
+if the document is to have one, and the
+<a href="definitions.html#pdfoutline">PDF outline</a>.
+With the <kbd>NAMED</kbd> argument, it furthermore acts as a
+bookmark for
+<a href="definitions.html#pdflink">PDF links</a>.
 </p>
 
-<p class="tip-bottom">
-<span class="additional-note">Additional note:</span>
-If an
-<a href="definitions.html#inputline">input line</a>
-in a head (i.e. one of the lines surrounded by double-quotes) has
-to be broken by mom in order to fit the current line-length (say,
-a narrow column measure), the head underline (underscore) will not
-behave.  You&#8217;ll recognize the problem as soon as you preview
-your document.  If you encounter a head that misbehaves with respect
-to underlining, the solution is to supply each line <i>as you want
-it</i> as a separate argument (surrounded by double-quotes) to the
-HEAD macro.
+<p>
+Headings can also be numbered on a per-heading-level basis,
+hierarchically and concatenatively, eg
+<br/>
+<span class="pre-in-pp">
+  1.
+  1.1
+  1.2
+  1.2.1
+  2.
+  2.1
+  2.2
+  2.2.1
+</span>
+By default, a blank line precedes headings, regardless of the level.
+Mom initially sets up a very basic style for nine levels of heading,
+of which you can have an infinite number, although as has been said,
+if you need more than four levels of heading, you should consider
+re-organizing your material.  The pared-down style of mom&#8217;s
+defaults is intentional; it is expected that you will design
+headings to your own specifications with the
+<a href="definitions.html#controlmacro">control macro</a>,
+<a href="#heading-style">HEADING_STYLE</a>.
 </p>
 
 <p>
-For example, if mom breaks
-<br/>
-<span class="pre-in-pp">
-  .HEAD "This is a very, very, very long head"
-</span>
-into<br/>
-<span class="pre-in-pp">
-  This is a very, very, very
-          long head        
-</span>
-you&#8217;ll see the misbehaving underscore and should change the
-argument to HEAD to
-<br/>
-<span class="pre-in-pp">
-    .HEAD "This is a very, very very" "long head"
-</span>
+It is very good practice, and strongly recommended, that you respect
+the hierarchy of headings, using level-1 for main heads, level-2 for
+subheads, level-3 for subsubheads, etc.  The ease of designing and
+re-designing the style for each level, plus mom&#8217;s very basic
+defaults, are meant, in part, to prevent the whimsical misuse of
+a particular heading level just because its style appeals to you.
 </p>
-</div>
 
-<div class="defaults-container" style="background-color: #ded4bd; border: 
none;">
-<h3 id="head-control" class="docs defaults">HEAD control macros and 
defaults</h3>
+<!-- -HEAD- -->
 
-<p class="defaults">
-There are, in addition to the usual family/font/size/quad control
-macros, a number of macros to manage head numbering, spacing,
-underlining, and so on.  Check them out if you&#8217;re unhappy with
-mom&#8217;s defaults.
-</p>
-<ol style="margin-top: .5em; padding-bottom: .5em;">
-  <li><a href="#head-general">Family/font/size/colour/quad</a></li>
-  <li><a href="#head-caps">Capitalizing heads</a></li>
-  <li><a href="#head-space">Pre-head space</a></li>
-  <li><a href="#head-underline">Underscoring</a></li>
-  <li><a href="#number-heads">Numbering</a></li>
-  <li><a href="#reset-head-number">Reset head numbering</a></li>
-  <li><a href="#head-inlines">Vertical inline escapes inside heads</a></li>
-</ol>
+<div class="macro-id-overline">
+<h3 id="heading" class="macro-id">HEADING</h3>
 </div>
 
-<h4 id="head-general" class="docs" style="margin-top: -1.5em; margin-bottom: 
.5em;">1. Family/font/size/colour/quad</h4>
-
-<div class="defaults-container" style="padding-bottom: 8px;">
-<p class="defaults" style="padding-top: 6px;">
-See
-<a href="#control-macro-args">Arguments to the control macros</a>.
-</p>
-<span class="pre defaults">
-.HEAD_FAMILY default = prevailing document family
-.HEAD_FONT   default = bold, underlined (TYPESET); roman,underlined (TYPEWRITE)
-.HEAD_SIZE   default = +1 (TYPESET); 0 (TYPEWRITE)
-.HEAD_COLOR  default = black
-.HEAD_QUAD   default = CENTER
-</span>
+<div class="box-macro-args">
+Macro: <b>HEADING</b> <kbd class="macro-args">&lt;level&gt; [
+PARAHEAD ] [ NAMED &lt;pdf-id&gt; ] &quot;&lt;heading text&gt;&quot;
 </div>
 
-<h4 id="head-caps" class="docs" style="margin-top: -1.25em;">2. Capitalizing 
heads</h4>
-
-<p>
-By default, mom sets heads in caps, regardless of the
-<a href="definitions.html#stringargument">string(s)</a>
-you give to
-<a href="#head">HEAD</a>.
-To change this behaviour, do
-<br/>
-<span class="pre-in-pp">
-  .HEAD_CAPS OFF
-</span>
-HEAD_CAPS is a toggle macro, therefore you can use any argument you
-like instead of <kbd>OFF</kbd> to disable it (e.g. <b>END, QUIT, Q,
-X</b>...).  To turn HEAD_CAPS back on, simply invoke it without an
-argument.
-</p>
-
-<h4 id="head-space" class="docs" style="margin-top: -.25em;">3. Pre-head 
space</h4>
-
 <p>
-By default, mom deposits 2 blank lines prior to every head when your
-<a href="docprocessing.html#printstyle">PRINTSTYLE</a>
-is <kbd>TYPESET</kbd>.  If you&#8217;d prefer just a single blank
-line, do
-<br/>
-<span class="pre-in-pp">
-  .HEAD_SPACE OFF
-</span>
-HEAD_SPACE is a toggle macro, therefore you can use any argument
-you like instead of <kbd>OFF</kbd> (<kbd>END, QUIT, Q, X</kbd>...).
-To restore the space before heads to 2 blank lines, invoke
-<kbd>.HEAD_SPACE</kbd> without an argument.
+The first argument to HEADING is the <kbd>level</kbd>.  Level 1 is
+analogous to a main head; level 2 is analogous to a subhead; level 3
+is analogous to a subsubhead; etc.
 </p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-HEAD_SPACE has no effect on PRINTSTYLE <kbd>TYPEWRITE</kbd>.
-</p>
-</div>
-
-<h4 id="head-underline" class="docs" style="margin-top: -.25em;">4. 
Underscoring</h4>
-
 <p>
-By default, mom underlines heads.  To change this behaviour, do
-<br/>
-<span class="pre-in-pp">
-  .HEAD_UNDERLINE OFF
-</span>
-HEAD_UNDERLINE can be used as a toggle macro, therefore you can
-use any argument you like instead of <kbd>OFF</kbd> (<kbd>END,
-QUIT, Q, X</kbd>...) to turn it off, or invoke it by itself to
-turn head underlining on.
+The second (optional) argument, <kbd>PARAHEAD</kbd>, instructs mom
+that the heading should be treated as a
+<a href="definitions.html#parahead">paragraph head</a>.
+If HEADING is being used to create a parahead, it must come after
+<a href="#pp">PP</a>,
+not before.
 </p>
 
 <p>
-In addition to toggling head underlining on or off, as of
-version 1.5 of mom, you can use HEAD_UNDERLINE to set the weight
-of the underline and its distance from the head, like this:
-<br/>
-<span class="pre-in-pp">
-  .HEAD_UNDERLINE &lt;weight&gt; [&lt;gap&gt;]
-</span>
-The <kbd>weight</kbd> argument is in points, or fractions thereof,
-and must not have the
-<a href="definitions.html#unitofmeasure">unit of measure</a>,
-<kbd>p</kbd>, appended.  Like
-<a href="inlines.html#rule-weight">RULE_WEIGHT</a>,
-weights must be greater than 0 and less than 100.  Mom&#8217;s
-default for head underlines is 1/2 point.
+The indent applied to a parahead is the same as what would be
+expected from a paragraph without the parahead (see
+<a href="#para-indent-first">Indenting initial paragraphs</a>).
+If you wish that a paragraph introduced by a parahead not be
+indented, use
+<a href="#para-indent">PARA_INDENT</a>
+to set the paragraph indent to zero, then reset the indent for
+subsequent paragraphs.
 </p>
 
 <p>
-The <kbd>gap</kbd> argument determines the distance from the
-baseline of the head to the upper edge of the underline.  It can
-be given using any unit of measure, and must have the unit of
-measure appended to the argument.  Mom&#8217;s default gap for head
-underlines is 2 points.
+The optional third argument, <kbd>NAMED &lt;id&gt;</kbd>, gives the
+heading a unique, non-printing identifier that allows it to
+referenced from anywhere in the final PDF document with the PDF_LINK
+macro, provided the mom file is processed with
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>.
+PDF_LINK usage is explained in the manual,
+<a href="http://www.schaffter.ca/mom/pdf/mom-pdf.pdf";><span 
class="book-title">Producing PDFs with groff and mom</span></a>.
 </p>
 
 <p>
-As an example, suppose you want your heads underlined with a
-4-point rule separated from the head by 3 points.  The way to
-accomplish it is:
-<br/>
-<span class="pre-in-pp">
-  .HEAD_UNDERLINE 4 3p
-</span>
-If you wanted the same thing, but were content with mom&#8217;s
-default gap of 2 points,
+The final argument is the text of the heading, surrounded by double
+quotes.  Long headings that are likely to exceed the current
+line length should be broken into chunks, each surrounded by
+double-quotes, like this:
 <br/>
 <span class="pre-in-pp">
-  .HEAD_UNDERLINE 4
+  .HEADING 1 "A needlessly long but instructive" "first level heading"
 </span>
-would do the trick.
 </p>
 
 <div class="box-tip">
 <p class="tip">
 <span class="note">Note:</span>
-If you supply a weight to HEAD_UNDERLINE, and optionally a gap, you
-also turn the underlining of heads on; if this is not what you want,
-you must turn head underlining off manually afterwards.
+If a heading falls near the bottom of an output page and mom is
+unable to fit the heading plus at least one line of text underneath
+it, she will set the head at the top of the next page.
 </p>
 </div>
 
-<h4 id="number-heads" class="docs" style="margin-top: -.25em;">5. 
Numbering</h4>
-
-<p>
-If you&#8217;d like your heads numbered, simply invoke
-<span class="pre-in-pp">
-  .NUMBER_HEADS
-</span>
-with no argument. Mom will number all subsequent heads automatically
-(in ascending order, naturally).
-</p>
-
-<p>
-If, in addition to numbering heads, you also request that
-<a href="#subhead-intro">subheads</a>
-and/or
-<a href="#parahead-intro">paraheads</a>
-be numbered, the head number will be included in their numbers (each
-number separated by a period [dot]).
-</p>
+<div class="box-tip">
+<h3 id="head-spacing-notes" class="docs" style="padding-top: 9px; font-size: 
100%; text-transform: none">Spacing of headings</h3>
 
 <p>
-Should you wish to stop head numbering, invoke
-<kbd>.NUMBER_HEADS</kbd> with any argument (<kbd>OFF, QUIT, END,
-X</kbd>...).  Head numbering will cease, and the head number will
-not be included in the numbering of subheads and/or paraheads.
+As described above, mom inserts a blank line before each heading.
+If the leading of your document never changes, and you introduce no
+additional space into the text&mdash;as, for example, between
+paragraphs&mdash;this will result in perfectly equal whitespace before
+each heading.
 </p>
 
 <p>
-See also
-<a href="#prefix-chapter-number">Prefixing chapter numbers</a>
-if you&#8217;d like chapter numbers prepended to the head numbers.
+If, however, you disrupt the regular placement of text on
+mom&#8217;s baseline grid, HEADING adds as much whitespace to the
+blank line as is necessary to get things back on track.  The extra
+whitespace is always less than the current leading and therefore
+usually doesn't draw attention to itself.  This, along with a
+similar strategy for whitespace around quotes and blockquotes, is
+what allows mom to balance the bottom margins of pages effectively.
+The manual,
+<a href="http://www.schaffter.ca/mom/pdf/mom-pdf.pdf";><span 
class="book-title">Producing PDFs with groff and mom</span></a>,
+demonstrates this well: the inter-paragraph spacing is 1/3 of the
+leading, yet mom is able to produce a document with good page-rhythm
+and evenly balanced bottom margins.
 </p>
 
-<h4 id="reset-head-number" class="docs" style="margin-top: -.25em;">6. Reset 
head numbering</h4>
-
 <p>
-Should you wish to reset the head number to &#8220;1&#8221;,
-invoke
-<span class="pre-in-pp">
-  .RESET_HEAD_NUMBER
-</span>
-with no argument.  If, for some reason, you want mom to use a head
-number that is not the next in ascending order (i.e. the last head
-number + 1), invoke <kbd>.RESET_HEAD_NUMBER</kbd> with the number
-you want, e.g.
+It occasionally happens that the extra whitespace becomes noticeable,
+typically when the amount of whitespace approaches the value of the
+current leading.  The result looks like two blank lines instead of
+one.  When this happens, a simple but effective fix is to reduce the
+space before the heading by backing up one line, either with
 <br/>
 <span class="pre-in-pp">
-  .RESET_HEAD_NUMBER 6
+  .SPACE -1v
 </span>
-Your next head will be numbered &#8220;6&#8221; and subsequent heads will
-be numbered in ascending order from &#8220;6&#8221;.
-</p>
-
-<h4 id="head-inlines" class="docs" style="margin-top: -.25em;">7. Vertical 
inline escapes inside heads</h4>
-
-<p>
-If you need to adjust the
-<a href="definitions.html#baseline">baseline</a>
-position of a head (e.g. the head falls at the top of a column and
-you want its
-<a href="definitions.html#ascender">ascenders</a>
-to line up with the ascenders of
-<a href="definitions.html#running">running text</a>
-in other columns), you can embed a vertical motion
-<a href="definitions.html#inlines">inline escape</a>
-(either
-<a href="inlines.html#inline-vertical-mom">mom</a>&#8217;s
 or
-<a href="inlines.html#inline-vertical-groff">groff</a>&#8217;s
-in the string(s) you pass to HEAD.
-</p>
-
-<p>
-For example,
 <br/>
-<span class="pre-in-pp" style="margin-bottom: -1em;">
-  .HEAD "\*[DOWN 3p]Text of head"
-</span>
-or
-<span class="pre-in-pp" style="margin-top: -.5em;">
-  .HEAD "\v'3p'Text of head"
+<span class="pre-in-pp">
+  .RLD -1v
 </span>
-will lower the baseline of the head by three points.  Note that
-there&#8217;s no need to reverse the sense of the inline escape.
+This results in slightly less whitespace than normal, but the
+difference is usually not apparent.
 </p>
 
-<p>
-In the case of heads that run to more than one line, you must embed
-the escape in the string for each line, like this:
+<p class="tip-bottom">
+If you&#8217;d prefer that mom not add flexible whitespace to
+headings, invoke the macro
 <br/>
-<span class="pre-in-pp" style="margin-bottom: -1em;">
-  .HEAD "\*[DOWN 3p]First line" "\[DOWN 3p]Next line" 
-</span>
-or
-<span class="pre-in-pp" style="margin-top: -.5em;">
-  .HEAD "\v'3p'First line" "\v'3p'Next line" 
+<span class="pre-in-pp">
+  .NO_SHIM
 </span>
-</p>
-
-<div class="rule-short"><hr/></div>
-
-<!-- ==================================================================== -->
-
-<h2 id="subhead-intro" class="macro-group">Subheads</h2>
-
-<ul style="margin-left: -.5em;">
-  <li><a href="#subhead">Tag: SUBHEAD</a></li>
-  <li><a href="#subhead-control">Subhead control macros</a></li>
-</ul>
-
-<p>
-Subheads should be used any place you want titles to introduce
-sections of a document below heads.  If you wish, mom can
-number subheads for you.  Subhead numbers can also be included
-hierarchically in numbered
-<a href="#subsubhead-intro">subsubheads</a>.
-</p>
-
-<p>
-By default, subheads are flush left.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
-they are set bold, slightly larger than paragraph text.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>,
-they are underlined.  A single linespace precedes them in both
-printstyles, and a tiny space adjustment raises them slightly
-above text that comes afterwards for greater clarity in document
-structuring.
-</p>
-
-<p>
-If these defaults don&#8217;t suit you, you can change them with the
-subhead control macros.
-</p>
-
-<!-- -SUBHEAD- -->
-
-<div class="macro-id-overline">
-<h3 id="subhead" class="macro-id">SUBHEAD</h3>
-</div>
-
-<div class="box-macro-args">
-Macro: <b>SUBHEAD</b> <kbd class="macro-args">&quot;&lt;text of 
subhead&gt;&quot; [ &quot;&lt;2nd line&gt;&quot; [ &quot;&lt;3rd line&gt;&quot; 
... ] ]</kbd>
-</div>
-
-<p>
-The argument to SUBHEAD is the text of the subhead, surrounded by
-double-quotes.  If you need additional lines for a subhead, simply
-surround each line with double-quotes.
-</p>
-
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-If a subhead falls near the bottom of an output page and mom
-is unable to fit the subhead <i>plus at least one line of text
-underneath it</i>, she will set the subhead at the top of the next
-page.
+either in the style sheet section of your document (ie after
+PRINTSTYLE but before START), which will globally disable whitespace
+adjustment not only before headings, but around quotes and
+blockquotes as well, or on a per-instance basis.  <kbd>.NO_SHIM</kbd>
+is disabled by issuing
+<br/>
+<span class="pre-in-pp">
+  .NO_SHIM OFF
+</span>
+Please note that <kbd>.NO_SHIM</kbd> also disables mom&#8217;s
+automatic shimming around quotes, blockquotes, after PDF images and
+floats, and
+<a href="docprocessing.html#shim">SHIM</a>
+macro itself.
 </p>
 </div>
 
 <div class="defaults-container" style="background-color: #ded4bd; border: 
none;">
-<h3 id="subhead-control" class="docs defaults">SUBHEAD control macros and 
defaults</h3>
-
-<p class="defaults">
-In addition to the usual family/font/size/quad control macros, there
-are macros to manage subhead numbering and vertical placement.
-</p>
-
-<ol style="margin-top: .5em; padding-bottom: .5em;">
-  <li><a href="#subhead-general">Family/font/size/colour/quad</a></li>
-  <li><a href="#number-subheads">Numbering</a></li>
-  <li><a href="#reset-subhead-number">Reset subhead numbering</a></li>
-  <li><a href="#subhead-baseline-adjust">Baseline adjustment</a></li>
-  <li><a href="#subhead-inlines">Vertical inline escapes inside 
subheads</a></li>
-</ol>
-</div>
-
-<h4 id="subhead-general" class="docs" style="margin-top: -1.5em; 
margin-bottom: .5em;">1. Family/font/size/quad</h4>
-
-<div class="defaults-container" style="padding-bottom: 8px;">
-<p class="defaults" style="padding-top: 6px;">
-See
-<a href="#control-macro-args">Arguments to the control macros</a>.
-</p>
-<span class="pre defaults" style="padding-bottom: -1em;">
-.SUBHEAD_FAMILY default = prevailing document family
-.SUBHEAD_FONT   default = bold (TYPESET); italic, ie underlined (TYPEWRITE)
-.SUBHEAD_SIZE   default = +.5 (TYPESET); 0 (TYPEWRITE)
-.SUBHEAD_COLOR  default = black
-.SUBHEAD_QUAD   default = LEFT
-</span>
-</div>
-
-<h4 id="number-subheads" class="docs" style="margin-top: -1.25em;">2. Number 
subheads</h4>
-
-<p>
-If you&#8217;d like your subheads numbered, simply invoke
-<kbd>.NUMBER_SUBHEADS</kbd> with no argument. Mom
-will number all subsequent subheads automatically (in ascending
-order, naturally).
-</p>
-
-<p>
-If, in addition to numbering subheads, you also request that
-<a href="#head-intro">heads</a>
-be numbered, the head number will be included in the subhead number
-(separated by a period [dot]).
-</p>
-
-<p>
-Should you wish to stop subhead numbering, invoke
-<kbd>.NUMBER_SUBHEADS</kbd> with any argument (<kbd>OFF, QUIT, END,
-X</kbd>...).  Subhead numbering will cease, and the subhead number
-will not be included in the numbering of paraheads.
-</p>
+<h3 id="heading-control" class="defaults" style="margin-left: 6px; 
margin-bottom: -1em">HEADING control and defaults</h3>
 
-<p>
-See also
-<a href="#prefix-chapter-number">Prefixing chapter numbers</a>
-if you&#8217;d like chapter numbers prepended to the subhead numbers.
+<div style="padding-left: 15px; padding-right: 15px">
+<p style="margin-bottom: 1em">
+By default, mom pre-initializes nine levels of headings to use
+the bold font of the prevailing document family, with a baseline
+adjustment of 1/10 of the current
+<a href="definitions.html#leading">leading</a>.
+In addition, level-1 headings are 3 points larger than running text,
+level 2-headings 2 points larger, and level 3-headings 1 point
+larger.  The remaining 6 levels are the same size as running text.
+A single blank line precedes all levels of heading.
 </p>
 
-<h4 id="reset-subhead-number" class="docs" style="margin-top: -.25em;">3. 
Reset subhead numbering</h4>
+<h4 id="heading-style" class="docs" style="margin-bottom: -.5em">The 
HEADING_STYLE macro</h4>
 
 <p>
-Should you wish to reset the subhead number to &#8220;1&#8221;,
-invoke
-<span class="pre-in-pp">
-  .RESET_SUBHEAD_NUMBER
-</span>
-with no argument.  If, for some reason, you want mom to use a
-subhead number that is not the next in ascending order (i.e. the
-last subhead number + 1), invoke <kbd>.RESET_SUBHEAD_NUMBER</kbd>
-with the number you want, e.g.
+Styling heads is accomplished with a single macro,
 <br/>
 <span class="pre-in-pp">
-  .RESET_SUBHEAD_NUMBER 4
+  .HEADING_STYLE&nbsp;&lt;level&gt;
 </span>
-
-Your next subhead will be numbered &#8220;4&#8221; and subsequent
-subheads will be numbered in ascending order from &#8220;4&#8221;.
-</p>
-
-<h4 id="subhead-baseline-adjust" class="docs" style="margin-top: -.25em;">4. 
Baseline adjustment</h4>
-
-<p>
-For aesthetic reasons and to clarify document structure, mom raises
-subheads slightly above the
-<a href="definitions.html#baseline">baseline</a>
-on which they would otherwise fall.  In 
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
-the amount is 1/8 of the prevailing
-<a href="definitions.html#leading">leading</a>.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>,
-it&#8217;s 1/5 of the prevailing leading.
-</p>
-
-<p>
-If you would prefer mom not exhibit this behaviour, or if you would
-like to change the amount by which she raises the subhead, use the
-macro <kbd>.SUBHEAD_BASELINE_ADJUST</kbd>.  With an argument of 0 (zero),
-subhead baseline adjustment will be disabled.  Any other numeric
-argument, with a
-<a href="definitions.html#unitofmeasure">unit of measure</a>
-appended directly onto the argument, will cause mom to raise your
-subheads by the amount you specify.
+where <kbd>&lt;level&gt;</kbd> is the numeric heading level to which
+the style applies.
 </p>
 
-<h4 id="subhead-inlines" class="docs" style="margin-top: -.25em;">5. Vertical 
inline escapes inside subheads</h4>
-
 <p>
-See
-<a href="#head-inlines">Vertical inline escapes inside heads</a>.
-The information there applies equally to subheads.
-</p>
-
-<div class="rule-short"><hr/></div>
-
-<!-- ==================================================================== -->
-
-<h2 id="subsubhead-intro" class="macro-group">Subsubheads</h2>
-
-<ul style="margin-left: -.5em;">
-  <li><a href="#subsubhead">Tag: SUBSUBHEAD</a></li>
-  <li><a href="#subsubhead-control">Subsubhead control macros</a></li>
-</ul>
-
-<p>
-Subsubheads should be used any place you want titles to introduce
-sections of a document below subheads.  If you wish, mom can
-number subsubheads for you.  Subsubhead numbers can also be included
-hierarchically in numbered
-<a href="#parahead-intro">paraheads</a>.
-</p>
-
-<p>
-By default, subsubheads are flush left.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
-they are set in italic, slightly larger than paragraph text.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>,
-they are set roman at the same size as the prevailing type.  A
-single linespace precedes them in both printstyles, and a tiny space
-adjustment raises them slightly above text that comes afterwards for
-greater clarity in document structuring.
+HEADING_STYLE takes any or all of the following arguments,
+which may be given in any order:
+<br/>
+<span class="pre defaults">
+  FAMILY &lt;family&gt;
+  FONT   &lt;font&gt;
+  SIZE   &lt;+|-size&gt;
+  QUAD   &lt;direction&gt;
+  COLOR  &lt;colour&gt;
+  UNDERSCORE  &lt;weight&gt; &lt;gap&gt; | NO_UNDERSCORE
+  UNDERSCORE2 &lt;weight&gt; &lt;gap1&gt; &lt;gap2&gt; | NO_UNDERSCORE2
+  CAPS | NO_CAPS
+  BASELINE_ADJUST &lt;amount to raise heading from the baseline&gt;
+  SPACE_AFTER | NO_SPACE_AFTER
+  NUMBER | NO_NUMBER
+</span>
 </p>
 
-<p>
-If these defaults don&#8217;t suit you, you can change them with the
-subsubhead control macros.
+<p class="defaults" style="margin-bottom: 1em">
+The arguments to <kbd>FAMILY</kbd>, <kbd>FONT</kbd>,
+<kbd>SIZE</kbd>, <kbd>QUAD</kbd>, and
+<kbd>COLOR</kbd> are the same as
+those you&#8217;d give to the
+<a href="#docelement-control">control macros</a>
+ending in _FAMILY, _FONT, _SIZE, _QUAD, or _COLOR.  See
+<a href="#control-macro-args">Arguments to the control macros</a>.
 </p>
 
-<!-- -SUBSUBHEAD- -->
-
-<div class="macro-id-overline">
-<h3 id="subsubhead" class="macro-id">SUBSUBHEAD</h3>
-</div>
-
-<div class="box-macro-args">
-Macro: <b>SUBSUBHEAD</b> <kbd class="macro-args">&quot;&lt;text of 
subsubhead&gt;&quot; [ &quot;&lt;2nd line&gt;&quot; [ &quot;&lt;3rd 
line&gt;&quot; ... ] ]</kbd>
-</div>
-
-<p>
-The argument to SUBSUBHEAD is the text of the subsubhead, surrounded by
-double-quotes.  If you need additional lines for a subsubhead, simply
-surround each line with double-quotes.
+<p class="defaults" style="margin-bottom: 1em">
+<kbd>UNDERSCORE</kbd> and <kbd>UNDERSCORE2</kbd> require that a
+weight for the underscore be given, in points (decimal fractions
+allowed), but without the unit of measure <kbd>p</kbd> appended.
+They also require that the underscore's distance from the baseline
+be supplied; in the case of UNDERSCORE2, an additional gap argument
+representing the distance between the two underscores must be
+provided.
+</p>
+
+<p class="defaults" style="margin-bottom: 1em">
+The <kbd>CAPS</kbd> argument capitalizes the text of a heading
+level in the body of a document but not in the Table of
+Contents, where capitalization of entries is controlled by
+<a 
href="tables-of-contents.html#toc-entry-style">TOC_ENTRY_STYLE&nbsp;&lt;n&gt;</a>.
+</p>
+
+<p class="defaults" style="margin-bottom: 1em">
+<kbd>BASELINE_ADJUST</kbd> allows you to raise a heading slightly
+above the baseline on which it would otherwise sit.  For aesthetic
+reasons, it is often desirable to introduce a small amount of space
+between a heading and the text following it.  Since headings are
+preceded by a blank line, it is preferable to move the heading
+upward than to lower the text following it.  The argument to
+BASELINE_ADJUST is the amount by which to raise the heading.  It
+requires no <kbd>+</kbd> or <kbd>-</kbd> sign, and must have a
+<a href="definitions.html#unitofmeasure">unit of measure</a>
+appended to it.
 </p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-If a subsubhead falls near the bottom of an output page and mom
-is unable to fit the subsubhead <i>plus at least one line of text
-underneath it</i>, she will set the subsubhead at the top of the next
-page.
+<p class="defaults" style="margin-bottom: 1em">
+<kbd>SPACE_AFTER</kbd> inserts a blank line equal to the current
+<a href="definitions.html#leading">leading</a> after a HEADING.
+If you'd like a full linespace after a heading level, use
+<kbd>SPACE_AFTER</kbd>.  If you'd like additional space before a
+heading level, you must introduce it yourself with
+<a href="typesetting.html#space">SPACE</a>
+or
+<a href="typesetting.html#ald">ALD</a>.
 </p>
-</div>
 
-<div class="defaults-container" style="background-color: #ded4bd; border: 
none;">
-<h3 id="subsubhead-control" class="docs defaults">SUBSUBHEAD control macros 
and defaults</h3>
-
-<p class="defaults">
-In addition to the usual family/font/size/quad control macros, there
-are macros to manage subsubhead numbering.
+<p class="defaults" style="margin-bottom: 1em">
+<kbd>NUMBER</kbd> and <kbd>NO_NUMBER</kbd> allow you to determine
+whether mom prepends a hierarchic numbering scheme to a heading
+level in the body of a document.  Numbering of Table of Contents
+entries is controlled separately with
+<a href="tables-of-contents.html#toc-entry-numbers">TOC_ENTRY_NUMBERS</a>.
+Mom also has a special macro to toggle whether to prefix a chapter
+number to numbered headings and Table of Contents entries,
+<a href="prefix-chapter-number">PREFIX_CHAPTER_NUMBER</a>.
+</p>
+
+<p class="defaults" style="padding-bottom: .5em">
+The argument list is long, so you may want to break it into
+several lines by using the backslash character (<kbd>\</kbd>).
+Here's an example of how you might style a level 1 heading:
+<br/>
+<span class="pre defaults">
+  .HEADING_STYLE 1 \
+  FONT B \
+  QUAD C \
+  UNDERSCORE .5 2p \
+  BASELINE_ADJUST 3p \
+  NUMBER
+</span>
+This creates a level-1 heading style that's bold, centered,
+underscored and numbered, raised by 3 points from the baseline.
 </p>
-
-<ol style="margin-top: .5em; padding-bottom: .5em;">
-  <li><a href="#subsubhead-general">Family/font/size/colour/quad</a></li>
-  <li><a href="#number-subsubheads">Numbering</a></li>
-  <li><a href="#reset-subsubhead-number">Reset subsubhead numbering</a></li>
-  <li><a href="#subsubhead-baseline-adjust">Baseline adjustment</a></li>
-  <li><a href="#subsubhead-inlines">Vertical inline escapes inside 
subsubheads</a></li>
-</ol>
 </div>
-
-<h4 id="subsubhead-general" class="docs" style="margin-top: -1.5em; 
margin-bottom: .5em;">1. Family/font/size/quad</h4>
-
-<div class="defaults-container" style="padding-bottom: 8px;">
-<p class="defaults" style="padding-top: 6px;">
-See
-<a href="#control-macro-args">Arguments to the control macros</a>.
-</p>
-<span class="pre defaults" style="padding-bottom: -1em;">
-.SUBSUBHEAD_FAMILY default = prevailing document family
-.SUBSUBHEAD_FONT   default = italic (TYPESET); roman (TYPEWRITE)
-.SUBSUBHEAD_SIZE   default = +.5 (TYPESET); 0 (TYPEWRITE)
-.SUBSUBHEAD_COLOR  default = black
-.SUBSUBHEAD_QUAD   default = LEFT
-</span>
 </div>
 
-<h4 id="number-subsubheads" class="docs" style="margin-top: -1.25em;">2. 
Number subsubheads</h4>
-
-<p>
-If you&#8217;d like your subsubheads numbered, simply invoke
-<kbd>.NUMBER_SUBSUBHEADS</kbd> with no argument.  Mom will number
-all subsequent subsubheads automatically (in ascending order,
-naturally).
-</p>
-
-<p>
-If, in addition to numbering subsubheads, you also request that
-<a href="#head-intro">heads</a>
-be numbered, the head number will be included in the subsubhead
-number (separated by a period [dot]).
-</p>
+<!-- -PREFIX_CHAPTER_NUMBER- -->
 
-<p>
-Should you wish to stop subsubhead numbering, invoke
-<kbd>.NUMBER_SUBSUBHEADS</kbd> with any argument (<kbd>OFF, QUIT, END,
-X</kbd>...).  Subsubhead numbering will cease, and the subsubhead number
-will not be included in the numbering of paraheads.
-</p>
+<div id="prefix-chapter-number" class="macro-id-overline" style="margin-top: 
-1em;">
+<h3 class="macro-id" style="text-transform: none; font-size: 105%;">Prefixing 
chapter numbers</h3>
+</div>
+
+<div class="box-macro-args">
+Macro: <b>PREFIX_CHAPTER_NUMBER</b> <kbd class="macro-args">&lt;none&gt; | 
&lt;chapter number as digit&gt; | &lt;anything&gt;</kbd>
+</div>
 
 <p>
-See also
-<a href="#prefix-chapter-number">Prefixing chapter numbers</a>
-if you&#8217;d like chapter numbers prepended to the subsubhead numbers.
+If you&#8217;ve requested numbering for any level of heading and
+you&#8217;d like mom, in addition, to prefix a chapter number to the
+numbering scheme, you can do so with PREFIX_CHAPTER_NUMBER.
 </p>
 
-<h4 id="reset-subsubhead-number" class="docs" style="margin-top: -.25em;">3. 
Reset subsubhead numbering</h4>
-
 <p>
-Should you wish to reset the subsubhead number to &#8220;1&#8221;,
-invoke
+After you invoke <kbd>.PREFIX_CHAPTER_NUMBER</kbd>, mom will prepend
+the current chapter number to all headings you have requested be
+numbered with
+<a href="#heading-style"><kbd>.HEADING_STYLE &lt;n&gt; NUMBER</a>.
+Thus, assuming chapter number twelve (12):
+<br/>
 <span class="pre-in-pp">
-  .RESET_SUBSUBHEAD_NUMBER
+  1.   LEVEL 1 HEADING
+  1.1. Level 2 heading
 </span>
-with no argument.  If, for some reason, you want mom to use a
-subsubhead number that is not the next in ascending order (i.e. the
-last subsubhead number + 1), invoke <kbd>.RESET_SUBSUBHEAD_NUMBER</kbd>
-with the number you want, e.g.
+would become
 <br/>
 <span class="pre-in-pp">
-  .RESET_SUBSUBHEAD_NUMBER 4
+  12.1.   LEVEL 1 HEADING
+  12.1.1. Level 2 heading
 </span>
-
-Your next subsubhead will be numbered &#8220;4&#8221; and subsequent
-subsubheads will be numbered in ascending order from &#8220;4&#8221;.
 </p>
 
-<h4 id="subsubhead-baseline-adjust" class="docs" style="margin-top: 
-.25em;">4. Baseline adjustment</h4>
-
 <p>
-For aesthetic reasons and to clarify document structure, mom raises
-subsubheads slightly above the
-<a href="definitions.html#baseline">baseline</a>
-on which they would otherwise fall.  In 
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
-the amount is 1/8 of the prevailing
-<a href="definitions.html#leading">leading</a>.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>,
-it&#8217;s 1/5 of the prevailing leading.
+When you invoke <kbd>.PREFIX_CHAPTER_NUMBER</kbd> without an
+argument, mom checks to see whether the argument you passed to
+<a href="docprocessing.html#chapter">CHAPTER</a>
+is a digit.  If it is, she immediately starts pre-pending the
+current chapter number to numbered head elements.  If it isn&#8217;t
+(say you&#8217;ve called your chapter &#8220;One&#8221; instead
+of &#8220;1&#8221;), mom will abort with a request that you pass
+PREFIX_CHAPTER_NUMBER a digit representing the current chapter
+number.
 </p>
 
 <p>
-If you would prefer mom not exhibit this behaviour, or if you would
-like to change the amount by which she raises the subsubhead, use the
-macro <kbd>.SUBSUBHEAD_BASELINE_ADJUST</kbd>.  With an argument of 0 (zero),
-subsubhead baseline adjustment will be disabled.  Any other numeric
-argument, with a
-<a href="definitions.html#unitofmeasure">unit of measure</a>
-appended directly onto the argument, will cause mom to raise your
-subsubheads by the amount you specify.
+In collated documents, mom automatically increments
+the digit used by PREFIX_CHAPTER_NUMBER by one
+(current chapter digit + 1) every time you invoke <a
+href="rectoverso.html#collate"><kbd>.COLLATE</kbd></a>, even if
+you&#8217;ve (temporarily) turned off the prefixing of chapter
+numbers.  Thus, even if you call your chapters &#8220;One&#8221;,
+&#8220;Two&#8221;, &#8220;Three&#8221; instead of &#8220;1&#8221;,
+&#8220;2&#8221;, &#8220;3&#8221;, mom will Do The Right Thing
+with respect to numbering head elements in all collated chapters
+following the first invocation of PREFIX_CHAPTER_NUMBER (assuming,
+of course, that the collated chapters are in incrementing order; if
+not, you must must put
+<br/>
+<span class="pre-in-pp">
+  .PREFIX_CHAPTER_NUMBER &lt;chapter number&gt;
+</span>
+somewhere after the invocation of COLLATE and before the first
+numbered head element of each collated document).
 </p>
 
-<h4 id="subsubhead-inlines" class="docs" style="margin-top: -.25em;">5. 
Vertical inline escapes inside sububheads</h4>
+<p>
+PREFIX_CHAPTER_NUMBER can be disabled by passing it any argument
+other than a digit (eg <b>OFF, QUIT, END, X</b>, etc), although,
+as noted above, mom will keep, and&mdash;in the case of collated
+documents&mdash;increment the chapter number, allowing you to turn
+prefixing of chapter numbers to numbered head elements off and on
+according to your needs or whims.
+</p>
 
 <p>
-See
-<a href="#head-inlines">Vertical inline escapes inside heads</a>.
-The information there applies equally to subsubheads.
+<span class="note">Note:</span>
+Because PREFIX_CHAPTER_NUMBER takes an (optional) digit representing
+the chapter number, it&#8217;s use need not be restricted to
+<a href="docprocessing.html#doctype">DOCTYPE <kbd>CHAPTER</kbd></a>.
+You can use it with any document type.  Furthermore, even if
+your doctype isn&#8217;t <kbd>CHAPTER</kbd>, you can identify
+the document as a chapter for the purposes of numbering head
+elements by invoking the macro,
+<a href="docprocessing.html#chapter"><kbd>.CHAPTER</kbd></a>,
+with a
+<a href="definitions.html#numericargument">numeric argument</a>
+in your document setup. 
 </p>
 
 <div class="rule-short"><hr/></div>
 
 <!-- ==================================================================== -->
 
-<h2 id="parahead-intro" class="macro-group">Paragraph heads</h2>
+<h2 id="oldstyle-headings-intro" class="macro-group">Oldstyle headings</h2>
 
 <ul style="margin-left: -.5em;">
-  <li><a href="#parahead">Tag: PARAHEAD</a></li>
-  <li><a href="#parahead-control">Parahead control macros</a></li>
+  <li><a href="#oldstyle-headings">Macro: OLDSTYLE_HEADINGS</a></li>
+  <li><a href="#head">Macro: HEAD</a></li>
+  <li><a href="#subhead">Macro: SUBHEAD</a></li>
+  <li><a href="#subsubhead">Macro: SUBSUBHEAD</a></li>
 </ul>
 
 <p>
-Paragraph heads (paraheads) should be used any place you want titles
-to introduce paragraphs below heads or subheads.  If you wish, mom
-can number paraheads for you.
+In versions of mom prior to 2.0, headings were entered by their
+commonly used names, <i>viz.</i> HEAD, SUBHEAD, and SUBSUBHEAD. The
+new
+<a href="#heading-intro">HEADING</a>
+scheme allows for greater flexibility, and permits seamless
+integration with PDF output.
 </p>
 
 <p>
-By default, paraheads are joined to the body of a paragraph,
-slightly indented (provided the paragraph is not a
-&#8220;first&#8221; paragraph as defined in
-<a href="#para-indent-first">Indenting initial paragraphs</a>)
-and separated from the body of the paragraph by a small amount of
-horizontal space.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
-they are set bold italic, slightly larger than paragraph text.  In
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>,
-they are underlined.
+Documents created with pre-2.0 versions may still use the oldstyle
+heading names, as may new documents, however there are some
+differences in their behaviour.
 </p>
 
 <p>
-If these defaults don&#8217;t suit you, you can change them with the
-parahead control macros.
+Whenever mom encounters an oldstyle heading, she loads the default
+style formerly associated with the oldstyle name.  See below for a
+description of the default styles in the sections
+<a href="#head">HEAD</a> (now HEADING 1),
+<a href="#subhead">SUBHEAD</a> (now HEADING 2),
+and
+<a href="#subsubhead">SUBSUBHEAD</a> (now HEADING 3).
+Mom also emits a message to stderr alerting you to what she's doing.
 </p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="tip">Tip:</span>
-If you really need a heading level below subsubheads that
-isn&#8217;t joined to the body of a paragraph, you can trick
-PARAHEAD into giving you one by creating a paragraph that contains
-only a parahead, like this:
+<p>
+The control macros formerly associated with oldstyle headings are no
+longer present in mom's macro file, which means that if you
+made changes to mom's default for those headings, you must recreate
+the changes with the
+<a href="#heading-style">HEADING_STYLE</a>
+macro.  The entire style need not be recreated, only those
+parameters that differed from mom's defaults.  Thus, if your HEADs
+were set flush left, instead of the oldstyle default, centered, but
+otherwise kept mom's settings, you need only do
+<br/>
+<span class="pre-in-pp">
+  .HEADING_STYLE 1 QUAD L
+</span>
+</p>
+
+<div id="parahead" class="box-important">
+<p class="tip-top">
+<span class="important">Important:</span>
+The macro, PARAHEAD, is no longer available.  You must create paragraph
+heads using the
+<a href="#heading">HEADING</a>
+macro.  Mom will abort with an informational message whenever she
+encounters PARAHEAD. Assuming a heading level of 3 for your
+paraheads, the former defaults for PARAHEAD can be set up like this:
+<br/>
+<span class="pre-in-pp">
+  .HEADING STYLE 3 FONT BI SIZE -.25 \" For PRINTSTYLE TYPESET
+  .HEADING STYLE 3 FONT I SIZE +0    \" For PRINTSTYLE TYPEWRITE
+</span>
+Equally, the macro NUMBER_PARAHEADS is no longer available.  You
+must enable numbering of the correct level for paraheads with
+HEADING_STYLE.  Again assuming a heading level of 3 for paraheads,
+it's simply done:
+<br/>
+<span class="pre-in-pp">
+  .HEADING_STYLE 3 NUMBER
+</span>
+</p>
+
+<h3 id="parahead-usage" class="docs" style="text-transform: none; margin-top: 
-1em">Correct usage of paraheads</h3>
+
+<p style="margin-top: .5em">
+It is tempting to choose an arbitrary heading level for paraheads,
+since they are sometimes needed out-of-sequence; for example,
+immediately after a main head (level-1) in a document that
+subsequently requires subheads (level-2).  In such a circumstance,
+choosing level-3 for all your paraheads might seem to make sense,
+but in fact doesn&#8217;t, since it disrupts the hierarchy of
+both the Table of Contents (if your document has one) and the PDF
+outline.
+</p>
+
+<p>
+Correct use of the <kbd>PARAHEAD</kbd> option to HEADING under such
+circumstances requires always assigning <kbd>PARAHEAD</kbd> to
+the next logical level in the heading hierarchy.  For example, if
+there are no headings before the parahead, it should be assigned to
+level-1.  If subsequently there is a main head to be followed by
+more paraheads, the main head should be level-1, and the paraheads
+level-2.  This will almost certainly require assigning new style
+parameters to level-1 (with
+<a href="#heading-style">HEADING_STYLE</a>)
+and to the level now being used for paraheads.  The following
+example demonstrates.
 <br/>
 <span class="pre-in-pp">
+  .HEADING_STYLE 1 FONT BI SIZE +.25 \" parahead style, level-1
+  .PP
+  .HEADING 1 PARAHEAD &lt;parahead&gt;
+  &lt;paragraph text&gt;
+  .PP
+  .HEADING 1 PARAHEAD &lt;parahead&gt;
+  &lt;paragraph text&gt;
+  \# main head style, level-1
+  .HEADING_STYLE 1 FONT B SIZE +3 QUAD CENTER UNDERSCORE .5 2p
+  .HEADING_STYLE 2 FONT BI SIZE +.25 \" parahead style, level-2
+  .HEADING 1 &lt;main head&gt;
   .PP
-  .PARAHEAD "My Sub-Subhead"
+  &lt;paragraph text&gt;
   .PP
-  &lt;text&gt;
+  .HEADING 2 PARAHEAD &lt;parahead&gt;
+  &lt;paragraph text&gt;
 </span>
 </p>
 </div>
 
-<!-- -PARAHEAD- -->
+<!-- -OLDSTYLE_HEADINGS - -->
 
 <div class="macro-id-overline">
-<h3 id="parahead" class="macro-id">PARAHEAD</h3>
+<h3 id="oldstyle-headings" class="macro-id">OLDSTYLE HEADINGS</h3>
 </div>
 
 <div class="box-macro-args">
-Macro: <b>PARAHEAD</b> <kbd class="macro-args">&quot;&lt;text of 
parahead&gt;&quot;</kbd>
+Macro: <b>OLDSTYLE_HEADINGS</b>
 </div>
 
 <p>
-PARAHEAD must come after
-<a href="#pp">PP</a>
-or it will not work.
-</p>
-
-<p>
-The argument is the text of the parahead, surrounded by
-double-quotes.  Because paraheads are joined to the body of a
-paragraph, they accept only one argument (see
-<a href="#head">HEAD</a>
-and
-<a href="#subhead">SUBHEAD</a>).
+OLDSTYLE_HEADINGS requires no argument.  It instructs mom to set the
+first three levels of heading to the parameters of her old defaults
+for HEAD, SUBHEAD, and SUBSUBHEAD.  Use of OLDSTYLE_HEADINGS will
+also prevent mom from generating the message she issues the first
+time she encounters HEAD, SUBHEAD, and SUBSUBHEAD.
 </p>
 
-<div class="defaults-container" style="background-color: #ded4bd; border: 
none;">
-<h3 id="parahead-control" class="docs defaults">PARAHEAD control macros and 
defaults</h3>
-
-<p class="defaults">
-In addition to the family/font/size/colour/indent control macros,
-there are macros to manage parahead numbering.
-</p>
+<!-- -HEAD- -->
 
-<ol style="margin-top: .5em; padding-bottom: .5em;">
-  <li><a href="#parahead-general">Family/font/size/color</a></li>
-  <li><a href="#parahead-indent">Indent</a></li>
-  <li><a href="#parahead-space">Horizontal space</a></li>
-  <li><a href="#number-paraheads">Numbering</a></li>
-  <li><a href="#reset-parahead-number">Reset parahead numbering</a></li>
-</ol>
+<div id="head" class="box-macro-args">
+Macro: <b>HEAD</b> <kbd class="macro-args">[ NAMED &lt;id&gt; ] &quot;&lt;text 
of head&gt;&quot; &quot;&lt;another line&gt;&quot;...</kbd>
 </div>
 
-<h4 id="parahead-general" class="docs" style="margin-top: -1.5em; 
margin-bottom: .5em;">1. Family/font/size/colour</h4>
-
-<div class="defaults-container" style="padding-bottom: 8px;">
-<p class="defaults" style="padding-top: 6px;">
-See
-<a href="#control-macro-args">Arguments to the control macros</a>.
+<p>
+When invoked for the first time, with or without
+<a href="oldstyle-headings">OLDSTYLE_HEADINGS</a>,
+HEAD sets the parameters for level-1 headings to mom&#8217;s old
+HEAD defaults, then prints the head as a level-1 heading.
+The <kbd>NAMED &lt;id&gt;</kbd> optional argument is explained in
+the description of
+<a href="#heading">HEADING</a>.
 </p>
-<span class="pre defaults">
-.PARAHEAD_FAMILY default = prevailing document family
-.PARAHEAD_FONT   default = bold italic (TYPESET); italic, ie underlined 
(TYPEWRITE)
-.PARAHEAD_SIZE   default = -.25 (TYPESET); 0 (TYPEWRITE)
-.PARAHEAD_COLOR  default = black*
 
-*If you colourize paragraph text, paraheads will appear in the same
- colour as the text unless you explicitly tell mom to colour them
- otherwise by invoking .PARAHEAD_COLOR.  If you do want paraheads
- that are coloured the same as paragraph text, it&#8217;s generally a good
- idea to invoke .PARAHEAD_COLOR anyway (with the same colour used
- for paragraph text), just to let mom know.
-</span>
-</div>
-
-<h4 id="parahead-indent" class="docs" style="margin-top: -1.25em;">2. 
Indent</h4>
+<p>
+If, prior to invoking HEAD, you have given any parameters to level-1
+heads with
+<a href="#heading-style">HEADING STYLE</a>,
+they will be preserved; any you give afterwards will be respected.
+</p>
 
 <p>
-Unlike other control macros that end in
-<a href="#control-indents">_INDENT</a>,
-the argument to the macro that controls indenting of paragraph
-heads (PARAHEAD_INDENT) is not relative to the first-line indent of
-normal paragraphs.  In other words, it takes an absolute value, and
-requires a
-<a href="definitions.html#unitofmeasure">unit of measure</a>.
-For example, to set the paragraph head indent to 2-1/2 picas, you
-do:
+The former style defaults for HEAD were:
 <br/>
 <span class="pre-in-pp">
-  .PARAHEAD_INDENT 2.5P
+  FAMILY     = prevailing document family
+  FONT       = bold (TYPESET); roman (TYPEWRITE)
+  SIZE       = +1 (TYPESET); +0 (TYPEWRITE)
+  QUAD       = C 
+  UNDERSCORE .5 2p
+  CAPS
 </span>
-Mom&#8217;s default indent for paragraph heads is 1/2 the first-line
-indent of normal paragraphs (both printstyles).  However, as stated
-above, if you choose to change the indent, you must give an absolute
-value (unless you&#8217;re a groff expert and want to manipulate the
-number register <kbd>\n[#PP_INDENT]u</kbd> arithmetically as the
-argument to PARAHEAD_INDENT for an indent that&#8217;s relative to
-PP_INDENT.)
 </p>
 
 <div class="box-tip">
 <p class="tip">
-<span class="tip">Tip:</span>
-If you want to make the parahead indent equal to the paragraph
-indent, a convenient way to do it is
+<span class="note">Note:</span>
+The macro, NUMBER_HEADS, from pre-2.0 versions of mom, can still be
+used, though it is now a wrapper for
 <br/>
 <span class="pre-in-pp">
-  .PARAHEAD INDENT \n[#PP_INDENT]
+  .HEADING_STYLE 1 NUMBER
 </span>
+Mom will alert you to this on stderr.
 </p>
 </div>
 
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-Paragraph heads in &#8220;first paragraphs&#8221;, as defined in
-<a href="#para-indent-first">Indenting initial paragraphs</a>,
-are not indented unless you turn
-<kbd><a href="#indent-first-paras">INDENT_FIRST_PARAS</a></kbd>
-on.
-</p>
-</div>
+<!-- -SUBHEAD- -->
 
-<h4 id="parahead-space" class="docs" style="margin-top: -.25em;">3. Horizontal 
space</h4>
+<div id="subhead" class="box-macro-args">
+Macro: <b>SUBHEAD</b> <kbd class="macro-args">[ NAMED &lt;id&gt; ] 
&quot;&lt;text of head&gt;&quot; &quot;&lt;another line&gt;&quot;...</kbd>
+</div>
 
 <p>
-The default amount of horizontal space between a parahead and the
-text that begins the body of a paragraph is 2/3 of an
-<a href="definitions.html#em">em</a>
-for 
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>)
-and 1
-<a href="definitions.html#figurespace">figure space</a>
-for
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>).
+When invoked for the first time, with or without
+<a href="oldstyle-headings">OLDSTYLE_HEADINGS</a>,
+SUBHEAD sets the parameters for level-2 headings to mom&#8217;s old
+SUBHEAD defaults, then prints the subhead as a level-2 heading.
+The <kbd>NAMED &lt;id&gt;</kbd> optional argument is explained in
+the description of
+<a href="#heading">HEADING</a>.
 </p>
 
 <p>
-The default for <kbd>TYPEWRITE</kbd> is fixed, but if the default
-for <kbd>TYPESET</kbd> doesn&#8217;t suit you, you can change it
-with the macro, PARAHEAD_SPACE.
-</p>
-<p>
-PARAHEAD_SPACE takes just one argument: the amount of space you
-want, with a
-<a href="definitions.html#unitofmeasure">unit of measure</a>
-appended.  Thus, if you want the horizontal space between a parahead
-and the start of paragraph text to be 6
-<a href="definitions.html#picaspoints">points</a>,
-you&#8217;d do:
+The former style defaults for SUBHEAD were:
 <br/>
 <span class="pre-in-pp">
-  .PARAHEAD_SPACE 6p
+  FAMILY          = prevailing document family
+  FONT            = bold (TYPESET); italic, ie underlined (TYPEWRITE)
+  SIZE            = +.5 (TYPESET); +0 (TYPEWRITE)
+  QUAD            = L 
+  BASELINE_ADJUST = 1/8 the current leading
 </span>
 </p>
 
-<h4 id="number-paraheads" class="docs" style="margin-top: -1.25em;">4. 
Numbering</h4>
-
-<p>
-If you&#8217;d like your paraheads numbered, simply invoke
-<kbd>.NUMBER_PARAHEADS</kbd> with no argument. Mom
-will number all subsequent paraheads automatically (in ascending
-order, naturally).
-</p>
-
-<p>
-If, in addition to numbering paraheads, you also request that
-<a href="#head-intro">heads</a>
-and
-<a href="#subhead-intro">subheads</a>
-be numbered, the head and/or subhead number will be included in the
-parahead number (separated by a period [dot]).
-</p>
-
-<p>
-Should you wish to stop parahead numbering, invoke
-<kbd>.NUMBER_PARAHEADS</kbd> with any argument (<kbd>OFF, QUIT, END,
-X</kbd>...).  Parahead numbering will cease.
-</p>
-
-<p>
-See also
-<a href="#prefix-chapter-number">Prefixing chapter numbers</a>
-if you&#8217;d like chapter numbers prepended to the paragraph head
-numbers.
-</p>
-
-<h4 id="reset-parahead-number" class="docs" style="margin-top: -.25em;">5. 
Reset paragraph head numbering</h4>
-
-<p>
-Should you wish to reset the parahead number to &#8220;1&#8221;,
-invoke
-<span class="pre-in-pp">
-  .RESET_PARAHEAD_NUMBER
-</span>
-with no argument.  If, for some reason, you want mom to use a
-parahead number that is not the next in ascending order (i.e. the
-last parahead number + 1), invoke <kbd>.RESET_PARAHEAD_NUMBER</kbd>
-with the number you want, e.g.
+<div class="box-tip">
+<p class="tip">
+<span class="note">Note:</span>
+The macro, NUMBER_SUBHEADS, from pre-2.0 versions of mom, can still be
+used, though it is now a wrapper for
 <br/>
 <span class="pre-in-pp">
-  .RESET_PARAHEAD_NUMBER 7
+  .HEADING_STYLE 2 NUMBER
 </span>
-Your next parahead will be numbered &#8220;7&#8221; and subsequent
-paraheads will be numbered in ascending order from &#8220;7&#8221;.
+Mom will alert you to this on stderr.
 </p>
+</div>
 
-<!-- -PREFIX_CHAPTER_NUMBER- -->
+<!-- -SUBSUBHEAD- -->
 
-<div class="examples-container" style="margin-bottom: 1.5em;">
-<div id="prefix-chapter-number" class="macro-id-overline" style="border-top: 
none;">
-<h3 class="macro-id" style="margin-top: 9px; text-transform: none; font-size: 
105%;">Prefixing chapter numbers</h3>
-</div>
+<div id="subsubhead" class="box-macro-args">
+Macro: <b>SUBSUBHEAD</b> <kbd class="macro-args">[ NAMED &lt;id&gt; ] 
&quot;&lt;text of head&gt;&quot; &quot;&lt;another line&gt;&quot;...</kbd>
 
-<div class="box-macro-args" style="width: 686px;">
-Macro: <b>PREFIX_CHAPTER_NUMBER</b> <kbd class="macro-args">&lt;none&gt; | 
&lt;chapter number as digit&gt; | &lt;anything&gt;</kbd>
 </div>
 
 <p>
-If you&#8217;ve requested numbering of heads, subheads, subsubheads
-and/or paragraph heads (with
-<a href="#number-heads">NUMBER_HEADS</a>,
-<a href="#number-subheads">NUMBER_SUBHEADS,</a>
-<a href="#number-subheads">NUMBER_SUBSUBHEADS</a>
-and/or
-<a href="#number-paraheads">NUMBER_PARAHEADS</a>)
-and you&#8217;d like mom, in addition, to prefix
-a chapter number to the numbering scheme, you can do so with
-PREFIX_CHAPTER_NUMBER.
+When invoked for the first time, with or without
+<a href="oldstyle-headings">OLDSTYLE_HEADINGS</a>,
+SUBSUBHEAD sets the parameters for level-3 headings to mom&#8217;s old
+SUBSUBHEAD defaults, then prints the subsubhead as a level-3 heading.
+The <kbd>NAMED &lt;id&gt;</kbd> optional argument is explained in
+the description of
+<a href="#heading">HEADING</a>.
 </p>
 
 <p>
-After you invoke <kbd>.PREFIX_CHAPTER_NUMBER</kbd>, mom will prepend
-the current chapter number to all subsequent head elements (main
-heads, subheads or paragraph heads) for which you have requested
-numbering.  Thus, assuming chapter number twelve (12):
+The former style defaults for SUBSUBHEAD were:
 <br/>
 <span class="pre-in-pp">
-          1. FIRST MAIN HEAD
-          ------------------
-
-  1.1. First Subhead Under Main Head
-</span>
-becomes
-<br/>
-<span class="pre-in-pp">
-          12.1. FIRST MAIN HEAD
-          ---------------------
-
-  12.1.1. First Subhead Under Main Head
+  FAMILY          = prevailing document family
+  FONT            = italic (TYPESET); roman (TYPEWRITE)
+  SIZE            = +.5 (TYPESET); +0 (TYPEWRITE)
+  QUAD            = L 
+  BASELINE_ADJUST = 1/8 the current leading
 </span>
 </p>
 
-<p>
-When you invoke <kbd>.PREFIX_CHAPTER_NUMBER</kbd> without an
-argument, mom checks to see whether the argument
-you passed to
-<a href="docprocessing.html#chapter">CHAPTER</a>
-is a digit.  If it is, she immediately starts pre-pending the
-current chapter number to numbered head elements.  If it isn&#8217;t
-(say you&#8217;ve called your chapter &#8220;One&#8221; instead of
-&#8220;1&#8221;), mom will abort with a request that
-you pass PREFIX_CHAPTER_NUMBER a digit representing
-the current chapter number.
-</p>
-
-<p>
-In collated documents, mom automatically increments
-the digit used by PREFIX_CHAPTER_NUMBER by one
-(current chapter digit + 1) every time you invoke
-<a href="rectoverso.html#collate"><kbd>.COLLATE</kbd></a>,
-even if you&#8217;ve (temporarily) turned off the prefixing of chapter
-numbers.  Thus, even if you call your chapters &#8220;One&#8221;,
-&#8220;Two&#8221;, &#8220;Three&#8221; instead of &#8220;1&#8221;,
-&#8220;2&#8221;, &#8220;3&#8221;, mom will Do
-The Right Thing with respect to numbering head elements in
-all collated chapters following the first invocation of
-PREFIX_CHAPTER_NUMBER (assuming, of course,
-that the collated chapters are in incrementing order; if
-not, you <i>must</i> must put
+<div class="box-tip">
+<p class="tip">
+<span class="note">Note:</span>
+The macro, NUMBER_SUBSUBHEADS, from pre-2.0 versions of mom, can still be
+used, though it is now a wrapper for
 <br/>
 <span class="pre-in-pp">
-  .PREFIX_CHAPTER_NUMBER &lt;chapter number&gt;
+  .HEADING_STYLE 3 NUMBER
 </span>
-somewhere after the invocation of COLLATE and
-before the first numbered head element of each collated document).
-</p>
-
-<p>
-PREFIX_CHAPTER_NUMBER can be disabled by passing
-it any argument other than a digit (e.g. <b>OFF, QUIT, END,
-X</b>, etc), although, as noted above, mom
-will keep, and&mdash;in the case of collated
-documents&mdash;increment the chapter number, allowing you to turn
-prefixing of
-chapter numbers to numbered head elements off and on according to
-your needs or whims.
-</p>
-
-<p>
-<span class="note">Note:</span>
-Because PREFIX_CHAPTER_NUMBER takes an (optional) digit representing
-the chapter number, it&#8217;s use need not be restricted to
-<a href="docprocessing.html#doctype">DOCTYPE <kbd>CHAPTER</kbd></a>.
-You can use it with any document type.  Furthermore, even if
-your doctype isn&#8217;t <kbd>CHAPTER</kbd>, you can identify
-the document as a chapter <i>for the purposes of numbering head
-elements</i> by invoking the macro,
-<a href="docprocessing.html#chapter"><kbd>.CHAPTER</kbd></a>,
-with a
-<a href="definitions.html#numericargument">numeric argument</a>
-in your document setup. 
+Mom will alert you to this on stderr.
 </p>
 </div>
 
@@ -2063,7 +1765,7 @@
 <p>
 Linebreaks (&#8220;author linebreaks&#8221;, &#8220;section
 breaks&#8221;) are gaps in the vertical flow of running text that
-indicate a shift in content (e.g. a scene change in story).  They
+indicate a shift in content (eg a scene change in story).  They
 are frequently set off by typographic symbols, sometimes whimsical
 in nature.
 </p>
@@ -2123,8 +1825,8 @@
 </p>
 
 <p>
-The first argument is any valid groff character (e.g. <kbd>*</kbd>
-[an asterisk], <kbd>\(dg</kbd> [a dagger], <kbd>\f(ZD\N'141\fP</kbd>
+The first argument is any valid groff character (eg <kbd>*</kbd>
+[an asterisk], <kbd>\[dg]</kbd> [a dagger], <kbd>\f[ZD]\N'141\fP</kbd>
 [an arbitrary character from Zapf Dingbats], <kbd>\l'4P'</kbd> [a
 4-pica long rule]). Mom sets the character centred on the current
 line length.  (See <kbd>man groff_char</kbd> for a list of all
@@ -2157,7 +1859,7 @@
 <span class="pre-in-pp">
   .LINEBREAK_CHAR * 3 -3p
 </span>
-i.e. three asterisks, lowered 3 points from their normal vertical
+ie three asterisks, lowered 3 points from their normal vertical
 position (for
 <a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>;
 the vertical adjustment is -2 points for
@@ -2167,7 +1869,7 @@
 <h4 id="linebreak-color" class="docs" style="margin-top: -.25em; 
margin-bottom: .5em;">2. Linebreak colour</h4>
 
 <div class="box-macro-args">
-Macro: <b>LINEBREAK_COLOR</b> <kbd class="macro-args">&lt;color name&gt;</kbd>
+Macro: <b>LINEBREAK_COLOR</b> <kbd class="macro-args">&lt;colourname&gt;</kbd>
 </div>
 <p class="alias" style="margin-bottom: 0;">
 <i>Alias:</i> <b>SECTION_COLOR</b>
@@ -2208,7 +1910,7 @@
 
 <p>
 Since mom originally came into being to serve the needs of creative
-writers (i.e. novelists, short story writers, etc.&mdash;not
+writers (ie novelists, short story writers, etc.&mdash;not
 to cast aspersions on the creativity of mathematicians and
 programmers), she sets quotes in italics
 <a href="docprocessing.html#printstyle">(PRINTSTYLE <kbd>TYPESET</kbd>)</a>
@@ -2217,12 +1919,12 @@
 indented from the left margin.  Obviously, she&#8217;s thinking
 &#8220;quotes from poetry or song lyrics&#8221;, but with the
 <a href="#quote-control">QUOTE control macros</a>
-you can change her defaults so QUOTE serves other needs, e.g.
+you can change her defaults so QUOTE serves other needs, eg
 entering verbatim snippets of programming code, command line
 instructions, and so on.  (See the
 <a href="#code">CODE</a>
-for a convenience macro to assist in including programming code
-snippets in documents.)
+for a convenience macro to assist in including code snippets in
+documents.)
 </p>
 
 <h3 id="quote-spacing" class="docs">QUOTE spacing</h3>
@@ -2236,7 +1938,7 @@
 <a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
 it&#8217;s 1/2 of the prevailing
 <a href="definitions.html#leading">leading</a>
-if the quote fits fully on the page (i.e. with running text above
+if the quote fits fully on the page (ie with running text above
 and below it), otherwise it&#8217;s a full linespace either above
 or below as is necessary to balance the page to the bottom margin.
 This behaviour can be changed with the control macro
@@ -2245,27 +1947,8 @@
 
 <div class="box-tip">
 <h2 id="quote-spacing-notes" class="docs" style="padding-top: 9px; font-size: 
100%;">Further notes on quote spacing</h2>
-<p class="cefaults">
-As of version 1.3 of mom, handling of the vertical whitespace around
-quotes changed slightly from its original implementation.
-</p>
-
-<p>
-In versions of mom prior to 1.3, it was not possible to alter the
-<a href="definitions.html#leading">leading</a>
-of quotes and blockquotes (which was the same as the document
-leading), ensuring that the vertical whitespace remained consistent,
-as described above.
-</p>
-
-<p>
-As of version 1.3, it became possible to change the
-leading of quotes and blockquotes with <kbd>.QUOTE_AUTOLEAD</kbd> and
-<kbd>BLOCKQUOTE_AUTOLEAD</kbd>, with the following changes in
-mom&#8217;s behaviour:
-</p>
 
-<p>
+<p clas"defaults">
 If your quote (or blockquote) leading differs from the document
 leading, mom attempts to observe the same rules for vertical
 whitespace outlined above; however, she will also insert a small,
@@ -2281,15 +1964,19 @@
 which, by and large, processes text on a line-per-line basis.)
 </p>
 
+<h3 id="no-shim" class="docs">Disable shimming of quotes and blockquotes</h3>
+
 <p>
-If you don&#8217;t want the behaviour described above (i.e. you
-don&#8217;t want mom shimming [possibly irregularly linespaced]
-quotes or blockquotes), issue the macro
+If you don&#8217;t want the behaviour described above (ie you
+don&#8217;t want mom shimming 
+quotes and blockquotes), issue the macro
 <br/>
 <span class="pre-in-pp">
   .NO_SHIM
 </span>
-prior to invoking <kbd>.QUOTE</kbd> or <kbd>.BLOCKQUOTE</kbd>.
+in the style sheet section of your document (ie after PRINTSTYLE but
+before START), which will disable shimming globally, or on a
+per-instance basis prior to <kbd>.QUOTE</kbd> or <kbd>.BLOCKQUOTE</kbd>.
 </p>
 
 <p>
@@ -2299,6 +1986,13 @@
 <kbd>QUIT, END, X</kbd>, etc).
 </p>
 
+<p>
+Please note that <kbd>NO_SHIM</kbd> disables shimming before
+headings, and the
+<a href="docprocessing.html#shim">SHIM</a>
+macro itself.
+</p>
+
 <p class="tip-bottom">
 If you don&#8217;t provide mom with a QUOTE_AUTOLEAD, quotes are
 leaded at the default for normal running text, meaning that multiple
@@ -2320,7 +2014,7 @@
 QUOTE is a toggle macro.  To begin a section
 of quoted text, invoke it with no argument, then type in your
 quote.  When you&#8217;re finished, invoke <kbd>.QUOTE</kbd> with any
-argument (e.g. <kbd>OFF, END, X, Q</kbd>...) to turn it off.  Example:
+argument (eg <kbd>OFF, END, X, Q</kbd>...) to turn it off.  Example:
 <br/>
 <span class="pre-in-pp">
   .QUOTE
@@ -2340,7 +2034,6 @@
   <li><a href="#quote-general">Family/font/size/leading/colour/indent</a></li>
   <li><a href="#always-fullspace-quotes">Spacing above and below quotes 
(typeset only)</a></li>
   <li><a href="#underline-quotes">Underlining quotes (typewrite only)</a></li>
-  <li><a href="#break-quote">Manually break a footnoted quote that crosses 
pages/columns (deprecated)</a></li>
 </ol>
 </div>
 
@@ -2354,7 +2047,7 @@
 <span class="pre defaults">
 .QUOTE_FAMILY   default = prevailing document family; default is Times Roman
 .QUOTE_FONT     default = italic; underlined in TYPEWRITE
-.QUOTE_SIZE     default = +0 (i.e. same size as paragraph text)
+.QUOTE_SIZE     default = +0 (ie same size as paragraph text)
 .QUOTE_AUTOLEAD default = none; leading of quotes is the same as paragraphs
 .QUOTE_COLOR    default = black
 .QUOTE_INDENT  (see below, "Quote indent")
@@ -2364,45 +2057,37 @@
 <h4 id="quote-indent" class="docs" style="margin-top: -1.5em;">Quote 
indent</h4>
 
 <p>
-Prior to version 1.4-b, mom allowed only the passing of an integer
-to the macro, <kbd>.QUOTE_INDENT</kbd>.  The integer represented the
-amount by which to multiply the argument passed to
-<kbd><a href="#para-indent">PARA_INDENT</a></kbd>
-to arrive at an indent for quotes (and blockquotes).
+<kbd>QUOTE_INDENT</kbd> takes one of two kinds of argument: an integer
+representing the amount by which to multiply the argument passed to
+<a href="#para-indent"><kbd>.PARA_INDENT</kbd></a>
+(by default, 2
+<a href="definitions.html#em">ems</a>
+for TYPESET, 3
+<a href="definitions.html#picaspoints">picas</a>
+for TYPEWRITE) to arrive at the quote indent, or a distance with a
+<a href="definitions.html#unitofmesaure">unit of measure</a>
+appended.  Both result in quotes being indented equally from the
+left and right margins.
 </p>
 
 <p>
-As of version 1.4-b, you can now append a
-<a href="definitions.html#unitofmeasure">unit of measure</a>
-to the argument passed to <kbd>.QUOTE_INDENT</kbd>, thus
-setting an absolute indent, relative to nothing.  The old
-behaviour is still respected, though; in other words, if you
-pass <kbd>.QUOTE_INDENT</kbd> an integer with no unit of measure
-appended, the integer represents the amount by which to multiply
-<kbd>.PARA_INDENT</kbd> to arrive at an indent for quotes (and
-blockquotes).
+The default value for QUOTE_INDENT is 3 (for
+<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>)
+and 1 (for
+<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>).
 </p>
 
 <div class="box-tip">
-<p class="tip">
+<p class="tip-top">
 <span class="note">Note:</span>
-If your PARA_INDENT is 0 (i.e. no indenting of the first line of
+If your PARA_INDENT is 0 (ie no indenting of the first line of
 paragraphs), you <i>must</i> set a QUOTE_INDENT yourself, with a
 unit of measure appended to the argument. Mom has no default for
 QUOTE_INDENT if paragraph first lines are not being indented.
 </p>
-</div>
-
-<p>
-The default value for QUOTE_INDENT is 3 (for
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>)
-and 1 (for
-<a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>).
-</p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
+<p class="tip-bottom">
+<span class="note">Additional note:</span>
 QUOTE_INDENT also sets the indent for
 <a href="#blockquote">blockquotes</a>.
 </p>
@@ -2444,53 +2129,16 @@
 </p>
 
 <p>
-If you not only wish that mom not underline
-quotes, but also that she set them in italic, you must follow each
-instance of QUOTE with the typesetting macro
+If you not only wish that mom not underline quotes, but also that
+she set them in italic, you must follow each instance of QUOTE with
+the typesetting macro
 <a href="typesetting.html#font">FT I</a>.
-Furthermore, since mom underlines all instances of
-italics by default in <b>PRINTSTYLE TYPEWRITE</b>, you
-must also make sure that ITALIC_MEANS_ITALIC is
-enabled (see
+Furthermore, since mom underlines all instances of italics by
+default in <b>PRINTSTYLE TYPEWRITE</b>, you must also make sure that
+ITALIC_MEANS_ITALIC is enabled (see
 <a href="docprocessing.html#typewrite-control">PRINTSTYLE TYPEWRITE control 
macros</a>).
 </p>
 
-<h4 id="break-quote" class="docs">4. Manually break a footnoted quote that 
crosses pages/columns (deprecated)</h4>
-
-<div class="box-tip">
-<p class="tip">
-<i>As of version 1.1.9, the macro</i> BREAK_QUOTE <i>became obsolete
-(or, at least, should have become obsolete.)  It remains here for
-backward compatibility with documents created prior to 1.1.9, and
-just in case despite my efforts to make it obsolete you still
-encounter the problem it&#8217;s supposed to fix.  Should you find
-yourself having to use</i> BREAK_QUOTE <i>while running</i> mom
-1.1.9 <i>or higher, please notify me immediately.</i>
-</p>
-</div>
-
-<p style="margin-top: -.5em;">
-Exceptionally, a quote or blockquote containing a footnote may
-cross a page or column.  When this happens, the footnote marker may
-not be correct for its position relative to other footnotes on the
-page, and the footnote itself may appear on the wrong page or at the
-bottom of the wrong column.  When this happens, study your output to
-determine the precise point at which the quote breaks (or at which
-you want it to break), and add
-<span class="pre-in-pp">
-  .BREAK_QUOTE
-</span>
-on a line by itself afterwards.  No other intervention is required,
-and the footnote(s) will be marked correctly and appear on the
-correct page.
-</p>
-
-<p>
-<kbd>.BREAK_QUOTE</kbd> may be used with both quotes and
-blockquotes, and hence is aliased as <kbd>.BREAK_BLOCKQUOTE</kbd>,
-<kbd>BREAK_CITATION</kbd> and <kbd>BREAK_CITE</kbd>.
-</p>
-
 <div class="rule-short"><hr/></div>
 
 <!-- ==================================================================== -->
@@ -2546,7 +2194,7 @@
 BLOCKQUOTE is a toggle macro.  To begin a cited passage, invoke
 the tag with no argument, then type in your blockquote.  When
 you&#8217;re finished, invoke <kbd>.BLOCKQUOTE</kbd> with any
-argument (e.g. <kbd>OFF, END, X, Q</kbd>...) to turn it off.
+argument (eg <kbd>OFF, END, X, Q</kbd>...) to turn it off.
 Example:
 <br/>
 <span class="pre-in-pp">
@@ -2578,7 +2226,6 @@
 <ol style="margin-top: .5em; padding-bottom: .5em;">
   <li><a 
href="#blockquote-general">Family/font/size/leading/colour/quad/indent</a></li>
   <li><a href="#bq-always-fullspace-quotes">Spacing above and below (typeset 
only)</a></li>
-  <li><a href="#break-quote">Manually break a footnoted blockquote that 
crosses pages/columns</a></li>
 </ol>
 </div>
 
@@ -2603,48 +2250,45 @@
 <h4 id="blockquote-indent" class="docs" style="margin-top: -1.5em;">Blockquote 
indent</h4>
 
 <p>
-Prior to version 1.4-b, mom allowed only the passing of an integer
-to the macro, BLOCKQUOTE_INDENT.  The integer represented the amount
-by which to multiply the argument passed to
-<kbd><a href="#para-indent">PARA_INDENT</a></kbd>
-to arrive at an indent for blockquotes (and quotes).
-</p>
-
-<p>
-As of version 1.4-b, you can append a
-<a href="definitions.html#unitofmeasure">unit of measure</a>
-to the argument passed to <kbd>.BLOCKQUOTE_INDENT</kbd>, thus
-setting an absolute indent, relative to nothing.  The old
-behaviour is still respected, though.  In other words, if you pass
-<kbd>.BLOCKQUOTE_INDENT</kbd> an integer with no unit of measure
-appended, the integer represents the amount by which to multiply
-<kbd>.PARA_INDENT</kbd> to arrive at an indent for blockquotes (and
-quotes).
+<kbd>BLOCKQUOTE_INDENT</kbd> takes one of two kinds of argument: an
+integer representing the amount by which to multiply the argument
+passed to
+<a href="#para-indent"><kbd>.PARA_INDENT</kbd></a>
+(by default, 2
+<a href="definitions.html#em">ems</a>
+for TYPESET, 3
+<a href="definitions.html#picaspoints">picas</a>
+for TYPEWRITE) to arrive at the blockquote indent, or a distance with a
+<a href="definitions.html#unitofmesaure">unit of measure</a>
+appended.  Both result in blockquotes being indented equally from
+the left and right margins.
 </p>
 
 <p>
-The default value for <kbd>.BLOCKQUOTE_INDENT</kbd> is 3 (for
+The default value for BLOCKQUOTE_INDENT is 3 (for
 <a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>)
-and 2 (for PRINTSTYLE
+and 1 (for
 <a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>).
 </p>
 
 <div class="box-tip">
 <p class="tip-top">
 <span class="note">Note:</span>
-If your PARA_INDENT is 0 (i.e. no indenting of the first line of
-paragraphs), you must set a BLOCKQUOTE_INDENT yourself, with a
-unit of measure appended to the argument. Mom has no default for
+If your PARA_INDENT is 0 (ie no indenting of the first line of
+paragraphs), you <i>must</i> set a BLOCKQUOTE_INDENT yourself, with
+a unit of measure appended to the argument.  Mom has no default for
 BLOCKQUOTE_INDENT if paragraph first lines are not being indented.
 </p>
 
 <p class="tip-bottom">
-<span class="additional-note">Additional note:</span>
+<span class="note">Additional note:</span>
 BLOCKQUOTE_INDENT also sets the indent for
-<a href="#quote">QUOTES</a>.
+<a href="#quote">quotes</a>.
 </p>
 </div>
 
+
+
 <h4 id="bq-always-fullspace-quotes" class="docs">2. Spacing above and below 
blockquotes (typeset only)</h4>
 
 <p>
@@ -2717,7 +2361,7 @@
 
 <p>
 Passing any argument other than <kbd>BR</kbd>, <kbd>BREAK</kbd>
-or <kbd>SPREAD</kbd> to CODE (e.g. <kbd>OFF, QUIT, END, X,</kbd>
+or <kbd>SPREAD</kbd> to CODE (eg <kbd>OFF, QUIT, END, X,</kbd>
 etc.) turns CODE off and returns the family, font, smartquotes
 and (if applicable) underlining of quotes to their former state.
 If you&#8217;ve used the inline escape, <kbd>\*[CODE]</kbd>, to
@@ -2744,7 +2388,7 @@
 <kbd>.CODE</kbd> does not cause a line break when
 you&#8217;re in a
 <a href="definitions.html#filled">fill mode</a>
-(i.e.
+(ie
 <a href="typesetting.html#justify">JUSTIFY</a>
 or
 <a href="typesetting.html#quad">QUAD</a>
@@ -2759,12 +2403,12 @@
 you want a break afterwards, you must supply it manually with
 <a href="typesetting.html#br">BR</a>
 unless what follows immediately is a macro that automatically causes
-a break (e.g.
+a break (eg
 <a href="#pp">PP</a>).
 </p>
 
 <p>
-In all likelihood, if you want the situation described above (i.e. a
+In all likelihood, if you want the situation described above (ie a
 break before and after CODE), what you probably want is to use
 <a href="quote">QUOTE</a>
 in conjunction with CODE, like this:
@@ -2772,7 +2416,7 @@
 <span class="pre-in-pp">
   .QUOTE
   .CODE
-  $ echo "Hello, world" | sed -e 's/Hello,/Goodbye, cruel'
+  $ echo "Hello, world" | sed -e 's/Hello,/Goodbye, cruel/'
   .CODE OFF
   .QUOTE OFF
 </span>
@@ -2795,7 +2439,7 @@
 <h3 id="code-control" class="docs defaults">CODE control macros and 
defaults</h3>
 
 <ol style="margin-top: .5em; padding-bottom: .5em;">
-  <li><a href="#code-general">Family/Font/Color</a></li>
+  <li><a href="#code-general">Family/Font/Colour</a></li>
   <li><a href="#code-size">Size</a></li>
 </ol>
 </div>
@@ -2927,7 +2571,7 @@
 </div>
 
 <p>
-Invoked by itself (i.e. with no argument), LIST
+Invoked by itself (ie with no argument), LIST
 initializes a list (with bullets as the default enumerator).
 Afterwards, each block of input text preceded by
 <kbd><a href="#item">.ITEM</a></kbd>,
@@ -2942,7 +2586,7 @@
 you must supply an enumerator (and optionally, a separator) for the
 list, unless you want mom&#8217;s default enumerator, which is a
 bullet.  Within nested lists, mom stores the enumerator, separator
-and indent for any list you return <i>backwards</i> to (i.e. with
+and indent for any list you return <i>backwards</i> to (ie with
 <kbd>.LIST OFF</kbd>), but does not store any information for lists
 you move <i>forward</i> to.
 </p>
@@ -2966,7 +2610,7 @@
 <p>
 The arguments, <kbd>ROMAN&lt;n&gt;</kbd> and
 <kbd>roman&lt;n&gt;</kbd>, are special.  You must append to them
-a digit (arabic, e.g. "1" or "9" or "17") saying how many items a
+a digit (arabic, eg "1" or "9" or "17") saying how many items a
 particular roman-numeralled LIST is going to have. Mom requires this
 information in order to align roman numerals sensibly, and will
 abort&mdash;with a message &mdash; if you don&#8217;t provide it.
@@ -3069,7 +2713,7 @@
 <h3 class="docs">The third argument &ndash; prefix style</h3>
 
 <p>
-Additionally, you may give a prefix (i.e. a character
+Additionally, you may give a prefix (ie a character
 that comes <i>before</i> the enumerator) when your
 enumerator style for a particular list is <kbd>DIGIT</kbd>,
 <kbd>ALPHA</kbd>, <kbd>alpha</kbd>, <kbd>ROMAN&lt;n&gt;</kbd> or
@@ -3113,7 +2757,7 @@
 Any single argument to <kbd>LIST</kbd> other than
 <kbd>BULLET</kbd>, <kbd>DASH</kbd>, <kbd>DIGIT</kbd>,
 <kbd>ALPHA</kbd>, <kbd>alpha</kbd>, <kbd>ROMAN&lt;n&gt;</kbd>,
-<kbd>roman&lt;n&gt;</kbd> or <kbd>USER</kbd> (e.g.
+<kbd>roman&lt;n&gt;</kbd> or <kbd>USER</kbd> (eg
 <kbd>LIST&nbsp;OFF</kbd> or <kbd>LIST&nbsp;BACK</kbd>) takes you out
 of the current list.
 </p>
@@ -3126,7 +2770,7 @@
 
 <p>
 If you are in a nested list, mom moves you back one list-level
-(i.e. does not take you out of the list structure) and restores the
+(ie does not take you out of the list structure) and restores the
 enumerator, separator and indent appropriate to that level.
 </p>
 
@@ -3382,7 +3026,7 @@
 
 <p>
 If you&#8217;d like the roman numerals to line
-up flush right (i.e. be padded "left"), simply
+up flush right (ie be padded "left"), simply
 invoke <kbd>.PAD_LIST_DIGITS&nbsp;LEFT</kbd> after
 <kbd>.LIST&nbsp;ROMAN&lt;n&gt;</kbd> or
 <kbd>.LIST&nbsp;roman&lt;n&gt;</kbd> and before <kbd>.ITEM</kbd>.
@@ -3476,7 +3120,7 @@
 <a href="definitions.html#outputline">output line</a>
 to have.  The optional arguments which <kbd>lines to number</kbd>
 and <kbd>gutter</kbd> allow you to state which lines should
-be numbered (e.g. every five or every ten lines), and the gutter to
+be numbered (eg every five or every ten lines), and the gutter to
 place between line numbers and
 <a href="definitions.html#running">running text</a>.
 </p>
@@ -3929,7 +3573,7 @@
 <p>
 If mom sees that a portion of a footnote cannot be fit on its page,
 she carries that portion over to the next page.  If an entire
-footnote can&#8217;t be fit on its page (i.e.  FOOTNOTE has been
+footnote can&#8217;t be fit on its page (ie  FOOTNOTE has been
 called too close to the bottom), she defers the footnote to the next
 page, but sets it with the appropriate marker from the previous
 page.
@@ -3946,7 +3590,7 @@
 
 <p>
 In the unfortunate happenstance that a deferred footnote is the
-only footnote on its page (i.e. it&#8217;s marked in the document
+only footnote on its page (ie it&#8217;s marked in the document
 body with a star) and the page it&#8217;s deferred to has its own
 footnotes, mom separates the deferred footnote from the page&#8217;s
 proper footnote(s) with a blank line.  This avoids the confusion
@@ -3968,7 +3612,7 @@
 </p>
 
 <p>
-Very exceptionally, two footnotes may have to be deferred (e.g. one
+Very exceptionally, two footnotes may have to be deferred (eg one
 occurs on the second to last line of a page, and another on the last
 line).  In such a circumstance, mom does not add
 a blank after the second deferred footnote.  If you&#8217;d like a blank
@@ -4004,17 +3648,6 @@
 problem.
 </p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-Exceptionally, you may encounter problems
-with footnotes inside quotes and blockquotes that cross a page or
-column.  See
-<a href="#break-quote">BREAK_QUOTE</a>
-for a solution.
-</p>
-</div>
-
 <h3 id="fn-and-punct" class="docs">Footnote markers and punctuation in the 
running text</h3>
 
 <ol style="margin-left: -1.25em;">
@@ -4213,7 +3846,7 @@
 <p>
 FOOTNOTE is a toggle macro, therefore invoking it on a line by
 itself allows you to enter a footnote in the body of a document.
-Invoking it with any argument other than INDENT (i.e. <kbd>OFF,
+Invoking it with any argument other than INDENT (ie <kbd>OFF,
 QUIT, END, X...</kbd>) tells mom you&#8217;re finished.
 </p>
 
@@ -4264,7 +3897,7 @@
 or
 <a href="typesetting.html#quad">QUAD</a>),
 the line <i>after</i> a <kbd>.FOOTNOTE&nbsp;OFF</kbd> should be
-entered as if there were no interruption in the input text, i.e.
+entered as if there were no interruption in the input text, ie
 the line should begin with a literal space or punctuation mark (see
 explanation and examples
 <a href="#fn-and-punct">here</a>).
@@ -4454,12 +4087,12 @@
 what you want is a single line number, you need only invoke
 <kbd>.FOOTNOTE</kbd>, <i>without the terminating</i> <kbd>\c</kbd>,
 at the appropriate place in running text.  Input lines after the
-footnote has been terminated (e.g. with <kbd>.FOOTNOTE OFF</kbd>)
+footnote has been terminated (eg with <kbd>.FOOTNOTE OFF</kbd>)
 must begin at the left margin.
 </p>
 
 <p>
-If you want a range of line numbers (e.g.&nbsp;[5-11]&nbsp;),
+If you want a range of line numbers (eg&nbsp;[5-11]&nbsp;),
 insert, directly into the first line of the range you want,
 the <a href="definitions.html#inlines">inline escape</a>,
 <kbd>\*[FN_MARK]</kbd>.  For the terminating line number of the
@@ -4548,7 +4181,7 @@
 <p style="margin-left: .5em;">
 Finally, if your footnote marker style is <kbd>LINE</kbd>, you may
 instruct mom to do &#8220;run-on style&#8221; footnotes.  Run-on
-footnotes do not treat footnotes as discrete entities, i.e. each
+footnotes do not treat footnotes as discrete entities, ie each
 beginning on a new line.  Rather, each footnote is separated from
 the footnote before it by horizontal space in the running line, so
 that the footnotes on any given page form a continuous block, like
@@ -4795,7 +4428,7 @@
 <a href="#blockquote-control">blockquote control macros</a>.
 However, you must make the changes <i>within</i> each endnote,
 prior to invoking <kbd>.QUOTE</kbd> or <kbd>.BLOCKQUOTE</kbd>,
-and undo them prior to terminating the endnote (i.e. before
+and undo them prior to terminating the endnote (ie before
 <kbd>.ENDNOTE&nbsp;OFF</kbd>), otherwise the changes will affect
 subsequent quotes and blockquotes that appear in the document body
 as well.
@@ -4879,7 +4512,7 @@
 <p>
 ENDNOTE is a toggle macro, therefore invoking it on a line by itself
 allows you to enter an endnote in the body of a document.  Invoking
-it with any other argument (i.e. <kbd>OFF, QUIT, END, X...</kbd>)
+it with any other argument (ie <kbd>OFF, QUIT, END, X...</kbd>)
 tells mom that you&#8217;ve finished the endnote.
 </p>
 
@@ -4919,7 +4552,7 @@
 or
 <a href="typesetting.html#quad">QUAD</a>,
 the line after <kbd>.ENDNOTE&nbsp;OFF</kbd> should be
-entered as if there were no interruption in the input text, i.e.
+entered as if there were no interruption in the input text, ie
 the line should begin with a literal space or punctuation mark (see
 explanation and examples for footnotes, which apply equally to
 endnotes,
@@ -4941,7 +4574,7 @@
 <p class="tip-bottom">
 If your ENDNOTE_MARKER_STYLE is LINE, do not use the <kbd>\c</kbd>
 escape, and enter the line after <kbd>.ENDNOTE OFF</kbd> normally,
-i.e. at your text editor&#8217;s left margin.
+ie at your text editor&#8217;s left margin.
 </p>
 </div>
 
@@ -4958,13 +4591,13 @@
 <p>
 Unlike footnotes, which mom automatically outputs at the bottom
 of pages, endnotes must be explicitly output by you, the
-user. ENDNOTES, by itself (i.e. without any argument), is the macro
+user. ENDNOTES, by itself (ie without any argument), is the macro
 to do this.
 </p>
 
 <p>
 Typically, you&#8217;ll use ENDNOTES at the end of a document.  If
-it&#8217;s a single (i.e. not collated) document, mom will print
+it&#8217;s a single (ie not collated) document, mom will print
 the endnotes pertaining to it.  If it&#8217;s a collated document,
 mom will print all the endnotes contained within all sections of
 the document (typically chapters), appropriately identified and
@@ -5020,7 +4653,7 @@
     <li><a href="#endnote-spacing">Spacing between endnotes</a></li>
     <li><a href="#singlespace-endnotes">Singlespace endnotes (TYPEWRITE 
only)</a></li>
     <li><a href="#endnote-para-indent">Paragraph indenting</a></li>
-    <li><a href="#endnote-para-space">Paragraph spacing</a></li>
+    <li><a href="#endnote-para-space">Inter-paragraph spacing</a></li>
     <li><a href="#endnotes-no-columns">Turning off column mode during endnotes 
output</a></li>
   </ul></li>
   <li><a href="#endnotes-pagination"><b>Pagination of endnotes</b></a>
@@ -5199,7 +4832,7 @@
 
 <p>
 If you'd like some whitespace between endnotes, just invoke
-ENDNOTE_SPACING with the amount of space you want, e.g.
+ENDNOTE_SPACING with the amount of space you want, eg
 <br/>
 <span class="pre-in-pp">
   .ENDNOTE_SPACING 6p
@@ -5285,7 +4918,7 @@
 
 <!-- -ENDNOTE_PARA_SPACE- -->
 
-<h5 id="endnote-para-space" class="docs" style="margin-top: -.5em; 
margin-bottom: .5em; margin-left: .5em;">&bull;&nbsp;Paragraph spacing</h5>
+<h5 id="endnote-para-space" class="docs" style="margin-top: -.5em; 
margin-bottom: .5em; margin-left: .5em;">&bull;&nbsp;Inter-paragraph 
spacing</h5>
 
 <div class="box-macro-args">
 Macro: <b>ENDNOTE_PARA_SPACE</b> <kbd class="macro-args">&lt;toggle&gt;</kbd>
@@ -5363,7 +4996,7 @@
 <p>
 Use this macro with caution.  If all endnotes for several
 <a href="rectoverso.html#collate">collated</a>
-documents are to be output at once, i.e. not at the end of each
+documents are to be output at once, ie not at the end of each
 separate doc, ENDNOTES_FIRST_PAGENUMBER tells mom what page number
 to put on the first page of the endnotes.
 </p>
@@ -5627,7 +5260,7 @@
 will place a single rule underneath the endnotes page title.  Invoked
 with the argument, <kbd>DOUBLE</kbd>, ENDNOTE_STRING_UNDERSCORE will
 double-underscore the title.  Invoked with any other non-numeric
-argument, (e.g. <kbd>OFF, NO, X</kbd>, etc.) the macro disables
+argument, (eg <kbd>OFF, NO, X</kbd>, etc.) the macro disables
 underscoring of the title.
 </p>
 
@@ -5724,7 +5357,7 @@
 If you don&#8217;t want any identifying title, invoke
 <kbd>.ENDNOTE_TITLE</kbd> with a blank argument, either two
 double-quotes side by side (<kbd>&quot;&quot;</kbd>) or no argument
-at all.  This is particularly useful if you have a single (i.e.
+at all.  This is particularly useful if you have a single (ie
 non-collated) document and find having the document&#8217;s title
 included in the endnotes redundant.
 </p>
@@ -5774,7 +5407,7 @@
 will place a single rule underneath the document identification
 string.  Invoked with the argument <kbd>DOUBLE</kbd>,
 ENDNOTE_TITLE_UNDERSCORE will double-underscore the string.  Invoked
-with any other non-numeric argument, (e.g. <kbd>OFF, NO, X</kbd>,
+with any other non-numeric argument, (eg <kbd>OFF, NO, X</kbd>,
 etc.) the macro disables underscoring of the string.
 </p>
 
@@ -5846,7 +5479,7 @@
 what you want is a single line number, you need only invoke
 <kbd>.ENDNOTE</kbd> at the appropriate place in running
 text <i>without the terminating</i> <kbd>\c</kbd>.  Input lines
-after the endnote has been terminated (e.g. with <kbd>.ENDNOTE
+after the endnote has been terminated (eg with <kbd>.ENDNOTE
 OFF</kbd>) must begin at the left margin.
 </p>
 
@@ -5860,7 +5493,7 @@
 </p>
 
 <p id="en-mark">
-If you want a range of line numbers (e.g.&nbsp;[5-11]&nbsp;),
+If you want a range of line numbers (eg&nbsp;[5-11]&nbsp;),
 insert, directly into the first line of the range you want, the
 <a href="definitions.html#inlines">inline escape</a>,
 <kbd>\*[EN-MARK]</kbd>.  For the terminating line number of the
@@ -5937,7 +5570,7 @@
 more (the total number of endnotes is greater than 99), use the
 macro,
 <a href="docelement.html#endnote-numbers-align">ENDNOTE_NUMBERS_ALIGN</a>,
-to set the desired amount of reserved space, e.g.
+to set the desired amount of reserved space, eg
 <br/>
 <span class="pre-in-pp">
   .ENDNOTE_NUMBERS_ALIGN RIGHT 1
@@ -6155,7 +5788,7 @@
   <ul style="margin-left: -.5em;">
     <li><a href="#margin-notes-vertical">Adjusting the vertical position of 
margin notes</a></li>
   </ul></li>
-  <li><a href="#mn-init">Macro: <b>MN_INIT</b></a>&mdash;initialize margin 
notes</li>
+  <li><a href="#mn-init">Macro: <b>MN_INIT</b></a> &ndash; set margin notes 
parameters</li>
   <li><a href="#mn">Tag: MN</a></li>
 </ul>
 
@@ -6185,6 +5818,8 @@
 <a href="definitions.html#family">family</a>
 and
 <a href="definitions.html#leading">leading</a>.
+MN_INIT may be called before or after
+<a href="docprocessing.html#start">START</a>.
 </p>
 
 <p>
@@ -6270,14 +5905,14 @@
 
 <p>
 Adjustments to the vertical position of margin notes must be done
-inside the margin note (i.e. after <kbd>.MN</kbd>), at the top,
+inside the margin note (ie after <kbd>.MN</kbd>), at the top,
 before entering text.  The commands to use are
 <kbd>\!<a href="typesetting.html#ald">.ALD</a></kbd>
 (to lower the margin note) and
 <kbd>\!<a href="typesetting.html#rld">.RLD</a></kbd>
 (to raise it).
 
-The <kbd>\!</kbd> <i>must</i> precede the macros, or they
+The <kbd>\!</kbd> must precede the macros, or they
 won&#8217;t have any effect.
 </p>
 
@@ -6288,45 +5923,57 @@
 </div>
 
 <div class="box-macro-args">
-Macro: <b>MN_INIT</b> <kbd class="macro-args">&lt;arguments (see 
list)&gt;</kbd>
+Macro: <b>MN_INIT</b> <kbd class="macro-args">&lt;arguments&gt; (see 
list)</kbd>
 </div>
 
 <h4 style="margin-top: .75em; margin-left: .5em; font-style: normal; 
font-weight: bold: font-size: 105%; color: #6f614a;">Argument list:</h4>
 
 <span class="pre" style="margin-top: -1.5em; margin-left: .5em;">
-[ RAGGED | SYMMETRIC ]
-&lt;left-width&gt;
-&lt;right-width&gt;
-&lt;gutter&gt;
-&lt;family+font&gt;
-&lt;point-size&gt;
-&lt;lead&gt;
-&lt;colour&gt;
-&lt;hyphenation-flags&gt;
+RAGGED | SYMMETRIC
+&lt;L_WIDTH&gt;   &lt;value&gt;
+&lt;R_WIDTH&gt;   &lt;value&gt;
+&lt;GUTTER&gt;    &lt;value&gt;
+&lt;FONTSTYLE&gt; &lt;value&gt;
+&lt;SIZE&gt;      &lt;value&gt;
+&lt;LEAD&gt;      &lt;value&gt;
+&lt;COLOR&gt;     &lt;value&gt;
+&lt;HY&gt;        &lt;value&gt;
 </span>
 
 <p style="margin-top: 1.25em;">
 Before you enter your first margin note, you must initialize
-<i>all</i> the parameters associated with margin notes with MN_INIT.
+the style parameters associated with margin notes using MN_INIT.
 If you forget to do so, mom will issue a warning and abort.
 </p>
 
 <p>
-The argument list is quite long; an explanation of each argument
-follows.  Any argument whose value you want to be the default must
-be entered as <kbd>&quot;&quot;</kbd> (i.e. two double-quotes with
-no space between them).  Defaults for each argument are given in the
-explanations below.
+The arguments may be entered in any order, and since the list is
+long, use of the backslash character ( <kbd>\</kbd> ) to put each on
+a separate line is recommended, eg.
+<br/>
+<span class="pre-in-pp">
+  .MN_INIT \
+  SYMMETRIC \
+  L_WIDTH 4P \
+  SIZE 8 \
+  LEAD 9 \
+  HY 14
+</span>
+All arguments are optional, but since mom requires you to run
+MN_INIT before entering margin notes, you should, at a minimum, set
+the <kbd>RAGGED</kbd> or <kbd>SYMMETRIC</kbd> parameter.  
+You will almost certainly want to set <kbd>L_WIDTH</kbd>, <kbd>R_WIDTH</kbd>,
+<kbd>SIZE</kbd> and <kbd>LEAD</kbd> as well.
 </p>
 
-<h4 class="docs arg-list">Argument 1:&nbsp;&nbsp;<kbd style="color: 
#302419;">[ RAGGED | SYMMETRIC ]</kbd></h4>
+<h4 class="docs arg-list"><kbd>RAGGED | SYMMETRIC</kbd></h4>
 
 <p>
-If the first argument is <kbd>RAGGED</kbd>, both left and
-right margin notes will be flush left.  If the first argument
-is <kbd>SYMMETRIC</kbd> left margin notes will be set flush
-<i>right</i>, and right margin notes will be set flush
-<i>left</i>.  The effect is something like this:
+If the argument <kbd>RAGGED</kbd> is given, both left and
+right margin notes will be flush left.  If the argument
+<kbd>SYMMETRIC</kbd> is given, left margin notes will be set flush
+<i>right</i>, and right margin notes flush <i>left</i>.  The effect
+is something like this:
 <br/>
 <span class="pre-in-pp">
          A left    This is a meaningless batch        A right
@@ -6338,13 +5985,13 @@
 </p>
 
 <p>
-If the argument is omitted, or given as <kbd>&quot;&quot;</kbd>,
-both left and right margin notes will be set justified.  (Justified
-is usually not a good idea, since the narrow measure of margin notes
-makes pleasing justification a near impossibility.)
+If the argument is omitted, both left and right margin notes will
+be set justified.  (Justified is usually not a good idea, since the
+narrow measure of margin notes makes pleasing justification a near
+impossibility.)
 </p>
 
-<h4 class="docs arg-list">Argument 2:&nbsp;&nbsp;<kbd style="color: 
#302419;">&lt;left-width&gt;</kbd></h4>
+<h4 class="docs arg-list"><kbd>L_WIDTH &lt;value&gt;</kbd></h4>
 
 <p>
 The width of left margin notes.  A
@@ -6355,7 +6002,7 @@
 argument if using left margin notes.
 </p>
 
-<h4 class="docs arg-list">Argument 3:&nbsp;&nbsp;<kbd style="color: 
#302419;">&lt;right-width&gt;</kbd></h4>
+<h4 class="docs arg-list"><kbd>R_WIDTH &lt;value&gt;</kbd></h4>
 
 <p>
 The width of right margin notes.  A
@@ -6366,7 +6013,7 @@
 this argument if using right margin notes.
 </p>
 
-<h4 class="docs arg-list">Argument 4:&nbsp;&nbsp;<kbd style="color: 
#302419;">&lt;gutter&gt;</kbd></h4>
+<h4 class="docs arg-list"><kbd>GUTTER &lt;value&gt;</kbd></h4>
 
 <p>
 The
@@ -6380,17 +6027,17 @@
 <a href="definitions.html#em">em</a>.
 </p>
 
-<h4 class="docs arg-list">Argument 5:&nbsp;&nbsp;<kbd style="color: 
#302419;">&lt;font&gt;</kbd></h4>
+<h4 class="docs arg-list"><kbd>FONTSTYLE &lt;value&gt;</kbd></h4>
 
 <p>
 The family+font for margin notes.  Yes, that&#8217;s right: the
 family <i>plus</i> font combo.  For example, if you want Times
-Roman Medium, the argument must be TR.  If you want Palatino
-Medium Italic, the argument must be PI.  The default is the same
+Roman Medium, the argument must be <kbd>TR</kbd>.  If you want Palatino
+Medium Italic, the argument must be <kbd>PI</kbd>.  The default is the same
 family+font combo used for a document&#8217;s paragraph text.
 </p>
 
-<h4 class="docs arg-list">Argument 6:&nbsp;&nbsp;<kbd style="color: 
#302419;">&lt;point size&gt;</kbd></h4>
+<h4 class="docs arg-list"><kbd>SIZE &lt;value&gt;</kbd></h4>
 
 <p>
 The point size of type for margin notes.  There is no need to append a
@@ -6403,24 +6050,19 @@
 as is used in document paragraphs.
 </p>
 
-<h4 class="docs arg-list">Argument 7:&nbsp;&nbsp;<kbd style="color: 
#302419;">&lt;lead&gt;</kbd></h4>
+<h4 class="docs arg-list"><kbd>LEAD &lt;value&gt;</kbd></h4>
 
 <p>
 The
 <a href="definitions.html#leading">leading</a>
-of margin notes.  <kbd>&lt;lead&gt;</kbd> uses
+of margin notes.  <kbd>&lt;LEAD&gt;</kbd> takes
 <a href="definitions.html#picaspoints">points</a>
 as its unit of measure, so don&#8217;t tack a unit of measure onto
-the end of the argument.  The default lead is the same leading
-as is used for paragraph text (i.e. the document&#8217;s base
-leading).  If you want the default, you may, for convenience
-and clarity, give the word, <kbd>DOC</kbd>, to this argument,
-instead of <kbd>&quot;&quot;</kbd> (two double-quotes).  Like the
-double-quotes, it indicates that the leading should be the same as
-the document&#8217;s base leading.
+the end of the argument.  The default lead is the same as paragraph
+text (ie the document&#8217;s base leading).
 </p>
 
-<h4 class="docs arg-list">Argument 8:&nbsp;&nbsp;<kbd style="color: 
#302419;">&lt;colour&gt;</kbd></h4>
+<h4 class="docs arg-list"><kbd>COLOR &lt;value&gt;</kbd></h4>
 
 <p>
 The colour of margin notes.  The colour must be pre-initialized
@@ -6431,11 +6073,11 @@
 The default is black.
 </p>
 
-<h4 class="docs arg-list">Argument 9:&nbsp;&nbsp;<kbd style="color: 
#302419;">&lt;hyphenation-flags&gt;</kbd></h4>
+<h4 class="docs arg-list"><kbd>HY &lt;value&gt;</kbd></h4>
 
 <p>
-A number telling groff how you want margin notes
-hyphenated.
+<kbd>&lt;value&gt;</kbd> is a digit telling groff how you want margin
+notes hyphenated.
 <br/>
 <span class="pre-in-pp">
   1 = hyphenate without restrictions
@@ -6446,7 +6088,7 @@
 The values can be added together, so, for example, if you want
 neither the first two nor the last two characters of words
 hyphenated, the hyphenation-flag would be 12.  The default value is
-14 (i.e. 2+4+8).
+14 (ie 2+4+8).
 </p>
 
 <!-- -MN- -->
@@ -6486,16 +6128,17 @@
   <ul style="margin-left: -1.25em;">
     <li><a href="#finis-string">Changing the FINIS string</a></li>
     <li><a href="#finis-string-caps">Automatic capitalization of the FINIS 
string</a></li>
-    <li><a href="#finis-color">Changing the FINIS color</a></li>
+    <li><a href="#finis-color">Changing the FINIS colour</a></li>
   </ul></li>
 </ul>
 
 <p>
-The use of FINIS is optional.  If you invoke it (at the end of a
-document before
-<kbd><a href="tables-of-contents.html#toc">.TOC</a></kbd>
+The use of FINIS is optional.  If you invoke it at the end of a
+document (before
+<kbd><a href="#endnotes">.ENDNOTES</a></kbd>,
+<kbd><a href="refer.html#bibliography">.BIBLIOGRAPHY</a></kbd>
 or
-<kbd><a href="#endnotes">.ENDNOTES</a></kbd>),
+<kbd><a href="tables-of-contents.html#toc">.TOC</a></kbd>)
 mom deposits the word, <b>END</b>, centred after a blank line,
 beneath the last line of the document. <b>END</b> is enclosed
 between
@@ -6504,8 +6147,11 @@
 <br/>
 <span class="pre-in-pp">
   ...and they all lived happily ever after.
+
                   &mdash; END &mdash;
 </span>
+If there is insufficient room for FINIS on the last page of a
+document, mom will alert you on stderr.
 </p>
 
 <p>
@@ -6524,10 +6170,11 @@
 
 <p>
 The use of FINIS is optional, but if you use it, it should be the
-last macro you invoke in a document (before
-<kbd><a href="#endnotes">.ENDNOTES</a></kbd>
+last macro you invoke in a document before
+<kbd><a href="#endnotes">.ENDNOTES</a></kbd>,
+<kbd><a href="refer.html#bibliography">.BIBLIOGRAPHY</a></kbd>
 or
-<kbd><a href="tables-of-contents.html#toc">.TOC</a></kbd>).
+<kbd><a href="tables-of-contents.html#toc">.TOC</a></kbd>.
 See
 <a href="#finis-intro">above</a>
 for a description of how FINIS behaves.
@@ -6551,7 +6198,9 @@
 
 <!-- -FINIS STRING- -->
 
-<h3 id="finis-string" class="docs">Changing the FINIS string</h3>
+<h3 id="finis-control" class="docs" style="margin-bottom: -1em">Finis contol 
macros</h3>
+
+<h4 id="finis-string" class="docs">Changing the FINIS string</h4>
 
 <p>
 By default, FINIS prints the word, END, between
@@ -6573,7 +6222,7 @@
 <div class="box-tip">
 <p class="tip">
 <span class="note">Note:</span>
-If you pass FINIS_STRING a blank string, i.e.
+If you pass FINIS_STRING a blank string, ie
 <br/>
 <span class="pre-in-pp">
     .FINIS_STRING ""
@@ -6588,7 +6237,7 @@
 
 <!-- -FINIS STRING CAPS- -->
 
-<h3 id="finis-string-caps" class="docs">Automatic capitalization of the FINIS 
string</h3>
+<h4 id="finis-string-caps" class="docs">Automatic capitalization of the FINIS 
string</h4>
 
 <p>
 By default, mom sets the string you pass to FINIS all-caps.
@@ -6600,21 +6249,21 @@
 <span class="pre-in-pp">
     .FINIS_STRING_CAPS OFF
 </span>
-<kbd>OFF</kbd>, above, could be anything, e.g. <kbd>NO</kbd> or
+<kbd>OFF</kbd>, above, could be anything, eg <kbd>NO</kbd> or
 <kbd>X</kbd>.
 </p>
 
 <!-- -FINIS COLOR- -->
 
-<h3 id="finis-color" class="docs">Changing the FINIS colour</h3>
+<h4 id="finis-color" class="docs">Changing the FINIS colour</h4>
 
 <p>
 Invoking the control macro, <kbd>.FINIS_COLOR</kbd>, with a
-pre-defined (or &#8220;initalized&#8221;) color changes the colour
+pre-defined (or &#8220;initalized&#8221;) colour changes the colour
 of both the FINIS string and the em-dashes that surround it.  If you
 use the
 <a href="definitions.html#inline">inline escape</a>,
-<a href="color.html#color-inline"><kbd>\*[&lt;colorname&gt;]</kbd></a>,
+<a href="color.html#color-inline"><kbd>\*[&lt;colourname&gt;]</kbd></a>,
 in the argument passed to FINIS, only the text will be in the
 new colour; the em-dashes will be in the default document colour
 (usually black).

Index: momdoc/docprocessing.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/docprocessing.html,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -b -r1.40 -r1.41
--- momdoc/docprocessing.html   21 Feb 2012 21:14:20 -0000      1.40
+++ momdoc/docprocessing.html   31 Aug 2012 22:49:58 -0000      1.41
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -54,10 +56,11 @@
 <div id="docprocessing-mini-toc" style="font-size: 90%; line-height: 150%; 
margin-top: .5em;">
 <div class="mini-toc-col-1" style="margin-left: 0;">
 <h3 class="toc toc-docproc-header" style="margin-top: 1em;"><a 
class="header-link" href="#docprocessing-intro">Introduction</a></h3>
-<h3 class="toc toc-docproc-header" style="margin-top: .5em;"><a 
class="header-link" href="#setup">Document setup</a></h3>
+<h3 class="toc toc-docproc-header" style="margin-top: .5em;"><a
+class="header-link" href="#setup">Preliminary document setup</a></h3>
 <ul class="toc-docproc" style="margin-top: .5em;">
   <li><a href="#docprocessing-tut"><b>Tutorial &ndash; Setting up a mom 
document</b></a></li>
-  <li><a href="#reference-macros"><b>The reference macros</b></a>
+  <li><a href="#reference-macros"><b>The reference macros (metadata)</b></a>
   <ul class="toc-docproc">
     <li><a href="#title">TITLE</a></li>
     <li><a href="#doc-title">DOCTITLE</a></li>
@@ -71,8 +74,9 @@
     <li><a href="#misc">MISC</a></li>
     <li><a href="#covertitle">COVERTITLE</a></li>
     <li><a href="#doc-covertitle">DOC_COVERTITLE</a></li>
+    <li><a href="#pdftitle">PDF_TITLE</a></li>
   </ul></li>
-  <li><a href="#docstyle-macros"><b>The docstyle macros</b></a>
+  <li><a href="#docstyle-macros"><b>The docstyle macros (templates)</b></a>
   <ul class="toc-docproc">
     <li><a href="#doctype">DOCTYPE</a></li>
     <li><a href="#printstyle">PRINTSTYLE</a></li>
@@ -98,7 +102,10 @@
   <li><a href="#doc-lead-adjust"><b>Adjust linespacing to fill pages</b></a>
   <ul class="toc-docproc">
     <li><a href="#doc-lead-adjust">DOC_LEAD_ADJUST</a></li>
-    <li><a href="#shim">SHIM</a> &ndash; the macro to get document leading 
back on track</li>
+    <li><a href="#shim">SHIM</a> &ndash; get document leading back on track
+    <ul>
+      <li><a href="#automatic-shimming">Automatic shimming (headings, 
etc)</a></li>
+    </ul></li>
   </ul></li>
   <li><a href="#docheader"><b>Managing the document header</b></a>
   <ul class="toc-docproc">
@@ -134,6 +141,7 @@
     <li><a href="#doc-quad">DOC_QUAD</a></li>
   </ul></li>
 </ul>
+<h3 class="toc toc-docproc-header"><a class="header-link" 
href="#terminating">Terminating a document</a></h3>
 </div>
 </div>
 
@@ -145,7 +153,7 @@
 
 <p>
 Document processing with mom uses markup tags to identify document elements
-such as heads, paragraphs, and so on.  The tags are, of course,
+such as headings, paragraphs, blockquotes, and so on.  The tags are, of course,
 macros, but with sensible, readable names that make them easy
 to grasp and easy to remember.  (And don&#8217;t forget: if you
 don&#8217;t like the &#8220;official&#8221; name of a tag &mdash;
@@ -162,12 +170,13 @@
 
 <p>
 Setting up a mom doc is a simple, four-part procedure.  You
-begin by entering information about the document itself (title,
+begin by entering metadata about the document itself (title,
 subtitle, author, etc.).  Next, you tell mom what kind of document
-you&#8217;re creating (e.g. chapter, letter, abstract, etc...) and
+you&#8217;re creating (eg chapter, letter, abstract, etc...) and
 what kind of output you want (typeset, typewritten, draft-style,
-etc).  Thirdly, you make as many or as few changes to mom&#8217;s
-default behaviour as you wish.  Lastly, you invoke the
+etc) &mdash; essentially, templates.  Thirdly, you make as many
+or as few changes to the templates as you wish; in other words,
+create a style sheet.  Lastly, you invoke the
 <kbd><a href="#start">START</a></kbd>
 macro.  Voilà!  You&#8217;re ready to write.
 </p>
@@ -193,7 +202,7 @@
       visually 1-inch
   </li>
   <li>pages are numbered; the number appears centred, at the
-      bottom, surrounded by hyphens ( e.g. -6- )
+      bottom, surrounded by hyphens ( eg -6- )
   </li>
   <li>the first page of a document begins with a
       <a href="definitions.html#docheader">document header</a>
@@ -212,7 +221,7 @@
 Mom takes evenly-aligned bottom margins in
 <a href="definitions.html#running">running text</a>
 very seriously.  Only under a very few (exceptional) circumstances
-will she allow a bottom margin to &#8220;hang&#8221; (i.e. to fall
+will she allow a bottom margin to &#8220;hang&#8221; (ie to fall
 short).
 </p>
 
@@ -220,7 +229,7 @@
 In order to ensure even bottom margins, mom uses the
 &#8220;base&#8221; document
 <a href="definitions.html#leading">leading</a>
-in effect <i>at the start of running text on each page</i> (i.e.
+in effect <i>at the start of running text on each page</i> (ie
 the leading used in paragraphs) to calculate the spacing of every
 document element.  Prior to invoking
 <a href="#start">START</a>,
@@ -289,28 +298,29 @@
 </p>
 
 <p>
-For example, say you want to insert a picture into a document with
-the special groff macro, PSPIC (see <kbd>man groff-tmac</kbd> for
-usage).
+For example, say you want to insert an image into a document with
+<a href="images.html#pdf-image">PDF_IMAGE</a>
+or
+<a href="images.html#pspic">PSPIC</a>.
 </p>
 
 <p>
-Pictures aren&#8217;t usually conveniently sized in multiples of
-document leading, which means that when you insert the picture, you
-disrupt mom&#8217;s ordered placement of baselines on the page.
-This will certainly result in a bottom margin that doesn&#8217;t
-match the bottom margins of your document&#8217;s other pages.
+Images and graphics aren&#8217;t usually conveniently sized in
+multiples of the document leading, which means that when you insert
+the picture, you disrupt mom&#8217;s ordered placement of baselines
+on the page.  This will certainly result in a bottom margin that
+doesn&#8217;t match the bottom margins of your document&#8217;s
+other pages.
 </p>
 
 <p>
-The solution is to insert SHIM after the picture,
-like this:
+The solution is to insert SHIM after the image, like this:
 <br/>
 <span class="pre-in-pp">
-  &lt;some lines of text&gt;
-  .PSPIC &lt;full path to picture&gt;
+  &lt;text&gt;
+  .PDF_IMAGE &lt;args&gt; <span style="font-family: arial,sans-serif; 
font-weight: normal;">or</span> .PSPIC &lt;args&gt;
   .SHIM
-  &lt;more lines of text&gt;
+  &lt;text&gt;
 </span>
 </p>
 
@@ -323,32 +333,79 @@
 </p>
 
 <p>
-And say, on previewing the above example, you find that the picture
+And say, on previewing the above example, you find the image
 doesn&#8217;t centre nicely between the lines of text, you can
-always do
+adjust the image position either by passing a baseline adjustment
+to PDF_IMAGE, or by using
+<a href="typesetting.html#ald">ALD</a>
+or
+<a href="typesetting.html#rld">RLD</a>
+before PSPIC.  To demonstrate,
 <br/>
 <span class="pre-in-pp">
-  &lt;some lines of text&gt;
+  &lt;text&gt;
+  .PDF_IMAGE &lt;args&gt; -3p
+  .SHIM
+  &lt;text&gt;
+</span>
+and
+<span class="pre-in-pp">
+  &lt;text&gt;
   .RLD 3p
-  .PSPIC &lt;full path to picture&gt;
+  .PSPIC &lt;args&gt;
   .SHIM
-  &lt;more lines of text&gt;
+  &lt;text&gt;
 </span>
-to raise the picture slightly (reverse lead 3 points; see
-<a href="typesetting.html#rld">RLD</a>),
-and still have SHIM ensure that text underneath falls exactly where
-it&#8217;s supposed to.
+both raise an image slightly within the space allotted for it while
+ensuring that text underneath falls exactly where should.
+</p>
+
+<h4 id="automatic-shimming" class="docs">Automatic shimming of headings, 
quotes, blockquotes, PDF images, and floats</h4>
+
+<p style="margin-bottom: -1em">
+By default, mom automatically applies shimming
+</p>
+<ul>
+  <li><i>before</i> headings</li>
+  <li><i>around</i> quotes and blockquotes</li>
+  <li><i>after</i> PDF images and floats</li>
+</ul>
+
+<p>
+In documents where paragraphs are not spaced, automatic shimming is
+almost always desirable.  In documents where paragraphs are spaced
+by an amount less than the document leading, or which have numerous
+graphics, headings, and quotes, you may want to disable shimming,
+either globally or on a tag-by-tag basis.
+</p>
+
+<p id="disable-shim">
+<span style="font-weight: bold; font-style: italic; font-size: 95%">To disable
+automatic shimming</span>, invoke the macro, <kbd>.NO_SHIM</kbd>,
+either in the style sheet section of your document (ie after
+<a href="#printstyle">PRINTSTYLE</a>
+and before
+<a href="#start">START</a>),
+or just before
+<a href="docelement.html#heading">HEADING</a>,
+<a href="docelement.html#quote">QUOTE</a>,
+<a href="docelement.html#blockquote">BLOCKQUOTE</a>,
+<a href="images.html#pdf-image">PDF_IMAGE</a>
+or
+<a href="images.html#float">FLOAT</a>.
 </p>
 
 <div class="box-tip">
 <p class="tip">
 <span class="note">Note:</span>
-For information on disabling the automatic shimming of quotes and
-blockquotes during document processing, see
-<a href="docelement.html#no-shim">here</a>.
+<kbd>.NO_SHIM</kbd> also disables the SHIM macro itself.
 </p>
 </div>
 
+<p>To re-enable automatic shimming and the SHIM macro itself, use
+<kbd>.NO_SHIM OFF</kbd> (or <kbd>QUIT, END, X</kbd>, etc).
+</p>
+
 <div class="rule-short"><hr/></div>
 
 <!-- ==================================================================== -->
@@ -374,9 +431,9 @@
 at the top of page 1,
 <a href="definitions.html#header">page headers</a>
 with the title and author on subsequent pages, and page numbers at
-the bottom of each page.  In the course of the document, heads,
-subheads, citations, quotes, epigraphs, and so on, all come out
-looking neat, trim, and professional.
+the bottom of each page.  In the course of the document, headings,
+citations, quotes, epigraphs, and so on, all come out looking neat,
+trim, and professional.
 </p>
 
 <p>
@@ -387,8 +444,8 @@
 </p>
 <ul style="margin-top: -.5em; margin-bottom: -.5em;">
   <li>to be draft 7, revision 39;</li>
-  <li>to use the &#8220;default&#8221; style of document formatting:</li>
-  <li>to print as draft-style output (instead of &#8220;final&#8221; copy 
output);</li>
+  <li>to use the DEFAULT template;</li>
+  <li>to print as draft-style output (instead of final-copy output);</li>
   <li>to be typeset, in Helvetica, 12 on 14,
       <a href="definitions.html#rag">rag-right</a>;
   </li>
@@ -411,27 +468,27 @@
 
 <p style="margin-bottom: -.5em;">
 The first step in setting up any document is giving mom some
-reference information.  The reference macros are:
+reference information (metadata).  The reference macros are:
 </p>
 <div style="width: 50%; float: left;">
 <ul>
   <li>TITLE</li>
-  <li>DOCTITLE</li>
-  <li>COVERTITLE</li>
-  <li>DOC_COVERTITLE</li>
   <li>SUBTITLE</li>
   <li>AUTHOR</li>
-  <li>CHAPTER &ndash; the chapter number</li>
+  <li>CHAPTER &ndash; chapter number</li>
+  <li>CHAPTER_TITLE &ndash; chapter name</li>
+  <li>DRAFT &ndash; the draft number</li>
+  <li>REVISION &ndash; the revision number</li>
 </ul>
 </div>
 <div>
 <ul>
-  <li>DRAFT &ndash; the draft number</li>
-  <li>REVISION &ndash; the revision number</li>
   <li>COPYRIGHT &ndash; only used on cover pages</li>
   <li>MISC &ndash; only used on cover pages</li>
-  <li>COVER_TITLE &ndash; only on cover pages; only if needed</li>
-  <li>DOC_COVER_TITLE &ndash; only on document cover pages; only if needed</li>
+  <li>DOCTITLE</li>
+  <li>COVERTITLE</li>
+  <li>DOC_COVERTITLE</li>
+  <li>PDF_TITLE</li>
 </ul>
 </div>
 
@@ -460,17 +517,17 @@
 document is it?  Should it be typeset or typewritten?  Is this a
 final copy (for the world to see) or just a draft?  Mom calls
 the macros that answer these questions &#8220;the docstyle
-macros.&#8221; They are:
+macros.&#8221;, and they're essentially templates.
 </p>
 <ul style="margin-top: -.5em; margin-bottom: -.5em;">
-  <li>DOCTYPE&mdash;the type of document (default, chapter, user-defined, 
letter)</li>
   <li>PRINTSTYLE&mdash;typeset or typewritten</li>
+  <li>DOCTYPE&mdash;the type of document (default, chapter, user-defined, 
letter)</li>
   <li>COPYSTYLE &mdash;draft or final copy</li>
 </ul>
 
 <p>
 Mom has defaults for DOCTYPE and COPYSTYLE; if they&#8217;re what
-you want, you don&#8217;t need to include them here.  However,
+you want, you don&#8217;t need to include them.  However,
 PRINTSTYLE has no default and must be present in every formatted
 document.  If you omit it, mom won&#8217;t process the document
 AND she&#8217;ll complain (both to stderr and as a single printed
@@ -501,17 +558,20 @@
 <h4 class="docs" style="margin-top: -.5em; margin-bottom: -.5em;">Step 3</h4>
 
 <p>
-This step&mdash;completely optional&mdash;is where you, the
-user, take charge.  Mom has defaults for <i>everything</i>, but
-who&#8217;s ever satisfied with defaults?  Use any of the
+This step&mdash;completely optional&mdash;is where you, the user,
+take charge.  Mom has reasonable defaults for every document element
+and tag, but who&#8217;s ever satisfied with defaults?  Use any of
+the
 <a href="typesetting.html#macros-typesetting">typesetting macros</a>
 here to change mom&#8217;s document defaults (paper size, margins,
-family, point size, line space, rag, etc), or any of the document
-processing macros that set/change/control the appearance of document
-elements.  Think of this as the &#8220;style-sheet &#8221; section
-of a document.  And please note: you MUST give mom a
+family, point size, line space, rag, etc), or use any of the
+document processing
+<a href="definitions.html#controlmacro">control macros</a>.
+This is the style-sheet section of a document, and
+must come after the
 <a href="#printstyle">PRINTSTYLE</a>
-directive <i>before</i> making any such changes.
+directive.  Failure to observe this condition will result in
+PRINTSTYLE overriding your changes.
 </p>
 
 <p>
@@ -539,7 +599,7 @@
   .FAMILY  H
   .PT_SIZE 12
   .LS      14
-  .QUAD    LEFT    \"i.e. rag right
+  .QUAD    LEFT    \"ie rag right
   .FOOTERS
   .LINEBREAK_CHAR *
 </span>
@@ -551,8 +611,7 @@
 The final step in setting up a document is telling mom to start
 document processing.  It&#8217;s a no-brainer, just the single
 macro, START.  Other than PRINTSTYLE, it&#8217;s the only macro
-required for document processing (although I can&#8217;t guarantee
-you&#8217;ll like the results of using just the two).
+required for document processing.
 </p>
 
 <p>
@@ -571,7 +630,7 @@
   .FAMILY   H
   .PT_SIZE  12
   .LS       14
-  .QUAD     LEFT    \"i.e. rag right
+  .QUAD     LEFT    \"ie rag right
   .FOOTERS
   .LINEBREAK_CHAR *
   \#
@@ -622,7 +681,7 @@
 </p>
 
 <p>
-BUT... to judge from the number of drafts already,
+But... to judge from the number of drafts already,
 J. Blow may very well decide his &#8220;final&#8221; version still
 isn&#8217;t up to snuff.  Hence, he might as well leave in the
 superfluous macros.  That way, when draft 7, rev. 62 becomes draft
@@ -634,11 +693,10 @@
 
 <!-- ======================================================================== 
-->
 
-<h2 id="reference-macros" class="macro-group">The reference macros</h2>
+<h2 id="reference-macros" class="macro-group">The reference macros 
(metadata)</h2>
 
 <p>
-The reference macros give mom the meta-information she needs to
-generate
+The reference macros give mom the metadata she needs to generate
 <a href="definitions.html#docheader">docheaders</a>,
 <a href="definitions.html#header">page headers</a>,
 and
@@ -672,6 +730,7 @@
   <li><a href="#misc">MISC</a></li>
   <li><a href="#covertitle">COVERTITLE</a> &ndash; frontispiece, title page, 
etc</li>
   <li><a href="#doc-covertitle">DOC_COVERTITLE</a> &ndash; book cover, 
collated document cover, etc</li>
+  <li><a href="#pdftitle">PDF_TITLE</a> &ndash; window title for PDF 
viewers</li>
 </ul>
 </div>
 
@@ -759,16 +818,27 @@
 
 <p>
 DOCTITLE tells mom the title of the complete document (as opposed to
-the title of each article or entitled section).
+the title of each article or entitled section), and appears
+</p>
+
+<ol style="list-style-type: lower-alpha">
+  <li>as the window title in PDF viewers (eg Okular or Evince)</li>
+  <li>in the initial rightmost position of page headers in the document</li>
+</ol>
+
+<p>
+Moreover, DOCTITLE does not appear in the
+<a href="definitions.html#pdfoutline">PDF outline </a>,
+as its presence in window title would make it redundant.
 </p>
 
 <p>
 The doctitle string can be caps or caps/lower-case; it&#8217;s up to
 you.  In
 <a href="#printstyle">PRINTSTYLE TYPESET</a>,
-by default, the doctitle appears in the rightmost position of
-<a href="definitions.html#header">page headers</a>,
-all in caps unless you turn that feature off (see
+by default, the doctitle in
+<a href="definitions.html#header">page headers</a>
+is all in caps, unless you turn that feature off (see
 <a href="headfootpage.html#_caps">HEADER_&lt;POSITION&gt;_CAPS</a>).
 In
 <a href="#printstyle">PRINTSTYLE TYPEWRITE</a>,
@@ -870,7 +940,7 @@
 </p>
 
 <p>
-Each author string can hold as many names as you like, e.g.
+Each author string can hold as many names as you like, eg
 <br/>
 <span class="pre-in-pp" style="margin-bottom: -1em;">
   .AUTHOR "Joe Blow"
@@ -1043,7 +1113,7 @@
 <p>
 The style of the chapter title can be altered by
 <a href="docelement.html#docelement-control">control macros</a>,
-e.g. CHAPTER_TITLE_FAMILY, CHAPTER_TITLE_FONT, etc.  The default
+eg CHAPTER_TITLE_FAMILY, CHAPTER_TITLE_FONT, etc.  The default
 family, font and point size are Times Roman, Bold Italic, 4 points
 larger than
 <a href="definitions.html#running">running text</a>.
@@ -1074,7 +1144,7 @@
 </p>
 
 <p>
-Mom prints the argument to <kbd>.DRAFT</kbd> (i.e. the draft number)
+Mom prints the argument to <kbd>.DRAFT</kbd> (ie the draft number)
 beside the word &#8220;Draft&#8221; in the middle part of
 <a href="definitions.html#header">page headers</a>.
 </p>
@@ -1380,7 +1450,7 @@
 <p>
 The arguments passed to COVERTITLE or DOC_COVERTITLE are only
 used on cover or doc cover pages, and then only if the argument
-COVERTITLE is passed to
+COVERTITLE or DOC_COVERTITLE is passed to
 <a href="cover.html#cover">COVER</a>
 or
 <a href="cover.html#doc-cover">DOC_COVER</a>.
@@ -1400,6 +1470,24 @@
 and/or doc cover pages.
 </p>
 
+<div class="macro-id-overline">
+<h3 class="macro-id">PDF Title</h3>
+</div>
+
+<div id="pdftitle" class="box-macro-args">
+Macro: <b>PDF_TITLE</b> <kbd class="macro-args">&quot;&lt;pdf viewer window 
title&gt;&quot; </kbd> 
+</div>
+<p class="requires">
+&bull;&nbsp;Arguments must be enclosed in double-quotes
+</p>
+
+<p>
+Except for
+<a href="#doctitle">DOCTITLE</a>,
+mom does not, by default, provide PDF viewers with a document title.
+You may set one, if you like, with PDF_TITLE.
+</p>
+
 <div class="rule-short"><hr/></div>
 
 <!-- ======================================================================== 
-->
@@ -1488,16 +1576,6 @@
 mom prints only the chapter title.
 </p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-For backward compatibility with pre-1.1.5 versions of mom, you can
-also supply a chapter title by omitting the CHAPTER reference macro
-and supplying a chapter title with
-<a href="#chapter-string">CHAPTER_STRING</a>.)
-</p>
-</div>
-
 <p>
 The page headers in DOCTYPE <kbd>CHAPTER</kbd> contain the author,
 the title of the book (which you gave with
@@ -1510,7 +1588,7 @@
 
 <p>
 <kbd>NAMED</kbd> takes an additional argument: a name for this
-particular kind of document (e.g. outline, synopsis, abstract,
+particular kind of document (eg outline, synopsis, abstract,
 memorandum), enclosed in double-quotes. <kbd>NAMED</kbd> is
 identical to <kbd>DEFAULT</kbd> except that mom prints the argument
 to <kbd>NAMED</kbd> beneath the
@@ -1552,8 +1630,7 @@
 </p>
 
 <p>
-Formerly, this underlining was carved in stone.  As of version 1.5
-of mom, you can use the macro DOCTYPE_UNDERLINE to set the weight of
+You can use the macro DOCTYPE_UNDERLINE to set the weight of
 the underline and its distance from where the doctype-name appears
 in the docheader (doc covers and covers handle underlining of the
 doctype-name differently; see
@@ -1657,9 +1734,10 @@
 </p>
 
 <p class="tip-bottom">
-Furthermore, PRINTSTYLE must come before any changes to mom&#8217;s
-default typestyle parameters.  (This applies primarily to, but is by
-no means restricted to, PRINTSTYLE <kbd>TYPESET</kbd>.) PRINTSTYLE
+<span class="important">Just as important:</span>
+PRINTSTYLE <b>must precede any and all page and style parameters
+associated with a document.</b>  This applies primarily to, but is by
+no means restricted to, PRINTSTYLE <kbd>TYPESET</kbd>.   PRINTSTYLE
 sets up complete templates that include default papersize, margins,
 family, fonts, point sizes, and so on.  Therefore, changes to any
 aspect of document style must come afterwards.
@@ -1792,7 +1870,7 @@
 <kbd>.TYPEWRITER_FAM</kbd>).  Since groff ships with only the
 Courier family, you will have to install any other monospace family
 yourself.  See
-<a href="appendices.html#fonts">Adding PostScript fonts to
+<a href="appendices.html#fonts">Adding fonts to
 groff</a>.
 </p>
 
@@ -1823,7 +1901,7 @@
 
 <p id="printstyle-italics">
 If you&#8217;d prefer that mom were less bloody-minded
-about pretending to be a typewriter (i.e. you&#8217;d like italics and
+about pretending to be a typewriter (ie you&#8217;d like italics and
 pseudo-italics to come out as italics), use the control macros
 <br/>
 <span class="pre-in-pp">
@@ -1843,7 +1921,7 @@
 underlining of italics and pseudo-italics.
 </p>
 
-<p>
+<p id="underline-quotes">
 Additionally, by default, mom underlines
 <a href="definitions.html#quotes">quotes</a>
 (but not
@@ -1992,7 +2070,7 @@
 
 <p>
 START takes no arguments.  It simply instructs mom to begin document
-processing.  If you don&#8217;t want document processing (i.e. you
+processing.  If you don&#8217;t want document processing (ie you
 only want the
 <a href="typesetting.html#macros-typesetting">typesetting macros</a>),
 don&#8217;t use START.
@@ -2008,10 +2086,11 @@
 
 <!-- ======================================================================== 
-->
 
-<h2 id="style-before-start" class="macro-group">Establishing type and 
formatting parameters before START</h2>
+<h2 id="style-before-start" class="macro-group">Establishing typestyle and 
formatting parameters before START</h2>
 
 <p>
-In the third (optional) part of setting up a document (see
+In the third (optional) part of setting up a document (the
+stylesheet; see
 <a href="#docprocessing-tut">Tutorial &ndash; Setting up a mom document</a>),
 you can use the
 <a href="typesetting.html">typesetting macros</a>
@@ -2022,7 +2101,7 @@
 </p>
 
 <p>
-Two additional style concerns have to be addressed here (i.e. in
+Two additional style concerns have to be addressed here (ie in
 macros before
 <a href="#start">START</a>):
 changes to the
@@ -2116,10 +2195,10 @@
 <span class="pre">
   L_MARGIN       Left margin of pages, including headers/footers
   R_MARGIN       Right margin of pages, including headers/footers
-  T_MARGIN       The point at which running text (i.e. not
+  T_MARGIN       The point at which running text (ie not
                  headers/footers or page numbers) starts on each
                  page
-  B_MARGIN*      The point at which running text (i.e. not
+  B_MARGIN*      The point at which running text (ie not
   (see note)     headers/footers or page numbers) ends on each page
 
   PAGE           If you use PAGE, its final four arguments have the
@@ -2131,7 +2210,7 @@
   FAMILY         The family of all type in the document
   PT_SIZE        The point size of type in paragraphs; mom uses
                  this to calculate automatic point size changes
-                 (e.g. for heads, footnotes, quotes, headers, etc)
+                 (eg for heads, footnotes, quotes, headers, etc)
   LS/AUTOLEAD**  The leading used in paragraphs; all leading and
                  spacing of running text is calculated from this
 
@@ -2467,7 +2546,7 @@
 This starts the document 1.5 inches from the top of the page PLUS
 whatever spacing adjustment mom has to make in order to ensure that
 the first baseline of running text falls on a &#8220;valid&#8221;
-baseline (i.e. one that ensures that the bottom margin of the first
+baseline (ie one that ensures that the bottom margin of the first
 page falls where it should).  The distance is measured from the top
 edge of the paper to the
 <a href="definitions.html#baseline">baseline</a>
@@ -2707,7 +2786,9 @@
 <p>
 Simply pass the appropriate macro the font you want. <kbd>R, B,
 I</kbd> and <kbd>BI</kbd> have the same meaning as they do for
-<a href="typesetting.html#font">FT</a>.
+<a href="typesetting.html#font">FT</a>.  You may also use any of the
+<a href="appendices.html#style-extensions">style extensions</a>
+provided by mom.
 </p>
 
 <h4 id="change-size" class="docs">6. Adjust the size of individual docheader 
elements</h4>
@@ -2731,19 +2812,19 @@
       <br/>
       &nbsp;&nbsp;&nbsp;default = +3.5 (+4 if docheader title is &quot;Chapter 
&lt;n&gt;&quot;)
   </li>
-  <li>Macro: <b>.CHAPTER_TITLE_SIZE</b> <kbd 
class="macro-args">&lt;+/-points&gt;</kbd>
+  <li>Macro: <b>CHAPTER_TITLE_SIZE</b> <kbd 
class="macro-args">&lt;+/-points&gt;</kbd>
       <br/>
       &nbsp;&nbsp;&nbsp;default = +4
   </li>
-  <li>Macro: <b>.SUBTITLE_SIZE</b> <kbd 
class="macro-args">&lt;+/-points&gt;</kbd>
+  <li>Macro: <b>SUBTITLE_SIZE</b> <kbd 
class="macro-args">&lt;+/-points&gt;</kbd>
       <br/>
       &nbsp;&nbsp;&nbsp;default = +0
   </li>
-  <li>Macro: <b>.AUTHOR_SIZE</b> <kbd 
class="macro-args">&lt;+/-points&gt;</kbd>
+  <li>Macro: <b>AUTHOR_SIZE</b> <kbd class="macro-args">&lt;+/-points&gt;</kbd>
       <br/>
       &nbsp;&nbsp;&nbsp;default = +0
   </li>
-  <li>Macro: <b>.DOCTYPE_SIZE</b> <kbd 
class="macro-args">&lt;+/-points&gt;</kbd>
+  <li>Macro: <b>DOCTYPE_SIZE</b> <kbd 
class="macro-args">&lt;+/-points&gt;</kbd>
       (if <a href="#doctype">DOCTYPE</a> is <kbd>NAMED</kbd>)
       <br/>
       &nbsp;&nbsp;&nbsp;default = +3
@@ -3301,7 +3382,7 @@
 ADD_SPACE takes as its single argument the distance
 you want mom to advance from the normal
 baseline position at the top of any page after the first
-(i.e. the one on which the docheader is normally printed).  A
+(ie the one on which the docheader is normally printed).  A
 <a href="definitions.html#unitofmeasure">unit of measure</a> is
 required.
 </p>
@@ -3330,6 +3411,7 @@
 </p>
 
 <!-- *** -->
+
 <h2 id="intro-doc-param" class="macro-group">Changing basic type and 
formatting parameters after START</h2>
 
 <p>
@@ -3378,7 +3460,7 @@
       <a href="typesetting.html#l-margin">L_MARGIN</a>
   </li>
   <li>changes all left margins to the new value</li>
-  <li>the line length remains the same (i.e. the right margin
+  <li>the line length remains the same (ie the right margin
       shifts when you change the left margin)
   </li>
 </ul>
@@ -3484,7 +3566,7 @@
       <li><a href="docelement.html#endnote-intro">endnotes pages</a></li>
       <li><a href="docelement.html#toc-intro">table of contents</a></li>
   </ul></li>
-  <li>any page elements (e.g. headers page numbers, footnotes) whose
+  <li>any page elements (eg headers page numbers, footnotes) whose
       families you wish to remain at their old values must be
       reset with the appropriate
       <a href="docelement.html#docelement-control">control macros</a>
@@ -3606,6 +3688,79 @@
   </li>
 </ul>
 
+<h2 id="terminating" class="macro-group">Terminating a document</h2>
+
+<p>
+You need do nothing special to terminate a document.  When groff
+finishes processing the last
+<a href="definitions.html#inputline">input line</a>
+of a file, the page is ejected, subject to whatever routines are
+needed to complete it (eg printing footnotes or adding the page
+number).
+</p>
+
+<p>
+It happens sometimes, however, that a last line of
+<a href="definitions.html#running">running text</a>,
+falling on or very near the bottom of the page, tricks groff into
+breaking to a new page before terminating.  The result is a blank
+page at the end of the formatted document.
+</p>
+
+<p>
+The situation is rare, generally occuring only when some additional
+macro is required after the input text, eg to exit a
+<a href="docelement.html#list-intro">list</a>
+or terminate a
+<a href="docelement.html#quote">quote</a>.
+To prevent it from ever happening, I recommend getting into the habit
+of following the final input line of all your mom files with
+<a href="typesetting.html#el"><kbd>.EL</kbd></a>.
+Depending on the
+<a href="definitions.html#filled">fill mode</a>
+in effect, you may also have to append the &#8220;join line&#8221;
+<a href="definitions.html#inlines">escape</a>,
+<kbd>\c</kbd>, to the final line.</p>
+
+<p>
+Thus, for normal text at the end of a paragraph, which is in fill
+mode,
+<br/>
+<span class="pre-in-pp">
+  and they all lived happily ever after.
+  .EL
+</span>
+or for ending a 
+<a href="docelement.html#list-intro">LIST</a>
+(also in fill mode)
+<span class="pre-in-pp">
+  .ITEM
+  peaches, pears, plums
+  .EL
+  .LIST OFF
+</span>
+whereas, at the end of a
+<a href="docelement.html#quote-intro">QUOTE</a>
+(which is in nofill mode),
+<span class="pre-in-pp">
+  Shall be lifted\[em]nevermore!\c
+  .EL
+  .QUOTE OFF
+</span>
+Notice that the <kbd>.EL</kbd> comes after the last line of input
+text, not any macros following.
+</p>
+
+<div class="box-tip">
+<p class="tip">
+<span class="note">Note:</span>
+<a href="inlines.html#b"><kbd>\*[B]</kbd></a>
+cannot be used as a replacement for <kbd>.EL</kbd> when terminating
+a document.
+</p>
+</div>
+
+
 <div class="rule-long"><hr/></div>
 
 <!-- Navigation links -->

Index: momdoc/goodies.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/goodies.html,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -b -r1.29 -r1.30
--- momdoc/goodies.html 22 Feb 2011 19:42:30 -0000      1.29
+++ momdoc/goodies.html 31 Aug 2012 22:49:59 -0000      1.30
@@ -2,8 +2,8 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011, 2012 Free Software 
Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +14,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -48,13 +49,13 @@
 <div class="mini-toc-col-1">
 <ul class="no-enumerator">
 <li class="list-head-goodies"><a href="#alias">ALIAS</a> <span 
class="normal-smaller">&ndash; rename macros</span></li>
-<li class="list-head-goodies"><a href="#silent">SILENT</a> <span 
class="normal-smaller">&ndash; &#8220;hide&#8221; input lines from 
output</span></li>
-<li class="list-head-goodies"><a href="#trap">TRAP</a> <span 
class="normal-smaller">&ndash; suspend/re-invoke traps</span></li>
-<li class="list-head-goodies"><a href="#smartquotes">SMARTQUOTES</a> <span 
class="normal-smaller">&ndash; convert typewriter doublequotes to proper 
doublequotes</span></li>
 <li class="list-head-goodies"><a href="#caps">CAPS</a> <span 
class="normal-smaller">&ndash; convert to upper case</span></li>
-<li class="list-head-goodies"><a href="#string">STRING</a> <span 
class="normal-smaller">&ndash; user-definable strings</span></li>
 <li class="list-head-goodies"><a href="#esc-char">ESC_CHAR</a> <span 
class="normal-smaller">&ndash; change the escape character to something other 
than a backslash</span></li>
+<li class="list-head-goodies"><a href="#silent">SILENT</a> <span 
class="normal-smaller">&ndash; hide input lines from output</span></li>
 <li class="list-head-goodies"><a href="#sizespecs">SIZESPECS</a> <span 
class="normal-smaller">&ndash; get cap-height, x-height and descender depth of 
a font</span></li>
+<li class="list-head-goodies"><a href="#smartquotes">SMARTQUOTES</a> <span 
class="normal-smaller">&ndash; convert typewriter doublequotes to proper 
doublequotes</span></li>
+<li class="list-head-goodies"><a href="#string">STRING</a> <span 
class="normal-smaller">&ndash; user-definable strings</span></li>
+<li class="list-head-goodies"><a href="#trap">TRAP</a> <span 
class="normal-smaller">&ndash; suspend/re-invoke traps</span></li>
 <li class="list-head-goodies no-anchor"><span style="font-size: 
90%;">Underscoring/underlining</span>
 <ul class="sublist">
   <li class="list-head-goodies text-color"><a 
href="#underscore">UNDERSCORE</a> <span class="normal-smaller">&ndash; single 
underscore</span>
@@ -70,7 +71,7 @@
 </ul></li>
 <li class="list-head-goodies no-anchor"><span style="font-size: 
90%;">Padding</span>
 <ul class="sublist">
-  <li class="list-head-goodies text-color"><a href="#pad">PAD</a> <span 
class="normal-smaller">&ndash; insert equalized space into lines</span>
+  <li class="list-head-goodies text-color"><a href="#pad">PAD</a> <span 
class="normal-smaller">&ndash; insert equalized whitespace into lines</span>
   <ul class="sublist sub">
     <li class="list-head-goodies text-color"><a 
href="#pad-marker">PAD_MARKER</a> <span class="normal-sub-sub">&ndash; 
change/set the marker used with PAD</span></li>
   </ul></li>
@@ -167,10 +168,10 @@
 <span class="tip">Tip:</span>
 A particularly good candidate for ALIAS is the macro,
 <a href="typesetting.html#ps">PT_SIZE</a>.
-A more natural name for it (at least to old-school phototypesetters)
-would simply be PS, but PS conflicts with the <b>eqn</b> equation
-preprocessor and thus mom uses the longer form.  However, if
-you&#8217;re not using <b>eqn</b>, you can happily rename PT_SIZE to
+A more natural name for it would simply be PS, but PS conflicts
+with the <b>eqn</b> equation preprocessor and thus mom uses the
+longer form.  However, if you&#8217;re not using <b>eqn</b>, you can
+happily rename PT_SIZE to
 PS:
 <br/>
 <span class="pre-in-pp">
@@ -294,9 +295,9 @@
 </div>
 
 <p>
-Traps are vertical positions on the output page at which you or
-mom have instructed groff to start doing something automatically.
-Commonly, this is near the bottom of the page, where automatic
+Traps are vertical positions on the output page at which
+you or mom have instructed groff to start doing something
+automatically.  Commonly, this is near the bottom of the page, where
 behind-the-scenes processing is needed in order for one page to
 finish and another to start.
 </p>
@@ -310,7 +311,7 @@
     ...
     .TRAP
 </span>
-TRAP is a toggle, therefore any argument turns it off (i.e. suspends
+TRAP is a toggle, therefore any argument turns it off (ie suspends
 the trap), and no argument turns it (back) on.
 </p>
 
@@ -356,7 +357,7 @@
 If you invoke SMARTQUOTES with one of the optional arguments
 (<kbd>,,</kbd> or <kbd>&gt;&gt;</kbd>
 or <kbd>&lt;&lt;</kbd>) you can use
-<kbd>&quot;</kbd> (i.e. the inch-mark/doublequotes key)
+<kbd>&quot;</kbd> (ie the inch-mark/doublequotes key)
 as &#8220;cheap&#8221; open-and close-quotes when inputting text in
 a language other than English, and have mom convert them, on output,
 into the chosen open-and close-quote style.
@@ -445,9 +446,8 @@
 all instances of the apostrophe as an apostrophe, making the symbol
 useless as an open-single-quote.  For open single quotes, input
 the backtick character typically found under the tilde on most
-keyboards.  (Pour nous autres, &#8220;backtick&#8221; veut dire
-l&#8217;accent grave.)  Here&#8217;s an example of correct input
-copy with single quotes:
+keyboards.  Here&#8217;s an example of correct input copy with
+single quotes:
 <br/>
 <span class="pre-in-pp">
   "But she said, `I don&#8217;t want to!'"    
@@ -693,7 +693,7 @@
 UNDERSCORE does not work across line breaks in output copy, which is
 to say that you can&#8217;t underscore a multi-line passage simply
 by putting the text of the whole thing in the string you pass to
-UNDERSCORE.  If you need to several lines of type, use
+UNDERSCORE.  If you need to underscore several lines of type, use
 <a href="#underline">UNDERLINE</a>.
 </p>
 </div>
@@ -830,11 +830,16 @@
 special macro,
 <a href="#underline-specs">UNDERLINE_SPECS</a>,
 to control the weight and distance from the baseline of the
-underline.
+underline.  Lastly, files that use UNDERLINE must be processed with
+<br/>
+<span class="pre-in-pp">
+  pdfmom -Tps filename.mom | ps2pdf - filename.pdf
+</span>
+since groff's native pdf driver does not recognize UNDERLINE.
 </p>
 
 <p>
-UNDERLINE is a toggle macro, therefore you invoke it by itself (i.e.
+UNDERLINE is a toggle macro, therefore you invoke it by itself (ie
 with no argument) to initiate underlining, and with any argument
 (<kbd>OFF, QUIT, X,</kbd> etc) to turn it off.
 </p>
@@ -850,13 +855,11 @@
 
 <p class="tip-bottom">
 <span class="additional-note">Additional note:</span>
-Neither <kbd>.UNDERLINE</kbd> nor <kbd>\*[UL]</kbd> persist past the
-current document element tag.  For example, if you turn underlining
-on in a paragraph
+In document processing, neither <kbd>.UNDERLINE</kbd> nor
+<kbd>\*[UL]</kbd> persist past the current document element tag.
+For example, if you turn underlining on in a paragraph
 (<kbd><a href="docelement.html#pp">.PP</a></kbd>),
-your next paragraph will not be underlined (nor your next head,
-subhead, etc), regardless of whether you explicitly turn underlining
-off.
+your next paragraph will not be underlined.
 </p>
 </div>
 
@@ -904,12 +907,15 @@
 <span class="pre-in-pp">
   Which should I heed? \*[UL]Just do it\*[ULX] or \*[UL]just say no?\*[ULX]
 </span>
+In either case, this is a misuse of UNDERLINE.
+<a href="#underscore">UNDERSCORE</a>
+is preferable.
 </p>
 
 <!-- -PAD- -->
 
 <div class="macro-id-overline">
-<h3 id="pad" class="macro-id">Insert space into lines</h3>
+<h3 id="pad" class="macro-id">Insert equalized whitespace into lines</h3>
 </div>
 
 <div class="box-macro-args">
@@ -981,10 +987,6 @@
 mom&#8217;s
 <a href="definitions.html#inlines">inline escape</a>
 <kbd><a href="inlines.html#inline-rule-mom">\*[RULE]</a></kbd>.
-(Instead of <kbd>\*[RULE]</kbd>, groff&#8217;s line
-drawing function,
-<kbd><a 
href="inlines.html#inline-linedrawing-groff">\l'&lt;distance&gt;'</a></kbd>
-could be used.)
 <br/>
 <span class="pre-in-pp">
   .LL 30P
@@ -997,14 +999,10 @@
   \*[RULE]
   .TQ
 </span>
-If you&#8217;re not a typesetter, and if you&#8217;re new to groff,
-the example probably looks like gibberish.  My apologies.  However,
-remember that typesetting is a craft, and without having studied the
-craft, it takes a while to grasp its concepts.
 </p>
 
 <p>
-Basically, what the example does is:
+Here&#8217;s what the example does:
 </p>
 <ol style="margin-top: -.5em; margin-bottom: -.5em;">
   <li>Pads the Date/Signature line with a shorter space for Date
@@ -1126,7 +1124,7 @@
 <br/>
 <span class="pre">
   .LL 30P
-  .PAD "Date\*[ST1]#\*[ST1X]Signature\*[ST2]###\*[ST2X]"
+  .PAD "Date\*[ST1]#\*[ST1X]  Signature\*[ST2]###\*[ST2X]" NOBREAK
   .EL
   .ST 1 J
   .ST 2 J
@@ -1178,6 +1176,28 @@
 </span>
 </p>
 
+<div class="box-tip">
+<p class="tip">
+<span class="tip">Tip:</span>
+A particularly useful function of LEADER_CHARACTER is that it can be
+used to increase the spacing of mom&#8217;s default leaders.  This is
+done by assigning to LEADER_CHARACTER both the period (dot) and a
+space.  The technique requires a little low-level groffing:
+<br/>
+<span class="pre-in-pp">
+  .char \[leader] . \"
+  .LEADER_CHARACTER \[leader]
+</span>
+The <kbd>.char</kbd>
+<a href="definitions.html#primitives">primitive</a>
+allows you to define a character called <kbd>leader</kbd>, to which
+you assign a period and a space.  The <kbd>\"</kbd>, which, in
+groff, is used to add non-printing comments to a line, is not
+strictly necessary.  Its presence here lets you see that
+there&#8217;s a space after the period.
+</p>
+</div>
+
 <!-- -DROPCAP- -->
 
 <div class="macro-id-overline">
@@ -1239,7 +1259,7 @@
 DROPCAP only works
 </p>
 <ul style="margin-top: -1em; margin-bottom: 0;">
-  <li>with initial paragraphs (i.e. at the start of the document,
+  <li>with initial paragraphs (ie at the start of the document,
       or after
       <a href="docelement.html#head">HEAD</a>),</li>
   <li>when <kbd>.DROPCAP</kbd> comes immediately after <kbd>.PP</kbd>,</li>
@@ -1401,18 +1421,14 @@
 Mom does a pretty fine job of making superscripts look good in any
 font and at any size.  If you&#8217;re fussy, though (and I am),
 about precise vertical placement, kerning, weight, size, and so on,
-you may want to roll your own solution.  And sorry, there&#8217;s
-no mom equivalent for subscripts.  I'm neither a mathematician
-nor a chemist, so I don&#8217;t need them.  Of course, anyone who
-wishes to contribute a subscript routine to mom will receive
-blessings not only in this lifetime, but in all lifetimes to come.
+you may want to roll your own solution.
 </p>
 </div>
 
 <h3 id="sup-raise" class="docs">SUPERSCRIPT RAISE AMOUNT</h3>
 <p>
 By default, mom raises superscripts 1/3 of an
-<a href="definitions.html#ems">em</a>
+<a href="definitions.html#em">em</a>
 above the baseline.  If you&#8217;re not happy with this default,
 you can change it by invoking SUPERSCRIPT_RAISE_AMOUNT with the
 amount you want them raised.  A

Index: momdoc/graphical.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/graphical.html,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -b -r1.8 -r1.9
--- momdoc/graphical.html       22 Feb 2011 19:42:30 -0000      1.8
+++ momdoc/graphical.html       31 Aug 2012 22:49:59 -0000      1.9
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 

Index: momdoc/headfootpage.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/headfootpage.html,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -b -r1.23 -r1.24
--- momdoc/headfootpage.html    22 Feb 2011 19:42:30 -0000      1.23
+++ momdoc/headfootpage.html    31 Aug 2012 22:49:59 -0000      1.24
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -160,7 +162,7 @@
 <div id="author-note" class="box-tip">
 <p class="tip">
 <span class="note">Author's note:</span>
-Left to their own devices (i.e. if you&#8217;re happy with the way
+Left to their own devices (ie if you&#8217;re happy with the way
 mom does things by default), headers are something you never have to
 worry about.  You can skip reading this section entirely.  But if
 you want to change them, be advised that headers have more macros to
@@ -178,10 +180,10 @@
 </p>
 
 <p>
-&#8221;The left part (&#8220;header-left) lines up with the
+The left part (&#8220;header-left&#8221;) lines up with the
 document&#8217;s left margin.  The centre part (&#8220;header
-centre&#8220;) is centred on the document&#8217;s line length.
-&#8221;The right part (&#8220;header-right) lines up with the
+centre&#8221;) is centred on the document&#8217;s line length.
+The right part (&#8220;header-right&#8221;) lines up with the
 document&#8217;s right margin.  Not all parts need contain a string,
 and if you don&#8217;t want headers at all, you can turn them off
 completely.
@@ -334,7 +336,7 @@
 numbers, whether at the top or the bottom of the page, is managed
 exactly as if the page numbers were headers (or footers), and are
 controlled by the same macros.  See
-<a href="#pagination">Pagination control</a>.
+<a href="#index-pagination-control">Pagination control</a>.
 </p>
 
 <div class="rule-short"><hr/></div>
@@ -423,7 +425,7 @@
 <a href="definitions.html#header">Page headers</a>
 are on by default.  If you don&#8217;t want them, turn them off by
 invoking <kbd>.HEADERS</kbd> with any argument (<b>OFF, QUIT,
-END, X...</b>), e.g.
+END, X...</b>), eg
 <br/>
 <span class="pre-in-pp">
     .HEADERS OFF
@@ -439,8 +441,7 @@
 </p>
 
 <p>
-<b>ADDITIONAL NOTE:</b> If HEADERS
-are OFF, mom&#8217;s normal top
+<b>ADDITIONAL NOTE:</b> If HEADERS are OFF, mom&#8217;s normal top
 margin for
 <a href="definitions.html#running">running text</a>
 (7.5
@@ -451,7 +452,7 @@
 <kbd><a href="#footers">FOOTERS</a></kbd>).
 Explicitly invoking footers moves page numbering to the
 top of the page, where its placement and spacing are the same as
-for headers.  (I.e. the top margin of running text remains 7.5
+for headers (i.e. the top margin of running text remains 7.5
 picas.)
 </p>
 
@@ -470,7 +471,7 @@
 are off by default.  If you want them instead of
 <a href="definitions.html#header">headers</a>
 (you can&#8217;t have both), turn them on by invoking
-<kbd>.FOOTERS</kbd> without an argument, e.g.
+<kbd>.FOOTERS</kbd> without an argument, eg
 <br/>
 <span class="pre-in-pp">
     .FOOTERS
@@ -537,8 +538,7 @@
     </ul></li>
     <li><a href="#hdrftr-right">HEADER_RIGHT</a></li>
     <li><a href="#reserved-strings">Using mom&#8217;s reserved strings in 
header/footer definitions</a>
-        (e.g. <kbd>\E*[$TITLE]</kbd> when you want
-        <br/>
+        (eg <kbd>\E*[$TITLE]</kbd> when you want
         the title, <kbd>\E*[$AUTHOR]</kbd> when you want the author, etc.)
     </li>
     <li><a href="#page-number-symbol">Replacing header-left, centre or right 
with the page number</a></li>
@@ -713,11 +713,12 @@
 <span class="pre-in-pp">
   \E*[$TITLE]          &mdash;the current argument passed to .TITLE
   \E*[$DOCTITLE]       &mdash;the current argument passed to .DOCTITLE
+  \E*[$DOC_TYPE]       &mdash;the NAMED argument passed to .DOCTYPE
   \E*[$AUTHOR]         &mdash;the current first argument passed to .AUTHOR
   \E*[$AUTHOR_1...9]   &mdash;the current arguments passed to .AUTHOR
   \E*[$AUTHORS]        &mdash;a comma-separated concatenated string
                           of all the current arguments passed to .AUTHOR
-                          (i.e. a list of authors)
+                          (ie a list of authors)
   \E*[$CHAPTER_STRING] &mdash;the current argument passed to .CHAPTER_STRING,
                           if invoked, otherwise, "Chapter"
   \E*[$CHAPTER]        &mdash;the current argument (typically a number) passed
@@ -1038,7 +1039,7 @@
 simply invoke this macro (using the appropriate position) with no
 argument.  If you wish to turn capitalization off (say, for the
 header-right string that mom capitalizes by default), invoke the
-macro with any argument (e.g. <kbd>OFF, QUIT, END, X</kbd>...).
+macro with any argument (eg <kbd>OFF, QUIT, END, X</kbd>...).
 </p>
 
 <p>
@@ -1166,7 +1167,7 @@
 <p class="tip-top">
 <span class="important" style="display: block; margin-bottom: -1em;">Important 
&ndash; FOOTER_MARGIN and bottom margins</span>
 <br/>
-Mom requires a footer margin (i.e. the distance from the bottom of
+Mom requires a footer margin (ie the distance from the bottom of
 the page at which to place footers) for proper operation, hence she
 sets one, even if you don&#8217;t.  As stated above, her default
 footer margin is 3-picas.
@@ -1176,9 +1177,9 @@
 If you use
 <a href="typesetting.html#b-margin">B_MARGIN</a>
 or
-<a href="typesetting.html#page">PAGE</a>,
+<a href="typesetting.html#page">PAGE</a>
 to set a bottom margin for your document (prior to
-<a href="docprocessing.html#start">START</a>)
+<a href="docprocessing.html#start">START</a>),
 and the margin&#8217;s too close to mom&#8217;s default
 footer margin (or a footer margin you set yourself with
 FOOTER_MARGIN), mom will not print your footers; additionally,
@@ -1330,7 +1331,7 @@
 By default, mom prints a header separator rule underneath headers
 (or above footers). If you don&#8217;t want the rule, turn it off by
 invoking <kbd>.HEADER_RULE</kbd> with any argument (<kbd>OFF, QUIT,
-END, X...</kbd>), e.g.
+END, X...</kbd>), eg
 <br/>
 <span class="pre-in-pp">
   .HEADER_RULE OFF
@@ -1413,7 +1414,7 @@
 decimal fractions are allowed.  Please note that HEADER_RULE_GAP has
 no effect on
 <a href="#hdrftr-gap">HEADER_GAP</a>
-(i.e. HEADER_RULE_GAP is NOT added to HEADER_GAP when mom calculates
+(ie HEADER_RULE_GAP is NOT added to HEADER_GAP when mom calculates
 the space between headers and the start of
 <a href="definitions.html#running">running text</a>).
 </p>
@@ -1575,9 +1576,10 @@
 Macro: <b>HEADER_VERSO</b> <kbd class="macro-args">LEFT | CENTER | RIGHT [ 
CAPS ] "&lt;header verso string&gt;"</kbd>
 </div>
 
-<div id="userdef-hdrftr" class="box-tip" style="margin-top: 1.5em; outline: 
2px dashed #000089; margin-left: 3px; margin-right: 3px;">
+<div id="userdef-hdrftr" class="box-important">
+
 <p class="tip">
-<span class="tip" style="display: block; margin-bottom: -1.25em; color: 
#000056; font-size: 105%;">User-defined single string headers/footers (no 
recto/verso)</span>
+<span class="tip" style="display: block; margin-bottom: -1.25em; color: 
#000056; font-size: 100%;">User-defined single string headers/footers (no 
recto/verso)</span>
 <br/>
 HEADER_RECTO may be used to create user-defined, single string
 headers (or footers, with FOOTER_RECTO), even when recto/verso is
@@ -1692,7 +1694,7 @@
 cases.  When padding a header, it doesn&#8217;t matter which
 quad argument you use, although you must be sure to supply
 one.  Also note that mom does not interpret the <kbd>#</kbd> in
-<kbd>\*[PAGE#]</kbd> as a padding marker (i.e. as a place to insert
+<kbd>\*[PAGE#]</kbd> as a padding marker (ie as a place to insert
 whitespace).
 </p>
 
@@ -1788,8 +1790,8 @@
 
 <p>
 <kbd>L | C | R</kbd> in the arguments to HEADERS_AND_FOOTERS refers
-to whether you want the specific header or footer set flush left,
-centered, or flush right.  (You can also use the longer forms,
+to whether you want the specific header or footer part on the left,
+in the middle, or on the right.  (You can also use the longer forms,
 <kbd>LEFT</kbd>, <kbd>CENTER</kbd> and <kbd>RIGHT</kbd>.)  The
 string you give afterwards is whatever text you want, including
 mom&#8217;s
@@ -1812,7 +1814,7 @@
 <p>
 If you want to disable having both headers and footers on the same
 page, invoke <kbd>.HEADERS_AND_FOOTERS</kbd> with any argument
-you want (e.g. <kbd>OFF, QUIT, END, X...</kbd>). Mom will restore
+you want (eg <kbd>OFF, QUIT, END, X...</kbd>). Mom will restore
 her default behaviour of setting automatically generated page
 headers, with the page number, centered, at the bottom of the
 page.  If you would prefer footers instead of headers after turning
@@ -1914,7 +1916,7 @@
   <li><a href="#pagenum-style">PAGENUM_STYLE</a> &ndash; digits, roman 
numerals, etc</li>
   <li><a href="#pagenum-on-first-page">PAGENUM_ON_FIRST_PAGE</a> &ndash; 
applies only when footers are enabled</li>
   <li><a href="#draft-with-pagenumber">DRAFT_WITH_PAGENUMBER</a> &ndash; 
attach draft/revision information to page numbers</li>
-  <li><a href="#paginate-control">Pagination control macros and 
defaults</a></li>
+  <li><a href="#index-paginate-control">Pagination control macros and 
defaults</a></li>
 </ul>
 </div>
 
@@ -1932,7 +1934,7 @@
 By default, mom paginates documents (in the bottom margin).  If
 you&#8217;d prefer she not paginate, turn pagination off by invoking
 <kbd>.PAGINATE</kbd> with any argument (<kbd>OFF, NO, QUIT, END,
-X...</kbd>), e.g.
+X...</kbd>), eg
 <br/>
 <span class="pre-in-pp">
   .PAGINATE NO 
@@ -2074,7 +2076,7 @@
 <span class="pre defaults">
 .PAGENUM_FAMILY default = prevailing document family; default is Times Roman
 .PAGENUM_FONT   default = roman
-.PAGENUM_SIZE   default = 0 (i.e. same size as paragraph text)
+.PAGENUM_SIZE   default = 0 (ie same size as paragraph text)
 .PAGENUM_COLOR  default = black
 </span>
 </div>
@@ -2153,7 +2155,7 @@
 </span>
 The optional argument, <kbd>DIVIDER</kbd>, must be given if
 you&#8217;re inserting a blank page before the start of any new
-document section (i.e. a new chapter, or endnotes, a bibliography,
+document section (ie a new chapter, or endnotes, a bibliography,
 or table of contents).  Without the <kbd>DIVIDER</kbd> argument, mom
 simply inserts the blank pages and prepares the next page to receive
 <a href="definitions.html#running">running text</a>.

Index: momdoc/images.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/images.html,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- momdoc/images.html  22 Feb 2011 19:42:30 -0000      1.2
+++ momdoc/images.html  31 Aug 2012 22:49:59 -0000      1.3
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,12 +15,13 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
 <head>
   <meta http-equiv="content-type" content="text/html;charset=utf-8"/>
-  <title>Mom -- Inserting images into mom documents</title>
+  <title>Mom -- Graphics and floats</title>
   <link rel="stylesheet" type="text/css" href="stylesheet.css" />
 </head>
 
@@ -37,24 +39,226 @@
 </tr>
 </table>
 
-<h1 class="docs">Inserting images into a document</h1>
+<h1 class="docs">Graphics and floats</h1>
+
+<div style="width: 55%; margin: auto;">
+<ul class="no-enumerator" style="margin-left: -1em;">
+  <li><a href="#images-intro">Introduction to inserting images and graphics</a>
+  <li><a href="#converting">Image conversion and file processing</a>
+  <ul style="margin-left: -.5em; list-style-type: disc;">
+    <li><a href="#pdf">PDF</a></li>
+    <li><a href="#eps">EPS</a></li>
+  </ul></li>
+  <li><a href="#pdf-image">The PDF_IMAGE macro</a></li>
+  <li><a href="#pspic">The PSPIC macro</a></li>
+  <li><a href="#floats-intro">Introduction to floats</a></li>
+  <li><a href="#float">The FLOAT macro</a>
+  <ul style="margin-left: -.5em; list-style-type: disc;">
+               <li><a href="#tbl-with-float">Using tbl with FLOAT</a></li>
+       </ul></li>
+</ul>
+</div>
+
+<div class="rule-medium"><hr/></div>
+
+<h2 id="images-intro" class="docs">Introduction to inserting images and 
graphics</h2>
+
+<p>
+In order to include images in mom documents, the images must be in
+either PDF (.pdf) or EPS (.eps) format.  Each format requires its own
+macro, but both take the same arguments, and in the same order.
+</p>
+
+<p>
+Please note that there are differences in the way the files
+containing PDF and EPS images must be processed, hence documents may
+not contain a mix.
+</p>
+
+<h3 id=converting class="docs">Image conversion and file processing</h3>
+
+<p>
+When your image files are not in PDF or EPS format&mdash;jpgs,
+for example&mdash;you must convert them before including them in
+a mom document.  Any utility for converting images may used.  The
+ImageMagick suite of programmes, present on most GNU/Linux
+systems, contains <b>convert</b>, which is simple and effective.
+</p>
+
+<h4 id="pdf" class="docs">PDF</h4>
+
+<p>
+Assuming a jpg image, conversion to PDF is done like this:
+<br/>
+<span class="pre-in-pp">
+  convert &lt;image&gt;.jpg &lt;image&gt;.pdf
+</span>
+Any image type supported by <b>convert</b> may be converted this
+way.
+</p>
+
+<p>
+Mom files containing PDF images must be processed using
+groff&#8217;s pdf driver.  Use of
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>
+is strongly recommended, which natively invokes the pdf driver.
+<br/>
+<span class="pre-in-pp">
+  pdfmom doc.mom &gt; doc.pdf
+</span>
+</p>
+
+<h4 id="eps" class="docs">EPS</h4>
+
+<p>
+Assuming a jpg image, conversion to EPS is done like this:
+<br/>
+<span class="pre-in-pp">
+  convert &lt;image&gt;.jpg &lt;image&gt;.eps
+</span>
+Any image type supported by <b>convert</b> may be converted this
+way.  There have been reports of trouble with PostScript level 2
+images, so don&#8217;t save your images in this format.
+</p>
+
+<p>
+Mom files containing EPS images must be processed using
+groff&#8217;s postscript driver.  Use of
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>,
+which can be told to use the postscript driver, is strongly
+recommended.
+<br/>
+<span class="pre-in-pp">
+  pdfmom -Tps doc.mom &gt; doc.pdf
+</span>
+</p>
+
+<!-- -PDF_IMAGE- -->
+
+<div class="macro-id-overline">
+<h3 id="pdf-image" class= "macro-id">PDF_IMAGE</h3>
+</div>
+
+<div class="box-macro-args">
+Macro: <b>PDF_IMAGE</b> <kbd class="macro-args">[ -L | -C | -R | -I 
&lt;indent&gt; ] \
+<br/>
+&lt;pdf image&gt; &lt;width&gt; &lt;height&gt; \
+<br/>
+[ SCALE &lt;factor&gt; ] [ ADJUST +|-&lt;vertical adjustment&gt; ]</kbd>
+</div>
+<p class="requires">
+&bull;&nbsp;<span style="font-style: normal">
+<kbd>&lt;indent&gt;</kbd>,
+<kbd>&lt;width&gt;</kbd>,
+<kbd>&lt;height&gt;</kbd></span>
+and
+<span style="font-style: normal">
+<kbd>&lt;vertical adjustment&gt;</kbd></span>
+require a
+<a href="definitions.html#unitofmeasure">unit of measure</a>
+</p>
+
+<p>
+Unlike
+<a href="#pspic">PSPIC</a>,
+which it resembles, PDF_IMAGE requires that the pdf image&#8217;s
+dimensions (the bounding box,
+<a href="#bounding-box">see below</a>)
+be supplied each time it&#8217;s called.
+</p>
+
+<p>
+The first optional argument tells mom how to align the image
+horizontally, with <kbd>-L</kbd>, <kbd>-C</kbd>, and <kbd>-R</kbd>
+standing for left, centre and right respectively.  If you need more
+precise placement, the <kbd>-I</kbd> argument allows you to give an
+indent from the left margin.  Thus, to indent a PDF image 6
+<a href="definitions.html#picaspoints">picas</a>
+from the left margin
+<br/>
+<span class="pre-in-pp">
+  .PDF_IMAGE -I 6P &lt;remaining arguments&gt;
+</span>
+If you omit the first argument, the image will be centred.
+</p>
+
+<p>
+<kbd>&lt;pdf image&gt;</kbd> must be in PDF format, with a .pdf
+extension.  If it is not, mom will abort with a message.  See <a
+href="#pdf">here</a> for instructions on converting image formats to
+PDF.
+</p>
+
+<p id="bounding-box">
+<kbd>&lt;width&gt;</kbd> and <kbd>&lt;height&gt;</kbd> are the
+dimensions of the image&#8217;s bounding box.  The most reliable way
+of getting the bounding box is with the utility, <strong>pdfinfo</strong>:
+<br/>
+<span class="pre-in-pp">
+  pdfinfo &lt;image.pdf&gt; | grep "Page *size"
+</span>
+This will spit out a line that looks like this:
+<br/>
+<span class="pre-in-pp">
+  Page size:      width x height pts
+</span>
+<kbd>pts</kbd> means
+<a href="definitions.html#picaspoints">points</a>,
+therefore the unit of measure appended to <kbd>&lt;width&gt;</kbd>
+and <kbd>&lt;height&gt;</kbd> must be <kbd>p</kbd>.
+</p>
+
+<p>
+The optional <kbd>SCALE</kbd> argument allows you to scale the image
+by <kbd>&lt;factor&gt;</kbd>.  The factor is a percentage of the
+image&#8217;s original dimensions, thus
+<br/>
+<span class="pre-in-pp">
+ SCALE 50
+</span>
+scales the image to 50 percent of its original size.  No percent
+sign or unit of measure should be appended.
+</p>
+
+<p>
+The final optional argument is the vertical adjustment to apply to
+the image.  A plus value raises the image
+<span style="font-style: italic">within the space allotted for it</span>;
+a negative value lowers it.  The value must have a unit of measure
+appended.
+</p>
 
 <p>
-You can insert images into a document by using the PSPIC
-macro. PSPIC isn&#8217;t actually part of mom; it comes packaged
-with groff itself.  Images must be in PostScript format, either
-straight .ps or .eps (Encapsulated PostScript).  If you have the
-ImageMagick suite of programmes installed on your system, a simple way
-to convert most image formats to .eps is with <kbd>convert</kbd>, at
-the command line, as in this jpg&nbsp;=>&nbsp;eps example:
+Remember that mom files with embedded PDF images must be processed
+with
 <br/>
 <span class="pre-in-pp">
-  convert &lt;filename&gt;.jpg &lt;filename&gt;.eps 
+ pdfmom doc.mom &gt; doc.pdf
 </span>
-There have been reports of trouble with PostScript level 2 images,
-so don&#8217;t save your images in this format.
 </p>
 
+<div class="box-tip">
+<p class="tip-top">
+<span class="note">Note:</span>
+Mom automatically applies shimming after PDF_IMAGE.  See
+<a href="docprocessing.html#shim">SHIM</a>
+for a discussion of shimming, and how to disable it.
+<p>
+
+<p class="tip-bottom">
+<span class="note">Additional note:</span>
+Mom treats images inserted into a document with PDF_IMAGE like
+<a href="#floats-intro">floats</a>,
+which is to say that if the image doesn&#8217;t fit on the output
+page, she will defer it to the top of the next page while continuing
+to process
+<a href="definitions.html#running">running text</a>.
+<kbd>ADJUST</kbd> is ignored whenever an image is deferred, and a
+message is printed to stderr advising you where the deferment has
+taken place.
+</p>
+</div>
+
 <!-- -PSPIC- -->
 
 <div class="macro-id-overline">
@@ -66,12 +270,19 @@
 </div>
 
 <p>
-<kbd>man groff-tmac</kbd> contains the documentation for PSPIC, but
+PSPIC is not actually part of mom, but rather a macro included with
+every groff installation.  Although its arguments are identical to
+PDF_IMAGE (except for <kbd>SCALE</kbd> and <kbd>ADJUST</kbd>, which
+are missing), its behaviour is slightly different.
+</p>
+
+<p>
+<kbd>man groff_tmac</kbd> contains the documentation for PSPIC, but
 I&#8217;ll repeat it here with a few modifications for clarity.
 </p>
 
 <div class="examples-container">
-<h3 id="groff-tmac" class="docs" style="margin-top: .5em;">From groff-tmac</h3>
+<h3 id="groff-tmac" class="docs" style="margin-top: .5em;">From <span 
style="text-transform: none">groff_tmac</span></h3>
 <p style="margin-top: .5em; margin-bottom: .5em;">
 <kbd>&lt;file&gt;</kbd> is the name of the file containing the
 image; <kbd>width</kbd> and <kbd>height</kbd> give the desired
@@ -82,7 +293,7 @@
 <kbd>i</kbd>.  PSPIC will scale the graphic
 uniformly in the x and y directions so that it is no more than
 <kbd>width</kbd> wide and <kbd>height</kbd> high.  By default, the
-graphic will be horizontally centered.  The <kbd>-L</kbd> and
+graphic will be horizontally centred.  The <kbd>-L</kbd> and
 <kbd>-R</kbd> options cause the graphic to be left-aligned and
 right-aligned, respectively.  The <kbd>-I</kbd> option causes
 the graphic to be indented by <kbd>&lt;n&gt;</kbd>;  the default unit of
@@ -92,13 +303,27 @@
 </div>
 
 <p>
-Unless you&#8217;re a PostScript whiz and have futzed around with
-bounding boxes and whatnot, it&#8217;s unlikely that your image will
-occupy an easily predictable and precise amount of space on the
-page.  This is particularly significant when it comes to the amount
-of vertical space occupied by the image.  A certain amount of
-manual tweaking of the vertical placement of the image will
-probably be required, via the
+It is not necessary to pass PSPIC the
+<kbd>&lt;width&gt;</kbd> and <kbd>&lt;height&gt;</kbd> arguments unless
+you are scaling the image, in which case you will most likely need
+the original dimensions of the EPS image&#8217;s bounding box.
+These can be found with
+<span class="pre-in-pp">
+ gs -q -dBATCH -dNOPAUSE -sDEVICE=bbox &lt;image file&gt;.pdf 2&gt;&amp;1 \
+ | grep "%%BoundingBox" | cut -d " " -f4,5
+</span>
+The two digits returned are in
+<a href="definitions.html#picaspoints">points</a>,
+therefore the
+<a href="definitions.html#unitofmeasure">unit of measure</a>
+<kbd>p</kbd> must be appended to them.
+</p>
+
+<p>
+Because PSPIC lacks the <kbd>ADJUST</kbd> option offered by
+<a href="#pdf-image">PDF_IMAGE</a>
+a certain amount of manual tweaking of the vertical placement of the
+image will probably be required, typically by using the
 <a href="typesetting.html#ald">ALD</a>
 and
 <a href="typesetting.html#rld">RLD</a>
@@ -106,14 +331,189 @@
 </p>
 
 <p>
-Additionally, images inserted into
+Additionally, EPS images inserted into
 <a href="definitions.html#running">running text</a>
 will almost certainly disrupt the baseline placement of running
 text.  In order to get mom back on track after
 invoking <kbd>.PSPIC</kbd>, I strongly recommend using the
 <a href="docprocessing.html#shim">SHIM</a>
 macro so that the bottom margin of running text falls where it
-should.
+should.  Please note that with PDF_IMAGE, this is not necessary.
+</p>
+
+<p>
+Remember that mom files with embedded EPS images must be processed
+with
+<br/>
+<span class="pre-in-pp">
+ pdfmom -Tps doc.mom &gt; doc.pdf
+</span>
+</p>
+
+<div class="rule-medium"><hr/></div>
+
+<h2 id="floats-intro" class="docs">Introduction to floats</h2>
+
+<p>
+Images and graphics (including those created with
+<strong>tbl</strong> and <strong>pic</strong>) sometimes do not
+fit on the output page of a PDF or PostScript document at the
+place they&#8217;re inserted in the input file.  It&#8217;s
+necessary, therefore, to defer them to the next page while carrying
+on with
+<a href="definitions.html#running">running text</a>.
+</p>
+
+<p>
+Whenever you need this functionality (tables, for example, generally
+need only appear near related text, not at a precise location), mom
+provides the FLOAT macro.
+</p>
+
+<p>
+Floats are usually used for images and graphics, but can contain
+anything you like, including text.  Whatever&#8217;s in the
+float will be kept together as a block, output immediately if
+there&#8217;s room, or deferred to the top of the next output page
+when there isn&#8217;t; running text continues to the bottom of the
+previous page without interruption.
+</p>
+
+<p>
+In the case of a float that doesn&#8217;t fit being followed by
+one that does, the second is output in position and the first is
+deferred.  In the case of two or more that don&#8217;t fit, they are
+output in order on the next page.
+</p>
+
+<p>
+A key distinction between a float and a
+<a href="docelement.html#quote">QUOTE</a>
+or
+<a href="docelement.html#blockquote">BLOCKQUOTE</a>
+is that while a float keeps everything together and defers output if
+necessary, quotes and blockquotes are output immediately, and may
+start on one page and finish on the next.
+</p>
+
+<p>
+Floats always deposit a break before they begin, which means the
+line beforehand will not be
+<a href="definitions.html#filled">filled</a>.
+Floats, therefore, cannot be inserted in the middle of a paragraph
+without studying the output file and determining where to break or
+<a href="typesetting.html#spread">spread</a>
+the line before the float.
+</p>
+
+<p id="float-spacing">
+Floats begin on the baseline immediately below the running text
+preceding them.  No additional whitespace surrounds them, above or
+below.  Running text below a float is, however,
+<a href="docprocessing.html#shim">shimmed</a>,
+unless shimming has been disabled with <kbd>.NO_SHIM</kbd>.  This
+usually results in a small amount of extra whitespace after the
+float.  The <kbd>ADJUST</kbd> argument to FLOAT allows you to
+fine-tune the vertical centering.
+</p>
+
+<p>
+If you&#8217;d like more space around a float, you must add it
+manually, for example with 
+<a href="typesetting.html#ald">ALD</a>
+or
+<a href="typesetting.html#space">SPACE</a>.
+</p>
+
+<!-- -FLOAT- -->
+
+<div class="macro-id-overline">
+<h3 id="float" class= "macro-id">FLOAT</h3>
+</div>
+
+<div class="box-macro-args">
+Macro: <b>FLOAT</b> <kbd class="macro-args">ADJUST [ +|-&lt;amount&gt; ] | 
&lt;anything&gt;</kbd>
+</div>
+
+<div class="box-tip">
+<p class="tip">
+<span class="note">Note:</span>
+FLOAT is intended for use with the document processing macros only.
+</p>
+</div>
+
+<p style="margin-top: -.5em">
+To begin a float, simply invoke <kbd>.FLOAT</kbd> and follow it with
+whatever you want the float to contain.  When you&#8217;re done,
+invoke <kbd>.FLOAT&nbsp;OFF</kbd> (or <kbd>QUIT, END, X</kbd>, etc).
+</p>
+
+<p>
+The <kbd>ADJUST</kbd> argument tells mom to raise
+(<kbd>+</kbd>) or lower (<kbd>-</kbd>) the float <i>within the space
+allotted to it</i> by the specified amount.
+<kbd>&lt;amount&gt;</kbd> must have a
+<a href="definitions.html#unitofmeasure">unit of measure</a>
+appended.  <kbd>ADJUST</kbd> gives you precise control over
+the vertical centering of floats, allowing you to compensate for
+unequal spacing that may result of from the automatic shimming of
+floats (or the absence thereof).  See
+<a href="docprocessing.html#shim">SHIM</a>
+for a discussion of automatic shimming.
+</p>
+
+<p>
+<kbd>ADJUST</kbd> is ignored whenever a float is deferred to
+the following page.
+</p>
+
+<div class="box-tip">
+<p class="tip-top">
+<span class="note">Note:</span>
+Floats use
+<a href="definitions.html#filled">no-fill mode</a>,
+with each input line beginning at the left margin.  If this is not
+what you want, you must specify the preferred horizontal alignment
+<i>within the float</i> (eg
+<a href="typesetting.html#lrc">CENTER</a>
+or
+<a href="typesetting.html#lrc">RIGHT</a>).
+</p>
+
+<p class="tip-bottom">
+Furthermore, if you want text
+<a href="definitions.html#filled">filled</a>,
+you must specify
+<a href="typesetting.html#quad"><kbd>.QUAD&nbsp;L|R|C</kbd></a>
+or
+<a href="typesetting.html#justify"><kbd>.JUSTIFY</kbd></a>&mdash;again,
+within the float.
+</p>
+</div>
+
+<h4 id="tbl-with-float" class="docs">Using tbl with FLOAT</h4>
+
+<p>
+Unboxed tables created with <strong>tbl</strong> (see <kbd>man
+tbl(1)</kbd>) may be put in a float with the usual start and end
+macros, <kbd>.TS</kbd> and <kbd>.TE</kbd>.
+</p>
+
+<p>
+Boxed tables don&#8217;t play nice with FLOAT, and require that you
+pass the argument <kbd>BOXED</kbd> to <kbd>.TS</kbd>, otherwise mom
+cannot guarantee the vertical spacing of the float will be
+<a href="#float-spacing">as described</a>.
+<br/>
+<span class="pre-in-pp">
+  .FLOAT
+  .TS BOXED
+  &lt;tbl commands&gt;
+  .TE
+  .FLOAT OFF
+</span>
+You may put text (or anything else you like) above or below the
+table; mom will ensure the float is spaced correctly.
 </p>
 
 <div class="rule-long"><hr/></div>

Index: momdoc/inlines.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/inlines.html,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -b -r1.26 -r1.27
--- momdoc/inlines.html 22 Feb 2011 19:42:30 -0000      1.26
+++ momdoc/inlines.html 31 Aug 2012 22:49:59 -0000      1.27
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 <head>
@@ -210,7 +212,7 @@
 HEADERS or FOOTERS, or in the strings passed to
 <a href="headfootpage.html#headers-and-footers">HEADERS_AND_FOOTERS</a>,
 you must enter the inlines beginning with <kbd>\E*</kbd>
-rather than just <kbd>\*</kbd>, e.g. <kbd>\E*[BD]</kbd>.
+rather than just <kbd>\*</kbd>, eg <kbd>\E*[BD]</kbd>.
 </p>
 </div>
 
@@ -376,7 +378,7 @@
   \*[BU1]...\*[BU36]&nbsp;Move backward 1...36 <a 
href="definitions.html#kernunit">kern units</a>
   \*[FU1]...\*[FU36]&nbsp;Move forward  1...36 <a 
href="definitions.html#kernunit">kern units</a>
 </span>
-also exist (i.e. with no space before the number of kern units desired,
+also exist (ie with no space before the number of kern units desired,
 up to a limit of 36).
 </p>
 
@@ -395,9 +397,9 @@
 HEADERS or FOOTERS, or in the strings passed to
 <a href="headfootpage.html#headers-and-footers">HEADERS_AND_FOOTERS</a>,
 you <i>must</i> use the forms <kbd>\E*[BU&lt;n&gt;]</kbd>
-and <kbd>\E*[FU&lt;n&gt;]</kbd> (i.e. with no space), and enter the
+and <kbd>\E*[FU&lt;n&gt;]</kbd> (ie with no space), and enter the
 inline beginning with <kbd>\E*</kbd> rather than just <kbd>\*</kbd>,
-e.g. <kbd>\E*[BU4]</kbd>.
+eg <kbd>\E*[BU4]</kbd>.
 </p>
  
 <p class="tip-bottom">
@@ -455,7 +457,7 @@
   \*[BP.25]...\*[BP12.75]&nbsp;Move backward .25...12.75 points
   \*[FP.25]...\*[FP12.75]&nbsp;Move forward  .25...12.75 points
 </span>
-also exist (i.e. with no space before the digit and points being
+also exist (ie with no space before the digit and points being
 the unit of measure, hence no unit of measure required).  Both
 accept quarter points, so it&#8217;s possible to do, for example,
 <kbd>\*[FP.5]</kbd> or <kbd>\*[BP1.25]</kbd> up to a limit
@@ -478,9 +480,9 @@
 HEADERS or FOOTERS, or in the strings passed to
 <a href="headfootpage.html#headers-and-footers">HEADERS_AND_FOOTERS</a>,
 you <i>must</i> use the forms <kbd>\E*[BP&lt;n&gt;]</kbd>
-and <kbd>\E*[FP&lt;n&gt;]</kbd> (i.e. with no space), and enter the
+and <kbd>\E*[FP&lt;n&gt;]</kbd> (ie with no space), and enter the
 inline beginning with <kbd>\E*</kbd> rather than just <kbd>\*</kbd>,
-e.g. <kbd>\E*[BP.755]</kbd>.
+eg <kbd>\E*[BP.755]</kbd>.
 </p>
 </div>
 
@@ -546,9 +548,9 @@
 HEADERS or FOOTERS, or in the strings passed to
 <a href="headfootpage.html#headers-and-footers">HEADERS_AND_FOOTERS</a>,
 you <i>must</i> use the forms <kbd>\E*[ALD&lt;n&gt;]</kbd>
-and <kbd>\E*[RLD&lt;n&gt;]</kbd> (i.e. with no space), and enter the
+and <kbd>\E*[RLD&lt;n&gt;]</kbd> (ie with no space), and enter the
 inline beginning with <kbd>\E*</kbd> rather than just <kbd>\*</kbd>,
-e.g. <kbd>\E*[ALD.5]</kbd>.
+eg <kbd>\E*[ALD.5]</kbd>.
 </p>
 </div>
 
@@ -557,19 +559,11 @@
 <h3 id="inline-b-mom" class="docs">Terminate a line without advancing on the 
page</h3>
 <p>
 Sometimes, you want mom to break a line but not advance on the page.
-See
-<a href="typesetting.html#el-example">here</a>
-for an example of when you might want to do this.
-</p>
-
-<p>
-In versions of mom prior to 1.2-f, this was accomplished through the
-use of the
+This can be accomplished with the macro,
 <a href="typesetting.html#el">EL</a>
-macro.  As of 1.2-f, you can, if you prefer, accomplish the same
-thing by using the inline escape, <kbd>\*[B]</kbd>.  Simply attach
-the escape to the end of any input line.  Using the example given in
-the document entry for EL, you'd use <kbd>\*[B]</kbd> like this:
+or with the escape, <kbd>\*[B]</kbd>.  Simply attach <kbd>\*[B]</kbd>
+to the end of any input line.  Using the example given in the
+document entry for EL, you'd use <kbd>\*[B]</kbd> like this:
 <br/>
 <span class="pre-in-pp">
   .LEFT
@@ -587,25 +581,18 @@
 
 <h3 id="tb-plus-mom" class="docs">Call the next sequential tab without 
advancing on the page</h3>
 <p>
-Sometimes, you want mom to move to the next tab in sequence (e.g.
+Sometimes, you want mom to move to the next tab in sequence (eg
 from TAB 1 to TAB 2, or TAB 8 to TAB 9) without mom advancing on the
 page.  (See the NOTE
 <a href="typesetting.html#note-tn">here</a>
 if you&#8217;re not clear how mom manages tabs and linebreaks.)
-</p>
-
-<p>
-In versions of mom prior to 1.2-f, this was accomplished through the
-use of
-<a href="typesetting.html#tn">TN</a>.
-As of 1.2-f, you can, if you prefer, accomplish the same thing by
-using the inline escape, <kbd>\*[TB+]</kbd>.  Simply attach the
-escape to the end of any input line in a tab, like this:
+To do so, simply attach the escape <kbd>\*[TB+]</kbd> to the end of
+the input line in previous tab, like this:
 <br/>
 <span class="pre-in-pp">
   .TAB 1
-  Some text\*[TB+]  \" This line is in tab 1
-  Some more text    \" This line is in tab 2, on the same baseline as tab 1
+  Some text\*[TB+]  \" In tab 1
+  Some more text    \" In tab 2, same baseline.
 </span>
 
 <kbd>\*[TB+]</kbd> works reliably regardless of the current
@@ -908,7 +895,7 @@
 <p>
 In the context of mom, the string width inline
 <kbd>\w'&lt;string&gt;'</kbd> primarily serves to let you establish the
-horizontal measure of something (e.g. indents) based on the length
+horizontal measure of something (eg indents) based on the length
 of a bit of text.  For example, if you want a left indent the length
 of the word &#8220;Examples:&#8221; plus a space, you can set it with
 the <kbd>\w</kbd> inline escape:
@@ -1016,7 +1003,7 @@
 </p>
 
 <p>
-For a complete list of special characters and glyphs (i.e. just
+For a complete list of special characters and glyphs (ie just
 about anything you'd ever want to appear on the printed page,
 including mathematical symbols, accented characters, unusual
 ligatures and letters unique to various European languages), consult
@@ -1033,26 +1020,28 @@
   Zero-width character        \&amp;
   Discretionary hyphen        \%
   Backslash                   \\ or \e
-  Plus&#47;minus (arithmetic)     \(+-
-  Subtract (arithmetic)       \(mi
-  Multiply (arithmetic)       \(mu
-  Divide (arithmetic)         \(di
-  Em-dash                     \(em
-  En-dash                     \(en
-  Left double-quote           \(lq
-  Right double-quote          \(rq
-  Bullet                      \(bu
-  Ballot box                  \(sq
-  One-quarter                 \(14
-  One-half                    \(12
-  Three-quarters              \(34
-  Degree sign                 \(de
-  Dagger                      \(dg
-  Foot mark                   \(fm
-  Cent sign                   \(ct
-  Registered trademark        \(rg
-  Copyright                   \(co
-  Section symbol              \(se
+  Plus&#47;minus (arithmetic)     \[+-]
+  Subtract (arithmetic)       \[mi]
+  Multiply (arithmetic)       \[mu]
+  Divide (arithmetic)         \[di]
+  Em-dash                     \[em]
+  En-dash                     \[en]
+  Left double-quote           \[lq]
+  Right double-quote          \[rq]
+  Open (left) single-quote    \[oq]
+  Close (right) single-quote  \[oq]
+  Bullet                      \[bu]
+  Ballot box                  \[sq]
+  One-quarter                 \[14]
+  One-half                    \[12]
+  Three-quarters              \[34]
+  Degree sign                 \[de]
+  Dagger                      \[dg]
+  Foot mark                   \[fm]
+  Cent sign                   \[ct]
+  Registered trademark        \[rg]
+  Copyright                   \[co]
+  Section symbol              \[se]
 </span>
 <br/>
 

Index: momdoc/intro.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/intro.html,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -b -r1.21 -r1.22
--- momdoc/intro.html   22 Feb 2011 19:42:30 -0000      1.21
+++ momdoc/intro.html   31 Aug 2012 22:49:59 -0000      1.22
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 
+2010, 2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -57,61 +59,42 @@
 
 <p>
 Mom (&#8220;my own macros&#8221;, &#8220;my other macros&#8221;,
-&#8220;maximum overdrive macros&#8221;...) is a macro set for
-groff, designed to format documents for PostScript output.
-She&#8217;s aimed at three kinds of users:
+&#8220;maximum overdrive macros&#8221;...) is a macro set for groff,
+designed to format documents in Portable Document Format (.pdf) and
+PostScript (.ps).  She&#8217;s aimed at three kinds of users:
 </p>
 
 <ol style="margin-top: -.5em; margin-bottom: -.5em;">
   <li>Typesetters who suspect groff might be &#8220;the right
-      tool for the job&#8221; but who are
-      frustrated/intimidated by groff&#8217;s terse, geeky,
+      tool for the job&#8221; but who are frustrated,
+      intimidated, or puzzled by groff&#8217;s terse,
       not-always-typographically-intuitive
       <a href="definitions.html#primitives">primitives</a>;
   </li>
-  <li>Non-scientific writers (novelists, short story writers,
-      journalists, students) who just want their work to
-      look good;
+  <li>Non-technical writers who need to format their work easily,
+      with a minimum of clutter;
   </li>
-  <li>Newbies to computer typesetting, document processing or
-      groff who need a well-documented macro set to help them get
-      started.
+  <li>Newcomers to groff, typesetting, or document processing
+      who need a well-documented macro set to get them started.
   </li>
 </ol>
 
 <p>
-As might be inferred from the above, mom is two macro packages in
-one: a set of typesetting macros, and a set of document formatting
-macros.  The typesetting macros govern the physical aspects
-of page layout and provide sane, comprehensible control over
-typographic refinements.  The document formatting macros let you
-focus on a document&#8217;s content and logical structure without
-worrying about typesetting or page layout at all.
-</p>
-
-<p>
-Because mom provides both typesetting and document formatting
-macros, it&#8217;s safe to say she blurs the distinction
-between document processing and document design.  While
-her basic document style come with pretty spiffy defaults
-(okay&mdash;change &#8220;spiffy&#8221; to &#8220;typographically
-professional&#8221;), you can easily control how all the various
-document elements look: titles, page headers and footers, page
-numbering, heads, subheads, footnotes and so on can be made to
-come out exactly the way you want.  And should you need precise
-typographic control over elements in a document that fall outside
-the range of mom&#8217;s document element tags, you don&#8217;t
-have to read up on groff
-<a href="definitions.html#primitives">primitives</a>
-in order to accomplish what you want; the typesetting macros take
-care of that.
+Mom is actually two macro packages in one: a very complete set
+of typesetting macros, and an equally thorough set of document
+formatting macros.  The typesetting macros afford fine-grained
+control over all visible aspects of page layout and design (margins,
+fonts, sizes, kerning, etc), while the document formatting macros
+focus on the logical structure of a document (titles, headings,
+paragraphs, lists, etc) and call on groff to render logical
+structure into pleasing type.
 </p>
 
 <h2 id="intro-typesetting" class="docs">Typesetting with mom</h2>
 
 <p>
 Mom&#8217;s typesetting macros control the basic parameters
-of type: margins, line length, type family, font, point size,
+of type: margins, line lengths, type family, font, point size,
 linespacing, and so on.  In addition, they allow you to move
 around on the page horizontally and vertically, and to set up
 tabs, indents, and columns.  Finally, they let you adjust such
@@ -120,63 +103,41 @@
 </p>
 
 <p>
-In terms of typographic control, these macros resemble
-the commands used on dedicated typesetting computers like
-Compugraphics and Linotronics.  Most of them simply give access
-to groff&#8217;s typesetting primitives in a way that&#8217;s
-consistent and easy to use.  A few of them (tabs and indents,
-for example) handle fundamental typesetting requirements in ways
-radically different from groff primitives.
+The typesetting macros also provide the means to create horizontal
+and vertical rules, rectangles (boxes, frames), and ellipses
+(circles).
 </p>
 
 <p>
-With mom&#8217;s typesetting macros, you can, if you wish, create
-individual output pages that you design from the ground up.
-Provided you have not signalled to mom that you want document
-processing (via the
+In terms of typographic control, the typesetting macros provide
+access to groff&#8217;s primitives in a way that&#8217;s consistent,
+sensible, and easy to use.  With them, you can create individual
+pages designed from the ground up.  Provided you have not signalled
+to mom that you want document processing (via the
 <kbd><a href="docprocessing.html#start">START</a></kbd>
-macro; see below), every macro is a literal command that remains
-in effect until you modify it or turn it off.  This means that if
-you want to create flyers, surveys, tabulated forms, curricula
-vitae and so on, you may do so in the good old-fashioned way: one
-step at a time with complete control over every element on the
-page.
+macro; see below), every typesetting macro is a literal command
+that remains in effect until you modify it or turn it off.  This
+means that if you want to create flyers, surveys, tabulated forms,
+curricula vitae and so on, you may do so in the good old-fashioned
+way: one step at a time with complete control over every element on
+the page.
 </p>
 
 <p>
-Years of reading various mailing lists dealing with computer
-typesetting (groff, TeX, and friends) have convinced me that no
-program can ever replace the human eye and human input when it
-comes to high quality typesetting.  As of this writing, a thread
-on the subject of &#8220;micro typography&#8221; in groff has been
-going on for nearly a month.  The reason for the lengthy thread
-is obvious; words and punctuation on the printed page are too
+Years of experience have convinced me that no program can ever
+replace the human eye and human input when it comes to high quality
+typesetting.  Words and punctuation on the printed page are too
 variable, too fluid, to be rendered flawlessly by any algorithm,
-no matter how clever.  (For whatever it&#8217;s worth, a similar
-problem exists with engraving musical scores by computer.)
-</p>
-
-<p>
-Mom does not try to solve the problems posed by things like
-hanging punctuation, left-margin adjustments for upper case
-letters like T and W, and so on.  She merely tries to provide
-tools that allow knowledgeable typesetters to come up with
-solutions to these problems in ways that are easier and more
-intuitive than manipulating groff at the
-<a href="definitions.html#primitives">primitive</a>
-level.  As a professional typesetter of more than two decades, and
-a writer, I have encountered few situations that cannot be handled
-by mom&#8217;s typesetting macros.
+no matter how clever.
 </p>
 
 <p>
-Author&#8217;s note: One area where groff itself needs serious
-rethinking is in the matter of an algorithm that takes into
-account both word and letter spacing when
-<a href="definitions.html#just">justifying</a>
-lines.  At present, only word spacing is adjusted, requiring what
-I consider an unnecessary amount of user intervention whenever
-letter spacing is required.
+Mom, therefore, does not try to guess solutions for issues like
+hanging punctuation, or left-margin adjustments for troublesome
+letters like T, V and W.  Rather, she provides tools that allow
+knowledgeable typesetters to handle these typographic challenges in
+ways that are easier and more intuitive than manipulating groff at
+the primitive level.
 </p>
 
 <h2 id="intro-docprocessing" class="docs">Document processing with mom</h2>
@@ -186,24 +147,22 @@
 without having to worry about the typographic details.  In this
 respect, mom is similar to other groff macro packages, as well as
 to html and LaTeX.  Where mom differs is in the degree of control
-you have over the look and placement of the various elements of
-a document.  For example, if you don&#8217;t want your heads
-underlined, or you want them bigger/smaller, or you&#8217;d prefer
-them to be in a different font, or you&#8217;d rather they were
-flush left instead of centred, you can make the changes easily
-and have them apply to the whole document.  Temporary and one-off
-changes are easy, too.
+you have over the look and placement of the various elements of a
+document.  For example, if you&#8217;d like your headings underlined,
+or in caps, or centred rather than flush left, you can make the
+changes easily and have them apply to the whole document.  Temporary
+and one-off changes are easy, too.
 </p>
 
 <p>
-Mom has some nifty features other macro sets don&#8217;t provide.
-For example, you can switch between draft-style and final-copy
-output.  If you regularly make submissions to publishers and
-editors who insist on "typewritten, double-spaced," there&#8217;s
-a special macro&mdash;
+Mom has some features other macro sets don&#8217;t provide.  For
+example, you can switch between draft-style and final-copy output.
+If you regularly make submissions to publishers and editors who
+insist on "typewritten, double-spaced," there&#8217;s a special
+macro&mdash;
 <a href="docprocessing.html#printstyle"><kbd>PRINTSTYLE 
TYPEWRITE</kbd></a>&mdash;
-that changes typeset documents into ones that would make your
-high-school typing teacher proud.  Footnotes, endnotes, tables of
+that changes typeset documents into ones that would make an
+old-school typing teacher proud.  Footnotes, endnotes, tables of
 contents, multiple columns, nested lists, recto/verso printing and
 user designable headers and footers are also part of the fun.
 </p>
@@ -227,9 +186,9 @@
 &#8220;comprehensible,&#8221; and &#8220;readable&#8221; often
 mean &#8220;you&#8217;re stuck with what you get.&#8221; No
 document formatting system can give you exactly what you want all
-the time, every time.  Documents, it seems, always need to be
-tweaked, either to satisfy a typographic whim or to clarify some
-aspect of their content.
+the time, every time.  Documents always need to be tweaked, either
+to satisfy a typographic whim or to clarify some aspect of their
+content.
 </p>
 
 <p>
@@ -239,21 +198,21 @@
 <a href="definitions.html#primitives">primitives</a>
 and
 <a href="definitions.html#inlines">inline escapes</a>
-for their special typesetting needs.  Not to put too fine a
-point on it, groff primitives tend toward the abstruse, and most
-inline escapes are about as readable in-line as an encrypted
-password.  This does not make for happy-camper writers, who either
-find themselves stuck with a document formatting style they
-don&#8217;t really like, or are forced to learn groff from the
-ground up&mdash;a daunting task, to say the least.
+for their special typesetting needs.  Not to put too fine a point
+on it, groff primitives tend toward the abstruse, and most inline
+escapes are about as readable as an encrypted password.  This does
+not make for happy-camper writers, who either find themselves stuck
+with a formatting style they don&#8217;t like, or are forced to
+learn groff from the ground up&mdash;a daunting task, to say the
+least.
 </p>
 
 <p>
-Mom aims to make creating documents a simple matter, but with
-no corresponding loss of user control.  The document processing
-macros provide an excellent set of defaults, but if something is
-not to your liking, you can change it.  And in combination with
-the typesetting macros, you have all the tools you need to massage
+Mom aims to make creating documents a simple matter, but with no
+corresponding loss of user control.  The document processing macros
+provide an initial set of reasonable defaults, but anything that
+is not to your liking can be changed.  In combination with the
+typesetting macros, you have all the tools you need to massage
 passages and tweak pages until they look utterly professional.
 </p>
 
@@ -266,27 +225,28 @@
 &#8220;coding&#8221; style.  Most of the macros (especially in
 the document processing set) have humanly-readable names.  Not
 only does this speed up learning the macros, it makes the sense
-of what&#8217;s going on in a document, typographically and
-structurally, easier to decipher.
+of what&#8217;s going on in a document easier to decipher,
+typographically and structurally.
 </p>
 
 <p>
 Mom does not try to be all things to all people.  In contrast to
 the normal groff philosophy, she does not try to produce output
 that looks good no matter where it&#8217;s displayed.  She&#8217;s
-designed for printed output, although with
-<a href="docprocessing.html#printstyle"><kbd>PRINTSTYLE TYPEWRITE</kbd></a>
-she produces acceptable terminal copy.  She makes no attempt to be
+designed for primarily for PDF or PostScript output, although
+with <a href="docprocessing.html#printstyle"><kbd>PRINTSTYLE
+TYPEWRITE</kbd></a>
+she produces acceptable terminal copy.  No attempt is made to be
 compatible with older versions of troff.
 </p>
 
 <p>
-One special feature in mom&#8217;s design is the attention she
-pays to aligning the bottom margins of every page.  Nothing
-screams shoddy in typeset documents louder than bottom margins
-that wander, or, in typesetter jargon, &#8220;hang.&#8221; There
-are, of course, situations where whitespace at the bottom of a
-page may be desirable (for example, you wouldn&#8217;t want a head
+One special feature in mom&#8217;s design is the attention she pays
+to aligning the bottom margins of every page.  Nothing screams
+shoddy in typeset documents louder than bottom margins that
+wander, or, in typesetter jargon, &#8220;hang.&#8221; There are,
+of course, situations where whitespace at the bottom of a page
+may be unavoidable (for example, you wouldn&#8217;t want a head
 to appear at the bottom of the page without some text underneath
 it), but in all cases where hanging bottom margins can be avoided,
 mom does avoid them, by clever adjustments to leading (&#8220;line
@@ -298,25 +258,24 @@
 
 <p>
 Writing documentation is tough, no doubt about it.  One is never
-quite sure of the user&#8217;s level of expertise.  Is s/he new
-to the application, new to its underlying protocols and programs,
-new to the operating system, new to computers?  At some point, one
-has to decide whom the documentation is for.  Making the wrong
-decision can mean the difference between a program that gets used
-and a program that gets tossed.
+quite sure of the user&#8217;s level of expertise.  Is s/he new to
+the application, new to its underlying protocols and programs, new
+to the operating system?  At some point, one has to decide for whom
+the documentation is intended.  Making the wrong choice can mean the
+difference between a program that gets used and a program that gets
+tossed.
 </p>
 
 <p>
 Mom&#8217;s documentation assumes users know their way around
-their own operating system (basic file management, how to invoke
-commands, how to use a text editor, etc).  I use GNU/Linux,
+their own operating system (basic file management, how to use
+the command line, how to use a text editor, etc).  I run GNU/Linux,
 and while the documentation may exhibit a GNU/Linux bias, mom
-and groff can, in fact, be used on a variety of other popular
-operating systems, including the one from Redmond, Virginia, USA.
+and groff can, in fact, be run on other platforms.
 </p>
 
 <p>
-The documentation further assumes they at least know what groff
+The documentation further assumes users at least know what groff
 is, even if they don&#8217;t know much about it.  Lastly,
 it assumes that everyone&mdash;groff newbies and experts
 alike&mdash;learns faster from a few well-placed examples than
@@ -329,7 +288,7 @@
 aren&#8217;t enough, I offer examples.
 </p>
 
-<h2 id="canonical" class="docs">Canonical reference materials</h2>
+<h3 id="canonical" class="docs">Canonical reference materials</h3>
 
 <p>
 The canonical reference materials for groff are
@@ -337,13 +296,12 @@
 is available
 <a href="http://www.kohala.com/start/troff/";>here</a>)
 and the <strong>troff</strong> and <strong>groff_diff</strong>
-manpages.  Another excellent source of information (maybe the best)
-is the groff info pages, available by typing
-<kbd>info groff</kbd>
-at the command line (assuming you have the TeXinfo standalone
-browser installed on your system, which is standard for most
-GNU/Linux distributions).  And for inputting special characters,
-see <kbd>man groff_char</kbd>.
+manpages.  The most complete and up-to-date source of information is
+the groff info pages, available by typing <kbd>info groff</kbd> at
+the command line (assuming you have the TeXinfo standalone browser
+installed on your system, which is standard for most GNU/Linux
+distributions).  And for inputting special characters, see <kbd>man
+groff_char</kbd>.
 </p>
 
 <p style="margin-top: 24px;">
@@ -355,6 +313,21 @@
 <i>Mea culpa.</i>
 </p>
 
+<p>
+Groff has ancillary programmes (pre-processors) for generating
+tables (<strong>tbl</strong>), diagrams (<strong>pic</strong>), and
+equations (<strong>eqn</strong>), which may be used in conjuction
+with mom.  The manuals describing their usage are found at:
+<br/>
+<span style="display:block; margin-top: .5em">
+<kbd>&nbsp;&nbsp;tbl</kbd>&nbsp;<a 
href="http://www.kohala.com/start/troff/v7man/tbl/tbl.ps";>http://www.kohala.com/start/troff/v7man/tbl/tbl.ps</a>
+<br/>
+<kbd>&nbsp;&nbsp;pic</kbd>&nbsp;<a 
href="http://www.kohala.com/start/troff/gpic.raymond.ps";>http://www.kohala.com/start/troff/gpic.raymond.ps</a>
+<br/>
+<kbd>&nbsp;&nbsp;eqn</kbd>&nbsp;<a 
href="http://www.kohala.com/start/troff/v7man/eqn/eqn2e.ps";>http://www.kohala.com/start/troff/v7man/eqn/eqn2e.ps</a>
+</span>
+</p>
+
 <div class="box-tip">
 <p class="tip-top" style="padding-bottom: 9px;">
 <b>Note:</b> Mom&#8217;s macro file (om.tmac) is heavily
@@ -366,10 +339,10 @@
 
 <div class="box-tip">
 <p class="tip-top" style="padding-bottom: 9px; text-indent: 0px;">
-<strong>Addendum:</strong> As of version 1.4-a, the main macro
-file, om.tmac, is now stripped of comments when groff is built
-from sources. om.tmac in the sources themselves still contains
-the comments, as do the tarballs posted on mom&#8217;s homepage.
+<strong>Addendum:</strong> The main macro file, om.tmac, is stripped
+of comments when groff is built from sources. om.tmac in the sources
+themselves still contains the comments, as do the tarballs posted on
+mom&#8217;s homepage.
 </p>
 </div>
 
@@ -399,16 +372,16 @@
       of the argument, not the argument itself.
   </li>
   <li>If an argument begins with or is surrounded by double-quotes, the
-      double quotes MUST be included in the argument.
+      double quotes must be included in the argument.
   </li>
   <li>If the user has a choice between several arguments, each of the
       choices is separated by the pipe character
       (<kbd>|</kbd>), which means &#8220;or.&#8221;
   </li>
   <li>Arguments that are optional are surrounded by square brackets.</li>
-  <li><kbd>&lt;off&gt;</kbd> in an argument list means that any
-      argument other than those in the argument list turns the
-      macro off.
+  <li><kbd>&lt;off&gt;</kbd> or <kbd>&lt;anything&gt;</kbd> in an argument
+      list means that any argument other than those in the argument
+      list turns the macro off.
   </li>
 </ol>
 
@@ -417,11 +390,10 @@
 <p>
 Some macros don&#8217;t require an argument.  They simply start
 something.  When you need to turn them off, the same macro with
-<em>any</em> argument will do the trick.  That&#8217;s right:
-<em>any</em> argument (in caps, lowercase or a mixture
-thereof).  This permits choosing whatever works for you:
-<kbd>OFF, end, Quit, Q, X</kbd>...  Hell, it
-could even be <kbd>I_love_mom</kbd>.
+any argument will do the trick.  That&#8217;s right: <em>any</em>
+argument (in caps, lowercase or a mixture thereof).  This permits
+choosing whatever works for you: <kbd>OFF, end, Quit, Q, X</kbd>,
+and so on.
 </p>
 
 <p>

Index: momdoc/letters.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/letters.html,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -b -r1.17 -r1.18
--- momdoc/letters.html 22 Feb 2011 19:42:30 -0000      1.17
+++ momdoc/letters.html 31 Aug 2012 22:49:59 -0000      1.18
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -39,6 +41,17 @@
 
 <h1 class="docs">Writing letters</h1>
 
+<div style="width: 33%; margin: auto;">
+<ul class="no-enumerator">
+  <li><a href="#letters-intro">Introduction</a>
+  <li><a href="#letters-tutorial">Tutorial</a></li>
+  <li><a href="#letters-defaults">Mom&#8217;s default letter style</a>
+  <li><a href="#index-letters-macros">The letter macros</a>
+</ul>
+</div>
+
+<div class="rule-medium"><hr/></div>
+
 <h2 id="letters-intro" class="docs">Introduction</h2>
 
 <p>
@@ -60,7 +73,7 @@
 </p>
 
 <div class="examples-container" style="margin-top: 1.5em; margin-bottom: 
1.5em;">
-<h3 id="tutorial" class="docs">Tutorial &ndash; writing letters</h3>
+<h3 id="letters-tutorial" class="docs">Tutorial &ndash; writing letters</h3>
 
 <p>
 Mom letters begin, like all mom-processed documents, with
@@ -91,7 +104,7 @@
 the date, the addressee (in business correspondence, typically both
 name and address), the addresser (that&#8217;s you; in business
 correspondence, typically both name and address), and a greeting
-(in full, e.g. &#8220;Dear Mr. Smith,&#8221; or &#8220;Dear
+(in full, eg &#8220;Dear Mr. Smith,&#8221; or &#8220;Dear
 Mr. Smith:&#8221;).
 </p>
 
@@ -113,13 +126,6 @@
 </p>
 
 <p>
-(In pre 1.1.7-a releases of mom, the order of entering headers was
-fixed at the above.  This has been changed, although if you do
-follow the above order, mom will continue to behave exactly as she
-did in pre 1.1.7-a.)
-</p>
-
-<p>
 Once you&#8217;ve filled in what you need to get a letter started,
 simply type the letter, introducing each and every paragraph,
 including the first, with the
@@ -210,7 +216,7 @@
 </p>
 </div>
 
-<h2 id="letters-defaults" class="docs">Mom&#8217;s default letter style</h2>
+<h2 id="letters-defaults" class="docs">Default letter style</h2>
 
 <p>
 In letters, if the order of header macros is
@@ -292,7 +298,7 @@
   Family                    Times Roman                Courier
   Font                      roman                      roman
   Point size                12                         12
-  Line space                13.5                       12 (i.e. singlespaced)
+  Line space                13.5                       12 (ie singlespaced)
   Paragraph indent          3 ems                      3 picas
   Spaced paragraphs         yes                        no
   Footers*                  yes                        yes
@@ -475,7 +481,7 @@
 
 <p>
 Invoke <kbd>.CLOSING</kbd> on a line by itself after the body of
-the letter, with the closing you&#8217;d like (e.g. &#8220;Yours
+the letter, with the closing you&#8217;d like (eg &#8220;Yours
 truly,&#8221;) underneath, like this:
 <br/>
 <span class="pre-in-pp">
@@ -504,7 +510,7 @@
 <a href="definitions.html#unitofmeasure">unit of measure</a>
 appended to it, unless you want an indent of 0 (zero).  Mom&#8217;s
 default is one half the width of the letter&#8217;s line length
-(i.e. halfway across the page).  If you wanted, instead, an indent of
+(ie halfway across the page).  If you wanted, instead, an indent of
 6
 <a href="definitions.html#picaspoints">picas</a>,
 you&#8217;d do it like this:
@@ -536,7 +542,7 @@
 
 <!-- -NO_SUITE- -->
 
-<div class="box-macro-args" style="margin-top: 2em;">
+<div id="no-suite" class="box-macro-args" style="margin-top: 2em;">
 Macro: <b>NO_SUITE</b>
 </div>
 

Index: momdoc/macrolist.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/macrolist.html,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -b -r1.19 -r1.20
--- momdoc/macrolist.html       27 Feb 2011 17:24:38 -0000      1.19
+++ momdoc/macrolist.html       31 Aug 2012 22:49:59 -0000      1.20
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -46,7 +48,6 @@
 elsewhere in the documentation.
 </p>
 
-
 <div class="macro-list-container" style="padding-left: 9px; padding-right: 
9px; padding-bottom: 1px;">
 <h2 class="docs" style="text-align: center; padding-top: 15px;">Index to the 
quick reference guide</h2>
 <div style="width: 50%; float: left; margin-right: 9px;">
@@ -69,7 +70,7 @@
   <li><a href="#qr-15">Colour</a></li>
   <li><a href="#qr-16">Dropcaps</a></li>
   <li><a href="#qr-17">Utilities</a></li>
-  <li><a href="#qr-18">Graphical Objects</a></li>
+  <li><a href="#qr-18">Graphics, images and floats</a></li>
 </ul>
 <h3 class="docs" style="margin-top: -.5em;">DOCUMENT PROCESSING MACROS</h3>
 <ul style="margin-top: .5em; margin-left: 0; padding-left: 0; list-style-type: 
none;">
@@ -81,12 +82,9 @@
   <li><a href="#qr-24">Initiate document processing</a></li>
 </ul>
 </div>
-<ul style="margin-top: 1.75em; margin-left: 0; padding-left: 0; 
list-style-type: none;">
+<ul style="margin-top: 2.7em; margin-left: 0; padding-left: 0; 
list-style-type: none;">
   <li><a href="#qr-25">Epigraphs</a></li>
-  <li><a href="#qr-26">Main heads</a></li>
-  <li><a href="#qr-27">Subheads</a></li>
-  <li><a href="#qr-28">Subsubheads</a></li>
-  <li><a href="#qr-29">Paragraph heads</a></li>
+  <li><a href="#qr-26">Headings</a></li>
   <li><a href="#qr-30">Paragraphs</a></li>
   <li><a href="#qr-31">Quotes (line for line quotes)</a> </li>
   <li><a href="#qr-32">Blockquotes (cited passages of text)</a></li>
@@ -107,6 +105,7 @@
   <li><a href="#qr-47">Document and section cover (title) pages</a></li>
   <li><a href="#qr-48">Utilities</a></li>
 </ul>
+<br/>
 </div>
 
 <h2 class="docs">Quick reference guide</h2>
@@ -258,7 +257,7 @@
 <th id="qr-6" class="quick-ref" colspan="2" >+++ Hyphenation</th>
 </tr>
 <tr>
-<td><a href="typesetting.html#hy">HY</a></td><td>-- automatic hyphenation on 
or off</td>
+<td><a href="typesetting.html#hy">HY</a></td><td>-- automatic hyphenation 
on/off</td>
 </tr>
 <tr>
 <td><a href="typesetting.html#hy-set">HY_SET</a></td><td>-- set automatic 
hyphenation parameters</td>
@@ -282,7 +281,7 @@
 <th id="qr-8" class="quick-ref" colspan="2" >+++ Kerning, ligatures, 
smartquotes</th>
 </tr>
 <tr>
-<td><a href="typesetting.html#kern">KERN</a></td><td>-- automatic character 
pair kerning on or off</td>
+<td><a href="typesetting.html#kern">KERN</a></td><td>-- automatic character 
pair kerning on/off</td>
 </tr>
 <tr>
 <td><a href="inlines.html#inline-kerning-mom">\*[BU n]</a></td><td>-- move 
characters pairs closer together inline</td>
@@ -291,19 +290,19 @@
 <td><a href="inlines.html#inline-kerning-mom">\*[FU n]</a></td><td>-- move 
character pairs further apart inline</td>
 </tr>
 <tr>
-<td><a href="typesetting.html#rw">RW</a></td><td>-- uniformly reduce space 
between characters (tighten)</td>
+<td><a href="typesetting.html#rw">RW</a></td><td>-- uniformly tighten space 
between characters</td>
 </tr>
 <tr>
-<td><a href="typesetting.html#ew">EW</a></td><td>-- uniformly increase space 
between characters (loosen)</td>
+<td><a href="typesetting.html#ew">EW</a></td><td>-- uniformly loosen space 
between characters</td>
 </tr>
 <tr>
-<td><a href="typesetting.html#br-at-line-kern">BR_AT_LINE_KERN</a></td><td>-- 
break previous line every time RW or EW is invoked</td>
+<td><a href="typesetting.html#br-at-line-kern">BR_AT_LINE_KERN</a></td><td>-- 
break previous line when RW or EW is invoked</td>
 </tr>
 <tr>
-<td><a href="typesetting.html#ligatures">LIGATURES</a></td><td>-- automatic 
generation of ligatures on or off</td>
+<td><a href="typesetting.html#ligatures">LIGATURES</a></td><td>-- automatic 
generation of ligatures on/off</td>
 </tr>
 <tr>
-<td><a href="goodies.html#smartquotes">SMARTQUOTES</a></td><td>-- smartquoting 
on or off</td>
+<td><a href="goodies.html#smartquotes">SMARTQUOTES</a></td><td>-- smartquoting 
on/off</td>
 </tr>
 </table>
 
@@ -390,10 +389,13 @@
 <td><a href="typesetting.html#tq">TQ</a></td><td>-- quit (exit) tabs</td>
 </tr>
 <tr>
-<td><a href="typesetting.html#inline-st">\*[STn]...\*[STnX]</a></td><td>-- 
string tabs (mark tab positions inline)</td>
+<td><a href="typesetting.html#inline-st">\*[ST&lt;n&gt;]...</a></td><td>-- 
string tabs (mark tab positions inline)</td>
 </tr>
 <tr>
-<td><a href="typesetting.html#tn">TN</a></td><td>-- move to tab &lt;n+1&gt; 
without advancing on the page</td>
+<td><a href="typesetting.html#inline-st">\*[ST&lt;n&gt;X]</a>
+</tr>
+<tr>
+<td><a href="typesetting.html#tn">TN</a></td><td>-- move to tab&lt;n+1&gt; 
without advancing on the page</td>
 </tr>
 <tr>
 <td><a href="typesetting.html#st">ST</a></td><td>-- set quad/fill for string 
tabs</td>
@@ -408,13 +410,16 @@
 <td><a href="goodies.html#underscore">UNDERSCORE</a></td><td>-- underscore</td>
 </tr>
 <tr>
-<td><a href="goodies.html#UNDERSCORE2">UNDERSCORE2</a></td><td>-- double 
underscore</td>
+<td><a href="goodies.html#underscore2">UNDERSCORE2</a></td><td>-- double 
underscore</td>
 </tr>
 <tr>
 <td><a href="goodies.html#underline">UNDERLINE</a></td><td>-- underline (fixed 
width fonts only)</td>
 </tr>
 <tr>
-<td><a href="goodies.html#ul">\*[UL]...\*[ULX]</a></td><td>-- invoke underling 
inline (fixed width fonts only)</td>
+<td><a href="goodies.html#ul">\*[UL]...</a></td><td>-- invoke underlining 
inline (fixed width fonts only)</td>
+</tr>
+<tr>
+<td><a href="goodies.html#ul">\*[ULX]</a></td>
 </tr>
 </table>
 
@@ -423,13 +428,13 @@
 <th id="qr-13" class="quick-ref" colspan="2" >+++ Superscipts</th>
 </tr>
 <tr>
-<td><a href="goodies.html#sup">\*[SUP]...\*[SUPX]</a></td><td>-- superscript 
(inline)</td>
+<td><a href="goodies.html#sup">\*[SUP]...\*[SUPX]</a></td><td>-- 
superscript</td>
 </tr>
 <tr>
-<td><a href="goodies.html#sup">\*[CONDSUP]...\*[CONDSUPX]</a></td><td>-- 
pseudo-condensed superscript (inline)</td>
+<td><a href="goodies.html#sup">\*[CONDSUP]...\*[CONDSUPX]</a></td><td>-- 
pseudo-condensed superscript</td>
 </tr>
 <tr>
-<td><a href="goodies.html#sup">\*[EXTSUP]...\*[EXTSUPX]</a></td><td>-- pseudo 
extended supercript (inline)</td>
+<td><a href="goodies.html#sup">\*[EXTSUP]...\*[EXTSUPX]</a></td><td>-- pseudo 
extended supercript</td>
 </tr>
 <tr>
 <td><a href="goodies.html#sup-raise">SUPERSCRIPT_RAISE_AMOUNT</a></td><td>-- 
vertical offset of superscripts</td>
@@ -453,7 +458,7 @@
 <td><a href="docelement.html#reset-list">RESET_LIST</a></td><td>-- clear and 
reset a list&#8217;s enumerator</td>
 </tr>
 <tr>
-<td><a href="docelement.html#pad-list-digits">PAD_LIST_DIGITS</a></td><td>-- 
space to leave for digits in a digit-enumerated list</td>
+<td><a href="docelement.html#pad-list-digits">PAD_LIST_DIGITS</a></td><td>-- 
reserve space for digits</td>
 </tr>
 </table>
 
@@ -468,7 +473,7 @@
 <td><a href="color.html#color">COLOR</a></td><td>-- begin using an initialized 
colour</td>
 </tr>
 <tr>
-<td><a href="color.htmlxcolor">XCOLOR</a></td><td>-- initialize a "named" X 
colour</td>
+<td><a href="color.html#xcolor">XCOLOR</a></td><td>-- initialize a "named" X 
colour</td>
 </tr>
 <tr>
 <td><a href="color.html#color-inline">\*[&lt;colorname&gt;]</a></td><td>-- 
begin using an initialized colour inline</td>
@@ -525,7 +530,7 @@
 <td><a href="typesetting.html#newpage">NEWPAGE</a></td><td>-- break to a new 
page</td>
 </tr>
 <tr>
-<td><a href="goodies.html#pad">PAD</a></td><td>-- insert equalized regions of 
whitespace into a line</td>
+<td><a href="goodies.html#pad">PAD</a></td><td>-- insert equalized whitespace 
into a line</td>
 </tr>
 <tr>
 <td><a href="goodies.html#pad-marker">PAD_MARKER</a></td><td>-- change the pad 
marker</td>
@@ -534,7 +539,7 @@
 <td><a href="inlines.html#inline-rule-mom">\*[RULE]</a></td><td>-- draw a full 
measure rule</td>
 </tr>
 <tr>
-<td><a href="goodies.html#sizespecs">SIZESPECS</a></td><td>-- get font's 
cap-height, x-height and descender depth</td>
+<td><a href="goodies.html#sizespecs">SIZESPECS</a></td><td>-- get cap-height, 
x-height and descender depth</td>
 </tr>
 <tr>
 <td><a href="goodies.html#silent">SILENT</a></td><td>-- output processing off 
or on</td>
@@ -546,7 +551,7 @@
 
 <table class="quick-ref">
 <tr>
-<th id="qr-18" class="quick-ref" colspan="2" >+++ Graphical objects</th>
+<th id="qr-18" class="quick-ref" colspan="2" >+++ Graphics, images and 
floats</th>
 </tr>
 <tr>
 <td><a href="graphical.html#drh">DRH</a></td><td>-- draw a horizontal rule</td>
@@ -564,7 +569,15 @@
 <td><a href="inlines.html#rule-weight">RULE_WEIGHT</a></td><td>-- set weight 
of rules drawn with \*[RULE]</td>
 </tr>
 <tr>
-<td><a href="docelement.html#pspic">PSPIC</a></td><td>-- insert a PostScript 
image</td>
+<td><a href="images.html#pdf-image">PDF_IMAGE</a></td><td>-- insert a PDF 
image</td>
+</tr>
+<tr>
+<td><a href="images.html#pspic">PSPIC</a></td><td>-- insert a PostScript 
image</td>
+</tr>
+<tr>
+<td style="vertical-align: top"><a 
href="images.html#float">FLOAT</a></td><td>-- keep blocks of input together, 
output on next page
+<br/>
+&nbsp;&nbsp;&nbsp;if necessary</td>
 </tr>
 </table>
 
@@ -578,19 +591,19 @@
 <td><a href="docprocessing.html#title">TITLE</a></td><td>-- document title</td>
 </tr>
 <tr>
-<td><a href="docprocessing.html#doctitle">DOCTITLE</a></td><td>-- overall 
document title (if different from TITLE)</td>
+<td><a href="docprocessing.html#doc-title">DOCTITLE</a></td><td>-- overall 
document title (if different from TITLE)</td>
 </tr>
 <tr>
-<td><a href="docelement.html#endnote-title">ENDNOTE_TITLE</a></td><td>-- 
document/chapter identification string for endnotes</td>
+<td><a href="docelement.html#endnote-title">ENDNOTE_TITLE</a></td><td>-- 
document/chapter id string for endnotes</td>
 </tr>
 <tr>
 <td><a href="docprocessing.html#chapter">CHAPTER</a></td><td>-- chapter 
number</td>
 </tr>
 <tr>
-<td><a href="docprocessing.html#chapter">CHAPTER_TITLE</a></td><td>-- chapter 
title</td>
+<td><a href="docprocessing.html#chapter-title">CHAPTER_TITLE</a></td><td>-- 
chapter title</td>
 </tr>
 <tr>
-<td><a href="docprocessing.html#draft-string">CHAPTER_STRING</a></td><td>-- 
what to use in place of &#8220;Chapter&#8221;</td>
+<td><a href="docprocessing.html#chapter-string">CHAPTER_STRING</a></td><td>-- 
what to use in place of &#8220;Chapter&#8221;</td>
 </tr>
 <tr>
 <td><a href="docprocessing.html#subtitle">SUBTITLE</a></td><td>-- document 
subtitle</td>
@@ -605,10 +618,10 @@
 <td><a href="docprocessing.html#covertitle">COVERTITLE</a></td><td>-- section 
cover title</td>
 </tr>
 <tr>
-<td><a href="docprocessing.html#covertitle">COPYRIGHT</a></td><td>-- 
copyright</td>
+<td><a href="docprocessing.html#copyright">COPYRIGHT</a></td><td>-- 
copyright</td>
 </tr>
 <tr>
-<td><a href="docprocessing.html#covertitle">MISC</a></td><td>-- miscellaneous 
cover information</td>
+<td><a href="docprocessing.html#misc">MISC</a></td><td>-- miscellaneous cover 
information</td>
 </tr>
 <tr>
 <td><a href="docprocessing.html#draft">DRAFT</a></td><td>-- document&#8217;s 
draft number</td>
@@ -644,16 +657,13 @@
 <th id="qr-21" class="quick-ref" colspan="2" >+++ Line numbering</th>
 </tr>
 <tr>
-<td><a href="docelement.html#number-lines">NUMBER_LINES</a></td><td>-- 
automatic line numbering on or off</td>
+<td><a href="docelement.html#number-lines">NUMBER_LINES</a></td><td>-- 
automatic line numbering on/off</td>
 </tr>
 <tr>
-<td><a href="docelement.html#number-lines-control">Control macros</a></td>
+<td><a 
href="docelement.html#number-quote-lines">NUMBER_QUOTE_LINES</a></td><td>-- 
numbering of QUOTE lines on/off</td>
 </tr>
 <tr>
-<td><a 
href="docelement.html#number-quote-lines">&nbsp;NUMBER_QUOTE_LINES</a></td><td>--
 numbering of QUOTE lines on or off</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#number-blockquote-lines">&nbsp;NUMBER_BLOCKQUOTE_LINES</a></td><td>--
 numbering of BLOCKQUOTE lines on or off</td>
+<td><a 
href="docelement.html#number-blockquote-lines">NUMBER_BLOCKQUOTE_LINES</a></td><td>--
 numbering of BLOCKQUOTE lines on/off</td>
 </tr>
 </table>
 
@@ -677,19 +687,19 @@
 <th id="qr-23" class="quick-ref" colspan="2" >+++ TYPEWRITE control macros</th>
 </tr>
 <tr>
-<td><a 
href="docprocessing.html#typewrite-control">UNDERLINE_ITALIC</a></td><td>--  
underlining of italics on</td>
+<td><a 
href="docprocessing.html#typewriter-underlining">UNDERLINE_ITALIC</a></td><td>--
  underlining of italics on</td>
 </tr>
 <tr>
-<td><a 
href="docprocessing.html#underline-quotes">UNDERLINE_QUOTES</a></td><td>--  
underlining of QUOTEs on or off</td>
+<td><a 
href="docprocessing.html#printstyle-italics">UNDERLINE_QUOTES</a></td><td>--  
underlining of QUOTEs on/off</td>
 </tr>
 <tr>
-<td><a 
href="docprocessing.html#typewrite-control">ITALIC_MEANS_ITALIC</a></td><td>--  
use real italics (not underlining)</td>
+<td><a 
href="docprocessing.html#printstyle-italics">ITALIC_MEANS_ITALIC</a></td><td>-- 
 use real italics (not underlining)</td>
 </tr>
 <tr>
-<td><a 
href="docprocessing.html#typewrite-control">UNDERLINE_SLANT</a></td><td>--  
underlining of pseudo-italics on</td>
+<td><a 
href="docprocessing.html#typewriter-underlining">UNDERLINE_SLANT</a></td><td>-- 
 underlining of pseudo-italics on</td>
 </tr>
 <tr>
-<td><a 
href="docprocessing.html#typewrite-control">SLANT_MEANS_SLANT</a></td><td>--  
use pseudo italics (not underlining)</td>
+<td><a 
href="docprocessing.html#typewriter-underlining">SLANT_MEANS_SLANT</a></td><td>--
  use pseudo italics (not underlining)</td>
 </tr>
 </table>
 
@@ -716,88 +726,17 @@
 
 <table class="quick-ref">
 <tr>
-<th id="qr-26" class="quick-ref" colspan="2" >+++ Main heads</th>
+<th id="qr-26" class="quick-ref" colspan="2" >+++ HEADINGS</th>
 </tr>
 <tr>
-<td><a href="docelement.html#head">HEAD</a></td><td>-- set a main head</td>
+<td><a href="docelement.html#heading">HEADING</a></td><td>-- hierarchical 
headings</td>
 </tr>
 <tr>
-<td><a href="docelement.html#head-general">Control macros</a></td><td>-- 
change default style of heads</td>
+<td><a href="docelement.html#heading-control">Control macros</a></td><td>-- 
style heading levels</td>
 </tr>
-<tr>
-<td><a href="docelement.html#head-space">&nbsp;HEAD_SPACE</a></td><td>-- 
control vertical space around heads</td>
+<td><a href="docelement.html#heading-style">&nbsp;HEADING_STYLE</a></td><td>-- 
set style parameters for heading levels</td>
 </tr>
-<tr>
-<td><a href="docelement.html#number-heads">&nbsp;NUMBER_HEADS</a></td><td>-- 
number heads</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#prefix-chapter-number">&nbsp;PREFIX_CHAPTER_NUMBER</a></td><td>--
 prefix chapter number to head numbers</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#reset-head-number">&nbsp;RESET_HEAD_NUMBER</a></td><td>-- 
reset head number to "1"</td>
-</tr>
-</table>
-
-<table class="quick-ref">
-<tr>
-<th id="qr-27" class="quick-ref" colspan="2" >+++ Subheads</th>
-</tr>
-<tr>
-<td><a href="docelement.html#subhead">SUBHEAD</a></td><td>-- set a subhead</td>
-</tr>
-<tr>
-<td><a href="docelement.html#subhead-general">Control macros</a></td><td>-- 
change default style of subheads</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#number-subheads">&nbsp;NUMBER_SUBHEADS</a></td><td>-- 
number subheads</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#prefix-chapter-number">&nbsp;PREFIX_CHAPTER_NUMBER</a></td><td>--
 prefix chapter number to subhead numbers</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#reset-subhead-number">&nbsp;RESET_SUBHEAD_NUMBER</a></td><td>--
 reset subhead number to "1"</td>
-</tr>
-</table>
-
-<table class="quick-ref">
-<tr>
-<th id="qr-28" class="quick-ref" colspan="2" >+++ Subsubheads</th>
-</tr>
-<tr>
-<td><a href="docelement.html#subsubhead">SUBSUBHEAD</a></td><td>-- set a 
subsubhead</td>
-</tr>
-<tr>
-<td><a href="docelement.html#subsubhead-general">Control macros</a></td><td>-- 
change default style of subsubheads</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#number-subsubheads">&nbsp;NUMBER_SUBSUBHEADS</a></td><td>--
 number subsubheads</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#prefix-chapter-number">&nbsp;PREFIX_CHAPTER_NUMBER</a></td><td>--
 prefix chapter number to subsubhead numbers</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#reset-subsubhead-number">&nbsp;RESET_SUBSUBHEAD_NUMBER</a></td><td>--
 reset subsubhead number to "1"</td>
-</tr>
-</table>
-
-<table class="quick-ref">
-<tr>
-<th id="qr-29" class="quick-ref" colspan="2" >+++ Paragraph heads</th>
-</tr>
-<tr>
-<td><a href="docelement.html#parahead">PARAHEAD</a></td><td>-- set a paragraph 
head</td>
-</tr>
-<tr>
-<td><a href="docelement.html#parahead-general">Control macros</a></td><td>-- 
change default style of paraheads</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#number-paraheads">&nbsp;NUMBER_PARAHEADS</a></td><td>-- 
number paraheads</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#prefix-chapter-number">&nbsp;PREFIX_CHAPTER_NUMBER</a></td><td>--
 prefix chapter number to parahead numbers</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#reset-parahead-number">&nbsp;RESET_PARAHEAD_NUMBER</a></td><td>--
 reset parahead number to "1"</td>
+<td><a 
href="docelement.html#prefix-chapter-number">&nbsp;PREFIX_CHAPTER_NUMBER</a></td><td>--
 add chapter number to heading numbering</td>
 </tr>
 </table>
 
@@ -818,10 +757,10 @@
 <td><a href="docelement.html#para-indent">&nbsp;PARA_INDENT</a></td><td>-- set 
the paragraph first-line indent</td>
 </tr>
 <tr>
-<td><a 
href="docelement.html#indent-first-paras">&nbsp;INDENT_FIRST_PARAS</a></td><td>--
 indenting of paragraph first-lines on or off</td>
+<td><a 
href="docelement.html#para-indent-first">&nbsp;INDENT_FIRST_PARAS</a></td><td>--
 indenting of paragraph first-lines on/off</td>
 </tr>
 <tr>
-<td><a href="docelement.html#pp-space">&nbsp;PARA_SPACE</a></td><td>-- 
linespace between paragraphs on or off</td>
+<td><a href="docelement.html#pp-space">&nbsp;PARA_SPACE</a></td><td>-- 
linespace between paragraphs on/off</td>
 </tr>
 </table>
 
@@ -838,9 +777,6 @@
 <tr>
 <td><a 
href="docelement.html#always-fullspace-quotes">&nbsp;ALWAYS_FULLSPACE_QUOTES</a></td><td>--
 control vertical space around quotes</td>
 </tr>
-<tr>
-<td><a href="docelement.html#break-quote">&nbsp;BREAK_QUOTE</a></td><td>-- 
deprecated</td>
-</tr>
 </table>
 
 <table class="quick-ref">
@@ -851,13 +787,10 @@
 <td><a href="docelement.html#blockquote">BLOCKQUOTE</a></td><td>-- set longer 
passages of cited text</td>
 </tr>
 <tr>
-<td><a href="docelement.html#blockquote-general">Control macros</a></td><td>-- 
change default style of blockquotes</td>
-</tr>
-<tr>
-<td><a 
href="docelement.html#always-fullspace-quotes">&nbsp;ALWAYS_FULLSPACE_BLOCKQUOTES</a></td><td>--
 control vertical space around quotes</td>
+<td><a href="docelement.html#blockquote-general">Control macros</a></td><td>-- 
change default blockquote style</td>
 </tr>
 <tr>
-<td><a 
href="docelement.html#break-quote">&nbsp;BREAK_BLOCKQUOTE</a></td><td>-- 
deprecated</td>
+<td><a 
href="docelement.html#always-fullspace-quotes">&nbsp;ALWAYS_FULLSPACE_BLOCKQUOTES</a></td><td>--
 control vertical spacing</td>
 </tr>
 </table>
 
@@ -902,7 +835,7 @@
 <th id="qr-35" class="quick-ref" colspan="2" >+++ Document termination 
string</th>
 </tr>
 <tr>
-<td><a href="docelement.html#finis">FINIS</a></td><td>-- insert a document 
termination string (e.g. --END--)</td>
+<td><a href="docelement.html#finis">FINIS</a></td><td>-- insert a document 
termination string</td>
 </tr>
 <tr>
 <td><a href="docelement.html#finis-control">Control macros</a></td><td>-- 
change default style finis string</td>
@@ -911,6 +844,9 @@
 <td><a href="docelement.html#finis-string">&nbsp;FINIS_STRING</a></td><td>-- 
set the document termination string</td>
 </tr>
 <tr>
+<td><a 
href="docelement.html#finis-string-caps">&nbsp;FINIS_STRING_CAPS</a></td><td>-- 
capitalization of termination string</td>
+</tr>
+<tr>
 <td><a href="docelement.html#finis-color">&nbsp;FINIS_COLOR</a></td><td>-- set 
the document termination string colour</td>
 </tr>
 </table>
@@ -926,7 +862,7 @@
 <td><a href="docelement.html#footnote-general">Control macros</a></td><td>-- 
change default style of footnotes</td>
 </tr>
 <tr>
-<td><a 
href="docelement.html#footnote-markers">&nbsp;FOOTNOTE_MARKERS</a></td><td>-- 
footnote markers on or off</td>
+<td><a 
href="docelement.html#footnote-markers">&nbsp;FOOTNOTE_MARKERS</a></td><td>-- 
footnote markers on/off</td>
 </tr>
 <tr>
 <td><a 
href="docelement.html#footnote-marker-style">&nbsp;FOOTNOTE_MARKER_STYLE</a></td><td>--
 type of footnote marker to use</td>
@@ -935,19 +871,17 @@
 <td><a 
href="docelement.html#reset-footnote-number">&nbsp;RESET_FOOTNOTE_NUMBER</a></td><td>--
 reset footnote numbering</td>
 </tr>
 <tr>
-<td><a href="docelement.html#footnote-rule">&nbsp;FOOTNOTE_RULE</a></td><td>-- 
footnote separator rule on or off</td>
+<td><a href="docelement.html#footnote-rule">&nbsp;FOOTNOTE_RULE</a></td><td>-- 
footnote separator rule on/off</td>
 </tr>
 <tr>
-<td><a 
href="docelement.html#footnote-rule-adj">&nbsp;FOOTNOTE_RULE_ADJ</a></td><td>-- 
adjust vertical position of footnote rule</td>
+<td><a 
href="docelement.html#footnote-rule-adj">&nbsp;FOOTNOTE_RULE_ADJ</a></td><td>-- 
adjust position of footnote rule</td>
 </tr>
 <tr>
 <td><a 
href="docelement.html#footnote-rule-length">&nbsp;FOOTNOTE_RULE_LENGTH</a></td><td>--
 adjust length of footnote rule</td>
 </tr>
 <tr>
 <td style="vertical-align: top;"><a 
href="docelement.html#footnotes-run-on">&nbsp;FOOTNOTES_RUN_ON</a></td>
-  <td>-- instruct footnotes to be continuous (i.e. not to<br />
-&nbsp;&nbsp;&nbsp;begin on a new line; only for use with footnotes<br />
-&nbsp;&nbsp;&nbsp;identified by document line number)</td>
+  <td>-- instruct footnotes to be continuous</td>
 </tr>
 </table>
 
@@ -959,7 +893,7 @@
 <td><a href="docelement.html#endnote">ENDNOTE</a></td><td>-- set an 
endnote</td>
 </tr>
 <tr>
-<td style="vertical-align: top;"><a 
href="docelement.html#EN-mark">\*[EN-MARK]</a></td>
+<td style="vertical-align: top;"><a 
href="docelement.html#en-mark">\*[EN-MARK]</a></td>
   <td>-- mark initial line of a range of line numbers<br />
 &nbsp;&nbsp;&nbsp;(for use with line numbered endnotes)</td>
 </tr>
@@ -967,7 +901,7 @@
 <td><a href="docelement.html#endnotes">ENDNOTES</a></td><td>-- output 
endnotes</td>
 </tr>
 <tr>
-<td><a href="docelement.html#endnote-control">Control macros</a></td><td>-- 
change just about anything to do with endnotes</td>
+<td><a href="docelement.html#endnote-control">Control macros</a></td><td></td>
 </tr>
 </table>
 
@@ -985,7 +919,7 @@
 <td><a href="docelement.html#endnotes-main-title">Title control</a></td>
 </tr>
 <tr>
-<td><a href="docelement.html#endnotes-main-title">Document/section 
identification control</a></td>
+<td><a href="docelement.html#endnotes-doc-title">Document/section 
identification control</a></td>
 </tr>
 <tr>
 <td><a href="docelement.html#endnotes-numbering">Identification style</a></td>
@@ -1030,7 +964,7 @@
 <td><a href="refer.html#bibliography">BIBLIOGRAPHY</a></td><td>-- output a 
bibliography</td>
 </tr>
 <tr>
-<td><a href="refer.html#biblio-control">Control macros</a></td><td>-- change 
just about anything to do with bibliographies</td>
+<td><a href="refer.html#biblio-control">Control macros</a></td>
 </tr>
 </table>
 
@@ -1054,28 +988,34 @@
 <th id="qr-40" class="quick-ref" colspan="2" >+++ Tables of contents</th>
 </tr>
 <tr>
-<td><a href="docelement.html#toc">TOC</a></td><td>-- output a table of 
contents</td>
+<td><a href="tables-of-contents.html#toc">TOC</a></td><td>-- output a table of 
contents</td>
 </tr>
 <tr>
-<td><a href="docelement.html#toc-control">Control macros</a></td><td>-- change 
just about anything to do with tables of contents</td>
+<td><a href="tables-of-contents.html#index-toc-control">Control macros</a></td>
 </tr>
 </table>
 
 <table class="quick-ref" style="margin-top: -.5em; margin-left: 1em;">
 <tr>
-<td><a href="docelement.html#toc-general">General style control</a></td>
+<td><a href="tables-of-contents.html#toc-general">General style 
control</a></td>
+</tr>
+<tr>
+<td><a href="tables-of-contents.html#toc-pagenumbering">Page numbering</a></td>
+</tr>
+<tr>
+<td><a href="tables-of-contents.html#toc-header">Header string control</a></td>
 </tr>
 <tr>
-<td><a href="docelement.html#toc-pagenumbering">Page numbering</a></td>
+<td><a href="tables-of-contents.html#toc-style">Entries and reference page 
numbers style control</a></td>
 </tr>
 <tr>
-<td><a href="docelement.html#toc-header">Title control</a></td>
+<td><a href="tables-of-contents.html#toc-title-style">TOC_TITLE_STYLE</a></td>
 </tr>
 <tr>
-<td><a href="docelement.html#toc-style">Changing the style of the different 
table of contents entry types</a></td>
+<td><a href="tables-of-contents.html#toc-entry-style">TOC_ENTRY_STYLE</a></td>
 </tr>
 <tr>
-<td><a href="docelement.html#toc-additional">Additional table of contents 
control macros</a></td>
+<td><a href="tables-of-contents.html#toc-additional">Additional table of 
contents control macros</a></td>
 </tr>
 </table>
 
@@ -1141,10 +1081,10 @@
 <th id="qr-43" class="quick-ref" colspan="2" >+++ Managing a document&#8217;s 
first-page header</th>
 </tr>
 <tr>
-<td><a href="docprocessing.html#docheader">DOCHEADER</a></td><td>-- document 
first-page header on or off</td>
+<td><a href="docprocessing.html#docheader">DOCHEADER</a></td><td>-- document 
first-page header on/off</td>
 </tr>
 <tr>
-<td><a href="docprocessing.html#docheader-control-index">Control 
macros</a></td><td>-- change default style of docheader elements</td>
+<td><a href="docprocessing.html#index-docheader-control">Control 
macros</a></td><td>-- change default style of docheader elements</td>
 </tr>
 </table>
 
@@ -1153,37 +1093,38 @@
 <th id="qr-44" class="quick-ref" colspan="2" >+++ Managing page headers and 
footers</th>
 </tr>
 <tr>
-<td><a href="headfootpage.html#headers">HEADERS</a></td><td>-- page headers on 
or off</td>
+<td><a href="headfootpage.html#headers">HEADERS</a></td><td>-- page headers 
on/off</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#footers">FOOTERS</a></td><td>-- page footers on 
or off</td>
+<td><a href="headfootpage.html#footers">FOOTERS</a></td><td>-- page footers 
on/off</td>
 </tr>
 <tr>
-<td style="vertical-align: top;"><a 
href="headfootpage.html#headers-and-footers">HEADERS_AND_FOOTERS</a></td><td>-- 
enable generation of both headers and footers</td>
+<td style="vertical-align: top;"><a 
href="headfootpage.html#headers-and-footers">HEADERS_AND_FOOTERS</a></td><td>-- 
enable generation of both headers and</br>
+&nbsp;&nbsp;&nbsp;footers</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#index-reference">Control macros</a></td>
+<td><a href="headfootpage.html#headfoot-control">Control macros</a></td>
 </tr>
 </table>
 
 <table class="quick-ref" style="margin-top: -.5em; margin-left: 1em;">
 <tr>
-<td><a href="headfootpage.html#strings">Strings</a></td><td>-- 
left-right-center strings</td>
+<td><a href="headfootpage.html#hdrftr-strings">Strings</a></td><td>-- 
left-right-center strings</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#style">Style</a></td><td>-- change style 
defaults for headers and/or footers</td>
+<td><a href="headfootpage.html#hdrftr-style">Style</a></td><td>-- change 
defaults for headers and/or footers</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#global">Global</a></td><td>-- global style 
changes</td>
+<td><a href="headfootpage.html#hdrftr-style-global">Global</a></td><td>-- 
global style changes</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#part-by-part">Part-by-part</a></td><td>-- 
part-by-part style changes</td>
+<td><a href="headfootpage.html#hdrftr-style-part">Part-by-part</a></td><td>-- 
part-by-part style changes</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#vertical">Vertical placement</a></td><td>-- 
adjust postion of headers and/or footers</td>
+<td><a href="headfootpage.html#vertical-spacing">Vertical 
placement</a></td><td>-- adjust postion of headers and/or footers</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#separator-rule">Separator rule</a></td><td>-- 
manage the header/footer separator rule</td>
+<td><a href="headfootpage.html#hdrftr-separator">Separator rule</a></td><td>-- 
manage the header/footer separator rule</td>
 </tr>
 </table>
 
@@ -1192,7 +1133,7 @@
 <th id="qr-45" class="quick-ref" colspan="2" >+++ Recto/verso page headers and 
footers</th>
 </tr>
 <tr>
-<td><a href="rectoverso.html#recto-verso">RECTO_VERSO</a></td><td>-- 
recto/verso headers and/or footers on or off</td>
+<td><a href="rectoverso.html#recto-verso">RECTO_VERSO</a></td><td>-- 
recto/verso headers and/or footers on/off</td>
 </tr>
 <tr>
 <td><a href="rectoverso.html#switch-hdrftr">SWITCH_HEADERS</a></td><td>-- 
switch recto or verso header</td>
@@ -1201,16 +1142,16 @@
 <td><a href="rectoverso.html#switch-hdrftr">SWITCH_FOOTERS</a></td><td>-- 
switch recto or verso footer</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#hdrftr-rectoverso">HEADER_RECTO</a></td><td>-- 
string that constitutes a recto header</td>
+<td><a href="headfootpage.html#hdrftr-recto">HEADER_RECTO</a></td><td>-- 
string that constitutes a recto header</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#hdrftr-rectoverso">HEADER_VERSO</a></td><td>-- 
string that constitutes a verso header</td>
+<td><a href="headfootpage.html#hdrftr-verso">HEADER_VERSO</a></td><td>-- 
string that constitutes a verso header</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#hdrftr-rectoverso">FOOTER_RECTO</a></td><td>-- 
string that constitutes a recto footer</td>
+<td><a href="headfootpage.html#hdrftr-recto">FOOTER_RECTO</a></td><td>-- 
string that constitutes a recto footer</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#hdrftr-rectoverso">FOOTER_VERSO</a></td><td>-- 
string that constitutes a recto footer</td>
+<td><a href="headfootpage.html#hdrftr-verso">FOOTER_VERSO</a></td><td>-- 
string that constitutes a recto footer</td>
 </tr>
 </table>
 
@@ -1219,10 +1160,10 @@
 <th id="qr-46" class="quick-ref" colspan="2" >+++ Pagination</th>
 </tr>
 <tr>
-<td><a href="headfootpage.html#paginate">PAGINATE</a></td><td>-- pagination on 
or off</td>
+<td><a href="headfootpage.html#index-pagination">PAGINATE</a></td><td>-- 
pagination on/off</td>
 </tr>
 <tr>
-<td><a href="headfootpage.html#paginate-control">Control macros</a></td><td>-- 
change default style for pagination</td>
+<td><a href="headfootpage.html#index-pagination-control">Control 
macros</a></td><td>-- change default style for pagination</td>
 </tr>
 <tr>
 <td><a href="headfootpage.html#pagenumber">&nbsp;PAGENUMBER</a></td><td>-- 
user-defined (starting) page number</td>
@@ -1234,8 +1175,7 @@
 <td><a 
href="headfootpage.html#pagenum-on-first-page">&nbsp;PAGENUM_ON_FIRST_PAGE</a></td><td>--
 when footers are enabled</td>
 </tr>
 <tr>
-<td style="vertical-align: top;"><a 
href="headfootpage.html#draft-with-pagenumber">&nbsp;DRAFT_WITH_PAGENUMBER</a></td><td>--
 attach draft/revision information to page<br />
-&nbsp;&nbsp;&nbsp;numbers</td>
+<td style="vertical-align: top;"><a 
href="headfootpage.html#draft-with-pagenumber">&nbsp;DRAFT_WITH_PAGENUMBER</a></td><td>--
 attach draft/revision to page number</td>
 </tr>
 </table>
 
@@ -1250,13 +1190,13 @@
 <td><a href="cover.html#cover">DOC_COVER</a></td><td>-- information to include 
in a document cover</td>
 </tr>
 <tr>
-<td><a href="cover.html#on-off">COVERS</a></td><td>-- printing of section 
covers on or off</td>
+<td><a href="cover.html#on-off">COVERS</a></td><td>-- printing of section 
covers on/off</td>
 </tr>
 <tr>
-<td><a href="cover.html#on-off">DOC_COVERS</a></td><td>-- printing of document 
covers on or off</td>
+<td><a href="cover.html#on-off">DOC_COVERS</a></td><td>-- printing of document 
covers on/off</td>
 </tr>
 <tr>
-<td><a href="cover.html#cover-control-index">Control macros</a></td><td>-- 
change style defaults for covers</td>
+<td><a href="cover.html#cover-control">Control macros</a></td><td>-- change 
style defaults for covers</td>
 </tr>
 </table>
 
@@ -1268,13 +1208,13 @@
 <td><a href="docprocessing.html#add-space">ADD_SPACE</a></td><td>-- add space 
to the top of a page</td>
 </tr>
 <tr>
-<td><a href="docelement.html#blank-page">BLANKPAGE</a></td><td>-- output one 
or more blank pages</td>
+<td><a href="headfootpage.html#blank-pages">BLANKPAGE</a></td><td>-- output 
one or more blank pages</td>
 </tr>
 <tr>
-<td><a 
href="docprocessing.html#doc-lead-adjust">DOC_LEAD_ADJUST</a></td><td>-- adjust 
document linespacing (lead) to fill pages</td>
+<td><a 
href="docprocessing.html#doc-lead-adjust">DOC_LEAD_ADJUST</a></td><td>-- adjust 
leading to fill pages</td>
 </tr>
 <tr>
-<td><a href="rectoverso.html#collate">COLLATE</a></td><td>-- join documents or 
chapters of a document together</td>
+<td><a href="rectoverso.html#collate">COLLATE</a></td><td>-- join documents 
(chapters/sections) together</td>
 </tr>
 <tr>
 <td><a href="docprocessing.html#shim">SHIM</a></td><td>-- move vertical 
position to next valid baseline</td>

Index: momdoc/rectoverso.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/rectoverso.html,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -b -r1.15 -r1.16
--- momdoc/rectoverso.html      22 Feb 2011 19:42:30 -0000      1.15
+++ momdoc/rectoverso.html      31 Aug 2012 22:49:59 -0000      1.16
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -39,7 +41,7 @@
 
 <h1 class="docs">Recto/verso printing, collating</h1>
 
-<div style="width: 37%; margin: auto;">
+<div style="width: 40%; margin: auto;">
 <ul class="no-enumerator" style="margin-left: -1em;">
   <li><a href="#rectoverso-intro">Introduction to recto/verso printing</a>
   <ul style="margin-left: -.5em; list-style-type: disc;">
@@ -85,22 +87,7 @@
   </li>
   <li>switching the page number position (if page numbers are not centred)</li>
 </ul>
-
-<p>
-It is beyond the scope of this documentation to cover the different
-ways in which you can make your printer print on both sides of
-a sheet.  A simple but effective method for those of us with
-&#8220;dumb&#8221; printers is to open the document (after
-it&#8217;s been processed into PostScript by groff&mdash;see
-<a href="using.html#using-invoking">How to invoke groff with mom</a>)
-in <b>gv</b> (ghostview), click the &#8220;odd pages&#8221; icon,
-then click &#8220;Print Marked&#8220;.  After printing is complete,
-rearrange the sheets appropriately, put them back in your printer,
-and have <b>gv</b> print the &#8220;even pages&#8220;.  If you
-prefer to work from the command line, check out the man pages for
-<kbd>pstops</kbd> and <kbd>psbook</kbd>.  There are other programs
-out there as well to help with two-sided printing.
-</p>
+<br/>
 
 <div class="macro-list-container">
 <h3 id="rectoverso-list" class="macro-list">Recto/verso macros</h3>
@@ -174,7 +161,7 @@
 SWITCH_HEADERS can also be useful in conjunction with
 <a href="#recto-verso">RECTO_VERSO</a>.
 The assumption of RECTO_VERSO is that the first page of a document
-(i.e. recto/odd) represents the norm for header-left and header-right,
+(ie recto/odd) represents the norm for header-left and header-right,
 meaning that the second (and all subsequent verso/even) pages of the
 document will reverse the order of header-left and header-right.
 </p>
@@ -211,21 +198,21 @@
 (most likely with the <kbd>cat</kbd> command), put <kbd>.COLLATE</kbd> at the 
end of each
 concatenated chapter, follow it with the
 <a href="docprocessing.html#reference-macros">reference macros</a>
-needed for the new chapter, e.g.
+(metadata) needed for the new chapter, eg
 <a href="docprocessing.html#chapter">CHAPTER</a>
 or
 <a href="docprocessing.html#chapter-string">CHAPTER_STRING</a>,
 make any pertinent style changes to the upcoming chapter (unlikely,
 but possible), and re-invoke the
 <a href="docprocessing.html#start">START</a>
-macro.  (Most likely, the reference macros and <kbd>.START</kbd> are
+macro.  (Most likely, the metadata and <kbd>.START</kbd> are
 already there.)  Each chapter will begin on a fresh page and behave
 as expected.
 </p>
 
 <p>
 Even if you always work with monolithic, multi-chapter files, every
-chapter and its associated reference macros plus <kbd>.START</kbd>
+chapter and its associated metadata plus <kbd>.START</kbd>
 still needs to be preceded by a <kbd>.COLLATE</kbd> command.
 </p>
 
@@ -244,9 +231,9 @@
 <p id="caution" class="tip">
 <b>Two words of caution:</b>
 </p>
-<ol style="margin-top: -1.25em; margin-left: -1.25em; padding-bottom: .5em;">
+<ol style="margin-top: -1.25em; padding-bottom: .5em;">
   <li>Do not collate documents of differing
-      PRINTSTYLES (i.e. don&#8217;t try to
+      PRINTSTYLES (ie don&#8217;t try to
       collate a <kbd>TYPESET</kbd> document and <kbd>TYPEWRITE</kbd>
       document).
   </li>

Index: momdoc/refer.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/refer.html,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -b -r1.13 -r1.14
--- momdoc/refer.html   22 Feb 2011 19:42:30 -0000      1.13
+++ momdoc/refer.html   31 Aug 2012 22:49:59 -0000      1.14
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -166,7 +168,7 @@
 themselves are composed of single lines (&#8220;fields&#8221;) with
 no blank lines between them.  Each field begins with a percent
 sign and a single letter (the &quot;field identifier&quot;)
-e.g. <kbd>%A</kbd> or <kbd>%T</kbd>.  The letter identifies
+eg <kbd>%A</kbd> or <kbd>%T</kbd>.  The letter identifies
 what part of a bibliographic entry the field refers to: Author,
 Title, Publisher, Date, etc.  After the field identifier comes
 a single space, followed by the information appropriate to
@@ -243,7 +245,7 @@
 </div>
 <p style="margin-top: .5em; font-size: 95%; line-height: 120%;">
 <kbd>&lt;full&nbsp;path&nbsp;to&nbsp;the&nbsp;database&gt;</kbd>
-means the full path including the filename, e.g.
+means the full path including the filename, eg
 <kbd>/home/user/refer/my-database-file</kbd>.
 </p>
 
@@ -272,7 +274,7 @@
 
 <p style="margin-top: .5em; font-size: 95%; line-height: 120%;">
 <kbd>&lt;full&nbsp;path&nbsp;to&nbsp;the&nbsp;database&gt;</kbd>
-means the full path including the filename, e.g.
+means the full path including the filename, eg
 <kbd>/home/user/refer/my-database</kbd>.
 </p>
 
@@ -644,7 +646,7 @@
     newspaper
 %J journal          &ndash; when %T contains the title of an article
 %e edition          &ndash; number or name of an edition
-                      (e.g. Second, 2nd, Collector's, etc.)
+                      (eg Second, 2nd, Collector's, etc.)
 %S series           &ndash; series name of books or journals
 %V volume           &ndash; volume number (of books)
 %N journal number   &ndash; journal or magazine number
@@ -786,7 +788,7 @@
 
 <p>
 Use this only if the author and the editor are not one in the same,
-e.g.
+eg
 <br/>
 <span class="pre-in-pp">
   %A Geoffrey Chaucer
@@ -1065,7 +1067,7 @@
 </p>
 
 <p>
-When FOOTNOTE_REFS is in effect, regular footnotes, (i.e.
+When FOOTNOTE_REFS is in effect, regular footnotes, (ie
 those introduced with <kbd>.FOOTNOTE</kbd> and terminated with
 <kbd>.FOOTNOTE OFF</kbd>) continue to behave normally.
 </p>
@@ -1079,7 +1081,7 @@
 <p>
 By default, FOOTNOTE_REFS sets the
 <a href="docelement.html#footnote-marker-style">FOOTNOTE_MARKER_STYLE</a>
-to <kbd>NUMBER</kbd> (i.e. superscript numbers).  You may change
+to <kbd>NUMBER</kbd> (ie superscript numbers).  You may change
 change that if you wish by invoking FOOTNOTE_MARKER_STYLE, with the
 argument you want after FOOTNOTE_REFS.
 </p>
@@ -1111,7 +1113,7 @@
 
 <p>
 When ENDNOTE_REFS is in effect, mom continues to format regular
-endnotes, (i.e. those introduced with <kbd>.ENDNOTE</kbd> and
+endnotes, (ie those introduced with <kbd>.ENDNOTE</kbd> and
 terminated with <kbd>.ENDNOTE OFF</kbd>) in the normal way.
 </p>
 
@@ -1403,7 +1405,7 @@
 and <kbd>&lt;list&nbsp;prefix&gt;</kbd> have the same meaning as the
 equivalent arguments to
 <a href="docelement.html#list">LIST</a>
-(i.e. <kbd>&lt;separator&gt;</kbd> and <kbd>&lt;prefix&gt;</kbd>).
+(ie <kbd>&lt;separator&gt;</kbd> and <kbd>&lt;prefix&gt;</kbd>).
 </p>
 
 <p>
@@ -1968,7 +1970,7 @@
 underneath the bibliography&#8217;s first-page title.  Invoked with the
 argument, <kbd>DOUBLE</kbd>, BIBLIOGRAPHY_STRING_UNDERSCORE will
 double-underscore the thtile.  Invoked with any other non-numeric
-argument, (e.g. <kbd>OFF, NO, X</kbd>, etc.) the macro disables
+argument, (eg <kbd>OFF, NO, X</kbd>, etc.) the macro disables
 underlining of the title.
 </p>
 

Index: momdoc/reserved.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/reserved.html,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -b -r1.42 -r1.43
--- momdoc/reserved.html        8 Sep 2011 18:30:43 -0000       1.42
+++ momdoc/reserved.html        31 Aug 2012 22:49:59 -0000      1.43
@@ -1,19 +1,21 @@
 <?xml version="1.0" encoding="utf-8"?>
 <!--
-  This file is part of groff, the GNU roff type-setting system.
+This file is part of groff, the GNU roff type-setting system.
 
-  Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, 
Inc.
-  Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
+
+Permission is granted to copy, distribute and/or modify this document
+under the terms of the GNU Free Documentation License, Version 1.3 or
+any later version published by the Free Software Foundation; with the
+Invariant Sections being this comment section, with no Front-Cover
+Texts, and with no Back-Cover Texts.
 
-  Permission is granted to copy, distribute and/or modify this document
-  under the terms of the GNU Free Documentation License, Version 1.3 or
-  any later version published by the Free Software Foundation; with the
-  Invariant Sections being this comment section, with no Front-Cover
-  Texts, and with no Back-Cover Texts.
-
-  A copy of the Free Documentation License is included as a file called
-  FDL in the main directory of the groff source package.
+A copy of the Free Documentation License is included as a file called
+FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -840,6 +842,7 @@
   HEAD_UNDERLINE           Underline section titles? (boolean)
   NUMBER_HEADS             Print head numbers
   RESET_HEAD_NUMBER        Reset head number
+  HEAD_BASELINE_ADJUST     Amount to raise head above baseline
 
 -Subheads-
   NUMBER_SUBHEADS          Print subhead numbers
@@ -1026,7 +1029,7 @@
 <span style="display: block; margin-top: -.5em; margin-bottom: 
-2.5em;">+++DIVERSIONS+++</span>
 
   B_QUOTE           Block (indented) quote text
-  CLOSING           Closing (i.e. Yours truly,)
+  CLOSING_TEXT      Closing (i.e. Yours truly,)
   EPI_TEXT          Epigraph text
   END_NOTES         Endnotes text
   FN_IN_DIVER       Footnotes gathered from inside a diversion
@@ -1442,6 +1445,7 @@
                                where the footnote is to be deferred to
                                the next page or column
   #GUTTER                    Width of gutter between columns
+  #H_BASELINE_ADJ            Vertical spacing adjustment for heads (default=0)
   #HDRFTR_BOTH               Are we setting both headers and footers? (boolean)
   #HDRFTR_CENTER_CAPS        CENTER part of header/footer in caps?
                                (boolean; default=off)
@@ -1712,8 +1716,6 @@
   #RESTORE_LN_NUM            Should we restore line numbering? (boolean)
   #RESTORE_OFFSET            Page offset at moment footer trap is sprung;
                                not currently used
-  #RESTORE_TOC_PN_PADDING    Saves #TOC_PN_PADDING in TOC prior to
-                               processing $FIRST_DOC_TITLE
   #RESTORE_UNDERLINE         Instructs CODE OFF to restore underlining of
                                 italics (TYPEWRITE) if underlining was
                                 formerly on 
@@ -1779,6 +1781,8 @@
   #SILENT_BQUOTE_LN          "Silently" linenumber blockquotes? (boolean)
   #SILENT_QUOTE_LN           "Silently" linenumber quotes? (boolean)
   #SINGLE_SPACE              Is TYPEWRITE in single space mode? (boolean)
+  #SKIP ENTRY                If one, don't print the first entry (the
+                               document title) in the TOC of uncollated docs.
   #SKIP_FOOTER               If 1, instructs DO_FOOTER to do nothing
                                if B_MARGIN falls below FOOTER_MARGIN
   #SLANT_MEANS_SLANT         For TYPEWRITE. (boolean)
@@ -2153,7 +2157,6 @@
   $FINIS_COLOR                     Color of FINIS string
   $FINIS_STRING                    What to print when FINIS macro is
                                      invoked
-  $FIRST_DOC_TITLE                 1st doc's title captured in COLLATE
     FN_MARK                          Inline, gets #FN_MARK ( \n[ln] )
   $FN_CLOSE_BRACKET                Close bracket for line-number identified
                                      footnotes
@@ -2401,14 +2404,14 @@
   CITE                              BLOCKQUOTE
   COL_BREAK                         COL_NEXT
   DOC_FAM                           DOC_FAMILY
-  DOC_LLENGTH                       DOC_LINE_LENGTH
   DOC_L_LENGTH                      DOC_LINE_LENGTH
+  DOC_L_LENGTH                      DOC_LINE_LENGTH
+  DOC_L_MARGIN                      DOC_LEFT_MARGIN
   DOC_L_MARGIN                      DOC_LEFT_MARGIN
-  DOC_LMARGIN                       DOC_LEFT_MARGIN
   DOC_LS                            DOC_LEAD
   DOC_PS                            DOC_PT_SIZE
   DOC_R_MARGIN                      DOC_RIGHT_MARGIN
-  DOC_RMARGIN                       DOC_RIGHT_MARGIN
+  DOC_R_MARGIN                      DOC_RIGHT_MARGIN
   ENDNOTE_STRING_UNDERSCORE         ENDNOTE_STRING_UNDERLINE
   ENDNOTE_TITLE_UNDERSCORE          ENDNOTE_TITLE_UNDERLINE
   FOOTER_CENTER_CAPS                HDRFTR_CENTER_CAPS

Index: momdoc/stylesheet.css
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/stylesheet.css,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- momdoc/stylesheet.css       3 Oct 2010 23:26:29 -0000       1.3
+++ momdoc/stylesheet.css       31 Aug 2012 22:49:59 -0000      1.4
@@ -33,7 +33,7 @@
 h1.docs
 {
   font-family: arial,sans-serif ;
-  font-size: 175% ;
+  font-size: 125% ;
   text-align: center ;
   color: #002b56 ;
   background-color: #e2f1ff ;
@@ -43,7 +43,7 @@
 h2.docs
 {
   margin-bottom: -.25em ;
-  font-size: 120% ;
+  font-size: 105% ;
   color: #000056 ;
 }
 h2.macro-group /* ie "Page setup" or "Indents" or "Multi-columns" */
@@ -92,6 +92,7 @@
 }
 h4.docs
 {
+  font-size: 95% ;
   margin-bottom: -.5em ;
   color: #000056 ;
 }
@@ -282,7 +283,7 @@
   margin-bottom: -1.5em ;
   font-family: "Lucida Console",monospace ;
   font-weight: bolder ;
-  font-size: 100% ;
+  font-size: 95% ;
   white-space: pre ;
   overflow: auto ;
 }
@@ -300,7 +301,7 @@
   margin-bottom: -.5em ;
   font-family: "Lucida Console",monospace ;
   font-weight: bolder ;
-  font-size: 100% ;
+  font-size: 95% ;
   white-space: pre ;
   overflow: auto ;
 }
@@ -509,6 +510,7 @@
 {
   margin-top: .25em ;
   margin-left: 6px ;
+  margin-right: 12px ;
   margin-bottom: 0 ;
 }
 #toc-title, #toc-head, #toc-subhead, #toc-parahead
@@ -532,7 +534,7 @@
 {
   font-family: "Lucida Console",monospace ;
   font-weight: bold ;
-  font-size: 100% ;
+  font-size: 95% ;
 }
 kbd.macro-args
 {
@@ -646,8 +648,17 @@
   font-weight: bold ;
   text-align: left ;
 }
+
 td
 {
   padding: 0 ;
   padding-left: .5em ;
 }
+
+/* Misc */
+
+span.book-title
+{
+  font-style: italic ;
+}
+

Index: momdoc/tables-of-contents.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/tables-of-contents.html,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- momdoc/tables-of-contents.html      22 Feb 2011 19:42:30 -0000      1.3
+++ momdoc/tables-of-contents.html      31 Aug 2012 22:49:59 -0000      1.4
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -42,14 +44,17 @@
 <div style="width: 68%; margin: auto;">
 <ul class="no-enumerator">
   <li><a href="#toc-intro">Introduction to tables of contents</a>
+  <li><a href="#toc-appearance">Tables of contents appearance and 
behaviour</a></li>
+  <li><a href="#pdf-output">PDF output</a>
   <ul style="margin-left: -.5em; list-style-type: disc;">
-    <li><a href="#toc-behaviour">Tables of contents behaviour</a></li>
-    <li><a href="#psselect">Using <kbd>psselect</kbd> to put the table of 
contents where you want it</a></li>
+    <li><a href="#positioning">Positioning the table of contents</a>
+    <li><a href="#auto-relocate-toc">AUTO_RELOCATE_TOC</a></li>
+    <li><a href="#psselect"><kbd>psselect</kbd></a></li>
   </ul></li>
-  <li><a href="#toc">Instruct mom to output a table of contents</a></li>
+  <li><a href="#toc">The TOC macro</a></li>
   <li><a href="#toc-control-top">Control macros for tables of contents</a>
   <ul style="margin-left: -.5em; list-style-type: disc;">
-    <li><a href="#index-toc-control">Table of contents control macros and 
defaults</a></li>
+    <li><a href="#index-toc-control">Table of contents control macros</a></li>
   </ul></li>
 </ul>
 </div>
@@ -67,21 +72,19 @@
 as the very last macro of your document file. Mom will have picked
 up all document titles (in
 <a href="rectoverso.html#collate">collated</a>
-documents), all heads, subheads, and paragraph heads, as well as
-any endnotes pages that have been output, and assigned them the
-appropriate page number (and page numbering style).  Talk about a
-no-brainer!
+documents) and headings, as well as the endnotes section and
+bibliography, if they exist, and assigned them the appropriate page
+number.  Talk about a no-brainer!
 </p>
 
 <p>
 That said, tables of contents have even more control macros than
 endnotes.  As always, the reason for so many control macros is so
 that if you want to change just about any aspect of the table of
-contents&#8217; typographic appearance, you can.  Mom is all about
-simplicity <i>and</i> flexibility.
+contents&#8217; typographic appearance, you can.
 </p>
 
-<h3 id="toc-behaviour" class="docs">Tables of contents behaviour</h3>
+<h2 id="toc-appearance" class="docs">Tables of contents appearance and 
behaviour</h2>
 
 <p>
 When you output a table of contents (with
@@ -108,14 +111,11 @@
 </p>
 
 <p>
-Entries in a table of contents are hierarchically indented, as
-you would expect.  By default, each type of entry (e.g. a head
-or a subhead) is set in a different font as well.  If any of
-heads, subheads or paragraph heads are numbered in the body of the
-document, they are also numbered in the table of contents.  Head,
-subhead and paragraph head numbering in the table of contents is
-<i>not</i> concatenated, as it is in the body of the document,
-because it's visually redundant in a table of contents.
+Entries in a table of contents are hierarchically indented, as you
+would expect, and if headings are numbered in the body of the document,
+you can instruct mom to number them in the table of contents as
+well (see
+<a href="#toc-entry-numbers">TOC_ENTRY_NUMBERS</a>).
 </p>
 
 <p>
@@ -140,40 +140,90 @@
 <a href="definitions.html#controlmacro">control macros</a>,
 as can the family,
 <a href="definitions.html#font">font</a>,
-point size and indent of each type of entry (i.e. title, head,
-subhead, paragraph head).  Furthermore, the page numbering style
-can be changed, as can the amount of visual space reserved for page
-reference numbers.
+point size and indent of each level of entry.  Furthermore, the page
+numbering style can be changed, as can the amount of visual space
+reserved for entry page numbers.
 </p>
 
-<h5 id="psselect" class="docs">Using <kbd>psselect</kbd> to put the table of 
contents where you want it</h5>
+<h2 id="pdf-output" class="docs">PDF output</h2>
 
 <p>
-Mom always outputs the table of contents at the end of a document.
-While this is desirable for some language conventions&mdash;French,
-for example&mdash;it is not desirable for others.
+When files containing a table of contents are processed with
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>,
+entries in the table of contents are clickable links when the
+document is viewed at the screen.  The colour of the links is the
+last <kbd>.PDF_LINK_COLOR</kbd> in effect, so if you wish another
+colour, it should be set just before issuing <kbd>.TOC</kbd>.
 </p>
 
 <p>
-If you&#8217;d like your tables of contents near the start of
-your document, you have two options: re-arrange the pages by hand
-(okay for one or two hard copies of the document), or use the
-<kbd>psselect</kbd> programme provided by the <b>psutils</b> suite
-of tools (which you may have to install as a package from your
-distribution if it is not already on your system).
+When preparing files for printing, coloured links in both the table
+of contents and elsewhere in the document may not be desirable.
+You can disable the colour by passing
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>
+the <kbd>-c</kbd> option, like this: <br/>
+<span class="pre-in-pp">
+   pdfmom -c doc.mom &gt; doc.pdf
+</span>
 </p>
 
+<h3 id="positioning" class="docs">Positioning the Table of Contents</h3>
+
 <p>
-The procedure for using <kbd>psselect</kbd> to put the table of
-contents near the beginning of the document begins by you
-determining how many pages it contains.  You can
-do this by previewing the document with the PostScript viewer of
-your choice (gv, okular, evince, etc).
+Because a table of contents can&#8217;t be generated until the
+end of a document (hence the last macro in the file), it is also
+the last page of the document.  While this is desirable for some
+language conventions&mdash;French, for example&mdash;it is not
+desirable for others.
+</p>
+
+<h4 id="auto-relocate-toc" class="docs">Automatic PDF relocation of the Table 
of Contents</h4>
+
+<p>
+When
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>
+is used to process files with a table of contents, the macro,
+<kbd>.AUTO_RELOCATE_TOC</kbd>, can be used to reposition the table
+of contents to the top of the output document, with the presence
+of a cover and/or title page sensibly taken into account.  Full
+AUTO_RELOCATE_TOC usage is described in the manual,
+<a href="http://www.schaffter.ca/mom/pdf/mom-pdf.pdf";><span 
class="book-title">Producing PDFs with groff and mom</span></a>.
+</p>
+
+<p>
+In order to take advantage of automatic table of contents
+repositioning, you must use
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>.
+with groff&#8217;s native PDF driver (ie without the
+<strong>-Tps</strong> flag).  Files that need to be processed with
+the <strong>-Tps</strong> flag require you to reposition the table
+of contents yourself with <strong>psselect</strong>, described
+below.
+</p>
+
+<h4 id="psselect" class="docs"><span style="text-transform: none">Using 
psselect to relocate the Table of Contents in PostScript documents</span></h4>
+
+<p>
+To change the location of the table of contents in files
+processed with <kbd>pdfmom -Tps</kbd>, you have two choices:
+rearrange the pages by hand (okay for one or two hard copies),
+or use the <strong>psselect</strong> programme provided by the
+<strong>psutils</strong> suite of tools (which you may have to
+install as a package from your distribution if it is not already on
+your system).
+</p>
+
+<p>
+The procedure for using <strong>psselect</strong> to put the
+table of contents near the beginning of a document begins by
+you determining how many pages it contains.  You can do this by
+previewing the document with the document viewer of your choice
+(gv, Okular, Evince, etc).
 </p>
 
 <p>
 Once you know the number of pages in the table of contents, you use
-<kbd>psselect</kbd> to place them where you want.
+<strong>psselect</strong> to place them where you want.
 </p>
 
 <p>
@@ -186,11 +236,11 @@
 </span>
 The <kbd>-p</kbd> option instructs <kbd>psselect</kbd> that what
 follows is a comma-separated list of the order in which you want
-pages of a document re-arranged.  The underscore character means
+pages of a document rearranged.  The underscore character means
 "counting backwards from the end of the document".  Thus, the above
-says: "Put the last page first (i.e. the table of contents), followed
+says: "Put the last page first (ie the table of contents), followed
 by all pages from the original first page up to the second to last
-(i.e. the last page before the table of contents)."
+(ie the last page before the table of contents)."
 </p>
 
 <p>
@@ -214,17 +264,16 @@
 <kbd>psselect</kbd> outputs to stdout, so you have to redirect the
 output to a new file.
 <br/>
-<span class="pre-in-pp">
+<span class="pre-in-pp" style="margin-bottom: -1em">
   psselect -p &lt;page list&gt; &lt;file&gt;.ps &gt; &lt;new-file&gt;.ps
 </span>
 </p>
 </div>
 
-
 <!-- -TOC- -->
 
 <div class="macro-id-overline">
-<h3 id="toc" class="macro-id">Instruct mom to output a table of contents</h3>
+<h3 id="toc" class="macro-id">The TOC macro</h3>
 </div>
 
 <div class="box-macro-args">
@@ -240,22 +289,15 @@
 
 <h2 id="toc-control-top" class="macro-group">Control macros for tables of 
contents</h2>
 
-<div class="box-tip">
-<p class="tip-top">
-<span class="note">ERRATUM:</span> In versions of mom prior to
-1.3-e_3, the documentation incorrectly stated that table of contents
-control macros could go anywhere in a mom file prior to invoking
-<kbd>.TOC</kbd>.
-</p>
-
-<p class="tip-bottom">
-In fact, table of contents control macros must come before
-<kbd><a href="docprocessing.html#start">.START</a></kbd>.
+<p>
+Aside from allowing you to set the style of table of contents
+entries on a per-level basis, the control macros let you design
+the table of contents as if they were a complete document unto
+themselves (overall family, headers/footers, pagination, etc).
 </p>
-</div>
 
 <div class="defaults-container" style="background-color: #ded4bd; border: 
none;">
-<h3 id="index-toc-control" class="docs defaults">Table of contents control 
macros and defaults</h3>
+<h3 id="index-toc-control" class="docs defaults">Table of contents control 
macros</h3>
 
 <ol style="margin-top: .5em; padding-bottom: .5em;">
   <li><a href="#toc-general">General table of contents style control</a>
@@ -264,31 +306,30 @@
     <li><a href="#toc-pt-size">TOC_PT_SIZE</a> &ndash; base point size for 
tables of contents</li>
     <li><a href="#toc-lead">TOC_LEAD</a> &ndash; leading of tables of 
contents</li>
   </ul></li>
-  <li><a href="#toc-pagenumbering">Table of contents page numbering</a>
+  <li><a href="#toc-pagenumbering">Page numbering</a>
   <ul style="margin-left: -.5em;">
     <li><a href="#paginate-toc">PAGINATE_TOC</a> &ndash; turn table of 
contents pagination on or off</li>
     <li><a href="#toc-pagenum-style">TOC_PAGENUM_STYLE</a> &ndash; table of 
contents page numbering style</li>
   </ul></li>
-  <li><a href="#toc-header">Changing the table of contents header (title), 
string and style</a>
+  <li><a href="#toc-header">Header string (eg &#8220;Contents&#8221;) and 
style</a>
   <ul style="margin-left: -.5em;">
-    <li><a href="#toc-header-string">Changing the header (title) string</a>
+    <li><a href="#toc-header-string">Changing the header string</a>
     <ul style="margin-left: -.5em;">
-      <li><a href="#toc-header-style">Table of contents header (title) string 
control macros and defaults</a></li>
+      <li><a href="#toc-header-style">Header string control macros and 
defaults</a></li>
     </ul></li>
   </ul></li>
-  <li><a href="#toc-style">Changing the style of table of contents entries and 
page number references</a>
+  <li><a href="#toc-style">Entries and reference page number style</a>
   <ul style="margin-left: -.5em;">
-    <li><a href="#toc-indent-note">Note: the table of contents _INDENT control 
macros</a></li>
-    <li><a href="#toc-title">Changing the style of table of contents title 
entries</a></li>
-    <li><a href="#toc-head">Changing the style of table of contents head 
entries</a></li>
-    <li><a href="#toc-subhead">Changing the style of table of contents subhead 
entries</a></li>
-    <li><a href="#toc-parahead">Changing the style of table of contents 
paragraph head entries</a></li>
-    <li><a href="#toc-pn">Changing the style of table of contents page number 
references</a></li>
+    <li><a href="#toc-pn">Reference page numbers style control</a></li>
+    <li><a href="#toc-title-style">Title entry style control</a></li>
+    <li><a href="#toc-entry-style">Heading entry style control</a></li>
+    <li><a href="#toc-entry-numbers">Controlling the numbering of 
entries</a></li>
   </ul></li>
   <li><a href="#toc-additional">Additional table of contents control macros</a>
   <ul style="margin-left: -.5em;">
     <li><a href="#toc-appends-author">Append author(s) to table of contents 
title entries</a></li>
     <li><a href="#toc-title-entry">Alter the wording of a table of contents 
title entry</a></li>
+    <li><a href="#space-toc-items">Space table of contents entries 
pleasingly</a></li>
     <li><a href="#toc-padding">Establish the number of placeholders to leave 
for page reference numbers</a></li>
     <li><a href="#toc-rv-switch">Switch tables of contents page 
margins</a></li>
   </ul></li>
@@ -297,6 +338,8 @@
 
 <h4 id="toc-general" class="docs" style="margin-top: -1.5em; margin-bottom: 
.5em;">1. General tables of contents style control</h4>
 
+<!-- -TOC_FAMILY- -->
+
 <div id="toc-family" class="box-macro-args">
 Macro: <b>TOC_FAMILY</b> <kbd class="macro-args">&lt;family&gt;</kbd>
 </div>
@@ -304,7 +347,7 @@
 <p>
 TOC_FAMILY establishes the default family for every page element in
 a table of contents, including the table of contents&#8217; header
-(title) string (by default, &#8220;Contents&#8221;) and the page
+string (by default, &#8220;Contents&#8221;) and the page
 number in the top or bottom margin.  The default is the prevailing
 document family.
 </p>
@@ -342,6 +385,8 @@
 document).
 </p>
 
+<!-- -TOC_LEAD- -->
+
 <div id="toc-lead" class="box-macro-args">
 Macro: <b>TOC_LEAD</b> <kbd class="macro-args">&lt;leading of the toc&gt; [ 
ADJUST ]</kbd>
 </div>
@@ -388,7 +433,7 @@
 <div class="box-tip">
 <p class="tip">
 <span class="note">Note:</span>
-Even if you give mom a <kbd>.DOC_LEAD_ADJUST&nbsp;.OFF</kbd> command,
+Even if you give mom a <kbd>.DOC_LEAD_ADJUST&nbsp;OFF</kbd> command,
 she will still, by default, adjust the leading of the table of
 contents.  You <i>must</i> enter
 <kbd>TOC_LEAD&nbsp;&lt;lead&gt;</kbd> with no <kbd>ADJUST</kbd>
@@ -403,7 +448,7 @@
 </p>
 </div>
 
-<h4 id="toc-pagenumbering" class="docs">2. Table of contents page 
numbering</h4>
+<h4 id="toc-pagenumbering" class="docs">2. Page numbering</h4>
 
 <p>
 The pagination style of tables of contents is controlled by the same
@@ -426,7 +471,7 @@
 <p>
 A special macro,
 <kbd><a href="#toc-pagenum-style">TOC_PAGENUM_STYLE</a></kbd>
-controls the style of table of contents pagination (i.e. the actual
+controls the style of table of contents pagination (ie the actual
 table of contents pages' numbers, not the page number references of
 entries).
 </p>
@@ -484,7 +529,7 @@
 </span>
 </p>
 
-<h4 id="toc-header" class="docs" style="margin-top: -.5em;">3. Changing the 
table of contents header (title) string and style</h4>
+<h4 id="toc-header" class="docs" style="margin-top: -.5em;">3. Header string 
and style</h4>
 
 <p>
 The table of contents header string is the title that appears at to top of the
@@ -504,7 +549,7 @@
 </span>
 </p>
 
-<h5 id="toc-header-style" class="docs" style="margin-top: -.5em; 
text-transform: none;">Table of contents header string (title) control macros 
and defaults</h5>
+<h5 id="toc-header-style" class="docs" style="margin-top: -.5em; 
text-transform: none;">Header string control macros and defaults</h5>
 
 <div class="defaults-container" style="margin-top: 1em; padding-bottom: 8px;">
 <p class="defaults" style="padding-top: 6px;">
@@ -519,99 +564,258 @@
 </span>
 </div>
 
-<h4 id="toc-style" class="docs" style="margin-top: -1em;">4. Changing the 
style of table of contents entries and page number references</h4>
+<h4 id="toc-style" class="docs" style="margin-top: -1em;">4. Entries and 
reference page numbers style</h4>
 
 <p>
-&#8220;Entries&#8221; refers to titles in
+&#8220;Entries&#8221; refers to the hierarchical arrangement of
+section titles (in
 <a href="rectoverso.html#collate-intro">collated</a>
-documents
-(<a href="docprocessing.html#title">TITLE</a>)
-, heads
-(<a href="docelement.html#head">HEAD</a>),
-subheads
-(<a href="docelement.html#subhead">SUBHEAD</a>),
-and paragraph heads
-(<a href="docelement.html#parahead">PARAHEAD</a>)
-as they appear in the table of contents.  Their style is managed by
-the usual
-<a href="definitions.html#controlmacro">control macros</a>,
-which take the form <kbd>TOC_&lt;ELEMENT&gt;_&lt;SPEC&gt;</kbd>
-(e.g. <kbd>TOC_HEAD_FAMILY</kbd> or <kbd>TOC_SUBHEAD_INDENT</kbd>).
+documents) and headings as they appear in the table of contents:
+<span class="pre-in-pp">
+  Section title
+    Head level 1
+      Head level 2
+        Head level 3
+          ...
+</span>
+The style for title entries (eg chapter numbers or titles) and
+heading levels is controlled by
+<a href="#toc-title-style">TOC_TITLE_STYLE </a>
+and
+<a href="#toc-entry-style">TOC_ENTRY_STYLE</a>
+respectively.
+</p>
+
+<p id="toc-pn">
+&#8220;Reference page numbers&#8221; means the page numbers
+associated with entries.  Macros to control their style take the
+form <kbd>.TOC_PN_&lt;SPEC&gt;</kbd>, and the defaults are listed
+here.
 </p>
 
+<div class="defaults-container" style="margin-top: 1em; padding-bottom: 8px;">
+<p class="defaults" style="padding-top: 6px;">
+See
+<a href="docelement.html#control-macro-args">Arguments to the control 
macros</a>.
+</p>
+
+<span class="pre defaults">
+.TOC_PN_FAMILY  default = prevailing doc family 
+.TOC_PN_FONT    default = roman
+.TOC_PN_SIZE    default = 0
+</span>
+</div>
+</p>
+
+<!-- -TOC_TITLE_STYLE- -->
+
+<div id="toc-title-style" class="box-macro-args">
+Macro: <b>TOC_TITLE_STYLE</b> <kbd class="macro-args">&lt;see below for 
args&gt;</kbd>
+</div>
+
 <p>
-&#8220;Page number references&#8221; means the page numbers associated with
-entries.  They take the form <kbd>TOC_PN_&lt;SPEC&gt;</kbd>.
+TOC_TITLE_STYLE allows you to set all the style parameters for
+title entries in the tables of contents with one macro.  The
+number of arguments can run long, so you may want to break them into
+several lines with the backslash character (<kbd>\</kbd>).  The
+arguments are:
+<br/>
+<span class="pre-in-pp">
+  FAMILY &lt;family&gt;
+  FONT &lt;font&gt;
+  SIZE +|-&lt;n&gt;
+  COLOR &lt;color&gt;
+  INDENT &lt;amount&gt;
+  CAPS | NO_CAPS
+</span>
+The arguments may be entered in any order.
 </p>
 
 <p>
-The following is a list of the control macros for table of contents
-entries, along with their defaults.
+The family, font, size, and color arguments behave identically
+to the individual control macros that govern other tags, therefore see
+<a href="docelement.html#control-macro-args">Arguments to the control 
macros</a>
+for usage.  Their defaults are the same as for paragraphs in
+<a href="definitions.html#running">running text</a>.
 </p>
 
-<div id="toc-indent-note" class="box-tip">
-<p class="tip">
-<span class="note">Note:</span>
-The table of contents _INDENT macros set an absolute indent,
-relative to nothing, and therefore require an appended
+<p>
+<kbd>INDENT</kbd> lets you indent title entries by the amount specified, and
+requires a
+<a href="definitions.html#unitofmeasure">unit of measure</a>.
+The default is zero.
+</p>
+
+<p>
+<kbd>CAPS</kbd> instructs mom to capitalize title entries.
+Capitalization may be enabled or disabled on a per-title basis.
+</p>
+
+<p>
+As an example, if you want title entries bold, slightly larger than other
+entries and capitalized, you could do either
+<br/>
+<span class="pre-in-pp">
+  .TOC_TITLE_ENTRY FONT B SIZE +.5 CAPS
+</span>
+or
+<br/>
+<span class="pre-in-pp">
+  .TOC_TITLE_ENTRY \
+   FONT B \
+   SIZE +.5 \
+   CAPS
+</span>
+</p>
+
+<!-- -TOC_ENTRY_STYLE- -->
+
+<div id="toc-entry-style" class="box-macro-args">
+Macro: <b>TOC_ENTRY_STYLE</b> <kbd class="macro-args">&lt;level&gt; &lt;see 
below for remaining args&gt;</kbd>
+</div>
+
+<p>
+TOC_ENTRY_STYLE allows you to set individually all the style
+parameters for any level of entry (beneath titles) in the tables
+of contents.  The number of arguments can run long, so you may
+want to break them into several lines with the backslash character
+(<kbd>\</kbd>).
+</p>
+
+<p>
+<kbd>&lt;level&gt;</kbd> corresponds to a
+<a href="docelement.html#heading">HEADING</a>
+level assigned in the body of the document.  The remaining arguments
+are as follows.
+<br/>
+<span class="pre-in-pp">
+  FAMILY &lt;family&gt;
+  FONT &lt;font&gt;
+  SIZE +|-&lt;n&gt;
+  COLOR &lt;color&gt;
+  INDENT &lt;amount&gt;
+  CAPS | NO_CAPS
+</span>
+The arguments may be entered in any order.
+</p>
+
+<p>
+The family, font, size, and color arguments behave identically
+to the individual control macros that govern other tags, therefore see
+<a href="docelement.html#control-macro-args">Arguments to the control 
macros</a>
+for usage.  Their defaults are the same as for paragraphs in
+<a href="definitions.html#running">running text</a>.
+</p>
+
+<p>
+<kbd>INDENT</kbd> lets you indent entries by the amount specified, and
+requires a
 <a href="definitions.html#unitofmeasure">unit of measure</a>.
-Furthermore, the size of the indent can only be changed when your
-<a href="docprocessing.html#printstyle">PRINTSTYLE</a>
-is <kbd>TYPESET</kbd>; the indent is fixed for <kbd>TYPEWRITE</kbd>.
+Mom sensibly indents and aligns all levels of entry.  If you change
+the indent for any level, all levels beneath it are still indented
+according to mom&#8217;s normal arrangement, but with the indent
+assigned to <kbd>level</kbd> taken into account.  When you use
+<kbd>INDENT</kbd>, the indent is measured from the left margin of
+the entire text of the previous level, including numbering, if any.
+</p>
+
+<p>
+<kbd>CAPS</kbd> instructs mom to capitalize title entries.
+Capitalization may be enabled or disabled on a per-title basis.
+</p>
+
+<p>
+As an example, if you want a particular entry level to be in
+Helvetica, italics, and slightly larger than other entries, you could
+do either
+<br/>
+<span class="pre-in-pp">
+  .TOC_TITLE_ENTRY FAMILY H FONT I SIZE +.25
+</span>
+or
+<br/>
+<span class="pre-in-pp">
+  .TOC_TITLE_ENTRY \
+   FAMILY H
+   FONT I \
+   SIZE +.25
+</span>
 </p>
+
+<!-- -TOC_ENTRY_NUMBERS- -->
+
+<div id="toc-entry-numbers" class="box-macro-args">
+Macro: <b>TOC_ENTRY_NUMBERS</b> <kbd class="macro-args">&lt;FULL&gt; 
&lt;TRUNCATE&gt; &lt;NONE&gt;</kbd>
 </div>
 
-<div id="index-toc-entry-control-macros" class="defaults-container" 
style="padding-bottom: 8px;">
-<p class="defaults" style="padding-top: 6px;">
-See
-<a href="docelement.html#control-macro-args">Arguments to the control 
macros</a>.
+<p>
+If numbering is enabled for any level of
+<a href="docelement.html#heading">HEADING</a>,
+mom, by default, includes the numbering in that level&#8217;s
+entries in table of contents.  If you would prefer that
+numbering not be included in the table of contents,
+issue <kbd>.TOC_ENTRY_NUMBERS&nbsp;NONE</kbd>.  If
+you&#8217;d like to include numbering, but not the full,
+concatenated numbering used in the body of the document, issue
+<kbd>.TOC_ENTRY_NUMBERS&nbsp;TRUNCATE</kbd>.
 </p>
 
-<span class="pre defaults">
-<span id="toc-title">
-.TOC_TITLE_FAMILY  default = prevailing doc family 
-.TOC_TITLE_FONT    default = bold italic (TYPESET); roman (TYPEWRITE)
-.TOC_TITLE_SIZE    default = +1.5
-.TOC_TITLE_INDENT  default = 0
-</span>
-<span id="toc-head">
-.TOC_HEAD_FAMILY  default = prevailing doc family 
-.TOC_HEAD_FONT    default = bold (TYPESET); roman (TYPEWRITE)
-.TOC_HEAD_SIZE    default = +.5
-.TOC_HEAD_INDENT  default = 2 <a href="definitions.html#figurespace">figure 
spaces</a> + a period
-</span>
-<span id="toc-subhead">
-.TOC_SUBHEAD_FAMILY  default = prevailing doc family 
-.TOC_SUBHEAD_FONT    default = roman
-.TOC_SUBHEAD_SIZE    default = 0
-.TOC_SUBHEAD_INDENT  default = TOC_HEAD_INDENT + 2 <a 
href="definitions.html#figurespace">figure spaces</a> + a period
-</span>
-<span id="toc-subsubhead">
-.TOC_SUBSUBHEAD_FAMILY  default = prevailing doc family 
-.TOC_SUBSUBHEAD_FONT    default = italic (TYPESET); roman (TYPEWRITE)
-.TOC_SUBSUBHEAD_SIZE    default = 0
-.TOC_SUBSUBHEAD_INDENT  default = TOC_SUBHEAD_INDENT + 2 <a 
href="definitions.html#figurespace">figure spaces</a> + a period
-</span>
-<span id="toc-parahead">
-.TOC_PARAHEAD_FAMILY  default = prevailing doc family 
-.TOC_PARAHEAD_FONT    default = bold italic (TYPESET); roman (TYPEWRITE)
-.TOC_PARAHEAD_SIZE    default = 0
-.TOC_PARAHEAD_INDENT  default = TOC_SUBSUBHEAD_INDENT + 2 <a 
href="definitions.html#figurespace">figure spaces</a> + a period 
+<p>
+Assuming numbering is enabled for HEADINGs 1, 2, and 3,
+<kbd>.TOC_ENTRY_NUMBERS FULL</kbd> (mom&#8217;s default), would
+result in
+<br/>
+<span class="pre-in-pp">
+  1. Level-1 entry
+     1.1. Level-2 entry
+       1.1.1. Level-3 entry
+  2. Level-1 entry
+     2.1. Level-2 entry
+       2.1.1. Level-3 entry
 </span>
-.TOC_PN_FAMILY  default = prevailing doc family 
-.TOC_PN_FONT    default = roman
-.TOC_PN_SIZE    default = 0
+whereas <kbd>.TOC_ENTRY_NUMBERS TRUNCATE</kbd> would produce
+<br/>
+<span class="pre-in-pp">
+  1. Level-1 entry
+     1. Level-2 entry
+        1. Level-3 entry
+  2. Level-1 entry
+     1. Level-2 entry
+        1. Level-3 entry
 </span>
+and <kbd>.TOC_ENTRY_NUMBERS NONE</kbd> would remove numbering
+completely.
+<br/>
+<span class="pre-in-pp">
+  Level-1 entry
+     Level-2 entry
+        Level-3 entry
+  Level-1 entry
+     Level-2 entry
+        Level-3 entry
+</span>
+</p>
+
+<div class="box-tip">
+<p class="tip">
+<span class="note">Note:</span>
+<kbd>.TOC_ENTRY_NUMBER TRUNCATE</kbd> removes the numbering
+associated with title entries if
+<a href="docelement.html#prefix-chapter-number">PREFIX_CHAPTER_NUMBER</a>
+is enabled.
+</p>
 </div>
 
+
 <h4 id="toc-additional" class="docs" style="margin-top: -1em;">5. Additional 
table of contents control macros</h4>
 
 <p>
-The following four macros allow you to
+The following five macros allow you to
 </p>
 <ul style="margin-top: -.5em; margin-left: -.5em;">
   <li>instruct mom to <a href="#toc-appends-author">append author(s) to</a> <a 
href="docprocessing.html#title">TITLE</a> <a 
href="toc-appends-author">entries</a></li>
   <li><a href="#toc-title-entry">alter the wording of</a> <a 
href="docprocessing.html#title">TITLE</a> <a 
href="#toc-title-entry">entries</a></li>
+  <li>instruct mom to <a href="#space-toc-items">space table of contents 
entries</a> pleasingly</li>
   <li>establish <a href="#toc-padding">how many placeholders to leave for page 
number references</a></li>
   <li><a href="#toc-rv-switch">switch table of contents page margins</a> 
should they be incorrect for recto/verso printing</li>
 </ul>
@@ -619,7 +823,7 @@
 <!-- -TOC_APPENDS_AUTHOR- -->
 
 <div id="toc-appends-author" class="box-macro-args">
-Macro: <b>TOC_APPENDS_AUTHOR</b> <kbd class="macro-args">&lt;none&gt; | 
&lt;&quot;name(s) of authors&quot;&gt;</kbd>
+Macro: <b>TOC_APPENDS_AUTHOR</b> <kbd class="macro-args">&lt;none&gt; | 
&quot;&lt;name(s) of authors&gt;&quot;</kbd>
 </div>
 
 <p>
@@ -654,7 +858,7 @@
 <!-- -TOC_TITLE_ENTRY- -->
 
 <div id="toc-title-entry" class="box-macro-args">
-Macro: <b>TOC_TITLE_ENTRY</b> <kbd class="macro-args">&lt;&quot;alternate 
wording for a title entry in the toc&quot;&gt;</kbd>
+Macro: <b>TOC_TITLE_ENTRY</b> <kbd class="macro-args">&quot;&lt;alternate 
wording for a title entry in the toc&gt;&quot;</kbd>
 </div>
 
 <p>
@@ -699,6 +903,20 @@
 &#8220;Burning Bush&#8221;.
 </p>
 
+<!-- -SPACE_TOC_ITEMS- -->
+
+<div id="space-toc-items" class="box-macro-args">
+Macro: <b>SPACE_TOC_ITEMS</b></kbd>
+</div>
+
+<p>
+If you&#8217;d like mom to add a small amount of space between table
+of contents entry levels, use <kbd>.SPACE_TOC_ITEMS</kbd>.  Mom will
+visually group entry levels in a way that's pleasing to the eye.
+The only catch to this macro is that the bottom margins of table of
+contents pages may not align perfectly.
+</p>
+
 <!-- -TOC_PADDING- -->
 
 <div id="toc-padding" class="box-macro-args">
@@ -724,7 +942,8 @@
 
 <p>
 TOC_RV_SWITCH doesn&#8217;t take an argument.  It simply instructs
-mom to switch the left and right margins of
+mom to switch the left and right margins of the first table of
+contents page in
 <a href="rectoverso.html#recto-verso">recto/verso</a>
 documents should the table of contents happen to begin on an even
 page when you want an odd, or vice versa.

Index: momdoc/toc.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/toc.html,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -b -r1.40 -r1.41
--- momdoc/toc.html     22 Feb 2011 19:42:30 -0000      1.40
+++ momdoc/toc.html     31 Aug 2012 22:49:59 -0000      1.41
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software 
Foundation, Inc.
-Written by Peter Schaffter (address@hidden).
+Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,12 +15,13 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
 <head>
   <meta http-equiv="content-type" content="text/html;charset=utf-8"/>
-  <title>Mom, version 1.6-a -- Table of Contents</title>
+  <title>Mom, version 2.0 -- Table of Contents</title>
   <link rel="stylesheet" type="text/css" href="stylesheet.css" />
 </head>
 
@@ -30,22 +32,22 @@
 <div class="page">
 
   <div class="version">
-    mom, version 1.6-a
+    mom, version 2.0
   </div>
 
 <h1 class="toc" style="margin-top: 9px;">Table of Contents</h1>
 
-    <p style="margin-left: 2.75em; margin-right: 2.75em;">
-    The table of contents has grown quite large.  To ease navigation,
+    <p style="margin-left: 2.75em; margin-right: 2.75em; text-align:center ">
+    The table of contents is large.  To ease navigation,
     click on any link in the
+    <br/>
     <a href="#quick-toc">Quick Table of Contents</a>
-    to go to the corresponding entry in the the
+    <br/>
+    which will take you to the corresponding entry in the
+    <br/>
     <a href="#full-toc">Full Table of Contents</a>.
-    </p>
-
-    <p style="margin-top: -.5em; margin-left: 2.75em; margin-right: 2.5em;">
-    Alternatively, if you've been using mom for a while, you might
-    prefer the
+    <br/>
+    If you've been using mom for a while, you may prefer the
     <a href="macrolist.html#top">Quick Reference Guide</a>.
     </p>
 
@@ -56,7 +58,11 @@
   <h2 id="quick-toc" class="toc" style="margin-top: 18px; text-align: 
center;">Quick Table of Contents</h2>
 
     <div style="width: 50%; margin-top: .75em; margin-left: 12px; float: 
left;">
-    <h3 id="introductory" class="toc"><a style="color: #6e70cc" 
href="#what">INTRODUCTORY STUFF</a></h3>
+    <h3 id="version-2" class="toc"><a style="color: #6e70cc" 
href="#v2-notes">VERSION 2.0 NOTES</a></h3>
+    <br/>
+
+    <h3 id="introductory" class="toc"><a style="color: #6e70cc" 
href="#what">INTRODUCTION TO MOM</a></h3>
+
     <ul class="toc">
       <li><a href="#what">What is mom?</a></li>
       <li><a href="#defs">Definitions of terms used in this manual</a></li>
@@ -91,8 +97,8 @@
       <li><a href="#doc-defaults">Document defaults</a></li>
       <li><a href="#prelim">Preliminary document setup</a></li>
       <li><a href="#typemacdoc">Behaviour of the typesetting macros during 
document processing</a></li>
-      <li><a href="#tags">The document element tags</a> &ndash; heads, 
paragraphs, subheads, footnotes, etc.</li>
-      <li><a href="#images">Inserting images into a document</a></li>
+      <li><a href="#tags">The document element tags</a> &ndash; headings, 
paragraphs, quotes, footnotes, etc.</li>
+      <li><a href="#images">Graphics and floats</a></li>
       <li><a href="#hdrftr">Page headers and footers</a></li>
       <li><a href="#paginate">Pagination</a></li>
       <li><a href="#rv">Recto/verso printing and collating</a></li>
@@ -105,7 +111,6 @@
       </ul></li>
       <li style="margin-top: -1em;"><a href="#quick">Quick reference 
guide</a></li>
       <li><a href="#appendices">Appendices</a></li>
-      <li><a href="#reserved">Reserved words (macros, strings, 
registers)</a></li>
     </ul>
   </div>
 
@@ -116,6 +121,23 @@
   <h2 id="full-toc" class="toc" style="margin-top: 24px; text-align: 
center;">Full Table of Contents</h2>
 
   <div style="margin-left: 12px;">
+    <h3 id="v2-notes" class="toc"><a style="color: #6e70cc" 
href="version-2.html#top">VERSION 2.0 NOTES</a></h3>
+
+    <ul class="toc">
+      <li><a href="version-2.html#prefatory">Prefatory comments</a></li>
+      <li><a href="version-2.html#differences">Differences between 2.0 and 
1.x</a>
+        <ul>
+          <li><a href="version-2.html#pdf-support">PDF Support</a></li>
+          <li><a href="version-2.html#covers">Covers</a></li>
+          <li><a href="version-2.html#headings">Headings</a></li>
+          <li><a href="version-2.html#margin-notes">Margin notes</a></li>
+          <li><a href="version-2.html#floats">Floats</a></li>
+          <li><a href="version-2.html#table-of-contents">Table of 
Contents</a></li>
+      </ul></li>
+      <li><a href="version-2.html#pdfmom">The <strong>pdfmom</strong> wrapper 
around groff</a></li>
+      <li><a href="version-2.html#install-font">The 
<strong>install-font</strong> script</a></li>
+    </ul>
+
     <h3 id="what" class="toc"><a style="color: #6e70cc" 
href="intro.html#top">1. WHAT IS MOM?</a></h3>
 
     <ul class="toc">
@@ -125,9 +147,10 @@
       <li><a href="intro.html#intro-philosophy">1.4 Mom's philosophy</a></li>
       <li><a href="intro.html#intro-documentation">1.5 A note on mom's 
documentation</a>
       <ul>
-        <li><a href="intro.html#macro-args">1.5.1 How to read macro 
arguments</a></li>
-        <li><a href="intro.html#toggle-macro">1.5.2 &quot;Toggle&quot; 
macros</a></li>
-        <li><a href="intro.html#examples">1.5.3 Examples</a></li>
+        <li><a href="intro.html#canonical">1.5.1 Canonical reference 
materials</a></li>
+        <li><a href="intro.html#macro-args">1.5.2 How to read macro 
arguments</a></li>
+        <li><a href="intro.html#toggle-macro">1.5.3 &#8220;Toggle&#8221; 
macros</a></li>
+        <li><a href="intro.html#examples">1.5.4 Examples</a></li>
       </ul>
       </li>
     </ul>
@@ -145,9 +168,12 @@
   <ul class="toc">
     <li><a href="using.html#using-intro">3.1 Introduction</a></li>
     <li><a href="using.html#using-macros">3.2 How to input mom&#8217;s 
macros</a></li>
-    <li><a href="using.html#using-previewing">3.3 How to preview 
documents</a></li>
-    <li><a href="using.html#using-saving">3.4 Saving documents</a></li>
-    <li><a href="using.html#using-printing">3.3 Printing &mdash; invoking 
groff with mom</a></li>
+    <li><a href="using.html#viewing">3.3 Processing and viewing documents</a>
+    <ul>
+      <li><a href="using.html#pdf">Mom and pdf</a></li>
+      <li><a href="using.html#pdfmom">pdfmom</a></li>
+    </ul></li>
+    <li><a href="using.html#previewing">3.4 Automatic previewing of 
documents</a></li>
   </ul>
 
 <!-- -TYPESETTING MACROS- -->
@@ -156,7 +182,7 @@
 
   <ul class="toc">
     <li><a id="type-intro" href="typesetting.html#typesetting-intro">4.1 
Introduction to the typesetting macros</a></li>
-    <li><a id="page" href="typesetting.html#page-setup-intro">4.2 Paper and 
page Setup</a> &ndash; paper size and page margins
+    <li><a id="page" href="typesetting.html#page-setup-intro">4.2 Page 
setup</a> &ndash; paper size and page margins
       <ul>
         <li><a href="typesetting.html#index-page-setup">4.2.1 Macro 
list</a></li>
       </ul></li>
@@ -237,17 +263,15 @@
   <h3 id="doc-proc" class="toc"><a style="color: #6e70cc" 
href="docprocessing.html#top">5. DOCUMENT PROCESSING WITH MOM</a></h3>
   <ul class="toc">
     <li><a href="docprocessing.html#docprocessing-intro">5.1 Introduction to 
document processing</a></li>
-    <li><a id="doc-defaults" href="docprocessing.html#defaults">5.2 Document 
defaults</a>
+    <li><a id="doc-defaults" href="docprocessing.html#defaults">5.2 Document 
defaults</a> &ndash; papersize, margins, etc.
       <ul>
-        <li><a href="docprocessing.html#leading-note">5.2.1 Important note on 
leading/spacing and bottom margins</a>
-        <ul>
-        <li><a href="docprocessing.html#shim">5.2.1.1 The SHIM macro</a> 
&ndash; to get document leading back on track</li>
-        </ul></li>
+        <li><a href="docprocessing.html#leading-note">5.2.1 Important note on 
leading/spacing and bottom margins</a></li>
+        <li><a href="docprocessing.html#shim">5.2.1 The SHIM macro</a> &ndash; 
flexible spacer to keep document leading back on track</li>
       </ul></li>
-    <li><a id="prelim" class="highlight" href="docprocessing.html#setup">5.3 
PRELIMINARY DOCUMENT SETUP</a>
+    <li><a id="prelim" href="docprocessing.html#setup" class="highlight">5.3 
PRELIMINARY DOCUMENT SETUP</a>
       <ul>
-        <li><a href="docprocessing.html#docprocessing-tut" 
class="highlight">5.3.1 Tutorial</a> &ndash; setting up a mom document</li>
-        <li><a href="docprocessing.html#reference-macros" 
class="highlight">5.3.2 The reference macros</a> &ndash; meta-information mom 
needs to do her job
+        <li><a href="docprocessing.html#docprocessing-tut">5.3.1 Tutorial</a> 
&ndash; setting up a mom document</li>
+        <li><a href="docprocessing.html#reference-macros">5.3.2 The reference 
macros</a> &ndash; metadata mom needs to do her job
            <ul>
             <li><a href="docprocessing.html#title">5.3.2.1 TITLE</a></li>
             <li><a href="docprocessing.html#doc-title">5.3.2.2 
DOCTITLE</a></li>
@@ -261,37 +285,41 @@
             <li><a href="docprocessing.html#misc">5.3.2.10 MISC</a></li>
             <li><a href="docprocessing.html#covertitle">5.3.2.11 
COVERTITLE</a></li>
             <li><a href="docprocessing.html#covertitle">5.3.2.12 
DOC_COVERTITLE</a></li>
+            <li><a href="docprocessing.html#pdftitle">5.3.2.12 
PDF_TITLE</a></li>
           </ul></li>
-        <li><a href="docprocessing.html#docstyle-macros" 
class="highlight">5.3.3 The docstyle macros</a> &ndash; general appearance; 
what kind of document you're creating, and how you want it to look overall
+        <li><a href="docprocessing.html#docstyle-macros">5.3.3 The docstyle 
macros</a> &ndash; base templates; what kind of document you're creating, how 
you want it to look overall
           <ul>
             <li><a href="docprocessing.html#doctype">5.3.3.1 DOCTYPE</a> 
&ndash; the kind of document</li>
             <li><a href="docprocessing.html#printstyle">5.3.3.2 PRINTSTYLE</a> 
&ndash; typeset or &#8220;typewritten, double-spaced&#8221;</li>
             <li><a href="docprocessing.html#copystyle">5.3.3.3 COPYSTYLE</a> 
&ndash; draft or final</li>
           </ul></li>
-        <li><a href="docprocessing.html#start-macro" class="highlight">5.3.4 
Initiate document processing</a>
+        <li><a href="docprocessing.html#start-macro">5.3.4 Initiate document 
processing</a>
           <ul>
             <li><a href="docprocessing.html#start">5.3.4.1 START</a> &ndash; 
the required macro to initiate document processing</li>
           </ul></li>
-        <li><a href="docprocessing.html#style-before-start" 
class="highlight">5.3.5 Establishing type and formatting parameters before 
START</a>
+        <li><a href="docprocessing.html#docheader">5.3.5 Managing the 
DOCHEADER</a> &ndash; title, author, etc. on first page</li>
           <ul>
-            <li><a href="docprocessing.html#type-before-start">5.3.5.1 Use of 
the typesetting macros before START</a>
+            <li><a href="docprocessing.html#docheader-control">5.3.5.1 
DOCHEADER control</a></li>
+          </ul></li>
+        <li><a href="docprocessing.html#columns-intro">5.3.6 Setting documents 
in columns</a></li>
+        <li><a href="docprocessing.html#style-before-start">5.3.7 Establishing 
type and formatting parameters <span style="font-style: italic">before</span> 
START</a>
+          <ul>
+            <li><a href="docprocessing.html#type-before-start">5.3.7.1 Use of 
the typesetting macros before START</a>
               <ul class="fourth-level">
-                <li>&ndash; <a href="docprocessing.html#include">5.3.5.1.1 
Including (sourcing) style sheets and files</a></li>
-                <li>&ndash; <a href="docprocessing.html#color">5.3.5.1.2 
Initializing colours</a></li>
+                <li>&ndash; <a href="docprocessing.html#include">5.3.7.1.1 
Including (sourcing) style sheets and files</a></li>
+                <li>&ndash; <a href="docprocessing.html#color">5.3.7.1.2 
Initializing colours</a></li>
               </ul></li>
-            <li><a href="docprocessing.html#doc-lead-adjust">5.3.5.2  
DOC_LEAD_ADJUST</a> &ndash; adjust document
+            <li><a href="docprocessing.html#doc-lead-adjust">5.3.7.2  
DOC_LEAD_ADJUST</a> &ndash; adjust document
                 <a href="definitions.html#leading">leading</a>
                 to fill pages
             <ul class="fourth-level">
-              <li>&ndash; <a href="docprocessing.html#shim">5.3.5.2.1 SHIM</a> 
&ndash; macro to get document leading back on track</li>
+              <li>&ndash; <a href="docprocessing.html#shim">5.3.6.7.1 SHIM</a> 
&ndash; flexible spacer to keep document leading back on track</li>
             </ul></li>
-            <li><a href="docprocessing.html#docheader">5.3.5.3 Managing the 
document header</a></li>
-            <li><a href="docprocessing.html#columns-intro">5.3.5.4 COLUMNS</a> 
&ndash; setting documents in columns</li>
         </ul></li>
-      <li><a href="docprocessing.html#style-after-start" 
class="highlight">5.3.6 Changing basic type and formatting parameters after 
START</a>
+      <li><a href="docprocessing.html#style-after-start">5.3.8 Changing basic 
type and formatting parameters <span style="font-style: italic">after</span> 
START</a>
         <ul>
-          <li><a id="typemacdoc" href="docprocessing.html#behaviour">5.3.6.1 
Behaviour of the typesetting macros during document processing</a></li>
-          <li><a href="docprocessing.html#intro-doc-param">5.3.6.2 Post-START 
global style change macros</a>
+          <li><a id="typemacdoc" href="docprocessing.html#behaviour">5.3.8.1 
Behaviour of the typesetting macros during document processing</a></li>
+          <li><a href="docprocessing.html#intro-doc-param">5.3.8.2 Post-START 
global style-change macros</a>
           <ul class="fourth-level">
             <li>&ndash; <a href="docprocessing.html#index-doc-param">Macro 
list</a></li>
           </ul></li>
@@ -306,22 +334,19 @@
             </ul></li>
           <li><a href="docelement.html#epigraph-intro">5.4.2 Epigraphs</a></li>
           <li><a href="docelement.html#pp-intro">5.4.3 Paragraphs</a></li>
-          <li><a href="docelement.html#head-intro">5.4.4 Main heads</a></li>
-          <li><a href="docelement.html#subhead-intro">5.4.5 Subheads</a></li>
-          <li><a href="docelement.html#subsubhead-intro">5.4.6 
Subsubheads</a></li>
-          <li><a href="docelement.html#parahead-intro">5.4.7 Paragraph 
heads</a></li>
-          <li><a href="docelement.html#linebreak-intro">5.4.8 Linebreaks</a> 
&ndash; author linebreaks (section breaks)</li>
-          <li><a href="docelement.html#quote-intro">5.4.9 Quotes</a> &ndash; 
line for line poetic quotes or unformatted, verbatim text (e.g. blocks of 
code)</li>
-          <li><a href="docelement.html#blockquote-intro">5.4.10 
Blockquotes</a> &ndash; cited material</li>
-          <li><a href="docelement.html#code">5.4.11 Code</a> &ndash; inserting 
code snippets</li>
-          <li><a href="docelement.html#list-intro">5.4.12 Lists</a> &ndash; 
nested lists</li>
-          <li><a href="docelement.html#number-lines-intro">5.4.13 Line 
numbering</a></li>
-          <li><a href="docelement.html#footnote-intro">5.4.14 
Footnotes</a></li>
-          <li><a href="docelement.html#endnote-intro">5.4.15 Endnotes</a></li>
-          <li><a href="docelement.html#margin-notes-intro">5.4.16 Margin 
notes</a></li>
-          <li><a href="docelement.html#finis-intro">5.4.17 Document 
termination string</a> &ndash; FINIS</li>
+          <li><a href="docelement.html#heading-intro">5.4.4 Headings</a></li>
+          <li><a href="docelement.html#linebreak-intro">5.4.5 Linebreaks</a> 
&ndash; author linebreaks (section breaks)</li>
+          <li><a href="docelement.html#quote-intro">5.4.6 Quotes</a> &ndash; 
line for line poetic quotes or unformatted, verbatim text (e.g. blocks of 
code)</li>
+          <li><a href="docelement.html#blockquote-intro">5.4.7 Blockquotes</a> 
&ndash; cited material</li>
+          <li><a href="docelement.html#code">5.4.8 Code</a> &ndash; inserting 
code snippets</li>
+          <li><a href="docelement.html#list-intro">5.4.9 Lists</a> &ndash; 
nested lists</li>
+          <li><a href="docelement.html#number-lines-intro">5.4.10 Line 
numbering</a></li>
+          <li><a href="docelement.html#footnote-intro">5.4.11 
Footnotes</a></li>
+          <li><a href="docelement.html#endnote-intro">5.4.12 Endnotes</a></li>
+          <li><a href="docelement.html#margin-notes-intro">5.4.13 Margin 
notes</a></li>
+          <li><a href="docelement.html#finis-intro">5.4.14 Document 
termination string</a> &ndash; FINIS</li>
         </ul></li>
-      <li><a id="images" class="highlight" href="images.html#top">5.5 
INSERTING IMAGES</a></li>
+      <li><a id="images" class="highlight" href="images.html#top">5.5 GRAPHICS 
AND FLOATS</a></li>
       <li><a id="hdrftr" class="highlight" href="headfootpage.html#top">5.6 
PAGE HEADERS AND FOOTERS</a>
         <ul>
           <li><a href="headfootpage.html#headfootpage-intro">5.6.1 
Introduction</a></li>
@@ -356,30 +381,33 @@
       <li><a id="cover" class="highlight" href="cover.html#top">5.9 COVER 
PAGES</a></li>
       <li><a id="tocs" class="highlight" 
href="tables-of-contents.html#top">5.10 TABLES OF CONTENTS</a>
         <ul>
-          <li><a href="tables-of-contents.html#toc-behaviour">5.10.1 Table of 
contents behaviour</a></li>
-          <li><a href="tables-of-contents.html#psselect">5.10.2 Using psselect 
to put tables of contents where you want them</a></li>
-          <li><a href="tables-of-contents.html#index-toc-control">5.10.3 Table 
of contents control macros</a></li>
+          <li><a href="tables-of-contents.html#toc-intro">5.10.1 
Introduction</a> &ndash; the TOC macro</li>
+          <li><a href="tables-of-contents.html#toc-appearance">5.10.2 Table of 
contents appearance and behaviour</a></li>
+          <li><a href="tables-of-contents.html#pdf-output">5.10.3 PDF 
output</a></li>
+          <li><a href="tables-of-contents.html#positioning">5.10.4 Positioning 
the table of contents</a>
+            <ul>
+              <li><a href="tables-of-contents.html#auto-relocate-toc">5.10.2 
Automatic PDF relocation of the Table of Contents</a></li>
+              <li><a href="tables-of-contents.html#psselect">5.10.2 Using 
psselect to relocate the TOC in PostScript documents</a></li>
+            </ul></li>
+          <li><a href="tables-of-contents.html#index-toc-control">5.10.5 Table 
of contents control macros</a></li>
         </ul></li>
       <li><a id="ref" class="highlight" href="refer.html#top">5.11 
BIBLIOGRAPHIES AND REFERENCES</a></li>
       <li><a id="letter" class="highlight" href="letters.html#top">5.12 
WRITING LETTERS</a>
         <ul>
         <li><a href="letters.html#letters-intro">5.11.1 Introduction to 
writing letters</a></li>
-          <li><a href="letters.html#tutorial">5.11.2 Tutorial on writing 
letters</a></li>
-          <li><a href="letters.html#letters-defaults">5.11.3 Default style for 
letters</a></li>
+          <li><a href="letters.html#letters-tutorial">5.11.2 Tutorial on 
writing letters</a></li>
+          <li><a href="letters.html#letters-defaults">5.11.3 Default letter 
style</a></li>
           <li><a href="letters.html#index-letters-macros">5.11.4 The letter 
macros</a></li>
         </ul></li>
       </ul>
       <h3 id="quick" class="toc highlight"><a style="color: #6e70cc" 
href="macrolist.html#top">6. QUICK REFERENCE GUIDE</a></h3>
       <h3 id="appendices" class="toc" style="margin-top: .5em;"><a 
style="color: #6e70cc" href="appendices.html#top">7. APPENDICES</a></h3>
       <ul class="toc">
-      <li><a href="appendices.html#moredoc">7.1 Notes on the 
documentation</a></li>
-      <li><a href="appendices.html#fonts">7.2 Adding PostScript fonts to 
groff</a>
+      <li><a href="appendices.html#fonts">7.2 Adding fonts to groff</a>
         <ul>
-          <li><a href="appendices.html#howto">7.2.1 How to create a PostScript 
font for use with groff</a></li>
+          <li><a href="appendices.html#steps">7.2.1 Step-by-step 
instructions</a></li>
       </ul></li>
       <li><a href="appendices.html#codenotes">7.3 Some reflections on 
mom</a></li>
-      <li id="reserved"><a href="reserved.html#top">7.5 List of reserved 
words</a>
-          &ndash; complete list of macros, registers, strings, aliases and 
diversions</li>
       <li><a href="appendices.html#contact">7.5 Contact the author</a></li>
     </ul>
   </div>

Index: momdoc/typesetting.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/typesetting.html,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -b -r1.29 -r1.30
--- momdoc/typesetting.html     22 Feb 2011 19:42:30 -0000      1.29
+++ momdoc/typesetting.html     31 Aug 2012 22:50:00 -0000      1.30
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010, 
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -148,7 +150,7 @@
 With them, you can typeset on-the-fly.  Book covers, your best
 friend&#8217;s résumé, a poster for a lost dog&mdash;none of these
 requires structured document processing (page headers, paragraphs,
-heads, footnotes, etc).  What they do demand is precise control over
+headings, footnotes, etc).  What they do demand is precise control over
 every element on the page.  The typesetting macros give you that
 control.
 </p>
@@ -162,10 +164,14 @@
 <p>
 The page setup macros establish the physical dimensions of your page
 and the margins you want it to have. Groff has defaults for these,
-but I recommend setting them at the top of your files anyway unless
-you&#8217;re using mom&#8217;s
-<a href="docprocessing.html#docprocessing">document processing macros</a>
-and are content with her defaults.
+but I recommend setting them at the top of your files anyway.
+</p>
+
+<p>
+If you&#8217;re using mom&#8217;s
+<a href="docprocessing.html#docprocessing">document processing macros</a>,
+these macros must come after
+<a href="docprocessing.html#printstyle">PRINTSTYLE</a>.
 </p>
 
 <p>
@@ -182,47 +188,41 @@
 <h3 id="page-setup-note" class="docs notes">Important note on page dimensions 
and papersize</h3>
 
 <p style="margin-top: .5em;">
-Mom&#8217;s macros for setting up the desired size of printer sheets
-tell mom and groff about the page dimensions, but not the driver
-responsible for generating the final PostScript file.  You must take
-care of this yourself.
+When mom files are processed with
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>,
+which is recommended (see
+<a href="http://www.schaffter.ca/mom/pdf/mom-pdf.pdf";><span 
class="book-title">Producing PDFs with groff and mom</span></a>),
+page dimensions are automatically passed to groff, and you don't
+have to worry about them.
 </p>
 
 <p>
-If you routinely print documents on the same size paper (you
-probably do), the easiest way to make sure the PostScript driver
-knows about your papersize is to edit the file
+Mom documents processed directly with <strong>groff</strong>, or with
+<strong>pdfroff</strong>, or with <strong>pdfmom -Tps</strong>, require
+that the papersize be given on the command line as well if the
+papersize is different from the default on your system.  You can
+verify&mdash;or change&mdash;the default papersize by inspecting the
+files
 <br/>
 <span class="pre-in-pp">
   &lt;path to groff&gt;/font/devps/DESC
 </span>
-In it, you will see a line that reads:
+and
+<br/>
 <span class="pre-in-pp">
-  papersize &lt;papersize&gt;
+  &lt;path to groff&gt;/font/devpdf/DESC
 </span>
-Change <kbd>&lt;papersize&gt;</kbd> to the name of your papersize
-(e.g. a4, letter, legal, etc.; a full list of valid named papersizes
-that can be used in DESC is found in <kbd>man papersize</kbd>).  If
-your routine papersize is non-standard (i.e. doesn&#8217;t have a
-&#8220;name&#8221;) you can give the dimensions for your papersize,
-separated by a comma.  The dimensions must have a
-<a href="definitions.html#unitofmeasure">unit of measure</a>
-appended.  Valid units of measure for papersize are
-inches (<kbd>i</kbd>),
-centimeters (<kbd>c</kbd>),
-picas (<kbd>P</kbd>) and
-points (<kbd>p</kbd>).
-For example, to set up a routine papersize of 8 inches by 10 inches,
-the line would look like this:
-<br/>
-<span class="pre-in-pp">
-  papersize 8i,10i
-</span>
-Having set up your routine papersize, if you occasionally need to
-print on sheets that do not conform to its dimensions, you must, in
-addition to setting the page dimensions in your mom file, invoke
-groff on the command line with the <kbd>-P-p&lt;papersize&gt;</kbd>
-option.
+(See <strong>man papersize</strong> for list of valid papersize
+names, as well as for instructions on how to enter a non-standard
+size.)
+</p>
+
+<p>
+If you occasionally need to print on sheets that do not
+conform to your default papersize, you must, in addition
+to setting the page dimensions in your mom file, pass the
+<kbd>-P-p&lt;papersize&gt;</kbd> option to <strong>groff</strong>,
+<strong>pdfroff</strong>, or <strong>pdfmom -Tps</strong>.
 </p>
 
 <p>
@@ -235,18 +235,22 @@
 or
 <a href="#paper">PAPER</a>,
 or
-<a href="#page">PAGE</a>)
-in your mom file, when you invoke groff to process the file, the
-command would look like this:
+<a href="#page">PAGE</a>),
+you must include <kbd>-P-p&lt;papersize&gt;</kbd> on whichever
+command line you use, eg
 <br/>
 <span class="pre-in-pp">
-  groff -mom -P-plegal
+  pdfmom -Tps -mom -P-plegal
 </span>
+Remember, though, that
+<a href="using.html#pdfmom" style="font-weight: bold">pdfmom</a>,
+with no <kbd>-Tps</kbd> option, is smart enough to know the
+papersize from the dimensions provided in your mom file.
 </p>
 
-<p class="tip-bottom" style="margin-top: -1em;">
+<p class="tip-bottom">
 Consult <kbd>man groff</kbd>, <kbd>man grops</kbd> and <kbd>man
-groff-font</kbd> for additional information concerning papersizes,
+groff_font</kbd> for additional information concerning papersizes,
 as well as information on printing in &#8220;landscape&#8221;
 orientation.
 </p>
@@ -477,7 +481,7 @@
 That way, you don&#8217;t have to worry about calculating the line
 length.  On the other hand, if you know the line length for a patch
 of type should be 17 picas and 3 points, entering the line length
-with LL is much easier than calculating the right margin, e.g.
+with LL is much easier than calculating the right margin, eg
 <br/>
 <span class="pre-in-pp">
   .LL 17P+3p
@@ -727,18 +731,6 @@
 <a href="#t-margin">T_MARGIN</a>).
 </p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="experts">Experts:</span>
-Prior to version 1.1.9, NEWPAGE was simply an alias of
-<kbd>.bp</kbd>.  As of 1.1.9, NEWPAGE, is its own mom macro.  While
-the new macro should be backwardly compatible with documents created
-using pre-1.1.9 moms, I suggest that from this version onward, if
-you were in the habit of using <kbd>.bp</kbd> whenever you wanted to
-break to a new page, you now begin to use NEWPAGE instead.
-</p>
-</div>
-
 <div class="rule-short" style="margin-bottom: 24px;"><hr/></div>
 
 <!-- ==================================================================== -->
@@ -789,7 +781,7 @@
 <p>
 FAMILY takes one argument: the name of the
 <a href="definitions.html#family">family</a>
-you want.  Groff comes with a number of PostScript families, each
+you want.  Groff comes with a small set of basic families, each
 identified by a 1-, 2-or 3-letter mnemonic.  The standard families
 are:
 <br/>
@@ -825,10 +817,10 @@
 </p>
 
 <p id="fam-add-note" class="tip-bottom">
-<span class="additional-note">Additional note:</span> As of mom,
-version 1.1.9-a, if you are running a version of groff lower than
-1.19.2, you must follow all FAMILY requests with a FT request,
-otherwise mom will set all type up to the next FT request in the
+<span class="additional-note">Additional note:</span> 
+If you are running a version of groff lower than 1.19.2, you must
+follow all FAMILY requests with a FT request, otherwise mom will set
+all type up to the next FT request in the
 <a href="#fallback-font">fallback font</a>.
 </p>
 </div>
@@ -871,7 +863,7 @@
 
 <p>
 Please see the Appendices,
-<a href="appendices.html#fonts">Adding PostScript fonts to groff</a>,
+<a href="appendices.html#fonts">Adding fonts to groff</a>,
 for information on adding fonts and families to groff, as well as
 to see a list of the extensions mom provides to groff&#8217;s basic
 <b>R</b>, <b>I</b>, <b>B</b>, <b>BI</b> styles.
@@ -879,10 +871,10 @@
 
 <div class="box-tip">
 <p class="tip">
-<span class="experts">Experts:</span> If you add other PostScript
-families to groff&#8217;s /font/devps directory, I recommend
-following the groff standard for naming families and fonts.  For
-example, if you add the Garamond family, name the font files
+<span class="tip">Suggestion:</span> When adding 
+families to groff, I recommend following the established standard
+for the naming families and fonts.  For example, if you add the
+Garamond family, name the font files
 <br/>
 <span class="pre-in-pp">
   GARAMONDR
@@ -934,15 +926,20 @@
 </p>
 
 <p>
-(As of mom, version 1.1.9-a, the range of arguments that can be
-passed to FT has been considerably extended, allowing access to a
-greater variety of font
+Mom considerably extends the range of arguments you can pass to FT,
+making it more convenient to add and access fonts of differing
 <a href="definitions.html#weight">weights</a>
 and
-<a href="definitions.html#shape">shapes</a>.
-Please see the
-<kbd><a href="#font-note">NOTE</a></kbd>,
-below.)
+<a href="definitions.html#shape">shapes</a>
+within the same family.  Have a look
+<a href="appendices.html#style-extensions">here</a>
+for a list of the weight/style arguments mom allows.  Be aware,
+though, that you must have the fonts, correctly installed and named,
+in order to use the arguments.  (See
+<a href="appendices.html#fonts">Adding fonts to groff</a>
+for instructions and information.)  Please also read the
+<a href="#fam-add-note">ADDITIONAL NOTE</a>
+found in the description of the FAMILY macro.
 </p>
 
 <p>
@@ -975,29 +972,6 @@
 <a href="inlines.html#inline-fonts-mom">Inline Escapes, font control</a>.
 </p>
 
-<div id="font-note" class="box-tip">
-<p class="tip">
-<span class="note">Note:</span> mom, versions 1.1.9-a and higher,
-considerably extends the range of arguments you can pass to FT,
-making it more convenient to add and access fonts of differing
-<a href="definitions.html#weight">weights</a>
-and
-<a href="definitions.html#shape">shapes</a>
-within the same family.  Have a look
-<a href="appendices.html#style-extensions">here</a>
-for a list of the weight/style arguments mom
-allows.
-</p>
-</div>
-
-<p>
-Be aware, though, that you must have the fonts, correctly installed
-and named, in order to use the arguments.  (See
-<a href="appendices.html#howto">How to create a PostScript font for use with 
groff</a>
-for how to add fonts to groff.)  Please also read the
-<a href="#fam-add-note">ADDITIONAL NOTE</a>
-found in the description of the FAMILY macro.
-</p>
 
 <!-- -FALLBACK_FONT- -->
 
@@ -1012,7 +986,7 @@
 <p>
 In the event that you pass an invalid argument to
 <a href="#font">.FAMILY</a>
-(i.e. a non-existent family), mom, by default, uses the fallback
+(ie a non-existent family), mom, by default, uses the fallback
 font, Courier Medium Roman (CR), in order to continue processing
 your file.
 </p>
@@ -1029,10 +1003,7 @@
 </p>
 
 <p>
-Additionally, if your version of groff accepts accepts &#8221;<kbd>.if
-F</kbd>&#8221; and &#8221;<kbd>.if S</kbd>&#8221; (see
-<a href="#fam-add-note">above</a>),
-mom issues a warning whenever a font style set with
+Mom issues a warning whenever a font style set with
 <a href="#font">FT</a>
 does not exist, either because you haven&#8217;t registered the
 style (see
@@ -1112,7 +1083,7 @@
 <span class="pre-in-pp">
   .PT_SIZE 11
 </span>
-Point sizes may be fractional (e.g.  10.25 or 12.5).
+Point sizes may be fractional (eg  10.25 or 12.5).
 </p>
 
 <p>
@@ -1165,7 +1136,7 @@
 <p>
 LS (Line Space) takes one argument: the distance you want, typically
 in points, from baseline to baseline of type.  The argument may be
-fractional (e.g. 12.25 or 14.5).  Like PT_SIZE, LS does not require
+fractional (eg 12.25 or 14.5).  Like PT_SIZE, LS does not require
 a unit of measure, since
 <a href="definitions.html#leading">leading</a>
 is most often given in points.  Therefore, to set the linespace to
@@ -1230,7 +1201,7 @@
 Used in this way, AUTOLEAD does not require a unit of measure;
 points is assumed.  However, you may use an alternate unit of
 measure by appending it to the argument.  The argument may be a
-decimal fraction (e.g. .5 or 2.75).
+decimal fraction (eg .5 or 2.75).
 </p>
 
 <p>
@@ -1665,23 +1636,17 @@
 <i>for the way around this.</i>
 </p>
 
-<p>
-The mnemonic &#8220;EL&#8221; is borrowed from old Compugraphic
-typesetting systems, where it stood for
-"<span style="text-decoration: underline;">E</span>nd <span 
style="text-decoration: underline;">L</span>ine."
-Conceptually, EL is equivalent to the notion of a carriage return
-with no linefeed.
-</p>
-
 <p id="el-example">
-EL&#8217;s function is simple: it breaks a line without advancing
-on the page.  As an example of where you might use it, imagine that
-you&#8217;re working from marked-up copy.  The markup indicates 24
-points of space between two given lines, but the prevailing line
-spacing is 12.5 points.  You may find it more convenient to break
-the first line with EL and instruct mom to advance 24 points to the
-next line instead of calculating the lead that needs to be added to
-12.5 to get 24.  To demonstrate:
+EL ("<span style="text-decoration: underline;">E</span>nd <span 
style="text-decoration: underline;">L</span>ine")
+is conceptually equivalent to the notion of a carriage return with
+no linefeed.  Its function is simple: it breaks a line without
+advancing on the page.  As an example of where you might use it,
+imagine that you&#8217;re working from marked-up copy.  The markup
+indicates 24 points of space between two given lines, but the
+prevailing line spacing is 12.5 points.  You may find it more
+convenient to break the first line with EL and instruct mom to
+advance 24 points to the next line instead of calculating the lead
+that needs to be added to 12.5 to get 24.  To demonstrate:
 <br/>
 <span class="pre-in-pp">
   .LEFT
@@ -1708,71 +1673,11 @@
 <p>
 ALD in the above examples stands for
 &#8220;<span style="text-decoration: underline;">A</span>dvance
-<span style="text-decoration: underline;">L</span>ea<span 
style="text-decoration: underline;">D</span>&#8221;
-(another mnemonic borrowed from Compugraphic), which is covered in
-the section
-<a href="#vertical-movements-intro">Vertical movements</a>.
-</p>
-
-<div class="box-notes">
-<h3 id="el-notes" class="docs notes">Notes</h3>
-
-<p style="margin-top: .5em;">
-In versions of mom prior to 1.1.9, EL did not always work as
-advertised on the last
-<a href="definitions.html#outputline">output line</a>
-of pages that contained a footer trap (e.g. one set with
-<a href="#b-margin">B_MARGIN</a>
-or in  documents formatted using the
-<a href="docprocessing.html#docprocessing">document processing macros</a>).
+<span style="text-decoration: underline;">L</span>ea<span 
style="text-decoration: underline;">D</span>&#8221;,
+which is covered in the section
+<a href="#aldrld-intro">Vertical movements</a>.
 </p>
 
-<p>
-EL has been re-written so that this should no longer be the case.
-However, in order for it to work in the
-<a href="definitions.html#filled">nofill</a>
-modes
-(<a href="#lrc">LEFT</a>,
-<a href="#lrc">RIGHT</a>
-or
-<a href="#lrc">CENTER</a>),
-you must always &#8220;join&#8221; <kbd>.EL</kbd> to
-the line before it using the
-<kbd><a href="#join">\c</a></kbd>
-<a href="definitions.html#inlines">inline escape</a>,
-like this:
-<br/>
-<span class="pre-in-pp">
-  .LEFT
-  A line I don&#8217;t want to advance\c
-  .EL
-</span>
-Conversely, in
-<a href="definitions.html#filled">fill modes</a>
-(<a href="#quad">QUAD LEFT</a>,
-<a href="#quad">QUAD RIGHT</a>,
-<a href="#quad">QUAD CENTER</a>
-or
-<a href="#justify">JUSTIFY</a>),
-the <kbd>\c</kbd> must not be used.
-</p>
-
-<p>
-If EL is used after most macros or groff
-<a href="definitions.html#primitives">primitives</a>
-(see the exception, below), you don&#8217;t have to worry about
-this, regardless of the fill mode.  Just type
-<kbd>.EL</kbd>
-</p>
-
-<p class="tip-bottom">
-<span class="experts">Experts:</span> EL is unrelated to
-groff&#8217;s <kbd>.el</kbd>.  If you find the similarity confusing,
-you may want to alias EL as something else (but don&#8217;t use EOL;
-mom uses it internally.)
-</p>
-</div>
-
 <!-- -SP- -->
 
 <div class="macro-id-overline">
@@ -2078,7 +1983,7 @@
 <a href="#ws">WS</a>,
 increasing the sentence space by a value of 1 or 2 produces a
 difference that in many cases is scarcely visible; increasing by a
-value of 5 or so produces a subtle but noticeable difference (i.e.
+value of 5 or so produces a subtle but noticeable difference (ie
 the space between double-spaced input sentences will be slightly but
 visibly greater than the space between words); and increasing by a
 value greater than 10 is always apparent.  You should preview your
@@ -2104,7 +2009,7 @@
 If you do use SS for something other than ensuring that you
 don&#8217;t get unwanted sentence spaces in output copy, you can set
 or reset the sentence space to the groff default (the same width
-as a word space, i.e. double-spaced input sentences will appear
+as a word space, ie double-spaced input sentences will appear
 double-spaced on output as well) with
 <br/>
 <span class="pre-in-pp">
@@ -2161,7 +2066,7 @@
 <h3 class="docs">1.&nbsp;&nbsp;HY</h3>
 
 <p>
-HY by itself (i.e. with no argument) simply turns automatic
+HY by itself (ie with no argument) simply turns automatic
 hyphenation on.  Any argument other than LINES, MARGIN, SPACE or
 DEFAULT, turns automatic hyphenation off.  For example, as explained
 in
@@ -2182,7 +2087,7 @@
 HY observes the following default hyphenation rules:
 </p>
 <ul style="margin-top: -.5em; margin-left: 18px;">
-  <li>Last lines (i.e. ones that will spring a trap&mdash;typically
+  <li>Last lines (ie ones that will spring a trap&mdash;typically
       the last line on a page) will not be hyphenated.
   </li>
   <li>The first and last two characters of a word are never
@@ -2209,7 +2114,7 @@
 <span class="note">Note:</span>
 <a href="definitions.html#discretionaryhyphen">Discretionary hyphens</a>
 count when groff is figuring out how many lines to hyphenate;
-explicit hyphens do not.
+explicit hyphens (ie the actual hyphen character) do not.
 </p>
 </div>
 
@@ -2217,7 +2122,7 @@
 
 <p>
 HY MARGIN sets the amount of room allowed at the end of a line
-before hyphenation is tripped (e.g. if there&#8217;s only 6 points
+before hyphenation is tripped (eg if there&#8217;s only 6 points
 left at the end of a line, groff won&#8217;t try to hyphenate the
 next word).  HY MARGIN only applies if you&#8217;re using
 <a href="#quad">QUAD</a>,
@@ -2400,7 +2305,7 @@
 <a href="#br">break</a>
 when it&#8217;s invoked if you&#8217;re in one of the
 <a href="definitions.html#fill">fill</a>
-modes (i.e.
+modes (ie
 <a href="#quad">QUAD</a>
 L, R, C, J or
 <a href="#justify">JUSTIFY</a>).
@@ -2415,16 +2320,11 @@
 
 <div class="box-important">
 <p class="tip">
-<span class="important">IMPORTANT:</span> In versions prior to
-1.1.9-a, RW affected all
-<a href="definitions.html#font">fonts</a>
-in the
-<a href="definitions.html#family">family</a>
-current at the time it was invoked.  As of 1.1.9-a, this behaviour
-has been changed. RW affects only the font current at the time
-it&#8217;s invoked, and remains in effect for that font every time
-the font is called, hence must be reset to zero to cancel its effect
-(<kbd>.RW&nbsp;0</kbd>) on that font.
+<span class="important">IMPORTANT:</span>
+RW (and its complement, EW; see below) only affects the current
+font, and remains in effect for that font every time it&#8217;s
+called, hence it must be reset to zero to cancel its effect
+(<kbd>.RW&nbsp;0</kbd>).
 </p>
 </div>
 
@@ -2468,7 +2368,7 @@
 <a href="#br">break</a>
 when it&#8217;s invoked if you&#8217;re in one of the
 <a href="definitions.html#fill">fill</a>
-modes (i.e.
+modes (ie
 <a href="#quad">QUAD</a>
 L, R, C, J or
 <a href="#justify">JUSTIFY</a>).
@@ -2484,16 +2384,11 @@
 
 <div class="box-important">
 <p class="tip">
-<span class="important">IMPORTANT:</span> In versions prior to
-1.1.9-a, EW affected all
-<a href="definitions.html#font">fonts</a>
-in the
-<a href="definitions.html#family">family</a>
-current at the time it was invoked.  As of 1.1.9-a, this behaviour
-has been changed.  EW affects only the font current at the time
-it&#8217;s invoked, and remains in effect for that font every time
-the font is called, hence must be reset to zero to cancel its effect
-(<kbd>.EW&nbsp;0</kbd>) on that font.
+<span class="important">IMPORTANT:</span>
+EW (and its complement, RW; see above) only affects the current
+font, and remains in effect for that font every time it&#8217;s
+called, hence it must be reset to zero to cancel its effect
+(<kbd>.RW&nbsp;0</kbd>).
 </p>
 </div>
 
@@ -2510,7 +2405,7 @@
 <p>
 By default, in
 <a href="definitions.html#filled">fill</a>
-modes (i.e.
+modes (ie
 <a href="#quad">QUAD</a>
 L, R, C, J or
 <a href="#justify">JUSTIFY</a>)
@@ -2549,9 +2444,9 @@
 </div>
 
 <p>
-By itself (i.e. with no argument), KERN turns automatic pairwise
+By itself (ie with no argument), KERN turns automatic pairwise
 <a href="definitions.html#kern">kerning</a>
-on.  With any argument (e.g. OFF, Q, X), pairwise kerning is turned
+on.  With any argument (eg OFF, Q, X), pairwise kerning is turned
 off.
 </p>
 
@@ -2605,11 +2500,11 @@
 <h2 id="modifications-intro" class="macro-group">Type modifications (pseudo 
font styles)</h2>
 
 <p>
-It sometimes happens that a PostScript 
+It sometimes happens that a
 <a href="definitions.html#family">family</a>
 doesn&#8217;t contain all the fonts you need.  You might, for
 example, be missing an italic font, or a bold font.  Or you might
-not be able to get your hands on a condensed family.  That&#8217;s
+not be able to get your hands on the condensed version.  That&#8217;s
 where these macros and inline escapes come in.  With them, you
 can fake the fonts you&#8217;re missing.  A word of caution,
 though: &#8220;faked&#8221; fonts are just that&mdash;faked.  You
@@ -3078,7 +2973,7 @@
 <div class="box-tip">
 <p class="tip">
 <span class="note">Note:</span> if you want to use ALD at the top
-of a page (i.e. to advance to the starting position of type on a
+of a page (ie to advance to the starting position of type on a
 page), combine the value you want with <kbd>-1v</kbd> (minus one
 line space), like this:
 <br/>
@@ -3155,7 +3050,7 @@
 <p class="tip">
 <span class="note">Note:</span> see the section
 <a href="docprocessing.html#behaviour">Typesetting macros during document 
processing</a>
-for re-assuring information on the use of tabs during
+for reassuring information on the use of tabs during
 <a href="docprocessing.html#docprocessing">document processing</a>.
 </p>
 </div>
@@ -3210,7 +3105,7 @@
 You want the first tab, CRITERION,
 </p>
 <ul style="margin-top: -.5em; margin-bottom: -.5em;">
-<li>to begin at the left margin of the page &ndash; i.e. no indent</li>
+<li>to begin at the left margin of the page &ndash; ie no indent</li>
 <li>to have a line length of 5 picas</li>
 <li>to be set flush left</li>
 </ul>
@@ -3273,7 +3168,10 @@
     advances one linespace and calls the tab.</li>
 <li>with <kbd><a href="#tn">.TN</a></kbd> (Tab Next), which keeps
     you on the current line and moves over to the next
-    tab in sequence (i.e. from 1 to 2, 2 to 3, etc.).</li>
+    tab in sequence (ie from 1 to 2, 2 to 3, etc.), or, more
+    conveniently, with the
+    <kbd><a href="#tn">\*[TB+]</a></kbd>
+    <a href="definitions.html#inlines">inline escape</a></li>
 </ul>
 
 <p>
@@ -3304,31 +3202,23 @@
 .TAB_SET 2 8P  9P  C
 .TAB_SET 3 19P 17P L QUAD
 .TAB 1
-CRITERION
-.TN
-EVALUATION
-.TN
+CRITERION\*[TB+]
+EVALUATION\*[TB+]
 COMMENTS
 .SP
 .TAB 1
-Service
-.TN
-Good
-.TN
+Service\*[TB+]
+Good\*[TB+]
 Many clients specifically request support from Joe by name.
 .SP
 .TAB 1
-Punctuality
-.TN
-Satisfactory
-.TN
+Punctuality\*[TB+]
+Satisfactory\*[TB+]
 Tends to arrive after 8:00am, but often works through lunch hour.
 .SP
 .TAB 1
-Team spirit
-.TN
-Needs work
-.TN
+Team spirit\*[TB+]
+Needs work\*[TB+]
 Persistently gives higher priority to helping clients
 than respecting organizational hierarchy.
 .TQ
@@ -3339,9 +3229,9 @@
 Try setting this up and processing it it with
 <br/>
 <span class="pre-in-pp">
-  groff -mom &lt;filename&gt; &gt; &lt;filename&gt;.ps
+  pdfmom filename.mom | ps2pdf - filename.pdf
 </span>
-then previewing the .ps file.  Notice how <kbd>.TN</kbd>
+then previewing the .pdf file.  Notice how <kbd>.TN</kbd>
 simply moves over to the next tab, while the combination
 <kbd>.SP/.TAB&nbsp;1</kbd> breaks the line, advances by one extra
 linespace, and calls the first tab.
@@ -3466,8 +3356,7 @@
 </span>
 </li>
 <li>We want a 1 pica (12 points) gutter between tab 1 and 2,
-    so we insert 12 points of space with \*[FWD 12p]
-    (ForWarD 12 points):
+    so we insert 12 points of space with \*[FWD 12p]:
 <br/>
 <span class="pre-in-pp" style="margin-bottom: -.25em;">
   \*[FWD 12p]
@@ -3513,12 +3402,13 @@
        |  |   |
        |  |   +--fill output lines
        |  |
-  tab #--+  +--direction
+tab #--+  +--direction
 </span>
 From here on in, you call the tabs with
-<kbd><a href="#tab">.TAB</a></kbd>
-and
-<kbd><a href="#tn">.TN</a></kbd>
+<kbd><a href="#tab">.TAB</a></kbd>,
+<kbd><a href="#tn">.TN</a></kbd>,
+or
+<kbd><a href="#tn">\*[TB+]</a></kbd>
 just like typesetting tabs (see
 <a href="#typesetting-tabs-tut">typesetting tabs tutorial</a>).
 </p>
@@ -3547,31 +3437,23 @@
 .ST  2  L
 .ST  3  L  QUAD
 .TAB 1
-CRITERION
-.TN
-EVALUATION
-.TN
+CRITERION\*[TB+]
+EVALUATION\*[TB+]
 COMMENTS
 .SP
 .TAB 1
-Service
-.TN
-Good
-.TN
+Service\*[TB+]
+Good\*[TB+]
 Many clients specifically request support from Joe by name.
 .SP
 .TAB 1
-Punctuality
-.TN
-Satisfactory
-.TN
+Punctuality\*[TB+]
+Satisfactory\*[TB+]
 Tends to arrive after 8:00am, but often works through lunch hour.
 .SP
 .TAB 1
-Team spirit
-.TN
-Needs work
-.TN
+Team spirit\*[TB+]
+Needs work\*[TB+]
 Persistently gives higher priority to helping clients
 than respecting organizational hierarchy.
 .TQ
@@ -3582,9 +3464,9 @@
 Try setting this up and processing it with
 <br/>
 <span class="pre-in-pp">
-  groff -mom &lt;filename&gt; &gt; &lt;filename&gt;.ps 
+  pdfmom filename | ps2pdf - filename.pdf
 </span>
-and previewing the .ps file.
+and previewing the .pdf file.
 </p>
 
 <p>
@@ -3611,7 +3493,8 @@
   <li><a href="#inline-st">\*[ST]...\*[STX]</a> &ndash; inline escapes for 
marking String Tabs</li>
   <li><a href="#st">ST</a> &ndash; set String Tabs</li>
   <li><a href="#tab">TAB</a> &ndash; call tabs</li>
-  <li><a href="#tn">TN</a> &ndash; Tab Next; call next tab in a sequence</li>
+  <li><a href="#tn">TN</a> &ndash; Tab Next; call next tab in sequence</li>
+  <li><a href="#tn">\*[TB+]</a> &ndash; inline escape to call next tab in 
sequence</li>
   <li><a href="#tq">TQ</a> &ndash; Tab Quit</li>
 </ul>
 
@@ -3756,7 +3639,7 @@
 </span>
 String tab 1 begins at the start of the line and ends after the word
 &#8220;time&#8221;.  String tab 2 starts at &#8220;good&#8221; and
-ends after &#8220;men&#8221;.  Inline escapes (e.g. font or point
+ends after &#8220;men&#8221;.  Inline escapes (eg font or point
 size changes, or horizontal movements, including
 <a href="goodies.html#pad">padding</a>)
 are taken into account when mom determines the position and length
@@ -3779,7 +3662,7 @@
 <div class="box-tip">
 <p class="tip">
 <span class="note">Note:</span> Lines with string tabs marked off
-in them are normal input lines, i.e. they get printed, just like
+in them are normal input lines, ie they get printed, just like
 any input line.  If you want to set up string tabs without the line
 printing, use the
 <a href="goodies.html#silent">SILENT</a>
@@ -3920,7 +3803,6 @@
 <span class="pre-in-pp">
   .TAB 3
 </span>
-<br/>
 moves you to tab 3.
 </p>
 
@@ -3943,12 +3825,13 @@
 </span>
 If you want the tabs to line up, use
 <a href="#tn">TN</a>
-(Tab Next), like this:
+(Tab Next)
+or, more conveniently, the inline escape
+<a href="#tn">\*[TB+]</a>:
 <br/>
 <span class="pre-in-pp">
   .TAB 1
-  A line of text in tab 1.
-  .TN
+  A line of text in tab 1.\*[TB+]
   A line of text in tab 2.
 </span>
 which produces
@@ -3979,44 +3862,50 @@
 
 <div class="box-macro-args">
 Macro: <b>TN</b>
+<br/>Inline escape: <b>\*[TB+]</b>
 </div>
-<p class="requires">
+
+<p>
+TN moves over to the next tab in numeric sequence (tab n+1) without
+advancing on the page.  See the
+<a href="#note-tn">NOTE</a>
+in the description of the TAB macro for an example of how TN works.
+</p>
+
+<p>
 In tabs that aren&#8217;t given the <kbd class="normal">QUAD</kbd>
 argument when they&#8217;re set up with
 <a href="#tab-set" class="normal">TAB_SET</a>
 or
 <a href="#st" class="normal">ST</a>,
 you must terminate the line preceding <kbd class="normal">.TN</kbd>
-with the <kbd class="normal">\c</kbd> inline escape.  See the
-<a href="#tn-note" class="normal">ADDITIONAL NOTE</a>.
+with the <kbd class="normal">\c</kbd> inline escape.  Conversely,
+if you did give a <kbd>QUAD</kbd> argument to TAB_SET or ST, the
+<kbd>\c</kbd> must not be used.
+</p>
+
+<p>
 If you find remembering whether to put in the
 <kbd class="normal">\c</kbd> bothersome, you may prefer to use the
 <a href="definitions.html#inlines" class="normal">inline escape</a>
 alternative to
 <kbd class="normal">.TN</kbd>,
-<kbd class="normal"><a href="inlines.html#TB+">\*[TB+]</a></kbd>,
+<kbd class="normal"><a href="inlines.html#tb-plus-mom">\*[TB+]</a></kbd>,
 which works consistently regardless of the fill mode.
 </p>
 
-<p>
-TN moves over to the next tab in numeric sequence (tab n+1) without
-advancing on the page.  See the
-<a href="#note-tn">NOTE</a>
-in the description of the TAB macro for an example of how TN works.
-</p>
-
 <div id="tn-note" class="box-tip">
-<p class="tip-top">
+<p class="tip">
 <span class="note">Note:</span> You must put text in the
 <a href="definitions.html#inputline">input line</a>
-immediately after TN. &#8220;Stacking&#8221; of TN&#8217;s is not
+immediately after TN. Stacking of TN&#8217;s is not
 allowed.  In other words, you cannot do
 <br/>
 <span class="pre-in-pp">
   .TAB 1
-  Some text
+  Some text\c
   .TN
-  Some more text
+  Some more text\c
   .TN
   .TN
   Yet more text
@@ -4025,54 +3914,18 @@
 <br/>
 <span class="pre-in-pp">
   .TAB 1
-  Some text
+  Some text\c
   .TN
-  Some more text
-  .TAB 4
-  Yet more text
-</span>
-<span class="additional-note">Additional note:</span>
-In versions of mom prior to 1.1.9, TN did not always work as
-advertised on the last
-<a href="definitions.html#outputline">output line</a>
-of pages that contained a footer trap (e.g. one set with
-<a href="#b-margin">B_MARGIN</a>
-or in  documents formatted using the
-<a href="docprocessing.html#docprocessing">document processing macros</a>).
-</p>
-
-<p>
-TN has been re-written so that this should no longer be the case.
-However, in order for it to work in tabs that have not been given a
-<kbd>QUAD</kbd> argument (see
-<a href="#tab-set">TAB_SET</a>
-and
-<a href="#st">ST</a>)
-you must always &#8220;join&#8221; <kbd>.TN</kbd> to
-the line before it using the
-<kbd><a href="#join">\c</a></kbd>
-<a href="definitions.html#inlines">inline escape</a>,
-as in the following example:
-<br/>
-<span class="pre-in-pp">
-  .TAB_SET 1 0  1P  L
-  .TAB_SET 2 1P 20P L
-  .TAB 1
-  1.\c
+  Some more text\c
   .TN
-  The first rule of survival is &#8220;make and keep good friends.&#8221;
-</span>
-When output, the example will look like this:
-<br/>
-<span class="pre-in-pp">
-  1.  The first rule of survival is &#8220;make and keep good friends.&#8221;
+  \&\c
+  .TN
+  Yet more text
 </span>
-</p>
 
-<p class="tip-bottom">
-Conversely, if you did give a <kbd>QUAD</kbd> argument
-to TAB_SET or ST, the
-<kbd>\c</kbd> must not be used.
+<kbd>\&</kbd> is a zero-width, non-printing character that groff
+recognizes as valid input, hence meets the requirement for input
+text following <kbd>.TN</kbd>.
 </p>
 </div>
 
@@ -4305,7 +4158,7 @@
 <p>
 With mom&#8217;s indents, you can indent from the left, the right,
 or both margins.  In addition, mom provides temporary left indents
-(i.e. only one line is indented, as at the start of a paragraph)
+(ie only one line is indented, as at the start of a paragraph)
 and &#8220;hanging&#8221; left indents (the reverse of a temporary
 indent; the first line isn&#8217;t indented, subsequent lines are).
 </p>
@@ -4371,7 +4224,7 @@
   .IL
 </span>
 As you can see, once you&#8217;ve supplied a measure to an indent
-macro mom stores the value, obviating the need to repeat it on
+macro, mom stores the value, obviating the need to repeat it on
 subsequent invocations.  And mom doesn&#8217;t just store the
 measure&mdash;she hangs on to it tenaciously.  Arguments passed to
 IL, IR and IB are additive.  Consider the following:
@@ -4386,12 +4239,12 @@
   A second block of text...
   ...
   ...
-  .IR 2P    \"Indent right by an additional 2 picas (i.e. 4 picas)
+  .IR 2P    \"Indent right by an additional 2 picas (ie 4 picas)
   A third block of text...
   ...
   ...
 </span>
-The first block of text is right indented by 2 picas (i.e. the line
+The first block of text is right indented by 2 picas (ie the line
 length is shortened by 2 picas to 18 picas).  The second block of
 text, after IQ, is, as you&#8217;d expect, set to the full measure.
 The third block of text&mdash;the one to pay attention to&mdash;is
@@ -4456,9 +4309,7 @@
 length.  In many instances where indents might seem expedient,
 it&#8217;s better to use tabs, or actually change the left margin
 or the line length. Mom&#8217;s indenting macros are flexible and
-powerful, but easy to get tangled up in.  Personally, I don&#8217;t
-use them much, except for cutarounds and multi-level lists à la
-html, at which they excel.
+powerful, but easy to get tangled up in.
 </p>
 
 <div class="box-tip">
@@ -4771,13 +4622,21 @@
 
 <p>
 Generally speaking, you should invoke HI immediately prior to the
-line you want hung (i.e. without any intervening
+line you want hung (ie without any intervening
 <a href="definitions.html#controllines">control lines</a>).
 And because hanging indents affect only one line, there&#8217;s no
 need to turn them off.
 </p>
 
-<h4 id="num-lists" class="macro-id">Recipe: Numbered lists using hanging 
indents</h4>
+<div class="box-important">
+<p class="tip">
+<span class="important">IMPORTANT:</span> Unlike IL, IR and IB,
+measures given to HI are NOT additive.  Each time you pass a measure
+to HI, the measure is treated literally.
+</p>
+</div>
+
+<h4 id="num-lists" class="macro-id">Recipe: A numbered list using hanging 
indents</h4>
 
 <div class="box-tip" style="margin-top: -.5em; margin-bottom: -.5em;">
 <p class="tip">
@@ -4788,8 +4647,6 @@
 </div>
 
 <p style="margin-top: 1.5em;">
-Consider the following example:
-<br/>
 <span class="pre-in-pp">
   .PAGE 8.5i 11i 1i 1i 1i 1i
   .FAMILY  T
@@ -4799,8 +4656,8 @@
   .JUSTIFY
   .KERN
   .SS 0
-  .IL \w'\0\0.'  \"Indent left by 2 figure spaces and a period
-  .HI \w'\0\0.'  \"Hang first line back by 2 figure spaces and a period
+  .IL \w'\0\0.'
+  .HI \w'\0\0.'
   1.\0The most important point to be considered is whether the
   answer to the meaning of Life, the Universe, and Everything
   really is 42.  We have no-one&#8217;s word on the subject except
@@ -4833,22 +4690,18 @@
 </p>
 
 <p>
-Notice that subsequent invocations of <kbd>.HI</kbd> without a
-measure produce exactly the same effect.
+Notice that subsequent invocations of <kbd>.HI</kbd> don&#8217;t
+require a measure to be given.
 </p>
 
 <p>
-Paste the example above into a file and preview it with <kbd>groff
--mom -X &lt;filename&gt;</kbd> to see hanging indents in action.
-</p>
-
-<div class="box-important">
-<p class="tip">
-<span class="important">IMPORTANT:</span> Unlike IL, IR and IB,
-measures given to HI are NOT additive.  Each time you pass a measure
-to HI, the measure is treated literally.
+Paste the example above into a file and preview it with
+<br/>
+<span class="pre-in-pp">
+  pdfmom filename.mom | ps2pdf - filename.pdf
+</span>
+to see hanging indents in action.
 </p>
-</div>
 
 <!-- -IX- -->
 
@@ -4871,8 +4724,8 @@
 
 <div class="box-important">
 <p class="tip-top">
-<span class="important">IMPORTANT NOTE:</span> Formerly, the macro
-for quitting all indents was IX.  This usage is now deprecated, in
+<span class="important">IMPORTANT NOTE:</span> The original macro
+for quitting all indents was IX.  This usage has been deprecated in
 favour of IQ.  IX will continue to behave as before, but mom will
 issue a warning to stderr indicating that you should update your
 documents.

Index: momdoc/using.html
===================================================================
RCS file: /sources/groff/groff/contrib/mom/momdoc/using.html,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- momdoc/using.html   22 Feb 2011 19:42:30 -0000      1.16
+++ momdoc/using.html   31 Aug 2012 22:50:00 -0000      1.17
@@ -2,8 +2,9 @@
 <!--
 This file is part of groff, the GNU roff type-setting system.
 
-Copyright (C) 2004, 2005, 2006, 2009, 2010, 2011 Free Software Foundation, Inc.
-Written by Peter Schaffter.
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
@@ -14,6 +15,7 @@
 A copy of the Free Documentation License is included as a file called
 FDL in the main directory of the groff source package.
 -->
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
 <html xmlns="http://www.w3.org/1999/xhtml";>
 
@@ -39,13 +41,16 @@
 
 <h1 id="using" class="docs">Using mom</h1>
 
-<div style="text-align: center;">
+<div style="text-align: left; margin-left: 33%">
 <ul class="no-enumerator" style="margin-left: -2.5em;">
-  <li ><a href="#using-intro">Introduction</a></li>
-  <li ><a href="#using-macros">How to input mom&#8217;s macros</a></li>
-  <li ><a href="#using-previewing">How to preview documents</a></li>
-  <li ><a href="#using-saving">Saving documents</a></li>
-  <li ><a href="#using-printing">Printing documents</a></li>
+  <li><a href="#using-intro">Introduction</a></li>
+  <li><a href="#using-macros">How to input mom&#8217;s macros</a></li>
+  <li><a href="#viewing">Processing and viewing documents</a>
+    <ul>
+    <li class="item"><a href="#pdf">Mom and PDF</a></li>
+    <li class="item"><a href="#pdfmom">pdfmom</a></li>
+  </ul></li>
+  <li><a href="#previewing">Automatic previewing of documents</a></li>
 </ul>
 </div>
 
@@ -56,40 +61,36 @@
 <p>
 As explained in the section
 <a href="intro.html#top">What is mom?</a>,
-mom can be used in two ways: for straight typesetting or
-for document processing.  The difference between the two
-is that in straight typesetting, every macro is a literal
-typesetting instruction that determines precisely how text
-following it will look.  Document processing, on the other
-hand, uses markup tags (e.g. <kbd>.PP</kbd> for
-paragraphs, <kbd>.HEAD</kbd> for heads,
-<kbd>.FOOTNOTE</kbd> for footnotes, etc.) that make a
-lot of typesetting decisions automatically.
+mom can be used in two ways: for straightforward typesetting or for
+document processing.  The difference between the two is that in
+straightforward typesetting, every macro is a literal instruction
+that determines precisely how text following it will look.  Document
+processing, on the other hand, uses markup tags (e.g. <kbd>.PP</kbd>
+for paragraphs, <kbd>.HEADING</kbd> for different levels of heads,
+<kbd>.FOOTNOTE</kbd> for footnotes, etc.) that perform typesetting
+operations automatically.
 </p>
 
 <p>
 You tell mom that you want to use the document processing macros
 with the
 <a href="docprocessing.html#start"><kbd>START</kbd></a>
-macro, explained below.  After <kbd>START</kbd>,
-mom determines the appearance of text following the markup tags
-automatically, although you, the user, can easily change how mom
-interprets the tags.  This gives you nearly complete control
-over document design.  In addition, the typesetting macros, in
-combination with document processing, let you meet all sorts of
-typesetting needs that just can&#8217;t be covered by &#8220;one
-macro fits all&#8220; markup tags.
+macro.  After <kbd>START</kbd>, mom determines the appearance of
+text following the markup tags automatically, although you, the
+user, can easily change how the tags are interpreted.
 </p>
 
 <h2 id="using-macros" class="docs">How to input mom&#8217;s macros</h2>
 
 <p>
-Regardless of which way you use mom, the following apply:
+Regardless of whether you&#8217;re preparing a term paper or making a
+flyer for your lost dog, the following apply.
 </p>
 
 <ol style="margin-top: -.5em; margin-bottom: -.5em;">
   <li>
     You need a good text editor for inputting mom files.
+    <br/>
     <span style="display: block; margin-top: .25em; margin-bottom: .5em;">
     I cannot recommend highly enough that you use an editor that
     lets you write syntax highlighting rules for mom&#8217;s
@@ -97,20 +98,42 @@
     <a href="definitions.html#inlines">inline escapes</a>.
     Simply colourizing macros and inlines to half-intensity can be
     enough to make text stand out clearly from formatting commands.
+    Mom herself comes with a complete set of syntax highlighting
+    rules for the vim editor.
     </span>
   </li>
   <li>
-    All mom&#8217;s macros begin with a period (dot) and must be
-    entered in upper case (capital) letters.
+    Macros begin with a period (dot) at the left margin of your text
+    editor's screen, and must be entered in upper case (capital)
+    letters.
   </li>
   <li>
     Macro
     <a href="definitions.html#arguments">arguments</a>
     are separated from the macro itself by spaces.  Multiple
     arguments to the same macro are separated from each
-    other by spaces.  Any number of spaces may be used.  All
-    arguments to a macro must appear on the same line as the
+    other by spaces.  Any number of spaces may be used.  
+  </li>
+  <li>
+    Arguments to a macro must appear on the same line as the
     macro.
+    <br/>
+    <span style="display: block; margin-top: .25em; margin-bottom: .5em;">
+    If the argument list is very long, you may use the
+    backslash character (<kbd>\</kbd>) to break the line visually.
+    From groff&#8217;s point of view, the backslash and newline are
+    invisible.  Thus, for example,
+    <span class="pre" style="margin-bottom: -2.25em">
+  .HEADING_STYLE 1 FAMILY Garamond FONT B SIZE +2
+    </span>
+    and
+    <span class="pre" style="margin-bottom: -2.25em">
+  .HEADING_STYLE 1 \
+   FAMILY Garamond \
+   FONT B \
+   SIZE +2
+    </span>
+    are exactly equivalent.
   </li>
   <li>
     Any argument (except a
@@ -131,21 +154,18 @@
   </li>
   <li>
     <a href="definitions.html#stringargument">String arguments</a>,
-    in the sense that the term is used in this manual, must be
-    surrounded by double-quotes
-    (<kbd>"&lt;text of string&gt;"</kbd>).  Multiple
-    string arguments are separated from each other by spaces (each
-    argument surrounded by double-quotes, of course).
-  </li>
-  <li>
-    If a string argument, as entered in your text editor, becomes
-    uncomfortably long (i.e. runs longer than the visible portion of
-    your screen or window), you may break it into two or more lines
-    by placing the backslash character (<kbd>\</kbd>)
-    at the ends of lines to break them up, like this:
+    in the sense of this manual, must be surrounded by double-quotes
+    (eg <kbd>"text"</kbd>).  Multiple
+    string arguments are separated from each other by spaces (with
+    each argument surrounded by double-quotes).
+    <br/>
+    <span style="display: block; margin-top: .25em; margin-bottom: .5em;">
+    If a string argument becomes
+    uncomfortably long, you may break it into two or more lines
+    with the backslash character.
     <span class="pre">
   .SUBTITLE "An In-Depth Consideration of the \
-  Implications of Forty-Two as the Meaning of Life, \
+  Implications of Forty-Two as the Answer to Life, \
   The Universe, and Everything"
     </span>
   </li>
@@ -154,136 +174,128 @@
 <div class="box-tip">
 <p class="tip">
 <span class="tip">Tip:</span>
-It&#8217;s important that formatted documents be easy to
-read/interpret when you&#8217;re looking at them in a text editor.
-One way to achieve this is to group macros that serve a similar
-purpose together, and separate them from other groups of macros
-with a blank comment line.  In groff, that&#8217;s done with
-<kbd>\#</kbd> on a line by itself.  Consider the
-following, which is a template for starting the chapter of a book.
+It&#8217;s important that your documents be easy to read and
+understand in a text editor.  One way to achieve this is to group
+macros that serve a similar purpose together, and separate them from
+other groups of macros with a comment line.  In groff, that&#8217;s
+done with <kbd>\#</kbd> (backslash-pound) or <kbd>.\"</kbd>
+(period-backslash-doublequote) on a line by itself.  Either
+instructs groff to ignore the remainder of the line, which may or
+may not contain text.  Consider the following, which is a template
+for starting the chapter of a book.
 <br/>
 <span class="pre-in-pp">
+  \# Reference/meta-data
   .TITLE   "My Pulitzer Novel"
   .AUTHOR  "Joe Blow"
   .CHAPTER  1
-  \#
+  \# Template
   .DOCTYPE    CHAPTER
   .PRINTSTYLE TYPESET
-  \#
+  \# Type style
   .FAM     P
   .PT_SIZE 10
   .LS      12
   \#
   .START
 </span>
+You may also, if you wish, add a comment to the end of a line with
+<kbd>\"</kbd> (no period), like this:
+<br/>
+<span class="pre-in-pp">
+  .FAMILY P \" Maybe Garamond instead?
+</span>
 </p>
 </div>
 
-<h2 id="using-previewing" class="docs">How to preview documents</h2>
-
-<p>
-Other than printing out hard copy, there are two well-established
-methods for previewing your work.  Both assume you have a working
-X server.
-</p>
+<h2 id="viewing" class="docs">Processing and viewing documents</h2>
 
 <p>
-Groff itself comes with a quick and dirty previewer called
-gxditview. Invoke it with:
+The most basic command line usage for processing a file formatted
+with the mom macros is
 <br/>
 <span class="pre-in-pp">
-  groff -X -mom &lt;filename&gt;
+  groff -mom filename.mom &gt; filename.ps
 </span>
-It&#8217;s not particularly pretty, doesn&#8217;t have many
-navigation options, requires a lot of work if you want to use
-other than the standard groff PostScript fonts, and occasionally has
-difficulty accurately reproducing some of mom&#8217;s macro effects
-(<a href="goodies.html#smartquotes">smartquotes</a>
-and
-<a href="goodies.html#leader">leaders</a>
-come to mind).  What it does have going for it is that it&#8217;s
-fast and doesn&#8217;t gobble up system resources.
+which processes the .mom file and dumps the output into a
+viewable/printable PostScript file.
 </p>
 
+<h3 id="pdf" class="docs">Mom and PDF</h3>
+
 <p>
-A surer way to preview documents is with gv (ghostview).  This
-involves processing documents with groff and directing the default
-PostScript output to a file, like this:
-<br/> 
-<span class="pre-in-pp">
-  groff -mom &lt;filename&gt; &gt; &lt;filename&gt;.ps
-</span>
-You can then then open the ps file in gv.
+Adobe's Portable Document Format (PDF) has largely supplanted
+PostScript, of which it is a subset, as the standard for typeset
+documents.  While printed versions of documents in either format
+will be identical, PDF documents, when viewed at the screen, may
+also contain clickable links and a number of other special features.
 </p>
 
-<div class="box-tip">
-<p class="tip">
-<span class="tip">Tip:</span>
-I&#8217;ve set up my editor (vi[m]) to do seamless, automatic
-previewing.  Whenever I&#8217;m working on a document that
-needs previewing/checking, I fire up gv with the &#8220;Watch
-File&#8220; option turned on.  The first time I want to look at
-the file, I tell vim (via a keymapping) to process it with groff
-and send it to a PostScript file:
+<p>
+As of version 2.0, mom supports full PDF integration.  The creation
+and processing of mom files into PostScript documents remains
+unchanged from 1.x, but the expected and recommended format of final
+documents is now PDF.
+
+<p>
+The manual,
+<a href="http://www.schaffter.ca/mom/pdf/mom-pdf.pdf";><span 
class="book-title">Producing PDFs with groff and mom</span></a>,
+explains and demonstrates the PDF-specific macros that are available
+in mom, as well as the use of <strong>pdfmom</strong>, the
+recommended way to process mom files.
+</p>
+
+<h4 id="pdfmom" class="docs">pdfmom</h4>
+
+<p>
+Groff provides more than one way to generate PDF documents,
+but when processing files formatted with the mom macros,
+<strong>pdfmom</strong> is the recommended and most robust way to do
+it:
 <br/>
 <span class="pre-in-pp">
-  groff -mom &lt;filename&gt; &gt; &lt;filename&gt;.ps
+  pdfmom filename.mom &gt; filename.pdf
 </span>
-I then open the file inside gv.  Ever after, when I want to look at
-any changes I make, I simply tell vim to work its magic again.
-The Watch File option in gv registers that the PostScript file has
-changed, and automatically loads the new version.  <i>Voilà!</i>&mdash;instant
-previewing.
+<strong>pdfmom</strong> is a wrapper around groff, and accepts all
+groff's command line options as listed in the groff manpage.
+Full usage is explained in the manual,
+<a href="http://www.schaffter.ca/mom/pdf/mom-pdf.pdf";><span 
class="book-title">Producing PDFs with groff and mom</span></a>.
 </p>
-</div>
-
-<h2 id="using-saving" class="docs">Saving documents</h2>
 
 <p>
-By default, groff dumps its PostScript output to stdout (your
-terminal screen) so you have to say where you want it to go if you
-want to save it to a file.  The most straightforward way to do
-this is:
+PDF links in a document, including linked entries in the
+Table of Contents, are identified by colour.  When printing
+documents with links, you will most likely not want the link
+text coloured.  The groff option, <kbd>-c</kbd>, disables colour
+throughout a document; thus, when preparing a document for printing,
+you should use:
 <br/>
 <span class="pre-in-pp">
-  groff -mom &lt;filename&gt; &gt; &lt;filename&gt;.ps
+  pdfmom -c filename.mom  &gt; filename.pdf
 </span>
-which drops the output in a PostScript file.  Alternatively, you
-might prefer to save it as a pdf file, in which case you'd do:
+<strong>pdfmom</strong> tends to produce large files.  You may
+reduce their size by piping them through ps2pdf:
 <br/>
-<span class="pre">
-  groff -mom &lt;filename&gt; | ps2pdf - &lt;filename&gt;.pdf
+<span class="pre-in-pp">
+  pdfmom -c filename.mom  | ps2pdf - filename.pdf
 </span>
+Be aware, though, that files piped through ps2pdf will lose some pdf
+metadata, notably the document window title set with PDF_TITLE.
 </p>
 
-<h2 id="using-printing" class="docs" style="margin-top: 1.5em;">Printing 
documents</h2>
+<h2 id="previewing" class="docs">Automatic previewing of documents</h2>
 
 <p>
-You can process and print documents from the command line without
-saving them to .ps or .pdf files first.  Here are two common ways
-to do it:
-
-<span class="pre">
-  groff -mom -l &lt;filename&gt;
-  groff -mom &lt;filename&gt; | lpr
-</span>
-</p>
-
-<p style="margin-top: -1.5em;">
-In the first, the <kbd>-l</kbd> option tells groff
-to send the output to your printer.  In the second, you&#8217;re
-doing the same thing, except you&#8217;re telling groff to
-<i>pipe</i> the output to your printer spooler.  Basically,
-they&#8217;re the same thing.  The advantage to the second is that
-you can pass additional options to lpr, for example to send
-the output to a particular printer, like this:
-<br/>
-<span class="pre-in-pp">
-  groff -mom &lt;filename&gt; | lpr -P &lt;printer_name&gt;
-</span>
+Most PDF viewers have a &#8220;Watch File&#8221; option, which
+automaticaly updates a displayed document whenever there's a change.
+This is useful when preparing documents that require judgment calls.
+I recommend creating a keymapping in your text editor that both
+saves the mom file and processes it with <strong>pdfmom</strong>.
+The displayed PDF then automatically reflects whatever changes you
+save to the mom file.
 </p>
 
-<div class="rule-long" style="margin-top: -.5em;"><hr/></div>
+<div class="rule-long"><hr/></div>
 
 <!-- Navigation links -->
 <table style="width: 100%; margin-top: 12px;">

Index: examples/mom-pdf.mom
===================================================================
RCS file: examples/mom-pdf.mom
diff -N examples/mom-pdf.mom
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ examples/mom-pdf.mom        31 Aug 2012 22:49:58 -0000      1.1
@@ -0,0 +1,595 @@
+.\" Reference macros (metadata)
+.TITLE     "Producing PDFs" "with groff and mom"
+.PDF_TITLE "\*[$TITLE]
+.AUTHOR    "\v'-.5v'\*[UP 4p]Deri James" \
+           "\v'-.5v'\*[UP 8p]and" \
+           "\v'-.5v'\*[UP 11p]Peter Schaffter"
+.MISC      "This file is part of groff." \
+           ".sp .25v" \
+           "groff is free software; you can redistribute it" \
+           "and\*[FU3]/or modify it under the terms of the GNU" \
+           "General Public License as published by the" \
+           "Free Software Foundation, either version 3" \
+           "of the License, or (at your option) any later" \
+           "version." \
+           ".sp .25v" \
+           "You should have received a copy of the GNU" \
+           "General Public License along with this program." \
+           "If not, see:" \
+           ".sp .25v" \
+           ".IL 2P" \
+           ".PDF_WWW_LINK http://www.gnu.org/licenses/"; \
+           ".IQ CLEAR"
+.COPYRIGHT "20\*[BU3]1\*[BU2]2 Deri James and Peter Schaffter
+.ATTRIBUTE_STRING ""  \" Don't print 'by'
+.PDF_BOOKMARKS_OPEN 2
+.\" Cover and page header
+.COVER       TITLE AUTHOR COPYRIGHT MISC
+.HEADER_LEFT "James, Schaffter"
+.\" Page, style, formatting
+.PRINTSTYLE TYPESET
+.PAPER     A4
+.L_MARGIN   2.5c
+.R_MARGIN   2.5c
+.B_MARGIN   2.5c
+.\"
+.FAM      H
+.FT       R
+.PT_SIZE  10.5
+.AUTOLEAD 3
+.PARA_INDENT 0  \" Because we're spacing paragraphs.
+.\"
+.COVER_LEAD     +3.5
+.DOCHEADER_LEAD +3.5
+.\" Color for code snippets
+.NEWCOLOUR dark-grey RGB #343434
+.\" Make QUOTE look like CODE
+.QUOTE_FAMILY C
+.QUOTE_FONT   B
+.QUOTE_SIZE   +1.5
+.QUOTE_COLOR  dark-grey
+.QUOTE_INDENT 9p
+.\"
+.CODE_FONT  B
+.CODE_SIZE  115
+.CODE_COLOR dark-grey
+.CONDENSE   87
+.\"
+.HEADING_STYLE 1 NUMBER FONT B SIZE +1 BASELINE_ADJUST \n[.v]/5
+.HEADING_STYLE 2 NUMBER FONT I SIZE +.25 BASELINE_ADJUST \n[.v]/5
+.\"
+.FOOTNOTE_SIZE -1
+.\" Character definitions for program names, opts, etc.
+.char \[ghostscript]      \*[BD]ghostscript\*[PREV]
+.char \[groff]            \*[BD]groff\*[PREV]
+.char \[gropdf]           \*[BD]gropdf\*[PREV]
+.char \[grops]            \*[BD]grops\*[PREV]
+.char \[man]              \*[BD]man\*[PREV]
+.char \[-mom]             \*[BD]-mom\*[PREV]
+.char \[mom]              \*[BD]mom\*[PREV]
+.char \[-mpdfmark]        \*[BD]-mpdfmark\*[PREV]
+.char \[ms]               \*[BD]ms\*[PREV]
+.char \[pdfmom]           \*[BD]pdfmom\*[PREV]
+.char \[pdfroff]          \*[BD]pdfroff\*[PREV]
+.char \[-P-e]             \*[BD]-P-e\*[PREV]
+.char \[-P-p<papersize>]  \*[BD]-P-p<papersize>\*[PREV]
+.char \[ps2pdf]           \*[BD]ps2pdf\*[PREV]
+.char \[psselect]         \*[BD]psselect\*[PREV]
+.char \[-T]               \*[BD]-T\*[PREV]
+.char \[-Tpdf]            \*[BD]-Tpdf\*[PREV]
+.char \[-Tps]             \*[BD]-Tps\*[PREV]
+.\" Strings for inline code
+.ds cod  "\E*[CODE]\&\E*[COND]
+.ds codx "\E*[CONDX]\E*[CODE off]\&
+.\" Paragraph spacing
+.de PP2
+. ALD .3v
+. PP
+..
+.\" Wrapper around QUOTE
+.de COD
+. QUOTE
+. nop \*[COND]\\$*\*[CONDX]
+. QUOTE OFF
+..
+.\" Note box
+.de BOX-NOTE
+. ie \\n[#NUM_ARGS]=1 .DBX .5 0 \\n[.l]u \\$1
+. el .DBX .5 0 \\$1 \\$2
+. ALD 15p
+. IB 6p
+..
+.\" Table of contents
+.TOC_PADDING 2
+.SPACE_TOC_ITEMS
+.AUTO_RELOCATE_TOC
+.TOC_ENTRY_STYLE 2 FONT I
+.TOC_LEAD 14
+.\"
+.DOCHEADER_ADVANCE 4.5c \" Begin this distance down from top of page
+.\"
+.START
+.\"
+.HEADING 1 NAMED intro "Introduction"
+.PP
+.RW .12
+PDF documents are intended to be "electronic paper,\*[BU6]" and, as
+such, take advantage of the digital medium in ways that PostScript
+documents do not.  Chief amongst these are clickable links that
+point to named destinations, either within the documents themselves
+.PDF_LINK internal PREFIX ( SUFFIX ) "internal links"
+or to remote web pages
+.PDF_LINK external PREFIX ( SUFFIX ), "external links"
+and the generation of a clickable document outline that appears in
+the Contents panel of most PDF viewers.
+.PP2
+.RW .01
+Using \[groff] and \[mom] to produce PDF documents results in the
+automatic generation of clickable document outlines (discussed
+below,
+.PDF_LINK outline SUFFIX ), +
+and, if the \*[cod]TOC\*[codx] macro is included in the source file,
+entries in the printable table of contents can be clicked on as well
+when the document is viewed at the screen (see
+.PDF_LINK toc SUFFIX ). +
+.RW 0
+.HEADING 1 NAMED generating "Using groff to generate PDF files"
+.PP
+Groff provides more than one way to generate PDF documents from
+files formatted with the \[mom] macros.  One is to call \[groff]
+directly, either with
+.COD "groff [-Tps] -mom -m pdfmark doc.mom | ps2pdf - doc.pdf
+which pipes output from the \[grops] PostScript driver through
+\[ps2pdf], or
+.COD "groff -Tpdf -mom doc.mom > doc.pdf
+which uses the native PDF driver, \[gropdf].  Alternatively, one may
+call the wrapper
+.COD "pdfroff -mom -mpdfmark --no-toc doc.mom > doc.pdf
+A fourth, preferred method is to use
+.PDF_LINK pdfmom SUFFIX , "\[pdfmom]"
+which is strongly recommended since it implements the full range
+of PDF features available in \[mom].
+.COD "pdfmom doc.mom > doc.pdf
+One reason to prefer using the native PDF driver (via \[pdfmom] or
+\[-Tpdf]) is that papersizes set within mom source files (see
+.PDF_WWW_LINK 
http://www.schaffter.ca/mom/momdoc/typesetting.html#page-setup-intro SUFFIX ) \
+  "paper and page setup macros"
+do not require a corresponding \[-P-p<papersize>] flag on the
+command line.
+.PP2
+There are other minor differences between the methods, discussed
+.PDF_LINK pdf-diff SUFFIX . "here"
+.RW 0
+.HEADING 1 NAMED links "Creating PDF links with mom"
+.PP
+Often, but not always, links in the body of a PDF document point
+to headings elsewhere in the same document.  Creating these links
+is a simple process.  First, identify the places to link to
+("destinations"), then link to them from any place in the document.
+.NO_SHIM
+.HEADING 2 NAMED naming "Creating destination points at headings"
+.PP
+The first step in creating links to a heading is to give the
+heading a unique destination name.  With mom, this is done by
+adding \*[cod]NAMED\|<id>\*[codx] to the HEADING macro, where
+\*[cod]<id>\*[codx] is a unique identifier for the heading.  For
+example,
+.PDF_TARGET intro-ex
+.COD "\&.HEADING 1 NAMED intro \[dq]Introduction\[dq]"
+would, in addition to printing the head in the body of the document,
+identify the introduction by the unique id, "intro"\*[BU6].  This
+id, or name, can then be used to create links to the introduction
+from any part of the document.
+.PP2
+Furthermore, \*[cod]NAMED\|<id>\*[codx] stores the text of the
+heading for use later on when linking to it (see
+.PDF_LINK internal SUFFIX ). +
+If headings are being numbered, the heading number is included.
+.HEADING 2 NAMED target  "Creating destination points at arbitrary locations"
+.PP
+Any part of a document can be a link destination, not just headings.
+For example, say you create a table that needs to be referred to
+from other parts of the document.  You'd identify the location of
+the table by placing
+.COD "\&.PDF_TARGET <id> \[dq]<text>\[dq]"
+just above the table in the source file.  As with
+\*[cod]HEADING\*[codx], \*[cod]<id>\*[codx] is any unique name.
+\*[cod]<text>\*[codx] is optional. \*[cod]<id>\*[codx] can now be linked
+to from anywhere in the document.
+.HEADING 2 NAMED internal "Creating internal links"
+.PP
+Internal links are clickable text areas that allow you to jump to
+named destinations within a document.  (See
+.PDF_LINK external "here"
+for a description of external links.)
+.PP2
+Internal links are created with the macro \*[cod]PDF_LINK\*[codx],
+which takes the form
+.COD "\&.PDF_LINK <id> [PREFIX <text>] [SUFFIX <text>] \
+\[dq]<hotlink text>\[dq]"
+where \*[cod]<id>\*[codx] is a named destination point elsewhere in
+the document (see
+.PDF_LINK naming +
+and
+.PDF_LINK target SUFFIX ). +
+.PP2
+\*[cod]PREFIX\|<text>\*[codx] and \*[cod]SUFFIX\|<text>\*[codx], both or
+either of which are optional, are printed around the clickable area
+but do not form part of the link itself.
+.PP2
+\*[cod]<hotlink text>\*[codx] is the text that should be clickable,
+identifiable in the PDF document by the colour assigned to links
+(see
+.PDF_LINK colour SUFFIX ). +
+.PDF_TARGET expando
+.PP2
+If the hotlink text ends in \*[cod]\[dq]*\[dq]\*[codx]\*[BU9],
+the asterisk is replaced by the text of the destination
+point, assuming it's a heading.  If the hotlink text ends in
+\*[cod]\[dq]+\[dq]\*[codx]\*[BU9], the replacement text is surrounded
+by quotes.
+.PP2
+Using our
+.PDF_LINK intro-ex SUFFIX , "HEADING example"
+.RW .1
+above, the following invocation of \*[cod]PDF_LINK\*[codx] would
+produce a click\%able link to the introduction:
+.COD "\&.PDF_LINK intro PREFIX ( SUFFIX ). \[dq]see: +\[dq]"
+.RW 0
+In the text, the link would look like this:
+.PDF_LINK intro PREFIX ( SUFFIX ). "see: +"
+.HEADING 2 NAMED external "Creating external links"
+.PP
+External links are clickable text areas whose destination is a
+URL.  Clicking on them causes a browser window to pop up with the
+destination address.
+.PP2
+The format of the macro to create external links is similar to the
+one for creating internal links links links.
+.COD "\&.PDF_WWW_LINK <url> [PREFIX <text>] [SUFFIX <text>] [\[dq]<hotlink 
text>\[dq]]"
+\*[cod]<url>\*[codx] is any valid URL, usually a web address;
+\*[cod]PREFIX\|<text>\*[codx] and \*[cod]SUFFIX\|<text>\*[codx] have
+exactly the same meaning.
+.PP2
+.RW .1
+If no hotlink text is given, then \*[cod]<url>\*[codx] is
+used as the text.  If hotlink text is given and ends in
+\*[cod]\[dq]*\[dq]\*[codx]\*[BU9], the asterisk is replaced by the
+URL.  If it ends in \*[cod]\[dq]+\[dq]\*[codx]\*[BU9], the URL is
+surrounded by quotes.  As an example,
+.RW 0
+.COD "\&.PDF_WWW_LINK http://www.schaffter.ca/mom/momdoc/toc.html
+would open mom's online documentation at
+.PDF_WWW_LINK http://www.schaffter.ca/mom/momdoc/toc.html SUFFIX "." 
+The same, with \*[cod]\[dq]here\[dq]\*[codx] supplied as
+hotlink text, lets you click
+.PDF_WWW_LINK http://www.schaffter.ca/mom/momdoc/toc.html "here"
+instead.
+.HEADING 2 NAMED colour  "Assigning a colour to links"
+.PP
+The colour of links is set with
+.COD "\&.PDF_LINK_COLOR <xcolor> | <newcolor> | <r g b> | <#rrggbb>
+where \*[cod]<xcolor>\*[codx] or \*[cod]<newcolor>\*[codx] are the names
+of colours already initialized with
+.PDF_WWW_LINK http://www.schaffter.ca/mom/momdoc/color.html#xcolor "XCOLOR"
+or
+.PDF_WWW_LINK http://www.schaffter.ca/mom/momdoc/color.html#newcolor SUFFIX . 
"NEWCOLOR"
+If you prefer to define a new colour (using the RGB colour scheme),
+enter it either as 3 numbers between
+0.0 \*[UP 1p]\[->]\*[DOWN 1p] 1\*[BU4].0
+or as a 6 character hex string.  Thus
+.SP .5v
+\*[FWD 6p]\*[cod].PDF_LINK_COLOR #ff0000\*[codx]
+\ \*[SIZE -.5]and\*[SIZE]\ \"
+\*[cod].PDF_LINK_COLOR 1.0 0 0\*[codx]
+.SP .5v
+both lead to mom using
+.PDF_LINK_COLOR 1 0 0
+.PDF_LINK colour red
+.PDF_LINK_COLOR
+links.
+.PP2
+The default colour can be restored by calling
+\*[cod]PDF_LINK_COLOR\*[codx] with no parameter.
+.FLOAT
+.JUSTIFY
+.BOX-NOTE 3P
+\*[BD]Note:\*[PREV]
+The decimal scheme for creating colours must be used if a file is to
+be processed with
+\[oq]\[groff]\~\[-Tps]\~\[-mpdfmark]\[cq],
+\[oq]\[pdfroff]\[cq], or
+\[oq]\[pdfmom]\~\[-Tps]\[cq].
+.IBQ
+.FLOAT off
+.NO_SHIM off
+.HEADING 1 NAMED outline "The PDF Outline"
+.PP
+Most PDF viewers provide a panel that displays a document's outline,
+similar to a table of contents.  Clicking on an entry navigates
+directly to the appropriate place in the document.
+.PP2
+Mom generates PDF outlines the same way she populates
+her own table of contents: by intercepting calls to the
+\*[cod]HEADING\*[codx] macro, as well as to the various title
+and chapter macros used in namimg documents, and allocating each a
+hierarchic level.
+.PP2
+Covers, titles/chapters, and the table of contents are all
+assigned to level 1\*[BU5].  Subsequent headings are assigned to
+n\*[UP 1p]+\*[DOWN 1p]\*[BU4]1, where n is the level given to
+\*[cod]HEADING\*[codx].
+.PP2
+.RW .22
+The PDF outline can sensibly recover from skipped or omitted heading
+levels; the printed table of contents cannot.  Users are therefore
+advised to use headings in logical order, not for typographic
+effects.
+.RW 0
+.HEADING 2 NAMED open-close "Opening and closing levels
+.PP
+A level is said to be open if one or more levels beneath it is
+visible in the PDF outline.  Closed \%levels have at least one level
+beneath them that is not visible unless the closed link is clicked.
+It is common for only the first two levels to be open so the outline
+doesn't look cluttered.
+.PP2
+To establish which levels should be open by default when a document
+loads, use
+.COD "\&.PDF_BOOKMARKS_OPEN n
+where \*[cod]n\*[codx] is a number specifying at which level all
+subsequent ones should be closed.
+.PP2
+If, at any point in the document, you specify
+.COD "\&.PDF_BOOKMARKS_OPEN NO  \e\[dq] or any other text argument
+then all subsequent bookmarks will be closed until
+\*[cod]PDF_BOOKMARKS_OPEN\*[codx] opens them again.
+.HEADING 2 NAMED disabling "Suspending/disabling collection of outline entries
+.PP
+Suspending the collection of entries for the PDF outline is
+accomplished with
+.COD "\&.PDF_BOOKMARKS OFF
+Mom's default is to collect entries, so if the command is placed at
+the start of a document, it \%disables entry collection completely.
+Elsewhere, it suspends collection until you re-enable it with
+.COD "\&.PDF_BOOKMARKS  \e\[dq] i.e. with no parameter
+.HEADING 2 NAMED pdf:title "The PDF window title"
+.PP
+While not strictly part of the PDF outline, the title of a document
+can be displayed as the document viewer's window title.  The macro
+to accomplish this is
+.COD "\&.PDF_TITLE\ \[dq]<window title>\[dq]
+It can take any text, so the viewer window title need not be the
+same as the document's title.
+.FLOAT
+.JUSTIFY
+.BOX-NOTE 4P+8p
+\*[BD]Note:\*[PREV] The macro, \*[cod]DOC_TITLE\*[codx], always
+invokes \*[cod]PDF_TITLE\*[codx].  If this is not what you want, you
+can remove the window title by issuing
+.COD ".PDF_TITLE \[dq]\[dq] \e\[dq] ie. with a blank argument
+.IBQ
+.FLOAT off
+.NO_SHIM
+.HEADING 1 NAMED toc "Tables of Contents"
+.RLD .5v
+.HEADING 2 NAMED toc:gen "Generating a Table of Contents 
+.PP
+.RW .1
+To generate a printable Table of Contents for any document, simply
+insert the macro, \*[cod]TOC\*[codx], as the last line of the source
+file. (Formatting of the printable Table of Contents is discussed in
+detail in the
+.PDF_WWW_LINK \
+http://www.schaffter.ca/mom/momdoc/tables-of-contents.html#top \
+SUFFIX ). "mom documentation"
+When the file is processed and loaded in a viewer, entries in the
+Table of Contents will be clickable links.
+.RW 0
+.PP2
+Whichever link colour is active at the end of the document, prior to
+\*[cod]TOC\*[codx], will be used for the \%Table of Contents
+links.
+.HEADING 2 NAMED toc:pos  "Positioning the Table of Contents"
+.PP
+If \[groff]'s PostScript device (\[-Tps]) is used to process a mom
+file, the Table of Contents is printed at the end of the document.
+When this is not desirable, the PostScript output from \[groff]
+must be processed with \[psselect] in order to place the TOC in the
+preferred location.
+.PP2
+When using mom and \[groff]'s native pdf device (via \[pdfmom] or
+\[groff] \[-Tpdf]), positioning of the Table of Contents can be done
+within the source file.
+.PP2
+The command to control the placement of the TOC is
+.COD "\&.AUTO_RELOCATE_TOC [<position>]
+where the optional \*[cod]<position>\*[codx] can be one of these
+keywords:
+.LEFT
+.IL 2P
+.SP .25v
+\*[SIZE -.7]TOP\*[FU2]\*[UP .5p]\c
+.FOOTNOTE
+\*[BD]Note:\*[PREV] Documents without a COVER or DOC_COVER require
+the \*[cod]TOP\*[codx] argument.
+.FOOTNOTE off
+\*[IT]\*[SIZE +.2]\
+(ie. at the very start of the document)\*[SIZE -.2]\*[PREV]
+BEFORE_DOCCOVER
+AFTER_DOCCOVER
+BEFORE_COVER
+AFTER_COVER\*[SIZE]
+.SP .25v
+.ILQ
+.JUSTIFY
+It is normally not necessary to supply a keyword, since
+\*[cod]AUTO_RELOCATE_TOC\*[codx] places the TOC after the DOC_COVER,
+if there is one, or the first COVER when no DOC_COVER is present.
+.NO_SHIM off
+In rare instances where it is desirable to place the TOC somewhere
+else in the document, there are two low-level commands,
+.SP .5v
+\*[FWD 6p]\*[cod].TOC_BEFORE_HERE\*[codx]
+\ \*[SIZE -.5]and\*[SIZE]\ \"
+\*[cod].TOC_AFTER_HERE\*[codx]
+.SP .5v
+which place the TOC either before or after the current page.
+.PP2
+These last two commands have a small catch: although the TOC will
+appear where specified, the \%"Contents" entry in the PDF outline,
+which observes a hierarchy of levels, will assign the TOC to
+level\~\*[BU4]1\*[BU4], possibly disrupting the visual ordering of
+levels in the outline.
+.NO_SHIM
+.HEADING 1 NAMED simplify "pdfmom: Simplifying PDF output"
+.PP
+As explained in the section
+.PDF_LINK generating SUFFIX , *
+.RW .15
+there are two established methods
+.RW 0
+for creating PDF files with \[groff]: the original method, ie.
+passing the \[-Tps] and \[-mpdfmark] options to \[groff] (or using
+\[pdfroff], which does this for you); or the newer \[-Tpdf], which
+produces PDF files natively.
+.HEADING 2 NAMED fwd:ref "The problem of forward references"
+.PP
+.EW .2
+Both methods encounter difficulties when dealing with forward
+references; that is, when a link \*[IT]\%earlier\/\*[PREV] in a
+document refers to a destination \*[IT]later\/\*[PREV] in the
+document and the link text terminates
+.EW 0
+with one of the expandos,
+\*[cod]\[dq]*\[dq]\*[codx] or \*[cod]\[dq]+\[dq]\*[codx]
+(explained
+.PDF_LINK expando SUFFIX ). "here"
+Mom doesn't know what text to put in the expando because it has not
+yet been defined.  This means that \[groff] must be run multiple
+times to find the unknown text.
+.PP2
+.EW .2
+The program \[pdfroff] exists to handle these multiple runs, but it
+imposes some limitations on the PDF features available with \[mom].
+.EW 0
+.NO_SHIM off
+.HEADING 2 NAMED pdfmom "pdfmom"
+.PP
+\[pdfmom] performs the same function as \[pdfroff], and is the
+preferred, trouble-free way to generate PDF documents from a mom
+source file.  Like \[pdfroff], it is a frontend to \[groff] and
+accepts all the same options (see \[man]\~\[groff]).
+.PP2
+.EW .2
+Called as-is, \[pdfmom] accepts all the same options as \[groff],
+and requires no additional flags.  PDF generation is performed by
+\[gropdf], \[groff]'s native PDF driver:
+.EW 0
+.COD "pdfmom doc.mom [groff opts] > doc.pdf
+If a \[-Tps] option is supplied, \[pdfmom] hands control over to
+\[pdfroff], and both \[groff] and \[pdfroff] options may given.
+The resulting PDF is produced from PostScript output fed into
+\[ghostscript].
+.COD "pdfmom -Tps [pdfroff opts [groff opts]] doc.mom > doc.pdf
+For either invocation, it is not necessary to add \[-mom] or
+\[-mpdfmark], as these are implied.
+.PP2
+If Encapsulated PostScript or plain PostScript images have been
+embedded in a document with
+.PDF_WWW_LINK http://www.schaffter.ca/mom/momdoc/images.html#pspic SUFFIX , \
+  "PSPIC"
+the \[-Tps] option must be used.  In most other cases, \[pdfmom]
+with no \[-T] flag is preferable.
+.HEADING 2 NAMED papersize "Setting papersize within a source file"
+A significant convenience afforded by using \[pdfmom] (or \[groff]
+with the \[-Tpdf] flag) is that papersizes or page dimensions set
+within mom source files (see
+.PDF_WWW_LINK 
http://www.schaffter.ca/mom/momdoc/typesetting.html#page-setup-intro \
+  SUFFIX ) "paper and page setup macros"
+do not require a corresponding \[-P-p<papersize>] option on the
+command line.  It is even possible to create documents with
+unequal-sized pages.
+.NO_SHIM
+.HEADING 2 NAMED pdf-diff \
+"Differences between pdfmom and pdfroff"
+.PP
+Several features described in this manual are not available when
+using \[pdfmom] with the \[-Tps] option, or when using \[pdfroff] or
+\[groff]\~\[-Tps]\~\[-mpdfmark].
+.SP .25v
+.QUAD LEFT
+.HYPHENATION off
+.IB 16p
+.LIST
+.ITEM
+.PDF_LINK toc:pos "Relocation of the Table of Contents"
+is not supported.  The TOC appears at the end of the document;
+\[psselect] must be used to re-order pages.
+.ITEM
+If a link crosses a page boundary, it will stop being a clickable
+hotspot on subsequent pages.
+.ITEM
+When establishing whether PDF outline levels are
+.PDF_LINK open-close SUFFIX , "open or closed"
+only the numerical parameter to \*[cod]PDF_BOOKMARKS_OPEN\*[codx] has
+any effect.
+.ITEM
+.PDF_LINK colour "PDF_LINK_COLOR"
+only accepts colour definitions in decimal notation.
+.LIST OFF
+.IQ
+.HEADING 1 \
+"Comparison of -Tps\*[FU4]/\*[FU2]-mpdfmark with -Tpdf\*[FU4]/\*[FU2]-mom
+.SP .25v
+.IB
+\[-Tps]\*[FU4]/\*[FU2]\[-mpdfmark]
+.LIST
+.SHIFT_LIST 1P+6p
+.ITEM
+does not support all the features described here
+.ITEM
+accepts images and graphics embedded with PSPIC
+.ITEM
+is mature and well-tested code
+.LIST OFF
+.IQ
+.ALD .4v
+.IB
+\[-Tpdf]\*[FU4]/\*[FU2]\[-mom]
+.LIST
+.SHIFT_LIST 1P+6p
+.ITEM
+facilitates embedding fonts directly in the PDF file (if the
+\[-P-e] flag is given on the command line)
+.ITEM
+sets papersize from within the source file, circumventing the need
+for the papersize flag (\[-P-p<papersize>]) on the command line
+.ITEM
+is not compatible with
+.PDF_WWW_LINK \
+  http://www.schaffter.ca/mom/momdoc/docprocessing.html#printstyle \
+  "PRINTSTYLE TYPEWRITE"
+underlining (eg of italics)
+.ITEM
+generally produces larger files; these can be reduced by piping
+the output through \[ps2pdf]\*[B]
+.RLD .5v
+.FLOAT
+.QUAD LEFT
+.BR_AT_LINE_KERN
+.IQ
+.BOX-NOTE (\n[.l]u-6P) 3P
+.EW .3
+\*[BD]Note:\*[PREV] Owing to a known bug, PDF files piped
+through \[ps2pdf] lose some of
+.EW 0
+their metadata, notably the window title set with
+\*[cod]PDF_TITLE\*[codx].
+.FLOAT off
+.ITEM
+is newer code with less testing\c
+.EL
+.LIST OFF
+.IQ CLEAR
+.TOC

Index: examples/penguin.pdf
===================================================================
RCS file: examples/penguin.pdf
diff -N examples/penguin.pdf
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ examples/penguin.pdf        31 Aug 2012 22:49:58 -0000      1.1
@@ -0,0 +1,148 @@
+%PDF-1.4 
+1 0 obj
+<<
+/Pages 2 0 R
+/Type /Catalog
+>>
+endobj
+2 0 obj
+<<
+/Type /Pages
+/Kids [ 3 0 R ]
+/Count 1
+>>
+endobj
+3 0 obj
+<<
+/Type /Page
+/Parent 2 0 R
+/Resources <<
+/XObject << /Im0 8 0 R >>
+/ProcSet 6 0 R >>
+/MediaBox [0 0 81 96]
+/CropBox [0 0 81 96]
+/Contents 4 0 R
+/Thumb 11 0 R
+>>
+endobj
+4 0 obj
+<<
+/Length 5 0 R
+>>
+stream
+q
+81 0 0 96 0 0 cm
+/Im0 Do
+Q
+endstream
+endobj
+5 0 obj
+29
+endobj
+6 0 obj
+[ /PDF /Text /ImageC ]
+endobj
+7 0 obj
+<<
+>>
+endobj
+8 0 obj
+<<
+/Type /XObject
+/Subtype /Image
+/Name /Im0
+/Filter [ /RunLengthDecode ]
+/Width 81
+/Height 96
+/ColorSpace 10 0 R
+/BitsPerComponent 8
+/SMask 15 0 R
+/Length 9 0 R
+>>
+stream
+õ…ì„þ…Ú„û…ø„û…û†þ‚þzþkûeþXûfþmþzþ~û†›…þ„þ…þ„þ…ì„þ…Ñ„õ…
þ€þpþ\þQøIþGûJþMþPþXþfþv›…ø„þ…ì„þ…Ñ„þ†þ‡þ„þwþ]þPûJþIûJþIøKþHþIþKþNþwþƒ•…ì„þ…ø„þ…
à„þ…þ†þ…þnþKþNþKþJïIþHøIþHþJþPþgþ€þ„þ‡¤…þ„þ…ì„þ…Ô„þ…
þ„þ†þOþNþHþJûIþJòHûIþQþiþ_þHþIþXþ{¡…þ„þ…ì„þ…ׄû…þþQþGàJþIþOþqþ”þ¦þ…þgþJþHþRþ}þ…
þ†°…û„þ…ì„þ…Ú„þ…þ„þ†þmþNþKàJþHþMþrþ™þ¨þþxþ[þJþMþcþƒþ†³…ø„þ…ì„þ…Ú„þ…
þ†þþXþHþKÝJþTþvþ–þ›þ€þwþbþJþKþOþsþ…þ‡³…û„þ…ì„þ…Ú„þ…
þ†þsþJþHþIãJþKþIþSþoþ‚þ{þYþWþQþKþMþHþZþƒþ‡³…þ„û…ì„þ…Ú„û…
þ_þGûIãJþIþJþNþ[þ`þOþMþKþIþMþJþIþKþt³…¶„û…
þRþIþHþIþMæJþIþKûJþNþKþNþIþMþKþIþKþJþ]þ†þ„­…ì„þ…Ú„þ…
þƒþJþKûIþKþIãJþKûJþIþJøKþIþJþIþOþ€ª…ì„þ…ׄþvþMûJþHþNþRþMæJþKþOþRþSûMûKøIþMþsþƒ­…
ì„þ…ׄþuþKþGþKþQþYþpþmþPûKûJøKþGþHþIþZþ~þNþIûKþJþHþIþKþoþ„­…ì„û…ø„þ…é„þ…
þuþMûHþœþ®þ‘þ[þsþ`þMøJþjþ™þ®þ¸þ¾þÃþŸþnþXøKþJþKþNþ\ª…ø„þ…ø„û…û„þ…ø„þ…ò„þ…
þtþMþGþ_þÃþÔþÇþŸþZþXþKûJþeþ¢þºþÃþÌþÒþÚþÊþPþYûKþJþHþIþJþXª…õ„þ…û„þ…Ú„þ…
þsþMþGþƒþÚþéþæþÖþ–þJþKûJþ—þÌþìþ÷ûùþõþáþlþJûKþIþHûIþPª…ì„þ…Ú„þ…
þsûMþªþâþÐþòþþââáþWþIûJþÅþùþýââáþ•þ˜þÚûüûþþGûKþJþIûHþOª…ì„þ…é„þ…õ„þ…
þtþIþXþÒþ`þ„þšþïþûþsþVþMþOþÒþüþîþfþXþœ‘’‘þ×þÒþTûKþJþHþIþHþMª…ì„þ…Ú„þ…
þsþJþ]þÝþHþ„þ–þ´þüþˆþfþvþxþÓþüþ¬þNþJþoþ¡‘’‘þìþgûKþJûIþHþMþ„¹…
³„þzþKþ\þÝþOþ\‘’‘þˆþúþ‚þZþ]þjÀÁÀþøþŽþFþMþVþnþ{þñþhøJøIþKþ„­…ì„þ…ì„û…
ï„þSþWþÖþMþNþiþzþØþyþþ‚þþ”þîþþKûJþKþnþïþkþIþJþIþJþIþMþHþ†­…ì„þ…
ԄþRþOþÄþWþKþRþ‚þµþÎþÓþÑþÍþ¿þÍþ­þJþMþKþOþžþãþ^øIþJøIª…ì„þ…õ„þ…
ã„þSþHþnþëþ¨þ¸þÍþ×øØþÜþßþãþáþÝþÐþ·þÐþêþvûHþIþJûIþJþFª…ì„þ…
ԄþSþFþOþ³þ·þÆþÔøØþÛþàþæþèþæþåââáþÞþ×þÎþ|þPòIþJþGª…õ„þ…û„þ…ï„þ…
é„þRþGþfþ³þÁþÍþÕûØþÚþÝââáþèþçþæøåþæþãþÂþhûJûIþJþMþHª…ì„þ…õ„þ…
ã„þ]þTþ•þºþÉþÒûØþÙþÜþßââáþèþæõåþÚþ¿þÌþqþMþKþIþJþMþIþMþ„­…ì„û…Ú„þ…
þeþ^þ¥þÀþÍþÕûØþÚþÝþáþåþæøåââáþÊþ·þ¼þ»þbþKþMþJþIûJþNþ~þ…þ†³…ø„þ…ø„û…ï„þ…û„þ…ø„þ…
þgþYþŸþÆþÎþØþÙþÚþÜþÞþâþæþåþäþãþØþºþ¹þÄþÇþ¹þ]þMþKþIþJþGþIþPþlþ„þ‡³…õ„þ…û„þ…
ԄþcþKþoþ¼þÓþÙûÚþÞþáþäþãþáþÚþ¾þ°þ¿þÅûÇþ™þQþJþKþþ‡þXþBþIþYþ„þ†³…ì„þ…
ԄþbþNþWþ˜þ²þÐþÚþÞþàþáþàþÚþ¶þ¦þ²þÁþÄþÇþÄþ»þ˜þSûHþvþ¨þŸþ‚þRþMþ|þ†³…ì„þ…þ„þ…ï„þ…
õ„þ…þ†þgþMþ[þËþ²þ¡þ¨þÁþÌþÆþÂÀÁÀþ¾þ½þ»þ´þ¹þÊþÒþØþÎþ‰þJþKþMþq©ª©þªþ™þIþNþx³…ì„û…
û„þ…ì„û…
û„þZþHþiþÍþËþ±þŸþ®þ¿þÁþÀþ½þ²þ°þ³ÀÁÀûÍþÐþÜþÝþºþRþJþKþQþŒþ›þmDEDþIþZþƒþ‡¶…ï„û…
æ„þ…þ†û…þvþPþMþ`þÐþÍþÌþ¶þ¡þ¢þ§þ©þ¦þ¤þ¶þÇûÍþÓþçþ÷þüþåþþKþMþJþIþSþMþJþIþOþtþ‡þ†¼…
ì„þ…é„þ…þ„þ…þ„þ…þƒþWþKþIþ_þáþÒûÍþÈþ¶û«þ­þÇþÌûÍþ×þéþúûþûüûþËþWòKþJþIþNþ^þƒþ„¼…
ï„û…ã„þ…þƒþ„þnþNþKþIþ þìþØûÎþÍþÎòÍþÒþÝþê÷ø÷õþþûþ…þPòKþJþIþTþmû‡¿…ì„þ…à„þ…
þzþcþXþFþkþæþùþêþÑþÍûÎþÍþÎþÍþÏþØþäþñþùøþþýþþþýþÕþ\þKþNþHþKøJþOþ\þ~û…þ„Å…ì„þ…
à„þ€þ]þgþTþQþ¿þùþþþùþÝïÍþÝþì÷ø÷þýòþþýþüþùþ•ûNûKþIþKþIþJþKþ`þ„¿…õ„þ…þ„û…æ„þ…
þ„þZûJþFþ†þ÷þþþüþýþðþØþÐøÍþ×þöûüûøþþýøþþýþþþýþÕþQþIþJþKûIþJþIþKþMþsþ…þ„Å…õ„þ…
û„þ…ã„þmþOþPþMþWþÙþýþþþýþþþý÷ø÷þëþáþãþëþôøýûþþýïþþøþ|þGþIþKõIûJþZþ}΅˄ø…
þzûKþIþ^þÛûüûþýòþþüûüûþýûþòýìþþüþÒûKûJþIøJþIþMþOþeõ…þ„ø…õ„þ…þ„þ…þ„þ…þ„û…ì„þ…
ø„û…þ„þˆþ†þ€þSþJþHþMþþìþûûÿõþþýþüþýûþþýûþþýìþþýþúþèþ_þMþKõJûKþIþJþKþ„þ†Ë…ì„þ…
ø„û…þ„þ…þþ_þKþJþFþXþ°þèþúþþþÿûýûþþýûúþýïþþýûþþýþüþ÷ûóþïþxþPìKþIþHþIþjхþ„û…ì„þ…
õ„þ…
û„þfþPþKþJþFþ\þ´þØþóþûþüþþþýþû÷ø÷þôþðþïþöþúûüûüûþýûüûþúþù÷ø÷þóþïþéþâþæþëþ™þYþKþJþKþJþIûJþKþIþJþPþoË
…ì„û…ø„þ…
þ„þuûNøJþnþ¸þÅþÙþìþñûû÷ø÷þñþéþçþëþìþõýûüûûüûþùþòþèââáþÜûØþÖþÒþÓþàþÐþdûJþGþMþIþNþKþJûIþNþOþvÎ
…ì„þ…ø„û…
þþ\þNþHûJþWþ‚þ»þÂþÕþäþïþüþýþþþýþñþê÷ø÷þüõþþýþùþñþéþÝþÔûÒûÑþÒþåþÅþVþOþwþ`þJþIþKûJþIþHþMþ]þ‚Ñ
…õ„ò…û„û…
þsþOþJûKþJþ]þþÇþÜþïþùþþþýþüþþþýþòþôøýûüþþûýþþþüþúþíþåþÜþÕþÒþÑþØþò©ª©þCþhþ‚þrþXþMþNþIþKûJþOþuÝ
…ø„þ…ø„þ…ø„þ…
ø„þ†þƒþ]þKþNþIþYþMþrþ¾þãþôþüûýþþøý÷ø÷÷ø÷þüþýþüòýûüþþþýþü÷ø÷þîþáþ×þÒþàþïþKûNþkþ
…þ]þKþNþKûJþMþdû†×…õ„þ…û„þ…
ø„þ†þþTþOþHþqþsþQþ¡þæ÷ø÷þýþþõýþüþýûüûûüûýþüþýþþõýþþûýþüþýþøþëþÜþÓþéþQþJþNþIþ_þ†þSDEDþOþKþJþIþRþ~þ
…þ†à…þ„þ…ì„þ…ø„þ†þjûMþsþ_þKþ 
þüþþþüþýþþòýûüþþþüþþþýþüøýþüûýûþõýþþþýþñþÜþÏþNþHþ`þnþcþwþkþJþKþJþFþMþQþ‚Ý…þ„þ…
ì„þ…
ø„þƒþZþPþYþ‚þGþHþîøþþüòýþüþýþþøýþüþýûüûýþþþýþþòýþþþýþþûôþkþPþqþŠþƒþgþ€þSþKþJþKþJþNþv×
…û„þ…õ„þ…þ„þ†þ…
þwþPþMþ}þeþGþNþüõýþüûýþþûýûüþýþüþýþüþýþþìýþüûýþþþýþþþüþýþþþ¦þWþxþþ†þeþlþtþMþIþJþIþKþ`þ„Ú
…ì„þ…
þ„þ‡þ„þdþJþWþ}þIþJþmûüûþýþüþýþüþýþüøýþüþúûüûþüøýþþþüþýþþûýþþûýþüþþþýþüõýþþþÑþbþqþwþiþTþQþ‹þKþNþIþKþNþTþÚ
…þ„þ…ò„ø…
þþYþHþoþfþBþOþ©þüæýþûþïòüþýþüþþûýþüõýþüþþûýûþûýþìþYþNþPûKþGþqþIþNþHûIþKþtþ„Ý…
ì„þ…þ„þ…
þvþMþKþƒþPþCþdââáþýûüûýþüûýþþþüþ÷þíûüûþýþþûýþüþýþüõýþüìýûüþýûüûþuþMûJþKþGþ]þGþNøIþKþcÚ
…ì„û…
þ„þ`þKþeþtþKþHþœþúþüþýþüìýþõþñþýþþøýþþþýþüïýûþõýþþøýþ–þHûKþIþJþPþRûHþIþHþJþRþ‚ã…
þ„þ…ì„û…
þyûMþ{þWþKþQþÐûüûþûýþþþüøýûñþüéýûüõýûüûõýþüûýþþþ²þMõKþNþGþHþKþJþIþKþPþ{é…ø„þ…
ø„þ…ø„þ…
þ„þOþNþ\þsþGþKþ”þüþýþþþüþþõýþüþýþüþëþïþüþýþþõýþüþþøýþþøýþþøýþüûýþþþÉþJûKþJþHþTþHþFþIþJþHþJþMþgÚ
…õ„û…
þ†þ€þJþGþfþoþHþIþ¹ûýûþøýþüþýþþûüþëþïþûûüþýûüûýþüþþûýþüøýþþõýþüûýþØþMûKþIþMþ`þIþGþHûIþHþMþbé
…û„û…
ï„þ†þ„þlþKþIþeþsþIþYþ×þýþüõýûþûýþþûüûþèþîûüûûüþýþþæýûüþýþüþþûýþþûýþÝþSøKþJþmþIþJþIþHûJþIþQÝ
…õ„þ…þ„þ…
þþRþMþFþiþ{þKþYþÞþþþüòýþüþýþþþýûüûþçþîûüþýþþûýþüõýþüþýþüøýûüþþþýþüþýþþââáþRûKþMþKþyþIûJþIþHþKþJþPã
…þ„þ…
ì„þhþMþKþQþrþ€þIþ^þçòýþüþþõýþûþçþðþüõýûüþýþþûýþþþüøýþüþýûüþþøýþäþSøKþIþwþIþJøIûJþOÚ
…ò„þ…
þbþOþNþbþ‰þ‘þKþnþîþýûþøüûýþüûüûþýþúþèþòûüÝýþüþþþýþüþýþþûýþüþþþåþTøKþWþrûKûJøIþOÝ
…
ï„þþXþIþHþXþ~þ˜þOþ|þñþýþþøýþüòýþùþèþòþýþüûýûþþýþüþþþýøþøýþþþüûýþüþýþüþþþãþVûKþHþmþXûKþJþHøIþQÝ
…û„þ…ø„þ‚þRûJþIþWþ…
þZþ|þóøýþüûýþüøýþüþúþèþôõýþüæýþüïýþüþþþýþÖþPþHþJþRþ{þKþNþJþKøJþKþS݅
ï„þþVûIûMþ[þuþþòþýþüæýþúþèþôþýþüþýþþþýûþòýûüãýþÅþKþPþmþ{þpþWþsþgþXþPþJþMþJþdã…
þ„þ…û„û…þ„þ…
þ„þ‡þ²þÝþÞþÒþŽþKþcþ¾þûþýþþøýþüþþøýþúþèþöþüûýþþïýõüþýþüòýûüþøþ|þiþQþKûJþIþKûJþsþŸþxþWþzþ
…þ†ã…û„þ…
þ„þ†þ„þ†þ«þÍøÝþÖ‘’‘þPþhþ¸÷ø÷þüþýþüþþûüþýþüþýþúþçþöþýþüõýþüûýûþéýþüþøþÝþÜþÛþ¬þlþIþJþIøKþJþMþpþ‰þtþZþ~Ý
…þ„þ…û„þ†þ…
þšþ¿þÒõÝþÖþ’þPþ`þ±þüøýþüõýþøþéþ÷þýþþûüéýþþøýþüøýþãþØþäþãþ×þnþOþJþIøKþJþOþxþqþdþ¬þ›û†ï
…ø„û…ø„þ…
þ‰þ²þÅþÒòÝþÑþ€þJþZþîþýþüþýþþþýûüþýþúþçþóþüþýþüøýþüûýþüþýþüøýþüõýþÝþÒþßââáþÇþcþHþMþIøKþJþRþbþQþ‰þØââáþ†þ‡ï
…þ„þ…þ„þ†û…
þ„þƒþ‘þ­ÀÁÀþÌþ×ïÝþÃþgþKþ†þÞûüûýûþþüûüûþïþñþýþüþþûýûþòýþüþýþüþýþþøýþßþÐþÝþÚþ¸þdþJþIþJøKûJþFþfþÇþÝþßþ†þ„ï
…
þ„þƒþŠþžþ¹þ·þ´þ²þ¶þÁþÉþÓþÚïÝþÛþ°þVþQþnþÍþùûýþþþüþýþþþüþûþýþþþýþüûýþüõýþüûýþþûýûüþúþàþÏþÛþÓþ·þoþJþKþHøKûJþRþ§þØþÚþÝþ†þƒï
…
þ†þŠþ¯þÀþÍþËûÇþÉþÏþÔþÚéÝþÕþþGþMþXþ®þöþüûýþþòýþüÝýþüþýþüþíþÜþÒþÏþØþÎþ¼þ‹þXþMþFûHþGþKþYþþËþÖþØþÚþ‰þ„ï
…
þ†þœþ¾þÊþ×þÖþÓþÒþÖþÚþÛãÝþÄþHþKþJþTþ™þëþþûýþüøýûþþüõýþüûýþþþýûüþþþýþòþ×þÒþÎþÍþÕþÍþ¼©ª©þ„þXþQþOþIþSþtþ›þÀþÎþÖþØþÛþˆé
…
þ®þÅþÒÔÝûÜþÝþxþHþKþHþCþPþjþËþüûýþüòýþüþýþþõýûüûýþüþæþÓþÒþÉþÆþÔþÑþÇþ¾þ·þ´þ±þ°þ±þ¶þ¿þËþÖþÚøÝþ½þŠþ„þ†õ
…
þ„þ£þÄþÑÑÝþÜþÝþµþXþIþHþMþJþHþeûýøþòýûþûýþþþýþþþüûýþüþæûÒþÅþÁûÔþÍþÆþÂþ¿þ¾û½þÄþÌþÕòÝþØþ¬ì
…
þžþÂþÎËÝþÓþþKþFþJûGþIþóõýþþãýþþþýþüþýþþþìþÕþÓÀÁÀþ¼þÓþÕþÒþÍþÈþÇøÆþÎþÓþÚòÝþÚþÒþ 
ò…
þ„þþÀþÌþÜËÝþÃþjþJøIþGþàòýþüþýþüûýþþõýþüûýþþþüþòþÙþÒþ»þ¹þÓþÙþØþÕþÐþÎûÍþÎþÒþØþÛïÝþÚþÍþ¡þ„þ
…þ†û…
‘’‘þ½þÉþÜËÝþØþ¨þQþHþIþKþIþÚøýþüþýþüþýþþþýþüòýþüþýþüûýþöþÜþÂþšþ¹þÓþÙþÛþÚþ×þÕþÓþÒþÔþØþÚìÝþÜþÙþÕ©ª©þ‰þ†û
…
þþ»þÈþÜÎÝþÜþÝþÐþûJþHþJþðþþøýþüòýþüþýþüûýþüûýþüþýþõþÏþzþ—þ¹þÓþÚûÜûÛþÙûÚþÛþÜàÝþÅþšû
…þŽþºþÇþÜËÝþÜþÝþ¿þgþRþXþŽøýþüûýûþûýþüøýûþøýþüþýþ×þpþVþ–þºþÔþÚþÛÅÝþØþ´þ…
þþ¼þÇþÜËÝûÜþØ©ª©þ¶þãþúòýûüõýþþõýþüûýþúþÍþeþJþYþ›þ¹þÔþÚþÜÅÝþÛþÑþƒþ–þ¼þÇþÛþÜÎÝþÜûÚþËþ³þ÷ûüûþüûýþüøýûüéýþüþøþ³þWþHþFþ`þœþ¹þÕþÛÅÝþÜþØþÍþ†þ­þ¼þÌÂÝþØþÙþÈþ¦þÚûüéýþüòýþóþ^þKþHþMþIþHþqþšþ¶þÖþÛËÝþÚþÑþÈþµþ‰þ“þµþÃþÕþÜÅÝþØþÔþËþ¯þ’ûüûþüøýþüøýþüõýþóþÁþnþJþKþJþGþHþIþwþšþµþÖþÜÔÝþÜþÚþÖþÍþÂþ¥þ‹þ„þ¥þ¼þËþ×þÜÅÝþÙþÑþÉþµþ•þœþÚþóþùþüþýþüûýûüûþöþìþÐþ¤þmþPþGòKþNþ~þþ¶þÕþÛÔÝþÒþÌþÂþ²þ’þ
…
û†þ³þ½þÉþÒûÛþÜþÝþÜÑÝþÚþÒþÈþ¸þŸþKþNþoþ‘þ¤þ¶þ¼þ°þ©þþqþ]þNþKþJûHõKþJþTþƒþŸþ¶þÔþÛãÝþÛþÚþÛþÚþÒþ¾þª‘’‘þ†õ
…þ²þºþÄþËþÕþ×ûØþÙþÛþÝþÜÚÝþÙþÒþÈþ¶þ 
þYþHþIþHûNþJþIþGþFDEDþJþHþKûGþKþJþIûJþHþYþˆþ¡þµþÓþÛæÝþÙþÖþÔþÑþÉþ¿þŒþ„ø…þ†û…
þªþ´þ¹þ½þÈþËþÌþÎþÐþÑþÔþÖþØþÚþÛûÜìÝþÜþØþÎþÃþ²þþhøIþJÚIûJûIþYþ‰þ 
þ²þÎþØïÝþÛþÚþÕþÐþËþÇþ¿þ«þ’þ„ì…
þþ¢þ©þ­þ²þ¶þºþ½þÀþÃþÄþÈþÌþÑþÓþ×þÙþÛïÝþÚþÒþÇþ¸þ©þœþlòJþIãJþHþIøJþ\þ‰þœþ­þÉþÓþÙþÛûÜûÛþÙþÒþËþÅþÀþµþœþ†ø„ï
…þ„þ…þˆþþžþ¢þ¨þ¬þ¯û³þµþ¸þ¿þÃþÇþÍþÒþ×þØþÚþÛûÚþÕþËþ¾þ®þ 
þ—þkþHþJþHþIïKþMòKþHþGþHþJþIþ^þ†þ—þ§þÂþËþÓþØþÙþÚþÙþ×þÒþÇþ½þ³þªþŽþ…þ„à…þ†û…
þ‡þþ—þþ¡û¥þ§þ«þ¯þ³þºÀÁÀþÆþÊþÎþÒþÔþÏþÇþ½þ²þ¤þ˜þþ`þMþQûRþ]þhækþjþ_ûWþTþQþ_þƒþ”þ¡þ¹þÃþÌþÐûÒþÑþÊþÅþ·þ«þœþˆþ„Ú
…ï„û…û„þ…þ‰þŽþþ”þ›þŸþ¢þ¦þ©þ«þ©þ£þœþ•þ‘þŒþ…þwþƒþ…þ„ø…ï„ì…
û„þƒþ€þ‰þ”þ¨þ«þ­þ°û±þ¯þ«þ§þþ†û…û„×…ì„þ…þ„þƒû„þ…þ‰þþ“þ˜û™þ˜þ•þ’þþŠþ‚þþ…Ý„æ…
þ„þƒþ‚þŒþžþ¢þ£ø¦þ¤þŸþ–ø„Î…ì„þ…ø„û†û…þ†þˆþ‰þþþŽþŒþ‡þþ€û…Ý„æ…þ„þ…
þþ‚þþ”þ—þšþ™þ˜þ•þŒþ‡þ„þ…þ„Î…ì„þ…ø„ï…þƒþ†þƒû‚þ„þƒø…ï„þ…ò„Ý…þ„û‚þ…þˆþ†û…þ„þ…þ„Ô…
€
+endstream
+endobj
+9 0 obj
+7826
+endobj
+10 0 obj
+/DeviceRGB
+endobj
+11 0 obj
+<<
+/Filter [ /RunLengthDecode ]
+/Width 81
+/Height 96
+/ColorSpace 10 0 R
+/BitsPerComponent 8
+/Length 12 0 R
+>>
+stream
+õ…ì„þ…Ú„û…ø„û…û†þ‚þzþkûeþXûfþmþzþ~û†›…þ„þ…þ„þ…ì„þ…Ñ„õ…
þ€þpþ\þQøIþGûJþMþPþXþfþv›…ø„þ…ì„þ…Ñ„þ†þ‡þ„þwþ]þPûJþIûJþIøKþHþIþKþNþwþƒ•…ì„þ…ø„þ…
à„þ…þ†þ…þnþKþNþKþJïIþHøIþHþJþPþgþ€þ„þ‡¤…þ„þ…ì„þ…Ô„þ…
þ„þ†þOþNþHþJûIþJòHûIþQþiþ_þHþIþXþ{¡…þ„þ…ì„þ…ׄû…þþQþGàJþIþOþqþ”þ¦þ…þgþJþHþRþ}þ…
þ†°…û„þ…ì„þ…Ú„þ…þ„þ†þmþNþKàJþHþMþrþ™þ¨þþxþ[þJþMþcþƒþ†³…ø„þ…ì„þ…Ú„þ…
þ†þþXþHþKÝJþTþvþ–þ›þ€þwþbþJþKþOþsþ…þ‡³…û„þ…ì„þ…Ú„þ…
þ†þsþJþHþIãJþKþIþSþoþ‚þ{þYþWþQþKþMþHþZþƒþ‡³…þ„û…ì„þ…Ú„û…
þ_þGûIãJþIþJþNþ[þ`þOþMþKþIþMþJþIþKþt³…¶„û…
þRþIþHþIþMæJþIþKûJþNþKþNþIþMþKþIþKþJþ]þ†þ„­…ì„þ…Ú„þ…
þƒþJþKûIþKþIãJþKûJþIþJøKþIþJþIþOþ€ª…ì„þ…ׄþvþMûJþHþNþRþMæJþKþOþRþSûMûKøIþMþsþƒ­…
ì„þ…ׄþuþKþGþKþQþYþpþmþPûKûJøKþGþHþIþZþ~þNþIûKþJþHþIþKþoþ„­…ì„û…ø„þ…é„þ…
þuþMûHþœþ®þ‘þ[þsþ`þMøJþjþ™þ®þ¸þ¾þÃþŸþnþXøKþJþKþNþ\ª…ø„þ…ø„û…û„þ…ø„þ…ò„þ…
þtþMþGþ_þÃþÔþÇþŸþZþXþKûJþeþ¢þºþÃþÌþÒþÚþÊþPþYûKþJþHþIþJþXª…õ„þ…û„þ…Ú„þ…
þsþMþGþƒþÚþéþæþÖþ–þJþKûJþ—þÌþìþ÷ûùþõþáþlþJûKþIþHûIþPª…ì„þ…Ú„þ…
þsûMþªþâþÐþòþþââáþWþIûJþÅþùþýââáþ•þ˜þÚûüûþþGûKþJþIûHþOª…ì„þ…é„þ…õ„þ…
þtþIþXþÒþ`þ„þšþïþûþsþVþMþOþÒþüþîþfþXþœ‘’‘þ×þÒþTûKþJþHþIþHþMª…ì„þ…Ú„þ…
þsþJþ]þÝþHþ„þ–þ´þüþˆþfþvþxþÓþüþ¬þNþJþoþ¡‘’‘þìþgûKþJûIþHþMþ„¹…
³„þzþKþ\þÝþOþ\‘’‘þˆþúþ‚þZþ]þjÀÁÀþøþŽþFþMþVþnþ{þñþhøJøIþKþ„­…ì„þ…ì„û…
ï„þSþWþÖþMþNþiþzþØþyþþ‚þþ”þîþþKûJþKþnþïþkþIþJþIþJþIþMþHþ†­…ì„þ…
ԄþRþOþÄþWþKþRþ‚þµþÎþÓþÑþÍþ¿þÍþ­þJþMþKþOþžþãþ^øIþJøIª…ì„þ…õ„þ…
ã„þSþHþnþëþ¨þ¸þÍþ×øØþÜþßþãþáþÝþÐþ·þÐþêþvûHþIþJûIþJþFª…ì„þ…
ԄþSþFþOþ³þ·þÆþÔøØþÛþàþæþèþæþåââáþÞþ×þÎþ|þPòIþJþGª…õ„þ…û„þ…ï„þ…
é„þRþGþfþ³þÁþÍþÕûØþÚþÝââáþèþçþæøåþæþãþÂþhûJûIþJþMþHª…ì„þ…õ„þ…
ã„þ]þTþ•þºþÉþÒûØþÙþÜþßââáþèþæõåþÚþ¿þÌþqþMþKþIþJþMþIþMþ„­…ì„û…Ú„þ…
þeþ^þ¥þÀþÍþÕûØþÚþÝþáþåþæøåââáþÊþ·þ¼þ»þbþKþMþJþIûJþNþ~þ…þ†³…ø„þ…ø„û…ï„þ…û„þ…ø„þ…
þgþYþŸþÆþÎþØþÙþÚþÜþÞþâþæþåþäþãþØþºþ¹þÄþÇþ¹þ]þMþKþIþJþGþIþPþlþ„þ‡³…õ„þ…û„þ…
ԄþcþKþoþ¼þÓþÙûÚþÞþáþäþãþáþÚþ¾þ°þ¿þÅûÇþ™þQþJþKþþ‡þXþBþIþYþ„þ†³…ì„þ…
ԄþbþNþWþ˜þ²þÐþÚþÞþàþáþàþÚþ¶þ¦þ²þÁþÄþÇþÄþ»þ˜þSûHþvþ¨þŸþ‚þRþMþ|þ†³…ì„þ…þ„þ…ï„þ…
õ„þ…þ†þgþMþ[þËþ²þ¡þ¨þÁþÌþÆþÂÀÁÀþ¾þ½þ»þ´þ¹þÊþÒþØþÎþ‰þJþKþMþq©ª©þªþ™þIþNþx³…ì„û…
û„þ…ì„û…
û„þZþHþiþÍþËþ±þŸþ®þ¿þÁþÀþ½þ²þ°þ³ÀÁÀûÍþÐþÜþÝþºþRþJþKþQþŒþ›þmDEDþIþZþƒþ‡¶…ï„û…
æ„þ…þ†û…þvþPþMþ`þÐþÍþÌþ¶þ¡þ¢þ§þ©þ¦þ¤þ¶þÇûÍþÓþçþ÷þüþåþþKþMþJþIþSþMþJþIþOþtþ‡þ†¼…
ì„þ…é„þ…þ„þ…þ„þ…þƒþWþKþIþ_þáþÒûÍþÈþ¶û«þ­þÇþÌûÍþ×þéþúûþûüûþËþWòKþJþIþNþ^þƒþ„¼…
ï„û…ã„þ…þƒþ„þnþNþKþIþ þìþØûÎþÍþÎòÍþÒþÝþê÷ø÷õþþûþ…þPòKþJþIþTþmû‡¿…ì„þ…à„þ…
þzþcþXþFþkþæþùþêþÑþÍûÎþÍþÎþÍþÏþØþäþñþùøþþýþþþýþÕþ\þKþNþHþKøJþOþ\þ~û…þ„Å…ì„þ…
à„þ€þ]þgþTþQþ¿þùþþþùþÝïÍþÝþì÷ø÷þýòþþýþüþùþ•ûNûKþIþKþIþJþKþ`þ„¿…õ„þ…þ„û…æ„þ…
þ„þZûJþFþ†þ÷þþþüþýþðþØþÐøÍþ×þöûüûøþþýøþþýþþþýþÕþQþIþJþKûIþJþIþKþMþsþ…þ„Å…õ„þ…
û„þ…ã„þmþOþPþMþWþÙþýþþþýþþþý÷ø÷þëþáþãþëþôøýûþþýïþþøþ|þGþIþKõIûJþZþ}΅˄ø…
þzûKþIþ^þÛûüûþýòþþüûüûþýûþòýìþþüþÒûKûJþIøJþIþMþOþeõ…þ„ø…õ„þ…þ„þ…þ„þ…þ„û…ì„þ…
ø„û…þ„þˆþ†þ€þSþJþHþMþþìþûûÿõþþýþüþýûþþýûþþýìþþýþúþèþ_þMþKõJûKþIþJþKþ„þ†Ë…ì„þ…
ø„û…þ„þ…þþ_þKþJþFþXþ°þèþúþþþÿûýûþþýûúþýïþþýûþþýþüþ÷ûóþïþxþPìKþIþHþIþjхþ„û…ì„þ…
õ„þ…
û„þfþPþKþJþFþ\þ´þØþóþûþüþþþýþû÷ø÷þôþðþïþöþúûüûüûþýûüûþúþù÷ø÷þóþïþéþâþæþëþ™þYþKþJþKþJþIûJþKþIþJþPþoË
…ì„û…ø„þ…
þ„þuûNøJþnþ¸þÅþÙþìþñûû÷ø÷þñþéþçþëþìþõýûüûûüûþùþòþèââáþÜûØþÖþÒþÓþàþÐþdûJþGþMþIþNþKþJûIþNþOþvÎ
…ì„þ…ø„û…
þþ\þNþHûJþWþ‚þ»þÂþÕþäþïþüþýþþþýþñþê÷ø÷þüõþþýþùþñþéþÝþÔûÒûÑþÒþåþÅþVþOþwþ`þJþIþKûJþIþHþMþ]þ‚Ñ
…õ„ò…û„û…
þsþOþJûKþJþ]þþÇþÜþïþùþþþýþüþþþýþòþôøýûüþþûýþþþüþúþíþåþÜþÕþÒþÑþØþò©ª©þCþhþ‚þrþXþMþNþIþKûJþOþuÝ
…ø„þ…ø„þ…ø„þ…
ø„þ†þƒþ]þKþNþIþYþMþrþ¾þãþôþüûýþþøý÷ø÷÷ø÷þüþýþüòýûüþþþýþü÷ø÷þîþáþ×þÒþàþïþKûNþkþ
…þ]þKþNþKûJþMþdû†×…õ„þ…û„þ…
ø„þ†þþTþOþHþqþsþQþ¡þæ÷ø÷þýþþõýþüþýûüûûüûýþüþýþþõýþþûýþüþýþøþëþÜþÓþéþQþJþNþIþ_þ†þSDEDþOþKþJþIþRþ~þ
…þ†à…þ„þ…ì„þ…ø„þ†þjûMþsþ_þKþ 
þüþþþüþýþþòýûüþþþüþþþýþüøýþüûýûþõýþþþýþñþÜþÏþNþHþ`þnþcþwþkþJþKþJþFþMþQþ‚Ý…þ„þ…
ì„þ…
ø„þƒþZþPþYþ‚þGþHþîøþþüòýþüþýþþøýþüþýûüûýþþþýþþòýþþþýþþûôþkþPþqþŠþƒþgþ€þSþKþJþKþJþNþv×
…û„þ…õ„þ…þ„þ†þ…
þwþPþMþ}þeþGþNþüõýþüûýþþûýûüþýþüþýþüþýþþìýþüûýþþþýþþþüþýþþþ¦þWþxþþ†þeþlþtþMþIþJþIþKþ`þ„Ú
…ì„þ…
þ„þ‡þ„þdþJþWþ}þIþJþmûüûþýþüþýþüþýþüøýþüþúûüûþüøýþþþüþýþþûýþþûýþüþþþýþüõýþþþÑþbþqþwþiþTþQþ‹þKþNþIþKþNþTþÚ
…þ„þ…ò„ø…
þþYþHþoþfþBþOþ©þüæýþûþïòüþýþüþþûýþüõýþüþþûýûþûýþìþYþNþPûKþGþqþIþNþHûIþKþtþ„Ý…
ì„þ…þ„þ…
þvþMþKþƒþPþCþdââáþýûüûýþüûýþþþüþ÷þíûüûþýþþûýþüþýþüõýþüìýûüþýûüûþuþMûJþKþGþ]þGþNøIþKþcÚ
…ì„û…
þ„þ`þKþeþtþKþHþœþúþüþýþüìýþõþñþýþþøýþþþýþüïýûþõýþþøýþ–þHûKþIþJþPþRûHþIþHþJþRþ‚ã…
þ„þ…ì„û…
þyûMþ{þWþKþQþÐûüûþûýþþþüøýûñþüéýûüõýûüûõýþüûýþþþ²þMõKþNþGþHþKþJþIþKþPþ{é…ø„þ…
ø„þ…ø„þ…
þ„þOþNþ\þsþGþKþ”þüþýþþþüþþõýþüþýþüþëþïþüþýþþõýþüþþøýþþøýþþøýþüûýþþþÉþJûKþJþHþTþHþFþIþJþHþJþMþgÚ
…õ„û…
þ†þ€þJþGþfþoþHþIþ¹ûýûþøýþüþýþþûüþëþïþûûüþýûüûýþüþþûýþüøýþþõýþüûýþØþMûKþIþMþ`þIþGþHûIþHþMþbé
…û„û…
ï„þ†þ„þlþKþIþeþsþIþYþ×þýþüõýûþûýþþûüûþèþîûüûûüþýþþæýûüþýþüþþûýþþûýþÝþSøKþJþmþIþJþIþHûJþIþQÝ
…õ„þ…þ„þ…
þþRþMþFþiþ{þKþYþÞþþþüòýþüþýþþþýûüûþçþîûüþýþþûýþüõýþüþýþüøýûüþþþýþüþýþþââáþRûKþMþKþyþIûJþIþHþKþJþPã
…þ„þ…
ì„þhþMþKþQþrþ€þIþ^þçòýþüþþõýþûþçþðþüõýûüþýþþûýþþþüøýþüþýûüþþøýþäþSøKþIþwþIþJøIûJþOÚ
…ò„þ…
þbþOþNþbþ‰þ‘þKþnþîþýûþøüûýþüûüûþýþúþèþòûüÝýþüþþþýþüþýþþûýþüþþþåþTøKþWþrûKûJøIþOÝ
…
ï„þþXþIþHþXþ~þ˜þOþ|þñþýþþøýþüòýþùþèþòþýþüûýûþþýþüþþþýøþøýþþþüûýþüþýþüþþþãþVûKþHþmþXûKþJþHøIþQÝ
…û„þ…ø„þ‚þRûJþIþWþ…
þZþ|þóøýþüûýþüøýþüþúþèþôõýþüæýþüïýþüþþþýþÖþPþHþJþRþ{þKþNþJþKøJþKþS݅
ï„þþVûIûMþ[þuþþòþýþüæýþúþèþôþýþüþýþþþýûþòýûüãýþÅþKþPþmþ{þpþWþsþgþXþPþJþMþJþdã…
þ„þ…û„û…þ„þ…
þ„þ‡þ²þÝþÞþÒþŽþKþcþ¾þûþýþþøýþüþþøýþúþèþöþüûýþþïýõüþýþüòýûüþøþ|þiþQþKûJþIþKûJþsþŸþxþWþzþ
…þ†ã…û„þ…
þ„þ†þ„þ†þ«þÍøÝþÖ‘’‘þPþhþ¸÷ø÷þüþýþüþþûüþýþüþýþúþçþöþýþüõýþüûýûþéýþüþøþÝþÜþÛþ¬þlþIþJþIøKþJþMþpþ‰þtþZþ~Ý
…þ„þ…û„þ†þ…
þšþ¿þÒõÝþÖþ’þPþ`þ±þüøýþüõýþøþéþ÷þýþþûüéýþþøýþüøýþãþØþäþãþ×þnþOþJþIøKþJþOþxþqþdþ¬þ›û†ï
…ø„û…ø„þ…
þ‰þ²þÅþÒòÝþÑþ€þJþZþîþýþüþýþþþýûüþýþúþçþóþüþýþüøýþüûýþüþýþüøýþüõýþÝþÒþßââáþÇþcþHþMþIøKþJþRþbþQþ‰þØââáþ†þ‡ï
…þ„þ…þ„þ†û…
þ„þƒþ‘þ­ÀÁÀþÌþ×ïÝþÃþgþKþ†þÞûüûýûþþüûüûþïþñþýþüþþûýûþòýþüþýþüþýþþøýþßþÐþÝþÚþ¸þdþJþIþJøKûJþFþfþÇþÝþßþ†þ„ï
…
þ„þƒþŠþžþ¹þ·þ´þ²þ¶þÁþÉþÓþÚïÝþÛþ°þVþQþnþÍþùûýþþþüþýþþþüþûþýþþþýþüûýþüõýþüûýþþûýûüþúþàþÏþÛþÓþ·þoþJþKþHøKûJþRþ§þØþÚþÝþ†þƒï
…
þ†þŠþ¯þÀþÍþËûÇþÉþÏþÔþÚéÝþÕþþGþMþXþ®þöþüûýþþòýþüÝýþüþýþüþíþÜþÒþÏþØþÎþ¼þ‹þXþMþFûHþGþKþYþþËþÖþØþÚþ‰þ„ï
…
þ†þœþ¾þÊþ×þÖþÓþÒþÖþÚþÛãÝþÄþHþKþJþTþ™þëþþûýþüøýûþþüõýþüûýþþþýûüþþþýþòþ×þÒþÎþÍþÕþÍþ¼©ª©þ„þXþQþOþIþSþtþ›þÀþÎþÖþØþÛþˆé
…
þ®þÅþÒÔÝûÜþÝþxþHþKþHþCþPþjþËþüûýþüòýþüþýþþõýûüûýþüþæþÓþÒþÉþÆþÔþÑþÇþ¾þ·þ´þ±þ°þ±þ¶þ¿þËþÖþÚøÝþ½þŠþ„þ†õ
…
þ„þ£þÄþÑÑÝþÜþÝþµþXþIþHþMþJþHþeûýøþòýûþûýþþþýþþþüûýþüþæûÒþÅþÁûÔþÍþÆþÂþ¿þ¾û½þÄþÌþÕòÝþØþ¬ì
…
þžþÂþÎËÝþÓþþKþFþJûGþIþóõýþþãýþþþýþüþýþþþìþÕþÓÀÁÀþ¼þÓþÕþÒþÍþÈþÇøÆþÎþÓþÚòÝþÚþÒþ 
ò…
þ„þþÀþÌþÜËÝþÃþjþJøIþGþàòýþüþýþüûýþþõýþüûýþþþüþòþÙþÒþ»þ¹þÓþÙþØþÕþÐþÎûÍþÎþÒþØþÛïÝþÚþÍþ¡þ„þ
…þ†û…
‘’‘þ½þÉþÜËÝþØþ¨þQþHþIþKþIþÚøýþüþýþüþýþþþýþüòýþüþýþüûýþöþÜþÂþšþ¹þÓþÙþÛþÚþ×þÕþÓþÒþÔþØþÚìÝþÜþÙþÕ©ª©þ‰þ†û
…
þþ»þÈþÜÎÝþÜþÝþÐþûJþHþJþðþþøýþüòýþüþýþüûýþüûýþüþýþõþÏþzþ—þ¹þÓþÚûÜûÛþÙûÚþÛþÜàÝþÅþšû
…þŽþºþÇþÜËÝþÜþÝþ¿þgþRþXþŽøýþüûýûþûýþüøýûþøýþüþýþ×þpþVþ–þºþÔþÚþÛÅÝþØþ´þ…
þþ¼þÇþÜËÝûÜþØ©ª©þ¶þãþúòýûüõýþþõýþüûýþúþÍþeþJþYþ›þ¹þÔþÚþÜÅÝþÛþÑþƒþ–þ¼þÇþÛþÜÎÝþÜûÚþËþ³þ÷ûüûþüûýþüøýûüéýþüþøþ³þWþHþFþ`þœþ¹þÕþÛÅÝþÜþØþÍþ†þ­þ¼þÌÂÝþØþÙþÈþ¦þÚûüéýþüòýþóþ^þKþHþMþIþHþqþšþ¶þÖþÛËÝþÚþÑþÈþµþ‰þ“þµþÃþÕþÜÅÝþØþÔþËþ¯þ’ûüûþüøýþüøýþüõýþóþÁþnþJþKþJþGþHþIþwþšþµþÖþÜÔÝþÜþÚþÖþÍþÂþ¥þ‹þ„þ¥þ¼þËþ×þÜÅÝþÙþÑþÉþµþ•þœþÚþóþùþüþýþüûýûüûþöþìþÐþ¤þmþPþGòKþNþ~þþ¶þÕþÛÔÝþÒþÌþÂþ²þ’þ
…
û†þ³þ½þÉþÒûÛþÜþÝþÜÑÝþÚþÒþÈþ¸þŸþKþNþoþ‘þ¤þ¶þ¼þ°þ©þþqþ]þNþKþJûHõKþJþTþƒþŸþ¶þÔþÛãÝþÛþÚþÛþÚþÒþ¾þª‘’‘þ†õ
…þ²þºþÄþËþÕþ×ûØþÙþÛþÝþÜÚÝþÙþÒþÈþ¶þ 
þYþHþIþHûNþJþIþGþFDEDþJþHþKûGþKþJþIûJþHþYþˆþ¡þµþÓþÛæÝþÙþÖþÔþÑþÉþ¿þŒþ„ø…þ†û…
þªþ´þ¹þ½þÈþËþÌþÎþÐþÑþÔþÖþØþÚþÛûÜìÝþÜþØþÎþÃþ²þþhøIþJÚIûJûIþYþ‰þ 
þ²þÎþØïÝþÛþÚþÕþÐþËþÇþ¿þ«þ’þ„ì…
þþ¢þ©þ­þ²þ¶þºþ½þÀþÃþÄþÈþÌþÑþÓþ×þÙþÛïÝþÚþÒþÇþ¸þ©þœþlòJþIãJþHþIøJþ\þ‰þœþ­þÉþÓþÙþÛûÜûÛþÙþÒþËþÅþÀþµþœþ†ø„ï
…þ„þ…þˆþþžþ¢þ¨þ¬þ¯û³þµþ¸þ¿þÃþÇþÍþÒþ×þØþÚþÛûÚþÕþËþ¾þ®þ 
þ—þkþHþJþHþIïKþMòKþHþGþHþJþIþ^þ†þ—þ§þÂþËþÓþØþÙþÚþÙþ×þÒþÇþ½þ³þªþŽþ…þ„à…þ†û…
þ‡þþ—þþ¡û¥þ§þ«þ¯þ³þºÀÁÀþÆþÊþÎþÒþÔþÏþÇþ½þ²þ¤þ˜þþ`þMþQûRþ]þhækþjþ_ûWþTþQþ_þƒþ”þ¡þ¹þÃþÌþÐûÒþÑþÊþÅþ·þ«þœþˆþ„Ú
…ï„û…û„þ…þ‰þŽþþ”þ›þŸþ¢þ¦þ©þ«þ©þ£þœþ•þ‘þŒþ…þwþƒþ…þ„ø…ï„ì…
û„þƒþ€þ‰þ”þ¨þ«þ­þ°û±þ¯þ«þ§þþ†û…û„×…ì„þ…þ„þƒû„þ…þ‰þþ“þ˜û™þ˜þ•þ’þþŠþ‚þþ…Ý„æ…
þ„þƒþ‚þŒþžþ¢þ£ø¦þ¤þŸþ–ø„Î…ì„þ…ø„û†û…þ†þˆþ‰þþþŽþŒþ‡þþ€û…Ý„æ…þ„þ…
þþ‚þþ”þ—þšþ™þ˜þ•þŒþ‡þ„þ…þ„Î…ì„þ…ø„ï…þƒþ†þƒû‚þ„þƒø…ï„þ…ò„Ý…þ„û‚þ…þˆþ†û…þ„þ…þ„Ô…
€
+endstream
+endobj
+12 0 obj
+7826
+endobj
+13 0 obj
+endobj
+14 0 obj
+7826
+endobj
+15 0 obj
+<<
+/Type /XObject
+/Subtype /Image
+/Name /Ma0
+/Filter [ /RunLengthDecode ]
+/Width 81
+/Height 96
+/ColorSpace /DeviceGray
+/BitsPerComponent 8
+/Length 16 0 R
+>>
+stream
+‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿ‚ÿäÿ€
+endstream
+endobj
+16 0 obj
+125
+endobj
+17 0 obj
+<<
+/Title (penguin.pdf)
+/CreationDate (D:20120619194903)
+/ModDate (D:20120619194903)
+/Producer (ImageMagick 6.6.0-4 2012-04-30 Q16 http://www.imagemagick.org)
+>>
+endobj
+xref
+0 18
+0000000000 65535 f 
+0000000010 00000 n 
+0000000059 00000 n 
+0000000118 00000 n 
+0000000296 00000 n 
+0000000377 00000 n 
+0000000395 00000 n 
+0000000433 00000 n 
+0000000454 00000 n 
+0000008478 00000 n 
+0000008498 00000 n 
+0000008525 00000 n 
+0000016495 00000 n 
+0000016516 00000 n 
+0000016532 00000 n 
+0000016553 00000 n 
+0000016869 00000 n 
+0000016889 00000 n 
+trailer
+<<
+/Size 18
+/Info 17 0 R
+/Root 1 0 R
+>>
+startxref
+17067
+%%EOF

Index: momdoc/version-2.html
===================================================================
RCS file: momdoc/version-2.html
diff -N momdoc/version-2.html
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ momdoc/version-2.html       31 Aug 2012 22:50:00 -0000      1.1
@@ -0,0 +1,380 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+This file is part of groff, the GNU roff type-setting system.
+
+Copyright (C) 2004, 2005, 2006, 2009, 2010,
+2011, 2012 Free Software Foundation, Inc.
+Written by Peter Schaffter (address@hidden).
+
+Permission is granted to copy, distribute and/or modify this document
+under the terms of the GNU Free Documentation License, Version 1.3 or
+any later version published by the Free Software Foundation; with the
+Invariant Sections being this comment section, with no Front-Cover
+Texts, and with no Back-Cover Texts.
+
+A copy of the Free Documentation License is included as a file called
+FDL in the main directory of the groff source package.
+-->
+
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
+<html xmlns="http://www.w3.org/1999/xhtml";>
+
+<head>
+  <meta http-equiv="content-type" content="text/html;charset=utf-8"/>
+  <title>Mom -- Version 2.0 notes</title>
+  <link rel="stylesheet" type="text/css" href="stylesheet.css" />
+</head>
+
+<body style="background-color: #f5faff;">
+
+<!-- ==================================================================== -->
+
+<div id="top" class="page">
+
+<!-- Navigation links -->
+<table style="width: 100%;">
+<tr>
+  <td><a href="toc.html">Back to Table of Contents</a></td>
+  <td style="text-align: right;"><a href="intro.html#top">Next: Introduction 
to mom</a></td>
+</tr>
+</table>
+
+<h1 class="docs">Version 2.0 notes</h1>
+
+<div style="width: 70%; margin: auto;">
+<ol style="margin-left: -1em;">
+  <li><a href="#prefatory">Prefatory comments</a></li>
+  <li><a href="#differences">Differences between 2.0 and 1.x</a>
+  <ul class="no-enumerator" style="padding-left: 0">
+    <li><a href="#pdf-support">2.1 PDF support</a>
+    <ul class="no-enumerator" style="padding-left: 1em">
+      <li><a href="#mom-pdf">2.1.1 The manual, <span 
class="book-title">Producing PDFs with groff and mom</span></a></li>
+      <li><a href="#pdf-image">2.1.2 PDF_IMAGE</a></li>
+    </ul></li>
+    <li><a href="#covers">2.2 Covers</a></li>
+    <li><a href="#headings">2.3 Headings</a></li>
+    <li><a href="#margin-notes">2.4 Margin notes</a></li>
+    <li><a href="#floats">2.5 Floats</a></li>
+    <li><a href="#table-of-contents">2.5 Table of contents</a></li>
+  </ul></li>
+  <li><a href="#pdfmom">The <strong>pdfmom</strong> wrapper around 
groff</a></li>
+  <li><a href="#install-font">The <strong>install-font</strong> script</a></li>
+</ol>
+</div>
+
+<div class="rule-medium"><hr/></div>
+
+<h2 id="prefatory" class="docs">1. Prefatory comments</h2>
+
+<p>
+Version 2.0 comes about as a result of Deri James&#8217;
+contribution of <strong>gropdf</strong> to <strong>groff</strong>,
+and his subsequent work integrating the device with
+<strong>mom</strong>.
+</p>
+
+<p>
+Whereas the 1.x releases were oriented toward PostScript output,
+2.0 focuses on PDF output, a bias reflected throughout this
+documentation.  Users are strongly encouraged to process their files
+with
+<a href="#pdfmom"><strong>pdfmom</strong></a>,
+a wrapper around <strong>groff&nbsp;-Tpdf</strong>, in order to take
+full advantage of all PDF has to offer.
+</p>
+
+<p>
+While portions of mom have been rewritten, and new features
+introduced, 2.0 is backwardly compatible with 1.x releases.  Changes
+are either transparent, or accompanied by notifications on stderr.
+</p>
+
+<p>
+The implementation of nested heads has been completely rethought,
+as has the manner of styling of them.  There are no limits on
+how deep the nesting can go.  The 1.x macros <kbd>HEAD</kbd>,
+<kbd>SUBHEAD</kbd>, and <kbd>SUBSUHEAD</kbd> may still be used, but
+must be re-designed with the new <kbd>HEADING_STYLE</kbd> macro
+if their 1.x defaults are not desired.
+</p>
+
+<p>
+In conjunction with the changes to nested heads, Table of Contents
+generation has also been rethought.  Greater flexibility in the
+inclusion of toc entry numbering been added.  Like nested heads,
+there&#8217;s a new macro, <kbd>TOC_ENTRY_STYLE</kbd>, that permits
+styling of each level in the toc hierarchy separately.  The default
+overall layout has also been significantly improved, achieving a
+level of typographical elegance formerly lacking.  Best of all, the
+Table of Contents can now be repositioned to the correct spot at the
+top of a document from within the mom source file.
+</p>
+
+<p>
+When mom files are processed with <strong>pdfmom</strong>, a PDF
+outline for the Contents panel of PDF viewers is automatically
+generated.  In addition, entries in the Table of Contents
+are clickable links when a document is viewed at the screen.
+<strong>pdfmom</strong> also permits setting a document&#8217;s
+papersize within the source file without the corresponding need for
+<kbd>-P-p&lt;papersize&gt;</kbd> on the command line.
+</p>
+
+<p>
+Lastly, while not strictly part of mom, a bash script,
+<strong>install-font</strong>, has been posted at the
+<a href="http://www.schaffter.ca/mom/";>mom site</a>.
+The script significantly eases the installation of new
+groff families and fonts, with conversion to .pfa
+and .t42 being performed by <strong>fontforge</strong>.
+</p>
+
+<h2 id="differences" class="docs">2. Differences between v2.0 and v1.x</h2>
+
+<h3 id="pdf-support" class="docs">2.1. PDF support</h3>
+
+<p>
+PDF support has been added, with features including the automatic
+generation of PDF outlines, embedding of images in PDF format (via
+the
+<a href="images.html#pdf-image">PDF_IMAGE</a>
+macro) and PDF linking (internal and external).
+</p>
+
+<h4 id="mom-pdf" class="docs">2.1.1. Producing PDFs with groff and mom</h4>
+
+<p>
+A manual in PDF format,
+<span class="book-title">Producing PDFs with groff and mom</span>,
+has been added to the documentation.  The file,
+<strong>mom-pdf.pdf</strong> can be found in
+<br/>
+<span class="pre-in-pp">
+  /usr/local/share/doc/groff-1.21/pdf/
+</span>
+or
+<br/>
+<span class="pre-in-pp">
+  /usr/share/doc/groff-base/pdf/
+</span>
+or at
+<br/>
+<span class="pre-in-pp">
+  <a 
href="http://www.schaffter.ca/mom/momdoc/mom-pdf.pdf";>http://www.schaffter.ca/mom/momdoc/mom-pdf.pdf</a>
+</span>
+PDF usage, and all associated macros except
+<a href="#pdf-image">PDF_IMAGE</a>,
+are fully explained in the manual, which should be considered an
+integral part of the present documentation.  In addition, the mom
+source file for the manual can be found in
+<br/>
+<span class="pre-in-pp">
+  /usr/local/share/doc/groff-1.21/examples/mom
+</span>
+or
+<br/>
+<span class="pre-in-pp">
+  /usr/share/doc/groff-base/examples/mom/
+</span>
+and provides an excellent demonstration of mom usage.
+</p>
+
+<h4 id="pdf-image" class="docs">2.1.2. PDF_IMAGE</h4>
+
+<p>
+A new macro for embedding PDF images has been added,
+<a href="images.html#pdf-image"><kbd>PDF_IMAGE</kbd></a>.
+</p>
+
+<p>
+<kbd>PDF_IMAGE</kbd> functions similarly to <kbd>PSPIC</kbd> and
+accepts the same arguments.  Differences in implementation are that
+PDF_IMAGE requires the image dimensions (the bounding box) to be
+supplied.  Instructions for getting the bounding box are included in
+the documentation entry for PDF_IMAGE.  Two additional options,
+<kbd>SCALE</kbd> and <kbd>ADJUST</kbd>, allow scaling of the image
+and optical centering.
+</p>
+
+<h3 id="covers" class="docs">2.2. Covers</h3>
+
+<p>
+Arguments to
+<a href="cover.html#cover"><kbd>COVER</kbd></a>
+and
+<a href="cover.html#doc-cover"><kbd>DOC_COVER</kbd></a>
+may now be given in any order.
+</p>
+
+<h3 id="headings" class="docs">2.3. Headings</h3>
+
+<p>
+The 1.x macros
+<br/>
+<span class="pre-in-pp">
+  HEAD SUBHEAD SUBSUBHEAD
+</span>
+are now deprecated and have been replaced by a single macro,
+<br/>
+<span class="pre-in-pp">
+  <a href="docelement.html#heading"><kbd>HEADING &lt;n&gt;</kbd></a>
+</span>
+where <kbd>&lt;n&gt;</kbd> is the heading level.  The deprecated
+macros may still be used, and conform in style to their original
+defaults; they are, however, wrappers around
+<kbd>HEADING</kbd> levels 1 - 3.
+Both the wrappers and <kbd>HEADING</kbd> itself can take a
+<kbd>NAMED &lt;id&gt;</kbd> argument, specifying a PDF link
+destination.
+</p>
+
+<p>
+Styling of headings is managed by a single macro,
+<br/>
+<span class="pre-in-pp">
+  <a href="docelement.html#heading"><kbd>HEADING_STYLE &lt;n&gt;</kbd></a>
+</span>
+where <kbd>&lt;n&gt;</kbd> conforms to a <kbd>HEADING</kbd> level.
+The control macros for HEAD, SUBHEAD and SUBSUBHEAD have been
+removed.  Users wishing to style the wrappers must use
+<kbd>HEADING_STYLE</kbd>.
+</p>
+
+<p>
+<kbd>PARAHEAD</kbd> is no longer valid.  Paragraph heads in
+2.0 are created by passing the <kbd>PARAHEAD</kbd> argument to
+<kbd>.HEADING</kbd>.  Mom will abort with an informational message
+whenever she encounters <kbd>.PARAHEAD</kbd>.
+</p>
+
+<h3 id="margin-notes" class="docs">2.4. Margin notes</h3>
+
+<p>
+The macro for setting margin note parameters,
+<a href="docelement.html#mn-init"><kbd>MN_INIT</kbd></a>,
+has been re-written such that each parameter now has the form
+<br/>
+<span class="pre-in-pp">
+  &lt;PARAMETER&gt; &lt;value&gt;
+</span>
+This differs from 1.x where parameters were entered without a
+preceding <kbd>&lt;PARAMETER&gt;</kbd> flag.  Parameters may be
+entered in any order.  Any that are skipped are set to default
+values.  Documents created with 1.x will have to have their
+<kbd>MN_INIT</kbd> updated accordingly.
+</p>
+
+<h3 id="floats" class="docs">2.5. Floats</h3>
+
+<p>
+A
+<a href="images.html#floats-intro">FLOAT</a>
+macro has been added, which functions similarly to the <kbd>ms</kbd>
+macros&#8217; <kbd>.KF/.KE</kbd>, ie the contents of the float are
+output immediately if there&#8217;s room on the page; otherwise,
+normal text processing continues and the contents are output at the
+top of the next page.  An <kbd>ADJUST</kbd> argument to FLOAT allows
+for optical centering.
+</p>
+
+<h3 id="table-of-contents" class="docs">2.6. Table of contents</h3>
+
+<p>
+The default look of the Table of Contents has been overhauled to
+produce a more typographically pleasing result.  All control macros
+for TOC title and entry styles have been removed, replaced by the
+macros
+<br/>
+<span class="pre-in-pp">
+  <a href="tables-of-contents.html#toc-title-style">TOC_TITLE_STYLE</a>
+</span>
+and
+<br/>
+<span class="pre-in-pp">
+  <a href="tables-of-contents.html#toc-title-style">TOC_ENTRY_STYLE 
&lt;n&gt;</a>
+</span>
+where <kbd>&lt;n&gt;</kbd> corresponds to a <kbd>HEADING</kbd>
+level.  Both macros permit setting any or all of the style
+parameters for TOC titles (ie chapters or major sections/divisions
+of a collated document) and TOC entries (nested heading levels) at
+once.  Documents created with 1.x that contain TOCs will need to
+have their TOC style updated if the new defaults are unsatisfactory.
+</p>
+
+<p>
+Two new TOC control macros have been added,
+<br/>
+<span class="pre-in-pp">
+  <a href="tables-of-contents.html#space-toc-items">SPACE_TOC_ITEMS</a>
+</span>
+and
+<br/>
+<span class="pre-in-pp">
+  <a
+  href="tables-of-contents.html#auto-relocate-toc">AUTO_RELOCATE_TOC</a>
+</span>
+<kbd>SPACE_TOC_ITEMS</kbd> groups TOC entry levels and separates
+them with a discrete amount of whitespace.  This leads to improved
+legibility, and is highly recommended even though it is not
+mom&#8217;s default. <kbd>AUTO_RELOCATE_TOC</kbd> intelligently
+repositions the Table of Contents to the top of a document when
+the mom source file is processed with
+<a href="pdfmom"><strong>pdfmom</strong></a>.
+</p>
+
+<h2 id="pdfmom" class="docs">3. pdfmom</h2>
+
+<p>
+Deri James has provided <strong>pdfmom</strong>, a wrapper around
+groff that processes mom source files with all the PDF bells and
+whistles.  Its use is highly recommended.  Usage is explained in the
+manual,
+<a href="http://www.schaffter.ca/mom/pdf/mom-pdf.pdf";><span 
class="book-title">Producing PDFs with groff and mom</span></a>.
+A significant convenience of <strong>pdfmom</strong> is that it can,
+with the <kbd>-Tps</kbd> flag, be used to pass processing over to Keith
+Marshall&#8217;s <strong>pdfroff</strong>.  This is useful when
+processing files that contain PostScript images embedded with
+<kbd>PSPIC</kbd>. <strong>pdfmom</strong>, without the flag, uses
+groff&#8217;s PDF device (<strong>gropdf</strong>), which only
+recognizes PDF images that have been embedded with
+<a href="images.html#pdf-image"><kbd>PDF_IMAGE</kbd></a>.
+</p>
+
+<h2 id="install-font" class="docs">4. install-font</h2>
+
+<p>
+A bash script, <strong>install-font</strong>, has been posted at the
+<a href="http://www.schaffter.ca/mom/";>mom site</a>.
+There&#8217;s nothing mom-specific about the script, and it is not
+an official part of groff.
+</p>
+
+<p>
+Installing groff fonts is a multi-step procedure, which, while not
+difficult, can be a nuisance.  <strong>install-font</strong> takes
+care of all the details, including converting fonts to formats
+acceptable to <strong>grops</strong> and <strong>gropdf</strong>,
+creating and installing the groff fonts in the appropriate
+directories, updating the <strong>download</strong> files, and
+installing the original fonts in a system-wide directory, if
+desired.
+</p>
+
+<div class="rule-long"><hr/></div>
+
+<!-- Navigation links -->
+<table style="width: 100%; margin-top: 12px;">
+<tr>
+  <td style="width: 33%;"><a href="toc.html">Back to Table of Contents</a></td>
+  <td style="width: 20%; text-align: center;"><a href="#top">Top</a></td>
+  <td style="width: 46%; text-align: right;"><a href="intro.html">Next: 
Introduction to mom</a></td>
+</tr>
+</table>
+
+</div>
+
+<div class="bottom-spacer"><br/></div>
+
+</body>
+</html>
+<!-- vim: fileencoding=utf-8: nomodified: -->



reply via email to

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