git.iko.soy/typeable/pandoc
on 2.2.2 help sign in
1008 lines 15 kB history raw
1.\" **** Custom macro definitions *********************************
2.\" * Super/subscript
3.\" (https://lists.gnu.org/archive/html/groff/2012-07/msg00046.html)
4.ds { \v'-0.3m'\\s[\\n[.s]*9u/12u]
5.ds } \s0\v'0.3m'
6.ds < \v'0.3m'\s[\\n[.s]*9u/12u]
7.ds > \s0\v'-0.3m'
8.\" * Horizontal line
9.de HLINE
10.LP
11.ce
12\l'20'
13..
14.\" **** Settings *************************************************
15.\" text width
16.nr LL 5.5i
17.\" left margin
18.nr PO 1.25i
19.\" top margin
20.nr HM 1.25i
21.\" bottom margin
22.nr FM 1.25i
23.\" header/footer width
24.nr LT \n[LL]
25.\" point size
26.nr PS 10p
27.\" line height
28.nr VS 12p
29.\" font family: A, BM, H, HN, N, P, T, ZCM
30.fam T
31.\" paragraph indent
32.nr PI 2m
33.\" interparagraph space
34.nr PD 0.33v
35.\" footnote width
36.nr FL \n[LL]
37.\" footnote point size
38.nr FPS (\n[PS] - 2000)
39.\" color used for strikeout
40.defcolor strikecolor rgb 0.7 0.7 0.7
41.\" color for links (rgb)
42.ds PDFHREF.COLOUR 0.35 0.00 0.60
43.\" border for links (default none)
44.ds PDFHREF.BORDER 0 0 0
45.\" point size difference between heading levels
46.nr PSINCR 1p
47.\" heading level above which point size no longer changes
48.nr GROWPS 2
49.\" comment these out if you want a dot after section numbers:
50.als SN SN-NO-DOT
51.als SN-STYLE SN-NO-DOT
52.\" pdf outline fold level
53.nr PDFOUTLINE.FOLDLEVEL 3
54.\" start out in outline view
55.pdfview /PageMode /UseOutlines
56.\" ***************************************************************
57.\" PDF metadata
58.pdfinfo /Title "Pandoc Test Suite"
59.pdfinfo /Author "John MacFarlane; Anonymous"
60.hy
61.EQ
62delim @@
63.EN
64.TL
65Pandoc Test Suite
66.AU
67John MacFarlane
68.AU
69Anonymous
70.AU
71.sp 0.5
72.ft R
73July 17, 2006
74.\" 1 column (use .2C for two column)
75.1C
76.LP
77This is a set of tests for pandoc.
78Most of them are adapted from John Gruber’s markdown test suite.
79.HLINE
80.SH 1
81Headers
82.pdfhref O 1 "Headers"
83.pdfhref M "headers"
84.SH 2
85Level 2 with an \c
86.pdfhref W -D "/url" -A "\c" \
87 -- "embedded link"
88\&
89.pdfhref O 2 "Level 2 with an embedded link"
90.pdfhref M "level-2-with-an-embedded-link"
91.SH 3
92Level 3 with \f[BI]emphasis\f[B]
93.pdfhref O 3 "Level 3 with emphasis"
94.pdfhref M "level-3-with-emphasis"
95.SH 4
96Level 4
97.pdfhref O 4 "Level 4"
98.pdfhref M "level-4"
99.SH 5
100Level 5
101.pdfhref O 5 "Level 5"
102.pdfhref M "level-5"
103.SH 1
104Level 1
105.pdfhref O 1 "Level 1"
106.pdfhref M "level-1"
107.SH 2
108Level 2 with \f[BI]emphasis\f[B]
109.pdfhref O 2 "Level 2 with emphasis"
110.pdfhref M "level-2-with-emphasis"
111.SH 3
112Level 3
113.pdfhref O 3 "Level 3"
114.pdfhref M "level-3"
115.LP
116with no blank line
117.SH 2
118Level 2
119.pdfhref O 2 "Level 2"
120.pdfhref M "level-2"
121.LP
122with no blank line
123.HLINE
124.SH 1
125Paragraphs
126.pdfhref O 1 "Paragraphs"
127.pdfhref M "paragraphs"
128.LP
129Here’s a regular paragraph.
130.PP
131In Markdown 1.0.0 and earlier.
132Version 8.
133This line turns into a list item.
134Because a hard-wrapped line in the middle of a paragraph looked like a list
135item.
136.PP
137Here’s one with a bullet.
138* criminey.
139.PP
140There should be a hard line break
141.br
142here.
143.HLINE
144.SH 1
145Block Quotes
146.pdfhref O 1 "Block Quotes"
147.pdfhref M "block-quotes"
148.LP
149E-mail style:
150.RS
151.LP
152This is a block quote.
153It is pretty short.
154.RE
155.RS
156.LP
157Code in a block quote:
158.IP
159.nf
160\f[C]
161sub\ status\ {
162\ \ \ \ print\ \[dq]working\[dq];
164\f[]
165.fi
166.LP
167A list:
168.IP " 1." 4
169item one
170.IP " 2." 4
171item two
172.LP
173Nested block quotes:
174.RS
175.LP
176nested
177.RE
178.RS
179.LP
180nested
181.RE
182.RE
183.LP
184This should not be a block quote: 2 > 1.
185.PP
186And a following paragraph.
187.HLINE
188.SH 1
189Code Blocks
190.pdfhref O 1 "Code Blocks"
191.pdfhref M "code-blocks"
192.LP
193Code:
194.IP
195.nf
196\f[C]
197----\ (should\ be\ four\ hyphens)
199sub\ status\ {
200\ \ \ \ print\ \[dq]working\[dq];
203this\ code\ block\ is\ indented\ by\ one\ tab
204\f[]
205.fi
206.LP
207And:
208.IP
209.nf
210\f[C]
211\ \ \ \ this\ code\ block\ is\ indented\ by\ two\ tabs
213These\ should\ not\ be\ escaped:\ \ \\$\ \\\\\ \\>\ \\[\ \\{
214\f[]
215.fi
216.HLINE
217.SH 1
218Lists
219.pdfhref O 1 "Lists"
220.pdfhref M "lists"
221.SH 2
222Unordered
223.pdfhref O 2 "Unordered"
224.pdfhref M "unordered"
225.LP
226Asterisks tight:
227.IP \[bu] 3
228asterisk 1
229.IP \[bu] 3
230asterisk 2
231.IP \[bu] 3
232asterisk 3
233.LP
234Asterisks loose:
235.IP \[bu] 3
236asterisk 1
237.IP \[bu] 3
238asterisk 2
239.IP \[bu] 3
240asterisk 3
241.LP
242Pluses tight:
243.IP \[bu] 3
244Plus 1
245.IP \[bu] 3
246Plus 2
247.IP \[bu] 3
248Plus 3
249.LP
250Pluses loose:
251.IP \[bu] 3
252Plus 1
253.IP \[bu] 3
254Plus 2
255.IP \[bu] 3
256Plus 3
257.LP
258Minuses tight:
259.IP \[bu] 3
260Minus 1
261.IP \[bu] 3
262Minus 2
263.IP \[bu] 3
264Minus 3
265.LP
266Minuses loose:
267.IP \[bu] 3
268Minus 1
269.IP \[bu] 3
270Minus 2
271.IP \[bu] 3
272Minus 3
273.SH 2
274Ordered
275.pdfhref O 2 "Ordered"
276.pdfhref M "ordered"
277.LP
278Tight:
279.IP " 1." 4
280First
281.IP " 2." 4
282Second
283.IP " 3." 4
284Third
285.LP
286and:
287.IP " 1." 4
288One
289.IP " 2." 4
290Two
291.IP " 3." 4
292Three
293.LP
294Loose using tabs:
295.IP " 1." 4
296First
297.IP " 2." 4
298Second
299.IP " 3." 4
300Third
301.LP
302and using spaces:
303.IP " 1." 4
304One
305.IP " 2." 4
306Two
307.IP " 3." 4
308Three
309.LP
310Multiple paragraphs:
311.IP " 1." 4
312Item 1, graf one.
313.RS 4
314.PP
315Item 1.
316graf two.
317The quick brown fox jumped over the lazy dog’s back.
318.RE
319.IP " 2." 4
320Item 2.
321.IP " 3." 4
322Item 3.
323.SH 2
324Nested
325.pdfhref O 2 "Nested"
326.pdfhref M "nested"
327.IP \[bu] 3
328Tab
329.RS 3
330.IP \[bu] 3
331Tab
332.RS 3
333.IP \[bu] 3
334Tab
335.RE
336.RE
337.LP
338Here’s another:
339.IP " 1." 4
340First
341.IP " 2." 4
342Second:
343.RS 4
344.IP \[bu] 3
345Fee
346.IP \[bu] 3
347Fie
348.IP \[bu] 3
349Foe
350.RE
351.IP " 3." 4
352Third
353.LP
354Same thing but with paragraphs:
355.IP " 1." 4
356First
357.IP " 2." 4
358Second:
359.RS 4
360.IP \[bu] 3
361Fee
362.IP \[bu] 3
363Fie
364.IP \[bu] 3
365Foe
366.RE
367.IP " 3." 4
368Third
369.SH 2
370Tabs and spaces
371.pdfhref O 2 "Tabs and spaces"
372.pdfhref M "tabs-and-spaces"
373.IP \[bu] 3
374this is a list item indented with tabs
375.IP \[bu] 3
376this is a list item indented with spaces
377.RS 3
378.IP \[bu] 3
379this is an example list item indented with tabs
380.IP \[bu] 3
381this is an example list item indented with spaces
382.RE
383.SH 2
384Fancy list markers
385.pdfhref O 2 "Fancy list markers"
386.pdfhref M "fancy-list-markers"
387.IP " (2)" 5
388begins with 2
389.IP " (3)" 5
390and now 3
391.RS 5
392.LP
393with a continuation
394.IP " iv." 5
395sublist with roman numerals, starting with 4
396.IP " v." 5
397more items
398.RS 5
399.IP " (A)" 5
400a subsublist
401.IP " (B)" 5
402a subsublist
403.RE
404.RE
405.LP
406Nesting:
407.IP " A." 4
408Upper Alpha
409.RS 4
410.IP " I." 4
411Upper Roman.
412.RS 4
413.IP " (6)" 5
414Decimal start with 6
415.RS 5
416.IP " c)" 4
417Lower alpha with paren
418.RE
419.RE
420.RE
421.LP
422Autonumbering:
423.IP " 1." 4
424Autonumber.
425.IP " 2." 4
426More.
427.RS 4
428.IP " 1." 4
429Nested.
430.RE
431.LP
432Should not be a list item:
433.PP
434M.A.\~2007
435.PP
436B.
437Williams
438.HLINE
439.SH 1
440Definition Lists
441.pdfhref O 1 "Definition Lists"
442.pdfhref M "definition-lists"
443.LP
444Tight using spaces:
445.IP "apple"
446red fruit
447.RS
448.RE
449.IP "orange"
450orange fruit
451.RS
452.RE
453.IP "banana"
454yellow fruit
455.RS
456.RE
457.LP
458Tight using tabs:
459.IP "apple"
460red fruit
461.RS
462.RE
463.IP "orange"
464orange fruit
465.RS
466.RE
467.IP "banana"
468yellow fruit
469.RS
470.RE
471.LP
472Loose:
473.IP "apple"
474red fruit
475.RS
476.RE
477.IP "orange"
478orange fruit
479.RS
480.RE
481.IP "banana"
482yellow fruit
483.RS
484.RE
485.LP
486Multiple blocks with italics:
487.IP "\f[I]apple\f[R]"
488red fruit
489.RS
490.PP
491contains seeds, crisp, pleasant to taste
492.RE
493.IP "\f[I]orange\f[R]"
494orange fruit
495.RS
496.IP
497.nf
498\f[C]
499{\ orange\ code\ block\ }
500\f[]
501.fi
502.RS
503.LP
504orange block quote
505.RE
506.RE
507.LP
508Multiple definitions, tight:
509.IP "apple"
510red fruit
511.RS
512.RE
513computer
514.RS
515.RE
516.IP "orange"
517orange fruit
518.RS
519.RE
520bank
521.RS
522.RE
523.LP
524Multiple definitions, loose:
525.IP "apple"
526red fruit
527.RS
528.RE
529computer
530.RS
531.RE
532.IP "orange"
533orange fruit
534.RS
535.RE
536bank
537.RS
538.RE
539.LP
540Blank line after term, indented marker, alternate markers:
541.IP "apple"
542red fruit
543.RS
544.RE
545computer
546.RS
547.RE
548.IP "orange"
549orange fruit
550.RS
551.IP " 1." 4
552sublist
553.IP " 2." 4
554sublist
555.RE
556.SH 1
557HTML Blocks
558.pdfhref O 1 "HTML Blocks"
559.pdfhref M "html-blocks"
560.LP
561Simple block on one line:
562foo
563.LP
564And nested without indentation:
565.LP
566foo
567bar
568.LP
569Interpreted markdown in a table:
570This is \f[I]emphasized\f[R]
571And this is \f[B]strong\f[R]
572.PP
573Here’s a simple block:
574.LP
575foo
576.LP
577This should be a code block, though:
578.IP
579.nf
580\f[C]
581<div>
582\ \ \ \ foo
583</div>
584\f[]
585.fi
586.LP
587As should this:
588.IP
589.nf
590\f[C]
591<div>foo</div>
592\f[]
593.fi
594.LP
595Now, nested:
596foo
597.LP
598This should just be an HTML comment:
599.PP
600Multiline:
601.PP
602Code block:
603.IP
604.nf
605\f[C]
606<!--\ Comment\ -->
607\f[]
608.fi
609.LP
610Just plain comment, with trailing spaces on the line:
611.PP
612Code:
613.IP
614.nf
615\f[C]
616<hr\ />
617\f[]
618.fi
619.LP
620Hr’s:
621.HLINE
622.SH 1
623Inline Markup
624.pdfhref O 1 "Inline Markup"
625.pdfhref M "inline-markup"
626.LP
627This is \f[I]emphasized\f[R], and so \f[I]is this\f[R].
628.PP
629This is \f[B]strong\f[R], and so \f[B]is this\f[R].
630.PP
631An \f[I]\c
632.pdfhref W -D "/url" -A "\c" \
633 -- "emphasized link"
634\&\f[R].
635.PP
636\f[B]\f[BI]This is strong and em.\f[B]\f[R]
637.PP
638So is \f[B]\f[BI]this\f[B]\f[R] word.
639.PP
640\f[B]\f[BI]This is strong and em.\f[B]\f[R]
641.PP
642So is \f[B]\f[BI]this\f[B]\f[R] word.
643.PP
644This is code: \f[C]>\f[R], \f[C]$\f[R], \f[C]\\\f[R], \f[C]\\$\f[R],
645\f[C]<html>\f[R].
646.PP
647\m[strikecolor]This is \f[I]strikeout\f[R].\m[]
648.PP
649Superscripts: a\*{bc\*}d a\*{\f[I]hello\f[R]\*} a\*{hello\~there\*}.
650.PP
651Subscripts: H\*<2\*>O, H\*<23\*>O, H\*<many\~of\~them\*>O.
652.PP
653These should not be superscripts or subscripts, because of the unescaped
654spaces: a\[ha]b c\[ha]d, a\[ti]b c\[ti]d.
655.HLINE
656.SH 1
657Smart quotes, ellipses, dashes
658.pdfhref O 1 "Smart quotes, ellipses, dashes"
659.pdfhref M "smart-quotes-ellipses-dashes"
660.LP
661\[lq]Hello,\[rq] said the spider.
662\[lq]`Shelob' is my name.\[rq]
663.PP
664`A', `B', and `C' are letters.
665.PP
666`Oak,' `elm,' and `beech' are names of trees.
667So is `pine.'
668.PP
669`He said, \[lq]I want to go.\[rq]' Were you alive in the 70’s?
670.PP
671Here is some quoted `\f[C]code\f[R]' and a \[lq]\c
672.pdfhref W -D "http://example.com/?foo=1&bar=2" -A "\c" \
673 -- "quoted link"
674\&\[rq].
675.PP
676Some dashes: one\[em]two \[em] three\[em]four \[em] five.
677.PP
678Dashes between numbers: 5\[en]7, 255\[en]66, 1987\[en]1999.
679.PP
680Ellipses\&...and\&...and\&....
681.HLINE
682.SH 1
683LaTeX
684.pdfhref O 1 "LaTeX"
685.pdfhref M "latex"
686.IP \[bu] 3
687.IP \[bu] 3
688@2 + 2 = 4@
689.IP \[bu] 3
690@x \[u2208] y@
691.IP \[bu] 3
692@alpha \[u2227] omega@
693.IP \[bu] 3
694@223@
695.IP \[bu] 3
696@p@-Tree
697.IP \[bu] 3
698Here’s some display math:
699.EQ
700d over {d x} f ( x ) = lim sub {h -> 0} {f ( x + h ) \[u2212] f ( x )} over h
701.EN
702.IP \[bu] 3
703Here’s one that has a line break in it: @alpha + omega times x sup 2@.
704.LP
705These shouldn’t be math:
706.IP \[bu] 3
707To get the famous equation, write \f[C]$e\ =\ mc\[ha]2$\f[R].
708.IP \[bu] 3
709$22,000 is a \f[I]lot\f[R] of money.
710So is $34,000.
711(It worked if \[lq]lot\[rq] is emphasized.)
712.IP \[bu] 3
713Shoes ($20) and socks ($5).
714.IP \[bu] 3
715Escaped \f[C]$\f[R]: $73 \f[I]this should be emphasized\f[R] 23$.
716.LP
717Here’s a LaTeX table:
718.HLINE
719.SH 1
720Special Characters
721.pdfhref O 1 "Special Characters"
722.pdfhref M "special-characters"
723.LP
724Here is some unicode:
725.IP \[bu] 3
726I hat: Î
727.IP \[bu] 3
728o umlaut: ö
729.IP \[bu] 3
730section: §
731.IP \[bu] 3
732set membership: ∈
733.IP \[bu] 3
734copyright: ©
735.LP
736AT&T has an ampersand in their name.
737.PP
738AT&T is another way to write it.
739.PP
740This & that.
741.PP
7424 < 5.
743.PP
7446 > 5.
745.PP
746Backslash: \\
747.PP
748Backtick: \`
749.PP
750Asterisk: *
751.PP
752Underscore: _
753.PP
754Left brace: {
755.PP
756Right brace: }
757.PP
758Left bracket: [
759.PP
760Right bracket: ]
761.PP
762Left paren: (
763.PP
764Right paren: )
765.PP
766Greater-than: >
767.PP
768Hash: #
769.PP
770Period: .
771.PP
772Bang: !
773.PP
774Plus: +
775.PP
776Minus: -
777.HLINE
778.SH 1
779Links
780.pdfhref O 1 "Links"
781.pdfhref M "links"
782.SH 2
783Explicit
784.pdfhref O 2 "Explicit"
785.pdfhref M "explicit"
786.LP
787Just a \c
788.pdfhref W -D "/url/" -A "\c" \
789 -- "URL"
790\&.
791.PP
792\c
793.pdfhref W -D "/url/" -A "\c" \
794 -- "URL and title"
795\&.
796.PP
797\c
798.pdfhref W -D "/url/" -A "\c" \
799 -- "URL and title"
800\&.
801.PP
802\c
803.pdfhref W -D "/url/" -A "\c" \
804 -- "URL and title"
805\&.
806.PP
807\c
808.pdfhref W -D "/url/" -A "\c" \
809 -- "URL and title"
810\&
811.PP
812\c
813.pdfhref W -D "/url/" -A "\c" \
814 -- "URL and title"
815\&
816.PP
817\c
818.pdfhref W -D "/url/with_underscore" -A "\c" \
819 -- "with_underscore"
820\&
821.PP
822\c
823.pdfhref W -D "mailto:nobody%40nowhere.net" -A "\c" \
824 -- "Email link"
825\&
826.PP
827\c
828.pdfhref W -D "" -A "\c" \
829 -- "Empty"
830\&.
831.SH 2
832Reference
833.pdfhref O 2 "Reference"
834.pdfhref M "reference"
835.LP
836Foo \c
837.pdfhref W -D "/url/" -A "\c" \
838 -- "bar"
839\&.
840.PP
841With \c
842.pdfhref W -D "/url/" -A "\c" \
843 -- "embedded [brackets]"
844\&.
845.PP
846\c
847.pdfhref W -D "/url/" -A "\c" \
848 -- "b"
849\& by itself should be a link.
850.PP
851Indented \c
852.pdfhref W -D "/url" -A "\c" \
853 -- "once"
854\&.
855.PP
856Indented \c
857.pdfhref W -D "/url" -A "\c" \
858 -- "twice"
859\&.
860.PP
861Indented \c
862.pdfhref W -D "/url" -A "\c" \
863 -- "thrice"
864\&.
865.PP
866This should [not][] be a link.
867.IP
868.nf
869\f[C]
870[not]:\ /url
871\f[]
872.fi
873.LP
874Foo \c
875.pdfhref W -D "/url/" -A "\c" \
876 -- "bar"
877\&.
878.PP
879Foo \c
880.pdfhref W -D "/url/" -A "\c" \
881 -- "biz"
882\&.
883.SH 2
884With ampersands
885.pdfhref O 2 "With ampersands"
886.pdfhref M "with-ampersands"
887.LP
888Here’s a \c
889.pdfhref W -D "http://example.com/?foo=1&bar=2" -A "\c" \
890 -- "link with an ampersand in the URL"
891\&.
892.PP
893Here’s a link with an amersand in the link text: \c
894.pdfhref W -D "http://att.com/" -A "\c" \
895 -- "AT&T"
896\&.
897.PP
898Here’s an \c
899.pdfhref W -D "/script?foo=1&bar=2" -A "\c" \
900 -- "inline link"
901\&.
902.PP
903Here’s an \c
904.pdfhref W -D "/script?foo=1&bar=2" -A "\c" \
905 -- "inline link in pointy braces"
906\&.
907.SH 2
908Autolinks
909.pdfhref O 2 "Autolinks"
910.pdfhref M "autolinks"
911.LP
912With an ampersand: \c
913.pdfhref W -D "http://example.com/?foo=1&bar=2" -A "\c" \
914 -- "http://example.com/?foo=1&bar=2"
915\&
916.IP \[bu] 3
917In a list?
918.IP \[bu] 3
919\c
920.pdfhref W -D "http://example.com/" -A "\c" \
921 -- "http://example.com/"
922\&
923.IP \[bu] 3
924It should.
925.LP
926An e-mail address: \c
927.pdfhref W -D "mailto:nobody%40nowhere.net" -A "\c" \
928 -- "nobody\@nowhere.net"
929\&
930.RS
931.LP
932Blockquoted: \c
933.pdfhref W -D "http://example.com/" -A "\c" \
934 -- "http://example.com/"
935\&
936.RE
937.LP
938Auto-links should not occur here: \f[C]<http://example.com/>\f[R]
939.IP
940.nf
941\f[C]
942or\ here:\ <http://example.com/>
943\f[]
944.fi
945.HLINE
946.SH 1
947Images
948.pdfhref O 1 "Images"
949.pdfhref M "images"
950.LP
951From \[lq]Voyage dans la Lune\[rq] by Georges Melies (1902):
952.PP
953[IMAGE: lalune]
954.PP
955Here is a movie [IMAGE: movie] icon.
956.HLINE
957.SH 1
958Footnotes
959.pdfhref O 1 "Footnotes"
960.pdfhref M "footnotes"
961.LP
962Here is a footnote reference,\**
963.FS
964Here is the footnote.
965It can go anywhere after the footnote reference.
966It need not be placed at the end of the document.
967.FE
968and another.\**
969.FS
970Here’s the long note.
971This one contains multiple blocks.
972.PP
973Subsequent blocks are indented to show that they belong to the footnote (as
974with list items).
975.IP
976.nf
977\f[C]
978\ \ {\ <code>\ }
979\f[]
980.fi
981.LP
982If you want, you can indent every line, but you can also be lazy and just
983indent the first line of each block.
984.FE
985This should \f[I]not\f[R] be a footnote reference, because it contains a
986space.[\[ha]my note] Here is an inline note.\**
987.FS
988This is \f[I]easier\f[R] to type.
989Inline notes may contain \c
990.pdfhref W -D "http://google.com" -A "\c" \
991 -- "links"
992\& and \f[C]]\f[R] verbatim characters, as well as [bracketed text].
993.FE
994.RS
995.LP
996Notes can go in quotes.\**
997.FS
998In quote.
999.FE
1000.RE
1001.IP " 1." 4
1002And in list items.\**
1003.FS
1004In list.
1005.FE
1006.LP
1007This paragraph should not be part of the note, as it is not indented.
1008.pdfsync