-
Bug
-
Resolution: Fixed
-
P3
-
jfx11, 8, jfx15
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8238443 | 8u261 | Philip Race | P3 | Resolved | Fixed | b01 |
JDK-8247984 | jfx11.0.8 | Philip Race | P3 | Resolved | Fixed |
The hmtx table stores the linearly scaled advances of all glyphs.
Per the opentype spec there can be fewer records in the table than there are glyphs in which case all entries past the last one apply to all remaining glyphs. The advance lookup code handles that.
But what if there are records entries in the table than specified by the numHorMetrics field in the hhea table ?
When we populate the advance widths we should stop reading when we reach the end of the table, else we could get a Java exception which would stop the font from being loaded when it might otherwise be OK - at least up to the extent of the valid data.
Per the opentype spec there can be fewer records in the table than there are glyphs in which case all entries past the last one apply to all remaining glyphs. The advance lookup code handles that.
But what if there are records entries in the table than specified by the numHorMetrics field in the hhea table ?
When we populate the advance widths we should stop reading when we reach the end of the table, else we could get a Java exception which would stop the font from being loaded when it might otherwise be OK - at least up to the extent of the valid data.
- backported by
-
JDK-8238443 Only read advances up to the minimum of the numHorMetrics or the available font data.
- Resolved
-
JDK-8247984 Only read advances up to the minimum of the numHorMetrics or the available font data.
- Resolved