Updates to Dear ImGui v1.92.5-docking
This commit is contained in:
parent
514e1e35e6
commit
5a6af5bf23
14 changed files with 11515 additions and 9345 deletions
|
|
@ -48,7 +48,7 @@ Note that you never need to do this as a user of the library, unless you're maki
|
||||||
2. Add `python3` to your path
|
2. Add `python3` to your path
|
||||||
3. Set `$DEAR_BINDINGS` to a path to an appropriate version of [dear_bindings](https://github.com/dearimgui/dear_bindings) for the version of Dear ImGUI you're updating to
|
3. Set `$DEAR_BINDINGS` to a path to an appropriate version of [dear_bindings](https://github.com/dearimgui/dear_bindings) for the version of Dear ImGUI you're updating to
|
||||||
4. Run `zig build dear_bindings`. Output may need tweaks, glance over diff.
|
4. Run `zig build dear_bindings`. Output may need tweaks, glance over diff.
|
||||||
5. Run `zig build generate` to see if the generator still works. If it fails, you're probably missing values in an enumeration, `std.json` does not provide helper errors for this at the time of writing, the easiest way to debug this is to comment out the actual generation code, and all fields in `Header`, adding them back until you figure out which are causing the issue.
|
5. Run `zig build generate -- ...` to see if the generator still works. If it fails, you're probably missing values in an enumeration, `std.json` does not provide helper errors for this at the time of writing, the easiest way to debug this is to comment out the actual generation code, and all fields in `Header`, adding them back until you figure out which are causing the issue.
|
||||||
6. Test the bindings from a real Zig program that imports Dear ImGUI.
|
6. Test the bindings from a real Zig program that imports Dear ImGUI.
|
||||||
|
|
||||||
## Known differences
|
## Known differences
|
||||||
|
|
|
||||||
|
|
@ -5,8 +5,8 @@
|
||||||
.minimum_zig_version = "0.16.0-dev.2193+fc517bd01",
|
.minimum_zig_version = "0.16.0-dev.2193+fc517bd01",
|
||||||
.dependencies = .{
|
.dependencies = .{
|
||||||
.@"dear-imgui" = .{
|
.@"dear-imgui" = .{
|
||||||
.url = "https://github.com/ocornut/imgui/archive/refs/tags/v1.92.2b-docking.tar.gz",
|
.url = "https://github.com/ocornut/imgui/archive/refs/tags/v1.92.5-docking.tar.gz",
|
||||||
.hash = "N-V-__8AAPZKeQDWGL4ckVmICNUMMWIikMKny4fQHvs2tCFh",
|
.hash = "N-V-__8AAEbOfQBnvcFcCX2W5z7tDaN8vaNZGamEQtNOe0UI",
|
||||||
},
|
},
|
||||||
.@"Vulkan-Headers" = .{
|
.@"Vulkan-Headers" = .{
|
||||||
.url = "https://github.com/KhronosGroup/Vulkan-Headers/archive/refs/tags/v1.4.313.tar.gz",
|
.url = "https://github.com/KhronosGroup/Vulkan-Headers/archive/refs/tags/v1.4.313.tar.gz",
|
||||||
|
|
|
||||||
|
|
@ -2806,9 +2806,9 @@ CIMGUI_API void cimgui::ImGui_DestroyPlatformWindows(void)
|
||||||
::ImGui::DestroyPlatformWindows();
|
::ImGui::DestroyPlatformWindows();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API cimgui::ImGuiViewport* cimgui::ImGui_FindViewportByID(ImGuiID id)
|
CIMGUI_API cimgui::ImGuiViewport* cimgui::ImGui_FindViewportByID(ImGuiID viewport_id)
|
||||||
{
|
{
|
||||||
return reinterpret_cast<::cimgui::ImGuiViewport*>(::ImGui::FindViewportByID(id));
|
return reinterpret_cast<::cimgui::ImGuiViewport*>(::ImGui::FindViewportByID(viewport_id));
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API cimgui::ImGuiViewport* cimgui::ImGui_FindViewportByPlatformHandle(void* platform_handle)
|
CIMGUI_API cimgui::ImGuiViewport* cimgui::ImGui_FindViewportByPlatformHandle(void* platform_handle)
|
||||||
|
|
@ -2906,15 +2906,6 @@ CIMGUI_API void cimgui::ImGuiIO_ClearInputMouse(cimgui::ImGuiIO* self)
|
||||||
reinterpret_cast<::ImGuiIO*>(self)->ClearInputMouse();
|
reinterpret_cast<::ImGuiIO*>(self)->ClearInputMouse();
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiIO_ClearInputCharacters(cimgui::ImGuiIO* self)
|
|
||||||
{
|
|
||||||
reinterpret_cast<::ImGuiIO*>(self)->ClearInputCharacters();
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextCallbackData_DeleteChars(cimgui::ImGuiInputTextCallbackData* self, int pos, int bytes_count)
|
CIMGUI_API void cimgui::ImGuiInputTextCallbackData_DeleteChars(cimgui::ImGuiInputTextCallbackData* self, int pos, int bytes_count)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextCallbackData*>(self)->DeleteChars(pos, bytes_count);
|
reinterpret_cast<::ImGuiInputTextCallbackData*>(self)->DeleteChars(pos, bytes_count);
|
||||||
|
|
@ -3158,15 +3149,6 @@ CIMGUI_API void cimgui::ImGuiListClipper_SeekCursorForItem(cimgui::ImGuiListClip
|
||||||
reinterpret_cast<::ImGuiListClipper*>(self)->SeekCursorForItem(item_index);
|
reinterpret_cast<::ImGuiListClipper*>(self)->SeekCursorForItem(item_index);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiListClipper_IncludeRangeByIndices(cimgui::ImGuiListClipper* self, int item_begin, int item_end)
|
|
||||||
{
|
|
||||||
reinterpret_cast<::ImGuiListClipper*>(self)->IncludeRangeByIndices(item_begin, item_end);
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImColor_SetHSV(cimgui::ImColor* self, float h, float s, float v, float a)
|
CIMGUI_API void cimgui::ImColor_SetHSV(cimgui::ImColor* self, float h, float s, float v, float a)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImColor*>(self)->SetHSV(h, s, v, a);
|
reinterpret_cast<::ImColor*>(self)->SetHSV(h, s, v, a);
|
||||||
|
|
@ -4033,9 +4015,9 @@ CIMGUI_API cimgui::ImVec2 cimgui::ImFont_CalcTextSizeA(cimgui::ImFont* self, flo
|
||||||
return ConvertFromCPP_ImVec2(reinterpret_cast<::ImFont*>(self)->CalcTextSizeA(size, max_width, wrap_width, text_begin));
|
return ConvertFromCPP_ImVec2(reinterpret_cast<::ImFont*>(self)->CalcTextSizeA(size, max_width, wrap_width, text_begin));
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API cimgui::ImVec2 cimgui::ImFont_CalcTextSizeAEx(cimgui::ImFont* self, float size, float max_width, float wrap_width, const char* text_begin, const char* text_end, const char** remaining)
|
CIMGUI_API cimgui::ImVec2 cimgui::ImFont_CalcTextSizeAEx(cimgui::ImFont* self, float size, float max_width, float wrap_width, const char* text_begin, const char* text_end, const char** out_remaining)
|
||||||
{
|
{
|
||||||
return ConvertFromCPP_ImVec2(reinterpret_cast<::ImFont*>(self)->CalcTextSizeA(size, max_width, wrap_width, text_begin, text_end, remaining));
|
return ConvertFromCPP_ImVec2(reinterpret_cast<::ImFont*>(self)->CalcTextSizeA(size, max_width, wrap_width, text_begin, text_end, out_remaining));
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API const char* cimgui::ImFont_CalcWordWrapPosition(cimgui::ImFont* self, float size, const char* text, const char* text_end, float wrap_width)
|
CIMGUI_API const char* cimgui::ImFont_CalcWordWrapPosition(cimgui::ImFont* self, float size, const char* text, const char* text_end, float wrap_width)
|
||||||
|
|
@ -4053,9 +4035,9 @@ CIMGUI_API void cimgui::ImFont_RenderCharEx(cimgui::ImFont* self, cimgui
|
||||||
reinterpret_cast<::ImFont*>(self)->RenderChar(reinterpret_cast<::ImDrawList*>(draw_list), size, ConvertToCPP_ImVec2(pos), col, c, reinterpret_cast<const ::ImVec4*>(cpu_fine_clip));
|
reinterpret_cast<::ImFont*>(self)->RenderChar(reinterpret_cast<::ImDrawList*>(draw_list), size, ConvertToCPP_ImVec2(pos), col, c, reinterpret_cast<const ::ImVec4*>(cpu_fine_clip));
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImFont_RenderText(cimgui::ImFont* self, cimgui::ImDrawList* draw_list, float size, cimgui::ImVec2 pos, ImU32 col, cimgui::ImVec4 clip_rect, const char* text_begin, const char* text_end, float wrap_width, bool cpu_fine_clip)
|
CIMGUI_API void cimgui::ImFont_RenderText(cimgui::ImFont* self, cimgui::ImDrawList* draw_list, float size, cimgui::ImVec2 pos, ImU32 col, cimgui::ImVec4 clip_rect, const char* text_begin, const char* text_end, float wrap_width, ImDrawTextFlags flags)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImFont*>(self)->RenderText(reinterpret_cast<::ImDrawList*>(draw_list), size, ConvertToCPP_ImVec2(pos), col, ConvertToCPP_ImVec4(clip_rect), text_begin, text_end, wrap_width, cpu_fine_clip);
|
reinterpret_cast<::ImFont*>(self)->RenderText(reinterpret_cast<::ImDrawList*>(draw_list), size, ConvertToCPP_ImVec2(pos), col, ConvertToCPP_ImVec4(clip_rect), text_begin, text_end, wrap_width, flags);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
|
|
@ -4092,6 +4074,16 @@ CIMGUI_API cimgui::ImVec2 cimgui::ImGuiViewport_GetWorkCenter(const cimgui::ImGu
|
||||||
return ConvertFromCPP_ImVec2(reinterpret_cast<const ::ImGuiViewport*>(self)->GetWorkCenter());
|
return ConvertFromCPP_ImVec2(reinterpret_cast<const ::ImGuiViewport*>(self)->GetWorkCenter());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_API void cimgui::ImGuiPlatformIO_ClearPlatformHandlers(cimgui::ImGuiPlatformIO* self)
|
||||||
|
{
|
||||||
|
reinterpret_cast<::ImGuiPlatformIO*>(self)->ClearPlatformHandlers();
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_API void cimgui::ImGuiPlatformIO_ClearRendererHandlers(cimgui::ImGuiPlatformIO* self)
|
||||||
|
{
|
||||||
|
reinterpret_cast<::ImGuiPlatformIO*>(self)->ClearRendererHandlers();
|
||||||
|
}
|
||||||
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGui_PushFont(cimgui::ImFont* font)
|
CIMGUI_API void cimgui::ImGui_PushFont(cimgui::ImFont* font)
|
||||||
|
|
@ -4184,10 +4176,5 @@ CIMGUI_API bool cimgui::ImGui_ListBoxObsoleteEx(const char* label, int* curren
|
||||||
return ::ImGui::ListBox(label, current_item, old_callback, user_data, items_count, height_in_items);
|
return ::ImGui::ListBox(label, current_item, old_callback, user_data, items_count, height_in_items);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGui_SetItemAllowOverlap(void)
|
|
||||||
{
|
|
||||||
::ImGui::SetItemAllowOverlap();
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
#endif // #ifndef IMGUI_DISABLE
|
#endif // #ifndef IMGUI_DISABLE
|
||||||
|
|
|
||||||
|
|
@ -2,38 +2,39 @@
|
||||||
// **DO NOT EDIT DIRECTLY**
|
// **DO NOT EDIT DIRECTLY**
|
||||||
// https://github.com/dearimgui/dear_bindings
|
// https://github.com/dearimgui/dear_bindings
|
||||||
|
|
||||||
// dear imgui, v1.92.2b
|
// dear imgui, v1.92.5
|
||||||
// (headers)
|
// (headers)
|
||||||
|
|
||||||
// Help:
|
// Help:
|
||||||
// - See links below.
|
|
||||||
// - Call and read ImGui::ShowDemoWindow() in imgui_demo.cpp. All applications in examples/ are doing that.
|
// - Call and read ImGui::ShowDemoWindow() in imgui_demo.cpp. All applications in examples/ are doing that.
|
||||||
// - Read top of imgui.cpp for more details, links and comments.
|
// - Read top of imgui.cpp for more details, links and comments.
|
||||||
// - Add '#define IMGUI_DEFINE_MATH_OPERATORS' before including this file (or in imconfig.h) to access courtesy maths operators for ImVec2 and ImVec4.
|
// - Add '#define IMGUI_DEFINE_MATH_OPERATORS' before including imgui.h (or in imconfig.h) to access courtesy maths operators for ImVec2 and ImVec4.
|
||||||
|
|
||||||
// Resources:
|
// Resources:
|
||||||
// - FAQ ........................ https://dearimgui.com/faq (in repository as docs/FAQ.md)
|
// - FAQ ........................ https://dearimgui.com/faq (in repository as docs/FAQ.md)
|
||||||
// - Homepage ................... https://github.com/ocornut/imgui
|
// - Homepage ................... https://github.com/ocornut/imgui
|
||||||
// - Releases & changelog ....... https://github.com/ocornut/imgui/releases
|
// - Releases & Changelog ....... https://github.com/ocornut/imgui/releases
|
||||||
// - Gallery .................... https://github.com/ocornut/imgui/issues?q=label%3Agallery (please post your screenshots/video there!)
|
// - Gallery .................... https://github.com/ocornut/imgui/issues?q=label%3Agallery (please post your screenshots/video there!)
|
||||||
// - Wiki ....................... https://github.com/ocornut/imgui/wiki (lots of good stuff there)
|
// - Wiki ....................... https://github.com/ocornut/imgui/wiki (lots of good stuff there)
|
||||||
// - Getting Started https://github.com/ocornut/imgui/wiki/Getting-Started (how to integrate in an existing app by adding ~25 lines of code)
|
// - Getting Started https://github.com/ocornut/imgui/wiki/Getting-Started (how to integrate in an existing app by adding ~25 lines of code)
|
||||||
// - Third-party Extensions https://github.com/ocornut/imgui/wiki/Useful-Extensions (ImPlot & many more)
|
// - Third-party Extensions https://github.com/ocornut/imgui/wiki/Useful-Extensions (ImPlot & many more)
|
||||||
// - Bindings/Backends https://github.com/ocornut/imgui/wiki/Bindings (language bindings, backends for various tech/engines)
|
// - Bindings/Backends https://github.com/ocornut/imgui/wiki/Bindings (language bindings + backends for various tech/engines)
|
||||||
// - Glossary https://github.com/ocornut/imgui/wiki/Glossary
|
|
||||||
// - Debug Tools https://github.com/ocornut/imgui/wiki/Debug-Tools
|
// - Debug Tools https://github.com/ocornut/imgui/wiki/Debug-Tools
|
||||||
|
// - Glossary https://github.com/ocornut/imgui/wiki/Glossary
|
||||||
// - Software using Dear ImGui https://github.com/ocornut/imgui/wiki/Software-using-dear-imgui
|
// - Software using Dear ImGui https://github.com/ocornut/imgui/wiki/Software-using-dear-imgui
|
||||||
// - Issues & support ........... https://github.com/ocornut/imgui/issues
|
// - Issues & support ........... https://github.com/ocornut/imgui/issues
|
||||||
// - Test Engine & Automation ... https://github.com/ocornut/imgui_test_engine (test suite, test engine to automate your apps)
|
// - Test Engine & Automation ... https://github.com/ocornut/imgui_test_engine (test suite, test engine to automate your apps)
|
||||||
|
// - Web version of the Demo .... https://pthom.github.io/imgui_manual_online/manual/imgui_manual.html (w/ source code browser)
|
||||||
|
|
||||||
// For first-time users having issues compiling/linking/running/loading fonts:
|
// For FIRST-TIME users having issues compiling/linking/running:
|
||||||
// please post in https://github.com/ocornut/imgui/discussions if you cannot find a solution in resources above.
|
// please post in https://github.com/ocornut/imgui/discussions if you cannot find a solution in resources above.
|
||||||
// Everything else should be asked in 'Issues'! We are building a database of cross-linked knowledge there.
|
// EVERYTHING ELSE should be asked in 'Issues'! We are building a database of cross-linked knowledge there.
|
||||||
|
// Since 1.92, we encourage font loading questions to also be posted in 'Issues'.
|
||||||
|
|
||||||
// Library Version
|
// Library Version
|
||||||
// (Integer encoded as XYYZZ for use in #if preprocessor conditionals, e.g. '#if IMGUI_VERSION_NUM >= 12345')
|
// (Integer encoded as XYYZZ for use in #if preprocessor conditionals, e.g. '#if IMGUI_VERSION_NUM >= 12345')
|
||||||
#define IMGUI_VERSION "1.92.2b"
|
#define IMGUI_VERSION "1.92.5"
|
||||||
#define IMGUI_VERSION_NUM 19222
|
#define IMGUI_VERSION_NUM 19250
|
||||||
#define IMGUI_HAS_TABLE // Added BeginTable() - from IMGUI_VERSION_NUM >= 18000
|
#define IMGUI_HAS_TABLE // Added BeginTable() - from IMGUI_VERSION_NUM >= 18000
|
||||||
#define IMGUI_HAS_TEXTURES // Added ImGuiBackendFlags_RendererHasTextures - from IMGUI_VERSION_NUM >= 19198
|
#define IMGUI_HAS_TEXTURES // Added ImGuiBackendFlags_RendererHasTextures - from IMGUI_VERSION_NUM >= 19198
|
||||||
#define IMGUI_HAS_VIEWPORT // In 'docking' WIP branch.
|
#define IMGUI_HAS_VIEWPORT // In 'docking' WIP branch.
|
||||||
|
|
@ -98,19 +99,24 @@ extern "C"
|
||||||
#define CIMGUI_IMPL_API CIMGUI_API
|
#define CIMGUI_IMPL_API CIMGUI_API
|
||||||
#endif // #ifndef CIMGUI_IMPL_API
|
#endif // #ifndef CIMGUI_IMPL_API
|
||||||
// Helper Macros
|
// Helper Macros
|
||||||
|
// (note: compiling with NDEBUG will usually strip out assert() to nothing, which is NOT recommended because we use asserts to notify of programmer mistakes.)
|
||||||
#ifndef IM_ASSERT
|
#ifndef IM_ASSERT
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
#define IM_ASSERT(_EXPR) assert(_EXPR) // You can override the default assert handler by editing imconfig.h
|
#define IM_ASSERT(_EXPR) assert(_EXPR) // You can override the default assert handler by editing imconfig.h
|
||||||
#endif // #ifndef IM_ASSERT
|
#endif // #ifndef IM_ASSERT
|
||||||
#define IM_ARRAYSIZE(_ARR) ((int)(sizeof(_ARR) / sizeof(*(_ARR)))) // Size of a static C-style array. Don't use on pointers!
|
#define IM_ARRAYSIZE(_ARR) ((int)(sizeof(_ARR) / sizeof(*(_ARR)))) // Size of a static C-style array. Don't use on pointers!
|
||||||
#define IM_UNUSED(_VAR) ((void)(_VAR)) // Used to silence "unused variable warnings". Often useful as asserts may be stripped out from final builds.
|
#define IM_UNUSED(_VAR) ((void)(_VAR)) // Used to silence "unused variable warnings". Often useful as asserts may be stripped out from final builds.
|
||||||
|
#define IM_STRINGIFY_HELPER(_EXPR) #_EXPR
|
||||||
|
#define IM_STRINGIFY(_EXPR) IM_STRINGIFY_HELPER(_EXPR) // Preprocessor idiom to stringify e.g. an integer or a macro.
|
||||||
|
|
||||||
// Check that version and structures layouts are matching between compiled imgui code and caller. Read comments above DebugCheckVersionAndDataLayout() for details.
|
// Check that version and structures layouts are matching between compiled imgui code and caller. Read comments above DebugCheckVersionAndDataLayout() for details.
|
||||||
#define CIMGUI_CHECKVERSION() ImGui_DebugCheckVersionAndDataLayout(IMGUI_VERSION, sizeof(ImGuiIO), sizeof(ImGuiStyle), sizeof(ImVec2), sizeof(ImVec4), sizeof(ImDrawVert), sizeof(ImDrawIdx))
|
#define CIMGUI_CHECKVERSION() ImGui_DebugCheckVersionAndDataLayout(IMGUI_VERSION, sizeof(ImGuiIO), sizeof(ImGuiStyle), sizeof(ImVec2), sizeof(ImVec4), sizeof(ImDrawVert), sizeof(ImDrawIdx))
|
||||||
|
|
||||||
// Helper Macros - IM_FMTARGS, IM_FMTLIST: Apply printf-style warnings to our formatting functions.
|
// Helper Macros - IM_FMTARGS, IM_FMTLIST: Apply printf-style warnings to our formatting functions.
|
||||||
// (MSVC provides an equivalent mechanism via SAL Annotations but it would require the macros in a different
|
// (MSVC provides an equivalent mechanism via SAL Annotations but it requires the macros in a different
|
||||||
// location. e.g. #include <sal.h> + void myprintf(_Printf_format_string_ const char* format, ...))
|
// location. e.g. #include <sal.h> + void myprintf(_Printf_format_string_ const char* format, ...),
|
||||||
|
// and only works when using Code Analysis, rather than just normal compiling).
|
||||||
|
// (see https://github.com/ocornut/imgui/issues/8871 for a patch to enable this for MSVC's Code Analysis)
|
||||||
#if !defined(IMGUI_USE_STB_SPRINTF)&& defined(__MINGW32__)&&!defined(__clang__)
|
#if !defined(IMGUI_USE_STB_SPRINTF)&& defined(__MINGW32__)&&!defined(__clang__)
|
||||||
#define IM_FMTARGS(FMT) __attribute__((format(gnu_printf, FMT, FMT+1)))
|
#define IM_FMTARGS(FMT) __attribute__((format(gnu_printf, FMT, FMT+1)))
|
||||||
#define IM_FMTLIST(FMT) __attribute__((format(gnu_printf, FMT, 0)))
|
#define IM_FMTLIST(FMT) __attribute__((format(gnu_printf, FMT, 0)))
|
||||||
|
|
@ -258,9 +264,9 @@ typedef struct ImGuiWindowClass_t ImGuiWindowClass; /
|
||||||
// Enumerations
|
// Enumerations
|
||||||
// - We don't use strongly typed enums much because they add constraints (can't extend in private code, can't store typed in bit fields, extra casting on iteration)
|
// - We don't use strongly typed enums much because they add constraints (can't extend in private code, can't store typed in bit fields, extra casting on iteration)
|
||||||
// - Tip: Use your programming IDE navigation facilities on the names in the _central column_ below to find the actual flags/enum lists!
|
// - Tip: Use your programming IDE navigation facilities on the names in the _central column_ below to find the actual flags/enum lists!
|
||||||
// - In Visual Studio: CTRL+comma ("Edit.GoToAll") can follow symbols inside comments, whereas CTRL+F12 ("Edit.GoToImplementation") cannot.
|
// - In Visual Studio: Ctrl+Comma ("Edit.GoToAll") can follow symbols inside comments, whereas Ctrl+F12 ("Edit.GoToImplementation") cannot.
|
||||||
// - In Visual Studio w/ Visual Assist installed: ALT+G ("VAssistX.GoToImplementation") can also follow symbols inside comments.
|
// - In Visual Studio w/ Visual Assist installed: Alt+G ("VAssistX.GoToImplementation") can also follow symbols inside comments.
|
||||||
// - In VS Code, CLion, etc.: CTRL+click can follow symbols inside comments.
|
// - In VS Code, CLion, etc.: Ctrl+Click can follow symbols inside comments.
|
||||||
typedef int ImGuiDir; // -> enum ImGuiDir // Enum: A cardinal direction (Left, Right, Up, Down)
|
typedef int ImGuiDir; // -> enum ImGuiDir // Enum: A cardinal direction (Left, Right, Up, Down)
|
||||||
typedef int ImGuiKey; // -> enum ImGuiKey // Enum: A key identifier (ImGuiKey_XXX or ImGuiMod_XXX value)
|
typedef int ImGuiKey; // -> enum ImGuiKey // Enum: A key identifier (ImGuiKey_XXX or ImGuiMod_XXX value)
|
||||||
typedef int ImGuiMouseSource; // -> enum ImGuiMouseSource // Enum; A mouse input source identifier (Mouse, TouchScreen, Pen)
|
typedef int ImGuiMouseSource; // -> enum ImGuiMouseSource // Enum; A mouse input source identifier (Mouse, TouchScreen, Pen)
|
||||||
|
|
@ -275,11 +281,12 @@ typedef int ImGuiTableBgTarget; // -> enum ImGuiTableBgTarget_ // Enum: A co
|
||||||
|
|
||||||
// Flags (declared as int to allow using as flags without overhead, and to not pollute the top of this file)
|
// Flags (declared as int to allow using as flags without overhead, and to not pollute the top of this file)
|
||||||
// - Tip: Use your programming IDE navigation facilities on the names in the _central column_ below to find the actual flags/enum lists!
|
// - Tip: Use your programming IDE navigation facilities on the names in the _central column_ below to find the actual flags/enum lists!
|
||||||
// - In Visual Studio: CTRL+comma ("Edit.GoToAll") can follow symbols inside comments, whereas CTRL+F12 ("Edit.GoToImplementation") cannot.
|
// - In Visual Studio: Ctrl+Comma ("Edit.GoToAll") can follow symbols inside comments, whereas Ctrl+F12 ("Edit.GoToImplementation") cannot.
|
||||||
// - In Visual Studio w/ Visual Assist installed: ALT+G ("VAssistX.GoToImplementation") can also follow symbols inside comments.
|
// - In Visual Studio w/ Visual Assist installed: Alt+G ("VAssistX.GoToImplementation") can also follow symbols inside comments.
|
||||||
// - In VS Code, CLion, etc.: CTRL+click can follow symbols inside comments.
|
// - In VS Code, CLion, etc.: Ctrl+Click can follow symbols inside comments.
|
||||||
typedef int ImDrawFlags; // -> enum ImDrawFlags_ // Flags: for ImDrawList functions
|
typedef int ImDrawFlags; // -> enum ImDrawFlags_ // Flags: for ImDrawList functions
|
||||||
typedef int ImDrawListFlags; // -> enum ImDrawListFlags_ // Flags: for ImDrawList instance
|
typedef int ImDrawListFlags; // -> enum ImDrawListFlags_ // Flags: for ImDrawList instance
|
||||||
|
typedef int ImDrawTextFlags; // -> enum ImDrawTextFlags_ // Internal, do not use!
|
||||||
typedef int ImFontFlags; // -> enum ImFontFlags_ // Flags: for ImFont
|
typedef int ImFontFlags; // -> enum ImFontFlags_ // Flags: for ImFont
|
||||||
typedef int ImFontAtlasFlags; // -> enum ImFontAtlasFlags_ // Flags: for ImFontAtlas
|
typedef int ImFontAtlasFlags; // -> enum ImFontAtlasFlags_ // Flags: for ImFontAtlas
|
||||||
typedef int ImGuiBackendFlags; // -> enum ImGuiBackendFlags_ // Flags: for io.BackendFlags
|
typedef int ImGuiBackendFlags; // -> enum ImGuiBackendFlags_ // Flags: for io.BackendFlags
|
||||||
|
|
@ -296,6 +303,7 @@ typedef int ImGuiInputFlags; // -> enum ImGuiInputFlags_ // Flags: f
|
||||||
typedef int ImGuiInputTextFlags; // -> enum ImGuiInputTextFlags_ // Flags: for InputText(), InputTextMultiline()
|
typedef int ImGuiInputTextFlags; // -> enum ImGuiInputTextFlags_ // Flags: for InputText(), InputTextMultiline()
|
||||||
typedef int ImGuiItemFlags; // -> enum ImGuiItemFlags_ // Flags: for PushItemFlag(), shared by all items
|
typedef int ImGuiItemFlags; // -> enum ImGuiItemFlags_ // Flags: for PushItemFlag(), shared by all items
|
||||||
typedef int ImGuiKeyChord; // -> ImGuiKey | ImGuiMod_XXX // Flags: for IsKeyChordPressed(), Shortcut() etc. an ImGuiKey optionally OR-ed with one or more ImGuiMod_XXX values.
|
typedef int ImGuiKeyChord; // -> ImGuiKey | ImGuiMod_XXX // Flags: for IsKeyChordPressed(), Shortcut() etc. an ImGuiKey optionally OR-ed with one or more ImGuiMod_XXX values.
|
||||||
|
typedef int ImGuiListClipperFlags; // -> enum ImGuiListClipperFlags_// Flags: for ImGuiListClipper
|
||||||
typedef int ImGuiPopupFlags; // -> enum ImGuiPopupFlags_ // Flags: for OpenPopup*(), BeginPopupContext*(), IsPopupOpen()
|
typedef int ImGuiPopupFlags; // -> enum ImGuiPopupFlags_ // Flags: for OpenPopup*(), BeginPopupContext*(), IsPopupOpen()
|
||||||
typedef int ImGuiMultiSelectFlags; // -> enum ImGuiMultiSelectFlags_// Flags: for BeginMultiSelect()
|
typedef int ImGuiMultiSelectFlags; // -> enum ImGuiMultiSelectFlags_// Flags: for BeginMultiSelect()
|
||||||
typedef int ImGuiSelectableFlags; // -> enum ImGuiSelectableFlags_ // Flags: for Selectable()
|
typedef int ImGuiSelectableFlags; // -> enum ImGuiSelectableFlags_ // Flags: for Selectable()
|
||||||
|
|
@ -363,7 +371,7 @@ IM_MSVC_RUNTIME_CHECKS_RESTORE
|
||||||
// - You may decide to store a higher-level structure containing texture, sampler, shader etc. with various
|
// - You may decide to store a higher-level structure containing texture, sampler, shader etc. with various
|
||||||
// constructors if you like. You will need to implement ==/!= operators.
|
// constructors if you like. You will need to implement ==/!= operators.
|
||||||
// History:
|
// History:
|
||||||
// - In v1.91.4 (2024/10/08): the default type for ImTextureID was changed from 'void*' to 'ImU64'. This allowed backends requirig 64-bit worth of data to build on 32-bit architectures. Use intermediary intptr_t cast and read FAQ if you have casting warnings.
|
// - In v1.91.4 (2024/10/08): the default type for ImTextureID was changed from 'void*' to 'ImU64'. This allowed backends requiring 64-bit worth of data to build on 32-bit architectures. Use intermediary intptr_t cast and read FAQ if you have casting warnings.
|
||||||
// - In v1.92.0 (2025/06/11): added ImTextureRef which carry either a ImTextureID either a pointer to internal texture atlas. All user facing functions taking ImTextureID changed to ImTextureRef
|
// - In v1.92.0 (2025/06/11): added ImTextureRef which carry either a ImTextureID either a pointer to internal texture atlas. All user facing functions taking ImTextureID changed to ImTextureRef
|
||||||
#ifndef ImTextureID
|
#ifndef ImTextureID
|
||||||
typedef ImU64 ImTextureID; // Default: store up to 64-bits (any pointer or integer). A majority of backends are ok with that.
|
typedef ImU64 ImTextureID; // Default: store up to 64-bits (any pointer or integer). A majority of backends are ok with that.
|
||||||
|
|
@ -702,13 +710,13 @@ CIMGUI_API bool ImGui_ComboCallback(const char* label, int* current_item, const
|
||||||
CIMGUI_API bool ImGui_ComboCallbackEx(const char* label, int* current_item, const char* (*getter)(void* user_data, int idx), void* user_data, int items_count, int popup_max_height_in_items /* = -1 */);
|
CIMGUI_API bool ImGui_ComboCallbackEx(const char* label, int* current_item, const char* (*getter)(void* user_data, int idx), void* user_data, int items_count, int popup_max_height_in_items /* = -1 */);
|
||||||
|
|
||||||
// Widgets: Drag Sliders
|
// Widgets: Drag Sliders
|
||||||
// - CTRL+Click on any drag box to turn them into an input box. Manually input values aren't clamped by default and can go off-bounds. Use ImGuiSliderFlags_AlwaysClamp to always clamp.
|
// - Ctrl+Click on any drag box to turn them into an input box. Manually input values aren't clamped by default and can go off-bounds. Use ImGuiSliderFlags_AlwaysClamp to always clamp.
|
||||||
// - For all the Float2/Float3/Float4/Int2/Int3/Int4 versions of every function, note that a 'float v[X]' function argument is the same as 'float* v',
|
// - For all the Float2/Float3/Float4/Int2/Int3/Int4 versions of every function, note that a 'float v[X]' function argument is the same as 'float* v',
|
||||||
// the array syntax is just a way to document the number of elements that are expected to be accessible. You can pass address of your first element out of a contiguous set, e.g. &myvector.x
|
// the array syntax is just a way to document the number of elements that are expected to be accessible. You can pass address of your first element out of a contiguous set, e.g. &myvector.x
|
||||||
// - Adjust format string to decorate the value with a prefix, a suffix, or adapt the editing and display precision e.g. "%.3f" -> 1.234; "%5.2f secs" -> 01.23 secs; "Biscuit: %.0f" -> Biscuit: 1; etc.
|
// - Adjust format string to decorate the value with a prefix, a suffix, or adapt the editing and display precision e.g. "%.3f" -> 1.234; "%5.2f secs" -> 01.23 secs; "Biscuit: %.0f" -> Biscuit: 1; etc.
|
||||||
// - Format string may also be set to NULL or use the default format ("%f" or "%d").
|
// - Format string may also be set to NULL or use the default format ("%f" or "%d").
|
||||||
// - Speed are per-pixel of mouse movement (v_speed=0.2f: mouse needs to move by 5 pixels to increase value by 1). For keyboard/gamepad navigation, minimum speed is Max(v_speed, minimum_step_at_given_precision).
|
// - Speed are per-pixel of mouse movement (v_speed=0.2f: mouse needs to move by 5 pixels to increase value by 1). For keyboard/gamepad navigation, minimum speed is Max(v_speed, minimum_step_at_given_precision).
|
||||||
// - Use v_min < v_max to clamp edits to given limits. Note that CTRL+Click manual input can override those limits if ImGuiSliderFlags_AlwaysClamp is not used.
|
// - Use v_min < v_max to clamp edits to given limits. Note that Ctrl+Click manual input can override those limits if ImGuiSliderFlags_AlwaysClamp is not used.
|
||||||
// - Use v_max = FLT_MAX / INT_MAX etc to avoid clamping to a maximum, same with v_min = -FLT_MAX / INT_MIN to avoid clamping to a minimum.
|
// - Use v_max = FLT_MAX / INT_MAX etc to avoid clamping to a maximum, same with v_min = -FLT_MAX / INT_MIN to avoid clamping to a minimum.
|
||||||
// - We use the same sets of flags for DragXXX() and SliderXXX() functions as the features are the same and it makes it easier to swap them.
|
// - We use the same sets of flags for DragXXX() and SliderXXX() functions as the features are the same and it makes it easier to swap them.
|
||||||
// - Legacy: Pre-1.78 there are DragXXX() function signatures that take a final `float power=1.0f' argument instead of the `ImGuiSliderFlags flags=0' argument.
|
// - Legacy: Pre-1.78 there are DragXXX() function signatures that take a final `float power=1.0f' argument instead of the `ImGuiSliderFlags flags=0' argument.
|
||||||
|
|
@ -739,7 +747,7 @@ CIMGUI_API bool ImGui_DragScalarN(const char* label, ImGuiDataType data_type, vo
|
||||||
CIMGUI_API bool ImGui_DragScalarNEx(const char* label, ImGuiDataType data_type, void* p_data, int components, float v_speed /* = 1.0f */, const void* p_min /* = NULL */, const void* p_max /* = NULL */, const char* format /* = NULL */, ImGuiSliderFlags flags /* = 0 */);
|
CIMGUI_API bool ImGui_DragScalarNEx(const char* label, ImGuiDataType data_type, void* p_data, int components, float v_speed /* = 1.0f */, const void* p_min /* = NULL */, const void* p_max /* = NULL */, const char* format /* = NULL */, ImGuiSliderFlags flags /* = 0 */);
|
||||||
|
|
||||||
// Widgets: Regular Sliders
|
// Widgets: Regular Sliders
|
||||||
// - CTRL+Click on any slider to turn them into an input box. Manually input values aren't clamped by default and can go off-bounds. Use ImGuiSliderFlags_AlwaysClamp to always clamp.
|
// - Ctrl+Click on any slider to turn them into an input box. Manually input values aren't clamped by default and can go off-bounds. Use ImGuiSliderFlags_AlwaysClamp to always clamp.
|
||||||
// - Adjust format string to decorate the value with a prefix, a suffix, or adapt the editing and display precision e.g. "%.3f" -> 1.234; "%5.2f secs" -> 01.23 secs; "Biscuit: %.0f" -> Biscuit: 1; etc.
|
// - Adjust format string to decorate the value with a prefix, a suffix, or adapt the editing and display precision e.g. "%.3f" -> 1.234; "%5.2f secs" -> 01.23 secs; "Biscuit: %.0f" -> Biscuit: 1; etc.
|
||||||
// - Format string may also be set to NULL or use the default format ("%f" or "%d").
|
// - Format string may also be set to NULL or use the default format ("%f" or "%d").
|
||||||
// - Legacy: Pre-1.78 there are SliderXXX() function signatures that take a final `float power=1.0f' argument instead of the `ImGuiSliderFlags flags=0' argument.
|
// - Legacy: Pre-1.78 there are SliderXXX() function signatures that take a final `float power=1.0f' argument instead of the `ImGuiSliderFlags flags=0' argument.
|
||||||
|
|
@ -774,7 +782,7 @@ CIMGUI_API bool ImGui_VSliderScalar(const char* label, ImVec2 size, ImGuiDataTyp
|
||||||
CIMGUI_API bool ImGui_VSliderScalarEx(const char* label, ImVec2 size, ImGuiDataType data_type, void* p_data, const void* p_min, const void* p_max, const char* format /* = NULL */, ImGuiSliderFlags flags /* = 0 */);
|
CIMGUI_API bool ImGui_VSliderScalarEx(const char* label, ImVec2 size, ImGuiDataType data_type, void* p_data, const void* p_min, const void* p_max, const char* format /* = NULL */, ImGuiSliderFlags flags /* = 0 */);
|
||||||
|
|
||||||
// Widgets: Input with Keyboard
|
// Widgets: Input with Keyboard
|
||||||
// - If you want to use InputText() with std::string or any custom dynamic string type, see misc/cpp/imgui_stdlib.h and comments in imgui_demo.cpp.
|
// - If you want to use InputText() with std::string or any custom dynamic string type, use the wrapper in misc/cpp/imgui_stdlib.h/.cpp!
|
||||||
// - Most of the ImGuiInputTextFlags flags are only useful for InputText() and not for InputFloatX, InputIntX, InputDouble etc.
|
// - Most of the ImGuiInputTextFlags flags are only useful for InputText() and not for InputFloatX, InputIntX, InputDouble etc.
|
||||||
CIMGUI_API bool ImGui_InputText(const char* label, char* buf, size_t buf_size, ImGuiInputTextFlags flags /* = 0 */); // Implied callback = NULL, user_data = NULL
|
CIMGUI_API bool ImGui_InputText(const char* label, char* buf, size_t buf_size, ImGuiInputTextFlags flags /* = 0 */); // Implied callback = NULL, user_data = NULL
|
||||||
CIMGUI_API bool ImGui_InputTextEx(const char* label, char* buf, size_t buf_size, ImGuiInputTextFlags flags /* = 0 */, ImGuiInputTextCallback callback /* = NULL */, void* user_data /* = NULL */);
|
CIMGUI_API bool ImGui_InputTextEx(const char* label, char* buf, size_t buf_size, ImGuiInputTextFlags flags /* = 0 */, ImGuiInputTextCallback callback /* = NULL */, void* user_data /* = NULL */);
|
||||||
|
|
@ -816,7 +824,7 @@ CIMGUI_API void ImGui_SetColorEditOptions(ImGuiColorEditFlags flags);
|
||||||
// Widgets: Trees
|
// Widgets: Trees
|
||||||
// - TreeNode functions return true when the node is open, in which case you need to also call TreePop() when you are finished displaying the tree node contents.
|
// - TreeNode functions return true when the node is open, in which case you need to also call TreePop() when you are finished displaying the tree node contents.
|
||||||
CIMGUI_API bool ImGui_TreeNode(const char* label);
|
CIMGUI_API bool ImGui_TreeNode(const char* label);
|
||||||
CIMGUI_API bool ImGui_TreeNodeStr(const char* str_id, const char* fmt, ...) IM_FMTARGS(2); // helper variation to easily decorelate the id from the displayed string. Read the FAQ about why and how to use ID. to align arbitrary text at the same level as a TreeNode() you can use Bullet().
|
CIMGUI_API bool ImGui_TreeNodeStr(const char* str_id, const char* fmt, ...) IM_FMTARGS(2); // helper variation to easily decorrelate the id from the displayed string. Read the FAQ about why and how to use ID. to align arbitrary text at the same level as a TreeNode() you can use Bullet().
|
||||||
CIMGUI_API bool ImGui_TreeNodePtr(const void* ptr_id, const char* fmt, ...) IM_FMTARGS(2); // "
|
CIMGUI_API bool ImGui_TreeNodePtr(const void* ptr_id, const char* fmt, ...) IM_FMTARGS(2); // "
|
||||||
CIMGUI_API bool ImGui_TreeNodeV(const char* str_id, const char* fmt, va_list args) IM_FMTLIST(2);
|
CIMGUI_API bool ImGui_TreeNodeV(const char* str_id, const char* fmt, va_list args) IM_FMTLIST(2);
|
||||||
CIMGUI_API bool ImGui_TreeNodeVPtr(const void* ptr_id, const char* fmt, va_list args) IM_FMTLIST(2);
|
CIMGUI_API bool ImGui_TreeNodeVPtr(const void* ptr_id, const char* fmt, va_list args) IM_FMTLIST(2);
|
||||||
|
|
@ -843,7 +851,7 @@ CIMGUI_API bool ImGui_SelectableBoolPtr(const char* label, bool* p_selected, ImG
|
||||||
CIMGUI_API bool ImGui_SelectableBoolPtrEx(const char* label, bool* p_selected, ImGuiSelectableFlags flags /* = 0 */, ImVec2 size /* = ImVec2(0, 0) */); // "bool* p_selected" point to the selection state (read-write), as a convenient helper.
|
CIMGUI_API bool ImGui_SelectableBoolPtrEx(const char* label, bool* p_selected, ImGuiSelectableFlags flags /* = 0 */, ImVec2 size /* = ImVec2(0, 0) */); // "bool* p_selected" point to the selection state (read-write), as a convenient helper.
|
||||||
|
|
||||||
// Multi-selection system for Selectable(), Checkbox(), TreeNode() functions [BETA]
|
// Multi-selection system for Selectable(), Checkbox(), TreeNode() functions [BETA]
|
||||||
// - This enables standard multi-selection/range-selection idioms (CTRL+Mouse/Keyboard, SHIFT+Mouse/Keyboard, etc.) in a way that also allow a clipper to be used.
|
// - This enables standard multi-selection/range-selection idioms (Ctrl+Mouse/Keyboard, Shift+Mouse/Keyboard, etc.) in a way that also allow a clipper to be used.
|
||||||
// - ImGuiSelectionUserData is often used to store your item index within the current view (but may store something else).
|
// - ImGuiSelectionUserData is often used to store your item index within the current view (but may store something else).
|
||||||
// - Read comments near ImGuiMultiSelectIO for instructions/details and see 'Demo->Widgets->Selection State & Multi-Select' for demo.
|
// - Read comments near ImGuiMultiSelectIO for instructions/details and see 'Demo->Widgets->Selection State & Multi-Select' for demo.
|
||||||
// - TreeNode() is technically supported but... using this correctly is more complicated. You need some sort of linear/random access to your tree,
|
// - TreeNode() is technically supported but... using this correctly is more complicated. You need some sort of linear/random access to your tree,
|
||||||
|
|
@ -1039,18 +1047,24 @@ CIMGUI_API bool ImGui_TabItemButton(const char* label, ImGuiTabItemFlags flags /
|
||||||
CIMGUI_API void ImGui_SetTabItemClosed(const char* tab_or_docked_window_label); // notify TabBar or Docking system of a closed tab/window ahead (useful to reduce visual flicker on reorderable tab bars). For tab-bar: call after BeginTabBar() and before Tab submissions. Otherwise call with a window name.
|
CIMGUI_API void ImGui_SetTabItemClosed(const char* tab_or_docked_window_label); // notify TabBar or Docking system of a closed tab/window ahead (useful to reduce visual flicker on reorderable tab bars). For tab-bar: call after BeginTabBar() and before Tab submissions. Otherwise call with a window name.
|
||||||
|
|
||||||
// Docking
|
// Docking
|
||||||
// [BETA API] Enable with io.ConfigFlags |= ImGuiConfigFlags_DockingEnable.
|
// - Read https://github.com/ocornut/imgui/wiki/Docking for details.
|
||||||
// Note: You can use most Docking facilities without calling any API. You DO NOT need to call DockSpace() to use Docking!
|
// - Enable with io.ConfigFlags |= ImGuiConfigFlags_DockingEnable.
|
||||||
// - Drag from window title bar or their tab to dock/undock. Hold SHIFT to disable docking.
|
// - You can use most Docking facilities without calling any API. You don't necessarily need to call a DockSpaceXXX function to use Docking!
|
||||||
// - Drag from window menu button (upper-left button) to undock an entire node (all windows).
|
// - Drag from window title bar or their tab to dock/undock. Hold SHIFT to disable docking.
|
||||||
// - When io.ConfigDockingWithShift == true, you instead need to hold SHIFT to enable docking.
|
// - Drag from window menu button (upper-left button) to undock an entire node (all windows).
|
||||||
// About dockspaces:
|
// - When io.ConfigDockingWithShift == true, you instead need to hold SHIFT to enable docking.
|
||||||
// - Use DockSpaceOverViewport() to create a window covering the screen or a specific viewport + a dockspace inside it.
|
// - Dockspaces:
|
||||||
// This is often used with ImGuiDockNodeFlags_PassthruCentralNode to make it transparent.
|
// - If you want to dock windows into the edge of your screen, most application can simply call DockSpaceOverViewport():
|
||||||
// - Use DockSpace() to create an explicit dock node _within_ an existing window. See Docking demo for details.
|
// e.g. ImGui::NewFrame(); then ImGui::DockSpaceOverViewport(); // Create a dockspace in main viewport.
|
||||||
// - Important: Dockspaces need to be submitted _before_ any window they can host. Submit it early in your frame!
|
// or: ImGui::NewFrame(); then ImGui::DockSpaceOverViewport(0, nullptr, ImGuiDockNodeFlags_PassthruCentralNode); // Create a dockspace in main viewport, where central node is transparent.
|
||||||
// - Important: Dockspaces need to be kept alive if hidden, otherwise windows docked into it will be undocked.
|
// - A dockspace is an explicit dock node within an existing window.
|
||||||
// e.g. if you have multiple tabs with a dockspace inside each tab: submit the non-visible dockspaces with ImGuiDockNodeFlags_KeepAliveOnly.
|
// - DockSpaceOverViewport() basically creates an invisible window covering a viewport, and submit a DockSpace() into it.
|
||||||
|
// - IMPORTANT: Dockspaces need to be submitted _before_ any window they can host. Submit them early in your frame!
|
||||||
|
// - IMPORTANT: Dockspaces need to be kept alive if hidden, otherwise windows docked into it will be undocked.
|
||||||
|
// If you have e.g. multiple tabs with a dockspace inside each tab: submit the non-visible dockspaces with ImGuiDockNodeFlags_KeepAliveOnly.
|
||||||
|
// - Programmatic docking:
|
||||||
|
// - There is no public API yet other than the very limited SetNextWindowDockID() function. Sorry for that!
|
||||||
|
// - Read https://github.com/ocornut/imgui/wiki/Docking for examples of how to use current internal API.
|
||||||
CIMGUI_API ImGuiID ImGui_DockSpace(ImGuiID dockspace_id); // Implied size = ImVec2(0, 0), flags = 0, window_class = NULL
|
CIMGUI_API ImGuiID ImGui_DockSpace(ImGuiID dockspace_id); // Implied size = ImVec2(0, 0), flags = 0, window_class = NULL
|
||||||
CIMGUI_API ImGuiID ImGui_DockSpaceEx(ImGuiID dockspace_id, ImVec2 size /* = ImVec2(0, 0) */, ImGuiDockNodeFlags flags /* = 0 */, const ImGuiWindowClass* window_class /* = NULL */);
|
CIMGUI_API ImGuiID ImGui_DockSpaceEx(ImGuiID dockspace_id, ImVec2 size /* = ImVec2(0, 0) */, ImGuiDockNodeFlags flags /* = 0 */, const ImGuiWindowClass* window_class /* = NULL */);
|
||||||
CIMGUI_API ImGuiID ImGui_DockSpaceOverViewport(void); // Implied dockspace_id = 0, viewport = NULL, flags = 0, window_class = NULL
|
CIMGUI_API ImGuiID ImGui_DockSpaceOverViewport(void); // Implied dockspace_id = 0, viewport = NULL, flags = 0, window_class = NULL
|
||||||
|
|
@ -1086,7 +1100,7 @@ CIMGUI_API const ImGuiPayload* ImGui_GetDragDropPayload(void);
|
||||||
// Disabling [BETA API]
|
// Disabling [BETA API]
|
||||||
// - Disable all user interactions and dim items visuals (applying style.DisabledAlpha over current colors)
|
// - Disable all user interactions and dim items visuals (applying style.DisabledAlpha over current colors)
|
||||||
// - Those can be nested but it cannot be used to enable an already disabled section (a single BeginDisabled(true) in the stack is enough to keep everything disabled)
|
// - Those can be nested but it cannot be used to enable an already disabled section (a single BeginDisabled(true) in the stack is enough to keep everything disabled)
|
||||||
// - Tooltips windows by exception are opted out of disabling.
|
// - Tooltips windows are automatically opted out of disabling. Note that IsItemHovered() by default returns false on disabled items, unless using ImGuiHoveredFlags_AllowWhenDisabled.
|
||||||
// - BeginDisabled(false)/EndDisabled() essentially does nothing but is provided to facilitate use of boolean expressions (as a micro-optimization: if you have tens of thousands of BeginDisabled(false)/EndDisabled() pairs, you might want to reformulate your code to avoid making those calls)
|
// - BeginDisabled(false)/EndDisabled() essentially does nothing but is provided to facilitate use of boolean expressions (as a micro-optimization: if you have tens of thousands of BeginDisabled(false)/EndDisabled() pairs, you might want to reformulate your code to avoid making those calls)
|
||||||
CIMGUI_API void ImGui_BeginDisabled(bool disabled /* = true */);
|
CIMGUI_API void ImGui_BeginDisabled(bool disabled /* = true */);
|
||||||
CIMGUI_API void ImGui_EndDisabled(void);
|
CIMGUI_API void ImGui_EndDisabled(void);
|
||||||
|
|
@ -1176,8 +1190,8 @@ CIMGUI_API void ImGui_SetNextFrameWantCaptureKeyboard(bool want_capture_k
|
||||||
|
|
||||||
// Inputs Utilities: Shortcut Testing & Routing [BETA]
|
// Inputs Utilities: Shortcut Testing & Routing [BETA]
|
||||||
// - ImGuiKeyChord = a ImGuiKey + optional ImGuiMod_Alt/ImGuiMod_Ctrl/ImGuiMod_Shift/ImGuiMod_Super.
|
// - ImGuiKeyChord = a ImGuiKey + optional ImGuiMod_Alt/ImGuiMod_Ctrl/ImGuiMod_Shift/ImGuiMod_Super.
|
||||||
// ImGuiKey_C // Accepted by functions taking ImGuiKey or ImGuiKeyChord arguments)
|
// ImGuiKey_C // Accepted by functions taking ImGuiKey or ImGuiKeyChord arguments
|
||||||
// ImGuiMod_Ctrl | ImGuiKey_C // Accepted by functions taking ImGuiKeyChord arguments)
|
// ImGuiMod_Ctrl | ImGuiKey_C // Accepted by functions taking ImGuiKeyChord arguments
|
||||||
// only ImGuiMod_XXX values are legal to combine with an ImGuiKey. You CANNOT combine two ImGuiKey values.
|
// only ImGuiMod_XXX values are legal to combine with an ImGuiKey. You CANNOT combine two ImGuiKey values.
|
||||||
// - The general idea is that several callers may register interest in a shortcut, and only one owner gets it.
|
// - The general idea is that several callers may register interest in a shortcut, and only one owner gets it.
|
||||||
// Parent -> call Shortcut(Ctrl+S) // When Parent is focused, Parent gets the shortcut.
|
// Parent -> call Shortcut(Ctrl+S) // When Parent is focused, Parent gets the shortcut.
|
||||||
|
|
@ -1265,7 +1279,7 @@ CIMGUI_API void ImGui_UpdatePlatformWindows(void);
|
||||||
CIMGUI_API void ImGui_RenderPlatformWindowsDefault(void); // Implied platform_render_arg = NULL, renderer_render_arg = NULL
|
CIMGUI_API void ImGui_RenderPlatformWindowsDefault(void); // Implied platform_render_arg = NULL, renderer_render_arg = NULL
|
||||||
CIMGUI_API void ImGui_RenderPlatformWindowsDefaultEx(void* platform_render_arg /* = NULL */, void* renderer_render_arg /* = NULL */); // call in main loop. will call RenderWindow/SwapBuffers platform functions for each secondary viewport which doesn't have the ImGuiViewportFlags_Minimized flag set. May be reimplemented by user for custom rendering needs.
|
CIMGUI_API void ImGui_RenderPlatformWindowsDefaultEx(void* platform_render_arg /* = NULL */, void* renderer_render_arg /* = NULL */); // call in main loop. will call RenderWindow/SwapBuffers platform functions for each secondary viewport which doesn't have the ImGuiViewportFlags_Minimized flag set. May be reimplemented by user for custom rendering needs.
|
||||||
CIMGUI_API void ImGui_DestroyPlatformWindows(void); // call DestroyWindow platform functions for all viewports. call from backend Shutdown() if you need to close platform windows before imgui shutdown. otherwise will be called by DestroyContext().
|
CIMGUI_API void ImGui_DestroyPlatformWindows(void); // call DestroyWindow platform functions for all viewports. call from backend Shutdown() if you need to close platform windows before imgui shutdown. otherwise will be called by DestroyContext().
|
||||||
CIMGUI_API ImGuiViewport* ImGui_FindViewportByID(ImGuiID id); // this is a helper for backends.
|
CIMGUI_API ImGuiViewport* ImGui_FindViewportByID(ImGuiID viewport_id); // this is a helper for backends.
|
||||||
CIMGUI_API ImGuiViewport* ImGui_FindViewportByPlatformHandle(void* platform_handle); // this is a helper for backends. the type platform_handle is decided by the backend (e.g. HWND, MyWindow*, GLFWwindow* etc.)
|
CIMGUI_API ImGuiViewport* ImGui_FindViewportByPlatformHandle(void* platform_handle); // this is a helper for backends. the type platform_handle is decided by the backend (e.g. HWND, MyWindow*, GLFWwindow* etc.)
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
@ -1294,7 +1308,7 @@ typedef enum
|
||||||
ImGuiWindowFlags_AlwaysVerticalScrollbar = 1<<14, // Always show vertical scrollbar (even if ContentSize.y < Size.y)
|
ImGuiWindowFlags_AlwaysVerticalScrollbar = 1<<14, // Always show vertical scrollbar (even if ContentSize.y < Size.y)
|
||||||
ImGuiWindowFlags_AlwaysHorizontalScrollbar = 1<<15, // Always show horizontal scrollbar (even if ContentSize.x < Size.x)
|
ImGuiWindowFlags_AlwaysHorizontalScrollbar = 1<<15, // Always show horizontal scrollbar (even if ContentSize.x < Size.x)
|
||||||
ImGuiWindowFlags_NoNavInputs = 1<<16, // No keyboard/gamepad navigation within the window
|
ImGuiWindowFlags_NoNavInputs = 1<<16, // No keyboard/gamepad navigation within the window
|
||||||
ImGuiWindowFlags_NoNavFocus = 1<<17, // No focusing toward this window with keyboard/gamepad navigation (e.g. skipped by CTRL+TAB)
|
ImGuiWindowFlags_NoNavFocus = 1<<17, // No focusing toward this window with keyboard/gamepad navigation (e.g. skipped by Ctrl+Tab)
|
||||||
ImGuiWindowFlags_UnsavedDocument = 1<<18, // Display a dot next to the title. When used in a tab/docking context, tab is selected when clicking the X + closure is not assumed (will wait for user to stop submitting the tab). Otherwise closure is assumed when pressing the X, so if you keep submitting the tab may reappear at end of tab bar.
|
ImGuiWindowFlags_UnsavedDocument = 1<<18, // Display a dot next to the title. When used in a tab/docking context, tab is selected when clicking the X + closure is not assumed (will wait for user to stop submitting the tab). Otherwise closure is assumed when pressing the X, so if you keep submitting the tab may reappear at end of tab bar.
|
||||||
ImGuiWindowFlags_NoDocking = 1<<19, // Disable docking of this window
|
ImGuiWindowFlags_NoDocking = 1<<19, // Disable docking of this window
|
||||||
ImGuiWindowFlags_NoNav = ImGuiWindowFlags_NoNavInputs | ImGuiWindowFlags_NoNavFocus,
|
ImGuiWindowFlags_NoNav = ImGuiWindowFlags_NoNavInputs | ImGuiWindowFlags_NoNavFocus,
|
||||||
|
|
@ -1308,16 +1322,10 @@ typedef enum
|
||||||
ImGuiWindowFlags_Popup = 1<<26, // Don't use! For internal use by BeginPopup()
|
ImGuiWindowFlags_Popup = 1<<26, // Don't use! For internal use by BeginPopup()
|
||||||
ImGuiWindowFlags_Modal = 1<<27, // Don't use! For internal use by BeginPopupModal()
|
ImGuiWindowFlags_Modal = 1<<27, // Don't use! For internal use by BeginPopupModal()
|
||||||
ImGuiWindowFlags_ChildMenu = 1<<28, // Don't use! For internal use by BeginMenu()
|
ImGuiWindowFlags_ChildMenu = 1<<28, // Don't use! For internal use by BeginMenu()
|
||||||
|
|
||||||
// Obsolete names
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
ImGuiWindowFlags_NavFlattened = 1<<29, // Obsoleted in 1.90.9: Use ImGuiChildFlags_NavFlattened in BeginChild() call.
|
|
||||||
ImGuiWindowFlags_AlwaysUseWindowPadding = 1<<30, // Obsoleted in 1.90.0: Use ImGuiChildFlags_AlwaysUseWindowPadding in BeginChild() call.
|
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
} ImGuiWindowFlags_;
|
} ImGuiWindowFlags_;
|
||||||
|
|
||||||
// Flags for ImGui::BeginChild()
|
// Flags for ImGui::BeginChild()
|
||||||
// (Legacy: bit 0 must always correspond to ImGuiChildFlags_Borders to be backward compatible with old API using 'bool border = false'.
|
// (Legacy: bit 0 must always correspond to ImGuiChildFlags_Borders to be backward compatible with old API using 'bool border = false'.)
|
||||||
// About using AutoResizeX/AutoResizeY flags:
|
// About using AutoResizeX/AutoResizeY flags:
|
||||||
// - May be combined with SetNextWindowSizeConstraints() to set a min/max size for each axis (see "Demo->Child->Auto-resize with Constraints").
|
// - May be combined with SetNextWindowSizeConstraints() to set a min/max size for each axis (see "Demo->Child->Auto-resize with Constraints").
|
||||||
// - Size measurement for a given axis is only performed when the child window is within visible boundaries, or is just appearing.
|
// - Size measurement for a given axis is only performed when the child window is within visible boundaries, or is just appearing.
|
||||||
|
|
@ -1328,20 +1336,15 @@ typedef enum
|
||||||
typedef enum
|
typedef enum
|
||||||
{
|
{
|
||||||
ImGuiChildFlags_None = 0,
|
ImGuiChildFlags_None = 0,
|
||||||
ImGuiChildFlags_Borders = 1<<0, // Show an outer border and enable WindowPadding. (IMPORTANT: this is always == 1 == true for legacy reason)
|
ImGuiChildFlags_Borders = 1<<0, // Show an outer border and enable WindowPadding. (IMPORTANT: this is always == 1 == true for legacy reason)
|
||||||
ImGuiChildFlags_AlwaysUseWindowPadding = 1<<1, // Pad with style.WindowPadding even if no border are drawn (no padding by default for non-bordered child windows because it makes more sense)
|
ImGuiChildFlags_AlwaysUseWindowPadding = 1<<1, // Pad with style.WindowPadding even if no border are drawn (no padding by default for non-bordered child windows because it makes more sense)
|
||||||
ImGuiChildFlags_ResizeX = 1<<2, // Allow resize from right border (layout direction). Enable .ini saving (unless ImGuiWindowFlags_NoSavedSettings passed to window flags)
|
ImGuiChildFlags_ResizeX = 1<<2, // Allow resize from right border (layout direction). Enable .ini saving (unless ImGuiWindowFlags_NoSavedSettings passed to window flags)
|
||||||
ImGuiChildFlags_ResizeY = 1<<3, // Allow resize from bottom border (layout direction). "
|
ImGuiChildFlags_ResizeY = 1<<3, // Allow resize from bottom border (layout direction). "
|
||||||
ImGuiChildFlags_AutoResizeX = 1<<4, // Enable auto-resizing width. Read "IMPORTANT: Size measurement" details above.
|
ImGuiChildFlags_AutoResizeX = 1<<4, // Enable auto-resizing width. Read "IMPORTANT: Size measurement" details above.
|
||||||
ImGuiChildFlags_AutoResizeY = 1<<5, // Enable auto-resizing height. Read "IMPORTANT: Size measurement" details above.
|
ImGuiChildFlags_AutoResizeY = 1<<5, // Enable auto-resizing height. Read "IMPORTANT: Size measurement" details above.
|
||||||
ImGuiChildFlags_AlwaysAutoResize = 1<<6, // Combined with AutoResizeX/AutoResizeY. Always measure size even when child is hidden, always return true, always disable clipping optimization! NOT RECOMMENDED.
|
ImGuiChildFlags_AlwaysAutoResize = 1<<6, // Combined with AutoResizeX/AutoResizeY. Always measure size even when child is hidden, always return true, always disable clipping optimization! NOT RECOMMENDED.
|
||||||
ImGuiChildFlags_FrameStyle = 1<<7, // Style the child window like a framed item: use FrameBg, FrameRounding, FrameBorderSize, FramePadding instead of ChildBg, ChildRounding, ChildBorderSize, WindowPadding.
|
ImGuiChildFlags_FrameStyle = 1<<7, // Style the child window like a framed item: use FrameBg, FrameRounding, FrameBorderSize, FramePadding instead of ChildBg, ChildRounding, ChildBorderSize, WindowPadding.
|
||||||
ImGuiChildFlags_NavFlattened = 1<<8, // [BETA] Share focus scope, allow keyboard/gamepad navigation to cross over parent border to this child or between sibling child windows.
|
ImGuiChildFlags_NavFlattened = 1<<8, // [BETA] Share focus scope, allow keyboard/gamepad navigation to cross over parent border to this child or between sibling child windows.
|
||||||
|
|
||||||
// Obsolete names
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
ImGuiChildFlags_Border = ImGuiChildFlags_Borders, // Renamed in 1.91.1 (August 2024) for consistency.
|
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
} ImGuiChildFlags_;
|
} ImGuiChildFlags_;
|
||||||
|
|
||||||
// Flags for ImGui::PushItemFlag()
|
// Flags for ImGui::PushItemFlag()
|
||||||
|
|
@ -1396,6 +1399,15 @@ typedef enum
|
||||||
ImGuiInputTextFlags_CallbackResize = 1<<22, // Callback on buffer capacity changes request (beyond 'buf_size' parameter value), allowing the string to grow. Notify when the string wants to be resized (for string types which hold a cache of their Size). You will be provided a new BufSize in the callback and NEED to honor it. (see misc/cpp/imgui_stdlib.h for an example of using this)
|
ImGuiInputTextFlags_CallbackResize = 1<<22, // Callback on buffer capacity changes request (beyond 'buf_size' parameter value), allowing the string to grow. Notify when the string wants to be resized (for string types which hold a cache of their Size). You will be provided a new BufSize in the callback and NEED to honor it. (see misc/cpp/imgui_stdlib.h for an example of using this)
|
||||||
ImGuiInputTextFlags_CallbackEdit = 1<<23, // Callback on any edit. Note that InputText() already returns true on edit + you can always use IsItemEdited(). The callback is useful to manipulate the underlying buffer while focus is active.
|
ImGuiInputTextFlags_CallbackEdit = 1<<23, // Callback on any edit. Note that InputText() already returns true on edit + you can always use IsItemEdited(). The callback is useful to manipulate the underlying buffer while focus is active.
|
||||||
|
|
||||||
|
// Multi-line Word-Wrapping [BETA]
|
||||||
|
// - Not well tested yet. Please report any incorrect cursor movement, selection behavior etc. bug to https://github.com/ocornut/imgui/issues/3237.
|
||||||
|
// - Wrapping style is not ideal. Wrapping of long words/sections (e.g. words larger than total available width) may be particularly unpleasing.
|
||||||
|
// - Wrapping width needs to always account for the possibility of a vertical scrollbar.
|
||||||
|
// - It is much slower than regular text fields.
|
||||||
|
// Ballpark estimate of cost on my 2019 desktop PC: for a 100 KB text buffer: +~0.3 ms (Optimized) / +~1.0 ms (Debug build).
|
||||||
|
// The CPU cost is very roughly proportional to text length, so a 10 KB buffer should cost about ten times less.
|
||||||
|
ImGuiInputTextFlags_WordWrap = 1<<24, // InputTextMultiline(): word-wrap lines that are too long.
|
||||||
|
|
||||||
// Obsolete names
|
// Obsolete names
|
||||||
//ImGuiInputTextFlags_AlwaysInsertMode = ImGuiInputTextFlags_AlwaysOverwrite // [renamed in 1.82] name was not matching behavior
|
//ImGuiInputTextFlags_AlwaysInsertMode = ImGuiInputTextFlags_AlwaysOverwrite // [renamed in 1.82] name was not matching behavior
|
||||||
} ImGuiInputTextFlags_;
|
} ImGuiInputTextFlags_;
|
||||||
|
|
@ -1421,7 +1433,7 @@ typedef enum
|
||||||
ImGuiTreeNodeFlags_SpanAllColumns = 1<<14, // Frame will span all columns of its container table (label will still fit in current column)
|
ImGuiTreeNodeFlags_SpanAllColumns = 1<<14, // Frame will span all columns of its container table (label will still fit in current column)
|
||||||
ImGuiTreeNodeFlags_LabelSpanAllColumns = 1<<15, // Label will span all columns of its container table
|
ImGuiTreeNodeFlags_LabelSpanAllColumns = 1<<15, // Label will span all columns of its container table
|
||||||
//ImGuiTreeNodeFlags_NoScrollOnOpen = 1 << 16, // FIXME: TODO: Disable automatic scroll on TreePop() if node got just open and contents is not visible
|
//ImGuiTreeNodeFlags_NoScrollOnOpen = 1 << 16, // FIXME: TODO: Disable automatic scroll on TreePop() if node got just open and contents is not visible
|
||||||
ImGuiTreeNodeFlags_NavLeftJumpsToParent = 1<<17, // Nav: left arrow moves back to parent. This is processed in TreePop() when there's an unfullfilled Left nav request remaining.
|
ImGuiTreeNodeFlags_NavLeftJumpsToParent = 1<<17, // Nav: left arrow moves back to parent. This is processed in TreePop() when there's an unfulfilled Left nav request remaining.
|
||||||
ImGuiTreeNodeFlags_CollapsingHeader = ImGuiTreeNodeFlags_Framed | ImGuiTreeNodeFlags_NoTreePushOnOpen | ImGuiTreeNodeFlags_NoAutoOpenOnLog,
|
ImGuiTreeNodeFlags_CollapsingHeader = ImGuiTreeNodeFlags_Framed | ImGuiTreeNodeFlags_NoTreePushOnOpen | ImGuiTreeNodeFlags_NoAutoOpenOnLog,
|
||||||
|
|
||||||
// [EXPERIMENTAL] Draw lines connecting TreeNode hierarchy. Discuss in GitHub issue #2920.
|
// [EXPERIMENTAL] Draw lines connecting TreeNode hierarchy. Discuss in GitHub issue #2920.
|
||||||
|
|
@ -1433,7 +1445,7 @@ typedef enum
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
ImGuiTreeNodeFlags_NavLeftJumpsBackHere = ImGuiTreeNodeFlags_NavLeftJumpsToParent, // Renamed in 1.92.0
|
ImGuiTreeNodeFlags_NavLeftJumpsBackHere = ImGuiTreeNodeFlags_NavLeftJumpsToParent, // Renamed in 1.92.0
|
||||||
ImGuiTreeNodeFlags_SpanTextWidth = ImGuiTreeNodeFlags_SpanLabelWidth, // Renamed in 1.90.7
|
ImGuiTreeNodeFlags_SpanTextWidth = ImGuiTreeNodeFlags_SpanLabelWidth, // Renamed in 1.90.7
|
||||||
ImGuiTreeNodeFlags_AllowItemOverlap = ImGuiTreeNodeFlags_AllowOverlap, // Renamed in 1.89.7
|
//ImGuiTreeNodeFlags_AllowItemOverlap = ImGuiTreeNodeFlags_AllowOverlap, // Renamed in 1.89.7
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
} ImGuiTreeNodeFlags_;
|
} ImGuiTreeNodeFlags_;
|
||||||
|
|
||||||
|
|
@ -1472,10 +1484,11 @@ typedef enum
|
||||||
ImGuiSelectableFlags_Disabled = 1<<3, // Cannot be selected, display grayed out text
|
ImGuiSelectableFlags_Disabled = 1<<3, // Cannot be selected, display grayed out text
|
||||||
ImGuiSelectableFlags_AllowOverlap = 1<<4, // (WIP) Hit testing to allow subsequent widgets to overlap this one
|
ImGuiSelectableFlags_AllowOverlap = 1<<4, // (WIP) Hit testing to allow subsequent widgets to overlap this one
|
||||||
ImGuiSelectableFlags_Highlight = 1<<5, // Make the item be displayed as if it is hovered
|
ImGuiSelectableFlags_Highlight = 1<<5, // Make the item be displayed as if it is hovered
|
||||||
|
ImGuiSelectableFlags_SelectOnNav = 1<<6, // Auto-select when moved into, unless Ctrl is held. Automatic when in a BeginMultiSelect() block.
|
||||||
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
ImGuiSelectableFlags_DontClosePopups = ImGuiSelectableFlags_NoAutoClosePopups, // Renamed in 1.91.0
|
ImGuiSelectableFlags_DontClosePopups = ImGuiSelectableFlags_NoAutoClosePopups, // Renamed in 1.91.0
|
||||||
ImGuiSelectableFlags_AllowItemOverlap = ImGuiSelectableFlags_AllowOverlap, // Renamed in 1.89.7
|
//ImGuiSelectableFlags_AllowItemOverlap = ImGuiSelectableFlags_AllowOverlap, // Renamed in 1.89.7
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
} ImGuiSelectableFlags_;
|
} ImGuiSelectableFlags_;
|
||||||
|
|
||||||
|
|
@ -1570,7 +1583,7 @@ typedef enum
|
||||||
// Tooltips mode
|
// Tooltips mode
|
||||||
// - typically used in IsItemHovered() + SetTooltip() sequence.
|
// - typically used in IsItemHovered() + SetTooltip() sequence.
|
||||||
// - this is a shortcut to pull flags from 'style.HoverFlagsForTooltipMouse' or 'style.HoverFlagsForTooltipNav' where you can reconfigure desired behavior.
|
// - this is a shortcut to pull flags from 'style.HoverFlagsForTooltipMouse' or 'style.HoverFlagsForTooltipNav' where you can reconfigure desired behavior.
|
||||||
// e.g. 'TooltipHoveredFlagsForMouse' defaults to 'ImGuiHoveredFlags_Stationary | ImGuiHoveredFlags_DelayShort'.
|
// e.g. 'HoverFlagsForTooltipMouse' defaults to 'ImGuiHoveredFlags_Stationary | ImGuiHoveredFlags_DelayShort | ImGuiHoveredFlags_AllowWhenDisabled'.
|
||||||
// - for frequently actioned or hovered items providing a tooltip, you want may to use ImGuiHoveredFlags_ForTooltip (stationary + delay) so the tooltip doesn't show too often.
|
// - for frequently actioned or hovered items providing a tooltip, you want may to use ImGuiHoveredFlags_ForTooltip (stationary + delay) so the tooltip doesn't show too often.
|
||||||
// - for items which main purpose is to be hovered, or items with low affordance, or in less consistent apps, prefer no delay or shorter delay.
|
// - for items which main purpose is to be hovered, or items with low affordance, or in less consistent apps, prefer no delay or shorter delay.
|
||||||
ImGuiHoveredFlags_ForTooltip = 1<<12, // Shortcut for standard flags when using IsItemHovered() + SetTooltip() sequence.
|
ImGuiHoveredFlags_ForTooltip = 1<<12, // Shortcut for standard flags when using IsItemHovered() + SetTooltip() sequence.
|
||||||
|
|
@ -1623,6 +1636,7 @@ typedef enum
|
||||||
ImGuiDragDropFlags_AcceptBeforeDelivery = 1<<10, // AcceptDragDropPayload() will returns true even before the mouse button is released. You can then call IsDelivery() to test if the payload needs to be delivered.
|
ImGuiDragDropFlags_AcceptBeforeDelivery = 1<<10, // AcceptDragDropPayload() will returns true even before the mouse button is released. You can then call IsDelivery() to test if the payload needs to be delivered.
|
||||||
ImGuiDragDropFlags_AcceptNoDrawDefaultRect = 1<<11, // Do not draw the default highlight rectangle when hovering over target.
|
ImGuiDragDropFlags_AcceptNoDrawDefaultRect = 1<<11, // Do not draw the default highlight rectangle when hovering over target.
|
||||||
ImGuiDragDropFlags_AcceptNoPreviewTooltip = 1<<12, // Request hiding the BeginDragDropSource tooltip from the BeginDragDropTarget site.
|
ImGuiDragDropFlags_AcceptNoPreviewTooltip = 1<<12, // Request hiding the BeginDragDropSource tooltip from the BeginDragDropTarget site.
|
||||||
|
ImGuiDragDropFlags_AcceptDrawAsHovered = 1<<13, // Accepting item will render as if hovered. Useful for e.g. a Button() used as a drop target.
|
||||||
ImGuiDragDropFlags_AcceptPeekOnly = ImGuiDragDropFlags_AcceptBeforeDelivery | ImGuiDragDropFlags_AcceptNoDrawDefaultRect, // For peeking ahead and inspecting the payload before delivery.
|
ImGuiDragDropFlags_AcceptPeekOnly = ImGuiDragDropFlags_AcceptBeforeDelivery | ImGuiDragDropFlags_AcceptNoDrawDefaultRect, // For peeking ahead and inspecting the payload before delivery.
|
||||||
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
|
|
@ -1871,12 +1885,9 @@ enum // Forward declared enum
|
||||||
ImGuiMod_Mask_ = 0xF000, // 4-bits
|
ImGuiMod_Mask_ = 0xF000, // 4-bits
|
||||||
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
ImGuiKey_COUNT = ImGuiKey_NamedKey_END, // Obsoleted in 1.91.5 because it was extremely misleading (since named keys don't start at 0 anymore)
|
ImGuiKey_COUNT = ImGuiKey_NamedKey_END, // Obsoleted in 1.91.5 because it was misleading (since named keys don't start at 0 anymore)
|
||||||
ImGuiMod_Shortcut = ImGuiMod_Ctrl, // Removed in 1.90.7, you can now simply use ImGuiMod_Ctrl
|
ImGuiMod_Shortcut = ImGuiMod_Ctrl, // Removed in 1.90.7, you can now simply use ImGuiMod_Ctrl
|
||||||
ImGuiKey_ModCtrl = ImGuiMod_Ctrl,
|
//ImGuiKey_ModCtrl = ImGuiMod_Ctrl, ImGuiKey_ModShift = ImGuiMod_Shift, ImGuiKey_ModAlt = ImGuiMod_Alt, ImGuiKey_ModSuper = ImGuiMod_Super, // Renamed in 1.89
|
||||||
ImGuiKey_ModShift = ImGuiMod_Shift,
|
|
||||||
ImGuiKey_ModAlt = ImGuiMod_Alt,
|
|
||||||
ImGuiKey_ModSuper = ImGuiMod_Super, // Renamed in 1.89
|
|
||||||
//ImGuiKey_KeyPadEnter = ImGuiKey_KeypadEnter, // Renamed in 1.87
|
//ImGuiKey_KeyPadEnter = ImGuiKey_KeypadEnter, // Renamed in 1.87
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
};
|
};
|
||||||
|
|
@ -1898,7 +1909,7 @@ typedef enum
|
||||||
ImGuiInputFlags_RouteAlways = 1<<13, // Do not register route, poll keys directly.
|
ImGuiInputFlags_RouteAlways = 1<<13, // Do not register route, poll keys directly.
|
||||||
// - Routing options
|
// - Routing options
|
||||||
ImGuiInputFlags_RouteOverFocused = 1<<14, // Option: global route: higher priority than focused route (unless active item in focused route).
|
ImGuiInputFlags_RouteOverFocused = 1<<14, // Option: global route: higher priority than focused route (unless active item in focused route).
|
||||||
ImGuiInputFlags_RouteOverActive = 1<<15, // Option: global route: higher priority than active item. Unlikely you need to use that: will interfere with every active items, e.g. CTRL+A registered by InputText will be overridden by this. May not be fully honored as user/internal code is likely to always assume they can access keys when active.
|
ImGuiInputFlags_RouteOverActive = 1<<15, // Option: global route: higher priority than active item. Unlikely you need to use that: will interfere with every active items, e.g. Ctrl+A registered by InputText will be overridden by this. May not be fully honored as user/internal code is likely to always assume they can access keys when active.
|
||||||
ImGuiInputFlags_RouteUnlessBgFocused = 1<<16, // Option: global route: will not be applied if underlying background/void is focused (== no Dear ImGui windows are focused). Useful for overlay applications.
|
ImGuiInputFlags_RouteUnlessBgFocused = 1<<16, // Option: global route: will not be applied if underlying background/void is focused (== no Dear ImGui windows are focused). Useful for overlay applications.
|
||||||
ImGuiInputFlags_RouteFromRootWindow = 1<<17, // Option: route evaluated from the point of view of root window rather than current window.
|
ImGuiInputFlags_RouteFromRootWindow = 1<<17, // Option: route evaluated from the point of view of root window rather than current window.
|
||||||
|
|
||||||
|
|
@ -1945,10 +1956,11 @@ typedef enum
|
||||||
ImGuiBackendFlags_RendererHasVtxOffset = 1<<3, // Backend Renderer supports ImDrawCmd::VtxOffset. This enables output of large meshes (64K+ vertices) while still using 16-bit indices.
|
ImGuiBackendFlags_RendererHasVtxOffset = 1<<3, // Backend Renderer supports ImDrawCmd::VtxOffset. This enables output of large meshes (64K+ vertices) while still using 16-bit indices.
|
||||||
ImGuiBackendFlags_RendererHasTextures = 1<<4, // Backend Renderer supports ImTextureData requests to create/update/destroy textures. This enables incremental texture updates and texture reloads. See https://github.com/ocornut/imgui/blob/master/docs/BACKENDS.md for instructions on how to upgrade your custom backend.
|
ImGuiBackendFlags_RendererHasTextures = 1<<4, // Backend Renderer supports ImTextureData requests to create/update/destroy textures. This enables incremental texture updates and texture reloads. See https://github.com/ocornut/imgui/blob/master/docs/BACKENDS.md for instructions on how to upgrade your custom backend.
|
||||||
|
|
||||||
// [BETA] Viewports
|
// [BETA] Multi-Viewports
|
||||||
ImGuiBackendFlags_PlatformHasViewports = 1<<10, // Backend Platform supports multiple viewports.
|
ImGuiBackendFlags_RendererHasViewports = 1<<10, // Backend Renderer supports multiple viewports.
|
||||||
ImGuiBackendFlags_HasMouseHoveredViewport = 1<<11, // Backend Platform supports calling io.AddMouseViewportEvent() with the viewport under the mouse. IF POSSIBLE, ignore viewports with the ImGuiViewportFlags_NoInputs flag (Win32 backend, GLFW 3.30+ backend can do this, SDL backend cannot). If this cannot be done, Dear ImGui needs to use a flawed heuristic to find the viewport under.
|
ImGuiBackendFlags_PlatformHasViewports = 1<<11, // Backend Platform supports multiple viewports.
|
||||||
ImGuiBackendFlags_RendererHasViewports = 1<<12, // Backend Renderer supports multiple viewports.
|
ImGuiBackendFlags_HasMouseHoveredViewport = 1<<12, // Backend Platform supports calling io.AddMouseViewportEvent() with the viewport under the mouse. IF POSSIBLE, ignore viewports with the ImGuiViewportFlags_NoInputs flag (Win32 backend, GLFW 3.30+ backend can do this, SDL backend cannot). If this cannot be done, Dear ImGui needs to use a flawed heuristic to find the viewport under.
|
||||||
|
ImGuiBackendFlags_HasParentViewport = 1<<13, // Backend Platform supports honoring viewport->ParentViewport/ParentViewportId value, by applying the corresponding parent/child relation at the Platform level.
|
||||||
} ImGuiBackendFlags_;
|
} ImGuiBackendFlags_;
|
||||||
|
|
||||||
// Enumeration for PushStyleColor() / PopStyleColor()
|
// Enumeration for PushStyleColor() / PopStyleColor()
|
||||||
|
|
@ -2009,10 +2021,12 @@ typedef enum
|
||||||
ImGuiCol_TextLink, // Hyperlink color
|
ImGuiCol_TextLink, // Hyperlink color
|
||||||
ImGuiCol_TextSelectedBg, // Selected text inside an InputText
|
ImGuiCol_TextSelectedBg, // Selected text inside an InputText
|
||||||
ImGuiCol_TreeLines, // Tree node hierarchy outlines when using ImGuiTreeNodeFlags_DrawLines
|
ImGuiCol_TreeLines, // Tree node hierarchy outlines when using ImGuiTreeNodeFlags_DrawLines
|
||||||
ImGuiCol_DragDropTarget, // Rectangle highlighting a drop target
|
ImGuiCol_DragDropTarget, // Rectangle border highlighting a drop target
|
||||||
|
ImGuiCol_DragDropTargetBg, // Rectangle background highlighting a drop target
|
||||||
|
ImGuiCol_UnsavedMarker, // Unsaved Document marker (in window title and tabs)
|
||||||
ImGuiCol_NavCursor, // Color of keyboard/gamepad navigation cursor/rectangle, when visible
|
ImGuiCol_NavCursor, // Color of keyboard/gamepad navigation cursor/rectangle, when visible
|
||||||
ImGuiCol_NavWindowingHighlight, // Highlight window when using CTRL+TAB
|
ImGuiCol_NavWindowingHighlight, // Highlight window when using Ctrl+Tab
|
||||||
ImGuiCol_NavWindowingDimBg, // Darken/colorize entire screen behind the CTRL+TAB window list, when active
|
ImGuiCol_NavWindowingDimBg, // Darken/colorize entire screen behind the Ctrl+Tab window list, when active
|
||||||
ImGuiCol_ModalWindowDimBg, // Darken/colorize entire screen behind a modal window, when one is active
|
ImGuiCol_ModalWindowDimBg, // Darken/colorize entire screen behind a modal window, when one is active
|
||||||
ImGuiCol_COUNT,
|
ImGuiCol_COUNT,
|
||||||
|
|
||||||
|
|
@ -2028,9 +2042,9 @@ typedef enum
|
||||||
// - The enum only refers to fields of ImGuiStyle which makes sense to be pushed/popped inside UI code.
|
// - The enum only refers to fields of ImGuiStyle which makes sense to be pushed/popped inside UI code.
|
||||||
// During initialization or between frames, feel free to just poke into ImGuiStyle directly.
|
// During initialization or between frames, feel free to just poke into ImGuiStyle directly.
|
||||||
// - Tip: Use your programming IDE navigation facilities on the names in the _second column_ below to find the actual members and their description.
|
// - Tip: Use your programming IDE navigation facilities on the names in the _second column_ below to find the actual members and their description.
|
||||||
// - In Visual Studio: CTRL+comma ("Edit.GoToAll") can follow symbols inside comments, whereas CTRL+F12 ("Edit.GoToImplementation") cannot.
|
// - In Visual Studio: Ctrl+Comma ("Edit.GoToAll") can follow symbols inside comments, whereas Ctrl+F12 ("Edit.GoToImplementation") cannot.
|
||||||
// - In Visual Studio w/ Visual Assist installed: ALT+G ("VAssistX.GoToImplementation") can also follow symbols inside comments.
|
// - In Visual Studio w/ Visual Assist installed: Alt+G ("VAssistX.GoToImplementation") can also follow symbols inside comments.
|
||||||
// - In VS Code, CLion, etc.: CTRL+click can follow symbols inside comments.
|
// - In VS Code, CLion, etc.: Ctrl+Click can follow symbols inside comments.
|
||||||
// - When changing this enum, you need to update the associated internal table GStyleVarInfo[] accordingly. This is where we link enum values to members offset/type.
|
// - When changing this enum, you need to update the associated internal table GStyleVarInfo[] accordingly. This is where we link enum values to members offset/type.
|
||||||
typedef enum
|
typedef enum
|
||||||
{
|
{
|
||||||
|
|
@ -2055,6 +2069,7 @@ typedef enum
|
||||||
ImGuiStyleVar_CellPadding, // ImVec2 CellPadding
|
ImGuiStyleVar_CellPadding, // ImVec2 CellPadding
|
||||||
ImGuiStyleVar_ScrollbarSize, // float ScrollbarSize
|
ImGuiStyleVar_ScrollbarSize, // float ScrollbarSize
|
||||||
ImGuiStyleVar_ScrollbarRounding, // float ScrollbarRounding
|
ImGuiStyleVar_ScrollbarRounding, // float ScrollbarRounding
|
||||||
|
ImGuiStyleVar_ScrollbarPadding, // float ScrollbarPadding
|
||||||
ImGuiStyleVar_GrabMinSize, // float GrabMinSize
|
ImGuiStyleVar_GrabMinSize, // float GrabMinSize
|
||||||
ImGuiStyleVar_GrabRounding, // float GrabRounding
|
ImGuiStyleVar_GrabRounding, // float GrabRounding
|
||||||
ImGuiStyleVar_ImageBorderSize, // float ImageBorderSize
|
ImGuiStyleVar_ImageBorderSize, // float ImageBorderSize
|
||||||
|
|
@ -2137,7 +2152,7 @@ typedef enum
|
||||||
|
|
||||||
// Obsolete names
|
// Obsolete names
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
ImGuiColorEditFlags_AlphaPreview = 0, // [Removed in 1.91.8] This is the default now. Will display a checkerboard unless ImGuiColorEditFlags_AlphaNoBg is set.
|
ImGuiColorEditFlags_AlphaPreview = 0, // Removed in 1.91.8. This is the default now. Will display a checkerboard unless ImGuiColorEditFlags_AlphaNoBg is set.
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
//ImGuiColorEditFlags_RGB = ImGuiColorEditFlags_DisplayRGB, ImGuiColorEditFlags_HSV = ImGuiColorEditFlags_DisplayHSV, ImGuiColorEditFlags_HEX = ImGuiColorEditFlags_DisplayHex // [renamed in 1.69]
|
//ImGuiColorEditFlags_RGB = ImGuiColorEditFlags_DisplayRGB, ImGuiColorEditFlags_HSV = ImGuiColorEditFlags_DisplayHSV, ImGuiColorEditFlags_HEX = ImGuiColorEditFlags_DisplayHex // [renamed in 1.69]
|
||||||
} ImGuiColorEditFlags_;
|
} ImGuiColorEditFlags_;
|
||||||
|
|
@ -2150,9 +2165,9 @@ typedef enum
|
||||||
ImGuiSliderFlags_None = 0,
|
ImGuiSliderFlags_None = 0,
|
||||||
ImGuiSliderFlags_Logarithmic = 1<<5, // Make the widget logarithmic (linear otherwise). Consider using ImGuiSliderFlags_NoRoundToFormat with this if using a format-string with small amount of digits.
|
ImGuiSliderFlags_Logarithmic = 1<<5, // Make the widget logarithmic (linear otherwise). Consider using ImGuiSliderFlags_NoRoundToFormat with this if using a format-string with small amount of digits.
|
||||||
ImGuiSliderFlags_NoRoundToFormat = 1<<6, // Disable rounding underlying value to match precision of the display format string (e.g. %.3f values are rounded to those 3 digits).
|
ImGuiSliderFlags_NoRoundToFormat = 1<<6, // Disable rounding underlying value to match precision of the display format string (e.g. %.3f values are rounded to those 3 digits).
|
||||||
ImGuiSliderFlags_NoInput = 1<<7, // Disable CTRL+Click or Enter key allowing to input text directly into the widget.
|
ImGuiSliderFlags_NoInput = 1<<7, // Disable Ctrl+Click or Enter key allowing to input text directly into the widget.
|
||||||
ImGuiSliderFlags_WrapAround = 1<<8, // Enable wrapping around from max to min and from min to max. Only supported by DragXXX() functions for now.
|
ImGuiSliderFlags_WrapAround = 1<<8, // Enable wrapping around from max to min and from min to max. Only supported by DragXXX() functions for now.
|
||||||
ImGuiSliderFlags_ClampOnInput = 1<<9, // Clamp value to min/max bounds when input manually with CTRL+Click. By default CTRL+Click allows going out of bounds.
|
ImGuiSliderFlags_ClampOnInput = 1<<9, // Clamp value to min/max bounds when input manually with Ctrl+Click. By default Ctrl+Click allows going out of bounds.
|
||||||
ImGuiSliderFlags_ClampZeroRange = 1<<10, // Clamp even if min==max==0.0f. Otherwise due to legacy reason DragXXX functions don't clamp with those values. When your clamping limits are dynamic you almost always want to use it.
|
ImGuiSliderFlags_ClampZeroRange = 1<<10, // Clamp even if min==max==0.0f. Otherwise due to legacy reason DragXXX functions don't clamp with those values. When your clamping limits are dynamic you almost always want to use it.
|
||||||
ImGuiSliderFlags_NoSpeedTweaks = 1<<11, // Disable keyboard modifiers altering tweak speed. Useful if you want to alter tweak speed yourself based on your own logic.
|
ImGuiSliderFlags_NoSpeedTweaks = 1<<11, // Disable keyboard modifiers altering tweak speed. Useful if you want to alter tweak speed yourself based on your own logic.
|
||||||
ImGuiSliderFlags_AlwaysClamp = ImGuiSliderFlags_ClampOnInput | ImGuiSliderFlags_ClampZeroRange,
|
ImGuiSliderFlags_AlwaysClamp = ImGuiSliderFlags_ClampOnInput | ImGuiSliderFlags_ClampZeroRange,
|
||||||
|
|
@ -2491,6 +2506,7 @@ struct ImGuiStyle_t
|
||||||
float ColumnsMinSpacing; // Minimum horizontal spacing between two columns. Preferably > (FramePadding.x + 1).
|
float ColumnsMinSpacing; // Minimum horizontal spacing between two columns. Preferably > (FramePadding.x + 1).
|
||||||
float ScrollbarSize; // Width of the vertical scrollbar, Height of the horizontal scrollbar.
|
float ScrollbarSize; // Width of the vertical scrollbar, Height of the horizontal scrollbar.
|
||||||
float ScrollbarRounding; // Radius of grab corners for scrollbar.
|
float ScrollbarRounding; // Radius of grab corners for scrollbar.
|
||||||
|
float ScrollbarPadding; // Padding of scrollbar grab within its frame (same for both axes).
|
||||||
float GrabMinSize; // Minimum width/height of a grab box for slider/scrollbar.
|
float GrabMinSize; // Minimum width/height of a grab box for slider/scrollbar.
|
||||||
float GrabRounding; // Radius of grabs corners rounding. Set to 0.0f to have rectangular slider grabs.
|
float GrabRounding; // Radius of grabs corners rounding. Set to 0.0f to have rectangular slider grabs.
|
||||||
float LogSliderDeadzone; // The size in pixels of the dead-zone around zero on logarithmic sliders that cross zero.
|
float LogSliderDeadzone; // The size in pixels of the dead-zone around zero on logarithmic sliders that cross zero.
|
||||||
|
|
@ -2508,6 +2524,9 @@ struct ImGuiStyle_t
|
||||||
ImGuiTreeNodeFlags TreeLinesFlags; // Default way to draw lines connecting TreeNode hierarchy. ImGuiTreeNodeFlags_DrawLinesNone or ImGuiTreeNodeFlags_DrawLinesFull or ImGuiTreeNodeFlags_DrawLinesToNodes.
|
ImGuiTreeNodeFlags TreeLinesFlags; // Default way to draw lines connecting TreeNode hierarchy. ImGuiTreeNodeFlags_DrawLinesNone or ImGuiTreeNodeFlags_DrawLinesFull or ImGuiTreeNodeFlags_DrawLinesToNodes.
|
||||||
float TreeLinesSize; // Thickness of outlines when using ImGuiTreeNodeFlags_DrawLines.
|
float TreeLinesSize; // Thickness of outlines when using ImGuiTreeNodeFlags_DrawLines.
|
||||||
float TreeLinesRounding; // Radius of lines connecting child nodes to the vertical line.
|
float TreeLinesRounding; // Radius of lines connecting child nodes to the vertical line.
|
||||||
|
float DragDropTargetRounding; // Radius of the drag and drop target frame.
|
||||||
|
float DragDropTargetBorderSize; // Thickness of the drag and drop target border.
|
||||||
|
float DragDropTargetPadding; // Size to expand the drag and drop target from actual target item size.
|
||||||
ImGuiDir ColorButtonPosition; // Side of the color button in the ColorEdit4 widget (left/right). Defaults to ImGuiDir_Right.
|
ImGuiDir ColorButtonPosition; // Side of the color button in the ColorEdit4 widget (left/right). Defaults to ImGuiDir_Right.
|
||||||
ImVec2 ButtonTextAlign; // Alignment of button text when button is larger than text. Defaults to (0.5f, 0.5f) (centered).
|
ImVec2 ButtonTextAlign; // Alignment of button text when button is larger than text. Defaults to (0.5f, 0.5f) (centered).
|
||||||
ImVec2 SelectableTextAlign; // Alignment of selectable text. Defaults to (0.0f, 0.0f) (top-left aligned). It's generally important to keep this left-aligned if you want to lay multiple items on a same line.
|
ImVec2 SelectableTextAlign; // Alignment of selectable text. Defaults to (0.0f, 0.0f) (top-left aligned). It's generally important to keep this left-aligned if you want to lay multiple items on a same line.
|
||||||
|
|
@ -2516,6 +2535,7 @@ struct ImGuiStyle_t
|
||||||
ImVec2 SeparatorTextPadding; // Horizontal offset of text from each edge of the separator + spacing on other axis. Generally small values. .y is recommended to be == FramePadding.y.
|
ImVec2 SeparatorTextPadding; // Horizontal offset of text from each edge of the separator + spacing on other axis. Generally small values. .y is recommended to be == FramePadding.y.
|
||||||
ImVec2 DisplayWindowPadding; // Apply to regular windows: amount which we enforce to keep visible when moving near edges of your screen.
|
ImVec2 DisplayWindowPadding; // Apply to regular windows: amount which we enforce to keep visible when moving near edges of your screen.
|
||||||
ImVec2 DisplaySafeAreaPadding; // Apply to every windows, menus, popups, tooltips: amount where we avoid displaying contents. Adjust if you cannot see the edges of your screen (e.g. on a TV where scaling has not been configured).
|
ImVec2 DisplaySafeAreaPadding; // Apply to every windows, menus, popups, tooltips: amount where we avoid displaying contents. Adjust if you cannot see the edges of your screen (e.g. on a TV where scaling has not been configured).
|
||||||
|
bool DockingNodeHasCloseButton; // Docking node has their own CloseButton() to close all docked windows.
|
||||||
float DockingSeparatorSize; // Thickness of resizing border between docked windows
|
float DockingSeparatorSize; // Thickness of resizing border between docked windows
|
||||||
float MouseCursorScale; // Scale software rendered mouse cursor (when io.MouseDrawCursor is enabled). We apply per-monitor DPI scaling over this scale. May be removed later.
|
float MouseCursorScale; // Scale software rendered mouse cursor (when io.MouseDrawCursor is enabled). We apply per-monitor DPI scaling over this scale. May be removed later.
|
||||||
bool AntiAliasedLines; // Enable anti-aliased lines/borders. Disable if you are really tight on CPU/GPU. Latched at the beginning of the frame (copied to ImDrawList).
|
bool AntiAliasedLines; // Enable anti-aliased lines/borders. Disable if you are really tight on CPU/GPU. Latched at the beginning of the frame (copied to ImDrawList).
|
||||||
|
|
@ -2582,7 +2602,7 @@ struct ImGuiIO_t
|
||||||
// Font system
|
// Font system
|
||||||
ImFontAtlas* Fonts; // <auto> // Font atlas: load, rasterize and pack one or more fonts into a single texture.
|
ImFontAtlas* Fonts; // <auto> // Font atlas: load, rasterize and pack one or more fonts into a single texture.
|
||||||
ImFont* FontDefault; // = NULL // Font to use on NewFrame(). Use NULL to uses Fonts->Fonts[0].
|
ImFont* FontDefault; // = NULL // Font to use on NewFrame(). Use NULL to uses Fonts->Fonts[0].
|
||||||
bool FontAllowUserScaling; // = false // [OBSOLETE] Allow user scaling text of individual window with CTRL+Wheel.
|
bool FontAllowUserScaling; // = false // Allow user scaling text of individual window with Ctrl+Wheel.
|
||||||
|
|
||||||
// Keyboard/Gamepad Navigation options
|
// Keyboard/Gamepad Navigation options
|
||||||
bool ConfigNavSwapGamepadButtons; // = false // Swap Activate<>Cancel (A<>B) buttons, matching typical "Nintendo/Japanese style" gamepad layout.
|
bool ConfigNavSwapGamepadButtons; // = false // Swap Activate<>Cancel (A<>B) buttons, matching typical "Nintendo/Japanese style" gamepad layout.
|
||||||
|
|
@ -2595,6 +2615,7 @@ struct ImGuiIO_t
|
||||||
|
|
||||||
// Docking options (when ImGuiConfigFlags_DockingEnable is set)
|
// Docking options (when ImGuiConfigFlags_DockingEnable is set)
|
||||||
bool ConfigDockingNoSplit; // = false // Simplified docking mode: disable window splitting, so docking is limited to merging multiple windows together into tab-bars.
|
bool ConfigDockingNoSplit; // = false // Simplified docking mode: disable window splitting, so docking is limited to merging multiple windows together into tab-bars.
|
||||||
|
bool ConfigDockingNoDockingOver; // = false // Simplified docking mode: disable window merging into a same tab-bar, so docking is limited to splitting windows.
|
||||||
bool ConfigDockingWithShift; // = false // Enable docking with holding Shift key (reduce visual noise, allows dropping in wider space)
|
bool ConfigDockingWithShift; // = false // Enable docking with holding Shift key (reduce visual noise, allows dropping in wider space)
|
||||||
bool ConfigDockingAlwaysTabBar; // = false // [BETA] [FIXME: This currently creates regression with auto-sizing and general overhead] Make every single floating window display within a docking node.
|
bool ConfigDockingAlwaysTabBar; // = false // [BETA] [FIXME: This currently creates regression with auto-sizing and general overhead] Make every single floating window display within a docking node.
|
||||||
bool ConfigDockingTransparentPayload; // = false // [BETA] Make window or viewport transparent when docking and only display docking boxes on the target viewport. Useful if rendering of multiple viewport cannot be synced. Best used with ConfigViewportsNoAutoMerge.
|
bool ConfigDockingTransparentPayload; // = false // [BETA] Make window or viewport transparent when docking and only display docking boxes on the target viewport. Useful if rendering of multiple viewport cannot be synced. Best used with ConfigViewportsNoAutoMerge.
|
||||||
|
|
@ -2603,8 +2624,8 @@ struct ImGuiIO_t
|
||||||
bool ConfigViewportsNoAutoMerge; // = false; // Set to make all floating imgui windows always create their own viewport. Otherwise, they are merged into the main host viewports when overlapping it. May also set ImGuiViewportFlags_NoAutoMerge on individual viewport.
|
bool ConfigViewportsNoAutoMerge; // = false; // Set to make all floating imgui windows always create their own viewport. Otherwise, they are merged into the main host viewports when overlapping it. May also set ImGuiViewportFlags_NoAutoMerge on individual viewport.
|
||||||
bool ConfigViewportsNoTaskBarIcon; // = false // Disable default OS task bar icon flag for secondary viewports. When a viewport doesn't want a task bar icon, ImGuiViewportFlags_NoTaskBarIcon will be set on it.
|
bool ConfigViewportsNoTaskBarIcon; // = false // Disable default OS task bar icon flag for secondary viewports. When a viewport doesn't want a task bar icon, ImGuiViewportFlags_NoTaskBarIcon will be set on it.
|
||||||
bool ConfigViewportsNoDecoration; // = true // Disable default OS window decoration flag for secondary viewports. When a viewport doesn't want window decorations, ImGuiViewportFlags_NoDecoration will be set on it. Enabling decoration can create subsequent issues at OS levels (e.g. minimum window size).
|
bool ConfigViewportsNoDecoration; // = true // Disable default OS window decoration flag for secondary viewports. When a viewport doesn't want window decorations, ImGuiViewportFlags_NoDecoration will be set on it. Enabling decoration can create subsequent issues at OS levels (e.g. minimum window size).
|
||||||
bool ConfigViewportsNoDefaultParent; // = false // Disable default OS parenting to main viewport for secondary viewports. By default, viewports are marked with ParentViewportId = <main_viewport>, expecting the platform backend to setup a parent/child relationship between the OS windows (some backend may ignore this). Set to true if you want the default to be 0, then all viewports will be top-level OS windows.
|
bool ConfigViewportsNoDefaultParent; // = true // When false: set secondary viewports' ParentViewportId to main viewport ID by default. Expects the platform backend to setup a parent/child relationship between the OS windows based on this value. Some backend may ignore this. Set to true if you want viewports to automatically be parent of main viewport, otherwise all viewports will be top-level OS windows.
|
||||||
bool ConfigViewportPlatformFocusSetsImGuiFocus; //= true // When a platform window is focused (e.g. using Alt+Tab, clicking Platform Title Bar), apply corresponding focus on imgui windows (may clear focus/active id from imgui windows location in other platform windows). In principle this is better enabled but we provide an opt-out, because some Linux window managers tend to eagerly focus windows (e.g. on mouse hover, or even a simple window pos/size change).
|
bool ConfigViewportsPlatformFocusSetsImGuiFocus; //= true // When a platform window is focused (e.g. using Alt+Tab, clicking Platform Title Bar), apply corresponding focus on imgui windows (may clear focus/active id from imgui windows location in other platform windows). In principle this is better enabled but we provide an opt-out, because some Linux window managers tend to eagerly focus windows (e.g. on mouse hover, or even a simple window pos/size change).
|
||||||
|
|
||||||
// DPI/Scaling options
|
// DPI/Scaling options
|
||||||
// This may keep evolving during 1.92.x releases. Expect some turbulence.
|
// This may keep evolving during 1.92.x releases. Expect some turbulence.
|
||||||
|
|
@ -2621,7 +2642,7 @@ struct ImGuiIO_t
|
||||||
bool ConfigDragClickToInputText; // = false // [BETA] Enable turning DragXXX widgets into text input with a simple mouse click-release (without moving). Not desirable on devices without a keyboard.
|
bool ConfigDragClickToInputText; // = false // [BETA] Enable turning DragXXX widgets into text input with a simple mouse click-release (without moving). Not desirable on devices without a keyboard.
|
||||||
bool ConfigWindowsResizeFromEdges; // = true // Enable resizing of windows from their edges and from the lower-left corner. This requires ImGuiBackendFlags_HasMouseCursors for better mouse cursor feedback. (This used to be a per-window ImGuiWindowFlags_ResizeFromAnySide flag)
|
bool ConfigWindowsResizeFromEdges; // = true // Enable resizing of windows from their edges and from the lower-left corner. This requires ImGuiBackendFlags_HasMouseCursors for better mouse cursor feedback. (This used to be a per-window ImGuiWindowFlags_ResizeFromAnySide flag)
|
||||||
bool ConfigWindowsMoveFromTitleBarOnly; // = false // Enable allowing to move windows only when clicking on their title bar. Does not apply to windows without a title bar.
|
bool ConfigWindowsMoveFromTitleBarOnly; // = false // Enable allowing to move windows only when clicking on their title bar. Does not apply to windows without a title bar.
|
||||||
bool ConfigWindowsCopyContentsWithCtrlC; // = false // [EXPERIMENTAL] CTRL+C copy the contents of focused window into the clipboard. Experimental because: (1) has known issues with nested Begin/End pairs (2) text output quality varies (3) text output is in submission order rather than spatial order.
|
bool ConfigWindowsCopyContentsWithCtrlC; // = false // [EXPERIMENTAL] Ctrl+C copy the contents of focused window into the clipboard. Experimental because: (1) has known issues with nested Begin/End pairs (2) text output quality varies (3) text output is in submission order rather than spatial order.
|
||||||
bool ConfigScrollbarScrollByPage; // = true // Enable scrolling page by page when clicking outside the scrollbar grab. When disabled, always scroll to clicked location. When enabled, Shift+Click scrolls to clicked location.
|
bool ConfigScrollbarScrollByPage; // = true // Enable scrolling page by page when clicking outside the scrollbar grab. When disabled, always scroll to clicked location. When enabled, Shift+Click scrolls to clicked location.
|
||||||
float ConfigMemoryCompactTimer; // = 60.0f // Timer (in seconds) to free transient windows/tables memory buffers when unused. Set to -1.0f to disable.
|
float ConfigMemoryCompactTimer; // = 60.0f // Timer (in seconds) to free transient windows/tables memory buffers when unused. Set to -1.0f to disable.
|
||||||
|
|
||||||
|
|
@ -2659,7 +2680,7 @@ struct ImGuiIO_t
|
||||||
// Option to enable various debug tools showing buttons that will call the IM_DEBUG_BREAK() macro.
|
// Option to enable various debug tools showing buttons that will call the IM_DEBUG_BREAK() macro.
|
||||||
// - The Item Picker tool will be available regardless of this being enabled, in order to maximize its discoverability.
|
// - The Item Picker tool will be available regardless of this being enabled, in order to maximize its discoverability.
|
||||||
// - Requires a debugger being attached, otherwise IM_DEBUG_BREAK() options will appear to crash your application.
|
// - Requires a debugger being attached, otherwise IM_DEBUG_BREAK() options will appear to crash your application.
|
||||||
// e.g. io.ConfigDebugIsDebuggerPresent = ::IsDebuggerPresent() on Win32, or refer to ImOsIsDebuggerPresent() imgui_test_engine/imgui_te_utils.cpp for a Unix compatible version).
|
// e.g. io.ConfigDebugIsDebuggerPresent = ::IsDebuggerPresent() on Win32, or refer to ImOsIsDebuggerPresent() imgui_test_engine/imgui_te_utils.cpp for a Unix compatible version.
|
||||||
bool ConfigDebugIsDebuggerPresent; // = false // Enable various tools calling IM_DEBUG_BREAK().
|
bool ConfigDebugIsDebuggerPresent; // = false // Enable various tools calling IM_DEBUG_BREAK().
|
||||||
|
|
||||||
// Tools to detect code submitting items with conflicting/duplicate IDs
|
// Tools to detect code submitting items with conflicting/duplicate IDs
|
||||||
|
|
@ -2732,7 +2753,7 @@ struct ImGuiIO_t
|
||||||
// (reading from those variables is fair game, as they are extremely unlikely to be moving anywhere)
|
// (reading from those variables is fair game, as they are extremely unlikely to be moving anywhere)
|
||||||
ImVec2 MousePos; // Mouse position, in pixels. Set to ImVec2(-FLT_MAX, -FLT_MAX) if mouse is unavailable (on another screen, etc.)
|
ImVec2 MousePos; // Mouse position, in pixels. Set to ImVec2(-FLT_MAX, -FLT_MAX) if mouse is unavailable (on another screen, etc.)
|
||||||
bool MouseDown[5]; // Mouse buttons: 0=left, 1=right, 2=middle + extras (ImGuiMouseButton_COUNT == 5). Dear ImGui mostly uses left and right buttons. Other buttons allow us to track if the mouse is being used by your application + available to user as a convenience via IsMouse** API.
|
bool MouseDown[5]; // Mouse buttons: 0=left, 1=right, 2=middle + extras (ImGuiMouseButton_COUNT == 5). Dear ImGui mostly uses left and right buttons. Other buttons allow us to track if the mouse is being used by your application + available to user as a convenience via IsMouse** API.
|
||||||
float MouseWheel; // Mouse wheel Vertical: 1 unit scrolls about 5 lines text. >0 scrolls Up, <0 scrolls Down. Hold SHIFT to turn vertical scroll into horizontal scroll.
|
float MouseWheel; // Mouse wheel Vertical: 1 unit scrolls about 5 lines text. >0 scrolls Up, <0 scrolls Down. Hold Shift to turn vertical scroll into horizontal scroll.
|
||||||
float MouseWheelH; // Mouse wheel Horizontal. >0 scrolls Left, <0 scrolls Right. Most users don't have a mouse with a horizontal wheel, may not be filled by all backends.
|
float MouseWheelH; // Mouse wheel Horizontal. >0 scrolls Left, <0 scrolls Right. Most users don't have a mouse with a horizontal wheel, may not be filled by all backends.
|
||||||
ImGuiMouseSource MouseSource; // Mouse actual input peripheral (Mouse/TouchScreen/Pen).
|
ImGuiMouseSource MouseSource; // Mouse actual input peripheral (Mouse/TouchScreen/Pen).
|
||||||
ImGuiID MouseHoveredViewport; // (Optional) Modify using io.AddMouseViewportEvent(). With multi-viewports: viewport the OS mouse is hovering. If possible _IGNORING_ viewports with the ImGuiViewportFlags_NoInputs flag is much better (few backends can handle that). Set io.BackendFlags |= ImGuiBackendFlags_HasMouseHoveredViewport if you can provide this info. If you don't imgui will infer the value using the rectangles and last focused time of the viewports it knows about (ignoring other OS windows).
|
ImGuiID MouseHoveredViewport; // (Optional) Modify using io.AddMouseViewportEvent(). With multi-viewports: viewport the OS mouse is hovering. If possible _IGNORING_ viewports with the ImGuiViewportFlags_NoInputs flag is much better (few backends can handle that). Set io.BackendFlags |= ImGuiBackendFlags_HasMouseHoveredViewport if you can provide this info. If you don't imgui will infer the value using the rectangles and last focused time of the viewports it knows about (ignoring other OS windows).
|
||||||
|
|
@ -2742,7 +2763,7 @@ struct ImGuiIO_t
|
||||||
bool KeySuper; // Keyboard modifier down: Windows/Super (non-macOS), Ctrl (macOS)
|
bool KeySuper; // Keyboard modifier down: Windows/Super (non-macOS), Ctrl (macOS)
|
||||||
|
|
||||||
// Other state maintained from data above + IO function calls
|
// Other state maintained from data above + IO function calls
|
||||||
ImGuiKeyChord KeyMods; // Key mods flags (any of ImGuiMod_Ctrl/ImGuiMod_Shift/ImGuiMod_Alt/ImGuiMod_Super flags, same as io.KeyCtrl/KeyShift/KeyAlt/KeySuper but merged into flags. Read-only, updated by NewFrame()
|
ImGuiKeyChord KeyMods; // Key mods flags (any of ImGuiMod_Ctrl/ImGuiMod_Shift/ImGuiMod_Alt/ImGuiMod_Super flags, same as io.KeyCtrl/KeyShift/KeyAlt/KeySuper but merged into flags). Read-only, updated by NewFrame()
|
||||||
ImGuiKeyData KeysData[ImGuiKey_NamedKey_COUNT]; // Key state for all known keys. MUST use 'key - ImGuiKey_NamedKey_BEGIN' as index. Use IsKeyXXX() functions to access this.
|
ImGuiKeyData KeysData[ImGuiKey_NamedKey_COUNT]; // Key state for all known keys. MUST use 'key - ImGuiKey_NamedKey_BEGIN' as index. Use IsKeyXXX() functions to access this.
|
||||||
bool WantCaptureMouseUnlessPopupClose; // Alternative to WantCaptureMouse: (WantCaptureMouse == true && WantCaptureMouseUnlessPopupClose == false) when a click over void is expected to close a popup.
|
bool WantCaptureMouseUnlessPopupClose; // Alternative to WantCaptureMouse: (WantCaptureMouse == true && WantCaptureMouseUnlessPopupClose == false) when a click over void is expected to close a popup.
|
||||||
ImVec2 MousePosPrev; // Previous mouse position (note that MouseDelta is not necessary == MousePos-MousePosPrev, in case either position is invalid)
|
ImVec2 MousePosPrev; // Previous mouse position (note that MouseDelta is not necessary == MousePos-MousePosPrev, in case either position is invalid)
|
||||||
|
|
@ -2756,8 +2777,8 @@ struct ImGuiIO_t
|
||||||
double MouseReleasedTime[5]; // Time of last released (rarely used! but useful to handle delayed single-click when trying to disambiguate them from double-click).
|
double MouseReleasedTime[5]; // Time of last released (rarely used! but useful to handle delayed single-click when trying to disambiguate them from double-click).
|
||||||
bool MouseDownOwned[5]; // Track if button was clicked inside a dear imgui window or over void blocked by a popup. We don't request mouse capture from the application if click started outside ImGui bounds.
|
bool MouseDownOwned[5]; // Track if button was clicked inside a dear imgui window or over void blocked by a popup. We don't request mouse capture from the application if click started outside ImGui bounds.
|
||||||
bool MouseDownOwnedUnlessPopupClose[5]; // Track if button was clicked inside a dear imgui window.
|
bool MouseDownOwnedUnlessPopupClose[5]; // Track if button was clicked inside a dear imgui window.
|
||||||
bool MouseWheelRequestAxisSwap; // On a non-Mac system, holding SHIFT requests WheelY to perform the equivalent of a WheelX event. On a Mac system this is already enforced by the system.
|
bool MouseWheelRequestAxisSwap; // On a non-Mac system, holding Shift requests WheelY to perform the equivalent of a WheelX event. On a Mac system this is already enforced by the system.
|
||||||
bool MouseCtrlLeftAsRightClick; // (OSX) Set to true when the current click was a Ctrl+click that spawned a simulated right click
|
bool MouseCtrlLeftAsRightClick; // (OSX) Set to true when the current click was a Ctrl+Click that spawned a simulated right click
|
||||||
float MouseDownDuration[5]; // Duration the mouse button has been down (0.0f == just clicked)
|
float MouseDownDuration[5]; // Duration the mouse button has been down (0.0f == just clicked)
|
||||||
float MouseDownDurationPrev[5]; // Previous time the mouse button has been down
|
float MouseDownDurationPrev[5]; // Previous time the mouse button has been down
|
||||||
ImVec2 MouseDragMaxDistanceAbs[5]; // Maximum distance, absolute, on each axis, of how much mouse has traveled from the clicking point
|
ImVec2 MouseDragMaxDistanceAbs[5]; // Maximum distance, absolute, on each axis, of how much mouse has traveled from the clicking point
|
||||||
|
|
@ -2786,6 +2807,8 @@ struct ImGuiIO_t
|
||||||
const char* (*GetClipboardTextFn)(void* user_data);
|
const char* (*GetClipboardTextFn)(void* user_data);
|
||||||
void (*SetClipboardTextFn)(void* user_data, const char* text);
|
void (*SetClipboardTextFn)(void* user_data, const char* text);
|
||||||
void* ClipboardUserData;
|
void* ClipboardUserData;
|
||||||
|
|
||||||
|
//void ClearInputCharacters() { InputQueueCharacters.resize(0); } // [Obsoleted in 1.89.8] Clear the current frame text input buffer. Now included within ClearInputKeys(). Removed this as it is ambiguous/misleading and generally incorrect to use with the existence of a higher-level input queue.
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
};
|
};
|
||||||
// Input Functions
|
// Input Functions
|
||||||
|
|
@ -2806,9 +2829,6 @@ CIMGUI_API void ImGuiIO_SetAppAcceptingEvents(ImGuiIO* self, bool accepting_even
|
||||||
CIMGUI_API void ImGuiIO_ClearEventsQueue(ImGuiIO* self); // Clear all incoming events.
|
CIMGUI_API void ImGuiIO_ClearEventsQueue(ImGuiIO* self); // Clear all incoming events.
|
||||||
CIMGUI_API void ImGuiIO_ClearInputKeys(ImGuiIO* self); // Clear current keyboard/gamepad state + current frame text input buffer. Equivalent to releasing all keys/buttons.
|
CIMGUI_API void ImGuiIO_ClearInputKeys(ImGuiIO* self); // Clear current keyboard/gamepad state + current frame text input buffer. Equivalent to releasing all keys/buttons.
|
||||||
CIMGUI_API void ImGuiIO_ClearInputMouse(ImGuiIO* self); // Clear current mouse state.
|
CIMGUI_API void ImGuiIO_ClearInputMouse(ImGuiIO* self); // Clear current mouse state.
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
CIMGUI_API void ImGuiIO_ClearInputCharacters(ImGuiIO* self); // [Obsoleted in 1.89.8] Clear the current frame text input buffer. Now included within ClearInputKeys().
|
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
// [SECTION] Misc data structures (ImGuiInputTextCallbackData, ImGuiSizeCallbackData, ImGuiPayload)
|
// [SECTION] Misc data structures (ImGuiInputTextCallbackData, ImGuiSizeCallbackData, ImGuiPayload)
|
||||||
|
|
@ -2839,10 +2859,10 @@ struct ImGuiInputTextCallbackData_t
|
||||||
ImGuiKey EventKey; // Key pressed (Up/Down/TAB) // Read-only // [Completion,History]
|
ImGuiKey EventKey; // Key pressed (Up/Down/TAB) // Read-only // [Completion,History]
|
||||||
char* Buf; // Text buffer // Read-write // [Resize] Can replace pointer / [Completion,History,Always] Only write to pointed data, don't replace the actual pointer!
|
char* Buf; // Text buffer // Read-write // [Resize] Can replace pointer / [Completion,History,Always] Only write to pointed data, don't replace the actual pointer!
|
||||||
int BufTextLen; // Text length (in bytes) // Read-write // [Resize,Completion,History,Always] Exclude zero-terminator storage. In C land: == strlen(some_text), in C++ land: string.length()
|
int BufTextLen; // Text length (in bytes) // Read-write // [Resize,Completion,History,Always] Exclude zero-terminator storage. In C land: == strlen(some_text), in C++ land: string.length()
|
||||||
int BufSize; // Buffer size (in bytes) = capacity+1 // Read-only // [Resize,Completion,History,Always] Include zero-terminator storage. In C land == ARRAYSIZE(my_char_array), in C++ land: string.capacity()+1
|
int BufSize; // Buffer size (in bytes) = capacity+1 // Read-only // [Resize,Completion,History,Always] Include zero-terminator storage. In C land: == ARRAYSIZE(my_char_array), in C++ land: string.capacity()+1
|
||||||
bool BufDirty; // Set if you modify Buf/BufTextLen! // Write // [Completion,History,Always]
|
bool BufDirty; // Set if you modify Buf/BufTextLen! // Write // [Completion,History,Always]
|
||||||
int CursorPos; // // Read-write // [Completion,History,Always]
|
int CursorPos; // // Read-write // [Completion,History,Always]
|
||||||
int SelectionStart; // // Read-write // [Completion,History,Always] == to SelectionEnd when no selection)
|
int SelectionStart; // // Read-write // [Completion,History,Always] == to SelectionEnd when no selection
|
||||||
int SelectionEnd; // // Read-write // [Completion,History,Always]
|
int SelectionEnd; // // Read-write // [Completion,History,Always]
|
||||||
};
|
};
|
||||||
CIMGUI_API void ImGuiInputTextCallbackData_DeleteChars(ImGuiInputTextCallbackData* self, int pos, int bytes_count);
|
CIMGUI_API void ImGuiInputTextCallbackData_DeleteChars(ImGuiInputTextCallbackData* self, int pos, int bytes_count);
|
||||||
|
|
@ -3002,6 +3022,13 @@ CIMGUI_API void ImGuiStorage_BuildSortByKey(ImGuiStorage* self);
|
||||||
// Obsolete: use on your own storage if you know only integer are being stored (open/close all tree nodes)
|
// Obsolete: use on your own storage if you know only integer are being stored (open/close all tree nodes)
|
||||||
CIMGUI_API void ImGuiStorage_SetAllInt(ImGuiStorage* self, int val);
|
CIMGUI_API void ImGuiStorage_SetAllInt(ImGuiStorage* self, int val);
|
||||||
|
|
||||||
|
// Flags for ImGuiListClipper (currently not fully exposed in function calls: a future refactor will likely add this to ImGuiListClipper::Begin function equivalent)
|
||||||
|
typedef enum
|
||||||
|
{
|
||||||
|
ImGuiListClipperFlags_None = 0,
|
||||||
|
ImGuiListClipperFlags_NoSetTableRowCounters = 1<<0, // [Internal] Disabled modifying table row counters. Avoid assumption that 1 clipper item == 1 table row.
|
||||||
|
} ImGuiListClipperFlags_;
|
||||||
|
|
||||||
// Helper: Manually clip large list of items.
|
// Helper: Manually clip large list of items.
|
||||||
// If you have lots evenly spaced items and you have random access to the list, you can perform coarse
|
// If you have lots evenly spaced items and you have random access to the list, you can perform coarse
|
||||||
// clipping based on visibility to only submit items that are in view.
|
// clipping based on visibility to only submit items that are in view.
|
||||||
|
|
@ -3024,14 +3051,15 @@ CIMGUI_API void ImGuiStorage_SetAllInt(ImGuiStorage* self, int val);
|
||||||
// - The clipper also handles various subtleties related to keyboard/gamepad navigation, wrapping etc.
|
// - The clipper also handles various subtleties related to keyboard/gamepad navigation, wrapping etc.
|
||||||
struct ImGuiListClipper_t
|
struct ImGuiListClipper_t
|
||||||
{
|
{
|
||||||
ImGuiContext* Ctx; // Parent UI context
|
ImGuiContext* Ctx; // Parent UI context
|
||||||
int DisplayStart; // First item to display, updated by each call to Step()
|
int DisplayStart; // First item to display, updated by each call to Step()
|
||||||
int DisplayEnd; // End of items to display (exclusive)
|
int DisplayEnd; // End of items to display (exclusive)
|
||||||
int ItemsCount; // [Internal] Number of items
|
int ItemsCount; // [Internal] Number of items
|
||||||
float ItemsHeight; // [Internal] Height of item after a first step and item submission can calculate it
|
float ItemsHeight; // [Internal] Height of item after a first step and item submission can calculate it
|
||||||
double StartPosY; // [Internal] Cursor position at the time of Begin() or after table frozen rows are all processed
|
double StartPosY; // [Internal] Cursor position at the time of Begin() or after table frozen rows are all processed
|
||||||
double StartSeekOffsetY; // [Internal] Account for frozen rows in a table and initial loss of precision in very large windows.
|
double StartSeekOffsetY; // [Internal] Account for frozen rows in a table and initial loss of precision in very large windows.
|
||||||
void* TempData; // [Internal] Internal data
|
void* TempData; // [Internal] Internal data
|
||||||
|
ImGuiListClipperFlags Flags; // [Internal] Flags, currently not yet well exposed.
|
||||||
};
|
};
|
||||||
CIMGUI_API void ImGuiListClipper_Begin(ImGuiListClipper* self, int items_count, float items_height /* = -1.0f */);
|
CIMGUI_API void ImGuiListClipper_Begin(ImGuiListClipper* self, int items_count, float items_height /* = -1.0f */);
|
||||||
CIMGUI_API void ImGuiListClipper_End(ImGuiListClipper* self); // Automatically called on the last call of Step() that returns false.
|
CIMGUI_API void ImGuiListClipper_End(ImGuiListClipper* self); // Automatically called on the last call of Step() that returns false.
|
||||||
|
|
@ -3044,9 +3072,6 @@ CIMGUI_API void ImGuiListClipper_IncludeItemsByIndex(ImGuiListClipper* self, int
|
||||||
// - The only reason to call this is: you can use ImGuiListClipper::Begin(INT_MAX) if you don't know item count ahead of time.
|
// - The only reason to call this is: you can use ImGuiListClipper::Begin(INT_MAX) if you don't know item count ahead of time.
|
||||||
// - In this case, after all steps are done, you'll want to call SeekCursorForItem(item_count).
|
// - In this case, after all steps are done, you'll want to call SeekCursorForItem(item_count).
|
||||||
CIMGUI_API void ImGuiListClipper_SeekCursorForItem(ImGuiListClipper* self, int item_index);
|
CIMGUI_API void ImGuiListClipper_SeekCursorForItem(ImGuiListClipper* self, int item_index);
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
CIMGUI_API void ImGuiListClipper_IncludeRangeByIndices(ImGuiListClipper* self, int item_begin, int item_end); // [renamed in 1.89.9]
|
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
|
||||||
|
|
||||||
// Helpers: ImVec2/ImVec4 operators
|
// Helpers: ImVec2/ImVec4 operators
|
||||||
// - It is important that we are keeping those disabled by default so they don't leak in user space.
|
// - It is important that we are keeping those disabled by default so they don't leak in user space.
|
||||||
|
|
@ -3100,7 +3125,7 @@ CIMGUI_API ImColor ImColor_HSV(float h, float s, float v, float a /* = 1.0f */);
|
||||||
// Multi-selection system
|
// Multi-selection system
|
||||||
// Documentation at: https://github.com/ocornut/imgui/wiki/Multi-Select
|
// Documentation at: https://github.com/ocornut/imgui/wiki/Multi-Select
|
||||||
// - Refer to 'Demo->Widgets->Selection State & Multi-Select' for demos using this.
|
// - Refer to 'Demo->Widgets->Selection State & Multi-Select' for demos using this.
|
||||||
// - This system implements standard multi-selection idioms (CTRL+Mouse/Keyboard, SHIFT+Mouse/Keyboard, etc)
|
// - This system implements standard multi-selection idioms (Ctrl+Mouse/Keyboard, Shift+Mouse/Keyboard, etc)
|
||||||
// with support for clipper (skipping non-visible items), box-select and many other details.
|
// with support for clipper (skipping non-visible items), box-select and many other details.
|
||||||
// - Selectable(), Checkbox() are supported but custom widgets may use it as well.
|
// - Selectable(), Checkbox() are supported but custom widgets may use it as well.
|
||||||
// - TreeNode() is technically supported but... using this correctly is more complicated: you need some sort of linear/random access to your tree,
|
// - TreeNode() is technically supported but... using this correctly is more complicated: you need some sort of linear/random access to your tree,
|
||||||
|
|
@ -3138,7 +3163,7 @@ typedef enum
|
||||||
{
|
{
|
||||||
ImGuiMultiSelectFlags_None = 0,
|
ImGuiMultiSelectFlags_None = 0,
|
||||||
ImGuiMultiSelectFlags_SingleSelect = 1<<0, // Disable selecting more than one item. This is available to allow single-selection code to share same code/logic if desired. It essentially disables the main purpose of BeginMultiSelect() tho!
|
ImGuiMultiSelectFlags_SingleSelect = 1<<0, // Disable selecting more than one item. This is available to allow single-selection code to share same code/logic if desired. It essentially disables the main purpose of BeginMultiSelect() tho!
|
||||||
ImGuiMultiSelectFlags_NoSelectAll = 1<<1, // Disable CTRL+A shortcut to select all.
|
ImGuiMultiSelectFlags_NoSelectAll = 1<<1, // Disable Ctrl+A shortcut to select all.
|
||||||
ImGuiMultiSelectFlags_NoRangeSelect = 1<<2, // Disable Shift+selection mouse/keyboard support (useful for unordered 2D selection). With BoxSelect is also ensure contiguous SetRange requests are not combined into one. This allows not handling interpolation in SetRange requests.
|
ImGuiMultiSelectFlags_NoRangeSelect = 1<<2, // Disable Shift+selection mouse/keyboard support (useful for unordered 2D selection). With BoxSelect is also ensure contiguous SetRange requests are not combined into one. This allows not handling interpolation in SetRange requests.
|
||||||
ImGuiMultiSelectFlags_NoAutoSelect = 1<<3, // Disable selecting items when navigating (useful for e.g. supporting range-select in a list of checkboxes).
|
ImGuiMultiSelectFlags_NoAutoSelect = 1<<3, // Disable selecting items when navigating (useful for e.g. supporting range-select in a list of checkboxes).
|
||||||
ImGuiMultiSelectFlags_NoAutoClear = 1<<4, // Disable clearing selection when navigating or selecting another one (generally used with ImGuiMultiSelectFlags_NoAutoSelect. useful for e.g. supporting range-select in a list of checkboxes).
|
ImGuiMultiSelectFlags_NoAutoClear = 1<<4, // Disable clearing selection when navigating or selecting another one (generally used with ImGuiMultiSelectFlags_NoAutoSelect. useful for e.g. supporting range-select in a list of checkboxes).
|
||||||
|
|
@ -3154,6 +3179,7 @@ typedef enum
|
||||||
ImGuiMultiSelectFlags_SelectOnClickRelease = 1<<14, // Apply selection on mouse release when clicking an unselected item. Allow dragging an unselected item without altering selection.
|
ImGuiMultiSelectFlags_SelectOnClickRelease = 1<<14, // Apply selection on mouse release when clicking an unselected item. Allow dragging an unselected item without altering selection.
|
||||||
//ImGuiMultiSelectFlags_RangeSelect2d = 1 << 15, // Shift+Selection uses 2d geometry instead of linear sequence, so possible to use Shift+up/down to select vertically in grid. Analogous to what BoxSelect does.
|
//ImGuiMultiSelectFlags_RangeSelect2d = 1 << 15, // Shift+Selection uses 2d geometry instead of linear sequence, so possible to use Shift+up/down to select vertically in grid. Analogous to what BoxSelect does.
|
||||||
ImGuiMultiSelectFlags_NavWrapX = 1<<16, // [Temporary] Enable navigation wrapping on X axis. Provided as a convenience because we don't have a design for the general Nav API for this yet. When the more general feature be public we may obsolete this flag in favor of new one.
|
ImGuiMultiSelectFlags_NavWrapX = 1<<16, // [Temporary] Enable navigation wrapping on X axis. Provided as a convenience because we don't have a design for the general Nav API for this yet. When the more general feature be public we may obsolete this flag in favor of new one.
|
||||||
|
ImGuiMultiSelectFlags_NoSelectOnRightClick = 1<<17, // Disable default right-click processing, which selects item on mouse down, and is designed for context-menus.
|
||||||
} ImGuiMultiSelectFlags_;
|
} ImGuiMultiSelectFlags_;
|
||||||
|
|
||||||
// Main IO structure returned by BeginMultiSelect()/EndMultiSelect().
|
// Main IO structure returned by BeginMultiSelect()/EndMultiSelect().
|
||||||
|
|
@ -3279,7 +3305,7 @@ struct ImDrawCmd_t
|
||||||
};
|
};
|
||||||
// Since 1.83: returns ImTextureID associated with this draw call. Warning: DO NOT assume this is always same as 'TextureId' (we will change this function for an upcoming feature)
|
// Since 1.83: returns ImTextureID associated with this draw call. Warning: DO NOT assume this is always same as 'TextureId' (we will change this function for an upcoming feature)
|
||||||
// Since 1.92: removed ImDrawCmd::TextureId field, the getter function must be used!
|
// Since 1.92: removed ImDrawCmd::TextureId field, the getter function must be used!
|
||||||
CIMGUI_API ImTextureID ImDrawCmd_GetTexID(const ImDrawCmd* self); // == (TexRef._TexData ? TexRef._TexData->TexID : TexRef._TexID
|
CIMGUI_API ImTextureID ImDrawCmd_GetTexID(const ImDrawCmd* self); // == (TexRef._TexData ? TexRef._TexData->TexID : TexRef._TexID)
|
||||||
|
|
||||||
// Vertex layout
|
// Vertex layout
|
||||||
#ifndef IMGUI_OVERRIDE_DRAWVERT_STRUCT_LAYOUT
|
#ifndef IMGUI_OVERRIDE_DRAWVERT_STRUCT_LAYOUT
|
||||||
|
|
@ -3480,7 +3506,7 @@ CIMGUI_API void ImDrawList_AddCallback(ImDrawList* self, ImDrawCallback c
|
||||||
CIMGUI_API void ImDrawList_AddCallbackEx(ImDrawList* self, ImDrawCallback callback, void* userdata, size_t userdata_size /* = 0 */);
|
CIMGUI_API void ImDrawList_AddCallbackEx(ImDrawList* self, ImDrawCallback callback, void* userdata, size_t userdata_size /* = 0 */);
|
||||||
// Advanced: Miscellaneous
|
// Advanced: Miscellaneous
|
||||||
CIMGUI_API void ImDrawList_AddDrawCmd(ImDrawList* self); // This is useful if you need to forcefully create a new draw call (to allow for dependent rendering / blending). Otherwise primitives are merged into the same draw-call as much as possible
|
CIMGUI_API void ImDrawList_AddDrawCmd(ImDrawList* self); // This is useful if you need to forcefully create a new draw call (to allow for dependent rendering / blending). Otherwise primitives are merged into the same draw-call as much as possible
|
||||||
CIMGUI_API ImDrawList* ImDrawList_CloneOutput(const ImDrawList* self); // Create a clone of the CmdBuffer/IdxBuffer/VtxBuffer.
|
CIMGUI_API ImDrawList* ImDrawList_CloneOutput(const ImDrawList* self); // Create a clone of the CmdBuffer/IdxBuffer/VtxBuffer. For multi-threaded rendering, consider using `imgui_threaded_rendering` from https://github.com/ocornut/imgui_club instead.
|
||||||
// Advanced: Channels
|
// Advanced: Channels
|
||||||
// - Use to split render into layers. By switching channels to can render out-of-order (e.g. submit FG primitives before BG primitives)
|
// - Use to split render into layers. By switching channels to can render out-of-order (e.g. submit FG primitives before BG primitives)
|
||||||
// - Use to minimize draw calls (e.g. if going back-and-forth between multiple clipping rectangles, prefer to append into separate channels then merge at the end)
|
// - Use to minimize draw calls (e.g. if going back-and-forth between multiple clipping rectangles, prefer to append into separate channels then merge at the end)
|
||||||
|
|
@ -3503,8 +3529,8 @@ CIMGUI_API void ImDrawList_PrimWriteIdx(ImDrawList* self, ImDrawIdx idx);
|
||||||
CIMGUI_API void ImDrawList_PrimVtx(ImDrawList* self, ImVec2 pos, ImVec2 uv, ImU32 col); // Write vertex with unique index
|
CIMGUI_API void ImDrawList_PrimVtx(ImDrawList* self, ImVec2 pos, ImVec2 uv, ImU32 col); // Write vertex with unique index
|
||||||
// Obsolete names
|
// Obsolete names
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
CIMGUI_API void ImDrawList_PushTextureID(ImDrawList* self, ImTextureRef tex_ref); // RENAMED in 1.92.x
|
CIMGUI_API void ImDrawList_PushTextureID(ImDrawList* self, ImTextureRef tex_ref); // RENAMED in 1.92.0
|
||||||
CIMGUI_API void ImDrawList_PopTextureID(ImDrawList* self); // RENAMED in 1.92.x
|
CIMGUI_API void ImDrawList_PopTextureID(ImDrawList* self); // RENAMED in 1.92.0
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
// [Internal helpers]
|
// [Internal helpers]
|
||||||
CIMGUI_API void ImDrawList__SetDrawListSharedData(ImDrawList* self, ImDrawListSharedData* data);
|
CIMGUI_API void ImDrawList__SetDrawListSharedData(ImDrawList* self, ImDrawListSharedData* data);
|
||||||
|
|
@ -3534,7 +3560,7 @@ struct ImDrawData_t
|
||||||
ImVec2 DisplaySize; // Size of the viewport to render (== GetMainViewport()->Size for the main viewport, == io.DisplaySize in most single-viewport applications)
|
ImVec2 DisplaySize; // Size of the viewport to render (== GetMainViewport()->Size for the main viewport, == io.DisplaySize in most single-viewport applications)
|
||||||
ImVec2 FramebufferScale; // Amount of pixels for each unit of DisplaySize. Copied from viewport->FramebufferScale (== io.DisplayFramebufferScale for main viewport). Generally (1,1) on normal display, (2,2) on OSX with Retina display.
|
ImVec2 FramebufferScale; // Amount of pixels for each unit of DisplaySize. Copied from viewport->FramebufferScale (== io.DisplayFramebufferScale for main viewport). Generally (1,1) on normal display, (2,2) on OSX with Retina display.
|
||||||
ImGuiViewport* OwnerViewport; // Viewport carrying the ImDrawData instance, might be of use to the renderer (generally not).
|
ImGuiViewport* OwnerViewport; // Viewport carrying the ImDrawData instance, might be of use to the renderer (generally not).
|
||||||
ImVector_ImTextureDataPtr* Textures; // List of textures to update. Most of the times the list is shared by all ImDrawData, has only 1 texture and it doesn't need any update. This almost always points to ImGui::GetPlatformIO().Textures[]. May be overriden or set to NULL if you want to manually update textures.
|
ImVector_ImTextureDataPtr* Textures; // List of textures to update. Most of the times the list is shared by all ImDrawData, has only 1 texture and it doesn't need any update. This almost always points to ImGui::GetPlatformIO().Textures[]. May be overridden or set to NULL if you want to manually update textures.
|
||||||
};
|
};
|
||||||
CIMGUI_API void ImDrawData_Clear(ImDrawData* self);
|
CIMGUI_API void ImDrawData_Clear(ImDrawData* self);
|
||||||
CIMGUI_API void ImDrawData_AddDrawList(ImDrawData* self, ImDrawList* draw_list); // Helper to add an external draw list into an existing ImDrawData.
|
CIMGUI_API void ImDrawData_AddDrawList(ImDrawData* self, ImDrawList* draw_list); // Helper to add an external draw list into an existing ImDrawData.
|
||||||
|
|
@ -3612,8 +3638,10 @@ CIMGUI_API int ImTextureData_GetPitch(const ImTextureData* self);
|
||||||
CIMGUI_API ImTextureRef ImTextureData_GetTexRef(ImTextureData* self);
|
CIMGUI_API ImTextureRef ImTextureData_GetTexRef(ImTextureData* self);
|
||||||
CIMGUI_API ImTextureID ImTextureData_GetTexID(const ImTextureData* self);
|
CIMGUI_API ImTextureID ImTextureData_GetTexID(const ImTextureData* self);
|
||||||
// Called by Renderer backend
|
// Called by Renderer backend
|
||||||
CIMGUI_API void ImTextureData_SetTexID(ImTextureData* self, ImTextureID tex_id); // Call after creating or destroying the texture. Never modify TexID directly!
|
// - Call SetTexID() and SetStatus() after honoring texture requests. Never modify TexID and Status directly!
|
||||||
CIMGUI_API void ImTextureData_SetStatus(ImTextureData* self, ImTextureStatus status); // Call after honoring a request. Never modify Status directly!
|
// - A backend may decide to destroy a texture that we did not request to destroy, which is fine (e.g. freeing resources), but we immediately set the texture back in _WantCreate mode.
|
||||||
|
CIMGUI_API void ImTextureData_SetTexID(ImTextureData* self, ImTextureID tex_id);
|
||||||
|
CIMGUI_API void ImTextureData_SetStatus(ImTextureData* self, ImTextureStatus status);
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
// [SECTION] Font API (ImFontConfig, ImFontGlyph, ImFontAtlasFlags, ImFontAtlas, ImFontGlyphRangesBuilder, ImFont)
|
// [SECTION] Font API (ImFontConfig, ImFontGlyph, ImFontAtlasFlags, ImFontAtlas, ImFontGlyphRangesBuilder, ImFont)
|
||||||
|
|
@ -3626,7 +3654,7 @@ struct ImFontConfig_t
|
||||||
char Name[40]; // <auto> // Name (strictly to ease debugging, hence limited size buffer)
|
char Name[40]; // <auto> // Name (strictly to ease debugging, hence limited size buffer)
|
||||||
void* FontData; // // TTF/OTF data
|
void* FontData; // // TTF/OTF data
|
||||||
int FontDataSize; // // TTF/OTF data size
|
int FontDataSize; // // TTF/OTF data size
|
||||||
bool FontDataOwnedByAtlas; // true // TTF/OTF data ownership taken by the container ImFontAtlas (will delete memory itself).
|
bool FontDataOwnedByAtlas; // true // TTF/OTF data ownership taken by the owner ImFontAtlas (will delete memory itself).
|
||||||
|
|
||||||
// Options
|
// Options
|
||||||
bool MergeMode; // false // Merge into previous ImFont, so you can combine multiple inputs font into one ImFont (e.g. ASCII font + icons + Japanese glyphs). You may want to use GlyphOffset.y when merge font of different heights.
|
bool MergeMode; // false // Merge into previous ImFont, so you can combine multiple inputs font into one ImFont (e.g. ASCII font + icons + Japanese glyphs). You may want to use GlyphOffset.y when merge font of different heights.
|
||||||
|
|
@ -3757,7 +3785,7 @@ struct ImFontAtlas_t
|
||||||
#ifdef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifdef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
ImTextureRef TexRef; // Latest texture identifier == TexData->GetTexRef().
|
ImTextureRef TexRef; // Latest texture identifier == TexData->GetTexRef().
|
||||||
#else
|
#else
|
||||||
union // Latest texture identifier == TexData->GetTexRef(). // RENAMED TexID to TexRef in 1.92.x
|
union // Latest texture identifier == TexData->GetTexRef(). // RENAMED TexID to TexRef in 1.92.0.
|
||||||
{
|
{
|
||||||
ImTextureRef TexRef;
|
ImTextureRef TexRef;
|
||||||
ImTextureRef TexID;
|
ImTextureRef TexID;
|
||||||
|
|
@ -3792,9 +3820,9 @@ struct ImFontAtlas_t
|
||||||
// Legacy: You can request your rectangles to be mapped as font glyph (given a font + Unicode point), so you can render e.g. custom colorful icons and use them as regular glyphs. --> Prefer using a custom ImFontLoader.
|
// Legacy: You can request your rectangles to be mapped as font glyph (given a font + Unicode point), so you can render e.g. custom colorful icons and use them as regular glyphs. --> Prefer using a custom ImFontLoader.
|
||||||
ImFontAtlasRect TempRect; // For old GetCustomRectByIndex() API
|
ImFontAtlasRect TempRect; // For old GetCustomRectByIndex() API
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
//unsigned int FontBuilderFlags; // OBSOLETED in 1.92.X: Renamed to FontLoaderFlags.
|
//unsigned int FontBuilderFlags; // OBSOLETED in 1.92.0: Renamed to FontLoaderFlags.
|
||||||
//int TexDesiredWidth; // OBSOLETED in 1.92.X: Force texture width before calling Build(). Must be a power-of-two. If have many glyphs your graphics API have texture size restrictions you may want to increase texture width to decrease height)
|
//int TexDesiredWidth; // OBSOLETED in 1.92.0: Force texture width before calling Build(). Must be a power-of-two. If have many glyphs your graphics API have texture size restrictions you may want to increase texture width to decrease height.
|
||||||
//typedef ImFontAtlasRect ImFontAtlasCustomRect; // OBSOLETED in 1.92.X
|
//typedef ImFontAtlasRect ImFontAtlasCustomRect; // OBSOLETED in 1.92.0
|
||||||
//typedef ImFontAtlasCustomRect CustomRect; // OBSOLETED in 1.72+
|
//typedef ImFontAtlasCustomRect CustomRect; // OBSOLETED in 1.72+
|
||||||
//typedef ImFontGlyphRangesBuilder GlyphRangesBuilder; // OBSOLETED in 1.67+
|
//typedef ImFontGlyphRangesBuilder GlyphRangesBuilder; // OBSOLETED in 1.67+
|
||||||
};
|
};
|
||||||
|
|
@ -3805,7 +3833,7 @@ CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryTTF(ImFontAtlas* self,
|
||||||
CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryCompressedTTF(ImFontAtlas* self, const void* compressed_font_data, int compressed_font_data_size, float size_pixels /* = 0.0f */, const ImFontConfig* font_cfg /* = NULL */, const ImWchar* glyph_ranges /* = NULL */); // 'compressed_font_data' still owned by caller. Compress with binary_to_compressed_c.cpp.
|
CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryCompressedTTF(ImFontAtlas* self, const void* compressed_font_data, int compressed_font_data_size, float size_pixels /* = 0.0f */, const ImFontConfig* font_cfg /* = NULL */, const ImWchar* glyph_ranges /* = NULL */); // 'compressed_font_data' still owned by caller. Compress with binary_to_compressed_c.cpp.
|
||||||
CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryCompressedBase85TTF(ImFontAtlas* self, const char* compressed_font_data_base85, float size_pixels /* = 0.0f */, const ImFontConfig* font_cfg /* = NULL */, const ImWchar* glyph_ranges /* = NULL */); // 'compressed_font_data_base85' still owned by caller. Compress with binary_to_compressed_c.cpp with -base85 parameter.
|
CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryCompressedBase85TTF(ImFontAtlas* self, const char* compressed_font_data_base85, float size_pixels /* = 0.0f */, const ImFontConfig* font_cfg /* = NULL */, const ImWchar* glyph_ranges /* = NULL */); // 'compressed_font_data_base85' still owned by caller. Compress with binary_to_compressed_c.cpp with -base85 parameter.
|
||||||
CIMGUI_API void ImFontAtlas_RemoveFont(ImFontAtlas* self, ImFont* font);
|
CIMGUI_API void ImFontAtlas_RemoveFont(ImFontAtlas* self, ImFont* font);
|
||||||
CIMGUI_API void ImFontAtlas_Clear(ImFontAtlas* self); // Clear everything (input fonts, output glyphs/textures)
|
CIMGUI_API void ImFontAtlas_Clear(ImFontAtlas* self); // Clear everything (input fonts, output glyphs/textures).
|
||||||
CIMGUI_API void ImFontAtlas_CompactCache(ImFontAtlas* self); // Compact cached glyphs and texture.
|
CIMGUI_API void ImFontAtlas_CompactCache(ImFontAtlas* self); // Compact cached glyphs and texture.
|
||||||
CIMGUI_API void ImFontAtlas_SetFontLoader(ImFontAtlas* self, const ImFontLoader* font_loader); // Change font loader at runtime.
|
CIMGUI_API void ImFontAtlas_SetFontLoader(ImFontAtlas* self, const ImFontLoader* font_loader); // Change font loader at runtime.
|
||||||
// As we are transitioning toward a new font system, we expect to obsolete those soon:
|
// As we are transitioning toward a new font system, we expect to obsolete those soon:
|
||||||
|
|
@ -3817,7 +3845,7 @@ CIMGUI_API void ImFontAtlas_ClearTexData(ImFontAtlas* self);
|
||||||
// - User is in charge of copying the pixels into graphics memory (e.g. create a texture with your engine). Then store your texture handle with SetTexID().
|
// - User is in charge of copying the pixels into graphics memory (e.g. create a texture with your engine). Then store your texture handle with SetTexID().
|
||||||
// - The pitch is always = Width * BytesPerPixels (1 or 4)
|
// - The pitch is always = Width * BytesPerPixels (1 or 4)
|
||||||
// - Building in RGBA32 format is provided for convenience and compatibility, but note that unless you manually manipulate or copy color data into
|
// - Building in RGBA32 format is provided for convenience and compatibility, but note that unless you manually manipulate or copy color data into
|
||||||
// the texture (e.g. when using the AddCustomRect*** api), then the RGB pixels emitted will always be white (~75% of memory/bandwidth waste.
|
// the texture (e.g. when using the AddCustomRect*** api), then the RGB pixels emitted will always be white (~75% of memory/bandwidth waste).
|
||||||
// - From 1.92 with backends supporting ImGuiBackendFlags_RendererHasTextures:
|
// - From 1.92 with backends supporting ImGuiBackendFlags_RendererHasTextures:
|
||||||
// - Calling Build(), GetTexDataAsAlpha8(), GetTexDataAsRGBA32() is not needed.
|
// - Calling Build(), GetTexDataAsAlpha8(), GetTexDataAsRGBA32() is not needed.
|
||||||
// - In backend: replace calls to ImFontAtlas::SetTexID() with calls to ImTextureData::SetTexID() after honoring texture creation.
|
// - In backend: replace calls to ImFontAtlas::SetTexID() with calls to ImTextureData::SetTexID() after honoring texture creation.
|
||||||
|
|
@ -3846,7 +3874,7 @@ CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesVietnamese(ImFontAtlas* self
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
// Register and retrieve custom rectangles
|
// Register and retrieve custom rectangles
|
||||||
// - You can request arbitrary rectangles to be packed into the atlas, for your own purpose.
|
// - You can request arbitrary rectangles to be packed into the atlas, for your own purpose.
|
||||||
// - Since 1.92.X, packing is done immediately in the function call (previously packing was done during the Build call)
|
// - Since 1.92.0, packing is done immediately in the function call (previously packing was done during the Build call)
|
||||||
// - You can render your pixels into the texture right after calling the AddCustomRect() functions.
|
// - You can render your pixels into the texture right after calling the AddCustomRect() functions.
|
||||||
// - VERY IMPORTANT:
|
// - VERY IMPORTANT:
|
||||||
// - Texture may be created/resized at any time when calling ImGui or ImFontAtlas functions.
|
// - Texture may be created/resized at any time when calling ImGui or ImFontAtlas functions.
|
||||||
|
|
@ -3866,11 +3894,11 @@ CIMGUI_API void ImFontAtlas_RemoveCustomRect(ImFontAtlas* self, ImF
|
||||||
CIMGUI_API bool ImFontAtlas_GetCustomRect(const ImFontAtlas* self, ImFontAtlasRectId id, ImFontAtlasRect* out_r); // Get rectangle coordinates for current texture. Valid immediately, never store this (read above)!
|
CIMGUI_API bool ImFontAtlas_GetCustomRect(const ImFontAtlas* self, ImFontAtlasRectId id, ImFontAtlasRect* out_r); // Get rectangle coordinates for current texture. Valid immediately, never store this (read above)!
|
||||||
// [Obsolete]
|
// [Obsolete]
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
CIMGUI_API ImFontAtlasRectId ImFontAtlas_AddCustomRectRegular(ImFontAtlas* self, int w, int h); // RENAMED in 1.92.X
|
CIMGUI_API ImFontAtlasRectId ImFontAtlas_AddCustomRectRegular(ImFontAtlas* self, int w, int h); // RENAMED in 1.92.0
|
||||||
CIMGUI_API const ImFontAtlasRect* ImFontAtlas_GetCustomRectByIndex(ImFontAtlas* self, ImFontAtlasRectId id); // OBSOLETED in 1.92.X
|
CIMGUI_API const ImFontAtlasRect* ImFontAtlas_GetCustomRectByIndex(ImFontAtlas* self, ImFontAtlasRectId id); // OBSOLETED in 1.92.0
|
||||||
CIMGUI_API void ImFontAtlas_CalcCustomRectUV(const ImFontAtlas* self, const ImFontAtlasRect* r, ImVec2* out_uv_min, ImVec2* out_uv_max); // OBSOLETED in 1.92.X
|
CIMGUI_API void ImFontAtlas_CalcCustomRectUV(const ImFontAtlas* self, const ImFontAtlasRect* r, ImVec2* out_uv_min, ImVec2* out_uv_max); // OBSOLETED in 1.92.0
|
||||||
CIMGUI_API ImFontAtlasRectId ImFontAtlas_AddCustomRectFontGlyph(ImFontAtlas* self, ImFont* font, ImWchar codepoint, int w, int h, float advance_x, ImVec2 offset /* = ImVec2(0, 0) */); // OBSOLETED in 1.92.X: Use custom ImFontLoader in ImFontConfig
|
CIMGUI_API ImFontAtlasRectId ImFontAtlas_AddCustomRectFontGlyph(ImFontAtlas* self, ImFont* font, ImWchar codepoint, int w, int h, float advance_x, ImVec2 offset /* = ImVec2(0, 0) */); // OBSOLETED in 1.92.0: Use custom ImFontLoader in ImFontConfig
|
||||||
CIMGUI_API ImFontAtlasRectId ImFontAtlas_AddCustomRectFontGlyphForSize(ImFontAtlas* self, ImFont* font, float font_size, ImWchar codepoint, int w, int h, float advance_x, ImVec2 offset /* = ImVec2(0, 0) */); // ADDED AND OBSOLETED in 1.92.X
|
CIMGUI_API ImFontAtlasRectId ImFontAtlas_AddCustomRectFontGlyphForSize(ImFontAtlas* self, ImFont* font, float font_size, ImWchar codepoint, int w, int h, float advance_x, ImVec2 offset /* = ImVec2(0, 0) */); // ADDED AND OBSOLETED in 1.92.0
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
|
|
||||||
// Font runtime data for a given size
|
// Font runtime data for a given size
|
||||||
|
|
@ -3896,7 +3924,7 @@ struct ImFontBaked_t
|
||||||
unsigned int LoadNoRenderOnLayout : 1; // 0 // // Enable a two-steps mode where CalcTextSize() calls will load AdvanceX *without* rendering/packing glyphs. Only advantagous if you know that the glyph is unlikely to actually be rendered, otherwise it is slower because we'd do one query on the first CalcTextSize and one query on the first Draw.
|
unsigned int LoadNoRenderOnLayout : 1; // 0 // // Enable a two-steps mode where CalcTextSize() calls will load AdvanceX *without* rendering/packing glyphs. Only advantagous if you know that the glyph is unlikely to actually be rendered, otherwise it is slower because we'd do one query on the first CalcTextSize and one query on the first Draw.
|
||||||
int LastUsedFrame; // 4 // // Record of that time this was bounds
|
int LastUsedFrame; // 4 // // Record of that time this was bounds
|
||||||
ImGuiID BakedId; // 4 // // Unique ID for this baked storage
|
ImGuiID BakedId; // 4 // // Unique ID for this baked storage
|
||||||
ImFont* ContainerFont; // 4-8 // in // Parent font
|
ImFont* OwnerFont; // 4-8 // in // Parent font
|
||||||
void* FontLoaderDatas; // 4-8 // // Font loader opaque storage (per baked font * sources): single contiguous buffer allocated by imgui, passed to loader.
|
void* FontLoaderDatas; // 4-8 // // Font loader opaque storage (per baked font * sources): single contiguous buffer allocated by imgui, passed to loader.
|
||||||
};
|
};
|
||||||
CIMGUI_API void ImFontBaked_ClearOutputData(ImFontBaked* self);
|
CIMGUI_API void ImFontBaked_ClearOutputData(ImFontBaked* self);
|
||||||
|
|
@ -3917,14 +3945,14 @@ typedef enum
|
||||||
|
|
||||||
// Font runtime data and rendering
|
// Font runtime data and rendering
|
||||||
// - ImFontAtlas automatically loads a default embedded font for you if you didn't load one manually.
|
// - ImFontAtlas automatically loads a default embedded font for you if you didn't load one manually.
|
||||||
// - Since 1.92.X a font may be rendered as any size! Therefore a font doesn't have one specific size.
|
// - Since 1.92.0 a font may be rendered as any size! Therefore a font doesn't have one specific size.
|
||||||
// - Use 'font->GetFontBaked(size)' to retrieve the ImFontBaked* corresponding to a given size.
|
// - Use 'font->GetFontBaked(size)' to retrieve the ImFontBaked* corresponding to a given size.
|
||||||
// - If you used g.Font + g.FontSize (which is frequent from the ImGui layer), you can use g.FontBaked as a shortcut, as g.FontBaked == g.Font->GetFontBaked(g.FontSize).
|
// - If you used g.Font + g.FontSize (which is frequent from the ImGui layer), you can use g.FontBaked as a shortcut, as g.FontBaked == g.Font->GetFontBaked(g.FontSize).
|
||||||
struct ImFont_t
|
struct ImFont_t
|
||||||
{
|
{
|
||||||
// [Internal] Members: Hot ~12-20 bytes
|
// [Internal] Members: Hot ~12-20 bytes
|
||||||
ImFontBaked* LastBaked; // 4-8 // Cache last bound baked. NEVER USE DIRECTLY. Use GetFontBaked().
|
ImFontBaked* LastBaked; // 4-8 // Cache last bound baked. NEVER USE DIRECTLY. Use GetFontBaked().
|
||||||
ImFontAtlas* ContainerAtlas; // 4-8 // What we have been loaded into.
|
ImFontAtlas* OwnerAtlas; // 4-8 // What we have been loaded into.
|
||||||
ImFontFlags Flags; // 4 // Font flags.
|
ImFontFlags Flags; // 4 // Font flags.
|
||||||
float CurrentRasterizerDensity; // Current rasterizer density. This is a varying state of the font.
|
float CurrentRasterizerDensity; // Current rasterizer density. This is a varying state of the font.
|
||||||
|
|
||||||
|
|
@ -3932,7 +3960,7 @@ struct ImFont_t
|
||||||
// Conceptually Sources[] is the list of font sources merged to create this font.
|
// Conceptually Sources[] is the list of font sources merged to create this font.
|
||||||
ImGuiID FontId; // Unique identifier for the font
|
ImGuiID FontId; // Unique identifier for the font
|
||||||
float LegacySize; // 4 // in // Font size passed to AddFont(). Use for old code calling PushFont() expecting to use that size. (use ImGui::GetFontBaked() to get font baked at current bound size).
|
float LegacySize; // 4 // in // Font size passed to AddFont(). Use for old code calling PushFont() expecting to use that size. (use ImGui::GetFontBaked() to get font baked at current bound size).
|
||||||
ImVector_ImFontConfigPtr Sources; // 16 // in // List of sources. Pointers within ContainerAtlas->Sources[]
|
ImVector_ImFontConfigPtr Sources; // 16 // in // List of sources. Pointers within OwnerAtlas->Sources[]
|
||||||
ImWchar EllipsisChar; // 2-4 // out // Character used for ellipsis rendering ('...').
|
ImWchar EllipsisChar; // 2-4 // out // Character used for ellipsis rendering ('...').
|
||||||
ImWchar FallbackChar; // 2-4 // out // Character used if a glyph isn't found (U+FFFD, '?')
|
ImWchar FallbackChar; // 2-4 // out // Character used if a glyph isn't found (U+FFFD, '?')
|
||||||
ImU8 Used8kPagesMap[(IM_UNICODE_CODEPOINT_MAX +1)/8192/8]; // 1 bytes if ImWchar=ImWchar16, 16 bytes if ImWchar==ImWchar32. Store 1-bit for each block of 4K codepoints that has one active glyph. This is mainly used to facilitate iterations across all used codepoints.
|
ImU8 Used8kPagesMap[(IM_UNICODE_CODEPOINT_MAX +1)/8192/8]; // 1 bytes if ImWchar=ImWchar16, 16 bytes if ImWchar==ImWchar32. Store 1-bit for each block of 4K codepoints that has one active glyph. This is mainly used to facilitate iterations across all used codepoints.
|
||||||
|
|
@ -3950,12 +3978,12 @@ CIMGUI_API const char* ImFont_GetDebugName(const ImFont* self);
|
||||||
// 'wrap_width' enable automatic word-wrapping across multiple lines to fit into given width. 0.0f to disable.
|
// 'wrap_width' enable automatic word-wrapping across multiple lines to fit into given width. 0.0f to disable.
|
||||||
CIMGUI_API ImFontBaked* ImFont_GetFontBaked(ImFont* self, float font_size); // Implied density = -1.0f
|
CIMGUI_API ImFontBaked* ImFont_GetFontBaked(ImFont* self, float font_size); // Implied density = -1.0f
|
||||||
CIMGUI_API ImFontBaked* ImFont_GetFontBakedEx(ImFont* self, float font_size, float density /* = -1.0f */); // Get or create baked data for given size
|
CIMGUI_API ImFontBaked* ImFont_GetFontBakedEx(ImFont* self, float font_size, float density /* = -1.0f */); // Get or create baked data for given size
|
||||||
CIMGUI_API ImVec2 ImFont_CalcTextSizeA(ImFont* self, float size, float max_width, float wrap_width, const char* text_begin); // Implied text_end = NULL, remaining = NULL
|
CIMGUI_API ImVec2 ImFont_CalcTextSizeA(ImFont* self, float size, float max_width, float wrap_width, const char* text_begin); // Implied text_end = NULL, out_remaining = NULL
|
||||||
CIMGUI_API ImVec2 ImFont_CalcTextSizeAEx(ImFont* self, float size, float max_width, float wrap_width, const char* text_begin, const char* text_end /* = NULL */, const char** remaining /* = NULL */); // utf8
|
CIMGUI_API ImVec2 ImFont_CalcTextSizeAEx(ImFont* self, float size, float max_width, float wrap_width, const char* text_begin, const char* text_end /* = NULL */, const char** out_remaining /* = NULL */);
|
||||||
CIMGUI_API const char* ImFont_CalcWordWrapPosition(ImFont* self, float size, const char* text, const char* text_end, float wrap_width);
|
CIMGUI_API const char* ImFont_CalcWordWrapPosition(ImFont* self, float size, const char* text, const char* text_end, float wrap_width);
|
||||||
CIMGUI_API void ImFont_RenderChar(ImFont* self, ImDrawList* draw_list, float size, ImVec2 pos, ImU32 col, ImWchar c); // Implied cpu_fine_clip = NULL
|
CIMGUI_API void ImFont_RenderChar(ImFont* self, ImDrawList* draw_list, float size, ImVec2 pos, ImU32 col, ImWchar c); // Implied cpu_fine_clip = NULL
|
||||||
CIMGUI_API void ImFont_RenderCharEx(ImFont* self, ImDrawList* draw_list, float size, ImVec2 pos, ImU32 col, ImWchar c, const ImVec4* cpu_fine_clip /* = NULL */);
|
CIMGUI_API void ImFont_RenderCharEx(ImFont* self, ImDrawList* draw_list, float size, ImVec2 pos, ImU32 col, ImWchar c, const ImVec4* cpu_fine_clip /* = NULL */);
|
||||||
CIMGUI_API void ImFont_RenderText(ImFont* self, ImDrawList* draw_list, float size, ImVec2 pos, ImU32 col, ImVec4 clip_rect, const char* text_begin, const char* text_end, float wrap_width /* = 0.0f */, bool cpu_fine_clip /* = false */);
|
CIMGUI_API void ImFont_RenderText(ImFont* self, ImDrawList* draw_list, float size, ImVec2 pos, ImU32 col, ImVec4 clip_rect, const char* text_begin, const char* text_end, float wrap_width /* = 0.0f */, ImDrawTextFlags flags /* = 0 */);
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
CIMGUI_API const char* ImFont_CalcWordWrapPositionA(ImFont* self, float scale, const char* text, const char* text_end, float wrap_width);
|
CIMGUI_API const char* ImFont_CalcWordWrapPositionA(ImFont* self, float scale, const char* text, const char* text_end, float wrap_width);
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
|
|
@ -4008,6 +4036,7 @@ struct ImGuiViewport_t
|
||||||
ImVec2 WorkSize; // Work Area: Size of the viewport minus task bars, menu bars, status bars (<= Size)
|
ImVec2 WorkSize; // Work Area: Size of the viewport minus task bars, menu bars, status bars (<= Size)
|
||||||
float DpiScale; // 1.0f = 96 DPI = No extra scale.
|
float DpiScale; // 1.0f = 96 DPI = No extra scale.
|
||||||
ImGuiID ParentViewportId; // (Advanced) 0: no parent. Instruct the platform backend to setup a parent/child relationship between platform windows.
|
ImGuiID ParentViewportId; // (Advanced) 0: no parent. Instruct the platform backend to setup a parent/child relationship between platform windows.
|
||||||
|
ImGuiViewport* ParentViewport; // (Advanced) Direct shortcut to ImGui::FindViewportByID(ParentViewportId). NULL: no parent.
|
||||||
ImDrawData* DrawData; // The ImDrawData corresponding to this viewport. Valid after Render() and until the next call to NewFrame().
|
ImDrawData* DrawData; // The ImDrawData corresponding to this viewport. Valid after Render() and until the next call to NewFrame().
|
||||||
|
|
||||||
// Platform/Backend Dependent Data
|
// Platform/Backend Dependent Data
|
||||||
|
|
@ -4092,7 +4121,7 @@ struct ImGuiPlatformIO_t
|
||||||
void* Platform_ClipboardUserData;
|
void* Platform_ClipboardUserData;
|
||||||
|
|
||||||
// Optional: Open link/folder/file in OS Shell
|
// Optional: Open link/folder/file in OS Shell
|
||||||
// (default to use ShellExecuteW() on Windows, system() on Linux/Mac)
|
// (default to use ShellExecuteW() on Windows, system() on Linux/Mac. expected to return false on failure, but some platforms may always return true)
|
||||||
bool (*Platform_OpenInShellFn)(ImGuiContext* ctx, const char* path);
|
bool (*Platform_OpenInShellFn)(ImGuiContext* ctx, const char* path);
|
||||||
void* Platform_OpenInShellUserData;
|
void* Platform_OpenInShellUserData;
|
||||||
|
|
||||||
|
|
@ -4178,7 +4207,13 @@ struct ImGuiPlatformIO_t
|
||||||
// Viewports list (the list is updated by calling ImGui::EndFrame or ImGui::Render)
|
// Viewports list (the list is updated by calling ImGui::EndFrame or ImGui::Render)
|
||||||
// (in the future we will attempt to organize this feature to remove the need for a "main viewport")
|
// (in the future we will attempt to organize this feature to remove the need for a "main viewport")
|
||||||
ImVector_ImGuiViewportPtr Viewports; // Main viewports, followed by all secondary viewports.
|
ImVector_ImGuiViewportPtr Viewports; // Main viewports, followed by all secondary viewports.
|
||||||
|
|
||||||
|
//------------------------------------------------------------------
|
||||||
|
// Functions
|
||||||
|
//------------------------------------------------------------------
|
||||||
};
|
};
|
||||||
|
CIMGUI_API void ImGuiPlatformIO_ClearPlatformHandlers(ImGuiPlatformIO* self); // Clear all Platform_XXX fields. Typically called on Platform Backend shutdown.
|
||||||
|
CIMGUI_API void ImGuiPlatformIO_ClearRendererHandlers(ImGuiPlatformIO* self); // Clear all Renderer_XXX fields. Typically called on Renderer Backend shutdown.
|
||||||
|
|
||||||
// (Optional) This is required when enabling multi-viewport. Represent the bounds of each connected monitor/display and their DPI.
|
// (Optional) This is required when enabling multi-viewport. Represent the bounds of each connected monitor/display and their DPI.
|
||||||
// We use this information for multiple DPI support + clamping the position of popups and tooltips so they don't straddle multiple monitors.
|
// We use this information for multiple DPI support + clamping the position of popups and tooltips so they don't straddle multiple monitors.
|
||||||
|
|
@ -4231,10 +4266,10 @@ CIMGUI_API bool ImGui_ComboObsolete(const char* label, int* current_item, bool
|
||||||
CIMGUI_API bool ImGui_ComboObsoleteEx(const char* label, int* current_item, bool (*old_callback)(void* user_data, int idx, const char** out_text), void* user_data, int items_count, int popup_max_height_in_items /* = -1 */);
|
CIMGUI_API bool ImGui_ComboObsoleteEx(const char* label, int* current_item, bool (*old_callback)(void* user_data, int idx, const char** out_text), void* user_data, int items_count, int popup_max_height_in_items /* = -1 */);
|
||||||
CIMGUI_API bool ImGui_ListBoxObsolete(const char* label, int* current_item, bool (*old_callback)(void* user_data, int idx, const char** out_text), void* user_data, int items_count); // Implied height_in_items = -1
|
CIMGUI_API bool ImGui_ListBoxObsolete(const char* label, int* current_item, bool (*old_callback)(void* user_data, int idx, const char** out_text), void* user_data, int items_count); // Implied height_in_items = -1
|
||||||
CIMGUI_API bool ImGui_ListBoxObsoleteEx(const char* label, int* current_item, bool (*old_callback)(void* user_data, int idx, const char** out_text), void* user_data, int items_count, int height_in_items /* = -1 */);
|
CIMGUI_API bool ImGui_ListBoxObsoleteEx(const char* label, int* current_item, bool (*old_callback)(void* user_data, int idx, const char** out_text), void* user_data, int items_count, int height_in_items /* = -1 */);
|
||||||
// OBSOLETED in 1.89.7 (from June 2023)
|
|
||||||
CIMGUI_API void ImGui_SetItemAllowOverlap(void); // Use SetNextItemAllowOverlap() before item.
|
|
||||||
|
|
||||||
// Some of the older obsolete names along with their replacement (commented out so they are not reported in IDE)
|
// Some of the older obsolete names along with their replacement (commented out so they are not reported in IDE)
|
||||||
|
// OBSOLETED in 1.89.7 (from June 2023)
|
||||||
|
//IMGUI_API void SetItemAllowOverlap(); // Use SetNextItemAllowOverlap() _before_ item.
|
||||||
//-- OBSOLETED in 1.89.4 (from March 2023)
|
//-- OBSOLETED in 1.89.4 (from March 2023)
|
||||||
//static inline void PushAllowKeyboardFocus(bool tab_stop) { PushItemFlag(ImGuiItemFlags_NoTabStop, !tab_stop); }
|
//static inline void PushAllowKeyboardFocus(bool tab_stop) { PushItemFlag(ImGuiItemFlags_NoTabStop, !tab_stop); }
|
||||||
//static inline void PopAllowKeyboardFocus() { PopItemFlag(); }
|
//static inline void PopAllowKeyboardFocus() { PopItemFlag(); }
|
||||||
|
|
@ -4299,7 +4334,7 @@ CIMGUI_API void ImGui_SetItemAllowOverlap(void);
|
||||||
//static inline float GetWindowFontSize() { return GetFontSize(); } // OBSOLETED in 1.48
|
//static inline float GetWindowFontSize() { return GetFontSize(); } // OBSOLETED in 1.48
|
||||||
//static inline void SetScrollPosHere() { SetScrollHere(); } // OBSOLETED in 1.42
|
//static inline void SetScrollPosHere() { SetScrollHere(); } // OBSOLETED in 1.42
|
||||||
|
|
||||||
//-- OBSOLETED in 1.92.x: ImFontAtlasCustomRect becomes ImTextureRect
|
//-- OBSOLETED in 1.92.0: ImFontAtlasCustomRect becomes ImTextureRect
|
||||||
// - ImFontAtlasCustomRect::X,Y --> ImTextureRect::x,y
|
// - ImFontAtlasCustomRect::X,Y --> ImTextureRect::x,y
|
||||||
// - ImFontAtlasCustomRect::Width,Height --> ImTextureRect::w,h
|
// - ImFontAtlasCustomRect::Width,Height --> ImTextureRect::w,h
|
||||||
// - ImFontAtlasCustomRect::GlyphColored --> if you need to write to this, instead you can write to 'font->Glyphs.back()->Colored' after calling AddCustomRectFontGlyph()
|
// - ImFontAtlasCustomRect::GlyphColored --> if you need to write to this, instead you can write to 'font->Glyphs.back()->Colored' after calling AddCustomRectFontGlyph()
|
||||||
|
|
@ -4335,7 +4370,7 @@ typedef ImFontAtlasRect ImFontAtlasCustomRect;
|
||||||
//};
|
//};
|
||||||
|
|
||||||
// RENAMED and MERGED both ImGuiKey_ModXXX and ImGuiModFlags_XXX into ImGuiMod_XXX (from September 2022)
|
// RENAMED and MERGED both ImGuiKey_ModXXX and ImGuiModFlags_XXX into ImGuiMod_XXX (from September 2022)
|
||||||
// RENAMED ImGuiKeyModFlags -> ImGuiModFlags in 1.88 (from April 2022). Exceptionally commented out ahead of obscolescence schedule to reduce confusion and because they were not meant to be used in the first place.
|
// RENAMED ImGuiKeyModFlags -> ImGuiModFlags in 1.88 (from April 2022). Exceptionally commented out ahead of obsolescence schedule to reduce confusion and because they were not meant to be used in the first place.
|
||||||
//typedef ImGuiKeyChord ImGuiModFlags; // == int. We generally use ImGuiKeyChord to mean "a ImGuiKey or-ed with any number of ImGuiMod_XXX value", so you may store mods in there.
|
//typedef ImGuiKeyChord ImGuiModFlags; // == int. We generally use ImGuiKeyChord to mean "a ImGuiKey or-ed with any number of ImGuiMod_XXX value", so you may store mods in there.
|
||||||
//enum ImGuiModFlags_ { ImGuiModFlags_None = 0, ImGuiModFlags_Ctrl = ImGuiMod_Ctrl, ImGuiModFlags_Shift = ImGuiMod_Shift, ImGuiModFlags_Alt = ImGuiMod_Alt, ImGuiModFlags_Super = ImGuiMod_Super };
|
//enum ImGuiModFlags_ { ImGuiModFlags_None = 0, ImGuiModFlags_Ctrl = ImGuiMod_Ctrl, ImGuiModFlags_Shift = ImGuiMod_Shift, ImGuiModFlags_Alt = ImGuiMod_Alt, ImGuiModFlags_Super = ImGuiMod_Super };
|
||||||
//typedef ImGuiKeyChord ImGuiKeyModFlags; // == int
|
//typedef ImGuiKeyChord ImGuiKeyModFlags; // == int
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load diff
|
|
@ -49,9 +49,14 @@ CIMGUI_IMPL_API void cimgui::cImGui_ImplVulkan_SetMinImageCount(uint32_t min_ima
|
||||||
::ImGui_ImplVulkan_SetMinImageCount(min_image_count);
|
::ImGui_ImplVulkan_SetMinImageCount(min_image_count);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_IMPL_API void cimgui::cImGui_ImplVulkan_UpdateTexture(ImTextureData* tex)
|
CIMGUI_IMPL_API void cimgui::cImGui_ImplVulkan_CreateMainPipeline(const cimgui::ImGui_ImplVulkan_PipelineInfo* info)
|
||||||
{
|
{
|
||||||
// NOTE(mason): fixed this binding by hand
|
// NOTE(mason): fixed this binding by hand
|
||||||
|
::ImGui_ImplVulkan_CreateMainPipeline(reinterpret_cast<const ::ImGui_ImplVulkan_PipelineInfo*>(info));
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_IMPL_API void cimgui::cImGui_ImplVulkan_UpdateTexture(ImTextureData* tex)
|
||||||
|
{
|
||||||
::ImGui_ImplVulkan_UpdateTexture(reinterpret_cast<::ImTextureData*>(tex));
|
::ImGui_ImplVulkan_UpdateTexture(reinterpret_cast<::ImTextureData*>(tex));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -75,39 +80,44 @@ CIMGUI_IMPL_API bool cimgui::cImGui_ImplVulkan_LoadFunctionsEx(uint32_t api_vers
|
||||||
return ::ImGui_ImplVulkan_LoadFunctions(api_version, loader_func, user_data);
|
return ::ImGui_ImplVulkan_LoadFunctions(api_version, loader_func, user_data);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_IMPL_API void cimgui::cImGui_ImplVulkanH_CreateOrResizeWindow(VkInstance instance, VkPhysicalDevice physical_device, VkDevice device, cimgui::ImGui_ImplVulkanH_Window* wd, uint32_t queue_family, const VkAllocationCallbacks* allocator, int w, int h, uint32_t min_image_count)
|
CIMGUI_IMPL_API void cimgui::cImGui_ImplVulkanH_CreateOrResizeWindow(VkInstance instance, VkPhysicalDevice physical_device, VkDevice device, cimgui::ImGui_ImplVulkanH_Window* wd, uint32_t queue_family, const VkAllocationCallbacks* allocator, int w, int h, uint32_t min_image_count, VkImageUsageFlags image_usage)
|
||||||
{
|
{
|
||||||
::ImGui_ImplVulkanH_CreateOrResizeWindow(instance, physical_device, device, reinterpret_cast<::ImGui_ImplVulkanH_Window*>(wd), queue_family, allocator, w, h, min_image_count);
|
::ImGui_ImplVulkanH_CreateOrResizeWindow(instance, physical_device, device, reinterpret_cast<::ImGui_ImplVulkanH_Window*>(wd), queue_family, allocator, w, h, min_image_count, image_usage);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_IMPL_API void cimgui::cImGui_ImplVulkanH_DestroyWindow(VkInstance instance, VkDevice device, cimgui::ImGui_ImplVulkanH_Window* wd, const VkAllocationCallbacks* allocator)
|
CIMGUI_IMPL_API void cimgui::cImGui_ImplVulkanH_DestroyWindow(VkInstance instance, VkDevice device, cimgui::ImGui_ImplVulkanH_Window* wd, const VkAllocationCallbacks* allocator)
|
||||||
{
|
{
|
||||||
::ImGui_ImplVulkanH_DestroyWindow(instance, device, reinterpret_cast<::ImGui_ImplVulkanH_Window*>(wd), allocator);
|
::ImGui_ImplVulkanH_DestroyWindow(instance, device, reinterpret_cast<::ImGui_ImplVulkanH_Window*>(wd), allocator);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_IMPL_API VkSurfaceFormatKHR cimgui::cImGui_ImplVulkanH_SelectSurfaceFormat(VkPhysicalDevice physical_device, VkSurfaceKHR surface, const VkFormat* request_formats, int request_formats_count, VkColorSpaceKHR request_color_space)
|
CIMGUI_IMPL_API VkSurfaceFormatKHR cimgui::cImGui_ImplVulkanH_SelectSurfaceFormat(VkPhysicalDevice physical_device, VkSurfaceKHR surface, const VkFormat* request_formats, int request_formats_count, VkColorSpaceKHR request_color_space)
|
||||||
{
|
{
|
||||||
return ::ImGui_ImplVulkanH_SelectSurfaceFormat(physical_device, surface, request_formats, request_formats_count, request_color_space);
|
return ::ImGui_ImplVulkanH_SelectSurfaceFormat(physical_device, surface, request_formats, request_formats_count, request_color_space);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_IMPL_API VkPresentModeKHR cimgui::cImGui_ImplVulkanH_SelectPresentMode(VkPhysicalDevice physical_device, VkSurfaceKHR surface, const VkPresentModeKHR* request_modes, int request_modes_count)
|
CIMGUI_IMPL_API VkPresentModeKHR cimgui::cImGui_ImplVulkanH_SelectPresentMode(VkPhysicalDevice physical_device, VkSurfaceKHR surface, const VkPresentModeKHR* request_modes, int request_modes_count)
|
||||||
{
|
{
|
||||||
return ::ImGui_ImplVulkanH_SelectPresentMode(physical_device, surface, request_modes, request_modes_count);
|
return ::ImGui_ImplVulkanH_SelectPresentMode(physical_device, surface, request_modes, request_modes_count);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_IMPL_API VkPhysicalDevice cimgui::cImGui_ImplVulkanH_SelectPhysicalDevice(VkInstance instance)
|
CIMGUI_IMPL_API VkPhysicalDevice cimgui::cImGui_ImplVulkanH_SelectPhysicalDevice(VkInstance instance)
|
||||||
{
|
{
|
||||||
return ::ImGui_ImplVulkanH_SelectPhysicalDevice(instance);
|
return ::ImGui_ImplVulkanH_SelectPhysicalDevice(instance);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_IMPL_API uint32_t cimgui::cImGui_ImplVulkanH_SelectQueueFamilyIndex(VkPhysicalDevice physical_device)
|
CIMGUI_IMPL_API uint32_t cimgui::cImGui_ImplVulkanH_SelectQueueFamilyIndex(VkPhysicalDevice physical_device)
|
||||||
{
|
{
|
||||||
return ::ImGui_ImplVulkanH_SelectQueueFamilyIndex(physical_device);
|
return ::ImGui_ImplVulkanH_SelectQueueFamilyIndex(physical_device);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_IMPL_API int cimgui::cImGui_ImplVulkanH_GetMinImageCountFromPresentMode(VkPresentModeKHR present_mode)
|
CIMGUI_IMPL_API int cimgui::cImGui_ImplVulkanH_GetMinImageCountFromPresentMode(VkPresentModeKHR present_mode)
|
||||||
{
|
{
|
||||||
return ::ImGui_ImplVulkanH_GetMinImageCountFromPresentMode(present_mode);
|
return ::ImGui_ImplVulkanH_GetMinImageCountFromPresentMode(present_mode);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_IMPL_API cimgui::ImGui_ImplVulkanH_Window* cimgui::cImGui_ImplVulkanH_GetWindowDataFromViewport(ImGuiViewport* viewport)
|
||||||
|
{
|
||||||
|
return reinterpret_cast<::cimgui::ImGui_ImplVulkanH_Window*>(::ImGui_ImplVulkanH_GetWindowDataFromViewport(reinterpret_cast<::ImGuiViewport*>(viewport)));
|
||||||
|
}
|
||||||
|
|
||||||
#endif // #ifndef IMGUI_DISABLE
|
#endif // #ifndef IMGUI_DISABLE
|
||||||
|
|
|
||||||
|
|
@ -31,6 +31,7 @@
|
||||||
// Read comments in imgui_impl_vulkan.h.
|
// Read comments in imgui_impl_vulkan.h.
|
||||||
|
|
||||||
// Auto-generated forward declarations for C header
|
// Auto-generated forward declarations for C header
|
||||||
|
typedef struct ImGui_ImplVulkan_PipelineInfo_t ImGui_ImplVulkan_PipelineInfo;
|
||||||
typedef struct ImGui_ImplVulkan_InitInfo_t ImGui_ImplVulkan_InitInfo;
|
typedef struct ImGui_ImplVulkan_InitInfo_t ImGui_ImplVulkan_InitInfo;
|
||||||
typedef struct ImGui_ImplVulkan_RenderState_t ImGui_ImplVulkan_RenderState;
|
typedef struct ImGui_ImplVulkan_RenderState_t ImGui_ImplVulkan_RenderState;
|
||||||
typedef struct ImGui_ImplVulkanH_FrameSemaphores_t ImGui_ImplVulkanH_FrameSemaphores;
|
typedef struct ImGui_ImplVulkanH_FrameSemaphores_t ImGui_ImplVulkanH_FrameSemaphores;
|
||||||
|
|
@ -54,9 +55,14 @@ extern "C"
|
||||||
// If you have no idea what this is, leave it alone!
|
// If you have no idea what this is, leave it alone!
|
||||||
//#define IMGUI_IMPL_VULKAN_NO_PROTOTYPES
|
//#define IMGUI_IMPL_VULKAN_NO_PROTOTYPES
|
||||||
|
|
||||||
// Convenience support for Volk
|
// [Configuration] Convenience support for Volk
|
||||||
// (you can also technically use IMGUI_IMPL_VULKAN_NO_PROTOTYPES + wrap Volk via ImGui_ImplVulkan_LoadFunctions().)
|
// (you can also technically use IMGUI_IMPL_VULKAN_NO_PROTOTYPES + wrap Volk via ImGui_ImplVulkan_LoadFunctions().)
|
||||||
|
// (When using Volk from directory outside your include directories list you can specify full path to the volk.h header,
|
||||||
|
// for example when using Volk from VulkanSDK and using include_directories(${Vulkan_INCLUDE_DIRS})' from 'find_package(Vulkan REQUIRED)')
|
||||||
//#define IMGUI_IMPL_VULKAN_USE_VOLK
|
//#define IMGUI_IMPL_VULKAN_USE_VOLK
|
||||||
|
//#define IMGUI_IMPL_VULKAN_VOLK_FILENAME <Volk/volk.h>
|
||||||
|
//#define IMGUI_IMPL_VULKAN_VOLK_FILENAME <volk.h> // Default
|
||||||
|
// Reminder: make those changes in your imconfig.h file, not here!
|
||||||
|
|
||||||
#if defined(IMGUI_IMPL_VULKAN_NO_PROTOTYPES)&&!defined(VK_NO_PROTOTYPES)
|
#if defined(IMGUI_IMPL_VULKAN_NO_PROTOTYPES)&&!defined(VK_NO_PROTOTYPES)
|
||||||
#define VK_NO_PROTOTYPES
|
#define VK_NO_PROTOTYPES
|
||||||
|
|
@ -66,7 +72,11 @@ extern "C"
|
||||||
#endif // #if defined(VK_USE_PLATFORM_WIN32_KHR)&&!defined(NOMINMAX)
|
#endif // #if defined(VK_USE_PLATFORM_WIN32_KHR)&&!defined(NOMINMAX)
|
||||||
// Vulkan includes
|
// Vulkan includes
|
||||||
#ifdef IMGUI_IMPL_VULKAN_USE_VOLK
|
#ifdef IMGUI_IMPL_VULKAN_USE_VOLK
|
||||||
|
#ifdef IMGUI_IMPL_VULKAN_VOLK_FILENAME
|
||||||
|
#include IMGUI_IMPL_VULKAN_VOLK_FILENAME
|
||||||
|
#else
|
||||||
#include <volk.h>
|
#include <volk.h>
|
||||||
|
#endif // #ifdef IMGUI_IMPL_VULKAN_VOLK_FILENAME
|
||||||
#else
|
#else
|
||||||
#include <vulkan/vulkan.h>
|
#include <vulkan/vulkan.h>
|
||||||
#endif // #ifdef IMGUI_IMPL_VULKAN_USE_VOLK
|
#endif // #ifdef IMGUI_IMPL_VULKAN_USE_VOLK
|
||||||
|
|
@ -76,6 +86,22 @@ extern "C"
|
||||||
// Backend uses a small number of descriptors per font atlas + as many as additional calls done to ImGui_ImplVulkan_AddTexture().
|
// Backend uses a small number of descriptors per font atlas + as many as additional calls done to ImGui_ImplVulkan_AddTexture().
|
||||||
#define IMGUI_IMPL_VULKAN_MINIMUM_IMAGE_SAMPLER_POOL_SIZE (8) // Minimum per atlas
|
#define IMGUI_IMPL_VULKAN_MINIMUM_IMAGE_SAMPLER_POOL_SIZE (8) // Minimum per atlas
|
||||||
|
|
||||||
|
// Specify settings to create pipeline and swapchain
|
||||||
|
struct ImGui_ImplVulkan_PipelineInfo_t
|
||||||
|
{
|
||||||
|
// For Main viewport only
|
||||||
|
VkRenderPass RenderPass; // Ignored if using dynamic rendering
|
||||||
|
|
||||||
|
// For Main and Secondary viewports
|
||||||
|
uint32_t Subpass; //
|
||||||
|
VkSampleCountFlagBits MSAASamples /* = {} */; // 0 defaults to VK_SAMPLE_COUNT_1_BIT
|
||||||
|
#ifdef IMGUI_IMPL_VULKAN_HAS_DYNAMIC_RENDERING
|
||||||
|
VkPipelineRenderingCreateInfoKHR PipelineRenderingCreateInfo; // Optional, valid if .sType == VK_STRUCTURE_TYPE_PIPELINE_RENDERING_CREATE_INFO_KHR
|
||||||
|
#endif // #ifdef IMGUI_IMPL_VULKAN_HAS_DYNAMIC_RENDERING
|
||||||
|
// For Secondary viewports only (created/managed by backend)
|
||||||
|
VkImageUsageFlags SwapChainImageUsage; // Extra flags for vkCreateSwapchainKHR() calls for secondary viewports. We automatically add VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT. You can add e.g. VK_IMAGE_USAGE_TRANSFER_SRC_BIT if you need to capture from viewports.
|
||||||
|
};
|
||||||
|
|
||||||
// Initialization data, for ImGui_ImplVulkan_Init()
|
// Initialization data, for ImGui_ImplVulkan_Init()
|
||||||
// [Please zero-clear before use!]
|
// [Please zero-clear before use!]
|
||||||
// - About descriptor pool:
|
// - About descriptor pool:
|
||||||
|
|
@ -83,38 +109,43 @@ extern "C"
|
||||||
// and must contain a pool size large enough to hold a small number of VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER descriptors.
|
// and must contain a pool size large enough to hold a small number of VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER descriptors.
|
||||||
// - As an convenience, by setting DescriptorPoolSize > 0 the backend will create one for you.
|
// - As an convenience, by setting DescriptorPoolSize > 0 the backend will create one for you.
|
||||||
// - About dynamic rendering:
|
// - About dynamic rendering:
|
||||||
// - When using dynamic rendering, set UseDynamicRendering=true and fill PipelineRenderingCreateInfo structure.
|
// - When using dynamic rendering, set UseDynamicRendering=true + fill PipelineInfoMain.PipelineRenderingCreateInfo structure.
|
||||||
struct ImGui_ImplVulkan_InitInfo_t
|
struct ImGui_ImplVulkan_InitInfo_t
|
||||||
{
|
{
|
||||||
uint32_t ApiVersion; // Fill with API version of Instance, e.g. VK_API_VERSION_1_3 or your value of VkApplicationInfo::apiVersion. May be lower than header version (VK_HEADER_VERSION_COMPLETE)
|
uint32_t ApiVersion; // Fill with API version of Instance, e.g. VK_API_VERSION_1_3 or your value of VkApplicationInfo::apiVersion. May be lower than header version (VK_HEADER_VERSION_COMPLETE)
|
||||||
VkInstance Instance;
|
VkInstance Instance;
|
||||||
VkPhysicalDevice PhysicalDevice;
|
VkPhysicalDevice PhysicalDevice;
|
||||||
VkDevice Device;
|
VkDevice Device;
|
||||||
uint32_t QueueFamily;
|
uint32_t QueueFamily;
|
||||||
VkQueue Queue;
|
VkQueue Queue;
|
||||||
VkDescriptorPool DescriptorPool; // See requirements in note above; ignored if using DescriptorPoolSize > 0
|
VkDescriptorPool DescriptorPool; // See requirements in note above; ignored if using DescriptorPoolSize > 0
|
||||||
VkRenderPass RenderPass; // Ignored if using dynamic rendering
|
uint32_t DescriptorPoolSize; // Optional: set to create internal descriptor pool automatically instead of using DescriptorPool.
|
||||||
uint32_t MinImageCount; // >= 2
|
uint32_t MinImageCount; // >= 2
|
||||||
uint32_t ImageCount; // >= MinImageCount
|
uint32_t ImageCount; // >= MinImageCount
|
||||||
VkSampleCountFlagBits MSAASamples; // 0 defaults to VK_SAMPLE_COUNT_1_BIT
|
VkPipelineCache PipelineCache; // Optional
|
||||||
|
|
||||||
// (Optional)
|
// Pipeline
|
||||||
VkPipelineCache PipelineCache;
|
ImGui_ImplVulkan_PipelineInfo PipelineInfoMain; // Infos for Main Viewport (created by app/user)
|
||||||
uint32_t Subpass;
|
ImGui_ImplVulkan_PipelineInfo PipelineInfoForViewports; // Infos for Secondary Viewports (created by backend)
|
||||||
|
//VkRenderPass RenderPass; // --> Since 2025/09/26: set 'PipelineInfoMain.RenderPass' instead
|
||||||
// (Optional) Set to create internal descriptor pool instead of using DescriptorPool
|
//uint32_t Subpass; // --> Since 2025/09/26: set 'PipelineInfoMain.Subpass' instead
|
||||||
uint32_t DescriptorPoolSize;
|
//VkSampleCountFlagBits MSAASamples; // --> Since 2025/09/26: set 'PipelineInfoMain.MSAASamples' instead
|
||||||
|
//VkPipelineRenderingCreateInfoKHR PipelineRenderingCreateInfo; // Since 2025/09/26: set 'PipelineInfoMain.PipelineRenderingCreateInfo' instead
|
||||||
|
|
||||||
// (Optional) Dynamic Rendering
|
// (Optional) Dynamic Rendering
|
||||||
// Need to explicitly enable VK_KHR_dynamic_rendering extension to use this, even for Vulkan 1.3.
|
// Need to explicitly enable VK_KHR_dynamic_rendering extension to use this, even for Vulkan 1.3 + setup PipelineInfoMain.PipelineRenderingCreateInfo and PipelineInfoViewports.PipelineRenderingCreateInfo.
|
||||||
bool UseDynamicRendering;
|
bool UseDynamicRendering;
|
||||||
#ifdef IMGUI_IMPL_VULKAN_HAS_DYNAMIC_RENDERING
|
|
||||||
VkPipelineRenderingCreateInfoKHR PipelineRenderingCreateInfo;
|
|
||||||
#endif // #ifdef IMGUI_IMPL_VULKAN_HAS_DYNAMIC_RENDERING
|
|
||||||
// (Optional) Allocation, Debugging
|
// (Optional) Allocation, Debugging
|
||||||
const VkAllocationCallbacks* Allocator;
|
const VkAllocationCallbacks* Allocator;
|
||||||
void (*CheckVkResultFn)(VkResult err);
|
void (*CheckVkResultFn)(VkResult err);
|
||||||
VkDeviceSize MinAllocationSize; // Minimum allocation size. Set to 1024*1024 to satisfy zealous best practices validation layer and waste a little memory.
|
VkDeviceSize MinAllocationSize; // Minimum allocation size. Set to 1024*1024 to satisfy zealous best practices validation layer and waste a little memory.
|
||||||
|
|
||||||
|
// (Optional) Customize default vertex/fragment shaders.
|
||||||
|
// - if .sType == VK_STRUCTURE_TYPE_SHADER_MODULE_CREATE_INFO we use specified structs, otherwise we use defaults.
|
||||||
|
// - Shader inputs/outputs need to match ours. Code/data pointed to by the structure needs to survive for whole during of backend usage.
|
||||||
|
VkShaderModuleCreateInfo CustomShaderVertCreateInfo;
|
||||||
|
VkShaderModuleCreateInfo CustomShaderFragCreateInfo;
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef struct ImDrawData_t ImDrawData;
|
typedef struct ImDrawData_t ImDrawData;
|
||||||
|
|
@ -126,6 +157,11 @@ CIMGUI_IMPL_API void cImGui_ImplVulkan_RenderDrawData(ImDrawData* draw_data, VkC
|
||||||
CIMGUI_IMPL_API void cImGui_ImplVulkan_RenderDrawDataEx(ImDrawData* draw_data, VkCommandBuffer command_buffer, VkPipeline pipeline /* = VK_NULL_HANDLE */);
|
CIMGUI_IMPL_API void cImGui_ImplVulkan_RenderDrawDataEx(ImDrawData* draw_data, VkCommandBuffer command_buffer, VkPipeline pipeline /* = VK_NULL_HANDLE */);
|
||||||
CIMGUI_IMPL_API void cImGui_ImplVulkan_SetMinImageCount(uint32_t min_image_count); // To override MinImageCount after initialization (e.g. if swap chain is recreated)
|
CIMGUI_IMPL_API void cImGui_ImplVulkan_SetMinImageCount(uint32_t min_image_count); // To override MinImageCount after initialization (e.g. if swap chain is recreated)
|
||||||
|
|
||||||
|
// (Advanced) Use e.g. if you need to recreate pipeline without reinitializing the backend (see #8110, #8111)
|
||||||
|
// The main window pipeline will be created by ImGui_ImplVulkan_Init() if possible (== RenderPass xor (UseDynamicRendering && PipelineRenderingCreateInfo->sType == VK_STRUCTURE_TYPE_PIPELINE_RENDERING_CREATE_INFO_KHR))
|
||||||
|
// Else, the pipeline can be created, or re-created, using ImGui_ImplVulkan_CreateMainPipeline() before rendering.
|
||||||
|
CIMGUI_IMPL_API void cImGui_ImplVulkan_CreateMainPipeline(const ImGui_ImplVulkan_PipelineInfo* info);
|
||||||
|
|
||||||
// (Advanced) Use e.g. if you need to precisely control the timing of texture updates (e.g. for staged rendering), by setting ImDrawData::Textures = NULL to handle this manually.
|
// (Advanced) Use e.g. if you need to precisely control the timing of texture updates (e.g. for staged rendering), by setting ImDrawData::Textures = NULL to handle this manually.
|
||||||
CIMGUI_IMPL_API void cImGui_ImplVulkan_UpdateTexture(ImTextureData* tex);
|
CIMGUI_IMPL_API void cImGui_ImplVulkan_UpdateTexture(ImTextureData* tex);
|
||||||
|
|
||||||
|
|
@ -164,25 +200,26 @@ struct ImGui_ImplVulkan_RenderState_t
|
||||||
//
|
//
|
||||||
// Your engine/app will likely _already_ have code to setup all that stuff (swap chain,
|
// Your engine/app will likely _already_ have code to setup all that stuff (swap chain,
|
||||||
// render pass, frame buffers, etc.). You may read this code if you are curious, but
|
// render pass, frame buffers, etc.). You may read this code if you are curious, but
|
||||||
// it is recommended you use you own custom tailored code to do equivalent work.
|
// it is recommended you use your own custom tailored code to do equivalent work.
|
||||||
//
|
//
|
||||||
// We don't provide a strong guarantee that we won't change those functions API.
|
// We don't provide a strong guarantee that we won't change those functions API.
|
||||||
//
|
//
|
||||||
// The ImGui_ImplVulkanH_XXX functions should NOT interact with any of the state used
|
// The ImGui_ImplVulkanH_XXX functions should NOT interact with any of the state used
|
||||||
// by the regular ImGui_ImplVulkan_XXX functions).
|
// by the regular ImGui_ImplVulkan_XXX functions.
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
|
|
||||||
typedef struct ImGui_ImplVulkanH_Frame_t ImGui_ImplVulkanH_Frame;
|
typedef struct ImGui_ImplVulkanH_Frame_t ImGui_ImplVulkanH_Frame;
|
||||||
typedef struct ImGui_ImplVulkanH_Window_t ImGui_ImplVulkanH_Window;
|
typedef struct ImGui_ImplVulkanH_Window_t ImGui_ImplVulkanH_Window;
|
||||||
|
|
||||||
// Helpers
|
// Helpers
|
||||||
CIMGUI_IMPL_API void cImGui_ImplVulkanH_CreateOrResizeWindow(VkInstance instance, VkPhysicalDevice physical_device, VkDevice device, ImGui_ImplVulkanH_Window* wd, uint32_t queue_family, const VkAllocationCallbacks* allocator, int w, int h, uint32_t min_image_count);
|
CIMGUI_IMPL_API void cImGui_ImplVulkanH_CreateOrResizeWindow(VkInstance instance, VkPhysicalDevice physical_device, VkDevice device, ImGui_ImplVulkanH_Window* wd, uint32_t queue_family, const VkAllocationCallbacks* allocator, int w, int h, uint32_t min_image_count, VkImageUsageFlags image_usage);
|
||||||
CIMGUI_IMPL_API void cImGui_ImplVulkanH_DestroyWindow(VkInstance instance, VkDevice device, ImGui_ImplVulkanH_Window* wd, const VkAllocationCallbacks* allocator);
|
CIMGUI_IMPL_API void cImGui_ImplVulkanH_DestroyWindow(VkInstance instance, VkDevice device, ImGui_ImplVulkanH_Window* wd, const VkAllocationCallbacks* allocator);
|
||||||
CIMGUI_IMPL_API VkSurfaceFormatKHR cImGui_ImplVulkanH_SelectSurfaceFormat(VkPhysicalDevice physical_device, VkSurfaceKHR surface, const VkFormat* request_formats, int request_formats_count, VkColorSpaceKHR request_color_space);
|
CIMGUI_IMPL_API VkSurfaceFormatKHR cImGui_ImplVulkanH_SelectSurfaceFormat(VkPhysicalDevice physical_device, VkSurfaceKHR surface, const VkFormat* request_formats, int request_formats_count, VkColorSpaceKHR request_color_space);
|
||||||
CIMGUI_IMPL_API VkPresentModeKHR cImGui_ImplVulkanH_SelectPresentMode(VkPhysicalDevice physical_device, VkSurfaceKHR surface, const VkPresentModeKHR* request_modes, int request_modes_count);
|
CIMGUI_IMPL_API VkPresentModeKHR cImGui_ImplVulkanH_SelectPresentMode(VkPhysicalDevice physical_device, VkSurfaceKHR surface, const VkPresentModeKHR* request_modes, int request_modes_count);
|
||||||
CIMGUI_IMPL_API VkPhysicalDevice cImGui_ImplVulkanH_SelectPhysicalDevice(VkInstance instance);
|
CIMGUI_IMPL_API VkPhysicalDevice cImGui_ImplVulkanH_SelectPhysicalDevice(VkInstance instance);
|
||||||
CIMGUI_IMPL_API uint32_t cImGui_ImplVulkanH_SelectQueueFamilyIndex(VkPhysicalDevice physical_device);
|
CIMGUI_IMPL_API uint32_t cImGui_ImplVulkanH_SelectQueueFamilyIndex(VkPhysicalDevice physical_device);
|
||||||
CIMGUI_IMPL_API int cImGui_ImplVulkanH_GetMinImageCountFromPresentMode(VkPresentModeKHR present_mode);
|
CIMGUI_IMPL_API int cImGui_ImplVulkanH_GetMinImageCountFromPresentMode(VkPresentModeKHR present_mode);
|
||||||
|
CIMGUI_IMPL_API ImGui_ImplVulkanH_Window* cImGui_ImplVulkanH_GetWindowDataFromViewport(ImGuiViewport* viewport); // Access to Vulkan objects associated with a viewport (e.g to export a screenshot)
|
||||||
|
|
||||||
// Helper structure to hold the data needed by one rendering frame
|
// Helper structure to hold the data needed by one rendering frame
|
||||||
// (Used by example's main.cpp. Used by multi-viewport features. Probably NOT used by your own engine/app.)
|
// (Used by example's main.cpp. Used by multi-viewport features. Probably NOT used by your own engine/app.)
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 50
|
"line": 55
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -25,7 +25,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 53
|
"line": 58
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -39,7 +39,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 63
|
"line": 72
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -51,13 +51,149 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 67
|
"line": 76
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"enums": [],
|
"enums": [],
|
||||||
"typedefs": [],
|
"typedefs": [],
|
||||||
"structs": [
|
"structs": [
|
||||||
|
{
|
||||||
|
"name": "ImGui_ImplVulkan_PipelineInfo",
|
||||||
|
"original_fully_qualified_name": "ImGui_ImplVulkan_PipelineInfo",
|
||||||
|
"kind": "struct",
|
||||||
|
"by_value": false,
|
||||||
|
"forward_declaration": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"fields": [
|
||||||
|
{
|
||||||
|
"name": "RenderPass",
|
||||||
|
"is_array": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"type": {
|
||||||
|
"declaration": "VkRenderPass",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "VkRenderPass"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"comments": {
|
||||||
|
"preceding": [
|
||||||
|
"// For Main viewport only"
|
||||||
|
],
|
||||||
|
"attached": "// Ignored if using dynamic rendering"
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 82
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Subpass",
|
||||||
|
"is_array": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"type": {
|
||||||
|
"declaration": "uint32_t",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "uint32_t"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"comments": {
|
||||||
|
"preceding": [
|
||||||
|
"// For Main and Secondary viewports"
|
||||||
|
],
|
||||||
|
"attached": "//"
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 85
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "MSAASamples",
|
||||||
|
"is_array": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"type": {
|
||||||
|
"declaration": "VkSampleCountFlagBits",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "VkSampleCountFlagBits"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"default_value": "{}",
|
||||||
|
"comments": {
|
||||||
|
"attached": "// 0 defaults to VK_SAMPLE_COUNT_1_BIT"
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 86
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "PipelineRenderingCreateInfo",
|
||||||
|
"is_array": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"type": {
|
||||||
|
"declaration": "VkPipelineRenderingCreateInfoKHR",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "VkPipelineRenderingCreateInfoKHR"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"comments": {
|
||||||
|
"attached": "// Optional, valid if .sType == VK_STRUCTURE_TYPE_PIPELINE_RENDERING_CREATE_INFO_KHR"
|
||||||
|
},
|
||||||
|
"conditionals": [
|
||||||
|
{
|
||||||
|
"condition": "ifdef",
|
||||||
|
"expression": "IMGUI_IMPL_VULKAN_HAS_DYNAMIC_RENDERING"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 88
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "SwapChainImageUsage",
|
||||||
|
"is_array": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"type": {
|
||||||
|
"declaration": "VkImageUsageFlags",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "VkImageUsageFlags"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"comments": {
|
||||||
|
"preceding": [
|
||||||
|
"// For Secondary viewports only (created/managed by backend)"
|
||||||
|
],
|
||||||
|
"attached": "// Extra flags for vkCreateSwapchainKHR() calls for secondary viewports. We automatically add VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT. You can add e.g. VK_IMAGE_USAGE_TRANSFER_SRC_BIT if you need to capture from viewports."
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 92
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"comments": {
|
||||||
|
"preceding": [
|
||||||
|
"// Specify settings to create pipeline and swapchain"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 79
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "ImGui_ImplVulkan_InitInfo",
|
"name": "ImGui_ImplVulkan_InitInfo",
|
||||||
"original_fully_qualified_name": "ImGui_ImplVulkan_InitInfo",
|
"original_fully_qualified_name": "ImGui_ImplVulkan_InitInfo",
|
||||||
|
|
@ -83,7 +219,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 79
|
"line": 105
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -100,7 +236,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 80
|
"line": 106
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -117,7 +253,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 81
|
"line": 107
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -134,7 +270,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 82
|
"line": 108
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -151,7 +287,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 83
|
"line": 109
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -168,7 +304,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 84
|
"line": 110
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -188,27 +324,27 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 85
|
"line": 111
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "RenderPass",
|
"name": "DescriptorPoolSize",
|
||||||
"is_array": false,
|
"is_array": false,
|
||||||
"is_anonymous": false,
|
"is_anonymous": false,
|
||||||
"type": {
|
"type": {
|
||||||
"declaration": "VkRenderPass",
|
"declaration": "uint32_t",
|
||||||
"description": {
|
"description": {
|
||||||
"kind": "User",
|
"kind": "User",
|
||||||
"name": "VkRenderPass"
|
"name": "uint32_t"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"comments": {
|
"comments": {
|
||||||
"attached": "// Ignored if using dynamic rendering"
|
"attached": "// Optional: set to create internal descriptor pool automatically instead of using DescriptorPool."
|
||||||
},
|
},
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 86
|
"line": 112
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -228,7 +364,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 87
|
"line": 113
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -248,27 +384,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 88
|
"line": 114
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "MSAASamples",
|
|
||||||
"is_array": false,
|
|
||||||
"is_anonymous": false,
|
|
||||||
"type": {
|
|
||||||
"declaration": "VkSampleCountFlagBits",
|
|
||||||
"description": {
|
|
||||||
"kind": "User",
|
|
||||||
"name": "VkSampleCountFlagBits"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"comments": {
|
|
||||||
"attached": "// 0 defaults to VK_SAMPLE_COUNT_1_BIT"
|
|
||||||
},
|
|
||||||
"is_internal": false,
|
|
||||||
"source_location": {
|
|
||||||
"filename": "imgui_impl_vulkan.h",
|
|
||||||
"line": 89
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -283,53 +399,55 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"comments": {
|
"comments": {
|
||||||
"preceding": [
|
"attached": "// Optional"
|
||||||
"// (Optional)"
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 92
|
"line": 115
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "Subpass",
|
"name": "PipelineInfoMain",
|
||||||
"is_array": false,
|
"is_array": false,
|
||||||
"is_anonymous": false,
|
"is_anonymous": false,
|
||||||
"type": {
|
"type": {
|
||||||
"declaration": "uint32_t",
|
"declaration": "ImGui_ImplVulkan_PipelineInfo",
|
||||||
"description": {
|
"description": {
|
||||||
"kind": "User",
|
"kind": "User",
|
||||||
"name": "uint32_t"
|
"name": "ImGui_ImplVulkan_PipelineInfo"
|
||||||
}
|
|
||||||
},
|
|
||||||
"is_internal": false,
|
|
||||||
"source_location": {
|
|
||||||
"filename": "imgui_impl_vulkan.h",
|
|
||||||
"line": 93
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "DescriptorPoolSize",
|
|
||||||
"is_array": false,
|
|
||||||
"is_anonymous": false,
|
|
||||||
"type": {
|
|
||||||
"declaration": "uint32_t",
|
|
||||||
"description": {
|
|
||||||
"kind": "User",
|
|
||||||
"name": "uint32_t"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"comments": {
|
"comments": {
|
||||||
"preceding": [
|
"preceding": [
|
||||||
"// (Optional) Set to create internal descriptor pool instead of using DescriptorPool"
|
"// Pipeline"
|
||||||
]
|
],
|
||||||
|
"attached": "// Infos for Main Viewport (created by app/user)"
|
||||||
},
|
},
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 96
|
"line": 118
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "PipelineInfoForViewports",
|
||||||
|
"is_array": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"type": {
|
||||||
|
"declaration": "ImGui_ImplVulkan_PipelineInfo",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "ImGui_ImplVulkan_PipelineInfo"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"comments": {
|
||||||
|
"attached": "// Infos for Secondary Viewports (created by backend)"
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 119
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -346,36 +464,13 @@
|
||||||
"comments": {
|
"comments": {
|
||||||
"preceding": [
|
"preceding": [
|
||||||
"// (Optional) Dynamic Rendering",
|
"// (Optional) Dynamic Rendering",
|
||||||
"// Need to explicitly enable VK_KHR_dynamic_rendering extension to use this, even for Vulkan 1.3."
|
"// Need to explicitly enable VK_KHR_dynamic_rendering extension to use this, even for Vulkan 1.3 + setup PipelineInfoMain.PipelineRenderingCreateInfo and PipelineInfoViewports.PipelineRenderingCreateInfo."
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 100
|
"line": 127
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "PipelineRenderingCreateInfo",
|
|
||||||
"is_array": false,
|
|
||||||
"is_anonymous": false,
|
|
||||||
"type": {
|
|
||||||
"declaration": "VkPipelineRenderingCreateInfoKHR",
|
|
||||||
"description": {
|
|
||||||
"kind": "User",
|
|
||||||
"name": "VkPipelineRenderingCreateInfoKHR"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"conditionals": [
|
|
||||||
{
|
|
||||||
"condition": "ifdef",
|
|
||||||
"expression": "IMGUI_IMPL_VULKAN_HAS_DYNAMIC_RENDERING"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"is_internal": false,
|
|
||||||
"source_location": {
|
|
||||||
"filename": "imgui_impl_vulkan.h",
|
|
||||||
"line": 102
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -403,7 +498,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 106
|
"line": 130
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -484,7 +579,48 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 108
|
"line": 132
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CustomShaderVertCreateInfo",
|
||||||
|
"is_array": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"type": {
|
||||||
|
"declaration": "VkShaderModuleCreateInfo",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "VkShaderModuleCreateInfo"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"comments": {
|
||||||
|
"preceding": [
|
||||||
|
"// (Optional) Customize default vertex/fragment shaders.",
|
||||||
|
"// - if .sType == VK_STRUCTURE_TYPE_SHADER_MODULE_CREATE_INFO we use specified structs, otherwise we use defaults.",
|
||||||
|
"// - Shader inputs/outputs need to match ours. Code/data pointed to by the structure needs to survive for whole during of backend usage."
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 137
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CustomShaderFragCreateInfo",
|
||||||
|
"is_array": false,
|
||||||
|
"is_anonymous": false,
|
||||||
|
"type": {
|
||||||
|
"declaration": "VkShaderModuleCreateInfo",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "VkShaderModuleCreateInfo"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 138
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
@ -497,13 +633,13 @@
|
||||||
"// and must contain a pool size large enough to hold a small number of VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER descriptors.",
|
"// and must contain a pool size large enough to hold a small number of VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER descriptors.",
|
||||||
"// - As an convenience, by setting DescriptorPoolSize > 0 the backend will create one for you.",
|
"// - As an convenience, by setting DescriptorPoolSize > 0 the backend will create one for you.",
|
||||||
"// - About dynamic rendering:",
|
"// - About dynamic rendering:",
|
||||||
"// - When using dynamic rendering, set UseDynamicRendering=true and fill PipelineRenderingCreateInfo structure."
|
"// - When using dynamic rendering, set UseDynamicRendering=true + fill PipelineInfoMain.PipelineRenderingCreateInfo structure."
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 77
|
"line": 103
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -542,7 +678,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 136
|
"line": 171
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -559,7 +695,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 137
|
"line": 172
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -576,7 +712,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 138
|
"line": 173
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
@ -590,7 +726,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 134
|
"line": 169
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -615,7 +751,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 180
|
"line": 216
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -632,7 +768,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 181
|
"line": 217
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -649,7 +785,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 182
|
"line": 218
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -666,7 +802,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 183
|
"line": 219
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -683,7 +819,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 184
|
"line": 220
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -700,7 +836,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 185
|
"line": 221
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
@ -714,7 +850,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 178
|
"line": 214
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -739,7 +875,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 190
|
"line": 226
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -756,14 +892,14 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 191
|
"line": 227
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 188
|
"line": 224
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -788,7 +924,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 198
|
"line": 234
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -805,7 +941,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 199
|
"line": 235
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -822,7 +958,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 200
|
"line": 236
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -839,7 +975,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 201
|
"line": 237
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -856,7 +992,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 202
|
"line": 238
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -873,7 +1009,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 203
|
"line": 239
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -890,7 +1026,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 204
|
"line": 240
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -907,7 +1043,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 205
|
"line": 241
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -924,7 +1060,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 206
|
"line": 242
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -941,7 +1077,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 207
|
"line": 243
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -961,7 +1097,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 208
|
"line": 244
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -981,7 +1117,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 209
|
"line": 245
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1001,7 +1137,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 210
|
"line": 246
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1021,7 +1157,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 211
|
"line": 247
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1038,7 +1174,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 212
|
"line": 248
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1055,7 +1191,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 213
|
"line": 249
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
@ -1068,7 +1204,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 196
|
"line": 232
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
@ -1115,7 +1251,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 112
|
"line": 142
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1138,7 +1274,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 113
|
"line": 143
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1161,7 +1297,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 114
|
"line": 144
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1217,7 +1353,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 115
|
"line": 145
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1284,7 +1420,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 115
|
"line": 145
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1324,7 +1460,57 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 116
|
"line": 146
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "cImGui_ImplVulkan_CreateMainPipeline",
|
||||||
|
"original_fully_qualified_name": "ImGui_ImplVulkan_CreateMainPipeline",
|
||||||
|
"return_type": {
|
||||||
|
"declaration": "void",
|
||||||
|
"description": {
|
||||||
|
"kind": "Builtin",
|
||||||
|
"builtin_type": "void"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"arguments": [
|
||||||
|
{
|
||||||
|
"name": "info",
|
||||||
|
"type": {
|
||||||
|
"declaration": "const ImGui_ImplVulkan_PipelineInfo*",
|
||||||
|
"description": {
|
||||||
|
"kind": "Pointer",
|
||||||
|
"inner_type": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "ImGui_ImplVulkan_PipelineInfo",
|
||||||
|
"storage_classes": [
|
||||||
|
"const"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"is_array": false,
|
||||||
|
"is_varargs": false,
|
||||||
|
"is_instance_pointer": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"is_default_argument_helper": false,
|
||||||
|
"is_manual_helper": false,
|
||||||
|
"is_imstr_helper": false,
|
||||||
|
"has_imstr_helper": false,
|
||||||
|
"is_unformatted_helper": false,
|
||||||
|
"is_static": false,
|
||||||
|
"comments": {
|
||||||
|
"preceding": [
|
||||||
|
"// (Advanced) Use e.g. if you need to recreate pipeline without reinitializing the backend (see #8110, #8111)",
|
||||||
|
"// The main window pipeline will be created by ImGui_ImplVulkan_Init() if possible (== RenderPass xor (UseDynamicRendering && PipelineRenderingCreateInfo->sType == VK_STRUCTURE_TYPE_PIPELINE_RENDERING_CREATE_INFO_KHR))",
|
||||||
|
"// Else, the pipeline can be created, or re-created, using ImGui_ImplVulkan_CreateMainPipeline() before rendering."
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 151
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1369,7 +1555,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 119
|
"line": 154
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1439,7 +1625,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 124
|
"line": 159
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1476,7 +1662,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 125
|
"line": 160
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1617,7 +1803,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 129
|
"line": 164
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1768,7 +1954,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 129
|
"line": 164
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -1907,6 +2093,19 @@
|
||||||
"is_array": false,
|
"is_array": false,
|
||||||
"is_varargs": false,
|
"is_varargs": false,
|
||||||
"is_instance_pointer": false
|
"is_instance_pointer": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "image_usage",
|
||||||
|
"type": {
|
||||||
|
"declaration": "VkImageUsageFlags",
|
||||||
|
"description": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "VkImageUsageFlags"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"is_array": false,
|
||||||
|
"is_varargs": false,
|
||||||
|
"is_instance_pointer": false
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"is_default_argument_helper": false,
|
"is_default_argument_helper": false,
|
||||||
|
|
@ -1923,7 +2122,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 167
|
"line": 202
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -2008,7 +2207,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 168
|
"line": 203
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -2103,7 +2302,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 169
|
"line": 204
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -2185,7 +2384,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 170
|
"line": 205
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -2222,7 +2421,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 171
|
"line": 206
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -2259,7 +2458,7 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 172
|
"line": 207
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -2296,7 +2495,53 @@
|
||||||
"is_internal": false,
|
"is_internal": false,
|
||||||
"source_location": {
|
"source_location": {
|
||||||
"filename": "imgui_impl_vulkan.h",
|
"filename": "imgui_impl_vulkan.h",
|
||||||
"line": 173
|
"line": 208
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "cImGui_ImplVulkanH_GetWindowDataFromViewport",
|
||||||
|
"original_fully_qualified_name": "ImGui_ImplVulkanH_GetWindowDataFromViewport",
|
||||||
|
"return_type": {
|
||||||
|
"declaration": "ImGui_ImplVulkanH_Window*",
|
||||||
|
"description": {
|
||||||
|
"kind": "Pointer",
|
||||||
|
"inner_type": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "ImGui_ImplVulkanH_Window"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"arguments": [
|
||||||
|
{
|
||||||
|
"name": "viewport",
|
||||||
|
"type": {
|
||||||
|
"declaration": "ImGuiViewport*",
|
||||||
|
"description": {
|
||||||
|
"kind": "Pointer",
|
||||||
|
"inner_type": {
|
||||||
|
"kind": "User",
|
||||||
|
"name": "ImGuiViewport"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"is_array": false,
|
||||||
|
"is_varargs": false,
|
||||||
|
"is_instance_pointer": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"is_default_argument_helper": false,
|
||||||
|
"is_manual_helper": false,
|
||||||
|
"is_imstr_helper": false,
|
||||||
|
"has_imstr_helper": false,
|
||||||
|
"is_unformatted_helper": false,
|
||||||
|
"is_static": false,
|
||||||
|
"comments": {
|
||||||
|
"attached": "// Access to Vulkan objects associated with a viewport (e.g to export a screenshot)"
|
||||||
|
},
|
||||||
|
"is_internal": false,
|
||||||
|
"source_location": {
|
||||||
|
"filename": "imgui_impl_vulkan.h",
|
||||||
|
"line": 209
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -187,26 +187,31 @@ static inline ::ImGuiListClipperRange ConvertToCPP_ImGuiListClipperRange(const c
|
||||||
|
|
||||||
#ifndef IMGUI_DISABLE
|
#ifndef IMGUI_DISABLE
|
||||||
|
|
||||||
CIMGUI_API ImGuiID cimgui::cImHashData(const void* data, size_t data_size)
|
CIMGUI_API ImGuiID cimgui::cImHashData(const void* data, size_t data_size)
|
||||||
{
|
{
|
||||||
return ::ImHashData(data, data_size);
|
return ::ImHashData(data, data_size);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API ImGuiID cimgui::cImHashDataEx(const void* data, size_t data_size, ImGuiID seed)
|
CIMGUI_API ImGuiID cimgui::cImHashDataEx(const void* data, size_t data_size, ImGuiID seed)
|
||||||
{
|
{
|
||||||
return ::ImHashData(data, data_size, seed);
|
return ::ImHashData(data, data_size, seed);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API ImGuiID cimgui::cImHashStr(const char* data)
|
CIMGUI_API ImGuiID cimgui::cImHashStr(const char* data)
|
||||||
{
|
{
|
||||||
return ::ImHashStr(data);
|
return ::ImHashStr(data);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API ImGuiID cimgui::cImHashStrEx(const char* data, size_t data_size, ImGuiID seed)
|
CIMGUI_API ImGuiID cimgui::cImHashStrEx(const char* data, size_t data_size, ImGuiID seed)
|
||||||
{
|
{
|
||||||
return ::ImHashStr(data, data_size, seed);
|
return ::ImHashStr(data, data_size, seed);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_API const char* cimgui::cImHashSkipUncontributingPrefix(const char* label)
|
||||||
|
{
|
||||||
|
return ::ImHashSkipUncontributingPrefix(label);
|
||||||
|
}
|
||||||
|
|
||||||
CIMGUI_API ImU32 cimgui::cImAlphaBlendColors(ImU32 col_a, ImU32 col_b)
|
CIMGUI_API ImU32 cimgui::cImAlphaBlendColors(ImU32 col_a, ImU32 col_b)
|
||||||
{
|
{
|
||||||
return ::ImAlphaBlendColors(col_a, col_b);
|
return ::ImAlphaBlendColors(col_a, col_b);
|
||||||
|
|
@ -414,9 +419,14 @@ CIMGUI_API int cimgui::cImTextCountUtf8BytesFromStr(const ImWchar* in_te
|
||||||
return ::ImTextCountUtf8BytesFromStr(in_text, in_text_end);
|
return ::ImTextCountUtf8BytesFromStr(in_text, in_text_end);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API const char* cimgui::cImTextFindPreviousUtf8Codepoint(const char* in_text_start, const char* in_text_curr)
|
CIMGUI_API const char* cimgui::cImTextFindPreviousUtf8Codepoint(const char* in_text_start, const char* in_p)
|
||||||
{
|
{
|
||||||
return ::ImTextFindPreviousUtf8Codepoint(in_text_start, in_text_curr);
|
return ::ImTextFindPreviousUtf8Codepoint(in_text_start, in_p);
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_API const char* cimgui::cImTextFindValidUtf8CodepointEnd(const char* in_text_start, const char* in_text_end, const char* in_p)
|
||||||
|
{
|
||||||
|
return ::ImTextFindValidUtf8CodepointEnd(in_text_start, in_text_end, in_p);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API int cimgui::cImTextCountLines(const char* in_text, const char* in_text_end)
|
CIMGUI_API int cimgui::cImTextCountLines(const char* in_text, const char* in_text_end)
|
||||||
|
|
@ -424,6 +434,21 @@ CIMGUI_API int cimgui::cImTextCountLines(const char* in_text, const char
|
||||||
return ::ImTextCountLines(in_text, in_text_end);
|
return ::ImTextCountLines(in_text, in_text_end);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_API cimgui::ImVec2 cimgui::cImFontCalcTextSizeEx(cimgui::ImFont* font, float size, float max_width, float wrap_width, const char* text_begin, const char* text_end_display, const char* text_end, const char** out_remaining, cimgui::ImVec2* out_offset, ImDrawTextFlags flags)
|
||||||
|
{
|
||||||
|
return ConvertFromCPP_ImVec2(::ImFontCalcTextSizeEx(reinterpret_cast<::ImFont*>(font), size, max_width, wrap_width, text_begin, text_end_display, text_end, out_remaining, reinterpret_cast<::ImVec2*>(out_offset), flags));
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_API const char* cimgui::cImFontCalcWordWrapPositionEx(cimgui::ImFont* font, float size, const char* text, const char* text_end, float wrap_width, ImDrawTextFlags flags)
|
||||||
|
{
|
||||||
|
return ::ImFontCalcWordWrapPositionEx(reinterpret_cast<::ImFont*>(font), size, text, text_end, wrap_width, flags);
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_API const char* cimgui::cImTextCalcWordWrapNextLineStart(const char* text, const char* text_end, ImDrawTextFlags flags)
|
||||||
|
{
|
||||||
|
return ::ImTextCalcWordWrapNextLineStart(text, text_end, flags);
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef IMGUI_DISABLE_FILE_FUNCTIONS
|
#ifdef IMGUI_DISABLE_FILE_FUNCTIONS
|
||||||
|
|
||||||
CIMGUI_API ImFileHandle cimgui::cImFileOpen(const char* __unnamed_arg0__, const char* __unnamed_arg1__)
|
CIMGUI_API ImFileHandle cimgui::cImFileOpen(const char* __unnamed_arg0__, const char* __unnamed_arg1__)
|
||||||
|
|
@ -989,77 +1014,82 @@ CIMGUI_API void cimgui::ImGuiInputTextDeactivatedState_ClearFreeMemory(cimgui::I
|
||||||
reinterpret_cast<::ImGuiInputTextDeactivatedState*>(self)->ClearFreeMemory();
|
reinterpret_cast<::ImGuiInputTextDeactivatedState*>(self)->ClearFreeMemory();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_ClearText(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API void cimgui::ImGuiInputTextState_ClearText(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->ClearText();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->ClearText();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_ClearFreeMemory(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API void cimgui::ImGuiInputTextState_ClearFreeMemory(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->ClearFreeMemory();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->ClearFreeMemory();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_OnKeyPressed(cimgui::ImGuiInputTextState* self, int key)
|
CIMGUI_API void cimgui::ImGuiInputTextState_OnKeyPressed(cimgui::ImGuiInputTextState* self, int key)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->OnKeyPressed(key);
|
reinterpret_cast<::ImGuiInputTextState*>(self)->OnKeyPressed(key);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_OnCharPressed(cimgui::ImGuiInputTextState* self, unsigned int c)
|
CIMGUI_API void cimgui::ImGuiInputTextState_OnCharPressed(cimgui::ImGuiInputTextState* self, unsigned int c)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->OnCharPressed(c);
|
reinterpret_cast<::ImGuiInputTextState*>(self)->OnCharPressed(c);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_CursorAnimReset(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API float cimgui::ImGuiInputTextState_GetPreferredOffsetX(const cimgui::ImGuiInputTextState* self)
|
||||||
|
{
|
||||||
|
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->GetPreferredOffsetX();
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_API void cimgui::ImGuiInputTextState_CursorAnimReset(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->CursorAnimReset();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->CursorAnimReset();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_CursorClamp(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API void cimgui::ImGuiInputTextState_CursorClamp(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->CursorClamp();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->CursorClamp();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API bool cimgui::ImGuiInputTextState_HasSelection(const cimgui::ImGuiInputTextState* self)
|
CIMGUI_API bool cimgui::ImGuiInputTextState_HasSelection(const cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->HasSelection();
|
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->HasSelection();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_ClearSelection(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API void cimgui::ImGuiInputTextState_ClearSelection(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->ClearSelection();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->ClearSelection();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API int cimgui::ImGuiInputTextState_GetCursorPos(const cimgui::ImGuiInputTextState* self)
|
CIMGUI_API int cimgui::ImGuiInputTextState_GetCursorPos(const cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->GetCursorPos();
|
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->GetCursorPos();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API int cimgui::ImGuiInputTextState_GetSelectionStart(const cimgui::ImGuiInputTextState* self)
|
CIMGUI_API int cimgui::ImGuiInputTextState_GetSelectionStart(const cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->GetSelectionStart();
|
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->GetSelectionStart();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API int cimgui::ImGuiInputTextState_GetSelectionEnd(const cimgui::ImGuiInputTextState* self)
|
CIMGUI_API int cimgui::ImGuiInputTextState_GetSelectionEnd(const cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->GetSelectionEnd();
|
return reinterpret_cast<const ::ImGuiInputTextState*>(self)->GetSelectionEnd();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_SelectAll(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API void cimgui::ImGuiInputTextState_SelectAll(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->SelectAll();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->SelectAll();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_ReloadUserBufAndSelectAll(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API void cimgui::ImGuiInputTextState_ReloadUserBufAndSelectAll(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->ReloadUserBufAndSelectAll();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->ReloadUserBufAndSelectAll();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_ReloadUserBufAndKeepSelection(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API void cimgui::ImGuiInputTextState_ReloadUserBufAndKeepSelection(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->ReloadUserBufAndKeepSelection();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->ReloadUserBufAndKeepSelection();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGuiInputTextState_ReloadUserBufAndMoveToEnd(cimgui::ImGuiInputTextState* self)
|
CIMGUI_API void cimgui::ImGuiInputTextState_ReloadUserBufAndMoveToEnd(cimgui::ImGuiInputTextState* self)
|
||||||
{
|
{
|
||||||
reinterpret_cast<::ImGuiInputTextState*>(self)->ReloadUserBufAndMoveToEnd();
|
reinterpret_cast<::ImGuiInputTextState*>(self)->ReloadUserBufAndMoveToEnd();
|
||||||
}
|
}
|
||||||
|
|
@ -1318,6 +1348,11 @@ CIMGUI_API bool cimgui::ImGui_IsWindowChildOf(cimgui::ImGuiWindow* w
|
||||||
return ::ImGui::IsWindowChildOf(reinterpret_cast<::ImGuiWindow*>(window), reinterpret_cast<::ImGuiWindow*>(potential_parent), popup_hierarchy, dock_hierarchy);
|
return ::ImGui::IsWindowChildOf(reinterpret_cast<::ImGuiWindow*>(window), reinterpret_cast<::ImGuiWindow*>(potential_parent), popup_hierarchy, dock_hierarchy);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_API bool cimgui::ImGui_IsWindowInBeginStack(cimgui::ImGuiWindow* window)
|
||||||
|
{
|
||||||
|
return ::ImGui::IsWindowInBeginStack(reinterpret_cast<::ImGuiWindow*>(window));
|
||||||
|
}
|
||||||
|
|
||||||
CIMGUI_API bool cimgui::ImGui_IsWindowWithinBeginStackOf(cimgui::ImGuiWindow* window, cimgui::ImGuiWindow* potential_parent)
|
CIMGUI_API bool cimgui::ImGui_IsWindowWithinBeginStackOf(cimgui::ImGuiWindow* window, cimgui::ImGuiWindow* potential_parent)
|
||||||
{
|
{
|
||||||
return ::ImGui::IsWindowWithinBeginStackOf(reinterpret_cast<::ImGuiWindow*>(window), reinterpret_cast<::ImGuiWindow*>(potential_parent));
|
return ::ImGui::IsWindowWithinBeginStackOf(reinterpret_cast<::ImGuiWindow*>(window), reinterpret_cast<::ImGuiWindow*>(potential_parent));
|
||||||
|
|
@ -1838,6 +1873,11 @@ CIMGUI_API void cimgui::ImGui_ShrinkWidths(cimgui::ImGuiShrinkWidthItem* items
|
||||||
::ImGui::ShrinkWidths(reinterpret_cast<::ImGuiShrinkWidthItem*>(items), count, width_excess, width_min);
|
::ImGui::ShrinkWidths(reinterpret_cast<::ImGuiShrinkWidthItem*>(items), count, width_excess, width_min);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_API void cimgui::ImGui_CalcClipRectVisibleItemsY(cimgui::ImRect clip_rect, cimgui::ImVec2 pos, float items_height, int* out_visible_start, int* out_visible_end)
|
||||||
|
{
|
||||||
|
::ImGui::CalcClipRectVisibleItemsY(ConvertToCPP_ImRect(clip_rect), ConvertToCPP_ImVec2(pos), items_height, out_visible_start, out_visible_end);
|
||||||
|
}
|
||||||
|
|
||||||
CIMGUI_API const cimgui::ImGuiStyleVarInfo* cimgui::ImGui_GetStyleVarInfo(ImGuiStyleVar idx)
|
CIMGUI_API const cimgui::ImGuiStyleVarInfo* cimgui::ImGui_GetStyleVarInfo(ImGuiStyleVar idx)
|
||||||
{
|
{
|
||||||
return reinterpret_cast<const ::cimgui::ImGuiStyleVarInfo*>(::ImGui::GetStyleVarInfo(idx));
|
return reinterpret_cast<const ::cimgui::ImGuiStyleVarInfo*>(::ImGui::GetStyleVarInfo(idx));
|
||||||
|
|
@ -2573,6 +2613,16 @@ CIMGUI_API bool cimgui::ImGui_BeginDragDropTargetCustom(cimgui::ImRect bb, ImGui
|
||||||
return ::ImGui::BeginDragDropTargetCustom(ConvertToCPP_ImRect(bb), id);
|
return ::ImGui::BeginDragDropTargetCustom(ConvertToCPP_ImRect(bb), id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_API bool cimgui::ImGui_BeginDragDropTargetViewport(cimgui::ImGuiViewport* viewport)
|
||||||
|
{
|
||||||
|
return ::ImGui::BeginDragDropTargetViewport(reinterpret_cast<::ImGuiViewport*>(viewport));
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_API bool cimgui::ImGui_BeginDragDropTargetViewportEx(cimgui::ImGuiViewport* viewport, const cimgui::ImRect* p_bb)
|
||||||
|
{
|
||||||
|
return ::ImGui::BeginDragDropTargetViewport(reinterpret_cast<::ImGuiViewport*>(viewport), reinterpret_cast<const ::ImRect*>(p_bb));
|
||||||
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGui_ClearDragDrop(void)
|
CIMGUI_API void cimgui::ImGui_ClearDragDrop(void)
|
||||||
{
|
{
|
||||||
::ImGui::ClearDragDrop();
|
::ImGui::ClearDragDrop();
|
||||||
|
|
@ -2583,9 +2633,14 @@ CIMGUI_API bool cimgui::ImGui_IsDragDropPayloadBeingAccepted(void)
|
||||||
return ::ImGui::IsDragDropPayloadBeingAccepted();
|
return ::ImGui::IsDragDropPayloadBeingAccepted();
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::ImGui_RenderDragDropTargetRect(cimgui::ImRect bb, cimgui::ImRect item_clip_rect)
|
CIMGUI_API void cimgui::ImGui_RenderDragDropTargetRectForItem(cimgui::ImRect bb)
|
||||||
{
|
{
|
||||||
::ImGui::RenderDragDropTargetRect(ConvertToCPP_ImRect(bb), ConvertToCPP_ImRect(item_clip_rect));
|
::ImGui::RenderDragDropTargetRectForItem(ConvertToCPP_ImRect(bb));
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_API void cimgui::ImGui_RenderDragDropTargetRectEx(cimgui::ImDrawList* draw_list, cimgui::ImRect bb)
|
||||||
|
{
|
||||||
|
::ImGui::RenderDragDropTargetRectEx(reinterpret_cast<::ImDrawList*>(draw_list), ConvertToCPP_ImRect(bb));
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API cimgui::ImGuiTypingSelectRequest* cimgui::ImGui_GetTypingSelectRequest(void)
|
CIMGUI_API cimgui::ImGuiTypingSelectRequest* cimgui::ImGui_GetTypingSelectRequest(void)
|
||||||
|
|
@ -2983,6 +3038,16 @@ CIMGUI_API cimgui::ImGuiTabBar* cimgui::ImGui_GetCurrentTabBar(void)
|
||||||
return reinterpret_cast<::cimgui::ImGuiTabBar*>(::ImGui::GetCurrentTabBar());
|
return reinterpret_cast<::cimgui::ImGuiTabBar*>(::ImGui::GetCurrentTabBar());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_API cimgui::ImGuiTabBar* cimgui::ImGui_TabBarFindByID(ImGuiID id)
|
||||||
|
{
|
||||||
|
return reinterpret_cast<::cimgui::ImGuiTabBar*>(::ImGui::TabBarFindByID(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
CIMGUI_API void cimgui::ImGui_TabBarRemove(cimgui::ImGuiTabBar* tab_bar)
|
||||||
|
{
|
||||||
|
::ImGui::TabBarRemove(reinterpret_cast<::ImGuiTabBar*>(tab_bar));
|
||||||
|
}
|
||||||
|
|
||||||
CIMGUI_API bool cimgui::ImGui_BeginTabBarEx(cimgui::ImGuiTabBar* tab_bar, cimgui::ImRect bb, ImGuiTabBarFlags flags)
|
CIMGUI_API bool cimgui::ImGui_BeginTabBarEx(cimgui::ImGuiTabBar* tab_bar, cimgui::ImRect bb, ImGuiTabBarFlags flags)
|
||||||
{
|
{
|
||||||
return ::ImGui::BeginTabBarEx(reinterpret_cast<::ImGuiTabBar*>(tab_bar), ConvertToCPP_ImRect(bb), flags);
|
return ::ImGui::BeginTabBarEx(reinterpret_cast<::ImGuiTabBar*>(tab_bar), ConvertToCPP_ImRect(bb), flags);
|
||||||
|
|
@ -3804,7 +3869,7 @@ CIMGUI_API int cimgui::cImFontAtlasRectId_GetIndex(ImFontAtlasRect
|
||||||
return ::ImFontAtlasRectId_GetIndex(id);
|
return ::ImFontAtlasRectId_GetIndex(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
CIMGUI_API int cimgui::cImFontAtlasRectId_GetGeneration(ImFontAtlasRectId id)
|
CIMGUI_API unsigned int cimgui::cImFontAtlasRectId_GetGeneration(ImFontAtlasRectId id)
|
||||||
{
|
{
|
||||||
return ::ImFontAtlasRectId_GetGeneration(id);
|
return ::ImFontAtlasRectId_GetGeneration(id);
|
||||||
}
|
}
|
||||||
|
|
@ -3834,6 +3899,11 @@ CIMGUI_API void cimgui::cImFontAtlasBuildSetupFontLoader(cimgui::ImFontAtlas* at
|
||||||
::ImFontAtlasBuildSetupFontLoader(reinterpret_cast<::ImFontAtlas*>(atlas), reinterpret_cast<const ::ImFontLoader*>(font_loader));
|
::ImFontAtlasBuildSetupFontLoader(reinterpret_cast<::ImFontAtlas*>(atlas), reinterpret_cast<const ::ImFontLoader*>(font_loader));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
CIMGUI_API void cimgui::cImFontAtlasBuildNotifySetFont(cimgui::ImFontAtlas* atlas, cimgui::ImFont* old_font, cimgui::ImFont* new_font)
|
||||||
|
{
|
||||||
|
::ImFontAtlasBuildNotifySetFont(reinterpret_cast<::ImFontAtlas*>(atlas), reinterpret_cast<::ImFont*>(old_font), reinterpret_cast<::ImFont*>(new_font));
|
||||||
|
}
|
||||||
|
|
||||||
CIMGUI_API void cimgui::cImFontAtlasBuildUpdatePointers(cimgui::ImFontAtlas* atlas)
|
CIMGUI_API void cimgui::cImFontAtlasBuildUpdatePointers(cimgui::ImFontAtlas* atlas)
|
||||||
{
|
{
|
||||||
::ImFontAtlasBuildUpdatePointers(reinterpret_cast<::ImFontAtlas*>(atlas));
|
::ImFontAtlasBuildUpdatePointers(reinterpret_cast<::ImFontAtlas*>(atlas));
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
// **DO NOT EDIT DIRECTLY**
|
// **DO NOT EDIT DIRECTLY**
|
||||||
// https://github.com/dearimgui/dear_bindings
|
// https://github.com/dearimgui/dear_bindings
|
||||||
|
|
||||||
// dear imgui, v1.92.2b
|
// dear imgui, v1.92.5
|
||||||
struct ImVector_ImFontBakedPtr_t { int Size; int Capacity; ImFontBaked** Data; }; // Instantiation of ImVector<ImFontBaked*>
|
struct ImVector_ImFontBakedPtr_t { int Size; int Capacity; ImFontBaked** Data; }; // Instantiation of ImVector<ImFontBaked*>
|
||||||
struct ImVector_ImFontAtlasPtr_t { int Size; int Capacity; ImFontAtlas** Data; }; // Instantiation of ImVector<ImFontAtlas*>
|
struct ImVector_ImFontAtlasPtr_t { int Size; int Capacity; ImFontAtlas** Data; }; // Instantiation of ImVector<ImFontAtlas*>
|
||||||
// (internal structures/api)
|
// (internal structures/api)
|
||||||
|
|
@ -84,8 +84,8 @@ extern "C"
|
||||||
#ifdef _MSC_VER
|
#ifdef _MSC_VER
|
||||||
#pragma warning (push)
|
#pragma warning (push)
|
||||||
#pragma warning (disable: 4251) // class 'xxx' needs to have dll-interface to be used by clients of struct 'xxx' // when IMGUI_API is set to__declspec(dllexport)
|
#pragma warning (disable: 4251) // class 'xxx' needs to have dll-interface to be used by clients of struct 'xxx' // when IMGUI_API is set to__declspec(dllexport)
|
||||||
#pragma warning (disable: 26812) // The enum type 'xxx' is unscoped. Prefer 'enum class' over 'enum' (Enum.3). [MSVC Static Analyzer)
|
|
||||||
#pragma warning (disable: 26495) // [Static Analyzer] Variable 'XXX' is uninitialized. Always initialize a member variable (type.6).
|
#pragma warning (disable: 26495) // [Static Analyzer] Variable 'XXX' is uninitialized. Always initialize a member variable (type.6).
|
||||||
|
#pragma warning (disable: 26812) // [Static Analyzer] The enum type 'xxx' is unscoped. Prefer 'enum class' over 'enum' (Enum.3).
|
||||||
#if defined(_MSC_VER)&& _MSC_VER >= 1922
|
#if defined(_MSC_VER)&& _MSC_VER >= 1922
|
||||||
#pragma warning (disable: 5054) // operator '|': deprecated between enumerations of different types
|
#pragma warning (disable: 5054) // operator '|': deprecated between enumerations of different types
|
||||||
#endif// MSVC 2019 16.2 or later
|
#endif// MSVC 2019 16.2 or later
|
||||||
|
|
@ -212,6 +212,7 @@ typedef struct ImGuiViewportP_t ImGuiViewportP;
|
||||||
typedef struct ImGuiDebugAllocEntry_t ImGuiDebugAllocEntry;
|
typedef struct ImGuiDebugAllocEntry_t ImGuiDebugAllocEntry;
|
||||||
typedef struct ImGuiDebugAllocInfo_t ImGuiDebugAllocInfo;
|
typedef struct ImGuiDebugAllocInfo_t ImGuiDebugAllocInfo;
|
||||||
typedef struct ImGuiStackLevelInfo_t ImGuiStackLevelInfo;
|
typedef struct ImGuiStackLevelInfo_t ImGuiStackLevelInfo;
|
||||||
|
typedef struct ImGuiDebugItemPathQuery_t ImGuiDebugItemPathQuery;
|
||||||
typedef struct ImGuiIDStackTool_t ImGuiIDStackTool;
|
typedef struct ImGuiIDStackTool_t ImGuiIDStackTool;
|
||||||
typedef struct ImGuiTableCellData_t ImGuiTableCellData;
|
typedef struct ImGuiTableCellData_t ImGuiTableCellData;
|
||||||
typedef struct ImGuiTableColumnSettings_t ImGuiTableColumnSettings;
|
typedef struct ImGuiTableColumnSettings_t ImGuiTableColumnSettings;
|
||||||
|
|
@ -288,6 +289,7 @@ typedef int ImGuiDataAuthority; // -> enum ImGuiDataAuthority_ // Enum: fo
|
||||||
typedef int ImGuiLayoutType; // -> enum ImGuiLayoutType_ // Enum: Horizontal or vertical
|
typedef int ImGuiLayoutType; // -> enum ImGuiLayoutType_ // Enum: Horizontal or vertical
|
||||||
|
|
||||||
// Flags
|
// Flags
|
||||||
|
typedef int ImDrawTextFlags; // -> enum ImDrawTextFlags_ // Flags: for ImTextCalcWordWrapPositionEx()
|
||||||
typedef int ImGuiActivateFlags; // -> enum ImGuiActivateFlags_ // Flags: for navigation/focus function (will be for ActivateItem() later)
|
typedef int ImGuiActivateFlags; // -> enum ImGuiActivateFlags_ // Flags: for navigation/focus function (will be for ActivateItem() later)
|
||||||
typedef int ImGuiDebugLogFlags; // -> enum ImGuiDebugLogFlags_ // Flags: for ShowDebugLogWindow(), g.DebugLogFlags
|
typedef int ImGuiDebugLogFlags; // -> enum ImGuiDebugLogFlags_ // Flags: for ShowDebugLogWindow(), g.DebugLogFlags
|
||||||
typedef int ImGuiFocusRequestFlags; // -> enum ImGuiFocusRequestFlags_ // Flags: for FocusWindow()
|
typedef int ImGuiFocusRequestFlags; // -> enum ImGuiFocusRequestFlags_ // Flags: for FocusWindow()
|
||||||
|
|
@ -303,6 +305,7 @@ typedef int ImGuiSeparatorFlags; // -> enum ImGuiSeparatorFlags_ // F
|
||||||
typedef int ImGuiTextFlags; // -> enum ImGuiTextFlags_ // Flags: for TextEx()
|
typedef int ImGuiTextFlags; // -> enum ImGuiTextFlags_ // Flags: for TextEx()
|
||||||
typedef int ImGuiTooltipFlags; // -> enum ImGuiTooltipFlags_ // Flags: for BeginTooltipEx()
|
typedef int ImGuiTooltipFlags; // -> enum ImGuiTooltipFlags_ // Flags: for BeginTooltipEx()
|
||||||
typedef int ImGuiTypingSelectFlags; // -> enum ImGuiTypingSelectFlags_ // Flags: for GetTypingSelectRequest()
|
typedef int ImGuiTypingSelectFlags; // -> enum ImGuiTypingSelectFlags_ // Flags: for GetTypingSelectRequest()
|
||||||
|
typedef int ImGuiWindowBgClickFlags; // -> enum ImGuiWindowBgClickFlags_ // Flags: for overriding behavior of clicking on window background/void.
|
||||||
typedef int ImGuiWindowRefreshFlags; // -> enum ImGuiWindowRefreshFlags_ // Flags: for SetNextWindowRefreshPolicy()
|
typedef int ImGuiWindowRefreshFlags; // -> enum ImGuiWindowRefreshFlags_ // Flags: for SetNextWindowRefreshPolicy()
|
||||||
|
|
||||||
typedef ImU16 ImGuiTableDrawChannelIdx;
|
typedef ImU16 ImGuiTableDrawChannelIdx;
|
||||||
|
|
@ -368,10 +371,8 @@ typedef ImU16 ImGuiTableDrawChannelIdx;
|
||||||
#define IM_F32_TO_INT8_SAT(_VAL) ((int)(ImSaturate(_VAL) * 255.0f + 0.5f)) // Saturated, always output 0..255
|
#define IM_F32_TO_INT8_SAT(_VAL) ((int)(ImSaturate(_VAL) * 255.0f + 0.5f)) // Saturated, always output 0..255
|
||||||
#define IM_TRUNC(_VAL) ((float)(int)(_VAL)) // ImTrunc() is not inlined in MSVC debug builds
|
#define IM_TRUNC(_VAL) ((float)(int)(_VAL)) // ImTrunc() is not inlined in MSVC debug builds
|
||||||
#define IM_ROUND(_VAL) ((float)(int)((_VAL) + 0.5f)) //
|
#define IM_ROUND(_VAL) ((float)(int)((_VAL) + 0.5f)) //
|
||||||
#define IM_STRINGIFY_HELPER(_X) #_X
|
|
||||||
#define IM_STRINGIFY(_X) IM_STRINGIFY_HELPER(_X) // Preprocessor idiom to stringify e.g. an integer.
|
|
||||||
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
#define IM_FLOOR IM_TRUNC
|
#define IM_FLOOR IM_TRUNC // [OBSOLETE] Renamed in 1.90.0 (Sept 2023)
|
||||||
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
#endif // #ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
|
||||||
// Hint for branch prediction
|
// Hint for branch prediction
|
||||||
#if (defined(__cplusplus)&&(__cplusplus >= 202002L))||(defined(_MSVC_LANG)&&(_MSVC_LANG >= 202002L))
|
#if (defined(__cplusplus)&&(__cplusplus >= 202002L))||(defined(_MSVC_LANG)&&(_MSVC_LANG >= 202002L))
|
||||||
|
|
@ -430,6 +431,8 @@ typedef ImU16 ImGuiTableDrawChannelIdx;
|
||||||
#define IM_PRIu64 "llu"
|
#define IM_PRIu64 "llu"
|
||||||
#define IM_PRIX64 "llX"
|
#define IM_PRIX64 "llX"
|
||||||
#endif // #if defined(_MSC_VER)&&!defined(__clang__)
|
#endif // #if defined(_MSC_VER)&&!defined(__clang__)
|
||||||
|
#define IM_TEXTUREID_TO_U64(_TEXID) ((ImU64)(intptr_t)(_TEXID))
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
// [SECTION] Generic helpers
|
// [SECTION] Generic helpers
|
||||||
// Note that the ImXXX helpers functions are lower-level than ImGui functions.
|
// Note that the ImXXX helpers functions are lower-level than ImGui functions.
|
||||||
|
|
@ -458,10 +461,11 @@ typedef ImU16 ImGuiTableDrawChannelIdx;
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
||||||
// Helpers: Hashing
|
// Helpers: Hashing
|
||||||
CIMGUI_API ImGuiID cImHashData(const void* data, size_t data_size); // Implied seed = 0
|
CIMGUI_API ImGuiID cImHashData(const void* data, size_t data_size); // Implied seed = 0
|
||||||
CIMGUI_API ImGuiID cImHashDataEx(const void* data, size_t data_size, ImGuiID seed /* = 0 */);
|
CIMGUI_API ImGuiID cImHashDataEx(const void* data, size_t data_size, ImGuiID seed /* = 0 */);
|
||||||
CIMGUI_API ImGuiID cImHashStr(const char* data); // Implied data_size = 0, seed = 0
|
CIMGUI_API ImGuiID cImHashStr(const char* data); // Implied data_size = 0, seed = 0
|
||||||
CIMGUI_API ImGuiID cImHashStrEx(const char* data, size_t data_size /* = 0 */, ImGuiID seed /* = 0 */);
|
CIMGUI_API ImGuiID cImHashStrEx(const char* data, size_t data_size /* = 0 */, ImGuiID seed /* = 0 */);
|
||||||
|
CIMGUI_API const char* cImHashSkipUncontributingPrefix(const char* label);
|
||||||
|
|
||||||
// Helpers: Color Blending
|
// Helpers: Color Blending
|
||||||
CIMGUI_API ImU32 cImAlphaBlendColors(ImU32 col_a, ImU32 col_b);
|
CIMGUI_API ImU32 cImAlphaBlendColors(ImU32 col_a, ImU32 col_b);
|
||||||
|
|
@ -508,16 +512,29 @@ CIMGUI_API const char* cImParseFormatSanitizeForScanning(const char* fmt_in, cha
|
||||||
CIMGUI_API int cImParseFormatPrecision(const char* format, int default_value);
|
CIMGUI_API int cImParseFormatPrecision(const char* format, int default_value);
|
||||||
|
|
||||||
// Helpers: UTF-8 <> wchar conversions
|
// Helpers: UTF-8 <> wchar conversions
|
||||||
CIMGUI_API int cImTextCharToUtf8(char out_buf[5], unsigned int c); // return output UTF-8 bytes count
|
CIMGUI_API int cImTextCharToUtf8(char out_buf[5], unsigned int c); // return output UTF-8 bytes count
|
||||||
CIMGUI_API int cImTextStrToUtf8(char* out_buf, int out_buf_size, const ImWchar* in_text, const ImWchar* in_text_end); // return output UTF-8 bytes count
|
CIMGUI_API int cImTextStrToUtf8(char* out_buf, int out_buf_size, const ImWchar* in_text, const ImWchar* in_text_end); // return output UTF-8 bytes count
|
||||||
CIMGUI_API int cImTextCharFromUtf8(unsigned int* out_char, const char* in_text, const char* in_text_end); // read one character. return input UTF-8 bytes count
|
CIMGUI_API int cImTextCharFromUtf8(unsigned int* out_char, const char* in_text, const char* in_text_end); // read one character. return input UTF-8 bytes count
|
||||||
CIMGUI_API int cImTextStrFromUtf8(ImWchar* out_buf, int out_buf_size, const char* in_text, const char* in_text_end); // Implied in_remaining = NULL
|
CIMGUI_API int cImTextStrFromUtf8(ImWchar* out_buf, int out_buf_size, const char* in_text, const char* in_text_end); // Implied in_remaining = NULL
|
||||||
CIMGUI_API int cImTextStrFromUtf8Ex(ImWchar* out_buf, int out_buf_size, const char* in_text, const char* in_text_end, const char** in_remaining /* = NULL */); // return input UTF-8 bytes count
|
CIMGUI_API int cImTextStrFromUtf8Ex(ImWchar* out_buf, int out_buf_size, const char* in_text, const char* in_text_end, const char** in_remaining /* = NULL */); // return input UTF-8 bytes count
|
||||||
CIMGUI_API int cImTextCountCharsFromUtf8(const char* in_text, const char* in_text_end); // return number of UTF-8 code-points (NOT bytes count)
|
CIMGUI_API int cImTextCountCharsFromUtf8(const char* in_text, const char* in_text_end); // return number of UTF-8 code-points (NOT bytes count)
|
||||||
CIMGUI_API int cImTextCountUtf8BytesFromChar(const char* in_text, const char* in_text_end); // return number of bytes to express one char in UTF-8
|
CIMGUI_API int cImTextCountUtf8BytesFromChar(const char* in_text, const char* in_text_end); // return number of bytes to express one char in UTF-8
|
||||||
CIMGUI_API int cImTextCountUtf8BytesFromStr(const ImWchar* in_text, const ImWchar* in_text_end); // return number of bytes to express string in UTF-8
|
CIMGUI_API int cImTextCountUtf8BytesFromStr(const ImWchar* in_text, const ImWchar* in_text_end); // return number of bytes to express string in UTF-8
|
||||||
CIMGUI_API const char* cImTextFindPreviousUtf8Codepoint(const char* in_text_start, const char* in_text_curr); // return previous UTF-8 code-point.
|
CIMGUI_API const char* cImTextFindPreviousUtf8Codepoint(const char* in_text_start, const char* in_p); // return previous UTF-8 code-point.
|
||||||
CIMGUI_API int cImTextCountLines(const char* in_text, const char* in_text_end); // return number of lines taken by text. trailing carriage return doesn't count as an extra line.
|
CIMGUI_API const char* cImTextFindValidUtf8CodepointEnd(const char* in_text_start, const char* in_text_end, const char* in_p); // return previous UTF-8 code-point if 'in_p' is not the end of a valid one.
|
||||||
|
CIMGUI_API int cImTextCountLines(const char* in_text, const char* in_text_end); // return number of lines taken by text. trailing carriage return doesn't count as an extra line.
|
||||||
|
|
||||||
|
// Helpers: High-level text functions (DO NOT USE!!! THIS IS A MINIMAL SUBSET OF LARGER UPCOMING CHANGES)
|
||||||
|
typedef enum
|
||||||
|
{
|
||||||
|
ImDrawTextFlags_None = 0,
|
||||||
|
ImDrawTextFlags_CpuFineClip = 1<<0, // Must be == 1/true for legacy with 'bool cpu_fine_clip' arg to RenderText()
|
||||||
|
ImDrawTextFlags_WrapKeepBlanks = 1<<1,
|
||||||
|
ImDrawTextFlags_StopOnNewLine = 1<<2,
|
||||||
|
} ImDrawTextFlags_;
|
||||||
|
CIMGUI_API ImVec2 cImFontCalcTextSizeEx(ImFont* font, float size, float max_width, float wrap_width, const char* text_begin, const char* text_end_display, const char* text_end, const char** out_remaining, ImVec2* out_offset, ImDrawTextFlags flags);
|
||||||
|
CIMGUI_API const char* cImFontCalcWordWrapPositionEx(ImFont* font, float size, const char* text, const char* text_end, float wrap_width, ImDrawTextFlags flags /* = 0 */);
|
||||||
|
CIMGUI_API const char* cImTextCalcWordWrapNextLineStart(const char* text, const char* text_end, ImDrawTextFlags flags /* = 0 */); // trim trailing space and find beginning of next line
|
||||||
|
|
||||||
// Helpers: File System
|
// Helpers: File System
|
||||||
#ifdef IMGUI_DISABLE_FILE_FUNCTIONS
|
#ifdef IMGUI_DISABLE_FILE_FUNCTIONS
|
||||||
|
|
@ -934,7 +951,7 @@ struct ImPool_ImGuiTable_t
|
||||||
// Maintain a line index for a text buffer. This is a strong candidate to be moved into the public API.
|
// Maintain a line index for a text buffer. This is a strong candidate to be moved into the public API.
|
||||||
struct ImGuiTextIndex_t
|
struct ImGuiTextIndex_t
|
||||||
{
|
{
|
||||||
ImVector_int LineOffsets;
|
ImVector_int Offsets;
|
||||||
int EndOffset /* = 0 */; // Because we don't own text buffer we need to maintain EndOffset (may bake in LineOffsets?)
|
int EndOffset /* = 0 */; // Because we don't own text buffer we need to maintain EndOffset (may bake in LineOffsets?)
|
||||||
};
|
};
|
||||||
typedef struct ImGuiTextIndex_t ImGuiTextIndex; // Maintain a line index for a text buffer.
|
typedef struct ImGuiTextIndex_t ImGuiTextIndex; // Maintain a line index for a text buffer.
|
||||||
|
|
@ -1056,7 +1073,6 @@ typedef enum
|
||||||
{
|
{
|
||||||
// NB: need to be in sync with last value of ImGuiSelectableFlags_
|
// NB: need to be in sync with last value of ImGuiSelectableFlags_
|
||||||
ImGuiSelectableFlags_NoHoldingActiveID = 1<<20,
|
ImGuiSelectableFlags_NoHoldingActiveID = 1<<20,
|
||||||
ImGuiSelectableFlags_SelectOnNav = 1<<21, // (WIP) Auto-select when moved into. This is not exposed in public API as to handle multi-select and modifiers we will need user to explicitly control focus scope. May be replaced with a BeginSelection() API.
|
|
||||||
ImGuiSelectableFlags_SelectOnClick = 1<<22, // Override button behavior to react on Click (default is Click+Release)
|
ImGuiSelectableFlags_SelectOnClick = 1<<22, // Override button behavior to react on Click (default is Click+Release)
|
||||||
ImGuiSelectableFlags_SelectOnRelease = 1<<23, // Override button behavior to react on Release (default is Click+Release)
|
ImGuiSelectableFlags_SelectOnRelease = 1<<23, // Override button behavior to react on Release (default is Click+Release)
|
||||||
ImGuiSelectableFlags_SpanAvailWidth = 1<<24, // Span all avail width even if we declared less for layout purpose. FIXME: We may be able to remove this (added in 6251d379, 2bcafc86 for menus)
|
ImGuiSelectableFlags_SpanAvailWidth = 1<<24, // Span all avail width even if we declared less for layout purpose. FIXME: We may be able to remove this (added in 6251d379, 2bcafc86 for menus)
|
||||||
|
|
@ -1162,6 +1178,7 @@ struct ImGuiGroupData_t
|
||||||
ImVec2 BackupCurrLineSize;
|
ImVec2 BackupCurrLineSize;
|
||||||
float BackupCurrLineTextBaseOffset;
|
float BackupCurrLineTextBaseOffset;
|
||||||
ImGuiID BackupActiveIdIsAlive;
|
ImGuiID BackupActiveIdIsAlive;
|
||||||
|
bool BackupActiveIdHasBeenEditedThisFrame;
|
||||||
bool BackupDeactivatedIdIsAlive;
|
bool BackupDeactivatedIdIsAlive;
|
||||||
bool BackupHoveredIdIsAlive;
|
bool BackupHoveredIdIsAlive;
|
||||||
bool BackupIsSameLine;
|
bool BackupIsSameLine;
|
||||||
|
|
@ -1217,35 +1234,40 @@ struct ImGuiInputTextState_t
|
||||||
ImVector_char CallbackTextBackup; // temporary storage for callback to support automatic reconcile of undo-stack
|
ImVector_char CallbackTextBackup; // temporary storage for callback to support automatic reconcile of undo-stack
|
||||||
int BufCapacity; // end-user buffer capacity (include zero terminator)
|
int BufCapacity; // end-user buffer capacity (include zero terminator)
|
||||||
ImVec2 Scroll; // horizontal offset (managed manually) + vertical scrolling (pulled from child window's own Scroll.y)
|
ImVec2 Scroll; // horizontal offset (managed manually) + vertical scrolling (pulled from child window's own Scroll.y)
|
||||||
|
int LineCount; // last line count (solely for debugging)
|
||||||
|
float WrapWidth; // word-wrapping width
|
||||||
float CursorAnim; // timer for cursor blink, reset on every user action so the cursor reappears immediately
|
float CursorAnim; // timer for cursor blink, reset on every user action so the cursor reappears immediately
|
||||||
bool CursorFollow; // set when we want scrolling to follow the current cursor position (not always!)
|
bool CursorFollow; // set when we want scrolling to follow the current cursor position (not always!)
|
||||||
|
bool CursorCenterY; // set when we want scrolling to be centered over the cursor position (while resizing a word-wrapping field)
|
||||||
bool SelectedAllMouseLock; // after a double-click to select all, we ignore further mouse drags to update selection
|
bool SelectedAllMouseLock; // after a double-click to select all, we ignore further mouse drags to update selection
|
||||||
bool Edited; // edited this frame
|
bool Edited; // edited this frame
|
||||||
bool WantReloadUserBuf; // force a reload of user buf so it may be modified externally. may be automatic in future version.
|
bool WantReloadUserBuf; // force a reload of user buf so it may be modified externally. may be automatic in future version.
|
||||||
|
ImS8 LastMoveDirectionLR; // ImGuiDir_Left or ImGuiDir_Right. track last movement direction so when cursor cross over a word-wrapping boundaries we can display it on either line depending on last move.s
|
||||||
int ReloadSelectionStart;
|
int ReloadSelectionStart;
|
||||||
int ReloadSelectionEnd;
|
int ReloadSelectionEnd;
|
||||||
};
|
};
|
||||||
CIMGUI_API void ImGuiInputTextState_ClearText(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_ClearText(ImGuiInputTextState* self);
|
||||||
CIMGUI_API void ImGuiInputTextState_ClearFreeMemory(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_ClearFreeMemory(ImGuiInputTextState* self);
|
||||||
CIMGUI_API void ImGuiInputTextState_OnKeyPressed(ImGuiInputTextState* self, int key); // Cannot be inline because we call in code in stb_textedit.h implementation
|
CIMGUI_API void ImGuiInputTextState_OnKeyPressed(ImGuiInputTextState* self, int key); // Cannot be inline because we call in code in stb_textedit.h implementation
|
||||||
CIMGUI_API void ImGuiInputTextState_OnCharPressed(ImGuiInputTextState* self, unsigned int c);
|
CIMGUI_API void ImGuiInputTextState_OnCharPressed(ImGuiInputTextState* self, unsigned int c);
|
||||||
|
CIMGUI_API float ImGuiInputTextState_GetPreferredOffsetX(const ImGuiInputTextState* self);
|
||||||
// Cursor & Selection
|
// Cursor & Selection
|
||||||
CIMGUI_API void ImGuiInputTextState_CursorAnimReset(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_CursorAnimReset(ImGuiInputTextState* self);
|
||||||
CIMGUI_API void ImGuiInputTextState_CursorClamp(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_CursorClamp(ImGuiInputTextState* self);
|
||||||
CIMGUI_API bool ImGuiInputTextState_HasSelection(const ImGuiInputTextState* self);
|
CIMGUI_API bool ImGuiInputTextState_HasSelection(const ImGuiInputTextState* self);
|
||||||
CIMGUI_API void ImGuiInputTextState_ClearSelection(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_ClearSelection(ImGuiInputTextState* self);
|
||||||
CIMGUI_API int ImGuiInputTextState_GetCursorPos(const ImGuiInputTextState* self);
|
CIMGUI_API int ImGuiInputTextState_GetCursorPos(const ImGuiInputTextState* self);
|
||||||
CIMGUI_API int ImGuiInputTextState_GetSelectionStart(const ImGuiInputTextState* self);
|
CIMGUI_API int ImGuiInputTextState_GetSelectionStart(const ImGuiInputTextState* self);
|
||||||
CIMGUI_API int ImGuiInputTextState_GetSelectionEnd(const ImGuiInputTextState* self);
|
CIMGUI_API int ImGuiInputTextState_GetSelectionEnd(const ImGuiInputTextState* self);
|
||||||
CIMGUI_API void ImGuiInputTextState_SelectAll(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_SelectAll(ImGuiInputTextState* self);
|
||||||
// Reload user buf (WIP #2890)
|
// Reload user buf (WIP #2890)
|
||||||
// If you modify underlying user-passed const char* while active you need to call this (InputText V2 may lift this)
|
// If you modify underlying user-passed const char* while active you need to call this (InputText V2 may lift this)
|
||||||
// strcpy(my_buf, "hello");
|
// strcpy(my_buf, "hello");
|
||||||
// if (ImGuiInputTextState* state = ImGui::GetInputTextState(id)) // id may be ImGui::GetItemID() is last item
|
// if (ImGuiInputTextState* state = ImGui::GetInputTextState(id)) // id may be ImGui::GetItemID() is last item
|
||||||
// state->ReloadUserBufAndSelectAll();
|
// state->ReloadUserBufAndSelectAll();
|
||||||
CIMGUI_API void ImGuiInputTextState_ReloadUserBufAndSelectAll(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_ReloadUserBufAndSelectAll(ImGuiInputTextState* self);
|
||||||
CIMGUI_API void ImGuiInputTextState_ReloadUserBufAndKeepSelection(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_ReloadUserBufAndKeepSelection(ImGuiInputTextState* self);
|
||||||
CIMGUI_API void ImGuiInputTextState_ReloadUserBufAndMoveToEnd(ImGuiInputTextState* self);
|
CIMGUI_API void ImGuiInputTextState_ReloadUserBufAndMoveToEnd(ImGuiInputTextState* self);
|
||||||
|
|
||||||
typedef enum
|
typedef enum
|
||||||
{
|
{
|
||||||
|
|
@ -1256,6 +1278,12 @@ typedef enum
|
||||||
// Refresh policy/frequency, Load Balancing etc.
|
// Refresh policy/frequency, Load Balancing etc.
|
||||||
} ImGuiWindowRefreshFlags_;
|
} ImGuiWindowRefreshFlags_;
|
||||||
|
|
||||||
|
typedef enum
|
||||||
|
{
|
||||||
|
ImGuiWindowBgClickFlags_None = 0,
|
||||||
|
ImGuiWindowBgClickFlags_Move = 1<<0, // Click on bg/void + drag to move window. Cleared by default when using io.ConfigWindowsMoveFromTitleBarOnly.
|
||||||
|
} ImGuiWindowBgClickFlags_;
|
||||||
|
|
||||||
typedef enum
|
typedef enum
|
||||||
{
|
{
|
||||||
ImGuiNextWindowDataFlags_None = 0,
|
ImGuiNextWindowDataFlags_None = 0,
|
||||||
|
|
@ -1555,8 +1583,8 @@ struct ImGuiKeyRoutingData_t
|
||||||
{
|
{
|
||||||
ImGuiKeyRoutingIndex NextEntryIndex;
|
ImGuiKeyRoutingIndex NextEntryIndex;
|
||||||
ImU16 Mods; // Technically we'd only need 4-bits but for simplify we store ImGuiMod_ values which need 16-bits.
|
ImU16 Mods; // Technically we'd only need 4-bits but for simplify we store ImGuiMod_ values which need 16-bits.
|
||||||
ImU8 RoutingCurrScore; // [DEBUG] For debug display
|
ImU16 RoutingCurrScore; // [DEBUG] For debug display
|
||||||
ImU8 RoutingNextScore; // Lower is better (0: perfect score)
|
ImU16 RoutingNextScore; // Lower is better (0: perfect score)
|
||||||
ImGuiID RoutingCurr;
|
ImGuiID RoutingCurr;
|
||||||
ImGuiID RoutingNext;
|
ImGuiID RoutingNext;
|
||||||
};
|
};
|
||||||
|
|
@ -1660,8 +1688,9 @@ typedef enum
|
||||||
ImGuiActivateFlags_PreferInput = 1<<0, // Favor activation that requires keyboard text input (e.g. for Slider/Drag). Default for Enter key.
|
ImGuiActivateFlags_PreferInput = 1<<0, // Favor activation that requires keyboard text input (e.g. for Slider/Drag). Default for Enter key.
|
||||||
ImGuiActivateFlags_PreferTweak = 1<<1, // Favor activation for tweaking with arrows or gamepad (e.g. for Slider/Drag). Default for Space key and if keyboard is not used.
|
ImGuiActivateFlags_PreferTweak = 1<<1, // Favor activation for tweaking with arrows or gamepad (e.g. for Slider/Drag). Default for Space key and if keyboard is not used.
|
||||||
ImGuiActivateFlags_TryToPreserveState = 1<<2, // Request widget to preserve state if it can (e.g. InputText will try to preserve cursor/selection)
|
ImGuiActivateFlags_TryToPreserveState = 1<<2, // Request widget to preserve state if it can (e.g. InputText will try to preserve cursor/selection)
|
||||||
ImGuiActivateFlags_FromTabbing = 1<<3, // Activation requested by a tabbing request
|
ImGuiActivateFlags_FromTabbing = 1<<3, // Activation requested by a tabbing request (ImGuiNavMoveFlags_IsTabbing)
|
||||||
ImGuiActivateFlags_FromShortcut = 1<<4, // Activation requested by an item shortcut via SetNextItemShortcut() function.
|
ImGuiActivateFlags_FromShortcut = 1<<4, // Activation requested by an item shortcut via SetNextItemShortcut() function.
|
||||||
|
ImGuiActivateFlags_FromFocusApi = 1<<5, // Activation requested by an api request (ImGuiNavMoveFlags_FocusApi)
|
||||||
} ImGuiActivateFlags_;
|
} ImGuiActivateFlags_;
|
||||||
|
|
||||||
// Early work-in-progress API for ScrollToItem()
|
// Early work-in-progress API for ScrollToItem()
|
||||||
|
|
@ -1704,7 +1733,7 @@ typedef enum
|
||||||
ImGuiNavMoveFlags_WrapMask_ = ImGuiNavMoveFlags_LoopX | ImGuiNavMoveFlags_LoopY | ImGuiNavMoveFlags_WrapX | ImGuiNavMoveFlags_WrapY,
|
ImGuiNavMoveFlags_WrapMask_ = ImGuiNavMoveFlags_LoopX | ImGuiNavMoveFlags_LoopY | ImGuiNavMoveFlags_WrapX | ImGuiNavMoveFlags_WrapY,
|
||||||
ImGuiNavMoveFlags_AllowCurrentNavId = 1<<4, // Allow scoring and considering the current NavId as a move target candidate. This is used when the move source is offset (e.g. pressing PageDown actually needs to send a Up move request, if we are pressing PageDown from the bottom-most item we need to stay in place)
|
ImGuiNavMoveFlags_AllowCurrentNavId = 1<<4, // Allow scoring and considering the current NavId as a move target candidate. This is used when the move source is offset (e.g. pressing PageDown actually needs to send a Up move request, if we are pressing PageDown from the bottom-most item we need to stay in place)
|
||||||
ImGuiNavMoveFlags_AlsoScoreVisibleSet = 1<<5, // Store alternate result in NavMoveResultLocalVisible that only comprise elements that are already fully visible (used by PageUp/PageDown)
|
ImGuiNavMoveFlags_AlsoScoreVisibleSet = 1<<5, // Store alternate result in NavMoveResultLocalVisible that only comprise elements that are already fully visible (used by PageUp/PageDown)
|
||||||
ImGuiNavMoveFlags_ScrollToEdgeY = 1<<6, // Force scrolling to min/max (used by Home/End) // FIXME-NAV: Aim to remove or reword, probably unnecessary
|
ImGuiNavMoveFlags_ScrollToEdgeY = 1<<6, // Force scrolling to min/max (used by Home/End) // FIXME-NAV: Aim to remove or reword as ImGuiScrollFlags
|
||||||
ImGuiNavMoveFlags_Forwarded = 1<<7,
|
ImGuiNavMoveFlags_Forwarded = 1<<7,
|
||||||
ImGuiNavMoveFlags_DebugNoResult = 1<<8, // Dummy scoring for debug purpose, don't apply result
|
ImGuiNavMoveFlags_DebugNoResult = 1<<8, // Dummy scoring for debug purpose, don't apply result
|
||||||
ImGuiNavMoveFlags_FocusApi = 1<<9, // Requests from focus API can land/focus/activate items even if they are marked with _NoTabStop (see NavProcessItemForTabbingRequest() for details)
|
ImGuiNavMoveFlags_FocusApi = 1<<9, // Requests from focus API can land/focus/activate items even if they are marked with _NoTabStop (see NavProcessItemForTabbingRequest() for details)
|
||||||
|
|
@ -2021,6 +2050,7 @@ typedef enum
|
||||||
ImGuiWindowDockStyleCol_TabDimmed,
|
ImGuiWindowDockStyleCol_TabDimmed,
|
||||||
ImGuiWindowDockStyleCol_TabDimmedSelected,
|
ImGuiWindowDockStyleCol_TabDimmedSelected,
|
||||||
ImGuiWindowDockStyleCol_TabDimmedSelectedOverline,
|
ImGuiWindowDockStyleCol_TabDimmedSelectedOverline,
|
||||||
|
ImGuiWindowDockStyleCol_UnsavedMarker,
|
||||||
ImGuiWindowDockStyleCol_COUNT,
|
ImGuiWindowDockStyleCol_COUNT,
|
||||||
} ImGuiWindowDockStyleCol;
|
} ImGuiWindowDockStyleCol;
|
||||||
|
|
||||||
|
|
@ -2056,6 +2086,7 @@ struct ImGuiViewportP_t
|
||||||
ImVec2 WorkSize; // Work Area: Size of the viewport minus task bars, menu bars, status bars (<= Size)
|
ImVec2 WorkSize; // Work Area: Size of the viewport minus task bars, menu bars, status bars (<= Size)
|
||||||
float DpiScale; // 1.0f = 96 DPI = No extra scale.
|
float DpiScale; // 1.0f = 96 DPI = No extra scale.
|
||||||
ImGuiID ParentViewportId; // (Advanced) 0: no parent. Instruct the platform backend to setup a parent/child relationship between platform windows.
|
ImGuiID ParentViewportId; // (Advanced) 0: no parent. Instruct the platform backend to setup a parent/child relationship between platform windows.
|
||||||
|
ImGuiViewport* ParentViewport; // (Advanced) Direct shortcut to ImGui::FindViewportByID(ParentViewportId). NULL: no parent.
|
||||||
ImDrawData* DrawData; // The ImDrawData corresponding to this viewport. Valid after Render() and until the next call to NewFrame().
|
ImDrawData* DrawData; // The ImDrawData corresponding to this viewport. Valid after Render() and until the next call to NewFrame().
|
||||||
// Platform/Backend Dependent Data
|
// Platform/Backend Dependent Data
|
||||||
// Our design separate the Renderer and Platform backends to facilitate combining default backends with each others.
|
// Our design separate the Renderer and Platform backends to facilitate combining default backends with each others.
|
||||||
|
|
@ -2253,23 +2284,31 @@ struct ImGuiMetricsConfig_t
|
||||||
|
|
||||||
struct ImGuiStackLevelInfo_t
|
struct ImGuiStackLevelInfo_t
|
||||||
{
|
{
|
||||||
ImGuiID ID;
|
ImGuiID ID;
|
||||||
ImS8 QueryFrameCount; // >= 1: Query in progress
|
ImS8 QueryFrameCount; // >= 1: Sub-query in progress
|
||||||
bool QuerySuccess; // Obtained result from DebugHookIdInfo()
|
bool QuerySuccess; // Sub-query obtained result from DebugHookIdInfo()
|
||||||
ImGuiDataType DataType : 8;
|
ImS8 DataType; // ImGuiDataType
|
||||||
char Desc[57]; // Arbitrarily sized buffer to hold a result (FIXME: could replace Results[] with a chunk stream?) FIXME: Now that we added CTRL+C this should be fixed.
|
int DescOffset; // -1 or offset into parent's ResultsPathsBuf
|
||||||
|
};
|
||||||
|
|
||||||
|
struct ImGuiDebugItemPathQuery_t
|
||||||
|
{
|
||||||
|
ImGuiID MainID; // ID to query details for.
|
||||||
|
bool Active; // Used to disambiguate the case when ID == 0 and e.g. some code calls PushOverrideID(0).
|
||||||
|
bool Complete; // All sub-queries are finished (some may have failed).
|
||||||
|
ImS8 Step; // -1: query stack + init Results, >= 0: filling individual stack level.
|
||||||
|
ImVector_ImGuiStackLevelInfo Results;
|
||||||
|
ImGuiTextBuffer ResultsDescBuf;
|
||||||
|
ImGuiTextBuffer ResultPathBuf;
|
||||||
};
|
};
|
||||||
|
|
||||||
// State for ID Stack tool queries
|
// State for ID Stack tool queries
|
||||||
struct ImGuiIDStackTool_t
|
struct ImGuiIDStackTool_t
|
||||||
{
|
{
|
||||||
int LastActiveFrame;
|
bool OptHexEncodeNonAsciiChars;
|
||||||
int StackLevel; // -1: query stack and resize Results, >= 0: individual stack level
|
bool OptCopyToClipboardOnCtrlC;
|
||||||
ImGuiID QueryId; // ID to query details for
|
int LastActiveFrame;
|
||||||
ImVector_ImGuiStackLevelInfo Results;
|
float CopyToClipboardLastTime;
|
||||||
bool CopyToClipboardOnCtrlC;
|
|
||||||
float CopyToClipboardLastTime;
|
|
||||||
ImGuiTextBuffer ResultPathBuf;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
@ -2305,6 +2344,15 @@ struct ImGuiContextHook_t
|
||||||
struct ImGuiContext_t
|
struct ImGuiContext_t
|
||||||
{
|
{
|
||||||
bool Initialized;
|
bool Initialized;
|
||||||
|
bool WithinFrameScope; // Set by NewFrame(), cleared by EndFrame()
|
||||||
|
bool WithinFrameScopeWithImplicitWindow; // Set by NewFrame(), cleared by EndFrame() when the implicit debug window has been pushed
|
||||||
|
bool TestEngineHookItems; // Will call test engine hooks: ImGuiTestEngineHook_ItemAdd(), ImGuiTestEngineHook_ItemInfo(), ImGuiTestEngineHook_Log()
|
||||||
|
int FrameCount;
|
||||||
|
int FrameCountEnded;
|
||||||
|
int FrameCountPlatformEnded;
|
||||||
|
int FrameCountRendered;
|
||||||
|
double Time;
|
||||||
|
char ContextName[16]; // Storage for a context name (to facilitate debugging multi-context setups)
|
||||||
ImGuiIO IO;
|
ImGuiIO IO;
|
||||||
ImGuiPlatformIO PlatformIO;
|
ImGuiPlatformIO PlatformIO;
|
||||||
ImGuiStyle Style;
|
ImGuiStyle Style;
|
||||||
|
|
@ -2319,18 +2367,8 @@ struct ImGuiContext_t
|
||||||
float FontRasterizerDensity; // Current font density. Used by all calls to GetFontBaked().
|
float FontRasterizerDensity; // Current font density. Used by all calls to GetFontBaked().
|
||||||
float CurrentDpiScale; // Current window/viewport DpiScale == CurrentViewport->DpiScale
|
float CurrentDpiScale; // Current window/viewport DpiScale == CurrentViewport->DpiScale
|
||||||
ImDrawListSharedData DrawListSharedData;
|
ImDrawListSharedData DrawListSharedData;
|
||||||
double Time;
|
|
||||||
int FrameCount;
|
|
||||||
int FrameCountEnded;
|
|
||||||
int FrameCountPlatformEnded;
|
|
||||||
int FrameCountRendered;
|
|
||||||
ImGuiID WithinEndChildID; // Set within EndChild()
|
ImGuiID WithinEndChildID; // Set within EndChild()
|
||||||
bool WithinFrameScope; // Set by NewFrame(), cleared by EndFrame()
|
|
||||||
bool WithinFrameScopeWithImplicitWindow; // Set by NewFrame(), cleared by EndFrame() when the implicit debug window has been pushed
|
|
||||||
bool GcCompactAll; // Request full GC
|
|
||||||
bool TestEngineHookItems; // Will call test engine hooks: ImGuiTestEngineHook_ItemAdd(), ImGuiTestEngineHook_ItemInfo(), ImGuiTestEngineHook_Log()
|
|
||||||
void* TestEngine; // Test engine user data
|
void* TestEngine; // Test engine user data
|
||||||
char ContextName[16]; // Storage for a context name (to facilitate debugging multi-context setups)
|
|
||||||
|
|
||||||
// Inputs
|
// Inputs
|
||||||
ImVector_ImGuiInputEvent InputEventsQueue; // Input events which will be trickled/written into IO structure.
|
ImVector_ImGuiInputEvent InputEventsQueue; // Input events which will be trickled/written into IO structure.
|
||||||
|
|
@ -2362,7 +2400,7 @@ struct ImGuiContext_t
|
||||||
|
|
||||||
// Item/widgets state and tracking information
|
// Item/widgets state and tracking information
|
||||||
ImGuiID DebugDrawIdConflictsId; // Set when we detect multiple items with the same identifier
|
ImGuiID DebugDrawIdConflictsId; // Set when we detect multiple items with the same identifier
|
||||||
ImGuiID DebugHookIdInfo; // Will call core hooks: DebugHookIdInfo() from GetID functions, used by ID Stack Tool [next HoveredId/ActiveId to not pull in an extra cache-line]
|
ImGuiID DebugHookIdInfoId; // Will call core hooks: DebugHookIdInfo() from GetID functions, used by ID Stack Tool [next HoveredId/ActiveId to not pull in an extra cache-line]
|
||||||
ImGuiID HoveredId; // Hovered widget, filled during the frame
|
ImGuiID HoveredId; // Hovered widget, filled during the frame
|
||||||
ImGuiID HoveredIdPreviousFrame;
|
ImGuiID HoveredIdPreviousFrame;
|
||||||
int HoveredIdPreviousFrameItemCount; // Count numbers of items using the same ID as last frame's hovered id
|
int HoveredIdPreviousFrameItemCount; // Count numbers of items using the same ID as last frame's hovered id
|
||||||
|
|
@ -2381,11 +2419,11 @@ struct ImGuiContext_t
|
||||||
bool ActiveIdHasBeenEditedBefore; // Was the value associated to the widget Edited over the course of the Active state.
|
bool ActiveIdHasBeenEditedBefore; // Was the value associated to the widget Edited over the course of the Active state.
|
||||||
bool ActiveIdHasBeenEditedThisFrame;
|
bool ActiveIdHasBeenEditedThisFrame;
|
||||||
bool ActiveIdFromShortcut;
|
bool ActiveIdFromShortcut;
|
||||||
|
ImS8 ActiveIdMouseButton;
|
||||||
ImGuiID ActiveIdDisabledId; // When clicking a disabled item we set ActiveId=window->MoveId to avoid interference with widget code. Actual item ID is stored here.
|
ImGuiID ActiveIdDisabledId; // When clicking a disabled item we set ActiveId=window->MoveId to avoid interference with widget code. Actual item ID is stored here.
|
||||||
int ActiveIdMouseButton : 8;
|
|
||||||
ImVec2 ActiveIdClickOffset; // Clicked offset from upper-left corner, if applicable (currently only set by ButtonBehavior)
|
ImVec2 ActiveIdClickOffset; // Clicked offset from upper-left corner, if applicable (currently only set by ButtonBehavior)
|
||||||
ImGuiWindow* ActiveIdWindow;
|
|
||||||
ImGuiInputSource ActiveIdSource; // Activating source: ImGuiInputSource_Mouse OR ImGuiInputSource_Keyboard OR ImGuiInputSource_Gamepad
|
ImGuiInputSource ActiveIdSource; // Activating source: ImGuiInputSource_Mouse OR ImGuiInputSource_Keyboard OR ImGuiInputSource_Gamepad
|
||||||
|
ImGuiWindow* ActiveIdWindow;
|
||||||
ImGuiID ActiveIdPreviousFrame;
|
ImGuiID ActiveIdPreviousFrame;
|
||||||
ImGuiDeactivatedItemData DeactivatedItemData;
|
ImGuiDeactivatedItemData DeactivatedItemData;
|
||||||
ImGuiDataTypeStorage ActiveIdValueOnActivation; // Backup of initial value at the time of activation. ONLY SET BY SPECIFIC WIDGETS: DragXXX and SliderXXX.
|
ImGuiDataTypeStorage ActiveIdValueOnActivation; // Backup of initial value at the time of activation. ONLY SET BY SPECIFIC WIDGETS: DragXXX and SliderXXX.
|
||||||
|
|
@ -2415,6 +2453,7 @@ struct ImGuiContext_t
|
||||||
ImGuiLastItemData LastItemData; // Storage for last submitted item (setup by ItemAdd)
|
ImGuiLastItemData LastItemData; // Storage for last submitted item (setup by ItemAdd)
|
||||||
ImGuiNextWindowData NextWindowData; // Storage for SetNextWindow** functions
|
ImGuiNextWindowData NextWindowData; // Storage for SetNextWindow** functions
|
||||||
bool DebugShowGroupRects;
|
bool DebugShowGroupRects;
|
||||||
|
bool GcCompactAll; // Request full GC
|
||||||
|
|
||||||
// Shared stacks
|
// Shared stacks
|
||||||
ImGuiCol DebugFlashStyleColorIdx; // (Keep close to ColorStack to share cache line)
|
ImGuiCol DebugFlashStyleColorIdx; // (Keep close to ColorStack to share cache line)
|
||||||
|
|
@ -2460,7 +2499,7 @@ struct ImGuiContext_t
|
||||||
float NavHighlightActivatedTimer;
|
float NavHighlightActivatedTimer;
|
||||||
ImGuiID NavNextActivateId; // Set by ActivateItemByID(), queued until next frame.
|
ImGuiID NavNextActivateId; // Set by ActivateItemByID(), queued until next frame.
|
||||||
ImGuiActivateFlags NavNextActivateFlags;
|
ImGuiActivateFlags NavNextActivateFlags;
|
||||||
ImGuiInputSource NavInputSource; // Keyboard or Gamepad mode? THIS CAN ONLY BE ImGuiInputSource_Keyboard or ImGuiInputSource_Mouse
|
ImGuiInputSource NavInputSource; // Keyboard or Gamepad mode? THIS CAN ONLY BE ImGuiInputSource_Keyboard or ImGuiInputSource_Gamepad
|
||||||
ImGuiSelectionUserData NavLastValidSelectionUserData; // Last valid data passed to SetNextItemSelectionUser(), or -1. For current window. Not reset when focusing an item that doesn't have selection data.
|
ImGuiSelectionUserData NavLastValidSelectionUserData; // Last valid data passed to SetNextItemSelectionUser(), or -1. For current window. Not reset when focusing an item that doesn't have selection data.
|
||||||
ImS8 NavCursorHideFrames;
|
ImS8 NavCursorHideFrames;
|
||||||
//ImGuiID NavActivateInputId; // Removed in 1.89.4 (July 2023). This is now part of g.NavActivateId and sets g.NavActivateFlags |= ImGuiActivateFlags_PreferInput. See commit c9a53aa74, issue #5606.
|
//ImGuiID NavActivateInputId; // Removed in 1.89.4 (July 2023). This is now part of g.NavActivateId and sets g.NavActivateFlags |= ImGuiActivateFlags_PreferInput. See commit c9a53aa74, issue #5606.
|
||||||
|
|
@ -2497,13 +2536,13 @@ struct ImGuiContext_t
|
||||||
bool NavJustMovedToIsTabbing; // Copy of ImGuiNavMoveFlags_IsTabbing. Maybe we should store whole flags.
|
bool NavJustMovedToIsTabbing; // Copy of ImGuiNavMoveFlags_IsTabbing. Maybe we should store whole flags.
|
||||||
bool NavJustMovedToHasSelectionData; // Copy of move result's ItemFlags & ImGuiItemFlags_HasSelectionUserData). Maybe we should just store ImGuiNavItemData.
|
bool NavJustMovedToHasSelectionData; // Copy of move result's ItemFlags & ImGuiItemFlags_HasSelectionUserData). Maybe we should just store ImGuiNavItemData.
|
||||||
|
|
||||||
// Navigation: Windowing (CTRL+TAB for list, or Menu button + keys or directional pads to move/resize)
|
// Navigation: Windowing (Ctrl+Tab for list, or Menu button + keys or directional pads to move/resize)
|
||||||
bool ConfigNavWindowingWithGamepad; // = true. Enable CTRL+TAB by holding ImGuiKey_GamepadFaceLeft (== ImGuiKey_NavGamepadMenu). When false, the button may still be used to toggle Menu layer.
|
bool ConfigNavWindowingWithGamepad; // = true. Enable Ctrl+Tab by holding ImGuiKey_GamepadFaceLeft (== ImGuiKey_NavGamepadMenu). When false, the button may still be used to toggle Menu layer.
|
||||||
ImGuiKeyChord ConfigNavWindowingKeyNext; // = ImGuiMod_Ctrl | ImGuiKey_Tab (or ImGuiMod_Super | ImGuiKey_Tab on OS X). For reconfiguration (see #4828)
|
ImGuiKeyChord ConfigNavWindowingKeyNext; // = ImGuiMod_Ctrl | ImGuiKey_Tab (or ImGuiMod_Super | ImGuiKey_Tab on OS X). For reconfiguration (see #4828)
|
||||||
ImGuiKeyChord ConfigNavWindowingKeyPrev; // = ImGuiMod_Ctrl | ImGuiMod_Shift | ImGuiKey_Tab (or ImGuiMod_Super | ImGuiMod_Shift | ImGuiKey_Tab on OS X)
|
ImGuiKeyChord ConfigNavWindowingKeyPrev; // = ImGuiMod_Ctrl | ImGuiMod_Shift | ImGuiKey_Tab (or ImGuiMod_Super | ImGuiMod_Shift | ImGuiKey_Tab on OS X)
|
||||||
ImGuiWindow* NavWindowingTarget; // Target window when doing CTRL+Tab (or Pad Menu + FocusPrev/Next), this window is temporarily displayed top-most!
|
ImGuiWindow* NavWindowingTarget; // Target window when doing Ctrl+Tab (or Pad Menu + FocusPrev/Next), this window is temporarily displayed top-most!
|
||||||
ImGuiWindow* NavWindowingTargetAnim; // Record of last valid NavWindowingTarget until DimBgRatio and NavWindowingHighlightAlpha becomes 0.0f, so the fade-out can stay on it.
|
ImGuiWindow* NavWindowingTargetAnim; // Record of last valid NavWindowingTarget until DimBgRatio and NavWindowingHighlightAlpha becomes 0.0f, so the fade-out can stay on it.
|
||||||
ImGuiWindow* NavWindowingListWindow; // Internal window actually listing the CTRL+Tab contents
|
ImGuiWindow* NavWindowingListWindow; // Internal window actually listing the Ctrl+Tab contents
|
||||||
float NavWindowingTimer;
|
float NavWindowingTimer;
|
||||||
float NavWindowingHighlightAlpha;
|
float NavWindowingHighlightAlpha;
|
||||||
ImGuiInputSource NavWindowingInputSource;
|
ImGuiInputSource NavWindowingInputSource;
|
||||||
|
|
@ -2513,7 +2552,7 @@ struct ImGuiContext_t
|
||||||
ImVec2 NavWindowingAccumDeltaSize;
|
ImVec2 NavWindowingAccumDeltaSize;
|
||||||
|
|
||||||
// Render
|
// Render
|
||||||
float DimBgRatio; // 0.0..1.0 animation when fading in a dimming background (for modal window and CTRL+TAB list)
|
float DimBgRatio; // 0.0..1.0 animation when fading in a dimming background (for modal window and Ctrl+Tab list)
|
||||||
|
|
||||||
// Drag and Drop
|
// Drag and Drop
|
||||||
bool DragDropActive;
|
bool DragDropActive;
|
||||||
|
|
@ -2526,7 +2565,9 @@ struct ImGuiContext_t
|
||||||
ImRect DragDropTargetRect; // Store rectangle of current target candidate (we favor small targets when overlapping)
|
ImRect DragDropTargetRect; // Store rectangle of current target candidate (we favor small targets when overlapping)
|
||||||
ImRect DragDropTargetClipRect; // Store ClipRect at the time of item's drawing
|
ImRect DragDropTargetClipRect; // Store ClipRect at the time of item's drawing
|
||||||
ImGuiID DragDropTargetId;
|
ImGuiID DragDropTargetId;
|
||||||
ImGuiDragDropFlags DragDropAcceptFlags;
|
ImGuiID DragDropTargetFullViewport;
|
||||||
|
ImGuiDragDropFlags DragDropAcceptFlagsCurr;
|
||||||
|
ImGuiDragDropFlags DragDropAcceptFlagsPrev;
|
||||||
float DragDropAcceptIdCurrRectSurface; // Target item surface (we resolve overlapping targets by prioritizing the smaller surface)
|
float DragDropAcceptIdCurrRectSurface; // Target item surface (we resolve overlapping targets by prioritizing the smaller surface)
|
||||||
ImGuiID DragDropAcceptIdCurr; // Target item id (set at the time of accepting the payload)
|
ImGuiID DragDropAcceptIdCurr; // Target item id (set at the time of accepting the payload)
|
||||||
ImGuiID DragDropAcceptIdPrev; // Target item id from previous frame (we need to store this to allow for overlapping drag and drop targets)
|
ImGuiID DragDropAcceptIdPrev; // Target item id from previous frame (we need to store this to allow for overlapping drag and drop targets)
|
||||||
|
|
@ -2576,10 +2617,11 @@ struct ImGuiContext_t
|
||||||
|
|
||||||
// Widget state
|
// Widget state
|
||||||
ImGuiInputTextState InputTextState;
|
ImGuiInputTextState InputTextState;
|
||||||
|
ImGuiTextIndex InputTextLineIndex; // Temporary storage
|
||||||
ImGuiInputTextDeactivatedState InputTextDeactivatedState;
|
ImGuiInputTextDeactivatedState InputTextDeactivatedState;
|
||||||
ImFontBaked InputTextPasswordFontBackupBaked;
|
ImFontBaked InputTextPasswordFontBackupBaked;
|
||||||
ImFontFlags InputTextPasswordFontBackupFlags;
|
ImFontFlags InputTextPasswordFontBackupFlags;
|
||||||
ImGuiID TempInputId; // Temporary text input when CTRL+clicking on a slider, etc.
|
ImGuiID TempInputId; // Temporary text input when using Ctrl+Click on a slider, etc.
|
||||||
ImGuiDataTypeStorage DataTypeZeroValue; // 0 for all data types
|
ImGuiDataTypeStorage DataTypeZeroValue; // 0 for all data types
|
||||||
int BeginMenuDepth;
|
int BeginMenuDepth;
|
||||||
int BeginComboDepth;
|
int BeginComboDepth;
|
||||||
|
|
@ -2634,14 +2676,14 @@ struct ImGuiContext_t
|
||||||
|
|
||||||
// Capture/Logging
|
// Capture/Logging
|
||||||
bool LogEnabled; // Currently capturing
|
bool LogEnabled; // Currently capturing
|
||||||
|
bool LogLineFirstItem;
|
||||||
ImGuiLogFlags LogFlags; // Capture flags/type
|
ImGuiLogFlags LogFlags; // Capture flags/type
|
||||||
ImGuiWindow* LogWindow;
|
ImGuiWindow* LogWindow;
|
||||||
ImFileHandle LogFile; // If != NULL log to stdout/ file
|
ImFileHandle LogFile; // If != NULL log to stdout/ file
|
||||||
ImGuiTextBuffer LogBuffer; // Accumulation buffer when log to clipboard. This is pointer so our GImGui static constructor doesn't call heap allocators.
|
ImGuiTextBuffer LogBuffer; // Accumulation buffer when log to clipboard. This is pointer so our GImGui static constructor doesn't call heap allocators.
|
||||||
const char* LogNextPrefix;
|
const char* LogNextPrefix; // See comment in LogSetNextTextDecoration(): doesn't copy underlying data, use carefully!
|
||||||
const char* LogNextSuffix;
|
const char* LogNextSuffix;
|
||||||
float LogLinePosY;
|
float LogLinePosY;
|
||||||
bool LogLineFirstItem;
|
|
||||||
int LogDepthRef;
|
int LogDepthRef;
|
||||||
int LogDepthToExpand;
|
int LogDepthToExpand;
|
||||||
int LogDepthToExpandDefault; // Default/stored value for LogDepthMaxExpand if not specified in the LogXXX function call.
|
int LogDepthToExpandDefault; // Default/stored value for LogDepthMaxExpand if not specified in the LogXXX function call.
|
||||||
|
|
@ -2657,7 +2699,7 @@ struct ImGuiContext_t
|
||||||
|
|
||||||
// Debug Tools
|
// Debug Tools
|
||||||
// (some of the highly frequently used data are interleaved in other structures above: DebugBreakXXX fields, DebugHookIdInfo, DebugLocateId etc.)
|
// (some of the highly frequently used data are interleaved in other structures above: DebugBreakXXX fields, DebugHookIdInfo, DebugLocateId etc.)
|
||||||
int DebugDrawIdConflictsCount; // Locked count (preserved when holding CTRL)
|
int DebugDrawIdConflictsCount; // Locked count (preserved when holding Ctrl)
|
||||||
ImGuiDebugLogFlags DebugLogFlags;
|
ImGuiDebugLogFlags DebugLogFlags;
|
||||||
ImGuiTextBuffer DebugLogBuf;
|
ImGuiTextBuffer DebugLogBuf;
|
||||||
ImGuiTextIndex DebugLogIndex;
|
ImGuiTextIndex DebugLogIndex;
|
||||||
|
|
@ -2674,6 +2716,7 @@ struct ImGuiContext_t
|
||||||
float DebugFlashStyleColorTime;
|
float DebugFlashStyleColorTime;
|
||||||
ImVec4 DebugFlashStyleColorBackup;
|
ImVec4 DebugFlashStyleColorBackup;
|
||||||
ImGuiMetricsConfig DebugMetricsConfig;
|
ImGuiMetricsConfig DebugMetricsConfig;
|
||||||
|
ImGuiDebugItemPathQuery DebugItemPathQuery;
|
||||||
ImGuiIDStackTool DebugIDStackTool;
|
ImGuiIDStackTool DebugIDStackTool;
|
||||||
ImGuiDebugAllocInfo DebugAllocInfo;
|
ImGuiDebugAllocInfo DebugAllocInfo;
|
||||||
ImGuiDockNode* DebugHoveredDockNode; // Hovered dock node.
|
ImGuiDockNode* DebugHoveredDockNode; // Hovered dock node.
|
||||||
|
|
@ -2816,13 +2859,14 @@ struct ImGuiWindow_t
|
||||||
short BeginOrderWithinParent; // Begin() order within immediate parent window, if we are a child window. Otherwise 0.
|
short BeginOrderWithinParent; // Begin() order within immediate parent window, if we are a child window. Otherwise 0.
|
||||||
short BeginOrderWithinContext; // Begin() order within entire imgui context. This is mostly used for debugging submission order related issues.
|
short BeginOrderWithinContext; // Begin() order within entire imgui context. This is mostly used for debugging submission order related issues.
|
||||||
short FocusOrder; // Order within WindowsFocusOrder[], altered when windows are focused.
|
short FocusOrder; // Order within WindowsFocusOrder[], altered when windows are focused.
|
||||||
|
ImGuiDir AutoPosLastDirection;
|
||||||
ImS8 AutoFitFramesX, AutoFitFramesY;
|
ImS8 AutoFitFramesX, AutoFitFramesY;
|
||||||
bool AutoFitOnlyGrows;
|
bool AutoFitOnlyGrows;
|
||||||
ImGuiDir AutoPosLastDirection;
|
|
||||||
ImS8 HiddenFramesCanSkipItems; // Hide the window for N frames
|
ImS8 HiddenFramesCanSkipItems; // Hide the window for N frames
|
||||||
ImS8 HiddenFramesCannotSkipItems; // Hide the window for N frames while allowing items to be submitted so we can measure their size
|
ImS8 HiddenFramesCannotSkipItems; // Hide the window for N frames while allowing items to be submitted so we can measure their size
|
||||||
ImS8 HiddenFramesForRenderOnly; // Hide the window until frame N at Render() time only
|
ImS8 HiddenFramesForRenderOnly; // Hide the window until frame N at Render() time only
|
||||||
ImS8 DisableInputsFrames; // Disable window interactions for N frames
|
ImS8 DisableInputsFrames; // Disable window interactions for N frames
|
||||||
|
ImGuiWindowBgClickFlags BgClickFlags : 8; // Configure behavior of click+dragging on window bg/void or over items. Default sets by io.ConfigWindowsMoveFromTitleBarOnly. If you use this please report in #3379.
|
||||||
ImGuiCond SetWindowPosAllowFlags : 8; // store acceptable condition flags for SetNextWindowPos() use.
|
ImGuiCond SetWindowPosAllowFlags : 8; // store acceptable condition flags for SetNextWindowPos() use.
|
||||||
ImGuiCond SetWindowSizeAllowFlags : 8; // store acceptable condition flags for SetNextWindowSize() use.
|
ImGuiCond SetWindowSizeAllowFlags : 8; // store acceptable condition flags for SetNextWindowSize() use.
|
||||||
ImGuiCond SetWindowCollapsedAllowFlags : 8; // store acceptable condition flags for SetNextWindowCollapsed() use.
|
ImGuiCond SetWindowCollapsedAllowFlags : 8; // store acceptable condition flags for SetNextWindowCollapsed() use.
|
||||||
|
|
@ -2865,7 +2909,7 @@ struct ImGuiWindow_t
|
||||||
ImGuiWindow* RootWindowDockTree; // Point to ourself or first ancestor that is not a child window. Cross through dock nodes.
|
ImGuiWindow* RootWindowDockTree; // Point to ourself or first ancestor that is not a child window. Cross through dock nodes.
|
||||||
ImGuiWindow* RootWindowForTitleBarHighlight; // Point to ourself or first ancestor which will display TitleBgActive color when this window is active.
|
ImGuiWindow* RootWindowForTitleBarHighlight; // Point to ourself or first ancestor which will display TitleBgActive color when this window is active.
|
||||||
ImGuiWindow* RootWindowForNav; // Point to ourself or first ancestor which doesn't have the NavFlattened flag.
|
ImGuiWindow* RootWindowForNav; // Point to ourself or first ancestor which doesn't have the NavFlattened flag.
|
||||||
ImGuiWindow* ParentWindowForFocusRoute; // Set to manual link a window to its logical parent so that Shortcut() chain are honoerd (e.g. Tool linked to Document)
|
ImGuiWindow* ParentWindowForFocusRoute; // Set to manual link a window to its logical parent so that Shortcut() chain are honored (e.g. Tool linked to Document)
|
||||||
|
|
||||||
ImGuiWindow* NavLastChildNavWindow; // When going to the menu bar, we remember the child window we came from. (This could probably be made implicit if we kept g.Windows sorted by last focused including child window.)
|
ImGuiWindow* NavLastChildNavWindow; // When going to the menu bar, we remember the child window we came from. (This could probably be made implicit if we kept g.Windows sorted by last focused including child window.)
|
||||||
ImGuiID NavLastIds[ImGuiNavLayer_COUNT]; // Last known NavId for this window, per layer (0/1)
|
ImGuiID NavLastIds[ImGuiNavLayer_COUNT]; // Last known NavId for this window, per layer (0/1)
|
||||||
|
|
@ -2888,7 +2932,7 @@ struct ImGuiWindow_t
|
||||||
ImGuiDockNode* DockNodeAsHost; // Which node are we owning (for parent windows)
|
ImGuiDockNode* DockNodeAsHost; // Which node are we owning (for parent windows)
|
||||||
ImGuiID DockId; // Backup of last valid DockNode->ID, so single window remember their dock node id even when they are not bound any more
|
ImGuiID DockId; // Backup of last valid DockNode->ID, so single window remember their dock node id even when they are not bound any more
|
||||||
|
|
||||||
// [Obsolete] ImGuiWindow::CalcFontSize() was removed in 1.92.x because error-prone/misleading. You can use window->FontRefSize for a copy of g.FontSize at the time of the last Begin() call for this window.
|
// [OBSOLETE] ImGuiWindow::CalcFontSize() was removed in 1.92.0 because error-prone/misleading. You can use window->FontRefSize for a copy of g.FontSize at the time of the last Begin() call for this window.
|
||||||
//float CalcFontSize() const { ImGuiContext& g = *Ctx; return g.FontSizeBase * FontWindowScale * FontDpiScale * FontWindowScaleParents;
|
//float CalcFontSize() const { ImGuiContext& g = *Ctx; return g.FontSizeBase * FontWindowScale * FontDpiScale * FontWindowScaleParents;
|
||||||
};
|
};
|
||||||
CIMGUI_API ImGuiID ImGuiWindow_GetIDStr(ImGuiWindow* self, const char* str); // Implied str_end = NULL
|
CIMGUI_API ImGuiID ImGuiWindow_GetIDStr(ImGuiWindow* self, const char* str); // Implied str_end = NULL
|
||||||
|
|
@ -2951,7 +2995,7 @@ struct ImGuiTabBar_t
|
||||||
ImGuiID ID; // Zero for tab-bars used by docking
|
ImGuiID ID; // Zero for tab-bars used by docking
|
||||||
ImGuiID SelectedTabId; // Selected tab/window
|
ImGuiID SelectedTabId; // Selected tab/window
|
||||||
ImGuiID NextSelectedTabId; // Next selected tab/window. Will also trigger a scrolling animation
|
ImGuiID NextSelectedTabId; // Next selected tab/window. Will also trigger a scrolling animation
|
||||||
ImGuiID VisibleTabId; // Can occasionally be != SelectedTabId (e.g. when previewing contents for CTRL+TAB preview)
|
ImGuiID VisibleTabId; // Can occasionally be != SelectedTabId (e.g. when previewing contents for Ctrl+Tab preview)
|
||||||
int CurrFrameVisible;
|
int CurrFrameVisible;
|
||||||
int PrevFrameVisible;
|
int PrevFrameVisible;
|
||||||
ImRect BarRect;
|
ImRect BarRect;
|
||||||
|
|
@ -3175,7 +3219,7 @@ struct ImGuiTable_t
|
||||||
bool IsContextPopupOpen; // Set when default context menu is open (also see: ContextPopupColumn, InstanceInteracted).
|
bool IsContextPopupOpen; // Set when default context menu is open (also see: ContextPopupColumn, InstanceInteracted).
|
||||||
bool DisableDefaultContextMenu; // Disable default context menu. You may submit your own using TableBeginContextMenuPopup()/EndPopup()
|
bool DisableDefaultContextMenu; // Disable default context menu. You may submit your own using TableBeginContextMenuPopup()/EndPopup()
|
||||||
bool IsSettingsRequestLoad;
|
bool IsSettingsRequestLoad;
|
||||||
bool IsSettingsDirty; // Set when table settings have changed and needs to be reported into ImGuiTableSetttings data.
|
bool IsSettingsDirty; // Set when table settings have changed and needs to be reported into ImGuiTableSettings data.
|
||||||
bool IsDefaultDisplayOrder; // Set when display order is unchanged from default (DisplayOrder contains 0...Count-1)
|
bool IsDefaultDisplayOrder; // Set when display order is unchanged from default (DisplayOrder contains 0...Count-1)
|
||||||
bool IsResetAllRequest;
|
bool IsResetAllRequest;
|
||||||
bool IsResetDisplayOrderRequest;
|
bool IsResetDisplayOrderRequest;
|
||||||
|
|
@ -3196,6 +3240,7 @@ struct ImGuiTable_t
|
||||||
// sizeof() ~ 136 bytes.
|
// sizeof() ~ 136 bytes.
|
||||||
struct ImGuiTableTempData_t
|
struct ImGuiTableTempData_t
|
||||||
{
|
{
|
||||||
|
ImGuiID WindowID; // Shortcut to g.Tables[TableIndex]->OuterWindow->ID.
|
||||||
int TableIndex; // Index in g.Tables.Buf[] pool
|
int TableIndex; // Index in g.Tables.Buf[] pool
|
||||||
float LastTimeActive; // Last timestamp this structure was used
|
float LastTimeActive; // Last timestamp this structure was used
|
||||||
float AngledHeadersExtraWidth; // Used in EndTable()
|
float AngledHeadersExtraWidth; // Used in EndTable()
|
||||||
|
|
@ -3259,6 +3304,7 @@ CIMGUI_API void ImGui_UpdateWindowParentAndRootLinks(ImGuiWindow* wi
|
||||||
CIMGUI_API void ImGui_UpdateWindowSkipRefresh(ImGuiWindow* window);
|
CIMGUI_API void ImGui_UpdateWindowSkipRefresh(ImGuiWindow* window);
|
||||||
CIMGUI_API ImVec2 ImGui_CalcWindowNextAutoFitSize(ImGuiWindow* window);
|
CIMGUI_API ImVec2 ImGui_CalcWindowNextAutoFitSize(ImGuiWindow* window);
|
||||||
CIMGUI_API bool ImGui_IsWindowChildOf(ImGuiWindow* window, ImGuiWindow* potential_parent, bool popup_hierarchy, bool dock_hierarchy);
|
CIMGUI_API bool ImGui_IsWindowChildOf(ImGuiWindow* window, ImGuiWindow* potential_parent, bool popup_hierarchy, bool dock_hierarchy);
|
||||||
|
CIMGUI_API bool ImGui_IsWindowInBeginStack(ImGuiWindow* window);
|
||||||
CIMGUI_API bool ImGui_IsWindowWithinBeginStackOf(ImGuiWindow* window, ImGuiWindow* potential_parent);
|
CIMGUI_API bool ImGui_IsWindowWithinBeginStackOf(ImGuiWindow* window, ImGuiWindow* potential_parent);
|
||||||
CIMGUI_API bool ImGui_IsWindowAbove(ImGuiWindow* potential_above, ImGuiWindow* potential_below);
|
CIMGUI_API bool ImGui_IsWindowAbove(ImGuiWindow* potential_above, ImGuiWindow* potential_below);
|
||||||
CIMGUI_API bool ImGui_IsWindowNavFocusable(ImGuiWindow* window);
|
CIMGUI_API bool ImGui_IsWindowNavFocusable(ImGuiWindow* window);
|
||||||
|
|
@ -3393,6 +3439,7 @@ CIMGUI_API ImVec2 ImGui_CalcItemSize(ImVec2 size, float default_w, float default
|
||||||
CIMGUI_API float ImGui_CalcWrapWidthForPos(ImVec2 pos, float wrap_pos_x);
|
CIMGUI_API float ImGui_CalcWrapWidthForPos(ImVec2 pos, float wrap_pos_x);
|
||||||
CIMGUI_API void ImGui_PushMultiItemsWidths(int components, float width_full);
|
CIMGUI_API void ImGui_PushMultiItemsWidths(int components, float width_full);
|
||||||
CIMGUI_API void ImGui_ShrinkWidths(ImGuiShrinkWidthItem* items, int count, float width_excess, float width_min);
|
CIMGUI_API void ImGui_ShrinkWidths(ImGuiShrinkWidthItem* items, int count, float width_excess, float width_min);
|
||||||
|
CIMGUI_API void ImGui_CalcClipRectVisibleItemsY(ImRect clip_rect, ImVec2 pos, float items_height, int* out_visible_start, int* out_visible_end);
|
||||||
|
|
||||||
// Parameter stacks (shared)
|
// Parameter stacks (shared)
|
||||||
CIMGUI_API const ImGuiStyleVarInfo* ImGui_GetStyleVarInfo(ImGuiStyleVar idx);
|
CIMGUI_API const ImGuiStyleVarInfo* ImGui_GetStyleVarInfo(ImGuiStyleVar idx);
|
||||||
|
|
@ -3520,7 +3567,7 @@ CIMGUI_API ImGuiKeyOwnerData* ImGui_GetKeyOwnerData(ImGuiContext* ctx, ImGuiKey
|
||||||
// - Binding generators may want to ignore those for now, or suffix them with Ex() until we decide if this gets moved into public API.
|
// - Binding generators may want to ignore those for now, or suffix them with Ex() until we decide if this gets moved into public API.
|
||||||
CIMGUI_API bool ImGui_IsKeyDownID(ImGuiKey key, ImGuiID owner_id);
|
CIMGUI_API bool ImGui_IsKeyDownID(ImGuiKey key, ImGuiID owner_id);
|
||||||
CIMGUI_API bool ImGui_IsKeyPressedImGuiInputFlags(ImGuiKey key, ImGuiInputFlags flags); // Implied owner_id = 0
|
CIMGUI_API bool ImGui_IsKeyPressedImGuiInputFlags(ImGuiKey key, ImGuiInputFlags flags); // Implied owner_id = 0
|
||||||
CIMGUI_API bool ImGui_IsKeyPressedImGuiInputFlagsEx(ImGuiKey key, ImGuiInputFlags flags, ImGuiID owner_id /* = 0 */); // Important: when transitioning from old to new IsKeyPressed(): old API has "bool repeat = true", so would default to repeat. New API requiress explicit ImGuiInputFlags_Repeat.
|
CIMGUI_API bool ImGui_IsKeyPressedImGuiInputFlagsEx(ImGuiKey key, ImGuiInputFlags flags, ImGuiID owner_id /* = 0 */); // Important: when transitioning from old to new IsKeyPressed(): old API has "bool repeat = true", so would default to repeat. New API requires explicit ImGuiInputFlags_Repeat.
|
||||||
CIMGUI_API bool ImGui_IsKeyReleasedID(ImGuiKey key, ImGuiID owner_id);
|
CIMGUI_API bool ImGui_IsKeyReleasedID(ImGuiKey key, ImGuiID owner_id);
|
||||||
CIMGUI_API bool ImGui_IsKeyChordPressedImGuiInputFlags(ImGuiKeyChord key_chord, ImGuiInputFlags flags); // Implied owner_id = 0
|
CIMGUI_API bool ImGui_IsKeyChordPressedImGuiInputFlags(ImGuiKeyChord key_chord, ImGuiInputFlags flags); // Implied owner_id = 0
|
||||||
CIMGUI_API bool ImGui_IsKeyChordPressedImGuiInputFlagsEx(ImGuiKeyChord key_chord, ImGuiInputFlags flags, ImGuiID owner_id /* = 0 */);
|
CIMGUI_API bool ImGui_IsKeyChordPressedImGuiInputFlagsEx(ImGuiKeyChord key_chord, ImGuiInputFlags flags, ImGuiID owner_id /* = 0 */);
|
||||||
|
|
@ -3622,9 +3669,12 @@ CIMGUI_API ImGuiID ImGui_GetCurrentFocusScope(void); // Focus scope we are outp
|
||||||
// Drag and Drop
|
// Drag and Drop
|
||||||
CIMGUI_API bool ImGui_IsDragDropActive(void);
|
CIMGUI_API bool ImGui_IsDragDropActive(void);
|
||||||
CIMGUI_API bool ImGui_BeginDragDropTargetCustom(ImRect bb, ImGuiID id);
|
CIMGUI_API bool ImGui_BeginDragDropTargetCustom(ImRect bb, ImGuiID id);
|
||||||
|
CIMGUI_API bool ImGui_BeginDragDropTargetViewport(ImGuiViewport* viewport); // Implied p_bb = NULL
|
||||||
|
CIMGUI_API bool ImGui_BeginDragDropTargetViewportEx(ImGuiViewport* viewport, const ImRect* p_bb /* = NULL */);
|
||||||
CIMGUI_API void ImGui_ClearDragDrop(void);
|
CIMGUI_API void ImGui_ClearDragDrop(void);
|
||||||
CIMGUI_API bool ImGui_IsDragDropPayloadBeingAccepted(void);
|
CIMGUI_API bool ImGui_IsDragDropPayloadBeingAccepted(void);
|
||||||
CIMGUI_API void ImGui_RenderDragDropTargetRect(ImRect bb, ImRect item_clip_rect);
|
CIMGUI_API void ImGui_RenderDragDropTargetRectForItem(ImRect bb);
|
||||||
|
CIMGUI_API void ImGui_RenderDragDropTargetRectEx(ImDrawList* draw_list, ImRect bb);
|
||||||
|
|
||||||
// Typing-Select API
|
// Typing-Select API
|
||||||
// (provide Windows Explorer style "select items by typing partial name" + "cycle through items by typing same letter" feature)
|
// (provide Windows Explorer style "select items by typing partial name" + "cycle through items by typing same letter" feature)
|
||||||
|
|
@ -3722,6 +3772,8 @@ CIMGUI_API ImGuiTableSettings* ImGui_TableSettingsFindByID(ImGuiID id);
|
||||||
|
|
||||||
// Tab Bars
|
// Tab Bars
|
||||||
CIMGUI_API ImGuiTabBar* ImGui_GetCurrentTabBar(void);
|
CIMGUI_API ImGuiTabBar* ImGui_GetCurrentTabBar(void);
|
||||||
|
CIMGUI_API ImGuiTabBar* ImGui_TabBarFindByID(ImGuiID id);
|
||||||
|
CIMGUI_API void ImGui_TabBarRemove(ImGuiTabBar* tab_bar);
|
||||||
CIMGUI_API bool ImGui_BeginTabBarEx(ImGuiTabBar* tab_bar, ImRect bb, ImGuiTabBarFlags flags);
|
CIMGUI_API bool ImGui_BeginTabBarEx(ImGuiTabBar* tab_bar, ImRect bb, ImGuiTabBarFlags flags);
|
||||||
CIMGUI_API ImGuiTabItem* ImGui_TabBarFindTabByID(ImGuiTabBar* tab_bar, ImGuiID tab_id);
|
CIMGUI_API ImGuiTabItem* ImGui_TabBarFindTabByID(ImGuiTabBar* tab_bar, ImGuiID tab_id);
|
||||||
CIMGUI_API ImGuiTabItem* ImGui_TabBarFindTabByOrder(ImGuiTabBar* tab_bar, int order);
|
CIMGUI_API ImGuiTabItem* ImGui_TabBarFindTabByOrder(ImGuiTabBar* tab_bar, int order);
|
||||||
|
|
@ -3955,11 +4007,11 @@ typedef ImFontLoader ImFontBuilderIO; // [renamed/changed in 1.92] The types ar
|
||||||
#define IMGUI_FONT_SIZE_THRESHOLD_FOR_LOADADVANCEXONLYMODE (128.0f)
|
#define IMGUI_FONT_SIZE_THRESHOLD_FOR_LOADADVANCEXONLYMODE (128.0f)
|
||||||
|
|
||||||
// Refer to ImFontAtlasPackGetRect() to better understand how this works.
|
// Refer to ImFontAtlasPackGetRect() to better understand how this works.
|
||||||
#define ImFontAtlasRectId_IndexMask_ (0x000FFFFF) // 20-bits: index to access builder->RectsIndex[].
|
#define ImFontAtlasRectId_IndexMask_ (0x0007FFFF) // 20-bits signed: index to access builder->RectsIndex[].
|
||||||
#define ImFontAtlasRectId_GenerationMask_ (0x3FF00000) // 10-bits: entry generation, so each ID is unique and get can safely detected old identifiers.
|
#define ImFontAtlasRectId_GenerationMask_ (0x3FF00000) // 10-bits: entry generation, so each ID is unique and get can safely detected old identifiers.
|
||||||
#define ImFontAtlasRectId_GenerationShift_ (20)
|
#define ImFontAtlasRectId_GenerationShift_ (20)
|
||||||
CIMGUI_API int cImFontAtlasRectId_GetIndex(ImFontAtlasRectId id);
|
CIMGUI_API int cImFontAtlasRectId_GetIndex(ImFontAtlasRectId id);
|
||||||
CIMGUI_API int cImFontAtlasRectId_GetGeneration(ImFontAtlasRectId id);
|
CIMGUI_API unsigned int cImFontAtlasRectId_GetGeneration(ImFontAtlasRectId id);
|
||||||
CIMGUI_API ImFontAtlasRectId cImFontAtlasRectId_Make(int index_idx, int gen_idx);
|
CIMGUI_API ImFontAtlasRectId cImFontAtlasRectId_Make(int index_idx, int gen_idx);
|
||||||
|
|
||||||
// Packed rectangle lookup entry (we need an indirection to allow removing/reordering rectangles)
|
// Packed rectangle lookup entry (we need an indirection to allow removing/reordering rectangles)
|
||||||
|
|
@ -3970,7 +4022,7 @@ CIMGUI_API ImFontAtlasRectId cImFontAtlasRectId_Make(int index_idx, int gen_idx)
|
||||||
struct ImFontAtlasRectEntry_t
|
struct ImFontAtlasRectEntry_t
|
||||||
{
|
{
|
||||||
int TargetIndex : 20; // When Used: ImFontAtlasRectId -> into Rects[]. When unused: index to next unused RectsIndex[] slot to consume free-list.
|
int TargetIndex : 20; // When Used: ImFontAtlasRectId -> into Rects[]. When unused: index to next unused RectsIndex[] slot to consume free-list.
|
||||||
int Generation : 10; // Increased each time the entry is reused for a new rectangle.
|
unsigned int Generation : 10; // Increased each time the entry is reused for a new rectangle.
|
||||||
unsigned int IsUsed : 1;
|
unsigned int IsUsed : 1;
|
||||||
};
|
};
|
||||||
struct ImVector_ImFontAtlasRectEntry_t { int Size; int Capacity; ImFontAtlasRectEntry* Data; }; // Instantiation of ImVector<ImFontAtlasRectEntry>
|
struct ImVector_ImFontAtlasRectEntry_t { int Size; int Capacity; ImFontAtlasRectEntry* Data; }; // Instantiation of ImVector<ImFontAtlasRectEntry>
|
||||||
|
|
@ -4039,6 +4091,7 @@ CIMGUI_API void cImFontAtlasBuildInit(ImFontAtlas* atlas);
|
||||||
CIMGUI_API void cImFontAtlasBuildDestroy(ImFontAtlas* atlas);
|
CIMGUI_API void cImFontAtlasBuildDestroy(ImFontAtlas* atlas);
|
||||||
CIMGUI_API void cImFontAtlasBuildMain(ImFontAtlas* atlas);
|
CIMGUI_API void cImFontAtlasBuildMain(ImFontAtlas* atlas);
|
||||||
CIMGUI_API void cImFontAtlasBuildSetupFontLoader(ImFontAtlas* atlas, const ImFontLoader* font_loader);
|
CIMGUI_API void cImFontAtlasBuildSetupFontLoader(ImFontAtlas* atlas, const ImFontLoader* font_loader);
|
||||||
|
CIMGUI_API void cImFontAtlasBuildNotifySetFont(ImFontAtlas* atlas, ImFont* old_font, ImFont* new_font);
|
||||||
CIMGUI_API void cImFontAtlasBuildUpdatePointers(ImFontAtlas* atlas);
|
CIMGUI_API void cImFontAtlasBuildUpdatePointers(ImFontAtlas* atlas);
|
||||||
CIMGUI_API void cImFontAtlasBuildRenderBitmapFromString(ImFontAtlas* atlas, int x, int y, int w, int h, const char* in_str, char in_marker_char);
|
CIMGUI_API void cImFontAtlasBuildRenderBitmapFromString(ImFontAtlas* atlas, int x, int y, int w, int h, const char* in_str, char in_marker_char);
|
||||||
CIMGUI_API void cImFontAtlasBuildClear(ImFontAtlas* atlas); // Clear output and custom rects
|
CIMGUI_API void cImFontAtlasBuildClear(ImFontAtlas* atlas); // Clear output and custom rects
|
||||||
|
|
@ -4121,7 +4174,7 @@ CIMGUI_API const char* cImGuiTestEngine_FindItemDebugLabel(ImGuiContext* ctx, Im
|
||||||
#define IMGUI_TEST_ENGINE_ITEM_INFO(_ID,_LABEL,_FLAGS) if (g.TestEngineHookItems) ImGuiTestEngineHook_ItemInfo(&g, _ID, _LABEL, _FLAGS) // Register item label and status flags (optional)
|
#define IMGUI_TEST_ENGINE_ITEM_INFO(_ID,_LABEL,_FLAGS) if (g.TestEngineHookItems) ImGuiTestEngineHook_ItemInfo(&g, _ID, _LABEL, _FLAGS) // Register item label and status flags (optional)
|
||||||
#define IMGUI_TEST_ENGINE_LOG(_FMT,...) ImGuiTestEngineHook_Log(&g, _FMT, __VA_ARGS__) // Custom log entry from user land into test log
|
#define IMGUI_TEST_ENGINE_LOG(_FMT,...) ImGuiTestEngineHook_Log(&g, _FMT, __VA_ARGS__) // Custom log entry from user land into test log
|
||||||
#else
|
#else
|
||||||
#define IMGUI_TEST_ENGINE_ITEM_ADD(_BB,_ID) ((void)0)
|
#define IMGUI_TEST_ENGINE_ITEM_ADD(_ID,_BB,_ITEM_DATA) ((void)0)
|
||||||
#define IMGUI_TEST_ENGINE_ITEM_INFO(_ID,_LABEL,_FLAGS) ((void)g)
|
#define IMGUI_TEST_ENGINE_ITEM_INFO(_ID,_LABEL,_FLAGS) ((void)g)
|
||||||
#endif // #ifdef IMGUI_ENABLE_TEST_ENGINE
|
#endif // #ifdef IMGUI_ENABLE_TEST_ENGINE
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -688,7 +688,7 @@ fn writeStructs(
|
||||||
try writeType(writer, field.type, declarations, .{});
|
try writeType(writer, field.type, declarations, .{});
|
||||||
if (field.default_value) |v| {
|
if (field.default_value) |v| {
|
||||||
try writer.writeAll(" = ");
|
try writer.writeAll(" = ");
|
||||||
try writeValue(writer, v);
|
try writeValue(writer, field.type, declarations, v);
|
||||||
}
|
}
|
||||||
try writer.writeAll(",\n");
|
try writer.writeAll(",\n");
|
||||||
}
|
}
|
||||||
|
|
@ -706,7 +706,20 @@ fn writeStructs(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn writeValue(writer: anytype, value: []const u8) !void {
|
pub fn writeValue(
|
||||||
|
writer: anytype,
|
||||||
|
ty: Header.Type,
|
||||||
|
declarations: *const Declarations,
|
||||||
|
value: []const u8,
|
||||||
|
) !void {
|
||||||
|
// Replace {} with std.mem.zeroes(T)
|
||||||
|
if (std.mem.eql(u8, "{}", value)) {
|
||||||
|
try writer.writeAll("@import(\"std\").mem.zeroes(");
|
||||||
|
try writeType(writer, ty, declarations, .{});
|
||||||
|
try writer.writeAll(")");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
// Strip the `f` postfix off of floats
|
// Strip the `f` postfix off of floats
|
||||||
float: {
|
float: {
|
||||||
if (value.len > 0 and
|
if (value.len > 0 and
|
||||||
|
|
@ -942,9 +955,12 @@ fn writePointerType(
|
||||||
// value or nullable. We fall back to a c pointer so that the user can decide how to
|
// value or nullable. We fall back to a c pointer so that the user can decide how to
|
||||||
// interpret it with less friction, unless it's an opaque type in which case that's not
|
// interpret it with less friction, unless it's an opaque type in which case that's not
|
||||||
// allowed so we assume it's a nullable single value pointer.
|
// allowed so we assume it's a nullable single value pointer.
|
||||||
if (is_opaque or is_void) {
|
// XXX: ...
|
||||||
|
const is_context = ty.declaration != null and std.mem.eql(u8, "ImGuiContext*", ty.declaration.?); // https://codeberg.org/Games-by-Mason/dear_imgui_zig/issues/5
|
||||||
|
if (is_opaque or is_void or is_context) {
|
||||||
try writer.writeAll("?*");
|
try writer.writeAll("?*");
|
||||||
} else {
|
} else {
|
||||||
|
std.log.err("{}", .{ty});
|
||||||
try writer.writeAll("[*c]");
|
try writer.writeAll("[*c]");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
const DrawData = @import("dear_imgui").DrawData;
|
const DrawData = @import("dear_imgui").DrawData;
|
||||||
const TextureData = @import("dear_imgui").TextureData;
|
const TextureData = @import("dear_imgui").TextureData;
|
||||||
|
const Viewport = @import("dear_imgui").Viewport;
|
||||||
|
|
||||||
const Options = struct {
|
const Options = struct {
|
||||||
PFNvkVoidFunction: type,
|
PFNvkVoidFunction: type,
|
||||||
|
|
@ -13,15 +14,17 @@ const Options = struct {
|
||||||
VkDevice: type,
|
VkDevice: type,
|
||||||
VkDeviceSize: type,
|
VkDeviceSize: type,
|
||||||
VkFence: type,
|
VkFence: type,
|
||||||
|
VkFormat: type,
|
||||||
VkFramebuffer: type,
|
VkFramebuffer: type,
|
||||||
VkImage: type,
|
VkImage: type,
|
||||||
VkImageLayout: type,
|
VkImageLayout: type,
|
||||||
|
VkImageUsageFlags: type,
|
||||||
VkImageView: type,
|
VkImageView: type,
|
||||||
VkInstance: type,
|
VkInstance: type,
|
||||||
VkPhysicalDevice: type,
|
VkPhysicalDevice: type,
|
||||||
VkPipeline: type,
|
VkPipeline: type,
|
||||||
VkPipelineLayout: type,
|
|
||||||
VkPipelineCache: type,
|
VkPipelineCache: type,
|
||||||
|
VkPipelineLayout: type,
|
||||||
VkPipelineRenderingCreateInfoKHR: type,
|
VkPipelineRenderingCreateInfoKHR: type,
|
||||||
VkPresentModeKHR: type,
|
VkPresentModeKHR: type,
|
||||||
VkQueue: type,
|
VkQueue: type,
|
||||||
|
|
@ -30,10 +33,10 @@ const Options = struct {
|
||||||
VkSampleCountFlagBits: type,
|
VkSampleCountFlagBits: type,
|
||||||
VkSampler: type,
|
VkSampler: type,
|
||||||
VkSemaphore: type,
|
VkSemaphore: type,
|
||||||
|
VkShaderModuleCreateInfo: type,
|
||||||
VkSurfaceFormatKHR: type,
|
VkSurfaceFormatKHR: type,
|
||||||
VkSurfaceKHR: type,
|
VkSurfaceKHR: type,
|
||||||
VkSwapchainKHR: type,
|
VkSwapchainKHR: type,
|
||||||
VkFormat: type,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
pub fn get(options: Options) type {
|
pub fn get(options: Options) type {
|
||||||
|
|
@ -52,6 +55,7 @@ pub fn get(options: Options) type {
|
||||||
const VkFramebuffer = options.VkFramebuffer;
|
const VkFramebuffer = options.VkFramebuffer;
|
||||||
const VkImage = options.VkImage;
|
const VkImage = options.VkImage;
|
||||||
const VkImageLayout = options.VkImageLayout;
|
const VkImageLayout = options.VkImageLayout;
|
||||||
|
const VkImageUsageFlags = options.VkImageUsageFlags;
|
||||||
const VkImageView = options.VkImageView;
|
const VkImageView = options.VkImageView;
|
||||||
const VkInstance = options.VkInstance;
|
const VkInstance = options.VkInstance;
|
||||||
const VkPhysicalDevice = options.VkPhysicalDevice;
|
const VkPhysicalDevice = options.VkPhysicalDevice;
|
||||||
|
|
@ -66,6 +70,7 @@ pub fn get(options: Options) type {
|
||||||
const VkSampleCountFlagBits = options.VkSampleCountFlagBits;
|
const VkSampleCountFlagBits = options.VkSampleCountFlagBits;
|
||||||
const VkSampler = options.VkSampler;
|
const VkSampler = options.VkSampler;
|
||||||
const VkSemaphore = options.VkSemaphore;
|
const VkSemaphore = options.VkSemaphore;
|
||||||
|
const VkShaderModuleCreateInfo = options.VkShaderModuleCreateInfo;
|
||||||
const VkSurfaceFormatKHR = options.VkSurfaceFormatKHR;
|
const VkSurfaceFormatKHR = options.VkSurfaceFormatKHR;
|
||||||
const VkSurfaceKHR = options.VkSurfaceKHR;
|
const VkSurfaceKHR = options.VkSurfaceKHR;
|
||||||
const VkSwapchainKHR = options.VkSwapchainKHR;
|
const VkSwapchainKHR = options.VkSwapchainKHR;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue