ScrollbarRounding=9.0f;// Radius of grab corners rounding for scrollbar
GrabMinSize=10.0f;// Minimum width/height of a grab box for slider/scrollbar
GrabRounding=0.0f;// Radius of grabs corners rounding. Set to 0.0f to have rectangular slider grabs.
LogSliderDeadzone=4.0f;// The size in pixels of the dead-zone around zero on logarithmic sliders that cross zero.
TabRounding=4.0f;// Radius of upper corners of a tab. Set to 0.0f to have rectangular tabs.
TabBorderSize=0.0f;// Thickness of border around tabs.
TabMinWidthForUnselectedCloseButton=0.0f;// Minimum width for close button to appears on an unselected tab when hovered. Set to 0.0f to always show when hovering, set to FLT_MAX to never show close button unless selected.
// (Integer encoded as XYYZZ for use in #if preprocessor conditionals. Work in progress versions typically starts at XYY99 then bounce up to XYY00, XYY01 etc. when release tagging happens)
// Define attributes of all API symbols declarations (e.g. for DLL under Windows)
@ -157,6 +157,7 @@ typedef int ImGuiButtonFlags; // -> enum ImGuiButtonFlags_ // Flags: f
typedefintImGuiColorEditFlags;// -> enum ImGuiColorEditFlags_ // Flags: for ColorEdit4(), ColorPicker4() etc.
typedefintImGuiConfigFlags;// -> enum ImGuiConfigFlags_ // Flags: for io.ConfigFlags
typedefintImGuiComboFlags;// -> enum ImGuiComboFlags_ // Flags: for BeginCombo()
typedefintImGuiDragFlags;// -> enum ImGuiDragFlags_ // Flags: for DragFloat(), DragInt() etc.
typedefintImGuiDragDropFlags;// -> enum ImGuiDragDropFlags_ // Flags: for BeginDragDropSource(), AcceptDragDropPayload()
typedefintImGuiFocusedFlags;// -> enum ImGuiFocusedFlags_ // Flags: for IsWindowFocused()
typedefintImGuiHoveredFlags;// -> enum ImGuiHoveredFlags_ // Flags: for IsItemHovered(), IsWindowHovered() etc.
@ -164,6 +165,7 @@ typedef int ImGuiInputTextFlags; // -> enum ImGuiInputTextFlags_ // Flags: f
typedefintImGuiKeyModFlags;// -> enum ImGuiKeyModFlags_ // Flags: for io.KeyMods (Ctrl/Shift/Alt/Super)
typedefintImGuiPopupFlags;// -> enum ImGuiPopupFlags_ // Flags: for OpenPopup*(), BeginPopupContext*(), IsPopupOpen()
typedefintImGuiSelectableFlags;// -> enum ImGuiSelectableFlags_ // Flags: for Selectable()
typedefintImGuiSliderFlags;// -> enum ImGuiSliderFlags_ // Flags: for SliderFloat(), SliderInt() etc.
typedefintImGuiTabBarFlags;// -> enum ImGuiTabBarFlags_ // Flags: for BeginTabBar()
typedefintImGuiTabItemFlags;// -> enum ImGuiTabItemFlags_ // Flags: for BeginTabItem()
typedefintImGuiTreeNodeFlags;// -> enum ImGuiTreeNodeFlags_ // Flags: for TreeNode(), TreeNodeEx(), CollapsingHeader()
@ -462,39 +464,45 @@ namespace ImGui
// - CTRL+Click on any drag box to turn them into an input box. Manually input values aren't clamped and 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
// - Adjust format string to decorate the value with a prefix, a suffix, or adapt the editing and display precision e.g. "%.3f" -> 1.234; "%5.2f secs" -> 01.23 secs; "Biscuit: %.0f" -> Biscuit: 1; etc.
// - Format string may also be set to NULL or use the default format ("%f" or "%d").
// - Speed are per-pixel of mouse movement (v_speed=0.2f: mouse needs to move by 5 pixels to increase value by 1). For gamepad/keyboard navigation, minimum speed is Max(v_speed, minimum_step_at_given_precision).
// - Use v_min < v_max to clamp edits to given limits. Note that CTRL+Click manual input can override those limits.
// - Use v_max = FLT_MAX / INT_MAX etc to avoid clamping to a maximum, same with v_min = -FLT_MAX / INT_MIN to avoid clamping to a minimum.
IMGUI_APIboolDragFloat(constchar*label,float*v,floatv_speed=1.0f,floatv_min=0.0f,floatv_max=0.0f,constchar*format="%.3f",floatpower=1.0f);// If v_min >= v_max we have no bound
// - Legacy: Pre-1.78 there are DragXXX() function signatures that takes a final `float power=1.0f' argument instead of the `ImGuiDragFlags flags=0' argument.
// If you get a warning converting a float to ImGuiDragFlags, read https://github.com/ocornut/imgui/issues/3361
IMGUI_APIboolDragFloat(constchar*label,float*v,floatv_speed=1.0f,floatv_min=0.0f,floatv_max=0.0f,constchar*format="%.3f",ImGuiDragFlagsflags=0);// If v_min >= v_max we have no bound
IMGUI_APIboolDragInt(constchar*label,int*v,floatv_speed=1.0f,intv_min=0,intv_max=0,constchar*format="%d",ImGuiDragFlagsflags=0);// If v_min >= v_max we have no bound
// - CTRL+Click on any slider to turn them into an input box. Manually input values aren't clamped and can go off-bounds.
// - Adjust format string to decorate the value with a prefix, a suffix, or adapt the editing and display precision e.g. "%.3f" -> 1.234; "%5.2f secs" -> 01.23 secs; "Biscuit: %.0f" -> Biscuit: 1; etc.
IMGUI_APIboolSliderFloat(constchar*label,float*v,floatv_min,floatv_max,constchar*format="%.3f",floatpower=1.0f);// adjust format to decorate the value with a prefix or a suffix for in-slider labels or unit display. Use power!=1.0 for power curve sliders
// - Format string may also be set to NULL or use the default format ("%f" or "%d").
// - Legacy: Pre-1.78 there are SliderXXX() function signatures that takes a final `float power=1.0f' argument instead of the `ImGuiSliderFlags flags=0' argument.
// If you get a warning converting a float to ImGuiSliderFlags, read https://github.com/ocornut/imgui/issues/3361
IMGUI_APIboolSliderFloat(constchar*label,float*v,floatv_min,floatv_max,constchar*format="%.3f",ImGuiSliderFlagsflags=0);// adjust format to decorate the value with a prefix or a suffix for in-slider labels or unit display.
// - If you want to use InputText() with std::string or any custom dynamic string type, see misc/cpp/imgui_stdlib.h and comments in imgui_demo.cpp.
@ -1282,6 +1290,28 @@ enum ImGuiColorEditFlags_
#endif
};
// Flags for DragFloat(), DragInt() etc.
enumImGuiDragFlags_
{
ImGuiDragFlags_None=0,
ImGuiDragFlags_InvalidMask_=0x7000000F,// [Internal] We treat using those bits as being potentially a 'float power' argument from the previous API that has got miscast to this enum, and will trigger an assert if needed.
ImGuiDragFlags_ClampOnInput=1<<4,// Clamp value to min/max bounds (if any) when input manually with CTRL+Click. By default CTRL+Click allows going out of bounds.
ImGuiDragFlags_Logarithmic=1<<5,// Make the widget logarithmic (linear otherwise). Consider using ImGuiDragFlags_NoRoundToFormat with this if using a format-string with small amount of digits.
ImGuiDragFlags_NoRoundToFormat=1<<6,// Disable rounding underlying value to match precision of the display format string (e.g. %.3f values are rounded to those 3 digits)
ImGuiDragFlags_NoInput=1<<7// Disable CTRL+Click or Enter key allowing to input text directly into the widget
};
// Flags for SliderFloat(), SliderInt() etc.
enumImGuiSliderFlags_
{
ImGuiSliderFlags_None=0,
ImGuiSliderFlags_InvalidMask_=0x7000000F,// [Internal] We treat using those bits as being potentially a 'float power' argument from the previous API that has got miscast to this enum, and will trigger an assert if needed.
ImGuiSliderFlags_ClampOnInput=1<<4,// Clamp value to min/max bounds when input manually with CTRL+Click. By default CTRL+Click allows going out of bounds.
ImGuiSliderFlags_Logarithmic=1<<5,// Make the widget logarithmic (linear otherwise). Consider using ImGuiSliderFlags_NoRoundToFormat with this if using a format-string with small amount of digits.
ImGuiSliderFlags_NoRoundToFormat=1<<6,// Disable rounding underlying value to match precision of the display format string (e.g. %.3f values are rounded to those 3 digits)
ImGuiSliderFlags_NoInput=1<<7// Disable CTRL+Click or Enter key allowing to input text directly into the widget
};
// Identify a mouse button.
// Those values are guaranteed to be stable and we frequently use 0/1 directly. Named enums provided for convenience.
enumImGuiMouseButton_
@ -1443,6 +1473,7 @@ struct ImGuiStyle
floatScrollbarRounding;// Radius of grab corners for scrollbar.
floatGrabMinSize;// Minimum width/height of a grab box for slider/scrollbar.
floatGrabRounding;// Radius of grabs corners rounding. Set to 0.0f to have rectangular slider grabs.
floatLogSliderDeadzone;// The size in pixels of the dead-zone around zero on logarithmic sliders that cross zero.
floatTabRounding;// Radius of upper corners of a tab. Set to 0.0f to have rectangular tabs.
floatTabBorderSize;// Thickness of border around tabs.
floatTabMinWidthForUnselectedCloseButton;// Minimum width for close button to appears on an unselected tab when hovered. Set to 0.0f to always show when hovering, set to FLT_MAX to never show close button unless selected.
@ -1685,6 +1716,20 @@ struct ImGuiPayload
#ifndef IMGUI_DISABLE_OBSOLETE_FUNCTIONS
namespaceImGui
{
// OBSOLETED in 1.78 (from August 2020)
// Old drag/sliders functions that took a 'float power = 1.0' argument instead of flags
staticinlineboolOpenPopupOnItemClick(constchar*str_id=NULL,ImGuiMouseButtonmb=1){returnOpenPopupContextItem(str_id,mb);}// Passing a mouse button to ImGuiPopupFlags is legal
ImGui::SameLine();HelpMarker("Disable rounding underlying value to match precision of the format string (e.g. %.3f values are rounded to those 3 digits).");
ImGui::SameLine();HelpMarker("Disable rounding underlying value to match precision of the format string (e.g. %.3f values are rounded to those 3 digits).");
ImGui::DragScalar("drag float ^2",ImGuiDataType_Float,&f32_v,0.005f,&f32_zero,&f32_one,"%f",2.0f);ImGui::SameLine();HelpMarker("You can use the 'power' parameter to increase tweaking precision on one side of the range.");
IMGUI_APIboolTreeNodeBehaviorIsOpen(ImGuiIDid,ImGuiTreeNodeFlagsflags=0);// Consume previous SetNextItemOpen() data, if any. May return true when logging
@ -1985,9 +1995,10 @@ namespace ImGui
// Template functions are instantiated in imgui_widgets.cpp for a finite number of types.
// To use them externally (for custom widget) you may need an "extern template" statement in your code in order to link to existing instances and silence Clang warnings (see #2036).
// e.g. " extern template IMGUI_API float RoundScalarWithFormatT<float, float>(const char* format, ImGuiDataType data_type, float v); "