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

How to set the position of the values top on BarChartView? #2759

Closed
guanyanlin opened this issue Aug 29, 2017 · 3 comments
Closed

How to set the position of the values top on BarChartView? #2759

guanyanlin opened this issue Aug 29, 2017 · 3 comments

Comments

@guanyanlin
Copy link

Today,our company has required me to change the position of the values top on BarChartView?And now I have no idea ,how to get it....

@thierryH91200
Copy link
Contributor

in the file

capture d ecran 2017-08-29 a 17 03 48

modify the line 439

capture d ecran 2017-08-29 a 17 04 06

and in your controller

    chartView.drawValueAboveBarEnabled = true

capture d ecran 2017-08-29 a 17 04 49

@seenoevo
Copy link

@thierryH91200 nice job for pointing in the right direction

@guanyanlin you can also subclass BarChartRenderer and copy the function that contains the posOffset into your subclass and override it there, that way you won't modify the original source code and any future updates in Charts won't wipe out your modifications.

@liuxuan30
Copy link
Member

great people are helping :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants