SimpleBulletChart constructor
const
SimpleBulletChart({
- Key? key,
- required List<
SimpleBulletChartData> data, - SimpleBarChartStyle style = SimpleBarChartStyle.elegant,
- double height = 220,
- EdgeInsets padding = _defaultPadding,
- Color? valueColor,
- Color? targetColor,
- Color? rangeColor,
- Color? activeColor,
- TextStyle? labelStyle,
- TextStyle? valueStyle,
- bool showLabels = true,
- bool showValues = true,
- bool showTooltip = true,
- bool showActiveBar = true,
- double? barHeightFactor,
- double? valueHeightFactor,
- double? targetWidth,
- SimpleBulletValueFormatter? valueFormatter,
- SimpleBulletTapCallback? onBulletTap,
- SimpleBulletTooltipBuilder? tooltipBuilder,
- WidgetBuilder? emptyBuilder,
- String? semanticLabel,
- bool excludeFromSemantics = false,
- Duration animationDuration = const Duration(milliseconds: 650),
- Curve animationCurve = Curves.easeOutCubic,
Implementation
const SimpleBulletChart({
super.key,
required this.data,
this.style = SimpleBarChartStyle.elegant,
this.height = 220,
this.padding = _defaultPadding,
this.valueColor,
this.targetColor,
this.rangeColor,
this.activeColor,
this.labelStyle,
this.valueStyle,
this.showLabels = true,
this.showValues = true,
this.showTooltip = true,
this.showActiveBar = true,
this.barHeightFactor,
this.valueHeightFactor,
this.targetWidth,
this.valueFormatter,
this.onBulletTap,
this.tooltipBuilder,
this.emptyBuilder,
this.semanticLabel,
this.excludeFromSemantics = false,
this.animationDuration = const Duration(milliseconds: 650),
this.animationCurve = Curves.easeOutCubic,
}) : assert(height > 0),
assert(
barHeightFactor == null ||
(barHeightFactor > 0 && barHeightFactor <= 1),
),
assert(
valueHeightFactor == null ||
(valueHeightFactor > 0 && valueHeightFactor <= 1),
),
assert(targetWidth == null || targetWidth > 0);