add doom font

This commit is contained in:
2024-08-07 15:17:41 +02:00
parent 2df849b63e
commit 89a6219072
2 changed files with 9 additions and 4 deletions

BIN
assets/fonts/doom.ttf Normal file

Binary file not shown.

View File

@@ -57,11 +57,16 @@ void ImGuiAppComponent::SetStyle() {
ImGui::GetStyle().Colors[ImGuiCol_HeaderHovered] = colorTabActive;
ImGui::GetStyle().Colors[ImGuiCol_Header] = colorTabActive;
/*ImFontConfig c;
c.SizePixels = 25.0f;
static const float DefaultFontSize = 25.0f;
ImFontConfig c;
c.SizePixels = DefaultFontSize;
c.OversampleH = 1; // prevent from blurring font
ImGui::GetIO().Fonts->AddFontDefault(&c);
auto* doomFont = ImGui::GetIO().Fonts->AddFontFromFileTTF("assets/fonts/doom.ttf", 25.0f, &c);
ImGui::GetIO().FontDefault = doomFont;*/
auto* doomFont = ImGui::GetIO().Fonts->AddFontFromFileTTF("assets/fonts/doom.ttf", DefaultFontSize, &c);
ImGui::GetIO().FontDefault = doomFont;
UpdateFontTexture();
}