Inheritance diagram for Exponent::MathTools::CPoint:

1.0.1 Added const == operator
1.0.2 Added isStraightLine method (either x's must match or the y's must match)
Definition at line 32 of file CPoint.hpp.
| Exponent::MathTools::CPoint::CPoint | ( | const long | x = 0, |
|
| const long | y = 0 | |||
| ) |
Construciton
| x | The X Position | |
| y | The Y Position |
| Exponent::MathTools::CPoint::CPoint | ( | const CPoint & | point | ) |
Copy construction
| point | The point to copy |
| virtual Exponent::MathTools::CPoint::~CPoint | ( | ) | [virtual] |
Destruction
| virtual void Exponent::MathTools::CPoint::getObjectDescription | ( | char * | string, | |
| const long | size | |||
| ) | const [virtual] |
Get a description of the object
| string | On return is filled with the description | |
| size | The size of the stirng |
Reimplemented from Exponent::Basics::CCountedObject.
| long Exponent::MathTools::CPoint::getXPosition | ( | ) | const [inline] |
Get the x position
| long | The X Position |
Definition at line 128 of file CPoint.hpp.
References m_x.
Referenced by Exponent::GUI::Graphics::CGraphics::appendToDrawingAreaOffset(), Exponent::GUI::Graphics::CGraphics::drawAAPixelIncreasingX(), Exponent::GUI::Graphics::CGraphics::drawAAPixelIncreasingY(), Exponent::GUI::Windowing::CMouse::getXPosition(), Exponent::GUI::Graphics::CGraphics::negateFromDrawingArea(), and Exponent::MathTools::CRect::pointIsInside().
| long Exponent::MathTools::CPoint::getYPosition | ( | ) | const [inline] |
Get the y position
| long | The Y Position |
Definition at line 134 of file CPoint.hpp.
References m_y.
Referenced by Exponent::GUI::Graphics::CGraphics::appendToDrawingAreaOffset(), Exponent::GUI::Graphics::CGraphics::drawAAPixelIncreasingX(), Exponent::GUI::Graphics::CGraphics::drawAAPixelIncreasingY(), Exponent::GUI::Windowing::CMouse::getYPosition(), Exponent::GUI::Graphics::CGraphics::negateFromDrawingArea(), and Exponent::MathTools::CRect::pointIsInside().
| static bool Exponent::MathTools::CPoint::isStraightLine | ( | const CPoint & | point1, | |
| const CPoint & | point2 | |||
| ) | [static] |
Is this a straight line
| point1 | Starting point | |
| point2 | Ending point |
| bool | True if either p1.x==p2.x or p1.y==p2.y |
| void Exponent::MathTools::CPoint::offset | ( | const long | x, | |
| const long | y | |||
| ) |
Offset by an amount
| x | Amount to add to x position | |
| y | Amount to add to y position |
| void Exponent::MathTools::CPoint::offset | ( | const CPoint & | point | ) |
Offset the point with another point
| point | The amount to offset by |
Referenced by Exponent::GUI::Graphics::CGraphics::appendToDrawingAreaOffset(), Exponent::GUI::Graphics::CGraphics::drawAAPixelIncreasingX(), Exponent::GUI::Graphics::CGraphics::drawAAPixelIncreasingY(), and Exponent::GUI::Graphics::CGraphics::negateFromDrawingArea().
Offset the point with another point
| point | The amount to offset by |
Offset the point with another point
| point | The amount to offset by |
Assignment operator
| point | The point to copy |
| CPoint& | A reference to this |
| bool Exponent::MathTools::CPoint::operator== | ( | const CPoint & | point | ) | const |
Equlity operator
| point | The point to compare to |
| bool | True if the points are the same, false otherwise |
| bool Exponent::MathTools::CPoint::operator== | ( | const CPoint & | point | ) |
Equlity operator
| point | The point to compare to |
| bool | True if the points are the same, false otherwise |
| void Exponent::MathTools::CPoint::setPoint | ( | const long | x, | |
| const long | y | |||
| ) | [inline] |
Set the entire position
| x | The X Position | |
| y | The Y Position |
Definition at line 104 of file CPoint.hpp.
References setXPosition(), and setYPosition().
Referenced by Exponent::GUI::Graphics::CGraphics::resetDrawingArea().
| void Exponent::MathTools::CPoint::setXPosition | ( | const long | x | ) | [inline] |
Set the X Position
| x | The X Position |
Definition at line 114 of file CPoint.hpp.
References m_x.
Referenced by setPoint().
| void Exponent::MathTools::CPoint::setYPosition | ( | const long | y | ) | [inline] |
Set the Y Position
| y | The Y Position |
Definition at line 120 of file CPoint.hpp.
References m_y.
Referenced by setPoint().
long Exponent::MathTools::CPoint::m_x [protected] |
X Position
Definition at line 176 of file CPoint.hpp.
Referenced by getXPosition(), and setXPosition().
long Exponent::MathTools::CPoint::m_y [protected] |
Y Position
Definition at line 177 of file CPoint.hpp.
Referenced by getYPosition(), and setYPosition().