SimpleBoxPlotChart constructor

const SimpleBoxPlotChart({
  1. Key? key,
  2. required List<SimpleBoxPlotData> data,
  3. SimpleBarChartStyle style = SimpleBarChartStyle.elegant,
  4. double? minValue,
  5. double? maxValue,
  6. double height = 260,
  7. EdgeInsets padding = _defaultPadding,
  8. List<Color>? palette,
  9. Color? boxColor,
  10. Color? whiskerColor,
  11. Color? medianColor,
  12. Color? meanColor,
  13. Color? outlierColor,
  14. Color? gridColor,
  15. Color? axisColor,
  16. Color? activeColor,
  17. TextStyle? labelStyle,
  18. TextStyle? valueStyle,
  19. bool showGrid = true,
  20. bool showValues = true,
  21. bool showMean = true,
  22. bool showOutliers = true,
  23. bool showTooltip = true,
  24. bool showActiveBox = true,
  25. List<SimpleChartReferenceLine> referenceLines = const [],
  26. List<SimpleChartReferenceBand> referenceBands = const [],
  27. int gridLineCount = 4,
  28. double? boxWidthFactor,
  29. double? strokeWidth,
  30. double? outlierRadius,
  31. SimpleBoxPlotValueFormatter? valueFormatter,
  32. SimpleBoxPlotTapCallback? onBoxTap,
  33. SimpleBoxPlotTooltipBuilder? tooltipBuilder,
  34. WidgetBuilder? emptyBuilder,
  35. String? semanticLabel,
  36. bool excludeFromSemantics = false,
  37. Duration animationDuration = const Duration(milliseconds: 700),
  38. Curve animationCurve = Curves.easeOutCubic,
})

Implementation

const SimpleBoxPlotChart({
  super.key,
  required this.data,
  this.style = SimpleBarChartStyle.elegant,
  this.minValue,
  this.maxValue,
  this.height = 260,
  this.padding = _defaultPadding,
  this.palette,
  this.boxColor,
  this.whiskerColor,
  this.medianColor,
  this.meanColor,
  this.outlierColor,
  this.gridColor,
  this.axisColor,
  this.activeColor,
  this.labelStyle,
  this.valueStyle,
  this.showGrid = true,
  this.showValues = true,
  this.showMean = true,
  this.showOutliers = true,
  this.showTooltip = true,
  this.showActiveBox = true,
  this.referenceLines = const [],
  this.referenceBands = const [],
  this.gridLineCount = 4,
  this.boxWidthFactor,
  this.strokeWidth,
  this.outlierRadius,
  this.valueFormatter,
  this.onBoxTap,
  this.tooltipBuilder,
  this.emptyBuilder,
  this.semanticLabel,
  this.excludeFromSemantics = false,
  this.animationDuration = const Duration(milliseconds: 700),
  this.animationCurve = Curves.easeOutCubic,
}) : assert(height > 0),
     assert(gridLineCount >= 2),
     assert(
       boxWidthFactor == null || (boxWidthFactor > 0 && boxWidthFactor <= 1),
     ),
     assert(strokeWidth == null || strokeWidth > 0),
     assert(outlierRadius == null || outlierRadius >= 0);