Kaydet (Commit) c30fb7d7 authored tarafından Oliver-Rainer Wittmann's avatar Oliver-Rainer Wittmann Kaydeden (comit) Caolán McNamara

Related: #i124106# correct handling of page break attributes

i.e. those which are providing the default value explicitly

(cherry picked from commit 5a15ef3d)

Conflicts:
	writerfilter/source/dmapper/DomainMapper.cxx
	writerfilter/source/dmapper/PropertyMap.cxx

Change-Id: Ib8721f2fce060d26ee75b0515b3bf62a603fd40c
üst 011df3ee
...@@ -984,7 +984,7 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext, SprmType ...@@ -984,7 +984,7 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext, SprmType
SectionPropertyMap * pSectionContext = m_pImpl->GetSectionContext(); SectionPropertyMap * pSectionContext = m_pImpl->GetSectionContext();
Value::Pointer_t pValue = rSprm.getValue(); Value::Pointer_t pValue = rSprm.getValue();
sal_Int32 nIntValue = pValue->getInt(); sal_Int32 nIntValue = pValue->getInt();
OUString sStringValue = pValue->getString(); const OUString sStringValue = pValue->getString();
PropertyNameSupplier& rPropNameSupplier = PropertyNameSupplier::GetPropertyNameSupplier(); PropertyNameSupplier& rPropNameSupplier = PropertyNameSupplier::GetPropertyNameSupplier();
switch(nSprmId) switch(nSprmId)
...@@ -1002,7 +1002,10 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext, SprmType ...@@ -1002,7 +1002,10 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext, SprmType
rContext->Insert(PROP_PARA_KEEP_TOGETHER, uno::makeAny( nIntValue ? true : false) ); rContext->Insert(PROP_PARA_KEEP_TOGETHER, uno::makeAny( nIntValue ? true : false) );
break; break;
case NS_ooxml::LN_CT_PPrBase_pageBreakBefore: case NS_ooxml::LN_CT_PPrBase_pageBreakBefore:
rContext->Insert(PROP_BREAK_TYPE, uno::makeAny( com::sun::star::style::BreakType_PAGE_BEFORE ) ); if ( nIntValue == 1 )
{
rContext->Insert(PROP_BREAK_TYPE, uno::makeAny( com::sun::star::style::BreakType_PAGE_BEFORE ) );
}
break; break;
case NS_ooxml::LN_CT_NumPr_ilvl: case NS_ooxml::LN_CT_NumPr_ilvl:
if (nIntValue < 0 || 10 <= nIntValue) // Writer can't do everything if (nIntValue < 0 || 10 <= nIntValue) // Writer can't do everything
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment