TXT file rendered not as expected


Attached is a simple TXT file. When the file is rendered some unexpected points are added.
For example “1 test” is rendered as “1. test” - see attached screenshots.

Is this a bug or a feature? Is there a setting to avoid such text manipulations?

Best Regards,

Hi Vassil,

Thanks for your inquiry.

While using the latest version of Aspose.Words i.e. 16.11.0, we managed to reproduce this issue on our end. We have logged this issue in our bug tracking system. The ID of this issue is WORDSNET-14436. Your request has also been linked to the appropriate issue and you will be notified as soon as it is resolved. Sorry for the inconvenience.

Best regards,

Hi Vassil,

It is to update you that our product team has completed the analysis of this issue. The text

1 test
2 test
3 test
4 test
5 test
6 01256

is interpreted by Aspose.Words as a numbered list. A default list with Arabic numbers is generated, in which a number is separated by a dot and a tab. The dots are written into the output PDF file.

MS Word does not detect the text as a numbered list, and PDF file that is generated by MS Word does not contains dots.

The LoadOptions class contains the AllowTrailingWhitespaceForListItems option on switching that to off the output file is generated as the you expect.

If I add dots after numbers in the input text file, MS Word does not still recognize the text as a numbered list, but Aspose.Words does.

Please tell if the following solution is acceptable for you?

LoadOptions options = new LoadOptions();
options.AllowTrailingWhitespaceForListItems = false;
Document doc = new Document(MyDir + @"161116_Points_Added.txt", options);
doc.Save(MyDir + @"17.1.0.pdf");

See attached 17.1.0.pdf

Best regards,

Yes, this option is acceptable. I would expect the default value to be false, but this is not a big issue.

Thanks for the solution!
Best Regards,

Hi Vassil,

Thanks for your feedback. Please continue using this workaround until our product team comes up with a solution to this problem. We will inform you via this thread as soon as this issue is resolved. We apologize for any inconvenience.

Best regards,

Hi Vassil,

Regarding WORDSNET-14436, our product team has completed the work on your issue and has come to a conclusion that this issue is not a bug in Aspose.Words. Your issue (WORDSNET-14436) has now been closed with ‘Not a Bug’ resolution. Please continue using the workaround mentioned in this post.

Best regards,