Hello,
We are experiencing an issue with Aspose.PDF.Drawing while working with tables. Specifically, when we enable word wrapping for a cell using the property:
cell.IsWordWrapped = true;
If the text within the cell is short and does not wrap, everything works as expected. However, when the text is long and wraps to the next line, it unexpectedly becomes underlined.
This behavior does not occur in Aspose.PDF; it works correctly there.
Could you please help us resolve this issue? Is this a known bug, or are there specific settings we need to adjust?
Thank you for your assistance!
Simple code:
Document doc = new Document();
Page page = doc.Pages.Add();
Table table = new Table();
page.Paragraphs.Add(table);
table.ColumnWidths = "100 100";
Row row = table.Rows.Add();
Cell cell = row.Cells.Add();
cell.Border = new BorderInfo(BorderSide.All, 1f);
cell.Margin = new MarginInfo(10, 10, 10, 10);
cell.Alignment = HorizontalAlignment.Left;
TextFragment textFragment = new TextFragment("Long text so try to check how it will be wrapped");
textFragment.TextState.Underline = false;
textFragment.TextState.LineSpacing = 5;
textFragment.TextState.FontStyle = FontStyles.Regular;
cell.Paragraphs.Add(textFragment);
cell.IsWordWrapped = true;
doc.Save("output.pdf");