mirror of
https://github.com/wavetermdev/xterm.js.git
synced 2026-08-05 13:43:48 -07:00
[issue #164] Fix bug that can occur when setting a scroll region
This commit is contained in:
+1
-1
@@ -1446,7 +1446,7 @@ export class InputHandler implements IInputHandler {
|
||||
public setScrollRegion(params: number[]): void {
|
||||
if (this._terminal.prefix) return;
|
||||
this._terminal.scrollTop = (params[0] || 1) - 1;
|
||||
this._terminal.scrollBottom = (params[1] || this._terminal.rows) - 1;
|
||||
this._terminal.scrollBottom = (params[1] && params[1] <= this._terminal.rows ? params[1] : this._terminal.rows) - 1;
|
||||
this._terminal.x = 0;
|
||||
this._terminal.y = 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user