Package com.adobe.fontengine.font.mac
Class FontFactory
java.lang.Object
com.adobe.fontengine.font.mac.FontFactory
Factory for building Mac resource fonts from data or resource fork type resources.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic intstatic intisResourceFont(byte[] bytes, URL url) static ResourceFont[]static FontData
-
Field Details
-
UNKNOWN
public static final int UNKNOWN- See Also:
-
RESOURCE_FORK_FONT
public static final int RESOURCE_FORK_FONT- See Also:
-
DATA_FORK_FONT
public static final int DATA_FORK_FONT- See Also:
-
-
Constructor Details
-
FontFactory
public FontFactory()
-
-
Method Details
-
load
public static FontData load(URL url, int type, int fontID, int fondID) throws InvalidFontException, UnsupportedFontException, FontLoadingException - Parameters:
url- this is the full URL including any resource fork informationtype- is this a data or resource forkfontID- the id of the font within the resourcefondID- the id of the FOND resource which describes this font- Returns:
- a FontData loaded from the URL given
- Throws:
InvalidFontExceptionUnsupportedFontExceptionFontLoadingException
-
load
public static ResourceFont[] load(URL url, int type) throws InvalidFontException, UnsupportedFontException, FontLoadingException - Parameters:
url- the base URL of the font not including any possible resource fork informationtype- the type of the resource - data or resource fork- Returns:
- all available fonts from this resource that are of a type understood
- Throws:
InvalidFontExceptionUnsupportedFontExceptionFontLoadingException
-
getNumBytesNeededToIdentify
public static int getNumBytesNeededToIdentify() -
isResourceFont
- Throws:
IOException
-