summaryrefslogtreecommitdiff
path: root/include/editeng/borderline.hxx
diff options
context:
space:
mode:
authorOliver Specht <oliver.specht@cib.de>2024-05-22 12:26:46 +0200
committerThorsten Behrens <thorsten.behrens@allotropia.de>2024-06-18 01:07:42 +0200
commitc39e4f6b8a942680bc7250177c34fd034a0605e0 (patch)
treee7fb5be56a6f3a391ab420bede1d2ea714901777 /include/editeng/borderline.hxx
parent8ef9573f087b86f93860c8d07d04b60a40512836 (diff)
Add SfxItemType to SfxPoolItem
The SfxPoolItem has a new member SfxItemType m_eItemType to compare types based on enums instead of typeinfo() which consumes a lot of time e.g. while AutoFormat is running Change-Id: I033ce67bc9a28ee4790f162380314de85fb4154e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166452 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de> Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Diffstat (limited to 'include/editeng/borderline.hxx')
-rw-r--r--include/editeng/borderline.hxx16
1 files changed, 16 insertions, 0 deletions
diff --git a/include/editeng/borderline.hxx b/include/editeng/borderline.hxx
index 851c16156dee..86c6be8161be 100644
--- a/include/editeng/borderline.hxx
+++ b/include/editeng/borderline.hxx
@@ -28,6 +28,7 @@
#include <editeng/editengdllapi.h>
#include <svtools/borderline.hxx>
#include <docmodel/color/ComplexColor.hxx>
+#include <o3tl/hash_combine.hxx>
class IntlWrapper;
@@ -253,6 +254,21 @@ public:
static Color threeDDarkColor( Color aMain );
static BorderWidthImpl getWidthImpl( SvxBorderLineStyle nStyle );
+
+ std::size_t getHash() const
+ {
+ std::size_t seed = 0;
+ o3tl::hash_combine(seed, m_nWidth);
+ o3tl::hash_combine(seed, m_nMult);
+ o3tl::hash_combine(seed, m_nDiv);
+ o3tl::hash_combine(seed, m_aWidthImpl.getHash());
+ o3tl::hash_combine(seed, m_aColor.operator::sal_uInt32());
+ o3tl::hash_combine(seed, m_aComplexColor.getHash());
+ o3tl::hash_combine(seed, m_nStyle);
+ o3tl::hash_combine(seed, m_bMirrorWidths);
+ o3tl::hash_combine(seed, m_bUseLeftTop);
+ return seed;
+ }
};
EDITENG_DLLPUBLIC bool operator!=( const SvxBorderLine& rLeft, const SvxBorderLine& rRight );