imgui-bindings 0.1.9 → 0.1.11

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 58148b6f5cf2fac39a54bfd25eff1d9451087998eb8e29ed1270cddbb8ceed53
4
- data.tar.gz: 37b074d46eb3f433aec1c4470df6864dbdbb74ddaf7df02b3445fabecf8c6eb3
3
+ metadata.gz: 2f4ab82ec1b7b3864037f67ece6ac3a0030142feb80b76a4dad18796b482563a
4
+ data.tar.gz: 1b90387f2ee8740f3189a1c45f1ef11400cd9ce71d62df47c3c533d5c7176985
5
5
  SHA512:
6
- metadata.gz: 7302ec520742ca2e5274325115bc4c492a03f85c50ad81dcc79033c7523c559cf74c28916361a62a59f0271d1734e4d7ccd25a178f3f49799e68f52aafc23186
7
- data.tar.gz: 85aa8ea965f385ba6b2176b270543f8d77ddb2ff35929cda26217fd25e8ac0b920cda2bc86e905035900023ff92c921f454d959b7a95a13fd8338b63e25dbf6a
6
+ metadata.gz: 5253284c99162d8def4fdfa281e2cbb8c9093860470cb9ecd8f748950ee2fd82e80e21374e7cc2f2887458845c7631b6df47144b1b08c2ea998bf1da4981f50d
7
+ data.tar.gz: 64763edd313a24856c05de4fe0fd5953f48175faeb5a6a4bf9ed64a2e59360be231ce06a9467f26ca64551c6000e03de00fc21ddb5225c4edd554dd8dbac0ae8
data/ChangeLog CHANGED
@@ -1,3 +1,15 @@
1
+ 2024-02-25 vaiorabbit <http://twitter.com/vaiorabbit>
2
+
3
+ * ImGui v1.90.4
4
+
5
+ 2024-01-12 vaiorabbit <http://twitter.com/vaiorabbit>
6
+
7
+ * ImGui v1.90.1
8
+
9
+ 2023-12-10 vaiorabbit <http://twitter.com/vaiorabbit>
10
+
11
+ * macOS : Generate libraries for each platform
12
+
1
13
  2023-11-19 vaiorabbit <http://twitter.com/vaiorabbit>
2
14
 
3
15
  * ImGui v1.90.0
data/LICENSE.txt CHANGED
@@ -1,5 +1,5 @@
1
1
  Ruby-ImGui : Yet another ImGui wrapper for Ruby
2
- Copyright (c) 2019-2023 vaiorabbit <http://twitter.com/vaiorabbit>
2
+ Copyright (c) 2019-2024 vaiorabbit <http://twitter.com/vaiorabbit>
3
3
 
4
4
  This software is provided 'as-is', without any express or implied
5
5
  warranty. In no event will the authors be held liable for any damages
data/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  # Yet another ImGui wrapper for Ruby #
4
4
 
5
5
  * Created : 2019-01-05
6
- * Last modified : 2023-11-19
6
+ * Last modified : 2024-02-25
7
7
 
8
8
  <img src="https://raw.githubusercontent.com/vaiorabbit/ruby-imgui/master/doc/jpfont_test.png" width="250">
9
9
 
@@ -16,7 +16,7 @@
16
16
  * [Windows] https://rubyinstaller.org/downloads/ Ruby+Devkit
17
17
  * ruby 3.2.0 (2022-12-25 revision a528908271) [x64-mingw-ucrt]
18
18
  * [macOS]
19
- * ruby 3.2.1 (2023-02-08 revision 31819e82c8) [arm64-darwin22]
19
+ * ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [arm64-darwin23]
20
20
  * [Linux]
21
21
  * ruby 3.2.0 (2022-12-25 revision a528908271) [aarch64-linux]
22
22
  * Ruby Gems
@@ -42,6 +42,7 @@
42
42
  * ruby 3.0.0p0 (2020-12-25 revision 95aff21468) [x64-mingw32]
43
43
  * ruby 2.7.1p83 (2020-03-31 revision a0c7c23c9c) [x64-mingw32]
44
44
  * [macOS]
45
+ * ruby 3.2.1 (2023-02-08 revision 31819e82c8) [arm64-darwin22]
45
46
  * ruby 3.2.0 (2022-12-25 revision a528908271) [arm64-darwin21]
46
47
  * ruby 3.1.2p20 (2022-04-12 revision 4491bb740a) [arm64-darwin21]
47
48
  * ruby 3.1.2p20 (2022-04-12 revision 4491bb740a) [arm64-darwin21]
@@ -95,7 +96,7 @@ All ruby codes here are available under the terms of the zlib/libpng License ( h
95
96
 
96
97
  ```
97
98
  Ruby-Imgui : Yet another ImGui wrapper for Ruby
98
- Copyright (c) 2019-2023 vaiorabbit <http://twitter.com/vaiorabbit>
99
+ Copyright (c) 2019-2024 vaiorabbit <http://twitter.com/vaiorabbit>
99
100
 
100
101
  This software is provided 'as-is', without any express or implied
101
102
  warranty. In no event will the authors be held liable for any damages
data/lib/imgui.aarch64.so CHANGED
Binary file
Binary file
data/lib/imgui.dll CHANGED
Binary file
data/lib/imgui.rb CHANGED
@@ -113,7 +113,7 @@ ImGuiButtonFlags_MouseButtonDefault_ = 1 # ImGuiButtonFlags_MouseButtonLeft
113
113
 
114
114
  # ImGuiChildFlags_
115
115
  # Flags for ImGui::BeginChild()
116
- # (Legacy: bot 0 must always correspond to ImGuiChildFlags_Border to be backward compatible with old API using 'bool border = false'.
116
+ # (Legacy: bit 0 must always correspond to ImGuiChildFlags_Border to be backward compatible with old API using 'bool border = false'.
117
117
  # About using AutoResizeX/AutoResizeY flags:
118
118
  # - May be combined with SetNextWindowSizeConstraints() to set a min/max size for each axis (see "Demo->Child->Auto-resize with Constraints").
119
119
  # - Size measurement for a given axis is only performed when the child window is within visible boundaries, or is just appearing.
@@ -122,7 +122,7 @@ ImGuiButtonFlags_MouseButtonDefault_ = 1 # ImGuiButtonFlags_MouseButtonLeft
122
122
  # - You may also use ImGuiChildFlags_AlwaysAutoResize to force an update even when child window is not in view.
123
123
  # HOWEVER PLEASE UNDERSTAND THAT DOING SO WILL PREVENT BeginChild() FROM EVER RETURNING FALSE, disabling benefits of coarse clipping.
124
124
  ImGuiChildFlags_None = 0 # 0
125
- ImGuiChildFlags_Border = 1 # 1 << 0 # Show an outer border and enable WindowPadding. (Important: this is always == 1 == true for legacy reason)
125
+ ImGuiChildFlags_Border = 1 # 1 << 0 # Show an outer border and enable WindowPadding. (IMPORTANT: this is always == 1 == true for legacy reason)
126
126
  ImGuiChildFlags_AlwaysUseWindowPadding = 2 # 1 << 1 # Pad with style.WindowPadding even if no border are drawn (no padding by default for non-bordered child windows because it makes more sense)
127
127
  ImGuiChildFlags_ResizeX = 4 # 1 << 2 # Allow resize from right border (layout direction). Enable .ini saving (unless ImGuiWindowFlags_NoSavedSettings passed to window flags)
128
128
  ImGuiChildFlags_ResizeY = 8 # 1 << 3 # Allow resize from bottom border (layout direction). "
@@ -143,15 +143,15 @@ ImGuiCol_BorderShadow = 6 # 6
143
143
  ImGuiCol_FrameBg = 7 # 7 # Background of checkbox, radio button, plot, slider, text input
144
144
  ImGuiCol_FrameBgHovered = 8 # 8
145
145
  ImGuiCol_FrameBgActive = 9 # 9
146
- ImGuiCol_TitleBg = 10 # 10
147
- ImGuiCol_TitleBgActive = 11 # 11
148
- ImGuiCol_TitleBgCollapsed = 12 # 12
146
+ ImGuiCol_TitleBg = 10 # 10 # Title bar
147
+ ImGuiCol_TitleBgActive = 11 # 11 # Title bar when focused
148
+ ImGuiCol_TitleBgCollapsed = 12 # 12 # Title bar when collapsed
149
149
  ImGuiCol_MenuBarBg = 13 # 13
150
150
  ImGuiCol_ScrollbarBg = 14 # 14
151
151
  ImGuiCol_ScrollbarGrab = 15 # 15
152
152
  ImGuiCol_ScrollbarGrabHovered = 16 # 16
153
153
  ImGuiCol_ScrollbarGrabActive = 17 # 17
154
- ImGuiCol_CheckMark = 18 # 18
154
+ ImGuiCol_CheckMark = 18 # 18 # Checkbox tick and RadioButton circle
155
155
  ImGuiCol_SliderGrab = 19 # 19
156
156
  ImGuiCol_SliderGrabActive = 20 # 20
157
157
  ImGuiCol_Button = 21 # 21
@@ -234,7 +234,7 @@ ImGuiComboFlags_WidthFitPreview = 128 # 1 << 7 # Width dynamically calculated fr
234
234
  ImGuiComboFlags_HeightMask_ = 30 # ImGuiComboFlags_HeightSmall | ImGuiComboFlags_HeightRegular | ImGuiComboFlags_HeightLarge | ImGuiComboFlags_HeightLargest
235
235
 
236
236
  # ImGuiCond_
237
- # Enumeration for ImGui::SetWindow***(), SetNextWindow***(), SetNextItem***() functions
237
+ # Enumeration for ImGui::SetNextWindow***(), SetWindow***(), SetNextItem***() functions
238
238
  # Represent a condition.
239
239
  # Important: Treat as a regular enum! Do NOT combine multiple values using binary operators! All the functions above treat 0 as a shortcut to ImGuiCond_Always.
240
240
  ImGuiCond_None = 0 # 0 # No condition (always set the variable), same as _Always
@@ -358,6 +358,7 @@ ImGuiInputTextFlags_EscapeClearsAll = 1048576 # 1 << 20 # Escape key clears con
358
358
  # Since >= 1.89 we increased typing (went from int to enum), some legacy code may need a cast to ImGuiKey.
359
359
  # Read details about the 1.87 and 1.89 transition : https://github.com/ocornut/imgui/issues/4921
360
360
  # Note that "Keys" related to physical keys and are not the same concept as input "Characters", the later are submitted via io.AddInputCharacter().
361
+ # The keyboard key enum values are named after the keys on a standard US keyboard, and on other keyboard types the keys reported may not match the keycaps.
361
362
  ImGuiKey_None = 0 # 0
362
363
  ImGuiKey_Tab = 512 # 512 # == ImGuiKey_NamedKey_BEGIN
363
364
  ImGuiKey_LeftArrow = 513 # 513
@@ -562,24 +563,25 @@ ImGuiMouseSource_COUNT = 3 # 3
562
563
 
563
564
  # ImGuiPopupFlags_
564
565
  # Flags for OpenPopup*(), BeginPopupContext*(), IsPopupOpen() functions.
565
- # - To be backward compatible with older API which took an 'int mouse_button = 1' argument, we need to treat
566
- # small flags values as a mouse button index, so we encode the mouse button in the first few bits of the flags.
566
+ # - To be backward compatible with older API which took an 'int mouse_button = 1' argument instead of 'ImGuiPopupFlags flags',
567
+ # we need to treat small flags values as a mouse button index, so we encode the mouse button in the first few bits of the flags.
567
568
  # It is therefore guaranteed to be legal to pass a mouse button index in ImGuiPopupFlags.
568
569
  # - For the same reason, we exceptionally default the ImGuiPopupFlags argument of BeginPopupContextXXX functions to 1 instead of 0.
569
570
  # IMPORTANT: because the default parameter is 1 (==ImGuiPopupFlags_MouseButtonRight), if you rely on the default parameter
570
571
  # and want to use another flag, you need to pass in the ImGuiPopupFlags_MouseButtonRight flag explicitly.
571
572
  # - Multiple buttons currently cannot be combined/or-ed in those functions (we could allow it later).
572
- ImGuiPopupFlags_None = 0 # 0
573
- ImGuiPopupFlags_MouseButtonLeft = 0 # 0 # For BeginPopupContext*(): open on Left Mouse release. Guaranteed to always be == 0 (same as ImGuiMouseButton_Left)
574
- ImGuiPopupFlags_MouseButtonRight = 1 # 1 # For BeginPopupContext*(): open on Right Mouse release. Guaranteed to always be == 1 (same as ImGuiMouseButton_Right)
575
- ImGuiPopupFlags_MouseButtonMiddle = 2 # 2 # For BeginPopupContext*(): open on Middle Mouse release. Guaranteed to always be == 2 (same as ImGuiMouseButton_Middle)
576
- ImGuiPopupFlags_MouseButtonMask_ = 31 # 0x1F
577
- ImGuiPopupFlags_MouseButtonDefault_ = 1 # 1
578
- ImGuiPopupFlags_NoOpenOverExistingPopup = 32 # 1 << 5 # For OpenPopup*(), BeginPopupContext*(): don't open if there's already a popup at the same level of the popup stack
579
- ImGuiPopupFlags_NoOpenOverItems = 64 # 1 << 6 # For BeginPopupContextWindow(): don't return true when hovering items, only when hovering empty space
580
- ImGuiPopupFlags_AnyPopupId = 128 # 1 << 7 # For IsPopupOpen(): ignore the ImGuiID parameter and test for any popup.
581
- ImGuiPopupFlags_AnyPopupLevel = 256 # 1 << 8 # For IsPopupOpen(): search/test at any level of the popup stack (default test in the current level)
582
- ImGuiPopupFlags_AnyPopup = 384 # ImGuiPopupFlags_AnyPopupId | ImGuiPopupFlags_AnyPopupLevel
573
+ ImGuiPopupFlags_None = 0 # 0
574
+ ImGuiPopupFlags_MouseButtonLeft = 0 # 0 # For BeginPopupContext*(): open on Left Mouse release. Guaranteed to always be == 0 (same as ImGuiMouseButton_Left)
575
+ ImGuiPopupFlags_MouseButtonRight = 1 # 1 # For BeginPopupContext*(): open on Right Mouse release. Guaranteed to always be == 1 (same as ImGuiMouseButton_Right)
576
+ ImGuiPopupFlags_MouseButtonMiddle = 2 # 2 # For BeginPopupContext*(): open on Middle Mouse release. Guaranteed to always be == 2 (same as ImGuiMouseButton_Middle)
577
+ ImGuiPopupFlags_MouseButtonMask_ = 31 # 0x1F
578
+ ImGuiPopupFlags_MouseButtonDefault_ = 1 # 1
579
+ ImGuiPopupFlags_NoReopen = 32 # 1 << 5 # For OpenPopup*(), BeginPopupContext*(): don't reopen same popup if already open (won't reposition, won't reinitialize navigation)
580
+ ImGuiPopupFlags_NoOpenOverExistingPopup = 128 # 1 << 7 # For OpenPopup*(), BeginPopupContext*(): don't open if there's already a popup at the same level of the popup stack
581
+ ImGuiPopupFlags_NoOpenOverItems = 256 # 1 << 8 # For BeginPopupContextWindow(): don't return true when hovering items, only when hovering empty space
582
+ ImGuiPopupFlags_AnyPopupId = 1024 # 1 << 10 # For IsPopupOpen(): ignore the ImGuiID parameter and test for any popup.
583
+ ImGuiPopupFlags_AnyPopupLevel = 2048 # 1 << 11 # For IsPopupOpen(): search/test at any level of the popup stack (default test in the current level)
584
+ ImGuiPopupFlags_AnyPopup = 3072 # ImGuiPopupFlags_AnyPopupId | ImGuiPopupFlags_AnyPopupLevel
583
585
 
584
586
  # ImGuiSelectableFlags_
585
587
  # Flags for ImGui::Selectable()
@@ -652,7 +654,7 @@ ImGuiTabBarFlags_None = 0 # 0
652
654
  ImGuiTabBarFlags_Reorderable = 1 # 1 << 0 # Allow manually dragging tabs to re-order them + New tabs are appended at the end of list
653
655
  ImGuiTabBarFlags_AutoSelectNewTabs = 2 # 1 << 1 # Automatically select new tabs when they appear
654
656
  ImGuiTabBarFlags_TabListPopupButton = 4 # 1 << 2 # Disable buttons to open the tab list popup
655
- ImGuiTabBarFlags_NoCloseWithMiddleMouseButton = 8 # 1 << 3 # Disable behavior of closing tabs (that are submitted with p_open != NULL) with middle mouse button. You can still repro this behavior on user's side with if (IsItemHovered() && IsMouseClicked(2)) *p_open = false.
657
+ ImGuiTabBarFlags_NoCloseWithMiddleMouseButton = 8 # 1 << 3 # Disable behavior of closing tabs (that are submitted with p_open != NULL) with middle mouse button. You may handle this behavior manually on user's side with if (IsItemHovered() && IsMouseClicked(2)) *p_open = false.
656
658
  ImGuiTabBarFlags_NoTabListScrollingButtons = 16 # 1 << 4 # Disable scrolling buttons (apply when fitting policy is ImGuiTabBarFlags_FittingPolicyScroll)
657
659
  ImGuiTabBarFlags_NoTooltip = 32 # 1 << 5 # Disable tooltips when hovering a tab
658
660
  ImGuiTabBarFlags_FittingPolicyResizeDown = 64 # 1 << 6 # Resize tabs when they don't fit
@@ -663,14 +665,15 @@ ImGuiTabBarFlags_FittingPolicyDefault_ = 64 # ImGuiTabBarFlags_FittingPoli
663
665
  # ImGuiTabItemFlags_
664
666
  # Flags for ImGui::BeginTabItem()
665
667
  ImGuiTabItemFlags_None = 0 # 0
666
- ImGuiTabItemFlags_UnsavedDocument = 1 # 1 << 0 # Display a dot next to the title + tab is selected when clicking the X + closure is not assumed (will wait for user to stop submitting the tab). Otherwise closure is assumed when pressing the X, so if you keep submitting the tab may reappear at end of tab bar.
668
+ ImGuiTabItemFlags_UnsavedDocument = 1 # 1 << 0 # Display a dot next to the title + set ImGuiTabItemFlags_NoAssumedClosure.
667
669
  ImGuiTabItemFlags_SetSelected = 2 # 1 << 1 # Trigger flag to programmatically make the tab selected when calling BeginTabItem()
668
- ImGuiTabItemFlags_NoCloseWithMiddleMouseButton = 4 # 1 << 2 # Disable behavior of closing tabs (that are submitted with p_open != NULL) with middle mouse button. You can still repro this behavior on user's side with if (IsItemHovered() && IsMouseClicked(2)) *p_open = false.
669
- ImGuiTabItemFlags_NoPushId = 8 # 1 << 3 # Don't call PushID(tab->ID)/PopID() on BeginTabItem()/EndTabItem()
670
+ ImGuiTabItemFlags_NoCloseWithMiddleMouseButton = 4 # 1 << 2 # Disable behavior of closing tabs (that are submitted with p_open != NULL) with middle mouse button. You may handle this behavior manually on user's side with if (IsItemHovered() && IsMouseClicked(2)) *p_open = false.
671
+ ImGuiTabItemFlags_NoPushId = 8 # 1 << 3 # Don't call PushID()/PopID() on BeginTabItem()/EndTabItem()
670
672
  ImGuiTabItemFlags_NoTooltip = 16 # 1 << 4 # Disable tooltip for the given tab
671
673
  ImGuiTabItemFlags_NoReorder = 32 # 1 << 5 # Disable reordering this tab or having another tab cross over this tab
672
674
  ImGuiTabItemFlags_Leading = 64 # 1 << 6 # Enforce the tab position to the left of the tab bar (after the tab list popup button)
673
675
  ImGuiTabItemFlags_Trailing = 128 # 1 << 7 # Enforce the tab position to the right of the tab bar (before the scrolling buttons)
676
+ ImGuiTabItemFlags_NoAssumedClosure = 256 # 1 << 8 # Tab is selected when trying to close + closure is not immediately assumed (will wait for user to stop submitting the tab). Otherwise closure is assumed when pressing the X, so if you keep submitting the tab may reappear at end of tab bar.
674
677
 
675
678
  # ImGuiTableBgTarget_
676
679
  # Enum for ImGui::TableSetBgColor()
@@ -837,7 +840,7 @@ ImGuiWindowFlags_UnsavedDocument = 262144 # 1 << 18 # Display a dot nex
837
840
  ImGuiWindowFlags_NoNav = 196608 # ImGuiWindowFlags_NoNavInputs | ImGuiWindowFlags_NoNavFocus
838
841
  ImGuiWindowFlags_NoDecoration = 43 # ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoScrollbar | ImGuiWindowFlags_NoCollapse
839
842
  ImGuiWindowFlags_NoInputs = 197120 # ImGuiWindowFlags_NoMouseInputs | ImGuiWindowFlags_NoNavInputs | ImGuiWindowFlags_NoNavFocus
840
- ImGuiWindowFlags_NavFlattened = 8388608 # 1 << 23 # [BETA] On child window: allow gamepad/keyboard navigation to cross over parent border to this child or between sibling child windows.
843
+ ImGuiWindowFlags_NavFlattened = 8388608 # 1 << 23 # [BETA] On child window: share focus scope, allow gamepad/keyboard navigation to cross over parent border to this child or between sibling child windows.
841
844
  ImGuiWindowFlags_ChildWindow = 16777216 # 1 << 24 # Don't use! For internal use by BeginChild()
842
845
  ImGuiWindowFlags_Tooltip = 33554432 # 1 << 25 # Don't use! For internal use by BeginTooltip()
843
846
  ImGuiWindowFlags_Popup = 67108864 # 1 << 26 # Don't use! For internal use by BeginPopup()
@@ -1447,6 +1450,7 @@ end
1447
1450
  # - Windows are generally trying to stay within the Work Area of their host viewport.
1448
1451
  class ImGuiViewport < FFI::Struct
1449
1452
  layout(
1453
+ :ID, :uint,
1450
1454
  :Flags, :int,
1451
1455
  :Pos, ImVec2.by_value,
1452
1456
  :Size, ImVec2.by_value,
@@ -1785,6 +1789,7 @@ class ImGuiIO < FFI::Struct
1785
1789
  :MouseDragThreshold, :float,
1786
1790
  :KeyRepeatDelay, :float,
1787
1791
  :KeyRepeatRate, :float,
1792
+ :ConfigDebugIsDebuggerPresent, :bool,
1788
1793
  :ConfigDebugBeginReturnValueOnce, :bool,
1789
1794
  :ConfigDebugBeginReturnValueLoop, :bool,
1790
1795
  :ConfigDebugIgnoreFocusLoss, :bool,
@@ -1812,7 +1817,6 @@ class ImGuiIO < FFI::Struct
1812
1817
  :MetricsRenderWindows, :int,
1813
1818
  :MetricsActiveWindows, :int,
1814
1819
  :MouseDelta, ImVec2.by_value,
1815
- :_UnusedPadding, :pointer,
1816
1820
  :Ctx, :pointer,
1817
1821
  :MousePos, ImVec2.by_value,
1818
1822
  :MouseDown, [:bool, 5],
@@ -2766,6 +2770,8 @@ module ImGui
2766
2770
  [:igCombo_FnStrPtr, [:pointer, :pointer, :pointer, :pointer, :int, :int], :bool],
2767
2771
  [:igCreateContext, [:pointer], :pointer],
2768
2772
  [:igDebugCheckVersionAndDataLayout, [:pointer, :size_t, :size_t, :size_t, :size_t, :size_t, :size_t], :bool],
2773
+ [:igDebugFlashStyleColor, [:int], :void],
2774
+ [:igDebugStartItemPicker, [], :void],
2769
2775
  [:igDebugTextEncoding, [:pointer], :void],
2770
2776
  [:igDestroyContext, [:pointer], :void],
2771
2777
  [:igDragFloat, [:pointer, :pointer, :float, :float, :float, :pointer, :int], :bool],
@@ -2803,7 +2809,7 @@ module ImGui
2803
2809
  [:igGetClipboardText, [], :pointer],
2804
2810
  [:igGetColorU32_Col, [:int, :float], :uint],
2805
2811
  [:igGetColorU32_Vec4, [ImVec4.by_value], :uint],
2806
- [:igGetColorU32_U32, [:uint], :uint],
2812
+ [:igGetColorU32_U32, [:uint, :float], :uint],
2807
2813
  [:igGetColumnIndex, [], :int],
2808
2814
  [:igGetColumnOffset, [:int], :float],
2809
2815
  [:igGetColumnWidth, [:int], :float],
@@ -3237,8 +3243,15 @@ module ImGui
3237
3243
  # arg: str_id(const char*), flags(ImGuiWindowFlags)
3238
3244
  # ret: bool
3239
3245
  #
3240
- # Popups: begin/end functions
3241
- # - BeginPopup(): query popup state, if open start appending into the window. Call EndPopup() afterwards. ImGuiWindowFlags are forwarded to the window.
3246
+ # Popups, Modals
3247
+ # - They block normal mouse hovering detection (and therefore most mouse interactions) behind them.
3248
+ # - If not modal: they can be closed by clicking anywhere outside them, or by pressing ESCAPE.
3249
+ # - Their visibility state (~bool) is held internally instead of being held by the programmer as we are used to with regular Begin*() calls.
3250
+ # - The 3 properties above are related: we need to retain popup visibility state in the library because popups may be closed as any time.
3251
+ # - You can bypass the hovering restriction by using ImGuiHoveredFlags_AllowWhenBlockedByPopup when calling IsItemHovered() or IsWindowHovered().
3252
+ # - IMPORTANT: Popup identifiers are relative to the current ID stack, so OpenPopup and BeginPopup generally needs to be at the same level of the stack.
3253
+ # This is sometimes leading to confusing mistakes. May rework this in the future.
3254
+ # - BeginPopup(): query popup state, if open start appending into the window. Call EndPopup() afterwards if returned true. ImGuiWindowFlags are forwarded to the window.
3242
3255
  # - BeginPopupModal(): block every interaction behind the window, cannot be closed by user, add a dimming background, has a title bar.
3243
3256
  def self.BeginPopup(str_id, flags = 0) # return true if the popup is open, and you can start outputting to it.
3244
3257
  igBeginPopup(str_id, flags)
@@ -3308,12 +3321,10 @@ module ImGui
3308
3321
  # TableNextColumn() will automatically wrap-around into the next row if needed.
3309
3322
  # - IMPORTANT: Comparatively to the old Columns() API, we need to call TableNextColumn() for the first column!
3310
3323
  # - Summary of possible call flow:
3311
- # --------------------------------------------------------------------------------------------------------
3312
- # TableNextRow() -> TableSetColumnIndex(0) -> Text("Hello 0") -> TableSetColumnIndex(1) -> Text("Hello 1") // OK
3313
- # TableNextRow() -> TableNextColumn() -> Text("Hello 0") -> TableNextColumn() -> Text("Hello 1") // OK
3314
- # TableNextColumn() -> Text("Hello 0") -> TableNextColumn() -> Text("Hello 1") // OK: TableNextColumn() automatically gets to next row!
3315
- # TableNextRow() -> Text("Hello 0") // Not OK! Missing TableSetColumnIndex() or TableNextColumn()! Text will not appear!
3316
- # --------------------------------------------------------------------------------------------------------
3324
+ # - TableNextRow() -> TableSetColumnIndex(0) -> Text("Hello 0") -> TableSetColumnIndex(1) -> Text("Hello 1") // OK
3325
+ # - TableNextRow() -> TableNextColumn() -> Text("Hello 0") -> TableNextColumn() -> Text("Hello 1") // OK
3326
+ # - TableNextColumn() -> Text("Hello 0") -> TableNextColumn() -> Text("Hello 1") // OK: TableNextColumn() automatically gets to next row!
3327
+ # - TableNextRow() -> Text("Hello 0") // Not OK! Missing TableSetColumnIndex() or TableNextColumn()! Text will not appear!
3317
3328
  # - 5. Call EndTable()
3318
3329
  def self.BeginTable(str_id, column, flags = 0, outer_size = ImVec2.create(0.0,0.0), inner_width = 0.0) # Implied outer_size = ImVec2(0.0f, 0.0f), inner_width = 0.0f
3319
3330
  igBeginTable(str_id, column, flags, outer_size, inner_width)
@@ -3505,10 +3516,22 @@ module ImGui
3505
3516
  igDebugCheckVersionAndDataLayout(version_str, sz_io, sz_style, sz_vec2, sz_vec4, sz_drawvert, sz_drawidx)
3506
3517
  end
3507
3518
 
3519
+ # arg: idx(ImGuiCol)
3520
+ # ret: void
3521
+ def self.DebugFlashStyleColor(idx)
3522
+ igDebugFlashStyleColor(idx)
3523
+ end
3524
+
3525
+ # ret: void
3526
+ def self.DebugStartItemPicker()
3527
+ igDebugStartItemPicker()
3528
+ end
3529
+
3508
3530
  # arg: text(const char*)
3509
3531
  # ret: void
3510
3532
  #
3511
3533
  # Debug Utilities
3534
+ # - Your main debugging friend is the ShowMetricsWindow() function, which is also accessible from Demo->Tools->Metrics Debugger
3512
3535
  def self.DebugTextEncoding(text)
3513
3536
  igDebugTextEncoding(text)
3514
3537
  end
@@ -3728,10 +3751,10 @@ module ImGui
3728
3751
  igGetColorU32_Vec4(col)
3729
3752
  end
3730
3753
 
3731
- # arg: col(ImU32)
3754
+ # arg: col(ImU32), alpha_mul(float)
3732
3755
  # ret: uint
3733
- def self.GetColorU32_U32(col)
3734
- igGetColorU32_U32(col)
3756
+ def self.GetColorU32_U32(col, alpha_mul = 1.0)
3757
+ igGetColorU32_U32(col, alpha_mul)
3735
3758
  end
3736
3759
 
3737
3760
  # ret: int
@@ -4016,7 +4039,7 @@ module ImGui
4016
4039
  end
4017
4040
 
4018
4041
  # ret: pointer
4019
- def self.GetStyle() # access the Style structure (colors, sizes). Always use PushStyleCol(), PushStyleVar() to modify style mid-frame!
4042
+ def self.GetStyle() # access the Style structure (colors, sizes). Always use PushStyleColor(), PushStyleVar() to modify style mid-frame!
4020
4043
  igGetStyle()
4021
4044
  end
4022
4045
 
@@ -4100,14 +4123,15 @@ module ImGui
4100
4123
  igGetWindowWidth()
4101
4124
  end
4102
4125
 
4103
- # arg: user_texture_id(ImTextureID), size(ImVec2), uv0(ImVec2), uv1(ImVec2), tint_col(ImVec4), border_col(ImVec4)
4126
+ # arg: user_texture_id(ImTextureID), image_size(ImVec2), uv0(ImVec2), uv1(ImVec2), tint_col(ImVec4), border_col(ImVec4)
4104
4127
  # ret: void
4105
4128
  #
4106
4129
  # Widgets: Images
4107
4130
  # - Read about ImTextureID here: https://github.com/ocornut/imgui/wiki/Image-Loading-and-Displaying-Examples
4108
- # - Note that ImageButton() adds style.FramePadding*2.0f to provided size. This is in order to facilitate fitting an image in a button.
4109
- def self.Image(user_texture_id, size, uv0 = ImVec2.create(0,0), uv1 = ImVec2.create(1,1), tint_col = ImVec4.create(1,1,1,1), border_col = ImVec4.create(0,0,0,0)) # Implied uv0 = ImVec2(0, 0), uv1 = ImVec2(1, 1), tint_col = ImVec4(1, 1, 1, 1), border_col = ImVec4(0, 0, 0, 0)
4110
- igImage(user_texture_id, size, uv0, uv1, tint_col, border_col)
4131
+ # - 'uv0' and 'uv1' are texture coordinates. Read about them from the same link above.
4132
+ # - Note that Image() may add +2.0f to provided size if a border is visible, ImageButton() adds style.FramePadding*2.0f to provided size.
4133
+ def self.Image(user_texture_id, image_size, uv0 = ImVec2.create(0,0), uv1 = ImVec2.create(1,1), tint_col = ImVec4.create(1,1,1,1), border_col = ImVec4.create(0,0,0,0)) # Implied uv0 = ImVec2(0, 0), uv1 = ImVec2(1, 1), tint_col = ImVec4(1, 1, 1, 1), border_col = ImVec4(0, 0, 0, 0)
4134
+ igImage(user_texture_id, image_size, uv0, uv1, tint_col, border_col)
4111
4135
  end
4112
4136
 
4113
4137
  # arg: str_id(const char*), user_texture_id(ImTextureID), image_size(ImVec2), uv0(ImVec2), uv1(ImVec2), bg_col(ImVec4), tint_col(ImVec4)
@@ -5404,7 +5428,7 @@ module ImGui
5404
5428
  end
5405
5429
 
5406
5430
  # ret: void
5407
- def self.TreePop() # ~ Unindent()+PopId()
5431
+ def self.TreePop() # ~ Unindent()+PopID()
5408
5432
  igTreePop()
5409
5433
  end
5410
5434
 
@@ -5475,7 +5499,7 @@ module ImGui
5475
5499
  # - Use child windows to begin into a self-contained independent scrolling/clipping regions within a host window. Child windows can embed their own child.
5476
5500
  # - Before 1.90 (November 2023), the "ImGuiChildFlags child_flags = 0" parameter was "bool border = false".
5477
5501
  # This API is backward compatible with old code, as we guarantee that ImGuiChildFlags_Border == true.
5478
- # Consider updating your old call sites:
5502
+ # Consider updating your old code:
5479
5503
  # BeginChild("Name", size, false) -> Begin("Name", size, 0); or Begin("Name", size, ImGuiChildFlags_None);
5480
5504
  # BeginChild("Name", size, true) -> Begin("Name", size, ImGuiChildFlags_Border);
5481
5505
  # - Manual sizing (each axis can use a different setting e.g. ImVec2(0.0f, 400.0f)):
@@ -5539,9 +5563,9 @@ module ImGui
5539
5563
  # arg: 0:col(ImVec4)
5540
5564
  # ret: uint
5541
5565
  return igGetColorU32_Vec4(arg[0]) if arg.length == 1 && (arg[0].kind_of?(ImVec4))
5542
- # arg: 0:col(ImU32)
5566
+ # arg: 0:col(ImU32), 1:alpha_mul(float)
5543
5567
  # ret: uint
5544
- return igGetColorU32_U32(arg[0]) if arg.length == 1 && (arg[0].kind_of?(Integer))
5568
+ return igGetColorU32_U32(arg[0], arg[1]) if arg.length == 2 && (arg[0].kind_of?(Integer) && arg[1].kind_of?(Float))
5545
5569
  $stderr.puts("[Warning] GetColorU32 : No matching functions found (#{arg})")
5546
5570
  end
5547
5571
 
@@ -5771,7 +5795,7 @@ module ImGui
5771
5795
  $stderr.puts("[Warning] TreeNodeEx : No matching functions found (#{arg})")
5772
5796
  end
5773
5797
 
5774
- def self.TreePush(*arg) # ~ Indent()+PushId(). Already called by TreeNode() when returning true, but you can call TreePush/TreePop yourself if desired.
5798
+ def self.TreePush(*arg) # ~ Indent()+PushID(). Already called by TreeNode() when returning true, but you can call TreePush/TreePop yourself if desired.
5775
5799
  # arg: 0:str_id(const char*)
5776
5800
  # ret: void
5777
5801
  return igTreePush_Str(arg[0]) if arg.length == 1 && (arg[0].kind_of?(String))
Binary file
data/lib/imgui.x86_64.so CHANGED
Binary file
Binary file
Binary file
data/lib/imnodes.dll CHANGED
Binary file
Binary file
Binary file
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: imgui-bindings
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.9
4
+ version: 0.1.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - vaiorabbit
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-11-19 00:00:00.000000000 Z
11
+ date: 2024-02-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ffi
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.15'
19
+ version: '1.16'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.15'
26
+ version: '1.16'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: opengl-bindings2
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -51,9 +51,10 @@ files:
51
51
  - LICENSE.txt
52
52
  - README.md
53
53
  - lib/imgui.aarch64.so
54
+ - lib/imgui.arm64.dylib
54
55
  - lib/imgui.dll
55
- - lib/imgui.dylib
56
56
  - lib/imgui.rb
57
+ - lib/imgui.x86_64.dylib
57
58
  - lib/imgui.x86_64.so
58
59
  - lib/imgui_impl_glfw.rb
59
60
  - lib/imgui_impl_opengl2.rb
@@ -63,9 +64,10 @@ files:
63
64
  - lib/imgui_impl_sdlrenderer.rb
64
65
  - lib/imgui_internal.rb
65
66
  - lib/imnodes.aarch64.so
67
+ - lib/imnodes.arm64.dylib
66
68
  - lib/imnodes.dll
67
- - lib/imnodes.dylib
68
69
  - lib/imnodes.rb
70
+ - lib/imnodes.x86_64.dylib
69
71
  - lib/imnodes.x86_64.so
70
72
  homepage: https://github.com/vaiorabbit/ruby-imgui
71
73
  licenses:
@@ -86,7 +88,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
86
88
  - !ruby/object:Gem::Version
87
89
  version: '0'
88
90
  requirements: []
89
- rubygems_version: 3.4.20
91
+ rubygems_version: 3.5.5
90
92
  signing_key:
91
93
  specification_version: 4
92
94
  summary: Bindings for Dear ImGui
data/lib/imgui.dylib DELETED
Binary file
data/lib/imnodes.dylib DELETED
Binary file