properties['seperateLines'] = true; $this->properties['fillAxis'] = .8; $this->properties['fillGrid'] = 0; $this->properties['depth'] = .1; $this->properties['pieChartHeight'] = 10.; $this->properties['pieChartRotation'] = .6; $this->properties['pieChartShadowSize'] = 0; $this->properties['pieChartShadowTransparency'] = .3; $this->properties['pieChartShadowColor'] = ezcGraphColor::fromHex( '#000000' ); $this->properties['pieChartGleam'] = false; $this->properties['pieChartGleamColor'] = ezcGraphColor::fromHex( '#FFFFFF' ); $this->properties['barDarkenSide'] = .2; $this->properties['barDarkenTop'] = .4; $this->properties['barChartGleam'] = false; parent::__construct( $options ); } /** * Set an option value * * @param string $propertyName * @param mixed $propertyValue * @throws ezcBasePropertyNotFoundException * If a property is not defined in this class * @return void * @ignore */ public function __set( $propertyName, $propertyValue ) { switch ( $propertyName ) { case 'fillAxis': case 'fillGrid': if ( $propertyValue !== false && !is_numeric( $propertyValue ) || ( $propertyValue < 0 ) || ( $propertyValue > 1 ) ) { throw new ezcBaseValueException( $propertyName, $propertyValue, 'false OR 0 <= float <= 1' ); } $this->properties[$propertyName] = ( $propertyValue === false ? false : (float) $propertyValue ); break; case 'depth': case 'pieChartRotation': case 'pieChartShadowTransparency': case 'barDarkenSide': case 'barDarkenTop': case 'barChartGleam': if ( !is_numeric( $propertyValue ) || ( $propertyValue < 0 ) || ( $propertyValue > 1 ) ) { throw new ezcBaseValueException( $propertyName, $propertyValue, '0 <= float <= 1' ); } $this->properties[$propertyName] = (float) $propertyValue; break; case 'pieChartHeight': case 'pieChartShadowSize': if ( !is_numeric( $propertyValue ) || ( $propertyValue <= 0 ) ) { throw new ezcBaseValueException( $propertyName, $propertyValue, 'float > 0' ); } $this->properties[$propertyName] = (float) $propertyValue; break; case 'seperateLines': if ( !is_bool( $propertyValue ) ) { throw new ezcBaseValueException( $propertyName, $propertyValue, 'bool' ); } $this->properties['seperateLines'] = $propertyValue; break; case 'pieChartShadowColor': $this->properties['pieChartShadowColor'] = ezcGraphColor::create( $propertyValue ); break; default: return parent::__set( $propertyName, $propertyValue ); } } } ?>