86 if (!$this->cx) $this->cx = $this->
width / 2;
87 if (!$this->cy) $this->cy = $this->
height / 2;
88 if (!$this->radius) $this->radius = min(
$width,
$height) * .4;
93 $this->containerWidth =
$width;
94 $this->containerHeight =
$height;
110 $this->labelSize =
$size;
115 $this->strokeWidth = $s;
120 $this->fontFamily = $font;
129 $this->legend = $show;
147 $values = implode(
", ", $this->values);
148 $labels =
"'".implode(
"', '", $this->labels) .
"'";
149 $animate = $this->animate ?
"true" :
"false";
151 $emboss = $this->
emboss ?
"true" :
"false";
152 $legend = $this->legend ?
"true" :
"false";
153 $percentages = $this->showPercentages ?
"true" :
"false";
154 $download = $this->enableDownload ?
"true" :
"false";
161 foreach($this->series as $s)
163 $data .=
"\t{$this->id}.addSeries(".$s->toScript().
");\n";
167 <script type=
"text/javascript">
168 window.addEvent(
'domready',
function ()
170 var {$this->
id} =
new RadarChart(
'{$this->id}',
176 radius: {$this->radius},
177 palette:
'{$this->palette}',
178 labelSize: {$this->labelSize},
179 fontFamily:
'{$this->fontFamily}',
180 strokeWidth: {$this->strokeWidth},
188 legendX: {$this->legendX},
189 legendY: {$this->legendY},
190 legendSwatchSize: {$this->legendSwatchSize},
191 legendLineHeight: {$this->legendLineHeight},
192 onLegendOver: {$this->onLegendOver},
193 onLegendOut: {$this->onLegendOut},
194 onLegendClick: {$this->onLegendClick},
195 title:
'{$this->title}',
196 titleSize: {$this->titleSize},
197 enableDownload: {$download},
198 units:
'{$this->units}'
201 {$this->
id}.labels = [
$labels ];
211 $dimensions =
"width: 100%; height: auto";
215 $dimensions =
"width: {$containerWidth}; height: {$containerHeight};";
218 echo
"<div id='{$this->id}' style='$dimensions'></div>";
static using()
Import the datamodels, views and manifest for the specified component(s).
showLegend($show, $x=0, $y=0)
__construct($id, $width=300, $height=300, $labels=null, $palette="standard")
setContainerSize($width, $height="0")