_align = null; $this->_spaceBefore = null; $this->_spaceAfter = null; $this->_spacing = null; } /** * Set Style value * * @param string $key * @param mixed $value */ public function setStyleValue($key, $value) { if($key == '_spacing') { $value += 240; // because line height of 1 matches 240 twips } $this->$key = $value; } /** * Get Paragraph Alignment * * @return string */ public function getAlign() { return $this->_align; } /** * Set Paragraph Alignment * * @param string $pValue * @return PHPWord_Style_Paragraph */ public function setAlign($pValue = null) { if(strtolower($pValue) == 'justify') { // justify becames both $pValue = 'both'; } $this->_align = $pValue; return $this; } /** * Get Space before Paragraph * * @return string */ public function getSpaceBefore() { return $this->_spaceBefore; } /** * Set Space before Paragraph * * @param int $pValue * @return PHPWord_Style_Paragraph */ public function setSpaceBefore($pValue = null) { $this->_spaceBefore = $pValue; return $this; } /** * Get Space after Paragraph * * @return string */ public function getSpaceAfter() { return $this->_spaceAfter; } /** * Set Space after Paragraph * * @param int $pValue * @return PHPWord_Style_Paragraph */ public function setSpaceAfter($pValue = null) { $this->_spaceAfter = $pValue; return $this; } /** * Get Spacing between breaks * * @return int */ public function getSpacing() { return $this->_spacing; } /** * Set Spacing between breaks * * @param int $pValue * @return PHPWord_Style_Paragraph */ public function setSpacing($pValue = null) { $this->_spacing = $pValue; return $this; } } ?>