577 Commits (cc12ea084bb68893fc23e220ce44bcf3a6764acd)

Author SHA1 Message Date
omar 54b38d88f7 TreeNode: Fixed bug where BeginDragDropSource() failed when the _OpenOnDoubleClick flag is set. Added basic demo code. (Amend 05420ea) 5 years ago
omar e8c986b34e Version 1.77 WIP 5 years ago
omar 5503c0a12e Version 1.76
+ fixed PVS warning, update demo binaries, update readme image
5 years ago
omar ec7294d890 Backends: OpenGL3: Fixed version check mistakenly testing for GL 4.0+ instead of 3.2+ to enable ImGuiBackendFlags_RendererHasVtxOffset, leaving 3.2 contexts without it. (#3119, #2866, #2852) 5 years ago
SergeyN 977ac53dd8 Examples: Win32+DX12: Fixed resizing main window, enabled debug layer. (#3087, #3115) 5 years ago
omar fb70d90fef Made default clipboard handlers for Win32 and OSX use a buffer inside the main context instead of a static buffer, so it can be freed properly on Shutdown. (#3110) 5 years ago
omar 752436219d Metrics: Made Tools section more prominent, added options, made mesh viewer more accessible. 5 years ago
omar cc0d4e346a Misc: Added an explicit compile-time test for non-scoped IM_ASSERT() macros to redirect users to a solution + fixed our stb wrappers.
+ Nav: Use nav layer enum, comments.
5 years ago
omar 11116eee80 Columns: undid the change in 1.75 were Columns()/BeginColumns() were preemptively limited to 64 columns with an assert. (#3037, #125)
Essentially reverting 9d444062f9.
5 years ago
omar 3490046c97 Nav: Disabled clipping g.NavId and fixed interactions with ImGuiListClipper. (#787) 5 years ago
omar 05420ea2cf TreeNode: Made clicking on arrow with _OpenOnArrow toggle the open state on the Mouse Down event rather than the Mouse Down+Up sequence (this is rather standard behavior). 5 years ago
omar ec2a24a5f1 Selectable: Allow using ImGuiSelectableFlags_SpanAllColumns in other columns than first. Comments. (#125) 5 years ago
omar 7c11997bcc Selectable: Fixed honoring style.SelectableTextAlign with unspecified size. (#2347, #2601) 5 years ago
omar 670367e51d Added IMGUI_USE_WCHAR32 instead of "#define ImWchar ImWchar32" to faclitate C-binding. (#2538, #2541, #2815) 5 years ago
omar f2b01c3436 Changelog, tweak OpenGL3 backends. (#3061), update Gallery thread links. 5 years ago
omar 4986dba270 Scrolling: Fixed scrolling centering API leading to non-integer scrolling values and initial cursor position. (#3073)
This would often get fixed after the fix item submission, but using the ImGuiListClipper as the first thing after Begin() could largely break size calculations. (#3073)
5 years ago
omar ccf0cc8584 Added ImGuiKeyModFlags. Added additional checks in EndFrame() to verify that io.KeyXXX values have not been tampered with between NewFrame() and EndFrame(). 5 years ago
omar d8824f9a9a CI: Clarify purpose of example_null, Changelog 5 years ago
David Kalnischkies 2fd411a83e Support custom stb_rect_pack filename in Freetype (#3062)
Copies the #define magic from imgui_draw.cpp to the imgui_freetype implementation to allow the use of a custom stb rect_pack here as well.
References: fe5347ef94
5 years ago
Rokas Kupstys 75a65f6fb0 CI: Test build with large indices, obsolete functions disabled and demo/metrics windows disabled.
+ amend notes
5 years ago
ocornut b016f1ad70 Examples: SDL+DX11: Fixed resizing main window. Amend (#3057) 5 years ago
ocornut b029182a73 Merge branch 'features/unicode' 5 years ago
omar 897704cb49 Menus: Tweak for first-level menu windows to be positioned regardless of MenuBarHeight() which is not stored in window, allowing undocumented modification of the menu bar height). 5 years ago
ocornut a41332453e Unicode: Changelog, comments, minimum CI integration. (#2541, #2538, #2815) 5 years ago
Rokas Kupstys 0342a3c548 Menus: Implement BeginMenu() appending to existing menu when executed with same ID multiple times. (#1207) 5 years ago
ocornut e547f898a9 Demo: Added color gradient in demo to identify srgb/linear issues better. Tweaks. 5 years ago
ocornut 0345324646 Backends: SDL: Fixed mapping for ImGuiKey_KeyPadEnter. (#3031) [@Davido71] 5 years ago
ocornut 02a6c06080 Window: Fixed a bug with child window inheriting ItemFlags from their parent when the child window also manipulate the ItemFlags stack. (#3024) [@Stanbroek]
Amend f843facba4 and 8828889d5e
5 years ago
Omar ea3fc76038 BeginMenu: Fixed a bug where SetNextWindowXXX data before a BeginMenu() would not be cleared when the menu is not open. (#3030) 5 years ago
Omar 8836975dcf Drag and Drop, Nav: Disabling navigation arrow keys when drag and drop is active. (#3025) 5 years ago
Omar ceec3cd3fd Backends: Win32: Added ImGui_ImplWin32_EnableDpiAwareness(), ImGui_ImplWin32_GetDpiScaleForHwnd(), ImGui_ImplWin32_GetDpiScaleForMonitor() helpers functions.
(backported from the docking branch)
5 years ago
omar d284a6cffc InputText: Fixed password fields displaying ASCII spaces as blanks. Fixed non-ASCII space occasionally creating unnecessary empty polygons. (#2149, #515) 5 years ago
omar 70975fe44d Demo: Added a black and white gradient to Demo>Examples>Custom Rendering. 5 years ago
omar d8948b5343 ColorButton: Added ImGuiColorEditFlags_NoBorder flag to remove the border normally enforced by default. 5 years ago
Rokas Kupstys 21b9e42964 Minor fixes to example_sdl_metal and a changelog entry.
Add example_sdl_metal to CI builds.

Closes #3017.
5 years ago
omar 58b3e02b95 Version 1.75
Comments
5 years ago
omar d37d25470a Added IMGUI_DISABLE compile-time definition to make all headers and sources empty. 5 years ago
omar f694244dec InputText: Fix using a combination of _CallbackResize + _EnterReturnsTrue + lack of persisting user storage. (#3009)
Amend 24ff25981 (#2006, #1443, #1008)
5 years ago
omar bdbb2b21f5 Fix 83efdcec from overflowing buffer + make it a single undo records + comments (#3008) 5 years ago
Rokas Kupstys 83efdcec8d Canceling text input with [esc] key uses stb_textedit facilities to restore original value. This makes restoration undoable using hotkeys.
Fixes #3008.
5 years ago
omar fc42528f13 When testing for the presence of the ImGuiWindowFlags_NoBringToFrontOnFocus flag we test both the focused/clicked window (which could be a child window) and the root window. 5 years ago
omar d9bca0d853 Nav: Fixed a bug where the initial CTRL-Tab press while in a child window sometimes selected the current root window instead of always selecting the previous root window. (#787) 5 years ago
omar 47fab0e166 Misc renaming, comments. Docs: add missing spacing to Changelog. 5 years ago
Rokas Kupstys 9cff4d6e5e Columns: ImDrawList::Channels* functions now work inside columns.
Use a private splitter in columns, paving way for removal of obsolete ImDrawList::Channels* functions.
5 years ago
omar 05a49f0413 Examples: Emscripten: Demonstrating embedding fonts in Makefile and code. (#2953) [@Oipo] 5 years ago
Konstantin Podsvirov 8cbb693f47 Emscripten: Allow filesystem support. (#3005)
Filesystem functions perfectly work for Emscripten platform. This changes remove extra changes added by #2734.
You can still disable filesystem functions by defining IMGUI_DISABLE_FILE_FUNCTIONS.
5 years ago
omar 6e1f8be07b Window: Fix SetNextWindowBgAlpha(1.0f) failing to override alpha component. (#3007) 5 years ago
omar 5f4dfad5b7 Merge misc/shallow changes from Docking to reduce drift.
Most are comments. Fix menu bar clipping: 07ff47bf1b
5 years ago
omar 4d4e3b97f4 TODO, Readme
(dropped TreeNode_NoIndent flag from todo, as it feels unnecessary)
5 years ago
omar f6da5000bf Backends: OpenGL2: Explicitly backup, setup and restore GL_TEXTURE_ENV to increase compatibility with legacy OpenGL applications. (#3000) 5 years ago
omar 5363af7f47 AddCircle, AddCircleFilled: Add auto-calculation of circle segment counts (amends)
Tweak default max error value, Changelog, comments, path-fast for 12 segments circles, made LUT store ImU8
5 years ago
omar 8bcac7d95c Backends: GLFW, SDL: report Windows key (io.KeySuper) as always released.
Neither GLFW nor SDL can correctly report the key release in every cases (e.g. when using Win+V) causing problems with some widgets. The next release of GLFW (3.4+) will have a fix for it. However since it is both difficult and discouraged to make use of this key for Windows application anyway, we just hide it. (#2976)
5 years ago
omar e499497ec5 Backends: Win32: Added support for io.KeySuper (Windows key) for consistency with other backends. (#2976)
Even if realistically it is difficult to make good use of under Windows.
+ Style editor: Use a more explicit form of RadioButton() to avoid being depending on underlying flags type. (#2983)
5 years ago
Loïc Molinari 6c00d1916e Disable format checks when using stb_sprintf.h
STB sprintf allows extra formats like %b or %$d. If ImGui is configured
to use STB sprintf, it generates warnings with GCC and clang when using
such formats because it keeps applying default printf-style warnings.
This commit disables printf-style warnings when using STB sprintf.

Since the printf-style warnings are defined in imgui.h based on the
compiler, IMGUI_USE_STB_SPRINTF can't just be defined in the cpp file
anymore and it's been moved as a proper config in imconfig.h.
5 years ago
omar 4f7bf7e96a Backends: Win32: Added support for #define IMGUI_IMPL_WIN32_DISABLE_GAMEPAD and IMGUI_IMPL_WIN32_DISABLE_LINKING_XINPUT. (#2716) 5 years ago
omar f56962cb9a ColorEdit: "Copy As" context-menu tool shows hex values with a '#' prefix instead of '0x' + both with/without alpha when available. 5 years ago
omar ff5299e0e0 Docs: FAQ, Comments. 5 years ago
Rokas Kupstys f03c00bc89 Added imgui_single_file.h, We use this to validate compiling all *.cpp in same compilation unit.
Removed Unity builds stuff from example_null/. CI builds a temporary .cpp file.
5 years ago
Rokas Kupstys 97a8dc6514 CI: Added PVS-Studio static analysis on the continuous-integration server. 5 years ago
omar 1db78b8ca7 Renaming + missing initialization + missing Changelog update. 5 years ago
Rokas Kupstys 5e2329b98e Backends: GL3: Implement glbinding opengl loader support. (#2870) 5 years ago
Rokas Kupstys e254167afd ColorEdit: Fix label alignment when using ImGuiColorEditFlags_NoInputs. (#2955) 5 years ago
omar 0f7105e156 Backends: SDL: Wayland: Use SDL_GetMouseState (amend 78ff147) (#2800, 2802) 5 years ago
omar 9d444062f9 Limiting Columns()/BeginColumns() api to 64 columns (#125)
While the current code technically supports it, future code may not so we're putting the restriction ahead.
5 years ago
omar 43bd80a40d Internals: Breaking: ImRect() default constructor initializes all fields with 0.0f
Instead of (FLT_MAX,FLT_MAX,-FLT_MAX,-FLT_MAX). Previous behavior was designed for adding into a bounding box but rarely relied on and not worth it.
5 years ago
Ben Carter 0e74103659 ImDrawList: Add AddNgon(), AddNgonFilled() API. 5 years ago
omar f9c26d23de Removed redirecting functions/enums that were marked obsolete in 1.53 (December 2017).
Comments
5 years ago
Ben Carter 697f15e339 Added PrimUnreserve() API. Obsoleted calling ImDrawList::PrimReserve() with a negative count. 5 years ago
omar f656e7775e Inputs: Added ImGuiMouseButton enum for convenience (e.g. ImGuiMouseButton_Right=1).
We forever guarantee that the existing value will not changes so existing code is free to use 0/1/2.
5 years ago
omar 7ff13f4ee1 Examples: Explicitly adding -DIMGUI_IMPL_OPENGL_LOADER_GL3W to Makefile to match linking settings
(otherwise if another loader such as Glew is accessible, the opengl3 backend might automatically use it). [#2919, #2798]
5 years ago
omar b521cd357d Removed implicit default parameter to IsMouseDragging(int button = 0) to be consistent with other mouse functions.
(none of the other functions have it).
5 years ago
Max Thrun 6d9a54a904 Examples: Metal: Wrap main event loop body in an @autoreleasepool block to ensure allocations get freed even if underlying system event loop gets paused due to app nap (#2910, #2917) 5 years ago
omar 8342e5b91a Amend previous commits (added ImGuiMouseCursor_NotAllowed enum + new cursors in GLFW 3.4)
Amend b5cad20d79, 945a509773
+ unrelated minor typos
5 years ago
omar abaf0256b8 Version 1.75 WIP
Added message to font file loading assert.
5 years ago
omar bdce833636 Version 1.74 5 years ago
omar 26d177bc03 Docs: Moved misc/fonts/README.txt to docs/FONTS.txt. + tweaks 5 years ago
omar bbe0409942 Metrics: Show wire-frame mesh and approximate surface area when hovering ImDrawCmd. Amend aeb5795.
Internals: Added ImTriangleArea()
5 years ago
omar 51a02b319c Added IM_UNICODE_CODEPOINT_MAX. Changed specs of ImFontAtlas::AddCustomRectRegular() (breaking change). 5 years ago
omar ca63349eb4 Renamed XX-bits -> XX-bit in comments to match what the world appears to be using. 5 years ago
omar ecbedc8c26 Tweaks, ammend 93efa54, rename to IMGUI_DISABLE_DEFAULT_FORMAT_FUNCTIONS (#1038) 5 years ago
omar 4e90906b04 Added IMGUI_DISABLE_DEFAULT_FILE_FUNCTIONS / IMGUI_DISABLE_FILE_FUNCTIONS #2734)
Using in Emscripten example.
5 years ago
omar 93efa5415f Renamed IMGUI_DISABLE_FORMAT_STRING_FUNCTIONS to IMGUI_DISABLE_DEFAULT_FORMAT_STRING_FUNCTIONS. (#1038)
Renamed IMGUI_DISABLE_MATH_FUNCTIONS to IMGUI_DISABLE_DEFAULT_MATH_FUNCTIONS.
5 years ago
Tracy Ma 8f40020ca6 Disable Win32 clipboard and IME functions when build target UWP (#2892, #2895) 5 years ago
omar be05e12e21 Misc: Using static_assert() when using C++11, instead of our own construct (avoid zealous Clang warnings). 5 years ago
omar 25eee91542 Error handling: Assert if user mistakenly calls End() instead of EndChild() on a child window. (#1651)
Internals: Moved some error handling code.
5 years ago
omar 6e8e2c0fa9 Scrollbar: Fixed an issue where scrollbars wouldn't display on the frame following a frame where all child window contents would be culled.
Demo: Fixed a small bug with scrolling demo.
Metrics: Tweaks.
5 years ago
omar 57dc34f4e8 TreeNode: Added IsItemToggledOpen() to explicitly query if item was just open/closed, facilitating interactions with custom multi-selections patterns. (#1896, #1861) 5 years ago
omar 011d475532 TreeNode: The collapsing arrow accepts click even if modifier keys are being held, facilitating interactions with multi-select patterns. (#2886, #1896, #1861) 5 years ago
omar 4c13807b7d Misc: Optimized storage of window settings data (reducing allocation count). 5 years ago
omar 3929255b77 Examples: Emscripten: Removed BINARYEN_TRAP_MODE=clamp from Makefile which was removed in Emscripten 1.39.0 but required prior to 1.39.0, making life easier for absolutely no-one. (#2877, #2878) [@podsvirov] 5 years ago
omar 792a8631aa Metrics: Expose basic details of each window key/value state storage. 5 years ago
omar d62a413476 Misc: Windows: Do not use _wfopen() if IMGUI_DISABLE_WIN32_FUNCTIONS is defined. (#2815) 5 years ago
omar f002a11898 Backends: OpenGL3: Fix building with pre-3.2 GL bindings which do not expose glDrawElementsBaseVertex(), using runtime GL version to decide if we set ImGuiBackendFlags_RendererHasVtxOffset. (#2866, #2852) [@dpilawa] 5 years ago
Rokas Kupstys d5b5a81946 GitHub Actions CI script for Windows/Linux/MacOS/iOS/Emscripten builds. 5 years ago
omar ec0e953cca Fixed a couple of subtle bounding box vertical positioning issues relating to text baseline alignment.
The issue would generally manifest when laying out multiple items on a same line, with varying heights and text baseline offsets. (#2833)
Some specific examples, e.g. a button with regular frame padding followed by another item with a multi-line label and no frame padding, such as: multi-line text, small button, tree node item, etc. The second item was correctly offset to match text baseline, and would interact/display correctly,but it wouldn't push the contents area boundary low enough.
Note: previously the second parameter to ItemSize() was 0.0f was default, now -1.0f to signify "no text baseline offset request". If you have code using ItemSize() with an hardcoded zero you may need to change it. (+1 squashed commits)
5 years ago
Alexey be9f1e8f00 ColorPicker: Fixed SV triangle gradient to block (broken in 1.73). (#2864, #2711). [@lewa-j] 5 years ago
omar 23c1ff4907 Removed redirecting functions/enums names that were marked obsolete in 1.52 (October 2017).
- Begin() [old 5 args version]     -> use Begin() [3 args], use SetNextWindowSize() SetNextWindowBgAlpha() if needed
- IsRootWindowOrAnyChildHovered()  -> use IsWindowHovered(ImGuiHoveredFlags_RootAndChildWindows)
- AlignFirstTextHeightToWidgets()  -> use AlignTextToFramePadding();
- SetNextWindowPosCenter()         -> use SetNextWindowPos() with a pivot of (0.5f, 0.5f)
- ImFont::Glyph                    -> use ImFontGlyph
If you were still using the old names, read "API Breaking Changes" section of imgui.cpp to find out the new names or equivalent features, or see how they were implemented until 1.73.
5 years ago
omar 6ffee0e75e Backends: DX12: Added extra ID3D12DescriptorHeap parameter to ImGui_ImplDX12_Init() function. The value is unused in master branch but will be used by the multi-viewport features (docking branch). (#2851)
+ Using SafeRelease() in master.
5 years ago
omar eedc8f993f Examples: DX12: Using IDXGIDebug1::ReportLiveObjects() when DX12_ENABLE_DEBUG_LAYER is enabled. 5 years ago
malte-v 4de32cc87e Backends: GLFW: Restore previously installed user callbacks in ImplGlfw when ImGui shuts down (#2836) 5 years ago
omar 5fc427a49e Improved and moved FAQ to docs/FAQ.md so it can be readable on the web. (#2848) 5 years ago
omar a41f0b2df4 Inputs: Fixed a miscalculation in the keyboard/mouse "typematic" repeat delay/rate calculation, used by keys and e.g. repeating mouse buttons as well as the GetKeyPressedAmount() function.
IMPORTANT: Renamed internal CalcTypematicPressedRepeatAmount to CalcTypematicRepeatAmount and reordered the t1, t0 arguments to t0, t1 !!
If you were using a non-default value for io.KeyRepeatRate (previous default was 0.250), you can add +io.KeyRepeatDelay to it to compensate for the fix.  The function was triggering on: 0.0 and (delay+rate*N) where (N>=1). Fixed formula responds to (N>=0).
Effectively it made io.KeyRepeatRate behave like it was set to (io.KeyRepeatRate + io.KeyRepeatDelay).
Fixed the code and altered default io.KeyRepeatRate,Delay from 0.250,0.050 to 0.300,0.050 to compensate.
If you never altered io.KeyRepeatRate nor used GetKeyPressedAmount() this won't affect you.
5 years ago
omar aeb6481499 InputText: Filter out Ascii 127 (DEL) emitted by low-level OSX layer, as we are using the Key value. (#2578) 5 years ago
omar fc10ba8d24 Amend f0238ece9cba67ecabef438008fea53682bd6bc7 (#2817, #2818) 5 years ago
omar bf746c4215 DragScalar, SliderScalar, InputScalar: Added p_ prefix to parameter that are pointers to the datato clarify how they are used, and more comments redirecting to the demo code. (#2844) 5 years ago
omar 3b271b1847 Demo: Added simple item reordering demo in Widgets -> Drag and Drop section. (#2823, #143) [@rokups] 5 years ago
omar ee3373d067 TreeNode: Fixed combination of ImGuiTreeNodeFlags_SpanFullWidth and ImGuiTreeNodeFlags_OpenOnArrow incorrectly locating the arrow hit position to the left of the frame. (#2451, #2438, #1897) 5 years ago
omar 892dfb1dea InputText, Nav: Fixed Home/End key broken when activating Keyboard Navigation. (#787)
Small refactor of ActiveIdUsingXXX inputs flags toward a little more consistent system. (#2637)
5 years ago
omar c262276988 Version 1.74 WIP 5 years ago
omar d5efe16157 Version 1.73 5 years ago
omar 664f9e76b9 Documentation: Various tweaks and improvements to the README page. [@ker0chan] 5 years ago
goran-w e100523917 CollapsingHeader: Added support for ImGuiTreeNodeFlags_Bullet and ImGuiTreeNodeFlags_Leaf on framed nodes. (#2159, #2160)
The Bullet and Leaf ImGuiTreeNodeFlags are now taken into account for Framed/CollapsingHeader tree nodes as well. TreeNodeEx() can be used to specify these flags. A choice was made to left-adjust the Framed text when no Bullet/Arrow is rendered, since this was deemed to look better in the Framed context (especially when considering that CollapsingHeader is drawn using NoTreePushOnOpen, so child/sibling Text items etc will often be non-indented).
5 years ago
omar ca858c084b Demo tweaks. Comments. Compacting the rarely used AutoFitXXX fields in ImGuiWindowTempData. 5 years ago
omar 25849234f6 Internal: Tree: tweaks (initially tried to implement auto-scrolling, stashed) 5 years ago
omar 97691643b7 Backends: OpenGL3: Attempt to automatically detect default GL loader by using __has_include. Followup to 44cd8e3 (#2798) 5 years ago
omar f47a0a85cc ImVector: added find, find_erase, find_erase_unsorted helpers. 5 years ago
omar eab03f4467 Selectable: Added ImGuiSelectableFlags_AllowItemOverlap flag in public api (was previously internal only). 5 years ago
omar f7468d05fe Fixed mouse event forwarding in macos example (#2710, #1961) 5 years ago
omar 38d22bc47d ColorPicker / ColorEdit: restore Hue when zeroing Saturation. (#2722, #2770) - changelog, fixed uninitialized variables, tweaks, renaming. 5 years ago
omar 9d02ed51e3 TreeNode: Added ImGuiTreeNodeFlags_SpanAvailWidth and ImGuiTreeNodeFlags_SpanFullWidth flags (#2451, #2438, #1897)
Added demo bits.
5 years ago
omar 098591fe4c ImDrawListSplitter: fixed an issue merging channels if the last submitted draw command used a different texture. (#2506) 5 years ago
omar b48dc067ae Style: Allow style.WindowMenuButtonPosition to be set to ImGuiDir_None to hide the collapse button. (#2634, #2639)
+ Fix #2775
5 years ago
omar 57623c15dd Font: Narrow ellipsis: various minor stylistic tweaks (#2775) 5 years ago
omar 3dcf323c35 Columns: Separator: Fixed a bug where non-visible separators within columns would alter the next row position differently than visible ones.
Fixed rounding issues also leading to change of ScrollMax depending on visible items (in particular negative coordinate would be rounded differently)
5 years ago
omar b05f6f6f50 Nav, Scrolling: Added support for Home/End key. (#787) 5 years ago
Bagrat Dabaghyan 3cf519c9cb Fix DragScalar for unsigned types (#2780)
decreasing the value was broken on arm64
5 years ago
omar cc288e073c Backends: OpenGL3: Tweaked initialization code allow application calling ImGui_ImplOpenGL3_CreateFontsTexture() before ImGui_ImplOpenGL3_NewFrame() if for some reason they wanted. 5 years ago
omar 0537ac005f ColorEdit: Disable Hue edit when Saturation==0 instead of letting Hue values jump around. 5 years ago
omar b59ec7b9b7 DragInt, DragFloat, DragScalar: Using (v_min > v_max) allows locking any edit to the value. 5 years ago
omar 3f99890f40 TabBar: feed desired width (sum of unclipped tabs width) into layout system to allow for auto-resize. (#2768)
Before 1.71 tab bars fed the sum of current width which created feedback loops in certain situations. Amend f95c77eeea.
5 years ago
omar f8d3d8d7f5 TabBar: improved shrinking for large number of tabs to avoid leaving extraneous space on the right side. Individuals tabs are given integer-rounded width and remainder is spread between tabs left-to-right. 5 years ago
omar 62f75c7fb1 Added a mechanism to compact/free the larger allocations of unused windows (buffers are compacted when a window is unused for 60 seconds, as per io.ConfigWindowsMemoryCompactTimer = 60.0f). Note that memory usage has never been reported as a problem, so this is merely a touch of overzealous luxury. (#2636) 5 years ago
omar c8418015c2 SliderScalar: Improved assert when using U32 or U64 types with a large v_max value. (#2765)
+  misc minor stuff.
5 years ago
Tommy Nguyen bcdb89ab07 Rebased imstb_rectpack on stb_rect_pack v1.00. 5 years ago
omar c4ff1b3578 ImDrawList: clarified the name of many parameters so reading the code is a little easier. (#2740) 5 years ago
omar 3fb5cf3541 Using offsetof() when available in C++11. Avoids Clang sanitizer complaining about old-style macros. (#94) 5 years ago
omar a856c670c1 TabBar: fixed single-tab not shrinking their width down.
+ minor typo fixes (#2738)
5 years ago
omar 7abd41bd5f TabBar: fixed ScrollToBar request creating bouncing loop when tab is larger than available space. 5 years ago
omar 9fce278918 ColorPicker: Made rendering aware of global style alpha of the picker can be faded out. (#2711)
Note that some elements won't accurately fade down with the same intensity, and the color wheel when enabled will have small overlap glitches with (style.Alpha < 1.0).
5 years ago
Vilya Harvey 62143dff64 Backends: Vulkan: Added support for specifying multisample count. (#2705, #2706) 5 years ago
omar 6cf4743f17 Backends: DX11: Fixed GSGetShader() call not passing an initialized instance count, would generally make the debug layer complain (Added in 1.72). 5 years ago
omar f624455d7b Version 1.73 WIP 5 years ago
omar 6a0d0dab5a Version 1.72b (patch for nav) 5 years ago
omar 27079e68c2 Nav: Made hovering non-MenuItem Selectable not re-assign the source item for keyboard navigation. 5 years ago
omar 4cfaf7d89c Scrolling, Nav: Fixed programmatic scroll leading to a slightly incorrect scroll offset when the window has decorations or a menu-bar (broken in 1.71). This was mostly noticeable when a keyboard/gamepad movement led to scrolling the view, or using e.g. SetScrollHereY() function. Fix/amend a0994d74. 5 years ago
omar 1b1e539288 Internal: Moved NavScrollToBringItemIntoView() declaration to imgui_internal.h. Fixed spacing missing in 494d804. Fixed changelog wreck from 1.72. 5 years ago
omar 9183e7c426 Version 1.73 WIP 5 years ago
omar ecb9b1e2eb Version 1.72 5 years ago
omar 7a26a49f08 Internal: Added IsMouseDragPastThreshold(). Tweaks. Todo.
Demo: Showing how to use the format parameter of Slider/Drag functions to display the name of an enum value instead of the underlying integer value
5 years ago
omar 26f14e056c Scrolling: Made mouse-wheel scrolling lock the underlying window until the mouse is moved again or until a short delay expires (2 seconds). This allow uninterrupted scroll even if child windows are passing under the mouse cursor. (#2604) 5 years ago
omar dcd03f62a7 Scrolling: Made it possible for mouse wheel and navigation-triggered scrolling to override a call to SetScrollX()/SetScrollY(), making it possible to use a simpler stateless pattern for auto-scrolling.
Demo: Log, Console: Using a simpler stateless pattern for auto-scrolling.
5 years ago
omar 34cf00566f InputTextMultiline: Fixed vertical scrolling tracking glitch.
Fixed Travis-CI banner address.
5 years ago
omar cbd5a21fb0 Backends: DX10/DX11: Backup, clear and restore Geometry Shader is any is bound when calling renderer.
Backends: DX11: Clear Hull Shader, Domain Shader, Compute Shader before rendering. Not backing/restoring them.
5 years ago
omar 29d9394a41 OSX: Disabled default native Mac clipboard copy/paste implementation in core library (added in 1.71), because it needs application to be linked with '-framework ApplicationServices'. It can be explicitly enabled back by using '#define IMGUI_ENABLE_OSX_DEFAULT_CLIPBOARD_FUNCTIONS' in imconfig.h. Re-added equivalent using NSPasteboard api in the imgui_impl_osx.mm experimental back-end. (#2546) 5 years ago
omar f0348ddffc Amend 0f86116, renamed to ImGuiKey_KeyPadEnter Changelog.. (#2677, #2005) 5 years ago
omar c37f21788f Columns: Made GetColumnOffset() and GetColumnWidth() behave when there's no column set, consistently with other column functions + fixed Columns demo (#2683) 5 years ago
omar b443bc0a64 Columns: Improved honoring alignment with various values of ItemSpacing.x and WindowPadding.x. (#125, #2666) 5 years ago
omar 4abc2a82e0 Columns: Made the right-most edge reaches up to the clipping rectangle (removing WindowPadding.x*0.5 worth of asymmetrical/extraneous padding). (#125, #2666)
+ Moved a few things in BeginColumns().
5 years ago
omar 44336950e9 Revert "Columns: Improved honoring left-most and right-most alignment with various values of ItemSpacing.x and WindowPadding.x. In particular, the right-most edge now reaches up to the clipping rectangle while ensuring that the right-most column clipping width matches others. (#125, #2666)"
This reverts commit 6c16ba6490.
5 years ago
omar 6c16ba6490 Columns: Improved honoring left-most and right-most alignment with various values of ItemSpacing.x and WindowPadding.x. In particular, the right-most edge now reaches up to the clipping rectangle while ensuring that the right-most column clipping width matches others. (#125, #2666) 5 years ago
omar e28d20c3e2 Columns: Fixed a regression from 1.71 where the right-side of the contents rectangle within each column would wrongly use a WindowPadding.x instead of ItemSpacing.x like it always did. (#125, #2666) 5 years ago
omar 61c7f0194e Misc: Made Button(), ColorButton() not trigger an "edited" event leading to IsItemDeactivatedAfterEdit() returning true. This also effectively make ColorEdit4() not incorrect trigger IsItemDeactivatedAfterEdit() when clicking the color button to open the picker popup. (#1875)
Demo: Added Button with repeater and InputFloat with +/- button to the status query test demo.
5 years ago
omar ea79992d9a Fixed old SetWindowFontScale() api value from not being inherited by child window. Added comments about the right way to scale your UI (load a font at the right side, rebuild atlas, scale style).
+ Added missing IMGUI_API marker to the EmptyString storage used by ImGuiTextBuffer. (#2672)
5 years ago
omar 130b44994e Debug, Metrics: Added "Tools->Item Picker" tool which allow clicking on a widget to break in the debugger within the item code. The tool calls IM_DEBUG_BREAK() which can be redefined in imconfig.h if needed. 5 years ago
omar e6a286b3a5 Style: Added style.ColorButtonButton (left/right, defaults to ImGuiDir_Right) to move the color button of ColorEdit3/ColorEdit4 functions to either side of the inputs. 5 years ago
omar a35f42f123 Removed TreeAdvanceToLabelPos() which is rarely used and only does SetCursorPosX(GetCursorPosX() + GetTreeNodeToLabelSpacing()). Kept redirection function (will obsolete). (#581, #324) 5 years ago
omar 3d07c7cbe4 TabBar: Fixed unfocused tab bar separator color (was using ImGuiCol_Tab, should use ImGuiCol_TabUnfocusedActive). 5 years ago
omar 7a9d32acee Fixed unnecessary test in UpdateMouseWheel() (thanks PVS).
TreeNodeBehavior: avoid computing bg_col for non-framed non-active tree nodes.
Comments, binaries update, minor typos.
5 years ago
omar d52c6316c8 Renamed ImFontAtlas::CustomRect to ImFontAtlasCustomRect. Keep redirection typedef (will obsolete). 5 years ago
omar 3436132d4b Combo: Hide arrow when there's not enough space even for the square button.
+ Various todo items.
5 years ago
omar d23f1b1409 fonts/binary_to_compress: display error message when failing to open file + misc comments. 5 years ago
omar 54c49b5fb1 Window: Mouse wheel scrolling while hovering a child window is automatically forwarded to parent window if ScrollMax is zero on the scrolling axis. Also still case if ImGuiWindowFlags_NoScrollWithMouse is set (not new), but previously the forwarding
would be disabled if ImGuiWindowFlags_NoScrollbar was set on the child window, which is not the case any more (amend #1502, #1380).
5 years ago
omar e16564e67a Scrollbar: Avoid overlapping the opposite side when window (often a child window) is forcibly too small. 5 years ago
omar 58c9f8a194 Misc: Added IMGUI_DISABLE_METRICS_WINDOW imconfig.h setting to explicitly compile out ShowMetricsWindow(). + Internals: Minor renaming. 5 years ago
omar da29d77253 Added SetScrollXHere, SetScrollFromPosX: Changelog, demo, comments (#1580). 5 years ago
omar 1dd322c6fb Style: Attenuated default opacity of ImGuiCol_Separator in Classic and Light styles. 5 years ago
omar 41e2d4b5ae ImDrawListSplitter: Fixed memory leak when using low-level split api (was not affecting ImDrawList api, also this type was added in 1.71 and not advertised as a public-facing feature). 5 years ago
omar dd41df3e98 Word-wrapping: Fixed overzealous word-wrapping when glyph edge lands exactly on the limit. Because of this, auto-fitting exactly unwrapped text would make it wrap. (fixes initial 1.15 commit, 78645a7d). 5 years ago
omar 516c3dee80 Examples: SDL+DX11: Changelog, readme, batch files, fixed vcxproj, minor stylistic fixes + minor sync of other main.cpp files. (#2632) 5 years ago
omar 70fe409338 Window: Fixed InnerClipRect right-most coordinates using wrong padding setting (introduced in 1.71). 5 years ago
omar b82e99c032 ImDrawList: Fixed CloneOutput() helper crashing. Also removed unnecessary risk from ImDrawList::Clear(), draw lists are being clear before use each frame anyway. (#1860) 5 years ago
omar 2645a2516f ImDrawList::ChannelsSplit(), ImDrawListSlitter: Fixed an issue with merging draw commands between channels 0 and 1. (#2624) Introduced by cef88f6aae. 5 years ago
omar af3080b81b Removed redirecting functions/enums that were obsoleted in version 1.51 (June 2017): ImGuiCol_Column*, ImGuiSetCond_*, IsItemHoveredRect(), IsPosHoveringAnyWindow(), IsMouseHoveringAnyWindow(), IsMouseHoveringWindow(), IMGUI_ONCE_UPON_A_FRAME. 5 years ago
omar 5286ecb8a7 Version 1.72 WIP 5 years ago
omar 2da1c66d15 Version 1.71 + comments 5 years ago
omar a8eb64fc54 Log/Capture: Fixed BeginTabItem() label not being included in a text log/capture.
Extracted tab rendering code into a RenderTextEllipsis() function.
5 years ago
omar 0770449630 Window: child windows outer decorations (e.g. scrollbar) are rendered as part of their parent window, avoiding the creation of an extraneous draw command.
+ Metrics: inverted color of clip rect vs vertices bounding box when hovering a draw command, so the color matches the per-vertex preview.
5 years ago
omar fea5f70611 ImDrawCallback: Allow to override the signature of ImDrawCallback by #define-ing it. This is meant to facilitate custom rendering back-ends passing local render-specific data to the draw callback. 5 years ago
omar 480d57e6a2 Revert "Changed syntax for (very rarely used) IMGUI_OVERRIDE_DRAWVERT_STRUCT_LAYOUT mechanism, instead you only need to '#define ImDrawVert MyDrawVert' to use this feature, avoiding the need to declare the entire structure within an awkward macro. Using the old macro will now error with a message pointing you to the new method. (#38, #103, #1172, #1231, #2489)"
This reverts commit 597c024904.
5 years ago
omar 597c024904 Changed syntax for (very rarely used) IMGUI_OVERRIDE_DRAWVERT_STRUCT_LAYOUT mechanism, instead you only need to '#define ImDrawVert MyDrawVert' to use this feature, avoiding the need to declare the entire structure within an awkward macro. Using the old macro will now error with a message pointing you to the new method. (#38, #103, #1172, #1231, #2489) 5 years ago
omar c96f2c4057 Window: Fixed one case where auto-resize by double-clicking the resize grip would make either scrollbar appear for a single frame after the resize. Moved Scrollbar visibility block. 5 years ago
omar c1a61d25a7 Scrollbar overlap an extra WindowBorderSize amount on the left to make all distances consistent. Reverted to BorderSize not affecting work/contents rectangles. Scrollbar, Style: Changed default style.ScrollbarSize from 16 to 14. 5 years ago
omar 4149d22e85 Fixed newly created window (e.g. appearing child window) from having scrollbar active on the first frame. (fix 6e03b27) + reworded code a little. (+1 squashed commits)
Fixed auto-resize with AlwaysVerticalScrollbar or AlwaysHorizontalScrollbar flags not taking account of the expect scrollbar sizes.
5 years ago
omar f95c77eeea Window rectangles: Changed WorkRect to cover the whole region including scrolling (toward obsolete ContentsRegionRect) + using full WindowPadding*1 padding.
Tweaked InnerClipRect.
TreeNode, CollapsingHeader: Fixed highlight frame not covering horizontal area fully when using horizontal scrolling. (#2211, #2579)
TabBar: Fixed BeginTabBar() within a window with horizontal scrolling from creating a feedback loop with the horizontal contents size.
Columns: Fixed Columns() within a window with horizontal scrolling from not covering the full horizontal area (previously only worked with an explicit contents size). (#125)
Demo: Added demo code to test contentsrect/workrect
5 years ago
omar a0994d74c2 Clarified behavior of SetNextWindowContentSize(). Content size is defined as the size available after removal of WindowPadding on each sides. So SetNextWindowContentSize(ImVec2(100,100)) + auto-resize will always allow submitting a 100x100 item without creating a scrollbar, regarding of WindowPadding.The exact meaning of ContentSize for decorated windows was previously ill-defined. 5 years ago
omar 57d8ab62f4 Nav: Fixed rare crash when e.g. releasing Alt-key while focusing a window with a menu at the same frame as clearing the focus. This was in most noticeable in some back-ends with emits key release events when focusing another viewport. (#2609) 5 years ago
DucaRii 6614bab883 Combo: Fixed rounding not applying with the ImGuiComboFlags_NoArrowButton flag. (#2606, #2607) 5 years ago
omar eb7849b477 Nav: Fixed gamepad/keyboard moving of window affecting contents size incorrectly, sometimes leading to scrollbars appearing during the movement. + minor fix with the mostly dead Ctrl+wheel scaling. 5 years ago
Max Thrun ed79b4d22e Examples/Backends: Metal: Added support for large meshes (64k+ vertices) with 16-bits indices, enable 'ImGuiBackendFlags_HasVtxOffset' config flag in back-end. (#2591, #2592) 5 years ago
omar 7755cbbef2 Renamed ImGuiBackendFlags_HasVtxOffset to ImGuiBackendFlags_RendererHasVtxOffset to match naming convention already used in viewport/docking branch. (#2591) + Fix OpenGL3 code missing flag. 5 years ago