Hello team,
Presently we are using Aspose word-java for generating PDF document by using a template with LINQ Report engine. We have hosted our application in Linux environment. The PDF document is also generated from Linux environment. In the output PDF document, the font is not matched with the template word document. FYI, we are using ‘Arial’ font in word template, we are expecting the same font in PDF document too. Is is possible to keep same font in PDF document which is used in word template?
Thanks in advance.
Font issue while generating PDF document using template with LINQ Report Engine in Linux environment
@ra.dinesh Most likely the problem occurs because the font is not available in the environment where the document is converted to PDF. If Aspose.Words cannot find the fonts used in the document the fonts are substituted. This might lead into the layout differences due to differences in fonts metrics. You can implement IWarningCallback to get a notification when font substitution is performed.
The following articles can be useful for you:
https://docs.aspose.com/words/java/specify-truetype-fonts-location/
https://docs.aspose.com/words/java/install-truetype-fonts-on-linux/
If after providing the required font the problem still persist. Please attach your input and output documents here for testing. We will check the issue and provide you more information.
Hello again, Thanks for your help. It works now