$value) { if (substr($key, 0, 1) != '_') { $key = '_' . $key; } $styleObject->setStyleValue($key, $value); } $style = $styleObject; } else { $style = $returnObject ? $styleObject : $styleValue; } return $style; } /** * Set doc part * * @param string $docPart * @param integer $docPartId */ public function setDocPart($docPart, $docPartId = 1) { $this->docPart = $docPart; $this->docPartId = $docPartId; } /** * Get doc part * * @return string */ public function getDocPart() { return $this->docPart; } /** * Get doc part Id * * @return integer */ public function getDocPartId() { return $this->docPartId; } /** * Check if element is located in section doc part (as opposed to header/footer) * * @return boolean */ public function isInSection() { return ($this->docPart == 'section'); } }