summaryrefslogtreecommitdiff
path: root/include/tools
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2016-12-05 12:47:37 +0200
committerAshod Nakashian <ashod.nakashian@collabora.co.uk>2017-12-18 01:07:40 -0500
commit448a931f776f2d4e4ca2e44c49f830653af7efbc (patch)
tree4ece62bffc3f83d6fb963ef75a1b45e224b440a4 /include/tools
parentdcbad5d45e9c658766f9b165020db8fb612d4f6e (diff)
convert PolyFlags to scoped enum
and remove the XPolyFlags enum, which has the same values and was being converted to PolyFlags anyhow Change-Id: Iaead84933c79a7603698a4e50257dd944df89c41 Reviewed-on: https://gerrit.libreoffice.org/31627 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit a08cb3b52ea4a071ce8eb5a1786ea45fd211ab78) (cherry picked from commit e13bb8d5290b27281d7742a9b7034929561d51aa)
Diffstat (limited to 'include/tools')
-rw-r--r--include/tools/poly.hxx14
1 files changed, 7 insertions, 7 deletions
diff --git a/include/tools/poly.hxx b/include/tools/poly.hxx
index eb962cbafb94..d35121bea67e 100644
--- a/include/tools/poly.hxx
+++ b/include/tools/poly.hxx
@@ -49,12 +49,12 @@ enum PolyStyle
POLY_CHORD = 3
};
-enum PolyFlags
+enum class PolyFlags : sal_uInt8
{
- POLY_NORMAL,
- POLY_SMOOTH,
- POLY_CONTROL,
- POLY_SYMMTR
+ Normal, // start-/endpoint of a curve or a line
+ Smooth, // smooth transition between curves
+ Control, // control handles of a Bezier curve
+ Symmetric // smooth and symmetrical transition between curves
};
class SvStream;
@@ -86,7 +86,7 @@ public:
Polygon();
Polygon( sal_uInt16 nSize );
Polygon( sal_uInt16 nPoints, const Point* pPtAry,
- const sal_uInt8* pFlagAry = nullptr );
+ const PolyFlags* pFlagAry = nullptr );
Polygon( const Rectangle& rRect );
Polygon( const Rectangle& rRect,
sal_uInt32 nHorzRound, sal_uInt32 nVertRound );
@@ -174,7 +174,7 @@ public:
void Write( SvStream& rOStream ) const;
const Point* GetConstPointAry() const;
- const sal_uInt8* GetConstFlagAry() const;
+ const PolyFlags* GetConstFlagAry() const;
// convert to ::basegfx::B2DPolygon and return
::basegfx::B2DPolygon getB2DPolygon() const;