meltygui-imgui 2.0.0.post3__cp313-cp313-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- meltygui_imgui/__init__.py +879 -0
- meltygui_imgui/_compat.py +16 -0
- meltygui_imgui/ansifeed.pxd +20 -0
- meltygui_imgui/cimgui.pxd +2242 -0
- meltygui_imgui/common.pyx +75 -0
- meltygui_imgui/core.cp313-win_amd64.pyd +0 -0
- meltygui_imgui/core.cpp +189914 -0
- meltygui_imgui/core.h +51 -0
- meltygui_imgui/core.pxd +12 -0
- meltygui_imgui/core.pyx +12812 -0
- meltygui_imgui/enums.pxd +561 -0
- meltygui_imgui/enums_internal.pxd +200 -0
- meltygui_imgui/extra.py +36 -0
- meltygui_imgui/integrations/__init__.py +13 -0
- meltygui_imgui/integrations/base.py +33 -0
- meltygui_imgui/integrations/cocos2d.py +27 -0
- meltygui_imgui/integrations/glfw.py +133 -0
- meltygui_imgui/integrations/glumpy.py +369 -0
- meltygui_imgui/integrations/opengl.py +422 -0
- meltygui_imgui/integrations/pygame.py +152 -0
- meltygui_imgui/integrations/pyglet.py +245 -0
- meltygui_imgui/integrations/sdl2.py +136 -0
- meltygui_imgui/internal.cp313-win_amd64.pyd +0 -0
- meltygui_imgui/internal.cpp +13336 -0
- meltygui_imgui/internal.h +51 -0
- meltygui_imgui/internal.pxd +686 -0
- meltygui_imgui/internal.pyx +207 -0
- meltygui_imgui-2.0.0.post3.dist-info/DELVEWHEEL +2 -0
- meltygui_imgui-2.0.0.post3.dist-info/METADATA +146 -0
- meltygui_imgui-2.0.0.post3.dist-info/RECORD +38 -0
- meltygui_imgui-2.0.0.post3.dist-info/WHEEL +5 -0
- meltygui_imgui-2.0.0.post3.dist-info/licenses/LICENSE +28 -0
- meltygui_imgui-2.0.0.post3.dist-info/licenses/LICENSES/imgui-MIT.txt +21 -0
- meltygui_imgui-2.0.0.post3.dist-info/licenses/LICENSES/imstb_rectpack.h.license.txt +37 -0
- meltygui_imgui-2.0.0.post3.dist-info/licenses/LICENSES/imstb_textedit.h.license.txt +37 -0
- meltygui_imgui-2.0.0.post3.dist-info/licenses/LICENSES/imstb_truetype.h.license.txt +37 -0
- meltygui_imgui-2.0.0.post3.dist-info/top_level.txt +1 -0
- meltygui_imgui.libs/msvcp140-a4c2229bdc2a2a630acdc095b4d86008.dll +0 -0
|
@@ -0,0 +1,2242 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# distutils: language = c++
|
|
3
|
+
# distutils: include_dirs = imgui-cpp
|
|
4
|
+
"""
|
|
5
|
+
Notes:
|
|
6
|
+
`✓` marks API element as already mapped in core bindings.
|
|
7
|
+
`✗` marks API element as "yet to be mapped
|
|
8
|
+
"""
|
|
9
|
+
from libcpp cimport bool
|
|
10
|
+
|
|
11
|
+
from enums cimport ImGuiKey_, ImGuiCol_, ImGuiSliderFlags_
|
|
12
|
+
|
|
13
|
+
cdef extern from "imgui.h":
|
|
14
|
+
# ====
|
|
15
|
+
# Forward declarations
|
|
16
|
+
ctypedef struct ImDrawChannel
|
|
17
|
+
ctypedef struct ImDrawCmd
|
|
18
|
+
ctypedef struct ImDrawData
|
|
19
|
+
#ctypedef struct ImDrawList # declared later
|
|
20
|
+
ctypedef struct ImDrawListSharedData
|
|
21
|
+
#ctypedef struct ImDrawListSplitter # declared later
|
|
22
|
+
ctypedef struct ImDrawVert
|
|
23
|
+
ctypedef struct ImFont
|
|
24
|
+
ctypedef struct ImFontAtlas
|
|
25
|
+
#ctypedef struct ImFontConfig # declared later
|
|
26
|
+
ctypedef struct ImFontGlyph
|
|
27
|
+
ctypedef struct ImFontGlyphRangesBuilder
|
|
28
|
+
#ctypedef struct ImColor # declared later
|
|
29
|
+
ctypedef struct ImGuiContext
|
|
30
|
+
ctypedef struct ImGuiIO
|
|
31
|
+
ctypedef struct ImGuiInputTextCallbackData
|
|
32
|
+
ctypedef struct ImGuiListClipper
|
|
33
|
+
ctypedef struct ImGuiOnceUponAFrame
|
|
34
|
+
ctypedef struct ImGuiPayload
|
|
35
|
+
ctypedef struct ImGuiSizeCallbackData
|
|
36
|
+
ctypedef struct ImGuiStorage
|
|
37
|
+
# ctypedef struct ImGuiStyle # declared later
|
|
38
|
+
ctypedef struct ImGuiTableSortSpecs
|
|
39
|
+
ctypedef struct ImGuiTableColumnSortSpecs
|
|
40
|
+
ctypedef struct ImGuiTextBuffer
|
|
41
|
+
ctypedef struct ImGuiTextFilter
|
|
42
|
+
# ctypedef struct ImGuiViewport # declared later
|
|
43
|
+
|
|
44
|
+
# ====
|
|
45
|
+
# Enums/Flags
|
|
46
|
+
ctypedef int ImGuiCol
|
|
47
|
+
ctypedef int ImGuiCond
|
|
48
|
+
ctypedef int ImGuiDataType
|
|
49
|
+
ctypedef int ImGuiDir
|
|
50
|
+
ctypedef int ImGuiKey
|
|
51
|
+
ctypedef int ImGuiNavInput
|
|
52
|
+
ctypedef int ImGuiMouseButton
|
|
53
|
+
ctypedef int ImGuiMouseCursor
|
|
54
|
+
ctypedef int ImGuiSortDirection
|
|
55
|
+
ctypedef int ImGuiStyleVar
|
|
56
|
+
ctypedef int ImGuiTableBgTarget
|
|
57
|
+
ctypedef int ImDrawCornerFlags # OBSOLETED in 1.82 (from Mars 2021)
|
|
58
|
+
ctypedef int ImDrawFlags
|
|
59
|
+
ctypedef int ImDrawListFlags
|
|
60
|
+
ctypedef int ImFontAtlasFlags
|
|
61
|
+
ctypedef int ImGuiViewportFlags
|
|
62
|
+
ctypedef int ImGuiBackendFlags
|
|
63
|
+
ctypedef int ImGuiButtonFlags
|
|
64
|
+
ctypedef int ImGuiColorEditFlags
|
|
65
|
+
ctypedef int ImGuiConfigFlags
|
|
66
|
+
ctypedef int ImGuiComboFlags
|
|
67
|
+
ctypedef int ImGuiDragDropFlags
|
|
68
|
+
ctypedef int ImGuiFocusedFlags
|
|
69
|
+
ctypedef int ImGuiHoveredFlags
|
|
70
|
+
ctypedef int ImGuiInputTextFlags
|
|
71
|
+
ctypedef int ImGuiKeyModFlags
|
|
72
|
+
ctypedef int ImGuiPopupFlags
|
|
73
|
+
ctypedef int ImGuiSelectableFlags
|
|
74
|
+
ctypedef int ImGuiSliderFlags
|
|
75
|
+
ctypedef int ImGuiTabBarFlags
|
|
76
|
+
ctypedef int ImGuiTabItemFlags
|
|
77
|
+
ctypedef int ImGuiTableFlags
|
|
78
|
+
ctypedef int ImGuiTableColumnFlags
|
|
79
|
+
ctypedef int ImGuiTableRowFlags
|
|
80
|
+
ctypedef int ImGuiTreeNodeFlags
|
|
81
|
+
ctypedef int ImGuiWindowFlags
|
|
82
|
+
# ctypedef int ImGuiColumnsFlags # DEPRECIATED
|
|
83
|
+
|
|
84
|
+
# ====
|
|
85
|
+
# Various int typedefs and enumerations
|
|
86
|
+
ctypedef void* ImTextureID
|
|
87
|
+
ctypedef unsigned int ImGuiID
|
|
88
|
+
ctypedef int (*ImGuiInputTextCallback)(ImGuiInputTextCallbackData *data);
|
|
89
|
+
ctypedef void (*ImGuiSizeCallback)(ImGuiSizeCallbackData* data);
|
|
90
|
+
ctypedef void* (*ImGuiMemAllocFunc)(size_t sz, void* user_data);
|
|
91
|
+
ctypedef void (*ImGuiMemFreeFunc)(void* ptr, void* user_data);
|
|
92
|
+
|
|
93
|
+
# ==== # TODO: Find a way to check IMGUI_USE_WCHAR32 define
|
|
94
|
+
# Decoded character types
|
|
95
|
+
ctypedef unsigned short ImWchar16
|
|
96
|
+
ctypedef unsigned int ImWchar32
|
|
97
|
+
|
|
98
|
+
# note: Default is ImWchar16,
|
|
99
|
+
# if IMGUI_USE_WCHAR32 is set in imconfig.h
|
|
100
|
+
# - ImWchar should be a ImWchar32
|
|
101
|
+
# - IM_UNICODE_CODEPOINT_MAX should be 0x10FFFF
|
|
102
|
+
ctypedef ImWchar32 ImWchar
|
|
103
|
+
cdef enum: # No const in cython
|
|
104
|
+
IM_UNICODE_CODEPOINT_MAX = 0x10FFFF
|
|
105
|
+
|
|
106
|
+
# ====
|
|
107
|
+
# Basic scalar data types
|
|
108
|
+
ctypedef signed char ImS8
|
|
109
|
+
ctypedef unsigned char ImU8
|
|
110
|
+
ctypedef signed short ImS16
|
|
111
|
+
ctypedef unsigned short ImU16
|
|
112
|
+
ctypedef signed int ImS32
|
|
113
|
+
ctypedef unsigned int ImU32
|
|
114
|
+
ctypedef signed long long ImS64
|
|
115
|
+
ctypedef unsigned long long ImU64
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
# ====
|
|
119
|
+
# 2D vector
|
|
120
|
+
ctypedef struct ImVec2:
|
|
121
|
+
float x
|
|
122
|
+
float y
|
|
123
|
+
|
|
124
|
+
# ====
|
|
125
|
+
# 4D vector
|
|
126
|
+
ctypedef struct ImVec4:
|
|
127
|
+
float x
|
|
128
|
+
float y
|
|
129
|
+
float z
|
|
130
|
+
float w
|
|
131
|
+
|
|
132
|
+
ctypedef struct ImGuiIO:
|
|
133
|
+
|
|
134
|
+
# ====
|
|
135
|
+
# Configuration (fill once)
|
|
136
|
+
ImGuiConfigFlags ConfigFlags # ✓
|
|
137
|
+
ImGuiBackendFlags BackendFlags # ✓
|
|
138
|
+
ImVec2 DisplaySize # ✓
|
|
139
|
+
float DeltaTime # ✓
|
|
140
|
+
float IniSavingRate # ✓
|
|
141
|
+
const char* IniFilename # ✓
|
|
142
|
+
const char* LogFilename # ✓
|
|
143
|
+
float MouseDoubleClickTime # ✓
|
|
144
|
+
float MouseDoubleClickMaxDist # ✓
|
|
145
|
+
float MouseDragThreshold # ✓
|
|
146
|
+
# note: originally KeyMap[ImGuiKey_COUNT]
|
|
147
|
+
# todo: find a way to access enum var here
|
|
148
|
+
int* KeyMap
|
|
149
|
+
float KeyRepeatDelay # ✓
|
|
150
|
+
float KeyRepeatRate # ✓
|
|
151
|
+
void* UserData
|
|
152
|
+
|
|
153
|
+
ImFontAtlas* Fonts # ✓
|
|
154
|
+
float FontGlobalScale # ✓
|
|
155
|
+
bool FontAllowUserScaling # ✓
|
|
156
|
+
ImFont* FontDefault # ✗
|
|
157
|
+
ImVec2 DisplayFramebufferScale # ✓
|
|
158
|
+
#ImVec2 DisplayVisibleMin # ✓ # DEPRECIATED
|
|
159
|
+
#ImVec2 DisplayVisibleMax # ✓ # DEPRECIATED
|
|
160
|
+
|
|
161
|
+
# Miscellaneous options
|
|
162
|
+
bool MouseDrawCursor # ✓
|
|
163
|
+
bool ConfigMacOSXBehaviors # ✓
|
|
164
|
+
bool ConfigInputTextCursorBlink # ✓
|
|
165
|
+
bool ConfigDragClickToInputText # ✓
|
|
166
|
+
#bool ConfigResizeWindowsFromEdges # ✓ # RENAMED
|
|
167
|
+
bool ConfigWindowsResizeFromEdges # ✓
|
|
168
|
+
bool ConfigWindowsMoveFromTitleBarOnly # ✓
|
|
169
|
+
float ConfigMemoryCompactTimer # ✓ # RENAMED
|
|
170
|
+
|
|
171
|
+
# ====
|
|
172
|
+
# Platform Functions
|
|
173
|
+
# Platform/Render
|
|
174
|
+
const char* BackendPlatformName # ✗
|
|
175
|
+
const char* BackendRendererName # ✗
|
|
176
|
+
void* BackendPlatformUserData # ✗
|
|
177
|
+
void* BackendRendererUserData # ✗
|
|
178
|
+
void* BackendLanguageUserData # ✗
|
|
179
|
+
|
|
180
|
+
# Optional: Access OS clipboard
|
|
181
|
+
# note: callbacks may wrap arbitrary Python code so we need to
|
|
182
|
+
# propagate exceptions from them (as well as C++ exceptions)
|
|
183
|
+
const char* (*GetClipboardTextFn)(void* user_data) except + # ✓
|
|
184
|
+
void (*SetClipboardTextFn)(void* user_data, const char* text) except + # ✓
|
|
185
|
+
void* ClipboardUserData # ✗
|
|
186
|
+
|
|
187
|
+
# Optional: Notify OS Input Method Editor of the screen position of your cursor for text input position
|
|
188
|
+
void (*ImeSetInputScreenPosFn)(int x, int y) except + # ✗ # TODO: Callback
|
|
189
|
+
void* ImeWindowHandle # ✗
|
|
190
|
+
|
|
191
|
+
# ====
|
|
192
|
+
# Input - Fill before calling NewFrame()
|
|
193
|
+
ImVec2 MousePos # ✓
|
|
194
|
+
bool MouseDown[5] # ✓
|
|
195
|
+
float MouseWheel # ✓
|
|
196
|
+
float MouseWheelH # ✓
|
|
197
|
+
bool KeyCtrl # ✓
|
|
198
|
+
bool KeyShift # ✓
|
|
199
|
+
bool KeyAlt # ✓
|
|
200
|
+
bool KeySuper # ✓
|
|
201
|
+
bool KeysDown[512] # ✓
|
|
202
|
+
# note: originally NavInputs[ImGuiNavInput_COUNT]
|
|
203
|
+
# todo: find a way to access enum var here
|
|
204
|
+
float* NavInputs # ✓
|
|
205
|
+
|
|
206
|
+
# Functions
|
|
207
|
+
void AddInputCharacter(unsigned int c) except + # ✓
|
|
208
|
+
void AddInputCharacterUTF16(ImWchar16 c) except + # ✓
|
|
209
|
+
void AddInputCharactersUTF8(const char* utf8_chars) except + # ✓
|
|
210
|
+
void ClearInputCharacters() except + # ✓
|
|
211
|
+
|
|
212
|
+
# ====
|
|
213
|
+
# Output - Updated by NewFrame() or EndFrame()/Render()
|
|
214
|
+
bool WantCaptureMouse # ✓
|
|
215
|
+
bool WantCaptureKeyboard # ✓
|
|
216
|
+
bool WantTextInput # ✓
|
|
217
|
+
bool WantSetMousePos # ✓
|
|
218
|
+
bool WantSaveIniSettings # ✓
|
|
219
|
+
bool NavActive # ✓
|
|
220
|
+
bool NavVisible # ✓
|
|
221
|
+
float Framerate # ✓
|
|
222
|
+
int MetricsRenderVertices # ✓
|
|
223
|
+
int MetricsRenderIndices # ✓
|
|
224
|
+
int MetricsRenderWindows # ✓
|
|
225
|
+
int MetricsActiveWindows # ✓
|
|
226
|
+
int MetricsActiveAllocations # ✓
|
|
227
|
+
ImVec2 MouseDelta # ✓
|
|
228
|
+
|
|
229
|
+
ctypedef struct ImGuiInputTextCallbackData: # ✓
|
|
230
|
+
ImGuiInputTextFlags EventFlag # Read-only # ✓
|
|
231
|
+
ImGuiInputTextFlags Flags # Read-only # ✓
|
|
232
|
+
void* UserData # Read-only # ✓
|
|
233
|
+
ImWchar EventChar # Read-write # ✓
|
|
234
|
+
ImGuiKey EventKey # Read-only # ✓
|
|
235
|
+
char* Buf # Read-write # ✓
|
|
236
|
+
int BufTextLen # Read-write # ✓
|
|
237
|
+
int BufSize # Read-only # ✓
|
|
238
|
+
bool BufDirty # Write # ✓
|
|
239
|
+
int CursorPos # Read-write # ✓
|
|
240
|
+
int SelectionStart # Read-write # ✓
|
|
241
|
+
int SelectionEnd # Read-write # ✓
|
|
242
|
+
|
|
243
|
+
ImGuiInputTextCallbackData() except +
|
|
244
|
+
void DeleteChars(int pos, int bytes_count) except + # ✓
|
|
245
|
+
void InsertChars(int pos, const char* text, const char* text_end = NULL) except + # ✓
|
|
246
|
+
void SelectAll() except + # ✓
|
|
247
|
+
void ClearSelection() except + # ✓
|
|
248
|
+
bool HasSelection() except + # ✓
|
|
249
|
+
|
|
250
|
+
ctypedef struct ImGuiSizeCallbackData: # ✓
|
|
251
|
+
void* UserData # Read-only # ✓
|
|
252
|
+
ImVec2 Pos # Read-only # ✓
|
|
253
|
+
ImVec2 CurrentSize # Read-only # ✓
|
|
254
|
+
ImVec2 DesiredSize # Read-write # ✓
|
|
255
|
+
|
|
256
|
+
cdef cppclass ImVector[T]:
|
|
257
|
+
int Size
|
|
258
|
+
int Capacity
|
|
259
|
+
T* Data
|
|
260
|
+
|
|
261
|
+
ctypedef struct ImGuiListClipper: # ✗
|
|
262
|
+
int DisplayStart # ✗
|
|
263
|
+
int DisplayEnd # ✗
|
|
264
|
+
|
|
265
|
+
void Begin( # ✗
|
|
266
|
+
int items_count,
|
|
267
|
+
# note: optional
|
|
268
|
+
float items_height #= -1.0f
|
|
269
|
+
) except +
|
|
270
|
+
void End() except + # ✗
|
|
271
|
+
bool Step() except + # ✗
|
|
272
|
+
|
|
273
|
+
cdef cppclass ImColor: # ✗
|
|
274
|
+
ImVec4 Value # ✗
|
|
275
|
+
|
|
276
|
+
ImColor(int r, int g, int b, int a = 255) except + # ✗
|
|
277
|
+
ImColor() except + # ✗
|
|
278
|
+
ImColor(ImU32 rgba) except + # ✗
|
|
279
|
+
ImColor(float r, float g, float b, float a = 1.0) except + # ✗
|
|
280
|
+
ImColor(const ImVec4& col) except + # ✗
|
|
281
|
+
|
|
282
|
+
#operator ImU32() except + # ✗
|
|
283
|
+
#operator ImVec4() except + # ✗
|
|
284
|
+
|
|
285
|
+
ctypedef void (*ImDrawCallback)(const ImDrawList* parent_list, const ImDrawCmd* cmd) # ✗ # TODO: Callback
|
|
286
|
+
|
|
287
|
+
ctypedef struct ImDrawCmd: # ✓
|
|
288
|
+
ImVec4 ClipRect # ✓
|
|
289
|
+
ImTextureID TextureId # ✓
|
|
290
|
+
unsigned int VtxOffset # ✗
|
|
291
|
+
unsigned int IdxOffset # ✗
|
|
292
|
+
unsigned int ElemCount # ✓
|
|
293
|
+
ImDrawCallback UserCallback # ✗
|
|
294
|
+
void* UserCallbackData # ✗
|
|
295
|
+
|
|
296
|
+
|
|
297
|
+
# note: this is redefined in config-cpp/py_imconfig.h
|
|
298
|
+
# (see: https://github.com/swistakm/pyimgui/issues/138)
|
|
299
|
+
# (see: https://github.com/ocornut/meltygui_imgui/issues/1188)
|
|
300
|
+
ctypedef unsigned int ImDrawIdx
|
|
301
|
+
|
|
302
|
+
|
|
303
|
+
ctypedef struct ImDrawVert: # ✗
|
|
304
|
+
ImVec2 pos # ✗
|
|
305
|
+
ImVec2 uv # ✗
|
|
306
|
+
ImU32 col # ✗
|
|
307
|
+
|
|
308
|
+
ctypedef struct ImDrawChannel: # ✗
|
|
309
|
+
ImVector[ImDrawCmd] _CmdBuffer # ✗
|
|
310
|
+
ImVector[ImDrawIdx] _IdxBuffer # ✗
|
|
311
|
+
|
|
312
|
+
cdef cppclass ImDrawListSplitter: # ✗
|
|
313
|
+
int _Current # ✗
|
|
314
|
+
int _Count # ✗
|
|
315
|
+
ImVector[ImDrawChannel] _Channels # ✗
|
|
316
|
+
|
|
317
|
+
ImDrawListSplitter() # ✗
|
|
318
|
+
# ~ImDrawListSplitter() # ✗
|
|
319
|
+
|
|
320
|
+
void Clear() except + # ✗
|
|
321
|
+
void ClearFreeMemory() except + # ✗
|
|
322
|
+
void Split(ImDrawList* draw_list, int count) except + # ✗
|
|
323
|
+
void Merge(ImDrawList* draw_list) except + # ✗
|
|
324
|
+
void SetCurrentChannel(ImDrawList* draw_list, int channel_idx) except + # ✗
|
|
325
|
+
|
|
326
|
+
cdef cppclass ImDrawList:
|
|
327
|
+
# we map only buffer vectors since everything else is internal
|
|
328
|
+
# and right now we dont want to suport it.
|
|
329
|
+
ImVector[ImDrawCmd] CmdBuffer # ✓
|
|
330
|
+
ImVector[ImDrawIdx] IdxBuffer # ✓
|
|
331
|
+
ImVector[ImDrawVert] VtxBuffer # ✓
|
|
332
|
+
ImDrawListFlags Flags # ✓
|
|
333
|
+
|
|
334
|
+
ImDrawList(const ImDrawListSharedData* shared_data) # ✗
|
|
335
|
+
|
|
336
|
+
void PushClipRect( # ✓
|
|
337
|
+
ImVec2 clip_rect_min,
|
|
338
|
+
ImVec2 clip_rect_max,
|
|
339
|
+
# note: optional
|
|
340
|
+
bool intersect_with_current_clip_rect # = false
|
|
341
|
+
) except +
|
|
342
|
+
void PushClipRectFullScreen() except + # ✓
|
|
343
|
+
void PopClipRect() except + # ✓
|
|
344
|
+
void PushTextureID(ImTextureID texture_id) except + # ✓
|
|
345
|
+
void PopTextureID() except + # ✓
|
|
346
|
+
ImVec2 GetClipRectMin() except + # ✓
|
|
347
|
+
ImVec2 GetClipRectMax() except + # ✓
|
|
348
|
+
|
|
349
|
+
void AddLine( # ✓
|
|
350
|
+
const ImVec2& a,
|
|
351
|
+
const ImVec2& b,
|
|
352
|
+
ImU32 col,
|
|
353
|
+
# note: optional
|
|
354
|
+
float thickness # = 1.0f
|
|
355
|
+
) except +
|
|
356
|
+
|
|
357
|
+
|
|
358
|
+
void AddRect( # ✓
|
|
359
|
+
const ImVec2& a,
|
|
360
|
+
const ImVec2& b,
|
|
361
|
+
ImU32 col,
|
|
362
|
+
# note: optional
|
|
363
|
+
float rounding, # = 0.0f,
|
|
364
|
+
ImDrawFlags flags, # = 0,
|
|
365
|
+
float thickness # = 1.0f
|
|
366
|
+
) except +
|
|
367
|
+
|
|
368
|
+
|
|
369
|
+
void AddRectFilled( # ✓
|
|
370
|
+
const ImVec2& a,
|
|
371
|
+
const ImVec2& b,
|
|
372
|
+
ImU32 col,
|
|
373
|
+
# note: optional
|
|
374
|
+
float rounding, # = 0.0f
|
|
375
|
+
ImDrawFlags flags # = 0
|
|
376
|
+
) except +
|
|
377
|
+
|
|
378
|
+
void AddRectFilledMultiColor( # ✓
|
|
379
|
+
const ImVec2& p_min,
|
|
380
|
+
const ImVec2& p_max,
|
|
381
|
+
ImU32 col_upr_left,
|
|
382
|
+
ImU32 col_upr_right,
|
|
383
|
+
ImU32 col_bot_right,
|
|
384
|
+
ImU32 col_bot_left
|
|
385
|
+
) except +
|
|
386
|
+
|
|
387
|
+
void AddQuad( # ✓
|
|
388
|
+
const ImVec2& p1,
|
|
389
|
+
const ImVec2& p2,
|
|
390
|
+
const ImVec2& p3,
|
|
391
|
+
const ImVec2& p4,
|
|
392
|
+
ImU32 col,
|
|
393
|
+
# note:optional
|
|
394
|
+
float thickness # = 1.0f
|
|
395
|
+
) except +
|
|
396
|
+
|
|
397
|
+
void AddQuadFilled( # ✓
|
|
398
|
+
const ImVec2& p1,
|
|
399
|
+
const ImVec2& p2,
|
|
400
|
+
const ImVec2& p3,
|
|
401
|
+
const ImVec2& p4,
|
|
402
|
+
ImU32 col
|
|
403
|
+
) except +
|
|
404
|
+
|
|
405
|
+
void AddTriangle( # ✓
|
|
406
|
+
const ImVec2& p1,
|
|
407
|
+
const ImVec2& p2,
|
|
408
|
+
const ImVec2& p3,
|
|
409
|
+
ImU32 col,
|
|
410
|
+
# note:optional
|
|
411
|
+
float thickness # = 1.0f
|
|
412
|
+
) except +
|
|
413
|
+
|
|
414
|
+
void AddTriangleFilled( # ✓
|
|
415
|
+
const ImVec2& p1,
|
|
416
|
+
const ImVec2& p2,
|
|
417
|
+
const ImVec2& p3,
|
|
418
|
+
ImU32 col
|
|
419
|
+
) except +
|
|
420
|
+
|
|
421
|
+
void AddCircle( # ✓
|
|
422
|
+
const ImVec2& centre,
|
|
423
|
+
float radius,
|
|
424
|
+
ImU32 col,
|
|
425
|
+
# note:optional
|
|
426
|
+
int num_segments, # = 0
|
|
427
|
+
float thickness # = 1.0f
|
|
428
|
+
) except +
|
|
429
|
+
|
|
430
|
+
|
|
431
|
+
void AddCircleFilled( # ✓
|
|
432
|
+
const ImVec2& centre,
|
|
433
|
+
float radius,
|
|
434
|
+
ImU32 col,
|
|
435
|
+
# note:optional
|
|
436
|
+
int num_segments # = 0
|
|
437
|
+
) except +
|
|
438
|
+
|
|
439
|
+
void AddNgon( # ✓
|
|
440
|
+
const ImVec2& center,
|
|
441
|
+
float radius,
|
|
442
|
+
ImU32 col,
|
|
443
|
+
int num_segments,
|
|
444
|
+
# note:optional
|
|
445
|
+
float thickness # = 1.0f
|
|
446
|
+
) except +
|
|
447
|
+
|
|
448
|
+
void AddNgonFilled( # ✓
|
|
449
|
+
const ImVec2& center,
|
|
450
|
+
float radius,
|
|
451
|
+
ImU32 col,
|
|
452
|
+
int num_segments
|
|
453
|
+
) except +
|
|
454
|
+
|
|
455
|
+
void AddText( # ✓
|
|
456
|
+
const ImVec2& pos,
|
|
457
|
+
ImU32 col,
|
|
458
|
+
const char* text_begin,
|
|
459
|
+
# note:optional
|
|
460
|
+
const char* text_end # = NULL
|
|
461
|
+
) except +
|
|
462
|
+
|
|
463
|
+
void AddText( # ✗
|
|
464
|
+
const ImFont* font,
|
|
465
|
+
float font_size,
|
|
466
|
+
const ImVec2& pos,
|
|
467
|
+
ImU32 col,
|
|
468
|
+
const char* text_begin,
|
|
469
|
+
# note:optional
|
|
470
|
+
const char* text_end, # = NULL
|
|
471
|
+
float wrap_width, # = 0.0f
|
|
472
|
+
const ImVec4* cpu_fine_clip_rect # = NULL
|
|
473
|
+
) except +
|
|
474
|
+
|
|
475
|
+
void AddPolyline( # ✓
|
|
476
|
+
const ImVec2* points,
|
|
477
|
+
int num_points,
|
|
478
|
+
ImU32 col,
|
|
479
|
+
ImDrawFlags flags,
|
|
480
|
+
float thickness
|
|
481
|
+
) except +
|
|
482
|
+
|
|
483
|
+
void AddConvexPolyFilled( # ✗
|
|
484
|
+
const ImVec2* points,
|
|
485
|
+
int num_points,
|
|
486
|
+
ImU32 col
|
|
487
|
+
) except +
|
|
488
|
+
|
|
489
|
+
void AddBezierCubic( # ✓
|
|
490
|
+
const ImVec2& p1,
|
|
491
|
+
const ImVec2& p2,
|
|
492
|
+
const ImVec2& p3,
|
|
493
|
+
const ImVec2& p4,
|
|
494
|
+
ImU32 col,
|
|
495
|
+
float thickness,
|
|
496
|
+
# note: optional
|
|
497
|
+
int num_segments # = 0
|
|
498
|
+
) except +
|
|
499
|
+
|
|
500
|
+
void AddBezierQuadratic( # ✓
|
|
501
|
+
const ImVec2& p1,
|
|
502
|
+
const ImVec2& p2,
|
|
503
|
+
const ImVec2& p3,
|
|
504
|
+
ImU32 col,
|
|
505
|
+
float thickness,
|
|
506
|
+
# note: optional
|
|
507
|
+
int num_segments # = 0
|
|
508
|
+
) except +
|
|
509
|
+
|
|
510
|
+
# Image primitives
|
|
511
|
+
void AddImage(
|
|
512
|
+
ImTextureID user_texture_id,
|
|
513
|
+
const ImVec2& a,
|
|
514
|
+
const ImVec2& b,
|
|
515
|
+
# note:optional
|
|
516
|
+
const ImVec2& uv_a, # = ImVec2(0,0)
|
|
517
|
+
const ImVec2& uv_b, # = ImVec2(1,1)
|
|
518
|
+
ImU32 col # = 0xFFFFFFFF
|
|
519
|
+
) except + # ✓
|
|
520
|
+
|
|
521
|
+
void AddImageQuad( # ✗
|
|
522
|
+
ImTextureID user_texture_id,
|
|
523
|
+
const ImVec2& p1,
|
|
524
|
+
const ImVec2& p2,
|
|
525
|
+
const ImVec2& p3,
|
|
526
|
+
const ImVec2& p4,
|
|
527
|
+
# note:optional
|
|
528
|
+
const ImVec2& uv1, # = ImVec2(0, 0)
|
|
529
|
+
const ImVec2& uv2, # = ImVec2(1, 0)
|
|
530
|
+
const ImVec2& uv3, # = ImVec2(1, 1)
|
|
531
|
+
const ImVec2& uv4, # = ImVec2(0, 1)
|
|
532
|
+
ImU32 col # = 0xFFFFFFFF
|
|
533
|
+
) except +
|
|
534
|
+
|
|
535
|
+
void AddImageRounded( # ✓
|
|
536
|
+
ImTextureID user_texture_id,
|
|
537
|
+
const ImVec2& p_min,
|
|
538
|
+
const ImVec2& p_max,
|
|
539
|
+
const ImVec2& uv_min,
|
|
540
|
+
const ImVec2& uv_max,
|
|
541
|
+
ImU32 col,
|
|
542
|
+
float rounding,
|
|
543
|
+
# note:optional
|
|
544
|
+
ImDrawFlags flags # = 0
|
|
545
|
+
) except +
|
|
546
|
+
|
|
547
|
+
# Stateful path API, add points then finish with PathFillConvex() or PathStroke()
|
|
548
|
+
void PathClear() except + # ✓
|
|
549
|
+
void PathLineTo(const ImVec2& pos) except + # ✓
|
|
550
|
+
void PathLineToMergeDuplicate(const ImVec2& pos) except + # ✗
|
|
551
|
+
void PathFillConvex(ImU32 col) except + # ✓
|
|
552
|
+
void PathStroke( # ✓
|
|
553
|
+
ImU32 col,
|
|
554
|
+
# note: optional
|
|
555
|
+
ImDrawFlags flags, # = 0
|
|
556
|
+
float thickness # = 1.0f
|
|
557
|
+
) except +
|
|
558
|
+
void PathArcTo( # ✓
|
|
559
|
+
const ImVec2& center,
|
|
560
|
+
float radius,
|
|
561
|
+
float a_min,
|
|
562
|
+
float a_max,
|
|
563
|
+
# note: optional
|
|
564
|
+
int num_segments # = 0
|
|
565
|
+
) except +
|
|
566
|
+
void PathArcToFast( # ✓
|
|
567
|
+
const ImVec2& center,
|
|
568
|
+
float radius,
|
|
569
|
+
int a_min_of_12,
|
|
570
|
+
int a_max_of_12
|
|
571
|
+
) except +
|
|
572
|
+
void PathBezierCubicCurveTo( # ✗
|
|
573
|
+
const ImVec2& p2,
|
|
574
|
+
const ImVec2& p3,
|
|
575
|
+
const ImVec2& p4,
|
|
576
|
+
# note: optional
|
|
577
|
+
int num_segments # = 0
|
|
578
|
+
) except +
|
|
579
|
+
void PathBezierQuadraticCurveTo( # ✗
|
|
580
|
+
const ImVec2& p2,
|
|
581
|
+
const ImVec2& p3,
|
|
582
|
+
# note: optional
|
|
583
|
+
int num_segments # = 0
|
|
584
|
+
) except +
|
|
585
|
+
void PathRect( # ✓
|
|
586
|
+
const ImVec2& rect_min,
|
|
587
|
+
const ImVec2& rect_max,
|
|
588
|
+
# note: optional
|
|
589
|
+
float rounding, # = 0.0f
|
|
590
|
+
ImDrawFlags flags # = 0
|
|
591
|
+
) except +
|
|
592
|
+
|
|
593
|
+
# Advanced
|
|
594
|
+
void AddCallback(ImDrawCallback callback, void* callback_data) except + # ✗
|
|
595
|
+
void AddDrawCmd() except + # ✗
|
|
596
|
+
ImDrawList* CloneOutput() except + # ✗
|
|
597
|
+
|
|
598
|
+
# Advanced: Channels
|
|
599
|
+
void ChannelsSplit(int channels_count) except + # ✓
|
|
600
|
+
void ChannelsMerge() except + # ✓
|
|
601
|
+
void ChannelsSetCurrent(int idx) except + # ✓
|
|
602
|
+
|
|
603
|
+
# Advanced: Primitives allocations
|
|
604
|
+
void PrimReserve(int idx_count, int vtx_count) except + # ✓
|
|
605
|
+
void PrimUnreserve(int idx_count, int vtx_count) except + # ✓
|
|
606
|
+
void PrimRect(const ImVec2& a, const ImVec2& b, ImU32 col) except + # ✓
|
|
607
|
+
void PrimRectUV(const ImVec2& a, const ImVec2& b, const ImVec2& uv_a, const ImVec2& uv_b, ImU32 col) except + # ✓
|
|
608
|
+
void PrimQuadUV(const ImVec2& a, const ImVec2& b, const ImVec2& c, const ImVec2& d, const ImVec2& uv_a, const ImVec2& uv_b, const ImVec2& uv_c, const ImVec2& uv_d, ImU32 col) except + # ✓
|
|
609
|
+
inline void PrimWriteVtx(const ImVec2& pos, const ImVec2& uv, ImU32 col) except + # ✓
|
|
610
|
+
inline void PrimWriteIdx(ImDrawIdx idx) except + # ✓
|
|
611
|
+
inline void PrimVtx(const ImVec2& pos, const ImVec2& uv, ImU32 col) except + # ✓
|
|
612
|
+
|
|
613
|
+
|
|
614
|
+
ctypedef struct ImDrawData: # ✓
|
|
615
|
+
bool Valid # ✓
|
|
616
|
+
ImDrawList** CmdLists # ✓
|
|
617
|
+
int CmdListsCount # ✓
|
|
618
|
+
int TotalIdxCount # ✓
|
|
619
|
+
int TotalVtxCount # ✓
|
|
620
|
+
ImVec2 DisplayPos # ✓
|
|
621
|
+
ImVec2 DisplaySize # ✓
|
|
622
|
+
ImVec2 FramebufferScale # ✓
|
|
623
|
+
|
|
624
|
+
void DeIndexAllBuffers() except + # ✓
|
|
625
|
+
void ScaleClipRects(const ImVec2&) except + # ✓
|
|
626
|
+
|
|
627
|
+
cdef cppclass ImFontConfig:
|
|
628
|
+
void* FontData # ✗
|
|
629
|
+
int FontDataSize # ✗
|
|
630
|
+
bool FontDataOwnedByAtlas # ✗
|
|
631
|
+
int FontNo # ✗
|
|
632
|
+
float SizePixels # ✗
|
|
633
|
+
int OversampleH # ✗
|
|
634
|
+
int OversampleV # ✗
|
|
635
|
+
bool PixelSnapH # ✗
|
|
636
|
+
ImVec2 GlyphExtraSpacing # ✗
|
|
637
|
+
ImVec2 GlyphOffset # ✗
|
|
638
|
+
const ImWchar* GlyphRanges # ✗
|
|
639
|
+
float GlyphMinAdvanceX # ✗
|
|
640
|
+
float GlyphMaxAdvanceX # ✗
|
|
641
|
+
bool MergeMode # ✗
|
|
642
|
+
unsigned int RasterizerFlags # ✗
|
|
643
|
+
float RasterizerMultiply # ✗
|
|
644
|
+
ImWchar EllipsisChar # ✗
|
|
645
|
+
|
|
646
|
+
ImFontConfig() # ✗
|
|
647
|
+
|
|
648
|
+
ctypedef struct ImFontGlyph: # ✗
|
|
649
|
+
unsigned int Codepoint # bitfield : 31 # ✗
|
|
650
|
+
unsigned int Visible # bitfield : 1 # ✗
|
|
651
|
+
float AdvanceX # ✗
|
|
652
|
+
float X0 # ✗
|
|
653
|
+
float Y0 # ✗
|
|
654
|
+
float X1 # ✗
|
|
655
|
+
float Y1 # ✗
|
|
656
|
+
float U0 # ✗
|
|
657
|
+
float V0 # ✗
|
|
658
|
+
float U1 # ✗
|
|
659
|
+
float V1 # ✗
|
|
660
|
+
|
|
661
|
+
ctypedef struct ImFontGlyphRangesBuilder: # ✗
|
|
662
|
+
ImVector[ImU32] UsedChars
|
|
663
|
+
|
|
664
|
+
# ImFontGlyphRangesBuilder() # ✗
|
|
665
|
+
void Clear() except + # ✗
|
|
666
|
+
bool GetBit(size_t n) except + # ✗
|
|
667
|
+
void SetBit(size_t n) except + # ✗
|
|
668
|
+
void AddChar(ImWchar c) except + # ✗
|
|
669
|
+
void AddText( # ✗
|
|
670
|
+
const char* text,
|
|
671
|
+
# note: optional
|
|
672
|
+
const char* text_end # = NULL
|
|
673
|
+
) except +
|
|
674
|
+
void AddRanges(const ImWchar* ranges) except + # ✗
|
|
675
|
+
void BuildRanges(ImVector[ImWchar]* out_ranges) except + # ✗
|
|
676
|
+
|
|
677
|
+
ctypedef struct ImFontAtlasCustomRect: # ✗
|
|
678
|
+
unsigned short Width, Height; # ✗
|
|
679
|
+
unsigned short X, Y; # ✗
|
|
680
|
+
unsigned int GlyphID; # ✗
|
|
681
|
+
float GlyphAdvanceX; # ✗
|
|
682
|
+
ImVec2 GlyphOffset; # ✗
|
|
683
|
+
ImFont* Font; # ✗
|
|
684
|
+
ImFontAtlasCustomRect() except + # ✗
|
|
685
|
+
bool IsPacked() except + # ✗
|
|
686
|
+
|
|
687
|
+
|
|
688
|
+
ctypedef struct ImFont: # ✗
|
|
689
|
+
|
|
690
|
+
# Members: Hot ~20/24 bytes (for CalcTextSize)
|
|
691
|
+
ImVector[float] IndexAdvanceX # ✗
|
|
692
|
+
float FallbackAdvanceX# ✗
|
|
693
|
+
float FontSize # ✗
|
|
694
|
+
|
|
695
|
+
# Members: Hot ~28/40 bytes (for CalcTextSize + render loop)
|
|
696
|
+
ImVector[ImWchar] IndexLookup # ✗
|
|
697
|
+
ImVector[ImFontGlyph] Glyphs # ✗
|
|
698
|
+
const ImFontGlyph* FallbackGlyph # ✗
|
|
699
|
+
|
|
700
|
+
# Members: Cold ~32/40 bytes
|
|
701
|
+
ImFontAtlas* ContainerAtlas # ✗
|
|
702
|
+
const ImFontConfig* ConfigData # ✗
|
|
703
|
+
short ConfigDataCount # ✗
|
|
704
|
+
ImWchar FallbackChar # ✗
|
|
705
|
+
ImWchar EllipsisChar # ✗
|
|
706
|
+
bool DirtyLookupTables # ✗
|
|
707
|
+
float Scale # ✗
|
|
708
|
+
float Ascent # ✗
|
|
709
|
+
float Descent # ✗
|
|
710
|
+
int MetricsTotalSurface # ✗
|
|
711
|
+
ImU8 Used4kPagesMap[(IM_UNICODE_CODEPOINT_MAX+1)/4096/8] # ✗
|
|
712
|
+
|
|
713
|
+
# Methods
|
|
714
|
+
const ImFontGlyph*FindGlyph(ImWchar c) except + # ✗
|
|
715
|
+
const ImFontGlyph*FindGlyphNoFallback(ImWchar c) except + # ✗
|
|
716
|
+
float GetCharAdvance(ImWchar c) except + # ✗
|
|
717
|
+
bool IsLoaded() except + # ✗
|
|
718
|
+
const char* GetDebugName() except + # ✗
|
|
719
|
+
|
|
720
|
+
ImVec2 CalcTextSizeA( # ✗
|
|
721
|
+
float size,
|
|
722
|
+
float max_width,
|
|
723
|
+
float wrap_width,
|
|
724
|
+
const char* text_begin,
|
|
725
|
+
# note: optional
|
|
726
|
+
const char* text_end, # = NULL,
|
|
727
|
+
const char** remaining # = NULL
|
|
728
|
+
) except +
|
|
729
|
+
const char* CalcWordWrapPositionA( # ✗
|
|
730
|
+
float scale,
|
|
731
|
+
const char* text,
|
|
732
|
+
const char* text_end,
|
|
733
|
+
float wrap_width
|
|
734
|
+
) except +
|
|
735
|
+
void RenderChar( # ✗
|
|
736
|
+
ImDrawList* draw_list,
|
|
737
|
+
float size,
|
|
738
|
+
ImVec2 pos,
|
|
739
|
+
ImU32 col,
|
|
740
|
+
ImWchar c
|
|
741
|
+
) except +
|
|
742
|
+
void RenderText( # ✗
|
|
743
|
+
ImDrawList* draw_list,
|
|
744
|
+
float size,
|
|
745
|
+
ImVec2 pos,
|
|
746
|
+
ImU32 col,
|
|
747
|
+
const ImVec4& clip_rect,
|
|
748
|
+
const char* text_begin,
|
|
749
|
+
const char* text_end,
|
|
750
|
+
# note: optional
|
|
751
|
+
float wrap_width, # = 0.0f,
|
|
752
|
+
bool cpu_fine_clip # = false
|
|
753
|
+
) except +
|
|
754
|
+
|
|
755
|
+
ctypedef struct ImFontAtlas: # ✓
|
|
756
|
+
ImFontAtlasFlags Flags # ✗
|
|
757
|
+
void* TexID # ✓
|
|
758
|
+
int TexDesiredWidth # ✓
|
|
759
|
+
int TexGlyphPadding # ✗
|
|
760
|
+
bool Locked # ✗
|
|
761
|
+
|
|
762
|
+
# Internals
|
|
763
|
+
int TexWidth # ✓
|
|
764
|
+
int TexHeight # ✓
|
|
765
|
+
|
|
766
|
+
ImFont* AddFont(const ImFontConfig* font_cfg) except + # ✗
|
|
767
|
+
|
|
768
|
+
|
|
769
|
+
ImFont* AddFontDefault( # ✓
|
|
770
|
+
# note: optional
|
|
771
|
+
const ImFontConfig* font_cfg
|
|
772
|
+
) except +
|
|
773
|
+
ImFont* AddFontFromFileTTF( # ✓
|
|
774
|
+
const char* filename, float size_pixels,
|
|
775
|
+
# note: optional
|
|
776
|
+
const ImFontConfig* font_cfg,
|
|
777
|
+
const ImWchar* glyph_ranges
|
|
778
|
+
) except +
|
|
779
|
+
ImFont* AddFontFromMemoryTTF( # ✗
|
|
780
|
+
void* font_data,
|
|
781
|
+
int font_size,
|
|
782
|
+
float size_pixels,
|
|
783
|
+
# note: optional
|
|
784
|
+
const ImFontConfig* font_cfg, # = NULL
|
|
785
|
+
const ImWchar* glyph_ranges # = NULL
|
|
786
|
+
) except +
|
|
787
|
+
ImFont* AddFontFromMemoryCompressedTTF( # ✗
|
|
788
|
+
const void* compressed_font_data,
|
|
789
|
+
int compressed_font_size,
|
|
790
|
+
float size_pixels,
|
|
791
|
+
# note: optional
|
|
792
|
+
const ImFontConfig* font_cfg, # = NULL
|
|
793
|
+
const ImWchar* glyph_ranges # = NULL
|
|
794
|
+
) except +
|
|
795
|
+
ImFont* AddFontFromMemoryCompressedBase85TTF( # ✗
|
|
796
|
+
const char* compressed_font_data_base85,
|
|
797
|
+
float size_pixels,
|
|
798
|
+
# note: optional
|
|
799
|
+
const ImFontConfig* font_cfg, # = NULL
|
|
800
|
+
const ImWchar* glyph_ranges # = NULL
|
|
801
|
+
) except +
|
|
802
|
+
|
|
803
|
+
void ClearInputData() except + # ✓
|
|
804
|
+
void ClearTexData() except + # ✓
|
|
805
|
+
void ClearFonts() except + # ✓
|
|
806
|
+
void Clear() except + # ✓
|
|
807
|
+
|
|
808
|
+
|
|
809
|
+
bool Build() except + # ✗
|
|
810
|
+
void GetTexDataAsAlpha8(unsigned char**, int*, int*, int* = NULL) except + # ✓
|
|
811
|
+
void GetTexDataAsRGBA32(unsigned char**, int*, int*, int* = NULL) except + # ✓
|
|
812
|
+
bool IsBuilt() except + # ✗
|
|
813
|
+
void SetTexID(ImTextureID id) except + # ✗
|
|
814
|
+
|
|
815
|
+
const ImWchar* GetGlyphRangesDefault() except + # ✓
|
|
816
|
+
const ImWchar* GetGlyphRangesKorean() except + # ✓
|
|
817
|
+
const ImWchar* GetGlyphRangesJapanese() except + # ✓
|
|
818
|
+
const ImWchar* GetGlyphRangesChineseFull() except + # ✓
|
|
819
|
+
const ImWchar* GetGlyphRangesChineseSimplifiedCommon() except + # ✓
|
|
820
|
+
const ImWchar* GetGlyphRangesCyrillic() except + # ✓
|
|
821
|
+
const ImWchar* GetGlyphRangesThai() except + # ✓
|
|
822
|
+
const ImWchar* GetGlyphRangesVietnamese() except + # ✓
|
|
823
|
+
|
|
824
|
+
# ====
|
|
825
|
+
# [BETA] Custom Rectangles/Glyphs API
|
|
826
|
+
int AddCustomRectRegular(int width, int height) except + # ✗
|
|
827
|
+
int AddCustomRectFontGlyph( # ✗
|
|
828
|
+
ImFont* font, ImWchar id,
|
|
829
|
+
int width, int height,
|
|
830
|
+
float advance_x,
|
|
831
|
+
# note: optional
|
|
832
|
+
const ImVec2& offset # = ImVec2(0, 0)
|
|
833
|
+
) except +
|
|
834
|
+
ImFontAtlasCustomRect* GetCustomRectByIndex(int index) except + # ✗
|
|
835
|
+
|
|
836
|
+
ctypedef struct ImGuiStorage: # ✗
|
|
837
|
+
pass
|
|
838
|
+
|
|
839
|
+
cdef cppclass ImGuiStyle:
|
|
840
|
+
float Alpha # ✓
|
|
841
|
+
ImVec2 WindowPadding # ✓
|
|
842
|
+
float WindowRounding # ✓
|
|
843
|
+
float WindowBorderSize # ✓
|
|
844
|
+
ImVec2 WindowMinSize # ✓
|
|
845
|
+
ImVec2 WindowTitleAlign # ✓
|
|
846
|
+
ImGuiDir WindowMenuButtonPosition # ✓
|
|
847
|
+
float ChildRounding # ✓
|
|
848
|
+
float ChildBorderSize # ✓
|
|
849
|
+
float PopupRounding # ✓
|
|
850
|
+
float PopupBorderSize # ✓
|
|
851
|
+
ImVec2 FramePadding # ✓
|
|
852
|
+
float FrameRounding # ✓
|
|
853
|
+
float FrameBorderSize # ✓
|
|
854
|
+
ImVec2 ItemSpacing # ✓
|
|
855
|
+
ImVec2 ItemInnerSpacing # ✓
|
|
856
|
+
ImVec2 CellPadding # ✓
|
|
857
|
+
ImVec2 TouchExtraPadding # ✓
|
|
858
|
+
float IndentSpacing # ✓
|
|
859
|
+
float ColumnsMinSpacing # ✓
|
|
860
|
+
float ScrollbarSize # ✓
|
|
861
|
+
float ScrollbarRounding # ✓
|
|
862
|
+
float GrabMinSize # ✓
|
|
863
|
+
float GrabRounding # ✓
|
|
864
|
+
float LogSliderDeadzone # ✓
|
|
865
|
+
float TabRounding # ✓
|
|
866
|
+
float TabBorderSize # ✓
|
|
867
|
+
float TabMinWidthForCloseButton # ✓
|
|
868
|
+
ImGuiDir ColorButtonPosition # ✓
|
|
869
|
+
ImVec2 ButtonTextAlign # ✓
|
|
870
|
+
ImVec2 SelectableTextAlign # ✓
|
|
871
|
+
ImVec2 DisplayWindowPadding # ✓
|
|
872
|
+
ImVec2 DisplaySafeAreaPadding # ✓
|
|
873
|
+
float MouseCursorScale # ✓
|
|
874
|
+
bool AntiAliasedLines # ✓
|
|
875
|
+
bool AntiAliasedLinesUseTex # ✓
|
|
876
|
+
bool AntiAliasedFill # ✓
|
|
877
|
+
float CurveTessellationTol # ✓
|
|
878
|
+
float CircleTessellationMaxError # ✓
|
|
879
|
+
|
|
880
|
+
# note: originally Colors[ImGuiCol_COUNT]
|
|
881
|
+
# todo: find a way to access enum var here
|
|
882
|
+
ImVec4* Colors
|
|
883
|
+
|
|
884
|
+
void ScaleAllSizes(float scale_factor) except + # ✗
|
|
885
|
+
|
|
886
|
+
ctypedef struct ImGuiPayload: # ✗
|
|
887
|
+
void* Data # ✓
|
|
888
|
+
int DataSize # ✓
|
|
889
|
+
|
|
890
|
+
bool IsDataType(const char* type) except + # ✗
|
|
891
|
+
bool IsPreview() except + # ✗
|
|
892
|
+
bool IsDelivery() except + # ✗
|
|
893
|
+
|
|
894
|
+
ctypedef struct ImGuiTableColumnSortSpecs: # ✓
|
|
895
|
+
ImGuiID ColumnUserID # ✓
|
|
896
|
+
ImS16 ColumnIndex # ✓
|
|
897
|
+
ImS16 SortOrder # ✓
|
|
898
|
+
ImGuiSortDirection SortDirection # ✓
|
|
899
|
+
|
|
900
|
+
ImGuiTableColumnSortSpecs() except + # ✗
|
|
901
|
+
|
|
902
|
+
ctypedef struct ImGuiTableSortSpecs: # ✓
|
|
903
|
+
const ImGuiTableColumnSortSpecs* Specs # ✓
|
|
904
|
+
int SpecsCount # ✓
|
|
905
|
+
bool SpecsDirty # ✓
|
|
906
|
+
|
|
907
|
+
ImGuiTableSortSpecs() except + # ✗
|
|
908
|
+
|
|
909
|
+
ctypedef struct ImGuiContext:
|
|
910
|
+
pass
|
|
911
|
+
|
|
912
|
+
ctypedef struct ImGuiViewport: # ✓
|
|
913
|
+
ImGuiViewportFlags Flags # ✓
|
|
914
|
+
ImVec2 Pos # ✓
|
|
915
|
+
ImVec2 Size # ✓
|
|
916
|
+
ImVec2 WorkPos # ✓
|
|
917
|
+
ImVec2 WorkSize # ✓
|
|
918
|
+
|
|
919
|
+
ImVec2 GetCenter() except + # ✓
|
|
920
|
+
ImVec2 GetWorkCenter() except + # ✓
|
|
921
|
+
|
|
922
|
+
cdef extern from "imgui.h" namespace "ImGui":
|
|
923
|
+
|
|
924
|
+
# ====
|
|
925
|
+
# Context creation and access
|
|
926
|
+
ImGuiContext* CreateContext( # ✓
|
|
927
|
+
# note: optional
|
|
928
|
+
ImFontAtlas* shared_font_atlas # = NULL
|
|
929
|
+
) except +
|
|
930
|
+
void DestroyContext(# ✓
|
|
931
|
+
# note: optional
|
|
932
|
+
ImGuiContext* ctx # = NULL
|
|
933
|
+
) except +
|
|
934
|
+
ImGuiContext* GetCurrentContext() except + # ✓
|
|
935
|
+
void SetCurrentContext(ImGuiContext* ctx) except + # ✓
|
|
936
|
+
|
|
937
|
+
# ====
|
|
938
|
+
# Main
|
|
939
|
+
ImGuiIO& GetIO() except + # ✓
|
|
940
|
+
ImGuiStyle& GetStyle() except + # ✓
|
|
941
|
+
void NewFrame() except + # ✓
|
|
942
|
+
void EndFrame() except + # ✓
|
|
943
|
+
# note: Render runs callbacks that may be arbitrary Python code
|
|
944
|
+
# so we need to propagate exceptions from them
|
|
945
|
+
void Render() except + # ✓
|
|
946
|
+
ImDrawData* GetDrawData() except + # ✓
|
|
947
|
+
|
|
948
|
+
# TODO: Shouldn't this be elsewhere? Member of ImGuiStyle
|
|
949
|
+
void ScaleAllSizes(float scale_factor) except + # ✗
|
|
950
|
+
|
|
951
|
+
# ====
|
|
952
|
+
# Demo, Debug, Information
|
|
953
|
+
void ShowDemoWindow(bool* p_open) except + # ✓
|
|
954
|
+
void ShowDemoWindow() except + # ✓
|
|
955
|
+
void ShowMetricsWindow(bool* p_open) except + # ✓
|
|
956
|
+
void ShowMetricsWindow() except + # ✓
|
|
957
|
+
void ShowAboutWindow(bool* p_open) except + # ✓
|
|
958
|
+
void ShowAboutWindow() except + # ✓
|
|
959
|
+
void ShowStyleEditor(ImGuiStyle* ref) except + # ✓
|
|
960
|
+
void ShowStyleEditor() except + # ✓
|
|
961
|
+
bool ShowStyleSelector(const char* label) except + # ✓
|
|
962
|
+
void ShowFontSelector(const char*) except + # ✓
|
|
963
|
+
void ShowUserGuide() except + # ✓
|
|
964
|
+
const char* GetVersion() except + # ✓
|
|
965
|
+
|
|
966
|
+
# ====
|
|
967
|
+
# Styles
|
|
968
|
+
void StyleColorsDark(ImGuiStyle* dst) except + # ✓
|
|
969
|
+
void StyleColorsLight(ImGuiStyle* dst) except + # ✓
|
|
970
|
+
void StyleColorsClassic(ImGuiStyle* dst) except + # ✓
|
|
971
|
+
|
|
972
|
+
# ====
|
|
973
|
+
# Window
|
|
974
|
+
bool Begin( # ✓
|
|
975
|
+
const char* name,
|
|
976
|
+
# note: optional
|
|
977
|
+
bool* p_open, # = NULL
|
|
978
|
+
ImGuiWindowFlags # = 0
|
|
979
|
+
) except +
|
|
980
|
+
# bool Begin(const char*, bool*, const ImVec2&, float, ImGuiWindowFlags) # DEPRECIATED
|
|
981
|
+
void End() except + # ✓
|
|
982
|
+
|
|
983
|
+
# ====
|
|
984
|
+
# Child Windows
|
|
985
|
+
bool BeginChild( # ✓
|
|
986
|
+
const char* str_id,
|
|
987
|
+
# note: optional
|
|
988
|
+
const ImVec2& size, # = ImVec2(0,0)
|
|
989
|
+
bool border, # = False
|
|
990
|
+
ImGuiWindowFlags flags # = 0
|
|
991
|
+
) except +
|
|
992
|
+
# bool BeginChild(const char*, const ImVec2&, bool) except + # ✓ # NOT NECESSARY ?
|
|
993
|
+
# bool BeginChild(const char*, const ImVec2&) except + # ✓ # NOT NECESSARY ?
|
|
994
|
+
# bool BeginChild(const char*) except + # ✓ # NOT NECESSARY ?
|
|
995
|
+
bool BeginChild( # ✓
|
|
996
|
+
ImGuiID id,
|
|
997
|
+
# note: optional
|
|
998
|
+
const ImVec2& size, # = ImVec2(0,0)
|
|
999
|
+
bool border, # = False
|
|
1000
|
+
ImGuiWindowFlags flags # = 0
|
|
1001
|
+
) except +
|
|
1002
|
+
# bool BeginChild(ImGuiID, const ImVec2&, bool) except + # ✓ # NOT NECESSARY ?
|
|
1003
|
+
# bool BeginChild(ImGuiID, const ImVec2&) except + # ✓ # NOT NECESSARY ?
|
|
1004
|
+
# bool BeginChild(ImGuiID) except + # ✓ # NOT NECESSARY ?
|
|
1005
|
+
void EndChild() except + # ✓
|
|
1006
|
+
|
|
1007
|
+
# ====
|
|
1008
|
+
# Windows Utilities
|
|
1009
|
+
bool IsWindowAppearing() except + # ✓
|
|
1010
|
+
bool IsWindowCollapsed() except + # ✓
|
|
1011
|
+
bool IsWindowFocused( # ✓
|
|
1012
|
+
# note: optional
|
|
1013
|
+
ImGuiFocusedFlags flags # = 0
|
|
1014
|
+
) except +
|
|
1015
|
+
bool IsWindowHovered( # ✓
|
|
1016
|
+
# note: optional
|
|
1017
|
+
ImGuiFocusedFlags flags # = 0
|
|
1018
|
+
) except +
|
|
1019
|
+
ImDrawList* GetWindowDrawList() except + # ✓
|
|
1020
|
+
ImDrawList* GetOverlayDrawList() except + # ✓ # OBSOLETED in 1.69 (from Mar 2019)
|
|
1021
|
+
ImVec2 GetWindowPos() except + # ✓
|
|
1022
|
+
ImVec2 GetWindowSize() except + # ✓
|
|
1023
|
+
float GetWindowWidth() except + # ✓
|
|
1024
|
+
float GetWindowHeight() except + # ✓
|
|
1025
|
+
|
|
1026
|
+
void SetNextWindowPos( # ✓ note: overrides ommited
|
|
1027
|
+
const ImVec2& pos,
|
|
1028
|
+
# note: optional
|
|
1029
|
+
ImGuiCond cond, # = 0
|
|
1030
|
+
const ImVec2& pivot # = ImVec2(0, 0)
|
|
1031
|
+
) except +
|
|
1032
|
+
void SetNextWindowSize( # ✓ note: overrides ommited
|
|
1033
|
+
const ImVec2& size,
|
|
1034
|
+
# note: optional
|
|
1035
|
+
ImGuiCond cond # = 0
|
|
1036
|
+
) except +
|
|
1037
|
+
void SetNextWindowSizeConstraints( # ✓
|
|
1038
|
+
const ImVec2& size_min,
|
|
1039
|
+
const ImVec2& size_max,
|
|
1040
|
+
# note: optional
|
|
1041
|
+
ImGuiSizeCallback custom_callback, # = NULL
|
|
1042
|
+
void* custom_callback_data # = NULL
|
|
1043
|
+
) except +
|
|
1044
|
+
void SetNextWindowContentSize(const ImVec2& size) except + # ✓
|
|
1045
|
+
void SetNextWindowCollapsed( # ✓
|
|
1046
|
+
bool collapsed,
|
|
1047
|
+
# note: optional
|
|
1048
|
+
ImGuiCond cond # = 0
|
|
1049
|
+
) except +
|
|
1050
|
+
void SetNextWindowFocus() except + # ✓
|
|
1051
|
+
void SetNextWindowBgAlpha(float alpha) except + # ✓
|
|
1052
|
+
void SetWindowPos( # ✓
|
|
1053
|
+
const ImVec2& pos,
|
|
1054
|
+
# note: optional
|
|
1055
|
+
ImGuiCond cond # = 0
|
|
1056
|
+
) except +
|
|
1057
|
+
void SetWindowSize( # ✓
|
|
1058
|
+
const ImVec2& size,
|
|
1059
|
+
# note: optional
|
|
1060
|
+
ImGuiCond cond # = 0
|
|
1061
|
+
) except +
|
|
1062
|
+
void SetWindowCollapsed( # ✓
|
|
1063
|
+
bool collapsed,
|
|
1064
|
+
# note: optional
|
|
1065
|
+
ImGuiCond cond # = 0
|
|
1066
|
+
) except +
|
|
1067
|
+
void SetWindowFocus() except + # ✓
|
|
1068
|
+
void SetWindowFontScale(float scale) except + # ✓
|
|
1069
|
+
void SetWindowPos( # ✓
|
|
1070
|
+
const char* name, const ImVec2& pos,
|
|
1071
|
+
# note: optional
|
|
1072
|
+
ImGuiCond cond # = 0
|
|
1073
|
+
) except +
|
|
1074
|
+
void SetWindowSize( # ✓
|
|
1075
|
+
const char* name, const ImVec2& size, ImGuiCond
|
|
1076
|
+
cond # = 0
|
|
1077
|
+
) except +
|
|
1078
|
+
void SetWindowCollapsed( # ✓
|
|
1079
|
+
const char* name, bool collapsed,
|
|
1080
|
+
# note: optional
|
|
1081
|
+
ImGuiCond cond # = 0
|
|
1082
|
+
) except +
|
|
1083
|
+
void SetWindowFocus(const char* name) except + # ✓
|
|
1084
|
+
|
|
1085
|
+
# ====
|
|
1086
|
+
# Content region
|
|
1087
|
+
ImVec2 GetContentRegionAvail() except + # ✓
|
|
1088
|
+
ImVec2 GetContentRegionMax() except + # ✓
|
|
1089
|
+
float GetContentRegionAvailWidth() except + # ✓ # OBSOLETED in 1.70 (from May 2019)
|
|
1090
|
+
ImVec2 GetWindowContentRegionMin() except + # ✓
|
|
1091
|
+
ImVec2 GetWindowContentRegionMax() except + # ✓
|
|
1092
|
+
float GetWindowContentRegionWidth() except + # ✓
|
|
1093
|
+
|
|
1094
|
+
# ====
|
|
1095
|
+
# Windows Scrolling
|
|
1096
|
+
float GetScrollX() except + # ✓
|
|
1097
|
+
float GetScrollY() except + # ✓
|
|
1098
|
+
void SetScrollX(float scroll_x) except + # ✓
|
|
1099
|
+
void SetScrollY(float scroll_y) except + # ✓
|
|
1100
|
+
float GetScrollMaxX() except + # ✓
|
|
1101
|
+
float GetScrollMaxY() except + # ✓
|
|
1102
|
+
# void SetScrollHere( # ✓ # OBSOLETED in 1.66 (from Sep 2018) # REMOVED in 1.82 (from Mars 2021)
|
|
1103
|
+
# # note: optional
|
|
1104
|
+
# float center_y_ratio # = 0.5
|
|
1105
|
+
#) except +
|
|
1106
|
+
void SetScrollHereX( # ✓
|
|
1107
|
+
# note: optional
|
|
1108
|
+
float center_x_ratio # = 0.5
|
|
1109
|
+
) except +
|
|
1110
|
+
void SetScrollHereY( # ✓
|
|
1111
|
+
# note: optional
|
|
1112
|
+
float center_y_ratio # = 0.5
|
|
1113
|
+
) except +
|
|
1114
|
+
void SetScrollFromPosX( # ✓
|
|
1115
|
+
float local_x,
|
|
1116
|
+
# note: optional
|
|
1117
|
+
float center_x_ratio # = 0.5
|
|
1118
|
+
) except +
|
|
1119
|
+
void SetScrollFromPosY( # ✓
|
|
1120
|
+
float local_y,
|
|
1121
|
+
# note: optional
|
|
1122
|
+
float center_y_ratio # = 0.5
|
|
1123
|
+
) except +
|
|
1124
|
+
|
|
1125
|
+
# ====
|
|
1126
|
+
# Parameters stacks (shared)
|
|
1127
|
+
void PushFont(ImFont*) except + # ✓
|
|
1128
|
+
void PopFont() except + # ✓
|
|
1129
|
+
void PushStyleColor(ImGuiCol idx, ImU32 col) except + # ✗
|
|
1130
|
+
void PushStyleColor(ImGuiCol idx, const ImVec4&) except + # ✓
|
|
1131
|
+
void PopStyleColor( # ✓
|
|
1132
|
+
# note: optional
|
|
1133
|
+
int count # = 1
|
|
1134
|
+
) except +
|
|
1135
|
+
void PushStyleVar(ImGuiStyleVar, float) except + # ✓
|
|
1136
|
+
void PushStyleVar(ImGuiStyleVar, const ImVec2&) except + # ✓
|
|
1137
|
+
void PopStyleVar( # ✓
|
|
1138
|
+
# note: optional
|
|
1139
|
+
int count # = 1
|
|
1140
|
+
) except +
|
|
1141
|
+
|
|
1142
|
+
void PushAllowKeyboardFocus(bool allow_keyboard_focus) except + # ✓
|
|
1143
|
+
void PopAllowKeyboardFocus() except + # ✓
|
|
1144
|
+
void PushButtonRepeat(bool repeat) except + # ✓
|
|
1145
|
+
void PopButtonRepeat() except + # ✓
|
|
1146
|
+
|
|
1147
|
+
# ====
|
|
1148
|
+
# Parameters stacks (current window)
|
|
1149
|
+
void PushItemWidth(float item_width) except + # ✓
|
|
1150
|
+
void PopItemWidth() except + # ✓
|
|
1151
|
+
void SetNextItemWidth(float item_width) except + # ✓
|
|
1152
|
+
float CalcItemWidth() except + # ✓
|
|
1153
|
+
void PushTextWrapPos( # ✓
|
|
1154
|
+
# note: optional
|
|
1155
|
+
float wrap_local_pos_x # = 0.0
|
|
1156
|
+
) except +
|
|
1157
|
+
void PopTextWrapPos() except + # ✓
|
|
1158
|
+
|
|
1159
|
+
# ===
|
|
1160
|
+
# Style read access
|
|
1161
|
+
ImFont* GetFont() except + # ✗
|
|
1162
|
+
float GetFontSize() except + # ✓
|
|
1163
|
+
ImVec2 GetFontTexUvWhitePixel() except + # ✓
|
|
1164
|
+
ImU32 GetColorU32( # ✓
|
|
1165
|
+
ImGuiCol idx,
|
|
1166
|
+
# note: optional
|
|
1167
|
+
float alpha_mul # = 1.0
|
|
1168
|
+
) except +
|
|
1169
|
+
ImU32 GetColorU32(const ImVec4& col) except + # ✓
|
|
1170
|
+
ImU32 GetColorU32(ImU32 col) except + # ✓
|
|
1171
|
+
ImVec4& GetStyleColorVec4(ImGuiCol idx) except + # ✓
|
|
1172
|
+
|
|
1173
|
+
# ====
|
|
1174
|
+
# Cursor / Layout
|
|
1175
|
+
void Separator() except + # ✓
|
|
1176
|
+
void SameLine( # ✓
|
|
1177
|
+
# note: optional
|
|
1178
|
+
float offset_from_start_x, # = 0.0
|
|
1179
|
+
float spacing # = -1.0 # API CHANGE
|
|
1180
|
+
) except +
|
|
1181
|
+
void NewLine() except + # ✓
|
|
1182
|
+
void Spacing() except + # ✓
|
|
1183
|
+
void Dummy(const ImVec2& size) except + # ✓
|
|
1184
|
+
void Indent( # ✓
|
|
1185
|
+
# note: optional
|
|
1186
|
+
float indent_w # = 0.0
|
|
1187
|
+
) except +
|
|
1188
|
+
void Unindent( # ✓
|
|
1189
|
+
# note: optional
|
|
1190
|
+
float indent_w # = 0.0
|
|
1191
|
+
) except +
|
|
1192
|
+
void BeginGroup() except + # ✓
|
|
1193
|
+
void EndGroup() except + # ✓
|
|
1194
|
+
ImVec2 GetCursorPos() except + # ✓
|
|
1195
|
+
float GetCursorPosX() except + # ✓
|
|
1196
|
+
float GetCursorPosY() except + # ✓
|
|
1197
|
+
void SetCursorPos(const ImVec2& local_pos) except + # ✓
|
|
1198
|
+
void SetCursorPosX(float local_x) except + # ✓
|
|
1199
|
+
void SetCursorPosY(float local_y) except + # ✓
|
|
1200
|
+
ImVec2 GetCursorStartPos() except + # ✓
|
|
1201
|
+
ImVec2 GetCursorScreenPos() except + # ✓
|
|
1202
|
+
void SetCursorScreenPos(const ImVec2& pos) except + # ✓
|
|
1203
|
+
void AlignTextToFramePadding() except + # ✓
|
|
1204
|
+
float GetTextLineHeight() except + # ✓
|
|
1205
|
+
float GetTextLineHeightWithSpacing() except + # ✓
|
|
1206
|
+
float GetFrameHeight() except + # ✓
|
|
1207
|
+
float GetFrameHeightWithSpacing() except + # ✓
|
|
1208
|
+
|
|
1209
|
+
# ====
|
|
1210
|
+
# ID stack/scopes
|
|
1211
|
+
void PushID(const char* str_id) except + # ✓
|
|
1212
|
+
void PushID(const char* str_id_begin, const char* str_id_end) except + # ✗
|
|
1213
|
+
void PushID(const void* ptr_id) except + # ✗
|
|
1214
|
+
void PushID(int int_id) except + # ✗
|
|
1215
|
+
void PopID() except + # ✓
|
|
1216
|
+
ImGuiID GetID(const char* str_id) except + # ✓
|
|
1217
|
+
ImGuiID GetID(const char* str_id_begin, const char* str_id_end) except + # ✗
|
|
1218
|
+
ImGuiID GetID(const void* ptr_id) except + # ✗
|
|
1219
|
+
|
|
1220
|
+
# ====
|
|
1221
|
+
# Widgets: Text
|
|
1222
|
+
void TextUnformatted(const char*) except + # ✓
|
|
1223
|
+
void Text(const char*, ...) except + # ✓
|
|
1224
|
+
# TextV ?
|
|
1225
|
+
void TextColored(const ImVec4&, const char*, ...) except + # ✓
|
|
1226
|
+
# TextColoredV ?
|
|
1227
|
+
void TextDisabled(const char*, ...) except + # ✓
|
|
1228
|
+
# TextDisabledV ?
|
|
1229
|
+
void TextWrapped(const char*, ...) except + # ✓
|
|
1230
|
+
# TextWrappedV ?
|
|
1231
|
+
void LabelText(const char*, const char*, ...) except + # ✓
|
|
1232
|
+
# LabelTextV ?
|
|
1233
|
+
void BulletText(const char*, ...) except + # ✓
|
|
1234
|
+
# BulletTextV ?
|
|
1235
|
+
|
|
1236
|
+
# ====
|
|
1237
|
+
# Widgets: Main
|
|
1238
|
+
bool Button( # ✓
|
|
1239
|
+
const char* label,
|
|
1240
|
+
# note: optional
|
|
1241
|
+
const ImVec2& size # = ImVec2(0,0)
|
|
1242
|
+
) except +
|
|
1243
|
+
bool Button(const char* label) except + # ✓
|
|
1244
|
+
bool SmallButton(const char*) except + # ✓
|
|
1245
|
+
bool InvisibleButton( # ✓
|
|
1246
|
+
const char* str_id,
|
|
1247
|
+
const ImVec2& size,
|
|
1248
|
+
# note: optional
|
|
1249
|
+
ImGuiButtonFlags flags # = 0
|
|
1250
|
+
) except +
|
|
1251
|
+
bool ArrowButton(const char* str_id, ImGuiDir dir) except + # ✓
|
|
1252
|
+
void Image( # ✓
|
|
1253
|
+
ImTextureID user_texture_id,
|
|
1254
|
+
const ImVec2& size,
|
|
1255
|
+
# note: optional
|
|
1256
|
+
const ImVec2& uv0, # = ImVec2(0,0)
|
|
1257
|
+
const ImVec2& uv1, # = ImVec2(1,1)
|
|
1258
|
+
const ImVec4& tint_col, # = ImVec4(1,1,1,1)
|
|
1259
|
+
const ImVec4& border_col # = ImVec4(0,0,0,0)
|
|
1260
|
+
) except +
|
|
1261
|
+
bool ImageButton( # ✓
|
|
1262
|
+
ImTextureID user_texture_id,
|
|
1263
|
+
const ImVec2& size,
|
|
1264
|
+
# note: optional
|
|
1265
|
+
const ImVec2& uv0, # = ImVec2(0,0)
|
|
1266
|
+
const ImVec2& uv1, # = ImVec2(1,1)
|
|
1267
|
+
int frame_padding, # = -1
|
|
1268
|
+
const ImVec4& bg_col, # = ImVec4(0,0,0,0)
|
|
1269
|
+
const ImVec4& tint_col # = ImVec4(1,1,1,1)
|
|
1270
|
+
) except +
|
|
1271
|
+
bool Checkbox(const char* label, bool* v) except + # ✓
|
|
1272
|
+
bool CheckboxFlags( const char* label, int* flags, int flags_value ) except + # ✗
|
|
1273
|
+
bool CheckboxFlags( # ✓
|
|
1274
|
+
const char* label, unsigned int* flags, unsigned int flags_value
|
|
1275
|
+
) except +
|
|
1276
|
+
bool RadioButton(const char* label, bool active) except + # ✓
|
|
1277
|
+
# note: probably no reason to support it
|
|
1278
|
+
bool RadioButton(const char* label, int* v, int v_button) except + # ✓
|
|
1279
|
+
void ProgressBar( # ✓
|
|
1280
|
+
float fraction,
|
|
1281
|
+
# note: optional
|
|
1282
|
+
const ImVec2& size_arg, # = ImVec2(-FLT_MIN, 0)
|
|
1283
|
+
const char* overlay # = NULL
|
|
1284
|
+
) except +
|
|
1285
|
+
void Bullet() except + # ✓
|
|
1286
|
+
|
|
1287
|
+
# ====
|
|
1288
|
+
# Widgets: Combo Box
|
|
1289
|
+
bool BeginCombo( # ✓
|
|
1290
|
+
const char* label,
|
|
1291
|
+
const char* preview_value,
|
|
1292
|
+
# note: optional
|
|
1293
|
+
ImGuiComboFlags flags # = 0
|
|
1294
|
+
) except +
|
|
1295
|
+
bool EndCombo() except + # ✓
|
|
1296
|
+
bool Combo( # ✓
|
|
1297
|
+
const char* label,
|
|
1298
|
+
int* current_item,
|
|
1299
|
+
const char* items_separated_by_zeros,
|
|
1300
|
+
# note: optional
|
|
1301
|
+
int popup_max_height_in_items # = -1
|
|
1302
|
+
) except +
|
|
1303
|
+
# note: we only implemented the null-separated version that is fully
|
|
1304
|
+
# compatible with following. Probably no reason to support it
|
|
1305
|
+
bool Combo( # ✓
|
|
1306
|
+
const char* label,
|
|
1307
|
+
int* current_item,
|
|
1308
|
+
const char** items,
|
|
1309
|
+
int items_count,
|
|
1310
|
+
# note: optional
|
|
1311
|
+
int popup_max_height_in_items # = -1
|
|
1312
|
+
) except +
|
|
1313
|
+
bool Combo( # ✗
|
|
1314
|
+
const char* label,
|
|
1315
|
+
int* current_item,
|
|
1316
|
+
bool (*items_getter)(void* data, # TODO: Callback
|
|
1317
|
+
int idx,
|
|
1318
|
+
const char** out_text),
|
|
1319
|
+
void* data, int items_count,
|
|
1320
|
+
# note: optional
|
|
1321
|
+
int popup_max_height_in_items # = -1
|
|
1322
|
+
) except +
|
|
1323
|
+
|
|
1324
|
+
# ====
|
|
1325
|
+
# Widgets: Drag Sliders
|
|
1326
|
+
# manually input values aren't clamped, can go off-bounds) except + # For all the Float2/Float3/Float4/Int2/Int3/Int4 versions of every
|
|
1327
|
+
# functions, remember than a 'float v[3]' function argument is the same
|
|
1328
|
+
# as 'float* v'. You can pass address of your first element out of a
|
|
1329
|
+
# contiguous set, e.g. &myvector.x
|
|
1330
|
+
bool DragFloat( # ✓
|
|
1331
|
+
const char* label,
|
|
1332
|
+
float* v,
|
|
1333
|
+
# note: optional
|
|
1334
|
+
float v_speed, # = 1.0
|
|
1335
|
+
float v_min, # = 0.0
|
|
1336
|
+
float v_max, # = 0.0
|
|
1337
|
+
const char* format, # = "%.3f"
|
|
1338
|
+
ImGuiSliderFlags flags # = 0
|
|
1339
|
+
) except +
|
|
1340
|
+
bool DragFloat2( # ✓
|
|
1341
|
+
const char* label,
|
|
1342
|
+
float v[2],
|
|
1343
|
+
# note: optional
|
|
1344
|
+
float v_speed, # = 1.0
|
|
1345
|
+
float v_min, # = 0.0
|
|
1346
|
+
float v_max, # = 0.0
|
|
1347
|
+
const char* format, # = "%.3f"
|
|
1348
|
+
ImGuiSliderFlags flags # = 0
|
|
1349
|
+
) except +
|
|
1350
|
+
bool DragFloat3( # ✓
|
|
1351
|
+
const char* label,
|
|
1352
|
+
float v[3],
|
|
1353
|
+
# note: optional
|
|
1354
|
+
float v_speed, # = 1.0
|
|
1355
|
+
float v_min, # = 0.0
|
|
1356
|
+
float v_max, # = 0.0
|
|
1357
|
+
const char* format, # = "%.3f"
|
|
1358
|
+
ImGuiSliderFlags flags # = 0
|
|
1359
|
+
) except +
|
|
1360
|
+
bool DragFloat4( # ✓
|
|
1361
|
+
const char* label,
|
|
1362
|
+
float v[4],
|
|
1363
|
+
# note: optional
|
|
1364
|
+
float v_speed, # = 1.0
|
|
1365
|
+
float v_min, # = 0.0
|
|
1366
|
+
float v_max, # = 0.0
|
|
1367
|
+
const char* format, # = "%.3f"
|
|
1368
|
+
ImGuiSliderFlags flags # = 0
|
|
1369
|
+
) except +
|
|
1370
|
+
bool DragFloatRange2( # ✓
|
|
1371
|
+
const char* label, float* v_current_min, float* v_current_max,
|
|
1372
|
+
# note: optional
|
|
1373
|
+
float v_speed, # = 1.0
|
|
1374
|
+
float v_min, # = 0.0
|
|
1375
|
+
float v_max, # = 0.0
|
|
1376
|
+
const char* format, # = "%.3f"
|
|
1377
|
+
const char* format_max, # = NULL
|
|
1378
|
+
ImGuiSliderFlags flags # = 0
|
|
1379
|
+
) except +
|
|
1380
|
+
bool DragInt( # ✓
|
|
1381
|
+
const char* label,
|
|
1382
|
+
int* v,
|
|
1383
|
+
# note: optional
|
|
1384
|
+
float v_speed, # = 1.0
|
|
1385
|
+
int v_min, # = 0
|
|
1386
|
+
int v_max, # = 0
|
|
1387
|
+
const char* format, # = "%d"
|
|
1388
|
+
ImGuiSliderFlags flags # = 0
|
|
1389
|
+
) except +
|
|
1390
|
+
bool DragInt2( # ✓
|
|
1391
|
+
const char* label,
|
|
1392
|
+
int v[2],
|
|
1393
|
+
# note: optional
|
|
1394
|
+
float v_speed, # = 1.0
|
|
1395
|
+
int v_min, # = 0
|
|
1396
|
+
int v_max, # = 0
|
|
1397
|
+
const char* format, # = "%d"
|
|
1398
|
+
ImGuiSliderFlags flags # = 0
|
|
1399
|
+
) except +
|
|
1400
|
+
bool DragInt3( # ✓
|
|
1401
|
+
const char* label,
|
|
1402
|
+
int v[3],
|
|
1403
|
+
# note: optional
|
|
1404
|
+
float v_speed, # = 1.0
|
|
1405
|
+
int v_min, # = 0
|
|
1406
|
+
int v_max, # = 0
|
|
1407
|
+
const char* format, # = "%d"
|
|
1408
|
+
ImGuiSliderFlags flags # = 0
|
|
1409
|
+
) except +
|
|
1410
|
+
bool DragInt4( # ✓
|
|
1411
|
+
const char* label,
|
|
1412
|
+
int v[4],
|
|
1413
|
+
# note: optional
|
|
1414
|
+
float v_speed, # = 1.0
|
|
1415
|
+
int v_min, # = 0
|
|
1416
|
+
int v_max, # = 0
|
|
1417
|
+
const char* format, # = "%d"
|
|
1418
|
+
ImGuiSliderFlags flags # = 0
|
|
1419
|
+
) except +
|
|
1420
|
+
bool DragIntRange2( # ✓
|
|
1421
|
+
const char* label,
|
|
1422
|
+
int* v_current_min,
|
|
1423
|
+
int* v_current_max,
|
|
1424
|
+
# note: optional
|
|
1425
|
+
float v_speed, # = 1.0
|
|
1426
|
+
int v_min, # = 0
|
|
1427
|
+
int v_max, # = 0
|
|
1428
|
+
const char* format, # = "%d"
|
|
1429
|
+
const char* format_max, # = NULL
|
|
1430
|
+
ImGuiSliderFlags flags # = 0
|
|
1431
|
+
) except + # Widgets: Input with Keyboard
|
|
1432
|
+
bool DragScalar( # ✓
|
|
1433
|
+
const char* label,
|
|
1434
|
+
ImGuiDataType data_type,
|
|
1435
|
+
void* p_data,
|
|
1436
|
+
float v_speed,
|
|
1437
|
+
# note: optional
|
|
1438
|
+
const void* p_min, # = NULL
|
|
1439
|
+
const void* p_max, # = NULL
|
|
1440
|
+
const char* format, # = NULL
|
|
1441
|
+
ImGuiSliderFlags flags # = 0
|
|
1442
|
+
) except +
|
|
1443
|
+
bool DragScalarN( # ✓
|
|
1444
|
+
const char* label,
|
|
1445
|
+
ImGuiDataType data_type,
|
|
1446
|
+
void* p_data,
|
|
1447
|
+
int components,
|
|
1448
|
+
float v_speed,
|
|
1449
|
+
# note: optional
|
|
1450
|
+
const void* p_min, # = NULL
|
|
1451
|
+
const void* p_max, # = NULL
|
|
1452
|
+
const char* format, # = NULL
|
|
1453
|
+
ImGuiSliderFlags flags # = 0
|
|
1454
|
+
) except +
|
|
1455
|
+
|
|
1456
|
+
# ====
|
|
1457
|
+
# Widgets: Regular Sliders
|
|
1458
|
+
# manually input values aren't clamped, can go off-bounds)
|
|
1459
|
+
bool SliderFloat( # ✓
|
|
1460
|
+
const char* label, float* v, float v_min, float v_max,
|
|
1461
|
+
# note: optional
|
|
1462
|
+
const char* format, # = "%.3f"
|
|
1463
|
+
ImGuiSliderFlags flags # = 0
|
|
1464
|
+
) except +
|
|
1465
|
+
bool SliderFloat2( # ✓
|
|
1466
|
+
const char* label, float v[2], float v_min, float v_max,
|
|
1467
|
+
# note: optional
|
|
1468
|
+
const char* format, # = "%.3f"
|
|
1469
|
+
ImGuiSliderFlags flags # = 0
|
|
1470
|
+
) except +
|
|
1471
|
+
bool SliderFloat3( # ✓
|
|
1472
|
+
const char* label, float v[3], float v_min, float v_max,
|
|
1473
|
+
# note: optional
|
|
1474
|
+
const char* format, # = "%.3f"
|
|
1475
|
+
ImGuiSliderFlags flags # = 0
|
|
1476
|
+
) except +
|
|
1477
|
+
bool SliderFloat4( # ✓
|
|
1478
|
+
const char* label, float v[4], float v_min, float v_max,
|
|
1479
|
+
# note: optional
|
|
1480
|
+
const char* format, # = "%.3f"
|
|
1481
|
+
ImGuiSliderFlags flags # = 0
|
|
1482
|
+
) except +
|
|
1483
|
+
bool SliderAngle( # ✓
|
|
1484
|
+
const char* label, float* v_rad,
|
|
1485
|
+
# note: optional
|
|
1486
|
+
float v_degrees_min, # = -360.0
|
|
1487
|
+
float v_degrees_max, # = 360.0
|
|
1488
|
+
const char* format, # = "%.0f deg"
|
|
1489
|
+
ImGuiSliderFlags flags # = 0
|
|
1490
|
+
) except +
|
|
1491
|
+
bool SliderInt( # ✓
|
|
1492
|
+
const char* label, int* v, int v_min, int v_max,
|
|
1493
|
+
# note: optional
|
|
1494
|
+
const char* format, # = "%d"
|
|
1495
|
+
ImGuiSliderFlags flags # = 0
|
|
1496
|
+
) except +
|
|
1497
|
+
bool SliderInt2( # ✓
|
|
1498
|
+
const char* label, int v[2], int v_min, int v_max,
|
|
1499
|
+
# note: optional
|
|
1500
|
+
const char* format, # = "%d"
|
|
1501
|
+
ImGuiSliderFlags flags # = 0
|
|
1502
|
+
) except +
|
|
1503
|
+
bool SliderInt3( # ✓
|
|
1504
|
+
const char* label, int v[3], int v_min, int v_max,
|
|
1505
|
+
# note: optional
|
|
1506
|
+
const char* format, # = "%d"
|
|
1507
|
+
ImGuiSliderFlags flags # = 0
|
|
1508
|
+
) except +
|
|
1509
|
+
bool SliderInt4( # ✓
|
|
1510
|
+
const char* label, int v[4], int v_min, int v_max,
|
|
1511
|
+
# note: optional
|
|
1512
|
+
const char* format, # = "%d"
|
|
1513
|
+
ImGuiSliderFlags flags # = 0
|
|
1514
|
+
) except +
|
|
1515
|
+
bool SliderScalar( # ✓
|
|
1516
|
+
const char* label, ImGuiDataType data_type,
|
|
1517
|
+
void* v, const void* v_min, const void* v_max,
|
|
1518
|
+
# note: optional
|
|
1519
|
+
const char* format, # = NULL
|
|
1520
|
+
ImGuiSliderFlags flags # = 0
|
|
1521
|
+
) except +
|
|
1522
|
+
bool SliderScalarN( # ✓
|
|
1523
|
+
const char* label, ImGuiDataType data_type,
|
|
1524
|
+
void *v,
|
|
1525
|
+
int components, const void* v_min, const void* v_max,
|
|
1526
|
+
# note: optional
|
|
1527
|
+
const char* format, # = NULL
|
|
1528
|
+
ImGuiSliderFlags flags # = 0
|
|
1529
|
+
) except +
|
|
1530
|
+
bool VSliderFloat( # ✓
|
|
1531
|
+
const char* label, const ImVec2& size, float* v,
|
|
1532
|
+
float v_min, float v_max,
|
|
1533
|
+
# note: optional
|
|
1534
|
+
const char* format, # = "%.3f"
|
|
1535
|
+
ImGuiSliderFlags flags # = 0
|
|
1536
|
+
) except +
|
|
1537
|
+
bool VSliderInt( # ✓
|
|
1538
|
+
const char* label, const ImVec2& size, int* v, int v_min, int v_max,
|
|
1539
|
+
# note: optional
|
|
1540
|
+
const char* format, # = "%d"
|
|
1541
|
+
ImGuiSliderFlags flags # = 0 # NEW
|
|
1542
|
+
) except + # Widgets: Trees
|
|
1543
|
+
bool VSliderScalar( # ✓
|
|
1544
|
+
const char* label,
|
|
1545
|
+
const ImVec2& size,
|
|
1546
|
+
ImGuiDataType data_type, void* v
|
|
1547
|
+
, const void* v_min, const void* v_max,
|
|
1548
|
+
# note: optional
|
|
1549
|
+
const char* format, # = NULL
|
|
1550
|
+
ImGuiSliderFlags flags # = 0
|
|
1551
|
+
) except +
|
|
1552
|
+
|
|
1553
|
+
# ====
|
|
1554
|
+
# Widgets: Input with Keyboard
|
|
1555
|
+
bool InputText( # ✓
|
|
1556
|
+
const char* label, char* buf, size_t buf_size,
|
|
1557
|
+
# note: optional
|
|
1558
|
+
ImGuiInputTextFlags flags, # = 0
|
|
1559
|
+
ImGuiInputTextCallback callback, # = NULL
|
|
1560
|
+
void* user_data # = NULL
|
|
1561
|
+
) except +
|
|
1562
|
+
bool InputTextMultiline( # ✓
|
|
1563
|
+
const char* label, char* buf, size_t buf_size,
|
|
1564
|
+
# note: optional
|
|
1565
|
+
const ImVec2& size, # = ImVec2(0,0)
|
|
1566
|
+
ImGuiInputTextFlags flags, # = 0
|
|
1567
|
+
ImGuiInputTextCallback callback, # = NULL
|
|
1568
|
+
void* user_data # = NULL
|
|
1569
|
+
) except +
|
|
1570
|
+
bool InputTextWithHint( # ✓
|
|
1571
|
+
const char* label, const char* hint, char* buf,
|
|
1572
|
+
size_t buf_size,
|
|
1573
|
+
# note: optional
|
|
1574
|
+
ImGuiInputTextFlags flags, # = 0
|
|
1575
|
+
ImGuiInputTextCallback callback, # = NULL
|
|
1576
|
+
void* user_data # = NULL
|
|
1577
|
+
) except +
|
|
1578
|
+
bool InputFloat( # ✓
|
|
1579
|
+
const char* label, float* v,
|
|
1580
|
+
# note: optional
|
|
1581
|
+
float step, # = 0.0f
|
|
1582
|
+
float step_fast, # = 0.0f
|
|
1583
|
+
const char* format, # = "%.3f"
|
|
1584
|
+
ImGuiInputTextFlags flags # = 0
|
|
1585
|
+
) except +
|
|
1586
|
+
bool InputFloat2( # ✓
|
|
1587
|
+
const char* label, float v[2],
|
|
1588
|
+
# note: optional
|
|
1589
|
+
const char* format, # = "%.3f"
|
|
1590
|
+
ImGuiInputTextFlags flags # = 0
|
|
1591
|
+
) except +
|
|
1592
|
+
bool InputFloat3( # ✓
|
|
1593
|
+
const char* label, float v[3],
|
|
1594
|
+
# note: optional
|
|
1595
|
+
const char* format, # = "%.3f"
|
|
1596
|
+
ImGuiInputTextFlags flags # = 0
|
|
1597
|
+
) except +
|
|
1598
|
+
bool InputFloat4( # ✓
|
|
1599
|
+
const char* label, float v[4],
|
|
1600
|
+
# note: optional
|
|
1601
|
+
const char* format, # = "%.3f"
|
|
1602
|
+
ImGuiInputTextFlags flags # = 0
|
|
1603
|
+
) except +
|
|
1604
|
+
bool InputInt( # ✓
|
|
1605
|
+
const char* label, int* v,
|
|
1606
|
+
# note: optional
|
|
1607
|
+
int step, # = 1
|
|
1608
|
+
int step_fast, # = 100
|
|
1609
|
+
ImGuiInputTextFlags flags # = 0
|
|
1610
|
+
) except +
|
|
1611
|
+
bool InputInt2( # ✓
|
|
1612
|
+
const char* label, int v[2],
|
|
1613
|
+
# note: optional
|
|
1614
|
+
ImGuiInputTextFlags flags # = 0
|
|
1615
|
+
) except +
|
|
1616
|
+
bool InputInt3( # ✓
|
|
1617
|
+
const char* label, int v[3],
|
|
1618
|
+
# note: optional
|
|
1619
|
+
ImGuiInputTextFlags flags # = 0
|
|
1620
|
+
) except +
|
|
1621
|
+
bool InputInt4( # ✓
|
|
1622
|
+
const char* label, int v[4],
|
|
1623
|
+
# note: optional
|
|
1624
|
+
ImGuiInputTextFlags flags # = 0
|
|
1625
|
+
) except +
|
|
1626
|
+
bool InputDouble( # ✓
|
|
1627
|
+
const char* label,
|
|
1628
|
+
double* v,
|
|
1629
|
+
# note: optional
|
|
1630
|
+
double step, # = 0.0
|
|
1631
|
+
double step_fast, # = 0.0
|
|
1632
|
+
const char* format, # = "%.6f"
|
|
1633
|
+
ImGuiInputTextFlags flags # = 0
|
|
1634
|
+
) except +
|
|
1635
|
+
bool InputScalar( # ✓
|
|
1636
|
+
const char* label, ImGuiDataType data_type, void* p_data,
|
|
1637
|
+
# note: optional
|
|
1638
|
+
const void* p_step, # = NULL
|
|
1639
|
+
const void* p_step_fast, # = NULL
|
|
1640
|
+
const char* format, # = NULL
|
|
1641
|
+
ImGuiInputTextFlags flags # = 0
|
|
1642
|
+
) except +
|
|
1643
|
+
bool InputScalarN( # ✓
|
|
1644
|
+
const char* label, ImGuiDataType data_type,
|
|
1645
|
+
void* p_data, int components,
|
|
1646
|
+
# note: optional
|
|
1647
|
+
const void* p_step, # = NULL
|
|
1648
|
+
const void* p_step_fast, # = NULL
|
|
1649
|
+
const char* format, # = NULL
|
|
1650
|
+
ImGuiInputTextFlags flags # = 0
|
|
1651
|
+
) except +
|
|
1652
|
+
|
|
1653
|
+
# ====
|
|
1654
|
+
# Widgets: Color Editor/Picker
|
|
1655
|
+
bool ColorEdit3( # ✓
|
|
1656
|
+
const char* label,
|
|
1657
|
+
float col[3],
|
|
1658
|
+
# note: optional
|
|
1659
|
+
ImGuiColorEditFlags flags # = 0 # NEW
|
|
1660
|
+
) except +
|
|
1661
|
+
bool ColorEdit4( # ✓
|
|
1662
|
+
const char* label, float col[4],
|
|
1663
|
+
# note: optional
|
|
1664
|
+
ImGuiColorEditFlags flags # = 0 # API CHANGE
|
|
1665
|
+
) except +
|
|
1666
|
+
#void ColorEditMode(ImGuiColorEditMode mode) except + # note: obsoleted
|
|
1667
|
+
bool ColorPicker3( # ✗
|
|
1668
|
+
const char* label, float col[3],
|
|
1669
|
+
# note: optional
|
|
1670
|
+
ImGuiColorEditFlags flags # = 0
|
|
1671
|
+
) except +
|
|
1672
|
+
bool ColorPicker4( # ✗
|
|
1673
|
+
const char* label, float col[4],
|
|
1674
|
+
# note: optional
|
|
1675
|
+
ImGuiColorEditFlags flags, # = 0
|
|
1676
|
+
const float* ref_col # = NULL
|
|
1677
|
+
) except +
|
|
1678
|
+
bool ColorButton( # ✓
|
|
1679
|
+
const char *desc_id,
|
|
1680
|
+
const ImVec4& col,
|
|
1681
|
+
# note: optional
|
|
1682
|
+
ImGuiColorEditFlags flags, # = 0
|
|
1683
|
+
ImVec2 size # = ImVec2(0,0)
|
|
1684
|
+
) except +
|
|
1685
|
+
void SetColorEditOptions(ImGuiColorEditFlags flags) except + # ✗
|
|
1686
|
+
|
|
1687
|
+
# ====
|
|
1688
|
+
# Widgets: Trees
|
|
1689
|
+
bool TreeNode(const char* label) except + # ✓
|
|
1690
|
+
# bool TreeNode(const char* str_id, const char* fmt, ...) except + # ✗
|
|
1691
|
+
# bool TreeNode(const void* ptr_id, const char* fmt, ...) except + # ✗
|
|
1692
|
+
# bool TreeNodeV(const char* str_id, const char* fmt, va_list args) except + # ✗
|
|
1693
|
+
# bool TreeNodeV(const void* ptr_id, const char* fmt, va_list args) except + # ✗
|
|
1694
|
+
bool TreeNodeEx( # ✓
|
|
1695
|
+
const char* label,
|
|
1696
|
+
# note: optional
|
|
1697
|
+
ImGuiTreeNodeFlags flags # = 0
|
|
1698
|
+
) except +
|
|
1699
|
+
# bool TreeNodeEx(const char* str_id, ImGuiTreeNodeFlags flags, const char* fmt, ...) except + # ✗
|
|
1700
|
+
# bool TreeNodeEx(const void* ptr_id, ImGuiTreeNodeFlags flags, const char* fmt, ...) except + # ✗
|
|
1701
|
+
# bool TreeNodeExV(const char* str_id, ImGuiTreeNodeFlags flags, const char* fmt, va_list args) except + # ✗
|
|
1702
|
+
# bool TreeNodeExV(const void* ptr_id, ImGuiTreeNodeFlags flags, const char* fmt, va_list args) except + # ✗
|
|
1703
|
+
void TreePush(const char* str_id) except + # ✗
|
|
1704
|
+
void TreePush( # ✗
|
|
1705
|
+
# note: optional
|
|
1706
|
+
const void* ptr_id # = NULL
|
|
1707
|
+
) except +
|
|
1708
|
+
void TreePop() except + # ✓
|
|
1709
|
+
void TreeAdvanceToLabelPos() except + # ✗ # OBSOLETED in 1.72 (from April 2019)
|
|
1710
|
+
float GetTreeNodeToLabelSpacing() except + # ✓
|
|
1711
|
+
bool CollapsingHeader( # ✓
|
|
1712
|
+
const char* label,
|
|
1713
|
+
# note: optional
|
|
1714
|
+
ImGuiTreeNodeFlags flags # = 0
|
|
1715
|
+
) except +
|
|
1716
|
+
bool CollapsingHeader( # ✓
|
|
1717
|
+
const char* label, bool* p_visible,
|
|
1718
|
+
# note: optional
|
|
1719
|
+
ImGuiTreeNodeFlags flags # = 0
|
|
1720
|
+
) except +
|
|
1721
|
+
void SetNextItemOpen( # ✓
|
|
1722
|
+
bool is_open,
|
|
1723
|
+
# note: open
|
|
1724
|
+
ImGuiCond cond # = 0
|
|
1725
|
+
) except +
|
|
1726
|
+
void SetNextTreeNodeOpen( # ✗ # OBSOLETED in 1.72 (from April 2019)
|
|
1727
|
+
bool is_open,
|
|
1728
|
+
# note: optional
|
|
1729
|
+
ImGuiCond cond
|
|
1730
|
+
) except +
|
|
1731
|
+
|
|
1732
|
+
# ====
|
|
1733
|
+
# Widgets: Selectable
|
|
1734
|
+
bool Selectable( # ✓
|
|
1735
|
+
const char* label,
|
|
1736
|
+
# note: optional
|
|
1737
|
+
bool selected, # = False
|
|
1738
|
+
ImGuiSelectableFlags flags, # = 0
|
|
1739
|
+
const ImVec2& size # = ImVec2(0,0)
|
|
1740
|
+
) except +
|
|
1741
|
+
bool Selectable( # ✓
|
|
1742
|
+
const char* label, bool* p_selected,
|
|
1743
|
+
# note: optional
|
|
1744
|
+
ImGuiSelectableFlags flags, #= 0
|
|
1745
|
+
const ImVec2& size # = ImVec2(0,0)
|
|
1746
|
+
) except +
|
|
1747
|
+
|
|
1748
|
+
# ====
|
|
1749
|
+
# Widgets: List Boxes
|
|
1750
|
+
bool ListBox( # ✓
|
|
1751
|
+
const char* label, int* current_item, const char* items[],
|
|
1752
|
+
int items_count,
|
|
1753
|
+
# note: optional
|
|
1754
|
+
int height_in_items # = -1
|
|
1755
|
+
) except +
|
|
1756
|
+
bool ListBox( # ✗
|
|
1757
|
+
const char* label, int* current_item,
|
|
1758
|
+
bool (*items_getter)(void* data, int idx, const char** out_text), # TODO: Callback
|
|
1759
|
+
void* data, int items_count,
|
|
1760
|
+
# note: optional
|
|
1761
|
+
int height_in_items # = -1
|
|
1762
|
+
) except +
|
|
1763
|
+
|
|
1764
|
+
bool BeginListBox( # ✓
|
|
1765
|
+
const char* label,
|
|
1766
|
+
# note: optional
|
|
1767
|
+
const ImVec2& size # = ImVec2(0,0)
|
|
1768
|
+
) except +
|
|
1769
|
+
#bool ListBoxHeader( # OBSOLETED in 1.81 (from February 2021)
|
|
1770
|
+
# const char* label,
|
|
1771
|
+
# # note: optional
|
|
1772
|
+
# const ImVec2& size # = ImVec2(0,0)
|
|
1773
|
+
#) except +
|
|
1774
|
+
#bool ListBoxHeader( # REMOVED in 1.81 (from February 2021)
|
|
1775
|
+
# const char* label, int items_count,
|
|
1776
|
+
# # note: optional
|
|
1777
|
+
# int height_in_items # = -1
|
|
1778
|
+
#) except +
|
|
1779
|
+
void EndListBox() except + # ✓
|
|
1780
|
+
#void ListBoxFooter() except + # OBSOLETED in 1.81 (from February 2021)
|
|
1781
|
+
|
|
1782
|
+
# ====
|
|
1783
|
+
# Widgets: Data Plotting
|
|
1784
|
+
void PlotLines( # ✓
|
|
1785
|
+
const char* label, const float* values, int values_count,
|
|
1786
|
+
# note: optional
|
|
1787
|
+
int values_offset, # = 0
|
|
1788
|
+
const char* overlay_text, # = NULL
|
|
1789
|
+
float scale_min, # = FLT_MAX
|
|
1790
|
+
float scale_max, # = FLT_MAX
|
|
1791
|
+
ImVec2 graph_size, # = ImVec2(0,0)
|
|
1792
|
+
int stride # = sizeof(float))
|
|
1793
|
+
) except +
|
|
1794
|
+
void PlotLines( # ✗
|
|
1795
|
+
const char* label,
|
|
1796
|
+
float(*values_getter)(void* data, int idx), # TODO: Callback
|
|
1797
|
+
void* data, int values_count,
|
|
1798
|
+
# note: optional
|
|
1799
|
+
int values_offset, # = 0
|
|
1800
|
+
const char* overlay_text, # = NULL
|
|
1801
|
+
float scale_min, # = FLT_MAX
|
|
1802
|
+
float scale_max, # = FLT_MAX
|
|
1803
|
+
ImVec2 graph_size # = ImVec2(0,0)
|
|
1804
|
+
) except +
|
|
1805
|
+
void PlotHistogram( # ✓
|
|
1806
|
+
const char* label, const float* values, int values_count,
|
|
1807
|
+
# note: optional
|
|
1808
|
+
int values_offset, # = 0
|
|
1809
|
+
const char* overlay_text, # = NULL
|
|
1810
|
+
float scale_min, # = FLT_MAX
|
|
1811
|
+
float scale_max, # = FLT_MAX
|
|
1812
|
+
ImVec2 graph_size, # = ImVec2(0,0)
|
|
1813
|
+
int stride # = sizeof(float)
|
|
1814
|
+
) except +
|
|
1815
|
+
void PlotHistogram( # ✗
|
|
1816
|
+
const char* label,
|
|
1817
|
+
float (*values_getter)(void* data, int idx), # TODO: Callback
|
|
1818
|
+
void* data, int values_count,
|
|
1819
|
+
# note: optional
|
|
1820
|
+
int values_offset, # = 0
|
|
1821
|
+
const char* overlay_text, # = NULL
|
|
1822
|
+
float scale_min, # = FLT_MAX
|
|
1823
|
+
float scale_max, # = FLT_MAX
|
|
1824
|
+
ImVec2 graph_size # = ImVec2(0,0)
|
|
1825
|
+
) except +
|
|
1826
|
+
|
|
1827
|
+
# ====
|
|
1828
|
+
# Widgets: Value() Helpers.
|
|
1829
|
+
void Value(const char* prefix, bool b) except + # ✗
|
|
1830
|
+
void Value(const char* prefix, int v) except + # ✗
|
|
1831
|
+
void Value(const char* prefix, unsigned int v) except + # ✗
|
|
1832
|
+
void Value( # ✗
|
|
1833
|
+
const char* prefix, float v,
|
|
1834
|
+
# note: optional
|
|
1835
|
+
const char* float_format # = NULL
|
|
1836
|
+
) except +
|
|
1837
|
+
|
|
1838
|
+
# NOT FOUND
|
|
1839
|
+
# void ValueColor(const char* prefix, const ImVec4& v) except + # ✗
|
|
1840
|
+
# void ValueColor(const char* prefix, unsigned int v) except + # ✗
|
|
1841
|
+
|
|
1842
|
+
# ====
|
|
1843
|
+
# Widgets: Menus
|
|
1844
|
+
bool BeginMenuBar() except + # ✓
|
|
1845
|
+
void EndMenuBar() except + # ✓
|
|
1846
|
+
bool BeginMainMenuBar() except + # ✓
|
|
1847
|
+
void EndMainMenuBar() except + # ✓
|
|
1848
|
+
bool BeginMenu( # ✓
|
|
1849
|
+
const char* label,
|
|
1850
|
+
# note: optional
|
|
1851
|
+
bool enabled # = true
|
|
1852
|
+
) except +
|
|
1853
|
+
void EndMenu() except + # ✓
|
|
1854
|
+
bool MenuItem( # ✓
|
|
1855
|
+
const char* label,
|
|
1856
|
+
# note: optional
|
|
1857
|
+
const char* shortcut, # = NULL
|
|
1858
|
+
bool selected, # = false
|
|
1859
|
+
bool enabled # = true
|
|
1860
|
+
) except +
|
|
1861
|
+
bool MenuItem( # ✓
|
|
1862
|
+
const char* label, const char* shortcut, bool* p_selected,
|
|
1863
|
+
# note: optional
|
|
1864
|
+
bool enabled # = true
|
|
1865
|
+
) except +
|
|
1866
|
+
|
|
1867
|
+
# ====
|
|
1868
|
+
# Tooltips
|
|
1869
|
+
void BeginTooltip() except + # ✓
|
|
1870
|
+
void EndTooltip() except + # ✓
|
|
1871
|
+
void SetTooltip(const char* fmt, ...) except + # ✓
|
|
1872
|
+
# void SetTooltipV(const char* fmt, va_list args) except + # ✗
|
|
1873
|
+
|
|
1874
|
+
# ====
|
|
1875
|
+
# Popups, Modals
|
|
1876
|
+
bool BeginPopup( # ✓
|
|
1877
|
+
const char* str_id,
|
|
1878
|
+
# note: optional
|
|
1879
|
+
ImGuiWindowFlags flags # = 0
|
|
1880
|
+
) except +
|
|
1881
|
+
bool BeginPopupModal( # ✓
|
|
1882
|
+
const char* name,
|
|
1883
|
+
# note: optional
|
|
1884
|
+
bool* p_open, # = NULL
|
|
1885
|
+
ImGuiWindowFlags extra_flags # = 0
|
|
1886
|
+
) except +
|
|
1887
|
+
void EndPopup() except + # ✓
|
|
1888
|
+
void OpenPopup( # ✓
|
|
1889
|
+
const char* str_id,
|
|
1890
|
+
# note: optional
|
|
1891
|
+
ImGuiPopupFlags popup_flags # = 0
|
|
1892
|
+
) except +
|
|
1893
|
+
void OpenPopupOnItemClick( # ✓
|
|
1894
|
+
# note: optional
|
|
1895
|
+
const char* str_id, # = NULL
|
|
1896
|
+
ImGuiPopupFlags popup_flags # = 1
|
|
1897
|
+
) except +
|
|
1898
|
+
void CloseCurrentPopup() except + # ✓
|
|
1899
|
+
bool BeginPopupContextItem( # ✓
|
|
1900
|
+
# note: optional
|
|
1901
|
+
const char* str_id, # = NULL
|
|
1902
|
+
ImGuiPopupFlags popup_flags # = 1
|
|
1903
|
+
) except +
|
|
1904
|
+
bool BeginPopupContextWindow( # ✓
|
|
1905
|
+
# note: optional
|
|
1906
|
+
const char* str_id, # = NULL
|
|
1907
|
+
ImGuiPopupFlags popup_flags # = 1
|
|
1908
|
+
) except +
|
|
1909
|
+
bool BeginPopupContextVoid( # ✓
|
|
1910
|
+
# note: optional
|
|
1911
|
+
const char* str_id, # = NULL
|
|
1912
|
+
ImGuiPopupFlags popup_flags # = 1
|
|
1913
|
+
) except +
|
|
1914
|
+
bool IsPopupOpen( # ✓
|
|
1915
|
+
const char* str_id,
|
|
1916
|
+
# note: optional
|
|
1917
|
+
ImGuiPopupFlags flags # = 0
|
|
1918
|
+
) except +
|
|
1919
|
+
|
|
1920
|
+
# ====
|
|
1921
|
+
# Tables
|
|
1922
|
+
# [BETA API] API may evolve slightly!
|
|
1923
|
+
bool BeginTable( # ✓
|
|
1924
|
+
const char* str_id,
|
|
1925
|
+
int column,
|
|
1926
|
+
# note: optional
|
|
1927
|
+
ImGuiTableFlags flags, # = 0
|
|
1928
|
+
const ImVec2& outer_size, # = ImVec2(0.0f, 0.0f)
|
|
1929
|
+
float inner_width # = 0.0f
|
|
1930
|
+
) except +
|
|
1931
|
+
void EndTable() except + # ✓
|
|
1932
|
+
void TableNextRow( # ✓
|
|
1933
|
+
# note: optional
|
|
1934
|
+
ImGuiTableRowFlags row_flags, # = 0
|
|
1935
|
+
float min_row_height # = 0.0f
|
|
1936
|
+
) except +
|
|
1937
|
+
bool TableNextColumn() except + # ✓
|
|
1938
|
+
bool TableSetColumnIndex(int column_n) except + # ✓
|
|
1939
|
+
|
|
1940
|
+
void TableSetupColumn( # ✓
|
|
1941
|
+
const char* label,
|
|
1942
|
+
# note: optional
|
|
1943
|
+
ImGuiTableColumnFlags flags, # = 0
|
|
1944
|
+
float init_width_or_weight, # = 0.0f
|
|
1945
|
+
ImGuiID user_id # = 0
|
|
1946
|
+
) except +
|
|
1947
|
+
void TableSetupScrollFreeze(int cols, int rows) except + # ✓
|
|
1948
|
+
void TableHeadersRow() except + # ✓
|
|
1949
|
+
void TableHeader(const char* label) except + # ✓
|
|
1950
|
+
|
|
1951
|
+
ImGuiTableSortSpecs* TableGetSortSpecs() except + # ✓
|
|
1952
|
+
|
|
1953
|
+
int TableGetColumnCount() except + # ✓
|
|
1954
|
+
int TableGetColumnIndex() except + # ✓
|
|
1955
|
+
int TableGetRowIndex() except + # ✓
|
|
1956
|
+
const char* TableGetColumnName( # ✓
|
|
1957
|
+
# note: optional
|
|
1958
|
+
int column_n # = -1
|
|
1959
|
+
) except +
|
|
1960
|
+
ImGuiTableColumnFlags TableGetColumnFlags( # ✓
|
|
1961
|
+
# note: optional
|
|
1962
|
+
int column_n # = -1
|
|
1963
|
+
) except +
|
|
1964
|
+
void TableSetBgColor( # ✓
|
|
1965
|
+
ImGuiTableBgTarget target,
|
|
1966
|
+
ImU32 color,
|
|
1967
|
+
# note: optional
|
|
1968
|
+
int column_n # = -1
|
|
1969
|
+
) except +
|
|
1970
|
+
|
|
1971
|
+
|
|
1972
|
+
# ====
|
|
1973
|
+
# Columns
|
|
1974
|
+
# Legacy Columns API (2020: prefer using Tables!)
|
|
1975
|
+
void Columns( # ✓
|
|
1976
|
+
# note: optional
|
|
1977
|
+
int count, # = 1
|
|
1978
|
+
const char* id, # = NULL
|
|
1979
|
+
bool border # = true
|
|
1980
|
+
) except +
|
|
1981
|
+
void NextColumn() except + # ✓
|
|
1982
|
+
int GetColumnIndex() except + # ✓
|
|
1983
|
+
float GetColumnWidth( # ✓
|
|
1984
|
+
# note: optional
|
|
1985
|
+
int column_index # = -1
|
|
1986
|
+
) except +
|
|
1987
|
+
void SetColumnWidth(int column_index, float width) except + # ✓
|
|
1988
|
+
float GetColumnOffset( # ✓
|
|
1989
|
+
# note: optional
|
|
1990
|
+
int column_index # = -1
|
|
1991
|
+
) except +
|
|
1992
|
+
void SetColumnOffset(int column_index, float offset_x) except + # ✓
|
|
1993
|
+
int GetColumnsCount() except + # ✓
|
|
1994
|
+
|
|
1995
|
+
# ====
|
|
1996
|
+
# Tab Bars, Tabs
|
|
1997
|
+
bool BeginTabBar( # ✓
|
|
1998
|
+
const char* str_id,
|
|
1999
|
+
# note: optional
|
|
2000
|
+
ImGuiTabBarFlags flags # = 0
|
|
2001
|
+
) except +
|
|
2002
|
+
void EndTabBar() except + # ✓ // only call EndTabBar() if BeginTabBar() returns true!
|
|
2003
|
+
bool BeginTabItem( # ✓
|
|
2004
|
+
const char* label,
|
|
2005
|
+
# note: optional
|
|
2006
|
+
bool* p_open, # = NULL
|
|
2007
|
+
ImGuiTabItemFlags flags # = 0
|
|
2008
|
+
) except +
|
|
2009
|
+
void EndTabItem() except + # ✓
|
|
2010
|
+
bool TabItemButton( # ✓
|
|
2011
|
+
const char* label,
|
|
2012
|
+
# note: optional
|
|
2013
|
+
ImGuiTabItemFlags flags # = 0
|
|
2014
|
+
) except +
|
|
2015
|
+
void SetTabItemClosed(const char* tab_or_docked_window_label) except + # ✓
|
|
2016
|
+
|
|
2017
|
+
# ====
|
|
2018
|
+
# Logging/Capture
|
|
2019
|
+
# Logging: all text output from interface is redirected to
|
|
2020
|
+
# tty/file/clipboard. By default, tree nodes are automatically opened
|
|
2021
|
+
# during logging.
|
|
2022
|
+
void LogToTTY( # ✗
|
|
2023
|
+
# note: optional
|
|
2024
|
+
int auto_open_depth # = -1
|
|
2025
|
+
) except +
|
|
2026
|
+
void LogToFile( # ✗
|
|
2027
|
+
# note: optional
|
|
2028
|
+
int auto_open_depth, # = -1
|
|
2029
|
+
const char* filename # = NULL
|
|
2030
|
+
) except +
|
|
2031
|
+
void LogToClipboard( # ✗
|
|
2032
|
+
# note: optional
|
|
2033
|
+
int auto_open_depth # = -1
|
|
2034
|
+
) except +
|
|
2035
|
+
void LogFinish() except + # ✗
|
|
2036
|
+
void LogButtons() except + # ✗
|
|
2037
|
+
void LogText(const char* fmt, ...) except + # ✗
|
|
2038
|
+
# void LogTextV(const char* fmt, va_list args) except + # ✗
|
|
2039
|
+
|
|
2040
|
+
# ====
|
|
2041
|
+
# Drag and Drop
|
|
2042
|
+
bool BeginDragDropSource( # ✓
|
|
2043
|
+
# note: optional
|
|
2044
|
+
ImGuiDragDropFlags flags # = 0
|
|
2045
|
+
) except +
|
|
2046
|
+
bool SetDragDropPayload( # ✓
|
|
2047
|
+
const char* type,
|
|
2048
|
+
const void* data,
|
|
2049
|
+
size_t size,
|
|
2050
|
+
# note: optional
|
|
2051
|
+
ImGuiCond cond # = 0
|
|
2052
|
+
) except +
|
|
2053
|
+
void EndDragDropSource() except + # ✓
|
|
2054
|
+
bool BeginDragDropTarget() except + # ✓
|
|
2055
|
+
const ImGuiPayload* AcceptDragDropPayload( # ✓
|
|
2056
|
+
const char* type,
|
|
2057
|
+
# note:optional
|
|
2058
|
+
ImGuiDragDropFlags flags # = 0
|
|
2059
|
+
) except +
|
|
2060
|
+
void EndDragDropTarget() except + # ✓
|
|
2061
|
+
const ImGuiPayload* GetDragDropPayload() except + # ✓
|
|
2062
|
+
|
|
2063
|
+
# ====
|
|
2064
|
+
# Clipping
|
|
2065
|
+
void PushClipRect(const ImVec2& clip_rect_min, const ImVec2& clip_rect_max, bool intersect_with_current_clip_rect) except + # ✓
|
|
2066
|
+
void PopClipRect() except + # ✓
|
|
2067
|
+
|
|
2068
|
+
# ====
|
|
2069
|
+
# Focus, Activation
|
|
2070
|
+
void SetItemDefaultFocus() except + # ✓
|
|
2071
|
+
void SetKeyboardFocusHere( # ✓
|
|
2072
|
+
# note: optional
|
|
2073
|
+
int offset
|
|
2074
|
+
) except +
|
|
2075
|
+
|
|
2076
|
+
# ====
|
|
2077
|
+
# Item/Widgets Utilities
|
|
2078
|
+
bool IsItemHovered( # ✓
|
|
2079
|
+
# note: optional
|
|
2080
|
+
ImGuiHoveredFlags flags
|
|
2081
|
+
) except +
|
|
2082
|
+
bool IsItemActive() except + # ✓
|
|
2083
|
+
bool IsItemFocused() except + # ✓
|
|
2084
|
+
bool IsItemClicked( # ✓
|
|
2085
|
+
# note: optional
|
|
2086
|
+
ImGuiMouseButton mouse_button # = 0
|
|
2087
|
+
) except +
|
|
2088
|
+
bool IsItemVisible() except + # ✓
|
|
2089
|
+
bool IsItemEdited() except + # ✓
|
|
2090
|
+
bool IsItemActivated() except + # ✓
|
|
2091
|
+
bool IsItemDeactivated() except + # ✓
|
|
2092
|
+
bool IsItemDeactivatedAfterEdit() except + # ✓
|
|
2093
|
+
bool IsItemToggledOpen() except + # ✓
|
|
2094
|
+
bool IsAnyItemHovered() except + # ✓
|
|
2095
|
+
bool IsAnyItemActive() except + # ✓
|
|
2096
|
+
bool IsAnyItemFocused() except + # ✓
|
|
2097
|
+
ImVec2 GetItemRectMin() except + # ✓
|
|
2098
|
+
ImVec2 GetItemRectMax() except + # ✓
|
|
2099
|
+
ImVec2 GetItemRectSize() except + # ✓
|
|
2100
|
+
void SetItemAllowOverlap() except + # ✓
|
|
2101
|
+
|
|
2102
|
+
# ====
|
|
2103
|
+
# Viewports
|
|
2104
|
+
ImGuiViewport* GetMainViewport() except + # ✓
|
|
2105
|
+
|
|
2106
|
+
# ====
|
|
2107
|
+
# Miscellaneous Utilities
|
|
2108
|
+
bool IsRectVisible(const ImVec2& size) except + # ✓
|
|
2109
|
+
bool IsRectVisible(const ImVec2& rect_min, const ImVec2& rect_max) except + # ✗
|
|
2110
|
+
double GetTime() except + # ✓
|
|
2111
|
+
int GetFrameCount() except + # ✗
|
|
2112
|
+
ImDrawList* GetBackgroundDrawList() except + # ✓
|
|
2113
|
+
ImDrawList* GetForegroundDrawList() except + # ✓
|
|
2114
|
+
ImDrawList* GetOverlayDrawList() except + # ✗ # OBSOLETED in 1.69 (from Mar 2019)
|
|
2115
|
+
ImDrawListSharedData* GetDrawListSharedData() except + # ✗
|
|
2116
|
+
const char* GetStyleColorName(ImGuiCol idx) except + # ✓
|
|
2117
|
+
void SetStateStorage(ImGuiStorage* storage) except + # ✗
|
|
2118
|
+
ImGuiStorage* GetStateStorage() except + # ✗
|
|
2119
|
+
void CalcListClipping(int items_count, float items_height, int* out_items_display_start, int* out_items_display_end) except + # ✗
|
|
2120
|
+
bool BeginChildFrame( # ✗
|
|
2121
|
+
ImGuiID id, const ImVec2& size,
|
|
2122
|
+
# note: optional
|
|
2123
|
+
ImGuiWindowFlags flags # = 0
|
|
2124
|
+
) except +
|
|
2125
|
+
void EndChildFrame() except + # ✗
|
|
2126
|
+
|
|
2127
|
+
# Text Utilities
|
|
2128
|
+
ImVec2 CalcTextSize( # ✓
|
|
2129
|
+
const char* text,
|
|
2130
|
+
# note: optional
|
|
2131
|
+
const char* text_end, # = NULL
|
|
2132
|
+
bool hide_text_after_double_hash, # = false
|
|
2133
|
+
float wrap_width # = -1.0
|
|
2134
|
+
) except +
|
|
2135
|
+
|
|
2136
|
+
# ====
|
|
2137
|
+
# Color Utilities
|
|
2138
|
+
ImVec4 ColorConvertU32ToFloat4(ImU32 in_) except + # ✓
|
|
2139
|
+
ImU32 ColorConvertFloat4ToU32(const ImVec4& in_) except + # ✓
|
|
2140
|
+
void ColorConvertRGBtoHSV(float r, float g, float b, float& out_h, float& out_s, float& out_v) except + # ✓
|
|
2141
|
+
void ColorConvertHSVtoRGB(float h, float s, float v, float& out_r, float& out_g, float& out_b) except + # ✓
|
|
2142
|
+
|
|
2143
|
+
# ====
|
|
2144
|
+
# Inputs Utilities: Keyboard
|
|
2145
|
+
int GetKeyIndex(ImGuiKey key) except + # ✓
|
|
2146
|
+
bool IsKeyDown(int key_index) except + # ✓
|
|
2147
|
+
bool IsKeyPressed( # ✓
|
|
2148
|
+
int key_index,
|
|
2149
|
+
# note: optional
|
|
2150
|
+
bool repeat # = True
|
|
2151
|
+
) except +
|
|
2152
|
+
bool IsKeyReleased(int key_index) except + # ✓
|
|
2153
|
+
int GetKeyPressedAmount(int key_index, float repeat_delay, float rate) except + # ✗
|
|
2154
|
+
void CaptureKeyboardFromApp( # ✗
|
|
2155
|
+
# note: optional
|
|
2156
|
+
bool want_capture_keyboard_value # = True
|
|
2157
|
+
) except +
|
|
2158
|
+
|
|
2159
|
+
# ====
|
|
2160
|
+
# Inputs Utilities: Mouse
|
|
2161
|
+
bool IsMouseDown(int button) except + # ✓
|
|
2162
|
+
bool IsMouseClicked( # ✓
|
|
2163
|
+
int button,
|
|
2164
|
+
# note: optional
|
|
2165
|
+
bool repeat # = False
|
|
2166
|
+
) except +
|
|
2167
|
+
bool IsMouseDoubleClicked(int button) except + # ✓
|
|
2168
|
+
bool IsMouseReleased(int button) except + # ✓
|
|
2169
|
+
bool IsMouseHoveringRect( # ✓
|
|
2170
|
+
const ImVec2& r_min, const ImVec2& r_max,
|
|
2171
|
+
# note: optional
|
|
2172
|
+
bool clip # = True
|
|
2173
|
+
) except +
|
|
2174
|
+
bool IsMousePosValid(const ImVec2* mouse_pos) except + # ✗
|
|
2175
|
+
bool IsAnyMouseDown() except + # ✗
|
|
2176
|
+
ImVec2 GetMousePos() except + # ✓
|
|
2177
|
+
ImVec2 GetMousePosOnOpeningCurrentPopup() except + # ✗
|
|
2178
|
+
bool IsMouseDragging( # ✓
|
|
2179
|
+
int button,
|
|
2180
|
+
# note: optional
|
|
2181
|
+
float lock_threshold # = -1.0f
|
|
2182
|
+
) except +
|
|
2183
|
+
ImVec2 GetMouseDragDelta( # ✓
|
|
2184
|
+
# note: optional
|
|
2185
|
+
int button, # = 0
|
|
2186
|
+
float lock_threshold # = -1.0f
|
|
2187
|
+
) except +
|
|
2188
|
+
void ResetMouseDragDelta( # ✓
|
|
2189
|
+
# note: optional
|
|
2190
|
+
int button # = 0
|
|
2191
|
+
) except +
|
|
2192
|
+
ImGuiMouseCursor GetMouseCursor() except + # ✓
|
|
2193
|
+
void SetMouseCursor(ImGuiMouseCursor type) except + # ✓
|
|
2194
|
+
void CaptureMouseFromApp( # ✓
|
|
2195
|
+
# note: optional
|
|
2196
|
+
bool want_capture_mouse_value # = True
|
|
2197
|
+
) except +
|
|
2198
|
+
|
|
2199
|
+
# ====
|
|
2200
|
+
# Clipboard Utilities
|
|
2201
|
+
const char* GetClipboardText() except + # ✓
|
|
2202
|
+
void SetClipboardText(const char* text) except + # ✓
|
|
2203
|
+
|
|
2204
|
+
# ====
|
|
2205
|
+
# Settings/.Ini Utilities
|
|
2206
|
+
void LoadIniSettingsFromDisk( # ✓
|
|
2207
|
+
const char* ini_filename
|
|
2208
|
+
) except +
|
|
2209
|
+
void LoadIniSettingsFromMemory( # ✓
|
|
2210
|
+
const char* ini_data,
|
|
2211
|
+
# note: optional
|
|
2212
|
+
size_t ini_size # = 0
|
|
2213
|
+
) except +
|
|
2214
|
+
void SaveIniSettingsToDisk( # ✓
|
|
2215
|
+
const char* ini_filename
|
|
2216
|
+
) except +
|
|
2217
|
+
const char* SaveIniSettingsToMemory( # ✓
|
|
2218
|
+
# note: optional
|
|
2219
|
+
size_t* out_ini_size # = NULL
|
|
2220
|
+
) except +
|
|
2221
|
+
|
|
2222
|
+
# ====
|
|
2223
|
+
# Debug Utilities
|
|
2224
|
+
bool DebugCheckVersionAndDataLayout(const char* version_str, size_t sz_io, size_t sz_style, size_t sz_vec2, size_t sz_vec4, size_t sz_drawvert) except + # ✓
|
|
2225
|
+
|
|
2226
|
+
# ====
|
|
2227
|
+
# Memory Allocators
|
|
2228
|
+
void SetAllocatorFunctions( # ✗
|
|
2229
|
+
void* (*alloc_func)(size_t sz, void* user_data), # TODO: Callback
|
|
2230
|
+
void (*free_func)(void* ptr, void* user_data), # TODO: Callback
|
|
2231
|
+
# note: optional
|
|
2232
|
+
void* user_data # = NULL
|
|
2233
|
+
) except +
|
|
2234
|
+
void GetAllocatorFunctions( # ✗
|
|
2235
|
+
ImGuiMemAllocFunc* p_alloc_func, # TODO: Callback
|
|
2236
|
+
ImGuiMemFreeFunc* p_free_func, # TODO: Callback
|
|
2237
|
+
void** p_user_data
|
|
2238
|
+
) except +
|
|
2239
|
+
void* MemAlloc(size_t size) except + # ✗
|
|
2240
|
+
void MemFree(void* ptr) except + # ✗
|
|
2241
|
+
|
|
2242
|
+
|