renderstack::rectangle Class Reference

simple 2D integer rectangle with x, y, width and height

#include <rectangle.hpp>

Public Member Functions

 rectangle (int x=0, int y=0, int width=0, int height=0)
void extend_by_point (int x, int y)
void set (int x, int y, int width, int height)
void set_x (int x)
void set_y (int y)
void set_width (int width)
void set_height (int height)
int x () const
int y () const
int width () const
int height () const

Detailed Description

Definition at line 35 of file rectangle.hpp.


Constructor & Destructor Documentation

renderstack::rectangle::rectangle ( int  x = 0,
int  y = 0,
int  width = 0,
int  height = 0 
) [inline]

Definition at line 38 of file rectangle.hpp.

00039     :   m_x(x)
00040     ,   m_y(y)
00041     ,   m_width(width)
00042     ,   m_height(height)
00043     {
00044     }


Member Function Documentation

void renderstack::rectangle::extend_by_point ( int  x,
int  y 
)

Definition at line 31 of file rectangle.cpp.

00032 {
00033     (void)(x);
00034     (void)(y);
00035     //  TODO mustfix
00036 }

void renderstack::rectangle::set ( int  x,
int  y,
int  width,
int  height 
)

Definition at line 38 of file rectangle.cpp.

00039 {
00040     m_x      = x;
00041     m_y      = y;
00042     m_width  = width;
00043     m_height = height;
00044 }

void renderstack::rectangle::set_x ( int  x  )  [inline]

Definition at line 52 of file rectangle.hpp.

00052 { m_x = x; }

void renderstack::rectangle::set_y ( int  y  )  [inline]

Definition at line 53 of file rectangle.hpp.

00053 { m_y = y; }

void renderstack::rectangle::set_width ( int  width  )  [inline]

Definition at line 54 of file rectangle.hpp.

00054 { m_width = width; }

void renderstack::rectangle::set_height ( int  height  )  [inline]

Definition at line 55 of file rectangle.hpp.

00055 { m_height = height; }

int renderstack::rectangle::x (  )  const [inline]

Definition at line 57 of file rectangle.hpp.

00057 { return m_x; }

int renderstack::rectangle::y (  )  const [inline]

Definition at line 58 of file rectangle.hpp.

00058 { return m_y; }

int renderstack::rectangle::width (  )  const [inline]

Definition at line 59 of file rectangle.hpp.

00059 { return m_width; }

int renderstack::rectangle::height (  )  const [inline]

Definition at line 60 of file rectangle.hpp.

00060 { return m_height; }


The documentation for this class was generated from the following files:
Generated on Sun Apr 11 12:23:12 2010 for RenderStack by  doxygen 1.6.3