pub trait RectExt {
    fn centered(self, other: Rect) -> Rect;
    fn scaled(self, x_scale: f64, y_scale: f64) -> Rect;
}

Required Methods

Calculates a rectangle centered on self, with the same size as other.

Width and height of other rectangle are truncated to that of self

Calculates a rectangle with a new height and width

Implementations on Foreign Types

Implementors