public function testParagraphRichText() { $phpPresentation = new PhpPresentation(); $oSlide = $phpPresentation->getActiveSlide(); $oRichText = $oSlide->createRichTextShape(); $oRichText->createTextRun('Alpha'); $oRichText->createBreak(); $oRichText->createText('Beta'); $oRichText->createBreak(); $oRun = $oRichText->createTextRun('Delta'); $oRun->getHyperlink()->setUrl('http://www.google.fr'); $pres = TestHelperDOCX::getDocument($phpPresentation, 'ODPresentation'); $element = '/office:document-content/office:body/office:presentation/draw:page/draw:frame/draw:text-box/text:p/text:span/text:line-break'; $this->assertTrue($pres->elementExists($element, 'content.xml')); $element = '/office:document-content/office:body/office:presentation/draw:page/draw:frame/draw:text-box/text:p/text:span/text:a'; $this->assertTrue($pres->elementExists($element, 'content.xml')); $this->assertEquals('http://www.google.fr', $pres->getElementAttribute($element, 'xlink:href', 'content.xml')); }