PhpOffice\PhpPresentation\Reader\ODPresentation::readListItem PHP Method

readListItem() protected method

Read List Item
protected readListItem ( RichText $oShape, DOMElement $oNodeParent, DOMElement $oNodeParagraph )
$oShape PhpOffice\PhpPresentation\Shape\RichText
$oNodeParent DOMElement
$oNodeParagraph DOMElement
    protected function readListItem(RichText $oShape, \DOMElement $oNodeParent, \DOMElement $oNodeParagraph)
    {
        $oParagraph = $oShape->createParagraph();
        if ($oNodeParagraph->hasAttribute('text:style-name')) {
            $keyStyle = $oNodeParagraph->getAttribute('text:style-name');
            if (isset($this->arrayStyles[$keyStyle])) {
                $oParagraph->setAlignment($this->arrayStyles[$keyStyle]['listStyle'][$this->levelParagraph]['alignment']);
                $oParagraph->setBulletStyle($this->arrayStyles[$keyStyle]['listStyle'][$this->levelParagraph]['bullet']);
            }
        }
        foreach ($this->oXMLReader->getElements('text:span', $oNodeParent) as $oNodeRichTextElement) {
            $this->readParagraphItem($oParagraph, $oNodeRichTextElement);
        }
    }