diff --git a/src/ui/windows/console_tab.cpp b/src/ui/windows/console_tab.cpp index 118fdad..f1955dc 100644 --- a/src/ui/windows/console_tab.cpp +++ b/src/ui/windows/console_tab.cpp @@ -327,6 +327,21 @@ void ConsoleTab::render(ConsoleCommandExecutor& exec) (row.rowIndex % 2 == 0) ? lightCol : darkCol); } } + // Continue the banding into any empty space below the last text row (the bottom + // fade padding, or when the content is shorter than the panel) so the zebra fills + // the whole panel instead of stopping short. + if (!scanline_rows_.empty()) { + const auto& last = scanline_rows_.back(); + int parity = (last.rowIndex + 1) & 1; + for (float y = last.yBot; y < outPanelMax.y; y += textLineH) { + float yTop = std::max(y, outPanelMin.y); + float yBot = std::min(y + textLineH, outPanelMax.y); + if (yTop < yBot) + dlOut->AddRectFilled(ImVec2(outPanelMin.x, yTop), ImVec2(outPanelMax.x, yBot), + (parity == 0) ? lightCol : darkCol); + parity ^= 1; + } + } } float panelH = outPanelMax.y - outPanelMin.y;