copyWith method

SfChartThemeData copyWith({
  1. Brightness? brightness,
  2. Color? axisLabelColor,
  3. Color? axisLineColor,
  4. Color? axisTitleColor,
  5. Color? backgroundColor,
  6. Color? titleTextColor,
  7. Color? crosshairBackgroundColor,
  8. Color? crosshairLabelColor,
  9. Color? crosshairLineColor,
  10. Color? legendBackgroundColor,
  11. Color? legendTextColor,
  12. Color? legendTitleColor,
  13. Color? majorGridLineColor,
  14. Color? majorTickLineColor,
  15. Color? minorGridLineColor,
  16. Color? minorTickLineColor,
  17. Color? plotAreaBackgroundColor,
  18. Color? plotAreaBorderColor,
  19. Color? selectionRectColor,
  20. Color? selectionRectBorderColor,
  21. Color? selectionTooltipConnectorLineColor,
  22. Color? titleBackgroundColor,
  23. Color? tooltipColor,
  24. Color? tooltipSeparatorColor,
  25. Color? tooltipLabelColor,
  26. Color? waterfallConnectorLineColor,
  27. TextStyle? titleTextStyle,
  28. TextStyle? axisTitleTextStyle,
  29. TextStyle? axisLabelTextStyle,
  30. TextStyle? axisMultiLevelLabelTextStyle,
  31. TextStyle? plotBandLabelTextStyle,
  32. TextStyle? legendTitleTextStyle,
  33. TextStyle? legendTextStyle,
  34. TextStyle? dataLabelTextStyle,
  35. TextStyle? tooltipTextStyle,
  36. TextStyle? trackballTextStyle,
  37. TextStyle? crosshairTextStyle,
  38. TextStyle? selectionZoomingTooltipTextStyle,
})

Creates a copy of this chart theme data object with the matching fields replaced with the non-null parameter values.

Implementation

SfChartThemeData copyWith({
  Brightness? brightness,
  Color? axisLabelColor,
  Color? axisLineColor,
  Color? axisTitleColor,
  Color? backgroundColor,
  Color? titleTextColor,
  Color? crosshairBackgroundColor,
  Color? crosshairLabelColor,
  Color? crosshairLineColor,
  Color? legendBackgroundColor,
  Color? legendTextColor,
  Color? legendTitleColor,
  Color? majorGridLineColor,
  Color? majorTickLineColor,
  Color? minorGridLineColor,
  Color? minorTickLineColor,
  Color? plotAreaBackgroundColor,
  Color? plotAreaBorderColor,
  Color? selectionRectColor,
  Color? selectionRectBorderColor,
  Color? selectionTooltipConnectorLineColor,
  Color? titleBackgroundColor,
  Color? tooltipColor,
  Color? tooltipSeparatorColor,
  Color? tooltipLabelColor,
  Color? waterfallConnectorLineColor,
  TextStyle? titleTextStyle,
  TextStyle? axisTitleTextStyle,
  TextStyle? axisLabelTextStyle,
  TextStyle? axisMultiLevelLabelTextStyle,
  TextStyle? plotBandLabelTextStyle,
  TextStyle? legendTitleTextStyle,
  TextStyle? legendTextStyle,
  TextStyle? dataLabelTextStyle,
  TextStyle? tooltipTextStyle,
  TextStyle? trackballTextStyle,
  TextStyle? crosshairTextStyle,
  TextStyle? selectionZoomingTooltipTextStyle,
}) {
  return SfChartThemeData.raw(
    brightness: brightness,
    axisLabelColor: axisLabelColor ?? this.axisLabelColor,
    axisLineColor: axisLineColor ?? this.axisLineColor,
    axisTitleColor: axisTitleColor ?? this.axisTitleColor,
    backgroundColor: backgroundColor ?? this.backgroundColor,
    titleTextColor: titleTextColor ?? this.titleTextColor,
    crosshairBackgroundColor:
        crosshairBackgroundColor ?? this.crosshairBackgroundColor,
    crosshairLabelColor: crosshairLabelColor ?? this.crosshairLabelColor,
    crosshairLineColor: crosshairLineColor ?? this.crosshairLineColor,
    legendBackgroundColor:
        legendBackgroundColor ?? this.legendBackgroundColor,
    legendTextColor: legendTextColor ?? this.legendTextColor,
    legendTitleColor: legendTitleColor ?? this.legendTitleColor,
    majorGridLineColor: majorGridLineColor ?? this.majorGridLineColor,
    majorTickLineColor: majorTickLineColor ?? this.majorTickLineColor,
    minorGridLineColor: minorGridLineColor ?? this.minorGridLineColor,
    minorTickLineColor: minorTickLineColor ?? this.minorTickLineColor,
    plotAreaBackgroundColor:
        plotAreaBackgroundColor ?? this.plotAreaBackgroundColor,
    plotAreaBorderColor: plotAreaBorderColor ?? this.plotAreaBackgroundColor,
    selectionRectColor: selectionRectColor ?? this.selectionRectColor,
    selectionRectBorderColor:
        selectionRectBorderColor ?? this.selectionRectBorderColor,
    selectionTooltipConnectorLineColor: selectionTooltipConnectorLineColor ??
        this.selectionTooltipConnectorLineColor,
    titleBackgroundColor: titleBackgroundColor ?? this.titleBackgroundColor,
    tooltipColor: tooltipColor ?? this.tooltipColor,
    tooltipSeparatorColor:
        tooltipSeparatorColor ?? this.tooltipSeparatorColor,
    tooltipLabelColor: tooltipLabelColor ?? this.tooltipLabelColor,
    waterfallConnectorLineColor:
        waterfallConnectorLineColor ?? this.waterfallConnectorLineColor,
    titleTextStyle: titleTextStyle ?? this.titleTextStyle,
    axisTitleTextStyle: axisTitleTextStyle ?? this.axisTitleTextStyle,
    axisLabelTextStyle: axisLabelTextStyle ?? this.axisLabelTextStyle,
    axisMultiLevelLabelTextStyle:
        axisMultiLevelLabelTextStyle ?? this.axisMultiLevelLabelTextStyle,
    plotBandLabelTextStyle:
        plotBandLabelTextStyle ?? this.plotBandLabelTextStyle,
    legendTitleTextStyle: legendTitleTextStyle ?? this.legendTitleTextStyle,
    legendTextStyle: legendTextStyle ?? this.legendTextStyle,
    dataLabelTextStyle: dataLabelTextStyle ?? this.dataLabelTextStyle,
    tooltipTextStyle: tooltipTextStyle ?? this.tooltipTextStyle,
    trackballTextStyle: trackballTextStyle ?? this.trackballTextStyle,
    crosshairTextStyle: crosshairTextStyle ?? this.crosshairTextStyle,
    selectionZoomingTooltipTextStyle: selectionZoomingTooltipTextStyle ??
        this.selectionZoomingTooltipTextStyle,
  );
}