pub enum Operator {
Delete,
Change,
Yank,
Uppercase,
Lowercase,
ToggleCase,
Indent,
Outdent,
Fold,
Reflow,
}Variants§
Delete
Change
Yank
Uppercase
gU{motion} — uppercase the range. Entered via the g prefix
in normal mode or U in visual mode.
Lowercase
gu{motion} — lowercase the range. u in visual mode.
ToggleCase
g~{motion} — toggle case of the range. ~ in visual mode
(character at the cursor for the single-char ~ command stays
its own code path in normal mode).
Indent
>{motion} — indent the line range by shiftwidth spaces.
Always linewise, even when the motion is char-wise — mirrors
vim’s behaviour where >w indents the current line, not the
word on it.
Outdent
<{motion} — outdent the line range (remove up to
shiftwidth leading spaces per line).
Fold
zf{motion} / zf{textobj} / Visual zf — create a closed
fold spanning the row range. Doesn’t mutate the buffer text;
cursor restores to the operator’s start position.
Reflow
gq{motion} — reflow the row range to settings.textwidth.
Greedy word-wrap: collapses each paragraph (blank-line-bounded
run) into space-separated words, then re-emits lines whose
width stays under textwidth. Always linewise, like indent.
Trait Implementations§
impl Copy for Operator
impl Eq for Operator
impl StructuralPartialEq for Operator
Auto Trait Implementations§
impl Freeze for Operator
impl RefUnwindSafe for Operator
impl Send for Operator
impl Sync for Operator
impl Unpin for Operator
impl UnsafeUnpin for Operator
impl UnwindSafe for Operator
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more