Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extra border on BarChartData #143

Closed
chengweiou opened this issue Dec 22, 2019 · 4 comments
Closed

Extra border on BarChartData #143

chengweiou opened this issue Dec 22, 2019 · 4 comments
Labels
bug Something isn't working

Comments

@chengweiou
Copy link

cannot set up custom border

BarChart(
            BarChartData(
              alignment: BarChartAlignment.spaceAround,
              barTouchData: BarTouchData(enabled: false),
              titlesData: FlTitlesData(
                show: true,
                leftTitles: SideTitles(
                  showTitles: false,
                ),
                rightTitles: SideTitles(
                  showTitles: true,
                  interval: 500,
                  getTitles: (v) => v.toInt().toString(),
                  textStyle: TextStyle(fontSize: 8, color: Colors.grey),
                ),
              ),
              barGroups: [
                BarChartGroupData(
                  x: 0,
                  barRods: [BarChartRodData(y: 2015, width: 25, isRound: false, color: Colors.lightBlueAccent)],
                  barsSpace: 10,
                ),
                BarChartGroupData(
                  x: 1,
                  barRods: [BarChartRodData(y: 2390, width: 25, isRound: false, color: Colors.lightBlueAccent)],
                ),
                BarChartGroupData(
                  x: 2,
                  barRods: [BarChartRodData(y: 2015, width: 25, isRound: false, color: Colors.lightBlueAccent)],
                ),
                BarChartGroupData(
                  x: 3,
                  barRods: [BarChartRodData(y: 2015, width: 25, isRound: false, color: Colors.lightBlueAccent)],
                ),
                BarChartGroupData(
                  x: 3,
                  barRods: [BarChartRodData(y: 1915, width: 25, isRound: false, color: Colors.lightBlueAccent)],
                ),
                BarChartGroupData(
                  x: 3,
                  barRods: [BarChartRodData(y: 1922, width: 25, isRound: false, color: Colors.lightBlueAccent)],
                ),
              ],
              borderData: FlBorderData(
                border: Border(top: BorderSide.none, right: BorderSide.none,)
              ),
              gridData: FlGridData(
                show: true,
                checkToShowHorizontalLine: (v) => v % 500 == 0,
              ),
            ),
          ),

focus on FlBorderData;
if show=false -> no border
if border: Border(top: BorderSide.none, right: BorderSide.none,) -> no different to default
if border: Border(top: BorderSide.none, right: BorderSide(color: Colors.grey),) -> will be two border on right side

@afinas-em
Copy link

try this.
borderData: FlBorderData(border: Border.all(width: 0.0))

imaNNeo added a commit that referenced this issue Jan 4, 2020
fixed drawing border with 0.0 width and Border.none, #143
@imaNNeo imaNNeo added the bug Something isn't working label Jan 4, 2020
@imaNNeo
Copy link
Owner

imaNNeo commented Jan 4, 2020

Sever bug from day one :)
Thanks for reporting, it has just been fixed,
I will let you know when we released the new version, be patient.
Thanks!

@imaNNeo
Copy link
Owner

imaNNeo commented Jan 6, 2020

Fixed in 0.6.3, check it out.
Thanks for reporting.

@imaNNeo imaNNeo closed this as completed Jan 6, 2020
@chengweiou
Copy link
Author

@imaNNeoFighT fixed, thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants