oox/source/ppt/pptshape.cxx         |   10 +++++++---
 sd/qa/unit/data/pptx/tdf169524.pptx |binary
 sd/qa/unit/export-tests-ooxml4.cxx  |   12 ++++++++++++
 3 files changed, 19 insertions(+), 3 deletions(-)

New commits:
commit 6897edfc215babab8c39ec29df364debfd93c131
Author:     Karthik Godha <[email protected]>
AuthorDate: Mon Dec 8 18:54:06 2025 +0530
Commit:     Michael Stahl <[email protected]>
CommitDate: Tue Feb 10 13:56:04 2026 +0100

    tdf#169559: PPTX import master placeholder styles
    
    Master Slide placeholder styles are skipped during import of PPTX
    
    Change-Id: I33fdf4e66cd5c2ab461e125c302bcbd2ca2cf14b
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/195229
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Reviewed-by: Michael Stahl <[email protected]>
    (cherry picked from commit 2201c215642fc93b4c78a7e98c11272938880a05)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/199040
    Tested-by: Jenkins

diff --git a/oox/source/ppt/pptshape.cxx b/oox/source/ppt/pptshape.cxx
index c71bdf7a3714..1b763a83c144 100644
--- a/oox/source/ppt/pptshape.cxx
+++ b/oox/source/ppt/pptshape.cxx
@@ -238,9 +238,6 @@ void PPTShape::addShape(
         ::oox::drawingml::ShapeIdMap* pShapeMap )
 {
     SAL_INFO("oox.ppt","add shape id: " << msId << " location: " << 
((meShapeLocation == Master) ? "master" : ((meShapeLocation == Slide) ? "slide" 
: ((meShapeLocation == Layout) ? "layout" : "other"))) << " subtype: " << 
mnSubType << " service: " << msServiceName);
-    // only placeholder from layout are being inserted
-    if ( mnSubType && ( meShapeLocation == Master ) )
-        return;
 
     OUString sServiceName( msServiceName );
     if (sServiceName.isEmpty())
@@ -522,6 +519,13 @@ void PPTShape::addShape(
             } else
                 setMasterTextListStyle( aMasterTextListStyle );
 
+            if (mnSubType && meShapeLocation == Master)
+            {
+                if (getTextBody() && !getTextBody()->isEmpty())
+                    setTextMasterStyles(rSlidePersist, rFilterBase, 
sServiceName);
+                return;
+            }
+
             Reference< XShape > xShape( createAndInsert( rFilterBase, 
sServiceName, pTheme, rxShapes, bClearText, mpPlaceholder, aTransformation, 
getFillProperties() ) );
 
             // Apply text properties on placeholder text inside this 
placeholder shape
diff --git a/sd/qa/unit/data/pptx/tdf169524.pptx 
b/sd/qa/unit/data/pptx/tdf169524.pptx
index f1e93c55ca3a..96361fffbef8 100644
Binary files a/sd/qa/unit/data/pptx/tdf169524.pptx and 
b/sd/qa/unit/data/pptx/tdf169524.pptx differ
diff --git a/sd/qa/unit/export-tests-ooxml4.cxx 
b/sd/qa/unit/export-tests-ooxml4.cxx
index 8f734e8db8c6..bb4ff075e941 100644
--- a/sd/qa/unit/export-tests-ooxml4.cxx
+++ b/sd/qa/unit/export-tests-ooxml4.cxx
@@ -2011,6 +2011,18 @@ CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, 
testParaAlignStartEnd)
     assertXPath(pDoc, 
"/p:sld/p:cSld/p:spTree/p:sp[2]/p:txBody/a:p[4]/a:pPr[@algn='l']", 1);
 }
 
+CPPUNIT_TEST_FIXTURE(SdOOXMLExportTest4, testTdf169559)
+{
+    createSdImpressDoc("pptx/tdf169524.pptx");
+    save(TestFilter::PPTX);
+
+    xmlDocUniquePtr pXmlDoc = 
parseExport(u"ppt/slideMasters/slideMaster1.xml"_ustr);
+    assertXPath(
+        pXmlDoc,
+        
"/p:sldMaster/p:cSld/p:spTree/p:sp[2]/p:txBody/a:lstStyle/a:lvl1pPr/a:spcAft/a:spcPts",
+        "val", u"1701");
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Reply via email to