|
@@ -867,11 +867,12 @@ bool ImGui::CloseButton(ImGuiID id, const ImVec2& pos)
|
|
|
if (hovered)
|
|
|
window->DrawList->AddRectFilled(bb.Min, bb.Max, bg_col);
|
|
|
RenderNavCursor(bb, id, ImGuiNavRenderCursorFlags_Compact);
|
|
|
- ImU32 cross_col = GetColorU32(ImGuiCol_Text);
|
|
|
- ImVec2 cross_center = bb.GetCenter() - ImVec2(0.5f, 0.5f);
|
|
|
- float cross_extent = g.FontSize * 0.5f * 0.7071f - 1.0f;
|
|
|
- window->DrawList->AddLine(cross_center + ImVec2(+cross_extent, +cross_extent), cross_center + ImVec2(-cross_extent, -cross_extent), cross_col, 1.0f);
|
|
|
- window->DrawList->AddLine(cross_center + ImVec2(+cross_extent, -cross_extent), cross_center + ImVec2(-cross_extent, +cross_extent), cross_col, 1.0f);
|
|
|
+ const ImU32 cross_col = GetColorU32(ImGuiCol_Text);
|
|
|
+ const ImVec2 cross_center = bb.GetCenter() - ImVec2(0.5f, 0.5f);
|
|
|
+ const float cross_extent = g.FontSize * 0.5f * 0.7071f - 1.0f;
|
|
|
+ const float cross_thickness = 1.0f; // FIXME-DPI
|
|
|
+ window->DrawList->AddLine(cross_center + ImVec2(+cross_extent, +cross_extent), cross_center + ImVec2(-cross_extent, -cross_extent), cross_col, cross_thickness);
|
|
|
+ window->DrawList->AddLine(cross_center + ImVec2(+cross_extent, -cross_extent), cross_center + ImVec2(-cross_extent, +cross_extent), cross_col, cross_thickness);
|
|
|
|
|
|
return pressed;
|
|
|
}
|
|
@@ -1478,7 +1479,7 @@ bool ImGui::TextLink(const char* label)
|
|
|
}
|
|
|
|
|
|
float line_y = bb.Max.y + ImFloor(g.Font->Descent * g.FontScale * 0.20f);
|
|
|
- window->DrawList->AddLine(ImVec2(bb.Min.x, line_y), ImVec2(bb.Max.x, line_y), GetColorU32(line_colf)); // FIXME-TEXT: Underline mode.
|
|
|
+ window->DrawList->AddLine(ImVec2(bb.Min.x, line_y), ImVec2(bb.Max.x, line_y), GetColorU32(line_colf)); // FIXME-TEXT: Underline mode // FIXME-DPI
|
|
|
|
|
|
PushStyleColor(ImGuiCol_Text, GetColorU32(text_colf));
|
|
|
RenderText(bb.Min, label, label_end);
|
|
@@ -5339,7 +5340,7 @@ bool ImGui::InputTextEx(const char* label, const char* hint, char* buf, int buf_
|
|
|
ImVec2 cursor_screen_pos = ImTrunc(draw_pos + cursor_offset - draw_scroll);
|
|
|
ImRect cursor_screen_rect(cursor_screen_pos.x, cursor_screen_pos.y - g.FontSize + 0.5f, cursor_screen_pos.x + 1.0f, cursor_screen_pos.y - 1.5f);
|
|
|
if (cursor_is_visible && cursor_screen_rect.Overlaps(clip_rect))
|
|
|
- draw_window->DrawList->AddLine(cursor_screen_rect.Min, cursor_screen_rect.GetBL(), GetColorU32(ImGuiCol_Text));
|
|
|
+ draw_window->DrawList->AddLine(cursor_screen_rect.Min, cursor_screen_rect.GetBL(), GetColorU32(ImGuiCol_Text), 1.0f); // FIXME-DPI: Cursor thickness (#7031) + Color
|
|
|
|
|
|
// Notify OS of text input position for advanced IME (-1 x offset so that Windows IME can cover our cursor. Bit of an extra nicety.)
|
|
|
if (!is_readonly)
|
|
@@ -6207,7 +6208,7 @@ bool ImGui::ColorButton(const char* desc_id, const ImVec4& col, ImGuiColorEditFl
|
|
|
if (g.Style.FrameBorderSize > 0.0f)
|
|
|
RenderFrameBorder(bb.Min, bb.Max, rounding);
|
|
|
else
|
|
|
- window->DrawList->AddRect(bb.Min, bb.Max, GetColorU32(ImGuiCol_FrameBg), rounding); // Color buttons are often in need of some sort of border
|
|
|
+ window->DrawList->AddRect(bb.Min, bb.Max, GetColorU32(ImGuiCol_FrameBg), rounding); // Color buttons are often in need of some sort of border // FIXME-DPI
|
|
|
}
|
|
|
|
|
|
// Drag and Drop Source
|
|
@@ -7486,7 +7487,7 @@ void ImGui::EndBoxSelect(const ImRect& scope_rect, ImGuiMultiSelectFlags ms_flag
|
|
|
ImRect box_select_r = bs->BoxSelectRectCurr;
|
|
|
box_select_r.ClipWith(scope_rect);
|
|
|
window->DrawList->AddRectFilled(box_select_r.Min, box_select_r.Max, GetColorU32(ImGuiCol_SeparatorHovered, 0.30f)); // FIXME-MULTISELECT: Styling
|
|
|
- window->DrawList->AddRect(box_select_r.Min, box_select_r.Max, GetColorU32(ImGuiCol_NavCursor)); // FIXME-MULTISELECT: Styling
|
|
|
+ window->DrawList->AddRect(box_select_r.Min, box_select_r.Max, GetColorU32(ImGuiCol_NavCursor)); // FIXME-MULTISELECT FIXME-DPI: Styling
|
|
|
|
|
|
// Scroll
|
|
|
const bool enable_scroll = (ms_flags & ImGuiMultiSelectFlags_ScopeWindow) && (ms_flags & ImGuiMultiSelectFlags_BoxSelectNoScroll) == 0;
|