Commit Graph

1767 Commits

Author SHA1 Message Date
ocornut
8567a4cca3 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_glfw.cpp
#	backends/imgui_impl_sdl.cpp
#	backends/imgui_impl_win32.cpp
#	imgui_demo.cpp
#	imgui_internal.h
2022-01-17 18:19:20 +01:00
ocornut
90a6961638 IO: apply same flooring as UpdateMouseInputs() in dupe event processing. (#4858) + provision for test engine. 2022-01-17 18:10:51 +01:00
ocornut
7374b96f5c IO: Added input queue. (#4858, #2787, #1992, #3383, #2525, #1320) 2022-01-17 17:36:55 +01:00
ocornut
eb823655af Removed support for pre-C++11 compilers. We'll stop supporting VS2010. (#4537)
Build all
2022-01-17 11:54:11 +01:00
ocornut
0647ba3bad Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_glfw.cpp
#	backends/imgui_impl_osx.h
#	backends/imgui_impl_osx.mm
#	backends/imgui_impl_sdl.cpp
#	backends/imgui_impl_win32.cpp
2022-01-13 18:36:23 +01:00
ocornut
290c51735e Fixed warning in ImFloorSigned(). (#4889) 2022-01-12 14:18:34 +01:00
ocornut
956e03009a Backends: OSX: Build fIx. Made GetKeyName() input tolerant. Internals: added GetNavInputName(). 2022-01-11 18:48:16 +01:00
ocornut
ef681e7019 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_glfw.cpp
#	backends/imgui_impl_glfw.h
#	backends/imgui_impl_osx.h
#	backends/imgui_impl_osx.mm
#	backends/imgui_impl_sdl.cpp
#	backends/imgui_impl_sdl.h
#	backends/imgui_impl_win32.cpp
#	backends/imgui_impl_win32.h
#	imgui.cpp
2022-01-10 15:24:21 +01:00
ocornut
bf08c13e9b Inputs: Extra Keys / AddKeyEvent(): bidirectional mapping, basic CI, simplify backends, asserts on misuses, tested backward compat. (#2625, #4858, #2787)
(edit: simplified backends merged into previous commits to make history clearer)
2022-01-10 15:09:56 +01:00
thedmd
3b66929301 Inputs: Extra Keys / AddKeyEvent(): Added ImGuiKey values, io.AddKeyEvent(), GetKeyName(), IMGUI_DISABLE_OBSOLETE_KEYIO. Obsoleted GetKeyIndex(), io.KeyMap[], io.KeysDown[]. (#2625, #4858, #2787) 2022-01-10 15:09:56 +01:00
ocornut
704ab1114a Merge branch 'master' into docking. Remove Platform_SetImeInputPos. Remove backend-side IME implementation. Rrevert removal of MouseDragMaxDistanceAbs in 206b9ea. (#2589, #3113)
# Conflicts:
#	backends/imgui_impl_glfw.cpp
#	backends/imgui_impl_sdl.cpp
#	backends/imgui_impl_win32.cpp
#	imgui.cpp
#	imgui.h
#	imgui_internal.h
#	imgui_widgets.cpp
2022-01-05 14:30:20 +01:00
ocornut
2706c9d66e Platform IME: reworked internals to simplify adding new features. 2022-01-05 13:47:20 +01:00
ocornut
9c8f288d1a Viewports: Fixed a CTRL+TAB crash with viewports enabled (#4023, #787) (amend 1dc3af3, 23ef6c1, 657073a)
+ Expose FindHoveredViewportFromPlatformWindowStack() in imgui_internal.h
2021-12-30 21:46:09 +01:00
ocornut
2aa9959553 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_glfw.cpp
#	backends/imgui_impl_opengl3.cpp
#	docs/CHANGELOG.txt
2021-12-30 21:42:19 +01:00
ocornut
89a28209e8 Version 1.87 WIP + Backends: OpenGL3: Fixed a buffer overflow in imgui_impl_opengl3_loader.h init, added in 1.86 (#4468, #4830) 2021-12-26 20:02:02 +01:00
ocornut
980deb4c9e Add missing include guard to avoid declaring ImFontAtlasGetBuilderForStbTruetype() function.
https://github.com/cimgui/cimgui/issues/193
https://github.com/imgui-rs/imgui-rs/pull/582
2021-12-26 19:51:10 +01:00
ocornut
15b4a064f9 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_win32.cpp
#	examples/example_marmalade/main.cpp
#	imgui.cpp
#	imgui.h
2021-12-22 16:02:04 +01:00
ocornut
512c54bbc0 Version 1.86 2021-12-22 15:31:13 +01:00
ocornut
248ed1b01d Internals: UpdateWindowInFocusOrderList: amend a528398 to fix docking. (#3496, #4797) 2021-12-15 14:28:10 +01:00
ocornut
1c4066cd9e Internals: UpdateWindowInFocusOrderList: amend a528398 to fix docking. (#3496, #4797) 2021-12-15 14:27:56 +01:00
ocornut
cd36acc88b Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_opengl3.cpp
#	backends/imgui_impl_osx.h
#	backends/imgui_impl_osx.mm
#	imgui.cpp
2021-12-15 12:10:03 +01:00
ocornut
11638fdf7d Menus: reuse more menu windows when stacked over popups.
This is actually mostly aimed at ensuring the _ChildWindow flag on menu window doesn't vary as this would cause issues with our current g.WindowsFocusOrder[] scheme
2021-12-13 19:35:16 +01:00
ocornut
e31d116d37 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_opengl2.cpp
#	imgui.cpp
#	imgui_internal.h
2021-12-09 11:52:23 +01:00
Rokas Kupstys
b38af0f522 Popups: Fix popups being closed by newly appearing windows. (#4317)
* Popups/modals now remain open when new windows are created from within popup/modal begin stack.
* Modals are not closed when new window appears behind active modal.
Tested by "window_popup_interruptions"
2021-12-07 15:52:13 +01:00
ocornut
c1b70e0391 Merge branch 'master' into docking
# Conflicts:
#	imgui.cpp
2021-12-06 19:17:03 +01:00
ocornut
027a7ba3eb Clipper: use line size instead of cursor comparaison when range are large. (#3609, #3962 + https://github.com/ocornut/imgui_club/issues/20) 2021-12-06 17:17:43 +01:00
ocornut
a76bc52da5 Window, Clipper: store initial precision loss and apply in clipper. (#3609, #3962 + https://github.com/ocornut/imgui_club/issues/20) 2021-12-06 16:19:47 +01:00
ocornut
6e141a9cae Internals: made ScrollbarEx() use ImS64 to facilitate use with larger ranges (not fully tested) + clipper tweaks (#3609, #3962 + https://github.com/ocornut/imgui_club/issues/20)
This does NOT fix all problems with large ranges and floating point precision, it merely attenuate them.
2021-12-06 12:09:38 +01:00
ocornut
23ef6c149e Reworked modal/ctrl+tab dimming system to be entirely processed at end of the frame (backported 1dc3af3 from docking) 2021-12-03 19:21:39 +01:00
ocornut
1dc3af381a Nav, Docking: reworked modal/ctrl+tab dimming system to be entirely processed at end of the frame, which will simplify things for an upcoming commit.
(Will backport some of this back to master now.)
2021-12-03 19:18:57 +01:00
ocornut
da3a36eefd Backport from docking branch: minor stuff.
Fixed software mouse cursor being rendered multiple times if Render() is called more than once.
2021-12-03 19:11:58 +01:00
ocornut
b16f738d04 Docking: docked windows honor ImGuiCol_WindowBg. Host window in charge of rendering seams. (#2700, #2539 + Docked windows honor display their border properly. (#2522)
Plus: better support for transparent one in nodes
Side effects: DockContextBindNodeToWindow doesn't alter node->IsVisible.
Side effects: ImDrawList:: _ResetForNewFrame() needs to merge, sane (in case of
(Amended, force-pushed)
2021-12-03 14:46:34 +01:00
ocornut
bf80204e63 Docking: internals: extracted rounding corner calculation into reusable CalcRoundingFlagsForRectInRect() function. 2021-12-02 20:22:03 +01:00
ocornut
8733ca49b0 Docking: Fixed single-frame node pos/size inconsistencies when window stop or start being submitted.
Fix 718e15c7d while preserving its intended property. Tested by "docking_window_appearing_layout". (#2109)
2021-12-02 18:46:42 +01:00
ocornut
848d21b6b5 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_sdlrenderer.cpp
#	backends/imgui_impl_sdlrenderer.h
#	imgui.cpp
#	imgui_widgets.cpp
2021-12-01 15:37:40 +01:00
ocornut
f087a5b856 Metrics: Added a node showing windows in submission order and showing the Begin() stack. 2021-11-30 16:04:19 +01:00
ocornut
9d704d99d3 Internals: wrapped ImQsort() in an inline function + added a define guard. 2021-11-30 12:59:00 +01:00
averne
cb5c73f64a
Fix: IM_DEBUG_BREAK macro on ARM GCC (#4767) 2021-11-29 00:05:57 +01:00
ocornut
65f4be1a10 InputText: Internals: moved "apply_new_text" application code to reduce noise in a future commit (will be for #4714) + removed unused fields.
The move would ideally be no-op. technically we now clear state->Flags before calling ResizeCallback but those are unrelated. The 2 unused fields were incorrectly added by 24ff25981.
2021-11-25 15:12:23 +01:00
Rokas Kupstys
4d9a3b19d5 Internals: Implement a continuable IM_DEBUG_BREAK on GCC for common archs. (#2673) 2021-11-22 12:35:07 +01:00
ocornut
f8a806ad9f Tooltips, Internal: (Breaking) swapped parameter order to accomodate for future tooltip api rework. 2021-11-10 17:53:58 +01:00
ocornut
dc8c3618e8 Merge branch 'master' into docking
# Conflicts:
#	imgui_demo.cpp
2021-11-10 15:26:03 +01:00
ocornut
eb02dcf87f Nav: enable move/resize window with keyboard in Ctrl+Tabbing windowing menu even without _NavEnableKeyboard. (#4023, #787). 2021-11-08 18:42:07 +01:00
ocornut
b17dffffb3 Merge branch 'master' into docking
# Conflicts:
#	imgui.cpp
2021-11-04 20:52:54 +01:00
ocornut
1a7526dcd4 Nav, Tabbing: refactor tabbing system to support clipped items, scrolling, using nav queries. (#4449)
Not using counter/modulo anymore and special provisions to handle tab wrapping with ImGuiListClipper. Wrapping may be done better as a next-frame forwarded request.
Also one extra step toward #3949 #3985
2021-11-04 20:48:12 +01:00
ocornut
c1d2793580 Merge branch 'master' into docking
# Conflicts:
#	imgui.cpp
2021-11-04 15:26:01 +01:00
ocornut
93cccd27f6 Clipper: bunch of rework. (#3841, #1725)
- Focused/NavId now always included in display range.
- Any number of steps (while preserving zero-alloc policy).
- Non contiguous ranges for nav processing
- Moved new fields internally (+ moved StepNo away from sight so it doesn't get missused).
- Generally tweaks/refactors.
2021-11-04 14:05:14 +01:00
ocornut
0b4edf4e94 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_vulkan.cpp
#	imgui.cpp
2021-11-03 11:51:37 +01:00
ocornut
a67f7dce31 Nav: relative rectangle positions are now stored relative to CursorStartPos to be independent of scrolling. Will facilitate rework of clipper (#3841)
+ Extracted code into NavUpdateCreateWrappingRequest()
+ Fix for PVS in NavUpdate() assigning g.NavMousePosDirty twice.
2021-10-27 14:18:03 +02:00
ocornut
8361ed1f54 Nav: wrap abs<>rel rectangle conversions before we attempt to switch the reference point from window->Pos to window->DC.CursorStartPos. This commit should have no effect.
Current point makes rectangle invalid right after a scroll, for interactive actions it's rarely a problem but e.g. clipper will want to use g.NavID rect rel while scrolling. (#3841)
2021-10-27 12:28:45 +02:00