summaryrefslogtreecommitdiff
path: root/tools/source/generic/poly2.cxx
diff options
context:
space:
mode:
authorPhilipp Riemer <ruderphilipp@gmail.com>2012-08-18 18:12:35 +0200
committerPhilipp Riemer <ruderphilipp@gmail.com>2012-08-18 18:33:50 +0200
commit42352dff5a8dc4c89fccf399359876aea7dc7d2d (patch)
tree7747642c5ee1c7465e8a684a35713f5dbd90dc82 /tools/source/generic/poly2.cxx
parent0700d6a1f3524ab79b5114559fb2d15c7ba85112 (diff)
removed ascii-art and blank lines in tools/source
Change-Id: I3f95d12a8c325c96c586253b5d9bb7dce24c0858
Diffstat (limited to 'tools/source/generic/poly2.cxx')
-rw-r--r--tools/source/generic/poly2.cxx81
1 files changed, 0 insertions, 81 deletions
diff --git a/tools/source/generic/poly2.cxx b/tools/source/generic/poly2.cxx
index 726d652a4b16..0bf255514d59 100644
--- a/tools/source/generic/poly2.cxx
+++ b/tools/source/generic/poly2.cxx
@@ -32,14 +32,8 @@
#include <basegfx/polygon/b2dpolygon.hxx>
#include <basegfx/polygon/b2dpolypolygoncutter.hxx>
-// ---------------
-// - PolyPolygon -
-// ---------------
-
DBG_NAME( PolyPolygon )
-// -----------------------------------------------------------------------
-
ImplPolyPolygon::ImplPolyPolygon( sal_uInt16 nInitSize )
{
mnRefCount = 1;
@@ -49,8 +43,6 @@ ImplPolyPolygon::ImplPolyPolygon( sal_uInt16 nInitSize )
mpPolyAry = new SVPPOLYGON[ nInitSize ];
}
-// -----------------------------------------------------------------------
-
ImplPolyPolygon::ImplPolyPolygon( const ImplPolyPolygon& rImplPolyPoly )
{
mnRefCount = 1;
@@ -68,8 +60,6 @@ ImplPolyPolygon::ImplPolyPolygon( const ImplPolyPolygon& rImplPolyPoly )
mpPolyAry = NULL;
}
-// -----------------------------------------------------------------------
-
ImplPolyPolygon::~ImplPolyPolygon()
{
if ( mpPolyAry )
@@ -80,8 +70,6 @@ ImplPolyPolygon::~ImplPolyPolygon()
}
}
-// =======================================================================
-
PolyPolygon::PolyPolygon( sal_uInt16 nInitSize, sal_uInt16 nResize )
{
DBG_CTOR( PolyPolygon, NULL );
@@ -97,8 +85,6 @@ PolyPolygon::PolyPolygon( sal_uInt16 nInitSize, sal_uInt16 nResize )
mpImplPolyPolygon = new ImplPolyPolygon( nInitSize, nResize );
}
-// -----------------------------------------------------------------------
-
PolyPolygon::PolyPolygon( const Polygon& rPoly )
{
DBG_CTOR( PolyPolygon, NULL );
@@ -112,8 +98,6 @@ PolyPolygon::PolyPolygon( const Polygon& rPoly )
mpImplPolyPolygon = new ImplPolyPolygon( 16, 16 );
}
-// -----------------------------------------------------------------------
-
PolyPolygon::PolyPolygon( sal_uInt16 nPoly, const sal_uInt16* pPointCountAry,
const Point* pPtAry )
{
@@ -131,8 +115,6 @@ PolyPolygon::PolyPolygon( sal_uInt16 nPoly, const sal_uInt16* pPointCountAry,
}
}
-// -----------------------------------------------------------------------
-
PolyPolygon::PolyPolygon( const PolyPolygon& rPolyPoly )
{
DBG_CTOR( PolyPolygon, NULL );
@@ -143,8 +125,6 @@ PolyPolygon::PolyPolygon( const PolyPolygon& rPolyPoly )
mpImplPolyPolygon->mnRefCount++;
}
-// -----------------------------------------------------------------------
-
PolyPolygon::~PolyPolygon()
{
DBG_DTOR( PolyPolygon, NULL );
@@ -155,8 +135,6 @@ PolyPolygon::~PolyPolygon()
delete mpImplPolyPolygon;
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Insert( const Polygon& rPoly, sal_uInt16 nPos )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -202,8 +180,6 @@ void PolyPolygon::Insert( const Polygon& rPoly, sal_uInt16 nPos )
mpImplPolyPolygon->mnCount++;
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Remove( sal_uInt16 nPos )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -222,8 +198,6 @@ void PolyPolygon::Remove( sal_uInt16 nPos )
(mpImplPolyPolygon->mnCount-nPos)*sizeof(SVPPOLYGON) );
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Replace( const Polygon& rPoly, sal_uInt16 nPos )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -239,8 +213,6 @@ void PolyPolygon::Replace( const Polygon& rPoly, sal_uInt16 nPos )
mpImplPolyPolygon->mpPolyAry[nPos] = new Polygon( rPoly );
}
-// -----------------------------------------------------------------------
-
const Polygon& PolyPolygon::GetObject( sal_uInt16 nPos ) const
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -249,8 +221,6 @@ const Polygon& PolyPolygon::GetObject( sal_uInt16 nPos ) const
return *(mpImplPolyPolygon->mpPolyAry[nPos]);
}
-// -----------------------------------------------------------------------
-
sal_Bool PolyPolygon::IsRect() const
{
sal_Bool bIsRect = sal_False;
@@ -259,8 +229,6 @@ sal_Bool PolyPolygon::IsRect() const
return bIsRect;
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Clear()
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -285,8 +253,6 @@ void PolyPolygon::Clear()
}
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Optimize( sal_uIntPtr nOptimizeFlags, const PolyOptimizeData* pData )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -328,8 +294,6 @@ void PolyPolygon::Optimize( sal_uIntPtr nOptimizeFlags, const PolyOptimizeData*
}
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::AdaptiveSubdivide( PolyPolygon& rResult, const double d ) const
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -345,36 +309,26 @@ void PolyPolygon::AdaptiveSubdivide( PolyPolygon& rResult, const double d ) cons
}
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::GetIntersection( const PolyPolygon& rPolyPoly, PolyPolygon& rResult ) const
{
ImplDoOperation( rPolyPoly, rResult, POLY_CLIP_INT );
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::GetUnion( const PolyPolygon& rPolyPoly, PolyPolygon& rResult ) const
{
ImplDoOperation( rPolyPoly, rResult, POLY_CLIP_UNION );
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::GetDifference( const PolyPolygon& rPolyPoly, PolyPolygon& rResult ) const
{
ImplDoOperation( rPolyPoly, rResult, POLY_CLIP_DIFF );
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::GetXOR( const PolyPolygon& rPolyPoly, PolyPolygon& rResult ) const
{
ImplDoOperation( rPolyPoly, rResult, POLY_CLIP_XOR );
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::ImplDoOperation( const PolyPolygon& rPolyPoly, PolyPolygon& rResult, sal_uIntPtr nOperation ) const
{
// Convert to B2DPolyPolygon, temporarily. It might be
@@ -391,7 +345,6 @@ void PolyPolygon::ImplDoOperation( const PolyPolygon& rPolyPoly, PolyPolygon& rR
switch( nOperation )
{
// All code extracted from svx/source/svdraw/svedtv2.cxx
- // -----------------------------------------------------
case POLY_CLIP_UNION:
{
@@ -426,16 +379,12 @@ void PolyPolygon::ImplDoOperation( const PolyPolygon& rPolyPoly, PolyPolygon& rR
rResult = PolyPolygon( aMergePolyPolygonA );
}
-// -----------------------------------------------------------------------
-
sal_uInt16 PolyPolygon::Count() const
{
DBG_CHKTHIS( PolyPolygon, NULL );
return mpImplPolyPolygon->mnCount;
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Move( long nHorzMove, long nVertMove )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -457,8 +406,6 @@ void PolyPolygon::Move( long nHorzMove, long nVertMove )
}
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Translate( const Point& rTrans )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -475,8 +422,6 @@ void PolyPolygon::Translate( const Point& rTrans )
mpImplPolyPolygon->mpPolyAry[ i ]->Translate( rTrans );
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Scale( double fScaleX, double fScaleY )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -493,8 +438,6 @@ void PolyPolygon::Scale( double fScaleX, double fScaleY )
mpImplPolyPolygon->mpPolyAry[ i ]->Scale( fScaleX, fScaleY );
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Rotate( const Point& rCenter, sal_uInt16 nAngle10 )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -507,8 +450,6 @@ void PolyPolygon::Rotate( const Point& rCenter, sal_uInt16 nAngle10 )
}
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Rotate( const Point& rCenter, double fSin, double fCos )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -525,8 +466,6 @@ void PolyPolygon::Rotate( const Point& rCenter, double fSin, double fCos )
mpImplPolyPolygon->mpPolyAry[ i ]->Rotate( rCenter, fSin, fCos );
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Clip( const Rectangle& rRect )
{
// Polygon-Clippen
@@ -554,8 +493,6 @@ void PolyPolygon::Clip( const Rectangle& rRect )
}
}
-// -----------------------------------------------------------------------
-
Rectangle PolyPolygon::GetBoundRect() const
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -600,8 +537,6 @@ Rectangle PolyPolygon::GetBoundRect() const
return Rectangle();
}
-// -----------------------------------------------------------------------
-
Polygon& PolyPolygon::operator[]( sal_uInt16 nPos )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -616,8 +551,6 @@ Polygon& PolyPolygon::operator[]( sal_uInt16 nPos )
return *(mpImplPolyPolygon->mpPolyAry[nPos]);
}
-// -----------------------------------------------------------------------
-
PolyPolygon& PolyPolygon::operator=( const PolyPolygon& rPolyPoly )
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -635,8 +568,6 @@ PolyPolygon& PolyPolygon::operator=( const PolyPolygon& rPolyPoly )
return *this;
}
-// -----------------------------------------------------------------------
-
sal_Bool PolyPolygon::operator==( const PolyPolygon& rPolyPoly ) const
{
DBG_CHKTHIS( PolyPolygon, NULL );
@@ -648,8 +579,6 @@ sal_Bool PolyPolygon::operator==( const PolyPolygon& rPolyPoly ) const
return sal_False;
}
-// -----------------------------------------------------------------------
-
sal_Bool PolyPolygon::IsEqual( const PolyPolygon& rPolyPoly ) const
{
sal_Bool bIsEqual = sal_True;
@@ -670,8 +599,6 @@ sal_Bool PolyPolygon::IsEqual( const PolyPolygon& rPolyPoly ) const
return bIsEqual;
}
-// -----------------------------------------------------------------------
-
SvStream& operator>>( SvStream& rIStream, PolyPolygon& rPolyPoly )
{
DBG_CHKOBJ( &rPolyPoly, PolyPolygon, NULL );
@@ -707,8 +634,6 @@ SvStream& operator>>( SvStream& rIStream, PolyPolygon& rPolyPoly )
return rIStream;
}
-// -----------------------------------------------------------------------
-
SvStream& operator<<( SvStream& rOStream, const PolyPolygon& rPolyPoly )
{
DBG_CHKOBJ( &rPolyPoly, PolyPolygon, NULL );
@@ -725,8 +650,6 @@ SvStream& operator<<( SvStream& rOStream, const PolyPolygon& rPolyPoly )
return rOStream;
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Read( SvStream& rIStream )
{
VersionCompat aCompat( rIStream, STREAM_READ );
@@ -762,8 +685,6 @@ void PolyPolygon::Read( SvStream& rIStream )
*this = PolyPolygon();
}
-// -----------------------------------------------------------------------
-
void PolyPolygon::Write( SvStream& rOStream ) const
{
VersionCompat aCompat( rOStream, STREAM_WRITE, 1 );
@@ -780,7 +701,6 @@ void PolyPolygon::Write( SvStream& rOStream ) const
mpImplPolyPolygon->mpPolyAry[i]->ImplWrite( rOStream );
}
-// -----------------------------------------------------------------------
// convert to basegfx::B2DPolyPolygon and return
basegfx::B2DPolyPolygon PolyPolygon::getB2DPolyPolygon() const
{
@@ -795,7 +715,6 @@ basegfx::B2DPolyPolygon PolyPolygon::getB2DPolyPolygon() const
return aRetval;
}
-// -----------------------------------------------------------------------
// constructor to convert from basegfx::B2DPolyPolygon
PolyPolygon::PolyPolygon(const basegfx::B2DPolyPolygon& rPolyPolygon)
{