mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-06 13:08:47 +02:00
GetStyleColorName -> GetStyleColName for consistency with type name. Removed ImGuiStyleVar_ColumnsMinSpacing
This commit is contained in:
@ -348,13 +348,13 @@ ImGuiStyle::ImGuiStyle()
|
||||
Alpha = 1.0f; // Global alpha applies to everything in ImGui
|
||||
WindowPadding = ImVec2(8,8); // Padding within a window
|
||||
WindowMinSize = ImVec2(48,48); // Minimum window size
|
||||
WindowRounding = 10.0f; // Radius of window corners rounding. Set to 0.0f to have rectangular windows
|
||||
FramePadding = ImVec2(5,4); // Padding within a framed rectangle (used by most widgets)
|
||||
ItemSpacing = ImVec2(10,5); // Horizontal and vertical spacing between widgets/lines
|
||||
ItemInnerSpacing = ImVec2(5,5); // Horizontal and vertical spacing between within elements of a composed widget (e.g. a slider and its label)
|
||||
TouchExtraPadding = ImVec2(0,0); // Expand bounding box for touch-based system where touch position is not accurate enough (unnecessary for mouse inputs). Unfortunately we don't sort widgets so priority on overlap will always be given to the first widget running. So dont grow this too much!
|
||||
AutoFitPadding = ImVec2(8,8); // Extra space after auto-fit (double-clicking on resize grip)
|
||||
WindowFillAlphaDefault = 0.70f; // Default alpha of window background, if not specified in ImGui::Begin()
|
||||
WindowRounding = 10.0f; // Radius of window corners rounding. Set to 0.0f to have rectangular windows
|
||||
TreeNodeSpacing = 22.0f; // Horizontal spacing when entering a tree node
|
||||
ColumnsMinSpacing = 6.0f; // Minimum horizontal spacing between two columns
|
||||
ScrollBarWidth = 16.0f; // Width of the vertical scroll bar
|
||||
@ -2758,7 +2758,6 @@ static float* GetStyleVarFloatAddr(ImGuiStyleVar idx)
|
||||
case ImGuiStyleVar_Alpha: return &g.Style.Alpha;
|
||||
case ImGuiStyleVar_WindowRounding: return &g.Style.WindowRounding;
|
||||
case ImGuiStyleVar_TreeNodeSpacing: return &g.Style.TreeNodeSpacing;
|
||||
case ImGuiStyleVar_ColumnsMinSpacing: return &g.Style.ColumnsMinSpacing;
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
@ -2819,7 +2818,7 @@ void ImGui::PopStyleVar(int count)
|
||||
}
|
||||
}
|
||||
|
||||
const char* ImGui::GetStyleColorName(ImGuiCol idx)
|
||||
const char* ImGui::GetStyleColName(ImGuiCol idx)
|
||||
{
|
||||
// Create switch-case from enum with regexp: ImGuiCol_{.*}, --> case ImGuiCol_\1: return "\1";
|
||||
switch (idx)
|
||||
@ -6719,7 +6718,7 @@ void ImGui::ShowStyleEditor(ImGuiStyle* ref)
|
||||
ImGui::ColorEditMode(edit_mode);
|
||||
for (int i = 0; i < ImGuiCol_COUNT; i++)
|
||||
{
|
||||
const char* name = GetStyleColorName(i);
|
||||
const char* name = ImGui::GetStyleColName(i);
|
||||
if (!filter.PassFilter(name))
|
||||
continue;
|
||||
ImGui::PushID(i);
|
||||
|
Reference in New Issue
Block a user