Struct EventContext
struct EventContext<'r> { ... }
Give access to user input.
Implementations
impl<'r> EventContext<'r>
fn mode(self: &Self) -> EditModeemacs or vi mode
fn input_mode(self: &Self) -> InputModevi input mode
fn has_hint(self: &Self) -> boolReturns
trueif there is a hint displayed.fn hint_text(self: &Self) -> Option<&str>Returns the hint text that is shown after the current cursor position.
fn line(self: &Self) -> &strcurrently edited line
fn pos(self: &Self) -> usizeCurrent cursor position (byte position)
impl<'r> Freeze for EventContext<'r>
impl<'r> RefUnwindSafe for EventContext<'r>
impl<'r> Send for EventContext<'r>
impl<'r> Sync for EventContext<'r>
impl<'r> Unpin for EventContext<'r>
impl<'r> UnsafeUnpin for EventContext<'r>
impl<'r> UnwindSafe for EventContext<'r>
impl<T> Any for EventContext<'r>
fn type_id(self: &Self) -> TypeId
impl<T> Borrow for EventContext<'r>
fn borrow(self: &Self) -> &T
impl<T> BorrowMut for EventContext<'r>
fn borrow_mut(self: &mut Self) -> &mut T
impl<T> From for EventContext<'r>
fn from(t: T) -> TReturns the argument unchanged.
impl<T, U> Into for EventContext<'r>
fn into(self: Self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom for EventContext<'r>
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto for EventContext<'r>
fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>