LibreOffice Module sc (master)  1
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at
8  *
9  * This file incorporates work covered by the following license notice:
10  *
11  * Licensed to the Apache Software Foundation (ASF) under one or more
12  * contributor license agreements. See the NOTICE file distributed
13  * with this work for additional information regarding copyright
14  * ownership. The ASF licenses this file to you under the Apache
15  * License, Version 2.0 (the "License"); you may not use this file
16  * except in compliance with the License. You may obtain a copy of
17  * the License at .
18  */
23 #include <vcl/idle.hxx>
24 #include <vcl/errcode.hxx>
25 #include <com/sun/star/uno/Reference.hxx>
26 #include <vcl/vclptr.hxx>
27 #include "patattr.hxx"
28 #include "scdllapi.h"
29 #include "interpretercontext.hxx"
30 #include "rangelst.hxx"
31 #include "rangenam.hxx"
32 #include "tabopparams.hxx"
33 #include "types.hxx"
34 #include <formula/grammar.hxx>
35 #include <formula/types.hxx>
36 #include "typedstrdata.hxx"
37 #include "calcmacros.hxx"
38 #include "calcconfig.hxx"
39 #include "sheetlimits.hxx"
40 #include <o3tl/deleter.hxx>
41 #include <o3tl/sorted_vector.hxx>
42 #include <svl/hint.hxx>
43 #include <svl/typedwhich.hxx>
44 #include <svl/zforlist.hxx>
45 #include <tools/gen.hxx>
46 #include <tools/solar.h>
48 #include <cassert>
49 #include <memory>
50 #include <map>
51 #include <set>
52 #include <unordered_map>
53 #include <vector>
55 #include "markdata.hxx"
57 namespace com::sun::star::chart2 { class XChartDocument; }
59 class Timer;
61 enum class SvtScriptType;
62 enum class ScMF;
63 enum class FormulaError : sal_uInt16;
64 enum class CharCompressType;
65 enum class EEHorizontalTextDirection;
66 namespace editeng { class SvxBorderLine; }
67 namespace formula { struct VectorRefArray; }
68 namespace svl {
70 class SharedString;
71 class SharedStringPool;
73 }
75 namespace sc {
77 struct FormulaGroupContext;
78 class StartListeningContext;
79 class EndListeningContext;
80 class CopyFromClipContext;
81 class ColumnSpanSet;
82 class RangeColumnSpanSet;
83 struct ColumnBlockPosition;
84 struct RefUpdateContext;
85 class EditTextIterator;
86 struct NoteEntry;
87 class DocumentStreamAccess;
88 class DocumentLinkManager;
89 class CellValues;
90 class TableValues;
91 class RowHeightContext;
92 struct SetFormulaDirtyContext;
93 class RefMovedHint;
94 struct ReorderParam;
95 class FormulaGroupAreaListener;
96 class ColumnSet;
97 class UpdatedRangeNames;
98 class TableColumnBlockPositionSet;
99 class ColumnIterator;
100 class ExternalDataMapper;
102 }
104 class Fraction;
106 class OutputDevice;
107 class SdrObject;
108 class SfxBroadcaster;
109 class SfxListener;
110 class SfxItemSet;
111 class SfxObjectShell;
112 class SfxBindings;
113 class SfxPoolItem;
114 class SfxItemPool;
115 class SfxPrinter;
116 class SfxStyleSheetBase;
117 class SvMemoryStream;
118 class SvxBoxInfoItem;
119 class SvxBoxItem;
121 namespace sfx2 {
122  class LinkManager;
123  }
124 class SvxSearchItem;
125 namespace vcl { class Window; }
126 class XColorList;
128 class ScAutoFormatData;
132 class ScClipOptions;
133 class ScColumn;
134 class ScConditionalFormat;
136 class ScDBCollection;
137 class ScDBData;
138 class ScDetOpData;
139 class ScDetOpList;
140 class ScDocOptions;
141 class ScDocProtection;
142 class ScDocumentPool;
143 class ScDrawLayer;
144 class ScExtDocOptions;
146 class ScFormulaCell;
147 class ScMacroManager;
148 class ScOutlineTable;
149 class ScPrintRangeSaver;
150 class ScStyleSheet;
151 class ScStyleSheetPool;
152 class ScTable;
153 class ScTableProtection;
154 class ScTokenArray;
155 class ScValidationData;
157 class ScViewOptions;
158 class ScChangeTrack;
160 class ScFieldEditEngine;
161 class ScNoteEditEngine;
162 class ScDPObject;
163 class ScDPCollection;
164 class ScMatrix;
165 class ScScriptTypeData;
166 class ScPoolHelper;
167 struct ScSortParam;
169 class ScUnoListenerCalls;
170 class ScUnoRefList;
171 class ScRecursionHelper;
172 struct RowInfo;
173 struct ScTableInfo;
174 struct ScTabOpParam;
175 class VirtualDevice;
176 class ScAutoNameCache;
178 class ScLookupCache;
179 struct ScLookupCacheMap;
180 class SfxUndoManager;
181 class ScFormulaParserPool;
182 struct ScClipParam;
183 class ScRowBreakIterator;
184 struct ScSetStringParam;
185 struct ScColWidthParam;
186 class ScSheetEvents;
187 class ScProgress;
188 class SvtListener;
189 class ScEditDataArray;
190 class EditTextObject;
191 struct ScRefCellValue;
192 class ScPostIt;
193 struct ScSubTotalParam;
194 struct ScQueryParam;
195 class ScHint;
196 class SvtBroadcaster;
197 enum class ScDBDataPortion;
198 enum class ScSheetEventId;
199 class BitmapEx;
200 class ScColumnsRange;
203 struct ScSheetLimits;
205 namespace sc {
207 typedef std::map<OUString, BitmapEx> IconSetBitmapMap;
209 }
211 namespace com::sun::star {
212  namespace lang {
213  struct EventObject;
214  }
215  namespace i18n {
216  class XBreakIterator;
217  }
218  namespace util {
219  class XModifyListener;
220  }
221  namespace embed {
222  class XEmbeddedObject;
223  }
224  namespace script::vba {
225  class XVBAEventProcessor;
226  }
227  namespace sheet {
228  struct TablePageBreakData;
229  }
230 }
232 namespace weld {
234 class Window;
236 }
238 #define SC_DOC_NEW 0xFFFF
245 {
250 };
253 {
254  ALLSHOWN, // All comments captions are shown
255  ALLHIDDEN, // All comments captions are hidden
256  MIXED // There are comments in shown and hidden.
257 };
260 {
261  GLOBAL, // A range name can be defined
262  SHEET // with two scope on Manage Names dialog.
263 };
266 enum class SheetGeomType
267 {
268  SIZES, // Column widths or row heights.
269  HIDDEN, // Hidden columns/rows.
270  FILTERED, // Filtered columns/rows.
271  GROUPS // Grouping of columns/rows.
272 };
274 struct ScDocStat
275 {
276  OUString aDocName;
280  sal_uInt16 nPageCount;
282  : nTableCount(0)
283  , nCellCount(0)
284  , nFormulaCount(0)
285  , nPageCount(0)
286  {
287  }
288 };
290 // DDE link modes
296 // During threaded calculation fields being mutated are kept in this struct
298 {
299  ScRecursionHelper* pRecursionHelper; // information for recursive and iterative cell formulas
300  ScInterpreterContext* pContext; // references the context passed around for easier access
303  : pRecursionHelper(nullptr)
304  , pContext(nullptr)
305  {
306  }
308  // To be called in the thread at start
309  static void SetupFromNonThreadedData(const ScDocumentThreadSpecific& rNonThreadedData);
311  // To be called in the main thread after the thread has finished
312  static void MergeBackIntoNonThreadedData(ScDocumentThreadSpecific& rNonThreadedData);
313 };
317 {
318  // Bit mask bits
319  CORE = 0x0001,
320 };
322 typedef std::unique_ptr<ScTable, o3tl::default_delete<ScTable>> ScTableUniquePtr;
325 {
326 friend class ScValueIterator;
330 friend class ScCellIterator;
331 friend class ScQueryCellIterator;
335 friend class ScDocAttrIterator;
337 friend class ScAttrRectIterator;
338 friend class ScDocShell;
341 friend class ScFormulaCell;
342 friend class ScTable;
343 friend class ScColumn;
344 friend struct ScRefCellValue;
345 friend class ScDocumentImport;
347 friend class sc::ColumnSpanSet;
349 friend class sc::EditTextIterator;
352 friend struct ScMutationGuard;
353 friend struct ScMutationDisable;
355  typedef std::vector<ScTableUniquePtr> TableContainer;
357 public:
358  enum class HardRecalcState
359  {
360  OFF,
363  };
365 private:
368  std::shared_ptr<svl::SharedStringPool> mpCellStringPool;
369  std::unique_ptr<sc::DocumentLinkManager> mpDocLinkMgr;
371  std::shared_ptr<sc::FormulaGroupContext> mpFormulaGroupCxt;
377  std::unique_ptr<ScFieldEditEngine> mpEditEngine; // uses pEditPool from xPoolHelper
378  std::unique_ptr<ScNoteEditEngine> mpNoteEngine; // uses pEditPool from xPoolHelper
382  std::unique_ptr<ScDrawLayer> mpDrawLayer; // SdrModel
384  std::unique_ptr<ScValidationDataList> pValidationList; // validity
385  SvNumberFormatterIndexTable* pFormatExchangeList; // for application of number formats
386  TableContainer maTabs;
388  std::vector<OUString> maTabNames; // for undo document, we need the information tab name <-> index
389  mutable std::unique_ptr<ScRangeName> pRangeName;
390  std::unique_ptr<ScDBCollection> pDBCollection;
391  std::unique_ptr<ScDPCollection> pDPCollection;
392  std::unique_ptr< ScTemporaryChartLock > apTemporaryChartLock;
393  std::unique_ptr<ScPatternAttr> pSelectionAttr; // Attributes of a block
394  ScFormulaCell* pFormulaTree; // formula tree (start)
395  ScFormulaCell* pEOFormulaTree; // formula tree (end), last cell
396  ScFormulaCell* pFormulaTrack; // BroadcastTrack (start)
397  ScFormulaCell* pEOFormulaTrack; // BroadcastTrack (end), last cell
398  std::unique_ptr<ScBroadcastAreaSlotMachine> pBASM; // BroadcastAreas
399  std::unique_ptr<ScChartListenerCollection> pChartListenerCollection;
400  std::unique_ptr<SvMemoryStream> pClipData;
401  std::unique_ptr<ScDetOpList> pDetOpList;
402  std::unique_ptr<ScChangeTrack> pChangeTrack;
403  std::unique_ptr<SfxBroadcaster> pUnoBroadcaster;
404  std::unique_ptr<ScUnoListenerCalls> pUnoListenerCalls;
405  std::unique_ptr<ScUnoRefList> pUnoRefUndoList;
406  std::unique_ptr<ScChangeViewSettings> pChangeViewSettings;
407  std::unique_ptr<ScScriptTypeData> pScriptTypeData;
408  std::unique_ptr<ScRefreshTimerControl> pRefreshTimerControl;
409  std::shared_ptr<SvxForbiddenCharactersTable> xForbiddenCharacters;
410  std::unique_ptr<ScDBData> mpAnonymousDBData;
411  std::unique_ptr<sc::ExternalDataMapper> mpDataMapper;
413  std::unique_ptr<ScFieldEditEngine> pCacheFieldEditEngine;
415  std::unique_ptr<ScDocProtection> pDocProtection;
416  std::unique_ptr<ScClipParam> mpClipParam;
418  std::unique_ptr<ScExternalRefManager> pExternalRefMgr;
419  std::unique_ptr<ScMacroManager> mpMacroMgr;
421  // mutable for lazy construction
422  mutable std::unique_ptr< ScFormulaParserPool >
425  OUString aDocName; // optional: name of document
426  OUString aDocCodeName; // optional: name of document (twice?)
427  OUString maFileURL; // file URL for copy & paste
431  std::unique_ptr<ScViewOptions> pViewOptions; // view options
432  std::unique_ptr<ScDocOptions> pDocOptions; // document options
433  std::unique_ptr<ScExtDocOptions> pExtDocOptions; // for import etc.
434  std::unique_ptr<ScClipOptions> mpClipOptions; // clipboard options
435  std::unique_ptr<ScConsolidateParam> pConsolidateDlgData;
437  std::unique_ptr<ScAutoNameCache> pAutoNameCache; // for automatic name lookup during CompileXML
439  std::unique_ptr<SfxItemSet> pPreviewFont; // convert to std::unique_ptr or whatever
442  sal_Int64 nUnoObjectId; // counted up for UNO objects
444  ErrCode nRangeOverflowType; // used in (xml) loading for overflow warnings
451  css::uno::Reference< css::script::vba::XVBAEventProcessor >
453 public:
455  std::vector<ScInterpreterTableOpParams*> m_TableOpList;
458 private:
460  LanguageType eLanguage; // default language
461  LanguageType eCjkLanguage; // default language for asian text
462  LanguageType eCtlLanguage; // default language for complex text
463  rtl_TextEncoding eSrcSet; // during reading: source character set
469  sal_uLong nFormulaCodeInTree; // formula RPN in the formula tree
470  sal_uLong nXMLImportedFormulaCount; // progress count during XML import
471  sal_uInt16 nInterpretLevel; // >0 if in interpreter
472  sal_uInt16 nMacroInterpretLevel; // >0 if macro in interpreter
473  sal_uInt16 nInterpreterTableOpLevel; // >0 if in interpreter TableOp
477  // There can be only one ScDocument being calculated in a thread at a time, so we can use a
478  // plain thread_local static member.
483  osl::Mutex mScLookupMutex; // protection for thread-unsafe parts of handling ScLookup
485  static const sal_uInt16 nSrcVer; // file version (load/save)
486  sal_uInt16 nFormulaTrackCount;
487  HardRecalcState eHardRecalcState; // off, temporary, eternal
488  SCTAB nVisibleTab; // for OLE etc., don't use inside ScDocument
489  SCCOL nPosLeft; // for OLE etc., don't use inside ScDocument
490  SCROW nPosTop; // for OLE etc., don't use inside ScDocument
494  bool bAutoCalc; // calculate automatically
495  bool bAutoCalcShellDisabled; // in/from/for ScDocShell disabled
496  // are there ForcedFormulas which have to be calculated
497  // in interaction with ScDocShell SetDocumentModified,
498  // AutoCalcShellDisabled and TrackFormulas
501  bool bIsClip;
502  bool bIsUndo;
504  bool bIsVisible; // set from view ctor
506  bool bIsEmbedded; // display/adjust Embedded area?
508  // no broadcast, construct no listener during insert from a different
509  // Doc (per filter or the like ), not until CompileAll / CalcAfterLoad
512  bool bImportingXML; // special handling of formula text
513  bool bCalcingAfterLoad; // in CalcAfterLoad TRUE
514  // don't construct/destruct listeners temporarily
517  bool bInLinkUpdate; // TableLink or AreaLink
519  // are/were there RC_FORCED formula cells in the document (if set once to TRUE then set forever)
521  // is the Doc being destroyed? (no Notify-Tracking etc. needed anymore)
523  // expand reference if insert column/row takes place at the border
524  // of a reference
525  // is fetched in each UpdateReference from InputOptions,
526  // assigned, and restored at the end of UpdateReference
528  // for detective update, is set for each change of a formula
530  // If the pointer is set, formula cells will not be automatically grouped into shared formula groups,
531  // instead the range will be extended to contain all such cells.
532  std::unique_ptr< ScRange > pDelayedFormulaGrouping;
533  // If non-empty, ScColumn::StartListeningFormulaCells() calls may be delayed using this,
534  // avoiding repeated calling for the same cells in the given range. The function will be called once
535  // later for all the cells in the range.
536  std::unordered_map< ScColumn*, std::pair<SCROW, SCROW>> pDelayedStartListeningFormulaCells;
538  bool bLinkFormulaNeedingCheck; // valid only after loading, for ocDde and ocWebservice
545  sal_uInt8 nInDdeLinkUpdate; // originating DDE links (stacked bool)
549  sal_uInt32 nAdjustHeightLock;
556  bool mbChangeReadOnlyEnabled:1; // allow changes in read-only document (for API import filters)
558  bool mbUserInteractionEnabled:1; // whether or not to launch any kind of interactive dialogs.
562  std::set<ScFormulaCell*> maSubTotalCells;
565  bool mbEmbedFonts : 1;
571  std::unique_ptr<sc::IconSetBitmapMap> m_pIconSetBitmapMap;
575  // This indicates if a ScDocShell::DoRecalc() or ScDocShell::DoHardRecalc() is in progress.
580 public:
581  bool IsCellInChangeTrack(const ScAddress &cell,Color *pColCellBorder);
582  void GetCellChangeTrackNote(const ScAddress &cell, OUString &strTrackText, bool &pbLeftEdge);
584  bool IsEmbedFonts() const { return mbEmbedFonts; }
590  void SetEmbedFonts(bool bUse) { mbEmbedFonts = bUse; }
591  void SetEmbedUsedFontsOnly(bool bUse) { mbEmbedUsedFontsOnly = bUse; }
596  SC_DLLPUBLIC sal_uLong GetCellCount() const; // all cells
597  SC_DLLPUBLIC sal_uLong GetFormulaGroupCount() const; // all cells
598  sal_uLong GetCodeCount() const; // RPN-Code in formulas
599  DECL_LINK( GetUserDefinedColor, sal_uInt16, Color* );
600  // number formatter
601 public:
603  SfxObjectShell* pDocShell = nullptr );
606  void SetName( const OUString& r ) { aDocName = r; }
607  const OUString& GetCodeName() const { return aDocCodeName; }
608  void SetCodeName( const OUString& r ) { aDocCodeName = r; }
609  const OUString& GetFileURL() const { return maFileURL; }
611  void GetDocStat( ScDocStat& rDocStat );
613  SC_DLLPUBLIC void InitDrawLayer( SfxObjectShell* pDocShell = nullptr );
616  {
618  return maInterpreterContext;
619  }
620  // Uses thread_local.
622  {
623  return IsThreadedGroupCalcInProgress() ? *maThreadSpecific.pContext : GetNonThreadedContext();
624  }
625  static void SetupFromNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber );
626  void MergeBackIntoNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber );
636  SC_DLLPUBLIC const ScDocOptions& GetDocOptions() const;
637  SC_DLLPUBLIC void SetDocOptions( const ScDocOptions& rOpt );
639  SC_DLLPUBLIC void SetViewOptions( const ScViewOptions& rOpt );
640  void SetPrintOptions();
642  ScExtDocOptions* GetExtDocOptions() { return pExtDocOptions.get(); }
643  SC_DLLPUBLIC void SetExtDocOptions( std::unique_ptr<ScExtDocOptions> pNewOptions );
645  ScClipOptions* GetClipOptions() { return mpClipOptions.get(); }
646  void SetClipOptions(std::unique_ptr<ScClipOptions> pClipOptions);
648  SC_DLLPUBLIC void GetLanguage( LanguageType& rLatin, LanguageType& rCjk, LanguageType& rCtl ) const;
649  void SetLanguage( LanguageType eLatin, LanguageType eCjk, LanguageType eCtl );
651  void SetConsolidateDlgData( std::unique_ptr<ScConsolidateParam> pData );
652  const ScConsolidateParam* GetConsolidateDlgData() const { return pConsolidateDlgData.get(); }
654  void Clear( bool bFromDestructor = false );
656  std::unique_ptr<ScFieldEditEngine> CreateFieldEditEngine();
657  void DisposeFieldEditEngine(std::unique_ptr<ScFieldEditEngine>& rpEditEngine);
664  SC_DLLPUBLIC void SetAllRangeNames(const std::map<OUString, std::unique_ptr<ScRangeName>>& rRangeMap);
665  SC_DLLPUBLIC void GetRangeNameMap(std::map<OUString, ScRangeName*>& rRangeName);
668  void SetRangeName(SCTAB nTab, std::unique_ptr<ScRangeName> pNew);
669  void SetRangeName( std::unique_ptr<ScRangeName> pNewRangeName );
670  bool IsAddressInRangeName( RangeNameScope eScope, const ScAddress& rAddress);
679  ScRangeData* FindRangeNameBySheetAndIndex( SCTAB nTab, sal_uInt16 nIndex ) const;
725  SCTAB nTokenTab, const sal_uInt16 nTokenIndex,
726  SCTAB nGlobalRefTab, SCTAB nLocalRefTab, SCTAB nOldTokenTab, SCTAB nOldTokenTabReplacement,
727  bool bSameDoc, int nRecursion ) const;
769  bool CopyAdjustRangeName( SCTAB& rSheet, sal_uInt16& rIndex, ScRangeData*& rpRangeData, ScDocument& rNewDoc,
770  const ScAddress& rNewPos, const ScAddress& rOldPos, const bool bGlobalNamesToLocal,
771  const bool bUsedByFormula ) const;
776  SC_DLLPUBLIC void PreprocessAllRangeNamesUpdate( const std::map<OUString, std::unique_ptr<ScRangeName>>& rRangeMap );
794  bool InsertNewRangeName( const OUString& rName, const ScAddress& rPos, const OUString& rExpr );
807  bool InsertNewRangeName( SCTAB nTab, const OUString& rName, const ScAddress& rPos, const OUString& rExpr );
809  SCTAB GetMaxTableNumber() const { return static_cast<SCTAB>(maTabs.size()) - 1; }
811  ScRangePairList* GetColNameRanges() { return xColNameRanges.get(); }
812  ScRangePairList* GetRowNameRanges() { return xRowNameRanges.get(); }
819  SC_DLLPUBLIC ScDBCollection* GetDBCollection() const { return pDBCollection.get();}
820  void SetDBCollection( std::unique_ptr<ScDBCollection> pNewDBCollection,
821  bool bRemoveAutoFilter = false );
822  const ScDBData* GetDBAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab, ScDBDataPortion ePortion) const;
823  ScDBData* GetDBAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab, ScDBDataPortion ePortion);
824  const ScDBData* GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2) const;
825  ScDBData* GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2);
829  SC_DLLPUBLIC const ScRangeData* GetRangeAtBlock( const ScRange& rBlock, OUString* pName ) const;
831  SC_DLLPUBLIC bool HasPivotTable() const;
834  SC_DLLPUBLIC ScDPObject* GetDPAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab) const;
835  ScDPObject* GetDPAtBlock( const ScRange& rBlock ) const;
837  void StopTemporaryChartLock();
839  void EnsureGraphicNames();
841  SdrObject* GetObjectAtPoint( SCTAB nTab, const Point& rPos );
842  bool HasChartAtPoint( SCTAB nTab, const Point& rPos, OUString& rName );
844  css::uno::Reference< css::chart2::XChartDocument > GetChartByName( const OUString& rChartName );
846  SC_DLLPUBLIC void GetChartRanges( const OUString& rChartName, std::vector< ScRangeList >& rRanges, const ScDocument* pSheetNameDoc );
847  void SetChartRanges( const OUString& rChartName, const std::vector< ScRangeList >& rRanges );
849  void UpdateChartArea( const OUString& rChartName, const ScRange& rNewArea,
850  bool bColHeaders, bool bRowHeaders, bool bAdd );
851  void UpdateChartArea( const OUString& rChartName,
852  const ScRangeListRef& rNewList,
853  bool bColHeaders, bool bRowHeaders, bool bAdd );
854  void GetOldChartParameters( const OUString& rName,
855  ScRangeList& rRanges, bool& rColHeaders, bool& rRowHeaders );
856  css::uno::Reference<
857  css::embed::XEmbeddedObject >
858  FindOleObjectByName( const OUString& rName );
860  SC_DLLPUBLIC void MakeTable( SCTAB nTab,bool _bNeedsNameCheck = true );
862  SCTAB GetVisibleTab() const { return nVisibleTab; }
863  SC_DLLPUBLIC void SetVisibleTab(SCTAB nTab) { nVisibleTab = nTab; }
864  SCCOL GetPosLeft() const { return nPosLeft; }
865  SC_DLLPUBLIC void SetPosLeft(SCCOL nCol) { nPosLeft = nCol; }
866  SCROW GetPosTop() const { return nPosTop; }
867  SC_DLLPUBLIC void SetPosTop(SCROW nRow) { nPosTop = nRow; }
869  SC_DLLPUBLIC bool HasTable( SCTAB nTab ) const;
870  SC_DLLPUBLIC bool GetHashCode( SCTAB nTab, sal_Int64& rHashCode) const;
871  SC_DLLPUBLIC bool GetName( SCTAB nTab, OUString& rName ) const;
872  SC_DLLPUBLIC bool GetCodeName( SCTAB nTab, OUString& rName ) const;
873  SC_DLLPUBLIC bool SetCodeName( SCTAB nTab, const OUString& rName );
874  SC_DLLPUBLIC bool GetTable( const OUString& rName, SCTAB& rTab ) const;
875  SC_DLLPUBLIC SCCOL MaxCol() const { return mxSheetLimits->mnMaxCol; }
876  SC_DLLPUBLIC SCROW MaxRow() const { return mxSheetLimits->mnMaxRow; }
878  [[nodiscard]] bool ValidCol(SCCOL nCol) const { return ::ValidCol(nCol, mxSheetLimits->mnMaxCol); }
879  [[nodiscard]] bool ValidRow(SCROW nRow) const { return ::ValidRow(nRow, mxSheetLimits->mnMaxRow); }
880  [[nodiscard]] bool ValidColRow(SCCOL nCol, SCROW nRow) const { return ::ValidColRow(nCol, nRow, MaxCol(), MaxRow()); }
881  [[nodiscard]] bool ValidColRowTab(SCCOL nCol, SCROW nRow, SCTAB nTab) const { return ::ValidColRowTab(nCol, nRow, nTab, MaxCol(), MaxRow()); }
882  [[nodiscard]] bool ValidRange(const ScRange& rRange) const { return ::ValidRange(rRange, MaxCol(), MaxRow()); }
883  [[nodiscard]] bool ValidAddress(const ScAddress& rAddress) const { return ::ValidAddress(rAddress, MaxCol(), MaxRow()); }
884  [[nodiscard]] SCCOL SanitizeCol( SCCOL nCol ) const { return ::SanitizeCol(nCol, MaxCol()); }
885  [[nodiscard]] SCROW SanitizeRow( SCROW nRow ) const { return ::SanitizeRow(nRow, MaxRow()); }
887  SC_DLLPUBLIC std::vector<OUString> GetAllTableNames() const;
889  OUString GetCopyTabName(SCTAB nTab) const;
891  SC_DLLPUBLIC void SetAnonymousDBData(SCTAB nTab, std::unique_ptr<ScDBData> pDBData);
898  SC_DLLPUBLIC void SetAnonymousDBData(std::unique_ptr<ScDBData> pDBData);
905  SC_DLLPUBLIC void SetDocProtection(const ScDocProtection* pProtect);
906  SC_DLLPUBLIC bool IsDocProtected() const;
907  bool IsDocEditable() const;
908  SC_DLLPUBLIC bool IsTabProtected( SCTAB nTab ) const;
910  SC_DLLPUBLIC void SetTabProtection(SCTAB nTab, const ScTableProtection* pProtect);
911  void CopyTabProtection(SCTAB nTabSrc, SCTAB nTabDest);
913  void LockTable(SCTAB nTab);
914  void UnlockTable(SCTAB nTab);
916  bool IsBlockEditable( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
917  SCCOL nEndCol, SCROW nEndRow,
918  bool* pOnlyNotBecauseOfMatrix = nullptr,
919  bool bNoMatrixAtAll = false ) const;
920  bool IsSelectionEditable( const ScMarkData& rMark,
921  bool* pOnlyNotBecauseOfMatrix = nullptr ) const;
922  bool HasSelectedBlockMatrixFragment( SCCOL nStartCol, SCROW nStartRow,
923  SCCOL nEndCol, SCROW nEndRow,
924  const ScMarkData& rMark ) const;
926  bool IsEditActionAllowed( sc::ColRowEditAction eAction, SCTAB nTab, SCCOLROW nStart, SCCOLROW nEnd ) const;
927  bool IsEditActionAllowed( sc::ColRowEditAction eAction, const ScMarkData& rMark, SCCOLROW nStart, SCCOLROW nEnd ) const;
929  SC_DLLPUBLIC bool GetMatrixFormulaRange( const ScAddress& rCellPos, ScRange& rMatrix );
931  bool IsEmbedded() const { return bIsEmbedded;}
932  void GetEmbedded( ScRange& rRange ) const;
933  void SetEmbedded( const ScRange& rRange );
934  void ResetEmbedded();
935  tools::Rectangle GetEmbeddedRect() const; // 1/100 mm
936  void SetEmbedded( SCTAB nTab, const tools::Rectangle& rRect ); // from VisArea (1/100 mm)
938  static SC_DLLPUBLIC bool ValidTabName( const OUString& rName );
940  SC_DLLPUBLIC bool ValidNewTabName( const OUString& rName ) const;
941  SC_DLLPUBLIC void CreateValidTabName(OUString& rName) const;
942  SC_DLLPUBLIC void CreateValidTabNames(std::vector<OUString>& aNames, SCTAB nCount) const;
944  void AppendTabOnLoad(const OUString& rName);
945  void SetTabNameOnLoad(SCTAB nTab, const OUString& rName);
946  void InvalidateStreamOnSave();
948  SC_DLLPUBLIC bool InsertTab( SCTAB nPos, const OUString& rName,
949  bool bExternalDocument = false, bool bUndoDeleteTab = false );
951  SC_DLLPUBLIC bool InsertTabs( SCTAB nPos, const std::vector<OUString>& rNames,
952  bool bNamesValid = false );
953  SC_DLLPUBLIC bool DeleteTabs( SCTAB nTab, SCTAB nSheets );
954  SC_DLLPUBLIC bool DeleteTab( SCTAB nTab );
955  SC_DLLPUBLIC bool RenameTab( SCTAB nTab, const OUString& rName,
956  bool bExternalDocument = false );
957  bool MoveTab( SCTAB nOldPos, SCTAB nNewPos, ScProgress* pProgress = nullptr );
958  bool CopyTab( SCTAB nOldPos, SCTAB nNewPos,
959  const ScMarkData* pOnlyMarked = nullptr );
960  SC_DLLPUBLIC sal_uLong TransferTab(ScDocument* pSrcDoc, SCTAB nSrcPos, SCTAB nDestPos,
961  bool bInsertNew = true,
962  bool bResultsOnly = false );
963  SC_DLLPUBLIC void TransferDrawPage(const ScDocument* pSrcDoc, SCTAB nSrcPos, SCTAB nDestPos);
964  SC_DLLPUBLIC void SetVisible( SCTAB nTab, bool bVisible );
965  SC_DLLPUBLIC bool IsVisible( SCTAB nTab ) const;
966  bool IsStreamValid( SCTAB nTab ) const;
967  void SetStreamValid( SCTAB nTab, bool bSet, bool bIgnoreLock = false );
968  void LockStreamValid( bool bLock );
969  bool IsStreamValidLocked() const { return mbStreamValidLocked; }
970  bool IsPendingRowHeights( SCTAB nTab ) const;
971  void SetPendingRowHeights( SCTAB nTab, bool bSet );
972  SC_DLLPUBLIC void SetLayoutRTL( SCTAB nTab, bool bRTL );
973  SC_DLLPUBLIC bool IsLayoutRTL( SCTAB nTab ) const;
974  SC_DLLPUBLIC bool IsNegativePage( SCTAB nTab ) const;
975  SC_DLLPUBLIC void SetScenario( SCTAB nTab, bool bFlag );
976  SC_DLLPUBLIC bool IsScenario( SCTAB nTab ) const;
977  SC_DLLPUBLIC void GetScenarioData(SCTAB nTab, OUString& rComment,
978  Color& rColor, ScScenarioFlags &rFlags) const;
979  SC_DLLPUBLIC void SetScenarioData(SCTAB nTab, const OUString& rComment,
980  const Color& rColor, ScScenarioFlags nFlags);
981  SC_DLLPUBLIC Color GetTabBgColor( SCTAB nTab ) const;
982  SC_DLLPUBLIC void SetTabBgColor( SCTAB nTab, const Color& rColor );
983  SC_DLLPUBLIC bool IsDefaultTabBgColor( SCTAB nTab ) const;
984  void GetScenarioFlags(SCTAB nTab, ScScenarioFlags &rFlags) const;
985  SC_DLLPUBLIC bool IsActiveScenario( SCTAB nTab ) const;
986  SC_DLLPUBLIC void SetActiveScenario( SCTAB nTab, bool bActive ); // only for Undo etc.
991  bool IsLinked( SCTAB nTab ) const;
992  SC_DLLPUBLIC OUString GetLinkDoc( SCTAB nTab ) const;
993  OUString GetLinkFlt( SCTAB nTab ) const;
994  OUString GetLinkOpt( SCTAB nTab ) const;
995  SC_DLLPUBLIC OUString GetLinkTab( SCTAB nTab ) const;
996  sal_uLong GetLinkRefreshDelay( SCTAB nTab ) const;
997  void SetLink( SCTAB nTab, ScLinkMode nMode, const OUString& rDoc,
998  const OUString& rFilter, const OUString& rOptions,
999  const OUString& rTabName, sal_uLong nRefreshDelay );
1000  bool HasLink( const OUString& rDoc,
1001  const OUString& rFilter, const OUString& rOptions ) const;
1002  SC_DLLPUBLIC bool LinkExternalTab( SCTAB& nTab, const OUString& aDocTab,
1003  const OUString& aFileName,
1004  const OUString& aTabName );
1006  bool HasExternalRefManager() const { return bool(pExternalRefMgr); }
1008  bool IsInExternalReferenceMarking() const;
1010  bool MarkUsedExternalReferences( const ScTokenArray& rArr, const ScAddress& rPos );
1016  bool HasAreaLinks() const;
1018  void UpdateAreaLinks();
1020  // originating DDE links
1021  void IncInDdeLinkUpdate() { if ( nInDdeLinkUpdate < 255 ) ++nInDdeLinkUpdate; }
1022  void DecInDdeLinkUpdate() { if ( nInDdeLinkUpdate ) --nInDdeLinkUpdate; }
1023  bool IsInDdeLinkUpdate() const { return nInDdeLinkUpdate != 0; }
1025  SC_DLLPUBLIC void CopyDdeLinks( ScDocument* pDestDoc ) const;
1030  SC_DLLPUBLIC bool FindDdeLink( const OUString& rAppl, const OUString& rTopic,
1031  const OUString& rItem, sal_uInt8 nMode, size_t& rnDdePos );
1039  bool GetDdeLinkData( size_t nDdePos, OUString& rAppl, OUString& rTopic, OUString& rItem ) const;
1044  bool GetDdeLinkMode( size_t nDdePos, sal_uInt8& rnMode ) const;
1048  SC_DLLPUBLIC const ScMatrix* GetDdeLinkResultMatrix( size_t nDdePos ) const;
1053  SC_DLLPUBLIC bool CreateDdeLink( const OUString& rAppl, const OUString& rTopic, const OUString& rItem, sal_uInt8 nMode, const ScMatrixRef& pResults );
1058  bool SetDdeLinkResultMatrix( size_t nDdePos, const ScMatrixRef& pResults );
1062  SC_DLLPUBLIC ScDrawLayer* GetDrawLayer() { return mpDrawLayer.get(); }
1063  SC_DLLPUBLIC const ScDrawLayer* GetDrawLayer() const { return mpDrawLayer.get(); }
1064  SfxBroadcaster* GetDrawBroadcaster(); // to avoid header
1065  void BeginDrawUndo();
1067  void BeginUnoRefUndo();
1068  bool HasUnoRefUndo() const { return ( pUnoRefUndoList != nullptr ); }
1069  [[nodiscard]]
1070  std::unique_ptr<ScUnoRefList> EndUnoRefUndo(); // must be deleted by caller!
1071  sal_Int64 GetNewUnoId() { return ++nUnoObjectId; }
1072  void AddUnoRefChange( sal_Int64 nId, const ScRangeList& rOldRanges );
1074  static bool IsChart( const SdrObject* pObject );
1076  void UpdateChartRef( UpdateRefMode eUpdateRefMode,
1077  SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1078  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1079  SCCOL nDx, SCROW nDy, SCTAB nDz );
1081  void SetChartRangeList( const OUString& rChartName,
1082  const ScRangeListRef& rNewRangeListRef );
1084  void StartAnimations( SCTAB nTab );
1086  bool HasBackgroundDraw( SCTAB nTab, const tools::Rectangle& rMMRect ) const;
1087  bool HasAnyDraw( SCTAB nTab, const tools::Rectangle& rMMRect ) const;
1089  const ScSheetEvents* GetSheetEvents( SCTAB nTab ) const;
1090  void SetSheetEvents( SCTAB nTab, std::unique_ptr<ScSheetEvents> pNew );
1091  bool HasSheetEventScript( SCTAB nTab, ScSheetEventId nEvent, bool bWithVbaEvents = false ) const;
1092  bool HasAnySheetEventScript( ScSheetEventId nEvent, bool bWithVbaEvents = false ) const; // on any sheet
1094  bool HasAnyCalcNotification() const;
1095  bool HasCalcNotification( SCTAB nTab ) const;
1096  void SetCalcNotification( SCTAB nTab );
1097  void ResetCalcNotifications();
1099  SC_DLLPUBLIC ScOutlineTable* GetOutlineTable( SCTAB nTab, bool bCreate = false );
1100  bool SetOutlineTable( SCTAB nTab, const ScOutlineTable* pNewOutline );
1102  void DoAutoOutline( SCCOL nStartCol, SCROW nStartRow,
1103  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab );
1105  bool DoSubTotals( SCTAB nTab, ScSubTotalParam& rParam );
1106  void RemoveSubTotals( SCTAB nTab, ScSubTotalParam& rParam );
1107  bool TestRemoveSubTotals( SCTAB nTab, const ScSubTotalParam& rParam );
1108  bool HasSubTotalCells( const ScRange& rRange );
1110  SC_DLLPUBLIC void EnsureTable( SCTAB nTab );
1112  // return TRUE = number format is set
1113  SC_DLLPUBLIC bool SetString( SCCOL nCol, SCROW nRow, SCTAB nTab, const OUString& rString,
1114  const ScSetStringParam * pParam = nullptr );
1115  SC_DLLPUBLIC bool SetString( const ScAddress& rPos, const OUString& rString,
1116  const ScSetStringParam* pParam = nullptr );
1127  SC_DLLPUBLIC bool SetEditText( const ScAddress& rPos, std::unique_ptr<EditTextObject> pEditText );
1128  void SetEditText( const ScAddress& rPos, const EditTextObject& rEditText, const SfxItemPool* pEditPool );
1129  SC_DLLPUBLIC void SetEditText( const ScAddress& rPos, const OUString& rStr );
1130  SC_DLLPUBLIC SCROW GetFirstEditTextRow( const ScRange& rRange ) const;
1136  SC_DLLPUBLIC void SetTextCell( const ScAddress& rPos, const OUString& rStr );
1137  void SetEmptyCell( const ScAddress& rPos );
1138  SC_DLLPUBLIC void SetValue( SCCOL nCol, SCROW nRow, SCTAB nTab, const double& rVal );
1139  SC_DLLPUBLIC void SetValue( const ScAddress& rPos, double fVal );
1140  void SetValues( const ScAddress& rPos, const std::vector<double>& rVals );
1141  void SetError( SCCOL nCol, SCROW nRow, SCTAB nTab, const FormulaError nError);
1142  SC_DLLPUBLIC void SetFormula( const ScAddress& rPos, const ScTokenArray& rArray );
1143  SC_DLLPUBLIC void SetFormula( const ScAddress& rPos, const OUString& rFormula,
1155  bool SetFormulaCells( const ScAddress& rPos, std::vector<ScFormulaCell*>& rCells );
1160  bool HasFormulaCell( const ScRange& rRange ) const;
1161  SC_DLLPUBLIC void InsertMatrixFormula(SCCOL nCol1, SCROW nRow1,
1162  SCCOL nCol2, SCROW nRow2,
1163  const ScMarkData& rMark,
1164  const OUString& rFormula,
1165  const ScTokenArray* p = nullptr,
1167  SC_DLLPUBLIC void InsertTableOp(const ScTabOpParam& rParam, // multi-operation
1168  SCCOL nCol1, SCROW nRow1,
1169  SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark);
1171  SC_DLLPUBLIC OUString GetString( SCCOL nCol, SCROW nRow, SCTAB nTab,
1172  const ScInterpreterContext* pContext = nullptr ) const;
1173  SC_DLLPUBLIC OUString GetString( const ScAddress& rPos,
1174  const ScInterpreterContext* pContext = nullptr ) const;
1184  double* GetValueCell( const ScAddress& rPos );
1189  svl::SharedString GetSharedString( const ScAddress& rPos ) const;
1191  std::shared_ptr<sc::FormulaGroupContext>& GetFormulaGroupContext();
1194  { mbFormulaGroupCxtBlockDiscard = block; }
1196  SC_DLLPUBLIC void GetInputString( SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rString );
1197  FormulaError GetStringForFormula( const ScAddress& rPos, OUString& rString );
1198  SC_DLLPUBLIC double GetValue( const ScAddress& rPos ) const;
1199  SC_DLLPUBLIC double GetValue( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1200  SC_DLLPUBLIC void GetValue( SCCOL nCol, SCROW nRow, SCTAB nTab, double& rValue ) const;
1201  SC_DLLPUBLIC const EditTextObject* GetEditText( const ScAddress& rPos ) const;
1202  void RemoveEditTextCharAttribs( const ScAddress& rPos, const ScPatternAttr& rAttr );
1203  SC_DLLPUBLIC double RoundValueAsShown( double fVal, sal_uInt32 nFormat, const ScInterpreterContext* pContext = nullptr ) const;
1204  SC_DLLPUBLIC void GetNumberFormat( SCCOL nCol, SCROW nRow, SCTAB nTab,
1205  sal_uInt32& rFormat ) const;
1206  sal_uInt32 GetNumberFormat( const ScRange& rRange ) const;
1207  SC_DLLPUBLIC sal_uInt32 GetNumberFormat( const ScInterpreterContext& rContext, const ScAddress& ) const;
1208  void SetNumberFormat( const ScAddress& rPos, sal_uInt32 nNumberFormat );
1210  void GetNumberFormatInfo( const ScInterpreterContext& rContext, SvNumFormatType& nType, sal_uInt32& nIndex, const ScAddress& rPos ) const;
1211  SC_DLLPUBLIC const ScFormulaCell* GetFormulaCell( const ScAddress& rPos ) const;
1213  SC_DLLPUBLIC void GetFormula( SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rFormula ) const;
1214  SC_DLLPUBLIC void GetCellType( SCCOL nCol, SCROW nRow, SCTAB nTab, CellType& rCellType ) const;
1215  SC_DLLPUBLIC CellType GetCellType( const ScAddress& rPos ) const;
1217  SC_DLLPUBLIC bool HasData( SCCOL nCol, SCROW nRow, SCTAB nTab );
1218  SC_DLLPUBLIC bool HasStringData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1219  SC_DLLPUBLIC bool HasValueData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1220  SC_DLLPUBLIC bool HasValueData( const ScAddress& rPos ) const;
1221  bool HasStringCells( const ScRange& rRange ) const;
1224  bool HasSelectionData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1225  bool HasValidationData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1233  sc::MultiDataCellState HasMultipleDataCells( const ScRange& rRange ) const;
1236  SC_DLLPUBLIC ScPostIt* GetNote(const ScAddress& rPos);
1237  SC_DLLPUBLIC ScPostIt* GetNote(SCCOL nCol, SCROW nRow, SCTAB nTab);
1238  void SetNote(const ScAddress& rPos, std::unique_ptr<ScPostIt> pNote);
1239  void SetNote(SCCOL nCol, SCROW nRow, SCTAB nTab, std::unique_ptr<ScPostIt> pNote);
1240  SC_DLLPUBLIC bool HasNote(const ScAddress& rPos) const;
1241  bool HasNote(SCCOL nCol, SCROW nRow, SCTAB nTab) const;
1242  SC_DLLPUBLIC bool HasColNotes(SCCOL nCol, SCTAB nTab) const;
1243  SC_DLLPUBLIC bool HasTabNotes(SCTAB nTab) const;
1244  bool HasNotes() const;
1245  SC_DLLPUBLIC std::unique_ptr<ScPostIt> ReleaseNote(const ScAddress& rPos);
1247  SC_DLLPUBLIC ScPostIt* CreateNote(const ScAddress& rPos);
1248  size_t GetNoteCount( SCTAB nTab, SCCOL nCol ) const;
1254  void CreateAllNoteCaptions();
1255  void ForgetNoteCaptions( const ScRangeList& rRanges, bool bPreserveData );
1258  ScAddress GetNotePosition( size_t nIndex ) const;
1259  ScAddress GetNotePosition( size_t nIndex, SCTAB nTab ) const;
1260  SCROW GetNotePosition( SCTAB nTab, SCCOL nCol, size_t nIndex ) const;
1262  SC_DLLPUBLIC void GetAllNoteEntries( std::vector<sc::NoteEntry>& rNotes ) const;
1263  SC_DLLPUBLIC void GetAllNoteEntries( SCTAB nTab, std::vector<sc::NoteEntry>& rNotes ) const;
1264  void GetNotesInRange( const ScRangeList& rRange, std::vector<sc::NoteEntry>& rNotes ) const;
1265  bool ContainsNotesInRange( const ScRangeList& rRange ) const;
1267  SC_DLLPUBLIC void SetDrawPageSize(SCTAB nTab);
1269  bool IsMerged( const ScAddress& rPos ) const;
1271  void ExtendMergeSel( SCCOL nStartCol, SCROW nStartRow,
1272  SCCOL& rEndCol, SCROW& rEndRow, const ScMarkData& rMark,
1273  bool bRefresh = false );
1274  SC_DLLPUBLIC bool ExtendMerge( SCCOL nStartCol, SCROW nStartRow,
1275  SCCOL& rEndCol, SCROW& rEndRow, SCTAB nTab,
1276  bool bRefresh = false );
1277  bool ExtendMerge( ScRange& rRange, bool bRefresh = false );
1278  SC_DLLPUBLIC void ExtendTotalMerge( ScRange& rRange ) const;
1279  SC_DLLPUBLIC void ExtendOverlapped( SCCOL& rStartCol, SCROW& rStartRow,
1280  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab ) const;
1281  SC_DLLPUBLIC void ExtendOverlapped( ScRange& rRange ) const;
1283  bool RefreshAutoFilter( SCCOL nStartCol, SCROW nStartRow,
1284  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab );
1286  SC_DLLPUBLIC void DoMergeContents( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1287  SCCOL nEndCol, SCROW nEndRow );
1288  SC_DLLPUBLIC void DoEmptyBlock( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1289  SCCOL nEndCol, SCROW nEndRow );
1290  // without checking:
1291  SC_DLLPUBLIC void DoMerge( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1292  SCCOL nEndCol, SCROW nEndRow, bool bDeleteCaptions = true );
1293  void RemoveMerge( SCCOL nCol, SCROW nRow, SCTAB nTab );
1295  bool IsBlockEmpty( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1296  SCCOL nEndCol, SCROW nEndRow, bool bIgnoreNotes = false ) const;
1297  bool IsPrintEmpty( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1298  SCCOL nEndCol, SCROW nEndRow,
1299  bool bLeftIsEmpty = false,
1300  ScRange* pLastRange = nullptr,
1301  tools::Rectangle* pLastMM = nullptr ) const;
1303  void SkipOverlapped( SCCOL& rCol, SCROW& rRow, SCTAB nTab ) const;
1304  bool IsHorOverlapped( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1305  bool IsVerOverlapped( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1307  SC_DLLPUBLIC bool HasAttrib( SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1308  SCCOL nCol2, SCROW nRow2, SCTAB nTab2, HasAttrFlags nMask ) const;
1309  SC_DLLPUBLIC bool HasAttrib( const ScRange& rRange, HasAttrFlags nMask ) const;
1311  SC_DLLPUBLIC void GetBorderLines( SCCOL nCol, SCROW nRow, SCTAB nTab,
1312  const ::editeng::SvxBorderLine** ppLeft,
1313  const ::editeng::SvxBorderLine** ppTop,
1314  const ::editeng::SvxBorderLine** ppRight,
1315  const ::editeng::SvxBorderLine** ppBottom ) const;
1317  void ResetChanged( const ScRange& rRange );
1319  void CheckVectorizationState();
1320  void SetAllFormulasDirty( const sc::SetFormulaDirtyContext& rCxt );
1321  void SetDirty( const ScRange&, bool bIncludeEmptyCells );
1322  void SetTableOpDirty( const ScRange& ); // for Interpreter TableOp
1323  void InterpretDirtyCells( const ScRangeList& rRanges );
1324  SC_DLLPUBLIC void CalcAll();
1325  SC_DLLPUBLIC void CalcAfterLoad( bool bStartListening = true );
1326  void CompileAll();
1327  void CompileXML();
1339  bool CompileErrorCells(FormulaError nErrCode);
1341  ScAutoNameCache* GetAutoNameCache() { return pAutoNameCache.get(); }
1342  void SetPreviewFont( std::unique_ptr<SfxItemSet> pFontSet );
1343  SfxItemSet* GetPreviewFont() { return pPreviewFont.get(); }
1344  SfxItemSet* GetPreviewFont( SCCOL nCol, SCROW nRow, SCTAB nTab );
1346  void SetPreviewSelection( const ScMarkData& rSel );
1348  ScStyleSheet* GetPreviewCellStyle( SCCOL nCol, SCROW nRow, SCTAB nTab );
1349  void SetPreviewCellStyle( ScStyleSheet* pStyle ) { pPreviewCellStyle = pStyle; }
1350  SC_DLLPUBLIC void SetAutoNameCache( std::unique_ptr<ScAutoNameCache> pCache );
1354  ScLookupCache & GetLookupCache( const ScRange & rRange, ScInterpreterContext* pContext );
1357  void RemoveLookupCache( ScLookupCache & rCache );
1359  void ClearLookupCaches();
1361  // calculate automatically
1362  SC_DLLPUBLIC void SetAutoCalc( bool bNewAutoCalc );
1363  SC_DLLPUBLIC bool GetAutoCalc() const { return bAutoCalc; }
1364  // calculate automatically in/from/for ScDocShell disabled
1365  void SetAutoCalcShellDisabled( bool bNew ) { bAutoCalcShellDisabled = bNew; }
1367  // ForcedFormulas are to be calculated
1368  void SetForcedFormulaPending( bool bNew ) { bForcedFormulaPending = bNew; }
1370  // if CalcFormulaTree() is currently running
1374  void DelayFormulaGrouping( bool delay );
1375  bool IsDelayedFormulaGrouping() const { return bool(pDelayedFormulaGrouping); }
1377  void AddDelayedFormulaGroupingCell( const ScFormulaCell* cell );
1381  void EnableDelayStartListeningFormulaCells( ScColumn* column, bool delay );
1382  bool IsEnabledDelayStartListeningFormulaCells( ScColumn* column ) const;
1385  bool CanDelayStartListeningFormulaCells( ScColumn* column, SCROW row1, SCROW row2 );
1387  FormulaError GetErrCode( const ScAddress& ) const;
1401  bool ShrinkToDataArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow, SCCOL& rEndCol, SCROW& rEndRow ) const;
1418  bool ShrinkToUsedDataArea( bool& o_bShrunk,
1419  SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1420  SCCOL& rEndCol, SCROW& rEndRow, bool bColumnsOnly,
1421  bool bStickyTopRow = false, bool bStickyLeftCol = false,
1422  bool bConsiderCellNotes = false,
1423  bool bConsiderCellDrawObjects = false ) const;
1435  SCROW GetLastDataRow( SCTAB nTab, SCCOL nCol1, SCCOL nCol2, SCROW nLastRow ) const;
1450  SC_DLLPUBLIC void GetDataArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1451  SCCOL& rEndCol, SCROW& rEndRow,
1452  bool bIncludeOld, bool bOnlyDown ) const;
1461  bool GetDataAreaSubrange(ScRange& rRange) const;
1463  SC_DLLPUBLIC bool GetCellArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow ) const;
1464  SC_DLLPUBLIC bool GetTableArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow ) const;
1465  SC_DLLPUBLIC bool GetPrintArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow,
1466  bool bNotes = true ) const;
1467  SC_DLLPUBLIC bool GetPrintAreaHor( SCTAB nTab, SCROW nStartRow, SCROW nEndRow,
1468  SCCOL& rEndCol ) const;
1469  SC_DLLPUBLIC bool GetPrintAreaVer( SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol,
1470  SCROW& rEndRow, bool bNotes ) const;
1471  void InvalidateTableArea();
1474  SC_DLLPUBLIC void GetTiledRenderingArea(SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow) const;
1476  SC_DLLPUBLIC bool GetDataStart( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow ) const;
1483  void ExtendPrintArea( OutputDevice* pDev, SCTAB nTab,
1484  SCCOL nStartCol, SCROW nStartRow,
1485  SCCOL& rEndCol, SCROW nEndRow ) const;
1486  SC_DLLPUBLIC SCSIZE GetEmptyLinesInBlock( SCCOL nStartCol, SCROW nStartRow, SCTAB nStartTab,
1487  SCCOL nEndCol, SCROW nEndRow, SCTAB nEndTab,
1488  ScDirection eDir );
1490  void FindAreaPos( SCCOL& rCol, SCROW& rRow, SCTAB nTab, ScMoveDirection eDirection ) const;
1491  SC_DLLPUBLIC void GetNextPos( SCCOL& rCol, SCROW& rRow, SCTAB nTab, SCCOL nMovX, SCROW nMovY,
1492  bool bMarked, bool bUnprotected, const ScMarkData& rMark,
1493  SCCOL nTabStartCol = SC_TABSTART_NONE ) const;
1495  bool GetNextMarkedCell( SCCOL& rCol, SCROW& rRow, SCTAB nTab,
1496  const ScMarkData& rMark );
1498  void LimitChartArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1499  SCCOL& rEndCol, SCROW& rEndRow );
1500  void LimitChartIfAll( ScRangeListRef& rRangeList );
1502  bool InsertRow( SCCOL nStartCol, SCTAB nStartTab,
1503  SCCOL nEndCol, SCTAB nEndTab,
1504  SCROW nStartRow, SCSIZE nSize, ScDocument* pRefUndoDoc = nullptr,
1505  const ScMarkData* pTabMark = nullptr );
1506  SC_DLLPUBLIC bool InsertRow( const ScRange& rRange );
1507  void DeleteRow( SCCOL nStartCol, SCTAB nStartTab,
1508  SCCOL nEndCol, SCTAB nEndTab,
1509  SCROW nStartRow, SCSIZE nSize,
1510  ScDocument* pRefUndoDoc = nullptr, bool* pUndoOutline = nullptr,
1511  const ScMarkData* pTabMark = nullptr );
1512  SC_DLLPUBLIC void DeleteRow( const ScRange& rRange );
1513  bool InsertCol( SCROW nStartRow, SCTAB nStartTab,
1514  SCROW nEndRow, SCTAB nEndTab,
1515  SCCOL nStartCol, SCSIZE nSize, ScDocument* pRefUndoDoc = nullptr,
1516  const ScMarkData* pTabMark = nullptr );
1517  SC_DLLPUBLIC bool InsertCol( const ScRange& rRange );
1518  void DeleteCol( SCROW nStartRow, SCTAB nStartTab,
1519  SCROW nEndRow, SCTAB nEndTab,
1520  SCCOL nStartCol, SCSIZE nSize,
1521  ScDocument* pRefUndoDoc = nullptr, bool* pUndoOutline = nullptr,
1522  const ScMarkData* pTabMark = nullptr );
1523  void DeleteCol( const ScRange& rRange );
1525  bool CanInsertRow( const ScRange& rRange ) const;
1526  bool CanInsertCol( const ScRange& rRange ) const;
1528  void FitBlock( const ScRange& rOld, const ScRange& rNew, bool bClear = true );
1529  bool CanFitBlock( const ScRange& rOld, const ScRange& rNew );
1531  bool IsClipOrUndo() const { return bIsClip || bIsUndo; }
1532  bool IsUndo() const { return bIsUndo; }
1533  bool IsClipboard() const { return bIsClip; }
1534  bool IsUndoEnabled() const { return mbUndoEnabled; }
1535  SC_DLLPUBLIC void EnableUndo( bool bVal );
1536  bool IsFunctionAccess() const { return bIsFunctionAccess; }
1538  bool IsAdjustHeightLocked() const { return nAdjustHeightLock != 0; }
1542  void EnableExecuteLink( bool bVal ) { mbExecuteLinkEnabled = bVal; }
1544  void EnableChangeReadOnly( bool bVal ) { mbChangeReadOnlyEnabled = bVal; }
1546  SC_DLLPUBLIC void EnableUserInteraction( bool bVal );
1548  void SetNamedRangesLockCount( sal_Int16 nCount ) { mnNamedRangesLockCount = nCount; }
1549  SC_DLLPUBLIC void ResetClip( ScDocument* pSourceDoc, const ScMarkData* pMarks );
1550  SC_DLLPUBLIC void ResetClip( ScDocument* pSourceDoc, SCTAB nTab );
1551  void SetCutMode( bool bCut );
1552  bool IsCutMode();
1553  void SetClipArea( const ScRange& rArea, bool bCut = false );
1555  SC_DLLPUBLIC bool IsDocVisible() const { return bIsVisible; }
1556  SC_DLLPUBLIC void SetDocVisible( bool bSet );
1558  bool HasOLEObjectsInArea( const ScRange& rRange, const ScMarkData* pTabMark = nullptr );
1560  void DeleteObjectsInArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1561  const ScMarkData& rMark, bool bAnchored = false );
1562  void DeleteObjectsInSelection( const ScMarkData& rMark );
1564  void DeleteArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark,
1565  InsertDeleteFlags nDelFlag, bool bBroadcast = true,
1566  sc::ColumnSpanSet* pBroadcastSpans = nullptr );
1568  SC_DLLPUBLIC void DeleteAreaTab(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1569  SCTAB nTab, InsertDeleteFlags nDelFlag);
1570  void DeleteAreaTab(const ScRange& rRange, InsertDeleteFlags nDelFlag);
1572  void CopyToClip( const ScClipParam& rClipParam, ScDocument* pClipDoc,
1573  const ScMarkData* pMarks, bool bKeepScenarioFlags,
1574  bool bIncludeObjects );
1585  SC_DLLPUBLIC void CopyStaticToDocument(const ScRange& rSrcRange, SCTAB nDestTab, ScDocument* pDestDoc);
1594  void CopyCellToDocument( const ScAddress& rSrcPos, const ScAddress& rDestPos, ScDocument& rDestDoc );
1596  void CopyTabToClip( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1597  SCTAB nTab, ScDocument* pClipDoc);
1602  sc::ColumnSpanSet& rBroadcastSpans );
1604  bool CopyOneCellFromClip(sc::CopyFromClipContext& rCxt, SCCOL nCol1, SCROW nRow1,
1605  SCCOL nCol2, SCROW nRow2 );
1606  void CopyBlockFromClip( sc::CopyFromClipContext& rCxt, SCCOL nCol1, SCROW nRow1,
1607  SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark,
1608  SCCOL nDx, SCROW nDy );
1610  SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1611  const ScMarkData& rMark, SCCOL nDx, SCROW & rClipStartRow );
1613  void StartListeningFromClip( SCCOL nCol1, SCROW nRow1,
1614  SCCOL nCol2, SCROW nRow2,
1615  const ScMarkData& rMark, InsertDeleteFlags nInsFlag );
1617  void SetDirtyFromClip( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1618  const ScMarkData& rMark, InsertDeleteFlags nInsFlag,
1619  sc::ColumnSpanSet& rBroadcastSpans );
1623  void CopyFromClip( const ScRange& rDestRange, const ScMarkData& rMark,
1624  InsertDeleteFlags nInsFlag,
1625  ScDocument* pRefUndoDoc,
1626  ScDocument* pClipDoc,
1627  bool bResetCut = true,
1628  bool bAsLink = false,
1629  bool bIncludeFiltered = true,
1630  bool bSkipAttrForEmpty = false,
1631  const ScRangeList * pDestRanges = nullptr );
1633  void CopyMultiRangeFromClip(const ScAddress& rDestPos, const ScMarkData& rMark,
1634  InsertDeleteFlags nInsFlag, ScDocument* pClipDoc,
1635  bool bResetCut = true, bool bAsLink = false,
1636  bool bIncludeFiltered = true,
1637  bool bSkipAttrForEmpty = false);
1639  void GetClipArea(SCCOL& nClipX, SCROW& nClipY, bool bIncludeFiltered);
1640  void GetClipStart(SCCOL& nClipX, SCROW& nClipY);
1642  bool HasClipFilteredRows();
1644  bool IsClipboardSource() const;
1646  SC_DLLPUBLIC void TransposeClip( ScDocument* pTransClip, InsertDeleteFlags nFlags, bool bAsLink );
1649  void SetClipParam(const ScClipParam& rParam);
1656  void ClosingClipboardSource();
1658  void MixDocument( const ScRange& rRange, ScPasteFunc nFunction, bool bSkipEmpty,
1659  ScDocument* pSrcDoc );
1661  void FillTab( const ScRange& rSrcArea, const ScMarkData& rMark,
1662  InsertDeleteFlags nFlags, ScPasteFunc nFunction,
1663  bool bSkipEmpty, bool bAsLink );
1664  void FillTabMarked( SCTAB nSrcTab, const ScMarkData& rMark,
1665  InsertDeleteFlags nFlags, ScPasteFunc nFunction,
1666  bool bSkipEmpty, bool bAsLink );
1668  void TransliterateText( const ScMarkData& rMultiMark, TransliterationFlags nType );
1670  SC_DLLPUBLIC void InitUndo( const ScDocument* pSrcDoc, SCTAB nTab1, SCTAB nTab2,
1671  bool bColInfo = false, bool bRowInfo = false );
1672  void AddUndoTab( SCTAB nTab1, SCTAB nTab2,
1673  bool bColInfo = false, bool bRowInfo = false );
1674  SC_DLLPUBLIC void InitUndoSelected( const ScDocument* pSrcDoc, const ScMarkData& rTabSelection,
1675  bool bColInfo = false, bool bRowInfo = false );
1677  // don't use anymore:
1678  void CopyToDocument(SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1679  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1680  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc,
1681  const ScMarkData* pMarks = nullptr, bool bColRowFlags = true);
1682  void UndoToDocument(SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1683  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1684  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc);
1686  void CopyToDocument(const ScRange& rRange,
1687  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc,
1688  const ScMarkData* pMarks = nullptr, bool bColRowFlags = true);
1689  void UndoToDocument(const ScRange& rRange,
1690  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc);
1692  void CopyScenario( SCTAB nSrcTab, SCTAB nDestTab, bool bNewScenario = false );
1693  bool TestCopyScenario( SCTAB nSrcTab, SCTAB nDestTab ) const;
1694  void MarkScenario(SCTAB nSrcTab, SCTAB nDestTab,
1695  ScMarkData& rDestMark, bool bResetMark = true,
1696  ScScenarioFlags nNeededBits = ScScenarioFlags::NONE) const;
1697  bool HasScenarioRange( SCTAB nTab, const ScRange& rRange ) const;
1698  SC_DLLPUBLIC const ScRangeList* GetScenarioRanges( SCTAB nTab ) const;
1700  SC_DLLPUBLIC void CopyUpdated( ScDocument* pPosDoc, ScDocument* pDestDoc );
1703  pUndoDoc = nullptr, bool bIncludeDraw = true,
1704  bool bUpdateNoteCaptionPos = true );
1706  SC_DLLPUBLIC void UpdateTranspose( const ScAddress& rDestPos, ScDocument* pClipDoc,
1707  const ScMarkData& rMark, ScDocument* pUndoDoc );
1709  void UpdateGrow( const ScRange& rArea, SCCOL nGrowX, SCROW nGrowY );
1711  SC_DLLPUBLIC void Fill( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1712  ScProgress* pProgress, const ScMarkData& rMark,
1713  sal_uLong nFillCount, FillDir eFillDir = FILL_TO_BOTTOM,
1714  FillCmd eFillCmd = FILL_LINEAR, FillDateCmd eFillDateCmd = FILL_DAY,
1715  double nStepValue = 1.0, double nMaxValue = 1E307 );
1716  OUString GetAutoFillPreview( const ScRange& rSource, SCCOL nEndX, SCROW nEndY );
1719  const ScAddress& rCursor, const ScMarkData& rMark,
1720  double& rResult );
1722  SC_DLLPUBLIC const SfxPoolItem* GetAttr( SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich ) const;
1723  template<class T> const T* GetAttr( SCCOL nCol, SCROW nRow, SCTAB nTab, TypedWhichId<T> nWhich ) const
1724  {
1725  return static_cast<const T*>(GetAttr(nCol, nRow, nTab, sal_uInt16(nWhich)));
1726  }
1727  SC_DLLPUBLIC const SfxPoolItem* GetAttr( const ScAddress& rPos, sal_uInt16 nWhich ) const;
1728  template<class T> const T* GetAttr( const ScAddress& rPos, TypedWhichId<T> nWhich ) const
1729  {
1730  return static_cast<const T*>(GetAttr(rPos, sal_uInt16(nWhich)));
1731  }
1732  SC_DLLPUBLIC const ScPatternAttr* GetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1733  SC_DLLPUBLIC const ScPatternAttr* GetPattern( const ScAddress& rPos ) const;
1734  SC_DLLPUBLIC const ScPatternAttr* GetMostUsedPattern( SCCOL nCol, SCROW nStartRow, SCROW nEndRow, SCTAB nTab ) const;
1735  const ScPatternAttr* GetSelectionPattern( const ScMarkData& rMark );
1736  std::unique_ptr<ScPatternAttr> CreateSelectionPattern( const ScMarkData& rMark, bool bDeep = true );
1737  SC_DLLPUBLIC void AddCondFormatData( const ScRangeList& rRange, SCTAB nTab, sal_uInt32 nIndex );
1738  void RemoveCondFormatData( const ScRangeList& rRange, SCTAB nTab, sal_uInt32 nIndex );
1740  SC_DLLPUBLIC ScConditionalFormat* GetCondFormat( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1741  // pCell is an optimization, must point to rPos
1742  SC_DLLPUBLIC const SfxItemSet* GetCondResult( SCCOL nCol, SCROW nRow, SCTAB nTab,
1743  ScRefCellValue* pCell = nullptr ) const;
1744  const SfxItemSet* GetCondResult( ScRefCellValue& rCell, const ScAddress& rPos,
1745  const ScConditionalFormatList& rList,
1746  const ScCondFormatIndexes& rIndex ) const;
1747  const SfxPoolItem* GetEffItem( SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich ) const;
1748  template<class T> const T* GetEffItem( SCCOL nCol, SCROW nRow, SCTAB nTab, TypedWhichId<T> nWhich ) const
1749  {
1750  return static_cast<const T*>(GetEffItem(nCol, nRow, nTab, sal_uInt16(nWhich)));
1751  }
1753  SC_DLLPUBLIC const css::uno::Reference< css::i18n::XBreakIterator >& GetBreakIterator();
1754  bool HasStringWeakCharacters( const OUString& rString );
1755  SC_DLLPUBLIC SvtScriptType GetStringScriptType( const OUString& rString );
1756  // pCell is an optimization, must point to rPos
1757  SC_DLLPUBLIC SvtScriptType GetCellScriptType( const ScAddress& rPos, sal_uInt32 nNumberFormat,
1758  const ScRefCellValue* pCell = nullptr );
1759  // pCell is an optimization, must point to nCol,nRow,nTab
1761  const ScRefCellValue* pCell = nullptr );
1762  SvtScriptType GetRangeScriptType( sc::ColumnBlockPosition& rBlockPos, const ScAddress& rPos, SCROW nLength );
1763  SvtScriptType GetRangeScriptType( const ScRangeList& rRanges );
1765  bool HasDetectiveOperations() const;
1766  void AddDetectiveOperation( const ScDetOpData& rData );
1767  void ClearDetectiveOperations();
1768  ScDetOpList* GetDetOpList() const { return pDetOpList.get(); }
1769  void SetDetOpList(std::unique_ptr<ScDetOpList> pNew);
1771  bool HasDetectiveObjects(SCTAB nTab) const;
1773  void GetSelectionFrame( const ScMarkData& rMark,
1774  SvxBoxItem& rLineOuter,
1775  SvxBoxInfoItem& rLineInner );
1776  void ApplySelectionFrame(const ScMarkData& rMark,
1777  const SvxBoxItem& rLineOuter,
1778  const SvxBoxInfoItem* pLineInner);
1779  void ApplyFrameAreaTab(const ScRange& rRange,
1780  const SvxBoxItem& rLineOuter,
1781  const SvxBoxInfoItem& rLineInner);
1783  void ClearSelectionItems( const sal_uInt16* pWhich, const ScMarkData& rMark );
1784  void ChangeSelectionIndent( bool bIncrement, const ScMarkData& rMark );
1786  SC_DLLPUBLIC sal_uLong AddCondFormat( std::unique_ptr<ScConditionalFormat> pNew, SCTAB nTab );
1787  void DeleteConditionalFormat( sal_uLong nIndex, SCTAB nTab );
1789  void SetCondFormList( ScConditionalFormatList* pList, SCTAB nTab );
1795  const ScValidationDataList* GetValidationList() const { return pValidationList.get();}
1796  ScValidationDataList* GetValidationList() { return pValidationList.get();}
1798  SC_DLLPUBLIC void ApplyAttr( SCCOL nCol, SCROW nRow, SCTAB nTab,
1799  const SfxPoolItem& rAttr );
1800  SC_DLLPUBLIC void ApplyPattern( SCCOL nCol, SCROW nRow, SCTAB nTab,
1801  const ScPatternAttr& rAttr );
1802  SC_DLLPUBLIC void ApplyPatternArea( SCCOL nStartCol, SCROW nStartRow,
1803  SCCOL nEndCol, SCROW nEndRow,
1804  const ScMarkData& rMark, const ScPatternAttr& rAttr,
1805  ScEditDataArray* pDataArray = nullptr,
1806  bool* const pIsChanged = nullptr );
1807  SC_DLLPUBLIC void ApplyPatternAreaTab( SCCOL nStartCol, SCROW nStartRow,
1808  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab,
1809  const ScPatternAttr& rAttr );
1812  const ScMarkData& rMark,
1813  const ScPatternAttr& rPattern,
1814  SvNumFormatType nNewType );
1816  void ApplyStyle( SCCOL nCol, SCROW nRow, SCTAB nTab,
1817  const ScStyleSheet& rStyle);
1818  void ApplyStyleArea( SCCOL nStartCol, SCROW nStartRow,
1819  SCCOL nEndCol, SCROW nEndRow,
1820  const ScMarkData& rMark, const ScStyleSheet& rStyle);
1821  SC_DLLPUBLIC void ApplyStyleAreaTab( SCCOL nStartCol, SCROW nStartRow,
1822  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab,
1823  const ScStyleSheet& rStyle);
1825  SC_DLLPUBLIC void ApplySelectionStyle( const ScStyleSheet& rStyle, const ScMarkData& rMark );
1826  void ApplySelectionLineStyle( const ScMarkData& rMark,
1827  const ::editeng::SvxBorderLine* pLine, bool bColorOnly );
1829  const ScStyleSheet* GetStyle( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1830  const ScStyleSheet* GetSelectionStyle( const ScMarkData& rMark ) const;
1832  void StyleSheetChanged( const SfxStyleSheetBase* pStyleSheet, bool bRemoved,
1833  OutputDevice* pDev,
1834  double nPPTX, double nPPTY,
1835  const Fraction& rZoomX, const Fraction& rZoomY );
1837  bool IsStyleSheetUsed( const ScStyleSheet& rStyle ) const;
1839  SC_DLLPUBLIC bool ApplyFlagsTab( SCCOL nStartCol, SCROW nStartRow,
1840  SCCOL nEndCol, SCROW nEndRow,
1841  SCTAB nTab, ScMF nFlags );
1842  SC_DLLPUBLIC bool RemoveFlagsTab( SCCOL nStartCol, SCROW nStartRow,
1843  SCCOL nEndCol, SCROW nEndRow,
1844  SCTAB nTab, ScMF nFlags );
1846  SC_DLLPUBLIC void SetPattern( const ScAddress&, const ScPatternAttr& rAttr );
1847  SC_DLLPUBLIC const ScPatternAttr* SetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab, std::unique_ptr<ScPatternAttr> );
1848  SC_DLLPUBLIC void SetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab, const ScPatternAttr& rAttr );
1850  void AutoFormat( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
1851  sal_uInt16 nFormatNo, const ScMarkData& rMark );
1852  void GetAutoFormatData( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
1853  ScAutoFormatData& rData );
1854  bool SearchAndReplace( const SvxSearchItem& rSearchItem,
1855  SCCOL& rCol, SCROW& rRow, SCTAB& rTab,
1856  const ScMarkData& rMark, ScRangeList& rMatchedRanges,
1857  OUString& rUndoStr, ScDocument* pUndoDoc = nullptr );
1859  // determine Col/Row of subsequent calls
1860  // (e.g. not found from the beginning, or subsequent tables)
1861  // meaning of explanation in "()" was already unclear in German
1862  void GetSearchAndReplaceStart( const SvxSearchItem& rSearchItem,
1863  SCCOL& rCol, SCROW& rRow );
1865  bool Solver( SCCOL nFCol, SCROW nFRow, SCTAB nFTab,
1866  SCCOL nVCol, SCROW nVRow, SCTAB nVTab,
1867  const OUString& sValStr, double& nX);
1869  SC_DLLPUBLIC void ApplySelectionPattern( const ScPatternAttr& rAttr, const ScMarkData& rMark,
1870  ScEditDataArray* pDataArray = nullptr, bool* pIsChanged = nullptr );
1871  void DeleteSelection( InsertDeleteFlags nDelFlag, const ScMarkData& rMark, bool bBroadcast = true );
1872  void DeleteSelectionTab( SCTAB nTab, InsertDeleteFlags nDelFlag, const ScMarkData& rMark );
1874  SC_DLLPUBLIC void SetColWidth( SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth );
1875  SC_DLLPUBLIC void SetColWidthOnly( SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth );
1876  SC_DLLPUBLIC void SetRowHeight( SCROW nRow, SCTAB nTab, sal_uInt16 nNewHeight );
1877  SC_DLLPUBLIC void SetRowHeightRange( SCROW nStartRow, SCROW nEndRow, SCTAB nTab,
1878  sal_uInt16 nNewHeight );
1880  SC_DLLPUBLIC void SetRowHeightOnly( SCROW nStartRow, SCROW nEndRow, SCTAB nTab,
1881  sal_uInt16 nNewHeight );
1882  SC_DLLPUBLIC void SetManualHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bManual );
1884  SC_DLLPUBLIC sal_uInt16 GetColWidth( SCCOL nCol, SCTAB nTab, bool bHiddenAsZero = true ) const;
1885  SC_DLLPUBLIC sal_uLong GetColWidth( SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab ) const;
1886  SC_DLLPUBLIC sal_uInt16 GetRowHeight( SCROW nRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1887  SC_DLLPUBLIC sal_uInt16 GetRowHeight( SCROW nRow, SCTAB nTab, SCROW* pStartRow, SCROW* pEndRow ) const;
1888  SC_DLLPUBLIC sal_uLong GetRowHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1895  SCROW GetRowForHeight( SCTAB nTab, sal_uLong nHeight ) const;
1896  sal_uLong GetScaledRowHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, double fScale, const sal_uLong* pnMaxHeight = nullptr ) const;
1897  SC_DLLPUBLIC sal_uLong GetColOffset( SCCOL nCol, SCTAB nTab, bool bHiddenAsZero = true ) const;
1898  SC_DLLPUBLIC sal_uLong GetRowOffset( SCROW nRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1900  SC_DLLPUBLIC sal_uInt16 GetOriginalWidth( SCCOL nCol, SCTAB nTab ) const;
1901  SC_DLLPUBLIC sal_uInt16 GetOriginalHeight( SCROW nRow, SCTAB nTab ) const;
1903  sal_uInt16 GetCommonWidth( SCCOL nEndCol, SCTAB nTab ) const;
1905  SCROW GetHiddenRowCount( SCROW nRow, SCTAB nTab ) const;
1907  sal_uInt16 GetOptimalColWidth( SCCOL nCol, SCTAB nTab, OutputDevice* pDev,
1908  double nPPTX, double nPPTY,
1909  const Fraction& rZoomX, const Fraction& rZoomY,
1910  bool bFormula,
1911  const ScMarkData* pMarkData = nullptr,
1912  const ScColWidthParam* pParam = nullptr );
1915  SCROW nEndRow, SCTAB nTab );
1917  void UpdateAllRowHeights( sc::RowHeightContext& rCxt, const ScMarkData* pTabMark );
1919  long GetNeededSize( SCCOL nCol, SCROW nRow, SCTAB nTab,
1920  OutputDevice* pDev,
1921  double nPPTX, double nPPTY,
1922  const Fraction& rZoomX, const Fraction& rZoomY,
1923  bool bWidth, bool bTotalSize = false,
1924  bool bInPrintTwips = false );
1926  SC_DLLPUBLIC void ShowCol(SCCOL nCol, SCTAB nTab, bool bShow);
1927  SC_DLLPUBLIC void ShowRow(SCROW nRow, SCTAB nTab, bool bShow);
1928  SC_DLLPUBLIC void ShowRows(SCROW nRow1, SCROW nRow2, SCTAB nTab, bool bShow);
1929  SC_DLLPUBLIC void SetRowFlags( SCROW nRow, SCTAB nTab, CRFlags nNewFlags );
1930  SC_DLLPUBLIC void SetRowFlags( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, CRFlags nNewFlags );
1932  SC_DLLPUBLIC CRFlags GetColFlags( SCCOL nCol, SCTAB nTab ) const;
1933  SC_DLLPUBLIC CRFlags GetRowFlags( SCROW nRow, SCTAB nTab ) const;
1935  SC_DLLPUBLIC void GetAllRowBreaks(std::set<SCROW>& rBreaks, SCTAB nTab, bool bPage, bool bManual) const;
1936  SC_DLLPUBLIC void GetAllColBreaks(std::set<SCCOL>& rBreaks, SCTAB nTab, bool bPage, bool bManual) const;
1937  SC_DLLPUBLIC ScBreakType HasRowBreak(SCROW nRow, SCTAB nTab) const;
1938  SC_DLLPUBLIC ScBreakType HasColBreak(SCCOL nCol, SCTAB nTab) const;
1939  SC_DLLPUBLIC void SetRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual);
1940  SC_DLLPUBLIC void SetColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual);
1941  void RemoveRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual);
1942  void RemoveColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual);
1943  css::uno::Sequence<
1944  css::sheet::TablePageBreakData> GetRowBreakData(SCTAB nTab) const;
1946  SC_DLLPUBLIC bool RowHidden(SCROW nRow, SCTAB nTab, SCROW* pFirstRow = nullptr, SCROW* pLastRow = nullptr) const;
1947  SC_DLLPUBLIC bool HasHiddenRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1948  SC_DLLPUBLIC bool ColHidden(SCCOL nCol, SCTAB nTab, SCCOL* pFirstCol = nullptr, SCCOL* pLastCol = nullptr) const;
1949  SC_DLLPUBLIC void SetRowHidden(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bHidden);
1950  SC_DLLPUBLIC void SetColHidden(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bHidden);
1951  SC_DLLPUBLIC SCROW FirstVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1952  SC_DLLPUBLIC SCROW LastVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1953  SCROW CountVisibleRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1955  bool RowFiltered(SCROW nRow, SCTAB nTab, SCROW* pFirstRow = nullptr, SCROW* pLastRow = nullptr) const;
1956  bool HasFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1957  bool ColFiltered(SCCOL nCol, SCTAB nTab) const;
1958  SC_DLLPUBLIC void SetRowFiltered(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bFiltered);
1959  SCROW FirstNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1960  SCROW LastNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1961  SCROW CountNonFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1963  SC_DLLPUBLIC bool IsManualRowHeight(SCROW nRow, SCTAB nTab) const;
1965  bool HasUniformRowHeight( SCTAB nTab, SCROW nRow1, SCROW nRow2 ) const;
1972  void SyncColRowFlags();
1975  SC_DLLPUBLIC SCROW GetLastFlaggedRow( SCTAB nTab ) const;
1978  SCCOL GetLastChangedCol( SCTAB nTab ) const;
1980  SCROW GetLastChangedRow( SCTAB nTab ) const;
1982  SCCOL GetNextDifferentChangedCol( SCTAB nTab, SCCOL nStart) const;
1984  SCROW GetNextDifferentChangedRow( SCTAB nTab, SCROW nStart) const;
1986  // returns whether to export a Default style for this col or not
1987  // nDefault is set to one position in the current row where the Default style is
1988  void GetColDefault( SCTAB nTab, SCCOL nCol, SCROW nLastRow, SCROW& nDefault);
1990  bool UpdateOutlineCol( SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bShow );
1991  bool UpdateOutlineRow( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bShow );
1993  void StripHidden( SCCOL& rX1, SCROW& rY1, SCCOL& rX2, SCROW& rY2, SCTAB nTab );
1994  void ExtendHidden( SCCOL& rX1, SCROW& rY1, SCCOL& rX2, SCROW& rY2, SCTAB nTab );
1999  void GetUnprotectedCells( ScRangeList& rRange, SCTAB nTab ) const;
2001  // PageStyle:
2002  SC_DLLPUBLIC OUString GetPageStyle( SCTAB nTab ) const;
2003  SC_DLLPUBLIC void SetPageStyle( SCTAB nTab, const OUString& rName );
2004  Size GetPageSize( SCTAB nTab ) const;
2005  void SetPageSize( SCTAB nTab, const Size& rSize );
2006  void SetRepeatArea( SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol, SCROW nStartRow, SCROW nEndRow );
2007  void InvalidatePageBreaks(SCTAB nTab);
2008  void UpdatePageBreaks( SCTAB nTab, const ScRange* pUserArea = nullptr );
2009  void RemoveManualBreaks( SCTAB nTab );
2010  bool HasManualBreaks( SCTAB nTab ) const;
2012  bool IsPageStyleInUse( const OUString& rStrPageStyle, SCTAB* pInTab );
2013  bool RemovePageStyleInUse( const OUString& rStrPageStyle );
2014  bool RenamePageStyleInUse( const OUString& rOld, const OUString& rNew );
2015  void ModifyStyleSheet( SfxStyleSheetBase& rPageStyle,
2016  const SfxItemSet& rChanges );
2018  void PageStyleModified( SCTAB nTab, const OUString& rNewName );
2020  SC_DLLPUBLIC bool NeedPageResetAfterTab( SCTAB nTab ) const;
2022  // Was stored in PageStyle previously. Now it exists for every table:
2023  SC_DLLPUBLIC bool HasPrintRange();
2024  SC_DLLPUBLIC sal_uInt16 GetPrintRangeCount( SCTAB nTab );
2025  SC_DLLPUBLIC const ScRange* GetPrintRange( SCTAB nTab, sal_uInt16 nPos );
2029  bool IsPrintEntireSheet( SCTAB nTab ) const;
2032  SC_DLLPUBLIC void ClearPrintRanges( SCTAB nTab );
2034  SC_DLLPUBLIC void AddPrintRange( SCTAB nTab, const ScRange& rNew );
2036  SC_DLLPUBLIC void SetPrintEntireSheet( SCTAB nTab );
2037  SC_DLLPUBLIC void SetRepeatColRange( SCTAB nTab, std::unique_ptr<ScRange> pNew );
2038  SC_DLLPUBLIC void SetRepeatRowRange( SCTAB nTab, std::unique_ptr<ScRange> pNew );
2039  std::unique_ptr<ScPrintRangeSaver> CreatePrintRangeSaver() const;
2040  void RestorePrintRanges( const ScPrintRangeSaver& rSaver );
2042  SC_DLLPUBLIC tools::Rectangle GetMMRect( SCCOL nStartCol, SCROW nStartRow,
2043  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
2044  SC_DLLPUBLIC ScRange GetRange( SCTAB nTab, const tools::Rectangle& rMMRect, bool bHiddenAsZero = true ) const;
2046  void UpdStlShtPtrsFrmNms();
2047  void StylesToNames();
2049  SC_DLLPUBLIC void CopyStdStylesFrom( const ScDocument* pSrcDoc );
2051  static sal_uInt16 GetSrcVersion() { return nSrcVer; }
2053  void SetSrcCharSet( rtl_TextEncoding eNew ) { eSrcSet = eNew; }
2054  void UpdateFontCharSet();
2056  void FillInfo( ScTableInfo& rTabInfo, SCCOL nCol1, SCROW nRow1,
2057  SCCOL nCol2, SCROW nRow2, SCTAB nTab, double fColScale,
2058  double fRowScale, bool bPageMode, bool bFormulaMode,
2059  const ScMarkData* pMarkData = nullptr );
2064  void Sort( SCTAB nTab, const ScSortParam& rSortParam,
2065  bool bKeepQuery, bool bUpdateRefs,
2066  ScProgress* pProgress, sc::ReorderParam* pUndo );
2068  void Reorder( const sc::ReorderParam& rParam );
2070  SCSIZE Query( SCTAB nTab, const ScQueryParam& rQueryParam, bool bKeepSub );
2071  SC_DLLPUBLIC bool CreateQueryParam( const ScRange& rRange, ScQueryParam& rQueryParam );
2072  void GetUpperCellString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rStr);
2080  void GetFilterEntries( SCCOL nCol, SCROW nRow,
2081  SCTAB nTab, ScFilterEntries& rFilterEntries );
2083  SC_DLLPUBLIC void GetFilterEntriesArea( SCCOL nCol, SCROW nStartRow, SCROW nEndRow,
2084  SCTAB nTab, bool bCaseSens,
2085  ScFilterEntries& rFilterEntries );
2087  void GetDataEntries( SCCOL nCol, SCROW nRow, SCTAB nTab,
2088  std::vector<ScTypedStrData>& rStrings, bool bLimit = false );
2089  void GetFormulaEntries( ScTypedCaseStrSet& rStrings );
2091  bool HasAutoFilter( SCCOL nCol, SCROW nRow, SCTAB nTab );
2092  void GetFilterSelCount( SCCOL nCol, SCROW nRow, SCTAB nTab, SCSIZE& nSelected, SCSIZE& nTotal );
2094  SC_DLLPUBLIC bool HasColHeader( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
2095  SCTAB nTab );
2096  SC_DLLPUBLIC bool HasRowHeader( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
2097  SCTAB nTab );
2099  SfxPrinter* GetPrinter( bool bCreateIfNotExist = true );
2100  void SetPrinter( VclPtr<SfxPrinter> const & pNewPrinter );
2102  SC_DLLPUBLIC OutputDevice* GetRefDevice(); // WYSIWYG: Printer, otherwise VirtualDevice...
2104  bool GetNextSpellingCell( SCCOL& nCol, SCROW& nRow, SCTAB nTab,
2105  bool bInSel, const ScMarkData& rMark) const;
2107  void ReplaceStyle( const SvxSearchItem& rSearchItem,
2108  SCCOL nCol, SCROW nRow, SCTAB nTab,
2109  const ScMarkData& rMark);
2111  void InvalidateTextWidth( const OUString& rStyleName );
2112  void InvalidateTextWidth( SCTAB nTab );
2113  void InvalidateTextWidth( const ScAddress* pAdrFrom, const ScAddress* pAdrTo, bool bNumFormatChanged );
2115  bool IdleCalcTextWidth();
2117  void RepaintRange( const ScRange& rRange );
2118  void RepaintRange( const ScRangeList& rRange );
2120  bool IsIdleEnabled() const { return mbIdleEnabled; }
2121  void EnableIdle(bool bDo) { mbIdleEnabled = bDo; }
2123  bool IsDetectiveDirty() const { return bDetectiveDirty; }
2124  void SetDetectiveDirty(bool bSet) { bDetectiveDirty = bSet; }
2127  void SetLinkFormulaNeedingCheck(bool bSet) { bLinkFormulaNeedingCheck = bSet; }
2131  void SetRangeOverflowType(ErrCode nType) { nRangeOverflowType = nType; }
2132  bool HasRangeOverflow() const { return nRangeOverflowType != ERRCODE_NONE; }
2135  // for broadcasting/listening
2136  void SetInsertingFromOtherDoc( bool bVal ) { bInsertingFromOtherDoc = bVal; }
2138  void SetLoadingMedium( bool bVal );
2139  SC_DLLPUBLIC void SetImportingXML( bool bVal );
2140  bool IsImportingXML() const { return bImportingXML; }
2141  bool IsCalcingAfterLoad() const { return bCalcingAfterLoad; }
2142  void SetNoListening( bool bVal ) { bNoListening = bVal; }
2143  bool GetNoListening() const { return bNoListening; }
2144  ScBroadcastAreaSlotMachine* GetBASM() const { return pBASM.get(); }
2146  SC_DLLPUBLIC ScChartListenerCollection* GetChartListenerCollection() const { return pChartListenerCollection.get(); }
2147  void SetChartListenerCollection( std::unique_ptr<ScChartListenerCollection>,
2148  bool bSetChartRangeLists );
2149  void UpdateChart( const OUString& rName );
2150  void RestoreChartListener( const OUString& rName );
2153  void SetChartListenerCollectionNeedsUpdate( bool bFlg ) { bChartListenerCollectionNeedsUpdate = bFlg; }
2154  void AddOLEObjectToCollection(const OUString& rName);
2156  ScChangeViewSettings* GetChangeViewSettings() const { return pChangeViewSettings.get(); }
2159  const std::shared_ptr<SvxForbiddenCharactersTable>& GetForbiddenCharacters() const;
2160  void SetForbiddenCharacters(const std::shared_ptr<SvxForbiddenCharactersTable>& rNew);
2163  bool IsValidAsianCompression() const;
2166  bool GetAsianKerning() const;
2167  bool IsValidAsianKerning() const;
2168  void SetAsianKerning(bool bNew);
2171  EEHorizontalTextDirection GetEditTextDirection(SCTAB nTab) const; // EEHorizontalTextDirection values
2174  void SetLinkMode( ScLkUpdMode nSet ) { eLinkMode = nSet;}
2178  void FillMatrix( ScMatrix& rMat, SCTAB nTab, SCCOL nCol1,
2179  SCROW nRow1, SCCOL nCol2, SCROW nRow2,
2180  svl::SharedStringPool* pPool = nullptr) const;
2190  void SC_DLLPUBLIC SetFormulaResults( const ScAddress& rTopPos, const double* pResults, size_t nLen );
2192  const ScDocumentThreadSpecific& CalculateInColumnInThread( ScInterpreterContext& rContext, const ScRange& rCalcRange, unsigned nThisThread, unsigned nThreadsTotal);
2193  void HandleStuffAfterParallelCalculation( SCCOL nColStart, SCCOL nColEnd, SCROW nRow, size_t nLen, SCTAB nTab, ScInterpreter* pInterpreter );
2200  void TransferCellValuesTo( const ScAddress& rTopPos, size_t nLen, sc::CellValues& rDest );
2201  void CopyCellValuesFrom( const ScAddress& rTopPos, const sc::CellValues& rSrc );
2203  std::set<Color> GetDocColors();
2206 private:
2207  ScDocument(const ScDocument& r) = delete;
2209  void FindMaxRotCol( SCTAB nTab, RowInfo* pRowInfo, SCSIZE nArrCount,
2210  SCCOL nX1, SCCOL nX2 ) const;
2212  sal_uInt16 RowDifferences( SCROW nThisRow, SCTAB nThisTab,
2213  ScDocument& rOtherDoc,
2214  SCROW nOtherRow, SCTAB nOtherTab,
2215  SCCOL nMaxCol, const SCCOLROW* pOtherCols );
2216  sal_uInt16 ColDifferences( SCCOL nThisCol, SCTAB nThisTab,
2217  ScDocument& rOtherDoc,
2218  SCCOL nOtherCol, SCTAB nOtherTab,
2219  SCROW nMaxRow, const SCCOLROW* pOtherRows );
2220  void FindOrder( SCCOLROW* pOtherRows, SCCOLROW nThisEndRow, SCCOLROW nOtherEndRow,
2221  bool bColumns,
2222  ScDocument& rOtherDoc, SCTAB nThisTab, SCTAB nOtherTab,
2223  SCCOLROW nEndCol, const SCCOLROW* pTranslate,
2224  ScProgress* pProgress, sal_uLong nProAdd );
2226  DECL_LINK(TrackTimeHdl, Timer *, void);
2245  bool LimitRangeToAvailableSheets( const ScRange& rRange, ScRange& o_rRange,
2246  bool& o_bEntirelyOutOfBounds ) const;
2248 public:
2249  void StartListeningArea( const ScRange& rRange, bool bGroupListening, SvtListener* pListener );
2251  void EndListeningArea( const ScRange& rRange, bool bGroupListening, SvtListener* pListener );
2257  void Broadcast( const ScHint& rHint );
2259  void BroadcastCells( const ScRange& rRange, SfxHintId nHint, bool bBroadcastSingleBroadcasters = true );
2262  void AreaBroadcast( const ScHint& rHint );
2263  void DelBroadcastAreasInRange( const ScRange& rRange );
2264  void UpdateBroadcastAreas( UpdateRefMode eUpdateRefMode,
2265  const ScRange& rRange,
2266  SCCOL nDx, SCROW nDy, SCTAB nDz );
2268  void StartListeningCell( const ScAddress& rAddress,
2269  SvtListener* pListener );
2270  void EndListeningCell( const ScAddress& rAddress,
2271  SvtListener* pListener );
2273  void StartListeningCell( sc::StartListeningContext& rCxt, const ScAddress& rPos, SvtListener& rListener );
2274  void EndListeningCell( sc::EndListeningContext& rCxt, const ScAddress& rPos, SvtListener& rListener );
2276  void EndListeningFormulaCells( std::vector<ScFormulaCell*>& rCells );
2278  void PutInFormulaTree( ScFormulaCell* pCell );
2279  void RemoveFromFormulaTree( ScFormulaCell* pCell );
2294  SC_DLLPUBLIC void CalcFormulaTree( bool bOnlyForced = false, bool bProgressBar = true, bool bSetAllDirty = true );
2295  void ClearFormulaTree();
2296  void AppendToFormulaTrack( ScFormulaCell* pCell );
2297  void RemoveFromFormulaTrack( ScFormulaCell* pCell );
2298  void TrackFormulas( SfxHintId nHintId = SfxHintId::ScDataChanged );
2301  void FinalTrackFormulas( SfxHintId nHintId );
2303  bool IsInFormulaTree( const ScFormulaCell* pCell ) const;
2304  bool IsInFormulaTrack( const ScFormulaCell* pCell ) const;
2306  void SetHardRecalcState( HardRecalcState eVal ) { eHardRecalcState = eVal; }
2307  void StartAllListeners();
2308  void StartNeededListeners();
2309  void StartNeededListeners( const std::shared_ptr<const sc::ColumnSet>& rpColSet );
2310  void StartAllListeners( const ScRange& rRange );
2312  void SetForcedFormulas( bool bVal ) { bHasForcedFormulas = bVal; }
2315  bool IsInInterpreter() const { return nInterpretLevel != 0; }
2318  {
2320  if ( nInterpretLevel < USHRT_MAX )
2321  nInterpretLevel++;
2322  }
2324  {
2326  if ( nInterpretLevel )
2327  nInterpretLevel--;
2328  }
2329  sal_uInt16 GetMacroInterpretLevel() const { return nMacroInterpretLevel; }
2331  {
2333  if ( nMacroInterpretLevel < USHRT_MAX )
2334  nMacroInterpretLevel++;
2335  }
2337  {
2339  if ( nMacroInterpretLevel )
2340  nMacroInterpretLevel--;
2341  }
2342  bool IsInInterpreterTableOp() const { return nInterpreterTableOpLevel != 0; }
2344  {
2345  if ( nInterpreterTableOpLevel < USHRT_MAX )
2346  nInterpreterTableOpLevel++;
2347  }
2349  {
2350  if ( nInterpreterTableOpLevel )
2351  nInterpreterTableOpLevel--;
2352  }
2354  // add a formula to be remembered for TableOp broadcasts
2356  void InvalidateLastTableOpParams() { aLastTableOpParams.bValid = false; }
2358  bool IsInDtorClear() const { return bInDtorClear; }
2359  void SetExpandRefs( bool bVal );
2360  bool IsExpandRefs() const { return bExpandRefs; }
2364  {
2365  if ( nXMLImportedFormulaCount + nVal > nXMLImportedFormulaCount )
2366  nXMLImportedFormulaCount += nVal;
2367  }
2369  {
2370  if ( nVal <= nXMLImportedFormulaCount )
2371  nXMLImportedFormulaCount -= nVal;
2372  else
2373  nXMLImportedFormulaCount = 0;
2374  }
2376  void StartTrackTimer();
2378  void CompileDBFormula();
2379  void CompileColRowNameFormula();
2385  sal_Int32 GetMaxStringLen( SCTAB nTab, SCCOL nCol,
2386  SCROW nRowStart, SCROW nRowEnd,
2387  rtl_TextEncoding eCharSet ) const;
2391  sal_Int32 GetMaxNumberStringLen( sal_uInt16& nPrecision,
2392  SCTAB nTab, SCCOL nCol,
2393  SCROW nRowStart, SCROW nRowEnd ) const;
2395  void KeyInput(); // TimerDelays etc.
2397  ScChangeTrack* GetChangeTrack() const { return pChangeTrack.get(); }
2401  SC_DLLPUBLIC void SetChangeTrack( std::unique_ptr<ScChangeTrack> pTrack );
2403  void StartChangeTracking();
2404  void EndChangeTracking();
2406  SC_DLLPUBLIC void CompareDocument( ScDocument& rOtherDoc );
2408  void AddUnoObject( SfxListener& rObject );
2409  void RemoveUnoObject( SfxListener& rObject );
2410  void BroadcastUno( const SfxHint &rHint );
2411  void AddUnoListenerCall( const css::uno::Reference<
2412  css::util::XModifyListener >& rListener,
2413  const css::lang::EventObject& rEvent );
2415  void SetInLinkUpdate(bool bSet); // TableLink or AreaLink
2416  bool IsInLinkUpdate() const; // including DdeLink
2423  std::unique_ptr<ScRefreshTimerControl> const & GetRefreshTimerControlAddress() const
2424  { return pRefreshTimerControl; }
2426  void SetPastingDrawFromOtherDoc( bool bVal )
2427  { bPastingDrawFromOtherDoc = bVal; }
2429  { return bPastingDrawFromOtherDoc; }
2432  sal_uInt32 GetDocumentID() const;
2434  void InvalidateStyleSheetUsage() { bStyleSheetUsageInvalid = true; }
2435  void SC_DLLPUBLIC GetSortParam( ScSortParam& rParam, SCTAB nTab );
2436  void SC_DLLPUBLIC SetSortParam( const ScSortParam& rParam, SCTAB nTab );
2438  void SetVbaEventProcessor( const css::uno::Reference< css::script::vba::XVBAEventProcessor >& rxVbaEvents )
2439  { mxVbaEvents = rxVbaEvents; }
2440  const css::uno::Reference< css::script::vba::XVBAEventProcessor >& GetVbaEventProcessor() const { return mxVbaEvents; }
2447  bool IsInVBAMode() const;
2450  void AddSubTotalCell(ScFormulaCell* pCell);
2451  void RemoveSubTotalCell(ScFormulaCell* pCell);
2452  void SetSubTotalCellsDirty(const ScRange& rDirtyRange);
2454  sal_uInt16 GetTextWidth( const ScAddress& rPos ) const;
2456  SvtScriptType GetScriptType( const ScAddress& rPos ) const;
2457  void SetScriptType( const ScAddress& rPos, SvtScriptType nType );
2458  void UpdateScriptTypes( const ScAddress& rPos, SCCOL nColSize, SCROW nRowSize );
2460  size_t GetFormulaHash( const ScAddress& rPos ) const;
2472  void UnshareFormulaCells( SCTAB nTab, SCCOL nCol, std::vector<SCROW>& rRows );
2473  void RegroupFormulaCells( SCTAB nTab, SCCOL nCol );
2474  void RegroupFormulaCells( const ScRange& range );
2482  bool HandleRefArrayForParallelism( const ScAddress& rPos, SCROW nLength, const ScFormulaCellGroupRef& mxGroup );
2483 #ifdef DBG_UTIL
2484  void AssertNoInterpretNeeded( const ScAddress& rPos, SCROW nLength );
2485 #endif
2491  void PrepareFormulaCalc();
2507  SC_DLLPUBLIC bool EnsureFormulaCellResults( const ScRange& rRange, bool bSkipRunning = false );
2509  SvtBroadcaster* GetBroadcaster( const ScAddress& rPos );
2510  const SvtBroadcaster* GetBroadcaster( const ScAddress& rPos ) const;
2511  void DeleteBroadcasters( sc::ColumnBlockPosition& rBlockPos, const ScAddress& rTopPos, SCROW nLength );
2513  std::unique_ptr<sc::ColumnIterator> GetColumnIterator( SCTAB nTab, SCCOL nCol, SCROW nRow1, SCROW nRow2 ) const;
2514  void CreateColumnIfNotExists( SCTAB nTab, SCCOL nCol );
2516  SC_DLLPUBLIC void StoreTabToCache(SCTAB nTab, SvStream& rStrm) const;
2517  SC_DLLPUBLIC void RestoreTabFromCache(SCTAB nTab, SvStream& rStream);
2520  SC_DLLPUBLIC void DumpColumnStorage( SCTAB nTab, SCCOL nCol ) const;
2521 #endif
2524  SC_DLLPUBLIC void DumpAreaBroadcasters() const;
2525 #endif
2527  SC_DLLPUBLIC void SetCalcConfig( const ScCalcConfig& rConfig );
2528  const ScCalcConfig& GetCalcConfig() const { return maCalcConfig; }
2529  void ConvertFormulaToValue( const ScRange& rRange, sc::TableValues* pUndo );
2530  void SwapNonEmpty( sc::TableValues& rValues );
2531  void finalizeOutlineImport();
2532  bool TableExists( SCTAB nTab ) const;
2534  SC_DLLPUBLIC ScColumnsRange GetColumnsRange(SCTAB nTab, SCCOL nColBegin, SCCOL nColEnd) const;
2536  bool IsInDocShellRecalc() const { return mbDocShellRecalc; }
2537  void SetDocShellRecalc(bool bSet) { mbDocShellRecalc = bSet; }
2547  OString dumpSheetGeomData(SCTAB nTab, bool bColumns, SheetGeomType eGeomType);
2549  SCCOL GetLOKFreezeCol(SCTAB nTab) const;
2550  SCROW GetLOKFreezeRow(SCTAB nTab) const;
2551  bool SetLOKFreezeCol(SCCOL nFreezeCol, SCTAB nTab);
2552  bool SetLOKFreezeRow(SCROW nFreezeRow, SCTAB nTab);
2554 private:
2562  {
2563  public:
2564  explicit NumFmtMergeHandler(ScDocument* pDoc, const ScDocument* pSrcDoc);
2567  private:
2569  };
2571  ScTable* FetchTable( SCTAB nTab );
2572  const ScTable* FetchTable( SCTAB nTab ) const;
2574  void MergeNumberFormatter(const ScDocument* pSrcDoc);
2576  void ImplCreateOptions(); // Suggestion: switch to on-demand?
2577  void ImplDeleteOptions();
2579  void DeleteDrawLayer();
2580  SC_DLLPUBLIC bool DrawGetPrintArea( ScRange& rRange, bool bSetHor, bool bSetVer ) const;
2582  void UpdateDrawPrinter();
2583  void UpdateDrawLanguages();
2584  SC_DLLPUBLIC void InitClipPtrs( ScDocument* pSourceDoc );
2586  void LoadDdeLinks(SvStream& rStream);
2587  void SaveDdeLinks(SvStream& rStream) const;
2589  void DeleteAreaLinksOnTab( SCTAB nTab );
2590  void UpdateRefAreaLinks( UpdateRefMode eUpdateRefMode,
2591  const ScRange& r, SCCOL nDx, SCROW nDy, SCTAB nDz );
2593  void CopyRangeNamesToClip(ScDocument* pClipDoc, const ScRange& rClipRange, const ScMarkData* pMarks);
2595  bool HasPartOfMerged( const ScRange& rRange );
2597  ScRefCellValue GetRefCellValue( const ScAddress& rPos );
2600  std::map< SCTAB, ScSortParam > mSheetSortParams;
2602  SCSIZE GetPatternCount( SCTAB nTab, SCCOL nCol ) const;
2603  SCSIZE GetPatternCount( SCTAB nTab, SCCOL nCol, SCROW nRow1, SCROW nRow2 ) const;
2604  void ReservePatternCount( SCTAB nTab, SCCOL nCol, SCSIZE nReserve );
2606  void SharePooledResources( const ScDocument* pSrcDoc );
2609  sc::EndListeningContext& rCxt, const ScAddress& rPos, std::vector<ScAddress>* pGroupPos );
2612  sc::EndListeningContext& rCxt, const ScRange& rRange, std::vector<ScAddress>* pGroupPos );
2614  void EndListeningGroups( const std::vector<ScAddress>& rPosArray );
2615  void SetNeedsListeningGroups( const std::vector<ScAddress>& rPosArray );
2616 };
2618 typedef std::unique_ptr<ScDocument, o3tl::default_delete<ScDocument>> ScDocumentUniquePtr;
2626 {
2628  {
2629 #ifndef NDEBUG
2630  mpDocument = pDocument;
2631  mnFlagRestore = pDocument->mnMutationGuardFlags;
2632  assert((mnFlagRestore & nFlags) == 0);
2633  mpDocument->mnMutationGuardFlags |= static_cast<size_t>(nFlags);
2634 #else
2635  (void)pDocument; (void)nFlags;
2636 #endif
2637  }
2638 #ifndef NDEBUG
2640  {
2642  }
2645 #endif
2646 };
2658 {
2660  {
2661 #ifndef NDEBUG
2662  mpDocument = pDocument;
2663  mnFlags = static_cast<size_t>(nFlags);
2665 #else
2666  (void)pDocument; (void)nFlags;
2667 #endif
2668  }
2669 #ifndef NDEBUG
2671  {
2673  }
2674  size_t mnFlags;
2676 #endif
2678 };
2681 {
2684 public:
2686  : mrDoc(rDoc)
2687  {
2688  assert(!mrDoc.IsInDocShellRecalc());
2689  mrDoc.SetDocShellRecalc(true);
2690  }
2693  {
2694  mrDoc.SetDocShellRecalc(false);
2695  }
2696 };
2698 #endif
2700 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
SC_DLLPUBLIC void UpdateTranspose(const ScAddress &rDestPos, ScDocument *pClipDoc, const ScMarkData &rMark, ScDocument *pUndoDoc)
Definition: documen3.cxx:1090
exports util
void FillTabMarked(SCTAB nSrcTab, const ScMarkData &rMark, InsertDeleteFlags nFlags, ScPasteFunc nFunction, bool bSkipEmpty, bool bAsLink)
Definition: document.cxx:3298
SC_DLLPUBLIC OUString GetLinkDoc(SCTAB nTab) const
Definition: documen3.cxx:492
SC_DLLPUBLIC bool IsDocProtected() const
Definition: documen3.cxx:1860
void AddDelayedFormulaGroupingCell(const ScFormulaCell *cell)
To be used only by SharedFormulaUtil::joinFormulaCells().
Definition: document10.cxx:392
SC_DLLPUBLIC bool GetPrintArea(SCTAB nTab, SCCOL &rEndCol, SCROW &rEndRow, bool bNotes=true) const
Definition: documen2.cxx:573
void SetThreadedGroupCalcInProgress(bool set)
Definition: document.hxx:627
Matrix data type that can store values of mixed types.
Definition: scmatrix.hxx:113
bool IsInFormulaTree(const ScFormulaCell *pCell) const
Definition: documen7.cxx:321
bool GetNextMarkedCell(SCCOL &rCol, SCROW &rRow, SCTAB nTab, const ScMarkData &rMark)
Definition: documen4.cxx:539
OUString GetLinkOpt(SCTAB nTab) const
Definition: documen3.cxx:506
SC_DLLPUBLIC const ScPatternAttr * GetMostUsedPattern(SCCOL nCol, SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4752
bool mbEmbedFontScriptComplex
Definition: document.hxx:569
SC_DLLPUBLIC const css::uno::Reference< css::i18n::XBreakIterator > & GetBreakIterator()
Definition: documen6.cxx:40
void BeginDrawUndo()
Definition: documen9.cxx:58
bool IsInDocShellRecalc() const
Definition: document.hxx:2536
void ClearDetectiveOperations()
Definition: documen4.cxx:898
void RemoveMerge(SCCOL nCol, SCROW nRow, SCTAB nTab)
Definition: documen3.cxx:2050
ScCalcConfig maCalcConfig
Definition: document.hxx:374
bool IsBlockEditable(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool *pOnlyNotBecauseOfMatrix=nullptr, bool bNoMatrixAtAll=false) const
Definition: document.cxx:5329
void AssertNoInterpretNeeded(const ScAddress &rPos, SCROW nLength)
Definition: document.cxx:1806
SC_DLLPUBLIC ScDPObject * GetDPAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: documen3.cxx:358
SC_DLLPUBLIC void ShowCol(SCCOL nCol, SCTAB nTab, bool bShow)
Definition: document.cxx:4300
void FillInfo(ScTableInfo &rTabInfo, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, SCTAB nTab, double fColScale, double fRowScale, bool bPageMode, bool bFormulaMode, const ScMarkData *pMarkData=nullptr)
Definition: fillinfo.cxx:346
bool IsValidAsianKerning() const
Definition: documen9.cxx:647
bool CanFitBlock(const ScRange &rOld, const ScRange &rNew)
Definition: document.cxx:1830
std::shared_ptr< SvxForbiddenCharactersTable > xForbiddenCharacters
Definition: document.hxx:409
constexpr double nPPTY
void DeleteCol(SCROW nStartRow, SCTAB nStartTab, SCROW nEndRow, SCTAB nEndTab, SCCOL nStartCol, SCSIZE nSize, ScDocument *pRefUndoDoc=nullptr, bool *pUndoOutline=nullptr, const ScMarkData *pTabMark=nullptr)
Definition: document.cxx:1585
void IncInDdeLinkUpdate()
Definition: document.hxx:1021
std::unique_ptr< ScFieldEditEngine > mpEditEngine
Definition: document.hxx:377
void EnableIdle(bool bDo)
Definition: document.hxx:2121
void ClearLookupCaches()
Zap all caches.
Definition: documen2.cxx:1198
void UpdatePageBreaks(SCTAB nTab, const ScRange *pUserArea=nullptr)
Definition: document.cxx:6223
static SC_DLLPUBLIC bool bThreadedGroupCalcInProgress
Calc's threaded group calculation is in progress.
Definition: global.hxx:817
SC_DLLPUBLIC void ApplySelectionStyle(const ScStyleSheet &rStyle, const ScMarkData &rMark)
Definition: document.cxx:4861
VclPtr< SfxPrinter > mpPrinter
Definition: document.hxx:380
bool HasExternalRefManager() const
Definition: document.hxx:1006
bool bIsUndo
Definition: document.hxx:502
void ApplyStyle(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScStyleSheet &rStyle)
Definition: document.cxx:4831
void DeleteRow(SCCOL nStartCol, SCTAB nStartTab, SCCOL nEndCol, SCTAB nEndTab, SCROW nStartRow, SCSIZE nSize, ScDocument *pRefUndoDoc=nullptr, bool *pUndoOutline=nullptr, const ScMarkData *pTabMark=nullptr)
Definition: document.cxx:1366
bool RefreshAutoFilter(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: document.cxx:5674
bool bStyleSheetUsageInvalid
Definition: document.hxx:552
void ExtendHidden(SCCOL &rX1, SCROW &rY1, SCCOL &rX2, SCROW &rY2, SCTAB nTab)
Definition: document.cxx:4708
void StripHidden(SCCOL &rX1, SCROW &rY1, SCCOL &rX2, SCROW &rY2, SCTAB nTab)
Definition: document.cxx:4702
void ClearSelectionItems(const sal_uInt16 *pWhich, const ScMarkData &rMark)
Definition: document.cxx:5922
sal_uLong GetXMLImportedFormulaCount() const
Definition: document.hxx:2362
::boost::intrusive_ptr< ScFormulaCellGroup > ScFormulaCellGroupRef
Definition: types.hxx:44
SCCOL SanitizeCol(SCCOL nCol) const
Definition: document.hxx:884
SC_DLLPUBLIC void ApplyStyleAreaTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, const ScStyleSheet &rStyle)
Definition: document.cxx:4853
ScFormulaCell * pFormulaTree
Definition: document.hxx:394
SC_DLLPUBLIC bool HasColHeader(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: documen3.cxx:1489
void FitBlock(const ScRange &rOld, const ScRange &rNew, bool bClear=true)
Definition: document.cxx:1861
SC_DLLPUBLIC const ScRange * GetRepeatColRange(SCTAB nTab)
Definition: document.cxx:6289
SC_DLLPUBLIC ScDBCollection * GetDBCollection() const
Definition: document.hxx:819
void DeleteConditionalFormat(sal_uLong nIndex, SCTAB nTab)
Definition: documen4.cxx:879
SC_DLLPUBLIC void ShowRows(SCROW nRow1, SCROW nRow2, SCTAB nTab, bool bShow)
Definition: document.cxx:4312
SfxItemSet * GetPreviewFont()
Definition: document.hxx:1343
void GetClipStart(SCCOL &nClipX, SCROW &nClipY)
Definition: document.cxx:3172
void IncXMLImportedFormulaCount(sal_uLong nVal)
Definition: document.hxx:2363
bool HasScenarioRange(SCTAB nTab, const ScRange &rRange) const
Definition: documen3.cxx:845
bool HasUnoRefUndo() const
Definition: document.hxx:1068
void EndChangeTracking()
Definition: documen2.cxx:267
SC_DLLPUBLIC void ApplyPatternIfNumberformatIncompatible(const ScRange &rRange, const ScMarkData &rMark, const ScPatternAttr &rPattern, SvNumFormatType nNewType)
Definition: document.cxx:4796
SC_DLLPUBLIC void SetScenario(SCTAB nTab, bool bFlag)
Definition: documen3.cxx:407
SC_DLLPUBLIC bool GetDataStart(SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow) const
Definition: documen2.cxx:641
std::unique_ptr< ScChangeTrack > pChangeTrack
Definition: document.hxx:402
SC_DLLPUBLIC svl::SharedStringPool & GetSharedStringPool()
Definition: documen2.cxx:563
void SetForcedFormulas(bool bVal)
Definition: document.hxx:2312
sal_uLong nFormulaCount
Definition: document.hxx:279
void SetConsolidateDlgData(std::unique_ptr< ScConsolidateParam > pData)
Definition: documen2.cxx:1104
SC_DLLPUBLIC bool IsTabProtected(SCTAB nTab) const
Definition: documen3.cxx:1871
SC_DLLPUBLIC void GetInputString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rString)
Definition: document.cxx:3542
todo: It should be possible to have MarkArrays for each table, in order to enable "search all" across...
Definition: markdata.hxx:43
void InvalidateTextWidth(const OUString &rStyleName)
Definition: documen8.cxx:295
std::unique_ptr< ScPatternAttr > CreateSelectionPattern(const ScMarkData &rMark, bool bDeep=true)
Definition: document.cxx:5058
Store parameters used in the ScDocument::SetString() method.
Definition: stringutil.hxx:35
SC_DLLPUBLIC bool HasPrintRange()
Definition: document.cxx:6252
sal_uInt16 nInterpretLevel
Definition: document.hxx:471
void HandleStuffAfterParallelCalculation(SCCOL nColStart, SCCOL nColEnd, SCROW nRow, size_t nLen, SCTAB nTab, ScInterpreter *pInterpreter)
Definition: documen8.cxx:429
SC_DLLPUBLIC CRFlags GetColFlags(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4330
VclPtr< VirtualDevice > mpVirtualDevice_100th_mm
Definition: document.hxx:381
SC_DLLPUBLIC sal_uLong TransferTab(ScDocument *pSrcDoc, SCTAB nSrcPos, SCTAB nDestPos, bool bInsertNew=true, bool bResultsOnly=false)
Definition: documen2.cxx:906
void SetEmbedUsedFontsOnly(bool bUse)
Definition: document.hxx:591
bool IsInInterpreter() const
Definition: document.hxx:2315
bool bChartListenerCollectionNeedsUpdate
Definition: document.hxx:518
void LoadDdeLinks(SvStream &rStream)
Definition: documen8.cxx:745
void SetCutMode(bool bCut)
Definition: document.cxx:2054
Definition: global.hxx:193
SC_DLLPUBLIC bool IsNegativePage(SCTAB nTab) const
Definition: document.cxx:1001
NumFmtMergeHandler(ScDocument *pDoc, const ScDocument *pSrcDoc)
Definition: document.cxx:2438
Use this to lock all charts in the calc for a little time.
Definition: chartlock.hxx:53
ScUnoListenerCalls stores notifications to XModifyListener that can't be processed during BroadcastUn...
bool IsEnabledDelayStartListeningFormulaCells(ScColumn *column) const
Definition: document10.cxx:422
bool mbUndoEnabled
Definition: document.hxx:554
bool bInDtorClear
Definition: document.hxx:522
void SC_DLLPUBLIC SetFormulaResults(const ScAddress &rTopPos, const double *pResults, size_t nLen)
Set an array of numerical formula results to a group of contiguous formula cells. ...
Definition: documen8.cxx:402
ScValidationDataList * GetValidationList()
Definition: document.hxx:1796
SC_DLLPUBLIC ScRangeName * GetRangeName() const
Definition: documen3.cxx:176
ScInterpreterContext & GetThreadedContext() const
Definition: document.hxx:621
SCTAB nVisibleTab
Definition: document.hxx:488
OUString maFileURL
Definition: document.hxx:427
void SetEmbedFontScriptComplex(bool bUse)
Definition: document.hxx:594
std::unique_ptr< ScRefreshTimerControl > const & GetRefreshTimerControlAddress() const
Definition: document.hxx:2423
bool UpdateOutlineCol(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bShow)
Adapt Outline.
Definition: documen3.cxx:1384
SC_DLLPUBLIC void SetChangeViewSettings(const ScChangeViewSettings &rNew)
Definition: documen2.cxx:1109
void SetPreviewSelection(const ScMarkData &rSel)
Definition: documen2.cxx:1363
SCSIZE Query(SCTAB nTab, const ScQueryParam &rQueryParam, bool bKeepSub)
Definition: documen3.cxx:1427
SC_DLLPUBLIC void SetTabProtection(SCTAB nTab, const ScTableProtection *pProtect)
Definition: documen3.cxx:1888
const OUString & GetFileURL() const
Definition: document.hxx:609
void CopyCellToDocument(const ScAddress &rSrcPos, const ScAddress &rDestPos, ScDocument &rDestDoc)
Copy only cell, nothing but cell to another document.
Definition: document.cxx:2265
SC_DLLPUBLIC void DoMergeContents(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow)
Definition: documen3.cxx:1996
Definition: global.hxx:318
void SetSheetEvents(SCTAB nTab, std::unique_ptr< ScSheetEvents > pNew)
Definition: documen3.cxx:647
const css::uno::Reference< css::script::vba::XVBAEventProcessor > & GetVbaEventProcessor() const
Definition: document.hxx:2440
void CopyFromClip(const ScRange &rDestRange, const ScMarkData &rMark, InsertDeleteFlags nInsFlag, ScDocument *pRefUndoDoc, ScDocument *pClipDoc, bool bResetCut=true, bool bAsLink=false, bool bIncludeFiltered=true, bool bSkipAttrForEmpty=false, const ScRangeList *pDestRanges=nullptr)
If pDestRanges is given it overrides rDestRange, rDestRange in this case is the overall encompassing ...
Definition: document.cxx:2800
SCROW FirstNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4533
ScTable * FetchTable(SCTAB nTab)
Definition: document.cxx:2507
void SetAsianKerning(bool bNew)
Definition: documen9.cxx:660
void RegroupFormulaCells(SCTAB nTab, SCCOL nCol)
Definition: document10.cxx:361
void SetRepeatArea(SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol, SCROW nStartRow, SCROW nEndRow)
Definition: document.cxx:6211
Provides methods to allow direct shifting of document content without broadcasting or shifting of bro...
void ReservePatternCount(SCTAB nTab, SCCOL nCol, SCSIZE nReserve)
Definition: documen3.cxx:2089
void LimitChartIfAll(ScRangeListRef &rRangeList)
Definition: document.cxx:1122
SC_DLLPUBLIC bool IsActiveScenario(SCTAB nTab) const
Definition: documen3.cxx:858
SC_DLLPUBLIC void SetAnonymousDBData(SCTAB nTab, std::unique_ptr< ScDBData > pDBData)
Definition: document.cxx:318
std::unique_ptr< ScClipParam > mpClipParam
Definition: document.hxx:416
void SetInLinkUpdate(bool bSet)
Definition: documen8.cxx:774
sheet protection state container
std::unique_ptr< ScFieldEditEngine > pCacheFieldEditEngine
Definition: document.hxx:413
SC_DLLPUBLIC void SetTabBgColor(SCTAB nTab, const Color &rColor)
Definition: documen3.cxx:436
SfxObjectShell * mpShell
Definition: document.hxx:379
ScRangePairList * GetColNameRanges()
Definition: document.hxx:811
SC_DLLPUBLIC void SetDrawPageSize(SCTAB nTab)
Definition: documen9.cxx:193
SC_DLLPUBLIC bool InsertTabs(SCTAB nPos, const std::vector< OUString > &rNames, bool bNamesValid=false)
Definition: document.cxx:591
ScInterpreterContext maInterpreterContext
Definition: document.hxx:481
SC_DLLPUBLIC const ScFormulaCell * GetFormulaCell(const ScAddress &rPos) const
Definition: document.cxx:3725
Think of this as a mini-ScColumn like storage that only stores cell values in a column.
Definition: cellvalues.hxx:42
Definition: global.hxx:236
bool IsAddressInRangeName(RangeNameScope eScope, const ScAddress &rAddress)
Definition: documen3.cxx:196
void CopyScenario(SCTAB nSrcTab, SCTAB nDestTab, bool bNewScenario=false)
Definition: documen3.cxx:789
SC_DLLPUBLIC sal_uLong GetFormulaGroupCount() const
Definition: document.cxx:6150
bool IsExpandRefs() const
Definition: document.hxx:2360
bool IsEmbedFontScriptLatin() const
Definition: document.hxx:586
void FillMatrix(ScMatrix &rMat, SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, svl::SharedStringPool *pPool=nullptr) const
Definition: documen8.cxx:384
void CompileColRowNameFormula()
Definition: documen4.cxx:566
SC_DLLPUBLIC void TransposeClip(ScDocument *pTransClip, InsertDeleteFlags nFlags, bool bAsLink)
Definition: document.cxx:2330
ScDetOpList * GetDetOpList() const
Definition: document.hxx:1768
SC_DLLPUBLIC bool IsUserInteractionEnabled() const
Definition: document.hxx:1545
SCROW GetLOKFreezeRow(SCTAB nTab) const
sc::IconSetBitmapMap & GetIconSetBitmapMap()
Definition: documen2.cxx:1389
SC_DLLPUBLIC bool HasTabNotes(SCTAB nTab) const
Definition: document.cxx:6568
sal_uIntPtr sal_uLong
SC_DLLPUBLIC void CompileHybridFormula()
Call this immediately after updating named ranges.
Definition: document10.cxx:316
bool ValidRange(const ScRange &rRange) const
Definition: document.hxx:882
bool mbUserInteractionEnabled
Definition: document.hxx:558
Context for reference update during shifting, moving or copying of cell ranges.
SC_DLLPUBLIC std::vector< OUString > GetAllTableNames() const
Definition: document.cxx:286
SC_DLLPUBLIC bool ValidNewTabName(const OUString &rName) const
Definition: document.cxx:373
const sal_uInt8 SC_DDE_DEFAULT
Definition: document.hxx:291
SC_DLLPUBLIC void ClearPrintRanges(SCTAB nTab)
Removes all print ranges.
Definition: document.cxx:6305
void SetName(const OUString &r)
Definition: document.hxx:606
SC_DLLPUBLIC bool ApplyFlagsTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, ScMF nFlags)
Definition: document.cxx:5014
Enumeration to determine which pieces of the code should not be mutated when set. ...
Definition: document.hxx:316
SC_DLLPUBLIC bool InitColumnBlockPosition(sc::ColumnBlockPosition &rBlockPos, SCTAB nTab, SCCOL nCol)
Definition: document.cxx:2613
bool mbStreamValidLocked
Definition: document.hxx:557
exports embed
std::shared_ptr< sc::FormulaGroupContext > & GetFormulaGroupContext()
Definition: document.cxx:3526
SC_DLLPUBLIC ScDPCollection * GetDPCollection()
Definition: documen3.cxx:346
bool IsUndo() const
Definition: document.hxx:1532
List of RefUpdate changes made to UNO objects during ScUpdateRefHint broadcast.
Definition: unoreflist.hxx:42
sal_Int16 mnNamedRangesLockCount
Definition: document.hxx:560
ScInterpreterContext * pContext
Definition: document.hxx:300
SC_DLLPUBLIC bool CreateDdeLink(const OUString &rAppl, const OUString &rTopic, const OUString &rItem, sal_uInt8 nMode, const ScMatrixRef &pResults)
Tries to find a DDE link or creates a new, if not extant.
Definition: documen8.cxx:991
void ApplySelectionLineStyle(const ScMarkData &rMark, const ::editeng::SvxBorderLine *pLine, bool bColorOnly)
Definition: document.cxx:4884
static const sal_uInt16 nSrcVer
Definition: document.hxx:485
bool IsInDdeLinkUpdate() const
Definition: document.hxx:1023
SC_DLLPUBLIC void SetColHidden(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bHidden)
Definition: document.cxx:4469
rtl::Reference< XColorList > pColorList
Definition: document.hxx:383
void BlockFormulaGroupContextDiscard(bool block)
Definition: document.hxx:1193
normal calculation of dependencies
void ModifyStyleSheet(SfxStyleSheetBase &rPageStyle, const SfxItemSet &rChanges)
Definition: documen8.cxx:209
void SetDirtyFromClip(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, InsertDeleteFlags nInsFlag, sc::ColumnSpanSet &rBroadcastSpans)
Definition: document.cxx:2596
const ScMarkData & GetPreviewSelection() const
Definition: document.hxx:1345
long GetNeededSize(SCCOL nCol, SCROW nRow, SCTAB nTab, OutputDevice *pDev, double nPPTX, double nPPTY, const Fraction &rZoomX, const Fraction &rZoomY, bool bWidth, bool bTotalSize=false, bool bInPrintTwips=false)
Definition: document.cxx:4255
void SetPendingRowHeights(SCTAB nTab, bool bSet)
Definition: document.cxx:943
rtl_TextEncoding eSrcSet
Definition: document.hxx:463
bool IsTrackFormulasPending() const
Definition: document.hxx:2300
sal_uLong GetCodeCount() const
Definition: document.cxx:6163
sal_uInt16 nFormulaTrackCount
Definition: document.hxx:486
Store position data for column array storage.
ScDocumentThreadSpecific maNonThreaded
Definition: document.hxx:475
bool HasPartOfMerged(const ScRange &rRange)
Definition: document.cxx:1737
void DecInterpreterTableOpLevel()
Definition: document.hxx:2348
void CopyMultiRangeFromClip(const ScAddress &rDestPos, const ScMarkData &rMark, InsertDeleteFlags nInsFlag, ScDocument *pClipDoc, bool bResetCut=true, bool bAsLink=false, bool bIncludeFiltered=true, bool bSkipAttrForEmpty=false)
Definition: document.cxx:3017
const ScDBData * GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2) const
Definition: documen3.cxx:319
Cache for faster lookup of automatic names during CompileXML (during CompileXML, no document content ...
bool IsClipOrUndo() const
Definition: document.hxx:1531
void EndListeningIntersectedGroup(sc::EndListeningContext &rCxt, const ScAddress &rPos, std::vector< ScAddress > *pGroupPos)
Definition: document10.cxx:464
void SC_DLLPUBLIC SetSortParam(const ScSortParam &rParam, SCTAB nTab)
Definition: documen3.cxx:2100
Stores cell values for multiple tables.
Definition: cellvalues.hxx:87
SC_DLLPUBLIC void SetRepeatColRange(SCTAB nTab, std::unique_ptr< ScRange > pNew)
Definition: document.cxx:6323
SC_DLLPUBLIC SCROW FirstVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4477
SC_DLLPUBLIC void GetNumberFormat(SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt32 &rFormat) const
Definition: document.cxx:3643
OString dumpSheetGeomData(SCTAB nTab, bool bColumns, SheetGeomType eGeomType)
Serializes the specified sheet's geometry data.
static ScRecursionHelper * CreateRecursionHelperInstance()
Definition: documen2.cxx:1151
SvtBroadcaster * GetBroadcaster(const ScAddress &rPos)
Definition: document.cxx:2456
SC_DLLPUBLIC sal_uLong AddCondFormat(std::unique_ptr< ScConditionalFormat > pNew, SCTAB nTab)
Definition: documen4.cxx:705
SC_DLLPUBLIC bool DeleteTabs(SCTAB nTab, SCTAB nSheets)
Definition: document.cxx:760
Extended options held by an ScDocument containing additional settings for filters.
Definition: scextopt.hxx:77
SC_DLLPUBLIC SCROW LastVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4485
bool bLoadingMedium
Definition: document.hxx:511
SC_DLLPUBLIC void SetLayoutRTL(SCTAB nTab, bool bRTL)
Definition: document.cxx:949
SC_DLLPUBLIC void CopyDdeLinks(ScDocument *pDestDoc) const
Definition: documen8.cxx:864
bool InsertCol(SCROW nStartRow, SCTAB nStartTab, SCROW nEndRow, SCTAB nEndTab, SCCOL nStartCol, SCSIZE nSize, ScDocument *pRefUndoDoc=nullptr, const ScMarkData *pTabMark=nullptr)
Definition: document.cxx:1498
bool bCalcingAfterLoad
Definition: document.hxx:513
HardRecalcState eHardRecalcState
Definition: document.hxx:487
VirtualDevice * GetVirtualDevice_100th_mm()
Definition: documen8.cxx:181
double * GetValueCell(const ScAddress &rPos)
Return a pointer to the double value stored in value cell.
Definition: document.cxx:3510
Stores options which are only relevant for clipboard documents.
Definition: clipoptions.hxx:19
ScDocShellRecalcGuard(ScDocument &rDoc)
Definition: document.hxx:2685
SC_DLLPUBLIC void SetValue(SCCOL nCol, SCROW nRow, SCTAB nTab, const double &rVal)
Definition: document.cxx:3460
SC_DLLPUBLIC void InsertTableOp(const ScTabOpParam &rParam, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark)
Definition: documen4.cxx:355
sal_Int64 GetNewUnoId()
Definition: document.hxx:1071
This is very similar to ScCellValue, except that it references the original value instead of copying ...
Definition: cellvalue.hxx:104
SC_DLLPUBLIC formula::FormulaGrammar::Grammar GetGrammar() const
Definition: document.hxx:988
sal_uInt16 nInterpreterTableOpLevel
Definition: document.hxx:473
bool IsHorOverlapped(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:5731
void GetEmbedded(ScRange &rRange) const
Definition: documen3.cxx:1666
bool InsertNewRangeName(const OUString &rName, const ScAddress &rPos, const OUString &rExpr)
Insert a new named expression to the global scope.
Definition: documen3.cxx:218
SC_DLLPUBLIC bool CreateQueryParam(const ScRange &rRange, ScQueryParam &rQueryParam)
Definition: documen3.cxx:1444
SC_DLLPUBLIC ScDBData * GetAnonymousDBData()
Definition: document.cxx:329
std::unique_ptr< ScExtDocOptions > pExtDocOptions
Definition: document.hxx:433
SC_DLLPUBLIC ScRange GetRange(SCTAB nTab, const tools::Rectangle &rMMRect, bool bHiddenAsZero=true) const
Definition: documen3.cxx:1763
std::unique_ptr< ScValidationDataList > pValidationList
Definition: document.hxx:384
void AppendToFormulaTrack(ScFormulaCell *pCell)
Definition: documen7.cxx:451
const sal_uInt8 SC_DDE_TEXT
Definition: document.hxx:293
SC_DLLPUBLIC void ApplyAttr(SCCOL nCol, SCROW nRow, SCTAB nTab, const SfxPoolItem &rAttr)
Definition: document.cxx:4759
Accessor class to ScDocument.
bool bImportingXML
Definition: document.hxx:512
ScFormulaVectorState GetFormulaVectorState(const ScAddress &rPos) const
Definition: document.cxx:1768
void SetPreviewFont(std::unique_ptr< SfxItemSet > pFontSet)
Definition: documen2.cxx:1358
Lookup cache for one range used with interpreter functions such as VLOOKUP and MATCH.
Definition: lookupcache.hxx:40
void ApplyAsianEditSettings(ScEditEngineDefaulter &rEngine)
Definition: documen9.cxx:669
sc::DocumentLinkManager & GetDocLinkManager()
Definition: documen2.cxx:225
void SetClipOptions(std::unique_ptr< ScClipOptions > pClipOptions)
Definition: documen3.cxx:1991
bool IsLinked(SCTAB nTab) const
Definition: documen3.cxx:466
SC_DLLPUBLIC SfxUndoManager * GetUndoManager()
Definition: document.cxx:6378
SC_DLLPUBLIC void SetRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual)
Definition: document.cxx:4391
void SetPrinter(VclPtr< SfxPrinter > const &pNewPrinter)
Definition: documen8.cxx:141
bool HasStringWeakCharacters(const OUString &rString)
Definition: documen6.cxx:51
css::uno::Sequence< css::sheet::TablePageBreakData > GetRowBreakData(SCTAB nTab) const
Definition: document.cxx:4423
ScFormulaCell * pEOFormulaTrack
Definition: document.hxx:397
void SetHardRecalcState(HardRecalcState eVal)
Definition: document.hxx:2306
SCSIZE GetPatternCount(SCTAB nTab, SCCOL nCol) const
Definition: documen3.cxx:2073
void GetClipArea(SCCOL &nClipX, SCROW &nClipY, bool bIncludeFiltered)
Definition: document.cxx:3120
bool DoSubTotals(SCTAB nTab, ScSubTotalParam &rParam)
Definition: documen3.cxx:758
SC_DLLPUBLIC void Fill(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, ScProgress *pProgress, const ScMarkData &rMark, sal_uLong nFillCount, FillDir eFillDir=FILL_TO_BOTTOM, FillCmd eFillCmd=FILL_LINEAR, FillDateCmd eFillDateCmd=FILL_DAY, double nStepValue=1.0, double nMaxValue=1E307)
Definition: documen3.cxx:1134
std::map< SCTAB, ScSortParam > mSheetSortParams
Definition: document.hxx:2600
SC_DLLPUBLIC void SetVisible(SCTAB nTab, bool bVisible)
Definition: document.cxx:900
SC_DLLPUBLIC formula::FormulaGrammar::AddressConvention GetAddressConvention() const
Definition: documen3.cxx:475
bool ValidColRowTab(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.hxx:881
bool Solver(SCCOL nFCol, SCROW nFRow, SCTAB nFTab, SCCOL nVCol, SCROW nVRow, SCTAB nVTab, const OUString &sValStr, double &nX)
(Goal Seek) Find a value of x that is a root of f(x)
Definition: documen4.cxx:69
sal_uLong nXMLImportedFormulaCount
Definition: document.hxx:470
SC_DLLPUBLIC bool HasAttrib(SCCOL nCol1, SCROW nRow1, SCTAB nTab1, SCCOL nCol2, SCROW nRow2, SCTAB nTab2, HasAttrFlags nMask) const
Definition: document.cxx:5181
bool HasAutoFilter(SCCOL nCol, SCROW nRow, SCTAB nTab)
Definition: documen3.cxx:1457
std::unique_ptr< ScPrintRangeSaver > CreatePrintRangeSaver() const
Definition: document.cxx:6335
void UpdateChartArea(const OUString &rChartName, const ScRange &rNewArea, bool bColHeaders, bool bRowHeaders, bool bAdd)
Definition: documen5.cxx:129
::std::map< SCTAB, const ScRangeName * > TabNameCopyMap
Map that stores non-managed pointers to ScRangeName instances.
Definition: rangenam.hxx:194
void GetNotesInRange(const ScRangeList &rRange, std::vector< sc::NoteEntry > &rNotes) const
Definition: document.cxx:6768
void EndListeningGroups(const std::vector< ScAddress > &rPosArray)
Definition: document10.cxx:489
bool TableExists(SCTAB nTab) const
Definition: document.cxx:2502
void UpdateChart(const OUString &rName)
Definition: documen5.cxx:334
SC_DLLPUBLIC SvtScriptType GetStringScriptType(const OUString &rString)
Definition: documen6.cxx:76
SvNumberFormatterIndexTable * pFormatExchangeList
Definition: document.hxx:385
SC_DLLPUBLIC void GetFormula(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rFormula) const
Definition: document.cxx:3717
bool IsAdjustHeightLocked() const
Definition: document.hxx:1538
SC_DLLPUBLIC ScBreakType HasRowBreak(SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4361
SC_DLLPUBLIC sal_uInt16 GetRowHeight(SCROW nRow, SCTAB nTab, bool bHiddenAsZero=true) const
Definition: document.cxx:4163
void StartAnimations(SCTAB nTab)
Definition: documen9.cxx:317
SC_DLLPUBLIC ScNoteEditEngine & GetNoteEngine()
Definition: documen2.cxx:467
void SetClipParam(const ScClipParam &rParam)
Definition: document.cxx:2559
bool mbChangeReadOnlyEnabled
Definition: document.hxx:556
ScAddress aCurTextWidthCalcPos
Definition: document.hxx:447
void AddUnoRefChange(sal_Int64 nId, const ScRangeList &rOldRanges)
Definition: documen3.cxx:980
SC_DLLPUBLIC void SetTextCell(const ScAddress &rPos, const OUString &rStr)
Call this if you are not sure whether to put this as an edit text or a simple text.
Definition: document.cxx:3433
exports sheet
void RemoveFromFormulaTrack(ScFormulaCell *pCell)
Definition: documen7.cxx:467
SC_DLLPUBLIC void GetBorderLines(SCCOL nCol, SCROW nRow, SCTAB nTab, const ::editeng::SvxBorderLine **ppLeft, const ::editeng::SvxBorderLine **ppTop, const ::editeng::SvxBorderLine **ppRight, const ::editeng::SvxBorderLine **ppBottom) const
Definition: document.cxx:5249
bool GetNextSpellingCell(SCCOL &nCol, SCROW &nRow, SCTAB nTab, bool bInSel, const ScMarkData &rMark) const
Definition: documen4.cxx:530
std::unique_ptr< SfxBroadcaster > pUnoBroadcaster
Definition: document.hxx:403
Row-wise value iterator.
Definition: dociter.hxx:479
std::map< sal_uInt16, sal_uInt32 > SvNumberFormatterIndexTable
void UnlockTable(SCTAB nTab)
Definition: document.cxx:5319
bool HasAnySheetEventScript(ScSheetEventId nEvent, bool bWithVbaEvents=false) const
Definition: documen3.cxx:677
bool IsExecuteLinkEnabled() const
Definition: document.hxx:1541
SC_DLLPUBLIC ScDocumentPool * GetPool()
Definition: document.cxx:6063
void Sort(SCTAB nTab, const ScSortParam &rSortParam, bool bKeepQuery, bool bUpdateRefs, ScProgress *pProgress, sc::ReorderParam *pUndo)
Sort a range of data.
Definition: documen3.cxx:1402
void TransliterateText(const ScMarkData &rMultiMark, TransliterationFlags nType)
Definition: documen8.cxx:1208
SC_DLLPUBLIC const ScValidationData * GetValidationEntry(sal_uLong nIndex) const
Definition: documen4.cxx:871
LanguageType eCjkLanguage
Definition: document.hxx:461
void InvalidateTableArea()
Definition: documen4.cxx:576
ScLkUpdMode eLinkMode
Definition: document.hxx:492
SC_DLLPUBLIC bool IsManualRowHeight(SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4557
void CopyNonFilteredFromClip(sc::CopyFromClipContext &rCxt, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, SCCOL nDx, SCROW &rClipStartRow)
Definition: document.cxx:2724
SfxPrinter * GetPrinter(bool bCreateIfNotExist=true)
Definition: documen8.cxx:113
void DeleteDrawLayer()
Definition: documen9.cxx:227
SC_DLLPUBLIC void SetImportingXML(bool bVal)
Definition: documen9.cxx:590
size_t GetFormulaHash(const ScAddress &rPos) const
Definition: document.cxx:1759
void SetAllFormulasDirty(const sc::SetFormulaDirtyContext &rCxt)
Definition: document.cxx:3837
SC_DLLPUBLIC void SetGrammar(formula::FormulaGrammar::Grammar eGram)
Definition: documen3.cxx:480
const ScStyleSheet * GetStyle(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4900
SC_DLLPUBLIC bool GetPrintAreaVer(SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol, SCROW &rEndRow, bool bNotes) const
Definition: documen2.cxx:619
void RepaintRange(const ScRange &rRange)
Definition: documen8.cxx:687
static void SetupFromNonThreadedData(const ScDocumentThreadSpecific &rNonThreadedData)
Definition: document.cxx:6824
bool IsPendingRowHeights(SCTAB nTab) const
Definition: document.cxx:935
SC_DLLPUBLIC ScPostIt * GetNote(const ScAddress &rPos)
Definition: document.cxx:6510
void SetEmbedFontScriptLatin(bool bUse)
Definition: document.hxx:592
SC_DLLPUBLIC bool LinkExternalTab(SCTAB &nTab, const OUString &aDocTab, const OUString &aFileName, const OUString &aTabName)
Definition: documen3.cxx:549
SC_DLLPUBLIC ScConditionalFormatList * GetCondFormList(SCTAB nTab) const
Definition: documen4.cxx:857
CommentCaptionState GetAllNoteCaptionsState(const ScRangeList &rRanges)
Definition: document.cxx:6651
SC_DLLPUBLIC void CheckLinkFormulaNeedingCheck(const ScTokenArray &rCode)
Check token array and set link check if ocDde/ocWebservice is contained.
Definition: documen8.cxx:1152
bool ValidColRowTab(SCCOL nCol, SCROW nRow, SCTAB nTab, SCCOL nMaxCol, SCROW nMaxRow)
Definition: address.hxx:121
bool HandleRefArrayForParallelism(const ScAddress &rPos, SCROW nLength, const ScFormulaCellGroupRef &mxGroup)
Definition: document.cxx:1821
bool bForcedFormulaPending
Definition: document.hxx:499
std::unordered_map< ScColumn *, std::pair< SCROW, SCROW > > pDelayedStartListeningFormulaCells
Definition: document.hxx:536
const std::shared_ptr< SvxForbiddenCharactersTable > & GetForbiddenCharacters() const
Definition: documen9.cxx:611
void SetChartListenerCollectionNeedsUpdate(bool bFlg)
Definition: document.hxx:2153
void DoAutoOutline(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: documen3.cxx:740
SC_DLLPUBLIC bool RenameTab(SCTAB nTab, const OUString &rName, bool bExternalDocument=false)
Definition: document.cxx:852
formula::FormulaGrammar::Grammar eGrammar
Definition: document.hxx:550
ScClipParam & GetClipParam()
Definition: document.cxx:2551
SC_DLLPUBLIC sal_uInt16 GetOriginalWidth(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4139
void InvalidateStyleSheetUsage()
Definition: document.hxx:2434
void UpdateReference(sc::RefUpdateContext &rCxt, ScDocument *pUndoDoc=nullptr, bool bIncludeDraw=true, bool bUpdateNoteCaptionPos=true)
Definition: documen3.cxx:986
Definition: document.hxx:876
size_t SCSIZE
size_t typedef to be able to find places where code was changed from USHORT to size_t and is used to ...
Definition: address.hxx:45
sal_Int32 SCCOLROW
a type capable of holding either SCCOL or SCROW
Definition: types.hxx:24
const BorderLinePrimitive2D *pCandidateB assert(pCandidateA)
void SetNamedRangesLockCount(sal_Int16 nCount)
Definition: document.hxx:1548
void SetCodeName(const OUString &r)
Definition: document.hxx:608
SC_DLLPUBLIC SCTAB GetTableCount() const
Definition: document.cxx:313
SC_DLLPUBLIC SCROW GetLastFlaggedRow(SCTAB nTab) const
Definition: document.cxx:4574
SvtScriptType GetRangeScriptType(sc::ColumnBlockPosition &rBlockPos, const ScAddress &rPos, SCROW nLength)
Definition: documen6.cxx:183
Additional class containing cell annotation data.
Definition: postit.hxx:160
bool CanDelayStartListeningFormulaCells(ScColumn *column, SCROW row1, SCROW row2)
If true is returned, ScColumn::StartListeningFormulaCells() for the given cells will be performed lat...
Definition: document10.cxx:427
ScFormulaCell * pEOFormulaTree
Definition: document.hxx:395
SC_DLLPUBLIC void PreprocessAllRangeNamesUpdate(const std::map< OUString, std::unique_ptr< ScRangeName >> &rRangeMap)
Call this immediately before updating all named ranges.
Definition: document10.cxx:246
SC_DLLPUBLIC void CopyUpdated(ScDocument *pPosDoc, ScDocument *pDestDoc)
From this document this method copies the cells of positions at which there are also cells in pPosDoc...
Definition: documen3.cxx:781
SC_DLLPUBLIC void SetColWidth(SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth)
Definition: document.cxx:4085
void SetExpandRefs(bool bVal)
Definition: documen2.cxx:305
const ScPatternAttr * GetSelectionPattern(const ScMarkData &rMark)
Definition: document.cxx:5102
bool HasChartAtPoint(SCTAB nTab, const Point &rPos, OUString &rName)
Definition: documen5.cxx:99
bool HasAnyDraw(SCTAB nTab, const tools::Rectangle &rMMRect) const
Definition: documen9.cxx:366
sal_uLong GetFormulaCodeInTree() const
Definition: document.hxx:2313
TableContainer maTabs
Definition: document.hxx:386
bool SetDdeLinkResultMatrix(size_t nDdePos, const ScMatrixRef &pResults)
Sets a result matrix for the specified DDE link.
Definition: documen8.cxx:1022
void SetEmbedFontScriptAsian(bool bUse)
Definition: document.hxx:593
Definition: global.hxx:418
const ScValidationDataList * GetValidationList() const
Definition: document.hxx:1795
Definition: global.hxx:343
std::unique_ptr< ScRefreshTimerControl > pRefreshTimerControl
Definition: document.hxx:408
void DecInDdeLinkUpdate()
Definition: document.hxx:1022
SC_DLLPUBLIC sc::ExternalDataMapper & GetExternalDataMapper()
SC_DLLPUBLIC OUString GetString(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScInterpreterContext *pContext=nullptr) const
Definition: document.cxx:3488
void DecInterpretLevel()
Definition: document.hxx:2323
std::unique_ptr< ScBroadcastAreaSlotMachine > pBASM
Definition: document.hxx:398
bool IsFinalTrackFormulas() const
Definition: document.hxx:2302
void CopyToDocument(SCCOL nCol1, SCROW nRow1, SCTAB nTab1, SCCOL nCol2, SCROW nRow2, SCTAB nTab2, InsertDeleteFlags nFlags, bool bMarked, ScDocument &rDestDoc, const ScMarkData *pMarks=nullptr, bool bColRowFlags=true)
Definition: document.cxx:2075
std::unique_ptr< ScConsolidateParam > pConsolidateDlgData
Definition: document.hxx:435
void SetChartListenerCollection(std::unique_ptr< ScChartListenerCollection >, bool bSetChartRangeLists)
Definition: documen3.cxx:393
void SetNoListening(bool bVal)
Definition: document.hxx:2142
sal_uInt16 GetOptimalColWidth(SCCOL nCol, SCTAB nTab, OutputDevice *pDev, double nPPTX, double nPPTY, const Fraction &rZoomX, const Fraction &rZoomY, bool bFormula, const ScMarkData *pMarkData=nullptr, const ScColWidthParam *pParam=nullptr)
Definition: document.cxx:4242
bool bInsertingFromOtherDoc
Definition: document.hxx:510
bool ValidRange(const ScRange &rRange, SCCOL nMaxCol=MAXCOL, SCROW nMaxRow=MAXROW)
Definition: address.hxx:793
SC_DLLPUBLIC bool GetTable(const OUString &rName, SCTAB &rTab) const
Definition: document.cxx:259
SC_DLLPUBLIC ScExternalRefManager * GetExternalRefManager() const
Definition: documen3.cxx:604
SC_DLLPUBLIC bool IsDocVisible() const
Definition: document.hxx:1555
void UpdateScriptTypes(const ScAddress &rPos, SCCOL nColSize, SCROW nRowSize)
Definition: document10.cxx:334
const ScDocumentThreadSpecific & CalculateInColumnInThread(ScInterpreterContext &rContext, const ScRange &rCalcRange, unsigned nThisThread, unsigned nThreadsTotal)
Definition: documen8.cxx:411
bool IsAutoCalcShellDisabled() const
Definition: document.hxx:1366
std::unique_ptr< ScDocProtection > pDocProtection
Definition: document.hxx:415
::boost::intrusive_ptr< ScMatrix > ScMatrixRef
Definition: types.hxx:26
std::map< OUString, BitmapEx > IconSetBitmapMap
Definition: document.hxx:207
OUString aDocCodeName
Definition: document.hxx:426
Walk through all cells in an area.
Definition: dociter.hxx:208
tools::Rectangle GetEmbeddedRect() const
Definition: documen3.cxx:1671
SC_DLLPUBLIC bool HasTable(SCTAB nTab) const
Definition: document.cxx:190
Definition: global.hxx:225
void EndListeningIntersectedGroups(sc::EndListeningContext &rCxt, const ScRange &rRange, std::vector< ScAddress > *pGroupPos)
Definition: document10.cxx:474
bool mbIdleEnabled
Definition: document.hxx:516
void DiscardFormulaGroupContext()
Definition: document.cxx:3535
SC_DLLPUBLIC void GetNextPos(SCCOL &rCol, SCROW &rRow, SCTAB nTab, SCCOL nMovX, SCROW nMovY, bool bMarked, bool bUnprotected, const ScMarkData &rMark, SCCOL nTabStartCol=SC_TABSTART_NONE) const
Definition: document.cxx:6096
formula::VectorRefArray FetchVectorRefArray(const ScAddress &rPos, SCROW nLength)
Definition: document.cxx:1796
SC_DLLPUBLIC const ScRange * GetPrintRange(SCTAB nTab, sal_uInt16 nPos)
Definition: document.cxx:6281
std::set< ScFormulaCell * > maSubTotalCells
Definition: document.hxx:562
void SetError(SCCOL nCol, SCROW nRow, SCTAB nTab, const FormulaError nError)
Definition: documen2.cxx:1056
bool RenamePageStyleInUse(const OUString &rOld, const OUString &rNew)
Definition: documen8.cxx:340
bool HasSheetEventScript(SCTAB nTab, ScSheetEventId nEvent, bool bWithVbaEvents=false) const
Definition: documen3.cxx:653
const sal_uInt8 SC_DDE_IGNOREMODE
Definition: document.hxx:294
void RestoreChartListener(const OUString &rName)
Definition: documen5.cxx:362
void CopyTabProtection(SCTAB nTabSrc, SCTAB nTabDest)
Definition: documen3.cxx:1896
void Clear(bool bFromDestructor=false)
Definition: documen9.cxx:498
SCTAB GetMaxTableNumber() const
Definition: document.hxx:809
void EndListeningArea(const ScRange &rRange, bool bGroupListening, SvtListener *pListener)
Definition: documen7.cxx:61
void EndListeningFormulaCells(std::vector< ScFormulaCell * > &rCells)
Definition: documen7.cxx:246
SC_DLLPUBLIC ~ScDocument()
Definition: documen2.cxx:324
Optimized ColumnSpanSet version that operates on a single ScRange.
bool IsEmbedUsedFontsOnly() const
Definition: document.hxx:585
std::unique_ptr< ScDBData > mpAnonymousDBData
Definition: document.hxx:410
ScRecursionHelper * pRecursionHelper
Definition: document.hxx:299
sal_uInt16 ColDifferences(SCCOL nThisCol, SCTAB nThisTab, ScDocument &rOtherDoc, SCCOL nOtherCol, SCTAB nOtherTab, SCROW nMaxRow, const SCCOLROW *pOtherRows)
Definition: documen4.cxx:954
bool SetOutlineTable(SCTAB nTab, const ScOutlineTable *pNewOutline)
Definition: documen3.cxx:735
SCROW SanitizeRow(SCROW nRow, SCROW nMaxRow)
Definition: address.hxx:133
void PrepareFormulaCalc()
Call this before any operations that might trigger one or more formula cells to get calculated...
Definition: document.cxx:2450
void PageStyleModified(SCTAB nTab, const OUString &rNewName)
Definition: document.cxx:6176
SC_DLLPUBLIC void SetColWidthOnly(SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth)
Definition: document.cxx:4091
SC_DLLPUBLIC void ResetClip(ScDocument *pSourceDoc, const ScMarkData *pMarks)
Definition: documen2.cxx:485
ScMutationDisable(ScDocument *pDocument, ScMutationGuardFlags nFlags)
Definition: document.hxx:2627
ScBroadcastAreaSlotMachine * GetBASM() const
Definition: document.hxx:2144
SC_DLLPUBLIC void ApplyPatternArea(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, const ScMarkData &rMark, const ScPatternAttr &rAttr, ScEditDataArray *pDataArray=nullptr, bool *const pIsChanged=nullptr)
Definition: document.cxx:4771
SC_DLLPUBLIC void SetRowHeightOnly(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, sal_uInt16 nNewHeight)
Definition: document.cxx:4110
bool mbTrackFormulasPending
Definition: document.hxx:573
SC_DLLPUBLIC const ScPatternAttr * GetPattern(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4737
void ReplaceStyle(const SvxSearchItem &rSearchItem, SCCOL nCol, SCROW nRow, SCTAB nTab, const ScMarkData &rMark)
Definition: documen4.cxx:548
SfxUndoManager * mpUndoManager
Definition: document.hxx:376
bool CopyOneCellFromClip(sc::CopyFromClipContext &rCxt, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2)
Definition: document10.cxx:82
void MarkUsedExternalReferences()
Definition: documen3.cxx:618
bool IsPrintEntireSheet(SCTAB nTab) const
Returns true, if the specified sheet is always printed.
Definition: document.cxx:6268
bool bHasForcedFormulas
Definition: document.hxx:520
void FinalTrackFormulas(SfxHintId nHintId)
Definition: documen7.cxx:506
ScChangeTrack * GetChangeTrack() const
Definition: document.hxx:2397
std::unique_ptr< ScDrawLayer > mpDrawLayer
Definition: document.hxx:382
void CopyTabToClip(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, SCTAB nTab, ScDocument *pClipDoc)
Definition: document.cxx:2276
bool ColFiltered(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4517
bool mbFinalTrackFormulas
Definition: document.hxx:574
void GetFilterEntries(SCCOL nCol, SCROW nRow, SCTAB nTab, ScFilterEntries &rFilterEntries)
Get a list of unique strings to use in filtering criteria.
Definition: documen3.cxx:1516
Stores the used instances of the FilterFormulaParser service implementations, mapped by the formula n...
SC_DLLPUBLIC const SfxPoolItem * GetAttr(SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich) const
Definition: document.cxx:4716
SC_DLLPUBLIC void SetAllRangeNames(const std::map< OUString, std::unique_ptr< ScRangeName >> &rRangeMap)
Definition: documen3.cxx:121
void PutInFormulaTree(ScFormulaCell *pCell)
Definition: documen7.cxx:258
SC_DLLPUBLIC SCCOL GetAllocatedColumnsCount(SCTAB nTab) const
Definition: documen3.cxx:2110
void StylesToNames()
Definition: document.cxx:6124
void StartListeningCell(const ScAddress &rAddress, SvtListener *pListener)
Definition: documen7.cxx:208
void ImplCreateOptions()
Definition: documen8.cxx:100
void SetInsertingFromOtherDoc(bool bVal)
Definition: document.hxx:2136
void SetSrcCharSet(rtl_TextEncoding eNew)
Definition: document.hxx:2053
void ResetEmbedded()
Definition: documen3.cxx:1710
bool GetNoListening() const
Definition: document.hxx:2143
bool IsStreamValid(SCTAB nTab) const
Definition: document.cxx:916
ScStyleSheet * GetPreviewCellStyle()
Definition: document.hxx:1347
bool HasValidationData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3811
SC_DLLPUBLIC bool GetCellArea(SCTAB nTab, SCCOL &rEndCol, SCROW &rEndRow) const
Definition: document.cxx:1017
ScRangePairListRef xColNameRanges
Definition: document.hxx:428
bool IsClipboard() const
Definition: document.hxx:1533
SC_DLLPUBLIC bool HasRowHeader(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: documen3.cxx:1495
SC_DLLPUBLIC double GetValue(const ScAddress &rPos) const
Definition: document.cxx:3630
SC_DLLPUBLIC const ScDocOptions & GetDocOptions() const
Definition: documen3.cxx:1904
SCCOL SanitizeCol(SCCOL nCol, SCCOL nMaxCol)
Definition: address.hxx:127
SC_DLLPUBLIC void InsertMatrixFormula(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, const OUString &rFormula, const ScTokenArray *p=nullptr, const formula::FormulaGrammar::Grammar=formula::FormulaGrammar::GRAM_DEFAULT)
Definition: documen4.cxx:257
constexpr double nPPTX
void SetTabNameOnLoad(SCTAB nTab, const OUString &rName)
Definition: document.cxx:483
bool IsPrintEmpty(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool bLeftIsEmpty=false, ScRange *pLastRange=nullptr, tools::Rectangle *pLastMM=nullptr) const
Definition: documen9.cxx:433
bool HasCalcNotification(SCTAB nTab) const
Definition: documen3.cxx:695
A pretty assertion that checks that the relevant bits in the are not set on the document at entry an...
Definition: document.hxx:2657
bool bInUnoBroadcast
Definition: document.hxx:547
size_t mnMutationGuardFlags
Definition: document.hxx:578
void AddOLEObjectToCollection(const OUString &rName)
Definition: documen5.cxx:644
SC_DLLPUBLIC bool SetEditText(const ScAddress &rPos, std::unique_ptr< EditTextObject > pEditText)
This method manages the lifecycle of the passed edit text object.
Definition: document.cxx:3396
SC_DLLPUBLIC void DumpColumnStorage(SCTAB nTab, SCCOL nCol) const
void AddDetectiveOperation(const ScDetOpData &rData)
Definition: documen4.cxx:890
void InvalidateStreamOnSave()
Definition: document.cxx:494
bool HasDetectiveObjects(SCTAB nTab) const
Definition: documen9.cxx:513
SC_DLLPUBLIC void GetDataArea(SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow, SCCOL &rEndCol, SCROW &rEndRow, bool bIncludeOld, bool bOnlyDown) const
Return the smallest area containing at least all contiguous cells having data.
Definition: document.cxx:1095
SC_DLLPUBLIC void SetAutoNameCache(std::unique_ptr< ScAutoNameCache > pCache)
Definition: document.cxx:6801
void SwapNonEmpty(sc::TableValues &rValues)
Definition: document10.cxx:224
bool ValidCol(SCCOL nCol, SCCOL nMaxCol)
Definition: address.hxx:93
ScRefCellValue GetRefCellValue(const ScAddress &rPos)
Definition: documen2.cxx:547
SC_DLLPUBLIC void SetVisibleTab(SCTAB nTab)
Definition: document.hxx:863
Enum used to indicate which portion of the DBArea is to be considered.
Definition: dbdata.hxx:41
Definition: global.hxx:189
SC_DLLPUBLIC bool SetString(SCCOL nCol, SCROW nRow, SCTAB nTab, const OUString &rString, const ScSetStringParam *pParam=nullptr)
Definition: document.cxx:3365
std::unique_ptr< ScViewOptions > pViewOptions
Definition: document.hxx:431
SC_DLLPUBLIC ScDocProtection * GetDocProtection() const
Definition: documen3.cxx:1847
static void MergeBackIntoNonThreadedData(ScDocumentThreadSpecific &rNonThreadedData)
Definition: document.cxx:6830
bool HasOLEObjectsInArea(const ScRange &rRange, const ScMarkData *pTabMark=nullptr)
Definition: documen9.cxx:274
bool IsCellInChangeTrack(const ScAddress &cell, Color *pColCellBorder)
Definition: documen2.cxx:1206
bool HasAnyCalcNotification() const
Definition: documen3.cxx:686
bool HasClipFilteredRows()
Definition: document.cxx:3189
bool bExpandRefs
Definition: document.hxx:527
formula::FormulaGrammar::Grammar eStorageGrammar
The compiler grammar used in document storage.
Definition: document.hxx:467
SC_DLLPUBLIC ScPostIt * GetOrCreateNote(const ScAddress &rPos)
Definition: document.cxx:6601
SC_DLLPUBLIC void SetScenarioData(SCTAB nTab, const OUString &rComment, const Color &rColor, ScScenarioFlags nFlags)
Definition: documen3.cxx:418
SC_DLLPUBLIC ScDrawLayer * GetDrawLayer()
Definition: document.hxx:1062
void SetClipArea(const ScRange &rArea, bool bCut=false)
Definition: document.cxx:3105
Definition: document.hxx:875
T * get() const
sal_uInt16 char * pName
Definition: callform.cxx:58
bool ShrinkToUsedDataArea(bool &o_bShrunk, SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow, SCCOL &rEndCol, SCROW &rEndRow, bool bColumnsOnly, bool bStickyTopRow=false, bool bStickyLeftCol=false, bool bConsiderCellNotes=false, bool bConsiderCellDrawObjects=false) const
Shrink a range to only include used data area.
Definition: document.cxx:1070
std::unique_ptr< ScUnoRefList > EndUnoRefUndo()
Definition: documen3.cxx:974
const ScStyleSheet * GetSelectionStyle(const ScMarkData &rMark) const
Definition: document.cxx:4908
SC_DLLPUBLIC SvNumberFormatter * GetFormatTable() const
Definition: documen2.cxx:438
SC_DLLPUBLIC bool ColHidden(SCCOL nCol, SCTAB nTab, SCCOL *pFirstCol=nullptr, SCCOL *pLastCol=nullptr) const
Definition: document.cxx:4447
SC_DLLPUBLIC void SetPattern(const ScAddress &, const ScPatternAttr &rAttr)
Definition: document.cxx:5051
bool IsChartListenerCollectionNeedsUpdate() const
Definition: document.hxx:2152
bool IsInsertingFromOtherDoc() const
Definition: document.hxx:2137
void ApplyFrameAreaTab(const ScRange &rRange, const SvxBoxItem &rLineOuter, const SvxBoxInfoItem &rLineInner)
Definition: document.cxx:5863
bool CopyTab(SCTAB nOldPos, SCTAB nNewPos, const ScMarkData *pOnlyMarked=nullptr)
Definition: documen2.cxx:765
SC_DLLPUBLIC void InitDrawLayer(SfxObjectShell *pDocShell=nullptr)
Definition: documen9.cxx:96
Parameter for data table aka multiple operations.
Definition: paramisc.hxx:46
bool PastingDrawFromOtherDoc() const
Definition: document.hxx:2428
void GetScenarioFlags(SCTAB nTab, ScScenarioFlags &rFlags) const
Definition: documen3.cxx:460
bool bIsFunctionAccess
Definition: document.hxx:503
void Reorder(const sc::ReorderParam &rParam)
Definition: documen3.cxx:1415
Definition: global.hxx:326
void DelayFormulaGrouping(bool delay)
If set, joining cells into shared formula groups will be delayed until reset again (RegroupFormulaCel...
Definition: document10.cxx:377
void SetStorageGrammar(formula::FormulaGrammar::Grammar eGrammar)
Should only be GRAM_PODF or GRAM_ODFF.
Definition: documen2.cxx:235
ScRecursionHelper & GetRecursionHelper()
Definition: document.cxx:6808
SC_DLLPUBLIC sal_uInt16 GetPrintRangeCount(SCTAB nTab)
Definition: document.cxx:6273
SCROW CountNonFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4549
Set of column block positions only for one table.
void UpdateBroadcastAreas(UpdateRefMode eUpdateRefMode, const ScRange &rRange, SCCOL nDx, SCROW nDy, SCTAB nDz)
Definition: documen7.cxx:590
void InvalidatePageBreaks(SCTAB nTab)
Definition: document.cxx:6217
void SetDBCollection(std::unique_ptr< ScDBCollection > pNewDBCollection, bool bRemoveAutoFilter=false)
Definition: documen3.cxx:256
std::unique_ptr< ScDPCollection > pDPCollection
Definition: document.hxx:391
SC_DLLPUBLIC void CalcFormulaTree(bool bOnlyForced=false, bool bProgressBar=true, bool bSetAllDirty=true)
Calculate formula cells that are on the formula tree either partially, or in full.
Definition: documen7.cxx:326
bool IsImportingXML() const
Definition: document.hxx:2140
Keep track of all named expressions that have been updated during reference update.
SCCOL nPosLeft
Definition: document.hxx:489
void EnableExecuteLink(bool bVal)
Definition: document.hxx:1542
sal_uInt16 RowDifferences(SCROW nThisRow, SCTAB nThisTab, ScDocument &rOtherDoc, SCROW nOtherRow, SCTAB nOtherTab, SCCOL nMaxCol, const SCCOLROW *pOtherCols)
Definition: documen4.cxx:916
ScDocument * mpDocument
Definition: document.hxx:2675
bool bIsEmbedded
Definition: document.hxx:506
void GetCellChangeTrackNote(const ScAddress &cell, OUString &strTrackText, bool &pbLeftEdge)
Definition: documen2.cxx:1270
SCROW GetNextDifferentChangedRow(SCTAB nTab, SCROW nStart) const
Definition: document.cxx:4613
SC_DLLPUBLIC bool HasPivotTable() const
Definition: documen3.cxx:341
LanguageType eCtlLanguage
Definition: document.hxx:462
SC_DLLPUBLIC const ScRangeList * GetScenarioRanges(SCTAB nTab) const
Definition: documen3.cxx:850
SC_DLLPUBLIC bool IsDefaultTabBgColor(SCTAB nTab) const
Definition: documen3.cxx:442
SC_DLLPUBLIC void GetRangeNameMap(std::map< OUString, ScRangeName * > &rRangeName)
Definition: documen3.cxx:146
bool HasUniformRowHeight(SCTAB nTab, SCROW nRow1, SCROW nRow2) const
Definition: document10.cxx:343
void GetColDefault(SCTAB nTab, SCCOL nCol, SCROW nLastRow, SCROW &nDefault)
Definition: document.cxx:4655
rtl::Reference< ScSheetLimits > mxSheetLimits
Definition: document.hxx:387
void DeleteBroadcasters(sc::ColumnBlockPosition &rBlockPos, const ScAddress &rTopPos, SCROW nLength)
Definition: document.cxx:2474
void UpdateAllRowHeights(sc::RowHeightContext &rCxt, const ScMarkData *pTabMark)
Definition: document.cxx:4277
SC_DLLPUBLIC void SetActiveScenario(SCTAB nTab, bool bActive)
Definition: documen3.cxx:863
void DelBroadcastAreasInRange(const ScRange &rRange)
Definition: documen7.cxx:202
void GetOldChartParameters(const OUString &rName, ScRangeList &rRanges, bool &rColHeaders, bool &rRowHeaders)
Definition: documen5.cxx:201
SC_DLLPUBLIC void CreateValidTabNames(std::vector< OUString > &aNames, SCTAB nCount) const
Definition: document.cxx:438
void GetFormulaEntries(ScTypedCaseStrSet &rStrings)
Entries for Formula auto input.
Definition: documen3.cxx:1622
void FillTab(const ScRange &rSrcArea, const ScMarkData &rMark, InsertDeleteFlags nFlags, ScPasteFunc nFunction, bool bSkipEmpty, bool bAsLink)
Definition: document.cxx:3230
void CompileXML()
Definition: document.cxx:3972
bool RowFiltered(SCROW nRow, SCTAB nTab, SCROW *pFirstRow=nullptr, SCROW *pLastRow=nullptr) const
Definition: document.cxx:4501
bool bDetectiveDirty
Definition: document.hxx:529
std::shared_ptr< sc::FormulaGroupContext > mpFormulaGroupCxt
Definition: document.hxx:371
Definition: global.hxx:335
ScAddress GetNotePosition(size_t nIndex) const
Definition: document.cxx:6684
std::unique_ptr< ScDocument, o3tl::default_delete< ScDocument > > ScDocumentUniquePtr
Definition: document.hxx:2618
SC_DLLPUBLIC void GetAllColBreaks(std::set< SCCOL > &rBreaks, SCTAB nTab, bool bPage, bool bManual) const
Definition: document.cxx:4353
void IncMacroInterpretLevel()
Definition: document.hxx:2330
SC_DLLPUBLIC void RestoreTabFromCache(SCTAB nTab, SvStream &rStream)
sal_Int16 SCCOL
Definition: types.hxx:22
void DeleteSelection(InsertDeleteFlags nDelFlag, const ScMarkData &rMark, bool bBroadcast=true)
Definition: document.cxx:5934
std::unique_ptr< sc::ExternalDataMapper > mpDataMapper
Definition: document.hxx:411
void GetAutoFormatData(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, ScAutoFormatData &rData)
Definition: documen3.cxx:1176
Definition: global.hxx:158
SC_DLLPUBLIC const ScMatrix * GetDdeLinkResultMatrix(size_t nDdePos) const
Returns the result matrix of the specified DDE link.
Definition: documen8.cxx:985
SCCOL GetNextDifferentChangedCol(SCTAB nTab, SCCOL nStart) const
Definition: document.cxx:4595
bool ValidCol(SCCOL nCol) const
Definition: document.hxx:878
void SetVbaEventProcessor(const css::uno::Reference< css::script::vba::XVBAEventProcessor > &rxVbaEvents)
Definition: document.hxx:2438
sal_uLong nCellCount
Definition: document.hxx:278
bool GetDdeLinkData(size_t nDdePos, OUString &rAppl, OUString &rTopic, OUString &rItem) const
Returns the connection data of the specified DDE link.
Definition: documen8.cxx:963
LanguageType eLanguage
Definition: document.hxx:460
bool HasBackgroundDraw(SCTAB nTab, const tools::Rectangle &rMMRect) const
Definition: documen9.cxx:341
sal_uLong GetScaledRowHeight(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, double fScale, const sal_uLong *pnMaxHeight=nullptr) const
Definition: document.cxx:4200
void RestorePrintRanges(const ScPrintRangeSaver &rSaver)
Definition: document.cxx:6345
SC_DLLPUBLIC void SetAutoCalc(bool bNewAutoCalc)
Definition: documen7.cxx:602
void EnableChangeReadOnly(bool bVal)
Definition: document.hxx:1544
bool HasAreaLinks() const
Definition: documen8.cxx:1032
void LimitChartArea(SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow, SCCOL &rEndCol, SCROW &rEndRow)
Definition: document.cxx:1114
ScMarkData maPreviewSelection
Definition: document.hxx:441
SC_DLLPUBLIC bool SetOptimalHeight(sc::RowHeightContext &rCxt, SCROW nStartRow, SCROW nEndRow, SCTAB nTab)
Definition: document.cxx:4268
SC_DLLPUBLIC void GetTiledRenderingArea(SCTAB nTab, SCCOL &rEndCol, SCROW &rEndRow) const
Return the number of columns / rows that should be visible for the tiled rendering.
Definition: documen2.cxx:664
bool IsForcedFormulaPending() const
Definition: document.hxx:1369
void ExtendPrintArea(OutputDevice *pDev, SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL &rEndCol, SCROW nEndRow) const
Find the maximum column position that contains printable data for the specified row range...
Definition: documen3.cxx:2066
SC_DLLPUBLIC void SetViewOptions(const ScViewOptions &rOpt)
Definition: documen3.cxx:1924
ScSheetLimits & GetSheetLimits() const
Definition: document.hxx:877
bool HasRangeOverflow() const
Definition: document.hxx:2132
void RemoveEditTextCharAttribs(const ScAddress &rPos, const ScPatternAttr &rAttr)
Definition: document.cxx:3622
void GetUnprotectedCells(ScRangeList &rRange, SCTAB nTab) const
Definition: document.cxx:6780
bool IsFunctionAccess() const
Definition: document.hxx:1536
bool InsertRow(SCCOL nStartCol, SCTAB nStartTab, SCCOL nEndCol, SCTAB nEndTab, SCROW nStartRow, SCSIZE nSize, ScDocument *pRefUndoDoc=nullptr, const ScMarkData *pTabMark=nullptr)
Definition: document.cxx:1247
bool GetDdeLinkMode(size_t nDdePos, sal_uInt8 &rnMode) const
Returns the link mode of the specified DDE link.
Definition: documen8.cxx:975
SC_DLLPUBLIC void CreateValidTabName(OUString &rName) const
Definition: document.cxx:391
ScFormulaParserPool & GetFormulaParserPool() const
Returns the pool containing external formula parsers.
Definition: documen3.cxx:633
void DeleteBeforeCopyFromClip(sc::CopyFromClipContext &rCxt, const ScMarkData &rMark, sc::ColumnSpanSet &rBroadcastSpans)
Definition: document10.cxx:57
SC_DLLPUBLIC SfxItemPool * GetEnginePool() const
Definition: documen2.cxx:449
SC_DLLPUBLIC void ApplyPattern(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScPatternAttr &rAttr)
Definition: document.cxx:4765
ScRange aEmbedRange
Definition: document.hxx:446
OUString GetAutoFillPreview(const ScRange &rSource, SCCOL nEndX, SCROW nEndY)
Definition: documen3.cxx:1152
sal_uInt16 GetMacroInterpretLevel() const
Definition: document.hxx:2329
SC_DLLPUBLIC void UnlockAdjustHeight()
Definition: document.cxx:1814
SC_DLLPUBLIC SCCOL ClampToAllocatedColumns(SCTAB nTab, SCCOL nCol) const
Definition: documen3.cxx:2105
::boost::intrusive_ptr< FormulaToken > FormulaTokenRef
bool IsInInterpreterTableOp() const
Definition: document.hxx:2342
void SetLinkFormulaNeedingCheck(bool bSet)
Definition: document.hxx:2127
void EndListeningCell(const ScAddress &rAddress, SvtListener *pListener)
Definition: documen7.cxx:217
void SharePooledResources(const ScDocument *pSrcDoc)
Definition: document10.cxx:327
void MarkScenario(SCTAB nSrcTab, SCTAB nDestTab, ScMarkData &rDestMark, bool bResetMark=true, ScScenarioFlags nNeededBits=ScScenarioFlags::NONE) const
Definition: documen3.cxx:833
bool HasManualBreaks(SCTAB nTab) const
Definition: document.cxx:6235
Structure that stores segments of boolean flags per column, and perform custom action on those segmen...
bool IsDetectiveDirty() const
Definition: document.hxx:2123
exports i18n
ScDPObject * GetDPAtBlock(const ScRange &rBlock) const
Definition: documen3.cxx:372
void SetLink(SCTAB nTab, ScLinkMode nMode, const OUString &rDoc, const OUString &rFilter, const OUString &rOptions, const OUString &rTabName, sal_uLong nRefreshDelay)
Definition: documen3.cxx:527
bool IsCutMode()
Definition: document.cxx:2064
SC_DLLPUBLIC void SetRowHeight(SCROW nRow, SCTAB nTab, sal_uInt16 nNewHeight)
Definition: document.cxx:4097
void SetNote(const ScAddress &rPos, std::unique_ptr< ScPostIt > pNote)
Definition: document.cxx:6525
bool mbEmbedFontScriptAsian
Definition: document.hxx:568
SC_DLLPUBLIC bool InsertTab(SCTAB nPos, const OUString &rName, bool bExternalDocument=false, bool bUndoDeleteTab=false)
Definition: document.cxx:503
void CopyCellValuesFrom(const ScAddress &rTopPos, const sc::CellValues &rSrc)
Definition: document10.cxx:173
bool ShrinkToDataArea(SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow, SCCOL &rEndCol, SCROW &rEndRow) const
Shrink a range to only include data area.
Definition: document.cxx:1039
SC_DLLPUBLIC ScDocument(ScDocumentMode eMode=SCDOCMODE_DOCUMENT, SfxObjectShell *pDocShell=nullptr)
Definition: documen2.cxx:103
HardRecalcState GetHardRecalcState() const
Definition: document.hxx:2305
bool GetDataAreaSubrange(ScRange &rRange) const
Returns true if there is a non-empty subrange in the range given as input.
Definition: document.cxx:1102
SC_DLLPUBLIC void ApplyPatternAreaTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, const ScPatternAttr &rAttr)
Definition: document.cxx:4788
SdrObject * GetObjectAtPoint(SCTAB nTab, const Point &rPos)
Definition: documen9.cxx:397
void TrackFormulas(SfxHintId nHintId=SfxHintId::ScDataChanged)
Definition: documen7.cxx:527
SC_DLLPUBLIC OUString GetPageStyle(SCTAB nTab) const
Definition: document.cxx:6188
BroadcastAreaSlots and their management, once per document.
Definition: bcaslot.hxx:246
SC_DLLPUBLIC void SetRowHeightRange(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, sal_uInt16 nNewHeight)
Definition: document.cxx:4103
ScMutationGuard(ScDocument *pDocument, ScMutationGuardFlags nFlags)
Definition: document.hxx:2659
void CreateColumnIfNotExists(SCTAB nTab, SCCOL nCol)
Definition: document10.cxx:976
void DecXMLImportedFormulaCount(sal_uLong nVal)
Definition: document.hxx:2368
SC_DLLPUBLIC SCROW GetFirstEditTextRow(const ScRange &rRange) const
Definition: document.cxx:3424
css::uno::Reference< css::chart2::XChartDocument > GetChartByName(const OUString &rChartName)
Definition: documen5.cxx:137
Instantiate this to ensure that subsequent modification of the document will cause an assertion failu...
Definition: document.hxx:2625
void BroadcastUno(const SfxHint &rHint)
Definition: documen3.cxx:930
const T * GetEffItem(SCCOL nCol, SCROW nRow, SCTAB nTab, TypedWhichId< T > nWhich) const
Definition: document.hxx:1748
OUString GetLinkFlt(SCTAB nTab) const
Definition: documen3.cxx:499
void SetSubTotalCellsDirty(const ScRange &rDirtyRange)
Definition: document.cxx:6426
void RemoveSubTotalCell(ScFormulaCell *pCell)
Definition: document.cxx:6405
SC_DLLPUBLIC const EditTextObject * GetEditText(const ScAddress &rPos) const
Definition: document.cxx:3613
bool IsInExternalReferenceMarking() const
Definition: documen3.cxx:613
void SaveDdeLinks(SvStream &rStream) const
Definition: documen8.cxx:707
formula::FormulaGrammar::Grammar GetStorageGrammar() const
Definition: document.hxx:2444
sal_uLong nFormulaCodeInTree
Definition: document.hxx:469
SCTAB nTableCount
Definition: document.hxx:277
SC_DLLPUBLIC tools::Rectangle GetMMRect(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, bool bHiddenAsZero=true) const
Definition: documen3.cxx:1953
bool IsBlockEmpty(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool bIgnoreNotes=false) const
Definition: document.cxx:5298
void IncInterpreterTableOpLevel()
Definition: document.hxx:2343
void DeleteObjectsInArea(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, bool bAnchored=false)
Definition: documen9.cxx:250
sal_uInt16 GetCommonWidth(SCCOL nEndCol, SCTAB nTab) const
Definition: document.cxx:4147
void ResetChanged(const ScRange &rRange)
Definition: document.cxx:4073
SCROW GetRowForHeight(SCTAB nTab, sal_uLong nHeight) const
Given the height i.e.
Definition: document.cxx:4195
sal_Int32 GetMaxNumberStringLen(sal_uInt16 &nPrecision, SCTAB nTab, SCCOL nCol, SCROW nRowStart, SCROW nRowEnd) const
Maximum string length of numerical cells of a column, e.g.
Definition: documen4.cxx:597
std::set< ScTypedStrData, ScTypedStrData::LessCaseSensitive > ScTypedCaseStrSet
Definition: document.hxx:259
void SetLoadingMedium(bool bVal)
Definition: documen9.cxx:578
void GetSearchAndReplaceStart(const SvxSearchItem &rSearchItem, SCCOL &rCol, SCROW &rRow)
Definition: documen3.cxx:1190
SC_DLLPUBLIC void DoMerge(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool bDeleteCaptions=true)
Definition: documen3.cxx:2033
SC_DLLPUBLIC void AddPrintRange(SCTAB nTab, const ScRange &rNew)
Adds a new print ranges.
Definition: document.cxx:6311
bool CompileErrorCells(FormulaError nErrCode)
Re-compile formula cells with error.
Definition: document.cxx:4012
Definition: document.hxx:252
std::unique_ptr< ScScriptTypeData > pScriptTypeData
Definition: document.hxx:407
Definition: document.hxx:867
void RemoveManualBreaks(SCTAB nTab)
Definition: document.cxx:6229
SC_DLLPUBLIC bool HasValueData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3767
SC_DLLPUBLIC ScPostIt * CreateNote(const ScAddress &rPos)
Definition: document.cxx:6608
bool HasSelectedBlockMatrixFragment(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, const ScMarkData &rMark) const
Definition: document.cxx:5409
std::unique_ptr< sc::DocumentLinkManager > mpDocLinkMgr
Definition: document.hxx:369
SC_DLLPUBLIC const SfxItemSet * GetCondResult(SCCOL nCol, SCROW nRow, SCTAB nTab, ScRefCellValue *pCell=nullptr) const
Definition: documen4.cxx:788
bool HasLinkFormulaNeedingCheck() const
Definition: document.hxx:2126
void GetNumberFormatInfo(const ScInterpreterContext &rContext, SvNumFormatType &nType, sal_uInt32 &nIndex, const ScAddress &rPos) const
Definition: document.cxx:3701
bool CanInsertCol(const ScRange &rRange) const
Definition: document.cxx:1477
Use this class as a locale variable to merge number formatter from another document, and set NULL pointer to pFormatExchangeList when done.
Definition: document.hxx:2561
std::unique_ptr< ScNoteEditEngine > mpNoteEngine
Definition: document.hxx:378
SC_DLLPUBLIC void StoreTabToCache(SCTAB nTab, SvStream &rStrm) const
void UpdateChartRef(UpdateRefMode eUpdateRefMode, SCCOL nCol1, SCROW nRow1, SCTAB nTab1, SCCOL nCol2, SCROW nRow2, SCTAB nTab2, SCCOL nDx, SCROW nDy, SCTAB nDz)
Definition: documen5.cxx:390
void Broadcast(const ScHint &rHint)
Broadcast wrapper, calls rHint.GetCell()->Broadcast() and AreaBroadcast() and TrackFormulas() Preferr...
Definition: documen7.cxx:117
void UpdStlShtPtrsFrmNms()
Definition: document.cxx:6111
bool CanInsertRow(const ScRange &rRange) const
Definition: document.cxx:1191
ScDocument * mpDocument
Definition: document.hxx:2644
void CheckVectorizationState()
Definition: document.cxx:3823
SC_DLLPUBLIC bool ExtendMerge(SCCOL nStartCol, SCROW nStartRow, SCCOL &rEndCol, SCROW &rEndRow, SCTAB nTab, bool bRefresh=false)
Definition: document.cxx:5570
SC_DLLPUBLIC bool HasNote(const ScAddress &rPos) const
Definition: document.cxx:6535
void CompileDBFormula()
Definition: documen4.cxx:556
void ForgetNoteCaptions(const ScRangeList &rRanges, bool bPreserveData)
Definition: document.cxx:6633
sal_Int32 GetMaxStringLen(SCTAB nTab, SCCOL nCol, SCROW nRowStart, SCROW nRowEnd, rtl_TextEncoding eCharSet) const
Maximum string length of a column, e.g.
Definition: documen4.cxx:588
bool ValidAddress(const ScAddress &rAddress) const
Definition: document.hxx:883
ScAutoNameCache * GetAutoNameCache()
Definition: document.hxx:1341
void UpdateRefAreaLinks(UpdateRefMode eUpdateRefMode, const ScRange &r, SCCOL nDx, SCROW nDy, SCTAB nDz)
Definition: documen8.cxx:1081
sal_uInt16 nPageCount
Definition: document.hxx:280
void LockStreamValid(bool bLock)
Definition: document.cxx:930
sal_uInt32 GetDocumentID() const
an ID unique to each document instance
Definition: documen2.cxx:252
css::uno::Reference< css::script::vba::XVBAEventProcessor > mxVbaEvents
Definition: document.hxx:452
bool HasFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4509
bool mbExecuteLinkEnabled
Definition: document.hxx:555
void GetDataEntries(SCCOL nCol, SCROW nRow, SCTAB nTab, std::vector< ScTypedStrData > &rStrings, bool bLimit=false)
Entries for selection list listbox (no numbers/formulas)
Definition: documen3.cxx:1582
void BroadcastCells(const ScRange &rRange, SfxHintId nHint, bool bBroadcastSingleBroadcasters=true)
Definition: documen7.cxx:143
bool bCalculatingFormulaTree
Definition: document.hxx:500
static void SetupFromNonThreadedContext(ScInterpreterContext &threadedContext, int threadNumber)
Definition: document.cxx:6835
SC_DLLPUBLIC bool HasStringData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3758
bool HasLink(const OUString &rDoc, const OUString &rFilter, const OUString &rOptions) const
Definition: documen3.cxx:535
SC_DLLPUBLIC void SetRepeatRowRange(SCTAB nTab, std::unique_ptr< ScRange > pNew)
Definition: document.cxx:6329
SC_DLLPUBLIC void EnsureTable(SCTAB nTab)
Definition: documen2.cxx:537
Iterate through all edit text cells in a given sheet.
SC_DLLPUBLIC void GetFilterEntriesArea(SCCOL nCol, SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bCaseSens, ScFilterEntries &rFilterEntries)
Entries for Filter dialog.
Definition: documen3.cxx:1568
void SetCalcNotification(SCTAB nTab)
Definition: documen3.cxx:702
ScDocument & mrDoc
Definition: document.hxx:2682
SC_DLLPUBLIC void SetColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual)
Definition: document.cxx:4399
SC_DLLPUBLIC ScMacroManager * GetMacroManager()
Definition: documen8.cxx:377
FormulaError GetErrCode(const ScAddress &) const
Definition: document.cxx:4065
bool bInLinkUpdate
Definition: document.hxx:517
void SetChartRangeList(const OUString &rChartName, const ScRangeListRef &rNewRangeListRef)
only assigns the new RangeList, no ChartListener or the like
Definition: documen5.cxx:481
SC_DLLPUBLIC const ScViewOptions & GetViewOptions() const
Definition: documen3.cxx:1918
Definition: document.hxx:490
Represents the type of sheet geometry data.
Definition: document.hxx:266
void RemoveSubTotals(SCTAB nTab, ScSubTotalParam &rParam)
Definition: documen3.cxx:752
void AddUnoObject(SfxListener &rObject)
Definition: documen3.cxx:879
std::unique_ptr< ScUnoRefList > pUnoRefUndoList
Definition: document.hxx:405
std::unique_ptr< SvMemoryStream > pClipData
Definition: document.hxx:400
bool bIsVisible
Definition: document.hxx:504
SC_DLLPUBLIC void CalcAfterLoad(bool bStartListening=true)
Definition: document.cxx:4028
OUString GetCopyTabName(SCTAB nTab) const
Definition: document.cxx:226
void CopyBlockFromClip(sc::CopyFromClipContext &rCxt, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, SCCOL nDx, SCROW nDy)
Definition: document.cxx:2621
void SetRangeOverflowType(ErrCode nType)
Definition: document.hxx:2131
bool IsEditActionAllowed(sc::ColRowEditAction eAction, SCTAB nTab, SCCOLROW nStart, SCCOLROW nEnd) const
Definition: document10.cxx:950
Configuration options for formula interpreter.
Definition: calcconfig.hxx:43
bool IsDelayedFormulaGrouping() const
Definition: document.hxx:1375
bool IsCalculatingFormulaTree() const
Definition: document.hxx:1371
Definition: global.hxx:149
void GetUpperCellString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rStr)
Definition: documen3.cxx:1436
SCROW SanitizeRow(SCROW nRow) const
Definition: document.hxx:885
SC_DLLPUBLIC void DoEmptyBlock(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow)
Definition: documen3.cxx:2020
SC_DLLPUBLIC ScLkUpdMode GetLinkMode() const
Definition: document.hxx:2173
SC_DLLPUBLIC void GetScenarioData(SCTAB nTab, OUString &rComment, Color &rColor, ScScenarioFlags &rFlags) const
Definition: documen3.cxx:449
void LockTable(SCTAB nTab)
Definition: document.cxx:5309
bool IdleCalcTextWidth()
Definition: documen8.cxx:530
SC_DLLPUBLIC double RoundValueAsShown(double fVal, sal_uInt32 nFormat, const ScInterpreterContext *pContext=nullptr) const
Definition: documen4.cxx:633
void CreateAllNoteCaptions()
Ensure that all note objects have an associated sdr object.
Definition: document.cxx:6624
void finalizeOutlineImport()
Definition: document10.cxx:569
void SetDetOpList(std::unique_ptr< ScDetOpList > pNew)
Definition: documen4.cxx:903
bool ValidColRow(SCCOL nCol, SCROW nRow) const
Definition: document.hxx:880
void SyncColRowFlags()
Write all column row flags to table's flag data, because not all column row attributes are stored in ...
Definition: document.cxx:4565
bool IsStyleSheetUsed(const ScStyleSheet &rStyle) const
Definition: document.cxx:4982
static thread_local ScDocumentThreadSpecific maThreadSpecific
Definition: document.hxx:479
void FindMaxRotCol(SCTAB nTab, RowInfo *pRowInfo, SCSIZE nArrCount, SCCOL nX1, SCCOL nX2) const
Definition: document.cxx:5238
bool IsInDtorClear() const
Definition: document.hxx:2358
o3tl::sorted_vector< sal_uInt32 > ScCondFormatIndexes
Definition: document.hxx:201
void SetNumberFormat(const ScAddress &rPos, sal_uInt32 nNumberFormat)
Definition: document.cxx:3691
SC_DLLPUBLIC void SetPageStyle(SCTAB nTab, const OUString &rName)
Definition: document.cxx:6182
SC_DLLPUBLIC bool EnsureFormulaCellResults(const ScRange &rRange, bool bSkipRunning=false)
Make sure all of the formula cells in the specified range have been fully calculated.
Definition: document10.cxx:985