From 06a5331b9cfc9411ef257024eaa9a65ef5e1cc12 Mon Sep 17 00:00:00 2001 From: sonoro1234 Date: Wed, 2 May 2018 19:58:33 +0200 Subject: [PATCH] start branch master_auto --- cimgui/auto_funcs.cpp | 1900 +++++++++++++++++++++++++++++++++ cimgui/auto_funcs.h | 475 +++++++++ cimgui/cimgui.cpp | 1881 +------------------------------- cimgui/cimgui.h | 642 +---------- cimgui/cimgui.sln | 28 - cimgui/cimgui.vcxproj | 161 --- cimgui/cimgui.vcxproj.filters | 48 - cimgui/drawList.cpp | 293 ----- cimgui/fontAtlas.cpp | 328 ------ cimgui/gen_imgui_funcs.bat | 9 + cimgui/gen_imgui_funcs.lua | 346 ++++++ cimgui/listClipper.cpp | 27 - 12 files changed, 2732 insertions(+), 3406 deletions(-) create mode 100644 cimgui/auto_funcs.cpp create mode 100644 cimgui/auto_funcs.h delete mode 100644 cimgui/cimgui.sln delete mode 100644 cimgui/cimgui.vcxproj delete mode 100644 cimgui/cimgui.vcxproj.filters delete mode 100644 cimgui/drawList.cpp delete mode 100644 cimgui/fontAtlas.cpp create mode 100644 cimgui/gen_imgui_funcs.bat create mode 100644 cimgui/gen_imgui_funcs.lua delete mode 100644 cimgui/listClipper.cpp diff --git a/cimgui/auto_funcs.cpp b/cimgui/auto_funcs.cpp new file mode 100644 index 0000000..c4d7392 --- /dev/null +++ b/cimgui/auto_funcs.cpp @@ -0,0 +1,1900 @@ +CIMGUI_API ImGuiContext* igCreateContext(ImFontAtlas* shared_font_atlas) +{ + return ImGui::CreateContext(shared_font_atlas); +} +CIMGUI_API void igDestroyContext(ImGuiContext* ctx) +{ + return ImGui::DestroyContext(ctx); +} +CIMGUI_API ImGuiContext* igGetCurrentContext() +{ + return ImGui::GetCurrentContext(); +} +CIMGUI_API void igSetCurrentContext(ImGuiContext* ctx) +{ + return ImGui::SetCurrentContext(ctx); +} +CIMGUI_API ImGuiIO* igGetIO() +{ + return ImGui::GetIO(); +} +CIMGUI_API ImGuiStyle* igGetStyle() +{ + return ImGui::GetStyle(); +} +CIMGUI_API void igNewFrame() +{ + return ImGui::NewFrame(); +} +CIMGUI_API void igRender() +{ + return ImGui::Render(); +} +CIMGUI_API ImDrawData* igGetDrawData() +{ + return ImGui::GetDrawData(); +} +CIMGUI_API void igEndFrame() +{ + return ImGui::EndFrame(); +} +CIMGUI_API void igShowDemoWindow(bool* p_open) +{ + return ImGui::ShowDemoWindow(p_open); +} +CIMGUI_API void igShowMetricsWindow(bool* p_open) +{ + return ImGui::ShowMetricsWindow(p_open); +} +CIMGUI_API void igShowStyleEditor(ImGuiStyle* ref) +{ + return ImGui::ShowStyleEditor(ref); +} +CIMGUI_API bool igShowStyleSelector(const char* label) +{ + return ImGui::ShowStyleSelector(label); +} +CIMGUI_API void igShowFontSelector(const char* label) +{ + return ImGui::ShowFontSelector(label); +} +CIMGUI_API void igShowUserGuide() +{ + return ImGui::ShowUserGuide(); +} +CIMGUI_API const char* igGetVersion() +{ + return ImGui::GetVersion(); +} +CIMGUI_API void igStyleColorsDark(ImGuiStyle* dst) +{ + return ImGui::StyleColorsDark(dst); +} +CIMGUI_API void igStyleColorsClassic(ImGuiStyle* dst) +{ + return ImGui::StyleColorsClassic(dst); +} +CIMGUI_API void igStyleColorsLight(ImGuiStyle* dst) +{ + return ImGui::StyleColorsLight(dst); +} +CIMGUI_API bool igBegin(const char* name,bool* p_open,ImGuiWindowFlags flags) +{ + return ImGui::Begin(name,p_open,flags); +} +CIMGUI_API void igEnd() +{ + return ImGui::End(); +} +CIMGUI_API bool igBeginChildStr(const char* str_id,const ImVec2 size,bool border,ImGuiWindowFlags flags) +{ + return ImGui::BeginChild(str_id,size,border,flags); +} +CIMGUI_API bool igBeginChildID(ImGuiID id,const ImVec2 size,bool border,ImGuiWindowFlags flags) +{ + return ImGui::BeginChild(id,size,border,flags); +} +CIMGUI_API void igEndChild() +{ + return ImGui::EndChild(); +} +CIMGUI_API bool igIsWindowAppearing() +{ + return ImGui::IsWindowAppearing(); +} +CIMGUI_API bool igIsWindowCollapsed() +{ + return ImGui::IsWindowCollapsed(); +} +CIMGUI_API bool igIsWindowFocused(ImGuiFocusedFlags flags) +{ + return ImGui::IsWindowFocused(flags); +} +CIMGUI_API bool igIsWindowHovered(ImGuiHoveredFlags flags) +{ + return ImGui::IsWindowHovered(flags); +} +CIMGUI_API ImDrawList* igGetWindowDrawList() +{ + return ImGui::GetWindowDrawList(); +} +CIMGUI_API ImVec2 igGetWindowPos() +{ + return ImGui::GetWindowPos(); +} +CIMGUI_API ImVec2 igGetWindowSize() +{ + return ImGui::GetWindowSize(); +} +CIMGUI_API float igGetWindowWidth() +{ + return ImGui::GetWindowWidth(); +} +CIMGUI_API float igGetWindowHeight() +{ + return ImGui::GetWindowHeight(); +} +CIMGUI_API ImVec2 igGetContentRegionMax() +{ + return ImGui::GetContentRegionMax(); +} +CIMGUI_API ImVec2 igGetContentRegionAvail() +{ + return ImGui::GetContentRegionAvail(); +} +CIMGUI_API float igGetContentRegionAvailWidth() +{ + return ImGui::GetContentRegionAvailWidth(); +} +CIMGUI_API ImVec2 igGetWindowContentRegionMin() +{ + return ImGui::GetWindowContentRegionMin(); +} +CIMGUI_API ImVec2 igGetWindowContentRegionMax() +{ + return ImGui::GetWindowContentRegionMax(); +} +CIMGUI_API float igGetWindowContentRegionWidth() +{ + return ImGui::GetWindowContentRegionWidth(); +} +CIMGUI_API void igSetNextWindowPos(const ImVec2 pos,ImGuiCond cond,const ImVec2 pivot) +{ + return ImGui::SetNextWindowPos(pos,cond,pivot); +} +CIMGUI_API void igSetNextWindowSize(const ImVec2 size,ImGuiCond cond) +{ + return ImGui::SetNextWindowSize(size,cond); +} +CIMGUI_API void igSetNextWindowSizeConstraints(const ImVec2 size_min,const ImVec2 size_max,ImGuiSizeCallback custom_callback,void* custom_callback_data) +{ + return ImGui::SetNextWindowSizeConstraints(size_min,size_max,custom_callback,custom_callback_data); +} +CIMGUI_API void igSetNextWindowContentSize(const ImVec2 size) +{ + return ImGui::SetNextWindowContentSize(size); +} +CIMGUI_API void igSetNextWindowCollapsed(bool collapsed,ImGuiCond cond) +{ + return ImGui::SetNextWindowCollapsed(collapsed,cond); +} +CIMGUI_API void igSetNextWindowFocus() +{ + return ImGui::SetNextWindowFocus(); +} +CIMGUI_API void igSetNextWindowBgAlpha(float alpha) +{ + return ImGui::SetNextWindowBgAlpha(alpha); +} +CIMGUI_API void igSetWindowPosVec2(const ImVec2 pos,ImGuiCond cond) +{ + return ImGui::SetWindowPos(pos,cond); +} +CIMGUI_API void igSetWindowSizeVec2(const ImVec2 size,ImGuiCond cond) +{ + return ImGui::SetWindowSize(size,cond); +} +CIMGUI_API void igSetWindowCollapsedBool(bool collapsed,ImGuiCond cond) +{ + return ImGui::SetWindowCollapsed(collapsed,cond); +} +CIMGUI_API void igSetWindowFocus() +{ + return ImGui::SetWindowFocus(); +} +CIMGUI_API void igSetWindowFontScale(float scale) +{ + return ImGui::SetWindowFontScale(scale); +} +CIMGUI_API void igSetWindowPosStr(const char* name,const ImVec2 pos,ImGuiCond cond) +{ + return ImGui::SetWindowPos(name,pos,cond); +} +CIMGUI_API void igSetWindowSizeStr(const char* name,const ImVec2 size,ImGuiCond cond) +{ + return ImGui::SetWindowSize(name,size,cond); +} +CIMGUI_API void igSetWindowCollapsedStr(const char* name,bool collapsed,ImGuiCond cond) +{ + return ImGui::SetWindowCollapsed(name,collapsed,cond); +} +CIMGUI_API void igSetWindowFocusStr(const char* name) +{ + return ImGui::SetWindowFocus(name); +} +CIMGUI_API float igGetScrollX() +{ + return ImGui::GetScrollX(); +} +CIMGUI_API float igGetScrollY() +{ + return ImGui::GetScrollY(); +} +CIMGUI_API float igGetScrollMaxX() +{ + return ImGui::GetScrollMaxX(); +} +CIMGUI_API float igGetScrollMaxY() +{ + return ImGui::GetScrollMaxY(); +} +CIMGUI_API void igSetScrollX(float scroll_x) +{ + return ImGui::SetScrollX(scroll_x); +} +CIMGUI_API void igSetScrollY(float scroll_y) +{ + return ImGui::SetScrollY(scroll_y); +} +CIMGUI_API void igSetScrollHere(float center_y_ratio) +{ + return ImGui::SetScrollHere(center_y_ratio); +} +CIMGUI_API void igSetScrollFromPosY(float pos_y,float center_y_ratio) +{ + return ImGui::SetScrollFromPosY(pos_y,center_y_ratio); +} +CIMGUI_API void igPushFont(ImFont* font) +{ + return ImGui::PushFont(font); +} +CIMGUI_API void igPopFont() +{ + return ImGui::PopFont(); +} +CIMGUI_API void igPushStyleColorU32(ImGuiCol idx,ImU32 col) +{ + return ImGui::PushStyleColor(idx,col); +} +CIMGUI_API void igPushStyleColorVec4(ImGuiCol idx,const ImVec4 col) +{ + return ImGui::PushStyleColor(idx,col); +} +CIMGUI_API void igPopStyleColor(int count) +{ + return ImGui::PopStyleColor(count); +} +CIMGUI_API void igPushStyleVarFloat(ImGuiStyleVar idx,float val) +{ + return ImGui::PushStyleVar(idx,val); +} +CIMGUI_API void igPushStyleVarVec2(ImGuiStyleVar idx,const ImVec2 val) +{ + return ImGui::PushStyleVar(idx,val); +} +CIMGUI_API void igPopStyleVar(int count) +{ + return ImGui::PopStyleVar(count); +} +CIMGUI_API const ImVec4* igGetStyleColorVec4(ImGuiCol idx) +{ + return ImGui::GetStyleColorVec4(idx); +} +CIMGUI_API ImFont* igGetFont() +{ + return ImGui::GetFont(); +} +CIMGUI_API float igGetFontSize() +{ + return ImGui::GetFontSize(); +} +CIMGUI_API ImVec2 igGetFontTexUvWhitePixel() +{ + return ImGui::GetFontTexUvWhitePixel(); +} +CIMGUI_API ImU32 igGetColorU32Col(ImGuiCol idx,float alpha_mul) +{ + return ImGui::GetColorU32(idx,alpha_mul); +} +CIMGUI_API ImU32 igGetColorU32Vec4(const ImVec4 col) +{ + return ImGui::GetColorU32(col); +} +CIMGUI_API ImU32 igGetColorU32U32(ImU32 col) +{ + return ImGui::GetColorU32(col); +} +CIMGUI_API void igPushItemWidth(float item_width) +{ + return ImGui::PushItemWidth(item_width); +} +CIMGUI_API void igPopItemWidth() +{ + return ImGui::PopItemWidth(); +} +CIMGUI_API float igCalcItemWidth() +{ + return ImGui::CalcItemWidth(); +} +CIMGUI_API void igPushTextWrapPos(float wrap_pos_x) +{ + return ImGui::PushTextWrapPos(wrap_pos_x); +} +CIMGUI_API void igPopTextWrapPos() +{ + return ImGui::PopTextWrapPos(); +} +CIMGUI_API void igPushAllowKeyboardFocus(bool allow_keyboard_focus) +{ + return ImGui::PushAllowKeyboardFocus(allow_keyboard_focus); +} +CIMGUI_API void igPopAllowKeyboardFocus() +{ + return ImGui::PopAllowKeyboardFocus(); +} +CIMGUI_API void igPushButtonRepeat(bool repeat) +{ + return ImGui::PushButtonRepeat(repeat); +} +CIMGUI_API void igPopButtonRepeat() +{ + return ImGui::PopButtonRepeat(); +} +CIMGUI_API void igSeparator() +{ + return ImGui::Separator(); +} +CIMGUI_API void igSameLine(float pos_x,float spacing_w) +{ + return ImGui::SameLine(pos_x,spacing_w); +} +CIMGUI_API void igNewLine() +{ + return ImGui::NewLine(); +} +CIMGUI_API void igSpacing() +{ + return ImGui::Spacing(); +} +CIMGUI_API void igDummy(const ImVec2 size) +{ + return ImGui::Dummy(size); +} +CIMGUI_API void igIndent(float indent_w) +{ + return ImGui::Indent(indent_w); +} +CIMGUI_API void igUnindent(float indent_w) +{ + return ImGui::Unindent(indent_w); +} +CIMGUI_API void igBeginGroup() +{ + return ImGui::BeginGroup(); +} +CIMGUI_API void igEndGroup() +{ + return ImGui::EndGroup(); +} +CIMGUI_API ImVec2 igGetCursorPos() +{ + return ImGui::GetCursorPos(); +} +CIMGUI_API float igGetCursorPosX() +{ + return ImGui::GetCursorPosX(); +} +CIMGUI_API float igGetCursorPosY() +{ + return ImGui::GetCursorPosY(); +} +CIMGUI_API void igSetCursorPos(const ImVec2 local_pos) +{ + return ImGui::SetCursorPos(local_pos); +} +CIMGUI_API void igSetCursorPosX(float x) +{ + return ImGui::SetCursorPosX(x); +} +CIMGUI_API void igSetCursorPosY(float y) +{ + return ImGui::SetCursorPosY(y); +} +CIMGUI_API ImVec2 igGetCursorStartPos() +{ + return ImGui::GetCursorStartPos(); +} +CIMGUI_API ImVec2 igGetCursorScreenPos() +{ + return ImGui::GetCursorScreenPos(); +} +CIMGUI_API void igSetCursorScreenPos(const ImVec2 screen_pos) +{ + return ImGui::SetCursorScreenPos(screen_pos); +} +CIMGUI_API void igAlignTextToFramePadding() +{ + return ImGui::AlignTextToFramePadding(); +} +CIMGUI_API float igGetTextLineHeight() +{ + return ImGui::GetTextLineHeight(); +} +CIMGUI_API float igGetTextLineHeightWithSpacing() +{ + return ImGui::GetTextLineHeightWithSpacing(); +} +CIMGUI_API float igGetFrameHeight() +{ + return ImGui::GetFrameHeight(); +} +CIMGUI_API float igGetFrameHeightWithSpacing() +{ + return ImGui::GetFrameHeightWithSpacing(); +} +CIMGUI_API void igPushIDStr(const char* str_id) +{ + return ImGui::PushID(str_id); +} +CIMGUI_API void igPushIDRange(const char* str_id_begin,const char* str_id_end) +{ + return ImGui::PushID(str_id_begin,str_id_end); +} +CIMGUI_API void igPushIDPtr(const void* ptr_id) +{ + return ImGui::PushID(ptr_id); +} +CIMGUI_API void igPushIDInt(int int_id) +{ + return ImGui::PushID(int_id); +} +CIMGUI_API void igPopID() +{ + return ImGui::PopID(); +} +CIMGUI_API ImGuiID igGetIDStr(const char* str_id) +{ + return ImGui::GetID(str_id); +} +CIMGUI_API ImGuiID igGetIDStrStr(const char* str_id_begin,const char* str_id_end) +{ + return ImGui::GetID(str_id_begin,str_id_end); +} +CIMGUI_API ImGuiID igGetIDPtr(const void* ptr_id) +{ + return ImGui::GetID(ptr_id); +} +CIMGUI_API void igTextUnformatted(const char* text,const char* text_end) +{ + return ImGui::TextUnformatted(text,text_end); +} +CIMGUI_API void igText(const char* fmt,...) +{ + return ImGui::Text(fmt,...); +} +CIMGUI_API void igTextV(const char* fmt,va_list args) +{ + return ImGui::TextV(fmt,args); +} +CIMGUI_API void igTextColored(const ImVec4 col,const char* fmt,...) +{ + return ImGui::TextColored(col,fmt,...); +} +CIMGUI_API void igTextColoredV(const ImVec4 col,const char* fmt,va_list args) +{ + return ImGui::TextColoredV(col,fmt,args); +} +CIMGUI_API void igTextDisabled(const char* fmt,...) +{ + return ImGui::TextDisabled(fmt,...); +} +CIMGUI_API void igTextDisabledV(const char* fmt,va_list args) +{ + return ImGui::TextDisabledV(fmt,args); +} +CIMGUI_API void igTextWrapped(const char* fmt,...) +{ + return ImGui::TextWrapped(fmt,...); +} +CIMGUI_API void igTextWrappedV(const char* fmt,va_list args) +{ + return ImGui::TextWrappedV(fmt,args); +} +CIMGUI_API void igLabelText(const char* label,const char* fmt,...) +{ + return ImGui::LabelText(label,fmt,...); +} +CIMGUI_API void igLabelTextV(const char* label,const char* fmt,va_list args) +{ + return ImGui::LabelTextV(label,fmt,args); +} +CIMGUI_API void igBulletText(const char* fmt,...) +{ + return ImGui::BulletText(fmt,...); +} +CIMGUI_API void igBulletTextV(const char* fmt,va_list args) +{ + return ImGui::BulletTextV(fmt,args); +} +CIMGUI_API bool igButton(const char* label,const ImVec2 size) +{ + return ImGui::Button(label,size); +} +CIMGUI_API bool igSmallButton(const char* label) +{ + return ImGui::SmallButton(label); +} +CIMGUI_API bool igArrowButton(const char* str_id,ImGuiDir dir) +{ + return ImGui::ArrowButton(str_id,dir); +} +CIMGUI_API bool igInvisibleButton(const char* str_id,const ImVec2 size) +{ + return ImGui::InvisibleButton(str_id,size); +} +CIMGUI_API void igImage(ImTextureID user_texture_id,const ImVec2 size,const ImVec2 uv0,const ImVec2 uv1,const ImVec4 tint_col,const ImVec4 border_col) +{ + return ImGui::Image(user_texture_id,size,uv0,uv1,tint_col,border_col); +} +CIMGUI_API bool igImageButton(ImTextureID user_texture_id,const ImVec2 size,const ImVec2 uv0,const ImVec2 uv1,int frame_padding,const ImVec4 bg_col,const ImVec4 tint_col) +{ + return ImGui::ImageButton(user_texture_id,size,uv0,uv1,frame_padding,bg_col,tint_col); +} +CIMGUI_API bool igCheckbox(const char* label,bool* v) +{ + return ImGui::Checkbox(label,v); +} +CIMGUI_API bool igCheckboxFlags(const char* label,unsigned int* flags,unsigned int flags_value) +{ + return ImGui::CheckboxFlags(label,flags,flags_value); +} +CIMGUI_API bool igRadioButtonBool(const char* label,bool active) +{ + return ImGui::RadioButton(label,active); +} +CIMGUI_API bool igRadioButtonIntPtr(const char* label,int* v,int v_button) +{ + return ImGui::RadioButton(label,v,v_button); +} +CIMGUI_API void igPlotLinesFloatPtr(const char* label,const float* values,int values_count,int values_offset,const char* overlay_text,float scale_min,float scale_max,ImVec2 graph_size,int stride) +{ + return ImGui::PlotLines(label,values,values_count,values_offset,overlay_text,scale_min,scale_max,graph_size,stride); +} +CIMGUI_API void igPlotLinesvalues_getter(const char* label,float(*values_getter)(void* data,int idx),void* data,int values_count,int values_offset,const char* overlay_text,float scale_min,float scale_max,ImVec2 graph_size) +{ + return ImGui::PlotLines(label,values_getter)(data,idx)data,values_count,values_offset,overlay_text,scale_min,scale_max,graph_size); +} +CIMGUI_API void igPlotHistogramFloatPtr(const char* label,const float* values,int values_count,int values_offset,const char* overlay_text,float scale_min,float scale_max,ImVec2 graph_size,int stride) +{ + return ImGui::PlotHistogram(label,values,values_count,values_offset,overlay_text,scale_min,scale_max,graph_size,stride); +} +CIMGUI_API void igPlotHistogramvalues_getter(const char* label,float(*values_getter)(void* data,int idx),void* data,int values_count,int values_offset,const char* overlay_text,float scale_min,float scale_max,ImVec2 graph_size) +{ + return ImGui::PlotHistogram(label,values_getter)(data,idx)data,values_count,values_offset,overlay_text,scale_min,scale_max,graph_size); +} +CIMGUI_API void igProgressBar(float fraction,const ImVec2 size_arg,const char* overlay) +{ + return ImGui::ProgressBar(fraction,size_arg,overlay); +} +CIMGUI_API void igBullet() +{ + return ImGui::Bullet(); +} +CIMGUI_API bool igBeginCombo(const char* label,const char* preview_value,ImGuiComboFlags flags) +{ + return ImGui::BeginCombo(label,preview_value,flags); +} +CIMGUI_API void igEndCombo() +{ + return ImGui::EndCombo(); +} +CIMGUI_API bool igComboStr_arr(const char* label,int* current_item,const char* const items[],int items_count,int popup_max_height_in_items) +{ + return ImGui::Combo(label,current_item,items_count,popup_max_height_in_items); +} +CIMGUI_API bool igComboStr(const char* label,int* current_item,const char* items_separated_by_zeros,int popup_max_height_in_items) +{ + return ImGui::Combo(label,current_item,items_separated_by_zeros,popup_max_height_in_items); +} +CIMGUI_API bool igComboitems_getter(const char* label,int* current_item,bool(*items_getter)(void* data,int idx,const char** out_text),void* data,int items_count,int popup_max_height_in_items) +{ + return ImGui::Combo(label,current_item,items_getter)(data,idx,out_text)data,items_count,popup_max_height_in_items); +} +CIMGUI_API bool igDragFloat(const char* label,float* v,float v_speed,float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::DragFloat(label,v,v_speed,v_min,v_max,display_format,power); +} +CIMGUI_API bool igDragFloat2(const char* label,float v[2],float v_speed,float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::DragFloat2(label,v_speed,v_min,v_max,display_format,power); +} +CIMGUI_API bool igDragFloat3(const char* label,float v[3],float v_speed,float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::DragFloat3(label,v_speed,v_min,v_max,display_format,power); +} +CIMGUI_API bool igDragFloat4(const char* label,float v[4],float v_speed,float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::DragFloat4(label,v_speed,v_min,v_max,display_format,power); +} +CIMGUI_API bool igDragFloatRange2(const char* label,float* v_current_min,float* v_current_max,float v_speed,float v_min,float v_max,const char* display_format,const char* display_format_max,float power) +{ + return ImGui::DragFloatRange2(label,v_current_min,v_current_max,v_speed,v_min,v_max,display_format,display_format_max,power); +} +CIMGUI_API bool igDragInt(const char* label,int* v,float v_speed,int v_min,int v_max,const char* display_format) +{ + return ImGui::DragInt(label,v,v_speed,v_min,v_max,display_format); +} +CIMGUI_API bool igDragInt2(const char* label,int v[2],float v_speed,int v_min,int v_max,const char* display_format) +{ + return ImGui::DragInt2(label,v_speed,v_min,v_max,display_format); +} +CIMGUI_API bool igDragInt3(const char* label,int v[3],float v_speed,int v_min,int v_max,const char* display_format) +{ + return ImGui::DragInt3(label,v_speed,v_min,v_max,display_format); +} +CIMGUI_API bool igDragInt4(const char* label,int v[4],float v_speed,int v_min,int v_max,const char* display_format) +{ + return ImGui::DragInt4(label,v_speed,v_min,v_max,display_format); +} +CIMGUI_API bool igDragIntRange2(const char* label,int* v_current_min,int* v_current_max,float v_speed,int v_min,int v_max,const char* display_format,const char* display_format_max) +{ + return ImGui::DragIntRange2(label,v_current_min,v_current_max,v_speed,v_min,v_max,display_format,display_format_max); +} +CIMGUI_API bool igInputText(const char* label,char* buf,size_t buf_size,ImGuiInputTextFlags flags,ImGuiTextEditCallback callback,void* user_data) +{ + return ImGui::InputText(label,buf,buf_size,flags,callback,user_data); +} +CIMGUI_API bool igInputTextMultiline(const char* label,char* buf,size_t buf_size,const ImVec2 size,ImGuiInputTextFlags flags,ImGuiTextEditCallback callback,void* user_data) +{ + return ImGui::InputTextMultiline(label,buf,buf_size,size,flags,callback,user_data); +} +CIMGUI_API bool igInputFloat(const char* label,float* v,float step,float step_fast,int decimal_precision,ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputFloat(label,v,step,step_fast,decimal_precision,extra_flags); +} +CIMGUI_API bool igInputFloat2(const char* label,float v[2],int decimal_precision,ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputFloat2(label,decimal_precision,extra_flags); +} +CIMGUI_API bool igInputFloat3(const char* label,float v[3],int decimal_precision,ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputFloat3(label,decimal_precision,extra_flags); +} +CIMGUI_API bool igInputFloat4(const char* label,float v[4],int decimal_precision,ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputFloat4(label,decimal_precision,extra_flags); +} +CIMGUI_API bool igInputInt(const char* label,int* v,int step,int step_fast,ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputInt(label,v,step,step_fast,extra_flags); +} +CIMGUI_API bool igInputInt2(const char* label,int v[2],ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputInt2(label,extra_flags); +} +CIMGUI_API bool igInputInt3(const char* label,int v[3],ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputInt3(label,extra_flags); +} +CIMGUI_API bool igInputInt4(const char* label,int v[4],ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputInt4(label,extra_flags); +} +CIMGUI_API bool igInputDouble(const char* label,double* v,double step,double step_fast,const char* display_format,ImGuiInputTextFlags extra_flags) +{ + return ImGui::InputDouble(label,v,step,step_fast,display_format,extra_flags); +} +CIMGUI_API bool igSliderFloat(const char* label,float* v,float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::SliderFloat(label,v,v_min,v_max,display_format,power); +} +CIMGUI_API bool igSliderFloat2(const char* label,float v[2],float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::SliderFloat2(label,v_min,v_max,display_format,power); +} +CIMGUI_API bool igSliderFloat3(const char* label,float v[3],float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::SliderFloat3(label,v_min,v_max,display_format,power); +} +CIMGUI_API bool igSliderFloat4(const char* label,float v[4],float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::SliderFloat4(label,v_min,v_max,display_format,power); +} +CIMGUI_API bool igSliderAngle(const char* label,float* v_rad,float v_degrees_min,float v_degrees_max) +{ + return ImGui::SliderAngle(label,v_rad,v_degrees_min,v_degrees_max); +} +CIMGUI_API bool igSliderInt(const char* label,int* v,int v_min,int v_max,const char* display_format) +{ + return ImGui::SliderInt(label,v,v_min,v_max,display_format); +} +CIMGUI_API bool igSliderInt2(const char* label,int v[2],int v_min,int v_max,const char* display_format) +{ + return ImGui::SliderInt2(label,v_min,v_max,display_format); +} +CIMGUI_API bool igSliderInt3(const char* label,int v[3],int v_min,int v_max,const char* display_format) +{ + return ImGui::SliderInt3(label,v_min,v_max,display_format); +} +CIMGUI_API bool igSliderInt4(const char* label,int v[4],int v_min,int v_max,const char* display_format) +{ + return ImGui::SliderInt4(label,v_min,v_max,display_format); +} +CIMGUI_API bool igVSliderFloat(const char* label,const ImVec2 size,float* v,float v_min,float v_max,const char* display_format,float power) +{ + return ImGui::VSliderFloat(label,size,v,v_min,v_max,display_format,power); +} +CIMGUI_API bool igVSliderInt(const char* label,const ImVec2 size,int* v,int v_min,int v_max,const char* display_format) +{ + return ImGui::VSliderInt(label,size,v,v_min,v_max,display_format); +} +CIMGUI_API bool igColorEdit3(const char* label,float col[3],ImGuiColorEditFlags flags) +{ + return ImGui::ColorEdit3(label,flags); +} +CIMGUI_API bool igColorEdit4(const char* label,float col[4],ImGuiColorEditFlags flags) +{ + return ImGui::ColorEdit4(label,flags); +} +CIMGUI_API bool igColorPicker3(const char* label,float col[3],ImGuiColorEditFlags flags) +{ + return ImGui::ColorPicker3(label,flags); +} +CIMGUI_API bool igColorPicker4(const char* label,float col[4],ImGuiColorEditFlags flags,const float* ref_col) +{ + return ImGui::ColorPicker4(label,flags,ref_col); +} +CIMGUI_API bool igColorButton(const char* desc_id,const ImVec4 col,ImGuiColorEditFlags flags,ImVec2 size) +{ + return ImGui::ColorButton(desc_id,col,flags,size); +} +CIMGUI_API void igSetColorEditOptions(ImGuiColorEditFlags flags) +{ + return ImGui::SetColorEditOptions(flags); +} +CIMGUI_API bool igTreeNodeStr(const char* label) +{ + return ImGui::TreeNode(label); +} +CIMGUI_API bool igTreeNodeStrStr(const char* str_id,const char* fmt,...) +{ + return ImGui::TreeNode(str_id,fmt,...); +} +CIMGUI_API bool igTreeNodePtr(const void* ptr_id,const char* fmt,...) +{ + return ImGui::TreeNode(ptr_id,fmt,...); +} +CIMGUI_API bool igTreeNodeVStr(const char* str_id,const char* fmt,va_list args) +{ + return ImGui::TreeNodeV(str_id,fmt,args); +} +CIMGUI_API bool igTreeNodeVPtr(const void* ptr_id,const char* fmt,va_list args) +{ + return ImGui::TreeNodeV(ptr_id,fmt,args); +} +CIMGUI_API bool igTreeNodeExStr(const char* label,ImGuiTreeNodeFlags flags) +{ + return ImGui::TreeNodeEx(label,flags); +} +CIMGUI_API bool igTreeNodeExStrStr(const char* str_id,ImGuiTreeNodeFlags flags,const char* fmt,...) +{ + return ImGui::TreeNodeEx(str_id,flags,fmt,...); +} +CIMGUI_API bool igTreeNodeExPtr(const void* ptr_id,ImGuiTreeNodeFlags flags,const char* fmt,...) +{ + return ImGui::TreeNodeEx(ptr_id,flags,fmt,...); +} +CIMGUI_API bool igTreeNodeExVStr(const char* str_id,ImGuiTreeNodeFlags flags,const char* fmt,va_list args) +{ + return ImGui::TreeNodeExV(str_id,flags,fmt,args); +} +CIMGUI_API bool igTreeNodeExVPtr(const void* ptr_id,ImGuiTreeNodeFlags flags,const char* fmt,va_list args) +{ + return ImGui::TreeNodeExV(ptr_id,flags,fmt,args); +} +CIMGUI_API void igTreePushStr(const char* str_id) +{ + return ImGui::TreePush(str_id); +} +CIMGUI_API void igTreePushPtr(const void* ptr_id) +{ + return ImGui::TreePush(ptr_id); +} +CIMGUI_API void igTreePop() +{ + return ImGui::TreePop(); +} +CIMGUI_API void igTreeAdvanceToLabelPos() +{ + return ImGui::TreeAdvanceToLabelPos(); +} +CIMGUI_API float igGetTreeNodeToLabelSpacing() +{ + return ImGui::GetTreeNodeToLabelSpacing(); +} +CIMGUI_API void igSetNextTreeNodeOpen(bool is_open,ImGuiCond cond) +{ + return ImGui::SetNextTreeNodeOpen(is_open,cond); +} +CIMGUI_API bool igCollapsingHeaderTreeNodeFlags(const char* label,ImGuiTreeNodeFlags flags) +{ + return ImGui::CollapsingHeader(label,flags); +} +CIMGUI_API bool igCollapsingHeaderBoolPtr(const char* label,bool* p_open,ImGuiTreeNodeFlags flags) +{ + return ImGui::CollapsingHeader(label,p_open,flags); +} +CIMGUI_API bool igSelectableBool(const char* label,bool selected,ImGuiSelectableFlags flags,const ImVec2 size) +{ + return ImGui::Selectable(label,selected,flags,size); +} +CIMGUI_API bool igSelectableBoolPtr(const char* label,bool* p_selected,ImGuiSelectableFlags flags,const ImVec2 size) +{ + return ImGui::Selectable(label,p_selected,flags,size); +} +CIMGUI_API bool igListBoxStr_arr(const char* label,int* current_item,const char* const items[],int items_count,int height_in_items) +{ + return ImGui::ListBox(label,current_item,items_count,height_in_items); +} +CIMGUI_API bool igListBoxitems_getter(const char* label,int* current_item,bool(*items_getter)(void* data,int idx,const char** out_text),void* data,int items_count,int height_in_items) +{ + return ImGui::ListBox(label,current_item,items_getter)(data,idx,out_text)data,items_count,height_in_items); +} +CIMGUI_API bool igListBoxHeaderVec2(const char* label,const ImVec2 size) +{ + return ImGui::ListBoxHeader(label,size); +} +CIMGUI_API bool igListBoxHeaderInt(const char* label,int items_count,int height_in_items) +{ + return ImGui::ListBoxHeader(label,items_count,height_in_items); +} +CIMGUI_API void igListBoxFooter() +{ + return ImGui::ListBoxFooter(); +} +CIMGUI_API void igValueBool(const char* prefix,bool b) +{ + return ImGui::Value(prefix,b); +} +CIMGUI_API void igValueInt(const char* prefix,int v) +{ + return ImGui::Value(prefix,v); +} +CIMGUI_API void igValueUint(const char* prefix,unsigned int v) +{ + return ImGui::Value(prefix,v); +} +CIMGUI_API void igValueFloat(const char* prefix,float v,const char* float_format) +{ + return ImGui::Value(prefix,v,float_format); +} +CIMGUI_API void igSetTooltip(const char* fmt,...) +{ + return ImGui::SetTooltip(fmt,...); +} +CIMGUI_API void igSetTooltipV(const char* fmt,va_list args) +{ + return ImGui::SetTooltipV(fmt,args); +} +CIMGUI_API void igBeginTooltip() +{ + return ImGui::BeginTooltip(); +} +CIMGUI_API void igEndTooltip() +{ + return ImGui::EndTooltip(); +} +CIMGUI_API bool igBeginMainMenuBar() +{ + return ImGui::BeginMainMenuBar(); +} +CIMGUI_API void igEndMainMenuBar() +{ + return ImGui::EndMainMenuBar(); +} +CIMGUI_API bool igBeginMenuBar() +{ + return ImGui::BeginMenuBar(); +} +CIMGUI_API void igEndMenuBar() +{ + return ImGui::EndMenuBar(); +} +CIMGUI_API bool igBeginMenu(const char* label,bool enabled) +{ + return ImGui::BeginMenu(label,enabled); +} +CIMGUI_API void igEndMenu() +{ + return ImGui::EndMenu(); +} +CIMGUI_API bool igMenuItemBool(const char* label,const char* shortcut,bool selected,bool enabled) +{ + return ImGui::MenuItem(label,shortcut,selected,enabled); +} +CIMGUI_API bool igMenuItemBoolPtr(const char* label,const char* shortcut,bool* p_selected,bool enabled) +{ + return ImGui::MenuItem(label,shortcut,p_selected,enabled); +} +CIMGUI_API void igOpenPopup(const char* str_id) +{ + return ImGui::OpenPopup(str_id); +} +CIMGUI_API bool igBeginPopup(const char* str_id,ImGuiWindowFlags flags) +{ + return ImGui::BeginPopup(str_id,flags); +} +CIMGUI_API bool igBeginPopupContextItem(const char* str_id,int mouse_button) +{ + return ImGui::BeginPopupContextItem(str_id,mouse_button); +} +CIMGUI_API bool igBeginPopupContextWindow(const char* str_id,int mouse_button,bool also_over_items) +{ + return ImGui::BeginPopupContextWindow(str_id,mouse_button,also_over_items); +} +CIMGUI_API bool igBeginPopupContextVoid(const char* str_id,int mouse_button) +{ + return ImGui::BeginPopupContextVoid(str_id,mouse_button); +} +CIMGUI_API bool igBeginPopupModal(const char* name,bool* p_open,ImGuiWindowFlags flags) +{ + return ImGui::BeginPopupModal(name,p_open,flags); +} +CIMGUI_API void igEndPopup() +{ + return ImGui::EndPopup(); +} +CIMGUI_API bool igOpenPopupOnItemClick(const char* str_id,int mouse_button) +{ + return ImGui::OpenPopupOnItemClick(str_id,mouse_button); +} +CIMGUI_API bool igIsPopupOpen(const char* str_id) +{ + return ImGui::IsPopupOpen(str_id); +} +CIMGUI_API void igCloseCurrentPopup() +{ + return ImGui::CloseCurrentPopup(); +} +CIMGUI_API void igColumns(int count,const char* id,bool border) +{ + return ImGui::Columns(count,id,border); +} +CIMGUI_API void igNextColumn() +{ + return ImGui::NextColumn(); +} +CIMGUI_API int igGetColumnIndex() +{ + return ImGui::GetColumnIndex(); +} +CIMGUI_API float igGetColumnWidth(int column_index) +{ + return ImGui::GetColumnWidth(column_index); +} +CIMGUI_API void igSetColumnWidth(int column_index,float width) +{ + return ImGui::SetColumnWidth(column_index,width); +} +CIMGUI_API float igGetColumnOffset(int column_index) +{ + return ImGui::GetColumnOffset(column_index); +} +CIMGUI_API void igSetColumnOffset(int column_index,float offset_x) +{ + return ImGui::SetColumnOffset(column_index,offset_x); +} +CIMGUI_API int igGetColumnsCount() +{ + return ImGui::GetColumnsCount(); +} +CIMGUI_API void igLogToTTY(int max_depth) +{ + return ImGui::LogToTTY(max_depth); +} +CIMGUI_API void igLogToFile(int max_depth,const char* filename) +{ + return ImGui::LogToFile(max_depth,filename); +} +CIMGUI_API void igLogToClipboard(int max_depth) +{ + return ImGui::LogToClipboard(max_depth); +} +CIMGUI_API void igLogFinish() +{ + return ImGui::LogFinish(); +} +CIMGUI_API void igLogButtons() +{ + return ImGui::LogButtons(); +} +CIMGUI_API void igLogText(const char* fmt,...) +{ + return ImGui::LogText(fmt,...); +} +CIMGUI_API bool igBeginDragDropSource(ImGuiDragDropFlags flags) +{ + return ImGui::BeginDragDropSource(flags); +} +CIMGUI_API bool igSetDragDropPayload(const char* type,const void* data,size_t size,ImGuiCond cond) +{ + return ImGui::SetDragDropPayload(type,data,size,cond); +} +CIMGUI_API void igEndDragDropSource() +{ + return ImGui::EndDragDropSource(); +} +CIMGUI_API bool igBeginDragDropTarget() +{ + return ImGui::BeginDragDropTarget(); +} +CIMGUI_API const ImGuiPayload* igAcceptDragDropPayload(const char* type,ImGuiDragDropFlags flags) +{ + return ImGui::AcceptDragDropPayload(type,flags); +} +CIMGUI_API void igEndDragDropTarget() +{ + return ImGui::EndDragDropTarget(); +} +CIMGUI_API void igPushClipRect(const ImVec2 clip_rect_min,const ImVec2 clip_rect_max,bool intersect_with_current_clip_rect) +{ + return ImGui::PushClipRect(clip_rect_min,clip_rect_max,intersect_with_current_clip_rect); +} +CIMGUI_API void igPopClipRect() +{ + return ImGui::PopClipRect(); +} +CIMGUI_API void igSetItemDefaultFocus() +{ + return ImGui::SetItemDefaultFocus(); +} +CIMGUI_API void igSetKeyboardFocusHere(int offset) +{ + return ImGui::SetKeyboardFocusHere(offset); +} +CIMGUI_API bool igIsItemHovered(ImGuiHoveredFlags flags) +{ + return ImGui::IsItemHovered(flags); +} +CIMGUI_API bool igIsItemActive() +{ + return ImGui::IsItemActive(); +} +CIMGUI_API bool igIsItemFocused() +{ + return ImGui::IsItemFocused(); +} +CIMGUI_API bool igIsItemClicked(int mouse_button) +{ + return ImGui::IsItemClicked(mouse_button); +} +CIMGUI_API bool igIsItemVisible() +{ + return ImGui::IsItemVisible(); +} +CIMGUI_API bool igIsAnyItemHovered() +{ + return ImGui::IsAnyItemHovered(); +} +CIMGUI_API bool igIsAnyItemActive() +{ + return ImGui::IsAnyItemActive(); +} +CIMGUI_API bool igIsAnyItemFocused() +{ + return ImGui::IsAnyItemFocused(); +} +CIMGUI_API ImVec2 igGetItemRectMin() +{ + return ImGui::GetItemRectMin(); +} +CIMGUI_API ImVec2 igGetItemRectMax() +{ + return ImGui::GetItemRectMax(); +} +CIMGUI_API ImVec2 igGetItemRectSize() +{ + return ImGui::GetItemRectSize(); +} +CIMGUI_API void igSetItemAllowOverlap() +{ + return ImGui::SetItemAllowOverlap(); +} +CIMGUI_API bool igIsRectVisible(const ImVec2 size) +{ + return ImGui::IsRectVisible(size); +} +CIMGUI_API bool igIsRectVisibleVec2(const ImVec2 rect_min,const ImVec2 rect_max) +{ + return ImGui::IsRectVisible(rect_min,rect_max); +} +CIMGUI_API float igGetTime() +{ + return ImGui::GetTime(); +} +CIMGUI_API int igGetFrameCount() +{ + return ImGui::GetFrameCount(); +} +CIMGUI_API ImDrawList* igGetOverlayDrawList() +{ + return ImGui::GetOverlayDrawList(); +} +CIMGUI_API ImDrawListSharedData* igGetDrawListSharedData() +{ + return ImGui::GetDrawListSharedData(); +} +CIMGUI_API const char* igGetStyleColorName(ImGuiCol idx) +{ + return ImGui::GetStyleColorName(idx); +} +CIMGUI_API void igSetStateStorage(ImGuiStorage* storage) +{ + return ImGui::SetStateStorage(storage); +} +CIMGUI_API ImGuiStorage* igGetStateStorage() +{ + return ImGui::GetStateStorage(); +} +CIMGUI_API ImVec2 igCalcTextSize(const char* text,const char* text_end,bool hide_text_after_double_hash,float wrap_width) +{ + return ImGui::CalcTextSize(text,text_end,hide_text_after_double_hash,wrap_width); +} +CIMGUI_API void igCalcListClipping(int items_count,float items_height,int* out_items_display_start,int* out_items_display_end) +{ + return ImGui::CalcListClipping(items_count,items_height,out_items_display_start,out_items_display_end); +} +CIMGUI_API bool igBeginChildFrame(ImGuiID id,const ImVec2 size,ImGuiWindowFlags flags) +{ + return ImGui::BeginChildFrame(id,size,flags); +} +CIMGUI_API void igEndChildFrame() +{ + return ImGui::EndChildFrame(); +} +CIMGUI_API ImVec4 igColorConvertU32ToFloat4(ImU32 in) +{ + return ImGui::ColorConvertU32ToFloat4(in); +} +CIMGUI_API ImU32 igColorConvertFloat4ToU32(const ImVec4 in) +{ + return ImGui::ColorConvertFloat4ToU32(in); +} +CIMGUI_API void igColorConvertRGBtoHSV(float r,float g,float b,float out_h,float out_s,float out_v) +{ + return ImGui::ColorConvertRGBtoHSV(r,g,b,out_h,out_s,out_v); +} +CIMGUI_API void igColorConvertHSVtoRGB(float h,float s,float v,float out_r,float out_g,float out_b) +{ + return ImGui::ColorConvertHSVtoRGB(h,s,v,out_r,out_g,out_b); +} +CIMGUI_API int igGetKeyIndex(ImGuiKey imgui_key) +{ + return ImGui::GetKeyIndex(imgui_key); +} +CIMGUI_API bool igIsKeyDown(int user_key_index) +{ + return ImGui::IsKeyDown(user_key_index); +} +CIMGUI_API bool igIsKeyPressed(int user_key_index,bool repeat) +{ + return ImGui::IsKeyPressed(user_key_index,repeat); +} +CIMGUI_API bool igIsKeyReleased(int user_key_index) +{ + return ImGui::IsKeyReleased(user_key_index); +} +CIMGUI_API int igGetKeyPressedAmount(int key_index,float repeat_delay,float rate) +{ + return ImGui::GetKeyPressedAmount(key_index,repeat_delay,rate); +} +CIMGUI_API bool igIsMouseDown(int button) +{ + return ImGui::IsMouseDown(button); +} +CIMGUI_API bool igIsAnyMouseDown() +{ + return ImGui::IsAnyMouseDown(); +} +CIMGUI_API bool igIsMouseClicked(int button,bool repeat) +{ + return ImGui::IsMouseClicked(button,repeat); +} +CIMGUI_API bool igIsMouseDoubleClicked(int button) +{ + return ImGui::IsMouseDoubleClicked(button); +} +CIMGUI_API bool igIsMouseReleased(int button) +{ + return ImGui::IsMouseReleased(button); +} +CIMGUI_API bool igIsMouseDragging(int button,float lock_threshold) +{ + return ImGui::IsMouseDragging(button,lock_threshold); +} +CIMGUI_API bool igIsMouseHoveringRect(const ImVec2 r_min,const ImVec2 r_max,bool clip) +{ + return ImGui::IsMouseHoveringRect(r_min,r_max,clip); +} +CIMGUI_API bool igIsMousePosValid(const ImVec2* mouse_pos) +{ + return ImGui::IsMousePosValid(mouse_pos); +} +CIMGUI_API ImVec2 igGetMousePos() +{ + return ImGui::GetMousePos(); +} +CIMGUI_API ImVec2 igGetMousePosOnOpeningCurrentPopup() +{ + return ImGui::GetMousePosOnOpeningCurrentPopup(); +} +CIMGUI_API ImVec2 igGetMouseDragDelta(int button,float lock_threshold) +{ + return ImGui::GetMouseDragDelta(button,lock_threshold); +} +CIMGUI_API void igResetMouseDragDelta(int button) +{ + return ImGui::ResetMouseDragDelta(button); +} +CIMGUI_API ImGuiMouseCursor igGetMouseCursor() +{ + return ImGui::GetMouseCursor(); +} +CIMGUI_API void igSetMouseCursor(ImGuiMouseCursor type) +{ + return ImGui::SetMouseCursor(type); +} +CIMGUI_API void igCaptureKeyboardFromApp(bool capture) +{ + return ImGui::CaptureKeyboardFromApp(capture); +} +CIMGUI_API void igCaptureMouseFromApp(bool capture) +{ + return ImGui::CaptureMouseFromApp(capture); +} +CIMGUI_API const char* igGetClipboardText() +{ + return ImGui::GetClipboardText(); +} +CIMGUI_API void igSetClipboardText(const char* text) +{ + return ImGui::SetClipboardText(text); +} +CIMGUI_API void igSetAllocatorFunctions(void*(*alloc_func)(size_t sz,void* user_data),void(*free_func)(void* ptr,void* user_data),void* user_data) +{ + return ImGui::SetAllocatorFunctions(alloc_func)(sz,user_data)free_func)(ptr,user_data)user_data); +} +CIMGUI_API void* igMemAlloc(size_t size) +{ + return ImGui::MemAlloc(size); +} +CIMGUI_API void igMemFree(void* ptr) +{ + return ImGui::MemFree(ptr); +} +CIMGUI_API void ImGuiStyle_ScaleAllSizes(ImGuiStyle* self,float scale_factor) +{ + return self->ScaleAllSizes(scale_factor); +} +CIMGUI_API void ImGuiIO_AddInputCharacter(ImGuiIO* self,ImWchar c) +{ + return self->AddInputCharacter(c); +} +CIMGUI_API void ImGuiIO_AddInputCharactersUTF8(ImGuiIO* self,const char* utf8_chars) +{ + return self->AddInputCharactersUTF8(utf8_chars); +} +CIMGUI_API inline void ImGuiIO_ClearInputCharacters(ImGuiIO* self,) +{ + return self->ClearInputCharacters(); +} +CIMGUI_API template void _IM_DELETE(* self,T* p) +{ + return self->IM_DELETE(p); +} +CIMGUI_API const char* TextRange_begin(TextRange* self,) +{ + return self->begin(); +} +CIMGUI_API const char* TextRange_end(TextRange* self,) +{ + return self->end(); +} +CIMGUI_API bool TextRange_empty(TextRange* self,) +{ + return self->empty(); +} +CIMGUI_API char TextRange_front(TextRange* self,) +{ + return self->front(); +} +CIMGUI_API static bool TextRange_is_blank(TextRange* self,char c) +{ + return self->is_blank(c); +} +CIMGUI_API void TextRange_trim_blanks(TextRange* self,) +{ + return self->trim_blanks(); +} +CIMGUI_API void TextRange_split(TextRange* self,char separator,ImVector out) +{ + return self->split(separator,out); +} +CIMGUI_API bool ImGuiTextFilter_Draw(ImGuiTextFilter* self,const char* label,float width) +{ + return self->Draw(label,width); +} +CIMGUI_API bool ImGuiTextFilter_PassFilter(ImGuiTextFilter* self,const char* text,const char* text_end) +{ + return self->PassFilter(text,text_end); +} +CIMGUI_API void ImGuiTextFilter_Build(ImGuiTextFilter* self,) +{ + return self->Build(); +} +CIMGUI_API void ImGuiTextFilter_Clear(ImGuiTextFilter* self,) +{ + return self->Clear(); +} +CIMGUI_API bool ImGuiTextFilter_IsActive(ImGuiTextFilter* self,) +{ + return self->IsActive(); +} +CIMGUI_API const char* ImGuiTextBuffer_begin(ImGuiTextBuffer* self,) +{ + return self->begin(); +} +CIMGUI_API const char* ImGuiTextBuffer_end(ImGuiTextBuffer* self,) +{ + return self->end(); +} +CIMGUI_API int ImGuiTextBuffer_size(ImGuiTextBuffer* self,) +{ + return self->size(); +} +CIMGUI_API bool ImGuiTextBuffer_empty(ImGuiTextBuffer* self,) +{ + return self->empty(); +} +CIMGUI_API void ImGuiTextBuffer_clear(ImGuiTextBuffer* self,) +{ + return self->clear(); +} +CIMGUI_API void ImGuiTextBuffer_reserve(ImGuiTextBuffer* self,int capacity) +{ + return self->reserve(capacity); +} +CIMGUI_API const char* ImGuiTextBuffer_c_str(ImGuiTextBuffer* self,) +{ + return self->c_str(); +} +CIMGUI_API void ImGuiTextBuffer_appendf(ImGuiTextBuffer* self,const char* fmt,...) +{ + return self->appendf(fmt,...); +} +CIMGUI_API void ImGuiTextBuffer_appendfv(ImGuiTextBuffer* self,const char* fmt,va_list args) +{ + return self->appendfv(fmt,args); +} +CIMGUI_API void ImGuiStorage_Clear(ImGuiStorage* self,) +{ + return self->Clear(); +} +CIMGUI_API int ImGuiStorage_GetInt(ImGuiStorage* self,ImGuiID key,int default_val) +{ + return self->GetInt(key,default_val); +} +CIMGUI_API void ImGuiStorage_SetInt(ImGuiStorage* self,ImGuiID key,int val) +{ + return self->SetInt(key,val); +} +CIMGUI_API bool ImGuiStorage_GetBool(ImGuiStorage* self,ImGuiID key,bool default_val) +{ + return self->GetBool(key,default_val); +} +CIMGUI_API void ImGuiStorage_SetBool(ImGuiStorage* self,ImGuiID key,bool val) +{ + return self->SetBool(key,val); +} +CIMGUI_API float ImGuiStorage_GetFloat(ImGuiStorage* self,ImGuiID key,float default_val) +{ + return self->GetFloat(key,default_val); +} +CIMGUI_API void ImGuiStorage_SetFloat(ImGuiStorage* self,ImGuiID key,float val) +{ + return self->SetFloat(key,val); +} +CIMGUI_API void* ImGuiStorage_GetVoidPtr(ImGuiStorage* self,ImGuiID key) +{ + return self->GetVoidPtr(key); +} +CIMGUI_API void ImGuiStorage_SetVoidPtr(ImGuiStorage* self,ImGuiID key,void* val) +{ + return self->SetVoidPtr(key,val); +} +CIMGUI_API int* ImGuiStorage_GetIntRef(ImGuiStorage* self,ImGuiID key,int default_val) +{ + return self->GetIntRef(key,default_val); +} +CIMGUI_API bool* ImGuiStorage_GetBoolRef(ImGuiStorage* self,ImGuiID key,bool default_val) +{ + return self->GetBoolRef(key,default_val); +} +CIMGUI_API float* ImGuiStorage_GetFloatRef(ImGuiStorage* self,ImGuiID key,float default_val) +{ + return self->GetFloatRef(key,default_val); +} +CIMGUI_API void** ImGuiStorage_GetVoidPtrRef(ImGuiStorage* self,ImGuiID key,void* default_val) +{ + return self->GetVoidPtrRef(key,default_val); +} +CIMGUI_API void ImGuiStorage_SetAllInt(ImGuiStorage* self,int val) +{ + return self->SetAllInt(val); +} +CIMGUI_API void ImGuiStorage_BuildSortByKey(ImGuiStorage* self,) +{ + return self->BuildSortByKey(); +} +CIMGUI_API void ImGuiTextEditCallbackData_DeleteChars(ImGuiTextEditCallbackData* self,int pos,int bytes_count) +{ + return self->DeleteChars(pos,bytes_count); +} +CIMGUI_API void ImGuiTextEditCallbackData_InsertChars(ImGuiTextEditCallbackData* self,int pos,const char* text,const char* text_end) +{ + return self->InsertChars(pos,text,text_end); +} +CIMGUI_API bool ImGuiTextEditCallbackData_HasSelection(ImGuiTextEditCallbackData* self,) +{ + return self->HasSelection(); +} +CIMGUI_API void ImGuiPayload_Clear(ImGuiPayload* self,) +{ + return self->Clear(); +} +CIMGUI_API bool ImGuiPayload_IsDataType(ImGuiPayload* self,const char* type) +{ + return self->IsDataType(type); +} +CIMGUI_API bool ImGuiPayload_IsPreview(ImGuiPayload* self,) +{ + return self->IsPreview(); +} +CIMGUI_API bool ImGuiPayload_IsDelivery(ImGuiPayload* self,) +{ + return self->IsDelivery(); +} +CIMGUI_API inline void ImColor_SetHSV(ImColor* self,float h,float s,float v,float a) +{ + return self->SetHSV(h,s,v,a); +} +CIMGUI_API static ImColor ImColor_HSV(ImColor* self,float h,float s,float v,float a) +{ + return self->HSV(h,s,v,a); +} +CIMGUI_API bool ImGuiListClipper_Step(ImGuiListClipper* self,) +{ + return self->Step(); +} +CIMGUI_API void ImGuiListClipper_Begin(ImGuiListClipper* self,int items_count,float items_height) +{ + return self->Begin(items_count,items_height); +} +CIMGUI_API void ImGuiListClipper_End(ImGuiListClipper* self,) +{ + return self->End(); +} +CIMGUI_API void ImDrawList_PushClipRect(ImDrawList* self,ImVec2 clip_rect_min,ImVec2 clip_rect_max,bool intersect_with_current_clip_rect) +{ + return self->PushClipRect(clip_rect_min,clip_rect_max,intersect_with_current_clip_rect); +} +CIMGUI_API void ImDrawList_PushClipRectFullScreen(ImDrawList* self,) +{ + return self->PushClipRectFullScreen(); +} +CIMGUI_API void ImDrawList_PopClipRect(ImDrawList* self,) +{ + return self->PopClipRect(); +} +CIMGUI_API void ImDrawList_PushTextureID(ImDrawList* self,ImTextureID texture_id) +{ + return self->PushTextureID(texture_id); +} +CIMGUI_API void ImDrawList_PopTextureID(ImDrawList* self,) +{ + return self->PopTextureID(); +} +CIMGUI_API inline ImVec2 ImDrawList_GetClipRectMin(ImDrawList* self,) +{ + return self->GetClipRectMin(); +} +CIMGUI_API inline ImVec2 ImDrawList_GetClipRectMax(ImDrawList* self,) +{ + return self->GetClipRectMax(); +} +CIMGUI_API void ImDrawList_AddLine(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col,float thickness) +{ + return self->AddLine(a,b,col,thickness); +} +CIMGUI_API void ImDrawList_AddRect(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col,float rounding,int rounding_corners_flags,float thickness) +{ + return self->AddRect(a,b,col,rounding,rounding_corners_flags,thickness); +} +CIMGUI_API void ImDrawList_AddRectFilled(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col,float rounding,int rounding_corners_flags) +{ + return self->AddRectFilled(a,b,col,rounding,rounding_corners_flags); +} +CIMGUI_API void ImDrawList_AddRectFilledMultiColor(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col_upr_left,ImU32 col_upr_right,ImU32 col_bot_right,ImU32 col_bot_left) +{ + return self->AddRectFilledMultiColor(a,b,col_upr_left,col_upr_right,col_bot_right,col_bot_left); +} +CIMGUI_API void ImDrawList_AddQuad(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,const ImVec2 d,ImU32 col,float thickness) +{ + return self->AddQuad(a,b,c,d,col,thickness); +} +CIMGUI_API void ImDrawList_AddQuadFilled(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,const ImVec2 d,ImU32 col) +{ + return self->AddQuadFilled(a,b,c,d,col); +} +CIMGUI_API void ImDrawList_AddTriangle(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,ImU32 col,float thickness) +{ + return self->AddTriangle(a,b,c,col,thickness); +} +CIMGUI_API void ImDrawList_AddTriangleFilled(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,ImU32 col) +{ + return self->AddTriangleFilled(a,b,c,col); +} +CIMGUI_API void ImDrawList_AddCircle(ImDrawList* self,const ImVec2 centre,float radius,ImU32 col,int num_segments,float thickness) +{ + return self->AddCircle(centre,radius,col,num_segments,thickness); +} +CIMGUI_API void ImDrawList_AddCircleFilled(ImDrawList* self,const ImVec2 centre,float radius,ImU32 col,int num_segments) +{ + return self->AddCircleFilled(centre,radius,col,num_segments); +} +CIMGUI_API void ImDrawList_AddTextVec2(ImDrawList* self,const ImVec2 pos,ImU32 col,const char* text_begin,const char* text_end) +{ + return self->AddText(pos,col,text_begin,text_end); +} +CIMGUI_API void ImDrawList_AddTextFontPtr(ImDrawList* self,const ImFont* font,float font_size,const ImVec2 pos,ImU32 col,const char* text_begin,const char* text_end,float wrap_width,const ImVec4* cpu_fine_clip_rect) +{ + return self->AddText(font,font_size,pos,col,text_begin,text_end,wrap_width,cpu_fine_clip_rect); +} +CIMGUI_API void ImDrawList_AddImage(ImDrawList* self,ImTextureID user_texture_id,const ImVec2 a,const ImVec2 b,const ImVec2 uv_a,const ImVec2 uv_b,ImU32 col) +{ + return self->AddImage(user_texture_id,a,b,uv_a,uv_b,col); +} +CIMGUI_API void ImDrawList_AddImageQuad(ImDrawList* self,ImTextureID user_texture_id,const ImVec2 a,const ImVec2 b,const ImVec2 c,const ImVec2 d,const ImVec2 uv_a,const ImVec2 uv_b,const ImVec2 uv_c,const ImVec2 uv_d,ImU32 col) +{ + return self->AddImageQuad(user_texture_id,a,b,c,d,uv_a,uv_b,uv_c,uv_d,col); +} +CIMGUI_API void ImDrawList_AddImageRounded(ImDrawList* self,ImTextureID user_texture_id,const ImVec2 a,const ImVec2 b,const ImVec2 uv_a,const ImVec2 uv_b,ImU32 col,float rounding,int rounding_corners) +{ + return self->AddImageRounded(user_texture_id,a,b,uv_a,uv_b,col,rounding,rounding_corners); +} +CIMGUI_API void ImDrawList_AddPolyline(ImDrawList* self,const ImVec2* points,const int num_points,ImU32 col,bool closed,float thickness) +{ + return self->AddPolyline(points,num_points,col,closed,thickness); +} +CIMGUI_API void ImDrawList_AddConvexPolyFilled(ImDrawList* self,const ImVec2* points,const int num_points,ImU32 col) +{ + return self->AddConvexPolyFilled(points,num_points,col); +} +CIMGUI_API void ImDrawList_AddBezierCurve(ImDrawList* self,const ImVec2 pos0,const ImVec2 cp0,const ImVec2 cp1,const ImVec2 pos1,ImU32 col,float thickness,int num_segments) +{ + return self->AddBezierCurve(pos0,cp0,cp1,pos1,col,thickness,num_segments); +} +CIMGUI_API inline void ImDrawList_PathClear(ImDrawList* self,) +{ + return self->PathClear(); +} +CIMGUI_API inline void ImDrawList_PathLineTo(ImDrawList* self,const ImVec2 pos) +{ + return self->PathLineTo(pos); +} +CIMGUI_API inline void ImDrawList_PathLineToMergeDuplicate(ImDrawList* self,const ImVec2 pos) +{ + return self->PathLineToMergeDuplicate(pos); +} +CIMGUI_API inline void ImDrawList_PathFillConvex(ImDrawList* self,ImU32 col) +{ + return self->PathFillConvex(col); +} +CIMGUI_API inline void ImDrawList_PathStroke(ImDrawList* self,ImU32 col,bool closed,float thickness) +{ + return self->PathStroke(col,closed,thickness); +} +CIMGUI_API void ImDrawList_PathArcTo(ImDrawList* self,const ImVec2 centre,float radius,float a_min,float a_max,int num_segments) +{ + return self->PathArcTo(centre,radius,a_min,a_max,num_segments); +} +CIMGUI_API void ImDrawList_PathArcToFast(ImDrawList* self,const ImVec2 centre,float radius,int a_min_of_12,int a_max_of_12) +{ + return self->PathArcToFast(centre,radius,a_min_of_12,a_max_of_12); +} +CIMGUI_API void ImDrawList_PathBezierCurveTo(ImDrawList* self,const ImVec2 p1,const ImVec2 p2,const ImVec2 p3,int num_segments) +{ + return self->PathBezierCurveTo(p1,p2,p3,num_segments); +} +CIMGUI_API void ImDrawList_PathRect(ImDrawList* self,const ImVec2 rect_min,const ImVec2 rect_max,float rounding,int rounding_corners_flags) +{ + return self->PathRect(rect_min,rect_max,rounding,rounding_corners_flags); +} +CIMGUI_API void ImDrawList_ChannelsSplit(ImDrawList* self,int channels_count) +{ + return self->ChannelsSplit(channels_count); +} +CIMGUI_API void ImDrawList_ChannelsMerge(ImDrawList* self,) +{ + return self->ChannelsMerge(); +} +CIMGUI_API void ImDrawList_ChannelsSetCurrent(ImDrawList* self,int channel_index) +{ + return self->ChannelsSetCurrent(channel_index); +} +CIMGUI_API void ImDrawList_AddCallback(ImDrawList* self,ImDrawCallback callback,void* callback_data) +{ + return self->AddCallback(callback,callback_data); +} +CIMGUI_API void ImDrawList_AddDrawCmd(ImDrawList* self,) +{ + return self->AddDrawCmd(); +} +CIMGUI_API ImDrawList* ImDrawList_CloneOutput(ImDrawList* self,) +{ + return self->CloneOutput(); +} +CIMGUI_API void ImDrawList_Clear(ImDrawList* self,) +{ + return self->Clear(); +} +CIMGUI_API void ImDrawList_ClearFreeMemory(ImDrawList* self,) +{ + return self->ClearFreeMemory(); +} +CIMGUI_API void ImDrawList_PrimReserve(ImDrawList* self,int idx_count,int vtx_count) +{ + return self->PrimReserve(idx_count,vtx_count); +} +CIMGUI_API void ImDrawList_PrimRect(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col) +{ + return self->PrimRect(a,b,col); +} +CIMGUI_API void ImDrawList_PrimRectUV(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 uv_a,const ImVec2 uv_b,ImU32 col) +{ + return self->PrimRectUV(a,b,uv_a,uv_b,col); +} +CIMGUI_API void ImDrawList_PrimQuadUV(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,const ImVec2 d,const ImVec2 uv_a,const ImVec2 uv_b,const ImVec2 uv_c,const ImVec2 uv_d,ImU32 col) +{ + return self->PrimQuadUV(a,b,c,d,uv_a,uv_b,uv_c,uv_d,col); +} +CIMGUI_API inline void ImDrawList_PrimWriteVtx(ImDrawList* self,const ImVec2 pos,const ImVec2 uv,ImU32 col) +{ + return self->PrimWriteVtx(pos,uv,col); +} +CIMGUI_API inline void ImDrawList_PrimWriteIdx(ImDrawList* self,ImDrawIdx idx) +{ + return self->PrimWriteIdx(idx); +} +CIMGUI_API inline void ImDrawList_PrimVtx(ImDrawList* self,const ImVec2 pos,const ImVec2 uv,ImU32 col) +{ + return self->PrimVtx(pos,uv,col); +} +CIMGUI_API void ImDrawList_UpdateClipRect(ImDrawList* self,) +{ + return self->UpdateClipRect(); +} +CIMGUI_API void ImDrawList_UpdateTextureID(ImDrawList* self,) +{ + return self->UpdateTextureID(); +} +CIMGUI_API void ImDrawData_Clear(ImDrawData* self,) +{ + return self->Clear(); +} +CIMGUI_API void ImDrawData_DeIndexAllBuffers(ImDrawData* self,) +{ + return self->DeIndexAllBuffers(); +} +CIMGUI_API void ImDrawData_ScaleClipRects(ImDrawData* self,const ImVec2 sc) +{ + return self->ScaleClipRects(sc); +} +CIMGUI_API ImFont* ImFontAtlas_AddFont(ImFontAtlas* self,const ImFontConfig* font_cfg) +{ + return self->AddFont(font_cfg); +} +CIMGUI_API ImFont* ImFontAtlas_AddFontDefault(ImFontAtlas* self,const ImFontConfig* font_cfg) +{ + return self->AddFontDefault(font_cfg); +} +CIMGUI_API ImFont* ImFontAtlas_AddFontFromFileTTF(ImFontAtlas* self,const char* filename,float size_pixels,const ImFontConfig* font_cfg,const ImWchar* glyph_ranges) +{ + return self->AddFontFromFileTTF(filename,size_pixels,font_cfg,glyph_ranges); +} +CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryTTF(ImFontAtlas* self,void* font_data,int font_size,float size_pixels,const ImFontConfig* font_cfg,const ImWchar* glyph_ranges) +{ + return self->AddFontFromMemoryTTF(font_data,font_size,size_pixels,font_cfg,glyph_ranges); +} +CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryCompressedTTF(ImFontAtlas* self,const void* compressed_font_data,int compressed_font_size,float size_pixels,const ImFontConfig* font_cfg,const ImWchar* glyph_ranges) +{ + return self->AddFontFromMemoryCompressedTTF(compressed_font_data,compressed_font_size,size_pixels,font_cfg,glyph_ranges); +} +CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryCompressedBase85TTF(ImFontAtlas* self,const char* compressed_font_data_base85,float size_pixels,const ImFontConfig* font_cfg,const ImWchar* glyph_ranges) +{ + return self->AddFontFromMemoryCompressedBase85TTF(compressed_font_data_base85,size_pixels,font_cfg,glyph_ranges); +} +CIMGUI_API void ImFontAtlas_ClearInputData(ImFontAtlas* self,) +{ + return self->ClearInputData(); +} +CIMGUI_API void ImFontAtlas_ClearTexData(ImFontAtlas* self,) +{ + return self->ClearTexData(); +} +CIMGUI_API void ImFontAtlas_ClearFonts(ImFontAtlas* self,) +{ + return self->ClearFonts(); +} +CIMGUI_API void ImFontAtlas_Clear(ImFontAtlas* self,) +{ + return self->Clear(); +} +CIMGUI_API bool ImFontAtlas_Build(ImFontAtlas* self,) +{ + return self->Build(); +} +CIMGUI_API void ImFontAtlas_GetTexDataAsAlpha8(ImFontAtlas* self,unsigned char** out_pixels,int* out_width,int* out_height,int* out_bytes_per_pixel) +{ + return self->GetTexDataAsAlpha8(out_pixels,out_width,out_height,out_bytes_per_pixel); +} +CIMGUI_API void ImFontAtlas_GetTexDataAsRGBA32(ImFontAtlas* self,unsigned char** out_pixels,int* out_width,int* out_height,int* out_bytes_per_pixel) +{ + return self->GetTexDataAsRGBA32(out_pixels,out_width,out_height,out_bytes_per_pixel); +} +CIMGUI_API void ImFontAtlas_SetTexID(ImFontAtlas* self,ImTextureID id) +{ + return self->SetTexID(id); +} +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesDefault(ImFontAtlas* self,) +{ + return self->GetGlyphRangesDefault(); +} +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesKorean(ImFontAtlas* self,) +{ + return self->GetGlyphRangesKorean(); +} +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesJapanese(ImFontAtlas* self,) +{ + return self->GetGlyphRangesJapanese(); +} +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesChinese(ImFontAtlas* self,) +{ + return self->GetGlyphRangesChinese(); +} +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesCyrillic(ImFontAtlas* self,) +{ + return self->GetGlyphRangesCyrillic(); +} +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesThai(ImFontAtlas* self,) +{ + return self->GetGlyphRangesThai(); +} +CIMGUI_API bool GlyphRangesBuilder_GetBit(GlyphRangesBuilder* self,int n) +{ + return self->GetBit(n); +} +CIMGUI_API void GlyphRangesBuilder_SetBit(GlyphRangesBuilder* self,int n) +{ + return self->SetBit(n); +} +CIMGUI_API void GlyphRangesBuilder_AddChar(GlyphRangesBuilder* self,ImWchar c) +{ + return self->AddChar(c); +} +CIMGUI_API void GlyphRangesBuilder_AddText(GlyphRangesBuilder* self,const char* text,const char* text_end) +{ + return self->AddText(text,text_end); +} +CIMGUI_API void GlyphRangesBuilder_AddRanges(GlyphRangesBuilder* self,const ImWchar* ranges) +{ + return self->AddRanges(ranges); +} +CIMGUI_API void GlyphRangesBuilder_BuildRanges(GlyphRangesBuilder* self,ImVector* out_ranges) +{ + return self->BuildRanges(out_ranges); +} +CIMGUI_API bool CustomRect_IsPacked(CustomRect* self,) +{ + return self->IsPacked(); +} +CIMGUI_API int ImFontAtlas_AddCustomRectRegular(ImFontAtlas* self,unsigned int id,int width,int height) +{ + return self->AddCustomRectRegular(id,width,height); +} +CIMGUI_API int ImFontAtlas_AddCustomRectFontGlyph(ImFontAtlas* self,ImFont* font,ImWchar id,int width,int height,float advance_x,const ImVec2 offset) +{ + return self->AddCustomRectFontGlyph(font,id,width,height,advance_x,offset); +} +CIMGUI_API const CustomRect* ImFontAtlas_GetCustomRectByIndex(ImFontAtlas* self,int index) +{ + return self->GetCustomRectByIndex(index); +} +CIMGUI_API void ImFontAtlas_CalcCustomRectUV(ImFontAtlas* self,const CustomRect* rect,ImVec2* out_uv_min,ImVec2* out_uv_max) +{ + return self->CalcCustomRectUV(rect,out_uv_min,out_uv_max); +} +CIMGUI_API bool ImFontAtlas_GetMouseCursorTexData(ImFontAtlas* self,ImGuiMouseCursor cursor,ImVec2* out_offset,ImVec2* out_size,ImVec2 out_uv_border[2],ImVec2 out_uv_fill[2]) +{ + return self->GetMouseCursorTexData(cursor,out_offset,out_size,ImVec2 out_uv_border[2],ImVec2 out_uv_fill[2]); +} +CIMGUI_API void ImFont_ClearOutputData(ImFont* self,) +{ + return self->ClearOutputData(); +} +CIMGUI_API void ImFont_BuildLookupTable(ImFont* self,) +{ + return self->BuildLookupTable(); +} +CIMGUI_API const ImFontGlyph ImFont_FindGlyph(ImFont* self,ImWchar c) +{ + return self->FindGlyph(c); +} +CIMGUI_API const ImFontGlyph ImFont_FindGlyphNoFallback(ImFont* self,ImWchar c) +{ + return self->FindGlyphNoFallback(c); +} +CIMGUI_API void ImFont_SetFallbackChar(ImFont* self,ImWchar c) +{ + return self->SetFallbackChar(c); +} +CIMGUI_API float ImFont_GetCharAdvance(ImFont* self,ImWchar c) +{ + return self->GetCharAdvance(c); +} +CIMGUI_API bool ImFont_IsLoaded(ImFont* self,) +{ + return self->IsLoaded(); +} +CIMGUI_API const char* ImFont_GetDebugName(ImFont* self,) +{ + return self->GetDebugName(); +} +CIMGUI_API ImVec2 ImFont_CalcTextSizeA(ImFont* self,float size,float max_width,float wrap_width,const char* text_begin,const char* text_end,const char** remaining) +{ + return self->CalcTextSizeA(size,max_width,wrap_width,text_begin,text_end,remaining); +} +CIMGUI_API const char* ImFont_CalcWordWrapPositionA(ImFont* self,float scale,const char* text,const char* text_end,float wrap_width) +{ + return self->CalcWordWrapPositionA(scale,text,text_end,wrap_width); +} +CIMGUI_API void ImFont_RenderChar(ImFont* self,ImDrawList* draw_list,float size,ImVec2 pos,ImU32 col,unsigned short c) +{ + return self->RenderChar(draw_list,size,pos,col,c); +} +CIMGUI_API void ImFont_RenderText(ImFont* self,ImDrawList* draw_list,float size,ImVec2 pos,ImU32 col,const ImVec4 clip_rect,const char* text_begin,const char* text_end,float wrap_width,bool cpu_fine_clip) +{ + return self->RenderText(draw_list,size,pos,col,clip_rect,text_begin,text_end,wrap_width,cpu_fine_clip); +} +CIMGUI_API void ImFont_GrowIndex(ImFont* self,int new_size) +{ + return self->GrowIndex(new_size); +} +CIMGUI_API void ImFont_AddGlyph(ImFont* self,ImWchar c,float x0,float y0,float x1,float y1,float u0,float v0,float u1,float v1,float advance_x) +{ + return self->AddGlyph(c,x0,y0,x1,y1,u0,v0,u1,v1,advance_x); +} +CIMGUI_API void ImFont_AddRemapChar(ImFont* self,ImWchar dst,ImWchar src,bool overwrite_dst) +{ + return self->AddRemapChar(dst,src,overwrite_dst); +} diff --git a/cimgui/auto_funcs.h b/cimgui/auto_funcs.h new file mode 100644 index 0000000..d207fdf --- /dev/null +++ b/cimgui/auto_funcs.h @@ -0,0 +1,475 @@ +CIMGUI_API ImGuiContext* igCreateContext(ImFontAtlas* shared_font_atlas); +CIMGUI_API void igDestroyContext(ImGuiContext* ctx); +CIMGUI_API ImGuiContext* igGetCurrentContext(); +CIMGUI_API void igSetCurrentContext(ImGuiContext* ctx); +CIMGUI_API ImGuiIO* igGetIO(); +CIMGUI_API ImGuiStyle* igGetStyle(); +CIMGUI_API void igNewFrame(); +CIMGUI_API void igRender(); +CIMGUI_API ImDrawData* igGetDrawData(); +CIMGUI_API void igEndFrame(); +CIMGUI_API void igShowDemoWindow(bool* p_open); +CIMGUI_API void igShowMetricsWindow(bool* p_open); +CIMGUI_API void igShowStyleEditor(ImGuiStyle* ref); +CIMGUI_API bool igShowStyleSelector(const char* label); +CIMGUI_API void igShowFontSelector(const char* label); +CIMGUI_API void igShowUserGuide(); +CIMGUI_API const char* igGetVersion(); +CIMGUI_API void igStyleColorsDark(ImGuiStyle* dst); +CIMGUI_API void igStyleColorsClassic(ImGuiStyle* dst); +CIMGUI_API void igStyleColorsLight(ImGuiStyle* dst); +CIMGUI_API bool igBegin(const char* name,bool* p_open,ImGuiWindowFlags flags); +CIMGUI_API void igEnd(); +CIMGUI_API bool igBeginChildStr(const char* str_id,const ImVec2 size,bool border,ImGuiWindowFlags flags); +CIMGUI_API bool igBeginChildID(ImGuiID id,const ImVec2 size,bool border,ImGuiWindowFlags flags); +CIMGUI_API void igEndChild(); +CIMGUI_API bool igIsWindowAppearing(); +CIMGUI_API bool igIsWindowCollapsed(); +CIMGUI_API bool igIsWindowFocused(ImGuiFocusedFlags flags); +CIMGUI_API bool igIsWindowHovered(ImGuiHoveredFlags flags); +CIMGUI_API ImDrawList* igGetWindowDrawList(); +CIMGUI_API ImVec2 igGetWindowPos(); +CIMGUI_API ImVec2 igGetWindowSize(); +CIMGUI_API float igGetWindowWidth(); +CIMGUI_API float igGetWindowHeight(); +CIMGUI_API ImVec2 igGetContentRegionMax(); +CIMGUI_API ImVec2 igGetContentRegionAvail(); +CIMGUI_API float igGetContentRegionAvailWidth(); +CIMGUI_API ImVec2 igGetWindowContentRegionMin(); +CIMGUI_API ImVec2 igGetWindowContentRegionMax(); +CIMGUI_API float igGetWindowContentRegionWidth(); +CIMGUI_API void igSetNextWindowPos(const ImVec2 pos,ImGuiCond cond,const ImVec2 pivot); +CIMGUI_API void igSetNextWindowSize(const ImVec2 size,ImGuiCond cond); +CIMGUI_API void igSetNextWindowSizeConstraints(const ImVec2 size_min,const ImVec2 size_max,ImGuiSizeCallback custom_callback,void* custom_callback_data); +CIMGUI_API void igSetNextWindowContentSize(const ImVec2 size); +CIMGUI_API void igSetNextWindowCollapsed(bool collapsed,ImGuiCond cond); +CIMGUI_API void igSetNextWindowFocus(); +CIMGUI_API void igSetNextWindowBgAlpha(float alpha); +CIMGUI_API void igSetWindowPosVec2(const ImVec2 pos,ImGuiCond cond); +CIMGUI_API void igSetWindowSizeVec2(const ImVec2 size,ImGuiCond cond); +CIMGUI_API void igSetWindowCollapsedBool(bool collapsed,ImGuiCond cond); +CIMGUI_API void igSetWindowFocus(); +CIMGUI_API void igSetWindowFontScale(float scale); +CIMGUI_API void igSetWindowPosStr(const char* name,const ImVec2 pos,ImGuiCond cond); +CIMGUI_API void igSetWindowSizeStr(const char* name,const ImVec2 size,ImGuiCond cond); +CIMGUI_API void igSetWindowCollapsedStr(const char* name,bool collapsed,ImGuiCond cond); +CIMGUI_API void igSetWindowFocusStr(const char* name); +CIMGUI_API float igGetScrollX(); +CIMGUI_API float igGetScrollY(); +CIMGUI_API float igGetScrollMaxX(); +CIMGUI_API float igGetScrollMaxY(); +CIMGUI_API void igSetScrollX(float scroll_x); +CIMGUI_API void igSetScrollY(float scroll_y); +CIMGUI_API void igSetScrollHere(float center_y_ratio); +CIMGUI_API void igSetScrollFromPosY(float pos_y,float center_y_ratio); +CIMGUI_API void igPushFont(ImFont* font); +CIMGUI_API void igPopFont(); +CIMGUI_API void igPushStyleColorU32(ImGuiCol idx,ImU32 col); +CIMGUI_API void igPushStyleColorVec4(ImGuiCol idx,const ImVec4 col); +CIMGUI_API void igPopStyleColor(int count); +CIMGUI_API void igPushStyleVarFloat(ImGuiStyleVar idx,float val); +CIMGUI_API void igPushStyleVarVec2(ImGuiStyleVar idx,const ImVec2 val); +CIMGUI_API void igPopStyleVar(int count); +CIMGUI_API const ImVec4* igGetStyleColorVec4(ImGuiCol idx); +CIMGUI_API ImFont* igGetFont(); +CIMGUI_API float igGetFontSize(); +CIMGUI_API ImVec2 igGetFontTexUvWhitePixel(); +CIMGUI_API ImU32 igGetColorU32Col(ImGuiCol idx,float alpha_mul); +CIMGUI_API ImU32 igGetColorU32Vec4(const ImVec4 col); +CIMGUI_API ImU32 igGetColorU32U32(ImU32 col); +CIMGUI_API void igPushItemWidth(float item_width); +CIMGUI_API void igPopItemWidth(); +CIMGUI_API float igCalcItemWidth(); +CIMGUI_API void igPushTextWrapPos(float wrap_pos_x); +CIMGUI_API void igPopTextWrapPos(); +CIMGUI_API void igPushAllowKeyboardFocus(bool allow_keyboard_focus); +CIMGUI_API void igPopAllowKeyboardFocus(); +CIMGUI_API void igPushButtonRepeat(bool repeat); +CIMGUI_API void igPopButtonRepeat(); +CIMGUI_API void igSeparator(); +CIMGUI_API void igSameLine(float pos_x,float spacing_w); +CIMGUI_API void igNewLine(); +CIMGUI_API void igSpacing(); +CIMGUI_API void igDummy(const ImVec2 size); +CIMGUI_API void igIndent(float indent_w); +CIMGUI_API void igUnindent(float indent_w); +CIMGUI_API void igBeginGroup(); +CIMGUI_API void igEndGroup(); +CIMGUI_API ImVec2 igGetCursorPos(); +CIMGUI_API float igGetCursorPosX(); +CIMGUI_API float igGetCursorPosY(); +CIMGUI_API void igSetCursorPos(const ImVec2 local_pos); +CIMGUI_API void igSetCursorPosX(float x); +CIMGUI_API void igSetCursorPosY(float y); +CIMGUI_API ImVec2 igGetCursorStartPos(); +CIMGUI_API ImVec2 igGetCursorScreenPos(); +CIMGUI_API void igSetCursorScreenPos(const ImVec2 screen_pos); +CIMGUI_API void igAlignTextToFramePadding(); +CIMGUI_API float igGetTextLineHeight(); +CIMGUI_API float igGetTextLineHeightWithSpacing(); +CIMGUI_API float igGetFrameHeight(); +CIMGUI_API float igGetFrameHeightWithSpacing(); +CIMGUI_API void igPushIDStr(const char* str_id); +CIMGUI_API void igPushIDRange(const char* str_id_begin,const char* str_id_end); +CIMGUI_API void igPushIDPtr(const void* ptr_id); +CIMGUI_API void igPushIDInt(int int_id); +CIMGUI_API void igPopID(); +CIMGUI_API ImGuiID igGetIDStr(const char* str_id); +CIMGUI_API ImGuiID igGetIDStrStr(const char* str_id_begin,const char* str_id_end); +CIMGUI_API ImGuiID igGetIDPtr(const void* ptr_id); +CIMGUI_API void igTextUnformatted(const char* text,const char* text_end); +CIMGUI_API void igText(const char* fmt,...); +CIMGUI_API void igTextV(const char* fmt,va_list args); +CIMGUI_API void igTextColored(const ImVec4 col,const char* fmt,...); +CIMGUI_API void igTextColoredV(const ImVec4 col,const char* fmt,va_list args); +CIMGUI_API void igTextDisabled(const char* fmt,...); +CIMGUI_API void igTextDisabledV(const char* fmt,va_list args); +CIMGUI_API void igTextWrapped(const char* fmt,...); +CIMGUI_API void igTextWrappedV(const char* fmt,va_list args); +CIMGUI_API void igLabelText(const char* label,const char* fmt,...); +CIMGUI_API void igLabelTextV(const char* label,const char* fmt,va_list args); +CIMGUI_API void igBulletText(const char* fmt,...); +CIMGUI_API void igBulletTextV(const char* fmt,va_list args); +CIMGUI_API bool igButton(const char* label,const ImVec2 size); +CIMGUI_API bool igSmallButton(const char* label); +CIMGUI_API bool igArrowButton(const char* str_id,ImGuiDir dir); +CIMGUI_API bool igInvisibleButton(const char* str_id,const ImVec2 size); +CIMGUI_API void igImage(ImTextureID user_texture_id,const ImVec2 size,const ImVec2 uv0,const ImVec2 uv1,const ImVec4 tint_col,const ImVec4 border_col); +CIMGUI_API bool igImageButton(ImTextureID user_texture_id,const ImVec2 size,const ImVec2 uv0,const ImVec2 uv1,int frame_padding,const ImVec4 bg_col,const ImVec4 tint_col); +CIMGUI_API bool igCheckbox(const char* label,bool* v); +CIMGUI_API bool igCheckboxFlags(const char* label,unsigned int* flags,unsigned int flags_value); +CIMGUI_API bool igRadioButtonBool(const char* label,bool active); +CIMGUI_API bool igRadioButtonIntPtr(const char* label,int* v,int v_button); +CIMGUI_API void igPlotLinesFloatPtr(const char* label,const float* values,int values_count,int values_offset,const char* overlay_text,float scale_min,float scale_max,ImVec2 graph_size,int stride); +CIMGUI_API void igPlotLinesvalues_getter(const char* label,float(*values_getter)(void* data,int idx),void* data,int values_count,int values_offset,const char* overlay_text,float scale_min,float scale_max,ImVec2 graph_size); +CIMGUI_API void igPlotHistogramFloatPtr(const char* label,const float* values,int values_count,int values_offset,const char* overlay_text,float scale_min,float scale_max,ImVec2 graph_size,int stride); +CIMGUI_API void igPlotHistogramvalues_getter(const char* label,float(*values_getter)(void* data,int idx),void* data,int values_count,int values_offset,const char* overlay_text,float scale_min,float scale_max,ImVec2 graph_size); +CIMGUI_API void igProgressBar(float fraction,const ImVec2 size_arg,const char* overlay); +CIMGUI_API void igBullet(); +CIMGUI_API bool igBeginCombo(const char* label,const char* preview_value,ImGuiComboFlags flags); +CIMGUI_API void igEndCombo(); +CIMGUI_API bool igComboStr_arr(const char* label,int* current_item,const char* const items[],int items_count,int popup_max_height_in_items); +CIMGUI_API bool igComboStr(const char* label,int* current_item,const char* items_separated_by_zeros,int popup_max_height_in_items); +CIMGUI_API bool igComboitems_getter(const char* label,int* current_item,bool(*items_getter)(void* data,int idx,const char** out_text),void* data,int items_count,int popup_max_height_in_items); +CIMGUI_API bool igDragFloat(const char* label,float* v,float v_speed,float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igDragFloat2(const char* label,float v[2],float v_speed,float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igDragFloat3(const char* label,float v[3],float v_speed,float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igDragFloat4(const char* label,float v[4],float v_speed,float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igDragFloatRange2(const char* label,float* v_current_min,float* v_current_max,float v_speed,float v_min,float v_max,const char* display_format,const char* display_format_max,float power); +CIMGUI_API bool igDragInt(const char* label,int* v,float v_speed,int v_min,int v_max,const char* display_format); +CIMGUI_API bool igDragInt2(const char* label,int v[2],float v_speed,int v_min,int v_max,const char* display_format); +CIMGUI_API bool igDragInt3(const char* label,int v[3],float v_speed,int v_min,int v_max,const char* display_format); +CIMGUI_API bool igDragInt4(const char* label,int v[4],float v_speed,int v_min,int v_max,const char* display_format); +CIMGUI_API bool igDragIntRange2(const char* label,int* v_current_min,int* v_current_max,float v_speed,int v_min,int v_max,const char* display_format,const char* display_format_max); +CIMGUI_API bool igInputText(const char* label,char* buf,size_t buf_size,ImGuiInputTextFlags flags,ImGuiTextEditCallback callback,void* user_data); +CIMGUI_API bool igInputTextMultiline(const char* label,char* buf,size_t buf_size,const ImVec2 size,ImGuiInputTextFlags flags,ImGuiTextEditCallback callback,void* user_data); +CIMGUI_API bool igInputFloat(const char* label,float* v,float step,float step_fast,int decimal_precision,ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igInputFloat2(const char* label,float v[2],int decimal_precision,ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igInputFloat3(const char* label,float v[3],int decimal_precision,ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igInputFloat4(const char* label,float v[4],int decimal_precision,ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igInputInt(const char* label,int* v,int step,int step_fast,ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igInputInt2(const char* label,int v[2],ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igInputInt3(const char* label,int v[3],ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igInputInt4(const char* label,int v[4],ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igInputDouble(const char* label,double* v,double step,double step_fast,const char* display_format,ImGuiInputTextFlags extra_flags); +CIMGUI_API bool igSliderFloat(const char* label,float* v,float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igSliderFloat2(const char* label,float v[2],float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igSliderFloat3(const char* label,float v[3],float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igSliderFloat4(const char* label,float v[4],float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igSliderAngle(const char* label,float* v_rad,float v_degrees_min,float v_degrees_max); +CIMGUI_API bool igSliderInt(const char* label,int* v,int v_min,int v_max,const char* display_format); +CIMGUI_API bool igSliderInt2(const char* label,int v[2],int v_min,int v_max,const char* display_format); +CIMGUI_API bool igSliderInt3(const char* label,int v[3],int v_min,int v_max,const char* display_format); +CIMGUI_API bool igSliderInt4(const char* label,int v[4],int v_min,int v_max,const char* display_format); +CIMGUI_API bool igVSliderFloat(const char* label,const ImVec2 size,float* v,float v_min,float v_max,const char* display_format,float power); +CIMGUI_API bool igVSliderInt(const char* label,const ImVec2 size,int* v,int v_min,int v_max,const char* display_format); +CIMGUI_API bool igColorEdit3(const char* label,float col[3],ImGuiColorEditFlags flags); +CIMGUI_API bool igColorEdit4(const char* label,float col[4],ImGuiColorEditFlags flags); +CIMGUI_API bool igColorPicker3(const char* label,float col[3],ImGuiColorEditFlags flags); +CIMGUI_API bool igColorPicker4(const char* label,float col[4],ImGuiColorEditFlags flags,const float* ref_col); +CIMGUI_API bool igColorButton(const char* desc_id,const ImVec4 col,ImGuiColorEditFlags flags,ImVec2 size); +CIMGUI_API void igSetColorEditOptions(ImGuiColorEditFlags flags); +CIMGUI_API bool igTreeNodeStr(const char* label); +CIMGUI_API bool igTreeNodeStrStr(const char* str_id,const char* fmt,...); +CIMGUI_API bool igTreeNodePtr(const void* ptr_id,const char* fmt,...); +CIMGUI_API bool igTreeNodeVStr(const char* str_id,const char* fmt,va_list args); +CIMGUI_API bool igTreeNodeVPtr(const void* ptr_id,const char* fmt,va_list args); +CIMGUI_API bool igTreeNodeExStr(const char* label,ImGuiTreeNodeFlags flags); +CIMGUI_API bool igTreeNodeExStrStr(const char* str_id,ImGuiTreeNodeFlags flags,const char* fmt,...); +CIMGUI_API bool igTreeNodeExPtr(const void* ptr_id,ImGuiTreeNodeFlags flags,const char* fmt,...); +CIMGUI_API bool igTreeNodeExVStr(const char* str_id,ImGuiTreeNodeFlags flags,const char* fmt,va_list args); +CIMGUI_API bool igTreeNodeExVPtr(const void* ptr_id,ImGuiTreeNodeFlags flags,const char* fmt,va_list args); +CIMGUI_API void igTreePushStr(const char* str_id); +CIMGUI_API void igTreePushPtr(const void* ptr_id); +CIMGUI_API void igTreePop(); +CIMGUI_API void igTreeAdvanceToLabelPos(); +CIMGUI_API float igGetTreeNodeToLabelSpacing(); +CIMGUI_API void igSetNextTreeNodeOpen(bool is_open,ImGuiCond cond); +CIMGUI_API bool igCollapsingHeaderTreeNodeFlags(const char* label,ImGuiTreeNodeFlags flags); +CIMGUI_API bool igCollapsingHeaderBoolPtr(const char* label,bool* p_open,ImGuiTreeNodeFlags flags); +CIMGUI_API bool igSelectableBool(const char* label,bool selected,ImGuiSelectableFlags flags,const ImVec2 size); +CIMGUI_API bool igSelectableBoolPtr(const char* label,bool* p_selected,ImGuiSelectableFlags flags,const ImVec2 size); +CIMGUI_API bool igListBoxStr_arr(const char* label,int* current_item,const char* const items[],int items_count,int height_in_items); +CIMGUI_API bool igListBoxitems_getter(const char* label,int* current_item,bool(*items_getter)(void* data,int idx,const char** out_text),void* data,int items_count,int height_in_items); +CIMGUI_API bool igListBoxHeaderVec2(const char* label,const ImVec2 size); +CIMGUI_API bool igListBoxHeaderInt(const char* label,int items_count,int height_in_items); +CIMGUI_API void igListBoxFooter(); +CIMGUI_API void igValueBool(const char* prefix,bool b); +CIMGUI_API void igValueInt(const char* prefix,int v); +CIMGUI_API void igValueUint(const char* prefix,unsigned int v); +CIMGUI_API void igValueFloat(const char* prefix,float v,const char* float_format); +CIMGUI_API void igSetTooltip(const char* fmt,...); +CIMGUI_API void igSetTooltipV(const char* fmt,va_list args); +CIMGUI_API void igBeginTooltip(); +CIMGUI_API void igEndTooltip(); +CIMGUI_API bool igBeginMainMenuBar(); +CIMGUI_API void igEndMainMenuBar(); +CIMGUI_API bool igBeginMenuBar(); +CIMGUI_API void igEndMenuBar(); +CIMGUI_API bool igBeginMenu(const char* label,bool enabled); +CIMGUI_API void igEndMenu(); +CIMGUI_API bool igMenuItemBool(const char* label,const char* shortcut,bool selected,bool enabled); +CIMGUI_API bool igMenuItemBoolPtr(const char* label,const char* shortcut,bool* p_selected,bool enabled); +CIMGUI_API void igOpenPopup(const char* str_id); +CIMGUI_API bool igBeginPopup(const char* str_id,ImGuiWindowFlags flags); +CIMGUI_API bool igBeginPopupContextItem(const char* str_id,int mouse_button); +CIMGUI_API bool igBeginPopupContextWindow(const char* str_id,int mouse_button,bool also_over_items); +CIMGUI_API bool igBeginPopupContextVoid(const char* str_id,int mouse_button); +CIMGUI_API bool igBeginPopupModal(const char* name,bool* p_open,ImGuiWindowFlags flags); +CIMGUI_API void igEndPopup(); +CIMGUI_API bool igOpenPopupOnItemClick(const char* str_id,int mouse_button); +CIMGUI_API bool igIsPopupOpen(const char* str_id); +CIMGUI_API void igCloseCurrentPopup(); +CIMGUI_API void igColumns(int count,const char* id,bool border); +CIMGUI_API void igNextColumn(); +CIMGUI_API int igGetColumnIndex(); +CIMGUI_API float igGetColumnWidth(int column_index); +CIMGUI_API void igSetColumnWidth(int column_index,float width); +CIMGUI_API float igGetColumnOffset(int column_index); +CIMGUI_API void igSetColumnOffset(int column_index,float offset_x); +CIMGUI_API int igGetColumnsCount(); +CIMGUI_API void igLogToTTY(int max_depth); +CIMGUI_API void igLogToFile(int max_depth,const char* filename); +CIMGUI_API void igLogToClipboard(int max_depth); +CIMGUI_API void igLogFinish(); +CIMGUI_API void igLogButtons(); +CIMGUI_API void igLogText(const char* fmt,...); +CIMGUI_API bool igBeginDragDropSource(ImGuiDragDropFlags flags); +CIMGUI_API bool igSetDragDropPayload(const char* type,const void* data,size_t size,ImGuiCond cond); +CIMGUI_API void igEndDragDropSource(); +CIMGUI_API bool igBeginDragDropTarget(); +CIMGUI_API const ImGuiPayload* igAcceptDragDropPayload(const char* type,ImGuiDragDropFlags flags); +CIMGUI_API void igEndDragDropTarget(); +CIMGUI_API void igPushClipRect(const ImVec2 clip_rect_min,const ImVec2 clip_rect_max,bool intersect_with_current_clip_rect); +CIMGUI_API void igPopClipRect(); +CIMGUI_API void igSetItemDefaultFocus(); +CIMGUI_API void igSetKeyboardFocusHere(int offset); +CIMGUI_API bool igIsItemHovered(ImGuiHoveredFlags flags); +CIMGUI_API bool igIsItemActive(); +CIMGUI_API bool igIsItemFocused(); +CIMGUI_API bool igIsItemClicked(int mouse_button); +CIMGUI_API bool igIsItemVisible(); +CIMGUI_API bool igIsAnyItemHovered(); +CIMGUI_API bool igIsAnyItemActive(); +CIMGUI_API bool igIsAnyItemFocused(); +CIMGUI_API ImVec2 igGetItemRectMin(); +CIMGUI_API ImVec2 igGetItemRectMax(); +CIMGUI_API ImVec2 igGetItemRectSize(); +CIMGUI_API void igSetItemAllowOverlap(); +CIMGUI_API bool igIsRectVisible(const ImVec2 size); +CIMGUI_API bool igIsRectVisibleVec2(const ImVec2 rect_min,const ImVec2 rect_max); +CIMGUI_API float igGetTime(); +CIMGUI_API int igGetFrameCount(); +CIMGUI_API ImDrawList* igGetOverlayDrawList(); +CIMGUI_API ImDrawListSharedData* igGetDrawListSharedData(); +CIMGUI_API const char* igGetStyleColorName(ImGuiCol idx); +CIMGUI_API void igSetStateStorage(ImGuiStorage* storage); +CIMGUI_API ImGuiStorage* igGetStateStorage(); +CIMGUI_API ImVec2 igCalcTextSize(const char* text,const char* text_end,bool hide_text_after_double_hash,float wrap_width); +CIMGUI_API void igCalcListClipping(int items_count,float items_height,int* out_items_display_start,int* out_items_display_end); +CIMGUI_API bool igBeginChildFrame(ImGuiID id,const ImVec2 size,ImGuiWindowFlags flags); +CIMGUI_API void igEndChildFrame(); +CIMGUI_API ImVec4 igColorConvertU32ToFloat4(ImU32 in); +CIMGUI_API ImU32 igColorConvertFloat4ToU32(const ImVec4 in); +CIMGUI_API void igColorConvertRGBtoHSV(float r,float g,float b,float out_h,float out_s,float out_v); +CIMGUI_API void igColorConvertHSVtoRGB(float h,float s,float v,float out_r,float out_g,float out_b); +CIMGUI_API int igGetKeyIndex(ImGuiKey imgui_key); +CIMGUI_API bool igIsKeyDown(int user_key_index); +CIMGUI_API bool igIsKeyPressed(int user_key_index,bool repeat); +CIMGUI_API bool igIsKeyReleased(int user_key_index); +CIMGUI_API int igGetKeyPressedAmount(int key_index,float repeat_delay,float rate); +CIMGUI_API bool igIsMouseDown(int button); +CIMGUI_API bool igIsAnyMouseDown(); +CIMGUI_API bool igIsMouseClicked(int button,bool repeat); +CIMGUI_API bool igIsMouseDoubleClicked(int button); +CIMGUI_API bool igIsMouseReleased(int button); +CIMGUI_API bool igIsMouseDragging(int button,float lock_threshold); +CIMGUI_API bool igIsMouseHoveringRect(const ImVec2 r_min,const ImVec2 r_max,bool clip); +CIMGUI_API bool igIsMousePosValid(const ImVec2* mouse_pos); +CIMGUI_API ImVec2 igGetMousePos(); +CIMGUI_API ImVec2 igGetMousePosOnOpeningCurrentPopup(); +CIMGUI_API ImVec2 igGetMouseDragDelta(int button,float lock_threshold); +CIMGUI_API void igResetMouseDragDelta(int button); +CIMGUI_API ImGuiMouseCursor igGetMouseCursor(); +CIMGUI_API void igSetMouseCursor(ImGuiMouseCursor type); +CIMGUI_API void igCaptureKeyboardFromApp(bool capture); +CIMGUI_API void igCaptureMouseFromApp(bool capture); +CIMGUI_API const char* igGetClipboardText(); +CIMGUI_API void igSetClipboardText(const char* text); +CIMGUI_API void igSetAllocatorFunctions(void*(*alloc_func)(size_t sz,void* user_data),void(*free_func)(void* ptr,void* user_data),void* user_data); +CIMGUI_API void* igMemAlloc(size_t size); +CIMGUI_API void igMemFree(void* ptr); +CIMGUI_API void ImGuiStyle_ScaleAllSizes(ImGuiStyle* self,float scale_factor); +CIMGUI_API void ImGuiIO_AddInputCharacter(ImGuiIO* self,ImWchar c); +CIMGUI_API void ImGuiIO_AddInputCharactersUTF8(ImGuiIO* self,const char* utf8_chars); +CIMGUI_API inline void ImGuiIO_ClearInputCharacters(ImGuiIO* self,); +CIMGUI_API template void _IM_DELETE(* self,T* p); +CIMGUI_API const char* TextRange_begin(TextRange* self,); +CIMGUI_API const char* TextRange_end(TextRange* self,); +CIMGUI_API bool TextRange_empty(TextRange* self,); +CIMGUI_API char TextRange_front(TextRange* self,); +CIMGUI_API static bool TextRange_is_blank(TextRange* self,char c); +CIMGUI_API void TextRange_trim_blanks(TextRange* self,); +CIMGUI_API void TextRange_split(TextRange* self,char separator,ImVector out); +CIMGUI_API bool ImGuiTextFilter_Draw(ImGuiTextFilter* self,const char* label,float width); +CIMGUI_API bool ImGuiTextFilter_PassFilter(ImGuiTextFilter* self,const char* text,const char* text_end); +CIMGUI_API void ImGuiTextFilter_Build(ImGuiTextFilter* self,); +CIMGUI_API void ImGuiTextFilter_Clear(ImGuiTextFilter* self,); +CIMGUI_API bool ImGuiTextFilter_IsActive(ImGuiTextFilter* self,); +CIMGUI_API const char* ImGuiTextBuffer_begin(ImGuiTextBuffer* self,); +CIMGUI_API const char* ImGuiTextBuffer_end(ImGuiTextBuffer* self,); +CIMGUI_API int ImGuiTextBuffer_size(ImGuiTextBuffer* self,); +CIMGUI_API bool ImGuiTextBuffer_empty(ImGuiTextBuffer* self,); +CIMGUI_API void ImGuiTextBuffer_clear(ImGuiTextBuffer* self,); +CIMGUI_API void ImGuiTextBuffer_reserve(ImGuiTextBuffer* self,int capacity); +CIMGUI_API const char* ImGuiTextBuffer_c_str(ImGuiTextBuffer* self,); +CIMGUI_API void ImGuiTextBuffer_appendf(ImGuiTextBuffer* self,const char* fmt,...); +CIMGUI_API void ImGuiTextBuffer_appendfv(ImGuiTextBuffer* self,const char* fmt,va_list args); +CIMGUI_API void ImGuiStorage_Clear(ImGuiStorage* self,); +CIMGUI_API int ImGuiStorage_GetInt(ImGuiStorage* self,ImGuiID key,int default_val); +CIMGUI_API void ImGuiStorage_SetInt(ImGuiStorage* self,ImGuiID key,int val); +CIMGUI_API bool ImGuiStorage_GetBool(ImGuiStorage* self,ImGuiID key,bool default_val); +CIMGUI_API void ImGuiStorage_SetBool(ImGuiStorage* self,ImGuiID key,bool val); +CIMGUI_API float ImGuiStorage_GetFloat(ImGuiStorage* self,ImGuiID key,float default_val); +CIMGUI_API void ImGuiStorage_SetFloat(ImGuiStorage* self,ImGuiID key,float val); +CIMGUI_API void* ImGuiStorage_GetVoidPtr(ImGuiStorage* self,ImGuiID key); +CIMGUI_API void ImGuiStorage_SetVoidPtr(ImGuiStorage* self,ImGuiID key,void* val); +CIMGUI_API int* ImGuiStorage_GetIntRef(ImGuiStorage* self,ImGuiID key,int default_val); +CIMGUI_API bool* ImGuiStorage_GetBoolRef(ImGuiStorage* self,ImGuiID key,bool default_val); +CIMGUI_API float* ImGuiStorage_GetFloatRef(ImGuiStorage* self,ImGuiID key,float default_val); +CIMGUI_API void** ImGuiStorage_GetVoidPtrRef(ImGuiStorage* self,ImGuiID key,void* default_val); +CIMGUI_API void ImGuiStorage_SetAllInt(ImGuiStorage* self,int val); +CIMGUI_API void ImGuiStorage_BuildSortByKey(ImGuiStorage* self,); +CIMGUI_API void ImGuiTextEditCallbackData_DeleteChars(ImGuiTextEditCallbackData* self,int pos,int bytes_count); +CIMGUI_API void ImGuiTextEditCallbackData_InsertChars(ImGuiTextEditCallbackData* self,int pos,const char* text,const char* text_end); +CIMGUI_API bool ImGuiTextEditCallbackData_HasSelection(ImGuiTextEditCallbackData* self,); +CIMGUI_API void ImGuiPayload_Clear(ImGuiPayload* self,); +CIMGUI_API bool ImGuiPayload_IsDataType(ImGuiPayload* self,const char* type); +CIMGUI_API bool ImGuiPayload_IsPreview(ImGuiPayload* self,); +CIMGUI_API bool ImGuiPayload_IsDelivery(ImGuiPayload* self,); +CIMGUI_API inline void ImColor_SetHSV(ImColor* self,float h,float s,float v,float a); +CIMGUI_API static ImColor ImColor_HSV(ImColor* self,float h,float s,float v,float a); +CIMGUI_API bool ImGuiListClipper_Step(ImGuiListClipper* self,); +CIMGUI_API void ImGuiListClipper_Begin(ImGuiListClipper* self,int items_count,float items_height); +CIMGUI_API void ImGuiListClipper_End(ImGuiListClipper* self,); +CIMGUI_API void ImDrawList_PushClipRect(ImDrawList* self,ImVec2 clip_rect_min,ImVec2 clip_rect_max,bool intersect_with_current_clip_rect); +CIMGUI_API void ImDrawList_PushClipRectFullScreen(ImDrawList* self,); +CIMGUI_API void ImDrawList_PopClipRect(ImDrawList* self,); +CIMGUI_API void ImDrawList_PushTextureID(ImDrawList* self,ImTextureID texture_id); +CIMGUI_API void ImDrawList_PopTextureID(ImDrawList* self,); +CIMGUI_API inline ImVec2 ImDrawList_GetClipRectMin(ImDrawList* self,); +CIMGUI_API inline ImVec2 ImDrawList_GetClipRectMax(ImDrawList* self,); +CIMGUI_API void ImDrawList_AddLine(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col,float thickness); +CIMGUI_API void ImDrawList_AddRect(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col,float rounding,int rounding_corners_flags,float thickness); +CIMGUI_API void ImDrawList_AddRectFilled(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col,float rounding,int rounding_corners_flags); +CIMGUI_API void ImDrawList_AddRectFilledMultiColor(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col_upr_left,ImU32 col_upr_right,ImU32 col_bot_right,ImU32 col_bot_left); +CIMGUI_API void ImDrawList_AddQuad(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,const ImVec2 d,ImU32 col,float thickness); +CIMGUI_API void ImDrawList_AddQuadFilled(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,const ImVec2 d,ImU32 col); +CIMGUI_API void ImDrawList_AddTriangle(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,ImU32 col,float thickness); +CIMGUI_API void ImDrawList_AddTriangleFilled(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,ImU32 col); +CIMGUI_API void ImDrawList_AddCircle(ImDrawList* self,const ImVec2 centre,float radius,ImU32 col,int num_segments,float thickness); +CIMGUI_API void ImDrawList_AddCircleFilled(ImDrawList* self,const ImVec2 centre,float radius,ImU32 col,int num_segments); +CIMGUI_API void ImDrawList_AddTextVec2(ImDrawList* self,const ImVec2 pos,ImU32 col,const char* text_begin,const char* text_end); +CIMGUI_API void ImDrawList_AddTextFontPtr(ImDrawList* self,const ImFont* font,float font_size,const ImVec2 pos,ImU32 col,const char* text_begin,const char* text_end,float wrap_width,const ImVec4* cpu_fine_clip_rect); +CIMGUI_API void ImDrawList_AddImage(ImDrawList* self,ImTextureID user_texture_id,const ImVec2 a,const ImVec2 b,const ImVec2 uv_a,const ImVec2 uv_b,ImU32 col); +CIMGUI_API void ImDrawList_AddImageQuad(ImDrawList* self,ImTextureID user_texture_id,const ImVec2 a,const ImVec2 b,const ImVec2 c,const ImVec2 d,const ImVec2 uv_a,const ImVec2 uv_b,const ImVec2 uv_c,const ImVec2 uv_d,ImU32 col); +CIMGUI_API void ImDrawList_AddImageRounded(ImDrawList* self,ImTextureID user_texture_id,const ImVec2 a,const ImVec2 b,const ImVec2 uv_a,const ImVec2 uv_b,ImU32 col,float rounding,int rounding_corners); +CIMGUI_API void ImDrawList_AddPolyline(ImDrawList* self,const ImVec2* points,const int num_points,ImU32 col,bool closed,float thickness); +CIMGUI_API void ImDrawList_AddConvexPolyFilled(ImDrawList* self,const ImVec2* points,const int num_points,ImU32 col); +CIMGUI_API void ImDrawList_AddBezierCurve(ImDrawList* self,const ImVec2 pos0,const ImVec2 cp0,const ImVec2 cp1,const ImVec2 pos1,ImU32 col,float thickness,int num_segments); +CIMGUI_API inline void ImDrawList_PathClear(ImDrawList* self,); +CIMGUI_API inline void ImDrawList_PathLineTo(ImDrawList* self,const ImVec2 pos); +CIMGUI_API inline void ImDrawList_PathLineToMergeDuplicate(ImDrawList* self,const ImVec2 pos); +CIMGUI_API inline void ImDrawList_PathFillConvex(ImDrawList* self,ImU32 col); +CIMGUI_API inline void ImDrawList_PathStroke(ImDrawList* self,ImU32 col,bool closed,float thickness); +CIMGUI_API void ImDrawList_PathArcTo(ImDrawList* self,const ImVec2 centre,float radius,float a_min,float a_max,int num_segments); +CIMGUI_API void ImDrawList_PathArcToFast(ImDrawList* self,const ImVec2 centre,float radius,int a_min_of_12,int a_max_of_12); +CIMGUI_API void ImDrawList_PathBezierCurveTo(ImDrawList* self,const ImVec2 p1,const ImVec2 p2,const ImVec2 p3,int num_segments); +CIMGUI_API void ImDrawList_PathRect(ImDrawList* self,const ImVec2 rect_min,const ImVec2 rect_max,float rounding,int rounding_corners_flags); +CIMGUI_API void ImDrawList_ChannelsSplit(ImDrawList* self,int channels_count); +CIMGUI_API void ImDrawList_ChannelsMerge(ImDrawList* self,); +CIMGUI_API void ImDrawList_ChannelsSetCurrent(ImDrawList* self,int channel_index); +CIMGUI_API void ImDrawList_AddCallback(ImDrawList* self,ImDrawCallback callback,void* callback_data); +CIMGUI_API void ImDrawList_AddDrawCmd(ImDrawList* self,); +CIMGUI_API ImDrawList* ImDrawList_CloneOutput(ImDrawList* self,); +CIMGUI_API void ImDrawList_Clear(ImDrawList* self,); +CIMGUI_API void ImDrawList_ClearFreeMemory(ImDrawList* self,); +CIMGUI_API void ImDrawList_PrimReserve(ImDrawList* self,int idx_count,int vtx_count); +CIMGUI_API void ImDrawList_PrimRect(ImDrawList* self,const ImVec2 a,const ImVec2 b,ImU32 col); +CIMGUI_API void ImDrawList_PrimRectUV(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 uv_a,const ImVec2 uv_b,ImU32 col); +CIMGUI_API void ImDrawList_PrimQuadUV(ImDrawList* self,const ImVec2 a,const ImVec2 b,const ImVec2 c,const ImVec2 d,const ImVec2 uv_a,const ImVec2 uv_b,const ImVec2 uv_c,const ImVec2 uv_d,ImU32 col); +CIMGUI_API inline void ImDrawList_PrimWriteVtx(ImDrawList* self,const ImVec2 pos,const ImVec2 uv,ImU32 col); +CIMGUI_API inline void ImDrawList_PrimWriteIdx(ImDrawList* self,ImDrawIdx idx); +CIMGUI_API inline void ImDrawList_PrimVtx(ImDrawList* self,const ImVec2 pos,const ImVec2 uv,ImU32 col); +CIMGUI_API void ImDrawList_UpdateClipRect(ImDrawList* self,); +CIMGUI_API void ImDrawList_UpdateTextureID(ImDrawList* self,); +CIMGUI_API void ImDrawData_Clear(ImDrawData* self,); +CIMGUI_API void ImDrawData_DeIndexAllBuffers(ImDrawData* self,); +CIMGUI_API void ImDrawData_ScaleClipRects(ImDrawData* self,const ImVec2 sc); +CIMGUI_API ImFont* ImFontAtlas_AddFont(ImFontAtlas* self,const ImFontConfig* font_cfg); +CIMGUI_API ImFont* ImFontAtlas_AddFontDefault(ImFontAtlas* self,const ImFontConfig* font_cfg); +CIMGUI_API ImFont* ImFontAtlas_AddFontFromFileTTF(ImFontAtlas* self,const char* filename,float size_pixels,const ImFontConfig* font_cfg,const ImWchar* glyph_ranges); +CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryTTF(ImFontAtlas* self,void* font_data,int font_size,float size_pixels,const ImFontConfig* font_cfg,const ImWchar* glyph_ranges); +CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryCompressedTTF(ImFontAtlas* self,const void* compressed_font_data,int compressed_font_size,float size_pixels,const ImFontConfig* font_cfg,const ImWchar* glyph_ranges); +CIMGUI_API ImFont* ImFontAtlas_AddFontFromMemoryCompressedBase85TTF(ImFontAtlas* self,const char* compressed_font_data_base85,float size_pixels,const ImFontConfig* font_cfg,const ImWchar* glyph_ranges); +CIMGUI_API void ImFontAtlas_ClearInputData(ImFontAtlas* self,); +CIMGUI_API void ImFontAtlas_ClearTexData(ImFontAtlas* self,); +CIMGUI_API void ImFontAtlas_ClearFonts(ImFontAtlas* self,); +CIMGUI_API void ImFontAtlas_Clear(ImFontAtlas* self,); +CIMGUI_API bool ImFontAtlas_Build(ImFontAtlas* self,); +CIMGUI_API void ImFontAtlas_GetTexDataAsAlpha8(ImFontAtlas* self,unsigned char** out_pixels,int* out_width,int* out_height,int* out_bytes_per_pixel); +CIMGUI_API void ImFontAtlas_GetTexDataAsRGBA32(ImFontAtlas* self,unsigned char** out_pixels,int* out_width,int* out_height,int* out_bytes_per_pixel); +CIMGUI_API void ImFontAtlas_SetTexID(ImFontAtlas* self,ImTextureID id); +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesDefault(ImFontAtlas* self,); +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesKorean(ImFontAtlas* self,); +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesJapanese(ImFontAtlas* self,); +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesChinese(ImFontAtlas* self,); +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesCyrillic(ImFontAtlas* self,); +CIMGUI_API const ImWchar* ImFontAtlas_GetGlyphRangesThai(ImFontAtlas* self,); +CIMGUI_API bool GlyphRangesBuilder_GetBit(GlyphRangesBuilder* self,int n); +CIMGUI_API void GlyphRangesBuilder_SetBit(GlyphRangesBuilder* self,int n); +CIMGUI_API void GlyphRangesBuilder_AddChar(GlyphRangesBuilder* self,ImWchar c); +CIMGUI_API void GlyphRangesBuilder_AddText(GlyphRangesBuilder* self,const char* text,const char* text_end); +CIMGUI_API void GlyphRangesBuilder_AddRanges(GlyphRangesBuilder* self,const ImWchar* ranges); +CIMGUI_API void GlyphRangesBuilder_BuildRanges(GlyphRangesBuilder* self,ImVector* out_ranges); +CIMGUI_API bool CustomRect_IsPacked(CustomRect* self,); +CIMGUI_API int ImFontAtlas_AddCustomRectRegular(ImFontAtlas* self,unsigned int id,int width,int height); +CIMGUI_API int ImFontAtlas_AddCustomRectFontGlyph(ImFontAtlas* self,ImFont* font,ImWchar id,int width,int height,float advance_x,const ImVec2 offset); +CIMGUI_API const CustomRect* ImFontAtlas_GetCustomRectByIndex(ImFontAtlas* self,int index); +CIMGUI_API void ImFontAtlas_CalcCustomRectUV(ImFontAtlas* self,const CustomRect* rect,ImVec2* out_uv_min,ImVec2* out_uv_max); +CIMGUI_API bool ImFontAtlas_GetMouseCursorTexData(ImFontAtlas* self,ImGuiMouseCursor cursor,ImVec2* out_offset,ImVec2* out_size,ImVec2 out_uv_border[2],ImVec2 out_uv_fill[2]); +CIMGUI_API void ImFont_ClearOutputData(ImFont* self,); +CIMGUI_API void ImFont_BuildLookupTable(ImFont* self,); +CIMGUI_API const ImFontGlyph ImFont_FindGlyph(ImFont* self,ImWchar c); +CIMGUI_API const ImFontGlyph ImFont_FindGlyphNoFallback(ImFont* self,ImWchar c); +CIMGUI_API void ImFont_SetFallbackChar(ImFont* self,ImWchar c); +CIMGUI_API float ImFont_GetCharAdvance(ImFont* self,ImWchar c); +CIMGUI_API bool ImFont_IsLoaded(ImFont* self,); +CIMGUI_API const char* ImFont_GetDebugName(ImFont* self,); +CIMGUI_API ImVec2 ImFont_CalcTextSizeA(ImFont* self,float size,float max_width,float wrap_width,const char* text_begin,const char* text_end,const char** remaining); +CIMGUI_API const char* ImFont_CalcWordWrapPositionA(ImFont* self,float scale,const char* text,const char* text_end,float wrap_width); +CIMGUI_API void ImFont_RenderChar(ImFont* self,ImDrawList* draw_list,float size,ImVec2 pos,ImU32 col,unsigned short c); +CIMGUI_API void ImFont_RenderText(ImFont* self,ImDrawList* draw_list,float size,ImVec2 pos,ImU32 col,const ImVec4 clip_rect,const char* text_begin,const char* text_end,float wrap_width,bool cpu_fine_clip); +CIMGUI_API void ImFont_GrowIndex(ImFont* self,int new_size); +CIMGUI_API void ImFont_AddGlyph(ImFont* self,ImWchar c,float x0,float y0,float x1,float y1,float u0,float v0,float u1,float v1,float advance_x); +CIMGUI_API void ImFont_AddRemapChar(ImFont* self,ImWchar dst,ImWchar src,bool overwrite_dst); diff --git a/cimgui/cimgui.cpp b/cimgui/cimgui.cpp index a033ba5..3220e56 100644 --- a/cimgui/cimgui.cpp +++ b/cimgui/cimgui.cpp @@ -6,1883 +6,4 @@ #define IMGUI_DEFINE_PLACEMENT_NEW #include "../imgui/imgui_internal.h" -CIMGUI_API ImGuiIO *igGetIO() -{ - return &ImGui::GetIO(); -} - -CIMGUI_API ImGuiStyle *igGetStyle() -{ - return &ImGui::GetStyle(); -} - -CIMGUI_API ImDrawData *igGetDrawData() -{ - return ImGui::GetDrawData(); -} - -CIMGUI_API void igNewFrame() -{ - ImGui::NewFrame(); -} - -CIMGUI_API void igRender() -{ - ImGui::Render(); -} - -CIMGUI_API void igEndFrame() -{ - ImGui::EndFrame(); -} - - -CIMGUI_API void igShowUserGuide() -{ - ImGui::ShowUserGuide(); -} - -CIMGUI_API void igShowStyleEditor(ImGuiStyle *ref) -{ - ImGui::ShowStyleEditor(ref); -} - -CIMGUI_API void igShowDemoWindow(bool *opened) -{ - ImGui::ShowDemoWindow(opened); -} - -IMGUI_API void igShowMetricsWindow(bool *opened) -{ - ImGui::ShowMetricsWindow(opened); -} - -CIMGUI_API void igShowStyleSelector(CONST char *label) -{ - ImGui::ShowStyleSelector(label); -} - -CIMGUI_API void igShowFontSelector(CONST char *label) -{ - ImGui::ShowFontSelector(label); -} - -// Window - -CIMGUI_API bool igBegin(CONST char *name, bool *p_opened, ImGuiWindowFlags flags) -{ - return ImGui::Begin(name, p_opened, flags); -} - -CIMGUI_API bool igBegin2(CONST char *name, bool *p_opened, CONST ImVec2 size_on_first_use, float bg_alpha, ImGuiWindowFlags flags) -{ - return ImGui::Begin(name, p_opened, size_on_first_use, bg_alpha, flags); -} - -CIMGUI_API void igEnd() -{ - ImGui::End(); -} - -CIMGUI_API bool igBeginChild(CONST char *str_id, CONST ImVec2 size, bool border, ImGuiWindowFlags extra_flags) -{ - return ImGui::BeginChild(str_id, size, border, extra_flags); -} - -CIMGUI_API bool igBeginChildEx(ImGuiID id, CONST ImVec2 size, bool border, ImGuiWindowFlags extra_flags) -{ - return ImGui::BeginChild(id, size, border, extra_flags); -} - -CIMGUI_API void igEndChild() -{ - ImGui::EndChild(); -} - -CIMGUI_API void igGetContentRegionMax(ImVec2 *out) -{ - *out = ImGui::GetContentRegionMax(); -} - -CIMGUI_API void igGetContentRegionAvail(struct ImVec2 *out) -{ - *out = ImGui::GetContentRegionAvail(); -} - -CIMGUI_API float igGetContentRegionAvailWidth() -{ - return ImGui::GetContentRegionAvailWidth(); -} - -CIMGUI_API void igGetWindowContentRegionMin(ImVec2 *out) -{ - *out = ImGui::GetWindowContentRegionMin(); -} - -CIMGUI_API void igGetWindowContentRegionMax(ImVec2 *out) -{ - *out = ImGui::GetWindowContentRegionMax(); -} - -CIMGUI_API float igGetWindowContentRegionWidth() -{ - return ImGui::GetWindowContentRegionWidth(); -} - -CIMGUI_API ImDrawList *igGetWindowDrawList() -{ - return ImGui::GetWindowDrawList(); -} - -CIMGUI_API void igGetWindowPos(ImVec2 *out) -{ - *out = ImGui::GetWindowPos(); -} - -CIMGUI_API void igGetWindowSize(ImVec2 *out) -{ - *out = ImGui::GetWindowSize(); -} - -CIMGUI_API float igGetWindowWidth() -{ - return ImGui::GetWindowWidth(); -} - -CIMGUI_API float igGetWindowHeight() -{ - return ImGui::GetWindowHeight(); -} - -CIMGUI_API bool igIsWindowCollapsed() -{ - return ImGui::IsWindowCollapsed(); -} - -CIMGUI_API bool igIsWindowAppearing() -{ - return ImGui::IsWindowAppearing(); -} - -CIMGUI_API void igSetWindowFontScale(float scale) -{ - ImGui::SetWindowFontScale(scale); -} - -CIMGUI_API void igSetNextWindowPos(CONST struct ImVec2 pos, ImGuiCond cond, CONST struct ImVec2 pivot) -{ - ImGui::SetNextWindowPos(pos, cond, pivot); -} - -CIMGUI_API void igSetNextWindowSize(CONST ImVec2 size, ImGuiCond cond) -{ - ImGui::SetNextWindowSize(size, cond); -} - -CIMGUI_API void igSetNextWindowSizeConstraints(CONST struct ImVec2 size_min, CONST struct ImVec2 size_max, ImGuiSizeCallback custom_callback, void *custom_callback_data) -{ - ImGui::SetNextWindowSizeConstraints(size_min, size_max, custom_callback, custom_callback_data); -} - -CIMGUI_API void igSetNextWindowContentSize(CONST ImVec2 size) -{ - ImGui::SetNextWindowContentSize(size); -} - -CIMGUI_API void igSetNextWindowCollapsed(bool collapsed, ImGuiCond cond) -{ - ImGui::SetNextWindowCollapsed(collapsed, cond); -} - -CIMGUI_API void igSetNextWindowFocus() -{ - ImGui::SetNextWindowFocus(); -} - -CIMGUI_API void igSetWindowPos(CONST ImVec2 pos, ImGuiCond cond) -{ - ImGui::SetWindowPos(pos, cond); -} - -CIMGUI_API void igSetWindowSize(CONST ImVec2 size, ImGuiCond cond) -{ - ImGui::SetWindowSize(size, cond); -} - -CIMGUI_API void igSetWindowCollapsed(bool collapsed, ImGuiCond cond) -{ - ImGui::SetWindowCollapsed(collapsed, cond); -} - -CIMGUI_API void igSetWindowFocus() -{ - ImGui::SetWindowFocus(); -} - -CIMGUI_API void igSetWindowPosByName(CONST char *name, CONST ImVec2 pos, ImGuiCond cond) -{ - ImGui::SetWindowPos(name, pos, cond); -} - -CIMGUI_API void igSetWindowSize2(CONST char *name, CONST ImVec2 size, ImGuiCond cond) -{ - ImGui::SetWindowSize(name, size, cond); -} - -CIMGUI_API void igSetWindowCollapsed2(CONST char *name, bool collapsed, ImGuiCond cond) -{ - ImGui::SetWindowCollapsed(name, collapsed, cond); -} - -CIMGUI_API void igSetWindowFocus2(CONST char *name) -{ - ImGui::SetWindowFocus(name); -} - -CIMGUI_API float igGetScrollX() -{ - return ImGui::GetScrollX(); -} - -CIMGUI_API float igGetScrollY() -{ - return ImGui::GetScrollY(); -} - -CIMGUI_API float igGetScrollMaxX() -{ - return ImGui::GetScrollMaxX(); -} - -CIMGUI_API float igGetScrollMaxY() -{ - return ImGui::GetScrollMaxY(); -} - -CIMGUI_API void igSetScrollX(float scroll_x) -{ - return ImGui::SetScrollX(scroll_x); -} - -CIMGUI_API void igSetScrollY(float scroll_y) -{ - return ImGui::SetScrollY(scroll_y); -} - -CIMGUI_API void igSetScrollHere(float center_y_ratio) -{ - ImGui::SetScrollHere(center_y_ratio); -} - -CIMGUI_API void igSetScrollFromPosY(float pos_y, float center_y_ratio) -{ - return ImGui::SetScrollFromPosY(pos_y, center_y_ratio); -} - -CIMGUI_API void igSetStateStorage(ImGuiStorage *tree) -{ - ImGui::SetStateStorage(tree); -} - -CIMGUI_API ImGuiStorage *igGetStateStorage() -{ - return ImGui::GetStateStorage(); -} - -// Parameters stacks (shared) -CIMGUI_API void igPushFont(ImFont *font) -{ - ImGui::PushFont(font); -} - -CIMGUI_API void igPopFont() -{ - return ImGui::PopFont(); -} - -CIMGUI_API void igPushStyleColorU32(ImGuiCol idx, ImU32 col) -{ - return ImGui::PushStyleColor(idx, col); -} - -CIMGUI_API void igPushStyleColor(ImGuiCol idx, CONST ImVec4 col) -{ - return ImGui::PushStyleColor(idx, col); -} - -CIMGUI_API void igPopStyleColor(int count) -{ - return ImGui::PopStyleColor(count); -} - -CIMGUI_API void igPushStyleVar(ImGuiStyleVar idx, float val) -{ - return ImGui::PushStyleVar(idx, val); -} - -CIMGUI_API void igPushStyleVarVec(ImGuiStyleVar idx, CONST ImVec2 val) -{ - return ImGui::PushStyleVar(idx, val); -} - -CIMGUI_API void igPopStyleVar(int count) -{ - return ImGui::PopStyleVar(count); -} - -CIMGUI_API void igGetStyleColorVec4(ImVec4 *pOut, ImGuiCol idx) -{ - *pOut = ImGui::GetStyleColorVec4(idx); -} - -CIMGUI_API ImFont *igGetFont() -{ - return ImGui::GetFont(); -} - -CIMGUI_API float igGetFontSize() -{ - return ImGui::GetFontSize(); -} - -CIMGUI_API void igGetFontTexUvWhitePixel(ImVec2 *pOut) -{ - *pOut = ImGui::GetFontTexUvWhitePixel(); -} - -CIMGUI_API ImU32 igGetColorU32(ImGuiCol idx, float alpha_mul) -{ - return ImGui::GetColorU32(idx, alpha_mul); -} - -CIMGUI_API ImU32 igGetColorU32Vec(CONST ImVec4 *col) -{ - return ImGui::GetColorU32(*col); -} - -CIMGUI_API ImU32 igGetColorU32U32(ImU32 col) -{ - return ImGui::GetColorU32(col); -} - -// Parameters stacks (current window) -CIMGUI_API void igPushItemWidth(float item_width) -{ - return ImGui::PushItemWidth(item_width); -} - -CIMGUI_API void igPopItemWidth() -{ - return ImGui::PopItemWidth(); -} - -CIMGUI_API float igCalcItemWidth() -{ - return ImGui::CalcItemWidth(); -} - -CIMGUI_API void igPushAllowKeyboardFocus(bool v) -{ - return ImGui::PushAllowKeyboardFocus(v); -} - -CIMGUI_API void igPopAllowKeyboardFocus() -{ - return ImGui::PopAllowKeyboardFocus(); -} - -CIMGUI_API void igPushTextWrapPos(float wrap_pos_x) -{ - return ImGui::PushTextWrapPos(wrap_pos_x); -} - -CIMGUI_API void igPopTextWrapPos() -{ - return ImGui::PopTextWrapPos(); -} - -CIMGUI_API void igPushButtonRepeat(bool repeat) -{ - return ImGui::PushButtonRepeat(repeat); -} - -CIMGUI_API void igPopButtonRepeat() -{ - return ImGui::PopButtonRepeat(); -} - -// Tooltip -CIMGUI_API void igSetTooltip(CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - ImGui::SetTooltipV(fmt, args); - va_end(args); -} - -CIMGUI_API void igSetTooltipV(CONST char *fmt, va_list args) -{ - ImGui::SetTooltipV(fmt, args); -} - -CIMGUI_API void igBeginTooltip() -{ - return ImGui::BeginTooltip(); -} - -CIMGUI_API void igEndTooltip() -{ - return ImGui::EndTooltip(); -} - -// Popup -CIMGUI_API void igOpenPopup(CONST char *str_id) -{ - return ImGui::OpenPopup(str_id); -} - -CIMGUI_API bool igOpenPopupOnItemClick(const char *str_id, int mouse_button) -{ - return ImGui::OpenPopupOnItemClick(str_id, mouse_button); -} - -CIMGUI_API bool igBeginPopup(CONST char *str_id) -{ - return ImGui::BeginPopup(str_id); -} - -CIMGUI_API bool igBeginPopupModal(CONST char *name, bool *p_open, ImGuiWindowFlags extra_flags) -{ - return ImGui::BeginPopupModal(name, p_open, extra_flags); -} - -CIMGUI_API bool igBeginPopupContextItem(CONST char *str_id, int mouse_button) -{ - return ImGui::BeginPopupContextItem(str_id, mouse_button); -} - -CIMGUI_API bool igBeginPopupContextWindow(CONST char *str_id, int mouse_button, bool also_over_items) -{ - return ImGui::BeginPopupContextWindow(str_id, mouse_button, also_over_items); -} - -CIMGUI_API bool igBeginPopupContextVoid(CONST char *str_id, int mouse_button) -{ - return ImGui::BeginPopupContextVoid(str_id, mouse_button); -} - -CIMGUI_API void igEndPopup() -{ - return ImGui::EndPopup(); -} - -CIMGUI_API bool igIsPopupOpen(CONST char *str_id) -{ - return ImGui::IsPopupOpen(str_id); -} - -CIMGUI_API void igCloseCurrentPopup() -{ - return ImGui::CloseCurrentPopup(); -} - -// Layout - -CIMGUI_API void igSeparator() -{ - return ImGui::Separator(); -} - -CIMGUI_API void igSameLine(float pos_x, float spacing_w) -{ - return ImGui::SameLine(pos_x, spacing_w); -} - -CIMGUI_API void igNewLine() -{ - return ImGui::NewLine(); -} - -CIMGUI_API void igSpacing() -{ - return ImGui::Spacing(); -} - -CIMGUI_API void igDummy(CONST ImVec2 *size) -{ - return ImGui::Dummy(*size); -} - -CIMGUI_API void igIndent(float indent_w) -{ - return ImGui::Indent(indent_w); -} - -CIMGUI_API void igUnindent(float indent_w) -{ - return ImGui::Unindent(indent_w); -} - -CIMGUI_API void igBeginGroup() -{ - return ImGui::BeginGroup(); -} - -CIMGUI_API void igEndGroup() -{ - return ImGui::EndGroup(); -} - -CIMGUI_API void igGetCursorPos(ImVec2 *pOut) -{ - *pOut = ImGui::GetCursorPos(); -} - -CIMGUI_API float igGetCursorPosX() -{ - return ImGui::GetCursorPosX(); -} - -CIMGUI_API float igGetCursorPosY() -{ - return ImGui::GetCursorPosY(); -} - -CIMGUI_API void igSetCursorPos(CONST ImVec2 local_pos) -{ - return ImGui::SetCursorPos(local_pos); -} - -CIMGUI_API void igSetCursorPosX(float x) -{ - return ImGui::SetCursorPosX(x); -} - -CIMGUI_API void igSetCursorPosY(float y) -{ - return ImGui::SetCursorPosY(y); -} - -CIMGUI_API void igGetCursorStartPos(ImVec2 *pOut) -{ - *pOut = ImGui::GetCursorStartPos(); -} - -CIMGUI_API void igGetCursorScreenPos(ImVec2 *pOut) -{ - *pOut = ImGui::GetCursorScreenPos(); -} - -CIMGUI_API void igSetCursorScreenPos(CONST ImVec2 pos) -{ - return ImGui::SetCursorScreenPos(pos); -} - -CIMGUI_API void igAlignTextToFramePadding() -{ - return ImGui::AlignTextToFramePadding(); -} - -CIMGUI_API float igGetTextLineHeight() -{ - return ImGui::GetTextLineHeight(); -} - -CIMGUI_API float igGetTextLineHeightWithSpacing() -{ - return ImGui::GetTextLineHeightWithSpacing(); -} - -CIMGUI_API float igGetFrameHeight() -{ - return ImGui::GetFrameHeight(); -} - -CIMGUI_API float igGetFrameHeightWithSpacing() -{ - return ImGui::GetFrameHeightWithSpacing(); -} - -//Columns - -CIMGUI_API void igColumns(int count, CONST char *id, bool border) -{ - return ImGui::Columns(count, id, border); -} - -CIMGUI_API void igNextColumn() -{ - return ImGui::NextColumn(); -} - -CIMGUI_API int igGetColumnIndex() -{ - return ImGui::GetColumnIndex(); -} - -CIMGUI_API float igGetColumnWidth(int column_index) -{ - return ImGui::GetColumnWidth(column_index); -} - -CIMGUI_API void igSetColumnWidth(int column_index, float width) -{ - return ImGui::SetColumnWidth(column_index, width); -} - -CIMGUI_API float igGetColumnOffset(int column_index) -{ - return ImGui::GetColumnOffset(column_index); -} - -CIMGUI_API void igSetColumnOffset(int column_index, float offset_x) -{ - return ImGui::SetColumnOffset(column_index, offset_x); -} - -CIMGUI_API int igGetColumnsCount() -{ - return ImGui::GetColumnsCount(); -} - -// ID scopes -// If you are creating widgets in a loop you most likely want to push a unique identifier so ImGui can differentiate them -// You can also use "##extra" within your widget name to distinguish them from each others (see 'Programmer Guide') -CIMGUI_API void igPushIDStr(CONST char *str_id) -{ - return ImGui::PushID(str_id); -} - -CIMGUI_API void igPushIDStrRange(CONST char *str_begin, CONST char *str_end) -{ - return ImGui::PushID(str_begin, str_end); -} - -CIMGUI_API void igPushIDPtr(CONST void *ptr_id) -{ - return ImGui::PushID(ptr_id); -} - -CIMGUI_API void igPushIDInt(int int_id) -{ - return ImGui::PushID(int_id); -} - -CIMGUI_API void igPopID() -{ - return ImGui::PopID(); -} - -CIMGUI_API ImGuiID igGetIDStr(CONST char *str_id) -{ - return ImGui::GetID(str_id); -} - -CIMGUI_API ImGuiID igGetIDStrRange(CONST char *str_begin, CONST char *str_end) -{ - return ImGui::GetID(str_begin, str_end); -} - -CIMGUI_API ImGuiID igGetIDPtr(CONST void *ptr_id) -{ - return ImGui::GetID(ptr_id); -} - -// Widgets -CIMGUI_API void igText(CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - ImGui::TextV(fmt, args); - va_end(args); -} - -CIMGUI_API void igTextV(CONST char *fmt, va_list args) -{ - ImGui::TextV(fmt, args); -} - -CIMGUI_API void igTextColored(CONST ImVec4 col, CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - ImGui::TextColoredV(col, fmt, args); - va_end(args); -} - -CIMGUI_API void igTextColoredV(CONST ImVec4 col, CONST char *fmt, va_list args) -{ - ImGui::TextColoredV(col, fmt, args); -} - -CIMGUI_API void igTextDisabled(CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - ImGui::TextDisabledV(fmt, args); - va_end(args); -} - -CIMGUI_API void igTextDisabledV(CONST char *fmt, va_list args) -{ - return ImGui::TextDisabledV(fmt, args); -} - -CIMGUI_API void igTextWrapped(CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - ImGui::TextWrappedV(fmt, args); - va_end(args); -} - -CIMGUI_API void igTextWrappedV(CONST char *fmt, va_list args) -{ - ImGui::TextWrappedV(fmt, args); -} - -CIMGUI_API void igTextUnformatted(CONST char *text, CONST char *text_end) -{ - return ImGui::TextUnformatted(text, text_end); -} - -CIMGUI_API void igLabelText(CONST char *label, CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - ImGui::LabelTextV(label, fmt, args); - va_end(args); -} - -CIMGUI_API void igLabelTextV(CONST char *label, CONST char *fmt, va_list args) -{ - ImGui::LabelTextV(label, fmt, args); -} - -CIMGUI_API void igBullet() -{ - return ImGui::Bullet(); -} - -CIMGUI_API void igBulletText(CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - ImGui::BulletTextV(fmt, args); - va_end(args); -} - -CIMGUI_API void igBulletTextV(CONST char *fmt, va_list args) -{ - ImGui::BulletTextV(fmt, args); -} - -CIMGUI_API bool igButton(CONST char *label, CONST ImVec2 size) -{ - return ImGui::Button(label, size); -} - -CIMGUI_API bool igSmallButton(CONST char *label) -{ - return ImGui::SmallButton(label); -} - -CIMGUI_API bool igInvisibleButton(CONST char *str_id, CONST ImVec2 size) -{ - return ImGui::InvisibleButton(str_id, size); -} - -CIMGUI_API void igImage(ImTextureID user_texture_id, CONST ImVec2 size, CONST ImVec2 uv0, CONST ImVec2 uv1, CONST ImVec4 tint_col, CONST ImVec4 border_col) -{ - return ImGui::Image(user_texture_id, size, uv0, uv1, tint_col, border_col); -} - -CIMGUI_API bool igImageButton(ImTextureID user_texture_id, CONST ImVec2 size, CONST ImVec2 uv0, CONST ImVec2 uv1, int frame_padding, CONST ImVec4 bg_col, CONST ImVec4 tint_col) -{ - return ImGui::ImageButton(user_texture_id, size, uv0, uv1, frame_padding, bg_col, tint_col); -} - -CIMGUI_API bool igCheckbox(CONST char *label, bool *v) -{ - return ImGui::Checkbox(label, v); -} - -CIMGUI_API bool igCheckboxFlags(CONST char *label, unsigned int *flags, unsigned int flags_value) -{ - return ImGui::CheckboxFlags(label, flags, flags_value); -} - -CIMGUI_API bool igRadioButtonBool(CONST char *label, bool active) -{ - return ImGui::RadioButton(label, active); -} - -CIMGUI_API bool igRadioButton(CONST char *label, int *v, int v_button) -{ - return ImGui::RadioButton(label, v, v_button); -} - -CIMGUI_API void igPlotLines(CONST char *label, CONST float *values, int values_count, int values_offset, CONST char *overlay_text, float scale_min, float scale_max, ImVec2 graph_size, int stride) -{ - return ImGui::PlotLines(label, values, values_count, values_offset, overlay_text, scale_min, scale_max, graph_size, stride); -} - -CIMGUI_API void igPlotLines2(CONST char *label, float (*values_getter)(void *data, int idx), void *data, int values_count, int values_offset, CONST char *overlay_text, float scale_min, float scale_max, ImVec2 graph_size) -{ - return ImGui::PlotLines(label, values_getter, data, values_count, values_offset, overlay_text, scale_min, scale_max, graph_size); -} - -CIMGUI_API void igPlotHistogram(CONST char *label, CONST float *values, int values_count, int values_offset, CONST char *overlay_text, float scale_min, float scale_max, ImVec2 graph_size, int stride) -{ - return ImGui::PlotHistogram(label, values, values_count, values_offset, overlay_text, scale_min, scale_max, graph_size, stride); -} - -CIMGUI_API void igPlotHistogram2(CONST char *label, float (*values_getter)(void *data, int idx), void *data, int values_count, int values_offset, CONST char *overlay_text, float scale_min, float scale_max, ImVec2 graph_size) -{ - return ImGui::PlotHistogram(label, values_getter, data, values_count, values_offset, overlay_text, scale_min, scale_max, graph_size); -} - -CIMGUI_API void igProgressBar(float fraction, CONST ImVec2 *size_arg, CONST char *overlay) -{ - return ImGui::ProgressBar(fraction, *size_arg, overlay); -} - -// Widgets: Sliders (tip: ctrl+click on a slider to input text) -CIMGUI_API bool igSliderFloat(CONST char *label, float *v, float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::SliderFloat(label, v, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igSliderFloat2(CONST char *label, float v[2], float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::SliderFloat2(label, v, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igSliderFloat3(CONST char *label, float v[3], float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::SliderFloat3(label, v, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igSliderFloat4(CONST char *label, float v[4], float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::SliderFloat4(label, v, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igSliderAngle(CONST char *label, float *v_rad, float v_degrees_min, float v_degrees_max) -{ - return ImGui::SliderAngle(label, v_rad, v_degrees_min, v_degrees_max); -} - -CIMGUI_API bool igSliderInt(CONST char *label, int *v, int v_min, int v_max, CONST char *display_format) -{ - return ImGui::SliderInt(label, v, v_min, v_max, display_format); -} - -CIMGUI_API bool igSliderInt2(CONST char *label, int v[2], int v_min, int v_max, CONST char *display_format) -{ - return ImGui::SliderInt2(label, v, v_min, v_max, display_format); -} - -CIMGUI_API bool igSliderInt3(CONST char *label, int v[3], int v_min, int v_max, CONST char *display_format) -{ - return ImGui::SliderInt3(label, v, v_min, v_max, display_format); -} - -CIMGUI_API bool igSliderInt4(CONST char *label, int v[4], int v_min, int v_max, CONST char *display_format) -{ - return ImGui::SliderInt4(label, v, v_min, v_max, display_format); -} - -CIMGUI_API bool igVSliderFloat(CONST char *label, CONST ImVec2 size, float *v, float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::VSliderFloat(label, size, v, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igVSliderInt(CONST char *label, CONST ImVec2 size, int *v, int v_min, int v_max, CONST char *display_format) -{ - return ImGui::VSliderInt(label, size, v, v_min, v_max, display_format); -} - -CIMGUI_API bool igBeginCombo(CONST char *label, CONST char *preview_value, ImGuiComboFlags flags) -{ - return ImGui::BeginCombo(label, preview_value, flags); -} - -CIMGUI_API void igEndCombo() -{ - return ImGui::EndCombo(); -} - -CIMGUI_API bool igCombo(CONST char *label, int *current_item, CONST char *CONST *items, int items_count, int popup_max_height_in_items) -{ - return ImGui::Combo(label, current_item, items, items_count, popup_max_height_in_items); -} - -CIMGUI_API bool igCombo2(CONST char *label, int *current_item, CONST char *items_separated_by_zeros, int popup_max_height_in_items) -{ - return ImGui::Combo(label, current_item, items_separated_by_zeros, popup_max_height_in_items); -} - -CIMGUI_API bool igCombo3(CONST char *label, int *current_item, bool (*items_getter)(void *data, int idx, CONST char **out_text), void *data, int items_count, int popup_max_height_in_items) -{ - return ImGui::Combo(label, current_item, items_getter, data, items_count, popup_max_height_in_items); -} - -// Widgets: Color Editor/Picker (tip: the ColorEdit* functions have a little colored preview square that can be left-clicked to open a picker, and right-clicked to open an option menu.) -CIMGUI_API bool igColorEdit3(CONST char *label, float col[3], ImGuiColorEditFlags flags) -{ - return ImGui::ColorEdit3(label, col, flags); -} - -CIMGUI_API bool igColorEdit4(CONST char *label, float col[4], ImGuiColorEditFlags flags) -{ - return ImGui::ColorEdit4(label, col, flags); -} - -CIMGUI_API bool igColorPicker3(CONST char *label, float col[3], ImGuiColorEditFlags flags) -{ - return ImGui::ColorPicker3(label, col, flags); -} - -CIMGUI_API bool igColorPicker4(CONST char *label, float col[4], ImGuiColorEditFlags flags, CONST float *ref_col) -{ - return ImGui::ColorPicker4(label, col, flags, ref_col); -} - -CIMGUI_API bool igColorButton(CONST char *desc_id, CONST ImVec4 col, ImGuiColorEditFlags flags, CONST ImVec2 size) -{ - return ImGui::ColorButton(desc_id, col, flags, size); -} - -CIMGUI_API void igSetColorEditOptions(ImGuiColorEditFlags flags) -{ - return ImGui::SetColorEditOptions(flags); -} - -// Widgets: Drags (tip: ctrl+click on a drag box to input text) -CIMGUI_API bool igDragFloat(CONST char *label, float *v, float v_speed, float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::DragFloat(label, v, v_speed, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igDragFloat2(CONST char *label, float v[2], float v_speed, float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::DragFloat2(label, v, v_speed, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igDragFloat3(CONST char *label, float v[3], float v_speed, float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::DragFloat3(label, v, v_speed, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igDragFloat4(CONST char *label, float v[4], float v_speed, float v_min, float v_max, CONST char *display_format, float power) -{ - return ImGui::DragFloat4(label, v, v_speed, v_min, v_max, display_format, power); -} - -CIMGUI_API bool igDragFloatRange2(CONST char *label, float *v_current_min, float *v_current_max, float v_speed, float v_min, float v_max, CONST char *display_format, CONST char *display_format_max, float power) -{ - return ImGui::DragFloatRange2(label, v_current_min, v_current_max, v_speed, v_min, v_max, display_format, display_format_max, power); -} - -CIMGUI_API bool igDragInt(CONST char *label, int *v, float v_speed, int v_min, int v_max, CONST char *display_format) -{ - return ImGui::DragInt(label, v, v_speed, v_min, v_max, display_format); -} - -CIMGUI_API bool igDragInt2(CONST char *label, int v[2], float v_speed, int v_min, int v_max, CONST char *display_format) -{ - return ImGui::DragInt2(label, v, v_speed, v_min, v_max, display_format); -} - -CIMGUI_API bool igDragInt3(CONST char *label, int v[3], float v_speed, int v_min, int v_max, CONST char *display_format) -{ - return ImGui::DragInt3(label, v, v_speed, v_min, v_max, display_format); -} - -CIMGUI_API bool igDragInt4(CONST char *label, int v[4], float v_speed, int v_min, int v_max, CONST char *display_format) -{ - return ImGui::DragInt4(label, v, v_speed, v_min, v_max, display_format); -} - -CIMGUI_API bool igDragIntRange2(CONST char *label, int *v_current_min, int *v_current_max, float v_speed, int v_min, int v_max, CONST char *display_format, CONST char *display_format_max) -{ - return ImGui::DragIntRange2(label, v_current_min, v_current_max, v_speed, v_min, v_max, display_format, display_format_max); -} - -// Widgets: Input -CIMGUI_API bool igInputText(CONST char *label, char *buf, size_t buf_size, ImGuiInputTextFlags flags, ImGuiTextEditCallback callback, void *user_data) -{ - return ImGui::InputText(label, buf, buf_size, flags, callback, user_data); -} - -CIMGUI_API bool igInputTextMultiline(CONST char *label, char *buf, size_t buf_size, CONST ImVec2 size, ImGuiInputTextFlags flags, ImGuiTextEditCallback callback, void *user_data) -{ - return ImGui::InputTextMultiline(label, buf, buf_size, size, flags, callback, user_data); -} - -CIMGUI_API bool igInputFloat(CONST char *label, float *v, float step, float step_fast, int decimal_precision, ImGuiInputTextFlags extra_flags) -{ - return ImGui::InputFloat(label, v, step, step_fast, decimal_precision, extra_flags); -} - -CIMGUI_API bool igInputFloat2(CONST char *label, float v[2], int decimal_precision, ImGuiInputTextFlags extra_flags) -{ - return ImGui::InputFloat2(label, v, decimal_precision, extra_flags); -} - -CIMGUI_API bool igInputFloat3(CONST char *label, float v[3], int decimal_precision, ImGuiInputTextFlags extra_flags) -{ - return ImGui::InputFloat3(label, v, decimal_precision, extra_flags); -} - -CIMGUI_API bool igInputFloat4(CONST char *label, float v[4], int decimal_precision, ImGuiInputTextFlags extra_flags) -{ - return ImGui::InputFloat4(label, v, decimal_precision, extra_flags); -} - -CIMGUI_API bool igInputInt(CONST char *label, int *v, int step, int step_fast, ImGuiInputTextFlags extra_flags) -{ - return ImGui::InputInt(label, v, step, step_fast, extra_flags); -} - -CIMGUI_API bool igInputInt2(CONST char *label, int v[2], ImGuiInputTextFlags extra_flags) -{ - return ImGui::InputInt2(label, v, extra_flags); -} - -CIMGUI_API bool igInputInt3(CONST char *label, int v[3], ImGuiInputTextFlags extra_flags) -{ - return ImGui::InputInt3(label, v, extra_flags); -} - -CIMGUI_API bool igInputInt4(CONST char *label, int v[4], ImGuiInputTextFlags extra_flags) -{ - return ImGui::InputInt4(label, v, extra_flags); -} - -// Widgets: Trees -CIMGUI_API bool igTreeNode(CONST char *label) -{ - return ImGui::TreeNode(label); -} - -CIMGUI_API bool igTreeNodeStr(CONST char *str_id, CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - bool res = ImGui::TreeNodeV(str_id, fmt, args); - va_end(args); - - return res; -} - -CIMGUI_API bool igTreeNodePtr(CONST void *ptr_id, CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - bool res = ImGui::TreeNodeV(ptr_id, fmt, args); - va_end(args); - - return res; -} - -CIMGUI_API bool igTreeNodeStrV(CONST char *str_id, CONST char *fmt, va_list args) -{ - return ImGui::TreeNodeV(str_id, fmt, args); -} - -CIMGUI_API bool igTreeNodePtrV(CONST void *ptr_id, CONST char *fmt, va_list args) -{ - return ImGui::TreeNodeV(ptr_id, fmt, args); -} - -CIMGUI_API bool igTreeNodeEx(CONST char *label, ImGuiTreeNodeFlags flags) -{ - return ImGui::TreeNodeEx(label, flags); -} - -CIMGUI_API bool igTreeNodeExStr(CONST char *str_id, ImGuiTreeNodeFlags flags, CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - bool res = ImGui::TreeNodeExV(str_id, flags, fmt, args); - va_end(args); - - return res; -} - -CIMGUI_API bool igTreeNodeExPtr(CONST void *ptr_id, ImGuiTreeNodeFlags flags, CONST char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - bool res = ImGui::TreeNodeExV(ptr_id, flags, fmt, args); - va_end(args); - - return res; -} - -CIMGUI_API bool igTreeNodeExV(CONST char *str_id, ImGuiTreeNodeFlags flags, CONST char *fmt, va_list args) -{ - return ImGui::TreeNodeExV(str_id, flags, fmt, args); -} - -CIMGUI_API bool igTreeNodeExVPtr(CONST void *ptr_id, ImGuiTreeNodeFlags flags, CONST char *fmt, va_list args) -{ - return ImGui::TreeNodeExV(ptr_id, flags, fmt, args); -} - -CIMGUI_API void igTreePushStr(CONST char *str_id) -{ - return ImGui::TreePush(str_id); -} - -CIMGUI_API void igTreePushPtr(CONST void *ptr_id) -{ - return ImGui::TreePush(ptr_id); -} - -CIMGUI_API void igTreePop() -{ - return ImGui::TreePop(); -} - -CIMGUI_API void igTreeAdvanceToLabelPos() -{ - return ImGui::TreeAdvanceToLabelPos(); -} - -CIMGUI_API float igGetTreeNodeToLabelSpacing() -{ - return ImGui::GetTreeNodeToLabelSpacing(); -} - -CIMGUI_API void igSetNextTreeNodeOpen(bool opened, ImGuiCond cond) -{ - return ImGui::SetNextTreeNodeOpen(opened, cond); -} - -CIMGUI_API bool igCollapsingHeader(CONST char *label, ImGuiTreeNodeFlags flags) -{ - return ImGui::CollapsingHeader(label, flags); -} - -CIMGUI_API bool igCollapsingHeaderEx(CONST char *label, bool *p_open, ImGuiTreeNodeFlags flags) -{ - return ImGui::CollapsingHeader(label, p_open, flags); -} - -// Widgets: Selectable / Lists -CIMGUI_API bool igSelectable(CONST char *label, bool selected, ImGuiSelectableFlags flags, CONST ImVec2 size) -{ - return ImGui::Selectable(label, selected, flags, size); -} - -CIMGUI_API bool igSelectableEx(CONST char *label, bool *p_selected, ImGuiSelectableFlags flags, CONST ImVec2 size) -{ - return ImGui::Selectable(label, p_selected, flags, size); -} - -CIMGUI_API bool igListBox(CONST char *label, int *current_item, CONST char *CONST *items, int items_count, int height_in_items) -{ - return ImGui::ListBox(label, current_item, items, items_count, height_in_items); -} - -CIMGUI_API bool igListBox2(CONST char *label, int *current_item, bool (*items_getter)(void *data, int idx, CONST char **out_text), void *data, int items_count, int height_in_items) -{ - return ImGui::ListBox(label, current_item, items_getter, data, items_count, height_in_items); -} - -CIMGUI_API bool igListBoxHeader(CONST char *label, CONST ImVec2 size) -{ - return ImGui::ListBoxHeader(label, size); -} - -CIMGUI_API bool igListBoxHeader2(CONST char *label, int items_count, int height_in_items) -{ - return ImGui::ListBoxHeader(label, items_count, height_in_items); -} - -CIMGUI_API void igListBoxFooter() -{ - return ImGui::ListBoxFooter(); -} - -CIMGUI_API bool igBeginMainMenuBar() -{ - return ImGui::BeginMainMenuBar(); -} - -CIMGUI_API void igEndMainMenuBar() -{ - return ImGui::EndMainMenuBar(); -} - -CIMGUI_API bool igBeginMenuBar() -{ - return ImGui::BeginMenuBar(); -} - -CIMGUI_API void igEndMenuBar() -{ - return ImGui::EndMenuBar(); -} - -CIMGUI_API bool igBeginMenu(CONST char *label, bool enabled) -{ - return ImGui::BeginMenu(label, enabled); -} - -CIMGUI_API void igEndMenu() -{ - return ImGui::EndMenu(); -} - -CIMGUI_API bool igMenuItem(CONST char *label, CONST char *shortcut, bool selected, bool enabled) -{ - return ImGui::MenuItem(label, shortcut, selected, enabled); -} - -CIMGUI_API bool igMenuItemPtr(CONST char *label, CONST char *shortcut, bool *p_selected, bool enabled) -{ - return ImGui::MenuItem(label, shortcut, p_selected, enabled); -} - -// Widgets: Value() Helpers. Output single value in "name: value" format (tip: freely declare your own within the ImGui namespace!) -CIMGUI_API void igValueBool(CONST char *prefix, bool b) -{ - ImGui::Value(prefix, b); -} - -CIMGUI_API void igValueInt(CONST char *prefix, int v) -{ - ImGui::Value(prefix, v); -} - -CIMGUI_API void igValueUInt(CONST char *prefix, unsigned int v) -{ - ImGui::Value(prefix, v); -} - -CIMGUI_API void igValueFloat(CONST char *prefix, float v, CONST char *float_format) -{ - ImGui::Value(prefix, v, float_format); -} - -// Logging: all text output from interface is redirected to tty/file/clipboard. Tree nodes are automatically opened. -CIMGUI_API void igLogToTTY(int max_depth) -{ - ImGui::LogToTTY(max_depth); -} - -CIMGUI_API void igLogToFile(int max_depth, CONST char *filename) -{ - ImGui::LogToFile(max_depth, filename); -} - -CIMGUI_API void igLogToClipboard(int max_depth) -{ - ImGui::LogToClipboard(max_depth); -} - -CIMGUI_API void igLogFinish() -{ - ImGui::LogFinish(); -} - -CIMGUI_API void igLogButtons() -{ - ImGui::LogButtons(); -} - -CIMGUI_API void igLogText(CONST char *fmt, ...) -{ - char buffer[256]; - va_list args; - va_start(args, fmt); - vsnprintf(buffer, 256, fmt, args); - va_end(args); - - ImGui::LogText("%s", buffer); -} - -CIMGUI_API bool igBeginDragDropSource(ImGuiDragDropFlags flags) -{ - return ImGui::BeginDragDropSource(flags); -} - -CIMGUI_API bool igSetDragDropPayload(CONST char *type, CONST void *data, size_t size, ImGuiCond cond) -{ - return ImGui::SetDragDropPayload(type, data, size, cond); -} - -CIMGUI_API void igEndDragDropSource() -{ - ImGui::EndDragDropSource(); -} - -CIMGUI_API bool igBeginDragDropTarget() -{ - return ImGui::BeginDragDropTarget(); -} - -CIMGUI_API CONST struct ImGuiPayload *igAcceptDragDropPayload(CONST char *type, ImGuiDragDropFlags flags) -{ - return ImGui::AcceptDragDropPayload(type, flags); -} - -CIMGUI_API void igEndDragDropTarget() -{ - ImGui::EndDragDropTarget(); -} - -CIMGUI_API void igPushClipRect(CONST struct ImVec2 clip_rect_min, CONST struct ImVec2 clip_rect_max, bool intersect_with_current_clip_rect) -{ - return ImGui::PushClipRect(clip_rect_min, clip_rect_max, intersect_with_current_clip_rect); -} - -CIMGUI_API void igPopClipRect() -{ - return ImGui::PopClipRect(); -} - -CIMGUI_API void igStyleColorsClassic(struct ImGuiStyle *dst) -{ - ImGui::StyleColorsClassic(dst); -} - -CIMGUI_API void igStyleColorsDark(struct ImGuiStyle *dst) -{ - ImGui::StyleColorsDark(dst); -} - -CIMGUI_API void igStyleColorsLight(struct ImGuiStyle *dst) -{ - ImGui::StyleColorsLight(dst); -} - -CIMGUI_API void igSetItemDefaultFocus() -{ - ImGui::SetItemDefaultFocus(); -} - -CIMGUI_API void igSetKeyboardFocusHere(int offset) -{ - ImGui::SetKeyboardFocusHere(offset); -} - -// Utilities -CIMGUI_API bool igIsItemHovered(ImGuiHoveredFlags flags) -{ - return ImGui::IsItemHovered(flags); -} - -CIMGUI_API bool igIsItemActive() -{ - return ImGui::IsItemActive(); -} - -CIMGUI_API bool igIsItemClicked(int mouse_button) -{ - return ImGui::IsItemClicked(mouse_button); -} - -CIMGUI_API bool igIsItemVisible() -{ - return ImGui::IsItemVisible(); -} - -CIMGUI_API bool igIsAnyItemHovered() -{ - return ImGui::IsAnyItemHovered(); -} - -CIMGUI_API bool igIsAnyItemActive() -{ - return ImGui::IsAnyItemActive(); -} - -CIMGUI_API void igGetItemRectMin(ImVec2 *pOut) -{ - *pOut = ImGui::GetItemRectMin(); -} - -CIMGUI_API void igGetItemRectMax(ImVec2 *pOut) -{ - *pOut = ImGui::GetItemRectMax(); -} - -CIMGUI_API void igGetItemRectSize(ImVec2 *pOut) -{ - *pOut = ImGui::GetItemRectSize(); -} - -CIMGUI_API void igSetItemAllowOverlap() -{ - ImGui::SetItemAllowOverlap(); -} - -CIMGUI_API bool igIsWindowFocused(ImGuiFocusedFlags flags) -{ - return ImGui::IsWindowFocused(flags); -} - -CIMGUI_API bool igIsWindowHovered(ImGuiHoveredFlags flags) -{ - return ImGui::IsWindowHovered(flags); -} - -CIMGUI_API bool igIsAnyWindowFocused() -{ - return ImGui::IsAnyWindowFocused(); -} - -CIMGUI_API bool igIsAnyWindowHovered() -{ - return ImGui::IsAnyWindowHovered(); -} - -CIMGUI_API bool igIsRectVisible(CONST ImVec2 item_size) -{ - return ImGui::IsRectVisible(item_size); -} - -CIMGUI_API bool igIsRectVisible2(CONST struct ImVec2 *rect_min, CONST struct ImVec2 *rect_max) -{ - return ImGui::IsRectVisible(*rect_min, *rect_max); -} - -CIMGUI_API int igGetKeyIndex(ImGuiKey imgui_key) -{ - return ImGui::GetKeyIndex(imgui_key); -} - -CIMGUI_API bool igIsKeyDown(int user_key_index) -{ - return ImGui::IsKeyDown(user_key_index); -} - -CIMGUI_API bool igIsKeyPressed(int user_key_index, bool repeat) -{ - return ImGui::IsKeyPressed(user_key_index, repeat); -} - -CIMGUI_API bool igIsKeyReleased(int user_key_index) -{ - return ImGui::IsKeyReleased(user_key_index); -} - -CIMGUI_API int igGetKeyPressedAmount(int key_index, float repeat_delay, float rate) -{ - return ImGui::GetKeyPressedAmount(key_index, repeat_delay, rate); -} - -CIMGUI_API bool igIsMouseDown(int button) -{ - return ImGui::IsMouseDown(button); -} - -CIMGUI_API bool igIsMouseClicked(int button, bool repeat) -{ - return ImGui::IsMouseClicked(button, repeat); -} - -CIMGUI_API bool igIsMouseDoubleClicked(int button) -{ - return ImGui::IsMouseDoubleClicked(button); -} - -CIMGUI_API bool igIsMouseReleased(int button) -{ - return ImGui::IsMouseReleased(button); -} - -CIMGUI_API bool igIsMouseDragging(int button, float lock_threshold) -{ - return ImGui::IsMouseDragging(button, lock_threshold); -} - -CIMGUI_API bool igIsMouseHoveringRect(CONST ImVec2 r_min, CONST ImVec2 r_max, bool clip) -{ - return ImGui::IsMouseHoveringRect(r_min, r_max, clip); -} - -CIMGUI_API bool igIsMousePosValid(CONST struct ImVec2 *mouse_pos) -{ - return ImGui::IsMousePosValid(mouse_pos); -} - -CIMGUI_API void igGetMousePos(ImVec2 *pOut) -{ - *pOut = ImGui::GetMousePos(); -} - -CIMGUI_API void igGetMousePosOnOpeningCurrentPopup(ImVec2 *pOut) -{ - *pOut = ImGui::GetMousePosOnOpeningCurrentPopup(); -} - -CIMGUI_API void igGetMouseDragDelta(ImVec2 *pOut, int button, float lock_threshold) -{ - *pOut = ImGui::GetMouseDragDelta(button, lock_threshold); -} - -CIMGUI_API void igResetMouseDragDelta(int button) -{ - ImGui::ResetMouseDragDelta(button); -} - -CIMGUI_API ImGuiMouseCursor igGetMouseCursor() -{ - return ImGui::GetMouseCursor(); -} - -CIMGUI_API void igSetMouseCursor(ImGuiMouseCursor type) -{ - ImGui::SetMouseCursor(type); -} - -CIMGUI_API void igCaptureKeyboardFromApp(bool capture) -{ - return ImGui::CaptureKeyboardFromApp(capture); -} - -CIMGUI_API void igCaptureMouseFromApp(bool capture) -{ - return ImGui::CaptureMouseFromApp(capture); -} - -CIMGUI_API void *igMemAlloc(size_t sz) -{ - return ImGui::MemAlloc(sz); -} - -CIMGUI_API void igMemFree(void *ptr) -{ - return ImGui::MemFree(ptr); -} - -CIMGUI_API CONST char *igGetClipboardText() -{ - return ImGui::GetClipboardText(); -} - -CIMGUI_API void igSetClipboardText(CONST char *text) -{ - return ImGui::SetClipboardText(text); -} - -CIMGUI_API float igGetTime() -{ - return ImGui::GetTime(); -} - -CIMGUI_API int igGetFrameCount() -{ - return ImGui::GetFrameCount(); -} - -CIMGUI_API struct ImDrawList *igGetOverlayDrawList() -{ - return ImGui::GetOverlayDrawList(); -} - -CIMGUI_API struct ImDrawListSharedData *igGetDrawListSharedData() -{ - return ImGui::GetDrawListSharedData(); -} - -CIMGUI_API CONST char *igGetStyleColorName(ImGuiCol idx) -{ - return ImGui::GetStyleColorName(idx); -} - -CIMGUI_API void igCalcItemRectClosestPoint(ImVec2 *pOut, CONST ImVec2 pos, bool on_edge, float outward) -{ - *pOut = ImGui::CalcItemRectClosestPoint(pos, on_edge, outward); -} - -CIMGUI_API void igCalcTextSize(ImVec2 *pOut, CONST char *text, CONST char *text_end, bool hide_text_after_double_hash, float wrap_width) -{ - *pOut = ImGui::CalcTextSize(text, text_end, hide_text_after_double_hash, wrap_width); -} - -CIMGUI_API void igCalcListClipping(int items_count, float items_height, int *out_items_display_start, int *out_items_display_end) -{ - ImGui::CalcListClipping(items_count, items_height, out_items_display_start, out_items_display_end); -} - -CIMGUI_API bool igBeginChildFrame(ImGuiID id, CONST ImVec2 size, ImGuiWindowFlags extra_flags) -{ - return ImGui::BeginChildFrame(id, size, extra_flags); -} - -CIMGUI_API void igEndChildFrame() -{ - ImGui::EndChildFrame(); -} - -CIMGUI_API void igColorConvertU32ToFloat4(ImVec4 *pOut, ImU32 in) -{ - *pOut = ImGui::ColorConvertU32ToFloat4(in); -} - -CIMGUI_API ImU32 igColorConvertFloat4ToU32(CONST ImVec4 in) -{ - return ImGui::ColorConvertFloat4ToU32(in); -} - -CIMGUI_API void igColorConvertRGBtoHSV(float r, float g, float b, float *out_h, float *out_s, float *out_v) -{ - ImGui::ColorConvertRGBtoHSV(r, g, b, *out_h, *out_s, *out_v); -} - -CIMGUI_API void igColorConvertHSVtoRGB(float h, float s, float v, float *out_r, float *out_g, float *out_b) -{ - ImGui::ColorConvertHSVtoRGB(h, s, v, *out_r, *out_g, *out_b); -} - -CIMGUI_API CONST char *igGetVersion() -{ - return ImGui::GetVersion(); -} - -CIMGUI_API ImGuiContext *igCreateContext(struct ImFontAtlas* shared_font_atlas) -{ - return ImGui::CreateContext(shared_font_atlas); -} - -CIMGUI_API void igDestroyContext(ImGuiContext *ctx) -{ - return ImGui::DestroyContext(ctx); -} - -CIMGUI_API ImGuiContext *igGetCurrentContext() -{ - return ImGui::GetCurrentContext(); -} - -CIMGUI_API void igSetCurrentContext(ImGuiContext *ctx) -{ - return ImGui::SetCurrentContext(ctx); -} - -CIMGUI_API void ImGuiIO_AddInputCharacter(unsigned short c) -{ - ImGui::GetIO().AddInputCharacter(c); -} - -CIMGUI_API void ImGuiIO_AddInputCharactersUTF8(CONST char *utf8_chars) -{ - return ImGui::GetIO().AddInputCharactersUTF8(utf8_chars); -} - -CIMGUI_API void ImGuiIO_ClearInputCharacters() -{ - return ImGui::GetIO().ClearInputCharacters(); -} - -CIMGUI_API struct ImGuiTextFilter *ImGuiTextFilter_Create(const char *default_filter) -{ - ImGuiTextFilter *filter = (ImGuiTextFilter *)ImGui::MemAlloc(sizeof(ImGuiTextFilter)); - IM_PLACEMENT_NEW(filter) - ImGuiTextFilter(default_filter); - return filter; -} - -CIMGUI_API void ImGuiTextFilter_Destroy(struct ImGuiTextFilter *filter) -{ - filter->~ImGuiTextFilter(); - ImGui::MemFree(filter); -} - -CIMGUI_API void ImGuiTextFilter_Clear(struct ImGuiTextFilter *filter) -{ - filter->Clear(); -} - -CIMGUI_API bool ImGuiTextFilter_Draw(struct ImGuiTextFilter *filter, const char *label, float width) -{ - return filter->Draw(label, width); -} - -CIMGUI_API bool ImGuiTextFilter_PassFilter(const struct ImGuiTextFilter *filter, const char *text, const char *text_end) -{ - return filter->PassFilter(text, text_end); -} - -CIMGUI_API bool ImGuiTextFilter_IsActive(const struct ImGuiTextFilter *filter) -{ - return filter->IsActive(); -} - -CIMGUI_API void ImGuiTextFilter_Build(struct ImGuiTextFilter *filter) -{ - filter->Build(); -} - -CIMGUI_API const char *ImGuiTextFilter_GetInputBuf(struct ImGuiTextFilter *filter) -{ - return filter->InputBuf; -} - -CIMGUI_API struct ImGuiTextBuffer *ImGuiTextBuffer_Create() -{ - ImGuiTextBuffer *buffer = (ImGuiTextBuffer *)ImGui::MemAlloc(sizeof(ImGuiTextBuffer)); - IM_PLACEMENT_NEW(buffer) - ImGuiTextBuffer(); - return buffer; -} - -CIMGUI_API void ImGuiTextBuffer_Destroy(struct ImGuiTextBuffer *buffer) -{ - buffer->~ImGuiTextBuffer(); - ImGui::MemFree(buffer); -} - -CIMGUI_API char ImGuiTextBuffer_index(struct ImGuiTextBuffer *buffer, int i) -{ - return (*buffer)[i]; -} - -CIMGUI_API const char *ImGuiTextBuffer_begin(const struct ImGuiTextBuffer *buffer) -{ - return buffer->begin(); -} - -CIMGUI_API const char *ImGuiTextBuffer_end(const struct ImGuiTextBuffer *buffer) -{ - return buffer->end(); -} - -CIMGUI_API int ImGuiTextBuffer_size(const struct ImGuiTextBuffer *buffer) -{ - return buffer->size(); -} - -CIMGUI_API bool ImGuiTextBuffer_empty(struct ImGuiTextBuffer *buffer) -{ - return buffer->empty(); -} - -CIMGUI_API void ImGuiTextBuffer_clear(struct ImGuiTextBuffer *buffer) -{ - buffer->clear(); -} - -CIMGUI_API const char *ImGuiTextBuffer_c_str(const struct ImGuiTextBuffer *buffer) -{ - return buffer->c_str(); -} - -CIMGUI_API void ImGuiTextBuffer_appendf(struct ImGuiTextBuffer *buffer, const char *fmt, ...) -{ - va_list args; - va_start(args, fmt); - buffer->appendfv(fmt, args); - va_end(args); -} - -CIMGUI_API void ImGuiTextBuffer_appendfv(struct ImGuiTextBuffer *buffer, const char *fmt, va_list args) -{ - buffer->appendfv(fmt, args); -} - -CIMGUI_API struct ImGuiStorage *ImGuiStorage_Create() -{ - ImGuiStorage *storage = (ImGuiStorage *)ImGui::MemAlloc(sizeof(ImGuiStorage)); - IM_PLACEMENT_NEW(storage) - ImGuiStorage(); - return storage; -} - -CIMGUI_API void ImGuiStorage_Destroy(struct ImGuiStorage *storage) -{ - storage->~ImGuiStorage(); - ImGui::MemFree(storage); -} - -CIMGUI_API void ImGuiStorage_Clear(struct ImGuiStorage *storage) -{ - storage->Clear(); -} - -CIMGUI_API int ImGuiStorage_GetInt(struct ImGuiStorage *storage, ImGuiID key, int default_val) -{ - return storage->GetInt(key, default_val); -} - -CIMGUI_API void ImGuiStorage_SetInt(struct ImGuiStorage *storage, ImGuiID key, int val) -{ - storage->SetInt(key, val); -} - -CIMGUI_API bool ImGuiStorage_GetBool(struct ImGuiStorage *storage, ImGuiID key, bool default_val) -{ - return storage->GetBool(key, default_val); -} - -CIMGUI_API void ImGuiStorage_SetBool(struct ImGuiStorage *storage, ImGuiID key, bool val) -{ - storage->SetBool(key, val); -} - -CIMGUI_API float ImGuiStorage_GetFloat(struct ImGuiStorage *storage, ImGuiID key, float default_val) -{ - return storage->GetFloat(key, default_val); -} - -CIMGUI_API void ImGuiStorage_SetFloat(struct ImGuiStorage *storage, ImGuiID key, float val) -{ - storage->SetFloat(key, val); -} - -CIMGUI_API void *ImGuiStorage_GetVoidPtr(struct ImGuiStorage *storage, ImGuiID key) -{ - return storage->GetVoidPtr(key); -} - -CIMGUI_API void ImGuiStorage_SetVoidPtr(struct ImGuiStorage *storage, ImGuiID key, void *val) -{ - storage->SetVoidPtr(key, val); -} - -CIMGUI_API int *ImGuiStorage_GetIntRef(struct ImGuiStorage *storage, ImGuiID key, int default_val) -{ - return storage->GetIntRef(key, default_val); -} - -CIMGUI_API bool *ImGuiStorage_GetBoolRef(struct ImGuiStorage *storage, ImGuiID key, bool default_val) -{ - return storage->GetBoolRef(key, default_val); -} - -CIMGUI_API float *ImGuiStorage_GetFloatRef(struct ImGuiStorage *storage, ImGuiID key, float default_val) -{ - return storage->GetFloatRef(key, default_val); -} - -CIMGUI_API void **ImGuiStorage_GetVoidPtrRef(struct ImGuiStorage *storage, ImGuiID key, void *default_val) -{ - return storage->GetVoidPtrRef(key, default_val); -} - -CIMGUI_API void ImGuiStorage_SetAllInt(struct ImGuiStorage *storage, int val) -{ - storage->SetAllInt(val); -} - -CIMGUI_API void ImGuiTextEditCallbackData_DeleteChars(struct ImGuiTextEditCallbackData *data, int pos, int bytes_count) -{ - data->DeleteChars(pos, bytes_count); -} - -CIMGUI_API void ImGuiTextEditCallbackData_InsertChars(struct ImGuiTextEditCallbackData *data, int pos, const char *text, const char *text_end) -{ - data->InsertChars(pos, text, text_end); -} - -CIMGUI_API bool ImGuiTextEditCallbackData_HasSelection(struct ImGuiTextEditCallbackData *data) -{ - return data->HasSelection(); -} +#include "auto_funcs.cpp" diff --git a/cimgui/cimgui.h b/cimgui/cimgui.h index 2179ec1..f2e7dcd 100644 --- a/cimgui/cimgui.h +++ b/cimgui/cimgui.h @@ -25,58 +25,7 @@ #define CIMGUI_API EXTERN API #define CONST const -struct ImGuiIO; -struct ImGuiStyle; -struct ImDrawData; -struct ImVec2; -struct ImVec4; -struct ImGuiTextEditCallbackData; -struct ImGuiSizeCallbackData; -struct ImDrawList; -struct ImGuiStorage; -struct ImFont; -struct ImFontConfig; -struct ImFontAtlas; -struct ImDrawCmd; -struct ImGuiListClipper; -struct ImGuiTextFilter; -struct ImGuiPayload; -#if defined __cplusplus -#define IMFONTGLYPH ImFontGlyph -#else -//struct Glyph; -#define IMFONTGLYPH ImFontGlyph -#endif - -typedef unsigned short ImDrawIdx; -typedef unsigned int ImU32; -typedef unsigned short ImWchar; -typedef void *ImTextureID; -typedef ImU32 ImGuiID; -typedef int ImGuiCol; -typedef int ImGuiStyleVar; -typedef int ImGuiKey; -typedef int ImGuiColorEditFlags; -typedef int ImGuiMouseCursor; -typedef int ImGuiWindowFlags; -typedef int ImGuiCond; -typedef int ImGuiColumnsFlags; -typedef int ImGuiConfigFlags; -typedef int ImGuiBackendFlags; -typedef int ImGuiInputTextFlags; -typedef int ImGuiSelectableFlags; -typedef int ImGuiTreeNodeFlags; -typedef int ImGuiHoveredFlags; -typedef int ImGuiNavFlags; -typedef int ImGuiComboFlags; -typedef int ImGuiDragDropFlags; -typedef int ImGuiFocusedFlags; -typedef int ImDrawCornerFlags; -typedef int ImDrawListFlags; -typedef int (*ImGuiTextEditCallback)(struct ImGuiTextEditCallbackData *data); -typedef void (*ImGuiSizeCallback)(struct ImGuiSizeCallbackData *data); -typedef void (*ImDrawCallback)(CONST struct ImDrawList *parent_list, CONST struct ImDrawCmd *cmd); #ifdef _MSC_VER typedef unsigned __int64 ImU64; #else @@ -87,593 +36,4 @@ typedef unsigned long long ImU64; #include "imgui_structs.h" #endif // CIMGUI_DEFINE_ENUMS_AND_STRUCTS -// Main -CIMGUI_API struct ImGuiIO *igGetIO(); -CIMGUI_API struct ImGuiStyle *igGetStyle(); -CIMGUI_API struct ImDrawData *igGetDrawData(); -CIMGUI_API void igNewFrame(); -CIMGUI_API void igRender(); -CIMGUI_API void igEndFrame(); - - -// Demo/Debug/Info -CIMGUI_API void igShowDemoWindow(bool *opened); -CIMGUI_API void igShowMetricsWindow(bool *opened); -CIMGUI_API void igShowStyleEditor(struct ImGuiStyle *ref); -CIMGUI_API void igShowStyleSelector(CONST char *label); -CIMGUI_API void igShowFontSelector(CONST char *label); -CIMGUI_API void igShowUserGuide(); - -// Window -CIMGUI_API bool igBegin(CONST char *name, bool *p_open, ImGuiWindowFlags flags); -//Is going to be obsolete, -//CIMGUI_API bool igBegin2(CONST char* name, bool* p_open, CONST struct ImVec2 size_on_first_use, float bg_alpha, ImGuiWindowFlags flags); -CIMGUI_API void igEnd(); -CIMGUI_API bool igBeginChild(CONST char *str_id, CONST struct ImVec2 size, bool border, ImGuiWindowFlags extra_flags); -CIMGUI_API bool igBeginChildEx(ImGuiID id, CONST struct ImVec2 size, bool border, ImGuiWindowFlags extra_flags); -CIMGUI_API void igEndChild(); -CIMGUI_API void igGetContentRegionMax(struct ImVec2 *out); -CIMGUI_API void igGetContentRegionAvail(struct ImVec2 *out); -CIMGUI_API float igGetContentRegionAvailWidth(); -CIMGUI_API void igGetWindowContentRegionMin(struct ImVec2 *out); -CIMGUI_API void igGetWindowContentRegionMax(struct ImVec2 *out); -CIMGUI_API float igGetWindowContentRegionWidth(); -CIMGUI_API struct ImDrawList *igGetWindowDrawList(); -CIMGUI_API void igGetWindowPos(struct ImVec2 *out); -CIMGUI_API void igGetWindowSize(struct ImVec2 *out); -CIMGUI_API float igGetWindowWidth(); -CIMGUI_API float igGetWindowHeight(); -CIMGUI_API bool igIsWindowCollapsed(); -CIMGUI_API bool igIsWindowAppearing(); -CIMGUI_API void igSetWindowFontScale(float scale); - -CIMGUI_API void igSetNextWindowPos(CONST struct ImVec2 pos, ImGuiCond cond, CONST struct ImVec2 pivot); -CIMGUI_API void igSetNextWindowSize(CONST struct ImVec2 size, ImGuiCond cond); -CIMGUI_API void igSetNextWindowSizeConstraints(CONST struct ImVec2 size_min, CONST struct ImVec2 size_max, ImGuiSizeCallback custom_callback, void *custom_callback_data); -CIMGUI_API void igSetNextWindowContentSize(CONST struct ImVec2 size); -CIMGUI_API void igSetNextWindowCollapsed(bool collapsed, ImGuiCond cond); -CIMGUI_API void igSetNextWindowFocus(); -CIMGUI_API void igSetWindowPos(CONST struct ImVec2 pos, ImGuiCond cond); -CIMGUI_API void igSetWindowSize(CONST struct ImVec2 size, ImGuiCond cond); -CIMGUI_API void igSetWindowCollapsed(bool collapsed, ImGuiCond cond); -CIMGUI_API void igSetWindowFocus(); -CIMGUI_API void igSetWindowPosByName(CONST char *name, CONST struct ImVec2 pos, ImGuiCond cond); -CIMGUI_API void igSetWindowSize2(CONST char *name, CONST struct ImVec2 size, ImGuiCond cond); -CIMGUI_API void igSetWindowCollapsed2(CONST char *name, bool collapsed, ImGuiCond cond); -CIMGUI_API void igSetWindowFocus2(CONST char *name); - -CIMGUI_API float igGetScrollX(); -CIMGUI_API float igGetScrollY(); -CIMGUI_API float igGetScrollMaxX(); -CIMGUI_API float igGetScrollMaxY(); -CIMGUI_API void igSetScrollX(float scroll_x); -CIMGUI_API void igSetScrollY(float scroll_y); -CIMGUI_API void igSetScrollHere(float center_y_ratio); -CIMGUI_API void igSetScrollFromPosY(float pos_y, float center_y_ratio); -CIMGUI_API void igSetStateStorage(struct ImGuiStorage *tree); -CIMGUI_API struct ImGuiStorage *igGetStateStorage(); - -// Parameters stacks (shared) -CIMGUI_API void igPushFont(struct ImFont *font); -CIMGUI_API void igPopFont(); -CIMGUI_API void igPushStyleColorU32(ImGuiCol idx, ImU32 col); -CIMGUI_API void igPushStyleColor(ImGuiCol idx, CONST struct ImVec4 col); -CIMGUI_API void igPopStyleColor(int count); -CIMGUI_API void igPushStyleVar(ImGuiStyleVar idx, float val); -CIMGUI_API void igPushStyleVarVec(ImGuiStyleVar idx, CONST struct ImVec2 val); -CIMGUI_API void igPopStyleVar(int count); -CIMGUI_API void igGetStyleColorVec4(struct ImVec4 *pOut, ImGuiCol idx); -CIMGUI_API struct ImFont *igGetFont(); -CIMGUI_API float igGetFontSize(); -CIMGUI_API void igGetFontTexUvWhitePixel(struct ImVec2 *pOut); -CIMGUI_API ImU32 igGetColorU32(ImGuiCol idx, float alpha_mul); -CIMGUI_API ImU32 igGetColorU32Vec(CONST struct ImVec4 *col); -CIMGUI_API ImU32 igGetColorU32U32(ImU32 col); - -// Parameters stacks (current window) -CIMGUI_API void igPushItemWidth(float item_width); -CIMGUI_API void igPopItemWidth(); -CIMGUI_API float igCalcItemWidth(); -CIMGUI_API void igPushTextWrapPos(float wrap_pos_x); -CIMGUI_API void igPopTextWrapPos(); -CIMGUI_API void igPushAllowKeyboardFocus(bool v); -CIMGUI_API void igPopAllowKeyboardFocus(); -CIMGUI_API void igPushButtonRepeat(bool repeat); -CIMGUI_API void igPopButtonRepeat(); - -// Cursor / Layout -CIMGUI_API void igSeparator(); -CIMGUI_API void igSameLine(float pos_x, float spacing_w); -CIMGUI_API void igNewLine(); -CIMGUI_API void igSpacing(); -CIMGUI_API void igDummy(CONST struct ImVec2 *size); -CIMGUI_API void igIndent(float indent_w); -CIMGUI_API void igUnindent(float indent_w); -CIMGUI_API void igBeginGroup(); -CIMGUI_API void igEndGroup(); -CIMGUI_API void igGetCursorPos(struct ImVec2 *pOut); -CIMGUI_API float igGetCursorPosX(); -CIMGUI_API float igGetCursorPosY(); -CIMGUI_API void igSetCursorPos(CONST struct ImVec2 local_pos); -CIMGUI_API void igSetCursorPosX(float x); -CIMGUI_API void igSetCursorPosY(float y); -CIMGUI_API void igGetCursorStartPos(struct ImVec2 *pOut); -CIMGUI_API void igGetCursorScreenPos(struct ImVec2 *pOut); -CIMGUI_API void igSetCursorScreenPos(CONST struct ImVec2 pos); -CIMGUI_API void igAlignTextToFramePadding(); -CIMGUI_API float igGetTextLineHeight(); -CIMGUI_API float igGetTextLineHeightWithSpacing(); -CIMGUI_API float igGetFrameHeight(); -CIMGUI_API float igGetFrameHeightWithSpacing(); - -//Columns -CIMGUI_API void igColumns(int count, CONST char *id, bool border); -CIMGUI_API void igNextColumn(); -CIMGUI_API int igGetColumnIndex(); -CIMGUI_API float igGetColumnWidth(int column_index); // get column width (in pixels). pass -1 to use current column -CIMGUI_API void igSetColumnWidth(int column_index, float width); -CIMGUI_API float igGetColumnOffset(int column_index); -CIMGUI_API void igSetColumnOffset(int column_index, float offset_x); -CIMGUI_API int igGetColumnsCount(); - -// ID scopes -// If you are creating widgets in a loop you most likely want to push a unique identifier so ImGui can differentiate them -// You can also use "##extra" within your widget name to distinguish them from each others (see 'Programmer Guide') -CIMGUI_API void igPushIDStr(CONST char *str_id); -CIMGUI_API void igPushIDStrRange(CONST char *str_begin, CONST char *str_end); -CIMGUI_API void igPushIDPtr(CONST void *ptr_id); -CIMGUI_API void igPushIDInt(int int_id); -CIMGUI_API void igPopID(); -CIMGUI_API ImGuiID igGetIDStr(CONST char *str_id); -CIMGUI_API ImGuiID igGetIDStrRange(CONST char *str_begin, CONST char *str_end); -CIMGUI_API ImGuiID igGetIDPtr(CONST void *ptr_id); - -// Widgets: Text -CIMGUI_API void igTextUnformatted(CONST char *text, CONST char *text_end); -CIMGUI_API void igText(CONST char *fmt, ...); -CIMGUI_API void igTextV(CONST char *fmt, va_list args); -CIMGUI_API void igTextColored(CONST struct ImVec4 col, CONST char *fmt, ...); -CIMGUI_API void igTextColoredV(CONST struct ImVec4 col, CONST char *fmt, va_list args); -CIMGUI_API void igTextDisabled(CONST char *fmt, ...); -CIMGUI_API void igTextDisabledV(CONST char *fmt, va_list args); -CIMGUI_API void igTextWrapped(CONST char *fmt, ...); -CIMGUI_API void igTextWrappedV(CONST char *fmt, va_list args); -CIMGUI_API void igLabelText(CONST char *label, CONST char *fmt, ...); -CIMGUI_API void igLabelTextV(CONST char *label, CONST char *fmt, va_list args); -CIMGUI_API void igBulletText(CONST char *fmt, ...); -CIMGUI_API void igBulletTextV(CONST char *fmt, va_list args); -CIMGUI_API void igBullet(); - -// Widgets: Main -CIMGUI_API bool igButton(CONST char *label, CONST struct ImVec2 size); -CIMGUI_API bool igSmallButton(CONST char *label); -CIMGUI_API bool igInvisibleButton(CONST char *str_id, CONST struct ImVec2 size); -CIMGUI_API void igImage(ImTextureID user_texture_id, CONST struct ImVec2 size, CONST struct ImVec2 uv0, CONST struct ImVec2 uv1, CONST struct ImVec4 tint_col, CONST struct ImVec4 border_col); -CIMGUI_API bool igImageButton(ImTextureID user_texture_id, CONST struct ImVec2 size, CONST struct ImVec2 uv0, CONST struct ImVec2 uv1, int frame_padding, CONST struct ImVec4 bg_col, CONST struct ImVec4 tint_col); -CIMGUI_API bool igCheckbox(CONST char *label, bool *v); -CIMGUI_API bool igCheckboxFlags(CONST char *label, unsigned int *flags, unsigned int flags_value); -CIMGUI_API bool igRadioButtonBool(CONST char *label, bool active); -CIMGUI_API bool igRadioButton(CONST char *label, int *v, int v_button); -CIMGUI_API void igPlotLines(CONST char *label, CONST float *values, int values_count, int values_offset, CONST char *overlay_text, float scale_min, float scale_max, struct ImVec2 graph_size, int stride); -CIMGUI_API void igPlotLines2(CONST char *label, float (*values_getter)(void *data, int idx), void *data, int values_count, int values_offset, CONST char *overlay_text, float scale_min, float scale_max, struct ImVec2 graph_size); -CIMGUI_API void igPlotHistogram(CONST char *label, CONST float *values, int values_count, int values_offset, CONST char *overlay_text, float scale_min, float scale_max, struct ImVec2 graph_size, int stride); -CIMGUI_API void igPlotHistogram2(CONST char *label, float (*values_getter)(void *data, int idx), void *data, int values_count, int values_offset, CONST char *overlay_text, float scale_min, float scale_max, struct ImVec2 graph_size); -CIMGUI_API void igProgressBar(float fraction, CONST struct ImVec2 *size_arg, CONST char *overlay); - -CIMGUI_API bool igBeginCombo(CONST char *label, CONST char *preview_value, ImGuiComboFlags flags); -CIMGUI_API void igEndCombo(); -CIMGUI_API bool igCombo(CONST char *label, int *current_item, CONST char *CONST *items, int items_count, int popup_max_height_in_items); -CIMGUI_API bool igCombo2(CONST char *label, int *current_item, CONST char *items_separated_by_zeros, int popup_max_height_in_items); -CIMGUI_API bool igCombo3(CONST char *label, int *current_item, bool (*items_getter)(void *data, int idx, CONST char **out_text), void *data, int items_count, int popup_max_height_in_items); - -// Widgets: Drags (tip: ctrl+click on a drag box to input with keyboard. manually input values aren't clamped, can go off-bounds) -// For all the Float2/Float3/Float4/Int2/Int3/Int4 versions of every functions, note that a 'float v[X]' function argument is the same as 'float* v', the array syntax is just a way to document the number of elements that are expected to be accessible. You can pass address of your first element out of a contiguous set, e.g. &myvector.x -CIMGUI_API bool igDragFloat(CONST char *label, float *v, float v_speed, float v_min, float v_max, CONST char *display_format, float power); // If v_max >= v_max we have no bound -CIMGUI_API bool igDragFloat2(CONST char *label, float v[2], float v_speed, float v_min, float v_max, CONST char *display_format, float power); -CIMGUI_API bool igDragFloat3(CONST char *label, float v[3], float v_speed, float v_min, float v_max, CONST char *display_format, float power); -CIMGUI_API bool igDragFloat4(CONST char *label, float v[4], float v_speed, float v_min, float v_max, CONST char *display_format, float power); -CIMGUI_API bool igDragFloatRange2(CONST char *label, float *v_current_min, float *v_current_max, float v_speed, float v_min, float v_max, CONST char *display_format, CONST char *display_format_max, float power); -CIMGUI_API bool igDragInt(CONST char *label, int *v, float v_speed, int v_min, int v_max, CONST char *display_format); // If v_max >= v_max we have no bound -CIMGUI_API bool igDragInt2(CONST char *label, int v[2], float v_speed, int v_min, int v_max, CONST char *display_format); -CIMGUI_API bool igDragInt3(CONST char *label, int v[3], float v_speed, int v_min, int v_max, CONST char *display_format); -CIMGUI_API bool igDragInt4(CONST char *label, int v[4], float v_speed, int v_min, int v_max, CONST char *display_format); -CIMGUI_API bool igDragIntRange2(CONST char *label, int *v_current_min, int *v_current_max, float v_speed, int v_min, int v_max, CONST char *display_format, CONST char *display_format_max); - -// Widgets: Input with Keyboard -CIMGUI_API bool igInputText(CONST char *label, char *buf, size_t buf_size, ImGuiInputTextFlags flags, ImGuiTextEditCallback callback, void *user_data); -CIMGUI_API bool igInputTextMultiline(CONST char *label, char *buf, size_t buf_size, CONST struct ImVec2 size, ImGuiInputTextFlags flags, ImGuiTextEditCallback callback, void *user_data); -CIMGUI_API bool igInputFloat(CONST char *label, float *v, float step, float step_fast, int decimal_precision, ImGuiInputTextFlags extra_flags); -CIMGUI_API bool igInputFloat2(CONST char *label, float v[2], int decimal_precision, ImGuiInputTextFlags extra_flags); -CIMGUI_API bool igInputFloat3(CONST char *label, float v[3], int decimal_precision, ImGuiInputTextFlags extra_flags); -CIMGUI_API bool igInputFloat4(CONST char *label, float v[4], int decimal_precision, ImGuiInputTextFlags extra_flags); -CIMGUI_API bool igInputInt(CONST char *label, int *v, int step, int step_fast, ImGuiInputTextFlags extra_flags); -CIMGUI_API bool igInputInt2(CONST char *label, int v[2], ImGuiInputTextFlags extra_flags); -CIMGUI_API bool igInputInt3(CONST char *label, int v[3], ImGuiInputTextFlags extra_flags); -CIMGUI_API bool igInputInt4(CONST char *label, int v[4], ImGuiInputTextFlags extra_flags); - -// Widgets: Sliders (tip: ctrl+click on a slider to input with keyboard. manually input values aren't clamped, can go off-bounds) -CIMGUI_API bool igSliderFloat(CONST char *label, float *v, float v_min, float v_max, CONST char *display_format, float power); -CIMGUI_API bool igSliderFloat2(CONST char *label, float v[2], float v_min, float v_max, CONST char *display_format, float power); -CIMGUI_API bool igSliderFloat3(CONST char *label, float v[3], float v_min, float v_max, CONST char *display_format, float power); -CIMGUI_API bool igSliderFloat4(CONST char *label, float v[4], float v_min, float v_max, CONST char *display_format, float power); -CIMGUI_API bool igSliderAngle(CONST char *label, float *v_rad, float v_degrees_min, float v_degrees_max); -CIMGUI_API bool igSliderInt(CONST char *label, int *v, int v_min, int v_max, CONST char *display_format); -CIMGUI_API bool igSliderInt2(CONST char *label, int v[2], int v_min, int v_max, CONST char *display_format); -CIMGUI_API bool igSliderInt3(CONST char *label, int v[3], int v_min, int v_max, CONST char *display_format); -CIMGUI_API bool igSliderInt4(CONST char *label, int v[4], int v_min, int v_max, CONST char *display_format); -CIMGUI_API bool igVSliderFloat(CONST char *label, CONST struct ImVec2 size, float *v, float v_min, float v_max, CONST char *display_format, float power); -CIMGUI_API bool igVSliderInt(CONST char *label, CONST struct ImVec2 size, int *v, int v_min, int v_max, CONST char *display_format); - -// Widgets: Color Editor/Picker (tip: the ColorEdit* functions have a little colored preview square that can be left-clicked to open a picker, and right-clicked to open an option menu.) -// Note that a 'float v[X]' function argument is the same as 'float* v', the array syntax is just a way to document the number of elements that are expected to be accessible. You can the pass the address of a first float element out of a contiguous structure, e.g. &myvector.x -CIMGUI_API bool igColorEdit3(CONST char *label, float col[3], ImGuiColorEditFlags flags); -CIMGUI_API bool igColorEdit4(CONST char *label, float col[4], ImGuiColorEditFlags flags); -CIMGUI_API bool igColorPicker3(CONST char *label, float col[3], ImGuiColorEditFlags flags); -CIMGUI_API bool igColorPicker4(CONST char *label, float col[4], ImGuiColorEditFlags flags, CONST float *ref_col); -CIMGUI_API bool igColorButton(CONST char *desc_id, CONST struct ImVec4 col, ImGuiColorEditFlags flags, CONST struct ImVec2 size); -CIMGUI_API void igSetColorEditOptions(ImGuiColorEditFlags flags); - -// Widgets: Trees -CIMGUI_API bool igTreeNode(CONST char *label); -CIMGUI_API bool igTreeNodeStr(CONST char *str_id, CONST char *fmt, ...); -CIMGUI_API bool igTreeNodePtr(CONST void *ptr_id, CONST char *fmt, ...); -CIMGUI_API bool igTreeNodeStrV(CONST char *str_id, CONST char *fmt, va_list args); -CIMGUI_API bool igTreeNodePtrV(CONST void *ptr_id, CONST char *fmt, va_list args); -CIMGUI_API bool igTreeNodeEx(CONST char *label, ImGuiTreeNodeFlags flags); -CIMGUI_API bool igTreeNodeExStr(CONST char *str_id, ImGuiTreeNodeFlags flags, CONST char *fmt, ...); -CIMGUI_API bool igTreeNodeExPtr(CONST void *ptr_id, ImGuiTreeNodeFlags flags, CONST char *fmt, ...); -CIMGUI_API bool igTreeNodeExV(CONST char *str_id, ImGuiTreeNodeFlags flags, CONST char *fmt, va_list args); -CIMGUI_API bool igTreeNodeExVPtr(CONST void *ptr_id, ImGuiTreeNodeFlags flags, CONST char *fmt, va_list args); -CIMGUI_API void igTreePushStr(CONST char *str_id); -CIMGUI_API void igTreePushPtr(CONST void *ptr_id); -CIMGUI_API void igTreePop(); -CIMGUI_API void igTreeAdvanceToLabelPos(); -CIMGUI_API float igGetTreeNodeToLabelSpacing(); -CIMGUI_API void igSetNextTreeNodeOpen(bool opened, ImGuiCond cond); -CIMGUI_API bool igCollapsingHeader(CONST char *label, ImGuiTreeNodeFlags flags); -CIMGUI_API bool igCollapsingHeaderEx(CONST char *label, bool *p_open, ImGuiTreeNodeFlags flags); - -// Widgets: Selectable / Lists -CIMGUI_API bool igSelectable(CONST char *label, bool selected, ImGuiSelectableFlags flags, CONST struct ImVec2 size); -CIMGUI_API bool igSelectableEx(CONST char *label, bool *p_selected, ImGuiSelectableFlags flags, CONST struct ImVec2 size); -CIMGUI_API bool igListBox(CONST char *label, int *current_item, CONST char *CONST *items, int items_count, int height_in_items); -CIMGUI_API bool igListBox2(CONST char *label, int *current_item, bool (*items_getter)(void *data, int idx, CONST char **out_text), void *data, int items_count, int height_in_items); -CIMGUI_API bool igListBoxHeader(CONST char *label, CONST struct ImVec2 size); -CIMGUI_API bool igListBoxHeader2(CONST char *label, int items_count, int height_in_items); -CIMGUI_API void igListBoxFooter(); - -// Widgets: Value() Helpers. Output single value in "name: value" format (tip: freely declare your own within the ImGui namespace!) -CIMGUI_API void igValueBool(CONST char *prefix, bool b); -CIMGUI_API void igValueInt(CONST char *prefix, int v); -CIMGUI_API void igValueUInt(CONST char *prefix, unsigned int v); -CIMGUI_API void igValueFloat(CONST char *prefix, float v, CONST char *float_format); - -// Tooltip -CIMGUI_API void igSetTooltip(CONST char *fmt, ...); -CIMGUI_API void igSetTooltipV(CONST char *fmt, va_list args); -CIMGUI_API void igBeginTooltip(); -CIMGUI_API void igEndTooltip(); - -// Widgets: Menus -CIMGUI_API bool igBeginMainMenuBar(); -CIMGUI_API void igEndMainMenuBar(); -CIMGUI_API bool igBeginMenuBar(); -CIMGUI_API void igEndMenuBar(); -CIMGUI_API bool igBeginMenu(CONST char *label, bool enabled); -CIMGUI_API void igEndMenu(); -CIMGUI_API bool igMenuItem(CONST char *label, CONST char *shortcut, bool selected, bool enabled); -CIMGUI_API bool igMenuItemPtr(CONST char *label, CONST char *shortcut, bool *p_selected, bool enabled); - -// Popup -CIMGUI_API void igOpenPopup(CONST char *str_id); -CIMGUI_API bool igOpenPopupOnItemClick(CONST char *str_id, int mouse_button); -CIMGUI_API bool igBeginPopup(CONST char *str_id); -CIMGUI_API bool igBeginPopupModal(CONST char *name, bool *p_open, ImGuiWindowFlags extra_flags); -CIMGUI_API bool igBeginPopupContextItem(CONST char *str_id, int mouse_button); -CIMGUI_API bool igBeginPopupContextWindow(CONST char *str_id, int mouse_button, bool also_over_items); -CIMGUI_API bool igBeginPopupContextVoid(CONST char *str_id, int mouse_button); -CIMGUI_API void igEndPopup(); -CIMGUI_API bool igIsPopupOpen(CONST char *str_id); -CIMGUI_API void igCloseCurrentPopup(); - -// Logging: all text output from interface is redirected to tty/file/clipboard. Tree nodes are automatically opened. -CIMGUI_API void igLogToTTY(int max_depth); -CIMGUI_API void igLogToFile(int max_depth, CONST char *filename); -CIMGUI_API void igLogToClipboard(int max_depth); -CIMGUI_API void igLogFinish(); -CIMGUI_API void igLogButtons(); -CIMGUI_API void igLogText(CONST char *fmt, ...); - -CIMGUI_API bool igBeginDragDropSource(ImGuiDragDropFlags flags); -CIMGUI_API bool igSetDragDropPayload(CONST char *type, CONST void *data, size_t size, ImGuiCond cond); -CIMGUI_API void igEndDragDropSource(); -CIMGUI_API bool igBeginDragDropTarget(); -CIMGUI_API CONST struct ImGuiPayload *igAcceptDragDropPayload(CONST char *type, ImGuiDragDropFlags flags); -CIMGUI_API void igEndDragDropTarget(); - -// Clipping -CIMGUI_API void igPushClipRect(CONST struct ImVec2 clip_rect_min, CONST struct ImVec2 clip_rect_max, bool intersect_with_current_clip_rect); -CIMGUI_API void igPopClipRect(); - -// Styles -CIMGUI_API void igStyleColorsClassic(struct ImGuiStyle *dst); -CIMGUI_API void igStyleColorsDark(struct ImGuiStyle *dst); -CIMGUI_API void igStyleColorsLight(struct ImGuiStyle *dst); - -CIMGUI_API void igSetItemDefaultFocus(); -CIMGUI_API void igSetKeyboardFocusHere(int offset); - -// Utilities -CIMGUI_API bool igIsItemHovered(ImGuiHoveredFlags flags); -CIMGUI_API bool igIsItemActive(); -CIMGUI_API bool igIsItemClicked(int mouse_button); -CIMGUI_API bool igIsItemVisible(); -CIMGUI_API bool igIsAnyItemHovered(); -CIMGUI_API bool igIsAnyItemActive(); -CIMGUI_API void igGetItemRectMin(struct ImVec2 *pOut); -CIMGUI_API void igGetItemRectMax(struct ImVec2 *pOut); -CIMGUI_API void igGetItemRectSize(struct ImVec2 *pOut); -CIMGUI_API void igSetItemAllowOverlap(); -CIMGUI_API bool igIsWindowFocused(ImGuiFocusedFlags flags); -CIMGUI_API bool igIsWindowHovered(ImGuiHoveredFlags falgs); -CIMGUI_API bool igIsAnyWindowFocused(); -CIMGUI_API bool igIsAnyWindowHovered(); -CIMGUI_API bool igIsRectVisible(CONST struct ImVec2 item_size); -CIMGUI_API bool igIsRectVisible2(CONST struct ImVec2 *rect_min, CONST struct ImVec2 *rect_max); -CIMGUI_API float igGetTime(); -CIMGUI_API int igGetFrameCount(); - -CIMGUI_API struct ImDrawList *igGetOverlayDrawList(); -CIMGUI_API struct ImDrawListSharedData *igGetDrawListSharedData(); - -CIMGUI_API CONST char *igGetStyleColorName(ImGuiCol idx); -CIMGUI_API void igCalcItemRectClosestPoint(struct ImVec2 *pOut, CONST struct ImVec2 pos, bool on_edge, float outward); -CIMGUI_API void igCalcTextSize(struct ImVec2 *pOut, CONST char *text, CONST char *text_end, bool hide_text_after_double_hash, float wrap_width); -CIMGUI_API void igCalcListClipping(int items_count, float items_height, int *out_items_display_start, int *out_items_display_end); - -CIMGUI_API bool igBeginChildFrame(ImGuiID id, CONST struct ImVec2 size, ImGuiWindowFlags extra_flags); -CIMGUI_API void igEndChildFrame(); - -CIMGUI_API void igColorConvertU32ToFloat4(struct ImVec4 *pOut, ImU32 in); -CIMGUI_API ImU32 igColorConvertFloat4ToU32(CONST struct ImVec4 in); -CIMGUI_API void igColorConvertRGBtoHSV(float r, float g, float b, float *out_h, float *out_s, float *out_v); -CIMGUI_API void igColorConvertHSVtoRGB(float h, float s, float v, float *out_r, float *out_g, float *out_b); - -// Inputs -CIMGUI_API int igGetKeyIndex(ImGuiKey imgui_key); -CIMGUI_API bool igIsKeyDown(int user_key_index); -CIMGUI_API bool igIsKeyPressed(int user_key_index, bool repeat); -CIMGUI_API bool igIsKeyReleased(int user_key_index); -CIMGUI_API int igGetKeyPressedAmount(int key_index, float repeat_delay, float rate); -CIMGUI_API bool igIsMouseDown(int button); -CIMGUI_API bool igIsMouseClicked(int button, bool repeat); -CIMGUI_API bool igIsMouseDoubleClicked(int button); -CIMGUI_API bool igIsMouseReleased(int button); -CIMGUI_API bool igIsMouseDragging(int button, float lock_threshold); -CIMGUI_API bool igIsMouseHoveringRect(CONST struct ImVec2 r_min, CONST struct ImVec2 r_max, bool clip); -CIMGUI_API bool igIsMousePosValid(CONST struct ImVec2 *mouse_pos); -; -CIMGUI_API void igGetMousePos(struct ImVec2 *pOut); -CIMGUI_API void igGetMousePosOnOpeningCurrentPopup(struct ImVec2 *pOut); -CIMGUI_API void igGetMouseDragDelta(struct ImVec2 *pOut, int button, float lock_threshold); -CIMGUI_API void igResetMouseDragDelta(int button); -CIMGUI_API ImGuiMouseCursor igGetMouseCursor(); -CIMGUI_API void igSetMouseCursor(ImGuiMouseCursor type); -CIMGUI_API void igCaptureKeyboardFromApp(bool capture); -CIMGUI_API void igCaptureMouseFromApp(bool capture); - -// Helpers functions to access functions pointers in ImGui::GetIO() -CIMGUI_API void *igMemAlloc(size_t sz); -CIMGUI_API void igMemFree(void *ptr); -CIMGUI_API CONST char *igGetClipboardText(); -CIMGUI_API void igSetClipboardText(CONST char *text); - -// Internal state access - if you want to share ImGui state between modules (e.g. DLL) or allocate it yourself -CIMGUI_API CONST char *igGetVersion(); -CIMGUI_API struct ImGuiContext *igCreateContext(struct ImFontAtlas* shared_font_atlas); -CIMGUI_API void igDestroyContext(struct ImGuiContext *ctx); -CIMGUI_API struct ImGuiContext *igGetCurrentContext(); -CIMGUI_API void igSetCurrentContext(struct ImGuiContext *ctx); - -CIMGUI_API void ImFontConfig_DefaultConstructor(struct ImFontConfig *config); - -// ImGuiIO -CIMGUI_API void ImGuiIO_AddInputCharacter(unsigned short c); -CIMGUI_API void ImGuiIO_AddInputCharactersUTF8(CONST char *utf8_chars); -CIMGUI_API void ImGuiIO_ClearInputCharacters(); - -// ImGuiTextFilter -CIMGUI_API struct ImGuiTextFilter *ImGuiTextFilter_Create(CONST char *default_filter); -CIMGUI_API void ImGuiTextFilter_Destroy(struct ImGuiTextFilter *filter); -CIMGUI_API void ImGuiTextFilter_Clear(struct ImGuiTextFilter *filter); -CIMGUI_API bool ImGuiTextFilter_Draw(struct ImGuiTextFilter *filter, CONST char *label, float width); -CIMGUI_API bool ImGuiTextFilter_PassFilter(CONST struct ImGuiTextFilter *filter, CONST char *text, CONST char *text_end); -CIMGUI_API bool ImGuiTextFilter_IsActive(CONST struct ImGuiTextFilter *filter); -CIMGUI_API void ImGuiTextFilter_Build(struct ImGuiTextFilter *filter); -CIMGUI_API CONST char *ImGuiTextFilter_GetInputBuf(struct ImGuiTextFilter *filter); - -// ImGuiTextBuffer -CIMGUI_API struct ImGuiTextBuffer *ImGuiTextBuffer_Create(); -CIMGUI_API void ImGuiTextBuffer_Destroy(struct ImGuiTextBuffer *buffer); -CIMGUI_API char ImGuiTextBuffer_index(struct ImGuiTextBuffer *buffer, int i); -CIMGUI_API CONST char *ImGuiTextBuffer_begin(CONST struct ImGuiTextBuffer *buffer); -CIMGUI_API CONST char *ImGuiTextBuffer_end(CONST struct ImGuiTextBuffer *buffer); -CIMGUI_API int ImGuiTextBuffer_size(CONST struct ImGuiTextBuffer *buffer); -CIMGUI_API bool ImGuiTextBuffer_empty(struct ImGuiTextBuffer *buffer); -CIMGUI_API void ImGuiTextBuffer_clear(struct ImGuiTextBuffer *buffer); -CIMGUI_API CONST char *ImGuiTextBuffer_c_str(CONST struct ImGuiTextBuffer *buffer); -CIMGUI_API void ImGuiTextBuffer_appendf(struct ImGuiTextBuffer *buffer, CONST char *fmt, ...); -CIMGUI_API void ImGuiTextBuffer_appendfv(struct ImGuiTextBuffer *buffer, CONST char *fmt, va_list args); - -// ImGuiStorage -CIMGUI_API struct ImGuiStorage *ImGuiStorage_Create(); -CIMGUI_API void ImGuiStorage_Destroy(struct ImGuiStorage *storage); -CIMGUI_API int ImGuiStorage_GetInt(struct ImGuiStorage *storage, ImGuiID key, int default_val); -CIMGUI_API void ImGuiStorage_SetInt(struct ImGuiStorage *storage, ImGuiID key, int val); -CIMGUI_API bool ImGuiStorage_GetBool(struct ImGuiStorage *storage, ImGuiID key, bool default_val); -CIMGUI_API void ImGuiStorage_SetBool(struct ImGuiStorage *storage, ImGuiID key, bool val); -CIMGUI_API float ImGuiStorage_GetFloat(struct ImGuiStorage *storage, ImGuiID key, float default_val); -CIMGUI_API void ImGuiStorage_SetFloat(struct ImGuiStorage *storage, ImGuiID key, float val); -CIMGUI_API void *ImGuiStorage_GetVoidPtr(struct ImGuiStorage *storage, ImGuiID key); -CIMGUI_API void ImGuiStorage_SetVoidPtr(struct ImGuiStorage *storage, ImGuiID key, void *val); -CIMGUI_API int *ImGuiStorage_GetIntRef(struct ImGuiStorage *storage, ImGuiID key, int default_val); -CIMGUI_API bool *ImGuiStorage_GetBoolRef(struct ImGuiStorage *storage, ImGuiID key, bool default_val); -CIMGUI_API float *ImGuiStorage_GetFloatRef(struct ImGuiStorage *storage, ImGuiID key, float default_val); -CIMGUI_API void **ImGuiStorage_GetVoidPtrRef(struct ImGuiStorage *storage, ImGuiID key, void *default_val); -CIMGUI_API void ImGuiStorage_SetAllInt(struct ImGuiStorage *storage, int val); - -// ImGuiTextEditCallbackData -CIMGUI_API void ImGuiTextEditCallbackData_DeleteChars(struct ImGuiTextEditCallbackData *data, int pos, int bytes_count); -CIMGUI_API void ImGuiTextEditCallbackData_InsertChars(struct ImGuiTextEditCallbackData *data, int pos, CONST char *text, CONST char *text_end); -CIMGUI_API bool ImGuiTextEditCallbackData_HasSelection(struct ImGuiTextEditCallbackData *data); - -// ImGuiListClipper -CIMGUI_API bool ImGuiListClipper_Step(struct ImGuiListClipper *clipper); -CIMGUI_API void ImGuiListClipper_Begin(struct ImGuiListClipper *clipper, int count, float items_height); -CIMGUI_API void ImGuiListClipper_End(struct ImGuiListClipper *clipper); -CIMGUI_API int ImGuiListClipper_GetDisplayStart(struct ImGuiListClipper *clipper); -CIMGUI_API int ImGuiListClipper_GetDisplayEnd(struct ImGuiListClipper *clipper); - -//ImDrawList -CIMGUI_API int ImDrawList_GetVertexBufferSize(struct ImDrawList *list); -CIMGUI_API struct ImDrawVert *ImDrawList_GetVertexPtr(struct ImDrawList *list, int n); -CIMGUI_API int ImDrawList_GetIndexBufferSize(struct ImDrawList *list); -CIMGUI_API ImDrawIdx *ImDrawList_GetIndexPtr(struct ImDrawList *list, int n); -CIMGUI_API int ImDrawList_GetCmdSize(struct ImDrawList *list); -CIMGUI_API struct ImDrawCmd *ImDrawList_GetCmdPtr(struct ImDrawList *list, int n); - -CIMGUI_API void ImDrawList_Clear(struct ImDrawList *list); -CIMGUI_API void ImDrawList_ClearFreeMemory(struct ImDrawList *list); -CIMGUI_API void ImDrawList_PushClipRect(struct ImDrawList *list, struct ImVec2 clip_rect_min, struct ImVec2 clip_rect_max, bool intersect_with_current_clip_rect); -CIMGUI_API void ImDrawList_PushClipRectFullScreen(struct ImDrawList *list); -CIMGUI_API void ImDrawList_PopClipRect(struct ImDrawList *list); -CIMGUI_API void ImDrawList_PushTextureID(struct ImDrawList *list, CONST ImTextureID texture_id); -CIMGUI_API void ImDrawList_PopTextureID(struct ImDrawList *list); -CIMGUI_API void ImDrawList_GetClipRectMin(struct ImVec2 *pOut, struct ImDrawList *list); -CIMGUI_API void ImDrawList_GetClipRectMax(struct ImVec2 *pOut, struct ImDrawList *list); - -// Primitives -CIMGUI_API void ImDrawList_AddLine(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col, float thickness); -CIMGUI_API void ImDrawList_AddRect(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col, float rounding, int rounding_corners_flags, float thickness); -CIMGUI_API void ImDrawList_AddRectFilled(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col, float rounding, int rounding_corners_flags); -CIMGUI_API void ImDrawList_AddRectFilledMultiColor(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col_upr_left, ImU32 col_upr_right, ImU32 col_bot_right, ImU32 col_bot_left); -CIMGUI_API void ImDrawList_AddQuad(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, CONST struct ImVec2 d, ImU32 col, float thickness); -CIMGUI_API void ImDrawList_AddQuadFilled(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, CONST struct ImVec2 d, ImU32 col); -CIMGUI_API void ImDrawList_AddTriangle(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, ImU32 col, float thickness); -CIMGUI_API void ImDrawList_AddTriangleFilled(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, ImU32 col); -CIMGUI_API void ImDrawList_AddCircle(struct ImDrawList *list, CONST struct ImVec2 centre, float radius, ImU32 col, int num_segments, float thickness); -CIMGUI_API void ImDrawList_AddCircleFilled(struct ImDrawList *list, CONST struct ImVec2 centre, float radius, ImU32 col, int num_segments); -CIMGUI_API void ImDrawList_AddText(struct ImDrawList *list, CONST struct ImVec2 pos, ImU32 col, CONST char *text_begin, CONST char *text_end); -CIMGUI_API void ImDrawList_AddTextExt(struct ImDrawList *list, CONST struct ImFont *font, float font_size, CONST struct ImVec2 pos, ImU32 col, CONST char *text_begin, CONST char *text_end, float wrap_width, CONST struct ImVec4 *cpu_fine_clip_rect); -CIMGUI_API void ImDrawList_AddImage(struct ImDrawList *list, ImTextureID user_texture_id, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, ImU32 col); -CIMGUI_API void ImDrawList_AddImageQuad(struct ImDrawList *list, ImTextureID user_texture_id, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, CONST struct ImVec2 d, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, CONST struct ImVec2 uv_c, CONST struct ImVec2 uv_d, ImU32 col); -CIMGUI_API void ImDrawList_AddImageRounded(struct ImDrawList *list, ImTextureID user_texture_id, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, ImU32 col, float rounding, int rounding_corners); -CIMGUI_API void ImDrawList_AddPolyline(struct ImDrawList *list, CONST struct ImVec2 *points, CONST int num_points, ImU32 col, bool closed, float thickness); -CIMGUI_API void ImDrawList_AddConvexPolyFilled(struct ImDrawList *list, CONST struct ImVec2 *points, CONST int num_points, ImU32 col); -CIMGUI_API void ImDrawList_AddBezierCurve(struct ImDrawList *list, CONST struct ImVec2 pos0, CONST struct ImVec2 cp0, CONST struct ImVec2 cp1, CONST struct ImVec2 pos1, ImU32 col, float thickness, int num_segments); - -// Stateful path API, add points then finish with PathFill() or PathStroke() -CIMGUI_API void ImDrawList_PathClear(struct ImDrawList *list); -CIMGUI_API void ImDrawList_PathLineTo(struct ImDrawList *list, CONST struct ImVec2 pos); -CIMGUI_API void ImDrawList_PathLineToMergeDuplicate(struct ImDrawList *list, CONST struct ImVec2 pos); -CIMGUI_API void ImDrawList_PathFillConvex(struct ImDrawList *list, ImU32 col); -CIMGUI_API void ImDrawList_PathStroke(struct ImDrawList *list, ImU32 col, bool closed, float thickness); -CIMGUI_API void ImDrawList_PathArcTo(struct ImDrawList *list, CONST struct ImVec2 centre, float radius, float a_min, float a_max, int num_segments); -CIMGUI_API void ImDrawList_PathArcToFast(struct ImDrawList *list, CONST struct ImVec2 centre, float radius, int a_min_of_12, int a_max_of_12); // Use precomputed angles for a 12 steps circle -CIMGUI_API void ImDrawList_PathBezierCurveTo(struct ImDrawList *list, CONST struct ImVec2 p1, CONST struct ImVec2 p2, CONST struct ImVec2 p3, int num_segments); -CIMGUI_API void ImDrawList_PathRect(struct ImDrawList *list, CONST struct ImVec2 rect_min, CONST struct ImVec2 rect_max, float rounding, int rounding_corners_flags); - -// Channels -CIMGUI_API void ImDrawList_ChannelsSplit(struct ImDrawList *list, int channels_count); -CIMGUI_API void ImDrawList_ChannelsMerge(struct ImDrawList *list); -CIMGUI_API void ImDrawList_ChannelsSetCurrent(struct ImDrawList *list, int channel_index); - -// Advanced -CIMGUI_API void ImDrawList_AddCallback(struct ImDrawList *list, ImDrawCallback callback, void *callback_data); // Your rendering function must check for 'UserCallback' in ImDrawCmd and call the function instead of rendering triangles. -CIMGUI_API void ImDrawList_AddDrawCmd(struct ImDrawList *list); // This is useful if you need to forcefully create a new draw call (to allow for dependent rendering / blending). Otherwise primitives are merged into the same draw-call as much as possible - -// Internal helpers -CIMGUI_API void ImDrawList_PrimReserve(struct ImDrawList *list, int idx_count, int vtx_count); -CIMGUI_API void ImDrawList_PrimRect(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col); -CIMGUI_API void ImDrawList_PrimRectUV(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, ImU32 col); -CIMGUI_API void ImDrawList_PrimQuadUV(struct ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, CONST struct ImVec2 d, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, CONST struct ImVec2 uv_c, CONST struct ImVec2 uv_d, ImU32 col); -CIMGUI_API void ImDrawList_PrimWriteVtx(struct ImDrawList *list, CONST struct ImVec2 pos, CONST struct ImVec2 uv, ImU32 col); -CIMGUI_API void ImDrawList_PrimWriteIdx(struct ImDrawList *list, ImDrawIdx idx); -CIMGUI_API void ImDrawList_PrimVtx(struct ImDrawList *list, CONST struct ImVec2 pos, CONST struct ImVec2 uv, ImU32 col); -CIMGUI_API void ImDrawList_UpdateClipRect(struct ImDrawList *list); -CIMGUI_API void ImDrawList_UpdateTextureID(struct ImDrawList *list); - -// ImDrawData -CIMGUI_API void ImDrawData_DeIndexAllBuffers(struct ImDrawData *drawData); -CIMGUI_API void ImDrawData_ScaleClipRects(struct ImDrawData *drawData, CONST struct ImVec2 sc); - -// ImFontAtlas -CIMGUI_API void ImFontAtlas_GetTexDataAsRGBA32(struct ImFontAtlas *atlas, unsigned char **out_pixels, int *out_width, int *out_height, int *out_bytes_per_pixel); -CIMGUI_API void ImFontAtlas_GetTexDataAsAlpha8(struct ImFontAtlas *atlas, unsigned char **out_pixels, int *out_width, int *out_height, int *out_bytes_per_pixel); -CIMGUI_API void ImFontAtlas_SetTexID(struct ImFontAtlas *atlas, ImTextureID id); -CIMGUI_API struct ImFont *ImFontAtlas_AddFont(struct ImFontAtlas *atlas, CONST struct ImFontConfig *font_cfg); -CIMGUI_API struct ImFont *ImFontAtlas_AddFontDefault(struct ImFontAtlas *atlas, CONST struct ImFontConfig *font_cfg); -CIMGUI_API struct ImFont *ImFontAtlas_AddFontFromFileTTF(struct ImFontAtlas *atlas, CONST char *filename, float size_pixels, CONST struct ImFontConfig *font_cfg, CONST ImWchar *glyph_ranges); -CIMGUI_API struct ImFont *ImFontAtlas_AddFontFromMemoryTTF(struct ImFontAtlas *atlas, void *font_data, int font_size, float size_pixels, CONST struct ImFontConfig *font_cfg, CONST ImWchar *glyph_ranges); -CIMGUI_API struct ImFont *ImFontAtlas_AddFontFromMemoryCompressedTTF(struct ImFontAtlas *atlas, CONST void *compressed_font_data, int compressed_font_size, float size_pixels, CONST struct ImFontConfig *font_cfg, CONST ImWchar *glyph_ranges); -CIMGUI_API struct ImFont *ImFontAtlas_AddFontFromMemoryCompressedBase85TTF(struct ImFontAtlas *atlas, CONST char *compressed_font_data_base85, float size_pixels, CONST struct ImFontConfig *font_cfg, CONST ImWchar *glyph_ranges); -CIMGUI_API void ImFontAtlas_ClearTexData(struct ImFontAtlas *atlas); -CIMGUI_API void ImFontAtlas_Clear(struct ImFontAtlas *atlas); -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesDefault(struct ImFontAtlas *atlas); -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesKorean(struct ImFontAtlas *atlas); -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesJapanese(struct ImFontAtlas *atlas); -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesChinese(struct ImFontAtlas *atlas); -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesCyrillic(struct ImFontAtlas *atlas); -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesThai(struct ImFontAtlas *atlas); - -CIMGUI_API ImTextureID ImFontAtlas_GetTexID(struct ImFontAtlas *atlas); -CIMGUI_API unsigned char *ImFontAtlas_GetTexPixelsAlpha8(struct ImFontAtlas *atlas); -CIMGUI_API unsigned int *ImFontAtlas_GetTexPixelsRGBA32(struct ImFontAtlas *atlas); -CIMGUI_API int ImFontAtlas_GetTexWidth(struct ImFontAtlas *atlas); -CIMGUI_API int ImFontAtlas_GetTexHeight(struct ImFontAtlas *atlas); -CIMGUI_API int ImFontAtlas_GetTexDesiredWidth(struct ImFontAtlas *atlas); -CIMGUI_API void ImFontAtlas_SetTexDesiredWidth(struct ImFontAtlas *atlas, int TexDesiredWidth_); -CIMGUI_API int ImFontAtlas_GetTexGlyphPadding(struct ImFontAtlas *atlas); -CIMGUI_API void ImFontAtlas_SetTexGlyphPadding(struct ImFontAtlas *atlas, int TexGlyphPadding_); -CIMGUI_API void ImFontAtlas_GetTexUvWhitePixel(struct ImFontAtlas *atlas, struct ImVec2 *pOut); - -// ImFontAtlas::Fonts; -CIMGUI_API int ImFontAtlas_Fonts_size(struct ImFontAtlas *atlas); -CIMGUI_API struct ImFont *ImFontAtlas_Fonts_index(struct ImFontAtlas *atlas, int index); - -// ImFont -CIMGUI_API float ImFont_GetFontSize(CONST struct ImFont *font); -CIMGUI_API void ImFont_SetFontSize(struct ImFont *font, float FontSize_); -CIMGUI_API float ImFont_GetScale(CONST struct ImFont *font); -CIMGUI_API void ImFont_SetScale(struct ImFont *font, float Scale_); -CIMGUI_API void ImFont_GetDisplayOffset(CONST struct ImFont *font, struct ImVec2 *pOut); -CIMGUI_API CONST struct IMFONTGLYPH *ImFont_GetFallbackGlyph(CONST struct ImFont *font); -CIMGUI_API void ImFont_SetFallbackGlyph(struct ImFont *font, CONST struct IMFONTGLYPH *FallbackGlyph_); -CIMGUI_API float ImFont_GetFallbackAdvanceX(CONST struct ImFont *font); -CIMGUI_API ImWchar ImFont_GetFallbackChar(CONST struct ImFont *font); -CIMGUI_API short ImFont_GetConfigDataCount(CONST struct ImFont *font); -CIMGUI_API struct ImFontConfig *ImFont_GetConfigData(struct ImFont *font); -CIMGUI_API struct ImFontAtlas *ImFont_GetContainerAtlas(struct ImFont *font); -CIMGUI_API float ImFont_GetAscent(CONST struct ImFont *font); -CIMGUI_API float ImFont_GetDescent(CONST struct ImFont *font); -CIMGUI_API int ImFont_GetMetricsTotalSurface(CONST struct ImFont *font); -CIMGUI_API void ImFont_ClearOutputData(struct ImFont *font); -CIMGUI_API void ImFont_BuildLookupTable(struct ImFont *font); -CIMGUI_API CONST struct IMFONTGLYPH *ImFont_FindGlyph(CONST struct ImFont *font, ImWchar c); -CIMGUI_API void ImFont_SetFallbackChar(struct ImFont *font, ImWchar c); -CIMGUI_API float ImFont_GetCharAdvance(CONST struct ImFont *font, ImWchar c); -CIMGUI_API bool ImFont_IsLoaded(CONST struct ImFont *font); -CIMGUI_API CONST char *ImFont_GetDebugName(CONST struct ImFont *font); -CIMGUI_API void ImFont_CalcTextSizeA(CONST struct ImFont *font, struct ImVec2 *pOut, float size, float max_width, float wrap_width, CONST char *text_begin, CONST char *text_end, CONST char **remaining); // utf8 -CIMGUI_API CONST char *ImFont_CalcWordWrapPositionA(CONST struct ImFont *font, float scale, CONST char *text, CONST char *text_end, float wrap_width); -CIMGUI_API void ImFont_RenderChar(CONST struct ImFont *font, struct ImDrawList *draw_list, float size, struct ImVec2 pos, ImU32 col, unsigned short c); -CIMGUI_API void ImFont_RenderText(CONST struct ImFont *font, struct ImDrawList *draw_list, float size, struct ImVec2 pos, ImU32 col, CONST struct ImVec4 *clip_rect, CONST char *text_begin, CONST char *text_end, float wrap_width, bool cpu_fine_clip); -// ImFont::Glyph -CIMGUI_API int ImFont_Glyphs_size(CONST struct ImFont *font); -CIMGUI_API struct IMFONTGLYPH *ImFont_Glyphs_index(struct ImFont *font, int index); -// ImFont::IndexXAdvance -CIMGUI_API int ImFont_IndexXAdvance_size(CONST struct ImFont *font); -CIMGUI_API float ImFont_IndexXAdvance_index(CONST struct ImFont *font, int index); -// ImFont::IndexLookup -CIMGUI_API int ImFont_IndexLookup_size(CONST struct ImFont *font); -CIMGUI_API unsigned short ImFont_IndexLookup_index(CONST struct ImFont *font, int index); +#include "auto_funcs.h" diff --git a/cimgui/cimgui.sln b/cimgui/cimgui.sln deleted file mode 100644 index bc9063c..0000000 --- a/cimgui/cimgui.sln +++ /dev/null @@ -1,28 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2013 -VisualStudioVersion = 12.0.31101.0 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cimgui", "cimgui.vcxproj", "{EDE48926-0595-4488-B1A0-32CA71397271}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Win32 = Debug|Win32 - Debug|x64 = Debug|x64 - Release|Win32 = Release|Win32 - Release|x64 = Release|x64 - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {EDE48926-0595-4488-B1A0-32CA71397271}.Debug|Win32.ActiveCfg = Debug|Win32 - {EDE48926-0595-4488-B1A0-32CA71397271}.Debug|Win32.Build.0 = Debug|Win32 - {EDE48926-0595-4488-B1A0-32CA71397271}.Debug|x64.ActiveCfg = Debug|x64 - {EDE48926-0595-4488-B1A0-32CA71397271}.Debug|x64.Build.0 = Debug|x64 - {EDE48926-0595-4488-B1A0-32CA71397271}.Release|Win32.ActiveCfg = Release|Win32 - {EDE48926-0595-4488-B1A0-32CA71397271}.Release|Win32.Build.0 = Release|Win32 - {EDE48926-0595-4488-B1A0-32CA71397271}.Release|x64.ActiveCfg = Release|x64 - {EDE48926-0595-4488-B1A0-32CA71397271}.Release|x64.Build.0 = Release|x64 - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/cimgui/cimgui.vcxproj b/cimgui/cimgui.vcxproj deleted file mode 100644 index fdc8510..0000000 --- a/cimgui/cimgui.vcxproj +++ /dev/null @@ -1,161 +0,0 @@ - - - - - Debug - Win32 - - - Debug - x64 - - - Release - Win32 - - - Release - x64 - - - - {EDE48926-0595-4488-B1A0-32CA71397271} - Win32Proj - cimgui - - - - DynamicLibrary - true - v140 - Unicode - - - DynamicLibrary - true - v140 - Unicode - - - DynamicLibrary - false - v140 - true - Unicode - - - DynamicLibrary - false - v140 - true - Unicode - - - - - - - - - - - - - - - - - - - true - - - true - - - false - - - false - - - - - - Level3 - Disabled - WIN32;_DEBUG;_WINDOWS;_USRDLL;CIMGUI_EXPORTS;%(PreprocessorDefinitions) - - - Windows - true - - - - - - - Level3 - Disabled - WIN32;_DEBUG;_WINDOWS;_USRDLL;CIMGUI_EXPORTS;%(PreprocessorDefinitions) - - - Windows - true - - - - - Level3 - - - MaxSpeed - true - true - WIN32;NDEBUG;_WINDOWS;_USRDLL;CIMGUI_EXPORTS;%(PreprocessorDefinitions) - MultiThreadedDLL - true - - - Windows - true - true - true - - - - - Level3 - - - MaxSpeed - true - true - WIN32;NDEBUG;_WINDOWS;_USRDLL;CIMGUI_EXPORTS;%(PreprocessorDefinitions) - MultiThreadedDLL - true - - - Windows - true - true - true - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/cimgui/cimgui.vcxproj.filters b/cimgui/cimgui.vcxproj.filters deleted file mode 100644 index 2023c37..0000000 --- a/cimgui/cimgui.vcxproj.filters +++ /dev/null @@ -1,48 +0,0 @@ - - - - - {4FC737F1-C7A5-4376-A066-2A32D752A2FF} - cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx - - - {93995380-89BD-4b04-88EB-625FBE52EBFB} - h;hh;hpp;hxx;hm;inl;inc;xsd - - - {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} - rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - - - Source Files - - - Source Files - - - \ No newline at end of file diff --git a/cimgui/drawList.cpp b/cimgui/drawList.cpp deleted file mode 100644 index 362e2fe..0000000 --- a/cimgui/drawList.cpp +++ /dev/null @@ -1,293 +0,0 @@ - -#include "../imgui/imgui.h" -#include "cimgui.h" - -CIMGUI_API void ImDrawData_DeIndexAllBuffers(ImDrawData *drawData) -{ - return drawData->DeIndexAllBuffers(); -} - -CIMGUI_API void ImDrawData_ScaleClipRects(ImDrawData *drawData, const struct ImVec2 sc) -{ - return drawData->ScaleClipRects(sc); -} - -CIMGUI_API int ImDrawList_GetVertexBufferSize(ImDrawList *list) -{ - return list->VtxBuffer.size(); -} - -CIMGUI_API ImDrawVert *ImDrawList_GetVertexPtr(ImDrawList *list, int n) -{ - return &list->VtxBuffer[n]; -} - -CIMGUI_API int ImDrawList_GetIndexBufferSize(ImDrawList *list) -{ - return list->IdxBuffer.size(); -} - -CIMGUI_API ImDrawIdx *ImDrawList_GetIndexPtr(ImDrawList *list, int n) -{ - return &list->IdxBuffer[n]; -} - -CIMGUI_API int ImDrawList_GetCmdSize(ImDrawList *list) -{ - return list->CmdBuffer.size(); -} - -CIMGUI_API ImDrawCmd *ImDrawList_GetCmdPtr(ImDrawList *list, int n) -{ - return &list->CmdBuffer[n]; -} - -CIMGUI_API void ImDrawList_Clear(ImDrawList *list) -{ - return list->Clear(); -} - -CIMGUI_API void ImDrawList_ClearFreeMemory(ImDrawList *list) -{ - return list->ClearFreeMemory(); -} - -CIMGUI_API void ImDrawList_PushClipRect(ImDrawList *list, struct ImVec2 clip_rect_min, struct ImVec2 clip_rect_max, bool intersect_with_current_clip_rect) -{ - return list->PushClipRect(clip_rect_min, clip_rect_max, intersect_with_current_clip_rect); -} - -CIMGUI_API void ImDrawList_PushClipRectFullScreen(ImDrawList *list) -{ - return list->PushClipRectFullScreen(); -} - -CIMGUI_API void ImDrawList_PopClipRect(ImDrawList *list) -{ - return list->PopClipRect(); -} - -CIMGUI_API void ImDrawList_PushTextureID(ImDrawList *list, CONST ImTextureID texture_id) -{ - return list->PushTextureID(texture_id); -} - -CIMGUI_API void ImDrawList_PopTextureID(ImDrawList *list) -{ - return list->PopTextureID(); -} - -CIMGUI_API void ImDrawList_GetClipRectMin(ImVec2 *pOut, ImDrawList *list) -{ - *pOut = list->GetClipRectMin(); -} - -CIMGUI_API void ImDrawList_GetClipRectMax(ImVec2 *pOut, ImDrawList *list) -{ - *pOut = list->GetClipRectMax(); -} - -CIMGUI_API void ImDrawList_AddLine(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col, float thickness) -{ - return list->AddLine(a, b, col, thickness); -} - -CIMGUI_API void ImDrawList_AddRect(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col, float rounding, int rounding_corners_flags, float thickness) -{ - return list->AddRect(a, b, col, rounding, rounding_corners_flags, thickness); -} - -CIMGUI_API void ImDrawList_AddRectFilled(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col, float rounding, int rounding_corners_flags) -{ - return list->AddRectFilled(a, b, col, rounding, rounding_corners_flags); -} - -CIMGUI_API void ImDrawList_AddRectFilledMultiColor(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col_upr_left, ImU32 col_upr_right, ImU32 col_bot_right, ImU32 col_bot_left) -{ - return list->AddRectFilledMultiColor(a, b, col_upr_left, col_upr_right, col_bot_right, col_bot_left); -} - -CIMGUI_API void ImDrawList_AddQuad(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, CONST struct ImVec2 d, ImU32 col, float thickness) -{ - return list->AddQuad(a, b, c, d, col, thickness); -} - -CIMGUI_API void ImDrawList_AddQuadFilled(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, CONST struct ImVec2 d, ImU32 col) -{ - return list->AddQuadFilled(a, b, c, d, col); -} - -CIMGUI_API void ImDrawList_AddTriangle(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, ImU32 col, float thickness) -{ - return list->AddTriangle(a, b, c, col, thickness); -} - -CIMGUI_API void ImDrawList_AddTriangleFilled(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, ImU32 col) -{ - return list->AddTriangleFilled(a, b, c, col); -} - -CIMGUI_API void ImDrawList_AddCircle(ImDrawList *list, CONST struct ImVec2 centre, float radius, ImU32 col, int num_segments, float thickness) -{ - return list->AddCircle(centre, radius, col, num_segments, thickness); -} - -CIMGUI_API void ImDrawList_AddCircleFilled(ImDrawList *list, CONST struct ImVec2 centre, float radius, ImU32 col, int num_segments) -{ - return list->AddCircleFilled(centre, radius, col, num_segments); -} - -CIMGUI_API void ImDrawList_AddText(ImDrawList *list, CONST struct ImVec2 pos, ImU32 col, CONST char *text_begin, CONST char *text_end) -{ - return list->AddText(pos, col, text_begin, text_end); -} - -CIMGUI_API void ImDrawList_AddTextExt(ImDrawList *list, CONST ImFont *font, float font_size, CONST struct ImVec2 pos, ImU32 col, CONST char *text_begin, CONST char *text_end, float wrap_width, CONST ImVec4 *cpu_fine_clip_rect) -{ - return list->AddText(font, font_size, pos, col, text_begin, text_end, wrap_width, cpu_fine_clip_rect); -} - -CIMGUI_API void ImDrawList_AddImage(ImDrawList *list, ImTextureID user_texture_id, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, ImU32 col) -{ - return list->AddImage(user_texture_id, a, b, uv_a, uv_b, col); -} - -CIMGUI_API void ImDrawList_AddImageQuad(struct ImDrawList *list, ImTextureID user_texture_id, CONST struct ImVec2 a, CONST ImVec2 b, CONST ImVec2 c, CONST ImVec2 d, CONST ImVec2 uv_a, CONST ImVec2 uv_b, CONST ImVec2 uv_c, CONST ImVec2 uv_d, ImU32 col) -{ - return list->AddImageQuad(user_texture_id, a, b, c, d, uv_a, uv_b, uv_c, uv_d, col); -} - -CIMGUI_API void ImDrawList_AddImageRounded(struct ImDrawList *list, ImTextureID user_texture_id, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, ImU32 col, float rounding, int rounding_corners) -{ - list->AddImageRounded(user_texture_id, a, b, uv_a, uv_b, col, rounding, rounding_corners); -} - -CIMGUI_API void ImDrawList_AddPolyline(ImDrawList *list, CONST ImVec2 *points, CONST int num_points, ImU32 col, bool closed, float thickness) -{ - return list->AddPolyline(points, num_points, col, closed, thickness); -} - -CIMGUI_API void ImDrawList_AddConvexPolyFilled(ImDrawList *list, CONST ImVec2 *points, CONST int num_points, ImU32 col) -{ - return list->AddConvexPolyFilled(points, num_points, col); -} - -CIMGUI_API void ImDrawList_AddBezierCurve(ImDrawList *list, CONST struct ImVec2 pos0, CONST struct ImVec2 cp0, CONST struct ImVec2 cp1, CONST struct ImVec2 pos1, ImU32 col, float thickness, int num_segments) -{ - return list->AddBezierCurve(pos0, cp0, cp1, pos1, col, thickness, num_segments); -} - -CIMGUI_API void ImDrawList_PathClear(ImDrawList *list) -{ - return list->PathClear(); -} - -CIMGUI_API void ImDrawList_PathLineTo(ImDrawList *list, CONST struct ImVec2 pos) -{ - return list->PathLineTo(pos); -} - -CIMGUI_API void ImDrawList_PathLineToMergeDuplicate(ImDrawList *list, CONST struct ImVec2 pos) -{ - return list->PathLineToMergeDuplicate(pos); -} - -CIMGUI_API void ImDrawList_PathFillConvex(ImDrawList *list, ImU32 col) -{ - return list->PathFillConvex(col); -} - -CIMGUI_API void ImDrawList_PathStroke(ImDrawList *list, ImU32 col, bool closed, float thickness) -{ - return list->PathStroke(col, closed, thickness); -} - -CIMGUI_API void ImDrawList_PathArcTo(ImDrawList *list, CONST struct ImVec2 centre, float radius, float a_min, float a_max, int num_segments) -{ - return list->PathArcTo(centre, radius, a_min, a_max, num_segments); -} - -CIMGUI_API void ImDrawList_PathArcToFast(ImDrawList *list, CONST struct ImVec2 centre, float radius, int a_min_of_12, int a_max_of_12) -{ - return list->PathArcToFast(centre, radius, a_min_of_12, a_max_of_12); -} - -CIMGUI_API void ImDrawList_PathBezierCurveTo(ImDrawList *list, CONST struct ImVec2 p1, CONST struct ImVec2 p2, CONST struct ImVec2 p3, int num_segments) -{ - return list->PathBezierCurveTo(p1, p2, p3, num_segments); -} - -CIMGUI_API void ImDrawList_PathRect(ImDrawList *list, CONST struct ImVec2 rect_min, CONST struct ImVec2 rect_max, float rounding, int rounding_corners_flags) -{ - return list->PathRect(rect_min, rect_max, rounding, rounding_corners_flags); -} - -CIMGUI_API void ImDrawList_ChannelsSplit(ImDrawList *list, int channels_count) -{ - return list->ChannelsSplit(channels_count); -} - -CIMGUI_API void ImDrawList_ChannelsMerge(ImDrawList *list) -{ - return list->ChannelsMerge(); -} - -CIMGUI_API void ImDrawList_ChannelsSetCurrent(ImDrawList *list, int channel_index) -{ - return list->ChannelsSetCurrent(channel_index); -} - -CIMGUI_API void ImDrawList_AddCallback(ImDrawList *list, ImDrawCallback callback, void *callback_data) -{ - return list->AddCallback(callback, callback_data); -} - -CIMGUI_API void ImDrawList_AddDrawCmd(ImDrawList *list) -{ - return list->AddDrawCmd(); -} - -CIMGUI_API void ImDrawList_PrimReserve(ImDrawList *list, int idx_count, int vtx_count) -{ - return list->PrimReserve(idx_count, vtx_count); -} - -CIMGUI_API void ImDrawList_PrimRect(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, ImU32 col) -{ - return list->PrimRect(a, b, col); -} - -CIMGUI_API void ImDrawList_PrimRectUV(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, ImU32 col) -{ - return list->PrimRectUV(a, b, uv_a, uv_b, col); -} - -CIMGUI_API void ImDrawList_PrimQuadUV(ImDrawList *list, CONST struct ImVec2 a, CONST struct ImVec2 b, CONST struct ImVec2 c, CONST struct ImVec2 d, CONST struct ImVec2 uv_a, CONST struct ImVec2 uv_b, CONST struct ImVec2 uv_c, CONST struct ImVec2 uv_d, ImU32 col) -{ - return list->PrimQuadUV(a, b, c, d, uv_a, uv_b, uv_c, uv_d, col); -} - -CIMGUI_API void ImDrawList_PrimVtx(ImDrawList *list, CONST struct ImVec2 pos, CONST struct ImVec2 uv, ImU32 col) -{ - return list->PrimVtx(pos, uv, col); -} - -CIMGUI_API void ImDrawList_PrimWriteVtx(ImDrawList *list, CONST struct ImVec2 pos, CONST struct ImVec2 uv, ImU32 col) -{ - return list->PrimWriteVtx(pos, uv, col); -} - -CIMGUI_API void ImDrawList_PrimWriteIdx(ImDrawList *list, ImDrawIdx idx) -{ - return list->PrimWriteIdx(idx); -} - -CIMGUI_API void ImDrawList_UpdateClipRect(ImDrawList *list) -{ - return list->UpdateClipRect(); -} - -CIMGUI_API void ImDrawList_UpdateTextureID(ImDrawList *list) -{ - return list->UpdateTextureID(); -} diff --git a/cimgui/fontAtlas.cpp b/cimgui/fontAtlas.cpp deleted file mode 100644 index 92d5658..0000000 --- a/cimgui/fontAtlas.cpp +++ /dev/null @@ -1,328 +0,0 @@ - -#include "../imgui/imgui.h" -#include "cimgui.h" - -CIMGUI_API void ImFontConfig_DefaultConstructor(ImFontConfig *config) -{ - *config = ImFontConfig(); -} - -CIMGUI_API void ImFontAtlas_GetTexDataAsRGBA32(ImFontAtlas *atlas, unsigned char **out_pixels, int *out_width, int *out_height, int *out_bytes_per_pixel) -{ - atlas->GetTexDataAsRGBA32(out_pixels, out_width, out_height, out_bytes_per_pixel); -} - -CIMGUI_API void ImFontAtlas_GetTexDataAsAlpha8(ImFontAtlas *atlas, unsigned char **out_pixels, int *out_width, int *out_height, int *out_bytes_per_pixel) -{ - atlas->GetTexDataAsAlpha8(out_pixels, out_width, out_height, out_bytes_per_pixel); -} - -CIMGUI_API void ImFontAtlas_SetTexID(ImFontAtlas *atlas, ImTextureID id) -{ - atlas->TexID = id; -} - -CIMGUI_API ImFont *ImFontAtlas_AddFont(ImFontAtlas *atlas, CONST ImFontConfig *font_cfg) -{ - return atlas->AddFont(font_cfg); -} - -CIMGUI_API ImFont *ImFontAtlas_AddFontDefault(ImFontAtlas *atlas, CONST ImFontConfig *font_cfg) -{ - return atlas->AddFontDefault(font_cfg); -} - -CIMGUI_API ImFont *ImFontAtlas_AddFontFromFileTTF(ImFontAtlas *atlas, CONST char *filename, float size_pixels, CONST ImFontConfig *font_cfg, CONST ImWchar *glyph_ranges) -{ - return atlas->AddFontFromFileTTF(filename, size_pixels, font_cfg, glyph_ranges); -} - -CIMGUI_API ImFont *ImFontAtlas_AddFontFromMemoryTTF(ImFontAtlas *atlas, void *font_data, int font_size, float size_pixels, CONST ImFontConfig *font_cfg, CONST ImWchar *glyph_ranges) -{ - return atlas->AddFontFromMemoryTTF(font_data, font_size, size_pixels, font_cfg, glyph_ranges); -} - -CIMGUI_API ImFont *ImFontAtlas_AddFontFromMemoryCompressedTTF(ImFontAtlas *atlas, CONST void *compressed_font_data, int compressed_font_size, float size_pixels, CONST ImFontConfig *font_cfg, CONST ImWchar *glyph_ranges) -{ - return atlas->AddFontFromMemoryCompressedTTF(compressed_font_data, compressed_font_size, size_pixels, font_cfg, glyph_ranges); -} - -CIMGUI_API ImFont *ImFontAtlas_AddFontFromMemoryCompressedBase85TTF(ImFontAtlas *atlas, CONST char *compressed_font_data_base85, float size_pixels, CONST ImFontConfig *font_cfg, CONST ImWchar *glyph_ranges) -{ - return atlas->AddFontFromMemoryCompressedBase85TTF(compressed_font_data_base85, size_pixels, font_cfg, glyph_ranges); -} - -CIMGUI_API void ImFontAtlas_ClearTexData(ImFontAtlas *atlas) -{ - return atlas->ClearTexData(); -} - -CIMGUI_API void ImFontAtlas_ClearInputData(ImFontAtlas *atlas) -{ - return atlas->ClearInputData(); -} - -CIMGUI_API void ImFontAtlas_ClearFonts(ImFontAtlas *atlas) -{ - return atlas->ClearFonts(); -} - -CIMGUI_API void ImFontAtlas_Clear(ImFontAtlas *atlas) -{ - return atlas->Clear(); -} - -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesDefault(struct ImFontAtlas *atlas) -{ - return atlas->GetGlyphRangesDefault(); -} - -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesKorean(struct ImFontAtlas *atlas) -{ - return atlas->GetGlyphRangesKorean(); -} - -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesJapanese(struct ImFontAtlas *atlas) -{ - return atlas->GetGlyphRangesJapanese(); -} - -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesChinese(struct ImFontAtlas *atlas) -{ - return atlas->GetGlyphRangesChinese(); -} - -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesCyrillic(struct ImFontAtlas *atlas) -{ - return atlas->GetGlyphRangesCyrillic(); -} - -CIMGUI_API CONST ImWchar *ImFontAtlas_GetGlyphRangesThai(struct ImFontAtlas *atlas) -{ - return atlas->GetGlyphRangesThai(); -} - -CIMGUI_API ImTextureID ImFontAtlas_GetTexID(struct ImFontAtlas *atlas) -{ - return atlas->TexID; -} - -CIMGUI_API unsigned char *ImFontAtlas_GetTexPixelsAlpha8(struct ImFontAtlas *atlas) -{ - return atlas->TexPixelsAlpha8; -} - -CIMGUI_API unsigned int *ImFontAtlas_GetTexPixelsRGBA32(struct ImFontAtlas *atlas) -{ - return atlas->TexPixelsRGBA32; -} - -CIMGUI_API int ImFontAtlas_GetTexWidth(struct ImFontAtlas *atlas) -{ - return atlas->TexWidth; -} - -CIMGUI_API int ImFontAtlas_GetTexHeight(struct ImFontAtlas *atlas) -{ - return atlas->TexHeight; -} - -CIMGUI_API int ImFontAtlas_GetTexDesiredWidth(struct ImFontAtlas *atlas) -{ - return atlas->TexDesiredWidth; -} - -CIMGUI_API void ImFontAtlas_SetTexDesiredWidth(struct ImFontAtlas *atlas, int TexDesiredWidth_) -{ - atlas->TexDesiredWidth = TexDesiredWidth_; -} - -CIMGUI_API int ImFontAtlas_GetTexGlyphPadding(struct ImFontAtlas *atlas) -{ - return atlas->TexGlyphPadding; -} - -CIMGUI_API void ImFontAtlas_SetTexGlyphPadding(struct ImFontAtlas *atlas, int TexGlyphPadding_) -{ - atlas->TexGlyphPadding = TexGlyphPadding_; -} - -CIMGUI_API void ImFontAtlas_GetTexUvWhitePixel(struct ImFontAtlas *atlas, ImVec2 *pOut) -{ - *pOut = atlas->TexUvWhitePixel; -} - -// ImFontAtlas::Fonts; -CIMGUI_API int ImFontAtlas_Fonts_size(struct ImFontAtlas *atlas) -{ - return atlas->Fonts.size(); -} - -CIMGUI_API ImFont *ImFontAtlas_Fonts_index(struct ImFontAtlas *atlas, int index) -{ - return atlas->Fonts[index]; -} - -// ImFont -CIMGUI_API float ImFont_GetFontSize(CONST struct ImFont *font) -{ - return font->FontSize; -} - -CIMGUI_API void ImFont_SetFontSize(struct ImFont *font, float FontSize_) -{ - font->FontSize = FontSize_; -} - -CIMGUI_API float ImFont_GetScale(CONST struct ImFont *font) -{ - return font->Scale; -} - -CIMGUI_API void ImFont_SetScale(struct ImFont *font, float Scale_) -{ - font->Scale = Scale_; -} - -CIMGUI_API void ImFont_GetDisplayOffset(CONST struct ImFont *font, ImVec2 *pOut) -{ - *pOut = font->DisplayOffset; -} - -CIMGUI_API CONST struct IMFONTGLYPH *ImFont_GetFallbackGlyph(CONST struct ImFont *font) -{ - return font->FallbackGlyph; -} - -CIMGUI_API void ImFont_SetFallbackGlyph(struct ImFont *font, CONST struct IMFONTGLYPH *FallbackGlyph_) -{ - font->FallbackGlyph = FallbackGlyph_; -} - -CIMGUI_API float ImFont_GetFallbackAdvanceX(CONST struct ImFont *font) -{ - return font->FallbackAdvanceX; -} - -CIMGUI_API ImWchar ImFont_GetFallbackChar(CONST struct ImFont *font) -{ - return font->FallbackChar; -} - -CIMGUI_API short ImFont_GetConfigDataCount(CONST struct ImFont *font) -{ - return font->ConfigDataCount; -} - -CIMGUI_API struct ImFontConfig *ImFont_GetConfigData(struct ImFont *font) -{ - return font->ConfigData; -} - -CIMGUI_API struct ImFontAtlas *ImFont_GetContainerAtlas(struct ImFont *font) -{ - return font->ContainerAtlas; -} - -CIMGUI_API float ImFont_GetAscent(CONST struct ImFont *font) -{ - return font->Ascent; -} - -CIMGUI_API float ImFont_GetDescent(CONST struct ImFont *font) -{ - return font->Descent; -} - -CIMGUI_API int ImFont_GetMetricsTotalSurface(CONST struct ImFont *font) -{ - return font->MetricsTotalSurface; -} - -CIMGUI_API void ImFont_ClearOutputData(struct ImFont *font) -{ - font->ClearOutputData(); -} - -CIMGUI_API void ImFont_BuildLookupTable(struct ImFont *font) -{ - font->BuildLookupTable(); -} - -CIMGUI_API CONST struct IMFONTGLYPH *ImFont_FindGlyph(CONST struct ImFont *font, ImWchar c) -{ - return font->FindGlyph(c); -} - -CIMGUI_API void ImFont_SetFallbackChar(struct ImFont *font, ImWchar c) -{ - font->SetFallbackChar(c); -} - -CIMGUI_API float ImFont_GetCharAdvance(CONST struct ImFont *font, ImWchar c) -{ - return font->GetCharAdvance(c); -} - -CIMGUI_API bool ImFont_IsLoaded(CONST struct ImFont *font) -{ - return font->IsLoaded(); -} - -CIMGUI_API CONST char *ImFont_GetDebugName(CONST struct ImFont *font) -{ - return font->GetDebugName(); -} - -CIMGUI_API void ImFont_CalcTextSizeA(CONST struct ImFont *font, ImVec2 *pOut, float size, float max_width, float wrap_width, CONST char *text_begin, CONST char *text_end, CONST char **remaining) -{ - *pOut = font->CalcTextSizeA(size, max_width, wrap_width, text_begin, text_end, remaining); -} - -CIMGUI_API CONST char *ImFont_CalcWordWrapPositionA(CONST struct ImFont *font, float scale, CONST char *text, CONST char *text_end, float wrap_width) -{ - return font->CalcWordWrapPositionA(scale, text, text_end, wrap_width); -} - -CIMGUI_API void ImFont_RenderChar(CONST struct ImFont *font, ImDrawList *draw_list, float size, ImVec2 pos, ImU32 col, unsigned short c) -{ - return font->RenderChar(draw_list, size, pos, col, c); -} - -CIMGUI_API void ImFont_RenderText(CONST struct ImFont *font, ImDrawList *draw_list, float size, ImVec2 pos, ImU32 col, CONST ImVec4 *clip_rect, CONST char *text_begin, CONST char *text_end, float wrap_width, bool cpu_fine_clip) -{ - return font->RenderText(draw_list, size, pos, col, *clip_rect, text_begin, text_end, wrap_width, cpu_fine_clip); -} - -// ImFont::Glyph -CIMGUI_API int ImFont_Glyphs_size(CONST struct ImFont *font) -{ - return font->Glyphs.size(); -} - -CIMGUI_API struct IMFONTGLYPH *ImFont_Glyphs_index(struct ImFont *font, int index) -{ - return &font->Glyphs[index]; -} - -// ImFont::IndexXAdvance -CIMGUI_API int ImFont_IndexXAdvance_size(CONST struct ImFont *font) -{ - return font->IndexAdvanceX.size(); -} - -CIMGUI_API float ImFont_IndexXAdvance_index(CONST struct ImFont *font, int index) -{ - return font->IndexAdvanceX[index]; -} - -// ImFont::IndexLookup -CIMGUI_API int ImFont_IndexLookup_size(CONST struct ImFont *font) -{ - return font->IndexLookup.size(); -} - -CIMGUI_API unsigned short ImFont_IndexLookup_index(CONST struct ImFont *font, int index) -{ - return font->IndexLookup[index]; -} diff --git a/cimgui/gen_imgui_funcs.bat b/cimgui/gen_imgui_funcs.bat new file mode 100644 index 0000000..ea6af61 --- /dev/null +++ b/cimgui/gen_imgui_funcs.bat @@ -0,0 +1,9 @@ +rem this is used to rebuild imgui_structs.h +rem set your PATH if necessary for gcc and lua with: +set PATH=%PATH%;C:\mingw32\bin;C:\luaGL; + +gcc -E -DIMGUI_DISABLE_OBSOLETE_FUNCTIONS ../imgui/imgui.h | luajit.exe ./gen_imgui_funcs.lua > auto_funcs.txt + +cmd /k + + diff --git a/cimgui/gen_imgui_funcs.lua b/cimgui/gen_imgui_funcs.lua new file mode 100644 index 0000000..4362e0a --- /dev/null +++ b/cimgui/gen_imgui_funcs.lua @@ -0,0 +1,346 @@ +--script for imgui_structs.h generation +--require"vicutils.utils" +local function strip(cad) + return cad:gsub("^%s*(.-)%s*$","%1") --remove initial and final spaces +end +local function clean_spaces(cad) + cad = strip(cad) + --cad = cad:gsub("%s+","%s") --not more than one space + cad = cad:gsub("%s*([%(%),=])%s*","%1") --not spaces with ( , ) + return cad +end + + +local cimgui_overloads = { + igPushID = { + ["(const char*)"] = "igPushIDStr", + ["(const char*,const char*)"] = "igPushIDRange", + ["(const void*)"] = "igPushIDPtr", + ["(int)"] = "igPushIDInt" + } +} + +local function getcimguiname(stname,funcname) + local pre = (stname == "ImGui") and "ig" or stname.."_" + return pre..funcname +end +local function getcimguiname_overload(stname,funcname,signature) + local cname = getcimguiname(stname,funcname) + local ov_cname = cimgui_overloads[cname] and cimgui_overloads[cname][signature] --or cname + return ov_cname +end + +cdefs = {} + +location_re = '^# %d+ "([^"]*)"' +cimpath_re = '^(.*[\\/])(imgui)%.h$' +define_re = "^#define%s+([^%s]+)%s+([^%s]+)$" +--function_re = "([^()]+%w%b();)" +function_re = "(%a*%w+%b())" --"(%a*%w+%s+%w+%b())" +struct_re = "^struct%s+([^%s;]+)$" +local struct_closed_re = "^struct%s+([^%s]+);$" +local struct_closing_re = "};" +local struct_op_close_re = "%b{}" +local namespace_re = "namespace ([^%s]+)" +local namespace_closing_re = "^}" +function_closed_re = "[;}]$" +function_closing_re = "}" + +number_re = "^-?[0-9]+$" +hex_re = "0x[0-9a-fA-F]+$" + +local in_imgui = false +local in_function = false +in_namespace = false +local structnames = {} +local stname = "" +local defsT = {} +for line in io.lines() do +repeat -- simulate continue with break + + --print(line) + line = clean_spaces(line) + if #line == 0 then break end + -- Is this a preprocessor statement? + if line:sub(1,1) == "#" then + -- Is this a location pragma? + local location_match = line:match(location_re) + if location_match then + --print("location_match",line) + -- If we are transitioning to a header we need to parse, set the flag + local cimpath_match,aaa = location_match:match(cimpath_re) + in_imgui = (cimpath_match ~= nil) + --if in_gl then print(aaa) end + break + end + + + elseif in_imgui then + --print(line) + line = line:gsub("%S+",{class="struct",mutable=""}) --class -> struct + if in_function then + if line:match(function_closing_re) then + in_function = false + end + break --discard + end + if line:match(function_re) and not line:match("typedef.*%b().*%b().*") then + -- function and functypedef + if not line:match(function_closed_re) then + in_function = true + end + end + if line:match(namespace_re) then + in_namespace = true + stname = line:match(namespace_re) + end + if in_namespace then + if line:match(namespace_closing_re) then + in_namespace = false + stname = "" + end + end + structnames[#structnames + 1] = line:match(struct_re) + if #structnames > 0 then + if line:match(struct_closing_re) and not line:match(struct_op_close_re) then + structnames[#structnames] = nil + end + stname = structnames[#structnames] or "" + end + --print("pre func re:",line) + local func = line:match(function_re) + if func and not in_function and not line:match("typedef.*%b().*%b().*") then--not line:match("typedef.*%b().*%b().*") then + --print(2,line) + + if stname~="ImVector" and not line:match("operator") then + + --clean implemetation + line = line:gsub("%s*%b{}","") + --clean attribute + line = line:gsub("%s*__attribute__%b()","") + + local ret = line:match("([^%(%)]+)[%s%*]~?[_%w]+(%b())") --"(^.+)(%w+)(%b())" + local funcname, args = line:match("(~?[_%w]+)(%b())") + + local argscsinpars = args:gsub("(=[^,%(%)]*)(%b())","%1") + argscsinpars = argscsinpars:gsub("(=[^,%(%)]*)([,%)])","%2") + argscsinpars = argscsinpars:gsub("&","") + --print(funcname,ret,args,argscsinpars) + local signature = argscsinpars:gsub("([%w%s%*_]+)%s[%w_]+%s*([,%)])","%1%2") + signature = signature:gsub("%s*([,%)])","%1") + signature = signature:gsub(",%s*",",") + local call_args = argscsinpars:gsub("[^%(].-([%w_]+)%s*([,%)])","%1%2") + + --if line:match(".*%b()%b().*") then print("bb:",line);print("b2:",ret,funcname,args) end + if not ret then --must be constructors + if not (stname == funcname or "~"..stname==funcname) then --break end + print("bb:",line); + print("b2:",ret,stname,funcname,args) + break --are function defs + end + end + + --local cimguiname = getcimguiname_overload(stname,funcname,signature) + local cimguiname = getcimguiname(stname,funcname) + table.insert(cdefs,{stname=stname,funcname=funcname,args=args,argsc=argscsinpars,signature=signature,cimguiname=cimguiname,call_args=call_args,ret =ret}) + + defsT[cimguiname] = defsT[cimguiname] or {} + table.insert(defsT[cimguiname],{}) + local defT = defsT[cimguiname][#defsT[cimguiname]] + --for k,def in args:gmatch("([%w%s]+)=([%w%(%)%s,]+)[,%)]") do + defT.defaults = {} + for k,def in args:gmatch("([%w%s%*]+)=([%w%(%)%s,%*]+)[,%)]") do + defT.defaults[k]=def + --print(k, def) + end + defT.cimguiname = cimguiname + defT.stname = stname + defT.funcname = funcname + defT.args=argscsinpars + defT.signature = signature + defT.call_args = call_args + if ret then + defT.ret = ret:gsub("&","*") + defT.retref = ret:match("&") + end + defsT[cimguiname][signature] = defT + + end + end + + end + +until true +end + + +--[[ +for s in str:gsub("(%[.-%])", + function(x) + return x:gsub("%s+", "\0") + end) + :gmatch "%S+" +do + print( (s:gsub("%z+", " ")) ) +end +--]] + +local alltypes = {} +local function get_types(v) + for i,t in ipairs(v) do + local signature = t.signature:sub(2,-2) -- without parenthesis + for typec in signature:gsub("(%(.-%))", function(x) return x:gsub(",","\0") end):gmatch(".-([^,]+),?") do + local key = typec:gsub("%z+", ",") + alltypes[key] = true + end + end +end + +local function name_overloadsAlgo(v) + local aa = {} + local bb = {} + local done = {} + local maxnum = 0 + for i,t in ipairs(v) do + bb[i] = "" + local signature = t.signature:sub(2,-2) -- without parenthesis + aa[i] = {} + local num = 1 + --for typec in t.signature:gmatch(".-([^,%(%s]+)[,%)]") do + --for typec in t.signature:gmatch(".-([^,%(]+)[,%)]") do + --for typec in signature:gmatch(".-([^,]+),?") do + for typec in signature:gsub("(%(.-%))", function(x) return x:gsub(",","\0") end):gmatch(".-([^,]+),?") do + --typec = typec:gsub + aa[i][num] = typec:gsub("%z+", ",") + num = num + 1 + end + num = num - 1 + maxnum = (num > maxnum) and num or maxnum + end + + for l=1,maxnum do + local keys = {} + local diferent = true + local equal = true + for i=1,#v do + aa[i][l] = aa[i][l] or "nil" + keys[aa[i][l]] = 1 + (aa[i][l] and keys[aa[i][l]] or 0) + if not done[i] then + for j=i+1,#v do + if not done[j] then + if aa[i][l] == aa[j][l] then + diferent = false + else + equal = false + end + end + end + end + end + --if not diferent then assert(#keys == 1) end + if not equal then -- not all the same + --prtable(keys) + for i=1,#v do + if not done[i] then + bb[i] = bb[i]..(aa[i][l]=="nil" and "" or aa[i][l]) + if keys[aa[i][l]] == 1 then + done[i] = true + end + end + end + --for i=1,#v do + -- bb[i] = bb[i]..tostring(aa[i][l]) + --end + end + end + return aa,bb +end +local function typetoStr(typ) + typ = typ:gsub("[^%(%)]+%(%*?(.+)%).+","%1") -- funcs + typ = typ:gsub("[%w_]+%[(%d*)%]","arr%1") + typ = typ:gsub("%*","Ptr") + typ = typ:gsub("void","") + typ = typ:gsub("unsigned%s","u") + typ = typ:gsub("const%s","")--"c") + typ = typ:gsub("%s+","_") + typ = typ:gsub("charPtr","Str") + typ = typ:gsub("int","Int") + typ = typ:gsub("bool","Bool") + typ = typ:gsub("float","Float") + typ = typ:gsub("uInt","Uint") + typ = typ:gsub("ImGui","") + typ = typ:gsub("Im","") + typ = typ:gsub("[<>]","") + return typ +end +local numoverloaded = 0 +print"overloading" +for k,v in pairs(defsT) do + get_types(v) + if #v > 1 then + numoverloaded = numoverloaded + #v + print(k,#v) + local typesc,post = name_overloadsAlgo(v) + for i,t in ipairs(v) do + t.ov_cimguiname = getcimguiname_overload(t.stname,t.funcname,t.signature) or k..typetoStr(post[i]) + print(i,t.signature,t.ret,t.ov_cimguiname)--post[i],typetoStr(post[i])) + --prtable(typesc[i]) + end + end +end +print(numoverloaded, "overloaded") +print"//-------------------------------------------------------------------------------------" + +for k,v in pairs(alltypes) do print(k, typetoStr(k) ) end +print"//-------------------------------------------------------------------------------------" + +for i,t in ipairs(cdefs) do + print(t.cimguiname," ",t.funcname,"\t",t.signature,"\t",t.args,"\t",t.argsc,"\t",t.call_args,"\t",t.ret) --,"\n") +end +print"//-------------------------------------------------------------------------------------" +--[[ +print"//constructors------------------------------------------------------------------" +for i,t in ipairs(cdefs) do + if not t.ret then + print(t.cimguiname,"\t",t.signature,"\t",t.args,"\t",t.argsc,"\t",t.call_args,"\t",t.ret) --,"\n") + end +end +--]] +local hfile = io.open("./auto_funcs.h","w") +for _,t in ipairs(cdefs) do + local cimf = defsT[t.cimguiname] + local def = cimf[t.signature] + if def.ret then --not constructor + if def.stname == "ImGui" then + hfile:write("CIMGUI_API"," ",def.ret," ",def.ov_cimguiname or def.cimguiname,def.args,";\n") + else + local args = def.args:gsub("^%(","("..def.stname.."* self,") + hfile:write("CIMGUI_API"," ",def.ret," ",def.ov_cimguiname or def.cimguiname,args,";\n") + end + end +end +hfile:close() +print"//-------------------------------------------------------------------------------------" +local cppfile = io.open("./auto_funcs.cpp","w") +for _,t in ipairs(cdefs) do + local cimf = defsT[t.cimguiname] + --for i,def in ipairs(cimf) do + --prtable(cimf) + local def = cimf[t.signature] + if def.ret then --not constructor + if def.stname == "ImGui" then + cppfile:write("CIMGUI_API"," ",def.ret," ",def.ov_cimguiname or def.cimguiname,def.args,"\n") + cppfile:write("{\n") + cppfile:write(" return ImGui::",def.funcname,def.call_args,";\n") + cppfile:write("}\n") + else + local args = def.args:gsub("^%(","("..def.stname.."* self,") + cppfile:write("CIMGUI_API"," ",def.ret," ",def.ov_cimguiname or def.cimguiname,args,"\n") + cppfile:write("{\n") + cppfile:write(" return self->",def.funcname,def.call_args,";\n") + cppfile:write("}\n") + end + end + --end +end +cppfile:close() diff --git a/cimgui/listClipper.cpp b/cimgui/listClipper.cpp deleted file mode 100644 index aea0a21..0000000 --- a/cimgui/listClipper.cpp +++ /dev/null @@ -1,27 +0,0 @@ -#include "../imgui/imgui.h" -#include "cimgui.h" - -CIMGUI_API void ImGuiListClipper_Begin(ImGuiListClipper* clipper, int count, float items_height) -{ - clipper->Begin(count, items_height); -} - -CIMGUI_API void ImGuiListClipper_End(ImGuiListClipper* clipper) -{ - clipper->End(); -} - -CIMGUI_API bool ImGuiListClipper_Step(ImGuiListClipper* clipper) -{ - return clipper->Step(); -} - -CIMGUI_API int ImGuiListClipper_GetDisplayStart(ImGuiListClipper* clipper) -{ - return clipper->DisplayStart; -} - -CIMGUI_API int ImGuiListClipper_GetDisplayEnd(ImGuiListClipper* clipper) -{ - return clipper->DisplayEnd; -}