[][src]Enum piano_keyboard::Element

pub enum Element {
    WhiteKey {
        wide: Rectangle,
        small: Rectangle,
        blind: Option<Rectangle>,
    },
    BlackKey(Rectangle),
}

The elements provided by a Keyboard are white keys, black keys and the full keyboard - defined by this enum.

Variants

WhiteKey

A white key consists of up to three rectangles: The wide part of the key. The small part of the key next to tbe black keys. For left/right outter keys, there may be a blind part for a non-existing black key.

Fields of WhiteKey

wide: Rectanglesmall: Rectangleblind: Option<Rectangle>
BlackKey(Rectangle)

A black key consists of only one rectangle

Trait Implementations

impl Debug for Element[src]

Auto Trait Implementations

impl RefUnwindSafe for Element

impl Send for Element

impl Sync for Element

impl Unpin for Element

impl UnwindSafe for Element

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.