From: Evert Timberg Date: Mon, 28 Dec 2015 22:20:08 +0000 (-0500) Subject: Fix layout service X-Git-Tag: v2.0.0~87^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0c534e1eb8140e09f8d55bba7431fd4116dc9dd6;p=thirdparty%2FChart.js.git Fix layout service --- diff --git a/src/core/core.layoutService.js b/src/core/core.layoutService.js index def2b55ae..a7f2bcfa8 100644 --- a/src/core/core.layoutService.js +++ b/src/core/core.layoutService.js @@ -179,7 +179,9 @@ bottom: 0, }; - box.update(box.options.fullWidth ? chartWidth : maxChartAreaWidth, minBoxSize.minSize.height, scaleMargin); + // Don't use min size here because of label rotation. When the labels are rotated, their rotation highly depends + // on the margin. Sometimes they need to increase in size slightly + box.update(box.options.fullWidth ? chartWidth : maxChartAreaWidth, chartHeight / 2, scaleMargin); } else { box.update(minBoxSize.minSize.width, maxChartAreaHeight); }