BackgroundBarChartRodData constructor

BackgroundBarChartRodData({
  1. double? fromY,
  2. double? toY,
  3. bool? show,
  4. Color? color,
  5. Gradient? gradient,
})

It will be rendered in rear of the main rod, background starts to show from fromY to toY, It draws with color or gradient. You must provide one of them, you prevent to show it, using show property.

Implementation

BackgroundBarChartRodData({
  double? fromY,
  double? toY,
  bool? show,
  Color? color,
  this.gradient,
})  : fromY = fromY ?? 0,
      toY = toY ?? 0,
      show = show ?? false,
      color = color ??
          ((color == null && gradient == null) ? Colors.blueGrey : null);