Helo there,
I'm trying to write a code to convert a PPTX slide to both a PNG image and a PDF. The issue I'm facing is that I have several custom font in these PPTX files. These fonts are installed locally and embedded in the PowerPoint file.
When I try to convert the files to PNG or PDF, these font are replaced by a basic font.
I've read the documentation, including about how to setup fallback and substition, However, the font is indeed installed locally, so that should not be an issue. The documentation also says that it's possible:
I've tested in a Blazor Server, WFP and Console app.
Do you have any idea about how to convert a PowerPoint to a PDF while preservin
Hi
Christopher,
Regarding - When I try to
convert the files to PNG or PDF, these fonts are replaced by a basic font. This
occurs even with a custom font installed in local:
We have tried to reproduce the
reported problem like the font being replaced by a basic font even the font installed locally, but it works properly on our end. For your reference, we have
attached the sample application which we tried to reproduce the reported
problem at our end, and it can be downloaded from the below link,
https://www.syncfusion.com/downloads/support/directtrac/general/ze/Convert-PPTX-to-PDF-1292037941.zip
While performing PPTX to PDF conversion, if the
necessary fonts are not installed in the environment, the Essential Presentation
library uses the alternate font as the default font for rendering the text in the output PDF/Image. So we suspect the problem occurs due to fonts missed in the environment. So, we suggest you install the necessary fonts in the environment
to resolve the problem.
Otherwise, by having a list of fonts in some folder, we suggest you use a font substitution
event to set the fonts which is missing in the environment.
To know more about font substitution, please refer to our
documentation from the below links.
https://help.syncfusion.com/file-formats/presentation/presentation-to-pdf#font-substitution-for-unavailable-fonts
After trying the above solutions still, issue occurs at your end, then
could you please provide the following details for further investigation,
1. Modify the attached sample as an issue reproducible sample and share us.
2. Input Presentation
document used at your end. Because we suspect that the problem might be due to custom
fonts used in the input Presentation
documents.
3. PDF document generated at your side using Syncfusion Presentation library.
4. Syncfusion version used at your side.
Note: If you have any confidential data in your input document,
please replace with some dummy data and provide us the same. We just need your
document to recreate the problem you face. So once investigated the issue, we will delete the document
permanently from our side and do not share to anyone.
Regarding - When I try
to convert the files to PNG or PDF, these fonts are replaced by a basic font.
This occurs even with font embedded in the PowerPoint file:
Currently, the Essential Presentation library
doesn’t have support to embed
a font in PPTX to PDF/Image conversion. We
have already logged this as a feature request in our database. We don’t have
any immediate plans to implement this feature. We will let you know when this
feature is implemented.
The status of the feature can be tracked through link:
https://www.syncfusion.com/feedback/38287/support-to-embed-a-font-in-pptx-document
Regarding - The
documentation also says that it's
possible:
|
Statement in UG documentation |
Explanation |
|
Embed fonts in a PowerPoint file into the converted PDF document to avoid font-related issues across different machines and different platforms. |
The statement denotes the
name of the fonts listed which fonts are used to render the text in the converted PDF.
Please refer below screenshot. |
Regards,
Anto Nihil S