FontBold in table problem


#1

This is using 2.3.8.0 Aspose.PowerPoint in a dynamically generated presentation - the template has a single slide.

Using the following code - for some reason all of my table cells fonts come out bold:

Originally - I was tracking a bug in Aspose where calling the AddTable routine would cause specific cells in the preceding table's "FontBold" property to change to "false" - though they were set to "true" initially.. I recently update to 2.3.8.0 - and now all fonts come out bold in the resulting presention.

Am I doing something incorrect? Is this a bug in the Aspose component? As always thanks for any assistance resolving this issue.

private void button4_Click(object sender, System.EventArgs e)

{

string fileTemp = "Opportunity.ppt";

Aspose.PowerPoint.Presentation pres = new Presentation(fileTemp);

Aspose.PowerPoint.Slide currentSlide = pres.GetSlideByPosition(pres.Slides.Count);

currentSlide.Shapes.AddTable(240, 240, 5328, 12, 4, 4);

Aspose.PowerPoint.Table currentTable =

(Aspose.PowerPoint.Table) currentSlide.Shapes[currentSlide.Shapes.Count - 1];

TestInsert(currentTable, 0, 0, true);

TestInsert(currentTable, 0, 1, false);

TestInsert(currentTable, 0, 2, true);

TestInsert(currentTable, 0, 3, false);

TestInsert(currentTable, 1, 0, true);

TestInsert(currentTable, 1, 1, false);

TestInsert(currentTable, 1, 2, true);

TestInsert(currentTable, 1, 3, false);

TestInsert(currentTable, 2, 0, true);

TestInsert(currentTable, 2, 1, false);

TestInsert(currentTable, 2, 2, true);

TestInsert(currentTable, 2, 3, false);

TestInsert(currentTable, 3, 0, true);

TestInsert(currentTable, 3, 1, false);

TestInsert(currentTable, 3, 2, true);

TestInsert(currentTable, 3, 3, false);

int tableArea = currentTable.Y + currentTable.Height + 40;

currentSlide.Shapes.AddTable(240, tableArea, 5328, 12, 2, 2);

currentTable = (Aspose.PowerPoint.Table) currentSlide.Shapes[currentSlide.Shapes.Count - 1];

TestInsert(currentTable, 0, 0, true);

TestInsert(currentTable, 0, 1, false);

TestInsert(currentTable, 1, 0, true);

TestInsert(currentTable, 1, 1, false);

pres.Write("C:/TEST.ppt");

}

private void TestInsert(Aspose.PowerPoint.Table table,int row, int col,bool isBold)

{

Aspose.PowerPoint.Cell cell = table.GetCell(col, row);

Aspose.PowerPoint.TextFrame textFrame = cell.TextFrame;

Aspose.PowerPoint.Paragraph paragraph = textFrame.Paragraphs[0];

Aspose.PowerPoint.Portion portion = paragraph.Portions[0];

portion.FontBold = isBold;

portion.Text = "TEST";

}


#2

Thank you for report, we will investigate this issue and fix it asap.