Releases: ocornut/imgui
v1.89.4
1.89.4: Release cadence continues!
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
Thank you! ❤️
Special thanks to @PathogenDavid and @GamingMinds-DanielC for their help with github answers.
Ongoing work on Dear ImGui is currently financially supported by:
- Blizzard
- Supercell
- G3DVu
- Asobo Studio
- Tuxedo Labs
- And individual contributions.
Huge thank you to all past and present supporters!
Also thanks to PVS Studio (great static analyzer) for providing us with a license for this project.
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
TL;DR
- Nav: Tab key goes through every items (when keyboard navigation is active).
- Nav: Enter key works to activate most items (when keyboard navigation is active).
- Added return value to BeginTooltip().
- Examples: Activated keyboard and gamepad navigation by default in all examples.
- Various other fixes related to: Nav, Tables, Drag and Drop, InputText.
- Various improvements to Win32, SDL2, SDL3, GLFW backends.
- Added a Debug Tools to facilitate testing user-code testing Begin/BeginChild return value.
Changes
This is a followup to v1.89, v1.89.1, v1.89.2 and v1.89.3. We are trying to make more frequent releases. Because: some people are relying on tagging and auto-generated bindings for other languages. And: it sets a beat and may encourage teams to update more frequently.
Breaking Changes:
- Renamed
PushAllowKeyboardFocus()
/PopAllowKeyboardFocus()
toPushTabStop()
/PopTabStop()
. Kept inline redirection functions (will obsolete). - Moved the optional "courtesy maths operators" implementation from imgui_internal.h in imgui.h. Even though we encourage using your own maths types and operators by setting up
IM_VEC2_CLASS_EXTRA
, it has been frequently requested by people to use our own. We had an opt-in define which was previously fulfilled by imgui_internal.h. It is now fulfilled by imgui.h. (#6164, #6137, #5966, #2832)- OK:
#define IMGUI_DEFINE_MATH_OPERATORS
/#include "imgui.h"
/#include "imgui_internal.h"
- Error:
#include "imgui.h"
/#define IMGUI_DEFINE_MATH_OPERATORS
/#include "imgui_internal.h"
- Added a dedicated compile-time check message to help diagnose this.
- OK:
- Tooltips: Added 'bool' return value to
BeginTooltip()
for API consistency. Please only submit contents and call EndTooltip() if BeginTooltip() returns true. In reality the function will currently always return true, but further changes down the line may change this, best to clarify API sooner. Updated demo code accordingly. - Commented out redirecting enums/functions names that were marked obsolete two years ago:
ImGuiSliderFlags_ClampOnInput
-> useImGuiSliderFlags_AlwaysClamp
ImGuiInputTextFlags_AlwaysInsertMode
-> useImGuiInputTextFlags_AlwaysOverwrite
ImDrawList::AddBezierCurve()
-> useImDrawList::AddBezierCubic()
ImDrawList::PathBezierCurveTo()
-> useImDrawList::PathBezierCubicCurveTo()
Other Changes:
- Nav: Tabbing now cycles through all items when
ImGuiConfigFlags_NavEnableKeyboard
is set. (#3092, #5759, #787)
While this was generally desired and requested by many, note that its addition means that some types of UI may become more fastidious to use TAB key with, if the navigation cursor cycles through too many items. You can mark items items as not tab-spottable:- Public API:
PushTabStop(false)
/PopTabStop()
. - Internal:
PushItemFlag(ImGuiItemFlags_NoTabStop, true);
. - Internal: Directly pass
ImGuiItemFlags_NoTabStop
toItemAdd()
for custom widgets.
- Public API:
- Nav: Tabbing/Shift-Tabbing can more reliably be used to step out of an item that is not tab-stoppable. (#3092, #5759, #787)
- Nav: Made Enter key submit the same type of Activation event as Space key, allowing to press buttons with Enter. (#5606)
(Enter emulates a "prefer text input" activation vs. Space emulates a "prefer tweak" activation which is to closer to gamepad controls). - Nav: Fixed an issue with Gamepad navigation when the movement lead to a scroll and frame time > repeat rate. Triggering a new move request on the same frame as a move result lead to an incorrect calculation and loss of navigation id. (#6171)
- Nav: Fixed SetItemDefaultFocus() from not scrolling when item is partially visible. (#2814, #2812) [@DomGries]
- Tables: Fixed an issue where user's Y cursor movement within a hidden column would have side-effects.
- IO: Lifted constraint to call
io.AddEventXXX
functions from current context. (#4921, #5856, #6199) - InputText: Fixed not being able to use CTRL+Tab while an InputText() using Tab for completion or text data is active (regression from 1.89).
- Drag and Drop: Fixed handling of overlapping targets when smaller one is submitted before and can accept the same data type. (#6183).
- Drag and Drop: Clear drag and drop state as soon as delivery is accepted in order to avoid interferences. (#5817, #6183) [@DimaKoltun]
- Debug Tools: Added
io.ConfigDebugBeginReturnValueOnce
/io.ConfigDebugBeginReturnValueLoop
options to simulate Begin/BeginChild returning false to facilitate debugging user behavior. - Demo: Updated to test return value of
BeginTooltip()
. - Backends: OpenGL3: Fixed restoration of a potentially deleted OpenGL program. If an active program was pending deletion, attempting to restore it would error. (#6220, #6224) [@Cyphall]
- Backends: Win32: Use
WM_NCMOUSEMOVE
/WM_NCMOUSELEAVE
to track mouse positions over non-client area (e.g. OS decorations) when app is not focused. (#6045, #6162) - Backends: SDL2, SDL3: Accept
SDL_GetPerformanceCounter()
not returning a monotonically increasing value. (#6189, #6114, #3644) [@adamkewley] - Backends: GLFW: Avoid using
glfwGetError()
andglfwGetGamepadState()
on Emscripten, which recently updated its GLFW emulation layer to GLFW 3.3 without supporting those. (#6240) - Examples: Android: Fixed example build for Gradle 8. (#6229, #6227) [@duddel]
- Examples: Updated all examples application to enable
ImGuiConfigFlags_NavEnableKeyboard
andImGuiConfigFlags_NavEnableGamepad
by default. (#787) - Internals: Misc tweaks to facilitate applying an explicit-context patch. (#5856) [@Dragnalith]
New exciting projects!
Since 1.89 we semi-sneakily soft launched two new entire projects!
Dear ImGui Automation/Test Engine & Test Suite
https://github.com/ocornut/imgui_test_engine
Dear Bindings: alternative binding generator for C and other languages by @ShironekoBen
https://github.com/dearimgui/dear_bindings
Also note the release of Dear ImGui Bundle by @pthom
https://github.com/pthom/imgui_bundle
Gallery
Below a selection of screenshots from Gallery threads...
Rat GUI
The most convenient simulation tool for magnet engineers
https://rat-gui.ch/index.html
RTSA (Real-Time Spectrum Analyzer) Suite
https://aaronia.com/software/rtsa-suite/
Structural Mechanics software ObjectiveFrame
https://github.com/jonaslindemann/objectiveframe
OpenSim Creator
https://github.com/ComputationalBiomechanicsLab/opensim-creator
Fun thing, Quake 3 re-release using a Dear ImGui underlying logic for in-game menus:
Astro Duel 2
https://store.steampowered.com/app/655350/Astro_Duel_2/)
rustym: "Dear ImGui has been just instrumental to creating Astro Duel 2. We’ve built debug menus, inspectors, editors and production tools all atop this incredible open source framework. What an industry gem!"
v1.89.3
1.89.3: Release cadence intensifies!
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
Thank you! ❤️
Special thanks to @PathogenDavid and @GamingMinds-DanielC for their help with github answers.
Ongoing work on Dear ImGui is currently financially supported by:
- Blizzard
- Supercell
- G3DVu
- Asobo Studio
- And individual contributions.
Huge thank you to all past and present supporters!
Also thanks to PVS Studio (great static analyzer) for providing us with a license for this project.
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
TL;DR
- Renamed SDL2 backend files (+ Added experimental SDL3 backend).
- Fixed wrapping text regression from previous versions.
- Added SeparatorText().
- Lifted limit on table columns count.
- Fixed to horizontal scrolling wheel in many backends.
- More Emscripten examples + fixes for Emscripten.
- Many other tweaks/fixes.
Changes
This is a followup to v1.89, v1.89.1 and v1.89.2. We are trying to make more frequent releases. Because: some people are relying on tagging and auto-generated bindings for other languages. And: it sets a beat and may encourage teams to update more frequently.
Breaking Changes:
- Backends+Examples: SDL2: renamed all unnumbered references to "sdl" to "sdl2". This is in prevision for the future release of SDL3 and its associated backend. (#6146)
imgui_impl_sdl.cpp
->imgui_impl_sdl2.cpp
imgui_impl_sdl.h
->imgui_impl_sdl2.h
example_sdl_xxxx/
->example_sdl2_xxxx/
(folders and projects)
Other Changes:
- SeparatorText(): Added
SeparatorText()
widget. (#1643) [@phed, @ocornut]- Added to style:
float SeparatorTextBorderSize
. - Added to style:
ImVec2 SeparatorTextAlign
,ImVec2 SeparatorTextPadding
.
- Added to style:
- Tables: Raised max Columns count from 64 to 512. The previous limit was due to using 64-bit integers but we moved to bits-array and tweaked the system enough to ensure no performance loss. (#6094, #5305, #4876, #3572)
- Tables: Solved an ID conflict issue with multiple-instances of a same table, due to how unique table instance id was generated. (#6140) [@ocornut, @rodrigorc]
- Inputs, Scrolling: Made horizontal scroll wheel and horizontal scroll direction consistent across backends/os. (#4019, #6096, #1463) [@PathogenDavid, @ocornut, @rokups]
- Clarified that 'wheel_y > 0.0f' scrolls Up, 'wheel_y > 0.0f' scrolls Down.
- Clarified that 'wheel_x > 0.0f' scrolls Left, 'wheel_x > 0.0f' scrolls Right.
- Backends: Fixed horizontal scroll direction for Win32 and SDL backends. (#4019)
- Shift+WheelY support on non-OSX machines was already correct. (#2424, #1463) (whereas on OSX machines Shift+WheelY turns into WheelX at the OS level).
- If you use a custom backend, you should verify horizontal wheel direction.
- Axises are flipped by OSX for mouse & touch-pad when 'Natural Scrolling' is on.
- Axises are flipped by Windows for touch-pad when 'Settings->Touchpad->Down motion scrolls up' is on.
- You can use
Demo->Tools->Debug Log->IO
to visualize values submitted to Dear ImGui.
- Known issues remaining with Emscripten:
- The magnitude of wheeling values on Emscripten was improved but isn't perfect. (#6096)
- When running the Emscripten app on a Mac with a mouse, SHIFT+WheelY doesn't turn into WheelX. This is because we don't know that we are running on Mac and apply our own Shift+swapping on top of OSX' own swapping, so wheel axises are swapped twice. Emscripten apps may need to find a way to detect this and set
io.ConfigMacOSXBehaviors
manually (if you know a way let us know!), or offer the "OSX-style behavior" option to their user.
- Window: Avoid rendering shapes for hidden resize grips.
- Text: Fixed layouting of wrapped-text block skipping successive empty lines, regression from the fix in 1.89.2. (#5720, #5919)
- Text: Fixed clipping of single-character "..." ellipsis (U+2026 or U+0085) when font is scaled. Scaling wasn't taken into account, leading to ellipsis character straying slightly out of its expected boundaries. (#2775)
- Text: Tweaked rendering of three-dots "..." ellipsis variant. (#2775, #4269)
- InputText: Added support for Ctrl+Delete to delete up to end-of-word. (Not adding Super+Delete to delete to up to end-of-line on OSX, as OSX doesn't have it) (#6067) [@ajweeks]
- InputText: On OSX, inhibit usage of Alt key to toggle menu when active (used for work skip).
- Menus: Fixed layout of
MenuItem()
/BeginMenu()
when label contains a '\n'. (#6116) [@imkcy9] - ColorEdit, ColorPicker: Fixed hue/saturation preservation logic from interfering with the displayed value (but not stored value) of others widgets instances. (#6155)
- PlotHistogram, PlotLines: Passing negative sizes honor alignment like other widgets.
- Combo: Allow
SetNextWindowSize()
to alter combo popup size. (#6130) - Fonts: Assert that in each
GlyphRanges[]
pairs first is <= second. - ImDrawList: Added missing early-out in
AddPolyline()
andAddConvexPolyFilled()
when color alpha is zero. - Misc: Most text functions treat
"%s"
as a shortcut to no-formatting. (#3466) - Misc: Tolerate zero delta-time under Emscripten as backends are imprecise in their values for
io.DeltaTime
, and browser features such asprivacy.resistFingerprinting=true
can exacerbate that. (#6114, #3644) - Backends: OSX: Fixed scroll/wheel scaling for devices emitting events with
hasPreciseScrollingDeltas==false
(e.g. non-Apple mices). - Backends: Win32: flipping
WM_MOUSEHWHEEL
horizontal value to match other backends and offer consistent horizontal scrolling direction. (#4019) - Backends: SDL2: flipping
SDL_MOUSEWHEEL
horizontal value to match other backends and offer consistent horizontal scrolling direction. (#4019) - Backends: SDL2: Removed
SDL_MOUSEWHEEL
value clamping. (#4019, #6096, #6081) - Backends: SDL2: Added support for SDL 2.0.18+
preciseX
/preciseY
mouse wheel data for smooth scrolling as reported by SDL. (#4019, #6096) - Backends: SDL2: Avoid calling
SDL_SetCursor()
when cursor has not changed, as the function is surprisingly costly on Mac with latest SDL (already fixed in SDL latest trunk). (#6113) - Backends: SDL2: Implement IME handler to call
SDL_SetTextInputRect()
/SDL_StartTextInput()
. It will only works with SDL 2.0.18+ if your code calls 'SDL_SetHint(SDL_HINT_IME_SHOW_UI, "1")' prior to callingSDL_CreateWindow()
. Updated all examples accordingly. (#6071, #1953) - Backends: SDL3: Added experimental
imgui_impl_sdl3.cpp
backend. SDL 3.0.0 has not yet been released, so it is possible that its specs/api will change before release. This backend is provided as a convenience for early adopters etc. We don't recommend
switching to SDL3 before it is released. (#6146) [@dovker, @ocornut] - Backends: GLFW: Registering custom low-level mouse wheel handler to get more accurate scrolling impulses on Emscripten. (#4019, #6096) [@ocornut, @wolfpld, @tolopolarity]
- Backends: GLFW: Added
ImGui_ImplGlfw_SetCallbacksChainForAllWindows()
to instruct backend to chain callbacks even for secondary viewports/windows. User callbacks may need to test the 'window' parameter. (#6142) - Backends: OpenGL3: Fixed GL loader compatibility with 2.x profiles. (#6154, #4445, #3530) [@grauw]
- Backends: WebGPU: Fixed building for latest WebGPU specs (remove implicit layout generation). (#6117, #4116, #3632) [@tonygrue, @bfierz]
- Examples: refactored SDL2+GL and GLFW+GL examples to compile with Emscripten. (#2492, #2494, #3699, #3705) [@ocornut, @nicolasnoble] The dedicated example_emscripten_opengl3/ has been removed.
- Examples: Added SDL3+GL experimental example. (#6146)
- Examples: Win32: Fixed examples using
RegisterClassW()
since 1.89 to also callDefWindowProcW()
instead ofDefWindowProc()
so that title text are correctly converted when application is compiled without/DUNICODE
. (#5725, #5961, #5975) [@markreidvfx] - Examples: SDL2+SDL_Renderer: Added call to
SDL_RenderSetScale()
to fix display on a Retina display (albeit lower-res as our other unmodified examples). (#6121, #6065, #5931).
Changes from 1.89.2 to 1.89.3 related to the docking branch (multi-viewport and docking features) include:
- Backends: GLFW: Handle unsupported glfwGetVideoMode() for Emscripten. (#6096)
New exciting projects!
Note the release of Dear ImGui Bundle by @pthom
https://github.com/pthom/imgui_bundle
_"Dear ImGui Bundle is a bundle for Dear ImGui, including various powerful libraries from its ecosystem. It enables to easily create ImGui applications in C++ and Python, under Windows...
v1.89.2
1.89.2: Happy New Year!
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
Thank you! ❤️
Special thanks to @rokups for their continued work on regression tests (now available as part of Dear ImGui Test Engine & Test Suite).
Special thanks to @PathogenDavid and @GamingMinds-DanielC for their help with github answers.
Ongoing work on Dear ImGui is currently financially supported by:
Huge thank you to all past and present supporters!
Also thanks to PVS Studio (great static analyzer) for providing us with a license for this project.
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
Changes
This is a followup to v1.89 and v1.89.1. We are trying to make more frequent releases. Because: some people are relying on tagging and auto-generated bindings for other languages. And: it sets a beat and may encourage teams to update more frequently.
All Changes:
- Tables, Nav, Scrolling: fixed scrolling functions and focus tracking with frozen rows and frozen columns. Windows now have a better understanding of outer/inner decoration sizes, which should later lead us toward more flexible uses of menu/status bars. (#5143, #3692)
- Tables, Nav: frozen columns are not part of menu layer and can be crossed over. (#5143, #3692)
- Tables, Columns: fixed cases where empty columns may lead to empty ImDrawCmd. (#4857, #5937)
- Tables: fixed matching width of synchronized tables (multiple tables with same id) when only some instances have a vertical scrollbar and not all. (#5920)
- Fixed cases where CTRL+Tab or Modal can occasionally lead to the creation of ImDrawCmd with zero triangles, which would makes the render loop of some backends assert (e.g. Metal with debugging, Allegro). (#4857, #5937)
- Inputs, IO: reworked
ImGuiMod_Shortcut
to redirect to Ctrl/Super at runtime instead of compile-time, being consistent with our support for io.ConfigMacOSXBehaviors and making it easier for bindings generators to process that value. (#5923, #456) - Inputs, Scrolling: better selection of scrolling window when hovering nested windows and when backend/OS is emitting dual-axis wheeling inputs (typically touch pads on macOS). We now select a primary axis based on recent events, and select a target window based on it. We expect this behavior to be further improved/tweaked. (#3795, #4559) [@ocornut, @folays]
- InputText: fixed cursor navigation when pressing Up Arrow on the last character of a multi-line buffer which doesn't end with a carriage return. (#6000)
- Text: fixed layouting of wrapped-text block when the last source line is above the clipping region. Regression added in 1.89. (#5720, #5919)
- Misc: added
GetItemID()
in public API. It is not often expected that you would use this, but it is useful for Shortcut() and upcoming owner-aware input functions which wants to be implemented with public API. - Fonts: imgui_freetype: fixed a packing issue which in some occurrences would prevent large amount of glyphs from being packed correctly. (#5788, #5829)
- Fonts: added a
void* UserData
field inImFontAtlas
, as a convenience for use by applications using multiple font atlases. - Demo: simplified "Inputs" section, moved contents to Metrics->Inputs.
- Debug Tools: Metrics: added "Inputs" section, moved from Demo for consistency.
- Misc: fixed parameters to
IMGUI_DEBUG_LOG()
not being dead-stripped when building withIMGUI_DISABLE_DEBUG_TOOLS
is used. (#5901) [@Teselka] - Misc: fixed compile-time detection of SSE features on MSVC 32-bits builds. (#5943) [@TheMostDiligent]
- Examples: DirectX10, DirectX11: try WARP software driver if hardware driver is not available. (#5924, #5562)
- Backends: GLFW: Fixed mods state on Linux when using Alt-GR text input (e.g. German keyboard layout), which could lead to broken text input. Revert a 2022/01/17 change were we resumed using mods provided by GLFW, turns out they are faulty in this specific situation. (#6034)
- Backends: Allegro5: restoring using al_draw_indexed_prim() when Allegro version is >= 5.2.5. (#5937) [@Espyo]
- Backends: Vulkan: Fixed sampler passed to
ImGui_ImplVulkan_AddTexture()
not being honored as we were using an immutable sampler. (#5502, #6001, #914) [@martin-ejdestig, @rytisss]
Changes from 1.89.1 to 1.89.2 related to the docking branch (multi-viewport and docking features) include:
- Docking: Internals: fixed
DockBuilderCopyDockSpace()
crashing when windows not in the remapping list are docked on the left or top side of a split. (#6035) - Docking: fixed
DockSpace()
withImGuiDockNodeFlags_KeepAliveOnly
marking current window as written to, even if it doesn't technically submit an item. This allow using KeepAliveOnly from any window location. (#6037) - Backends: OSX: fixed typo in
ImGui_ImplOSX_GetWindowSize
that would cause issues when resizing from OS decorations, if they are enabled on secondary viewports. (#6009) [@sivu] - Backends: Metal: fixed secondary viewport rendering. (#6015) [@dmirty-kuzmenko]
New exciting projects!
Since 1.89 we semi-sneakily soft launched two new entire projects!
Dear ImGui Automation/Test Engine & Test Suite
https://github.com/ocornut/imgui_test_engine
Dear Bindings: alternative binding generator for C and other languages by @ShironekoBen
https://github.com/dearimgui/dear_bindings
Gallery
Below a selection of screenshots from Gallery threads...
Projectreal by @thefoxcam
"WIP Open source layer-based compositor](https://foxcam.net/projectreal with a focus on bitmap editing for 2D motion design work, basically a combination of After Effects and Photoshop. ImGui's paradigm has been invaluable to my learning journey--"
NAP Framework by https://nap-labs.tech/
https://www.napframework.com
Dear ImGui File Dialogs CLI and Client Library by Samuel Venable.
https://github.com/time-killer-games/libfiledialogs
"Based on ImFileDialog by dfranx, with many bugs/crashes fixed and overall improvements. The 'Quick Access' sidebar actually remembers what favorites were previously saved to it from previous runs of your application now, by saving the settings to a text file in a hidden configuration subfolder of your home folder. Allows for full localization among many other good things you'll find useful. Most of the dialog is customizable via environment variables. Uses system icon theme."
RetroDebugger by @slajerek
https://github.com/slajerek/RetroDebugger
RE Edit, a free and open source WYSIWYG editor for the UI of a Rack Extension
https://github.com/pongasoft/re-edit
v1.89.1
1.89.1: Friendly tweaks and fixes
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
Wiki: https://github.com/ocornut/imgui/wiki for bindings, extensions, links, etc.
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
Thank you! ❤️
Special thanks to @rokups for their continued work on stuff that are still not visible e.g. regression tests.
Special thanks to @PathogenDavid for their continued contributions and helping with github answers.
Special thanks to @thedmd for their code reviews and continued exchanges of ideas.
Ongoing work on Dear ImGui is currently financially supported by:
Huge thank you to all past and present supporters!
Also thanks to PVS Studio (great static analyzer) for providing us with a license for this project.
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
Changes
This is mostly a couple of changes to amend the release of v1.89:
- Scrolling, Focus: fixed
SetKeyboardFocusHere()
/SetItemDefaultFocus()
during a window-appearing frame (and associated lower-level functions e.g.ScrollToRectEx()
) from not centering item. (#5902) - Inputs: fixed moving a window or drag and dropping from preventing input-owner-unaware code from accessing keys. (#5888, #4921, #456)
- Inputs: fixed moving a window or drag and dropping from capturing mods. (#5888, #4921, #456)
- Layout: fixed
End()
/EndChild()
incorrectly asserting if users manipulates cursor position inside a collapsed/culled window andIMGUI_DISABLE_OBSOLETE_FUNCTIONS
is enabled. (#5548, #5911) - Combo: fixed selected item (marked with
SetItemDefaultFocus()
) from not being centered when the combo window initially appears. (#5902). - ColorEdit: fixed label overlapping when using
style.ColorButtonPosition == ImGuiDir_Left
to move the color button on the left side (regression introduced in 1.88 WIP 2022/02/28). (#5912) - Drag and Drop: fixed
GetDragDropPayload()
returning a non-NULL value if a drag source is active but a payload hasn't been submitted yet. This is convenient to detect new payload from within a drag source handler. (#5910, #143) - Backends: GLFW: cancel out errors emitted by
glfwGetKeyName()
when a name is missing. (#5908) - Backends: WebGPU: fixed validation error with default depth buffer settings. (#5869, #5914) [@kdchambers]
Changes from 1.89 to 1.89,1 related to the docking branch (multi-viewport and docking features) include:
- Viewport: Fixed collapsed windows setting
ImGuiViewportFlags_NoRendererClear
without making title bar color opaque, leading to potential texture/fb garbage being visible. Right now as we don't fully support transparent viewports (#2766), so we turn thatTitleBgCollapsed
color opaque just like we do forWindowBG
on uncollapsed windows.
New secret exciting stuff!
Since 1.89 we semi-sneakily soft launched two new entire projects!
Dear Bindings: alternative binding generator for C and other languages
https://github.com/dearimgui/dear_bindings
Dear ImGui Automation/Test Engine & Test Suite
https://github.com/ocornut/imgui_test_engine
See v1.89 for full release details.
v1.89
1.89: Autumn release!
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
Wiki: https://github.com/ocornut/imgui/wiki for bindings, extensions, links, etc.
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
📢 Updating from <1.86 and got visual glitches with custom/old backend when using CTRL+Tab or Modal Windows? See 1.86 release note.
Thank you! ❤️
Special thanks to @rokups for their continued work on stuff that are still not visible e.g. regression tests.
Special thanks to @PathogenDavid for their continued contributions and helping with github answers.
Special thanks to @thedmd for their code reviews and continued exchanges of ideas.
Ongoing work on Dear ImGui is currently financially supported by:
Huge thank you to all past and present supporters!
Also thanks to PVS Studio (great static analyzer) for providing us with a license for this project.
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
TL;DR;
Some arbitrary highlights among the 90+ changes:
- Debug Tools: Hovering 0xXXXXXXX ids in Debug Log and Metrics can now visually locate the item. (#5855)
- Popups & Modals: fixed nested Begin() inside a popup being erroneously input-inhibited.
- IO: Mitigate scrolling issues on system sending dual-axis wheel data simultaneously (more fixes coming later).
- IsItemHovered: added
ImGuiHoveredFlags_DelayNormal
andImGuiHoveredFlags_DelayShort
for delayed hover test (work on items that have no persistent identifier e.g. Text items). - InputText: added
ImGuiInputTextFlags_EscapeClearsAll
andio.ConfigInputTextEnterKeepActive
. Added Shift+Click style selection. Improvements for numerical inputs for IME mode sending full-width characters. Other fixes. - Menus: various fixes for menu item inside non-popup root windows. Fixes for keyboard/gamepad navigations.
- TabBar: fixes occasional freezes when feeding non-rounded tab widths.
- Backends: Many fixes: freezing IME on Win32, fix for SDL 2.0.22 auto-capture and drag and drop issues with multi-viewports, fixes corruptions issues with OpenGL and multi-viewports on buggy Intel GPU drivers, OSX support for C++ apps etc.
- Obsoleted variety of old symbols, with backward-compatible redirection for newly obsoleted stuff.
- Internals: added wip internal APIs to allow handling input/shorting routing and key ownership. Things will be moved into public APIs over time, including a
Shortcut()
function that magically handle input routing. - And many more things...
Breaking Changes
(Suggestion: once in a while, add #define IMGUI_DISABLE_OBSOLETE_FUNCTIONS
in your imconfig.h
file to make sure you are not using to-be-obsoleted symbols.)
- Layout: Obsoleted using
SetCursorPos()
/SetCursorScreenPos()
to extend parent window/cell boundaries. (#5548)
This relates to when moving the cursor position beyond current boundaries WITHOUT submitting an item.- Previously this would make the window content size ~200x200:
Begin(...)
+SetCursorScreenPos(GetCursorScreenPos() + ImVec2(200,200))
+End()
- Instead, please submit an item:
Begin(...)
+SetCursorScreenPos(GetCursorScreenPos() + ImVec2(200,200))
+Dummy(ImVec2(0,0))
+End()
- Or simpler alternative:
Begin(...)
+Dummy(ImVec2(200,200))
+End()
; - Content size is now only extended when submitting an item.
- With
#define IMGUI_DISABLE_OBSOLETE_FUNCTIONS
this will now be detected and assert. - Without
#define IMGUI_DISABLE_OBSOLETE_FUNCTIONS
this will silently be fixed until we obsolete it. - This incorrect pattern has been mentioned or suggested in: #4510, #3355, #1760, #1490, #4152, #150, threads have been amended to refer to this issue.
- With
- Previously this would make the window content size ~200x200:
- Renamed and merged keyboard modifiers key enums and flags into a same set: (#4921, #456)
ImGuiKey_ModCtrl
andImGuiModFlags_Ctrl
->ImGuiMod_Ctrl
ImGuiKey_ModShift
andImGuiModFlags_Shift
->ImGuiMod_Shift
ImGuiKey_ModAlt
andImGuiModFlags_Alt
->ImGuiMod_Alt
ImGuiKey_ModSuper
andImGuiModFlags_Super
->ImGuiMod_Super
Kept inline redirection enums (will obsolete). This change simplifies a few things, reduces confusion, and will facilitate upcoming shortcut/input ownership apis.- (The
ImGuiKey_ModXXX
were introduced in 1.87 and mostly used by backends. TheImGuiModFlags_XXX
have been exposed in imgui.h but not really used by any public api, only by third-party extensions. They were however subject to a recent renameImGuiKeyModFlags_XXX
->ImGuiModFlags_XXX
and we are exceptionally commenting out the olderImGuiKeyModFlags_XXX
names ahead of obsolescence schedule to reduce confusion and because they were not meant to be used anyway.)
- Removed
io.NavInputs[]
andImGuiNavInput
enum that were used to feed gamepad inputs. Basically 1.87 already obsoleted them from the backend's point of view, but internally our navigation code still used this array and enum, so they were still present. Not anymore! (#4921, #4858, #787, #1599, #323)
Transition guide:- Official backends from 1.87:
- no issue.
- Official backends from 1.60 to 1.86:
- will compile and convert legacy gamepad inputs, unless
IMGUI_DISABLE_OBSOLETE_KEYIO
is defined. Need updating!
- will compile and convert legacy gamepad inputs, unless
- Custom backends not writing to
io.NavInputs[]
(no gamepad support)- no issue.
- Custom backends writing to
io.NavInputs[]
:- will compile and convert legacy gamepad inputs, unless
IMGUI_DISABLE_OBSOLETE_KEYIO
is defined. Need fixing!
- will compile and convert legacy gamepad inputs, unless
- TL;DR: Backends should call
io.AddKeyEvent()
/io.AddKeyAnalogEvent()
withImGuiKey_GamepadXXX
values instead of fillingio.NavInput[]
. The ImGuiNavInput enum was essentially 1.60's attempt to combine keyboard and gamepad inputs with named semantic, but the additional indirection and copy added complexity and got in the way of other incoming work. User's code (other than backends) should not be affected, unless you have custom widgets intercepting navigation events via the named enums (in which case you can upgrade your code).
- Official backends from 1.87:
DragInt()
,SliderInt()
: Removed runtime patching of invalid "%f"/"%.0f" types of format strings. This was obsoleted in 1.61 (May 2018). See 1.61 changelog for details.- Changed signature of
ImageButton()
function: (#5533, #4471, #2464, #1390)- Added
const char* str_id
parameter + removedint frame_padding = -1
parameter. - Old signature:
bool ImageButton(ImTextureID tex_id, ImVec2 size, ImVec2 uv0 = ImVec2(0,0), ImVec2 uv1 = ImVec2(1,1), int frame_padding = -1, ImVec4 bg_col = ImVec4(0,0,0,0), ImVec4 tint_col = ImVec4(1,1,1,1));
- used the
ImTextureID
value to create an ID. This was inconsistent with other functions, led to ID conflicts, and caused problems with engines using transient ImTextureID values. - had a
FramePadding
override which was inconsistent with other functions and made the already-long signature even longer.
- used the
- New signature:
bool ImageButton(const char* str_id, ImTextureID tex_id, ImVec2 size, ImVec2 uv0 = ImVec2(0,0), ImVec2 uv1 = ImVec2(1,1), ImVec4 bg_col = ImVec4(0,0,0,0), ImVec4 tint_col = ImVec4(1,1,1,1));
- requires an explicit identifier. You may still use e.g.
PushID()
calls and then pass an empty identifier. - always uses
style.FramePadding
for padding, to be consistent with other buttons. You may usePushStyleVar()
to alter this.
- requires an explicit identifier. You may still use e.g.
- As always we are keeping a redirection function available (will obsolete later).
- Added
- Removed the bizarre legacy default argument for
TreePush(const void* ptr = NULL)
. Must always pass a pointer value explicitly, NULL/nullptr is ok but require cast, e.g.TreePush((void*)nullptr);
If you usedTreePush()
replace withTreePush((void*)NULL);
(#1057) - Commented out redirecting functions/enums names that were marked obsolete in 1.77 and 1.79 (August 2020): (#3361)
DragScalar()
,DragScalarN()
,DragFloat()
,DragFloat2()
,DragFloat3()
,DragFloat4()
SliderScalar()
,SliderScalarN()
,SliderFloat()
,SliderFloat2()
,SliderFloat3()
,SliderFloat4()
- For old signatures ending with
(..., const char* format, float power = 1.0f)
->use (..., format ImGuiSliderFlags_Logarithmic)
ifpower != 1.0f
.
- For old signatures ending with
BeginPopupContextWindow(const char*, ImGuiMouseButton, bool)
-> useBeginPopupContextWindow(const char*, ImGuiPopupFlags)
OpenPopupContextItem()
(briefly existed from 1.77 to 1.79) -> useOpenPopupOnItemClick()
- Removed support for 1.42-era
IMGUI_DISABLE_INCLUDE_IMCONFIG_H
/IMGUI_INCLUDE_IMCONFIG_H
. They only made sense before we could useIMGUI_USER_CONFIG
. (#255)
Other Changes
- Popups & Modals: fixed nested Begin() inside a popup being erroneously input-inhibited. While it is unusual, you can nest a Begin() inside a popup or mo...
v1.88
1.88: Summer maintainance release!
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
Wiki: https://github.com/ocornut/imgui/wiki for bindings, extensions, links, etc.
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
📢 Updating from <1.86 and got visual glitches with custom/old backend when using CTRL+Tab or Modal Windows? See 1.86 release note.
Thank you!
Special thanks to @rokups for their continued work on stuff that are still not visible e.g. regression tests.
Special thanks to @PathogenDavid for their continued contributions and helping with github answers.
Ongoing work on Dear ImGui is currently financially supported by companies such as:
- Platinum sponsors: Blizzard
- Chocolate sponsors: Adobe, Google, Ubisoft, Supercell
- Salty-caramel sponsors: Kylotonn, Wonderland Engine
Huge thank you to all past and present supporters!
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
TL;DR;
This is a general "many things" release. Initially I was expecting 1.88 to include new features for input ownership and input routing but it's not ready and we haven't had a release for a while. Among the 80+ changes, some that may interest more people:
- Various fixes related to the 1.87 input io/queue changes.
- Debug: Added of a "Dear ImGui Debug Log" window facilitating looking into common issues (e.g. focus change, popup closure, active id being stolen, etc.).
- Debug: Added a "UTF-8 Encoding Viewer" in Metrics and
DebugTextEncoding()
function to help validating UTF-8 code since many users have issues with UTF-8 encoding and C++ makes things difficult. - Sliders: Clicking within the grab/knob of a non-Drag Slider width doesn't alter current value.
- InputText: Fixed undo-state corruptions when altering in-buffers in user callback and in other cases.
- Tables: Fixed a rather frequent draw-call merging issues (some tables created an unnecessary extra draw-call).
- Fixed subtle or rare nav and focus issues.
- Many backends fixes (including tentative fixes for frequent OpenGL issues on Windows in multi-viewport mode).
- Various Docking and Multi-viewport fixes.
Breaking Changes
(Suggestion: once in a while, add #define IMGUI_DISABLE_OBSOLETE_FUNCTIONS
in your imconfig.h
file to make sure you are not using to-be-obsoleted symbols.)
- Renamed
IMGUI_DISABLE_METRICS_WINDOW to
IMGUI_DISABLE_DEBUG_TOOLS` for correctness. Kept support for old define (will obsolete). - Renamed
CaptureMouseFromApp()
andCaptureKeyboardFromApp()
toSetNextFrameWantCaptureMouse()
andSetNextFrameWantCaptureKeyboard()
to clarify purpose, old name was too misleading. Kept inline redirection functions (will obsolete). - Renamed
ImGuiKeyModFlags
toImGuiModFlags
. Kept inline redirection enums (will obsolete). (This was never used in public API functions but technically present in imgui.h and ImGuiIO). - Backends: OSX: Removed
ImGui_ImplOSX_HandleEvent()
from backend API in favor of backend automatically handling event capture. Examples that are using the OSX backend have removed all the now-unnecessary calls to ImGui_ImplOSX_HandleEvent(), applications can do as well. [@stuartcarnie] (#4821) - Internals: calling
ButtonBehavior()
without callingItemAdd()
now requires aKeepAliveID()
call. This is because theKeepAliveID()
call was moved fromGetID()
toItemAdd()
. (#5181)
Other Changes
- IO: Fixed backward-compatibility regression introduced in 1.87: (#4921, #4858)
- Direct accesses to
io.KeysDown[]
with legacy indices didn't work (with new backends). - Direct accesses to
io.KeysDown[GetKeyIndex(XXX)]
would access invalid data (with old/new backends). - Calling
IsKeyDown()
didn't have those problems, and is recommended asio.KeysDown[]
is obsolete.
- Direct accesses to
- IO: Fixed input queue trickling of interleaved keys/chars events (which are frequent especially when holding down a key as OS submits chars repeat events) delaying key presses and mouse movements. In particular, using the input system for fast game-like actions (e.g. WASD camera move) would typically have been impacted, as well as holding a key while dragging mouse. Constraints have been lifted and are now only happening when e.g. an InputText() widget is active. (#4921, #4858)
- Note that even thought you shouldn't need to disable
io.ConfigInputTrickleEventQueue
, you can technically dynamically change its setting based on the context (e.g. disable only when hovering or interacting with a game/3D view).
- Note that even thought you shouldn't need to disable
- IO: Fixed input queue trickling of mouse wheel events: multiple wheel events are merged, while a mouse pos followed by a mouse wheel are now trickled. (#4921, #4821)
- IO: Added
io.SetAppAcceptingEvents()
to set a master flag for accepting key/mouse/characters events (default to true). Useful if you have native dialog boxes that are interrupting your application loop/refresh, and you want to disable events being queued while your app is frozen. - Windows: Fixed first-time windows appearing in negative coordinates from being initialized with a wrong size. This would most often be noticeable in multi-viewport mode (docking branch) when spawning a window in a monitor with negative coordinates. (#5215, #3414) [@DimaKoltun]
- Clipper: Fixed a regression in 1.86 when not calling clipper.End() and late destructing the clipper instance. High-level languages (Lua,Rust etc.) would typically be affected. (#4822)
- Layout: Fixed mixing up
SameLine()
andSetCursorPos()
together from creating situations where line height would be emitted from the wrong location (e.g. ItemA+SameLine()+SetCursorPos()+ItemB' would emit ItemA worth of height from the position of ItemB, which is not necessarily aligned with ItemA). - Sliders: An initial click within the knob/grab doesn't shift its position. (#1946, #5328)
- Sliders, Drags: Fixed dragging when using hexadecimal display format string. (#5165, #3133)
- Sliders, Drags: Fixed manual input when using hexadecimal display format string. (#5165, #3133)
- InputScalar: Fixed manual input when using %03d style width in display format string. (#5165, #3133)
- InputScalar: Automatically allow hexadecimal input when format is %X (without extra flag).
- InputScalar: Automatically allow scientific input when format is float/double (without extra flag).
- Nav: Fixed nav movement in a scope with only one disabled item from focusing the disabled item. (#5189)
- Nav: Fixed issues with nav request being transferred to another window when calling
SetKeyboardFocusHere()
and simultaneous changing window focus. (#4449) - Nav: Changed
SetKeyboardFocusHere()
to not behave if a drag or window moving is in progress. - Nav: Fixed inability to cancel nav in modal popups. (#5400) [@rokups]
- IsItemHovered(): added
ImGuiHoveredFlags_NoNavOverride
to disable the behavior where the return value is overridden by focus when gamepad/keyboard navigation is active. - InputText: Fixed pressing Tab emitting two tabs characters because of dual Keys/Chars events being trickled with the new input queue (happened on some backends only). (#2467, #1336)
- InputText: Fixed a one-frame display glitch where pressing Escape to revert after a deletion would lead to small garbage being displayed for one frame. Curiously a rather old bug! (#3008)
- InputText: Fixed an undo-state corruption issue when editing main buffer before reactivating item. (#4947)
- InputText: Fixed an undo-state corruption issue when editing in-flight buffer in user callback. (#4947, #4949] [@JoshuaWebb]
- Tables: Fixed incorrect border height used for logic when resizing one of several synchronized instance of a same table ID, when instances have a different height. (#3955).
- Tables: Fixed incorrect auto-fit of parent windows when using non-resizable weighted columns. (#5276)
- Tables: Fixed draw-call merging of last column. Depending on some unrelated settings (e.g. BorderH) merging drawcall of the last column didn't always work (regression since 1.87). (#4843, #4844) [@rokups]
- Inputs: Fixed
IsMouseClicked()
repeat mode rate being half of keyboard repeat rate. - ColorEdit: Fixed text baseline alignment after a
SameLine()
after aColorEdit()
with visible label. - TabBar:
BeginTabItem()
now reacts toSetNextItemWidth()
. (#5262) - TabBar: Tweak shrinking policy so that while resizing tabs that don't need shrinking keep their initial width more precisely (without the occasional +1 worth of width).
- Menus: Adjusted
BeginMenu()
closing logic so hovering void or non-MenuItem() in parent window always lead to menu closure. Fixes using items that are notMenuItem()
orBeginItem()
at the root level of a popup with a child menu opened. - Menus: Menus emitted from th...
v1.87
1.87: The event-based IO release!
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
Wiki: https://github.com/ocornut/imgui/wiki for bindings, extensions, links, etc.
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
📢 Got visual glitches with custom/old backend when using CTRL+Tab or Modal Windows? See 1.86 release note.
📢 EDIT 2022/02/21: A regression in 1.87 prevents direct access to legacy io.KeysDown[] array in certains situations (see #4921, now fixed in latest). IsKeyDown() function was not affected.
Thank you!
Special thanks to @rokups for their continued work on stuff that are still not visible e.g. regression tests.
Special thanks to @thedmd for their contribution to this verison.
Special thanks to @PathogenDavid for their continued contributions and helping with github answers.
Ongoing work on Dear ImGui is currently financially supported by companies such as:
Huge thank you to all past and present supporters!
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
TL;DR;
This is a rather "boring" release in the sense that the refactor are not super exciting per se, but they are going to enable quite a few good things. Backends for all platforms have been updated. Most of the IO API hadn't changed this 1.0!
- Revamped the way for backend submit data to ImGuiIO. Now using functions e.g.
io.AddKeyEvent()
. The vast majority of changes are backward compatible but you are encouraged to update your backends now. See full recap > #4921. - Added full range of
ImGuiKey
values, making it possible to access keys in a backend-agnostic way and make it easier to share code (e.g. for third-party libraries using Dear ImGui). - Most platfom backends have been reworked to submit events.
- Backward compatible: 99% of old backends (custom or standard) and app code will still work (but consider updating!)
- Fixed SDL and GLFW backends to submit translated keys (not same as characters) to facilitate using shortcuts with ImGuiKey values.
- Trickling input queue improve usability on very low framerate (e.g. <15 FPS).
- Variety of other fixes (popups, ctrl+tab).
Breaking Changes
(Suggestion: once in a while, add #define IMGUI_DISABLE_OBSOLETE_FUNCTIONS
in your imconfig.h
file to make sure you are not using to-be-obsoleted symbols.)
- Removed support for pre-C++11 compilers. We'll stop supporting VS2010. (#4537)
- Reworked IO mouse input API: (#4921, #4858) [@thedmd, @ocornut]
- Added
io.AddMousePosEvent()
,io.AddMouseButtonEvent()
,io.AddMouseWheelEvent()
functions, obsoleting writing directly toio.MousePos
,io.MouseDown[]
,io.MouseWheel
, etc. - This enable input queue trickling to support low framerates. (#2787, #1992, #3383, #2525, #1320)
- For all new calls to IO functions, the Dear ImGui context should be bound/current.
- Added
- Reworked IO keyboard input API: (#4921, #2625, #3724) [@thedmd, @ocornut]
- Added
io.AddKeyEvent()
function, obsoleting writing directly to io.KeyMap[], io.KeysDown[] arrays. - For keyboard modifiers, you must call
io.AddKeyEvent()
withImGuiKey_ModXXX
values, obsoleting writing directly to io.KeyCtrl, io.KeyShift etc. - Added
io.SetKeyEventNativeData()
function (optional) to pass native and old legacy indices. - Added full range of key enums in ImGuiKey (e.g.
ImGuiKey_F1
). - Added
GetKeyName()
helper function. - Obsoleted
GetKeyIndex()
: it is now unnecessary and will now return the same value. - All keyboard related functions taking '
nt user_key_index
now takeImGuiKey key
:IsKeyDown()
,IsKeyPressed()
,IsKeyReleased()
,GetKeyPressedAmount()
. - Added
io.ConfigInputTrickleEventQueue
(defaulting to true) to disable input queue trickling. - Backward compatibility:
- All backends updated to use new functions.
- Old backends populating those arrays should still work!
- Calling e.g.
IsKeyPressed(MY_NATIVE_KEY_XXX)
will still work! (for a while) - Those legacy arrays will only be disabled if
#define IMGUI_DISABLE_OBSOLETE_KEYIO'
is set in your imconfig. In a few versions,IMGUI_DISABLE_OBSOLETE_FUNCTIONS
will automatically enableIMGUI_DISABLE_OBSOLETE_KEYIO
, so this will be moved into the regular obsolescence path. - BREAKING: (unlikely) If your custom backend used ImGuiKey as mock native indices (e.g.
io.KeyMap[ImGuiKey_A] = ImGuiKey_A`` this is a use case that will now assert and be breaking for your old backend. **- Transition guide:** **-
IsKeyPressed(MY_NATIVE_KEY_XXX)-> use
IsKeyPressed(ImGuiKey_XXX)` IsKeyPressed(GetKeyIndex(ImGuiKey_XXX))
-> use `IsKeyPressed(ImGuiKey_XXX)- Backend writing to io.KeyMap[],KeysDown[] -> backend should call
io.AddKeyEvent()
, if legacy indexing is desired, call io.SetKeyEventNativeData()** - Basically the trick we took advantage of is that we previously only supported native keycode from 0 to 511, so ImGuiKey values can still express a legacy native keycode, and new named keys are all >= 512.
- This will enable a few things in the future:
- Access to portable keys allows for backend-agnostic keyboard input code. Until now it was difficult to share code using keyboard across project because of this gap. (#2625, #3724)
- Access to full key ranges will allow us to develop a proper keyboard shortcut system. (#456)
- `io.SetKeyEventNativeData() include native keycode/scancode which may later be exposed. (#3141, #2959)
- Added
- Reworked IO nav/gamepad input API and unifying inputs sources: (#4921, #4858, #787)
- Added full range of
ImGuiKey_GamepadXXXX
enums (e.g.ImGuiKey_GamepadDpadUp
,ImGuiKey_GamepadR2
) to use withio.AddKeyEvent()
,io.AddKeyAnalogEvent()
. - Added
io.AddKeyAnalogEvent()
function, obsoleting writing directly toio.NavInputs[]
arrays.
- Added full range of
- Renamed
ImGuiKey_KeyPadEnter
toImGuiKey_KeypadEnter
to align with new symbols. Kept redirection enum. (#2625) - Removed support for legacy arithmetic operators (+,+-,*,/) when inputing text into a slider/drag. (#4917, #3184)
This doesn't break any API/code but a feature that was accessible by end-users (which seemingly no one used). (Instead you may implement custom expression evaluators to provide a better version of this). - Backends: GLFW: backend now uses
glfwSetCursorPosCallback()
.- If calling ImGui_ImplGlfw_InitXXX with install_callbacks=true: nothing to do. is already done for you.
- If calling ImGui_ImplGlfw_InitXXX with install_callbacks=false: you WILL NEED to register the GLFW callback
usingglfwSetCursorPosCallback()
and forward it to the backend functionImGui_ImplGlfw_CursorPosCallback()
.
- Backends: SDL: Added
SDL_Renderer*
parameter toImGui_ImplSDL2_InitForSDLRenderer()
, so backend can callSDL_GetRendererOutputSize()
to obtain framebuffer size valid for hi-dpi. (#4927) [@Clownacy] - Commented out redirecting functions/enums names that were marked obsolete in 1.69, 1.70, 1.71, 1.72 (March-July 2019)
ImGui::SetNextTreeNodeOpen()
-> useImGui::SetNextItemOpen()
ImGui::GetContentRegionAvailWidth()
-> useImGui::GetContentRegionAvail().x
ImGui::TreeAdvanceToLabelPos()
-> useImGui::SetCursorPosX(ImGui::GetCursorPosX() +
ImGui::GetTreeNodeToLabelSpacing());`ImFontAtlas::CustomRect
-> useImFontAtlasCustomRect
ImGuiColorEditFlags_RGB/HSV/HEX
-> useImGuiColorEditFlags_DisplayRGB/HSV/Hex
- Platform IME: Removed
io.ImeSetInputScreenPosFn()
in favor of more flexibleio.SetPlatformImeDataFn()
for IME support. Because this field was mostly only ever used by Dear ImGui internally, not by backends nor the vast majority of user code, this should only affect a very small fraction for users who are already very IME-aware. - Platform IME: Obsoleted
void* io.ImeWindowHandle
in favor of writing tovoid* ImGuiViewport::PlatformHandleRaw
. This removes an incompatibility between 'master' and 'multi-viewports' backends and toward enabling better support for IME. Updated backends accordingly. Because the old field is set by existing backends, we are keeping it (marked as obsolete).
Other Changes
- IO: Added event based input queue API, which now trickles events to support low framerates. Previously the most common issue case (button presses in low framerates) was handled by backend. This is now handled by core automatically for all kind of inputs. (#4858, #2787, #1992, #3383, #2525, #1320) [@thedmd, @ocornut]
- New IO functions for keyboard/gamepad:
io.AddKeyEvent()
,io.AddKeyAnalogEvent()
. - New IO functions for mouse:
io.AddMousePosEvent()
,io.AddMouseButtonEvent()
,io.AddMouseWheelEvent()
.
- New IO functions for keyboard/gamepad:
- IO: Unified key enums allow using key functions on key mods and gamepad values.
- Fixed CTRL+Tab into...
v1.86
Happy holidays!
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
Wiki: https://github.com/ocornut/imgui/wiki for bindings, extensions, links, etc.
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
Got visual glitches?
If you get visual glitches and incorrect dimming when using CTRL+Tab or Modal Windows:
It means your Rendering backend is not honoring the ImDrawCmd::IdxOffset
field correctly. Update your standard backend or fix your custom one. See this link about how the e.g. OpenGL2 backend was fixed recently. The issue was not noticeable until now so it is possible your Rendering backend never used the IdxOffset
field correctly.
Wrong code: during the rendering loop: draw call with idx_buffer
, then idx_buffer += cmd->ElemCount
after every command.
Correct code: during the rendering loop: draw call with idx_buffer + cmd->IdxOffset
Thank you!
Special thanks to @rokups for their continued work on stuff that are still not visible e.g. regression tests.
Special thanks to @PathogenDavid, @thedmd, for their continued contributions and helping with github answers.
Ongoing work on Dear ImGui is currently financially supported by:
Huge thank you to all past and present supporters!
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
TL;DR;
- CTRL+Tab is now available enabled regardless of the
ImGuiConfigFlags_NavEnableKeyboard
config flag. - Fixed issues with window reappearing while a modal is open.
- Fixes issues with menus and menubars in popups and modals.
- Various fixes/improvements to gamepad/keyboard navigation.
- Many improvements to
ImGuiListClipper
. Can now return non-contiguous ranges over multiple steps. Improvement for very large amount of contents. Fix drag and drop source being clipped when off scrolling. - Docking: Honor WindowBG color and borders better when docked + various fixes.
- Backends: OpenGL3 now has a workaround for multi-viewport leaks when using (buggy?) Intel HD drivers on Windows.
- Backends: OpenGL2, Allegro5: fixed mishandling ofImDrawCmd::IdxOffset
field. If you get visual glitches when using CTRL+Tabs or Modal, update your backend to get the fix. - Backends: OSX: Add game controller and better keyboard support.
- Many other fixes, features and improvements.
PS: previous release 1.85 added the incredibly useful STACK TOOL which we suggest you check out! (Demo>Tools>Stack Tool
or via calling ShowStackToolWindow()
).
Breaking Changes
(Suggestion: once in a while, add #define IMGUI_DISABLE_OBSOLETE_FUNCTIONS
in your imconfig.h
file to make sure you are not using to-be-obsoleted symbols.)
- Removed
CalcListClipping()
function. Prefer usingImGuiListClipper
which can return non-contiguous ranges. Please open an issue if you think you really need this function. (#3841) - Backends: OSX: Added
NSView*
parameter toImGui_ImplOSX_Init()
. (#4759) [@stuartcarnie] - Backends: Marmalade: Removed obsolete Marmalade backend (imgui_impl_marmalade.cpp) + example app. (#368, #375) Find last supported version at https://github.com/ocornut/imgui/wiki/Bindings
Other Changes
- Added an assertion for the common user mistake of using
""
as an identifier at the root level of a window instead of using"##something"
. Empty identifiers are valid and useful in a very small amount of cases, but 99.9% of the time if you need an empty label you should use"##something"
. (#1414, #2562, #2807, #4008, #4158, #4375, #4548, #4657, #4796). READ THE FAQ ABOUT HOW THE ID STACK WORKS > https://dearimgui.org/faq - Added
GetMouseClickedCount()
function, returning the number of successive clicks (soIsMouseDoubleClicked(ImGuiMouseButton_Left)
is same asGetMouseClickedCount(ImGuiMouseButton_Left) == 2
, but it allows testing for triple clicks and more). (#3229) [@kudaba] - Modals: fixed issue hovering popups inside a child inside a modal. (#4676, #4527)
- Modals, Popups, Windows: changes how appearing windows are interrupting popups and modals. (#4317) [@rokups]
- appearing windows created from within the begin stack of a popup/modal will no longer close it.
- appearing windows created not within the begin stack of a modal will no longer close the modal, and automatically appear behind it.
- Fixed
IsWindowFocused()
/IsWindowHovered()
issues with child windows inside popups. (#4676) - Nav: Ctrl+tabbing to cycle through windows is now enabled regardless of using the
ImGuiConfigFlags_NavEnableKeyboard
configuration flag. This is part of an effort to generalize the use of keyboard inputs. (#4023, #787). Note that while this is active you can also moving windows (with arrow) and resize (shift+arrows). - Nav: tabbing now cycles through clipped items and scroll accordingly. (#4449)
- Nav: pressing PageUp/PageDown/Home/End when in Menu layer automatically moves back to Main layer.
- Nav: fixed resizing window from borders setting navigation to Menu layer.
- Nav: prevent child from clipping items when using
_NavFlattened
and parent has a pending request. - Nav: pressing Esc to exit a child window reactivates the Nav highlight if it was disabled by mouse.
- Nav: with
ImGuiConfigFlags_NavEnableSetMousePos
enabled: Fixed absolute mouse position when using Home/End leads to scrolling. Fixed not setting mouse position when a failed move request (e.g. when already at edge) reactivates the navigation highlight. - Menus: fixed closing a menu inside a popup/modal by clicking on the popup/modal. (#3496, #4797)
- Menus: fixed closing a menu by clicking on its menu-bar item when inside a popup. (#3496, #4797) [@xndcn]
- Menus: fixed menu inside a popup/modal not inhibiting hovering of items in the popup/modal. (#3496, #4797)
- Menus: fixed sub-menu items inside a popups from closing the popup.
- Menus: fixed top-level menu from not consistently using
style.PopupRounding
. (#4788) - InputText, Nav: fixed repeated calls to
SetKeyboardFocusHere()
preventing to useInputText()
. (#4682) - Inputtext, Nav: fixed using
SetKeyboardFocusHere()
onInputTextMultiline()
. (#4761) - InputText: made double-click select word, triple-line select line. Word delimitation logic differs slightly from the one used by CTRL+arrows. (#2244)
- InputText: fixed
ImGuiInputTextFlags_ReadOnly
flag preventing callbacks from receiving the text buffer. (#4762) [@actondev] - InputText: fixed Shift+Delete from not cutting into clipboard. (#4818, #1541) [@corporateshark]
- InputTextMultiline: fixed incorrect padding when
FrameBorder > 0
. (#3781, #4794) - InputTextMultiline: fixed vertical tracking with large values of
FramePadding.y
. (#3781, #4794) - Separator: fixed cover all columns while called inside a table. (#4787)
- Clipper: currently focused item is automatically included in clipper range. Fixes issue where e.g. drag and dropping an item and scrolling ensure the item source location is still submitted. (#3841, #1725) [@GamingMinds-DanielC, @ocornut]
- Clipper: added
ForceDisplayRangeByIndices()
to force a given item (or several) to be stepped out during a clipping operation. (#3841) [@@GamingMinds-DanielC] - Clipper: rework so gamepad/keyboard navigation doesn't create spikes in number of items requested by the clipper to display. (#3841)
- Clipper: fixed content height declaration slightly mismatching the value of when not using a clipper (an additional ItemSpacing.y was declared, affecting scrollbar range).
- Clipper: various and incomplete changes to tame down scrolling and precision issues on very large ranges. Passing an explicit height to the clipper now allows larger ranges. (#3609, #3962).
- Clipper: fixed invalid state when number of frozen table row is smaller than ItemCount.
- Drag and Drop:
BeginDragDropSource()
withImGuiDragDropFlags_SourceAllowNullID
doesn't lose tooltip when scrolling. (#143) - Fonts: fixed infinite loop in
ImFontGlyphRangesBuilder::AddRanges()
when passing UINT16_MAX or UINT32_MAX without theIMGUI_USE_WCHAR32
compile-time option. (#4802) [@SlavicPotato] - Metrics: Added a node showing windows in submission order and showing the Begin() stack.
- Misc: Added missing
ImGuiMouseCursor_NotAllowed
cursor for software rendering (when theio.MouseDrawCursor
configuration flag is enabled). (#4713) [@nobody-special666] - Misc: Fixed software mouse cursor being rendered multiple times if Render() is called more than once.
- Misc: Fix MinGW DLL build issue (when
IMGUI_API
is defined). [@rokups] - CI: Add MinGW DLL build to test suite. [@rokups]
- Backends: Vulkan: Call
vkCmdSetScissor()
at the end of render with a full viewport to reduce likeho...
v1.85
Hello!
Reading the changelog is a good way to keep up to date with the things Dear ImGui has to offer, and maybe will give you ideas of some features that you've been ignoring until now!
Homepage: https://github.com/ocornut/imgui
Release notes: https://github.com/ocornut/imgui/releases
Wiki: https://github.com/ocornut/imgui/wiki for bindings, extensions, links, etc.
FAQ: https://www.dearimgui.org/faq/
Issues: https://github.com/ocornut/imgui/issues
Did you know? We have a Wiki!
It has sections such as this Useful Extensions Gallery!
Thank you!
Special thanks to @rokups for their continued work on stuff that are still not visible e.g. regression tests.
Special thanks to @PathogenDavid, @AidanSun05, @thedmd, for their continued contributions and helping with github answers.
Ongoing work on Dear ImGui is currently financially supported by:
Huge thank you to all past and present supporters!
Dear ImGui is funded by your contributions and needs them right now.
If your company uses Dear ImGui, consider reaching out. See Sponsors page for details.
TL;DR;
- New Stack Tool to help debugging the source of ID. Access from Demo>Tools or Metrics>Tools.
SetKeyboardFocusHere()
now works on clipped items (finally).- Nav: Plenty of fixes for gamepad/keyboard navigation.
- Docking, Viewports: various fixes.
- Menus: Fixed layout issue with MenuItem() calls inside a menu bar.
- Added SDL_Renderer backend for upcoming SDL 2.0.18+ (yet unreleased). Note that using native GL/DX backends is generally recommended but this is now available for users of the SDL_Renderer features.
- Dozens of other fixes and improvements.
Breaking Changes
(Suggestion: once in a while, add #define IMGUI_DISABLE_OBSOLETE_FUNCTIONS
in your imconfig.h
file to make sure you are not using to-be-obsoleted symbols.)
- Removed
GetWindowContentRegionWidth()
function. keep inline redirection helper. Can useGetWindowContentRegionMax().x - GetWindowContentRegionMin().x
instead but it's not very useful in practice, and the only use of it in the demo was ill-fit. UsingGetContentRegionAvail().x
is generally a better choice.
Other Changes
- Debug: Stack Tool: Added
Stack Tool
available inDemo->Tools->Stack Tool
,Metrics->Tools
, or by calling theShowStackToolWindow()
function. The tool run queries on hovered id to display details about individual components that were hashed to create an ID. It helps understanding the ID stack system and debugging potential ID collisions. (#4631) [@ocornut, @rokups] - Windows: Fixed background order of overlapping childs submitted sequentially. (#4493)
- IsWindowFocused: Added
ImGuiFocusedFlags_NoPopupHierarchy
flag allowing to exclude child popups from the tested windows when combined withImGuiFocusedFlags_ChildWindows
. - IsWindowHovered: Added
ImGuiHoveredFlags_NoPopupHierarchy
flag allowing to exclude child popups from the tested windows when combined withImGuiHoveredFlags__ChildWindows
. - InputTextMultiline: Fixed label size not being included into window contents rect unless the whole widget is clipped.
- InputText: Allow activating/cancelling/validating input with gamepad nav events. (#2321, #4552)
- InputText: Fixed selection rectangle appearing one frame late when selecting all.
- TextUnformatted: Accept null ranges including (NULL,NULL) without asserting, in order to conform to common idioms (e.g. passing .data(), .data() + .size() from a null string). (#3615)
- Disabled: Added assert guard for mismatching
BeginDisabled()
/EndDisabled()
blocks. (#211) - Nav: Fixed using
SetKeyboardFocusHere()
on non-visible/clipped items. It now works and will scroll toward the item. When called during a frame where the parent window is appearing, scrolling will aim to center the item in the window. When calling during a frame where the parent window is already visible, scrolling will aim to scroll as little as possible to make the item visible. We will later expose scroll functions and flags in public API to select those behaviors. (#343, #4079, #2352) - Nav: Fixed using
SetKeyboardFocusHere()
from activating a different item on the next frame if submitted items have changed during that frame. (#432) - Nav: Fixed toggling menu layer with Alt or exiting menu layer with Esc not moving mouse when the
ImGuiConfigFlags_NavEnableSetMousePos
config flag is set. - Nav: Fixed a few widgets from not setting reference keyboard/gamepad navigation ID when activated with mouse. More specifically:
BeginTabItem()
, the scrolling arrows ofBeginTabBar()
, the arrow section ofTreeNode()
, the +/- buttons ofInputInt()
/InputFloat()
,Selectable()
withImGuiSelectableFlags_SelectOnRelease
. More generally: any direct use ofButtonBehavior()
with the PressedOnClick/PressedOnDoubleClick/PressedOnRelease button policy. - Nav: Fixed an issue with losing focus on docked windows when pressing Alt while keyboard navigation is disabled. (#4547, #4439) [@PathogenDavid]
- Nav: Fixed vertical scoring offset when wrapping on Y in a decorated window.
- Nav: Improve scrolling behavior when navigating to an item larger than view.
- TreePush(): removed unnecessary/inconsistent legacy behavior where passing a NULL value to the
TreePush(const char*)
andTreePush(const void*)
functions would use an hard-coded replacement. The only situation where that change would make a meaningful difference isTreePush((const char*)NULL)
(explicitly casting a null pointer to const char*), which is unlikely and will now crash. You may replace it with anything else. - ColorEdit4: Fixed not being able to change hue when saturation is 0. (#4014) [@rokups]
- ColorEdit4: Fixed hue resetting to 0 when it is set to 255. [@rokups]
- ColorEdit4: Fixed hue value jitter when source color is stored as RGB in 32-bit integer and perform RGB<>HSV round trips every frames. [@rokups]
- ColorPicker4: Fixed picker being unable to select exact 1.0f color when dragging toward the edges of the SV square (previously picked 0.999989986f). (#3517) [@rokups]
- Menus: Fixed vertical alignments of
MenuItem()
calls within a menu bar (broken in 1.84). (#4538) - Menus: Improve closing logic when moving diagonally in empty between between parent and child menus to accommodate for varying font size and dpi.
- Menus: Fixed crash when navigating left inside a child window inside a sub-menu. (#4510).
- Menus: Fixed an assertion happening in some situations when closing nested menus (broken in 1.83). (#4640)
- Drag and Drop: Fixed using
BeginDragDropSource()
inside aBeginChild()
that returned false. (#4515) - PlotHistogram: Fixed zero-line position when manually specifying min<0 and max>0. (#4349) [@filippocrocchini]
- Misc: Added asserts for missing
PopItemFlag()
calls. - Misc: Fixed printf-style format checks on Clang+MinGW. (#4626, #4183, #3592) [@guusw]
- IO: Added
io.WantCaptureMouseUnlessPopupClose
alternative toio.WantCaptureMouse
. (#4480) This allows apps to receive the click on void when that click is used to close popup (by default, clicking on a void when a popup is open will close the popup but not releaseio.WantCaptureMouse
). - Fonts: imgui_freetype: Fixed crash when
FT_Render_Glyph()
fails to render a glyph and returns NULL (which apparently happens with Freetype 2.11). (#4394, #4145?). - Fonts: Fixed
ImFontAtlas::ClearInputData()
marking atlas as not built. (#4455, #3487) - Backends: Added more implicit asserts to detect invalid/redundant calls to Shutdown functions. (#4562)
- Backends: OpenGL3: Fixed our custom GL loader conflicting with user using GL3W. (#4445) [@rokups]
- Backends: WebGPU: Fixed for latest specs. (#4472, #4512) [@Kangz, @bfierz]
- Backends: SDL_Renderer: Added SDL_Renderer backend compatible with upcoming SDL 2.0.18. (#3926) [@1bsyl]
- Backends: Metal: Fixed a crash when clipping rect larger than framebuffer is submitted via a direct unclipped
PushClipRect()
call. (#4464) - Backends: OSX: Use mach_absolute_time as CFAbsoluteTimeGetCurrent can jump backwards. (#4557, #4563) [@lfnoise]
- Backends: All renderers: Normalize clipping rect handling across backends. (#4464)
- Examples: Added SDL + SDL_Renderer example in examples/example_sdl_sdlrenderer folder. (#3926) [@1bsyl]
Other branches & Beta features!
Also see previous release notes such as 1.80, 1.81, 1.80, 1.83, 1.84.
The docking (#2109) and multi-viewports (#1542) features are available in the docking branch, they are in beta but actively maintained and being used by many teams already. Your continuous feedback is always appreciated.
Some of changes from 1.84 to ...
v1.84.2
Apologies, 1.84.1 still had issue with nested BeginDisabled()
/EndDisabled()
calls. What a botched release! Issuing a fix for it.
See 1.84 release notes for the full list.
All changes:
- Disabled: Fixed nested
BeginDisabled()
/EndDisabled()
calls. (#211, #4452, #4453, #4462) [@Legulysse] - Backends: OpenGL3: OpenGL: Fixed ES 3.0 shader (
"#version 300 es"
) to use normal precision floats. Avoid wobbly rendering at HD resolutions. (#4463) [@nicolasnoble]