oox/source/ppt/EmbeddedFontListContext.cxx | 1 + sd/qa/unit/FontEmbeddingTest.cxx | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-)
New commits: commit 3fb2c50e6639e1c6af2fac2b1ae3901c55885d80 Author: Tomaž Vajngerl <tomaz.vajng...@collabora.co.uk> AuthorDate: Mon May 26 14:22:54 2025 +0900 Commit: Miklos Vajna <vmik...@collabora.com> CommitDate: Wed May 28 08:38:18 2025 +0200 sd: enable "EmbedOnlyUsedFonts" at PPTX import If fonts are embedded in the imported PPTX document, also enable "EmbedOnlyUsedFonts" as MSO usually only embeds the fonts that are used. Change-Id: I6edc47ef793675017e8b127340535fd3d641fa55 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/185762 Reviewed-by: Miklos Vajna <vmik...@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com> diff --git a/oox/source/ppt/EmbeddedFontListContext.cxx b/oox/source/ppt/EmbeddedFontListContext.cxx index 792387e34556..de480363a3e3 100644 --- a/oox/source/ppt/EmbeddedFontListContext.cxx +++ b/oox/source/ppt/EmbeddedFontListContext.cxx @@ -87,6 +87,7 @@ void EmbeddedFontListContext::onEndElement() if (mxDocSettings.is()) { mxDocSettings->setPropertyValue(u"EmbedFonts"_ustr, uno::Any(true)); + mxDocSettings->setPropertyValue(u"EmbedOnlyUsedFonts"_ustr, uno::Any(true)); } if (!moCurrentFont->aRegularID.isEmpty()) diff --git a/sd/qa/unit/FontEmbeddingTest.cxx b/sd/qa/unit/FontEmbeddingTest.cxx index bcbfc81345c9..22ec352ceaf6 100644 --- a/sd/qa/unit/FontEmbeddingTest.cxx +++ b/sd/qa/unit/FontEmbeddingTest.cxx @@ -81,7 +81,7 @@ CPPUNIT_TEST_FIXTURE(FontEmbeddingTest, testRoundtripEmbeddedFontsPPTX) xSettings->getPropertyValue(u"EmbedComplexScriptFonts"_ustr) >>= bEmbedComplexScript; CPPUNIT_ASSERT_EQUAL(true, bEmbedFonts); - CPPUNIT_ASSERT_EQUAL(false, bEmbedUsedOnly); + CPPUNIT_ASSERT_EQUAL(true, bEmbedUsedOnly); CPPUNIT_ASSERT_EQUAL(true, bEmbedLatinScript); CPPUNIT_ASSERT_EQUAL(true, bEmbedAsianScript); CPPUNIT_ASSERT_EQUAL(true, bEmbedComplexScript);