pub enum Motion {
Show 25 variants
Left,
Right,
Up,
Down,
WordStartNext,
WordEndNext,
WordStartPrev,
LineStart,
LineFirstNonBlank,
LineEnd,
DocStart,
DocEnd,
PageUp,
PageDown,
HalfPageUp,
HalfPageDown,
GotoLine(u32),
ForwardSexp,
BackwardSexp,
UpList,
DownList,
BeginningOfDefun,
EndOfDefun,
BeginningOfSexp,
EndOfSexp,
}Expand description
Cursor motions — primitive movements the keymap compiles user keys to.
Two families:
- Text motions — vim-ish char/word/line/doc/page motions.
- Structural motions — Lisp-aware
(forward-sexp)/(backward-sexp)/(up-list)/(down-list)equivalents. Enabled on buffers whose major mode opts in via(defmajor-mode … :structural-lisp #t). Matches paredit’s model — equal-or-superior to emacs on Lisp UX.
Variants§
Left
Right
Up
Down
WordStartNext
WordEndNext
WordStartPrev
LineStart
LineFirstNonBlank
LineEnd
DocStart
DocEnd
PageUp
PageDown
HalfPageUp
HalfPageDown
GotoLine(u32)
ForwardSexp
Move to the start of the next sibling s-expression.
BackwardSexp
Move to the start of the previous sibling s-expression.
UpList
Move up one parenthesis level — to the opening ( of the enclosing list.
DownList
Move down into the current list — past the opening (.
BeginningOfDefun
Move to the start of the enclosing top-level defun / top form.
EndOfDefun
Move to the end of the enclosing top-level defun / top form.
BeginningOfSexp
Move to the start of the current s-expression (current atom / list open).
EndOfSexp
Move to the end of the current s-expression (matching close).
Implementations§
Trait Implementations§
impl Copy for Motion
Source§impl<'de> Deserialize<'de> for Motion
impl<'de> Deserialize<'de> for Motion
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Motion
Source§impl JsonSchema for Motion
impl JsonSchema for Motion
Source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref keyword. Read moreimpl StructuralPartialEq for Motion
Auto Trait Implementations§
impl Freeze for Motion
impl RefUnwindSafe for Motion
impl Send for Motion
impl Sync for Motion
impl Unpin for Motion
impl UnsafeUnpin for Motion
impl UnwindSafe for Motion
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