TableFormatter
Category: UI
Source: table_formatter.dart
Enums
TableAlign
| Value | Description |
|---|---|
left | |
right |
Classes
TableColumn
Constructor
dart
const TableColumn({
required this.key,
required this.header,
this.align = TableAlign.left,
this.minWidth = 0,
this.maxWidth,
})Properties
| Property | Type | Description |
|---|---|---|
key | String | |
header | String | |
align | TableAlign | |
minWidth | int | |
maxWidth | int? |
TableRender
Constructor
dart
const TableRender({required this.headerLines, required this.rowLines})Properties
| Property | Type | Description |
|---|---|---|
headerLines | List<String> | |
rowLines | List<String> |
TableFormatter
Methods
`static TableRender format({
required List<TableColumn> columns,
required List<Map<String, String>> rows,
String gap = ' ',
int? maxTotalWidth,
bool includeHeader = true,
bool includeHeaderInWidth = true,
bool includeDivider = true,
String? headerStylePrefix = '\x1b[90m',
String? headerStyleSuffix = '\x1b[0m',
})`