Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to find out which fonts are referenced and which are embedded in a PDF document

Tags:

pdf

fonts

We have a little problem with fonts in PDF documents. In order to put the finger on the problem I'd like to inspect, which fonts are actually embedded in the pdf document and which are only referenced. Is there an easy (and cheap as in free) way to do that?

like image 546
Jens Schauder Avatar asked Mar 05 '09 12:03

Jens Schauder


People also ask

How do you find out what fonts are embedded in a PDF?

To check that your fonts are embedded in Adobe Acrobat, go to File on the top menu and select Properties… then select the Fonts tab, this will list the font used in the document. You want to check that they are either (Embedded) or (Embedded Subset).

Can you identify the fonts in a PDF?

Open the PDF file with Acrobat Reader. Press "Ctrl-D" or select "Properties" from the File menu. In the Document Properties window that opens, click the "Fonts" tab to reveal the fonts embedded in the PDF.

How do I find a font that is not embedded?

Choose File > Properties and click on the Fonts tab. You'll see your fonts are usually Embedded Subsets which means that only the characters actually used are embedded. For printing, this is perfectly acceptable.


2 Answers

pdffonts command line tool originally from Xpdf, now part of Poppler.

This tool is available in most Linux distributions as part of poppler-utils package.

Example usage and output:

$ pdffonts some.pdf   name                                 type              emb sub uni object ID ------------------------------------ ----------------- --- --- --- --------- BAAAAA+Arial-Black                   TrueType          yes yes yes     53  0 CAAAAA+Tahoma                        TrueType          yes yes yes     28  0 DAAAAA+Wingdings-Regular             TrueType          yes yes yes     43  0 EAAAAA+Webdings                      TrueType          yes yes yes     38  0 FAAAAA+Arial-BoldMT                  TrueType          yes yes yes     33  0 GAAAAA+Tahoma-Bold                   TrueType          yes yes yes     23  0 HAAAAA+OpenSymbol                    TrueType          yes yes yes     48  0 
like image 145
vartec Avatar answered Oct 03 '22 08:10

vartec


Much simpler if you just want to find out the font names: run this from a terminal

strings yourPDFfilepath.pdf | grep FontName 
like image 25
michelem Avatar answered Oct 03 '22 09:10

michelem