Darwin Help

Back to Index

Table

Class Table - structure to print/display tables

Calling Sequence  Table(arg1,...,argn)
Parameters
NameTypeDescription

arg1..n anythingcomponents of table in any order

centerthe entire table is centered

borderthe entire table is framed with a border

gutter=posintset gutter between columns

gutter=list(posint)set gutter for each individual column

ColAlign({string,p(posint)}...)set alignment for each individual column

RowAlign(string)set vertical alignment for following rows

 ('l', 'c' and 'r' for left, center, right)

Row(args)a row of data, each argument in a column

title=stringtitle/caption to describe the table

Values(args)args to be distributed columwise

rowwiseuses Values(), but args are distributed rowwise

width=posintwidth of the table in characters

Ruledraw a horizontal line

SpanPrevious possible argument of Row
Return Type  Table
Methods HTMLC, LaTeXC, print, string, type
Synopsis The Table structure holds information describing a table (or tabular information). This is expected to be laid out as a table either as text, latex, html or something else. If a Row structure has an element with the name 'SpanPrevious', then the previous entry will be expanded to occupy also the space of this entry (like \multicolumn in latex or colspan in html). The alignment inside the cells are set with ColAlign - either l (left), r (right), c (center) or p(x) (paragraph with a fixed width of x characters).
Examples
> t := Table( center, border, gutter=4, Row('abc','cde'),Row(1,1e9)):

> print(t);
                            -----------------------
                            |  abc       cde      |
                            |   1     1000000000  |
                            -----------------------



See also Code,   Color,   Copyright,   Document,   HTML,   HyperLink,   Indent,   LastUpdatedBy,   latex,   List,   Paragraph,   PostscriptFigure,   print,   Roman,   RunDarwinSession,   screenwidth,   TT,   View