Struct axgeom::Rect[][src]

#[must_use]
pub struct Rect<T: Copy>(pub [Range<T>; 2]);

Stored as two Ranges.

Methods

impl<T: Copy> Rect<T>
[src]

impl<T: PartialOrd + Copy> Rect<T>
[src]

impl<T: Copy + Sub<Output = T> + Add<Output = T>> Rect<T>
[src]

impl<T: Ord + Copy> Rect<T>
[src]

Subdivides the rectangle. No floating point calculations are done (so no precision loss/rounding issues).

Returns true if the specified rect is inside of this rect.

Grow the rectangle to fit the specified rectangle by replacing values with the specified rectangle. No floating point computations.

Get an intersecting rectangle. No floating point calculations as the new rectangle is made up of values from this rectangle and the specified rectangle.

Trait Implementations

impl<T: Copy + Copy> Copy for Rect<T>
[src]

impl<T: Clone + Copy> Clone for Rect<T>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<T: Debug + Copy> Debug for Rect<T>
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl<T> Send for Rect<T> where
    T: Send

impl<T> Sync for Rect<T> where
    T: Sync