diff options
Diffstat (limited to 'sw/source/core/doc/poolfmt.cxx')
-rw-r--r-- | sw/source/core/doc/poolfmt.cxx | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/sw/source/core/doc/poolfmt.cxx b/sw/source/core/doc/poolfmt.cxx index be521cfdccd7..b32dcab95c1c 100644 --- a/sw/source/core/doc/poolfmt.cxx +++ b/sw/source/core/doc/poolfmt.cxx @@ -25,6 +25,8 @@ #include <doc.hxx> #include <IDocumentState.hxx> #include <IDocumentStylePoolAccess.hxx> +#include <IDocumentListsAccess.hxx> +#include <list.hxx> #include <poolfmt.hxx> #include <pagedesc.hxx> #include <fmtcol.hxx> @@ -106,9 +108,14 @@ bool SwDoc::IsUsed( const SwTableAutoFormat& rTableAutoFormat) const // See if the NumRule is used bool SwDoc::IsUsed( const SwNumRule& rRule ) { + SwList const*const pList(getIDocumentListsAccess().getListByName(rRule.GetDefaultListId())); bool bUsed = rRule.GetTextNodeListSize() > 0 || rRule.GetParagraphStyleListSize() > 0 || - rRule.IsUsedByRedline(); + rRule.IsUsedByRedline() + // tdf#135014 default num rule is used if any associated num rule is used + || (pList + && pList->GetDefaultListStyleName() == rRule.GetName() + && pList->HasNodes()); return bUsed; } |