The inline paragraph is rendered wrong in the table cell

Hello,


One more issue we found with inline paragraphs. We need render some text in a table cell. Here it is the code snippet:

private static void Main()
{
Document doc = new Document();
Page page = doc.Pages.Add();

Table table = new Table();
Row row = table.Rows.Add();
Cell cell = row.Cells.Add();
cell.Border = new BorderInfo(BorderSide.All, 1, Color.Red);

cell.Paragraphs.Add(Create(false));
cell.Paragraphs.Add(Create(true));
cell.Paragraphs.Add(Create(false));
cell.Paragraphs.Add(Create(true));
cell.Paragraphs.Add(Create(false));

page.Paragraphs.Add(table);

doc.Save(@“d:\wrong_inline_paragraph.pdf”);
}

private static TextFragment Create(bool isInline)
{
return new TextFragment(“TestParagraph”)
{
IsInLineParagraph = isInline
};
}

The output is attached. As you can see there is an indentation in the 2nd and 3rd line that is definitely wrong and it breaks the cell content.

Please advise.

One note. We’ve recently found and raised too many issues related to inline paragraphs:

1) Free Support Forum - aspose.com
2) Inline paragraph alignment bug - Free Support Forum - aspose.com

and because of them (and some others) we cannot deploy the code for more than 2 months. So please set the priority to the found issues and test this functionality thoroughly.


Hi Dmitry,

Thanks for your inquiry.

ShmelP:
Hello,

One more issue we found with inline paragraphs. We need render some text in a table cell. Here it is the code snippet:

private static void Main()
{
Document doc = new Document();
Page page = doc.Pages.Add();

Table table = new Table();
Row row = table.Rows.Add();
Cell cell = row.Cells.Add();
cell.Border = new BorderInfo(BorderSide.All, 1, Color.Red);

cell.Paragraphs.Add(Create(false));
cell.Paragraphs.Add(Create(true));
cell.Paragraphs.Add(Create(false));
cell.Paragraphs.Add(Create(true));
cell.Paragraphs.Add(Create(false));

page.Paragraphs.Add(table);

doc.Save(@"d:\wrong_inline_paragraph.pdf");
}

private static TextFragment Create(bool isInline)
{
return new TextFragment("TestParagraph")
{
IsInLineParagraph = isInline
};
}

The output is attached. As you can see there is an indentation in the 2nd and 3rd line that is definitely wrong and it breaks the cell content.

Please advise.


We have tested the scenario and noticed the reported issue, so logged a ticket PDFNEWNET-39336 in our issue tracking system for further investigation and resolution. We will notify you as soon as it is resolved.

ShmelP:

One note. We've recently found and raised too many issues related to inline paragraphs:

1) http://www.aspose.com/community/forums/650942/bug-quot-linespacing-quot-is-wrong-in-the-quot-inline-quot-paragraph/showthread.aspx#650942
2) http://www.aspose.com/community/forums/653422/inline-paragraph-alignment-bug/showthread.aspx#653422

and because of them (and some others) we cannot deploy the code for more than 2 months. So please set the priority to the found issues and test this functionality thoroughly.



Please note issues logged against first thread, mentioned above, have been resolved in upcoming release of Apose.Pdf for .NET 10.8.0 and hopefully it will be released in couple of days.

Moreover, we have recently logged issues regarding second thread with high priority. We have shared your concern with the product team. We will keep you updated about the issues' resolution progress.

We are sorry for the inconvenience caused.

Best Regards,

The issues you have found earlier (filed as PDFNEWNET-39336) have been fixed in Aspose.Pdf for .NET 10.9.0.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.