pub enum EditorAction {
Show 30 variants
Insert(String),
InsertAt {
at: usize,
text: String,
},
DeleteRange {
start: usize,
end: usize,
},
DeleteSelection,
Backspace,
DeleteForward,
InsertNewline,
SetCursor(usize),
Select {
anchor: usize,
head: usize,
},
SelectAll,
MoveLeft {
extend: bool,
},
MoveRight {
extend: bool,
},
MoveUp {
extend: bool,
},
MoveDown {
extend: bool,
},
MoveWordForward {
extend: bool,
},
MoveWordBackward {
extend: bool,
},
MoveLineStart {
extend: bool,
},
MoveLineEnd {
extend: bool,
},
MoveDocStart {
extend: bool,
},
MoveDocEnd {
extend: bool,
},
Undo,
Redo,
Save,
Format,
SetLanguage(String),
SetCursorStyle(CursorStyle),
SetTheme(String),
SetStatus(Option<String>),
Wait(u64),
Message(String),
}Expand description
A movement or edit a plugin wants performed.
Variants§
Insert(String)
InsertAt
DeleteRange
DeleteSelection
Backspace
DeleteForward
InsertNewline
SetCursor(usize)
Select
SelectAll
MoveLeft
MoveRight
MoveUp
MoveDown
MoveWordForward
MoveWordBackward
MoveLineStart
MoveLineEnd
MoveDocStart
MoveDocEnd
Undo
Redo
Save
Format
Formats the buffer through the language server (on_buffer_save).
SetLanguage(String)
SetCursorStyle(CursorStyle)
SetTheme(String)
Switch to the named color theme (built-in or defined by a plugin).
SetStatus(Option<String>)
Replace the right-hand status line with Some(text), or restore the
built-in status when None. Plugins use this for custom status bars.
Wait(u64)
Pause automated playback for this many milliseconds before running the next action. Hosts without timed playback may treat it immediately.
Message(String)
Implementations§
Source§impl EditorAction
impl EditorAction
Trait Implementations§
Source§impl Clone for EditorAction
impl Clone for EditorAction
Source§impl Debug for EditorAction
impl Debug for EditorAction
impl Eq for EditorAction
Source§impl PartialEq for EditorAction
impl PartialEq for EditorAction
impl StructuralPartialEq for EditorAction
Auto Trait Implementations§
impl Forget for EditorAction
impl Freeze for EditorAction
impl Move for EditorAction
impl RefUnwindSafe for EditorAction
impl Send for EditorAction
impl Sync for EditorAction
impl Unpin for EditorAction
impl UnsafeUnpin for EditorAction
impl UnwindSafe for EditorAction
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more