From 3bc77bb2d32741f951be5d2ff5364422b3b2585b Mon Sep 17 00:00:00 2001 From: Werner LEMBERG Date: Sat, 14 May 2005 07:07:13 +0000 Subject: [PATCH] *Thu May 12 2005 o Added margin notes capability o Added mom-specific refer support; refer calls can be embedded in running text, sent to footnotes or endnotes, or collected for output on a bibliography page; also added mom-specific refer control macros o Added bibliography page capability, with full suite of control macros o Added referencing of footnotes and endnotes by line number o Added capability to have footnotes run on when footnotes are being referenced by line number o Added a post footnote space option, in case users want a little space between their footnotes o Added ENDNOTE_MARKER_STYLE, so user can choose between endnotes identified by a numerical marker in the text, or by line number o Added control macros to accommodate differing needs for endnotes identified by line number o Added ENDNOTE_TITLE_SPACE, so user can control starting position of the endnotes page title o Extended LIST so that it accepts lowercase alpha, uppercase roman numeral and lowercase roman numeral enumerators; also added a "prefix" argument (which comes *after* the separator argument) o Changed RESET_LIST so that it can reset a list to any number, letter, or roman numeral, instead of just 1, a, A, I and i o Change to handling of footnote/endnote markers in text; input lines before FOOTNOTE still require \c, but input line after FOOTNOTE OFF must be entered as a literal continuation of the line before FOOTNOTE, including any required word space or punctuation (this so users can get the footnote marker in text either before or after the punctuation without hassle) o Added QUOTE_AUTOLEAD and BLOCKQUOTE_AUTOLEAD, so user can have quotes and blockquotes leaded differently from running text o Reworked QUOTE and BLOCKQUOTE to accommodate _AUTOLEAD control; spacing above and below quotes is equalized *on a per quote basis* (not completely happy with this, but at least it gives users some flexibility in designing (block)quotes) *Fri Mar 18 2005 o Added mom.vim to /examples --- contrib/mom/BUGS | 15 + contrib/mom/ChangeLog | 60 +- contrib/mom/NEWS | 32 + contrib/mom/copyright | 4 +- contrib/mom/examples/README.txt | 24 +- contrib/mom/examples/elvis_syntax | 1 + contrib/mom/examples/elvis_syntax.new | 11 +- contrib/mom/examples/sample_docs.mom | 10 +- contrib/mom/momdoc/appendices.html | 13 +- contrib/mom/momdoc/color.html | 8 +- contrib/mom/momdoc/cover.html | 14 +- contrib/mom/momdoc/docelement.html | 1849 +++++++++++--- contrib/mom/momdoc/docprocessing.html | 126 +- contrib/mom/momdoc/goodies.html | 28 +- contrib/mom/momdoc/headfootpage.html | 54 +- contrib/mom/momdoc/inlines.html | 6 +- contrib/mom/momdoc/intro.html | 12 +- contrib/mom/momdoc/letters.html | 8 +- contrib/mom/momdoc/macrolist.html | 122 +- contrib/mom/momdoc/refer.html | 1482 +++++++++++ contrib/mom/momdoc/reserved.html | 760 ++++-- contrib/mom/momdoc/toc.html | 40 +- contrib/mom/momdoc/typemacdoc.html | 10 +- contrib/mom/momdoc/typesetting.html | 112 +- contrib/mom/momdoc/using.html | 32 +- contrib/mom/om.tmac | 4531 ++++++++++++++++++++++++++------- 26 files changed, 7616 insertions(+), 1748 deletions(-) create mode 100644 contrib/mom/momdoc/refer.html diff --git a/contrib/mom/BUGS b/contrib/mom/BUGS index 28fcc721..b428a7aa 100644 --- a/contrib/mom/BUGS +++ b/contrib/mom/BUGS @@ -5,6 +5,8 @@ how things ought to be. Post to the groff mailing list with bug reports, questions and suggestions, or contact me directly at: + peter@faustus.dyn.ca + or ptpi@golden.net If writing me directly, please include the word "groff" or "mom" in @@ -15,6 +17,19 @@ Also, please--no html email. That, too, gets nuked. ======================================================================== +Version 1.2-f +============ + +Multiple line subheads near page bottom sometimes printing one line +of subhead at page bottom, and subsequent lines on next page. +---Fixed--- + +Post-quote spacing still wonky when paragraph spacing is turned on. +---Fixed--- (for good would be nice) + +RULE not always resetting quad and quad value. +---Fixed--- + Version 1.2-e ============= diff --git a/contrib/mom/ChangeLog b/contrib/mom/ChangeLog index ab3b6df1..ca400201 100644 --- a/contrib/mom/ChangeLog +++ b/contrib/mom/ChangeLog @@ -1,3 +1,58 @@ +*Thu May 12 2005 + +o Added margin notes capability + +o Added mom-specific refer support; refer calls can be embedded in + running text, sent to footnotes or endnotes, or collected for + output on a bibliography page; also added mom-specific refer + control macros + +o Added bibliography page capability, with full suite of control + macros + +o Added referencing of footnotes and endnotes by line number + +o Added capability to have footnotes run on when footnotes are + being referenced by line number + +o Added a post footnote space option, in case users want a little + space between their footnotes + +o Added ENDNOTE_MARKER_STYLE, so user can choose between endnotes + identified by a numerical marker in the text, or by line number + +o Added control macros to accommodate differing needs for endnotes + identified by line number + +o Added ENDNOTE_TITLE_SPACE, so user can control starting position + of the endnotes page title + +o Extended LIST so that it accepts lowercase alpha, uppercase roman + numeral and lowercase roman numeral enumerators; also added a + "prefix" argument (which comes *after* the separator argument) + +o Changed RESET_LIST so that it can reset a list to any number, + letter, or roman numeral, instead of just 1, a, A, I and i + +o Change to handling of footnote/endnote markers in text; input + lines before FOOTNOTE still require \c, but input line after + FOOTNOTE OFF must be entered as a literal continuation of the + line before FOOTNOTE, including any required word space or + punctuation (this so users can get the footnote marker in text + either before or after the punctuation without hassle) + +o Added QUOTE_AUTOLEAD and BLOCKQUOTE_AUTOLEAD, so user can have + quotes and blockquotes leaded differently from running text + +o Reworked QUOTE and BLOCKQUOTE to accommodate _AUTOLEAD control; + spacing above and below quotes is equalized *on a per quote + basis* (not completely happy with this, but at least it gives + users some flexibility in designing (block)quotes) + +*Fri Mar 18 2005 + +o Added mom.vim to /examples + *Thu Jan 20 2005 o Added \*[TB+] and \*[B] to give inline functionality of .TN and @@ -11,6 +66,10 @@ o Added a NOBREAK option to PAD, so when PAD is called, it's possible *Wed Jan 19 2005 +o New macro, ADD_SPACE, so that extra space can be added at the + top of a new page in document processing; the .ns call in HEADER + was making additional space impossible + o Reworked handling of ALD/SPACE/SP and LS when they're used at the tops of pages during pure (i.e. non-docprocessing) typesetting. First lines were still wandering. Should also be @@ -19,7 +78,6 @@ o Reworked handling of ALD/SPACE/SP and LS when they're used at first baseline (i.e. merely sets the lead for the text that follows). - *Tue Dec 14 2004 o Fixed a small problem with spacing under quotes when paragraph diff --git a/contrib/mom/NEWS b/contrib/mom/NEWS index a41e9e8a..2433eb00 100644 --- a/contrib/mom/NEWS +++ b/contrib/mom/NEWS @@ -1,3 +1,35 @@ +Release 1.3 +----------- + +Added line numbering capabilities, with controls. + +Footnotes and endnotes can now be referenced by line number. + +Added ability to adjust vertical position of the title that appears +on the first endnotes page. + +Footnotes can run on when being referenced by line number. + +Footnotes now have a post-footnote spacing option, for adding +a little space between footnotes. + +Extended LIST so it accepts alpha, ROMAN and roman enumerators. + +Added margin notes capability. + +Added refer support. + +Added bibliography page support. + +Added QUOTE_AUTOLEAD and BLOCKQUOTE_AUTOLEAD, so user can have +quotes and blockquotes leaded differently from running text. + +Change: the input line immediately after FOOTNOTE OFF must be +entered as a literal continuation of the line prior to FOOTNOTE, +including any initial spaces or punctuation marks. This allows +for hassle-free placing of footnote markers in running text either +before or after punctuation marks. + Release 1.2-f ------------- diff --git a/contrib/mom/copyright b/contrib/mom/copyright index 7b7a1105..51756d00 100644 --- a/contrib/mom/copyright +++ b/contrib/mom/copyright @@ -1,6 +1,6 @@ AUTHOR ------ -Peter Schaffter (ptpi@golden.net) +Peter Schaffter (peter@faustus.dyn.ca) (ptpi@golden.net) 320 Gordon St. Fergus, Ontario CANADA @@ -9,7 +9,7 @@ N1M 2W3 ======================================================================== The groff macro file om.tmac and the html documentation pertaining -to it are copyright (c) 2004 Peter Schaffter. +to it are copyright (c) 2004, 2005 Peter Schaffter. om.tmac is issued under the GNU General Public License, a full copy of which can be had at diff --git a/contrib/mom/examples/README.txt b/contrib/mom/examples/README.txt index c38aaba6..65188a79 100644 --- a/contrib/mom/examples/README.txt +++ b/contrib/mom/examples/README.txt @@ -90,4 +90,26 @@ being maintained. Users are encouraged to update to elvis 2.2h or higher, and to use elvis_syntax.new for mom highlighting. I'll be very happy if someone decides to send me syntax highlighting -rules for vim and emacs. :) +rules for emacs. :) + +***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 +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 + +Contact Christian (cvjb@cvjb.de) if you have any suggestions or +requests. diff --git a/contrib/mom/examples/elvis_syntax b/contrib/mom/examples/elvis_syntax index 15fa9c23..64fbb3b0 100644 --- a/contrib/mom/examples/elvis_syntax +++ b/contrib/mom/examples/elvis_syntax @@ -47,6 +47,7 @@ font args BOLDER BOLDERX SLANT SLANTX font args UP DOWN BCK FWD BU BP FU FP font args ROM IT BD BDI PREV font args ST +font args SUSPEND RESUME prefix { \{ \{\ font braces { \{ \{\ diff --git a/contrib/mom/examples/elvis_syntax.new b/contrib/mom/examples/elvis_syntax.new index 4381a7aa..d31e0c26 100644 --- a/contrib/mom/examples/elvis_syntax.new +++ b/contrib/mom/examples/elvis_syntax.new @@ -50,21 +50,22 @@ font args FINAL DRAFT font args BLOCK QUAD font args LEFT RIGHT CENTER CENTRE JUSTIFY TOP BOTTOM L R C J font args OFF QUIT END EXIT DONE NO ALL -font args PAGE NUMBER STAR +font args PAGE NUMBER STAR LINE font args LETTER LEGAL EXECUTIVE LEDGER TABLOID QUARTO FOLIO font args 10x14 A3 A4 A5 B4 B5 font args SINGLESPACE font args FACTOR -font args DASH BULLET ALPHA DIGIT USER +font args DASH BULLET ALPHA DIGIT USER ROMAN roman alpha +font args SUSPEND RESUME font args RGB CYM CMYK GRAY GREY font args COND CONDX EXT EXTX SUP SUPX CONDSUP CONDSUPX EXTSUP EXTSUPX font args BOLDER BOLDERX SLANT SLANTX -font args UP DOWN BCK FWD BU BP FU FP +font args UP DOWN BCK FWD BU BP FU FP FN_MARK EN_MARK font args ROM IT BD BDI PREV font args ST -prefix { \{ \} \{\ -font braces { \{ \} \{\ +prefix { \{ \} \{\ } +font braces { \{ \} \{\ } prefix [ ] font brackets [ ] prefix \(bu \(co \(ct \(de \(dg \(di \(em \(en \(mu \(pl \(rg \(sc \(sq \(lq \(rq diff --git a/contrib/mom/examples/sample_docs.mom b/contrib/mom/examples/sample_docs.mom index 2960dc88..592c75e1 100644 --- a/contrib/mom/examples/sample_docs.mom +++ b/contrib/mom/examples/sample_docs.mom @@ -378,7 +378,7 @@ sit amet. Sadipscing\c Sadipscing diam nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna ali\%quyam erat, sed diam voluptua. .FOOTNOTE OFF -elitr sed diam nonumy eirmod tempor invidunt. Ut labore et do\%lo\%re + 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. Stet clita kasd gubergren no sea. \# @@ -408,7 +408,7 @@ No sea takimata\c Takimata sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna ali\%quyam erat, sed diam voluptua. .FOOTNOTE OFF -sanctus est lorem. Ipsum dolor sit amet, consetetur + 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 do\%lo\%res et ea rebum amet. Consetetur sadipscing @@ -446,7 +446,7 @@ Labore 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. .FOOTNOTE OFF -Et do\%lo\%re et magna ali\%quyam erat, sed diam voluptua, at vero. + Et do\%lo\%re et magna ali\%quyam erat, sed diam voluptua, at vero. Eos et accusam et justo duo. .BLOCKQUOTE OFF \# @@ -495,7 +495,7 @@ tempor invidunt ut labore et do\%lo\%re. Magna ali\%quyam\c .FOOTNOTE Aliquyam nonumy eirmod tempor invidunt ut labore. .FOOTNOTE OFF -erat, sed diam + erat, sed diam voluptua at vero eos et accusam. Et justo duo do\%lo\%res et ea rebum, stet clita kasd gubergren, no sea takimata. .PP @@ -555,7 +555,7 @@ sit amet. Sadipscing\c Sadipscing diam nonumy eirmod tempor invidunt ut labore et do\%lo\%re magna ali\%quyam erat, sed diam voluptua. .FOOTNOTE OFF -elitr sed diam nonumy eirmod tempor invidunt. Ut labore et do\%lo\%re + 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. Stet clita kasd gubergren no sea takimata lorem. Ipsum dolor sit amet, consetetur sadipscing elitr. diff --git a/contrib/mom/momdoc/appendices.html b/contrib/mom/momdoc/appendices.html index dc1ecb53..fa62535e 100644 --- a/contrib/mom/momdoc/appendices.html +++ b/contrib/mom/momdoc/appendices.html @@ -597,8 +597,10 @@ As a writer living in a perpetual state of penury, all the computers I've ever owned have been hand-me-downs -- several generations out-of-date and "resource challenged". Disk space has always been an issue, as has processor speed and available RAM. -One of the reasons I run Linux is that it has helped enormously to -get the most out of my poor little boxes. +One of the reasons I run GNU/Linux is that it has helped enormously +to get the most out of my poor little boxes. (It has been pointed +out to me that NetBSD might be an even better choice of operating +systems for computers with limited resources.)

In Linux-land, the choice of typesetting systems basically comes down to groff or TeX. Both are wonderful -- monumental achievements if you @@ -616,7 +618,7 @@ However, groff has always had a liability: it's incredibly geeky. Owing to its very long history, it -- and its "power users" -- have remained stuck in a time warp. Most common macro packages still look as they did in those decades when memory was exorbitantly -expensive, and every byte mattered. Documentation -- not always +expensive and every byte mattered. Documentation -- not always easy to find -- is written as if all readers are computer whizzes, or at least have a university degree in one of the higher sciences.

@@ -668,7 +670,10 @@ groff mailing list at (subscription information available here) or contact me, Peter Schaffter, directly at +peter@faustus.dyn.ca +or ptpi@golden.net. +

Please include the word "mom" or "groff" in the Subject: line of any message sent to my personal address, or you @@ -676,7 +681,7 @@ risk the wrath of my implacable spam filters. :)

If you want to visit mom's homepage, you'll find it -here. +here.


Next   diff --git a/contrib/mom/momdoc/color.html b/contrib/mom/momdoc/color.html index 6bd0cead..480c29db 100644 --- a/contrib/mom/momdoc/color.html +++ b/contrib/mom/momdoc/color.html @@ -104,7 +104,7 @@ continue to do so without confusing mom.
  • NEWCOLOR
  • XCOLOR
  • COLOR -
  • \*[<colorname> inline escape +
  • \*[<colorname>] inline escape

    @@ -113,7 +113,7 @@ continue to do so without confusing mom.


    Creating (initializing) a colour with NEWCOLOR


    -Macro: NEWCOLOR <colour name> [<colour scheme>] <colour components> +Macro: NEWCOLOR <colour name> [<colour scheme>] <colour components>

    NEWCOLOR lets you create a colour, rather like an @@ -194,7 +194,7 @@ supplying the name of the color as an argument.


    Initializing a colour with XCOLOR


    -Macro: XCOLOR <X color name> [<alias>] +
    Macro: XCOLOR <X color name> [<alias>]
    *<X color name> must be all one word, all lower case.
    @@ -290,7 +290,7 @@ be all one word, all in lower case.

    Invoking a color


    -Macro: COLOR <colorname> +
    Macro: COLOR <colorname>
    Inline: \*[<colorname>]

    diff --git a/contrib/mom/momdoc/cover.html b/contrib/mom/momdoc/cover.html index 1a95b9c7..c154b110 100644 --- a/contrib/mom/momdoc/cover.html +++ b/contrib/mom/momdoc/cover.html @@ -8,12 +8,12 @@ -Next   +Next   Prev   Back to Table of Contents

    - +

    CREATING A COVER PAGE

    @@ -183,9 +183,9 @@ unless you instruct her otherwise with
    Macro: DOC_COVER
    - Required argument: TITLE | DOCTITLE | COVERTITLE | CHAPTER | CHAPTER_TITLE | CHAPTER+TITLE + Required argument:
    TITLE | DOCTITLE | COVERTITLE | CHAPTER | CHAPTER_TITLE | CHAPTER+TITLE
    - Optional arguments: [ SUBTITLE AUTHOR DOCTYPE COPYRIGHT MISC ] + Optional arguments:
    [ SUBTITLE AUTHOR DOCTYPE COPYRIGHT MISC ]

    *Note: these macros should be placed in the "style-sheet" section of your document setup (see the @@ -361,9 +361,9 @@ would in the


    - Macro: COVERS <toggle> + Macro: COVERS <toggle>
    - Macro: DOC_COVERS <toggle> +
    Macro: DOC_COVERS <toggle>

    By default, if you give mom a @@ -504,7 +504,7 @@ it's more likely you want to get MISC right first.)


    -Next   +Next   Prev   Top   Back to Table of Contents diff --git a/contrib/mom/momdoc/docelement.html b/contrib/mom/momdoc/docelement.html index f006657d..20fa9aa8 100644 --- a/contrib/mom/momdoc/docelement.html +++ b/contrib/mom/momdoc/docelement.html @@ -62,10 +62,10 @@ the tag.

    The control macros for document processing tags let you "design" the look of all the parts of your documents -- -should you wish. At a bare minimum, all tags have macros to -change mom's defaults for family, font -and point size. Where appropriate, there are macros to control -leading, indents and quad as well. +should you wish. At a bare minimum, all tags have macros to change +mom's defaults for family, font, point size and +colour. Where appropriate, there are macros to control leading, +indents and quad as well.

    In addition, many tags have special macros to control features that are pertinent to those tags alone. Have a look at the section dealing @@ -221,7 +221,7 @@ arguments as

  • PARAHEAD
  • Parahead control -
  • Linebreaks (author linebreaks) +
  • Linebreaks (author linebreaks, section breaks)
  • List control +
  • Line numbering +
  • Footnotes -
  • Document termination -
  • Endnotes +
  • Margin notes +
      +
    • MN_INIT -- initialize margin notes +
    • MN -- start and end a margin note +
    +
  • Bibliographies and references + +
  • Blank pages
  • Table of contents -
  • Blank page +
  • Document termination + +
    @@ -299,7 +318,7 @@ epigraph "blocks."

    - Macro: EPIGRAPH <toggle> | [ BLOCK ] + Macro: EPIGRAPH <toggle> | [ BLOCK ]

    @@ -759,7 +778,7 @@ head control macros.


    - Macro: HEAD "<text of head>" [ "<2nd line>" [ "<3rd line>" ... ] ] + Macro: HEAD "<text of head>" [ "<2nd line>" [ "<3rd line>" ... ] ]

    @@ -984,7 +1003,7 @@ subhead control macros.


    - Macro: SUBHEAD "<text of subhead>" [ "<2nd line>" [ "<3rd line>" ... ] ] + Macro: SUBHEAD "<text of subhead>" [ "<2nd line>" [ "<3rd line>" ... ] ]

    The argument to SUBHEAD is the text of the subhead, @@ -1092,7 +1111,7 @@ parahead control macros.


    - Macro: PARAHEAD "<text of parahead>" + Macro: PARAHEAD "<text of parahead>"

    PARAHEAD must come AFTER @@ -1241,7 +1260,7 @@ macro.

    Linebreak character control macro

    - Macro: LINEBREAK_CHAR [ <character> ] [ <iterations> [ <vertical adjustment> ] ] + Macro: LINEBREAK_CHAR [ <character> ] [ <iterations> [ <vertical adjustment> ] ]
    Alias: SECTION_CHAR @@ -1291,7 +1310,7 @@ the vertical adjustment is -2 points for

    Linebreak colour control macro

    - Macro: LINEBREAK_COLOR <color name> + Macro: LINEBREAK_COLOR <color name>

    To change the colour of the linebreak character(s), simply invoke @@ -1359,6 +1378,34 @@ and as does the control macro QUOTE_INDENT.

    +Version 1.3: mom's handling of the vertical +whitespace around quotes has changed slightly. In versions prior +to 1.3, it was not possible to alter the +leading +of quotes and blockquotes (which was the same as the document +leading), ensuring that the vertical whitespace remained consistent, +as described above. In 1.3 and later, it is possible to change the +leading of quotes and blockquote via +the QUOTE_AUTOLEAD and +BLOCKQUOTE_AUTOLEADmacro. Now, 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, +flexible amount of extra whitespace around the quotes to make sure +the whitespace is equal, top and bottom. Since she does this on a +quote by quote basis, rather than by figuring out how much extra +whitespace is needed to adjust all quotes on a page, +the spacing around multiple quotes on the same page will differ +slightly, although each will be balanced between lines of normal +running text, +top and bottom. (The inability to scan an entire page and insert +equalized whitespace at marked places is a limitation of groff, +which, by and large, works in a linear, line by line fashion.) +If you don't provide mom with a +QUOTE_AUTOLEAD, quotes are leaded at the default +for normal running text, meaning that multiple quotes on the same +page are all spaced identically. +

    TIP: If you want to include snippets of programming code in mom documents, you may come acropper of the fact @@ -1407,7 +1454,7 @@ font like Courier):


    - Macro: QUOTE toggle + Macro: QUOTE toggle

    @@ -1428,7 +1475,7 @@ argument (e.g. OFF, END, X, Q...) to turn it off. Example:

    Quote control macros

      -
    1. Family/font/size/colour/indent +
    2. Family/font/size/leading/colour/indent
    3. Spacing above and below (typeset only)
    4. Underline quotes (typewrite only)
    5. Manually break a footnoted quote that crosses pages/columns @@ -1440,13 +1487,14 @@ See Arguments to the control macros.

      -.QUOTE_FAMILY default = prevailing document family; default is Times Roman
      -.QUOTE_FONT   default = italic
      -.QUOTE_SIZE   default = +0 (i.e. same size as paragraph text)
      -.QUOTE_COLOR  default = black
      -.QUOTE_INDENT default = paragraph indent x 3 (typeset); x 2 (typewrite)
      -             (note that this macro also sets the indents (left and right)
      -              for blockquotes)
      +.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_AUTOLEAD default = none; leading of quotes is the same as paragraphs
      +.QUOTE_COLOR    default = black
      +.QUOTE_INDENT   default = paragraph indent x 3 (typeset); x 2 (typewrite)
      +               (note that this macro also sets the indents (left and right)
      +                for blockquotes)
       

      2. Spacing above and below -- ALWAYS_FULLSPACE_QUOTES (typeset only)

      @@ -1539,19 +1587,8 @@ Besides indenting blockquotes, mom further sets them off from running text with a small amount of vertical whitespace top and bottom. (See above -for a complete explanation of how this is managed, and how to control it.) -

      -You may notice that BLOCKQUOTE has no macro to -control -leading, -although you can change the point size. There are Very Good -Reasons for this. If you can't live with the limitation, change -the leading of blockquotes (after invoking the tag) with -LS, -but know that there will be Bottom Margin Consequences unless you -use the -SHIM -macro after you turn the blockquote off. +for a complete explanation of how this is managed, and how to control it. +Be sure to read the section Version 1.3.)

      @@ -1559,7 +1596,7 @@ macro after you turn the blockquote off.


      - Macro: BLOCKQUOTE toggle + Macro: BLOCKQUOTE toggle
      Aliases: CITE, CITATION
      @@ -1593,7 +1630,7 @@ macros that begin with BLOCKQUOTE_ or end with

      Blockquote control macros

        -
      1. Family/font/size/colour/quad/indent +
      2. Family/font/size/leading/colour/quad/indent
      3. Spacing above and below (typeset only)
      4. Manually break a footnoted blockquote that crosses pages/columns
      @@ -1604,13 +1641,14 @@ See Arguments to the control macros.

      -.BLOCKQUOTE_FAMILY default = prevailing document family; default is Times Roman
      -.BLOCKQUOTE_FONT   default = italic
      -.BLOCKQUOTE_SIZE   default = -1 (point)
      -.BLOCKQUOTE_COLOR  default = black
      -.BLOCKQUOTE_QUAD   default = left
      -.QUOTE_INDENT      default = paragraph indent x 3 (typeset); x 2 (typewrite)
      -                  (note that this macro also sets the left indent for quotes)
      +.BLOCKQUOTE_FAMILY   default = prevailing document family; default is Times Roman
      +.BLOCKQUOTE_FONT     default = roman
      +.BLOCKQUOTE_SIZE     default = -1 (point)
      +.BLOCKQUOTE_AUTOLEAD default = none; leading of blockquotes is the same as paragraphs
      +.BLOCKQUOTE_COLOR    default = black
      +.BLOCKQUOTE_QUAD     default = left
      +.BLOCKQUOTE_INDENT   default = paragraph indent x 3 (typeset); x 2 (typewrite)
      +                    (note that this macro also sets the left indent for quotes)
       

      2. Spacing above and below -- ALWAYS_FULLSPACE_QUOTES (typeset only)

      @@ -1651,7 +1689,7 @@ initialize a list with the LIST macro. Then, for every item in the list, you invoke the macro, ITEM, followed by the text of the item. When a list is finished, you exit the list with LIST OFF (or -QUIT, END, X, +QUIT, END, BACK, etc.)

      By default mom starts each list with the enumerator @@ -1674,7 +1712,7 @@ like this: In other words, mom does not, by default, indent entire lists. Indenting a list is controlled by the macro, -SHIFT_LIST. +SHIFT_LIST. (This is a design decision; there are too many instances where a default indent is not desirable.) Equally, mom does not add any extra space above or below lists. @@ -1682,7 +1720,8 @@ does not add any extra space above or below lists. Lists can be nested (as in the example above). In other words, you can set lists within lists, each with an enumerator (and possibly, indent) of your choosing. In nested lists, each invocation of -LIST OFF takes you back to the previous depth (or +LIST OFF (you may prefer to use LIST +BACK) takes you back to the previous depth (or level) of list, with that list's enumerator and indent intact. The final LIST OFF exits lists completely and returns you to the left margin of running text. @@ -1696,8 +1735,7 @@ document processing macros or just the typesetting macros.


      - Macro: LIST [ BULLET | DASH | DIGIT | ALPHA | USER ] [ <separator> | <user-defined enumerator> ] [ <off> ] - + Macro: LIST [ BULLET | DASH | DIGIT | ALPHA | alpha | ROMAN<n> | roman<n> | USER <string>] [ <separator> | <user-defined enumerator> ] [ <prefix> ] [ <off> ]

      Invoked by itself (i.e. with no argument), LIST initializes a list (with bullets as the default enumerator). @@ -1705,77 +1743,184 @@ Afterwards, each block of input text preceded by .ITEM, on a line by itself, is treated as a list item.

      +NOTE: Every time you invoke LIST +to start a list (as opposed to +exiting one), +you must supply an enumerator (and optionally, a separator) for the +list, unless you want mom's default enumerator, +which is a bullet. Within nested lists, mom +stores the enumerator, separator and indent for any list you return +backwards to (i.e. with LIST OFF), but +does not store any information for lists you move forward +to. +
      + +

      The first argument--enumerator style

      +

      The optional arguments BULLET, -DASH, DIGIT (for Arabic -numerals), ALPHA (for lowercase letters) and -USER allow you to say what kind of enumerator you -want for a given list. +DASH, DIGIT (for +Arabic numerals), ALPHA (for uppercase +letters), alpha (for lowercase letters), +ROMAN<n> (for uppercase roman numerals), +roman<n> (for lowercase roman numerals) tell +mom what kind of enumerator to use for a given +list. +

      +The arguments, ROMAN<n> and +roman<n>, are special. You must append to +them a digit (arabic, e.g. "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--with a message--if +you don't provide it. +

      +A roman-numeralled list containing, say, five items, would be set +up like this: +

      +

      +	.LIST roman5        producing        i)   Item 1.
      +	.ITEM                                ii)  Item 2.
      +	Item 1.                              iii) Item 3.
      +	.ITEM                                iv)  Item 4.
      +	Item 2.                              v)   Item 5.
      +	.ITEM
      +	Item 3
      +	.ITEM
      +	Item 4
      +	.ITEM
      +	Item 5
      +
      + +

      +The argument, USER, lets you make up your own +enumerator, and must be followed by a second argument: what you'd +like the enumerator to look like. For example, if you want a list +enumerated with +=>,

      -If you choose DIGIT or ALPHA, you -may enter the optional argument separator to say -what kind of separator you want after the enumerator. The separator -can be anything you like. The default for DIGIT is -a period (dot), like this: +

      +	.LIST USER =>
      +	.ITEM
      +	A list item
      +
      + +will produce +

      +

      +	=> A list item
      +
      + +Please note: if the argument to +USER contains spaces, you must enclose the argument +in double quotes. + +
      + +

      The second argument--separator style

      +

      +If you choose DIGIT, ALPHA, +alpha, ROMAN<n>, or +roman<n>, you may enter the optional +argument, separator, to say what kind of separator +you want after the enumerator. The separator can be anything you +like. The default for DIGIT is a period (dot), +like this:

       	1. A list item
       
      -The default separator for ALPHA is a right -parenthesis, like this: +The default separator for ALPHA, +alpha, ROMAN<n> and +roman<n> is a right parenthesis, like this:

      -	a) A list item
      +	a) An alpha-ed list item
      +	b) A second alpha-ed list item
      +
      +	   or
      +
      +	i)  A roman-ed list item
      +	ii) A second roman-ed item
       
      -If you want digits with a right-parenthesis separator, you'd do +If you'd prefer, say, digits with right-parenthesis separators +instead of the default period, you'd do

       	.LIST DIGIT )
       	.ITEM
      -	A list item
      +	A numberd list item
       
      which would produce

      -	1) A list item
      +	1) A numbered list item
       
      -BULLET, DASH and +Please note: BULLET, DASH and USER do not take a separator. +
      + +

      The third argument--prefix style

      -USER lets you make up your own enumerator. For -example, if you want a list enumerated with =>, +Additionally, you may give a prefix (i.e. a character that comes +before the enumerator) when your enumerator style for a +particular list is DIGIT, ALPHA, +alpha, ROMAN<n> +or roman<n>. In the arguments to +LIST, the prefix comes after the +separator, which may seem counter-intuitive, so please be careful. +

      +A prefix can be anything you like. Most likely, you'll want some +kind of open-bracket, such as a left parenthesis. If, for example, +you want a DIGIT list with the numbers enclosed in +parentheses, you'd enter

      -	.LIST USER =>
      +	.LIST DIGIT ) (
       	.ITEM
      -	A list item
      +	The first item on the list.
      +	.ITEM
      +	The second item on the list.
       
      -will produce +which would produce

      -	=> A list item
      +	(1) The first item on the list.
      +	(2) The second item on the list.
       
      -If the argument to USER contains spaces, you must -enclose the argument in double quotes. +Please note: BULLET, DASH and +USER do not take a prefix. +
      + + +

      Exiting lists--.LIST OFF/BACK or .QUIT_LISTS

      -Any single argument other than BULLET, -DASH, DIGIT, -ALPHA or USER takes you out of the -current list. If you are at the first list-level (or -depth), +Any single argument to LIST other +than BULLET, DASH, +DIGIT, ALPHA, +alpha, ROMAN<n>, +roman<n> or USER (e.g. +LIST OFF or LIST +BACK) takes you out of the current list. +

      +If you are at the first list-level (or "list-depth"), mom returns you to the left margin of running text. Any indents that were in effect prior to setting the list are fully -restored. If you are in a nested list, mom moves -you back one list-level and restores the enumerator, separator and -indent appropriate to that level. +restored. +

      +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 enumerator, separator and indent +appropriate to that level.

      -Each invocation of LIST must be matched by a -corresponding LIST OFF in order to fully exit -lists. For example, +Each invocation of LIST should be be matched by +a corresponding LIST OFF in order to fully exit +lists. For example,

       	Lorem ipsum dolor sit amet, consetetur sadipscing elitr,
      @@ -1809,14 +1954,10 @@ is created like this:
       	sed diam nonumy eirmod tempor invidunt ut labore.
       
      -NOTE: Every time you invoke LIST -to start a list (as opposed to exiting one), you must supply an -enumerator (and optionally, a separator) for the list, unless you -want mom's default enumerator, which is a bullet. -Within nested lists, mom stores the enumerator, -separator and indent for any list you return backwards to -(i.e. with LIST OFF), but does not store any -information for lists you move forward to. +Alternatively, you may use the single-purpose macro, +QUIT_LISTS, to get yourself out of a list +structure. In the example above, the two .LIST OFF +lines could be replaced with a single .QUIT_LISTS.


      @@ -1924,11 +2065,11 @@ produces (approximately)

      2. Resetting an initialized list's enumerator -- RESET_LIST

      -In nested lists, if your choice of list enumerator for a given level -of list is either DIGIT or ALPHA, -you may sometimes want to reset the list's enumerator back to -"1" or "a" when you return, within the nest, to -that list. Consider the following: +In nested lists, if your choice of list enumerator for a given +level of list is DIGIT, ALPHA, +alpha, ROMAN or +roman, you may sometimes want to reset the list's +enumerator when you return to that list. Consider the following:

       	Things to do religiously each and every day:
      @@ -1943,19 +2084,25 @@ that list.  Consider the following:
       	   c) canned tuna on Sunday
       
      -Normally, within a nested list, when you return to an alpha- or -digit-enumerated list, the enumerator continues incrementing from -where it left off. That means, in the example above, the normal -state of affairs for the alpha'ed list under "2. Feed the -cat" would be c), d) and e). The solution, in such a case, is -simply to reset the enumerator --before ITEM!-- +Normally, within a nested list, when you return to an +incrementally-enumerated list, the enumerator continues incrementing +from where it left off. That means, in the example above, the +normal state of affairs for the alpha'ed list under "2. Feed +the cat" would be c), d) and e). The solution, in such a case, +is simply to reset the enumerator --before ITEM!-- with the macro, RESET_LIST.

      -RESET_LIST does exactly what it says -- resets the -list -- and doesn't take any arguments. +By default, with no argument, RESET_LIST resets the +enumerator to 1, A, a, I or i depending on the style of enumerator. +You may, if you wish, pass RESET_LISTS a numeric +argument representing the starting enumerator for the reset (if +different from "1"), although I can't at present think of a use for +this feature.

      3. Padding digit enumerators (PAD_LIST_DIGITS)

      +Arabic digits +

      When your choice of enumerators is DIGIT AND the number of items in the list exceeds nine (9), you have to make a design decision: should mom leave room for the @@ -1986,6 +2133,411 @@ If you want the extra space to the left, invoke Of course, if the number of items in the list is less than ten (10), there's no need for PAD_LIST_DIGITS.

      +Roman numerals +

      +By default, mom sets roman numerals in lists flush +left. The <n> argument appended to +ROMAN<n> or roman<n> +allows her to calculate how much space to put after each numeral in +order to ensure that the text of items lines up properly. +

      +If you'd like the roman numerals to line up flush right (i.e. be +padded "left"), simply invoke PAD_LIST_DIGITS +LEFT after LIST ROMAN<n> +or LIST roman<n> amd before +ITEM. +

      +


      + + + +

      Line numbering

      + + +

      +Mom's line-numbering capabilities are not as flexible +as most of her other document processing macros. The reason is +that groff's underlying line-numbering +primitive, +.nm, is, well...primtive. It is not possible, for +example, to select a particular family or font for use exclusively +with line numbers. Nor is it possible to set the +gutter +using any +unit of measure +other than the +figure space. +

      +That said, when you turn line-numbering on, mom, +by default +
      + +

        +
      • numbers every line of paragraph text; line-numbering is + suspended for all other document processing tags (like + docheaders, epigraphs, heads, subheads, etc.) and special + pages (covers, endotes, bibliographies, etc.); be aware, + though, that if you turn + docheaders + off (with + DOCHEADER OFF) + and create your own docheader, mom + will line-number your custom docheader +
      • doesn't touch your line length; line numbers are hung + outside your current left margin (as set with + L_MARGIN, + PAGE + or + DOC_LEFT_MARGIN), + regardless of any indents that may be active +
      • separates line numbers from running text by two + figure spaces. +
      +

      +Line numbering may be enabled and disabled for +QUOTE +and/or +BLOCKQUOTE +in one of three styles. See +Line numbering control macros for quotes and blockquotes. +

      +The first time you invoke +NUMBER_LINES +you must, at a minimum, tell it what line number you want the +next +output line +to have. Optional arguments allow you to state which lines should +be numbered (e.g. every five or every ten lines), and the gutter to +place between line numbers and +running text. +

      +Subsequently, you can turn line-numbering off, either permanently, +or resume it later at a place of your choosing. When you +resume line-numbering, the line numbers pick up where you left off. +

      + + + +


      +

      + + + Macro: NUMBER_LINES <start number> [ <which lines to number> [ <gutter> ] ] +
      +
      Macro: NUMBER_LINES <anything> | RESUME +
      +
      + + +

      +NUMBER_LINES does what it says: prints line +numbers, to the left of +output lines +of paragraph text. One of the chief reasons for wanting numbered +lines is in order to identify footnotes or endnotes by line number +instead of by a marker in the text. (See +.FOOTNOTE_MARKER_STYLE LINE +for instructions on line-numbered footnotes, and +.ENDNOTE_MARKER_STYLE +for instructions on line-numbered endnotes.) +

      +Every time you invoke NUMBER_LINES, unless you are +using the arguments OFF (QUIT, +END, X, etc.) or +RESUME you must, at a minimum, pass it one +argument, namely the number (digit) you want the next +output line +to have. For example, +

      +	.NUMBER_LINES 3
      +
      + +will prepend the number, 3, to the next output line. +

      +Normally, of course, you will number lines of text starting at 1. +All you have to do in that case is ensure that +

      +	.NUMBER_LINES 1
      +
      + +precedes your first line of input text, which will also be the +first line of output text. +

      +You can alter mom's default line numbering +behaviour (see +above) +with the optional arguments <which lines to +number> and <gutter>. +

      +<which lines to number> instructs +NUMBER_LINES to number only certain lines, e.g. +every two lines or every five lines. If you want, say, only every +five lines to have a prepended number, you'd do +

      +	.NUMBER_LINES 1 5
      +
      + +GOTCHA! The argument to <which +lines to number> only numbers those lines that are +multiples of the argument. Hence, in the above example, line +number "1" will not be numbered, since "1" is not a +multiple of "5". +

      +If you wanted line number "1" to be numbered, you'd have to invoke +.NUMBER_LINES 1 1 before the first output line, then +study your output copy and determine where best to insert +the following in your input copy: +

      +	.NUMBER_LINES \n(ln 5
      +
      + +(The escape, \n(ln, ensures that +NUMBER_LINES automatically supplies the correct +value for the first argument, <start +number>.) +

      +Following this recipe, line number 1 will be numbered; subsequently, +only line numbers that are multiples of 5 will be numbered. A +little experimentation may be required to determine the best place +for it. +

      +The optional argument, <gutter>, tells +mom how much space to put between the line numbers +and the running text. +

      +Note: when giving a value for +<gutter>, you cannot skip the +<which lines to number> argument. Either +fill in the desired value, or use two double-quotes +("") to have mom use the value +formerly in effect. +

      +<gutter> does not require (or even accept) a +unit of measure. +The argument you pass to it is the number of +figure spaces +you want between line numbers and running text. +Mom's default gutter is two figure spaces. If +you'd like a wider gutter, say, four figures spaces, you'd do +

      +	.NUMBER_LINES 1 1 4
      +	                |
      +	                +-- Notice you *must* supply a value
      +	                    for the 2nd argument in order to supply
      +	                    a value for the 3rd.
      +
      + +

      +After you've set up line-numbering, NUMBER_LINES +can be used to control line numbering. +
      +

      Line-numbering control

      +

      +NUMBER_LINES OFF (or END, QUIT, X, etc.) +turns line-numbering off. +

      +Sometimes, you merely want to suspend line-numbering. In that case, +turn line numbering off with NUMBER_LINES OFF. +Later, when you want it to resume, enter +

      +	.NUMBER_LINES RESUME
      +
      + +Line numbering will resume exactly where it left off. If this is +not what you want--say you want to reset the line number to "1"--simply +invoke NUMBER_LINES with whatever arguments +are needed for the desired result. +

      +Extra Notes: +
      +

        +
      1. In document processing, you may invoke NUMBER_LINES + either before or after START. + Mom doesn't care. +
      2. If you're collating documents with + COLLATE, + you should re-invoke, at a minimum, .NUMBER_LINES + 1 for each collated document, in order to ensure that + each begins with the number "1" prepended to the first line + (unless, of course, that is not what you want). +
      3. Occasionally, you may want to change the current gutter + between line numbers and running text without knowing + what the next output line number should be. Since + NUMBER_LINES requires this number + as its first argument, in such instances, pass + NUMBER_LINES as its first argument the + escape \n(ln. +

        + For example, if you were numbering every 5 lines with a + gutter of 2 (figure spaces) and you needed to change the + gutter to 4 (figures spaces), +

        +     .NUMBER_LINES \n(ln 5 4 +

        + would do the trick. +

      4. If you're using margin notes in a document, be sure to set + the gutter for margin notes wide enough to allow room for + the line numbers. +
      5. Mom (groff, actually), only numbers lines + to the left of text. For aesthetic reason, + therefore, the use of line numbering when setting a document + in columns is discouraged. However, should you wish to + number lines when setting in columns, make sure the + gutter(s) + between columns is wide enough to leave room for the + numbers. +
      +
      + +

      Line numbering control macros for QUOTE and BLOCKQUOTE

      +
        +
      1. NUMBER_QUOTE_LINES +
      2. NUMBER_BLOCKQUOTE_LINES +
      3. Setting up line numbering in quotes and blockquotes on a case by case basis +
      + +

      1. NUMBER_QUOTE_LINES

      +

      +If you'd like mom to number lines of output text +in a +QUOTE +as part of the same order and sequence as paragraph text, simply +invoke NUMBER_QUOTE_LINES by itself. +

      +There is a catch with numbering quotes, though. Owing to groff's +restriction of accepting only the figure space as the line number +gutter's unit of measure, it is not possible for line numbers +in quotes to hang outside a document's overall left margin and +be reliably flush with the line numbers of paragraph text. +Conseqently, line numbers in quotes hang to the left of the quote, +separated from the quote by the <gutter> +argument. +

      +If you'd like to change the gutter for quotes line-numbered in +this way, invoke NUMBER_QUOTE_LINES with a digit +representing the number of +figure spaces +you'd like between the line numbers and the quoted text, like this: +

      +	.NUMBER_QUOTE_LINES 1
      +
      + +With the above, line numbers in quotes (and only quotes) will have +a gutter of 1 figure space. +

      +If you are using "line numbering style" for footnotes +(FOOTNOTE_MARKER_STYLE LINE), +you may not wish to have quotes visibly line-numbered, but +still want to embed footnotes inside quotes. In order to do that, +mom allows you to say NUMBER_QUOTE_LINES +SILENT. +

      +When you invoke NUMBER_QUOTE_LINES +SILENT, mom continues to increment line +numbers while quotes are being output, but they won't appear in the +output copy. (Compare this with mom's default +behaviour of suspending incrementing of line numbers +during the output of quotes.) This allows you to embed +line-numbered footnotes inside quotes and have the line number +"label" in the footnote come out sensibly. +

      +Once having turned NUMBER_QUOTE_LINES on, you +may disable it with NUMBER_QUOTE_LINES OFF (or +QUIT, END, X, +etc). +

      + +

      2. NUMBER_BLOCKQUOTE_LINES

      +

      +If you'd like mom to number lines of output text +in a +BLOCKQUOTE +as part of the same order and sequence as paragraph text, simply +invoke NUMBER_BLOCKQUOTE_LINES by itself. +

      +There is a catch with numbering blockquotes, though. Owing to +groff's restriction of accepting only the figure space as the +line number gutter's unit of measure, it is not possible for line +numbers in blockquotes to hang outside a document's overall left +margin and be reliably flush with the line numbers of paragraph +text. Conseqently, line numbers in blockquotes hang to the +left of the blockquote, separated from the blockquote by the +<gutter> argument. +

      +If you'd like to change the gutter for blockquotes line-numbered in +this way, invoke NUMBER_BLOCKQUOTE_LINES with a digit +representing the number of +figure spaces +you'd like between the line numbers and the blockquoted text, like +this: +

      +	.NUMBER_BLOCKQUOTE_LINES 1
      +
      + +With the above, line numbers in blockquotes (and only blockquotes) +will have a gutter of 1 figure space. +

      +If you are using "line numbering style" for footnotes +(FOOTNOTE_MARKER_STYLE LINE), +you may not wish to have blockquotes visibly line-numbered, +but still want to embed footnotes inside blockquotes. In +order to do that, mom allows you to say +NUMBER_BLOCKQUOTE_LINES SILENT. +

      +When you invoke NUMBER_BLOCKQUOTE_LINES +SILENT, mom continues to increment line +numbers while blockquotes are being output, but they won't appear in +the output copy. (Compare this with mom's default +behaviour of suspending incrementing of line numbers during +the output of blockquotes.) This allows you to embed line-numbered +footnotes inside blockquotes and have the line number "label" in the +footnote come out sensibly. +

      +Once having turned NUMBER_BLOCKQUOTE_LINES on, you +may disable it with NUMBER_BLOCKQUOTE_LINES OFF (or +QUIT, END, X, +etc). +

      + +

      3. Setting up line numbering in quotes and blockquotes on a case by case basis

      +

      +Sometimes, you may want quotes or blockquotes to have a different +line numbering scheme from the one used in the rest of the +document. Or, you may want line numbering enabled only inside a +particular quote or blockquote. A common reason for this would be +if you were using the +QUOTE +macro to insert lines of programming code into a document. (See +here +for suggestions about including programming code snippets in +documents.) +

      +To enable line numbering within quotes or blockquotes on a case by +case basis, simply invoke NUMBER_LINES, with the +arguments you need, immediately after entering QUOTE +or BLOCKQUOTE. (NUMBER_QUOTE_LINES +and/or NUMBER_BLOCKQUOTE_LINES should be turned +off if you're doing this.) The quote or blockquote will then be +line-numbered according to your specifications: the starting line +number of the quote or blockquote will be the one you give as a +first argument to NUMBER_LINES; which lines to +number will be the value you pass to <which lines to +number> (defaults to "1"); line numbers will hang +to the left of the quote or blockquote, separated from the quote or +blockquote by <gutter> (defaults to "2"). +

      +As soon as QUOTE or BLOCKQUOTE is +turned off, line numbering ceases, not only with respect to +subsequent paragraph text (if they are not being line-numbered), +but also for any subsequent invocation of QUOTE or +BLOCKQUOTE. In other words, you must re-enable +quote or blockquote line-numbering inside every instance of +QUOTE or BLOCKQUOTE when +line-numbering either of them on a case by case basis. +


      @@ -1993,6 +2545,9 @@ Of course, if the number of items in the list is less than ten

      Footnotes

      @@ -2007,19 +2562,63 @@ You just type, for example .FOOTNOTE <footnote about who the hell is Schelling> .FOOTNOTE OFF - were generally the points of discussion presenting the most + were generally the points of discussion presenting the most of beauty to the imaginative Morella. -and be done with it. (Note the obligatory use of the -\c -inline escape.) -Mom takes care of everything: -putting footnote markers in the body of the document, keeping track -of how many footnotes are on the page, identifying the footnotes -themselves appropriately, balancing them properly with the bottom -margin, deferring footnotes that don't fit on the page... Even if -you're using +and be done with it. +

      +(Note the obligatory use of the \c +inline escape. +It is required when your +FOOTNOTE_MARKER_STYLE +is either STAR [star/dagger footnotes] or +NUMBER [superscript numbers]; it is NOT to be used +when the FOOTNOTE_MARKER_STYLE is +LINE, or when footnote markers have been disabled +with +.FOOTNOTE_MARKERS +OFF.) +

      +***Version 1.3 change*** +

      +As of version 1.3, the manner of entering the line +after .FOOTNOTE OFF has changed +to accommodate users' differing wishes with respect to +the order of punctuation and footnote markers. The +correct way to enter the line after .FOOTNOTE +OFF--ONLY if your +FOOTNOTE_MARKER_STYLE is +STAR or NUMBER--is to input +it as if it's literally a continuation of the line before +.FOOTNOTE, and therefore begins with either a space +or a punctuation mark, as in the two following examples. +

      +

      +	   Example 1					  Example 2
      +	   ---------                      ---------
      +
      +	A line of text,\c				A line of text\c
      +	.FOOTNOTE						.FOOTNOTE
      +	A footnote line.				A footnote line.
      +	.FOOTNOTE OFF					.FOOTNOTE OFF
      +	 broken up with a comma.		, broken up with a comma.
      +
      +	(last line begins with			(last line begins with
      +	 a literal space)				 the comma and a space)
      +
      + +If your FOOTNOTE_MARKER_STYLE is line, none of +this is a concern. +

      +***End of version 1.3 change*** +

      +After you invoke FOOTNOTE, mom +takes care of everything: putting footnote markers in the body of +the document, keeping track of how many footnotes are on the page, +identifying the footnotes themselves appropriately, balancing them +properly with the bottom margin, deferring footnotes that don't fit +on the page... Even if you're using COLUMNS, mom knows what to do, and Does The Right Thing.

      @@ -2043,6 +2642,7 @@ in the footnotes. Mom tries for a nice balance between too little whitespace and too much, but when push comes to shove, she'll usually opt for ample over cramped. The last lines of footnotes are always flush with the document's bottom margin. +

      If mom sees that a portion of a footnote cannot be fit on its page, she carries that portion over to the next @@ -2084,7 +2684,7 @@ last line). In such a circumstance, mom does not add a blank after the second deferred footnote. If you'd like a blank line separating both deferred footnotes from any footnotes proper to the page the deferred ones were moved to, add the space -manually with by putting a +manually by putting a .SPACE command at the end of the footnote text, before FOOTNOTE OFF (or FOOTNOTE X, QUIT, @@ -2117,12 +2717,53 @@ href="#BREAK_QUOTE">BREAK_QUOTE for a solution.

      +

      Footnote markers and punctuation in the running text

      + +

      +As of version 1.3, the manner of entering the line after +.FOOTNOTE OFF has changed. The correct way to +enter the line after .FOOTNOTE OFF now is to +input it as if it's literally a continuation of the line before +.FOOTNOTE, and therefore begins with either a space +or a punctuation mark, as in the two following examples. +

      +

      +	   Example 1					  Example 2
      +	   ---------                      ---------
      +
      +	A line of text,\c				A line of text\c
      +	.FOOTNOTE						.FOOTNOTE
      +	A footnote line.				A footnote line.
      +	.FOOTNOTE OFF					.FOOTNOTE OFF
      +	 broken up with a comma.		, broken up with a comma.
      +
      +	(last line begins with			(last line begins with
      +	 a literal space)				 the comma and a space)
      +
      + +Care must be taken, though, if the punctuation mark that begins the +line after FOOTNOTE OFF is a period (dot). You +must begin such lines with +\&., like this: +

      +

      +	end of a sentence\c
      +	.FOOTNOTE
      +	A footnote line.
      +	.FOOTNOTE OFF
      +	\&.  A new sentence...
      +
      + +If you omit the \&., the line will vanish! +

      + +


      - Macro: FOOTNOTE <toggle> | INDENT LEFT | RIGHT | BOTH <indent value> + Tag: FOOTNOTE <toggle> | INDENT LEFT | RIGHT | BOTH <indent value>
      *See
      HYPER-IMPORTANT NOTE!!!
      @@ -2164,19 +2805,39 @@ The final word on the that comes immediately before FOOTNOTE MUST terminate with a \c -inline escape. Otherwise, the footnote marker for the word won't be attached to -it (i.e. mom will insert a word space between the word -and the marker). See the +inline escape if your +FOOTNOTE_MARKER_STYLE +is either STAR or NUMBER. +See the footnote example above. +

      +Additionally, the line after a FOOTNOTE +OFF should be entered as if there were no interruption in +the input text, i.e. the line should begin with a literal space or +punctuation mark. See +above. +

      +Do NOT use the \c inline escape if your +FOOTNOTE_MARKER_STYLE is LINE, or +if you have disabled footnote markers with +.FOOTNOTE_MARKERS +OFF. As well, the line after +FOOTNOTE OFF should be entered normally.

      Footnote control macros

      1. Family/font/size/colour/lead/quad
      2. Footnote markers -- on or off -
      3. Footnote marker style -- star+dagger or numbered +
      4. Footnote marker style -- star+dagger, numbered or by line number +
      5. Reset footnote number -- set footnote marker number to 1 +
      6. Inter-footnote spacing
      7. Footnote rule -- on or off
      8. Footnote rule length -- length of footnote separator rule
      9. Adjust vertical position of footnote separator rule @@ -2206,6 +2867,10 @@ you'll have to roll your own. If you want them back on, invoke .FOOTNOTE_MARKERS with no argument. Footnote markers are on by default.

        +If FOOTNOTE_MARKERS are disabled, do NOT use the +\c inline escape to terminate the line before +.FOOTNOTE. +

        3. Footnote marker style -- FOOTNOTE_MARKER_STYLE

        @@ -2223,10 +2888,98 @@ numbers, both in the document body and in the footnote entries themselves. By default, footnote numbers increase incrementally (prev. footnote number + 1) throughout the whole document. You can ask mom to start each page's footnote numbers at 1 -with .RESET_FOOTNOTE_NUMBER (see below). +with .RESET_FOOTNOTE_NUMBER +(see below.) +

        +

        +.FOOTNOTE_MARKER_STYLE LINE lets you have +footnotes which are identified by line number, rather than by a +marker in the text. (Note that +NUMBER_LINES +must be enabled in order to use this marker style.) +

        +With FOOTNOTE_MARKER_STYLE LINE, mom +will identify footnotes either by single line numbers, or line +ranges. If what you want is a single line number, you need only +invoke .FOOTNOTE, without terminating the text +line before it with \c, at the appropriate +place in running text. +

        +If you want a range of line numbers (e.g. [5-11] ), +insert, directly into the first line of the range you want, the +inline escape, +\*[FN-MARK]. For the terminating line number of +the range, you need only invoke .FOOTNOTE, (again, +without attaching \c to the text line before it). +Mom is smart enough to figure out that where +FOOTNOTE was invoked represents the terminating +line number. Range-numbered footnotes are always output on the page +where FOOTNOTE was invoked, not the page where +\*[FN-MARK] appears (subject, of course, to the +rules for footnotes that fall too close to the bottom of a page, as +outlined +here). + +

        +Mom, by default, puts footnote line numbers inside +square brackets. The style of the brackets may be changed with +the macro, FOOTNOTE_LINENUMBER_BRACKETS, which +takes one of three possible arguments: PARENS +("round" brackets), SQUARE (the default) or +BRACES (curly braces). If you prefer a +shortform, the arguments, (, [ or +{ may be used instead. + +

        +If you don't want the numbers enclosed in brackets, you may tell +mom to use a "separator" instead. A common +separator would be the colon, but it can be anything you like. The +macro to do this is FOOTNOTE_LINENUMBER_SEPARATOR, +which takes, as its single argument, the separator you want. For +safety and consistency's sake, ALWAYS enclose the argument in +double-quotes. +

        +The separator can be composed of any legal groff character, or any +combination of characters. A word of caution: when +using a separator, mom doesn't insert a space +after the separator. Hence, if you want the space (you probably +do), you must make the space part of the argument you pass to +FOOTNOTE_LINENUMBER_SEPARATOR. For example, +to get a colon separator with a space after it, you'd do +

        +

        +	.FOOTNOTE_LINENUMBER_SEPARATOR ": "
        +
        + +RUN-ON FOOTNOTES +

        +Finally, if your footnote marker style is LINE, you +may instruct mom to do "run-on style" footnotes. +Run-on footnotes do not treat footnotes as discrete entities, i.e. +on a line by themselves. Rather, each footnote is separated from +the footnote before it by a space, so that the footnotes on any +given page form a continuous block, like lines in a paragraph. The +macro to get +mom to run footnotes on is +.FOOTNOTES_RUN_ON. Invoked by itself, it turns +the feature on. Invoked with any other argument +(OFF, NO, etc.), it turns the +feature off. It is generally NOT a good idea to turn the feature +on and off during the course of a single document. If you do, +mom will issue a warning if there's going to be a +problem. However, it is always perfectly safe to enable/disable the +feature after +COLLATE. +

        +The usual reason for wanting run-on footnotes is that you're +using them to hold many, short references. (See +here +for instructions on using the groff program, +refer, to set up references.) +

        -

        4. Reset footnote number -- RESET FOOTNOTE NUMBER

        +

        4. Reset footnote number -- RESET_FOOTNOTE_NUMBER

        .RESET_FOOTNOTE_NUMBER, by itself, resets footnote numbering so that the next footnote you enter is @@ -2236,7 +2989,23 @@ numbered 1. mom to start every page's footnote numbering at 1.

        -

        5. Footnote rule -- FOOTNOTE_RULE

        +

        5. Inter-footnote spacing -- FOOTNOTE_SPACE

        +

        +If you'd like a little extra space between footnotes, you can have +mom put it in for you by invoking +.FOOTNOTE_SPACE with an argument representing the +amount of extra space you'd like. The argument to +FOOTNOTE_SPACE requires a +unit of measure. +

        +In the following example, footnotes will be separated from each +other by 3 +points. +

        +	.FOOTNOTE_SPACE 3p
        +
        + +

        6. Footnote rule -- FOOTNOTE_RULE

        If you don't want a footnote separator rule, toggle it off with .FOOTNOTE_RULE OFF (or END, @@ -2245,12 +3014,11 @@ QUIT, X...). Toggle it back on by invoking print the rule.

        -

        6. Footnote rule length -- FOOTNOTE_RULE_LENGTH

        +

        7. Footnote rule length -- FOOTNOTE_RULE_LENGTH

        If you want to change the length of the footnote separator rule, invoke .FOOTNOTE_RULE_LENGTH with a length, like this, -

         	.FOOTNOTE_RULE_LENGTH 1i
         
        @@ -2263,7 +3031,7 @@ for both PRINTSTYLES.

        -

        7. Adjust vertical position of footnote separator rule -- FOOTNOTE_RULE_ADJ

        +

        8. Adjust vertical position of footnote separator rule -- FOOTNOTE_RULE_ADJ

        The footnote separator rule is actually a baseline rule that falls on the @@ -2285,180 +3053,111 @@ the rule, not lower it. A unit of measure is required.

        -Tip: If your +Tip: If your document leading is 2 points or less (e.g your point size is 10 and your linespacing is 10, 11, or 12, lowering -mom's default footnote rule adjustment will almost -certainly give you nicer looking results than leaving the -adjustment at the default. Furthermore, you can invoke -FOOTNOTE_RULE_ADJ on any page (or in any column) -in which footnotes appear, so that the placement of the footnote -rule can be changed on-the-fly, should you wish to do so. +mom's default footnote rule adjustment will +almost certainly give you nicer looking results than leaving +the adjustment at the default. Furthermore, you can invoke +FOOTNOTE_RULE_ADJ on any page in which footnotes +appear, or in any column, so that the placement of the footnote rule +can be changed on-the-fly, should you wish to do so.


        -

        Terminate document processing

        +

        Endnotes

        -The use of FINIS is optional. If you invoke it -(at the end of a document before -TOC -or -ENDNOTES), -mom -deposits the word END, centred after a blank line, beneath the last -line of the document. END is enclosed between -em-dashes. -

        -Please note that in versions of -mom prior to 1.1.9, FINIS used to -turn off -footers -(if they were on) and page numbering (if page numbers were at the -bottom of the page). Damned if I can recall why I thought anyone -would want this behaviour, but it has been removed. -

        -If you're writing in a language other than English, you can -change what mom prints for END with -the control macro FINIS_STRING. +Embedding endnotes into mom documents is accomplished +the same way as embedding +footnotes. The example below is +identical to the one shown in the +introduction to footnotes, +except that .FOOTNOTE has been replaced with +.ENDNOTE.

        + +

        +	...the doctrines of Identity as urged by Schelling\c
        +	.ENDNOTE
        +	<endnote about who the hell is Schelling>
        +	.ENDNOTE OFF
        +	 were generally the points of discussion presenting the most
        +	of beauty to the imaginative Morella.
        +
        - +As with footnotes, note the obligatory use of the \c +inline escape +when your +ENDNOTE_MARKER_STYLE +is NUMBER (which marks endnotes references in +running text +with superscript numbers). When the marker style is +LINE, you must not use the +\c escape. +

        +***Version 1.3 change*** +

        +As of version 1.3, the manner of entering the line after +.ENDNOTE OFF has changed to accommodate users' +differing wishes with respect to the order of punctuation and +endnote markers. The correct way to enter the line after +.ENDNOTE OFF--but NOT +if your +ENDNOTE_MARKER_STYLE +is LINE--is to input it as if it's literally +a continuation of the line before .ENDNOTE, and +therefore begins with either a space or a punctuation mark, as in +the two following examples. +

        + +

        +	   Example 1					  Example 2
        +	   ---------                      ---------
         
        -
        -

        - - Macro: FINIS - + A line of text,\c A line of text\c + .ENDNOTE .ENDNOTE + A footnote line. A footnote line. + .ENDNOTE OFF .ENDNOTE OFF + broken up with a comma. , broken up with a comma. -

        -The use of FINIS is optional, but if you use -it, it should be the last macro you invoke in a document (before -ENDNOTES -or -TOC). -See -above -for a description of how FINIS behaves. -

        -NOTE: If you don't use FINIS, -and you don't want -footers -(if they're on) or a page number at the bottom of the last page of -a document, you have to turn them off manually, as the last two -lines of your document file, like this: -

        -

        -	.FOOTERS OFF
        -	.PAGINATE OFF
        +	(last line begins with			(last line begins with
        +	 a literal space)				 the comma and a space)
         
        -

        Changing the FINIS string

        - -

        -By default, FINIS prints the word -END between -em-dashes. -If you'd like mom to print something else -between the dashes, use the FINIS_STRING macro -(anywhere in the document prior to FINIS). -

        -For example, if your document's in French, you'd do -

        -

        -	.FINIS_STRING "FIN"
        -
        - -Double-quotes must enclose the macro's argument. -

        -NOTE: If you pass FINIS_STRING -a blank string, i.e. -

        -

        -	.FINIS_STRING ""
        -
        - -mom will still print the em-dashes if you -invoke FINIS. This, in effect, produces a -short, centred horizontal rule that terminates the document. -(In -PRINTSTYLE TYPEWRITE, -it's a short, dashed line composed of four hyphens.) - -

        Changing the FINIS colour

        -

        -Invoking FINIS_COLOR with a pre-defined (or -"initalized") color changes the colour of both the FINIS -string and the em-dashes that surround it. If you use the -inline escape, -\*[<colorname>], -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). - -

        -


        - - - -

        Endnotes

        - - -

        -Embedding endnotes into mom documents is accomplished -the same way as embedding -footnotes. The example below is -identical to the one shown in the -introduction to footnotes, -except that .FOOTNOTE has been replaced with -.ENDNOTE. -

        - -

        -	...the doctrines of Identity as urged by Schelling\c
        -	.ENDNOTE
        -	<endnote about who the hell is Schelling>
        -	.ENDNOTE OFF
        -	were generally the points of discussion presenting the most
        -	of beauty to the imaginative Morella.
        -
        - -As with footnotes, note the obligatory use of the \c -inline escape. +***End version 1.3 change***

        Endnotes differ from footnotes in two ways (other than the fact that endnotes come at the end of a document whereas footnotes appear in the body of the document):

          -
        1. Endnotes are always numbered incrementally throughout a - document. In other words, you don't get a choice of marker styles, - as you do with footnotes. +
        2. When your ENDNOTE_MARKER_STYLE is + NUMBER, endnotes are always numbered + incrementally, starting at "1".
        3. Endnotes MUST be output explicitly; mom does not output them for you. In collated documents, this allows you to choose whether you want the endnotes to appear at the end of each chapter or - section, or grouped together at the very end of the document. + article in a document, or grouped together at the very end + of the document.

        Within endnotes, you may use the document element tags @@ -2482,7 +3181,7 @@ blockquotes that appear in the document body as well.

        Endnote behaviour

        -

        +
        When you output endnotes (with ENDNOTES), mom finishes processing the last page of your document, @@ -2519,13 +3218,14 @@ the body of the document.

        A Note on Endnote Spacing

        +
        On the endnotes page(s), each new endnote is separated from the previous endnote by a full line space. This can result in a bottom margin that hangs, and is the one instance, other than the use of PARA_SPACE, where mom allows unequal bottom alignment of pages. Should you wish to correct this, by adding or subtracting small amounts -of space between endnotes that appear together on an endnote page, make +of space between endnotes that appear together on an endnotes page, make the adjustment (with ALD, RLD @@ -2539,6 +3239,7 @@ rather than at the top.

        Endnotes and columnar documents

        +
        Formerly (pre 1.1.6), there was no way to set a document in columns (see COLUMNS) @@ -2552,7 +3253,7 @@ you may now do so. See

        - Macro: ENDNOTE <toggle> + Macro: ENDNOTE <toggle>
        *See
        HYPER-IMPORTANT NOTE!!! @@ -2570,23 +3271,36 @@ that you've finished the endnote. tag. Use PP only to introduce subsequent paragraphs.

        HYPER-IMPORTANT NOTE: -The final word on the +If your +ENDNOTE_MARKER_STYLE +is NUMBER (mom's default), the +final word on the input line that comes immediately before ENDNOTE MUST terminate with a \c -inline escape. Otherwise, the endnote number for the word won't be attached to -it (i.e. mom will insert a word space between the word -and the number). See the +inline escape. See the endnote example above.

        +Additionally, the line after +.ENDNOTE OFF should be entered as if there +were no interruption in the input text, i.e. the line should begin +with a literal space or punctuation mark. See the two +examples, +above. +

        +If your ENDNOTE_MARKER_STYLE is +LINE, do NOT use the \c escape, +and enter the line after .ENDNOTE OFF +normally. +


        -Macro: ENDNOTES +Tag: ENDNOTES

        Unlike footnotes, which mom automatically outputs at the @@ -2635,7 +3349,7 @@ endnotes pages, set them up prior to

        1. General endnotes-pages style control
        2. Endnotes-pages endnote numbering style
            +
          • Endnote marker style--by numbers in the text, or by line number +
          • Endnotes-pages endnote numbering style control
          • Endnote numbering alignment
              @@ -2683,7 +3403,7 @@ endnotes pages, set them up prior to

              1. General endnotes page style control

              -

              *Endnote family/font/quad

              +

              *Endnote family/font/quad

              See Arguments to the control macros. @@ -2691,14 +3411,16 @@ See

               .ENDNOTE_FAMILY    default = prevailing document family; default is Times Roman
               .ENDNOTE_FONT      default = roman
              -.ENDNOTE_QUAD      default = justified
              +.ENDNOTE_QUAD*     default = justified
              +
              +*Note: ENDNOTE_QUAD must be set to either L or J
               

              *Endnote point size

              -Macro: ENDNOTE_PT_SIZE <base type size of endnotes> +Macro: ENDNOTE_PT_SIZE <base type size of endnotes>

              Unlike most other control macros that deal with size of document @@ -2737,7 +3459,7 @@ is 12.5 points (the same default size used in the body of the document).

              *Endnote lead

              -Macro: ENDNOTE_LEAD <base leading of endnotes> [ ADJUST ] +Macro: ENDNOTE_LEAD <base leading of endnotes> [ ADJUST ]
              *Does not require a unit of measure; points is assumed @@ -2787,7 +3509,7 @@ default, adjust endnote leading. You MUST enter

              *Singlespace endnotes (TYPEWRITE only)

              -Macro: SINGLESPACE_ENDNOTES <toggle> +Macro: SINGLESPACE_ENDNOTES <toggle>

              If your @@ -2811,7 +3533,7 @@ argument (OFF, QUIT, Q, X...).

              *Endnote paragraph indenting

              -Macro: ENDNOTE_PARA_INDENT <amount to indent first line of paragraphs in endnotes> +Macro: ENDNOTE_PARA_INDENT <amount to indent first line of paragraphs in endnotes>
              *Requires a unit of measure @@ -2839,7 +3561,7 @@ never indented. Only subsequent paragraphs are affected by

              *Endnote paragraph spacing

              -Macro: ENDNOTE_PARA_SPACE <toggle> +Macro: ENDNOTE_PARA_SPACE <toggle>

              ENDNOTE_PARA_SPACE works exactly the same way as @@ -2859,7 +3581,7 @@ refers only to paragraphs that appear within each discrete endnote.

              *Turning off column mode during endnotes output

              -Macro: ENDNOTES_NO_COLUMNS <toggle> +Macro: ENDNOTES_NO_COLUMNS <toggle>

              By default, if your document is @@ -2881,7 +3603,7 @@ be reinstated for each document, even with

              *Endnotes-pages page numbering style

              -Macro: ENDNOTES_PAGENUM_STYLE DIGIT | ROMAN | roman | ALPHA | alpha +Macro: ENDNOTES_PAGENUM_STYLE DIGIT | ROMAN | roman | ALPHA | alpha

              Use this macro to set the page numbering style of endnotes pages. @@ -2898,7 +3620,7 @@ to, say, alpha, which you would do with

              *Setting the first page number of endnotes pages

              -Macro: ENDNOTES_FIRST_PAGENUMBER <page # that appears on page 1 of endnotes> +Macro: ENDNOTES_FIRST_PAGENUMBER <page # that appears on page 1 of endnotes>

              Use this macro with caution. If all endnotes for several @@ -2920,7 +3642,7 @@ and before

              *Omitting a page number on the first page of endnotes

              -Macro: ENDNOTES_NO_FIRST_PAGENUM <toggle> +Macro: ENDNOTES_NO_FIRST_PAGENUM <toggle>

              This macro is for use only if FOOTERS are on. It @@ -2948,7 +3670,6 @@ continues, however to increment page numbers silently. To restore normal document pagination after endnotes, invoke RESTORE_PAGINATION (again, with no argument) immediately after ENDNOTES. -

              2. Endnotes-page header/footer control

              @@ -2989,7 +3710,7 @@ for the HEADER_CENTER to appear.

              *Endnotes page(s) header/footer centre string

              -Macro: ENDNOTES_HEADER_CENTER toggle +Macro: ENDNOTES_HEADER_CENTER toggle

              If your @@ -3005,9 +3726,9 @@ on endnotes pages, you wish to disable it, invoke the same macro with any argument (OFF, QUIT, Q, X...).

              -

              *Allow headers on endnotes_pages

              +

              *Allow headers on endnotes-pages

              -Macro: ENDNOTES_ALLOWS_HEADERS <none> | ALL +Macro: ENDNOTES_ALLOWS_HEADERS <none> | ALL

              By default, if HEADERS are on, mom @@ -3036,7 +3757,7 @@ as ENDNOTES_ALLOWS_FOOTERS OFF.

              *Endnotes-page first page head (title) string

              -Macro: ENDNOTE_STRING "<head to print at the top of endnotes>" +Macro: ENDNOTE_STRING "<head to print at the top of endnotes>"

              By default, mom prints the word "ENDNOTES" @@ -3069,7 +3790,7 @@ See

              *Endnotes-page head (title) underscoring

              -Macro: ENDNOTE_STRING_UNDERSCORE toggle | 2 +Macro: ENDNOTE_STRING_UNDERSCORE toggle | 2

              Invoked by itself, ENDNOTE_STRING_UNDERSCORE will @@ -3088,7 +3809,7 @@ NONE, etc.) into your document prior to outputting endnotes with

              *Endnotes-page head (title) automatic capitalization

              -Macro: ENDNOTE_STRING_CAPS toggle +Macro: ENDNOTE_STRING_CAPS toggle

              Invoked by itself, ENDNOTE_STRING_CAPS will @@ -3112,7 +3833,7 @@ head string.

              4. Endnote document-identification title

              *Endnote document-identification title string

              -Macro: ENDNOTE_TITLE "<title to identify a document in endnotes>" +Macro: ENDNOTE_TITLE "<title to identify a document in endnotes>"

              By default, mom identifies the document(s) to which @@ -3150,7 +3871,7 @@ See

              *Endnote document-identification title underscoring

              -Macro: ENDNOTE_TITLE_UNDERSCORE toggle +Macro: ENDNOTE_TITLE_UNDERSCORE toggle

              Invoked by itself, ENDNOTE_TITLE_UNDERSCORE will @@ -3167,6 +3888,106 @@ NONE, etc.) into your document prior to outputting endnotes with

              5. Endnotes-pages endnote numbering style

              +

              *Endnote marker style

              +

              +The macro to control how endnotes are referenced is +ENDNOTE_MARKER_STYLE. +

              +By default, mom places superscript numbers in +running text +to identify endnotes. However, if you have +line-numbering +turned on, you may instruct mom not to put +superscript numbers in the running text, but rather to reference +endnotes by line number. The command to do this is +

              +

              +	.ENDNOTE_MARKER_STYLE LINE
              +
              + +With ENDNOTE_MARKER_STYLE LINE, mom +will identify endnotes either by single line numbers, or line +ranges. If what you want is a single line number, you need only +invoke .ENDNOTE, without terminating the text +line before it with \c, at the appropriate +place in running text. (Should you wish to revert to +mom's default behaviour of placing a superscript +number in the text to identify an endnote, you can invoke +ENDNOTE_MARKER_STYLE with the argument, +NUMBER. It is not advisable to switch marker +styles within a single document, for aesthetic reasons, but there +is nothing to prevent you from doing so.) +

              +If you want a range of line numbers (e.g. [5-11] ), +insert, directly into the first line of the range you want, the +inline escape, +\*[EN-MARK]. For the terminating line number of +the range, you need only invoke .ENDNOTE, (again, +without attaching \c to the text line before it). +Mom is smart enough to figure out that where +ENDNOTE was invoked represents the terminating +line number. + +

              +Given the impossibility of knowing, in advance, the "string length" +of all the line numbers or ranges of line numbers that will be used +in endnotes (the string length of 12 is two; the string length +of 12-15 is 5), mom cannot "hang" line numbers +and guarantee that they, and the endnote text, will align in a +visually pleasing manner. Consequently, mom sets +the entirety of line-numbered endnotes completely flush left, +including the line numbers themselves. The line +numbers (by default, enclosed in square brackets) are separated from +the beginning of each endnote by a gap, so that a line-numbered +endnote looks approximately like this: +

              +

              +	[1-2]   Notwithstanding, Frye later asserts that Christianity
              +	is "a ghost  with the chains of a foul historical record of
              +	cruelty clanking behind it."
              +
              + +The default gap for PRINTSTYLE TYPESET and +PRINSTYLE TYPEWRITE is 1.5 +ems. +You can change the size of the gap with the macro, +ENDNOTE_LINENUMBER_GAP, which takes, as its single +argument, the size of the gap. The argument requires a +unit of measure, +so, for example, to change the gap to 2 +picas, +you'd do +

              +

              +	.ENDNOTE_LINENUMBER_GAP 2P
              +
              + + +By default, mom puts endnote line numbers inside +square brackets. The style of the brackets may be changed with +the macro, ENDNOTE_LINENUMBER_BRACKETS, which +takes one of three possible arguments: PARENS +("round" brackets), SQUARE (the default) or +BRACES (curly braces). If you prefer a +shortform, the arguments, (, [ or +{ may be used instead. + +

              +If you don't want the numbers enclosed in brackets, you may tell +mom to use a "separator" instead. A common +separator would be the colon, but it can be anything you like. The +macro to do this is ENDNOTE_LINENUMBER_SEPARATOR, +which takes, as its single argument, the separator you want. +(If the argument contains spaces, don't forget to enclose the +argument in double-quotes.) The separator can be composed of +any legal groff character, or any combination of characters. +For example, to get a colon separator after the line number in +line-numbered endnotes, you'd do +

              +

              +	.ENDNOTE_LINENUMBER_SEPARATOR :
              +
              +

              *Endnote numbering style control

              See @@ -3213,7 +4034,7 @@ The macros to alter this behaviour are

              - Macro: ENDNOTE_NUMBERS_ALIGN_RIGHT <number of placeholders> + Macro: ENDNOTE_NUMBERS_ALIGN_RIGHT <number of placeholders>

              ENDNOTE_NUMBERS_ALIGN_RIGHT takes one (non-optional) @@ -3236,6 +4057,7 @@ endnotes, you'd want to do to ensure that the numbers hang and are properly right-aligned.

              +


              @@ -3265,6 +4087,321 @@ comes out like this: +

              Margin notes

              + + +

              +Margin notes are short annotations that appear in either the left +or right margin of a document. Sometimes they comment on the text. +Sometimes they assist in following the "flow" of a document by +summarizing the subject of a portion of text. Sometimes they're +comments to yourself in a draft copy. +

              +The margin notes macros and routines in om.tmac +(mom) are "mommified" versions of the margin notes +macros and routines written by Werner Lemberg and patched by Gaius +Mulley. +

              + +Margin notes behaviour +

              +First things first: before you enter your first margin note, you +must "initialize" margin notes with +MN_INIT. +MN_INIT sets up the style parameters for margin +notes, including things like +font, +family +and +leading. +

              +After initializing margin notes, you create margin notes with the +MN +macro. Based on the argument you pass MN, your +margin note will go in either the left or the right margin. +

              +Margin notes are tricky from a typographic standpoint with respect +to vertical placement. Since the leading of margin notes may +differ from that of +running text, +it's impossible for mom to guess whether to align +the first lines of margin notes with a document +baseline, +whether to align the last lines of margin notes with a document +baseline, or whether to center them, vertically, so that neither +first nor last line aligns with anything! +

              +Given this difficulty, mom always aligns the first +line of any margin note with a document baseline. If you want a +different behaviour, you must adjust the position(s) of margin +notes yourself, on a note by note basis. (See +Adjusting the vertical position of margin notes.) +

              +Generally speaking, mom tries to place margin +notes at the point where you invoke the tag, +MN. +However, in the event that a margin note runs deep, she may not +be able to place a subsequent margin note exactly where you want. +In such an instance, mom will "shift" the margin +note down on the page, placing it one (margin note) +linespace beneath the previous margin note (plus whatever vertical +space is required to get the first line to line up with a baseline +of running text). A warning will be issued, letting you know this +has happened, and where. +

              +Sometimes, if a margin note has to be shifted down, there simply +isn't enough room to start the margin note on the page on which +MN is invoked. In that case, mom +ignores the margin note entirely and issues a warning, letting you +know what she's done, and where. +

              +In the event that a margin note, sucessfully begun on a page, +runs past your bottom margin (or the last line before footnotes +begin), the margin note will "flow" onto the next page. If it is a +"left" margin note, it will continue in the left margin. If it is a +"right" margin note, it will continue in the right margin. +

              +If your document is being set in two columns, mom +will sensibly and automatically set all margin notes pertaining +to the left column in the left margin, and all margin notes +pertaining to the right column in the right margin, regardless of +the "direction" argument you give the MN tag. If +you try to use MN in documents of more than two +columns, mom will ignore all margin notes, and +issue warning for each. +

              +

              Adjusting the vertical position of margin notes

              +

              +When the +leading +of margin notes differs from the leading used throughout a document, +you may want to adjust the vertical position of individual margin +notes. This is most often going to be the case with margin notes +that end near the bottom of the page, where you want the last line of +the margin note to line up with the last line of text on the page. +

              +Adjustments to the vertical position of margin notes must be done +inside the margin note (i.e. after MN), at the +top, before entering text. The commands to use are +\!.ALD +(to lower the margin note), and +\!.RLD +(to raise it). The \! must precede the +macros, or they won't have any effect. + +

              +


              + + + +

              + + Macro: MN_INIT [ ragged | symmetric ] < left-width right-width gutter family+font point-size lead colour hyphenation-flags > + +

              +Before you enter your first margin note, you must initialize +all the parameters associated with margin notes with +MN_INIT. If you forget to do so, +mom will issue a warning and abort. +

              +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 "" (i.e. two +double-quotes with no space between them). Defaults for each +argument are given in the explanation below. +

              +[ ragged | symmetric ] +
              +If the first argument is "ragged", both left and right margin notes +will be flush left. If the first argument is "symmetric", left +margin notes will be set flush right, and right margin +notes will be set flush left. The effect is something +like this: +

              +

              +	     A left    This is a meaningless batch        A right
              +	margin note    of text whose sole purpose is      margin note
              +	  with just    to demonstrate how the sym-        with just
              +	a few words    metric argument to MN sets left    a few words
              +	     in it.    and right margin notes.            in it.
              +
              + + +If the argument is omitted, +or given as "", 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.) +

              +left-width +
              +The width of left margin notes. A +unit of measure +must be appended directly onto the argument. The default is to set +left margin notes right out to the edge of the page, which is +almost certainly not what you want, so you should give a value for +this argument if using left margin notes. +

              +right-width +
              +The width of right margin notes. A +unit of measure +must be appended directly onto the argument. The default is to set +right margin notes right out to the edge of the page, which is +almost certainly not what you want, so you should give a value for +this argument if using right margin notes. +

              +gutter +
              +The +gutter +between margin notes and +running text. +A +unit of measure +must be appended directly onto the argument. The gutter applies to +both left and right margin notes. The default is 1 +em. +

              +font +
              +The family+font for margin notes. Yes, that's right: the family +PLUS 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 family+font combo used +for a document's paragraph text. +

              +lead +
              +The +leading +of margin notes. lead uses +points +as its unit of measure, so don'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's base leading). +For convenience and clarity, you may also give the word, +DOC, to this argument, which indicates that the +leading should be the same as the document's base leading. +

              +colour +
              +The colour of margin notes. The colour must be pre-initialized +with +NEWCOLOR +or +XCOLOR. +The default is black. +

              +hyphenation-flags +
              +A number telling groff how you want margin notes +hyphenated. +

              +

              +	1 = hyphenate without restrictions
              +	2 = do not hyphenate the last word on the page
              +	4 = do not hyphenate the last two characters of a word
              +	8 = do not hyphenate the first two characters of a word
              +
              + +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). + +

              +


              + + + +

              + + Macro: MN LEFT|RIGHT | <anything> + +

              +Once you've initialized margin notes with +MN_INIT, +you can enter margin notes any time you like with +MN. An argument of LEFT will set +a left margin note. An argument of RIGHT will set +a right margin note. +

              +Any argument, such as OFF (or +QUIT, END, X, +etc) exits the current margin note. + +

              +


              + + + +

              Inserting a blank page into the document

              +

              + + Macro: BLANKPAGE <# of blank pages to insert> + + +

              +This one does exactly what you'd expect -- inserts a blank page into +the document. Mom silently increments the page +number of every blank page and keeps track of +recto/verso +stuff, but otherwise, does nothing. It's up to you, the user, to +figure out what to do with this feature. However, it's worth +noting that without it, inserting completely blank pages, to use +a vernacular Québécois phrase, "c'est pas évident" +(somewhere between "isn't easy", "isn't +obvious" and "isn't fun"). +

              +The argument to BLANK_PAGE is the number of blank +pages to insert. The argument is not optional, hence even if you +only want one blank page, you have to tell mom: +

              +

              +	.BLANKPAGE 1
              +
              + +

              Terminate document processing

              + + +

              +The use of FINIS is optional. If you invoke it +(at the end of a document before +TOC +or +ENDNOTES), +mom +deposits the word END, centred after a blank line, beneath the last +line of the document. END is enclosed between +em-dashes. +

              +Please note that in versions of +mom prior to 1.1.9, FINIS used to +turn off +footers +(if they were on) and page numbering (if page numbers were at the +bottom of the page). Damned if I can recall why I thought anyone +would want this behaviour, but it has been removed. +

              +If you're writing in a language other than English, you can +change what mom prints for END with +the control macro FINIS_STRING. +

              +


              + + +

              Table of contents


        -

        3. Changing the toc header (title) string and style

        @@ -3734,7 +4869,7 @@ The same result can be accomplished by outputting a

        - Macro: TOC_TITLE_ENTRY <"alternate wording for a title entry in the toc"> + Macro: TOC_TITLE_ENTRY <"alternate wording for a title entry in the toc">

        In @@ -3779,7 +4914,7 @@ Bush".

        - Macro: TOC_APPENDS_AUTHOR <none> | <"name(s) of authors"> + Macro: TOC_APPENDS_AUTHOR <none> | <"name(s) of authors">

        In certain kinds of collated documents, different authors are @@ -3812,7 +4947,7 @@ would be a good way to identify them in the toc.

        - Macro: TOC_PADDING <# of placeholders to allow for page number listings> + Macro: TOC_PADDING <# of placeholders to allow for page number listings>

        By default, mom allows room for 3 digits in the @@ -3823,37 +4958,81 @@ placeholders, say 2, do .TOC_PADDING 2 -


        - - + -

        Inserting a blank page into the document

        +

        - - Macro: BLANKPAGE <# of blank pages to insert> + + Macro: FINIS

        -This one does exactly what you'd expect -- inserts a blank page into -the document. Mom silently increments the page -number of every blank page and keeps track of -recto/verso -stuff, but otherwise, does nothing. It's up to you, the user, to -figure out what to do with this feature. However, it's worth -noting that without it, inserting completely blank pages, to use -a vernacular Québécois phrase, "c'est pas évident" -(somewhere between "isn't easy", "isn't -obvious" and "isn't fun"). +The use of FINIS is optional, but if you use +it, it should be the last macro you invoke in a document (before +ENDNOTES +or +TOC). +See +above +for a description of how FINIS behaves.

        -The argument to BLANK_PAGE is the number of blank -pages to insert. The argument is not optional, hence even if you -only want one blank page, you have to tell mom: +NOTE: If you don't use FINIS, +and you don't want +footers +(if they're on) or a page number at the bottom of the last page of +a document, you have to turn them off manually, as the last two +lines of your document file, like this:

        -	.BLANKPAGE 1
        +	.FOOTERS OFF
        +	.PAGINATE OFF
         
        -
        +

        Changing the FINIS string

        + +

        +By default, FINIS prints the word +END between +em-dashes. +If you'd like mom to print something else +between the dashes, use the FINIS_STRING macro +(anywhere in the document prior to FINIS). +

        +For example, if your document's in French, you'd do +

        +

        +	.FINIS_STRING "FIN"
        +
        + +Double-quotes must enclose the macro's argument. +

        +NOTE: If you pass FINIS_STRING +a blank string, i.e. +

        +

        +	.FINIS_STRING ""
        +
        + +mom will still print the em-dashes if you +invoke FINIS. This, in effect, produces a +short, centred horizontal rule that terminates the document. +(In +PRINTSTYLE TYPEWRITE, +it's a short, dashed line composed of four hyphens.) + +

        Changing the FINIS colour

        +

        +Invoking FINIS_COLOR with a pre-defined (or +"initalized") color changes the colour of both the FINIS +string and the em-dashes that surround it. If you use the +inline escape, +\*[<colorname>], +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). + +

        +


        Next   Prev   Top   diff --git a/contrib/mom/momdoc/docprocessing.html b/contrib/mom/momdoc/docprocessing.html index 489d894a..e43f3747 100644 --- a/contrib/mom/momdoc/docprocessing.html +++ b/contrib/mom/momdoc/docprocessing.html @@ -8,7 +8,7 @@ -Next   +Next   Prev   Back to Table of Contents

        @@ -199,7 +199,7 @@ -

      10. CREATING A COVER PAGE +
      11. CREATING A COVER PAGE
      12. WRITING LETTERS
          @@ -674,7 +674,7 @@ document processing macros.

          -Macro: TITLE "<title>" +Macro: TITLE "<title>"
          *Argument must be enclosed in double-quotes @@ -703,7 +703,7 @@ title of the opus, not "CHAPTER whatever".


          -Macro: DOCTITLE "<overall document title>" +Macro: DOCTITLE "<overall document title>"
          *Argument must be enclosed in double-quotes @@ -750,7 +750,7 @@ everything.


          -Macro: SUBTITLE "<subtitle>" +Macro: SUBTITLE "<subtitle>"
          *Argument must be enclosed in double-quotes @@ -766,7 +766,7 @@ and the title is most likely in caps, I recommend caps/lower case.


          -Macro: AUTHOR "<author string>" [ "<author2 string>" "<author3 string>" ... ] +Macro: AUTHOR "<author string>" [ "<author2 string>" "<author3 string>" ... ]
          *Multiple arguments must all be enclosed in double-quotes @@ -798,7 +798,7 @@ case.


          -Macro: CHAPTER <chapter number> +Macro: CHAPTER <chapter number>

          The chapter number can be in any form you like -- a digit, a roman @@ -839,7 +839,7 @@ page-headers.


          -Macro: CHAPTER_TITLE "<chapter title>" +Macro: CHAPTER_TITLE "<chapter title>"
          *Argument must be enclosed in double-quotes @@ -885,7 +885,7 @@ than


          -Macro: DRAFT <draft #> +Macro: DRAFT <draft #>

          DRAFT only gets used with @@ -952,7 +952,7 @@ result in mom using her default, which is to print


          -Macro: REVISION <revision #> +Macro: REVISION <revision #>

          REVISION only gets used with @@ -1029,7 +1029,7 @@ either or both.


          -Macro: COPYRIGHT "<copyright info>" +Macro: COPYRIGHT "<copyright info>"
          *Argument must be enclosed in double-quotes @@ -1050,7 +1050,7 @@ you.


          -Macro: MISC "<argument 1>" ["<argument 2>" "<argument 3>" ...] +Macro: MISC "<argument 1>" ["<argument 2>" "<argument 3>" ...]
          *Multliple arguments must all be enclosed in double-quotes @@ -1081,9 +1081,9 @@ and the information would appear on the essay's cover page.


          -Macro: COVERTITLE "<user defined cover page title>" +Macro: COVERTITLE "<user defined cover page title>"
          -Macro: DOC_COVERTITLE "<user defined document cover page title>" +
          Macro: DOC_COVERTITLE "<user defined document cover page title>"
          *Argument must be enclosed in double-quotes @@ -1137,7 +1137,7 @@ draft and revision information in the headers) or a final copy.


          -Macro: DOCTYPE DEFAULT | CHAPTER | NAMED "<name>" | LETTER +Macro: DOCTYPE DEFAULT | CHAPTER | NAMED "<name>" | LETTER

          The arguments DEFAULT, CHAPTER and NAMED tell mom what to put @@ -1228,7 +1228,7 @@ for instructions on using mom to format letters.


          -Macro: PRINTSTYLE TYPESET | TYPEWRITE [ SINGLESPACE ] +Macro: PRINTSTYLE TYPESET | TYPEWRITE [ SINGLESPACE ]
          *Required for document processing.
          @@ -1412,7 +1412,7 @@ is DRAFT).


          -Macro: COPYSTYLE DRAFT | FINAL +Macro: COPYSTYLE DRAFT | FINAL

          Mom's default COPYSTYLE is @@ -1672,7 +1672,7 @@ elements.


          Adjusting document leading to fill pages


          -Macro: DOC_LEAD_ADJUST toggle +
          Macro: DOC_LEAD_ADJUST toggle
          *Must come after LS or AUTOLEAD and before START @@ -1747,7 +1747,7 @@ for an explanation of how to disable this default behaviour.

          Managing the docheader


          -Macro: DOCHEADER <toggle> [ distance to advance from top of page ] +
          Macro: DOCHEADER <toggle> [ distance to advance from top of page ]
          *Must come before START; distance requires a unit of measure @@ -1962,11 +1962,11 @@ The following macros let you change the of each docheader element separately:

            -
          • TITLE_FAMILY <family> -
          • CHAPTER_TITLE_FAMILY <family> -
          • SUBTITLE_FAMILY <family> -
          • AUTHOR_FAMILY <family> -
          • DOCTYPE_FAMILY <family> (if +
          • TITLE_FAMILY <family> +
          • CHAPTER_TITLE_FAMILY <family> +
          • SUBTITLE_FAMILY <family> +
          • AUTHOR_FAMILY <family> +
          • DOCTYPE_FAMILY <family> (if DOCTYPE is NAMED)

          @@ -1982,11 +1982,11 @@ The following macros let you change the of each docheader element separately:

            -
          • TITLE_FONT R | B | I | BI -
          • CHAPTER_TITLE_FONT R | B | I | BI -
          • SUBTITLE_FONT R | B | I | BI -
          • AUTHOR_FONT R | B | I | BI -
          • DOCTYPE_FONT R | B | I | BI (if +
          • TITLE_FONT R | B | I | BI +
          • CHAPTER_TITLE_FONT R | B | I | BI +
          • SUBTITLE_FONT R | B | I | BI +
          • AUTHOR_FONT R | B | I | BI +
          • DOCTYPE_FONT R | B | I | BI (if DOCTYPE is NAMED)

          @@ -2006,8 +2006,8 @@ or XCOLOR.

            -
          • TITLE_COLOR <colorname> -
          • CHAPTER_TITLE_COLOR <colorname> +
          • TITLE_COLOR <colorname> +
          • CHAPTER_TITLE_COLOR <colorname>
            • Note: CHAPTER_TITLE_COLOR is needed only if you enter both a CHAPTER @@ -2016,11 +2016,11 @@ or TITLE_COLOR takes care of colorizing the chapter header.
            -
          • SUBTITLE_COLOR <colorname> -
          • ATTRIBUTE_COLOR <colorname> +
          • SUBTITLE_COLOR <colorname> +
          • ATTRIBUTE_COLOR <colorname> (the "by" string that precedes the author[s] name[s]) -
          • AUTHOR_COLOR <colorname> -
          • DOCTYPE_COLOR <colorname> (if +
          • AUTHOR_COLOR <colorname> +
          • DOCTYPE_COLOR <colorname> (if DOCTYPE is NAMED)

          @@ -2043,7 +2043,7 @@ colourized, or parts thereof, use the header/footer control macros.) If you want to colourize the entire docheader, use the macro

            -
          • DOCHEADER_COLOR <color name>. +
          • DOCHEADER_COLOR <color name>.

          7. Adjust the size of docheader elements

          @@ -2060,19 +2060,19 @@ so there's no need to append a unit to the argument. Fractional point sizes are allowed.

            -
          • TITLE_SIZE <+/-points> +
          • TITLE_SIZE <+/-points>
            default = +3.5 (+4 if docheader title is "Chapter #") -
          • CHAPTER_TITLE_SIZE <+/-points> +
          • CHAPTER_TITLE_SIZE <+/-points>
            default = +4 -
          • SUBTITLE_SIZE <+/-points> +
          • SUBTITLE_SIZE <+/-points>
            default = +0 -
          • AUTHOR_SIZE <+/-points> +
          • AUTHOR_SIZE <+/-points>
            default = +0 -
          • DOCTYPE_SIZE <+/-points> (if +
          • DOCTYPE_SIZE <+/-points> (if DOCTYPE is NAMED)
            default = +3 @@ -2161,7 +2161,7 @@ as well).

            COLUMNS


            -Macro: COLUMNS <number of columns> <width of gutters> +
            Macro: COLUMNS <number of columns> <width of gutters>
            *Should be the last macro before START
            @@ -2311,7 +2311,7 @@ global changes to the basic type parameters of a document.

            - Macro: DOC_LEFT_MARGIN <left margin> + Macro: DOC_LEFT_MARGIN <left margin>
            *Requires a unit of measure @@ -2328,7 +2328,7 @@ global changes to the basic type parameters of a document.


            - Macro: DOC_RIGHT_MARGIN <right margin> + Macro: DOC_RIGHT_MARGIN <right margin>
            *Requires a unit of measure @@ -2336,7 +2336,17 @@ global changes to the basic type parameters of a document.

            @@ -2345,22 +2355,32 @@ global changes to the basic type parameters of a document.

            - Macro: DOC_LINE_LENGTH <length> + Macro: DOC_LINE_LENGTH <length>
            *Requires a unit of measure



            - Macro: DOC_FAMILY <family> + Macro: DOC_FAMILY <family>

              @@ -2378,7 +2398,7 @@ global changes to the basic type parameters of a document.

              - Macro: DOC_PT_SIZE <point size> + Macro: DOC_PT_SIZE <point size>
              *Does not require a unit of measure; points is assumed @@ -2399,7 +2419,7 @@ global changes to the basic type parameters of a document.


              - Macro: DOC_LEAD <points> [ ADJUST ] + Macro: DOC_LEAD <points> [ ADJUST ]
              *Does not require a unit of measure; points is assumed @@ -2444,7 +2464,7 @@ for an explanation of how to disable this default behaviour.


              - Macro: DOC_QUAD L | R | C | J + Macro: DOC_QUAD L | R | C | J

                @@ -2456,7 +2476,7 @@ for an explanation of how to disable this default behaviour.

                -Next   +Next   Prev   Top   Back to Table of Contents diff --git a/contrib/mom/momdoc/goodies.html b/contrib/mom/momdoc/goodies.html index af6d2002..83a7ff3b 100644 --- a/contrib/mom/momdoc/goodies.html +++ b/contrib/mom/momdoc/goodies.html @@ -84,7 +84,7 @@ nearly indispensable) routines to simplify typesetting.

                Rename macros


                -Macro: ALIAS <new name> <old name> +
                Macro: ALIAS <new name> <old name>

                The ALIAS macro may well be your best friend. With it, @@ -161,7 +161,7 @@ impunity.


                Hide input lines from output


                -Macro: SILENT toggle +
                Macro: SILENT toggle
                Alias: COMMENT @@ -214,7 +214,7 @@ portion of your text disappearing into a black hole.

                Suspend/re-invoke traps


                -Macro: TRAP toggle +
                Macro: TRAP toggle

                Traps are vertical positions on the output page at which you or @@ -242,11 +242,11 @@ turns it off (i.e. suspends the trap), and no argument turns it


                Convert typewriter doublequotes to proper doublequotes


                -Macro: SMARTQUOTES [<off>] [ ,, | >> | << ] +
                Macro: SMARTQUOTES [<off>] [ ,, | >> | << ]
                or
                -Macro: SMARTQUOTES DA | DE | ES | FR | IT | NL | NO | PT | SV +
                Macro: SMARTQUOTES DA | DE | ES | FR | IT | NL | NO | PT | SV

                If you invoke SMARTQUOTES without an argument, @@ -371,7 +371,7 @@ of ' and ".


                Convert to upper case


                -Macro: CAPS toggle +
                Macro: CAPS toggle

                CAPS converts all lower case letters to upper @@ -398,7 +398,7 @@ produces, on output


                User-defined strings


                -Macro: STRING <name> <what you want in the string> +
                Macro: STRING <name> <what you want in the string>

                You may find sometimes that you have to type out portions of text @@ -443,7 +443,7 @@ You can use either, or mix 'n' match with impunity.


                Single underscore


                -Macro: UNDERSCORE [ <distance below baseline> ] "<string>" +
                Macro: UNDERSCORE [ <distance below baseline> ] "<string>"
                *Optional argument requires a unit of measure @@ -510,7 +510,7 @@ to preview files anyway. See the section on

                Double underscore


                -Macro: UNDERSCORE2 [ <distance below baseline> [ <distance between rules> ] ] "<string>" +
                Macro: UNDERSCORE2 [ <distance below baseline> [ <distance between rules> ] ] "<string>"
                *Optional arguments require a unit of measure @@ -554,7 +554,7 @@ for UNDERSCORE.

                Underline text -- Courier font only!


                -Macro: UNDERLINE toggle +
                Macro: UNDERLINE toggle

                If your font is Courier, or you're using the document processing macro @@ -632,7 +632,7 @@ produces the same result as


                Insert space into lines


                -Macro: PAD "<string with pad markers inserted>" [NOBREAK] +
                Macro: PAD "<string with pad markers inserted>" [NOBREAK]

                With PAD, you can insert unspecified amounts of @@ -756,7 +756,7 @@ string passed to PAD.


                Change/set the marker used with PAD


                -Macro: PAD_MARKER <character to use as the pad marker> +
                Macro: PAD_MARKER <character to use as the pad marker>

                If you need to change mom's default pad marker @@ -831,7 +831,7 @@ with leaders. The result looks like this:


                Change/set the leader character


                -Macro: LEADER_CHARACTER <character> +
                Macro: LEADER_CHARACTER <character>

                LEADER_CHARACTER takes one argument: a single @@ -853,7 +853,7 @@ default (a period) to the underscore character, enter


                Drop caps


                -Macro: DROPCAP <dropcap letter> <number of lines to drop> [ COND <percentage> | EXT <percentage> ] +
                Macro: DROPCAP <dropcap letter> <number of lines to drop> [ COND <percentage> | EXT <percentage> ]

                The first two arguments to DROPCAP are the letter you diff --git a/contrib/mom/momdoc/headfootpage.html b/contrib/mom/momdoc/headfootpage.html index 5f730744..39a16bd4 100644 --- a/contrib/mom/momdoc/headfootpage.html +++ b/contrib/mom/momdoc/headfootpage.html @@ -293,7 +293,7 @@ there's no need to turn headers off first.


                -Macro: HEADERS toggle +Macro: HEADERS toggle

                Page headers @@ -332,7 +332,7 @@ picas.)


                -Macro: FOOTERS toggle +Macro: FOOTERS toggle

                Page footers @@ -363,7 +363,7 @@ If you don't want this behaviour, you can change it with


                -Macro: FOOTER_ON_FIRST_PAGE toggle +Macro: FOOTER_ON_FIRST_PAGE toggle

                If you invoke @@ -445,9 +445,9 @@ mechanism whereby it's possible to "pad" the string as well.


                -Macro: HEADER_RECTO LEFT | CENTER | RIGHT "<header recto string>" +Macro: HEADER_RECTO LEFT | CENTER | RIGHT "<header recto string>"
                -Macro: HEADER_VERSO LEFT | CENTER | RIGHT "<header verso string>" +
                Macro: HEADER_VERSO LEFT | CENTER | RIGHT "<header verso string>"

                @@ -620,15 +620,15 @@ can be designed to your own specifications.

                Header/footer strings

                - Macro: HEADER_LEFT "<text of header left>" | # + Macro: HEADER_LEFT "<text of header left>" | #
                - Macro: HEADER_CENTER "<text of header centre>" | # +
                Macro: HEADER_CENTER "<text of header centre>" | #
                - Macro: HEADER_RIGHT "<text of header right>" | # +
                Macro: HEADER_RIGHT "<text of header right>" | #

                @@ -653,7 +653,7 @@ with FOOTER_ to change the strings in footers.

                *Padding the header/footer centre string

                -Macro: HEADER_CENTER_PAD LEFT | RIGHT <amount of space by which to pad centre string left or right> +Macro: HEADER_CENTER_PAD LEFT | RIGHT <amount of space by which to pad centre string left or right>
                *Requires a unit of measure

                @@ -862,7 +862,7 @@ Please note that HEADER_FAMILY and


                - Macro: HEADER_FAMILY <family> + Macro: HEADER_FAMILY <family>

                @@ -881,7 +881,7 @@ with FOOTER_ to change the footer family.


                - Macro: HEADER_SIZE <+|-number of points> + Macro: HEADER_SIZE <+|-number of points>
                *Argument is relative to the point size of type in paragraphs
                @@ -950,7 +950,7 @@ default behaviour for the various elements of footer style.


                - Macro: HEADER_COLOR <colorname> + Macro: HEADER_COLOR <colorname>

                @@ -992,7 +992,7 @@ or RIGHT as appropriate.


                - Macro: HEADER_<POSITION>_FAMILY <family> + Macro: HEADER_<POSITION>_FAMILY <family>

                Use HEADER_<POSITION>_FAMILY to change the @@ -1009,7 +1009,7 @@ with FOOTER_ to change a footer part's family.


                - Macro: HEADER_<POSITION>_FONT <font> + Macro: HEADER_<POSITION>_FONT <font>

                Use HEADER_<POSITION>_FONT to change the @@ -1026,7 +1026,7 @@ with FOOTER_ to change a footer part's font.


                - Macro: HEADER_<POSITION>_SIZE <+|-number of points> + Macro: HEADER_<POSITION>_SIZE <+|-number of points>

                Use HEADER_<POSITION>_SIZE to change the size of any @@ -1043,7 +1043,7 @@ with FOOTER_ to change a footer part's size.


                - Macro: HEADER_<POSITION>_CAPS toggle + Macro: HEADER_<POSITION>_CAPS toggle

                HEADER_<POSITION>_CAPS is a @@ -1068,7 +1068,7 @@ capitalization style.


                - Macro: HEADER_<POSITION>_COLOR <colorname> + Macro: HEADER_<POSITION>_COLOR <colorname>

                HEADER_<POSITION>_COLOR allows you to set a @@ -1127,7 +1127,7 @@ headers, footers, and top/bottom page margins.


                -Macro: HEADER_MARGIN <distance to baseline of header> +Macro: HEADER_MARGIN <distance to baseline of header>
                *Requires a unit of measure @@ -1227,7 +1227,7 @@ baseline placement.


                -Macro: HEADER_GAP <distance from header to start of running text> +Macro: HEADER_GAP <distance from header to start of running text>
                *Requires a unit of measure @@ -1319,7 +1319,7 @@ footer), you can alter its placement.


                -Macro: HEADER_RULE toggle +Macro: HEADER_RULE toggle

                By default, mom prints a header separator rule @@ -1345,7 +1345,7 @@ the footer separator rule. (Most likely, if you're using


                -Macro: HEADER_RULE_GAP distance of rule beneath header +Macro: HEADER_RULE_GAP distance of rule beneath header
                *Requires a unit of measure @@ -1396,7 +1396,7 @@ should always be negative (smaller) than the default.


                -Macro: HEADER_RULE_COLOR <colorname> +Macro: HEADER_RULE_COLOR <colorname>

                If you wish to change the colour of the header rule, invoke @@ -1450,7 +1450,7 @@ with control macros.


                -Macro: PAGINATE toggle +Macro: PAGINATE toggle
                Alias: PAGINATION @@ -1473,7 +1473,7 @@ without any argument.


                -Macro: PAGENUMBER <number> +Macro: PAGENUMBER <number>

                As is to be expected, pagination of documents begins at page 1. @@ -1493,7 +1493,7 @@ incremented by 1 from that number.


                -Macro: PAGENUM_STYLE DIGIT | ROMAN | roman | ALPHA | alpha +Macro: PAGENUM_STYLE DIGIT | ROMAN | roman | ALPHA | alpha

                PAGENUM_STYLE lets you tell @@ -1513,7 +1513,7 @@ Macro: PAGENUM_STYLE DIGIT | ROMAN | roman | ALPHA | alpha


                -Macro: PAGENUM_ON_FIRST_PAGE toggle +Macro: PAGENUM_ON_FIRST_PAGE toggle

                This macro applies only if you've enabled @@ -1592,7 +1592,7 @@ See

                2. Page number position

                -Macro: PAGENUM_POS TOP | BOTTOM  LEFT | CENTER | RIGHT +Macro: PAGENUM_POS TOP | BOTTOM  LEFT | CENTER | RIGHT

                Use PAGENUM_POS to change the default position of diff --git a/contrib/mom/momdoc/inlines.html b/contrib/mom/momdoc/inlines.html index 7f4ded52..9409aab9 100644 --- a/contrib/mom/momdoc/inlines.html +++ b/contrib/mom/momdoc/inlines.html @@ -409,7 +409,7 @@ As of 1.2-f, you can, if you prefer, accomplish the same thing by using the inline escape, \*[B]. Simply attach the escape to the end of any line. Using the example given in the document entry for EL, you'd use -\*[B} like this: +\*[B] like this:

                @@ -476,7 +476,7 @@ example:
                 
                 The above draws a rule the full measure of the 6-pica line length.
                 

                -\*[$RULE] should appear on a line by itself. In +\*[RULE] should appear on a line by itself. In fill modes, (i.e. QUAD @@ -494,7 +494,7 @@ or CENTER), the .BR is not required.

                -Please note that \*[$RULE] draws the rule to the +Please note that \*[RULE] draws the rule to the full measure, hence it cannot be used to fill the remainder of a partial line with a rule in this way:

                diff --git a/contrib/mom/momdoc/intro.html b/contrib/mom/momdoc/intro.html index e37f5602..3376cbc1 100644 --- a/contrib/mom/momdoc/intro.html +++ b/contrib/mom/momdoc/intro.html @@ -298,9 +298,9 @@ documentation. The concise descriptions of macros in this documentation typically look like this:

                -Macro: NAME arguments +Macro: NAME arguments
                -arguments lists the macro's arguments using conventions that +arguments lists the macro's arguments using conventions that should be familiar to anyone who has ever read a manpage. Briefly:

                  @@ -329,14 +329,14 @@ it could even be I_LOVE_MOM. Since these macros toggle things on and off, the argument list simply reads
                  -toggle +toggle


                  Example 1: an argument requiring double-quotes

                  -Macro: TITLE "<title of document>" +Macro: TITLE "<title of document>"

                  The required argument to TITLE is the title of your @@ -349,7 +349,7 @@ include them in the argument, like this:

                  Example 2: a macro with required and optional arguments

                  -Macro: TAB_SET <tab #> <indent> <length> [ L | R | C | J [ QUAD ] ] +Macro: TAB_SET <tab #> <indent> <length> [ L | R | C | J [ QUAD ] ]

                  The first required argument is a number that identifies the tab (say, @@ -377,7 +377,7 @@ you could enter:

                  Example 3: a sample toggle macro:

                  -Macro: QUOTE toggle +Macro: QUOTE toggle

                  QUOTE begins a section of quoted text in a document diff --git a/contrib/mom/momdoc/letters.html b/contrib/mom/momdoc/letters.html index b1aa13d2..ad35a711 100644 --- a/contrib/mom/momdoc/letters.html +++ b/contrib/mom/momdoc/letters.html @@ -8,8 +8,8 @@ -Next   -Prev   +Next   +Prev   Back to Table of Contents

                  @@ -455,8 +455,8 @@ page" number at the bottom of multi-page letters, invoke


                  -Next   -Prev   +Next   +Prev   Top   Back to Table of Contents diff --git a/contrib/mom/momdoc/macrolist.html b/contrib/mom/momdoc/macrolist.html index b445782d..01125f72 100644 --- a/contrib/mom/momdoc/macrolist.html +++ b/contrib/mom/momdoc/macrolist.html @@ -114,6 +114,26 @@ sensibly.   + Lists + + +   + Margin notes + + +   + Line numbering + + +   + References + + +   + Bibliographies + + +   Table of contents @@ -1099,9 +1119,14 @@ see   - QUOTE_COLOR + QUOTE_AUTOLEAD UNDERLINE_QUOTES + +   + QUOTE_COLOR +   +

                  *Note that the use of QUOTE_INDENT sets the indent for both QUOTE @@ -1135,9 +1160,13 @@ and BLOCKQUOTE.   - BLOCKQUOTE_COLOR + BLOCKQUOTE_AUTOLEAD   + +   + BLOCKQUOTE_COLOR +  

                  @@ -1146,7 +1175,7 @@ and QUOTE.

                  Author linebreaks
                  -(also called "scene breaks") +(also called "scene" or "section" breaks)

                  @@ -1210,6 +1239,11 @@ and QUOTE. + + + + +
                    FOOTNOTE_RULE_LENGTH
                    FOOTNOTES_RUN_ON

                  *Indenting of footnotes is handled by arguments passed to FOOTNOTE. @@ -1337,6 +1371,82 @@ macro, .TITLE
                  **Applies to PRINTSTYLE TYPEWRITE only +

                  Margin notes

                  + + + + + + + + + + +
                  InitializeStart
                  MN_INITMN
                  + +

                  Line numbering

                  + + + + + + + + + + + + +
                  TextQuotesBlockquotes
                  NUMBER_LINESNUMBER_QUOTE_LINESNUMBER_BLOCKQUOTE_LINES
                  + +

                  References

                  + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                  Begin/end refsFootnote refsEndnote refsEmbedded refs
                  REFFOOTNOTE_REFSENDNOTE_REFSREF( / REF)
                     REF( / REF)
                     REF[ / REF]
                     REF{ / REF}
                  + +

                  Bibliographies

                  + + + + + + + + + + +
                  Start bibliography pageBibliography type
                  BIBLIOGRAPHYBIBLIOGRAPHY_TYPE
                  +

                  Table of contents

                  @@ -1661,8 +1771,10 @@ see
                  - - + + diff --git a/contrib/mom/momdoc/refer.html b/contrib/mom/momdoc/refer.html new file mode 100644 index 00000000..e3ad7868 --- /dev/null +++ b/contrib/mom/momdoc/refer.html @@ -0,0 +1,1482 @@ + + + + +Mom -- Bibliographies and References + + + + + +Next   +Prev   +Back to Table of Contents + + +

                  + Bibliographies and references +

                  +

                  +Introduction to bibliographies and references +
                  +Tutorial +

                  +
                  +Index of bibliography and reference macros +

                  + + +

                  Introduction to bibliographies and references

                  + + +Mom provides the ability to automatically format +and generate bibliography pages, as well as footnote or endnote +bibliographic references, or references embedded in text. She +accomplishes this by working in conjunction with a special +groff program called "refer". +

                  +refer is a groff +"pre-processor", which is to say that it scans your files looking +for very specific commands (i.e. lines that begin with a period +[dot], just like macros and document element tags). If the +commands aren't there, refer can't do it's job, +and neither can mom. The scanning is done +before any actual mom processing +occurs. +

                  +refer is a program that's been around for a long +time. It's powerful and has many, many features. Unfortunately, +the manpage (man refer), while complete and accurate, is +dense and not a good introduction to refer. (It's +a classic manpage Catch-22: the information it contains is most +useful only after you already grasp it.) +

                  +In order to get mom users up and running with +refer, this section of mom's +documentation focuses exclusively, in a recipe-like manner, on +what you need to know to use refer satisfactorily +in conjunction with mom. The information and +instructions are not to be taken as +a manual or tutorial on full refer usage. Much has +been left out, on purpose. +

                  +It is tempting to provide two levels of documentation, one for +users familiar with refer and one for newcomers +to groff and mom, but such an +approach may muddy the waters for newcomers. Mom's +allegiance, first and foremost, is to newcomers. If you're already +a refer user, the information herein will be useful +for adapting your current refer usage to +mom's way of doing things. If you've never used +refer, the information is essential, and, in many +cases, may be all you need. +

                  +(For the benefit of old groff-hands: refer +support in mom is heavily based on the +refer module of the ms macros. The choice +was deliberate so that those wishing to play around with +mom's bibliography formatting style would be +tinkering with the familiar.) +

                  +refer requires first that you create a +bibliographic database. From the information contained in the +database, mom formats and generates bibliographies +and references in MLA (Modern Language Association) style. MLA +style is clean, contemporary and flexible, and is widely used in +the humanities, where the range of material that has to be +referenced can run from simple books to live interviews and film. +

                  +Once you have created your database, you instruct +refer (and mom) to access entries +in it by supplying keywords from the entries. Depending on what +you've instructed mom to do, she will put the +entries--fully and properly formatted with respect to order, punctuation +and italicization--in footnotes, endnotes, or a full bibliography. +

                  +I encourage anyone interested in what MLA style looks like--and, by +extension, how your bibliographies and references will look after +mom formats them--to check out +

                  +

                  +	http://www.aresearchguide.com/12biblio.html
                  +
                  + +or any other website or reference book on MLA style. +

                  +NOTE: MLA style requires that second and +subsequent lines of individual references be indented. Mom +takes care of this for you with a default indent, which +can be changed with the macro +INDENT_REFS. + + +

                  Tutorial

                  + +
                    +
                  1. Creating a refer database +
                  2. Required "refer" commands +
                  3. Accessing references +
                  4. Telling mom where to put references +
                  5. Creating bibliography pages +
                  6. Invoking groff with mom and refer +
                  +

                  + +

                  1. Creating a refer database

                  +

                  +The first step in using refer with +mom is setting up your bibliographic database. +The database is a file containing separate entries for each +reference you want to access from your mom files. +The file is not a "mom" file; it is a separate database. +You may set up individual databases for individual documents, or +create a large database that contains all the references you'll +ever need. +

                  +Entries ("records") in the database file are separated from each +other by a single, blank line. The records themselves are composed +of single lines ("fields") with no blank lines between them. Each +field begins with a percent sign and a single letter (the "field +identifier") e.g. %A or %T. 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 field. No punctuation +should go at the ends of fields; mom adds what's +correct automatically. Do note, however, that author(s) (%A) +requires that you enter the author information exactly as you wish +it to come out (minus the period), including the comma after the +first author's last name. +

                  +Here's a sample database containing two records so you can +visualize what the above paragraph says: +

                  +

                  +%A Schweitzer, Albert
                  +%A C.M. Widor
                  +%T J.S. Bach
                  +%l Ernest Newman
                  +%V Vol 2
                  +%C London
                  +%I Adam and Charles Black
                  +%D 1923
                  +%O 2 vols
                  +%K bach vol 2
                  +
                  +%A Schaffter, Peter
                  +%T The Schumann Proof
                  +%C Toronto
                  +%I RendezVous Press
                  +%D 2004
                  +%K schumann schaffter
                  +
                  + +The order in which you enter fields doesn't matter. +mom and refer will re-arrange +them in the correct order for you. +

                  +The meaning of the letters follows. There are, with +refer, quite a few--all uppercase--which have, over +time, come to be "standard". Mom respects these. +However, she adds to the list (mostly the lowercase letters). +

                  +

                  +	%A Author           -- additional authors may be entered on separate %A
                  +	                       lines as in first entry of the sample, above; mom 
                  +	                       and refer will figure out what to do with multiple
                  +	                       authors according to MLA rules
                  +	%T Title            -- either the primary title (e.g. of a book), or the
                  +	                       title of an article (e.g. within a book or
                  +	                       journal or magazine)
                  +	%B Book title       -- the title of a book when %T contains the title
                  +	                       of an article; otherwise, use %T for book
                  +	                       titles
                  +	%R Report number    -- for technical reports
                  +	%J Journal name     -- the name of a journal or magazine when %T
                  +	                       contains the title of an article
                  +	%E Editor           -- additional editors may be entered on separate %E
                  +	                       lines (like authors); mom and refer will figure
                  +	                       out what to do with them according to MLA rules
                  +	%e Edition          -- the number of name of a specific edition
                  +	                       (e.g. Second, 2nd, Collector's, etc.)
                  +	%V Volume           -- volume number of a journal or series of books
                  +	%N Journal number   -- journal or magazine number
                  +	%S Series           -- series name for books or journals that are part of
                  +	                       a series
                  +	%C City             -- the city of publication
                  +	%I Publisher        -- the publisher; %I stands for "Issuer"
                  +	%D Publication date
                  +	%P Page number(s)   -- enter page ranges as, e.g., 22-25
                  +	%G Gov't.
                  +	   ordering number  -- for government publications
                  +	%O Other            -- additional information or comments you want
                  +	                       to appear at the end of the reference
                  +	%K Keywords         -- any words that will clear up ambiguities
                  +	                       resulting from database entries that
                  +	                       contain, say, the same author or the
                  +	                       same title
                  +	%d original
                  +	   publication date -- if different from the date
                  +	                                   of publication
                  +	%a additions        -- for books, any additions to the original work,
                  +					       such as the preface to a new edition or a new
                  +	                       introduction
                  +	%t reprint title    -- if different from a work's original title
                  +	%l translator       -- if the translator is not the editor; if more
                  +	                        than one translator, this field should contain
                  +	                        all the names, with appropriate punctuation
                  +	%r translator
                  +	   and editor       -- if tr. and ed. are one in the same;
                  +	%s site name        -- for web sites, the site name
                  +	%c content
                  +	   of site          -- for web sites, the content, if unclear
                  +	                       (i.e. advertisement, cartoon, blog)
                  +	%o organization     -- for web sites, the organization, group or
                  +	                       sponsor of the site
                  +	%a access date      -- for a website, the date you accessed it
                  +	%u URL              -- for websites, the full URL of the site
                  +
                  + +
                  +Tip: If you have hyphenation turned on in your +document (you probably do), mom will hyphenate +your references. This can be a problem because references +typically contain several proper names. Proper names shouldn't be +hyphenated. The solution is to prepend to any proper name in the +database the groff +discretionary hyphen +character, \%, like this: +

                  +

                  +	%A Hill, \%Reginald
                  +
                  + +Alternatively, you can turn hyphenation off entirely in +references with the macro, +HYPHENATE_REFSOFF. +

                  + +

                  2. Required "refer" commands

                  +

                  +Having set up your database, you now need to put some +refer-specific commands at the top of your +mom file. You cannot skip this step, nor can you +"source" these commands with the groff +primitive, +.so. They must +appear, exactly as shown, in every file requiring bibliographic +references. +

                  +refer commands are introduced with a single +line containing .R1, and concluded with a single line +containing .R2. What you put between the .R1 +and .R2 lines are the commands themselves. The commands +should be entered one per line, in lowercase letters, with +no initial period (dot). +

                  +Here's an example: +

                  +

                  +	.R1
                  +	no-label-in-text
                  +	no-label-in-reference
                  +	.R2
                  +
                  + +There are an awful lot of refer commands. We will +focus only on those required to get mom cooperating +with refer. If you're interested, study the +refer manpage to discover what other commands are +available and how to manipulate them. +

                  +At a minimum, all mom files accessing +a bibliographic database must contain the following +refer commands, exactly as shown: +

                  + +

                  +.R1
                  +no-label-in-text
                  +no-label-in-reference
                  +join-authors ", and " ", " ", and "
                  +database <full path to the database>
                  +.R2
                  +
                  + +The first two commands tell refer to let +mom handle everything associated with footnote +and endnote markers, both in the body of the document, and in the +footnotes/endnotes themselves. +

                  +The third command is required for mom to handle +multiple authors in proper, MLA style. +

                  +The last command, database, assumes you have created +your own database, and do not otherwise have a system-wide +"default" database. "...full path to the database" means the full +path including the database filename, e.g. +/home/user/refer/my_database. +

                  If you're already a refer user, feel free to +enter whatever refer commands are necessary to +access the database(s) you want. +

                  +With the above refer block, you can embed +references directly into the text of your document, or have them +output as footnotes or endnotes. If you want to "collect" +references for later output on a bibliography page, the block must +read: +

                  +

                  +.R1
                  +no-label-in-text
                  +no-label-in-reference
                  +join-authors ", and " ", " ", and "
                  +database <full path to the database>
                  +sort
                  +accumulate
                  +.R2
                  +
                  + +

                  3. Accessing references

                  +

                  +References are accessed by putting keywords, all on one line, +between the refer commands .[ and +.]. Both of these commands must appear on separate +lines, by themselves, like this: +

                  +

                  +	.[
                  +	keyword(s)
                  +	.]
                  +
                  + +Keywords are any word, or set of words, that identify a database +record (i.e. a reference) unambiguously. (refer +doesn't like ambiguity.) +

                  +If, for example, you want to reference a book by Ray Bradbury, +and the database contains only one book by Bradbury, a suitable +keyword would be "Bradbury". If your database contains several +books by Bradbury, say, Fahrenheit 451 and The Martian +Chronicles, you could reference them with the keywords, "451" +and "Martian". If, in addition to the two books by Bradbury, you +also had one whose title was The Martian Mission, suitable +keywords to reference The Martian Chronicles might be: +

                  +

                  +	.[                or    .[                   or  .[
                  +	Bradbury Martian        Bradbury Chronicles      Martian Chronicles
                  +	.]                      .]                       .]
                  +
                  + +The database field identifier, %K, lets you create special keywords +for references. This can be very handy if you need both a "short" +and a "long" reference to the same work. The short reference might +be used in footnotes; the long one in a bibliography. Consider the +following: +

                  +

                  +	%A Isherwood, Christopher      %A Isherwood
                  +	%T Mr. Norris Changes Trains   %T Mr. Norris Changes Trains
                  +	%d 1935                        %K Nor short
                  +	%t The Last of Mr. \%Norris
                  +	%a Intro. Tom Crawford
                  +	%C New York
                  +	%I New Directions
                  +	%D 1945
                  +	%K Norris
                  +
                  +
                  + +To access the shorter reference, you'd do +

                  +

                  +	.[
                  +	Nor short
                  +	.]
                  +
                  + +To access the longer one, you'd do +
                  +	.[
                  +	Norris
                  +	.]
                  +
                  + +

                  4. Telling mom where to put references

                  +

                  +Mom provides several mechanisms for outputting +references where you want. +

                  +

                  Embedding references in the document body

                  +

                  +References may be embedded in the document body, surrounded by +parentheses, square brackets, or braces. Use whichever you prefer, +following the recipes below. +

                  +

                  +	Parentheses    Square brackets    Braces
                  +	-----------    ---------------    ------
                  +
                  +	.REF(          .REF[              .REF{
                  +	.[             .[                 .[
                  +	keyword(s)     keyword(s)         keyword(s)
                  +	.]             .]                 .]
                  +	.REF)          .REF]              .REF}
                  +
                  + +

                  Footnote or endnote references

                  +

                  +Most times, you'll probably want references in either footnotes or +endnotes. Mom provides a simple mechanism whereby +you can choose which, or even switch back and forth. The primary +tag is +REF, which is used like this: +

                  +

                  +	.REF
                  +	.[
                  +	keyword(s)
                  +	.]
                  +	.REF
                  +
                  + +REF collects references and outputs them +where you say with the macros, +FOOTNOTE_REFS +or +ENDNOTE_REFS. +Neither +FOOTNOTE_REFS nor ENDNOTE_REFS +requires an argument. All they do is tell REF, +whenever it's invoked, where to put the references. +

                  +A recipe for footnote references looks like this: +

                  +	.FOOTNOTE_REFS
                  +	.REF
                  +	.[
                  +	keyword(s)
                  +	.]
                  +	.REF
                  +
                  + +When FOOTNOTE_REFS are enabled, REF +behaves identically to +FOOTNOTE, +so please read the +HYPER IMPORTANT NOTE +found in the document entry for FOOTNOTE. +

                  +The reference between the first and second REF +will be treated as a footnote, as will all subsequent +REF pairs unless you invoke the macro, +ENDNOTE_REFS. +

                  +A recipe for endnote references looks like this: +

                  +	.ENDNOTE_REFS
                  +	.REF
                  +	.[
                  +	keyword(s)
                  +	.]
                  +	.REF
                  +
                  + +The reference between the first and second REF +will be treated as an endnote, as will all subsequent +REF pairs unless you invoke the macro, +FOOTNOTE_REFS. +

                  +When ENDNOTE_REFS are enabled, REF +behaves identically to +ENDNOTE, +so please read the +HYPER IMPORTANT NOTE +found in the document entry for ENDNOTE. +

                  +The innate flexibility of this scheme allows you to have both +footnote references and endnote references in the same document. +This would be desirable if, say, you wanted "short" references in +footnotes, and complete references in endnotes. +

                  + +

                  Collected references

                  +

                  +Sometimes, you may want to put references in input text near +sections of text to which they pertain, but not actually want +them output until later (typically, on a bibliography page). +REF is used for this, too, but you have to make +sure your refer commands block is set up properly. +The recipe for this is: +

                  + +

                  +.R1
                  +no-label-in-text
                  +no-label-in-reference
                  +join-authors ", and " ", " ", and "
                  +database <full path to the database>
                  +sort
                  +accumulate
                  +.R2
                  +
                  + +After this set up, and provided you don't issue a +FOOTNOTE_REFS or ENDNOTE_REFS +command, all reference between REF pairs will be +collected for later output. +

                  +As a precaution, mom will issue a message the +first time you call .REF if neither +FOOTNOTE_REFS nor ENDNOTE_REFS is +in effect. If collected references are what you want, and you have +set up your .R1 - .R2 block as above, you may +safely ignore the message. +

                  +LIMITATION: You cannot combine "collected" +references (plain REF) with REFs +that are instructed to go into footnotes (with +FOOTNOTE_REFS) or endnotes (with +ENDNOTE_REFS). This is a limitation imposed by +refer, not mom. + +

                  5. Creating bibliography pages

                  +

                  +Bibliography pages are separate pages, like endnotes, on which +complete bibliographies are output. And, like endnotes pages, just +about every element on them can be designed to your specifications +with control macros. (See +Control macros for bibliographies.) +A bibliography page that uses mom's defaults +begins with the macro, +BIBLIOGRAPHY, +like this: +

                  +

                  +	.BIBLIOGRAPHY
                  +
                  + +

                  +Following BIBLIOGRAPHY, you have three choices of +how to proceed. +

                  +If you have elected to have references collected from within the +body of a document (see above, +Collected references, +for instructions), which assumes you have a refer +command block like the one +here +at the top of your document, you need only do +

                  +

                  +	.BIBLIOGRAPHY
                  +	.[
                  +	$LIST$
                  +	.]
                  +
                  + +If you want to create the bibliography by hand (which may be the +case if you've used footnote and/or endnote references throughout +your document), follow this recipe, which assumes you already have a +refer block like the one +here +at the top of your document: +

                  +

                  +	.BIBLIOGRAPHY
                  +	.R1
                  +	sort
                  +	accumulate
                  +	.R2
                  +	.[          -+
                  +	keyword(s)   |
                  +	.]           | "keyword(s)" are keywords identifying the
                  +	.[           | particular bibliographic reference you want
                  +	keyword(s)   | from your database.  Order doesn't matter here;
                  +	.]           | the refer command, sort, takes care of that.
                  +	.[           |
                  +	keyword(s)   |
                  +	.]          -+
                  +	.[
                  +	$LIST$
                  +	.]
                  +
                  + +Your final choice is to output your whole database. Again, +assuming you have a refer block like the one +here at the top of your file, you need +only do: +

                  +

                  +	.BIBLIOGRAPHY
                  +	.R1
                  +	bibliography <full path to database>
                  +	.R2
                  +
                  + +If you haven't put a refer block in +your file already, you can put the whole thing after +BIBLIOGRAPHY, like this: +

                  +

                  +	.BIBLIOGRAPHY
                  +	.R1
                  +	no-label-in-text                       -+
                  +	no-label-in-reference                   | These are actually optional
                  +	database <full path to the database>   -+ 
                  +	join-authors ", and " ", " ", and "
                  +	bibliography <full path to database>
                  +	.R2
                  +
                  + +Whichever option you choose, mom will output a +full bibliography page, complete with a title (BIBLIOGRAPHY by +default, but that can be changed). + +

                  6. Invoking groff with mom and refer

                  +

                  +So, now you've got a document, formatted properly to use +references processed with refer, what do you do to +output the document? +

                  +It's simple. Instead of invoking groff with just +the -mom option, as explained +here, +invoke groff with the -R option as well, like this: +

                  +

                  +	groff -R -mom filename
                  +
                  + +
                  + +

                  +

                  Index of bibliography and reference macros

                  + +

                  + + + +


                  +

                  Marking off references for footnotes, endnotes, or collection

                  +

                  + +Tag: REF +

                  +The macro, REF, tells mom that +what follows is refer-specific, a +keyword-identified reference from a +refer database. Depending on whether you've +issued a +FOOTNOTE_REFS +or +ENDNOTE_REFS +instruction, REF also tells mom +where to place the reference. If FOOTNOTE_REFS, +the reference will be formatted and placed in a footnote. If +ENDNOTE_REFS, the reference will be collected for +output as an endnote. If you have issued neither instruction, the +reference will be collected for later output, most likely on a +bibliography page. +

                  +Before you use REF, you must create a +refer block containing refer +commands (see +Required refer commands +in the tutorial, above). +

                  +REF usage always looks like this: +

                  +

                  +	.REF
                  +	.[
                  +	keyword(s)
                  +	.]
                  +	.REF
                  +
                  + +Notice that REF "brackets" the +refer call, and never takes an argument. +

                  +What REF really is is a convenience. One could, +for example, put a reference in a footnote by doing +

                  +

                  +	.FOOTNOTE
                  +	.[
                  +	keyword(s)
                  +	.]
                  +	.FOOTNOTE OFF
                  +
                  + +However, if you have a lot of references going into footnotes (or +endnotes), it's much shorter to type .REF/.REF than +.FOOTNOTE/.FOOTNOTE OFF. It also helps you +distinguish--visually, in your input file--between footnotes (or +endnotes) which are references, and footnotes (or endnotes) which +are explanatory, or expand on the text. +

                  +Additional arguments: If you're using +REF to put references in footnotes and your +footnotes need to be indented, you may (indeed, should) pass +REF the same arguments used to indent footnotes. +See +FOOTNOTE. +

                  +Note: +When REF is used with +FOOTNOTE_REFS, +it behaves identically to +FOOTNOTE, +so please read the +HYPER IMPORTANT NOTE +found in the document entry for FOOTNOTE. +

                  +When REF is used with +ENDNOTE_REFS, +it behaves identically to +ENDNOTE, +so please read the +HYPER IMPORTANT NOTE +found in the document entry for ENDNOTE. + +
                  + + + +


                  +

                  Instruct REF to put references in footnotes

                  +

                  + +Macro: FOOTNOTE_REFS +

                  +FOOTNOTE_REFS is an instruction to +REF, +saying, "put all subsequent references bracketed by the +REF macro into footnotes." You invoke it by +itself, with no argument. +

                  +When FOOTNOTE_REFS is in effect, regular +footnotes, (i.e. those introduced with .FOOTNOTE and +terminated with .FOOTNOTE OFF) continue to behave +normally. +

                  +You may switch between FOOTNOTE_REFS and +ENDNOTE_REFS +at any time. +

                  +If you have a lot of footnote references, and are identifying +footnotes by line number rather than by markers in the text, you may +want to enable +FOOTNOTES_RUN_ON +in conjunctions with FOOTNOTE_REFS. + +
                  + + + +


                  +

                  Instruct REF to put references in endnotes

                  +

                  + +Macro: ENDNOTE_REFS +

                  +ENDNOTE_REFS is an instruction to +REF, +saying, "add all subsequent references bracketed by the +REF macro to endnotes." You invoke it by +itself, with no argument. +

                  +When ENDNOTE_REFS is in effect, +mom continues to format regular endnotes, (i.e. +those introduced with .ENDNOTE and terminated with +.ENDNOTE OFF) in the normal way. +

                  +You may switch between ENDNOTE_REFS and +FOOTNOTE_REFS +at any time. + +
                  + + + +


                  +

                  References embedded in text

                  +

                  + +Macro pair: REF(  ...  REF) +
                  +Macro pair: REF[  ...  REF] +
                  +Macro pair: REF{  ...  REF} +

                  +You may sometimes want to embed references directly into the body +of your documents, typically, but not always, inside parentheses. +Mom makes this possible through the use of the +REF<bracket type> macros. +

                  +All three macro pairs, above, are invoked the same way, namely by +introducing the reference with the first ("open") macro of +the REF<bracket type> pair, and +terminating it with the second ("close") +REF<bracket type> of the pair. For +example +

                  +

                  +	.REF(
                  +	.[
                  +	keyword(s)
                  +	.]
                  +	.REF)
                  +
                  + +will embed a reference in the body of your document, surrounded by +parentheses. .REF[ ... .REF] will +surround the reference with square brackets. +.REF{ ... .REF} will surround it with +curly braces. +
                  + + + +
                  +

                  Manage the second-line indent of references

                  +

                  + +Macro: INDENT_REFS FOOTNOTE | ENDNOTE | BIBLIO <indent> +
                  +*<indent> requires a unit of measure +

                  +Proper MLA-style references should have their second, and subsequent +lines, if any, indented. Since mom formats +references in MLA style, she automatically indents second lines. +By default, the indent for the second line of references, +regardless of whether the references appear in footnotes, endnotes, +or bibliographies, is 1.5 +ems +for +PRINSTYLE +TYPESET +and 2 ems for +PRINSTYLE +TYPEWRITE. +

                  +If you'd like to change the indent for footnotes, endnotes or +bibliographies, just invoke INDENT_REFS with a +first argument telling mom for which you want the +indent changed, and a second argument saying what you'd like the +indent to be. For example, if you want the second-line indent of +references on a bibliography page to be 3 +picas, +

                  +

                  +	.INDENT_REFS BIBLIO 3P
                  +
                  + +is how you'd set it up. +

                  +Tip: if you are identifying endnotes by line +number +(ENDNOTE_MARKER_STYLE LINE) +and you have instructed mom to put references +bracketed by +REF +into endnotes (with +ENDNOTE_REFS), +you will probably want to adjust the second-line indent for +references in endnotes, owing to the way mom +formats line-numbered endnotes. Study the output of such +documents to see whether an indent adjustment is required. +
                  + + + +


                  +

                  Enable/disable hyphenation of references

                  +

                  + +Macro: HYPHENATE_REFS <toggle> +

                  +If you have hyphenation turned on for a document (see HY), +and in most cases you probably do, mom will +hyphenate references bracketed by the +REF +macro. Since references typically contain quite a lot of proper +names, which shouldn't be hyphenated, you may want to disable +hyphenation for references. +

                  +HYPHENATE_REFS is a toggle macro; +invoking it by itself will turn automatic hyphenation of +REF-bracketed references on (the default). +Invoking it with any other argument (OFF, +NO, X, etc.) will disable +automatic hyphenation for references bracketed by +REF. +

                  +An alternative to turning reference hyphenation off is to prepend +to selected proper names in your refer database +the groff +discretionary hyphen +character, \%. (See +here +in the tutorial for an example.) +

                  +Note: references embedded in the body of a document +with +REF<bracket type> +are considered part of +running text, +and are hyphenated (or not) according to whether hyphenation +is turned on or off for running text. Therefore, if you want to +disable hyphenation for such references, you must do so +temporarily, with HY, like this: +

                  +

                  +	.HY OFF
                  +	.REF(
                  +	.[
                  +	keyword(s)
                  +	.]
                  +	.REF)
                  +	.HY
                  +
                  + +Alternatively, sprinkle your database fields liberally with +\%. +
                  + + + +
                  +

                  Begin a bibliography page

                  +

                  + +Macro: BIBLIOGRAPHY +
                  +

                  +If you want to append a bibliography to your document, all you need +do is invoke BIBLIOGRAPHY at the place you want +it. BIBLIOGRAPHY breaks to a new page, prints the +title (BIBLIOGRAPHY by default, but that can be changed), and awaits +refer instructions. How to create bibliographies +is covered in the tutorial section, +Creating bibliography pages. +

                  +See the +Bibliography page style control macros +for macros to tweak, design and control the appearance of +bibliography pages. +
                  + + + +


                  +

                  Plain, or numbered list bibliography

                  +

                  + +Macro: BIBLIOGRAPHY_TYPE PLAIN | LIST [ <list separator> ] [ <list prefix> ] +

                  +Mom offers two styles of bibliography output: plain, +or numbered list style. With PLAIN, bibliography +entries are output with no enumerators. With LIST, +each entry is numbered. +

                  +Entering .BIBLIOGRPHY_TYPE PLAIN gives you a plain +bibliography. +

                  +Entering .BIBLIOGRAPHY_TYPE LIST gives you an enumerated +bibliography. The two optional arguments, +<list separator> and +<list prefix> have the same meaning as +the equivalent arguments to +LIST +(i.e. <separator> and <prefix>). +

                  +You may enter BIBLIOGRAPHY_TYPE either before or +after BIBLIOGRAPHY. It must, however, always come +before the refer command to output bibliographies. +(See the tutorial section, +Creating bibliography pages, +for instructions on how to output bibliographies.) +

                  +Mom's default BIBLIOGRAPHY_TYPE +is LIST, with a period (dot) as the separator, and +no prefix. + +
                  + + + +


                  +

                  Bibliography page style control

                  + +

                  +Mom processes bibliography pages in a manner very +similar to the way she processes endnotes pages. The bibliography +page control macros, therefore, behave in the same way as their +endnotes pages equivalents. +
                  +

                    +
                  1. General bibliography page style control + +
                  2. Bibliography pages header/footer control + +
                  3. Bibliography page head (i.e. the title at the top) control + + +
                  +
                  + +

                  1. General bibliography page style control

                  + +

                  *Bibliography family/font/quad

                  +

                  +See +Arguments to the control macros. +

                  +

                  +.BIBLIOGRAPHY_FAMILY    default = prevailing document family; default is Times Roman
                  +.BIBLIOGRAPHY_FONT      default = roman
                  +.BIBLIOGRAPHY_QUAD*     default = justified
                  +
                  +*Note: BIBLIOGRAPHY_QUAD must be set to either L or J
                  +
                  + + + +

                  *Bibliography point size

                  +

                  +Macro: BIBLIOGRAPHY_PT_SIZE <base type size of bibliography> + +

                  +Unlike most other control macros that deal with size of document +elements, BIBLIOGRAPHY_PT_SIZE takes as its argument an +absolute value, relative to nothing. Therefore, the argument represents +the size of bibliography type in +points, +unless you append an alternative +unit of measure. +For example, +

                  +

                  +	.BIBLIOGRAPHY_PT_SIZE 12
                  +
                  + +sets the base point size of type on the bibliography page to 12 +points, whereas +

                  +

                  +	.BIBLIOGRAPHY_PT_SIZE .6i
                  +
                  + +sets the base point size of type on the bibliography page to 1/6 of an +inch. +

                  +The type size set with BIBLIOGRAPHY_PT_SIZE is the size of +type used for the text of the bibliographies, and forms the basis from which +the point size of other bibliography page elements is calculated. +

                  +The default for +PRINTSTYLE TYPESET +is 12.5 points (the same default size used in the body of the document). +

                  + + + +

                  *Bibliography lead

                  +

                  +Macro: BIBLIOGRAPHY_LEAD <base leading of bibliographies> [ ADJUST ] +
                  +*Does not require a unit of measure; points is assumed + +

                  +Unlike most other control macros that deal with leading of document +elements, BIBLIOGRAPHY_LEAD takes as its argument an +absolute value, relative to nothing. Therefore, the argument represents +the +leading +of endnotes in +points +unless you append an alternative +unit of measure. +For example, +

                  +

                  +	.BIBLIOGRAPHY_LEAD 14
                  +
                  + +sets the base leading of type on the bibliography page to 14 +points, whereas +

                  +

                  +	.BIBLIOGRAPHY_LEAD .5i
                  +
                  + +sets the base leading of type on the bibliography page to 1/2 inch. +

                  +If you want the leading of bibliographies adjusted to fill the page, +pass BIBLIOGRAPHY_LEAD the optional argument +ADJUST. (See +DOC_LEAD_ADJUST +for an explanation of leading adjustment.) +

                  +The default for +PRINTSTYLE TYPESET +is 14 points, adjusted. +

                  +NOTE: Even if you give mom a +DOC_LEAD_ADJUST OFF command, she will still, by +default, adjust bibliography leading. You MUST enter +BIBLIOGRAPHY_LEAD <lead> with no +ADJUST argument to disable this default behaviour. +

                  + + + +

                  *Singlespace bibliographies (TYPEWRITE only)

                  +

                  +Macro: SINGLESPACE_BIBLIOGRAPHY <toggle> + +

                  +If your +PRINTSTYLE +is TYPEWRITE and you use TYPEWRITE's default +double-spacing, bibliographies are double-spaced. If your document +is single-spaced, bibliographies are single-spaced. +

                  +If, for some reason, you'd prefer that bibliographies be single-spaced +in an otherwise double-spaced document (including double-spaced +collated +documents), invoke SINGLESPACE_BIBLIOGRAPHY with +with no argument. +

                  + + + +

                  *Adjusting the space between bibliography entries

                  +

                  +Macro: BIBLIOGRAPHY_SPACING <amount of space> +
                  +*Requires a unit of measure + +

                  +By default, mom inserts 1 linespaces between +bibliography entries on bibliography pages. If you'd prefer she +add a different amount of space, instruct her to do so with the +macro, BIBLIOGRAPHY_SPACING. Say, for example, +you'd prefer only 1/2 linespace. That would be done with +

                  +

                  +	.BIBLIOGRAPHY_SPACING .5v
                  +
                  + +As with endnotes pages, owing to the space inserted between bibliography +entries, bibliography pages may have hanging bottom margins. +Unlike endnotes pages, mom is sad to report that +there's nothing you can do about this, except a) pray things work +out, or b) set your BIBLIOGRAPHY_SPACING to zero. + + + +

                  *Turning off column mode during bibliography output

                  +

                  +Macro: BIBLIOGRAPHY_NO_COLUMNS <toggle> + +

                  +By default, if your document is +set in columns, +mom sets the bibliographies in columns, too. However, +if your document is set in columns and you'd like the bibliographies not +to be, just invoke BIBLIOGRAPHY_NO_COLUMNS with no +argument. The bibliography pages will be set to the full page measure +of your document. +

                  +If you output bibliographies at the end of each document in a +collated +document set in columns, column mode will automatically +be reinstated for each document, even with +BIBLIOGRAPHY_NO_COLUMNS turned on. +

                  + + + +

                  *Bibliography-page page numbering style

                  +

                  +Macro: BIBLIOGRAPHY_PAGENUM_STYLE DIGIT | ROMAN | roman | ALPHA | alpha + +

                  +Use this macro to set the page numbering style of bibliography pages. +The arguments are identical to those for +PAGENUM_STYLE. +The default is digit. You may want to change it +to, say, alpha, which you would do with +

                  +

                  +	.BIBLIOGRAPHY_PAGENUM_STYLE alpha
                  +
                  + + + +

                  *Setting the first page number of bibliography pages

                  +

                  +Macro: BIBILOGRAPHY_FIRST_PAGENUMBER <page # that appears on page 1 of bibliographies> + +

                  +Use this macro with caution. If all bibliographies for several +collated +documents are to be output at once, i.e. not at the end of each +separate doc, BIBLIOGRAPHY_FIRST_PAGENUMBER tells +mom what page number to put on the first page of +the bibliography. +

                  +If you set BIBLIOGRAPHY_FIRST_PAGENUMBER in collated +documents where the bibliographies are output after each separate doc, +you have to reset every separate document's first page number after +COLLATE +and before +START. +

                  + + + +

                  *Omitting a page number on the first page of bibliographies

                  +

                  +Macro: BIBLIOGRAPHY_NO_FIRST_PAGENUM <toggle> + +

                  +This macro is for use only if FOOTERS are on. It +tells +BIBLIOGRAPHY +not to print a page number on the first bibliography page. +Mom's default is to print the page number. +

                  + + + +

                  *Suspending pagination of bibliography pages

                  +

                  +Macro: SUSPEND_PAGINATION +
                  +Macro: RESTORE_PAGINATION + +

                  +SUSPEND_PAGINATION doesn't take an argument. +Invoked immediately prior to +BIBLIOGRAPHY, +it turns off pagination for the duration of the bibliography. +Mom continues, however to increment page numbers +silently. +

                  +To restore normal document pagination after bibliographies, invoke +RESTORE_PAGINATION (again, with no argument) +immediately after you've finished with your bibliography. + +

                  2. Bibliography page header/footer control

                  +

                  + +If you wish to modify what appears in the header/footer that appears +on bibliography pages, make the changes before you invoke +BIBLIOGRAPHY, +not afterwards. +

                  +Except in the case of +DOCTYPE CHAPTER, +mom prints the same header or footer used throughout +the document on bibliography pages. Chapters get treated differently +in that, by default, mom does not print the +header/footer centre string (normally the chapter number or chapter +title.) In most cases, this is what you want. However, should you +not want mom to remove the centre string from +the bibliography pages headers/footers, invoke +BIBLIOGRAPHY_HEADER_CENTER +with no argument. +

                  +An important change you may want to make is to put the word +"Bibliography" in the header/footer centre position. +To do so, do +

                  +

                  +	.HEADER_CENTER "Bibliography"
                  +	           or
                  +	.FOOTER_CENTER "Bibliography"
                  +
                  + +prior to invoking .BIBLIOGRAPHY. If your +DOCTYPE +is CHAPTER, you must also invoke +BIBLIOGRAPHY_HEADER_CENTER +for the HEADER_CENTER to appear. +

                  + +

                  *Bibliography page header/footer centre string

                  +

                  +Macro: BIBLIOGRAPHY_HEADER_CENTER toggle + +

                  +If your +DOCTYPE +is CHAPTER and you want mom to include +a centre string in the headers/footers that appear on bibliography pages, +invoke BIBLIOGRAPHY_HEADER_CENTER (or +BIBLIOGRAPHY_FOOTER_CENTER) with no argument. +Mom's default is NOT to print the centre string. +

                  +If, for some reason, having enabled the header/footer centre string +on bibliography pages, you wish to disable it, invoke the same macro +with any argument (OFF, QUIT, Q, X...). +

                  + +

                  *Allow headers on bibliography pages

                  +

                  +Macro: BIBLIOGRAPHY_ALLOWS_HEADERS <none> | ALL + +

                  +By default, if HEADERS are on, mom +prints page headers on all bibliography pages except the first. If you +don't want her to print headers on bibliography pages, do +

                  +

                  +	.BIBLIOGRAPHY_ALLOWS_HEADERS OFF
                  +
                  + +If you want headers on every page including the first, do +

                  +

                  +	.BIBLIOGRAPHY_ALLOWS_HEADERS ALL
                  +
                  + +NOTE: If FOOTERS are on, +mom prints footers on every bibliography page. This is +a style convention. In mom, there is no such beast +as BIBLIOGRAPHY_ALLOWS_FOOTERS OFF. +

                  + +

                  3. Bibliography page first page head (title) control

                  + + + +

                  *Bibliography pages first page head (title) string

                  +

                  +Macro: BIBLIOGRAPHY_STRING "<head to print at the top of bibliography pages>" + +

                  +By default, mom prints the word "BIBLIOGRAPHY" +as a head at the top of the first page of a bibliography. If you want her +to print something else, invoke BIBLIOGRAPHY_STRING with +the bibliography page head you want, surrounded by double-quotes. If +you don't want a head at the top of the first bibliography page, invoke +BIBLIOGRAPHY_STRING with a blank argument (either two +double-quotes side by side -- "" -- or no argument +at all). +

                  + + + +

                  *Bibliography page first page head (title) control

                  +

                  +See +Arguments to the control macros. +

                  +

                  +.BIBLIOGRAPHY_STRING_FAMILY    default = prevailing document family; default is Times Roman
                  +.BIBLIOGRAPHY_STRING_FONT      default = bold
                  +.BIBLIOGRAPHY_STRING_SIZE*     default = +1
                  +.BIBLIOGRAPHY_STRING_QUAD      default = centred
                  +
                  +*Relative to the size of the bibliography text (set with BIBLIOGRAPHY_PT_SIZE)
                  +
                  + + + +

                  *Bibliography-page head (title) underscoring

                  +

                  +Macro: BIBLIOGRAPHY_STRING_UNDERSCORE toggle | 2 + +

                  +Invoked by itself, BIBLIOGRAPHY_STRING_UNDERSCORE will +underscore the bibliography page head. Invoked with the argument 2 +(i.e. the digit 2), BIBLIOGRAPHY_STRING_UNDERSCORE will +double-underscore the head. Invoked with any other argument, the macro +disables underscoring of the head. +

                  +Mom's default is to double-underscore the +head, therefore if you want no underscoring, you must insert +.BIBLIOGRAPHY_STRING_UNDERSCORE OFF (or QUIT, X, NO, +NONE, etc.) into your document prior to outputting a +bibliography with +BIBLIOGRAPHY. + + + +

                  *Bibliography-page head (title) automatic capitalization

                  +

                  +Macro: BIBLIOGRAPHY_STRING_CAPS toggle + +

                  +Invoked by itself, BIBLIOGRAPHY_STRING_CAPS will +automatically capitalize the bibliography page head. Invoked with any +other argument, the macro disables automatic capitalization of the +head. +

                  +If you're generating a table of contents, you may want the +bibliography page head string in caps, but the toc entry in caps/lower +case. If the argument to +BIBLIOGRAPHY_STRING +is in caps/lower case and BIBLIOGRAPHY_STRING_CAPS is +on, this is exactly what will happen. +

                  +Mom's default is to capitalize the bibliography-page +head string. +

                  + +
                  + +


                  +Next   +Prev   +Top   +Back to Table of Contents + + diff --git a/contrib/mom/momdoc/reserved.html b/contrib/mom/momdoc/reserved.html index 228b69f1..ab8eeb19 100644 --- a/contrib/mom/momdoc/reserved.html +++ b/contrib/mom/momdoc/reserved.html @@ -272,6 +272,8 @@ p Output line horiz position at end of #REMOVE Used in LIST OFF cleanup #RESTORE_LEAD Lead value in effect prior to AUTOLEAD #RESTORE_LINE_LENGTH Restores actual line length in RULE +#RESTORE_LN_NUMBER Start linenumbering again with stored + #NEXT_LN? (toggle) #RESTORE_PT_SIZE Stores current point size (in units) prior to underscore #R_INDENT Value of right indent @@ -491,42 +493,65 @@ DOC_COVERTITLE User-defined doc cover title string Document style -------------- -COPYSTYLE Output style (DRAFT or FINAL) -DEFAULTS In START, sets defaults -DOCTYPE Kind of doc (DEFAULT, CHAPTER, NAMED, LETTER) -PAGENUMBER Page number that appears on 1st page of doc -PAPER Paper size (LETTER, LEGAL, A4) -PRINTSTYLE Print style (TYPEWRITE or TYPESET) - -Document tags -------------- -ADD_SPACE Special macro to add space to the top of a pages after - page 1; must be preceded by NEWPAGE -BLOCKQUOTE Block-indented, quoted text -COL_BREAK Breaks and spreads line before invocation; moves to - next column on page or 1st col of next page. An alias - of COL_NEXT. -COL_NEXT Moves to next column on page or 1st col of next page -ENDNOTE Endnote -ENDNOTES Output endnotes -EPIGRAPH Epigraph before 1st para -FINIS Prints --END-- -FOOTNOTE Collects footnotes in text for printing at bottom of page -HEAD Section title (main heads) -ITEM Begin a list item -LINEBREAK Break between narrative sections -LIST Initialize a list -PAD_LIST_DIGITS Leave space for two-numeral digit enumerators in a list -PARAHEAD Paragraph head -PP Paragraph -QUOTE Poetic or line for line quotes -RESET_LIST Reset digit or alpha list enumerator -SHIFT_LIST Move a list over to the right -START Prints info collected with doc info macros -SUBHEAD Subheads +COPYSTYLE Output style (DRAFT or FINAL) +DEFAULTS In START, sets defaults +DOCTYPE Kind of doc (DEFAULT, CHAPTER, NAMED, LETTER) +PAGENUMBER Page number that appears on 1st page of doc +PAPER Paper size (LETTER, LEGAL, A4) +PRINTSTYLE Print style (TYPEWRITE or TYPESET) +NUMBER_LINES Number output lines in the left margin + +Document tags and macros +------------------------ +ADD_SPACE Special macro to add space to the top of a pages after + page 1; must be preceded by NEWPAGE +BIBLIOGRAPHY Begin a bibliography page +BIBLIOGRAPHY_TYPE LIST or PLAIN +BLOCKQUOTE Block-indented, quoted text +COL_BREAK Breaks and spreads line before invocation; moves to + next column on page or 1st col of next page. An alias + of COL_NEXT. +COL_NEXT Moves to next column on page or 1st col of next page +ENDNOTE Endnote +ENDNOTE_REFS Send REFs to endnotes +ENDNOTES Output endnotes +EPIGRAPH Epigraph before 1st para +FINIS Prints --END-- +FOOTNOTE Collects footnotes in text for printing at bottom of page +FOOTNOTE_REFS Send REFs to footnotes +HEAD Section title (main heads) +HYPHENATE_REFS Turn on/off hyphenation of REF references +ITEM Begin a list item +LINEBREAK Break between narrative sections +LIST Initialize a list +MN Margin note +MN_INIT Initialize parameters for margin notes +NUMBER_LINES Number text lines +NUMBER_BLOCKQUOTE_LINES Number blockquote lines +NUMBER_QUOTE_LINES Number quote lines +PAD_LIST_DIGITS Leave space for two-numeral digit enumerators + in a list +PARAHEAD Paragraph head +PP Paragraph +QUOTE Poetic or line for line quotes +REF Wrapper around FOOTNOTE or ENDNOTE, depending + on FOOTNOTE_REFS or ENDNOTE_REFS +REF( Begin embedded reference, parens +REF) End embedded reference, parens +REF[ Begin embedded reference, square brackets +REF] End embedded reference, square brackets +REF{ Begin embedded reference, braces +REF} End embedded reference, braces +REF_INDENT Amount of 2nd line indent of references for + footnote, endnote or bibliography refs +RESET_LIST Reset digit or alpha list enumerator +SHIFT_LIST Move a list over to the right +START Sets doc defaults and prints info collected + with doc info macros +SUBHEAD Subheads Headers/footers --------------- +--------------- BREAK_QUOTE Manually break a footnoted quote that crosses a page/column DO_FOOTER Prints footer (after footnote processing, if any) @@ -580,34 +605,6 @@ DOC_COVER_ADVANCE Vertical place on page to start outputting doc cover material DOC_COVER_LEAD Lead in/decrease for doc cover pages -***Endnotes*** - -ENDNOTE_LEAD Leading for endnotes page -ENDNOTE_PARA_INDENT First line indent of paras in multi-para - endnotes -ENDNOTE_PARA_SPACE Whether to space paras in multi-para endnotes -ENDNOTE_PT_SIZE Base point size for endnotes page -ENDNOTE_STRING Endnotes page head -ENDNOTE_STRING_CAPS Capitalize the endnotes string -ENDNOTE_STRING_UNDERSCORE Underscoring of endnotes page head -ENDNOTE_TITLE Endnotes identifying title -ENDNOTE_TITLE_UNDERSCORE Underscoring of endnotes identifying title -ENDNOTE_NUMBERS_ALIGN_RIGHT Hang endnote numbers and align right -ENDNOTE_NUMBERS_ALIGN_LEFT Don't hang endnote numbers and align left -ENDNOTES_ALLOWS_HEADERS Page headers on endnotes pages? (toggle) -ENDNOTES_FIRST_PAGENUMBER Page number to appear on page 1 of endnotes - pages -ENDNOTES_HDRFTR_CENTER Print header/footer centre string on endnotes - pages? -ENDNOTES_HEADER_CENTER Print header centre string on endnotes pages? -ENDNOTES_FOOTER_CENTER Print footer centre string on endnotes pages? -ENDNOTES_NO_COLUMNS Turn columnar mode off for endnotes pages -ENDNOTES_NO_FIRST_PAGENUM Don't print a pagenumber on page 1 of - endnotes. -ENDNOTES_PAGENUM_STYLE Set numbering style for endnotes pages page - numbers -SINGLESPACE_ENDNOTES Single space TYPEWRITE endnotes - ***Epigraphs and finis*** EPIGRAPH_AUTOLEAD Autolead value for epigraphs @@ -617,16 +614,75 @@ FINIS_STRING What to print when FINIS is invoked ***Footnotes*** -FOOTNOTE_AUTOLEAD Autolead to use in footnotes -FOOTNOTE_MARKERS Turns footnote markers on or off -FOOTNOTE_MARKER_STYLE STAR or NUMBER; default=STAR -FOOTNOTE_RULE_ADJ # of points to raise footnote rule from its - baseline -FOOTNOTE_RULE_LENGTH Length of footnote separator rule -FOOTNOTE_RULE Turns printing of fn separator rule on or off; - default is on -RESET_FOOTNOTE_NUMBER Reset fn# to 1, or, if arg PAGE, reset - automatically to 1 on every page +FOOTNOTE_AUTOLEAD Autolead to use in footnotes +FOOTNOTE_LINENUMBER_BRACKETS Brackets for footnote linenumbers +FOOTNOTE_LINENUMBER_SEPARATOR Separator for footnote linenumbers +FOOTNOTE_MARKERS Turns footnote markers on or off +FOOTNOTE_MARKER_STYLE STAR or NUMBER; default=STAR +FOOTNOTE_RULE_ADJ # of points to raise footnote rule from its + baseline +FOOTNOTE_RULE_LENGTH Length of footnote separator rule +FOOTNOTE_RULE Turns printing of fn separator rule on or off; + default is on +FOOTNOTE_SPACING Post footnote item spacing +FOOTNOTES_RUN_ON Run footnotes on (line numbering mode only) +RESET_FOOTNOTE_NUMBER Reset fn# to 1, or, if arg PAGE, reset + automatically to 1 on every page +RUNON_WARNING Utility macro; warns if FOOTNOTES_RUN_ON + was called when fn marker style is STAR or NUMBER + +***Endnotes*** + +ENDNOTE_LEAD Leading for endnotes page +ENDNOTE_LINENUMBER_BRACKETS Brackets around line numbers identifying + endnotes and text +ENDNOTE_LINENUMBER_GAP Amount of space to leave between line +ENDNOTE_LINENUMBER_SEPARATOR Separator between line numbers identifying + endnotes and the endnote item text + endnotes and text +ENDNOTE_MARKER_STYLE NUMBER or LINE +ENDNOTE_NUMBERS_ALIGN_RIGHT Hang endnote numbers and align right +ENDNOTE_NUMBERS_ALIGN_LEFT Don't hang endnote numbers and align left +ENDNOTE_PARA_INDENT First line indent of paras in multi-para + endnotes +ENDNOTE_PARA_SPACE Whether to space paras in multi-para endnotes +ENDNOTE_PT_SIZE Base point size for endnotes page +ENDNOTE_STRING Endnotes page head +ENDNOTE_STRING_CAPS Capitalize the endnotes string +ENDNOTE_STRING_UNDERSCORE Underscoring of endnotes page head +ENDNOTE_TITLE Endnotes identifying title +ENDNOTE_TITLE_SPACE Distance from top of page to endnotest title +ENDNOTE_TITLE_UNDERSCORE Underscoring of endnotes identifying title +ENDNOTES_ALLOWS_HEADERS Page headers on endnotes pages? (toggle) +ENDNOTES_FIRST_PAGENUMBER Page number to appear on page 1 of endnotes + pages +ENDNOTES_HDRFTR_CENTER Print header/footer centre string on endnotes + pages? +ENDNOTES_HEADER_CENTER Print header centre string on endnotes pages? +ENDNOTES_FOOTER_CENTER Print footer centre string on endnotes pages? +ENDNOTES_NO_COLUMNS Turn columnar mode off for endnotes pages +ENDNOTES_NO_FIRST_PAGENUM Don't print a pagenumber on page 1 of + endnotes. +ENDNOTES_PAGENUM_STYLE Set numbering style for endnotes pages page + numbers +SINGLESPACE_ENDNOTES Single space TYPEWRITE endnotes + +***Bibliographies*** + +BIBLIOGRAPHY_ALLOWS_HEADERS Allow headers on bib pages +BIBLIOGRAPHY_FIRST_PAGENUMBER Starting page number for bibliographies +BIBLIOGRAPHY_HDRFTR_CENTER Header/footer center string for bib pages +BIBLIOGRAPHY_LEAD Base lead of bib pages +BIBLIOGRAPHY_NO_COLUMNS De-columnize bibliographies +BIBLIOGRAPHY_NO_FIRST_PAGENUM Don't print a page number on the first + page of bibliographies +BIBLIOGRAPHY_PAGENUM_STYLE Format for bib pages page numbering +BIBLIOGRAPHY_PT_SIZE Base point size for bib pages +BIBLIOGRAPHY_SPACING Post bib entry space +BIBLIOGRAPHY_STRING String for bib title +BIBLIOGRAPHY_STRING_CAPS Capitalize bib title string +BIBLIOGRAPHY_STRING_UNDERSCORE Underscore bib title string +SINGLESPACE_BIBLIOGRAPHY Singlespace bibs if PRINTSTYLE TYPEWRITE ***Headers and footers*** @@ -705,6 +761,12 @@ PARA_INDENT Size of para indent PARA_SPACE Put a line space before paras PP_FONT Overall doc font +***Quotes*** + +Q_FITS Utility macro for DO_QUOTE +Q_NOFIT Utility macro for DO_QUOTE +QUOTE_AUTOLEAD Leading of (block)quotes + ***Line/section breaks*** LINEBREAK_CHAR Linebreak character, iterations and positioning @@ -825,7 +887,11 @@ DO_EPIGRAPH Outputs epigraphs with space adjustments before and after FN_OVERFLOW_TRAP Fixed at B_MARGIN; if footnotes run longer than B_MARGIN, diverts excess into FN_OVERFLOW +GET_ROMAN_INDENT Figures out amount of space to reserve + for roman numerals in lists HDRFTR_RULE Prints rule under header or over footer +MN_OVERFLOW_TRAP Trap-invoked macro to collect margin note + overflows PRINT_FOOTNOTE_RULE An alias of PRINT_FOOTNOTE; prints footnote separator rule PRINT_HDRFTR Prints header/footer (trap invoked) @@ -837,6 +903,9 @@ PROCESS_SHIM Calculates #SHIM when \n(.d is lower on the PROCESS_FN_IN_DIVER Processes footnotes gathered in a diversion (called at page/column breaks) REMOVE_INDENT Removes indents set with CHECK_INDENT +Q_FITS Handles spacing of quotes when quote fits on the page +Q_NOFIT Handles spacing of quotes when quote does not fit on + the page QUIT_LISTS Exit lists cleanly and completely SET_LIST_INDENT Restore indent of a prev. level of list SHIM Advance to next "legal" baseline @@ -855,18 +924,21 @@ VFP_CHECK Trap-sprung macro 1 legal baseline higher than +++DIVERSIONS+++ -B_QUOTE Block (indented) quote text -CLOSING Closing (i.e. Yours truly,) -EPI_TEXT Epigraph text -END_NOTES Endnotes text -FN_IN_DIVER Footnotes gathered from inside a diversion -FN_OVERFLOW Excess footnotes when B_MARGIN is reached -FOOTNOTES Text of footnotes -GREETING Full salutation (e.g. Dear John Smith,) -LETTERHEAD<n> Date, addresser, addressee or greeting; - <n> is from 1 to 4, supplied by #FIELD -P_QUOTE Line for line (poetic) quote text -TOC_ENTRIES TOC entries +B_QUOTE Block (indented) quote text +CLOSING Closing (i.e. Yours truly,) +EPI_TEXT Epigraph text +END_NOTES Endnotes text +FN_IN_DIVER Footnotes gathered from inside a diversion +FN_OVERFLOW Excess footnotes when B_MARGIN is reached +FOOTNOTES Text of footnotes +GREETING Full salutation (e.g. Dear John Smith,) +LETTERHEAD<n> Date, addresser, addressee or greeting; + <n> is from 1 to 4, supplied by #FIELD +P_QUOTE Line for line (poetic) quote text +RUNON_FOOTNOTES Special diversion for run-on footnotes +RUNON_FN_IN_DIVER Special diversion for run-on footnotes inside + (block)quotes +TOC_ENTRIES TOC entries +++NUMBER REGISTERS+++ @@ -874,10 +946,15 @@ TOC_ENTRIES TOC entries doesn't fall below what should be the correct last printed line of running text +#ADD_BREAK Instructs FOOTNOTEs and ENDNOTEs to add + a break afer processing a footnote if + we're not in fill mode +#ADJ_BIB_LEAD Adjust BIB_LEAD? (toggle) #ADJ_DOC_LEAD Adjust DOC_LEAD? (toggle) #ADJ_TOC_LEAD Adjust TOC_LEAD? (toggle) #ARG_NUM Keeps track of number of args passed to a macro +#ARGS_TO_LIST Was LIST passed some args? (toggle) #AUTHOR_[n] Strings passed to AUTHOR #AUTHOR_LINES # of lines of authors in doc header; odd=0 even=1 @@ -892,7 +969,29 @@ TOC_ENTRIES TOC entries #BMARG Position of unvarying bottom margin during doc processing; required for collecting footnotes inside diversions +#BIB_ALLOWS_HEADERS Put headers on bib pages? (toggle) +#BIB_ALLOWS_HEADERS_ALL Put headers on all bib pages? (toggle) +#BIB_FIRST_PAGE Tells PRINT_PAGE_NUMBER about bibliography + first page number +#BIB_FIRST_PN Starting pagenumber for bibliographies +#BIB_HDRFTR_CENTER Put a center string in bib page headers? + (toggle) +#BIB_LEAD Bibliography lead, expressed in points +#BIB_LIST Output bibs in list style? (toggle) +#BIB_NO_COLS De-columnize bibliographies? (toggle) +#BIB_NO_FIRST_PN Put a page number on the first page of + bibliographies? (toggle) +#BIB_SINGLESPACE Single-space TYPEWRITE bibliographies? (toggle) +#BIB_SPACE Post item space for bibliography pages +#BIB_STRING_CAPS Capitalize bib title? (toggle) +#BIB_STRING_UNDERSCORE Underscore bib title? 0=no; 1=yes; 2=double +#BIB_PS Base point size for bibliography pages expressed + in points +#BIBLIOGRAPHY Are we doing a bib page? (toggle) +#BQ_AUTOLEAD Register created by BLOCKQUOTE_AUTOLEAD +#BQ_LEAD Leading of blockquotes #BQUOTE_COLOR Colored blockquotes? (toggle) +#BQUOTE_LN Number blockquotes? (toggle) #BROKEN_QUOTE Did we invoke BREAK_QUOTE? (toggle) #CAP_HEIGHT_ADJUST Tallest cap height of strings LEFT, CENTER, and RIGHT in footers; used to place rule @@ -936,8 +1035,12 @@ dc "mark" register for document columns #DIVER_FN Register that tells FOOTNOTE whether to "move" or "defer" a footnote collected inside a diversion +#DEFER_BIB_SPACING Tells DEFAULTS to do BIBLIOGRAPHY_SPACING + if it was called before START #DEFER_PAGINATION Tells COLLATE to restore pagination (from RESTORE_PAGINATION +#DELAY_SHIM Instructs DO_QUOTE to delay SHIM when quote + falls at the top of a page #DEPTH_1 Doc header depth with lead adjustment (#DOCHEADER_LINES * #DOCHEADER_LEAD) #DEPTH_2 Doc header depth without lead adjustment @@ -987,17 +1090,31 @@ dc "mark" register for document columns #DONE_ONCE Keeps track of how many times footnotes have been collected inside the same diversion #DONT_RULE_ME Rule this (apparent) first footnote? (toggle) +#DIVER_LN_OFF Turn linenumbering off in (block)quotes? + (toggle) #DRAFT_WITH_PAGENUM Are we attaching draft/revision info to page number? (toggle) #EM_ADJUST Amount to raise \(em at END #EN_ALLOWS_HEADERS Put page headers on endnotes pages? (toggle) #EN_ALLOWS_HEADERS_ALL Put page headers on all endnotes pages? (toggle) +#EN_BQ_AUTOLEAD Register created by EN_BLOCKQUOTE_AUTOLEAD +#EN_BQ_LEAD Leading of blockquotes on endnotes pages +#EN_FIGURE_SPACE Width of \0, for use with formatting endnotes #EN_FIRST_PAGE Tells PRINT_PAGE_NUMBER about endnotes first page number #EN_FIRST_PN Page number that appears on page 1 of endnotes pages. +#EN_HDRFTR_CENTER Should we print centre string of + headers/footers on endnotes pages? (toggle) #EN_LEAD Lead of endnotes +#EN_LN_BRACKETS Are we using brackets for line-numbered + endnotes (toggle) +#EN_LN_SEP Are we using a separator for line-numbered + endnotes (toggle) +#EN_MARK \n(ln when \*[EN-MARK] is called +#EN_MARK_2 \n(ln when ENDNOTE is called +#EN_MARKER_STYLE 1=NUMBER; 2=LINE #EN_NO_COLS Do not set endnotes in columns? (toggle) #EN_NO_FIRST_PN Put pagenumber on 1st page of endnotes? (toggle) @@ -1013,6 +1130,9 @@ dc "mark" register for document columns endnotes #EN_PP_SPACE Space multi-paras in endnotes? (toggle) #EN_PS ps of endnotes +#EN_Q_AUTOLEAD Register created by EN_QUOTE_AUTOLEAD +#EN_Q_LEAD Leading of quotes on endnotes pages +#EN_REF Put REFs in endnotes? (toggle) #EN_SINGLESPACE Single space endnotes pages? (toggle) #EN_STRING_CAPS Should ENDNOTES capitalize the endnotes string? (toggle) @@ -1024,9 +1144,8 @@ dc "mark" register for document columns #END_QUOTE For PP=0 indenting; did we just end a quote? (toggle) #ENDNOTE Are we in an endnote? (toggle) +#ENDNOTE_REFS Are REFs going to endnotes? (toggle) #ENDNOTES Are we in an endnote (for FOOTERs; toggle) -#EN_HDRFTR_CENTER Should we print centre string of - headers/footers on endnotes pages? (toggle) #EPI_ACTIVE Are we in an epigraph? (toggle) #EPI_COLOR Colored epigraphs? (toggle) #EPI_DEPTH Depth of epigraph from first baseline to @@ -1078,6 +1197,12 @@ dc "mark" register for document columns #FN_L_INDENT Left indent of INDENT LEFT in footnotes #FN_LINES Number of lines in fn; used to calculate fn depth +#FN_LN_BRACKETS Are footnote linenumber brackets being used? + (toggle) +#FN_LN_SEP Is a footnote linenumber separator being used? + (toggle) +#FN_MARK \n(ln when \*[FN-MARK] is called +#FN_MARK_2 \n(nl when FOOTNOTE is called #FN_MARKERS Print footnote markers? (toggle) #FN_MARKER_STYLE 1=STAR; 2=NUMBER #FN_NUMBER The footnote number attached to running text @@ -1087,10 +1212,12 @@ dc "mark" register for document columns #FN_OVERFLOW_TRAP_POS The register that sets the position of trap FN_OVERFLOW_TRAP. #FN_R_INDENT Right indent of INDENT RIGHT in footnotes +#FN_REF Put REFs in footnotes? (toggle) #FN_RULE_ADJ # of points to raise footnote separator from its baseline #FN_RULE_LENGTH Length of footnote separator rule #FN_RULE Print fn rule? (toggle) +#FN_SPACE Post footnote space #FN_WAS_DEFERED Tells HEADER about a deferred footnote #FOOTER_DIFF In TRAPS, the difference between the original #B_MARGIN and #VISUAL_B_MARGIN @@ -1155,25 +1282,32 @@ dc "mark" register for document columns #HOW_MANY Number of blank pages to output #IGNORE Should we ignore this macro? Set to 1 in TYPEWRITE. +#IN_BIB_LIST Tells ITEM we're doing a bibliography in + list style #INDENT_FIRST_PARAS Indent first paras? (toggle) #INDENT_FIRSTS Tells footnotes to leave INDENT_FIRST_PARAS alone if it's on for running text. #ITALIC_MEANS_ITALIC For TYPEWRITE. 1=yes; 0=no +#L_LENGTH_FOR_EPI Stores line length at top of doc for use + with EPIGRAPH when columns are on +#L_MARGIN_DIFF Difference between DOC_L_MARGIN and + L_MARGIN #LEFT_CAP_HEIGHT Cap height of left string in headers/footers -#LEGAL_BASELINE Calculates vet. position of next legal +#LEGAL_BASELINE Calculates vert. position of next legal baseline in SHIM #LETTER_STYLE 1=BUSINESS 2=PERSONAL #LINEBREAK Did we have a linebreak? (toggle) #LINEBREAK_COLOR Colored linebreak? (toggle) +#LINENUMBERS Holds various states of line-numbering when + line numbering is enabled #LINES_PER_PAGE # of lines (at DOC_LEAD) that fit on page after #B_MARGIN is set -#L_LENGTH_FOR_EPI Stores line length at top of doc for use - with EPIGRAPH when columns are on -#L_MARGIN_DIFF Difference between DOC_L_MARGIN and - L_MARGIN +#LN Are line numbers on? (toggle) #MISC_<n> Used to print "next" misc lines in DO_COVER #MISC_NUM Number of MISC lines #MISCS =#MISC_NUM in DO_COVER +#MN_OVERFLOW_LEFT If 1, left margin note text overflows +#MN_OVERFLOW_RIGHT If 1, right margin note text overflows #n%_AT_PAGENUM_SET Page # from n% when PAGENUMBER invoked #NEEDS_SPACE Instruct FOOTNOTE, when called by PROCESS_FN_IN_DIVER, that if the footnote @@ -1181,6 +1315,8 @@ dc "mark" register for document columns raised by 1v (set in DIVER_FN_2_PRE) #NEXT_AUTHOR Supplies correct digit to AUTHOR_<#> when printing authors in doc header +#NEXT_LN Next linenumber when \n(ln has to be stored + because linenumbering suspended #NEXT_MISC Incrementing counter for misc lines in DO_COVER #NO_BACK_UP Instructs FN_OVERFLOW_TRAP not to @@ -1249,20 +1385,34 @@ dc "mark" register for document columns #PRINT_STYLE Typewrite=1, typeset=2 #PT_SIZE_IN_UNITS Stored value of \n[.ps] from last time PT_SIZE was called +#Q_AUTOLEAD Register created by QUOTE_AUTOLEAD #Q_DEPTH Depth of quote #Q_FITS Does this quote fit on one page/column? (toggle) +#Q_LEAD Leading of quotes +#Q_LEAD_DIFF Difference between leading of running text + and the leading used in quotes/blockquotes +#Q_LEAD_REAL Leading of quotes and blockquotes saved at the + ends of their respective diversions #Q_L_LENGTH Line length of quotes #Q_OFFSET Page offset for quotes #Q_OFFSET_VALUE Factor by which to multiply PP_INDENT to offset quotes +#Q_PARTIAL_DEPTH The amount of a quote/blockquote that fits at + the bottom of a page when a quote/blockquote + spans pages #Q_PP In PP, stores para # in QUOTE. Removed in ENDQUOTE. +#Q_SPACE_ADJ The flexible amount of whitespace to add before + and after a quote/blockquote #Q_TOP Vertical place on page that a quote starts #QUOTE 1=PQUOTE, 2=BQUOTE #QUOTE_COLOR Color quotes (poetic)? (toggle) +#QUOTE_LN Linenumber quotes? (toggle) #RECTO_VERSO Switch HEADER_LEFT and HEADER_RIGHT on alternate pages? (toggle); default=0 +#REF_HYPHENATE Hyphenate REFs? (toggle) +#REF_WARNING Have we issued a ref warning? (toggle) #REPEAT Number of times to repeat linebreak character #RESERVED_SPACE Just enough room to put 1 more line of @@ -1280,6 +1430,7 @@ dc "mark" register for document columns #FULLSPACE_QUOTES (used in endnotes) #RESTORE_DOC_LEAD Holds value of current doc lead (used in endnotes) +#RESTORE_HY Restore hyphenation after .][? (toggle) #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 @@ -1288,6 +1439,11 @@ dc "mark" register for document columns headers/footers #RULED Tells FOOTNOTE if a rule (or space has been put above the first footnote on the page +#RUNON_FN_IN_DIVER If #LN=1, if we're in a (block)quote, instructs + FOOTNOTE to unformat diversion RUNON_FN_IN_DIVER +#RUNON_FOOTNOTES If #LN=1, instructs FOOTNOTE to unformat + diversion RUNON_FOOTNOTES +#RUN_ON Are we using run-on footnotes? (toggle) #SAVED_DIVER_FN_COUNT In the case of a footnote inside a diversion that should be treated as a "normal" footnote, FOOTNOTE needs to @@ -1311,6 +1467,7 @@ dc "mark" register for document columns #SAVED_FN_DEPTH_2 Footnote depth after to adding footnote diversion depth to FN_DEPTH; used when footnote text will overflow +#SAVED_FOOTER_POS Position of FOOTER in DO_QUOTE (hack) #SAVED_LEAD In FOOTER and DO_FOOTER, stores the lead in effect prior to outputting FOOTNOTES or performing either @@ -1322,11 +1479,14 @@ dc "mark" register for document columns performed with the #SAVED_LEAD in order to remove register #AUTO_LEAD or #AUTO_LEAD_FACTOR. +#SEP_TYPE Set to 1 if LIST separator is ( or [ or { #SH_LEAD_ADJUST #DOC_LEAD/8 (TYPESET) or /2 (TYPEWRITE) (used for subhead spacing) #SH_NUM Subhead number #SHIM Amount of lead required to advance to next legal baseline +#SILENT_BQUOTE_LN "Silently" linenumber blockquotes? (toggle) +#SILENT_QUOTE_LN "Silently" linenumber quotes? (toggle) #SINGLE_SPACE Is TYPEWRITE in single space mode? (toggle) #SKIP_FOOTER If 1, instructs DO_FOOTER to do nothing if B_MARGIN falls below FOOTER_MARGIN @@ -1345,6 +1505,7 @@ dc "mark" register for document columns PRINT_HDRFTR that START has been invoked, allowing PRINT_HDRFTR to decide whether or not to print a footer on page 1 +#START_FOR_MNinit If 1, defer processing MN_INIT until #START #STORED_PP_INDENT Temporarily holds value of #PP_INDENT #SUITE Current page number (for letters) #SUP_PT_SIZE Point size of superscript @@ -1408,12 +1569,31 @@ y Vertical position stored with mk in hdrftrs. +++STRINGS+++ +$1ST_LETTER First letter of first arg to LIST +$ADJUST_BIB_LEAD 2nd arg to BIBLIOGRAPHY_LEAD; if not blank + adjust bib leading $ATTRIBUTE_STRING "by" line in doc header $AUTHOR_1...9 Document author(s) $AUTHOR_FAM Family to use for author in doc header $AUTHOR_FT Font to use for author in doc header $AUTHOR_SIZE_CHANGE ps in/decrease of author in doc header* $AUTHOR_PT_SIZE Absolute ps of authors +$BIB_FAM Bibliography page family +$BIB_FT Bibliography page font +$BIB_LEAD Base leading for bibliographies +$BIB_LIST_SEPARATOR Separator between enumerator and text + when outputting bibliographies in LIST style +$BIB_LIST_PREFIX Prefix before enumerator when outputting + bibliographies in LIST style +$BIB_PN_STYLE Format of bibliography page numbers +$BIB_SPACE Post entry space for bibliographies +$BIB_STRING Bibliography title string +$BIB_STRING_FAM Bib title family +$BIB_STRING_FT Bib title font +$BIB_STRING_QUAD Bib title quad +$BIB_STRING_SIZE_CHANGE Bib title size (+ or -) +$BQ_LN_GUTTER Gutter between line numbers and bquotes in + bquotes $BQUOTE_COLOR Blockquote color $BQUOTE_FAM Family to use for blockquotes $BQUOTE_FT Font to use for blockquotes @@ -1464,6 +1644,7 @@ $COVER_MISC_FAM Cover misc family $COVER_MISC_FT Cover misc font $COVER_MISC_SIZE_CHANGE Cover misc size* $COVER_MISC_COLOR Cover misc color +$CURRENT_EV \n[.ev] at REF_BRACKETS_START $DOC_COVER_FAM Overall doc cover family $DOC_COVER_COLOR Overall doc cover color $DOC_COVER_TITLE User-defined doc cover title string @@ -1516,8 +1697,23 @@ $DOCTYPE_PT_SIZE Absolute ps of DOCTYPE $DRAFT The draft number (string valued) $DRAFT_STRING What to print whenever the word "draft" is required +EN_MARK Inline, gets #EN_MARK (\(ln) +$EN_CLOSE_BRACKET Close bracket for line-number enumerated + endnotes $EN_FAMILY Family for endnotes $EN_FT Font for endnotes +$EN_LINENUMBER String to print for line-number enumerators + in line-numbered endnotes +$EN_LN_FAM Family for line-numbers in line-number + identified endnotes +$EN_LN_FT Font for line-numbers in line-number + identified endnotes +$EN_LN_GAP Gap to leave in initial endnote lines + between line-number identifies and text +$EN_OPEN_BRACKET Open bracket for line-number enumerated + endnotes +$EN_LN_SIZE_CHANGE Size change (+ or -) for line-numbers in + line-number identified endnotes $EN_PN_STYLE Pagenumbering style for endnotes pages $EN_QUAD Quad for endnotes $EN_STRING Endnotes page head @@ -1542,12 +1738,23 @@ $EPI_FT Font to use in epigraphs $EPI_QUAD Quad in block-style epigraphs (justified or left) $EPI_SIZE_CHANGE ps in/decrease of epigraphs* +$EVAL_BIB_SPACE Temporary string to find out if the + arg to BIBLIOGRAPHY_SPACING ended in "v" $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 $FN_FAM Family used in footnotes $FN_FT Font used in footnotes +$FN_LINENUMBER String to print before footnotes when + line-numbering enabled for footnotes +$FN_LN_SEP Separator after line-number identified + footnotes +$FN_OPEN_BRACKET Open bracket for line-number identified + footnotes $FN_QUAD Quad used in footnotes $FN_SIZE_CHANGE ps in/decrease of footnotes* $FOOTNOTE_COLOR Footnote color @@ -1592,7 +1799,16 @@ $HEAD_SIZE_CHANGE ps in/decrease of section titles* $LINEBREAK_CHAR Character that marks line breaks $LINEBREAK_CHAR_V_ADJ +|- amount by which to raise/lower linebreak character +$LAST_CHAR Temporary string used to discover whether + user has remembered to put a digit after + ROMAN or roman in arg to LIST $LINEBREAK_COLOR Linebreak color +$LIST_ARG_1 The first arg to LIST (minus digits if + ROMAN or roman +$LN_GUTTER Gutter to leave between line numbers + and text +$LN_INC 2nd arg to NUMBER_LINES as a string +$LN_NUM 1st arg to NUMBER_LINES as a string $MISC_COLOR Misc line color $MISC_QUAD Misc line quad PAGE# For use in hdrftr strings where page # @@ -1606,10 +1822,21 @@ $PAPER Paper size (LETTER, A4, LEGAL); default=LETTER $PH_COLOR Parahead color $PP_FT Font used in paragraphs +$ROMAN_WIDTH The digit(s) appended to ROMAN or + roman LIST args +$Q_LN_GUTTER Gutter between linenumbers and quotes + in quotes $QUOTE_COLOR Quote (poetic) color $QUOTE_FAM Family to use for pquotes $QUOTE_FT Font to use for pquotes $QUOTE_SIZE_CHANGE ps in/decrease of pquotes* +$REF_BIB_INDENT 2nd line indent value for references in + bibliographies +$REF_EN_INDENT 2nd line indent value for references in + endnotes +$REF_FN_INDENT 2nd line indent value for references in + footnotes +$RESTORE_SS_VAR Saves \*[$SS_VAR] for use with ref*build #REVISION The revision number (string valued) $REVISION_STRING What to print whenever the word "revision" is required @@ -1774,168 +2001,195 @@ TOC_PS TOC_PT_SIZE +++The following are used for docelement type-style control+++ -AUTHOR_FAMILY _FAMILY -AUTHOR_FONT _FONT -AUTHOR_SIZE _SIZE -BLOCKQUOTE_COLOR _COLOR -BLOCKQUOTE_FAMILY _FAMILY -BLOCKQUOTE_FONT _FONT -BLOCKQUOTE_QUAD _QUAD -BLOCKQUOTE_SIZE _SIZE -CHAPTER_TITLE_COLOR _COLOR -CHAPTER_TITLE_FAMILY _FAMILY -CHAPTER_TITLE_FONT _FONT -CHAPTER_TITLE_SIZE _SIZE -COVER_COPYRIGHT_COLOR _COLOR -COVER_COPYRIGHT_FAMILY _FAMILY -COVER_COPYRIGHT_FONT _FONT -COVER_COPYRIGHT_QUAD _QUAD -COVER_COPYRIGHT_SIZE _SIZE -COVER_ATTRIBUTE_COLOR _COLOR -COVER_AUTHOR_COLOR _COLOR -COVER_AUTHOR_FAMILY _FAMILY -COVER_AUTHOR_FONT _FONT -COVER_AUTHOR_SIZE _SIZE -COVER_COLOR _COLOR -COVER_DOCTYPE_COLOR _COLOR -COVER_DOCTYPE_FAMILY _FAMILY -COVER_DOCTYPE_FONT _FONT -COVER_DOCTYPE_SIZE _SIZE -COVER_FAMILY _FAMILY -COVER_MISC_COLOR _COLOR -COVER_MISC_QUAD _QUAD -COVER_SUBTITLE_COLOR _COLOR -COVER_SUBTITLE_FAMILY _FAMILY -COVER_SUBTITLE_FONT _FONT -COVER_SUBTITLE_SIZE _SIZE -COVER_TITLE_COLOR _COLOR -COVER_TITLE_FAMILY _FAMILY -COVER_TITLE_FONT _FONT -COVER_TITLE_SIZE _SIZE -DOC_COVER_COPYRIGHT_COLOR _COLOR -DOC_COVER_COPYRIGHT_FAMILY _FAMILY -DOC_COVER_COPYRIGHT_FONT _FONT -DOC_COVER_COPYRIGHT_QUAD _QUAD -DOC_COVER_COPYRIGHT_SIZE _SIZE -DOC_COVER_ATTRIBUTE_COLOR _COLOR -DOC_COVER_AUTHOR_COLOR _COLOR -DOC_COVER_AUTHOR_FAMILY _FAMILY -DOC_COVER_AUTHOR_FONT _FONT -DOC_COVER_AUTHOR_SIZE _SIZE -DOC_COVER_COLOR _COLOR -DOC_COVER_DOCTYPE_COLOR _COLOR -DOC_COVER_DOCTYPE_FAMILY _FAMILY -DOC_COVER_DOCTYPE_FONT _FONT -DOC_COVER_DOCTYPE_SIZE _SIZE -DOC_COVER_FAMILY _FAMILY -DOC_COVER_MISC_COLOR _COLOR -DOC_COVER_MISC_QUAD _QUAD -DOC_COVER_SUBTITLE_COLOR _COLOR -DOC_COVER_SUBTITLE_FAMILY _FAMILY -DOC_COVER_SUBTITLE_FONT _FONT -DOC_COVER_SUBTITLE_SIZE _SIZE -DOC_COVER_TITLE_COLOR _COLOR -DOC_COVER_TITLE_FAMILY _FAMILY -DOC_COVER_TITLE_FONT _FONT -DOC_COVER_TITLE_SIZE _SIZE -DOC_QUAD _QUAD -DOCHEADER_COLOR _COLOR -DOCHEADER_FAMILY _FAMILY -DOCTYPE_FAMILY _FAMILY -DOCTYPE_FONT _FONT -DOCTYPE_SIZE _SIZE -ENDNOTE_FAMILY _FAMILY -ENDNOTE_FONT _FONT -ENDNOTE_NUMBER_FAMILY _FAMILY -ENDNOTE_NUMBER_FONT _FONT -ENDNOTE_NUMBER_SIZE _SIZE -ENDNOTE_QUAD _QUAD -ENDNOTE_STRING_FAMILY _FAMILY -ENDNOTE_STRING_FONT _FONT -ENDNOTE_STRING_QUAD _QUAD -ENDNOTE_STRING_SIZE _SIZE -ENDNOTE_TITLE_FAMILY _FAMILY -ENDNOTE_TITLE_FONT _FONT -ENDNOTE_TITLE_QUAD _QUAD -ENDNOTE_TITLE_SIZE _SIZE -EPIGRAPH_COLOR _COLOR -EPIGRAPH_FAMILY _FAMILY -EPIGRAPH_FONT _FONT -EPIGRAPH_QUAD _QUAD -EPIGRAPH_SIZE _SIZE -FINIS_COLOR _COLOR -FOOTNOTE_COLOR _COLOR -FOOTNOTE_FAMILY _FAMILY -FOOTNOTE_FONT _FONT -FOOTNOTE_QUAD _QUAD -FOOTNOTE_SIZE _SIZE -HDRFTR_CENTER_FAMILY _FAMILY -HDRFTR_CENTER_FONT _FONT -HDRFTR_CENTER_SIZE _SIZE -HDRFTR_COLOR _COLOR -HDRFTR_FAMILY _FAMILY -HDRFTR_LEFT_FAMILY _FAMILY -HDRFTR_LEFT_FONT _FONT -HDRFTR_LEFT_SIZE _SIZE -HDRFTR_RIGHT_FAMILY _FAMILY -HDRFTR_RIGHT_FONT _FONT -HDRFTR_RIGHT_SIZE _SIZE -HDRFTR_RULE_COLOR _COLOR -HDRFTR_SIZE _SIZE -HEAD_COLOR _COLOR -HEAD_FAMILY _FAMILY -HEAD_FONT _FONT -HEAD_QUAD _QUAD -HEAD_SIZE _SIZE -LINEBREAK_COLOR _COLOR -MISC_COLOR _COLOR -MISC_QUAD _QUAD -PAGENUM_COLOR _COLOR -PAGENUM_FAMILY _FAMILY -PAGENUM_FONT _FONT -PARAHEAD_COLOR _COLOR -PARAHEAD_FAMILY _FAMILY -PARAHEAD_FONT _FONT -PARAHEAD_SIZE _SIZE -QUOTE_COLOR _COLOR -QUOTE_FAMILY _FAMILY -QUOTE_FONT _FONT -QUOTE_INDENT _INDENT -QUOTE_SIZE _SIZE -SUBHEAD_COLOR _COLOR -SUBHEAD_FAMILY _FAMILY -SUBHEAD_FONT _FONT -SUBHEAD_SIZE _SIZE -SUBTITLE_COLOR _COLOR -SUBTITLE_FAMILY _FAMILY -SUBTITLE_FONT _FONT -SUBTITLE_SIZE _SIZE -TITLE_COLOR _COLOR -TITLE_FAMILY _FAMILY -TITLE_FONT _FONT -TITLE_SIZE _SIZE -TOC_FAM _FAMILY -TOC_FAMILY _FAMILY -TOC_HEADER_FAMILY _FAMILY -TOC_HEADER_FONT _FONT -TOC_HEADER_QUAD _QUAD -TOC_HEADER_SIZE _SIZE -TOC_HEAD_FAMILY _FAMILY -TOC_HEAD_FONT _FONT -TOC_HEAD_SIZE _SIZE -TOC_PARAHEAD_FAMILY _FAMILY -TOC_PARAHEAD_FONT _FONT -TOC_PARAHEAD_SIZE _SIZE -TOC_PN_FAMILY _FAMILY -TOC_PN_FONT _FONT -TOC_PN_SIZE _SIZE -TOC_PT_SIZE _SIZE -TOC_SUBHEAD_FAMILY _FAMILY -TOC_SUBHEAD_FONT _FONT -TOC_SUBHEAD_SIZE _SIZE -TOC_TITLE_FAMILY _FAMILY -TOC_TITLE_FONT _FONT -TOC_TITLE_SIZE _SIZE +AUTHOR_FAMILY _FAMILY +AUTHOR_FONT _FONT +AUTHOR_SIZE _SIZE +BIBLIOGRAPHY_FAMILY _FAMILY +BIBLIOGRAPHY_FONT _FONT +BIBLIOGRAPHY_FOOTER_CENTER BIBLIOGRAPHY_HDRFTR_CENTER +BIBLIOGRAPHY_FOOTER_CENTRE BIBLIOGRAPHY_HDRFTR_CENTRE +BIBLIOGRAPHY_HEADER_CENTER BIBLIOGRAPHY_HDRFTR_CENTER +BIBLIOGRAPHY_HEADER_CENTRE BIBLIOGRAPHY_HDRFTR_CENTRE +BIBLIOGRAPHY_QUAD _QUAD +BIBLIOGRAPHY_STRING_FAMILY _FAMILY +BIBLIOGRAPHY_STRING_FONT _FONT +BIBLIOGRAPHY_STRING_QUAD _QUAD +BIBLIOGRAPHY_STRING_SIZE _SIZE +BLOCKQUOTE_AUTOLEAD Q_AUTOLEAD +BLOCKQUOTE_AUTOLEAD QUOTE_AUTOLEAD +BLOCKQUOTE_COLOR _COLOR +BLOCKQUOTE_FAMILY _FAMILY +BLOCKQUOTE_FONT _FONT +BLOCKQUOTE_QUAD _QUAD +BLOCKQUOTE_SIZE _SIZE +CHAPTER_TITLE_COLOR _COLOR +CHAPTER_TITLE_FAMILY _FAMILY +CHAPTER_TITLE_FONT _FONT +CHAPTER_TITLE_SIZE _SIZE +COVER_ATTRIBUTE_COLOR _COLOR +COVER_AUTHOR_COLOR _COLOR +COVER_AUTHOR_FAMILY _FAMILY +COVER_AUTHOR_FONT _FONT +COVER_AUTHOR_SIZE _SIZE +COVER_COLOR _COLOR +COVER_COPYRIGHT_COLOR _COLOR +COVER_COPYRIGHT_FAMILY _FAMILY +COVER_COPYRIGHT_FONT _FONT +COVER_COPYRIGHT_QUAD _QUAD +COVER_COPYRIGHT_SIZE _SIZE +COVER_DOCTYPE_COLOR _COLOR +COVER_DOCTYPE_FAMILY _FAMILY +COVER_DOCTYPE_FONT _FONT +COVER_DOCTYPE_SIZE _SIZE +COVER_FAMILY _FAMILY +COVER_MISC_COLOR _COLOR +COVER_MISC_QUAD _QUAD +COVER_SUBTITLE_COLOR _COLOR +COVER_SUBTITLE_FAMILY _FAMILY +COVER_SUBTITLE_FONT _FONT +COVER_SUBTITLE_SIZE _SIZE +COVER_TITLE_COLOR _COLOR +COVER_TITLE_FAMILY _FAMILY +COVER_TITLE_FONT _FONT +COVER_TITLE_SIZE _SIZE +DOC_COVER_ATTRIBUTE_COLOR _COLOR +DOC_COVER_AUTHOR_COLOR _COLOR +DOC_COVER_AUTHOR_FAMILY _FAMILY +DOC_COVER_AUTHOR_FONT _FONT +DOC_COVER_AUTHOR_SIZE _SIZE +DOC_COVER_COLOR _COLOR +DOC_COVER_COPYRIGHT_COLOR _COLOR +DOC_COVER_COPYRIGHT_FAMILY _FAMILY +DOC_COVER_COPYRIGHT_FONT _FONT +DOC_COVER_COPYRIGHT_QUAD _QUAD +DOC_COVER_COPYRIGHT_SIZE _SIZE +DOC_COVER_DOCTYPE_COLOR _COLOR +DOC_COVER_DOCTYPE_FAMILY _FAMILY +DOC_COVER_DOCTYPE_FONT _FONT +DOC_COVER_DOCTYPE_SIZE _SIZE +DOC_COVER_FAMILY _FAMILY +DOC_COVER_MISC_COLOR _COLOR +DOC_COVER_MISC_QUAD _QUAD +DOC_COVER_SUBTITLE_COLOR _COLOR +DOC_COVER_SUBTITLE_FAMILY _FAMILY +DOC_COVER_SUBTITLE_FONT _FONT +DOC_COVER_SUBTITLE_SIZE _SIZE +DOC_COVER_TITLE_COLOR _COLOR +DOC_COVER_TITLE_FAMILY _FAMILY +DOC_COVER_TITLE_FONT _FONT +DOC_COVER_TITLE_SIZE _SIZE +DOCHEADER_COLOR _COLOR +DOCHEADER_FAMILY _FAMILY +DOC_QUAD _QUAD +DOCTYPE_FAMILY _FAMILY +DOCTYPE_FONT _FONT +DOCTYPE_SIZE _SIZE +ENDNOTE_BLOCKQUOTE_AUTOLEAD Q_AUTOLEAD +ENDNOTE_BLOCKQUOTE_AUTOLEAD QUOTE_AUTOLEAD +ENDNOTE_FAMILY _FAMILY +ENDNOTE_FONT _FONT +ENDNOTE_LINENUMBER_FAMILY _FAMILY +ENDNOTE_LINENUMBER_FONT _FONT +ENDNOTE_LINENUMBER_SIZE _SIZE +ENDNOTE_NUMBER_FAMILY _FAMILY +ENDNOTE_NUMBER_FONT _FONT +ENDNOTE_NUMBER_SIZE _SIZE +ENDNOTE_QUAD _QUAD +ENDNOTE_QUOTE_AUTLOEAD Q_AUTOLEAD +ENDNOTE_QUOTE_AUTOLEAD QUOTE_AUTOLEAD +ENDNOTE_STRING_FAMILY _FAMILY +ENDNOTE_STRING_FONT _FONT +ENDNOTE_STRING_QUAD _QUAD +ENDNOTE_STRING_SIZE _SIZE +ENDNOTE_TITLE_FAMILY _FAMILY +ENDNOTE_TITLE_FONT _FONT +ENDNOTE_TITLE_QUAD _QUAD +ENDNOTE_TITLE_SIZE _SIZE +EPIGRAPH_COLOR _COLOR +EPIGRAPH_FAMILY _FAMILY +EPIGRAPH_FONT _FONT +EPIGRAPH_QUAD _QUAD +EPIGRAPH_SIZE _SIZE +FINIS_COLOR _COLOR +FOOTNOTE_COLOR _COLOR +FOOTNOTE_FAMILY _FAMILY +FOOTNOTE_FONT _FONT +FOOTNOTE_QUAD _QUAD +FOOTNOTE_SIZE _SIZE +HDRFTR_CENTER_FAMILY _FAMILY +HDRFTR_CENTER_FONT _FONT +HDRFTR_CENTER_SIZE _SIZE +HDRFTR_COLOR _COLOR +HDRFTR_FAMILY _FAMILY +HDRFTR_LEFT_FAMILY _FAMILY +HDRFTR_LEFT_FONT _FONT +HDRFTR_LEFT_SIZE _SIZE +HDRFTR_RIGHT_FAMILY _FAMILY +HDRFTR_RIGHT_FONT _FONT +HDRFTR_RIGHT_SIZE _SIZE +HDRFTR_RULE_COLOR _COLOR +HDRFTR_SIZE _SIZE +HEAD_COLOR _COLOR +HEAD_FAMILY _FAMILY +HEAD_FONT _FONT +HEAD_QUAD _QUAD +HEAD_SIZE _SIZE +LINEBREAK_COLOR _COLOR +MISC_COLOR _COLOR +MISC_QUAD _QUAD +PAGENUM_COLOR _COLOR +PAGENUM_FAMILY _FAMILY +PAGENUM_FONT _FONT +PARAHEAD_COLOR _COLOR +PARAHEAD_FAMILY _FAMILY +PARAHEAD_FONT _FONT +PARAHEAD_SIZE _SIZE +QUOTE_COLOR _COLOR +QUOTE_FAMILY _FAMILY +QUOTE_FONT _FONT +QUOTE_INDENT _INDENT +QUOTE_SIZE _SIZE +REF_INDENT INDENT_REFS +REF) REF_BRACKETS_END +REF] REF_BRACKETS_END +REF} REF_BRACKETS_END +REF( REF_BRACKETS_START +REF[ REF_BRACKETS_START +REF{ REF_BRACKETS_START +SUBHEAD_COLOR _COLOR +SUBHEAD_FAMILY _FAMILY +SUBHEAD_FONT _FONT +SUBHEAD_SIZE _SIZE +SUBTITLE_COLOR _COLOR +SUBTITLE_FAMILY _FAMILY +SUBTITLE_FONT _FONT +SUBTITLE_SIZE _SIZE +TITLE_COLOR _COLOR +TITLE_FAMILY _FAMILY +TITLE_FONT _FONT +TITLE_SIZE _SIZE +TOC_FAM _FAMILY +TOC_FAMILY _FAMILY +TOC_HEADER_FAMILY _FAMILY +TOC_HEADER_FONT _FONT +TOC_HEADER_QUAD _QUAD +TOC_HEADER_SIZE _SIZE +TOC_HEAD_FAMILY _FAMILY +TOC_HEAD_FONT _FONT +TOC_HEAD_SIZE _SIZE +TOC_PARAHEAD_FAMILY _FAMILY +TOC_PARAHEAD_FONT _FONT +TOC_PARAHEAD_SIZE _SIZE +TOC_PN_FAMILY _FAMILY +TOC_PN_FONT _FONT +TOC_PN_SIZE _SIZE +TOC_PT_SIZE _SIZE +TOC_SUBHEAD_FAMILY _FAMILY +TOC_SUBHEAD_FONT _FONT +TOC_SUBHEAD_SIZE _SIZE +TOC_TITLE_FAMILY _FAMILY +TOC_TITLE_FONT _FONT +TOC_TITLE_SIZE _SIZE
                  diff --git a/contrib/mom/momdoc/toc.html b/contrib/mom/momdoc/toc.html index ca5276e9..9eff8efa 100644 --- a/contrib/mom/momdoc/toc.html +++ b/contrib/mom/momdoc/toc.html @@ -2,13 +2,13 @@ -Mom, version 1.2-f -- Table of Contents +Mom, version 1.3 -- Table of Contents -

                  Table of Contents for mom, version 1.2-f

                  +

                  Table of Contents for mom, version 1.3

                  The table of contents has grown quite large. If you've been using mom for a while, you might prefer the @@ -58,6 +58,7 @@ to go directly to the Full Table of Contents.
                1. Pagination
                2. Recto/verso printing and collating
                3. Cover pages +
                4. Bibliographies and references
                5. Writing letters
                6. Using typesetting macros during document processing
                7. Quick reference guide to mom @@ -217,7 +218,7 @@ to go directly to the Full Table of Contents.
                8. 5.3.4 Changing Type and Style Parameters before START
                9. 5.4 THE DOCUMENT ELEMENT TAGS @@ -248,15 +251,17 @@ to go directly to the Full Table of Contents.
                10. 5.4.4 Main heads
                11. 5.4.5 Subheads
                12. 5.4.6 Paragraph heads -
                13. 5.4.7 Linebreaks -- author linebreaks -
                14. 5.4.8 Quotes -- line for line poetic quotes or unformatted, verbatim text +
                15. 5.4.7 Linebreaks -- author linebreaks (section breaks) +
                16. 5.4.8 Quotes -- line for line poetic quotes or unformatted, verbatim text (e.g. code snippets)
                17. 5.4.9 Blockquotes -- cited material
                18. 5.4.10 Lists -- (nested) lists -
                19. 5.4.11 Footnotes -
                20. 5.4.12 Endnotes -
                21. 5.4.13 Blank page -
                22. 5.4.14 Table of contents -
                23. 5.4.15 Document termination -- FINIS +
                24. 5.4.11 Line numbering +
                25. 5.4.12 Footnotes +
                26. 5.4.13 Endnotes +
                27. 5.4.14 Margin notes +
                28. 5.4.15 Blank pages +
                29. 5.4.16 Table of contents +
                30. 5.4.17 Document termination -- FINIS
                31. 5.5 DOCUMENT HEADERS AND FOOTERS @@ -292,16 +297,17 @@ to go directly to the Full Table of Contents.
                32. 5.8 CREATING COVER PAGES
                  + +
                33. 5.9 BIBLIOGRAPHIES AND REFERENCES +
                  -
                34. 5.9 WRITING LETTERS +
                35. 5.10 WRITING LETTERS - -
                36. 5.10 USING TYPESETTING MACROS DURING DOCUMENT PROCESSING
                37. 6. QUICK REFERENCE GUIDE TO MOM diff --git a/contrib/mom/momdoc/typemacdoc.html b/contrib/mom/momdoc/typemacdoc.html index 164520cf..bedd0319 100644 --- a/contrib/mom/momdoc/typemacdoc.html +++ b/contrib/mom/momdoc/typemacdoc.html @@ -8,8 +8,8 @@ -Next   -Prev   +Next   +Prev   Back to Table of Contents

                  @@ -74,8 +74,6 @@ in document processing. Additionally, see if you encounter the problem of trying to get mom to put space at the tops of pages after the first.) - -

                   MACRO           EFFECT DURING DOCUMENT PROCESSING
                   -----           ---------------------------------
                  @@ -229,8 +227,8 @@ margins, I highly recommend using the
                   macro immediately after ADD_SPACE.
                   


                  -Next   -Prev   +Next   +Prev   Top   Back to Table of Contents diff --git a/contrib/mom/momdoc/typesetting.html b/contrib/mom/momdoc/typesetting.html index a003575c..2bff6079 100644 --- a/contrib/mom/momdoc/typesetting.html +++ b/contrib/mom/momdoc/typesetting.html @@ -164,7 +164,7 @@ some or all of the page margins with a single macro.

                  Page width


                  -Macro: PAGEWIDTH <width of printer sheet> +
                  Macro: PAGEWIDTH <width of printer sheet>
                  *Requires a unit of measure @@ -183,7 +183,7 @@ the width of your printer sheet is 8-1/2 inches, you enter

                  Page length


                  -Macro: PAGELENGTH <length of printer sheet> +
                  Macro: PAGELENGTH <length of printer sheet>
                  *Requires a unit of measure @@ -203,12 +203,12 @@ enter

                  Paper


                  -Macro: PAPER <paper type> +
                  Macro: PAPER <paper type>

                  PAPER provides a convenient way to set the page -dimensions for some common printer sheet sizes. <paper -type> can be one of: +dimensions for some common printer sheet sizes. <paper +type> can be one of:

                   	LETTER
                  @@ -246,7 +246,7 @@ than to remember the correct dimensions and enter
                   

                  Left margin


                  -Macro: L_MARGIN <left margin> +
                  Macro: L_MARGIN <left margin>
                  *Requires a unit of measure @@ -292,7 +292,7 @@ for an explanation.

                  Right margin


                  -Macro: R_MARGIN <right margin> +
                  Macro: R_MARGIN <right margin>
                  *Requires a unit of measure @@ -366,7 +366,7 @@ for an explanation.

                  Top margin


                  -Macro: T_MARGIN <top margin> +
                  Macro: T_MARGIN <top margin>
                  *Requires a unit of measure @@ -418,7 +418,7 @@ for an explanation.

                  Bottom margin


                  -Macro: B_MARGIN <bottom margin> +
                  Macro: B_MARGIN <bottom margin>
                  *Requires a unit of measure @@ -460,7 +460,7 @@ for an explanation.

                  Page


                  Macro: PAGE -<width> [ <length> [ <lm> [ <rm> [ <tm> [ <bm> ] ] ] ] ] +
                  <width> [ <length> [ <lm> [ <rm> [ <tm> [ <bm> ] ] ] ] ]
                  *All arguments require a unit of measure @@ -468,8 +468,8 @@ Macro: PAGE PAGE lets you establish paper dimensions and page margins with a single macro. The only required argument is page width. The rest are optional, but they must appear in order and you can't -skip over any. <lm>, <rm>, <tm> -and <bm> refer to the left, right, top and bottom +skip over any.
                  <lm>, <rm>, <tm> +and <bm> refer to the left, right, top and bottom margins respectively.

                  Assuming your page dimensions are 11 inches by 17 inches, and that's @@ -487,7 +487,7 @@ If you want to set the left margin as well, say, at 1 inch,

                  Now suppose you also want to set the top margin, say, at 1-1/2 -inches. <tm> comes after <rm> +inches. <tm> comes after <rm> in the optional arguments, but you can't skip over any arguments, therefore to set the top margin, you must also give a right margin. The PAGE macro would look like this: @@ -593,7 +593,7 @@ for an explanation.

                  Type family


                  -Macro: FAMILY <family> +
                  Macro: FAMILY <family>
                  Alias: FAM @@ -707,7 +707,7 @@ groff's basic R, I, B, BI styles.

                  Font


                  -Macro: FT R | I | B | BI | <any other valid font style> +
                  Macro: FT R | I | B | BI | <any other valid font style>

                  By default, groff permits FT to take one of four @@ -793,7 +793,7 @@ found in the description of the FAMILY macro.


                  Fallback font


                  -Macro: FALLBACK_FONT <fallback font> [ ABORT | WARN ] | ABORT | WARN +
                  Macro: FALLBACK_FONT <fallback font> [ ABORT | WARN ] | ABORT | WARN

                  In the event that you pass an invalid argument to @@ -867,7 +867,7 @@ again abort on font errors.


                  Point size of type


                  -Macro: PT_SIZE <size of type in points> +
                  Macro: PT_SIZE <size of type in points>
                  *Does not require a unit of measure @@ -922,7 +922,7 @@ would allow you to set point sizes with .PS.

                  Line spacing/leading


                  -Macro: LS <distance between lines> +
                  Macro: LS <distance between lines>
                  *Does not require a unit of measure @@ -975,7 +975,7 @@ then later reset it to 14 points with

                  Automatic line spacing


                  -Macro: AUTOLEAD <amount of automatic leading> [FACTOR] +
                  Macro: AUTOLEAD <amount of automatic leading> [FACTOR]
                  *Does not require a unit of measure @@ -1030,7 +1030,7 @@ wish.

                  Line length


                  -Macro: LL <line length> +
                  Macro: LL <line length>
                  *Requires a unit of measure @@ -1175,7 +1175,7 @@ use the

                  Quad lines left, right, or centre


                  -Macro: QUAD L | LEFT | R | RIGHT | C | CENTER | J | JUSTIFY +
                  Macro: QUAD L | LEFT | R | RIGHT | C | CENTER | J | JUSTIFY
                  Alias: FILL
                  @@ -1433,7 +1433,7 @@ regardless of the fill mode. Just type .EL

                  Break lines and add space between


                  -Macro: SPACE <space to add between lines> +
                  Macro: SPACE <space to add between lines>
                  Alias: SP @@ -1622,7 +1622,7 @@ ensuring that your documents look typographically professional.

                  Word spacing


                  -Macro: WS <+|-wordspace> | DEFAULT +
                  Macro: WS <+|-wordspace> | DEFAULT

                  WS (Word Space) increases or decreases the amount @@ -1693,7 +1693,7 @@ have to in/decrease the word space to get it back to normal.


                  Sentence space


                  -Macro: SS <+sentence space> | 0 | DEFAULT +
                  Macro: SS <+sentence space> | 0 | DEFAULT

                  SS (Sentence Space) tells groff how to treat double @@ -1767,15 +1767,15 @@ the space between sentences is not equal.


                  Automatic hyphenation control


                  -Macro: HY toggle +
                  Macro: HY toggle
                  -Macro: HY LINES <max. number of consecutive hyphenated lines> +
                  Macro: HY LINES <max. number of consecutive hyphenated lines>
                  -Macro: HY MARGIN <size of hyphenation margin> +
                  Macro: HY MARGIN <size of hyphenation margin>
                  -Macro: HY SPACE <extra interword spacing to prevent hyphenation> +
                  Macro: HY SPACE <extra interword spacing to prevent hyphenation>
                  -Macro: HY DEFAULT +
                  Macro: HY DEFAULT
                  Aliases: HYPHENATE, HYPHENATION @@ -1898,7 +1898,7 @@ a bit if your copy looks hyphen-heavy.

                  Set hyphenation parameters all at once


                  -Macro: HY_SET <lines> [ <margin> [ <space> ] ] +
                  Macro: HY_SET <lines> [ <margin> [ <space> ] ]
                  Alias: HYSET @@ -1947,7 +1947,7 @@ is how you'd do it.

                  Reduce whitespace


                  -Macro: RW <amount of whitespace reduction between letters> +
                  Macro: RW <amount of whitespace reduction between letters>

                  @@ -2011,7 +2011,7 @@ toggle macro.


                  Expand whitespace


                  -Macro: EW <amount of whitespace expansion between letters> +
                  Macro: EW <amount of whitespace expansion between letters>

                  @@ -2068,7 +2068,7 @@ toggle macro.


                  Break before line kerning


                  -Macro: BR_AT_LINE_KERN toggle +
                  Macro: BR_AT_LINE_KERN toggle

                  @@ -2106,7 +2106,7 @@ the line prior to EW or RW.


                  Automatic kerning


                  -Macro: KERN toggle +
                  Macro: KERN toggle

                  @@ -2127,7 +2127,7 @@ Kerning of individual character pairs can be controlled with the


                  Automatic ligature generation


                  -Macro: LIGATURES toggle +
                  Macro: LIGATURES toggle
                  Alias: LIG @@ -2202,7 +2202,7 @@ type in a faked font look typographically cheap.

                  Set degree of slant for pseudo-italicizing


                  -Macro: SETSLANT <degrees to slant type> | RESET +
                  Macro: SETSLANT <degrees to slant type> | RESET

                  Pseudo-italicizing of type is accomplished by slanting a roman font @@ -2276,7 +2276,7 @@ change this behaviour, use the special macro


                  Set amount of emboldening


                  -Macro: SETBOLDER <amount of emboldening, in machine units> | RESET +
                  Macro: SETBOLDER <amount of emboldening, in machine units> | RESET

                  Emboldening of type is accomplished by printing characters @@ -2351,7 +2351,7 @@ requests.


                  Set percentage for pseudo-condensed type


                  -Macro: CONDENSE <pseudo-condense percentage> +
                  Macro: CONDENSE <pseudo-condense percentage>

                  Pseudo-condensing of type is accomplished by reducing the width of @@ -2435,7 +2435,7 @@ requests.


                  Set percentage for pseudo-extended type


                  -Macro: EXTEND <pseudo-extend percentage> +
                  Macro: EXTEND <pseudo-extend percentage>

                  Pseudo-extending of type is accomplished by increasing the width of @@ -2541,7 +2541,7 @@ relative to the current


                  Advance Lead (move downward)


                  -Macro: ALD <distance to move downward> +
                  Macro: ALD <distance to move downward>
                  *Requires a unit of measure @@ -2599,7 +2599,7 @@ or

                  Reverse Lead (move upward)


                  -Macro: RLD <distance to move upward> +
                  Macro: RLD <distance to move upward>
                  *Requires a unit of measure @@ -3056,7 +3056,7 @@ the gutters are wider.

                  Set up typesetting tabs


                  -Macro: TAB_SET <tab number> <indent> <length> L | R | C | J [ QUAD ] +
                  Macro: TAB_SET <tab number> <indent> <length> L | R | C | J [ QUAD ]
                  *<indent> and <length> require a unit of measure @@ -3220,7 +3220,7 @@ To circumvent this behaviour, I recommend using the PAD to set up string tabs in centered or flush right lines. Say, for example, you want to use a string tab to underscore the text of a -centered line with a thick rule. Rather than this, +centered line with a rule. Rather than this,

                   	.CENTER
                  @@ -3257,7 +3257,7 @@ you should do:
                   

                  Set string tabs


                  -Macro: ST <tab number> L | R | C | J [ QUAD ] +
                  Macro: ST <tab number> L | R | C | J [ QUAD ]

                  After string tabs have been marked off on an input line (see @@ -3298,7 +3298,7 @@ for a full explanation of setting up string tabs.


                  Call tabs


                  -Macro: TAB <tab number> +
                  Macro: TAB <tab number>
                  Alias: TB

                  @@ -3612,7 +3612,7 @@ your columns.


                  Exit multi-columns


                  -Macro: MCX [ <distance to advance below longest column> ] +
                  Macro: MCX [ <distance to advance below longest column> ]
                  *Optional argument requires a unit of measure @@ -3628,7 +3628,7 @@ below the longest column. Linespace, in this instance, is the in effect at the moment MCX is invoked.

                  -If you pass the <distance> argument to +If you pass the <distance> argument to MCX, it advances 1 linespace below the longest column (see above) PLUS the distance specified by the argument. The argument requires a unit of measure; therefore, to advance @@ -3844,7 +3844,7 @@ for information and advice on using indents with the


                  Indent left


                  -Macro: IL [ <measure> ] +
                  Macro: IL [ <measure> ]
                  *The optional argument requires a unit of measure @@ -3887,7 +3887,7 @@ automatically turns off IB.

                  Indent right


                  -Macro: IR [ <measure> ] +
                  Macro: IR [ <measure> ]
                  *The optional argument requires a unit of measure @@ -3928,7 +3928,7 @@ automatically turns off IB.

                  Indent both


                  -Macro: IB [ <left measure> <right measure> ] +
                  Macro: IB [ <left measure> <right measure> ]
                  *The optional arguments require a unit of measure @@ -3981,7 +3981,7 @@ automatically turns off IL and

                  Temporary (left) indent


                  -Macro: TI [ <measure> ] +
                  Macro: TI [ <measure> ]
                  *The optional argument requires a unit of measure @@ -4026,7 +4026,7 @@ are NOT additive. In the following example, the second .TI

                  Hanging indent


                  -Macro: HI [ <measure> ] +
                  Macro: HI [ <measure> ]
                  *The optional argument requires a unit of measure @@ -4141,13 +4141,13 @@ are NOT additive. Each time you pass a measure to

                  Quitting indents


                  -Macro: IQ  [ CLEAR ]  (quit any/all indents -- see *IMPORTANT NOTE) +
                  Macro: IQ  [ CLEAR ]  (quit any/all indents -- see *IMPORTANT NOTE)
                  -Macro: ILX [ CLEAR ]  (exit Indent Left) +
                  Macro: ILX [ CLEAR ]  (exit Indent Left)
                  -Macro: IRX [ CLEAR ]  (exit Indent Right) +
                  Macro: IRX [ CLEAR ]  (exit Indent Right)
                  -Macro: IBX [ CLEAR ]  (exit Indent Both) +
                  Macro: IBX [ CLEAR ]  (exit Indent Both)

                  *IMPORTANT NOTE: diff --git a/contrib/mom/momdoc/using.html b/contrib/mom/momdoc/using.html index 744629ab..1265eec8 100644 --- a/contrib/mom/momdoc/using.html +++ b/contrib/mom/momdoc/using.html @@ -185,7 +185,7 @@ Groff itself comes with a quick and dirty previewer called gxditview. Invoke it with

                  -	groff -X -mom <filename>
                  +	groff -X -mom filename
                   
                  It's not particularly pretty, doesn't have many navigation @@ -201,18 +201,24 @@ doesn't gobble up system resources.

                  A surer way to preview documents is with gv (ghostview). This involves processing documents with groff, -directing the output to a temporary (PostScript) file, then opening -the temporary file in gv. While that may sound -like a lot of work, I've set up my editor (elvis) to do it for me. -Whenever I'm working on a document that needs previewing/checking, -I fire up gv with the "Watch File" -option turned on. To look at the file, I tell elvis to process -it (with groff) and send it to a temporary file (groff --mom filename > filename.ps), then open the file inside -gv. Ever after, when I want to look at any changes -I make, I simply tell elvis to work his magic again. The Watch File -option in gv registers that the file has changed, -and automatically loads the new version. Voilà! -- instant previewing. +and directing the output to a PostScript file, like this, +

                  +

                  +	groff -mom filename > filename.ps
                  +
                  +then opening .ps file in gv. +

                  +While that may sound like a lot of work, I've set up my editor +(elvis) to do it for me. Whenever I'm working on a document that +needs previewing/checking, I fire up gv with the +"Watch File" option turned on. To look at the file, I +tell elvis to process it (with groff) and send it to a temporary +file (groff -mom filename > filename.ps), then open +the file inside gv. Ever after, when I want to +look at any changes I make, I simply tell elvis to work his magic +again. The Watch File option in gv registers that +the file has changed, and automatically loads the new version. +Voilà! --instant previewing.


                  diff --git a/contrib/mom/om.tmac b/contrib/mom/om.tmac index 719cd362..fd61710a 100644 --- a/contrib/mom/om.tmac +++ b/contrib/mom/om.tmac @@ -1,49 +1,47 @@ .\" om.tmac -.\" -.\" Mom -- a typesetting/document-processing macro set for groff. -.\" -.\" Copyright (C) 2002, 2003 Free Software Foundation, Inc. -.\" Written by Peter Schaffter (ptpi@golden.net) -.\" -.\" 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 2, or (at your option) any later -.\" version. -.\" -.\" groff is distributed in the hope that it will be useful, but WITHOUT ANY -.\" WARRANTY; without even the implied warranty of MERCHANTABILITY or -.\" FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -.\" for more details. -.\" -.\" You should have received a copy of the GNU General Public License along -.\" with groff; see the file COPYING. If not, write to the Free Software -.\" Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -.\" -.\" -.\" -\# Version 1.2-f -\# ------------- -\# -\# 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.). -\# -\# "" in the description of arguments that can be passed -\# to a macro means that any argument turns the feature off. +.ig +Mom -- a typesetting/document-processing macro set for groff. + +Copyright (C) 2002, 2003 Free Software Foundation, Inc. + Written by Peter Schaffter (peter@faustus.dyn.ca) + +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 2, or (at your option) any later +version. + +groff is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License along +with groff; see the file COPYING. If not, write to the Free Software +Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +Version 1.3 +----------- +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.). + +"" in the description of arguments that can be passed +to a macro means that any argument turns the feature off. +.. \# \# ==================================================================== \# @@ -53,6 +51,8 @@ \# Check that GNU troff is being run .if !\n[.g]=1 \ . ab The mom macros require that you be running GNU troff. +.if \n(.C \ +. ab The groff mom macros do not work in compatibility mode. \# Add supplementary styles .sty \n[.fp] L \" Light Roman .sty \n[.fp] LI \" Light Italic @@ -129,28 +129,30 @@ .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). +.ig +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). +.. \# \# ==================================================================== \# @@ -335,6 +337,7 @@ \# .MAC NEWPAGE END . br +. nr #NEWPAGE 1 . ie \\n[#B_MARGIN_SET]=1 \{\ . ie !\\n[#DOCS]=1 \{\ . ev NP @@ -433,8 +436,14 @@ \# to $FAMILY. \# .MAC FAMILY END -. if \\n[#PRINT_STYLE]=1 \{ .return \} -. if \\n[#IGNORE] \{ .return \} +. if \\n[#PRINT_STYLE]=1 \{\ +. fam C +. return +. \} +. if \\n[#IGNORE] \{\ +. fam C +. return +. \} . if (\\n[.x]\\n[.y]\\n[.Y] >= 1192) \{\ . ds $SAVED_STYLE \\n[.sty] . \} @@ -553,6 +562,7 @@ \# Does not require unit of measure. LS automatically turns off AUTOLEAD. \# .MAC LS END +. br . nr #OLD_LEAD \\n(.v . if \\n[#PRINT_STYLE]=1 \{ .return \} . if \\n[#IGNORE] \{ .return \} @@ -645,33 +655,35 @@ .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. -\# -\# N.B.--the amount of inline kerning supplied by \*[BU] or -\# \*[FU] 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] 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. -\# +.ig +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. + +N.B.--the amount of inline kerning supplied by \*[BU] or +\*[FU] 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] 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)' @@ -690,13 +702,15 @@ .\} .rr #LOOP \# -\# -\# *Horizontal movements -\# 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 ] and \*[FWD ]. +.ig +Horizontal movements + +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 ] and \*[FWD ]. +.. \# .ds BCK \h'-\\$1' .ds FWD \h'\\$1' @@ -808,10 +822,13 @@ \# \# 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. +\# +.ig +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. +.. \# \# *Argument: \# @@ -825,22 +842,24 @@ \# *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. -\# -\# \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. +.ig +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. + +\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] \{\ @@ -1008,11 +1027,13 @@ \# \# ALD/RLD STRINGS \# --------------- -\# The strings \*[ALD.25]...\*[ALD12.75] and their corresponding -\# \*[RLD] forms have been left in for backward compatibility with -\# documents created using mom-1.1.3c or earlier. The prefered -\# methods of advancing and reversing on the page inline are -\# \*[UP ] and \*[DOWN ]. +.ig +The strings \*[ALD.25]...\*[ALD12.75] and their corresponding +\*[RLD] forms have been left in for backward compatibility with +documents created using mom-1.1.3c or earlier. The prefered methods +of advancing and reversing on the page inline are \*[UP ] +and \*[DOWN ]. +.. \# .ds DOWN \v'\\$1' .ds UP \v'-\\$1' @@ -1367,13 +1388,16 @@ \# \# 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. +\# +.ig +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. +.. \# \# LEFT \# ---- @@ -1396,7 +1420,7 @@ . ce 0 . nf . nr #PSEUDO_FILL 1 -\# Fix for a little conflict with DOCTYPE LETTER +.\" Fix for a little conflict with DOCTYPE LETTER . if '\\n(.z'LETTERHEAD1' \{ .rr #DATE_FIRST \} .END \# @@ -1448,33 +1472,35 @@ \# \# +++TABS+++ \# -\# There are two different kinds of tabs available: 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 -\# with a quad direction and an instruction to fill lines). After tabs -\# are set with TAB_SET, they are called with .TAB n, where "n" -\# corresponds to the number passed to TAB_SET as a valid tab number. -\# -\# String tabs allow the user to mark off tab positions inline. Tab -\# indents and lengths are calculated from the beginning and end -\# positions of the marks. Up to 19 string tabs may be created, -\# numbered 1-19. Once created, they are called with .TAB n, -\# just like typesetting tabs. -\# -\# Setting up string tabs is a two-step procedure. First, the user -\# enters an input line in which s/he wants to mark off string tabs. -\# The beginning of a tab is marked with \*[STn], where "n" is -\# the desired number of the tab. The end of the the tab is marked -\# with \*[STnX]. All ST's must have a matching STX. String tabs -\# may be nested. -\# -\# Next, the user invokes .ST n for every string tab defined, and -\# 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. +.ig +There are two different kinds of tabs available: 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 +with a quad direction and an instruction to fill lines). After tabs +are set with TAB_SET, they are called with .TAB n, where "n" +corresponds to the number passed to TAB_SET as a valid tab number. + +String tabs allow the user to mark off tab positions inline. Tab +indents and lengths are calculated from the beginning and end +positions of the marks. Up to 19 string tabs may be created, +numbered 1-19. Once created, they are called with .TAB n, +just like typesetting tabs. + +Setting up string tabs is a two-step procedure. First, the user +enters an input line in which s/he wants to mark off string tabs. +The beginning of a tab is marked with \*[STn], where "n" is +the desired number of the tab. The end of the the tab is marked +with \*[STnX]. All ST's must have a matching STX. String tabs +may be nested. + +Next, the user invokes .ST n for every string tab defined, and +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 \# ------------------------------ @@ -1551,40 +1577,43 @@ \# \# 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 if you want them to align. -\# -\# If you want to reset tabs, you must use .TQ before .TAB_SET. -\# -\# Note that indents are turned off automatically whenever a new -\# tab is called with TAB . -\# -\# Tabs themselves are user-invoked using the TAB macro with a numeric -\# argument, e.g. TAB 1. -\# -\# Generally, in order not to get confused, it's a good idea -\# to make sure all indents are off before setting tabs. +.ig +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 if you want them to align. + +If you want to reset tabs, you must use .TQ before .TAB_SET. + +Note that indents are turned off automatically whenever a new +tab is called with TAB . + +Tabs themselves are user-invoked using the TAB macro with a numeric +argument, e.g. TAB 1. + +Generally, in order not to get confused, it's a good idea +to make sure all indents are off before setting tabs. +.. \# .MAC TAB_SET END . br @@ -1776,7 +1805,6 @@ . if \\n[#NUM_ARGS]=2 .ds \\$2 \m[\\$1] .END \# -\# \# Pre-define xcolors black and white \# .ds black \m[black] @@ -2376,7 +2404,8 @@ . if !d$PAD_MARKER .ds $PAD_MARKER # . char \\*[$PAD_MARKER] \R'#PAD_COUNT \En[#PAD_COUNT]+1' . ds $FAMILY_FOR_PAD \\n[.fam] -. fp \\n[.fp] \\*[$FONT] +\#. fp \\n[.fp] \\*[$FONT] +. fp \\n[.fp] \\n[.sty] . ds $FONT_FOR_PAD \\*[$FONT] . nr #SIZE_FOR_PAD \\n[.ps] . ds $PAD_STRING \\$1 @@ -2425,14 +2454,15 @@ \# \# +++LEADERS+++ \# -\# The leader mechanism is primitive, but it works. Basically, -\# every macro in this set that includes a line length also sets -\# a single groff tab stop at the right hand end of the line. -\# That way, whenever Ctrl-A is invoked (always at the end of -\# an input line), leader of the correct length gets deposited. -\# Ctrl-A is accessed by the string LEADER (i.e. inline, as -\# \*[LEADER]). Leaders within tabs get their length from the -\# tab line length. +.ig +The leader mechanism is primitive, but it works. Basically, every +macro in this set that includes a line length also sets a single +groff tab stop at the right hand end of the line. That way, +whenever Ctrl-A is invoked (always at the end of an input line), +leader of the correct length gets deposited. Ctrl-A is accessed by +the string LEADER (i.e. inline, as \*[LEADER]). Leaders within tabs +get their length from the tab line length. +.. \# \# SET LEADER CHARACTER \# -------------------- @@ -2586,7 +2616,7 @@ . ps \\n[#PT_SIZE]u+100u . SIZESPECS . nr #GET_DC_HEIGHT \\n[#CAP_HEIGHT] -. \} +.\} . if d$DC_ADJUST \{ .ps \\*[$DC_ADJUST]p \} . mk x . sp \\n[#DC_LINES]v @@ -2750,86 +2780,88 @@ \# \# +++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 -\# .IX/Q macros. -\# -\# Example -\# ------- -\# -\# .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 IX 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. +.ig +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 +.IX/Q macros. + +Example +------- + +.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 IX 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 \# ----------- @@ -3625,7 +3657,7 @@ y\\R'#DESCENDER \\n[.cdp]' . if !d$CHAPTER_STRING \{ .CHAPTER_STRING "Chapter" \} . if !d$DRAFT_STRING \{ .DRAFT_STRING "Draft" \} . if !d$REVISION_STRING \{ .REVISION_STRING "Rev." \} -\# Default +.\" Default . if \\n[#DOC_TYPE]=1 \{\ . ie \\n[#COPY_STYLE]=1 \{\ . ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] \} @@ -3657,9 +3689,9 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . \} . \} -\# Chapter +.\" Chapter . if \\n[#DOC_TYPE]=2 \{\ -\# Copystyle DRAFT +.\" Copystyle DRAFT . ie \\n[#COPY_STYLE]=1 \{\ . ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] \} . el \{ .PAGENUM_STYLE roman \} @@ -3669,13 +3701,13 @@ y\\R'#DESCENDER \\n[.cdp]' . ie !'\\*[$CHAPTER_TITLE]'' \{\ . ds $HDRFTR_CENTER \\*[$CHAPTER_TITLE] . \} -. el \{ .ds $HDRFTR_CENTER \\*[$CHAPTER_STRING]\} +. el .ds $HDRFTR_CENTER \\*[$CHAPTER_STRING] . \} . el \{\ . ie !'\\*[$CHAPTER_TITLE]'' \{\ . ds $HDRFTR_CENTER \\*[$CHAPTER_TITLE] . \} -. el \{ .ds $HDRFTR_CENTER \\*[$CHAPTER_STRING] \\*[$CHAPTER]\} +. el .ds $HDRFTR_CENTER \\*[$CHAPTER_STRING] \\*[$CHAPTER] . \} . \} . el \{\ @@ -3788,7 +3820,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . \} . \} -\# Copystyle FINAL +.\" Copystyle FINAL . el \{\ . if r#DRAFT_WITH_PAGENUM \{ .rr #DRAFT_WITH_PAGENUM \} . if \\n[#USER_DEF_HDRFTR_CENTER]=0 \{\ @@ -3813,7 +3845,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . \} . \} -\# Named +.\" Named . if \\n[#DOC_TYPE]=3 \{\ . ie \\n[#COPY_STYLE]=1 \{\ . ie \\n[#PAGENUM_STYLE_SET] \{ .PAGENUM_STYLE \\*[$PAGENUM_STYLE] \} @@ -3895,8 +3927,8 @@ y\\R'#DESCENDER \\n[.cdp]' \# \# .MAC DRAFT END \"Draft number -. ie '\\$1'' \{ .ds $DRAFT \} -. el \{ .ds $DRAFT " \\$1\} +. ie '\\$1'' .ds $DRAFT +. el .ds $DRAFT " \\$1 .END \# \# @@ -3914,7 +3946,7 @@ y\\R'#DESCENDER \\n[.cdp]' . nr #AUTHOR_NUM -1 1 . while \\n[#NUM_ARGS]>\\n[#AUTHOR_NUM] \{\ . ds $AUTHOR_\\n+[#AUTHOR_NUM] \\$\\n[#AUTHOR_NUM] -. \} +.\} . nr #NUM_AUTHORS \\n[#NUM_ARGS]%2 \"Use mod 2 to test if odd or even # of authors . ie \\n[#NUM_AUTHORS]=1 \{ .nr #AUTHOR_LINES 0 \} . el \{ .nr #AUTHOR_LINES 1 \} @@ -3930,7 +3962,7 @@ y\\R'#DESCENDER \\n[.cdp]' . nr #MISC_NUM -1 1 . while \\n[#NUM_ARGS]>\\n[#MISC_NUM] \{\ . ds $MISC_\\n+[#MISC_NUM] \\$\\n[#MISC_NUM] -. \} +.\} . nr #NUM_MISCS \\n[#NUM_ARGS] .END \# @@ -4097,15 +4129,19 @@ y\\R'#DESCENDER \\n[.cdp]' \# TYPE-STYLE CONTROL MACROS \# ------------------------- \# -\# The control macros for family, font, size, quad and color are here -\# grouped together. Each (e.g. _FAMILY or _FONT) tests for a calling -\# alias before performing the action(s) appropriate to the calling -\# macro. Defaults for all these guys are set in DEFAULTS, and -\# listed in the "Control Macros" section of the documentation -\# pertinent to the macro whose style is to be changed. +.ig +The control macros for family, font, size, quad and color are here +grouped together. Each (e.g. _FAMILY or _FONT) tests for a calling +alias before performing the action(s) appropriate to the calling +macro. Defaults for all these guys are set in DEFAULTS, and listed +in the "Control Macros" section of the documentation pertinent to +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 @@ -4128,6 +4164,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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 @@ -4161,6 +4198,8 @@ y\\R'#DESCENDER \\n[.cdp]' \# .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 @@ -4180,6 +4219,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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 @@ -4205,6 +4245,7 @@ y\\R'#DESCENDER \\n[.cdp]' \# .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 @@ -4223,6 +4264,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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 @@ -4421,6 +4463,12 @@ y\\R'#DESCENDER \\n[.cdp]' \# \# .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 @@ -4432,7 +4480,11 @@ y\\R'#DESCENDER \\n[.cdp]' . ds $DOC_QUAD \\$1 . QUAD \\*[$DOC_QUAD] . \} -. if '\\$0'ENDNOTE_QUAD' .ds $EN_QUAD \\$1 +. 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 @@ -4510,14 +4562,14 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . if !r#HDRFTR_RULE \{ .HDRFTR_RULE \} . if !r#PAGE_NUM_SET \{ .PAGENUMBER 1 \} -\# Read in number registers and strings for type parameters +.\" 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] . nr #DOC_LEAD \\n[#LEAD] -\# #SAVED_DOC_LEAD is set in COLLATE +.\" #SAVED_DOC_LEAD is set in COLLATE . if r#SAVED_DOC_LEAD \{\ . if !\\n[#DOC_LEAD]=\\n[#SAVED_DOC_LEAD] \{ .nr #RERUN_TRAPS 1 \} . \} @@ -4529,7 +4581,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . ds $DOC_QUAD \\*[$QUAD_VALUE] . ds $PP_FT \\*[$FONT] -\# Counters +.\" Counters . nr #PP 0 . nr #FN_NUMBER 0 1 . nr #EN_NUMBER 0 1 @@ -4538,7 +4590,7 @@ y\\R'#DESCENDER \\n[.cdp]' . RESET_HEAD_NUMBER . RESET_SUBHEAD_NUMBER . RESET_PARAHEAD_NUMBER -\# General style defaults for both PRINTSTYLEs +.\" General style defaults for both PRINTSTYLEs . nr #PP_STYLE 1 . PARA_INDENT \\n[#PP_INDENT]u . if !d$HDRFTR_FAM \{ .HDRFTR_FAMILY \\*[$DOC_FAM] \} @@ -4560,21 +4612,22 @@ y\\R'#DESCENDER \\n[.cdp]' . if \\n[#HDRFTR_RIGHT_CAPS]=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 !r#FN_MARKER_STYLE \{ .FOOTNOTE_MARKER_STYLE STAR \} -. if !d$EN_PN_STYLE \{ .ENDNOTES_PAGENUM_STYLE digit \} -. if !d$EN_FAM \{ .ENDNOTE_FAMILY \\*[$DOC_FAM] \} -. if !d$EN_FN \{ .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_UNDERSCORE \{ .ENDNOTE_STRING_UNDERSCORE 2 \} -. if !r#EN_STRING_CAPS \{ .ENDNOTE_STRING_CAPS \} +. 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_MARKER_STYLE] \{ .FOOTNOTE_MARKER_STYLE STAR \} +. if !\\n[#EN_MARKER_STYLE] \{ .ENDNOTE_MARKER_STYLE NUMBER \} +. 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_UNDERSCORE \{ .ENDNOTE_STRING_UNDERSCORE 2 \} +. if !r#EN_STRING_CAPS \{ .ENDNOTE_STRING_CAPS \} . if !d$EN_TITLE \{\ . ie \\n[#DOC_TYPE]=2 \{\ . ie '\\*[$CHAPTER]'' \{ .ENDNOTE_TITLE "\\*[$CHAPTER_STRING]" \} @@ -4589,73 +4642,83 @@ y\\R'#DESCENDER \\n[.cdp]' . if !r#EN_NUMBERS_ALIGN_LEFT \{\ . if !r#EN_NUMBERS_ALIGN_RIGHT \{ .ENDNOTE_NUMBERS_ALIGN_RIGHT 2 \} . \} -. 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 \} -. if !r#TOC_HEAD_INDENT \{ .TOC_HEAD_INDENT 18p \} -. if !r#TOC_SH_INDENT \{ .TOC_SUBHEAD_INDENT 30p \} -. if !r#TOC_PH_INDENT \{ .TOC_PARAHEAD_INDENT 42p \} -\# String defaults for both PRINTSTYLEs +. if !d$EN_LN_GAP \{ .ENDNOTE_LINENUMBER_GAP 1.5n \} +. 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_UNDERSCORE \{ .BIBLIOGRAPHY_STRING_UNDERSCORE 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 \} +. if !r#TOC_HEAD_INDENT \{ .TOC_HEAD_INDENT 18p \} +. if !r#TOC_SH_INDENT \{ .TOC_SUBHEAD_INDENT 30p \} +. if !r#TOC_PH_INDENT \{ .TOC_PARAHEAD_INDENT 42p \} +.\" String defaults for both PRINTSTYLEs . ie \\n[#DOC_TYPE]=1 \{\ . ie '\\*[$DOC_TITLE]'' \{\ -. if \\n[#USER_DEF_HDRFTR_LEFT]=0 \{ .ds $HDRFTR_LEFT \\*[$AUTHOR_1]\} +. if \\n[#USER_DEF_HDRFTR_LEFT]=0 .ds $HDRFTR_LEFT \\*[$AUTHOR_1] . rr #USER_DEF_HDRFTR_LEFT -. if \\n[#USER_DEF_HDRFTR_RIGHT]=0 \{ .ds $HDRFTR_RIGHT \\*[$TITLE]\} +. if \\n[#USER_DEF_HDRFTR_RIGHT]=0 .ds $HDRFTR_RIGHT \\*[$TITLE] . rr #USER_DEF_HDRFTR_RIGHT . \} . el \{\ . 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_LEFT]=0 .ds $HDRFTR_LEFT \\*[$AUTHOR_1] . rr #USER_DEF_HDRFTR_LEFT -. if \\n[#USER_DEF_HDRFTR_CENTER]=0 \{ .ds $HDRFTR_CENTER \\*[$TITLE]\} +. if \\n[#USER_DEF_HDRFTR_CENTER]=0 .ds $HDRFTR_CENTER \\*[$TITLE] . rr #USER_DEF_HDRFTR_CENTER -. if \\n[#USER_DEF_HDRFTR_RIGHT]=0 \{ .ds $HDRFTR_RIGHT \\*[$DOC_TITLE]\} +. if \\n[#USER_DEF_HDRFTR_RIGHT]=0 .ds $HDRFTR_RIGHT \\*[$DOC_TITLE] . rr #USER_DEF_HDRFTR_RIGHT . \} . \} . el \{\ -. if \\n[#USER_DEF_HDRFTR_LEFT]=0 \{ .ds $HDRFTR_LEFT \\*[$AUTHOR_1]\} +. if \\n[#USER_DEF_HDRFTR_LEFT]=0 .ds $HDRFTR_LEFT \\*[$AUTHOR_1] . rr #USER_DEF_HDRFTR_LEFT -. if \\n[#USER_DEF_HDRFTR_RIGHT]=0 \{ .ds $HDRFTR_RIGHT \\*[$TITLE]\} +. if \\n[#USER_DEF_HDRFTR_RIGHT]=0 .ds $HDRFTR_RIGHT \\*[$TITLE] . rr #USER_DEF_HDRFTR_RIGHT . \} -. if !d$ATTRIBUTE_STRING \{ .ATTRIBUTE_STRING "by" \} -. if !d$FINIS_STRING \{ .FINIS_STRING "END" \} -\# Covers +. if !d$ATTRIBUTE_STRING \{ .ATTRIBUTE_STRING "by" \} +. if !d$FINIS_STRING \{ .FINIS_STRING "END" \} +.\" 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 \} -\# Defaults for printstyle TYPEWRITE +.\" Defaults for printstyle TYPEWRITE . if \\n[#PRINT_STYLE]=1 \{\ . if \\n[#UNDERLINE_QUOTES]=1 \{ .UNDERLINE_QUOTES \} . if \\n[#UNDERLINE_QUOTES]=0 \{ .UNDERLINE_QUOTES OFF \} -\# +Quotes and blockquotes +.\" +Quotes and blockquotes . if !r#Q_OFFSET_VALUE \{ .QUOTE_INDENT 2 \} -\# +Epigraphs +.\" +Epigraphs . if !r#EPI_OFFSET_VALUE \{ .EPIGRAPH_INDENT 2 \} -\# +Linebreaks +.\" +Linebreaks . if !d$LINEBREAK_CHAR \{ .LINEBREAK_CHAR * 3 2p \} -\# +Footnotes +.\" +Footnotes . if !d$FN_SIZE_CHANGE \{ .FOOTNOTE_SIZE +0 \} . if !r#FN_RULE_LENGTH \{ .FOOTNOTE_RULE_LENGTH 2i \} -\# +Paragraph heads +.\" +Paragraph heads . if !r#PH_INDENT \{ .PARAHEAD_INDENT \\n[#PP_INDENT]u/2u \} -\# +Endnotes +.\" +Endnotes . if !r#EN_PP_INDENT \{ .ENDNOTE_PARA_INDENT \\n[#PP_INDENT] \} -\# +Footnotes +.\" +Footnotes . if !r#FN_RULE_ADJ \{ .FOOTNOTE_RULE_ADJ 6p \} -\# +Slant stuff +.\" +Slant stuff . if !r#SLANT_MEANS_SLANT \{\ . ie \\n[#UNDERLINE_SLANT]=1 \{ .UNDERLINE_SLANT \} . el \{ .UNDERLINE_SLANT OFF \} . \} . \} -\# Defaults for printstyle TYPESET +.\" Defaults for printstyle TYPESET . if \\n[#PRINT_STYLE]=2 \{\ . if !d$DOCHEADER_LEAD_ADJ \{\ . ie !'\\*[$CHAPTER_TITLE]'' \{\ @@ -4666,97 +4729,97 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . el \{ .DOCHEADER_LEAD +0 \} . \} -\# +Cover +.\" +Cover . if !d$COVER_LEAD_ADJ \{ .COVER_LEAD +0 \} . if !d$COVER_FAM \{ .COVER_FAMILY \\*[$DOC_FAM] \} -\# (title) +.\" (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_FT \{ .COVER_TITLE_FONT B \} . if !d$COVER_TITLE_SIZE_CHANGE \{ .COVER_TITLE_SIZE +3.5 \} -\# (chapter title) +.\" (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_FT \{ .COVER_CHAPTER_TITLE_FONT BI \} +. if !d$COVER_CHAPTER_TITLE_FT \{ .COVER_CHAPTER_TITLE_FONT BI \} . if !d$COVER_CHAPTER_TITLE_SIZE_CHANGE \{ .COVER_CHAPTER_TITLE_SIZE +4 \} -\# (subtitle) +.\" (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_FT \{ .COVER_SUBTITLE_FONT R \} . if !d$COVER_SUBTITLE_SIZE_CHANGE \{ .COVER_SUBTITLE_SIZE +0 \} -\# (attribution and author[s]) +.\" (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_FT \{ .COVER_AUTHOR_FONT I \} . if !d$COVER_AUTHOR_SIZE_CHANGE \{ .COVER_AUTHOR_SIZE +0 \} -\# (doctype if "named") +.\" (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_FT \{ .COVER_DOCTYPE_FONT BI \} . if !d$COVER_DOCTYPE_SIZE_CHANGE \{ .COVER_DOCTYPE_SIZE +3 \} -\# (copyright) +.\" (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_FT \{ .COVER_COPYRIGHT_FONT R \} . if !d$COVER_COPYRIGHT_SIZE_CHANGE \{ .COVER_COPYRIGHT_SIZE -2 \} -\# +Doc cover +.\" +Doc cover . if !d$DOC_COVER_LEAD_ADJ \{ .DOC_COVER_LEAD +0 \} . if !d$DOC_COVER_FAM \{ .DOC_COVER_FAMILY \\*[$DOC_FAM] \} -\# (title) +.\" (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_FT \{ .DOC_COVER_TITLE_FONT B \} . if !d$DOC_COVER_TITLE_SIZE_CHANGE \{ .DOC_COVER_TITLE_SIZE +3.5 \} -\# (chapter title) +.\" (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_FT \{ .DOC_COVER_CHAPTER_TITLE_FONT BI \} +. 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) +.\" (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_FT \{ .DOC_COVER_SUBTITLE_FONT R \} . if !d$DOC_COVER_SUBTITLE_SIZE_CHANGE \{ .DOC_COVER_SUBTITLE_SIZE +0 \} -\# (attribution and author[s]) +.\" (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] \} +. 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 \} -\# (doctype if "named") +.\" (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_FT \{ .DOC_COVER_DOCTYPE_FONT BI \} . if !d$DOC_COVER_DOCTYPE_SIZE_CHANGE \{ .DOC_COVER_DOCTYPE_SIZE +3 \} -\# (copyright) +.\" (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_FT \{ .DOC_COVER_COPYRIGHT_FONT R \} . if !d$DOC_COVER_COPYRIGHT_SIZE_CHANGE \{ .DOC_COVER_COPYRIGHT_SIZE -2 \} -\# +Docheader +.\" +Docheader . if !d$DOCHEADER_FAM \{ .DOCHEADER_FAMILY \\*[$DOC_FAM] \} . if !d$TITLE_FAM \{\ . ie !d$DOCHEADER_FAM \{ .TITLE_FAMILY \\*[$DOC_FAM] \} @@ -4778,22 +4841,22 @@ y\\R'#DESCENDER \\n[.cdp]' . el \{ .SUBTITLE_FAMILY \\*[$DOCHEADER_FAM] \} . \} . if !d$SUBTITLE_FT \{ .SUBTITLE_FONT R \} -. if !d$SUBTITLE_SIZE_CHANGE \{ .SUBTITLE_SIZE +0 \} +. 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_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 \} -\# +Headers and footers +. if !d$DOCTYPE_FT \{ .DOCTYPE_FONT BI \} +. if !d$DOCTYPE_SIZE_CHANGE \{ .DOCTYPE_SIZE +3 \} +.\" +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_FT \{ .HDRFTR_LEFT_FONT R \} . if \\n[#HDRFTR_LEFT_CAPS] \{\ . if !d$HDRFTR_LEFT_SIZE_CHANGE \{ .HDRFTR_LEFT_SIZE -2 \} . \} @@ -4810,47 +4873,47 @@ y\\R'#DESCENDER \\n[.cdp]' . if !d$HDRFTR_RIGHT_SIZE_CHANGE \{ .HDRFTR_RIGHT_SIZE -2 \} . \} . if !d$HDRFTR_RIGHT_SIZE_CHANGE \{ .HDRFTR_RIGHT_SIZE -.5 \} -\# +Heads +.\" +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 +.\" +Subheads . if !d$SH_FAM \{ .SUBHEAD_FAMILY \\*[$DOC_FAM] \} . if !d$SH_FT \{ .SUBHEAD_FONT B \} . if !d$SH_SIZE_CHANGE \{ .SUBHEAD_SIZE +.5 \} -\# +Paragraph heads +.\" +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 \} -\# +Quotes +.\" +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 \{ .QUOTE_INDENT 3 \} -\# +Blockquotes +.\" +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 \} -\# +Epigraphs +.\" +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 \{ .EPIGRAPH_INDENT 3 \} -\# +Linebreaks +.\" +Linebreaks . if !d$LINEBREAK_CHAR \{ .LINEBREAK_CHAR * 3 3p \} -\# +Footnotes +.\" +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 \} -\# +Endnotes +.\" +Endnotes . if !r#EN_PS \{ .ENDNOTE_PT_SIZE \\n[#DOC_PT_SIZE]u \} -. if !d$EN_LEAD \{ .ENDNOTE_LEAD 14 ADJUST \} . 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 \} @@ -4858,34 +4921,54 @@ y\\R'#DESCENDER \\n[.cdp]' . if !d$EN_NUMBER_FT \{ .ENDNOTE_NUMBER_FONT B \} . if !d$EN_NUMBER_SIZE_CHANGE \{ .ENDNOTE_NUMBER_SIZE +0 \} . if !r#EN_PP_INDENT \{ .ENDNOTE_PARA_INDENT 1.5m \} -\# +Table of contents +.\" +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 \} +.\" +Table of contents . if !d$TOC_FAM \{ .TOC_FAMILY \\*[$DOC_FAM] \} . if !r#TOC_PS \{ .TOC_PT_SIZE \\n[#DOC_PT_SIZE]u \} . if !r#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_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_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_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_PH_FT \{ .TOC_PARAHEAD_FONT I \} -. if !d$TOC_TITLE_SIZE_CHANGE \{ .TOC_TITLE_SIZE +.5 \} -. if !d$TOC_PN_SIZE_CHANGE \{ .TOC_PN_SIZE +0 \} -. if !d$TOC_HEAD_SIZE_CHANGE \{ .TOC_HEAD_SIZE +.5 \} +. 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_PH_FT \{ .TOC_PARAHEAD_FONT I \} +. if !d$TOC_TITLE_SIZE_CHANGE \{ .TOC_TITLE_SIZE +.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_PH_SIZE_CHANGE \{ .TOC_PARAHEAD_SIZE +0 \} +. if !d$TOC_PH_SIZE_CHANGE \{ .TOC_PARAHEAD_SIZE +0 \} +. \} +.\" +Refer support +. if !r#ENDNOTE_REFS \{ .nr #FN_REFS 1 \} +. if '\\*[$REF_FN_INDENT]'' \{\ +. if \\n[#PRINT_STYLE]=1 \{ .INDENT_REFS FOOTNOTE 2m \} +. if \\n[#PRINT_STYLE]=2 \{ .INDENT_REFS FOOTNOTE 1.5m \} . \} +. if '\\*[$REF_EN_INDENT]'' \{\ +. if \\n[#PRINT_STYLE]=1 \{ .INDENT_REFS ENDNOTE 2m \} +. if \\n[#PRINT_STYLE]=2 \{ .INDENT_REFS ENDNOTE 1.5m \} +. \} +. if '\\*[$REF_BIB_INDENT]'' \{\ +. if \\n[#PRINT_STYLE]=1 \{ .INDENT_REFS BIBLIO 2m \} +. if \\n[#PRINT_STYLE]=2 \{ .INDENT_REFS BIBLIO 1.5m :\} +. \} +.\" Adjust doc leading for PRINTSTYLE TYPESET . if \\n[#PRINT_STYLE]=2 \{\ . ie \\n[#ADJ_DOC_LEAD]=1 \{ .DOC_LEAD_ADJUST \} . el \{ . \} . \} -\# This diversion is to get a value for #FN_AUTOLEAD +.\" This diversion is to get a value for #FN_AUTOLEAD . di NULL . ev NULL . if \\n[#PRINT_STYLE]=1 \{\ @@ -4902,29 +4985,43 @@ y\\R'#DESCENDER \\n[.cdp]' . ev . di . ie !\\n[#COLLATE] \{\ +.\" DOC_LEAD adjusted (or not) here . TRAPS . rr #DOC_LEAD_ADJUST_OFF -\# Endnote and toc leading +.\" Endnote, bibliography and toc leading . nr #OK_PROCESS_LEAD 1 . nr #RESTORE_DOC_LEAD \\n(.v . nr #RESTORE_B_MARGIN \\n[#B_MARGIN] . if \\n[#PRINT_STYLE]=1 \{\ . ie \\n[#SINGLE_SPACE] \{\ . ENDNOTE_LEAD 12 ADJUST +. BIBLIOGRAPHY_LEAD 12 ADJUST . \} . el \{\ . ie \\n[#EN_SINGLESPACE] \{ .ENDNOTE_LEAD 12 ADJUST \} . el \{ .ENDNOTE_LEAD 24 ADJUST \} +. ie \\n[#BIB_SINGLESPACE] \{ .BIBLIOGRAPHY_LEAD 12 ADJUST \} +. el \{ .BIBLIOGRAPHY_LEAD 24 ADJUST \} . \} . \} . if \\n[#PRINT_STYLE]=2 \{\ . ie !d$EN_LEAD \{ .ENDNOTE_LEAD 14 ADJUST \} . el \{ .ENDNOTE_LEAD \\*[$EN_LEAD] \\*[$ADJUST_EN_LEAD] \} +. ie !d$BIB_LEAD \{ .BIBLIOGRAPHY_LEAD 14 ADJUST \} +. el \{ .BIBLIOGRAPHY_LEAD \\*[$BIB_LEAD] \\*[$ADJUST_BIB_LEAD] \} . ie !d$TOC_LEAD \{ .TOC_LEAD \\n[#RESTORE_DOC_LEAD]u \} . el \{ .TOC_LEAD \\*[$TOC_LEAD] \\*[$ADJUST_TOC_LEAD] \} . rm $ADJUST_EN_LEAD +. rm $ADJUST_BIB_LEAD . rm $ADJUST_TOC_LEAD . \} +. ie !d$BIB_SPACE \{ .BIBLIOGRAPHY_SPACING 1v \} +. el \{\ +. if \\n[#DEFER_BIB_SPACING]=1 \{\ +. BIBLIOGRAPHY_SPACING \\*[$BIB_SPACE] +. rr #DEFER_BIB_SPACING +. \} +. \} . DOC_LEAD \\n[#RESTORE_DOC_LEAD]u . nr #B_MARGIN \\n[#RESTORE_B_MARGIN] . \} @@ -4996,7 +5093,7 @@ y\\R'#DESCENDER \\n[.cdp]' . PRINT \m[\\*[$COVER_AUTHOR_COLOR]]\\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]\m[] . \} . el \{ .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]] \} -. \} +.\} . \} . if \\n[#DOC_COVER]=1 \{\ . while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\ @@ -5004,7 +5101,7 @@ y\\R'#DESCENDER \\n[.cdp]' . PRINT \m[\\*[$DOC_COVER_AUTHOR_COLOR]]\\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]\m[] . \} . el \{ .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]] \} -. \} +.\} . \} . \} . el \{\ @@ -5013,7 +5110,7 @@ y\\R'#DESCENDER \\n[.cdp]' . PRINT \m[\\*[$AUTHOR_COLOR]]\\*[$AUTHOR_\\n+[#NEXT_AUTHOR]]\m[] . \} . el \{ .PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]] \} -. \} +.\} . \} .END \# @@ -5057,7 +5154,7 @@ y\\R'#DESCENDER \\n[.cdp]' . FT \\*[$TITLE_FT] . PT_SIZE \\*[$TITLE_PT_SIZE] . LS \\n[#DOCHEADER_LEAD]u -\# Chapter title only +.\" Chapter title only . ie '\\*[$CHAPTER]'' \{\ . ie !'\\*[$CHAPTER_TITLE]'' \{\ . if \\n[#PRINT_STYLE]=2 \{\ @@ -5078,7 +5175,7 @@ y\\R'#DESCENDER \\n[.cdp]' . el \{ .PRINT \\*[$CHAPTER_STRING] \} . \} . \} -\# Chapter string, possibly with a chapter title +.\" Chapter string, possibly with a chapter title . el \{\ . ie \\n[#TITLE_COLOR]=1 \{\ . PRINT \m[\\*[$TITLE_COLOR]]\\*[$CHAPTER_STRING] \\*[$CHAPTER]\m[] @@ -5216,8 +5313,8 @@ y\\R'#DESCENDER \\n[.cdp]' \# \# .MAC COVERTITLE END -. ie '\\$0'DOC_COVERTITLE' \{ .ds $DOC_COVER_TITLE \\$1\} -. el \{ .ds $COVER_TITLE \\$1\} +. ie '\\$0'DOC_COVERTITLE' .ds $DOC_COVER_TITLE \\$1 +. el .ds $COVER_TITLE \\$1 .END \# \# @@ -5320,7 +5417,7 @@ y\\R'#DESCENDER \\n[.cdp]' . nr #COLUMNS_WERE_ON 1 . rr #COLUMNS . \} -\# Doc cover +.\" Doc cover . ie '\\$0'DO_DOC_COVER' \{\ . if !r#DOC_COVER_START_POS \{\ . nr #DOC_COVER_START_POS \\n[#PAGE_LENGTH]/3 @@ -5519,10 +5616,10 @@ y\\R'#DESCENDER \\n[.cdp]' . PRINT \\*[$MISC_\\n+[#NEXT_MISC]] . br . \} -. \} +.\} . \} . \} -\# Cover +.\" Cover . el \{\ . if !r#COVER_START_POS \{\ . nr #COVER_START_POS \\n[#PAGE_LENGTH]/3 @@ -5721,7 +5818,7 @@ y\\R'#DESCENDER \\n[.cdp]' . PRINT \\*[$MISC_\\n+[#NEXT_MISC]] . br . \} -. \} +.\} . \} . \} . EOL @@ -5763,6 +5860,10 @@ y\\R'#DESCENDER \\n[.cdp]' . ab PRINTSTYLE missing . \} . nr #DOCS 1 +. if \\n[#LINENUMBERS]=1 \{\ +. NUMBER_LINES OFF +. nr #LINENUMBERS 2 +. \} . if \\n[#COLLATE] \{\ . COPYSTYLE \\*[$COPY_STYLE] . nr #HEADERS_ON \\n[#HEADER_STATE] @@ -5775,7 +5876,13 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . \} . DEFAULTS -\# Covers and doc covers +.\" 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] \} +.\" Covers and doc covers . if \\n[#DOC_COVERS]=1 \{\ . if \\n[#DOC_COVER]=1 \{\ . DO_DOC_COVER @@ -5800,9 +5907,9 @@ y\\R'#DESCENDER \\n[.cdp]' . rr #COVER_MISC . \} . \} -\# Collate related stuff +.\" Collate related stuff . ie \\n[#COLLATED_DOC]=1 \{\ -\# Collect TITLE for TOC. +.\" Collect TITLE for TOC. . nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ] . af #TOC_ENTRY_PN \\g[#PAGENUMBER] . ie \\n[#USER_SET_TITLE_ITEM] \{\ @@ -5837,9 +5944,9 @@ y\\R'#DESCENDER \\n[.cdp]' . 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. +.\" 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 \{\ @@ -5881,14 +5988,14 @@ y\\R'#DESCENDER \\n[.cdp]' . af #FIRST_DOC_TITLE_PN \\g[#PAGENUMBER] . nr #FIRST_DOC_TOC_PN_PADDING \\n[#TOC_PN_PADDING] . \} -\# End TITLE collection +.\" End TITLE collection . if \\n[#PRINT_PAGENUM_ON_PAGE_1] \{\ . sp |\\n[#HEADER_MARGIN]u . PRINT_PAGE_NUMBER . \} . rr #COLLATE . rr #PAGINATION_STATE -\# End collate stuff +.\" End collate stuff . ie \\n[#DOC_HEADER]=0 \{\ . PRINT \& . if \\n[#DOC_TYPE]=4 \{\ @@ -5918,7 +6025,7 @@ y\\R'#DESCENDER \\n[.cdp]' . el \{\ . if \\n[#PRINT_STYLE]=2 \{ .LS \\n[#DOC_LEAD]u\\*[$DOCHEADER_LEAD_ADJ] \} . nr #DOCHEADER_LEAD \\n[#LEAD] -\# Default +.\" Default . if \\n[#DOC_TYPE]=1 \{\ . PRINT \& . sp |\\n[#DOCHEADER_ADVANCE]u-1v @@ -5959,7 +6066,7 @@ y\\R'#DESCENDER \\n[.cdp]' . nr #NEXT_AUTHOR 0 1 . while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\ . PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]] -. \} +.\} . if \\n[#AUTHOR_LINES]=1 \{\ . ie \\n[#SINGLE_SPACE] \{ .RLD \\n[#DOC_LEAD]u \} . el \{ .ALD \\n[#DOC_LEAD]u/2u \} @@ -5989,7 +6096,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . ev . \} -\# Chapter +.\" Chapter . if \\n[#DOC_TYPE]=2 \{\ . PRINT \& . sp |\\n[#DOCHEADER_ADVANCE]u-1v @@ -6041,7 +6148,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . ev . \} -\# Named +.\" Named . if \\n[#DOC_TYPE]=3 \{\ . PRINT \& . sp |\\n[#DOCHEADER_ADVANCE]u-1v @@ -6082,7 +6189,7 @@ y\\R'#DESCENDER \\n[.cdp]' . nr #NEXT_AUTHOR 0 1 . while \\n[#AUTHORS]>\\n[#NEXT_AUTHOR] \{\ . PRINT \\*[$AUTHOR_\\n+[#NEXT_AUTHOR]] -. \} +.\} . if \\n[#AUTHOR_LINES]=1 \{\ . ie \\n[#SINGLE_SPACE] \{ .RLD \\n[#DOC_LEAD]u \} . el \{ .ALD \\n[#DOC_LEAD]u/2u \} @@ -6139,18 +6246,37 @@ y\\R'#DESCENDER \\n[.cdp]' . 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[#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 \} +. \} .END \# .MAC CLEANUP_DEFAULTS END . nr #START 1 -\# "Family" strings for docheader +.\" Family strings for docheader . rm $AUTHOR_FAM . rm $CHAPTER_TITLE_FAM . rm $DOCTYPE_FAM . rm $SUBTITLE_FAM . rm $TITLE_FAM -\# "Family" strings for cover +.\" Family strings for cover . rm $COVER_AUTHOR_FAM . rm $COVER_CHAPTER_TITLE_FAM . rm $COVER_COPYRIGHT_FAM @@ -6158,7 +6284,7 @@ y\\R'#DESCENDER \\n[.cdp]' . rm $COVER_LEAD_ADJ . rm $COVER_SUBTITLE_FAM . rm $COVER_TITLE_FAM -\# "Family" strings for doc cover +.\" Family strings for doc cover . rm $DOC_COVER_AUTHOR_FAM . rm $DOC_COVER_CHAPTER_TITLE_FAM . rm $DOC_COVER_COPYRIGHT_FAM @@ -6166,15 +6292,15 @@ y\\R'#DESCENDER \\n[.cdp]' . rm $DOC_COVER_LEAD_ADJ . rm $DOC_COVER_SUBTITLE_FAM . rm $DOC_COVER_TITLE_FAM -\# "Quad" args to copyright and misc +.\" Quad args to copyright and misc . rm $COVER_COPYRIGHT_QUAD . rm $COVER_MISC_QUAD . rm $DOC_COVER_COPYRIGHT_QUAD . rm $DOC_COVER_MISC_QUAD -\# Miscellaneous strings +.\" Miscellaneous strings . rm $TOC_TITLE_ITEM . rm $DOCHEADER_LEAD_ADJ -\# Various registers +.\" Various registers . rr #ADJ_DOC_LEAD . rr #ADVANCE_FROM_TOP . rr #AUTHOR_NUM @@ -6408,18 +6534,19 @@ y\\R'#DESCENDER \\n[.cdp]' .MAC PROCESS_SHIM END . while \\n+[#LEGAL_BASELINE]<\\n[#CURRENT_V_POS] \{\ . -. \} +.\} . nr #SHIM \\n[#LEGAL_BASELINE]-\\n[#CURRENT_V_POS] .END \# +\# .MAC SHIM END -. nr #CURRENT_V_POS \\n(.d . nr #LEGAL_BASELINE \\n[#T_MARGIN]-1v \\n[#DOC_LEAD] +. 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-[#LEGAL_BASELINE]>\\n[#CURRENT_V_POS] \{\ . -. \} +.\} . nr #LEGAL_BASELINE +\\n[#DOC_LEAD] . nr #SHIM \\n[#LEGAL_BASELINE]-\\n[#CURRENT_V_POS] . \} @@ -6431,6 +6558,7 @@ y\\R'#DESCENDER \\n[.cdp]' . PROCESS_SHIM . \} . ALD \\n[#SHIM]u +. rr #CURRENT_V_POS .END \# \# @@ -6587,6 +6715,10 @@ y\\R'#DESCENDER \\n[.cdp]' .MAC EPIGRAPH END . nr #PP_STYLE 2 . nr #Q_PP 0 +. if \\n[#LINENUMBERS]=1 \{\ +. NUMBER_LINES OFF +. nr #LINENUMBERS 2 +. \} . if \\n[#START] \{\ . if \\n[#PRINT_STYLE]=1 \{\ . if \\n[#AUTHOR_LINES]=1 \{ .ALD \\n[#DOC_LEAD]u \} @@ -6743,7 +6875,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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]=2 \{\ . RLD \\n[#DOC_LEAD]u . if \\n[#EPI_WHITESPACE]<\\n[#DOC_LEAD] \{\ @@ -6760,7 +6892,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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 \} . \} @@ -6778,12 +6910,12 @@ y\\R'#DESCENDER \\n[.cdp]' . 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]) . 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 \} . \} @@ -6832,7 +6964,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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 \{\ @@ -6856,7 +6988,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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] \{\ @@ -6884,6 +7016,10 @@ y\\R'#DESCENDER \\n[.cdp]' . mk dc . \} . \} +. if \\n[#LINENUMBERS]=2 \{\ +. NUMBER_LINES RESUME +. nr #LINENUMBERS 1 +. \} .END \# \# ==================================================================== @@ -7249,21 +7385,23 @@ y\\R'#DESCENDER \\n[.cdp]' \# Creates or modifies register #SWITCH_HDRFTR, used to switch \# default location of HDRFTR_LEFT and HDRFTR_RIGHT. \# *Notes: -\# Typically, the author string appears at the left of header/footers, -\# and the title string appears at the right. This switches the -\# location of the two. Useful in conjuction with RECTO_VERSO to -\# tweak switches on alternate pages to come out as the user wishes. -\# The assumption of RECTO_VERSO is that the first page of the document -\# (recto) is odd, and even though it has no header/footer, if it did have one, -\# it would print as AUTHOR...CENTER...TITLE (or whatever strings -\# the user has supplied for HDRFTR_LEFT/RIGHT), meaning that the -\# next page, which does have a header/footer, will come out as -\# TITLE...CENTER...AUTHOR (or whatever strings the user has -\# supplied for HDRFTR_LEFT/RIGHT). SWITCH_HDRFTRS allows the user -\# to get the desired string in the desired place on the desired -\# recto/verso page. \# -\# Default is OFF. +.ig +Typically, the author string appears at the left of header/footers, +and the title string appears at the right. This switches the +location of the two. Useful in conjuction with RECTO_VERSO to tweak +switches on alternate pages to come out as the user wishes. The +assumption of RECTO_VERSO is that the first page of the document +(recto) is odd, and even though it has no header/footer, if it did +have one, it would print as AUTHOR...CENTER...TITLE (or whatever +strings the user has supplied for HDRFTR_LEFT/RIGHT), meaning that +the next page, which does have a header/footer, will come out as +TITLE...CENTER...AUTHOR (or whatever strings the user has supplied +for HDRFTR_LEFT/RIGHT). SWITCH_HDRFTRS allows the user to get the +desired string in the desired place on the desired recto/verso page. + +Default is OFF. +.. \# .MAC SWITCH_HDRFTR END . ie '\\$1'' \{ .nr #SWITCH_HDRFTR 1 \} @@ -7715,6 +7853,7 @@ y\\R'#DESCENDER \\n[.cdp]' \# comprehensible. \# .MAC HEADER END +. MNtop . rr #FROM_FOOTER . nr #FROM_HEADER 1 . nr #LAST_FN_COUNT_FOR_COLS \\n[#FN_COUNT_FOR_COLS] @@ -7759,7 +7898,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . if \\n[#PRINT_STYLE]=1 \{\ . if \\n[#ENDNOTES]=1 \{\ -\# Single-spaced endotes have a different lead +.\" Single-spaced endotes have a different lead . if \\n[#EN_SINGLESPACE] \{\ . nr #RESTORE_DOC_LEAD \\n[#DOC_LEAD] . nr #DOC_LEAD \\n[#EN_LEAD]u @@ -7809,6 +7948,7 @@ y\\R'#DESCENDER \\n[.cdp]' . nr #Q_OFFSET \\n[#L_MARGIN]+(\\n[#PP_INDENT]*\\n[#Q_OFFSET_VALUE]) . po \\n[#Q_OFFSET]u . \} +. ALD \\n[#Q_LEAD_DIFF]u . \} . if \\n[#EPIGRAPH] \{\ . ie \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \} @@ -7859,6 +7999,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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 \\n[#PRINT_STYLE]=1 \{\ . if \\n[#SLANT_ON] \{\ @@ -7870,6 +8011,24 @@ y\\R'#DESCENDER \\n[.cdp]' . if !\\n[#FN_DEPTH] \{\ . if r#DIVERTED \{ .rr #DIVERTED \} . \} +. if \\n[#MN_OVERFLOW_LEFT]=1 \{\ +. MN LEFT +. nf +. MN_OVERFLOW_LEFT +. MN +. \} +. if \\n[#MN_OVERFLOW_RIGHT]=1 \{\ +. MN RIGHT +. nf +. MN_OVERFLOW_RIGHT +. MN +. \} +. rm MN_OVERFLOW_LEFT +. rr #MN_OVERFLOW_LEFT +. rr #no-repeat-MN-left +. rm MN_OVERFLOW_RIGHT +. rr #MN_OVERFLOW_RIGHT +. rr #no-repeat-MN-right .END \# \# ==================================================================== @@ -7942,29 +8101,40 @@ y\\R'#DESCENDER \\n[.cdp]' \# FINAL respects PAGENUMBER. \# .MAC FOOTER END -. ev PAGE_BOTTOM +. ev PAGE_TRANSITION +. if \\n[MN-left]>0 \{\ +. if !\\n[#no-repeat-MN-left]=1 \{\ +. MNbottom-left +. nr #no-repeat-MN-left 1 +. \} +. if '\\n(.z'MN_OVERFLOW_LEFT' \{\ +. di +. nr #MN_OVERFLOW_LEFT 1 +. rr #OVERFLOW_LEFT +. \} +. \} +. if \\n[MN-right]>0 \{\ +. if (\\n[MN-right] > 0) \{\ +. if !\\n[#no-repeat-MN-right]=1 \{\ +. MNbottom-right +. \} +. \} +. if '\\n(.z'MN_OVERFLOW_RIGHT' \{\ +. di +. nr #MN_OVERFLOW_RIGHT 1 +. rr #OVERFLOW_RIGHT +. \} +. \} +. ch MN_OVERFLOW_TRAP . nr #SAVED_LEAD \\n(.v -\# I can't figure out why I thought I needed this next bit, but I'm -\# leaving it in, commented out, in case I (re)discover what it was -\# there for. -\# -\#.if \\n[#START]=1 \{\ -\#.bp -\#.ev -\#.rr #START -\#.return -\#.\} . nr #L_MARGIN_DIFF \\n[#L_MARGIN]-\\n[#DOC_L_MARGIN] . if !\\n[#FN_DEFER] \{\ . nr #DIVER_DEPTH 0 . if \\n[#FN_DEPTH] \{\ -\# #DIVERTED=2 doesn't seem to have a use anymore, but I'm leaving -\# this in, commented out, in case I discover why I thought I needed -\# it. -\# -\#.if \\n[#DIVERTED]=2 \{ .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) +. vpt 1 . po \\n[#DOC_L_MARGIN]u . if \\n[#COLUMNS] \{\ . po \\n[#COL_\\n[#COL_NUM]_L_MARGIN]u @@ -7974,6 +8144,7 @@ y\\R'#DESCENDER \\n[.cdp]' . nf . FOOTNOTES . rm FOOTNOTES +. if dRUNON_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' \{\ @@ -7996,13 +8167,6 @@ y\\R'#DESCENDER \\n[.cdp]' . el \{ .sp |\\n(dcu \} . po \\n[#COL_\\n+[#COL_NUM]_L_MARGIN]u . nr #L_MARGIN \\n(.o -\# #DIVERTED=2 doesn't seem to have a use anymore, but I'm leaving -\# this in, commented out, in case I discover why I thought I needed -\# it. -\# -\# Reverse the sense of #DIVERTED=2 (from above) if moving col to col -\#.if \\n[#DIVERTED]=2 \{ .nr #FN_DEPTH +\\n[#VFP_DIFF] \} -\# . if \\n[#FN_DEPTH] \{ .PROCESS_FN_LEFTOVER \} . LS \\n[#SAVED_LEAD]u . if \\n[#PREV_FN_DEFERRED] \{\ @@ -8018,6 +8182,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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 \} . \} . rr #DEFER_SPACE_ADDED . if \\n[#TAB_ACTIVE] \{ .TAB \\n[#CURRENT_TAB] \} @@ -8066,16 +8231,19 @@ y\\R'#DESCENDER \\n[.cdp]' \# Resets CAPS and UNDERLINE if they were on. \# .MAC DO_FOOTER END -\# 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. -. ch FN_OVERFLOW_TRAP 20i +.\" 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 \} +. rr #SAVED_FOOTER_POS . ie (\\n[#FOOTER_MARGIN]+\\n(.v)>\\n[#B_MARGIN] \{\ . nr #SKIP_FOOTER 1 . \} . el \{\ +. vpt 0 . sp |\\n[#PAGE_LENGTH]u-\\n[#FOOTER_MARGIN]u-1v . mk y +. vpt 1 . \} . ev FOOTER . po \\n[#DOC_L_MARGIN]u @@ -8117,9 +8285,10 @@ y\\R'#DESCENDER \\n[.cdp]' . rr #UNDERLINE_WAS_ON . \} . ev -. ch FN_OVERFLOW_TRAP -(\\n[#FN_OVERFLOW_TRAP_POS]u) . rr #SAVED_LEAD . bp +.\" This ev pops the PAGE_TRANSITION environment still active at the +.\" end of HEADER . ev .END \# @@ -8309,7 +8478,7 @@ y\\R'#DESCENDER \\n[.cdp]' \# .MAC HEAD END . br -\# Collect head for TOC. +.\" Collect head for TOC. . nr #ARG_NUM 0 1 . nr #TOC_ENTRY_PN \\n%+\\n[#PAGE_NUM_ADJ] . af #TOC_ENTRY_PN \\g[#PAGENUMBER] @@ -8318,8 +8487,8 @@ y\\R'#DESCENDER \\n[.cdp]' . as $TOC_HEAD_ITEM \\$[\\n+[#ARG_NUM]]\\| . \} . el \{\ -\# Note that in the .as lines, below, \ at the end has a literal -\# space after it. +.\" 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]]\ @@ -8333,10 +8502,10 @@ y\\R'#DESCENDER \\n[.cdp]' . 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. +.\} +.\" 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 \{\ @@ -8372,8 +8541,8 @@ y\\R'#DESCENDER \\n[.cdp]' \!. TQ . di . ev -\# End collection of head for TOC -\# Process head +.\" End collection of head for TOC +.\" Process head . nr #HEAD 1 . ev HEAD . ll \\n[#L_LENGTH]u @@ -8397,10 +8566,10 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . if r#QUOTE \{ .rr #QUOTE \} . if r#EPIGRAPH \{ .rr #EPIGRAPH \} -. if \\n[#PRINT_STYLE]=1 \{ .ne 3 \} +. if \\n[#PRINT_STYLE]=1 \{ .ne \\n[#NUM_ARGS]+2 \} . if \\n[#PRINT_STYLE]=2 \{\ -. ie \\n[#HEAD_SPACE] \{ .ne 4 \} -. el \{ .ne 3 \} +. ie \\n[#HEAD_SPACE] \{ .ne \\n[#NUM_ARGS]+3 \} +. el \{ .ne \\n[#NUM_ARGS]+2 \} . \} . ie \\n[#START] \{\ . if \\n[#DOC_HEADER]=0 \{ .RLD 1v \} @@ -8440,7 +8609,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . \} . \} -\# Print head +.\" Print head . nr #ARG_NUM 0 1 . if \\n[#HEAD_CAPS] \{ .CAPS \} . if \\n[#PRINT_STYLE]=2 \{\ @@ -8472,7 +8641,7 @@ y\\R'#DESCENDER \\n[.cdp]' . el \{ .UNDERSCORE "\\$[\\n+[#ARG_NUM]]\} . br . \} -. \} +.\} . REMOVE_INDENT . CAPS OFF . ev @@ -8511,7 +8680,7 @@ y\\R'#DESCENDER \\n[.cdp]' \# .MAC SUBHEAD END . br -\# Collect subhead for TOC. +.\" 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] \{\ @@ -8519,8 +8688,8 @@ y\\R'#DESCENDER \\n[.cdp]' . as $TOC_SH_ITEM \\$[\\n+[#ARG_NUM]]\\| . \} . el \{\ -\# Note that in the .as lines, below, \ at the end has a literal -\# space after it. +.\" 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]]\ @@ -8534,10 +8703,10 @@ y\\R'#DESCENDER \\n[.cdp]' . 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. +.\} +.\" 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 \{\ @@ -8573,8 +8742,8 @@ y\\R'#DESCENDER \\n[.cdp]' \!. TQ . di . ev -\# End collection of head for TOC -\# Process subhead +.\" End collection of head for TOC +.\" Process subhead . nr #ARG_NUM 0 1 . if r#QUOTE \{ .rr #QUOTE \} . if r#Q_AT_TOP \{ .rr #Q_AT_TOP \} @@ -8603,7 +8772,7 @@ y\\R'#DESCENDER \\n[.cdp]' . if \\n[#PRINT_STYLE]=2 \{ .nr #SH_LEAD_ADJUST \\n[#LEAD]/8 \} . ie \\n[#START] \{ .RLD 1v \} . el \{\ -. ie ( \\n[#TRAP_DISTANCE] < \\n[#DOC_LEAD]*2 ) \{\ +. ie ( \\n[#TRAP_DISTANCE] < (\\n[#DOC_LEAD]*(\\n[#NUM_ARGS]+1)) ) \{\ . ie \\n[#COLUMNS] \{ .COL_NEXT \} . el \{ .bp \} . \} @@ -8625,7 +8794,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . \} . \} -\# Print subhead +.\" Print subhead . if \\n[#PRINT_STYLE]=1 \{\ . while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\ . ie \\n[#NUMBER_SH] \{\ @@ -8653,7 +8822,7 @@ y\\R'#DESCENDER \\n[.cdp]' . UNDERSCORE "\v'-\\n[#SH_LEAD_ADJUST]u'\\$[\\n+[#ARG_NUM]] . br . \} -. \} +.\} . \} . if \\n[#PRINT_STYLE]=1 \{\ . if \\n[#SINGLE_SPACE] \{ .ALD \\n[#DOC_LEAD]u \} @@ -8686,7 +8855,7 @@ y\\R'#DESCENDER \\n[.cdp]' . PRINT "\\v'-\\n[#SH_LEAD_ADJUST]u'\\$[\\n+[#ARG_NUM]] . br . \} -. \} +.\} . \} . el \{\ . ALD \\n[#DOC_LEAD]u @@ -8695,7 +8864,7 @@ y\\R'#DESCENDER \\n[.cdp]' . if \\n[#EPIGRAPH] \{ .RLD \\n[#DOC_LEAD]u \} . while \\n[#ARG_NUM]<\\n[#NUM_ARGS] \{\ . PRINT "\\$[\\n+[#ARG_NUM]] -. \} +.\} . ALD \\n[#DOC_LEAD]u . \} . \} @@ -8739,7 +8908,7 @@ y\\R'#DESCENDER \\n[.cdp]' \# PARAHEAD *must* come after PP. \# .MAC PARAHEAD END -\# Collect parahead for TOC. +.\" 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\\| @@ -8783,8 +8952,8 @@ y\\R'#DESCENDER \\n[.cdp]' \!. TQ . di . ev -\# End collection of parahead for TOC -\# Process parahead +.\" End collection of parahead for TOC +.\" Process parahead . if \\n[#SLANT_ON] \{\ . nr #SLANT_WAS_ON 1 \E*[SLANTX] @@ -8903,7 +9072,7 @@ y\\R'#DESCENDER \\n[.cdp]' . while \\$2>\\n[#REPEAT] \{\ . as $LINEBREAK_CHAR "\\ \\$1 . nr #REPEAT \\n[#REPEAT]+1 -. \} +.\} . rr #REPEAT .END \# @@ -9051,7 +9220,7 @@ y\\R'#DESCENDER \\n[.cdp]' . 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 @@ -9233,6 +9402,24 @@ y\\R'#DESCENDER \\n[.cdp]' .END \# \# +\# QUOTE_AUTOLEAD +\# -------------- +\# *Arguments: +\# +\# *Function: +\# 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 \} +.END +\# +.ALIAS BLOCKQUOTE_AUTOLEAD QUOTE_AUTOLEAD +.ALIAS ENDNOTE_QUOTE_AUTOLEAD QUOTE_AUTOLEAD +.ALIAS ENDNOTE_BLOCKQUOTE_AUTOLEAD QUOTE_AUTOLEAD +\# \# ALWAYS FULLSPACE QUOTES \# ----------------------- \# *Arguments: @@ -9262,12 +9449,25 @@ y\\R'#DESCENDER \\n[.cdp]' \# .MAC QUOTE END . br +. if \\n[#LINENUMBERS]=1 \{\ +. nr #LINENUMBERS 2 +. nr #NEXT_LN \\n(ln +. nm +. \} . ie '\\$1'' \{\ . ev QUOTE +. if \\n[#LINENUMBERS]=2 \{\ +. if \\n[#SILENT_QUOTE_LN]=1 \{ .nm \\n[#NEXT_LN] 1000 -4 \} +. \} . nr #IN_DIVER 1 . nr #QUOTE 1 . di P_QUOTE . ll \\n[#L_LENGTH]u-(\\n[#PP_INDENT]u*\\n[#Q_OFFSET_VALUE]u) +. if \\n[#LINENUMBERS]=2 \{\ +. if \\n[#QUOTE_LN]=1 \{\ +. nm \\n(ln "" \\*[$Q_LN_GUTTER] -3-\\*[$Q_LN_GUTTER] +. \} +. \} . ta \\n(.lu . if \\n[#COLUMNS] \{\ . ll \\n[#COL_L_LENGTH]u-(\\n[#PP_INDENT]u*\\n[#Q_OFFSET_VALUE]u) @@ -9282,7 +9482,20 @@ y\\R'#DESCENDER \\n[.cdp]' . FAMILY \\*[$QUOTE_FAM] . FT \\*[$QUOTE_FT] . PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$QUOTE_SIZE_CHANGE] -. LS \\n[#DOC_LEAD]u +. ie !r#Q_AUTOLEAD \{ .LS \\n[#Q_LEAD]u \} +. el \{\ +. AUTOLEAD \\n[#Q_AUTOLEAD] +. 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 \} +. el \{\ +. AUTOLEAD \\n[#EN_Q_AUTOLEAD] +. nr #EN_Q_LEAD \\n(.v +. \} +. \} +. nr #Q_LEAD_REAL \\n(.v . LEFT . if \\n[#QUOTE_COLOR]=1 \{\ . nf @@ -9290,6 +9503,15 @@ y\\R'#DESCENDER \\n[.cdp]' . EOL . \} . \} +. 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] +. \} +. el \{\ +. if !\\n[#SILENT_QUOTE_LN] \{ .NUMBER_LINES OFF \} +. \} +. \} . nr #Q_TOP \\n(nl . if \\n[#PRINT_STYLE]=1 \{\ . if \\n[#UNDERLINE_QUOTES] \{\ @@ -9308,7 +9530,7 @@ y\\R'#DESCENDER \\n[.cdp]' \# | \# *Function: \# Indents quoted text in fill mode and shortens line length -\# accordingly, or turns BLOCKQUOTE off. +\# equivalently, or turns BLOCKQUOTE off. \# *Notes: \# Owing to the need to bottom align TYPESET pages, quoted text gets \# diverted so its depth can be measured (in DO_QUOTE) for determining @@ -9319,8 +9541,16 @@ y\\R'#DESCENDER \\n[.cdp]' \# .MAC BLOCKQUOTE END . br +. if \\n[#LINENUMBERS]=1 \{\ +. nr #LINENUMBERS 2 +. nr #NEXT_LN \\n(ln +. nm +. \} . ie '\\$1'' \{\ . ev BLOCKQUOTE +. if \\n[#LINENUMBERS]=2 \{\ +. if \\n[#SILENT_BQUOTE_LN]=1 \{ .nm \\n[#NEXT_LN] 1000 -4 \} +. \} . nr #IN_DIVER 1 . nr #QUOTE 2 . nr #PP_STYLE 2 @@ -9351,7 +9581,7 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . if \\n[#PRINT_STYLE]=1 \{\ . TYPEWRITER -. vs \\n[#DOC_LEAD]u +. vs \\n[#DOC_LEAD]u . QUAD LEFT . HY OFF . \} @@ -9359,10 +9589,20 @@ y\\R'#DESCENDER \\n[.cdp]' . FAMILY \\*[$BQUOTE_FAM] . FT \\*[$BQUOTE_FT] . PT_SIZE \\n[#DOC_PT_SIZE]u\\*[$BQUOTE_SIZE_CHANGE] -. LS \\n[#DOC_LEAD]u +. ie !\\n[#BQ_AUTOLEAD] \{ .LS \\n[#BQ_LEAD]u \} +. el \{\ +. AUTOLEAD \\n[#BQ_AUTOLEAD] +. 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 \} +. el \{\ +. AUTOLEAD \\n[#EN_BQ_AUTOLEAD] +. nr #EN_BQ_LEAD \\n(.v +. \} . \} +. nr #Q_LEAD_REAL \\n(.v . if \\n[#BQUOTE_COLOR]=1 \{\ . nf \m[\\*[$BQUOTE_COLOR]] @@ -9373,6 +9613,15 @@ y\\R'#DESCENDER \\n[.cdp]' . HY_SET 1 \\n[#DIVERSIONS_HY_MARGIN]u (\\n[#PT_SIZE]u/1000u/8u)p . hy 14 . \} +. 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] +. \} +. el \{\ +. if !\\n[#SILENT_BQUOTE_LN] \{ .NUMBER_LINES OFF \} +. \} +. \} . nr #Q_TOP \\n(nl . if \\n[#INDENT_FIRST_PARAS] \{\ . ie !\\n[#ENDNOTE] \{\ @@ -9406,6 +9655,10 @@ y\\R'#DESCENDER \\n[.cdp]' \# .MAC DO_QUOTE END . br +. if \\n[#DIVER_LN_OFF] \{\ +\!. NUMBER_LINES OFF +. rr #DIVER_LN_OFF +. \} . di . rr #IN_DIVER . if \\n[#RESET_FN_COUNTERS]=2 \{\ @@ -9420,11 +9673,20 @@ y\\R'#DESCENDER \\n[.cdp]' . nr #DONE_ONCE 0 1 . REMOVE_INDENT . ev +. nr #Q_DEPTH (\\n[#DIVER_DEPTH]-\\n[#Q_LEAD_REAL])+\\n[#LEAD] +. nr #Q_LEAD_DIFF \\n[#LEAD]-\\n[#Q_LEAD_REAL] +. SILENT +. br +. nf +. 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 . if \\n[#ENDNOTE] \{\ . nr #RESET_QUOTE_SPACING \\n[#FULLSPACE_QUOTES] . ALWAYS_FULLSPACE_QUOTES . \} -. nr #Q_DEPTH \\n[#DIVER_DEPTH]+(\\n[#LEAD]*1) . if \\n[#PRINT_STYLE]=1 \{\ . if \\n[#START]=1 \{ . \} . if \\n[#START]=0 \{\ @@ -9443,37 +9705,16 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . \} . el \{\ -. ie \\n[#Q_DEPTH]<\\n[#TRAP_DISTANCE] \{\ -. nr #Q_FITS 1 -. ie \\n[#HEAD]=1 \{ . \} +. ie \\n[#Q_DEPTH]<(\\n[#TRAP_DISTANCE]-1) \{\ +. ie (\\n[#TRAP_DISTANCE]-1)-\\n[#Q_DEPTH]<\\n[#DOC_LEAD] \{\ +. Q_NOFIT +. \} . el \{\ -. ie \\n[#START] \{ . \} -. el \{\ -. ie \\n[#FULLSPACE_QUOTES] \{\ -. ie \\n[#ENDNOTE] \{\ -. ALD \\n[#EN_LEAD]u -. \} -. el \{ .ALD \\n[#DOC_LEAD]u \} -. \} -. el \{\ -. ie \\n[#ENDNOTE] \{\ -. ALD \\n[#EN_LEAD]u/2u -. \} -. el \{ .ALD \\n[#DOC_LEAD]u/2u \} -. \} -. \} +. Q_FITS . \} -. if \\n[#DIVER_FN]=2 \{ .rr #DIVER_FN \} . \} . el \{\ -. rr #Q_FITS -. ie r#HEAD \{\ -. if \\n[#HEAD]=1 \{ . \} -. \} -. el \{\ -. ie \\n[#ENDNOTE] \{ .ALD \\n[#EN_LEAD]u \} -. el \{ .ALD \\n[#DOC_LEAD]u \} -. \} +. Q_NOFIT . \} . \} . \} @@ -9485,6 +9726,13 @@ y\\R'#DESCENDER \\n[.cdp]' . if \\n[#ENDNOTE] \{\ . in +\\n[#EN_PP_INDENT]u*\\n[#Q_OFFSET_VALUE]u . \} +. ie \\n[#START]=1 \{\ +. ie !\\n[#Q_LEAD_DIFF]<0 \{ .ALD \\n[#Q_SPACE_ADJ]u \} +. el \{ .RLD 0-\\n[#Q_LEAD_DIFF]u \} +. \} +. el \{\ +. ALD \\n[#Q_SPACE_ADJ]u +. \} . if \\n[#QUOTE]=1 \{\ . nf . P_QUOTE @@ -9499,32 +9747,57 @@ y\\R'#DESCENDER \\n[.cdp]' . \} . if \\n[#PRINT_STYLE]=2 \{\ . ie \\n[#START] \{\ -. ie \\n[#PP_SPACE] \{ . \} -. el \{ .ALD \\n[#DOC_LEAD]u \} +. ie \\n[#PP_SPACE] \{\ +. +. \} +. el \{\ +. ALD \\n[#DOC_LEAD]u +. SHIM +. \} . \} . el \{\ . ie \\n[#PP_SPACE] \{ . \} . el \{\ -. ie \\n[#HEAD]=1 \{ .ALD \\n[#DOC_LEAD]u \} +. ie \\n[#HEAD]=1 \{\ +. ALD \\n[#DOC_LEAD]u +. SHIM +. \} . el \{\ +. ie \\n[#FULLSPACE_QUOTES] \{\ +. ie \\n[#ENDNOTE] \{ .ALD \\n[#EN_LEAD]u \} +. el \{ .ALD \\n[#DOC_LEAD]u \} +. \} +. el \{ .ALD (\\n[#DOC_LEAD]u/2u) \} . ie \\n[#Q_FITS] \{\ . ie \\n[#Q_TOP]=\\n[#PAGE_TOP] \{\ . nr #Q_AT_TOP 1 -. ALD \\n[#DOC_LEAD]u +. nr #DELAY_SHIM 1 . \} -. el \{\ -. ie \\n[#FULLSPACE_QUOTES] \{ .ALD \\n[#DOC_LEAD]u \} -. el \{ .ALD \\n[#DOC_LEAD]u/2u \} +. el \{ .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]) \{\ +. PRINT \& +. br +. sp -1v-\\n[#Q_LEAD_DIFF]u . \} . \} -. el \{ .ALD \\n[#DOC_LEAD]u \} . \} . \} . \} . \} +. if \\n[#LINENUMBERS]=2 \{\ +. nr #LINENUMBERS 1 +. 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 r#HEAD \{ .rr #HEAD \} +. if r#EPIGRAPH \{ .rr #EPIGRAPH \} . rr #Q_PP . rr #LINEBREAK . nr #PP_STYLE 1 @@ -9556,6 +9829,88 @@ y\\R'#DESCENDER \\n[.cdp]' . ENDNOTE_PARA_INDENT \\n[#RESET_EN_PP_INDENT]u . QUAD \\*[EN_QUAD] . \} +. if r#DELAY_SHIM \{\ +. SHIM +. rr #DELAY_SHIM +. \} +.END +\# +\# +\# Utility macros for DO_QUOTE +\# --------------------------- +\# +.MAC Q_FITS END +. nr #Q_FITS 1 +. ie \\n[#HEAD]=1 \{\ +. ALD \\n[#Q_LEAD_DIFF]u +. \} +. el \{\ +. 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 \} +. \} +. 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 legal baseline of the page). +. ie \\n[#Q_TOP]=\\n[#PAGE_TOP] \{\ +. if \\n[#QUOTE]=1 \{\ +. rn P_QUOTE Q_TEMP +. di P_QUOTE +. vs \\n[#Q_LEAD]u +. PRINT \& +. sp -1v+\\n[#Q_LEAD_DIFF]u +. Q_TEMP +. di +. \} +. if \\n[#QUOTE]=2 \{\ +. rn B_QUOTE Q_TEMP +. di B_QUOTE +. vs \\n[#BQ_LEAD]u +. PRINT \& +. sp -1v+\\n[#Q_LEAD_DIFF]u +. Q_TEMP +. di +. \} +. rm Q_TEMP +. \} +. el \{\ +. ALD (\\n[#DOC_LEAD]u/2u)+\\n[#Q_LEAD_DIFF]u +. \} +. \} +. \} +. if \\n[#DIVER_FN]=2 \{ .rr #DIVER_FN \} +. \} +.END +\# +.MAC Q_NOFIT END +. rr #Q_FITS +. ie r#HEAD \{\ +. if \\n[#HEAD]=1 \{ . \} +. \} +. 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 \} +. \} +. 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 +.\" 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. +. nr #SAVED_FOOTER_POS \\n[#VARIABLE_FOOTER_POS] +. ch FOOTER \\n[#VARIABLE_FOOTER_POS]u+.25v +. \} .END \# \# ==================================================================== @@ -9609,7 +9964,6 @@ y\\R'#DESCENDER \\n[.cdp]' . if \\n[#QUOTE]=1 \{\ . nf . P_QUOTE -. if !\\n[#START] \{ .rr #QUOTE \} . \} . if \\n[#QUOTE]=2 \{\ . nf @@ -9803,6 +10157,10 @@ y\\R'#DESCENDER \\n[.cdp]' . 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] \} +. rr #BIB_FIRST_PAGE +. \} . if \\n[#TOC_FIRST_PAGE] \{\ . PAGENUMBER 1 . rr #TOC_FIRST_PAGE @@ -9856,13 +10214,14 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# \# +++FOOTNOTES+++ \# -\# 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. -\# -\# The macros are heavily commented. +.ig +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. + +The macros are heavily commented. +.. \# \# FOOTNOTE AUTOLEAD \# ----------------- @@ -9896,23 +10255,129 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# FOOTNOTE MARKER STYLE \# --------------------- \# *Arguments: -\# STAR | NUMBER +\# STAR | NUMBER | LINE \# *Function: \# Sets register #FN_MARKER_STYLE, used in FOOTNOTE to determine \# the style of footnote markers. \# *Notes: -\# 1=STAR; 2=NUMBER. Default is STAR. +\# 1=STAR; 2=NUMBER; 3=LINE. LINE means "use output line numbers". +\# Default is STAR. \# .MAC FOOTNOTE_MARKER_STYLE END . if '\\$1'STAR' \{\ +. if \\n[#FN_MARKER_STYLE]=3 \{\ +. if !\\n[#NEWPAGE]=1 \{\ +. 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. +. return +. \} +. \} +. if \\n[#RUN_ON]=1 \{\ +. 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 \} +. FOOTNOTE_MARKERS . \} . if '\\$1'NUMBER' \{\ +. if \\n[#FN_MARKER_STYLE]=3 \{\ +. if !\\n[#NEWPAGE]=1 \{\ +. 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. +. return +. \} +. \} +. if \\n[#RUN_ON]=1 \{\ +. 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 +. 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 \} +. \} . \} .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' +\# +\# +\# FOOTNOTE LINENUMBER SEPARATOR +\# ----------------------------- +\# *Argument: +\# +\# *Function: +\# Stores user-defined separator (for use then +\# FOOTNOTE_MARKER_STYLE is LINE) in string $FN_LN_SEP. The +\# separator is intended to be used when the user wishes a +\# separator, rather than the choice of brackets offered by +\# FOOTNOTE_LINENUMBER_BRACKETS. +\# +.MAC FOOTNOTE_LINENUMBER_SEPARATOR END +. rr #FN_LN_BRACKETS +. nr #FN_LN_SEP 1 +. ds $FN_LN_SEP "\\$1 +.END +\# +\# +\# FOOTNOTE LINENUMBER BRACKETS +\# ---------------------------- +\# *Argument: +\# PARENS | SQUARE | BRACES or ( | [ | { +\# *Function: +\# Sets register #FN_LN_BRACKETS to 1, and creates strings +\# $FN_OPEN_BRACKET and $FN_CLOSE_BRACKET according to the given +\# argument. +\# +.MAC FOOTNOTE_LINENUMBER_BRACKETS END +. rr #FN_LN_SEP +. nr #FN_LN_BRACKETS 1 +. if '\\$1'PARENS' \{\ +. ds $FN_OPEN_BRACKET ( +. ds $FN_CLOSE_BRACKET ) +. \} +. if '\\$1'(' \{\ +. ds $FN_OPEN_BRACKET ( +. ds $FN_CLOSE_BRACKET ) +. \} +. if '\\$1'SQUARE' \{\ +. ds $FN_OPEN_BRACKET [ +. ds $FN_CLOSE_BRACKET ] +. \} +. if '\\$1'[' \{\ +. ds $FN_OPEN_BRACKET [ +. ds $FN_CLOSE_BRACKET ] +. \} +. if '\\$1'BRACES' \{\ +. ds $FN_OPEN_BRACKET { +. ds $FN_CLOSE_BRACKET } +. \} +. if '\\$1'{' \{\ +. ds $FN_OPEN_BRACKET { +. ds $FN_CLOSE_BRACKET } +. \} +.END +\# +\# \# RESET FOOTNOTE NUMBER \# --------------------- \# *Arguments: @@ -9978,7 +10443,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \!. PT_SIZE 12 . RLD 1v . LEFT -. PRINT \\v'-\\n[#FN_RULE_ADJ]u'\\l'\\n[#FN_RULE_LENGTH]u'\\v'+\\n[#FN_RULE_ADJ]u' +. PRINT \v'-\\n[#FN_RULE_ADJ]u'\l'\\n[#FN_RULE_LENGTH]u'\v'+\\n[#FN_RULE_ADJ]u' \!. PT_SIZE \\n[#DOC_PT_SIZE]u\\*$[FN_SIZE_CHANGE] . QUAD \\*[$FN_QUAD] . \} @@ -9989,10 +10454,76 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .END \# \# +\# FOOTNOTE SPACING +\# ---------------- +\# *Arguments: +\# | +\# *Function: +\# Enables printing of post footnote spacing. +\# *Notes: +\# Default is no space. +\# +.MAC FOOTNOTE_SPACING END +. ie \B'\\$1' \{ .nr #FN_SPACE (\\$1) \} +. el \{ .nr #FN_SPACE 0 \} +.END +\# +\# +\# RUN ON FOOTNOTES +\# ---------------- +\# *Arguments: +\# | +\# *Function: +\# Toggles run-on footnotes on or off. +\# +.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 " 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 \} +. \} +. 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 " you to loose footnotes already formatted for this page. +. tm1 " Ignoring request FOOTNOTES_RUN_ON \\$1. +. return +. \} +. \} +. rr #RUN_ON +. \} +.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 " 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 " 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 +. \} +.END +\# \# FOOTNOTE \# -------- \# *Arguments: -\# | INDENT L|LEFT|R|RIGHT|B|BOTH > | +\# | INDENT L|LEFT|R|RIGHT|B|BOTH | \# *Function: \# Begins collecting and diverting footnote text if no argument \# given. Otherwise, ends diversion FOOTNOTES, measures footnote @@ -10008,14 +10539,52 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# for each footnote the user wants indented. \# .MAC FOOTNOTE END +. if !\\n(.u \{ .nr #ADD_BREAK 1 \} . ie '\\$1'' \{\ -\# Begin processing footnotes that occur inside QUOTE, BLOCKQUOTE -\# or EPIGRAPH. +. if \\n[#FN_MARKER_STYLE]=3 \{\ +. 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. +. \} +. 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[#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 " for QUOTES. Printing footnote with label "0". +. rr #FN_MARK +. rr #FN_MARK_2 +. \} +. \} +. \} +. 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 " for BLOCKQUOTES. Printing footnote with label "0". +. rr #FN_MARK +. rr #FN_MARK_2 +. \} +. \} +. \} +. \} +. \} +.\" 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 #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. +.\" 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 \{\ . nr #DIVER_FN 2 \" treat like a normal deferred footnote . \} @@ -10025,34 +10594,34 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . 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. +.\" 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] \} -\# A footnote inside a diversion will become the 1st footnote on the -\# following page/column. +.\" A footnote inside a diversion will become the 1st footnote on the +.\" following page/column. . if \\n[#DIVER_FN]=1 \{ .DIVER_FN_1_PRE \} -\# A footnote inside a diversion that should be treated like a -\# normal footnote (including defers.) +.\" A footnote inside a diversion that should be treated like a +.\" normal footnote (including defers.) . 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 . \} -\# End processing footnotes that occur inside QUOTE, BLOCKQUOTE or -\# EPIGRAPH. -\# -\# Test for situation where, because a final line of running text -\# 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 marker in running text to -\# be the correct one for the 1st footnote on a page. +.\" End processing footnotes that occur inside QUOTE, BLOCKQUOTE or +.\" EPIGRAPH. +.\" +.\" Test for situation where, because a final line of running text +.\" 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 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]) \{\ . ie \\n[#COLUMNS]=1 \{\ @@ -10081,8 +10650,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . \} -\# Housekeeping . if \\n[#FN_MARKERS] \{\ +.\" Housekeeping . if \\n[#CONDENSE] \{ \*[CONDX]\c \} . if \\n[#EXTEND] \{ \*[EXTX]\c \} . if \\n[#PRINT_STYLE]=1 \{\ @@ -10091,56 +10660,56 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . UNDERLINE OFF . \} . \} -\# Add footnote markers to running text... +.\" Add footnote markers to running text... . if !\\n[#NO_FN_MARKER] \{\ -\# ...but not if TERMINATE has not been called +.\" ...but not if TERMINATE has not been called . if !r#TERMINATE \{\ -\# Marker style star/dagger/double-dagger +.\" Marker style star/dagger/double-dagger . if \\n[#FN_MARKER_STYLE]=1 \{\ -\# Columnar docs either move col to col, or last col to next page. -\# They require their own special FN_COUNT because regular FN_COUNT -\# is used to figure out things like whether or not to put a rule -\# above footnotes (in addition to keeping track of the footnote -\# count in non-columnar docs). +.\" Columnar docs either move col to col, or last col to next page. +.\" They require their own special FN_COUNT because regular FN_COUNT +.\" is used to figure out things like whether or not to put a rule +.\" 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]* \} -. if \\n[#FN_COUNT_FOR_COLS]=1 \{ .PRINT \*[BU1]\(dg \} -. if \\n[#FN_COUNT_FOR_COLS]=2 \{ .PRINT \(dd \} -. if \\n[#FN_COUNT_FOR_COLS]=3 \{ .PRINT \*[BU2]** \} -. if \\n[#FN_COUNT_FOR_COLS]=4 \{ .PRINT \*[BU1]\(dg\(dg \} -. if \\n[#FN_COUNT_FOR_COLS]=5 \{ .PRINT \(dd\(dd \} -. if \\n[#FN_COUNT_FOR_COLS]=6 \{ .PRINT \*[BU2]*** \} -. if \\n[#FN_COUNT_FOR_COLS]=7 \{ .PRINT \*[BU1]\(dg\(dg\(dg \} -. if \\n[#FN_COUNT_FOR_COLS]=8 \{ .PRINT \(dd\(dd\(dd \} -. if \\n[#FN_COUNT_FOR_COLS]=9 \{ .PRINT \*[BU2]**** \} +. 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]* \} -. if \\n[#FN_COUNT]=1 \{ .PRINT \*[BU1]\(dg \} -. if \\n[#FN_COUNT]=2 \{ .PRINT \(dd \} -. if \\n[#FN_COUNT]=3 \{ .PRINT \*[BU2]** \} -. if \\n[#FN_COUNT]=4 \{ .PRINT \*[BU1]\(dg\(dg \} -. if \\n[#FN_COUNT]=5 \{ .PRINT \(dd\(dd \} -. if \\n[#FN_COUNT]=6 \{ .PRINT \*[BU2]*** \} -. if \\n[#FN_COUNT]=7 \{ .PRINT \*[BU1]\(dg\(dg\(dg \} -. if \\n[#FN_COUNT]=8 \{ .PRINT \(dd\(dd\(dd \} -. if \\n[#FN_COUNT]=9 \{ .PRINT \*[BU2]**** \} +. 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 +.\" 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" \} -. if \\n[#PRINT_STYLE]=2 \{ .PRINT "\*[SUP]\\n+[#FN_NUMBER]\*[SUPX]" \} +. 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" \} . \} . \} . \} . \} -\# More housekeeping -\# -\# #SPACE_REMAINING is the space left between where we are -\# 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. +.\" More housekeeping +.\" +.\" #SPACE_REMAINING is the space left between where we are +.\" 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 \{\ . nr #SPACE_REMAINING (\\n[#PAGE_LENGTH]-\\n[#B_MARGIN])-(\\n[#PAGE_POS]) . \} @@ -10155,7 +10724,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . nr #PP_STYLE 2 . if \\n[#INDENT_FIRST_PARAS] \{ .nr #INDENT_FIRSTS 1 \} . INDENT_FIRST_PARAS -\# Prepare FOOTNOTE to receive footnote text. +.\" Prepare FOOTNOTE to receive footnote text. . ev FOOTNOTES . ll \\n[#DOC_L_LENGTH]u . ta \\n(.lu @@ -10184,39 +10753,53 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . HY OFF . \} . nr #FN_LEAD \\n[#LEAD] -\# Begin diversion FOOTNOTES or FN_IN_DIVER +.\" Begin diversion FOOTNOTES or FN_IN_DIVER . ie r#COUNTERS_RESET \{\ . ie \\n[#DONE_ONCE]=1 \{\ -. di FN_IN_DIVER +. ie \\n[#RUN_ON] \{\ +. di RUNON_FN_IN_DIVER +. nr #RUNON_FN_IN_DIVER 1 +. \} +. el \{ .di FN_IN_DIVER \} . \} . el \{\ -. da FN_IN_DIVER +. ie \\n[#RUN_ON] \{\ +. da RUNON_FN_IN_DIVER +. nr #RUNON_FN_IN_DIVER 1 +. \} +. el \{ .da FN_IN_DIVER \} . \} -. \\n+[#DONE_ONCE] +. \\n+[#DONE_ONCE] . \} -. el \{ .da FOOTNOTES \} -. if \\n[#FOOTNOTE_COLOR]=1 \{\ -. TRAP OFF -. nf -\m[\\*[$FOOTNOTE_COLOR]] -. EOL -. fi -. TRAP +. el \{\ +. ie \\n[#RUN_ON] \{\ +. da RUNON_FOOTNOTES +. nr #RUNON_FOOTNOTES 1 . \} +. el \{ .da FOOTNOTES \} +. \} +. if \\n[#FOOTNOTE_COLOR]=1 \{\ +. TRAP OFF +. nf +\m[\\*[$FOOTNOTE_COLOR]] +. EOL +. fi +. TRAP +. \} . 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 -\# first footnote belonging to the output page so that there's -\# no confusion when two stars (or two number 1s) appear in -\# footnotes... +.\" 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 +.\" first footnote belonging to the output page so that there's +.\" no confusion when two stars (or two number 1s) appear in +.\" footnotes... . if \\n[#FN_DEFER_SPACE] \{\ -\# ...but only add the extra space if TERMINATE has not been called +.\" ...but only add the extra space if TERMINATE has not been called . if !r#TERMINATE \{\ -\# ...and not if defer space has already been added +.\" ...and not if defer space has already been added . if !\\n[#DEFER_SPACE_ADDED] \{\ -\# ...and not if the footnote count the last time we checked for -\# a defer situation inside a diversion is greater than 1. +.\" ...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 \} @@ -10229,31 +10812,44 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . if \\n[#DIVERTED]=3 \{\ . if \\n[#FN_COUNT]>0 \{\ -\!.RLD 1v +\!. RLD 1v . \} . \} -\# Add footnote rule (or, if no rule, some whitespace). -\# N.B.- this line increments #FN_COUNT each and every time FOOTNOTE -\# is run. +.\" Add footnote rule (or, if no rule, some whitespace). +.\" N.B.- this line increments #FN_COUNT each and every time FOOTNOTE +.\" is run. . if \\n+[#FN_COUNT]=1 \{\ -\# If a footnote is called in a diversion, and the footnote has to -\# be moved, don't put in the rule now (it's taken care of when -\# FN_IN_DIVER is output into FOOTNOTE in PROCESS_FN_IN_DIVER). +.\" If a footnote is called in a diversion, and the footnote has to +.\" be moved, don't put in the rule now (it's taken care of when +.\" FN_IN_DIVER is output into FOOTNOTE in PROCESS_FN_IN_DIVER). . if !\\n[#DONT_RULE_ME]=1 \{\ . if !\\n[#FN_DEPTH] \{\ -. if \\n[#PRINT_STYLE]=1 \{ .ALD \\n[#DOC_LEAD]u \} -. ie \\n[#FN_RULE]=1 \{ .PRINT_FOOTNOTE_RULE \} +. if \\n[#PRINT_STYLE]=1 \{\ +. if !\\n[#RUN_ON] \{ .ALD \\n[#DOC_LEAD]u \} +. \} +. ie \\n[#FN_RULE]=1 \{\ +. if !\\n[#RUN_ON] \{ .PRINT_FOOTNOTE_RULE \} +. \} . el \{ .ALD 1v \} . nr #RULED 1 . \} . \} . \} . rr #DONT_RULE_ME -\# Add footnote markers to footnote text... -. if \\n[#FN_MARKERS] \{\ +.\" Add footnote markers to footnote text... +. ie \\n[#FN_MARKERS] \{\ +. if \\n[#FN_SPACE]>0 \{\ +. if \\n[#FN_COUNT]>0 \{\ +. ALD \\n[#FN_SPACE]u +. \} +. \} . if !\\n[#NO_FN_MARKER] \{\ -\# ...but not if TERMINATE has been called. +.\" ...but not if TERMINATE has been called. . if !r#TERMINATE \{\ +. if \\n[#REF]=1 \{\ +\!. in +\\*[$REF_FN_INDENT] +\!. ti -\\*[$REF_FN_INDENT] +. \} . if \\n[#FN_MARKER_STYLE]=1 \{\ . ie \\n[#COLUMNS]=1 \{\ . \\n+[#FN_COUNT_FOR_COLS] @@ -10295,9 +10891,49 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . \} +. 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[#REF]=1 \{\ +. if !\\n[#RUN_ON]=1 \{\ +\!. in +\\*[$REF_FN_INDENT] +\!. ti -\\*[$REF_FN_INDENT] +. \} +. \} +. 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' \" +. \} +. el \{\ +. as $FN_LINENUMBER \\n[#FN_MARK]\v'-.1m'-\v'.1m'\\n[#FN_MARK_2]\v'-.085m'\\*[$FN_CLOSE_BRACKET]\v'.085m' \" +. \} +. \} +. el \{\ +. 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] +. \} +. \} +. if !\\n[#NO_FN_MARKER] \{\ +. PRINT \\*[$FN_LINENUMBER]\c +. \} +. rm $FN_LINENUMBER +. nr #FN_MARK 0 +. \} +. \} . \} +.\" If INDENT arg is passed to FOOTNOTE, calculate the indent... . el \{\ -\# If INDENT arg passed to footnotes, calculate the indent... . ie '\\$1'INDENT' \{\ . ev FOOTNOTES . if '\\$2'L' \{ .in (\\$3) \} @@ -10317,14 +10953,14 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . in \\n[#FN_BL_INDENT]u . \} . ev -\# ...then re-run FOOTNOTE without an argument. +.\" ...then re-run FOOTNOTE without an argument. . FOOTNOTE . \} . el \{\ . br -\# Add "defer space" if the previously diverted footnote was the -\# 1st footnote proper to its page (i.e. it looks like a deferred -\# footnote but its really an overflow). +.\" Add "defer space" if the previously diverted footnote was the +.\" 1st footnote proper to its page (i.e. it looks like a deferred +.\" 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 \} @@ -10332,13 +10968,21 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . nr #PREV_FN_DEFERRED 2 . \} . \} -\# Terminate FOOTNOTES or FN_IN_DIVER diversion +. if \\n[#REF]=1 \{\ +\!. in +. \} +.\" Terminate FOOTNOTES or FN_IN_DIVER diversion . di . HY_SET 1 \\n[#DIVERSIONS_HY_MARGIN]u (\\n[#PT_SIZE]u/1000u/8u)p . hy 14 -\# More housekeeping -\# Turn off indent possibly set by FOOTNOTE INDENT +.\" More housekeeping +.\" Turn off indent possibly set by FOOTNOTE INDENT . in 0 +.\" Restore sentence spacing +. if \\n[#PRINT_STYLE]=2 \{\ +. if d$RESTORE_SS_VAR \{ .SS \\*[$RESTORE_SS_VAR] \} +. rm $RESTORE_SS_VAR +. \} . if \\n[#PRINT_STYLE]=1 \{\ . if \\n[#UNDERLINE_WAS_ON] \{\ . UNDERLINE @@ -10351,44 +10995,76 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . nr #PP_STYLE \\n[#PP_STYLE_PREV] . 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). +.\" 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 . \} . el \{\ . nr #GET_DEPTH 1 -\# If the footnote is the 1st on the page and it falls too close -\# to the bottom margin, defer the footnote text to the next page... +.\" If the footnote is the 1st on the page and it falls too close +.\" to the bottom margin, defer the footnote text to the next page... . if (\\n[#SPACE_REMAINING]-1)<=(\\n[#DOC_LEAD]) \{\ -\# ...but not if PROCESS_FN_LEFTOVER has set #PREV_FN_DEFERRED to 1 +.\" ...but not if PROCESS_FN_LEFTOVER has set #PREV_FN_DEFERRED to 1 . if !\\n[#PREV_FN_DEFERRED]=1 \{\ . nr #FN_DEFER 1 . nr #FN_DEPTH +\\n[#DIVER_DEPTH] . rr #GET_DEPTH -\# This is required so that the defer space clause can distinguish -\# a real #FN_COUNT=1 from one generated if footnotes is run inside -\# QUOTE, BLOCKQUOTE or EPIGRAPH +.\" This is required so that the defer space clause can distinguish +.\" a real #FN_COUNT=1 from one generated if FOOTNOTE is run inside +.\" QUOTE, BLOCKQUOTE or EPIGRAPH . if \\n[#DIVER_FN]=2 \{\ . nr #SAVED_DIVER_FN_COUNT \\n[#FN_COUNT] . rr #DIVER_FN . \} . \} . \} -\# Calculate the footnote depth. +.\" Calculate the footnote depth. . if \\n[#GET_DEPTH]=1 \{\ -\# Save the previous footnote depth (for use when there will be -\# some overflowed footnote text). +.\" Save the previous footnote depth (for use when there will be +.\" some overflowed footnote text). . nr #SAVED_FN_DEPTH_1 \\n[#FN_DEPTH] -\# Add the depth of the current footnote to any already existent -\# footnotes. +.\" Add the depth of the current footnote to any already existent +.\" footnotes. . nr #FN_DEPTH +\\n[#DIVER_DEPTH] -\# Save the new 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 +. \} +. ev FOOTNOTES +.\" Recreate FOOTNOTES with rule followed by text of unformatted +.\" run-on footnotes. +. di FOOTNOTES +. ie \\n[#FN_RULE]=0 \{ .RLD 1v \} +. el \{\ +. PRINT \v'-\\n[#FN_RULE_ADJ]u'\l'\\n[#FN_RULE_LENGTH]u'\v'+\\n[#FN_RULE_ADJ]u' +. \} +. br +. if \\n[#RUNON_FOOTNOTES] \{\ +. RUNON_FOOTNOTES +. rr #RUNON_FOOTNOTES +. \} +. if \\n[#RUNON_FN_IN_DIVER] \{\ +. RUNON_FN_IN_DIVER +. rr #RUNON_FN_IN_DIVER +. \} +. br +. di +. ev +. nr #FN_DEPTH \\n[#DIVER_DEPTH] +. nr #SAVED_VFP 0+\\n[#VARIABLE_FOOTER_POS] +. nr #VARIABLE_FOOTER_POS 0-\\n[#B_MARGIN]u +. \} +.\" Save the new depth . nr #SAVED_FN_DEPTH_2 \\n[#FN_DEPTH] -\# Signal that defer space should be added when PROCESS_FN_LEFTOVER -\# processes deferred footnotes. +.\" Signal that defer space should be added when PROCESS_FN_LEFTOVER +.\" processes deferred footnotes. . if \\n[#FN_DEFER] \{\ . if \\n[#FN_COUNT]=2 \{\ . ie \\n[#COLUMNS] \{\ @@ -10404,22 +11080,22 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . rr #FN_DEFER . \} -\# If the depth of the whole footnote won't fit in the space -\# between where we are on the page and the bottom margin, calculate -\# how much of it will fit. +.\" If the depth of the whole footnote won't fit in the space +.\" between where we are on the page and the bottom margin, calculate +.\" how much of it will fit. . if \\n[#FN_DEPTH]>\\n[#SPACE_REMAINING] \{\ . nr #FN_LINES 0 1 -. while (\\n+[#FN_LINES]*\\n[#FN_LEAD])<(\\n[#SPACE_REMAINING] \{\ +. 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 -\# be deferred, comes up with a depth equal to exactly 1 line -\# of footnotes, i.e. enough room to print the rule and nothing -\# else. The following tests for such a condition, and rather than -\# attempting to treat the footnote as an overflow, it tells mom to -\# treat it as a special kind of deferred footnote (#FN_DEFER 2). +.\" Very occasionally, #VFP_DIFF, on a 1st footnote that isn't to +.\" be deferred, comes up with a depth equal to exactly 1 line +.\" of footnotes, i.e. enough room to print the rule and nothing +.\" else. The following tests for such a condition, and rather than +.\" attempting to treat the footnote as an overflow, it tells mom to +.\" treat it as a special kind of deferred footnote (#FN_DEFER 2). . if \\n[#SAVED_FN_DEPTH_1]=0 \{\ . if \\n[#FN_DEPTH]=\\n[#FN_LEAD] \{\ . nr #FN_DEFER 2 @@ -10428,9 +11104,13 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . \} -\# Calculate VFP based on whether the footnote overflows, or is to -\# be treated normally. +.\" Calculate VFP based on whether the footnote overflows, or is to +.\" be treated normally. . ie \\n[#OVERFLOW]=1 \{\ +. if \\n[#RUN_ON] \{\ +. rr #VARIABLE_FOOTER_POS +. nr #VARIABLE_FOOTER_POS \\n[#SAVED_VFP] +. \} . ie \\n[#FN_COUNT]=1 \{\ . ie \\n[#RULED]=1 \{\ . ie \\n[#COLUMNS]=1 \{\ @@ -10478,12 +11158,12 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . if !\\n[#VFP_DIFF] \{\ . if \\n[#FN_MARKER_STYLE]=1 \{\ . da FOOTNOTES -\!.ALD \\n[#FN_LEAD]u +\!. ALD \\n[#FN_LEAD]u . di . \} . if \\n[#RESET_FN_NUMBER] \{\ . da FOOTNOTES -\!.ALD \\n[#FN_LEAD]u +\!. ALD \\n[#FN_LEAD]u . di . \} . \} @@ -10492,6 +11172,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . \} +. nr #VARIABLE_FOOTER_POS -\\n[#VFP_DIFF] +. nr #FN_DEPTH \\n[#SAVED_FN_DEPTH_1]+\\n[#VFP_DIFF] . \} . el \{\ . nr #VARIABLE_FOOTER_POS -\\n[#VFP_DIFF] @@ -10513,13 +11195,6 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . if \\n[#FN_COUNT]>1 \{\ . nr #NO_BACK_UP 1 -\# DIVERTED=2 doesn't seem to serve a purpose anymore, but I'm -\# leaving it in, commented out, in case I discover why it was there in -\# the first place. The rr #DIVERTED line seems to solve whatever -\# problem DIVERTED=2 was designed to correct. -\# -\#.if \\n[#DIVERTED]=1 \{ .nr #DIVERTED 2 \} -\# . rr #DIVERTED . rr #RULED . \} @@ -10527,15 +11202,15 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . 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. +.\" 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 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] \{\ . nr #VARIABLE_FOOTER_POS 0-\\n[#B_MARGIN]u . ch FOOTER \\n[#VARIABLE_FOOTER_POS]u @@ -10543,14 +11218,20 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . nr #NO_FN_MARKER 0 . \} +. if \\n[#ADD_BREAK] \{\ +. br +. rr #ADD_BREAK +. \} .END \# \# Utility macros to manage footnotes that occur inside diversions \# --------------------------------------------------------------- \# -\# There are some redundancies here; they're left in in case -\# unforeseen footnote situations crop up in the future that might -\# require manipulation of them. +.ig +There are some redundancies here; they're left in in case unforeseen +footnote situations crop up in the future that might require +manipulation of them. +.. \# \# 1. Pre-footnote processing for footnotes in diversions \# @@ -10601,7 +11282,9 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# 2. Post-footnote processing for footnotes in diversions \# \# Even when a footnote inside a diversion is treated as -\# "normal," some manipulation of registers is required. +\# "normal," some manipulation of registers is required. The +\# macro is called in DO_QUOTE (i.e. at the termination of +\# quotes and blockquotes) and in DO_EPIGRAPH. \# .MAC DIVER_FN_2_POST END . if \\n[#DONE_ONCE]=1 \{\ @@ -10640,22 +11323,24 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# 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. +.ig +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 +.\" The trap also has to be removed each time VFP_CHECK is run . if \\n[#PRINT_STYLE]=2 \{\ . ch VFP_CHECK . SIZESPECS @@ -10684,13 +11369,14 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . ev .END \# -\# FN_OVERFLOW_TRAP starts off "underneath" FOOTER, but is revealed as -\# #VARIABLE_FOOTER_POSITION changes the position of FOOTER. -\# FN_OVERFLOW_TRAP simply starts diversion FN_OVERFLOW -\# to "catch" the overflow. The diversion is ended in FOOTER, -\# immediately after FOOTER outputs the diversion, FOOTNOTES, -\# before PROCESS_FN_LEFTOVER is run (either in HEADER, or in -\# FOOTER if moving col to col). +.ig +FN_OVERFLOW_TRAP starts off "underneath" FOOTER, but is revealed +as #VARIABLE_FOOTER_POSITION changes the position of FOOTER. +FN_OVERFLOW_TRAP simply starts diversion FN_OVERFLOW to "catch" +the overflow. The diversion is ended in FOOTER, immediately after +FOOTER outputs the diversion, FOOTNOTES, before PROCESS_FN_LEFTOVER +is run (either in HEADER, or in FOOTER if moving col to col). +.. \# .MAC FN_OVERFLOW_TRAP END . if \\n[#FN_COUNT] \{\ @@ -10701,11 +11387,6 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . if \\n[#FROM_FOOTER] \{\ . if \\n[#PREV_FN_DEFERRED] \{\ . if !\\n[#COL_NUM]=\\n[#NUM_COLS] \{\ -\# The following line used to serve some purpose, but as things -\# stand now, it screws things up. I'm leaving it in, commented out, -\# in case I \# discover why I thought it was needed. -\# -\#\!.RLD \\n[#FN_LEAD]u . rr #PREV_FN_DEFERRED . \} . \} @@ -10713,13 +11394,13 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . if !\\n[#FROM_FOOTER] \{\ . if !\\n[#COL_NUM]=\\n[#NUM_COLS] \{\ . if !\\n[#LAST_FN_COUNT_FOR_COLS]>1 \{\ -\!.RLD \\n[#FN_LEAD]u +\!. RLD \\n[#FN_LEAD]u . \} . \} . \} . \} . el \{\ -\!.RLD \\n[#FN_LEAD]u +\!. RLD \\n[#FN_LEAD]u . \} . \} . \} @@ -10728,26 +11409,23 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . rr #PREV_FN_DEFERRED . \} . \} -\# When #FROM_DIVERT_FN is 1, it signals to FOOTNOTE, when run from -\# within DIVERT_FN_LEFTOVER, to set #SPACE_REMAINING to the total -\# area allowable for running text. +.\" When #FROM_DIVERT_FN is 1, it signals to FOOTNOTE, when run from +.\" within DIVERT_FN_LEFTOVER, to set #SPACE_REMAINING to the total +.\" area allowable for running text. . nr #FROM_DIVERT_FN 1 .END \# -\# PROCESS_FN_LEFTOVER is called at the top of HEADER, and in -\# FOOTER if we're moving from one column to the next (i.e. after -\# outputting FOOTNOTES). It checks for whether we have a "deferred -\# footnote" situation, and resets counters and number registers -\# accordingly. Lastly, if we have some footnote overflow, it calls -\# DIVERT_FN_OVERFLOW. +.ig +PROCESS_FN_LEFTOVER is called at the top of HEADER, and in +FOOTER if we're moving from one column to the next (i.e. after +outputting FOOTNOTES). It checks for whether we have a "deferred +footnote" situation, and resets counters and number registers +accordingly. Lastly, if we have some footnote overflow, it calls +DIVERT_FN_OVERFLOW. +.. \# .MAC PROCESS_FN_LEFTOVER END . if \\n[#PREV_FN_DEFERRED]=2 \{\ -\# #FN_COUNT_FOR_COLS_AT_FOOTER used to have a purpose. I'm -\# leaving it in, commented out, as a safeguard against -\# (re)discovering why it was needed. -\# -\#.if \\n[#FN_COUNT_FOR_COLS_AT_FOOTER]=0 \{ .rr #PREV_FN_DEFERRED \} . if \\n[#FN_COUNT_AT_FOOTER]>1 \{ .rr #PREV_FN_DEFERRED \} . \} . if !\\n[#FN_DEFER] \{\ @@ -10795,9 +11473,11 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . rr #FROM_DIVERT_FN .END \# -\# DIVERT_FN_LEFTOVER is called in PROCESS_FN_LEFTOVER (at -\# the top of HEADER, and in FOOTER if we're moving from one column -\# to the next). +.ig +DIVERT_FN_LEFTOVER is called in PROCESS_FN_LEFTOVER (at +the top of HEADER, and in FOOTER if we're moving from one column +to the next). +.. \# .MAC DIVERT_FN_LEFTOVER END . nr #NO_FN_MARKER 1 @@ -10818,10 +11498,12 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . rr #FN_OVERFLOW_DEPTH .END \# -\# This is a special macro to deal with footnotes that are set -\# inside diversions (QUOTE, BLOCKQUOTE and EPIGRAPH). It's called -\# in HEADER (and in FOOTER, if we're moving from column to column), -\# and comes after PROCESS_FOOTNOTE_LEFTOVER in those two macros. +.ig +This is a special macro to deal with footnotes that are set inside +diversions (QUOTE, BLOCKQUOTE and EPIGRAPH). It's called in HEADER +(and in FOOTER, if we're moving from column to column), and comes +after PROCESS_FOOTNOTE_LEFTOVER in those two macros. +.. \# .MAC PROCESS_FN_IN_DIVER END . nr #SPACE_REMAINING 0 @@ -10831,8 +11513,15 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . rr #RESET_FN_COUNTERS . \} . FOOTNOTE -. nf -. FN_IN_DIVER +. if \\n[#FN_OVERFLOW_DEPTH] \{ .nf \} +. ie dRUNON_FN_IN_DIVER \{\ +. RUNON_FN_IN_DIVER +. rm RUNON_FN_IN_DIVER +. \} +. el \{\ +. nf +. FN_IN_DIVER +. \} . FOOTNOTE OFF . rr #DIVER_FN .END @@ -10841,16 +11530,20 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# \# +++ENDNOTES+++ \# -\# When endnotes are output, the spacing between the notes is always 1 -\# extra linespace. This can have bottom margin consequences. If this -\# doesn't bother you, don't worry about it. If it does bother you, and -\# you want to adjust the spacing between any two endnotes (as they're -\# output), make the spacing adjustments (.ALD/.RLD) at the *end* of -\# endnotes (i.e. just before .ENDNOTE OFF), not at the top. -\# -\# Endnotes must be output manually with .ENDNOTES. This allows user -\# the flexibility to output endnotes at the end of each collated -\# document, or to output them at the end of the entire document. +.ig +When endnotes are output, the spacing between the notes is always +1 extra linespace. This can have bottom margin consequences. If +this doesn't bother you, don't worry about it. If it does bother +you, and you want to adjust the spacing between any two endnotes (as +they're output), make the spacing adjustments (.ALD/.RLD) at the +*end* of endnotes (i.e. just before .ENDNOTE OFF), not at the top. + +Endnotes must be output manually with .ENDNOTES. This allows user +the flexibility to output endnotes at the end of each collated +document, or to output them at the end of the entire document. +.. +\# +\# Control macros \# \# ENDNOTE POINT SIZE \# ------------------ @@ -11000,6 +11693,11 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .END \# \# +.MAC ENDNOTE_TITLE_SPACE END +. nr #EN_TITLE_SPACE (\\$1) +.END +\# +\# \# ENDNOTE TITLE UNDERSCORE \# ------------------------ \# *Argument: @@ -11015,6 +11713,108 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .END \# \# +\# ENDNOTE MARKER STYLE +\# -------------------- +\# *Arguments: +\# NUMBER | LINE +\# *Function: +\# Sets register #EN_MARKER_STYLE, used in ENDNOTE to determine +\# the style of endnote markers (labels). +\# *Notes: +\# 1=NUMBER; 2=LINE. LINE means "use output line numbers". +\# Default is NUMBER. +\# +.MAC ENDNOTE_MARKER_STYLE END +. 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 \} +. \} +. \} +.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' +\# +\# +\# ENDNOTE LINENUMBER SEPARATOR +\# ---------------------------- +\# *Argument: +\# +\# *Function: +\# Stores user-defined separator (for use then +\# ENDNOTE_MARKER_STYLE is LINE) in string $EN_LN_SEP. The +\# separator is intended to be used when the user wishes a +\# separator, rather than the choice of brackets offered by +\# ENDNOTE_LINENUMBER_BRACKETS. +\# +.MAC ENDNOTE_LINENUMBER_SEPARATOR END +. rr #EN_LN_BRACKETS +. nr #EN_LN_SEP 1 +. ds $EN_LN_SEP "\\$1 +.END +\# +\# +\# ENDNOTE LINENUMBER BRACKETS +\# --------------------------- +\# *Argument: +\# PARENS | SQUARE | BRACES or ( | [ | { +\# *Function: +\# Sets register #EN_LN_BRACKETS to 1, and creates strings +\# $EN_OPEN_BRACKET and $EN_CLOSE_BRACKET according to the given argument. +\# +.MAC ENDNOTE_LINENUMBER_BRACKETS END +. rr #EN_LN_SEP +. nr #EN_LN_BRACKETS 1 +. if '\\$1'PARENS' \{\ +. ds $EN_OPEN_BRACKET ( +. ds $EN_CLOSE_BRACKET ) +. \} +. if '\\$1'(' \{\ +. ds $EN_OPEN_BRACKET ( +. ds $EN_CLOSE_BRACKET ) +. \} +. if '\\$1'SQUARE' \{\ +. ds $EN_OPEN_BRACKET [ +. ds $EN_CLOSE_BRACKET ] +. \} +. if '\\$1'[' \{\ +. ds $EN_OPEN_BRACKET [ +. ds $EN_CLOSE_BRACKET ] +. \} +. if '\\$1'BRACES' \{\ +. ds $EN_OPEN_BRACKET { +. ds $EN_CLOSE_BRACKET } +. \} +. if '\\$1'{' \{\ +. ds $EN_OPEN_BRACKET { +. ds $EN_CLOSE_BRACKET } +. \} +.END +\# +\# +\# ENDNOTE LINENUMBER GAP +\# ---------------------- +\# *Argument: +\# +\# *Function: +\# Defines string $EN_LN_GAP, used during printing of line-number +\# labels in ENDNOTE. +\# +.MAC ENDNOTE_LINENUMBER_GAP END +. ds $EN_LN_GAP \\$1 +.END +\# +\# \# ENDNOTE NUMBERS ALIGN RIGHT \# --------------------------- \# *Argument: @@ -11225,25 +12025,42 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# Places superscript endnote number in text, then collects and \# processes endnote in diversion END_NOTES. \# *Notes: -\# \c must be appended to the word immediately preceding .ENDNOTE. +\# \c must be appended to the word immediately preceding .ENDNOTE +\# when ENDNOTE_MARKER_STYLE is NUMBER. \# .MAC ENDNOTE END +. if !\\n(.u \{ .nr #ADD_BREAK 1 \} . ie '\\$1'' \{\ . nr #ENDNOTE 1 -. if \\n[#CONDENSE] \{ \*[CONDX]\c \} -. if \\n[#EXTEND] \{ \*[EXTX]\c \} -. if \\n[#PRINT_STYLE]=1 \{\ -. if \\n[#UNDERLINE_ON] \{\ -. nr #UNDERLINE_WAS_ON 1 -. UNDERLINE OFF -. \} -. if \\n[#SLANT_ON] \{\ -. nr #SLANT_WAS_ON 1 +. if \\n[#EN_MARKER_STYLE]=1 \{\ +. if \\n[#CONDENSE] \{ \*[CONDX]\c \} +. if \\n[#EXTEND] \{ \*[EXTX]\c \} +. if \\n[#PRINT_STYLE]=1 \{\ +. if \\n[#UNDERLINE_ON] \{\ +. nr #UNDERLINE_WAS_ON 1 +. UNDERLINE OFF +. \} +. if \\n[#SLANT_ON] \{\ +. nr #SLANT_WAS_ON 1 \*[SLANTX]\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" \} +. \} +. if \\n[#EN_MARKER_STYLE]=2 \{\ +. 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. +. \} +. 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 . \} -. PRINT "\s-2\v'-\\n[#DOC_LEAD]u/5u'\\n+[#EN_NUMBER]\v'+\\n[#DOC_LEAD]u/5u'\s+2" . \} -. if \\n[#PRINT_STYLE]=2 \{ .PRINT "\*[SUP]\\n+[#EN_NUMBER]\*[SUPX]" \} . nr #PP_STYLE_PREV \\n[#PP_STYLE] . nr #PP_STYLE 1 . if \\n[#INDENT_FIRST_PARAS] \{ .nr #INDENT_FIRSTS 1 \} @@ -11285,84 +12102,141 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . \} -. ie \\n[#EN_NUMBERS_ALIGN_RIGHT] \{\ -. ie \\n[#EN_NUMBER]=1 \{\ -. if !'\\*[$EN_TITLE]'' \{ .sp \} -. \} -. el \{ .sp \} -\!. TRAP OFF -. if \\n[#PRINT_STYLE]=1 \{\ -. TYPEWRITER -. \} -. if \\n[#PRINT_STYLE]=2 \{\ +. ie \\n[#EN_NUMBER]=1 \{\ +. if !'\\*[$EN_TITLE]'' \{ .sp \} +. \} +. el \{ .sp \} +. if \\n[#PRINT_STYLE]=1 \{\ +. TYPEWRITER +. \} +. if \\n[#PRINT_STYLE]=2 \{\ +. if \\n[#EN_MARKER_STYLE]=1 \{\ . FAMILY \\*[$EN_NUMBER_FAM] . FT \\*[$EN_NUMBER_FT] . PT_SIZE \\n[#EN_PS]u\\*[$EN_NUMBER_SIZE_CHANGE] . \} -. nr #RESET_L_LENGTH \\n(.l -. nr #EN_NUMBER_L_LENGTH \w'\0'*\\n[#EN_NUMBER_PLACEHOLDERS]+\w'.' -. ll \\n[#EN_NUMBER_L_LENGTH]u -. RIGHT -\En[#EN_NUMBER]. -. if \\n[#PRINT_STYLE]=1 \{\ -. TYPEWRITER -. \} -. if \\n[#PRINT_STYLE]=2 \{\ -. FAMILY \\*[$EN_FAM] -. FT \\*[$EN_FT] -. PT_SIZE \\n[#EN_PS]u +. if \\n[#EN_MARKER_STYLE]=2 \{\ +. FAMILY \\*[$EN_LN_FAM] +. FT \\*[$EN_LN_FT] +. PT_SIZE \\n[#EN_PS]u\\*[$EN_LN_SIZE_CHANGE] . \} -. EOL -. ll \\n[#RESET_L_LENGTH]u -. in \\n[#EN_NUMBER_L_LENGTH]u+\w'.\0'u -. nr #EN_TEXT_INDENT \\n(.i -. QUAD \\*[$EN_QUAD] -\!. TRAP . \} -. el \{\ -. ie \\n[#EN_NUMBER]=1 \{\ -. if !'\\*[$EN_TITLE]'' \{ .sp \} -. \} -. el \{ .sp \} -. if \\n[#PRINT_STYLE]=1 \{\ -. TYPEWRITER -. \} -. if \\n[#PRINT_STYLE]=2 \{\ -. FAMILY \\*[$EN_NUMBER_FAM] -. FT \\*[$EN_NUMBER_FT] -. PT_SIZE \\n[#EN_PS]u\\*[$EN_NUMBER_SIZE_CHANGE] +. if \\n[#EN_MARKER_STYLE]=2 \{\ +. ENDNOTE_NUMBERS_ALIGN_LEFT +. 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' \" +. \} . \} -. QUAD \\*[$EN_QUAD] -\En[#EN_NUMBER].\0\c -. if \\n[#PRINT_STYLE]=2 \{\ -. FAMILY \\*[$EN_FAM] -. FT \\*[$EN_FT] -. PT_SIZE \\n[#EN_PS]u +. el \{\ +. 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 . \} -. \} -. el \{\ -. br -. if \\n[#EN_NUMBERS_ALIGN_RIGHT] \{\ -. in 0 +\!. TRAP OFF +. nr #RESET_L_LENGTH \\n(.l +. ie \\n[#EN_NUMBERS_ALIGN_RIGHT] \{\ +. nr #EN_NUMBER_L_LENGTH \w'\0'*\\n[#EN_NUMBER_PLACEHOLDERS]+\w'.' +. RIGHT . \} -. di -. ev -. nr #PP_STYLE \\n[#PP_STYLE_PREV] -. if !\\n[#INDENT_FIRSTS] \{ .INDENT_FIRST_PARAS OFF \} -. rr #INDENT_FIRSTS -. rr #ENDNOTE -. if \\n[#PRINT_STYLE]=1 \{\ -. if \\n[#UNDERLINE_WAS_ON] \{\ -. rr #UNDERLINE_WAS_ON -. UNDERLINE +. el \{\ +. nr #EN_NUMBER_L_LENGTH \w'\En[#EN_NUMBER].\0' +. LEFT +. \} +. if \\n[#EN_MARKER_STYLE]=2 \{\ +. if !\\n[#EN_NUMBERS_ALIGN_RIGHT] \{\ +. nr #EN_NUMBER_L_LENGTH \w'\\*[$EN_LINENUMBER]'+\\*[$EN_LN_GAP] +. LEFT . \} . \} -. if \\n[#SLANT_WAS_ON] \{\ -. rr #SLANT_WAS_ON +. ll \\n[#EN_NUMBER_L_LENGTH]u +. if \\n[#EN_MARKER_STYLE]=1 \{\ +\En[#EN_NUMBER]. +. \} +. if \\n[#EN_MARKER_STYLE]=2 \{\ +\\*[$EN_LINENUMBER] +. rm $EN_LINENUMBER +. \} +. EOL +. ll \\n[#RESET_L_LENGTH]u +. nr #EN_FIGURE_SPACE \w'\0.' +. ie \\n[#EN_NUMBERS_ALIGN_RIGHT] \{\ +. in \\n[#EN_NUMBER_L_LENGTH]u+\\n[#EN_FIGURE_SPACE]u +. \} +. el \{\ +. ti \\n[#EN_NUMBER_L_LENGTH]u +. \} +. nr #EN_TEXT_INDENT \\n(.i +. QUAD \\*[$EN_QUAD] +\!. TRAP +. if \\n[#PRINT_STYLE]=1 \{\ +. TYPEWRITER +. \} +. if \\n[#PRINT_STYLE]=2 \{\ +. FAMILY \\*[$EN_FAM] +. FT \\*[$EN_FT] +. PT_SIZE \\n[#EN_PS]u +. \} +. if \\n[#REF]=1 \{\ +. ie !\\n[#EN_MARKER_STYLE]=2 \{\ +. if \\n[#EN_NUMBERS_ALIGN_LEFT] \{\ +. in \\*[$REF_EN_INDENT] +. ti -(\\*[$REF_EN_INDENT]-\\n[#EN_NUMBER_L_LENGTH]u) +. \} +. if \\n[#EN_NUMBERS_ALIGN_RIGHT] \{\ +. in \\*[$REF_EN_INDENT] +. ti -(\\*[$REF_EN_INDENT]-\\n[#EN_NUMBER_L_LENGTH]u-\\n[#EN_FIGURE_SPACE]u) +. \} +. \} +. el \{\ +. if \\n[#EN_NUMBERS_ALIGN_LEFT] \{\ +. in \\*[$REF_EN_INDENT] +. ti -(\\*[$REF_EN_INDENT]-\\n[#EN_NUMBER_L_LENGTH]u) +. \} +. \} +. \} +. \} +. el \{\ +. br +. in 0 +. if \\n[#EN_MARKER_STYLE]=2 \{\ +\!. in 0 +. \} +. di +.\" Restore sentence spacing +. if \\n[#PRINT_STYLE]=2 \{\ +. if d$RESTORE_SS_VAR \{ .SS \\*[$RESTORE_SS_VAR] \} +. rm $RESTORE_SS_VAR +. \} +. ev +. nr #PP_STYLE \\n[#PP_STYLE_PREV] +. if !\\n[#INDENT_FIRSTS] \{ .INDENT_FIRST_PARAS OFF \} +. rr #INDENT_FIRSTS +. rr #ENDNOTE +. if \\n[#PRINT_STYLE]=1 \{\ +. if \\n[#UNDERLINE_WAS_ON] \{\ +. rr #UNDERLINE_WAS_ON +. UNDERLINE +. \} +. \} +. if \\n[#SLANT_WAS_ON] \{\ +. rr #SLANT_WAS_ON \*[SLANT]\c . \} . \} +. if \\n[#ADD_BREAK] \{\ +. br +. rr #ADD_BREAK +. \} .END \# \# @@ -11380,6 +12254,10 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . nr #EN_FIRST_PAGE 1 . nr #HEADER_STATE \\n[#HEADERS_ON] . ds $RESTORE_PAGENUM_STYLE \\*[$PAGENUM_STYLE] +. if \\n[#LINENUMBERS]=1 \{\ +. NUMBER_LINES OFF +. nr #LINENUMBERS 2 +. \} . if \\n[#HEADERS_ON]=1 \{\ . if !\\n[#EN_ALLOWS_HEADERS_ALL] \{ .HEADERS OFF \} . \} @@ -11401,7 +12279,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . 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 \{\ @@ -11427,7 +12305,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . if \\n[#HEADER_STATE]=1 \{\ . if \\n[#EN_ALLOWS_HEADERS] \{ .HEADERS \} . \} -\# Collect endnote title string for TOC +.\" 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]\\| @@ -11464,8 +12342,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \!. TQ . di . ev -\# End collection of endnote title string for TOC -\# Process endnote +.\" End collection of endnotes title string for TOC +.\" Process endnotes . if \\n[#PRINT_STYLE]=1 \{ .vs \\n[#EN_LEAD]u \} . if \\n[#PRINT_STYLE]=2 \{\ . if \\n[#EN_NO_COLS] \{\ @@ -11479,7 +12357,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . el \{ .DOC_LEAD \\n[#EN_LEAD]u \} . \} . PRINT \& -. sp |\\n[#T_MARGIN]u +. ie r#EN_TITLE_SPACE \{ .sp |\\n[#EN_TITLE_SPACE]u \} +. el \{ .sp |\\n[#T_MARGIN]u \} . mk ec . if \\n[#SLANT_ON] \{\ \*[SLANTX]\c @@ -11525,7 +12404,20 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . CAPS OFF -. ALD \\n[#EN_LEAD]u +. if \\n[#PRINT_STYLE]=1 \{\ +. ie \\n[#SINGLE_SPACE]=1 \{\ +. ALD \\n[#EN_LEAD]u*2u +. \} +. el \{\ +. ie \\n[#EN_SINGLESPACE]=1 \{\ +. ALD \\n[#EN_LEAD]u*2 +. \} +. el \{\ +. +. \} +. \} +. \} +. if \\n[#PRINT_STYLE]=2 \{ .ALD \\n[#EN_LEAD]u \} . QUAD \\*[$EN_QUAD] . nf . END_NOTES @@ -11542,11 +12434,417 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . if \\n[#COLUMNS_WERE_ON] \{ .nr #COLUMNS 1 \} . if \\n[#HEADER_STATE]=1 \{ .HEADERS \} +. if \\n[#LINENUMBERS]=2 \{\ +. NUMBER_LINES RESUME +. nr #LINENUMBERS 1 +. \} . rr #ENDNOTES .END \# \# ==================================================================== \# +\# +++BIBLIOGRAPHY+++ +\# +.ig +Mom treats bibliographies and endnotes very similarly. The chief +difference is that endnotes are collected and formatted inside a +diversion, while bibliographies are built "by hand." ENDNOTES sets +up the endnotes page and outputs the formatted diversion. +BIBLIOGRAPHY sets up the bibliography page, then awaits refer +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. +.. +\# Bibliography control macros +\# +.MAC BIBLIOGRAPHY_PT_SIZE END +. nr #BIB_PS (p;\\$1) +.END +\# +.MAC BIBLIOGRAPHY_LEAD END +. if !\\n[#OK_PROCESS_LEAD] \{\ +. ds $BIB_LEAD \\$1 +. if !'\\$2'' \{\ +. ds $ADJUST_BIB_LEAD \\$2 +. \} +. return +. \} +. rr #ADJ_BIB_LEAD +. nr #BIB_LEAD (p;\\$1) +. if '\\$2'ADJUST' \{\ +. nr #ORIG_DOC_LEAD \\n[#DOC_LEAD] +. nr #RESTORE_ADJ_DOC_LEAD \\n[#ADJ_DOC_LEAD] +. nr #ADJ_DOC_LEAD 1 +. nr #ADJ_BIB_LEAD 1 +. nr #NO_TRAP_RESET 1 +. DOC_LEAD \\n[#BIB_LEAD]u ADJUST +. nr #BIB_LEAD \\n[#DOC_LEAD] +. DOC_LEAD \\n[#ORIG_DOC_LEAD]u +. rr #NO_TRAP_RESET +. nr #ADJ_DOC_LEAD \\n[#RESTORE_ADJ_DOC_LEAD] +. rr #ORIG_DOC_LEAD +. \} +.END +\# +.MAC BIBLIOGRAPHY_HDRFTR_CENTER END +. ie '\\$1'' \{ .nr #BIB_HDRFTR_CENTER 1 \} +. el \{ .rr #BIB_HDRFTR_CENTER \} +.END +\# +.MAC BIBLIOGRAPHY_STRING END +. ds $BIB_STRING \\$1 +.END +\# +.MAC BIBLIOGRAPHY_STRING_UNDERSCORE END +. ie '\\$1'' \{ .nr #BIB_STRING_UNDERSCORE 1 \} +. el \{\ +. ie '\\$1'2' \{ .nr #BIB_STRING_UNDERSCORE 2 \} +. el \{ .nr #BIB_STRING_UNDERSCORE 0 \} +. \} +.END +\# +.MAC BIBLIOGRAPHY_STRING_CAPS END +. ie '\\$1'' \{ .nr #BIB_STRING_CAPS 1 \} +. el \{ .rr #BIB_STRING_CAPS \} +.END +\# +.MAC BIBLIOGRAPHY_NO_COLUMNS END +. 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 \} +.END +\# +.MAC BIBLIOGRAPHY_ALLOWS_HEADERS END +. ie '\\$1'' \{ .nr #BIB_ALLOWS_HEADERS 1 \} +. el \{\ +. ie '\\$1'ALL' \{\ +. nr #BIB_ALLOWS_HEADERS 1 +. nr #BIB_ALLOWS_HEADERS_ALL 1 +. \} +. el \{\ +. rr #BIB_ALLOWS_HEADERS +. rr #BIB_ALLOWS_HEADERS_ALL +. \} +. \} +.END +\# +.MAC BIBLIOGRAPHY_PAGENUM_STYLE END +. ds $BIB_PN_STYLE \\$1 +.END +\# +.MAC BIBLIOGRAPHY_FIRST_PAGENUMBER END +. nr #BIB_FIRST_PN \\$1 +.END +\# +.MAC SINGLESPACE_BIBLIOGRAPHY END +. if \\n[#PRINT_STYLE]=1 \{\ +. ie \\n[#SINGLE_SPACE] \{\ +. nr #BIB_SINGLESPACE 1 +. rr #IGNORE +. if \\n[#OK_PROCESS_LEAD] \{\ +. BIBLIOGRAPHY_LEAD 12 ADJUST +. nr #IGNORE 1 +. \} +. \} +. el \{\ +. ie '\\$1'' \{\ +. nr #BIB_SINGLESPACE 1 +. rr #IGNORE +. if \\n[#OK_PROCESS_LEAD] \{\ +. BIBLIOGRAPHY_LEAD 12 ADJUST +. nr #IGNORE 1 +. \} +. \} +. el \{\ +. rr #BIB_SINGLESPACE +. rr #IGNORE +. if \\n[#OK_PROCESS_LEAD] \{\ +. BIBLIOGRAPHY_LEAD 24 ADJUST +. nr #IGNORE 1 +. \} +. \} +. \} +. \} +.END +\# +\# +\# Style for outputting collected bibliographic references +\# ------------------------------------------------------- +\# *Argument: +\# LIST | PLAIN [ ] [ ] +\# *Function: +\# Sets #BIB_LIST to 1 for numbered list style, 0 for plain output +\# *Notes: +\# Technically, user is supposed to enter PLAIN if s/he wants an +\# unumbered bibliography, but the el clause says "any arg but +\# LIST means unumbered." Effectively, any arg but LIST produces +\# a "plain" bibliographic list. +\# +\# The 2nd and 3rd args have the same options as the 2nd arg to LIST. +\# +.MAC BIBLIOGRAPHY_TYPE END +. ie '\\$1'LIST' \{\ +. nr #BIB_LIST 1 +. ie '\\$2'' \{\ +. if '\\*[$BIB_LIST_SEPARATOR]'' .ds $BIB_LIST_SEPARATOR . +. \} +. el .ds $BIB_LIST_SEPARATOR \\$2 +. ie '\\$3'' .ds $BIB_LIST_PREFIX +. el .ds $BIB_LIST_PREFIX \\$3 +. \} +. el \{ .nr #BIB_LIST 0 \} +.END +\# +\# Spacing between items in bibliographies +\# --------------------------------------- +\# *Argument: +\# +\# *Function: +\# Gets value for #BIB_SPACE in units. +\# *Notes: +\# Requires a unit of measure. +\# +.MAC BIBLIOGRAPHY_SPACING END +. ds $BIB_SPACE \\$1 +. if \\n[#BIB_LEAD]=0 \{\ +. nr #DEFER_BIB_SPACING 1 +. return +. \} +. ds $EVAL_BIB_SPACE \\*[$BIB_SPACE] +. substring $EVAL_BIB_SPACE -1 +. ie '\\*[$EVAL_BIB_SPACE]'v' \{\ +. substring $BIB_SPACE 0 0 +. nr #BIB_SPACE \\n[#BIB_LEAD]*\\*[$BIB_SPACE] +. \} +. el \{\ +. nr #BIB_SPACE (\\$1) +. \} +.END +\# +\# Set up bibliography page +\# ------------------------ +\# *Function: +\# Sets up a new page, with title, ready to accept the output +\# of refer's $LIST$ or .R1 bibliography .R2 +\# *Notes: +\# Bibliography pages are set up almost identically to endnotes pages. +\# +.MAC BIBLIOGRAPHY END +. nr #BIBLIOGRAPHY 1 +. nr #BIB_FIRST_PAGE 1 +. nr #HEADER_STATE \\n[#HEADERS_ON] +. ds $RESTORE_PAGENUM_STYLE \\*[$PAGENUM_STYLE] +. if \\n[#LINENUMBERS]=1 \{\ +. NUMBER_LINES OFF +. nr #LINENUMBERS 2 +. \} +. if \\n[#HEADERS_ON]=1 \{\ +. 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[#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 \} +. \} +. \} +. \} +. el \{\ +. 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] +. \} +. NEWPAGE +. if \\n[#FOOTERS_ON]=1 \{\ +. ds $HDRFTR_CENTER \\*[$HDRFTR_CENTER_NEW] +. rm $HDRFTR_CENTER_OLD +. rm $HDRFTR_CENTER_NEW +. \} +. ie !\\n[#SUSPEND_PAGINATION] \{\ +. if \\n[#PAGE_NUM_V_POS]=1 \{\ +. if r#BIB_NO_FIRST_PN \{\ +. if \\n[#PAGINATION_STATE]=1 \{\ +. nr #PAGINATE 1 +. \} +. \} +. \} +. \} +. el \{\ +. 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[#HEADER_STATE]=1 \{\ +. 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 +. 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]" +. \} +\!. 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 bibliography title string for TOC +.\" Process bibliography +. 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 \} +. 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 \} +. \} +. PRINT \& +. ie r#BIB_TITLE_SPACE \{ .sp |\\n[#BIB_TITLE_SPACE]u \} +. el \{ .sp |\\n[#T_MARGIN]u \} +. mk ec +. if \\n[#SLANT_ON] \{\ +\*[SLANTX]\c +. \} +. if !'\\*[$BIB_STRING]'' \{\ +. if \\n[#PRINT_STYLE]=1 \{\ +. TYPEWRITER +. vs \\n[#BIB_LEAD]u +. \} +. if \\n[#PRINT_STYLE]=2 \{\ +. LL \\n[#DOC_L_LENGTH]u +. ta \\n(.lu +. if \\n[#COLUMNS] \{\ +. ie \\n[#BIB_NO_COLS] \{ .LL \\n[#DOC_L_LENGTH]u \} +. el \{ .LL \\n[#COL_L_LENGTH]u \} +. ta \\n(.lu +. \} +. 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 '\\*[$EN_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 \} +. ie \\n[#BIB_STRING_UNDERSCORE] \{\ +. ie \\n[#BIB_STRING_UNDERSCORE]=2 \{\ +. UNDERSCORE2 "\\*[$BIB_STRING] +. \} +. el \{\ +. UNDERSCORE "\\*[$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 +. \} +. el \{\ +. 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 \{\ +. 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[#COLUMNS_WERE_ON] \{ .nr #COLUMNS 1 \} +. if \\n[#HEADER_STATE]=1 \{ .HEADERS \} +. rr #BIBLIOGRAPHY +. if \\n[#LINENUMBERS]=2 \{\ +. NUMBER_LINES RESUME +. nr #LINENUMBERS 1 +. \} +.END +\# +\# ==================================================================== +\# \# +++TABLE OF CONTENTS+++ \# \# Strings to allocate space for leaders and entry page numbers @@ -11761,6 +13059,10 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# \# .MAC TOC END +. if \\n[#LINENUMBERS]=1 \{\ +. NUMBER_LINES OFF +. nr #LINENUMBERS 2 +. \} . if !r#PAGINATE_TOC \{ .PAGINATE_TOC \} . nr #TOC_FIRST_PAGE 1 . if \\n[#FINIS] \{\ @@ -11769,7 +13071,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . 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] . ie \\n[#PAGINATE_TOC]=1 \{ .PAGINATE \} . el \{ .PAGINATION OFF \} . \} @@ -11799,6 +13101,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . DOC_LEAD 24 ADJUST . nr #IGNORE 1 . \} +. if \\n[#LINENUMBERS]=2 \{ .nr #LINENUMBERS 3 \} . START . PP . nr #COLUMNS 0 @@ -11837,9 +13140,9 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . LEFT . SP -\# In collated docs, this bit inserts the first doc's title -\# underneath the TOC header, before the TOC_ENTRIES diversion -\# gets output. +.\" 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] @@ -11874,6 +13177,11 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . TOC_ENTRIES . br . rr #TOC +. if \\n[#LINENUMBERS]=3 \{\ +. NUMBER_LINES RESUME +. nr #LINENUMBERS 1 +. nn 1 +. \} .END \# \# ==================================================================== @@ -11901,6 +13209,9 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . 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 \} . \} . rr #COL_TOTAL . rr #COL_NUM @@ -11938,7 +13249,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# LIST \# ---- \# *Arguments: -\# [ BULLET | DASH | DIGIT | ALPHA | USER ] [ ] [ ] +\# [ BULLET | DASH | DIGIT | alpha | ALPHA | roman | ROMAN | USER ] [ | NONE ] [ ] [ ] \# *Function: \# Stores indent information in effect prior to invocation and \# initializes a list with the supplied enumerator (and separator). @@ -11953,6 +13264,30 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# completely if the level in which it's invoked is the first. \# .MAC LIST END +. ds $1ST_LETTER \\$1 +. substring $1ST_LETTER 0 0 +. if '\\*[$1ST_LETTER]'r' .ds $1ST_LETTER R +. ie '\\*[$1ST_LETTER]'R' \{\ +. ds $LAST_CHAR \\$1 +. substring $LAST_CHAR -1 +. if !\B'\\*[$LAST_CHAR]' \{\ +. 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 +. \} +. 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) +. \} +. el \{\ +. ds $LIST_ARG_1 \\$1 +. \} . if !r#DEPTH \{\ . nr #STORED_HL_INDENT \\n[#HL_INDENT] . nr #STORED_T_INDENT \\n[#T_INDENT] @@ -11984,45 +13319,93 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . if \\n[#NUM_ARGS]=0 \{\ . nr #ARGS_TO_LIST 1 \" So default behaves as if LIST BULLET . ds $ENUMERATOR\\n+[#DEPTH] \(bu +. ds $ENUMERATOR_TYPE\\n[#DEPTH] other . ds $SEPARATOR . \} . if \\n[#NUM_ARGS]>0 \{\ . rr #ARGS_TO_LIST \" Clear this before processing arg 1. -. if '\\$1'DASH' \{\ +. if '\\*[$LIST_ARG_1]'DASH' \{\ . nr #ARGS_TO_LIST 1 . ds $ENUMERATOR\\n+[#DEPTH] \(en +. ds $ENUMERATOR_TYPE\\n[#DEPTH] other . ds $SEPARATOR\\n[#DEPTH] . \} -. if '\\$1'BULLET' \{\ +. if '\\*[$LIST_ARG_1]'BULLET' \{\ . nr #ARGS_TO_LIST 1 . ds $ENUMERATOR\\n+[#DEPTH] \(bu +. ds $ENUMERATOR_TYPE\\n[#DEPTH] other . ds $SEPARATOR\\n[#DEPTH] . \} -. if '\\$1'DIGIT' \{\ +. if '\\*[$LIST_ARG_1]'DIGIT' \{\ . nr #ARGS_TO_LIST 1 . nr #ENUMERATOR\\n+[#DEPTH] 0 1 . ds $ENUMERATOR_TYPE\\n[#DEPTH] register . ds $SEPARATOR\\n[#DEPTH] . -. if \\n[#NUM_ARGS]=2 \{\ -. ie '\\$2'NONE' \{ .ds $SEPARATOR\\n[#DEPTH]\} -. el \{ .ds $SEPARATOR\\n[#DEPTH] \\$2\} +. 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 '\\$1'ALPHA' \{\ +. if '\\*[$LIST_ARG_1]'alpha' \{\ . nr #ARGS_TO_LIST 1 . nr #ENUMERATOR\\n+[#DEPTH] 0 1 . af #ENUMERATOR\\n[#DEPTH] a . ds $ENUMERATOR_TYPE\\n[#DEPTH] register . ds $SEPARATOR\\n[#DEPTH] ) -. if \\n[#NUM_ARGS]=2 \{\ -. ie '\\$2'NONE' \{ .ds $SEPARATOR\\n[#DEPTH]\} -. el \{ .ds $SEPARATOR\\n[#DEPTH] \\$2\} +. 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 '\\*[$LIST_ARG_1]'ALPHA' \{\ +. nr #ARGS_TO_LIST 1 +. nr #ENUMERATOR\\n+[#DEPTH] 0 1 +. af #ENUMERATOR\\n[#DEPTH] A +. ds $ENUMERATOR_TYPE\\n[#DEPTH] register +. 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 '\\$1'USER' \{\ +. 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 +. \} +. 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 '\\*[$LIST_ARG_1]'USER' \{\ . nr #ARGS_TO_LIST 1 . ds $ENUMERATOR\\n+[#DEPTH] \\$2 +. ds $ENUMERATOR_TYPE\\n[#DEPTH] other . ds $SEPARATOR\\n[#DEPTH] +. ds $PREFIX\\n[#DEPTH] . \} . if \\n[#NUM_ARGS]=1 \{\ . if !r#ARGS_TO_LIST \{\ @@ -12048,11 +13431,17 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . \} . nr #TOTAL_LISTS \\n[#DEPTH] -. ie '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'register' \{\ -. nr #LIST_INDENT\\n[#DEPTH] \\w'm\\*[$SEPARATOR\\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]]\ ' +. \} . \} -. el \{\ -. nr #LIST_INDENT\\n[#DEPTH] \\w'\\*[$ENUMERATOR\\n[#DEPTH]]\\0' +. 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' . \} . LL \\n[#CURRENT_L_LENGTH]u . ie \\n[#DEPTH]=1 \{\ @@ -12098,6 +13487,10 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# receive the text of an item. \# .MAC ITEM END +. if \\n[#LINENUMBERS]=1 \{\ +. NUMBER_LINES OFF +. nr #LINENUMBERS 2 +. \} . if \\n[#KERN]=1 \{\ . nr #KERN_WAS_ON 1 . KERN OFF @@ -12106,38 +13499,304 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . ll \\n[#CURRENT_L_LENGTH]u \" Set ll again because IL turns IB off. . TRAP OFF . HI \\n[#HL_INDENT\\n[#DEPTH]]u -. ie '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'register' \{\ -. ie '\\g[#ENUMERATOR\\n[#DEPTH]]'0' \{\ +. 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]] +. \} +. \} +. 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]] +. \} +. \} +. \} +. el \{\ +. ie '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'register' \{\ +.\" DIGIT +. 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]] +. \} +. \} +. \} +. 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 \{\ +.\" 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]] +. \} +. \} +.\" alpha +. el \{\ +. PRINT \\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] +. \} +. \} +. \} +. \} +. el \{\ +. if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'roman' \{\ . ie \\n[#PAD_LIST_DIGITS\\n[#DEPTH]]=1 \{\ -. ie \\n[#ENUMERATOR\\n[#DEPTH]]<9 \{\ -. PRINT \\0\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] +.\" ROMAN I, padded +. ie '\\g[#ENUMERATOR\\n[#DEPTH]]'I' \{\ +. ie \\n[#SEP_TYPE]=1 \{\ +. PRINT "\h'\\n[#LIST_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\n[#SEPARATOR\\n[#DEPTH]]\ 'u'\v'-.085m'\\*[$PREFIX\\n[#DEPTH]]\v'.085m'\\n[#ENUMERATOR\\n[#DEPTH]]\v'-.085m'\\*[$SEPARATOR\\n[#DEPTH]]\v'.085m' +. \} +. el \{\ +. PRINT "\h'\\n[#LIST_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\n[#SEPARATOR\\n[#DEPTH]]\ 'u'\\*[$PREFIX\\n[#DEPTH]]\\n[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] +. \} . \} +.\" roman i, padded . el \{\ -. PRINT \\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] +. PRINT "\h'\\n[#LIST_INDENT\\n[#DEPTH]]u'\h'-\w'\\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\n[#SEPARATOR\\n[#DEPTH]]\ 'u'\\*[$PREFIX\\n[#DEPTH]]\\n[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] . \} . \} +.\" No pad . el \{\ -. PRINT \\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] +.\" 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]] +. \} +. \} +.\" roman i, no pad +. el \{\ +. PRINT \\*[$PREFIX\\n[#DEPTH]]\\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] +. \} . \} . \} -. el \{\ -. PRINT \\n+[#ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] +. if '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'other' \{\ +. PRINT \\*[$ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] . \} . \} -. el \{\ -. PRINT \\*[$ENUMERATOR\\n[#DEPTH]]\\*[$SEPARATOR\\n[#DEPTH]] -. \} +. rr #SEP_TYPE . EOL +. if \\n[#REF]=1 \{\ +. IL +\\*[$REF_BIB_INDENT] +. ti \\n[#L_INDENT]u-\\*[$REF_BIB_INDENT] +. \} . TRAP . if \\n[#KERN_WAS_ON]=1 \{\ . KERN . rr #KERN_WAS_ON . \} +. if \\n[#LINENUMBERS]=2 \{\ +. NUMBER_LINES RESUME +. nr #LINENUMBERS 1 +. \} .END \# +\# A utility macro that determines the space to reserve for +\# roman numeral enumerated lists. Limit is 20 roman numerals +\# per list. If this isn't enough, the user can add to the +\# macro. +\# +.MAC GET_ROMAN_INDENT END +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'2' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 2 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'4' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 4 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'6' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 6 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'8' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 8 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'10' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 10 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'12' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 12 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'14' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 14 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'16' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 16 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'18' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 18 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'20' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 20 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'2' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 2 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'4' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 4 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'6' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 6 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'8' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 8 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'10' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 10 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'12' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 12 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'14' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 14 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'16' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 16 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'18' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 18 +. 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' +. \} +. if '\\*[$ROMAN_WIDTH]'20' \{\ +. ds $ROMAN_WIDTH\\n[#DEPTH] 20 +. nr #LIST_INDENT\\n[#DEPTH] \w'\\*[$PREFIX\\n[#DEPTH]]XVIII\\*[$SEPARATOR\\n[#DEPTH]]\0' +. \} +. \} +.END \# \# SHIFT LIST -\# --------- +\# ---------- \# *Arguments: \# \# *Function: @@ -12146,8 +13805,15 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# Requires a unit of measure. \# .MAC SHIFT_LIST END -. nr #LIST_INDENT\\n[#DEPTH] \\n[#L_INDENT]+(\\$1) -. nr #L_INDENT \\n[#LIST_INDENT\\n[#DEPTH]] +. ie '\\*[$ENUMERATOR_TYPE\\n[#DEPTH]]'roman' \{\ +. nr #SHIFT_LIST\\n[#DEPTH] (\\$1) +. nr #LIST_INDENT\\n[#DEPTH] \\n(.i+\\n[#L_INDENT]+\\n[#SHIFT_LIST\\n[#DEPTH]] +. nr #L_INDENT \\n[#LIST_INDENT\\n[#DEPTH]] +. \} +. el \{\ +. nr #LIST_INDENT\\n[#DEPTH] \\n[#L_INDENT]+(\\$1) +. nr #L_INDENT \\n[#LIST_INDENT\\n[#DEPTH]] +. \} .END \# \# @@ -12166,6 +13832,12 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . nr #HL_INDENT\\n+[#DEPTH] +\\w'\\n[#ENUMERATOR\\n[#DEPTH]]' . 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 '\\g[#ENUMERATOR\\n[#DEPTH]]'I' \{\ +. if '\\$1'LEFT' \{ .nr #PAD_LIST_DIGITS\\n[#DEPTH] 1 \} +. \} .END \# \# @@ -12177,7 +13849,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# Resets register enumerators to 1 or a. \# .MAC RESET_LIST END -. nr #ENUMERATOR\\n[#DEPTH] 0 1 +. ie '\\$1'' \{ .nr #ENUMERATOR\\n[#DEPTH] 0 1 \} +. el \{ .nr #ENUMERATOR\\n[#DEPTH] \\$1-1 1 \} .END \# \# @@ -12222,7 +13895,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . rr #STORED_R_INDENT . rr #STORED_L_INDENT . \} -\# Clean up after exiting last depth of list +.\" Clean up after exiting last depth of list . nr #REMOVE 0 1 . while \\n+[#REMOVE]<=\\n[#TOTAL_LISTS] \{\ . rr #LIST_INDENT\\n[#REMOVE] @@ -12231,7 +13904,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . rr #SEPARATOR\\n[#REMOVE] . rm $ENUMERATOR_TYPE\\n[#REMOVE] . rr #PAD_LIST_DIGITS\\n[#REMOVE] -. \} +.\} . rr #REMOVE . rr #TOTAL_LISTS . rr #QUIT @@ -12258,8 +13931,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . nr #QUIT 1 . return . \} -. ie \\n[#NEXT_DEPTH_BACK]=1 \{ .nr #L_INDENT \\n[#LIST_INDENT1] \} -. el \{ .nr #L_INDENT -\\n[#LIST_INDENT\\n[#DEPTH]] \} +. nr #L_INDENT -\\n[#LIST_INDENT\\n[#DEPTH]] . nr #HL_INDENT \\n[#HL_INDENT\\n-[#DEPTH]] .END \# @@ -12293,7 +13965,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . IQ CLEAR . TQ -\# Collect first doc's title for TOC +.\" 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]\\| @@ -12329,7 +14001,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . \} . nr #COLLATED_DOC 1 . \} -\# End title collection for TOC +.\" End title collection for TOC . LL \\n[#DOC_L_LENGTH]u . QUAD $DOC_QUAD . nr #SAVED_DOC_LEAD \\n[#DOC_LEAD] @@ -12348,6 +14020,105 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .END \# \# +\# NUMBER_LINES +\# ------------ +\# *Arguments: +\# [ [ ] ] +\# or +\# | RESUME +\# *Function: +\# Begin, suspend/turn off, or resume numbering of output lines. +\# +.MAC NUMBER_LINES END +. br +. if '\\n(.z'EPI_TEXT' \{ .return \} +. if '\\$1'' \{\ +. 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. +. \} +. 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 \} +. ie '\\$2'' \{\ +. if '\\*[$LN_INC]'' .ds $LN_INC 1 +. \} +. el .ds $LN_INC \\$2 +. ie '\\$3'' \{\ +. if '\\*[$LN_GUTTER]'' .ds $LN_GUTTER 2 +. \} +. el .ds $LN_GUTTER \\$3 +. \} +. ie !\\n[#LN] \{\ +.\" In other words, the first arg was not a digit. +. rr #LN +. ie '\\$1'RESUME' \{\ +. nm +0 +. \} +. el \{\ +. nm +. if !\\n[#LINENUMBERS]=2 \{ .rr #LINENUMBERS \} +. \} +. \} +. el \{\ +. nm \\*[$LN_NUM] \\*[$LN_INC] \\*[$LN_GUTTER] -3-\\*[$LN_GUTTER] +. if !'\\n(.z'' \{ .nr #DIVER_LN_OFF 1 \} +. \} +. rr #LN +.END +\# +\# +\# NUMBER QUOTE AND BLOCKQUOTE LINES AS PART OF RUNNING TEXT +\# --------------------------------------------------------- +\# *Argument: +\# | +\# *Function: +\# Sets #(B)QUOTE_LN to 1 if no argument, or a single numeric +\# argument, is given; otherwise, turns (BLOCK)QUOTE linenumbering +\# off. +\# *Notes: +\# #(B)QUOTE is checked for in QUOTE and BLOCKQUOTE. +\# The single numeric argument allows establishing a different gutter from +\# the one used for line numbers in running text. +\# +.MAC NUMBER_QUOTE_LINES END +. 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 \} +. el \{\ +. rr #QUOTE_LN +. rr #SILENT_QUOTE_LN +. \} +. \} +. \} +.END +\# +\# +.MAC NUMBER_BLOCKQUOTE_LINES END +. 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 \} +. el \{\ +. rr #BQUOTE_LN +. rr #SILENT_BQUOTE_LN +. \} +. \} +. \} +.END +\# \# OUTPUT BLANK PAGES \# ------------------ \# *Argument: @@ -12358,6 +14129,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# If recto/verso, each page is recto/verso, even if there's \# nothing on it. \# +\# The argument to BLANKPAGE is non-optional. +\# .MAC BLANKPAGE END . nr #HOW_MANY \\$1 . nr #PAGES 0 1 @@ -12384,7 +14157,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . if \\n[#PAGE_NUM_V_POS]=1 \{\ . if \\n[#PAGINATE_WAS_ON] \{ .PAGINATE \} . \} -. \} +.\} . NEWPAGE . if \\n[#FOOTERS_WERE_ON] \{ .FOOTERS \} . if \\n[#PAGE_NUM_V_POS]=2 \{\ @@ -12410,58 +14183,58 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# exactly on #B_MARGIN. \# .MAC TRAPS END -\# Remove all header/footer traps +.\" Remove all header/footer traps . if !\\n[#NO_TRAP_RESET] \{\ . ch DO_T_MARGIN . ch DO_B_MARGIN . ch HEADER . ch FOOTER . ch FN_OVERFLOW_TRAP -\# Plant header trap +.\" Plant header trap . wh 0 HEADER . \} -\# Adjust lead so last line of text falls on B_MARGIN,... +.\" Adjust lead so last line of text falls on B_MARGIN,... . 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]-1v -\# Get the number of unadjusted lines that fit on the page; always a -\# bit short of the bottom margin +.\" 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 +.\" 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 -\# last line before the FOOTER trap is sprung +.\" 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 +.\" Get the difference between #B_MARGIN and #VISUAL_B_MARGIN . nr #FOOTER_DIFF (\\n[#PAGE_LENGTH]-\\n[#B_MARGIN])-\\n[#VISUAL_B_MARGIN] -\# Set #B_MARGIN to 1 machine unit lower on the page than #VISUAL_B_MARGIN +.\" Set #B_MARGIN to 1 machine unit lower on the page than #VISUAL_B_MARGIN . nr #B_MARGIN \\n[#B_MARGIN]+(\\n[#FOOTER_DIFF]-1) -\# Set the FN_OVERFLOW_TRAP position +.\" Set the FN_OVERFLOW_TRAP position . nr #FN_OVERFLOW_TRAP_POS \\n[#B_MARGIN]u-\\n[#FN_LEAD] . if \\n[#PRINT_STYLE]=1 .nr #FN_OVERFLOW_TRAP_POS \\n[#ORIGINAL_B_MARGIN]u . \} -\# ...or calculate new B_MARGIN based on # of lines (at #DOC_LEAD) that fit -\# on the page. +.\" ...or calculate new B_MARGIN based on # of lines (at #DOC_LEAD) that fit +.\" on the page. . el \{\ . nr #LINES_PER_PAGE 0 1 . nr #DEPTH_TO_B_MARGIN \\n[#PAGE_LENGTH]-\\n[#B_MARGIN]-1v . 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 #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] . \} -\# Set footer and footnote overflow traps +.\" Set footer and footnote overflow traps . if !\\n[#NO_TRAP_RESET] \{\ . nr #FN_COUNT 0 1 . nr #SPACE_REMAINING 0 @@ -12642,6 +14415,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .ALIAS PAGENUM PAGENUMBER .ALIAS PAGINATION PAGINATE .ALIAS PP_FT PP_FONT +.ALIAS REF_INDENT INDENT_REFS .ALIAS TOC_PS TOC_PT_SIZE \# \# HEADER and FOOTER macros @@ -12963,6 +14737,10 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# \# HEADER and FOOTER aliases for HDRFTR macros. \# +.ALIAS BIBLIOGRAPHY_FOOTER_CENTER BIBLIOGRAPHY_HDRFTR_CENTER +.ALIAS BIBLIOGRAPHY_FOOTER_CENTRE BIBLIOGRAPHY_HDRFTR_CENTRE +.ALIAS BIBLIOGRAPHY_HEADER_CENTER BIBLIOGRAPHY_HDRFTR_CENTER +.ALIAS BIBLIOGRAPHY_HEADER_CENTRE BIBLIOGRAPHY_HDRFTR_CENTRE .ALIAS ENDNOTES_FOOTER_CENTER ENDNOTES_HDRFTR_CENTER .ALIAS ENDNOTES_FOOTER_CENTRE ENDNOTES_HDRFTR_CENTRE .ALIAS ENDNOTES_HEADER_CENTER ENDNOTES_HDRFTR_CENTER @@ -13002,6 +14780,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' \# Type-style aliases \# .ALIAS AUTHOR_FAMILY _FAMILY +.ALIAS BIBLIOGRAPHY_FAMILY _FAMILY +.ALIAS BIBLIOGRAPHY_STRING_FAMILY _FAMILY .ALIAS BLOCKQUOTE_FAMILY _FAMILY .ALIAS CHAPTER_TITLE_FAMILY _FAMILY .ALIAS COVER_AUTHOR_FAMILY _FAMILY @@ -13022,6 +14802,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .ALIAS DOCTYPE_FAMILY _FAMILY .ALIAS ENDNOTE_FAMILY _FAMILY .ALIAS ENDNOTE_NUMBER_FAMILY _FAMILY +.ALIAS ENDNOTE_LINENUMBER_FAMILY _FAMILY .ALIAS ENDNOTE_STRING_FAMILY _FAMILY .ALIAS ENDNOTE_TITLE_FAMILY _FAMILY .ALIAS EPIGRAPH_FAMILY _FAMILY @@ -13047,6 +14828,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .ALIAS TOC_TITLE_FAMILY _FAMILY \# .ALIAS AUTHOR_FONT _FONT +.ALIAS BIBLIOGRAPHY_STRING_FONT _FONT +.ALIAS BIBLIOGRAPHY_FONT _FONT .ALIAS BLOCKQUOTE_FONT _FONT .ALIAS CHAPTER_TITLE_FONT _FONT .ALIAS COVER_AUTHOR_FONT _FONT @@ -13064,6 +14847,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .ALIAS DOCTYPE_FONT _FONT .ALIAS ENDNOTE_FONT _FONT .ALIAS ENDNOTE_NUMBER_FONT _FONT +.ALIAS ENDNOTE_LINENUMBER_FONT _FONT .ALIAS ENDNOTE_STRING_FONT _FONT .ALIAS ENDNOTE_TITLE_FONT _FONT .ALIAS EPIGRAPH_FONT _FONT @@ -13086,6 +14870,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .ALIAS TOC_TITLE_FONT _FONT \# .ALIAS AUTHOR_SIZE _SIZE +.ALIAS BIBLIOGRAPHY_STRING_SIZE _SIZE .ALIAS BLOCKQUOTE_SIZE _SIZE .ALIAS CHAPTER_TITLE_SIZE _SIZE .ALIAS COVER_AUTHOR_SIZE _SIZE @@ -13102,6 +14887,7 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .ALIAS DOC_COVER_TITLE_SIZE _SIZE .ALIAS DOCTYPE_SIZE _SIZE .ALIAS ENDNOTE_NUMBER_SIZE _SIZE +.ALIAS ENDNOTE_LINENUMBER_SIZE _SIZE .ALIAS ENDNOTE_STRING_SIZE _SIZE .ALIAS ENDNOTE_TITLE_SIZE _SIZE .ALIAS EPIGRAPH_SIZE _SIZE @@ -13165,6 +14951,8 @@ E\\R'#CAP_HEIGHT \\n[.cht]' .ALIAS SUBTITLE_COLOR _COLOR .ALIAS TITLE_COLOR _COLOR \# +.ALIAS BIBLIOGRAPHY_QUAD _QUAD +.ALIAS BIBLIOGRAPHY_STRING_QUAD _QUAD .ALIAS BLOCKQUOTE_QUAD _QUAD .ALIAS COVER_COPYRIGHT_QUAD _QUAD .ALIAS COVER_MISC_QUAD _QUAD @@ -13207,3 +14995,892 @@ E\\R'#CAP_HEIGHT \\n[.cht]' . br . sp -1v .END +\# +\# REFER SUPPORT +\# ------------- +\# +\# Footnote references +\# ------------------- +\# *Function: +\# Instruct REF to put references in footnotes. +\# +.MAC FOOTNOTE_REFS END +. if r#EN_REF \{ .rr #EN_REF \} +. nr #FN_REF 1 +.END +\# +\# Endnote references +\# ------------------ +\# *Function: +\# Instruct REF to collect references for endnotes output. +\# +.MAC ENDNOTE_REFS END +. if r#FN_REF \{ .rr #FN_REF \} +. nr #EN_REF 1 +.END +\# +\# Prepare mom for a reference +\# --------------------------- +\# *Argument: +\# | INDENT L|LEFT|R|RIGHT|B|BOTH +\# *Function: +\# Calls FOOTNOTE or ENDNOTE, depending on whether #REF_FN or +\# #REF_EN is set to 1. +\# *Notes: +\# For convenience, REF is a toggle. +\# +\# REF optionally takes the same arguments as FOOTNOTE, allowing +\# users to indent references that go in footnotes when footnote +\# indenting is required. FOOTNOTE_REFS must be on for this. +\# +.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 " 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. +. nr #REF_WARNING 1 +. \} +. \} +. el \{\ +. ie \\n[#REF]=1 \{\ +. 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 \} +. \} +. \} +.END +\# +\# Embedded references in text (with brackets) +\# ------------------------------------------- +\# +.MAC REF_BRACKETS_START END +. ds $CURRENT_EV \\n[.ev] +. ev REFERENCE +. evc \\*[$CURRENT_EV] +. di REFERENCE +.END +\# +.MAC REF_BRACKETS_END END +. br +. di +. ev +. chop REFERENCE +. unformat REFERENCE +. if '\\$0'REF)' \{ .nop (\\*[REFERENCE]) \} +. if '\\$0'REF]' \{ .nop [\\*[REFERENCE]] \} +. if '\\$0'REF}' \{ .nop {\\*[REFERENCE]} \} +.END +\# +\# These three pairs of aliases allow users to embed references in +\# text and have them surrounded by (), [] or {}. +\# +.ALIAS REF( REF_BRACKETS_START +.ALIAS REF) REF_BRACKETS_END +\# +.ALIAS REF[ REF_BRACKETS_START +.ALIAS REF{ REF_BRACKETS_START +\# +.ALIAS REF} REF_BRACKETS_END +.ALIAS REF] REF_BRACKETS_END +\# +\# Second-line indent for refs +\# --------------------------- +\# *Argument: +\# FOOTNOTE | ENDNOTE | BIBLIO +\# *Function: +\# Sets strings $REF_FN_INDENT, $REF_EN_INDENT or $REF_BIB_INDENT. +\# *Notes: +\# Indent value requires a unit of measure. +\# +.MAC INDENT_REFS END +. if '\\$1'FOOTNOTE' .ds $REF_FN_INDENT \\$2 +. if '\\$1'ENDNOTE' .ds $REF_EN_INDENT \\$2 +. if '\\$1'BIBLIO' .ds $REF_BIB_INDENT \\$2 +.END +\# +\# Hyphenation of references +\# ------------------------- +\# *Argument: +\# | +\# *Function: +\# Sets register #REF_HYPHENATE +\# +.MAC HYPHENATE_REFS END +. ie '\\$1'' \{ .nr #REF_HYPHENATE 1 \} +. el \{\ +. if r#REF_HY \{ .rr #REF_HY \} +. \} +.END +\# +.ig +The remainder of the definitions in this section are modified +versions of the definitions found in the refer module of s.tmac. +.. +\# +\# This one is directly from s.tmac. +.de @error +.tm \\n(.F:\\n(.c: macro error: \\$* +.. +\# +.ig +The following strings define the order of entries for different +types of references. Each letter in the string refers to a database +field (A for author, T1/T2 for article and book titles, etc). +Mom is set up for MLA-style bibliographies. Other styles can be +implemented here by re-ordering the fields. +.. +\# Book - type 2 +.ds ref*spec!2 Q A T1 d t l r E S e V a C I D P O +\# Article within book - type 3 +.ds ref*spec!3 Q A T2 B d t l r E S e V a C I D P O +\# Journal article - type 1 +.ds ref*spec!1 Q A T2 J S N D P O +\# Tech report - type 4 +.ds ref*spec!4 Q A T1 R G C I D P O +\# Internet site - type 0 +.ds ref*spec!0 Q A T2 s E c d o a u O +\# +\# Refer's "1st" macro. Since it is possible to define database +\# fields using any single letter, we remove all possible string +\# definitions of the form [X and [x +\# +.de ]- +.rm [A [B [C [D [E [F [G [H [I [J [K [L [M \ + [N [O [P [Q [R [S [T [U [V [W [X [Y [Z \ +. [a [b [c [d [e [f [g [h [i [j [k [l [m \ + [n [o [p [q [r [s [t [u [v [w [x [y [z +.rm ref*string +.rr ref*type +.. +\# +\# Refer's "2nd" macro; builds up a reference with ref*build, and +\# prints it with ref*print. +\# +.de ][ +.nr ref*type \\$1 +.if \\n[ref*type]=3 \{\ +. if !'\\*([R'' \{\ +. nr ref*type 4 +. ds ref*spec!4 Q A T2 B R C I D P O +. \} +. if !'\\*([G'' \{\ +. nr ref*type 4 +. ds ref*spec!4 Q A T2 B G C I D P O +. \} +.\} +.if r [T \{\ +. als [T1 [T +. als [T2 [T +.\} +.ie d ref*spec!\\n[ref*type] .ref*build \\*[ref*spec!\\n[ref*type]] +.el \{\ +. @error unknown reference type `\\n[ref*type]' +. ref*build \\*[ref*spec!0] +.\} +.if !\\n[.hy]=0 \{\ +.nr #RESTORE_HY \\n[.hy] +.if !r#REF_HY .nh +.\} +.ref*print +.if !\\n[#RESTORE_HY]=0 .hy \\n[#RESTORE_HY] +.rr #RESTORE_HY +.rm ref*string +.rm [F [T1 [T2 +.. +\# +\# Refer's "3rd" macros, which set up and terminate the output +\# of collected references +\# +.de ]< +.als ref*print ref*end-print +.nr #REF 1 +.if \\n[#BIB_LIST]=1 \{\ +. nr #IN_BIB_LIST 1 +. LIST DIGIT \\*[$BIB_LIST_SEPARATOR] \\*[$BIB_LIST_PREFIX] +.\} +.. +\# +.de ]> +.LIST OFF +.rr #REF +.rr #IN_BIB_LIST +.als ref*print ref*normal-print +.. +\# +\# Output +\# ------ +\# +\# Output normal, non-collected refs +\# +.de ref*normal-print +.nr #CURRENT_HY \\n[.hy] +\\*[ref*string] +.. +\# +\# Output collected refs +\# +.de ref*end-print +.\" 10 is abritrary +.nn 10 +.ie \\n[#BIB_LIST]=0 \{\ +.in +\\*[$REF_BIB_INDENT] +.ti -\\*[$REF_BIB_INDENT] +.\} +.el .ITEM +\\*[ref*string] +.sp \\n[#BIB_SPACE]u +.ie \\n[#BIB_LIST]=0 .in +.el .IL -\\*[$REF_BIB_INDENT]u +.nn 0 +.. +\# +.als ref*print ref*normal-print +\# +\# Build up the ref*string +\# +.ig +Correct MLA "typewritten" style (printstyle TYPEWRITE) demands +two spaces after each period. The spaces are hardwired into the +string definitions (ref*add-), so we have to make sure that there +aren't two spaces when the printstyle is TYPESET. Since I find that +references look a bit crowded with 0 sentence space, I've bumped it +up to +4. User's sentence spacing is reset in FOOTNOTES and ENDNOTES. +.. +\# +.de ref*build +.if \\n[#PRINT_STYLE]=2 \{\ +. ds $RESTORE_SS_VAR \\*[$SS_VAR] +. SS +4 +.\} +.rm ref*string ref*post-punct +.nr ref*suppress-period 1 +.while \\n[.$] \{\ +. if d [\\$1 \{\ +. ie d ref*add-\\$1 .ref*add-\\$1 +. el .ref*add-dflt \\$1 +. \} +. shift +.\} +.\" now add a final period +.ie d ref*string \{\ +. if !\\n[ref*suppress-period] .as ref*string . +. if d ref*post-punct \{\ +. as ref*string "\\*[ref*post-punct] +. rm ref*post-punct +. \} +.\} +.el .ds ref*string +.. +\# +\# The following macros determine how entries are formatted WRT +\# punctuation, type style, additional strings, etc. +\# +.ig +o First argument is the database field letter. +o Second argument is the punctuation character to use to separate this + field from the previous field. +o Third argument is a string with which to prefix this field. +o Fourth argument is a string with which to postfix this field. +o Fifth argument is a string to add after the punctuation character + supplied by the next field. +.. +\# +\# %A Author(s) +.de ref*add-A +.ref*field A , +.if r [A .nr ref*suppress-period \\n([A +.. +\# %T Title (generic) +.de ref*add-T1 +.ref*field T . " \E*[IT]" "" \E*[PREV] +.if \\n([T .nr ref*suppress-period \\n([T +.. +\# %T Title of a chapter or article +.de ref*add-T2 +.ref*field T . " \(lq" "" "\(rq" +.if \\n([T .nr ref*suppress-period \\n([T +.. +\# %B Book title (when citing an article from a book) +.de ref*add-B +.ie \\n([T .ref*field B "" ".\E*[IT]" "" \E*[PREV] +.el .ref*field B . " \E*[IT]" "" \E*[PREV] +\# refer doesn't set reg [T to 1 for these book titles, so we do it here +.ds eval*[B \\*([B +.substring eval*[B -1 +.rr [T +.if '\\*[eval*[B]'!' .nr [T 1 +.if '\\*[eval*[B]'?' .nr [T 1 +.rm eval*[B +.. +\# %R Report number for technical reports +.de ref*add-R +.ref*field R . " " +.. +\# %J Journal name +.de ref*add-J +.ie \\n([T .ref*field J "" " \E*[IT]" "" \E*[PREV] +.el .ref*field J . " \E*[IT]" "" \E*[PREV] +.. +\# %E Editor(s) +.de ref*add-E +.ie !\\n[ref*type]=0 \{\ +. ie \\n([E>0 \{\ +. ie \\n([T .ref*field E "" " Eds. " +. el .ref*field E . " Eds. " +. \} +. el \{\ +. ie \\n([T .ref*field E "" " Ed. " +. el .ref*field E . " Ed. " +. \} +.\} +.el \{\ +. ie \\n([T .ref*field E "" " " +. el .ref*field E . " " +.\} +.rr [T +.. +\# %e Edition +.de ref*add-e +.ie \\n([T .ref*field e "" " " " edition" +.el .ref*field e . " " " edition" +.rr [T +.. +\# %V Volume (of a journal, or series of books) +.de ref*add-V +.if \\n[ref*type]=1 \{\ +. ref*field V +.\} +.if \\n[ref*type]=2 \{\ +. ie \\n([T .ref*field V "" " " +. el .ref*field V . " " +.\} +.if \\n[ref*type]=3 \{\ +. ie \\n([T .ref*field V "" " " +. el .ref*field V . " " +.\} +.rr [T +.. +\# %N Journal number +.de ref*add-N +.ref*field N +.. +\# %S Series (books or journals) +.de ref*add-S +.if \\n[ref*type]=1 \{\ +. ref*field S +.\} +.if \\n[ref*type]=2 \{\ +. ie \\n([T .ref*field S "" " " +. el .ref*field S . " " +.\} +.if \\n[ref*type]=3 \{\ +. ie \\n([T .ref*field S "" " " +. el .ref*field S . " " +.\} +.rr [T +\# refer doesn't set reg [T to 1 for series titles, so we do it here +.ds eval*[S \\*([S +.substring eval*[S -1 +.if '\\*[eval*[S]'!' .nr [T 1 +.if '\\*[eval*[S]'?' .nr [T 1 +.rm eval*[S +.. +\# %C City +.de ref*add-C +.ie \\n([T .ref*field C "" " " +.el .ref*field C . " " +.rr [T +.. +\# %I Publisher (I stands for Issuer) +.de ref*add-I +.ie !'\\*([C'' .ref*field I : +.el \{\ +. ie \\n([T .ref*field I "" " " +. el .ref*field I . " " +.\} +.rr [T +.. +\# %D Date of publication +.de ref*add-D +.if \\n[ref*type]=1 \{\ +. ie !'\\*([V''.ref*field D "" "(" ")" +. el .ref*field D +.\} +.if \\n[ref*type]=2 .ref*field D , +.if \\n[ref*type]=3 \{\ +. ie '\\*([C'' \{\ +. ie '\\*([I'' .ref*field D . " " +. el .ref*field D , +. \} +. el .ref*field D , +.\} +.if \\n[ref*type]=4 .ref*field D , +.. +\# %P Page number(s) +.de ref*add-P +.ie \\n[ref*type]=1 .ref*field P : +.el .ref*field P . " " +.. +\# %G Gov't. ordering number +.de ref*add-G +.ref*field G . " " +.. +\# %O Other (usually goes at end of ref) +.de ref*add-O +.ref*field O . " " +.ie r [O .nr ref*suppress-period \\n([O +.el .nr ref*suppress-period 1 +.. +\# +.de ref*add-dflt +.ref*field \\$1 , +.. +\# +\# Book reprints +\# ------------- +\# %d date of publication (the orignal date of publication) +.de ref*add-d +.ie \\n([T .ref*field d "" " " +.el .ref*field d . " " +.rr [T +.. +\# %a additions (such as a new intro to reprints) +.de ref*add-a +.ie \\n([T .ref*field a "" " " +.el .ref*field a . " " +.rr [T +.. +\# %t title, if different from original title (the T field, which s/b +\# the original title) +.de ref*add-t +.ie \\n([T .ref*field t "" " Rpt. as \E*[IT]" "" \E*[PREV] +.el .ref*field t . " Rpt. as \E*[IT]" "" \E*[PREV] +.rr [T +.. +\# +\# Translated works +\# ---------------- +\# %l Trans(l)ator +.de ref*add-l +.ie \\n([T .ref*field l "" " Trans. " +.el .ref*field l . " Trans. " +.rr [T +.. +\# %r Translato(r) and edito(r) +.de ref*add-r +.ie \\n([T .ref*field r "" " Trans. and Ed. " +.el .ref*field r . " Trans. and Ed. " +.rr [T +.. +\# +\# Internet +\# -------- +\# %s Site name +.de ref*add-s +.ie \\n([s .ref*field s "" ".\E*[IT]" "" \E*[PREV] +.el .ref*field s . " \E*[IT]" "" \E*[PREV] +.\" refer doesn't set reg [T to 1 for these book titles, so we do it here +.ds eval*[s \\*([s +.substring eval*[s -1 +.rr [T +.if '\\*[eval*[s]'!' .nr [T 1 +.if '\\*[eval*[s]'?' .nr [T 1 +.rm eval*[s +.. +\# %c content of site, if unclear (i.e. advertisement, cartoon, +\# interview, etc.) +.de ref*add-c +.ie \\n([T .ref*field c "" " " +.el .ref*field c . " " +.rr [T +.. +\# %o organization, group or sponsor of site +.de ref*add-o +.ie \\n([T .ref*field o "" " " +.el .ref*field o . " " +.rr [T +.. +\# %a access date, i.e. the date you read it +.de ref*add-a +.ie \\n([T .ref*field a "" " " +.el .ref*field a . " " +.rr [T +.. +\# %u URL +.de ref*add-u +.ref*field u "" " <" ">" +.rr [T +.. +\# +\# Build up reference string from ref*add- macros. +\# +.de ref*field +.if d ref*string \{\ +. ie d ref*post-punct \{\ +. as ref*string "\\$2\\*[ref*post-punct] \" +. rm ref*post-punct +. \} +. el .as ref*string "\\$2 \" +.\} +.as ref*string "\\$3\\*([\\$1\\$4 +.if \\n[.$]>4 .ds ref*post-punct "\\$5 +.nr ref*suppress-period 0 +.. +\# +\# 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. +\# +.MAC MN_INIT END +. if !'\\$1'rerun' \{\ +. ds $MN-arg1 \\$1 +. ds $MN-arg2 \\$2 +. ds $MN-arg3 \\$3 +. ds $MN-arg4 \\$4 +. ds $MN-arg5 \\$5 +. ds $MN-arg6 \\$6 +. ds $MN-arg7 \\$7 +. ds $MN-arg8 \\$8 +. ds $MN-arg9 \\$9 +. \} +. ie \\n[#START_FOR_MNinit]=0 \{\ +. nr #MNinit_DEFERRED 1 +. nr #START_FOR_MNinit 1 +. return +. \} +. el \{\ +. 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 +. if \\n[#OVERFLOW_LEFT]=1 \{\ +. nr #no-repeat-MN-left 1 +. di MN_OVERFLOW_LEFT +. \} +. if \\n[#OVERFLOW_RIGHT]=1 \{\ +. nr #no-repeat-MN-right 1 +. di MN_OVERFLOW_RIGHT +. \} +. rr #OVERFLOW_LEFT +. rr #OVERFLOW_RIGHT +.END +\# +.ig +The remainder of the margin notes macros and routines are adapted +from Werner Lemberg's MN.tmac. +.. +\# +\# MNinit +\# ------ +\# Usage: +\# MNinit [ragged|symmetric] \ +\# left-width right-width separation \ +\# font fontsize vertical-spacing \ +\# color hyphenation-flags +\# +\# Initialize margin notes. Empty arguments (denoted with "") set +\# default values. If the first argument is the string `ragged', +\# left and right margin notes are printed ragged-right. If it is +\# `symmetric', left margin notes are printed ragged-left and right +\# 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'RAGGED' \{\ +. ds MN-left-ad l\" +. ds MN-right-ad l\" +. shift +. \} +. if '\\$1'SYMMETRIC' \{\ +. ds MN-left-ad r\" +. ds MN-right-ad l\" +. shift +. \} +. 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' \{\ +. nr MN-left-width (n;\\$1) +. nr MN-left-start (\\n[.o] - \\n[MN-sep] - \\n[MN-left-width]) +. \} +. el \{\ +. nr MN-left-width (\\n[.o] - \\n[MN-sep]) +. nr MN-left-start 0 +. \} +. if (\\n[MN-left-start] < 0) \ +. ab MN: Left margin too small for requested margin notes settings. +. if (\\n[MN-left-width] < 1n) \ +. ab MN: Left margin notes width too small (<1n). +. +. ie \B'\\$2' \{\ +. nr MN-right-width (n;\\$2) +. nr MN-right-start (\\n[.o] + \\n[.l] + \\n[MN-sep]) +. if \\n[#COLUMNS]=1 \{\ +. if !\\n[#NUM_COLS]=1 \{\ +. nr MN-right-start (\\n[#COL_2_L_MARGIN] + \\n[#COL_L_LENGTH] + \\n[MN-sep]) +. \} +. \} +. \} +. el \{\ +. nr MN-right-width \\n[MN-left-width] +. nr MN-right-start (\\n[.o] + \\n[.l] + \\n[MN-sep]) +. if \\n[#COLUMNS]=1 \{\ +. if !\\n[#NUM_COLS]=1 \{\ +. nr MN-right-start (\\n[#COL_2_L_MARGIN] + \\n[#COL_L_LENGTH] + \\n[MN-sep]) +. \} +. \} +. \} +. ie \A'\\$4' \{\ +. ds MN-font \\$4\" +. if \\n[#PRINT_STYLE]=1 .ds MN-font CR +. \} +. el \{\ +. ds MN-font \\*[$PP_FT] +. if \\n[#PRINT_STYLE]=1 .ds MN-font CR +. \} +. ie \B'\\$5' \{\ +. ps \\$5 +. nr MN-size \\n[.ps] +. ps +. if \\n[#PRINT_STYLE]=1 \{\ +. ps 12 +. nr MN-size \\n[.ps] +. ps +. \} +. \} +. el \{\ +. nr MN-size \\n[#DOC_PT_SIZE] +. \} +. ie \B'\\$6' \{\ +' vs \\$6 +. 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] +. \} +. 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] +. 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 +. ll \\n[MN-left-width]u +. ad \\*[MN-left-ad] +. hy \\n[MN-hy] +' in 0 +. 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 +. ll \\n[MN-right-width]u +. ad \\*[MN-right-ad] +. hy \\n[MN-hy] +' in 0 +. nop \m[\\*[MN-color]]\c +. ev +. nr MN-active 0 +.. +\# MN +\# -- +\# Usage: +\# +\# MN LEFT|RIGHT +\# margin note text +\# MN +\# +\# With a parameter, start a margin note, otherwise end a margin note. +\# If the parameter is the string `left', define a left margin note, +\# otherwise define a right margin note. +\# +.de MN +.ds MN-dir \\$1 +.if \\n[#COLUMNS]=1 \{\ +. if \\n[#NUM_COLS]>2 \{\ +. tm MN: More than two columns. Ignoring margin notes. +. return +. \} +. if !\\n[#NUM_COLS]=1 \{\ +. ie \\n[#COL_NUM]=1 .ds MN-dir LEFT +. el .ds MN-dir RIGHT +. \} +.\} +. if !\\n[#MNinit]=1 \{\ +. tm MN: You must set parameters with MN_INIT before using MN. +. ab Aborting +. \} +. ie !'\\$1'' \{\ +. if \\n[MN-active] \{\ +. tm MN: Can't handle nested margin notes. +. return +. \} +. nr MN-active 1 +. ev MN-env +. ie '\\*[MN-dir]'LEFT' \{\ +. nr MN-left +1 +. ds MN-curr l-\\n[MN-left]\" +. evc MNbottom-left-env +. \} +. el \{\ +. nr MN-right +1 +. ds MN-curr r-\\n[MN-right]\" +. evc MNbottom-right-env +. \} +. mk MN-mk-\\*[MN-curr] +. di MN-div-\\*[MN-curr] +. \} +. el \{\ +. if \\n[MN-active] \{\ +. br +. di +. nr MN-div-\\*[MN-curr]-depth \\n(dn +. ev +. \} +. nr MN-active 0 +. \} +.. +\# +\# MNtop +\# ----- +\# Resets these registers (called in HEADER) +.de MNtop +. nr MN-left 0 +. nr MN-right 0 +. nr MN-active 0 +.. +\# +\# MNbottom-left +\# ------------- +\# The "left" half of Werner's original MNbottom. +\# +.de MNbottom-left +. nr MN-curr 0 +. nr MN-last-pos 0 +. nr MN-lead-adj \\n[#DOC_LEAD]-\\n[MN-spacing] +. vpt 0 +. mk MN-curr-pos +. if \\n[MN-active] \{\ +. di +. tm MN: Margin note finished by new page. Ignored. +. \} +. po \\n[MN-left-start]u +. ev MNbottom-left-env +. nr #P \\n%+\\n[#PAGE_NUM_ADJ] +. while (\\n[MN-curr] < \\n[MN-left]) \{\ +. nr MN-curr +1 +. ie (\\n[MN-last-pos] < \\n[MN-mk-l-\\n[MN-curr]]) \ +. sp |\\n[MN-mk-l-\\n[MN-curr]]u+\\n[MN-lead-adj]u +. el \{\ +. nr MN-shifted 1 +. sp 1v +. SHIM +. if \\n[#SHIM]u>\\n[MN-spacing] .sp -(1v+\\n[MN-lead-adj]u) +. tm 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]) ) \{\ +. if \\n[MN-shifted]=1 \{\ +. sp -(1v+\\n[#SHIM]u) +. rm MN-div-l-\\n[MN-curr] +. tm1 "[mom]: No room to start left margin note #\\n[MN-curr] on page \\n[#P] on page \\n[#P]. +. tm1 " Ignoring margin note. +. rr MN-shifted +. \} +. nr #no-repeat-MN-left 1 +. nr #OVERFLOW_LEFT 1 +. wh \\n[.p]u+\\n[#VARIABLE_FOOTER_POS]u-1u MN_OVERFLOW_TRAP +. vpt 1 +. \} +. MN-div-l-\\n[MN-curr] +. br +. nr MN-last-pos \\n[nl] +.\} +. ev +. po +. if !\\n[#no-repeat-MN-left]=1 \{\ +. if \\n[MN-right]=0 .vpt 1 +. \} +.. +\# +\# MNbottom-right +\# -------------- +\# The "right" half of Werner's original MNbottom. +\# +.de MNbottom-right +. nr MN-curr 0 +. nr MN-last-pos 0 +. nr MN-lead-adj \\n[#DOC_LEAD]-\\n[MN-spacing] +. vpt 0 +. po \\n[MN-right-start]u +. ev MNbottom-right-env +. nr #P \\n%+\\n[#PAGE_NUM_ADJ] +. while (\\n[MN-curr] < \\n[MN-right]) \{\ +. nr MN-curr +1 +. ie (\\n[MN-last-pos] < \\n[MN-mk-r-\\n[MN-curr]]) \ +. sp |\\n[MN-mk-r-\\n[MN-curr]]u+\\n[MN-lead-adj]u +. el \{\ +. nr MN-shifted 1 +. sp 1v +. SHIM +. tm 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]) ) \{\ +. 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 " Ignoring margin note. +. rr MN-shifted +. \} +. nr #no-repeat-MN-right 1 +. nr #OVERFLOW_RIGHT 1 +. wh \\n[.p]u+\\n[#VARIABLE_FOOTER_POS]u-1u MN_OVERFLOW_TRAP +. vpt 1 +. \} +. MN-div-r-\\n[MN-curr] +. br +. nr MN-last-pos \\n[nl] +.\} +. ev +. po +' sp |\\n[MN-curr-pos]u +. if !\\n[#no-repeat-MN-right]=1 .vpt 1 +.. -- 2.11.4.GIT
                38. Output a blank pageCollate multiple documentsGet leading back on trackCollate multiple +
                  documents
                  Get leading back +
                  on track
                  BLANKPAGE