mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-29 20:03:41 +01:00
feat: add new ConsoleWindow
This commit is contained in:
parent
dc992e15ae
commit
c287e28832
5 changed files with 529 additions and 190 deletions
|
|
@ -140,6 +140,11 @@ namespace Dalamud.Interface.Internal
|
|||
/// </summary>
|
||||
public static ImFontPtr IconFont { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets an included monospaced font.
|
||||
/// </summary>
|
||||
public static ImFontPtr MonoFont { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets an action that is exexuted when fonts are rebuilt.
|
||||
/// </summary>
|
||||
|
|
@ -464,6 +469,13 @@ namespace Dalamud.Interface.Internal
|
|||
GCHandleType.Pinned);
|
||||
IconFont = ImGui.GetIO().Fonts.AddFontFromFileTTF(fontPathIcon, 17.0f, null, iconRangeHandle.AddrOfPinnedObject());
|
||||
|
||||
var fontPathMono = Path.Combine(this.dalamud.AssetDirectory.FullName, "UIRes", "Inconsolata-Regular.ttf");
|
||||
|
||||
if (!File.Exists(fontPathMono))
|
||||
ShowFontError(fontPathMono);
|
||||
|
||||
MonoFont = ImGui.GetIO().Fonts.AddFontFromFileTTF(fontPathMono, 16.0f);
|
||||
|
||||
Log.Verbose("[FONT] Invoke OnBuildFonts");
|
||||
this.OnBuildFonts?.Invoke();
|
||||
Log.Verbose("[FONT] OnBuildFonts OK!");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue