pub struct CutoffPicker { /* private fields */ }Expand description
State of the picker, independent of the terminal so it can be tested.
Implementations§
Trait Implementations§
Source§impl Screen for CutoffPicker
impl Screen for CutoffPicker
fn done(&self) -> bool
fn interrupt(&mut self)
Source§fn handle_key(&mut self, key: KeyEvent)
fn handle_key(&mut self, key: KeyEvent)
A key press (Ctrl-C goes to
Screen::interrupt instead).fn render(&mut self, frame: &mut Frame<'_>)
Source§fn pending_work(&self) -> Option<String>
fn pending_work(&self) -> Option<String>
Blocking work the last key asked for, as a line to print while it
runs;
Screen::do_work then does it.fn do_work(&mut self)
Source§fn tick(&mut self) -> bool
fn tick(&mut self) -> bool
Called about every
TICK, keys or not: true redraws, for a view
waiting on work in the background.Source§fn takes_mouse(&self) -> bool
fn takes_mouse(&self) -> bool
Whether the view takes the mouse: only then is the terminal asked for
it, since a view holding it keeps text from being selected.
Source§fn mouse(&mut self, _event: MouseEvent) -> bool
fn mouse(&mut self, _event: MouseEvent) -> bool
A mouse event (a button pressed or let go, or a turn of the wheel)
at a cell of the screen; whether the screen changed and is drawn
again.
Source§fn reports_chords(&self) -> bool
fn reports_chords(&self) -> bool
Whether the terminal is asked to report keys held with Shift, Alt or
Ctrl apart (the kitty keyboard protocol; others ignore the request),
so that Shift+Enter, say, is not taken for Enter.
Source§fn take_notice(&mut self) -> Option<String>
fn take_notice(&mut self) -> Option<String>
Something to tell whoever is away, once:
run_screen rings the
terminal’s bell and asks it for a desktop notification saying it.Auto Trait Implementations§
impl Freeze for CutoffPicker
impl RefUnwindSafe for CutoffPicker
impl Send for CutoffPicker
impl Sync for CutoffPicker
impl Unpin for CutoffPicker
impl UnsafeUnpin for CutoffPicker
impl UnwindSafe for CutoffPicker
Blanket Implementations§
impl<T> Allocation for T
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
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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> ⓘ
Converts
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> ⓘ
Converts
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.