GhostTextStateManager

Trait GhostTextStateManager 

Source
pub trait GhostTextStateManager: Send + Sync {
    // Required methods
    fn display(&mut self, ghost_text: GhostText);
    fn dismiss(&mut self);
    fn accept(&mut self) -> Option<GhostText>;
    fn accept_partial(&mut self, mode: PartialAcceptanceMode) -> Option<String>;
    fn update(&mut self, new_ghost_text: GhostText);
    fn get_state(&self) -> &GhostTextState;
    fn is_displayed(&self) -> bool;
}
Expand description

Ghost text state manager

Required Methods§

Source

fn display(&mut self, ghost_text: GhostText)

Display ghost text

Source

fn dismiss(&mut self)

Dismiss ghost text

Source

fn accept(&mut self) -> Option<GhostText>

Accept ghost text (full acceptance)

Source

fn accept_partial(&mut self, mode: PartialAcceptanceMode) -> Option<String>

Accept ghost text partially

Source

fn update(&mut self, new_ghost_text: GhostText)

Update ghost text based on context change

Source

fn get_state(&self) -> &GhostTextState

Get current ghost text state

Source

fn is_displayed(&self) -> bool

Check if ghost text is currently displayed

Implementors§