Struct tuifw_screen_base::Rect
source · pub struct Rect {
pub tl: Point,
pub size: Vector,
}
Fields§
§tl: Point
§size: Vector
Implementations§
source§impl Rect
impl Rect
pub fn from_tl_br(tl: Point, br: Point) -> Rect
pub fn from_h_v_ranges(h_range: Range1d, v_range: Range1d) -> Rect
pub fn is_empty(self) -> bool
pub fn w(self) -> i16
pub fn h(self) -> i16
pub fn l(self) -> i16
pub fn t(self) -> i16
pub fn r(self) -> i16
pub fn b(self) -> i16
pub fn tr(self) -> Point
pub fn bl(self) -> Point
pub fn br(self) -> Point
pub fn r_inner(self) -> i16
pub fn b_inner(self) -> i16
pub fn tr_inner(self) -> Point
pub fn bl_inner(self) -> Point
pub fn br_inner(self) -> Point
pub fn area(self) -> u32
pub fn points(self) -> RectPoints ⓘ
pub fn h_range(self) -> Range1d ⓘ
pub fn v_range(self) -> Range1d ⓘ
pub fn contains(self, p: Point) -> bool
pub fn intersect(self, other: Rect) -> Rect
pub fn intersect_h_band(self, band: HBand) -> Rect
pub fn intersect_v_band(self, band: VBand) -> Rect
pub fn union(self, other: Rect) -> Option<Either<Either<HBand, VBand>, Rect>>
pub fn union_intersect(self, union_with: Rect, intersect_with: Rect) -> Rect
pub fn offset(self, d: Vector) -> Rect
pub fn relative_to(self, base: Point) -> Rect
pub fn absolute_with(self, base: Point) -> Rect
pub fn t_line(self) -> Rect
pub fn b_line(self) -> Rect
pub fn l_line(self) -> Rect
pub fn r_line(self) -> Rect
Trait Implementations§
source§impl PartialEq for Rect
impl PartialEq for Rect
impl Copy for Rect
impl Eq for Rect
impl StructuralPartialEq for Rect
Auto Trait Implementations§
impl Freeze for Rect
impl RefUnwindSafe for Rect
impl Send for Rect
impl Sync for Rect
impl Unpin for Rect
impl UnwindSafe for Rect
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more