8260453: Improve Font Bounding
Reviewed-by: rhalade, psadhukhan, mschoene, serb
This commit is contained in:
parent
7ad6c23c32
commit
7b6410f213
@ -426,7 +426,6 @@ abstract class CMap {
|
||||
try {
|
||||
this.uvs = new UVS(buffer, offset);
|
||||
} catch (Throwable t) {
|
||||
t.printStackTrace();
|
||||
}
|
||||
}
|
||||
return;
|
||||
|
@ -518,6 +518,10 @@ public class TrueTypeFont extends FileFont {
|
||||
&& getDirectoryEntry(hheaTag) == null) {
|
||||
throw new FontFormatException("missing hhea table");
|
||||
}
|
||||
ByteBuffer maxpTable = getTableBuffer(maxpTag);
|
||||
if (maxpTable.getChar(4) == 0) {
|
||||
throw new FontFormatException("zero glyphs");
|
||||
}
|
||||
initNames();
|
||||
} catch (Exception e) {
|
||||
if (FontUtilities.isLogging()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user