Ejemplo n.º 1
0
 /**
  * Sets and returns margins
  *
  * @param null|array $margin
  * @return Margin
  */
 public function margin($margin = null)
 {
     if (!isset($this->margin)) {
         $this->margin = new Margin();
     }
     if (null !== $margin) {
         $this->margin->setValues($margin);
     }
     return $this->margin;
 }
Ejemplo n.º 2
0
 /**
  * Returns params
  * 
  * @return array 
  */
 public function getParams()
 {
     $params = parent::getParams();
     $paramKeys = array('titleField', 'valueField', 'angle', 'depth3D', 'balloonText', 'groupedTitle', 'groupPercent', 'innerRadius', 'labelRadius', 'labelText', 'outlineColor', 'outlineThickness', 'pieBaseColor', 'pieBrightnessStep', 'pullOutDuration', 'pullOutEffect', 'pullOutRadius', 'sequencedAnimation', 'startDuration', 'startEffect', 'urlTarget');
     foreach ($paramKeys as $key) {
         if (isset($this->{$key})) {
             if ($this->{$key} instanceof Setting\Alpha) {
                 $params[$key] = $this->{$key}->getValue();
             } else {
                 $params[$key] = $this->{$key};
             }
         }
     }
     if (isset($this->margin)) {
         $params += $this->margin->toArray();
     }
     return $params;
 }
Ejemplo n.º 3
0
 /**
  * Returns params
  * 
  * @return array 
  */
 public function getParams()
 {
     $params = parent::getParams();
     $paramKeys = array('angle', 'depth3D');
     foreach ($paramKeys as $key) {
         if (isset($this->{$key})) {
             if ($this->{$key} instanceof Setting\Alpha) {
                 $params[$key] = $this->{$key}->getValue();
             } else {
                 $params[$key] = $this->{$key};
             }
         }
     }
     if (isset($this->cursor)) {
         $params += $this->cursor->toArray();
     }
     if (isset($this->margin)) {
         $params += $this->margin->toArray();
     }
     return $params;
 }