. */ /** * For more information, please contact */ namespace Goat1000\SVGGraph; class StackedCylinderGraph extends CylinderGraph { use StackedBarTrait { setBarVisibility as traitSetBarVis; } public function __construct($w, $h, $settings, $fixed_settings = []) { $fixed = [ 'single_axis' => true ]; $fixed_settings = array_merge($fixed, $fixed_settings); parent::__construct($w, $h, $settings, $fixed_settings); } /** * Sets whether a bar is visible or not */ protected function setBarVisibility($dataset, DataItem $item, $top) { $this->traitSetBarVis($dataset, $item, $top, $top || $item->value != 0); } }