diff options
Diffstat (limited to 'test/tables.typst')
| -rw-r--r-- | test/tables.typst | 251 |
1 files changed, 129 insertions, 122 deletions
diff --git a/test/tables.typst b/test/tables.typst index 46b3e7133..e84b7c41c 100644 --- a/test/tables.typst +++ b/test/tables.typst @@ -1,149 +1,156 @@ Simple table with caption: #figure( -align(center)[#table( - columns: 4, - align: (col, row) => (right,left,center,auto,).at(col), - inset: 6pt, - [Right], [Left], [Center], [Default], - [12], - [12], - [12], - [12], - [123], - [123], - [123], - [123], - [1], - [1], - [1], - [1], -)] -, caption: [Demonstration of simple table syntax.] -) + align(center)[#table( + columns: 4, + align: (col, row) => (right,left,center,auto,).at(col), + inset: 6pt, + [Right], [Left], [Center], [Default], + [12], + [12], + [12], + [12], + [123], + [123], + [123], + [123], + [1], + [1], + [1], + [1], + )] + , caption: [Demonstration of simple table syntax.] + , kind: table + ) Simple table without caption: #figure( -align(center)[#table( - columns: 4, - align: (col, row) => (right,left,center,auto,).at(col), - inset: 6pt, - [Right], [Left], [Center], [Default], - [12], - [12], - [12], - [12], - [123], - [123], - [123], - [123], - [1], - [1], - [1], - [1], -)] -) + align(center)[#table( + columns: 4, + align: (col, row) => (right,left,center,auto,).at(col), + inset: 6pt, + [Right], [Left], [Center], [Default], + [12], + [12], + [12], + [12], + [123], + [123], + [123], + [123], + [1], + [1], + [1], + [1], + )] + , kind: table + ) Simple table indented two spaces: #figure( -align(center)[#table( - columns: 4, - align: (col, row) => (right,left,center,auto,).at(col), - inset: 6pt, - [Right], [Left], [Center], [Default], - [12], - [12], - [12], - [12], - [123], - [123], - [123], - [123], - [1], - [1], - [1], - [1], -)] -, caption: [Demonstration of simple table syntax.] -) + align(center)[#table( + columns: 4, + align: (col, row) => (right,left,center,auto,).at(col), + inset: 6pt, + [Right], [Left], [Center], [Default], + [12], + [12], + [12], + [12], + [123], + [123], + [123], + [123], + [1], + [1], + [1], + [1], + )] + , caption: [Demonstration of simple table syntax.] + , kind: table + ) Multiline table with caption: #figure( -align(center)[#table( - columns: 4, - align: (col, row) => (center,left,right,left,).at(col), - inset: 6pt, - [Centered Header], [Left Aligned], [Right Aligned], [Default aligned], - [First], - [row], - [12.0], - [Example of a row that spans multiple lines.], - [Second], - [row], - [5.0], - [Here’s another one. Note the blank line between rows.], -)] -, caption: [Here’s the caption. It may span multiple lines.] -) + align(center)[#table( + columns: 4, + align: (col, row) => (center,left,right,left,).at(col), + inset: 6pt, + [Centered Header], [Left Aligned], [Right Aligned], [Default aligned], + [First], + [row], + [12.0], + [Example of a row that spans multiple lines.], + [Second], + [row], + [5.0], + [Here’s another one. Note the blank line between rows.], + )] + , caption: [Here’s the caption. It may span multiple lines.] + , kind: table + ) Multiline table without caption: #figure( -align(center)[#table( - columns: 4, - align: (col, row) => (center,left,right,left,).at(col), - inset: 6pt, - [Centered Header], [Left Aligned], [Right Aligned], [Default aligned], - [First], - [row], - [12.0], - [Example of a row that spans multiple lines.], - [Second], - [row], - [5.0], - [Here’s another one. Note the blank line between rows.], -)] -) + align(center)[#table( + columns: 4, + align: (col, row) => (center,left,right,left,).at(col), + inset: 6pt, + [Centered Header], [Left Aligned], [Right Aligned], [Default aligned], + [First], + [row], + [12.0], + [Example of a row that spans multiple lines.], + [Second], + [row], + [5.0], + [Here’s another one. Note the blank line between rows.], + )] + , kind: table + ) Table without column headers: #figure( -align(center)[#table( - columns: 4, - align: (col, row) => (right,left,center,right,).at(col), - inset: 6pt, - [12], - [12], - [12], - [12], - [123], - [123], - [123], - [123], - [1], - [1], - [1], - [1], -)] -) + align(center)[#table( + columns: 4, + align: (col, row) => (right,left,center,right,).at(col), + inset: 6pt, + [12], + [12], + [12], + [12], + [123], + [123], + [123], + [123], + [1], + [1], + [1], + [1], + )] + , kind: table + ) Multiline table without column headers: #figure( -align(center)[#table( - columns: 4, - align: (col, row) => (center,left,right,auto,).at(col), - inset: 6pt, - [First], - [row], - [12.0], - [Example of a row that spans multiple lines.], - [Second], - [row], - [5.0], - [Here’s another one. Note the blank line between rows.], -)] -) + align(center)[#table( + columns: 4, + align: (col, row) => (center,left,right,auto,).at(col), + inset: 6pt, + [First], + [row], + [12.0], + [Example of a row that spans multiple lines.], + [Second], + [row], + [5.0], + [Here’s another one. Note the blank line between rows.], + )] + , kind: table + ) |
