Struct SearchDriver
pub struct SearchDriver { /* private fields */ }Expand description
The find engine behind a window’s search, run where the app’s widgets are: by the window for an app in its process, by the app’s own runtime for an app in a process of its own. It finds or narrows when the query changed, follows the content when it changed under the search, steps, and stops when the search closed.
Implementations§
§impl SearchDriver
impl SearchDriver
pub fn open(&mut self, in_place: InPlace)
pub fn open(&mut self, in_place: InPlace)
Start a search on what the app offers: the query runs afresh on what it shows now.
pub fn in_place(&self) -> InPlace
pub fn in_place(&self) -> InPlace
What the search acts on; InPlace::Nothing while none is open.
pub fn abilities(&self) -> FindAbilities
pub fn abilities(&self) -> FindAbilities
What the document’s find offers beyond matching, as last driven.
pub fn position(&self) -> Option<(usize, usize)>
pub fn position(&self) -> Option<(usize, usize)>
(current, total) in a document, 1-based; None with no match.
pub fn count(&self) -> Option<FilterCount>
pub fn count(&self) -> Option<FilterCount>
What the field’s counter shows: the current match of all of them in a document, the rows shown of all rows in a list; none before anything is typed.
pub fn forget(&mut self)
pub fn forget(&mut self)
Forget what was found without telling the app (it went away).
pub fn set_cover(&mut self, cover: Option<Rect>)
pub fn set_cover(&mut self, cover: Option<Rect>)
What of the document the search’s options cover now, in the app’s
coordinates (None: nothing). The next drive tells the document,
which shows the current match clear of it.
pub fn take_adopted(&mut self) -> Option<(String, FindOptions)>
pub fn take_adopted(&mut self) -> Option<(String, FindOptions)>
The query and options of a find the document ran on its own
(Findable::take_own_find) that the last drive took over: the
field shows that query and drives with it from now on.
Trait Implementations§
§impl Debug for SearchDriver
impl Debug for SearchDriver
§impl Default for SearchDriver
impl Default for SearchDriver
§fn default() -> SearchDriver
fn default() -> SearchDriver
Auto Trait Implementations§
impl Freeze for SearchDriver
impl RefUnwindSafe for SearchDriver
impl Send for SearchDriver
impl Sync for SearchDriver
impl Unpin for SearchDriver
impl UnsafeUnpin for SearchDriver
impl UnwindSafe for SearchDriver
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSend for T
impl<T> DowncastSend for T
§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more