We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Custom fonts on Azure

I have a working solution that reads slides with embedded fonts when run locally on my machine. It produces both bitmap thumbnails and PDFs with the correct fonts.

When I deploy my website to Azure, the embedded fonts do not work and it reverts to some basic font. My guess is that the library is using some WinAPI calls to register fonts temporarily and Azure is not allowing/ignoring these calls.

There is a thing in .net called PrivateFontCollection which could work http://stackoverflow.com/questions/3909520/how-to-manage-custom-fonts-in-web-application-system-drawing

But I would need a way to supply the custom collection to the Aspose libraries. Maybe the libraries should be changed to use PrivateFontCollection rather than WinAPI calls (if I’m correct in that assumption).

Does anyone know of a way of doing that or otherwise achieving this?

Hi Alan,

Thanks for inquiring Aspose.Slides.

I have observed the requirements shared by you and like to share that the alternate default fonts are used for rendering when desired font is inaccessible or missing. I request you to please provide a sample application along with embedded font in it which is reproducing issue on your end so that we may investigate on our end.

One solution that I also offer you in this situation is to copy the used fonts in some directory without installing them. Aspose.Slides provides the facility to load the fonts externally from specified location without being installed. You can keep as many fonts in desired directory and set its path in your application using following code just after setting the license and before loading the presentation.

String path = @"D:\Aspose Data\Fonts_posboss\";
FontsLoader.LoadExternalFonts(new String[] { path });

I hope this will work in your scenario. Please share, if I may help you further in this regard.

Many Thanks,