git.iko.soy/typeable/pandoc
on dark-mode help sign in
typeable/pandoc/test/tables.latex
110 lines 3.1 kB history raw
1Simple table with caption:
3\begin{longtable}[]{@{}rlcl@{}}
4\caption{Demonstration of simple table syntax.}\tabularnewline
5\toprule
6Right & Left & Center & Default \\
7\midrule
8\endfirsthead
9\toprule
10Right & Left & Center & Default \\
11\midrule
12\endhead
1312 & 12 & 12 & 12 \\
14123 & 123 & 123 & 123 \\
151 & 1 & 1 & 1 \\
16\bottomrule
17\end{longtable}
19Simple table without caption:
21\begin{longtable}[]{@{}rlcl@{}}
22\toprule
23Right & Left & Center & Default \\
24\midrule
25\endhead
2612 & 12 & 12 & 12 \\
27123 & 123 & 123 & 123 \\
281 & 1 & 1 & 1 \\
29\bottomrule
30\end{longtable}
32Simple table indented two spaces:
34\begin{longtable}[]{@{}rlcl@{}}
35\caption{Demonstration of simple table syntax.}\tabularnewline
36\toprule
37Right & Left & Center & Default \\
38\midrule
39\endfirsthead
40\toprule
41Right & Left & Center & Default \\
42\midrule
43\endhead
4412 & 12 & 12 & 12 \\
45123 & 123 & 123 & 123 \\
461 & 1 & 1 & 1 \\
47\bottomrule
48\end{longtable}
50Multiline table with caption:
52\begin{longtable}[]{@{}
53 >{\centering\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.15}}
54 >{\raggedright\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.14}}
55 >{\raggedleft\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.16}}
56 >{\raggedright\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.35}}@{}}
57\caption{Here's the caption. It may span multiple lines.}\tabularnewline
58\toprule
59Centered Header & Left Aligned & Right Aligned & Default aligned \\
60\midrule
61\endfirsthead
62\toprule
63Centered Header & Left Aligned & Right Aligned & Default aligned \\
64\midrule
65\endhead
66First & row & 12.0 & Example of a row that spans multiple lines. \\
67Second & row & 5.0 & Here's another one. Note the blank line between rows. \\
68\bottomrule
69\end{longtable}
71Multiline table without caption:
73\begin{longtable}[]{@{}
74 >{\centering\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.15}}
75 >{\raggedright\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.14}}
76 >{\raggedleft\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.16}}
77 >{\raggedright\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.35}}@{}}
78\toprule
79Centered Header & Left Aligned & Right Aligned & Default aligned \\
80\midrule
81\endhead
82First & row & 12.0 & Example of a row that spans multiple lines. \\
83Second & row & 5.0 & Here's another one. Note the blank line between rows. \\
84\bottomrule
85\end{longtable}
87Table without column headers:
89\begin{longtable}[]{@{}rlcr@{}}
90\toprule
91\endhead
9212 & 12 & 12 & 12 \\
93123 & 123 & 123 & 123 \\
941 & 1 & 1 & 1 \\
95\bottomrule
96\end{longtable}
98Multiline table without column headers:
100\begin{longtable}[]{@{}
101 >{\centering\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.15}}
102 >{\raggedright\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.14}}
103 >{\raggedleft\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.16}}
104 >{\raggedright\arraybackslash}p{(\columnwidth - 6\tabcolsep) * \real{0.35}}@{}}
105\toprule
106\endhead
107First & row & 12.0 & Example of a row that spans multiple lines. \\
108Second & row & 5.0 & Here's another one. Note the blank line between rows. \\
109\bottomrule
110\end{longtable}