Skip to main content

Class FontAtlasBuildToolkitUtilities

Convenience function for building fonts through Dalamud.Interface.ManagedFontAtlas.IFontAtlas.

Assembly: Dalamud.dll
View Source
Declaration
public static class FontAtlasBuildToolkitUtilities

Methods

BeginGlyphRange(IEnumerable<char>)

Begins building a new array of System.UInt16 containing ImGui glyph ranges.

View Source
Declaration
public static FluentGlyphRangeBuilder BeginGlyphRange(this IEnumerable<char> chars)
Returns

Dalamud.Interface.ManagedFontAtlas.FluentGlyphRangeBuilder: A new range builder.

Parameters
TypeNameDescription
System.Collections.Generic.IEnumerable<System.Char>charsThe chars.

BeginGlyphRange(ReadOnlySpan<char>)

Begins building a new array of System.UInt16 containing ImGui glyph ranges.

View Source
Declaration
public static FluentGlyphRangeBuilder BeginGlyphRange(this ReadOnlySpan<char> chars)
Returns

Dalamud.Interface.ManagedFontAtlas.FluentGlyphRangeBuilder: A new range builder.

Parameters
TypeNameDescription
System.ReadOnlySpan<System.Char>charsThe chars.

BeginGlyphRange(string)

Begins building a new array of System.UInt16 containing ImGui glyph ranges.

View Source
Declaration
public static FluentGlyphRangeBuilder BeginGlyphRange(this string chars)
Returns

Dalamud.Interface.ManagedFontAtlas.FluentGlyphRangeBuilder: A new range builder.

Parameters
TypeNameDescription
System.StringcharsThe chars.

BeginGlyphRange(UnicodeRange)

Begins building a new array of System.UInt16 containing ImGui glyph ranges.

View Source
Declaration
public static FluentGlyphRangeBuilder BeginGlyphRange(this UnicodeRange range)
Returns

Dalamud.Interface.ManagedFontAtlas.FluentGlyphRangeBuilder: A new range builder.

Parameters
TypeNameDescription
System.Text.Unicode.UnicodeRangerangeThe unicode range.

ToGlyphRange(IEnumerable<char>, bool, bool)

Compiles given System.Chars into an array of System.UInt16 containing ImGui glyph ranges.

View Source
Declaration
public static ushort[] ToGlyphRange(this IEnumerable<char> enumerable, bool addFallbackCodepoints = true, bool addEllipsisCodepoints = true)
Returns

System.UInt16[]: The compiled range.

Parameters
TypeNameDescription
System.Collections.Generic.IEnumerable<System.Char>enumerableThe chars.
System.BooleanaddFallbackCodepointsAdd fallback codepoints to the range.
System.BooleanaddEllipsisCodepointsAdd ellipsis codepoints to the range.

ToGlyphRange(ReadOnlySpan<char>, bool, bool)

Compiles given System.Chars into an array of System.UInt16 containing ImGui glyph ranges.

View Source
Declaration
public static ushort[] ToGlyphRange(this ReadOnlySpan<char> span, bool addFallbackCodepoints = true, bool addEllipsisCodepoints = true)
Returns

System.UInt16[]: The compiled range.

Parameters
TypeNameDescription
System.ReadOnlySpan<System.Char>spanThe chars.
System.BooleanaddFallbackCodepointsAdd fallback codepoints to the range.
System.BooleanaddEllipsisCodepointsAdd ellipsis codepoints to the range.

ToGlyphRange(string, bool, bool)

Compiles given string into an array of System.UInt16 containing ImGui glyph ranges.

View Source
Declaration
public static ushort[] ToGlyphRange(this string @string, bool addFallbackCodepoints = true, bool addEllipsisCodepoints = true)
Returns

System.UInt16[]: The compiled range.

Parameters
TypeNameDescription
System.StringstringThe string.
System.BooleanaddFallbackCodepointsAdd fallback codepoints to the range.
System.BooleanaddEllipsisCodepointsAdd ellipsis codepoints to the range.

FindConfigPtr(IFontAtlasBuildToolkit, ImFontPtr)

Finds the corresponding ImGuiNET.ImFontConfigPtr in Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkit.NewImAtlas.ImGuiNET.ImFontAtlasPtr.ConfigData that corresponds to the specified font <code class="paramref">fontPtr</code>.

View Source
Declaration
public static ImFontConfigPtr FindConfigPtr(this IFontAtlasBuildToolkit toolkit, ImFontPtr fontPtr)
Returns

ImGuiNET.ImFontConfigPtr: The relevant config pointer, or empty config pointer if not found.

Parameters
TypeNameDescription
Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkittoolkitThe toolkit.
ImGuiNET.ImFontPtrfontPtrThe font.

OnPreBuild(IFontAtlasBuildToolkit, Action<IFontAtlasBuildToolkitPreBuild>)

Invokes <code class="paramref">action</code> if Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkit.BuildStep of <code class="paramref">toolkit</code> is Dalamud.Interface.ManagedFontAtlas.FontAtlasBuildStep.PreBuild.

View Source
Declaration
public static IFontAtlasBuildToolkit OnPreBuild(this IFontAtlasBuildToolkit toolkit, Action<IFontAtlasBuildToolkitPreBuild> action)
Returns

Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkit: This, for method chaining.

Parameters
TypeNameDescription
Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkittoolkitThe toolkit.
System.Action<Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkitPreBuild>actionThe action.

OnPostBuild(IFontAtlasBuildToolkit, Action<IFontAtlasBuildToolkitPostBuild>)

Invokes <code class="paramref">action</code> if Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkit.BuildStep of <code class="paramref">toolkit</code> is Dalamud.Interface.ManagedFontAtlas.FontAtlasBuildStep.PostBuild.

View Source
Declaration
public static IFontAtlasBuildToolkit OnPostBuild(this IFontAtlasBuildToolkit toolkit, Action<IFontAtlasBuildToolkitPostBuild> action)
Returns

Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkit: toolkit, for method chaining.

Parameters
TypeNameDescription
Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkittoolkitThe toolkit.
System.Action<Dalamud.Interface.ManagedFontAtlas.IFontAtlasBuildToolkitPostBuild>actionThe action.