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

WIP: Adjust nticks based on length of axis #5494

Closed
wants to merge 4 commits into from

Conversation

mdboom
Copy link
Member

@mdboom mdboom commented Nov 16, 2015

There's a bit of a chicken and egg problem here. You don't know how many ticks you can fit if you don't know what the tick labels contain. And you don't know what the tick labels contain until you know how many ticks there are.

Therefore this is just based on a heuristic that the text will have an aspect ratio of around 4:1. Probably not always true, and there are perhaps better ways to estimate based on what the tick formatter actually is, or by rendering just one of them and using that.

@mdboom mdboom added this to the next major release (2.0) milestone Nov 16, 2015
@Tillsten
Copy link
Contributor

Very nice to see some work on this, adjusting ticks always takes quite a lot of time. Feature request: ability to disallow ticks near the end of an axis, this is very helpful when stacking axes without any hspace/wspace, because else the ticklabels are overlapping.

@mdboom
Copy link
Member Author

mdboom commented Nov 18, 2015

I'm going to close this and move it to the style-change branch. It's not possible to make this backward compatible without some other changes over there.

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

Successfully merging this pull request may close these issues.

None yet

2 participants