MCPcopy Create free account
hub / github.com/danoon2/Boxedwine / RenderCheckMark

Method RenderCheckMark

lib/imgui/imgui.cpp:2543–2559  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2541}
2542
2543void ImGui::RenderCheckMark(ImVec2 pos, ImU32 col, float sz)
2544{
2545 ImGuiContext& g = *GImGui;
2546 ImGuiWindow* window = g.CurrentWindow;
2547
2548 float thickness = ImMax(sz / 5.0f, 1.0f);
2549 sz -= thickness*0.5f;
2550 pos += ImVec2(thickness*0.25f, thickness*0.25f);
2551
2552 float third = sz / 3.0f;
2553 float bx = pos.x + third;
2554 float by = pos.y + sz - third*0.5f;
2555 window->DrawList->PathLineTo(ImVec2(bx - third, by - third));
2556 window->DrawList->PathLineTo(ImVec2(bx, by));
2557 window->DrawList->PathLineTo(ImVec2(bx + third*2, by - third*2));
2558 window->DrawList->PathStroke(col, false, thickness);
2559}
2560
2561void ImGui::RenderNavHighlight(const ImRect& bb, ImGuiID id, ImGuiNavHighlightFlags flags)
2562{

Callers

nothing calls this directly

Calls 4

ImMaxFunction · 0.85
ImVec2Class · 0.85
PathLineToMethod · 0.80
PathStrokeMethod · 0.80

Tested by

no test coverage detected