Cell alignment html issue

I’m adding an html string to a text in a cell, when ever the string has tags inside the string that don’t start and end the string the alignment gets defaulted to left.

asText = new Aspose.Pdf.Text(getText(2));
asText.Margin.Top = Convert.ToInt32(row[2]);
asText.Margin.Left = Convert.ToInt32(row[3]);
asText.IsHtmlTagSupported = true;
asText.IsSpaced = true;
asText.IsAlignedByWord = true;
asText.TextInfo.Alignment = Aspose.Pdf.AlignmentType.Right;

asCell = asRow.Cells.Add();
asCell.Paragraphs.Add(asText);

the getText(2) returns “

<FONT face=“lucida sans”>ABCDEFGHIKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz

”;

The right and center alignment for multiple-segment text is not supported well in Aspose.Pdf. We are now working on this issue. I hope it can be solved at the end of this month.

i did a little more development with the cell and alignment. Whenever text wraps it loses the alignment. if you manually input a #$NL the next line seems to work correctly.