summaryrefslogtreecommitdiff
path: root/writerfilter
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@suse.cz>2012-06-27 16:59:24 +0200
committerMiklos Vajna <vmiklos@suse.cz>2012-06-27 17:42:37 +0200
commit2992b53f39ea3d61d4acbe7f7c494f90228ce377 (patch)
treeb3c9c5fc972051bf219b2f36b1ff3066d6d527a7 /writerfilter
parent35ab4087992581104cae28f45b6be97fb1212213 (diff)
n#693238 dmapper: fix margin values vs SBkc = 0 at the end of the doc
The problem was that a continous section break at the end of the document caused the section margins to be ignored. Just ignoring the continous section break (only in case it's at the end of the document) makes the problem go away. The original fix was commit cd1c434c4bd4756fa1355e906cb2e8de4aae0618, but it got reverted in commit 2dee7d6205832a1212790ac1ab168a6b6fce686d, as it caused fdo#44292. This second attempt fixes the original bug again, without introducing the "4 columns" bug. Change-Id: I75d612430a5cd631dec0d224127cba580070900d
Diffstat (limited to 'writerfilter')
-rw-r--r--writerfilter/source/dmapper/DomainMapper.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx
index 5ecceba11cc5..ac52d070fa05 100644
--- a/writerfilter/source/dmapper/DomainMapper.cxx
+++ b/writerfilter/source/dmapper/DomainMapper.cxx
@@ -2369,7 +2369,12 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext, SprmType
*/
OSL_ENSURE(pSectionContext, "SectionContext unavailable!");
if(pSectionContext)
- pSectionContext->SetBreakType( nIntValue );
+ {
+ // Ignore continous section break at the end of the document
+ // It makes the importer loose margin settings with no benefit
+ if (m_pImpl->GetParaSectpr() || nIntValue != 0)
+ pSectionContext->SetBreakType( nIntValue );
+ }
break;
case 143:
case NS_sprm::LN_SFTitlePage: // sprmSFTitlePage