Home

Fantom Tbl

Fantom pod to export to `tbl` format. `Tbl` is used with troff and makes really easy to create tables in postscript, pdf or html.

Example:

   out := Env.cur.out
   tbl := TblOutStream.makeWith(out)
   {

     // options

     allbox = true
     expand = true
     tab = ';'

     // format of columns

     "lb rb",
     "l  n",

     // data

     ["Empresa", "Ventas"],
     ["Evil Corp.", "17.00"],
   }

Write the table:

tbl.writeAll

Result

The output is:

 .TS
 allbox,expand,tab(;);
 lb rb
 l n .
 Empresa;Ventas
 Evil Corp;17.00
 .TE