FontDefinition
Inheritance: java.lang.Object
public class FontDefinition
Represents Font file set definition. This class contains fields which are not related to font internal data. These fields describe font placement and another data needed to load font from some font source(file, memory, etc).
Constructors
Methods
Method | Description |
---|---|
open(String fileName, FontType fontType) | Returns FontDefinition for font file and font type. |
open(StreamSource source, FontType fontType) | Returns FontDefinition for font stream source and font type. |
getFontName() | Returns Font name. |
getFontNames() | Gets Font names as a MultiLanguageString . |
getPostscriptName() | Gets postscript Font name. |
getPostscriptNames() | Gets postscript Font names as a MultiLanguageString . |
getFontType() | Gets Font type. |
getFileDefinitions() | Gets file definitions collection. |
FontDefinition(FontType fontType, String fileExtension, StreamSource streamSource)
public FontDefinition(FontType fontType, String fileExtension, StreamSource streamSource)
Creates single-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontType | FontType | Font type. |
fileExtension | java.lang.String | Font file extension. |
streamSource | StreamSource | Font stream source. |
FontDefinition(FontType fontType, StreamSource streamSource)
public FontDefinition(FontType fontType, StreamSource streamSource)
Creates single-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontType | FontType | Font type. |
streamSource | StreamSource | Font stream source. |
FontDefinition(String fontName, FontType fontType, String fileExtension, StreamSource streamSource)
public FontDefinition(String fontName, FontType fontType, String fileExtension, StreamSource streamSource)
Creates single-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontName | java.lang.String | Font name. |
fontType | FontType | Font type. |
fileExtension | java.lang.String | Font file extension. |
streamSource | StreamSource | Font stream source. |
FontDefinition(FontType fontType, FontFileDefinition fileDefinition)
public FontDefinition(FontType fontType, FontFileDefinition fileDefinition)
Creates single-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontType | FontType | Font type. |
fileDefinition | FontFileDefinition | FontFileDefinition. |
FontDefinition(String fontName, FontType fontType, FontFileDefinition fileDefinition)
public FontDefinition(String fontName, FontType fontType, FontFileDefinition fileDefinition)
Creates single-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontName | java.lang.String | Font name. |
fontType | FontType | Font type. |
fileDefinition | FontFileDefinition | FontFileDefinition. |
FontDefinition(String fontName, String postscriptName, FontType fontType, FontFileDefinition fileDefinition)
public FontDefinition(String fontName, String postscriptName, FontType fontType, FontFileDefinition fileDefinition)
Creates single-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontName | java.lang.String | Font name. |
postscriptName | java.lang.String | Postscript Font name. |
fontType | FontType | Font type. |
fileDefinition | FontFileDefinition | FontFileDefinition. |
FontDefinition(FontType fontType, FontFileDefinition[] fileDefinitions)
public FontDefinition(FontType fontType, FontFileDefinition[] fileDefinitions)
Creates multi-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontType | FontType | Font type. |
fileDefinitions | FontFileDefinition[] | Array of FontFileDefinition objects. |
FontDefinition(String fontName, String postscriptName, FontType fontType, FontFileDefinition[] fileDefinitions)
public FontDefinition(String fontName, String postscriptName, FontType fontType, FontFileDefinition[] fileDefinitions)
Creates multi-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontName | java.lang.String | Font name. |
postscriptName | java.lang.String | Postscript Font name. |
fontType | FontType | Font type. |
fileDefinitions | FontFileDefinition[] | Array of FontFileDefinition objects. |
FontDefinition(MultiLanguageString fontNames, MultiLanguageString postscriptNames, FontType fontType, FontFileDefinition fileDefinition)
public FontDefinition(MultiLanguageString fontNames, MultiLanguageString postscriptNames, FontType fontType, FontFileDefinition fileDefinition)
Creates multi-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontNames | MultiLanguageString | Font names. |
postscriptNames | MultiLanguageString | Postscript Font names. |
fontType | FontType | Font type. |
fileDefinition | FontFileDefinition | FontFileDefinition. |
FontDefinition(MultiLanguageString fontNames, MultiLanguageString postscriptNames, FontType fontType, FontFileDefinition[] fileDefinitions)
public FontDefinition(MultiLanguageString fontNames, MultiLanguageString postscriptNames, FontType fontType, FontFileDefinition[] fileDefinitions)
Creates multi-file Font definition.
Parameters:
Parameter | Type | Description |
---|---|---|
fontNames | MultiLanguageString | Font names. |
postscriptNames | MultiLanguageString | Postscript Font names. |
fontType | FontType | Font type. |
fileDefinitions | FontFileDefinition[] | Array of FontFileDefinition objects. |
open(String fileName, FontType fontType)
public static FontDefinition open(String fileName, FontType fontType)
Returns FontDefinition for font file and font type.
Parameters:
Parameter | Type | Description |
---|---|---|
fileName | java.lang.String | Font file name. |
fontType | FontType | Font type. |
Returns: FontDefinition - FontDefinition.
open(StreamSource source, FontType fontType)
public static FontDefinition open(StreamSource source, FontType fontType)
Returns FontDefinition for font stream source and font type.
Parameters:
Parameter | Type | Description |
---|---|---|
source | StreamSource | Font stream source. |
fontType | FontType | Font type. |
Returns: FontDefinition - FontDefinition.
getFontName()
public String getFontName()
Returns Font name.
Returns: java.lang.String - Font name.
getFontNames()
public MultiLanguageString getFontNames()
Gets Font names as a MultiLanguageString .
Returns: MultiLanguageString - Font names as a MultiLanguageString .
getPostscriptName()
public String getPostscriptName()
Gets postscript Font name.
Returns: java.lang.String - Postscript Font name.
getPostscriptNames()
public MultiLanguageString getPostscriptNames()
Gets postscript Font names as a MultiLanguageString .
Returns: MultiLanguageString - Postscript Font names as a MultiLanguageString .
getFontType()
public FontType getFontType()
Gets Font type.
Returns: FontType - Font type.
getFileDefinitions()
public FontFileDefinition[] getFileDefinitions()
Gets file definitions collection.
Returns: com.aspose.font.FontFileDefinition[] - File definitions collection.