mirror of
https://github.com/xemu-project/imgui.git
synced 2024-11-23 18:29:51 +00:00
Columns: Separator: Fixed a bug where non-visible separators within columns would alter the next row position differently than visible ones.
Fixed rounding issues also leading to change of ScrollMax depending on visible items (in particular negative coordinate would be rounded differently)
This commit is contained in:
parent
b05f6f6f50
commit
3dcf323c35
@ -45,6 +45,8 @@ Other Changes:
|
||||
(before 1.71 tab bars fed the sum of current width which created feedback loops in certain situations).
|
||||
- TabBar: improved shrinking for large number of tabs to avoid leaving extraneous space on the right side.
|
||||
Individuals tabs are given integer-rounded width and remainder is spread between tabs left-to-right.
|
||||
- Columns, Separator: Fixed a bug where non-visible separators within columns would alter the next row position
|
||||
differently than visible ones.
|
||||
- SliderScalar: Improved assert when using U32 or U64 types with a large v_max value. (#2765) [@loicmouton]
|
||||
- DragInt, DragFloat, DragScalar: Using (v_min > v_max) allows locking any edit to the value.
|
||||
- DragScalar: Fixed dragging of unsigned values on ARM cpu. (#2780) [@dBagrat]
|
||||
|
@ -1451,7 +1451,7 @@ static void ShowDemoWindowWidgets()
|
||||
ImGui::PushID("set2");
|
||||
static float values2[4] = { 0.20f, 0.80f, 0.40f, 0.25f };
|
||||
const int rows = 3;
|
||||
const ImVec2 small_slider_size(18, (160.0f-(rows-1)*spacing)/rows);
|
||||
const ImVec2 small_slider_size(18, (float)(int)((160.0f - (rows - 1) * spacing) / rows));
|
||||
for (int nx = 0; nx < 4; nx++)
|
||||
{
|
||||
if (nx > 0) ImGui::SameLine();
|
||||
|
@ -1261,7 +1261,10 @@ void ImGui::SeparatorEx(ImGuiSeparatorFlags flags)
|
||||
if (!ItemAdd(bb, 0))
|
||||
{
|
||||
if (columns)
|
||||
{
|
||||
PopColumnsBackground();
|
||||
columns->LineMinY = window->DC.CursorPos.y;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
@ -5624,7 +5627,7 @@ bool ImGui::ListBoxHeader(const char* label, int items_count, int height_in_item
|
||||
// We include ItemSpacing.y so that a list sized for the exact number of items doesn't make a scrollbar appears. We could also enforce that by passing a flag to BeginChild().
|
||||
ImVec2 size;
|
||||
size.x = 0.0f;
|
||||
size.y = GetTextLineHeightWithSpacing() * height_in_items_f + style.FramePadding.y * 2.0f;
|
||||
size.y = ImFloor(GetTextLineHeightWithSpacing() * height_in_items_f + style.FramePadding.y * 2.0f);
|
||||
return ListBoxHeader(label, size);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user