Changes

Jump to navigation Jump to search
3,181 bytes added ,  17:29, 13 October 2018
< [[Visuals]] | [[Structurals]] >
ConTeXt has a whole bunch of possibilities to typeset tables. Not each provides everything you may need, and the older ones are deprecated.
* [[tabulateTabulate]] (tabulation, '''recommended for simple requirements''')* [[tableTABLE]] (TaBlE)* [[natural tables, HTML tables]] (multipage TaBlE, '''recommended''')* [[TABLExtables]] (extreme tables – mostly compatible to natural tables, HTML tablesbetter for page breaking)* [[linetable]] framed tables (new multipage for simple tablesthat span hundreds of pages)
Older ones: * [[Table]] (TaBlE, '''deprecated''')* [[Tables]] (multipage TaBlE, '''deprecated''')* [[Linetable]] ("new" multipage tables, '''experimental''' and probably obsolete) Note that you can use natural and extreme tables with the old Table/Tabulate syntax. (To make this even more confusing...) If you have simple tables with lots of contents, and you're tired of typing <code>\bTR\bTD</code>s or <code>\NC\NR</code>s, you can also have a look at* [[M-database|database]] module and its [http://dl.contextgarden.net/myway/csv.pdf manual].* [[wikitable]], a TABLE wrapper that uses MediaWiki syntax* [http://tug.org/TUGboat/Articles/tb28-3/tb90mahajan.pdf ConTeXt basics for users: Table macros] and [http://www.tug.org/TUGboat/Articles/tb29-1/tb91mahajan.pdf Table macros II] by Aditya Mahajan (2007 and 2008). == Features:==<tablestyle="border:1px solid #DDDDDD; width:100%" align="left" valign="top"><trstyle="background-color:#DDDDDD" align="left" valign="top"><th>Feature</th><th>tabulate[[Tabulate]]</th><th>table[[Table]]/[[Tables]]</th><th>tables[[TABLE]]</th><th>[[xtables]]</th><th>TABLE[[Linetable]]</th><th>linetable[[framedtable]]</th></tr> <tralign="left" valign="top"><thstyle="background-color:#DDDDDD">horizonal lines</th><td><cmd>HL</cmd></td>
<td><cmd>HL</cmd></td>
<td><cmd>HL</cmd></td>
[bottomframe=on]
</texcode></td>
<td><texcode>\setupxtable[...]</texcode></td><td>unknown</td><td>yes</td></tr> <tralign="left" valign="top" style="background-color:#EEEEEE;"><thstyle="background-color:#DDDDDD">vertical lines</th><td>no</td>
<td><cmd>VL</cmd></td>
<td><cmd>VL</cmd></td>
[rightframe=on]
</texcode></td>
<td></tdtexcode>\setupxtable[...]</trtexcode><tr/td><thtd>multipageunknown</thtd>
<td>yes</td>
<td/tr> <tr align="left" valign="top"><th style="background-color:#DDDDDD">nomultipage</tdth>
<td>yes</td>
<td>no / yes (tables)</td><td>yes, with <tt>split=yes</tt> or <tt>split=repeat</tt></td><td>vertically yes, horizontally not but planned</td><td>yes, even horizontally</td>
<td>yes</td>
</tr> <tralign="left" valign="top" style="background-color:#EEEEEE;"><thstyle="background-color:#DDDDDD">repeated header</th><td>no</tdtexcode>\setuptabulate[header=repeat]\starttabulatehead...\stoptabulatehead<td/texcode>only one line</td><td>table<cmdb>s</b> only:<texcode>\setuptables [split=repeat] \starttablehead...\stoptablehead</cmdtexcode></td>
<td><texcode>
\bTABLE
\eTABLEhead
</texcode></td>
<td>yes</td><td>yes</td><td>yes</td></tr> <tralign="left" valign="top"><thstyle="background-color:#DDDDDD">repeated footer</th>
<td>no</td>
<td>table<b>s</b> only:<texcode>\setuptables [split=repeat] \starttabletail...\stoptabletail</texcode></td><td>no?<cmd/td>starttabletail</cmdtd>yes</td>
<td>no</td>
<td>unknown</td></tr> <tralign="left" valign="top" style="background-color:#EEEEEE;"><thstyle="background-color:#DDDDDD">automatic fitting to given table width</th>
<td>no</td>
<td><cmd>SetTableToWidth</cmd></td>
<td><texcode>\setupTABLE[option=stretch, textwidth=10cm]<cmd/texcode>SetTableToWidth</cmdtd><td>yes</td><td>nodefault</td><td>unknown</td></tr> <tralign="left" valign="top"><thstyle="background-color:#DDDDDD">problems</th><td>very limited</td><td></td>some limitations, problems with spacing<td><texcode>
\starttext
\starttablehead
\stoptext
</texcode></td>
<td>there may be problems in width and height calculation and perhaps the multipage features</td><td>very verbose</td><td>lack of documentation, just experimental</td><td>limitations, lack of documentation</td></tr> <!-- Tabulate Table(s) TABLE xtable linetable framedtable --><tralign="left" valign="top" style="background-color:#EEEEEE;"><thstyle="background-color:#DDDDDD">documentation(except wiki)</th><td>cont-enp[http://pmrb.free.fr/contextref.pdf contextref.pdf], core[[source:tabl-tbl.texmkii|tabl-tbl.mkii]], [http://www.ntg.nl/maps/pdf/22_28.pdf MAPS article]</td><td>[[manual:mp-cb-en.pdf|ms-cb-en.pdf]], core[[source:tabl-tab.mkii|tabl-tab.texmkii]]</td><td>core[[manual:enattab.pdf|enattab.pdf]], [http://dl.contextgarden.net/myway/NaturalTables.pdf NaturalTables.pdf], [[source:tabl-tabntb.mkii|tabl-ntb.mkii]] / [[source:tabl-ntb.mkiv|tabl-ntb.texmkiv]]</td><td>enattab[http://www.pragma-ade.com/general/manuals/xtables-mkiv.pdf, NaturalTablesxtables-mkiv.pdf], core[[source:tabl-ntbxtb.lua|tabl-xtb.texlua]]</td><td>core[[source:tabl-ltb.mkii|tabl-ltb.texmkii]] / [[source:tabl-ltb.mkiv|tabl-ltb.mkiv]]</td><td>?</td></tr></table> [[Category:Tables]]
58

edits

Navigation menu