diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2017-05-26 18:13:54 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2017-05-26 23:17:16 +0200 |
commit | f85ded43446b17fbfdd868cc057ba39666d3d7cb (patch) | |
tree | 8ee201762ab53cdc724270ccc93e42f29e3ddf11 /sw/source/ui/config | |
parent | 0714d2f3009bbb24501561c1a8e96a6feb9a42ca (diff) |
tdf#108056 sw: add UI to disable SubtractFlysAnchoredAtFlys compat option
There is a reason this is off by default, make it a bit more easier for
users to not depend this option when they don't actually need it.
Change-Id: I21c5b942c6021fa21840779e1a9f53055fbf279f
Reviewed-on: https://gerrit.libreoffice.org/38081
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'sw/source/ui/config')
-rw-r--r-- | sw/source/ui/config/optcomp.cxx | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/sw/source/ui/config/optcomp.cxx b/sw/source/ui/config/optcomp.cxx index 3dc5d377ace0..4feaf12b3684 100644 --- a/sw/source/ui/config/optcomp.cxx +++ b/sw/source/ui/config/optcomp.cxx @@ -114,7 +114,8 @@ sal_uLong convertBools2Ulong_Impl bool _bConsiderWrappingStyle, bool _bExpandWordSpace, bool _bProtectForm, - bool _bMsWordCompTrailingBlanks + bool _bMsWordCompTrailingBlanks, + bool bSubtractFlysAnchoredAtFlys ) { sal_uLong nRet = 0; @@ -158,6 +159,9 @@ sal_uLong convertBools2Ulong_Impl nSetBit = nSetBit << 1; if ( _bMsWordCompTrailingBlanks ) nRet |= nSetBit; + nSetBit = nSetBit << 1; + if (bSubtractFlysAnchoredAtFlys) + nRet |= nSetBit; return nRet; } @@ -241,7 +245,8 @@ void SwCompatibilityOptPage::InitControls( const SfxItemSet& rSet ) aEntry.getValue<bool>( SvtCompatibilityEntry::Index::ConsiderWrappingStyle ), aEntry.getValue<bool>( SvtCompatibilityEntry::Index::ExpandWordSpace ), aEntry.getValue<bool>( SvtCompatibilityEntry::Index::ProtectForm ), - aEntry.getValue<bool>( SvtCompatibilityEntry::Index::MsWordTrailingBlanks ) ); + aEntry.getValue<bool>( SvtCompatibilityEntry::Index::MsWordTrailingBlanks ), + aEntry.getValue<bool>( SvtCompatibilityEntry::Index::SubtractFlysAnchoredAtFlys ) ); m_pFormattingLB->SetEntryData( nPos, reinterpret_cast<void*>((sal_IntPtr)nOptions) ); } @@ -313,7 +318,8 @@ sal_uLong SwCompatibilityOptPage::GetDocumentOptions() const rIDocumentSettingAccess.get( DocumentSettingId::CONSIDER_WRAP_ON_OBJECT_POSITION ), !rIDocumentSettingAccess.get( DocumentSettingId::DO_NOT_JUSTIFY_LINES_WITH_MANUAL_BREAK ), rIDocumentSettingAccess.get( DocumentSettingId::PROTECT_FORM ), - rIDocumentSettingAccess.get( DocumentSettingId::MS_WORD_COMP_TRAILING_BLANKS ) ); + rIDocumentSettingAccess.get( DocumentSettingId::MS_WORD_COMP_TRAILING_BLANKS ), + rIDocumentSettingAccess.get( DocumentSettingId::SUBTRACT_FLYS ) ); } return nRet; } @@ -401,6 +407,10 @@ bool SwCompatibilityOptPage::FillItemSet( SfxItemSet* ) m_pWrtShell->SetMsWordCompTrailingBlanks( bChecked ); break; + case SvtCompatibilityEntry::Index::SubtractFlysAnchoredAtFlys: + m_pWrtShell->SetSubtractFlysAnchoredAtFlys(bChecked); + break; + default: break; } |