summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-08-17 13:49:16 +0200
committerNoel Grandin <noel@peralex.com>2016-08-18 08:49:02 +0200
commit4a4c1bf4423a8b426c56c8d2b7013d6b5109309e (patch)
tree979f603a4f19373cb7e0abead4094c196010c927 /svx
parenta43de3d55bccfd8312dfcafbd387f3e8c7d1c633 (diff)
convert XFormTextStyle to scoped enum
Change-Id: I88facbbbe262d9e26d2b45703c4f05c71bf51479
Diffstat (limited to 'svx')
-rw-r--r--svx/source/dialog/fontwork.cxx20
-rw-r--r--svx/source/sdr/attribute/sdrformtextattribute.cxx2
-rw-r--r--svx/source/sdr/attribute/sdrtextattribute.cxx2
-rw-r--r--svx/source/svdraw/svdibrow.cxx2
-rw-r--r--svx/source/svdraw/svdotext.cxx2
-rw-r--r--svx/source/svdraw/svdotextpathdecomposition.cxx10
6 files changed, 19 insertions, 19 deletions
diff --git a/svx/source/dialog/fontwork.cxx b/svx/source/dialog/fontwork.cxx
index 3c20641fd531..df0d257faf03 100644
--- a/svx/source/dialog/fontwork.cxx
+++ b/svx/source/dialog/fontwork.cxx
@@ -346,16 +346,16 @@ void SvxFontWorkDialog::SetStyle_Impl(const XFormTextStyleItem* pItem)
switch ( pItem->GetValue() )
{
- case XFT_ROTATE : nId = nStyleRotateId; break;
- case XFT_UPRIGHT: nId = nStyleUprightId; break;
- case XFT_SLANTX : nId = nStyleSlantXId; break;
- case XFT_SLANTY : nId = nStyleSlantYId; break;
+ case XFormTextStyle::Rotate : nId = nStyleRotateId; break;
+ case XFormTextStyle::Upright: nId = nStyleUprightId; break;
+ case XFormTextStyle::SlantX : nId = nStyleSlantXId; break;
+ case XFormTextStyle::SlantY : nId = nStyleSlantYId; break;
default: ;//prevent warning
}
m_pTbxStyle->Enable();
// Make sure that there is always exactly one checked toolbox item.
- if ( pItem->GetValue() == XFT_NONE )
+ if ( pItem->GetValue() == XFormTextStyle::NONE )
{
m_pTbxStyle->CheckItem(nStyleRotateId, false);
m_pTbxStyle->CheckItem(nStyleUprightId, false);
@@ -642,16 +642,16 @@ IMPL_LINK_NOARG_TYPED(SvxFontWorkDialog, SelectStyleHdl_Impl, ToolBox *, void)
// enabled that is.)
if (nId == nStyleOffId || nId != nLastStyleTbxId )
{
- XFormTextStyle eStyle = XFT_NONE;
+ XFormTextStyle eStyle = XFormTextStyle::NONE;
if (nId == nStyleRotateId)
- eStyle = XFT_ROTATE;
+ eStyle = XFormTextStyle::Rotate;
else if (nId == nStyleUprightId)
- eStyle = XFT_UPRIGHT;
+ eStyle = XFormTextStyle::Upright;
else if (nId == nStyleSlantXId)
- eStyle = XFT_SLANTX;
+ eStyle = XFormTextStyle::SlantX;
else if (nId == nStyleSlantYId)
- eStyle = XFT_SLANTY;
+ eStyle = XFormTextStyle::SlantY;
XFormTextStyleItem aItem( eStyle );
GetBindings().GetDispatcher()->ExecuteList(SID_FORMTEXT_STYLE,
diff --git a/svx/source/sdr/attribute/sdrformtextattribute.cxx b/svx/source/sdr/attribute/sdrformtextattribute.cxx
index 44607a05dc8c..b960efef6d8c 100644
--- a/svx/source/sdr/attribute/sdrformtextattribute.cxx
+++ b/svx/source/sdr/attribute/sdrformtextattribute.cxx
@@ -213,7 +213,7 @@ namespace drawinglayer
mnFormTextShdwXVal(0),
mnFormTextShdwYVal(0),
mnFormTextShdwTransp(0),
- meFormTextStyle(XFT_NONE),
+ meFormTextStyle(XFormTextStyle::NONE),
meFormTextAdjust(XFormTextAdjust::Center),
meFormTextShadow(XFormTextShadow::NONE),
maFormTextShdwColor(),
diff --git a/svx/source/sdr/attribute/sdrtextattribute.cxx b/svx/source/sdr/attribute/sdrtextattribute.cxx
index 4ff9225970ac..76f47517c365 100644
--- a/svx/source/sdr/attribute/sdrtextattribute.cxx
+++ b/svx/source/sdr/attribute/sdrtextattribute.cxx
@@ -114,7 +114,7 @@ namespace drawinglayer
{
if(pSdrText)
{
- if(XFT_NONE != eFormTextStyle)
+ if(XFormTextStyle::NONE != eFormTextStyle)
{
// text on path. Create FormText attribute
const SfxItemSet& rSet = pSdrText->GetItemSet();
diff --git a/svx/source/svdraw/svdibrow.cxx b/svx/source/svdraw/svdibrow.cxx
index 925cdbbc9187..37d8fe192c1d 100644
--- a/svx/source/svdraw/svdibrow.cxx
+++ b/svx/source/svdraw/svdibrow.cxx
@@ -731,7 +731,7 @@ bool IsItemIneffective(sal_uInt16 nWhich, const SfxItemSet* pSet, sal_uInt16& rI
rIndent=1;
if (ImpGetItem(*pSet,XATTR_FORMTXTSTYLE,pItem)) {
XFormTextStyle eStyle=static_cast<const XFormTextStyleItem*>(pItem)->GetValue();
- if (eStyle==XFT_NONE) return true;
+ if (eStyle==XFormTextStyle::NONE) return true;
}
if ((nWhich>=XATTR_FORMTXTSHDWCOLOR && nWhich<=XATTR_FORMTXTSHDWYVAL) || nWhich>=XATTR_FORMTXTSHDWTRANSP) {
rIndent=2;
diff --git a/svx/source/svdraw/svdotext.cxx b/svx/source/svdraw/svdotext.cxx
index 5bc0ddc922d1..42e3d6320686 100644
--- a/svx/source/svdraw/svdotext.cxx
+++ b/svx/source/svdraw/svdotext.cxx
@@ -1808,7 +1808,7 @@ long SdrTextObj::GetMaxTextFrameWidth() const
bool SdrTextObj::IsFontwork() const
{
return !bTextFrame // Default is FALSE
- && static_cast<const XFormTextStyleItem&>(GetObjectItemSet().Get(XATTR_FORMTXTSTYLE)).GetValue() != XFT_NONE;
+ && static_cast<const XFormTextStyleItem&>(GetObjectItemSet().Get(XATTR_FORMTXTSTYLE)).GetValue() != XFormTextStyle::NONE;
}
bool SdrTextObj::IsHideContour() const
diff --git a/svx/source/svdraw/svdotextpathdecomposition.cxx b/svx/source/svdraw/svdotextpathdecomposition.cxx
index d7cba40402e6..d0bcac13ca6f 100644
--- a/svx/source/svdraw/svdotextpathdecomposition.cxx
+++ b/svx/source/svdraw/svdotextpathdecomposition.cxx
@@ -403,7 +403,7 @@ namespace
switch(maSdrFormTextAttribute.getFormTextStyle())
{
- case XFT_ROTATE :
+ case XFormTextStyle::Rotate :
{
aEndPos = basegfx::tools::getPositionAbsolute(aPolygonCandidate, fPolyStart + fPortionLength, fPolyLength);
const basegfx::B2DVector aDirection(aEndPos - aStartPos);
@@ -412,13 +412,13 @@ namespace
break;
}
- case XFT_UPRIGHT :
+ case XFormTextStyle::Upright :
{
aNewTransformB.translate(aStartPos.getX() - (fPortionLength / 2.0), aStartPos.getY());
break;
}
- case XFT_SLANTX :
+ case XFormTextStyle::SlantX :
{
aEndPos = basegfx::tools::getPositionAbsolute(aPolygonCandidate, fPolyStart + fPortionLength, fPolyLength);
const basegfx::B2DVector aDirection(aEndPos - aStartPos);
@@ -436,7 +436,7 @@ namespace
break;
}
- case XFT_SLANTY :
+ case XFormTextStyle::SlantY :
{
aEndPos = basegfx::tools::getPositionAbsolute(aPolygonCandidate, fPolyStart + fPortionLength, fPolyLength);
const basegfx::B2DVector aDirection(aEndPos - aStartPos);
@@ -455,7 +455,7 @@ namespace
break;
}
- default : break; // XFT_NONE
+ default : break; // XFormTextStyle::NONE
}
// distance from path?