summaryrefslogtreecommitdiff
path: root/sw/source/core/edit/autofmt.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2017-06-19 09:32:45 +0200
committerStephan Bergmann <sbergman@redhat.com>2017-06-19 09:38:05 +0200
commit1e3a00f0c772a76a1dd76b8272e2c35a1802d574 (patch)
treea1eadac1680f1e46c789964200aa8a61bb659189 /sw/source/core/edit/autofmt.cxx
parent9fe114e78f1285397dcd2a0d2e3d6afc3024fa66 (diff)
Make SfxItemSet ranges correct by construction: Fix static cases
...with the aid of an extended compilerplugins/clang/store/sfxitemsetrewrite.cxx (which in turn needed a small addition to compilerplugins/clang/check.hxx). Enable svl::detail::validGap check for the static case, but keep it disabled for now for the dynamic case. Change-Id: I4846ba8e99aff94a86518e2cb5044e575093386e
Diffstat (limited to 'sw/source/core/edit/autofmt.cxx')
-rw-r--r--sw/source/core/edit/autofmt.cxx12
1 files changed, 7 insertions, 5 deletions
diff --git a/sw/source/core/edit/autofmt.cxx b/sw/source/core/edit/autofmt.cxx
index f9e37f7ab433..06fc8d8605a8 100644
--- a/sw/source/core/edit/autofmt.cxx
+++ b/sw/source/core/edit/autofmt.cxx
@@ -986,11 +986,13 @@ void SwAutoFormat::SetColl( sal_uInt16 nId, bool bHdLineOrText )
m_aDelPam.GetPoint()->nContent.Assign( m_pCurTextNd, 0 );
// keep hard tabs, alignment, language, hyphenation, DropCaps and nearly all frame attributes
- SfxItemSet aSet( m_pDoc->GetAttrPool(),
- svl::Items<RES_PARATR_ADJUST, RES_PARATR_ADJUST,
- RES_PARATR_TABSTOP, RES_PARATR_DROP,
- RES_CHRATR_LANGUAGE, RES_CHRATR_LANGUAGE,
- RES_BACKGROUND, RES_SHADOW>{} );
+ SfxItemSet aSet(
+ m_pDoc->GetAttrPool(),
+ svl::Items<
+ RES_CHRATR_LANGUAGE, RES_CHRATR_LANGUAGE,
+ RES_PARATR_ADJUST, RES_PARATR_ADJUST,
+ RES_PARATR_TABSTOP, RES_PARATR_DROP,
+ RES_BACKGROUND, RES_SHADOW>{});
if( m_pCurTextNd->HasSwAttrSet() )
{