summaryrefslogtreecommitdiff
path: root/writerfilter
diff options
context:
space:
mode:
authorJustin Luth <justin_luth@sil.org>2016-12-20 13:51:26 +0300
committerThorsten Behrens <Thorsten.Behrens@CIB.de>2018-02-02 09:56:29 +0100
commit4b282dc07884f39d31edffb256e608e91eb266b3 (patch)
treecd74bd998e12e96d970b750d1ac1051195407b0b /writerfilter
parent7ae46b7cbb7148412b4093d8a1a419348459b991 (diff)
related to tdf#97417: fix unit test's early para numbering
The unit test's first blank page already started the paragraph numbering. Setting it so that a contentless, single paragraph section will not display numbering. In fact, no dummy paragraph should have numbering, but that would get complicated. This is in preparation for tdf#104710. Reviewed-on: https://gerrit.libreoffice.org/32235 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> (cherry picked from commit c829e01e973ac32fb625925ce83f843ad30d94db) Reviewed-on: https://gerrit.libreoffice.org/32326 Reviewed-by: Justin Luth <justin_luth@sil.org> Change-Id: I98c9926cb3cd1e3fe3cd43bf46cab22bfbec7eba Reviewed-on: https://gerrit.libreoffice.org/49035 Reviewed-by: Justin Luth <justin_luth@sil.org> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Diffstat (limited to 'writerfilter')
-rw-r--r--writerfilter/source/dmapper/DomainMapper.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx
index eec33d46246f..e364d23f0091 100644
--- a/writerfilter/source/dmapper/DomainMapper.cxx
+++ b/writerfilter/source/dmapper/DomainMapper.cxx
@@ -3277,7 +3277,9 @@ void DomainMapper::lcl_utext(const sal_uInt8 * data_, size_t len)
// If the paragraph contains only the section properties and it has
// no runs, we should not create a paragraph for it in Writer, unless that would remove the whole section.
bool bRemove = !m_pImpl->GetParaChanged() && m_pImpl->GetParaSectpr() && !bSingleParagraph && !m_pImpl->GetIsDummyParaAddedForTableInSection();
- PropertyMapPtr xContext = bRemove ? m_pImpl->GetTopContextOfType(CONTEXT_PARAGRAPH) : PropertyMapPtr();
+
+ const bool bNoNumbering = bRemove || (!m_pImpl->GetParaChanged() && m_pImpl->GetParaSectpr() && bSingleParagraph);
+ PropertyMapPtr xContext = bNoNumbering ? m_pImpl->GetTopContextOfType(CONTEXT_PARAGRAPH) : PropertyMapPtr();
if (xContext)
{
// tdf#97417 delete numbering of the paragraph