summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sw/qa/core/exportdata/ooxml/fail/.gitignore0
-rw-r--r--sw/qa/core/exportdata/ooxml/indeterminate/.gitignore0
-rw-r--r--sw/qa/core/exportdata/ooxml/pass/sdt-in-shape-with-textbox.docxbin0 -> 17960 bytes
-rw-r--r--sw/qa/core/filters-test.cxx9
-rw-r--r--sw/source/filter/ww8/docxsdrexport.cxx9
5 files changed, 18 insertions, 0 deletions
diff --git a/sw/qa/core/exportdata/ooxml/fail/.gitignore b/sw/qa/core/exportdata/ooxml/fail/.gitignore
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/sw/qa/core/exportdata/ooxml/fail/.gitignore
diff --git a/sw/qa/core/exportdata/ooxml/indeterminate/.gitignore b/sw/qa/core/exportdata/ooxml/indeterminate/.gitignore
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/sw/qa/core/exportdata/ooxml/indeterminate/.gitignore
diff --git a/sw/qa/core/exportdata/ooxml/pass/sdt-in-shape-with-textbox.docx b/sw/qa/core/exportdata/ooxml/pass/sdt-in-shape-with-textbox.docx
new file mode 100644
index 000000000000..be033f156643
--- /dev/null
+++ b/sw/qa/core/exportdata/ooxml/pass/sdt-in-shape-with-textbox.docx
Binary files differ
diff --git a/sw/qa/core/filters-test.cxx b/sw/qa/core/filters-test.cxx
index 2a80f3efb242..8c128c35a84f 100644
--- a/sw/qa/core/filters-test.cxx
+++ b/sw/qa/core/filters-test.cxx
@@ -188,6 +188,15 @@ void SwFiltersTest::testCVEs()
0,
0,
/*bExport=*/true);
+
+ testDir("MS Word 2007 XML",
+ getURLFromSrc("/sw/qa/core/exportdata/ooxml/"),
+ OUString(),
+ SFX_FILTER_STARONEFILTER,
+ 0,
+ 0,
+ /*bExport=*/true);
+
}
void SwFiltersTest::setUp()
diff --git a/sw/source/filter/ww8/docxsdrexport.cxx b/sw/source/filter/ww8/docxsdrexport.cxx
index bd34f04596b7..b1aa91070b7a 100644
--- a/sw/source/filter/ww8/docxsdrexport.cxx
+++ b/sw/source/filter/ww8/docxsdrexport.cxx
@@ -1314,6 +1314,9 @@ void DocxSdrExport::writeOnlyTextOfFrame(sw::Frame* pParentFrame)
void DocxSdrExport::writeDMLTextFrame(sw::Frame* pParentFrame, int nAnchorId, bool bTextBoxOnly)
{
+ bool bDMLAndVMLDrawingOpen = m_pImpl->m_bDMLAndVMLDrawingOpen;
+ m_pImpl->m_bDMLAndVMLDrawingOpen = true;
+
sax_fastparser::FSHelperPtr pFS = m_pImpl->m_pSerializer;
const SwFrmFmt& rFrmFmt = pParentFrame->GetFrmFmt();
const SwNodeIndex* pNodeIndex = rFrmFmt.GetCntnt().GetCntntIdx();
@@ -1542,10 +1545,14 @@ void DocxSdrExport::writeDMLTextFrame(sw::Frame* pParentFrame, int nAnchorId, bo
endDMLAnchorInline(&rFrmFmt);
}
+ m_pImpl->m_bDMLAndVMLDrawingOpen = bDMLAndVMLDrawingOpen;
}
void DocxSdrExport::writeVMLTextFrame(sw::Frame* pParentFrame, bool bTextBoxOnly)
{
+ bool bDMLAndVMLDrawingOpen = m_pImpl->m_bDMLAndVMLDrawingOpen;
+ m_pImpl->m_bDMLAndVMLDrawingOpen = true;
+
sax_fastparser::FSHelperPtr pFS = m_pImpl->m_pSerializer;
const SwFrmFmt& rFrmFmt = pParentFrame->GetFrmFmt();
const SwNodeIndex* pNodeIndex = rFrmFmt.GetCntnt().GetCntntIdx();
@@ -1633,6 +1640,8 @@ void DocxSdrExport::writeVMLTextFrame(sw::Frame* pParentFrame, bool bTextBoxOnly
pFS->endElementNS(XML_w, XML_pict);
}
m_pImpl->m_bFrameBtLr = false;
+
+ m_pImpl->m_bDMLAndVMLDrawingOpen = bDMLAndVMLDrawingOpen;
}
bool DocxSdrExport::checkFrameBtlr(SwNode* pStartNode, sax_fastparser::FastAttributeList* pTextboxAttrList)