Demo: Custom rendering: Minor sizing issue fix.

This commit is contained in:
omar 2019-03-13 15:44:23 +01:00
parent 55c02099c5
commit ebe79bbed0

View File

@ -4072,7 +4072,7 @@ static void ShowExampleAppCustomRendering(bool* p_open)
draw_list->AddRectFilled(ImVec2(x, y), ImVec2(x + thickness, y + sz), col32); x += spacing + spacing; // Vertical line (faster than AddLine, but only handle integer thickness)
draw_list->AddRectFilled(ImVec2(x, y), ImVec2(x + 1, y + 1), col32); x += sz; // Pixel (faster than AddLine)
draw_list->AddRectFilledMultiColor(ImVec2(x, y), ImVec2(x + sz, y + sz), IM_COL32(0, 0, 0, 255), IM_COL32(255, 0, 0, 255), IM_COL32(255, 255, 0, 255), IM_COL32(0, 255, 0, 255));
ImGui::Dummy(ImVec2((sz + spacing) * 8, (sz + spacing) * 3));
ImGui::Dummy(ImVec2((sz + spacing) * 9.5f, (sz + spacing) * 3));
ImGui::EndTabItem();
}