Matterhorn 31-006 · PDF/UA-1 UA1:7.21.3.3-1
CMap not in Table 118 and not embedded in the PDF
A predefined CMap must be one of the standard names; anything else must be embedded in the file.
The condition, as the protocol states it. “A CMap is neither listed as described in ISO 32000-1:2008, 9.7.5.2, Table 118 nor is it embedded.”
Matterhorn Protocol 1.1, checkpoint 31, index 31-006, section UA1:7.21.3.3-1. Software can decide this one on its own.
What a screen reader actually does
Without the CMap, character codes cannot be interpreted at all.
What the CMap does that nothing else can
In a composite (Type0) font, the content stream does not hold characters. It holds byte strings, and the font’s /Encoding — a CMap — is what turns them into something:
- It says how many bytes make one code.
Identity-Hreads two bytes at a time. A Shift-JIS CMap such as90ms-RKSJ-Hmixes one-byte and two-byte codes. A UTF-8 CMap reads one to four. Without the CMap, the viewer does not know where one character ends. - It maps each code to a CID, which the descendant font turns into a glyph.
The ToUnicode CMap, which supplies the text a screen reader gets, is keyed by those same codes. So if the codes cannot be found, neither can the text.
Two ways to provide one
A font can name a predefined CMap, which costs nothing because the viewer is expected to have it:
/Encoding /UniJIS-UTF16-H
or embed one as a stream:
/Encoding 14 0 R % a stream with /Type /CMap, /CMapName, /CIDSystemInfo
“Predefined” has a precise meaning: the 61 names in ISO 32000-1, section 9.7.5.2, Table 118. They fall into five groups — Adobe-GB1 (simplified Chinese: the GB… and UniGB… CMaps), Adobe-CNS1 (traditional Chinese: B5pc, ETen, HKscs, CNS, UniCNS…), Adobe-Japan1 (83pv, 90ms, 90msp, 90pv, Add, EUC, Ext, H, V, UniJIS…), Adobe-Korea1 (KSC…, UniKS…), and the two Identity CMaps.
Condition 31-006 is the third case: a name that is not on the list, and no stream.
How a file ends up there
A real CMap that is not in the standard. Adobe’s CMap resources run well past Table 118. UniJIS-UTF8-H, UniJIS-UTF32-H and UniJIS2004-UTF16-H are all published Adobe-Japan1 CMaps, maintained by Adobe. A producer on a machine that has them can name them, and the file renders on that machine and on any other that has them too. It is not a PDF/UA file, because nothing guarantees the next machine does.
A name that is almost right. PDF names are case-sensitive: /identity-h is not /Identity-H. A forgiving viewer may cope; a strict one has no CMap.
What the reader gets
It depends entirely on the machine. Where the viewer has the CMap, the codes are split correctly, the ToUnicode map applies, and the text reads normally. Where it does not, the viewer has to guess how to split the bytes or give up — and one wrong guess about where a character ends can throw off the characters after it.
How much a wrong split costs is easy to show. The test file for this page has two-byte codes and names UniJIS-UTF8-H, which the Poppler install it was checked on does have. Poppler applied it faithfully and split each two-byte code into two one-byte codes, so pdftotext returned 1 4 2 8 9( 2 0 1 4 ) for text that reads 14289 (2014). That file is artificial — its bytes were written for Identity-H — but it is exactly what happens when the CMap a viewer uses is not the one the bytes were written for. For a screen-reader user the result is spaced-out digits at best, and for Japanese or Chinese text it is wrong characters or silence.
How to check it free
pdffonts (Poppler) prints the CMap name in its encoding column for every composite font:
name type encoding emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
ABCDEF+JPGothic-Regular CID TrueType UniJIS-UTF8-H yes yes yes 11 0
Custom there means the CMap is embedded, which passes. Any other value must be one of the 61 names in Table 118, spelled exactly.
Acrobat Pro. Document Properties (File → Properties, or Menu → Document Properties in the newer interface) → Fonts lists every font with its type and the encoding used to display it, as Adobe documents the tab. For a composite font the encoding is the CMap.
veraPDF with its PDF/UA-1 profile tests it under clause 7.21.3.3.
How to fix it
Acrobat has no command that embeds a CMap or changes which one a font uses. Adobe’s own advice for character-encoding failures is to re-create the PDF, and that is the fix here.
Re-export so the font uses Identity-H with a ToUnicode CMap, or so the producer embeds the CMap it uses.
Or embed the CMap yourself, if you have the exact resource the file names (Adobe publishes them in its cmap-resources repository). That means adding a stream object with /Type /CMap, /CMapName and /CIDSystemInfo and pointing /Encoding at it, which qpdf --json-output and --update-from-json can do. It is low-level work, and if that CMap is itself built on another one with usecmap, the condition moves to 31-008 rather than going away.
What Taggart does
For every Type 0 font that text is set in, Taggart looks at the CMap name. If /Encoding is a stream, the CMap is embedded and passes, whatever it is called. If it is a name, Taggart compares it — exactly, case included — with the 61 names in Table 118, and reports anything else as a blocker:
/ABCDEF+JPGothic-Regular uses the CMap ‘UniJIS-UTF8-H’, which is neither listed in ISO 32000-1 Table 118 nor embedded in the file.
The finding carries the font’s object number and the first page it appears on. There is no fix in Taggart: it carries no CMap resources to embed, and it does not rewrite a font’s encoding. The finding stays a blocker until the file is re-made, and Taggart will not write the PDF/UA identifier while it stands.
How Taggart handles it
Taggart checks for this condition automatically and reports it as a blocker, with where in the file it found it.
Whatever Taggart changes, the page still looks identical. Fixes edit the PDF object model, not the content streams, and every remediation is re-rendered and compared against the original at structural similarity ≥ 0.999 before you get the file back. A tool that quietly reflows your document is worse than no tool.
Frequently asked questions
Which CMaps are allowed without embedding?
The 61 listed in ISO 32000-1 Table 118: Identity-H and Identity-V, and the predefined Chinese, Japanese and Korean CMaps such as UniGB-UTF16-H, 90ms-RKSJ-H or UniKS-UCS2-H. A conforming viewer is expected to know those by name. Any other CMap has to be in the file.
UniJIS-UTF8-H is a real Adobe CMap. Why does it fail?
Because real is not the test; listed is. Adobe publishes many more CMap resources than ISO 32000-1 lists — UTF-8 and UTF-32 variants, the JIS2004 ones — and a viewer may or may not have them. The standard draws the line at Table 118, and anything past it must travel with the document.
Is a typo in the name the same failure?
Yes. PDF names are case-sensitive, so /identity-h is not /Identity-H; it is an unlisted CMap that is not embedded, and a viewer that does not happen to forgive the spelling has no CMap at all.
Does an embedded CMap with a predefined name count as embedded?
Yes. If /Encoding is a stream, the CMap is in the file, whatever its /CMapName says. Whether that embedded CMap in turn leans on an unlisted one through /UseCMap is a separate condition, 31-008.
Where this sits in the standards
| Standard | Reference |
|---|---|
| Matterhorn Protocol 1.1 | Checkpoint 31 (Fonts), index 31-006 |
| PDF/UA-1 (ISO 14289-1) | Clause 7.21.3.3-1 |
| WCAG 2.1 | 1.3.1 Info and Relationships — Level A |
| EN 301 549 / Section 508 / ADA Title II | All three point at WCAG 2.1 Level AA for non-web documents, so a Level A or AA criterion here is in scope for each of them. |
Related conditions
- 31-008 A CMap references another CMap which is not listed in ISO 32000-1 Table 118A UseCMap chain must terminate at a predefined CMap.
- 31-007 The WMode entry in a CMap dictionary is not identical to the WMode value in the CMap streamWriting mode (horizontal or vertical) must be declared consistently in the dictionary and the stream.
- 31-001 CIDSystemInfo Registry values are not identicalThe CMap and the descendant CID font must agree on the character collection registry.
- 31-027 A font dictionary does not contain the ToUnicode entry and no exemption appliesA ToUnicode CMap is required unless the font uses MacRoman/MacExpert/WinAnsi encoding, or is a Type 1/Type 3 whose glyph names are all in the Adobe Glyph List or the Symbol set, or is a Type 0 whose descendant uses a standard Adobe character collection, or is a non-symbolic TrueType.
Other conditions in checkpoint 31
Checkpoint 31 covers fonts. These are its other failure conditions; the ones without a link are in the rule set but do not have a written page yet.
- 31-001 CIDSystemInfo Registry values are not identicalThe CMap and the descendant CID font must agree on the character collection registry.
- 31-002 CIDSystemInfo Ordering values are not identicalThe CMap and the descendant CID font must agree on the character collection ordering.
- 31-003 CIDSystemInfo Supplement of the CID font is lower than that of the CMapThe font's character collection supplement must be at least as new as the CMap's, or the CMap may reference CIDs the font does not define.
- 31-004 A Type 2 CID font contains neither a stream nor the name Identity as CIDToGIDMapCIDToGIDMap must be either the name /Identity or a stream mapping CIDs to glyph indices.
- 31-005 A Type 2 CID font does not contain a CIDToGIDMap entryThe entry is absent entirely.
- 31-007 The WMode entry in a CMap dictionary is not identical to the WMode value in the CMap streamWriting mode (horizontal or vertical) must be declared consistently in the dictionary and the stream.
- 31-008 A CMap references another CMap which is not listed in ISO 32000-1 Table 118A UseCMap chain must terminate at a predefined CMap.
- 31-009 For a font used by text intended to be rendered the font program is not embeddedPDF/UA-1 requires every font used for visible text to be embedded, so the document renders and extracts identically everywhere. A glyph counts as rendered if the text render mode is not 3.
- 31-010 A font program is embedded that is not legally embeddable for unlimited, universal renderingThe font's embedding permission bits forbid the kind of embedding used. Machines can read the flags but the flags may not reflect the actual licence.
- 31-011 The embedded font program does not contain glyphs for all referenced glyphsThe subset embedded in the file is missing glyphs the content stream asks for — very common when a document is edited after subsetting.
- 31-012 A glyph present in an embedded Type 1 font program is not listed in CharSetCharSet must accurately list the glyphs in the embedded subset.
- 31-013 A glyph listed in CharSet is not present in the Type 1 font programCharSet promises glyphs the font does not contain.
- 31-014 A glyph present in an embedded CID font program is not listed in CIDSetCIDSet must accurately list the CIDs in the embedded subset.
- 31-015 A glyph listed in CIDSet is not present in the CID font programCIDSet promises CIDs the font does not contain.
- 31-016 Glyph widths in the font dictionary and the font program differThe /Widths array must agree with the embedded font program.
- 31-017 A non-symbolic TrueType font has no non-symbolic cmapA font declared non-symbolic must actually carry a (3,1) or (1,0) cmap subtable.
- 31-018 A glyph cannot be looked up by any non-symbolic cmap entrySome rendered glyph is unreachable through the declared cmap tables.
- 31-019 The font dictionary for a non-symbolic TrueType font does not contain an Encoding entryNon-symbolic TrueType fonts must declare an /Encoding.
- 31-020 The Encoding dictionary for a non-symbolic TrueType font does not contain BaseEncodingIf /Encoding is a dictionary it must name a /BaseEncoding.
- 31-021 BaseEncoding is neither MacRomanEncoding nor WinAnsiEncodingOnly MacRomanEncoding and WinAnsiEncoding are permitted for non-symbolic TrueType fonts.
- 31-022 Differences contains glyph names not listed in the Adobe Glyph ListGlyph names in /Differences must be resolvable through the Adobe Glyph List so a processor can derive Unicode.
- 31-023 Differences present but the font has no (3,1) Microsoft Unicode cmapThe Differences array is resolved through the (3,1) cmap; without it the mapping is undefined.
- 31-024 The Encoding entry is present in the font dictionary for a symbolic TrueType fontSymbolic TrueType fonts must not carry an /Encoding; the font's own cmap governs.
- 31-025 The embedded font program for a symbolic TrueType font contains no cmapA symbolic TrueType font must contain at least one cmap subtable.
- 31-026 A symbolic TrueType font has multiple cmaps but none is a (3,0) Microsoft Symbol cmapWith multiple cmaps present, a (3,0) symbol cmap is required to disambiguate.
- 31-027 A font dictionary does not contain the ToUnicode entry and no exemption appliesA ToUnicode CMap is required unless the font uses MacRoman/MacExpert/WinAnsi encoding, or is a Type 1/Type 3 whose glyph names are all in the Adobe Glyph List or the Symbol set, or is a Type 0 whose descendant uses a standard Adobe character collection, or is a non-symbolic TrueType.
- 31-028 Unicode values in the ToUnicode CMap are zeroU+0000 is not a valid mapping target; it usually means the producer could not determine the character and wrote a placeholder.
- 31-029 Unicode values in the ToUnicode CMap are U+FEFF or U+FFFEByte-order marks are not characters and must not appear as mapping targets.
- 31-030 Characters used in text showing operators reference the .notdef glyphThe content stream paints glyph index 0, which is by definition "no glyph" — typically a hollow box or nothing at all.
Check your own file. Taggart’s validator is free and unlimited — 75 of the 87 Matterhorn conditions software can decide, with the other 12 listed for you to confirm; no watermark, no expiry, and no account needed up to 60 pages.
Checked with Taggart on a generated file that fails this condition on . The Acrobat steps follow Adobe’s documentation and were not walked through by hand. Last updated .