summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-02-28 13:09:02 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-03-04 07:32:43 +0100
commit9865440d217d975206a3f91612f0666312bc8fd8 (patch)
tree7d5926e5bfe94c05a923ea68dba0ac6793c5a4a9 /sw
parente7f71c7ab675f238b61d7f28e7f79f51c7e19801 (diff)
new loplugin typedefparam
verify that parameters use the exact same typedef-names (if any) in definition and declaration Change-Id: I55d2817f599b0253904dce2d35a1a93967e15a77 Reviewed-on: https://gerrit.libreoffice.org/68439 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r--sw/inc/crsrsh.hxx2
-rw-r--r--sw/inc/doc.hxx4
-rw-r--r--sw/inc/swatrset.hxx6
-rw-r--r--sw/inc/swtypes.hxx3
-rw-r--r--sw/source/core/SwNumberTree/SwNumberTree.cxx4
-rw-r--r--sw/source/core/doc/docfmt.cxx2
-rw-r--r--sw/source/core/inc/frmtool.hxx10
-rw-r--r--sw/source/core/inc/paintfrm.hxx5
-rw-r--r--sw/source/core/view/viewsh.cxx2
-rw-r--r--sw/source/filter/basflt/fltini.cxx2
-rw-r--r--sw/source/filter/ww8/ww8scan.hxx16
11 files changed, 32 insertions, 24 deletions
diff --git a/sw/inc/crsrsh.hxx b/sw/inc/crsrsh.hxx
index 98895e664963..a732b8b8b669 100644
--- a/sw/inc/crsrsh.hxx
+++ b/sw/inc/crsrsh.hxx
@@ -802,7 +802,7 @@ public:
void SetAutoUpdateCells( bool bFlag ) { m_bAutoUpdateCells = bFlag; }
bool GetShadowCursorPos( const Point& rPt, SwFillMode eFillMode,
- SwRect& rRect, short& rOrient );
+ SwRect& rRect, sal_Int16& rOrient );
bool SetShadowCursorPos( const Point& rPt, SwFillMode eFillMode );
const SwRangeRedline* SelNextRedline();
diff --git a/sw/inc/doc.hxx b/sw/inc/doc.hxx
index e9b3023ce5be..b32263289b2b 100644
--- a/sw/inc/doc.hxx
+++ b/sw/inc/doc.hxx
@@ -1151,7 +1151,7 @@ public:
*/
const SwTable* InsertTable( const SwInsertTableOptions& rInsTableOpts, // HeadlineNoBorder
const SwPosition& rPos, sal_uInt16 nRows,
- sal_uInt16 nCols, short eAdjust,
+ sal_uInt16 nCols, sal_Int16 eAdjust,
const SwTableAutoFormat* pTAFormat = nullptr,
const std::vector<sal_uInt16> *pColArr = nullptr,
bool bCalledFromShell = false,
@@ -1164,7 +1164,7 @@ public:
// Create a balanced table out of the selected range.
const SwTable* TextToTable( const SwInsertTableOptions& rInsTableOpts, // HeadlineNoBorder,
const SwPaM& rRange, sal_Unicode cCh,
- short eAdjust,
+ sal_Int16 eAdjust,
const SwTableAutoFormat* );
// text to table conversion - API support
diff --git a/sw/inc/swatrset.hxx b/sw/inc/swatrset.hxx
index 397887d09429..d446dcddcc51 100644
--- a/sw/inc/swatrset.hxx
+++ b/sw/inc/swatrset.hxx
@@ -128,6 +128,10 @@ class SwTableBoxNumFormat;
class SwTableBoxFormula;
class SwTableBoxValue;
+namespace vcl {
+ typedef OutputDevice RenderContext;
+};
+
class SwAttrPool : public SfxItemPool
{
private:
@@ -318,7 +322,7 @@ public:
//Helper for filters to find true lineheight of a font
SW_DLLPUBLIC long AttrSetToLineHeight( const IDocumentSettingAccess& rIDocumentSettingAccess,
const SwAttrSet &rSet,
- const OutputDevice &rOut, sal_Int16 nScript);
+ const vcl::RenderContext &rOut, sal_Int16 nScript);
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/inc/swtypes.hxx b/sw/inc/swtypes.hxx
index b37c36407a72..dee697c2eed8 100644
--- a/sw/inc/swtypes.hxx
+++ b/sw/inc/swtypes.hxx
@@ -26,6 +26,7 @@
#include "swdllapi.h"
#include <o3tl/typed_flags_set.hxx>
#include <i18nlangtag/lang.h>
+#include <vcl/outdev.hxx>
namespace com { namespace sun { namespace star {
namespace linguistic2{
@@ -130,7 +131,7 @@ css::uno::Reference< css::linguistic2::XThesaurus > GetThesaurus();
css::uno::Reference< css::linguistic2::XLinguProperties > GetLinguPropertySet();
// Returns the twip size of this graphic.
-SW_DLLPUBLIC Size GetGraphicSizeTwip( const Graphic&, OutputDevice* pOutDev );
+SW_DLLPUBLIC Size GetGraphicSizeTwip( const Graphic&, vcl::RenderContext* pOutDev );
// Separator for jumps to different content types in document.
const sal_Unicode cMarkSeparator = '|';
diff --git a/sw/source/core/SwNumberTree/SwNumberTree.cxx b/sw/source/core/SwNumberTree/SwNumberTree.cxx
index 30adb4744335..e4f5c2efe713 100644
--- a/sw/source/core/SwNumberTree/SwNumberTree.cxx
+++ b/sw/source/core/SwNumberTree/SwNumberTree.cxx
@@ -297,7 +297,7 @@ void SwNumberTreeNode::Validate(const SwNumberTreeNode * pNode) const
}
}
-void SwNumberTreeNode::GetNumberVector_(vector<SwNumberTree::tSwNumTreeNumber> & rVector,
+void SwNumberTreeNode::GetNumberVector_(SwNumberTree::tNumberVector & rVector,
bool bValidate) const
{
if (mpParent)
@@ -675,7 +675,7 @@ SwNumberTree::tSwNumTreeNumber SwNumberTreeNode::GetNumber(bool bValidate)
}
-vector<SwNumberTree::tSwNumTreeNumber> SwNumberTreeNode::GetNumberVector() const
+SwNumberTree::tNumberVector SwNumberTreeNode::GetNumberVector() const
{
vector<SwNumberTree::tSwNumTreeNumber> aResult;
diff --git a/sw/source/core/doc/docfmt.cxx b/sw/source/core/doc/docfmt.cxx
index 22ff781213dd..9367874f24c5 100644
--- a/sw/source/core/doc/docfmt.cxx
+++ b/sw/source/core/doc/docfmt.cxx
@@ -2074,7 +2074,7 @@ SwFrameFormats::~SwFrameFormats()
DeleteAndDestroyAll();
}
-SwFrameFormats::iterator SwFrameFormats::find( const value_type& x ) const
+SwFrameFormats::const_iterator SwFrameFormats::find( const value_type& x ) const
{
ByTypeAndName::iterator it = m_TypeAndNameIndex.find(
boost::make_tuple(x->Which(), x->GetName(), x) );
diff --git a/sw/source/core/inc/frmtool.hxx b/sw/source/core/inc/frmtool.hxx
index 0790582777bf..7c76779cd658 100644
--- a/sw/source/core/inc/frmtool.hxx
+++ b/sw/source/core/inc/frmtool.hxx
@@ -75,7 +75,7 @@ void AppendAllObjs(const SwFrameFormats* pTable, const SwFrame* pSib);
// transparency, saved in the color of the brush item.
void DrawGraphic(
const SvxBrushItem *,
- OutputDevice *,
+ vcl::RenderContext *,
const SwRect &rOrg,
const SwRect &rOut,
const sal_uInt8 nGrfNum = GRFNUM_NO,
@@ -85,11 +85,11 @@ bool DrawFillAttributes(
const SwRect& rOriginalLayoutRect,
const SwRegionRects& rPaintRegion,
const basegfx::utils::B2DClipState& rClipState,
- OutputDevice& rOut);
+ vcl::RenderContext& rOut);
// RotGrfFlyFrame: Adapted to rotation
void paintGraphicUsingPrimitivesHelper(
- OutputDevice & rOutputDevice,
+ vcl::RenderContext & rOutputDevice,
GraphicObject const& rGraphicObj,
GraphicAttr const& rGraphicAttr,
const basegfx::B2DHomMatrix& rGraphicTransform,
@@ -103,7 +103,7 @@ void SwAlignRect( SwRect &rRect, const SwViewShell *pSh, const vcl::RenderContex
// method to align graphic rectangle
// Created declaration here to avoid <extern> declarations
-void SwAlignGrfRect( SwRect *pGrfRect, const OutputDevice &rOut );
+void SwAlignGrfRect( SwRect *pGrfRect, const vcl::RenderContext &rOut );
/**
* Paint border around a run of characters using frame painting code.
@@ -144,7 +144,7 @@ extern bool bDontCreateObjects;
extern bool bSetCompletePaintOnInvalidate;
// for table settings via keyboard
-long CalcRowRstHeight( SwLayoutFrame *pRow );
+SwTwips CalcRowRstHeight( SwLayoutFrame *pRow );
long CalcHeightWithFlys( const SwFrame *pFrame );
SwPageFrame *InsertNewPage( SwPageDesc &rDesc, SwFrame *pUpper,
diff --git a/sw/source/core/inc/paintfrm.hxx b/sw/source/core/inc/paintfrm.hxx
index 6f30539e6ffe..b3d4812d6aad 100644
--- a/sw/source/core/inc/paintfrm.hxx
+++ b/sw/source/core/inc/paintfrm.hxx
@@ -25,8 +25,11 @@
extern Color aGlobalRetoucheColor;
class OutputDevice;
+namespace vcl {
+ typedef OutputDevice RenderContext;
+};
-void SwCalcPixStatics( OutputDevice const *pOut );
+void SwCalcPixStatics( vcl::RenderContext const *pOut );
#endif // INCLUDED_SW_SOURCE_CORE_INC_PAINTFRM_HXX
diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx
index 006b33927a41..3d106bb195c4 100644
--- a/sw/source/core/view/viewsh.cxx
+++ b/sw/source/core/view/viewsh.cxx
@@ -2076,7 +2076,7 @@ SwRootFrame *SwViewShell::GetLayout() const
return mpLayout.get();
}
-OutputDevice& SwViewShell::GetRefDev() const
+vcl::RenderContext& SwViewShell::GetRefDev() const
{
OutputDevice* pTmpOut = nullptr;
if ( GetWin() &&
diff --git a/sw/source/filter/basflt/fltini.cxx b/sw/source/filter/basflt/fltini.cxx
index 0e7b6622a260..c42086edb0e8 100644
--- a/sw/source/filter/basflt/fltini.cxx
+++ b/sw/source/filter/basflt/fltini.cxx
@@ -184,7 +184,7 @@ void GetWriter( const OUString& rFltName, const OUString& rBaseURL, WriterRef& x
}
}
-SwRead GetReader( const OUString& rFltName )
+Reader* GetReader( const OUString& rFltName )
{
SwRead pRead = nullptr;
for( int n = 0; n < MAXFILTER; ++n )
diff --git a/sw/source/filter/ww8/ww8scan.hxx b/sw/source/filter/ww8/ww8scan.hxx
index a6fa398d9076..b0ba35346da4 100644
--- a/sw/source/filter/ww8/ww8scan.hxx
+++ b/sw/source/filter/ww8/ww8scan.hxx
@@ -452,7 +452,7 @@ public:
virtual sal_uInt32 GetIdx() const override;
virtual void SetIdx(sal_uInt32 nI) override;
virtual bool SeekPos(WW8_CP nCpPos) override;
- virtual WW8_FC Where() override;
+ virtual WW8_CP Where() override;
virtual void GetSprms( WW8PLCFxDesc* p ) override;
virtual void advance() override;
@@ -477,7 +477,7 @@ public:
virtual sal_uInt32 GetIdx() const override;
virtual void SetIdx(sal_uInt32 nI) override;
virtual bool SeekPos(WW8_CP nCpPos) override;
- virtual WW8_FC Where() override;
+ virtual WW8_CP Where() override;
virtual long GetNoSprms( WW8_CP& rStart, WW8_CP&, sal_Int32& rLen ) override;
virtual void advance() override;
WW8_CP CurrentPieceStartFc2Cp( WW8_FC nStartPos );
@@ -680,7 +680,7 @@ public:
virtual sal_uInt32 GetIdx() const override;
virtual void SetIdx(sal_uInt32 nIdx) override;
virtual bool SeekPos(WW8_CP nCpPos) override;
- virtual WW8_FC Where() override;
+ virtual WW8_CP Where() override;
virtual void GetSprms( WW8PLCFxDesc* p ) override;
virtual void advance() override;
SprmResult HasSprm( sal_uInt16 nId ) const;
@@ -708,7 +708,7 @@ public:
virtual sal_uInt32 GetIdx() const override;
virtual void SetIdx(sal_uInt32 nIdx) override;
virtual bool SeekPos(WW8_CP nCpPos) override;
- virtual WW8_FC Where() override;
+ virtual WW8_CP Where() override;
// returns reference descriptors
const void* GetData() const
@@ -736,7 +736,7 @@ public:
virtual sal_uInt32 GetIdx() const override;
virtual void SetIdx(sal_uInt32 nIdx) override;
virtual bool SeekPos(WW8_CP nCpPos) override;
- virtual WW8_FC Where() override;
+ virtual WW8_CP Where() override;
virtual void GetSprms(WW8PLCFxDesc* p) override;
virtual void advance() override;
bool StartPosIsFieldStart();
@@ -769,7 +769,7 @@ public:
virtual sal_uInt32 GetIdx2() const override;
virtual void SetIdx2(sal_uInt32 nIdx) override;
virtual bool SeekPos(WW8_CP nCpPos) override;
- virtual WW8_FC Where() override;
+ virtual WW8_CP Where() override;
virtual long GetNoSprms( WW8_CP& rStart, WW8_CP& rEnd, sal_Int32& rLen ) override;
virtual void advance() override;
const OUString* GetName() const;
@@ -806,7 +806,7 @@ public:
virtual sal_uInt32 GetIdx2() const override;
virtual void SetIdx2(sal_uInt32 nIdx) override;
virtual bool SeekPos(WW8_CP nCpPos) override;
- virtual WW8_FC Where() override;
+ virtual WW8_CP Where() override;
virtual long GetNoSprms( WW8_CP& rStart, WW8_CP& rEnd, sal_Int32& rLen ) override;
virtual void advance() override;
@@ -836,7 +836,7 @@ public:
virtual sal_uInt32 GetIdx2() const override;
virtual void SetIdx2(sal_uInt32 nIdx) override;
virtual bool SeekPos(WW8_CP nCpPos) override;
- virtual WW8_FC Where() override;
+ virtual WW8_CP Where() override;
virtual long GetNoSprms(WW8_CP& rStart, WW8_CP& rEnd, sal_Int32& rLen) override;
virtual void advance() override;