Trait piston_window::Rectangled[][src]

pub trait Rectangled {
    pub fn margin(self, m: f64) -> Self;
pub fn rel(self, x: f64, y: f64) -> Self; pub fn expand(self, m: f64) -> Self { ... } }

Should be implemented by contexts that have rectangle information.

Required methods

pub fn margin(self, m: f64) -> Self[src]

Shrinks the current rectangle equally by all sides.

pub fn rel(self, x: f64, y: f64) -> Self[src]

Moves to a relative rectangle using the current rectangle as tile.

Loading content...

Provided methods

pub fn expand(self, m: f64) -> Self[src]

Expands the current rectangle equally by all sides.

Loading content...

Implementations on Foreign Types

impl Rectangled for [f64; 4][src]

Loading content...

Implementors

Loading content...