public final class FontSettings extends Object
General imaging vector formats renderer font settings.
Constructor and Description |
---|
FontSettings() |
Modifier and Type | Method and Description |
---|---|
static String |
getDefaultFontName()
Gets or sets the default name of the font.
|
static String[] |
getDefaultFontsFolders()
Gets the default fonts folders.
|
static String[] |
getFontsFolders()
Gets a copy of the array that contains the list of folders where Aspose.Words looks for TrueType fonts.
|
static void |
reset()
Resets the fonts folder and default font name to the system default.
|
static void |
setDefaultFontName(String value)
Gets or sets the default name of the font.
|
static void |
setFontsFolder(String fontFolder)
This is a shortcut to
FontSettings.setFontsFolders(String[],boolean) for setting only one font directory. |
static void |
setFontsFolders(String[] fontsFolders,
boolean recursive)
Sets the folders where TrueType fonts are loaded from and clears all loaded fonts.
|
static void |
updateFonts()
Updates fonts cache for PSD files that contain text layers.
|
public static String getDefaultFontName()
Gets or sets the default name of the font.
Value: The default name of the font.public static void setDefaultFontName(String value)
Gets or sets the default name of the font.
Value: The default name of the font.public static String[] getFontsFolders()
Gets a copy of the array that contains the list of folders where Aspose.Words looks for TrueType fonts.
The returned value is a copy of the data that Aspose.Words uses. If you change the entries in the returned array,
it will have no effect on document rendering. To specify new font locations use the FontSettings.setFontsFolders(String[],boolean)
method.
public static String[] getDefaultFontsFolders()
Gets the default fonts folders.
public static void setFontsFolder(String fontFolder)
This is a shortcut to FontSettings.setFontsFolders(String[],boolean)
for setting only one font directory.
There are no checks performed on the fonts folder.
fontFolder
- The font folder.public static void setFontsFolders(String[] fontsFolders, boolean recursive)
Sets the folders where TrueType fonts are loaded from and clears all loaded fonts. There are no checks performed on the fonts folders.
fontsFolders
- The fonts folders.recursive
- if set to true
[recursive].public static void reset()
Resets the fonts folder and default font name to the system default.
public static void updateFonts()
Updates fonts cache for PSD files that contain text layers. This method guarantees that fonts from folder fontsFolder using method FontSettings.SetFontsFolder(fontsFolder) or after reset fonts using FontSettings.Reset() will be taken into consideration when processing PSD files. Please use this method each time when FontSettings.SetFontsFolder(fontsFolder) or FontSettings.Reset() called for PSD images. Without calling this Method there is no guarantee that fonts will be updated.
Copyright (c) 2008-2020 Aspose Pty Ltd. All Rights Reserved.