Back to Table of Contents Next: Cover pages

Recto/verso printing, collating


Introduction to recto/verso printing

Recto/verso printing allows you to set up a mom document in such a way that it can be printed on both sides of a printer sheet and subsequently bound.

With recto/verso, mom automatically takes control of the following aspects of alternating page layout:


Recto/verso macros

Macro: RECTO_VERSO

If you want mom to set up alternating pages for recto/verso printing, simply invoke RECTO_VERSO, with no argument, anywhere in your document (most likely before START).

Note: Recto/verso always switches the left and right parts of headers or footers on odd/even pages. However, it only switches the left and right margins if the margins aren’t equal. Consequently, it is your responsibility to set the appropriate differing left and right margins with L_MARGIN and R_MARGIN (prior to START) or with DOC_LEFT_MARGIN and DOC_RIGHT_MARGIN (before or after START).

Equally, recto/verso only switches the page number position if page numbers aren’t centred, which means you have to set the page number position with PAGENUM_POS (before or after START).

Macro: SWITCH_HEADERS

SWITCH_HEADERS switches the location of the header left string (by default, the author) and the header right string (by default, the document title). If you don’t like mom’s default placement of author and title, use SWITCH_HEADERS to reverse it.

SWITCH_HEADERS can also be useful in conjunction with RECTO_VERSO. The assumption of RECTO_VERSO is that the first page of a document (ie recto/odd) represents the norm for header-left and header-right, meaning that the second (and all subsequent verso/even) pages of the document will reverse the order of header-left and header-right.

If mom’s behaviour in this matter is not what you want, simply invoke SWITCH_HEADERS on the first page of your recto/verso document to reverse her default treatment of header parts. The remainder of your document (with respect to headers) will come out as you want.


Introduction to collating

Many people wisely keep chapters of a long work in separate files, previewing or printing them as needed during the draft phase. However, when it comes to the final version, mom requires a single, collated file in order to keep track of page numbering and recto/verso administration, generating tables of contents and endnotes, ensuring that docheaders get printed correctly, and a host of other details.

The COLLATE macro, which can be used with any DOCTYPE except LETTER, lets you glue mom-formatted text files together. You need only concatenate chapters into a single file (most likely with the cat command), put .COLLATE at the end of each concatenated chapter, follow it with the reference macros (metadata) needed for the new chapter, eg CHAPTER or CHAPTER_STRING, make any pertinent style changes to the upcoming chapter (unlikely, but possible), and re-invoke the START macro. (Most likely, the metadata and .START are already there.) Each chapter will begin on a fresh page and behave as expected.

Even if you always work with monolithic, multi-chapter files, every chapter and its associated metadata plus .START still needs to be preceded by a .COLLATE command.

Note: COLLATE assumes you are collating documents/files with similar type-style parameters hence there’s no need for PRINTSTYLE to appear after COLLATE, although if you’re collating documents that were created as separate files, chances are the PRINTSTYLE’s already there.

Two words of caution:

  1. Do not collate documents of differing PRINTSTYLES (ie don’t try to collate a TYPESET document and TYPEWRITE document).
  2. Use .DOC_FAMILY instead of .FAMILY if, for some reason, you want to change the family of all the document elements after .COLLATE. .FAMILY, by itself, will change the family of paragraph text only.

collate

Macro: COLLATE

The most basic (and most likely) collating situation looks like this:
.COLLATE .CHAPTER 17 .START

A slightly more complex version of the same thing, for chapters that require their own titles, looks like this:
.COLLATE .CHAPTER_TITLE "Geek Fatigue: Symptoms and Causes" .START

Tip: If the last line of text before .COLLATE falls too close to the bottom margin, or if the line is followed by a macro likely to cause a linebreak (eg .LIST OFF or .IQ), mom may output a superfluous blank page before the start of the following document.

In order to avoid this, insert .EL after the last line of text, before .COLLATE and/or any concluding macros. For example,
some concluding text. .EL .COLLATE or
some concluding text. .EL .LIST OFF .COLLATE

Note: See the two words of caution, above.


Back to Table of Contents Top Next: Cover pages