Expand description
Each main-table column’s drawn width, kept by identity so the layout holds through
paging, scrolling, reordering and resizing. Automatic widths are learned from the
first page drawn (values already formatted, nothing read): text keeps it, bounded by
text_cap and clipped beyond; numbers, dates and flags only grow (clipped they
would read wrong). Sidebar-set widths win. A query, reshape, drill, sort or filter
relearns automatic widths; paging and scrolling never do.
Structs§
- Column
Widths - Display widths by column identity (name and type): a retyped column starts afresh, one returning with its type keeps its width. Unrelated to the byte estimate that plans buffers.
- Page
Measure - One column measured on the rows on screen, in cells, as the table draws it.
Enums§
- Width
Choice - How a column’s width is chosen.
Constants§
- MAX_
WIDTH - MIN_
WIDTH - The narrowest and widest a width set by hand may be.
- UNSEEN_
WIDTH - Where narrower or wider starts on a column that has not been drawn yet.
- WIDTH_
STEP - Cells one narrower or wider press moves a width.
Functions§
- text_
cap - The most cells an automatic width gives text or a heading: two fifths of the terminal (32 at 80 columns), between 16 and 64. From the terminal, not the table, so a sidebar moves nothing; a resize does.