From: Tanner Linsley Date: Tue, 27 Oct 2015 08:33:34 +0000 (-0600) Subject: Category Scale now plays nice with full width X-Git-Tag: 2.0.0-beta2~25^2~32 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2bc386ee8181ff2b8bbd11cdd8e9ddf7e29d3df6;p=thirdparty%2FChart.js.git Category Scale now plays nice with full width --- diff --git a/src/scales/scale.category.js b/src/scales/scale.category.js index 039a9bef6..e3441bb20 100644 --- a/src/scales/scale.category.js +++ b/src/scales/scale.category.js @@ -30,7 +30,7 @@ widthOffset += (valueWidth / 2); } - return this.left + Math.round(widthOffset); + return this.left + this.margins.left + Math.round(widthOffset); } else { var innerHeight = this.height - (this.paddingTop + this.paddingBottom); var valueHeight = innerHeight / Math.max((this.data.labels.length - ((this.options.gridLines.offsetGridLines) ? 0 : 1)), 1);