50 const sal_Int32 x1(maPos.
getX());
51 const sal_Int32 y1(maPos.
getY());
52 const sal_Int32 x2(x1 + maSize.
getX());
53 const sal_Int32 y2(y1 + maSize.
getY());
54 if(px < x1)
return false;
55 if(px >= x2)
return false;
56 if(py < y1)
return false;
57 if(py >= y2)
return false;
64 const sal_Int32 x1(maPos.
getX());
65 const sal_Int32 y1(maPos.
getY());
66 const sal_Int32 x1w(x1 + maSize.
getX() - 1);
67 const sal_Int32 y1h(y1 + maSize.
getY() - 1);
74 return !((x1w < x2) || (x2w < x1) || (y1h < y2) || (y2h < y1));
79 const sal_Int32 x1(maPos.
getX());
80 const sal_Int32 y1(maPos.
getY());
81 const sal_Int32 x2(x1 + maSize.
getX() - 1);
82 const sal_Int32 y2(y1 + maSize.
getY() - 1);
bool intersection(const SurfaceRect &r) const
returns true if the passed rect intersects this one.
bool inside(const SurfaceRect &r) const
bool pointInside(sal_Int32 px, sal_Int32 py) const
SurfaceRect(const ::basegfx::B2ISize &rSize)
::basegfx::B2IPoint maPos
::basegfx::B2ISize maSize
This implements some equivalent to basegfx::B2IBox, but instead of two BasicBox ranges, it uses a position and a size.