#include <rect.h>
Collaboration diagram for rect:
Public Methods | |
rect () throw () | |
rect (int x, int y) throw (std::exception) | |
rect (const point &size) throw (std::exception) | |
rect (int x1, int y1, int x2, int y2) throw (std::exception) | |
rect (const point &topleft, const point &bottomright) throw (std::exception) | |
rect (const rect &r) throw () | |
rect & | operator= (const rect &r) throw () |
bool | operator== (const rect &r) const throw () |
point | size () const throw () |
int | width () const throw () |
int | height () const throw () |
int | left () const throw () |
int | right () const throw () |
int | top () const throw () |
int | bottom () const throw () |
const point & | topleft () const throw () |
const point & | bottomright () const throw () |
bool | is_inside (int x, int y) const throw () |
check if given position is inside the rectangle | |
bool | is_inside (const point &p) const throw () |
check if given point is inside the rectangle | |
bool | clip (rect &r) const throw (std::exception) |
Protected Methods | |
void | check () throw (std::exception) |
Private Attributes | |
point | _topleft |
The point at the top left of the rectangle. | |
point | _bottomright |
The point at the bottom right of the rectangle. |
This small class is an helper for rectangles. It is mostly used by the blitter class.
Definition at line 60 of file rect.h.
|
Definition at line 27 of file rect.cpp. Referenced by operator=(). |
|
|
|
|
|
|
|
|
|
|
|
Definition at line 81 of file rect.h. References point::get_y(). Referenced by blitter::block_copy(), and operator<<(). |
|
|
|
|
|
|
|
Definition at line 77 of file rect.h. References point::get_y(), and size(). |
|
check if given point is inside the rectangle
|
|
check if given position is inside the rectangle
|
|
Definition at line 78 of file rect.h. References point::get_x(). Referenced by operator<<(). |
|
|
|
|
|
Definition at line 79 of file rect.h. References point::get_x(). Referenced by blitter::block_copy(), and operator<<(). |
|
|
|
Definition at line 80 of file rect.h. References point::get_y(). Referenced by operator<<(). |
|
|
|
Definition at line 76 of file rect.h. References point::get_x(), and size(). |
|
The point at the bottom right of the rectangle.
|
|
The point at the top left of the rectangle.
Definition at line 62 of file rect.h. Referenced by operator=(). |