Struct tui::widgets::canvas::Context [−][src]
pub struct Context<'a> { /* fields omitted */ }
Holds the state of the Canvas when painting to it.
Methods
impl<'a> Context<'a>
[src]
impl<'a> Context<'a>
pub fn draw<'b, S>(&mut self, shape: &'b S) where
S: Shape<'b>,
[src]
pub fn draw<'b, S>(&mut self, shape: &'b S) where
S: Shape<'b>,
Draw any object that may implement the Shape trait
pub fn layer(&mut self)
[src]
pub fn layer(&mut self)
Go one layer above in the canvas.
pub fn print(&mut self, x: f64, y: f64, text: &'a str, color: Color)
[src]
pub fn print(&mut self, x: f64, y: f64, text: &'a str, color: Color)
Print a string on the canvas at the given position