Skip to content

Commit 9f3f686

Browse files
devX2712Progi1984
authored andcommitted
ADD Read also texte zone margin RLTB
ADD Read also from original PPTX mragin of shape (left,right,top,bottom) Writing already existing and object have been initialized by default (so now setted by reading existing file)
1 parent db96a0a commit 9f3f686

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/PhpPresentation/Reader/PowerPoint2007.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -968,6 +968,20 @@ protected function loadShapeRichText(XMLReader $document, DOMElement $node, $oSl
968968
}
969969
}
970970

971+
$bodyPr = $document->getElement('p:txBody/a:bodyPr', $node);
972+
if (($bodyPr instanceof \DOMElement) && $bodyPr->hasAttribute('lIns')) {
973+
$oShape->setInsetLeft((int)$bodyPr->getAttribute('lIns'));
974+
}
975+
if (($bodyPr instanceof \DOMElement) && $bodyPr->hasAttribute('tIns')) {
976+
$oShape->setInsetTop((int)$bodyPr->getAttribute('tIns'));
977+
}
978+
if (($bodyPr instanceof \DOMElement) && $bodyPr->hasAttribute('rIns')) {
979+
$oShape->setInsetRight((int)$bodyPr->getAttribute('rIns'));
980+
}
981+
if (($bodyPr instanceof \DOMElement) && $bodyPr->hasAttribute('bIns')) {
982+
$oShape->setInsetBottom((int)$bodyPr->getAttribute('bIns'));
983+
}
984+
971985
$arrayElements = $document->getElements('p:txBody/a:p', $node);
972986
foreach ($arrayElements as $oElement) {
973987
if ($oElement instanceof DOMElement) {

0 commit comments

Comments
 (0)