pub enum WordStyle {
AlphaNum,
Big,
CharSet(fn(_: char) -> bool),
FileName,
FilePath,
Little,
NonAlphaNum,
Number(Radix),
Whitespace(bool),
}
Expand description
The different ways of grouping a buffer’s contents into words.
Variants§
AlphaNum
A run of alphanumeric characters.
Big
A sequence of non-blank characters.
An empty line is also a Big word. Vim calls this a WORD
.
CharSet(fn(_: char) -> bool)
A sequence of characters that match a test function.
FileName
A name of a directory or file.
FilePath
A path to a directory or file.
Little
Either a sequence of alphanumeric characters and underscores, or a sequence of other non-blank characters.
An empty line is also a Little word.
NonAlphaNum
A run of non-alphanumeric characters.
Number(Radix)
A run of digits in the given base, with an optional leading hyphen.
Whitespace(bool)
A run of blank characters.
bool controls whether this crosses line boundaries.
Trait Implementations§
source§impl BoundaryTest for WordStyle
impl BoundaryTest for WordStyle
source§fn is_boundary_begin(&self, ctx: &BoundaryTestContext) -> bool
fn is_boundary_begin(&self, ctx: &BoundaryTestContext) -> bool
Check whether we are at the beginning of the range.
source§fn is_boundary_end(&self, ctx: &BoundaryTestContext) -> bool
fn is_boundary_end(&self, ctx: &BoundaryTestContext) -> bool
Check whether we are at the end of the range.
source§fn is_boundary(&self, terminus: MoveTerminus, ctx: &BoundaryTestContext) -> bool
fn is_boundary(&self, terminus: MoveTerminus, ctx: &BoundaryTestContext) -> bool
Check whether we are at the given side of the range.
source§impl PartialEq for WordStyle
impl PartialEq for WordStyle
impl Eq for WordStyle
impl StructuralPartialEq for WordStyle
Auto Trait Implementations§
impl Freeze for WordStyle
impl RefUnwindSafe for WordStyle
impl Send for WordStyle
impl Sync for WordStyle
impl Unpin for WordStyle
impl UnwindSafe for WordStyle
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
source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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
Compare self to
key
and return true
if they are equal.