Example #1
0
 /**
  * Builds a new chart with the given label and DataTable.
  *
  * @param  \Khill\Lavacharts\Values\Label $chartLabel Identifying label for the chart.
  * @param  \Khill\Lavacharts\DataTables\DataTable $datatable DataTable used for the chart.
  * @param  array $config Array of options to set for the chart.
  * @return \Khill\Lavacharts\Charts\DonutChart
  */
 public function __construct(Label $chartLabel, DataTable $datatable, $config = [])
 {
     $options = new Options($this->donutDefaults);
     $options->set('pieHole', 0.5);
     parent::__construct($chartLabel, $datatable, $config);
     $this->options->merge($options);
 }
Example #2
0
 public function __construct($chartLabel)
 {
     parent::__construct($chartLabel);
     $this->defaults = array_merge($this->defaults, array('pieHole'));
     $this->pieHole(0.5);
 }
 /**
  * Builds a new chart with the given label and DataTable.
  *
  * @param  \Khill\Lavacharts\Values\Label $chartLabel Identifying label for the chart.
  * @param  \Khill\Lavacharts\DataTables\DataTable $datatable DataTable used for the chart.
  * @param  array $config Array of options to set for the chart.
  * @return \Khill\Lavacharts\Charts\DonutChart
  */
 public function __construct(Label $chartLabel, DataTable $datatable, $config = [])
 {
     parent::__construct($chartLabel, $datatable, $config);
 }
 public function __construct($chartLabel)
 {
     parent::__construct($chartLabel);
     $this->defaults = array_merge($this->defaults, array('pieHole'));
     $this->chartType = 'PieChart';
 }