LibreOffice Module basegfx (master)  1
Public Member Functions | Static Public Member Functions | List of all members
basegfx::B2DPoint Class Reference

Base Point class with two double values. More...

#include <b2dpoint.hxx>

Inheritance diagram for basegfx::B2DPoint:
[legend]
Collaboration diagram for basegfx::B2DPoint:
[legend]

Public Member Functions

 B2DPoint ()
 Create a 2D Point. More...
 
 B2DPoint (double fX, double fY)
 Create a 2D Point. More...
 
 B2DPoint (const ::basegfx::B2IPoint &rPoint)
 Create a copy of a 2D Point. More...
 
 B2DPoint (const ::basegfx::B2DTuple &rTuple)
 constructor with tuple to allow copy-constructing from B2DTuple-based classes More...
 
B2DPointoperator*= (const B2DPoint &rPnt)
 *=operator to allow usage from B2DPoint, too More...
 
B2DPointoperator*= (double t)
 *=operator to allow usage from B2DPoint, too More...
 
BASEGFX_DLLPUBLIC B2DPointoperator= (const ::basegfx::B2DTuple &rPoint)
 assignment operator to allow assigning the results of B2DTuple calculations More...
 
BASEGFX_DLLPUBLIC B2DPointoperator*= (const ::basegfx::B2DHomMatrix &rMat)
 Transform point by given transformation matrix. More...
 
- Public Member Functions inherited from basegfx::B2DTuple
 B2DTuple ()
 Create a 2D Tuple. More...
 
 B2DTuple (double fX, double fY)
 Create a 2D Tuple. More...
 
BASEGFX_DLLPUBLIC B2DTuple (const B2ITuple &rTup)
 Create a copy of a 2D integer Tuple. More...
 
double getX () const
 Get X-Coordinate of 2D Tuple. More...
 
double getY () const
 Get Y-Coordinate of 2D Tuple. More...
 
void setX (double fX)
 Set X-Coordinate of 2D Tuple. More...
 
void setY (double fY)
 Set Y-Coordinate of 2D Tuple. More...
 
const double & operator[] (int nPos) const
 Array-access to 2D Tuple. More...
 
double & operator[] (int nPos)
 Array-access to 2D Tuple. More...
 
bool equalZero () const
 
bool equal (const B2DTuple &rTup) const
 
B2DTupleoperator+= (const B2DTuple &rTup)
 
B2DTupleoperator-= (const B2DTuple &rTup)
 
B2DTupleoperator/= (const B2DTuple &rTup)
 
B2DTupleoperator*= (const B2DTuple &rTup)
 
B2DTupleoperator*= (double t)
 
B2DTupleoperator/= (double t)
 
B2DTuple operator- (void) const
 
bool operator== (const B2DTuple &rTup) const
 
bool operator!= (const B2DTuple &rTup) const
 

Static Public Member Functions

static const B2DPointgetEmptyPoint ()
 
- Static Public Member Functions inherited from basegfx::B2DTuple
static BASEGFX_DLLPUBLIC const B2DTuplegetEmptyTuple ()
 

Additional Inherited Members

- Protected Attributes inherited from basegfx::B2DTuple
double mfX
 
double mfY
 

Detailed Description

Base Point class with two double values.

This class derives all operators and common handling for a 2D data class from B2DTuple. All necessary extensions which are special for points will be added here.

See also
B2DTuple

Definition at line 41 of file b2dpoint.hxx.

Constructor & Destructor Documentation

basegfx::B2DPoint::B2DPoint ( )
inline

Create a 2D Point.

The point is initialized to (0.0, 0.0)

Definition at line 48 of file b2dpoint.hxx.

basegfx::B2DPoint::B2DPoint ( double  fX,
double  fY 
)
inline

Create a 2D Point.

Parameters
fXThis parameter is used to initialize the X-coordinate of the 2D Point.
fYThis parameter is used to initialize the Y-coordinate of the 2D Point.

Definition at line 62 of file b2dpoint.hxx.

basegfx::B2DPoint::B2DPoint ( const ::basegfx::B2IPoint rPoint)
inlineexplicit

Create a copy of a 2D Point.

Parameters
rPointThe 2D Point which will be copied.

Definition at line 71 of file b2dpoint.hxx.

basegfx::B2DPoint::B2DPoint ( const ::basegfx::B2DTuple rTuple)
inline

constructor with tuple to allow copy-constructing from B2DTuple-based classes

Definition at line 78 of file b2dpoint.hxx.

Member Function Documentation

static const B2DPoint& basegfx::B2DPoint::getEmptyPoint ( )
inlinestatic

Definition at line 112 of file b2dpoint.hxx.

References basegfx::B2DTuple::getEmptyTuple().

Referenced by ImplB3DPolygon::insert().

B2DPoint& basegfx::B2DPoint::operator*= ( const B2DPoint rPnt)
inline

*=operator to allow usage from B2DPoint, too

Definition at line 84 of file b2dpoint.hxx.

References mfX, basegfx::B2DTuple::mfX, mfY, and basegfx::B2DTuple::mfY.

B2DPoint& basegfx::B2DPoint::operator*= ( double  t)
inline

*=operator to allow usage from B2DPoint, too

Definition at line 93 of file b2dpoint.hxx.

References mfX, and mfY.

B2DPoint & basegfx::B2DPoint::operator*= ( const ::basegfx::B2DHomMatrix rMat)

Transform point by given transformation matrix.

The translational components of the matrix are, in contrast to B2DVector, applied.

Definition at line 33 of file b2dpoint.cxx.

References basegfx::fTools::equal(), basegfx::fTools::equalZero(), basegfx::B2DTuple::mfX, and basegfx::B2DTuple::mfY.

B2DPoint & basegfx::B2DPoint::operator= ( const ::basegfx::B2DTuple rPoint)

assignment operator to allow assigning the results of B2DTuple calculations

Definition at line 26 of file b2dpoint.cxx.

References basegfx::B2DTuple::mfX, and basegfx::B2DTuple::mfY.


The documentation for this class was generated from the following files: