by John Brinkman
It strikes me that we don’t complain about big email attachments as much as we used to. We don’t mind as much when aunt Grace sends us a batch of 2MB jpg files straight from her camera. The photo quality is the same as always (sigh), but at least it doesn’t bring our internet connection and email client to it’s knees anymore. Heck, even Dad and Mom now have a broadband connection.
But just because we *can* send big attachments doesn’t mean we should. Let’s have some professional pride in making sure that our files are as lean as possible. Today’s topic is about managing your fonts so that your PDF forms are tidy and small.
I’m sure you already knew this, but I’ll repeat the basics. PDF files can embed font definitions. The advantage of embedding a font is that it guarantees your PDF will look exactly the same no matter where it’s opened — you don’t have to worry whether the user opening your form has copies of the fonts you used or not. If you don’t embed fonts, and the user doesn’t have "Charlemagne Std" on their system, Reader will display the PDF with a substitute font. It won’t look the same.
Of course, the disadvantage of embedding fonts is that they’re big. They bump up the size of your PDF in a big hurry. Often around 200K per font.
Here are some notes to remember about font usage:
Note #1: If you’re using common fonts, and especially if you can tolerate some variance in your page display, then don’t embed fonts. Designer embeds all fonts by default:
Note #2: If you’re embedding fonts, use as few fonts as possible in your form design.
There was a reason I just finished updated the form reporter. It will tell you what fonts you have used and how many instances of each. I recently reviewed a form that showed this in the report:
All fonts were embeded. The form had one object using Times New Roman. That one instance bloated the PDF by over 200K. After I consolidated all font instances to Myriad Pro, the form was a total of 600K smaller.
Note #3: Not all fonts are equal in size
I haven’t done an extensive accounting, but it appears that Myriad Pro is smaller than most. A small form with Myriad Pro embedded is 77K. While the not-embedded version is 13K. Why does embedding Myriad Pro cost only 64K while Times New Roman was 200K? I’m told that the embedded Myriad Pro excludes character sets that are not in use e.g. Cyrillic.
Note #4: Reader installs fonts
On my system, Reader X installed Minion Pro, Myriad Pro and Courier Std. There are asian font packs for Reader available for download. I’d like to think that for most users having Adobe Reader installed fonts would mean they don’t need to be embedded in your PDFs.
Note #5: Fonts can be subset
If you use a font in an interactive form field, you need to have the entire font embeded. But if the font is used only in boilerplate text, then you only need to embed the definitions of the characters that are found in the PDF. In this case we can reduce the size by embedding only a subset of the font. Options to embed subset fonts are not exposed in Designer. This is server-side processing. And as long as you’re mucking in that area, you can also explicitly choose on a font-by-font basis which are embedded and which are never embedded.
Edit Fonts in Designer
Here’s the problem: The form report shows you have one instance of Times New Roman in your form design. Now find that one instance among the 300 fields on your form and change it. If it were me, I’d probably switch over to source view. But that’s not very user friendly.
This becomes yet another case where Designer macros can be very helpful. Here is a zip file that contains a Designer macro to perform global font substitutions. When you run it, you’ll get a dialog like this:
The macro will replace the font references it finds in <font> elements, as well as the font references it finds inside rich text values. Just be sure to type the names of the fonts correctly. If you mis-spell the replacement font, the macro will happily give you a form full of "Myirod Pro" references. When the macro completes, look in Designer’s log display for a summary of the changes.