s-gnu-diff.sh: removed
[s-roff.git] / tmac / andoc.tmac
blob4c02753d9b95710346f2a67e696ef3f4ac01363b
1 .\"@ andoc.tmac
2 .\"@ Load either an-old.tmac or doc.tmac.  Multiple man pages can be handled.
3 .\"
4 .\" Copyright (c) 2014 - 2017 Steffen (Daode) Nurpmeso <steffen@sdaoden.eu>.
5 .\"
6 .\" Copyright (C) 1991, 1995, 2000, 2002, 2008
7 .\"   Free Software Foundation, Inc.
8 .\"      Written by James Clark (jjc@jclark.com)
9 .\"
10 .\" This is free software; you can redistribute it and/or modify it under
11 .\" the terms of the GNU General Public License as published by the Free
12 .\" Software Foundation; either version 2, or (at your option) any later
13 .\" version.
14 .\"
15 .\" This is distributed in the hope that it will be useful, but WITHOUT ANY
16 .\" WARRANTY; without even the implied warranty of MERCHANTABILITY or
17 .\" FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
18 .\" for more details.
19 .\"
20 .\" You should have received a copy of the GNU General Public License along
21 .\" with groff; see the file COPYING.  If not, write to the Free Software
22 .\" Foundation, 51 Franklin St - Fifth Floor, Boston, MA 02110-1301, USA.
24 .if !\n(.g \
25 .  ab These macros require groff / compatible.
27 .nr _C \n(.C
28 .cp 0
30 .als andoc-em em
31 .als andoc-bp bp
33 .\" We must not use `.de1' for `reload-doc' or `reload-man'!  `doc.tmac'
34 .\" unconditionally switches compatibility mode off, but `.de1' would ignore
35 .\" this, restoring the mode that was active before.  Similarly, we have to
36 .\" switch back to the original compatibility mode for man documents in case
37 .\" there is a mix of mdoc and man input files.
38 .\"
39 .\" Due to a bug in GNU troff it necessary to have a no-op line between
40 .\" `.do' and `\*'.
42 .de reload-doc
43 .  do ch an-header   \" remove trap set by an-old.tmac
44 .  do ch an-footer   \" remove trap set by an-old.tmac
45 .  do ch an-p-footer \" remove trap set by an-old.tmac
47 .  do als em andoc-em
48 .  do als bp andoc-bp
49 .  do rm Dd          \" disable load-only-once, see doc.tmac
51 .  do mso doc.tmac
53 .  do als TH reload-man
55 \\*(Dd\\
58 .de reload-man
59 .  do cp \n(.C       \" restore original compatibility mode
61 .  do ch header      \" remove trap set by doc.tmac
62 .  do ch footer      \" remove trap set by doc.tmac
64 .  do als em andoc-em
65 .  do als bp andoc-bp
66 .  do rm RI          \" disable load-only-once, see an-old.tmac
67 .  do blm            \" no blank line macro
68 .  do rm TH
70 .  do mso an-old.tmac
72 .  do als Dd reload-doc
74 \\*(TH\\
77 .als TH reload-man
78 .als Dd reload-doc
80 .\" dummy equation macros -- eqnrc is read before .TH or .Dd is parsed
81 .de EQ
83 .de EN
86 .cp \n[_C]
87 .rm _C
89 .\" s-ts-mode