Open PlatonB opened 2 years ago
@PlatonB can you clarify the problem here? Looks to me as though when the labels are vertical they're perhaps 1-2 px to the left of where they should be, is that what you mean?
@alexcjohnson I don't know how to measure the exact number of px, but it is clearly visible that the labels are to the left. If I zoom in the canvas, the labels return to the center (where they should be).
Let's build a histogram for 1000 random values from 0 to 1, narrow down the bins and add tick text to each bin. To make the existence of the bug visible, draw a vertical line in the middle of each bin.
Result:
An interesting detail: if I double zoom the diagram (HTML), the offset eliminates:
If anyone thinks the problem is because the tick texts are too long, let's simplify them by removing
ticktext=[' - '.join(map(str, rng)) for rng in ranges],
. The displacement will remain: