copyWith method

  1. @override
TextCell<T> copyWith({
  1. T? itemContent,
  2. String itemToString(
    1. T
    )?,
  3. double? cellWidth,
  4. double? cellHeight,
  5. double? textSize,
  6. AlignmentGeometry? textAlignment,
  7. Color? backgroundColor,
  8. Color? textColor,
  9. Color? borderColor,
  10. bool? isBold,
  11. bool? isItalic,
  12. bool? isUnderline,
  13. bool? isAmount,
  14. CellNumberFormat? numberFormatType,
  15. RoundMode? roundMode,
  16. int? roundTo,
  17. void onTap(
    1. T
    )?,
})
override

Creates a copy of this TextCell with updated properties.

This is used by the layout engine to inject calculated dimensions during the build phase.

Implementation

@override
TextCell<T> copyWith({
  T? itemContent,
  String Function(T)? itemToString,
  double? cellWidth,
  double? cellHeight,
  double? textSize,
  AlignmentGeometry? textAlignment,
  Color? backgroundColor,
  Color? textColor,
  Color? borderColor,
  bool? isBold,
  bool? isItalic,
  bool? isUnderline,
  bool? isAmount,
  CellNumberFormat? numberFormatType,
  RoundMode? roundMode,
  int? roundTo,
  void Function(T)? onTap,
}) {
  return TextCell<T>(
    key: key,
    itemContent: itemContent ?? this.itemContent,
    itemToString: itemToString ?? this.itemToString,
    cellWidth: cellWidth ?? this.cellWidth,
    cellHeight: cellHeight ?? this.cellHeight,
    textSize: textSize ?? this.textSize,
    textAlignment: textAlignment ?? this.textAlignment,
    backgroundColor: backgroundColor ?? this.backgroundColor,
    textColor: textColor ?? this.textColor,
    borderColor: borderColor ?? this.borderColor,
    isBold: isBold ?? this.isBold,
    isItalic: isItalic ?? this.isItalic,
    isUnderline: isUnderline ?? this.isUnderline,
    isAmount: isAmount ?? this.isAmount,
    numberFormatType: numberFormatType ?? this.numberFormatType,
    roundMode: roundMode ?? this.roundMode,
    roundTo: roundTo ?? this.roundTo,
    onTap: onTap ?? this.onTap,
  );
}