Skip to content
This repository has been archived by the owner on Dec 31, 2019. It is now read-only.

issue with the latest flot from github #1

Open
freeeve opened this issue May 19, 2012 · 3 comments
Open

issue with the latest flot from github #1

freeeve opened this issue May 19, 2012 · 3 comments

Comments

@freeeve
Copy link

freeeve commented May 19, 2012

Using flot-tickrotor with the latest flot seems to give some undesirable results--too much space between the axis label and the graph, and the labels go off the canvas to the left. I'm using angles > 90. I tested with angles < 90 as well, and it seems less bad that way, but still goes off the edge to the right.

I've got a demo Monday and no time to work out what's wrong with the math, so I just hacked some extra offset calculations that worked for my particular rotation angle.

Anyway, just letting you know, in case you're still maintaining this. Thanks for a good starting point.

@markrcote
Copy link
Owner

Hi yup I'm stil maintaining this. Yeah the right-edge cut off with angles < 90 is a known bug. Haven't had time to investigate yet. The left edge should be fine though... are you using really long labels?

As for the distance between the labels and the graph, you can set grid.labelMargin to increase (or even decrease) the distance, although it will apply to all axes. It's hard to get the spacing right for all font sizes.

If you have an example, or even a screenshot, I might be able to help more.

@freeeve
Copy link
Author

freeeve commented May 19, 2012

Yes, they're pretty long, and some are longer than others. That's another thing--it would be better if they would right justify so they're all flush up against the graph.

So this is what I got it to look like (I chopped off the bottom to keep some of the data private):
Example after tweaking offsets

But this is what it started with before tweaking the axis widths and offsets in your code (note that it's not using the full height of the div, either, there was a bunch of white space below the labels):
Example before tweaking offsets

@markrcote
Copy link
Owner

That's pretty fascinating. I'll try to reproduce it.

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

No branches or pull requests

2 participants