xref: /aoo41x/main/sw/inc/doc.hxx (revision 69a74367)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 #ifndef SW_DOC_HXX
24 #define SW_DOC_HXX
25 
26 /** SwDoc interfaces */
27 
28 #include <IInterface.hxx>
29 #include <IDocumentSettingAccess.hxx>
30 #include <IDocumentDeviceAccess.hxx>
31 #include <IDocumentMarkAccess.hxx>
32 #include <IDocumentRedlineAccess.hxx>
33 #include <IDocumentLinksAdministration.hxx>
34 #include <IDocumentFieldsAccess.hxx>
35 #include <IDocumentContentOperations.hxx>
36 #include <IDocumentStylePoolAccess.hxx>
37 #include <IDocumentLineNumberAccess.hxx>
38 #include <IDocumentStatistics.hxx>
39 #include <IDocumentState.hxx>
40 #include <IDocumentDrawModelAccess.hxx>
41 #include <IDocumentLayoutAccess.hxx>
42 #include <IDocumentTimerAccess.hxx>
43 #include <IDocumentChartDataProviderAccess.hxx>
44 // --> OD 2007-10-26 #i83479#
45 #include <IDocumentOutlineNodes.hxx>
46 #include <IDocumentListItems.hxx>
47 #include <set>
48 // <--
49 // --> OD 2008-03-12 #refactorlists#
50 #include <IDocumentListsAccess.hxx>
51 class SwList;
52 // <--
53 #include <IDocumentExternalData.hxx>
54 #define _SVSTDARR_STRINGSDTOR
55 #include <svl/svstdarr.hxx>
56 #include <com/sun/star/embed/XEmbeddedObject.hpp>
57 #include <com/sun/star/embed/XStorage.hpp>
58 #include <vcl/timer.hxx>
59 #include "swdllapi.h"
60 #include <swtypes.hxx>
61 #include <swatrset.hxx>
62 #include <toxe.hxx>   	  		// enums
63 #include <flyenum.hxx>
64 #include <itabenum.hxx>
65 #include <swdbdata.hxx>
66 #include <chcmprse.hxx>
67 #include <com/sun/star/linguistic2/XSpellChecker1.hpp>
68 #include <com/sun/star/linguistic2/XHyphenatedWord.hpp>
69 #include <vos/ref.hxx>
70 #include <svx/svdtypes.hxx>
71 #include <sfx2/objsh.hxx>
72 #include <svl/style.hxx>
73 #include <editeng/numitem.hxx>
74 #include "comphelper/implementationreference.hxx"
75 #include <com/sun/star/chart2/data/XDataProvider.hpp>
76 #include <com/sun/star/linguistic2/XProofreadingIterator.hpp>
77 #ifdef FUTURE_VBA
78 #include <com/sun/star/script/vba/XVBAEventProcessor.hpp>
79 #endif
80 
81 #include <hash_map>
82 #include <stringhash.hxx>
83 
84 #include <svtools/embedhlp.hxx>
85 #include <vector>
86 #include <set>
87 #include <map>
88 #include <memory>
89 
90 #include <boost/scoped_ptr.hpp>
91 #include <boost/shared_ptr.hpp>
92 #include <flypos.hxx>
93 
94 class SvxForbiddenCharactersTable;
95 class SwExtTextInput;
96 class DateTime;
97 class EditFieldInfo;
98 class JobSetup;
99 class Color;
100 class KeyCode;
101 class Outliner;
102 class OutputDevice;
103 class Point;
104 class SbxArray;
105 class SdrModel;
106 class SdrObject;
107 class SdrUndoAction;
108 class VirtualDevice;
109 class SfxPrinter;
110 class SvNumberFormatter;
111 class SvStringsSort;
112 class SvUShorts;
113 class SvUShortsSort;
114 class SvxMacro;
115 class SvxMacroTableDtor;
116 class SvxBorderLine;
117 class SwAutoCompleteWord;
118 class SwAutoCorrExceptWord;
119 class SwCalc;
120 class SwCellFrm;
121 class SwCharFmt;
122 class SwCharFmts;
123 class SwConditionTxtFmtColl;
124 class SwCrsrShell;
125 class SwCursor;
126 class SwDBNameInfField;
127 class SwDocShell;
128 class SwDocUpdtFld;
129 class SwDrawFrmFmt;
130 class SwDrawView;
131 class SwEditShell;
132 class SwFieldType;
133 class SwField;
134 class SwTxtFld;
135 class SwFldTypes;
136 class SwFlyFrmFmt;
137 class SwFmt;
138 class SwFmtINetFmt;
139 class SwFmtRefMark;
140 class SwFrmFmt;
141 class SwFrmFmts;
142 class SwFtnIdxs;
143 class SwFtnInfo;
144 class SwEndNoteInfo;
145 class GraphicObject;
146 class SwGrfFmtColl;
147 class SwGrfFmtColls;
148 class SwLineNumberInfo;
149 class SwNewDBMgr;
150 class SwNoTxtNode;
151 class SwNodeIndex;
152 class SwNodeRange;
153 class SwNodes;
154 class SwNumRule;
155 class SwNumRuleTbl;
156 class SwPageDesc;
157 class SwPagePreViewPrtData;
158 class SwRedline;
159 class SwRedlineTbl;
160 class SwRootFrm;
161 class SwRubyList;
162 class SwRubyListEntry;
163 class SwSectionFmt;
164 class SwSectionFmts;
165 class SwSectionData;
166 class SwSelBoxes;
167 class SwSpzFrmFmts;
168 class SwTOXBase;
169 class SwTOXBaseSection;
170 class SwTOXMark;
171 class SwTOXMarks;
172 class SwTOXType;
173 class SwTOXTypes;
174 class SwTabCols;
175 class SwTable;
176 class SwTableAutoFmt;
177 class SwTableBox;
178 class SwTableBoxFmt;
179 class SwTableFmt;
180 class SwTableLineFmt;
181 class SwTableNode;
182 class SwTextBlocks;
183 class SwTxtFmtColl;
184 class SwTxtFmtColls;
185 class SwURLStateChanged;
186 class SwUnoCrsr;
187 class SwUnoCrsrTbl;
188 class ViewShell;
189 class _SetGetExpFld;
190 class SwDrawContact;
191 class SwLayouter;
192 class SdrView;
193 class SdrMarkList;
194 class SwAuthEntry;
195 class SwLayoutCache;
196 class IStyleAccess;
197 struct SwCallMouseEvent;
198 struct SwDocStat;
199 struct SwHash;
200 struct SwSortOptions;
201 struct SwDefTOXBase_Impl;
202 class SwPrintData;
203 class SwPrintUIOptions;
204 class SdrPageView;
205 struct SwConversionArgs;
206 class SwRewriter;
207 class SwMsgPoolItem;
208 class SwChartDataProvider;
209 class SwChartLockController_Helper;
210 class IGrammarContact;
211 class SwPrintData;
212 class SwRenderData;
213 class SwPageFrm;
214 class SwViewOption;
215 class IDocumentUndoRedo;
216 
217 namespace sw { namespace mark {
218     class MarkManager;
219 }}
220 namespace sw {
221     class MetaFieldManager;
222     class UndoManager;
223     class IShellCursorSupplier;
224 }
225 
226 namespace com { namespace sun { namespace star {
227 namespace i18n {
228 	struct ForbiddenCharacters;    // comes from the I18N UNO interface
229 }
230 namespace uno {
231 	template < class > class Sequence;
232 }
233 namespace container {
234 	class XNameContainer; // for getXForms()/isXForms()/initXForms() methods
235 }
236 }}}
237 
238 namespace sfx2 {
239 	class SvLinkSource;
240     class IXmlIdRegistry;
241     class LinkManager;
242 }
243 
244 //PageDescriptor-Schnittstelle, Array hier wegen inlines.
245 typedef SwPageDesc* SwPageDescPtr;
246 SV_DECL_PTRARR_DEL( SwPageDescs, SwPageDescPtr, 4, 4 )
247 
248 // forward declartion
249 void SetAllScriptItem( SfxItemSet& rSet, const SfxPoolItem& rItem );
250 
251 // global function to start grammar checking in the document
252 void StartGrammarChecking( SwDoc &rDoc );
253 
254 class SW_DLLPUBLIC SwDoc :
255     public IInterface,
256     public IDocumentSettingAccess,
257     public IDocumentDeviceAccess,
258     public IDocumentRedlineAccess,
259     public IDocumentLinksAdministration,
260     public IDocumentFieldsAccess,
261     public IDocumentContentOperations,
262     public IDocumentStylePoolAccess,
263     public IDocumentLineNumberAccess,
264     public IDocumentStatistics,
265     public IDocumentState,
266     public IDocumentDrawModelAccess,
267     public IDocumentLayoutAccess,
268     public IDocumentTimerAccess,
269     public IDocumentChartDataProviderAccess,
270     // --> OD 2007-10-26 #i83479#
271     public IDocumentListItems,
272     public IDocumentOutlineNodes,
273     // <--
274     // --> OD 2008-03-12 #refactorlists#
275     public IDocumentListsAccess,
276     // <--
277     public IDocumentExternalData
278 {
279 
280 	friend void _InitCore();
281 	friend void _FinitCore();
282 
283     //---------------- private Member --------------------------------
284 
285 	// -------------------------------------------------------------------
286     ::boost::scoped_ptr<SwNodes> m_pNodes;  /// document content (Nodes Array)
287 	SwAttrPool*	mpAttrPool;				// der Attribut Pool
288 	SwPageDescs	aPageDescs;				// PageDescriptoren
289 	Link 		aOle2Link;				// OLE 2.0-Benachrichtigung
290     /* @@@MAINTAINABILITY-HORROR@@@
291        Timer should not be members of the model
292     */
293     Timer       aIdleTimer;             // der eigene IdleTimer
294 	Timer		aOLEModifiedTimer; 		// Timer for update modified OLE-Objecs
295 	SwDBData	aDBData;				// database descriptor
296 	::com::sun::star::uno::Sequence <sal_Int8 > aRedlinePasswd;
297 	String		sTOIAutoMarkURL; 		// ::com::sun::star::util::URL of table of index AutoMark file
298 	SvStringsDtor aPatternNms;			// Array fuer die Namen der Dokument-Vorlagen
299 	com::sun::star::uno::Reference<com::sun::star::container::XNameContainer>
300         xXForms;                        // container with XForms models
301     mutable com::sun::star::uno::Reference< com::sun::star::linguistic2::XProofreadingIterator > m_xGCIterator;
302 
303     const ::boost::scoped_ptr< ::sw::mark::MarkManager> pMarkManager;
304     const ::boost::scoped_ptr< ::sw::MetaFieldManager > m_pMetaFieldManager;
305     const ::boost::scoped_ptr< ::sw::UndoManager > m_pUndoManager;
306 
307 	// -------------------------------------------------------------------
308 	// die Pointer
309 								//Defaultformate
310 	SwFrmFmt		*pDfltFrmFmt;
311  	SwFrmFmt		*pEmptyPageFmt;		// Format fuer die Default-Leerseite.
312 	SwFrmFmt		*pColumnContFmt; 	// Format fuer Spaltencontainer
313 	SwCharFmt		*pDfltCharFmt;
314 	SwTxtFmtColl	*pDfltTxtFmtColl;	// Defaultformatcollections
315 	SwGrfFmtColl	*pDfltGrfFmtColl;
316 
317 	SwFrmFmts		*pFrmFmtTbl;		// Formattabellen
318 	SwCharFmts		*pCharFmtTbl;
319 	SwSpzFrmFmts	*pSpzFrmFmtTbl;
320 	SwSectionFmts	*pSectionFmtTbl;
321 	SwFrmFmts		*pTblFrmFmtTbl;		// spz. fuer Tabellen
322 	SwTxtFmtColls	*pTxtFmtCollTbl;	// FormatCollections
323 	SwGrfFmtColls	*pGrfFmtCollTbl;
324 
325 	SwTOXTypes		*pTOXTypes;			// Verzeichnisse
326 	SwDefTOXBase_Impl * pDefTOXBases;	// defaults of SwTOXBase's
327 
328 	ViewShell		*pCurrentView;	// SwDoc should get a new member pCurrentView//swmod 071225
329 	boost::shared_ptr<SwRootFrm> pLayoutPtr;
330 	SdrModel		*pDrawModel;		// StarView Drawing
331 
332 	SwDocUpdtFld 	*pUpdtFlds;			// Struktur zum Field-Update
333 	SwFldTypes		*pFldTypes;			// Feldtypen
334 	SwNewDBMgr 		*pNewDBMgr;			// Pointer auf den neuen DBMgr fuer
335 										// Evaluierung der DB-Fields
336 
337     VirtualDevice   *pVirDev;           // can be used for formatting
338     SfxPrinter      *pPrt;              // can be used for formatting
339     SwPrintData     *pPrtData;          // Print configuration
340 
341 	SwDoc			*pGlossaryDoc;		// Pointer auf das Glossary-Dokument. Dieses
342 
343 	SwNumRule		*pOutlineRule;
344 	SwFtnInfo		*pFtnInfo;
345 	SwEndNoteInfo 	*pEndNoteInfo;
346     SwLineNumberInfo*pLineNumberInfo;
347 	SwFtnIdxs		*pFtnIdxs;
348 	SwDocStat		*pDocStat;			// Statistic Informationen
349 	SvxMacroTableDtor *pMacroTable; 	// Tabelle der dokumentglobalen Macros
350 
351 	SwDocShell		*pDocShell;			// Ptr auf die SfxDocShell vom Doc
352     SfxObjectShellLock xTmpDocShell;    // A temporary shell that is used to copy OLE-Nodes
353 
354 	sfx2::LinkManager	*pLinkMgr;			// Liste von Verknuepften (Grafiken/DDE/OLE)
355 
356 	SwAutoCorrExceptWord *pACEWord;		// fuer die automatische Uebernahme von
357 										// autokorrigierten Woertern, die "zurueck"
358 										// verbessert werden
359 	SwURLStateChanged *pURLStateChgd;	// SfxClient fuer Aenderungen in der
360 										// INetHistory
361 	SvNumberFormatter *pNumberFormatter;	// NumFormatter fuer die Tabellen/Felder
362 
363     mutable SwNumRuleTbl    *pNumRuleTbl;           // Liste aller benannten NumRules
364 
365     // Hash map to find numrules by name
366     mutable std::hash_map<String, SwNumRule *, StringHash> maNumRuleMap;
367 
368     // --> OD 2008-03-12 #refactorlists#
369     typedef std::hash_map< String, SwList*, StringHash > tHashMapForLists;
370     // container to hold the lists of the text document
371     tHashMapForLists maLists;
372     // relation between list style and its default list
373     tHashMapForLists maListStyleLists;
374     // <--
375 
376 	SwRedlineTbl	*pRedlineTbl;			// Liste aller Redlines
377 	String			*pAutoFmtRedlnComment;	// Kommentar fuer Redlines, die
378 										// uebers Autoformat eingefuegt werden
379 	SwUnoCrsrTbl	*pUnoCrsrTbl;
380 
381 	SwPagePreViewPrtData *pPgPViewPrtData;		// Einzuege/Abstaende fuers
382 										// Drucken der Seitenansicht
383 	SwPaM			*pExtInputRing;
384 
385 	SwLayouter		*pLayouter;		// ::com::sun::star::frame::Controller for complex layout formatting
386 									// like footnote/endnote in sections
387     IStyleAccess    *pStyleAccess;  // handling of automatic styles
388     SwLayoutCache   *pLayoutCache;  // Layout cache to read and save with the
389                                     // document for a faster formatting
390 
391     SwModify *pUnoCallBack;
392     IGrammarContact *mpGrammarContact;   // for grammar checking in paragraphs during editing
393 
394     mutable  comphelper::ImplementationReference< SwChartDataProvider
395         , ::com::sun::star::chart2::data::XDataProvider >
396                                 aChartDataProviderImplRef;
397     SwChartLockController_Helper  *pChartControllerHelper;
398 
399 	// table of forbidden characters of this document
400 	vos::ORef<SvxForbiddenCharactersTable>	xForbiddenCharsTable;
401 #ifdef FUTURE_VBA
402     com::sun::star::uno::Reference< com::sun::star::script::vba::XVBAEventProcessor > mxVbaEvents;
403 #endif
404     // --> OD 2007-10-26 #i83479#
405 public:
406     struct lessThanNodeNum
407     {
408         bool operator()( const SwNodeNum* pNodeNumOne,
409                          const SwNodeNum* pNodeNumTwo ) const;
410     };
411 
412     typedef ::std::set< const SwNodeNum*, lessThanNodeNum > tImplSortedNodeNumList;
413 private:
414     tImplSortedNodeNumList* mpListItemsList;
415     // <--
416 
417     ::std::auto_ptr< ::sfx2::IXmlIdRegistry > m_pXmlIdRegistry;
418 
419 	// -------------------------------------------------------------------
420 	// sonstige
421 
422 	sal_uInt16 nAutoFmtRedlnCommentNo;	// SeqNo fuers UI-seitige zusammenfassen
423 									// von AutoFmt-Redlines. Wird vom SwAutoFmt
424 									// verwaltet!
425 	sal_uInt16	nLinkUpdMode;		// UpdateMode fuer Links
426     SwFldUpdateFlags    eFldUpdMode;        // Mode fuer Felder/Charts automatisch aktualisieren
427 	RedlineMode_t eRedlineMode;		// aktueller Redline Modus
428 	SwCharCompressType eChrCmprType;	// for ASIAN: compress punctuation/kana
429 
430     sal_Int32   mReferenceCount;
431     sal_Int32   mIdleBlockCount;
432 	sal_Int8	nLockExpFld;		// Wenn != 0 hat UpdateExpFlds() keine Wirkung
433 
434     /* Draw Model Layer IDs
435      * LayerIds, Heaven == ueber dem Dokument
436      * Hell   == unter dem Dokument
437      * Controls == ganz oben
438      */
439     SdrLayerID  nHeaven;
440     SdrLayerID  nHell;
441     SdrLayerID  nControls;
442     SdrLayerID  nInvisibleHeaven;
443     SdrLayerID  nInvisibleHell;
444     SdrLayerID  nInvisibleControls;
445 
446     bool mbGlossDoc              : 1;    //sal_True: ist ein Textbaustein Dokument
447     bool mbModified              : 1;    //sal_True: Dokument ist veraendert
448     bool mbDtor                  : 1;    //sal_True: ist im SwDoc DTOR
449                                          //      leider auch temporaer von
450                                          //      SwSwgReader::InLayout(), wenn fehlerhafte
451                                          //      Frames geloescht werden muessen
452     bool mbPageNums              : 1;    // TRUE: es gibt virtuelle Seitennummern
453     bool mbLoaded                : 1;    // TRUE: ein geladenes Doc
454     bool mbUpdateExpFld          : 1;    // TRUE: Expression-Felder updaten
455     bool mbNewDoc                : 1;    // TRUE: neues Doc
456     bool mbNewFldLst             : 1;    // TRUE: Felder-Liste neu aufbauen
457     bool mbCopyIsMove            : 1;    // TRUE: Copy ist ein verstecktes Move
458     bool mbVisibleLinks          : 1;    // TRUE: Links werden sichtbar eingefuegt
459     bool mbInReading             : 1;    // TRUE: Dokument wird gerade gelesen
460     bool mbInXMLImport           : 1;    // TRUE: During xml import, attribute portion building is not necessary
461     bool mbUpdateTOX             : 1;    // TRUE: nach Dokument laden die TOX Updaten
462     bool mbInLoadAsynchron       : 1;    // TRUE: Dokument wird gerade asynchron geladen
463     bool mbHTMLMode              : 1;    // TRUE: Dokument ist im HTMLMode
464     bool mbInCallModified        : 1;    // TRUE: im Set/Reset-Modified Link
465     bool mbIsGlobalDoc           : 1;    // TRUE: es ist ein GlobalDokument
466     bool mbGlblDocSaveLinks      : 1;    // TRUE: im GlobalDoc. gelinkte Sect. mit speichern
467     bool mbIsLabelDoc            : 1;    // TRUE: es ist ein Etiketten-Dokument
468     bool mbIsAutoFmtRedline      : 1;    // TRUE: die Redlines werden vom Autoformat aufgezeichnet
469     bool mbOLEPrtNotifyPending   : 1;    // TRUE: Printer  ist geaendert und beim
470                                          //       Erzeugen der ::com::sun::star::sdbcx::View ist eine Benachrichtigung
471                                          //       der OLE-Objekte PrtOLENotify() notwendig.
472     bool mbAllOLENotify          : 1;    // True: Benachrichtigung aller Objekte ist notwendig
473     bool mbIsRedlineMove         : 1;    // True: die Redlines werden in/aus der Section verschoben
474     bool mbInsOnlyTxtGlssry      : 1;    // True: insert 'only text' glossary into doc
475     bool mbContains_MSVBasic     : 1;    // True: MS-VBasic exist is in our storage
476     bool mbPurgeOLE              : 1;    // sal_True: Purge OLE-Objects
477     bool mbKernAsianPunctuation  : 1;    // sal_True: kerning also for ASIAN punctuation
478     bool mbReadlineChecked       : 1;    // sal_True: if the query was already shown
479     bool mbLinksUpdated          : 1;    // OD 2005-02-11 #i38810#
480                                          // flag indicating, that the links have been updated.
481     bool mbClipBoard             : 1;    // true: this document represents the clipboard
482     bool mbColumnSelection       : 1;    // true: this content has bee created by a column selection
483                                          //       (clipboard docs only)
484 	//IAccessibility2 Implementation 2009-----
485 	sal_Bool	bIsPrepareSelAll		:1;
486 	//-----IAccessibility2 Implementation 2009
487 
488 #ifdef DBG_UTIL
489     bool mbXMLExport : 1;                // sal_True: during XML export
490 #endif
491 
492     // --> OD 2006-03-21 #b6375613#
493     // Document flag to trigger conversion, which applys the workaround for documents,
494     // which uses a certain layout defect in OOo 1.x to layout the documents.
495     // This conversion is performed, when the frames for the layout are created.
496     // Thus, this document flag has to be set after load a document and before
497     // creating the document view.
498     bool mbApplyWorkaroundForB6375613 : 1;
499     // <--
500 
501     // true: Document contains at least one anchored object, which is anchored AT_PAGE with a content position.
502     //       Thus, certain adjustment needed during formatting for these kind of anchored objects.
503     bool mbContainsAtPageObjWithContentAnchor : 1;
504 
505     //
506     // COMPATIBILITY FLAGS START
507     //
508     //
509     // HISTORY OF THE COMPATIBILITY FLAGS:
510     //
511     // SO5:
512     // mbParaSpaceMax                        def = sal_False, sal_True since SO8
513     // mbParaSpaceMaxAtPages                 def = sal_False, sal_True since SO8
514     //
515     // SO6:
516     // mbTabCompat                           def = sal_False, sal_True since SO8
517     //
518     // SO7:
519     // mbUseVirtualDevice                    def = sal_True
520     // mbAddFlyOffsets                       def = sal_False, hidden
521     //
522     // SO7pp1:
523     // bOldNumbering                        def = sal_False, hidden
524     //
525     // SO8:
526     // mbAddExternalLeading                  def = sal_True
527     // mbUseHiResolutionVirtualDevice        def = sal_True, hidden
528     // mbOldLineSpacing                      def = sal_False
529     // mbAddParaSpacingToTableCells          def = sal_True
530     // mbUseFormerObjectPos                  def = sal_False
531     // mbUseFormerTextWrapping               def = sal_False
532     // mbConsiderWrapOnObjPos                def = sal_False
533     //
534     // SO8pp1:
535     // mbIgnoreFirstLineIndentInNumbering    def = sal_False, hidden
536     // mbDoNotJustifyLinesWithManualBreak    def = sal_False, hidden
537     // mbDoNotResetParaAttrsForNumFont       def = sal_False, hidden
538     //
539     // SO8pp3
540     // mbDoNotCaptureDrawObjsOnPage         def = sal_False, hidden
541     // - Relevant for drawing objects, which don't follow the text flow, but
542     //   whose position is outside the page area:
543     //   sal_False: Such drawing objects are captured on the page area of its anchor.
544     //   sal_True: Such drawing objects can leave the page area, they aren't captured.
545     // mbTableRowKeep                            def = sal_False, hidden
546     // mbIgnoreTabsAndBlanksForLineCalculation   def = sal_False, hidden
547     // mbClipAsCharacterAnchoredWriterFlyFrame   def = sal_False, hidden
548     // - Introduced in order to re-activate clipping of as-character anchored
549     //   Writer fly frames in method <SwFlyInCntFrm::MakeAll()> for documents,
550     //   which are created with version prior SO8/OOo 2.0
551     //
552     // SO8pp4
553     // mbUnixForceZeroExtLeading                def = sal_False, hidden
554     //
555     // SO8pu8
556     // mbOldPrinterMetrics                      def = sal_False, hidden
557     //
558     // SO9
559     // #i24363# tab stops relative to indent
560     // mbTabRelativeToIndent                    def = sal_True, hidden
561     // #i89181# suppress tab stop at left indent for paragraphs in lists, whose
562     // list level position and space mode equals LABEL_ALIGNMENT and whose list
563     // label is followed by a tab character.
564     // mbTabAtLeftIndentForParagraphsInList     def = sal_False, hidden
565 
566     bool mbParaSpaceMax                     : 1;
567     bool mbParaSpaceMaxAtPages              : 1;
568     bool mbTabCompat                        : 1;
569     bool mbUseVirtualDevice                 : 1;
570     bool mbAddFlyOffsets                    : 1;
571     bool mbAddExternalLeading               : 1;
572     bool mbUseHiResolutionVirtualDevice     : 1;
573     bool mbOldLineSpacing                   : 1;    // OD  2004-01-06 #i11859#
574     bool mbAddParaSpacingToTableCells       : 1;    // OD  2004-02-16 #106629#
575     bool mbUseFormerObjectPos               : 1;    // OD  2004-03-12 #i11860#
576     bool mbUseFormerTextWrapping            : 1;    // FME 2005-05-11 #108724#
577     bool mbConsiderWrapOnObjPos             : 1;    // OD  2004-05-05 #i28701#
578                                                     // sal_True: object positioning algorithm has consider the wrapping style of                                                    //       the floating screen objects as given by its attribute 'WrapInfluenceOnObjPos'
579     bool mbMathBaselineAlignment            : 1;    // TL  2010-10-29 #i972#
580 
581     // non-ui-compatibility flags:
582     bool mbOldNumbering                             : 1;   // HBRINKM #111955#
583     bool mbIgnoreFirstLineIndentInNumbering         : 1;   // FME 2005-05-30# i47448#
584     bool mbDoNotJustifyLinesWithManualBreak         : 1;   // FME 2005-06-08 #i49277#
585     bool mbDoNotResetParaAttrsForNumFont            : 1;   // FME 2005-08-11 #i53199#
586     bool mbTableRowKeep                             : 1;   // FME 2006-02-10 #131283#
587     bool mbIgnoreTabsAndBlanksForLineCalculation    : 1;   // FME 2006-03-01 #i3952#
588     bool mbDoNotCaptureDrawObjsOnPage               : 1;   // OD 2006-03-14 #i62875#
589     bool mbOutlineLevelYieldsOutlineRule            : 1;
590     bool mbClipAsCharacterAnchoredWriterFlyFrames   : 1;   // OD 2006-04-13 #b6402800#
591     bool mbUnixForceZeroExtLeading                  : 1;   // FME 2006-10-09 #i60945#
592     bool mbOldPrinterMetrics                        : 1;   // FME 2007-05-14 #147385#
593     bool mbTabRelativeToIndent                      : 1;   // #i24363# tab stops relative to indent
594     bool mbProtectForm                              : 1;
595     bool mbTabAtLeftIndentForParagraphsInList;             // OD 2008-06-05 #i89181# - see above
596 
597     bool mbLastBrowseMode                           : 1;
598 
599 	// #i78591#
600 	sal_uInt32  n32DummyCompatabilityOptions1;
601 	sal_uInt32  n32DummyCompatabilityOptions2;
602     //
603     // COMPATIBILITY FLAGS END
604     //
605 
606     sal_Bool    mbStartIdleTimer                 ;    // idle timer mode start/stop
607 
608 	static SwAutoCompleteWord *pACmpltWords;	// Liste aller Worte fuers AutoComplete
609 
610 	//---------------- private Methoden ------------------------------
611 	void checkRedlining(RedlineMode_t& _rReadlineMode);
612 
613 	DECL_LINK( AddDrawUndo, SdrUndoAction * );
614 										// DrawModel
615 	void DrawNotifyUndoHdl();	// wegen CLOOKs
616 
617 		// nur fuer den internen Gebrauch deshalb privat.
618 		// Kopieren eines Bereiches im oder in ein anderes Dokument !
619 		// Die Position darf nicht im Bereich liegen !!
620     bool CopyImpl( SwPaM&, SwPosition&, const bool MakeNewFrms /*= true */,
621             const bool bCopyAll, SwPaM *const pCpyRng /*= 0*/ ) const;
622 
623 	SwFlyFrmFmt* _MakeFlySection( const SwPosition& rAnchPos,
624 								const SwCntntNode& rNode, RndStdIds eRequestId,
625 								const SfxItemSet* pFlyAttrSet,
626 								SwFrmFmt* = 0 );
627 
628 	SwFlyFrmFmt* _InsNoTxtNode( const SwPosition&rPos, SwNoTxtNode*,
629 								const SfxItemSet* pFlyAttrSet,
630 								const SfxItemSet* pGrfAttrSet,
631 								SwFrmFmt* = 0 );
632 
633     void CopyFlyInFlyImpl(  const SwNodeRange& rRg,
634                             const xub_StrLen nEndContentIndex,
635                             const SwNodeIndex& rStartIdx,
636                             const bool bCopyFlyAtFly = false ) const;
637     sal_Int8 SetFlyFrmAnchor( SwFrmFmt& rFlyFmt, SfxItemSet& rSet, sal_Bool bNewFrms );
638 
639     // --> OD 2005-01-13 #i40550#
640     typedef SwFmt* (SwDoc:: *FNCopyFmt)( const String&, SwFmt*, sal_Bool, sal_Bool );
641     // <--
642 	SwFmt* CopyFmt( const SwFmt& rFmt, const SvPtrarr& rFmtArr,
643 						FNCopyFmt fnCopyFmt, const SwFmt& rDfltFmt );
644 	void CopyFmtArr( const SvPtrarr& rSourceArr, SvPtrarr& rDestArr,
645 						FNCopyFmt fnCopyFmt, SwFmt& rDfltFmt );
646     void CopyPageDescHeaderFooterImpl( bool bCpyHeader,
647 								const SwFrmFmt& rSrcFmt, SwFrmFmt& rDestFmt );
648 	SwFmt* FindFmtByName( const SvPtrarr& rFmtArr,
649 									const String& rName ) const;
650 
651     VirtualDevice& CreateVirtualDevice_() const;
652     SfxPrinter& CreatePrinter_() const;
653 	void		PrtDataChanged();	//Printer oder JobSetup geandert, es muss
654 									//fuer entsprechende Invalidierungen und
655 									//Benachrichtigungen gesorgt werden.
656 
657 	// gcc: aFtnInfo::CopyCtor ist private, also muessen wir uns auch schuetzen
658 	SwDoc( const SwDoc &);
659 
660     // fuer Felder:
661 	void _InitFieldTypes(); 	// wird vom CTOR gerufen!!
662 	void _MakeFldList( int eMode );
663 
664 	// Datenbankfelder:
665 	void UpdateDBNumFlds( SwDBNameInfField& rDBFld, SwCalc& rCalc );
666 	void AddUsedDBToList( SvStringsDtor& rDBNameList,
667 						  const SvStringsDtor& rUsedDBNames );
668 	void AddUsedDBToList( SvStringsDtor& rDBNameList, const String& rDBName );
669 	sal_Bool IsNameInArray( const SvStringsDtor& rOldNames, const String& rName );
670 	void GetAllDBNames( SvStringsDtor& rAllDBNames );
671 	void ReplaceUsedDBs( const SvStringsDtor& rUsedDBNames,
672 						const String& rNewName, String& rFormel );
673 	SvStringsDtor& FindUsedDBs( const SvStringsDtor& rAllDBNames,
674 								const String& rFormel,
675 								SvStringsDtor& rUsedDBNames );
676 
677 	void InitDrawModel();
678 	void ReleaseDrawModel();
679 
680 	void _CreateNumberFormatter();
681 
682 	sal_Bool _UnProtectTblCells( SwTable& rTbl );
683 
684 	// erzeuge Anhand der vorgebenen Collection Teildokumente
685 	// falls keine angegeben ist, nehme die Kapitelvorlage der 1. Ebene
686 	sal_Bool SplitDoc( sal_uInt16 eDocType, const String& rPath,
687 						const SwTxtFmtColl* pSplitColl );
688 	sal_Bool SplitDoc( sal_uInt16 eDocType, const String& rPath, int nOutlineLevel = 0 ); //#outline level,add by zhaijianwei.
689 
690 
691 	// Charts der angegebenen Tabelle updaten
692 	void _UpdateCharts( const SwTable& rTbl, ViewShell& rVSh ) const;
693 
694 	sal_Bool _SelectNextRubyChars( SwPaM& rPam, SwRubyListEntry& rRubyEntry,
695 								sal_uInt16 nMode );
696 
697 	// unser eigener 'IdlTimer' ruft folgende Methode
698 	DECL_LINK( DoIdleJobs, Timer * );
699 	// der CharTimer ruft diese Methode
700 	DECL_LINK( DoUpdateAllCharts, Timer * );
701 	DECL_LINK( DoUpdateModifiedOLE, Timer * );
702 
703      SwFmt *_MakeCharFmt(const String &, SwFmt *, sal_Bool, sal_Bool );
704      SwFmt *_MakeFrmFmt(const String &, SwFmt *, sal_Bool, sal_Bool );
705      SwFmt *_MakeTxtFmtColl(const String &, SwFmt *, sal_Bool, sal_Bool );
706 
707 //IAccessibility2 Implementation 2009-----
708 private:
709 	sal_Bool bReadOnly;
710 	String msDocAccTitle;
711 
712      void InitTOXTypes();
713      void   Paste( const SwDoc& );
714      bool DeleteAndJoinImpl(SwPaM&, const bool);
715      bool DeleteAndJoinWithRedlineImpl(SwPaM&, const bool unused = false);
716      bool DeleteRangeImpl(SwPaM&, const bool unused = false);
717      bool DeleteRangeImplImpl(SwPaM &);
718      bool ReplaceRangeImpl(SwPaM&, String const&, const bool);
719 
720 public:
721 	virtual void setDocReadOnly( sal_Bool b) { bReadOnly = b; }
722 	virtual sal_Bool getDocReadOnly() const { return bReadOnly; }
723 	virtual void setDocAccTitle( const String& rTitle ) { msDocAccTitle = rTitle; }
724 	virtual const String getDocAccTitle() const { return msDocAccTitle; }
725 	//-----IAccessibility2 Implementation 2009
726 
727 	enum DocumentType {
728 		DOCTYPE_NATIVE,
729 		DOCTYPE_MSWORD				//This doc medul is come from Ms Word
730 		};
731 	DocumentType	meDocType;
732 	DocumentType	GetDocumentType(){ return meDocType; }
733 	void			SetDocumentType( DocumentType eDocType ) { meDocType = eDocType; }
734 
735     /** Life cycle
736     */
737 	SwDoc();
738 	~SwDoc();
739 
740     inline bool IsInDtor() const { return mbDtor; }
741 
742     /* @@@MAINTAINABILITY-HORROR@@@
743 	   Implementation details made public.
744 	*/
745     SwNodes      & GetNodes()       { return *m_pNodes; }
746     SwNodes const& GetNodes() const { return *m_pNodes; }
747 
748     /** IInterface
749     */
750     virtual sal_Int32 acquire();
751     virtual sal_Int32 release();
752     virtual sal_Int32 getReferenceCount() const;
753 
754     /** IDocumentSettingAccess
755     */
756     virtual bool get(/*[in]*/ DocumentSettingId id) const;
757     virtual void set(/*[in]*/ DocumentSettingId id, /*[in]*/ bool value);
758     virtual const com::sun::star::i18n::ForbiddenCharacters* getForbiddenCharacters(/*[in]*/ sal_uInt16 nLang, /*[in]*/ bool bLocaleData ) const;
759     virtual void setForbiddenCharacters(/*[in]*/ sal_uInt16 nLang, /*[in]*/ const com::sun::star::i18n::ForbiddenCharacters& rForbiddenCharacters );
760     virtual vos::ORef<SvxForbiddenCharactersTable>& getForbiddenCharacterTable();
761     virtual const vos::ORef<SvxForbiddenCharactersTable>& getForbiddenCharacterTable() const;
762     virtual sal_uInt16 getLinkUpdateMode( /*[in]*/bool bGlobalSettings ) const;
763     virtual void setLinkUpdateMode( /*[in]*/ sal_uInt16 nMode );
764     virtual SwFldUpdateFlags getFieldUpdateFlags( /*[in]*/bool bGlobalSettings ) const;
765     virtual void setFieldUpdateFlags( /*[in]*/ SwFldUpdateFlags eMode );
766     virtual SwCharCompressType getCharacterCompressionType() const;
767     virtual void setCharacterCompressionType( /*[in]*/SwCharCompressType nType );
768 
769     /** IDocumentDeviceAccess
770     */
771     virtual SfxPrinter* getPrinter(/*[in]*/ bool bCreate ) const;
772     virtual void setPrinter(/*[in]*/ SfxPrinter* pP,/*[in]*/ bool bDeleteOld,/*[in]*/ bool bCallPrtDataChanged );
773     virtual VirtualDevice* getVirtualDevice(/*[in]*/ bool bCreate ) const;
774     virtual void setVirtualDevice(/*[in]*/ VirtualDevice* pVd,/*[in]*/ bool bDeleteOld, /*[in]*/ bool bCallVirDevDataChanged );
775     virtual OutputDevice* getReferenceDevice(/*[in]*/ bool bCreate ) const;
776     virtual void setReferenceDeviceType(/*[in]*/ bool bNewVirtual,/*[in]*/ bool bNewHiRes );
777     virtual const JobSetup* getJobsetup() const;
778     virtual void setJobsetup(/*[in]*/ const JobSetup& rJobSetup );
779     virtual const SwPrintData & getPrintData() const;
780     virtual void setPrintData(/*[in]*/ const SwPrintData& rPrtData);
781 
782     /** IDocumentMarkAccess
783     */
784     IDocumentMarkAccess* getIDocumentMarkAccess();
785     const IDocumentMarkAccess* getIDocumentMarkAccess() const;
786 
787     /** IDocumentRedlineAccess
788     */
789     virtual RedlineMode_t GetRedlineMode() const;
790 	virtual void SetRedlineMode_intern(/*[in]*/RedlineMode_t eMode);
791 	virtual void SetRedlineMode(/*[in]*/RedlineMode_t eMode);
792 	virtual bool IsRedlineOn() const;
793 	virtual bool IsIgnoreRedline() const;
794     virtual bool IsInRedlines(const SwNode& rNode) const;
795 	virtual const SwRedlineTbl& GetRedlineTbl() const;
796 	virtual bool AppendRedline(/*[in]*/SwRedline* pPtr, /*[in]*/bool bCallDelete);
797 	virtual bool SplitRedline(const SwPaM& rPam);
798 	virtual bool DeleteRedline(/*[in]*/const SwPaM& rPam, /*[in]*/bool bSaveInUndo, /*[in]*/sal_uInt16 nDelType);
799 	virtual bool DeleteRedline(/*[in]*/const SwStartNode& rSection, /*[in]*/bool bSaveInUndo, /*[in]*/sal_uInt16 nDelType);
800     virtual sal_uInt16 GetRedlinePos(/*[in]*/const SwNode& rNode, /*[in]*/sal_uInt16 nType) const;
801 	virtual void CompressRedlines();
802     virtual const SwRedline* GetRedline(/*[in]*/const SwPosition& rPos, /*[in]*/sal_uInt16* pFndPos) const;
803 	virtual bool IsRedlineMove() const;
804 	virtual void SetRedlineMove(/*[in]*/bool bFlag);
805 	virtual bool AcceptRedline(/*[in]*/sal_uInt16 nPos, /*[in]*/bool bCallDelete);
806     virtual bool AcceptRedline(/*[in]*/const SwPaM& rPam, /*[in]*/bool bCallDelete);
807 	virtual bool RejectRedline(/*[in]*/sal_uInt16 nPos, /*[in]*/bool bCallDelete);
808     virtual bool RejectRedline(/*[in]*/const SwPaM& rPam, /*[in]*/bool bCallDelete);
809     virtual const SwRedline* SelNextRedline(/*[in]*/SwPaM& rPam) const;
810 	virtual const SwRedline* SelPrevRedline(/*[in]*/SwPaM& rPam) const;
811 	virtual void UpdateRedlineAttr();
812     virtual sal_uInt16 GetRedlineAuthor();
813 	virtual sal_uInt16 InsertRedlineAuthor(const String& rAuthor);
814 	virtual bool SetRedlineComment(/*[in]*/const SwPaM& rPam, /*[in]*/const String& rComment);
815 	virtual const ::com::sun::star::uno::Sequence <sal_Int8>& GetRedlinePassword() const;
816 	virtual void SetRedlinePassword(/*[in]*/const ::com::sun::star::uno::Sequence <sal_Int8>& rNewPassword);
817 
818     /** IDocumentUndoRedo
819     */
820     IDocumentUndoRedo      & GetIDocumentUndoRedo();
821     IDocumentUndoRedo const& GetIDocumentUndoRedo() const;
822 
823     /** IDocumentLinksAdministration
824     */
825     virtual bool IsVisibleLinks() const;
826 	virtual void SetVisibleLinks(bool bFlag);
827     virtual sfx2::LinkManager& GetLinkManager();
828 	virtual const sfx2::LinkManager& GetLinkManager() const;
829     virtual void UpdateLinks(sal_Bool bUI);
830 	virtual bool GetData(const String& rItem, const String& rMimeType, ::com::sun::star::uno::Any& rValue) const;
831 	virtual bool SetData(const String& rItem, const String& rMimeType, const ::com::sun::star::uno::Any& rValue);
832     virtual ::sfx2::SvLinkSource* CreateLinkSource(const String& rItem);
833 	virtual bool EmbedAllLinks();
834     virtual void SetLinksUpdated(const bool bNewLinksUpdated);
835     virtual bool LinksUpdated() const;
836 
837     /** IDocumentFieldsAccess
838     */
839     virtual const SwFldTypes *GetFldTypes() const;
840 	virtual SwFieldType *InsertFldType(const SwFieldType &);
841 	virtual SwFieldType *GetSysFldType( const sal_uInt16 eWhich ) const;
842 	virtual SwFieldType* GetFldType(sal_uInt16 nResId, const String& rName, bool bDbFieldMatching) const;
843     virtual void RemoveFldType(sal_uInt16 nFld);
844     virtual void UpdateFlds( SfxPoolItem* pNewHt, bool bCloseDB);
845     virtual void InsDeletedFldType(SwFieldType &);
846     virtual bool PutValueToField(const SwPosition & rPos, const com::sun::star::uno::Any& rVal, sal_uInt16 nWhich);
847     virtual bool UpdateFld(SwTxtFld * rDstFmtFld, SwField & rSrcFld, SwMsgPoolItem * pMsgHnt, bool bUpdateTblFlds);
848 	virtual void UpdateRefFlds(SfxPoolItem* pHt);
849     virtual void UpdateTblFlds(SfxPoolItem* pHt);
850     virtual void UpdateExpFlds(SwTxtFld* pFld, bool bUpdateRefFlds);
851     virtual void UpdateUsrFlds();
852     virtual void UpdatePageFlds(SfxPoolItem*);
853     virtual void LockExpFlds();
854     virtual void UnlockExpFlds();
855     virtual bool IsExpFldsLocked() const;
856     virtual SwDocUpdtFld& GetUpdtFlds() const;
857 	virtual bool SetFieldsDirty(bool b, const SwNode* pChk, sal_uLong nLen);
858 	virtual void SetFixFields(bool bOnlyTimeDate, const DateTime* pNewDateTime);
859 	virtual void FldsToCalc(SwCalc& rCalc, sal_uLong nLastNd, sal_uInt16 nLastCnt);
860 	virtual void FldsToCalc(SwCalc& rCalc, const _SetGetExpFld& rToThisFld);
861 	virtual void FldsToExpand(SwHash**& ppTbl, sal_uInt16& rTblSize, const _SetGetExpFld& rToThisFld);
862 	virtual bool IsNewFldLst() const;
863 	virtual void SetNewFldLst( bool bFlag);
864 	virtual void InsDelFldInFldLst(bool bIns, const SwTxtFld& rFld);
865 
866     /** Returns the field at a certain position.
867        @param rPos position to search at
868        @return pointer to field at the given position or NULL in case no field is found
869     */
870     static SwField* GetFieldAtPos(const SwPosition& rPos);
871 
872     /** Returns the field at a certain position.
873        @param rPos position to search at
874        @return pointer to field at the given position or NULL in case no field is found
875     */
876     static SwTxtFld* GetTxtFldAtPos(const SwPosition& rPos);
877 
878     /** IDocumentContentOperations
879     */
880     virtual bool CopyRange(SwPaM&, SwPosition&, const bool bCopyAll) const;
881 	virtual void DeleteSection(SwNode* pNode);
882     virtual bool DeleteRange(SwPaM&);
883 	virtual bool DelFullPara(SwPaM&);
884     // Add optional parameter <bForceJoinNext>, default value <false>
885     // Needed for hiding of deletion redlines
886     virtual bool DeleteAndJoin( SwPaM&,
887                                 const bool bForceJoinNext = false );
888     virtual bool MoveRange(SwPaM&, SwPosition&, SwMoveFlags);
889     virtual bool MoveNodeRange(SwNodeRange&, SwNodeIndex&, SwMoveFlags);
890 	virtual bool MoveAndJoin(SwPaM&, SwPosition&, SwMoveFlags);
891 	virtual bool Overwrite(const SwPaM &rRg, const String& rStr);
892     virtual bool InsertString(const SwPaM &rRg, const String&,
893               const enum InsertFlags nInsertMode = INS_EMPTYEXPAND );
894 	virtual SwFlyFrmFmt* Insert(const SwPaM &rRg, const String& rGrfName, const String& rFltName, const Graphic* pGraphic,
895 						const SfxItemSet* pFlyAttrSet, const SfxItemSet* pGrfAttrSet, SwFrmFmt*);
896 	virtual SwFlyFrmFmt* Insert(const SwPaM& rRg, const GraphicObject& rGrfObj,	const SfxItemSet* pFlyAttrSet,
897 						const SfxItemSet* pGrfAttrSet, SwFrmFmt*);
898     virtual SwDrawFrmFmt* Insert(const SwPaM &rRg, SdrObject& rDrawObj, const SfxItemSet* pFlyAttrSet, SwFrmFmt*);
899     virtual SwFlyFrmFmt* Insert(const SwPaM &rRg, const svt::EmbeddedObjectRef& xObj, const SfxItemSet* pFlyAttrSet,
900 						const SfxItemSet* pGrfAttrSet, SwFrmFmt*);
901 
902     virtual bool InsertPoolItem(
903         const SwPaM &rRg,
904         const SfxPoolItem&,
905         const SetAttrMode nFlags,
906         const bool bExpandCharToPara=false);
907 
908     virtual bool InsertItemSet (const SwPaM &rRg, const SfxItemSet&,
909                                 const SetAttrMode nFlags);
910 	virtual void ReRead(SwPaM&, const String& rGrfName, const String& rFltName, const Graphic* pGraphic, const GraphicObject* pGrfObj);
911     virtual void TransliterateText(const SwPaM& rPaM, utl::TransliterationWrapper&);
912 	virtual SwFlyFrmFmt* InsertOLE(const SwPaM &rRg, const String& rObjName, sal_Int64 nAspect, const SfxItemSet* pFlyAttrSet,
913                            const SfxItemSet* pGrfAttrSet, SwFrmFmt*);
914 	virtual bool SplitNode(const SwPosition &rPos, bool bChkTableStart);
915 	virtual bool AppendTxtNode(SwPosition& rPos);
916         virtual void SetModified(SwPaM &rPaM);
917     virtual bool ReplaceRange(SwPaM& rPam, const String& rNewStr,
918                               const bool bRegExReplace);
919     virtual void RemoveLeadingWhiteSpace(const SwPosition & rPos );
920 
921     /** IDocumentStylePoolAccess
922     */
923     virtual SwTxtFmtColl* GetTxtCollFromPool( sal_uInt16 nId, bool bRegardLanguage = true );
924     virtual SwFmt* GetFmtFromPool( sal_uInt16 nId );
925     virtual SwFrmFmt* GetFrmFmtFromPool( sal_uInt16 nId );
926     virtual SwCharFmt* GetCharFmtFromPool( sal_uInt16 nId );
927     virtual SwPageDesc* GetPageDescFromPool( sal_uInt16 nId, bool bRegardLanguage = true );
928     virtual SwNumRule* GetNumRuleFromPool( sal_uInt16 nId );
929     virtual bool IsPoolTxtCollUsed( sal_uInt16 nId ) const;
930     virtual bool IsPoolFmtUsed( sal_uInt16 nId ) const;
931     virtual bool IsPoolPageDescUsed( sal_uInt16 nId ) const;
932 
933     /** IDocumentLineNumberAccess
934     */
935     virtual const SwLineNumberInfo& GetLineNumberInfo() const;
936     virtual void SetLineNumberInfo(const SwLineNumberInfo& rInfo);
937 
938 	/** IDocumentStatistics
939 	*/
940 	virtual void DocInfoChgd();
941 	virtual const SwDocStat	&GetDocStat() const;
942 	virtual void SetDocStat(const SwDocStat& rStat);
943 	virtual void UpdateDocStat(SwDocStat& rStat);
944 
945 	/** IDocumentState
946 	*/
947 	virtual void SetModified();
948 	virtual void ResetModified();
949 	virtual bool IsModified() const;
950 	virtual bool IsLoaded() const;
951     virtual bool IsUpdateExpFld() const;
952 	virtual bool IsNewDoc() const;
953     virtual bool IsPageNums() const;
954     virtual void SetPageNums(bool b);
955 	virtual void SetNewDoc(bool b);
956 	virtual void SetUpdateExpFldStat(bool b);
957 	virtual void SetLoaded(bool b);
958 
959     /** IDocumentDrawModelAccess
960     */
961     virtual const SdrModel* GetDrawModel() const;
962     virtual SdrModel* GetDrawModel();
963     virtual SdrLayerID GetHeavenId() const;
964     virtual SdrLayerID GetHellId() const;
965     virtual SdrLayerID GetControlsId() const;
966     virtual SdrLayerID GetInvisibleHeavenId() const;
967     virtual SdrLayerID GetInvisibleHellId() const;
968     virtual SdrLayerID GetInvisibleControlsId() const;
969     virtual void NotifyInvisibleLayers( SdrPageView& _rSdrPageView );
970     virtual bool IsVisibleLayerId( const SdrLayerID& _nLayerId ) const;
971     virtual SdrLayerID GetVisibleLayerIdByInvisibleOne( const SdrLayerID& _nInvisibleLayerId );
972     virtual SdrLayerID GetInvisibleLayerIdByVisibleOne( const SdrLayerID& _nVisibleLayerId );
973     virtual SdrModel* _MakeDrawModel();
974     virtual SdrModel* GetOrCreateDrawModel();
975 
976     /** IDocumentLayoutAccess
977     */
978 	virtual void SetCurrentViewShell( ViewShell* pNew );//swmod 071225
979     virtual SwLayouter* GetLayouter();
980     virtual const SwLayouter* GetLayouter() const;
981     virtual void SetLayouter( SwLayouter* pNew );
982     virtual SwFrmFmt* MakeLayoutFmt( RndStdIds eRequest, const SfxItemSet* pSet );
983     virtual void DelLayoutFmt( SwFrmFmt *pFmt );
984     virtual SwFrmFmt* CopyLayoutFmt( const SwFrmFmt& rSrc, const SwFmtAnchor& rNewAnchor, bool bSetTxtFlyAtt, bool bMakeFrms );
985 	virtual const ViewShell *GetCurrentViewShell() const;	//swmod 080219
986 	virtual ViewShell *GetCurrentViewShell();//swmod 080219 It must be able to communicate to a ViewShell.This is going to be removerd later.
987 	virtual const SwRootFrm *GetCurrentLayout() const;
988 	virtual SwRootFrm *GetCurrentLayout();//swmod 080219
989     virtual bool HasLayout() const;
990 
991     /** IDocumentTimerAccess
992     */
993 	virtual void StartIdling();
994 	virtual void StopIdling();
995 	virtual void BlockIdling();
996 	virtual void UnblockIdling();
997 
998     /** IDocumentChartDataProviderAccess
999     */
1000     virtual SwChartDataProvider * GetChartDataProvider( bool bCreate = false ) const;
1001     virtual void CreateChartInternalDataProviders( const SwTable *pTable );
1002     virtual SwChartLockController_Helper & GetChartControllerHelper();
1003 
1004     /** IDocumentListItems
1005 
1006         OD 2007-10-26 #i83479#
1007     */
1008     virtual void addListItem( const SwNodeNum& rNodeNum );
1009     virtual void removeListItem( const SwNodeNum& rNodeNum );
1010     virtual String getListItemText( const SwNodeNum& rNodeNum,
1011                                     const bool bWithNumber = true,
1012                                     const bool bWithSpacesForLevel = false ) const;
1013     virtual void getListItems( IDocumentListItems::tSortedNodeNumList& orNodeNumList ) const;
1014     virtual void getNumItems( IDocumentListItems::tSortedNodeNumList& orNodeNumList ) const;
1015 
1016     /** IDocumentOutlineNodes
1017 
1018         OD 2007-11-15 #i83479#
1019     */
1020     virtual sal_Int32 getOutlineNodesCount() const;
1021     virtual int getOutlineLevel( const sal_Int32 nIdx ) const;
1022     virtual String getOutlineText( const sal_Int32 nIdx,
1023                                    const bool bWithNumber,
1024                                    const bool bWithSpacesForLevel ) const;
1025     virtual SwTxtNode* getOutlineNode( const sal_Int32 nIdx ) const;
1026     virtual void getOutlineNodes( IDocumentOutlineNodes::tSortedOutlineNodeList& orOutlineNodeList ) const;
1027 
1028     /** IDocumentListsAccess
1029 
1030         OD 2008-03-26 #refactorlists#
1031     */
1032     virtual SwList* createList( String sListId,
1033                                 const String sDefaultListStyleName );
1034     virtual void deleteList( const String sListId );
1035     virtual SwList* getListByName( const String sListId ) const;
1036     virtual SwList* createListForListStyle( const String sListStyleName );
1037     virtual SwList* getListForListStyle( const String sListStyleName ) const;
1038     virtual void deleteListForListStyle( const String sListStyleName );
1039     // --> OD 2008-07-08 #i91400#
1040     virtual void trackChangeOfListStyleName( const String sListStyleName,
1041                                              const String sNewListStyleName );
1042     // <--
1043 
1044     /** IDocumentExternalData */
1045     virtual void setExternalData(::sw::tExternalDataType eType,
1046                                  ::sw::tExternalDataPointer pPayload);
1047     virtual ::sw::tExternalDataPointer getExternalData(::sw::tExternalDataType eType);
1048 
1049 
1050     /** INextInterface here
1051     */
1052 
1053     DECL_STATIC_LINK( SwDoc, BackgroundDone, SvxBrushItem *);
1054     DECL_LINK(CalcFieldValueHdl, EditFieldInfo*);
1055 
1056     /** OLE ???
1057     */
1058     bool IsOLEPrtNotifyPending() const  { return mbOLEPrtNotifyPending; }
1059     inline void SetOLEPrtNotifyPending( bool bSet = true );
1060 	void PrtOLENotify( sal_Bool bAll );	//Alle oder nur Markierte
1061 
1062 #ifdef DBG_UTIL
1063     bool InXMLExport() const            { return mbXMLExport; }
1064     void SetXMLExport( bool bFlag )     { mbXMLExport = bFlag; }
1065 #endif
1066 	//-----IAccessibility2 Implementation 2009
1067 	void SetSelAll( sal_Bool bSel )
1068 	{
1069 		bIsPrepareSelAll = bSel;
1070 	}
1071 	sal_Bool IsPrepareSelAll()  { return bIsPrepareSelAll; }
1072 	void SetPrepareSelAll() { bIsPrepareSelAll = sal_True; }
1073 	//IAccessibility2 Implementation 2009-----
1074 
1075     void SetContainsAtPageObjWithContentAnchor( const bool bFlag )
1076     {
1077         mbContainsAtPageObjWithContentAnchor = bFlag;
1078     }
1079     bool DoesContainAtPageObjWithContentAnchor()
1080     {
1081         return mbContainsAtPageObjWithContentAnchor;
1082     }
1083 
1084 	// liefert zu allen fliegenden Rahmen die Position im Dokument.
1085 	// Wird ein Pam-Pointer uebergeben, muessen die absatzgebundenen
1086 	// FlyFrames von der ::com::sun::star::awt::Selection vollstaendig umschlossen sein
1087 	// ( Start < Pos < End ) !!!
1088 	// (wird fuer die Writer benoetigt)
1089 	SwPosFlyFrms GetAllFlyFmts( const SwPaM* = 0, sal_Bool bDrawAlso = sal_False ) const;
1090 
1091     // wegen swrtf.cxx und define private public, jetzt hier
1092 	SwFlyFrmFmt  *MakeFlyFrmFmt (const String &rFmtName, SwFrmFmt *pDerivedFrom);
1093 	SwDrawFrmFmt *MakeDrawFrmFmt(const String &rFmtName, SwFrmFmt *pDerivedFrom);
1094 
1095     // JP 08.05.98: fuer Flys muss jetzt diese Schnittstelle benutzt
1096 	//				werden. pAnchorPos muss gesetzt sein, wenn keine
1097 	//				Seitenbindung vorliegt UND der ::com::sun::star::chaos::Anchor nicht schon
1098 	//				im FlySet/FrmFmt mit gueltiger CntntPos gesetzt ist
1099     /* #109161# new parameter bCalledFromShell
1100 
1101        sal_True: An existing adjust item at pAnchorPos is propagated to
1102        the content node of the new fly section. That propagation only
1103        takes place if there is no adjust item in the paragraph style
1104        for the new fly section.
1105 
1106        sal_False: no propagation
1107     */
1108 	SwFlyFrmFmt* MakeFlySection( RndStdIds eAnchorType,
1109                                  const SwPosition* pAnchorPos,
1110                                  const SfxItemSet* pSet = 0,
1111                                  SwFrmFmt *pParent = 0,
1112                                  sal_Bool bCalledFromShell = sal_False );
1113 	SwFlyFrmFmt* MakeFlyAndMove( const SwPaM& rPam, const SfxItemSet& rSet,
1114 								const SwSelBoxes* pSelBoxes = 0,
1115 								SwFrmFmt *pParent = 0 );
1116 
1117 	void CopyWithFlyInFly( const SwNodeRange& rRg,
1118                             const xub_StrLen nEndContentIndex,
1119 							const SwNodeIndex& rInsPos,
1120 							sal_Bool bMakeNewFrms = sal_True,
1121 							sal_Bool bDelRedlines = sal_True,
1122 							sal_Bool bCopyFlyAtFly = sal_False ) const;
1123 
1124     sal_Bool SetFlyFrmAttr( SwFrmFmt& rFlyFmt, SfxItemSet& rSet );
1125 
1126     sal_Bool SetFrmFmtToFly( SwFrmFmt& rFlyFmt, SwFrmFmt& rNewFmt,
1127 						SfxItemSet* pSet = 0, sal_Bool bKeepOrient = sal_False );
1128     // --> OD 2009-07-20 #i73249#
1129     void SetFlyFrmTitle( SwFlyFrmFmt& rFlyFrmFmt,
1130                          const String& sNewTitle );
1131     void SetFlyFrmDescription( SwFlyFrmFmt& rFlyFrmFmt,
1132                                const String& sNewDescription );
1133     // <--
1134 
1135     /** Footnotes
1136     */
1137 	// Fussnoten Informationen
1138 	const SwFtnInfo& GetFtnInfo() const			{ return *pFtnInfo; }
1139 	void SetFtnInfo(const SwFtnInfo& rInfo);
1140 	const SwEndNoteInfo& GetEndNoteInfo() const { return *pEndNoteInfo; }
1141 	void SetEndNoteInfo(const SwEndNoteInfo& rInfo);
1142 		  SwFtnIdxs& GetFtnIdxs() 		{ return *pFtnIdxs; }
1143 	const SwFtnIdxs& GetFtnIdxs() const { return *pFtnIdxs; }
1144     // change footnotes in area
1145     bool SetCurFtn( const SwPaM& rPam, const String& rNumStr,
1146                     sal_uInt16 nNumber, bool bIsEndNote );
1147 
1148     /** Operations on the content of the document e.g.
1149         spell-checking/hyphenating/word-counting
1150     */
1151     ::com::sun::star::uno::Any
1152 			Spell( SwPaM&, ::com::sun::star::uno::Reference<
1153 							::com::sun::star::linguistic2::XSpellChecker1 > &,
1154                    sal_uInt16* pPageCnt, sal_uInt16* pPageSt, bool bGrammarCheck,
1155                    SwConversionArgs *pConvArgs = 0 ) const;
1156 
1157 	::com::sun::star::uno::Reference<
1158 		::com::sun::star::linguistic2::XHyphenatedWord >
1159 			Hyphenate( SwPaM *pPam, const Point &rCrsrPos,
1160 			  		   sal_uInt16* pPageCnt, sal_uInt16* pPageSt );
1161 
1162     // count words in pam
1163     void CountWords( const SwPaM& rPaM, SwDocStat& rStat ) const;
1164 
1165 
1166     /** ???
1167     */
1168     // Textbaustein Dokument?
1169     void SetGlossDoc( bool bGlssDc = true ) { mbGlossDoc = bGlssDc; }
1170     bool IsInsOnlyTextGlossary() const      { return mbInsOnlyTxtGlssry; }
1171 
1172 	// Abstakt fuellen
1173 	void Summary( SwDoc* pExtDoc, sal_uInt8 nLevel, sal_uInt8 nPara, sal_Bool bImpress );
1174 
1175     void ChangeAuthorityData(const SwAuthEntry* pNewData);
1176 
1177     bool IsInCallModified() const      { return mbInCallModified; }
1178 	sal_Bool IsInHeaderFooter( const SwNodeIndex& rIdx ) const;
1179     short GetTextDirection( const SwPosition& rPos,
1180                             const Point* pPt = 0 ) const;
1181     sal_Bool IsInVerticalText( const SwPosition& rPos,
1182 							   const Point* pPt = 0 ) const;
1183     /** Database ???
1184     */
1185 
1186 	/*	Datenbank &&  DB-Manager */
1187 	void SetNewDBMgr( SwNewDBMgr* pNewMgr )		{ pNewDBMgr = pNewMgr; }
1188 	SwNewDBMgr* GetNewDBMgr() const 			{ return pNewDBMgr; }
1189 	void ChangeDBFields( const SvStringsDtor& rOldNames,
1190 						const String& rNewName );
1191 	void SetInitDBFields(sal_Bool b);
1192 	// Von Feldern verwendete Datenbanken herausfinden
1193 	void GetAllUsedDB( SvStringsDtor& rDBNameList,
1194 					   const SvStringsDtor* pAllDBNames = 0 );
1195 
1196 	void ChgDBData( const SwDBData& rNewData );
1197 	SwDBData GetDBData();
1198 	const SwDBData& GetDBDesc();
1199 	const SwDBData& _GetDBDesc() const { return aDBData; }
1200 
1201     /** Some helper functions
1202     */
1203     String GetUniqueGrfName() const;
1204     String GetUniqueOLEName() const;
1205 	String GetUniqueFrameName() const;
1206 
1207 	std::set<SwRootFrm*> GetAllLayouts();//swmod 080225
1208 
1209 	void SetFlyName( SwFlyFrmFmt& rFmt, const String& rName );
1210 	const SwFlyFrmFmt* FindFlyByName( const String& rName, sal_Int8 nNdTyp = 0 ) const;
1211 
1212 	void GetGrfNms( const SwFlyFrmFmt& rFmt, String* pGrfName,
1213 					String* pFltName ) const;
1214 
1215 	// setze bei allen Flys ohne Namen einen gueltigen (Wird von den Readern
1216 	// nach dem Einlesen gerufen )
1217 	void SetAllUniqueFlyNames();
1218 
1219 		//Zuruecksetzen der Attribute; es werden alle TxtHints und bei
1220 		//vollstaendiger Selektion harte Formatierung (AUTO-Formate) entfernt
1221     // --> OD 2008-11-28 #i96644#
1222     // introduce new optional parameter <bSendDataChangedEvents> in order to
1223     // control, if the side effect "send data changed events" is triggered or not.
1224     void ResetAttrs( const SwPaM &rRg,
1225                      sal_Bool bTxtAttr = sal_True,
1226                      const SvUShortsSort* = 0,
1227                      const bool bSendDataChangedEvents = true );
1228     // <--
1229     void RstTxtAttrs(const SwPaM &rRg, sal_Bool bInclRefToxMark = sal_False );
1230 
1231 		// Setze das Attribut im angegebenen Format. Ist Undo aktiv, wird
1232 		// das alte in die Undo-History aufgenommen
1233 	void SetAttr( const SfxPoolItem&, SwFmt& );
1234 	void SetAttr( const SfxItemSet&, SwFmt& );
1235 
1236     // --> OD 2008-02-12 #newlistlevelattrs#
1237     // method to reset a certain attribute at the given format
1238     void ResetAttrAtFormat( const sal_uInt16 nWhichId,
1239                             SwFmt& rChangedFormat );
1240     // <--
1241 
1242 		// Setze das Attribut als neues default Attribut in diesem Dokument.
1243 		// Ist Undo aktiv, wird das alte in die Undo-History aufgenommen
1244 	void SetDefault( const SfxPoolItem& );
1245 	void SetDefault( const SfxItemSet& );
1246 
1247 	// Erfrage das Default Attribut in diesem Dokument.
1248 	const SfxPoolItem& GetDefault( sal_uInt16 nFmtHint ) const;
1249 	// TextAttribute nicht mehr aufspannen lassen
1250 	sal_Bool DontExpandFmt( const SwPosition& rPos, sal_Bool bFlag = sal_True );
1251 
1252 	/* Formate */
1253 	const SwFrmFmts* GetFrmFmts() const 	{ return pFrmFmtTbl; }
1254 		  SwFrmFmts* GetFrmFmts()			{ return pFrmFmtTbl; }
1255 	const SwCharFmts* GetCharFmts() const	{ return pCharFmtTbl;}
1256 
1257 	/* LayoutFormate (Rahmen, DrawObjecte), mal const mal nicht */
1258 	const SwSpzFrmFmts* GetSpzFrmFmts() const	{ return pSpzFrmFmtTbl; }
1259 		  SwSpzFrmFmts* GetSpzFrmFmts() 		{ return pSpzFrmFmtTbl; }
1260 
1261 	const SwFrmFmt *GetDfltFrmFmt() const	{ return pDfltFrmFmt; }
1262 		  SwFrmFmt *GetDfltFrmFmt() 		{ return pDfltFrmFmt; }
1263 	const SwFrmFmt *GetEmptyPageFmt() const { return pEmptyPageFmt; }
1264 		  SwFrmFmt *GetEmptyPageFmt()		{ return pEmptyPageFmt; }
1265 	const SwFrmFmt *GetColumnContFmt() const{ return pColumnContFmt; }
1266 		  SwFrmFmt *GetColumnContFmt()		{ return pColumnContFmt; }
1267 	const SwCharFmt *GetDfltCharFmt() const { return pDfltCharFmt;}
1268 		  SwCharFmt *GetDfltCharFmt()		{ return pDfltCharFmt;}
1269 
1270     // Returns the interface of the management of (auto)styles
1271     IStyleAccess& GetIStyleAccess() { return *pStyleAccess; }
1272 
1273 	// Remove all language dependencies from all existing formats
1274 	void RemoveAllFmtLanguageDependencies();
1275 
1276 	SwFrmFmt  *MakeFrmFmt(const String &rFmtName, SwFrmFmt *pDerivedFrom,
1277                           sal_Bool bBroadcast = sal_False, sal_Bool bAuto = sal_True);
1278 	void	   DelFrmFmt( SwFrmFmt *pFmt, sal_Bool bBroadcast = sal_False );
1279 	SwFrmFmt* FindFrmFmtByName( const String& rName ) const
1280 		{	return (SwFrmFmt*)FindFmtByName( (SvPtrarr&)*pFrmFmtTbl, rName ); }
1281 
1282     // --> OD 2005-01-13 #i40550#
1283     SwCharFmt *MakeCharFmt(const String &rFmtName, SwCharFmt *pDerivedFrom,
1284                            sal_Bool bBroadcast = sal_False,
1285                            sal_Bool bAuto = sal_True );
1286     // <--
1287 	void	   DelCharFmt(sal_uInt16 nFmt, sal_Bool bBroadcast = sal_False);
1288 	void	   DelCharFmt(SwCharFmt* pFmt, sal_Bool bBroadcast = sal_False);
1289 	SwCharFmt* FindCharFmtByName( const String& rName ) const
1290 		{	return (SwCharFmt*)FindFmtByName( (SvPtrarr&)*pCharFmtTbl, rName ); }
1291 
1292 	/* Formatcollections (Vorlagen) */
1293 	// TXT
1294 	const SwTxtFmtColl* GetDfltTxtFmtColl() const { return pDfltTxtFmtColl; }
1295 	const SwTxtFmtColls *GetTxtFmtColls() const { return pTxtFmtCollTbl; }
1296     // --> OD 2005-01-13 #i40550#
1297     SwTxtFmtColl *MakeTxtFmtColl( const String &rFmtName,
1298 								  SwTxtFmtColl *pDerivedFrom,
1299                                   sal_Bool bBroadcast = sal_False,
1300                                   sal_Bool bAuto = sal_True );
1301     // <--
1302 	SwConditionTxtFmtColl* MakeCondTxtFmtColl( const String &rFmtName,
1303 											   SwTxtFmtColl *pDerivedFrom,
1304                                                sal_Bool bBroadcast = sal_False);
1305 	void DelTxtFmtColl(sal_uInt16 nFmt, sal_Bool bBroadcast = sal_False);
1306 	void DelTxtFmtColl( SwTxtFmtColl* pColl, sal_Bool bBroadcast = sal_False );
1307     // --> OD 2007-11-06 #i62675#
1308     // Add 4th optional parameter <bResetListAttrs>.
1309     // 'side effect' of <SetTxtFmtColl> with <bReset = true> is that the hard
1310     // attributes of the affected text nodes are cleared, except the break
1311     // attribute, the page description attribute and the list style attribute.
1312     // The new parameter <bResetListAttrs> indicates, if the list attributes
1313     // (list style, restart at and restart with) are cleared as well in case
1314     // that <bReset = true> and the paragraph style has a list style attribute set.
1315     sal_Bool SetTxtFmtColl( const SwPaM &rRg, SwTxtFmtColl *pFmt,
1316                             bool bReset = true,
1317                             bool bResetListAttrs = false );
1318     // <--
1319 	SwTxtFmtColl* FindTxtFmtCollByName( const String& rName ) const
1320 		{	return (SwTxtFmtColl*)FindFmtByName( (SvPtrarr&)*pTxtFmtCollTbl, rName ); }
1321 
1322     void ChkCondColls();
1323 
1324 		// GRF
1325 	const SwGrfFmtColl* GetDfltGrfFmtColl() const	{ return pDfltGrfFmtColl; }
1326 	const SwGrfFmtColls *GetGrfFmtColls() const		{ return pGrfFmtCollTbl; }
1327 	SwGrfFmtColl *MakeGrfFmtColl(const String &rFmtName,
1328 									SwGrfFmtColl *pDerivedFrom);
1329 	SwGrfFmtColl* FindGrfFmtCollByName( const String& rName ) const
1330 		{	return (SwGrfFmtColl*)FindFmtByName( (SvPtrarr&)*pGrfFmtCollTbl, rName ); }
1331 
1332 		// Tabellen-Formate
1333 	const SwFrmFmts* GetTblFrmFmts() const	{ return pTblFrmFmtTbl; }
1334 		  SwFrmFmts* GetTblFrmFmts()		{ return pTblFrmFmtTbl; }
1335 	sal_uInt16 GetTblFrmFmtCount( sal_Bool bUsed ) const;
1336 	SwFrmFmt& GetTblFrmFmt(sal_uInt16 nFmt, sal_Bool bUsed ) const;
1337 	SwTableFmt* MakeTblFrmFmt(const String &rFmtName, SwFrmFmt *pDerivedFrom);
1338 	void	    DelTblFrmFmt( SwTableFmt* pFmt );
1339 	SwTableFmt* FindTblFmtByName( const String& rName, sal_Bool bAll = sal_False ) const;
1340 
1341 	//Rahmenzugriff
1342 	//iterieren ueber Flys - fuer Basic-Collections
1343 	sal_uInt16 GetFlyCount( FlyCntType eType = FLYCNTTYPE_ALL) const;
1344 	SwFrmFmt* GetFlyNum(sal_uInt16 nIdx, FlyCntType eType = FLYCNTTYPE_ALL);
1345 
1346 
1347 	// kopiere die Formate in die eigenen Arrays und returne diese
1348 	SwFrmFmt  *CopyFrmFmt ( const SwFrmFmt& );
1349 	SwCharFmt *CopyCharFmt( const SwCharFmt& );
1350 	SwTxtFmtColl* CopyTxtColl( const SwTxtFmtColl& rColl );
1351 	SwGrfFmtColl* CopyGrfColl( const SwGrfFmtColl& rColl );
1352 
1353 		// ersetze alle Formate mit denen aus rSource
1354 	void ReplaceStyles( SwDoc& rSource );
1355 
1356 	// erfrage ob die Absatz-/Zeichen-/Rahmen-/Seiten - Vorlage benutzt wird
1357 	sal_Bool IsUsed( const SwModify& ) const;
1358 	sal_Bool IsUsed( const SwNumRule& ) const;
1359 
1360 		// setze den Namen der neu geladenen Dokument-Vorlage
1361 	sal_uInt16 SetDocPattern( const String& rPatternName );
1362         // gebe den Dok-VorlagenNamen zurueck. !!! Kann auch 0 sein !!!
1363 	String* GetDocPattern( sal_uInt16 nPos ) const { return aPatternNms[nPos]; }
1364 
1365 		// Loesche alle nicht referenzierten FeldTypen
1366 	void GCFieldTypes();				// impl. in docfld.cxx
1367 
1368 		// akt. Dokument mit Textbausteindokument verbinden/erfragen
1369 	void SetGlossaryDoc( SwDoc* pDoc ) { pGlossaryDoc = pDoc; }
1370 
1371 	// travel over PaM Ring
1372 	sal_Bool InsertGlossary( SwTextBlocks& rBlock, const String& rEntry,
1373 						SwPaM& rPaM, SwCrsrShell* pShell = 0);
1374 
1375     // get the set of printable pages for the XRenderable API by
1376     // evaluating the respective settings (see implementation)
1377     void CalculatePagesForPrinting( const SwRootFrm& rLayout, SwRenderData &rData, const SwPrintUIOptions &rOptions, bool bIsPDFExport,
1378             sal_Int32 nDocPageCount );
1379     void UpdatePagesForPrintingWithPostItData( SwRenderData &rData, const SwPrintUIOptions &rOptions, bool bIsPDFExport,
1380             sal_Int32 nDocPageCount );
1381     void CalculatePagePairsForProspectPrinting( const SwRootFrm& rLayout, SwRenderData &rData, const SwPrintUIOptions &rOptions,
1382             sal_Int32 nDocPageCount );
1383 
1384 		//PageDescriptor-Schnittstelle
1385 	sal_uInt16 GetPageDescCnt() const { return aPageDescs.Count(); }
1386 	const SwPageDesc& GetPageDesc( const sal_uInt16 i ) const { return *aPageDescs[i]; }
1387 	SwPageDesc* FindPageDescByName( const String& rName,
1388 									sal_uInt16* pPos = 0 ) const;
1389 
1390 		// kopiere den gesamten PageDesc - ueber Dokumentgrenzen und "tief"!
1391 		// optional kann das kopieren der PoolFmtId, -HlpId verhindert werden
1392 	void CopyPageDesc( const SwPageDesc& rSrcDesc, SwPageDesc& rDstDesc,
1393 						sal_Bool bCopyPoolIds = sal_True );
1394 
1395 		// kopiere die Kopzeile (mit dem Inhalt!) aus dem SrcFmt
1396 		// ins DestFmt ( auch ueber Doc grenzen hinaus!)
1397 	void CopyHeader( const SwFrmFmt& rSrcFmt, SwFrmFmt& rDestFmt )
1398         { CopyPageDescHeaderFooterImpl( true, rSrcFmt, rDestFmt ); }
1399 		// kopiere die Fusszeile (mit dem Inhalt!) aus dem SrcFmt
1400 		// ins DestFmt ( auch ueber Doc grenzen hinaus!)
1401 	void CopyFooter( const SwFrmFmt& rSrcFmt, SwFrmFmt& rDestFmt )
1402         { CopyPageDescHeaderFooterImpl( false, rSrcFmt, rDestFmt ); }
1403 
1404 		//fuer Reader
1405 
1406     SwPageDesc * GetPageDesc( const String & rName );
1407 	SwPageDesc& _GetPageDesc( sal_uInt16 i ) const { return *aPageDescs[i]; }
1408 	void ChgPageDesc( const String & rName, const SwPageDesc& );
1409 	void ChgPageDesc( sal_uInt16 i, const SwPageDesc& );
1410     sal_Bool FindPageDesc( const String & rName, sal_uInt16 * pFound );
1411     // -> #116530#
1412     void DelPageDesc( const String & rName, sal_Bool bBroadcast = sal_False);
1413 	void DelPageDesc( sal_uInt16 i, sal_Bool bBroadcast = sal_False );
1414     // <- #116530#
1415     void PreDelPageDesc(SwPageDesc * pDel); // #i7983#
1416     // -> #116530#
1417 	sal_uInt16 MakePageDesc( const String &rName, const SwPageDesc* pCpy = 0,
1418                              sal_Bool bRegardLanguage = sal_True,
1419                              sal_Bool bBroadcast = sal_False);
1420     void BroadcastStyleOperation(String rName, SfxStyleFamily eFamily,
1421                                  sal_uInt16 nOp);
1422     // <- #116530#
1423 
1424 
1425     // --> FME 2005-03-16 #i44963# The html import sometimes overwrites the
1426     // page sizes set in the page descriptions. This function is used to
1427     // correct this.
1428     void CheckDefaultPageFmt();
1429     // <--
1430 
1431 		// Methoden fuer die Verzeichnisse:
1432 		// - Verzeichnismarke einfuegen loeschen travel
1433 	sal_uInt16 GetCurTOXMark( const SwPosition& rPos, SwTOXMarks& ) const;
1434     void DeleteTOXMark( const SwTOXMark* pTOXMark );
1435 	const SwTOXMark& GotoTOXMark( const SwTOXMark& rCurTOXMark,
1436 								SwTOXSearch eDir, sal_Bool bInReadOnly );
1437 
1438 		// - Verzeichnis einfuegen, und bei Bedarf erneuern
1439 	const SwTOXBaseSection* InsertTableOf( const SwPosition& rPos,
1440 											const SwTOXBase& rTOX,
1441 											const SfxItemSet* pSet = 0,
1442 											sal_Bool bExpand = sal_False );
1443 	const SwTOXBaseSection* InsertTableOf( sal_uLong nSttNd, sal_uLong nEndNd,
1444 											const SwTOXBase& rTOX,
1445 											const SfxItemSet* pSet = 0											);
1446 	const SwTOXBase* GetCurTOX( const SwPosition& rPos ) const;
1447 	const SwAttrSet& GetTOXBaseAttrSet(const SwTOXBase& rTOX) const;
1448 
1449 	sal_Bool DeleteTOX( const SwTOXBase& rTOXBase, sal_Bool bDelNodes = sal_False );
1450 	String GetUniqueTOXBaseName( const SwTOXType& rType,
1451 								const String* pChkStr = 0 ) const;
1452 
1453 	sal_Bool SetTOXBaseName(const SwTOXBase& rTOXBase, const String& rName);
1454 	void SetTOXBaseProtection(const SwTOXBase& rTOXBase, sal_Bool bProtect);
1455 
1456 	// nach einlesen einer Datei alle Verzeichnisse updaten
1457     void SetUpdateTOX( bool bFlag = true )     { mbUpdateTOX = bFlag; }
1458     bool IsUpdateTOX() const                   { return mbUpdateTOX; }
1459 
1460 	const String&	GetTOIAutoMarkURL() const {return sTOIAutoMarkURL;}
1461 	void			SetTOIAutoMarkURL(const String& rSet)  {sTOIAutoMarkURL = rSet;}
1462 	void 			ApplyAutoMark();
1463 
1464     bool IsInReading() const                    { return mbInReading; }
1465     void SetInReading( bool bNew )              { mbInReading = bNew; }
1466 
1467     bool IsClipBoard() const                    { return mbClipBoard; }
1468     // N.B.: must be called right after constructor! (@see GetXmlIdRegistry)
1469     void SetClipBoard( bool bNew )              { mbClipBoard = bNew; }
1470 
1471     bool IsColumnSelection() const              { return mbColumnSelection; }
1472     void SetColumnSelection( bool bNew )        { mbColumnSelection = bNew; }
1473 
1474     bool IsInXMLImport() const { return mbInXMLImport; }
1475     void SetInXMLImport( bool bNew ) { mbInXMLImport = bNew; }
1476 
1477 	// - Verzeichnis-Typen verwalten
1478 	sal_uInt16 GetTOXTypeCount( TOXTypes eTyp ) const;
1479 	const SwTOXType* GetTOXType( TOXTypes eTyp, sal_uInt16 nId ) const;
1480 	sal_Bool DeleteTOXType( TOXTypes eTyp, sal_uInt16 nId );
1481 	const SwTOXType* InsertTOXType( const SwTOXType& rTyp );
1482 	const SwTOXTypes& GetTOXTypes() const { return *pTOXTypes; }
1483 
1484 	const SwTOXBase* 	GetDefaultTOXBase( TOXTypes eTyp, sal_Bool bCreate = sal_False );
1485 	void				SetDefaultTOXBase(const SwTOXBase& rBase);
1486 
1487 	// - Schluessel fuer die Indexverwaltung
1488 	sal_uInt16 GetTOIKeys( SwTOIKeyType eTyp, SvStringsSort& rArr ) const;
1489 
1490 	// Sortieren Tabellen Text
1491 	sal_Bool SortTbl(const SwSelBoxes& rBoxes, const SwSortOptions&);
1492 	sal_Bool SortText(const SwPaM&, const SwSortOptions&);
1493 
1494 		// korrigiere die im Dokument angemeldeten SwPosition-Objecte,
1495 		// wie z.B. die ::com::sun::star::text::Bookmarks oder die Verzeichnisse.
1496 		// JP 22.06.95: ist bMoveCrsr gesetzt, verschiebe auch die Crsr
1497 
1498 		// Setzt alles in rOldNode auf rNewPos + Offset
1499 	void CorrAbs( const SwNodeIndex& rOldNode, const SwPosition& rNewPos,
1500 					const xub_StrLen nOffset = 0, sal_Bool bMoveCrsr = sal_False );
1501 		// Setzt alles im Bereich von [rStartNode, rEndNode] nach rNewPos
1502 	void CorrAbs( const SwNodeIndex& rStartNode, const SwNodeIndex& rEndNode,
1503 					const SwPosition& rNewPos, sal_Bool bMoveCrsr = sal_False );
1504 		// Setzt alles im Bereich von rRange nach rNewPos
1505 	void CorrAbs( const SwPaM& rRange, const SwPosition& rNewPos,
1506 					sal_Bool bMoveCrsr = sal_False );
1507 		// Setzt alles in rOldNode auf relative Pos
1508 	void CorrRel( const SwNodeIndex& rOldNode, const SwPosition& rNewPos,
1509 					const xub_StrLen nOffset = 0, sal_Bool bMoveCrsr = sal_False );
1510 
1511 		// GliederungsRegeln erfragen / setzen
1512     // --> OD 2005-11-02 #i51089 - TUNING#
1513     inline SwNumRule* GetOutlineNumRule() const
1514     {
1515         return pOutlineRule;
1516     }
1517     // <--
1518 	void SetOutlineNumRule( const SwNumRule& rRule );
1519     void PropagateOutlineRule();
1520 
1521 	// Gliederung - hoch-/runterstufen
1522 	sal_Bool OutlineUpDown( const SwPaM& rPam, short nOffset = 1 );
1523 	// Gliederung - hoch-/runtermoven
1524 	sal_Bool MoveOutlinePara( const SwPaM& rPam, short nOffset = 1);
1525 		// zu diesem Gliederungspunkt
1526 	sal_Bool GotoOutline( SwPosition& rPos, const String& rName ) const;
1527 	// die Aenderungen an den Gliederungsvorlagen in die OutlineRule uebernehmen
1528 
1529 		// setzt, wenn noch keine Numerierung, sonst wird geaendert
1530 		// arbeitet mit alten und neuen Regeln, nur Differenzen aktualisieren
1531     // --> OD 2005-02-18 #i42921# - re-use unused 3rd parameter
1532     // --> OD 2008-02-08 #newlistlevelattrs#
1533     // Add optional parameter <bResetIndentAttrs> - default value sal_False.
1534     // If <bResetIndentAttrs> equals true, the indent attributes "before text"
1535     // and "first line indent" are additionally reset at the provided PaM, if
1536     // the list style makes use of the new list level attributes.
1537     // --> OD 2008-03-17 #refactorlists#
1538     // introduce parameters <bCreateNewList> and <sContinuedListId>
1539     // <bCreateNewList> indicates, if a new list is created by applying the
1540     // given list style.
1541     void SetNumRule( const SwPaM&,
1542                      const SwNumRule&,
1543                      const bool bCreateNewList,
1544                      const String sContinuedListId = String(),
1545                      sal_Bool bSetItem = sal_True,
1546                      const bool bResetIndentAttrs = false );
1547     // <--
1548     void SetCounted( const SwPaM&, bool bCounted);
1549 
1550     // --> OD 2009-08-25 #i86492#
1551     // no longer needed.
1552     // SwDoc::SetNumRule( rPaM, rNumRule, false, <ListId>, sal_True, true ) have to be used instead.
1553 //    /**
1554 //       Replace numbering rules in a PaM by another numbering rule.
1555 
1556 //       \param rPaM         PaM to replace the numbering rules in
1557 //       \param rNumRule     numbering rule to replace the present numbering rules
1558 //     */
1559 //    void ReplaceNumRule(const SwPaM & rPaM, const SwNumRule & rNumRule);
1560 
1561     void MakeUniqueNumRules(const SwPaM & rPaM);
1562 
1563 	void SetNumRuleStart( const SwPosition& rPos, sal_Bool bFlag = sal_True );
1564     void SetNodeNumStart( const SwPosition& rPos, sal_uInt16 nStt );
1565 
1566 	SwNumRule* GetCurrNumRule( const SwPosition& rPos ) const;
1567 
1568     const SwNumRuleTbl& GetNumRuleTbl() const { return *pNumRuleTbl; }
1569 
1570     // #i36749#
1571     /**
1572        Add numbering rule to document.
1573 
1574        @param pRule    rule to add
1575     */
1576     void AddNumRule(SwNumRule * pRule);
1577 
1578     // --> OD 2008-02-11 #newlistlevelattrs#
1579     // add optional parameter <eDefaultNumberFormatPositionAndSpaceMode>
1580     sal_uInt16 MakeNumRule( const String &rName,
1581         const SwNumRule* pCpy = 0,
1582         sal_Bool bBroadcast = sal_False,
1583         const SvxNumberFormat::SvxNumPositionAndSpaceMode eDefaultNumberFormatPositionAndSpaceMode =
1584             SvxNumberFormat::LABEL_WIDTH_AND_POSITION );
1585     // <--
1586 	sal_uInt16 FindNumRule( const String& rName ) const;
1587 	SwNumRule* FindNumRulePtr( const String& rName ) const;
1588 
1589 	// loeschen geht nur, wenn die ::com::sun::star::chaos::Rule niemand benutzt!
1590     // #106897#
1591     sal_Bool RenameNumRule(const String & aOldName, const String & aNewName,
1592                            sal_Bool bBroadcast = sal_False);
1593 	sal_Bool DelNumRule( const String& rName, sal_Bool bBroadCast = sal_False );
1594 	String GetUniqueNumRuleName( const String* pChkStr = 0, sal_Bool bAutoNum = sal_True ) const;
1595 
1596 	void UpdateNumRule();	// alle invaliden Updaten
1597     // #106897#
1598 	void ChgNumRuleFmts( const SwNumRule& rRule, const String * pOldName = 0 );
1599 	sal_Bool ReplaceNumRule( const SwPosition& rPos, const String& rOldRule,
1600 						const String& rNewRule );
1601 
1602 		// zum naechsten/vorhergehenden Punkt auf gleicher Ebene
1603 	sal_Bool GotoNextNum( SwPosition&, sal_Bool bOverUpper = sal_True,
1604 						sal_uInt8* pUpper = 0, sal_uInt8* pLower = 0 );
1605 	sal_Bool GotoPrevNum( SwPosition&, sal_Bool bOverUpper = sal_True,
1606 						sal_uInt8* pUpper = 0, sal_uInt8* pLower = 0 );
1607 
1608     // #i23731#
1609     /** Searches for a text node with a numbering rule.
1610 
1611        OD 2005-10-24 #i55391# - add optional parameter <bInvestigateStartNode>
1612        OD 2008-03-18 #refactorlists# - add output parameter <sListId>
1613 
1614        \param rPos         position to start search
1615        \param bForward     - sal_True:  search forward
1616                            - sal_False: search backward
1617 	   \param bNum		   - sal_True:  search for enumeration
1618 		                   - sal_False: search for itemize
1619        \param bOutline     - sal_True:  search for outline numbering rule
1620                            - sal_False: search for non-outline numbering rule
1621        \param nNonEmptyAllowed   number of non-empty paragraphs allowed between
1622                                  rPos and found paragraph
1623 
1624         @param sListId
1625         output parameter - in case a list style is found, <sListId> holds the
1626         list id, to which the text node belongs, which applies the found list style.
1627 
1628         @param bInvestigateStartNode
1629         input parameter - boolean, indicating, if start node, determined by given
1630         start position has to be investigated or not.
1631      */
1632     const SwNumRule * SearchNumRule(const SwPosition & rPos,
1633                                     const bool bForward,
1634                                     const bool bNum,
1635                                     const bool bOutline,
1636                                     int nNonEmptyAllowed,
1637                                     String& sListId,
1638                                     const bool bInvestigateStartNode = false );
1639 
1640 		// Absaetze ohne Numerierung, aber mit Einzuegen
1641 	sal_Bool NoNum( const SwPaM& );
1642 		// Loeschen, Splitten der Aufzaehlungsliste
1643     void DelNumRules( const SwPaM& );
1644 
1645     // Invalidates all numrules
1646     void InvalidateNumRules();
1647 
1648 		// Hoch-/Runterstufen
1649 	sal_Bool NumUpDown( const SwPaM&, sal_Bool bDown = sal_True );
1650 		// Bewegt selektierte Absaetze (nicht nur Numerierungen)
1651 		// entsprechend des Offsets. (negativ: zum Doc-Anf.)
1652 	sal_Bool MoveParagraph( const SwPaM&, long nOffset = 1, sal_Bool bIsOutlMv = sal_False );
1653 		// No-/Numerierung ueber Delete/Backspace ein/abschalten #115901#
1654 	sal_Bool NumOrNoNum( const SwNodeIndex& rIdx, sal_Bool bDel = sal_False);
1655 		// Animation der Grafiken stoppen
1656 	void StopNumRuleAnimations( OutputDevice* );
1657 
1658 		// fuege eine neue Tabelle auf der Position rPos ein. (es
1659 		// wird vor dem Node eingefuegt !!)
1660 		//JP 28.10.96:
1661 		// 	fuer AutoFormat bei der Eingabe: dann muessen die Spalten
1662 		//	auf die vordefinierten Breite gesetzt werden. Im Array stehen die
1663 		// 	Positionen der Spalten!! (nicht deren Breite!)
1664     /* #109161# new parameter bCalledFromShell:
1665 
1666        sal_True: called from shell -> propagate existing adjust item at
1667        rPos to every new cell. A existing adjust item in the table
1668        heading or table contents paragraph style prevent that
1669        propagation.
1670 
1671        sal_False: do not propagate
1672     */
1673     const SwTable* InsertTable( const SwInsertTableOptions& rInsTblOpts,  // HEADLINE_NO_BORDER
1674                                 const SwPosition& rPos, sal_uInt16 nRows,
1675                                 sal_uInt16 nCols, short eAdjust,
1676                                 const SwTableAutoFmt* pTAFmt = 0,
1677                                 const SvUShorts* pColArr = 0,
1678                                 sal_Bool bCalledFromShell = sal_False,
1679                                 sal_Bool bNewModel = sal_True );
1680 
1681     // steht der Index in einer Tabelle, dann returne den TableNode sonst 0
1682 				 SwTableNode* IsIdxInTbl( const SwNodeIndex& rIdx );
1683 	inline const SwTableNode* IsIdxInTbl( const SwNodeIndex& rIdx ) const;
1684 
1685 		// erzeuge aus dem makierten Bereich eine ausgeglichene Tabelle
1686     const SwTable* TextToTable( const SwInsertTableOptions& rInsTblOpts, // HEADLINE_NO_BORDER,
1687                                 const SwPaM& rRange, sal_Unicode cCh,
1688                                 short eAdjust,
1689                                 const SwTableAutoFmt* = 0 );
1690     // text to table conversion - API support
1691     const SwTable* TextToTable( const std::vector< std::vector<SwNodeRange> >& rTableNodes );
1692 		// erzeuge aus der Tabelle wieder normalen Text
1693 	sal_Bool TableToText( const SwTableNode* pTblNd, sal_Unicode cCh );
1694 		// einfuegen von Spalten/Zeilen in der Tabelle
1695 	sal_Bool InsertCol( const SwCursor& rCursor,
1696 					sal_uInt16 nCnt = 1, sal_Bool bBehind = sal_True );
1697 	sal_Bool InsertCol( const SwSelBoxes& rBoxes,
1698 					sal_uInt16 nCnt = 1, sal_Bool bBehind = sal_True );
1699 	sal_Bool InsertRow( const SwCursor& rCursor,
1700 					sal_uInt16 nCnt = 1, sal_Bool bBehind = sal_True );
1701 	sal_Bool InsertRow( const SwSelBoxes& rBoxes,
1702 					sal_uInt16 nCnt = 1, sal_Bool bBehind = sal_True );
1703 		// loeschen von Spalten/Zeilen in der Tabelle
1704 	sal_Bool DeleteRowCol( const SwSelBoxes& rBoxes, bool bColumn = false );
1705 	sal_Bool DeleteRow( const SwCursor& rCursor );
1706 	sal_Bool DeleteCol( const SwCursor& rCursor );
1707 		// teilen / zusammenfassen von Boxen in der Tabelle
1708     sal_Bool SplitTbl( const SwSelBoxes& rBoxes, sal_Bool bVert = sal_True,
1709                        sal_uInt16 nCnt = 1, sal_Bool bSameHeight = sal_False );
1710 		// returnt den enum TableMergeErr
1711 	sal_uInt16 MergeTbl( SwPaM& rPam );
1712 	String GetUniqueTblName() const;
1713 	sal_Bool IsInsTblFormatNum() const;
1714 	sal_Bool IsInsTblChangeNumFormat() const;
1715 	sal_Bool IsInsTblAlignNum() const;
1716 
1717 		// aus der FEShell wg.. Undo und bModified
1718     void GetTabCols( SwTabCols &rFill, const SwCursor* pCrsr,
1719 					const SwCellFrm* pBoxFrm = 0 ) const;
1720 	void SetTabCols( const SwTabCols &rNew, sal_Bool bCurRowOnly,
1721 					const SwCursor* pCrsr, const SwCellFrm* pBoxFrm = 0 );
1722     void GetTabRows( SwTabCols &rFill, const SwCursor* pCrsr,
1723                     const SwCellFrm* pBoxFrm = 0 ) const;
1724     void SetTabRows( const SwTabCols &rNew, sal_Bool bCurColOnly, const SwCursor* pCrsr,
1725                      const SwCellFrm* pBoxFrm = 0 );
1726 
1727 
1728 	// Direktzugriff fuer Uno
1729     void SetTabCols(SwTable& rTab, const SwTabCols &rNew, const SwTabCols &rOld,
1730 									const SwTableBox *pStart, sal_Bool bCurRowOnly);
1731 
1732     void SetRowsToRepeat( SwTable &rTable, sal_uInt16 nSet );
1733 
1734 		// AutoFormat fuer die Tabelle/TabellenSelection
1735 	sal_Bool SetTableAutoFmt( const SwSelBoxes& rBoxes, const SwTableAutoFmt& rNew );
1736 		// Erfrage wie attributiert ist
1737 	sal_Bool GetTableAutoFmt( const SwSelBoxes& rBoxes, SwTableAutoFmt& rGet );
1738 		// setze das InsertDB als Tabelle Undo auf:
1739 	void AppendUndoForInsertFromDB( const SwPaM& rPam, sal_Bool bIsTable );
1740 		// setze die Spalten/Zeilen/ZTellen Breite/Hoehe
1741 	sal_Bool SetColRowWidthHeight( SwTableBox& rAktBox, sal_uInt16 eType,
1742 								SwTwips nAbsDiff, SwTwips nRelDiff );
1743 	SwTableBoxFmt* MakeTableBoxFmt();
1744 	SwTableLineFmt* MakeTableLineFmt();
1745 	// teste ob die Box ein numerischen Wert darstellt und aender dann ggfs.
1746 	// das Format der Box
1747 	void ChkBoxNumFmt( SwTableBox& rAktBox, sal_Bool bCallUpdate );
1748 	void SetTblBoxFormulaAttrs( SwTableBox& rBox, const SfxItemSet& rSet );
1749 	void ClearBoxNumAttrs( const SwNodeIndex& rNode );
1750 
1751 	sal_Bool InsCopyOfTbl( SwPosition& rInsPos, const SwSelBoxes& rBoxes,
1752 						const SwTable* pCpyTbl = 0, sal_Bool bCpyName = sal_False,
1753 						sal_Bool bCorrPos = sal_False );
1754 
1755 	sal_Bool UnProtectCells( const String& rTblName );
1756 	sal_Bool UnProtectCells( const SwSelBoxes& rBoxes );
1757 	sal_Bool UnProtectTbls( const SwPaM& rPam );
1758 	sal_Bool HasTblAnyProtection( const SwPosition* pPos,
1759 							  const String* pTblName = 0,
1760 							  sal_Bool* pFullTblProtection = 0 );
1761 
1762 	// Tabelle an der Position in der GrundLine aufsplitten, sprich eine
1763 	// neue Tabelle erzeugen.
1764 	sal_Bool SplitTable( const SwPosition& rPos, sal_uInt16 eMode = 0,
1765 						sal_Bool bCalcNewSize = sal_False );
1766 	// und die Umkehrung davon. rPos muss in der Tabelle stehen, die bestehen
1767 	// bleibt. Das Flag besagt ob die aktuelle mit der davor oder dahinter
1768 	// stehenden vereint wird.
1769 	sal_Bool MergeTable( const SwPosition& rPos, sal_Bool bWithPrev = sal_True,
1770 						sal_uInt16 nMode = 0 );
1771 
1772 	// Charts der angegebenen Tabelle zum Update bewegen
1773 	void UpdateCharts( const String &rName ) const;
1774 	// update all charts, for that exists any table
1775     void UpdateAllCharts()          { DoUpdateAllCharts( 0 ); }
1776 	// Tabelle wird umbenannt und aktualisiert die Charts
1777 	void SetTableName( SwFrmFmt& rTblFmt, const String &rNewName );
1778 
1779 	// returne zum Namen die im Doc gesetzte Referenz
1780 	const SwFmtRefMark* GetRefMark( const String& rName ) const;
1781 	// returne die RefMark per Index - fuer Uno
1782 	const SwFmtRefMark* GetRefMark( sal_uInt16 nIndex ) const;
1783 	// returne die Namen aller im Doc gesetzten Referenzen.
1784 	// 	Ist der ArrayPointer 0 dann returne nur, ob im Doc. eine RefMark
1785 	//	gesetzt ist
1786 	sal_uInt16 GetRefMarks( SvStringsDtor* = 0 ) const;
1787 
1788 	//Einfuegen einer Beschriftung - falls ein FlyFormat erzeugt wird, so
1789 	// returne dieses.
1790     SwFlyFrmFmt* InsertLabel( const SwLabelType eType, const String &rTxt, const String& rSeparator,
1791                     const String& rNumberingSeparator,
1792 					const sal_Bool bBefore, const sal_uInt16 nId, const sal_uLong nIdx,
1793                     const String& rCharacterStyle,
1794 					const sal_Bool bCpyBrd = sal_True );
1795     SwFlyFrmFmt* InsertDrawLabel(
1796         const String &rTxt, const String& rSeparator, const String& rNumberSeparator,
1797         const sal_uInt16 nId, const String& rCharacterStyle, SdrObject& rObj );
1798 
1799 	// erfrage den Attribut Pool
1800 	const SwAttrPool& GetAttrPool() const	{ return *mpAttrPool; }
1801 		  SwAttrPool& GetAttrPool() 		{ return *mpAttrPool; }
1802 
1803 	// suche ueber das Layout eine EditShell und ggfs. eine ViewShell
1804 	SwEditShell* GetEditShell( ViewShell** ppSh = 0 ) const;
1805     ::sw::IShellCursorSupplier * GetIShellCursorSupplier();
1806 
1807 	// OLE 2.0-Benachrichtung
1808 	inline		 void  SetOle2Link(const Link& rLink) {aOle2Link = rLink;}
1809 	inline const Link& GetOle2Link() const {return aOle2Link;}
1810 
1811     // insert section (the ODF kind of section, not the nodesarray kind)
1812     SwSection * InsertSwSection(SwPaM const& rRange, SwSectionData &,
1813             SwTOXBase const*const pTOXBase = 0,
1814             SfxItemSet const*const pAttr = 0, bool const bUpdate = true);
1815 	sal_uInt16 IsInsRegionAvailable( const SwPaM& rRange,
1816 								const SwNode** ppSttNd = 0 ) const;
1817 	SwSection* GetCurrSection( const SwPosition& rPos ) const;
1818 	SwSectionFmts& GetSections() { return *pSectionFmtTbl; }
1819 	const SwSectionFmts& GetSections() const { return *pSectionFmtTbl; }
1820 	SwSectionFmt *MakeSectionFmt( SwSectionFmt *pDerivedFrom );
1821 	void DelSectionFmt( SwSectionFmt *pFmt, sal_Bool bDelNodes = sal_False );
1822     void UpdateSection(sal_uInt16 const nSect, SwSectionData &,
1823             SfxItemSet const*const = 0, bool const bPreventLinkUpdate = false);
1824 	String GetUniqueSectionName( const String* pChkStr = 0 ) const;
1825 
1826     /* @@@MAINTAINABILITY-HORROR@@@
1827        The model should not have anything to do with a shell.
1828        Unnecessary compile/link time dependency.
1829     */
1830 	// Pointer auf die SfxDocShell vom Doc, kann 0 sein !!!
1831 		  SwDocShell* GetDocShell() 		{ return pDocShell; }
1832 	const SwDocShell* GetDocShell() const	{ return pDocShell; }
1833 	void SetDocShell( SwDocShell* pDSh );
1834 
1835 	void ShareLayout( boost::shared_ptr<SwRootFrm>& rPtr);
1836 
1837 	// in case during copying of embedded object a new shell is created,
1838     // it should be set here and cleaned later
1839     void SetTmpDocShell( SfxObjectShellLock rLock )    { xTmpDocShell = rLock; }
1840     SfxObjectShellLock GetTmpDocShell()    { return xTmpDocShell; }
1841 
1842     // fuer die TextBausteine - diese habe nur ein SvPersist zur
1843     // Verfuegung
1844     SfxObjectShell* GetPersist() const;
1845 
1846 	// Pointer auf den Storage des SfxDocShells, kann 0 sein !!!
1847     ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > GetDocStorage();
1848 
1849 		// abfrage/setze Flag, ob das Dokument im asynchronen Laden ist
1850     bool IsInLoadAsynchron() const             { return mbInLoadAsynchron; }
1851     void SetInLoadAsynchron( bool bFlag )       { mbInLoadAsynchron = bFlag; }
1852 
1853 	// erzeuge um das zu Servende Object eine Selektion
1854 	sal_Bool SelectServerObj( const String& rStr, SwPaM*& rpPam,
1855 							SwNodeRange*& rpRange ) const;
1856 
1857 	// fuer Drag&Move: ( z.B. RefMarks "verschieben" erlauben )
1858     bool IsCopyIsMove() const              { return mbCopyIsMove; }
1859     void SetCopyIsMove( bool bFlag )        { mbCopyIsMove = bFlag; }
1860 
1861 	SwDrawContact* GroupSelection( SdrView& );
1862 	void UnGroupSelection( SdrView& );
1863 	sal_Bool DeleteSelection( SwDrawView& );
1864 
1865 	// Invalidiert OnlineSpell-WrongListen
1866 	void SpellItAgainSam( sal_Bool bInvalid, sal_Bool bOnlyWrong, sal_Bool bSmartTags );
1867 	void InvalidateAutoCompleteFlag();
1868 
1869     // <--
1870 	void SetCalcFieldValueHdl(Outliner* pOutliner);
1871 
1872 	// erfrage ob die ::com::sun::star::util::URL besucht war. Uebers Doc, falls nur ein ::com::sun::star::text::Bookmark
1873 	// angegeben ist. Dann muss der Doc. Name davor gesetzt werden!
1874 	sal_Bool IsVisitedURL( const String& rURL ) const;
1875 
1876 	// speicher die akt. Werte fuer die automatische Aufnahme von Ausnahmen
1877 	// in die Autokorrektur
1878 	void SetAutoCorrExceptWord( SwAutoCorrExceptWord* pNew );
1879 	SwAutoCorrExceptWord* GetAutoCorrExceptWord()		{ return pACEWord; }
1880 
1881 	const SwFmtINetFmt* FindINetAttr( const String& rName ) const;
1882 
1883 	// rufe ins dunkle Basic, mit evt. Return String
1884 	sal_Bool ExecMacro( const SvxMacro& rMacro, String* pRet = 0, SbxArray* pArgs = 0 );
1885 	// rufe ins dunkle Basic/JavaScript
1886 	sal_uInt16 CallEvent( sal_uInt16 nEvent, const SwCallMouseEvent& rCallEvent,
1887 						sal_Bool bChkPtr = sal_False, SbxArray* pArgs = 0,
1888 						const Link* pCallBack = 0 );
1889 
1890 	// linken Rand ueber Objectleiste einstellen (aenhlich dem Stufen von
1891 	// Numerierungen), optional kann man "um" den Offset stufen oder "auf"
1892 	// die Position gestuft werden (bModulus = sal_True)
1893 	void MoveLeftMargin( const SwPaM& rPam, sal_Bool bRight = sal_True,
1894 						sal_Bool bModulus = sal_True );
1895 
1896 	// Numberformatter erfragen
1897 	inline	  	 SvNumberFormatter* GetNumberFormatter( sal_Bool bCreate = sal_True );
1898 	inline const SvNumberFormatter* GetNumberFormatter( sal_Bool bCreate = sal_True ) const;
1899 
1900     bool HasInvisibleContent() const;
1901     /// delete invisible content, like hidden sections and paragraphs
1902     bool RemoveInvisibleContent();
1903     /// restore the invisible content if it's available on the undo stack
1904     bool RestoreInvisibleContent();
1905     // replace fields by text - mailmerge support
1906     sal_Bool ConvertFieldsToText();
1907 
1908 	// erzeuge Anhand der vorgebenen Collection Teildokumente
1909 	// falls keine angegeben ist, nehme die Kapitelvorlage der 1. Ebene
1910 	sal_Bool GenerateGlobalDoc( const String& rPath,
1911 								const SwTxtFmtColl* pSplitColl = 0 );
1912 	sal_Bool GenerateGlobalDoc( const String& rPath, int nOutlineLevel = 0 );	//#outline level,add by zhaojianwei
1913 	sal_Bool GenerateHTMLDoc( const String& rPath,
1914 								const SwTxtFmtColl* pSplitColl = 0 );
1915 	sal_Bool GenerateHTMLDoc( const String& rPath, int nOutlineLevel = 0 );	//#outline level,add by zhaojianwei
1916 
1917 	//  vergleiche zwei Dokument miteinander
1918 	long CompareDoc( const SwDoc& rDoc );
1919 	// merge zweier Dokumente
1920 	long MergeDoc( const SwDoc& rDoc );
1921 	// setze Kommentar-Text fuers Redline, das dann per AppendRedline
1922 	// hereinkommt. Wird vom Autoformat benutzt. 0-Pointer setzt den Modus
1923 	// wieder zurueck. Die SequenceNummer ist fuers UI-seitige zusammen-
1924 	// fassen von Redlines.
1925 	void SetAutoFmtRedlineComment( const String* pTxt, sal_uInt16 nSeqNo = 0 );
1926 
1927     bool IsAutoFmtRedline() const           { return mbIsAutoFmtRedline; }
1928     void SetAutoFmtRedline( bool bFlag )    { mbIsAutoFmtRedline = bFlag; }
1929 
1930 	// fuer AutoFormat: mit Undo/Redlining - Behandlung
1931 	void SetTxtFmtCollByAutoFmt( const SwPosition& rPos, sal_uInt16 nPoolId,
1932 								const SfxItemSet* pSet = 0 );
1933 	void SetFmtItemByAutoFmt( const SwPaM& rPam, const SfxItemSet& );
1934 
1935 	// !!!NUR fuer die SW-Textblocks!! beachtet kein LAYOUT!!!
1936 	void ClearDoc(); 		// loescht den gesamten Inhalt.
1937 
1938 	// erfrage / setze die Daten fuer die PagePreView
1939 	const SwPagePreViewPrtData* GetPreViewPrtData() const { return pPgPViewPrtData; }
1940 	// wenn der Pointer == 0 ist, dann wird im Doc der Pointer zerstoert,
1941 	// ansonsten wird das Object kopiert.
1942 	// Der Pointer geht NICHT in den Besitz des Doc's!!
1943 	void SetPreViewPrtData( const SwPagePreViewPrtData* pData );
1944 
1945 	// update all modified OLE-Objects. The modification is called over the
1946 	// StarOne - Interface				--> Bug 67026
1947 	void SetOLEObjModified()
1948 	{	if( GetCurrentViewShell() ) aOLEModifiedTimer.Start(); }	//swmod 071107//swmod 071225
1949 
1950 	// -------------------- Uno - Schnittstellen ---------------------------
1951 	const SwUnoCrsrTbl& GetUnoCrsrTbl() const 		{ return *pUnoCrsrTbl; }
1952 	SwUnoCrsr* CreateUnoCrsr( const SwPosition& rPos, sal_Bool bTblCrsr = sal_False );
1953 	// -------------------- Uno - Schnittstellen ---------------------------
1954 
1955 	// -------------------- FeShell - Schnittstellen -----------------------
1956 	// !!!!! diese gehen immer davon aus, das ein Layout existiert  !!!!
1957     sal_Bool ChgAnchor( const SdrMarkList& _rMrkList,
1958                         RndStdIds _eAnchorType,
1959                         const sal_Bool _bSameOnly,
1960                         const sal_Bool _bPosCorr );
1961 
1962 	void SetRowHeight( const SwCursor& rCursor, const SwFmtFrmSize &rNew );
1963 	void GetRowHeight( const SwCursor& rCursor, SwFmtFrmSize *& rpSz ) const;
1964     void SetRowSplit( const SwCursor& rCursor, const SwFmtRowSplit &rNew );
1965     void GetRowSplit( const SwCursor& rCursor, SwFmtRowSplit *& rpSz ) const;
1966 	sal_Bool BalanceRowHeight( const SwCursor& rCursor, sal_Bool bTstOnly = sal_True );
1967 	void SetRowBackground( const SwCursor& rCursor, const SvxBrushItem &rNew );
1968 	sal_Bool GetRowBackground( const SwCursor& rCursor, SvxBrushItem &rToFill ) const;
1969 	void SetTabBorders( const SwCursor& rCursor, const SfxItemSet& rSet );
1970 	void SetTabLineStyle( const SwCursor& rCursor,
1971 						  const Color* pColor, sal_Bool bSetLine,
1972 						  const SvxBorderLine* pBorderLine );
1973 	void GetTabBorders( const SwCursor& rCursor, SfxItemSet& rSet ) const;
1974 	void SetBoxAttr( const SwCursor& rCursor, const SfxPoolItem &rNew );
1975     sal_Bool GetBoxAttr( const SwCursor& rCursor, SfxPoolItem &rToFill ) const;
1976     void SetBoxAlign( const SwCursor& rCursor, sal_uInt16 nAlign );
1977 	sal_uInt16 GetBoxAlign( const SwCursor& rCursor ) const;
1978 	void AdjustCellWidth( const SwCursor& rCursor, sal_Bool bBalance = sal_False );
1979 
1980 	int Chainable( const SwFrmFmt &rSource, const SwFrmFmt &rDest );
1981 	int Chain( SwFrmFmt &rSource, const SwFrmFmt &rDest );
1982 	void Unchain( SwFrmFmt &rFmt );
1983 
1984 	// fuers Copy/Move aus der FrmShell
1985 	SdrObject* CloneSdrObj( const SdrObject&, sal_Bool bMoveWithinDoc = sal_False,
1986 							sal_Bool bInsInPage = sal_True );
1987 
1988 	//
1989 	// -------------------- FeShell - Schnittstellen Ende ------------------
1990 
1991 
1992 	// Schnittstelle fuer die TextInputDaten - ( fuer die Texteingabe
1993 	// von japanischen/chinesischen Zeichen)
1994 	SwExtTextInput* CreateExtTextInput( const SwPaM& rPam );
1995 	void DeleteExtTextInput( SwExtTextInput* pDel );
1996 	SwExtTextInput* GetExtTextInput( const SwNode& rNd,
1997 								xub_StrLen nCntntPos = STRING_NOTFOUND) const;
1998 	SwExtTextInput* GetExtTextInput() const;
1999 
2000 	// Schnistelle fuer den Zugriff auf die AutoComplete-Liste
2001 	static SwAutoCompleteWord& GetAutoCompleteWords() { return *pACmpltWords; }
2002 
2003     bool ContainsMSVBasic() const          { return mbContains_MSVBasic; }
2004     void SetContainsMSVBasic( bool bFlag )  { mbContains_MSVBasic = bFlag; }
2005 
2006     // Interface for the list of Ruby - texts/attributes
2007 	sal_uInt16 FillRubyList( const SwPaM& rPam, SwRubyList& rList,
2008 						sal_uInt16 nMode );
2009 	sal_uInt16 SetRubyList( const SwPaM& rPam, const SwRubyList& rList,
2010 						sal_uInt16 nMode );
2011 
2012     void ReadLayoutCache( SvStream& rStream );
2013     void WriteLayoutCache( SvStream& rStream );
2014     SwLayoutCache* GetLayoutCache() const { return pLayoutCache; }
2015 
2016     /** Checks if any of the text node contains hidden characters.
2017         Used for optimization. Changing the view option 'view hidden text'
2018         has to trigger a reformatting only if some of the text is hidden.
2019     */
2020     bool ContainsHiddenChars() const;
2021 
2022 	// call back for API wrapper
2023 	SwModify*	GetUnoCallBack() const;
2024 
2025     IGrammarContact* getGrammarContact() const { return mpGrammarContact; }
2026 
2027     // -> #i27615#
2028     /** Marks/Unmarks a list level of a certain list
2029 
2030         OD 2008-04-02 #refactorlists#
2031         levels of a certain lists are marked now
2032 
2033         @param sListId    list Id of the list whose level has to be marked/unmarked
2034         @param nListLevel level to mark
2035         @param bValue     - sal_True  mark the level
2036                           - sal_False unmark the level
2037     */
2038     void MarkListLevel( const String& sListId,
2039                         const int nListLevel,
2040                         const sal_Bool bValue );
2041 
2042     /** Marks/Unmarks a list level of a certain list
2043 
2044         OD 2008-04-02 #refactorlists#
2045         levels of a certain lists are marked now
2046 
2047         @param rList      list whose level has to be marked/unmarked
2048         @param nListLevel level to mark
2049         @param bValue     - sal_True  mark the level
2050                           - sal_False unmark the level
2051      */
2052     void MarkListLevel( SwList& rList,
2053                         const int nListLevel,
2054                         const sal_Bool bValue );
2055     // <- #i27615#
2056 
2057     // Change a format undoable.
2058     void ChgFmt(SwFmt & rFmt, const SfxItemSet & rSet);
2059 
2060     void RenameFmt(SwFmt & rFmt, const String & sNewName,
2061                    sal_Bool bBroadcast = sal_False);
2062 
2063     // Change a TOX undoable.
2064     void ChgTOX(SwTOXBase & rTOX, const SwTOXBase & rNew);
2065 
2066     // #111827#
2067     /**
2068        Returns a textual description of a PaM.
2069 
2070        @param rPaM     the PaM to describe
2071 
2072        If rPaM only spans one paragraph the result is:
2073 
2074             '<text in the PaM>'
2075 
2076        <text in the PaM> is shortened to nUndoStringLength characters.
2077 
2078        If rPaM spans more than one paragraph the result is:
2079 
2080             paragraphs                               (STR_PARAGRAPHS)
2081 
2082        @return the textual description of rPaM
2083      */
2084     String GetPaMDescr(const SwPaM & rPaM) const;
2085 
2086     // -> #i23726#
2087     sal_Bool IsFirstOfNumRule(SwPosition & rPos);
2088     // <- #i23726#
2089 
2090     // --> #i31958# access methods for XForms model(s)
2091 
2092     /// access container for XForms model; will be NULL if !isXForms()
2093 	com::sun::star::uno::Reference<com::sun::star::container::XNameContainer>
2094         getXForms() const;
2095 
2096     com::sun::star::uno::Reference< com::sun::star::linguistic2::XProofreadingIterator > GetGCIterator() const;
2097 
2098     /// is this an XForms document?
2099     bool isXForms() const;
2100 
2101     /// initialize XForms models; turn this into an XForms document
2102     void initXForms( bool bCreateDefaultModel );
2103     // <-- #i31958# access methods for XForms model(s)
2104 
2105     void disposeXForms( );  // #i113606#, for disposing XForms
2106 
2107     // --> OD 2006-03-21 #b6375613#
2108     inline bool ApplyWorkaroundForB6375613() const
2109     {
2110         return mbApplyWorkaroundForB6375613;
2111     }
2112     void SetApplyWorkaroundForB6375613( bool p_bApplyWorkaroundForB6375613 );
2113     // <--
2114 
2115     //Update all the page masters
2116     void SetDefaultPageMode(bool bSquaredPageMode);
2117     sal_Bool IsSquaredPageMode() const;
2118 
2119 	// i#78591#
2120 	void Setn32DummyCompatabilityOptions1( sal_uInt32 CompatabilityOptions1 )
2121 	{
2122 		n32DummyCompatabilityOptions1 = CompatabilityOptions1;
2123 	}
2124 	sal_uInt32 Getn32DummyCompatabilityOptions1( )
2125 	{
2126 		return n32DummyCompatabilityOptions1;
2127 	}
2128 	void Setn32DummyCompatabilityOptions2( sal_uInt32 CompatabilityOptions2 )
2129 	{
2130 		n32DummyCompatabilityOptions2 = CompatabilityOptions2;
2131 	}
2132 	sal_uInt32 Getn32DummyCompatabilityOptions2( )
2133 	{
2134 		return n32DummyCompatabilityOptions2;
2135 	}
2136 #ifdef FUTURE_VBA
2137     com::sun::star::uno::Reference< com::sun::star::script::vba::XVBAEventProcessor > GetVbaEventProcessor();
2138 #endif
2139     ::sfx2::IXmlIdRegistry& GetXmlIdRegistry();
2140     ::sw::MetaFieldManager & GetMetaFieldManager();
2141     ::sw::UndoManager      & GetUndoManager();
2142     ::sw::UndoManager const& GetUndoManager() const;
2143     SfxObjectShell* CreateCopy(bool bCallInitNew) const;
2144 };
2145 
2146 
2147 // Diese Methode wird im Dtor vom SwDoc gerufen und loescht den Cache
2148 // der Konturobjekte
2149 void ClrContourCache();
2150 
2151 
2152 //------------------ inline impl. ---------------------------------
2153 
2154 inline const SwTableNode* SwDoc::IsIdxInTbl( const SwNodeIndex& rIdx ) const
2155 {
2156 	return ((SwDoc*)this)->IsIdxInTbl( rIdx );
2157 }
2158 
2159 inline SvNumberFormatter* SwDoc::GetNumberFormatter( sal_Bool bCreate )
2160 {
2161 	if( bCreate && !pNumberFormatter )
2162 		_CreateNumberFormatter();
2163 	return pNumberFormatter;
2164 }
2165 
2166 inline const SvNumberFormatter* SwDoc::GetNumberFormatter( sal_Bool bCreate ) const
2167 {
2168 	return ((SwDoc*)this)->GetNumberFormatter( bCreate );
2169 }
2170 
2171 inline void SwDoc::SetOLEPrtNotifyPending( bool bSet )
2172 {
2173 	mbOLEPrtNotifyPending = bSet;
2174 	if( !bSet )
2175 		mbAllOLENotify = sal_False;
2176 }
2177 
2178 // --> OD 2006-03-14 #i62875#
2179 // namespace <docfunc> for functions and procedures working on a Writer document.
2180 namespace docfunc
2181 {
2182     /** method to check, if given Writer document contains at least one drawing object
2183 
2184         OD 2006-03-17 #i62875#
2185 
2186         @author OD
2187 
2188         @param p_rDoc
2189         input parameter - reference to the Writer document, which is investigated.
2190     */
2191     bool ExistsDrawObjs( SwDoc& p_rDoc );
2192 
2193     /** method to check, if given Writer document contains only drawing objects,
2194         which are completely on its page.
2195 
2196         OD 2006-03-17 #i62875#
2197 
2198         @author OD
2199 
2200         @param p_rDoc
2201         input parameter - reference to the Writer document, which is investigated.
2202     */
2203     bool AllDrawObjsOnPage( SwDoc& p_rDoc );
2204 
2205     /** method to check, if the outline style has to written as a normal list style
2206 
2207         OD 2006-09-27 #i69627#
2208         The outline style has to written as a normal list style, if a parent
2209         paragraph style of one of the paragraph styles, which are assigned to
2210         the list levels of the outline style, has a list style set or inherits
2211         a list style from its parent paragraphs style.
2212         This information is needed for the OpenDocument file format export.
2213 
2214         @author OD
2215 
2216         @param rDoc
2217         input parameter - reference to the text document, which is investigated.
2218 
2219         @return boolean
2220         indicating, if the outline style has to written as a normal list style
2221     */
2222     bool HasOutlineStyleToBeWrittenAsNormalListStyle( SwDoc& rDoc );
2223 }
2224 // <--
2225 #endif	//_DOC_HXX
2226