Excel to PDF conversion - font embedding

Hi,


I need a way to convert XLS and DOC files into PDF. But user needs to decide whether to include all fonts, just non-standard or none at all…

In Aspose.Words there is a method perfect for that:

com.aspose.words.PdfSaveOptions.setFontEmbeddingMode(EMBED_NONSTANDARD/EMBED_ALL/EMBED_NONE);

Whether in Aspose.Cells the following method:

com.aspose.cells.PdfSaveOptions.setEmbedStandardWindowsFonts(true/false);

Can you standardize it and add the setFontEmbeddingMode method?
Can you also explain me how setEmbedStandardWindowsFonts relates to the font embedding mode?

Thanks,
Mariusz

Hi Mariusz,


Thank you for contacting Aspose support.

We have to discuss the matter internally before we can commit that if we can standardize the PdfSaveOptions as of Aspose.Words API in terms of loading and embedding fonts. We will get back to you with updates in this regard.

Please note, the setEmbedStandardWindowsFonts method from Aspose.Cells for Java API has the default value as true, means that standard windows fonts will be embedded in the resultant PDF. If this field is set to false then no fonts will be embedded.

Thank you. Is there any way to embed just non-standard fonts?

Hi Mariusz,


Please note, the current implementation of Aspose.Cells APIs can load and embed only TTC & TTF fonts so if you have any font in aforesaid formats, you can simply place them in any directory of your system and set the path using CellsHelper.setFontDir method. The Aspose.Cells API will pick those fonts (if the fonts are used in the spreadsheet) to embed them in the resultant PDF file. Rest of the font formats are not supported at the moment, and we currently do not have plans to support them in near future.

Hopefully, I have answered your concerns. Please feel free to write back in case you have more questions for us.