From 573f08135d8ce0d8cde6db2cd0156b2b602e137e Mon Sep 17 00:00:00 2001 From: ocornut Date: Tue, 10 Jun 2025 17:47:30 +0200 Subject: [PATCH] Fonts: fixed PopFont() broken recovery. "misc_recover_1" test would assert in EndFrame() --- imgui.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/imgui.cpp b/imgui.cpp index 39a79a398..faf8ae690 100644 --- a/imgui.cpp +++ b/imgui.cpp @@ -8812,7 +8812,7 @@ void ImGui::PushFont(ImFont* font, float font_size_base) void ImGui::PopFont() { ImGuiContext& g = *GImGui; - if (g.FontStack.Size <= 0 && g.WithinFrameScope) + if (g.FontStack.Size <= 0) { IM_ASSERT_USER_ERROR(0, "Calling PopFont() too many times!"); return;