aboutsummaryrefslogtreecommitdiff
path: root/g.tmac
blob: 7bc0a2403194978693c2cb0fdea6054636010d2e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
.\"                                          "/.
.\"        mg macro package for troff        "/.
.\"        created by John Ankarström        "/.
.\"                                          "/.
.\" Permission to use, copy, modify and/or   "/.
.\" distribute this software for any purpose "/.
.\" with or without fee is hereby granted.   "/.
.\"                                          "/.
.\" For a summary of the macros defined in   "/.
.\" this file, issue `grep -- -- g.tmac'.    "/.
.
.eo \" disable backslash escapes
.
.\" Internal macros
.\" ---------------
.
.\" _s -- setup document
.de _s
.
. \" configure initial options
. _nr mt 1i \" margin top
. _nr mb 1i \" margin bottom
. _ds cfam C \" inline constant-width font family
. _ds cps -1p \" inline constant-width font size
.
. \" initialize document
. wh 0 _h
. wh -\n(mbu _f
. sp 1u \" trigger header
. ns
.
. \" configure environments
. t \" title
.  evc 0
.  ps +4p
.  vs +2p
.  ft B
.  ad c
. n \" name (of author)
.  evc 0
.  nr sp 0.4v
.  ad c
. d \" date
.  evc 0
.  nr sp 0.4v
.  ad c
. h \" heading
.  evc 0
.  nr sp 0.6v
.  ps +1p
.  ft B
. s \" section heading
.  evc 0
.  nr sp 0.6v
.  ft B
. p \" paragraph
.  evc 0
.  nr sp 0.3v
.  nr ti 0.5c
.  ad b
. l \" literal display
.  evc 0
.  nr sp 0.3v
.  nf
.  in 0.5c
.  fam C
.  ps -1p
.  vs -1p
. q \" quotation
.  evc 0
.  nr sp 0.3v
.  nr ti 1c
.  in 0.5c
.  ps -1p
.  vs -1p
. _e
..
.
.\" _h -- page header
.de _h
' sp \n(mtu
..
.
.\" _f -- page footer
.de _f
' sp 1v
. tl ''%''
' bp
..
.
.\" _nr -- set default numeric value
.de _nr
. if \n[\$1]=0 .nr \$1 \$2
..
.
.\" _ds -- set default string value
.de _ds
. if '\*[\$1]'' .ds \$1 \$2
..
.
.\" _e -- set environment
.de _e
.
. \" initialize document?
. if '\n(_s'0' \{\
.  nr _s 1
.  _s
. \}
.
. br
.
. \" save special environment variables
. if !'\n[.ev]'0' \{\
.  nr \n[.ev]_sp \n(sp
.  nr \n[.ev]_ti \n(ti
.  ev
. \}
.
. \" keep track of previous and new environment
. ds penv \*[env]
. ds env \$1
.
. \" activate new environment
. if !'\$1'' \{\
.  ev \$1
.  nr sp \n[\n[.ev]_sp]
.  nr ti \n[\n[.ev]_ti]
.  sp \n(spu
. \}
.
. \" perform post-environment operations
. _pe
..
.
.\" _pe -- post-environment operations
.de _pe
.
. \" add small space after title
. if '\*[penv]'t' \{\
.  if '\*[env]'n' .sp 0.1v
.  if '\*[env]'d' .sp 0.1v
. \}
.
. \" add space after title/name/date
. if '\*[env]'n' .return
. if '\*[env]'d' .return
. ie '\*[penv]'t' .sp 1v
. el .ie '\*[penv]'n' .sp 1v
. el .if '\*[penv]'d' .sp 1v
..
.
.
.\" Inline macros
.\" -------------
.
.\" b -- bold font
.de b
\$3\fB\$1\fP\$2
..
.
.\" i -- italic font
.de i
\$3\fI\$1\fP\$2
..
.
.\" x -- bold italic font
.de x
\$3\f(BI\$1\fP\$2
..
.
.\" c -- constant-width font
.de c
\$3\c
. fam \*[cfam]
. ps \*[cps]
\$1\c
. fam
. ps
\$2
..
.
.
.\" Hybrid macros
.\" -------------
.
.\" q -- quotation
.de q
.
. \" inline quotation
. ie !'\$1'' \$3\(lq\$1\(rq\$2
.
. \" block quotation
. el \{\
.  _e q
.  ti \n(tiu
. \}
..
.
.
.\" Environment macros
.\" ------------------
.
.\" t -- title
.de t
. _e t
..
.
.\" n -- name (of author)
.de n
. _e n
..
.
.\" d -- date
.de d
. _e d
. af mo 00
. af dy 00
. ie '\$1'' \n[year]-\n(mo-\n(dy
. el \$1
. af mo 1
. af dy 1
..
.
.\" h -- heading
.de h
. _e h
.
..
.\" s -- section heading
.de s
. _e s
.
..
.\" p -- paragraph
.de p
. _e p
. if '\*[penv]'p' .ti \n(tiu
..
.
.\" l -- literal display
.de l
. _e l
..
.
.ec \" re-enable backslash escapes