143435Scael.\" Copyright (c) 1990 The Regents of the University of California. 243435Scael.\" All rights reserved. 343435Scael.\" 4*48889Scael.\" %sccs.include.redist.roff% 543435Scael.\" 6*48889Scael.\" @(#)mdoc.samples.7 5.5 (Berkeley) 05/01/91 743435Scael.\" 843435Scael.\" This sampler invokes every macro in the package several 943435Scael.\" times and is garanteed to give a worst case performance 1048888Scael.\" for an already extremely slow package. 1143435Scael.Dd 1243435Scael.Os BSD 4.4 1343435Scael.Dt MDOC.SAMPLES 7 1443435Scael.Sh NAME 1543435Scael.Nm mdoc.sample 1648888Scael.Nd writing manual pages with 1743435Scael.Nm -mdoc 1843435Scaelmacro package 1943435Scael.Sh SYNOPSIS 2043435Scael.Nm man mdoc.sample 2143435Scael.Sh DESCRIPTION 2248888ScaelA tutorial sampler for writing 2348888Scael.Bx 2448888Scaelmanual pages with the 2543435Scael.Nm \-mdoc 2648888Scaelmacro package; a 2748888Scael.Em content Ns \- 2848888Scaelbased formatting 2948888Scaelpackage for 3048888Scael.Xr troff 1 . 3148888ScaelIts predecessor, the 3248888Scael.Xr \-man 7 3348888Scaelpackage, 3448888Scaeladdressed page structure leaving the 3548888Scaelmanipulation of fonts and other 3648888Scaeltypesetting details to the individual author. 3748888ScaelThe 3848888Scael.Nm \-mdoc 3948888Scaelpackage 4048888Scaelallows the author to ignore font considerations by 4148888Scaelusing macros to label 4248888Scaelpieces of text according to content. 4348888ScaelIn the context of manual pages, examples of content 4448888Scaelare a command name, a file pathname or a cross 4548888Scaelreference to another manual page; these 4648888Scaelitems have value 4748888Scaelfor both the author and the future user of the manual page. 4848888ScaelIt is hoped the consistency gained 4948888Scaelacross the manual set will provide easier 5048888Scaeltranslation to future documentation tools. 5148888Scael.Pp 5248888ScaelThrough out the 5348888Scael.Ux 5448888Scaelmanual pages, a manual entry 5548888Scaelis simply referred 5648888Scaelto as a man page, regardless of actual length and without 5748888Scaelsexist intention. 5843435Scael.Sh TROFF IDIOSYNCRASIES 5948888ScaelThe 6048888Scael.Nm \-mdoc 6148888Scaelpackage attempts to simplify the process of writing a man page. 6248888ScaelTheoretically, one should not have to learn the dirty details of 6343435Scael.Xr troff 1 6448888Scaelto use 6548888Scael.Nm \-mdoc ; 6648888Scaelhowever, there are a few 6743435Scaellimitations which are unavoidable and best gotten out 6848888Scaelof the way. And, too, be forewarned, this package is 6948888Scael.Em not 7048888Scaelfast. 7143435Scael.Ss Macro Usage 7243435ScaelAs in 7343435Scael.Xr troff 1 , 7448888Scaela macro is called by placing a 7548888Scael.Ql \&\. 7643435Scael(dot character) 7743435Scaelat the beginning of 7843435Scaela line followed by the two character name for the macro. 7948888ScaelArguments may follow the macro separated by spaces. 8043435ScaelIt is the dot character at the beginning of the line which causes 8143435Scael.Xr troff 1 8248888Scaelto interpret the next two characters as a macro name. 8343435ScaelTo place a 8448888Scael.Ql \&\. 8543435Scael(dot character) 8643435Scaelat the beginning of a line in some context other than 8748888Scaela macro macro, precede the 8848888Scael.Ql \&\. 8943435Scael(dot) with a 9048888Scael.Ql \e& . 9148888Scael.Pp 9248888ScaelIn general, 9348888Scael.Xr troff 1 9448888Scaelmacros accept up to nine arguments, any 9548888Scaelextra arguments are ignored. 9648888ScaelMost macros in 9748888Scael.Nm \-mdoc 9848888Scaelaccept nine arguments and, 9948888Scaelin limited cases, arguments may be continued or extended 10048888Scaelon the 10148888Scaelnext line (See 10248888Scael.Sx Extensions 10348888Scael\- 10448888Scaelmacro 10548888Scael.Ql \&.Xo 10648888Scaeland 10748888Scael.Ql \&.Xc ) . 10848888ScaelA few macros handle quoted aguments (see 10948888Scael.Sx Passing Space Characters in an Argument 11048888Scaelbelow). 11148888ScaelMany 11248888Scael.Nm \-mdoc 11348888Scaelmacros may be given the 11443435Scaelname of another macro as an argument. In this case 11543435Scaelthe argument, although the name of a macro, 11643435Scaelis not preceded by a 11748888Scael.Ql \&\. 11843435Scael(dot), 11948888Scaeland is 12048888Scael.Em called 12148888Scaelwhen the argument is processed. 12248888ScaelIt is in this manner that some macros are nested; for 12348888Scaelexample 12448888Scaelthe option macro, 12548888Scael.Ql \&.Op , 12648888Scaelmay 12743435Scael.Em call 12848888Scaelthe flag and argument macros, 12948888Scael.Ql \&.Fl 13048888Scaeland 13148888Scael.Ql \&.Ar , 13248888Scaelto specify an optional flag with an argument: 13348888Scael.nr D 1 13448888Scael.Bl -tag -width "\&.Op \&Fl s \&Ar bytes" -offset indent 13548888Scael.It Op Fl s Ar bytes 13643435Scaelis produced by 13748888Scael.Li \&.Op \&Fl s \&Ar bytes 13848888Scael.El 13943435Scael.Pp 14048888ScaelTo prevent a two character 14148888Scaelstring from being interpreted as a macro name, precede 14248888Scaelthe string with the 14348888Scaelescape sequence 14448888Scael.Ql \e& : 14548888Scael.Bl -tag -width "[\&Fl s \&Ar bytes]" -offset indent 14648888Scael.It Op \&Fl s \&Ar bytes 14748888Scaelis produced by 14848888Scael.Li \&.Op \e&Fl s \e&Ar bytes 14948888Scael.El 15043435Scael.Pp 15148888Scael.nr D 0 15248888ScaelHere the strings 15348888Scael.Ql \&Fl 15448888Scaeland 15548888Scael.Ql \&Ar 15648888Scaelwere not interpreted as macros. 15748888ScaelDetails on callable macros are presented in the 15848888Scaelsections 15948888Scael.Sx CONTENT MACROS 16048888Scaeland 16148888Scael.Sx PAGE LAYOUT MACROS. 16248888Scael.Ss Passing Space Characters in an Argument 16348888ScaelSometimes it is desirable to give as one argument a string 16448888Scaelcontaining one or more blank space characters. This may be necessary 16548888Scaelto defeat the nine argument limit or to specify arguments to macros 16648888Scaelwhich expect particular arrangement of items in the argument list. 16748888ScaelFor example, 16848888Scaelthe function macro 16948888Scael.Ql \&.Fn 17048888Scaelexpects the first argument to be the name of a function and any 17148888Scaelremaining arguments to be function parameters. As 17248888Scael.Tn "ANSI C" 17348888Scaelstipulates the declaration of function parameters in the 17448888Scaelparenthesized parameter list, each parameter is guaranteed 17548888Scaelto be at minimum a two word string. For example, 17648888Scael.Fa int foo . 17748888ScaelThere are two possible ways to pass an argument which contains 17848888Scaelan imbedded space. Unfortunately, the most convient way 17948888Scaelof passing such a space between quotes was too expensive to implement for 18048888Scaelall the macros. It is however, implemented for the following macros which need 18148888Scaelit the most: 18243435Scael.Pp 18348888Scael.Bl -tag -width 4n -offset indent -compact 18448888Scael.It Li \&Cd 18548888ScaelConfiguration declaration (section 4 SYNOPSIS) 18648888Scael.It Li \&Bl 18748888ScaelBegin list (for the width specifier). 18848888Scael.It Li \&Em 18948888ScaelEmphasized text. 19048888Scael.It Li \&Fn 19148888ScaelFunctions (sections two and four). 19248888Scael.It Li \&It 19348888ScaelList items. 19448888Scael.It Li \&Li 19548888ScaelLiteral text. 19648888Scael.It Li \&Sy 19748888ScaelSymbolic text. 19848888Scael.It Li \&%B 19948888ScaelBook titles. 20048888Scael.It Li \&%J 20148888ScaelJournal names. 20248888Scael.It Li \&%O 20348888ScaelOptional notes for a reference. 20448888Scael.It Li \&%R 20548888ScaelReport title (in a reference). 20648888Scael.It Li \&%T 20748888ScaelTitle of article in a book or journal. 20848888Scael.El 20948888Scael.Pp 21048888ScaelOne way of passing a string 21148888Scaelcontaining blank spaces is to use the hard or unpaddable space character 21248888Scael.Ql \e\ , 21348888Scaelthat is, a blank space preceeded by the escape character 21448888Scael.Ql \e . 21548888ScaelThis method may be used with any macro but has the side effect 21648888Scaelof interfering with the adjustment of text 21748888Scaelover the length of a line. 21848888Scael.Xr Troff 21948888Scaelsees the hard space as if it were any other printable character and 22048888Scaelcannot split the string into blank or newline separated pieces as one 22148888Scaelwould expect. The method is useful for strings which are not expected 22248888Scaelto overlap a line boundary. For example: 22348888Scael.Bl -tag -width "fetch(char *str)" -offset indent 22448888Scael.It Fn fetch char\ *str 22543435Scaelis created by 22648888Scael.Ql \&.Fn fetch char\e *str 22748888Scael.It Fn fetch "char *str" 22848888Scaelcan also be created by 22948888Scael.Ql \&.Fn fetch "\\*q*char *str\\*q" 23048888Scael.El 23148888Scael.Pp 23248888ScaelIf the 23348888Scael.Ql \e 23448888Scaelor quotes 23548888Scaelwere omitted, 23648888Scael.Ql \&.Fn 23748888Scaelwould see three arguments and 23848888Scaelthe result would be: 23948888Scael.Pp 24048888Scael.Dl Fn fetch char *str 24148888Scael.Pp 24248888ScaelNote what happens if the parameter list overlaps a newline 24348888Scaelboundary. For example, the next two examples are repeated several times 24448888Scaelto make sure a line boundary is crossed: 24548888Scael.Bd -literal 24648888Scael\&.Fn struct\e\ dtable\e\ *dlookup struct\e\ dtable\e\ *tab[] 24748888Scael.Ed 24848888Scael.Pp 24948888Scaelproduces, nudge nudge, 25048888Scael.Fn struct\ dtable\ *dlookup char\ *h struct\ dtable\ *tab[] , 25148888Scael.Fn struct\ dtable\ *dlookup char\ *h struct\ dtable\ *tab[] , 25248888Scaelnudge 25348888Scael.Fn struct\ dtable\ *dlookup char\ *h struct\ dtable\ *tab[] . 25448888Scael.Pp 25548888ScaelIf double quotes are used, for example: 25648888Scael.Bd -literal 25748888Scael\&.Fn \*qstruct dtable *dlookup\*q \*qchar *h\*q \*qstruct dtable *tab[]\*q 25848888Scael.Ed 25948888Scael.Pp 26048888Scaelproduces, nudge nudge, 26148888Scael.Fn "struct dtable *dlookup" "char *h" "struct dtable *tab[]" , 26248888Scaelnudge 26348888Scael.Fn "struct dtable *dlookup" "char *h" "struct dtable *tab[]" , 26448888Scaelnudge 26548888Scael.Fn "struct dtable *dlookup" "char *h" "struct dtable *tab[]" . 26648888Scael.Pp 26748888ScaelNot a pretty sight... 26848888ScaelIn a paragraph, a long parameter containing unpaddable spaces as 26948888Scaelin the former example will cause 27048888Scael.Xr troff 27148888Scaelto break the line and spread 27248888Scaelthe remaining words out. The latter example will adjust nicely to 27348888Scaeljustified margins, but may break in between an argument and its 27448888Scaeldeclaration. In 27548888Scael.Xr nroff 27648888Scaelthe right margin adjustment is normally ragged and the problem is 27748888Scaelnot as severe. 27848888Scael.Ss Trailing Blank Space Characters 27948888Scael.Xr Troff 28048888Scaelcan be confused by blank space characters at the end of a line. It 28148888Scaelis wise preventative measure to globally remove all blank spaces 28248888Scaelfrom <blank-space><end-of-line> character sequences. Should the need 28348888Scaelarise to force a blank character at the end of a line, 28448888Scaelit may be forced with an unpaddable space and the 28548888Scael.Ql \e& 28648888Scaelescape character. 28748888ScaelFor example, 28848888Scael.Ql string\e\ \e& . 28943435Scael.Ss Escaping Special Characters 29043435ScaelSpecial characters 29143435Scaellike the newline character 29248888Scael.Ql \en , 29343435Scaelare handled by replacing the 29448888Scael.Ql \e 29543435Scaelwith 29648888Scael.Ql \ee 29743435Scael(e.g. 29848888Scael.Ql \een ) 29943435Scaelto preserve 30043435Scaelthe backslash. 30148888Scael.Sh THE ANATOMY OF A MAN PAGE (Getting Started) 30248888ScaelThere are three basic groups of macros: specific header macros 30348888Scaelcalled only once at the very beginning of 30448888Scaeleach manual page, page layout or structure macros 30548888Scaelwhich may be called many times, and content macros which also 30648888Scaelmay be called many times. 30748888ScaelThe body of a man page is easily constructed from a basic 30848888Scaeltemplate found in the file: 30948888Scael.Bd -literal -offset indent 31048888Scael\&.\e" /usr/share/misc/man.tempate : 31148888Scael\&.\e" The following six lines are required. 31248888Scael\&.Dt DOCUMENT_TITLE [section number] [volume] 31348888Scael\&.Os OPERATING_SYSTEM [version/release] 31448888Scael\&.Dd Month day, year 31548888Scael\&.Sh NAME 31648888Scael\&.Sh SYNOPSIS 31748888Scael\&.Sh DESCRIPTION 31848888Scael\&.\e" The following requests should be uncommented and 31948888Scael\&.\e" used where appropriate. This next request is 32048888Scael\&.\e" for sections 2 and 3 function return values only. 32148888Scael\&.\e" .Sh RETURN VALUES 32248888Scael\&.\e" This next request is for sections 1, 6, 7 & 8 only 32348888Scael\&.\e" .Sh ENVIRONMENT 32448888Scael\&.\e" .Sh FILES 32548888Scael\&.\e" .Sh EXAMPLES 32648888Scael\&.\e" This next request is for sections 1, 6, 7 & 8 only 32748888Scael\&.\e" (command return values (to shell) and 32848888Scael\&.\e" fprintf/stderr type diagnostics) 32948888Scael\&.\e" .Sh DIAGNOSTICS 33048888Scael\&.\e" The next request is for sections 2 and 3 error 33148888Scael\&.\e" and signal handling only. 33248888Scael\&.\e" .Sh ERRORS 33348888Scael\&.\e" .Sh SEE ALSO 33448888Scael\&.\e" .Sh STANDARDS 33548888Scael\&.\e" .Sh HISTORY 33648888Scael\&.\e" .Sh AUTHORS 33748888Scael\&.\e" .Sh BUGS 33848888Scael.Ed 33948888Scael.Pp 34048888ScaelThe first items in the template are the macros 34148888Scael.Pq Li \&.Dt , \&.Dd , \&.Os ; 34248888Scaelthe document or man page title 34348888Scael.Pq Em in upper case , 34448888Scaelthe section of the manual the page 34548888Scaelbelongs to, the (document) date, 34648888Scaeland the operating system the man page is derived 34748888Scaelfrom. These macros identify the page, 34848888Scaeland are discussed below in 34948888Scael.Sx TITLE MACROS . 35048888Scael.Pp 35148888ScaelThe remaining items in the template are section headers 35248888Scael.Pq Li \&.Sh ; 35348888Scaelof which NAME, SYNOPSIS and DESCRIPTION 35448888Scaelare mandatory. The 35548888Scaelheaders are 35648888Scaeldiscussed in 35748888Scael.Sx PAGE LAYOUT MACROS, 35848888Scaelafter 35948888Scaelpresentation of 36048888Scael.Sx CONTENT MACROS . 36148888ScaelSeveral content macros are used to demonstrate page layout macros; 36248888Scaelreading about content macros before page layout macros is 36348888Scaelrecommended. 36448888Scael.Sh TITLE MACROS 36543435ScaelThree header macros designate the document title or manual page title, 36643435Scaelthe operating system, 36748888Scaeland the date of authorship. 36843435ScaelThese macros are one called once at the very beginning of the document 36943435Scaeland are used to construct the headers and footers only. 37048888Scael.Bl -tag -width 6n 37148888Scael.It Li \&.Dt DOCUMENT_TITLE section# [volume] 37243435ScaelThe document title is the 37343435Scaelsubject of the man page and must be in CAPITALS due to troff 37443435Scaellimitations. 37548888ScaelThe section number may be 1,\ ...,\ 8, 37643435Scaeland if it is specified, 37743435Scaelthe volume title may be omitted. 37843435ScaelA volume title may be arbitrary or one of the following: 37943435Scael.\" .Cl 38043435Scael.\" USD UNIX User's Supplementary Documents 38143435Scael.\" .Cl 38243435Scael.\" PS1 UNIX Programmers's Supplementary Documents 38348888Scael.Pp 38448888Scael.Bl -column SMM -offset indent -compact 38548888Scael.It AMD UNIX Ancestral Manual Documents 38648888Scael.It SMM UNIX System Manager's Manual 38748888Scael.It URM UNIX Reference Manual 38848888Scael.It PRM UNIX Programmers's Manual 38948888Scael.El 39048888Scael.Pp 39143435Scael.\" .Cl 39243435Scael.\" MMI UNIX Manual Master Index 39343435Scael.\" .Cl 39443435Scael.\" CON UNIX Contributed Software Manual 39543435Scael.\" .Cl 39643435Scael.\" LOC UNIX Local Manual 39748888Scael.It Li \&.Os operating_system release# 39843435ScaelThe name of the operating system 39943435Scaelshould be the common acronym, e.g. BSD 40043435Scaelor ATT. The release should be the standard release 40148888Scaelnomenclature for the system specified, e.g. 4.3, 4.3+Tahoe, V.3, 40243435ScaelV.4. Unrecognized arguments are displayed as given in the page footer. 40343435ScaelFor instance, for the footer on this page, the 4.4 Berkeley Distribution 40443435Scaelwas produced by: 40543435Scael.Pp 40648888Scael.Dl \&.Os BSD 4.4 40748888Scael.It Li \&.Dd month day, year 40843435ScaelThe date should be written formally: 40943435Scael.Pp 41043435Scael.Dl January 25, 1989 41148888Scael.El 41248888Scael.Sh CONTENT MACROS 41348888Scael.Ss What's in a name... 41448888ScaelContent macro names are derived from the day to day 41548888Scaelinformal language used to describe commands, subroutines and related 41648888Scaelfiles. Slightly 41748888Scaeldifferent variations of this language are used to describe 41848888Scaelthe three different aspects of writing a man page. 41948888ScaelFirst, there is the description of 42048888Scael.Nm \-mdoc 42148888Scaelmacro request usage. 42248888ScaelSecond is the description of a 42348888Scael.Ux 42448888Scaelcommand 42548888Scael.Em with 42648888Scael.Nm \-mdoc 42748888Scaelmacros and third, 42848888Scaelthe 42948888Scaeldescription a command to a user in the verbal sense; 43048888Scaelthat is, discussion of a command in the text of a man page. 43148888Scael.Pp 43248888ScaelIn the first case, 43348888Scael.Xr troff 1 43448888Scaelmacros are themselves a type of command; 43548888Scaelthe general syntax for a troff command is: 43648888Scael.Bd -filled -offset indent 43748888Scael\&.Va argument1 argument2 ... argument9 43848888Scael.Ed 43948888Scael.Pp 44048888ScaelThe 44148888Scael.Ql \&.Va 44248888Scaelis a macro command or request, and anything following it is an argument to 44348888Scaelbe processed. 44448888ScaelIn the second case, 44548888Scaelthe description of a 44648888Scael.Ux 44748888Scaelcommand using the content macros is a 44848888Scaelbit more involved; 44948888Scaela typical SYNOPSIS command line might be displayed as: 45048888Scael.Pp 45148888Scael.Bd -filled -offset indent 45248888Scael.Nm filter 45348888Scael.Op Fl flag 45448888Scael.Ar infile outfile 45548888Scael.Ed 45648888Scael.Pp 45748888ScaelHere, 45848888Scael.Nm filter 45948888Scaelis the command name and the 46048888Scaelbracketed string 46148888Scael.Fl flag 46248888Scaelis a 46348888Scael.Em flag 46448888Scaelargument designated as optional by the option brackets. 46548888ScaelIn 46648888Scael.Nm \-mdoc 46748888Scaelterms, 46848888Scael.Ar infile 46943435Scaeland 47048888Scael.Ar outfile 47148888Scaelare 47248888Scaelcalled 47348888Scael.Em arguments . 47448888ScaelThe macros which formatted the above example: 47543435Scael.Pp 47648888Scael.Bd -ragged -offset indent 47748888Scael.Li \&.Nm filter 47848888Scael.Li \&.Op \&Fl flag 47948888Scael.Li \&.Ar infile outfile 48048888Scael.Ed 48148888Scael.Pp 48248888ScaelIn the third case, discussion of commands and command syntax 48348888Scaelincludes both examples above, but may add more detail. The 48448888Scaelarguments 48548888Scael.Ar infile 48648888Scaeland 48748888Scael.Ar outfile 48848888Scaelfrom the example above might be refered to as 48948888Scael.Em operands 49048888Scaelor 49148888Scael.Em file arguments . 49248888ScaelSome command line argument lists are quite long: 49348888Scael.\" .Bl -tag -width make -offset indent 49448888Scael.Bl -tag -width make -offset indent 49548888Scael.It Nm make 49648888Scael.Op Fl eiknqrstv 49748888Scael.Op Fl D Ar variable 49848888Scael.Op Fl d Ar flags 49948888Scael.Op Fl f Ar makefile 50048888Scael.Op Fl I Ar directory 50148888Scael.Op Fl j Ar max_jobs 50248888Scael.Op Ar variable=value 50348888Scael.br 50448888Scael.Op Ar "target\ ..." 50548888Scael.El 50648888Scael.Pp 50748888ScaelHere one might talk about the command 50848888Scael.Nm make 50948888Scaeland qualify the argument 51048888Scael.Ar makefile , 51148888Scaelas an argument to the flag, 51248888Scael.Fl f , 51348888Scaelor discuss the optional 51448888Scaelfile 51548888Scaeloperand 51648888Scael.Ar target . 51748888ScaelIn the verbal context, such detail can prevent confusion, 51848888Scaelhowever the 51948888Scael.Nm \-mdoc 52048888Scaelpackage 52148888Scaeldoes not have a macro for an argument 52248888Scael.Em to 52348888Scaela flag. 52448888ScaelInstead the 52548888Scael.Ql \&Ar 52648888Scaelargument macro is used for an operand or file argument like 52748888Scael.Ar target 52848888Scaelas well as an argument to a flag like 52948888Scael.Ar variable : 53048888Scael.Bd -literal -offset indent 53148888Scael\&.Nm make 53248888Scael\&.Op Fl eiknqrstv 53348888Scael\&.Op Fl D Ar variable 53448888Scael\&.Op Fl d Ar flags 53548888Scael\&.Op Fl f Ar makefile 53648888Scael\&.Op Fl I Ar directory 53748888Scael\&.Op Fl j Ar max_jobs 53848888Scael\&.Op Ar variable=value 53948888Scael\&.Op Ar target ... 54048888Scael.Ed 54148888Scael.Ss General Syntax 54248888ScaelAll content macros share a similar 54348888Scaelsyntax with a few minor deviations: 54448888Scael.Ql \&.Ar , 54548888Scael.Ql \&.Fl , 54648888Scael.Ql \&.Nm , 54748888Scaeland 54848888Scael.Ql \&.Pa 54948888Scaeldiffer only when called without arguments; 55048888Scael.Ql \&.Fn 55148888Scaeland 55248888Scael.Ql \&.Xr 55348888Scaelimpose an order on their argument lists 55448888Scaeland the 55548888Scael.Em enclosure 55648888Scaeland 55748888Scael.Em quoting 55848888Scaelmacros 55948888Scaelhave nesting limitations. All content macros 56048888Scaelare capable of handling punctuation. 56143435ScaelAny argument which may be tested for punctuation 56243435Scaeland contains a member of the mathematical, logical or 56348888Scaelquotation set: 56448888Scael.Bd -literal -offset indent -compact 56543435Scael{+,\-,/,*,%,<,>,<=,>=,=,==,&,`,',"} 56648888Scael.Ed 56743435Scaelshould have 56848888Scaelthe character escaped with 56948888Scael.Ql \e& . 57048888ScaelTypical syntax is shown in the first content macro displayed 57148888Scaelbelow, 57248888Scael.Ql \&.Ad , 57348888Scaeland the syntax for enclosure/quoting macros is shown in 57448888Scael.Sx Enclosure and Quoting Macros . 57548888Scael.Ss Address Macro 57648888ScaelThe address macro constructs an address 57743435Scaelof the form addr1[,addr2[,addr3]]. 57843435Scael.Pp 57948888Scael.Dl Usage: .Ad address ... \*(Pu 58048888Scael.Bl -tag -width ".Ad f1 , f2 , f3 :" -compact -offset 14n 58148888Scael.It Li \&.Ad addr1 58243435Scael.Ad addr1 58348888Scael.It Li \&.Ad addr1\ . 58443435Scael.Ad addr1 . 58548888Scael.It Li \&.Ad addr1\ , file2 58643435Scael.Ad addr1 , file2 58748888Scael.It Li \&.Ad f1\ , f2\ , f3\ : 58843435Scael.Ad f1 , f2 , f3 : 58948888Scael.It Li \&.Ad addr\ )\ )\ , 59043435Scael.Ad addr ) ) , 59148888Scael.El 59248888Scael.Pp 59343435ScaelIt is an error to call 59443435Scael.Li \&.Ad 59543435Scaelwithout arguments. 59648888Scael.Li \&.Ad 59748888Scaelis callable by other macros and may call other macros. 59848888Scael.Ss Argument Macro 59943435ScaelThe 60043435Scael.Li \&.Ar 60148888Scaelargument macro may be used whenever 60243435Scaela command line argument is referenced. 60343435Scael.Pp 60443435Scael.Dl Usage: .Ar argument ... \*(Pu 60548888Scael.Bl -tag -width ".Ar file1 file2" -compact -offset 15n 60648888Scael.It Li \&.Ar 60743435Scael.Ar 60848888Scael.It Li \&.Ar file1 60943435Scael.Ar file1 61048888Scael.It Li \&.Ar file1\ . 61143435Scael.Ar file1 . 61248888Scael.It Li \&.Ar file1 file2 61343435Scael.Ar file1 file2 61448888Scael.It Li \&.Ar f1 f2 f3\ : 61543435Scael.Ar f1 f2 f3 : 61648888Scael.It Li \&.Ar file\ )\ )\ , 61743435Scael.Ar file ) ) , 61848888Scael.El 61943435Scael.Pp 62043435ScaelIf 62143435Scael.Li \&.Ar 62248888Scaelis called without arguments 62348888Scael.Ql Ar 62443435Scaelis assumed. The 62543435Scael.Li \&.Ar 62648888Scaelmacro may call other macros, and may be 62748888Scaelcalled by other macros. 62848888Scael.Ss Angle Bracket Quote/Enclosure 62948888ScaelEncloses a string or strings in between angle brackets. The macro 63048888Scael.Ql \&.Aq 63148888Scaelencloses the remaining arguments on the macro command line, and the 63248888Scael.Ql \&.Ao 63348888Scael(angle open) and 63448888Scael.Ql \&.Ac 63548888Scael(angle close) macros may be used across one or more lines. 63648888Scael.Pp 63748888Scael.Dl Usage: .Aq string ... \*(Pu 63848888Scael.Bl -tag -width ".Aq Pa ctype.h ) ," -compact -offset 14n 63948888Scael.It Li \&.Aq 64048888Scael.Aq 64148888Scael.It Li \&.Aq string. 64248888Scael.Aq string. 64348888Scael.It Li \&.Aq string\ . 64448888Scael.Aq string . 64548888Scael.It Li \&.Aq stdio.h 64648888Scael.Aq stdio.h 64748888Scael.It Li \&.Aq \&Ar ctype.h\ )\ , 64848888Scael.Aq Ar ctype.h ) , 64948888Scael.El 65048888Scael.Pp 65148888ScaelSee 65248888Scael.Sx Enclosure Macros 65348888Scaelfor discussion and 65448888Scael.Sx Options 65548888Scaelfor examples of the open and close 65648888Scaelmacros 65748888Scael.Ql \&.Ac 65848888Scaeland 65948888Scael.Ql \&.Ao . 66048888Scael.Ql \&.Aq 66148888Scaelis callable by other macros and may call other macros. 66248888Scael.Ss Apostrophes 66348888ScaelThe simple act of appending an apostrophe to the end of a word 66448888Scaelis quite painful with out the apostrophe macro. All arguments 66548888Scaelin 66648888Scael.Nm \-mdoc 66748888Scaelare measured for width and the apostrophe character is misinterpreted 66848888Scaelas a width delimiter. To get around this, the aprostrophe macro 66948888Scaelappends the apostrophe character to the word after is has been measured. 67048888Scael.Pp 67148888Scael.Dl Usage: .(macro_name) string Ap appended string \*(Pu 67248888Scael.Bl -tag -width ".Aq Pa ctype.h ) ," -compact -offset 14n 67348888Scael.It Li \&.Em execve \&Ap ing 67448888Scael.Em execve Ap ing 67548888Scael.El 67648888Scael.Pp 67743435ScaelThe 67848888Scael.Ql \&Ap 67948888Scaelmacro may be called by other macros and may call other macros, it cannot 68048888Scaelhowever, be the first macro on a request line. 68148888Scael.Ss Bracket Quotes/Enclosure 68248888ScaelBracket quotes should be used when the string being bracketed is 68348888Scael.Em not 68448888Scaelan option string. The brackets for an option may be different 68548888Scaelthan the default brackets. The macro 68648888Scael.Ql \&.Bq 68748888Scaelencloses the remaining arguments on a macro command line and the 68848888Scaelmacros 68948888Scael.Ql \&.Bo 69048888Scaeland 69148888Scael.Ql \&.Bc 69248888Scaelmay be used across one or more lines. 69343435Scael.Pp 69448888Scael.Dl Usage: .Bq string ... \*(Pu 69548888Scael.Pp 69648888ScaelThe 69748888Scael.Li \&.Bq 69848888Scaelmacro exists for statements which use other macros: 69948888Scael.Bq Em Greek , French . 70048888ScaelThis was done with: 70148888Scael.Pp 70248888Scael.Dl Li \&.Bq \&Em Greek \&, French \&. 70348888Scael.Pp 70448888ScaelIt also could have been done using the prefix macro: 70548888Scael.Pp 70648888Scael.Dl Li ".Pf [ Em Greek , French ] ." 70748888Scael.Pp 70848888ScaelSee 70948888Scael.Sx Enclosure Macros 71048888Scaelfor discussion and 71148888Scael.Sx Options 71248888Scaelfor examples of the open and close 71348888Scaelmacros 71448888Scael.Ql \&.Bc 71548888Scaeland 71648888Scael.Ql \&.Bo . 71748888ScaelThe 71848888Scael.Ql \&.Bq 71948888Scaelmacro 72048888Scaelis callable and may call other macros. 72148888Scael.Ss Configuration Declaration (section four only) 72248888ScaelThe 72348888Scael.Ql \&.Cd 72448888Scaelmacro is used to demonstrate a 72548888Scael.Xr config 8 72648888Scaeldeclaration for a device interface in a section four manual. 72748888ScaelThis macro accepts quoted arguments (double quotes only). 72848888Scael.Pp 72948888Scael.Bl -tag -width "device le0 at scode?" -offset indent 73048888Scael.It Cd "device le0 at scode?" 73148888Scaelproduced by: 73248888Scael.Ql ".Cd device le0 at scode?" . 73348888Scael.El 73448888Scael.Ss Command Modifier 73548888ScaelThe command modifier is identical to the 73648888Scael.Ql \&.Fl 73748888Scael(flag) command with the exception 73848888Scaelthe 73948888Scael.Ql \&.Cm 74048888Scaelmacro does not assert a dash 74148888Scaelin front of every argument. Traditionally flags are marked by the 74248888Scaelpreceding dash, some commands or subsets of commands do not use them. 74348888ScaelCommand modifiers may also be specified in conjunction with interactive 74448888Scaelcommands such as editor commands. 74548888ScaelSee 74648888Scael.Sx Flags . 74748888Scael.Ss Double Quote macro/Enclosure 74848888ScaelThe 74948888Scael.Ql \&.Dq 75048888Scaeldouble quote encloses 75148888Scaelany remaining strings on the command line with double quotes. 75248888ScaelPunctuation is 75348888Scaelplaced after the end quote. 75448888ScaelThe macros 75548888Scael.Ql \&.Do 75648888Scaeland 75748888Scael.Ql \&.Dc 75848888Scaelmay be used across one or more lines. 75948888Scael.Pp 76043435Scael.Dl Usage: .Dq string ... \*(Pu 76148888Scael.Bl -tag -width ".Dq Ar patternx ) ) ," -compact -offset 14n 76248888Scael.It Li \&.Dq 76343435Scael.Dq 76448888Scael.It Li ".Dq string." 76548888Scael.Dq string. 76648888Scael.It Li ".Dq string abc ." 76748888Scael.Dq string abc . 76848888Scael.It Li ".Dq \'^[A-Z]\'" 76948888Scael.Dq \'^[A-Z]\' 77048888Scael.It Li \&.Dq \&Ar pattern\ )\ )\ , 77143435Scael.Dq Ar pattern ) ) , 77248888Scael.El 77343435Scael.Pp 77443435ScaelIf 77548888Scael.Ql \&.Dq 77643435Scaelis called with no arguments 77743435Scael.Dq 77843435Scaelis assumed. The 77948888Scael.Ql \&.Dq 78048888Scaelmacro may call or be called by 78148888Scaelother macros. 78248888ScaelSee 78348888Scael.Sx Enclosure Macros 78448888Scaelfor discussion of 78548888Scael.Ql \&.Dc 78643435Scaeland 78748888Scael.Ql \&.Do 78848888Scaelmacro types. 78948888Scael.Ss Defined Variables 79048888ScaelA variable which is defined in an include file is specified 79148888Scaelby the macro 79248888Scael.Ql \&.Dv . 79343435Scael.Pp 79448888Scael.Dl Usage: .Dv defined_variable ... \*(Pu 79548888Scael.Bl -tag -width ".Dv MAXHOSTNAMELEN" -compact -offset 14n 79648888Scael.It Li ".Dv MAXHOSTNAMELEN" 79748888Scael.Dv MAXHOSTNAMELEN 79848888Scael.It Li ".Dv TIOCGPGRP )" 79948888Scael.Dv TIOCGPGRP ) 80048888Scael.El 80148888Scael.Pp 80248888ScaelIt is an error to call 80348888Scael.Ql \&.Dv 80448888Scaelwithout arguments. 80548888Scael.Ql \&.Dv 80648888Scaelmay call other macros and 80748888Scaelmay be called by other macros. 80848888Scael.Ss Emphasis Macro 80948888ScaelText may be stressed or emphasized with the 81048888Scael.Ql \&.Em 81148888Scaelmacro. The usual font for emphasis is italic. 81248888Scael.Pp 81343435Scael.Dl Usage: .Em argument ... \*(Pu 81448888Scael.Bl -tag -width ".Em vide infra ) ) ," -compact -offset 14n 81548888Scael.It Li ".Em does not" 81643435Scael.Em does not 81748888Scael.It Li ".Em exceed 1024 ." 81843435Scael.Em exceed 1024 . 81948888Scael.It Li ".Em vide infra ) ) ," 82043435Scael.Em vide infra ) ) , 82148888Scael.El 82243435Scael.Pp 82348888ScaelThe emphasis can be forced across several lines of text by using 82448888Scaelthe 82548888Scael.Ql \&.Bf 82648888Scaelmacro discussed in 82748888Scael.Sx Modes 82848888Scaelunder 82948888Scael.Sx PAGE LAYOUT . 83048888Scael.\" .Pp 83148888Scael.\" .Em 83248888Scael.\" I'm certain the reason so many people desire an MBA from Harvard 83348888Scael.\" is because they want to be successful philanthropists. 83448888Scael.\" .Em 83548888Scael.Pp 83648888ScaelThe 83748888Scael.Ql \&.Em 83848888Scaelmacro 83948888Scaelis callable and may call other macros. 84043435ScaelIt is an error to call 84148888Scael.Ql \&.Em 84243435Scaelwithout arguments. 84348888Scael.Ss Enclosure and Quoting Macros 84448888ScaelThe concept of enclosure is similar to quoting. 84548888ScaelThe object is to enclose a string or more between 84648888Scaela pair of characters like quotes or parentheses. 84748888ScaelThe terms quoting and enclosure are used 84848888Scaelinterchangeably throughout this document. Many of the 84948888Scaelone line enclosure macros end 85048888Scaelend in small letter 85148888Scael.Ql q 85248888Scaelto give a hint of quoting, but there are a few exceptions 85348888Scael(the macros 85448888Scael.Ql \&.En , 85548888Scael.Ql \&.Fn 85648888Scaeland 85748888Scael.Ql \&.Op 85848888Scaelare also enclosure macros). 85948888ScaelFor each enclosure macro 86048888Scaelthere is also a pair of open and close macros which end 86148888Scaelin small letters 86248888Scael.Ql o 86348888Scaeland 86448888Scael.Ql c 86548888Scaelrespectively. These can be used across one or more lines of text 86648888Scaeland while they cannot be nested, the one line quote macros 86748888Scaelcan be used inside 86848888Scaelof them. 86948888ScaelFor a good example of one these macros, see 87048888Scael.Sx Options . 87148888Scael.Pp 87248888Scael.Bd -filled -offset indent 87348888Scael.Bl -column "quote" "close" "open" "Enclose Stringx(in XX)" XXstringXX 87448888Scael.Em " quote close open function result" 87548888Scael\&.Aq, .Ac, .Ao Angle Bracket Enclosure <string> 87648888Scael\&.Bq, .Bc, .Bo Bracket Enclosure [string] 87748888Scael\&.Dq, .Dc, .Do Double Quote ``string'' 87848888Scael .Ec, .Eo Enclose String (in XX) XXstringXX 87948888Scael\&.Fn, .Fc, .Fo Function Enclosure function(string) 88048888Scael\&.Op, .Oc, .Oo Option Enclosure [string] 88148888Scael\&.Pq, .Pc, .Po Parenthesis Enclosure (string) 88248888Scael\&.Qq, .Qc, .Qo Straight Double Quote "string" 88348888Scael\&.Sq, .Sc, .So Single Quote `string' 88448888Scael\& .Xc, .Xo Extend Argument \ \-\- 88548888Scael.El 88648888Scael.Ed 88748888Scael.Pp 88848888ScaelThe macros 88948888Scael.Ql \&.Eo 89048888Scaeland 89148888Scael.Ql \&.Ec 89248888Scaelallow a user to specify an open and close with the first argument as the 89348888Scaelopening or closing string respectively. 89448888Scael.Ss Errno's (Section two only) 89543435ScaelThe 89648888Scael.Ql \&.Er 89748888Scaelerrno macro specifies the error return value 89848888Scaelfor section two library routines. The second example 89943435Scaelbelow shows 90048888Scael.Ql \&.Er 90143435Scaelused with the 90248888Scael.Ql \&.Bq 90348888Scaelmacro, as it would be used in 90448888Scaela section two manual page. 90543435Scael.Pp 90643435Scael.Dl Usage: .Er ERRNOTYPE ... \*(Pu 90748888Scael.Bl -tag -width ".Bq Er ENOTDIR" -compact -offset 14n 90848888Scael.It Li \&.Er ENOENT 90943435Scael.Er ENOENT 91048888Scael.It Li \&.Er ENOENT\ )\ ; 91148888Scael.Er ENOENT ) ; 91248888Scael.It Li \&.Bq \&Er ENOTDIR 91348888Scael.Bq Er ENOTDIR 91448888Scael.El 91543435Scael.Pp 91643435ScaelIt is an error to call 91748888Scael.Ql \&.Er 91843435Scaelwithout arguments. 91948888ScaelThe 92048888Scael.Ql \&.Er 92148888Scaelmacro 92248888Scaelis callable and may call other macros. 92343435Scael.Ss Environment Variables 92443435ScaelThe 92548888Scael.Ql \&.Ev 92648888Scaelmacro specifies a environment variable. 92743435Scael.Pp 92843435Scael.Dl Usage: .Ev argument ... \*(Pu 92948888Scael.Bl -tag -width ".Ev PRINTER ) ) ," -compact -offset 14n 93048888Scael.It Li \&.Ev DISPLAY 93143435Scael.Ev DISPLAY 93248888Scael.It Li \&.Ev PATH\ . 93343435Scael.Ev PATH . 93448888Scael.It Li \&.Ev PRINTER\ )\ )\ , 93543435Scael.Ev PRINTER ) ) , 93648888Scael.El 93743435Scael.Pp 93843435ScaelIt is an error to call 93948888Scael.Ql \&.Ev 94043435Scaelwithout arguments. 94148888ScaelThe 94248888Scael.Ql \&.Ev 94348888Scaelmacro 94448888Scaelis callable by other macros and may call other macros. 94548888Scael.Ss Function Argument 94648888ScaelThe 94748888Scael.Ql \&.Fa 94848888Scaelmacro is used to refer to function arguments (parameters) 94948888Scaeloutside of the SYNOPSIS section of the manual or inside 95048888Scaelthe SYNOPSIS section should a parameter list be too 95148888Scaellong for the 95248888Scael.Ql \&.Fn 95348888Scaelmacro and the enclosure macros 95448888Scael.Ql \&.Fo 95548888Scaeland 95648888Scael.Ql \&.Fc 95748888Scaelmust be used. 95848888Scael.Ql \&.Fa 95948888Scaelmay also be used to refer to structure members. 96048888Scael.Pp 96148888Scael.Dl Usage: .Fa function_argument ... \*(Pu 96248888Scael.Bl -tag -width ".Fa d_namlen\ )\ )\ ," -compact -offset 14n 96348888Scael.It Li \&.Fa d_namlen\ )\ )\ , 96448888Scael.Fa d_namlen ) ) , 96548888Scael.It Li \&.Fa iov_len 96648888Scael.Fa iov_len 96748888Scael.El 96848888Scael.Pp 96948888ScaelIt is an error to call 97048888Scael.Ql \&.Fa 97148888Scaelwithout arguments. 97248888Scael.Ql \&.Fa 97348888Scaelis callable by other macros and may call other macros. 97448888Scael.Ss Function Declaration 97548888ScaelThe 97648888Scael.Ql \&.Fd 97748888Scaelmacro is used in the SYNOPSIS section with section two or three 97848888Scaelfunctions. The 97948888Scael.Ql \&.Fd 98048888Scaelmacro does not call other macros and is not callable by other 98148888Scaelmacros. 98248888Scael.Pp 98348888Scael.Dl Usage: .Fd include_file (or defined variable) 98448888Scael.Pp 98548888ScaelIn the SYNOPSIS section a 98648888Scael.Ql \&.Fd 98748888Scaelrequest causes a line break if a function has already been presented 98848888Scaeland a break has not occurred. This leaves a nice vertical space 98948888Scaelin between the previous function call and the declaration for the 99048888Scaelnext function. 99143435Scael.Ss Flags 99243435ScaelThe 99348888Scael.Ql \&.Fl 99448888Scaelmacro handles command line flags. It prepends 99543435Scaela dash, 99648888Scael.Ql \- , 99743435Scaelto the flag. For interactive command flags, which 99843435Scaelare not prepended with a dash, the 99948888Scael.Ql \&.Cm 100048888Scael(command modifier) 100148888Scaelmacro is identical, but with out the dash. 100243435Scael.Pp 100343435Scael.Dl Usage: .Fl argument ... \*(Pu 100448888Scael.Bl -tag -width ".Fl \-s \-t \-v" -compact -offset 14n 100548888Scael.It Li \&.Fl 100643435Scael.Fl 100748888Scael.It Li \&.Fl cfv 100843435Scael.Fl cfv 100948888Scael.It Li \&.Fl cfv\ . 101043435Scael.Fl cfv . 101148888Scael.It Li \&.Fl s v t 101243435Scael.Fl s v t 101348888Scael.It Li \&.Fl -\ , 101443435Scael.Fl - , 101548888Scael.It Li \&.Fl xyz\ )\ , 101643435Scael.Fl xyz ) , 101748888Scael.El 101843435Scael.Pp 101943435ScaelThe 102048888Scael.Ql \&.Fl 102148888Scaelmacro without any arguments results 102248888Scaelin a dash representing stdin/stdout. 102343435ScaelNote that giving 102448888Scael.Ql \&.Fl 102543435Scaela single dash, will result in two dashes. 102648888ScaelThe 102748888Scael.Ql \&.Fl 102848888Scaelmacro 102948888Scaelis callable and may call other macros. 103043435Scael.Ss Functions (library routines) 103148888ScaelThe .Fn macro is modeled on ANSI C conventions. 103248888Scael.Bd -literal 103348888ScaelUsage: .Fn [type] function [[type] params ... \*(Pu] 103448888Scael.Ed 103548888Scael.Bl -tag -width ".Fn .int align. .const * char *sptrs" -compact 103648888Scael.It Li "\&.Fn getchar" 103743435Scael.Fn getchar 103848888Scael.It Li "\&.Fn strlen ) ," 103943435Scael.Fn strlen ) , 104048888Scael.It Li \&.Fn "\\*qint align\\*q" "\\*qconst * char *sptrs\\*q" , 104148888Scael.Fn "int align" "const * char *sptrs" , 104248888Scael.El 104343435Scael.Pp 104443435ScaelIt is an error to call 104548888Scael.Ql \&.Fn 104643435Scaelwithout any arguments. 104748888ScaelThe 104848888Scael.Ql \&.Fn 104948888Scaelmacro 105048888Scaelis callable by other macros and may call other macros, but 105148888Scaelnote that any call to another macro signals the end of 105248888Scaelthe 105348888Scael.Ql \&.Fn 105448888Scaelcall (it will close-paren at that point). 105548888Scael.Pp 105648888ScaelIn the SYNOPSIS section, the function will always begin at 105748888Scaelthe beginning of line. If there is more than one function 105848888Scaelpresented in the SYNOPSIS section and a function type has not been 105948888Scaelgiven, a line break will occur, leaving a nice vertical space 106048888Scaelbetween the current function name and the one prior. 106143435ScaelAt the moment, 106248888Scael.Ql \&.Fn 106343435Scaeldoes not check its word boundaries 106448888Scaelagainst troff line lengths and may split across a newline 106548888Scaelungracefully. This will be fixed in the near future. 106648888Scael.Ss Function Type 106748888ScaelThis macro is intended for the SYNOPSIS section. It may be used 106848888Scaelanywhere else in the manpage without problems, but its main purpose 106948888Scaelis to present the function type in kernel normal form for the SYNOPSIS 107048888Scaelof sections two and three 107148888Scael(it causes a page break allowing the function name to appear 107248888Scaelon the next line). 107348888Scael.Pp 107448888Scael.Dl Usage: .Ft type ... \*(Pu 107548888Scael.Pp 107648888Scael.Bl -tag -width "\&.Ft struct stat" -offset 14n -compact 107748888Scael.It Li \&.Ft struct stat 107848888Scael.Ft struct stat 107948888Scael.El 108048888Scael.Pp 108143435ScaelThe 108248888Scael.Ql \&.Ft 108348888Scaelrequest is not callable by other macros. 108448888Scael.Ss Interactive Commands 108548888ScaelThe 108648888Scael.Ql \&.Ic 108748888Scaelmacro designates an interactive or internal command. 108848888Scael.Pp 108948888Scael.Dl Usage: .Li argument ... \*(Pu 109048888Scael.Bl -tag -width ".Ic setenv , unsetenv" -compact -offset 14n 109148888Scael.It Li \&.Ic :wq 109248888Scael.Ic :wq 109348888Scael.It Li \&.Ic do while {...} 109448888Scael.Ic do while {...} 109548888Scael.It Li \&.Ic setenv\ , unsetenv 109648888Scael.Ic setenv , unsetenv 109748888Scael.El 109848888Scael.Pp 109948888ScaelIt is an error to call 110048888Scael.Ql \&.Ic 110148888Scaelwithout arguments. 110248888ScaelThe 110348888Scael.Ql \&.Ic 110448888Scaelmacro may call other macros and is callable. 110543435Scael.Ss Literals 110643435ScaelThe 110748888Scael.Ql \&.Li 110848888Scaelliteral macro may be used for special characters, 110943435Scaelvariable constants, anything which should be displayed as it 111043435Scaelwould be typed. 111143435Scael.Pp 111243435Scael.Dl Usage: .Li argument ... \*(Pu 111348888Scael.Bl -tag -width ".Li cntrl-D ) ," -compact -offset 14n 111448888Scael.It Li \&.Li \een 111543435Scael.Li \en 111648888Scael.It Li \&.Li M1 M2 M3\ ; 111743435Scael.Li M1 M2 M3 ; 111848888Scael.It Li \&.Li cntrl-D\ )\ , 111943435Scael.Li cntrl-D ) , 112048888Scael.It Li \&.Li 1024\ ... 112143435Scael.Li 1024 ... 112248888Scael.El 112343435Scael.Pp 112443435ScaelThe 112548888Scael.Ql \&.Li 112648888Scaelmacro 112748888Scaelis callable by other macros and may call other macros. 112848888Scael.Ss Name Macro 112948888ScaelThe 113048888Scael.Ql \&.Nm 113148888Scaelmacro is used for the document title or subject name. 113248888ScaelIt has the peculiarity of remembering the first 113343435Scaelargument it was called with, which should 113443435Scaelalways be the subject name of the page. When called without 113543435Scaelarguments, 113648888Scael.Ql \&.Nm 113743435Scaelregurgitates this initial name for the sole purpose 113843435Scaelof making less work for the author. 113948888ScaelNote: 114048888Scaela section two 114143435Scaelor three document function name is addressed with the 114248888Scael.Ql \&.Nm 114348888Scaelin the NAME section, and with 114448888Scael.Ql \&.Fn 114548888Scaelin the SYNOPSIS 114648888Scaeland remaining sections. 114743435ScaelFor interactive commands, such as the 114848888Scael.Ql while 114943435Scaelcommand keyword in 115043435Scael.Xr csh 1 , 115143435Scaelthe 115248888Scael.Ql \&.Ic 115348888Scaelmacro should be used. 115443435ScaelWhile the 115548888Scael.Ql \&.Ic 115643435Scaelis nearly identical 115743435Scaelto 115848888Scael.Ql \&.Nm , 115943435Scaelit can not recall the first argument it was invoked with. 116043435Scael.Pp 116143435Scael.Dl Usage: .Nm argument ... \*(Pu 116248888Scael.Bl -tag -width ".Nm mdoc.sample" -compact -offset 14n 116348888Scael.It Li \&.Nm mdoc.sample 116443435Scael.Nm mdoc.sample 116548888Scael.It Li \&.Nm \-mdoc 116643435Scael.Nm \-mdoc . 116748888Scael.It Li \&.Nm foo\ )\ )\ , 116843435Scael.Nm foo ) ) , 116948888Scael.It Li \&.Nm 117043435Scael.Nm 117148888Scael.El 117243435Scael.Pp 117343435ScaelThe 117448888Scael.Ql \&.Nm 117548888Scaelmacro 117648888Scaelis callable by other macros and may call other macros. 117748888Scael.Ss No\-Op or Normal Text Macro 117848888ScaelThe macro 117948888Scael.Li \&.No 118048888Scaelis 118148888Scaela hack for words in a macro command line which should 118248888Scael.Em not 118348888Scaelbe formatted and follows the conventional syntax 118448888Scaelfor content macros. 118548888Scael.Ss No Space Macro 118648888ScaelThe 118748888Scael.Ql \&.Ns 118848888Scaelmacro eliminates unwanted spaces in between macro requests. 118948888ScaelIt is useful for old style argument lists where there is no space 119048888Scaelbetween the flag and argument: 119148888Scael.Bl -tag -width ".Op Fl I Ns Ar directory" -offset indent 119248888Scael.It Li ".Op Fl I Ns Ar directory" 119348888Scaelproduces 119448888Scael.Op Fl I Ns Ar directory 119548888Scael.El 119648888Scael.Pp 119748888ScaelNote: the 119848888Scael.Ql \&.Ns 119948888Scaelmacro always invokes the 120048888Scael.Ql \&.No 120148888Scaelmacro after eliminating the space unless another macro name 120248888Scaelfollows it. 120348888ScaelThe macro 120448888Scael.Ql \&.Ns 120548888Scaelis callable and may call other macros. 120648888ScaelFor the special case of appending an apostrophe to a string, see 120748888Scael.Ql \&Ap . 120848888Scael.Sx Apostrophes . 120948888ScaelFor prefixes see 121048888Scael.Sx Prefixes. 121148888Scael.Ss Options 121248888ScaelThe 121348888Scael.Ql \&.Op 121448888Scaelmacro 121548888Scaelplaces option brackets around the any remaining arguments on the command 121648888Scaelline, and places any 121748888Scaeltrailing punctuation outside the brackets. The macros 121848888Scael.Ql \&.Oc 121948888Scaeland 122048888Scael.Ql \&.Oo 122148888Scaelmay be used across one or more lines. 122248888Scael.Pp 122348888Scael.Dl Usage: .Op options ... \*(Pu 122448888Scael.Bl -tag -width ".Op Fl c Ar objfil Op Ar corfil ," -compact -offset indent 122548888Scael.It Li \&.Op 122648888Scael.Op 122748888Scael.It Li ".Op Fl k" 122848888Scael.Op Fl k 122948888Scael.It Li ".Op Fl k ) ." 123048888Scael.Op Fl k ) . 123148888Scael.It Li ".Op Fl k Ar kookfile" 123248888Scael.Op Fl k Ar kookfile 123348888Scael.It Li ".Op Fl k Ar kookfile ," 123448888Scael.Op Fl k Ar kookfile , 123548888Scael.It Li ".Op Ar objfil Op Ar corfil" 123648888Scael.Op Ar objfil Op Ar corfil 123748888Scael.It Li ".Op Fl c Ar objfil Op Ar corfil ," 123848888Scael.Op Fl c Ar objfil Op Ar corfil , 123948888Scael.It Li \&.Op word1 word2 124048888Scael.Op word1 word2 124148888Scael.El 124248888Scael.Pp 124348888ScaelThe 124448888Scael.Ql \&.Oc 124548888Scaeland 124648888Scael.Ql \&.Oo 124748888Scaelmacros: 124848888Scael.Bd -literal -offset indent 124948888Scael\&.Oo 125048888Scael\&.Op \&Fl k \&Ar kilobytes 125148888Scael\&.Op \&Fl i \&Ar interval 125248888Scael\&.Op \&Fl c \&Ar count 125348888Scael\&.Oc 125448888Scael.Ed 125548888Scael.Pp 125648888ScaelProduce: 125748888Scael.Oo 125848888Scael.Op Fl k Ar kilobytes 125948888Scael.Op Fl i Ar interval 126048888Scael.Op Fl c Ar count 126148888Scael.Oc 126248888Scael.Pp 126348888ScaelThe macros 126448888Scael.Ql \&.Op , 126548888Scael.Ql \&.Oc 126648888Scaeland 126748888Scael.Ql \&.Oo 126848888Scaelare callable and may call other macros. 126948888Scael.Ss Parenthesis Quote/Enclosure 127048888ScaelMacros 127148888Scael.Li \&.Pq , \&.Pc 127248888Scaeland 127348888Scael.Li \&.Po 127448888Scaelfollow the conventions for a typical quoting macros, 127548888Scaelsee 127648888Scael.Sx Enclosure Macros 127748888Scaeland 127848888Scael.Sx Options 127948888Scaelabove. 128043435Scael.Ss Pathnames 128143435ScaelThe 128248888Scael.Ql \&.Pa 128348888Scaelmacro formats path or file names. 128443435Scael.Pp 128543435Scael.Dl Usage: .Pa pathname \*(Pu 128648888Scael.Bl -tag -width ".Pa /tmp/fooXXXXX ) ." -compact -offset 14n 128748888Scael.It Li \&.Pa /usr/share 128843435Scael.Pa /usr/share 128948888Scael.It Li \&.Pa /tmp/fooXXXXX\ )\ . 129043435Scael.Pa /tmp/fooXXXXX ) . 129148888Scael.El 129243435Scael.Pp 129348888ScaelThe 129448888Scael.Ql \&.Pa 129548888Scaelmacro 129648888Scaelis callable by other macros and may call other macros. 129748888Scael.Ss Single Quotes/Enclosure 129848888ScaelSee 129948888Scael.Sx Enclosure Macros . 130048888ScaelSee 130148888Scael.Sx Double Quote/Enclosure 130248888Scaelabove. 130348888ScaelThe single quoting macro 130448888Scael.Ql \&.Sq 130548888Scaelworks in the identical manner as 130648888Scael.Ql \&.Dq. 130748888Scael.Ss Prefix Macro 130848888ScaelThe 130948888Scael.Ql \&.Pf is a short cut for combining 131048888Scaeltwo strings together, the first of which is 131148888Scaelin the default font, and the second is a content 131248888Scaelspecified string. 131348888Scael.Pp 131448888Scael.Bl -tag -width ".Pf ( Fa name2 " -offset 14n -compact 131548888Scael.It Li ".Pf ( Fa name2" 131648888Scaelbecomes 131748888Scael.Pf ( Fa name2 131848888Scael.El 131948888Scael.Pp 132048888ScaelThe 132148888Scael.Ql \&.Pf 132248888Scaelmacro is not callable, but may call other macros. The 132348888Scael.Ql \&.Ns 132448888Scaelmacro performs the analogus suffix function. 132548888Scael.Ss Section Cross References 132648888ScaelThe 132748888Scael.Ql \&.Sx 132848888Scaelmacro designates a reference to a section header 132948888Scaelwithin the same document. It is callable by other macros and may 133048888Scaelcall other macros. 133148888Scael.Pp 133248888Scael.Bl -tag -width "Li \&.Sx FILES" -offset 14n 133348888Scael.It Li \&.Sx FILES 133448888Scael.Sx FILES 133548888Scael.El 133648888Scael.Ss References and Citations 133748888ScaelThe following macros make a modest attempt to handle references. 133848888ScaelAt best, the macros make it convientent to manually drop in a subset of 133948888Scaelrefer style references. 134048888Scael.Pp 134148888Scael.Bl -tag -width 6n -offset indent -compact 134248888Scael.It Li ".Rs" 134348888ScaelReference Start. Causes a line break and begins collection 134448888Scaelof reference information until the 134548888Scaelreference end macro is read. 134648888Scael.It Li ".Re" 134748888ScaelReference End. The reference is printed. 134848888Scael.It Li ".%A" 134948888ScaelReference author name, one name per invocation. 135048888Scael.It Li ".%B" 135148888ScaelBook title. 135248888Scael.It Li ".%J" 135348888ScaelJournal title. 135448888Scael.It Li ".%N" 135548888ScaelIssue number. 135648888Scael.It Li ".%O" 135748888ScaelOptional information. 135848888Scael.It Li ".%R" 135948888ScaelReport name. 136048888Scael.It Li ".%T" 136148888ScaelTitle of article. 136248888Scael.It Li ".%V" 136348888ScaelVolume(s). 136448888Scael.El 136548888Scael.Pp 136648888ScaelThe macros begining with 136748888Scael.Ql % 136848888Scaelare not callable, but may call only the trade name macro which 136948888Scaelreturns to its caller. The purpose is to allow trade names 137048888Scaelto be pretty printed in troff/ditroff output. WARNING: this 137148888Scaelhas very few trade names defined at the moment and will print unknown 137248888Scaeltrade names in the default font. 137343435Scael.Ss Symbolic 137448888ScaelThe symbolic emphasis macro is generally a boldface macro in 137548888Scaeleither the symbolic sense or the traditional English usage. 137643435Scael.Pp 137743435Scael.Dl Usage: .Sy symbol ... \*(Pu 137848888Scael.Bl -tag -width ".Sy Important Notice" -compact -offset 14n 137948888Scael.It Li \&.Sy Important Notice 138048888Scael.Sy Important Notice 138148888Scael.El 138243435Scael.Pp 138343435ScaelThe 138448888Scael.Ql \&.Sy 138548888Scaelmacro 138648888Scaelis callable by other macros and may call other macros, except 138748888Scaelin the second form. Arguments to 138848888Scael.Ql \&.Sy 138948888Scaelmay be quoted. 139043435Scael.Ss Variables 139143435ScaelGeneric variable reference: 139243435Scael.Pp 139343435Scael.Dl Usage: .Va variable ... \*(Pu 139448888Scael.Bl -tag -width ".Va char s ] ) ) ," -compact -offset 14n 139548888Scael.It Li \&.Va count 139643435Scael.Va count 139748888Scael.It Li \&.Va settimer , 139843435Scael.Va settimer , 139948888Scael.It Li \&.Va int\ *prt\ )\ : 140043435Scael.Va int\ *prt ) : 140148888Scael.It Li \&.Va char\ s\ ]\ )\ )\ , 140243435Scael.Va char\ s ] ) ) , 140348888Scael.El 140443435Scael.Pp 140548888ScaelIt is an error to call 140648888Scael.Ql \&.Va 140748888Scaelwithout any arguments. 140848888ScaelThe 140948888Scael.Ql \&.Va 141048888Scaelmacro 141148888Scaelis callable by other macros and may call other macros. 141243435Scael.Ss Cross References 141343435ScaelThe 141448888Scael.Ql \&.Xr 141548888Scaelmacro expects the first argument to be 141643435Scaela manual page name, and the second argument, if it exists, 141743435Scaelto be either a section page number or punctuation. Any 141843435Scaelremaining arguments are assumed to be punctuation. 141943435Scael.Pp 142043435Scael.Dl Usage: .Xr manpage [1,...,8] \*(Pu 142148888Scael.Bl -tag -width ".Xr mdoc 7 ) ) ," -compact -offset 14n 142248888Scael.It Li \&.Xr mdoc 142343435Scael.Xr mdoc 142448888Scael.It Li \&.Xr mdoc\ , 142543435Scael.Xr mdoc , 142648888Scael.It Li \&.Xr mdoc 7 142743435Scael.Xr mdoc 7 142848888Scael.It Li \&.Xr mdoc 7\ )\ )\ , 142943435Scael.Xr mdoc 7 ) ) , 143048888Scael.El 143143435Scael.Pp 143243435ScaelThe 143348888Scael.Ql \&.Xr 143448888Scaelmacro 143548888Scaelis callable by other macros and may call other macros. 143643435ScaelIt is an error to call 143748888Scael.Ql \&.Xr 143843435Scaelwithout 143943435Scaelany arguments. 144048888Scael.Ss Extended Arguments 144148888ScaelThe 144248888Scael.Li \&.Xo 144348888Scaeland 144448888Scael.Li \&.Xc 144548888Scaelmaxros allow one to extend an argument list 144648888Scaelon a macro boundary. Argument lists cannot 144748888Scaelbe extended within a macro 144848888Scaelwhich expects all of its arguments on one line such 144948888Scaelas 145048888Scael.Ql \&.Op . 145143435Scael.\" --- 145243435Scael.Sh PAGE LAYOUT MACROS 145343435Scael.Ss Section Headers 145448888ScaelThe first three 145548888Scael.Ql \&.Sh 145648888Scaelsection header macros 145748888Scaellist below are required in every 145848888Scaelman page. The remaining section headers 145948888Scaelare recommended at the disgression of the author 146048888Scaelwriting the manual page. The 146148888Scael.Ql \&.Sh 146248888Scaelmacro can take up to nine arguments. It may call 146348888Scaelother macros, but it may not be called by other macros. 146448888Scael.Bl -tag -width ".Sh SYNOPSIS" 146548888Scael.It \&.Sh NAME 146643435ScaelThe 146748888Scael.Ql \&.Sh NAME 146848888Scaelmacro is mandatory. If not specified, 146943435Scaelthe headers, footers and page layout defaults 147043435Scaelwill not be set and things will be rather unpleasant. 147143435ScaelThe NAME section consists of at least three items. 147243435ScaelThe first is the 147348888Scael.Ql \&.Nm 147448888Scaelname macro naming the subject of the man page. 147548888ScaelThe second is the Name Description macro, 147648888Scael.Ql \&.Nd , 147743435Scaelwhich separates the subject 147843435Scaelname from the third item, which is the description. The 147943435Scaeldescription should be the most terse and lucid possible, 148043435Scaelas the space available is small. 148148888Scael.It \&.Sh SYNOPSIS 148243435ScaelThe SYNOPSIS section describes the typical usage of the 148348888Scaelsubject of a man page. The macros required 148443435Scaelare either 148548888Scael.Ql ".Nm" , 148648888Scael.Ql ".Cd" , 148743435Scaelor 148848888Scael.Ql ".Fn" 148948888Scael(and possibly 149048888Scael.Ql ".Fd" , 149148888Scael.Ql ".Ft" 149248888Scaelmacros). 149343435ScaelThe function name 149448888Scaelmacro 149548888Scael.Ql ".Fn" 149643435Scaelis required 149743435Scaelfor manual page sections 2 and 3, the command and general 149848888Scaelname macro 149948888Scael.Ql \&.Nm 150048888Scaelis required for sections 1, 5, 6, 7, 8. 150148888ScaelSection 4 manuals require a 150248888Scael.Ql ".Nm" , ".Fd" 150348888Scaelor a 150448888Scael.Ql ".Cd" 150548888Scaelconfiguration device usage macro. 150648888ScaelSeveral other macros may be necessary to produce 150743435Scaelthe synopsis line as shown below: 150843435Scael.Pp 150948888Scael.Bd -filled -offset indent 151043435Scael.Nm cat 151143435Scael.Op Fl benstuv 151243435Scael.Op Fl 151343435Scael.Ar 151448888Scael.Ed 151543435Scael.Pp 151648888ScaelThe following macros were used: 151743435Scael.Pp 151843435Scael.Dl \&.Nm cat 151948888Scael.Dl \&.Op \&Fl benstuv 152048888Scael.Dl \&.Op \&Fl 152143435Scael.Dl \&.Ar 152248888Scael.It \&.Sh DESCRIPTION 152343435ScaelIn most cases the first text in the DESCRIPTION section 152443435Scaelis a brief paragraph on the command, function or file, 152543435Scaelfollowed by a lexical list of options and respective 152643435Scaelexplanations. To create such a list, the 152748888Scael.Ql \&.Bl 152848888Scaelbegin-list, 152948888Scael.Ql \&.It 153048888Scaellist-item and 153148888Scael.Ql \&.El 153248888Scaelend-list 153348888Scaelmacros are used (see 153448888Scael.Sx Lists and Columns 153548888Scaelbelow). 153648888Scael.El 153743435Scael.Pp 153843435ScaelThe following 153948888Scael.Ql \&.Sh 154043435Scaelsection headers are part of the 154143435Scaelpreferred manual page layout and must be used appropriately 154243435Scaelto maintain consistency. They are listed in the order 154343435Scaelin which they would be used. 154448888Scael.Bl -tag -width SYNOPSIS 154548888Scael.It \&.Sh ENVIRONMENT 154643435ScaelThe ENVIRONMENT section should reveal any related 154743435Scaelenvironment 154843435Scaelvariables and clues to their behaviour and/or usage. 154948888Scael.It \&.Sh EXAMPLES 155043435ScaelThere are several ways to create examples. See 155143435Scaelthe EXAMPLES section below 155243435Scaelfor details. 155348888Scael.It \&.Sh FILES 155443435ScaelFiles which are used or created by the man page subject 155543435Scaelshould be listed via the 155648888Scael.Ql \&.Pa 155748888Scaelmacro in the FILES section. 155848888Scael.It \&.Sh SEE ALSO 155943435ScaelReferences to other material on the man page topic and 156043435Scaelcross references to other relevant man pages should 156143435Scaelbe placed in the SEE ALSO section. Cross references 156243435Scaelare specified using the 156348888Scael.Ql \&.Xr 156448888Scaelmacro. At this time 156543435Scael.Xr refer 1 156643435Scaelstyle references are not accommodated. 156748888Scael.It \&.Sh STANDARDS 156843435ScaelIf the command, library function or file adheres to a 156943435Scaelspecific implementation such as POSIX 1003.1 or 157043435ScaelANSI C X3.159-1989 this should be noted here. If the 157143435Scaelcommand does not adhere to any standard, its history 157243435Scaelshould be noted in the HISTORY section. 157348888Scael.It \&.Sh HISTORY 157443435ScaelAny command which does not adhere to any specific standards 157543435Scaelshould be outlined historically in this section. 157648888Scael.It \&.Sh AUTHORS 157743435ScaelCredits, if need be, should be placed here. 157848888Scael.It \&.Sh DIAGNOSTICS 157943435ScaelDiagnostics from a command should be placed in this section. 158048888Scael.It \&.Sh ERRORS 158143435ScaelSpecific error handling, especially from library functions 158243435Scael(man page sections 2 and 3) should go here. The 158348888Scael.Ql \&.Er 158448888Scaelmacro is used to specify an errno. 158548888Scael.It \&.Sh BUGS 158643435ScaelBlatant problems with the topic go here... 158748888Scael.El 158843435Scael.Pp 158948888ScaelUser specified 159048888Scael.Ql \&.Sh 159148888Scaelsections may be added, 159248888Scaelfor example, this section was set with: 159348888Scael.Bd -literal -offset 14n 159448888Scael\&.Sh PAGE LAYOUT MACROS 159548888Scael.Ed 159643435Scael.Ss Paragraphs and Line Spacing. 159748888Scael.Bl -tag -width 6n 159848888Scael.It \&.Pp 159943435ScaelThe \&.Pp paragraph command may 160043435Scaelbe used to specify a line space where necessary. 160148888ScaelThe macro is not necessary after a 160248888Scael.Ql \&.Sh 160343435Scaelor 160448888Scael.Ql \&.Ss 160548888Scaelmacro or before 160643435Scaela 160748888Scael.Ql \&.Bl 160848888Scaelmacro. 160948888Scael(The 161048888Scael.Ql \&.Bl 161148888Scaelmacro asserts a vertical distance unless the -compact flag is given). 161248888Scael.El 161348888Scael.\" .Pp 161448888Scael.\" .Ds I 161548888Scael.\" .Cw (ax+bx+c) \ is\ produced\ by\ \& 161648888Scael.\" .\".Cw (ax+bx+c) \&.Va_by_) \&_and_\& \&[?/]m_b1_e1_f1[?/]\& 161748888Scael.\" .Cl Cx \t\t 161848888Scael.\" .Li \&.Cx\ ( 161948888Scael.\" .Cx 162048888Scael.\" .Cl Cx \t\t 162148888Scael.\" .Li \&.Va ax 162248888Scael.\" .Cx 162348888Scael.\" .Cl Cx \t\t 162448888Scael.\" .Li \&.Sy \+ 162548888Scael.\" .Cx 162648888Scael.\" .Cl Cx \&(\& 162748888Scael.\" .Va ax 162848888Scael.\" .Cx + 162948888Scael.\" .Va by 163048888Scael.\" .Cx + 163148888Scael.\" .Va c ) 163248888Scael.\" .Cx \t 163348888Scael.\" .Em is produced by 163448888Scael.\" .Cx \t 163548888Scael.\" .Li \&.Va by 163648888Scael.\" .Cx 163748888Scael.\" .Cl Cx \t\t 163848888Scael.\" .Li \&.Sy \+ 163948888Scael.\" .Cx 164048888Scael.\" .Cl Cx \t\t 164148888Scael.\" .Li \&.Va c ) 164248888Scael.\" .Cx 164348888Scael.\" .Cl Cx \t\t 164448888Scael.\" .Li \&.Cx 164548888Scael.\" .Cx 164648888Scael.\" .Cw 164748888Scael.\" .De 164848888Scael.\" .Pp 164948888Scael.\" This example shows the same equation in a different format. The spaces 165048888Scael.\" around the 165148888Scael.\" .Li \&+ 165248888Scael.\" signs were forced with 165348888Scael.\" .Li \e : 165448888Scael.\" .Pp 165548888Scael.\" .Ds I 165648888Scael.\" .Cw (ax\ +\ bx\ +\ c) \ is\ produced\ by\ \& 165748888Scael.\" .\".Cw (ax+bx+c) \&.Va_by_) \&_and_\& \&[?/]m_b1_e1_f1[?/]\& 165848888Scael.\" .Cl Cx \t\t 165948888Scael.\" .Li \&.Cx\ ( 166048888Scael.\" .Cx 166148888Scael.\" .Cl Cx \t\t 166248888Scael.\" .Li \&.Va a 166348888Scael.\" .Cx 166448888Scael.\" .Cl Cx \t\t 166548888Scael.\" .Li \&.Sy x 166648888Scael.\" .Cx 166748888Scael.\" .Cl Cx \t\t 166848888Scael.\" .Li \&.Cx \e\ +\e\ \e& 166948888Scael.\" .Cx 167048888Scael.\" .Cl Cx \&(\& 167148888Scael.\" .Va a 167248888Scael.\" .Sy x 167348888Scael.\" .Cx \ +\ \& 167448888Scael.\" .Va b 167548888Scael.\" .Sy y 167648888Scael.\" .Cx \ +\ \& 167748888Scael.\" .Va c ) 167848888Scael.\" .Cx \t 167948888Scael.\" .Em is produced by 168048888Scael.\" .Cl Cx \t\t 168148888Scael.\" .Li \&.Va b 168248888Scael.\" .Cx 168348888Scael.\" .Cl Cx \t\t 168448888Scael.\" .Li \&.Sy y 168548888Scael.\" .Cx 168648888Scael.\" .Cl Cx \t\t 168748888Scael.\" .Li \&.Cx \e\ +\e\ \e& 168848888Scael.\" .Cx 168948888Scael.\" .Cl Cx \t\t 169048888Scael.\" .Li \&.Va c ) 169148888Scael.\" .Cx 169248888Scael.\" .Cl Cx \t\t 169348888Scael.\" .Li \&.Cx 169448888Scael.\" .Cx 169548888Scael.\" .Cw 169648888Scael.\" .De 169748888Scael.\" .Pp 169848888Scael.\" The incantation below was 169948888Scael.\" lifted from the 170048888Scael.\" .Xr adb 1 170148888Scael.\" manual page: 170248888Scael.\" .Pp 170348888Scael.\" .Ds I 170448888Scael.\" .Cw \&[?/]m_b1_e1_f1[?/]\& is\ produced\ by 170548888Scael.\" .Cl Cx \t\t 170648888Scael.\" .Li \&.Cx Op Sy ?/ 170748888Scael.\" .Cx 170848888Scael.\" .Cl Cx \t\t 170948888Scael.\" .Li \&.Nm m 171048888Scael.\" .Cx 171148888Scael.\" .Cl Cx Op Sy ?/ 171248888Scael.\" .Nm m 171348888Scael.\" .Ad \ b1 e1 f1 171448888Scael.\" .Op Sy ?/ 171548888Scael.\" .Cx \t 171648888Scael.\" .Em is produced by 171748888Scael.\" .Cx \t 171848888Scael.\" .Li \&.Ar \e\ b1 e1 f1 171948888Scael.\" .Cx 172048888Scael.\" .Cl Cx \t\t 172148888Scael.\" .Li \&.Op Sy ?/ 172248888Scael.\" .Cx 172348888Scael.\" .Cl Cx \t\t 172448888Scael.\" .Li \&.Cx 172548888Scael.\" .Cx 172648888Scael.\" .Cw 172748888Scael.\" .De 172848888Scael.\" .Pp 172948888Scael.Ss Examples and Displays 173048888ScaelThere are five types of displays, a quickie one line indented display 173148888Scael.Ql \&.D1 , 173248888Scaela quickie one line literal display 173348888Scael.Ql \&.Dl , 173448888Scaela block literal, block filled and block ragged which use 173548888Scaelthe 173648888Scael.Ql \&.Bd 173748888Scaelbegin-display 173848888Scaeland 173948888Scael.Ql \&.Ed 174048888Scaelend-display macros. 174143435Scael.Pp 174248888Scael.Bl -tag -width \&.D1 174348888Scael.It Li \&.D1 174448888Scael(D-one) Display one line of indented text. 174548888ScaelArguments are checked to see if they are callable. 174648888Scael.Bd -ragged -offset indent 174748888Scael.Li \&.D1 \&Fl ldghfstru 174848888Scael.Ed 174943435Scael.Pp 175048888Scaelproduces: 175143435Scael.Pp 175248888Scael.Dl Fl ldghfstru 175348888Scael.It Li \&.Dl 175448888Scael(D-ell) 175548888ScaelDisplay one line of indented 175648888Scael.Em literal 175748888Scaeltext. The 175848888Scael.Ql \&.Dl 175948888Scaelexample macro has been used throughout this 176048888Scaelfile. It allows 176148888Scaelthe indent (display) of one line of text. 176248888ScaelIts default font is set to 176348888Scaelconstant width (literal) however 176448888Scael.Ql \&.Dl 176548888Scaeldoes check arguments to see it they are callable. 176648888ScaelMacros called from 176743435Scael.Li \&.Dl 176848888Scaelshould be content macros; calling macros from 176948888Scaelthe page layout section 177048888Scaelis redundant and may cause unpredictable errors. 177148888Scael.Bd -ragged -offset indent 177243435Scael.Li \&.Dl % ls -ldg /usr/local/bin 177348888Scael.Ed 177443435Scael.Pp 177543435Scaelproduces: 177648888Scael.Pp 177743435Scael.Dl % ls -ldg /usr/local/bin 177848888Scael.It Li \&.Bd 177948888ScaelBegin-display. The 178048888Scael.Ql \&.Bd 178148888Scaeldisplay must be ended with the 178248888Scael.Ql \&.Ed 178348888Scaelmacro. Displays may be nested within displays and 178448888Scaellists. 178548888Scael.Ql \&.Bd 178648888Scaelhas the following syntax: 178743435Scael.Pp 178848888Scael.Dl ".Bd display-type [offset offset_value]" 178943435Scael.Pp 179048888ScaelThe display-type must be one of the following four types and 179148888Scaelmay have an offset specifier for indentation: 179248888Scael.Ql \&.Bd . 179343435Scael.Pp 179448888Scael.Bl -tag -width "literalxx" -compact 179548888Scael.It Fl ragged 179643435ScaelDisplay a block of text as typed, 179748888Scaelright (and left) margin edges are left ragged. 179848888Scael.It Fl filled 179948888ScaelDisplay a filled (formatted) block. 180048888ScaelThe block of text is formatted (the edges are filled \- 180148888Scaelnot left ragged). 180248888Scael.It Fl literal 180348888ScaelDisplay a literal block, useful for source code or 180448888Scaelsimple tabbed or spaced text. 180548888Scael.It Fl file Ar file_name 180648888ScaelThe file name following the 180748888Scael.Fl file 180848888Scaelflag is read and displayed. Literal mode is 180948888Scaelasserted and tabs are set at 8 constant width character 181048888Scaelintervals, however any 181148888Scael.Xr troff/ Ns Nm \-mdoc 181248888Scaelcommands in file will be processed. 181348888Scael.It Fl offset Ar string 181448888ScaelIf 181548888Scael.Fl offset 181648888Scaelis specified with one of the following strings, the string 181748888Scaelis interpreted to indicate the level of indentation for the 181848888Scaelforthcoming block of text: 181948888Scael.Pp 182048888Scael.Bl -tag -width "indent" -compact 182148888Scael.It Ar left 182243435ScaelAlign block on the current left margin, 182343435Scaelthis is the default mode of 182448888Scael.Ql \&.Bd . 182548888Scael.It Ar center 182643435ScaelSupposedly center the block. At this time 182743435Scaelunfortunately, the block merely gets 182843435Scaelleft aligned about an imaginary center margin. 182948888Scael.It Ar indent 183048888ScaelIndents by one default indent value or tab. The default 183148888Scaelindent value is also used for the 183248888Scael.Ql \&.D1 183348888Scaeldisplay so one can be garanteed of the two types of displays 183448888Scaellining up. This indent is nornally set to 6n or about two 183548888Scaelthirds of an inch (six constant width characters). 183648888Scael.It Ar indent-two 183748888ScaelIndents two times the default indent value. 183848888Scael.It Ar right 183948888ScaelThis 184048888Scael.Em left 184148888Scaelaligns the block about two inches from 184248888Scaelthe right side of the page. This macro also needs 184348888Scaelwork and perhaps may never be right in 184448888Scael.Xr troff . 184548888Scael.El 184648888Scael.El 184748888Scael.It ".Ed" 184848888ScaelEnd-display. 184948888Scael.El 185048888Scael.Ss Tagged Lists and Columns 185148888ScaelThere are several types of lists which may be initiated with the 185248888Scael.Ql ".Bl" 185348888Scaelbegin-list macro. Items within the list 185448888Scaelare specified with the 185548888Scael.Ql ".It" 185648888Scaelitem macro and 185748888Scaeleach list must end with the 185848888Scael.Ql ".El" 185948888Scaelmacro. Lists may be nested within themselves and within displays. 186048888ScaelColumns may be used inside of lists, but lists are unproven 186148888Scaelinside of columns. 186243435Scael.Pp 186348888ScaelIn addition, several list attributes may be specified such as 186448888Scaelthe width of a tag, the list offset, and compactness specified 186548888Scael(blank lines between items allowed or disallowed). 186648888ScaelThe following list types are accepted by 186748888Scael.Ql ".Bl": 186843435Scael.Pp 186948888Scael.Bl -ohang -compact 187048888Scael.It Fl bullet 187148888Scael.It Fl item 187248888Scael.It Fl enum 187348888ScaelThese three are the simplest types of lists. Once the 187448888Scael.Ql ".Bl" 187548888Scaelmacro has been given, items in the list are merely 187648888Scaelindicated by a line consisting solely of the 187748888Scael.Ql ".It" 187848888Scaelmacro. For example, the source text for a simple enumerated list 187948888Scaelwould look like: 188048888Scael.Bd -literal -offset indent-two 188148888Scael\&.Bl -enum -compact 188248888Scael\&.It 188348888Scael\&Item one goes here. 188448888Scael\&.It 188548888Scael\&And item two here. 188648888Scael\&.It 188748888Scael\&Lastly item three goes here. 188848888Scael\&.El 188948888Scael.Ed 189043435Scael.Pp 189148888ScaelThe results: 189243435Scael.Pp 189348888Scael.Bl -enum -offset indent-two -compact 189448888Scael.It 189548888ScaelItem one goes here. 189648888Scael.It 189748888ScaelAnd item two here. 189848888Scael.It 189948888ScaelLastly item three goes here. 190048888Scael.El 190143435Scael.Pp 190248888ScaelA simple bullet list construction: 190348888Scael.Bd -literal -offset indent-two 190448888Scael\&.Bl -bullet -compact 190548888Scael\&.It 190648888Scael\&Bullet one goes here. 190748888Scael\&.It 190848888Scael\&Bullet two here. 190948888Scael\&.El 191048888Scael.Ed 191143435Scael.Pp 191248888ScaelProduces: 191348888Scael.Bl -bullet -offset indent-two -compact 191448888Scael.It 191548888ScaelBullet one goes here. 191648888Scael.It 191748888ScaelBullet two here. 191848888Scael.El 191943435Scael.Pp 192048888Scael.It Fl tag 192148888Scael.It Fl diag 192248888Scael.It Fl hang 192348888Scael.It Fl ohang 192448888Scael.It Fl inset 192548888ScaelThese list-types collect arguments specified with the 192648888Scael.Ql \&.It 192748888Scaelmacro and create a label which may be 192848888Scael.Em inset 192948888Scaelinto the forth coming text, 193048888Scael.Em hanged 193148888Scael(exdented) from the forth coming text, 193248888Scael.Em overhanged 193348888Scaelset above the forth coming paragraph or 193448888Scael.Em tagged 193548888Scael(exdented and offset). This 193648888Scaellist was constructed with the 193748888Scael.Ql Fl ohang 193848888Scaellist-type. The 193948888Scael.Ql \&.It 194048888Scaelmacro may call any callable macros for the inset, hang 194148888Scaeland tag list-types, but will not call macros for the 194248888Scaeldiag type. 194348888ScaelHere is an example of inset labels: 194448888Scael.Bl -inset -offset indent 194548888Scael.It Em Tag 194648888ScaelThe tagged list (also called a tagged paragraph) is the 194748888Scaelmost common type of list used in the Berkeley manuals. 194848888Scael.It Em Diag 194948888ScaelDiag lists create section four diagnostic lists 195048888Scaeland are similar to inset lists except callable 195148888Scaelmacros are ignored. 195248888Scael.It Em Hang 195348888ScaelHanged labels are a matter of taste. 195448888Scael.It Em Ohang 195548888ScaelOver hanging labels are nice when space is constrained. 195648888Scael.It Em Inset 195748888ScaelInset labels are useful for controlling blocks of 195848888Scaelparagraphs and are valuable for converting 195948888Scael.Nm \-mdoc 196048888Scaelmanuals to other formats. 196148888Scael.El 196243435Scael.Pp 196348888ScaelHere is the source text which produced the above example: 196448888Scael.Bd -literal -offset indent 196548888Scael\&.Bl -inset -offset indent 196648888Scael\&.It Em Tag 196748888Scael\&The tagged list (also called a tagged paragraph) is the 196848888Scael\&most common type of list used in the Berkeley manuals. 196948888Scael\&.It Em Diag 197048888Scael\&Diag lists create section four diagnostic lists 197148888Scael\&and are similar to inset lists except callable 197248888Scael\¯os are ignored. 197348888Scael\&.It Em Hang 197448888Scael\&Hanged labels are a matter of taste. 197548888Scael\&.It Em Ohang 197648888Scael\&Over hanging labels are nice when space is constrained. 197748888Scael\&.It Em Inset 197848888Scael\&Inset labels are useful for controlling blocks of 197948888Scael\¶graphs and are valuable for converting 198048888Scael\&.Nm \-mdoc 198148888Scael\&manuals to other formats. 198248888Scael\&.El 198348888Scael.Ed 198443435Scael.Pp 198548888ScaelHere is a hanged list with just one item: 198648888Scael.Bl -hang -offset indent 198748888Scael.It Em Hanged 198848888Scaellabels appear similar to tagged lists when the 198948888Scaellabel is smaller than the label width. 199048888Scael.It Em Longer hanged list labels 199148888Scaelblend in to the paragraph unlike 199248888Scaeltagged paragraph labels. 199348888Scael.El 199443435Scael.Pp 199548888ScaelAnd the unfomatted text which created it: 199648888Scael.Bd -literal -offset indent 199748888Scael\&.Bl -hang -offset indent 199848888Scael\&.It Em Hanged 199948888Scael\&labels appear similar to tagged lists when the 200048888Scael\&label is smaller than the label width. 200148888Scael\&.It Em Longer hanged list labels 200248888Scael\&blend in to the paragraph unlike 200348888Scael\&tagged paragraph labels. 200448888Scael\&.El 200548888Scael.Ed 200648888Scael.Pp 200748888ScaelThe tagged list which follows uses an optional width specifier to controll 200848888Scaelthe width of the tag. 200948888Scael.Pp 201048888Scael.Bl -tag -width "PAGEIN 10" -compact -offset indent 201148888Scael.It SL 10 201243435Scaelsleep time of the process (seconds blocked) 201348888Scael.It PAGEIN 10 201448888Scaelnumber of disk i/o's resulting from references 201548888Scaelby the process to pages not loaded in core. 201648888Scael.It UID 10 201743435Scaelnumerical user-id of process owner 201848888Scael.It PPID 10 201948888Scaelnumerical id of parent of process process priority 202048888Scael(non-positive when in non-interruptible wait) 202148888Scael.El 202243435Scael.Pp 202343435ScaelThe raw text: 202448888Scael.Bd -literal -offset indent 202548888Scael\&.Bl -tag -width "PAGEIN 10" -compact -offset indent 202648888Scael\&.It SL 10 202748888Scael\&sleep time of the process (seconds blocked) 202848888Scael\&.It PAGEIN 10 202948888Scael\&number of disk i/o's resulting from references 203048888Scael\&by the process to pages not loaded in core. 203148888Scael\&.It UID 10 203248888Scael\&numerical user-id of process owner 203348888Scael\&.It PPID 10 203448888Scael\&numerical id of parent of process process priority 203548888Scael\&(non-positive when in non-interruptible wait) 203648888Scael\&.El 203748888Scael.Ed 203843435Scael.Pp 203948888ScaelAcceptable width specifiers: 204048888Scael.Bl -tag -width Ar -offset indent 204148888Scael.It Fl width Ar "\&Fl" 204248888Scaelsets the width to the default width for a flag. All callable 204348888Scaelmacros have a default width value. The 204448888Scael.Ql \&.Fl , 204548888Scaelvalue is presently 204648888Scaelset to ten constant width characters or about five sixth of 204748888Scaelan inch. 204848888Scael.It Fl width Ar "24n" 204948888Scaelsets the width to 24 constant width characters or about two 205048888Scaelinches. The 205148888Scael.Ql n 205248888Scaelis absolutely necessary for the scaling to work correctly. 205348888Scael.It Fl width Ar "ENAMETOOLONG" 205448888Scaelsets width to the constant width length of the 205548888Scaelstring given. 205648888Scael.It Fl width Ar "\\*qint mkfifo\\*q" 205748888Scaelagain, the width is set to the constant width of the string 205848888Scaelgiven. 205948888Scael.El 206043435Scael.Pp 206148888ScaelIf a width is not specified for the tag list type, the first 206248888Scaeltime 206348888Scael.Ql \&.It 206448888Scaelis invoked, an attempt is made to determine an appropriate 206548888Scaelwidth. If the first argument to 206648888Scael.Ql ".It" 206748888Scaelis a callable macro, the default width for that macro will be used 206848888Scaelas if the macro name had been supplied as the width. However, 206948888Scaelif another item in the list is given with a different callable 207048888Scaelmacro name, a new and nested list is assumed. Here is an involved 207148888Scaelexample of a self nesting list: 207248888Scael.Sh DIAGNOSTICS 207348888ScaelThe debugging facilities for 207448888Scael.Nm \-mdoc 207548888Scaelare limited, but can help detect subtle errors such 207648888Scaelas the collision of an argument name with an internal 207748888Scaelregister or macro name. (A what?) 207848888ScaelA register is an arithmetic storage class for 207948888Scael.Xr troff 208048888Scaelwith a one or two character name. 208148888ScaelAll registers internal to 208248888Scael.Nm \-mdoc 208348888Scaelfor 208448888Scael.Xr troff 208548888Scaeland 208648888Scael.Xr ditroff 208748888Scaelare two characters and 208848888Scaelof the form <uppercase><lowercase> such as 208948888Scael.Ql \&Ar , 209048888Scael<lowercase><uppercase> as 209148888Scael.Ql \&aR 209243435Scaelor 209348888Scael<upper or lower letter><digit> as 209448888Scael.Ql \&C\&1 . 209548888ScaelAnd adding to the muddle, 209648888Scael.Xr troff 209748888Scaelhas its own internal registers all of which are either 209848888Scaeltwo lowercase characters or a dot plus a letter or meta-character 209948888Scaelcharacter. 210048888ScaelIn one of the introduction examples, it was shown how to 210148888Scaelprevent the interpretation of a macro name with the escape sequence 210248888Scael.Ql \e& . 210348888ScaelThis is sufficient for the internal register names also. 210443435Scael.Pp 210548888Scael.\" Every callable macro name has a corresponding register 210648888Scael.\" of the same name (<Uppercase><lowercase>). 210748888Scael.\" There are also specific registers which have 210848888Scael.\" been used for stacks and arrays and are listed in the 210948888Scael.\" .Sx Appendix . 211048888Scael.\" .Bd -ragged -offset 4n 211148888Scael.\" [A-Z][a-z] registers corresponding to macro names (example ``Ar'') 211248888Scael.\" [a-z][A-Z] registers corresponding to macro names (example ``aR'') 211348888Scael.\" C[0-9] argument types (example C1) 211448888Scael.\" O[0-9] offset stack (displays) 211548888Scael.\" h[0-9] horizontal spacing stack (lists) 211648888Scael.\" o[0-9] offset (stack) (lists) 211748888Scael.\" t[0-9] tag stack (lists) 211848888Scael.\" v[0-9] vertical spacing stack (lists) 211948888Scael.\" w[0-9] width tag/label stack 212048888Scael.\" .Ed 212148888Scael.\" .Pp 212248888ScaelIf a non-escaped register name is given in the argument list of a request 212348888Scaelunpredictable behaviour will occur. In general, anytime huge portions 212448888Scaelof text do not appear where expected in the output, or small strings 212548888Scaelsuch as list tags disappear, chances are there is a misunderstanding 212648888Scaelabout an argument type in the argument list. 212748888ScaelYour mother never intended for you to remember this evil stuff - so here 212848888Scaelis a way to find out whether or not your arguments are valid: The 212948888Scael.Ql \&.Db 213048888Scael(debug) 213148888Scaelmacro displays the interpretation of the argument list for most 213248888Scaelmacros. Macros such as the 213348888Scael.Ql \&.Pp 213448888Scael(paragraph) 213548888Scaelmacro do not contain debugging information. All of the callable macros do, 213648888Scaeland it is strongly advised whenever in doubt, 213748888Scaelturn on the 213848888Scael.Ql \&.Db 213948888Scaelmacro. 214043435Scael.Pp 214148888Scael.Dl Usage: \&.Db [on | off] 214243435Scael.Pp 214348888ScaelAn example of a portion of text with 214448888Scaelthe debug macro placed above and below an 214548888Scaelartificially created problem (a flag argument 214648888Scael.Ql \&aC 214748888Scaelwhich should be 214848888Scael.Ql \e&aC 214948888Scaelin order to work): 215048888Scael.Bd -literal -offset indent 215148888Scael\&.Db on 215248888Scael\&.Op Fl aC Ar file ) 215348888Scael\&.Db off 215448888Scael.Ed 215543435Scael.Pp 215648888ScaelThe resulting output: 215748888Scael.Bd -literal -offset indent 215848888ScaelDEBUGGING ON 215948888ScaelDEBUG(argv) MACRO: `.Op' Line #: 2 216048888Scael Argc: 1 Argv: `Fl' Length: 2 216148888Scael Space: `' Class: Executable 216248888Scael Argc: 2 Argv: `aC' Length: 2 216348888Scael Space: `' Class: Executable 216448888Scael Argc: 3 Argv: `Ar' Length: 2 216548888Scael Space: `' Class: Executable 216648888Scael Argc: 4 Argv: `file' Length: 4 216748888Scael Space: ` ' Class: String 216848888Scael Argc: 5 Argv: `)' Length: 1 216948888Scael Space: ` ' Class: Closing Punctuation or suffix 217048888Scael MACRO REQUEST: .Op Fl aC Ar file ) 217148888ScaelDEBUGGING OFF 217248888Scael.Ed 217343435Scael.Pp 217448888ScaelThe first line of information tells the name of the calling 217548888Scaelmacro, here 217648888Scael.Ql \&.Op , 217748888Scaeland the line number it appears on. If one or more files are involved 217848888Scael(especially if text from another file is included) the line number 217948888Scaelmay be bogus. If there is only one file, it should be accurate. 218048888ScaelThe second line gives the argument count, the argument 218148888Scael.Pq Ql \&Fl 218248888Scaeland its length. If the length of an argument is two characters, the 218348888Scaelargument is tested to see if it is executable (unfortunately, any 218448888Scaelregister which contains a non-zero value appears executable). 218548888ScaelThe third line gives the space allotted for a class, and the 218648888Scaelclass type. The problem here is the argument aC should not be 218748888Scaelexecutable. The four types of classes are string, executable, closing 218848888Scaelpunctuation and opening punctuation. The last line shows the entire 218948888Scaelargument list as it was read. In this next example, the offending 219048888Scael.Ql \&aC 219148888Scaelis escaped: 219248888Scael.Bd -literal -offset indent 219348888Scael\&.Db on 219448888Scael\&.Em An escaped \e&aC 219548888Scael\&.Db off 219648888Scael.Ed 219748888Scael.Bd -literal -offset indent 219848888ScaelDEBUGGING ON 219948888ScaelDEBUG(fargv) MACRO: `.Em' Line #: 2 220048888Scael Argc: 1 Argv: `An' Length: 2 220148888Scael Space: ` ' Class: String 220248888Scael Argc: 2 Argv: `escaped' Length: 7 220348888Scael Space: ` ' Class: String 220448888Scael Argc: 3 Argv: `aC' Length: 2 220548888Scael Space: ` ' Class: String 220648888Scael MACRO REQUEST: .Em An escaped &aC 220748888ScaelDEBUGGING OFF 220848888Scael.Ed 220943435Scael.Pp 221048888ScaelThe argument 221148888Scael.Ql \e&aC 221248888Scaelshows up with the same length of 2 as the 221348888Scael.Ql \e& 221448888Scaelsequence produces a zero width, but a register 221548888Scaelnamed 221648888Scael.Ql \e&aC 221748888Scaelwas not found and the type classified as string. 221848888Scael.Pp 221948888ScaelOther diagnostics consist of usage statements and are self explanatory. 222043435Scael.Sh FILES 222148888Scael.Bl -tag -width /usr/share/man0/template.doc -compact 222248888Scael.It Pa /usr/share/tmac/tmac.doc 222343435Scaelmanual macro package 222448888Scael.It Pa /usr/share/man0/template.doc 222543435Scaeltemplate for writing a man page 222648888Scael.El 222743435Scael.Sh HISTORY 222843435Scael4.4 BSD 222943435Scael.Sh SEE ALSO 223048888Scael.Xr mdoc 7 , 223143435Scael.Xr man 1 , 223243435Scael.Xr troff 1 223343435Scael.Sh BUGS 223443435ScaelUndesirable hyphenation on the dash of a flag 223543435Scaelargument is not yet resolved, and causes 223643435Scaeloccasional mishaps in the DESCRIPTION section. 223748888Scael(line break on the hyphen). 223843435Scael.Pp 223943435ScaelPredefined strings are not declared in documentation. 224043435Scael.Pp 224143435ScaelSection 3f has not been added to the header routines. 224243435Scael.Pp 224348888Scael.Ql \&.Nm 224443435Scaelfont should be changed in NAME section. 224543435Scael.Pp 224648888Scael.Ql \&.Fn 224743435Scaelneeds to have a check to prevent splitting up 224843435Scaelif the line length is too short. Right now it 224943435Scaelseparates the last parenthesis, and sometimes 225043435Scaellooks ridiculous if a line is in fill mode. 225143435Scael.Pp 225243435ScaelThe method used to prevent header and footer page 225343435Scaelbreaks (other than the initial header and footer) when using 225443435Scaelnroff seems to be putting out a partially filled line 225543435Scaelat the bottom of the page leaving an unsightly blank space. 225643435Scael.Pp 225748888ScaelThe list and display macros to not do any keeps 225843435Scaeland certainly should be able to. 2259