Extends
Constructor
new ve.ui.CodeMirrorAction(surface)
#
CodeMirror action
Properties
methodsstatic
#
Methods
toggle([enable]) → {Promise}
#
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
enable |
boolean |
optional |
State to force toggle to, inverts current state if undefined |
Returns:
Action was executed
- Type
- Promise
setHighlightStylesEnabled(enabled)static
#
Enable or park the ::highlight() styles.
Browsers match these rules against the whole document on each style recalculation. In Chrome this costs seconds on a long article. Only the highlighter draws them, so park them while it does not draw.
Parameters:
| Name | Type | Description |
|---|---|---|
enabled |
boolean |
Enable or park the ::highlight() styles.