diff --git a/typings/xterm-headless.d.ts b/typings/xterm-headless.d.ts index d39a7098..04732cea 100644 --- a/typings/xterm-headless.d.ts +++ b/typings/xterm-headless.d.ts @@ -48,11 +48,6 @@ declare module 'xterm-headless' { */ convertEol?: boolean; - /** - * The number of columns in the terminal. - */ - cols?: number; - /** * Whether the cursor blinks. */ @@ -145,11 +140,6 @@ declare module 'xterm-headless' { */ rightClickSelectsWord?: boolean; - /** - * The number of rows in the terminal. - */ - rows?: number; - /** * Whether screen reader support is enabled. When on this will expose * supporting elements in the DOM to support NVDA on Windows and VoiceOver @@ -210,6 +200,22 @@ declare module 'xterm-headless' { windowOptions?: IWindowOptions; } + /** + * An object containing additional options for the terminal that can only be + * set on start up. + */ + export interface ITerminalInitOnlyOptions { + /** + * The number of columns in the terminal. + */ + cols?: number; + + /** + * The number of rows in the terminal. + */ + rows?: number; + } + /** * Contains colors to theme the terminal with. */ @@ -558,7 +564,7 @@ declare module 'xterm-headless' { * * @param options An object containing a set of options. */ - constructor(options?: ITerminalOptions); + constructor(options?: ITerminalOptions & ITerminalInitOnlyOptions); /** * Adds an event listener for when the bell is triggered.