SSpreadsheet constructor
const
SSpreadsheet({
- Key? key,
- required int rowCount,
- required int columnCount,
- required SSpreadsheetCellBuilder cellBuilder,
- SSpreadsheetRowHeaderBuilder? rowHeaderBuilder,
- SSpreadsheetColumnHeaderBuilder? columnHeaderBuilder,
- WidgetBuilder? cornerBuilder,
- double rowHeaderWidth = 100,
- double headerHeight = 48,
- SSpreadsheetRowHeightBuilder? rowHeightBuilder,
- SSpreadsheetColumnWidthBuilder? columnWidthBuilder,
- EdgeInsetsGeometry padding = EdgeInsets.zero,
- EdgeInsetsGeometry rowPadding = EdgeInsets.zero,
- ScrollController? verticalController,
- ScrollPhysics? verticalPhysics,
- ScrollPhysics? horizontalPhysics,
- Color? backgroundColor,
- bool showColumnHeader = true,
- SSpreadsheetHorizontalMetricsChanged? onHorizontalMetricsChanged,
- SSpreadsheetHorizontalSyncController? horizontalSyncController,
- bool repaintBoundaryPerRow = false,
- Duration rowExtentAnimationDuration = Duration.zero,
- bool addAutomaticKeepAlives = false,
Implementation
const SSpreadsheet({
super.key,
required this.rowCount,
required this.columnCount,
required this.cellBuilder,
this.rowHeaderBuilder,
this.columnHeaderBuilder,
this.cornerBuilder,
this.rowHeaderWidth = 100,
this.headerHeight = 48,
this.rowHeightBuilder,
this.columnWidthBuilder,
this.padding = EdgeInsets.zero,
this.rowPadding = EdgeInsets.zero,
this.verticalController,
this.verticalPhysics,
this.horizontalPhysics,
this.backgroundColor,
this.showColumnHeader = true,
this.onHorizontalMetricsChanged,
this.horizontalSyncController,
this.repaintBoundaryPerRow = false,
this.rowExtentAnimationDuration = Duration.zero,
this.addAutomaticKeepAlives = false,
}) : assert(rowCount >= 0, 'rowCount must be >= 0'),
assert(columnCount >= 0, 'columnCount must be >= 0'),
assert(rowHeaderWidth >= 0, 'rowHeaderWidth must be >= 0'),
assert(headerHeight >= 0, 'headerHeight must be >= 0');