30#define IMGUI_VERSION "1.90.9"
31#define IMGUI_VERSION_NUM 19090
32#define IMGUI_HAS_TABLE
59#ifdef IMGUI_USER_CONFIG
60#include IMGUI_USER_CONFIG
83#define IMGUI_IMPL_API IMGUI_API
89#define IM_ASSERT(_EXPR) assert(_EXPR)
91#define IM_ARRAYSIZE(_ARR) ((int)(sizeof(_ARR) / sizeof(*(_ARR))))
92#define IM_UNUSED(_VAR) ((void)(_VAR))
95#define IMGUI_CHECKVERSION() ImGui::DebugCheckVersionAndDataLayout(IMGUI_VERSION, sizeof(ImGuiIO), sizeof(ImGuiStyle), sizeof(ImVec2), sizeof(ImVec4), sizeof(ImDrawVert), sizeof(ImDrawIdx))
100#if !defined(IMGUI_USE_STB_SPRINTF) && defined(__MINGW32__) && !defined(__clang__)
101#define IM_FMTARGS(FMT) __attribute__((format(gnu_printf, FMT, FMT+1)))
102#define IM_FMTLIST(FMT) __attribute__((format(gnu_printf, FMT, 0)))
103#elif !defined(IMGUI_USE_STB_SPRINTF) && (defined(__clang__) || defined(__GNUC__))
104#define IM_FMTARGS(FMT) __attribute__((format(printf, FMT, FMT+1)))
105#define IM_FMTLIST(FMT) __attribute__((format(printf, FMT, 0)))
107#define IM_FMTARGS(FMT)
108#define IM_FMTLIST(FMT)
112#if defined(_MSC_VER) && !defined(__clang__) && !defined(__INTEL_COMPILER) && !defined(IMGUI_DEBUG_PARANOID)
113#define IM_MSVC_RUNTIME_CHECKS_OFF __pragma(runtime_checks("",off)) __pragma(check_stack(off)) __pragma(strict_gs_check(push,off))
114#define IM_MSVC_RUNTIME_CHECKS_RESTORE __pragma(runtime_checks("",restore)) __pragma(check_stack()) __pragma(strict_gs_check(pop))
116#define IM_MSVC_RUNTIME_CHECKS_OFF
117#define IM_MSVC_RUNTIME_CHECKS_RESTORE
122#pragma warning (push)
123#pragma warning (disable: 26495)
125#if defined(__clang__)
126#pragma clang diagnostic push
127#if __has_warning("-Wunknown-warning-option")
128#pragma clang diagnostic ignored "-Wunknown-warning-option"
130#pragma clang diagnostic ignored "-Wunknown-pragmas"
131#pragma clang diagnostic ignored "-Wold-style-cast"
132#pragma clang diagnostic ignored "-Wfloat-equal"
133#pragma clang diagnostic ignored "-Wzero-as-null-pointer-constant"
134#pragma clang diagnostic ignored "-Wreserved-identifier"
135#pragma clang diagnostic ignored "-Wunsafe-buffer-usage"
136#elif defined(__GNUC__)
137#pragma GCC diagnostic push
138#pragma GCC diagnostic ignored "-Wpragmas"
139#pragma GCC diagnostic ignored "-Wclass-memaccess"
147typedef unsigned int ImGuiID;
148typedef signed char ImS8;
149typedef unsigned char ImU8;
150typedef signed short ImS16;
151typedef unsigned short ImU16;
152typedef signed int ImS32;
153typedef unsigned int ImU32;
154typedef signed long long ImS64;
155typedef unsigned long long ImU64;
198enum ImGuiMouseSource : int;
199enum ImGuiSortDirection : ImU8;
201typedef int ImGuiCond;
202typedef int ImGuiDataType;
203typedef int ImGuiMouseButton;
204typedef int ImGuiMouseCursor;
205typedef int ImGuiStyleVar;
206typedef int ImGuiTableBgTarget;
213typedef int ImDrawFlags;
214typedef int ImDrawListFlags;
215typedef int ImFontAtlasFlags;
216typedef int ImGuiBackendFlags;
217typedef int ImGuiButtonFlags;
218typedef int ImGuiChildFlags;
219typedef int ImGuiColorEditFlags;
220typedef int ImGuiConfigFlags;
221typedef int ImGuiComboFlags;
222typedef int ImGuiDragDropFlags;
223typedef int ImGuiFocusedFlags;
224typedef int ImGuiHoveredFlags;
225typedef int ImGuiInputFlags;
226typedef int ImGuiInputTextFlags;
227typedef int ImGuiKeyChord;
228typedef int ImGuiPopupFlags;
229typedef int ImGuiSelectableFlags;
230typedef int ImGuiSliderFlags;
231typedef int ImGuiTabBarFlags;
232typedef int ImGuiTabItemFlags;
233typedef int ImGuiTableFlags;
234typedef int ImGuiTableColumnFlags;
235typedef int ImGuiTableRowFlags;
236typedef int ImGuiTreeNodeFlags;
237typedef int ImGuiViewportFlags;
238typedef int ImGuiWindowFlags;
244typedef void* ImTextureID;
251typedef unsigned short ImDrawIdx;
256typedef unsigned int ImWchar32;
257typedef unsigned short ImWchar16;
258#ifdef IMGUI_USE_WCHAR32
259typedef ImWchar32 ImWchar;
261typedef ImWchar16 ImWchar;
267typedef void* (*ImGuiMemAllocFunc)(
size_t sz,
void* user_data);
268typedef void (*ImGuiMemFreeFunc)(
void* ptr,
void* user_data);
273IM_MSVC_RUNTIME_CHECKS_OFF
277 constexpr ImVec2() : x(0.0f), y(0.0f) { }
278 constexpr ImVec2(
float _x,
float _y) : x(_x), y(_y) { }
279 float& operator[] (
size_t idx) { IM_ASSERT(idx == 0 || idx == 1);
return ((
float*)(
void*)(
char*)
this)[idx]; }
280 float operator[] (
size_t idx)
const { IM_ASSERT(idx == 0 || idx == 1);
return ((
const float*)(
const void*)(
const char*)
this)[idx]; }
281#ifdef IM_VEC2_CLASS_EXTRA
290 constexpr ImVec4() : x(0.0f), y(0.0f), z(0.0f), w(0.0f) { }
291 constexpr ImVec4(
float _x,
float _y,
float _z,
float _w) : x(_x), y(_y), z(_z), w(_w) { }
292#ifdef IM_VEC4_CLASS_EXTRA
296IM_MSVC_RUNTIME_CHECKS_RESTORE
310 IMGUI_API
void DestroyContext(
ImGuiContext* ctx = NULL);
317 IMGUI_API
void NewFrame();
318 IMGUI_API
void EndFrame();
319 IMGUI_API
void Render();
323 IMGUI_API
void ShowDemoWindow(
bool* p_open = NULL);
324 IMGUI_API
void ShowMetricsWindow(
bool* p_open = NULL);
325 IMGUI_API
void ShowDebugLogWindow(
bool* p_open = NULL);
326 IMGUI_API
void ShowIDStackToolWindow(
bool* p_open = NULL);
327 IMGUI_API
void ShowAboutWindow(
bool* p_open = NULL);
328 IMGUI_API
void ShowStyleEditor(
ImGuiStyle* ref = NULL);
329 IMGUI_API
bool ShowStyleSelector(
const char* label);
330 IMGUI_API
void ShowFontSelector(
const char* label);
331 IMGUI_API
void ShowUserGuide();
332 IMGUI_API
const char* GetVersion();
335 IMGUI_API
void StyleColorsDark(
ImGuiStyle* dst = NULL);
336 IMGUI_API
void StyleColorsLight(
ImGuiStyle* dst = NULL);
337 IMGUI_API
void StyleColorsClassic(
ImGuiStyle* dst = NULL);
351 IMGUI_API
bool Begin(
const char* name,
bool* p_open = NULL, ImGuiWindowFlags flags = 0);
352 IMGUI_API
void End();
372 IMGUI_API
bool BeginChild(
const char* str_id,
const ImVec2& size =
ImVec2(0, 0), ImGuiChildFlags child_flags = 0, ImGuiWindowFlags window_flags = 0);
373 IMGUI_API
bool BeginChild(ImGuiID
id,
const ImVec2& size =
ImVec2(0, 0), ImGuiChildFlags child_flags = 0, ImGuiWindowFlags window_flags = 0);
374 IMGUI_API
void EndChild();
378 IMGUI_API
bool IsWindowAppearing();
379 IMGUI_API
bool IsWindowCollapsed();
380 IMGUI_API
bool IsWindowFocused(ImGuiFocusedFlags flags=0);
381 IMGUI_API
bool IsWindowHovered(ImGuiHoveredFlags flags=0);
383 IMGUI_API
ImVec2 GetWindowPos();
384 IMGUI_API
ImVec2 GetWindowSize();
385 IMGUI_API
float GetWindowWidth();
386 IMGUI_API
float GetWindowHeight();
390 IMGUI_API
void SetNextWindowPos(
const ImVec2& pos, ImGuiCond cond = 0,
const ImVec2& pivot =
ImVec2(0, 0));
391 IMGUI_API
void SetNextWindowSize(
const ImVec2& size, ImGuiCond cond = 0);
392 IMGUI_API
void SetNextWindowSizeConstraints(
const ImVec2& size_min,
const ImVec2& size_max, ImGuiSizeCallback custom_callback = NULL,
void* custom_callback_data = NULL);
393 IMGUI_API
void SetNextWindowContentSize(
const ImVec2& size);
394 IMGUI_API
void SetNextWindowCollapsed(
bool collapsed, ImGuiCond cond = 0);
395 IMGUI_API
void SetNextWindowFocus();
396 IMGUI_API
void SetNextWindowScroll(
const ImVec2& scroll);
397 IMGUI_API
void SetNextWindowBgAlpha(
float alpha);
398 IMGUI_API
void SetWindowPos(
const ImVec2& pos, ImGuiCond cond = 0);
399 IMGUI_API
void SetWindowSize(
const ImVec2& size, ImGuiCond cond = 0);
400 IMGUI_API
void SetWindowCollapsed(
bool collapsed, ImGuiCond cond = 0);
401 IMGUI_API
void SetWindowFocus();
402 IMGUI_API
void SetWindowFontScale(
float scale);
403 IMGUI_API
void SetWindowPos(
const char* name,
const ImVec2& pos, ImGuiCond cond = 0);
404 IMGUI_API
void SetWindowSize(
const char* name,
const ImVec2& size, ImGuiCond cond = 0);
405 IMGUI_API
void SetWindowCollapsed(
const char* name,
bool collapsed, ImGuiCond cond = 0);
406 IMGUI_API
void SetWindowFocus(
const char* name);
411 IMGUI_API
ImVec2 GetContentRegionAvail();
412 IMGUI_API
ImVec2 GetContentRegionMax();
413 IMGUI_API
ImVec2 GetWindowContentRegionMin();
414 IMGUI_API
ImVec2 GetWindowContentRegionMax();
419 IMGUI_API
float GetScrollX();
420 IMGUI_API
float GetScrollY();
421 IMGUI_API
void SetScrollX(
float scroll_x);
422 IMGUI_API
void SetScrollY(
float scroll_y);
423 IMGUI_API
float GetScrollMaxX();
424 IMGUI_API
float GetScrollMaxY();
425 IMGUI_API
void SetScrollHereX(
float center_x_ratio = 0.5f);
426 IMGUI_API
void SetScrollHereY(
float center_y_ratio = 0.5f);
427 IMGUI_API
void SetScrollFromPosX(
float local_x,
float center_x_ratio = 0.5f);
428 IMGUI_API
void SetScrollFromPosY(
float local_y,
float center_y_ratio = 0.5f);
431 IMGUI_API
void PushFont(
ImFont* font);
432 IMGUI_API
void PopFont();
433 IMGUI_API
void PushStyleColor(ImGuiCol idx, ImU32 col);
434 IMGUI_API
void PushStyleColor(ImGuiCol idx,
const ImVec4& col);
435 IMGUI_API
void PopStyleColor(
int count = 1);
436 IMGUI_API
void PushStyleVar(ImGuiStyleVar idx,
float val);
437 IMGUI_API
void PushStyleVar(ImGuiStyleVar idx,
const ImVec2& val);
438 IMGUI_API
void PopStyleVar(
int count = 1);
439 IMGUI_API
void PushTabStop(
bool tab_stop);
440 IMGUI_API
void PopTabStop();
441 IMGUI_API
void PushButtonRepeat(
bool repeat);
442 IMGUI_API
void PopButtonRepeat();
445 IMGUI_API
void PushItemWidth(
float item_width);
446 IMGUI_API
void PopItemWidth();
447 IMGUI_API
void SetNextItemWidth(
float item_width);
448 IMGUI_API
float CalcItemWidth();
449 IMGUI_API
void PushTextWrapPos(
float wrap_local_pos_x = 0.0f);
450 IMGUI_API
void PopTextWrapPos();
454 IMGUI_API
ImFont* GetFont();
455 IMGUI_API
float GetFontSize();
456 IMGUI_API
ImVec2 GetFontTexUvWhitePixel();
457 IMGUI_API ImU32 GetColorU32(ImGuiCol idx,
float alpha_mul = 1.0f);
458 IMGUI_API ImU32 GetColorU32(
const ImVec4& col);
459 IMGUI_API ImU32 GetColorU32(ImU32 col,
float alpha_mul = 1.0f);
460 IMGUI_API
const ImVec4& GetStyleColorVec4(ImGuiCol idx);
470 IMGUI_API
ImVec2 GetCursorScreenPos();
471 IMGUI_API
void SetCursorScreenPos(
const ImVec2& pos);
472 IMGUI_API
ImVec2 GetCursorPos();
473 IMGUI_API
float GetCursorPosX();
474 IMGUI_API
float GetCursorPosY();
475 IMGUI_API
void SetCursorPos(
const ImVec2& local_pos);
476 IMGUI_API
void SetCursorPosX(
float local_x);
477 IMGUI_API
void SetCursorPosY(
float local_y);
478 IMGUI_API
ImVec2 GetCursorStartPos();
481 IMGUI_API
void Separator();
482 IMGUI_API
void SameLine(
float offset_from_start_x=0.0f,
float spacing=-1.0f);
483 IMGUI_API
void NewLine();
484 IMGUI_API
void Spacing();
485 IMGUI_API
void Dummy(
const ImVec2& size);
486 IMGUI_API
void Indent(
float indent_w = 0.0f);
487 IMGUI_API
void Unindent(
float indent_w = 0.0f);
488 IMGUI_API
void BeginGroup();
489 IMGUI_API
void EndGroup();
490 IMGUI_API
void AlignTextToFramePadding();
491 IMGUI_API
float GetTextLineHeight();
492 IMGUI_API
float GetTextLineHeightWithSpacing();
493 IMGUI_API
float GetFrameHeight();
494 IMGUI_API
float GetFrameHeightWithSpacing();
507 IMGUI_API
void PushID(
const char* str_id);
508 IMGUI_API
void PushID(
const char* str_id_begin,
const char* str_id_end);
509 IMGUI_API
void PushID(
const void* ptr_id);
510 IMGUI_API
void PushID(
int int_id);
511 IMGUI_API
void PopID();
512 IMGUI_API ImGuiID GetID(
const char* str_id);
513 IMGUI_API ImGuiID GetID(
const char* str_id_begin,
const char* str_id_end);
514 IMGUI_API ImGuiID GetID(
const void* ptr_id);
517 IMGUI_API
void TextUnformatted(
const char* text,
const char* text_end = NULL);
518 IMGUI_API
void Text(
const char* fmt, ...) IM_FMTARGS(1);
519 IMGUI_API
void TextV(const
char* fmt, va_list args) IM_FMTLIST(1);
520 IMGUI_API
void TextColored(const
ImVec4& col, const
char* fmt, ...) IM_FMTARGS(2);
521 IMGUI_API
void TextColoredV(const
ImVec4& col, const
char* fmt, va_list args) IM_FMTLIST(2);
522 IMGUI_API
void TextDisabled(const
char* fmt, ...) IM_FMTARGS(1);
523 IMGUI_API
void TextDisabledV(const
char* fmt, va_list args) IM_FMTLIST(1);
524 IMGUI_API
void TextWrapped(const
char* fmt, ...) IM_FMTARGS(1);
525 IMGUI_API
void TextWrappedV(const
char* fmt, va_list args) IM_FMTLIST(1);
526 IMGUI_API
void LabelText(const
char* label, const
char* fmt, ...) IM_FMTARGS(2);
527 IMGUI_API
void LabelTextV(const
char* label, const
char* fmt, va_list args) IM_FMTLIST(2);
528 IMGUI_API
void BulletText(const
char* fmt, ...) IM_FMTARGS(1);
529 IMGUI_API
void BulletTextV(const
char* fmt, va_list args) IM_FMTLIST(1);
530 IMGUI_API
void SeparatorText(const
char* label);
535 IMGUI_API
bool Button(const
char* label, const
ImVec2& size =
ImVec2(0, 0));
536 IMGUI_API
bool SmallButton(const
char* label);
537 IMGUI_API
bool InvisibleButton(const
char* str_id, const
ImVec2& size, ImGuiButtonFlags flags = 0);
538 IMGUI_API
bool ArrowButton(const
char* str_id, ImGuiDir dir);
539 IMGUI_API
bool Checkbox(const
char* label,
bool* v);
540 IMGUI_API
bool CheckboxFlags(const
char* label,
int* flags,
int flags_value);
541 IMGUI_API
bool CheckboxFlags(const
char* label,
unsigned int* flags,
unsigned int flags_value);
542 IMGUI_API
bool RadioButton(const
char* label,
bool active);
543 IMGUI_API
bool RadioButton(const
char* label,
int* v,
int v_button);
544 IMGUI_API
void ProgressBar(
float fraction, const
ImVec2& size_arg =
ImVec2(-FLT_MIN, 0), const
char* overlay = NULL);
545 IMGUI_API
void Bullet();
551 IMGUI_API
void Image(ImTextureID user_texture_id, const
ImVec2& image_size, const
ImVec2& uv0 =
ImVec2(0, 0), const
ImVec2& uv1 =
ImVec2(1, 1), const
ImVec4& tint_col =
ImVec4(1, 1, 1, 1), const
ImVec4& border_col =
ImVec4(0, 0, 0, 0));
552 IMGUI_API
bool ImageButton(const
char* str_id, ImTextureID user_texture_id, const
ImVec2& image_size, const
ImVec2& uv0 =
ImVec2(0, 0), const
ImVec2& uv1 =
ImVec2(1, 1), const
ImVec4& bg_col =
ImVec4(0, 0, 0, 0), const
ImVec4& tint_col =
ImVec4(1, 1, 1, 1));
557 IMGUI_API
bool BeginCombo(const
char* label, const
char* preview_value, ImGuiComboFlags flags = 0);
558 IMGUI_API
void EndCombo();
559 IMGUI_API
bool Combo(const
char* label,
int* current_item, const
char* const items[],
int items_count,
int popup_max_height_in_items = -1);
560 IMGUI_API
bool Combo(const
char* label,
int* current_item, const
char* items_separated_by_zeros,
int popup_max_height_in_items = -1);
561 IMGUI_API
bool Combo(const
char* label,
int* current_item, const
char* (*getter)(
void* user_data,
int idx),
void* user_data,
int items_count,
int popup_max_height_in_items = -1);
575 IMGUI_API
bool DragFloat(const
char* label,
float* v,
float v_speed = 1.0f,
float v_min = 0.0f,
float v_max = 0.0f, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
576 IMGUI_API
bool DragFloat2(const
char* label,
float v[2],
float v_speed = 1.0f,
float v_min = 0.0f,
float v_max = 0.0f, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
577 IMGUI_API
bool DragFloat3(const
char* label,
float v[3],
float v_speed = 1.0f,
float v_min = 0.0f,
float v_max = 0.0f, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
578 IMGUI_API
bool DragFloat4(const
char* label,
float v[4],
float v_speed = 1.0f,
float v_min = 0.0f,
float v_max = 0.0f, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
579 IMGUI_API
bool DragFloatRange2(const
char* label,
float* v_current_min,
float* v_current_max,
float v_speed = 1.0f,
float v_min = 0.0f,
float v_max = 0.0f, const
char* format = "%.3f", const
char* format_max = NULL, ImGuiSliderFlags flags = 0);
580 IMGUI_API
bool DragInt(const
char* label,
int* v,
float v_speed = 1.0f,
int v_min = 0,
int v_max = 0, const
char* format = "%d", ImGuiSliderFlags flags = 0);
581 IMGUI_API
bool DragInt2(const
char* label,
int v[2],
float v_speed = 1.0f,
int v_min = 0,
int v_max = 0, const
char* format = "%d", ImGuiSliderFlags flags = 0);
582 IMGUI_API
bool DragInt3(const
char* label,
int v[3],
float v_speed = 1.0f,
int v_min = 0,
int v_max = 0, const
char* format = "%d", ImGuiSliderFlags flags = 0);
583 IMGUI_API
bool DragInt4(const
char* label,
int v[4],
float v_speed = 1.0f,
int v_min = 0,
int v_max = 0, const
char* format = "%d", ImGuiSliderFlags flags = 0);
584 IMGUI_API
bool DragIntRange2(const
char* label,
int* v_current_min,
int* v_current_max,
float v_speed = 1.0f,
int v_min = 0,
int v_max = 0, const
char* format = "%d", const
char* format_max = NULL, ImGuiSliderFlags flags = 0);
585 IMGUI_API
bool DragScalar(const
char* label, ImGuiDataType data_type,
void* p_data,
float v_speed = 1.0f, const
void* p_min = NULL, const
void* p_max = NULL, const
char* format = NULL, ImGuiSliderFlags flags = 0);
586 IMGUI_API
bool DragScalarN(const
char* label, ImGuiDataType data_type,
void* p_data,
int components,
float v_speed = 1.0f, const
void* p_min = NULL, const
void* p_max = NULL, const
char* format = NULL, ImGuiSliderFlags flags = 0);
594 IMGUI_API
bool SliderFloat(const
char* label,
float* v,
float v_min,
float v_max, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
595 IMGUI_API
bool SliderFloat2(const
char* label,
float v[2],
float v_min,
float v_max, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
596 IMGUI_API
bool SliderFloat3(const
char* label,
float v[3],
float v_min,
float v_max, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
597 IMGUI_API
bool SliderFloat4(const
char* label,
float v[4],
float v_min,
float v_max, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
598 IMGUI_API
bool SliderAngle(const
char* label,
float* v_rad,
float v_degrees_min = -360.0f,
float v_degrees_max = +360.0f, const
char* format = "%.0f deg", ImGuiSliderFlags flags = 0);
599 IMGUI_API
bool SliderInt(const
char* label,
int* v,
int v_min,
int v_max, const
char* format = "%d", ImGuiSliderFlags flags = 0);
600 IMGUI_API
bool SliderInt2(const
char* label,
int v[2],
int v_min,
int v_max, const
char* format = "%d", ImGuiSliderFlags flags = 0);
601 IMGUI_API
bool SliderInt3(const
char* label,
int v[3],
int v_min,
int v_max, const
char* format = "%d", ImGuiSliderFlags flags = 0);
602 IMGUI_API
bool SliderInt4(const
char* label,
int v[4],
int v_min,
int v_max, const
char* format = "%d", ImGuiSliderFlags flags = 0);
603 IMGUI_API
bool SliderScalar(const
char* label, ImGuiDataType data_type,
void* p_data, const
void* p_min, const
void* p_max, const
char* format = NULL, ImGuiSliderFlags flags = 0);
604 IMGUI_API
bool SliderScalarN(const
char* label, ImGuiDataType data_type,
void* p_data,
int components, const
void* p_min, const
void* p_max, const
char* format = NULL, ImGuiSliderFlags flags = 0);
605 IMGUI_API
bool VSliderFloat(const
char* label, const
ImVec2& size,
float* v,
float v_min,
float v_max, const
char* format = "%.3f", ImGuiSliderFlags flags = 0);
606 IMGUI_API
bool VSliderInt(const
char* label, const
ImVec2& size,
int* v,
int v_min,
int v_max, const
char* format = "%d", ImGuiSliderFlags flags = 0);
607 IMGUI_API
bool VSliderScalar(const
char* label, const
ImVec2& size, ImGuiDataType data_type,
void* p_data, const
void* p_min, const
void* p_max, const
char* format = NULL, ImGuiSliderFlags flags = 0);
612 IMGUI_API
bool InputText(const
char* label,
char* buf,
size_t buf_size, ImGuiInputTextFlags flags = 0, ImGuiInputTextCallback callback = NULL,
void* user_data = NULL);
613 IMGUI_API
bool InputTextMultiline(const
char* label,
char* buf,
size_t buf_size, const
ImVec2& size =
ImVec2(0, 0), ImGuiInputTextFlags flags = 0, ImGuiInputTextCallback callback = NULL,
void* user_data = NULL);
614 IMGUI_API
bool InputTextWithHint(const
char* label, const
char* hint,
char* buf,
size_t buf_size, ImGuiInputTextFlags flags = 0, ImGuiInputTextCallback callback = NULL,
void* user_data = NULL);
615 IMGUI_API
bool InputFloat(const
char* label,
float* v,
float step = 0.0f,
float step_fast = 0.0f, const
char* format = "%.3f", ImGuiInputTextFlags flags = 0);
616 IMGUI_API
bool InputFloat2(const
char* label,
float v[2], const
char* format = "%.3f", ImGuiInputTextFlags flags = 0);
617 IMGUI_API
bool InputFloat3(const
char* label,
float v[3], const
char* format = "%.3f", ImGuiInputTextFlags flags = 0);
618 IMGUI_API
bool InputFloat4(const
char* label,
float v[4], const
char* format = "%.3f", ImGuiInputTextFlags flags = 0);
619 IMGUI_API
bool InputInt(const
char* label,
int* v,
int step = 1,
int step_fast = 100, ImGuiInputTextFlags flags = 0);
620 IMGUI_API
bool InputInt2(const
char* label,
int v[2], ImGuiInputTextFlags flags = 0);
621 IMGUI_API
bool InputInt3(const
char* label,
int v[3], ImGuiInputTextFlags flags = 0);
622 IMGUI_API
bool InputInt4(const
char* label,
int v[4], ImGuiInputTextFlags flags = 0);
623 IMGUI_API
bool InputDouble(const
char* label,
double* v,
double step = 0.0,
double step_fast = 0.0, const
char* format = "%.6f", ImGuiInputTextFlags flags = 0);
624 IMGUI_API
bool InputScalar(const
char* label, ImGuiDataType data_type,
void* p_data, const
void* p_step = NULL, const
void* p_step_fast = NULL, const
char* format = NULL, ImGuiInputTextFlags flags = 0);
625 IMGUI_API
bool InputScalarN(const
char* label, ImGuiDataType data_type,
void* p_data,
int components, const
void* p_step = NULL, const
void* p_step_fast = NULL, const
char* format = NULL, ImGuiInputTextFlags flags = 0);
630 IMGUI_API
bool ColorEdit3(const
char* label,
float col[3], ImGuiColorEditFlags flags = 0);
631 IMGUI_API
bool ColorEdit4(const
char* label,
float col[4], ImGuiColorEditFlags flags = 0);
632 IMGUI_API
bool ColorPicker3(const
char* label,
float col[3], ImGuiColorEditFlags flags = 0);
633 IMGUI_API
bool ColorPicker4(const
char* label,
float col[4], ImGuiColorEditFlags flags = 0, const
float* ref_col = NULL);
634 IMGUI_API
bool ColorButton(const
char* desc_id, const
ImVec4& col, ImGuiColorEditFlags flags = 0, const
ImVec2& size =
ImVec2(0, 0));
635 IMGUI_API
void SetColorEditOptions(ImGuiColorEditFlags flags);
639 IMGUI_API
bool TreeNode(const
char* label);
640 IMGUI_API
bool TreeNode(const
char* str_id, const
char* fmt, ...) IM_FMTARGS(2);
641 IMGUI_API
bool TreeNode(const
void* ptr_id, const
char* fmt, ...) IM_FMTARGS(2);
642 IMGUI_API
bool TreeNodeV(const
char* str_id, const
char* fmt, va_list args) IM_FMTLIST(2);
643 IMGUI_API
bool TreeNodeV(const
void* ptr_id, const
char* fmt, va_list args) IM_FMTLIST(2);
644 IMGUI_API
bool TreeNodeEx(const
char* label, ImGuiTreeNodeFlags flags = 0);
645 IMGUI_API
bool TreeNodeEx(const
char* str_id, ImGuiTreeNodeFlags flags, const
char* fmt, ...) IM_FMTARGS(3);
646 IMGUI_API
bool TreeNodeEx(const
void* ptr_id, ImGuiTreeNodeFlags flags, const
char* fmt, ...) IM_FMTARGS(3);
647 IMGUI_API
bool TreeNodeExV(const
char* str_id, ImGuiTreeNodeFlags flags, const
char* fmt, va_list args) IM_FMTLIST(3);
648 IMGUI_API
bool TreeNodeExV(const
void* ptr_id, ImGuiTreeNodeFlags flags, const
char* fmt, va_list args) IM_FMTLIST(3);
649 IMGUI_API
void TreePush(const
char* str_id);
650 IMGUI_API
void TreePush(const
void* ptr_id);
651 IMGUI_API
void TreePop();
652 IMGUI_API
float GetTreeNodeToLabelSpacing();
653 IMGUI_API
bool CollapsingHeader(const
char* label, ImGuiTreeNodeFlags flags = 0);
654 IMGUI_API
bool CollapsingHeader(const
char* label,
bool* p_visible, ImGuiTreeNodeFlags flags = 0);
655 IMGUI_API
void SetNextItemOpen(
bool is_open, ImGuiCond cond = 0);
660 IMGUI_API
bool Selectable(const
char* label,
bool selected = false, ImGuiSelectableFlags flags = 0, const
ImVec2& size =
ImVec2(0, 0));
661 IMGUI_API
bool Selectable(const
char* label,
bool* p_selected, ImGuiSelectableFlags flags = 0, const
ImVec2& size =
ImVec2(0, 0));
669 IMGUI_API
bool BeginListBox(const
char* label, const
ImVec2& size =
ImVec2(0, 0));
670 IMGUI_API
void EndListBox();
671 IMGUI_API
bool ListBox(const
char* label,
int* current_item, const
char* const items[],
int items_count,
int height_in_items = -1);
672 IMGUI_API
bool ListBox(const
char* label,
int* current_item, const
char* (*getter)(
void* user_data,
int idx),
void* user_data,
int items_count,
int height_in_items = -1);
676 IMGUI_API
void PlotLines(const
char* label, const
float* values,
int values_count,
int values_offset = 0, const
char* overlay_text = NULL,
float scale_min = FLT_MAX,
float scale_max = FLT_MAX,
ImVec2 graph_size =
ImVec2(0, 0),
int stride = sizeof(
float));
677 IMGUI_API
void PlotLines(const
char* label,
float(*values_getter)(
void* data,
int idx),
void* data,
int values_count,
int values_offset = 0, const
char* overlay_text = NULL,
float scale_min = FLT_MAX,
float scale_max = FLT_MAX,
ImVec2 graph_size =
ImVec2(0, 0));
678 IMGUI_API
void PlotHistogram(const
char* label, const
float* values,
int values_count,
int values_offset = 0, const
char* overlay_text = NULL,
float scale_min = FLT_MAX,
float scale_max = FLT_MAX,
ImVec2 graph_size =
ImVec2(0, 0),
int stride = sizeof(
float));
679 IMGUI_API
void PlotHistogram(const
char* label,
float (*values_getter)(
void* data,
int idx),
void* data,
int values_count,
int values_offset = 0, const
char* overlay_text = NULL,
float scale_min = FLT_MAX,
float scale_max = FLT_MAX,
ImVec2 graph_size =
ImVec2(0, 0));
683 IMGUI_API
void Value(const
char* prefix,
bool b);
684 IMGUI_API
void Value(const
char* prefix,
int v);
685 IMGUI_API
void Value(const
char* prefix,
unsigned int v);
686 IMGUI_API
void Value(const
char* prefix,
float v, const
char* float_format = NULL);
693 IMGUI_API
bool BeginMenuBar();
694 IMGUI_API
void EndMenuBar();
695 IMGUI_API
bool BeginMainMenuBar();
696 IMGUI_API
void EndMainMenuBar();
697 IMGUI_API
bool BeginMenu(const
char* label,
bool enabled = true);
698 IMGUI_API
void EndMenu();
699 IMGUI_API
bool MenuItem(const
char* label, const
char* shortcut = NULL,
bool selected = false,
bool enabled = true);
700 IMGUI_API
bool MenuItem(const
char* label, const
char* shortcut,
bool* p_selected,
bool enabled = true);
706 IMGUI_API
bool BeginTooltip();
707 IMGUI_API
void EndTooltip();
708 IMGUI_API
void SetTooltip(const
char* fmt, ...) IM_FMTARGS(1);
709 IMGUI_API
void SetTooltipV(const
char* fmt, va_list args) IM_FMTLIST(1);
715 IMGUI_API
bool BeginItemTooltip();
716 IMGUI_API
void SetItemTooltip(const
char* fmt, ...) IM_FMTARGS(1);
717 IMGUI_API
void SetItemTooltipV(const
char* fmt, va_list args) IM_FMTLIST(1);
729 IMGUI_API
bool BeginPopup(const
char* str_id, ImGuiWindowFlags flags = 0);
730 IMGUI_API
bool BeginPopupModal(const
char* name,
bool* p_open = NULL, ImGuiWindowFlags flags = 0);
731 IMGUI_API
void EndPopup();
741 IMGUI_API
void OpenPopup(const
char* str_id, ImGuiPopupFlags popup_flags = 0);
742 IMGUI_API
void OpenPopup(ImGuiID
id, ImGuiPopupFlags popup_flags = 0);
743 IMGUI_API
void OpenPopupOnItemClick(const
char* str_id = NULL, ImGuiPopupFlags popup_flags = 1);
744 IMGUI_API
void CloseCurrentPopup();
751 IMGUI_API
bool BeginPopupContextItem(const
char* str_id = NULL, ImGuiPopupFlags popup_flags = 1);
752 IMGUI_API
bool BeginPopupContextWindow(const
char* str_id = NULL, ImGuiPopupFlags popup_flags = 1);
753 IMGUI_API
bool BeginPopupContextVoid(const
char* str_id = NULL, ImGuiPopupFlags popup_flags = 1);
759 IMGUI_API
bool IsPopupOpen(const
char* str_id, ImGuiPopupFlags flags = 0);
782 IMGUI_API
bool BeginTable(const
char* str_id,
int columns, ImGuiTableFlags flags = 0, const
ImVec2& outer_size =
ImVec2(0.0f, 0.0f),
float inner_width = 0.0f);
783 IMGUI_API
void EndTable();
784 IMGUI_API
void TableNextRow(ImGuiTableRowFlags row_flags = 0,
float min_row_height = 0.0f);
785 IMGUI_API
bool TableNextColumn();
786 IMGUI_API
bool TableSetColumnIndex(
int column_n);
796 IMGUI_API
void TableSetupColumn(const
char* label, ImGuiTableColumnFlags flags = 0,
float init_width_or_weight = 0.0f, ImGuiID user_id = 0);
797 IMGUI_API
void TableSetupScrollFreeze(
int cols,
int rows);
798 IMGUI_API
void TableHeader(const
char* label);
799 IMGUI_API
void TableHeadersRow();
800 IMGUI_API
void TableAngledHeadersRow();
809 IMGUI_API
int TableGetColumnCount();
810 IMGUI_API
int TableGetColumnIndex();
811 IMGUI_API
int TableGetRowIndex();
812 IMGUI_API const
char* TableGetColumnName(
int column_n = -1);
813 IMGUI_API ImGuiTableColumnFlags TableGetColumnFlags(
int column_n = -1);
814 IMGUI_API
void TableSetColumnEnabled(
int column_n,
bool v);
815 IMGUI_API
int TableGetHoveredColumn();
816 IMGUI_API
void TableSetBgColor(ImGuiTableBgTarget target, ImU32 color,
int column_n = -1);
820 IMGUI_API
void Columns(
int count = 1, const
char*
id = NULL,
bool border = true);
821 IMGUI_API
void NextColumn();
822 IMGUI_API
int GetColumnIndex();
823 IMGUI_API
float GetColumnWidth(
int column_index = -1);
824 IMGUI_API
void SetColumnWidth(
int column_index,
float width);
825 IMGUI_API
float GetColumnOffset(
int column_index = -1);
826 IMGUI_API
void SetColumnOffset(
int column_index,
float offset_x);
827 IMGUI_API
int GetColumnsCount();
831 IMGUI_API
bool BeginTabBar(const
char* str_id, ImGuiTabBarFlags flags = 0);
832 IMGUI_API
void EndTabBar();
833 IMGUI_API
bool BeginTabItem(const
char* label,
bool* p_open = NULL, ImGuiTabItemFlags flags = 0);
834 IMGUI_API
void EndTabItem();
835 IMGUI_API
bool TabItemButton(const
char* label, ImGuiTabItemFlags flags = 0);
836 IMGUI_API
void SetTabItemClosed(const
char* tab_or_docked_window_label);
840 IMGUI_API
void LogToTTY(
int auto_open_depth = -1);
841 IMGUI_API
void LogToFile(
int auto_open_depth = -1, const
char* filename = NULL);
842 IMGUI_API
void LogToClipboard(
int auto_open_depth = -1);
843 IMGUI_API
void LogFinish();
844 IMGUI_API
void LogButtons();
845 IMGUI_API
void LogText(const
char* fmt, ...) IM_FMTARGS(1);
846 IMGUI_API
void LogTextV(const
char* fmt, va_list args) IM_FMTLIST(1);
853 IMGUI_API
bool BeginDragDropSource(ImGuiDragDropFlags flags = 0);
854 IMGUI_API
bool SetDragDropPayload(const
char* type, const
void* data,
size_t sz, ImGuiCond cond = 0);
855 IMGUI_API
void EndDragDropSource();
856 IMGUI_API
bool BeginDragDropTarget();
857 IMGUI_API const
ImGuiPayload* AcceptDragDropPayload(const
char* type, ImGuiDragDropFlags flags = 0);
858 IMGUI_API
void EndDragDropTarget();
866 IMGUI_API
void BeginDisabled(
bool disabled = true);
867 IMGUI_API
void EndDisabled();
871 IMGUI_API
void PushClipRect(const
ImVec2& clip_rect_min, const
ImVec2& clip_rect_max,
bool intersect_with_current_clip_rect);
872 IMGUI_API
void PopClipRect();
876 IMGUI_API
void SetItemDefaultFocus();
877 IMGUI_API
void SetKeyboardFocusHere(
int offset = 0);
880 IMGUI_API
void SetNextItemAllowOverlap();
885 IMGUI_API
bool IsItemHovered(ImGuiHoveredFlags flags = 0);
886 IMGUI_API
bool IsItemActive();
887 IMGUI_API
bool IsItemFocused();
888 IMGUI_API
bool IsItemClicked(ImGuiMouseButton mouse_button = 0);
889 IMGUI_API
bool IsItemVisible();
890 IMGUI_API
bool IsItemEdited();
891 IMGUI_API
bool IsItemActivated();
892 IMGUI_API
bool IsItemDeactivated();
893 IMGUI_API
bool IsItemDeactivatedAfterEdit();
894 IMGUI_API
bool IsItemToggledOpen();
895 IMGUI_API
bool IsAnyItemHovered();
896 IMGUI_API
bool IsAnyItemActive();
897 IMGUI_API
bool IsAnyItemFocused();
898 IMGUI_API ImGuiID GetItemID();
899 IMGUI_API
ImVec2 GetItemRectMin();
900 IMGUI_API
ImVec2 GetItemRectMax();
901 IMGUI_API
ImVec2 GetItemRectSize();
910 IMGUI_API
ImDrawList* GetBackgroundDrawList();
911 IMGUI_API
ImDrawList* GetForegroundDrawList();
914 IMGUI_API
bool IsRectVisible(const
ImVec2& size);
915 IMGUI_API
bool IsRectVisible(const
ImVec2& rect_min, const
ImVec2& rect_max);
916 IMGUI_API
double GetTime();
917 IMGUI_API
int GetFrameCount();
919 IMGUI_API const
char* GetStyleColorName(ImGuiCol idx);
924 IMGUI_API
ImVec2 CalcTextSize(const
char* text, const
char* text_end = NULL,
bool hide_text_after_double_hash = false,
float wrap_width = -1.0f);
927 IMGUI_API
ImVec4 ColorConvertU32ToFloat4(ImU32 in);
928 IMGUI_API ImU32 ColorConvertFloat4ToU32(const
ImVec4& in);
929 IMGUI_API
void ColorConvertRGBtoHSV(
float r,
float g,
float b,
float& out_h,
float& out_s,
float& out_v);
930 IMGUI_API
void ColorConvertHSVtoRGB(
float h,
float s,
float v,
float& out_r,
float& out_g,
float& out_b);
937 IMGUI_API
bool IsKeyDown(ImGuiKey key);
938 IMGUI_API
bool IsKeyPressed(ImGuiKey key,
bool repeat = true);
939 IMGUI_API
bool IsKeyReleased(ImGuiKey key);
940 IMGUI_API
bool IsKeyChordPressed(ImGuiKeyChord key_chord);
941 IMGUI_API
int GetKeyPressedAmount(ImGuiKey key,
float repeat_delay,
float rate);
942 IMGUI_API const
char* GetKeyName(ImGuiKey key);
943 IMGUI_API
void SetNextFrameWantCaptureKeyboard(
bool want_capture_keyboard);
960 IMGUI_API
bool Shortcut(ImGuiKeyChord key_chord, ImGuiInputFlags flags = 0);
961 IMGUI_API
void SetNextItemShortcut(ImGuiKeyChord key_chord, ImGuiInputFlags flags = 0);
967 IMGUI_API
bool IsMouseDown(ImGuiMouseButton button);
968 IMGUI_API
bool IsMouseClicked(ImGuiMouseButton button,
bool repeat = false);
969 IMGUI_API
bool IsMouseReleased(ImGuiMouseButton button);
970 IMGUI_API
bool IsMouseDoubleClicked(ImGuiMouseButton button);
971 IMGUI_API
int GetMouseClickedCount(ImGuiMouseButton button);
972 IMGUI_API
bool IsMouseHoveringRect(const
ImVec2& r_min, const
ImVec2& r_max,
bool clip = true);
973 IMGUI_API
bool IsMousePosValid(const
ImVec2* mouse_pos = NULL);
974 IMGUI_API
bool IsAnyMouseDown();
975 IMGUI_API
ImVec2 GetMousePos();
976 IMGUI_API
ImVec2 GetMousePosOnOpeningCurrentPopup();
977 IMGUI_API
bool IsMouseDragging(ImGuiMouseButton button,
float lock_threshold = -1.0f);
978 IMGUI_API
ImVec2 GetMouseDragDelta(ImGuiMouseButton button = 0,
float lock_threshold = -1.0f);
979 IMGUI_API
void ResetMouseDragDelta(ImGuiMouseButton button = 0);
980 IMGUI_API ImGuiMouseCursor GetMouseCursor();
981 IMGUI_API
void SetMouseCursor(ImGuiMouseCursor cursor_type);
982 IMGUI_API
void SetNextFrameWantCaptureMouse(
bool want_capture_mouse);
986 IMGUI_API const
char* GetClipboardText();
987 IMGUI_API
void SetClipboardText(const
char* text);
993 IMGUI_API
void LoadIniSettingsFromDisk(const
char* ini_filename);
994 IMGUI_API
void LoadIniSettingsFromMemory(const
char* ini_data,
size_t ini_size=0);
995 IMGUI_API
void SaveIniSettingsToDisk(const
char* ini_filename);
996 IMGUI_API const
char* SaveIniSettingsToMemory(
size_t* out_ini_size = NULL);
1000 IMGUI_API
void DebugTextEncoding(const
char* text);
1001 IMGUI_API
void DebugFlashStyleColor(ImGuiCol idx);
1002 IMGUI_API
void DebugStartItemPicker();
1003 IMGUI_API
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,
size_t sz_drawidx);
1009 IMGUI_API
void SetAllocatorFunctions(ImGuiMemAllocFunc alloc_func, ImGuiMemFreeFunc free_func,
void* user_data = NULL);
1010 IMGUI_API
void GetAllocatorFunctions(ImGuiMemAllocFunc* p_alloc_func, ImGuiMemFreeFunc* p_free_func,
void** p_user_data);
1011 IMGUI_API
void* MemAlloc(
size_t size);
1012 IMGUI_API
void MemFree(
void* ptr);
1022enum ImGuiWindowFlags_
1024 ImGuiWindowFlags_None = 0,
1025 ImGuiWindowFlags_NoTitleBar = 1 << 0,
1026 ImGuiWindowFlags_NoResize = 1 << 1,
1027 ImGuiWindowFlags_NoMove = 1 << 2,
1028 ImGuiWindowFlags_NoScrollbar = 1 << 3,
1029 ImGuiWindowFlags_NoScrollWithMouse = 1 << 4,
1030 ImGuiWindowFlags_NoCollapse = 1 << 5,
1031 ImGuiWindowFlags_AlwaysAutoResize = 1 << 6,
1032 ImGuiWindowFlags_NoBackground = 1 << 7,
1033 ImGuiWindowFlags_NoSavedSettings = 1 << 8,
1034 ImGuiWindowFlags_NoMouseInputs = 1 << 9,
1035 ImGuiWindowFlags_MenuBar = 1 << 10,
1036 ImGuiWindowFlags_HorizontalScrollbar = 1 << 11,
1037 ImGuiWindowFlags_NoFocusOnAppearing = 1 << 12,
1038 ImGuiWindowFlags_NoBringToFrontOnFocus = 1 << 13,
1039 ImGuiWindowFlags_AlwaysVerticalScrollbar= 1 << 14,
1040 ImGuiWindowFlags_AlwaysHorizontalScrollbar=1<< 15,
1041 ImGuiWindowFlags_NoNavInputs = 1 << 16,
1042 ImGuiWindowFlags_NoNavFocus = 1 << 17,
1043 ImGuiWindowFlags_UnsavedDocument = 1 << 18,
1044 ImGuiWindowFlags_NoNav = ImGuiWindowFlags_NoNavInputs | ImGuiWindowFlags_NoNavFocus,
1045 ImGuiWindowFlags_NoDecoration = ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoScrollbar | ImGuiWindowFlags_NoCollapse,
1046 ImGuiWindowFlags_NoInputs = ImGuiWindowFlags_NoMouseInputs | ImGuiWindowFlags_NoNavInputs | ImGuiWindowFlags_NoNavFocus,
1049 ImGuiWindowFlags_ChildWindow = 1 << 24,
1050 ImGuiWindowFlags_Tooltip = 1 << 25,
1051 ImGuiWindowFlags_Popup = 1 << 26,
1052 ImGuiWindowFlags_Modal = 1 << 27,
1053 ImGuiWindowFlags_ChildMenu = 1 << 28,
1056#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
1057 ImGuiWindowFlags_AlwaysUseWindowPadding = 1 << 30,
1058 ImGuiWindowFlags_NavFlattened = 1 << 31,
1071enum ImGuiChildFlags_
1073 ImGuiChildFlags_None = 0,
1074 ImGuiChildFlags_Border = 1 << 0,
1075 ImGuiChildFlags_AlwaysUseWindowPadding = 1 << 1,
1076 ImGuiChildFlags_ResizeX = 1 << 2,
1077 ImGuiChildFlags_ResizeY = 1 << 3,
1078 ImGuiChildFlags_AutoResizeX = 1 << 4,
1079 ImGuiChildFlags_AutoResizeY = 1 << 5,
1080 ImGuiChildFlags_AlwaysAutoResize = 1 << 6,
1081 ImGuiChildFlags_FrameStyle = 1 << 7,
1082 ImGuiChildFlags_NavFlattened = 1 << 8,
1087enum ImGuiInputTextFlags_
1090 ImGuiInputTextFlags_None = 0,
1091 ImGuiInputTextFlags_CharsDecimal = 1 << 0,
1092 ImGuiInputTextFlags_CharsHexadecimal = 1 << 1,
1093 ImGuiInputTextFlags_CharsScientific = 1 << 2,
1094 ImGuiInputTextFlags_CharsUppercase = 1 << 3,
1095 ImGuiInputTextFlags_CharsNoBlank = 1 << 4,
1098 ImGuiInputTextFlags_AllowTabInput = 1 << 5,
1099 ImGuiInputTextFlags_EnterReturnsTrue = 1 << 6,
1100 ImGuiInputTextFlags_EscapeClearsAll = 1 << 7,
1101 ImGuiInputTextFlags_CtrlEnterForNewLine = 1 << 8,
1104 ImGuiInputTextFlags_ReadOnly = 1 << 9,
1105 ImGuiInputTextFlags_Password = 1 << 10,
1106 ImGuiInputTextFlags_AlwaysOverwrite = 1 << 11,
1107 ImGuiInputTextFlags_AutoSelectAll = 1 << 12,
1108 ImGuiInputTextFlags_ParseEmptyRefVal = 1 << 13,
1109 ImGuiInputTextFlags_DisplayEmptyRefVal = 1 << 14,
1110 ImGuiInputTextFlags_NoHorizontalScroll = 1 << 15,
1111 ImGuiInputTextFlags_NoUndoRedo = 1 << 16,
1114 ImGuiInputTextFlags_CallbackCompletion = 1 << 17,
1115 ImGuiInputTextFlags_CallbackHistory = 1 << 18,
1116 ImGuiInputTextFlags_CallbackAlways = 1 << 19,
1117 ImGuiInputTextFlags_CallbackCharFilter = 1 << 20,
1118 ImGuiInputTextFlags_CallbackResize = 1 << 21,
1119 ImGuiInputTextFlags_CallbackEdit = 1 << 22,
1126enum ImGuiTreeNodeFlags_
1128 ImGuiTreeNodeFlags_None = 0,
1129 ImGuiTreeNodeFlags_Selected = 1 << 0,
1130 ImGuiTreeNodeFlags_Framed = 1 << 1,
1131 ImGuiTreeNodeFlags_AllowOverlap = 1 << 2,
1132 ImGuiTreeNodeFlags_NoTreePushOnOpen = 1 << 3,
1133 ImGuiTreeNodeFlags_NoAutoOpenOnLog = 1 << 4,
1134 ImGuiTreeNodeFlags_DefaultOpen = 1 << 5,
1135 ImGuiTreeNodeFlags_OpenOnDoubleClick = 1 << 6,
1136 ImGuiTreeNodeFlags_OpenOnArrow = 1 << 7,
1137 ImGuiTreeNodeFlags_Leaf = 1 << 8,
1138 ImGuiTreeNodeFlags_Bullet = 1 << 9,
1139 ImGuiTreeNodeFlags_FramePadding = 1 << 10,
1140 ImGuiTreeNodeFlags_SpanAvailWidth = 1 << 11,
1141 ImGuiTreeNodeFlags_SpanFullWidth = 1 << 12,
1142 ImGuiTreeNodeFlags_SpanTextWidth = 1 << 13,
1143 ImGuiTreeNodeFlags_SpanAllColumns = 1 << 14,
1144 ImGuiTreeNodeFlags_NavLeftJumpsBackHere = 1 << 15,
1146 ImGuiTreeNodeFlags_CollapsingHeader = ImGuiTreeNodeFlags_Framed | ImGuiTreeNodeFlags_NoTreePushOnOpen | ImGuiTreeNodeFlags_NoAutoOpenOnLog,
1148#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
1149 ImGuiTreeNodeFlags_AllowItemOverlap = ImGuiTreeNodeFlags_AllowOverlap,
1161enum ImGuiPopupFlags_
1163 ImGuiPopupFlags_None = 0,
1164 ImGuiPopupFlags_MouseButtonLeft = 0,
1165 ImGuiPopupFlags_MouseButtonRight = 1,
1166 ImGuiPopupFlags_MouseButtonMiddle = 2,
1167 ImGuiPopupFlags_MouseButtonMask_ = 0x1F,
1168 ImGuiPopupFlags_MouseButtonDefault_ = 1,
1169 ImGuiPopupFlags_NoReopen = 1 << 5,
1171 ImGuiPopupFlags_NoOpenOverExistingPopup = 1 << 7,
1172 ImGuiPopupFlags_NoOpenOverItems = 1 << 8,
1173 ImGuiPopupFlags_AnyPopupId = 1 << 10,
1174 ImGuiPopupFlags_AnyPopupLevel = 1 << 11,
1175 ImGuiPopupFlags_AnyPopup = ImGuiPopupFlags_AnyPopupId | ImGuiPopupFlags_AnyPopupLevel,
1179enum ImGuiSelectableFlags_
1181 ImGuiSelectableFlags_None = 0,
1182 ImGuiSelectableFlags_DontClosePopups = 1 << 0,
1183 ImGuiSelectableFlags_SpanAllColumns = 1 << 1,
1184 ImGuiSelectableFlags_AllowDoubleClick = 1 << 2,
1185 ImGuiSelectableFlags_Disabled = 1 << 3,
1186 ImGuiSelectableFlags_AllowOverlap = 1 << 4,
1188#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
1189 ImGuiSelectableFlags_AllowItemOverlap = ImGuiSelectableFlags_AllowOverlap,
1194enum ImGuiComboFlags_
1196 ImGuiComboFlags_None = 0,
1197 ImGuiComboFlags_PopupAlignLeft = 1 << 0,
1198 ImGuiComboFlags_HeightSmall = 1 << 1,
1199 ImGuiComboFlags_HeightRegular = 1 << 2,
1200 ImGuiComboFlags_HeightLarge = 1 << 3,
1201 ImGuiComboFlags_HeightLargest = 1 << 4,
1202 ImGuiComboFlags_NoArrowButton = 1 << 5,
1203 ImGuiComboFlags_NoPreview = 1 << 6,
1204 ImGuiComboFlags_WidthFitPreview = 1 << 7,
1205 ImGuiComboFlags_HeightMask_ = ImGuiComboFlags_HeightSmall | ImGuiComboFlags_HeightRegular | ImGuiComboFlags_HeightLarge | ImGuiComboFlags_HeightLargest,
1209enum ImGuiTabBarFlags_
1211 ImGuiTabBarFlags_None = 0,
1212 ImGuiTabBarFlags_Reorderable = 1 << 0,
1213 ImGuiTabBarFlags_AutoSelectNewTabs = 1 << 1,
1214 ImGuiTabBarFlags_TabListPopupButton = 1 << 2,
1215 ImGuiTabBarFlags_NoCloseWithMiddleMouseButton = 1 << 3,
1216 ImGuiTabBarFlags_NoTabListScrollingButtons = 1 << 4,
1217 ImGuiTabBarFlags_NoTooltip = 1 << 5,
1218 ImGuiTabBarFlags_DrawSelectedOverline = 1 << 6,
1219 ImGuiTabBarFlags_FittingPolicyResizeDown = 1 << 7,
1220 ImGuiTabBarFlags_FittingPolicyScroll = 1 << 8,
1221 ImGuiTabBarFlags_FittingPolicyMask_ = ImGuiTabBarFlags_FittingPolicyResizeDown | ImGuiTabBarFlags_FittingPolicyScroll,
1222 ImGuiTabBarFlags_FittingPolicyDefault_ = ImGuiTabBarFlags_FittingPolicyResizeDown,
1226enum ImGuiTabItemFlags_
1228 ImGuiTabItemFlags_None = 0,
1229 ImGuiTabItemFlags_UnsavedDocument = 1 << 0,
1230 ImGuiTabItemFlags_SetSelected = 1 << 1,
1231 ImGuiTabItemFlags_NoCloseWithMiddleMouseButton = 1 << 2,
1232 ImGuiTabItemFlags_NoPushId = 1 << 3,
1233 ImGuiTabItemFlags_NoTooltip = 1 << 4,
1234 ImGuiTabItemFlags_NoReorder = 1 << 5,
1235 ImGuiTabItemFlags_Leading = 1 << 6,
1236 ImGuiTabItemFlags_Trailing = 1 << 7,
1237 ImGuiTabItemFlags_NoAssumedClosure = 1 << 8,
1241enum ImGuiFocusedFlags_
1243 ImGuiFocusedFlags_None = 0,
1244 ImGuiFocusedFlags_ChildWindows = 1 << 0,
1245 ImGuiFocusedFlags_RootWindow = 1 << 1,
1246 ImGuiFocusedFlags_AnyWindow = 1 << 2,
1247 ImGuiFocusedFlags_NoPopupHierarchy = 1 << 3,
1249 ImGuiFocusedFlags_RootAndChildWindows = ImGuiFocusedFlags_RootWindow | ImGuiFocusedFlags_ChildWindows,
1255enum ImGuiHoveredFlags_
1257 ImGuiHoveredFlags_None = 0,
1258 ImGuiHoveredFlags_ChildWindows = 1 << 0,
1259 ImGuiHoveredFlags_RootWindow = 1 << 1,
1260 ImGuiHoveredFlags_AnyWindow = 1 << 2,
1261 ImGuiHoveredFlags_NoPopupHierarchy = 1 << 3,
1263 ImGuiHoveredFlags_AllowWhenBlockedByPopup = 1 << 5,
1265 ImGuiHoveredFlags_AllowWhenBlockedByActiveItem = 1 << 7,
1266 ImGuiHoveredFlags_AllowWhenOverlappedByItem = 1 << 8,
1267 ImGuiHoveredFlags_AllowWhenOverlappedByWindow = 1 << 9,
1268 ImGuiHoveredFlags_AllowWhenDisabled = 1 << 10,
1269 ImGuiHoveredFlags_NoNavOverride = 1 << 11,
1270 ImGuiHoveredFlags_AllowWhenOverlapped = ImGuiHoveredFlags_AllowWhenOverlappedByItem | ImGuiHoveredFlags_AllowWhenOverlappedByWindow,
1271 ImGuiHoveredFlags_RectOnly = ImGuiHoveredFlags_AllowWhenBlockedByPopup | ImGuiHoveredFlags_AllowWhenBlockedByActiveItem | ImGuiHoveredFlags_AllowWhenOverlapped,
1272 ImGuiHoveredFlags_RootAndChildWindows = ImGuiHoveredFlags_RootWindow | ImGuiHoveredFlags_ChildWindows,
1280 ImGuiHoveredFlags_ForTooltip = 1 << 12,
1285 ImGuiHoveredFlags_Stationary = 1 << 13,
1286 ImGuiHoveredFlags_DelayNone = 1 << 14,
1287 ImGuiHoveredFlags_DelayShort = 1 << 15,
1288 ImGuiHoveredFlags_DelayNormal = 1 << 16,
1289 ImGuiHoveredFlags_NoSharedDelay = 1 << 17,
1293enum ImGuiDragDropFlags_
1295 ImGuiDragDropFlags_None = 0,
1297 ImGuiDragDropFlags_SourceNoPreviewTooltip = 1 << 0,
1298 ImGuiDragDropFlags_SourceNoDisableHover = 1 << 1,
1299 ImGuiDragDropFlags_SourceNoHoldToOpenOthers = 1 << 2,
1300 ImGuiDragDropFlags_SourceAllowNullID = 1 << 3,
1301 ImGuiDragDropFlags_SourceExtern = 1 << 4,
1302 ImGuiDragDropFlags_PayloadAutoExpire = 1 << 5,
1303 ImGuiDragDropFlags_PayloadNoCrossContext = 1 << 6,
1304 ImGuiDragDropFlags_PayloadNoCrossProcess = 1 << 7,
1306 ImGuiDragDropFlags_AcceptBeforeDelivery = 1 << 10,
1307 ImGuiDragDropFlags_AcceptNoDrawDefaultRect = 1 << 11,
1308 ImGuiDragDropFlags_AcceptNoPreviewTooltip = 1 << 12,
1309 ImGuiDragDropFlags_AcceptPeekOnly = ImGuiDragDropFlags_AcceptBeforeDelivery | ImGuiDragDropFlags_AcceptNoDrawDefaultRect,
1311#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
1312 ImGuiDragDropFlags_SourceAutoExpirePayload = ImGuiDragDropFlags_PayloadAutoExpire,
1317#define IMGUI_PAYLOAD_TYPE_COLOR_3F "_COL3F"
1318#define IMGUI_PAYLOAD_TYPE_COLOR_4F "_COL4F"
1331 ImGuiDataType_Float,
1332 ImGuiDataType_Double,
1348enum ImGuiSortDirection : ImU8
1350 ImGuiSortDirection_None = 0,
1351 ImGuiSortDirection_Ascending = 1,
1352 ImGuiSortDirection_Descending = 2
1356#if defined(IMGUI_DISABLE_OBSOLETE_FUNCTIONS) && !defined(IMGUI_DISABLE_OBSOLETE_KEYIO)
1357#define IMGUI_DISABLE_OBSOLETE_KEYIO
1372 ImGuiKey_RightArrow,
1385 ImGuiKey_LeftCtrl, ImGuiKey_LeftShift, ImGuiKey_LeftAlt, ImGuiKey_LeftSuper,
1386 ImGuiKey_RightCtrl, ImGuiKey_RightShift, ImGuiKey_RightAlt, ImGuiKey_RightSuper,
1388 ImGuiKey_0, ImGuiKey_1, ImGuiKey_2, ImGuiKey_3, ImGuiKey_4, ImGuiKey_5, ImGuiKey_6, ImGuiKey_7, ImGuiKey_8, ImGuiKey_9,
1389 ImGuiKey_A, ImGuiKey_B, ImGuiKey_C, ImGuiKey_D, ImGuiKey_E, ImGuiKey_F, ImGuiKey_G, ImGuiKey_H, ImGuiKey_I, ImGuiKey_J,
1390 ImGuiKey_K, ImGuiKey_L, ImGuiKey_M, ImGuiKey_N, ImGuiKey_O, ImGuiKey_P, ImGuiKey_Q, ImGuiKey_R, ImGuiKey_S, ImGuiKey_T,
1391 ImGuiKey_U, ImGuiKey_V, ImGuiKey_W, ImGuiKey_X, ImGuiKey_Y, ImGuiKey_Z,
1392 ImGuiKey_F1, ImGuiKey_F2, ImGuiKey_F3, ImGuiKey_F4, ImGuiKey_F5, ImGuiKey_F6,
1393 ImGuiKey_F7, ImGuiKey_F8, ImGuiKey_F9, ImGuiKey_F10, ImGuiKey_F11, ImGuiKey_F12,
1394 ImGuiKey_F13, ImGuiKey_F14, ImGuiKey_F15, ImGuiKey_F16, ImGuiKey_F17, ImGuiKey_F18,
1395 ImGuiKey_F19, ImGuiKey_F20, ImGuiKey_F21, ImGuiKey_F22, ImGuiKey_F23, ImGuiKey_F24,
1396 ImGuiKey_Apostrophe,
1403 ImGuiKey_LeftBracket,
1405 ImGuiKey_RightBracket,
1406 ImGuiKey_GraveAccent,
1408 ImGuiKey_ScrollLock,
1410 ImGuiKey_PrintScreen,
1412 ImGuiKey_Keypad0, ImGuiKey_Keypad1, ImGuiKey_Keypad2, ImGuiKey_Keypad3, ImGuiKey_Keypad4,
1413 ImGuiKey_Keypad5, ImGuiKey_Keypad6, ImGuiKey_Keypad7, ImGuiKey_Keypad8, ImGuiKey_Keypad9,
1414 ImGuiKey_KeypadDecimal,
1415 ImGuiKey_KeypadDivide,
1416 ImGuiKey_KeypadMultiply,
1417 ImGuiKey_KeypadSubtract,
1419 ImGuiKey_KeypadEnter,
1420 ImGuiKey_KeypadEqual,
1422 ImGuiKey_AppForward,
1426 ImGuiKey_GamepadStart,
1427 ImGuiKey_GamepadBack,
1428 ImGuiKey_GamepadFaceLeft,
1429 ImGuiKey_GamepadFaceRight,
1430 ImGuiKey_GamepadFaceUp,
1431 ImGuiKey_GamepadFaceDown,
1432 ImGuiKey_GamepadDpadLeft,
1433 ImGuiKey_GamepadDpadRight,
1434 ImGuiKey_GamepadDpadUp,
1435 ImGuiKey_GamepadDpadDown,
1442 ImGuiKey_GamepadLStickLeft,
1443 ImGuiKey_GamepadLStickRight,
1444 ImGuiKey_GamepadLStickUp,
1445 ImGuiKey_GamepadLStickDown,
1446 ImGuiKey_GamepadRStickLeft,
1447 ImGuiKey_GamepadRStickRight,
1448 ImGuiKey_GamepadRStickUp,
1449 ImGuiKey_GamepadRStickDown,
1453 ImGuiKey_MouseLeft, ImGuiKey_MouseRight, ImGuiKey_MouseMiddle, ImGuiKey_MouseX1, ImGuiKey_MouseX2, ImGuiKey_MouseWheelX, ImGuiKey_MouseWheelY,
1456 ImGuiKey_ReservedForModCtrl, ImGuiKey_ReservedForModShift, ImGuiKey_ReservedForModAlt, ImGuiKey_ReservedForModSuper,
1469 ImGuiMod_Ctrl = 1 << 12,
1470 ImGuiMod_Shift = 1 << 13,
1471 ImGuiMod_Alt = 1 << 14,
1472 ImGuiMod_Super = 1 << 15,
1473 ImGuiMod_Mask_ = 0xF000,
1478 ImGuiKey_NamedKey_BEGIN = 512,
1479 ImGuiKey_NamedKey_END = ImGuiKey_COUNT,
1480 ImGuiKey_NamedKey_COUNT = ImGuiKey_NamedKey_END - ImGuiKey_NamedKey_BEGIN,
1481#ifdef IMGUI_DISABLE_OBSOLETE_KEYIO
1482 ImGuiKey_KeysData_SIZE = ImGuiKey_NamedKey_COUNT,
1483 ImGuiKey_KeysData_OFFSET = ImGuiKey_NamedKey_BEGIN,
1485 ImGuiKey_KeysData_SIZE = ImGuiKey_COUNT,
1486 ImGuiKey_KeysData_OFFSET = 0,
1489#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
1490 ImGuiMod_Shortcut = ImGuiMod_Ctrl,
1491 ImGuiKey_ModCtrl = ImGuiMod_Ctrl, ImGuiKey_ModShift = ImGuiMod_Shift, ImGuiKey_ModAlt = ImGuiMod_Alt, ImGuiKey_ModSuper = ImGuiMod_Super,
1499enum ImGuiInputFlags_
1501 ImGuiInputFlags_None = 0,
1502 ImGuiInputFlags_Repeat = 1 << 0,
1507 ImGuiInputFlags_RouteActive = 1 << 10,
1508 ImGuiInputFlags_RouteFocused = 1 << 11,
1509 ImGuiInputFlags_RouteGlobal = 1 << 12,
1510 ImGuiInputFlags_RouteAlways = 1 << 13,
1512 ImGuiInputFlags_RouteOverFocused = 1 << 14,
1513 ImGuiInputFlags_RouteOverActive = 1 << 15,
1514 ImGuiInputFlags_RouteUnlessBgFocused = 1 << 16,
1515 ImGuiInputFlags_RouteFromRootWindow = 1 << 17,
1518 ImGuiInputFlags_Tooltip = 1 << 18,
1521#ifndef IMGUI_DISABLE_OBSOLETE_KEYIO
1527 ImGuiNavInput_Activate, ImGuiNavInput_Cancel, ImGuiNavInput_Input, ImGuiNavInput_Menu, ImGuiNavInput_DpadLeft, ImGuiNavInput_DpadRight, ImGuiNavInput_DpadUp, ImGuiNavInput_DpadDown,
1528 ImGuiNavInput_LStickLeft, ImGuiNavInput_LStickRight, ImGuiNavInput_LStickUp, ImGuiNavInput_LStickDown, ImGuiNavInput_FocusPrev, ImGuiNavInput_FocusNext, ImGuiNavInput_TweakSlow, ImGuiNavInput_TweakFast,
1529 ImGuiNavInput_COUNT,
1534enum ImGuiConfigFlags_
1536 ImGuiConfigFlags_None = 0,
1537 ImGuiConfigFlags_NavEnableKeyboard = 1 << 0,
1538 ImGuiConfigFlags_NavEnableGamepad = 1 << 1,
1539 ImGuiConfigFlags_NavEnableSetMousePos = 1 << 2,
1540 ImGuiConfigFlags_NavNoCaptureKeyboard = 1 << 3,
1541 ImGuiConfigFlags_NoMouse = 1 << 4,
1542 ImGuiConfigFlags_NoMouseCursorChange = 1 << 5,
1543 ImGuiConfigFlags_NoKeyboard = 1 << 6,
1546 ImGuiConfigFlags_IsSRGB = 1 << 20,
1547 ImGuiConfigFlags_IsTouchScreen = 1 << 21,
1551enum ImGuiBackendFlags_
1553 ImGuiBackendFlags_None = 0,
1554 ImGuiBackendFlags_HasGamepad = 1 << 0,
1555 ImGuiBackendFlags_HasMouseCursors = 1 << 1,
1556 ImGuiBackendFlags_HasSetMousePos = 1 << 2,
1557 ImGuiBackendFlags_RendererHasVtxOffset = 1 << 3,
1564 ImGuiCol_TextDisabled,
1569 ImGuiCol_BorderShadow,
1571 ImGuiCol_FrameBgHovered,
1572 ImGuiCol_FrameBgActive,
1574 ImGuiCol_TitleBgActive,
1575 ImGuiCol_TitleBgCollapsed,
1577 ImGuiCol_ScrollbarBg,
1578 ImGuiCol_ScrollbarGrab,
1579 ImGuiCol_ScrollbarGrabHovered,
1580 ImGuiCol_ScrollbarGrabActive,
1582 ImGuiCol_SliderGrab,
1583 ImGuiCol_SliderGrabActive,
1585 ImGuiCol_ButtonHovered,
1586 ImGuiCol_ButtonActive,
1588 ImGuiCol_HeaderHovered,
1589 ImGuiCol_HeaderActive,
1591 ImGuiCol_SeparatorHovered,
1592 ImGuiCol_SeparatorActive,
1593 ImGuiCol_ResizeGrip,
1594 ImGuiCol_ResizeGripHovered,
1595 ImGuiCol_ResizeGripActive,
1596 ImGuiCol_TabHovered,
1598 ImGuiCol_TabSelected,
1599 ImGuiCol_TabSelectedOverline,
1601 ImGuiCol_TabDimmedSelected,
1602 ImGuiCol_TabDimmedSelectedOverline,
1604 ImGuiCol_PlotLinesHovered,
1605 ImGuiCol_PlotHistogram,
1606 ImGuiCol_PlotHistogramHovered,
1607 ImGuiCol_TableHeaderBg,
1608 ImGuiCol_TableBorderStrong,
1609 ImGuiCol_TableBorderLight,
1610 ImGuiCol_TableRowBg,
1611 ImGuiCol_TableRowBgAlt,
1612 ImGuiCol_TextSelectedBg,
1613 ImGuiCol_DragDropTarget,
1614 ImGuiCol_NavHighlight,
1615 ImGuiCol_NavWindowingHighlight,
1616 ImGuiCol_NavWindowingDimBg,
1617 ImGuiCol_ModalWindowDimBg,
1620#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
1621 ImGuiCol_TabActive = ImGuiCol_TabSelected,
1622 ImGuiCol_TabUnfocused = ImGuiCol_TabDimmed,
1623 ImGuiCol_TabUnfocusedActive = ImGuiCol_TabDimmedSelected,
1638 ImGuiStyleVar_Alpha,
1639 ImGuiStyleVar_DisabledAlpha,
1640 ImGuiStyleVar_WindowPadding,
1641 ImGuiStyleVar_WindowRounding,
1642 ImGuiStyleVar_WindowBorderSize,
1643 ImGuiStyleVar_WindowMinSize,
1644 ImGuiStyleVar_WindowTitleAlign,
1645 ImGuiStyleVar_ChildRounding,
1646 ImGuiStyleVar_ChildBorderSize,
1647 ImGuiStyleVar_PopupRounding,
1648 ImGuiStyleVar_PopupBorderSize,
1649 ImGuiStyleVar_FramePadding,
1650 ImGuiStyleVar_FrameRounding,
1651 ImGuiStyleVar_FrameBorderSize,
1652 ImGuiStyleVar_ItemSpacing,
1653 ImGuiStyleVar_ItemInnerSpacing,
1654 ImGuiStyleVar_IndentSpacing,
1655 ImGuiStyleVar_CellPadding,
1656 ImGuiStyleVar_ScrollbarSize,
1657 ImGuiStyleVar_ScrollbarRounding,
1658 ImGuiStyleVar_GrabMinSize,
1659 ImGuiStyleVar_GrabRounding,
1660 ImGuiStyleVar_TabRounding,
1661 ImGuiStyleVar_TabBorderSize,
1662 ImGuiStyleVar_TabBarBorderSize,
1663 ImGuiStyleVar_TableAngledHeadersAngle,
1664 ImGuiStyleVar_TableAngledHeadersTextAlign,
1665 ImGuiStyleVar_ButtonTextAlign,
1666 ImGuiStyleVar_SelectableTextAlign,
1667 ImGuiStyleVar_SeparatorTextBorderSize,
1668 ImGuiStyleVar_SeparatorTextAlign,
1669 ImGuiStyleVar_SeparatorTextPadding,
1674enum ImGuiButtonFlags_
1676 ImGuiButtonFlags_None = 0,
1677 ImGuiButtonFlags_MouseButtonLeft = 1 << 0,
1678 ImGuiButtonFlags_MouseButtonRight = 1 << 1,
1679 ImGuiButtonFlags_MouseButtonMiddle = 1 << 2,
1680 ImGuiButtonFlags_MouseButtonMask_ = ImGuiButtonFlags_MouseButtonLeft | ImGuiButtonFlags_MouseButtonRight | ImGuiButtonFlags_MouseButtonMiddle,
1685enum ImGuiColorEditFlags_
1687 ImGuiColorEditFlags_None = 0,
1688 ImGuiColorEditFlags_NoAlpha = 1 << 1,
1689 ImGuiColorEditFlags_NoPicker = 1 << 2,
1690 ImGuiColorEditFlags_NoOptions = 1 << 3,
1691 ImGuiColorEditFlags_NoSmallPreview = 1 << 4,
1692 ImGuiColorEditFlags_NoInputs = 1 << 5,
1693 ImGuiColorEditFlags_NoTooltip = 1 << 6,
1694 ImGuiColorEditFlags_NoLabel = 1 << 7,
1695 ImGuiColorEditFlags_NoSidePreview = 1 << 8,
1696 ImGuiColorEditFlags_NoDragDrop = 1 << 9,
1697 ImGuiColorEditFlags_NoBorder = 1 << 10,
1700 ImGuiColorEditFlags_AlphaBar = 1 << 16,
1701 ImGuiColorEditFlags_AlphaPreview = 1 << 17,
1702 ImGuiColorEditFlags_AlphaPreviewHalf= 1 << 18,
1703 ImGuiColorEditFlags_HDR = 1 << 19,
1704 ImGuiColorEditFlags_DisplayRGB = 1 << 20,
1705 ImGuiColorEditFlags_DisplayHSV = 1 << 21,
1706 ImGuiColorEditFlags_DisplayHex = 1 << 22,
1707 ImGuiColorEditFlags_Uint8 = 1 << 23,
1708 ImGuiColorEditFlags_Float = 1 << 24,
1709 ImGuiColorEditFlags_PickerHueBar = 1 << 25,
1710 ImGuiColorEditFlags_PickerHueWheel = 1 << 26,
1711 ImGuiColorEditFlags_InputRGB = 1 << 27,
1712 ImGuiColorEditFlags_InputHSV = 1 << 28,
1716 ImGuiColorEditFlags_DefaultOptions_ = ImGuiColorEditFlags_Uint8 | ImGuiColorEditFlags_DisplayRGB | ImGuiColorEditFlags_InputRGB | ImGuiColorEditFlags_PickerHueBar,
1719 ImGuiColorEditFlags_DisplayMask_ = ImGuiColorEditFlags_DisplayRGB | ImGuiColorEditFlags_DisplayHSV | ImGuiColorEditFlags_DisplayHex,
1720 ImGuiColorEditFlags_DataTypeMask_ = ImGuiColorEditFlags_Uint8 | ImGuiColorEditFlags_Float,
1721 ImGuiColorEditFlags_PickerMask_ = ImGuiColorEditFlags_PickerHueWheel | ImGuiColorEditFlags_PickerHueBar,
1722 ImGuiColorEditFlags_InputMask_ = ImGuiColorEditFlags_InputRGB | ImGuiColorEditFlags_InputHSV,
1731enum ImGuiSliderFlags_
1733 ImGuiSliderFlags_None = 0,
1734 ImGuiSliderFlags_AlwaysClamp = 1 << 4,
1735 ImGuiSliderFlags_Logarithmic = 1 << 5,
1736 ImGuiSliderFlags_NoRoundToFormat = 1 << 6,
1737 ImGuiSliderFlags_NoInput = 1 << 7,
1738 ImGuiSliderFlags_WrapAround = 1 << 8,
1739 ImGuiSliderFlags_InvalidMask_ = 0x7000000F,
1747enum ImGuiMouseButton_
1749 ImGuiMouseButton_Left = 0,
1750 ImGuiMouseButton_Right = 1,
1751 ImGuiMouseButton_Middle = 2,
1752 ImGuiMouseButton_COUNT = 5
1757enum ImGuiMouseCursor_
1759 ImGuiMouseCursor_None = -1,
1760 ImGuiMouseCursor_Arrow = 0,
1761 ImGuiMouseCursor_TextInput,
1762 ImGuiMouseCursor_ResizeAll,
1763 ImGuiMouseCursor_ResizeNS,
1764 ImGuiMouseCursor_ResizeEW,
1765 ImGuiMouseCursor_ResizeNESW,
1766 ImGuiMouseCursor_ResizeNWSE,
1767 ImGuiMouseCursor_Hand,
1768 ImGuiMouseCursor_NotAllowed,
1769 ImGuiMouseCursor_COUNT
1776enum ImGuiMouseSource :
int
1778 ImGuiMouseSource_Mouse = 0,
1779 ImGuiMouseSource_TouchScreen,
1780 ImGuiMouseSource_Pen,
1781 ImGuiMouseSource_COUNT
1790 ImGuiCond_Always = 1 << 0,
1791 ImGuiCond_Once = 1 << 1,
1792 ImGuiCond_FirstUseEver = 1 << 2,
1793 ImGuiCond_Appearing = 1 << 3,
1822enum ImGuiTableFlags_
1825 ImGuiTableFlags_None = 0,
1826 ImGuiTableFlags_Resizable = 1 << 0,
1827 ImGuiTableFlags_Reorderable = 1 << 1,
1828 ImGuiTableFlags_Hideable = 1 << 2,
1829 ImGuiTableFlags_Sortable = 1 << 3,
1830 ImGuiTableFlags_NoSavedSettings = 1 << 4,
1831 ImGuiTableFlags_ContextMenuInBody = 1 << 5,
1833 ImGuiTableFlags_RowBg = 1 << 6,
1834 ImGuiTableFlags_BordersInnerH = 1 << 7,
1835 ImGuiTableFlags_BordersOuterH = 1 << 8,
1836 ImGuiTableFlags_BordersInnerV = 1 << 9,
1837 ImGuiTableFlags_BordersOuterV = 1 << 10,
1838 ImGuiTableFlags_BordersH = ImGuiTableFlags_BordersInnerH | ImGuiTableFlags_BordersOuterH,
1839 ImGuiTableFlags_BordersV = ImGuiTableFlags_BordersInnerV | ImGuiTableFlags_BordersOuterV,
1840 ImGuiTableFlags_BordersInner = ImGuiTableFlags_BordersInnerV | ImGuiTableFlags_BordersInnerH,
1841 ImGuiTableFlags_BordersOuter = ImGuiTableFlags_BordersOuterV | ImGuiTableFlags_BordersOuterH,
1842 ImGuiTableFlags_Borders = ImGuiTableFlags_BordersInner | ImGuiTableFlags_BordersOuter,
1843 ImGuiTableFlags_NoBordersInBody = 1 << 11,
1844 ImGuiTableFlags_NoBordersInBodyUntilResize = 1 << 12,
1846 ImGuiTableFlags_SizingFixedFit = 1 << 13,
1847 ImGuiTableFlags_SizingFixedSame = 2 << 13,
1848 ImGuiTableFlags_SizingStretchProp = 3 << 13,
1849 ImGuiTableFlags_SizingStretchSame = 4 << 13,
1851 ImGuiTableFlags_NoHostExtendX = 1 << 16,
1852 ImGuiTableFlags_NoHostExtendY = 1 << 17,
1853 ImGuiTableFlags_NoKeepColumnsVisible = 1 << 18,
1854 ImGuiTableFlags_PreciseWidths = 1 << 19,
1856 ImGuiTableFlags_NoClip = 1 << 20,
1858 ImGuiTableFlags_PadOuterX = 1 << 21,
1859 ImGuiTableFlags_NoPadOuterX = 1 << 22,
1860 ImGuiTableFlags_NoPadInnerX = 1 << 23,
1862 ImGuiTableFlags_ScrollX = 1 << 24,
1863 ImGuiTableFlags_ScrollY = 1 << 25,
1865 ImGuiTableFlags_SortMulti = 1 << 26,
1866 ImGuiTableFlags_SortTristate = 1 << 27,
1868 ImGuiTableFlags_HighlightHoveredColumn = 1 << 28,
1871 ImGuiTableFlags_SizingMask_ = ImGuiTableFlags_SizingFixedFit | ImGuiTableFlags_SizingFixedSame | ImGuiTableFlags_SizingStretchProp | ImGuiTableFlags_SizingStretchSame,
1875enum ImGuiTableColumnFlags_
1878 ImGuiTableColumnFlags_None = 0,
1879 ImGuiTableColumnFlags_Disabled = 1 << 0,
1880 ImGuiTableColumnFlags_DefaultHide = 1 << 1,
1881 ImGuiTableColumnFlags_DefaultSort = 1 << 2,
1882 ImGuiTableColumnFlags_WidthStretch = 1 << 3,
1883 ImGuiTableColumnFlags_WidthFixed = 1 << 4,
1884 ImGuiTableColumnFlags_NoResize = 1 << 5,
1885 ImGuiTableColumnFlags_NoReorder = 1 << 6,
1886 ImGuiTableColumnFlags_NoHide = 1 << 7,
1887 ImGuiTableColumnFlags_NoClip = 1 << 8,
1888 ImGuiTableColumnFlags_NoSort = 1 << 9,
1889 ImGuiTableColumnFlags_NoSortAscending = 1 << 10,
1890 ImGuiTableColumnFlags_NoSortDescending = 1 << 11,
1891 ImGuiTableColumnFlags_NoHeaderLabel = 1 << 12,
1892 ImGuiTableColumnFlags_NoHeaderWidth = 1 << 13,
1893 ImGuiTableColumnFlags_PreferSortAscending = 1 << 14,
1894 ImGuiTableColumnFlags_PreferSortDescending = 1 << 15,
1895 ImGuiTableColumnFlags_IndentEnable = 1 << 16,
1896 ImGuiTableColumnFlags_IndentDisable = 1 << 17,
1897 ImGuiTableColumnFlags_AngledHeader = 1 << 18,
1900 ImGuiTableColumnFlags_IsEnabled = 1 << 24,
1901 ImGuiTableColumnFlags_IsVisible = 1 << 25,
1902 ImGuiTableColumnFlags_IsSorted = 1 << 26,
1903 ImGuiTableColumnFlags_IsHovered = 1 << 27,
1906 ImGuiTableColumnFlags_WidthMask_ = ImGuiTableColumnFlags_WidthStretch | ImGuiTableColumnFlags_WidthFixed,
1907 ImGuiTableColumnFlags_IndentMask_ = ImGuiTableColumnFlags_IndentEnable | ImGuiTableColumnFlags_IndentDisable,
1908 ImGuiTableColumnFlags_StatusMask_ = ImGuiTableColumnFlags_IsEnabled | ImGuiTableColumnFlags_IsVisible | ImGuiTableColumnFlags_IsSorted | ImGuiTableColumnFlags_IsHovered,
1909 ImGuiTableColumnFlags_NoDirectResize_ = 1 << 30,
1913enum ImGuiTableRowFlags_
1915 ImGuiTableRowFlags_None = 0,
1916 ImGuiTableRowFlags_Headers = 1 << 0,
1928enum ImGuiTableBgTarget_
1930 ImGuiTableBgTarget_None = 0,
1931 ImGuiTableBgTarget_RowBg0 = 1,
1932 ImGuiTableBgTarget_RowBg1 = 2,
1933 ImGuiTableBgTarget_CellBg = 3,
1952 ImGuiID ColumnUserID;
1955 ImGuiSortDirection SortDirection;
1971inline void*
operator new(size_t,
ImNewWrapper,
void* ptr) {
return ptr; }
1972inline void operator delete(
void*,
ImNewWrapper,
void*) {}
1973#define IM_ALLOC(_SIZE) ImGui::MemAlloc(_SIZE)
1974#define IM_FREE(_PTR) ImGui::MemFree(_PTR)
1975#define IM_PLACEMENT_NEW(_PTR) new(ImNewWrapper(), _PTR)
1976#define IM_NEW(_TYPE) new(ImNewWrapper(), ImGui::MemAlloc(sizeof(_TYPE))) _TYPE
1977template<
typename T>
void IM_DELETE(T* p) {
if (p) { p->~T(); ImGui::MemFree(p); } }
1990IM_MSVC_RUNTIME_CHECKS_OFF
1999 typedef T value_type;
2000 typedef value_type* iterator;
2001 typedef const value_type* const_iterator;
2004 inline ImVector() { Size = Capacity = 0; Data = NULL; }
2005 inline ImVector(
const ImVector<T>& src) { Size = Capacity = 0; Data = NULL; operator=(src); }
2006 inline ImVector<T>& operator=(
const ImVector<T>& src) { clear(); resize(src.Size);
if (src.Data) memcpy(Data, src.Data, (
size_t)Size *
sizeof(T));
return *
this; }
2007 inline ~ImVector() {
if (Data) IM_FREE(Data); }
2009 inline void clear() {
if (Data) { Size = Capacity = 0; IM_FREE(Data); Data = NULL; } }
2010 inline void clear_delete() {
for (
int n = 0; n < Size; n++) IM_DELETE(Data[n]); clear(); }
2011 inline void clear_destruct() {
for (
int n = 0; n < Size; n++) Data[n].~T(); clear(); }
2013 inline bool empty()
const {
return Size == 0; }
2014 inline int size()
const {
return Size; }
2015 inline int size_in_bytes()
const {
return Size * (int)
sizeof(T); }
2016 inline int max_size()
const {
return 0x7FFFFFFF / (int)
sizeof(T); }
2017 inline int capacity()
const {
return Capacity; }
2018 inline T& operator[](
int i) { IM_ASSERT(i >= 0 && i < Size);
return Data[i]; }
2019 inline const T& operator[](
int i)
const { IM_ASSERT(i >= 0 && i < Size);
return Data[i]; }
2021 inline T* begin() {
return Data; }
2022 inline const T* begin()
const {
return Data; }
2023 inline T* end() {
return Data + Size; }
2024 inline const T* end()
const {
return Data + Size; }
2025 inline T& front() { IM_ASSERT(Size > 0);
return Data[0]; }
2026 inline const T& front()
const { IM_ASSERT(Size > 0);
return Data[0]; }
2027 inline T& back() { IM_ASSERT(Size > 0);
return Data[Size - 1]; }
2028 inline const T& back()
const { IM_ASSERT(Size > 0);
return Data[Size - 1]; }
2029 inline void swap(
ImVector<T>& rhs) {
int rhs_size = rhs.Size; rhs.Size = Size; Size = rhs_size;
int rhs_cap = rhs.Capacity; rhs.Capacity = Capacity; Capacity = rhs_cap; T* rhs_data = rhs.Data; rhs.Data = Data; Data = rhs_data; }
2031 inline int _grow_capacity(
int sz)
const {
int new_capacity = Capacity ? (Capacity + Capacity / 2) : 8;
return new_capacity > sz ? new_capacity : sz; }
2032 inline void resize(
int new_size) {
if (new_size > Capacity) reserve(_grow_capacity(new_size)); Size = new_size; }
2033 inline void resize(
int new_size,
const T& v) {
if (new_size > Capacity) reserve(_grow_capacity(new_size));
if (new_size > Size)
for (
int n = Size; n < new_size; n++) memcpy(&Data[n], &v,
sizeof(v)); Size = new_size; }
2034 inline void shrink(
int new_size) { IM_ASSERT(new_size <= Size); Size = new_size; }
2035 inline void reserve(
int new_capacity) {
if (new_capacity <= Capacity)
return; T* new_data = (T*)IM_ALLOC((
size_t)new_capacity *
sizeof(T));
if (Data) { memcpy(new_data, Data, (
size_t)Size *
sizeof(T)); IM_FREE(Data); } Data = new_data; Capacity = new_capacity; }
2036 inline void reserve_discard(
int new_capacity) {
if (new_capacity <= Capacity)
return;
if (Data) IM_FREE(Data); Data = (T*)IM_ALLOC((
size_t)new_capacity *
sizeof(T)); Capacity = new_capacity; }
2039 inline void push_back(
const T& v) {
if (Size == Capacity) reserve(_grow_capacity(Size + 1)); memcpy(&Data[Size], &v,
sizeof(v)); Size++; }
2040 inline void pop_back() { IM_ASSERT(Size > 0); Size--; }
2041 inline void push_front(
const T& v) {
if (Size == 0) push_back(v);
else insert(Data, v); }
2042 inline T* erase(
const T* it) { IM_ASSERT(it >= Data && it < Data + Size);
const ptrdiff_t off = it - Data; memmove(Data + off, Data + off + 1, ((
size_t)Size - (
size_t)off - 1) *
sizeof(T)); Size--;
return Data + off; }
2043 inline T* erase(
const T* it,
const T* it_last){ IM_ASSERT(it >= Data && it < Data + Size && it_last >= it && it_last <= Data + Size);
const ptrdiff_t count = it_last - it;
const ptrdiff_t off = it - Data; memmove(Data + off, Data + off + count, ((
size_t)Size - (
size_t)off - (
size_t)count) *
sizeof(T)); Size -= (int)count;
return Data + off; }
2044 inline T* erase_unsorted(
const T* it) { IM_ASSERT(it >= Data && it < Data + Size);
const ptrdiff_t off = it - Data;
if (it < Data + Size - 1) memcpy(Data + off, Data + Size - 1,
sizeof(T)); Size--;
return Data + off; }
2045 inline T* insert(
const T* it,
const T& v) { IM_ASSERT(it >= Data && it <= Data + Size);
const ptrdiff_t off = it - Data;
if (Size == Capacity) reserve(_grow_capacity(Size + 1));
if (off < (
int)Size) memmove(Data + off + 1, Data + off, ((
size_t)Size - (
size_t)off) *
sizeof(T)); memcpy(&Data[off], &v,
sizeof(v)); Size++;
return Data + off; }
2046 inline bool contains(
const T& v)
const {
const T* data = Data;
const T* data_end = Data + Size;
while (data < data_end)
if (*data++ == v)
return true;
return false; }
2047 inline T* find(
const T& v) { T* data = Data;
const T* data_end = Data + Size;
while (data < data_end)
if (*data == v)
break;
else ++data;
return data; }
2048 inline const T* find(
const T& v)
const {
const T* data = Data;
const T* data_end = Data + Size;
while (data < data_end)
if (*data == v)
break;
else ++data;
return data; }
2049 inline int find_index(
const T& v)
const {
const T* data_end = Data + Size;
const T* it = find(v);
if (it == data_end)
return -1;
const ptrdiff_t off = it - Data;
return (
int)off; }
2050 inline bool find_erase(
const T& v) {
const T* it = find(v);
if (it < Data + Size) { erase(it);
return true; }
return false; }
2051 inline bool find_erase_unsorted(
const T& v) {
const T* it = find(v);
if (it < Data + Size) { erase_unsorted(it);
return true; }
return false; }
2052 inline int index_from_ptr(
const T* it)
const { IM_ASSERT(it >= Data && it < Data + Size);
const ptrdiff_t off = it - Data;
return (
int)off; }
2054IM_MSVC_RUNTIME_CHECKS_RESTORE
2067 float DisabledAlpha;
2069 float WindowRounding;
2070 float WindowBorderSize;
2073 ImGuiDir WindowMenuButtonPosition;
2074 float ChildRounding;
2075 float ChildBorderSize;
2076 float PopupRounding;
2077 float PopupBorderSize;
2079 float FrameRounding;
2080 float FrameBorderSize;
2084 ImVec2 TouchExtraPadding;
2085 float IndentSpacing;
2086 float ColumnsMinSpacing;
2087 float ScrollbarSize;
2088 float ScrollbarRounding;
2091 float LogSliderDeadzone;
2093 float TabBorderSize;
2094 float TabMinWidthForCloseButton;
2095 float TabBarBorderSize;
2096 float TableAngledHeadersAngle;
2097 ImVec2 TableAngledHeadersTextAlign;
2098 ImGuiDir ColorButtonPosition;
2100 ImVec2 SelectableTextAlign;
2101 float SeparatorTextBorderSize;
2102 ImVec2 SeparatorTextAlign;
2103 ImVec2 SeparatorTextPadding;
2104 ImVec2 DisplayWindowPadding;
2105 ImVec2 DisplaySafeAreaPadding;
2106 float MouseCursorScale;
2107 bool AntiAliasedLines;
2108 bool AntiAliasedLinesUseTex;
2109 bool AntiAliasedFill;
2110 float CurveTessellationTol;
2111 float CircleTessellationMaxError;
2112 ImVec4 Colors[ImGuiCol_COUNT];
2116 float HoverStationaryDelay;
2117 float HoverDelayShort;
2118 float HoverDelayNormal;
2119 ImGuiHoveredFlags HoverFlagsForTooltipMouse;
2120 ImGuiHoveredFlags HoverFlagsForTooltipNav;
2123 IMGUI_API
void ScaleAllSizes(
float scale_factor);
2142 float DownDurationPrev;
2152 ImGuiConfigFlags ConfigFlags;
2153 ImGuiBackendFlags BackendFlags;
2156 float IniSavingRate;
2157 const char* IniFilename;
2158 const char* LogFilename;
2162 float FontGlobalScale;
2163 bool FontAllowUserScaling;
2165 ImVec2 DisplayFramebufferScale;
2168 bool MouseDrawCursor;
2169 bool ConfigMacOSXBehaviors;
2170 bool ConfigInputTrickleEventQueue;
2171 bool ConfigInputTextCursorBlink;
2172 bool ConfigInputTextEnterKeepActive;
2173 bool ConfigDragClickToInputText;
2174 bool ConfigWindowsResizeFromEdges;
2175 bool ConfigWindowsMoveFromTitleBarOnly;
2176 float ConfigMemoryCompactTimer;
2180 float MouseDoubleClickTime;
2181 float MouseDoubleClickMaxDist;
2182 float MouseDragThreshold;
2183 float KeyRepeatDelay;
2184 float KeyRepeatRate;
2194 bool ConfigDebugIsDebuggerPresent;
2200 bool ConfigDebugBeginReturnValueOnce;
2201 bool ConfigDebugBeginReturnValueLoop;
2206 bool ConfigDebugIgnoreFocusLoss;
2209 bool ConfigDebugIniSettings;
2217 const char* BackendPlatformName;
2218 const char* BackendRendererName;
2219 void* BackendPlatformUserData;
2220 void* BackendRendererUserData;
2221 void* BackendLanguageUserData;
2225 const char* (*GetClipboardTextFn)(
void* user_data);
2226 void (*SetClipboardTextFn)(
void* user_data,
const char* text);
2227 void* ClipboardUserData;
2234 ImWchar PlatformLocaleDecimalPoint;
2241 IMGUI_API
void AddKeyEvent(ImGuiKey key,
bool down);
2242 IMGUI_API
void AddKeyAnalogEvent(ImGuiKey key,
bool down,
float v);
2243 IMGUI_API
void AddMousePosEvent(
float x,
float y);
2244 IMGUI_API
void AddMouseButtonEvent(
int button,
bool down);
2245 IMGUI_API
void AddMouseWheelEvent(
float wheel_x,
float wheel_y);
2246 IMGUI_API
void AddMouseSourceEvent(ImGuiMouseSource source);
2247 IMGUI_API
void AddFocusEvent(
bool focused);
2248 IMGUI_API
void AddInputCharacter(
unsigned int c);
2249 IMGUI_API
void AddInputCharacterUTF16(ImWchar16 c);
2250 IMGUI_API
void AddInputCharactersUTF8(
const char* str);
2252 IMGUI_API
void SetKeyEventNativeData(ImGuiKey key,
int native_keycode,
int native_scancode,
int native_legacy_index = -1);
2253 IMGUI_API
void SetAppAcceptingEvents(
bool accepting_events);
2254 IMGUI_API
void ClearEventsQueue();
2255 IMGUI_API
void ClearInputKeys();
2256 IMGUI_API
void ClearInputMouse();
2257#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
2258 IMGUI_API
void ClearInputCharacters();
2267 bool WantCaptureMouse;
2268 bool WantCaptureKeyboard;
2270 bool WantSetMousePos;
2271 bool WantSaveIniSettings;
2275 int MetricsRenderVertices;
2276 int MetricsRenderIndices;
2277 int MetricsRenderWindows;
2278 int MetricsActiveWindows;
2294 ImGuiMouseSource MouseSource;
2301 ImGuiKeyChord KeyMods;
2303 bool WantCaptureMouseUnlessPopupClose;
2305 ImVec2 MouseClickedPos[5];
2306 double MouseClickedTime[5];
2307 bool MouseClicked[5];
2308 bool MouseDoubleClicked[5];
2309 ImU16 MouseClickedCount[5];
2310 ImU16 MouseClickedLastCount[5];
2311 bool MouseReleased[5];
2312 bool MouseDownOwned[5];
2313 bool MouseDownOwnedUnlessPopupClose[5];
2314 bool MouseWheelRequestAxisSwap;
2315 bool MouseCtrlLeftAsRightClick;
2316 float MouseDownDuration[5];
2317 float MouseDownDurationPrev[5];
2318 float MouseDragMaxDistanceSqr[5];
2321 bool AppAcceptingEvents;
2322 ImS8 BackendUsingLegacyKeyArrays;
2323 bool BackendUsingLegacyNavInputArray;
2324 ImWchar16 InputQueueSurrogate;
2330#ifndef IMGUI_DISABLE_OBSOLETE_KEYIO
2331 int KeyMap[ImGuiKey_COUNT];
2332 bool KeysDown[ImGuiKey_COUNT];
2333 float NavInputs[ImGuiNavInput_COUNT];
2356 ImGuiInputTextFlags EventFlag;
2357 ImGuiInputTextFlags Flags;
2378 IMGUI_API
void DeleteChars(
int pos,
int bytes_count);
2379 IMGUI_API
void InsertChars(
int pos,
const char* text,
const char* text_end = NULL);
2380 void SelectAll() { SelectionStart = 0; SelectionEnd = BufTextLen; }
2381 void ClearSelection() { SelectionStart = SelectionEnd = BufTextLen; }
2382 bool HasSelection()
const {
return SelectionStart != SelectionEnd; }
2404 ImGuiID SourceParentId;
2406 char DataType[32 + 1];
2411 void Clear() { SourceId = SourceParentId = 0; Data = NULL; DataSize = 0; memset(DataType, 0,
sizeof(DataType)); DataFrameCount = -1; Preview = Delivery =
false; }
2412 bool IsDataType(
const char* type)
const {
return DataFrameCount != -1 && strcmp(type, DataType) == 0; }
2413 bool IsPreview()
const {
return Preview; }
2414 bool IsDelivery()
const {
return Delivery; }
2422#define IM_UNICODE_CODEPOINT_INVALID 0xFFFD
2423#ifdef IMGUI_USE_WCHAR32
2424#define IM_UNICODE_CODEPOINT_MAX 0x10FFFF
2426#define IM_UNICODE_CODEPOINT_MAX 0xFFFF
2434 mutable int RefFrame;
2435 operator bool()
const {
int current_frame = ImGui::GetFrameCount();
if (RefFrame == current_frame)
return false; RefFrame = current_frame;
return true; }
2442 IMGUI_API
bool Draw(
const char* label =
"Filter (inc,-exc)",
float width = 0.0f);
2443 IMGUI_API
bool PassFilter(
const char* text,
const char* text_end = NULL)
const;
2444 IMGUI_API
void Build();
2445 void Clear() { InputBuf[0] = 0; Build(); }
2446 bool IsActive()
const {
return !Filters.empty(); }
2455 ImGuiTextRange(
const char* _b,
const char* _e) { b = _b; e = _e; }
2456 bool empty()
const {
return b == e; }
2469 IMGUI_API
static char EmptyString[1];
2472 inline char operator[](
int i)
const { IM_ASSERT(Buf.Data != NULL);
return Buf.Data[i]; }
2473 const char* begin()
const {
return Buf.Data ? &Buf.front() : EmptyString; }
2474 const char* end()
const {
return Buf.Data ? &Buf.back() : EmptyString; }
2475 int size()
const {
return Buf.Size ? Buf.Size - 1 : 0; }
2476 bool empty()
const {
return Buf.Size <= 1; }
2477 void clear() { Buf.clear(); }
2478 void reserve(
int capacity) { Buf.reserve(capacity); }
2479 const char* c_str()
const {
return Buf.Data ? Buf.Data : EmptyString; }
2480 IMGUI_API
void append(
const char* str,
const char* str_end = NULL);
2481 IMGUI_API
void appendf(
const char* fmt, ...) IM_FMTARGS(2);
2482 IMGUI_API
void appendfv(
const char* fmt, va_list args) IM_FMTLIST(2);
2489 union {
int val_i;
float val_f;
void* val_p; };
2511 void Clear() { Data.clear(); }
2512 IMGUI_API
int GetInt(ImGuiID key,
int default_val = 0)
const;
2513 IMGUI_API
void SetInt(ImGuiID key,
int val);
2514 IMGUI_API
bool GetBool(ImGuiID key,
bool default_val =
false)
const;
2515 IMGUI_API
void SetBool(ImGuiID key,
bool val);
2516 IMGUI_API
float GetFloat(ImGuiID key,
float default_val = 0.0f)
const;
2517 IMGUI_API
void SetFloat(ImGuiID key,
float val);
2518 IMGUI_API
void* GetVoidPtr(ImGuiID key)
const;
2519 IMGUI_API
void SetVoidPtr(ImGuiID key,
void* val);
2525 IMGUI_API
int* GetIntRef(ImGuiID key,
int default_val = 0);
2526 IMGUI_API
bool* GetBoolRef(ImGuiID key,
bool default_val =
false);
2527 IMGUI_API
float* GetFloatRef(ImGuiID key,
float default_val = 0.0f);
2528 IMGUI_API
void** GetVoidPtrRef(ImGuiID key,
void* default_val = NULL);
2531 IMGUI_API
void BuildSortByKey();
2533 IMGUI_API
void SetAllInt(
int val);
2535#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
2574 IMGUI_API
void Begin(
int items_count,
float items_height = -1.0f);
2575 IMGUI_API
void End();
2576 IMGUI_API
bool Step();
2580 inline void IncludeItemByIndex(
int item_index) { IncludeItemsByIndex(item_index, item_index + 1); }
2581 IMGUI_API
void IncludeItemsByIndex(
int item_begin,
int item_end);
2583#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
2584 inline void IncludeRangeByIndices(
int item_begin,
int item_end) { IncludeItemsByIndex(item_begin, item_end); }
2585 inline void ForceDisplayRangeByIndices(
int item_begin,
int item_end) { IncludeItemsByIndex(item_begin, item_end); }
2594#ifdef IMGUI_DEFINE_MATH_OPERATORS
2595#define IMGUI_DEFINE_MATH_OPERATORS_IMPLEMENTED
2596IM_MSVC_RUNTIME_CHECKS_OFF
2597static inline ImVec2 operator*(
const ImVec2& lhs,
const float rhs) {
return ImVec2(lhs.x * rhs, lhs.y * rhs); }
2598static inline ImVec2 operator/(
const ImVec2& lhs,
const float rhs) {
return ImVec2(lhs.x / rhs, lhs.y / rhs); }
2599static inline ImVec2 operator+(
const ImVec2& lhs,
const ImVec2& rhs) {
return ImVec2(lhs.x + rhs.x, lhs.y + rhs.y); }
2600static inline ImVec2 operator-(
const ImVec2& lhs,
const ImVec2& rhs) {
return ImVec2(lhs.x - rhs.x, lhs.y - rhs.y); }
2601static inline ImVec2 operator*(
const ImVec2& lhs,
const ImVec2& rhs) {
return ImVec2(lhs.x * rhs.x, lhs.y * rhs.y); }
2602static inline ImVec2 operator/(
const ImVec2& lhs,
const ImVec2& rhs) {
return ImVec2(lhs.x / rhs.x, lhs.y / rhs.y); }
2604static inline ImVec2& operator*=(
ImVec2& lhs,
const float rhs) { lhs.x *= rhs; lhs.y *= rhs;
return lhs; }
2605static inline ImVec2& operator/=(
ImVec2& lhs,
const float rhs) { lhs.x /= rhs; lhs.y /= rhs;
return lhs; }
2606static inline ImVec2& operator+=(
ImVec2& lhs,
const ImVec2& rhs) { lhs.x += rhs.x; lhs.y += rhs.y;
return lhs; }
2607static inline ImVec2& operator-=(
ImVec2& lhs,
const ImVec2& rhs) { lhs.x -= rhs.x; lhs.y -= rhs.y;
return lhs; }
2608static inline ImVec2& operator*=(
ImVec2& lhs,
const ImVec2& rhs) { lhs.x *= rhs.x; lhs.y *= rhs.y;
return lhs; }
2609static inline ImVec2& operator/=(
ImVec2& lhs,
const ImVec2& rhs) { lhs.x /= rhs.x; lhs.y /= rhs.y;
return lhs; }
2610static inline bool operator==(
const ImVec2& lhs,
const ImVec2& rhs) {
return lhs.x == rhs.x && lhs.y == rhs.y; }
2611static inline bool operator!=(
const ImVec2& lhs,
const ImVec2& rhs) {
return lhs.x != rhs.x || lhs.y != rhs.y; }
2612static inline ImVec4 operator+(
const ImVec4& lhs,
const ImVec4& rhs) {
return ImVec4(lhs.x + rhs.x, lhs.y + rhs.y, lhs.z + rhs.z, lhs.w + rhs.w); }
2613static inline ImVec4 operator-(
const ImVec4& lhs,
const ImVec4& rhs) {
return ImVec4(lhs.x - rhs.x, lhs.y - rhs.y, lhs.z - rhs.z, lhs.w - rhs.w); }
2614static inline ImVec4 operator*(
const ImVec4& lhs,
const ImVec4& rhs) {
return ImVec4(lhs.x * rhs.x, lhs.y * rhs.y, lhs.z * rhs.z, lhs.w * rhs.w); }
2615static inline bool operator==(
const ImVec4& lhs,
const ImVec4& rhs) {
return lhs.x == rhs.x && lhs.y == rhs.y && lhs.z == rhs.z && lhs.w == rhs.w; }
2616static inline bool operator!=(
const ImVec4& lhs,
const ImVec4& rhs) {
return lhs.x != rhs.x || lhs.y != rhs.y || lhs.z != rhs.z || lhs.w != rhs.w; }
2617IM_MSVC_RUNTIME_CHECKS_RESTORE
2622#ifndef IM_COL32_R_SHIFT
2623#ifdef IMGUI_USE_BGRA_PACKED_COLOR
2624#define IM_COL32_R_SHIFT 16
2625#define IM_COL32_G_SHIFT 8
2626#define IM_COL32_B_SHIFT 0
2627#define IM_COL32_A_SHIFT 24
2628#define IM_COL32_A_MASK 0xFF000000
2630#define IM_COL32_R_SHIFT 0
2631#define IM_COL32_G_SHIFT 8
2632#define IM_COL32_B_SHIFT 16
2633#define IM_COL32_A_SHIFT 24
2634#define IM_COL32_A_MASK 0xFF000000
2637#define IM_COL32(R,G,B,A) (((ImU32)(A)<<IM_COL32_A_SHIFT) | ((ImU32)(B)<<IM_COL32_B_SHIFT) | ((ImU32)(G)<<IM_COL32_G_SHIFT) | ((ImU32)(R)<<IM_COL32_R_SHIFT))
2638#define IM_COL32_WHITE IM_COL32(255,255,255,255)
2639#define IM_COL32_BLACK IM_COL32(0,0,0,255)
2640#define IM_COL32_BLACK_TRANS IM_COL32(0,0,0,0)
2651 constexpr ImColor(
float r,
float g,
float b,
float a = 1.0f) : Value(r, g, b, a) { }
2653 constexpr ImColor(
int r,
int g,
int b,
int a = 255) : Value((
float)r * (1.0f / 255.0f), (
float)g * (1.0f / 255.0f), (
float)b * (1.0f / 255.0f), (
float)a* (1.0f / 255.0f)) {}
2654 constexpr ImColor(ImU32 rgba) : Value((
float)((rgba >> IM_COL32_R_SHIFT) & 0xFF) * (1.0f / 255.0f), (
float)((rgba >> IM_COL32_G_SHIFT) & 0xFF) * (1.0f / 255.0f), (
float)((rgba >> IM_COL32_B_SHIFT) & 0xFF) * (1.0f / 255.0f), (
float)((rgba >> IM_COL32_A_SHIFT) & 0xFF) * (1.0f / 255.0f)) {}
2655 inline operator ImU32()
const {
return ImGui::ColorConvertFloat4ToU32(Value); }
2656 inline operator ImVec4()
const {
return Value; }
2659 inline void SetHSV(
float h,
float s,
float v,
float a = 1.0f){ ImGui::ColorConvertHSVtoRGB(h, s, v, Value.x, Value.y, Value.z); Value.w = a; }
2660 static ImColor HSV(
float h,
float s,
float v,
float a = 1.0f) {
float r, g, b; ImGui::ColorConvertHSVtoRGB(h, s, v, r, g, b);
return ImColor(r, g, b, a); }
2669#ifndef IM_DRAWLIST_TEX_LINES_WIDTH_MAX
2670#define IM_DRAWLIST_TEX_LINES_WIDTH_MAX (63)
2680#ifndef ImDrawCallback
2688#define ImDrawCallback_ResetRenderState (ImDrawCallback)(-8)
2698 ImTextureID TextureId;
2699 unsigned int VtxOffset;
2700 unsigned int IdxOffset;
2701 unsigned int ElemCount;
2702 ImDrawCallback UserCallback;
2703 void* UserCallbackData;
2705 ImDrawCmd() { memset(
this, 0,
sizeof(*
this)); }
2708 inline ImTextureID GetTexID()
const {
return TextureId; }
2712#ifndef IMGUI_OVERRIDE_DRAWVERT_STRUCT_LAYOUT
2724IMGUI_OVERRIDE_DRAWVERT_STRUCT_LAYOUT;
2731 ImTextureID TextureId;
2732 unsigned int VtxOffset;
2753 inline void Clear() { _Current = 0; _Count = 1; }
2754 IMGUI_API
void ClearFreeMemory();
2755 IMGUI_API
void Split(
ImDrawList* draw_list,
int count);
2757 IMGUI_API
void SetCurrentChannel(
ImDrawList* draw_list,
int channel_idx);
2764 ImDrawFlags_None = 0,
2765 ImDrawFlags_Closed = 1 << 0,
2766 ImDrawFlags_RoundCornersTopLeft = 1 << 4,
2767 ImDrawFlags_RoundCornersTopRight = 1 << 5,
2768 ImDrawFlags_RoundCornersBottomLeft = 1 << 6,
2769 ImDrawFlags_RoundCornersBottomRight = 1 << 7,
2770 ImDrawFlags_RoundCornersNone = 1 << 8,
2771 ImDrawFlags_RoundCornersTop = ImDrawFlags_RoundCornersTopLeft | ImDrawFlags_RoundCornersTopRight,
2772 ImDrawFlags_RoundCornersBottom = ImDrawFlags_RoundCornersBottomLeft | ImDrawFlags_RoundCornersBottomRight,
2773 ImDrawFlags_RoundCornersLeft = ImDrawFlags_RoundCornersBottomLeft | ImDrawFlags_RoundCornersTopLeft,
2774 ImDrawFlags_RoundCornersRight = ImDrawFlags_RoundCornersBottomRight | ImDrawFlags_RoundCornersTopRight,
2775 ImDrawFlags_RoundCornersAll = ImDrawFlags_RoundCornersTopLeft | ImDrawFlags_RoundCornersTopRight | ImDrawFlags_RoundCornersBottomLeft | ImDrawFlags_RoundCornersBottomRight,
2776 ImDrawFlags_RoundCornersDefault_ = ImDrawFlags_RoundCornersAll,
2777 ImDrawFlags_RoundCornersMask_ = ImDrawFlags_RoundCornersAll | ImDrawFlags_RoundCornersNone,
2782enum ImDrawListFlags_
2784 ImDrawListFlags_None = 0,
2785 ImDrawListFlags_AntiAliasedLines = 1 << 0,
2786 ImDrawListFlags_AntiAliasedLinesUseTex = 1 << 1,
2787 ImDrawListFlags_AntiAliasedFill = 1 << 2,
2788 ImDrawListFlags_AllowVtxOffset = 1 << 3,
2806 ImDrawListFlags Flags;
2809 unsigned int _VtxCurrentIdx;
2812 ImDrawIdx* _IdxWritePtr;
2819 const char* _OwnerName;
2825 IMGUI_API
void PushClipRect(
const ImVec2& clip_rect_min,
const ImVec2& clip_rect_max,
bool intersect_with_current_clip_rect =
false);
2826 IMGUI_API
void PushClipRectFullScreen();
2827 IMGUI_API
void PopClipRect();
2828 IMGUI_API
void PushTextureID(ImTextureID texture_id);
2829 IMGUI_API
void PopTextureID();
2830 inline ImVec2 GetClipRectMin()
const {
const ImVec4& cr = _ClipRectStack.back();
return ImVec2(cr.x, cr.y); }
2831 inline ImVec2 GetClipRectMax()
const {
const ImVec4& cr = _ClipRectStack.back();
return ImVec2(cr.z, cr.w); }
2840 IMGUI_API
void AddLine(
const ImVec2& p1,
const ImVec2& p2, ImU32 col,
float thickness = 1.0f);
2841 IMGUI_API
void AddRect(
const ImVec2& p_min,
const ImVec2& p_max, ImU32 col,
float rounding = 0.0f, ImDrawFlags flags = 0,
float thickness = 1.0f);
2842 IMGUI_API
void AddRectFilled(
const ImVec2& p_min,
const ImVec2& p_max, ImU32 col,
float rounding = 0.0f, ImDrawFlags flags = 0);
2843 IMGUI_API
void AddRectFilledMultiColor(
const ImVec2& p_min,
const ImVec2& p_max, ImU32 col_upr_left, ImU32 col_upr_right, ImU32 col_bot_right, ImU32 col_bot_left);
2844 IMGUI_API
void AddQuad(
const ImVec2& p1,
const ImVec2& p2,
const ImVec2& p3,
const ImVec2& p4, ImU32 col,
float thickness = 1.0f);
2846 IMGUI_API
void AddTriangle(
const ImVec2& p1,
const ImVec2& p2,
const ImVec2& p3, ImU32 col,
float thickness = 1.0f);
2847 IMGUI_API
void AddTriangleFilled(
const ImVec2& p1,
const ImVec2& p2,
const ImVec2& p3, ImU32 col);
2848 IMGUI_API
void AddCircle(
const ImVec2& center,
float radius, ImU32 col,
int num_segments = 0,
float thickness = 1.0f);
2849 IMGUI_API
void AddCircleFilled(
const ImVec2& center,
float radius, ImU32 col,
int num_segments = 0);
2850 IMGUI_API
void AddNgon(
const ImVec2& center,
float radius, ImU32 col,
int num_segments,
float thickness = 1.0f);
2851 IMGUI_API
void AddNgonFilled(
const ImVec2& center,
float radius, ImU32 col,
int num_segments);
2852 IMGUI_API
void AddEllipse(
const ImVec2& center,
const ImVec2& radius, ImU32 col,
float rot = 0.0f,
int num_segments = 0,
float thickness = 1.0f);
2853 IMGUI_API
void AddEllipseFilled(
const ImVec2& center,
const ImVec2& radius, ImU32 col,
float rot = 0.0f,
int num_segments = 0);
2854 IMGUI_API
void AddText(
const ImVec2& pos, ImU32 col,
const char* text_begin,
const char* text_end = NULL);
2855 IMGUI_API
void AddText(
const ImFont* font,
float font_size,
const ImVec2& pos, ImU32 col,
const char* text_begin,
const char* text_end = NULL,
float wrap_width = 0.0f,
const ImVec4* cpu_fine_clip_rect = NULL);
2856 IMGUI_API
void AddBezierCubic(
const ImVec2& p1,
const ImVec2& p2,
const ImVec2& p3,
const ImVec2& p4, ImU32 col,
float thickness,
int num_segments = 0);
2857 IMGUI_API
void AddBezierQuadratic(
const ImVec2& p1,
const ImVec2& p2,
const ImVec2& p3, ImU32 col,
float thickness,
int num_segments = 0);
2862 IMGUI_API
void AddPolyline(
const ImVec2* points,
int num_points, ImU32 col, ImDrawFlags flags,
float thickness);
2863 IMGUI_API
void AddConvexPolyFilled(
const ImVec2* points,
int num_points, ImU32 col);
2864 IMGUI_API
void AddConcavePolyFilled(
const ImVec2* points,
int num_points, ImU32 col);
2870 IMGUI_API
void AddImage(ImTextureID user_texture_id,
const ImVec2& p_min,
const ImVec2& p_max,
const ImVec2& uv_min =
ImVec2(0, 0),
const ImVec2& uv_max =
ImVec2(1, 1), ImU32 col = IM_COL32_WHITE);
2871 IMGUI_API
void AddImageQuad(ImTextureID user_texture_id,
const ImVec2& p1,
const ImVec2& p2,
const ImVec2& p3,
const ImVec2& p4,
const ImVec2& uv1 =
ImVec2(0, 0),
const ImVec2& uv2 =
ImVec2(1, 0),
const ImVec2& uv3 =
ImVec2(1, 1),
const ImVec2& uv4 =
ImVec2(0, 1), ImU32 col = IM_COL32_WHITE);
2872 IMGUI_API
void AddImageRounded(ImTextureID user_texture_id,
const ImVec2& p_min,
const ImVec2& p_max,
const ImVec2& uv_min,
const ImVec2& uv_max, ImU32 col,
float rounding, ImDrawFlags flags = 0);
2877 inline void PathClear() { _Path.Size = 0; }
2878 inline void PathLineTo(
const ImVec2& pos) { _Path.push_back(pos); }
2879 inline void PathLineToMergeDuplicate(
const ImVec2& pos) {
if (_Path.Size == 0 || memcmp(&_Path.Data[_Path.Size - 1], &pos, 8) != 0) _Path.push_back(pos); }
2880 inline void PathFillConvex(ImU32 col) { AddConvexPolyFilled(_Path.Data, _Path.Size, col); _Path.Size = 0; }
2881 inline void PathFillConcave(ImU32 col) { AddConcavePolyFilled(_Path.Data, _Path.Size, col); _Path.Size = 0; }
2882 inline void PathStroke(ImU32 col, ImDrawFlags flags = 0,
float thickness = 1.0f) { AddPolyline(_Path.Data, _Path.Size, col, flags, thickness); _Path.Size = 0; }
2883 IMGUI_API
void PathArcTo(
const ImVec2& center,
float radius,
float a_min,
float a_max,
int num_segments = 0);
2884 IMGUI_API
void PathArcToFast(
const ImVec2& center,
float radius,
int a_min_of_12,
int a_max_of_12);
2885 IMGUI_API
void PathEllipticalArcTo(
const ImVec2& center,
const ImVec2& radius,
float rot,
float a_min,
float a_max,
int num_segments = 0);
2886 IMGUI_API
void PathBezierCubicCurveTo(
const ImVec2& p2,
const ImVec2& p3,
const ImVec2& p4,
int num_segments = 0);
2887 IMGUI_API
void PathBezierQuadraticCurveTo(
const ImVec2& p2,
const ImVec2& p3,
int num_segments = 0);
2888 IMGUI_API
void PathRect(
const ImVec2& rect_min,
const ImVec2& rect_max,
float rounding = 0.0f, ImDrawFlags flags = 0);
2891 IMGUI_API
void AddCallback(ImDrawCallback callback,
void* callback_data);
2892 IMGUI_API
void AddDrawCmd();
2901 inline void ChannelsSplit(
int count) { _Splitter.Split(
this, count); }
2902 inline void ChannelsMerge() { _Splitter.Merge(
this); }
2903 inline void ChannelsSetCurrent(
int n) { _Splitter.SetCurrentChannel(
this, n); }
2908 IMGUI_API
void PrimReserve(
int idx_count,
int vtx_count);
2909 IMGUI_API
void PrimUnreserve(
int idx_count,
int vtx_count);
2910 IMGUI_API
void PrimRect(
const ImVec2& a,
const ImVec2& b, ImU32 col);
2913 inline void PrimWriteVtx(
const ImVec2& pos,
const ImVec2& uv, ImU32 col) { _VtxWritePtr->pos = pos; _VtxWritePtr->uv = uv; _VtxWritePtr->col = col; _VtxWritePtr++; _VtxCurrentIdx++; }
2914 inline void PrimWriteIdx(ImDrawIdx idx) { *_IdxWritePtr = idx; _IdxWritePtr++; }
2915 inline void PrimVtx(
const ImVec2& pos,
const ImVec2& uv, ImU32 col) { PrimWriteIdx((ImDrawIdx)_VtxCurrentIdx); PrimWriteVtx(pos, uv, col); }
2925 IMGUI_API
void _ResetForNewFrame();
2926 IMGUI_API
void _ClearFreeMemory();
2927 IMGUI_API
void _PopUnusedDrawCmd();
2928 IMGUI_API
void _TryMergeDrawCmds();
2929 IMGUI_API
void _OnChangedClipRect();
2930 IMGUI_API
void _OnChangedTextureID();
2931 IMGUI_API
void _OnChangedVtxOffset();
2932 IMGUI_API
int _CalcCircleAutoSegmentCount(
float radius)
const;
2933 IMGUI_API
void _PathArcToFastEx(
const ImVec2& center,
float radius,
int a_min_sample,
int a_max_sample,
int a_step);
2934 IMGUI_API
void _PathArcToN(
const ImVec2& center,
float radius,
float a_min,
float a_max,
int num_segments);
2954 IMGUI_API
void Clear();
2955 IMGUI_API
void AddDrawList(
ImDrawList* draw_list);
2956 IMGUI_API
void DeIndexAllBuffers();
2957 IMGUI_API
void ScaleClipRects(
const ImVec2& fb_scale);
2968 bool FontDataOwnedByAtlas;
2974 ImVec2 GlyphExtraSpacing;
2976 const ImWchar* GlyphRanges;
2977 float GlyphMinAdvanceX;
2978 float GlyphMaxAdvanceX;
2980 unsigned int FontBuilderFlags;
2981 float RasterizerMultiply;
2982 float RasterizerDensity;
2983 ImWchar EllipsisChar;
2996 unsigned int Colored : 1;
2997 unsigned int Visible : 1;
2998 unsigned int Codepoint : 30;
3000 float X0, Y0, X1, Y1;
3001 float U0, V0, U1, V1;
3011 inline void Clear() {
int size_in_bytes = (IM_UNICODE_CODEPOINT_MAX + 1) / 8; UsedChars.resize(size_in_bytes / (
int)
sizeof(ImU32)); memset(UsedChars.Data, 0, (
size_t)size_in_bytes); }
3012 inline bool GetBit(
size_t n)
const {
int off = (int)(n >> 5); ImU32 mask = 1u << (n & 31);
return (UsedChars[off] & mask) != 0; }
3013 inline void SetBit(
size_t n) {
int off = (int)(n >> 5); ImU32 mask = 1u << (n & 31); UsedChars[off] |= mask; }
3014 inline void AddChar(ImWchar c) { SetBit(c); }
3015 IMGUI_API
void AddText(
const char* text,
const char* text_end = NULL);
3016 IMGUI_API
void AddRanges(
const ImWchar* ranges);
3023 unsigned short Width, Height;
3024 unsigned short X, Y;
3025 unsigned int GlyphID;
3026 float GlyphAdvanceX;
3029 ImFontAtlasCustomRect() { Width = Height = 0; X = Y = 0xFFFF; GlyphID = 0; GlyphAdvanceX = 0.0f; GlyphOffset =
ImVec2(0, 0); Font = NULL; }
3030 bool IsPacked()
const {
return X != 0xFFFF; }
3034enum ImFontAtlasFlags_
3036 ImFontAtlasFlags_None = 0,
3037 ImFontAtlasFlags_NoPowerOfTwoHeight = 1 << 0,
3038 ImFontAtlasFlags_NoMouseCursors = 1 << 1,
3039 ImFontAtlasFlags_NoBakedLines = 1 << 2,
3065 IMGUI_API
ImFont* AddFontFromFileTTF(
const char* filename,
float size_pixels,
const ImFontConfig* font_cfg = NULL,
const ImWchar* glyph_ranges = NULL);
3066 IMGUI_API
ImFont* AddFontFromMemoryTTF(
void* font_data,
int font_data_size,
float size_pixels,
const ImFontConfig* font_cfg = NULL,
const ImWchar* glyph_ranges = NULL);
3067 IMGUI_API
ImFont* AddFontFromMemoryCompressedTTF(
const void* compressed_font_data,
int compressed_font_data_size,
float size_pixels,
const ImFontConfig* font_cfg = NULL,
const ImWchar* glyph_ranges = NULL);
3068 IMGUI_API
ImFont* AddFontFromMemoryCompressedBase85TTF(
const char* compressed_font_data_base85,
float size_pixels,
const ImFontConfig* font_cfg = NULL,
const ImWchar* glyph_ranges = NULL);
3069 IMGUI_API
void ClearInputData();
3070 IMGUI_API
void ClearTexData();
3071 IMGUI_API
void ClearFonts();
3072 IMGUI_API
void Clear();
3079 IMGUI_API
bool Build();
3080 IMGUI_API
void GetTexDataAsAlpha8(
unsigned char** out_pixels,
int* out_width,
int* out_height,
int* out_bytes_per_pixel = NULL);
3081 IMGUI_API
void GetTexDataAsRGBA32(
unsigned char** out_pixels,
int* out_width,
int* out_height,
int* out_bytes_per_pixel = NULL);
3082 bool IsBuilt()
const {
return Fonts.Size > 0 && TexReady; }
3083 void SetTexID(ImTextureID
id) { TexID = id; }
3093 IMGUI_API
const ImWchar* GetGlyphRangesDefault();
3094 IMGUI_API
const ImWchar* GetGlyphRangesGreek();
3095 IMGUI_API
const ImWchar* GetGlyphRangesKorean();
3096 IMGUI_API
const ImWchar* GetGlyphRangesJapanese();
3097 IMGUI_API
const ImWchar* GetGlyphRangesChineseFull();
3098 IMGUI_API
const ImWchar* GetGlyphRangesChineseSimplifiedCommon();
3099 IMGUI_API
const ImWchar* GetGlyphRangesCyrillic();
3100 IMGUI_API
const ImWchar* GetGlyphRangesThai();
3101 IMGUI_API
const ImWchar* GetGlyphRangesVietnamese();
3114 IMGUI_API
int AddCustomRectRegular(
int width,
int height);
3115 IMGUI_API
int AddCustomRectFontGlyph(
ImFont* font, ImWchar
id,
int width,
int height,
float advance_x,
const ImVec2& offset =
ImVec2(0, 0));
3116 ImFontAtlasCustomRect* GetCustomRectByIndex(
int index) { IM_ASSERT(index >= 0);
return &CustomRects[index]; }
3120 IMGUI_API
bool GetMouseCursorTexData(ImGuiMouseCursor cursor,
ImVec2* out_offset,
ImVec2* out_size,
ImVec2 out_uv_border[2],
ImVec2 out_uv_fill[2]);
3126 ImFontAtlasFlags Flags;
3128 int TexDesiredWidth;
3129 int TexGlyphPadding;
3136 bool TexPixelsUseColors;
3137 unsigned char* TexPixelsAlpha8;
3138 unsigned int* TexPixelsRGBA32;
3146 ImVec4 TexUvLines[IM_DRAWLIST_TEX_LINES_WIDTH_MAX + 1];
3150 unsigned int FontBuilderFlags;
3153 int PackIdMouseCursors;
3167 float FallbackAdvanceX;
3178 short ConfigDataCount;
3179 ImWchar FallbackChar;
3180 ImWchar EllipsisChar;
3181 short EllipsisCharCount;
3182 float EllipsisWidth;
3183 float EllipsisCharStep;
3184 bool DirtyLookupTables;
3186 float Ascent, Descent;
3187 int MetricsTotalSurface;
3188 ImU8 Used4kPagesMap[(IM_UNICODE_CODEPOINT_MAX+1)/4096/8];
3193 IMGUI_API
const ImFontGlyph*FindGlyph(ImWchar c)
const;
3194 IMGUI_API
const ImFontGlyph*FindGlyphNoFallback(ImWchar c)
const;
3195 float GetCharAdvance(ImWchar c)
const {
return ((
int)c < IndexAdvanceX.Size) ? IndexAdvanceX[(int)c] : FallbackAdvanceX; }
3196 bool IsLoaded()
const {
return ContainerAtlas != NULL; }
3197 const char* GetDebugName()
const {
return ConfigData ? ConfigData->Name :
"<unknown>"; }
3201 IMGUI_API
ImVec2 CalcTextSizeA(
float size,
float max_width,
float wrap_width,
const char* text_begin,
const char* text_end = NULL,
const char** remaining = NULL)
const;
3202 IMGUI_API
const char* CalcWordWrapPositionA(
float scale,
const char* text,
const char* text_end,
float wrap_width)
const;
3203 IMGUI_API
void RenderChar(
ImDrawList* draw_list,
float size,
const ImVec2& pos, ImU32 col, ImWchar c)
const;
3204 IMGUI_API
void RenderText(
ImDrawList* draw_list,
float size,
const ImVec2& pos, ImU32 col,
const ImVec4& clip_rect,
const char* text_begin,
const char* text_end,
float wrap_width = 0.0f,
bool cpu_fine_clip =
false)
const;
3207 IMGUI_API
void BuildLookupTable();
3208 IMGUI_API
void ClearOutputData();
3209 IMGUI_API
void GrowIndex(
int new_size);
3210 IMGUI_API
void AddGlyph(
const ImFontConfig* src_cfg, ImWchar c,
float x0,
float y0,
float x1,
float y1,
float u0,
float v0,
float u1,
float v1,
float advance_x);
3211 IMGUI_API
void AddRemapChar(ImWchar dst, ImWchar src,
bool overwrite_dst =
true);
3212 IMGUI_API
void SetGlyphVisible(ImWchar c,
bool visible);
3213 IMGUI_API
bool IsGlyphRangeUnused(
unsigned int c_begin,
unsigned int c_last);
3221enum ImGuiViewportFlags_
3223 ImGuiViewportFlags_None = 0,
3224 ImGuiViewportFlags_IsPlatformWindow = 1 << 0,
3225 ImGuiViewportFlags_IsPlatformMonitor = 1 << 1,
3226 ImGuiViewportFlags_OwnedByApp = 1 << 2,
3239 ImGuiViewportFlags Flags;
3246 void* PlatformHandle;
3247 void* PlatformHandleRaw;
3252 ImVec2 GetCenter()
const {
return ImVec2(Pos.x + Size.x * 0.5f, Pos.y + Size.y * 0.5f); }
3253 ImVec2 GetWorkCenter()
const {
return ImVec2(WorkPos.x + WorkSize.x * 0.5f, WorkPos.y + WorkSize.y * 0.5f); }
3265 float InputLineHeight;
3276#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
3280 static inline bool BeginChildFrame(ImGuiID
id,
const ImVec2& size, ImGuiWindowFlags window_flags = 0) {
return BeginChild(
id, size, ImGuiChildFlags_FrameStyle, window_flags); }
3281 static inline void EndChildFrame() { EndChild(); }
3284 static inline void ShowStackToolWindow(
bool* p_open = NULL) { ShowIDStackToolWindow(p_open); }
3285 IMGUI_API
bool ListBox(
const char* label,
int* current_item,
bool (*old_callback)(
void* user_data,
int idx,
const char** out_text),
void* user_data,
int items_count,
int height_in_items = -1);
3286 IMGUI_API
bool Combo(
const char* label,
int* current_item,
bool (*old_callback)(
void* user_data,
int idx,
const char** out_text),
void* user_data,
int items_count,
int popup_max_height_in_items = -1);
3288 IMGUI_API
void SetItemAllowOverlap();
3290 static inline void PushAllowKeyboardFocus(
bool tab_stop) { PushTabStop(tab_stop); }
3291 static inline void PopAllowKeyboardFocus() { PopTabStop(); }
3293 IMGUI_API
bool ImageButton(ImTextureID user_texture_id,
const ImVec2& size,
const ImVec2& uv0 =
ImVec2(0, 0),
const ImVec2& uv1 =
ImVec2(1, 1),
int frame_padding = -1,
const ImVec4& bg_col =
ImVec4(0, 0, 0, 0),
const ImVec4& tint_col =
ImVec4(1, 1, 1, 1));
3295 IMGUI_API ImGuiKey GetKeyIndex(ImGuiKey key);
3374typedef ImGuiKeyChord ImGuiModFlags;
3375enum ImGuiModFlags_ { ImGuiModFlags_None = 0, ImGuiModFlags_Ctrl = ImGuiMod_Ctrl, ImGuiModFlags_Shift = ImGuiMod_Shift, ImGuiModFlags_Alt = ImGuiMod_Alt, ImGuiModFlags_Super = ImGuiMod_Super };
3379#define IM_OFFSETOF(_TYPE,_MEMBER) offsetof(_TYPE, _MEMBER)
3384#if defined(IMGUI_DISABLE_METRICS_WINDOW) && !defined(IMGUI_DISABLE_OBSOLETE_FUNCTIONS) && !defined(IMGUI_DISABLE_DEBUG_TOOLS)
3385#define IMGUI_DISABLE_DEBUG_TOOLS
3387#if defined(IMGUI_DISABLE_METRICS_WINDOW) && defined(IMGUI_DISABLE_OBSOLETE_FUNCTIONS)
3388#error IMGUI_DISABLE_METRICS_WINDOW was renamed to IMGUI_DISABLE_DEBUG_TOOLS, please use new name.
3393#if defined(__clang__)
3394#pragma clang diagnostic pop
3395#elif defined(__GNUC__)
3396#pragma GCC diagnostic pop
3400#pragma warning (pop)
3405#ifdef IMGUI_INCLUDE_IMGUI_USER_H
3406#ifdef IMGUI_USER_H_FILENAME
3407#include IMGUI_USER_H_FILENAME
3409#include "imgui_user.h"
Definition imgui_internal.h:774
Definition imgui_internal.h:3580
Definition imgui_internal.h:1922