diff options
author | Kore Nordmann <github@kore-nordmann.de> | 2007-04-26 08:37:59 +0000 |
---|---|---|
committer | Kore Nordmann <github@kore-nordmann.de> | 2007-04-26 08:37:59 +0000 |
commit | 76285842b1610e26e7d99dbc02e8edf90549861b (patch) | |
tree | d7e7b5c3c7480d988a4fa9f5251ba7229f8d50d8 /src/interfaces | |
parent | 8637b8b5ef26a8c7c2203e485784bfecd7e269b5 (diff) | |
download | zetacomponents-graph-76285842b1610e26e7d99dbc02e8edf90549861b.zip zetacomponents-graph-76285842b1610e26e7d99dbc02e8edf90549861b.tar.gz |
- First working version of radar charts
# Still marked private because of:
# - Slightly wrong axis arrows
# - Axis grid needs some love
- Some fixes for axis label renderers to work with random directions
# Results in some non visual changes in comparision files
Diffstat (limited to 'src/interfaces')
-rw-r--r-- | src/interfaces/axis_label_renderer.php | 11 | ||||
-rw-r--r-- | src/interfaces/renderer.php | 34 |
2 files changed, 45 insertions, 0 deletions
diff --git a/src/interfaces/axis_label_renderer.php b/src/interfaces/axis_label_renderer.php index 9bebc73..73793af 100644 --- a/src/interfaces/axis_label_renderer.php +++ b/src/interfaces/axis_label_renderer.php @@ -26,6 +26,8 @@ * Indicates if steps are shown on the outer side of axis. * @property bool $outerGrid * Indicates if the grid is shown on the outer side of axis. + * @property bool $showLables + * Indicates if the labels should be shown * @property int $labelPadding * Padding of labels. * @@ -56,6 +58,7 @@ abstract class ezcGraphAxisLabelRenderer extends ezcBaseOptions $this->properties['innerStep'] = true; $this->properties['outerStep'] = false; $this->properties['outerGrid'] = false; + $this->properties['showLabels'] = true; $this->properties['labelPadding'] = 2; parent::__construct( $options ); @@ -149,6 +152,14 @@ abstract class ezcGraphAxisLabelRenderer extends ezcBaseOptions $this->properties['outerGrid'] = (bool) $propertyValue; break; + case 'showLabels': + if ( !is_bool( $propertyValue ) ) + { + throw new ezcBaseValueException( $propertyName, $propertyValue, 'bool' ); + } + + $this->properties['showLabels'] = (bool) $propertyValue; + break; case 'labelPadding': if ( !is_numeric( $propertyValue ) || ( $propertyValue < 0 ) ) diff --git a/src/interfaces/renderer.php b/src/interfaces/renderer.php index a9908f5..1014330 100644 --- a/src/interfaces/renderer.php +++ b/src/interfaces/renderer.php @@ -189,6 +189,40 @@ abstract class ezcGraphRenderer ); /** + * Draw radar chart data line + * + * Draws a line as a data element in a radar chart + * + * @param ezcGraphBoundings $boundings Chart boundings + * @param ezcGraphContext $context Context of call + * @param ezcGraphColor $color Color of line + * @param ezcGraphCoordinate $center Center of radar chart + * @param ezcGraphCoordinate $start Starting point + * @param ezcGraphCoordinate $end Ending point + * @param int $dataNumber Number of dataset + * @param int $dataCount Count of datasets in chart + * @param int $symbol Symbol to draw for line + * @param ezcGraphColor $symbolColor Color of the symbol, defaults to linecolor + * @param ezcGraphColor $fillColor Color to fill line with + * @param float $thickness Line thickness + * @return void + */ + abstract public function drawRadarDataLine( + ezcGraphBoundings $boundings, + ezcGraphContext $context, + ezcGraphColor $color, + ezcGraphCoordinate $center, + ezcGraphCoordinate $start, + ezcGraphCoordinate $end, + $dataNumber = 1, + $dataCount = 1, + $symbol = ezcGraph::NO_SYMBOL, + ezcGraphColor $symbolColor = null, + ezcGraphColor $fillColor = null, + $thickness = 1 + ); + + /** * Draws a highlight textbox for a datapoint. * * A highlight textbox for line and bar charts means a box with the current |