agentsclimarketplace

Syncfusion flutter cartesian charts

Skill syncfusion/flutter-ui-components-skills/skills/syncfusion-flutter-cartesian-charts

Implements Syncfusion Flutter Cartesian Charts (SfCartesianChart) for a wide range of 2D chart types in Flutter apps. Use when working with line, column, bar, area, spline, scatter, bubble, financial, stacked, or histogram charts. This skill covers axis types (NumericAxis, CategoryAxis, DateTimeAxis), zoom and pan, tooltip, trackball, legend, annotations, technical indicators, trendlines, and chart export.From its SKILL.md

Install
npx -y skills add syncfusion/flutter-ui-components-skills --skill syncfusion-flutter-cartesian-charts

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

9.7 KB, ~2.3k tokens by cl100k_base, as published. Nobody here has run it

Implementing Syncfusion Flutter Cartesian Charts

SfCartesianChart is a high-performance Flutter widget from the syncfusion_flutter_charts package that supports 30+ chart types plotted on Cartesian (X/Y) coordinates. It handles real-time data, rich interactivity, and deep customization.

When to Use This Skill

Use this skill when you need to:

  • Render any line, area, column, bar, spline, scatter, or financial chart in Flutter
  • Configure axis types (numeric, category, date-time, logarithmic)
  • Add zooming, panning, tooltip, trackball, or crosshair interaction
  • Customize series appearance (colors, gradients, markers, data labels)
  • Add annotations, technical indicators, or trendlines
  • Export charts or respond to chart callbacks
  • Support RTL, localization, or accessibility

Component Overview

The SfCartesianChart widget is a comprehensive charting solution that displays data using Cartesian (X/Y) coordinates. It supports over 30 chart types across multiple categories:

  • Line Charts: Line, fast line, spline (various tension types), step line
  • Area Charts: Area, spline area, step area, range area, spline range area, stacked area (including 100%)
  • Column/Bar Charts: Column, bar, range column, stacked column/bar (including 100%)
  • Scatter/Bubble: Scatter, bubble charts
  • Financial Charts: Candle, OHLC, HiLo, HiLoOpenClose with support for technical indicators
  • Statistical: Histogram, box and whisker, error bar
  • Waterfall: For cumulative effect visualization

The widget provides five axis types (Numeric, Category, DateTime, DateTimeCategory, Logarithmic), interactive features (zoom, pan, tooltip, trackball, crosshair), selection behaviors, rich customization (markers, data labels, gradients, animations), technical indicators (SMA, EMA, MACD, RSI, Bollinger Bands, etc.), trendlines, annotations, and chart export capabilities.


Quick Start

# Always installs the latest compatible version automatically
flutter pub add syncfusion_flutter_charts

Always install the package via terminal β€” do not edit pubspec.yaml directly. Run this command from the Flutter project root and wait for it to complete successfully before proceeding.

import 'package:syncfusion_flutter_charts/charts.dart';

class MyChart extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return SizedBox(
      height: 300,
      child: SfCartesianChart(
        primaryXAxis: CategoryAxis(),
        title: ChartTitle(text: 'Monthly Sales'),
        legend: Legend(isVisible: true),
        tooltipBehavior: TooltipBehavior(enable: true),
        series: <CartesianSeries>[
          LineSeries<ChartData, String>(
            dataSource: [
              ChartData('Jan', 35),
              ChartData('Feb', 28),
              ChartData('Mar', 34),
              ChartData('Apr', 32),
              ChartData('May', 40),
            ],
            xValueMapper: (ChartData d, _) => d.x,
            yValueMapper: (ChartData d, _) => d.y,
            name: 'Sales',
            dataLabelSettings: DataLabelSettings(isVisible: true),
          ),
        ],
      ),
    );
  }
}

class ChartData {
  ChartData(this.x, this.y);
  final String x;
  final double? y;
}

Navigation Guide

Getting Started

πŸ“„ Read: references/getting-started.md

  • Package installation and import
  • Initialize SfCartesianChart
  • Bind data source and data model
  • Add title, data labels, legend, tooltip
  • Complete minimal working example

Line, Area & Spline Chart Types

πŸ“„ Read: references/chart-types-line-area.md

  • Line, fast line, spline (with spline types)
  • Step line, area, spline area
  • Step area, range area, spline range area
  • When to use each type

Column, Bar & Other Cartesian Types

πŸ“„ Read: references/chart-types-column-bar.md

  • Column, bar, range column
  • Bubble, scatter, histogram
  • Waterfall, error bar, box and whisker
  • Key configuration for each type

Stacked Chart Types

πŸ“„ Read: references/chart-types-stacked.md

  • Stacked area/bar/column/line
  • 100% stacked variants
  • When to choose stacked vs 100% stacked

Financial Chart Types

πŸ“„ Read: references/chart-types-financial.md

  • Candle, HILO, OHLC charts
  • Financial data model (open/high/low/close mappers)
  • Hollow candle and solid candle

Axis Types

πŸ“„ Read: references/axis-types.md

  • NumericAxis, CategoryAxis, DateTimeAxis
  • DateTimeCategoryAxis, LogarithmicAxis
  • Choosing the right axis for your data

Axis Customization

πŸ“„ Read: references/axis-customization.md

  • Title, labels, label format
  • Gridlines, tick marks, range (min/max/interval)
  • Strip lines, multi-level labels
  • Secondary axis, axis crossing, inversed axis

Series Customization

πŸ“„ Read: references/series-customization.md

  • Color, border, opacity, gradient fill
  • Dash array, width, point color mapper
  • Animation, palette colors, empty point settings

Legend

πŸ“„ Read: references/legend.md

  • Enable and position legend
  • Toggle series visibility via legend
  • Overflow modes (wrap, scroll)
  • Custom legend items and icons

Tooltip, Trackball & Crosshair

πŸ“„ Read: references/tooltip-trackball.md

  • TooltipBehavior β€” enable, format, custom template
  • Shared tooltip across series
  • TrackballBehavior β€” display modes
  • CrosshairBehavior configuration

Zooming, Panning & Selection

πŸ“„ Read: references/zoom-pan-selection.md

  • ZoomPanBehavior β€” pinch, mouse wheel, directional
  • ZoomMode (x, y, xy), panning
  • Auto-scrolling for live data
  • SelectionBehavior β€” point, series, cluster, box

Annotations, Markers & Data Labels

πŸ“„ Read: references/annotations-markers-datalabels.md

  • CartesianChartAnnotation β€” text and widget overlays
  • Coordinate units (point vs pixel vs percent)
  • MarkerSettings β€” shape, size, color
  • DataLabelSettings β€” position, format, template, connector lines

Technical Indicators & Trendlines

πŸ“„ Read: references/technical-indicators-trendlines.md

  • SMA, EMA, TMA, WMA, MACD, RSI, Stochastic
  • Bollinger Bands, ATR, CCI, Momentum, AD, ROC
  • Trendline types (linear, exponential, polynomial, moving average, power, logarithmic)
  • Forecasting periods

Chart Appearance & Multiple Charts

πŸ“„ Read: references/chart-appearance.md

  • Background color/image, plot area customization
  • Color palette, theme integration
  • Rendering multiple charts on the same screen
  • On-demand / lazy data loading

Callbacks, Methods, Export & Accessibility

πŸ“„ Read: references/callbacks-methods-export.md

  • Key callbacks (onTooltipRender, onDataLabelRender, onZooming, etc.)
  • ChartSeriesController methods (updateDataSource, animate)
  • Export to PNG, PDF, JPEG
  • Localization, RTL, accessibility

Common Patterns

Pattern 1 β€” Live / Real-Time Data Update

late ChartSeriesController _controller;

onRendererCreated: (ChartSeriesController controller) {
  _controller = controller;
},

void addDataPoint(ChartData newPoint) {
  chartData.add(newPoint);
  _controller.updateDataSource(
    addedDataIndexes: [chartData.length - 1],
  );
}

Pattern 2 β€” Multiple Series on One Chart

series: <CartesianSeries>[
  LineSeries<ChartData, String>(
    dataSource: data,
    xValueMapper: (d, _) => d.x,
    yValueMapper: (d, _) => d.y1,
    name: 'Revenue',
  ),
  ColumnSeries<ChartData, String>(
    dataSource: data,
    xValueMapper: (d, _) => d.x,
    yValueMapper: (d, _) => d.y2,
    name: 'Cost',
  ),
]

Pattern 3 β€” Zoom + Tooltip Together

late ZoomPanBehavior _zoom;
late TooltipBehavior _tooltip;

@override
void initState() {
  _zoom = ZoomPanBehavior(enablePinching: true, enableDoubleTapZooming: true);
  _tooltip = TooltipBehavior(enable: true);
  super.initState();
}

zoomPanBehavior: _zoom,
tooltipBehavior: _tooltip,

Key Widget Properties

PropertyTypePurpose
primaryXAxisChartAxisHorizontal axis type and config
primaryYAxisChartAxisVertical axis type and config
seriesList<CartesianSeries>One or more data series
titleChartTitleChart heading text
legendLegendLegend visibility and position
tooltipBehaviorTooltipBehaviorTooltip on tap
zoomPanBehaviorZoomPanBehaviorZoom and pan interaction
selectionTypeSelectionTypePoint/series/cluster selection
annotationsList<CartesianChartAnnotation>Overlay widgets/text
indicatorsList<TechnicalIndicator>Technical analysis overlays
onTooltipRenderChartTooltipCallbackCustomize tooltip text
onZoomingChartZoomingCallbackRespond to zoom events
paletteList<Color>Custom series color palette

What ships with it: 15 files

63.9 KB alongside SKILL.md

Keep looking

Skills are one crate of 326,696. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.