Questions tagged [fl-chart]

fl-chart is a powerful Flutter chart library, currently supporting Line Chart, Bar Chart and Pie Chart.

FL Chart is a library to draw charts in Flutter.

It's used to create Line Charts, Bar Charts, Pie Charts, Scatter Charts and many more.

Here you can find examples on GitHub.

95 questions
0
votes
0 answers

How to zoom in and out in fl_chart flutter?

I am using fl_chart library for line chart, but there is no option for zoom in out chart, how to zoom fl line chart?
Kokila
  • 242
  • 1
  • 13
0
votes
0 answers

fl_chart bar chart clip out of chartbox

I have been using fl_chart for making a barChart with usage over time (displaying : week/month/year). I don't quite understand why when i pass from one to another display the bar does the following: fl_chart bug clip out of the box My chartwidget…
weaked
  • 5
  • 1
  • 3
0
votes
1 answer

Flutter Data in Bar Chart - fl_chart

I need to plot a chart and I am struggling to do it. Below is my data. [ { "#": "396", "%": "5.38", "month": "Apr", "year": "2022", "createdAt": "19-Apr-2022 (17:09:09.860499)", "id":…
Hwebservices
  • 63
  • 3
  • 11
0
votes
2 answers

Flutter FLCharts Grid not rendering correctly

I am showing a chart in my Flutter App using fl_chart library. I am trying to show spots with an y value of either 1, 2, or 3 and I want to draw a horizontal line on the chart on the values 1, 2 and 3. Here is my code: class MyChart extends…
Apri
  • 1,241
  • 1
  • 8
  • 33
0
votes
1 answer

Flutter - void Function(FlTouchEvent) can't be assigned to the parameter type void Function

So I cloned this project and put all the code into one file: https://github.com/JohannesMilke/fl_pie_chart_example However, I'm getting an error, and cannot run the code with the stable Flutter version I have (2.8.1). It complains about: The…
N90J
  • 57
  • 7
0
votes
0 answers

fl_chart axis title not aligning with the bar when rotateAngle is used

I'm using fl_chart for platting a bar chart in the Flutter application. I have lengthy titles for the x-axis units and the issue I'm seeing is, more the length of the title more the alignment goes for a toss. In the below chart, x-axis titles with…
Nikhil Bharadwaj
  • 867
  • 4
  • 24
  • 42
0
votes
1 answer

How to change color of this floating element in LineChart (fl_chart)?

I cannot understand how to change the color of this floating element. Right now, it is greenish/greish. I would like it to be this exact color: Color(0xFF3238a4). Also, its text is blue, i would like to change it to Colors.white. I tried to read all…
iocomxda
  • 73
  • 8
0
votes
1 answer

FlSpot data Flutter

I use FL Chart in my Flutter Apps but i too many repeat my code, can i make it to use i++ here my code final LineChartBarData lineChartBarData1 = LineChartBarData( spots: [ FlSpot(00.00, (dataAcc[50]['x'] / 1.00)), …
KAnggara75
  • 103
  • 1
  • 8
0
votes
1 answer

Icons as titles with fl_chart?

I'm creating a simple bar chart with fl_chart (below) and need to use icons as x titles (rather than text). E.g., replace 0, 1, 2, 3 below with icons. Below is the code that generates the current bar chart. Is it possible to add icons/PNGs as…
buttonsrtoys
  • 2,359
  • 3
  • 32
  • 52
0
votes
0 answers

fl_chart custom Legend gets pushed down when section is empty

I'm using the PieChart of fl_chart to display the distribution of locally saved documents. The percentages displayed in the chart are the result of the length of the two document type lists (See image below). But when one List is empty I have a…
JonasLevin
  • 1,592
  • 1
  • 20
  • 50
0
votes
1 answer

How to display children with in a card widget, and one of the child is fl bar chart?

This is the error that appeared on my terminal when I run the flutter run command. How can I have two children inside a card without overflowing or extending its size to infinity?? The following RenderObject was being processed when the exception…
0
votes
2 answers

How to get a single tooltip when there are multiple lineBarsData FlChart

I'm using this package https://pub.dev/packages/fl_chart and and there is the possibility of when you move the mouse over a line of the graph to show a tooltip with the data but of all the lines on the graph. This is what happen now. I attach an…
Nico
  • 166
  • 1
  • 12
0
votes
1 answer

fl_chart Wrap PieChartSectionData with widget

I am trying to create a pie chart with the fl_chart package and am wondering if i can wrap element in sections with flutter widget. ... PieChart( PieChartData( pieTouchData:…
Ahmad Haziq
  • 91
  • 1
  • 9
0
votes
0 answers

What caused an error when drawing a bottom titles in linear chart using fl_chart packages

The error stated 'RangeError (index): Invalid value: Not in inclusive range 0..11: 15' Example of the list element getDays = [30 Aug, 31 Aug, 01 Sep, 02 Sep, 03 Sep, 04 Sep, 05 Sep, 06 Sep, 07 Sep, 08 Sep, 09 Sep, 10 Sep] The shorter list cause the…
0
votes
1 answer

How to rotate text in flutter charts?

I am trying to design a chart in a flutter app that displays data graphed against time or day (depending on a button press), however, I am running into an issue where the graph label text runs into each other. I was wondering if there is a way to…
mojojojo
  • 157
  • 1
  • 8