pub enum SelectionMode {
Character,
Block,
Line,
}Expand description
Selection mode determining how text is selected.
These modes correspond to vim’s visual mode variants:
vfor character-wiseVfor line-wiseCtrl-Vfor block (rectangular)
Variants§
Character
Character-wise selection (vim’s v mode).
Selection extends character by character from anchor to cursor, spanning multiple lines if necessary.
Block
Block (rectangular) selection (vim’s Ctrl-V mode).
Selection forms a rectangle defined by the anchor and cursor positions, regardless of line lengths.
Line
Line-wise selection (vim’s V mode).
Selection extends by whole lines from the anchor line to the cursor line, inclusive.
Implementations§
Trait Implementations§
Source§impl Clone for SelectionMode
impl Clone for SelectionMode
Source§fn clone(&self) -> SelectionMode
fn clone(&self) -> SelectionMode
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SelectionMode
impl Debug for SelectionMode
Source§impl Default for SelectionMode
impl Default for SelectionMode
Source§fn default() -> SelectionMode
fn default() -> SelectionMode
Returns the “default value” for a type. Read more
Source§impl Hash for SelectionMode
impl Hash for SelectionMode
Source§impl PartialEq for SelectionMode
impl PartialEq for SelectionMode
impl Copy for SelectionMode
impl Eq for SelectionMode
impl StructuralPartialEq for SelectionMode
Auto Trait Implementations§
impl Freeze for SelectionMode
impl RefUnwindSafe for SelectionMode
impl Send for SelectionMode
impl Sync for SelectionMode
impl Unpin for SelectionMode
impl UnsafeUnpin for SelectionMode
impl UnwindSafe for SelectionMode
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