Merge branch 'topic/sync-to-go-2'
[s-roff.git] / tmac / an-ext.tmac
blob205faeb997551292d67e52fd70dab838e08ed9cb
1 .\"@ an-ext.tmac
2 .\"
3 .\" Copyright (c) 2014 - 2017 Steffen (Daode) Nurpmeso <steffen@sdaoden.eu>.
4 .\"
5 .\" Copyright (C) 2007 Free Software Foundation, Inc.
6 .\" You may freely use, modify and/or distribute this file.
7 .\"
8 .\" Written by Eric S. Raymond <esr@thyrsus.com>
9 .\"            Werner Lemberg <wl@gnu.org>
10 .\"
11 .\" The code below provides extension macros for the `man' macro package.
12 .\" Care has been taken to make the code portable; groff extensions are
13 .\" properly hidden so that all troff implementations can use it without
14 .\" changes.
15 .\"
16 .\" With groff, this file is sourced by the `man' macro package itself.
17 .\" Man page authors who are concerned about portability might add the
18 .\" used macros directly to the prologue of the man page(s).
21 .\" Convention: Auxiliary macros and registers start with `m' followed
22 .\"             by an uppercase letter or digit.
25 .\" Protect against being sourced twice.
26 .nr mX +1
27 .if \n(mX>1 \
28 .  nx
30 .\" Check whether we are using grohtml.
31 .nr mH 0
32 .if \n(.g \
33 .  if '\*(.T'html' \
34 .    nr mH 1
37 .\" Map mono-width fonts to standard fonts for groff's TTY device.
38 .if n \{\
39 .  do ftr CR R
40 .  do ftr CI I
41 .  do ftr CB B
42 .\}
44 .\" groff has glyph entities for angle brackets.
45 .ie \n(.g \{\
46 .  ds la \(la\"
47 .  ds ra \(ra\"
48 .\}
49 .el \{\
50 .  ds la <\"
51 .  ds ra >\"
52 .  \" groff's man macros control hyphenation with this register.
53 .  nr HY 1
54 .\}
56 .nr mS 0
59 .\" Declare start of command synopsis.  Sets up hanging indentation.
60 .de SY
61 .  ie !\\n(mS \{\
62 .    nh
63 .    nr mS 1
64 .    nr mA \\n(.j
65 .    ad l
66 .    nr mI \\n(.i
67 .  \}
68 .  el \{\
69 .    br
70 .    ns
71 .  \}
73 .  nr mT \w'\fB\\$1\fP\ '
74 .  HP \\n(mTu
75 .  rr mT
76 .  B "\\$1"
80 .\" End of command synopsis.  Restores adjustment.
81 .de YS
82 .  in \\n(mIu
83 .  ad \\n(mA
84 .  hy \\n(HY
85 .  nr mS 0
89 .\" Declare optional option.
90 .de OP
91 .  ie \\n(.$-1 \
92 .    RI "[\fB\\$1\fP" "\ \\$2" "]"
93 .  el \
94 .    RB "[" "\\$1" "]"
98 .\" Start URL.
99 .de UR
100 .  ds m1 \\$1\"
101 .  nh
102 .  if \\n(mH \{\
103 .    \" Start diversion in a new environment.
104 .    do ev URL-div
105 .    do di URL-div
106 .  \}
110 .\" End URL.
111 .de UE
112 .  ie \\n(mH \{\
113 .    br
114 .    di
115 .    ev
117 .    \" Has there been one or more input lines for the link text?
118 .    ie \\n(dn \{\
119 .      do HTML-NS "<a href=""\\*(m1"">"
120 .      \" Yes, strip off final newline of diversion and emit it.
121 .      do chop URL-div
122 .      do URL-div
124 .      do HTML-NS </a>
125 .    \}
126 .    el \
127 .      do HTML-NS "<a href=""\\*(m1"">\\*(m1</a>"
128 \&\\$*\"
129 .  \}
130 .  el \
131 \\*(la\\*(m1\\*(ra\\$*\"
133 .  hy \\n(HY
137 .\" Start email address.
138 .de MT
139 .  ds m1 \\$1\"
140 .  nh
141 .  if \\n(mH \{\
142 .    \" Start diversion in a new environment.
143 .    do ev URL-div
144 .    do di URL-div
145 .  \}
149 .\" End email address.
150 .de ME
151 .  ie \\n(mH \{\
152 .    br
153 .    di
154 .    ev
156 .    \" Has there been one or more input lines for the link text?
157 .    ie \\n(dn \{\
158 .      do HTML-NS "<a href=""mailto:\\*(m1"">"
159 .      \" Yes, strip off final newline of diversion and emit it.
160 .      do chop URL-div
161 .      do URL-div
163 .      do HTML-NS </a>
164 .    \}
165 .    el \
166 .      do HTML-NS "<a href=""mailto:\\*(m1"">\\*(m1</a>"
167 \&\\$*\"
168 .  \}
169 .  el \
170 \\*(la\\*(m1\\*(ra\\$*\"
172 .  hy \\n(HY
176 .\" Continuation line for .TP header.
177 .de TQ
178 .  br
179 .  ns
180 .  TP \\$1\" no doublequotes around argument!
184 .\" Start example.
185 .de EX
186 .  do ds mF \\n[.fam]
187 .  nr mE \\n(.f
188 .  nf
189 .  nh
190 .  do fam C
191 .  ft CW
195 .\" End example.
196 .de EE
197 .  do fam \\*(mF
198 .  ft \\n(mE
199 .  fi
200 .  hy \\n(HY
204 .\" Start display.
205 .de DS
206 .  \" XXX to be written
210 .\" End display.
211 .de DE
212 .  \" XXX to be written
215 .\" s-ts-mode