def_colwidths uses heuristics to determine suitable column widths given a
table or listing, and a font.
listing_column_widths(
mpf,
incl_header = TRUE,
col_gap = 0.5,
pg_width_ins = 8.88,
fontspec = font_spec("Times", 8, 1.2),
verbose = FALSE
)def_colwidths(
tt,
fontspec,
label_width_ins = 2,
col_gap = ifelse(type == "Listing", 0.5, 3),
type = tlg_type(tt)
)
listing_column_widths: a vector of column widths suitable to use in tt_to_tlgrtf and
other exporters.
def_colwidths: a vector of column widths (including the label row pseudo-column in the table
case) suitable for use rendering tt in the specified font.
(listing_df or MatrixPrintForm derived thereof)
The listing
calculate column widths for.
(logical(1))
Should the constraint to not break up
individual words be extended to words in the column labels? Defaults to TRUE
Column gap in spaces. Defaults to .5 for listings and 3
for tables.
(numeric(1))
Number of inches in width for
the portion of the page the listing will be printed to. Defaults to 8.88
which corresponds to landscape orientation on a standard page after margins.
Font specification
(logical(1))
Should additional information messages be
displayed during the calculation of the column widths? Defaults to FALSE.
input TableTree
Label Width in Inches.
Type of the TableTree, used to determine column width calculation method.
Listings are assumed to be rendered landscape on standard A1 paper,
such that all columns are rendered on one page. Tables are allowed to
be horizontally paginated, and column widths are determined based only on
required word wrapping. See the Automatic Column Widths vignette for
a detailed discussion of the algorithms used.