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

YAxis size calculations #480

Closed
AlBirdie opened this issue Oct 15, 2015 · 6 comments
Closed

YAxis size calculations #480

AlBirdie opened this issue Oct 15, 2015 · 6 comments

Comments

@AlBirdie
Copy link
Contributor

I've noticed that the current master branch resizes the y axis when the axis labels change, for instance during scrolling.
That means, that when you manipulate the current x axis range, it can happen that the max width of the y labels change, resulting in a resize of the chart drawing panel.
Can be disable this feature and go back to truncating the y axis labels instead?
I couldn't find a property for that.

@danielgindi
Copy link
Collaborator

It was actually never truncated - just did not calculate when scrolling... This has changed many commits ago!
You can set a fixed width for the Y axis to disable the constant updates

@AlBirdie
Copy link
Contributor Author

Oh I see.
Didn't keep up the changes lately as I had to implement the Android version of the chart.
Ok then, fixed size it is. Thanks for your help, Daniel!

@danielgindi
Copy link
Collaborator

NP :-)

@AlBirdie
Copy link
Contributor Author

@danielgindi, is there a way to actually truncate the y-axis labels? Turns out that constantly re-adjusting my synchronised chart viewports (I've got several charts stacked vertically that need to have the same y-axis width), looks kinda wrong during manipulation of the chart's viewport. Instead, setting the y-axes widths to the maximum size after the initial draw and then leave it that way looks way better.
However, in order to not have the y-axis labels reach into the chart's viewport, I need them to be truncated.
This should be doable in the ChartYAxisRenderer (if _yAxis.maxWidth > 0...), and using a lineBreakMode, right?
This is probably a feature many require, so I'd like to give this a go in the foreseeable future.

@danielgindi
Copy link
Collaborator

Well I'm planning to do some work on the Y axis labels anyway, to support
wrapping, line break mode etc.

‏בתאריך יום שישי, 16 באוקטובר 2015, AlBirdie notifications@github.com כתב:

@danielgindi https://github.com/danielgindi, is there a way to actually
truncate the y-axis labels? Turns out that constantly re-adjusting my
synchronised chart viewports (I've got several charts stacked vertically
that need to have the same y-axis width), looks kinda wrong during
manipulation of the chart's viewport. Instead, setting the y-axes widths to
the maximum size after the initial draw and then leave it that way looks
way better.
However, in order to not have the y-axis labels reach into the chart's
viewport, I need them to be truncated.
This should be doable in the ChartYAxisRenderer (if _yAxis.maxWidth >
0...), and using a lineBreakMode, right?
This is probably a feature many require, so I'd like to give this a go in
the foreseeable future.


Reply to this email directly or view it on GitHub
#480 (comment)
.

@AlBirdie
Copy link
Contributor Author

Ok then. I'll leave it to you then. :)
Cheers mate!

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

2 participants