Struct smithay::utils::Rectangle [−][src]
Expand description
A rectangle defined by its top-left corner and dimensions
Fields
loc: Point<N, Kind>
Location of the top-left corner of the rectangle
size: Size<N, Kind>
Size of the rectangle, as (width, height)
Implementations
Create a new Rectangle
from the coordinates of its top-left corner and its dimensions
Create a new Rectangle
from the coordinates of its top-left corner and its dimensions
Checks whether given Point
is inside the rectangle
Checks whether a given Rectangle
overlaps with this one
Compute the bounding box of a given set of points
Convert this logical rectangle to physical coordinate space according to given scale factor
Convert this physical rectangle to logical coordinate space according to given scale factor
Convert this physical rectangle to logical coordinate space according to given scale factor
Trait Implementations
Auto Trait Implementations
impl<N, Kind> RefUnwindSafe for Rectangle<N, Kind> where
Kind: RefUnwindSafe,
N: RefUnwindSafe,
impl<N, Kind> UnwindSafe for Rectangle<N, Kind> where
Kind: UnwindSafe,
N: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read more
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read more
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read more
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read more
pub fn vzip(self) -> V