pub struct IndicatorMock { /* private fields */ }Expand description
A mock component to display a colored indicator inside the TUI. The indicator is a simple box alternating its style from a given set of Style when Self::cycle is called.
Implementations§
Source§impl IndicatorMock
impl IndicatorMock
Sourcepub fn with_palette(name: String, palette: &EzPalette) -> Self
pub fn with_palette(name: String, palette: &EzPalette) -> Self
Create a new IndicatorMock component with two styles derived from one [Palette].
Sourcepub fn with_palettes(
name: String,
palette_a: &EzPalette,
palette_b: &EzPalette,
) -> Self
pub fn with_palettes( name: String, palette_a: &EzPalette, palette_b: &EzPalette, ) -> Self
Create a new IndicatorMock component with two styles derived from two [Palette].
Trait Implementations§
Source§impl Debug for IndicatorMock
impl Debug for IndicatorMock
Source§impl MockComponent for IndicatorMock
impl MockComponent for IndicatorMock
Auto Trait Implementations§
impl Freeze for IndicatorMock
impl RefUnwindSafe for IndicatorMock
impl Send for IndicatorMock
impl Sync for IndicatorMock
impl Unpin for IndicatorMock
impl UnsafeUnpin for IndicatorMock
impl UnwindSafe for IndicatorMock
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
Mutably borrows from an owned value. Read more
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 more