copyWith method

FlGridData copyWith({
  1. bool? show,
  2. bool? drawHorizontalLine,
  3. double? horizontalInterval,
  4. GetDrawingGridLine? getDrawingHorizontalLine,
  5. CheckToShowGrid? checkToShowHorizontalLine,
  6. bool? drawVerticalLine,
  7. double? verticalInterval,
  8. GetDrawingGridLine? getDrawingVerticalLine,
  9. CheckToShowGrid? checkToShowVerticalLine,
})

Copies current FlGridData to a new FlGridData, and replaces provided values.

Implementation

FlGridData copyWith({
  bool? show,
  bool? drawHorizontalLine,
  double? horizontalInterval,
  GetDrawingGridLine? getDrawingHorizontalLine,
  CheckToShowGrid? checkToShowHorizontalLine,
  bool? drawVerticalLine,
  double? verticalInterval,
  GetDrawingGridLine? getDrawingVerticalLine,
  CheckToShowGrid? checkToShowVerticalLine,
}) {
  return FlGridData(
    show: show ?? this.show,
    drawHorizontalLine: drawHorizontalLine ?? this.drawHorizontalLine,
    horizontalInterval: horizontalInterval ?? this.horizontalInterval,
    getDrawingHorizontalLine:
        getDrawingHorizontalLine ?? this.getDrawingHorizontalLine,
    checkToShowHorizontalLine:
        checkToShowHorizontalLine ?? this.checkToShowHorizontalLine,
    drawVerticalLine: drawVerticalLine ?? this.drawVerticalLine,
    verticalInterval: verticalInterval ?? this.verticalInterval,
    getDrawingVerticalLine:
        getDrawingVerticalLine ?? this.getDrawingVerticalLine,
    checkToShowVerticalLine:
        checkToShowVerticalLine ?? this.checkToShowVerticalLine,
  );
}