3

Find Which Font is Used in A PDF

 2 years ago
source link: https://jdhao.github.io/2021/10/20/find_font_used_in_pdf/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Find Which Font is Used in A PDF

2021-10-20219 words 2 mins read 9 times read

Sometimes, we are interested in which font is used for the main text in a PDF. How do we find out?

Use Adobe Acrobat PDF reader

Open the PDF in Adobe Acrobat and go to File --> Properties, under the Fonts tab page, a list of fonts embedded in in the document are listed there.

However, there does not seem to be an option to view the font used by a specific text in the document.

You can check the fonts whose encoding is Custom and look them up on Google to see which one is what you want.

Use pdffonts

We can also use pdffonts from the poppler package. First, we need to install poppler, I won’t go into detail here, check this post for the details.

After that, we can run pdffonts to find the interested fonts. It helps to narrow to the page where the text occurs. For example, if we want to find font for page 2, run the following command:

# -f: start page
# -l: end page
pdffonts -f 2 -l 2 test.pdf

This will greatly narrow down the range of fonts. You can then quickly find which font the text uses.

References

Author jdhao

LastMod 2021-10-21

License CC BY-NC-ND 4.0

Reward
Scheduling Your Tasks with Package Apscheduler

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK