calculateColumnWidths<T, K> static method
One-shot convenience wrapper around measureColumns + TTableColumnMeasurements.resolve for callers that don't need to cache the measurement step themselves.
Implementation
static Map<int, TableColumnWidth> calculateColumnWidths<T, K>(
List<TTableHeader<T, K>> headers,
bool selectable,
bool expandable, {
int maxTreeLevel = 0,
bool isHierarchical = false,
List<T> sampleItems = const [],
TextStyle? headerTextStyle,
TextStyle? contentTextStyle,
double availableWidth = double.infinity,
}) {
return measureColumns<T, K>(
headers,
selectable,
expandable,
maxTreeLevel: maxTreeLevel,
isHierarchical: isHierarchical,
sampleItems: sampleItems,
headerTextStyle: headerTextStyle,
contentTextStyle: contentTextStyle,
).resolve(availableWidth);
}