pub struct MenuStyle<C, S, IT, P>where
    C: PixelColor,
    S: IndicatorStyle,
    IT: InteractionController,
    P: SelectionIndicatorController,{ /* private fields */ }

Implementations§

source§

impl<C> MenuStyle<C, LineIndicator, Programmed, StaticPosition>where C: PixelColor,

source

pub const fn new(color: C) -> Self

source§

impl<C, S, IT, P> MenuStyle<C, S, IT, P>where C: PixelColor, S: IndicatorStyle, IT: InteractionController, P: SelectionIndicatorController,

source

pub const fn with_font(self, font: &'static MonoFont<'static>) -> Self

source

pub const fn with_title_font( self, title_font: &'static MonoFont<'static> ) -> Self

source

pub const fn with_scrollbar_style(self, scrollbar: DisplayScrollbar) -> Self

source

pub const fn with_details_delay(self, frames: u16) -> Self

source

pub const fn with_selection_indicator<S2>( self, indicator_style: S2 ) -> MenuStyle<C, S2, IT, P>where S2: IndicatorStyle,

source

pub const fn with_interaction_controller<IT2>( self, interaction: IT2 ) -> MenuStyle<C, S, IT2, P>where IT2: InteractionController,

source

pub const fn with_animated_selection_indicator( &self, frames: i32 ) -> MenuStyle<C, S, IT, AnimatedPosition>

source

pub fn text_style(&self) -> MonoTextStyle<'static, C>

source

pub fn title_style(&self) -> MonoTextStyle<'static, C>

Trait Implementations§

source§

impl<C, S, IT, P> Clone for MenuStyle<C, S, IT, P>where C: PixelColor + Clone, S: IndicatorStyle + Clone, IT: InteractionController + Clone, P: SelectionIndicatorController + Clone,

source§

fn clone(&self) -> MenuStyle<C, S, IT, P>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<C, S, IT, P> Debug for MenuStyle<C, S, IT, P>where C: PixelColor + Debug, S: IndicatorStyle + Debug, IT: InteractionController + Debug, P: SelectionIndicatorController + Debug,

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for MenuStyle<BinaryColor, LineIndicator, Programmed, StaticPosition>

source§

fn default() -> Self

Returns the “default value” for a type. Read more
source§

impl<C, S, V, IT, P> StyledDrawable<MenuStyle<C, S, IT, P>> for Chain<V>where C: PixelColor, V: StyledMenuItem<C, S, IT, P>, S: IndicatorStyle, IT: InteractionController, P: SelectionIndicatorController,

§

type Color = C

Color type.
§

type Output = ()

Output type.
source§

fn draw_styled<D>( &self, style: &MenuStyle<Self::Color, S, IT, P>, display: &mut D ) -> Result<(), D::Error>where D: DrawTarget<Color = Self::Color>,

Draws the primitive using the given style.
source§

impl<C, S, V, VC, IT, P> StyledDrawable<MenuStyle<C, S, IT, P>> for Link<V, VC>where C: PixelColor, V: StyledMenuItem<C, S, IT, P>, VC: ChainElement + StyledMenuItem<C, S, IT, P>, S: IndicatorStyle, IT: InteractionController, P: SelectionIndicatorController,

§

type Color = C

Color type.
§

type Output = ()

Output type.
source§

fn draw_styled<D>( &self, style: &MenuStyle<Self::Color, S, IT, P>, display: &mut D ) -> Result<(), D::Error>where D: DrawTarget<Color = Self::Color>,

Draws the primitive using the given style.
source§

impl<C, S, I, IT, P> StyledDrawable<MenuStyle<C, S, IT, P>> for MenuLine<I>where C: PixelColor + From<Rgb888>, I: MenuItem, S: IndicatorStyle, IT: InteractionController, P: SelectionIndicatorController,

§

type Color = C

Color type.
§

type Output = ()

Output type.
source§

fn draw_styled<D>( &self, style: &MenuStyle<C, S, IT, P>, display: &mut D ) -> Result<Self::Output, D::Error>where D: DrawTarget<Color = Self::Color>,

Draws the primitive using the given style.
source§

impl<C, S, IT, P> Copy for MenuStyle<C, S, IT, P>where C: PixelColor + Copy, S: IndicatorStyle + Copy, IT: InteractionController + Copy, P: SelectionIndicatorController + Copy,

Auto Trait Implementations§

§

impl<C, S, IT, P> !RefUnwindSafe for MenuStyle<C, S, IT, P>

§

impl<C, S, IT, P> Send for MenuStyle<C, S, IT, P>where C: Send, IT: Send, P: Send, S: Send,

§

impl<C, S, IT, P> Sync for MenuStyle<C, S, IT, P>where C: Sync, IT: Sync, P: Sync, S: Sync,

§

impl<C, S, IT, P> Unpin for MenuStyle<C, S, IT, P>where C: Unpin, IT: Unpin, P: Unpin, S: Unpin,

§

impl<C, S, IT, P> !UnwindSafe for MenuStyle<C, S, IT, P>

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Az for T

source§

fn az<Dst>(self) -> Dstwhere T: Cast<Dst>,

Casts the value.
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<Src, Dst> CastFrom<Src> for Dstwhere Src: Cast<Dst>,

source§

fn cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> CheckedAs for T

source§

fn checked_as<Dst>(self) -> Option<Dst>where T: CheckedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere Src: CheckedCast<Dst>,

source§

fn checked_cast_from(src: Src) -> Option<Dst>

Casts the value.
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> OverflowingAs for T

source§

fn overflowing_as<Dst>(self) -> (Dst, bool)where T: OverflowingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere Src: OverflowingCast<Dst>,

source§

fn overflowing_cast_from(src: Src) -> (Dst, bool)

Casts the value.
source§

impl<T> SaturatingAs for T

source§

fn saturating_as<Dst>(self) -> Dstwhere T: SaturatingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere Src: SaturatingCast<Dst>,

source§

fn saturating_cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> UnwrappedAs for T

source§

fn unwrapped_as<Dst>(self) -> Dstwhere T: UnwrappedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere Src: UnwrappedCast<Dst>,

source§

fn unwrapped_cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> WrappingAs for T

source§

fn wrapping_as<Dst>(self) -> Dstwhere T: WrappingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere Src: WrappingCast<Dst>,

source§

fn wrapping_cast_from(src: Src) -> Dst

Casts the value.