@@ -6,8 +6,9 @@ Pandoc is a [Haskell] library for converting from one markup format
66to another, and a command-line tool that uses this library. It can read
77[markdown] and (subsets of) [reStructuredText], [HTML], and [LaTeX],
88and it can write [markdown], [reStructuredText], [HTML], [LaTeX], [RTF],
9−[DocBook XML], and [S5] HTML slide shows. Pandoc's version of markdown
10−contains some enhancements, like footnotes and embedded LaTeX.
9+[DocBook XML], [groff man] pages, and [S5] HTML slide shows. Pandoc's
10+version of markdown contains some enhancements, like footnotes and
11+embedded LaTeX.
1112
1213In contrast to existing tools for converting markdown to HTML, which
1314use regex substitutions, Pandoc has a modular design: it consists of a
@@ -23,6 +24,7 @@ or output format requires only adding a reader or writer.
2324[LaTeX]: http://www.latex-project.org/
2425[RTF]: http://en.wikipedia.org/wiki/Rich_Text_Format
2526[DocBook XML]: http://www.docbook.org/
27+[groff man]: http://developer.apple.com/DOCUMENTATION/Darwin/Reference/ManPages/man7/groff_man.7.html
2628[Haskell]: http://www.haskell.org/
2729
2830(c) 2006 John MacFarlane (jgm at berkeley dot edu). Released under the
@@ -110,16 +112,17 @@ To convert `hello.html` from html to markdown:
110112
111113Supported output formats include `markdown`, `latex`, `html`, `rtf`
112114(rich text format), `rst` (reStructuredText), `docbook` (DocBook
113−XML), and `s5` (which produces an HTML file that acts like powerpoint).
114−Supported input formats include `markdown`, `html`, `latex`, and `rst`.
115−Note that the `rst` reader only parses a subset of reStructuredText
116−syntax. For example, it doesn't handle tables, definition lists, option
117−lists, or footnotes. It handles only the constructs expressible in
118−unextended markdown. But for simple documents it should be adequate.
119−The `latex` and `html` readers are also limited in what they can do.
120−Because the `html` reader is picky about the HTML it parses, it is
121−recommended that you pipe HTML through [HTML Tidy] before sending it to
122−`pandoc`, or use the `html2markdown` script described below.
115+XML), `man` (groff man), and `s5` (which produces an HTML file that
116+acts like powerpoint). Supported input formats include `markdown`,
117+`html`, `latex`, and `rst`. Note that the `rst` reader only parses
118+a subset of reStructuredText syntax. For example, it doesn't handle
119+tables, definition lists, option lists, or footnotes. It handles only
120+the constructs expressible in unextended markdown. But for simple
121+documents it should be adequate. The `latex` and `html` readers are also
122+limited in what they can do. Because the `html` reader is picky about
123+the HTML it parses, it is recommended that you pipe HTML through [HTML
124+Tidy] before sending it to `pandoc`, or use the `html2markdown` script
125+described below.
123126
124127If you don't specify a reader or writer explicitly, `pandoc` will
125128try to determine the input and output format from the extensions of
@@ -137,11 +140,10 @@ be assumed to be markdown unless explicitly specified.
137140Character encodings
138141-------------------
139142
140−Unfortunately, due to limitations in GHC, `pandoc` does not automatically
141−detect the system's local character encoding. Hence, all input and
142−output is assumed to be in the UTF-8 encoding. If your local character
143−encoding is not UTF-8 and you use accented or foreign characters,
144−you should pipe the input and output through [`iconv`]. For example,
143+All input is assumed to be in the UTF-8 encoding, and all output
144+is in UTF-8. If your local character encoding is not UTF-8 and you use
145+accented or foreign characters, you should pipe the input and output
146+through [`iconv`]. For example,
145147
146148 iconv -t utf-8 source.txt | pandoc | iconv -f utf-8 > output.html
147149
@@ -652,11 +654,21 @@ window in a browser -- and once at the beginning of the document body.
652654The title in the document head can have an optional prefix attached
653655(`--title-prefix` or `-T` option). The title in the body appears as
654656an H1 element with class "title", so it can be suppressed or
655−reformatted with CSS.
657+reformatted with CSS. If a title prefix is specified with `-T` and no
658+title block appears in the document, the title prefix will be used by
659+itself as the HTML title.
656660
657−If a title prefix is specified with `-T` and no title block appears
658−in the document, the title prefix will be used by itself as the
659−HTML title.
661+The man page writer extracts a title, man page section number, and
662+other header and footer information from the title line. These should
663+be separated by pipe characters (`|`), as follows:
664+
665+ % title | section number (1-9) | footer left | header center
666+
667+For example,
668+
669+ % pandoc | 1 | Pandoc User Manuals | Version 4.0
670+
671+The middle of the man page footer is used for the date.
660672
661673Box-style blockquotes
662674---------------------