[]
Loads the first Font from a specified file.
public static Font FromFile(string path, bool initCodeMap = false)
Public Shared Function FromFile(path As String, Optional initCodeMap As Boolean = False) As Font
| Type | Name | Description |
|---|---|---|
| string | path | The path to the file containing the font data. |
| bool | initCodeMap | Set this parameter to True if you're planning to add the font to the fallback font collection. |
| Type | Description |
|---|---|
| Font | The newly created font, or null if the file did not contain any fonts. |
Loads a Font with given full font name from a specified file.
public static Font FromFile(string path, string fullFontName)
Public Shared Function FromFile(path As String, fullFontName As String) As Font
| Type | Name | Description |
|---|---|---|
| string | path | The path to the file containing the font data. |
| string | fullFontName | The full font name to be loaded. |
| Type | Description |
|---|---|
| Font | The newly created font. |