[Go to CFHT Home Page] Man Pages
Back to Software Index  BORDER=0Manpage Top Level
    GROFF_MS(7) manual page Table of Contents

Name

groff_ms - groff ms macros

Synopsis

groff -ms [ options... ] [ files... ]
groff -m ms [ options... ] [ files... ]

Description

This manual page describes the GNU version of the ms macros, part of the groff typesetting system. The ms macros are mostly compatible with the documented behavior of the 4.3 BSD Unix ms macros (see Differences from troff ms below for details). The ms macros are suitable for reports, letters, books, and technical documentation.

Usage

The ms macro package expects files to have a certain amount of structure. The simplest documents can begin with a paragraph macro and consist of text separated by paragraph macros or even blank lines. Longer documents have a structure as follows:
Document type
If you use the RP (report) macro at the beginning of the document, groff prints the cover page information on its own page; otherwise it prints the information on the first page with your document text immediately following. Other document formats found in AT&T troff are specific to AT&T or Berkeley, and are not supported in groff ms.
Format and layout
By setting number registers, you can change your document’s type (font and size), margins, spacing, headers and footers, and footnotes. See Document control registers below for more details.
Cover page
A cover page consists of a title, and optionally the author’s name and institution, an abstract, and the date. See Cover page macros below for more details.
Body
Following the cover page is your document. It consists of paragraphs, headings, and lists.
Table of contents
Longer documents usually include a table of contents, which you can add by placing the TC macro at the end of your document.

Document control registers

The following table lists the document control number registers. For the sake of consistency, set registers related to margins at the beginning of your document, or just after the RP macro.

Margin settings

Reg.DefinitionEffectiveDefault
POPage offset (left margin)next page1i
LLLine lengthnext paragraph6i
LTHeader/footer lengthnext paragraph6i
HMTop (header) marginnext page1i
FMBottom (footer) marginnext page1i

Text settings

Reg.DefinitionEffectiveDefault
PSPoint sizenext paragraph10p
VSLine spacing (leading) next paragraph12p
PSINCRPoint size increment for section headings of increasing importance next heading1p
GROWPSHeading level beyond which PSINCR is ignored next heading0

Paragraph settings

Reg.DefinitionEffectiveDefault
PIInitial indentnext paragraph5n
PDSpace between paragraphs next paragraph0.3v
QIQuoted paragraph indent next paragraph5n
PORPHANSNumber of initial lines to be kept together next paragraph1
HORPHANSNumber of initial lines to be kept with heading next heading1

Footnote settings

Reg.DefinitionEffectiveDefault
FLFootnote lengthnext footnote[rs]n[LL]*5/6
FIFootnote indentnext footnote2n
FFFootnote formatnext footnote0
FPSPoint sizenext footnote[rs]n[PS]-2
FVSVert. spacingnext footnote[rs]n[FPS]+2
FPDPara. spacingnext footnote[rs]n[PD]/2

Other settings

Reg.DefinitionEffectiveDefault
DDDisplay, table, eqn, pic spacingnext para.0.5v
MINGWMinimum width between columnsnext page2n

Cover page macros

Use the following macros to create a cover page for your document in the order shown.

Paragraphs

Use the PP macro to create indented paragraphs, and the LP macro to create paragraphs with no initial indent.

The QP macro indents all text at both left and right margins. The effect is identical to the HTML <BLOCKQUOTE> element. The next paragraph or heading returns margins to normal.

The XP macro produces an exdented paragraph. The first line of the paragraph begins at the left margin, and subsequent lines are indented (the opposite of PP).

For each of the above paragraph types, and also for any list entry introduced by the IP macro (described later), the document control register PORPHANS, sets the minimum number of lines which must be printed, after the start of the paragraph, and before any page break occurs. If there is insufficient space remaining on the current page to accommodate this number of lines, then a page break is forced before the first line of the paragraph is printed.

Similarly, when a section heading (see subsection Headings below) precedes any of these paragraph types, the HORPHANS document control register specifies the minimum number of lines of the paragraph which must be kept on the same page as the heading. If insufficient space remains on the current page to accommodate the heading and this number of lines of paragraph text, then a page break is forced before the heading is printed.

Headings

Use headings to create a hierarchical structure for your document. By default, the ms macros print headings in bold using the same font family and point size as the body text. For output devices which support scalable fonts, this behaviour may be modified, by defining the document control registers, GROWPS and PSINCR.

The following heading macros are available: