Don't account for paddingLeft until after rotated

This commit is contained in:
Tanner Linsley 2015-08-28 15:12:35 -06:00
parent 8164418dc8
commit bade753fe3

View File

@ -126,7 +126,7 @@
var datasetWidth = Math.floor(this.getPixelForValue(0, 1) - this.getPixelForValue(0, 0)) - 6;
//Max label rotation can be set or default to 90 - also act as a loop counter
while (this.labelWidth > (datasetWidth + this.paddingLeft) && this.labelRotation <= this.options.labels.maxRotation) {
while (this.labelWidth > datasetWidth && this.labelRotation <= this.options.labels.maxRotation) {
cosRotation = Math.cos(helpers.toRadians(this.labelRotation));
sinRotation = Math.sin(helpers.toRadians(this.labelRotation));