Ejemplo n.º 1
0
 /**
  * Create a new PHPExcel_Style
  *
  * @param boolean $isSupervisor Flag indicating if this is a supervisor or not
  *         Leave this value at default unless you understand exactly what
  *    its ramifications are
  * @param boolean $isConditional Flag indicating if this is a conditional style or not
  *       Leave this value at default unless you understand exactly what
  *    its ramifications are
  */
 public function __construct($isSupervisor = false, $isConditional = false)
 {
     // Supervisor?
     $this->isSupervisor = $isSupervisor;
     // Initialise values
     $this->conditionalStyles = array();
     $this->font = new PHPExcel_Style_Font($isSupervisor, $isConditional);
     $this->fill = new PHPExcel_Style_Fill($isSupervisor, $isConditional);
     $this->borders = new PHPExcel_Style_Borders($isSupervisor, $isConditional);
     $this->alignment = new PHPExcel_Style_Alignment($isSupervisor, $isConditional);
     $this->numberFormat = new PHPExcel_Style_NumberFormat($isSupervisor, $isConditional);
     $this->protection = new PHPExcel_Style_Protection($isSupervisor, $isConditional);
     // bind parent if we are a supervisor
     if ($isSupervisor) {
         $this->font->bindParent($this);
         $this->fill->bindParent($this);
         $this->borders->bindParent($this);
         $this->alignment->bindParent($this);
         $this->numberFormat->bindParent($this);
         $this->protection->bindParent($this);
     }
 }