We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

When I Copy a Slide, the Font Changes and the Line Breaks in the Shape

Hi. I’m using the latest version of Aspose.Slide (21.6.0.0).

There are two files in the attached zip
origin.pptx This is the original file.
This is a file that is a copy of the slide from the above file with the origin_out.pptx program.

My source is below.

var copyPpt = new Presentation("origin.pptx");
var basePpt = new Presentation();

var baseMaster = basePpt.Masters;

foreach (var master in copyPpt.Masters)
{
    master.Name = string.Format("{0}", master.Name);
    baseMaster.AddClone(master);
}

foreach (var targetSlide in copyPpt.Slides)
{
    var selectMaster = baseMaster.FirstOrDefault(m => m.Name == targetSlide.LayoutSlide.MasterSlide.Name);
    var copySlide = basePpt.Slides.AddClone(targetSlide,
        selectMaster ?? baseMaster[0], true);
}

basePpt.Save("origin_out.pptx", Aspose.Slides.Export.SaveFormat.Pptx);

When I copy a slide from origin.pptx, the font of the characters in the shape inside the slide changes.
Why is this?

Please tell me the cause of the font change and the workaround.
Best regard.

forum.zip (76.7 KB)

@yuya

It seems to be an issue with API and a ticket with ID SLIDESNET-42699 has been created to further investigate and resolve the issue. This thread has been linked with the issue so that you may be notified once the issue will be fixed.

1 Like

The issues you have found earlier (filed as SLIDESNET-42699) have been fixed in this update.

1 Like