Struct CustomFont
Represents a custom font with its file path, font size and glyph ranges.
Namespace: Evergine.UI
Assembly: Evergine.ImGui.dll
Syntax
public struct CustomFont
Constructors
CustomFont(string, float, ushort[])
Initializes a new instance of the CustomFont struct.
Declaration
public CustomFont(string path, float size = 14, ushort[] glyphRange = null)
Parameters
| Type | Name | Description |
|---|---|---|
| string | path | Path to the custom font. Must include file extension. |
| float | size | Font size. |
| ushort[] | glyphRange | Which character is the first and which is the last. Mainly used of icon fonts, otherwise you can leave it as null. |
Fields
GlyphRange
Gets or sets the glyph range for the font. Should contain two elements, the first being the start of the range and the second being the end.
Declaration
public ushort[] GlyphRange
Field Value
| Type | Description |
|---|---|
| ushort[] |
Path
Gets or sets the path to the font file.
Declaration
public string Path
Field Value
| Type | Description |
|---|---|
| string |
Size
Gets or sets the size of the font.
Declaration
public float Size
Field Value
| Type | Description |
|---|---|
| float |