VerticalRangeAnnotation constructor

VerticalRangeAnnotation({
  1. required double x1,
  2. required double x2,
  3. Color? color,
  4. Gradient? gradient,
})

Annotates a vertical region from most bottom to most top point of the chart, and from x1 to x2, and fills the area with color or gradient.

Implementation

VerticalRangeAnnotation({
  required this.x1,
  required this.x2,
  Color? color,
  this.gradient,
}) : color = color ??
          ((color == null && gradient == null) ? Colors.white : null);