fix readability-make-member-function-const

This commit is contained in:
wmayer
2023-11-15 12:04:18 +01:00
parent a602003747
commit a6ea6ff155
5 changed files with 6 additions and 6 deletions

View File

@@ -208,7 +208,7 @@ public:
{
spaces -= 2;
}
int count()
int count() const
{
return spaces;
}

View File

@@ -571,7 +571,7 @@ public:
/**
* Returns whether a LogStyle category is active or not
*/
bool isActive(Base::LogStyle category)
bool isActive(Base::LogStyle category) const
{
if (category == Base::LogStyle::Log) {
return bLog;

View File

@@ -112,7 +112,7 @@ public:
inline BoundBox2d(BoundBox2d&&) = default;
inline BoundBox2d(double fX1, double fY1, double fX2, double fY2);
~BoundBox2d() = default;
inline bool IsValid();
inline bool IsValid() const;
inline bool IsEqual(const BoundBox2d& bbox, double tolerance) const;
// operators
@@ -466,7 +466,7 @@ inline BoundBox2d::BoundBox2d(double fX1, double fY1, double fX2, double fY2)
, MaxY(std::max<double>(fY1, fY2))
{}
inline bool BoundBox2d::IsValid()
inline bool BoundBox2d::IsValid() const
{
return (MaxX >= MinX) && (MaxY >= MinY);
}

View File

@@ -172,7 +172,7 @@ void Writer::setForceXML(bool on)
forceXML = on;
}
bool Writer::isForceXML()
bool Writer::isForceXML() const
{
return forceXML;
}

View File

@@ -64,7 +64,7 @@ public:
/// switch the writer in XML only mode (no files allowed)
void setForceXML(bool on);
/// check on state
bool isForceXML();
bool isForceXML() const;
void setFileVersion(int);
int getFileVersion() const;