|
|
@ -371,6 +371,9 @@ |
|
|
|
// for arc
|
|
|
|
// for arc
|
|
|
|
$$.arcWidth = $$.width - ($$.isLegendRight ? legendWidth + 10 : 0); |
|
|
|
$$.arcWidth = $$.width - ($$.isLegendRight ? legendWidth + 10 : 0); |
|
|
|
$$.arcHeight = $$.height - ($$.isLegendRight ? 0 : 10); |
|
|
|
$$.arcHeight = $$.height - ($$.isLegendRight ? 0 : 10); |
|
|
|
|
|
|
|
if ($$.hasType('gauge')) { |
|
|
|
|
|
|
|
$$.arcHeight += $$.height - $$.getGaugeLabelHeight(); |
|
|
|
|
|
|
|
} |
|
|
|
if ($$.updateRadius) { $$.updateRadius(); } |
|
|
|
if ($$.updateRadius) { $$.updateRadius(); } |
|
|
|
|
|
|
|
|
|
|
|
if ($$.isLegendRight && hasArc) { |
|
|
|
if ($$.isLegendRight && hasArc) { |
|
|
@ -2257,7 +2260,7 @@ |
|
|
|
c3_chart_internal_fn.getCurrentHeight = function () { |
|
|
|
c3_chart_internal_fn.getCurrentHeight = function () { |
|
|
|
var $$ = this, config = $$.config, |
|
|
|
var $$ = this, config = $$.config, |
|
|
|
h = config.size_height ? config.size_height : $$.getParentHeight(); |
|
|
|
h = config.size_height ? config.size_height : $$.getParentHeight(); |
|
|
|
return h > 0 ? h : 320; |
|
|
|
return h > 0 ? h : 320 / ($$.hasType('gauge') ? 2 : 1); |
|
|
|
}; |
|
|
|
}; |
|
|
|
c3_chart_internal_fn.getCurrentPaddingTop = function () { |
|
|
|
c3_chart_internal_fn.getCurrentPaddingTop = function () { |
|
|
|
var config = this.config; |
|
|
|
var config = this.config; |
|
|
@ -4399,6 +4402,9 @@ |
|
|
|
.text(config.gauge_label_show ? config.gauge_max : ''); |
|
|
|
.text(config.gauge_label_show ? config.gauge_max : ''); |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
c3_chart_internal_fn.getGaugeLabelHeight = function () { |
|
|
|
|
|
|
|
return this.config.gauge_label_show ? 20 : 0; |
|
|
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
c3_chart_internal_fn.initRegion = function () { |
|
|
|
c3_chart_internal_fn.initRegion = function () { |
|
|
|
var $$ = this; |
|
|
|
var $$ = this; |
|
|
|