public int getNumGlyphs() { return _maxp.getNumGlyphs(); }
break; case Table.maxp: t = new MaxpTable(de, dis); break; case Table.name:
break; case Table.maxp: t = new MaxpTable(de, dis); break; case Table.name:
public int getNumGlyphs() { return _maxp.getNumGlyphs(); }
protected LocaTable( final DirectoryEntry de, final DataInput di, final HeadTable head, final MaxpTable maxp) throws IOException { _de = (DirectoryEntry) de.clone(); _offsets = new int[maxp.getNumGlyphs() + 1]; final boolean shortEntries = head.getIndexToLocFormat() == 0; if (shortEntries) { _factor = 2; for (int i = 0; i <= maxp.getNumGlyphs(); i++) { _offsets[i] = di.readUnsignedShort(); } } else { _factor = 1; for (int i = 0; i <= maxp.getNumGlyphs(); i++) { _offsets[i] = di.readInt(); } } }
protected LocaTable( final DirectoryEntry de, final DataInput di, final HeadTable head, final MaxpTable maxp) throws IOException { _de = (DirectoryEntry) de.clone(); _offsets = new int[maxp.getNumGlyphs() + 1]; final boolean shortEntries = head.getIndexToLocFormat() == 0; if (shortEntries) { _factor = 2; for (int i = 0; i <= maxp.getNumGlyphs(); i++) { _offsets[i] = di.readUnsignedShort(); } } else { _factor = 1; for (int i = 0; i <= maxp.getNumGlyphs(); i++) { _offsets[i] = di.readInt(); } } }
/** Creates a new instance of HdmxTable */ protected HdmxTable(final DirectoryEntry de, final DataInput di, final MaxpTable maxp) throws IOException { _de = (DirectoryEntry) de.clone(); _version = di.readUnsignedShort(); _numRecords = di.readShort(); _sizeDeviceRecords = di.readInt(); _records = new DeviceRecord[_numRecords]; // Read the device records for (int i = 0; i < _numRecords; ++i) { _records[i] = new DeviceRecord(maxp.getNumGlyphs(), di); } }
/** Creates a new instance of HdmxTable */ protected HdmxTable(final DirectoryEntry de, final DataInput di, final MaxpTable maxp) throws IOException { _de = (DirectoryEntry) de.clone(); _version = di.readUnsignedShort(); _numRecords = di.readShort(); _sizeDeviceRecords = di.readInt(); _records = new DeviceRecord[_numRecords]; // Read the device records for (int i = 0; i < _numRecords; ++i) { _records[i] = new DeviceRecord(maxp.getNumGlyphs(), di); } }
protected HmtxTable( final DirectoryEntry de, final DataInput di, final HheaTable hhea, final MaxpTable maxp) throws IOException { _de = (DirectoryEntry) de.clone(); _hMetrics = new int[hhea.getNumberOfHMetrics()]; for (int i = 0; i < hhea.getNumberOfHMetrics(); ++i) { _hMetrics[i] = di.readUnsignedByte()<<24 | di.readUnsignedByte()<<16 | di.readUnsignedByte()<<8 | di.readUnsignedByte(); } final int lsbCount = maxp.getNumGlyphs() - hhea.getNumberOfHMetrics(); _leftSideBearing = new short[lsbCount]; for (int i = 0; i < lsbCount; ++i) { _leftSideBearing[i] = di.readShort(); } }
protected HmtxTable( final DirectoryEntry de, final DataInput di, final HheaTable hhea, final MaxpTable maxp) throws IOException { _de = (DirectoryEntry) de.clone(); _hMetrics = new int[hhea.getNumberOfHMetrics()]; for (int i = 0; i < hhea.getNumberOfHMetrics(); ++i) { _hMetrics[i] = di.readUnsignedByte()<<24 | di.readUnsignedByte()<<16 | di.readUnsignedByte()<<8 | di.readUnsignedByte(); } final int lsbCount = maxp.getNumGlyphs() - hhea.getNumberOfHMetrics(); _leftSideBearing = new short[lsbCount]; for (int i = 0; i < lsbCount; ++i) { _leftSideBearing[i] = di.readShort(); } }
protected VmtxTable( final DirectoryEntry de, final DataInput di, final VheaTable vhea, final MaxpTable maxp) throws IOException { _de = (DirectoryEntry) de.clone(); _vMetrics = new int[vhea.getNumberOfLongVerMetrics()]; for (int i = 0; i < vhea.getNumberOfLongVerMetrics(); ++i) { _vMetrics[i] = di.readUnsignedByte()<<24 | di.readUnsignedByte()<<16 | di.readUnsignedByte()<<8 | di.readUnsignedByte(); } final int tsbCount = maxp.getNumGlyphs() - vhea.getNumberOfLongVerMetrics(); _topSideBearing = new short[tsbCount]; for (int i = 0; i < tsbCount; ++i) { _topSideBearing[i] = di.readShort(); } }
protected VmtxTable( final DirectoryEntry de, final DataInput di, final VheaTable vhea, final MaxpTable maxp) throws IOException { _de = (DirectoryEntry) de.clone(); _vMetrics = new int[vhea.getNumberOfLongVerMetrics()]; for (int i = 0; i < vhea.getNumberOfLongVerMetrics(); ++i) { _vMetrics[i] = di.readUnsignedByte()<<24 | di.readUnsignedByte()<<16 | di.readUnsignedByte()<<8 | di.readUnsignedByte(); } final int tsbCount = maxp.getNumGlyphs() - vhea.getNumberOfLongVerMetrics(); _topSideBearing = new short[tsbCount]; for (int i = 0; i < tsbCount; ++i) { _topSideBearing[i] = di.readShort(); } }
final LocaTable loca) throws IOException { _de = (DirectoryEntry) de.clone(); _descript = new GlyfDescript[maxp.getNumGlyphs()]; for (int i = 0; i < maxp.getNumGlyphs(); i++) { final int len = loca.getOffset(i + 1) - loca.getOffset(i); if (len > 0) { for (int i = 0; i < maxp.getNumGlyphs(); i++) { final int len = loca.getOffset(i + 1) - loca.getOffset(i); if (len > 0) {
final LocaTable loca) throws IOException { _de = (DirectoryEntry) de.clone(); _descript = new GlyfDescript[maxp.getNumGlyphs()]; for (int i = 0; i < maxp.getNumGlyphs(); i++) { final int len = loca.getOffset(i + 1) - loca.getOffset(i); if (len > 0) { for (int i = 0; i < maxp.getNumGlyphs(); i++) { final int len = loca.getOffset(i + 1) - loca.getOffset(i); if (len > 0) {