mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-22 16:18:08 +02:00
Only use base encoding if it's populated. (bug 1727053)
The font dict in this file has an encoding entry, but only specifies a differences map. The base encoding is empty in this case and shouldn't be used.
This commit is contained in:
parent
306119b12a
commit
a7f807b059
4 changed files with 8 additions and 1 deletions
|
@ -2629,7 +2629,7 @@ class Font {
|
|||
let glyphName;
|
||||
if (this.differences[charCode] !== undefined) {
|
||||
glyphName = this.differences[charCode];
|
||||
} else if (baseEncoding[charCode] !== "") {
|
||||
} else if (baseEncoding.length && baseEncoding[charCode] !== "") {
|
||||
glyphName = baseEncoding[charCode];
|
||||
} else {
|
||||
glyphName = StandardEncoding[charCode];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue