mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-06 04:58:47 +02:00
ColorEdit: Fixed text baseline alignment after a SameLine() after a ColorEdit() with visible label.
This commit is contained in:
@ -4997,8 +4997,7 @@ bool ImGui::ColorEdit4(const char* label, float col[4], ImGuiColorEditFlags flag
|
||||
|
||||
if (label != label_display_end && !(flags & ImGuiColorEditFlags_NoLabel))
|
||||
{
|
||||
const float text_offset_x = (flags & ImGuiColorEditFlags_NoInputs) ? w_button : w_full + style.ItemInnerSpacing.x;
|
||||
window->DC.CursorPos = ImVec2(pos.x + text_offset_x, pos.y + style.FramePadding.y);
|
||||
SameLine(0.0f, style.ItemInnerSpacing.x);
|
||||
TextEx(label, label_display_end);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user