MoSync 3.3
MAUtil::Rect Class Reference

Rect geometric helper structure/function. More...

#include <MAUtil/Geometry.h>

List of all members.

Public Member Functions

 Rect ()
 Rect (int x, int y, int width, int height)
bool contains (const Point &p) const
bool contains (int x, int y) const
bool overlaps (const Rect &r) const
void setPosition (int x, int y)
virtual void set (int x, int y, int w, int h)

Public Attributes

int x
int y
int width
int height

Detailed Description

Rect geometric helper structure/function.


Constructor & Destructor Documentation

MAUtil::Rect::Rect ( int  x,
int  y,
int  width,
int  height 
)

Member Function Documentation

bool MAUtil::Rect::contains ( const Point p) const
bool MAUtil::Rect::contains ( int  x,
int  y 
) const
bool MAUtil::Rect::overlaps ( const Rect r) const

Returns true if this and r share any surface point.

void MAUtil::Rect::setPosition ( int  x,
int  y 
)
virtual void MAUtil::Rect::set ( int  x,
int  y,
int  w,
int  h 
) [virtual]

Member Data Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines