diff --git a/sc/inc/stylehelper.hxx b/sc/inc/stylehelper.hxx index 63189ccd6c77..e11fcef97c8e 100644 --- a/sc/inc/stylehelper.hxx +++ b/sc/inc/stylehelper.hxx @@ -20,6 +20,7 @@ #pragma once #include +#include "scdllapi.h" // conversion programmatic <-> display (visible) name // currently, the core always has the visible names @@ -46,7 +47,8 @@ class ScStyleNameConversion { public: static OUString DisplayToProgrammaticName(const OUString& rDispName, SfxStyleFamily nType); - static OUString ProgrammaticToDisplayName(const OUString& rProgName, SfxStyleFamily nType); + static SC_DLLPUBLIC OUString ProgrammaticToDisplayName(const OUString& rProgName, + SfxStyleFamily nType); }; /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sc/source/filter/orcus/interface.cxx b/sc/source/filter/orcus/interface.cxx index 63926a72fc59..1bcc914a0ada 100644 --- a/sc/source/filter/orcus/interface.cxx +++ b/sc/source/filter/orcus/interface.cxx @@ -49,6 +49,7 @@ #include #include +#include using namespace com::sun::star; @@ -2176,7 +2177,9 @@ size_t ScOrcusStyles::commit_cell_style() ScStyleSheetPool* pPool = mrFactory.getDoc().getDoc().GetStyleSheetPool(); SfxStyleSheetBase& rBase = pPool->Make(maCurrentCellStyle.maName, SfxStyleFamily::Para); - rBase.SetParent(maCurrentCellStyle.maParentName); + // Need to convert the parent name to localized UI name, see tdf#139205. + rBase.SetParent(ScStyleNameConversion::ProgrammaticToDisplayName(maCurrentCellStyle.maParentName, + SfxStyleFamily::Para)); SfxItemSet& rSet = rBase.GetItemSet(); xf& rXf = maCellStyleXfs[maCurrentCellStyle.mnXFId];