// We access everything through this pointer (always assumed to be != NULL)
// You can swap the pointer to a different context by calling ImGui::SetInternalState()
staticImGuiStateGImDefaultState;
ImGuiState*GImGui=&GImDefaultState;
// You can swap the pointer to a different context by calling ImGui::SetCurrentContext()
staticImGuiStateGImDefaultContext;
ImGuiState*GImGui=&GImDefaultContext;
// Statically allocated default font atlas. This is merely a maneuver to keep ImFontAtlas definition at the bottom of the .h file (otherwise it'd be inside ImGuiIO)
// Also we wouldn't be able to new() one at this point, before users may define IO.MemAllocFn.
// Also we wouldn't be able to new() one at this point, before users have a chance to setup their allocator.
// Internal state access - if you want to share ImGui state between modules (e.g. DLL) or allocate it yourself
// Note that we still point to some static data and members (such as GFontAtlas), so the state instance you end up using will point to the static data within its module
@ -54,6 +54,7 @@ struct ImGuiTextFilter; // Parse and apply text filters. In format "
structImGuiTextBuffer;// Text buffer for logging/accumulating text
structImGuiTextEditCallbackData;// Shared state of ImGui::InputText() when using custom callbacks (advanced)
structImGuiListClipper;// Helper to manually clip large list of items
structImGuiState;// ImGui context (opaque)
// Enumerations (declared as int for compatibility and to not pollute the top of this file)
typedefunsignedintImU32;
@ -442,11 +443,12 @@ namespace ImGui
IMGUI_APIconstchar*GetClipboardText();
IMGUI_APIvoidSetClipboardText(constchar*text);
// Internal state/context access - if you want to use multiple ImGui context, or share context between modules (e.g. DLL), or allocate the memory yourself
// Internal context access - if you want to use multiple context, share context between modules (e.g. DLL). There is a default context created and active by default.