Legend constructor
const
Legend({
- bool isVisible = false,
- LegendPosition position = LegendPosition.auto,
- ChartAlignment alignment = ChartAlignment.center,
- Color? backgroundColor,
- Color? borderColor,
- double borderWidth = 1.0,
- double opacity = 1.0,
- String? height,
- String? width,
- double padding = 10.0,
- double iconHeight = 12.0,
- double iconWidth = 12.0,
- bool shouldAlwaysShowScrollbar = false,
- bool toggleSeriesVisibility = true,
- TextStyle? textStyle,
- bool isResponsive = false,
- LegendItemOrientation orientation = LegendItemOrientation.auto,
- LegendTitle? title,
- LegendItemOverflowMode overflowMode = LegendItemOverflowMode.scroll,
- LegendItemBuilder? legendItemBuilder,
- Color? iconBorderColor,
- double? iconBorderWidth,
- double itemPadding = 15.0,
- Offset? offset,
- ImageProvider<
Object> ? image,
Creating an argument constructor of Legend class.
Implementation
const Legend({
this.isVisible = false,
this.position = LegendPosition.auto,
this.alignment = ChartAlignment.center,
this.backgroundColor,
this.borderColor,
this.borderWidth = 1.0,
this.opacity = 1.0,
this.height,
this.width,
this.padding = 10.0,
this.iconHeight = 12.0,
this.iconWidth = 12.0,
this.shouldAlwaysShowScrollbar = false,
this.toggleSeriesVisibility = true,
this.textStyle,
this.isResponsive = false,
this.orientation = LegendItemOrientation.auto,
this.title,
this.overflowMode = LegendItemOverflowMode.scroll,
this.legendItemBuilder,
this.iconBorderColor,
this.iconBorderWidth,
this.itemPadding = 15.0,
this.offset,
this.image,
});