pub trait KeyBindingExt<This>where
This: NavigationStateAlg,{
// Required methods
fn page_bindings(&self) -> impl Iterator<Item = ManagerKeyBinding<This>>;
fn keystroke_meaning(
&self,
stroke: Keystroke,
) -> Option<ManagerKeyBinding<This>>;
fn typed_meaning(&self, typed: char) -> Option<ManagerKeyBinding<This>>;
fn paste_meaning(&self, text: &str) -> Option<ManagerKeyBinding<This>>;
fn page_accepts_text(&self) -> bool;
fn action_keys(
&self,
action: ManagerAction,
) -> impl Iterator<Item = Keystroke>;
}Expand description
States the keys one page binds and what they denote there.
Required Methods§
Sourcefn page_bindings(&self) -> impl Iterator<Item = ManagerKeyBinding<This>>
fn page_bindings(&self) -> impl Iterator<Item = ManagerKeyBinding<This>>
States every keystroke the current page binds, cursor movement first.
Typed scalars are not bound here: on an editor page every scalar the table leaves free denotes insertion, which is one rule rather than one binding per character.
Sourcefn keystroke_meaning(
&self,
stroke: Keystroke,
) -> Option<ManagerKeyBinding<This>>
fn keystroke_meaning( &self, stroke: Keystroke, ) -> Option<ManagerKeyBinding<This>>
States what one keystroke denotes on the current page.
Exit is bound on every page. Any other modified keystroke denotes nothing, so a chord the terminal reports is never mistaken for the unmodified key inside it.
Sourcefn typed_meaning(&self, typed: char) -> Option<ManagerKeyBinding<This>>
fn typed_meaning(&self, typed: char) -> Option<ManagerKeyBinding<This>>
States what one typed scalar denotes on the current page.
Sourcefn paste_meaning(&self, text: &str) -> Option<ManagerKeyBinding<This>>
fn paste_meaning(&self, text: &str) -> Option<ManagerKeyBinding<This>>
States what pasted text denotes on the current page.
Sourcefn page_accepts_text(&self) -> bool
fn page_accepts_text(&self) -> bool
Observes whether the current page holds a text draft free scalars belong to.
Sourcefn action_keys(&self, action: ManagerAction) -> impl Iterator<Item = Keystroke>
fn action_keys(&self, action: ManagerAction) -> impl Iterator<Item = Keystroke>
States the keys reaching one action on the current page, the primary key first.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementors§
impl<This> KeyBindingExt<This> for Thiswhere
This: NavigationStateAlg,
States the keys one page binds and what they denote there.