Readonly
charThe widget of a character in the editor in pixels.
Readonly
edgeA signal emitted when either the top or bottom edge is requested.
Readonly
hostThe DOM node that hosts the editor.
Readonly
isReadonly
lineGet the number of lines in the editor.
Readonly
lineThe height of a line in the editor in pixels.
Readonly
modelThe model used by the editor.
The uuid of this selection owner.
Dispose of the resources held by the object.
If the object's dispose
method is called more than once, all
calls made after the first will be a no-op.
It is undefined behavior to use any functionality of the object after it has been disposed unless otherwise explicitly noted.
Get the window coordinates given a cursor position.
The desired position.
The coordinates of the position.
Returns the content for the given line number.
The line of interest.
The value of the line.
Lines are 0-based, and accessing a line out of range returns
undefined
.
Find an offset for the given position.
The position of interest.
The offset at the position, clamped to the extent of the editor contents.
Get the cursor position given window coordinates.
The desired coordinate.
The position of the coordinates, or null if not contained in the editor.
Get the token at a given editor position.
Get the token a the cursor position.
Get a list of tokens for the current editor text content.
Alpha
Experimental
Inject an extension into the editor
Editor extension
Optional
replaceReveals the given position in the editor.
The desired position to reveal.
Reveals the given selection in the editor.
The desired selection to reveal.
Set the primary position of the cursor.
The new primary position.
Optional
options: { Optional
scroll?: booleanSet config options for the editor.
Set the primary selection.
A widget that provides a code editor.
As of JupyterLab 4.0.0, it is not possible to provide an editor that is different of CodeMirror 6.