mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-22 16:18:08 +02:00
Merge pull request #6270 from Snuffleupagus/opentype-cff-2
Adjust the heuristics used to detect OpenType font file with CFF data (bug 1186827, bug 1182130, issue 6264)
This commit is contained in:
commit
977397ebfd
5 changed files with 17 additions and 1 deletions
|
@ -4053,7 +4053,7 @@ var Font = (function FontClosure() {
|
|||
var isTrueType = !tables['CFF '];
|
||||
if (!isTrueType) {
|
||||
// OpenType font
|
||||
if (header.version === 'OTTO' ||
|
||||
if ((header.version === 'OTTO' && properties.type !== 'CIDFontType2') ||
|
||||
!tables.head || !tables.hhea || !tables.maxp || !tables.post) {
|
||||
// no major tables: throwing everything at CFFFont
|
||||
cffFile = new Stream(tables['CFF '].data);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue