diff options
author | Valentin Kettner <vakevk+libreoffice@gmail.com> | 2014-05-23 14:43:48 +0200 |
---|---|---|
committer | Valentin Kettner <vakevk+libreoffice@gmail.com> | 2014-06-03 19:12:01 +0200 |
commit | 051bf9d29e518797932804228668740e977efc13 (patch) | |
tree | 200b34a4653b950e1e7eeef7c9113a33ba33e27d /sw/source/core | |
parent | dbb2e6befb9d0e970048dfb2c31c7cdc281c8ed5 (diff) |
Work on DocumentSettingManager for SwDoc.
Moved mn32DummyCompatabilityOptions1 from SwDoc to DocumentSettingManager
and moved a comment from SwDoc to it.
Change-Id: I4abd5cd9596d23dc3ac12460ee9b38345d0bf0a7
Diffstat (limited to 'sw/source/core')
-rw-r--r-- | sw/source/core/doc/DocumentSettingManager.cxx | 27 | ||||
-rw-r--r-- | sw/source/core/doc/docnew.cxx | 12 | ||||
-rw-r--r-- | sw/source/core/inc/DocumentSettingManager.hxx | 67 |
3 files changed, 92 insertions, 14 deletions
diff --git a/sw/source/core/doc/DocumentSettingManager.cxx b/sw/source/core/doc/DocumentSettingManager.cxx index 1f2b3775a1d6..4cd205812bf5 100644 --- a/sw/source/core/doc/DocumentSettingManager.cxx +++ b/sw/source/core/doc/DocumentSettingManager.cxx @@ -33,11 +33,12 @@ /* IDocumentSettingAccess */ sw::DocumentSettingManager::DocumentSettingManager(SwDoc &rDoc) - :m_rDoc(rDoc) - , + :m_rDoc(rDoc), mnLinkUpdMode( GLOBALSETTING ), meFldUpdMode( AUTOUPD_GLOBALSETTING ), meChrCmprType( CHARCOMPRESS_NONE ), + mn32DummyCompatabilityOptions1(0), + mn32DummyCompatabilityOptions2(0), mbHTMLMode(false), mbIsGlobalDoc(false), mbGlblDocSaveLinks(false), @@ -480,6 +481,9 @@ void sw::DocumentSettingManager::setCharacterCompressionType( /*[in]*/SwCharComp void sw::DocumentSettingManager::ReplaceCompatabilityOptions(const DocumentSettingManager& rSource) { + Setn32DummyCompatabilityOptions1( rSource.Getn32DummyCompatabilityOptions1() ); + Setn32DummyCompatabilityOptions2( rSource.Getn32DummyCompatabilityOptions2() ); + mbParaSpaceMax = rSource.mbParaSpaceMax; mbParaSpaceMaxAtPages = rSource.mbParaSpaceMaxAtPages; mbTabCompat = rSource.mbTabCompat; @@ -506,4 +510,23 @@ void sw::DocumentSettingManager::ReplaceCompatabilityOptions(const DocumentSetti mbTabAtLeftIndentForParagraphsInList = rSource.mbTabAtLeftIndentForParagraphsInList; } +sal_uInt32 sw::DocumentSettingManager::Getn32DummyCompatabilityOptions1() const +{ + return mn32DummyCompatabilityOptions1; +} + +void sw::DocumentSettingManager::Setn32DummyCompatabilityOptions1( const sal_uInt32 CompatabilityOptions1 ) +{ + mn32DummyCompatabilityOptions1 = CompatabilityOptions1; +} + +sal_uInt32 sw::DocumentSettingManager::Getn32DummyCompatabilityOptions2() const +{ + return mn32DummyCompatabilityOptions2; +} + +void sw::DocumentSettingManager::Setn32DummyCompatabilityOptions2( const sal_uInt32 CompatabilityOptions2 ) +{ + mn32DummyCompatabilityOptions2 = CompatabilityOptions2; +} /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/doc/docnew.cxx b/sw/source/core/doc/docnew.cxx index 94bd30eb65c4..90f8eae12f7b 100644 --- a/sw/source/core/doc/docnew.cxx +++ b/sw/source/core/doc/docnew.cxx @@ -276,14 +276,6 @@ SwDoc::SwDoc() #endif mbContainsAtPageObjWithContentAnchor(false), //#i119292#, fdo#37024 - // COMPATIBILITY FLAGS START - - mbOldPrinterMetrics(false), - mn32DummyCompatabilityOptions1(0), - mn32DummyCompatabilityOptions2(0), - - // COMPATIBILITY FLAGS END - mbStartIdleTimer(false), mbReadOnly(false), meDocType(DOCTYPE_NATIVE) @@ -1017,10 +1009,6 @@ void SwDoc::ReplaceDefaults(const SwDoc& rSource) void SwDoc::ReplaceCompatabilityOptions(const SwDoc& rSource) { - mn32DummyCompatabilityOptions1 = rSource.mn32DummyCompatabilityOptions1; - mn32DummyCompatabilityOptions2 = rSource.mn32DummyCompatabilityOptions2; - mbOldPrinterMetrics = rSource.mbOldPrinterMetrics; - m_pDocumentSettingManager->ReplaceCompatabilityOptions(rSource.GetDocumentSettingManager()); } diff --git a/sw/source/core/inc/DocumentSettingManager.hxx b/sw/source/core/inc/DocumentSettingManager.hxx index 2e8ab4bdf3a3..b4fc03e57ab9 100644 --- a/sw/source/core/inc/DocumentSettingManager.hxx +++ b/sw/source/core/inc/DocumentSettingManager.hxx @@ -34,6 +34,68 @@ class DocumentSettingManager : SwFldUpdateFlags meFldUpdMode;//< Automatically Update Mode for fields/charts. SwCharCompressType meChrCmprType;//< for ASIAN: compress punctuation/kana + sal_uInt32 mn32DummyCompatabilityOptions1; + sal_uInt32 mn32DummyCompatabilityOptions2; + + // COMPATIBILITY FLAGS START + // + // + // HISTORY OF THE COMPATIBILITY FLAGS: + // + // SO5: + // mbParaSpaceMax def = sal_False, sal_True since SO8 + // mbParaSpaceMaxAtPages def = sal_False, sal_True since SO8 + // + // SO6: + // mbTabCompat def = sal_False, sal_True since SO8 + // + // SO7: + // mbUseVirtualDevice def = sal_True + // mbAddFlyOffsets def = sal_False, hidden + // + // SO7pp1: + // bOldNumbering def = sal_False, hidden + // + // SO8: + // mbAddExternalLeading def = sal_True + // mbUseHiResolutionVirtualDevice def = sal_True, hidden + // mbOldLineSpacing def = sal_False + // mbAddParaSpacingToTableCells def = sal_True + // mbUseFormerObjectPos def = sal_False + // mbUseFormerTextWrapping def = sal_False + // mbConsiderWrapOnObjPos def = sal_False + // + // SO8pp1: + // mbIgnoreFirstLineIndentInNumbering def = sal_False, hidden + // mbDoNotJustifyLinesWithManualBreak def = sal_False, hidden + // mbDoNotResetParaAttrsForNumFont def = sal_False, hidden + // + // SO8pp3 + // mbDoNotCaptureDrawObjsOnPage def = sal_False, hidden + // - Relevant for drawing objects, which don't follow the text flow, but + // whose position is outside the page area: + // sal_False: Such drawing objects are captured on the page area of its anchor. + // sal_True: Such drawing objects can leave the page area, they aren't captured. + // mbTableRowKeep def = sal_False, hidden + // mbIgnoreTabsAndBlanksForLineCalculation def = sal_False, hidden + // mbClipAsCharacterAnchoredWriterFlyFrame def = sal_False, hidden + // - Introduced in order to re-activate clipping of as-character anchored + // Writer fly frames in method <SwFlyInCntFrm::MakeAll()> for documents, + // which are created with version prior SO8/OOo 2.0 + // + // SO8pp4 + // mbUnixForceZeroExtLeading def = sal_False, hidden + // + // SO8pu8 + // + // SO9 + // #i24363# tab stops relative to indent + // mbTabRelativeToIndent def = sal_True, hidden + // #i89181# suppress tab stop at left indent for paragraphs in lists, whose + // list level position and space mode equals LABEL_ALIGNMENT and whose list + // label is followed by a tab character. + // mbTabAtLeftIndentForParagraphsInList def = sal_False, hidden + bool mbHTMLMode : 1; //< TRUE: Document is in HTMLMode. bool mbIsGlobalDoc : 1; //< TRUE: It's a global document. bool mbGlblDocSaveLinks : 1; //< TRUE: Save sections linked in global document. @@ -112,6 +174,11 @@ public: // Replace all compatability options with those from rSource. void ReplaceCompatabilityOptions(const DocumentSettingManager& rSource); + sal_uInt32 Getn32DummyCompatabilityOptions1() const; + void Setn32DummyCompatabilityOptions1( const sal_uInt32 CompatabilityOptions1 ); + sal_uInt32 Getn32DummyCompatabilityOptions2() const; + void Setn32DummyCompatabilityOptions2( const sal_uInt32 CompatabilityOptions2 ); + }; } |