Skip to content

Commit f5accf1

Browse files
committed
Fill inserted lines with background color
When scrolling occurs due to a LF or scroll code, the new line should be filled with the currently set background color. As with VTE, fill with the _default_ color if the new line was caused by line-wrap.
1 parent a531b4d commit f5accf1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Terminal.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1170,7 +1170,8 @@ export class Terminal extends EventEmitter implements ITerminal, IDisposable, II
11701170
* @param isWrapped Whether the new line is wrapped from the previous line.
11711171
*/
11721172
public scroll(isWrapped?: boolean): void {
1173-
const newLine = BufferLine.blankLine(this.cols, DEFAULT_ATTR, isWrapped);
1173+
const blankAttr = isWrapped ? DEFAULT_ATTR : this.eraseAttr();
1174+
const newLine = BufferLine.blankLine(this.cols, blankAttr, isWrapped);
11741175
const topRow = this.buffer.ybase + this.buffer.scrollTop;
11751176
const bottomRow = this.buffer.ybase + this.buffer.scrollBottom;
11761177

0 commit comments

Comments
 (0)