1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-22 16:18:08 +02:00

Always fallback to system font on font failure.

The font in the PDF is marked as a CIDFontType0, but the font file is
actually a true type font. To fully address this issue we should really
peek into the font file and try to determine what it is. However, this
is the first case of this issue, so I think this solution is acceptable for
now.
This commit is contained in:
Brendan Dahl 2018-08-03 16:47:45 -07:00
parent 8a4be24645
commit 5f67a6a237
4 changed files with 4646 additions and 3 deletions

View file

@ -621,9 +621,6 @@ var Font = (function FontClosure() {
throw new FormatError(`Font ${type} is not supported`);
}
} catch (e) {
if (!(e instanceof FormatError)) {
throw e;
}
warn(e);
this.fallbackToSystemFont();
return;