From 53e3d79c6327fc85528c5564f2fde0e64f2cacbd Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Thu, 13 Feb 2014 22:49:03 +0100 Subject: [PATCH] writerfilter: NS_sprm::LN_PDx/yaFromText -> NS_ooxml::LN_CT_FramePr_h/vSpace Change-Id: I651a1fd5279afa07929e6cfae4440f5b008d6215 --- writerfilter/source/dmapper/DomainMapper.cxx | 12 ++-- writerfilter/source/doctok/resources.xmi | 62 ------------------- writerfilter/source/ooxml/model.xml | 4 +- .../source/rtftok/rtfdocumentimpl.cxx | 20 +++--- 4 files changed, 18 insertions(+), 80 deletions(-) diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx index 900b95fb109a..0d30a7993559 100644 --- a/writerfilter/source/dmapper/DomainMapper.cxx +++ b/writerfilter/source/dmapper/DomainMapper.cxx @@ -618,8 +618,8 @@ void DomainMapper::lcl_attribute(Id nName, Value & val) case NS_ooxml::LN_CT_FramePr_w: case NS_ooxml::LN_CT_FramePr_h: case NS_sprm::LN_PWr: - case NS_sprm::LN_PDxaFromText: - case NS_sprm::LN_PDyaFromText: + case NS_ooxml::LN_CT_FramePr_hSpace: + case NS_ooxml::LN_CT_FramePr_vSpace: { ParagraphProperties* pParaProperties = dynamic_cast< ParagraphProperties*>( m_pImpl->GetTopContextOfType( CONTEXT_PARAGRAPH ).get() ); @@ -736,10 +736,10 @@ void DomainMapper::lcl_attribute(Id nName, Value & val) case NS_ooxml::LN_CT_FramePr_h: pParaProperties->Seth(ConversionHelper::convertTwipToMM100(nIntValue)); break; - case NS_sprm::LN_PDxaFromText: + case NS_ooxml::LN_CT_FramePr_hSpace: pParaProperties->SethSpace( ConversionHelper::convertTwipToMM100(nIntValue )); break; - case NS_sprm::LN_PDyaFromText: + case NS_ooxml::LN_CT_FramePr_vSpace: pParaProperties->SetvSpace( ConversionHelper::convertTwipToMM100(nIntValue )); break; default:; @@ -1202,9 +1202,9 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext, SprmType } } break; - case NS_sprm::LN_PDyaFromText: + case NS_ooxml::LN_CT_FramePr_vSpace: break; // sprmPDyaFromText - case NS_sprm::LN_PDxaFromText: + case NS_ooxml::LN_CT_FramePr_hSpace: break; // sprmPDxaFromText case NS_sprm::LN_PFLocked: break; // sprmPFLocked diff --git a/writerfilter/source/doctok/resources.xmi b/writerfilter/source/doctok/resources.xmi index 33d5b1f08442..d9dc166dac63 100644 --- a/writerfilter/source/doctok/resources.xmi +++ b/writerfilter/source/doctok/resources.xmi @@ -573,68 +573,6 @@ - - - - - - - - 0x842E - - - - - - - - rtf:sprmPDyaFromText - - - - - - - - paragraph - - - - - - - - - - - - - - - 0x842F - - - - - - - - rtf:sprmPDxaFromText - - - - - - - - paragraph - - - - - - - diff --git a/writerfilter/source/ooxml/model.xml b/writerfilter/source/ooxml/model.xml index f7f8771f127a..31b97e2d82a2 100644 --- a/writerfilter/source/ooxml/model.xml +++ b/writerfilter/source/ooxml/model.xml @@ -21956,8 +21956,8 @@ - - + + diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx index 2533eaaa98cd..9eea3d42e3ce 100644 --- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx +++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx @@ -3555,15 +3555,15 @@ int RTFDocumentImpl::dispatchValue(RTFKeyword nKeyword, int nParam) NS_ooxml::LN_EG_SectPrContents_endnotePr, NS_ooxml::LN_EG_FtnEdnNumProps_numStart, pIntValue); break; case RTF_DFRMTXTX: - m_aStates.top().aFrame.setSprm(NS_sprm::LN_PDxaFromText, nParam); + m_aStates.top().aFrame.setSprm(NS_ooxml::LN_CT_FramePr_hSpace, nParam); break; case RTF_DFRMTXTY: - m_aStates.top().aFrame.setSprm(NS_sprm::LN_PDyaFromText, nParam); + m_aStates.top().aFrame.setSprm(NS_ooxml::LN_CT_FramePr_vSpace, nParam); break; case RTF_DXFRTEXT: { - m_aStates.top().aFrame.setSprm(NS_sprm::LN_PDxaFromText, nParam); - m_aStates.top().aFrame.setSprm(NS_sprm::LN_PDyaFromText, nParam); + m_aStates.top().aFrame.setSprm(NS_ooxml::LN_CT_FramePr_hSpace, nParam); + m_aStates.top().aFrame.setSprm(NS_ooxml::LN_CT_FramePr_vSpace, nParam); } break; case RTF_FLYVERT: @@ -5105,10 +5105,10 @@ void RTFFrame::setSprm(Id nId, Id nValue) case NS_ooxml::LN_CT_FramePr_y: nY = nValue; break; - case NS_sprm::LN_PDxaFromText: + case NS_ooxml::LN_CT_FramePr_hSpace: nHoriPadding = nValue; break; - case NS_sprm::LN_PDyaFromText: + case NS_ooxml::LN_CT_FramePr_vSpace: nVertPadding = nValue; break; case NS_ooxml::LN_CT_FramePr_xAlign: @@ -5142,8 +5142,8 @@ RTFSprms RTFFrame::getSprms() NS_ooxml::LN_CT_FramePr_hRule, // Make sure nHRule is processed before nH NS_ooxml::LN_CT_FramePr_h, NS_ooxml::LN_CT_FramePr_w, - NS_sprm::LN_PDxaFromText, - NS_sprm::LN_PDyaFromText, + NS_ooxml::LN_CT_FramePr_hSpace, + NS_ooxml::LN_CT_FramePr_vSpace, NS_ooxml::LN_CT_FramePr_hAnchor, NS_ooxml::LN_CT_FramePr_vAnchor, NS_ooxml::LN_CT_FramePr_xAlign, @@ -5181,11 +5181,11 @@ RTFSprms RTFFrame::getSprms() if ( nW != 0 ) pValue.reset(new RTFValue(nW)); break; - case NS_sprm::LN_PDxaFromText: + case NS_ooxml::LN_CT_FramePr_hSpace: if ( nHoriPadding != 0 ) pValue.reset(new RTFValue(nHoriPadding)); break; - case NS_sprm::LN_PDyaFromText: + case NS_ooxml::LN_CT_FramePr_vSpace: if ( nVertPadding != 0 ) pValue.reset(new RTFValue(nVertPadding)); break;