makeBarRendererElement method
BarRendererElement<D>
makeBarRendererElement({
- Color? color,
- List<
int> ? dashPattern, - required BarRendererElement<
D> details, - D? domainValue,
- required ImmutableAxis<
D> domainAxis, - required int domainWidth,
- num? measureValue,
- required num measureOffsetValue,
- required ImmutableAxis<
num> measureAxis, - double? measureAxisPosition,
- Color? fillColor,
- FillPatternType? fillPattern,
- double? strokeWidthPx,
- required int barGroupIndex,
- double? previousBarGroupWeight,
- double? barGroupWeight,
- List<
double> ? allBarGroupWeights, - required int numBarGroups,
- bool? measureIsNull,
- bool? measureIsNegative,
Generates a BarRendererElement
to represent the rendering data for one
bar on the chart.
Implementation
@override
BarRendererElement<D> makeBarRendererElement(
{Color? color,
List<int>? dashPattern,
required BarRendererElement<D> details,
D? domainValue,
required ImmutableAxis<D> domainAxis,
required int domainWidth,
num? measureValue,
required num measureOffsetValue,
required ImmutableAxis<num> measureAxis,
double? measureAxisPosition,
Color? fillColor,
FillPatternType? fillPattern,
double? strokeWidthPx,
required int barGroupIndex,
double? previousBarGroupWeight,
double? barGroupWeight,
List<double>? allBarGroupWeights,
required int numBarGroups,
bool? measureIsNull,
bool? measureIsNegative}) {
return BarRendererElement<D>()
..color = color
..dashPattern = dashPattern
..fillColor = fillColor
..fillPattern = fillPattern
..measureAxisPosition = measureAxisPosition
..roundPx = details.roundPx
..strokeWidthPx = strokeWidthPx
..measureIsNull = measureIsNull
..measureIsNegative = measureIsNegative
..bounds = _getBarBounds(
domainValue,
domainAxis,
domainWidth,
config.maxBarWidthPx,
measureValue,
measureOffsetValue,
measureAxis,
barGroupIndex,
previousBarGroupWeight,
barGroupWeight,
allBarGroupWeights,
numBarGroups);
}