summaryrefslogtreecommitdiff
path: root/sw/source/core
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-08-04 15:17:10 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-08-04 16:06:22 +0200
commitc14f1abc49de68591298437b33b07feeddeb5a5d (patch)
tree04923fa380f401559d16bbd98c3d484158d1708e /sw/source/core
parentfa1be538cdb0f15aff717aa8583c191194609266 (diff)
loplugin:constparams in sw part4
Change-Id: Ic42b2691869b61ba906222db893e284d8b9c39c1 Reviewed-on: https://gerrit.libreoffice.org/40767 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source/core')
-rw-r--r--sw/source/core/inc/SwXMLBlockExport.hxx4
-rw-r--r--sw/source/core/inc/flyfrm.hxx2
-rw-r--r--sw/source/core/inc/layouter.hxx8
-rw-r--r--sw/source/core/inc/pagefrm.hxx12
-rw-r--r--sw/source/core/inc/paintfrm.hxx2
-rw-r--r--sw/source/core/inc/swfont.hxx22
-rw-r--r--sw/source/core/inc/txtfrm.hxx4
-rw-r--r--sw/source/core/layout/fly.cxx2
-rw-r--r--sw/source/core/layout/layouter.cxx12
-rw-r--r--sw/source/core/layout/paintfrm.cxx68
-rw-r--r--sw/source/core/layout/trvlfrm.cxx2
-rw-r--r--sw/source/core/layout/virtoutp.hxx2
-rw-r--r--sw/source/core/ole/ndole.cxx8
-rw-r--r--sw/source/core/swg/SwXMLBlockExport.cxx4
-rw-r--r--sw/source/core/swg/swblocks.cxx2
-rw-r--r--sw/source/core/table/swtable.cxx2
-rw-r--r--sw/source/core/text/EnhancedPDFExportHelper.cxx2
-rw-r--r--sw/source/core/text/atrhndl.hxx2
-rw-r--r--sw/source/core/text/atrstck.cxx2
-rw-r--r--sw/source/core/text/inftxt.cxx2
-rw-r--r--sw/source/core/text/inftxt.hxx6
-rw-r--r--sw/source/core/text/itratr.cxx7
-rw-r--r--sw/source/core/text/itratr.hxx8
-rw-r--r--sw/source/core/text/itrform2.cxx8
-rw-r--r--sw/source/core/text/itrform2.hxx10
-rw-r--r--sw/source/core/text/itrpaint.hxx2
-rw-r--r--sw/source/core/text/itrtxt.hxx8
-rw-r--r--sw/source/core/text/porfly.cxx6
-rw-r--r--sw/source/core/text/porfly.hxx4
-rw-r--r--sw/source/core/text/pormulti.cxx4
-rw-r--r--sw/source/core/text/portxt.cxx2
-rw-r--r--sw/source/core/text/portxt.hxx2
-rw-r--r--sw/source/core/text/redlnitr.cxx4
-rw-r--r--sw/source/core/text/redlnitr.hxx2
-rw-r--r--sw/source/core/text/txtcache.cxx6
-rw-r--r--sw/source/core/text/txtcache.hxx2
-rw-r--r--sw/source/core/text/txtfld.cxx2
-rw-r--r--sw/source/core/text/txtfrm.cxx4
-rw-r--r--sw/source/core/text/txtftn.cxx4
-rw-r--r--sw/source/core/text/txthyph.cxx2
-rw-r--r--sw/source/core/text/widorp.cxx2
-rw-r--r--sw/source/core/text/widorp.hxx2
-rw-r--r--sw/source/core/tox/tox.cxx2
-rw-r--r--sw/source/core/txtnode/atrftn.cxx4
-rw-r--r--sw/source/core/txtnode/fntcache.cxx2
-rw-r--r--sw/source/core/txtnode/ndhints.cxx4
-rw-r--r--sw/source/core/txtnode/ndtxt.cxx2
-rw-r--r--sw/source/core/txtnode/swfont.cxx12
-rw-r--r--sw/source/core/txtnode/thints.cxx4
-rw-r--r--sw/source/core/txtnode/txtatr2.cxx4
-rw-r--r--sw/source/core/txtnode/txtedt.cxx2
51 files changed, 148 insertions, 149 deletions
diff --git a/sw/source/core/inc/SwXMLBlockExport.hxx b/sw/source/core/inc/SwXMLBlockExport.hxx
index 7e9e74a17736..d858cfecfcc1 100644
--- a/sw/source/core/inc/SwXMLBlockExport.hxx
+++ b/sw/source/core/inc/SwXMLBlockExport.hxx
@@ -34,7 +34,7 @@ public:
const css::uno::Reference< css::uno::XComponentContext >& rContext,
SwXMLTextBlocks & rBlocks,
const OUString &rFileName,
- css::uno::Reference< css::xml::sax::XDocumentHandler> &rHandler);
+ css::uno::Reference< css::xml::sax::XDocumentHandler> const &rHandler);
ErrCode exportDoc( enum ::xmloff::token::XMLTokenEnum eClass = ::xmloff::token::XML_TOKEN_INVALID ) override;
void ExportAutoStyles_() override {}
@@ -52,7 +52,7 @@ public:
const css::uno::Reference< css::uno::XComponentContext >& rContext,
SwXMLTextBlocks & rBlocks,
const OUString &rFileName,
- css::uno::Reference< css::xml::sax::XDocumentHandler> &rHandler);
+ css::uno::Reference< css::xml::sax::XDocumentHandler> const &rHandler);
ErrCode exportDoc(enum ::xmloff::token::XMLTokenEnum /*eClass*/) override { return ERRCODE_NONE; }
void exportDoc(const OUString & rText);
diff --git a/sw/source/core/inc/flyfrm.hxx b/sw/source/core/inc/flyfrm.hxx
index 4e284eaea530..1faae2876a74 100644
--- a/sw/source/core/inc/flyfrm.hxx
+++ b/sw/source/core/inc/flyfrm.hxx
@@ -163,7 +163,7 @@ public:
SwTwips Shrink_( SwTwips, bool bTst );
SwTwips Grow_ ( SwTwips, bool bTst );
- void Invalidate_( SwPageFrame *pPage = nullptr );
+ void Invalidate_( SwPageFrame const *pPage = nullptr );
bool FrameSizeChg( const SwFormatFrameSize & );
diff --git a/sw/source/core/inc/layouter.hxx b/sw/source/core/inc/layouter.hxx
index fd9ac92aa556..00b5bf1ed2d6 100644
--- a/sw/source/core/inc/layouter.hxx
+++ b/sw/source/core/inc/layouter.hxx
@@ -44,7 +44,7 @@ class SwLayouter
SwEndnoter* mpEndnoter;
SwLooping* mpLooping;
void CollectEndnotes_( SwSectionFrame* pSect );
- bool StartLooping( SwPageFrame* pPage );
+ bool StartLooping( SwPageFrame const * pPage );
// --> #i28701#
SwMovedFwdFramesByObjPos* mpMovedFwdFrames;
@@ -95,7 +95,7 @@ private:
public:
SwLayouter();
~SwLayouter();
- void InsertEndnotes( SwSectionFrame* pSect );
+ void InsertEndnotes( SwSectionFrame const * pSect );
void CollectEndnote( SwFootnoteFrame* pFootnote );
bool HasEndnotes() const;
@@ -104,8 +104,8 @@ public:
void LoopingLouieLight( const SwDoc& rDoc, const SwTextFrame& rFrame );
static void CollectEndnotes( SwDoc* pDoc, SwSectionFrame* pSect );
- static bool Collecting( SwDoc* pDoc, SwSectionFrame* pSect, SwFootnoteFrame* pFootnote );
- static bool StartLoopControl( SwDoc* pDoc, SwPageFrame *pPage );
+ static bool Collecting( SwDoc* pDoc, SwSectionFrame const * pSect, SwFootnoteFrame* pFootnote );
+ static bool StartLoopControl( SwDoc* pDoc, SwPageFrame const *pPage );
// --> #i28701#
static void ClearMovedFwdFrames( const SwDoc& _rDoc );
diff --git a/sw/source/core/inc/pagefrm.hxx b/sw/source/core/inc/pagefrm.hxx
index 3bb152e40cef..e6b4d92777d2 100644
--- a/sw/source/core/inc/pagefrm.hxx
+++ b/sw/source/core/inc/pagefrm.hxx
@@ -89,7 +89,7 @@ class SwPageFrame: public SwFootnoteBossFrame
static void GetHorizontalShadowRect( const SwRect& _rPageRect,
const SwViewShell* _pViewShell,
- OutputDevice* pRenderContext,
+ OutputDevice const * pRenderContext,
SwRect& _orBottomShadowRect,
bool bPaintLeftShadow,
bool bPaintRightShadow,
@@ -136,7 +136,7 @@ public:
inline const SwContentFrame *FindFirstBodyContent() const;
inline const SwContentFrame *FindLastBodyContent() const;
- SwRect GetBoundRect(OutputDevice* pOutputDevice) const;
+ SwRect GetBoundRect(OutputDevice const * pOutputDevice) const;
// Specialized GetContentPos() for Field in Frames
void GetContentPosition( const Point &rPt, SwPosition &rPos ) const;
@@ -169,7 +169,7 @@ public:
virtual void Paste( SwFrame* pParent, SwFrame* pSibling = nullptr ) override;
virtual void CheckDirection( bool bVert ) override;
void CheckGrid( bool bInvalidate );
- void PaintGrid( OutputDevice* pOut, SwRect &rRect ) const;
+ void PaintGrid( OutputDevice const * pOut, SwRect const &rRect ) const;
bool HasGrid() const { return m_bHasGrid; }
void PaintDecorators( ) const;
@@ -248,7 +248,7 @@ public:
has to be generated.
*/
void PaintMarginArea( const SwRect& _rOutputRect,
- SwViewShell* _pViewShell ) const;
+ SwViewShell const * _pViewShell ) const;
/** paint page border and shadow
@@ -295,7 +295,7 @@ public:
*/
static void GetBorderAndShadowBoundRect( const SwRect& _rPageRect,
const SwViewShell* _pViewShell,
- OutputDevice* pRenderContext,
+ OutputDevice const * pRenderContext,
SwRect& _orBorderAndShadowBoundRect,
const bool bLeftShadow,
const bool bRightShadow,
@@ -303,7 +303,7 @@ public:
);
static void PaintNotesSidebar(const SwRect& _rPageRect, SwViewShell* _pViewShell, sal_uInt16 nPageNum, bool bRight);
- static void PaintNotesSidebarArrows(const Point &rMiddleFirst, const Point &rMiddleSecond, SwViewShell* _pViewShell, const Color& rColorUp, const Color& rColorDown);
+ static void PaintNotesSidebarArrows(const Point &rMiddleFirst, const Point &rMiddleSecond, SwViewShell const * _pViewShell, const Color& rColorUp, const Color& rColorDown);
/**
asks the page on which side a margin should be shown, e.g for notes
returns true for left side, false for right side
diff --git a/sw/source/core/inc/paintfrm.hxx b/sw/source/core/inc/paintfrm.hxx
index b7d6097fd5a5..ec05b04901db 100644
--- a/sw/source/core/inc/paintfrm.hxx
+++ b/sw/source/core/inc/paintfrm.hxx
@@ -22,7 +22,7 @@
extern Color aGlobalRetoucheColor;
-void SwCalcPixStatics( OutputDevice *pOut );
+void SwCalcPixStatics( OutputDevice const *pOut );
#endif // INCLUDED_SW_SOURCE_CORE_INC_PAINTFRM_HXX
diff --git a/sw/source/core/inc/swfont.hxx b/sw/source/core/inc/swfont.hxx
index e59826889d85..04804c482269 100644
--- a/sw/source/core/inc/swfont.hxx
+++ b/sw/source/core/inc/swfont.hxx
@@ -62,16 +62,16 @@ class SwSubFont : public SvxFont
sal_uInt16 CalcEscAscent( const sal_uInt16 nOldAscent ) const;
sal_uInt16 CalcEscHeight( const sal_uInt16 nOldHeight,
const sal_uInt16 nOldAscent ) const;
- void CalcEsc( SwDrawTextInfo& rInf, Point& rPos );
+ void CalcEsc( SwDrawTextInfo const & rInf, Point& rPos );
SwSubFont& operator=( const SwSubFont &rFont );
short CheckKerning_( );
bool ChgFnt( SwViewShell const *pSh, OutputDevice& rOut );
- bool IsSymbol( SwViewShell *pSh );
- sal_uInt16 GetAscent( SwViewShell *pSh, const OutputDevice& rOut );
- sal_uInt16 GetHeight( SwViewShell *pSh, const OutputDevice& rOut );
+ bool IsSymbol( SwViewShell const *pSh );
+ sal_uInt16 GetAscent( SwViewShell const *pSh, const OutputDevice& rOut );
+ sal_uInt16 GetHeight( SwViewShell const *pSh, const OutputDevice& rOut );
Size GetTextSize_( SwDrawTextInfo& rInf );
Size GetCapitalSize( SwDrawTextInfo& rInf );
void DrawText_( SwDrawTextInfo &rInf, const bool bGrey );
@@ -186,14 +186,14 @@ public:
const SvxFont& GetActualFont() const { return m_aSub[m_nActual]; }
// gets a MagicNumber via SwFntAccess
- void GoMagic( SwViewShell *pSh, SwFontScript nWhich );
+ void GoMagic( SwViewShell const *pSh, SwFontScript nWhich );
// set background color
void SetBackColor( Color* pNewColor );
const Color* GetBackColor() const{ return m_pBackColor.get(); }
void SetHighlightColor( const Color& aNewColor );
const Color& GetHighlightColor() const { return m_aHighlightColor; }
- void ChkMagic( SwViewShell *pSh, SwFontScript nWhich )
+ void ChkMagic( SwViewShell const *pSh, SwFontScript nWhich )
{ if( !m_aSub[ nWhich ].m_pMagic ) GoMagic( pSh, nWhich ); }
void GetMagic( const void* &rMagic, sal_uInt16 &rIdx, SwFontScript nWhich )
{ rMagic = m_aSub[nWhich].m_pMagic; rIdx = m_aSub[nWhich].m_nFontIndex; }
@@ -267,7 +267,7 @@ public:
const SvxFont &GetFnt( const SwFontScript nWhich ) const
{ return m_aSub[nWhich]; };
- bool IsSymbol( SwViewShell *pSh )
+ bool IsSymbol( SwViewShell const *pSh )
{ return m_aSub[m_nActual].IsSymbol( pSh ); }
FontLineStyle GetUnderline() const { return m_aSub[m_nActual].GetUnderline(); }
const Color& GetUnderColor() const { return m_aUnderColor; }
@@ -297,7 +297,7 @@ public:
{ return m_aSub[nWhich].GetFontSize().Height(); }
// makes the logical font be effective in the OutputDevice
- void ChgPhysFnt( SwViewShell *pSh, OutputDevice& rOut );
+ void ChgPhysFnt( SwViewShell const *pSh, OutputDevice& rOut );
sal_Int32 GetCapitalBreak( SwViewShell const* pSh, const OutputDevice* pOut,
const SwScriptInfo* pScript, const OUString& rText,
@@ -310,7 +310,7 @@ public:
Size GetTextSize_( SwDrawTextInfo& rInf )
{ rInf.SetFont( this ); return m_aSub[m_nActual].GetTextSize_( rInf ); }
- sal_Int32 GetTextBreak( SwDrawTextInfo& rInf, long nTextWidth );
+ sal_Int32 GetTextBreak( SwDrawTextInfo const & rInf, long nTextWidth );
sal_Int32 GetCursorOfst_( SwDrawTextInfo& rInf )
{ return m_aSub[m_nActual].GetCursorOfst_( rInf ); }
@@ -324,9 +324,9 @@ public:
short CheckKerning()
{ return m_aSub[m_nActual].CheckKerning(); }
- sal_uInt16 GetAscent( SwViewShell *pSh, const OutputDevice& rOut )
+ sal_uInt16 GetAscent( SwViewShell const *pSh, const OutputDevice& rOut )
{ return m_aSub[m_nActual].GetAscent( pSh, rOut ); }
- sal_uInt16 GetHeight( SwViewShell *pSh, const OutputDevice& rOut )
+ sal_uInt16 GetHeight( SwViewShell const *pSh, const OutputDevice& rOut )
{ return m_aSub[m_nActual].GetHeight( pSh, rOut ); }
void Invalidate()
diff --git a/sw/source/core/inc/txtfrm.hxx b/sw/source/core/inc/txtfrm.hxx
index e8a20b7dd72e..429abead817a 100644
--- a/sw/source/core/inc/txtfrm.hxx
+++ b/sw/source/core/inc/txtfrm.hxx
@@ -219,7 +219,7 @@ public:
SwRect SmartTagScan();
/// Is called by CollectAutoCmplWords()
- void CollectAutoCmplWrds( SwContentNode* , sal_Int32 );
+ void CollectAutoCmplWrds( SwContentNode const * , sal_Int32 );
/**
* Returns the screen position of rPos. The values are relative to the upper
@@ -514,7 +514,7 @@ public:
void MoveFlyInCnt( SwTextFrame *pNew, sal_Int32 nStart, sal_Int32 nEnd );
/// Calculates the position of FlyInContentFrames
- sal_Int32 CalcFlyPos( SwFrameFormat* pSearch );
+ sal_Int32 CalcFlyPos( SwFrameFormat const * pSearch );
/// Determines the start position and step size of the register
bool FillRegister( SwTwips& rRegStart, sal_uInt16& rRegDiff );
diff --git a/sw/source/core/layout/fly.cxx b/sw/source/core/layout/fly.cxx
index c8e73eab2ee3..dfe7ddb18527 100644
--- a/sw/source/core/layout/fly.cxx
+++ b/sw/source/core/layout/fly.cxx
@@ -990,7 +990,7 @@ bool SwFlyFrame::GetInfo( SfxPoolItem & rInfo ) const
return true; // Continue searching
}
-void SwFlyFrame::Invalidate_( SwPageFrame *pPage )
+void SwFlyFrame::Invalidate_( SwPageFrame const *pPage )
{
InvalidatePage( pPage );
m_bNotifyBack = m_bInvalid = true;
diff --git a/sw/source/core/layout/layouter.cxx b/sw/source/core/layout/layouter.cxx
index 6dc0c80d3c10..4723475526db 100644
--- a/sw/source/core/layout/layouter.cxx
+++ b/sw/source/core/layout/layouter.cxx
@@ -38,7 +38,7 @@ class SwLooping
sal_uInt16 nCount;
sal_uInt16 mnLoopControlStage;
public:
- explicit SwLooping( SwPageFrame* pPage );
+ explicit SwLooping( SwPageFrame const * pPage );
void Control( SwPageFrame* pPage );
void Drastic( SwFrame* pFrame );
bool IsLoopingLouieLight() const { return nCount > LOOP_DETECT - 30; };
@@ -137,7 +137,7 @@ void SwEndnoter::InsertEndnotes()
pSect = nullptr;
}
-SwLooping::SwLooping( SwPageFrame* pPage )
+SwLooping::SwLooping( SwPageFrame const * pPage )
{
OSL_ENSURE( pPage, "Where's my page?" );
nMinPage = pPage->GetPhyPageNum();
@@ -239,7 +239,7 @@ void SwLayouter::CollectEndnote( SwFootnoteFrame* pFootnote )
mpEndnoter->CollectEndnote( pFootnote );
}
-void SwLayouter::InsertEndnotes( SwSectionFrame* pSect )
+void SwLayouter::InsertEndnotes( SwSectionFrame const * pSect )
{
if( !mpEndnoter || mpEndnoter->GetSect() != pSect )
return;
@@ -263,7 +263,7 @@ void SwLayouter::LoopingLouieLight( const SwDoc& rDoc, const SwTextFrame& rFrame
}
}
-bool SwLayouter::StartLooping( SwPageFrame* pPage )
+bool SwLayouter::StartLooping( SwPageFrame const * pPage )
{
if( mpLooping )
return false;
@@ -285,7 +285,7 @@ void SwLayouter::CollectEndnotes( SwDoc* pDoc, SwSectionFrame* pSect )
pDoc->getIDocumentLayoutAccess().GetLayouter()->CollectEndnotes_( pSect );
}
-bool SwLayouter::Collecting( SwDoc* pDoc, SwSectionFrame* pSect, SwFootnoteFrame* pFootnote )
+bool SwLayouter::Collecting( SwDoc* pDoc, SwSectionFrame const * pSect, SwFootnoteFrame* pFootnote )
{
if( !pDoc->getIDocumentLayoutAccess().GetLayouter() )
return false;
@@ -301,7 +301,7 @@ bool SwLayouter::Collecting( SwDoc* pDoc, SwSectionFrame* pSect, SwFootnoteFrame
return false;
}
-bool SwLayouter::StartLoopControl( SwDoc* pDoc, SwPageFrame *pPage )
+bool SwLayouter::StartLoopControl( SwDoc* pDoc, SwPageFrame const *pPage )
{
OSL_ENSURE( pDoc, "No doc, no fun" );
if( !pDoc->getIDocumentLayoutAccess().GetLayouter() )
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx
index 3b0e364f601c..4c23869dad9d 100644
--- a/sw/source/core/layout/paintfrm.cxx
+++ b/sw/source/core/layout/paintfrm.cxx
@@ -169,7 +169,7 @@ public:
bool IsLocked() const { return nLock != 0; }
SubColFlags GetSubColor() const { return nSubColor;}
- bool MakeUnion( const SwRect &rRect, SwPaintProperties &properties );
+ bool MakeUnion( const SwRect &rRect, SwPaintProperties const &properties );
};
#ifdef IOS
@@ -201,9 +201,9 @@ public:
#endif
}
void AddLineRect( const SwRect& rRect, const Color *pColor, const SvxBorderLineStyle nStyle,
- const SwTabFrame *pTab, const SubColFlags nSCol, SwPaintProperties &properties );
- void ConnectEdges( OutputDevice *pOut, SwPaintProperties &properties );
- void PaintLines ( OutputDevice *pOut, SwPaintProperties &properties );
+ const SwTabFrame *pTab, const SubColFlags nSCol, SwPaintProperties const &properties );
+ void ConnectEdges( OutputDevice const *pOut, SwPaintProperties const &properties );
+ void PaintLines ( OutputDevice *pOut, SwPaintProperties const &properties );
void LockLines( bool bLock );
//Limit lines to 100
@@ -212,16 +212,16 @@ public:
class SwSubsRects : public SwLineRects
{
- void RemoveSuperfluousSubsidiaryLines( const SwLineRects &rRects, SwPaintProperties &properties );
+ void RemoveSuperfluousSubsidiaryLines( const SwLineRects &rRects, SwPaintProperties const &properties );
public:
- void PaintSubsidiary( OutputDevice *pOut, const SwLineRects *pRects, SwPaintProperties &properties );
+ void PaintSubsidiary( OutputDevice *pOut, const SwLineRects *pRects, SwPaintProperties const &properties );
};
class BorderLines
{
drawinglayer::primitive2d::Primitive2DContainer m_Lines;
public:
- void AddBorderLine(css::uno::Reference<BorderLinePrimitive2D> const& xLine, SwPaintProperties& properties);
+ void AddBorderLine(css::uno::Reference<BorderLinePrimitive2D> const& xLine, SwPaintProperties const & properties);
drawinglayer::primitive2d::Primitive2DContainer GetBorderLines_Clear()
{
drawinglayer::primitive2d::Primitive2DContainer lines;
@@ -344,7 +344,7 @@ bool isTableBoundariesEnabled()
* For 'small' twip-to-pixel relations (less then 2:1)
* values of <gProp.nSHalfPixelSzW> and <gProp.nSHalfPixelSzH> are set to ZERO
*/
-void SwCalcPixStatics( vcl::RenderContext *pOut )
+void SwCalcPixStatics( vcl::RenderContext const *pOut )
{
// determine 'small' twip-to-pixel relation
bool bSmallTwipToPxRelW = false;
@@ -484,7 +484,7 @@ SwSavePaintStatics::~SwSavePaintStatics()
static sal_uInt8 lcl_TryMergeLines(
pair<double, double> const& mergeA,
pair<double, double> const& mergeB,
- SwPaintProperties& properties)
+ SwPaintProperties const & properties)
{
double const fMergeGap(properties.nSPixelSzW + properties.nSHalfPixelSzW); // NOT static!
// A is above/before B
@@ -558,7 +558,7 @@ lcl_MergeBorderLines(
static rtl::Reference<BorderLinePrimitive2D>
lcl_TryMergeBorderLine(BorderLinePrimitive2D const& rThis,
BorderLinePrimitive2D const& rOther,
- SwPaintProperties& properties)
+ SwPaintProperties const & properties)
{
assert(rThis.getEnd().getX() >= rThis.getStart().getX());
assert(rThis.getEnd().getY() >= rThis.getStart().getY());
@@ -657,7 +657,7 @@ lcl_TryMergeBorderLine(BorderLinePrimitive2D const& rThis,
}
void BorderLines::AddBorderLine(
- css::uno::Reference<BorderLinePrimitive2D> const& xLine, SwPaintProperties& properties)
+ css::uno::Reference<BorderLinePrimitive2D> const& xLine, SwPaintProperties const & properties)
{
for (drawinglayer::primitive2d::Primitive2DContainer::reverse_iterator it = m_Lines.rbegin(); it != m_Lines.rend();
++it)
@@ -686,7 +686,7 @@ SwLineRect::SwLineRect( const SwRect &rRect, const Color *pCol, const SvxBorderL
aColor = *pCol;
}
-bool SwLineRect::MakeUnion( const SwRect &rRect, SwPaintProperties& properties)
+bool SwLineRect::MakeUnion( const SwRect &rRect, SwPaintProperties const & properties)
{
// It has already been tested outside, whether the rectangles have
// the same orientation (horizontal or vertical), color, etc.
@@ -724,7 +724,7 @@ bool SwLineRect::MakeUnion( const SwRect &rRect, SwPaintProperties& properties)
}
void SwLineRects::AddLineRect( const SwRect &rRect, const Color *pCol, const SvxBorderLineStyle nStyle,
- const SwTabFrame *pTab, const SubColFlags nSCol, SwPaintProperties& properties )
+ const SwTabFrame *pTab, const SubColFlags nSCol, SwPaintProperties const & properties )
{
// Loop backwards because lines which can be combined, can usually be painted
// in the same context
@@ -745,7 +745,7 @@ void SwLineRects::AddLineRect( const SwRect &rRect, const Color *pCol, const Svx
aLineRects.push_back( SwLineRect( rRect, pCol, nStyle, pTab, nSCol ) );
}
-void SwLineRects::ConnectEdges( OutputDevice *pOut, SwPaintProperties& properties )
+void SwLineRects::ConnectEdges( OutputDevice const *pOut, SwPaintProperties const & properties )
{
if ( pOut->GetOutDevType() != OUTDEV_PRINTER )
{
@@ -914,7 +914,7 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut, SwPaintProperties& propertie
}
}
-void SwSubsRects::RemoveSuperfluousSubsidiaryLines( const SwLineRects &rRects, SwPaintProperties& properties )
+void SwSubsRects::RemoveSuperfluousSubsidiaryLines( const SwLineRects &rRects, SwPaintProperties const & properties )
{
// All help lines that are covered by any border will be removed or split
for (size_t i = 0; i < aLineRects.size(); ++i)
@@ -1018,7 +1018,7 @@ void SwLineRects::LockLines( bool bLock )
(*it).Lock( bLock );
}
-static void lcl_DrawDashedRect( OutputDevice * pOut, SwLineRect & rLRect )
+static void lcl_DrawDashedRect( OutputDevice * pOut, SwLineRect const & rLRect )
{
long startX = rLRect.Left( ), endX;
long startY = rLRect.Top( ), endY;
@@ -1044,7 +1044,7 @@ static void lcl_DrawDashedRect( OutputDevice * pOut, SwLineRect & rLRect )
sal_uInt32( nHalfLWidth * 2 ), rLRect.GetStyle( ) );
}
-void SwLineRects::PaintLines( OutputDevice *pOut, SwPaintProperties &properties )
+void SwLineRects::PaintLines( OutputDevice *pOut, SwPaintProperties const &properties )
{
// Paint the borders. Sadly two passes are needed.
// Once for the inside and once for the outside edges of tables
@@ -1165,7 +1165,7 @@ void SwLineRects::PaintLines( OutputDevice *pOut, SwPaintProperties &properties
void SwSubsRects::PaintSubsidiary( OutputDevice *pOut,
const SwLineRects *pRects,
- SwPaintProperties& properties )
+ SwPaintProperties const & properties )
{
if ( !aLineRects.empty() )
{
@@ -1428,7 +1428,7 @@ void SwAlignGrfRect( SwRect *pGrfRect, const vcl::RenderContext &rOut )
pGrfRect->SSize( rOut.PixelToLogic( aPxRect.GetSize() ) );
}
-static long lcl_AlignWidth( const long nWidth, SwPaintProperties& properties )
+static long lcl_AlignWidth( const long nWidth, SwPaintProperties const & properties )
{
if ( nWidth )
{
@@ -1440,7 +1440,7 @@ static long lcl_AlignWidth( const long nWidth, SwPaintProperties& properties )
return nWidth;
}
-static long lcl_AlignHeight( const long nHeight, SwPaintProperties& properties )
+static long lcl_AlignHeight( const long nHeight, SwPaintProperties const & properties )
{
if ( nHeight )
{
@@ -1452,7 +1452,7 @@ static long lcl_AlignHeight( const long nHeight, SwPaintProperties& properties )
return nHeight;
}
-static long lcl_MinHeightDist( const long nDist, SwPaintProperties& properties )
+static long lcl_MinHeightDist( const long nDist, SwPaintProperties const & properties )
{
if ( properties.aSScaleX < aMinDistScale || properties.aSScaleY < aMinDistScale )
return nDist;
@@ -1465,7 +1465,7 @@ static long lcl_MinHeightDist( const long nDist, SwPaintProperties& properties )
static void lcl_CalcBorderRect( SwRect &rRect, const SwFrame *pFrame,
const SwBorderAttrs &rAttrs,
const bool bShadow,
- SwPaintProperties& properties)
+ SwPaintProperties const & properties)
{
// Special handling for cell frames.
// The printing area of a cell frame is completely enclosed in the frame area
@@ -1594,7 +1594,7 @@ static basegfx::B2DRange lcl_ShrinkFly(const SwRect& rRect)
}
static void lcl_SubtractFlys( const SwFrame *pFrame, const SwPageFrame *pPage,
- const SwRect &rRect, SwRegionRects &rRegion, basegfx::tools::B2DClipState& rClipState, SwPaintProperties & rProperties)
+ const SwRect &rRect, SwRegionRects &rRegion, basegfx::tools::B2DClipState& rClipState, SwPaintProperties const & rProperties)
{
const SwSortedObjs& rObjs = *pPage->GetSortedObjs();
const SwFlyFrame* pSelfFly = pFrame->IsInFly() ? pFrame->FindFlyFrame() : gProp.pSRetoucheFly2;
@@ -1763,7 +1763,7 @@ static void lcl_implDrawGraphicBackgrd( const SvxBrushItem& _rBackgrdBrush,
vcl::RenderContext* _pOut,
const SwRect& _rAlignedPaintRect,
const GraphicObject& _rGraphicObj,
- SwPaintProperties& properties)
+ SwPaintProperties const & properties)
{
/// determine color of background
/// If color of background brush is not "no fill"/"auto fill" or
@@ -1846,7 +1846,7 @@ static inline void lcl_DrawGraphicBackgrd( const SvxBrushItem& _rBackgrdBrush,
const SwRect& _rAlignedPaintRect,
const GraphicObject& _rGraphicObj,
bool _bNumberingGraphic,
- SwPaintProperties& properties,
+ SwPaintProperties const & properties,
bool _bBackgrdAlreadyDrawn = false)
{
// draw background with background color, if
@@ -1880,7 +1880,7 @@ static inline void lcl_DrawGraphicBackgrd( const SvxBrushItem& _rBackgrdBrush,
static void lcl_DrawGraphic( const SvxBrushItem& rBrush, vcl::RenderContext *pOut,
SwViewShell &rSh, const SwRect &rGrf, const SwRect &rOut,
bool bClip, bool bGrfNum,
- SwPaintProperties& properties,
+ SwPaintProperties const & properties,
bool bBackgrdAlreadyDrawn )
// add parameter <bBackgrdAlreadyDrawn> to indicate
// that the background is already drawn.
@@ -4362,7 +4362,7 @@ static void lcl_PaintShadow( const SwRect& rRect, SwRect& rOutRect,
const SvxShadowItem& rShadow, const bool bDrawFullShadowRectangle,
const bool bTop, const bool bBottom,
const bool bLeft, const bool bRight,
- SwPaintProperties& properties)
+ SwPaintProperties const & properties)
{
const long nWidth = ::lcl_AlignWidth ( rShadow.GetWidth(), properties );
const long nHeight = ::lcl_AlignHeight( rShadow.GetWidth(), properties );
@@ -4658,7 +4658,7 @@ static void lcl_SubTopBottom( SwRect& _iorRect,
const SwFrame& _rFrame,
const SwRectFn& _rRectFn,
const bool _bPrtOutputDev,
- SwPaintProperties& properties )
+ SwPaintProperties const & properties )
{
const bool bCnt = _rFrame.IsContentFrame();
if ( _rBox.GetTop() && _rBox.GetTop()->GetInWidth() &&
@@ -5616,7 +5616,7 @@ void SwLayoutFrame::PaintColLines( const SwRect &rRect, const SwFormatCol &rForm
}
}
-void SwPageFrame::PaintGrid( OutputDevice* pOut, SwRect &rRect ) const
+void SwPageFrame::PaintGrid( OutputDevice const * pOut, SwRect const &rRect ) const
{
if( !m_bHasGrid || gProp.pSRetoucheFly || gProp.pSRetoucheFly2 )
return;
@@ -5927,7 +5927,7 @@ void SwPageFrame::PaintGrid( OutputDevice* pOut, SwRect &rRect ) const
* has to be generated.
*/
void SwPageFrame::PaintMarginArea( const SwRect& _rOutputRect,
- SwViewShell* _pViewShell ) const
+ SwViewShell const * _pViewShell ) const
{
if ( _pViewShell->GetWin() && !_pViewShell->GetViewOptions()->getBrowseMode() )
{
@@ -5982,7 +5982,7 @@ bool SwPageFrame::IsLeftShadowNeeded() const
*/
/*static*/ void SwPageFrame::GetHorizontalShadowRect( const SwRect& _rPageRect,
const SwViewShell* _pViewShell,
- OutputDevice* pRenderContext,
+ OutputDevice const * pRenderContext,
SwRect& _orHorizontalShadowRect,
bool bPaintLeftShadow,
bool bPaintRightShadow,
@@ -6299,7 +6299,7 @@ static void lcl_paintBitmapExToRect(vcl::RenderContext *pOut, const Point& aPoin
}
}
-/*static*/ void SwPageFrame::PaintNotesSidebarArrows(const Point &aMiddleFirst, const Point &aMiddleSecond, SwViewShell* _pViewShell, const Color& rColorUp, const Color& rColorDown)
+/*static*/ void SwPageFrame::PaintNotesSidebarArrows(const Point &aMiddleFirst, const Point &aMiddleSecond, SwViewShell const * _pViewShell, const Color& rColorUp, const Color& rColorDown)
{
tools::Polygon aTriangleUp(3);
tools::Polygon aTriangleDown(3);
@@ -6325,7 +6325,7 @@ static void lcl_paintBitmapExToRect(vcl::RenderContext *pOut, const Point& aPoin
*/
/*static*/ void SwPageFrame::GetBorderAndShadowBoundRect( const SwRect& _rPageRect,
const SwViewShell* _pViewShell,
- OutputDevice* pRenderContext,
+ OutputDevice const * pRenderContext,
SwRect& _orBorderAndShadowBoundRect,
bool bLeftShadow,
bool bRightShadow,
@@ -6350,7 +6350,7 @@ static void lcl_paintBitmapExToRect(vcl::RenderContext *pOut, const Point& aPoin
_orBorderAndShadowBoundRect = pRenderContext->PixelToLogic( aPagePxRect.SVRect() );
}
-SwRect SwPageFrame::GetBoundRect(OutputDevice* pOutputDevice) const
+SwRect SwPageFrame::GetBoundRect(OutputDevice const * pOutputDevice) const
{
const SwViewShell *pSh = getRootFrame()->GetCurrShell();
SwRect aPageRect( Frame() );
diff --git a/sw/source/core/layout/trvlfrm.cxx b/sw/source/core/layout/trvlfrm.cxx
index d2c7a62111e8..57c65a417528 100644
--- a/sw/source/core/layout/trvlfrm.cxx
+++ b/sw/source/core/layout/trvlfrm.cxx
@@ -51,7 +51,7 @@
namespace {
bool lcl_GetCursorOfst_Objects( const SwPageFrame* pPageFrame, bool bSearchBackground,
- SwPosition *pPos, Point& rPoint, SwCursorMoveState* pCMS )
+ SwPosition *pPos, Point const & rPoint, SwCursorMoveState* pCMS )
{
bool bRet = false;
Point aPoint( rPoint );
diff --git a/sw/source/core/layout/virtoutp.hxx b/sw/source/core/layout/virtoutp.hxx
index d53d38aee29e..17ec8841f5c3 100644
--- a/sw/source/core/layout/virtoutp.hxx
+++ b/sw/source/core/layout/virtoutp.hxx
@@ -49,7 +49,7 @@ public:
void Enter( SwViewShell *pShell, SwRect &rRect, bool bOn );
void Leave() { --nCount; Flush(); }
- void SetOrgRect( SwRect &rRect ) { aOrgRect = rRect; }
+ void SetOrgRect( SwRect const &rRect ) { aOrgRect = rRect; }
const SwRect& GetOrgRect() const { return aOrgRect; }
bool IsFlushable() const { return bool(pOut); }
diff --git a/sw/source/core/ole/ndole.cxx b/sw/source/core/ole/ndole.cxx
index d4299386f45c..0bb33a83a6fe 100644
--- a/sw/source/core/ole/ndole.cxx
+++ b/sw/source/core/ole/ndole.cxx
@@ -208,7 +208,7 @@ void SwEmbedObjectLink::Closed()
SwOLENode::SwOLENode( const SwNodeIndex &rWhere,
const svt::EmbeddedObjectRef& xObj,
SwGrfFormatColl *pGrfColl,
- SwAttrSet* pAutoAttr ) :
+ SwAttrSet const * pAutoAttr ) :
SwNoTextNode( rWhere, SwNodeType::Ole, pGrfColl, pAutoAttr ),
aOLEObj( xObj ),
bOLESizeInvalid( false ),
@@ -221,7 +221,7 @@ SwOLENode::SwOLENode( const SwNodeIndex &rWhere,
const OUString &rString,
sal_Int64 nAspect,
SwGrfFormatColl *pGrfColl,
- SwAttrSet* pAutoAttr ) :
+ SwAttrSet const * pAutoAttr ) :
SwNoTextNode( rWhere, SwNodeType::Ole, pGrfColl, pAutoAttr ),
aOLEObj( rString, nAspect ),
bOLESizeInvalid( false ),
@@ -388,7 +388,7 @@ SwOLENode * SwNodes::MakeOLENode( const SwNodeIndex & rWhere,
}
SwOLENode * SwNodes::MakeOLENode( const SwNodeIndex & rWhere,
- const OUString &rName, sal_Int64 nAspect, SwGrfFormatColl* pGrfColl, SwAttrSet* pAutoAttr )
+ const OUString &rName, sal_Int64 nAspect, SwGrfFormatColl* pGrfColl, SwAttrSet const * pAutoAttr )
{
OSL_ENSURE( pGrfColl,"SwNodes::MakeOLENode: Formatpointer is 0." );
@@ -441,7 +441,7 @@ SwContentNode* SwOLENode::MakeCopy( SwDoc* pDoc, const SwNodeIndex& rIdx ) const
SwOLENode* pOLENd = pDoc->GetNodes().MakeOLENode( rIdx, aNewName, GetAspect(),
pDoc->GetDfltGrfFormatColl(),
- const_cast<SwAttrSet*>(GetpSwAttrSet()) );
+ GetpSwAttrSet() );
pOLENd->SetChartTableName( GetChartTableName() );
pOLENd->SetTitle( GetTitle() );
diff --git a/sw/source/core/swg/SwXMLBlockExport.cxx b/sw/source/core/swg/SwXMLBlockExport.cxx
index 43dc87b634a9..005211412e5e 100644
--- a/sw/source/core/swg/SwXMLBlockExport.cxx
+++ b/sw/source/core/swg/SwXMLBlockExport.cxx
@@ -30,7 +30,7 @@ SwXMLBlockListExport::SwXMLBlockListExport(
const uno::Reference< uno::XComponentContext >& rContext,
SwXMLTextBlocks & rBlocks,
const OUString &rFileName,
- uno::Reference< xml::sax::XDocumentHandler> &rHandler)
+ uno::Reference< xml::sax::XDocumentHandler> const &rHandler)
: SvXMLExport( rContext, "", rFileName, util::MeasureUnit::CM, rHandler ),
rBlockList(rBlocks)
{
@@ -80,7 +80,7 @@ SwXMLTextBlockExport::SwXMLTextBlockExport(
const uno::Reference< uno::XComponentContext >& rContext,
SwXMLTextBlocks & rBlocks,
const OUString &rFileName,
- uno::Reference< xml::sax::XDocumentHandler> &rHandler)
+ uno::Reference< xml::sax::XDocumentHandler> const &rHandler)
: SvXMLExport( rContext, "", rFileName, util::MeasureUnit::CM, rHandler ),
rBlockList(rBlocks)
{
diff --git a/sw/source/core/swg/swblocks.cxx b/sw/source/core/swg/swblocks.cxx
index 6e133f1d0d54..a0c3da4b8a04 100644
--- a/sw/source/core/swg/swblocks.cxx
+++ b/sw/source/core/swg/swblocks.cxx
@@ -368,7 +368,7 @@ void SwTextBlocks::Rename( sal_uInt16 n, const OUString* s, const OUString* l )
}
}
-ErrCode SwTextBlocks::CopyBlock( SwTextBlocks& rSource, OUString& rSrcShort,
+ErrCode SwTextBlocks::CopyBlock( SwTextBlocks const & rSource, OUString& rSrcShort,
const OUString& rLong )
{
bool bIsOld = false;
diff --git a/sw/source/core/table/swtable.cxx b/sw/source/core/table/swtable.cxx
index 1372c94a0731..475f460bc776 100644
--- a/sw/source/core/table/swtable.cxx
+++ b/sw/source/core/table/swtable.cxx
@@ -229,7 +229,7 @@ SwTable::SwTable( const SwTable& rTable )
{
}
-void DelBoxNode( SwTableSortBoxes& rSortCntBoxes )
+void DelBoxNode( SwTableSortBoxes const & rSortCntBoxes )
{
for (size_t n = 0; n < rSortCntBoxes.size(); ++n)
{
diff --git a/sw/source/core/text/EnhancedPDFExportHelper.cxx b/sw/source/core/text/EnhancedPDFExportHelper.cxx
index 3f0ddffcacd5..dfb2e0ffbcaf 100644
--- a/sw/source/core/text/EnhancedPDFExportHelper.cxx
+++ b/sw/source/core/text/EnhancedPDFExportHelper.cxx
@@ -263,7 +263,7 @@ bool lcl_HasPreviousParaSameNumRule( const SwTextNode& rNode )
SwTaggedPDFHelper::SwTaggedPDFHelper( const Num_Info* pNumInfo,
const Frame_Info* pFrameInfo,
const Por_Info* pPorInfo,
- OutputDevice& rOut )
+ OutputDevice const & rOut )
: nEndStructureElement( 0 ),
nRestoreCurrentTag( -1 ),
mpNumInfo( pNumInfo ),
diff --git a/sw/source/core/text/atrhndl.hxx b/sw/source/core/text/atrhndl.hxx
index 2338710da368..be83c9f67d30 100644
--- a/sw/source/core/text/atrhndl.hxx
+++ b/sw/source/core/text/atrhndl.hxx
@@ -132,7 +132,7 @@ public:
inline const SwFont* GetFont() const;
void GetDefaultAscentAndHeight(SwViewShell* pShell,
- OutputDevice& rOut,
+ OutputDevice const & rOut,
sal_uInt16& nAscent,
sal_uInt16& nHeight) const;
};
diff --git a/sw/source/core/text/atrstck.cxx b/sw/source/core/text/atrstck.cxx
index 50529398e7a5..fc46c87536d8 100644
--- a/sw/source/core/text/atrstck.cxx
+++ b/sw/source/core/text/atrstck.cxx
@@ -895,7 +895,7 @@ void SwAttrHandler::FontChg(const SfxPoolItem& rItem, SwFont& rFnt, bool bPush )
}
/// Takes the default font and calculated the ascent and height
-void SwAttrHandler::GetDefaultAscentAndHeight( SwViewShell* pShell, OutputDevice& rOut,
+void SwAttrHandler::GetDefaultAscentAndHeight( SwViewShell* pShell, OutputDevice const & rOut,
sal_uInt16& nAscent, sal_uInt16& nHeight ) const
{
OSL_ENSURE( pFnt, "No font available for GetDefaultAscentAndHeight" );
diff --git a/sw/source/core/text/inftxt.cxx b/sw/source/core/text/inftxt.cxx
index caedd00c9819..6a0fccff0ae7 100644
--- a/sw/source/core/text/inftxt.cxx
+++ b/sw/source/core/text/inftxt.cxx
@@ -1573,7 +1573,7 @@ SwTextFormatInfo::SwTextFormatInfo( const SwTextFormatInfo& rInf,
SetFirstMulti( rInf.IsFirstMulti() );
}
-bool SwTextFormatInfo::CheckFootnotePortion_( SwLineLayout* pCurr )
+bool SwTextFormatInfo::CheckFootnotePortion_( SwLineLayout const * pCurr )
{
const sal_uInt16 nHeight = pCurr->GetRealHeight();
for( SwLinePortion *pPor = pCurr->GetPortion(); pPor; pPor = pPor->GetPortion() )
diff --git a/sw/source/core/text/inftxt.hxx b/sw/source/core/text/inftxt.hxx
index 131b3f2645f4..2e20756477fa 100644
--- a/sw/source/core/text/inftxt.hxx
+++ b/sw/source/core/text/inftxt.hxx
@@ -200,7 +200,7 @@ public:
// GetMultiAttr returns the text attribute of the multiportion,
// if rPos is inside any multi-line part.
// rPos will set to the end of the multi-line part.
- SwMultiCreator* GetMultiCreator( sal_Int32 &rPos, SwMultiPortion* pM ) const;
+ SwMultiCreator* GetMultiCreator( sal_Int32 &rPos, SwMultiPortion const * pM ) const;
bool OnWin() const { return m_bOnWin; }
void SetOnWin( const bool bNew ) { m_bOnWin = bNew; }
@@ -527,7 +527,7 @@ class SwTextFormatInfo : public SwTextPaintInfo
// Hyphenating ...
bool InitHyph( const bool bAuto = false );
- bool CheckFootnotePortion_( SwLineLayout* pCurr );
+ bool CheckFootnotePortion_( SwLineLayout const * pCurr );
public:
void CtorInitTextFormatInfo( OutputDevice* pRenderContext, SwTextFrame *pFrame, const bool bInterHyph = false,
@@ -652,7 +652,7 @@ public:
HyphWord( const OUString &rText, const sal_Int32 nMinTrail );
const css::beans::PropertyValues & GetHyphValues() const;
- bool CheckFootnotePortion( SwLineLayout* pCurr )
+ bool CheckFootnotePortion( SwLineLayout const * pCurr )
{ return IsFootnoteInside() && CheckFootnotePortion_( pCurr ); }
// Dropcaps called by SwTextFormatter::CTOR
diff --git a/sw/source/core/text/itratr.cxx b/sw/source/core/text/itratr.cxx
index a4fde667652f..270ef8a2a82d 100644
--- a/sw/source/core/text/itratr.cxx
+++ b/sw/source/core/text/itratr.cxx
@@ -58,7 +58,7 @@
using namespace ::com::sun::star::i18n;
using namespace ::com::sun::star;
-void SwAttrIter::Chg( SwTextAttr *pHt )
+void SwAttrIter::Chg( SwTextAttr const *pHt )
{
assert(pHt && m_pFont && "No attribute of font available for change");
if( m_pRedline && m_pRedline->IsOn() )
@@ -68,7 +68,7 @@ void SwAttrIter::Chg( SwTextAttr *pHt )
m_nChgCnt++;
}
-void SwAttrIter::Rst( SwTextAttr *pHt )
+void SwAttrIter::Rst( SwTextAttr const *pHt )
{
assert(pHt && m_pFont && "No attribute of font available for reset");
// get top from stack after removing pHt
@@ -397,8 +397,7 @@ bool SwTextNode::IsSymbol( const sal_Int32 nBegin ) const
SwScriptInfo aScriptInfo;
SwAttrIter aIter( *const_cast<SwTextNode*>(this), aScriptInfo );
aIter.Seek( nBegin );
- return aIter.GetFnt()->IsSymbol(
- const_cast<SwViewShell *>(getIDocumentLayoutAccess().GetCurrentViewShell()) );
+ return aIter.GetFnt()->IsSymbol( getIDocumentLayoutAccess().GetCurrentViewShell() );
}
class SwMinMaxNodeArgs
diff --git a/sw/source/core/text/itratr.hxx b/sw/source/core/text/itratr.hxx
index c8bea5fead05..07ab43d5af2c 100644
--- a/sw/source/core/text/itratr.hxx
+++ b/sw/source/core/text/itratr.hxx
@@ -62,10 +62,10 @@ private:
void SetFnt( SwFont* pNew ) { m_pFont = pNew; }
protected:
- void Chg( SwTextAttr *pHt );
- void Rst( SwTextAttr *pHt );
- void CtorInitAttrIter( SwTextNode& rTextNode, SwScriptInfo& rScrInf, SwTextFrame* pFrame = nullptr );
- explicit SwAttrIter(SwTextNode* pTextNode)
+ void Chg( SwTextAttr const *pHt );
+ void Rst( SwTextAttr const *pHt );
+ void CtorInitAttrIter( SwTextNode& rTextNode, SwScriptInfo& rScrInf, SwTextFrame const * pFrame = nullptr );
+ explicit SwAttrIter(SwTextNode const * pTextNode)
: m_pViewShell(nullptr)
, m_pFont(nullptr)
, m_pHints(nullptr)
diff --git a/sw/source/core/text/itrform2.cxx b/sw/source/core/text/itrform2.cxx
index ef902be38e77..f877a969e7e2 100644
--- a/sw/source/core/text/itrform2.cxx
+++ b/sw/source/core/text/itrform2.cxx
@@ -69,7 +69,7 @@ using namespace ::com::sun::star;
namespace {
//! Calculates and sets optimal repaint offset for the current line
long lcl_CalcOptRepaint( SwTextFormatter &rThis,
- SwLineLayout &rCurr,
+ SwLineLayout const &rCurr,
const sal_Int32 nOldLineEnd,
const std::vector<long> &rFlyStarts );
//! Determine if we need to build hidden portions
@@ -2566,7 +2566,7 @@ SwFlyCntPortion *SwTextFormatter::NewFlyCntPortion( SwTextFormatInfo &rInf,
/* Drop portion is a special case, because it has parts which aren't portions
but we have handle them just like portions */
-void SwTextFormatter::MergeCharacterBorder( SwDropPortion& rPortion )
+void SwTextFormatter::MergeCharacterBorder( SwDropPortion const & rPortion )
{
if( rPortion.GetLines() > 1 )
{
@@ -2584,7 +2584,7 @@ void SwTextFormatter::MergeCharacterBorder( SwDropPortion& rPortion )
}
}
-void SwTextFormatter::MergeCharacterBorder( SwLinePortion& rPortion, SwLinePortion *pPrev, SwTextFormatInfo& rInf )
+void SwTextFormatter::MergeCharacterBorder( SwLinePortion& rPortion, SwLinePortion const *pPrev, SwTextFormatInfo& rInf )
{
const SwFont aCurFont = *rInf.GetFont();
if( aCurFont.HasBorder() )
@@ -2676,7 +2676,7 @@ void SwTextFormatter::MergeCharacterBorder( SwLinePortion& rPortion, SwLinePorti
namespace {
// calculates and sets optimal repaint offset for the current line
long lcl_CalcOptRepaint( SwTextFormatter &rThis,
- SwLineLayout &rCurr,
+ SwLineLayout const &rCurr,
const sal_Int32 nOldLineEnd,
const std::vector<long> &rFlyStarts )
{
diff --git a/sw/source/core/text/itrform2.hxx b/sw/source/core/text/itrform2.hxx
index 28f19b9e78c1..3cd75e1aefa8 100644
--- a/sw/source/core/text/itrform2.hxx
+++ b/sw/source/core/text/itrform2.hxx
@@ -52,8 +52,8 @@ class SwTextFormatter : public SwTextPainter
SwTabPortion *NewTabPortion( SwTextFormatInfo &rInf, bool bAuto ) const;
SwNumberPortion *NewNumberPortion( SwTextFormatInfo &rInf ) const;
SwDropPortion *NewDropPortion( SwTextFormatInfo &rInf );
- SwNumberPortion *NewFootnoteNumPortion( SwTextFormatInfo &rInf ) const;
- SwErgoSumPortion *NewErgoSumPortion( SwTextFormatInfo &rInf ) const;
+ SwNumberPortion *NewFootnoteNumPortion( SwTextFormatInfo const &rInf ) const;
+ SwErgoSumPortion *NewErgoSumPortion( SwTextFormatInfo const &rInf ) const;
SwExpandPortion *NewFieldPortion( SwTextFormatInfo &rInf,
const SwTextAttr *pHt ) const;
SwFootnotePortion *NewFootnotePortion( SwTextFormatInfo &rInf, SwTextAttr *pHt );
@@ -65,7 +65,7 @@ class SwTextFormatter : public SwTextPainter
SwTextAttr *pHt ) const;
SwLinePortion *WhichFirstPortion( SwTextFormatInfo &rInf );
SwTextPortion *WhichTextPor( SwTextFormatInfo &rInf ) const;
- SwExpandPortion * TryNewNoLengthPortion( SwTextFormatInfo & rInfo );
+ SwExpandPortion * TryNewNoLengthPortion( SwTextFormatInfo const & rInfo );
// The center piece of formatting
void BuildPortions( SwTextFormatInfo &rInf );
@@ -227,7 +227,7 @@ public:
* the portions' part. Removing left or right border.
* @param rPortion drop portion for merge
**/
- static void MergeCharacterBorder( SwDropPortion& rPortion );
+ static void MergeCharacterBorder( SwDropPortion const & rPortion );
/**
* Merge border of the line portion with setting the portion's
@@ -238,7 +238,7 @@ public:
* @param pPrev portion immediately before rPortion
* @param rInf contain information
**/
- void MergeCharacterBorder( SwLinePortion& rPortion, SwLinePortion *pPrev, SwTextFormatInfo& rInf );
+ void MergeCharacterBorder( SwLinePortion& rPortion, SwLinePortion const *pPrev, SwTextFormatInfo& rInf );
};
#endif
diff --git a/sw/source/core/text/itrpaint.hxx b/sw/source/core/text/itrpaint.hxx
index a47b90784eb7..b9d3f03e974b 100644
--- a/sw/source/core/text/itrpaint.hxx
+++ b/sw/source/core/text/itrpaint.hxx
@@ -32,7 +32,7 @@ class SwTextPainter : public SwTextCursor
long nAdjustBaseLine = 0 );
protected:
void CtorInitTextPainter( SwTextFrame *pFrame, SwTextPaintInfo *pInf );
- explicit SwTextPainter(SwTextNode* pTextNode)
+ explicit SwTextPainter(SwTextNode const * pTextNode)
: SwTextCursor(pTextNode)
, bPaintDrop(false)
{
diff --git a/sw/source/core/text/itrtxt.hxx b/sw/source/core/text/itrtxt.hxx
index da394e1fbbdb..6b72b703b6f9 100644
--- a/sw/source/core/text/itrtxt.hxx
+++ b/sw/source/core/text/itrtxt.hxx
@@ -53,7 +53,7 @@ protected:
// Reset in the first line
void Init();
void CtorInitTextIter( SwTextFrame *pFrame, SwTextInfo *pInf );
- explicit SwTextIter(SwTextNode* pTextNode)
+ explicit SwTextIter(SwTextNode const * pTextNode)
: SwAttrIter(pTextNode)
, m_pFrame(nullptr)
, m_pInf(nullptr)
@@ -158,7 +158,7 @@ protected:
void Right( const SwTwips nNew ) { nRight = nNew; }
void CtorInitTextMargin( SwTextFrame *pFrame, SwTextSizeInfo *pInf );
- explicit SwTextMargin(SwTextNode* pTextNode)
+ explicit SwTextMargin(SwTextNode const * pTextNode)
: SwTextIter(pTextNode)
, nLeft(0)
, nRight(0)
@@ -237,7 +237,7 @@ class SwTextAdjuster : public SwTextMargin
const SwRect &rCurrRect );
protected:
- explicit SwTextAdjuster(SwTextNode* pTextNode) : SwTextMargin(pTextNode) { }
+ explicit SwTextAdjuster(SwTextNode const * pTextNode) : SwTextMargin(pTextNode) { }
// Creates the Glues for adjusted paragraphs
void CalcNewBlock( SwLineLayout *pCurr, const SwLinePortion *pStopAt,
SwTwips nReal = 0, bool bSkipKashida = false );
@@ -270,7 +270,7 @@ class SwTextCursor : public SwTextAdjuster
void GetCharRect_(SwRect *, const sal_Int32, SwCursorMoveState* );
protected:
void CtorInitTextCursor( SwTextFrame *pFrame, SwTextSizeInfo *pInf );
- explicit SwTextCursor(SwTextNode* pTextNode) : SwTextAdjuster(pTextNode) { }
+ explicit SwTextCursor(SwTextNode const * pTextNode) : SwTextAdjuster(pTextNode) { }
public:
SwTextCursor( SwTextFrame *pTextFrame, SwTextSizeInfo *pTextSizeInf )
: SwTextAdjuster(pTextFrame->GetTextNode())
diff --git a/sw/source/core/text/porfly.cxx b/sw/source/core/text/porfly.cxx
index a853b67912ee..53b10b50681d 100644
--- a/sw/source/core/text/porfly.cxx
+++ b/sw/source/core/text/porfly.cxx
@@ -180,7 +180,7 @@ void SwTextFrame::MoveFlyInCnt( SwTextFrame *pNew, sal_Int32 nStart, sal_Int32 n
}
}
-sal_Int32 SwTextFrame::CalcFlyPos( SwFrameFormat* pSearch )
+sal_Int32 SwTextFrame::CalcFlyPos( SwFrameFormat const * pSearch )
{
SwpHints* pHints = GetTextNode()->GetpSwpHints();
OSL_ENSURE( pHints, "CalcFlyPos: Why me?" );
@@ -267,7 +267,7 @@ sw::FlyContentPortion::FlyContentPortion(SwFlyInContentFrame* pFly)
SAL_WARN_IF(!pFly, "sw.core", "SwFlyCntPortion::SwFlyCntPortion: no SwFlyInContentFrame!");
}
-sw::DrawFlyCntPortion::DrawFlyCntPortion(SwFrameFormat& rFormat)
+sw::DrawFlyCntPortion::DrawFlyCntPortion(SwFrameFormat const & rFormat)
: m_pContact(nullptr)
{
rFormat.CallSwClientNotify(sw::CreatePortionHint(&m_pContact));
@@ -281,7 +281,7 @@ sw::FlyContentPortion* sw::FlyContentPortion::Create(const SwTextFrame& rFrame,
return pNew;
}
-sw::DrawFlyCntPortion* sw::DrawFlyCntPortion::Create(const SwTextFrame& rFrame, SwFrameFormat& rFormat, const Point& rBase, long nLnAscent, long nLnDescent, long nFlyAsc, long nFlyDesc, AsCharFlags nFlags)
+sw::DrawFlyCntPortion* sw::DrawFlyCntPortion::Create(const SwTextFrame& rFrame, SwFrameFormat const & rFormat, const Point& rBase, long nLnAscent, long nLnDescent, long nFlyAsc, long nFlyDesc, AsCharFlags nFlags)
{
auto pNew(new DrawFlyCntPortion(rFormat));
pNew->SetBase(rFrame, rBase, nLnAscent, nLnDescent, nFlyAsc, nFlyDesc, nFlags | AsCharFlags::UlSpace | AsCharFlags::Init);
diff --git a/sw/source/core/text/porfly.hxx b/sw/source/core/text/porfly.hxx
index 84568066302f..e6fd152ad05e 100644
--- a/sw/source/core/text/porfly.hxx
+++ b/sw/source/core/text/porfly.hxx
@@ -82,8 +82,8 @@ namespace sw
SwDrawContact* m_pContact;
virtual SdrObject* GetSdrObj(const SwTextFrame&) override;
public:
- DrawFlyCntPortion(SwFrameFormat& rFormat);
- static DrawFlyCntPortion* Create(const SwTextFrame& rFrame, SwFrameFormat& rFormat, const Point& rBase, long nAsc, long nDescent, long nFlyAsc, long nFlyDesc, AsCharFlags nFlags);
+ DrawFlyCntPortion(SwFrameFormat const & rFormat);
+ static DrawFlyCntPortion* Create(const SwTextFrame& rFrame, SwFrameFormat const & rFormat, const Point& rBase, long nAsc, long nDescent, long nFlyAsc, long nFlyDesc, AsCharFlags nFlags);
virtual void Paint(const SwTextPaintInfo& rInf) const override;
virtual ~DrawFlyCntPortion() override;
};
diff --git a/sw/source/core/text/pormulti.cxx b/sw/source/core/text/pormulti.cxx
index df11d817c2c3..554dadf254f8 100644
--- a/sw/source/core/text/pormulti.cxx
+++ b/sw/source/core/text/pormulti.cxx
@@ -790,7 +790,7 @@ static bool lcl_HasRotation( const SwTextAttr& rAttr,
// E.g. a ruby portion interrupts a 2-line-attribute, a 2-line-attribute
// with different brackets interrupts another 2-line-attribute.
SwMultiCreator* SwTextSizeInfo::GetMultiCreator( sal_Int32 &rPos,
- SwMultiPortion* pMulti ) const
+ SwMultiPortion const * pMulti ) const
{
SwScriptInfo& rSI = const_cast<SwParaPortion*>(GetParaPortion())->GetScriptInfo();
@@ -800,7 +800,7 @@ SwMultiCreator* SwTextSizeInfo::GetMultiCreator( sal_Int32 &rPos,
{
OSL_ENSURE( pMulti->IsBidi(), "Nested MultiPortion is not BidiPortion" );
// level associated with bidi-portion;
- nCurrLevel = static_cast<SwBidiPortion*>(pMulti)->GetLevel();
+ nCurrLevel = static_cast<SwBidiPortion const *>(pMulti)->GetLevel();
}
else
// no nested bidi portion required
diff --git a/sw/source/core/text/portxt.cxx b/sw/source/core/text/portxt.cxx
index d953c7276c6e..4a70a1801eb9 100644
--- a/sw/source/core/text/portxt.cxx
+++ b/sw/source/core/text/portxt.cxx
@@ -271,7 +271,7 @@ void SwTextPortion::BreakUnderflow( SwTextFormatInfo &rInf )
rInf.SetUnderflow( this );
}
-static bool lcl_HasContent( const SwFieldPortion& rField, SwTextFormatInfo &rInf )
+static bool lcl_HasContent( const SwFieldPortion& rField, SwTextFormatInfo const &rInf )
{
OUString aText;
return rField.GetExpText( rInf, aText ) && !aText.isEmpty();
diff --git a/sw/source/core/text/portxt.hxx b/sw/source/core/text/portxt.hxx
index f795f36d3c4e..6764ef5cd31b 100644
--- a/sw/source/core/text/portxt.hxx
+++ b/sw/source/core/text/portxt.hxx
@@ -46,7 +46,7 @@ public:
// Counts the spaces for justified paragraph
sal_Int32 GetSpaceCnt( const SwTextSizeInfo &rInf, sal_Int32& rCnt ) const;
- bool CreateHyphen( SwTextFormatInfo &rInf, SwTextGuess &rGuess );
+ bool CreateHyphen( SwTextFormatInfo &rInf, SwTextGuess const &rGuess );
// Accessibility: pass information about this portion to the PortionHandler
virtual void HandlePortion( SwPortionHandler& rPH ) const override;
diff --git a/sw/source/core/text/redlnitr.cxx b/sw/source/core/text/redlnitr.cxx
index c830216b5858..aede807d9520 100644
--- a/sw/source/core/text/redlnitr.cxx
+++ b/sw/source/core/text/redlnitr.cxx
@@ -44,7 +44,7 @@
using namespace ::com::sun::star;
-void SwAttrIter::CtorInitAttrIter( SwTextNode& rTextNode, SwScriptInfo& rScrInf, SwTextFrame* pFrame )
+void SwAttrIter::CtorInitAttrIter( SwTextNode& rTextNode, SwScriptInfo& rScrInf, SwTextFrame const * pFrame )
{
// during HTML-Import it can happen, that no layout exists
SwRootFrame* pRootFrame = rTextNode.getIDocumentLayoutAccess().GetCurrentLayout();
@@ -291,7 +291,7 @@ void SwRedlineItr::FillHints( std::size_t nAuthor, RedlineType_t eType )
}
}
-void SwRedlineItr::ChangeTextAttr( SwFont* pFnt, SwTextAttr &rHt, bool bChg )
+void SwRedlineItr::ChangeTextAttr( SwFont* pFnt, SwTextAttr const &rHt, bool bChg )
{
OSL_ENSURE( IsOn(), "SwRedlineItr::ChangeTextAttr: Off?" );
diff --git a/sw/source/core/text/redlnitr.hxx b/sw/source/core/text/redlnitr.hxx
index 5aef747246da..b8b231b4772d 100644
--- a/sw/source/core/text/redlnitr.hxx
+++ b/sw/source/core/text/redlnitr.hxx
@@ -92,7 +92,7 @@ public:
~SwRedlineItr();
bool IsOn() const { return bOn || ( pExt && pExt->IsOn() ); }
void Clear( SwFont* pFnt ) { if( bOn ) Clear_( pFnt ); }
- void ChangeTextAttr( SwFont* pFnt, SwTextAttr &rHt, bool bChg );
+ void ChangeTextAttr( SwFont* pFnt, SwTextAttr const &rHt, bool bChg );
short Seek( SwFont& rFnt, sal_Int32 nNew, sal_Int32 nOld ) {
if( bShow || pExt ) return Seek_( rFnt, nNew, nOld );
return 0;
diff --git a/sw/source/core/text/txtcache.cxx b/sw/source/core/text/txtcache.cxx
index c120041bcfff..3c1ef3fc043b 100644
--- a/sw/source/core/text/txtcache.cxx
+++ b/sw/source/core/text/txtcache.cxx
@@ -21,8 +21,8 @@
#include "txtfrm.hxx"
#include "porlay.hxx"
-SwTextLine::SwTextLine( SwTextFrame *pFrame, SwParaPortion *pNew ) :
- SwCacheObj( static_cast<void*>(pFrame) ),
+SwTextLine::SwTextLine( SwTextFrame const *pFrame, SwParaPortion *pNew ) :
+ SwCacheObj( static_cast<void const *>(pFrame) ),
pLine( pNew )
{
}
@@ -33,7 +33,7 @@ SwTextLine::~SwTextLine()
SwCacheObj *SwTextLineAccess::NewObj()
{
- return new SwTextLine( const_cast<SwTextFrame *>(static_cast<SwTextFrame const *>(m_pOwner)) );
+ return new SwTextLine( static_cast<SwTextFrame const *>(m_pOwner) );
}
SwParaPortion *SwTextLineAccess::GetPara()
diff --git a/sw/source/core/text/txtcache.hxx b/sw/source/core/text/txtcache.hxx
index 77d199c72750..e6b822f2d6d5 100644
--- a/sw/source/core/text/txtcache.hxx
+++ b/sw/source/core/text/txtcache.hxx
@@ -34,7 +34,7 @@ class SwTextLine : public SwCacheObj
public:
DECL_FIXEDMEMPOOL_NEWDEL(SwTextLine)
- SwTextLine( SwTextFrame *pFrame, SwParaPortion *pNew = nullptr );
+ SwTextLine( SwTextFrame const *pFrame, SwParaPortion *pNew = nullptr );
virtual ~SwTextLine() override;
SwParaPortion *GetPara() { return pLine.get(); }
diff --git a/sw/source/core/text/txtfld.cxx b/sw/source/core/text/txtfld.cxx
index faa5fa153ae3..1652d5222fbb 100644
--- a/sw/source/core/text/txtfld.cxx
+++ b/sw/source/core/text/txtfld.cxx
@@ -314,7 +314,7 @@ static SwFieldPortion * lcl_NewMetaPortion(SwTextAttr & rHint, const bool bPrefi
* due to Underflow. In that case, m_nHintEndIndex must be decremented,
* so the portion will be created again on the next line.
*/
-SwExpandPortion * SwTextFormatter::TryNewNoLengthPortion(SwTextFormatInfo & rInfo)
+SwExpandPortion * SwTextFormatter::TryNewNoLengthPortion(SwTextFormatInfo const & rInfo)
{
if (m_pHints)
{
diff --git a/sw/source/core/text/txtfrm.cxx b/sw/source/core/text/txtfrm.cxx
index 7100e0dfcaa9..76e36402977e 100644
--- a/sw/source/core/text/txtfrm.cxx
+++ b/sw/source/core/text/txtfrm.cxx
@@ -1789,7 +1789,7 @@ bool SwTextFrame::Prepare( const PrepareHint ePrep, const void* pVoid,
{
if( pVoid )
{
- sal_Int32 nWhere = CalcFlyPos( const_cast<SwFrameFormat *>(static_cast<SwFrameFormat const *>(pVoid)) );
+ sal_Int32 nWhere = CalcFlyPos( static_cast<SwFrameFormat const *>(pVoid) );
OSL_ENSURE( COMPLETE_STRING != nWhere, "Prepare: Why me?" );
InvalidateRange( SwCharRange( nWhere, 1 ) );
return bParaPossiblyInvalid;
@@ -2602,7 +2602,7 @@ const SwScriptInfo* SwTextFrame::GetScriptInfo() const
* Helper function for SwTextFrame::CalcBasePosForFly()
*/
static SwTwips lcl_CalcFlyBasePos( const SwTextFrame& rFrame, SwRect aFlyRect,
- SwTextFly& rTextFly )
+ SwTextFly const & rTextFly )
{
SwRectFnSet aRectFnSet(&rFrame);
SwTwips nRet = rFrame.IsRightToLeft() ?
diff --git a/sw/source/core/text/txtftn.cxx b/sw/source/core/text/txtftn.cxx
index 443c2853795c..55b3c13dd1e7 100644
--- a/sw/source/core/text/txtftn.cxx
+++ b/sw/source/core/text/txtftn.cxx
@@ -926,7 +926,7 @@ SwFootnotePortion *SwTextFormatter::NewFootnotePortion( SwTextFormatInfo &rInf,
/**
* The portion for the Footnote Numbering in the Footnote Area
*/
-SwNumberPortion *SwTextFormatter::NewFootnoteNumPortion( SwTextFormatInfo &rInf ) const
+SwNumberPortion *SwTextFormatter::NewFootnoteNumPortion( SwTextFormatInfo const &rInf ) const
{
OSL_ENSURE( m_pFrame->IsInFootnote() && !m_pFrame->GetIndPrev() && !rInf.IsFootnoteDone(),
"This is the wrong place for a ftnnumber" );
@@ -985,7 +985,7 @@ OUString lcl_GetPageNumber( const SwPageFrame* pPage )
return rNum.GetNumStr( nVirtNum );
}
-SwErgoSumPortion *SwTextFormatter::NewErgoSumPortion( SwTextFormatInfo &rInf ) const
+SwErgoSumPortion *SwTextFormatter::NewErgoSumPortion( SwTextFormatInfo const &rInf ) const
{
// We cannot assume we're a Follow
if( !m_pFrame->IsInFootnote() || m_pFrame->GetPrev() ||
diff --git a/sw/source/core/text/txthyph.cxx b/sw/source/core/text/txthyph.cxx
index a48ae3f2194c..acf4c7fe4fc2 100644
--- a/sw/source/core/text/txthyph.cxx
+++ b/sw/source/core/text/txthyph.cxx
@@ -247,7 +247,7 @@ bool SwTextFormatter::Hyphenate( SwInterHyphInfo &rHyphInf )
return false;
}
-bool SwTextPortion::CreateHyphen( SwTextFormatInfo &rInf, SwTextGuess &rGuess )
+bool SwTextPortion::CreateHyphen( SwTextFormatInfo &rInf, SwTextGuess const &rGuess )
{
Reference< XHyphenatedWord > xHyphWord = rGuess.HyphWord();
diff --git a/sw/source/core/text/widorp.cxx b/sw/source/core/text/widorp.cxx
index 91d3c1090d06..01de602ba732 100644
--- a/sw/source/core/text/widorp.cxx
+++ b/sw/source/core/text/widorp.cxx
@@ -101,7 +101,7 @@ SwTextFrameBreak::SwTextFrameBreak( SwTextFrame *pNewFrame, const SwTwips nRst )
* be done until the Follow is formatted. Unfortunately this is crucial
* to decide if the whole paragraph goes to the next page or not.
*/
-bool SwTextFrameBreak::IsInside( SwTextMargin &rLine ) const
+bool SwTextFrameBreak::IsInside( SwTextMargin const &rLine ) const
{
bool bFit = false;
diff --git a/sw/source/core/text/widorp.hxx b/sw/source/core/text/widorp.hxx
index 56326a1cb53e..92f80f009b58 100644
--- a/sw/source/core/text/widorp.hxx
+++ b/sw/source/core/text/widorp.hxx
@@ -39,7 +39,7 @@ public:
void SetKeep( const bool bNew ) { m_bKeep = bNew; }
- bool IsInside( SwTextMargin &rLine ) const;
+ bool IsInside( SwTextMargin const &rLine ) const;
// In order to be able to handle special cases with Footnote.
// SetRstHeight sets the rest height for SwTextFrameBreak. This is needed
diff --git a/sw/source/core/tox/tox.cxx b/sw/source/core/tox/tox.cxx
index f35d49fd9799..844dce1e936a 100644
--- a/sw/source/core/tox/tox.cxx
+++ b/sw/source/core/tox/tox.cxx
@@ -446,7 +446,7 @@ sal_uInt16 SwForm::GetFormMaxLevel( TOXTypes eTOXType )
return 0;
}
-void SwForm::AdjustTabStops( SwDoc& rDoc ) // #i21237#
+void SwForm::AdjustTabStops( SwDoc const & rDoc ) // #i21237#
{
const sal_uInt16 nFormMax = GetFormMax();
for ( sal_uInt16 nLevel = 1; nLevel < nFormMax; ++nLevel )
diff --git a/sw/source/core/txtnode/atrftn.cxx b/sw/source/core/txtnode/atrftn.cxx
index 0c1c034a6e91..799526e60802 100644
--- a/sw/source/core/txtnode/atrftn.cxx
+++ b/sw/source/core/txtnode/atrftn.cxx
@@ -43,7 +43,7 @@ namespace {
/// @param[out] rUsedRef The set of used reference numbers.
/// @param[out] rInvalid A returned list of all items that had an invalid reference number.
void lcl_FillUsedFootnoteRefNumbers(SwDoc &rDoc,
- SwTextFootnote *pExclude,
+ SwTextFootnote const *pExclude,
std::set<sal_uInt16> &rUsedRef,
std::vector<SwTextFootnote*> &rInvalid)
{
@@ -72,7 +72,7 @@ namespace {
/// @param[in] rUsedNums Set of used reference numbers.
/// @param[in] requested The requested reference number.
/// @returns true if the number is available, false if not.
- bool lcl_IsRefNumAvailable(std::set<sal_uInt16> &rUsedNums,
+ bool lcl_IsRefNumAvailable(std::set<sal_uInt16> const &rUsedNums,
sal_uInt16 requested)
{
if ( USHRT_MAX == requested )
diff --git a/sw/source/core/txtnode/fntcache.cxx b/sw/source/core/txtnode/fntcache.cxx
index 29ddcabedee1..3925c2ca4939 100644
--- a/sw/source/core/txtnode/fntcache.cxx
+++ b/sw/source/core/txtnode/fntcache.cxx
@@ -2285,7 +2285,7 @@ SwCacheObj *SwFntAccess::NewObj( )
return new SwFntObj( *static_cast<SwSubFont const *>(m_pOwner), ++pMagicNo, pShell );
}
-sal_Int32 SwFont::GetTextBreak( SwDrawTextInfo& rInf, long nTextWidth )
+sal_Int32 SwFont::GetTextBreak( SwDrawTextInfo const & rInf, long nTextWidth )
{
ChgFnt( rInf.GetShell(), rInf.GetOut() );
diff --git a/sw/source/core/txtnode/ndhints.cxx b/sw/source/core/txtnode/ndhints.cxx
index 55d31dc4c1f4..58ac2803f247 100644
--- a/sw/source/core/txtnode/ndhints.cxx
+++ b/sw/source/core/txtnode/ndhints.cxx
@@ -96,12 +96,12 @@ static bool lcl_IsLessEnd( const SwTextAttr &rHt1, const SwTextAttr &rHt2 )
return ( nHt1 < nHt2 );
}
-bool CompareSwpHtStart::operator()(SwTextAttr* const lhs, SwTextAttr* const rhs) const
+bool CompareSwpHtStart::operator()(SwTextAttr const * const lhs, SwTextAttr const * const rhs) const
{
return lcl_IsLessStart( *lhs, *rhs );
}
-bool CompareSwpHtEnd::operator()(SwTextAttr* const lhs, SwTextAttr* const rhs) const
+bool CompareSwpHtEnd::operator()(SwTextAttr const * const lhs, SwTextAttr const * const rhs) const
{
return lcl_IsLessEnd( *lhs, *rhs );
}
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index 83ebfe995a46..4f4d9a3dccf8 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -1322,7 +1322,7 @@ static void
lcl_GetTextAttrs(
std::vector<SwTextAttr *> *const pVector,
SwTextAttr **const ppTextAttr,
- SwpHints *const pSwpHints,
+ SwpHints const *const pSwpHints,
sal_Int32 const nIndex, RES_TXTATR const nWhich,
enum SwTextNode::GetTextAttrMode const eMode)
{
diff --git a/sw/source/core/txtnode/swfont.cxx b/sw/source/core/txtnode/swfont.cxx
index 8c1cd91f3b10..b2ac4e733251 100644
--- a/sw/source/core/txtnode/swfont.cxx
+++ b/sw/source/core/txtnode/swfont.cxx
@@ -937,13 +937,13 @@ SwFont& SwFont::operator=( const SwFont &rFont )
return *this;
}
-void SwFont::GoMagic( SwViewShell *pSh, SwFontScript nWhich )
+void SwFont::GoMagic( SwViewShell const *pSh, SwFontScript nWhich )
{
SwFntAccess aFntAccess( m_aSub[nWhich].m_pMagic, m_aSub[nWhich].m_nFontIndex,
&m_aSub[nWhich], pSh, true );
}
-bool SwSubFont::IsSymbol( SwViewShell *pSh )
+bool SwSubFont::IsSymbol( SwViewShell const *pSh )
{
SwFntAccess aFntAccess( m_pMagic, m_nFontIndex, this, pSh, false );
return aFntAccess.Get()->IsSymbol();
@@ -966,7 +966,7 @@ bool SwSubFont::ChgFnt( SwViewShell const *pSh, OutputDevice& rOut )
STRIKEOUT_NONE != GetStrikeout();
}
-void SwFont::ChgPhysFnt( SwViewShell *pSh, OutputDevice& rOut )
+void SwFont::ChgPhysFnt( SwViewShell const *pSh, OutputDevice& rOut )
{
if( m_bOrgChg && m_aSub[m_nActual].IsEsc() )
{
@@ -1021,14 +1021,14 @@ short SwSubFont::CheckKerning_( )
return nKernx;
}
-sal_uInt16 SwSubFont::GetAscent( SwViewShell *pSh, const OutputDevice& rOut )
+sal_uInt16 SwSubFont::GetAscent( SwViewShell const *pSh, const OutputDevice& rOut )
{
SwFntAccess aFntAccess( m_pMagic, m_nFontIndex, this, pSh );
const sal_uInt16 nAscent = aFntAccess.Get()->GetFontAscent( pSh, rOut );
return GetEscapement() ? CalcEscAscent( nAscent ) : nAscent;
}
-sal_uInt16 SwSubFont::GetHeight( SwViewShell *pSh, const OutputDevice& rOut )
+sal_uInt16 SwSubFont::GetHeight( SwViewShell const *pSh, const OutputDevice& rOut )
{
SV_STAT( nGetTextSize );
SwFntAccess aFntAccess( m_pMagic, m_nFontIndex, this, pSh );
@@ -1383,7 +1383,7 @@ sal_Int32 SwSubFont::GetCursorOfst_( SwDrawTextInfo& rInf )
return nCursor;
}
-void SwSubFont::CalcEsc( SwDrawTextInfo& rInf, Point& rPos )
+void SwSubFont::CalcEsc( SwDrawTextInfo const & rInf, Point& rPos )
{
long nOfst;
diff --git a/sw/source/core/txtnode/thints.cxx b/sw/source/core/txtnode/thints.cxx
index fb7f05fd6bed..361a7513d4bd 100644
--- a/sw/source/core/txtnode/thints.cxx
+++ b/sw/source/core/txtnode/thints.cxx
@@ -949,7 +949,7 @@ void SwpHints::BuildPortions( SwTextNode& rNode, SwTextAttr& rNewHint,
rNode.DestroyAttr( &rNewHint );
}
-SwTextAttr* MakeRedlineTextAttr( SwDoc & rDoc, SfxPoolItem & rAttr )
+SwTextAttr* MakeRedlineTextAttr( SwDoc & rDoc, SfxPoolItem const & rAttr )
{
// this is intended _only_ for special-purpose redline attributes!
switch (rAttr.Which())
@@ -3297,7 +3297,7 @@ void SwpHints::DeleteAtPos( const size_t nPos )
/// delete the hint
/// precondition: pTextHt must be in this array
-void SwpHints::Delete( SwTextAttr* pTextHt )
+void SwpHints::Delete( SwTextAttr const * pTextHt )
{
const size_t nPos = GetIndexOf( pTextHt );
assert(SAL_MAX_SIZE != nPos);
diff --git a/sw/source/core/txtnode/txtatr2.cxx b/sw/source/core/txtnode/txtatr2.cxx
index 8abd4af0abfd..7efab4b169c5 100644
--- a/sw/source/core/txtnode/txtatr2.cxx
+++ b/sw/source/core/txtnode/txtatr2.cxx
@@ -69,10 +69,10 @@ void SwTextCharFormat::ModifyNotification( const SfxPoolItem* pOld, const SfxPoo
}
}
-bool SwTextCharFormat::GetInfo( SfxPoolItem& rInfo ) const
+bool SwTextCharFormat::GetInfo( SfxPoolItem const & rInfo ) const
{
if ( RES_AUTOFMT_DOCNODE != rInfo.Which() || !m_pTextNode ||
- &m_pTextNode->GetNodes() != static_cast<SwAutoFormatGetDocNode&>(rInfo).pNodes )
+ &m_pTextNode->GetNodes() != static_cast<SwAutoFormatGetDocNode const &>(rInfo).pNodes )
{
return true;
}
diff --git a/sw/source/core/txtnode/txtedt.cxx b/sw/source/core/txtnode/txtedt.cxx
index fa0724c85047..56b0c0c466cf 100644
--- a/sw/source/core/txtnode/txtedt.cxx
+++ b/sw/source/core/txtnode/txtedt.cxx
@@ -1568,7 +1568,7 @@ SwRect SwTextFrame::SmartTagScan()
return aRet;
}
-void SwTextFrame::CollectAutoCmplWrds( SwContentNode* pActNode, sal_Int32 nActPos )
+void SwTextFrame::CollectAutoCmplWrds( SwContentNode const * pActNode, sal_Int32 nActPos )
{
SwTextNode *pNode = GetTextNode();
if( pNode != pActNode || !nActPos )