Skip to content

Commit

Permalink
Merge branch 'master' into docking
Browse files Browse the repository at this point in the history
# Conflicts:
#	backends/imgui_impl_sdl2.cpp
#	backends/imgui_impl_sdl3.cpp
#	imgui.cpp
#	imgui_internal.h
  • Loading branch information
ocornut committed Feb 12, 2025
2 parents 8679cfa + a931fb7 commit 71d39a4
Show file tree
Hide file tree
Showing 11 changed files with 188 additions and 90 deletions.
1 change: 1 addition & 0 deletions backends/imgui_impl_opengl3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,7 @@ bool ImGui_ImplOpenGL3_Init(const char* glsl_version)
// GLES 2
bd->GlVersion = 200;
bd->GlProfileIsES2 = true;
IM_UNUSED(gl_version_str);
#else
// Desktop or GLES 3
GLint major = 0;
Expand Down
3 changes: 3 additions & 0 deletions backends/imgui_impl_sdl2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
// CHANGELOG
// (minor and older changes stripped away, please see git history for details)
// 2025-XX-XX: Platform: Added support for multiple windows via the ImGuiPlatformIO interface.
// 2025-02-10: Using SDL_OpenURL() in platform_io.Platform_OpenInShellFn handler.
// 2025-01-20: Made ImGui_ImplSDL2_SetGamepadMode(ImGui_ImplSDL2_GamepadMode_Manual) accept an empty array.
// 2024-10-24: Emscripten: from SDL 2.30.9, SDL_EVENT_MOUSE_WHEEL event doesn't require dividing by 100.0f.
// 2024-09-09: use SDL_Vulkan_GetDrawableSize() when available. (#7967, #3190)
Expand Down Expand Up @@ -534,6 +535,8 @@ static bool ImGui_ImplSDL2_Init(SDL_Window* window, SDL_Renderer* renderer, void
platform_io.Platform_SetImeDataFn = ImGui_ImplSDL2_PlatformSetImeData;
#ifdef __EMSCRIPTEN__
platform_io.Platform_OpenInShellFn = [](ImGuiContext*, const char* url) { ImGui_ImplSDL2_EmscriptenOpenURL(url); return true; };
#else
platform_io.Platform_OpenInShellFn = [](ImGuiContext*, const char* url) { return SDL_OpenURL(url) == 0; };
#endif

// Update monitor a first time during init
Expand Down
2 changes: 2 additions & 0 deletions backends/imgui_impl_sdl3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
// CHANGELOG
// (minor and older changes stripped away, please see git history for details)
// 2025-XX-XX: Platform: Added support for multiple windows via the ImGuiPlatformIO interface.
// 2025-02-10: Using SDL_OpenURL() in platform_io.Platform_OpenInShellFn handler.
// 2025-01-20: Made ImGui_ImplSDL3_SetGamepadMode(ImGui_ImplSDL3_GamepadMode_Manual) accept an empty array.
// 2024-10-24: Emscripten: SDL_EVENT_MOUSE_WHEEL event doesn't require dividing by 100.0f on Emscripten.
// 2024-09-11: (Docking) Added support for viewport->ParentViewportId field to support parenting at OS level. (#7973)
Expand Down Expand Up @@ -515,6 +516,7 @@ static bool ImGui_ImplSDL3_Init(SDL_Window* window, SDL_Renderer* renderer, void
platform_io.Platform_SetClipboardTextFn = ImGui_ImplSDL3_SetClipboardText;
platform_io.Platform_GetClipboardTextFn = ImGui_ImplSDL3_GetClipboardText;
platform_io.Platform_SetImeDataFn = ImGui_ImplSDL3_PlatformSetImeData;
platform_io.Platform_OpenInShellFn = [](ImGuiContext*, const char* url) { return SDL_OpenURL(url) == 0; };

// Update monitor a first time during init
ImGui_ImplSDL3_UpdateMonitors();
Expand Down
25 changes: 25 additions & 0 deletions docs/CHANGELOG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,23 +42,48 @@ HOW TO UPDATE?
Breaking changes:

- Renamed ImFontConfig::GlyphExtraSpacing.x option to GlyphExtraAdvanceX. (#242)
- Renamed style.TabMinWidthForCloseButton to style.TabCloseButtonMinWidthUnselected.

Other changes:

- Fixed IsItemDeactivatedAfterEdit() signal being broken for Checkbox(),
RadioButton(), Selectable(). Regression from 2025/01/13. (#8370)
- Windows: Fixed an issue where BeginChild() inside a collapsed Begin()
wouldn't inherit the SkipItems flag, resulting in missing coarse clipping
opportunity for code not checking the BeginChild() return value.
- Windows, Style: Added style.WindowBorderHoverPadding setting to configure
inner/outer padding applied to hit-testing of windows borders and detection
of hovered window.
- InputText: Allow CTRL+Shift+Z to redo even outside of OSX. (#8389) [@tanksdude]
- InputTextWithHint(): Fixed buffer-overflow (luckily often with no visible effect)
when a user callback modified the buffer contents in a way that altered the
visibility of the preview/hint buffer. (#8368) [@m9710797, @ocornut]
- Scrollbar: Rework logic that fades-out scrollbar when it becomes too small,
which amusingly made it disappear when using very big font/frame size.
- Tables: fixed calling SetNextWindowScroll() on clipped scrolling table
to not leak the value into a subsequent window. (#8196)
- Tables: fixed an issue where Columns Visible/Hidden state wouldn't be correctly
overridden when hot-reloading .ini state. (#7934)
- Tables: tamed some .ini settings optimizations to more accurately allow
overwriting/hot-reloading settings in more situations. (#7934)
- Styles, Tabs: made the Close Button of selected tabs always visible by default,
without requiring to hover the tab. (#8387)
- Added style.TabCloseButtonMinWidthSelected/TabCloseButtonMinWidthUnselected settings
to configure visibility of the Close Button for selected and unselected tabs.
(-1: always visible. 0.0f: visible when hovered. >0.0f: visible when hovered if minimum width)
- Default for selected tabs: TabCloseButtonMinWidthSelected = -1.0f (always visible)
- Default for unselected tabs: TabCloseButtonMinWidthUnselected = 0.0f (visible when hovered)
- TextLinkOpenURL(): fixed default Win32 io.PlatformOpenInShellFn handler to
handle UTF-8 regardless of system regional settings. (#7660) [@achabense]
- Demo: Combos: demonstrate a very simple way to add a filter to a combo,
by showing the filter inside the combo contents. (#718)
- Backends: SDL2, SDL3: Using SDL_OpenURL() in platform_io.Platform_OpenInShellFn
handler. (#7660) [@achabense]
- Backends: Metal: Fixed a crash on application resources. (#8367, #7419) [@anszom]
- Backends: WebGPU: Fix for DAWN API rename WGPUProgrammableStageDescriptor -> WGPUComputeState.
[@PhantomCloak] (#8369)


-----------------------------------------------------------------------
VERSION 1.91.8 (Released 2025-01-31)
-----------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion examples/example_win32_directx12/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ struct ExampleDescriptorHeapAllocator
HeapHandleIncrement = device->GetDescriptorHandleIncrementSize(HeapType);
FreeIndices.reserve((int)desc.NumDescriptors);
for (int n = desc.NumDescriptors; n > 0; n--)
FreeIndices.push_back(n);
FreeIndices.push_back(n - 1);
}
void Destroy()
{
Expand Down
Loading

0 comments on commit 71d39a4

Please sign in to comment.