From f21f79761aaa991a28fb700caddabb80649c4627 Mon Sep 17 00:00:00 2001 From: antoine Date: Thu, 25 May 2017 22:04:23 +0200 Subject: [PATCH] fix sample --- samples/Sample_37_Comments.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/samples/Sample_37_Comments.php b/samples/Sample_37_Comments.php index 91d353a9..670e914b 100644 --- a/samples/Sample_37_Comments.php +++ b/samples/Sample_37_Comments.php @@ -15,7 +15,7 @@ $section = $phpWord->addSection(); $textrun = $section->addTextRun(); $textrun->addText('This '); $text = $textrun->addText('is'); -$text->setCommentStart($comment); +$text->setCommentRangeStart($comment); $textrun->addText(' a test'); $section->addTextBreak(2); @@ -28,10 +28,10 @@ $phpWord->addComment($commentWithStartAndEnd); $textrunWithEnd = $section->addTextRun(); $textrunWithEnd->addText('This '); $textToStartOn = $textrunWithEnd->addText('is', array('bold' => true)); -$textToStartOn->setCommentStart($commentWithStartAndEnd); +$textToStartOn->setCommentRangeStart($commentWithStartAndEnd); $textrunWithEnd->addText(' another', array('italic' => true)); $textToEndOn = $textrunWithEnd->addText(' test'); -$textToEndOn->setCommentEnd($commentWithStartAndEnd); +$textToEndOn->setCommentRangeEnd($commentWithStartAndEnd); $section->addTextBreak(2); @@ -42,7 +42,7 @@ $imageComment->addText('Hey, Mars does look '); $imageComment->addText('red', array('color' => 'FF0000')); $phpWord->addComment($commentOnImage); $image = $section->addImage('resources/_mars.jpg'); -$image->setCommentStart($commentOnImage); +$image->setCommentRangeStart($commentOnImage); $section->addTextBreak(2);