








                    AA RReevviisseedd VVeerrssiioonn ooff --mmss


                          _B_i_l_l _T_u_t_h_i_l_l
                       Computing Services
                    University of California
                       Berkeley, CA  94720


     The -ms macros have been slightly revised and rearranged for
the Berkeley Unix distribution.  Because  of  the  rearrangement,
the new macros can be read by the computer in about half the time
required by the previous version of -ms.  This means that  output
will begin to appear between ten seconds and several minutes more
quickly, depending on the system load.  On long  files,  however,
the  savings  in total time are not substantial.  The old version
of -ms is still available as -mos.

     Several bugs in -ms have been fixed, including a bad problem
with  the  .1C macro, minor difficulties with boxed text, a break
induced by .EQ before initialization,  the  failure  to  set  tab
stops  in  displays,  and  several bothersome errors in the rreeffeerr
macros.  Macros used only at Bell Laboratories have been removed.
There  are  a few extensions to previous -ms macros, and a number
of new macros, but all  the  documented  -ms  macros  still  work
exactly  as  they  did before, and have the same names as before.
Output produced with -ms should look like  output  produced  with
-mos.

     One  important  new  feature is automatically numbered foot-
notes.  Footnote numbers are printed by means  of  a  pre-defined
string (\**), which you invoke separately from .FS and .FE.  Each
time it is used, this string increases  the  footnote  number  by
one,  whether  or not you use .FS and .FE in your text.  Footnote
numbers will be  superscripted  on  the  phototypesetter  and  on
daisy-wheel terminals, but on low-resolution devices (such as the
lpr and a crt), they will be bracketed.  If you use \** to  indi-
cate  numbered  footnotes,  then the .FS macro will automatically
include the footnote number at the  bottom  of  the  page.   This
footnote, for example, was produced as follows:1

     This footnote, for example, was produced as follows:\**
     .FS
          ...
     .FE

If you are using \** to number footnotes, but want  a  particular
-----------
  1 If you never use the ``\**'' string, no footnote numbers
will appear anywhere in the text, including down here.   The
output  footnotes  will look exactly like footnotes produced









USD:18-2                                 A Revised Version of -ms


footnote  to  be  marked  with an asterisk or a dagger, then give
that mark as the first argument to .FS: [+]

     then give that mark as the first argument to .FS: \(dg
     .FS   \(dg
          ...
     .FE

Footnote numbering will be temporarily suspended, because the \**
string is not used.  Instead of a dagger, you could use an aster-
isk * or double dagger [++], represented as \(dd.

     Another new feature is a macro for printing theses according
to Berkeley standards.  This macro is called  .TM,  which  stands
for  thesis  mode.   (It  is much like the .th macro in -me.)  It
will put page numbers in the upper right-hand corner; number  the
first  page; suppress the date; and doublespace everything except
quotes, displays, and keeps.  Use it at the top of each file mak-
ing  up your thesis.  Calling .TM defines the .CT macro for chap-
ter titles, which skips to a new page and moves the pagenumber to
the  center footer.  The .P1 (P one) macro can be used even with-
out thesis mode to print the header on  page  1,  which  is  sup-
pressed  except  in  thesis mode.  If you want roman numeral page
numbering, use an ``.af PN i'' request.

     There is a new macro especially  for  bibliography  entries,
called  .XP, which stands for exdented paragraph.  It will exdent
the first line of the paragraph by \n(PI units, usually  5n  (the
same as the indent for the first line of a .PP).  Most bibliogra-
phies are printed this way.  Here are some examples  of  exdented
paragraphs:

Lumley, Lyle S., _S_e_x _i_n _C_r_u_s_t_a_c_e_a_n_s_: _S_h_e_l_l _F_i_s_h _H_a_b_i_t_s_, Harbinger
     Press, Tampa Bay and San Diego, October  1979.   243  pages.
     The pioneering work in this field.

Leffadinger,  Harry A., ``Mollusk Mating Season: 52 Weeks, or All
     Year?''  in _A_c_t_a _B_i_o_l_o_g_i_c_a_, vol. 42, no. 11, November  1980.
     A provocative thesis, but the conclusions are wrong.

Of  course,  you  will  have to take care of italicizing the book
title and journal, and quoting the title of the journal  article.
Indentation or exdentation can be changed by setting the value of
number register PI.

     If you need to produce endnotes rather than  footnotes,  put
the  references  in a file of their own.  This is similar to what
you would do if you were typing the paper on a conventional type-
writer.  Note that you can use automatic footnote numbering with-
out actually having .FS and .FE pairs in your text.  If you place
-----------
with -mos.
  [+] In the footnote, the  dagger  will  appear  where  the
footnote number would otherwise appear, as on the left.









A Revised Version of -ms                                 USD:18-3


footnotes  in a separate file, you can use .IP macros with \** as
a hanging tag; this will give you numbers at the  left-hand  mar-
gin.   With  some  styles  of endnotes, you would want to use .PP
rather than .IP macros, and  specify  \**  before  the  reference
begins.

     There  are  four  new macros to help produce a table of con-
tents.  Table of contents entries must be enclosed in .XS and .XE
pairs, with optional .XA macros for additional entries; arguments
to .XS and .XA specify the page number,  to  be  printed  at  the
right.  A final .PX macro prints out the table of contents.  Here
is a sample of typical input and output text:

     .XS  ii
     Introduction
     .XA  1
     Chapter 1: Review of the Literature
     .XA  23
     Chapter 2: Experimental Evidence
     .XE
     .PX
                   TTaabbllee ooff CCoonntteennttss

     Introduction  ....................................   ii
     Chapter 1: Review of the Literature ..............    1
     Chapter 2: Experimental Evidence .................   23

The .XS and .XE pairs may also be used in the text, after a  sec-
tion header for instance, in which case page numbers are supplied
automatically.  However, most documents that require a  table  of
contents  are  too long to produce in one run, which is necessary
if this method is to work.  It is recommended that you do a table
of  contents after finishing your document.  To print out the ta-
ble of contents, use the .PX macro; if  you  forget  it,  nothing
will happen.

     As  an aid in producing text that will format correctly with
both nnrrooffff and ttrrooffff, there are some new string definitions  that
define  quotation  marks and dashes for each of these two format-
ting programs.  The \*_ string will yield two hyphens  in  nnrrooffff,
but in ttrrooffff it will produce an em dash-- like this one.  The \*Q
and \*U strings will produce `` and '' in ttrrooffff, but " in  nnrrooffff.
(In typesetting, the double quote is traditionally considered bad
form.)

     There are now a large  number  of  optional  foreign  accent
marks  defined by the -ms macros.  All the accent marks available
in -mos are present, and they all work just as they  always  did.
However, there are better definitions available by placing .AM at
the beginning of your document.  Unlike the  -mos  accent  marks,
the  accent  strings should come _a_f_t_e_r the letter being accented.
Here is a list of the diacritical marks, with  examples  of  what
they look like.










USD:18-4                                 A Revised Version of -ms


     name of accent      input     output
     ___________________________________
     acute accent        e\*'      e'
     grave accent        e\*`      e`
     circumflex          o\*^      o^
     cedilla             c\*,      c,
     tilde               n\*~      n~
     question            \*?       ?
     exclamation         \*!       !
     umlaut              u\*:      u
     digraph s           \*8       ss
     hacvek               c\*v      cv
     macron              a\*_      a--
     underdot            s\*.      s.
     o-slash             o\*/      o/
     angstrom            a\*o      ao
     yogh                kni\*3t   kni3t
     Thorn               \*(Th     P
     thorn               \*(th     p
     Eth                 \*(D-     D
     eth                 \*(d-     d
     hooked o            \*q       oo
     ae ligature         \*(ae     ae
     AE ligature         \*(Ae     AE
     oe ligature         \*(oe     oe
     OE ligature         \*(Oe     OE

If  you want to use these new diacritical marks, don't forget the
.AM at the top of your file.  Without it, some will not print  at
all, and others will be placed on the wrong letter.

     It  is  also  possible to produce custom headers and footers
that are different on even and odd pages.  The .OH and .EH macros
define  odd  and  even  headers, while .OF and .EF define odd and
even footers.  Arguments to these four macros  are  specified  as
with .tl.  This document was produced with:

     .OH  '\fIThe  -mx  Macros''Page  %\fP'
     .EH  '\fIPage  %''The  -mx  Macros\fP'

Note that it would be a error to have an apostrophe in the header
text; if you need one, you will have to use a different delimiter
around  the  left,  center, and right portions of the title.  You
can use any character as a delimiter, provided it doesn't  appear
elsewhere in the argument to .OH, .EH, .OF, or EF.

     The  -ms  macros  work in conjunction with the ttbbll, eeqqnn, and
rreeffeerr preprocessors.  Macros to deal with these items are read in
only  as  needed,  as  are  the  thesis macros (.TM), the special
accent mark definitions (.AM), table of contents macros (.XS  and
.XE), and macros to format the optional cover page.  The code for
the -ms package lives in /usr/lib/tmac/tmac.s, and sourced  files
reside in the directory /usr/ucb/lib/ms.







