This commit is contained in:
2024-03-23 02:20:07 +05:00
parent 72352994f7
commit 58b62eb3a8
7 changed files with 72 additions and 10 deletions

View File

@@ -12,7 +12,7 @@ ImFont* _ImFont_LoadEmbedded(const void* data, int data_size, const char* font_n
ImGuiIO& io = ImGui::GetIO();
font_size *= dpi;
ImFontConfig font_cfg = ImFontConfig();
sprintf_s(font_cfg.Name, IM_ARRAYSIZE(font_cfg.Name), "%s, %.0fpx", font_name, font_size);
ksprintf(font_cfg.Name, IM_ARRAYSIZE(font_cfg.Name), "%s, %.0fpx", font_name, font_size);
return io.Fonts->AddFontFromMemoryCompressedTTF(data, data_size, font_size, &font_cfg);
}

View File

@@ -4,6 +4,7 @@
#include "../../dependencies/SDL2/include/SDL.h"
#include "../../dependencies/SDL2/include/SDL_opengl.h"
#include "../../dependencies/imgui/imgui.h"
#include "../format.hpp"
#include "NodeEditor.hpp"
#include "imgui_extensions.hpp"
#include "fonts.hpp"