Next Prev Back to Table of Contents

# Recto/verso printing, collating

- Introduction to recto/verso

- Macro list

- Introduction to collating

- The COLLATE macro

## Introduction to recto/verso

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:

- switching left and right margins (if they're not equal)
- switching the left and right parts of the default 3-part headers or footers (see the General description of headers)
- switching HEADER_RECTO and HEADER_VERSO if user-defined, single string recto/verso headers or footers are used in place of the default 3-part headers or footers
- switching the page number position (if page numbers are not centred)

It is beyond the scope of this documentation to cover the different ways in which you can make your printer print on both sides of a sheet. A simple but effective method for those of us with "dumb" printers is to open the document (after it's been processed into PostScript by groff — see How to invoke groff with mom) in gv (ghostview), click the "odd pages" icon, then click "Print Marked". After printing is complete, rearrange the sheets appropriately, put them back in your printer, and have gv print the "even pages". If you prefer to work from the command line, check out the man pages for pstops and psbook. There are other programs out there as well to help with two-sided printing.

### Recto/verso macros list

- RECTO_VERSO
- SWITCH_HEADERS (also FOOTERS) — switch position of the header parts (left and right)

Macro: RECTO_VERSO

If you want mom to set up alternating pages for recto/verso printing, simply invoke RECTO_VERSO with no argument.

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 (recto/odd) represents the norm for header-left and header-right, meaning that the second (and all subsequent even) page(s) of the document exchange 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

The macro COLLATE lets you join documents together. Primarily, it's a convenience for printing long documents that comprise several chapters, although it could be used for any document type (except LETTER).

Personally, I prefer to keep chapters in separate files and print them out as needed. However, that means keeping track of the correct starting page number for each chapter, a problem circumvented by the use of COLLATE.

When collating chapters, you need only put `.COLLATE` at the end of a chapter, follow it with any reference macros needed for the new chapter, e.g. CHAPTER or CHAPTER_STRING, make any pertinent style changes to the document (unlikely, but possible), and re-invoke the START macro. Your new chapter will begin on a fresh page and behave as expected.

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 (i.e. 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.

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

NOTE: See the two words of caution, above.

Next Prev Top Back to Table of Contents