Struct GameFontStyle
Describes a font based on game resource file.
Inherited Members
Namespace: Dalamud.Interface.GameFonts
Assembly: Dalamud.dll
Syntax
public struct GameFontStyle
Constructors
| Improve this Doc View SourceGameFontStyle(GameFontFamily, Single)
Initializes a new instance of the GameFontStyle struct.
Declaration
public GameFontStyle(GameFontFamily family, float size)
Parameters
| Type | Name | Description |
|---|---|---|
| GameFontFamily | family | Font family. |
| System.Single | size | Size in points. |
GameFontStyle(GameFontFamilyAndSize)
Initializes a new instance of the GameFontStyle struct.
Declaration
public GameFontStyle(GameFontFamilyAndSize familyAndSize)
Parameters
| Type | Name | Description |
|---|---|---|
| GameFontFamilyAndSize | familyAndSize | Font family and size. |
Fields
| Improve this Doc View SourceFamilyAndSize
Font family of the font.
Declaration
public GameFontFamilyAndSize FamilyAndSize
Field Value
| Type | Description |
|---|---|
| GameFontFamilyAndSize |
SkewStrength
Skewedness of the font.
0 is unaltered. Greater than 1 will make upper part go rightwards. Less than 1 will make lower part go rightwards.
Declaration
public float SkewStrength
Field Value
| Type | Description |
|---|---|
| System.Single |
Weight
Weight of the font.
0 is unaltered. Any value greater than 0 will make it bolder.
Declaration
public float Weight
Field Value
| Type | Description |
|---|---|
| System.Single |
Properties
| Improve this Doc View SourceBold
Gets or sets a value indicating whether this font is bold.
Declaration
public bool Bold { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
Family
Gets the font family.
Declaration
public readonly GameFontFamily Family { get; }
Property Value
| Type | Description |
|---|---|
| GameFontFamily |
Italic
Gets or sets a value indicating whether this font is italic.
Declaration
public bool Italic { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
Size
Gets the font size.
Declaration
public readonly float Size { get; }
Property Value
| Type | Description |
|---|---|
| System.Single |
Methods
| Improve this Doc View SourceCalculateWidthAdjustment(FdtReader, FdtReader.FontTableEntry)
Calculates the adjustment to width resulting fron Weight and SkewStrength.
Declaration
public int CalculateWidthAdjustment(FdtReader reader, FdtReader.FontTableEntry glyph)
Parameters
| Type | Name | Description |
|---|---|---|
| FdtReader | reader | Font information. |
| FdtReader.FontTableEntry | glyph | Glyph. |
Returns
| Type | Description |
|---|---|
| System.Int32 | Width adjustment in pixel unit. |
GetRecommendedFamilyAndSize(GameFontFamily, Single)
Gets the recommend GameFontFamilyAndSize given family and size.
Declaration
public static GameFontFamilyAndSize GetRecommendedFamilyAndSize(GameFontFamily family, float size)
Parameters
| Type | Name | Description |
|---|---|---|
| GameFontFamily | family | Font family. |
| System.Single | size | Font size in points. |
Returns
| Type | Description |
|---|---|
| GameFontFamilyAndSize | Recommended GameFontFamilyAndSize. |