
Functions to get or set the column widths property of huxtable cols.
col_width(ht)
col_width(ht) <- value
set_col_width(ht, col, value)
A huxtable.
A vector. If numeric, they are treated as proportions of the table width. If character, they must be valid CSS or LaTeX lengths.
A col specifier. See rowspecs for details.
For col_width
, the col_width
property.
For set_col_width
, the modified huxtable.
In LaTeX, if you specify a column width, but set wrap
to FALSE
and have cells which
overrun, then you may have problems with table position and with background colours in other cells.
The workaround is to adjust the width, so that your cells no longer overrun.
Other row/column heights: row_height
# NOT RUN {
orig <- col_width(jams)
col_width(jams) <- c(.2, .8)
col_width(jams)
col_width(jams) <- orig
# }
Run the code above in your browser using DataLab