pub trait CharacterCache {
    type Texture: ImageSize;
    type Error;

    fn character(
        &mut self,
        font_size: u32,
        ch: char
    ) -> Result<Character<'_, Self::Texture>, Self::Error>; fn width(&mut self, size: u32, text: &str) -> Result<f64, Self::Error> { ... } }
Expand description

Stores characters in a buffer and loads them by demand.

Required Associated Types

The texture type associated with the character cache.

The error type associated with the character cache.

Required Methods

Get reference to character.

Provided Methods

Return the width for some given text.

Implementors