BarChartConfig class

Configuration for bar charts with complete JSON support

Inheritance

Constructors

BarChartConfig({required List<Series> series, XYAxis? xAxis, XYAxis? yAxis, double? maxY, BarChartAlignment alignment = BarChartAlignment.spaceAround, double barWidth = 16.0, double? barBorderRadiusValue = 0.0, bool isStacked = false, bool isHorizontal = false, bool isMultiBar = false, TitlesData? title, ChartTooltip? tooltip, ChartLegend? legend, ChartToolbox? toolbox, GridData? grid, ChartTheme? theme, ChartController? controller, ChartAxisConfig? xAxisConfig, ChartAxisConfig? yAxisConfig})
BarChartConfig.fromJson(Map<String, dynamic> json)
Create bar chart config from JSON
factory

Properties

alignment BarChartAlignment
final
apiContract ChartApiContract
Shared API contract for all config-driven chart families.
no setterinherited
barBorderRadius BorderRadius
Get border radius from value
no setter
barBorderRadiusValue double?
final
barWidth double
final
controller ChartController?
finalinherited
grid GridData?
finalinherited
hashCode int
The hash code for this object.
no setterinherited
isHorizontal bool
final
isMultiBar bool
final
isStacked bool
final
legend ChartLegend?
finalinherited
maxY double?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
series List<Series>
finalinherited
theme ChartTheme
finalinherited
title TitlesData?
finalinherited
toolbox ChartToolbox?
finalinherited
tooltip ChartTooltip?
finalinherited
type ChartType
finalinherited
xAxis XYAxis?
final
xAxisConfig ChartAxisConfig?
finalinherited
yAxis XYAxis?
final
yAxisConfig ChartAxisConfig?
finalinherited

Methods

buildChart() Widget
Method to create the appropriate chart widget
override
copyWith({List<Series>? series, XYAxis? xAxis, XYAxis? yAxis, double? maxY, BarChartAlignment? alignment, double? barWidth, double? barBorderRadiusValue, bool? isStacked, bool? isHorizontal, bool? isMultiBar, TitlesData? title, ChartTooltip? tooltip, ChartLegend? legend, ChartToolbox? toolbox, GridData? grid, ChartTheme? theme, ChartController? controller, ChartAxisConfig? xAxisConfig, ChartAxisConfig? yAxisConfig}) BarChartConfig
getMaxSeriesValue() double
Calculate maximum value from series data with buffer
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
supportsApiField(String field) bool
inherited
toJson() Map<String, dynamic>
Convert configuration to JSON
override
toString() String
A string representation of this object.
inherited
withController(ChartController controller) BarChartConfig
Override in concrete configs to return a controller-attached copy.
override
withTheme(ChartTheme theme) BarChartConfig
Override in concrete configs to return a themed copy.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited