Struct glyph_ui::Printer[][src]

pub struct Printer<'a> { /* fields omitted */ }

Draw on a subset of the screen

Implementations

impl<'a> Printer<'a>[src]

pub fn size(&self) -> Size2D<u16, Cell>[src]

Get the size of this printer

Note that the printable area will be [(0, 0), (size.x, size.y)), i.e. inclusive-exclusive.

pub fn print<P>(&self, text: &str, start: P) -> Result<(), OutOfBounds> where
    P: Into<Point2D<u16, Cell>>, 
[src]

Prints text inside the printer's area

pub fn show_cursor_at<P>(&self, point: P) -> Result<(), OutOfBounds> where
    P: Into<Point2D<u16, Cell>>, 
[src]

Shows the cursor at the given location

pub fn hide_cursor<P>(&self)[src]

Hides the cursor

pub fn to_sub_area<R>(&self, sub_area: R) -> Result<Self, OutOfBounds> where
    R: Into<Rect<u16, Cell>>, 
[src]

Returns a printer that's allowed to print on a subset of its parent

Auto Trait Implementations

impl<'a> !RefUnwindSafe for Printer<'a>[src]

impl<'a> !Send for Printer<'a>[src]

impl<'a> !Sync for Printer<'a>[src]

impl<'a> Unpin for Printer<'a>[src]

impl<'a> !UnwindSafe for Printer<'a>[src]

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.

impl<V> ViewExt for V[src]

impl<'a, T, M, V> ViewExt<'a, T, M> for V[src]

impl<'a, T, O, M, F, V> ViewExt<'a, T, O, M, F> for V where
    F: Fn(O) -> M + Clone + 'static,
    M: 'static,
    O: 'static, 
[src]

impl<V> ViewExt for V[src]

impl<V> ViewExt for V[src]

impl<V> ViewExt for V[src]