[Libreoffice-commits] .: basegfx/inc basegfx/source

2012-04-14 Thread Miklos Vajna
 basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx |4 -
 basegfx/inc/basegfx/polygon/b3dpolygontools.hxx |6 -
 basegfx/inc/basegfx/polygon/b3dpolypolygontools.hxx |4 -
 basegfx/source/polygon/b2dpolypolygontools.cxx  |   21 --
 basegfx/source/polygon/b3dpolygontools.cxx  |   65 
 basegfx/source/polygon/b3dpolypolygontools.cxx  |   21 --
 6 files changed, 121 deletions(-)

New commits:
commit 7a9738f407c916d56090e9805632a5b29f96df18
Author: Gábor Stefanik 
Date:   Sat Apr 14 01:10:24 2012 +0200

Clean up basegfx's polygon tools code

diff --git a/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx 
b/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
index 091614a..bacc97d 100644
--- a/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
+++ b/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
@@ -227,10 +227,6 @@ namespace basegfx
 // #i76891# Try to remove existing curve segments if they are simply 
edges
 BASEGFX_DLLPUBLIC B2DPolyPolygon simplifyCurveSegments(const 
B2DPolyPolygon& rCandidate);
 
-//
-// comparators with tolerance for 2D PolyPolygons
-BASEGFX_DLLPUBLIC bool equal(const B2DPolyPolygon& rCandidateA, const 
B2DPolyPolygon& rCandidateB, const double& rfSmallValue);
-
 /** snap some polygon coordinates to discrete coordinates
 
 This method allows to snap some polygon points to discrete 
(integer) values
diff --git a/basegfx/inc/basegfx/polygon/b3dpolygontools.hxx 
b/basegfx/inc/basegfx/polygon/b3dpolygontools.hxx
index c94495e..1ff1e6e 100644
--- a/basegfx/inc/basegfx/polygon/b3dpolygontools.hxx
+++ b/basegfx/inc/basegfx/polygon/b3dpolygontools.hxx
@@ -67,12 +67,6 @@ namespace basegfx
 // get normal vector of polygon
 BASEGFX_DLLPUBLIC B3DVector getNormal(const B3DPolygon& rCandidate);
 
-// get signed area of polygon
-BASEGFX_DLLPUBLIC double getSignedArea(const B3DPolygon& rCandidate);
-
-// get signed area of polygon
-BASEGFX_DLLPUBLIC double getSignedArea(const B3DPolygon& rCandidate);
-
 // get area of polygon
 BASEGFX_DLLPUBLIC double getArea(const ::basegfx::B3DPolygon& 
rCandidate);
 
diff --git a/basegfx/inc/basegfx/polygon/b3dpolypolygontools.hxx 
b/basegfx/inc/basegfx/polygon/b3dpolypolygontools.hxx
index 327ef19..4c3c0b0 100644
--- a/basegfx/inc/basegfx/polygon/b3dpolypolygontools.hxx
+++ b/basegfx/inc/basegfx/polygon/b3dpolypolygontools.hxx
@@ -134,10 +134,6 @@ namespace basegfx
 // in bWithBorder flag. It is assumed that the orientations of the 
given polygon are correct.
 BASEGFX_DLLPUBLIC bool isInside(const B3DPolyPolygon& rCandidate, 
const B3DPoint& rPoint, bool bWithBorder = false);
 
-//
-// comparators with tolerance for 3D PolyPolygons
-BASEGFX_DLLPUBLIC bool equal(const B3DPolyPolygon& rCandidateA, const 
B3DPolyPolygon& rCandidateB, const double& rfSmallValue);
-
 } // end of namespace tools
 } // end of namespace basegfx
 
diff --git a/basegfx/source/polygon/b2dpolypolygontools.cxx 
b/basegfx/source/polygon/b2dpolypolygontools.cxx
index 6434dc0..e071b18 100644
--- a/basegfx/source/polygon/b2dpolypolygontools.cxx
+++ b/basegfx/source/polygon/b2dpolypolygontools.cxx
@@ -475,27 +475,6 @@ namespace basegfx
 }
 }
 
-//
-// comparators with tolerance for 2D PolyPolygons
-
-bool equal(const B2DPolyPolygon& rCandidateA, const B2DPolyPolygon& 
rCandidateB, const double& rfSmallValue)
-{
-const sal_uInt32 nPolygonCount(rCandidateA.count());
-
-if(nPolygonCount != rCandidateB.count())
-return false;
-
-for(sal_uInt32 a(0); a < nPolygonCount; a++)
-{
-const B2DPolygon aCandidate(rCandidateA.getB2DPolygon(a));
-
-if(!equal(aCandidate, rCandidateB.getB2DPolygon(a), 
rfSmallValue))
-return false;
-}
-
-return true;
-}
-
 B2DPolyPolygon snapPointsOfHorizontalOrVerticalEdges(const 
B2DPolyPolygon& rCandidate)
 {
 B2DPolyPolygon aRetval;
diff --git a/basegfx/source/polygon/b3dpolygontools.cxx 
b/basegfx/source/polygon/b3dpolygontools.cxx
index 8bdfd13..bcec720 100644
--- a/basegfx/source/polygon/b3dpolygontools.cxx
+++ b/basegfx/source/polygon/b3dpolygontools.cxx
@@ -88,71 +88,6 @@ namespace basegfx
 return rCandidate.getNormal();
 }
 
-double getSignedArea(const B3DPolygon& rCandidate)
-{
-double fRetval(0.0);
-const sal_uInt32 nPointCount(rCandidate.count());
-
-if(nPointCount > 2)
-{
-const B3DVector aAbsNormal(absolute(getNorm

[Libreoffice-commits] .: basegfx/inc basegfx/source xmloff/inc xmloff/source

2012-03-26 Thread Fridrich Strba
 basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx |7 ++-
 basegfx/source/polygon/b2dsvgpolypolygon.cxx|4 ++--
 xmloff/inc/xexptran.hxx |3 ++-
 xmloff/source/draw/xexptran.cxx |   15 +--
 xmloff/source/draw/ximp3dobject.cxx |3 +--
 xmloff/source/draw/ximpshap.cxx |6 ++
 xmloff/source/style/MarkerStyle.cxx |3 +--
 xmloff/source/text/XMLTextFrameContext.cxx  |3 +--
 8 files changed, 28 insertions(+), 16 deletions(-)

New commits:
commit 7a19798c73fd39d8d69ff6364f0696e68cdd1381
Author: Fridrich Å trba 
Date:   Mon Mar 26 12:55:44 2012 +0200

Compatibility option for incorrect relative moves after closePath 
(fdo#47406)

diff --git a/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx 
b/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
index 54437ba..091614a 100644
--- a/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
+++ b/basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx
@@ -118,10 +118,15 @@ namespace basegfx
 @param rSvgDAttribute
 A valid SVG-D attribute string
 
+@param rWrongPositionAfterZ
+Indicates wheter the generator interprets wrongly
+the position in the path after Z or z elements
+https://bugs.freedesktop.org/show_bug.cgi?id=47406
+
 @return true, if the string was successfully parsed
  */
 BASEGFX_DLLPUBLIC bool importFromSvgD( B2DPolyPolygon&
o_rPolyPoly,
- const ::rtl::OUString& rSvgDAttribute );
+ const ::rtl::OUString& rSvgDAttribute, bool 
bWrongPositionAfterZ = false );
 
 /** Read poly-polygon from SVG.
 
diff --git a/basegfx/source/polygon/b2dsvgpolypolygon.cxx 
b/basegfx/source/polygon/b2dsvgpolypolygon.cxx
index 590b8db..e3e60cd 100644
--- a/basegfx/source/polygon/b2dsvgpolypolygon.cxx
+++ b/basegfx/source/polygon/b2dsvgpolypolygon.cxx
@@ -209,7 +209,7 @@ namespace basegfx
 }
 }
 
-bool importFromSvgD(B2DPolyPolygon& o_rPolyPolygon, const 
::rtl::OUString&  rSvgDStatement)
+bool importFromSvgD(B2DPolyPolygon& o_rPolyPolygon, const 
::rtl::OUString&  rSvgDStatement, bool bWrongPositionAfterZ)
 {
 o_rPolyPolygon.clear();
 const sal_Int32 nLen(rSvgDStatement.getLength());
@@ -240,7 +240,7 @@ namespace basegfx
 bIsClosed = true;
 
 // update current point - we're back at the start
-if( aCurrPoly.count() )
+if( aCurrPoly.count() && !bWrongPositionAfterZ)
 {
 const B2DPoint aFirst( aCurrPoly.getB2DPoint(0) );
 nLastX = aFirst.getX();
diff --git a/xmloff/inc/xexptran.hxx b/xmloff/inc/xexptran.hxx
index 814ad2a..86883cf 100644
--- a/xmloff/inc/xexptran.hxx
+++ b/xmloff/inc/xexptran.hxx
@@ -36,6 +36,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 
@@ -171,7 +172,7 @@ public:
 const SdXMLImExViewBox& rViewBox,
 const com::sun::star::awt::Point& rObjectPos,
 const com::sun::star::awt::Size& rObjectSize,
-const SvXMLUnitConverter& rConv);
+const SvXMLImport& rImport);
 
 void AddPolygon(
 com::sun::star::drawing::PointSequence* pPoints,
diff --git a/xmloff/source/draw/xexptran.cxx b/xmloff/source/draw/xexptran.cxx
index 6032984..80a61ac 100644
--- a/xmloff/source/draw/xexptran.cxx
+++ b/xmloff/source/draw/xexptran.cxx
@@ -2121,7 +2121,7 @@ SdXMLImExSvgDElement::SdXMLImExSvgDElement(const 
OUString& rNew,
 const SdXMLImExViewBox& rViewBox,
 const awt::Point& rObjectPos,
 const awt::Size& rObjectSize,
-const SvXMLUnitConverter& /*rConv*/)
+const SvXMLImport& rImport)
 :   msString( rNew ),
 mrViewBox( rViewBox ),
 mbIsClosed( false ),
@@ -2130,9 +2130,20 @@ SdXMLImExSvgDElement::SdXMLImExSvgDElement(const 
OUString& rNew,
 mnLastY( 0L ),
 maPoly()
 {
+bool bWrongPositionAfterZ( false );
+   sal_Int32 nUPD( 0 );
+   sal_Int32 nBuildId( 0 );
+   if ( rImport.getBuildIds( nUPD, nBuildId ) &&
+   ( ( nUPD == 641 ) || ( nUPD == 645 ) || ( nUPD == 680 ) || ( nUPD == 
300 ) ||
+ ( nUPD == 310 ) || ( nUPD == 320 ) || ( nUPD == 330 ) || ( nUPD == 
340 ) ||
+ ( nUPD == 350 && nBuildId < 202 ) ) )
+{
+bWrongPositionAfterZ = true;
+}
+
 // convert string to polygon
 basegfx::B2DPolyPolygon aPoly;
-basegfx::tools::importFromSvgD(aPoly,msString);
+basegfx::tools::importFromSvgD(aPoly,msString,bWrongPositionAfterZ);
 
 mbIsCurve = aPoly.areControlPointsUsed();
 mbIsClosed = aPoly.isClosed();
diff --git a/xmloff/source/draw/ximp3dobject.cxx 
b/xmloff/source/draw/ximp3dobject.cxx
index 1d84030..eacf1df 100644
--- a/xmloff/source/draw/ximp3dobject.cxx
+++ b/

[Libreoffice-commits] .: basegfx/inc basegfx/source sw/source

2012-03-20 Thread Jan Holesovsky
 basegfx/inc/basegfx/tools/zoomtools.hxx |2 --
 basegfx/source/tools/zoomtools.cxx  |   21 -
 sw/source/ui/uiview/viewport.cxx|6 +++---
 3 files changed, 3 insertions(+), 26 deletions(-)

New commits:
commit f626ff59b229ce7aec2f2313936133c53d70781f
Author: Tim Hardeck 
Date:   Thu Feb 23 19:59:34 2012 +0100

removed zoomtools int functions

Changed viewport.cxx to use long instead of int like all other zoom
functions and in this succession removed the zoomtools int functions
which where only added for this one exception.

diff --git a/basegfx/inc/basegfx/tools/zoomtools.hxx 
b/basegfx/inc/basegfx/tools/zoomtools.hxx
index 566418d..44d9052 100644
--- a/basegfx/inc/basegfx/tools/zoomtools.hxx
+++ b/basegfx/inc/basegfx/tools/zoomtools.hxx
@@ -42,8 +42,6 @@ namespace basegfx
 {
 BASEGFX_DLLPUBLIC long zoomOut(long nCurrent);
 BASEGFX_DLLPUBLIC long zoomIn(long nCurrent);
-BASEGFX_DLLPUBLIC int zoomOut(int nCurrent);
-BASEGFX_DLLPUBLIC int zoomIn(int nCurrent);
 }
 }
 
diff --git a/basegfx/source/tools/zoomtools.cxx 
b/basegfx/source/tools/zoomtools.cxx
index d4b274c..34b0b8c 100644
--- a/basegfx/source/tools/zoomtools.cxx
+++ b/basegfx/source/tools/zoomtools.cxx
@@ -129,27 +129,6 @@ long zoomOut(long nCurrent)
 nNew = enforceStep(nNew, nCurrent, 25);
 return nNew;
 }
-
-/**
-* Increasing the zoom level.
-*
-* @param nCurrent current zoom factor
-*/
-int zoomIn(int nCurrent)
-{
-return static_cast( zoomIn( long( nCurrent ) ) );
-}
-
-/**
-* Decreasing the zoom level.
-*
-* @param nCurrent current zoom factor
-*/
-int zoomOut(int nCurrent)
-{
-return static_cast( zoomOut( long( nCurrent ) ) );
-}
-
 } // namespace zoomtools
 } // namespace basegfx
 
diff --git a/sw/source/ui/uiview/viewport.cxx b/sw/source/ui/uiview/viewport.cxx
index d6b723d..e28d63e 100644
--- a/sw/source/ui/uiview/viewport.cxx
+++ b/sw/source/ui/uiview/viewport.cxx
@@ -1307,11 +1307,11 @@ sal_Bool SwView::HandleWheelCommands( const 
CommandEvent& rCEvt )
 const CommandWheelData* pWData = rCEvt.GetWheelData();
 if( pWData && COMMAND_WHEEL_ZOOM == pWData->GetMode() )
 {
-sal_uInt16 nFact = pWrtShell->GetViewOptions()->GetZoom();
+long nFact = pWrtShell->GetViewOptions()->GetZoom();
 if( 0L > pWData->GetDelta() )
-nFact = static_cast< sal_uInt16 >(Max( 20, 
basegfx::zoomtools::zoomOut( static_cast(nFact) )));
+nFact = Max( (long) 20, basegfx::zoomtools::zoomOut( nFact ));
 else
-nFact = static_cast< sal_uInt16 >(Min( 600, 
basegfx::zoomtools::zoomIn( static_cast(nFact) )));
+nFact = Min( (long) 600, basegfx::zoomtools::zoomIn( nFact ));
 
 SetZoom( SVX_ZOOM_PERCENT, nFact );
 bOk = sal_True;
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: basegfx/inc basegfx/source sc/inc sc/source sot/inc sot/source toolkit/inc toolkit/source unusedcode.easy

2012-03-05 Thread Tor Lillqvist
 basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx |3 
 basegfx/source/polygon/b3dpolygonclipper.cxx  |  172 --
 sc/inc/conditio.hxx   |4 
 sc/inc/dpsave.hxx |2 
 sc/inc/postit.hxx |2 
 sc/inc/rangenam.hxx   |1 
 sc/source/core/data/conditio.cxx  |9 -
 sc/source/core/data/dpsave.cxx|  116 --
 sc/source/core/data/postit.cxx|9 -
 sc/source/core/tool/rangenam.cxx  |   28 ---
 sc/source/ui/dbgui/fieldwnd.cxx   |8 -
 sc/source/ui/inc/fieldwnd.hxx |3 
 sot/inc/sot/stg.hxx   |1 
 sot/source/sdstor/stg.cxx |8 -
 sot/source/sdstor/stgavl.cxx  |6 
 sot/source/sdstor/stgavl.hxx  |1 
 toolkit/inc/toolkit/controls/unocontrols.hxx  |2 
 toolkit/source/controls/unocontrols.cxx   |   17 --
 unusedcode.easy   |   12 -
 19 files changed, 1 insertion(+), 403 deletions(-)

New commits:
commit a1a1131c16227327d17bcf5ad2a5209ddc0f01a1
Author: Elton Chung 
Date:   Sun Mar 4 15:27:27 2012 +0800

Remove unused code

diff --git a/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx 
b/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
index a6ca714..d1bce0e 100644
--- a/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
+++ b/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
@@ -52,9 +52,6 @@ namespace basegfx
 B3DORIENTATION_Z// Z-Axis
 };
 
-// version for Polygons
-BASEGFX_DLLPUBLIC B3DPolyPolygon clipPolygonOnOrthogonalPlane(const 
B3DPolygon& rCandidate, B3DOrientation ePlaneOrthogonal, bool bClipPositive, 
double fPlaneOffset, bool bStroke);
-
 } // end of namespace tools
 } // end of namespace basegfx
 
diff --git a/basegfx/source/polygon/b3dpolygonclipper.cxx 
b/basegfx/source/polygon/b3dpolygonclipper.cxx
index 8130d00..728fc46 100644
--- a/basegfx/source/polygon/b3dpolygonclipper.cxx
+++ b/basegfx/source/polygon/b3dpolygonclipper.cxx
@@ -127,178 +127,6 @@ namespace basegfx
 
 //
 
-namespace basegfx
-{
-namespace tools
-{
-B3DPolyPolygon clipPolygonOnOrthogonalPlane(const B3DPolygon& 
rCandidate, B3DOrientation ePlaneOrthogonal, bool bClipPositive, double 
fPlaneOffset, bool bStroke)
-{
-B3DPolyPolygon aRetval;
-
-if(rCandidate.count())
-{
-const B3DRange aCandidateRange(getRange(rCandidate));
-
-if(B3DORIENTATION_X == ePlaneOrthogonal && 
fTools::moreOrEqual(aCandidateRange.getMinX(), fPlaneOffset))
-{
-// completely above and on the clip plane.
-if(bClipPositive)
-{
-// add completely
-aRetval.append(rCandidate);
-}
-}
-else if(B3DORIENTATION_X == ePlaneOrthogonal && 
fTools::lessOrEqual(aCandidateRange.getMaxX(), fPlaneOffset))
-{
-// completely below and on the clip plane.
-if(!bClipPositive)
-{
-// add completely
-aRetval.append(rCandidate);
-}
-}
-else if(B3DORIENTATION_Y == ePlaneOrthogonal && 
fTools::moreOrEqual(aCandidateRange.getMinY(), fPlaneOffset))
-{
-// completely above and on the clip plane.
-if(bClipPositive)
-{
-// add completely
-aRetval.append(rCandidate);
-}
-}
-else if(B3DORIENTATION_Y == ePlaneOrthogonal && 
fTools::lessOrEqual(aCandidateRange.getMaxY(), fPlaneOffset))
-{
-// completely below and on the clip plane.
-if(!bClipPositive)
-{
-// add completely
-aRetval.append(rCandidate);
-}
-}
-else if(B3DORIENTATION_Z == ePlaneOrthogonal && 
fTools::moreOrEqual(aCandidateRange.getMinZ(), fPlaneOffset))
-{
-// completely above and on the clip plane.
-if(bClipPositive)
-{
-// add completely
-aRetval.append(rCandidate);
-}
-}
-else if(B3DORIENTATION_Z == ePlaneOrthogonal && 
fTools::lessOrEqual(aCandidateRange.getMaxZ(), fPlaneOffset))
-{
-// comp

[Libreoffice-commits] .: basegfx/inc

2012-02-26 Thread Ivan Timofeev
 basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx |3 ---
 1 file changed, 3 deletions(-)

New commits:
commit 0499a44cddae31dff5ce1959aba8aa64119dea90
Author: Ivan Timofeev 
Date:   Sun Feb 26 16:29:47 2012 +0400

definition was removed, remove declaration as well

diff --git a/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx 
b/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
index 03fd079..d125d47 100644
--- a/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
+++ b/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
@@ -62,9 +62,6 @@ namespace basegfx
 // version for Polygons
 BASEGFX_DLLPUBLIC B3DPolyPolygon clipPolygonOnOrthogonalPlane(const 
B3DPolygon& rCandidate, B3DOrientation ePlaneOrthogonal, bool bClipPositive, 
double fPlaneOffset, bool bStroke);
 
-// versions for B2DRange, clips only against X,Y
-BASEGFX_DLLPUBLIC B3DPolyPolygon clipPolygonOnRange(const B3DPolygon& 
rCandidate, const B2DRange& rRange, bool bInside, bool bStroke);
-
 } // end of namespace tools
 } // end of namespace basegfx
 
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: basegfx/inc basegfx/source unusedcode.easy

2012-02-20 Thread Michael Meeks
 basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx|2 
 basegfx/inc/basegfx/polygon/b2dpolygontools.hxx |   58 ---
 basegfx/inc/basegfx/polygon/b2dpolypolygontools.hxx |4 
 basegfx/inc/basegfx/polygon/b3dpolygontools.hxx |5 
 basegfx/inc/basegfx/polygon/b3dpolypolygontools.hxx |1 
 basegfx/inc/basegfx/tools/tools.hxx |   24 -
 basegfx/source/matrix/b2dhommatrixtools.cxx |   24 -
 basegfx/source/polygon/b2dpolygontools.cxx  |  302 
 basegfx/source/polygon/b2dpolypolygontools.cxx  |   22 -
 basegfx/source/polygon/b3dpolygontools.cxx  |   99 --
 basegfx/source/polygon/b3dpolypolygontools.cxx  |7 
 basegfx/source/tools/liangbarsky.cxx|   57 ---
 unusedcode.easy |   14 
 13 files changed, 619 deletions(-)

New commits:
commit dbff99a60ec5268c92f1404cb01754de9186c2e8
Author: Elton Chung 
Date:   Mon Feb 20 00:30:16 2012 +0800

Remove unused code

diff --git a/basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx 
b/basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx
index e53a598..cf49df0 100644
--- a/basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx
+++ b/basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx
@@ -56,8 +56,6 @@ namespace basegfx
 multiplications
  */
 BASEGFX_DLLPUBLIC B2DHomMatrix createScaleB2DHomMatrix(double fScaleX, 
double fScaleY);
-BASEGFX_DLLPUBLIC B2DHomMatrix createShearXB2DHomMatrix(double 
fShearX);
-BASEGFX_DLLPUBLIC B2DHomMatrix createShearYB2DHomMatrix(double 
fShearY);
 BASEGFX_DLLPUBLIC B2DHomMatrix createRotateB2DHomMatrix(double 
fRadiant);
 BASEGFX_DLLPUBLIC B2DHomMatrix createTranslateB2DHomMatrix(double 
fTranslateX, double fTranslateY);
 
diff --git a/basegfx/inc/basegfx/polygon/b2dpolygontools.hxx 
b/basegfx/inc/basegfx/polygon/b2dpolygontools.hxx
index 1bee9b3..86c31f3 100644
--- a/basegfx/inc/basegfx/polygon/b2dpolygontools.hxx
+++ b/basegfx/inc/basegfx/polygon/b2dpolygontools.hxx
@@ -154,23 +154,6 @@ namespace basegfx
 #define CUTFLAG_ALL 
(CUTFLAG_LINE|CUTFLAG_START1|CUTFLAG_START2|CUTFLAG_END1|CUTFLAG_END2)
 #define CUTFLAG_DEFAULT (CUTFLAG_LINE|CUTFLAG_START2|CUTFLAG_END2)
 
-// Calculate cut between the points given by the two indices. pCut1
-// and pCut2 will contain the cut coordinate on each edge in ]0.0, 1.0]
-// (if given) and the return value will contain a cut description.
-BASEGFX_DLLPUBLIC CutFlagValue findCut(
-const B2DPolygon& rCandidate,
-sal_uInt32 nIndex1, sal_uInt32 nIndex2,
-CutFlagValue aCutFlags = CUTFLAG_DEFAULT,
-double* pCut1 = 0L, double* pCut2 = 0L);
-
-// This version is working with two indexed edges from different
-// polygons.
-BASEGFX_DLLPUBLIC CutFlagValue findCut(
-const B2DPolygon& rCandidate1, sal_uInt32 nIndex1,
-const B2DPolygon& rCandidate2, sal_uInt32 nIndex2,
-CutFlagValue aCutFlags = CUTFLAG_DEFAULT,
-double* pCut1 = 0L, double* pCut2 = 0L);
-
 // This version works with two points and vectors to define the
 // edges for the cut test.
 BASEGFX_DLLPUBLIC CutFlagValue findCut(
@@ -245,17 +228,6 @@ namespace basegfx
 @param rRect
 The rectangle which describes the polygon size
 
-@param fRadius
-Radius of the edge rounding, relative to the rectangle size. 0.0 
means no
-rounding, 1.0 will lead to an ellipse
- */
-BASEGFX_DLLPUBLIC B2DPolygon createPolygonFromRect( const 
B2DRectangle& rRect, double fRadius );
-
-/** Create a polygon from a rectangle.
-
-@param rRect
-The rectangle which describes the polygon size
-
 @param fRadiusX
 @param fRadiusY
 Radius of the edge rounding, relative to the rectangle size. 0.0 
means no
@@ -340,11 +312,6 @@ namespace basegfx
 // matrix and the resulting x,y is used to form the new polygon.
 BASEGFX_DLLPUBLIC B2DPolygon createB2DPolygonFromB3DPolygon(const 
B3DPolygon& rCandidate, const B3DHomMatrix& rMat);
 
-// create simplified version of the original polygon by
-// replacing segments with spikes/loops and self intersections
-// by several trivial sub-segments
-BASEGFX_DLLPUBLIC B2DPolygon createSimplifiedPolygon(const 
B2DPolygon&);
-
 // calculate the smallest distance to given edge and return. The 
relative position on the edge is returned in Cut.
 // That position is in the range [0.0 .. 1.0] and the returned 
distance is adapted accordingly to the start or end
 // point of the edge
@@ -422,8 +389,6 @@ namespace basegfx
 // organisation, e.g. same amount of points
 BASEGFX_DLLPUBLIC B2DPolygon interpolate(const B2DPolygon& rOld1, 
const B2DPolygon& rOld2, doub

[Libreoffice-commits] .: basegfx/inc basegfx/source

2012-02-16 Thread Radek Doulík
 basegfx/inc/basegfx/polygon/b3dpolygontools.hxx |   26 
 basegfx/source/polygon/b3dpolygontools.cxx  |  146 
 2 files changed, 1 insertion(+), 171 deletions(-)

New commits:
commit 0aaecbac864b0c0e3ddb72355e416db0b4f72a77
Author: Björgvin Ragnarsson 
Date:   Wed Feb 15 01:04:12 2012 +

Removed unused code.

diff --git a/basegfx/inc/basegfx/polygon/b3dpolygontools.hxx 
b/basegfx/inc/basegfx/polygon/b3dpolygontools.hxx
index 2cd8ec9..defaae8 100644
--- a/basegfx/inc/basegfx/polygon/b3dpolygontools.hxx
+++ b/basegfx/inc/basegfx/polygon/b3dpolygontools.hxx
@@ -59,7 +59,6 @@ namespace basegfx
 
 // Get successor and predecessor indices. Returning the same index 
means there
 // is none. Same for successor.
-BASEGFX_DLLPUBLIC sal_uInt32 getIndexOfPredecessor(sal_uInt32 nIndex, 
const B3DPolygon& rCandidate);
 BASEGFX_DLLPUBLIC sal_uInt32 getIndexOfSuccessor(sal_uInt32 nIndex, 
const B3DPolygon& rCandidate);
 
 // Get orientation of Polygon
@@ -71,15 +70,9 @@ namespace basegfx
 // get normal vector of polygon
 BASEGFX_DLLPUBLIC B3DVector getNormal(const B3DPolygon& rCandidate);
 
-// get normal vector of positive oriented polygon
-BASEGFX_DLLPUBLIC B3DVector getPositiveOrientedNormal(const 
B3DPolygon& rCandidate);
-
 // get signed area of polygon
 BASEGFX_DLLPUBLIC double getSignedArea(const B3DPolygon& rCandidate);
 
-// get area of polygon
-BASEGFX_DLLPUBLIC double getArea(const B3DPolygon& rCandidate);
-
 // get signed area of polygon
 BASEGFX_DLLPUBLIC double getSignedArea(const B3DPolygon& rCandidate);
 
@@ -97,11 +90,6 @@ namespace basegfx
 // using getLength(...)
 BASEGFX_DLLPUBLIC B3DPoint getPositionAbsolute(const B3DPolygon& 
rCandidate, double fDistance, double fLength = 0.0);
 
-// get position on polygon for relative given distance in range [0.0 
.. 1.0]. If
-// length is given, it is assumed the correct polygon length, if 0.0 
it is calculated
-// using getLength(...)
-BASEGFX_DLLPUBLIC B3DPoint getPositionRelative(const B3DPolygon& 
rCandidate, double fDistance, double fLength = 0.0);
-
 /** Apply given LineDashing to given polygon
 
 For a description see applyLineDashing in b2dpolygontoos.hxx
@@ -143,15 +131,8 @@ namespace basegfx
 // fDistance, and the sphere around both points with radius fDistance.
 BASEGFX_DLLPUBLIC bool isInEpsilonRange(const B3DPoint& rEdgeStart, 
const B3DPoint& rEdgeEnd, const B3DPoint& rTestPosition, double fDistance);
 
-// test if point is inside epsilon-range around the given Polygon. Can 
be used
-// for HitTesting. The epsilon-range is defined to be the cylinder 
centered to
-// the given edge, using radius fDistance, and the sphere around both 
points with radius fDistance.
-BASEGFX_DLLPUBLIC bool isInEpsilonRange(const B3DPolygon& rCandidate, 
const B3DPoint& rTestPosition, double fDistance);
-
-// isInside tests for B3DPoint and other B3DPolygon. On border is not 
inside as long as
-// not true is given in bWithBorder flag.
+// isInside tests for B3DPoint. On border is not inside as long as not 
true is given in bWithBorder flag.
 BASEGFX_DLLPUBLIC bool isInside(const B3DPolygon& rCandidate, const 
B3DPoint& rPoint, bool bWithBorder = false);
-BASEGFX_DLLPUBLIC bool isInside(const B3DPolygon& rCandidate, const 
B3DPolygon& rPolygon, bool bWithBorder = false);
 
 // calculates if given point is on given line, taking care of the 
numerical epsilon
 BASEGFX_DLLPUBLIC bool isPointOnLine(const B3DPoint& rStart, const 
B3DPoint& rEnd, const B3DPoint& rCandidate, bool bWithPoints = false);
@@ -164,14 +145,9 @@ namespace basegfx
 // and a line given by start and end point
 BASEGFX_DLLPUBLIC bool getCutBetweenLineAndPlane(const B3DVector& 
rPlaneNormal, const B3DPoint& rPlanePoint, const B3DPoint& rEdgeStart, const 
B3DPoint& rEdgeEnd, double& fCut);
 
-// helper to get a fCut position between a 3d Polygon
-// and a line given by start and end point
-BASEGFX_DLLPUBLIC bool getCutBetweenLineAndPolygon(const B3DPolygon& 
rCandidate, const B3DPoint& rEdgeStart, const B3DPoint& rEdgeEnd, double& fCut);
-
 //
 // comparators with tolerance for 3D Polygons
 BASEGFX_DLLPUBLIC bool equal(const B3DPolygon& rCandidateA, const 
B3DPolygon& rCandidateB, const double& rfSmallValue);
-BASEGFX_DLLPUBLIC bool equal(const B3DPolygon& rCandidateA, const 
B3DPolygon& rCandidateB);
 
 /** snap some polygon coordinates to discrete coordinates
 
diff --git a/basegfx/source/polygon/b3dpolygontools.cxx 
b/basegfx/source/polygon/b3dpolygontools.cxx
index fda58fb..b31712a 100644
--- a/basegfx/source/polygon/b3dpolygontools.

[Libreoffice-commits] .: basegfx/inc basegfx/source

2012-02-08 Thread Caolán McNamara
 basegfx/inc/basegfx/tools/unopolypolygon.hxx |   15 +--
 basegfx/source/tools/unopolypolygon.cxx  |5 -
 2 files changed, 9 insertions(+), 11 deletions(-)

New commits:
commit fb9908eece3076ad88c160654450d3069d28c0d8
Author: Caolán McNamara 
Date:   Wed Feb 8 16:48:59 2012 +

use boost::noncopyable

diff --git a/basegfx/inc/basegfx/tools/unopolypolygon.hxx 
b/basegfx/inc/basegfx/tools/unopolypolygon.hxx
index ca04b7a..9f41983 100644
--- a/basegfx/inc/basegfx/tools/unopolypolygon.hxx
+++ b/basegfx/inc/basegfx/tools/unopolypolygon.hxx
@@ -37,6 +37,7 @@
 #include 
 #include 
 #include 
+#include 
 
 
 namespace basegfx
@@ -48,8 +49,10 @@ namespace unotools
   ::com::sun::star::rendering::XBezierPolyPolygon2D,
   ::com::sun::star::lang::XServiceInfo > UnoPolyPolygonBase;
 
-class BASEGFX_DLLPUBLIC UnoPolyPolygon : private cppu::BaseMutex,
-   public UnoPolyPolygonBase
+class BASEGFX_DLLPUBLIC UnoPolyPolygon
+: private cppu::BaseMutex
+, private boost::noncopyable
+, public UnoPolyPolygonBase
 {
 public:
 explicit UnoPolyPolygon( const B2DPolyPolygon& );
@@ -96,15 +99,15 @@ namespace unotools
  sal_Int32 nNumberOfPoints ) const;
 
 /// Get cow copy of internal polygon. not thread-safe outside this 
object.
-B2DPolyPolygon getPolyPolygonUnsafe() const;
+B2DPolyPolygon getPolyPolygonUnsafe() const
+{
+return maPolyPoly;
+}
 
 /// Called whenever internal polypolygon gets modified
 virtual void modifying() const {}
 
 private:
-UnoPolyPolygon( const UnoPolyPolygon& );
-UnoPolyPolygon& operator=( const UnoPolyPolygon& );
-
 B2DPolyPolygonmaPolyPoly;
 ::com::sun::star::rendering::FillRule meFillRule;
 };
diff --git a/basegfx/source/tools/unopolypolygon.cxx 
b/basegfx/source/tools/unopolypolygon.cxx
index 80203c2..2ffaabd 100644
--- a/basegfx/source/tools/unopolypolygon.cxx
+++ b/basegfx/source/tools/unopolypolygon.cxx
@@ -445,11 +445,6 @@ namespace unotools
 return aSubsetPoly;
 }
 
-B2DPolyPolygon UnoPolyPolygon::getPolyPolygonUnsafe() const
-{
-return maPolyPoly;
-}
-
 #define IMPLEMENTATION_NAME "gfx::internal::UnoPolyPolygon"
 #define SERVICE_NAME "com.sun.star.rendering.PolyPolygon2D"
 ::rtl::OUString SAL_CALL UnoPolyPolygon::getImplementationName() throw( 
uno::RuntimeException )
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: basegfx/inc basegfx/source unusedcode.easy

2012-02-01 Thread Caolán McNamara
 basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx |3 -
 basegfx/inc/basegfx/point/b2ipoint.hxx   |5 --
 basegfx/inc/basegfx/point/b3ipoint.hxx   |5 --
 basegfx/inc/basegfx/polygon/b2dpolygon.hxx   |   20 
 basegfx/inc/basegfx/polygon/b3dpolygon.hxx   |3 -
 basegfx/inc/basegfx/polygon/b3dpolypolygon.hxx   |3 -
 basegfx/inc/basegfx/range/b1drange.hxx   |8 ---
 basegfx/inc/basegfx/range/b2drange.hxx   |6 --
 basegfx/inc/basegfx/range/b3drange.hxx   |8 ---
 basegfx/inc/basegfx/tools/canvastools.hxx|   10 
 basegfx/inc/basegfx/tools/unopolypolygon.hxx |3 -
 basegfx/inc/basegfx/tuple/b2i64tuple.hxx |2 
 basegfx/inc/basegfx/tuple/b2ituple.hxx   |2 
 basegfx/inc/basegfx/tuple/b3dtuple.hxx   |7 --
 basegfx/inc/basegfx/tuple/b3i64tuple.hxx |8 ---
 basegfx/inc/basegfx/tuple/b3ituple.hxx   |8 ---
 basegfx/inc/basegfx/vector/b2dvector.hxx |8 ---
 basegfx/inc/basegfx/vector/b2ivector.hxx |   14 -
 basegfx/inc/basegfx/vector/b3ivector.hxx |5 --
 basegfx/source/matrix/b2dhommatrixtools.cxx  |   26 --
 basegfx/source/polygon/b2dpolygon.cxx|   24 -
 basegfx/source/polygon/b3dpolygon.cxx|5 --
 basegfx/source/polygon/b3dpolypolygon.cxx|   24 -
 basegfx/source/range/b1drange.cxx|   18 ---
 basegfx/source/range/b2drange.cxx|7 --
 basegfx/source/range/b3drange.cxx|   29 ---
 basegfx/source/tools/canvastools.cxx |   56 ---
 basegfx/source/tools/unopolypolygon.cxx  |5 --
 basegfx/source/tuple/b2i64tuple.cxx  |5 --
 basegfx/source/tuple/b2ituple.cxx|5 --
 basegfx/source/tuple/b3dtuple.cxx|6 --
 basegfx/source/tuple/b3i64tuple.cxx  |4 -
 basegfx/source/tuple/b3ituple.cxx|4 -
 basegfx/source/vector/b2dvector.cxx  |8 ---
 basegfx/source/vector/b2ivector.cxx  |6 --
 unusedcode.easy  |   25 --
 36 files changed, 385 deletions(-)

New commits:
commit b3c3e116ff0eb9b550b73d3901395c042e31d192
Author: Alexander Bergmann 
Date:   Wed Feb 1 16:34:15 2012 +

unusedcode.easy: Removed unused code

diff --git a/basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx 
b/basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx
index 3d0d22d..e53a598 100644
--- a/basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx
+++ b/basegfx/inc/basegfx/matrix/b2dhommatrixtools.hxx
@@ -226,9 +226,6 @@ namespace basegfx
 };
 } // end of namespace tools
 
-/// Returns a string with svg's "matrix(m00,m10,m01,m11,m02,m12)" 
representation
-::rtl::OUString exportToSvg( const B2DHomMatrix& rMatrix );
-
 } // end of namespace basegfx
 
 ///
diff --git a/basegfx/inc/basegfx/point/b2ipoint.hxx 
b/basegfx/inc/basegfx/point/b2ipoint.hxx
index b74b559..c356e1c 100644
--- a/basegfx/inc/basegfx/point/b2ipoint.hxx
+++ b/basegfx/inc/basegfx/point/b2ipoint.hxx
@@ -118,11 +118,6 @@ namespace basegfx
 contrast to B2DVector, applied.
 */
 B2IPoint& operator*=( const ::basegfx::B2DHomMatrix& rMat );
-
-static const B2IPoint& getEmptyPoint()
-{
-return (const B2IPoint&) ::basegfx::B2ITuple::getEmptyTuple();
-}
 };
 } // end of namespace basegfx
 
diff --git a/basegfx/inc/basegfx/point/b3ipoint.hxx 
b/basegfx/inc/basegfx/point/b3ipoint.hxx
index 334ff33..f773994 100644
--- a/basegfx/inc/basegfx/point/b3ipoint.hxx
+++ b/basegfx/inc/basegfx/point/b3ipoint.hxx
@@ -130,11 +130,6 @@ namespace basegfx
 contrast to B3DVector, applied.
 */
 B3IPoint& operator*=( const ::basegfx::B3DHomMatrix& rMat );
-
-static const B3IPoint& getEmptyPoint()
-{
-return (const B3IPoint&) ::basegfx::B3ITuple::getEmptyTuple();
-}
 };
 } // end of namespace basegfx
 
diff --git a/basegfx/inc/basegfx/polygon/b2dpolygon.hxx 
b/basegfx/inc/basegfx/polygon/b2dpolygon.hxx
index 707590d..3443d72 100644
--- a/basegfx/inc/basegfx/polygon/b2dpolygon.hxx
+++ b/basegfx/inc/basegfx/polygon/b2dpolygon.hxx
@@ -187,26 +187,6 @@ namespace basegfx
 */
 B2DRange getB2DRange() const;
 
-/** insert other 2D polygons
-
-The default (with nIndex2 == 0 && nCount == 0) inserts the whole
-rPoly at position nIndex
-
-@param nIndex
-Target index for points to be inserted
-
-@param rPoly
-The source for new points
-
-@param nIndex2
-The index to the first source point into rPoly
-
-@param nCount
-How many points to add from rPoly to this polygon. Null
-

[Libreoffice-commits] .: basegfx/inc basegfx/source unusedcode.easy

2012-01-28 Thread Michael Meeks
 basegfx/inc/basegfx/point/b2dhompoint.hxx |  239 ---
 basegfx/source/point/b2dhompoint.cxx  |  260 --
 unusedcode.easy   |9 -
 3 files changed, 508 deletions(-)

New commits:
commit aedea4de6cc93d1dc36e06e08b0bdf18b6700e1b
Author: Alexander Bergmann 
Date:   Sat Jan 28 10:06:32 2012 +0100

unusedcode.easy: Removed unused code (basegfx::B2DHomPoint)

diff --git a/basegfx/inc/basegfx/point/b2dhompoint.hxx 
b/basegfx/inc/basegfx/point/b2dhompoint.hxx
deleted file mode 100644
index 7f11827..000
--- a/basegfx/inc/basegfx/point/b2dhompoint.hxx
+++ /dev/null
@@ -1,239 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org.  If not, see
- * 
- * for a copy of the LGPLv3 License.
- *
- /
-
-#ifndef _BGFX_POINT_B2DHOMPOINT_HXX
-#define _BGFX_POINT_B2DHOMPOINT_HXX
-
-#include 
-#include 
-
-namespace basegfx
-{
-/** Basic homogen Point class with two double values and one homogen factor
-
-This class provides access to homogen coordinates in 2D.
-For this purpose all the operators which need to do specific
-action due to their homogenity are implemented here.
-The only caveat are member methods which are declared as const
-but do change the content. These are documented for that reason.
-The class is designed to provide homogenous coordinates without
-direct access to the homogen part (mfW). This is also the reason
-for leaving out the [] operators which return references to members.
-
-@see B2DTuple
-*/
-class BASEGFX_DLLPUBLIC B2DHomPoint
-{
-protected:
-/// This member contains the coordinate part of the point
-::basegfx::B2DTuple maTuple;
-
-/// This Member holds the homogenous part of the point
-double  mfW;
-
-/** Test if this homogen point does have a homogenous part
-
-@return Returns true if this point has no homogenous part
-*/
-bool implIsHomogenized() const;
-
-/** Remove homogenous part of this Point
-
-This method does necessary calculations to remove
-the evtl. homogenous part of this Point. This may
-change all members.
-*/
-void implHomogenize();
-
-/** Test and on demand remove homogenous part
-
-This method tests if this Point does have a homogenous part
-and then evtl. takes actions to remove that part.
-
-@attention Even when this method is const it may change all
-members of this instance. This is due to the fact that changing
-the homogenous part of a homogenous point does from a mathematical
-point of view not change the point at all.
-*/
-void implTestAndHomogenize() const;
-
-public:
-/** Create a homogen point
-
-The point is initialized to (0.0, 0.0)
-*/
-B2DHomPoint()
-:   maTuple(),
-mfW(1.0)
-{}
-
-/** Create a homogen point
-
-@param fX
-This parameter is used to initialize the X-coordinate
-of the Point. The homogenous part is initialized to 1.0.
-
-@param fY
-This parameter is used to initialize the Y-coordinate
-of the Point. The homogenous part is initialized to 1.0.
-*/
-B2DHomPoint(double fX, double fY)
-:   maTuple(fX, fY),
-mfW(1.0)
-{}
-
-/** Create a copy of a 2D Point
-
-@param rVec
-The 2D point which will be copied. The homogenous part
-is initialized to 1.0.
-*/
-B2DHomPoint(const B2DPoint& rVec)
-:   maTuple(rVec),
-mfW(1.0)
-{

[Libreoffice-commits] .: basegfx/inc basegfx/source

2012-01-27 Thread Michael Meeks
 basegfx/inc/basegfx/tuple/b2ituple.hxx   |7 ---
 basegfx/inc/basegfx/vector/b2ivector.hxx |   65 --
 basegfx/source/tuple/b2ituple.cxx|   48 --
 basegfx/source/vector/b2ivector.cxx  |   67 ---
 4 files changed, 187 deletions(-)

New commits:
commit 6e4b79042bbb6695eb88ee5d4a8f661932778a50
Author: Alexander Bergmann 
Date:   Sat Jan 28 00:22:05 2012 +

Actually apply substance of previous unused code removal

diff --git a/basegfx/inc/basegfx/tuple/b2ituple.hxx 
b/basegfx/inc/basegfx/tuple/b2ituple.hxx
index f376bb7..4072073 100644
--- a/basegfx/inc/basegfx/tuple/b2ituple.hxx
+++ b/basegfx/inc/basegfx/tuple/b2ituple.hxx
@@ -204,13 +204,6 @@ namespace basegfx
 //
 class B2DTuple;
 
-BASEGFX_DLLPUBLIC B2ITuple minimum(const B2ITuple& rTupA, const B2ITuple& 
rTupB);
-BASEGFX_DLLPUBLIC B2ITuple maximum(const B2ITuple& rTupA, const B2ITuple& 
rTupB);
-BASEGFX_DLLPUBLIC B2ITuple absolute(const B2ITuple& rTup);
-BASEGFX_DLLPUBLIC B2DTuple interpolate(const B2ITuple& rOld1, const 
B2ITuple& rOld2, double t);
-BASEGFX_DLLPUBLIC B2DTuple average(const B2ITuple& rOld1, const B2ITuple& 
rOld2);
-BASEGFX_DLLPUBLIC B2DTuple average(const B2ITuple& rOld1, const B2ITuple& 
rOld2, const B2ITuple& rOld3);
-
 BASEGFX_DLLPUBLIC B2ITuple operator+(const B2ITuple& rTupA, const 
B2ITuple& rTupB);
 BASEGFX_DLLPUBLIC B2ITuple operator-(const B2ITuple& rTupA, const 
B2ITuple& rTupB);
 BASEGFX_DLLPUBLIC B2ITuple operator/(const B2ITuple& rTupA, const 
B2ITuple& rTupB);
diff --git a/basegfx/inc/basegfx/vector/b2ivector.hxx 
b/basegfx/inc/basegfx/vector/b2ivector.hxx
index 1e3be78..2fcbc54 100644
--- a/basegfx/inc/basegfx/vector/b2ivector.hxx
+++ b/basegfx/inc/basegfx/vector/b2ivector.hxx
@@ -113,12 +113,6 @@ namespace basegfx
 */
 B2IVector& operator=( const ::basegfx::B2ITuple& rVec );
 
-/** Calculate the length of this 2D Vector
-
-@return The Length of the 2D Vector
-*/
-double getLength() const;
-
 /** Set the length of this 2D Vector
 
 @param fLen
@@ -136,69 +130,17 @@ namespace basegfx
 */
 double scalar( const B2IVector& rVec ) const;
 
-/** Calculate the length of the cross product with another 2D Vector
-
-In 2D, returning an actual vector does not make much
-sense here. The magnitude, although, can be readily
-used for tasks such as angle calculations, since for
-the returned value, the following equation holds:
-retVal = getLength(this)*getLength(rVec)*sin(theta),
-with theta being the angle between the two vectors.
-
-@param rVec
-The second 2D Vector
-
-@return
-The length of the cross product of the two involved 2D Vectors
-*/
-double cross( const B2IVector& rVec ) const;
-
-/** Calculate the Angle with another 2D Vector
-
-@param rVec
-The second 2D Vector
-
-@return
-The Angle value of the two involved 2D Vectors in -pi/2 < return < 
pi/2
-*/
-double angle( const B2IVector& rVec ) const;
-
 /** Transform vector by given transformation matrix.
 
 Since this is a vector, translational components of the
 matrix are disregarded.
 */
 B2IVector& operator*=( const B2DHomMatrix& rMat );
-
-static const B2IVector& getEmptyVector();
 };
 
 // external operators
 //
 
-/** Calculate the orientation to another 2D Vector
-
-@param rVecA
-The first 2D Vector
-
-@param rVecB
-The second 2D Vector
-
-@return
-The mathematical Orientation of the two involved 2D Vectors
-*/
-BASEGFX_DLLPUBLIC B2VectorOrientation getOrientation( const B2IVector& 
rVecA, const B2IVector& rVecB );
-
-/** Calculate a perpendicular 2D Vector to the given one
-
-@param rVec
-The source 2D Vector
-
-@return
-A 2D Vector perpendicular to the one given in parameter rVec
-*/
-BASEGFX_DLLPUBLIC B2IVector getPerpendicular( const B2IVector& rVec );
-
 /** Test two vectors which need not to be normalized for parallelism
 
 @param rVecA
@@ -220,13 +162,6 @@ namespace basegfx
 */
 BASEGFX_DLLPUBLIC B2IVector operator*( const B2DHomMatrix& rMat, const 
B2IVector& rVec );
 
-/** Test continuity between given vectors.
-
-The two given vectors are assumed to describe control points on a
-common point. Calculate if there is a continuity between them.
-*/
-BASEGFX_DLLPUBLIC B2VectorContinuity getContinuity( const B2IVector& 
rBackVector, const B2IVector& rForwardVector );
-
 

[Libreoffice-commits] .: basegfx/inc basegfx/source unusedcode.easy

2012-01-24 Thread Muthu Subramanian
 basegfx/inc/basegfx/polygon/b2dpolygonclipper.hxx |7 -
 basegfx/inc/basegfx/polygon/b2dpolygoncutandtouch.hxx |   10 -
 basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx |   14 --
 basegfx/source/polygon/b2dpolygonclipper.cxx  |   66 --
 basegfx/source/polygon/b2dpolygoncutandtouch.cxx  |  112 --
 basegfx/source/polygon/b3dpolygonclipper.cxx  |  102 
 unusedcode.easy   |   10 -
 7 files changed, 321 deletions(-)

New commits:
commit 92a87649a79de6013703d2344365ef86fc9788bd
Author: Alexander Bergmann 
Date:   Wed Jan 25 12:01:28 2012 +0530

Removing unused code (basegfx).

diff --git a/basegfx/inc/basegfx/polygon/b2dpolygonclipper.hxx 
b/basegfx/inc/basegfx/polygon/b2dpolygonclipper.hxx
index 172996a..2556b34 100644
--- a/basegfx/inc/basegfx/polygon/b2dpolygonclipper.hxx
+++ b/basegfx/inc/basegfx/polygon/b2dpolygonclipper.hxx
@@ -57,13 +57,6 @@ namespace basegfx
 BASEGFX_DLLPUBLIC B2DPolyPolygon clipPolyPolygonOnRange(const 
B2DPolyPolygon& rCandidate, const B2DRange& rRange, bool bInside, bool bStroke);
 BASEGFX_DLLPUBLIC B2DPolyPolygon clipPolygonOnRange(const B2DPolygon& 
rCandidate, const B2DRange& rRange, bool bInside, bool bStroke);
 
-// Clip given PolyPolygon against the endless edge (ray) defined by 
the given two points. bAbove defines on which side
-// of the edge the result will be together with the definition of the 
edge. If the edge is seen as a vector
-// from A to B and bAbove is true, the result will contain the 
geometry left of the vector.
-// The switch bStroke decides if the polygon is interpreted as area 
(false) or strokes (true).
-BASEGFX_DLLPUBLIC B2DPolyPolygon clipPolyPolygonOnEdge(const 
B2DPolyPolygon& rCandidate, const B2DPoint& rPointA, const B2DPoint& rPointB, 
bool bAbove, bool bStroke);
-BASEGFX_DLLPUBLIC B2DPolyPolygon clipPolygonOnEdge(const B2DPolygon& 
rCandidate, const B2DPoint& rPointA, const B2DPoint& rPointB, bool bAbove, bool 
bStroke);
-
 // Clip given PolyPolygon against given clipping polygon.
 // The switch bStroke decides if the polygon is interpreted as area 
(false) or strokes (true).
 // With stroke polygons, You get all line snippets inside rCip.
diff --git a/basegfx/inc/basegfx/polygon/b2dpolygoncutandtouch.hxx 
b/basegfx/inc/basegfx/polygon/b2dpolygoncutandtouch.hxx
index 0c6296d..8997c54 100644
--- a/basegfx/inc/basegfx/polygon/b2dpolygoncutandtouch.hxx
+++ b/basegfx/inc/basegfx/polygon/b2dpolygoncutandtouch.hxx
@@ -53,28 +53,18 @@ namespace basegfx
 // not change or add points to rMask.
 BASEGFX_DLLPUBLIC B2DPolygon addPointsAtCutsAndTouches(const 
B2DPolyPolygon& rMask, const B2DPolygon& rCandidate);
 
-// look for intersections of rCandidate with all polygons from rMask 
and add extra points there. Do
-// not change or add points to rMask.
-BASEGFX_DLLPUBLIC B2DPolyPolygon addPointsAtCutsAndTouches(const 
B2DPolyPolygon& rMask, const B2DPolyPolygon& rCandidate);
-
 // look for intersections of rCandidate with the edge from rStart to 
rEnd and add extra points there.
 // Points are only added in the range of the edge, not on the endless 
vector.
 BASEGFX_DLLPUBLIC B2DPolygon addPointsAtCuts(const B2DPolygon& 
rCandidate, const B2DPoint& rStart, const B2DPoint& rEnd);
-BASEGFX_DLLPUBLIC B2DPolyPolygon addPointsAtCuts(const B2DPolyPolygon& 
rCandidate, const B2DPoint& rStart, const B2DPoint& rEnd);
 
 // look for intersections of rCandidate with the mask Polygon and add 
extra points there.
 // The mask polygon is assumed to be closed, even when it's not 
explicitly.
 BASEGFX_DLLPUBLIC B2DPolygon addPointsAtCuts(const B2DPolygon& 
rCandidate, const B2DPolyPolygon& rMask);
-BASEGFX_DLLPUBLIC B2DPolyPolygon addPointsAtCuts(const B2DPolyPolygon& 
rCandidate, const B2DPolyPolygon& rMask);
 
 // look for self-intersections in given polygon and add extra points 
there. Result will have no
 // intersections on an edge
 BASEGFX_DLLPUBLIC B2DPolygon addPointsAtCuts(const B2DPolygon& 
rCandidate);
 
-// add points at all self-intersections of single polygons (depends on 
bSelfIntersections)
-// and at polygon-polygon intersections
-BASEGFX_DLLPUBLIC B2DPolyPolygon addPointsAtCuts(const B2DPolyPolygon& 
rCandidate, bool bSelfIntersections = true);
-
 } // end of namespace tools
 } // end of namespace basegfx
 
diff --git a/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx 
b/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
index 0c66967..f34effe 100644
--- a/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
+++ b/basegfx/inc/basegfx/polygon/b3dpolygonclipper.hxx
@@ -62,26 +62,12 @@ namespace basegfx
 // version for Polygons
 BASEGFX_DLLPUBLIC B3DPolyPolygon clipPolygonOnOrthogonalPlane(const 
B3D

[Libreoffice-commits] .: basegfx/inc basegfx/Library_basegfx.mk basegfx/Package_inc.mk basegfx/source basegfx/StaticLibrary_basegfx_s.mk basegfx/test

2011-12-19 Thread August Sodora
 basegfx/Library_basegfx.mk |1 
 basegfx/Package_inc.mk |1 
 basegfx/StaticLibrary_basegfx_s.mk |1 
 basegfx/inc/basegfx/tools/debugplotter.hxx |  111 ---
 basegfx/source/tools/debugplotter.cxx  |  416 -
 basegfx/test/basegfx2d.cxx |  321 --
 6 files changed, 851 deletions(-)

New commits:
commit cdb2736f5bbc15c0b485cde667d889ed17c699c6
Author: August Sodora 
Date:   Mon Dec 19 15:33:43 2011 -0500

Remove DebugPlotter

diff --git a/basegfx/Library_basegfx.mk b/basegfx/Library_basegfx.mk
index 5e4885a..af62918 100644
--- a/basegfx/Library_basegfx.mk
+++ b/basegfx/Library_basegfx.mk
@@ -66,7 +66,6 @@ $(eval $(call gb_Library_add_linked_libs,basegfx,\
 $(eval $(call gb_Library_add_exception_objects,basegfx,\
basegfx/source/tools/b2dclipstate \
basegfx/source/tools/canvastools \
-   basegfx/source/tools/debugplotter \
basegfx/source/tools/gradienttools \
basegfx/source/tools/keystoplerp \
basegfx/source/tools/liangbarsky \
diff --git a/basegfx/Package_inc.mk b/basegfx/Package_inc.mk
index 158948e..6d1a4e7 100644
--- a/basegfx/Package_inc.mk
+++ b/basegfx/Package_inc.mk
@@ -30,7 +30,6 @@ $(eval $(call 
gb_Package_Package,basegfx_inc,$(SRCDIR)/basegfx/inc))
 
 $(eval $(call 
gb_Package_add_file,basegfx_inc,inc/basegfx/tools/lerp.hxx,basegfx/tools/lerp.hxx))
 $(eval $(call 
gb_Package_add_file,basegfx_inc,inc/basegfx/tools/keystoplerp.hxx,basegfx/tools/keystoplerp.hxx))
-$(eval $(call 
gb_Package_add_file,basegfx_inc,inc/basegfx/tools/debugplotter.hxx,basegfx/tools/debugplotter.hxx))
 $(eval $(call 
gb_Package_add_file,basegfx_inc,inc/basegfx/tools/canvastools.hxx,basegfx/tools/canvastools.hxx))
 $(eval $(call 
gb_Package_add_file,basegfx_inc,inc/basegfx/tools/rectcliptools.hxx,basegfx/tools/rectcliptools.hxx))
 $(eval $(call 
gb_Package_add_file,basegfx_inc,inc/basegfx/tools/b2dclipstate.hxx,basegfx/tools/b2dclipstate.hxx))
diff --git a/basegfx/StaticLibrary_basegfx_s.mk 
b/basegfx/StaticLibrary_basegfx_s.mk
index 9b113bd..891e232 100644
--- a/basegfx/StaticLibrary_basegfx_s.mk
+++ b/basegfx/StaticLibrary_basegfx_s.mk
@@ -71,7 +71,6 @@ $(WORKDIR)/CustomTarget/basegfx/source/%.cxx : 
$(SRCDIR)/basegfx/source/%.cxx
 # copied sources are generated cxx sources
 $(eval $(call gb_StaticLibrary_add_generated_exception_objects,basegfx_s,\
CustomTarget/basegfx/source/tools/liangbarsky \
-   CustomTarget/basegfx/source/tools/debugplotter \
CustomTarget/basegfx/source/tools/canvastools \
CustomTarget/basegfx/source/tools/gradienttools \
CustomTarget/basegfx/source/tools/keystoplerp \
diff --git a/basegfx/inc/basegfx/tools/debugplotter.hxx 
b/basegfx/inc/basegfx/tools/debugplotter.hxx
deleted file mode 100644
index a588d0f..000
--- a/basegfx/inc/basegfx/tools/debugplotter.hxx
+++ /dev/null
@@ -1,111 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org.  If not, see
- * 
- * for a copy of the LGPLv3 License.
- *
- /
-
-#ifndef _BGFX_TOOLS_DEBUGPLOTTER_HXX
-#define _BGFX_TOOLS_DEBUGPLOTTER_HXX
-
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include  // for noncopyable
-#include 
-#include 
-#include 
-#include 
-
-
-namespace basegfx
-{
-class B2DCubicBezier;
-
-/** Generates debug output for various basegfx data types.
-
-Use this class to produce debug (trace) output for various
-basegfx geometry data types. By default, this class outputs
-via OSL_TRACE (i.e. to stderr), and uses the gnuplot output
-format.
-
-To be able to generate one coherent block of output, this
-class delays actual writing to its destructor
- */
-class BASEGFX_DLLPUBLIC DebugPlotter : private ::boost::noncopyable
-{
-public:
-  

[Libreoffice-commits] .: basegfx/inc

2011-11-07 Thread Fridrich Strba
 basegfx/inc/basegfx/raster/bpixelraster.hxx|2 +-
 basegfx/inc/basegfx/raster/bzpixelraster.hxx   |2 +-
 basegfx/inc/basegfx/raster/rasterconvert3d.hxx |   10 +-
 3 files changed, 7 insertions(+), 7 deletions(-)

New commits:
commit f8508036d1f28765ad43055d9ba99219e1523087
Author: Fridrich Å trba 
Date:   Mon Nov 7 11:24:19 2011 +0100

Fix linking on Windows

Don't declare dllexport classes that are purely inlined.
This will cause for the binary that links then to look for dll symbols,
which are naturlly not present.

diff --git a/basegfx/inc/basegfx/raster/bpixelraster.hxx 
b/basegfx/inc/basegfx/raster/bpixelraster.hxx
index 781bac1..6f33795 100644
--- a/basegfx/inc/basegfx/raster/bpixelraster.hxx
+++ b/basegfx/inc/basegfx/raster/bpixelraster.hxx
@@ -42,7 +42,7 @@
 
 namespace basegfx
 {
-class BASEGFX_DLLPUBLIC BPixelRaster
+class BPixelRaster
 {
 private:
 // do not allow copy constructor and assignment operator
diff --git a/basegfx/inc/basegfx/raster/bzpixelraster.hxx 
b/basegfx/inc/basegfx/raster/bzpixelraster.hxx
index fa7525e..2f161b6 100644
--- a/basegfx/inc/basegfx/raster/bzpixelraster.hxx
+++ b/basegfx/inc/basegfx/raster/bzpixelraster.hxx
@@ -40,7 +40,7 @@
 
 namespace basegfx
 {
-class BASEGFX_DLLPUBLIC BZPixelRaster : public BPixelRaster
+class BZPixelRaster : public BPixelRaster
 {
 protected:
 // additionally, host a ZBuffer
diff --git a/basegfx/inc/basegfx/raster/rasterconvert3d.hxx 
b/basegfx/inc/basegfx/raster/rasterconvert3d.hxx
index 32c82f6..6f1cb20 100644
--- a/basegfx/inc/basegfx/raster/rasterconvert3d.hxx
+++ b/basegfx/inc/basegfx/raster/rasterconvert3d.hxx
@@ -51,7 +51,7 @@ namespace basegfx
 
 namespace basegfx
 {
-class BASEGFX_DLLPUBLIC ip_single
+class ip_single
 {
 private:
 double  mfVal;
@@ -77,7 +77,7 @@ namespace basegfx
 
 namespace basegfx
 {
-class BASEGFX_DLLPUBLIC ip_double
+class ip_double
 {
 private:
 ip_single   maX;
@@ -103,7 +103,7 @@ namespace basegfx
 
 namespace basegfx
 {
-class BASEGFX_DLLPUBLIC ip_triple
+class ip_triple
 {
 private:
 ip_single   maX;
@@ -139,7 +139,7 @@ namespace basegfx
 {
 #define SCANLINE_EMPTY_INDEX (0x)
 
-class BASEGFX_DLLPUBLIC InterpolatorProvider3D
+class InterpolatorProvider3D
 {
 private:
 ::std::vector< ip_triple >  maColorInterpolators;
@@ -211,7 +211,7 @@ namespace basegfx
 
 namespace basegfx
 {
-class BASEGFX_DLLPUBLIC RasterConversionLineEntry3D
+class RasterConversionLineEntry3D
 {
 private:
 ip_single   maX;
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits