Trait modalkit::editing::application::ApplicationAction
source · pub trait ApplicationAction: Clone + Debug + Eq + PartialEq + Send {
// Required methods
fn is_edit_sequence(&self, ctx: &EditContext) -> SequenceStatus;
fn is_last_action(&self, ctx: &EditContext) -> SequenceStatus;
fn is_last_selection(&self, ctx: &EditContext) -> SequenceStatus;
fn is_switchable(&self, ctx: &EditContext) -> bool;
}
Expand description
Trait for objects that describe application-specific actions.
Implementors of this trait can be used with Action::Application. This can then be used to create additional keybindings and commands on top of the defaults provided within modalkit::env.
Required Methods§
sourcefn is_edit_sequence(&self, ctx: &EditContext) -> SequenceStatus
fn is_edit_sequence(&self, ctx: &EditContext) -> SequenceStatus
Allows controlling how application-specific actions are included in RepeatType::EditSequence.
sourcefn is_last_action(&self, ctx: &EditContext) -> SequenceStatus
fn is_last_action(&self, ctx: &EditContext) -> SequenceStatus
Allows controlling how application-specific actions are included in RepeatType::LastAction.
sourcefn is_last_selection(&self, ctx: &EditContext) -> SequenceStatus
fn is_last_selection(&self, ctx: &EditContext) -> SequenceStatus
Allows controlling how application-specific actions are included in RepeatType::LastSelection.
sourcefn is_switchable(&self, ctx: &EditContext) -> bool
fn is_switchable(&self, ctx: &EditContext) -> bool
Allows controlling whether an application-specific action can cause a buffer switch on an EditError::WrongBuffer.
Object Safety§
This trait is not object safe.