From 6820dec8903b182260340c638c35b5a5ca207a85 Mon Sep 17 00:00:00 2001 From: Jacobo Aragunde PĂ©rez Date: Mon, 17 Mar 2014 20:53:35 +0100 Subject: ooxml: preserve several simple types of sdt This patch is to preserve the sdt blocks for several simple sdt types: equation, picture, citation and group. This patch reuses the infrastructure created at commit 55211e612d2cbed03dd81c039d07ea4e936c2804 to grab-bag the properties of the sdt block and write them back on export, with small modifications in particular related with the fact that these tags don't have children. The type of the property tags equation, picture, citation and group was modified in the ooxml model file to be able to process them. They were previously empty. A unit test was added to check the preservation of these fields. Another had to be modified. Change-Id: Ica1a340f589f5d6c85c1a35d2a3a4bf930eb2d8a --- writerfilter/source/dmapper/DomainMapper.cxx | 4 ++++ writerfilter/source/ooxml/model.xml | 8 ++++---- 2 files changed, 8 insertions(+), 4 deletions(-) (limited to 'writerfilter') diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx index 7c259917dc8a..435919ec3a62 100644 --- a/writerfilter/source/dmapper/DomainMapper.cxx +++ b/writerfilter/source/dmapper/DomainMapper.cxx @@ -2229,7 +2229,11 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext ) m_pImpl->m_pSdtHelper->getLocale().append(sStringValue); } break; + case NS_ooxml::LN_CT_SdtPr_equation: case NS_ooxml::LN_CT_SdtPr_docPartObj: + case NS_ooxml::LN_CT_SdtPr_picture: + case NS_ooxml::LN_CT_SdtPr_citation: + case NS_ooxml::LN_CT_SdtPr_group: { // this is an unsupported SDT property, create a grab bag for it OUString sName = OUString::createFromAscii((*QNameToString::Instance())(nSprmId).c_str()); diff --git a/writerfilter/source/ooxml/model.xml b/writerfilter/source/ooxml/model.xml index 417a0de7e42c..d80f2e2d1a3e 100644 --- a/writerfilter/source/ooxml/model.xml +++ b/writerfilter/source/ooxml/model.xml @@ -18855,7 +18855,7 @@ - + @@ -18873,7 +18873,7 @@ - + @@ -18882,10 +18882,10 @@ - + - + -- cgit