MCPcopy Create free account
hub / github.com/Aegel5/SimpleSwitcher / ClearFonts

Method ClearFonts

imgui_tiny_app/imgui/imgui_draw.cpp:2721–2737  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2719}
2720
2721void ImFontAtlas::ClearFonts()
2722{
2723 // FIXME-NEWATLAS: Illegal to remove currently bound font.
2724 IM_ASSERT(!Locked && "Cannot modify a locked ImFontAtlas!");
2725 for (ImFont* font : Fonts)
2726 ImFontAtlasBuildNotifySetFont(this, font, NULL);
2727 ImFontAtlasBuildDestroy(this);
2728 ClearInputData();
2729 Fonts.clear_delete();
2730 TexIsBuilt = false;
2731 for (ImDrawListSharedData* shared_data : DrawListSharedDatas)
2732 if (shared_data->FontAtlas == this)
2733 {
2734 shared_data->Font = NULL;
2735 shared_data->FontScale = shared_data->FontSize = 0.0f;
2736 }
2737}
2738
2739static void ImFontAtlasBuildUpdateRendererHasTexturesFromContext(ImFontAtlas* atlas)
2740{

Callers

nothing calls this directly

Calls 2

ImFontAtlasBuildDestroyFunction · 0.85

Tested by

no test coverage detected