ChartTheme constructor
const
ChartTheme({
- ChartPalette palette = ChartPalette.material,
- ChartTypography typography = const ChartTypography(),
- ChartSpacing spacing = const ChartSpacing(),
- Color backgroundColor = Colors.transparent,
- Color gridColor = const Color(0x1A000000),
- Color axisColor = const Color(0x33000000),
- Color axisLabelColor = const Color(0xFF666666),
- Color titleColor = const Color(0xFF1A1A1A),
- Color legendTextColor = const Color(0xFF444444),
- Color tooltipBackgroundColor = const Color(0xFF1A1A2E),
- Color tooltipTextColor = Colors.white,
- Color tooltipBorderColor = Colors.transparent,
- Color crosshairColor = const Color(0x44000000),
- Color highlightOverlayColor = Colors.white,
- double highlightOverlayOpacity = 0.15,
Implementation
const ChartTheme({
this.palette = ChartPalette.material,
this.typography = const ChartTypography(),
this.spacing = const ChartSpacing(),
this.backgroundColor = Colors.transparent,
this.gridColor = const Color(0x1A000000), // 10% black
this.axisColor = const Color(0x33000000), // 20% black
this.axisLabelColor = const Color(0xFF666666),
this.titleColor = const Color(0xFF1A1A1A),
this.legendTextColor = const Color(0xFF444444),
this.tooltipBackgroundColor = const Color(0xFF1A1A2E),
this.tooltipTextColor = Colors.white,
this.tooltipBorderColor = Colors.transparent,
this.crosshairColor = const Color(0x44000000),
this.highlightOverlayColor = Colors.white,
this.highlightOverlayOpacity = 0.15,
});