summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2021-07-03 21:20:18 +0100
committerCaolán McNamara <caolanm@redhat.com>2021-07-04 17:46:14 +0200
commitc551e34018d7392f44ff8d7216dda4a480c6eea7 (patch)
treec94720e3f70f11d129cf3de6ca6f08925b3cf5a1
parentf244961d1ff2df1e50980e116f95c312089bc8ce (diff)
ofz#33258 don't set a replacement font if the current one is the same
5.602s->4.022s Change-Id: I5983d4f51bda7249f7b37d642dd970f01b70d3aa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118365 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--sw/source/filter/html/htmlcss1.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/sw/source/filter/html/htmlcss1.cxx b/sw/source/filter/html/htmlcss1.cxx
index f241b396dfce..267996f4ea01 100644
--- a/sw/source/filter/html/htmlcss1.cxx
+++ b/sw/source/filter/html/htmlcss1.cxx
@@ -2286,6 +2286,8 @@ static void lcl_swcss1_setEncoding( SwFormat& rFormat, rtl_TextEncoding eEnc )
const SvxFontItem& rFont = *static_cast<const SvxFontItem*>(pItem);
if (RTL_TEXTENCODING_SYMBOL == rFont.GetCharSet())
continue;
+ if (eEnc == rFont.GetCharSet())
+ continue;
SvxFontItem aFont(rFont.GetFamily(), rFont.GetFamilyName(),
rFont.GetStyleName(), rFont.GetPitch(),
eEnc, i);