]> Shamusworld >> Repos - architektonas/blobdiff - src/rect.h
Preliminary support for Polylines.
[architektonas] / src / rect.h
index 0a8478a6b47cc461d80eb408777d3148018dc18c..23b79fff0a1ec041bbc3b97b94cab7ca7b4840bb 100644 (file)
@@ -13,14 +13,24 @@ struct Rect
        double l, r, t, b;
 
        Rect();
-       Rect(double ll, double rr, double tt, double bb);
+       Rect(double tt, double ll, double bb, double rr);
        Rect(Point tl, Point br);
+       Rect(Point);
        Rect & operator*=(double scale);
        Rect & operator|=(Rect x);
+       Rect & operator+=(Point p);
+       double & operator[](int);
        void Normalize(void);
        void Translate(Point p);
        void Expand(double amt);
+       double Width(void);
+       double Height(void);
+       bool Contains(Point p);
+       bool Contains(Rect r);
+       Point TopLeft(void);
+       Point TopRight(void);
+       Point BottomLeft(void);
+       Point BottomRight(void);
 };
 
 #endif // __RECT_H__
-