Map missing glyphs to the notdef
glyph for TrueType (3, 1) fonts regardless if the 'post' table is defined or not (issue 6889)
This commit is contained in:
parent
e60fde73ca
commit
4855d4cc9f
@ -4362,10 +4362,12 @@ var Font = (function FontClosure() {
|
||||
var glyphId = properties.glyphNames.indexOf(glyphName);
|
||||
if (glyphId > 0 && hasGlyph(glyphId, -1, -1)) {
|
||||
charCodeToGlyphId[charCode] = glyphId;
|
||||
} else {
|
||||
charCodeToGlyphId[charCode] = 0; // notdef
|
||||
found = true;
|
||||
}
|
||||
}
|
||||
if (!found) {
|
||||
charCodeToGlyphId[charCode] = 0; // notdef
|
||||
}
|
||||
}
|
||||
} else if (cmapPlatformId === 0 && cmapEncodingId === 0) {
|
||||
// Default Unicode semantics, use the charcodes as is.
|
||||
|
1
test/pdfs/.gitignore
vendored
1
test/pdfs/.gitignore
vendored
@ -202,6 +202,7 @@
|
||||
!issue6106.pdf
|
||||
!issue6296.pdf
|
||||
!issue6298.pdf
|
||||
!issue6889.pdf
|
||||
!bug1001080.pdf
|
||||
!issue6108.pdf
|
||||
!issue6113.pdf
|
||||
|
BIN
test/pdfs/issue6889.pdf
Normal file
BIN
test/pdfs/issue6889.pdf
Normal file
Binary file not shown.
@ -1446,6 +1446,13 @@
|
||||
"link": false,
|
||||
"type": "eq"
|
||||
},
|
||||
{ "id": "issue6889",
|
||||
"file": "pdfs/issue6889.pdf",
|
||||
"md5": "397fa92da1a8bfa83dc8c20287854d15",
|
||||
"rounds": 1,
|
||||
"link": false,
|
||||
"type": "eq"
|
||||
},
|
||||
{ "id": "tamreview",
|
||||
"file": "pdfs/TAMReview.pdf",
|
||||
"md5": "8039aba56790d3597d2bc8c794a51301",
|
||||
|
Loading…
Reference in New Issue
Block a user