mirror of
https://github.com/cimgui/cimgui.git
synced 2025-08-10 20:08:31 +01:00
implement all remaining changes for 1.40 release
This commit is contained in:
@@ -129,9 +129,9 @@ CIMGUI_API float ig_GetWindowWidth()
|
||||
return ImGui::GetWindowWidth();
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_GetWindowCollapsed()
|
||||
CIMGUI_API bool ig_IsWindowCollapsed()
|
||||
{
|
||||
return ImGui::GetWindowCollapsed();
|
||||
return ImGui::IsWindowCollapsed();
|
||||
}
|
||||
|
||||
CIMGUI_API void ig_SetNextWindowPos(CONST ImVec2 pos, ImGuiSetCond cond)
|
||||
@@ -296,6 +296,16 @@ CIMGUI_API void ig_PopTextWrapPos()
|
||||
return ImGui::PopTextWrapPos();
|
||||
}
|
||||
|
||||
CIMGUI_API void ig_PushButtonRepeat(bool repeat)
|
||||
{
|
||||
return ImGui::PushButtonRepeat(repeat);
|
||||
}
|
||||
|
||||
CIMGUI_API void ig_PopButtonRepeat()
|
||||
{
|
||||
return ImGui::PopButtonRepeat();
|
||||
}
|
||||
|
||||
// Tooltip
|
||||
CIMGUI_API void ig_SetTooltip(CONST char* fmt, ...)
|
||||
{
|
||||
@@ -331,6 +341,21 @@ CIMGUI_API bool ig_BeginPopup(const char* str_id)
|
||||
return ImGui::BeginPopup(str_id);
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_BeginPopupContextItem(CONST char* str_id, int mouse_button)
|
||||
{
|
||||
return ImGui::BeginPopupContextItem(str_id, mouse_button);
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_BeginPopupContextWindow(bool also_over_items, CONST char* str_id, int mouse_button)
|
||||
{
|
||||
return ImGui::BeginPopupContextWindow(also_over_items, str_id, mouse_button);
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_BeginPopupContextVoid(CONST char* str_id, int mouse_button)
|
||||
{
|
||||
return ImGui::BeginPopupContextVoid(str_id, mouse_button);
|
||||
}
|
||||
|
||||
CIMGUI_API void ig_EndPopup()
|
||||
{
|
||||
return ImGui::EndPopup();
|
||||
@@ -472,6 +497,11 @@ CIMGUI_API float ig_GetTextLineHeightWithSpacing()
|
||||
return ImGui::GetTextLineHeightWithSpacing();
|
||||
}
|
||||
|
||||
CIMGUI_API float ig_GetItemsLineHeightWithSpacing()
|
||||
{
|
||||
return ImGui::GetItemsLineHeightWithSpacing();
|
||||
}
|
||||
|
||||
// ID scopes
|
||||
// If you are creating widgets in a loop you most likely want to push a unique identifier so ImGui can differentiate them
|
||||
// You can also use "##extra" within your widget name to distinguish them from each others (see 'Programmer Guide')
|
||||
@@ -543,6 +573,19 @@ CIMGUI_API void ig_TextColoredV(CONST ImVec4 col, CONST char* fmt, va_list ar
|
||||
ImGui::TextColoredV(col,fmt,args);
|
||||
}
|
||||
|
||||
CIMGUI_API void ig_TextDisabled(CONST char* fmt, ...)
|
||||
{
|
||||
va_list args;
|
||||
va_start(args, fmt);
|
||||
ImGui::TextDisabledV(fmt, args);
|
||||
va_end(args);
|
||||
}
|
||||
|
||||
CIMGUI_API void ig_TextDisabledV(CONST char* fmt, va_list args)
|
||||
{
|
||||
return ImGui::TextDisabledV(fmt,args);
|
||||
}
|
||||
|
||||
CIMGUI_API void ig_TextWrapped(CONST char* fmt, ...)
|
||||
{
|
||||
va_list args;
|
||||
@@ -592,9 +635,9 @@ CIMGUI_API void ig_BulletTextV(CONST char* fmt, va_list args)
|
||||
ImGui::BulletTextV(fmt, args);
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_Button(CONST char* label, CONST ImVec2 size, bool repeat_when_held)
|
||||
CIMGUI_API bool ig_Button(CONST char* label, CONST ImVec2 size)
|
||||
{
|
||||
return ImGui::Button(label, size, repeat_when_held);
|
||||
return ImGui::Button(label, size);
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_SmallButton(CONST char* label)
|
||||
@@ -1057,16 +1100,21 @@ CIMGUI_API bool ig_IsItemActive()
|
||||
return ImGui::IsItemActive();
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_IsAnyItemActive()
|
||||
{
|
||||
return ImGui::IsAnyItemActive();
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_IsItemVisible()
|
||||
{
|
||||
return ImGui::IsItemVisible();
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_IsAnyItemHovered()
|
||||
{
|
||||
return ImGui::IsAnyItemHovered();
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_IsAnyItemActive()
|
||||
{
|
||||
return ImGui::IsAnyItemActive();
|
||||
}
|
||||
|
||||
CIMGUI_API void ig_GetItemRectMin(ImVec2* pOut)
|
||||
{
|
||||
*pOut = ImGui::GetItemRectMin();
|
||||
@@ -1097,9 +1145,9 @@ CIMGUI_API bool ig_IsRootWindowOrAnyChildFocused()
|
||||
return ImGui::IsRootWindowOrAnyChildFocused();
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_IsRectClipped(CONST ImVec2 item_size)
|
||||
CIMGUI_API bool ig_IsRectVisible(CONST ImVec2 item_size)
|
||||
{
|
||||
return ImGui::IsRectClipped(item_size);
|
||||
return ImGui::IsRectVisible(item_size);
|
||||
}
|
||||
|
||||
CIMGUI_API bool ig_IsKeyDown(int key_index)
|
||||
|
@@ -50,7 +50,7 @@ CIMGUI_API void ig_SetWindowFontScale(float scale);
|
||||
CIMGUI_API void ig_GetWindowPos(struct ImVec2* out);
|
||||
CIMGUI_API void ig_GetWindowSize(struct ImVec2* out);
|
||||
CIMGUI_API float ig_GetWindowWidth();
|
||||
CIMGUI_API bool ig_GetWindowCollapsed();
|
||||
CIMGUI_API bool ig_IsWindowCollapsed();
|
||||
|
||||
CIMGUI_API void ig_SetNextWindowPos(CONST struct ImVec2 pos, ImGuiSetCond cond);
|
||||
CIMGUI_API void ig_SetNextWindowSize(CONST struct ImVec2 size, ImGuiSetCond cond);
|
||||
@@ -89,6 +89,9 @@ CIMGUI_API void ig_PushAllowKeyboardFocus(bool v);
|
||||
CIMGUI_API void ig_PopAllowKeyboardFocus();
|
||||
CIMGUI_API void ig_PushTextWrapPos(float wrap_pos_x);
|
||||
CIMGUI_API void ig_PopTextWrapPos();
|
||||
CIMGUI_API void ig_PushButtonRepeat(bool repeat);
|
||||
CIMGUI_API void ig_PopButtonRepeat();
|
||||
|
||||
|
||||
// Tooltip
|
||||
CIMGUI_API void ig_SetTooltip(CONST char* fmt, ...);
|
||||
@@ -99,6 +102,9 @@ CIMGUI_API void ig_EndTooltip();
|
||||
// Popup
|
||||
CIMGUI_API void ig_OpenPopup(CONST char* str_id);
|
||||
CIMGUI_API bool ig_BeginPopup(CONST char* str_id);
|
||||
CIMGUI_API bool ig_BeginPopupContextItem(CONST char* str_id, int mouse_button = 1);
|
||||
CIMGUI_API bool ig_BeginPopupContextWindow(bool also_over_items = true, CONST char* str_id = NULL, int mouse_button = 1);
|
||||
CIMGUI_API bool ig_BeginPopupContextVoid(CONST char* str_id = NULL, int mouse_button = 1);
|
||||
CIMGUI_API void ig_EndPopup();
|
||||
CIMGUI_API void ig_CloseCurrentPopup();
|
||||
|
||||
@@ -129,6 +135,7 @@ CIMGUI_API void ig_SetCursorScreenPos(CONST struct ImVec2 pos);
|
||||
CIMGUI_API void ig_AlignFirstTextHeightToWidgets();
|
||||
CIMGUI_API float ig_GetTextLineHeight();
|
||||
CIMGUI_API float ig_GetTextLineHeightWithSpacing();
|
||||
CIMGUI_API float ig_GetItemsLineHeightWithSpacing();
|
||||
|
||||
// ID scopes
|
||||
// If you are creating widgets in a loop you most likely want to push a unique identifier so ImGui can differentiate them
|
||||
@@ -147,6 +154,8 @@ CIMGUI_API void ig_Text(CONST char* fmt, ...);
|
||||
CIMGUI_API void ig_TextV(CONST char* fmt, va_list args);
|
||||
CIMGUI_API void ig_TextColored(CONST struct ImVec4 col, CONST char* fmt, ...);
|
||||
CIMGUI_API void ig_TextColoredV(CONST struct ImVec4 col, CONST char* fmt, va_list args);
|
||||
CIMGUI_API void ig_TextDisabled(CONST char* fmt, ...);
|
||||
CIMGUI_API void ig_TextDisabledV(CONST char* fmt, va_list args);
|
||||
CIMGUI_API void ig_TextWrapped(CONST char* fmt, ...);
|
||||
CIMGUI_API void ig_TextWrappedV(CONST char* fmt, va_list args);
|
||||
CIMGUI_API void ig_TextUnformatted(CONST char* text, CONST char* text_end);
|
||||
@@ -155,7 +164,7 @@ CIMGUI_API void ig_LabelTextV(CONST char* label, CONST char* fmt, va
|
||||
CIMGUI_API void ig_Bullet();
|
||||
CIMGUI_API void ig_BulletText(CONST char* fmt, ...);
|
||||
CIMGUI_API void ig_BulletTextV(CONST char* fmt, va_list args);
|
||||
CIMGUI_API bool ig_Button(CONST char* label, CONST struct ImVec2 size, bool repeat_when_held);
|
||||
CIMGUI_API bool ig_Button(CONST char* label, CONST struct ImVec2 size);
|
||||
CIMGUI_API bool ig_SmallButton(CONST char* label);
|
||||
CIMGUI_API bool ig_InvisibleButton(CONST char* str_id, CONST struct ImVec2 size);
|
||||
CIMGUI_API void ig_Image(ImTextureID user_texture_id, CONST struct ImVec2 size, CONST struct ImVec2 uv0, CONST struct ImVec2 uv1, CONST struct ImVec4 tint_col, CONST struct ImVec4 border_col);
|
||||
@@ -237,10 +246,10 @@ CIMGUI_API bool ig_BeginMainMenuBar();
|
||||
CIMGUI_API void ig_EndMainMenuBar();
|
||||
CIMGUI_API bool ig_BeginMenuBar();
|
||||
CIMGUI_API void ig_EndMenuBar();
|
||||
CIMGUI_API bool ig_BeginMenu(CONST char* label, bool enabled = true);
|
||||
CIMGUI_API bool ig_BeginMenu(CONST char* label, bool enabled);
|
||||
CIMGUI_API void ig_EndMenu();
|
||||
CIMGUI_API bool ig_MenuItem(CONST char* label, CONST char* shortcut = NULL, bool selected = false, bool enabled = true);
|
||||
CIMGUI_API bool ig_MenuItemPtr(CONST char* label, CONST char* shortcut, bool* p_selected, bool enabled = true);
|
||||
CIMGUI_API bool ig_MenuItem(CONST char* label, CONST char* shortcut, bool selected, bool enabled);
|
||||
CIMGUI_API bool ig_MenuItemPtr(CONST char* label, CONST char* shortcut, bool* p_selected, bool enabled);
|
||||
|
||||
|
||||
// Widgets: Value() Helpers. Output single value in "name: value" format (tip: freely declare your own within the ImGui namespace!)
|
||||
@@ -263,15 +272,16 @@ CIMGUI_API void ig_LogText(CONST char* fmt, ...);
|
||||
CIMGUI_API bool ig_IsItemHovered();
|
||||
CIMGUI_API bool ig_IsItemHoveredRect();
|
||||
CIMGUI_API bool ig_IsItemActive();
|
||||
CIMGUI_API bool ig_IsAnyItemActive();
|
||||
CIMGUI_API bool ig_IsItemVisible();
|
||||
CIMGUI_API bool ig_IsAnyItemHovered();
|
||||
CIMGUI_API bool ig_IsAnyItemActive();
|
||||
CIMGUI_API void ig_GetItemRectMin(struct ImVec2* pOut);
|
||||
CIMGUI_API void ig_GetItemRectMax(struct ImVec2* pOut);
|
||||
CIMGUI_API void ig_GetItemRectSize(struct ImVec2* pOut);
|
||||
CIMGUI_API bool ig_IsWindowFocused();
|
||||
CIMGUI_API bool ig_IsRootWindowFocused();
|
||||
CIMGUI_API bool ig_IsRootWindowOrAnyChildFocused();
|
||||
CIMGUI_API bool ig_IsRectClipped(CONST struct ImVec2 item_size);
|
||||
CIMGUI_API bool ig_IsRectVisible(CONST struct ImVec2 item_size);
|
||||
CIMGUI_API bool ig_IsKeyDown(int key_index);
|
||||
CIMGUI_API bool ig_IsKeyPressed(int key_index, bool repeat);
|
||||
CIMGUI_API bool ig_IsMouseDown(int button);
|
||||
|
2
imgui
2
imgui
Submodule imgui updated: 3a6e6645e6...931b8dcdaf
Reference in New Issue
Block a user