Home » Acrobat 8 PDF Optimizer Review Continued

Acrobat 8 PDF Optimizer Review Continued

Summary:

Unembed or Subset Fonts Depending on the font, each additional font face can easily add 40K or more of data to PDF files if fully embedded (unusual) or less if subset (the norm). For smaller PDFs, that can make a big difference in file size. Embedding fonts ensures that your document will be rendered exactly …

Read more

Unembed or Subset Fonts

Depending on the font, each additional font face can easily add 40K or more of data to PDF files if fully embedded (unusual) or less if subset (the norm). For smaller PDFs, that can make a big difference in file size. Embedding fonts ensures that your document will be rendered exactly as you intended, but bulks up your PDF. If you subset your fonts Acrobat uses only the glyph descriptions (graphical outlines of characters) of the actual characters used in your document, using a subset of the entire font face (see Figure 12). Note that Type 1 fonts can be represented in a special compact format in PDF files.

Font Standardization: Base 14

Adobe requires that all PDF applications include the so-called BASE 14 set of standard fonts that can be used unembedded. The fonts are the four faces of these Latin typefaces (Courier, Helvetica, and Times) plus Symbol and ITC Zapf Dingbats.

If you use fonts from the BASE 14 set of basic fonts found in most computers you can safely unembed your fonts and Acrobat will use these system fonts (see Figure 13), provided your users are on Windows NT/2K/XP or Mac OS X using Adobe Acrobat. The most common case of unembedding error is the absence of the Euro symbol, which is not present in all versions of the Base 14 on all OS platforms (e.g., Win95 & 98 don’t have this symbol).

Acrobat’s Font Fallback Method

If Acrobat cannot find the font, it will substitute similar fonts for you. Without the original fonts, Acrobat first matches installed fonts (BASE 14), then “similar” fonts, then multiple master fonts, and finally a “last resort” font. Multiple master fonts (AdobeSansMM and AdobeSerifMM) are an extension of the Type 1 font format that allow the creation of many type faces from one font. Note that if there are any symbols, international glyphs, or non-roman languages you must embed your fonts for these characters to appear.

font settings dialog acrobat 8

Figure 13: Font Settings Dialog

Use Outline Fonts with Caution

For Web use, outline fonts can give the smallest files when you start with a font-embedded PDF, but can have accessibility and font fidelity issues. If you do outline fonts, make sure that you retain the textual data. In Acrobat 7, if you choose Flatten transparency -> Outline fonts, Adobe converts fonts to “paths” (drawing instructions in the main part of the PDF). In Acrobat 8 use the Flattener Preview dialog in the Print Production menu (see above). For CID fonts (Character Identifier, two-byte Unicode-based fonts), outlines should yield smaller files. For simple Type 1 and TrueType fonts, outlines will probably be larger (assuming an already subset font). When outlining I created smaller files starting from a file with embedded fonts than a file with no embedded fonts.

PDF Enhancer 3.1 on the other hand, converts the font data from complex Type 1, TrueType, and OpenType to simple Type 3 fonts, reducing the size of the file while keeping the textual data, allowing search engines to index and search your PDF documents. In my tests however, using the “Convert All fonts to outlines” option in PDF Enhancer 3.1 increased file size.

Delete Unused Objects

In the Discard Objects panel you can remove features that you don’t use from your PDF (see Figure 14), and optimize curved lines in CAD drawings. Acrobat 8 Pro adds the “flatten form fields” option that makes form fields unusable and does not change their appearance. Your form data is merged with the page to become page content. Discard Document Tags removes tags from the document, which also removes the accessibility and reflow capabilities for the text. I usually leave the document structure alone, since it makes the document more accessible. The “tagged PDF” data also makes your PDFs more easily repurposed for different form factors (palmtops for example). If you do leave the document structure, make sure you enable the “Compress Document Structure” option for PDF 1.3 and later.

discard object settings dialog acrobat 8

Figure 14: Discard Objects Settings Dialog

Discard User Data

Acrobat 8 has broken out user-specific cleanups to the new Discard User Data panel of the PDF Optimizer (see Figure 15). You can use this panel to delete any personal information you don’t want to share with others. I usually leave “Discard Document Information and Metadata” unchecked, as this information is good for SEO and the semantic Web. This checkbox removes information in the document information dictionary and all metadata streams. You can use the Save As command to restore metadata streams to a copy of the PDF.

discard user data settings dialog acrobat 8

Figure 15: Discard User Data Settings Dialog

Clean Up Your Document

The Clean Up panel does some additional housekeeping to shrink your PDF and display the first page faster (Optimize the PDF for fast web view). The first two options use Flate to encode unencoded data streams (like outline fonts) and substitute Flate for LZW encoding (more efficient). Fast web view “linearizes” to make the first page selected display quickly, by essentially duplicating some data in the PDF. The PDF will be larger, but it will feel much faster (see Figure 16).

cleanup settings dialog acrobat 8

Figure 16: Clean Up Settings Dialog

Note that compress entire file is available only in Acrobat 6 or higher (PDF version 1.4). Using this option will spawn an error message in Acrobat 5 or lower (see Figure 17).

error message in acrobat 5 opening compressed Acrobat 6 document

Figure 17: Error message in Acrobat 5 opening compressed Acrobat 6 document

Save the Optimized PDF

Once you’ve finished tweaking your PDF optimizer settings you can save them for reuse for subsequent PDFs (see Figure 10). Save your optimized PDF as a new file to compare it to the original. Table 2 shows a comparison of different optimization settings for Chapter 2 of Speed Up Your Site in Acrobat 7 Pro, saved in different PDF versions. The first column of sizes is for the subsetted font version of the file (starting at 123K for the original partially-optimized file). The second column is for the refried version without embedded fonts. The third column shows the outlined version of the first version. The refried version optimized in Acrobat 7 Pro for Acrobat 5 compatibility is the one we’d use for the Web, at 96.6K it is 21.5% smaller than the original. The outlines-only Acrobat 5-compatible PDF is over 50% smaller than the original subsetted version (60.8K versus 123K) but has some font fidelity issues. Note that “compress entire file” shaves 11% to 20% off of PDF file size, but is not compatible with Acrobat 5.

Acrobat VersionPDF VersionFile Size (K)Notes
Subset fontsRefried-unembedOutlines-unembed (from 123K file)
4.01.3123K98.85K*96.6KSubset Fonts, ebook/refry-noembed/outline from 123K file
5.01.4122.1K96.6K^60.8KJBIG2/JBIG2/outline fonts from 123K
6.01.5107.95K85.12K48.40KCompress entire file
7.01.6107.94K85.11K48.39KSlight change in file size

*Note that the 98K 2opt.pdf is a refried PDF without embedded fonts that closely matches the original document.

^Recommended version for web use.

Optimizing in Acrobat 8 Professional

Next we optimized the original chapter file in Acrobat 8 Pro (pre-release) to compare the two versions. Acrobat 8 Pro did a slightly better job then the previous version in shrinking our PDF (see Table 3). We experienced savings from 2.5% to 3.3% over Acrobat 7. Distiller 8 was faster to optimize than Distiller 7. Re-refrying saved even more, nearly 6% off of Acrobat 7 (5.7% for Acrobat 5 re-refried version).

For maximum savings choose “reduce file size” to discard unused elements in the Document menu, then refry. Using this technique with Acrobat 8 level compatibility we shrank the example PDF 6.6% smaller than Acrobat 7 (see note “#”). We found that re-refrying (refrying twice) using Acrobat 8 level compatibility at maximum optimization settings gave the smallest file (81,316 bytes). Don’t refry more than twice, the third time wasn’t smaller and you lose font fidelity if you overfry your PDFs.

Acrobat VersionPDF VersionFile Size (K)Notes
Subset fontsRefried-unembedOutlines-unembed (from 123K file)
4.01.3125,928 (123K)96,210 (93.95K)N/ASubset Fonts/refry-noembed
5.01.4121,840 (119K)96,187 (93.93K)
(93,301 re-refried)*
N/AJBIG2 /CCITT Group 4 – (2.5%/2.7% smaller than Acrobat 7)**
6.01.5107,428 (104.91K)84,236 (82.26K)N/AJPEG2000 is slightly smaller than JPEG/Compress entire file/maximum object level compression (Distiller) (2.8%/3.3% smaller than Acrobat 7)
7.01.6107,432 (104.9K)84,253 (82.28K)N/AJPEG2000/Slight change in file size
8.01.7107,429 (104.9K)84,197# (82.22K)N/AJPEG2000/Slight change in file size/reduce file size/refry level 2 gave best results (see #)

*Note the Acrobat Version 5 re-refried file would be the one we’d use for the Web.

**Note you can save more space by using “reduce file size” option under the Document menu. Doing this to our version 5 original brought it down to 121,677 and refrying got it down to 96,182 bytes. This is 5 bytes less than the non-reduced refried version.

#For Acrobat 8 the smallest refried result was obtained first using Document -> Reduce File Size down to 119K, then exporting to Postscript at Postscript Level 2 (level 3 is slighter larger) then refrying using Distiller using maximum compression settings (minimum image quality, 72/150 dpi). Re-refrying bought us another 3.4%. Optimizing with PDF Optimizer then refrying yielded larger files.Optimize PDF Files > PDF Optimizer > PDF Optimizer 2 > Combine Files > Optimization Tools