1
0
Fork 0
mirror of https://github.com/ocornut/imgui.git synced 2026-01-16 00:54:19 +00:00

Fonts: fixed PopFont() broken recovery.

"misc_recover_1" test would assert in EndFrame()
This commit is contained in:
ocornut 2025-06-10 17:47:30 +02:00
parent 2e67bd4de7
commit 573f08135d

View file

@ -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;