summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-08-22 10:02:35 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-08-22 11:04:05 +0200
commit3be72fe233b3e6d7aeb267f6c82d8bf9759b39ef (patch)
treea8304c473bac0da12a6b5d35f7841cd61a13b01c
parentb5c5cccabe68dc2de84cee4ef041f52268e5b8b4 (diff)
loplugin:constmethod in vcl
Change-Id: I20545527b117c9562b91076b748fb3e2659d2497 Reviewed-on: https://gerrit.libreoffice.org/77944 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--include/vcl/BitmapTools.hxx2
-rw-r--r--include/vcl/GraphicNativeMetadata.hxx2
-rw-r--r--include/vcl/button.hxx2
-rw-r--r--include/vcl/cursor.hxx2
-rw-r--r--include/vcl/dialog.hxx2
-rw-r--r--include/vcl/filter/pdfdocument.hxx8
-rw-r--r--include/vcl/graph.hxx2
-rw-r--r--include/vcl/graphicfilter.hxx6
-rw-r--r--include/vcl/metaact.hxx2
-rw-r--r--include/vcl/opengl/OpenGLContext.hxx4
-rw-r--r--include/vcl/pdfextoutdevdata.hxx4
-rw-r--r--include/vcl/pdfwriter.hxx2
-rw-r--r--include/vcl/print.hxx2
-rw-r--r--include/vcl/roadmap.hxx2
-rw-r--r--include/vcl/svlbitm.hxx2
-rw-r--r--include/vcl/syschild.hxx2
-rw-r--r--include/vcl/texteng.hxx4
-rw-r--r--include/vcl/uitest/logger.hxx2
-rw-r--r--include/vcl/vectorgraphicdata.hxx2
-rw-r--r--include/vcl/window.hxx4
-rw-r--r--vcl/inc/FileDefinitionWidgetDraw.hxx2
-rw-r--r--vcl/inc/impgraph.hxx2
-rw-r--r--vcl/inc/opengl/FixedTextureAtlas.hxx2
-rw-r--r--vcl/inc/opengl/RenderList.hxx6
-rw-r--r--vcl/inc/printdlg.hxx6
-rw-r--r--vcl/inc/salframe.hxx2
-rw-r--r--vcl/inc/scrptrun.h12
-rw-r--r--vcl/inc/unx/cpdmgr.hxx2
-rw-r--r--vcl/inc/unx/gtk/gtkinst.hxx2
-rw-r--r--vcl/inc/unx/gtk/gtksalmenu.hxx2
-rw-r--r--vcl/inc/unx/i18n_ic.hxx2
-rw-r--r--vcl/inc/unx/printergfx.hxx2
-rw-r--r--vcl/inc/unx/salobj.h2
-rw-r--r--vcl/inc/widgetdraw/WidgetDefinitionReader.hxx2
-rw-r--r--vcl/opengl/PackedTextureAtlas.cxx4
-rw-r--r--vcl/qa/cppunit/lifecycle.cxx2
-rw-r--r--vcl/source/app/salvtables.cxx2
-rw-r--r--vcl/source/control/roadmap.cxx2
-rw-r--r--vcl/source/filter/graphicfilter.cxx6
-rw-r--r--vcl/source/filter/ipdf/pdfdocument.cxx11
-rw-r--r--vcl/source/filter/jpeg/Exif.cxx2
-rw-r--r--vcl/source/filter/jpeg/Exif.hxx6
-rw-r--r--vcl/source/gdi/WidgetDefinitionReader.cxx4
-rw-r--r--vcl/source/gdi/graph.cxx2
-rw-r--r--vcl/source/gdi/impgraph.cxx2
-rw-r--r--vcl/source/gdi/pdfextoutdevdata.cxx2
-rw-r--r--vcl/source/gdi/pdfwriter.cxx2
-rw-r--r--vcl/source/gdi/print3.cxx2
-rw-r--r--vcl/source/gdi/salgdilayout.cxx2
-rw-r--r--vcl/source/gdi/vectorgraphicdata.cxx2
-rw-r--r--vcl/source/treelist/svlbitm.cxx2
-rw-r--r--vcl/source/window/cursor.cxx2
-rw-r--r--vcl/source/window/dialog.cxx2
-rw-r--r--vcl/source/window/menubarwindow.hxx2
-rw-r--r--vcl/source/window/mouse.cxx2
-rw-r--r--vcl/source/window/printdlg.cxx6
-rw-r--r--vcl/source/window/syschild.cxx2
-rw-r--r--vcl/source/window/window.cxx2
-rw-r--r--vcl/unx/generic/dtrans/X11_selection.hxx2
-rw-r--r--vcl/unx/generic/print/glyphset.hxx4
-rw-r--r--vcl/unx/generic/print/prtsetup.cxx8
-rw-r--r--vcl/unx/generic/print/prtsetup.hxx8
-rw-r--r--vcl/unx/generic/printer/cpdmgr.cxx2
-rw-r--r--vcl/unx/gtk/gtkinst.cxx2
-rw-r--r--vcl/workben/vcldemo.cxx4
65 files changed, 105 insertions, 102 deletions
diff --git a/include/vcl/BitmapTools.hxx b/include/vcl/BitmapTools.hxx
index c15fdf9e16b8..1cf13d4c7de8 100644
--- a/include/vcl/BitmapTools.hxx
+++ b/include/vcl/BitmapTools.hxx
@@ -80,7 +80,7 @@ public:
void SetPixel(long nY, long nX, BitmapColor nColor) = delete;
long Height() { return maSize.Height(); }
long Width() { return maSize.Width(); }
- sal_uInt8 GetBitCount() { return mnBitCount; }
+ sal_uInt8 GetBitCount() const { return mnBitCount; }
};
BitmapEx VCL_DLLPUBLIC loadFromName(const OUString& rFileName, const ImageLoadFlags eFlags = ImageLoadFlags::NONE);
diff --git a/include/vcl/GraphicNativeMetadata.hxx b/include/vcl/GraphicNativeMetadata.hxx
index 4ae29276205a..b6b162556e76 100644
--- a/include/vcl/GraphicNativeMetadata.hxx
+++ b/include/vcl/GraphicNativeMetadata.hxx
@@ -31,7 +31,7 @@ public:
~GraphicNativeMetadata();
bool read(Graphic const & rGraphic);
- sal_uInt16 getRotation() { return mRotation;}
+ sal_uInt16 getRotation() const { return mRotation;}
};
#endif // INCLUDED_VCL_GRAPHICNATIVEMETADATA_HXX
diff --git a/include/vcl/button.hxx b/include/vcl/button.hxx
index d6f39bb6f8f2..53192fc211c1 100644
--- a/include/vcl/button.hxx
+++ b/include/vcl/button.hxx
@@ -161,7 +161,7 @@ public:
mbIsAction = bIsAction;
}
- bool isAction()
+ bool isAction() const
{
return mbIsAction;
}
diff --git a/include/vcl/cursor.hxx b/include/vcl/cursor.hxx
index 714d6f569e80..c8e46da8082c 100644
--- a/include/vcl/cursor.hxx
+++ b/include/vcl/cursor.hxx
@@ -100,7 +100,7 @@ public:
private:
void LOKNotify( vcl::Window* pWindow, const OUString& rAction );
- bool ImplPrepForDraw(OutputDevice* pDevice, ImplCursorData& rData);
+ bool ImplPrepForDraw(const OutputDevice* pDevice, ImplCursorData& rData);
void ImplRestore();
void ImplDoShow( bool bDrawDirect, bool bRestore );
bool ImplDoHide( bool bStop );
diff --git a/include/vcl/dialog.hxx b/include/vcl/dialog.hxx
index 056c448ce251..e2ddea74be78 100644
--- a/include/vcl/dialog.hxx
+++ b/include/vcl/dialog.hxx
@@ -179,7 +179,7 @@ public:
void add_button(PushButton* pButton, int nResponse, bool bTransferOwnership);
void set_default_response(int nResponse);
- int get_default_response();
+ int get_default_response() const;
vcl::Window* get_widget_for_response(int nResponse);
};
diff --git a/include/vcl/filter/pdfdocument.hxx b/include/vcl/filter/pdfdocument.hxx
index f78eab2b5985..023882b8e8a2 100644
--- a/include/vcl/filter/pdfdocument.hxx
+++ b/include/vcl/filter/pdfdocument.hxx
@@ -131,9 +131,9 @@ public:
/// Access to the stream of the object, if it has any.
PDFStreamElement* GetStream() const;
void SetArrayOffset(sal_uInt64 nArrayOffset);
- sal_uInt64 GetArrayOffset();
+ sal_uInt64 GetArrayOffset() const;
void SetArrayLength(sal_uInt64 nArrayLength);
- sal_uInt64 GetArrayLength();
+ sal_uInt64 GetArrayLength() const;
PDFArrayElement* GetArray() const;
/// Parse objects stored in this object stream.
void ParseStoredObjects();
@@ -154,7 +154,7 @@ public:
PDFArrayElement(PDFObjectElement* pObject);
bool Read(SvStream& rStream) override;
void PushBack(PDFElement* pElement);
- const std::vector<PDFElement*>& GetElements();
+ const std::vector<PDFElement*>& GetElements() const;
};
/// Reference object: something with a unique ID.
@@ -397,7 +397,7 @@ public:
/// Instead of all whitespace, just skip CR and NL characters.
static void SkipLineBreaks(SvStream& rStream);
size_t GetObjectOffset(size_t nIndex) const;
- const std::vector<std::unique_ptr<PDFElement>>& GetElements();
+ const std::vector<std::unique_ptr<PDFElement>>& GetElements() const;
std::vector<PDFObjectElement*> GetPages();
/// Remember the end location of an EOF token.
void PushBackEOF(size_t nOffset);
diff --git a/include/vcl/graph.hxx b/include/vcl/graph.hxx
index d49a8a2ce512..4adac78b48c4 100644
--- a/include/vcl/graph.hxx
+++ b/include/vcl/graph.hxx
@@ -205,7 +205,7 @@ public:
std::shared_ptr<GraphicReader>& GetContext();
void SetContext( const std::shared_ptr<GraphicReader> &pReader );
void SetDummyContext(bool value);
- bool IsDummyContext();
+ bool IsDummyContext() const;
private:
friend class GraphicObject;
diff --git a/include/vcl/graphicfilter.hxx b/include/vcl/graphicfilter.hxx
index 2e8dda3c0d2d..14373039b684 100644
--- a/include/vcl/graphicfilter.hxx
+++ b/include/vcl/graphicfilter.hxx
@@ -233,7 +233,7 @@ public:
GraphicFilter( bool bUseConfig = true );
~GraphicFilter();
- sal_uInt16 GetImportFormatCount();
+ sal_uInt16 GetImportFormatCount() const;
sal_uInt16 GetImportFormatNumber( const OUString& rFormatName );
sal_uInt16 GetImportFormatNumberForShortName( const OUString& rShortName );
sal_uInt16 GetImportFormatNumberForTypeName( const OUString& rType );
@@ -245,7 +245,7 @@ public:
OUString GetImportFormatShortName( sal_uInt16 nFormat );
OUString GetImportWildcard( sal_uInt16 nFormat, sal_Int32 nEntry );
- sal_uInt16 GetExportFormatCount();
+ sal_uInt16 GetExportFormatCount() const;
sal_uInt16 GetExportFormatNumber( const OUString& rFormatName );
sal_uInt16 GetExportFormatNumberForMediaType( const OUString& rShortName );
sal_uInt16 GetExportFormatNumberForShortName( const OUString& rShortName );
@@ -295,7 +295,7 @@ public:
WmfExternal const *pExtHeader = nullptr );
// Setting sizeLimit limits how much will be read from the stream.
- Graphic ImportUnloadedGraphic(SvStream& rIStream, sal_uInt64 sizeLimit = 0, Size* pSizeHint = nullptr);
+ Graphic ImportUnloadedGraphic(SvStream& rIStream, sal_uInt64 sizeLimit = 0, const Size* pSizeHint = nullptr);
const FilterErrorEx& GetLastError() const { return *pErrorEx;}
void ResetLastError();
diff --git a/include/vcl/metaact.hxx b/include/vcl/metaact.hxx
index ae77e39520b8..7dea93dce676 100644
--- a/include/vcl/metaact.hxx
+++ b/include/vcl/metaact.hxx
@@ -76,7 +76,7 @@ public:
virtual void Execute( OutputDevice* pOut );
- oslInterlockedCount GetRefCount() { return m_nCount; }
+ oslInterlockedCount GetRefCount() const { return m_nCount; }
virtual rtl::Reference<MetaAction> Clone();
diff --git a/include/vcl/opengl/OpenGLContext.hxx b/include/vcl/opengl/OpenGLContext.hxx
index 7e7842041dd6..c6807a6fe863 100644
--- a/include/vcl/opengl/OpenGLContext.hxx
+++ b/include/vcl/opengl/OpenGLContext.hxx
@@ -129,14 +129,14 @@ public:
SystemChildWindow* getChildWindow();
const SystemChildWindow* getChildWindow() const;
- bool isInitialized()
+ bool isInitialized() const
{
return mbInitialized;
}
/// VCL promiscuously re-uses its own contexts:
void setVCLOnly() { mbVCLOnly = true; }
- bool isVCLOnly() { return mbVCLOnly; }
+ bool isVCLOnly() const { return mbVCLOnly; }
virtual SystemWindowData generateWinData(vcl::Window* pParent, bool bRequestLegacyContext);
diff --git a/include/vcl/pdfextoutdevdata.hxx b/include/vcl/pdfextoutdevdata.hxx
index 4c14283b03a8..5a932570af6a 100644
--- a/include/vcl/pdfextoutdevdata.hxx
+++ b/include/vcl/pdfextoutdevdata.hxx
@@ -141,7 +141,7 @@ public:
void SetDocumentLocale( const css::lang::Locale& rLoc );
std::vector< PDFExtOutDevBookmarkEntry >& GetBookmarks() { return maBookmarks;}
- const std::vector<OUString>& GetChapterNames() { return maChapterNames; }
+ const std::vector<OUString>& GetChapterNames() const { return maChapterNames; }
const Graphic& GetCurrentGraphic() const;
@@ -387,7 +387,7 @@ public:
@returns
the id of the current structure element
*/
- sal_Int32 GetCurrentStructureElement();
+ sal_Int32 GetCurrentStructureElement() const;
/** set a structure attribute on the current structural element
diff --git a/include/vcl/pdfwriter.hxx b/include/vcl/pdfwriter.hxx
index adf19cd1272c..fe24e50ad11f 100644
--- a/include/vcl/pdfwriter.hxx
+++ b/include/vcl/pdfwriter.hxx
@@ -689,7 +689,7 @@ The following structure describes the permissions used in PDF security
* this should enable the producer to give feedback about
* any anomalies that might have occurred
*/
- std::set< ErrorCode > const & GetErrors();
+ std::set< ErrorCode > const & GetErrors() const;
// uses 128bit encryption
static css::uno::Reference< css::beans::XMaterialHolder >
diff --git a/include/vcl/print.hxx b/include/vcl/print.hxx
index 854c08d96660..d25af2b42bd2 100644
--- a/include/vcl/print.hxx
+++ b/include/vcl/print.hxx
@@ -526,7 +526,7 @@ public:
// don't use outside vcl. Some of these are exported for
// the benefit of vcl's plugins.
// Still: DO NOT USE OUTSIDE VCL
- int getFilteredPageCount();
+ int getFilteredPageCount() const;
VCL_DLLPRIVATE PageSize getPageFile( int i_inUnfilteredPage, GDIMetaFile& rMtf,
bool i_bMayUseCache = false );
PageSize getFilteredPageFile( int i_nFilteredPage, GDIMetaFile& o_rMtf,
diff --git a/include/vcl/roadmap.hxx b/include/vcl/roadmap.hxx
index 1b58a194c0fb..f3811ba56812 100644
--- a/include/vcl/roadmap.hxx
+++ b/include/vcl/roadmap.hxx
@@ -55,7 +55,7 @@ public:
void ChangeRoadmapItemID( ItemId _nID, ItemId NewID );
void SetRoadmapInteractive( bool _bInteractive );
- bool IsRoadmapInteractive();
+ bool IsRoadmapInteractive() const;
void SetRoadmapComplete( bool _bComplete );
bool IsRoadmapComplete() const;
diff --git a/include/vcl/svlbitm.hxx b/include/vcl/svlbitm.hxx
index c28bed22f460..9484535ce81f 100644
--- a/include/vcl/svlbitm.hxx
+++ b/include/vcl/svlbitm.hxx
@@ -80,7 +80,7 @@ public:
long Width();
long Height();
void SetLink( const Link<SvLBoxButtonData*,void>& rLink) { aLink=rLink; }
- bool IsRadio();
+ bool IsRadio() const;
// as buttons are not derived from LinkHdl
void CallLink();
diff --git a/include/vcl/syschild.hxx b/include/vcl/syschild.hxx
index e15295e79a78..bdfd913fe929 100644
--- a/include/vcl/syschild.hxx
+++ b/include/vcl/syschild.hxx
@@ -56,7 +56,7 @@ public:
//no visible flash
void SetLeaveEnterBackgrounds(const css::uno::Sequence<css::uno::Any>& rLeaveArgs, const css::uno::Sequence<css::uno::Any>& rEnterArgs);
// return the platform specific handle/id of this window;
- sal_IntPtr GetParentWindowHandle();
+ sal_IntPtr GetParentWindowHandle() const;
void* CreateGStreamerSink();
};
diff --git a/include/vcl/texteng.hxx b/include/vcl/texteng.hxx
index 1df2b87c702b..916a27d01c08 100644
--- a/include/vcl/texteng.hxx
+++ b/include/vcl/texteng.hxx
@@ -263,12 +263,12 @@ public:
void UndoActionStart( sal_uInt16 nId = 0 );
void UndoActionEnd();
void InsertUndo( std::unique_ptr<TextUndo> pUndo, bool bTryMerge = false );
- bool IsInUndo() { return mbIsInUndo; }
+ bool IsInUndo() const { return mbIsInUndo; }
void SetIsInUndo( bool bInUndo ) { mbIsInUndo = bInUndo; }
void ResetUndo();
void EnableUndo( bool bEnable );
- bool IsUndoEnabled() { return mbUndoEnabled; }
+ bool IsUndoEnabled() const { return mbUndoEnabled; }
void SetModified( bool bModified ) { mbModified = bModified; }
bool IsModified() const { return mbModified; }
diff --git a/include/vcl/uitest/logger.hxx b/include/vcl/uitest/logger.hxx
index 450285c5c247..8bda3548875d 100644
--- a/include/vcl/uitest/logger.hxx
+++ b/include/vcl/uitest/logger.hxx
@@ -73,7 +73,7 @@ public:
void setAppName(OUString name) { app_name = name; }
- OUString getAppName() { return app_name; }
+ OUString getAppName() const { return app_name; }
};
#endif
diff --git a/include/vcl/vectorgraphicdata.hxx b/include/vcl/vectorgraphicdata.hxx
index 7a45533b8f6b..b64e79d8d936 100644
--- a/include/vcl/vectorgraphicdata.hxx
+++ b/include/vcl/vectorgraphicdata.hxx
@@ -96,7 +96,7 @@ public:
const VectorGraphicDataArray& getVectorGraphicDataArray() const { return maVectorGraphicDataArray; }
sal_uInt32 getVectorGraphicDataArrayLength() const { return maVectorGraphicDataArray.getLength(); }
enum class State { UNPARSED, PARSED };
- std::pair<State, size_t> getSizeBytes();
+ std::pair<State, size_t> getSizeBytes() const;
const OUString& getPath() const { return maPath; }
const VectorGraphicDataType& getVectorGraphicDataType() const { return meVectorGraphicDataType; }
diff --git a/include/vcl/window.hxx b/include/vcl/window.hxx
index a93b1da700a8..823456ff077e 100644
--- a/include/vcl/window.hxx
+++ b/include/vcl/window.hxx
@@ -865,7 +865,7 @@ public:
Point maPos; // mouse position in output coordinates
};
PointerState GetPointerState();
- bool IsMouseOver();
+ bool IsMouseOver() const;
void SetInputContext( const InputContext& rInputContext );
const InputContext& GetInputContext() const;
@@ -1083,7 +1083,7 @@ public:
bool HasFocus() const;
bool HasChildPathFocus( bool bSystemWindow = false ) const;
bool IsActive() const;
- bool HasActiveChildFrame();
+ bool HasActiveChildFrame() const;
GetFocusFlags GetGetFocusFlags() const;
void GrabFocusToDocument();
diff --git a/vcl/inc/FileDefinitionWidgetDraw.hxx b/vcl/inc/FileDefinitionWidgetDraw.hxx
index 9ce2122299d1..7e3d398fb0f8 100644
--- a/vcl/inc/FileDefinitionWidgetDraw.hxx
+++ b/vcl/inc/FileDefinitionWidgetDraw.hxx
@@ -32,7 +32,7 @@ private:
public:
FileDefinitionWidgetDraw(SalGraphics& rGraphics);
- bool isActive() { return m_bIsActive; }
+ bool isActive() const { return m_bIsActive; }
bool isNativeControlSupported(ControlType eType, ControlPart ePart) override;
diff --git a/vcl/inc/impgraph.hxx b/vcl/inc/impgraph.hxx
index 1b0a273d845d..76e00febcbde 100644
--- a/vcl/inc/impgraph.hxx
+++ b/vcl/inc/impgraph.hxx
@@ -115,7 +115,7 @@ public:
ImpGraphic( const GDIMetaFile& rMtf );
~ImpGraphic();
- void ImplSetPrepared(bool bAnimated, Size* pSizeHint);
+ void ImplSetPrepared(bool bAnimated, const Size* pSizeHint);
private:
diff --git a/vcl/inc/opengl/FixedTextureAtlas.hxx b/vcl/inc/opengl/FixedTextureAtlas.hxx
index 145ddf52f5e1..0523403b2b2a 100644
--- a/vcl/inc/opengl/FixedTextureAtlas.hxx
+++ b/vcl/inc/opengl/FixedTextureAtlas.hxx
@@ -36,7 +36,7 @@ public:
OpenGLTexture InsertBuffer(int nWidth, int nHeight, int nFormat, int nType, sal_uInt8 const * pData);
OpenGLTexture Reserve(int nWidth, int nHeight);
- int GetSubtextureSize()
+ int GetSubtextureSize() const
{
return mSubTextureSize;
}
diff --git a/vcl/inc/opengl/RenderList.hxx b/vcl/inc/opengl/RenderList.hxx
index bb46206ea7ff..e4df834755d6 100644
--- a/vcl/inc/opengl/RenderList.hxx
+++ b/vcl/inc/opengl/RenderList.hxx
@@ -56,17 +56,17 @@ struct RenderEntry
std::unordered_map<GLuint, RenderTextureParameters> maTextureParametersMap;
- bool hasTriangles()
+ bool hasTriangles() const
{
return !maTriangleParameters.maVertices.empty();
}
- bool hasLines()
+ bool hasLines() const
{
return !maLineParameters.maVertices.empty();
}
- bool hasTextures()
+ bool hasTextures() const
{
return !maTextureParametersMap.empty();
}
diff --git a/vcl/inc/printdlg.hxx b/vcl/inc/printdlg.hxx
index d034bbd3b2a1..137f6a47a40c 100644
--- a/vcl/inc/printdlg.hxx
+++ b/vcl/inc/printdlg.hxx
@@ -114,10 +114,10 @@ namespace vcl
virtual ~PrintDialog() override;
virtual void dispose() override;
- bool isPrintToFile();
- bool isCollate();
+ bool isPrintToFile() const;
+ bool isCollate() const;
bool isSingleJobs() const { return mbSingleJobs; };
- bool hasPreview();
+ bool hasPreview() const;
void setPaperSizes();
void previewForward();
diff --git a/vcl/inc/salframe.hxx b/vcl/inc/salframe.hxx
index e190d3e758b5..d4cdcba9b545 100644
--- a/vcl/inc/salframe.hxx
+++ b/vcl/inc/salframe.hxx
@@ -161,7 +161,7 @@ public:
virtual void GetWorkArea( tools::Rectangle& rRect ) = 0;
virtual SalFrame* GetParent() const = 0;
// Note: x will be mirrored at parent if UI mirroring is active
- SalFrameGeometry GetGeometry();
+ SalFrameGeometry GetGeometry() const;
const SalFrameGeometry& GetUnmirroredGeometry() const { return maGeometry; }
virtual void SetWindowState( const SalFrameState* pState ) = 0;
diff --git a/vcl/inc/scrptrun.h b/vcl/inc/scrptrun.h
index 097f6302f38d..3d1d706a6f3d 100644
--- a/vcl/inc/scrptrun.h
+++ b/vcl/inc/scrptrun.h
@@ -67,11 +67,11 @@ public:
void reset(const UChar chars[], int32_t start, int32_t length);
- int32_t getScriptStart();
+ int32_t getScriptStart() const;
- int32_t getScriptEnd();
+ int32_t getScriptEnd() const;
- UScriptCode getScriptCode();
+ UScriptCode getScriptCode() const;
UBool next();
@@ -114,17 +114,17 @@ inline ScriptRun::ScriptRun(const UChar chars[], int32_t length)
reset(chars, 0, length);
}
-inline int32_t ScriptRun::getScriptStart()
+inline int32_t ScriptRun::getScriptStart() const
{
return scriptStart;
}
-inline int32_t ScriptRun::getScriptEnd()
+inline int32_t ScriptRun::getScriptEnd() const
{
return scriptEnd;
}
-inline UScriptCode ScriptRun::getScriptCode()
+inline UScriptCode ScriptRun::getScriptCode() const
{
return scriptCode;
}
diff --git a/vcl/inc/unx/cpdmgr.hxx b/vcl/inc/unx/cpdmgr.hxx
index ed1929744163..6449355a1501 100644
--- a/vcl/inc/unx/cpdmgr.hxx
+++ b/vcl/inc/unx/cpdmgr.hxx
@@ -99,7 +99,7 @@ public:
GDBusProxy* getProxy(const std::string& target);
void addBackend( std::pair< std::string, GDBusProxy * > pair );
void addTempBackend(const std::pair<std::string, gchar*>& pair);
- std::vector<std::pair<std::string, gchar*>> const & getTempBackends();
+ std::vector<std::pair<std::string, gchar*>> const & getTempBackends() const;
void addNewPrinter( const OUString&, const OUString&, CPDPrinter * );
#endif
diff --git a/vcl/inc/unx/gtk/gtkinst.hxx b/vcl/inc/unx/gtk/gtkinst.hxx
index cc2455a42eb8..2ed92b0b511d 100644
--- a/vcl/inc/unx/gtk/gtkinst.hxx
+++ b/vcl/inc/unx/gtk/gtkinst.hxx
@@ -247,7 +247,7 @@ public:
#endif
virtual const cairo_font_options_t* GetCairoFontOptions() override;
- const cairo_font_options_t* GetLastSeenCairoFontOptions();
+ const cairo_font_options_t* GetLastSeenCairoFontOptions() const;
void ResetLastSeenCairoFontOptions(const cairo_font_options_t* pOptions);
void RemoveTimer ();
diff --git a/vcl/inc/unx/gtk/gtksalmenu.hxx b/vcl/inc/unx/gtk/gtksalmenu.hxx
index 858584398974..2d812cad3962 100644
--- a/vcl/inc/unx/gtk/gtksalmenu.hxx
+++ b/vcl/inc/unx/gtk/gtksalmenu.hxx
@@ -105,7 +105,7 @@ public:
void SetMenu( Menu* pMenu ) { mpVCLMenu = pMenu; }
Menu* GetMenu() { return mpVCLMenu; }
void SetMenuModel(GMenuModel* pMenuModel);
- unsigned GetItemCount() { return maItems.size(); }
+ unsigned GetItemCount() const { return maItems.size(); }
GtkSalMenuItem* GetItemAtPos( unsigned nPos ) { return maItems[ nPos ]; }
void SetActionGroup( GActionGroup* pActionGroup ) { mpActionGroup = pActionGroup; }
bool IsItemVisible( unsigned nPos );
diff --git a/vcl/inc/unx/i18n_ic.hxx b/vcl/inc/unx/i18n_ic.hxx
index c07bc6f3a3fb..055b8616285e 100644
--- a/vcl/inc/unx/i18n_ic.hxx
+++ b/vcl/inc/unx/i18n_ic.hxx
@@ -57,7 +57,7 @@ private:
public:
Bool UseContext() { return mbUseable; }
- bool IsPreeditMode() { return maClientData.eState == PreeditStatus::Active; }
+ bool IsPreeditMode() const { return maClientData.eState == PreeditStatus::Active; }
XIC GetContext() { return maContext; }
void ExtendEventMask( ::Window aFocusWindow );
diff --git a/vcl/inc/unx/printergfx.hxx b/vcl/inc/unx/printergfx.hxx
index a8f0dc0ab7c2..10d83546c49e 100644
--- a/vcl/inc/unx/printergfx.hxx
+++ b/vcl/inc/unx/printergfx.hxx
@@ -266,7 +266,7 @@ public:
void Clear();
// query depth
- sal_uInt16 GetBitCount () { return mnDepth;}
+ sal_uInt16 GetBitCount () const { return mnDepth;}
// clip region
void ResetClipRegion ();
diff --git a/vcl/inc/unx/salobj.h b/vcl/inc/unx/salobj.h
index 0795f20115db..bef98cbbdf6e 100644
--- a/vcl/inc/unx/salobj.h
+++ b/vcl/inc/unx/salobj.h
@@ -40,7 +40,7 @@ public:
return ClipRectangleList.get(); }
void ResetClipRegion() {
numClipRectangles = 0; }
- int GetRectangleCount() {
+ int GetRectangleCount() const {
return numClipRectangles; }
private:
diff --git a/vcl/inc/widgetdraw/WidgetDefinitionReader.hxx b/vcl/inc/widgetdraw/WidgetDefinitionReader.hxx
index 94c7d49e18cd..49ecfac7a6ed 100644
--- a/vcl/inc/widgetdraw/WidgetDefinitionReader.hxx
+++ b/vcl/inc/widgetdraw/WidgetDefinitionReader.hxx
@@ -31,7 +31,7 @@ private:
void readPart(tools::XmlWalker& rWalker, std::shared_ptr<WidgetDefinitionPart> rpPart);
void readDrawingDefinition(tools::XmlWalker& rWalker,
- std::shared_ptr<WidgetDefinitionState>& rStates);
+ const std::shared_ptr<WidgetDefinitionState>& rStates);
public:
WidgetDefinitionReader(OUString const& rDefinitionFile, OUString const& rResourcePath);
diff --git a/vcl/opengl/PackedTextureAtlas.cxx b/vcl/opengl/PackedTextureAtlas.cxx
index 0e3bdc5f1d5c..dd9310103e35 100644
--- a/vcl/opengl/PackedTextureAtlas.cxx
+++ b/vcl/opengl/PackedTextureAtlas.cxx
@@ -28,7 +28,7 @@ struct Node
explicit Node(int nWidth, int nHeight);
explicit Node(tools::Rectangle const & aRectangle);
- bool isLeaf();
+ bool isLeaf() const;
Node* insert(int nWidth, int nHeight, int nPadding);
};
@@ -46,7 +46,7 @@ Node::Node(tools::Rectangle const & aRectangle)
, mOccupied(false)
{}
-bool Node::isLeaf() { return mLeftNode == nullptr && mRightNode == nullptr; }
+bool Node::isLeaf() const { return mLeftNode == nullptr && mRightNode == nullptr; }
Node* Node::insert(int nWidth, int nHeight, int nPadding)
{
diff --git a/vcl/qa/cppunit/lifecycle.cxx b/vcl/qa/cppunit/lifecycle.cxx
index 32a29e33c326..5b97c0114962 100644
--- a/vcl/qa/cppunit/lifecycle.cxx
+++ b/vcl/qa/cppunit/lifecycle.cxx
@@ -253,7 +253,7 @@ public:
pNew->mpRef = static_cast<void *>(static_cast<vcl::Window *>(pNew->mxRef));
return pNew;
}
- const VclPtr<vcl::Window>& getRef() { return mxRef; }
+ const VclPtr<vcl::Window>& getRef() const { return mxRef; }
void disposeAndClear()
{
mxRef.disposeAndClear();
diff --git a/vcl/source/app/salvtables.cxx b/vcl/source/app/salvtables.cxx
index a5a8dc8c1592..66b5e3d1bbe2 100644
--- a/vcl/source/app/salvtables.cxx
+++ b/vcl/source/app/salvtables.cxx
@@ -5506,7 +5506,7 @@ public:
return std::make_unique<SalInstanceSizeGroup>();
}
- OString get_current_page_help_id()
+ OString get_current_page_help_id() const
{
TabControl *pCtrl = get_builder().get<TabControl>("tabcontrol");
TabPage* pTabPage = pCtrl ? pCtrl->GetTabPage(pCtrl->GetCurPageId()) : nullptr;
diff --git a/vcl/source/control/roadmap.cxx b/vcl/source/control/roadmap.cxx
index c1a301110fb3..e7f0cfedbeb9 100644
--- a/vcl/source/control/roadmap.cxx
+++ b/vcl/source/control/roadmap.cxx
@@ -301,7 +301,7 @@ void ORoadmap::SetRoadmapInteractive(bool _bInteractive)
}
}
-bool ORoadmap::IsRoadmapInteractive()
+bool ORoadmap::IsRoadmapInteractive() const
{
return m_pImpl->isInteractive();
}
diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx
index 901c9407e36f..d42eaede02d1 100644
--- a/vcl/source/filter/graphicfilter.cxx
+++ b/vcl/source/filter/graphicfilter.cxx
@@ -869,7 +869,7 @@ ErrCode GraphicFilter::ImplSetError( ErrCode nError, const SvStream* pStm )
return nError;
}
-sal_uInt16 GraphicFilter::GetImportFormatCount()
+sal_uInt16 GraphicFilter::GetImportFormatCount() const
{
return pConfig->GetImportFormatCount();
}
@@ -916,7 +916,7 @@ OUString GraphicFilter::GetImportWildcard( sal_uInt16 nFormat, sal_Int32 nEntry
return pConfig->GetImportWildcard( nFormat, nEntry );
}
-sal_uInt16 GraphicFilter::GetExportFormatCount()
+sal_uInt16 GraphicFilter::GetExportFormatCount() const
{
return pConfig->GetExportFormatCount();
}
@@ -1176,7 +1176,7 @@ void GraphicFilter::ImportGraphics(std::vector< std::shared_ptr<Graphic> >& rGra
}
Graphic GraphicFilter::ImportUnloadedGraphic(SvStream& rIStream, sal_uInt64 sizeLimit,
- Size* pSizeHint)
+ const Size* pSizeHint)
{
Graphic aGraphic;
sal_uInt16 nFormat = GRFILTER_FORMAT_DONTKNOW;
diff --git a/vcl/source/filter/ipdf/pdfdocument.cxx b/vcl/source/filter/ipdf/pdfdocument.cxx
index 9aa317715e41..1aec86c9ee2f 100644
--- a/vcl/source/filter/ipdf/pdfdocument.cxx
+++ b/vcl/source/filter/ipdf/pdfdocument.cxx
@@ -1812,7 +1812,10 @@ size_t PDFDocument::GetObjectOffset(size_t nIndex) const
return it->second.GetOffset();
}
-const std::vector<std::unique_ptr<PDFElement>>& PDFDocument::GetElements() { return m_aElements; }
+const std::vector<std::unique_ptr<PDFElement>>& PDFDocument::GetElements() const
+{
+ return m_aElements;
+}
/// Visits the page tree recursively, looking for page objects.
static void visitPages(PDFObjectElement* pPages, std::vector<PDFObjectElement*>& rRet)
@@ -2470,7 +2473,7 @@ sal_uInt64 PDFObjectElement::GetDictionaryOffset()
void PDFObjectElement::SetArrayOffset(sal_uInt64 nArrayOffset) { m_nArrayOffset = nArrayOffset; }
-sal_uInt64 PDFObjectElement::GetArrayOffset() { return m_nArrayOffset; }
+sal_uInt64 PDFObjectElement::GetArrayOffset() const { return m_nArrayOffset; }
void PDFDictionaryElement::SetKeyOffset(const OString& rKey, sal_uInt64 nOffset)
{
@@ -2517,7 +2520,7 @@ sal_uInt64 PDFObjectElement::GetDictionaryLength()
void PDFObjectElement::SetArrayLength(sal_uInt64 nArrayLength) { m_nArrayLength = nArrayLength; }
-sal_uInt64 PDFObjectElement::GetArrayLength() { return m_nArrayLength; }
+sal_uInt64 PDFObjectElement::GetArrayLength() const { return m_nArrayLength; }
PDFDictionaryElement* PDFObjectElement::GetDictionary()
{
@@ -2978,7 +2981,7 @@ void PDFArrayElement::PushBack(PDFElement* pElement)
m_aElements.push_back(pElement);
}
-const std::vector<PDFElement*>& PDFArrayElement::GetElements() { return m_aElements; }
+const std::vector<PDFElement*>& PDFArrayElement::GetElements() const { return m_aElements; }
PDFEndArrayElement::PDFEndArrayElement() = default;
diff --git a/vcl/source/filter/jpeg/Exif.cxx b/vcl/source/filter/jpeg/Exif.cxx
index 4bb43049f76d..6dd3bd1b2baa 100644
--- a/vcl/source/filter/jpeg/Exif.cxx
+++ b/vcl/source/filter/jpeg/Exif.cxx
@@ -50,7 +50,7 @@ Orientation Exif::convertToOrientation(sal_Int32 value)
return TOP_LEFT;
}
-sal_Int32 Exif::getRotation()
+sal_Int32 Exif::getRotation() const
{
switch(maOrientation) {
case TOP_LEFT:
diff --git a/vcl/source/filter/jpeg/Exif.hxx b/vcl/source/filter/jpeg/Exif.hxx
index d6d13c55877a..7eb5a7da0009 100644
--- a/vcl/source/filter/jpeg/Exif.hxx
+++ b/vcl/source/filter/jpeg/Exif.hxx
@@ -66,10 +66,10 @@ public:
Exif();
~Exif();
- bool hasExif() { return mbExifPresent;}
+ bool hasExif() const { return mbExifPresent;}
- Orientation getOrientation() { return maOrientation;}
- sal_Int32 getRotation();
+ Orientation getOrientation() const { return maOrientation;}
+ sal_Int32 getRotation() const;
void setOrientation(Orientation orientation);
diff --git a/vcl/source/gdi/WidgetDefinitionReader.cxx b/vcl/source/gdi/WidgetDefinitionReader.cxx
index dd6bf75abe32..cbfa7c8bfe87 100644
--- a/vcl/source/gdi/WidgetDefinitionReader.cxx
+++ b/vcl/source/gdi/WidgetDefinitionReader.cxx
@@ -184,8 +184,8 @@ WidgetDefinitionReader::WidgetDefinitionReader(OUString const& rDefinitionFile,
{
}
-void WidgetDefinitionReader::readDrawingDefinition(tools::XmlWalker& rWalker,
- std::shared_ptr<WidgetDefinitionState>& rpState)
+void WidgetDefinitionReader::readDrawingDefinition(
+ tools::XmlWalker& rWalker, const std::shared_ptr<WidgetDefinitionState>& rpState)
{
rWalker.children();
while (rWalker.isValid())
diff --git a/vcl/source/gdi/graph.cxx b/vcl/source/gdi/graph.cxx
index 1cdf4e4c8825..89c02b677fd7 100644
--- a/vcl/source/gdi/graph.cxx
+++ b/vcl/source/gdi/graph.cxx
@@ -500,7 +500,7 @@ void Graphic::SetDummyContext( bool value )
mxImpGraphic->ImplSetDummyContext( value );
}
-bool Graphic::IsDummyContext()
+bool Graphic::IsDummyContext() const
{
return mxImpGraphic->ImplIsDummyContext();
}
diff --git a/vcl/source/gdi/impgraph.cxx b/vcl/source/gdi/impgraph.cxx
index c645e9d6cda6..252a4fc9c979 100644
--- a/vcl/source/gdi/impgraph.cxx
+++ b/vcl/source/gdi/impgraph.cxx
@@ -521,7 +521,7 @@ ImpSwapFile::~ImpSwapFile()
}
}
-void ImpGraphic::ImplSetPrepared(bool bAnimated, Size* pSizeHint)
+void ImpGraphic::ImplSetPrepared(bool bAnimated, const Size* pSizeHint)
{
mbPrepared = true;
mbSwapOut = true;
diff --git a/vcl/source/gdi/pdfextoutdevdata.cxx b/vcl/source/gdi/pdfextoutdevdata.cxx
index 2a953b7b9d03..1af5c48938b5 100644
--- a/vcl/source/gdi/pdfextoutdevdata.cxx
+++ b/vcl/source/gdi/pdfextoutdevdata.cxx
@@ -753,7 +753,7 @@ bool PDFExtOutDevData::SetCurrentStructureElement( sal_Int32 nStructId )
}
return bSuccess;
}
-sal_Int32 PDFExtOutDevData::GetCurrentStructureElement()
+sal_Int32 PDFExtOutDevData::GetCurrentStructureElement() const
{
return mpGlobalSyncData->mCurrentStructElement;
}
diff --git a/vcl/source/gdi/pdfwriter.cxx b/vcl/source/gdi/pdfwriter.cxx
index 3a50ad3af042..4e5a3c14e6a8 100644
--- a/vcl/source/gdi/pdfwriter.cxx
+++ b/vcl/source/gdi/pdfwriter.cxx
@@ -445,7 +445,7 @@ void PDFWriter::AddStream( const OUString& rMimeType, PDFOutputStream* pStream )
xImplementation->addStream( rMimeType, pStream );
}
-std::set< PDFWriter::ErrorCode > const & PDFWriter::GetErrors()
+std::set< PDFWriter::ErrorCode > const & PDFWriter::GetErrors() const
{
return xImplementation->getErrors();
}
diff --git a/vcl/source/gdi/print3.cxx b/vcl/source/gdi/print3.cxx
index ec1682f91012..89d0a405d7b8 100644
--- a/vcl/source/gdi/print3.cxx
+++ b/vcl/source/gdi/print3.cxx
@@ -1209,7 +1209,7 @@ PrinterController::PageSize PrinterController::getFilteredPageFile( int i_nFilte
return PrinterController::PageSize( aPaperSize, true );
}
-int PrinterController::getFilteredPageCount()
+int PrinterController::getFilteredPageCount() const
{
int nDiv = mpImplData->maMultiPage.nRows * mpImplData->maMultiPage.nColumns;
if( nDiv < 1 )
diff --git a/vcl/source/gdi/salgdilayout.cxx b/vcl/source/gdi/salgdilayout.cxx
index 192eaf66c373..b949e213adf4 100644
--- a/vcl/source/gdi/salgdilayout.cxx
+++ b/vcl/source/gdi/salgdilayout.cxx
@@ -36,7 +36,7 @@
// The only common SalFrame method
-SalFrameGeometry SalFrame::GetGeometry()
+SalFrameGeometry SalFrame::GetGeometry() const
{
// mirror frame coordinates at parent
SalFrame *pParent = GetParent();
diff --git a/vcl/source/gdi/vectorgraphicdata.cxx b/vcl/source/gdi/vectorgraphicdata.cxx
index 5beef667e367..09e1d45974c5 100644
--- a/vcl/source/gdi/vectorgraphicdata.cxx
+++ b/vcl/source/gdi/vectorgraphicdata.cxx
@@ -208,7 +208,7 @@ void VectorGraphicData::ensureSequenceAndRange()
}
}
-auto VectorGraphicData::getSizeBytes() -> std::pair<State, size_t>
+auto VectorGraphicData::getSizeBytes() const -> std::pair<State, size_t>
{
if (maSequence.empty() && maVectorGraphicDataArray.hasElements())
{
diff --git a/vcl/source/treelist/svlbitm.cxx b/vcl/source/treelist/svlbitm.cxx
index 58433644ee93..e484a04fb568 100644
--- a/vcl/source/treelist/svlbitm.cxx
+++ b/vcl/source/treelist/svlbitm.cxx
@@ -163,7 +163,7 @@ bool SvLBoxButtonData::HasDefaultImages() const
return pImpl->bDefaultImages;
}
-bool SvLBoxButtonData::IsRadio() {
+bool SvLBoxButtonData::IsRadio() const {
return pImpl->bShowRadioButton;
}
diff --git a/vcl/source/window/cursor.cxx b/vcl/source/window/cursor.cxx
index c5c64684f1b9..24d05c8f86f3 100644
--- a/vcl/source/window/cursor.cxx
+++ b/vcl/source/window/cursor.cxx
@@ -126,7 +126,7 @@ static void ImplCursorInvert(vcl::Window* pWindow, ImplCursorData const * pData)
pGuard->SetPaintRect(pRenderContext->PixelToLogic(aPaintRect));
}
-bool vcl::Cursor::ImplPrepForDraw(OutputDevice* pDevice, ImplCursorData& rData)
+bool vcl::Cursor::ImplPrepForDraw(const OutputDevice* pDevice, ImplCursorData& rData)
{
if (pDevice && !rData.mbCurVisible)
{
diff --git a/vcl/source/window/dialog.cxx b/vcl/source/window/dialog.cxx
index a6d542fbcc69..9b5f0babe06a 100644
--- a/vcl/source/window/dialog.cxx
+++ b/vcl/source/window/dialog.cxx
@@ -1487,7 +1487,7 @@ vcl::Window* Dialog::get_widget_for_response(int response)
return nullptr;
}
-int Dialog::get_default_response()
+int Dialog::get_default_response() const
{
//copy explicit responses
std::map<VclPtr<vcl::Window>, short> aResponses(mpDialogImpl->maResponses);
diff --git a/vcl/source/window/menubarwindow.hxx b/vcl/source/window/menubarwindow.hxx
index 86e4eef79cb2..c871455ad25c 100644
--- a/vcl/source/window/menubarwindow.hxx
+++ b/vcl/source/window/menubarwindow.hxx
@@ -47,7 +47,7 @@ public:
void SetImages( long nMaxHeight, bool bForce = false );
void calcMinSize();
- const Size& getMinSize() { return maMinSize;}
+ const Size& getMinSize() const { return maMinSize;}
Image maImage;
};
diff --git a/vcl/source/window/mouse.cxx b/vcl/source/window/mouse.cxx
index 415f6996d7ec..06c8d6949c94 100644
--- a/vcl/source/window/mouse.cxx
+++ b/vcl/source/window/mouse.cxx
@@ -604,7 +604,7 @@ Window::PointerState Window::GetPointerState()
return aState;
}
-bool Window::IsMouseOver()
+bool Window::IsMouseOver() const
{
return ImplGetWinData()->mbMouseOver;
}
diff --git a/vcl/source/window/printdlg.cxx b/vcl/source/window/printdlg.cxx
index fda6c7bbbd2d..f2780f2eda5e 100644
--- a/vcl/source/window/printdlg.cxx
+++ b/vcl/source/window/printdlg.cxx
@@ -1760,17 +1760,17 @@ void PrintDialog::updateWindowFromProperty( const OUString& i_rProperty )
}
}
-bool PrintDialog::isPrintToFile()
+bool PrintDialog::isPrintToFile() const
{
return ( mpPrinters->GetSelectedEntryPos() == 0 );
}
-bool PrintDialog::isCollate()
+bool PrintDialog::isCollate() const
{
return mpCopyCountField->GetValue() > 1 && mpCollateBox->IsChecked();
}
-bool PrintDialog::hasPreview()
+bool PrintDialog::hasPreview() const
{
return mpPreviewBox->IsChecked();
}
diff --git a/vcl/source/window/syschild.cxx b/vcl/source/window/syschild.cxx
index e7beacdf608c..d98eabd3ff93 100644
--- a/vcl/source/window/syschild.cxx
+++ b/vcl/source/window/syschild.cxx
@@ -165,7 +165,7 @@ void SystemChildWindow::SetForwardKey( bool bEnable )
mpWindowImpl->mpSysObj->SetForwardKey( bEnable );
}
-sal_IntPtr SystemChildWindow::GetParentWindowHandle()
+sal_IntPtr SystemChildWindow::GetParentWindowHandle() const
{
sal_IntPtr nRet = 0;
diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx
index 67f3b674d949..d20dccb60481 100644
--- a/vcl/source/window/window.cxx
+++ b/vcl/source/window/window.cxx
@@ -3486,7 +3486,7 @@ void Window::ImplNotifyIconifiedState( bool bIconified )
mpWindowImpl->mpFrameWindow->mpWindowImpl->mpClientWindow->CallEventListeners( bIconified ? VclEventId::WindowMinimize : VclEventId::WindowNormalize );
}
-bool Window::HasActiveChildFrame()
+bool Window::HasActiveChildFrame() const
{
bool bRet = false;
vcl::Window *pFrameWin = ImplGetSVData()->maWinData.mpFirstFrame;
diff --git a/vcl/unx/generic/dtrans/X11_selection.hxx b/vcl/unx/generic/dtrans/X11_selection.hxx
index 130ac6709d29..5bcabe9bdb78 100644
--- a/vcl/unx/generic/dtrans/X11_selection.hxx
+++ b/vcl/unx/generic/dtrans/X11_selection.hxx
@@ -450,7 +450,7 @@ namespace x11 {
void dropComplete( bool success, ::Window aDropXLIB_Window );
// for XDragSourceContext
- sal_Int32 getCurrentCursor() { return m_aCurrentCursor;}
+ sal_Int32 getCurrentCursor() const { return m_aCurrentCursor;}
void setCursor( sal_Int32 cursor, ::Window aDropXLIB_Window );
void transferablesFlavorsChanged();
diff --git a/vcl/unx/generic/print/glyphset.hxx b/vcl/unx/generic/print/glyphset.hxx
index 52f7052bd710..f3599a4e8a89 100644
--- a/vcl/unx/generic/print/glyphset.hxx
+++ b/vcl/unx/generic/print/glyphset.hxx
@@ -65,12 +65,12 @@ public:
GlyphSet (sal_Int32 nFontID, bool bVertical);
~GlyphSet ();
- sal_Int32 GetFontID () { return mnFontID;}
+ sal_Int32 GetFontID () const { return mnFontID;}
static OString
GetReencodedFontName (rtl_TextEncoding nEnc,
const OString &rFontName);
- bool IsVertical () { return mbVertical;}
+ bool IsVertical () const { return mbVertical;}
void DrawGlyph (PrinterGfx& rGfx,
const Point& rPoint,
diff --git a/vcl/unx/generic/print/prtsetup.cxx b/vcl/unx/generic/print/prtsetup.cxx
index d3c565846c17..72d550f11844 100644
--- a/vcl/unx/generic/print/prtsetup.cxx
+++ b/vcl/unx/generic/print/prtsetup.cxx
@@ -378,7 +378,7 @@ RTSDevicePage::~RTSDevicePage()
{
}
-sal_uLong RTSDevicePage::getDepth()
+sal_uLong RTSDevicePage::getDepth() const
{
sal_uInt16 nSelectPos = m_xDepthBox->get_active();
if (nSelectPos == 0)
@@ -387,7 +387,7 @@ sal_uLong RTSDevicePage::getDepth()
return 24;
}
-sal_uLong RTSDevicePage::getColorDevice()
+sal_uLong RTSDevicePage::getColorDevice() const
{
sal_uInt16 nSelectPos = m_xSpaceBox->get_active();
switch (nSelectPos)
@@ -402,7 +402,7 @@ sal_uLong RTSDevicePage::getColorDevice()
return 0;
}
-sal_uLong RTSDevicePage::getLevel()
+sal_uLong RTSDevicePage::getLevel() const
{
auto nLevel = m_xLevelBox->get_active_id().toInt32();
if (nLevel == 0)
@@ -410,7 +410,7 @@ sal_uLong RTSDevicePage::getLevel()
return nLevel < 10 ? nLevel-1 : 0;
}
-sal_uLong RTSDevicePage::getPDFDevice()
+sal_uLong RTSDevicePage::getPDFDevice() const
{
auto nLevel = m_xLevelBox->get_active_id().toInt32();
if (nLevel > 9)
diff --git a/vcl/unx/generic/print/prtsetup.hxx b/vcl/unx/generic/print/prtsetup.hxx
index 67eabe92a6a6..a2282e2980b1 100644
--- a/vcl/unx/generic/print/prtsetup.hxx
+++ b/vcl/unx/generic/print/prtsetup.hxx
@@ -126,10 +126,10 @@ public:
RTSDevicePage(weld::Widget* pPage, RTSDialog* pDialog);
~RTSDevicePage();
- sal_uLong getLevel();
- sal_uLong getPDFDevice();
- sal_uLong getDepth();
- sal_uLong getColorDevice();
+ sal_uLong getLevel() const;
+ sal_uLong getPDFDevice() const;
+ sal_uLong getDepth() const;
+ sal_uLong getColorDevice() const;
};
int SetupPrinterDriver(weld::Window* pParent, ::psp::PrinterInfo& rJobData);
diff --git a/vcl/unx/generic/printer/cpdmgr.cxx b/vcl/unx/generic/printer/cpdmgr.cxx
index 4861daac500b..26e2eacd67fe 100644
--- a/vcl/unx/generic/printer/cpdmgr.cxx
+++ b/vcl/unx/generic/printer/cpdmgr.cxx
@@ -189,7 +189,7 @@ void CPDManager::addTempBackend(const std::pair<std::string, gchar*>& pair)
m_tBackends.push_back(pair);
}
-std::vector<std::pair<std::string, gchar*>> const & CPDManager::getTempBackends() {
+std::vector<std::pair<std::string, gchar*>> const & CPDManager::getTempBackends() const {
return m_tBackends;
}
diff --git a/vcl/unx/gtk/gtkinst.cxx b/vcl/unx/gtk/gtkinst.cxx
index f18dc9457fd5..97192654c201 100644
--- a/vcl/unx/gtk/gtkinst.cxx
+++ b/vcl/unx/gtk/gtkinst.cxx
@@ -471,7 +471,7 @@ const cairo_font_options_t* GtkInstance::GetCairoFontOptions()
return pCairoFontOptions;
}
-const cairo_font_options_t* GtkInstance::GetLastSeenCairoFontOptions()
+const cairo_font_options_t* GtkInstance::GetLastSeenCairoFontOptions() const
{
return m_pLastCairoFontOptions;
}
diff --git a/vcl/workben/vcldemo.cxx b/vcl/workben/vcldemo.cxx
index 78381da7c155..20e30811f9e2 100644
--- a/vcl/workben/vcldemo.cxx
+++ b/vcl/workben/vcldemo.cxx
@@ -164,7 +164,7 @@ public:
void selectRenderer(const OUString &rName);
int selectNextRenderer();
void setIterCount(sal_Int32 iterCount);
- sal_Int32 getIterCount();
+ sal_Int32 getIterCount() const;
void addTime(int i, double t);
Size maSize;
@@ -1674,7 +1674,7 @@ void DemoRenderer::setIterCount(sal_Int32 i)
iterCount = i;
}
-sal_Int32 DemoRenderer::getIterCount()
+sal_Int32 DemoRenderer::getIterCount() const
{
return iterCount;
}