Trait sourceview4::prelude::CompletionContextExt
source · pub trait CompletionContextExt: IsA<CompletionContext> + Sealed + 'static {
// Provided methods
fn add_proposals(
&self,
provider: &impl IsA<CompletionProvider>,
proposals: &[CompletionProposal],
finished: bool
) { ... }
fn activation(&self) -> CompletionActivation { ... }
fn iter(&self) -> Option<TextIter> { ... }
fn set_activation(&self, activation: CompletionActivation) { ... }
fn completion(&self) -> Option<Completion> { ... }
fn set_iter(&self, iter: Option<&TextIter>) { ... }
fn connect_cancelled<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId { ... }
fn emit_cancelled(&self) { ... }
fn connect_activation_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId { ... }
fn connect_iter_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId { ... }
}
Expand description
Provided Methods§
sourcefn add_proposals(
&self,
provider: &impl IsA<CompletionProvider>,
proposals: &[CompletionProposal],
finished: bool
)
fn add_proposals( &self, provider: &impl IsA<CompletionProvider>, proposals: &[CompletionProposal], finished: bool )
Providers can use this function to add proposals to the completion. They
can do so asynchronously by means of the finished
argument. Providers must
ensure that they always call this function with finished
set to true
once each population (even if no proposals need to be added).
Population occurs when the CompletionProviderExt::populate()
function is called.
provider
proposals
The list of proposals to add.
finished
Whether the provider is finished adding proposals.
sourcefn activation(&self) -> CompletionActivation
fn activation(&self) -> CompletionActivation
sourcefn iter(&self) -> Option<TextIter>
fn iter(&self) -> Option<TextIter>
sourcefn set_activation(&self, activation: CompletionActivation)
fn set_activation(&self, activation: CompletionActivation)
The completion activation
sourcefn completion(&self) -> Option<Completion>
fn completion(&self) -> Option<Completion>
The Completion
associated with the context.
sourcefn set_iter(&self, iter: Option<&TextIter>)
fn set_iter(&self, iter: Option<&TextIter>)
The gtk::TextIter
at which the completion is invoked.
sourcefn connect_cancelled<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
fn connect_cancelled<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
Emitted when the current population of proposals has been cancelled. Providers adding proposals asynchronously should connect to this signal to know when to cancel running proposal queries.
fn emit_cancelled(&self)
fn connect_activation_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
fn connect_iter_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
Object Safety§
This trait is not object safe.