+double Rect::Width(void)
+{
+ return fabs(r - l);
+}
+
+double Rect::Height(void)
+{
+ return fabs(t - b);
+}
+
+bool Rect::Contains(Point p)
+{
+ return ((p.x >= l) && (p.x <= r) && (p.y >= b) && (p.y <= t) ? true : false);
+}
+
+bool Rect::Contains(Rect rect)
+{
+ return ((rect.l >= l) && (rect.r <= r) && (rect.b >= b) && (rect.t <= t) ? true : false);
+}
+
+Point Rect::TopLeft(void)
+{
+ return Point(l, t);
+}
+
+Point Rect::TopRight(void)
+{
+ return Point(r, t);
+}
+
+Point Rect::BottomLeft(void)
+{
+ return Point(l, b);
+}
+
+Point Rect::BottomRight(void)
+{
+ return Point(r, b);
+}