equal
deleted
inserted
replaced
352 pub fn split_at(&self, point: Point) -> [Rect; 4] { |
352 pub fn split_at(&self, point: Point) -> [Rect; 4] { |
353 assert!(self.contains_inside(point)); |
353 assert!(self.contains_inside(point)); |
354 [ |
354 [ |
355 Rect::from_box(self.left(), point.x, self.top(), point.y), |
355 Rect::from_box(self.left(), point.x, self.top(), point.y), |
356 Rect::from_box(point.x, self.right(), self.top(), point.y), |
356 Rect::from_box(point.x, self.right(), self.top(), point.y), |
357 Rect::from_box(self.left(), point.x, point.y, self.bottom()), |
357 Rect::from_box(point.x, self.right(), point.y, self.bottom()), |
358 Rect::from_box(point.x, self.right(), point.y, self.bottom()) |
358 Rect::from_box(self.left(), point.x, point.y, self.bottom()) |
359 ] |
359 ] |
360 } |
360 } |
361 } |
361 } |
362 |
362 |
363 pub struct Polygon { |
363 pub struct Polygon { |