getStyle(); if (!$style instanceof \PhpOffice\PhpWord\Style\Extrusion) { return; } $xmlWriter = $this->getXmlWriter(); $xmlWriter->startElement('o:extrusion'); $xmlWriter->writeAttribute('on', 't'); $xmlWriter->writeAttributeIf($style->getType() !== null, 'type', $style->getType()); $xmlWriter->writeAttributeIf($style->getColor() !== null, 'color', $style->getColor()); $xmlWriter->endElement(); } }