Package com.adobe.fontengine.font.cff
Class Type2GlyphBBoxCalculator
java.lang.Object
com.adobe.fontengine.font.cff.Type2GlyphBBoxCalculator
- All Implemented Interfaces:
GlyphBBoxCalculator
Calculates an unhinted glyph bounding box for a type2 glyph description
at a specified size.
Instances of this class can be reused across multiple fonts and glyphs.
Synchronization
This class is synchronized. Only one thread will be allowed into the calculateBBox method at a time.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncalculateBBox(FontData font, int glyphID) Calculates the bounding box for a glyph.
-
Constructor Details
-
Type2GlyphBBoxCalculator
-
-
Method Details
-
calculateBBox
public Rect calculateBBox(FontData font, int glyphID) throws InvalidFontException, UnsupportedFontException Calculates the bounding box for a glyph.- Specified by:
calculateBBoxin interfaceGlyphBBoxCalculator- Parameters:
font- the font containing the glyphglyphID- the glyph to be calculated- Returns:
- the unhinted bounding box for the glyph
- Throws:
InvalidFontException- thrown when a glyph description is malformed.UnsupportedFontException
-