[Libreoffice-commits] core.git: sw/inc sw/qa sw/source
Noel Grandin
noel.grandin at collabora.co.uk
Mon Mar 20 06:53:00 UTC 2017
sw/inc/dcontact.hxx | 10 -
sw/inc/fesh.hxx | 8
sw/inc/fmtanchr.hxx | 2
sw/inc/swtypes.hxx | 21 +-
sw/inc/undobj.hxx | 3
sw/qa/core/uwriter.cxx | 4
sw/qa/extras/uiwriter/uiwriter.cxx | 2
sw/source/core/access/accdoc.cxx | 4
sw/source/core/access/accframebase.cxx | 4
sw/source/core/access/accfrmobj.cxx | 8
sw/source/core/access/accmap.cxx | 10 -
sw/source/core/access/accselectionhelper.cxx | 2
sw/source/core/doc/CntntIdxStore.cxx | 8
sw/source/core/doc/DocumentContentOperationsManager.cxx | 42 ++--
sw/source/core/doc/DocumentDrawModelManager.cxx | 2
sw/source/core/doc/DocumentLayoutManager.cxx | 46 ++---
sw/source/core/doc/DocumentStylePoolManager.cxx | 14 -
sw/source/core/doc/docdesc.cxx | 4
sw/source/core/doc/docdraw.cxx | 2
sw/source/core/doc/docedt.cxx | 12 -
sw/source/core/doc/docfly.cxx | 58 +++---
sw/source/core/doc/docglbl.cxx | 4
sw/source/core/doc/doclay.cxx | 46 ++---
sw/source/core/doc/docnew.cxx | 2
sw/source/core/doc/docsort.cxx | 2
sw/source/core/doc/tblcpy.cxx | 4
sw/source/core/docnode/ndtbl.cxx | 4
sw/source/core/docnode/node.cxx | 4
sw/source/core/docnode/nodes.cxx | 2
sw/source/core/docnode/swbaslnk.cxx | 8
sw/source/core/draw/dcontact.cxx | 22 +-
sw/source/core/draw/dview.cxx | 8
sw/source/core/edit/autofmt.cxx | 2
sw/source/core/fields/expfld.cxx | 10 -
sw/source/core/frmedt/fecopy.cxx | 70 ++++----
sw/source/core/frmedt/fefly1.cxx | 86 ++++-----
sw/source/core/frmedt/feshview.cxx | 56 +++---
sw/source/core/frmedt/fews.cxx | 14 -
sw/source/core/frmedt/tblsel.cxx | 4
sw/source/core/inc/UndoCore.hxx | 2
sw/source/core/inc/flyfrm.hxx | 8
sw/source/core/layout/anchoreddrawobject.cxx | 14 -
sw/source/core/layout/anchoredobject.cxx | 12 -
sw/source/core/layout/atrfrm.cxx | 78 ++++----
sw/source/core/layout/calcmove.cxx | 2
sw/source/core/layout/flowfrm.cxx | 2
sw/source/core/layout/fly.cxx | 14 -
sw/source/core/layout/flycnt.cxx | 2
sw/source/core/layout/flylay.cxx | 8
sw/source/core/layout/flypos.cxx | 4
sw/source/core/layout/frmtool.cxx | 20 +-
sw/source/core/layout/objectformattertxtfrm.cxx | 4
sw/source/core/layout/pagechg.cxx | 10 -
sw/source/core/layout/sortedobjs.cxx | 32 +--
sw/source/core/layout/tabfrm.cxx | 6
sw/source/core/layout/wsfrm.cxx | 4
sw/source/core/objectpositioning/tocntntanchoredobjectposition.cxx | 2
sw/source/core/objectpositioning/tolayoutanchoredobjectposition.cxx | 2
sw/source/core/text/EnhancedPDFExportHelper.cxx | 8
sw/source/core/text/frmform.cxx | 2
sw/source/core/text/itratr.cxx | 4
sw/source/core/text/porfly.cxx | 4
sw/source/core/text/txtfly.cxx | 32 +--
sw/source/core/text/txtfrm.cxx | 12 -
sw/source/core/txtnode/atrflyin.cxx | 6
sw/source/core/txtnode/ndtxt.cxx | 4
sw/source/core/txtnode/thints.cxx | 2
sw/source/core/undo/rolbck.cxx | 2
sw/source/core/undo/unattr.cxx | 20 +-
sw/source/core/undo/undel.cxx | 4
sw/source/core/undo/undobj.cxx | 8
sw/source/core/undo/undobj1.cxx | 87 +++++-----
sw/source/core/undo/undraw.cxx | 26 +-
sw/source/core/undo/untbl.cxx | 4
sw/source/core/undo/untblk.cxx | 4
sw/source/core/unocore/unodraw.cxx | 38 ++--
sw/source/core/unocore/unoframe.cxx | 24 +-
sw/source/core/unocore/unoobj2.cxx | 5
sw/source/core/unocore/unotext.cxx | 2
sw/source/core/view/vdraw.cxx | 2
sw/source/filter/basflt/fltshell.cxx | 2
sw/source/filter/basflt/shellio.cxx | 10 -
sw/source/filter/html/css1atr.cxx | 10 -
sw/source/filter/html/htmlcss1.cxx | 10 -
sw/source/filter/html/htmldrawreader.cxx | 12 -
sw/source/filter/html/htmlfly.cxx | 2
sw/source/filter/html/htmlflywriter.cxx | 24 +-
sw/source/filter/html/htmlforw.cxx | 2
sw/source/filter/html/htmlgrin.cxx | 14 -
sw/source/filter/html/htmlplug.cxx | 4
sw/source/filter/html/swhtml.cxx | 12 -
sw/source/filter/ww8/docxsdrexport.cxx | 4
sw/source/filter/ww8/rtfattributeoutput.cxx | 6
sw/source/filter/ww8/writerhelper.cxx | 4
sw/source/filter/ww8/wrtw8esh.cxx | 16 -
sw/source/filter/ww8/wrtw8nds.cxx | 12 -
sw/source/filter/ww8/wrtww8.cxx | 4
sw/source/filter/ww8/wrtww8gr.cxx | 6
sw/source/filter/ww8/ww8atr.cxx | 10 -
sw/source/filter/ww8/ww8glsy.cxx | 4
sw/source/filter/ww8/ww8graf.cxx | 10 -
sw/source/filter/ww8/ww8graf2.cxx | 4
sw/source/filter/ww8/ww8par.cxx | 4
sw/source/filter/ww8/ww8par2.cxx | 8
sw/source/filter/ww8/ww8par4.cxx | 2
sw/source/filter/ww8/ww8par5.cxx | 2
sw/source/filter/ww8/ww8par6.cxx | 12 -
sw/source/filter/xml/xmltexti.cxx | 2
sw/source/ui/dbui/mmlayoutpage.cxx | 2
sw/source/ui/frmdlg/column.cxx | 2
sw/source/ui/frmdlg/frmpage.cxx | 52 ++---
sw/source/ui/frmdlg/wrap.cxx | 32 +--
sw/source/uibase/app/appenv.cxx | 4
sw/source/uibase/app/applab.cxx | 4
sw/source/uibase/dialog/regionsw.cxx | 6
sw/source/uibase/docvw/edtwin.cxx | 12 -
sw/source/uibase/frmdlg/frmmgr.cxx | 24 +-
sw/source/uibase/ribbar/conrect.cxx | 2
sw/source/uibase/ribbar/drawbase.cxx | 2
sw/source/uibase/shells/basesh.cxx | 58 +++---
sw/source/uibase/shells/drwbassh.cxx | 18 +-
sw/source/uibase/shells/frmsh.cxx | 2
sw/source/uibase/shells/textidx.cxx | 2
sw/source/uibase/shells/textsh.cxx | 4
sw/source/uibase/uiview/viewtab.cxx | 4
sw/source/uibase/utlui/attrdesc.cxx | 6
126 files changed, 796 insertions(+), 792 deletions(-)
New commits:
commit d99d143900081dd14e070c7373ba204739d80496
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date: Fri Mar 17 14:15:30 2017 +0200
convert RndStdIds to scoped enum
Change-Id: I029ad67dfcbc40f3953adf485957efcbd97f23d0
Reviewed-on: https://gerrit.libreoffice.org/35328
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/sw/inc/dcontact.hxx b/sw/inc/dcontact.hxx
index fe2a7f0dfe17..9021f5b7796d 100644
--- a/sw/inc/dcontact.hxx
+++ b/sw/inc/dcontact.hxx
@@ -153,11 +153,11 @@ public:
}
RndStdIds GetAnchorId() const { return GetAnchorFormat().GetAnchorId(); }
- bool ObjAnchoredAtPage() const { return GetAnchorId() == FLY_AT_PAGE; }
- bool ObjAnchoredAtFly() const { return GetAnchorId() == FLY_AT_FLY; }
- bool ObjAnchoredAtPara() const { return GetAnchorId() == FLY_AT_PARA; }
- bool ObjAnchoredAtChar() const { return GetAnchorId() == FLY_AT_CHAR; }
- bool ObjAnchoredAsChar() const { return GetAnchorId() == FLY_AS_CHAR; }
+ bool ObjAnchoredAtPage() const { return GetAnchorId() == RndStdIds::FLY_AT_PAGE; }
+ bool ObjAnchoredAtFly() const { return GetAnchorId() == RndStdIds::FLY_AT_FLY; }
+ bool ObjAnchoredAtPara() const { return GetAnchorId() == RndStdIds::FLY_AT_PARA; }
+ bool ObjAnchoredAtChar() const { return GetAnchorId() == RndStdIds::FLY_AT_CHAR; }
+ bool ObjAnchoredAsChar() const { return GetAnchorId() == RndStdIds::FLY_AS_CHAR; }
const SwPosition& GetContentAnchor() const
{
diff --git a/sw/inc/fesh.hxx b/sw/inc/fesh.hxx
index d3f2db36c79d..5995c6288e83 100644
--- a/sw/inc/fesh.hxx
+++ b/sw/inc/fesh.hxx
@@ -512,9 +512,9 @@ public:
void EndTextEdit(); ///< Deletes object if required.
- /** Anchor type of selected object, -1 if ambiguous or in case of frame selection.
- Else FLY_AT_PAGE or FLY_AT_PARA resp. from frmatr.hxx. */
- short GetAnchorId() const;
+ /** Anchor type of selected object, RndStdIds::UNKNOWN if ambiguous or in case of frame selection.
+ Else RndStdIds::FLY_AT_PAGE or RndStdIds::FLY_AT_PARA. */
+ RndStdIds GetAnchorId() const;
/** Process of creating draw objects. At the beginning object type is passed.
At the end a Cmd can be passed. Here, SDRCREATE_RESTRAINTEND for end
@@ -549,7 +549,7 @@ public:
/** frmatr.hxx. Here no enum because of dependencies.
bool value only for internal use! Anchor is newly set according
to current document position. Anchor is not re-set. */
- void ChgAnchor( int eAnchorId, bool bSameOnly = false,
+ void ChgAnchor( RndStdIds eAnchorId, bool bSameOnly = false,
bool bPosCorr = true );
bool SetDrawingAttr( SfxItemSet &rSet );
diff --git a/sw/inc/fmtanchr.hxx b/sw/inc/fmtanchr.hxx
index c26cfa74c31d..374f014930ed 100644
--- a/sw/inc/fmtanchr.hxx
+++ b/sw/inc/fmtanchr.hxx
@@ -44,7 +44,7 @@ class SW_DLLPUBLIC SwFormatAnchor: public SfxPoolItem
static sal_uInt32 mnOrderCounter;
public:
- SwFormatAnchor( RndStdIds eRnd = FLY_AT_PAGE, sal_uInt16 nPageNum = 0 );
+ SwFormatAnchor( RndStdIds eRnd = RndStdIds::FLY_AT_PAGE, sal_uInt16 nPageNum = 0 );
SwFormatAnchor( const SwFormatAnchor &rCpy );
virtual ~SwFormatAnchor() override;
diff --git a/sw/inc/swtypes.hxx b/sw/inc/swtypes.hxx
index 8fe08352119e..33ba955f3743 100644
--- a/sw/inc/swtypes.hxx
+++ b/sw/inc/swtypes.hxx
@@ -136,22 +136,25 @@ const short lOutlineMinTextDistance = 216; // 0.15 inch = 0.38 cm
// The former Rendevouz-IDs live on:
// There are IDs for the anchors (SwFormatAnchor) and some others
// that are only of importance for interfaces (SwDoc).
-enum RndStdIds
+enum class RndStdIds
{
- FLY_AT_PARA, // Anchored at paragraph.
+ UNKNOWN = -1, // return value used by SwFEShell::GetAnchorId
+
+ // the following 5 values are deliberately the same as the values in css::text::TextContentAnchorType
+ FLY_AT_PARA = 0, // Anchored at paragraph.
FLY_AS_CHAR, // Anchored as character.
FLY_AT_PAGE, // Anchored at page.
FLY_AT_FLY, // Anchored at frame.
FLY_AT_CHAR, // Anchored at character.
- RND_STD_HEADER,
- RND_STD_FOOTER,
- RND_STD_HEADERL,
- RND_STD_HEADERR,
- RND_STD_FOOTERL,
- RND_STD_FOOTERR,
+ HEADER,
+ FOOTER,
+ HEADERL,
+ HEADERR,
+ FOOTERL,
+ FOOTERR,
- RND_DRAW_OBJECT // A draw-Object! For the SwDoc-interface only!
+ DRAW_OBJECT // A draw-Object! For the SwDoc-interface only!
};
extern ResMgr* pSwResMgr;
diff --git a/sw/inc/undobj.hxx b/sw/inc/undobj.hxx
index 3f0e521213e7..0f99d73670b8 100644
--- a/sw/inc/undobj.hxx
+++ b/sw/inc/undobj.hxx
@@ -40,6 +40,7 @@ class SwNodeRange;
class SwRedlineData;
class SwRedlineSaveDatas;
enum class RedlineFlags;
+enum class RndStdIds;
namespace sw {
class UndoRedoContext;
@@ -268,7 +269,7 @@ protected:
SwFrameFormat* pFrameFormat; // The saved FlyFormat.
sal_uLong nNdPgPos;
sal_Int32 nCntPos; // Page at/in paragraph.
- sal_uInt16 nRndId;
+ RndStdIds nRndId;
bool bDelFormat; // Delete saved format.
void InsFly(::sw::UndoRedoContext & rContext, bool bShowSel = true);
diff --git a/sw/qa/core/uwriter.cxx b/sw/qa/core/uwriter.cxx
index 4dcf6e12df74..23265c032e2f 100644
--- a/sw/qa/core/uwriter.cxx
+++ b/sw/qa/core/uwriter.cxx
@@ -971,7 +971,7 @@ void SwDocTest::testGraphicAnchorDeletion()
//Insert a graphic at X of >>X<< in paragraph 2
SfxItemSet aFlySet(m_pDoc->GetAttrPool(), RES_FRMATR_BEGIN, RES_FRMATR_END-1);
- SwFormatAnchor aAnchor(FLY_AS_CHAR);
+ SwFormatAnchor aAnchor(RndStdIds::FLY_AS_CHAR);
aAnchor.SetAnchor(aPaM.GetPoint());
aFlySet.Put(aAnchor);
SwFlyFrameFormat *pFrame = m_pDoc->getIDocumentContentOperations().Insert(aPaM, OUString(), OUString(), nullptr, &aFlySet, nullptr, nullptr);
@@ -1000,7 +1000,7 @@ void SwDocTest::testGraphicAnchorDeletion()
CPPUNIT_ASSERT_EQUAL_MESSAGE("Should be 0 graphics", static_cast<size_t>(0), m_pDoc->GetFlyCount(FLYCNTTYPE_GRF));
- //Now, if instead we swap FLY_AS_CHAR (inline graphic) to FLY_AT_CHAR (anchored to character)
+ //Now, if instead we swap RndStdIds::FLY_AS_CHAR (inline graphic) to RndStdIds::FLY_AT_CHAR (anchored to character)
//and repeat the above, graphic is *not* deleted, i.e. it belongs to the paragraph, not the
//range to which its anchored, which is annoying.
}
diff --git a/sw/qa/extras/uiwriter/uiwriter.cxx b/sw/qa/extras/uiwriter/uiwriter.cxx
index aec4b5e00a77..e6e4aa3ae38e 100644
--- a/sw/qa/extras/uiwriter/uiwriter.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter.cxx
@@ -3219,7 +3219,7 @@ void SwUiWriterTest::testShapeAnchorUndo()
pWrtShell->SelectObj(Point(), 0, pObject);
pWrtShell->GetDrawView()->MoveMarkedObj(Size(100, 100));
- pWrtShell->ChgAnchor(0, true);
+ pWrtShell->ChgAnchor(RndStdIds::FLY_AT_PARA, true);
rUndoManager.EndUndo(SwUndoId::END, nullptr);
diff --git a/sw/source/core/access/accdoc.cxx b/sw/source/core/access/accdoc.cxx
index 0cd8202d849d..84e7298487f2 100644
--- a/sw/source/core/access/accdoc.cxx
+++ b/sw/source/core/access/accdoc.cxx
@@ -560,7 +560,7 @@ uno::Any SAL_CALL SwAccessibleDocument::getExtendedAttributes()
SwFlyFrame *pFlyFrame = pCurrFrame->FindFlyFrame();
const SwFormatAnchor& rAnchor = pFlyFrame->GetFormat()->GetAnchor();
RndStdIds eAnchorId = rAnchor.GetAnchorId();
- if(eAnchorId == FLY_AS_CHAR)
+ if(eAnchorId == RndStdIds::FLY_AS_CHAR)
{
const SwFrame *pSwFrame = pFlyFrame->GetAnchorFrame();
if(pSwFrame->IsTextFrame())
@@ -584,7 +584,7 @@ uno::Any SAL_CALL SwAccessibleDocument::getExtendedAttributes()
SdrObject *pObj = rMrkList.GetMark(i)->GetMarkedSdrObj();
SwFrameFormat* pFormat = static_cast<SwDrawContact*>(pObj->GetUserCall())->GetFormat();
const SwFormatAnchor& rAnchor = pFormat->GetAnchor();
- if( FLY_AS_CHAR != rAnchor.GetAnchorId() )
+ if( RndStdIds::FLY_AS_CHAR != rAnchor.GetAnchorId() )
pCurrTextFrame = nullptr;
}
}
diff --git a/sw/source/core/access/accframebase.cxx b/sw/source/core/access/accframebase.cxx
index e4021791935b..396cbb0571cf 100644
--- a/sw/source/core/access/accframebase.cxx
+++ b/sw/source/core/access/accframebase.cxx
@@ -336,13 +336,13 @@ bool SwAccessibleFrameBase::GetSelectedState( )
sal_uLong nEndIndex = pEnd->nNode.GetIndex();
if( ( nHere >= nStartIndex ) && (nHere <= nEndIndex) )
{
- if( rAnchor.GetAnchorId() == FLY_AS_CHAR )
+ if( rAnchor.GetAnchorId() == RndStdIds::FLY_AS_CHAR )
{
if( ((nHere == nStartIndex) && (nIndex >= pStart->nContent.GetIndex())) || (nHere > nStartIndex) )
if( ((nHere == nEndIndex) && (nIndex < pEnd->nContent.GetIndex())) || (nHere < nEndIndex) )
return true;
}
- else if( rAnchor.GetAnchorId() == FLY_AT_PARA )
+ else if( rAnchor.GetAnchorId() == RndStdIds::FLY_AT_PARA )
{
if( ((nHere > nStartIndex) || pStart->nContent.GetIndex() ==0 )
&& (nHere < nEndIndex ) )
diff --git a/sw/source/core/access/accfrmobj.cxx b/sw/source/core/access/accfrmobj.cxx
index 9c8d51520160..b2471797b673 100644
--- a/sw/source/core/access/accfrmobj.cxx
+++ b/sw/source/core/access/accfrmobj.cxx
@@ -157,7 +157,7 @@ bool SwAccessibleChild::IsBoundAsChar() const
{
const SwFrameFormat* pFrameFormat = ::FindFrameFormat( mpDrawObj );
bRet = pFrameFormat
- && (FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId());
+ && (RndStdIds::FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId());
}
else if ( mpWindow )
{
@@ -334,7 +334,7 @@ const SwFrame* SwAccessibleChild::GetParent( const bool bInPagePreview ) const
const SwFlyFrame* pFly = static_cast< const SwFlyFrame *>( mpFrame );
if( pFly->IsFlyInContentFrame() )
{
- // For FLY_AS_CHAR the parent is the anchor
+ // For RndStdIds::FLY_AS_CHAR the parent is the anchor
pParent = pFly->GetAnchorFrame();
OSL_ENSURE( SwAccessibleChild( pParent ).IsAccessible( bInPagePreview ),
"parent is not accessible" );
@@ -368,9 +368,9 @@ const SwFrame* SwAccessibleChild::GetParent( const bool bInPagePreview ) const
{
const SwFrameFormat *pFrameFormat = pContact->GetFormat();
OSL_ENSURE( pFrameFormat, "frame format is missing" );
- if( pFrameFormat && FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId() )
+ if( pFrameFormat && RndStdIds::FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId() )
{
- // For FLY_AS_CHAR the parent is the anchor
+ // For RndStdIds::FLY_AS_CHAR the parent is the anchor
pParent = pContact->GetAnchorFrame();
OSL_ENSURE( SwAccessibleChild( pParent ).IsAccessible( bInPagePreview ),
"parent is not accessible" );
diff --git a/sw/source/core/access/accmap.cxx b/sw/source/core/access/accmap.cxx
index c925bac2c6fb..959652ef7484 100644
--- a/sw/source/core/access/accmap.cxx
+++ b/sw/source/core/access/accmap.cxx
@@ -1152,7 +1152,7 @@ void SwAccessibleMap::InvalidateShapeInParaSelection()
const SwFormatAnchor& rAnchor = pFrameFormat->GetAnchor();
const SwPosition *pPos = rAnchor.GetContentAnchor();
- if(rAnchor.GetAnchorId() == FLY_AT_PAGE)
+ if(rAnchor.GetAnchorId() == RndStdIds::FLY_AT_PAGE)
{
uno::Reference < XAccessible > xAcc( (*aIter).second );
if(xAcc.is())
@@ -1189,7 +1189,7 @@ void SwAccessibleMap::InvalidateShapeInParaSelection()
sal_uLong nEndIndex = pEnd->nNode.GetIndex();
if( ( nHere >= nStartIndex ) && (nHere <= nEndIndex) )
{
- if( rAnchor.GetAnchorId() == FLY_AS_CHAR )
+ if( rAnchor.GetAnchorId() == RndStdIds::FLY_AS_CHAR )
{
if( ( ((nHere == nStartIndex) && (nIndex >= pStart->nContent.GetIndex())) || (nHere > nStartIndex) )
&&( ((nHere == nEndIndex) && (nIndex < pEnd->nContent.GetIndex())) || (nHere < nEndIndex) ) )
@@ -1205,7 +1205,7 @@ void SwAccessibleMap::InvalidateShapeInParaSelection()
static_cast < ::accessibility::AccessibleShape* >(xAcc.get())->ResetState( AccessibleStateType::SELECTED );
}
}
- else if( rAnchor.GetAnchorId() == FLY_AT_PARA )
+ else if( rAnchor.GetAnchorId() == RndStdIds::FLY_AT_PARA )
{
if( ((nHere > nStartIndex) || pStart->nContent.GetIndex() ==0 )
&& (nHere < nEndIndex ) )
@@ -1272,7 +1272,7 @@ void SwAccessibleMap::InvalidateShapeInParaSelection()
if (pFrameFormat)
{
const SwFormatAnchor& rAnchor = pFrameFormat->GetAnchor();
- if( rAnchor.GetAnchorId() == FLY_AS_CHAR )
+ if( rAnchor.GetAnchorId() == RndStdIds::FLY_AS_CHAR )
{
uno::Reference< XAccessible > xAccParent = pAccFrame->getAccessibleParent();
if (xAccParent.is())
@@ -1543,7 +1543,7 @@ void SwAccessibleMap::DoInvalidateShapeSelection(bool bInvalidateFocusMode /*=fa
if (pFrameFormat)
{
const SwFormatAnchor& rAnchor = pFrameFormat->GetAnchor();
- if( rAnchor.GetAnchorId() == FLY_AS_CHAR )
+ if( rAnchor.GetAnchorId() == RndStdIds::FLY_AS_CHAR )
{
uno::Reference< XAccessible > xPara = pAccShape->getAccessibleParent();
if (xPara.is())
diff --git a/sw/source/core/access/accselectionhelper.cxx b/sw/source/core/access/accselectionhelper.cxx
index 61b25e1a7022..0781b7b04ed2 100644
--- a/sw/source/core/access/accselectionhelper.cxx
+++ b/sw/source/core/access/accselectionhelper.cxx
@@ -292,7 +292,7 @@ Reference<XAccessible> SwAccessibleSelectionHelper::getSelectedAccessibleChild(
if (pFrameFormat)
{
const SwFormatAnchor& rAnchor = pFrameFormat->GetAnchor();
- if( rAnchor.GetAnchorId() == FLY_AS_CHAR )
+ if( rAnchor.GetAnchorId() == RndStdIds::FLY_AS_CHAR )
{
const SwFrame *pParaFrame = SwAccessibleFrame::GetParent( SwAccessibleChild(pFlyFrame), m_rContext.IsInPagePreview() );
aChild = pParaFrame;
diff --git a/sw/source/core/doc/CntntIdxStore.cxx b/sw/source/core/doc/CntntIdxStore.cxx
index 102d4873f202..14775d1e050a 100644
--- a/sw/source/core/doc/CntntIdxStore.cxx
+++ b/sw/source/core/doc/CntntIdxStore.cxx
@@ -326,13 +326,13 @@ void ContentIdxStoreImpl::SaveFlys(SwDoc* pDoc, sal_uLong nNode, sal_Int32 nCont
const SwFormatAnchor& rAnchor = pFrameFormat->GetAnchor();
SwPosition const*const pAPos = rAnchor.GetContentAnchor();
if ( pAPos && ( nNode == pAPos->nNode.GetIndex() ) &&
- ( FLY_AT_PARA == rAnchor.GetAnchorId() ||
- FLY_AT_CHAR == rAnchor.GetAnchorId() ) )
+ ( RndStdIds::FLY_AT_PARA == rAnchor.GetAnchorId() ||
+ RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId() ) )
{
bool bSkip = false;
aSave.m_bOther = false;
aSave.m_nContent = pAPos->nContent.GetIndex();
- if ( FLY_AT_CHAR == rAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId() )
{
if( nContent <= aSave.m_nContent )
{
@@ -364,7 +364,7 @@ void ContentIdxStoreImpl::RestoreFlys(SwDoc* pDoc, updater_t& rUpdater, bool bAu
SwFormatAnchor aNew( rFlyAnchor );
SwPosition aNewPos( *rFlyAnchor.GetContentAnchor() );
rUpdater(aNewPos, aEntry.m_nContent);
- if ( FLY_AT_CHAR != rFlyAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AT_CHAR != rFlyAnchor.GetAnchorId() )
{
aNewPos.nContent.Assign( nullptr, 0 );
}
diff --git a/sw/source/core/doc/DocumentContentOperationsManager.cxx b/sw/source/core/doc/DocumentContentOperationsManager.cxx
index a842102340cc..2e4fe3c54cac 100644
--- a/sw/source/core/doc/DocumentContentOperationsManager.cxx
+++ b/sw/source/core/doc/DocumentContentOperationsManager.cxx
@@ -94,10 +94,10 @@ namespace
SwFormatAnchor const*const pAnchor = &pFormat->GetAnchor();
SwPosition const*const pAPos = pAnchor->GetContentAnchor();
if (pAPos &&
- ((FLY_AS_CHAR == pAnchor->GetAnchorId()) ||
- (FLY_AT_CHAR == pAnchor->GetAnchorId()) ||
- (FLY_AT_FLY == pAnchor->GetAnchorId()) ||
- (FLY_AT_PARA == pAnchor->GetAnchorId())) &&
+ ((RndStdIds::FLY_AS_CHAR == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_FLY == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_PARA == pAnchor->GetAnchorId())) &&
nSttNd <= pAPos->nNode.GetIndex() &&
pAPos->nNode.GetIndex() < nEndNd )
{
@@ -1889,8 +1889,8 @@ bool DocumentContentOperationsManager::DelFullPara( SwPaM& rPam )
const SwFormatAnchor* pAnchor = &pFly->GetAnchor();
SwPosition const*const pAPos = pAnchor->GetContentAnchor();
if (pAPos &&
- ((FLY_AT_PARA == pAnchor->GetAnchorId()) ||
- (FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
+ ((RndStdIds::FLY_AT_PARA == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
aRg.aStart <= pAPos->nNode && pAPos->nNode <= aRg.aEnd )
{
m_rDoc.getIDocumentLayoutAccess().DelLayoutFormat( pFly );
@@ -2734,7 +2734,7 @@ SwDrawFrameFormat* DocumentContentOperationsManager::InsertDrawObj(
// Didn't set the Anchor yet?
// DrawObjecte must never end up in the Header/Footer!
RndStdIds eAnchorId = pAnchor != nullptr ? pAnchor->GetAnchorId() : pFormat->GetAnchor().GetAnchorId();
- const bool bIsAtContent = (FLY_AT_PAGE != eAnchorId);
+ const bool bIsAtContent = (RndStdIds::FLY_AT_PAGE != eAnchorId);
const SwNodeIndex* pChkIdx = nullptr;
if ( pAnchor == nullptr )
@@ -2753,7 +2753,7 @@ SwDrawFrameFormat* DocumentContentOperationsManager::InsertDrawObj(
&& m_rDoc.IsInHeaderFooter( *pChkIdx ) )
{
// apply at-page anchor format
- eAnchorId = FLY_AT_PAGE;
+ eAnchorId = RndStdIds::FLY_AT_PAGE;
pFormat->SetFormatAttr( SwFormatAnchor( eAnchorId ) );
}
else if( pAnchor == nullptr
@@ -2763,7 +2763,7 @@ SwDrawFrameFormat* DocumentContentOperationsManager::InsertDrawObj(
// apply anchor format
SwFormatAnchor aAnch( pAnchor != nullptr ? *pAnchor : pFormat->GetAnchor() );
eAnchorId = aAnch.GetAnchorId();
- if ( eAnchorId == FLY_AT_FLY )
+ if ( eAnchorId == RndStdIds::FLY_AT_FLY )
{
SwPosition aPos( *rRg.GetNode().FindFlyStartNode() );
aAnch.SetAnchor( &aPos );
@@ -2771,9 +2771,9 @@ SwDrawFrameFormat* DocumentContentOperationsManager::InsertDrawObj(
else
{
aAnch.SetAnchor( rRg.GetPoint() );
- if ( eAnchorId == FLY_AT_PAGE )
+ if ( eAnchorId == RndStdIds::FLY_AT_PAGE )
{
- eAnchorId = dynamic_cast<const SdrUnoObj*>( &rDrawObj) != nullptr ? FLY_AS_CHAR : FLY_AT_PARA;
+ eAnchorId = dynamic_cast<const SdrUnoObj*>( &rDrawObj) != nullptr ? RndStdIds::FLY_AS_CHAR : RndStdIds::FLY_AT_PARA;
aAnch.SetType( eAnchorId );
}
}
@@ -2781,7 +2781,7 @@ SwDrawFrameFormat* DocumentContentOperationsManager::InsertDrawObj(
}
// insert text attribute for as-character anchored drawing object
- if ( eAnchorId == FLY_AS_CHAR )
+ if ( eAnchorId == RndStdIds::FLY_AS_CHAR )
{
bool bAnchorAtPageAsFallback = true;
const SwFormatAnchor& rDrawObjAnchorFormat = pFormat->GetAnchor();
@@ -2801,7 +2801,7 @@ SwDrawFrameFormat* DocumentContentOperationsManager::InsertDrawObj(
if ( bAnchorAtPageAsFallback )
{
OSL_ENSURE( false, "DocumentContentOperationsManager::InsertDrawObj(..) - missing content anchor for as-character anchored drawing object --> anchor at-page" );
- pFormat->SetFormatAttr( SwFormatAnchor( FLY_AT_PAGE ) );
+ pFormat->SetFormatAttr( SwFormatAnchor( RndStdIds::FLY_AT_PAGE ) );
}
}
@@ -3267,21 +3267,21 @@ void DocumentContentOperationsManager::CopyFlyInFlyImpl(
SwFrameFormat* pFormat = (*m_rDoc.GetSpzFrameFormats())[n];
SwFormatAnchor const*const pAnchor = &pFormat->GetAnchor();
SwPosition const*const pAPos = pAnchor->GetContentAnchor();
- bool bAtContent = (pAnchor->GetAnchorId() == FLY_AT_PARA);
+ bool bAtContent = (pAnchor->GetAnchorId() == RndStdIds::FLY_AT_PARA);
if ( !pAPos )
continue;
sal_uLong nSkipAfter = pAPos->nNode.GetIndex();
sal_uLong nStart = rRg.aStart.GetIndex();
switch ( pAnchor->GetAnchorId() )
{
- case FLY_AT_FLY:
+ case RndStdIds::FLY_AT_FLY:
if(bCopyFlyAtFly)
++nSkipAfter;
else if(m_rDoc.getIDocumentRedlineAccess().IsRedlineMove())
++nStart;
break;
- case FLY_AT_CHAR:
- case FLY_AT_PARA:
+ case RndStdIds::FLY_AT_CHAR:
+ case RndStdIds::FLY_AT_PARA:
if(m_rDoc.getIDocumentRedlineAccess().IsRedlineMove())
++nStart;
break;
@@ -3364,8 +3364,8 @@ void DocumentContentOperationsManager::CopyFlyInFlyImpl(
// method <SwNodes::CopyNodes(..)>.
// Thus, the new anchor position in the destination document is found
// by counting the text nodes.
- if ((aAnchor.GetAnchorId() == FLY_AT_PARA) ||
- (aAnchor.GetAnchorId() == FLY_AT_CHAR) )
+ if ((aAnchor.GetAnchorId() == RndStdIds::FLY_AT_PARA) ||
+ (aAnchor.GetAnchorId() == RndStdIds::FLY_AT_CHAR) )
{
// First, determine number of anchor text node in the copied range.
// Note: The anchor text node *have* to be inside the copied range.
@@ -3429,7 +3429,7 @@ void DocumentContentOperationsManager::CopyFlyInFlyImpl(
newPos.nNode = aIdx;
}
// Set the character bound Flys back at the original character
- if ((FLY_AT_CHAR == aAnchor.GetAnchorId()) &&
+ if ((RndStdIds::FLY_AT_CHAR == aAnchor.GetAnchorId()) &&
newPos.nNode.GetNode().IsTextNode() )
{
newPos.nContent.Assign( newPos.nNode.GetNode().GetTextNode(), newPos.nContent.GetIndex() );
@@ -4068,7 +4068,7 @@ SwFlyFrameFormat* DocumentContentOperationsManager::InsNoTextNode( const SwPosit
SwFlyFrameFormat *pFormat = nullptr;
if( pNode )
{
- pFormat = m_rDoc.MakeFlySection_( rPos, *pNode, FLY_AT_PARA,
+ pFormat = m_rDoc.MakeFlySection_( rPos, *pNode, RndStdIds::FLY_AT_PARA,
pFlyAttrSet, pFrameFormat );
if( pGrfAttrSet )
pNode->SetAttr( *pGrfAttrSet );
diff --git a/sw/source/core/doc/DocumentDrawModelManager.cxx b/sw/source/core/doc/DocumentDrawModelManager.cxx
index b97143d3fbe4..ec8fd87235cc 100644
--- a/sw/source/core/doc/DocumentDrawModelManager.cxx
+++ b/sw/source/core/doc/DocumentDrawModelManager.cxx
@@ -307,7 +307,7 @@ bool DocumentDrawModelManager::Search(const SwPaM& rPaM, const SvxSearchItem& rS
// Filter for at-paragraph anchored draw frames.
const SwFrameFormat& rFrameFormat = pPosFlyFrame->GetFormat();
const SwFormatAnchor& rAnchor = rFrameFormat.GetAnchor();
- if (rAnchor.GetAnchorId() != FLY_AT_PARA || rFrameFormat.Which() != RES_DRAWFRMFMT)
+ if (rAnchor.GetAnchorId() != RndStdIds::FLY_AT_PARA || rFrameFormat.Which() != RES_DRAWFRMFMT)
continue;
// Does the shape have matching text?
diff --git a/sw/source/core/doc/DocumentLayoutManager.cxx b/sw/source/core/doc/DocumentLayoutManager.cxx
index 08e1cff435a7..55d0192c9775 100644
--- a/sw/source/core/doc/DocumentLayoutManager.cxx
+++ b/sw/source/core/doc/DocumentLayoutManager.cxx
@@ -115,16 +115,16 @@ SwFrameFormat *DocumentLayoutManager::MakeLayoutFormat( RndStdIds eRequest, cons
switch ( eRequest )
{
- case RND_STD_HEADER:
- case RND_STD_HEADERL:
- case RND_STD_HEADERR:
+ case RndStdIds::HEADER:
+ case RndStdIds::HEADERL:
+ case RndStdIds::HEADERR:
{
bHeader = true;
SAL_FALLTHROUGH;
}
- case RND_STD_FOOTER:
- case RND_STD_FOOTERL:
- case RND_STD_FOOTERR:
+ case RndStdIds::FOOTER:
+ case RndStdIds::FOOTERL:
+ case RndStdIds::FOOTERR:
{
pFormat = new SwFrameFormat( m_rDoc.GetAttrPool(),
(bHeader ? "Right header" : "Right footer"),
@@ -136,14 +136,14 @@ SwFrameFormat *DocumentLayoutManager::MakeLayoutFormat( RndStdIds eRequest, cons
( aTmpIdx,
bHeader ? SwHeaderStartNode : SwFooterStartNode,
m_rDoc.getIDocumentStylePoolAccess().GetTextCollFromPool(static_cast<sal_uInt16>( bHeader
- ? ( eRequest == RND_STD_HEADERL
+ ? ( eRequest == RndStdIds::HEADERL
? RES_POOLCOLL_HEADERL
- : eRequest == RND_STD_HEADERR
+ : eRequest == RndStdIds::HEADERR
? RES_POOLCOLL_HEADERR
: RES_POOLCOLL_HEADER )
- : ( eRequest == RND_STD_FOOTERL
+ : ( eRequest == RndStdIds::FOOTERL
? RES_POOLCOLL_FOOTERL
- : eRequest == RND_STD_FOOTERR
+ : eRequest == RndStdIds::FOOTERR
? RES_POOLCOLL_FOOTERR
: RES_POOLCOLL_FOOTER )
) ) );
@@ -159,7 +159,7 @@ SwFrameFormat *DocumentLayoutManager::MakeLayoutFormat( RndStdIds eRequest, cons
}
break;
- case RND_DRAW_OBJECT:
+ case RndStdIds::DRAW_OBJECT:
{
pFormat = m_rDoc.MakeDrawFrameFormat( OUString(), m_rDoc.GetDfltFrameFormat() );
if( pSet ) // Set a few more attributes
@@ -174,11 +174,11 @@ SwFrameFormat *DocumentLayoutManager::MakeLayoutFormat( RndStdIds eRequest, cons
break;
#if OSL_DEBUG_LEVEL > 0
- case FLY_AT_PAGE:
- case FLY_AT_CHAR:
- case FLY_AT_FLY:
- case FLY_AT_PARA:
- case FLY_AS_CHAR:
+ case RndStdIds::FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_CHAR:
+ case RndStdIds::FLY_AT_FLY:
+ case RndStdIds::FLY_AT_PARA:
+ case RndStdIds::FLY_AS_CHAR:
OSL_FAIL( "use new interface instead: SwDoc::MakeFlySection!" );
break;
#endif
@@ -269,7 +269,7 @@ void DocumentLayoutManager::DelLayoutFormat( SwFrameFormat *pFormat )
{
SwFrameFormat* pTmpFormat = (*pTable)[i];
const SwFormatAnchor &rAnch = pTmpFormat->GetAnchor();
- if ( rAnch.GetAnchorId() == FLY_AT_FLY &&
+ if ( rAnch.GetAnchorId() == RndStdIds::FLY_AT_FLY &&
rAnch.GetContentAnchor()->nNode.GetIndex() == nNodeIdxOfFlyFormat )
{
aToDeleteFrameFormats.push_back( pTmpFormat );
@@ -298,7 +298,7 @@ void DocumentLayoutManager::DelLayoutFormat( SwFrameFormat *pFormat )
// Delete the character for FlyFrames anchored as char (if necessary)
const SwFormatAnchor& rAnchor = pFormat->GetAnchor();
- if ((FLY_AS_CHAR == rAnchor.GetAnchorId()) && rAnchor.GetContentAnchor())
+ if ((RndStdIds::FLY_AS_CHAR == rAnchor.GetAnchorId()) && rAnchor.GetContentAnchor())
{
const SwPosition* pPos = rAnchor.GetContentAnchor();
SwTextNode *pTextNd = pPos->nNode.GetNode().GetTextNode();
@@ -354,7 +354,7 @@ SwFrameFormat *DocumentLayoutManager::CopyLayoutFormat(
rSource.CallSwClientNotify(sw::CheckDrawFrameFormatLayerHint(&bCheckControlLayer));
bMayNotCopy =
bCheckControlLayer &&
- ((FLY_AT_PARA == rNewAnchor.GetAnchorId()) || (FLY_AT_FLY == rNewAnchor.GetAnchorId()) || (FLY_AT_CHAR == rNewAnchor.GetAnchorId())) &&
+ ((RndStdIds::FLY_AT_PARA == rNewAnchor.GetAnchorId()) || (RndStdIds::FLY_AT_FLY == rNewAnchor.GetAnchorId()) || (RndStdIds::FLY_AT_CHAR == rNewAnchor.GetAnchorId())) &&
pCAnchor && m_rDoc.IsInHeaderFooter(pCAnchor->nNode);
}
@@ -463,7 +463,7 @@ SwFrameFormat *DocumentLayoutManager::CopyLayoutFormat(
}
}
- if (bSetTextFlyAtt && (FLY_AS_CHAR == rNewAnchor.GetAnchorId()))
+ if (bSetTextFlyAtt && (RndStdIds::FLY_AS_CHAR == rNewAnchor.GetAnchorId()))
{
const SwPosition* pPos = rNewAnchor.GetContentAnchor();
SwFormatFlyCnt aFormat( pDest );
@@ -478,13 +478,13 @@ SwFrameFormat *DocumentLayoutManager::CopyLayoutFormat(
if (SwFrameFormat* pSourceTextBox = SwTextBoxHelper::getOtherTextBoxFormat(&rSource, RES_DRAWFRMFMT))
{
SwFormatAnchor boxAnchor(rNewAnchor);
- if (FLY_AS_CHAR == boxAnchor.GetAnchorId())
+ if (RndStdIds::FLY_AS_CHAR == boxAnchor.GetAnchorId())
{
// AS_CHAR *must not* be set on textbox fly-frame
- boxAnchor.SetType(FLY_AT_CHAR);
+ boxAnchor.SetType(RndStdIds::FLY_AT_CHAR);
}
// presumably these anchors are supported though not sure
- assert(FLY_AT_CHAR == boxAnchor.GetAnchorId() || FLY_AT_PARA == boxAnchor.GetAnchorId());
+ assert(RndStdIds::FLY_AT_CHAR == boxAnchor.GetAnchorId() || RndStdIds::FLY_AT_PARA == boxAnchor.GetAnchorId());
SwFrameFormat* pDestTextBox = CopyLayoutFormat(*pSourceTextBox,
boxAnchor, bSetTextFlyAtt, bMakeFrames);
SwAttrSet aSet(pDest->GetAttrSet());
diff --git a/sw/source/core/doc/DocumentStylePoolManager.cxx b/sw/source/core/doc/DocumentStylePoolManager.cxx
index 9ee0154171b0..c911c72b09b4 100644
--- a/sw/source/core/doc/DocumentStylePoolManager.cxx
+++ b/sw/source/core/doc/DocumentStylePoolManager.cxx
@@ -1271,13 +1271,13 @@ SwFormat* DocumentStylePoolManager::GetFormatFromPool( sal_uInt16 nId )
{
if ( m_rDoc.GetDocumentSettingManager().get(DocumentSettingId::HTML_MODE) )
{
- aSet.Put( SwFormatAnchor( FLY_AS_CHAR ));
+ aSet.Put( SwFormatAnchor( RndStdIds::FLY_AS_CHAR ));
aSet.Put( SwFormatVertOrient( 0, text::VertOrientation::LINE_CENTER, text::RelOrientation::PRINT_AREA ) );
aSet.Put( SwFormatSurround( css::text::WrapTextMode_NONE ) );
}
else
{
- aSet.Put( SwFormatAnchor( FLY_AT_PARA ));
+ aSet.Put( SwFormatAnchor( RndStdIds::FLY_AT_PARA ));
aSet.Put( SwFormatSurround( css::text::WrapTextMode_PARALLEL ) );
aSet.Put( SwFormatHoriOrient( 0, text::HoriOrientation::CENTER, text::RelOrientation::PRINT_AREA ) );
aSet.Put( SwFormatVertOrient( 0, text::VertOrientation::TOP, text::RelOrientation::PRINT_AREA ) );
@@ -1301,7 +1301,7 @@ SwFormat* DocumentStylePoolManager::GetFormatFromPool( sal_uInt16 nId )
case RES_POOLFRM_GRAPHIC:
case RES_POOLFRM_OLE:
{
- aSet.Put( SwFormatAnchor( FLY_AT_PARA ));
+ aSet.Put( SwFormatAnchor( RndStdIds::FLY_AT_PARA ));
aSet.Put( SwFormatHoriOrient( 0, text::HoriOrientation::CENTER, text::RelOrientation::FRAME ));
aSet.Put( SwFormatVertOrient( 0, text::VertOrientation::TOP, text::RelOrientation::FRAME ));
aSet.Put( SwFormatSurround( css::text::WrapTextMode_DYNAMIC ));
@@ -1309,14 +1309,14 @@ SwFormat* DocumentStylePoolManager::GetFormatFromPool( sal_uInt16 nId )
break;
case RES_POOLFRM_FORMEL:
{
- aSet.Put( SwFormatAnchor( FLY_AS_CHAR ) );
+ aSet.Put( SwFormatAnchor( RndStdIds::FLY_AS_CHAR ) );
aSet.Put( SwFormatVertOrient( 0, text::VertOrientation::CHAR_CENTER, text::RelOrientation::FRAME ) );
aSet.Put( SvxLRSpaceItem( 114, 114, 0, 0, RES_LR_SPACE ) );
}
break;
case RES_POOLFRM_MARGINAL:
{
- aSet.Put( SwFormatAnchor( FLY_AT_PARA ));
+ aSet.Put( SwFormatAnchor( RndStdIds::FLY_AT_PARA ));
aSet.Put( SwFormatHoriOrient( 0, text::HoriOrientation::LEFT, text::RelOrientation::FRAME ));
aSet.Put( SwFormatVertOrient( 0, text::VertOrientation::TOP, text::RelOrientation::FRAME ));
aSet.Put( SwFormatSurround( css::text::WrapTextMode_PARALLEL ));
@@ -1328,7 +1328,7 @@ SwFormat* DocumentStylePoolManager::GetFormatFromPool( sal_uInt16 nId )
break;
case RES_POOLFRM_WATERSIGN:
{
- aSet.Put( SwFormatAnchor( FLY_AT_PAGE ));
+ aSet.Put( SwFormatAnchor( RndStdIds::FLY_AT_PAGE ));
aSet.Put( SwFormatHoriOrient( 0, text::HoriOrientation::CENTER, text::RelOrientation::FRAME ));
aSet.Put( SwFormatVertOrient( 0, text::VertOrientation::CENTER, text::RelOrientation::FRAME ));
aSet.Put( SvxOpaqueItem( RES_OPAQUE, false ));
@@ -1337,7 +1337,7 @@ SwFormat* DocumentStylePoolManager::GetFormatFromPool( sal_uInt16 nId )
break;
case RES_POOLFRM_LABEL:
{
- aSet.Put( SwFormatAnchor( FLY_AS_CHAR ) );
+ aSet.Put( SwFormatAnchor( RndStdIds::FLY_AS_CHAR ) );
aSet.Put( SwFormatVertOrient( 0, text::VertOrientation::TOP, text::RelOrientation::FRAME ) );
aSet.Put( SvxLRSpaceItem( 114, 114, 0, 0, RES_LR_SPACE ) );
diff --git a/sw/source/core/doc/docdesc.cxx b/sw/source/core/doc/docdesc.cxx
index bbc3897392c6..52e5600fa6b7 100644
--- a/sw/source/core/doc/docdesc.cxx
+++ b/sw/source/core/doc/docdesc.cxx
@@ -257,7 +257,7 @@ void SwDoc::CopyMasterHeader(const SwPageDesc &rChged, const SwFormatHeader &rHe
const SwFormatHeader &rFormatHead = rDescFrameFormat.GetHeader();
if ( !rFormatHead.IsActive() )
{
- SwFormatHeader aHead( getIDocumentLayoutAccess().MakeLayoutFormat( RND_STD_HEADERL, nullptr ) );
+ SwFormatHeader aHead( getIDocumentLayoutAccess().MakeLayoutFormat( RndStdIds::HEADERL, nullptr ) );
rDescFrameFormat.SetFormatAttr( aHead );
// take over additional attributes (margins, borders ...)
::lcl_DescSetAttr( *rHead.GetHeaderFormat(), *aHead.GetHeaderFormat(), false);
@@ -330,7 +330,7 @@ void SwDoc::CopyMasterFooter(const SwPageDesc &rChged, const SwFormatFooter &rFo
const SwFormatFooter &rFormatFoot = rDescFrameFormat.GetFooter();
if ( !rFormatFoot.IsActive() )
{
- SwFormatFooter aFoot( getIDocumentLayoutAccess().MakeLayoutFormat( RND_STD_FOOTER, nullptr ) );
+ SwFormatFooter aFoot( getIDocumentLayoutAccess().MakeLayoutFormat( RndStdIds::FOOTER, nullptr ) );
rDescFrameFormat.SetFormatAttr( aFoot );
// Take over additional attributes (margins, borders ...).
::lcl_DescSetAttr( *rFoot.GetFooterFormat(), *aFoot.GetFooterFormat(), false);
diff --git a/sw/source/core/doc/docdraw.cxx b/sw/source/core/doc/docdraw.cxx
index a6c66c2b232a..28be9b0d92d1 100644
--- a/sw/source/core/doc/docdraw.cxx
+++ b/sw/source/core/doc/docdraw.cxx
@@ -420,7 +420,7 @@ bool SwDoc::DeleteSelection( SwDrawView& rDrawView )
SwDrawContact *pC = static_cast<SwDrawContact*>(GetUserCall(pObj));
SwDrawFrameFormat *pFrameFormat = static_cast<SwDrawFrameFormat*>(pC->GetFormat());
if( pFrameFormat &&
- FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId() )
+ RndStdIds::FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId() )
{
rDrawView.MarkObj( pObj, rDrawView.Imp().GetPageView(), true );
--i;
diff --git a/sw/source/core/doc/docedt.cxx b/sw/source/core/doc/docedt.cxx
index 5f2c8d0d1d27..4782b010d8ed 100644
--- a/sw/source/core/doc/docedt.cxx
+++ b/sw/source/core/doc/docedt.cxx
@@ -94,8 +94,8 @@ void SaveFlyInRange( const SwNodeRange& rRg, SaveFlyArr& rArr )
SwFormatAnchor const*const pAnchor = &pFormat->GetAnchor();
SwPosition const*const pAPos = pAnchor->GetContentAnchor();
if (pAPos &&
- ((FLY_AT_PARA == pAnchor->GetAnchorId()) ||
- (FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
+ ((RndStdIds::FLY_AT_PARA == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
rRg.aStart <= pAPos->nNode && pAPos->nNode < rRg.aEnd )
{
SaveFly aSave( pAPos->nNode.GetIndex() - rRg.aStart.GetIndex(),
@@ -137,8 +137,8 @@ void SaveFlyInRange( const SwPaM& rPam, const SwNodeIndex& rInsPos,
const SwPosition* pAPos = pAnchor->GetContentAnchor();
const SwNodeIndex* pContentIdx;
if (pAPos &&
- ((FLY_AT_PARA == pAnchor->GetAnchorId()) ||
- (FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
+ ((RndStdIds::FLY_AT_PARA == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
// do not move if the InsPos is in the ContentArea of the Fly
( nullptr == ( pContentIdx = pFormat->GetContent().GetContentIdx() ) ||
!( *pContentIdx < rInsPos &&
@@ -194,8 +194,8 @@ void DelFlyInRange( const SwNodeIndex& rMkNdIdx,
const SwFormatAnchor &rAnch = pFormat->GetAnchor();
SwPosition const*const pAPos = rAnch.GetContentAnchor();
if (pAPos &&
- ((rAnch.GetAnchorId() == FLY_AT_PARA) ||
- (rAnch.GetAnchorId() == FLY_AT_CHAR)) &&
+ ((rAnch.GetAnchorId() == RndStdIds::FLY_AT_PARA) ||
+ (rAnch.GetAnchorId() == RndStdIds::FLY_AT_CHAR)) &&
( bDelFwrd
? rMkNdIdx < pAPos->nNode && pAPos->nNode <= rPtNdIdx
: rPtNdIdx <= pAPos->nNode && pAPos->nNode < rMkNdIdx ))
diff --git a/sw/source/core/doc/docfly.cxx b/sw/source/core/doc/docfly.cxx
index 231c1785d518..7bf6cba8e05e 100644
--- a/sw/source/core/doc/docfly.cxx
+++ b/sw/source/core/doc/docfly.cxx
@@ -218,7 +218,7 @@ static Point lcl_FindAnchorLayPos( SwDoc& rDoc, const SwFormatAnchor& rAnch,
if( rDoc.getIDocumentLayoutAccess().GetCurrentViewShell() )
switch( rAnch.GetAnchorId() )
{
- case FLY_AS_CHAR:
+ case RndStdIds::FLY_AS_CHAR:
if( pFlyFormat && rAnch.GetContentAnchor() )
{
const SwFrame* pOld = static_cast<const SwFlyFrameFormat*>(pFlyFormat)->GetFrame( &aRet );
@@ -227,8 +227,8 @@ static Point lcl_FindAnchorLayPos( SwDoc& rDoc, const SwFormatAnchor& rAnch,
}
break;
- case FLY_AT_PARA:
- case FLY_AT_CHAR: // LAYER_IMPL
+ case RndStdIds::FLY_AT_PARA:
+ case RndStdIds::FLY_AT_CHAR: // LAYER_IMPL
if( rAnch.GetContentAnchor() )
{
const SwPosition *pPos = rAnch.GetContentAnchor();
@@ -239,7 +239,7 @@ static Point lcl_FindAnchorLayPos( SwDoc& rDoc, const SwFormatAnchor& rAnch,
}
break;
- case FLY_AT_FLY: // LAYER_IMPL
+ case RndStdIds::FLY_AT_FLY: // LAYER_IMPL
if( rAnch.GetContentAnchor() )
{
const SwFlyFrameFormat* pFormat = static_cast<SwFlyFrameFormat*>(rAnch.GetContentAnchor()->
@@ -250,7 +250,7 @@ static Point lcl_FindAnchorLayPos( SwDoc& rDoc, const SwFormatAnchor& rAnch,
}
break;
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PAGE:
{
sal_uInt16 nPgNum = rAnch.GetPageNum();
const SwPageFrame *pPage = static_cast<SwPageFrame*>(rDoc.getIDocumentLayoutAccess().GetCurrentLayout()->Lower());
@@ -285,9 +285,9 @@ sal_Int8 SwDoc::SetFlyFrameAnchor( SwFrameFormat& rFormat, SfxItemSet& rSet, boo
RndStdIds nNew = aNewAnch.GetAnchorId();
// Is the new anchor valid?
- if( !aNewAnch.GetContentAnchor() && (FLY_AT_FLY == nNew ||
- (FLY_AT_PARA == nNew) || (FLY_AS_CHAR == nNew) ||
- (FLY_AT_CHAR == nNew) ))
+ if( !aNewAnch.GetContentAnchor() && (RndStdIds::FLY_AT_FLY == nNew ||
+ (RndStdIds::FLY_AT_PARA == nNew) || (RndStdIds::FLY_AS_CHAR == nNew) ||
+ (RndStdIds::FLY_AT_CHAR == nNew) ))
{
return IGNOREANCHOR;
}
@@ -303,7 +303,7 @@ sal_Int8 SwDoc::SetFlyFrameAnchor( SwFrameFormat& rFormat, SfxItemSet& rSet, boo
// kind of a show!
rFormat.DelFrames();
- if ( FLY_AS_CHAR == nOld )
+ if ( RndStdIds::FLY_AS_CHAR == nOld )
{
// We need to handle InContents in a special way:
// The TextAttribut needs to be destroyed which, unfortunately, also
@@ -334,7 +334,7 @@ sal_Int8 SwDoc::SetFlyFrameAnchor( SwFrameFormat& rFormat, SfxItemSet& rSet, boo
const SfxPoolItem* pItem;
switch( nNew )
{
- case FLY_AS_CHAR:
+ case RndStdIds::FLY_AS_CHAR:
// If no position attributes are received, we have to make sure
// that no forbidden automatic alignment is left.
{
@@ -364,10 +364,10 @@ sal_Int8 SwDoc::SetFlyFrameAnchor( SwFrameFormat& rFormat, SfxItemSet& rSet, boo
}
break;
- case FLY_AT_PARA:
- case FLY_AT_CHAR: // LAYER_IMPL
- case FLY_AT_FLY: // LAYER_IMPL
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PARA:
+ case RndStdIds::FLY_AT_CHAR: // LAYER_IMPL
+ case RndStdIds::FLY_AT_FLY: // LAYER_IMPL
+ case RndStdIds::FLY_AT_PAGE:
{
// If no position attributes are coming in, we correct the position in a way
// such that the fly's document coordinates are preserved.
@@ -381,7 +381,7 @@ sal_Int8 SwDoc::SetFlyFrameAnchor( SwFrameFormat& rFormat, SfxItemSet& rSet, boo
if( text::HoriOrientation::NONE == aOldH.GetHoriOrient() && ( !pItem ||
aOldH.GetPos() == static_cast<const SwFormatHoriOrient*>(pItem)->GetPos() ))
{
- SwTwips nPos = (FLY_AS_CHAR == nOld) ? 0 : aOldH.GetPos();
+ SwTwips nPos = (RndStdIds::FLY_AS_CHAR == nOld) ? 0 : aOldH.GetPos();
nPos += aOldAnchorPos.getX() - aNewAnchorPos.getX();
if( pItem )
@@ -403,7 +403,7 @@ sal_Int8 SwDoc::SetFlyFrameAnchor( SwFrameFormat& rFormat, SfxItemSet& rSet, boo
if( text::VertOrientation::NONE == aOldV.GetVertOrient() && (!pItem ||
aOldV.GetPos() == static_cast<const SwFormatVertOrient*>(pItem)->GetPos() ) )
{
- SwTwips nPos = (FLY_AS_CHAR == nOld) ? 0 : aOldV.GetPos();
+ SwTwips nPos = (RndStdIds::FLY_AS_CHAR == nOld) ? 0 : aOldV.GetPos();
nPos += aOldAnchorPos.getY() - aNewAnchorPos.getY();
if( pItem )
{
@@ -766,7 +766,7 @@ bool SwDoc::ChgAnchor( const SdrMarkList& _rMrkList,
// anchored as character.
std::unique_ptr<const SwPosition> xOldAsCharAnchorPos;
const RndStdIds eOldAnchorType = pContact->GetAnchorId();
- if ( !_bSameOnly && eOldAnchorType == FLY_AS_CHAR )
+ if ( !_bSameOnly && eOldAnchorType == RndStdIds::FLY_AS_CHAR )
{
xOldAsCharAnchorPos.reset(new SwPosition(pContact->GetContentAnchor()));
}
@@ -781,8 +781,8 @@ bool SwDoc::ChgAnchor( const SdrMarkList& _rMrkList,
switch ( _eAnchorType )
{
- case FLY_AT_PARA:
- case FLY_AT_CHAR:
+ case RndStdIds::FLY_AT_PARA:
+ case RndStdIds::FLY_AT_CHAR:
{
const Point aNewPoint = ( pOldAnchorFrame->IsVertical() ||
pOldAnchorFrame->IsRightToLeft() )
@@ -808,7 +808,7 @@ bool SwDoc::ChgAnchor( const SdrMarkList& _rMrkList,
}
break;
- case FLY_AT_FLY: // LAYER_IMPL
+ case RndStdIds::FLY_AT_FLY: // LAYER_IMPL
{
// Search the closest SwFlyFrame starting from the upper left corner.
SwFrame *pTextFrame;
@@ -834,10 +834,10 @@ bool SwDoc::ChgAnchor( const SdrMarkList& _rMrkList,
break;
}
- aNewAnch.SetType( FLY_AT_PAGE );
+ aNewAnch.SetType( RndStdIds::FLY_AT_PAGE );
SAL_FALLTHROUGH;
}
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PAGE:
{
pNewAnchorFrame = getIDocumentLayoutAccess().GetCurrentLayout()->Lower();
while ( pNewAnchorFrame && !pNewAnchorFrame->Frame().IsInside( aPt ) )
@@ -848,7 +848,7 @@ bool SwDoc::ChgAnchor( const SdrMarkList& _rMrkList,
aNewAnch.SetPageNum( static_cast<const SwPageFrame*>(pNewAnchorFrame)->GetPhyPageNum());
}
break;
- case FLY_AS_CHAR:
+ case RndStdIds::FLY_AS_CHAR:
if( _bSameOnly ) // Change of position/size
{
if( !pOldAnchorFrame )
@@ -871,7 +871,7 @@ bool SwDoc::ChgAnchor( const SdrMarkList& _rMrkList,
bUnmark = ( 0 != i );
Point aPoint( aPt );
aPoint.setX(aPoint.getX() - 1); // Do not load in the DrawObj!
- aNewAnch.SetType( FLY_AS_CHAR );
+ aNewAnch.SetType( RndStdIds::FLY_AS_CHAR );
SwPosition aPos( *static_cast<const SwContentFrame*>(pNewAnchorFrame)->GetNode() );
if ( pNewAnchorFrame->Frame().IsInside( aPoint ) )
{
@@ -905,7 +905,7 @@ bool SwDoc::ChgAnchor( const SdrMarkList& _rMrkList,
OSL_ENSURE( false, "unexpected AnchorId." );
}
- if ( (FLY_AS_CHAR != _eAnchorType) &&
+ if ( (RndStdIds::FLY_AS_CHAR != _eAnchorType) &&
pNewAnchorFrame &&
( !_bSameOnly || pNewAnchorFrame != pOldAnchorFrame ) )
{
@@ -1013,8 +1013,8 @@ SwChainRet SwDoc::Chainable( const SwFrameFormat &rSource, const SwFrameFormat &
const SwFormatAnchor& rAnchor = pSpzFrameFm->GetAnchor();
sal_uLong nTstSttNd;
// #i20622# - to-frame anchored objects are allowed.
- if ( ((rAnchor.GetAnchorId() == FLY_AT_PARA) ||
- (rAnchor.GetAnchorId() == FLY_AT_CHAR)) &&
+ if ( ((rAnchor.GetAnchorId() == RndStdIds::FLY_AT_PARA) ||
+ (rAnchor.GetAnchorId() == RndStdIds::FLY_AT_CHAR)) &&
nullptr != rAnchor.GetContentAnchor() &&
nFlySttNd <= ( nTstSttNd =
rAnchor.GetContentAnchor()->nNode.GetIndex() ) &&
@@ -1034,9 +1034,9 @@ SwChainRet SwDoc::Chainable( const SwFrameFormat &rSource, const SwFrameFormat &
&rDstAnchor = rDest.GetAnchor();
sal_uLong nEndOfExtras = GetNodes().GetEndOfExtras().GetIndex();
bool bAllowed = false;
- if ( FLY_AT_PAGE == rSrcAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AT_PAGE == rSrcAnchor.GetAnchorId() )
{
- if ( (FLY_AT_PAGE == rDstAnchor.GetAnchorId()) ||
+ if ( (RndStdIds::FLY_AT_PAGE == rDstAnchor.GetAnchorId()) ||
( rDstAnchor.GetContentAnchor() &&
rDstAnchor.GetContentAnchor()->nNode.GetIndex() > nEndOfExtras ))
bAllowed = true;
diff --git a/sw/source/core/doc/docglbl.cxx b/sw/source/core/doc/docglbl.cxx
index 4facb1feac1f..f4b0afb0d8da 100644
--- a/sw/source/core/doc/docglbl.cxx
+++ b/sw/source/core/doc/docglbl.cxx
@@ -379,8 +379,8 @@ bool SwDoc::SplitDoc( sal_uInt16 eDocType, const OUString& rPath, bool bOutline,
SwPosition const*const pAPos =
pAnchor->GetContentAnchor();
if (pAPos &&
- ((FLY_AT_PARA == pAnchor->GetAnchorId()) ||
- (FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
+ ((RndStdIds::FLY_AT_PARA == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
aSIdx <= pAPos->nNode &&
pAPos->nNode < aEIdx )
{
diff --git a/sw/source/core/doc/doclay.cxx b/sw/source/core/doc/doclay.cxx
index 7a59d8ca5391..0685cf164a9f 100644
--- a/sw/source/core/doc/doclay.cxx
+++ b/sw/source/core/doc/doclay.cxx
@@ -206,19 +206,19 @@ SwFlyFrameFormat* SwDoc::MakeFlySection_( const SwPosition& rAnchPos,
// #i107811# Assure that at-page anchored fly frames have a page num or a
// content anchor set.
if ( !pAnchor ||
- ( FLY_AT_PAGE != pAnchor->GetAnchorId() &&
+ ( RndStdIds::FLY_AT_PAGE != pAnchor->GetAnchorId() &&
!pAnchor->GetContentAnchor() ) ||
- ( FLY_AT_PAGE == pAnchor->GetAnchorId() &&
+ ( RndStdIds::FLY_AT_PAGE == pAnchor->GetAnchorId() &&
!pAnchor->GetContentAnchor() &&
pAnchor->GetPageNum() == 0 ) )
{
// set it again, needed for Undo
SwFormatAnchor aAnch( pFormat->GetAnchor() );
- if (pAnchor && (FLY_AT_FLY == pAnchor->GetAnchorId()))
+ if (pAnchor && (RndStdIds::FLY_AT_FLY == pAnchor->GetAnchorId()))
{
SwPosition aPos( *rAnchPos.nNode.GetNode().FindFlyStartNode() );
aAnch.SetAnchor( &aPos );
- eAnchorId = FLY_AT_FLY;
+ eAnchorId = RndStdIds::FLY_AT_FLY;
}
else
{
@@ -229,7 +229,7 @@ SwFlyFrameFormat* SwDoc::MakeFlySection_( const SwPosition& rAnchPos,
}
eAnchorId = aAnch.GetAnchorId();
- if ( FLY_AT_PAGE != eAnchorId || !pAnchor || aAnch.GetPageNum() == 0)
+ if ( RndStdIds::FLY_AT_PAGE != eAnchorId || !pAnchor || aAnch.GetPageNum() == 0)
{
aAnch.SetAnchor( &rAnchPos );
}
@@ -239,7 +239,7 @@ SwFlyFrameFormat* SwDoc::MakeFlySection_( const SwPosition& rAnchPos,
else
eAnchorId = pFormat->GetAnchor().GetAnchorId();
- if ( FLY_AS_CHAR == eAnchorId )
+ if ( RndStdIds::FLY_AS_CHAR == eAnchorId )
{
const sal_Int32 nStt = rAnchPos.nContent.GetIndex();
SwTextNode * pTextNode = rAnchPos.nNode.GetNode().GetTextNode();
@@ -299,7 +299,7 @@ SwFlyFrameFormat* SwDoc::MakeFlySection( RndStdIds eAnchorType,
SwFrameFormat* pFrameFormat, bool bCalledFromShell )
{
SwFlyFrameFormat* pFormat = nullptr;
- if ( !pAnchorPos && (FLY_AT_PAGE != eAnchorType) )
+ if ( !pAnchorPos && (RndStdIds::FLY_AT_PAGE != eAnchorType) )
{
const SwFormatAnchor* pAnch;
if( (pFlySet && SfxItemState::SET == pFlySet->GetItemState(
@@ -307,7 +307,7 @@ SwFlyFrameFormat* SwDoc::MakeFlySection( RndStdIds eAnchorType,
( pFrameFormat && SfxItemState::SET == pFrameFormat->GetItemState(
RES_ANCHOR, true, reinterpret_cast<const SfxPoolItem**>(&pAnch) )) )
{
- if ( (FLY_AT_PAGE != pAnch->GetAnchorId()) )
+ if ( (RndStdIds::FLY_AT_PAGE != pAnch->GetAnchorId()) )
{
pAnchorPos = pAnch->GetContentAnchor();
}
@@ -481,7 +481,7 @@ static bool lcl_TstFlyRange( const SwPaM* pPam, const SwPosition* pFlyPos,
const SwPosition* pPaMEnd = pTmp->End();
const sal_uInt32 nPamStartIndex = pPaMStart->nNode.GetIndex();
const sal_uInt32 nPamEndIndex = pPaMEnd->nNode.GetIndex();
- if (FLY_AT_PARA == nAnchorId)
+ if (RndStdIds::FLY_AT_PARA == nAnchorId)
bOk = (nPamStartIndex < nFlyIndex && nPamEndIndex > nFlyIndex) ||
(((nPamStartIndex == nFlyIndex) && (pPaMStart->nContent.GetIndex() == 0)) &&
(nPamEndIndex > nFlyIndex));
@@ -519,10 +519,10 @@ SwPosFlyFrames SwDoc::GetAllFlyFormats( const SwPaM* pCmpRange, bool bDrawAlso,
const SwFormatAnchor& rAnchor = pFly->GetAnchor();
SwPosition const*const pAPos = rAnchor.GetContentAnchor();
if (pAPos &&
- ((FLY_AT_PARA == rAnchor.GetAnchorId()) ||
- (FLY_AT_FLY == rAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == rAnchor.GetAnchorId()) ||
- ((FLY_AS_CHAR == rAnchor.GetAnchorId()) && bAsCharAlso)))
+ ((RndStdIds::FLY_AT_PARA == rAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_FLY == rAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId()) ||
+ ((RndStdIds::FLY_AS_CHAR == rAnchor.GetAnchorId()) && bAsCharAlso)))
{
if( pCmpRange &&
!lcl_TstFlyRange( pCmpRange, pAPos, rAnchor.GetAnchorId() ))
@@ -556,9 +556,9 @@ SwPosFlyFrames SwDoc::GetAllFlyFormats( const SwPaM* pCmpRange, bool bDrawAlso,
continue;
const SwFormatAnchor& rAnchor = pFly->GetAnchor();
- if ((FLY_AT_PARA != rAnchor.GetAnchorId()) &&
- (FLY_AT_FLY != rAnchor.GetAnchorId()) &&
- (FLY_AT_CHAR != rAnchor.GetAnchorId()))
+ if ((RndStdIds::FLY_AT_PARA != rAnchor.GetAnchorId()) &&
+ (RndStdIds::FLY_AT_FLY != rAnchor.GetAnchorId()) &&
+ (RndStdIds::FLY_AT_CHAR != rAnchor.GetAnchorId()))
{
const SwContentFrame * pContentFrame = pPage->FindFirstBodyContent();
if ( !pContentFrame )
@@ -791,7 +791,7 @@ lcl_InsertLabel(SwDoc & rDoc, SwTextFormatColls *const pTextFormatCollTable,
// To avoid this, we disconnect the attribute from the Format.
const SwFormatAnchor& rAnchor = pNewFormat->GetAnchor();
- if ( FLY_AS_CHAR == rAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AS_CHAR == rAnchor.GetAnchorId() )
{
const SwPosition *pPos = rAnchor.GetContentAnchor();
SwTextNode *pTextNode = pPos->nNode.GetNode().GetTextNode();
@@ -849,7 +849,7 @@ lcl_InsertLabel(SwDoc & rDoc, SwTextFormatColls *const pTextFormatCollTable,
pNewSet->Put( SvxULSpaceItem(RES_UL_SPACE) );
// The old one is paragraph-bound to the paragraph in the new one.
- SwFormatAnchor aAnch( FLY_AT_PARA );
+ SwFormatAnchor aAnch( RndStdIds::FLY_AT_PARA );
SwNodeIndex aAnchIdx( *pNewFormat->GetContent().GetContentIdx(), 1 );
pNew = aAnchIdx.GetNode().GetTextNode();
SwPosition aPos( aAnchIdx );
@@ -1108,7 +1108,7 @@ lcl_InsertDrawLabel( SwDoc & rDoc, SwTextFormatColls *const pTextFormatCollTable
pNewFormat->SetFormatAttr( *pNewSet );
const SwFormatAnchor& rAnchor = pNewFormat->GetAnchor();
- if ( FLY_AS_CHAR == rAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AS_CHAR == rAnchor.GetAnchorId() )
{
const SwPosition *pPos = rAnchor.GetContentAnchor();
SwTextNode *pTextNode = pPos->nNode.GetNode().GetTextNode();
@@ -1149,7 +1149,7 @@ lcl_InsertDrawLabel( SwDoc & rDoc, SwTextFormatColls *const pTextFormatCollTable
pNewSet->Put( SwFormatHoriOrient( 0, text::HoriOrientation::CENTER, text::RelOrientation::FRAME ) );
// The old one is paragraph-bound to the new one's paragraph.
- SwFormatAnchor aAnch( FLY_AT_PARA );
+ SwFormatAnchor aAnch( RndStdIds::FLY_AT_PARA );
SwNodeIndex aAnchIdx( *pNewFormat->GetContent().GetContentIdx(), 1 );
pNew = aAnchIdx.GetNode().GetTextNode();
SwPosition aPos( aAnchIdx );
@@ -1467,7 +1467,7 @@ void SwDoc::SetAllUniqueFlyNames()
if ( !bContainsAtPageObjWithContentAnchor )
{
const SwFormatAnchor& rAnchor = pFlyFormat->GetAnchor();
- if ( (FLY_AT_PAGE == rAnchor.GetAnchorId()) &&
+ if ( (RndStdIds::FLY_AT_PAGE == rAnchor.GetAnchorId()) &&
rAnchor.GetContentAnchor() )
{
bContainsAtPageObjWithContentAnchor = true;
@@ -1553,7 +1553,7 @@ bool SwDoc::IsInHeaderFooter( const SwNodeIndex& rIdx ) const
checkFormats.erase( checkPos );
#endif
const SwFormatAnchor& rAnchor = pFormat->GetAnchor();
- if ((FLY_AT_PAGE == rAnchor.GetAnchorId()) ||
+ if ((RndStdIds::FLY_AT_PAGE == rAnchor.GetAnchorId()) ||
!rAnchor.GetContentAnchor() )
{
return false;
@@ -1602,7 +1602,7 @@ SvxFrameDirection SwDoc::GetTextDirection( const SwPosition& rPos,
{
pItem = nullptr;
const SwFormatAnchor* pAnchor = &pFlyFormat->GetAnchor();
- if ((FLY_AT_PAGE != pAnchor->GetAnchorId()) &&
+ if ((RndStdIds::FLY_AT_PAGE != pAnchor->GetAnchorId()) &&
pAnchor->GetContentAnchor())
{
pFlyFormat = pAnchor->GetContentAnchor()->nNode.
diff --git a/sw/source/core/doc/docnew.cxx b/sw/source/core/doc/docnew.cxx
index 2679bd708879..d579215bcfee 100644
--- a/sw/source/core/doc/docnew.cxx
+++ b/sw/source/core/doc/docnew.cxx
@@ -1225,7 +1225,7 @@ else
{
const SwFrameFormat& rCpyFormat = *pCpyFormat;
SwFormatAnchor aAnchor( rCpyFormat.GetAnchor() );
- if (FLY_AT_PAGE != aAnchor.GetAnchorId())
+ if (RndStdIds::FLY_AT_PAGE != aAnchor.GetAnchorId())
continue;
SAL_INFO( "sw.docappend", "PaAn: " << aAnchor.GetPageNum()
<< " => " << aAnchor.GetPageNum() + pageOffset );
diff --git a/sw/source/core/doc/docsort.cxx b/sw/source/core/doc/docsort.cxx
index c1e47b041d59..f3e1095f8333 100644
--- a/sw/source/core/doc/docsort.cxx
+++ b/sw/source/core/doc/docsort.cxx
@@ -304,7 +304,7 @@ bool SwDoc::SortText(const SwPaM& rPaM, const SwSortOptions& rOpt)
SwFormatAnchor const*const pAnchor = &pFormat->GetAnchor();
SwPosition const*const pAPos = pAnchor->GetContentAnchor();
- if (pAPos && (FLY_AT_PARA == pAnchor->GetAnchorId()) &&
+ if (pAPos && (RndStdIds::FLY_AT_PARA == pAnchor->GetAnchorId()) &&
pStart->nNode <= pAPos->nNode && pAPos->nNode <= pEnd->nNode )
return false;
}
diff --git a/sw/source/core/doc/tblcpy.cxx b/sw/source/core/doc/tblcpy.cxx
index 1addcf3c5ca3..fb1eb20955f8 100644
--- a/sw/source/core/doc/tblcpy.cxx
+++ b/sw/source/core/doc/tblcpy.cxx
@@ -561,8 +561,8 @@ static void lcl_CpyBox( const SwTable& rCpyTable, const SwTableBox* pCpyBox,
SwFormatAnchor const*const pAnchor = &pFly->GetAnchor();
SwPosition const*const pAPos = pAnchor->GetContentAnchor();
if (pAPos &&
- ((FLY_AT_PARA == pAnchor->GetAnchorId()) ||
- (FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
+ ((RndStdIds::FLY_AT_PARA == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
aInsIdx <= pAPos->nNode && pAPos->nNode <= aEndNdIdx )
{
pDoc->getIDocumentLayoutAccess().DelLayoutFormat( pFly );
diff --git a/sw/source/core/docnode/ndtbl.cxx b/sw/source/core/docnode/ndtbl.cxx
index 5a3abcb11420..e81e481cacba 100644
--- a/sw/source/core/docnode/ndtbl.cxx
+++ b/sw/source/core/docnode/ndtbl.cxx
@@ -1689,8 +1689,8 @@ bool SwNodes::TableToText( const SwNodeRange& rRange, sal_Unicode cCh,
const SwFormatAnchor& rAnchor = pFormat->GetAnchor();
SwPosition const*const pAPos = rAnchor.GetContentAnchor();
if (pAPos &&
- ((FLY_AT_PARA == rAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == rAnchor.GetAnchorId())) &&
+ ((RndStdIds::FLY_AT_PARA == rAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId())) &&
nStt <= pAPos->nNode.GetIndex() &&
pAPos->nNode.GetIndex() < nEnd )
{
diff --git a/sw/source/core/docnode/node.cxx b/sw/source/core/docnode/node.cxx
index 4962f734223c..96ec1e018fcd 100644
--- a/sw/source/core/docnode/node.cxx
+++ b/sw/source/core/docnode/node.cxx
@@ -528,7 +528,7 @@ const SwPageDesc* SwNode::FindPageDesc( size_t* pPgDescNdIdx ) const
if( pFormat )
{
const SwFormatAnchor* pAnchor = &pFormat->GetAnchor();
- if ((FLY_AT_PAGE != pAnchor->GetAnchorId()) &&
+ if ((RndStdIds::FLY_AT_PAGE != pAnchor->GetAnchorId()) &&
pAnchor->GetContentAnchor() )
{
pNd = &pAnchor->GetContentAnchor()->nNode.GetNode();
@@ -551,7 +551,7 @@ const SwPageDesc* SwNode::FindPageDesc( size_t* pPgDescNdIdx ) const
break;
}
pAnchor = &pFrameFormat->GetAnchor();
- if ((FLY_AT_PAGE == pAnchor->GetAnchorId()) ||
+ if ((RndStdIds::FLY_AT_PAGE == pAnchor->GetAnchorId()) ||
!pAnchor->GetContentAnchor() )
{
pFlyNd = nullptr;
diff --git a/sw/source/core/docnode/nodes.cxx b/sw/source/core/docnode/nodes.cxx
index ccc50ee39f72..fd5edbf0bfaa 100644
--- a/sw/source/core/docnode/nodes.cxx
+++ b/sw/source/core/docnode/nodes.cxx
@@ -2227,7 +2227,7 @@ void SwNodes::RemoveNode( sal_uLong nDelPos, sal_uLong nSz, bool bDel )
if (pTextNd)
{
pTextNd->RemoveFromList();
- // remove FLY_AS_CHAR *before* adjusting SwNodeIndex
+ // remove RndStdIds::FLY_AS_CHAR *before* adjusting SwNodeIndex
// so their anchor still points to correct node when deleted!
// NOTE: this will call RemoveNode() recursively!
// so adjust our indexes to account for removed nodes
diff --git a/sw/source/core/docnode/swbaslnk.cxx b/sw/source/core/docnode/swbaslnk.cxx
index 4fbd3b7a5137..cc86094b1808 100644
--- a/sw/source/core/docnode/swbaslnk.cxx
+++ b/sw/source/core/docnode/swbaslnk.cxx
@@ -439,10 +439,10 @@ const SwNode* SwBaseLink::GetAnchor() const
const SwFormatAnchor& rAnchor = pFormat->GetAnchor();
SwPosition const*const pAPos = rAnchor.GetContentAnchor();
if (pAPos &&
- ((FLY_AS_CHAR == rAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == rAnchor.GetAnchorId()) ||
- (FLY_AT_FLY == rAnchor.GetAnchorId()) ||
- (FLY_AT_PARA == rAnchor.GetAnchorId())))
+ ((RndStdIds::FLY_AS_CHAR == rAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_FLY == rAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_PARA == rAnchor.GetAnchorId())))
{
return &pAPos->nNode.GetNode();
}
diff --git a/sw/source/core/draw/dcontact.cxx b/sw/source/core/draw/dcontact.cxx
index e2e67a0de425..291ae1a58e5e 100644
--- a/sw/source/core/draw/dcontact.cxx
+++ b/sw/source/core/draw/dcontact.cxx
@@ -1751,7 +1751,7 @@ void SwDrawContact::ConnectToLayout( const SwFormatAnchor* pAnch )
switch ( pAnch->GetAnchorId() )
{
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PAGE:
{
sal_uInt16 nPgNum = pAnch->GetPageNum();
SwViewShell *pShell = pDrawFrameFormat->getIDocumentLayoutAccess().GetCurrentViewShell();
@@ -1775,12 +1775,12 @@ void SwDrawContact::ConnectToLayout( const SwFormatAnchor* pAnch )
}
break;
- case FLY_AT_CHAR:
- case FLY_AT_PARA:
- case FLY_AT_FLY:
- case FLY_AS_CHAR:
+ case RndStdIds::FLY_AT_CHAR:
+ case RndStdIds::FLY_AT_PARA:
+ case RndStdIds::FLY_AT_FLY:
+ case RndStdIds::FLY_AS_CHAR:
{
- if ( pAnch->GetAnchorId() == FLY_AS_CHAR )
+ if ( pAnch->GetAnchorId() == RndStdIds::FLY_AS_CHAR )
{
ClrContourCache( GetMaster() );
}
@@ -1792,7 +1792,7 @@ void SwDrawContact::ConnectToLayout( const SwFormatAnchor* pAnch )
SwModify *pModify = nullptr;
if( pAnch->GetContentAnchor() )
{
- if ( pAnch->GetAnchorId() == FLY_AT_FLY )
+ if ( pAnch->GetAnchorId() == RndStdIds::FLY_AT_FLY )
{
SwNodeIndex aIdx( pAnch->GetContentAnchor()->nNode );
SwContentNode* pCNd = pDrawFrameFormat->GetDoc()->GetNodes().GoNext( &aIdx );
@@ -1844,14 +1844,14 @@ void SwDrawContact::ConnectToLayout( const SwFormatAnchor* pAnch )
if( bAdd )
{
- if ( FLY_AT_FLY == pAnch->GetAnchorId() && !pFrame->IsFlyFrame() )
+ if ( RndStdIds::FLY_AT_FLY == pAnch->GetAnchorId() && !pFrame->IsFlyFrame() )
{
pFrame = pFrame->FindFlyFrame();
assert(pFrame);
}
// find correct follow for as character anchored objects
- if ((pAnch->GetAnchorId() == FLY_AS_CHAR) &&
+ if ((pAnch->GetAnchorId() == RndStdIds::FLY_AS_CHAR) &&
pFrame->IsTextFrame() )
{
pFrame = lcl_GetFlyInContentAnchor(
@@ -1869,7 +1869,7 @@ void SwDrawContact::ConnectToLayout( const SwFormatAnchor* pAnch )
{
// append 'virtual' drawing object
SwDrawVirtObj* pDrawVirtObj = AddVirtObj();
- if ( pAnch->GetAnchorId() == FLY_AS_CHAR )
+ if ( pAnch->GetAnchorId() == RndStdIds::FLY_AS_CHAR )
{
ClrContourCache( pDrawVirtObj );
}
@@ -1878,7 +1878,7 @@ void SwDrawContact::ConnectToLayout( const SwFormatAnchor* pAnch )
pDrawVirtObj->ActionChanged();
}
- if ( pAnch->GetAnchorId() == FLY_AS_CHAR )
+ if ( pAnch->GetAnchorId() == RndStdIds::FLY_AS_CHAR )
{
pFrame->InvalidatePrt();
}
diff --git a/sw/source/core/draw/dview.cxx b/sw/source/core/draw/dview.cxx
index 9e95c18c6464..7ef966ca04b3 100644
--- a/sw/source/core/draw/dview.cxx
+++ b/sw/source/core/draw/dview.cxx
@@ -218,7 +218,7 @@ void SwDrawView::AddCustomHdl()
}
const SwFormatAnchor &rAnchor = pFrameFormat->GetAnchor();
- if (FLY_AS_CHAR == rAnchor.GetAnchorId())
+ if (RndStdIds::FLY_AS_CHAR == rAnchor.GetAnchorId())
return;
const SwFrame* pAnch;
@@ -227,7 +227,7 @@ void SwDrawView::AddCustomHdl()
Point aPos(aAnchorPoint);
- if ( FLY_AT_CHAR == rAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId() )
{
// #i28701# - use last character rectangle saved at object
// in order to avoid a format of the anchor frame
@@ -843,7 +843,7 @@ void SwDrawView::CheckPossibilities()
// #i972: protect position if it is a Math object anchored 'as char' and baseline alignment is activated
SwDoc* pDoc = Imp().GetShell()->GetDoc();
const bool bProtectMathPos = SotExchange::IsMath( xObj->getClassID() )
- && FLY_AS_CHAR == pFly->GetFormat()->GetAnchor().GetAnchorId()
+ && RndStdIds::FLY_AS_CHAR == pFly->GetFormat()->GetAnchor().GetAnchorId()
&& pDoc->GetDocumentSettingManager().get( DocumentSettingId::MATH_BASELINE_ALIGNMENT );
if (bProtectMathPos)
bMoveProtect = true;
@@ -867,7 +867,7 @@ void SwDrawView::CheckPossibilities()
OSL_FAIL( "<SwDrawView::CheckPossibilities()> - missing frame format" );
bProtect = true;
}
- else if ((FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId()) &&
+ else if ((RndStdIds::FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId()) &&
rMrkList.GetMarkCount() > 1 )
{
bProtect = true;
diff --git a/sw/source/core/edit/autofmt.cxx b/sw/source/core/edit/autofmt.cxx
index 9a094f7dacce..cfc87bffeec7 100644
--- a/sw/source/core/edit/autofmt.cxx
+++ b/sw/source/core/edit/autofmt.cxx
@@ -353,7 +353,7 @@ bool SwAutoFormat::HasObjects( const SwNode& rNd )
for( auto pFrameFormat : rFormats )
{
const SwFormatAnchor& rAnchor = pFrameFormat->GetAnchor();
- if ((FLY_AT_PAGE != rAnchor.GetAnchorId()) &&
+ if ((RndStdIds::FLY_AT_PAGE != rAnchor.GetAnchorId()) &&
rAnchor.GetContentAnchor() &&
&rAnchor.GetContentAnchor()->nNode.GetNode() == &rNd )
{
diff --git a/sw/source/core/fields/expfld.cxx b/sw/source/core/fields/expfld.cxx
index 2e10443c0aa9..8bdac6feb728 100644
--- a/sw/source/core/fields/expfld.cxx
+++ b/sw/source/core/fields/expfld.cxx
@@ -179,20 +179,20 @@ const SwTextNode* GetBodyTextNode( const SwDoc& rDoc, SwPosition& rPos,
const SwFormatAnchor &rAnchor = pFlyFormat->GetAnchor();
- if( FLY_AT_FLY == rAnchor.GetAnchorId() )
+ if( RndStdIds::FLY_AT_FLY == rAnchor.GetAnchorId() )
{
// the fly needs to be attached somewhere, so ask it
pLayout = static_cast<const SwLayoutFrame*>(static_cast<const SwFlyFrame*>(pLayout)->GetAnchorFrame());
continue;
}
- else if ((FLY_AT_PARA == rAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == rAnchor.GetAnchorId()) ||
- (FLY_AS_CHAR == rAnchor.GetAnchorId()))
+ else if ((RndStdIds::FLY_AT_PARA == rAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AS_CHAR == rAnchor.GetAnchorId()))
{
OSL_ENSURE( rAnchor.GetContentAnchor(), "no valid position" );
rPos = *rAnchor.GetContentAnchor();
pTextNode = rPos.nNode.GetNode().GetTextNode();
- if ( FLY_AT_PARA == rAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AT_PARA == rAnchor.GetAnchorId() )
{
const_cast<SwTextNode*>(pTextNode)->MakeStartIndex(
&rPos.nContent );
diff --git a/sw/source/core/frmedt/fecopy.cxx b/sw/source/core/frmedt/fecopy.cxx
index d62e5cea4300..bd4f5e6b1ee0 100644
--- a/sw/source/core/frmedt/fecopy.cxx
+++ b/sw/source/core/frmedt/fecopy.cxx
@@ -108,8 +108,8 @@ bool SwFEShell::Copy( SwDoc* pClpDoc, const OUString* pNewClpText )
SwFormatAnchor const*const pAnchor = &pFly->GetAnchor();
SwPosition const*const pAPos = pAnchor->GetContentAnchor();
if (pAPos &&
- ((FLY_AT_PARA == pAnchor->GetAnchorId()) ||
- (FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
+ ((RndStdIds::FLY_AT_PARA == pAnchor->GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == pAnchor->GetAnchorId())) &&
aSttIdx <= pAPos->nNode && pAPos->nNode <= aEndNdIdx )
{
pClpDoc->getIDocumentLayoutAccess().DelLayoutFormat( pFly );
@@ -139,13 +139,13 @@ bool SwFEShell::Copy( SwDoc* pClpDoc, const OUString* pNewClpText )
SwFrameFormat* pFlyFormat = pFly->GetFormat();
SwFormatAnchor aAnchor( pFlyFormat->GetAnchor() );
- if ((FLY_AT_PARA == aAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
- (FLY_AT_FLY == aAnchor.GetAnchorId()) ||
- (FLY_AS_CHAR == aAnchor.GetAnchorId()))
+ if ((RndStdIds::FLY_AT_PARA == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_FLY == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AS_CHAR == aAnchor.GetAnchorId()))
{
SwPosition aPos( aSttIdx );
- if ( FLY_AS_CHAR == aAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AS_CHAR == aAnchor.GetAnchorId() )
{
aPos.nContent.Assign( pTextNd, 0 );
}
@@ -165,7 +165,7 @@ bool SwFEShell::Copy( SwDoc* pClpDoc, const OUString* pNewClpText )
assert( !inserted && "Fly not contained in Spz-Array" );
}
- if ( FLY_AS_CHAR == aAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AS_CHAR == aAnchor.GetAnchorId() )
{
// JP 13.02.99 Bug 61863: if a frameselection is passed to the
// clipboard, it should be found at pasting. Therefore
@@ -196,7 +196,7 @@ bool SwFEShell::Copy( SwDoc* pClpDoc, const OUString* pNewClpText )
{
SfxItemSet aSet( pClpDoc->GetAttrPool(), aFrameFormatSetRange );
- SwFormatAnchor aAnchor( FLY_AT_PARA );
+ SwFormatAnchor aAnchor( RndStdIds::FLY_AT_PARA );
aAnchor.SetAnchor( &aPos );
aSet.Put( aAnchor );
@@ -211,10 +211,10 @@ bool SwFEShell::Copy( SwDoc* pClpDoc, const OUString* pNewClpText )
SwDrawContact *pContact = static_cast<SwDrawContact*>(GetUserCall( pObj ));
SwFrameFormat *pFormat = pContact->GetFormat();
SwFormatAnchor aAnchor( pFormat->GetAnchor() );
- if ((FLY_AT_PARA == aAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
- (FLY_AT_FLY == aAnchor.GetAnchorId()) ||
- (FLY_AS_CHAR == aAnchor.GetAnchorId()))
+ if ((RndStdIds::FLY_AT_PARA == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_FLY == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AS_CHAR == aAnchor.GetAnchorId()))
{
aAnchor.SetAnchor( &aPos );
}
@@ -263,7 +263,7 @@ static bool lcl_SetAnchor( const SwPosition& rPos, const SwNode& rNd, SwFlyFrame
{
bRet = false;
}
- else if ( FLY_AT_FLY == rAnchor.GetAnchorId() )
+ else if ( RndStdIds::FLY_AT_FLY == rAnchor.GetAnchorId() )
{
if( pTmpFly )
{
@@ -274,7 +274,7 @@ static bool lcl_SetAnchor( const SwPosition& rPos, const SwNode& rNd, SwFlyFrame
}
else
{
- rAnchor.SetType( FLY_AT_PAGE );
+ rAnchor.SetType( RndStdIds::FLY_AT_PAGE );
rAnchor.SetPageNum( rDestShell.GetPageNumber( rInsPt ) );
const SwFrame *pPg = pTmpFrame->FindPageFrame();
rNewPos = pPg->Frame().Pos();
@@ -321,7 +321,7 @@ bool SwFEShell::CopyDrawSel( SwFEShell* pDestShell, const Point& rSttPt,
// insert into the group, when it belongs to an entered group
// or when the object is not anchored as a character
if( pSrcDrwView->IsGroupEntered() ||
- (FLY_AS_CHAR != rAnchor.GetAnchorId()) )
+ (RndStdIds::FLY_AS_CHAR != rAnchor.GetAnchorId()) )
{
SdrObject* pNew = pDestDoc->CloneSdrObj( *pObj, bIsMove &&
@@ -337,10 +337,10 @@ bool SwFEShell::CopyDrawSel( SwFEShell* pDestShell, const Point& rSttPt,
SwFormatAnchor aAnchor( rAnchor );
Point aNewAnch;
- if ((FLY_AT_PARA == aAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
- (FLY_AT_FLY == aAnchor.GetAnchorId()) ||
- (FLY_AS_CHAR == aAnchor.GetAnchorId()))
+ if ((RndStdIds::FLY_AT_PARA == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_FLY == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AS_CHAR == aAnchor.GetAnchorId()))
{
if ( this == pDestShell )
{
@@ -370,7 +370,7 @@ bool SwFEShell::CopyDrawSel( SwFEShell* pDestShell, const Point& rSttPt,
aNewAnch, false );
}
}
- else if ( FLY_AT_PAGE == aAnchor.GetAnchorId() )
+ else if ( RndStdIds::FLY_AT_PAGE == aAnchor.GetAnchorId() )
{
aAnchor.SetPageNum( pDestShell->GetPageNumber( rInsPt ) );
const SwRootFrame* pTmpRoot = pDestShell->GetLayout();
@@ -397,7 +397,7 @@ bool SwFEShell::CopyDrawSel( SwFEShell* pDestShell, const Point& rSttPt,
if ( pFormat )
{
SdrObject* pNew = pFormat->FindSdrObject();
- if ( FLY_AS_CHAR != aAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AS_CHAR != aAnchor.GetAnchorId() )
{
Point aPos( rInsPt );
aPos -= aNewAnch;
@@ -482,10 +482,10 @@ bool SwFEShell::Copy( SwFEShell* pDestShell, const Point& rSttPt,
bRet = true;
Point aNewAnch;
- if ((FLY_AT_PARA == aAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
- (FLY_AT_FLY == aAnchor.GetAnchorId()) ||
- (FLY_AS_CHAR == aAnchor.GetAnchorId()))
+ if ((RndStdIds::FLY_AT_PARA == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_FLY == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AS_CHAR == aAnchor.GetAnchorId()))
{
if ( this == pDestShell )
{
@@ -524,7 +524,7 @@ bool SwFEShell::Copy( SwFEShell* pDestShell, const Point& rSttPt,
aNewAnch, GetDoc() == pDestShell->GetDoc());
}
}
- else if ( FLY_AT_PAGE == aAnchor.GetAnchorId() )
+ else if ( RndStdIds::FLY_AT_PAGE == aAnchor.GetAnchorId() )
{
aAnchor.SetPageNum( pDestShell->GetPageNumber( rInsPt ) );
const SwRootFrame* pTmpRoot = pDestShell->GetLayout();
@@ -541,7 +541,7 @@ bool SwFEShell::Copy( SwFEShell* pDestShell, const Point& rSttPt,
SwFrameFormat *pOldFormat = pFlyFormat;
pFlyFormat = pDestShell->GetDoc()->getIDocumentLayoutAccess().CopyLayoutFormat( *pFlyFormat, aAnchor, true, true );
- if ( FLY_AS_CHAR != aAnchor.GetAnchorId() )
+ if ( RndStdIds::FLY_AS_CHAR != aAnchor.GetAnchorId() )
{
Point aPos( rInsPt );
aPos -= aNewAnch;
@@ -908,7 +908,7 @@ bool SwFEShell::Paste( SwDoc* pClpDoc )
if( Imp()->GetDrawView()->IsGroupEntered() &&
RES_DRAWFRMFMT == pCpyFormat->Which() &&
- (FLY_AS_CHAR != pCpyFormat->GetAnchor().GetAnchorId()) )
+ (RndStdIds::FLY_AS_CHAR != pCpyFormat->GetAnchor().GetAnchorId()) )
{
const SdrObject* pSdrObj = pCpyFormat->FindSdrObject();
if( pSdrObj )
@@ -956,9 +956,9 @@ bool SwFEShell::Paste( SwDoc* pClpDoc )
if( bInsWithFormat )
{
SwFormatAnchor aAnchor( pCpyFormat->GetAnchor() );
- if ((FLY_AT_PARA == aAnchor.GetAnchorId()) ||
- (FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
- (FLY_AS_CHAR == aAnchor.GetAnchorId()))
+ if ((RndStdIds::FLY_AT_PARA == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AT_CHAR == aAnchor.GetAnchorId()) ||
+ (RndStdIds::FLY_AS_CHAR == aAnchor.GetAnchorId()))
{
SwPosition* pPos = rPaM.GetPoint();
// allow shapes (no controls) in header/footer
@@ -976,11 +976,11 @@ bool SwFEShell::Paste( SwDoc* pClpDoc )
aAnchor.SetAnchor( pPos );
}
- else if ( FLY_AT_PAGE == aAnchor.GetAnchorId() )
+ else if ( RndStdIds::FLY_AT_PAGE == aAnchor.GetAnchorId() )
{
aAnchor.SetPageNum( GetPhyPageNum() );
}
- else if( FLY_AT_FLY == aAnchor.GetAnchorId() )
+ else if( RndStdIds::FLY_AT_FLY == aAnchor.GetAnchorId() )
{
Point aPt;
(void)lcl_SetAnchor( *rPaM.GetPoint(), rPaM.GetNode(),
@@ -1171,7 +1171,7 @@ bool SwFEShell::PastePages( SwFEShell& rToFill, sal_uInt16 nStartPage, sal_uInt1
for ( auto pCpyFormat : *GetDoc()->GetSpzFrameFormats() )
{
SwFormatAnchor aAnchor( pCpyFormat->GetAnchor() );
- if ((FLY_AT_PAGE == aAnchor.GetAnchorId()) &&
+ if ((RndStdIds::FLY_AT_PAGE == aAnchor.GetAnchorId()) &&
aAnchor.GetPageNum() >= nStartPage && aAnchor.GetPageNum() <= nEndPage)
{
aAnchor.SetPageNum( aAnchor.GetPageNum() - nStartPage + 1);
diff --git a/sw/source/core/frmedt/fefly1.cxx b/sw/source/core/frmedt/fefly1.cxx
index 394454cc7ba9..c495a35abf73 100644
--- a/sw/source/core/frmedt/fefly1.cxx
+++ b/sw/source/core/frmedt/fefly1.cxx
@@ -97,7 +97,7 @@ static bool lcl_SetNewFlyPos( const SwNode& rNode, SwFormatAnchor& rAnchor,
const SwPageFrame *pPg = pCFrame ? pCFrame->FindPageFrame() : nullptr;
rAnchor.SetPageNum( pPg ? pPg->GetPhyPageNum() : 1 );
- rAnchor.SetType( FLY_AT_PAGE );
+ rAnchor.SetType( RndStdIds::FLY_AT_PAGE );
}
return bRet;
}
@@ -117,9 +117,9 @@ static bool lcl_FindAnchorPos(
Point aTmpPnt( rPt );
switch( nNew )
{
- case FLY_AS_CHAR: // also include this?
- case FLY_AT_PARA:
- case FLY_AT_CHAR: // LAYER_IMPL
+ case RndStdIds::FLY_AS_CHAR: // also include this?
+ case RndStdIds::FLY_AT_PARA:
+ case RndStdIds::FLY_AT_CHAR: // LAYER_IMPL
{
// starting from the upper-left corner of the Fly,
// search nearest ContentFrame
@@ -133,7 +133,7 @@ static bool lcl_FindAnchorPos(
}
SwPosition aPos( *static_cast<const SwContentFrame*>(pNewAnch)->GetNode() );
- if ((FLY_AT_CHAR == nNew) || (FLY_AS_CHAR == nNew))
+ if ((RndStdIds::FLY_AT_CHAR == nNew) || (RndStdIds::FLY_AS_CHAR == nNew))
{
// textnode should be found, as only in those
// a content bound frame can be anchored
@@ -159,7 +159,7 @@ static bool lcl_FindAnchorPos(
}
break;
- case FLY_AT_FLY: // LAYER_IMPL
+ case RndStdIds::FLY_AT_FLY: // LAYER_IMPL
{
// starting from the upper-left corner of the Fly
// search nearest SwFlyFrame
@@ -180,10 +180,10 @@ static bool lcl_FindAnchorPos(
}
}
- aNewAnch.SetType( nNew = FLY_AT_PAGE );
+ aNewAnch.SetType( nNew = RndStdIds::FLY_AT_PAGE );
SAL_FALLTHROUGH;
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PAGE:
pNewAnch = rFrame.FindPageFrame();
aNewAnch.SetPageNum( pNewAnch->GetPhyPageNum() );
break;
@@ -214,8 +214,8 @@ bool sw_ChkAndSetNewAnchor(
SwDoc* pDoc = const_cast<SwDoc*>(rFormat.GetDoc());
#if OSL_DEBUG_LEVEL > 0
- OSL_ENSURE( !(nNew == FLY_AT_PAGE &&
- (FLY_AT_PARA==nOld || FLY_AT_CHAR==nOld || FLY_AS_CHAR==nOld ) &&
+ OSL_ENSURE( !(nNew == RndStdIds::FLY_AT_PAGE &&
+ (RndStdIds::FLY_AT_PARA==nOld || RndStdIds::FLY_AT_CHAR==nOld || RndStdIds::FLY_AS_CHAR==nOld ) &&
pDoc->IsInHeaderFooter( rOldAnch.GetContentAnchor()->nNode )),
"forbidden anchor change in Head/Foot." );
#endif
@@ -316,7 +316,7 @@ const SwFrameFormat* SwFEShell::IsFlyInFly()
SdrObject *pObj = rMrkList.GetMark( 0 )->GetMarkedSdrObj();
SwFrameFormat *pFormat = FindFrameFormat( pObj );
- if( pFormat && FLY_AT_FLY == pFormat->GetAnchor().GetAnchorId() )
+ if( pFormat && RndStdIds::FLY_AT_FLY == pFormat->GetAnchor().GetAnchorId() )
{
const SwFrame* pFly;
if (SwVirtFlyDrawObj* pFlyObj = dynamic_cast<SwVirtFlyDrawObj *>(pObj))
@@ -405,7 +405,7 @@ Point SwFEShell::FindAnchorPos( const Point& rAbsPos, bool bMoveIt )
SwFrameFormat& rFormat = pAnchoredObj->GetFrameFormat();
const RndStdIds nAnchorId = rFormat.GetAnchor().GetAnchorId();
- if ( FLY_AS_CHAR == nAnchorId )
+ if ( RndStdIds::FLY_AS_CHAR == nAnchorId )
return aRet;
bool bFlyFrame = dynamic_cast<SwVirtFlyDrawObj *>(pObj) != nullptr;
@@ -425,7 +425,7 @@ Point SwFEShell::FindAnchorPos( const Point& rAbsPos, bool bMoveIt )
const SwFrame* pOldAnch = pFly->GetAnchorFrame();
if( !pOldAnch )
return aRet;
- if ( FLY_AT_PAGE != nAnchorId )
+ if ( RndStdIds::FLY_AT_PAGE != nAnchorId )
{
pFooterOrHeader = pContent->FindFooterOrHeader();
}
@@ -450,7 +450,7 @@ Point SwFEShell::FindAnchorPos( const Point& rAbsPos, bool bMoveIt )
Point aTmpPnt( rAbsPos );
GetLayout()->GetCursorOfst( &aPos, aTmpPnt, &aState );
if (aPos.nNode != GetDoc()->GetNodes().GetEndOfExtras().GetIndex()
- && (nAnchorId != FLY_AT_CHAR || !PosInsideInputField(aPos)))
+ && (nAnchorId != RndStdIds::FLY_AT_CHAR || !PosInsideInputField(aPos)))
{
SwContentNode* pCNode = aPos.nNode.GetNode().GetContentNode();
assert(pCNode);
@@ -460,7 +460,7 @@ Point SwFEShell::FindAnchorPos( const Point& rAbsPos, bool bMoveIt )
const SwFrame *pNewAnch = nullptr;
if( pTextFrame != nullptr )
{
- if ( FLY_AT_PAGE == nAnchorId )
+ if ( RndStdIds::FLY_AT_PAGE == nAnchorId )
{
pNewAnch = pTextFrame->FindPageFrame();
}
@@ -468,7 +468,7 @@ Point SwFEShell::FindAnchorPos( const Point& rAbsPos, bool bMoveIt )
{
pNewAnch = ::FindAnchor( pTextFrame, rAbsPos );
- if( FLY_AT_FLY == nAnchorId ) // LAYER_IMPL
+ if( RndStdIds::FLY_AT_FLY == nAnchorId ) // LAYER_IMPL
{
pNewAnch = pNewAnch->FindFlyFrame();
}
@@ -495,12 +495,12 @@ Point SwFEShell::FindAnchorPos( const Point& rAbsPos, bool bMoveIt )
{
aRet = pNewAnch->GetFrameAnchorPos( ::HasWrap( pObj ) );
- if ( bMoveIt || (nAnchorId == FLY_AT_CHAR) )
+ if ( bMoveIt || (nAnchorId == RndStdIds::FLY_AT_CHAR) )
{
SwFormatAnchor aAnch( rFormat.GetAnchor() );
switch ( nAnchorId )
{
- case FLY_AT_PARA:
+ case RndStdIds::FLY_AT_PARA:
{
SwPosition pos = *aAnch.GetContentAnchor();
pos.nNode = *pTextFrame->GetNode();
@@ -508,14 +508,14 @@ Point SwFEShell::FindAnchorPos( const Point& rAbsPos, bool bMoveIt )
aAnch.SetAnchor( &pos );
break;
}
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PAGE:
{
aAnch.SetPageNum( static_cast<const SwPageFrame*>(pNewAnch)->
GetPhyPageNum() );
break;
}
- case FLY_AT_FLY:
+ case RndStdIds::FLY_AT_FLY:
{
SwPosition aPos( *static_cast<const SwFlyFrame*>(pNewAnch)->GetFormat()->
GetContent().GetContentIdx() );
@@ -523,7 +523,7 @@ Point SwFEShell::FindAnchorPos( const Point& rAbsPos, bool bMoveIt )
break;
}
- case FLY_AT_CHAR:
+ case RndStdIds::FLY_AT_CHAR:
{
SwPosition pos = *aAnch.GetContentAnchor();
Point aTmpPnt( rAbsPos );
@@ -631,24 +631,24 @@ const SwFrameFormat *SwFEShell::NewFlyFrame( const SfxItemSet& rSet, bool bAnchV
RndStdIds eRndId = rAnch.GetAnchorId();
switch( eRndId )
{
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PAGE:
if( !rAnch.GetPageNum() ) //HotFix: Bug in UpdateByExample
rAnch.SetPageNum( 1 );
break;
- case FLY_AT_FLY:
- case FLY_AT_PARA:
- case FLY_AT_CHAR:
- case FLY_AS_CHAR:
+ case RndStdIds::FLY_AT_FLY:
+ case RndStdIds::FLY_AT_PARA:
+ case RndStdIds::FLY_AT_CHAR:
+ case RndStdIds::FLY_AS_CHAR:
if( !bAnchValid )
{
- if( FLY_AT_FLY != eRndId )
+ if( RndStdIds::FLY_AT_FLY != eRndId )
{
rAnch.SetAnchor( &rPos );
}
else if( lcl_SetNewFlyPos( rPos.nNode.GetNode(), rAnch, aPt ) )
{
- eRndId = FLY_AT_PAGE;
+ eRndId = RndStdIds::FLY_AT_PAGE;
}
}
break;
@@ -667,14 +667,14 @@ const SwFrameFormat *SwFEShell::NewFlyFrame( const SfxItemSet& rSet, bool bAnchV
SwFormatVertOrient aOldV;
SwFormatHoriOrient aOldH;
- if ( FLY_AT_PAGE != eRndId )
+ if ( RndStdIds::FLY_AT_PAGE != eRndId )
{
// First as with page link. Paragraph/character link on if
// everything was shifted. Then the position is valid!
// JP 13.05.98: if necessary also convert the horizontal/vertical
// orientation, to prevent correction during re-anchoring
pOldAnchor = new SwFormatAnchor( rAnch );
- const_cast<SfxItemSet&>(rSet).Put( SwFormatAnchor( FLY_AT_PAGE, 1 ) );
+ const_cast<SfxItemSet&>(rSet).Put( SwFormatAnchor( RndStdIds::FLY_AT_PAGE, 1 ) );
const SfxPoolItem* pItem;
if( SfxItemState::SET == rSet.GetItemState( RES_HORI_ORIENT, false, &pItem )
@@ -708,7 +708,7 @@ const SwFrameFormat *SwFEShell::NewFlyFrame( const SfxItemSet& rSet, bool bAnchV
const SwFrame* pAnch = ::FindAnchor( GetLayout(), aPt );
SwPosition aPos( *static_cast<const SwContentFrame*>(pAnch)->GetNode() );
- if ( FLY_AS_CHAR == eRndId )
+ if ( RndStdIds::FLY_AS_CHAR == eRndId )
{
aPos.nContent.Assign( const_cast<SwContentFrame*>(static_cast<const SwContentFrame*>(pAnch))->GetNode(), 0 );
}
@@ -789,22 +789,22 @@ void SwFEShell::Insert( const OUString& rGrfName, const OUString& rFltName,
SwFormatAnchor* pAnchor = const_cast<SwFormatAnchor*>(static_cast<const SwFormatAnchor*>(pItem));
switch( pAnchor->GetAnchorId())
{
- case FLY_AT_PARA:
- case FLY_AT_CHAR: // LAYER_IMPL
- case FLY_AS_CHAR:
+ case RndStdIds::FLY_AT_PARA:
+ case RndStdIds::FLY_AT_CHAR: // LAYER_IMPL
+ case RndStdIds::FLY_AS_CHAR:
if( !pAnchor->GetContentAnchor() )
{
pAnchor->SetAnchor( pCursor->GetPoint() );
}
break;
- case FLY_AT_FLY:
+ case RndStdIds::FLY_AT_FLY:
if( !pAnchor->GetContentAnchor() )
{
lcl_SetNewFlyPos( pCursor->GetNode(),
*pAnchor, GetCursorDocPos() );
}
break;
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PAGE:
if( !pAnchor->GetPageNum() )
{
pAnchor->SetPageNum( pCursor->GetPageNum(
@@ -882,7 +882,7 @@ void SwFEShell::InsertDrawObj( SdrObject& rDrawObj,
SET_CURR_SHELL( this );
SfxItemSet rFlyAttrSet( GetDoc()->GetAttrPool(), aFrameFormatSetRange );
- rFlyAttrSet.Put( SwFormatAnchor( FLY_AT_PARA ));
+ rFlyAttrSet.Put( SwFormatAnchor( RndStdIds::FLY_AT_PARA ));
// #i89920#
rFlyAttrSet.Put( SwFormatSurround( css::text::WrapTextMode_THROUGHT ) );
rDrawObj.SetLayer( getIDocumentDrawModelAccess().GetHeavenId() );
@@ -926,7 +926,7 @@ void SwFEShell::GetPageObjs( std::vector<SwFrameFormat*>& rFillArr )
for( auto pFormat : *mpDoc->GetSpzFrameFormats() )
{
- if (FLY_AT_PAGE == pFormat->GetAnchor().GetAnchorId())
+ if (RndStdIds::FLY_AT_PAGE == pFormat->GetAnchor().GetAnchorId())
{
rFillArr.push_back( pFormat );
}
@@ -952,7 +952,7 @@ void SwFEShell::SetPageObjsNewPage( std::vector<SwFrameFormat*>& rFillArr )
// FlyFormat is still valid, therefore process
SwFormatAnchor aNewAnchor( pFormat->GetAnchor() );
- if ((FLY_AT_PAGE != aNewAnchor.GetAnchorId()) ||
+ if ((RndStdIds::FLY_AT_PAGE != aNewAnchor.GetAnchorId()) ||
0 >= ( nNewPage = aNewAnchor.GetPageNum() + 1 ) )
// chaos::Anchor has been changed or invalid page number,
// therefore: do not change!
@@ -1003,11 +1003,11 @@ bool SwFEShell::GetFlyFrameAttr( SfxItemSet &rSet ) const
const SwFormatAnchor* pAnchor = static_cast<const SwFormatAnchor*>(pItem);
RndStdIds eType = pAnchor->GetAnchorId();
- if ( FLY_AT_PAGE != eType )
+ if ( RndStdIds::FLY_AT_PAGE != eType )
{
// OD 12.11.2003 #i22341# - content anchor of anchor item is needed.
// Thus, don't overwrite anchor item by default contructed anchor item.
- if ( FLY_AS_CHAR == eType )
+ if ( RndStdIds::FLY_AS_CHAR == eType )
{
rSet.ClearItem( RES_OPAQUE );
rSet.ClearItem( RES_SURROUND );
@@ -1664,7 +1664,7 @@ ObjCntType SwFEShell::GetObjCntType( const SdrObject& rObj )
OSL_FAIL( "<SwFEShell::GetObjCntType(..)> - missing frame format" );
eType = OBJCNT_NONE;
}
- else if ( FLY_AS_CHAR != pFrameFormat->GetAnchor().GetAnchorId() )
+ else if ( RndStdIds::FLY_AS_CHAR != pFrameFormat->GetAnchor().GetAnchorId() )
{
eType = OBJCNT_GROUPOBJ;
}
@@ -1998,7 +1998,7 @@ void SwFEShell::AlignFormulaToBaseline( const uno::Reference < embed::XEmbeddedO
SwFrameFormat * pFrameFormat = pFly ? pFly->GetFormat() : nullptr;
// baseline to baseline alignment should only be applied to formulas anchored as char
- if ( pFly && pFrameFormat && FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId() )
+ if ( pFly && pFrameFormat && RndStdIds::FLY_AS_CHAR == pFrameFormat->GetAnchor().GetAnchorId() )
{
// get baseline from Math object
uno::Any aBaseline;
diff --git a/sw/source/core/frmedt/feshview.cxx b/sw/source/core/frmedt/feshview.cxx
index 9ff50efd80c9..9df3d900447f 100644
--- a/sw/source/core/frmedt/feshview.cxx
+++ b/sw/source/core/frmedt/feshview.cxx
@@ -362,7 +362,7 @@ bool SwFEShell::MoveAnchor( SwMove nDir )
SwFrameFormat& rFormat = pAnchoredObj->GetFrameFormat();
SwFormatAnchor aAnch( rFormat.GetAnchor() );
RndStdIds nAnchorId = aAnch.GetAnchorId();
- if ( FLY_AS_CHAR == nAnchorId )
+ if ( RndStdIds::FLY_AS_CHAR == nAnchorId )
return false;
if( pOld->IsVertical() )
{
@@ -384,7 +384,7 @@ bool SwFEShell::MoveAnchor( SwMove nDir )
}
}
switch ( nAnchorId ) {
- case FLY_AT_PAGE:
+ case RndStdIds::FLY_AT_PAGE:
{
OSL_ENSURE( pOld->IsPageFrame(), "Wrong anchor, page expected." );
if( SwMove::UP == nDir )
@@ -398,7 +398,7 @@ bool SwFEShell::MoveAnchor( SwMove nDir )
}
break;
}
- case FLY_AT_CHAR:
+ case RndStdIds::FLY_AT_CHAR:
{
OSL_ENSURE( pOld->IsContentFrame(), "Wrong anchor, page expected." );
if( SwMove::LEFT == nDir || SwMove::RIGHT == nDir )
@@ -433,7 +433,7 @@ bool SwFEShell::MoveAnchor( SwMove nDir )
}
SAL_FALLTHROUGH;
}
- case FLY_AT_PARA:
+ case RndStdIds::FLY_AT_PARA:
{
OSL_ENSURE( pOld->IsContentFrame(), "Wrong anchor, page expected." );
... etc. - the rest is truncated
More information about the Libreoffice-commits
mailing list