Skip to content

added titles to the axis#3399

Open
xpete wants to merge 3 commits intoPhilJay:masterfrom
xpete:axistitles
Open

added titles to the axis#3399
xpete wants to merge 3 commits intoPhilJay:masterfrom
xpete:axistitles

Conversation

@xpete
Copy link
Copy Markdown

@xpete xpete commented Sep 2, 2017

I'am using this myself on a LineChart and it's working well.
MPAndroidChart is the best chart library for Android but it's useless for me without axis titles and I think it's the most requested feature.

Related feature requests:
#2034
#1869
#716
#828
#1324
#1440
#513

Screenshot

This is an update of this PR:
#2625

@xpete xpete mentioned this pull request Sep 2, 2017
@xpete
Copy link
Copy Markdown
Author

xpete commented Sep 2, 2017

@andrebstv @leslieLinn @hermamitr please check this. I fixed the right YAxis.

@xpete
Copy link
Copy Markdown
Author

xpete commented Sep 2, 2017

@boomsya I have a legend and title on the buttom in the screen shot and they are not in the same place. Are you doing anything that could create the bug?

@MaximeKjaer
Copy link
Copy Markdown

The link to the screenshot seems to be dead. I would really want to see this merged, but there are quite a few PRs around here that just haven't ever been replied to... It's a shame 🙁

@axoaxel
Copy link
Copy Markdown

axoaxel commented May 5, 2018

is it now in the library? Actually I still cannot call the methods

@almic
Copy link
Copy Markdown
Contributor

almic commented May 6, 2018

Currently I see no need to do this in the library itself, due to how simple of a feature it is. If you want axis titles, there is no reason you can't manually put two text views on the sides of the chart view. This is like asking android to add the ability to add a feature that adds captions to ImageViews. They would never add that because you can already do it with TextViews.

This is no different. Won't fix :/

@almic almic closed this May 6, 2018
@almic almic added the wontfix will not be implemented for various reasons label May 6, 2018
@xpete
Copy link
Copy Markdown
Author

xpete commented May 8, 2018

It's not possible to do this with a TextView because it's not possible to put a TextView between the chart and the legend. If it was possible I would have done it.
Before using this library I tried all Android charting libraries I've found and none of them had everything I need but from what I remember all of the others had axis title. I figured It would be easier to fix this library than the others. It's also the most requested feature in this issue tracker. If I was going to do a charting library It would be one of the first things I would. It's just a basic feature of any charting library.
It's already done and it's working as you can try here: https://play.google.com/store/apps/details?id=com.diogopicarra.adslspeed.free
I see no reason not to accept this. If something is wrong just tell me and will try to fix It.

@andrebstv
Copy link
Copy Markdown

andrebstv commented May 8, 2018 via email

@almic
Copy link
Copy Markdown
Contributor

almic commented May 8, 2018

I'll reopen this. I stand by my opinion that a TextView is better, and you can easily change the legend position by the way.

However my opinion doesn't matter as much as the users, as this library is built on user contributions, like this one.

@almic almic reopened this May 8, 2018
@almic almic added enhancement improves upon existing functionality and removed wontfix will not be implemented for various reasons labels May 8, 2018
@xpete
Copy link
Copy Markdown
Author

xpete commented May 9, 2018

None of that option allow me to put the title between the legend and the chart.

Copy link
Copy Markdown

@trantuananh1996 trantuananh1996 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Usefull and basic function for every chart

@trantuananh1996
Copy link
Copy Markdown

trantuananh1996 commented Jun 1, 2018

Edit: Sorry my bad, offset calculated in this pull request.

Need to add titleHeight to offsetBottom in case Legend is disabled. Take a look at calculateOffsets() in BarLineChartBase.
And I'm working with title position of those axis

@luizfp
Copy link
Copy Markdown

luizfp commented Sep 20, 2018

Will this PR be merged any time soon?

This is also a feature that our team needs.

@devonhuangcodes
Copy link
Copy Markdown

Any updates on this?

@axoaxel
Copy link
Copy Markdown

axoaxel commented Nov 30, 2018

I gues it will not be added to the library, Just work with the layout adding textviews

@devonhuangcodes
Copy link
Copy Markdown

I need the axis titles between the bottom legend and the chart that’s the only issue. I don’t think textviews help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement improves upon existing functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants