Get font type in pdf

Hi,
Is there a way to get all font type information from a pdf (.net )?
Fontutilities.GetAllfonts() method can not identiy the font type in xobject, such as the example.pdf.
Thank you all!
example.pdf (8.1 KB)

@Jason_yi

By font type, do you mean its format? like TTF, OTF, etc.? Please share a bit more details of your requirements so that we can further proceed accordingly.

I mean a list of font type names , the fonts which are used in the pdf, such as “Times New Roman”,

@Jason_yi

We tested the scenario in our environment using below code snippet and noticed that the API returned Helvetica and ZapfDingbats Fonts:

Document doc = new Document(dataDir + "example.pdf");
Aspose.Pdf.Text.Font[] fonts = doc.FontUtilities.GetAllFonts();
foreach (Aspose.Pdf.Text.Font font in fonts)
{
 var embedded = font.IsEmbedded;
 var subset = font.IsSubset;
 Console.WriteLine(font.FontName + " embedded = " + embedded);
}

Are you receiving similar results at your side? Please share the results you are getting and we will log an issue in our issue management system to address it accordingly.

Thank you sir.
You can see from the screenshot, in the example.pdf, it has a font of SimSun, this content is display in the pdf, but this font can not be identified by the method.
Helvetica and ZapfDingbats Fonts are returned as the same.
example.png (81.5 KB)

@Jason_yi

We have logged an issue as PDFNET-51531 in our issue tracking system for further investigation. We will look into its details and let you know as soon as it is fixed. Please be patient and spare us some time.

We are sorry for the inconvenience.

Thank you sir.

1 Like

Hi sir,
Is there any progress on the problem?

@Jason_yi

The ticket has recently been logged in our issue management system and it is pending for review. Please note that we will investigate and resolve it on a first come first serve basis. You will be informed via this forum thread as soon as we have some definite updates regarding issue fix. Please be patient and spare us some time.

We are sorry for the inconvenience.