From f76f2fc99dcb4a6a250835ec1d52e7c3f6a73321 Mon Sep 17 00:00:00 2001 From: Justin Luth Date: Fri, 10 Sep 2021 16:48:47 +0200 Subject: tdf#137363 DOC export: don't lose sprmPIlvl of para style Move the DOCX code so that it provides the style's level to all three formats. (RTF just returns when no text node, so there is no impact in that case). Change-Id: Iadeb3e6d9f4e3f0d86222cb3f6bfef84d87d87f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121909 Tested-by: Justin Luth Reviewed-by: Justin Luth Reviewed-by: Miklos Vajna --- sw/source/filter/ww8/docxattributeoutput.cxx | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'sw/source/filter/ww8/docxattributeoutput.cxx') diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx index d4067db3703b..c2aa3880ece0 100644 --- a/sw/source/filter/ww8/docxattributeoutput.cxx +++ b/sw/source/filter/ww8/docxattributeoutput.cxx @@ -8829,19 +8829,6 @@ void DocxAttributeOutput::ParaNumRule_Impl( const SwTextNode* pTextNd, sal_Int32 return; } - if (!pTextNd && nLvl == 0) - { - // This is a paragraph style and the level would be zero. Then see if the importer set a - // custom numbering level. - const SfxItemSet* pSet = m_rExport.m_pISet; - if (pSet && pSet->HasItem(RES_PARATR_LIST_LEVEL)) - { - // It did, so use that level. - const SfxPoolItem* pItem = pSet->GetItem(RES_PARATR_LIST_LEVEL); - nLvl = pItem->StaticWhichCast(RES_PARATR_LIST_LEVEL).GetValue(); - } - } - m_pSerializer->startElementNS(XML_w, XML_numPr); m_pSerializer->singleElementNS(XML_w, XML_ilvl, FSNS(XML_w, XML_val), OString::number(nLvl)); m_pSerializer->singleElementNS(XML_w, XML_numId, FSNS(XML_w, XML_val), OString::number(nNumId)); -- cgit v1.2.3