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

Free Support Forum - aspose.com

Wrong position after multiline text replace

I try to replace miltiline value, but I get unexpected results with empty spaces.
Aspose pdf version 21.3
Language: Java

Example code:
var txtFragmentAbsorber = new TextFragmentAbsorber(“Lorem\s*Ipsum”);
TextFragmentCollection collection = txtFragmentAbsorber.getTextFragments();
TextFragment item = collection.get_Item(2);
item.setText(“Some Replace Text Value”);

input.pdf (12.7 KB)


I have been able to reproduce the issue on our end. A ticket with ID PDFJAVA-40638 has been created in our issue tracking system to further investigate the issue on our end. This thread has been linked with the issue so that you may be notified once the issue will be fixed.