32 Rect(
const Pnt& bottomleft,
const Pnt& topright);
33 Rect(
double left,
double bottom,
double width,
double height);
36 bool isNull(
void)
const;
37 bool isEmpty(
void)
const;
38 bool isValid(
void)
const;
41 void makeSingular(
void);
43 void getRect(
double* x,
double* y,
double* w,
double* h)
const;
45 double left(
void)
const {
return _x1; }
46 double right(
void)
const {
return _x2; }
47 double bottom(
void)
const {
return _y1; }
48 double top(
void)
const {
return _y2; }
50 double width(
void)
const {
return abs(_x2 - _x1); }
51 double height(
void)
const {
return abs(_y2 - _y1); }
57 Pnt center(
void)
const {
return Pnt((_x1 + _x2) / 2, (_y1 + _y2) / 2); }
59 void setLeft(
double left);
60 void setRight(
double right);
61 void setBottom(
double bottom);
62 void setTop(
double top);
66 void setSize(
double width,
double height);
68 void moveCenter(
const Pnt& p);
69 void moveCenter(
double x,
double y);
70 void grow(
double value);
71 void shrink(
double value);
72 void translate(
double dx,
double dy);
78 void unite(
const Rect& t);
80 Rect normalized(
void)
const;
82 bool contains(
const Geom::Pnt& point)
const;
double left(void) const
Definition: Rect.h:45
Defines a non-persistent 3D Cartesian point.
Definition: Pnt.h:42
#define GEOM_EXPORT
Definition: geom_defines.h:8
Pnt bottomRight(void) const
Definition: Rect.h:54
Pnt topRight(void) const
Definition: Rect.h:56
void setWidth(double w)
Definition: Rect.h:64
Pnt bottomLeft(void) const
Definition: Rect.h:53
double right(void) const
Definition: Rect.h:46
void setHeight(double h)
Definition: Rect.h:65
double bottom(void) const
Definition: Rect.h:47
double height(void) const
Definition: Rect.h:51
Pnt center(void) const
Definition: Rect.h:57
Pnt topLeft(void) const
Definition: Rect.h:55
double top(void) const
Definition: Rect.h:48
double width(void) const
Definition: Rect.h:50