SpiderChartThemeData constructor
const
SpiderChartThemeData({
- Color gridLineColor = const Color(0x4D9E9E9E),
- Color gridDashedLineColor = const Color(0x337B4DFF),
- Color spokeLineColor = const Color(0x1A9E9E9E),
- Color dataLineColor = const Color(0xFF7B4DFF),
- Color dataFillColor = const Color(0x267B4DFF),
- bool useGradient = false,
- List<
Color> ? gradientColors, - List<
Color> ? dataLineGradientColors, - List<
Color> ? gridLineGradientColors, - List<
Color> ? centerCircleGradientColors, - Color? centerCircleColor,
- TextStyle labelStyle = const TextStyle(color: Colors.black87, fontSize: 10, fontWeight: FontWeight.w500),
- TextStyle selectedLabelStyle = const TextStyle(color: Color(0xFF7B4DFF), fontSize: 12, fontWeight: FontWeight.bold),
- bool showSelectedLabel = true,
- bool? showTitleSelectedLabel,
- TitleLabelMode titleLabelMode = TitleLabelMode.hidden,
- TitleLabelBehavior titleLabelBehavior = TitleLabelBehavior.always,
- double titleSlideSpace = 40.0,
- bool enableTitleSlide = true,
- Duration titleSlideDuration = const Duration(milliseconds: 450),
- Curve titleSlideCurve = Curves.easeInOutCubic,
- bool useSpline = false,
- TextStyle titleSelectedLabelStyle = const TextStyle(color: Colors.black87, fontSize: 16, fontWeight: FontWeight.bold),
- double titleSelectedLabelTopOffset = 0.0,
- double chartTopOffset = 0.0,
- double labelOffsetFromChart = 10.0,
- double labelRadiusFactor = 1.0,
- double bubbleOffset = 10.0,
- double strokeWidth = 3.0,
- double pointSize = 4.0,
- Color pointColor = const Color(0xFF7B4DFF),
- bool rotateToTop = true,
- Duration rotationDuration = const Duration(milliseconds: 500),
- TriangleDirection triangleDirection = TriangleDirection.down,
- bool autoTriangleDirection = true,
- BubbleAnchor bubbleAnchor = BubbleAnchor.label,
- double bottomPadding = 0.0,
- bool autoHeightAdjustment = true,
Implementation
const SpiderChartThemeData({
this.gridLineColor = const Color(
0x4D9E9E9E,
), // Colors.grey.withOpacity(0.3)
this.gridDashedLineColor = const Color(
0x337B4DFF,
), // Colors.deepPurple.withOpacity(0.2)
this.spokeLineColor = const Color(
0x1A9E9E9E,
), // Colors.grey.withOpacity(0.1)
this.dataLineColor = const Color(0xFF7B4DFF), // Colors.deepPurple
this.dataFillColor = const Color(
0x267B4DFF,
), // Colors.deepPurple.withOpacity(0.15)
this.useGradient = false,
this.gradientColors,
this.dataLineGradientColors,
this.gridLineGradientColors,
this.centerCircleGradientColors,
this.centerCircleColor,
this.labelStyle = const TextStyle(
color: Colors.black87,
fontSize: 10,
fontWeight: FontWeight.w500,
),
this.selectedLabelStyle = const TextStyle(
color: Color(0xFF7B4DFF),
fontSize: 12,
fontWeight: FontWeight.bold,
),
this.showSelectedLabel = true,
bool? showTitleSelectedLabel,
TitleLabelMode titleLabelMode = TitleLabelMode.hidden,
this.titleLabelBehavior = TitleLabelBehavior.always,
this.titleSlideSpace = 40.0,
this.enableTitleSlide = true,
this.titleSlideDuration = const Duration(milliseconds: 450),
this.titleSlideCurve = Curves.easeInOutCubic,
this.useSpline = false,
this.titleSelectedLabelStyle = const TextStyle(
color: Colors.black87,
fontSize: 16,
fontWeight: FontWeight.bold,
),
this.titleSelectedLabelTopOffset = 0.0,
this.chartTopOffset = 0.0,
this.labelOffsetFromChart = 10.0,
this.labelRadiusFactor = 1.0,
this.bubbleOffset = 10.0,
this.strokeWidth = 3.0,
this.pointSize = 4.0,
this.pointColor = const Color(0xFF7B4DFF),
this.rotateToTop = true,
this.rotationDuration = const Duration(milliseconds: 500),
this.triangleDirection = TriangleDirection.down,
this.autoTriangleDirection = true,
this.bubbleAnchor = BubbleAnchor.label,
this.bottomPadding = 0.0,
this.autoHeightAdjustment = true,
}) : titleLabelMode = showTitleSelectedLabel != null
? (showTitleSelectedLabel
? TitleLabelMode.shown
: TitleLabelMode.hidden)
: titleLabelMode,
// ignore: deprecated_member_use_from_same_package
showTitleSelectedLabel =
showTitleSelectedLabel ?? (titleLabelMode == TitleLabelMode.shown);