Font

Trait Font 

Source
pub trait Font {
    // Required methods
    fn get_char(&self, c: char) -> Option<&[Point]>;
    fn get_char_width(&self) -> u16;
    fn get_char_height(&self) -> u16;

    // Provided methods
    fn draw_char(&self, c: char, x: u16, y: u16, style: Style, buf: &mut Buffer) { ... }
    fn draw_str(&self, s: &str, area: Rect, style: Style, buf: &mut Buffer) { ... }
}

Required Methods§

Source

fn get_char(&self, c: char) -> Option<&[Point]>

Source

fn get_char_width(&self) -> u16

Source

fn get_char_height(&self) -> u16

Provided Methods§

Source

fn draw_char(&self, c: char, x: u16, y: u16, style: Style, buf: &mut Buffer)

Source

fn draw_str(&self, s: &str, area: Rect, style: Style, buf: &mut Buffer)

Implementors§