SystemFontsSubstitution
Inheritance: java.lang.Object, com.aspose.pdf.text.FontSubstitution com.aspose.pdf.text.SystemFontsSubstitution, com.aspose.pdf.text.FontSubstitution, com.aspose.pdf.text.SystemFontsSubstitution
public final class SystemFontsSubstitution extends FontSubstitution
Represents a class for font substitution strategy that substitutes fonts with system fonts.
Constructors
| Constructor | Description |
|---|---|
| SystemFontsSubstitution | Initializes a new instance of {@code SystemFontsSubstitution} class. |
Methods
| Method | Description |
|---|---|
| getDefaultFont | Gets or sets default substitution font. The font is used when no other valid substitution were found but initial font belongs to target substitution category ({@code FontCategories}). |
| getFontCategories | Gets or sets substitution font categories that should be substituted with system fonts. |
| setDefaultFont | Gets or sets default substitution font. The font is used when no other valid substitution were found but initial font belongs to target substitution category ({@code FontCategories}). |
| setFontCategories | Gets or sets substitution font categories that should be substituted with system fonts. |
SystemFontsSubstitution
public SystemFontsSubstitution(int fontCategories)
Initializes a new instance of {@code SystemFontsSubstitution} class.
Parameters:
| Parameter | Type | Description |
|---|---|---|
| fontCategories | Target font categories to substitute with system fonts |
getDefaultFont
public Font getDefaultFont()
Gets or sets default substitution font. The font is used when no other valid substitution were found but initial font belongs to target substitution category ({@code FontCategories}).
Returns: Font object
getFontCategories
public int getFontCategories()
Gets or sets substitution font categories that should be substituted with system fonts.
Returns: SubstitutionFontCategories element @see SubstitutionFontCategories
setDefaultFont
Gets or sets default substitution font. The font is used when no other valid substitution were found but initial font belongs to target substitution category ({@code FontCategories}).
setFontCategories
public void setFontCategories(int value)
Gets or sets substitution font categories that should be substituted with system fonts.
Parameters:
| Parameter | Type | Description |
|---|---|---|
| value | SubstitutionFontCategories element @see SubstitutionFontCategories |