Skip to content

Commit

Permalink
fix: change canvas drawing order in RadarChartPainter - drawGrids() a…
Browse files Browse the repository at this point in the history
…fter drawTicks(), drawDataSets()
  • Loading branch information
frybitsinc committed Nov 6, 2024
1 parent da270ae commit 8c5e010
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion example/lib/presentation/samples/chart_samples.dart
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class ChartSamples {
ScatterChartSample(2, (context) => const ScatterChartSample2()),
],
ChartType.radar: [
// RadarChartSample(1, (context) => RadarChartSample1()),
RadarChartSample(1, (context) => RadarChartSample1()),
RadarChartSample(2, (context) => RadarChartSample2()),
],
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ class _RadarChartSample2State extends State<RadarChartSample2> {
RadarChartData(
elevation: 10,
radarShape: RadarShape.polygon,
radarBackgroundColor: Colors.white,
radarBackgroundColor: Colors.amber,
radarShadowColor: Colors.white,
radarTouchData: RadarTouchData(
touchCallback: (FlTouchEvent event, response) {
Expand Down
2 changes: 1 addition & 1 deletion lib/src/chart/radar_chart/radar_chart_painter.dart
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,10 @@ class RadarChartPainter extends BaseChartPainter<RadarChartData> {

dataSetsPosition = calculateDataSetsPosition(canvasWrapper.size, holder);

drawGrids(canvasWrapper, holder);
drawTicks(context, canvasWrapper, holder);
drawTitles(context, canvasWrapper, holder);
drawDataSets(canvasWrapper, holder);
drawGrids(canvasWrapper, holder);
}

@visibleForTesting
Expand Down

0 comments on commit 8c5e010

Please sign in to comment.