Free Support Forum - aspose.com

Preserve Text Order when Converting Word Document with Mixed Hebrew English Text & Digits to PDF using C# .NET

Hello,
I am using Aspose.words version 18.10 for converting word documents to PDF.
I want to upgrade to version 20.6 and doing some tests.
I’ve noticed that the text order in some words changes after converting from word to PDF.
The text order was OK in version 18.10 and not OK in version 20.6.

The text continas some Hebrew letters, English letters and digits.
For example:
Text in word:
image.png (1.7 KB)
Text after converting to PDF:
image.png (3.0 KB)
Note that the 50X50 has changed to X5050 after converting to PDF.
In version 18.10 the text was OK in the PDF:
image.png (3.0 KB)

I am attaching here a zip file that contains:
the word document: word.docx
the PDF document that was OK in version 18.10: pdf_good.pdf
the PDF document that was not OK in version 20.6: pdf_bad.pdf
example.zip (82.4 KB)

The code I use for converting word to PDF is:

Aspose.Words.Document doc = new Aspose.Words.Document(wordFileName);
PdfSaveOptions saveOptions = new PdfSaveOptions();
saveOptions.FontEmbeddingMode = PdfFontEmbeddingMode.EmbedNonstandard;
saveOptions.EmbedFullFonts = false;
doc.Save(pdfFileName, saveOptions);

any help would be appreciated,
Thanks!

@aviaw,

While using the latest 20.6 version of Aspose.Words, 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-20727. Your thread has also been linked to this issue and you will be notified as soon as it will get resolved in future. Sorry for the inconvenience.

The issues you have found earlier (filed as WORDSNET-20727) have been fixed in this Aspose.Words for .NET 20.9 update and this Aspose.Words for Java 20.9 update.