1 .\" $Id: mdocterm.1,v 1.20 2009/03/14 12:35:02 kristaps Exp $
3 .\" Copyright (c) 2009 Kristaps Dzonsons <kristaps@kth.se>
5 .\" Permission to use, copy, modify, and distribute this software for any
6 .\" purpose with or without fee is hereby granted, provided that the
7 .\" above copyright notice and this permission notice appear in all
10 .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
11 .\" WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
12 .\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
13 .\" AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
14 .\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
15 .\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
16 .\" TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
17 .\" PERFORMANCE OF THIS SOFTWARE.
19 .Dd $Mdocdate: March 14 2009 $
25 .Nd mdoc macro compiler
30 .Op Fl f Ns Ar option...
31 .Op Fl O Ns Ar option...
40 manual page for display on the terminal. The arguments are as follows:
41 .Bl -tag -width XXXXXXXXXXXX
44 Print verbose parsing output.
47 Print version and exit.
49 .It Fl f Ns Ar option...
50 Override default compiler behaviour. See
54 .It Fl O Ns Ar option...
55 Terminal-encoding options. May be set to
57 for ANSI/VT100-encoded output (the default) or
64 Print warning messages. May be set to
68 for groff/troff-compatibility warnings, or
70 for syntax warnings. If
72 is specified, warnings are considered errors and cause utility
75 arguments may be comma-separated, such as
76 .Fl W Ns Ar error,all .
89 utility is a formatting front-end for
97 into an abstract syntax tree.
101 reads from stdin and prints ANSI
103 terminal-encoded output to stdout, at this time to a fixed column with
110 Default compiler behaviour may be overriden with the
112 flag. The available options are as follows:
113 .Bl -tag -width XXXXXXXXXXXX -offset XXXX
114 .It Fl f Ns Ar ign-scope
115 When rewinding the scope of a block macro, forces the compiler to ignore
116 scope violations. This can seriously mangle the resulting tree.
117 .It Fl f Ns Ar ign-escape
118 Ignore invalid escape sequences.
119 .It Fl f Ns Ar ign-macro
120 Ignore unknown macros at the start of input lines.
128 options may be grouped and delimited with a comma. Using
129 .Fl f Ns Ar ign-scope,ign-escape ,
130 for example, will try to ignore scope and character-escape errors.
132 .Ss Character Escapes
133 The following table shows all
135 character escapes rendered by
139 column will render differently whether executed with
141 or another output filter.
146 .Bl -tag -width "OutputXXXX" -offset "XXXX" -compact
162 .Bl -tag -width "OutputXXXX" -offset "XXXX" -compact
174 \\(rB (right bracket)
180 \\(lq (left double-quote)
182 \\(rq (right double-quote)
184 \\(oq, \\` (left single-quote)
186 \\(aq, \\' (right single-quote, apostrophe)
192 .Bl -tag -width "OutputXXXX" -offset "XXXX" -compact
208 .Bl -tag -width "OutputXXXX" -offset "XXXX" -compact
212 \\(<= (less-than-equal)
214 \\(>= (greater-than-equal)
232 .Bl -tag -width "OutputXXXX" -offset "XXXX" -compact
238 \\(aa (accent accute)
244 .Bl -tag -width "OutputXXXX" -offset "XXXX" -compact
255 *This is a deviation from the standard, as NaN is usually rendered as
256 \\*(Na, which is a deprecated form. We introduce \\(na, which follows
257 the more general syntax.
260 To display this manual page on ANSI-capable terminal:
263 .D1 % mdocmterm \-Wall,error mdocmterm.1
266 To pipe a manual page to the pager:
268 .D1 % mdocterm -Onroff mdocterm.1 | less
280 utility was written by
281 .An Kristaps Dzonsons Aq kristaps@kth.se .
286 for a list of bugs, caveats, and incomplete macros regarding the
291 utility doesn't yet know how to display the following:
297 list is not yet supported.
299 The \-literal and \-unfilled
301 displays only accept text contents.
305 pair isn't supported (and never will be).
309 macro has no effect, yet.