pub trait Surface {
// Required methods
fn clear(&mut self);
fn pixel(&mut self, x: i32, y: i32);
fn width(&self) -> i32;
fn height(&self) -> i32;
// Provided method
fn line(&mut self, x1: i32, y1: i32, x2: i32, y2: i32) { ... }
}Expand description
A drawable surface