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

Free Support Forum - aspose.com

SubsequentLinesIndent doesn't work properly if page break happens in between paragraph

Hi,

With the following code I’m getting mis-aligned the first line at the second page.

string lorem = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, " +
                       "sed do eiusmod tempor incididunt ut labore et dolore magna " +
                       "aliqua. Ut enim ad minim veniam, quis nostrud exercitation " +
                       "ullamco laboris nisi ut aliquip ex ea commodo consequat. " +
                       "Duis aute irure dolor in reprehenderit in voluptate velit esse " +
                       "cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat " +
                       "cupidatat non proident, sunt in culpa qui officia deserunt " +
                       "mollit anim id est laborum.";
        var doc = new Document();
        var page = doc.Pages.Add();

        for (int i = 0; i < 100; i++)
        {
            page.Paragraphs.Add(new TextFragment(lorem)
            {
                HorizontalAlignment = HorizontalAlignment.Justify,
                TextState =
                {
                    FontSize = 12,
                    LineSpacing = 6,
                    FormattingOptions = new TextFormattingOptions
                    {
                        SubsequentLinesIndent = 12
                    }
                }
            });
        }

        doc.Save("TestAsposePdf.pdf");

AsposePdfTesting.png (39.7 KB)

How to fix it?

Thanks,
Vladimir

@VladimirPrihodko

Thank you for contacting support.

We have worked with the data shared by you and have been able to reproduce the issue in our environment. A ticket with ID PDFNET-44679 has been logged in our issue management system for further investigation and resolution. The ticket ID has been linked with this thread so that you will receive notification as soon as the ticket is resolved.

We are sorry for the inconvenience.