window
Namespace for dealing with the current window of the editor. That is visible and active editors, as well as, UI elements to show messages, selections, and asking for user input.
Types
Properties
The currently active color theme as configured in the settings. The active theme can be changed via the workbench.colorTheme
setting.
The currently active notebook editor or undefined
. The active editor is the one that currently has focus or, when none has focus, the one that has changed input most recently.
The currently active terminal or undefined
. The active terminal is the one that currently has focus or most recently had focus.
The currently active editor or undefined
. The active editor is the one that currently has focus or, when none has focus, the one that has changed input most recently.
An Event which fires when the active color theme is changed or has changes.
An Event which fires when the active notebook editor has changed. Note that the event also fires when the active editor changes to undefined
.
An Event which fires when the active terminal has changed. Note that the event also fires when the active terminal changes to undefined
.
An Event which fires when the active editor has changed. Note that the event also fires when the active editor changes to undefined
.
An Event which fires when the notebook editor selections have changed.
An Event which fires when the notebook editor visible ranges have changed.
Fires when shell integration activates or one of its properties changes in a terminal.
An Event which fires when a terminal's state has changed.
An Event which fires when the options of an editor have changed.
An Event which fires when the selection in an editor has changed.
An Event which fires when the view column of an editor has changed.
An Event which fires when the visible ranges of an editor has changed.
An Event which fires when the visible notebook editors has changed.
An Event which fires when the array of visible editors has changed.
An Event which fires when the focus or activity state of the current window changes. The value of the event represents whether the window is focused.
An Event which fires when a terminal is disposed.
This will be fired when a terminal command is ended. This event will fire only when shell integration is activated for the terminal.
An Event which fires when a terminal has been created, either through the createTerminal API or commands.
This will be fired when a terminal command is started. This event will fire only when shell integration is activated for the terminal.
Represents the current window's state.
The currently opened terminals or an empty array.
The currently visible notebook editors or an empty array.
The currently visible editors or an empty array.
Functions
Creates a InputBox to let the user enter some text input.
Creates a new output channel with the given name and language id If language id is not provided, then Log is used as default language id.
Creates a QuickPick to let the user pick an item from a list of items of type T.
Creates a status bar item.
Creates a Terminal where an extension controls its input and output.
Creates a Terminal with a backing shell process.
Creates a Terminal with a backing shell process. The cwd of the terminal will be the workspace directory if it exists.
Create a TextEditorDecorationType that can be used to add decorations to text editors.
Create a TreeView for the view contributed using the extension point views
.
Register a provider for custom editors for the viewType
contributed by the customEditors
extension point.
Register a file decoration provider.
Register provider that enables the detection and handling of links within the terminal.
Registers a provider for a contributed terminal profile.
Register a TreeDataProvider for the view contributed using the extension point views
. This will allow you to contribute data to the TreeView and update if the data changes.
Registers a uri handler} capable of handling system-wide {@link Uri uris. In case there are multiple windows open, the topmost window will handle the uri. A uri handler is scoped to the extension it is contributed from; it will only be able to handle uris which are directed to the extension itself. A uri must respect the following rules:
Registers a webview panel serializer.
Register a new provider for webview views.
Set a message to the status bar. This is a short hand for the more powerful status bar items.
Show an error message.
Show an information message.
Show an information message to users. Optionally provide an array of items which will be presented as clickable buttons.
Opens an input box to ask the user for input.
Show the given NotebookDocument in a notebook editor.
Shows a file open dialog to the user which allows to select a file for opening-purposes.
Shows a selection list.
Shows a file save dialog to the user which allows to select a file for saving-purposes.
Show the given document in a text editor. Options can be provided to control options of the editor is being shown. Might change the active editor.
A short-hand for openTextDocument(uri).then(document => showTextDocument(document, options))
.
Show the given document in a text editor. A column can be provided to control where the editor is being shown. Might change the active editor.
Show a warning message.
Shows a selection list of workspace folders to pick from. Returns undefined
if no folder is open.