imgui-bindings 0.1.14-arm64-darwin → 0.1.15-arm64-darwin

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: c1a7474a5fbdaa65814ca46af49b6e6a22205bdbfd23643cc59a29ca46ffb6a9
4
- data.tar.gz: 837c1307987af90b8c724735d64d65403640b78bb6e77753da2c9a4ad294aef4
3
+ metadata.gz: 58c5b0736a40e4e30aeba88f11a14c40f20e1ce8bc5f46478a2c8cdf51526bfc
4
+ data.tar.gz: 6732b1d95f40487815afa68742126ad35a624c7e861c129247c400e8ae5726c6
5
5
  SHA512:
6
- metadata.gz: 7a11cbcd4b9f803222acb31c5e20e054765a311c3118caa074b7367138ed46cd14ffd28e9a3675655e5b546e41d13bbef3493640a1930862e5da0042f29af1ac
7
- data.tar.gz: 9d3ac7a6b694610d60f68f80a2271f8c952ba30deb99c2e4a988627ba832ec33cf85cebf59078ecd4ac70fbe5516933e1130ac962d039282f8b3e7e420bbfa23
6
+ metadata.gz: 6875569a848c7d6c7f7196020c6204f455b3f6938c03cccf7fcecfb86305d5f5da44a446678cb9c1b4bd92d4dcf0a85fa290f2b8f6bac4be424c84215e126bb2
7
+ data.tar.gz: 7836cd558f060a6ab39519e7d8d87241bde55446909ca0aed2b1dcea13d91633f473383d286ca352a8fb9bfdcd72cd2f5d7989e9b33a1f7a9d1b899c14162fd2
data/ChangeLog CHANGED
@@ -1,3 +1,7 @@
1
+ 2024-09-22 vaiorabbit <http://twitter.com/vaiorabbit>
2
+
3
+ * ImGui v1.91.1
4
+
1
5
  2024-08-04 vaiorabbit <http://twitter.com/vaiorabbit>
2
6
 
3
7
  * ImGui v1.91.0
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 : 2024-08-04
6
+ * Last modified : 2024-09-21
7
7
 
8
8
  <img src="https://raw.githubusercontent.com/vaiorabbit/ruby-imgui/master/doc/jpfont_test.png" width="250">
9
9
 
Binary file
data/lib/imgui.rb CHANGED
@@ -156,7 +156,7 @@ ImGuiButtonFlags_MouseButtonMask_ = 7 # ImGuiButtonFlags_MouseButtonLeft | ImGu
156
156
 
157
157
  # ImGuiChildFlags_
158
158
  # Flags for ImGui::BeginChild()
159
- # (Legacy: bit 0 must always correspond to ImGuiChildFlags_Border to be backward compatible with old API using 'bool border = false'.
159
+ # (Legacy: bit 0 must always correspond to ImGuiChildFlags_Borders to be backward compatible with old API using 'bool border = false'.
160
160
  # About using AutoResizeX/AutoResizeY flags:
161
161
  # - May be combined with SetNextWindowSizeConstraints() to set a min/max size for each axis (see "Demo->Child->Auto-resize with Constraints").
162
162
  # - Size measurement for a given axis is only performed when the child window is within visible boundaries, or is just appearing.
@@ -165,7 +165,7 @@ ImGuiButtonFlags_MouseButtonMask_ = 7 # ImGuiButtonFlags_MouseButtonLeft | ImGu
165
165
  # - You may also use ImGuiChildFlags_AlwaysAutoResize to force an update even when child window is not in view.
166
166
  # HOWEVER PLEASE UNDERSTAND THAT DOING SO WILL PREVENT BeginChild() FROM EVER RETURNING FALSE, disabling benefits of coarse clipping.
167
167
  ImGuiChildFlags_None = 0 # 0
168
- ImGuiChildFlags_Border = 1 # 1 << 0 # Show an outer border and enable WindowPadding. (IMPORTANT: this is always == 1 == true for legacy reason)
168
+ ImGuiChildFlags_Borders = 1 # 1 << 0 # Show an outer border and enable WindowPadding. (IMPORTANT: this is always == 1 == true for legacy reason)
169
169
  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)
170
170
  ImGuiChildFlags_ResizeX = 4 # 1 << 2 # Allow resize from right border (layout direction). Enable .ini saving (unless ImGuiWindowFlags_NoSavedSettings passed to window flags)
171
171
  ImGuiChildFlags_ResizeY = 8 # 1 << 3 # Allow resize from bottom border (layout direction). "
@@ -817,7 +817,7 @@ ImGuiTableColumnFlags_NoClip = 256 # 1 << 8 # Disable clipping f
817
817
  ImGuiTableColumnFlags_NoSort = 512 # 1 << 9 # Disable ability to sort on this field (even if ImGuiTableFlags_Sortable is set on the table).
818
818
  ImGuiTableColumnFlags_NoSortAscending = 1024 # 1 << 10 # Disable ability to sort in the ascending direction.
819
819
  ImGuiTableColumnFlags_NoSortDescending = 2048 # 1 << 11 # Disable ability to sort in the descending direction.
820
- ImGuiTableColumnFlags_NoHeaderLabel = 4096 # 1 << 12 # TableHeadersRow() will not submit horizontal label for this column. Convenient for some small columns. Name will still appear in context menu or in angled headers.
820
+ ImGuiTableColumnFlags_NoHeaderLabel = 4096 # 1 << 12 # TableHeadersRow() will submit an empty label for this column. Convenient for some small columns. Name will still appear in context menu or in angled headers. You may append into this cell by calling TableSetColumnIndex() right after the TableHeadersRow() call.
821
821
  ImGuiTableColumnFlags_NoHeaderWidth = 8192 # 1 << 13 # Disable header text width contribution to automatic column width.
822
822
  ImGuiTableColumnFlags_PreferSortAscending = 16384 # 1 << 14 # Make the initial sort direction Ascending when first sorting on this column (default).
823
823
  ImGuiTableColumnFlags_PreferSortDescending = 32768 # 1 << 15 # Make the initial sort direction Descending when first sorting on this column.
@@ -908,8 +908,8 @@ ImGuiTreeNodeFlags_AllowOverlap = 4 # 1 << 2 # Hit testing to allow
908
908
  ImGuiTreeNodeFlags_NoTreePushOnOpen = 8 # 1 << 3 # Don't do a TreePush() when open (e.g. for CollapsingHeader) = no extra indent nor pushing on ID stack
909
909
  ImGuiTreeNodeFlags_NoAutoOpenOnLog = 16 # 1 << 4 # Don't automatically and temporarily open node when Logging is active (by default logging will automatically open tree nodes)
910
910
  ImGuiTreeNodeFlags_DefaultOpen = 32 # 1 << 5 # Default node to be open
911
- ImGuiTreeNodeFlags_OpenOnDoubleClick = 64 # 1 << 6 # Need double-click to open node
912
- ImGuiTreeNodeFlags_OpenOnArrow = 128 # 1 << 7 # Only open when clicking on the arrow part. If ImGuiTreeNodeFlags_OpenOnDoubleClick is also set, single-click arrow or double-click all box to open.
911
+ ImGuiTreeNodeFlags_OpenOnDoubleClick = 64 # 1 << 6 # Open on double-click instead of simple click (default for multi-select unless any _OpenOnXXX behavior is set explicitly). Both behaviors may be combined.
912
+ ImGuiTreeNodeFlags_OpenOnArrow = 128 # 1 << 7 # Open when clicking on the arrow part (default for multi-select unless any _OpenOnXXX behavior is set explicitly). Both behaviors may be combined.
913
913
  ImGuiTreeNodeFlags_Leaf = 256 # 1 << 8 # No collapsing, no arrow (use as a convenience for leaf nodes).
914
914
  ImGuiTreeNodeFlags_Bullet = 512 # 1 << 9 # Display a bullet instead of arrow. IMPORTANT: node can still be marked open/close if you don't set the _Leaf flag!
915
915
  ImGuiTreeNodeFlags_FramePadding = 1024 # 1 << 10 # Use FramePadding (even for an unframed text node) to vertically align text baseline to regular widget height. Equivalent to calling AlignTextToFramePadding() before the node.
@@ -925,7 +925,7 @@ ImGuiTreeNodeFlags_CollapsingHeader = 26 # ImGuiTreeNodeFlags_Framed | Im
925
925
  ImGuiViewportFlags_None = 0 # 0
926
926
  ImGuiViewportFlags_IsPlatformWindow = 1 # 1 << 0 # Represent a Platform Window
927
927
  ImGuiViewportFlags_IsPlatformMonitor = 2 # 1 << 1 # Represent a Platform Monitor (unused yet)
928
- ImGuiViewportFlags_OwnedByApp = 4 # 1 << 2 # Platform Window: is created/managed by the application (rather than a dear imgui backend)
928
+ ImGuiViewportFlags_OwnedByApp = 4 # 1 << 2 # Platform Window: Is created/managed by the user application? (rather than our backend)
929
929
 
930
930
  # ImGuiWindowFlags_
931
931
  # Flags for ImGui::Begin()
@@ -1371,6 +1371,10 @@ class ImDrawList < FFI::Struct
1371
1371
  ImGui::ImDrawList__ResetForNewFrame(self)
1372
1372
  end
1373
1373
 
1374
+ def _SetTextureID(texture_id)
1375
+ ImGui::ImDrawList__SetTextureID(self, texture_id)
1376
+ end
1377
+
1374
1378
  def _TryMergeDrawCmds()
1375
1379
  ImGui::ImDrawList__TryMergeDrawCmds(self)
1376
1380
  end
@@ -1562,7 +1566,7 @@ class ImGuiKeyData < FFI::Struct
1562
1566
  end
1563
1567
 
1564
1568
  # - Currently represents the Platform Window created by the application which is hosting our Dear ImGui windows.
1565
- # - In 'docking' branch with multi-viewport enabled, we extend this concept to have multiple active viewports.
1569
+ # - With multi-viewport enabled, we extend this concept to have multiple active viewports.
1566
1570
  # - In the future we will extend this concept further to also represent Platform Monitor and support a "no main platform window" operation mode.
1567
1571
  # - About Main Area vs Work Area:
1568
1572
  # - Main Area = entire viewport.
@@ -1996,13 +2000,6 @@ class ImGuiIO < FFI::Struct
1996
2000
  :BackendPlatformUserData, :pointer,
1997
2001
  :BackendRendererUserData, :pointer,
1998
2002
  :BackendLanguageUserData, :pointer,
1999
- :GetClipboardTextFn, :pointer,
2000
- :SetClipboardTextFn, :pointer,
2001
- :ClipboardUserData, :pointer,
2002
- :PlatformOpenInShellFn, :pointer,
2003
- :PlatformOpenInShellUserData, :pointer,
2004
- :PlatformSetImeDataFn, :pointer,
2005
- :PlatformLocaleDecimalPoint, :ushort,
2006
2003
  :WantCaptureMouse, :bool,
2007
2004
  :WantCaptureKeyboard, :bool,
2008
2005
  :WantTextInput, :bool,
@@ -2300,7 +2297,7 @@ class ImGuiPayload < FFI::Struct
2300
2297
 
2301
2298
  end
2302
2299
 
2303
- # (Optional) Support for IME (Input Method Editor) via the io.PlatformSetImeDataFn() function.
2300
+ # (Optional) Support for IME (Input Method Editor) via the platform_io.Platform_SetImeDataFn() function.
2304
2301
  class ImGuiPlatformImeData < FFI::Struct
2305
2302
  layout(
2306
2303
  :WantVisible, :bool,
@@ -2813,6 +2810,7 @@ module ImGui
2813
2810
  [:ImDrawList__PathArcToN, [:pointer, ImVec2.by_value, :float, :float, :float, :int], :void],
2814
2811
  [:ImDrawList__PopUnusedDrawCmd, [:pointer], :void],
2815
2812
  [:ImDrawList__ResetForNewFrame, [:pointer], :void],
2813
+ [:ImDrawList__SetTextureID, [:pointer, :pointer], :void],
2816
2814
  [:ImDrawList__TryMergeDrawCmds, [:pointer], :void],
2817
2815
  [:ImDrawList_destroy, [:pointer], :void],
2818
2816
  [:ImFontAtlasCustomRect_ImFontAtlasCustomRect, [], :pointer],
@@ -2918,6 +2916,8 @@ module ImGui
2918
2916
  [:ImGuiPayload_IsDelivery, [:pointer], :bool],
2919
2917
  [:ImGuiPayload_IsPreview, [:pointer], :bool],
2920
2918
  [:ImGuiPayload_destroy, [:pointer], :void],
2919
+ [:ImGuiPlatformIO_ImGuiPlatformIO, [], :pointer],
2920
+ [:ImGuiPlatformIO_destroy, [:pointer], :void],
2921
2921
  [:ImGuiPlatformImeData_ImGuiPlatformImeData, [], :pointer],
2922
2922
  [:ImGuiPlatformImeData_destroy, [:pointer], :void],
2923
2923
  [:ImGuiSelectionBasicStorage_ApplyRequests, [:pointer, :pointer], :void],
@@ -3117,6 +3117,7 @@ module ImGui
3117
3117
  [:igGetMouseDragDelta, [:pointer, :int, :float], :void],
3118
3118
  [:igGetMousePos, [:pointer], :void],
3119
3119
  [:igGetMousePosOnOpeningCurrentPopup, [:pointer], :void],
3120
+ [:igGetPlatformIO, [], :pointer],
3120
3121
  [:igGetScrollMaxX, [], :float],
3121
3122
  [:igGetScrollMaxY, [], :float],
3122
3123
  [:igGetScrollX, [], :float],
@@ -3232,6 +3233,8 @@ module ImGui
3232
3233
  [:igPushStyleColor_Vec4, [:int, ImVec4.by_value], :void],
3233
3234
  [:igPushStyleVar_Float, [:int, :float], :void],
3234
3235
  [:igPushStyleVar_Vec2, [:int, ImVec2.by_value], :void],
3236
+ [:igPushStyleVarX, [:int, :float], :void],
3237
+ [:igPushStyleVarY, [:int, :float], :void],
3235
3238
  [:igPushTextWrapPos, [:float], :void],
3236
3239
  [:igRadioButton_Bool, [:pointer, :bool], :bool],
3237
3240
  [:igRadioButton_IntPtr, [:pointer, :pointer, :int], :bool],
@@ -3761,13 +3764,13 @@ module ImGui
3761
3764
  igColorPicker4(label, col, flags, ref_col)
3762
3765
  end
3763
3766
 
3764
- # arg: count(int), id(const char*), border(bool)
3767
+ # arg: count(int), id(const char*), borders(bool)
3765
3768
  # ret: void
3766
3769
  #
3767
3770
  # Legacy Columns API (prefer using Tables!)
3768
3771
  # - You can also use SameLine(pos_x) to mimic simplified columns.
3769
- def self.Columns(count = 1, id = nil, border = true) # Implied count = 1, id = NULL, border = true
3770
- igColumns(count, id, border)
3772
+ def self.Columns(count = 1, id = nil, borders = true) # Implied count = 1, id = NULL, borders = true
3773
+ igColumns(count, id, borders)
3771
3774
  end
3772
3775
 
3773
3776
  # arg: label(const char*), current_item(int*), items(const char* const[]), items_count(int), popup_max_height_in_items(int)
@@ -4027,7 +4030,7 @@ module ImGui
4027
4030
  # ret: pointer
4028
4031
  #
4029
4032
  # Background/Foreground Draw Lists
4030
- def self.GetBackgroundDrawList() # this draw list will be the first rendered one. Useful to quickly draw shapes/text behind dear imgui contents.
4033
+ def self.GetBackgroundDrawList() # Implied viewport = NULL
4031
4034
  igGetBackgroundDrawList()
4032
4035
  end
4033
4036
 
@@ -4162,14 +4165,14 @@ module ImGui
4162
4165
  end
4163
4166
 
4164
4167
  # ret: void
4165
- def self.GetFontTexUvWhitePixel() # get UV coordinate for a while pixel, useful to draw custom shapes via the ImDrawList API
4168
+ def self.GetFontTexUvWhitePixel() # get UV coordinate for a white pixel, useful to draw custom shapes via the ImDrawList API
4166
4169
  pOut = ImVec2.new
4167
4170
  igGetFontTexUvWhitePixel(pOut)
4168
4171
  return pOut
4169
4172
  end
4170
4173
 
4171
4174
  # ret: pointer
4172
- def self.GetForegroundDrawList() # this draw list will be the last rendered one. Useful to quickly draw shapes/text over dear imgui contents.
4175
+ def self.GetForegroundDrawList() # Implied viewport = NULL
4173
4176
  igGetForegroundDrawList()
4174
4177
  end
4175
4178
 
@@ -4215,7 +4218,7 @@ module ImGui
4215
4218
  # ret: pointer
4216
4219
  #
4217
4220
  # Main
4218
- def self.GetIO() # access the IO structure (mouse/keyboard/gamepad inputs, time, various configuration options/flags)
4221
+ def self.GetIO() # access the ImGuiIO structure (mouse/keyboard/gamepad inputs, time, various configuration options/flags)
4219
4222
  igGetIO()
4220
4223
  end
4221
4224
 
@@ -4300,6 +4303,11 @@ module ImGui
4300
4303
  return pOut
4301
4304
  end
4302
4305
 
4306
+ # ret: pointer
4307
+ def self.GetPlatformIO() # access the ImGuiPlatformIO structure (mostly hooks/functions to connect to platform/renderer and OS Clipboard, IME etc.)
4308
+ igGetPlatformIO()
4309
+ end
4310
+
4303
4311
  # ret: float
4304
4312
  def self.GetScrollMaxX() # get maximum scrolling amount ~~ ContentSize.x - WindowSize.x - DecorationsSize.x
4305
4313
  igGetScrollMaxX()
@@ -5003,6 +5011,18 @@ module ImGui
5003
5011
  igPushStyleVar_Vec2(idx, val)
5004
5012
  end
5005
5013
 
5014
+ # arg: idx(ImGuiStyleVar), val_x(float)
5015
+ # ret: void
5016
+ def self.PushStyleVarX(idx, val_x) # modify X component of a style ImVec2 variable. "
5017
+ igPushStyleVarX(idx, val_x)
5018
+ end
5019
+
5020
+ # arg: idx(ImGuiStyleVar), val_y(float)
5021
+ # ret: void
5022
+ def self.PushStyleVarY(idx, val_y) # modify Y component of a style ImVec2 variable. "
5023
+ igPushStyleVarY(idx, val_y)
5024
+ end
5025
+
5006
5026
  # arg: wrap_local_pos_x(float)
5007
5027
  # ret: void
5008
5028
  def self.PushTextWrapPos(wrap_local_pos_x = 0.0) # push word-wrapping position for Text*() commands. < 0.0f: no wrapping; 0.0f: wrap to end of window (or column); > 0.0f: wrap at 'wrap_pos_x' position in window local space
@@ -5839,10 +5859,10 @@ module ImGui
5839
5859
  # Child Windows
5840
5860
  # - Use child windows to begin into a self-contained independent scrolling/clipping regions within a host window. Child windows can embed their own child.
5841
5861
  # - Before 1.90 (November 2023), the "ImGuiChildFlags child_flags = 0" parameter was "bool border = false".
5842
- # This API is backward compatible with old code, as we guarantee that ImGuiChildFlags_Border == true.
5862
+ # This API is backward compatible with old code, as we guarantee that ImGuiChildFlags_Borders == true.
5843
5863
  # Consider updating your old code:
5844
5864
  # BeginChild("Name", size, false) -> Begin("Name", size, 0); or Begin("Name", size, ImGuiChildFlags_None);
5845
- # BeginChild("Name", size, true) -> Begin("Name", size, ImGuiChildFlags_Border);
5865
+ # BeginChild("Name", size, true) -> Begin("Name", size, ImGuiChildFlags_Borders);
5846
5866
  # - Manual sizing (each axis can use a different setting e.g. ImVec2(0.0f, 400.0f)):
5847
5867
  # == 0.0f: use remaining parent window size for this axis.
5848
5868
  # > 0.0f: use specified size for this axis.
@@ -6036,7 +6056,7 @@ module ImGui
6036
6056
  $stderr.puts("[Warning] PushStyleColor : No matching functions found (#{arg})")
6037
6057
  end
6038
6058
 
6039
- def self.PushStyleVar(*arg) # modify a style float variable. always use this if you modify the style after NewFrame().
6059
+ def self.PushStyleVar(*arg) # modify a style float variable. always use this if you modify the style after NewFrame()!
6040
6060
  # arg: 0:idx(ImGuiStyleVar), 1:val(float)
6041
6061
  # ret: void
6042
6062
  return igPushStyleVar_Float(arg[0], arg[1]) if arg.length == 2 && (arg[0].kind_of?(Integer) && arg[1].kind_of?(Float))
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.14
4
+ version: 0.1.15
5
5
  platform: arm64-darwin
6
6
  authors:
7
7
  - vaiorabbit
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-08-04 00:00:00.000000000 Z
11
+ date: 2024-09-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ffi
@@ -80,7 +80,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
80
80
  - !ruby/object:Gem::Version
81
81
  version: '0'
82
82
  requirements: []
83
- rubygems_version: 3.5.15
83
+ rubygems_version: 3.5.18
84
84
  signing_key:
85
85
  specification_version: 4
86
86
  summary: Bindings for Dear ImGui