i use aspose.words to convert doc to pdf. the pdf file layout is not matched. font weight and font space are wrong. the attachments are original doc file and converted pdf file. please help!
can anyone help?
Thanks for your inquiry and sorry for the delayed response. Please note that Aspose.Words requires TrueType fonts when rendering documents to fixed-page formats (PDF, XPS or SWF). Aspose.Words selects the fonts according to the following process:
- Aspose.Words tries to find the required font among the fonts embedded in the original document. Some document formats such as DOCX can contain embedded fonts.
- Next, Aspose.Words tries to find a font on the file system with an exact font name match.
- If Aspose.Words cannot find a font with the exact name match, Aspose.Words attempts to select the most suitable font from all of the available fonts.
- Finally, if Aspose.Words cannot find any fonts on the file system, it renders the document using the free Gentium font that is embedded into the Aspose.Words assembly.
Moreover, I would suggest you please read 'Rendering and Printing' section in documentation below:
I hope, this helps.
PS: Please upgrade to the latest version of Aspose.Words i.e. 13.5.0 from here. I have attached the PDF document that is produced on my side here for your reference.
thanks for you reply.
I looks the file you produced, the file format is not correct too.
specially the width between two words.
Thanks for your inquiry. Please also attach the fonts (e.g. STZhongsong, 华文中宋) the problematic text is formatted with here for testing. I will investigate the issue further on my side and provide you more information.
Thanks for your reply.
The attachment is the fonts.
Thanks for your inquiry.
chichuidan:thanks for you reply.I looks the file you produced, the file format is not correct too.specially the width between two words.
While using the latest version of Aspose.Words i.e. 13.5.0, I managed to reproduce this issue on my side. I have logged this issue in our bug tracking system. The issue ID is WORDSNET-8392. Your thread has also been linked to this issue and you will be notified as soon as it is resolved. Sorry for the inconvenience.
Thanks a lot.