[][src]Trait embedded_text::rendering::RendererFactory

pub trait RendererFactory<'a, C: PixelColor> {
    type Renderer: Iterator<Item = Pixel<C>>;
    pub fn create_renderer(&self) -> Self::Renderer;
}

This trait is used to associate a renderer type to a horizontal alignment option.

Implementing this trait is only necessary when creating new alignment algorithms.

Associated Types

type Renderer: Iterator<Item = Pixel<C>>[src]

The type of the pixel iterator.

Loading content...

Required methods

pub fn create_renderer(&self) -> Self::Renderer[src]

Creates a new renderer object.

Loading content...

Implementors

impl<'a, C, F, V, H> RendererFactory<'a, C> for StyledTextBox<'a, C, F, CenterAligned, V, H> where
    C: PixelColor + From<Rgb>,
    F: Font + Copy,
    V: VerticalTextAlignment,
    H: HeightMode
[src]

type Renderer = StyledTextBoxIterator<'a, C, F, CenterAligned, V, H, UniformSpaceConfig<F>>

impl<'a, C, F, V, H> RendererFactory<'a, C> for StyledTextBox<'a, C, F, Justified, V, H> where
    C: PixelColor + From<Rgb>,
    F: Font + Copy,
    V: VerticalTextAlignment,
    H: HeightMode
[src]

type Renderer = StyledTextBoxIterator<'a, C, F, Justified, V, H, JustifiedSpaceConfig<F>>

impl<'a, C, F, V, H> RendererFactory<'a, C> for StyledTextBox<'a, C, F, LeftAligned, V, H> where
    C: PixelColor + From<Rgb>,
    F: Font + Copy,
    V: VerticalTextAlignment,
    H: HeightMode
[src]

type Renderer = StyledTextBoxIterator<'a, C, F, LeftAligned, V, H, UniformSpaceConfig<F>>

impl<'a, C, F, V, H> RendererFactory<'a, C> for StyledTextBox<'a, C, F, RightAligned, V, H> where
    C: PixelColor + From<Rgb>,
    F: Font + Copy,
    V: VerticalTextAlignment,
    H: HeightMode
[src]

type Renderer = StyledTextBoxIterator<'a, C, F, RightAligned, V, H, UniformSpaceConfig<F>>

Loading content...