Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions packages/xterm/lib/src/ui/painter.dart
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,7 @@ class TerminalPainter {
if (cellData.flags & CellFlags.inverse != 0) {
color = resolveForegroundColor(cellData.foreground);
} else if (colorType == CellColor.normal) {
Copy link

Copilot AI Jan 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding a comment to explain why normal cells return early. This would help future maintainers understand that the terminal background is already painted in render.dart (lines 462-465), and painting normal cell backgrounds here would cover selection highlights and other overlays. For example: "Skip painting background for normal cells - the terminal background is already painted in render.dart and painting here would cover selection highlights."

Suggested change
} else if (colorType == CellColor.normal) {
} else if (colorType == CellColor.normal) {
// Skip painting background for normal cells - the terminal background is
// already painted in render.dart and painting here would cover selection
// highlights and other overlays.

Copilot uses AI. Check for mistakes.
// Always paint background for normal cells to prevent gaps.
// Previously this returned early, leaving gaps between lines.
color = _theme.background;
return;
} else {
color = resolveBackgroundColor(cellData.background);
}
Expand Down