From e5b838a01b8b6af0317c4ad0bf2c8b53c6751c47 Mon Sep 17 00:00:00 2001 From: Daniel Imms <2193314+Tyriar@users.noreply.github.com> Date: Mon, 21 Apr 2025 06:39:15 -0700 Subject: [PATCH] scrollOnDisplayErase -> scrollOnEraseInDisplay --- src/common/InputHandler.test.ts | 4 ++-- src/common/InputHandler.ts | 2 +- src/common/services/OptionsService.ts | 2 +- src/common/services/Services.ts | 2 +- typings/xterm-headless.d.ts | 2 +- typings/xterm.d.ts | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/common/InputHandler.test.ts b/src/common/InputHandler.test.ts index e750349e..78ce646a 100644 --- a/src/common/InputHandler.test.ts +++ b/src/common/InputHandler.test.ts @@ -438,13 +438,13 @@ describe('InputHandler', () => { inputHandler.eraseInLine(Params.fromArray([2])); assert.equal(bufferService.buffer.lines.get(2)!.isWrapped, false); }); - it('ED2 with scrollOnDisplayErase turned on', async () => { + it('ED2 with scrollOnEraseInDisplay turned on', async () => { const inputHandler = new TestInputHandler( bufferService, new MockCharsetService(), new MockCoreService(), new MockLogService(), - new MockOptionsService({ scrollOnDisplayErase: true }), + new MockOptionsService({ scrollOnEraseInDisplay: true }), new MockOscLinkService(), new MockCoreMouseService(), new MockUnicodeService() diff --git a/src/common/InputHandler.ts b/src/common/InputHandler.ts index f656014d..0e151173 100644 --- a/src/common/InputHandler.ts +++ b/src/common/InputHandler.ts @@ -1220,7 +1220,7 @@ export class InputHandler extends Disposable implements IInputHandler { this._dirtyRowTracker.markDirty(0); break; case 2: - if (this._optionsService.rawOptions.scrollOnDisplayErase) { + if (this._optionsService.rawOptions.scrollOnEraseInDisplay) { j = this._bufferService.rows; this._dirtyRowTracker.markRangeDirty(0, j - 1); while (j--) { diff --git a/src/common/services/OptionsService.ts b/src/common/services/OptionsService.ts index 4d2353f5..6ad48b93 100644 --- a/src/common/services/OptionsService.ts +++ b/src/common/services/OptionsService.ts @@ -32,7 +32,7 @@ export const DEFAULT_OPTIONS: Readonly> = { logLevel: 'info', logger: null, scrollback: 1000, - scrollOnDisplayErase: false, + scrollOnEraseInDisplay: false, scrollOnUserInput: true, scrollSensitivity: 1, screenReaderMode: false, diff --git a/src/common/services/Services.ts b/src/common/services/Services.ts index 33b3eb56..9c3aebf7 100644 --- a/src/common/services/Services.ts +++ b/src/common/services/Services.ts @@ -254,7 +254,7 @@ export interface ITerminalOptions { windowOptions?: IWindowOptions; wordSeparator?: string; overviewRuler?: IOverviewRulerOptions; - scrollOnDisplayErase?: boolean; + scrollOnEraseInDisplay?: boolean; [key: string]: any; cancelEvents: boolean; diff --git a/typings/xterm-headless.d.ts b/typings/xterm-headless.d.ts index f0bc42da..8d1facc7 100644 --- a/typings/xterm-headless.d.ts +++ b/typings/xterm-headless.d.ts @@ -191,7 +191,7 @@ declare module '@xterm/headless' { * erased text to scrollback, instead of clearing only the viewport portion. * This emulates PuTTY's default clear screen behavior. */ - scrollOnDisplayErase?: boolean; + scrollOnEraseInDisplay?: boolean; /** * The scrolling speed multiplier used for adjusting normal scrolling speed. diff --git a/typings/xterm.d.ts b/typings/xterm.d.ts index 9f0e0fb4..1310009e 100644 --- a/typings/xterm.d.ts +++ b/typings/xterm.d.ts @@ -262,7 +262,7 @@ declare module '@xterm/xterm' { * erased text to scrollback, instead of clearing only the viewport portion. * This emulates PuTTY's default clear screen behavior. */ - scrollOnDisplayErase?: boolean; + scrollOnEraseInDisplay?: boolean; /** * Whether to scroll to the bottom whenever there is some user input. The