MinimalColumn class

One column of a MinimalTable: its header label, how much of the width it takes, and how its cells print.

A column is either a fixed width or a share of what the fixed ones leave (flex). Under a larger text scale a fixed width grows as far as its header, its text cells or its badges need (never past the scale itself). Columns share the width by need: where the table is short of room a fixed column first gives up its air past its content, then the gaps close from 16 to 8 px (never between two numeric or mono columns, whose figures would read as one), then the shared columns' words are cut, never under 72 px and never into a badge. A column with a widget cell keeps its width, and its widgets shorten.

numeric is the figure register — mono, tabular and right-aligned, so a column of quantities or times lines up on its last digit. mono prints an identifier column (1047, HAB-4) in the quiet mono without right-aligning it. sortable makes the header a control that reports to MinimalTable.onSort; the table never reorders rows itself.

MinimalColumn('Qty', width: 44, numeric: true, sortable: true)
Annotations

Constructors

MinimalColumn(String label, {double? width, int flex = 1, bool numeric = false, bool mono = false, bool sortable = false, bool? alignEnd})
A column headed label.
const

Properties

alignEnd → bool?
Right-align the column's header and cells; null aligns numeric columns at the end and everything else at the start.
final
flex → int
Its share of the width over what the shared columns' words ask for, when it has no fixed width.
final
hashCode → int
The hash code for this object.
no setterinherited
label → String
The header text; the table upper-cases it.
final
mono → bool
Identifiers: mono in the quiet ink, aligned at the start.
final
numeric → bool
Figures: mono, tabular, right-aligned.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sortable → bool
Whether its header sorts the table.
final
width → double?
A fixed width in logical pixels; null shares the free width by flex.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited