-
Notifications
You must be signed in to change notification settings - Fork 514
Open
Labels
Description
Expected Behavior
skip parse name table
Current Behavior
When open an embed font, who's tables like (ttfdump):
Offset Table
sfnt version: 1.0
numTables = 9
searchRange = 128
entrySelector = 3
rangeShift = 16
- 'cvt ' - chksm = 0x74E2F99D, off = 0x0000009C, len = 2092
- 'fpgm' - chksm = 0x379E7810, off = 0x000008C8, len = 1599
- 'glyf' - chksm = 0xABC33A52, off = 0x00000F08, len = 4246
- 'head' - chksm = 0xE3ACEF64, off = 0x00001FA0, len = 54
- 'hhea' - chksm = 0x13041853, off = 0x00001FD8, len = 36
- 'hmtx' - chksm = 0xBA6A7548, off = 0x00001FFC, len = 16392
- 'loca' - chksm = 0x01068764, off = 0x00006004, len = 16396
- 'maxp' - chksm = 0x194B065D, off = 0x0000A010, len = 32
- 'prep' - chksm = 0x025F6028, off = 0x0000A030, len = 4968
so nameTableEntry is undefined,
opentype.js line 311: const nameTable = uncompressTable(data, nameTableEntry);
cause TypeError: Cannot read property 'compression' of undefined
Possible Solution
check nameTableEntry is undefined
Steps to Reproduce (for bugs)
- load font.zip as ArrayBuffer
- invoke Font.parse(buffer)
Context
Your Environment
- Version used: 1.3.3
- Font used:
- Browser Name and version: Google Chrome 87.0.4280.88 x64
- Operating System and version (desktop or mobile): Windows 10 1909
- Link to your project: