diff --git a/include/wx/itemattr.h b/include/wx/itemattr.h index 3a77cdaded..596cb2bab8 100644 --- a/include/wx/itemattr.h +++ b/include/wx/itemattr.h @@ -28,6 +28,17 @@ public: // default copy ctor, assignment operator and dtor are ok + bool operator==(const wxItemAttr& other) const + { + return m_colText == other.m_colText && + m_colBack == other.m_colBack && + m_font == other.m_font; + } + + bool operator!=(const wxItemAttr& other) const + { + return !(*this == other); + } // setters void SetTextColour(const wxColour& colText) { m_colText = colText; } diff --git a/interface/wx/itemattr.h b/interface/wx/itemattr.h index 518e0426ed..041bb2c37e 100644 --- a/interface/wx/itemattr.h +++ b/interface/wx/itemattr.h @@ -35,6 +35,16 @@ public: const wxColour& colBack, const wxFont& font); + /** + Compare two item attributes for equality. + */ + bool operator==(const wxItemAttr& other) const; + + /** + Compare two item attributes for inequality. + */ + bool operator!=(const wxItemAttr& other) const; + /** Returns the currently set background colour. */