git.iko.soy/typeable/pandoc
on 1.10.0.4 help sign in
typeable/pandoc/tests/writer.texinfo
1041 lines 15 kB history raw
1\input texinfo
2@documentencoding UTF-8
4@macro textstrikeout{text}
5~~\text\~~
6@end macro
8@macro textsubscript{text}
9@iftex
10@textsubscript{\text\}
11@end iftex
12@ifnottex
13_@{\text\@}
14@end ifnottex
15@end macro
17@macro textsuperscript{text}
18@iftex
19@textsuperscript{\text\}
20@end iftex
21@ifnottex
22^@{\text\@}
23@end ifnottex
24@end macro
26@ifnottex
27@paragraphindent 0
28@end ifnottex
29@titlepage
30@title Pandoc Test Suite
31@author John MacFarlane
32@author Anonymous
33July 17, 2006
34@end titlepage
36@node Top
37@top Pandoc Test Suite
39This is a set of tests for pandoc. Most of them are adapted from John Gruber's markdown test suite.
41@iftex
42@bigskip@hrule@bigskip
43@end iftex
44@ifnottex
45------------------------------------------------------------------------
46@end ifnottex
47@menu
48* Headers::
49* Level 1::
50* Paragraphs::
51* Block Quotes::
52* Code Blocks::
53* Lists::
54* Definition Lists::
55* HTML Blocks::
56* Inline Markup::
57* Smart quotes ellipses dashes::
58* LaTeX::
59* Special Characters::
60* Links::
61* Images::
62* Footnotes::
63@end menu
65@node Headers
66@chapter Headers
67@anchor{#headers}
68@menu
69* Level 2 with an embedded link::
70@end menu
72@node Level 2 with an embedded link
73@section Level 2 with an @uref{/url,embedded link}
74@anchor{#level-2-with-an-embedded-link}
75@menu
76* Level 3 with emphasis::
77@end menu
79@node Level 3 with emphasis
80@subsection Level 3 with @emph{emphasis}
81@anchor{#level-3-with-emphasis}
82@menu
83* Level 4::
84@end menu
86@node Level 4
87@subsubsection Level 4
88@anchor{#level-4}
89Level 5
91@node Level 1
92@chapter Level 1
93@anchor{#level-1}
94@menu
95* Level 2 with emphasis::
96* Level 2::
97@end menu
99@node Level 2 with emphasis
100@section Level 2 with @emph{emphasis}
101@anchor{#level-2-with-emphasis}
102@menu
103* Level 3::
104@end menu
106@node Level 3
107@subsection Level 3
108@anchor{#level-3}
109with no blank line
111@node Level 2
112@section Level 2
113@anchor{#level-2}
114with no blank line
116@iftex
117@bigskip@hrule@bigskip
118@end iftex
119@ifnottex
120------------------------------------------------------------------------
121@end ifnottex
123@node Paragraphs
124@chapter Paragraphs
125@anchor{#paragraphs}
126Here's a regular paragraph.
128In Markdown 1.0.0 and earlier. Version 8. This line turns into a list item. Because a hard-wrapped line in the middle of a paragraph looked like a list item.
130Here's one with a bullet. * criminey.
132There should be a hard line break@*here.
134@iftex
135@bigskip@hrule@bigskip
136@end iftex
137@ifnottex
138------------------------------------------------------------------------
139@end ifnottex
141@node Block Quotes
142@chapter Block Quotes
143@anchor{#block-quotes}
144E-mail style:
146@quotation
147This is a block quote. It is pretty short.
148@end quotation
149@quotation
150Code in a block quote:
152@verbatim
153sub status {
154 print "working";
156@end verbatim
158A list:
160@enumerate
161@item
162item one
163@item
164item two
165@end enumerate
167Nested block quotes:
169@quotation
170nested
171@end quotation
172@quotation
173nested
174@end quotation
175@end quotation
176This should not be a block quote: 2 > 1.
178And a following paragraph.
180@iftex
181@bigskip@hrule@bigskip
182@end iftex
183@ifnottex
184------------------------------------------------------------------------
185@end ifnottex
187@node Code Blocks
188@chapter Code Blocks
189@anchor{#code-blocks}
190Code:
192@verbatim
193---- (should be four hyphens)
195sub status {
196 print "working";
199this code block is indented by one tab
200@end verbatim
202And:
204@verbatim
205 this code block is indented by two tabs
207These should not be escaped: \$ \\ \> \[ \{
208@end verbatim
210@iftex
211@bigskip@hrule@bigskip
212@end iftex
213@ifnottex
214------------------------------------------------------------------------
215@end ifnottex
217@node Lists
218@chapter Lists
219@anchor{#lists}
220@menu
221* Unordered::
222* Ordered::
223* Nested::
224* Tabs and spaces::
225* Fancy list markers::
226@end menu
228@node Unordered
229@section Unordered
230@anchor{#unordered}
231Asterisks tight:
233@itemize
234@item
235asterisk 1
236@item
237asterisk 2
238@item
239asterisk 3
240@end itemize
242Asterisks loose:
244@itemize
245@item
246asterisk 1
248@item
249asterisk 2
251@item
252asterisk 3
254@end itemize
256Pluses tight:
258@itemize
259@item
260Plus 1
261@item
262Plus 2
263@item
264Plus 3
265@end itemize
267Pluses loose:
269@itemize
270@item
271Plus 1
273@item
274Plus 2
276@item
277Plus 3
279@end itemize
281Minuses tight:
283@itemize
284@item
285Minus 1
286@item
287Minus 2
288@item
289Minus 3
290@end itemize
292Minuses loose:
294@itemize
295@item
296Minus 1
298@item
299Minus 2
301@item
302Minus 3
304@end itemize
306@node Ordered
307@section Ordered
308@anchor{#ordered}
309Tight:
311@enumerate
312@item
313First
314@item
315Second
316@item
317Third
318@end enumerate
320and:
322@enumerate
323@item
324One
325@item
326Two
327@item
328Three
329@end enumerate
331Loose using tabs:
333@enumerate
334@item
335First
337@item
338Second
340@item
341Third
343@end enumerate
345and using spaces:
347@enumerate
348@item
349One
351@item
352Two
354@item
355Three
357@end enumerate
359Multiple paragraphs:
361@enumerate
362@item
363Item 1, graf one.
365Item 1. graf two. The quick brown fox jumped over the lazy dog's back.
367@item
368Item 2.
370@item
371Item 3.
373@end enumerate
375@node Nested
376@section Nested
377@anchor{#nested}
378@itemize
379@item
380Tab
381@itemize
382@item
383Tab
384@itemize
385@item
386Tab
387@end itemize
389@end itemize
391@end itemize
393Here's another:
395@enumerate
396@item
397First
398@item
399Second:
400@itemize
401@item
402Fee
403@item
404Fie
405@item
406Foe
407@end itemize
409@item
410Third
411@end enumerate
413Same thing but with paragraphs:
415@enumerate
416@item
417First
419@item
420Second:
422@itemize
423@item
424Fee
425@item
426Fie
427@item
428Foe
429@end itemize
431@item
432Third
434@end enumerate
436@node Tabs and spaces
437@section Tabs and spaces
438@anchor{#tabs-and-spaces}
439@itemize
440@item
441this is a list item indented with tabs
443@item
444this is a list item indented with spaces
446@itemize
447@item
448this is an example list item indented with tabs
450@item
451this is an example list item indented with spaces
453@end itemize
455@end itemize
457@node Fancy list markers
458@section Fancy list markers
459@anchor{#fancy-list-markers}
460@enumerate 2
461@item
462begins with 2
463@item
464and now 3
466with a continuation
468@enumerate 4
469@item
470sublist with roman numerals, starting with 4
471@item
472more items
473@enumerate A
474@item
475a subsublist
476@item
477a subsublist
478@end enumerate
480@end enumerate
482@end enumerate
484Nesting:
486@enumerate A
487@item
488Upper Alpha
489@enumerate
490@item
491Upper Roman.
492@enumerate 6
493@item
494Decimal start with 6
495@enumerate c
496@item
497Lower alpha with paren
498@end enumerate
500@end enumerate
502@end enumerate
504@end enumerate
506Autonumbering:
508@enumerate
509@item
510Autonumber.
511@item
512More.
513@enumerate
514@item
515Nested.
516@end enumerate
518@end enumerate
520Should not be a list item:
522M.A.@ 2007
524B. Williams
526@iftex
527@bigskip@hrule@bigskip
528@end iftex
529@ifnottex
530------------------------------------------------------------------------
531@end ifnottex
533@node Definition Lists
534@chapter Definition Lists
535@anchor{#definition-lists}
536Tight using spaces:
538@table @asis
539@item apple
541red fruit
542@item orange
544orange fruit
545@item banana
547yellow fruit
548@end table
550Tight using tabs:
552@table @asis
553@item apple
555red fruit
556@item orange
558orange fruit
559@item banana
561yellow fruit
562@end table
564Loose:
566@table @asis
567@item apple
569red fruit
571@item orange
573orange fruit
575@item banana
577yellow fruit
579@end table
581Multiple blocks with italics:
583@table @asis
584@item @emph{apple}
586red fruit
588contains seeds, crisp, pleasant to taste
590@item @emph{orange}
592orange fruit
594@verbatim
595{ orange code block }
596@end verbatim
598@quotation
599orange block quote
600@end quotation
601@end table
603Multiple definitions, tight:
605@table @asis
606@item apple
608red fruit
609computer
610@item orange
612orange fruit
613bank
614@end table
616Multiple definitions, loose:
618@table @asis
619@item apple
621red fruit
623computer
625@item orange
627orange fruit
629bank
631@end table
633Blank line after term, indented marker, alternate markers:
635@table @asis
636@item apple
638red fruit
640computer
642@item orange
644orange fruit
646@enumerate
647@item
648sublist
649@item
650sublist
651@end enumerate
653@end table
655@node HTML Blocks
656@chapter HTML Blocks
657@anchor{#html-blocks}
658Simple block on one line:
660foo
661And nested without indentation:
663foo
664bar
665Interpreted markdown in a table:
667This is @emph{emphasized}
668And this is @strong{strong}
669Here's a simple block:
671foo
672This should be a code block, though:
674@verbatim
675<div>
676 foo
677</div>
678@end verbatim
680As should this:
682@verbatim
683<div>foo</div>
684@end verbatim
686Now, nested:
688foo
689This should just be an HTML comment:
691Multiline:
693Code block:
695@verbatim
696<!-- Comment -->
697@end verbatim
699Just plain comment, with trailing spaces on the line:
701Code:
703@verbatim
704<hr />
705@end verbatim
707Hr's:
709@iftex
710@bigskip@hrule@bigskip
711@end iftex
712@ifnottex
713------------------------------------------------------------------------
714@end ifnottex
716@node Inline Markup
717@chapter Inline Markup
718@anchor{#inline-markup}
719This is @emph{emphasized}, and so @emph{is this}.
721This is @strong{strong}, and so @strong{is this}.
723An @emph{@uref{/url,emphasized link}}.
725@strong{@emph{This is strong and em.}}
727So is @strong{@emph{this}} word.
729@strong{@emph{This is strong and em.}}
731So is @strong{@emph{this}} word.
733This is code: @code{>}, @code{$}, @code{\}, @code{\$}, @code{<html>}.
735@textstrikeout{This is @emph{strikeout}.}
737Superscripts: a@textsuperscript{bc}d a@textsuperscript{@emph{hello}} a@textsuperscript{hello@ there}.
739Subscripts: H@textsubscript{2}O, H@textsubscript{23}O, H@textsubscript{many@ of@ them}O.
741These should not be superscripts or subscripts, because of the unescaped spaces: a^b c^d, a~b c~d.
743@iftex
744@bigskip@hrule@bigskip
745@end iftex
746@ifnottex
747------------------------------------------------------------------------
748@end ifnottex
750@node Smart quotes ellipses dashes
751@chapter Smart quotes, ellipses, dashes
752@anchor{#smart-quotes-ellipses-dashes}
753``Hello,'' said the spider. ```Shelob' is my name.''
755`A', `B', and `C' are letters.
757`Oak,' `elm,' and `beech' are names of trees. So is `pine.'
759`He said, ``I want to go.''' Were you alive in the 70's?
761Here is some quoted `@code{code}' and a ``@uref{http://example.com/?foo=1&bar=2,quoted link}''.
763Some dashes: one---two --- three---four --- five.
765Dashes between numbers: 5--7, 255--66, 1987--1999.
767Ellipses@dots{}and@dots{}and@dots{}.
769@iftex
770@bigskip@hrule@bigskip
771@end iftex
772@ifnottex
773------------------------------------------------------------------------
774@end ifnottex
776@node LaTeX
777@chapter LaTeX
778@anchor{#latex}
779@itemize
780@item
781@tex
782\cite[22-23]{smith.1899}
783@end tex
784@item
785@math{2+2=4}
786@item
787@math{x \in y}
788@item
789@math{\alpha \wedge \omega}
790@item
791@math{223}
792@item
793@math{p}-Tree
794@item
795Here's some display math: @math{\frac{d}{dx}f(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}}
796@item
797Here's one that has a line break in it: @math{\alpha + \omega \times x^2}.
798@end itemize
800These shouldn't be math:
802@itemize
803@item
804To get the famous equation, write @code{$e = mc^2$}.
805@item
806$22,000 is a @emph{lot} of money. So is $34,000. (It worked if ``lot'' is emphasized.)
807@item
808Shoes ($20) and socks ($5).
809@item
810Escaped @code{$}: $73 @emph{this should be emphasized} 23$.
811@end itemize
813Here's a LaTeX table:
815@tex
816\begin{tabular}{|l|l|}\hline
817Animal & Number \\ \hline
818Dog & 2 \\
819Cat & 1 \\ \hline
820\end{tabular}
821@end tex
822@iftex
823@bigskip@hrule@bigskip
824@end iftex
825@ifnottex
826------------------------------------------------------------------------
827@end ifnottex
829@node Special Characters
830@chapter Special Characters
831@anchor{#special-characters}
832Here is some unicode:
834@itemize
835@item
836I hat: Î
837@item
838o umlaut: ö
839@item
840section: §
841@item
842set membership: ∈
843@item
844copyright: ©
845@end itemize
847AT&T has an ampersand in their name.
849AT&T is another way to write it.
851This & that.
8534 < 5.
8556 > 5.
857Backslash: \
859Backtick: `
861Asterisk: *
863Underscore: _
865Left brace: @{
867Right brace: @}
869Left bracket: [
871Right bracket: ]
873Left paren: (
875Right paren: )
877Greater-than: >
879Hash: #
881Period: .
883Bang: !
885Plus: +
887Minus: -
889@iftex
890@bigskip@hrule@bigskip
891@end iftex
892@ifnottex
893------------------------------------------------------------------------
894@end ifnottex
896@node Links
897@chapter Links
898@anchor{#links}
899@menu
900* Explicit::
901* Reference::
902* With ampersands::
903* Autolinks::
904@end menu
906@node Explicit
907@section Explicit
908@anchor{#explicit}
909Just a @uref{/url/,URL}.
911@uref{/url/,URL and title}.
913@uref{/url/,URL and title}.
915@uref{/url/,URL and title}.
917@uref{/url/,URL and title}
919@uref{/url/,URL and title}
921@uref{/url/with_underscore,with_underscore}
923@uref{mailto:nobody@@nowhere.net,Email link}
925@uref{,Empty}.
927@node Reference
928@section Reference
929@anchor{#reference}
930Foo @uref{/url/,bar}.
932Foo @uref{/url/,bar}.
934Foo @uref{/url/,bar}.
936With @uref{/url/,embedded [brackets]}.
938@uref{/url/,b} by itself should be a link.
940Indented @uref{/url,once}.
942Indented @uref{/url,twice}.
944Indented @uref{/url,thrice}.
946This should [not][] be a link.
948@verbatim
949[not]: /url
950@end verbatim
952Foo @uref{/url/,bar}.
954Foo @uref{/url/,biz}.
956@node With ampersands
957@section With ampersands
958@anchor{#with-ampersands}
959Here's a @uref{http://example.com/?foo=1&bar=2,link with an ampersand in the URL}.
961Here's a link with an amersand in the link text: @uref{http://att.com/,AT&T}.
963Here's an @uref{/script?foo=1&bar=2,inline link}.
965Here's an @uref{/script?foo=1&bar=2,inline link in pointy braces}.
967@node Autolinks
968@section Autolinks
969@anchor{#autolinks}
970With an ampersand: @url{http://example.com/?foo=1&bar=2}
972@itemize
973@item
974In a list?
975@item
976@url{http://example.com/}
977@item
978It should.
979@end itemize
981An e-mail address: @uref{mailto:nobody@@nowhere.net,nobody@@nowhere.net}
983@quotation
984Blockquoted: @url{http://example.com/}
985@end quotation
986Auto-links should not occur here: @code{<http://example.com/>}
988@verbatim
989or here: <http://example.com/>
990@end verbatim
992@iftex
993@bigskip@hrule@bigskip
994@end iftex
995@ifnottex
996------------------------------------------------------------------------
997@end ifnottex
999@node Images
1000@chapter Images
1001@anchor{#images}
1002From ``Voyage dans la Lune'' by Georges Melies (1902):
1004@float
1005@image{lalune,,,lalune,jpg}
1006@caption{lalune}
1007@end float
1009Here is a movie @image{movie,,,movie,jpg} icon.
1011@iftex
1012@bigskip@hrule@bigskip
1013@end iftex
1014@ifnottex
1015------------------------------------------------------------------------
1016@end ifnottex
1018@node Footnotes
1019@chapter Footnotes
1020@anchor{#footnotes}
1021Here is a footnote reference,@footnote{Here is the footnote. It can go anywhere after the footnote reference. It need not be placed at the end of the document.} and another.@footnote{Here's the long note. This one contains multiple blocks.
1023Subsequent blocks are indented to show that they belong to the footnote (as with list items).
1025@verbatim
1026 { <code> }
1027@end verbatim
1029If you want, you can indent every line, but you can also be lazy and just indent the first line of each block.} This should @emph{not} be a footnote reference, because it contains a space.[^my note] Here is an inline note.@footnote{This is @emph{easier} to type. Inline notes may contain @uref{http://google.com,links} and @code{]} verbatim characters, as well as [bracketed text].}
1031@quotation
1032Notes can go in quotes.@footnote{In quote.}
1033@end quotation
1034@enumerate
1035@item
1036And in list items.@footnote{In list.}
1037@end enumerate
1039This paragraph should not be part of the note, as it is not indented.
1041@bye