Ejemplo n.º 1
0
 /**
  * How far to separate the slice from the rest of the pie.
  * from 0.0 (not at all) to 1.0 (the pie's radius).
  *
  * @param float offset
  * @return \slice
  */
 public function offset($offset)
 {
     if (is_float($offset) && Helpers::between($offset, 0.0, 1.0)) {
         $this->offset = $offset;
     } else {
         $this->type_error(__FUNCTION__, 'float', 'where 0.0 < $offset < 0.1');
     }
     return $this;
 }
Ejemplo n.º 2
0
 /**
  * Sets the angle of the axis text, if it's drawn slanted. Ignored if
  * axis.slantedText is false, or is in auto mode, and the chart decided to
  * draw the text horizontally.
  *
  * This option is only supported for a discrete axis.
  *
  * @param int Angle of labels
  * @return \hAxis
  */
 public function slantedTextAngle($angle)
 {
     if (is_int($angle) && Helpers::between($angle, 1, 90)) {
         $this->slantedTextAngle = $angle;
     } else {
         $this->type_error(__FUNCTION__, 'int', 'between 1 - 90');
     }
     return $this;
 }