1 .\" @(#)e.tmac 2.31 (Berkeley) 5/21/88
2 .\" Modified by James Clark for use with groff.
3 .\" Adapted to S-roff by Steffen (Daode) Nurpmeso <steffen@sdaoden.eu>.
5 .\" Copyright (c) 1988 Regents of the University of California.
6 .\" All rights reserved.
8 .\" Redistribution and use in source and binary forms are permitted
9 .\" provided that this notice is preserved and that due credit is given
10 .\" to the University of California at Berkeley. The name of the University
11 .\" may not be used to endorse or promote products derived from this
12 .\" software without specific prior written permission. This software
13 .\" is provided ``as is'' without express or implied warranty.
16 .\"**********************************************************************
18 .\"* ****** - M E N R O F F / T R O F F M A C R O S ****** *
20 .\"* Produced for your edification and enjoyment by: *
22 .\"* Electronics Research Laboratory *
24 .\"* current address: *
25 .\"* Britton-Lee, Inc. *
26 .\"* 1919 Addison Street Suite 105 *
27 .\"* Berkeley, California 94704 *
29 .\"* VERSION 2.31 First Release: 11 Sept 1978 *
31 .\"* Documentation is available. *
33 .\"**********************************************************************
35 .\" Code on .de commands:
36 .\" *** a user interface macro.
37 .\" &&& a user interface macro which is redefined
38 .\" when used to be the real thing.
39 .\" $$$ a macro which may be redefined by the user
40 .\" to provide variant functions.
41 .\" --- an internal macro.
51 .de @R \" --- initialize number register to 0, if undefined
55 .\" --- check whether grohtml needs end of title/heading
56 .de @html_check_need_title
57 .do if (\\n[need_eo_tl] == 1) \
62 .do if (\\n[need_tl] == 1) \
68 .do if \\n[need_eo_h]>0 .do DEVTAG-EO-H
76 . do als check_need_title @html_check_need_title
78 . do als check_need_title @check_need_title
84 .de @S \" --- initialize string/macro to empty, if undefined
85 .if !d\\$1 .ds \\$1 \" empty
88 .@R @\" \" debugging level
91 .\" *** INTERNAL GP MACROS ***
94 .de @C \" --- change ev's, taking info with us
119 .de @D \" --- determine display type (Indent, Left, Center)
138 .de @z \" --- end macro
139 .if \n@>1 .tm >> @z, .z=\\n(.z ?a=\\n(?a
142 . tm Line \\n(c. -- Unclosed block, footnote, or other diversion (\\n(.z)
147 . bp \" force out final table
149 .ds @b\" \" don't start another page
155 .\" *** STANDARD HEADERS AND FOOTERS ***
158 .ie \n(.g .ds $* \\\\$*
159 .el .ds $* \\\\$1 \\\\$2 \\\\$3 \\\\$4 \\\\$5 \\\\$6 \\\\$7 \\\\$8 \\\\$9
161 .de he \" *** define header
174 .de eh \" *** define even header
181 .de oh \" *** define odd header
188 .de fo \" *** define footer
201 .de ef \" *** define even foot
208 .de of \" *** define odd footer
215 .de ep \" *** end page (must always be followed by a .bp)
225 .\" *** INTERNAL HEADER AND FOOTER MACROS ***
229 .if \n@>1 .tm >> @h %=\\n% ?a=\\n(?a ?b=\\n(?b ?w=\\n(?w
230 .if (\\n(.i+\\n(.o)>=\\n(.l \
231 . tm Line \\n(c. -- Offset + indent exceeds line length
232 .\" initialize a pile of junk
233 .nr ?h \\n(?H \" transfer "next page" to "this page"
241 .nr _w 0 \" reset max footnote width
242 .nr ?W 0 \" no wide floats this page (yet)
244 .\" begin actual header stuff
249 . sp |\\n(hmu \" move to header position
250 .@t $h\" \" output header title
254 . sp |\\n(tmu \" move to top of text
256 .mk _k \" for columned output
257 .if \\n(?n=1 .nm 1 \" restore line numbering if n1 mode
258 .nr $c 1 \" set first column
259 .if \n@>4 .tm -- @h >> .ns nl=\\n(nl %=\\n% _k=\\n(_k tm=\\n(tm
267 . @n\" \" begin the column
271 .de @n \" --- new column or page
272 .if \n@>3 .tm >> @n nl=\\n(nl %=\\n% ?f=\\n(?f ?o=\\n(?o
275 .if (\\n(_w<=\\n($l)&(\\n(?W=0) \
277 . nr _b (\\n(ppp*\\n($vu)/200u \" compute fudge factor (must be < 1P)
278 . if \\n(_bu>((\\n(bmu-\\n(fmu-((\\n(tpp*\\n($vu)/100u))/2u) \
279 . nr _b (\\n(ppp*\\n($vu)/100u-\n(.Vu
285 .nr _b +(\\n(ppp*\\n($vu)/100u \" add 1 paragraph v in case of sweep past
286 .if \n@>2 .tm @n .p=\\n(.p bm=\\n(bm _b=\\n(_b _B=\\n(_B
287 .nr ?f 0 \" reset footnote flag
290 . (f _\" \" reprocess footnotes which run off page
304 . |h\" \" output the table header
309 . mk #T \" for tbl commands
312 .if (\\n(?a)&((\\n($c<2):(\\n(?w=0)) \
314 . nr ?a 0 \" output floating keep
317 . mk _k \" don't overstrike wide keeps
321 .$H\" \" special column header macro
326 .if \n@>1 .tm >> @f %=\\n% nl=\\n(nl ?a=\\n(?a ?b=\\n(?b ?f=\\n(?f
327 .if \n@>2 .nr VL \\n(.pu-\\n(nlu
328 .if \n@>2 .tm @f bm=\\n(bm _B=\\n(_B _b=\\n(_b .p-nl=\\n(VL
332 . nr T. 1 \" for tbl commands (to output bottom line)
333 . T# 1\" \" output the sides and bottom lines
341 . @k |b\" \" output bottom of page tables
344 . @o\" \" output footnote if present
346 . @c\" \" handle new column
353 .de @o \" --- output footnote
357 .if \n@>2 .tm @o last printed text = \\n(nl placing @r trap at -\\n(_B
365 .if \n@>2 .tm @o triggered @r (?o) = \\n(?o
368 . di \" just in case triggered @r
381 .de @c \" --- new column
382 .if \n@>2 .tm >> @c %=\\n%
390 .de @e \" --- end page
394 .sp |\\n(.pu-\\n(fmu-((\\n(tpp*\\n($vu)/100u) \" move to footer position
395 .@t $f\" \" output footer title
400 .de @t \" --- output header or footer title
403 . sz \\n(tp\" \" set header/footer type fonts, etc.
405 . lt \\n(_Lu \" make title span entire page
416 .de $h \" $$$ print header
420 . if e .ds |z "\\*(|0
421 . if o .ds |z "\\*(|1
423 .if !\(ts\\*(|z\(ts\(ts \
428 .de $f \" $$$ print footer
432 . if e .ds |z "\\*(|0
433 . if o .ds |z "\\*(|1
435 .if \(ts\\*(|z\(ts\(ts \
437 . if e .ds |z "\\*(|2
438 . if o .ds |z "\\*(|3
440 .if !\(ts\\*(|z\(ts\(ts \
445 .de @r \" --- reprocess overflow footnotes
446 .if \n@>3 .tm >> @r .z=\\n(.z ?f=\\n(?f ?a=\\n(?a ?b=\\n(?b _b=\\n(_b
447 .di |o \" save overflow footnote
454 .\" *** COMMANDS WITH VARIANT DEFINITIONS ***
457 .if !'\*(.T'html' .rn bp @b \" --- begin page
459 .de bp \" *** begin new page (overrides columns)
460 .nr $c \\n($m \" force new page, not new column
468 . @h\" \" 'spring' the header trap
471 .wh 0 @h \" reset header
474 .rn ll xl \" *** special line length (local)
475 .de ll \" *** line length (global to environments)
479 .if (\\n($m<=1):(\\n($l>\\n(_L) \
483 .rn po @O \" --- local page offset
485 .de po \" *** page offset
490 .\" Redefine the fam request to set the family in
491 .\" environment 2 as well as the current environment.
493 .do rn fam @fam \" --- set family in current environment
494 .do de fam \" *** set font family in ev 2 and current ev
502 .\" *** MISCELLANEOUS ROFF COMMANDS ***
505 .de hx \" *** suppress headers and footers next page
509 .de ix \" *** indent, no break
513 .de bl \" *** contiguous blank lines
519 .de @s \" --- diversion-surviving space test
522 .if !'\\n(.z'' \!.@s \\$1
525 .de n1 \" *** line numbering 1
531 .de n2 \" *** line numbering 2
542 . do substring |i 0 0 \" pick off leading char and rest to check
543 . do substring |j 1 \" for +N / -N
545 . nr ln (\\n[_ln])+\\*(|j
548 . nr ln (\\n[_ln])-\\*(|j
550 . nr ln \\$1 \" unsigned N
556 . tm Line \\n(.c -- Bad .n2 value
569 .de pa \" *** new page
573 .de ro \" *** roman page numbers
577 .de ar \" *** arabic page numbers
581 .de m1 \" *** position one space
584 .nr tm +\\n(hmu-\\n(_0u
588 .de m2 \" *** position two space
589 .nr tm \\n(hmu+\\n(tpp+\\$1v
592 .de m3 \" *** position three space
593 .nr bm \\n(fmu+\\n(tpp+\\$1v
596 .de m4 \" *** position four space
599 .nr bm +\\n(fmu-\\n(_0u
602 .de sk \" *** leave a blank page (next page)
604 . tm Line \\n(c. -- I cannot skip multiple pages
609 .\" *** MISCELLANEOUS USER SUPPORT COMMANDS ***
613 .de re \" *** reset tabs (TROFF defines 15 stops default)
619 .ta 0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i +0.5i
622 .de ba \" *** set base indent
626 . nr $i \\n(siu*\\n($0u
629 .de hl \" *** draw horizontal line
636 .ie \n(.g .do nr _I \\n[.in]
643 .\" *** PARAGRAPHING ***
646 .de pp \" *** paragraph
650 .de lp \" *** left aligned paragraph
657 .de ip \" *** indented paragraph w/ optional tag
658 .if (\\n(ii>0)&(\\n(ii<1n) \
675 . ie \\w"\\*(|j">=\\n(_0 \
679 . do DEVTAG-COL-NEXT 2
694 .de np \" *** numbered paragraph
695 .\" use string comparison in case user has changed format of $p
697 . nr $p 0 \" reset number after .bu
698 .nr $p +1 \" increment paragraph number
701 \0(\\n($p)\h'|\w'\0(000)\0'u'\c
704 .de bu \" *** bulleted paragraph
706 .\" use string comparison in case user has changed format of $p
708 . ns \" don't space between .bu paragraphs
709 .nr $p 0-1 \" mark "bulleted paragraph" mode
715 .de @p \" --- initialize for paragraph
717 .if "\\n(.z"|e" .tm Line \\n(c. -- Unmatched continued equation
731 .\" *** SECTION HEADINGS ***
734 .de sh \" *** section heading
737 .if (\\n(si>0)&(\\n(si<1n) \
739 .if '\*(.T'html' .nr si 0
746 .@d "\\$1" +1 \\$3 \\$4 \\$5 \\$6 \\$7 \\$8
750 . $p "\\*(|n" "\\*($n" \\n($0
751 . $0 "\\*(|n" "\\*($n" \\n($0
754 .nr $p 0 1 \" reset .np count
757 .de @d \" --- change section depth
760 .if \\n($0&(\\n(.$>1) \
767 . if (\\n(.$>=3) .if !"\\$3"-" \
777 . if (\\n(.$>=4) .if !"\\$4"-" \
787 . if (\\n(.$>=5) .if !"\\$5"-" \
797 . if (\\n(.$>=6) .if !"\\$6"-" \
807 . if (\\n(.$>=7) .if !"\\$7"-" \
817 . if (\\n(.$>=8) .if !"\\$8"-" \
825 .de sx \" *** heading up, no increment (2.1.1 -> 2.1)
830 .if \\n(.$ .nr _0 \\$1
834 .nr $p 0 1 \" reset .np count
837 .de uh \" *** unnumbered section heading
842 .de $p \" $$$ print section heading
843 .if (\\n(si>0)&(\\n(.$>2) \
848 . sp \\n(ssu \" one of them is non-null
849 . ne \\n(.Lv+\\n(.Vu+\\n(psu+((\\n(spp*\\n($vu*\\n(.Lu)/100u)
850 . \" exdent if \\$3 > 0
852 . ti -(\\n(siu-\\n(sou)
859 . if \w"\\$2">0 \\$2.
860 . if \w"\\$1">0 \\$1\f1\ \ \&
869 .\" *** COLUMNED OUTPUT ***
872 .de 2c \" *** double columned output
875 . 1c\" \" revert to 1c if already 2c
881 . nr $s \\$1n \" param 1: column separation
882 .nr $l (\\n(.l-((\\n($m-1)*\\n($s))/\\n($m
888 .de 1c \" *** single columned output
892 .ll \\n(_Lu \" return to normal output
897 .de bc \" *** begin column
902 .\" *** FLOATING TABLES AND NONFLOATING BLOCKS ***
905 .de (z \" *** begin floating keep
906 .if \n@>4 .tm >> (z, .z=\n(.z
911 .de )z \" *** end floating keep
912 .if \n@>4 .tm >> )z, .z=\n(.z
915 .if \n@>4 .tm -- )z << @), .z=\n(.z
918 . nr dn +(\\n(ppp*\\n($vu)/200u+\\n(zsu
919 .nr dl -\n(.H \" fudge factor necessary to make it work
920 .ie ((\\n(dn+\n(.V)>=\\n(.t):(\\n(?a):((\\n(dl>\\n($l)&(\\n($c>1)) \
923 . if (\\n(dl>\\n($l)&(\\n($m>1) \
924 . nr ?w 1 \" mark wider than one column (top)
930 . if (\\n(dl>\\n($l)&(\\n($m>1) \
931 . nr ?W 1 \" mark wider than one column (bottom)
933 . \" avoid moving @f back past the current position
934 . if \\n(.p-\\n(nl-\n(.V<\\n(_b \
935 . nr _b \\n(.p-\\n(nl-\n(.V
939 .da \\*(|x \" copy to save macro
943 .if \n@>4 .tm -- )z >> \\*(|x
944 \!.if \\\\n(nl>(\\\\n(tm+2v) .ne \\n(dnu-\\n(zsu
945 .|k\" \" and the body
947 .if \n@>4 .tm -- )z << \\*(|x, .z=\\n(.z
949 .rm |k\" \" remove the temp macro
955 .if \n@>4 .tm << )z, .z=\\n(.z
958 .de @k \" --- output floating keep
959 .if \n@>4 .tm >> @k, $1=\\$1, .z=\\n(.z
976 .de (t \" XXX temp ref to (z
980 .de )t \" XXX temp ref to )t
984 .de (b \" *** begin block
989 .if '\*(.T'html' .sp \\n(bsu
992 .de )b \" *** end block
995 .if (\\n(bt=0):(\\n(.t<\\n(bt) \
996 . ne \\n(dnu \" make it all on one page
998 .ev \" return from display environment
999 .sp \\n(bsu+\\n(.Lv-1v
1002 .de @( \" --- begin keep
1003 .if !"\\n(.z"" .tm Line \\n(c. -- Invalid nested keep \\n(.z
1009 .de @M \" --- set modes for display
1014 .vs \\n(.sp*\\n($Vu/100u
1017 . fi \" set fill mode if "F" parameter
1029 .de @) \" --- end keep
1031 .if !"\\n(.z"|k" .tm Line \\n(c. -- Close of a keep which has never been opened
1038 .de (c \" *** begin block centered text
1040 .if "\\n(.z"|c" .tm Line \\n(c. -- Nested .(c requests
1045 .de )c \" *** end block centered text
1046 .if !"\\n(.z"|c" .tm Line \\n(c. -- Unmatched .)c
1047 .br \" force out final line
1049 .if \n@>4 .tm >> .)c .l=\\n(.l .i=\\n(.i $i=\\n($i dl=\\n(dl
1052 .in (\\n(.lu-\\n(.iu-\\n(dlu)/2u
1053 .if \n@>4 .tm -- .)c << .in .l=\\n(.l .i=\\n(.i dl=\\n(dl
1068 .\" *** BLOCK QUOTES (OR WHATEVER) AND LISTS ***
1071 .de (q \" *** begin block quote
1083 .de )q \" *** end block quote
1088 .sp \\n(qsu+\\n(.Lv-1v
1092 .de (l \" *** begin list
1099 .if '\*(.T'html' .sp \\n(bsu
1102 .de )l \" *** end list
1107 .sp \\n(bsu+\\n(.Lv-1v
1112 .\" *** PREPROCESSOR SUPPORT ***
1118 .de EQ \" *** equation start
1119 .do if \\n[need_eo_h]>0 .do DEVTAG-EO-H
1124 . do nr e-EQ-ll \\n(.l
1130 . if "\\n(.z"|e" .tm Line \\n(c. -- Nested .EQ request
1131 . @D 1 "\\$1" "\\$2"
1140 .de EN \" *** equation end
1144 . do ll \\n[e-EQ-ll]u
1155 . @q\" \" actual equation output
1161 .de @q \" --- equation output
1164 .sp \\n(esu \" output rest of preceding text
1165 .if !"\\n(.z"" \!.ne \\n(_Qu
1166 .ne \\n(_Qu+\n(.Vu \" keep it on one page
1167 .@C 2\" \" .ev 2 may be jumbled from header
1169 . in (\\n(.lu+\\n($iu-\\n(dlu)/2u
1173 . in \\n(biu+\\n($iu
1177 .if \n@>1 .tm --@e: _Q=\\n(_Q _q=\\n(_q nl=\\n(nl |p=\\*(|p
1181 . sp (\\n(_Qu-\\n(.vu)/2u
1190 .sp |\\n(_qu+\\n(_Qu
1191 .sp \\n(esu+\\n(.Lv-1v
1199 .de TS \" *** table start
1203 . do nr e-TS-ll \\n(.l
1208 .fi \" drop into fill mode for text boxes
1211 . di |h \" save header part
1215 .ch @f -(\\n(_bu+1v) \" set pseudo-trap for bottom line
1216 .if \\n(.p-\\n(_b-1v<=\\n(nl \
1217 . ch @f \\n(nlu+\n(.Vu
1220 .de TH \" *** end header part of table
1230 .if \\n(?n .nm \\n(ln
1232 .|h\" \" put in the initial header
1238 .de TE \" *** table end
1240 .ch @f -\\n(_bu \" reset pseudo-trap
1241 .if \\n(.p-\\n(_b<=\\n(nl \
1242 . ch @f \\n(nlu+\n(.Vu
1246 . do ll \\n[e-TS-ll]u
1247 .sp \\n(bsu+\\n(.Lv-1v
1262 .de IS \" *** start ideal picture
1272 .de IE \" *** end ideal picture
1280 .de PS \" *** start picture: $1=height, $2=width in units or inches
1284 .in (u;\\n(.l-\\n(g7>?0/2)
1290 . de PS_nm_check && \" define macro to emit .nm at top diversion
1291 . if \n@>4 .tm -- PS: \\\\$1 \\\\$2 .z=\\\\n(.z PS_nm_cnt=\\\\n[PS_nm_cnt]
1292 . \" \" multiple .PS/.PE in a keep.
1293 . if `\\\\$2`init` \
1294 . do nr PS_nm_cnt \\\\n[PS_nm_cnt]+1
1297 . if `\\\\$1`suspend` \
1299 . if `\\\\$1`resume` \
1302 . do nr PS_nm_cnt \\\\n[PS_nm_cnt]-1
1303 . do if !\\\\n[PS_nm_cnt] \
1310 .el \!.PS_nm_check \\\\$1
1312 . mk _q \" emit a single numbered line for PS picture
1317 . PS_nm_check suspend init
1321 .de PE \" *** end picture
1322 .if \\n(?n .PS_nm_check resume
1333 .de GS \" *** start gremlin picture
1336 . ie "\\$1"L" .do HTML-IMAGE-LEFT
1337 . el .ie "\\$1"R" .do HTML-IMAGE-RIGHT
1342 . nr g7 (\\n(.lu-\\n(g1u)/2u
1343 . if "\\$1"L" .nr g7 \\n(.iu
1344 . if "\\$1"R" .nr g7 \\n(.lu-\\n(g1u
1353 .de GE \" *** end gremlin picture
1354 .ie '\*(.T'html' .do HTML-IMAGE-END
1362 .de GF \" *** finish gremlin picture; stay at top
1369 .\" *** FONT AIDS ***
1372 .de sz \" *** set point size and vertical spacing
1375 .vs \\n(.sp*\\n($vu/100u \" default vs at pointsize + 20%
1378 .de @v \" --- possibly set $v from $r
1379 .if (1i>=240u)&(1p<=\\n($r)&(\\n($r<=4p) .nr $v \\n($r00/1p
1382 .de @V \" --- possibly set $V from $R
1383 .if (1i>=240u)&(1p<=\\n($R)&(\\n($R<=4p) .nr $V \\n($R00/1p
1386 .de @E \" --- store in _F argument to \f for restoring font
1391 . ie \\n(.f<100&\n(.g \
1398 .de r \" *** enter roman font
1399 .do check_need_title
1402 .if \\n(.$ \&\\$1\f\\*(_F\\$2
1403 .do check_need_title
1406 .de i \" *** enter italic
1407 .do check_need_title
1410 .if \\n(.$ \&\\$1\f\\*(_F\\$2
1411 .do check_need_title
1414 .de b \" *** enter boldface
1415 .do check_need_title
1418 .if \\n(.$ \&\\$1\f\\*(_F\\$2
1419 .do check_need_title
1422 .de rb \" *** enter real boldface
1423 .do check_need_title
1426 .if \\n(.$ \&\\$1\f\\*(_F\\$2
1427 .do check_need_title
1430 .de bi \" *** enter bold italic
1431 .do check_need_title
1434 .if \\n(.$ \&\\$1\f\\*(_F\\$2
1435 .do check_need_title
1438 .de u \" *** enter underlined word
1439 \&\\$1\l'|0\(ul'\\$2
1442 .\" a better version of u
1445 \Z'\\$1'\v'.25m'\D'l \w'\\$1'u 0'\v'-.25m'\\$2
1448 .de q \" *** enter quoted word
1449 \&\\*(lq\\$1\\*(rq\\$2
1452 .de bx \" *** enter boxed word
1453 .ie '\*(.T'html' \\$1\\$2
1454 .el \k~\(br\|\\$1\|\(br\l'|\\n~u\(rn'\l'|\\n~u\(ul'\^\\$2
1457 .de sm \" *** print in smaller font
1461 .de @F \" --- change font (0 -> no change)
1469 .\" *** FOOTNOTING ***
1472 .de (f \" *** begin footnote
1474 .if "\\n(.z"|f" .tm Line \\n(c. -- Invalid footnote nesting
1483 . xl \\n($lu-\\n(fuu
1486 . vs \\n(.sp*\\n($Vu/100u
1489 . nr _b +1v \" allow space for $s
1493 . if \\n(.p-\\n(_b-\\n(_0-\\n(.h-1v-\\n(fs<0 \
1495 . da\" \" won't fit on page at all
1500 .\" next five lines could be dropped if headers had their own environment
1501 . in 0 \" reset everything from .bc
1502 . xl \\n($lu-\\n(fuu
1505 . vs \\n(.sp*\\n($Vu/100u
1516 . if \n@>2 .tm << (f $f=\\n($f
1523 . xl \\n($lu-\\n(fuu
1526 . vs \\n(.sp*\\n($Vu/100u
1533 .de @N \" --- set no fill mode in the top-level diversion
1538 .de )f \" *** end footnote
1543 . ds * \\*{\\n($f\\*}\k*
1548 . if \\n(_w<\\n(dl \
1549 . nr _w \\n(dl \" compute maximum fn width
1552 . if \\n(.p-\\n(_b<=\\n(nl \
1553 . ch @f \\n(nlu+\n(.Vu
1567 . nr ff 1 \" footnote font: Times Roman
1570 . nr fp 8 \" footnote pointsize
1572 .de $s \" $$$ footnote separator
1577 .\" *** DELAYED TEXT ***
1580 .de (d \" *** begin delayed text
1585 .de )d \" *** end delayed text
1592 .de pd \" *** print delayed text
1600 .\" *** INDEXES (TABLE OF CONTENTS) ***
1607 .de (x \" *** begin index entry
1608 .if \n@>4 .tm >> (x, .z=\\n(.z
1619 .de @0 \" --- finish (x if no current diversion
1625 .de @1 \" --- finish (x if current diversion
1626 .if "\\n(_x"z" .nr _x 0
1630 .de )x \" *** end index entry
1631 .if \n@>4 .tm >> )x, .z=\\n(.z
1640 . if \w"\\$2">(\\n(.l-\\n(.i-\\n(.k) \
1642 \\\\a\\\\t\\$2\\*(|x
1656 .de xp \" *** print the index
1660 .vs \\n(.sp*\\n($Vu/100u
1666 .xl -(\\n(xuu+\w'...'u)
1677 .ta \\n(.lu-\\n(xuuR \\n(.luR
1685 .\" *** HTML VERSIONS OF .x(, .x), AND .xp ***
1688 .de (x-html \" --- create TAG and divert text
1697 .de )x-html \" --- end diversion
1702 .de xp-html \" --- create list of links
1708 .do while \\n[_xx]<=\\n[_xn] \
1711 . do unformat |x\\n[_xx]
1719 . do asciify xp-html-div
1721 . do as xp-html-as #
1722 . do as xp-html-as _x\\n[_xx]
1725 . do URL \\*[xp-html-as] "\\*[xp-html-div]
1745 .\" *** CHAPTERS AND TITLES ***
1748 .de +c \" *** begin chapter
1749 .ep\" \" force out footnotes
1752 . bp \" force out a table or more footnote
1762 .in \\n($iu \" reset the indent
1770 .de ++ \" *** declare chapter type
1773 . nr _0 1 \" chapter
1775 . nr _0 11 \" renumbered chapter
1777 . nr _0 2 \" appendix
1779 . nr _0 12 \" renumbered appendix
1781 . nr _0 3 \" preliminary material
1783 . nr _0 4 \" bibliographic material
1785 . nr _0 5 \" abstract
1787 . tm Line \\n(c. -- Bad mode to .++
1795 .if (\\n(_0=3):(\\n(_0=5) \
1796 . pn 1 \" must do before .ep
1797 .if !\\n(_0=\\n(_M .if \\n(_M=3 \
1798 . pn 1 \" must do before .ep
1799 .ep\" \" end page for correct page number types
1822 .de $c \" $$$ print chapter title
1828 .ie \\n(_M=1 CHAPTER\ \ \\n(ch
1829 .el .if \\n(_M=2 APPENDIX\ \ \\n(ch
1830 .if \w"\\$1" .sp 3-\\n(.L
1832 .if (\\n(_M<3):(\w"\\$1") \
1838 . $C Chapter \\n(ch "\\$1"
1840 . $C Appendix \\n(ch "\\$1"
1843 .de tp \" *** title page
1852 .if \n(mo=1 .ds mo January
1853 .if \n(mo=2 .ds mo February
1854 .if \n(mo=3 .ds mo March
1855 .if \n(mo=4 .ds mo April
1856 .if \n(mo=5 .ds mo May
1857 .if \n(mo=6 .ds mo June
1858 .if \n(mo=7 .ds mo July
1859 .if \n(mo=8 .ds mo August
1860 .if \n(mo=9 .ds mo September
1861 .if \n(mo=10 .ds mo October
1862 .if \n(mo=11 .ds mo November
1863 .if \n(mo=12 .ds mo December
1864 .if \n(dw=1 .ds dw Sunday
1865 .if \n(dw=2 .ds dw Monday
1866 .if \n(dw=3 .ds dw Tuesday
1867 .if \n(dw=4 .ds dw Wednesday
1868 .if \n(dw=5 .ds dw Thursday
1869 .if \n(dw=6 .ds dw Friday
1870 .if \n(dw=7 .ds dw Saturday
1874 .ds td \*(mo \n(dy, \n(y4
1877 .\" *** PARAMETRIC INITIALIZATIONS ***
1881 .nr $v \n(.v00+\n(.sp-1/\n(.sp \" vs as percentage of ps for .sz request
1882 .nr $V \n($v \" same for displays & footnotes
1883 .nr hm 4v \" header margin
1884 .nr tm 7v \" top margin
1885 .nr bm 6v \" bottom margin
1886 .nr fm 3v \" footer margin
1887 .nr tf 3 \" title font: (real) Times Bold
1888 .nr tp 10 \" title point size
1890 .nr bi 4m \" indent for blocks
1891 .nr pi 5n \" indent for paragraphs
1892 .nr pf 1 \" normal text font
1893 .nr pp 10 \" normal text point size
1894 .nr qi 4n \" indent for quotes
1895 .nr qp -1 \" down one point
1896 .nr ii 5n \" indent for .ip's and .np's
1897 .nr $m 1 \" max number of columns
1898 .nr $s 4n \" column separation
1899 .nr sf 3 \" section font -- Times Bold
1900 .nr sp 10 \" section title pointsize
1901 .nr ss 12p \" section prespacing
1902 .nr si 0 \" section indent
1905 .\" *** OTHER INITIALIZATION ***
1908 .\" GNU pic sets this register to 1, to indicate that \x should not be used.
1910 .ds { \v'-0.4m'\x'\\n(0x=0*-0.2m'\s-3
1912 .\" for compatibility with traditional -me
1913 .\" (the first will work only in compatibility mode)
1916 .ds < \v'0.4m'\x'\\n(0x=0*0.2m'\s-3
1919 .\" Avoid warnings from groff -ww.
1937 .@R po\" \" simulated page offset
1938 .@R $0\" \" section depth
1939 .@R $i\" \" paragraph base indent
1940 .@R $p\" \" numbered paragraph number
1941 .@R $r\" \" ratio of vs to ps (may override $v)
1942 .@R $R\" \" same for displays (may override $V)
1943 .@R df\" \" display font: same as surrounding text
1944 .@R so\" \" additional section title offset
1945 .@R fu\" \" footnote undent
1946 .@R bt\" \" block keep threshold
1947 .@R *\" \" has \** been referenced?
1948 .@R ?a\" \" pending floating keep at page top?
1949 .@R ?b\" \" pending floating keep at page bottom?
1950 .@R ?C\" \" at chapter header?
1951 .@R ?e\" \" in equation?
1952 .@R ?H\" \" suppress headers and footers next page?
1953 .@R ?I\" \" has the header trap been sprung?
1954 .@R ?n\" \" n1 mode?
1955 .@R ?o\" \" footnote overflow?
1956 .@R ?R\" \" renumbered chapter?
1957 .@R ?s\" \" skip next page?
1958 .@R ?T\" \" inside .TS H?
1959 .@R ?W\" \" wide floating keep at page bottom?
1960 .@R ?w\" \" wide floating keep at page top?
1966 .if \n(ps<\n(.V .nr ps \n(.V
1967 .nr bs \n(ps \" block pre/post spacing
1968 .nr qs \n(ps \" quote pre/post spacing
1969 .nr zs 1v \" float-block pre/postspacing
1970 .nr xs 0.2v \" index prespacing
1971 .nr xu 0.5i \" index undent
1972 .nr fs 0.2v \" footnote prespacing
1973 .nr es 0.5v \" equation pre/postspacing
1974 .if \n(es<\n(.V .nr es \n(.V
1975 .wh 0 @h \" set header
1976 .nr $l \n(.lu \" line length
1977 .nr _L \n(.lu \" line length of page
1978 .nr $c 1 \" current column number
1979 .nr $f 1 1 \" footnote number
1980 .ds * \*{1\*}\k*\" \" footnote "name"
1981 .nr $d 1 1 \" delayed text number
1982 .ds # [1]\k#\" \" delayed text "name"
1983 .nr _M 1 \" chapter mode is chapter
1984 .ds lq \(lq\" \" left quote
1985 .ds rq \(rq\" \" right quote
1989 .\" *** FOREIGN LETTERS AND SPECIAL CHARACTERS ***
1992 .ds #h ((1u-(\\\\n(.fu%2u))*0.13m)
1996 .ds ' \k_\h'-(\\n(.wu*8/10-\*(#h)'\(aa\h'|\\n_u'
1997 .ds ` \k_\h'-(\\n(.wu*7/10-\*(#h)'\(ga\h'|\\n_u'
2000 .ds : \k_\h'-(\\n(.wu*8/10-\*(#h+0.1m)'\v'-\*(#v'\z.\h'0.2m'.\h'|\\n_u'\v'\*(#v'
2002 .\" \" circumflex and tilde
2003 .ds ^ \k_\h'-(\\n(.wu-\*(#h-0.05m)'^\h'|\\n_u'
2004 .ds ~ \k_\h'-(\\n(.wu-\*(#h-0.05m)'~\h'|\\n_u'
2006 .\" \" cedilla and czech
2007 .ds , \k_\h'-(\\n(.wu)',\h'|\\n_u'
2008 .ds v \k_\h'-(\\n(.wu*9/10-\*(#h)'\v'-\*(#v'\s-4v\s0\v'\*(#v'\h'|\\n_u'
2010 .\" \" Norwegian A or angstrom
2011 .ds o \k_\h'-(\\n(.wu+\w'\(de'u-\*(#h)/2u'\v'-0.4n'\z\(de\v'0.4n'\h'|\\n_u'
2013 .\" \" there exists, for all
2014 .ds qe \s-2\v'0.45m'\z\(em\v'-0.625m'\z\(em\v'-0.625m'\(em\v'0.8m'\s0\h'-0.1m'\v'-0.05m'\(br\v'0.05m'\h'0.1m'
2015 .ds qa \z\e\h'0.35m'\z\(sl\h'-0.33m'\v'-0.3m'\s-4\(em\s0\v'0.3m'\h'0.15m'
2021 .tm The \\$1 macro has been removed from this version of the -me macros.