summaryrefslogtreecommitdiff
path: root/tools/source/generic/poly.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'tools/source/generic/poly.cxx')
-rw-r--r--tools/source/generic/poly.cxx16
1 files changed, 8 insertions, 8 deletions
diff --git a/tools/source/generic/poly.cxx b/tools/source/generic/poly.cxx
index 244727169571..e5ed7f2762b2 100644
--- a/tools/source/generic/poly.cxx
+++ b/tools/source/generic/poly.cxx
@@ -416,10 +416,10 @@ Polygon::Polygon( const Point& rCenter, long nRadX, long nRadY, sal_uInt16 nPoin
// Compute default (depends on size)
if( !nPoints )
{
- nPoints = (sal_uInt16) ( F_PI * ( 1.5 * ( nRadX + nRadY ) -
- sqrt( (double) labs( nRadX * nRadY ) ) ) );
-
- nPoints = (sal_uInt16) MinMax( nPoints, 32, 256 );
+ nPoints = (sal_uInt16) MinMax(
+ ( F_PI * ( 1.5 * ( nRadX + nRadY ) -
+ sqrt( (double) labs( nRadX * nRadY ) ) ) ),
+ 32, 256 );
if( ( nRadX > 32 ) && ( nRadY > 32 ) && ( nRadX + nRadY ) < 8192 )
nPoints >>= 1;
@@ -471,10 +471,10 @@ Polygon::Polygon( const Rectangle& rBound, const Point& rStart, const Point& rEn
const long nRadY = aCenter.Y() - rBound.Top();
sal_uInt16 nPoints;
- nPoints = (sal_uInt16) ( F_PI * ( 1.5 * ( nRadX + nRadY ) -
- sqrt( (double) labs( nRadX * nRadY ) ) ) );
-
- nPoints = (sal_uInt16) MinMax( nPoints, 32, 256 );
+ nPoints = (sal_uInt16) MinMax(
+ ( F_PI * ( 1.5 * ( nRadX + nRadY ) -
+ sqrt( (double) labs( nRadX * nRadY ) ) ) ),
+ 32, 256 );
if( ( nRadX > 32 ) && ( nRadY > 32 ) && ( nRadX + nRadY ) < 8192 )
nPoints >>= 1;