This commit is contained in:
Jason Lin
2022-12-07 10:12:43 +11:00
parent 73d20c1d3b
commit 9e84895141
5 changed files with 9 additions and 9 deletions
+1 -1
View File
@@ -68,7 +68,7 @@ export class CoreService extends Disposable implements ICoreService {
// Input is being sent to the terminal, the terminal should focus the prompt.
const buffer = this._bufferService.buffer;
if (wasUserInput && this._optionsService.rawOptions.scrollOnKeypress && buffer.ybase !== buffer.ydisp) {
if (wasUserInput && this._optionsService.rawOptions.scrollOnUserInput && buffer.ybase !== buffer.ydisp) {
this._scrollToBottom!();
}
+1 -1
View File
@@ -28,7 +28,7 @@ export const DEFAULT_OPTIONS: Readonly<Required<ITerminalOptions>> = {
linkHandler: null,
logLevel: 'info',
scrollback: 1000,
scrollOnKeypress: true,
scrollOnUserInput: true,
scrollSensitivity: 1,
screenReaderMode: false,
smoothScrollDuration: 0,
+3 -3
View File
@@ -85,9 +85,9 @@ export interface ICoreService {
/**
* Triggers the onData event in the public API.
* @param data The data that is being emitted.
* @param wasFromUser Whether the data originated from the user (as opposed to
* @param wasUserInput Whether the data originated from the user (as opposed to
* resulting from parsing incoming data). When true this will also:
* - Scroll to the bottom of the buffer if option scrollOnKeypress is true.
* - Scroll to the bottom of the buffer if option scrollOnUserInput is true.
* - Fire the `onUserInput` event (so selection can be cleared).
*/
triggerDataEvent(data: string, wasUserInput?: boolean): void;
@@ -243,7 +243,7 @@ export interface ITerminalOptions {
rows?: number;
screenReaderMode?: boolean;
scrollback?: number;
scrollOnKeypress?: boolean;
scrollOnUserInput?: boolean;
scrollSensitivity?: number;
smoothScrollDuration?: number;
tabStopWidth?: number;