summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@collabora.com>2022-04-27 14:43:45 +0200
committerLuboš Luňák <l.lunak@collabora.com>2022-04-28 05:52:19 +0200
commitc8a7a6d600c2fb0ebe84c97553b2754936122023 (patch)
treeaeb799784af932db2d3550adc167387de6a2fbed
parent9e2d48b9e04f7ea895fb095699c32ed8a44eb129 (diff)
better debug font compare in SalLayoutGlyphsImpl
The pointer comparison can be false even though the contents match. Change-Id: I584d30fdc7f311fd1a6058ae3cef98ce8b243f86 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133529 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
-rw-r--r--vcl/source/gdi/impglyphitem.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/vcl/source/gdi/impglyphitem.cxx b/vcl/source/gdi/impglyphitem.cxx
index 92703432d8bb..5896d5bfeb7c 100644
--- a/vcl/source/gdi/impglyphitem.cxx
+++ b/vcl/source/gdi/impglyphitem.cxx
@@ -134,7 +134,8 @@ SalLayoutGlyphsImpl* SalLayoutGlyphsImpl::cloneCharRange(sal_Int32 index, sal_In
#ifdef DBG_UTIL
bool SalLayoutGlyphsImpl::isEqual(const SalLayoutGlyphsImpl* other) const
{
- if (GetFont()->mxFontMetric != other->GetFont()->mxFontMetric)
+ if (!GetFont()->mxFontMetric->CompareDeviceIndependentFontAttributes(
+ *other->GetFont()->mxFontMetric))
return false;
if (GetFlags() != other->GetFlags())
return false;