Word2007 : Add rowspan and colspan to cells
This commit is contained in:
parent
0d19d57cba
commit
a610c34a18
|
|
@ -121,7 +121,20 @@ class PHPWord_Style_Cell {
|
|||
* @var string
|
||||
*/
|
||||
private $_defaultBorderColor;
|
||||
|
||||
|
||||
/**
|
||||
* colspan
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
private $_gridSpan = NULL;
|
||||
|
||||
/**
|
||||
* rowspan
|
||||
*
|
||||
* @var integer
|
||||
*/
|
||||
private $_vMerge = NULL;
|
||||
|
||||
/**
|
||||
* Create a new Cell Style
|
||||
|
|
@ -233,7 +246,6 @@ class PHPWord_Style_Cell {
|
|||
return $this->_borderTopColor;
|
||||
}
|
||||
|
||||
|
||||
public function setBorderLeftSize($pValue = null) {
|
||||
$this->_borderLeftSize = $pValue;
|
||||
}
|
||||
|
|
@ -249,8 +261,7 @@ class PHPWord_Style_Cell {
|
|||
public function getBorderLeftColor() {
|
||||
return $this->_borderLeftColor;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public function setBorderRightSize($pValue = null) {
|
||||
$this->_borderRightSize = $pValue;
|
||||
}
|
||||
|
|
@ -287,5 +298,21 @@ class PHPWord_Style_Cell {
|
|||
public function getDefaultBorderColor() {
|
||||
return $this->_defaultBorderColor;
|
||||
}
|
||||
|
||||
public function setGridSpan($pValue = null) {
|
||||
$this->_gridSpan = $pValue;
|
||||
}
|
||||
|
||||
public function getGridSpan() {
|
||||
return $this->_gridSpan;
|
||||
}
|
||||
|
||||
public function setVMerge($pValue = null) {
|
||||
$this->_vMerge = $pValue;
|
||||
}
|
||||
|
||||
public function getVMerge() {
|
||||
return $this->_vMerge;
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
|
@ -586,6 +586,19 @@ class PHPWord_Writer_Word2007_Base extends PHPWord_Writer_Word2007_WriterPart {
|
|||
$objWriter->endElement();
|
||||
}
|
||||
}
|
||||
$gridSpan = $style->getGridSpan();
|
||||
if(!is_null($gridSpan)) {
|
||||
$objWriter->startElement('w:gridSpan');
|
||||
$objWriter->writeAttribute('w:val', $gridSpan);
|
||||
$objWriter->endElement();
|
||||
}
|
||||
|
||||
$vMerge = $style->getVMerge();
|
||||
if(!is_null($vMerge)) {
|
||||
$objWriter->startElement('w:vMerge');
|
||||
$objWriter->writeAttribute('w:val', $vMerge);
|
||||
$objWriter->endElement();
|
||||
}
|
||||
}
|
||||
|
||||
protected function _writeImage(PHPWord_Shared_XMLWriter $objWriter = null, $image) {
|
||||
|
|
|
|||
|
|
@ -26,6 +26,7 @@ Fixed in branch for release 0.7 :
|
|||
- Bugfix: (RomanSyroeshko) GH-34 - PHPWord_Shared_String.IsUTF8 returns FALSE for Cyrillic UTF-8 input
|
||||
- Feature: (Progi1984) GH-1 - Implement RTF Writer
|
||||
- Feature: (Progi1984) GH-2 - Implement ODT Writer
|
||||
- Feature: (kaystrobach) - Word2007 : Add rowspan and colspan to cells
|
||||
- General: (MarkBaker) - Add superscript/subscript styling in Excel2007 Writer
|
||||
- General: (deds) - add indentation support to paragraphs
|
||||
- General: (Progi1984) GH-27 - Support for Composer
|
||||
|
|
|
|||
Loading…
Reference in New Issue