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  */
20 #pragma once
22 #include <vcl/idle.hxx>
23 #include <vcl/errcode.hxx>
24 #include <com/sun/star/uno/Reference.hxx>
25 #include <vcl/vclptr.hxx>
26 #include "patattr.hxx"
27 #include "scdllapi.h"
28 #include "interpretercontext.hxx"
29 #include "rangelst.hxx"
30 #include "rangenam.hxx"
31 #include "tabopparams.hxx"
32 #include "types.hxx"
33 #include <formula/grammar.hxx>
34 #include <formula/types.hxx>
35 #include "typedstrdata.hxx"
36 #include "calcmacros.hxx"
37 #include "calcconfig.hxx"
38 #include "sheetlimits.hxx"
39 #include <o3tl/deleter.hxx>
40 #include <o3tl/sorted_vector.hxx>
41 #include <svl/hint.hxx>
42 #include <svl/typedwhich.hxx>
43 #include <svl/zforlist.hxx>
44 #include <tools/gen.hxx>
45 #include <tools/solar.h>
47 #include <cassert>
48 #include <memory>
49 #include <map>
50 #include <set>
51 #include <unordered_map>
52 #include <vector>
54 #include "markdata.hxx"
55 #include "drwlayer.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  std::unique_ptr<ScRecursionHelper> xRecursionHelper; // information for recursive and iterative cell formulas
300  ScInterpreterContext* pContext = nullptr; // references the context passed around for easier access
301 };
305 {
306  // Bit mask bits
307  CORE = 0x0001,
308 };
310 typedef std::unique_ptr<ScTable, o3tl::default_delete<ScTable>> ScTableUniquePtr;
313 {
314 friend class ScValueIterator;
318 friend class ScCellIterator;
319 friend class ScQueryCellIterator;
323 friend class ScDocAttrIterator;
325 friend class ScAttrRectIterator;
326 friend class ScDocShell;
329 friend class ScFormulaCell;
330 friend class ScTable;
331 friend class ScColumn;
332 friend struct ScRefCellValue;
333 friend class ScDocumentImport;
335 friend class sc::ColumnSpanSet;
337 friend class sc::EditTextIterator;
340 friend struct ScMutationGuard;
341 friend struct ScMutationDisable;
343  typedef std::vector<ScTableUniquePtr> TableContainer;
345 public:
346  enum class HardRecalcState
347  {
348  OFF,
351  };
353 private:
356  std::shared_ptr<svl::SharedStringPool> mpCellStringPool;
357  std::unique_ptr<sc::DocumentLinkManager> mpDocLinkMgr;
359  std::shared_ptr<sc::FormulaGroupContext> mpFormulaGroupCxt;
365  std::unique_ptr<ScFieldEditEngine> mpEditEngine; // uses pEditPool from xPoolHelper
366  std::unique_ptr<ScNoteEditEngine> mpNoteEngine; // uses pEditPool from xPoolHelper
370  std::unique_ptr<ScDrawLayer> mpDrawLayer; // SdrModel
372  std::unique_ptr<ScValidationDataList> pValidationList; // validity
373  SvNumberFormatterIndexTable* pFormatExchangeList; // for application of number formats
374  TableContainer maTabs;
376  std::vector<OUString> maTabNames; // for undo document, we need the information tab name <-> index
377  mutable std::unique_ptr<ScRangeName> pRangeName;
378  std::unique_ptr<ScDBCollection> pDBCollection;
379  std::unique_ptr<ScDPCollection> pDPCollection;
380  std::unique_ptr< ScTemporaryChartLock > apTemporaryChartLock;
381  std::unique_ptr<ScPatternAttr> pSelectionAttr; // Attributes of a block
382  ScFormulaCell* pFormulaTree; // formula tree (start)
383  ScFormulaCell* pEOFormulaTree; // formula tree (end), last cell
384  ScFormulaCell* pFormulaTrack; // BroadcastTrack (start)
385  ScFormulaCell* pEOFormulaTrack; // BroadcastTrack (end), last cell
386  std::unique_ptr<ScBroadcastAreaSlotMachine> pBASM; // BroadcastAreas
387  std::unique_ptr<ScChartListenerCollection> pChartListenerCollection;
388  std::unique_ptr<SvMemoryStream> pClipData;
389  std::unique_ptr<ScDetOpList> pDetOpList;
390  std::unique_ptr<ScChangeTrack> pChangeTrack;
391  std::unique_ptr<SfxBroadcaster> pUnoBroadcaster;
392  std::unique_ptr<ScUnoListenerCalls> pUnoListenerCalls;
393  std::unique_ptr<ScUnoRefList> pUnoRefUndoList;
394  std::unique_ptr<ScChangeViewSettings> pChangeViewSettings;
395  std::unique_ptr<ScScriptTypeData> pScriptTypeData;
396  std::unique_ptr<ScRefreshTimerControl> pRefreshTimerControl;
397  std::shared_ptr<SvxForbiddenCharactersTable> xForbiddenCharacters;
398  std::unique_ptr<ScDBData> mpAnonymousDBData;
399  std::unique_ptr<sc::ExternalDataMapper> mpDataMapper;
401  std::unique_ptr<ScFieldEditEngine> pCacheFieldEditEngine;
403  std::unique_ptr<ScDocProtection> pDocProtection;
404  std::unique_ptr<ScClipParam> mpClipParam;
406  std::unique_ptr<ScExternalRefManager> pExternalRefMgr;
407  std::unique_ptr<ScMacroManager> mpMacroMgr;
409  // mutable for lazy construction
410  mutable std::unique_ptr< ScFormulaParserPool >
413  OUString aDocName; // optional: name of document
414  OUString aDocCodeName; // optional: name of document (twice?)
415  OUString maFileURL; // file URL for copy & paste
419  std::unique_ptr<ScViewOptions> pViewOptions; // view options
420  std::unique_ptr<ScDocOptions> pDocOptions; // document options
421  std::unique_ptr<ScExtDocOptions> pExtDocOptions; // for import etc.
422  std::unique_ptr<ScClipOptions> mpClipOptions; // clipboard options
423  std::unique_ptr<ScConsolidateParam> pConsolidateDlgData;
425  std::unique_ptr<ScAutoNameCache> pAutoNameCache; // for automatic name lookup during CompileXML
427  std::unique_ptr<SfxItemSet> pPreviewFont; // convert to std::unique_ptr or whatever
430  sal_Int64 nUnoObjectId; // counted up for UNO objects
432  ErrCode nRangeOverflowType; // used in (xml) loading for overflow warnings
439  css::uno::Reference< css::script::vba::XVBAEventProcessor >
441 public:
443  std::vector<ScInterpreterTableOpParams*> m_TableOpList;
446 private:
448  LanguageType eLanguage; // default language
449  LanguageType eCjkLanguage; // default language for asian text
450  LanguageType eCtlLanguage; // default language for complex text
451  rtl_TextEncoding eSrcSet; // during reading: source character set
457  sal_uLong nFormulaCodeInTree; // formula RPN in the formula tree
458  sal_uLong nXMLImportedFormulaCount; // progress count during XML import
459  sal_uInt16 nInterpretLevel; // >0 if in interpreter
460  sal_uInt16 nMacroInterpretLevel; // >0 if macro in interpreter
461  sal_uInt16 nInterpreterTableOpLevel; // >0 if in interpreter TableOp
465  // There can be only one ScDocument being calculated in a thread at a time, so we can use a
466  // plain thread_local static member.
471  osl::Mutex mScLookupMutex; // protection for thread-unsafe parts of handling ScLookup
473  static const sal_uInt16 nSrcVer; // file version (load/save)
474  sal_uInt16 nFormulaTrackCount;
475  HardRecalcState eHardRecalcState; // off, temporary, eternal
476  SCTAB nVisibleTab; // for OLE etc., don't use inside ScDocument
477  SCCOL nPosLeft; // for OLE etc., don't use inside ScDocument
478  SCROW nPosTop; // for OLE etc., don't use inside ScDocument
482  bool bAutoCalc; // calculate automatically
483  bool bAutoCalcShellDisabled; // in/from/for ScDocShell disabled
484  // are there ForcedFormulas which have to be calculated
485  // in interaction with ScDocShell SetDocumentModified,
486  // AutoCalcShellDisabled and TrackFormulas
489  bool bIsClip;
490  bool bIsUndo;
492  bool bIsVisible; // set from view ctor
494  bool bIsEmbedded; // display/adjust Embedded area?
496  // no broadcast, construct no listener during insert from a different
497  // Doc (per filter or the like ), not until CompileAll / CalcAfterLoad
500  bool bImportingXML; // special handling of formula text
501  bool bCalcingAfterLoad; // in CalcAfterLoad TRUE
502  // don't construct/destruct listeners temporarily
505  bool bInLinkUpdate; // TableLink or AreaLink
507  // are/were there RC_FORCED formula cells in the document (if set once to TRUE then set forever)
509  // is the Doc being destroyed? (no Notify-Tracking etc. needed anymore)
511  // expand reference if insert column/row takes place at the border
512  // of a reference
513  // is fetched in each UpdateReference from InputOptions,
514  // assigned, and restored at the end of UpdateReference
516  // for detective update, is set for each change of a formula
518  // If the pointer is set, formula cells will not be automatically grouped into shared formula groups,
519  // instead the range will be extended to contain all such cells.
520  std::unique_ptr< ScRange > pDelayedFormulaGrouping;
521  // If non-empty, ScColumn::StartListeningFormulaCells() calls may be delayed using this,
522  // avoiding repeated calling for the same cells in the given range. The function will be called once
523  // later for all the cells in the range.
524  std::unordered_map< ScColumn*, std::pair<SCROW, SCROW>> pDelayedStartListeningFormulaCells;
526  bool bLinkFormulaNeedingCheck; // valid only after loading, for ocDde and ocWebservice
533  sal_uInt8 nInDdeLinkUpdate; // originating DDE links (stacked bool)
537  sal_uInt32 nAdjustHeightLock;
544  bool mbChangeReadOnlyEnabled:1; // allow changes in read-only document (for API import filters)
546  bool mbUserInteractionEnabled:1; // whether or not to launch any kind of interactive dialogs.
550  std::set<ScFormulaCell*> maSubTotalCells;
553  bool mbEmbedFonts : 1;
559  std::unique_ptr<sc::IconSetBitmapMap> m_pIconSetBitmapMap;
563  // This indicates if a ScDocShell::DoRecalc() or ScDocShell::DoHardRecalc() is in progress.
568 public:
569  bool IsCellInChangeTrack(const ScAddress &cell,Color *pColCellBorder);
570  void GetCellChangeTrackNote(const ScAddress &cell, OUString &strTrackText, bool &pbLeftEdge);
572  bool IsEmbedFonts() const { return mbEmbedFonts; }
578  void SetEmbedFonts(bool bUse) { mbEmbedFonts = bUse; }
579  void SetEmbedUsedFontsOnly(bool bUse) { mbEmbedUsedFontsOnly = bUse; }
584  SC_DLLPUBLIC sal_uLong GetCellCount() const; // all cells
585  SC_DLLPUBLIC sal_uLong GetFormulaGroupCount() const; // all cells
586  sal_uLong GetCodeCount() const; // RPN-Code in formulas
587  DECL_LINK( GetUserDefinedColor, sal_uInt16, Color* );
588  // number formatter
589 public:
591  SfxObjectShell* pDocShell = nullptr );
594  void SetName( const OUString& r ) { aDocName = r; }
595  const OUString& GetCodeName() const { return aDocCodeName; }
596  void SetCodeName( const OUString& r ) { aDocCodeName = r; }
597  const OUString& GetFileURL() const { return maFileURL; }
599  void GetDocStat( ScDocStat& rDocStat );
601  SC_DLLPUBLIC void InitDrawLayer( SfxObjectShell* pDocShell = nullptr );
604  {
606  return maInterpreterContext;
607  }
608  // Uses thread_local.
610  {
611  return IsThreadedGroupCalcInProgress() ? *maThreadSpecific.pContext : GetNonThreadedContext();
612  }
613  void SetupContextFromNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber );
614  void MergeContextBackIntoNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber );
624  SC_DLLPUBLIC const ScDocOptions& GetDocOptions() const;
625  SC_DLLPUBLIC void SetDocOptions( const ScDocOptions& rOpt );
627  SC_DLLPUBLIC void SetViewOptions( const ScViewOptions& rOpt );
628  void SetPrintOptions();
630  ScExtDocOptions* GetExtDocOptions() { return pExtDocOptions.get(); }
631  SC_DLLPUBLIC void SetExtDocOptions( std::unique_ptr<ScExtDocOptions> pNewOptions );
633  ScClipOptions* GetClipOptions() { return mpClipOptions.get(); }
634  void SetClipOptions(std::unique_ptr<ScClipOptions> pClipOptions);
636  SC_DLLPUBLIC void GetLanguage( LanguageType& rLatin, LanguageType& rCjk, LanguageType& rCtl ) const;
637  void SetLanguage( LanguageType eLatin, LanguageType eCjk, LanguageType eCtl );
639  void SetConsolidateDlgData( std::unique_ptr<ScConsolidateParam> pData );
640  const ScConsolidateParam* GetConsolidateDlgData() const { return pConsolidateDlgData.get(); }
642  void Clear( bool bFromDestructor = false );
644  std::unique_ptr<ScFieldEditEngine> CreateFieldEditEngine();
645  void DisposeFieldEditEngine(std::unique_ptr<ScFieldEditEngine>& rpEditEngine);
652  SC_DLLPUBLIC void SetAllRangeNames(const std::map<OUString, std::unique_ptr<ScRangeName>>& rRangeMap);
653  SC_DLLPUBLIC void GetRangeNameMap(std::map<OUString, ScRangeName*>& rRangeName);
656  void SetRangeName(SCTAB nTab, std::unique_ptr<ScRangeName> pNew);
657  void SetRangeName( std::unique_ptr<ScRangeName> pNewRangeName );
658  bool IsAddressInRangeName( RangeNameScope eScope, const ScAddress& rAddress);
667  ScRangeData* FindRangeNameBySheetAndIndex( SCTAB nTab, sal_uInt16 nIndex ) const;
713  SCTAB nTokenTab, const sal_uInt16 nTokenIndex,
714  SCTAB nGlobalRefTab, SCTAB nLocalRefTab, SCTAB nOldTokenTab, SCTAB nOldTokenTabReplacement,
715  bool bSameDoc, int nRecursion ) const;
757  bool CopyAdjustRangeName( SCTAB& rSheet, sal_uInt16& rIndex, ScRangeData*& rpRangeData, ScDocument& rNewDoc,
758  const ScAddress& rNewPos, const ScAddress& rOldPos, const bool bGlobalNamesToLocal,
759  const bool bUsedByFormula ) const;
764  SC_DLLPUBLIC void PreprocessAllRangeNamesUpdate( const std::map<OUString, std::unique_ptr<ScRangeName>>& rRangeMap );
782  bool InsertNewRangeName( const OUString& rName, const ScAddress& rPos, const OUString& rExpr );
795  bool InsertNewRangeName( SCTAB nTab, const OUString& rName, const ScAddress& rPos, const OUString& rExpr );
803  SCTAB GetMaxTableNumber() const { return static_cast<SCTAB>(maTabs.size()) - 1; }
805  ScRangePairList* GetColNameRanges() { return xColNameRanges.get(); }
806  ScRangePairList* GetRowNameRanges() { return xRowNameRanges.get(); }
813  SC_DLLPUBLIC ScDBCollection* GetDBCollection() const { return pDBCollection.get();}
814  void SetDBCollection( std::unique_ptr<ScDBCollection> pNewDBCollection,
815  bool bRemoveAutoFilter = false );
816  const ScDBData* GetDBAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab, ScDBDataPortion ePortion) const;
817  ScDBData* GetDBAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab, ScDBDataPortion ePortion);
818  SC_DLLPUBLIC const ScDBData* GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2) const;
819  SC_DLLPUBLIC ScDBData* GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2);
823  SC_DLLPUBLIC const ScRangeData* GetRangeAtBlock( const ScRange& rBlock, OUString& rName,
824  bool* pSheetLocal = nullptr ) const;
826  SC_DLLPUBLIC bool HasPivotTable() const;
829  SC_DLLPUBLIC ScDPObject* GetDPAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab) const;
830  ScDPObject* GetDPAtBlock( const ScRange& rBlock ) const;
832  void StopTemporaryChartLock();
834  void EnsureGraphicNames();
836  SdrObject* GetObjectAtPoint( SCTAB nTab, const Point& rPos );
837  bool HasChartAtPoint( SCTAB nTab, const Point& rPos, OUString& rName );
839  css::uno::Reference< css::chart2::XChartDocument > GetChartByName( std::u16string_view rChartName );
841  SC_DLLPUBLIC void GetChartRanges( std::u16string_view rChartName, std::vector< ScRangeList >& rRanges, const ScDocument& rSheetNameDoc );
842  void SetChartRanges( std::u16string_view rChartName, const std::vector< ScRangeList >& rRanges );
844  void UpdateChartArea( const OUString& rChartName, const ScRange& rNewArea,
845  bool bColHeaders, bool bRowHeaders, bool bAdd );
846  void UpdateChartArea( const OUString& rChartName,
847  const ScRangeListRef& rNewList,
848  bool bColHeaders, bool bRowHeaders, bool bAdd );
849  void GetOldChartParameters( std::u16string_view rName,
850  ScRangeList& rRanges, bool& rColHeaders, bool& rRowHeaders );
851  css::uno::Reference<
852  css::embed::XEmbeddedObject >
853  FindOleObjectByName( std::u16string_view rName );
855  SC_DLLPUBLIC void MakeTable( SCTAB nTab,bool _bNeedsNameCheck = true );
857  SCTAB GetVisibleTab() const { return nVisibleTab; }
858  SC_DLLPUBLIC void SetVisibleTab(SCTAB nTab) { nVisibleTab = nTab; }
859  SCCOL GetPosLeft() const { return nPosLeft; }
860  SC_DLLPUBLIC void SetPosLeft(SCCOL nCol) { nPosLeft = nCol; }
861  SCROW GetPosTop() const { return nPosTop; }
862  SC_DLLPUBLIC void SetPosTop(SCROW nRow) { nPosTop = nRow; }
864  SC_DLLPUBLIC bool HasTable( SCTAB nTab ) const;
865  SC_DLLPUBLIC bool GetHashCode( SCTAB nTab, sal_Int64& rHashCode) const;
866  SC_DLLPUBLIC bool GetName( SCTAB nTab, OUString& rName ) const;
867  SC_DLLPUBLIC bool GetCodeName( SCTAB nTab, OUString& rName ) const;
868  SC_DLLPUBLIC bool SetCodeName( SCTAB nTab, const OUString& rName );
869  SC_DLLPUBLIC bool GetTable( const OUString& rName, SCTAB& rTab ) const;
870  SC_DLLPUBLIC SCCOL MaxCol() const { return mxSheetLimits->mnMaxCol; }
871  SC_DLLPUBLIC SCROW MaxRow() const { return mxSheetLimits->mnMaxRow; }
873  [[nodiscard]] bool ValidCol(SCCOL nCol) const { return ::ValidCol(nCol, mxSheetLimits->mnMaxCol); }
874  [[nodiscard]] bool ValidRow(SCROW nRow) const { return ::ValidRow(nRow, mxSheetLimits->mnMaxRow); }
875  [[nodiscard]] bool ValidColRow(SCCOL nCol, SCROW nRow) const { return ::ValidColRow(nCol, nRow, MaxCol(), MaxRow()); }
876  [[nodiscard]] bool ValidColRowTab(SCCOL nCol, SCROW nRow, SCTAB nTab) const { return ::ValidColRowTab(nCol, nRow, nTab, MaxCol(), MaxRow()); }
877  [[nodiscard]] bool ValidRange(const ScRange& rRange) const { return ::ValidRange(rRange, MaxCol(), MaxRow()); }
878  [[nodiscard]] bool ValidAddress(const ScAddress& rAddress) const { return ::ValidAddress(rAddress, MaxCol(), MaxRow()); }
879  [[nodiscard]] SCCOL SanitizeCol( SCCOL nCol ) const { return ::SanitizeCol(nCol, MaxCol()); }
880  [[nodiscard]] SCROW SanitizeRow( SCROW nRow ) const { return ::SanitizeRow(nRow, MaxRow()); }
882  SC_DLLPUBLIC std::vector<OUString> GetAllTableNames() const;
884  OUString GetCopyTabName(SCTAB nTab) const;
886  SC_DLLPUBLIC void SetAnonymousDBData(SCTAB nTab, std::unique_ptr<ScDBData> pDBData);
893  SC_DLLPUBLIC void SetAnonymousDBData(std::unique_ptr<ScDBData> pDBData);
900  SC_DLLPUBLIC void SetDocProtection(const ScDocProtection* pProtect);
901  SC_DLLPUBLIC bool IsDocProtected() const;
902  bool IsDocEditable() const;
903  SC_DLLPUBLIC bool IsTabProtected( SCTAB nTab ) const;
905  SC_DLLPUBLIC void SetTabProtection(SCTAB nTab, const ScTableProtection* pProtect);
906  void CopyTabProtection(SCTAB nTabSrc, SCTAB nTabDest);
908  void LockTable(SCTAB nTab);
909  void UnlockTable(SCTAB nTab);
911  bool IsBlockEditable( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
912  SCCOL nEndCol, SCROW nEndRow,
913  bool* pOnlyNotBecauseOfMatrix = nullptr,
914  bool bNoMatrixAtAll = false ) const;
915  bool IsSelectionEditable( const ScMarkData& rMark,
916  bool* pOnlyNotBecauseOfMatrix = nullptr ) const;
917  bool HasSelectedBlockMatrixFragment( SCCOL nStartCol, SCROW nStartRow,
918  SCCOL nEndCol, SCROW nEndRow,
919  const ScMarkData& rMark ) const;
921  bool IsEditActionAllowed( sc::ColRowEditAction eAction, SCTAB nTab, SCCOLROW nStart, SCCOLROW nEnd ) const;
922  bool IsEditActionAllowed( sc::ColRowEditAction eAction, const ScMarkData& rMark, SCCOLROW nStart, SCCOLROW nEnd ) const;
924  SC_DLLPUBLIC bool GetMatrixFormulaRange( const ScAddress& rCellPos, ScRange& rMatrix );
926  bool IsEmbedded() const { return bIsEmbedded;}
927  void GetEmbedded( ScRange& rRange ) const;
928  void SetEmbedded( const ScRange& rRange );
929  void ResetEmbedded();
930  tools::Rectangle GetEmbeddedRect() const; // 1/100 mm
931  void SetEmbedded( SCTAB nTab, const tools::Rectangle& rRect ); // from VisArea (1/100 mm)
933  static SC_DLLPUBLIC bool ValidTabName( const OUString& rName );
935  SC_DLLPUBLIC bool ValidNewTabName( const OUString& rName ) const;
936  SC_DLLPUBLIC void CreateValidTabName(OUString& rName) const;
937  SC_DLLPUBLIC void CreateValidTabNames(std::vector<OUString>& aNames, SCTAB nCount) const;
939  void AppendTabOnLoad(const OUString& rName);
940  void SetTabNameOnLoad(SCTAB nTab, const OUString& rName);
941  void InvalidateStreamOnSave();
943  SC_DLLPUBLIC bool InsertTab( SCTAB nPos, const OUString& rName,
944  bool bExternalDocument = false, bool bUndoDeleteTab = false );
946  SC_DLLPUBLIC bool InsertTabs( SCTAB nPos, const std::vector<OUString>& rNames,
947  bool bNamesValid = false );
948  SC_DLLPUBLIC bool DeleteTabs( SCTAB nTab, SCTAB nSheets );
949  SC_DLLPUBLIC bool DeleteTab( SCTAB nTab );
950  SC_DLLPUBLIC bool RenameTab( SCTAB nTab, const OUString& rName,
951  bool bExternalDocument = false );
952  bool MoveTab( SCTAB nOldPos, SCTAB nNewPos, ScProgress* pProgress = nullptr );
953  bool CopyTab( SCTAB nOldPos, SCTAB nNewPos,
954  const ScMarkData* pOnlyMarked = nullptr );
955  SC_DLLPUBLIC sal_uLong TransferTab(ScDocument& rSrcDoc, SCTAB nSrcPos, SCTAB nDestPos,
956  bool bInsertNew = true,
957  bool bResultsOnly = false );
958  SC_DLLPUBLIC void TransferDrawPage(const ScDocument& rSrcDoc, SCTAB nSrcPos, SCTAB nDestPos);
959  SC_DLLPUBLIC void SetVisible( SCTAB nTab, bool bVisible );
960  SC_DLLPUBLIC bool IsVisible( SCTAB nTab ) const;
961  bool IsStreamValid( SCTAB nTab ) const;
962  void SetStreamValid( SCTAB nTab, bool bSet, bool bIgnoreLock = false );
963  void LockStreamValid( bool bLock );
964  bool IsStreamValidLocked() const { return mbStreamValidLocked; }
965  bool IsPendingRowHeights( SCTAB nTab ) const;
966  void SetPendingRowHeights( SCTAB nTab, bool bSet );
967  SC_DLLPUBLIC void SetLayoutRTL( SCTAB nTab, bool bRTL, ScObjectHandling eObjectHandling = ScObjectHandling::RecalcPosMode);
968  SC_DLLPUBLIC bool IsLayoutRTL( SCTAB nTab ) const;
969  SC_DLLPUBLIC bool IsNegativePage( SCTAB nTab ) const;
970  SC_DLLPUBLIC void SetScenario( SCTAB nTab, bool bFlag );
971  SC_DLLPUBLIC bool IsScenario( SCTAB nTab ) const;
972  SC_DLLPUBLIC void GetScenarioData(SCTAB nTab, OUString& rComment,
973  Color& rColor, ScScenarioFlags &rFlags) const;
974  SC_DLLPUBLIC void SetScenarioData(SCTAB nTab, const OUString& rComment,
975  const Color& rColor, ScScenarioFlags nFlags);
976  SC_DLLPUBLIC Color GetTabBgColor( SCTAB nTab ) const;
977  SC_DLLPUBLIC void SetTabBgColor( SCTAB nTab, const Color& rColor );
978  SC_DLLPUBLIC bool IsDefaultTabBgColor( SCTAB nTab ) const;
979  void GetScenarioFlags(SCTAB nTab, ScScenarioFlags &rFlags) const;
980  SC_DLLPUBLIC bool IsActiveScenario( SCTAB nTab ) const;
981  SC_DLLPUBLIC void SetActiveScenario( SCTAB nTab, bool bActive ); // only for Undo etc.
986  bool IsLinked( SCTAB nTab ) const;
987  SC_DLLPUBLIC OUString GetLinkDoc( SCTAB nTab ) const;
988  OUString GetLinkFlt( SCTAB nTab ) const;
989  OUString GetLinkOpt( SCTAB nTab ) const;
990  SC_DLLPUBLIC OUString GetLinkTab( SCTAB nTab ) const;
991  sal_uLong GetLinkRefreshDelay( SCTAB nTab ) const;
992  void SetLink( SCTAB nTab, ScLinkMode nMode, const OUString& rDoc,
993  const OUString& rFilter, const OUString& rOptions,
994  const OUString& rTabName, sal_uLong nRefreshDelay );
995  bool HasLink( std::u16string_view rDoc,
996  std::u16string_view rFilter, std::u16string_view rOptions ) const;
997  SC_DLLPUBLIC bool LinkExternalTab( SCTAB& nTab, const OUString& aDocTab,
998  const OUString& aFileName,
999  const OUString& aTabName );
1001  bool HasExternalRefManager() const { return bool(pExternalRefMgr); }
1003  bool IsInExternalReferenceMarking() const;
1005  bool MarkUsedExternalReferences( const ScTokenArray& rArr, const ScAddress& rPos );
1011  bool HasAreaLinks() const;
1013  void UpdateAreaLinks();
1015  // originating DDE links
1016  void IncInDdeLinkUpdate() { if ( nInDdeLinkUpdate < 255 ) ++nInDdeLinkUpdate; }
1017  void DecInDdeLinkUpdate() { if ( nInDdeLinkUpdate ) --nInDdeLinkUpdate; }
1018  bool IsInDdeLinkUpdate() const { return nInDdeLinkUpdate != 0; }
1020  SC_DLLPUBLIC void CopyDdeLinks( ScDocument& rDestDoc ) const;
1025  SC_DLLPUBLIC bool FindDdeLink( std::u16string_view rAppl, std::u16string_view rTopic,
1026  std::u16string_view rItem, sal_uInt8 nMode, size_t& rnDdePos );
1034  bool GetDdeLinkData( size_t nDdePos, OUString& rAppl, OUString& rTopic, OUString& rItem ) const;
1039  bool GetDdeLinkMode( size_t nDdePos, sal_uInt8& rnMode ) const;
1043  SC_DLLPUBLIC const ScMatrix* GetDdeLinkResultMatrix( size_t nDdePos ) const;
1048  SC_DLLPUBLIC bool CreateDdeLink( const OUString& rAppl, const OUString& rTopic, const OUString& rItem, sal_uInt8 nMode, const ScMatrixRef& pResults );
1053  bool SetDdeLinkResultMatrix( size_t nDdePos, const ScMatrixRef& pResults );
1057  SC_DLLPUBLIC ScDrawLayer* GetDrawLayer() { return mpDrawLayer.get(); }
1058  SC_DLLPUBLIC const ScDrawLayer* GetDrawLayer() const { return mpDrawLayer.get(); }
1059  SfxBroadcaster* GetDrawBroadcaster(); // to avoid header
1060  void BeginDrawUndo();
1062  void BeginUnoRefUndo();
1063  bool HasUnoRefUndo() const { return ( pUnoRefUndoList != nullptr ); }
1064  [[nodiscard]]
1065  std::unique_ptr<ScUnoRefList> EndUnoRefUndo(); // must be deleted by caller!
1066  sal_Int64 GetNewUnoId() { return ++nUnoObjectId; }
1067  void AddUnoRefChange( sal_Int64 nId, const ScRangeList& rOldRanges );
1069  static bool IsChart( const SdrObject* pObject );
1071  void UpdateChartRef( UpdateRefMode eUpdateRefMode,
1072  SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1073  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1074  SCCOL nDx, SCROW nDy, SCTAB nDz );
1076  void SetChartRangeList( std::u16string_view rChartName,
1077  const ScRangeListRef& rNewRangeListRef );
1079  void StartAnimations( SCTAB nTab );
1081  bool HasBackgroundDraw( SCTAB nTab, const tools::Rectangle& rMMRect ) const;
1082  bool HasAnyDraw( SCTAB nTab, const tools::Rectangle& rMMRect ) const;
1084  const ScSheetEvents* GetSheetEvents( SCTAB nTab ) const;
1085  void SetSheetEvents( SCTAB nTab, std::unique_ptr<ScSheetEvents> pNew );
1086  bool HasSheetEventScript( SCTAB nTab, ScSheetEventId nEvent, bool bWithVbaEvents = false ) const;
1087  bool HasAnySheetEventScript( ScSheetEventId nEvent, bool bWithVbaEvents = false ) const; // on any sheet
1089  bool HasAnyCalcNotification() const;
1090  bool HasCalcNotification( SCTAB nTab ) const;
1091  void SetCalcNotification( SCTAB nTab );
1092  void ResetCalcNotifications();
1094  SC_DLLPUBLIC ScOutlineTable* GetOutlineTable( SCTAB nTab, bool bCreate = false );
1095  bool SetOutlineTable( SCTAB nTab, const ScOutlineTable* pNewOutline );
1097  void DoAutoOutline( SCCOL nStartCol, SCROW nStartRow,
1098  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab );
1100  bool DoSubTotals( SCTAB nTab, ScSubTotalParam& rParam );
1101  void RemoveSubTotals( SCTAB nTab, ScSubTotalParam& rParam );
1102  bool TestRemoveSubTotals( SCTAB nTab, const ScSubTotalParam& rParam );
1103  bool HasSubTotalCells( const ScRange& rRange );
1105  SC_DLLPUBLIC void EnsureTable( SCTAB nTab );
1107  // return TRUE = number format is set
1108  SC_DLLPUBLIC bool SetString( SCCOL nCol, SCROW nRow, SCTAB nTab, const OUString& rString,
1109  const ScSetStringParam * pParam = nullptr );
1110  SC_DLLPUBLIC bool SetString( const ScAddress& rPos, const OUString& rString,
1111  const ScSetStringParam* pParam = nullptr );
1122  SC_DLLPUBLIC bool SetEditText( const ScAddress& rPos, std::unique_ptr<EditTextObject> pEditText );
1123  void SetEditText( const ScAddress& rPos, const EditTextObject& rEditText, const SfxItemPool* pEditPool );
1124  SC_DLLPUBLIC void SetEditText( const ScAddress& rPos, const OUString& rStr );
1125  SC_DLLPUBLIC SCROW GetFirstEditTextRow( const ScRange& rRange ) const;
1131  SC_DLLPUBLIC void SetTextCell( const ScAddress& rPos, const OUString& rStr );
1132  void SetEmptyCell( const ScAddress& rPos );
1133  SC_DLLPUBLIC void SetValue( SCCOL nCol, SCROW nRow, SCTAB nTab, const double& rVal );
1134  SC_DLLPUBLIC void SetValue( const ScAddress& rPos, double fVal );
1135  void SetValues( const ScAddress& rPos, const std::vector<double>& rVals );
1136  void SetError( SCCOL nCol, SCROW nRow, SCTAB nTab, const FormulaError nError);
1137  SC_DLLPUBLIC void SetFormula( const ScAddress& rPos, const ScTokenArray& rArray );
1138  SC_DLLPUBLIC void SetFormula( const ScAddress& rPos, const OUString& rFormula,
1150  bool SetFormulaCells( const ScAddress& rPos, std::vector<ScFormulaCell*>& rCells );
1155  bool HasFormulaCell( const ScRange& rRange ) const;
1156  SC_DLLPUBLIC void InsertMatrixFormula(SCCOL nCol1, SCROW nRow1,
1157  SCCOL nCol2, SCROW nRow2,
1158  const ScMarkData& rMark,
1159  const OUString& rFormula,
1160  const ScTokenArray* p = nullptr,
1162  SC_DLLPUBLIC void InsertTableOp(const ScTabOpParam& rParam, // multi-operation
1163  SCCOL nCol1, SCROW nRow1,
1164  SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark);
1166  SC_DLLPUBLIC OUString GetString( SCCOL nCol, SCROW nRow, SCTAB nTab,
1167  const ScInterpreterContext* pContext = nullptr ) const;
1168  SC_DLLPUBLIC OUString GetString( const ScAddress& rPos,
1169  const ScInterpreterContext* pContext = nullptr ) const;
1179  SC_DLLPUBLIC double* GetValueCell( const ScAddress& rPos );
1184  svl::SharedString GetSharedString( const ScAddress& rPos ) const;
1186  std::shared_ptr<sc::FormulaGroupContext>& GetFormulaGroupContext();
1189  { mbFormulaGroupCxtBlockDiscard = block; }
1191  SC_DLLPUBLIC void GetInputString( SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rString );
1192  FormulaError GetStringForFormula( const ScAddress& rPos, OUString& rString );
1193  SC_DLLPUBLIC double GetValue( const ScAddress& rPos ) const;
1194  SC_DLLPUBLIC double GetValue( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1195  SC_DLLPUBLIC void GetValue( SCCOL nCol, SCROW nRow, SCTAB nTab, double& rValue ) const;
1196  SC_DLLPUBLIC const EditTextObject* GetEditText( const ScAddress& rPos ) const;
1197  void RemoveEditTextCharAttribs( const ScAddress& rPos, const ScPatternAttr& rAttr );
1198  SC_DLLPUBLIC double RoundValueAsShown( double fVal, sal_uInt32 nFormat, const ScInterpreterContext* pContext = nullptr ) const;
1199  SC_DLLPUBLIC void GetNumberFormat( SCCOL nCol, SCROW nRow, SCTAB nTab,
1200  sal_uInt32& rFormat ) const;
1201  sal_uInt32 GetNumberFormat( const ScRange& rRange ) const;
1202  SC_DLLPUBLIC sal_uInt32 GetNumberFormat( const ScInterpreterContext& rContext, const ScAddress& ) const;
1203  void SetNumberFormat( const ScAddress& rPos, sal_uInt32 nNumberFormat );
1205  void GetNumberFormatInfo( const ScInterpreterContext& rContext, SvNumFormatType& nType, sal_uInt32& nIndex, const ScAddress& rPos ) const;
1206  SC_DLLPUBLIC const ScFormulaCell* GetFormulaCell( const ScAddress& rPos ) const;
1208  SC_DLLPUBLIC void GetFormula( SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rFormula ) const;
1209  SC_DLLPUBLIC void GetCellType( SCCOL nCol, SCROW nRow, SCTAB nTab, CellType& rCellType ) const;
1210  SC_DLLPUBLIC CellType GetCellType( const ScAddress& rPos ) const;
1212  SC_DLLPUBLIC bool HasData( SCCOL nCol, SCROW nRow, SCTAB nTab );
1213  SC_DLLPUBLIC bool HasStringData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1214  SC_DLLPUBLIC bool HasValueData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1215  SC_DLLPUBLIC bool HasValueData( const ScAddress& rPos ) const;
1216  bool HasStringCells( const ScRange& rRange ) const;
1219  bool HasSelectionData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1220  bool HasValidationData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1228  sc::MultiDataCellState HasMultipleDataCells( const ScRange& rRange ) const;
1231  SC_DLLPUBLIC ScPostIt* GetNote(const ScAddress& rPos);
1232  SC_DLLPUBLIC ScPostIt* GetNote(SCCOL nCol, SCROW nRow, SCTAB nTab);
1233  void SetNote(const ScAddress& rPos, std::unique_ptr<ScPostIt> pNote);
1234  void SetNote(SCCOL nCol, SCROW nRow, SCTAB nTab, std::unique_ptr<ScPostIt> pNote);
1235  SC_DLLPUBLIC bool HasNote(const ScAddress& rPos) const;
1236  bool HasNote(SCCOL nCol, SCROW nRow, SCTAB nTab) const;
1237  SC_DLLPUBLIC bool HasColNotes(SCCOL nCol, SCTAB nTab) const;
1238  SC_DLLPUBLIC bool HasTabNotes(SCTAB nTab) const;
1239  bool HasNotes() const;
1240  SC_DLLPUBLIC std::unique_ptr<ScPostIt> ReleaseNote(const ScAddress& rPos);
1242  SC_DLLPUBLIC ScPostIt* CreateNote(const ScAddress& rPos);
1243  size_t GetNoteCount( SCTAB nTab, SCCOL nCol ) const;
1249  void CreateAllNoteCaptions();
1250  void ForgetNoteCaptions( const ScRangeList& rRanges, bool bPreserveData );
1253  ScAddress GetNotePosition( size_t nIndex ) const;
1254  ScAddress GetNotePosition( size_t nIndex, SCTAB nTab ) const;
1255  SCROW GetNotePosition( SCTAB nTab, SCCOL nCol, size_t nIndex ) const;
1257  SC_DLLPUBLIC void GetAllNoteEntries( std::vector<sc::NoteEntry>& rNotes ) const;
1258  SC_DLLPUBLIC void GetAllNoteEntries( SCTAB nTab, std::vector<sc::NoteEntry>& rNotes ) const;
1259  void GetNotesInRange( const ScRangeList& rRange, std::vector<sc::NoteEntry>& rNotes ) const;
1260  bool ContainsNotesInRange( const ScRangeList& rRange ) const;
1262  SC_DLLPUBLIC void SetDrawPageSize(SCTAB nTab);
1264  bool IsMerged( const ScAddress& rPos ) const;
1266  void ExtendMergeSel( SCCOL nStartCol, SCROW nStartRow,
1267  SCCOL& rEndCol, SCROW& rEndRow, const ScMarkData& rMark,
1268  bool bRefresh = false );
1269  SC_DLLPUBLIC bool ExtendMerge( SCCOL nStartCol, SCROW nStartRow,
1270  SCCOL& rEndCol, SCROW& rEndRow, SCTAB nTab,
1271  bool bRefresh = false );
1272  bool ExtendMerge( ScRange& rRange, bool bRefresh = false );
1273  SC_DLLPUBLIC void ExtendTotalMerge( ScRange& rRange ) const;
1274  SC_DLLPUBLIC void ExtendOverlapped( SCCOL& rStartCol, SCROW& rStartRow,
1275  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab ) const;
1276  SC_DLLPUBLIC void ExtendOverlapped( ScRange& rRange ) const;
1278  bool RefreshAutoFilter( SCCOL nStartCol, SCROW nStartRow,
1279  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab );
1281  SC_DLLPUBLIC void DoMergeContents( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1282  SCCOL nEndCol, SCROW nEndRow );
1283  SC_DLLPUBLIC void DoEmptyBlock( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1284  SCCOL nEndCol, SCROW nEndRow );
1285  // without checking:
1286  SC_DLLPUBLIC void DoMerge( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1287  SCCOL nEndCol, SCROW nEndRow, bool bDeleteCaptions = true );
1288  void RemoveMerge( SCCOL nCol, SCROW nRow, SCTAB nTab );
1290  bool IsBlockEmpty( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1291  SCCOL nEndCol, SCROW nEndRow, bool bIgnoreNotes = false ) const;
1292  bool IsPrintEmpty( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1293  SCCOL nEndCol, SCROW nEndRow,
1294  bool bLeftIsEmpty = false,
1295  ScRange* pLastRange = nullptr,
1296  tools::Rectangle* pLastMM = nullptr ) const;
1298  void SkipOverlapped( SCCOL& rCol, SCROW& rRow, SCTAB nTab ) const;
1299  bool IsHorOverlapped( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1300  bool IsVerOverlapped( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1302  SC_DLLPUBLIC bool HasAttrib( SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1303  SCCOL nCol2, SCROW nRow2, SCTAB nTab2, HasAttrFlags nMask ) const;
1304  SC_DLLPUBLIC bool HasAttrib( const ScRange& rRange, HasAttrFlags nMask ) const;
1306  SC_DLLPUBLIC void GetBorderLines( SCCOL nCol, SCROW nRow, SCTAB nTab,
1307  const ::editeng::SvxBorderLine** ppLeft,
1308  const ::editeng::SvxBorderLine** ppTop,
1309  const ::editeng::SvxBorderLine** ppRight,
1310  const ::editeng::SvxBorderLine** ppBottom ) const;
1312  void ResetChanged( const ScRange& rRange );
1314  void CheckVectorizationState();
1315  void SetAllFormulasDirty( const sc::SetFormulaDirtyContext& rCxt );
1316  void SetDirty( const ScRange&, bool bIncludeEmptyCells );
1317  void SetTableOpDirty( const ScRange& ); // for Interpreter TableOp
1318  void InterpretDirtyCells( const ScRangeList& rRanges );
1319  SC_DLLPUBLIC void CalcAll();
1320  SC_DLLPUBLIC void CalcAfterLoad( bool bStartListening = true );
1321  void CompileAll();
1322  void CompileXML();
1334  bool CompileErrorCells(FormulaError nErrCode);
1336  ScAutoNameCache* GetAutoNameCache() { return pAutoNameCache.get(); }
1337  void SetPreviewFont( std::unique_ptr<SfxItemSet> pFontSet );
1338  SfxItemSet* GetPreviewFont() { return pPreviewFont.get(); }
1339  SfxItemSet* GetPreviewFont( SCCOL nCol, SCROW nRow, SCTAB nTab );
1341  void SetPreviewSelection( const ScMarkData& rSel );
1343  ScStyleSheet* GetPreviewCellStyle( SCCOL nCol, SCROW nRow, SCTAB nTab );
1344  void SetPreviewCellStyle( ScStyleSheet* pStyle ) { pPreviewCellStyle = pStyle; }
1345  SC_DLLPUBLIC void SetAutoNameCache( std::unique_ptr<ScAutoNameCache> pCache );
1349  ScLookupCache & GetLookupCache( const ScRange & rRange, ScInterpreterContext* pContext );
1352  void RemoveLookupCache( ScLookupCache & rCache );
1354  void ClearLookupCaches();
1356  // calculate automatically
1357  SC_DLLPUBLIC void SetAutoCalc( bool bNewAutoCalc );
1358  SC_DLLPUBLIC bool GetAutoCalc() const { return bAutoCalc; }
1359  // calculate automatically in/from/for ScDocShell disabled
1360  void SetAutoCalcShellDisabled( bool bNew ) { bAutoCalcShellDisabled = bNew; }
1362  // ForcedFormulas are to be calculated
1363  void SetForcedFormulaPending( bool bNew ) { bForcedFormulaPending = bNew; }
1365  // if CalcFormulaTree() is currently running
1369  void DelayFormulaGrouping( bool delay );
1370  bool IsDelayedFormulaGrouping() const { return bool(pDelayedFormulaGrouping); }
1372  void AddDelayedFormulaGroupingCell( const ScFormulaCell* cell );
1376  void EnableDelayStartListeningFormulaCells( ScColumn* column, bool delay );
1377  bool IsEnabledDelayStartListeningFormulaCells( ScColumn* column ) const;
1380  bool CanDelayStartListeningFormulaCells( ScColumn* column, SCROW row1, SCROW row2 );
1382  FormulaError GetErrCode( const ScAddress& ) const;
1396  bool ShrinkToDataArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow, SCCOL& rEndCol, SCROW& rEndRow ) const;
1415  bool ShrinkToUsedDataArea( bool& o_bShrunk,
1416  SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1417  SCCOL& rEndCol, SCROW& rEndRow, bool bColumnsOnly,
1418  bool bStickyTopRow = false, bool bStickyLeftCol = false,
1419  bool bConsiderCellNotes = false,
1420  bool bConsiderCellDrawObjects = false,
1421  bool bConsiderCellFormats = false ) const;
1433  SCROW GetLastDataRow( SCTAB nTab, SCCOL nCol1, SCCOL nCol2, SCROW nLastRow ) const;
1448  SC_DLLPUBLIC void GetDataArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1449  SCCOL& rEndCol, SCROW& rEndRow,
1450  bool bIncludeOld, bool bOnlyDown ) const;
1459  bool GetDataAreaSubrange(ScRange& rRange) const;
1461  SC_DLLPUBLIC bool GetCellArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow ) const;
1462  SC_DLLPUBLIC bool GetTableArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow,
1463  bool bCalcHiddens = false) const;
1464  SC_DLLPUBLIC bool GetPrintArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow,
1465  bool bNotes = true) const;
1466  SC_DLLPUBLIC bool GetPrintAreaHor( SCTAB nTab, SCROW nStartRow, SCROW nEndRow,
1467  SCCOL& rEndCol ) const;
1468  SC_DLLPUBLIC bool GetPrintAreaVer( SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol,
1469  SCROW& rEndRow, bool bNotes ) const;
1470  void InvalidateTableArea();
1473  SC_DLLPUBLIC void GetTiledRenderingArea(SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow) const;
1475  SC_DLLPUBLIC bool GetDataStart( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow ) const;
1482  void ExtendPrintArea( OutputDevice* pDev, SCTAB nTab,
1483  SCCOL nStartCol, SCROW nStartRow,
1484  SCCOL& rEndCol, SCROW nEndRow ) const;
1485  SC_DLLPUBLIC SCSIZE GetEmptyLinesInBlock( SCCOL nStartCol, SCROW nStartRow, SCTAB nStartTab,
1486  SCCOL nEndCol, SCROW nEndRow, SCTAB nEndTab,
1487  ScDirection eDir );
1489  void FindAreaPos( SCCOL& rCol, SCROW& rRow, SCTAB nTab, ScMoveDirection eDirection ) const;
1490  SC_DLLPUBLIC void GetNextPos( SCCOL& rCol, SCROW& rRow, SCTAB nTab, SCCOL nMovX, SCROW nMovY,
1491  bool bMarked, bool bUnprotected, const ScMarkData& rMark,
1492  SCCOL nTabStartCol = SC_TABSTART_NONE ) const;
1494  bool GetNextMarkedCell( SCCOL& rCol, SCROW& rRow, SCTAB nTab,
1495  const ScMarkData& rMark );
1497  void LimitChartArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1498  SCCOL& rEndCol, SCROW& rEndRow );
1499  void LimitChartIfAll( ScRangeListRef& rRangeList );
1501  bool InsertRow( SCCOL nStartCol, SCTAB nStartTab,
1502  SCCOL nEndCol, SCTAB nEndTab,
1503  SCROW nStartRow, SCSIZE nSize, ScDocument* pRefUndoDoc = nullptr,
1504  const ScMarkData* pTabMark = nullptr );
1505  SC_DLLPUBLIC bool InsertRow( const ScRange& rRange );
1506  void DeleteRow( SCCOL nStartCol, SCTAB nStartTab,
1507  SCCOL nEndCol, SCTAB nEndTab,
1508  SCROW nStartRow, SCSIZE nSize,
1509  ScDocument* pRefUndoDoc = nullptr, bool* pUndoOutline = nullptr,
1510  const ScMarkData* pTabMark = nullptr );
1511  SC_DLLPUBLIC void DeleteRow( const ScRange& rRange );
1512  bool InsertCol( SCROW nStartRow, SCTAB nStartTab,
1513  SCROW nEndRow, SCTAB nEndTab,
1514  SCCOL nStartCol, SCSIZE nSize, ScDocument* pRefUndoDoc = nullptr,
1515  const ScMarkData* pTabMark = nullptr );
1516  SC_DLLPUBLIC bool InsertCol( const ScRange& rRange );
1517  void DeleteCol( SCROW nStartRow, SCTAB nStartTab,
1518  SCROW nEndRow, SCTAB nEndTab,
1519  SCCOL nStartCol, SCSIZE nSize,
1520  ScDocument* pRefUndoDoc = nullptr, bool* pUndoOutline = nullptr,
1521  const ScMarkData* pTabMark = nullptr );
1522  void DeleteCol( const ScRange& rRange );
1524  bool CanInsertRow( const ScRange& rRange ) const;
1525  bool CanInsertCol( const ScRange& rRange ) const;
1527  void FitBlock( const ScRange& rOld, const ScRange& rNew, bool bClear = true );
1528  bool CanFitBlock( const ScRange& rOld, const ScRange& rNew );
1530  bool IsClipOrUndo() const { return bIsClip || bIsUndo; }
1531  bool IsUndo() const { return bIsUndo; }
1532  bool IsClipboard() const { return bIsClip; }
1533  bool IsUndoEnabled() const { return mbUndoEnabled; }
1534  SC_DLLPUBLIC void EnableUndo( bool bVal );
1535  bool IsFunctionAccess() const { return bIsFunctionAccess; }
1537  bool IsAdjustHeightLocked() const { return nAdjustHeightLock != 0; }
1541  void EnableExecuteLink( bool bVal ) { mbExecuteLinkEnabled = bVal; }
1543  void EnableChangeReadOnly( bool bVal ) { mbChangeReadOnlyEnabled = bVal; }
1545  SC_DLLPUBLIC void EnableUserInteraction( bool bVal );
1547  void SetNamedRangesLockCount( sal_Int16 nCount ) { mnNamedRangesLockCount = nCount; }
1548  SC_DLLPUBLIC void ResetClip( ScDocument* pSourceDoc, const ScMarkData* pMarks );
1549  SC_DLLPUBLIC void ResetClip( ScDocument* pSourceDoc, SCTAB nTab );
1550  void SetCutMode( bool bCut );
1551  bool IsCutMode();
1552  void SetClipArea( const ScRange& rArea, bool bCut = false );
1554  SC_DLLPUBLIC bool IsDocVisible() const { return bIsVisible; }
1555  SC_DLLPUBLIC void SetDocVisible( bool bSet );
1557  bool HasOLEObjectsInArea( const ScRange& rRange, const ScMarkData* pTabMark = nullptr );
1559  void DeleteObjectsInArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1560  const ScMarkData& rMark, bool bAnchored = false );
1561  void DeleteObjectsInSelection( const ScMarkData& rMark );
1563  void DeleteArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark,
1564  InsertDeleteFlags nDelFlag, bool bBroadcast = true,
1565  sc::ColumnSpanSet* pBroadcastSpans = nullptr );
1567  SC_DLLPUBLIC void DeleteAreaTab(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1568  SCTAB nTab, InsertDeleteFlags nDelFlag);
1569  void DeleteAreaTab(const ScRange& rRange, InsertDeleteFlags nDelFlag);
1571  SC_DLLPUBLIC void CopyToClip( const ScClipParam& rClipParam, ScDocument* pClipDoc,
1572  const ScMarkData* pMarks, bool bKeepScenarioFlags,
1573  bool bIncludeObjects );
1584  SC_DLLPUBLIC void CopyStaticToDocument(const ScRange& rSrcRange, SCTAB nDestTab, ScDocument& rDestDoc);
1593  void CopyCellToDocument( const ScAddress& rSrcPos, const ScAddress& rDestPos, ScDocument& rDestDoc );
1595  void CopyTabToClip( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1596  SCTAB nTab, ScDocument* pClipDoc);
1601  sc::ColumnSpanSet& rBroadcastSpans );
1603  bool CopyOneCellFromClip(sc::CopyFromClipContext& rCxt, SCCOL nCol1, SCROW nRow1,
1604  SCCOL nCol2, SCROW nRow2 );
1605  void CopyBlockFromClip( sc::CopyFromClipContext& rCxt, SCCOL nCol1, SCROW nRow1,
1606  SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark,
1607  SCCOL nDx, SCROW nDy );
1612  SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark, SCCOL nDx,
1613  SCROW& rClipStartRow, SCROW nClipEndRow);
1615  void StartListeningFromClip( SCCOL nCol1, SCROW nRow1,
1616  SCCOL nCol2, SCROW nRow2,
1617  const ScMarkData& rMark, InsertDeleteFlags nInsFlag );
1619  void SetDirtyFromClip( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1620  const ScMarkData& rMark, InsertDeleteFlags nInsFlag,
1621  sc::ColumnSpanSet& rBroadcastSpans );
1625  SC_DLLPUBLIC void CopyFromClip( const ScRange& rDestRange, const ScMarkData& rMark,
1626  InsertDeleteFlags nInsFlag,
1627  ScDocument* pRefUndoDoc,
1628  ScDocument* pClipDoc,
1629  bool bResetCut = true,
1630  bool bAsLink = false,
1631  bool bIncludeFiltered = true,
1632  bool bSkipAttrForEmpty = false,
1633  const ScRangeList * pDestRanges = nullptr );
1635  void CopyMultiRangeFromClip(const ScAddress& rDestPos, const ScMarkData& rMark,
1636  InsertDeleteFlags nInsFlag, ScDocument* pClipDoc,
1637  bool bResetCut = true, bool bAsLink = false,
1638  bool bIncludeFiltered = true,
1639  bool bSkipAttrForEmpty = false);
1641  void GetClipArea(SCCOL& nClipX, SCROW& nClipY, bool bIncludeFiltered);
1642  void GetClipStart(SCCOL& nClipX, SCROW& nClipY);
1644  bool HasClipFilteredRows();
1646  bool IsClipboardSource() const;
1648  SC_DLLPUBLIC void TransposeClip(ScDocument* pTransClip, InsertDeleteFlags nFlags, bool bAsLink,
1649  bool bIncludeFiltered);
1652  void SetClipParam(const ScClipParam& rParam);
1659  void ClosingClipboardSource();
1661  void MixDocument( const ScRange& rRange, ScPasteFunc nFunction, bool bSkipEmpty,
1662  ScDocument& rSrcDoc );
1664  void FillTab( const ScRange& rSrcArea, const ScMarkData& rMark,
1665  InsertDeleteFlags nFlags, ScPasteFunc nFunction,
1666  bool bSkipEmpty, bool bAsLink );
1667  void FillTabMarked( SCTAB nSrcTab, const ScMarkData& rMark,
1668  InsertDeleteFlags nFlags, ScPasteFunc nFunction,
1669  bool bSkipEmpty, bool bAsLink );
1671  void TransliterateText( const ScMarkData& rMultiMark, TransliterationFlags nType );
1673  SC_DLLPUBLIC void InitUndo( const ScDocument& rSrcDoc, SCTAB nTab1, SCTAB nTab2,
1674  bool bColInfo = false, bool bRowInfo = false );
1675  void AddUndoTab( SCTAB nTab1, SCTAB nTab2,
1676  bool bColInfo = false, bool bRowInfo = false );
1677  SC_DLLPUBLIC void InitUndoSelected( const ScDocument& rSrcDoc, const ScMarkData& rTabSelection,
1678  bool bColInfo = false, bool bRowInfo = false );
1680  // don't use anymore:
1681  void CopyToDocument(SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1682  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1683  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc,
1684  const ScMarkData* pMarks = nullptr, bool bColRowFlags = true);
1685  void UndoToDocument(SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1686  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1687  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc);
1689  void CopyToDocument(const ScRange& rRange,
1690  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc,
1691  const ScMarkData* pMarks = nullptr, bool bColRowFlags = true);
1692  void UndoToDocument(const ScRange& rRange,
1693  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc);
1695  void CopyScenario( SCTAB nSrcTab, SCTAB nDestTab, bool bNewScenario = false );
1696  bool TestCopyScenario( SCTAB nSrcTab, SCTAB nDestTab ) const;
1697  void MarkScenario(SCTAB nSrcTab, SCTAB nDestTab,
1698  ScMarkData& rDestMark, bool bResetMark = true,
1699  ScScenarioFlags nNeededBits = ScScenarioFlags::NONE) const;
1700  bool HasScenarioRange( SCTAB nTab, const ScRange& rRange ) const;
1701  SC_DLLPUBLIC const ScRangeList* GetScenarioRanges( SCTAB nTab ) const;
1703  SC_DLLPUBLIC void CopyUpdated( ScDocument* pPosDoc, ScDocument* pDestDoc );
1706  pUndoDoc = nullptr, bool bIncludeDraw = true,
1707  bool bUpdateNoteCaptionPos = true );
1709  SC_DLLPUBLIC void UpdateTranspose( const ScAddress& rDestPos, ScDocument* pClipDoc,
1710  const ScMarkData& rMark, ScDocument* pUndoDoc );
1712  void UpdateGrow( const ScRange& rArea, SCCOL nGrowX, SCROW nGrowY );
1714  SC_DLLPUBLIC void Fill( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1715  ScProgress* pProgress, const ScMarkData& rMark,
1716  sal_uLong nFillCount, FillDir eFillDir = FILL_TO_BOTTOM,
1717  FillCmd eFillCmd = FILL_LINEAR, FillDateCmd eFillDateCmd = FILL_DAY,
1718  double nStepValue = 1.0, double nMaxValue = 1E307 );
1719  OUString GetAutoFillPreview( const ScRange& rSource, SCCOL nEndX, SCROW nEndY );
1722  const ScAddress& rCursor, const ScMarkData& rMark,
1723  double& rResult );
1725  SC_DLLPUBLIC const SfxPoolItem* GetAttr( SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich ) const;
1726  template<class T> const T* GetAttr( SCCOL nCol, SCROW nRow, SCTAB nTab, TypedWhichId<T> nWhich ) const
1727  {
1728  return static_cast<const T*>(GetAttr(nCol, nRow, nTab, sal_uInt16(nWhich)));
1729  }
1730  SC_DLLPUBLIC const SfxPoolItem* GetAttr( const ScAddress& rPos, sal_uInt16 nWhich ) const;
1731  template<class T> const T* GetAttr( const ScAddress& rPos, TypedWhichId<T> nWhich ) const
1732  {
1733  return static_cast<const T*>(GetAttr(rPos, sal_uInt16(nWhich)));
1734  }
1735  SC_DLLPUBLIC const ScPatternAttr* GetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1736  SC_DLLPUBLIC const ScPatternAttr* GetPattern( const ScAddress& rPos ) const;
1737  SC_DLLPUBLIC const ScPatternAttr* GetMostUsedPattern( SCCOL nCol, SCROW nStartRow, SCROW nEndRow, SCTAB nTab ) const;
1738  const ScPatternAttr* GetSelectionPattern( const ScMarkData& rMark );
1739  std::unique_ptr<ScPatternAttr> CreateSelectionPattern( const ScMarkData& rMark, bool bDeep = true );
1740  SC_DLLPUBLIC void AddCondFormatData( const ScRangeList& rRange, SCTAB nTab, sal_uInt32 nIndex );
1741  void RemoveCondFormatData( const ScRangeList& rRange, SCTAB nTab, sal_uInt32 nIndex );
1743  SC_DLLPUBLIC ScConditionalFormat* GetCondFormat( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1744  // pCell is an optimization, must point to rPos
1745  SC_DLLPUBLIC const SfxItemSet* GetCondResult( SCCOL nCol, SCROW nRow, SCTAB nTab,
1746  ScRefCellValue* pCell = nullptr ) const;
1747  const SfxItemSet* GetCondResult( ScRefCellValue& rCell, const ScAddress& rPos,
1748  const ScConditionalFormatList& rList,
1749  const ScCondFormatIndexes& rIndex ) const;
1750  const SfxPoolItem* GetEffItem( SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich ) const;
1751  template<class T> const T* GetEffItem( SCCOL nCol, SCROW nRow, SCTAB nTab, TypedWhichId<T> nWhich ) const
1752  {
1753  return static_cast<const T*>(GetEffItem(nCol, nRow, nTab, sal_uInt16(nWhich)));
1754  }
1756  SC_DLLPUBLIC const css::uno::Reference< css::i18n::XBreakIterator >& GetBreakIterator();
1757  bool HasStringWeakCharacters( const OUString& rString );
1758  SC_DLLPUBLIC SvtScriptType GetStringScriptType( const OUString& rString );
1759  // pCell is an optimization, must point to rPos
1760  SC_DLLPUBLIC SvtScriptType GetCellScriptType( const ScAddress& rPos, sal_uInt32 nNumberFormat,
1761  const ScRefCellValue* pCell = nullptr );
1762  // pCell is an optimization, must point to nCol,nRow,nTab
1764  const ScRefCellValue* pCell = nullptr );
1765  SvtScriptType GetRangeScriptType( sc::ColumnBlockPosition& rBlockPos, const ScAddress& rPos, SCROW nLength );
1766  SvtScriptType GetRangeScriptType( const ScRangeList& rRanges );
1768  bool HasDetectiveOperations() const;
1769  void AddDetectiveOperation( const ScDetOpData& rData );
1770  void ClearDetectiveOperations();
1771  ScDetOpList* GetDetOpList() const { return pDetOpList.get(); }
1772  void SetDetOpList(std::unique_ptr<ScDetOpList> pNew);
1774  bool HasDetectiveObjects(SCTAB nTab) const;
1776  void GetSelectionFrame( const ScMarkData& rMark,
1777  SvxBoxItem& rLineOuter,
1778  SvxBoxInfoItem& rLineInner );
1779  void ApplySelectionFrame(const ScMarkData& rMark,
1780  const SvxBoxItem& rLineOuter,
1781  const SvxBoxInfoItem* pLineInner);
1782  void ApplyFrameAreaTab(const ScRange& rRange,
1783  const SvxBoxItem& rLineOuter,
1784  const SvxBoxInfoItem& rLineInner);
1786  void ClearSelectionItems( const sal_uInt16* pWhich, const ScMarkData& rMark );
1787  void ChangeSelectionIndent( bool bIncrement, const ScMarkData& rMark );
1789  SC_DLLPUBLIC sal_uLong AddCondFormat( std::unique_ptr<ScConditionalFormat> pNew, SCTAB nTab );
1790  void DeleteConditionalFormat( sal_uLong nIndex, SCTAB nTab );
1792  void SetCondFormList( ScConditionalFormatList* pList, SCTAB nTab );
1798  const ScValidationDataList* GetValidationList() const { return pValidationList.get();}
1799  ScValidationDataList* GetValidationList() { return pValidationList.get();}
1801  SC_DLLPUBLIC void ApplyAttr( SCCOL nCol, SCROW nRow, SCTAB nTab,
1802  const SfxPoolItem& rAttr );
1803  SC_DLLPUBLIC void ApplyPattern( SCCOL nCol, SCROW nRow, SCTAB nTab,
1804  const ScPatternAttr& rAttr );
1805  SC_DLLPUBLIC void ApplyPatternArea( SCCOL nStartCol, SCROW nStartRow,
1806  SCCOL nEndCol, SCROW nEndRow,
1807  const ScMarkData& rMark, const ScPatternAttr& rAttr,
1808  ScEditDataArray* pDataArray = nullptr,
1809  bool* const pIsChanged = nullptr );
1810  SC_DLLPUBLIC void ApplyPatternAreaTab( SCCOL nStartCol, SCROW nStartRow,
1811  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab,
1812  const ScPatternAttr& rAttr );
1815  const ScMarkData& rMark,
1816  const ScPatternAttr& rPattern,
1817  SvNumFormatType nNewType );
1819  void ApplyStyle( SCCOL nCol, SCROW nRow, SCTAB nTab,
1820  const ScStyleSheet& rStyle);
1821  void ApplyStyleArea( SCCOL nStartCol, SCROW nStartRow,
1822  SCCOL nEndCol, SCROW nEndRow,
1823  const ScMarkData& rMark, const ScStyleSheet& rStyle);
1824  SC_DLLPUBLIC void ApplyStyleAreaTab( SCCOL nStartCol, SCROW nStartRow,
1825  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab,
1826  const ScStyleSheet& rStyle);
1828  SC_DLLPUBLIC void ApplySelectionStyle( const ScStyleSheet& rStyle, const ScMarkData& rMark );
1829  void ApplySelectionLineStyle( const ScMarkData& rMark,
1830  const ::editeng::SvxBorderLine* pLine, bool bColorOnly );
1832  const ScStyleSheet* GetStyle( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1833  const ScStyleSheet* GetSelectionStyle( const ScMarkData& rMark ) const;
1835  void StyleSheetChanged( const SfxStyleSheetBase* pStyleSheet, bool bRemoved,
1836  OutputDevice* pDev,
1837  double nPPTX, double nPPTY,
1838  const Fraction& rZoomX, const Fraction& rZoomY );
1840  bool IsStyleSheetUsed( const ScStyleSheet& rStyle ) const;
1842  SC_DLLPUBLIC bool ApplyFlagsTab( SCCOL nStartCol, SCROW nStartRow,
1843  SCCOL nEndCol, SCROW nEndRow,
1844  SCTAB nTab, ScMF nFlags );
1845  SC_DLLPUBLIC bool RemoveFlagsTab( SCCOL nStartCol, SCROW nStartRow,
1846  SCCOL nEndCol, SCROW nEndRow,
1847  SCTAB nTab, ScMF nFlags );
1849  SC_DLLPUBLIC void SetPattern( const ScAddress&, const ScPatternAttr& rAttr );
1850  SC_DLLPUBLIC const ScPatternAttr* SetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab, std::unique_ptr<ScPatternAttr> );
1851  SC_DLLPUBLIC void SetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab, const ScPatternAttr& rAttr );
1853  void AutoFormat( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
1854  sal_uInt16 nFormatNo, const ScMarkData& rMark );
1855  void GetAutoFormatData( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
1856  ScAutoFormatData& rData );
1857  bool SearchAndReplace( const SvxSearchItem& rSearchItem,
1858  SCCOL& rCol, SCROW& rRow, SCTAB& rTab,
1859  const ScMarkData& rMark, ScRangeList& rMatchedRanges,
1860  OUString& rUndoStr, ScDocument* pUndoDoc = nullptr );
1862  // determine Col/Row of subsequent calls
1863  // (e.g. not found from the beginning, or subsequent tables)
1864  // meaning of explanation in "()" was already unclear in German
1865  void GetSearchAndReplaceStart( const SvxSearchItem& rSearchItem,
1866  SCCOL& rCol, SCROW& rRow );
1868  bool Solver( SCCOL nFCol, SCROW nFRow, SCTAB nFTab,
1869  SCCOL nVCol, SCROW nVRow, SCTAB nVTab,
1870  const OUString& sValStr, double& nX);
1872  SC_DLLPUBLIC void ApplySelectionPattern( const ScPatternAttr& rAttr, const ScMarkData& rMark,
1873  ScEditDataArray* pDataArray = nullptr, bool* pIsChanged = nullptr );
1874  void DeleteSelection( InsertDeleteFlags nDelFlag, const ScMarkData& rMark, bool bBroadcast = true );
1875  void DeleteSelectionTab( SCTAB nTab, InsertDeleteFlags nDelFlag, const ScMarkData& rMark );
1877  SC_DLLPUBLIC void SetColWidth( SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth );
1878  SC_DLLPUBLIC void SetColWidthOnly( SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth );
1879  SC_DLLPUBLIC void SetRowHeight( SCROW nRow, SCTAB nTab, sal_uInt16 nNewHeight );
1880  SC_DLLPUBLIC void SetRowHeightRange( SCROW nStartRow, SCROW nEndRow, SCTAB nTab,
1881  sal_uInt16 nNewHeight );
1883  SC_DLLPUBLIC void SetRowHeightOnly( SCROW nStartRow, SCROW nEndRow, SCTAB nTab,
1884  sal_uInt16 nNewHeight );
1885  SC_DLLPUBLIC void SetManualHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bManual );
1887  SC_DLLPUBLIC sal_uInt16 GetColWidth( SCCOL nCol, SCTAB nTab, bool bHiddenAsZero = true ) const;
1888  SC_DLLPUBLIC sal_uLong GetColWidth( SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab ) const;
1889  SC_DLLPUBLIC sal_uInt16 GetRowHeight( SCROW nRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1890  SC_DLLPUBLIC sal_uInt16 GetRowHeight( SCROW nRow, SCTAB nTab, SCROW* pStartRow, SCROW* pEndRow ) const;
1891  SC_DLLPUBLIC sal_uLong GetRowHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1898  SCROW GetRowForHeight( SCTAB nTab, sal_uLong nHeight ) const;
1899  sal_uLong GetScaledRowHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, double fScale, const sal_uLong* pnMaxHeight = nullptr ) const;
1900  SC_DLLPUBLIC sal_uLong GetColOffset( SCCOL nCol, SCTAB nTab, bool bHiddenAsZero = true ) const;
1901  SC_DLLPUBLIC sal_uLong GetRowOffset( SCROW nRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1903  SC_DLLPUBLIC sal_uInt16 GetOriginalWidth( SCCOL nCol, SCTAB nTab ) const;
1904  SC_DLLPUBLIC sal_uInt16 GetOriginalHeight( SCROW nRow, SCTAB nTab ) const;
1906  sal_uInt16 GetCommonWidth( SCCOL nEndCol, SCTAB nTab ) const;
1908  SCROW GetHiddenRowCount( SCROW nRow, SCTAB nTab ) const;
1910  sal_uInt16 GetOptimalColWidth( SCCOL nCol, SCTAB nTab, OutputDevice* pDev,
1911  double nPPTX, double nPPTY,
1912  const Fraction& rZoomX, const Fraction& rZoomY,
1913  bool bFormula,
1914  const ScMarkData* pMarkData = nullptr,
1915  const ScColWidthParam* pParam = nullptr );
1918  SCROW nEndRow, SCTAB nTab, bool bApi );
1920  void UpdateAllRowHeights( sc::RowHeightContext& rCxt, const ScMarkData* pTabMark );
1922  tools::Long GetNeededSize( SCCOL nCol, SCROW nRow, SCTAB nTab,
1923  OutputDevice* pDev,
1924  double nPPTX, double nPPTY,
1925  const Fraction& rZoomX, const Fraction& rZoomY,
1926  bool bWidth, bool bTotalSize = false,
1927  bool bInPrintTwips = false );
1929  SC_DLLPUBLIC void ShowCol(SCCOL nCol, SCTAB nTab, bool bShow);
1930  SC_DLLPUBLIC void ShowRow(SCROW nRow, SCTAB nTab, bool bShow);
1931  SC_DLLPUBLIC void ShowRows(SCROW nRow1, SCROW nRow2, SCTAB nTab, bool bShow);
1932  SC_DLLPUBLIC void SetRowFlags( SCROW nRow, SCTAB nTab, CRFlags nNewFlags );
1933  SC_DLLPUBLIC void SetRowFlags( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, CRFlags nNewFlags );
1935  SC_DLLPUBLIC CRFlags GetColFlags( SCCOL nCol, SCTAB nTab ) const;
1936  SC_DLLPUBLIC CRFlags GetRowFlags( SCROW nRow, SCTAB nTab ) const;
1938  SC_DLLPUBLIC void GetAllRowBreaks(std::set<SCROW>& rBreaks, SCTAB nTab, bool bPage, bool bManual) const;
1939  SC_DLLPUBLIC void GetAllColBreaks(std::set<SCCOL>& rBreaks, SCTAB nTab, bool bPage, bool bManual) const;
1940  SC_DLLPUBLIC ScBreakType HasRowBreak(SCROW nRow, SCTAB nTab) const;
1941  SC_DLLPUBLIC ScBreakType HasColBreak(SCCOL nCol, SCTAB nTab) const;
1942  SC_DLLPUBLIC void SetRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual);
1943  SC_DLLPUBLIC void SetColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual);
1944  void RemoveRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual);
1945  void RemoveColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual);
1946  css::uno::Sequence<
1947  css::sheet::TablePageBreakData> GetRowBreakData(SCTAB nTab) const;
1949  SC_DLLPUBLIC bool RowHidden(SCROW nRow, SCTAB nTab, SCROW* pFirstRow = nullptr, SCROW* pLastRow = nullptr) const;
1950  SC_DLLPUBLIC bool HasHiddenRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1951  SC_DLLPUBLIC bool ColHidden(SCCOL nCol, SCTAB nTab, SCCOL* pFirstCol = nullptr, SCCOL* pLastCol = nullptr) const;
1952  SC_DLLPUBLIC void SetRowHidden(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bHidden);
1953  SC_DLLPUBLIC void SetColHidden(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bHidden);
1954  SC_DLLPUBLIC SCROW FirstVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1955  SC_DLLPUBLIC SCROW LastVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1956  SCROW CountVisibleRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1958  SC_DLLPUBLIC bool RowFiltered(SCROW nRow, SCTAB nTab, SCROW* pFirstRow = nullptr, SCROW* pLastRow = nullptr) const;
1959  bool HasFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1960  bool ColFiltered(SCCOL nCol, SCTAB nTab) const;
1961  SC_DLLPUBLIC void SetRowFiltered(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bFiltered);
1962  SCROW FirstNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1963  SCROW LastNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1964  SCROW CountNonFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1966  SC_DLLPUBLIC bool IsManualRowHeight(SCROW nRow, SCTAB nTab) const;
1968  bool HasUniformRowHeight( SCTAB nTab, SCROW nRow1, SCROW nRow2 ) const;
1975  void SyncColRowFlags();
1978  SC_DLLPUBLIC SCROW GetLastFlaggedRow( SCTAB nTab ) const;
1981  SCCOL GetLastChangedCol( SCTAB nTab ) const;
1983  SCROW GetLastChangedRow( SCTAB nTab ) const;
1985  SCCOL GetNextDifferentChangedCol( SCTAB nTab, SCCOL nStart) const;
1987  SCROW GetNextDifferentChangedRow( SCTAB nTab, SCROW nStart) const;
1989  // returns whether to export a Default style for this col or not
1990  // nDefault is set to one position in the current row where the Default style is
1991  void GetColDefault( SCTAB nTab, SCCOL nCol, SCROW nLastRow, SCROW& nDefault);
1993  bool UpdateOutlineCol( SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bShow );
1994  bool UpdateOutlineRow( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bShow );
1996  void StripHidden( SCCOL& rX1, SCROW& rY1, SCCOL& rX2, SCROW& rY2, SCTAB nTab );
1997  void ExtendHidden( SCCOL& rX1, SCROW& rY1, SCCOL& rX2, SCROW& rY2, SCTAB nTab );
2002  void GetUnprotectedCells( ScRangeList& rRange, SCTAB nTab ) const;
2004  // PageStyle:
2005  SC_DLLPUBLIC OUString GetPageStyle( SCTAB nTab ) const;
2006  SC_DLLPUBLIC void SetPageStyle( SCTAB nTab, const OUString& rName );
2007  Size GetPageSize( SCTAB nTab ) const;
2008  void SetPageSize( SCTAB nTab, const Size& rSize );
2009  void SetRepeatArea( SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol, SCROW nStartRow, SCROW nEndRow );
2010  void InvalidatePageBreaks(SCTAB nTab);
2011  void UpdatePageBreaks( SCTAB nTab, const ScRange* pUserArea = nullptr );
2012  void RemoveManualBreaks( SCTAB nTab );
2013  bool HasManualBreaks( SCTAB nTab ) const;
2015  bool IsPageStyleInUse( std::u16string_view rStrPageStyle, SCTAB* pInTab );
2016  bool RemovePageStyleInUse( std::u16string_view rStrPageStyle );
2017  bool RenamePageStyleInUse( std::u16string_view rOld, const OUString& rNew );
2018  void ModifyStyleSheet( SfxStyleSheetBase& rPageStyle,
2019  const SfxItemSet& rChanges );
2021  void PageStyleModified( SCTAB nTab, const OUString& rNewName );
2023  SC_DLLPUBLIC bool NeedPageResetAfterTab( SCTAB nTab ) const;
2025  // Was stored in PageStyle previously. Now it exists for every table:
2026  SC_DLLPUBLIC bool HasPrintRange();
2027  SC_DLLPUBLIC sal_uInt16 GetPrintRangeCount( SCTAB nTab );
2028  SC_DLLPUBLIC const ScRange* GetPrintRange( SCTAB nTab, sal_uInt16 nPos );
2032  bool IsPrintEntireSheet( SCTAB nTab ) const;
2035  SC_DLLPUBLIC void ClearPrintRanges( SCTAB nTab );
2037  SC_DLLPUBLIC void AddPrintRange( SCTAB nTab, const ScRange& rNew );
2039  SC_DLLPUBLIC void SetPrintEntireSheet( SCTAB nTab );
2040  SC_DLLPUBLIC void SetRepeatColRange( SCTAB nTab, std::unique_ptr<ScRange> pNew );
2041  SC_DLLPUBLIC void SetRepeatRowRange( SCTAB nTab, std::unique_ptr<ScRange> pNew );
2042  std::unique_ptr<ScPrintRangeSaver> CreatePrintRangeSaver() const;
2043  void RestorePrintRanges( const ScPrintRangeSaver& rSaver );
2045  SC_DLLPUBLIC tools::Rectangle GetMMRect( SCCOL nStartCol, SCROW nStartRow,
2046  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
2047  SC_DLLPUBLIC ScRange GetRange( SCTAB nTab, const tools::Rectangle& rMMRect, bool bHiddenAsZero = true ) const;
2049  void UpdStlShtPtrsFrmNms();
2050  void StylesToNames();
2052  SC_DLLPUBLIC void CopyStdStylesFrom( const ScDocument& rSrcDoc );
2054  static sal_uInt16 GetSrcVersion() { return nSrcVer; }
2056  void SetSrcCharSet( rtl_TextEncoding eNew ) { eSrcSet = eNew; }
2057  void UpdateFontCharSet();
2059  void FillInfo( ScTableInfo& rTabInfo, SCCOL nCol1, SCROW nRow1,
2060  SCCOL nCol2, SCROW nRow2, SCTAB nTab, double fColScale,
2061  double fRowScale, bool bPageMode, bool bFormulaMode,
2062  const ScMarkData* pMarkData = nullptr );
2067  void Sort( SCTAB nTab, const ScSortParam& rSortParam,
2068  bool bKeepQuery, bool bUpdateRefs,
2069  ScProgress* pProgress, sc::ReorderParam* pUndo );
2071  void Reorder( const sc::ReorderParam& rParam );
2073  void PrepareQuery( SCTAB nTab, ScQueryParam& rQueryParam );
2074  SCSIZE Query( SCTAB nTab, const ScQueryParam& rQueryParam, bool bKeepSub );
2075  SC_DLLPUBLIC bool CreateQueryParam( const ScRange& rRange, ScQueryParam& rQueryParam );
2076  void GetUpperCellString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rStr);
2084  void GetFilterEntries( SCCOL nCol, SCROW nRow,
2085  SCTAB nTab, ScFilterEntries& rFilterEntries );
2087  SC_DLLPUBLIC void GetFilterEntriesArea( SCCOL nCol, SCROW nStartRow, SCROW nEndRow,
2088  SCTAB nTab, bool bCaseSens,
2089  ScFilterEntries& rFilterEntries );
2091  void GetDataEntries( SCCOL nCol, SCROW nRow, SCTAB nTab,
2092  std::vector<ScTypedStrData>& rStrings, bool bLimit = false );
2093  void GetFormulaEntries( ScTypedCaseStrSet& rStrings );
2095  bool HasAutoFilter( SCCOL nCol, SCROW nRow, SCTAB nTab );
2096  void GetFilterSelCount( SCCOL nCol, SCROW nRow, SCTAB nTab, SCSIZE& nSelected, SCSIZE& nTotal );
2098  SC_DLLPUBLIC bool HasColHeader( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
2099  SCTAB nTab );
2100  SC_DLLPUBLIC bool HasRowHeader( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
2101  SCTAB nTab );
2103  SfxPrinter* GetPrinter( bool bCreateIfNotExist = true );
2104  void SetPrinter( VclPtr<SfxPrinter> const & pNewPrinter );
2106  SC_DLLPUBLIC OutputDevice* GetRefDevice(); // WYSIWYG: Printer, otherwise VirtualDevice...
2108  bool GetNextSpellingCell( SCCOL& nCol, SCROW& nRow, SCTAB nTab,
2109  bool bInSel, const ScMarkData& rMark) const;
2111  void ReplaceStyle( const SvxSearchItem& rSearchItem,
2112  SCCOL nCol, SCROW nRow, SCTAB nTab,
2113  const ScMarkData& rMark);
2115  void InvalidateTextWidth( std::u16string_view rStyleName );
2116  void InvalidateTextWidth( SCTAB nTab );
2117  void InvalidateTextWidth( const ScAddress* pAdrFrom, const ScAddress* pAdrTo, bool bNumFormatChanged );
2119  bool IdleCalcTextWidth();
2121  void RepaintRange( const ScRange& rRange );
2122  void RepaintRange( const ScRangeList& rRange );
2124  bool IsIdleEnabled() const { return mbIdleEnabled; }
2125  void EnableIdle(bool bDo) { mbIdleEnabled = bDo; }
2127  bool IsDetectiveDirty() const { return bDetectiveDirty; }
2128  void SetDetectiveDirty(bool bSet) { bDetectiveDirty = bSet; }
2131  void SetLinkFormulaNeedingCheck(bool bSet) { bLinkFormulaNeedingCheck = bSet; }
2135  void SetRangeOverflowType(ErrCode nType) { nRangeOverflowType = nType; }
2136  bool HasRangeOverflow() const { return nRangeOverflowType != ERRCODE_NONE; }
2139  // for broadcasting/listening
2140  void SetInsertingFromOtherDoc( bool bVal ) { bInsertingFromOtherDoc = bVal; }
2142  void SetLoadingMedium( bool bVal );
2143  SC_DLLPUBLIC void SetImportingXML( bool bVal );
2144  bool IsImportingXML() const { return bImportingXML; }
2145  bool IsCalcingAfterLoad() const { return bCalcingAfterLoad; }
2146  void SetNoListening( bool bVal ) { bNoListening = bVal; }
2147  bool GetNoListening() const { return bNoListening; }
2148  ScBroadcastAreaSlotMachine* GetBASM() const { return pBASM.get(); }
2150  SC_DLLPUBLIC ScChartListenerCollection* GetChartListenerCollection() const { return pChartListenerCollection.get(); }
2151  void SetChartListenerCollection( std::unique_ptr<ScChartListenerCollection>,
2152  bool bSetChartRangeLists );
2153  void UpdateChart( const OUString& rName );
2154  void RestoreChartListener( const OUString& rName );
2157  void SetChartListenerCollectionNeedsUpdate( bool bFlg ) { bChartListenerCollectionNeedsUpdate = bFlg; }
2158  void AddOLEObjectToCollection(const OUString& rName);
2160  ScChangeViewSettings* GetChangeViewSettings() const { return pChangeViewSettings.get(); }
2163  const std::shared_ptr<SvxForbiddenCharactersTable>& GetForbiddenCharacters() const;
2164  void SetForbiddenCharacters(const std::shared_ptr<SvxForbiddenCharactersTable>& rNew);
2167  bool IsValidAsianCompression() const;
2170  bool GetAsianKerning() const;
2171  bool IsValidAsianKerning() const;
2172  void SetAsianKerning(bool bNew);
2175  EEHorizontalTextDirection GetEditTextDirection(SCTAB nTab) const; // EEHorizontalTextDirection values
2178  void SetLinkMode( ScLkUpdMode nSet ) { eLinkMode = nSet;}
2182  void FillMatrix( ScMatrix& rMat, SCTAB nTab, SCCOL nCol1,
2183  SCROW nRow1, SCCOL nCol2, SCROW nRow2,
2184  svl::SharedStringPool* pPool = nullptr) const;
2194  void SC_DLLPUBLIC SetFormulaResults( const ScAddress& rTopPos, const double* pResults, size_t nLen );
2196  void CalculateInColumnInThread( ScInterpreterContext& rContext, const ScRange& rCalcRange, unsigned nThisThread, unsigned nThreadsTotal);
2197  void HandleStuffAfterParallelCalculation( SCCOL nColStart, SCCOL nColEnd, SCROW nRow, size_t nLen, SCTAB nTab, ScInterpreter* pInterpreter );
2204  void TransferCellValuesTo( const ScAddress& rTopPos, size_t nLen, sc::CellValues& rDest );
2205  void CopyCellValuesFrom( const ScAddress& rTopPos, const sc::CellValues& rSrc );
2207  std::set<Color> GetDocColors();
2210 private:
2211  ScDocument(const ScDocument& r) = delete;
2213  void FindMaxRotCol( SCTAB nTab, RowInfo* pRowInfo, SCSIZE nArrCount,
2214  SCCOL nX1, SCCOL nX2 ) const;
2216  sal_uInt16 RowDifferences( SCROW nThisRow, SCTAB nThisTab,
2217  ScDocument& rOtherDoc,
2218  SCROW nOtherRow, SCTAB nOtherTab,
2219  SCCOL nMaxCol, const SCCOLROW* pOtherCols );
2220  sal_uInt16 ColDifferences( SCCOL nThisCol, SCTAB nThisTab,
2221  ScDocument& rOtherDoc,
2222  SCCOL nOtherCol, SCTAB nOtherTab,
2223  SCROW nMaxRow, const SCCOLROW* pOtherRows );
2224  void FindOrder( SCCOLROW* pOtherRows, SCCOLROW nThisEndRow, SCCOLROW nOtherEndRow,
2225  bool bColumns,
2226  ScDocument& rOtherDoc, SCTAB nThisTab, SCTAB nOtherTab,
2227  SCCOLROW nEndCol, const SCCOLROW* pTranslate,
2228  ScProgress* pProgress, sal_uLong nProAdd );
2230  DECL_LINK(TrackTimeHdl, Timer *, void);
2247  bool LimitRangeToAvailableSheets( const ScRange& rRange, ScRange& o_rRange,
2248  bool& o_bEntirelyOutOfBounds ) const;
2250 public:
2251  void StartListeningArea( const ScRange& rRange, bool bGroupListening, SvtListener* pListener );
2253  void EndListeningArea( const ScRange& rRange, bool bGroupListening, SvtListener* pListener );
2259  void Broadcast( const ScHint& rHint );
2261  void BroadcastCells( const ScRange& rRange, SfxHintId nHint, bool bBroadcastSingleBroadcasters = true );
2264  void AreaBroadcast( const ScHint& rHint );
2265  void DelBroadcastAreasInRange( const ScRange& rRange );
2266  void UpdateBroadcastAreas( UpdateRefMode eUpdateRefMode,
2267  const ScRange& rRange,
2268  SCCOL nDx, SCROW nDy, SCTAB nDz );
2270  void StartListeningCell( const ScAddress& rAddress,
2271  SvtListener* pListener );
2272  void EndListeningCell( const ScAddress& rAddress,
2273  SvtListener* pListener );
2275  void StartListeningCell( sc::StartListeningContext& rCxt, const ScAddress& rPos, SvtListener& rListener );
2276  void EndListeningCell( sc::EndListeningContext& rCxt, const ScAddress& rPos, SvtListener& rListener );
2278  void EndListeningFormulaCells( std::vector<ScFormulaCell*>& rCells );
2280  void PutInFormulaTree( ScFormulaCell* pCell );
2281  void RemoveFromFormulaTree( ScFormulaCell* pCell );
2296  SC_DLLPUBLIC void CalcFormulaTree( bool bOnlyForced = false, bool bProgressBar = true, bool bSetAllDirty = true );
2297  void ClearFormulaTree();
2298  void AppendToFormulaTrack( ScFormulaCell* pCell );
2299  void RemoveFromFormulaTrack( ScFormulaCell* pCell );
2300  void TrackFormulas( SfxHintId nHintId = SfxHintId::ScDataChanged );
2303  void FinalTrackFormulas( SfxHintId nHintId );
2305  bool IsInFormulaTree( const ScFormulaCell* pCell ) const;
2306  bool IsInFormulaTrack( const ScFormulaCell* pCell ) const;
2308  void SetHardRecalcState( HardRecalcState eVal ) { eHardRecalcState = eVal; }
2309  void StartAllListeners();
2310  void StartNeededListeners();
2311  void StartNeededListeners( const std::shared_ptr<const sc::ColumnSet>& rpColSet );
2312  void StartAllListeners( const ScRange& rRange );
2314  void SetForcedFormulas( bool bVal ) { bHasForcedFormulas = bVal; }
2317  bool IsInInterpreter() const { return nInterpretLevel != 0; }
2320  {
2322  if ( nInterpretLevel < USHRT_MAX )
2323  nInterpretLevel++;
2324  }
2326  {
2328  if ( nInterpretLevel )
2329  nInterpretLevel--;
2330  }
2331  sal_uInt16 GetMacroInterpretLevel() const { return nMacroInterpretLevel; }
2333  {
2335  if ( nMacroInterpretLevel < USHRT_MAX )
2336  nMacroInterpretLevel++;
2337  }
2339  {
2341  if ( nMacroInterpretLevel )
2342  nMacroInterpretLevel--;
2343  }
2344  bool IsInInterpreterTableOp() const { return nInterpreterTableOpLevel != 0; }
2346  {
2347  if ( nInterpreterTableOpLevel < USHRT_MAX )
2348  nInterpreterTableOpLevel++;
2349  }
2351  {
2352  if ( nInterpreterTableOpLevel )
2353  nInterpreterTableOpLevel--;
2354  }
2356  // add a formula to be remembered for TableOp broadcasts
2358  void InvalidateLastTableOpParams() { aLastTableOpParams.bValid = false; }
2360  bool IsInDtorClear() const { return bInDtorClear; }
2361  void SetExpandRefs( bool bVal );
2362  bool IsExpandRefs() const { return bExpandRefs; }
2366  {
2367  if ( nXMLImportedFormulaCount + nVal > nXMLImportedFormulaCount )
2368  nXMLImportedFormulaCount += nVal;
2369  }
2371  {
2372  if ( nVal <= nXMLImportedFormulaCount )
2373  nXMLImportedFormulaCount -= nVal;
2374  else
2375  nXMLImportedFormulaCount = 0;
2376  }
2378  void StartTrackTimer();
2380  void CompileDBFormula();
2381  void CompileColRowNameFormula();
2387  sal_Int32 GetMaxStringLen( SCTAB nTab, SCCOL nCol,
2388  SCROW nRowStart, SCROW nRowEnd,
2389  rtl_TextEncoding eCharSet ) const;
2393  sal_Int32 GetMaxNumberStringLen( sal_uInt16& nPrecision,
2394  SCTAB nTab, SCCOL nCol,
2395  SCROW nRowStart, SCROW nRowEnd ) const;
2397  void KeyInput(); // TimerDelays etc.
2399  ScChangeTrack* GetChangeTrack() const { return pChangeTrack.get(); }
2403  SC_DLLPUBLIC void SetChangeTrack( std::unique_ptr<ScChangeTrack> pTrack );
2405  void StartChangeTracking();
2406  void EndChangeTracking();
2408  SC_DLLPUBLIC void CompareDocument( ScDocument& rOtherDoc );
2410  void AddUnoObject( SfxListener& rObject );
2411  void RemoveUnoObject( SfxListener& rObject );
2412  void BroadcastUno( const SfxHint &rHint );
2413  void AddUnoListenerCall( const css::uno::Reference<
2414  css::util::XModifyListener >& rListener,
2415  const css::lang::EventObject& rEvent );
2417  void SetInLinkUpdate(bool bSet); // TableLink or AreaLink
2418  bool IsInLinkUpdate() const; // including DdeLink
2425  std::unique_ptr<ScRefreshTimerControl> const & GetRefreshTimerControlAddress() const
2426  { return pRefreshTimerControl; }
2428  void SetPastingDrawFromOtherDoc( bool bVal )
2429  { bPastingDrawFromOtherDoc = bVal; }
2431  { return bPastingDrawFromOtherDoc; }
2434  sal_uInt32 GetDocumentID() const;
2436  void InvalidateStyleSheetUsage() { bStyleSheetUsageInvalid = true; }
2437  void SC_DLLPUBLIC GetSortParam( ScSortParam& rParam, SCTAB nTab );
2438  void SC_DLLPUBLIC SetSortParam( const ScSortParam& rParam, SCTAB nTab );
2440  void SetVbaEventProcessor( const css::uno::Reference< css::script::vba::XVBAEventProcessor >& rxVbaEvents )
2441  { mxVbaEvents = rxVbaEvents; }
2442  const css::uno::Reference< css::script::vba::XVBAEventProcessor >& GetVbaEventProcessor() const { return mxVbaEvents; }
2449  bool IsInVBAMode() const;
2452  void AddSubTotalCell(ScFormulaCell* pCell);
2453  void RemoveSubTotalCell(ScFormulaCell* pCell);
2454  void SetSubTotalCellsDirty(const ScRange& rDirtyRange);
2456  sal_uInt16 GetTextWidth( const ScAddress& rPos ) const;
2458  SvtScriptType GetScriptType( const ScAddress& rPos ) const;
2459  void SetScriptType( const ScAddress& rPos, SvtScriptType nType );
2460  void UpdateScriptTypes( const ScAddress& rPos, SCCOL nColSize, SCROW nRowSize );
2462  size_t GetFormulaHash( const ScAddress& rPos ) const;
2474  void UnshareFormulaCells( SCTAB nTab, SCCOL nCol, std::vector<SCROW>& rRows );
2475  void RegroupFormulaCells( SCTAB nTab, SCCOL nCol );
2476  void RegroupFormulaCells( const ScRange& range );
2484  bool HandleRefArrayForParallelism( const ScAddress& rPos, SCROW nLength, const ScFormulaCellGroupRef& mxGroup );
2485 #ifdef DBG_UTIL
2486  void AssertNoInterpretNeeded( const ScAddress& rPos, SCROW nLength );
2487 #endif
2493  void PrepareFormulaCalc();
2509  SC_DLLPUBLIC bool EnsureFormulaCellResults( const ScRange& rRange, bool bSkipRunning = false );
2511  SvtBroadcaster* GetBroadcaster( const ScAddress& rPos );
2512  const SvtBroadcaster* GetBroadcaster( const ScAddress& rPos ) const;
2513  void DeleteBroadcasters( sc::ColumnBlockPosition& rBlockPos, const ScAddress& rTopPos, SCROW nLength );
2515  std::unique_ptr<sc::ColumnIterator> GetColumnIterator( SCTAB nTab, SCCOL nCol, SCROW nRow1, SCROW nRow2 ) const;
2516  void CreateColumnIfNotExists( SCTAB nTab, SCCOL nCol );
2518  SC_DLLPUBLIC void StoreTabToCache(SCTAB nTab, SvStream& rStrm) const;
2519  SC_DLLPUBLIC void RestoreTabFromCache(SCTAB nTab, SvStream& rStream);
2522  SC_DLLPUBLIC void DumpColumnStorage( SCTAB nTab, SCCOL nCol ) const;
2523 #endif
2526  SC_DLLPUBLIC void DumpAreaBroadcasters() const;
2527 #endif
2529  SC_DLLPUBLIC void SetCalcConfig( const ScCalcConfig& rConfig );
2530  const ScCalcConfig& GetCalcConfig() const { return maCalcConfig; }
2531  void ConvertFormulaToValue( const ScRange& rRange, sc::TableValues* pUndo );
2532  void SwapNonEmpty( sc::TableValues& rValues );
2533  void finalizeOutlineImport();
2534  bool TableExists( SCTAB nTab ) const;
2536  SC_DLLPUBLIC ScColumnsRange GetColumnsRange(SCTAB nTab, SCCOL nColBegin, SCCOL nColEnd) const;
2538  bool IsInDocShellRecalc() const { return mbDocShellRecalc; }
2539  void SetDocShellRecalc(bool bSet) { mbDocShellRecalc = bSet; }
2549  OString dumpSheetGeomData(SCTAB nTab, bool bColumns, SheetGeomType eGeomType);
2551  SCCOL GetLOKFreezeCol(SCTAB nTab) const;
2552  SCROW GetLOKFreezeRow(SCTAB nTab) const;
2553  bool SetLOKFreezeCol(SCCOL nFreezeCol, SCTAB nTab);
2554  bool SetLOKFreezeRow(SCROW nFreezeRow, SCTAB nTab);
2556 private:
2564  {
2565  public:
2566  explicit NumFmtMergeHandler(ScDocument& rDoc, const ScDocument& rSrcDoc);
2569  private:
2571  };
2573  ScTable* FetchTable( SCTAB nTab );
2574  const ScTable* FetchTable( SCTAB nTab ) const;
2576  void MergeNumberFormatter(const ScDocument& rSrcDoc);
2578  void ImplCreateOptions(); // Suggestion: switch to on-demand?
2579  void ImplDeleteOptions();
2581  void DeleteDrawLayer();
2582  SC_DLLPUBLIC bool DrawGetPrintArea( ScRange& rRange, bool bSetHor, bool bSetVer ) const;
2584  void UpdateDrawPrinter();
2585  void UpdateDrawLanguages();
2586  SC_DLLPUBLIC void InitClipPtrs( ScDocument* pSourceDoc );
2588  void LoadDdeLinks(SvStream& rStream);
2589  void SaveDdeLinks(SvStream& rStream) const;
2591  void DeleteAreaLinksOnTab( SCTAB nTab );
2592  void UpdateRefAreaLinks( UpdateRefMode eUpdateRefMode,
2593  const ScRange& r, SCCOL nDx, SCROW nDy, SCTAB nDz );
2595  void CopyRangeNamesToClip(ScDocument* pClipDoc, const ScRange& rClipRange, const ScMarkData* pMarks);
2597  bool HasPartOfMerged( const ScRange& rRange );
2599  ScRefCellValue GetRefCellValue( const ScAddress& rPos );
2602  std::map< SCTAB, ScSortParam > mSheetSortParams;
2604  SCSIZE GetPatternCount( SCTAB nTab, SCCOL nCol ) const;
2605  SCSIZE GetPatternCount( SCTAB nTab, SCCOL nCol, SCROW nRow1, SCROW nRow2 ) const;
2606  void ReservePatternCount( SCTAB nTab, SCCOL nCol, SCSIZE nReserve );
2608  void SharePooledResources( const ScDocument* pSrcDoc );
2611  sc::EndListeningContext& rCxt, const ScAddress& rPos, std::vector<ScAddress>* pGroupPos );
2614  sc::EndListeningContext& rCxt, const ScRange& rRange, std::vector<ScAddress>* pGroupPos );
2616  void EndListeningGroups( const std::vector<ScAddress>& rPosArray );
2617  void SetNeedsListeningGroups( const std::vector<ScAddress>& rPosArray );
2618 };
2620 typedef std::unique_ptr<ScDocument, o3tl::default_delete<ScDocument>> ScDocumentUniquePtr;
2628 {
2629 #ifndef NDEBUG
2631  : mnFlagRestore(rDocument.mnMutationGuardFlags)
2632  , mrDocument(rDocument)
2633  {
2634  assert((mnFlagRestore & nFlags) == 0);
2635  mrDocument.mnMutationGuardFlags |= static_cast<size_t>(nFlags);
2636  }
2638  {
2640  }
2643 #else
2645  {
2646  (void)rDocument; (void)nFlags;
2647  }
2648 #endif
2649 };
2661 {
2662 #ifndef NDEBUG
2664  : mnFlags(static_cast<size_t>(nFlags))
2665  , mrDocument(rDocument)
2666  {
2668  }
2671  {
2673  }
2674  size_t mnFlags;
2676 #else
2677  ScMutationGuard(ScDocument& rDocument, ScMutationGuardFlags nFlags)
2678  {
2679  (void)rDocument; (void)nFlags;
2680  }
2681 #endif
2682 };
2685 {
2688 public:
2690  : mrDoc(rDoc)
2691  {
2692  assert(!mrDoc.IsInDocShellRecalc());
2693  mrDoc.SetDocShellRecalc(true);
2694  }
2697  {
2698  mrDoc.SetDocShellRecalc(false);
2699  }
2700 };
2702 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
SC_DLLPUBLIC void UpdateTranspose(const ScAddress &rDestPos, ScDocument *pClipDoc, const ScMarkData &rMark, ScDocument *pUndoDoc)
Definition: documen3.cxx:1109
exports util
void FillTabMarked(SCTAB nSrcTab, const ScMarkData &rMark, InsertDeleteFlags nFlags, ScPasteFunc nFunction, bool bSkipEmpty, bool bAsLink)
Definition: document.cxx:3346
SC_DLLPUBLIC OUString GetLinkDoc(SCTAB nTab) const
Definition: documen3.cxx:511
SC_DLLPUBLIC bool IsDocProtected() const
Definition: documen3.cxx:1895
void SetupContextFromNonThreadedContext(ScInterpreterContext &threadedContext, int threadNumber)
Definition: document.cxx:6867
void AddDelayedFormulaGroupingCell(const ScFormulaCell *cell)
To be used only by SharedFormulaUtil::joinFormulaCells().
Definition: document10.cxx:391
SC_DLLPUBLIC bool GetPrintArea(SCTAB nTab, SCCOL &rEndCol, SCROW &rEndRow, bool bNotes=true) const
Definition: documen2.cxx:575
void SetThreadedGroupCalcInProgress(bool set)
Definition: document.hxx:615
Matrix data type that can store values of mixed types.
Definition: scmatrix.hxx:112
bool IsInFormulaTree(const ScFormulaCell *pCell) const
Definition: documen7.cxx:321
bool GetNextMarkedCell(SCCOL &rCol, SCROW &rRow, SCTAB nTab, const ScMarkData &rMark)
Definition: documen4.cxx:540
OUString GetLinkOpt(SCTAB nTab) const
Definition: documen3.cxx:525
SC_DLLPUBLIC const ScPatternAttr * GetMostUsedPattern(SCCOL nCol, SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4800
bool mbEmbedFontScriptComplex
Definition: document.hxx:557
SC_DLLPUBLIC const css::uno::Reference< css::i18n::XBreakIterator > & GetBreakIterator()
Definition: documen6.cxx:40
void BeginDrawUndo()
Definition: documen9.cxx:60
bool IsInDocShellRecalc() const
Definition: document.hxx:2538
void ClearDetectiveOperations()
Definition: documen4.cxx:899
void RemoveMerge(SCCOL nCol, SCROW nRow, SCTAB nTab)
Definition: documen3.cxx:2085
ScCalcConfig maCalcConfig
Definition: document.hxx:362
bool IsBlockEditable(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool *pOnlyNotBecauseOfMatrix=nullptr, bool bNoMatrixAtAll=false) const
Definition: document.cxx:5372
ScMutationGuard(ScDocument &rDocument, ScMutationGuardFlags nFlags)
Definition: document.hxx:2663
void AssertNoInterpretNeeded(const ScAddress &rPos, SCROW nLength)
Definition: document.cxx:1799
SC_DLLPUBLIC ScDPObject * GetDPAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: documen3.cxx:377
SC_DLLPUBLIC void ShowCol(SCCOL nCol, SCTAB nTab, bool bShow)
Definition: document.cxx:4348
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:347
bool IsValidAsianKerning() const
Definition: documen9.cxx:651
bool CanFitBlock(const ScRange &rOld, const ScRange &rNew)
Definition: document.cxx:1823
std::shared_ptr< SvxForbiddenCharactersTable > xForbiddenCharacters
Definition: document.hxx:397
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:1578
void IncInDdeLinkUpdate()
Definition: document.hxx:1016
std::unique_ptr< ScFieldEditEngine > mpEditEngine
Definition: document.hxx:365
void EnableIdle(bool bDo)
Definition: document.hxx:2125
void ClearLookupCaches()
Zap all caches.
Definition: documen2.cxx:1195
void UpdatePageBreaks(SCTAB nTab, const ScRange *pUserArea=nullptr)
Definition: document.cxx:6266
static SC_DLLPUBLIC bool bThreadedGroupCalcInProgress
Calc's threaded group calculation is in progress.
Definition: global.hxx:813
SC_DLLPUBLIC void ApplySelectionStyle(const ScStyleSheet &rStyle, const ScMarkData &rMark)
Definition: document.cxx:4909
VclPtr< SfxPrinter > mpPrinter
Definition: document.hxx:368
bool HasExternalRefManager() const
Definition: document.hxx:1001
bool bIsUndo
Definition: document.hxx:490
void ApplyStyle(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScStyleSheet &rStyle)
Definition: document.cxx:4879
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:1359
bool RefreshAutoFilter(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: document.cxx:5717
bool bStyleSheetUsageInvalid
Definition: document.hxx:540
void ExtendHidden(SCCOL &rX1, SCROW &rY1, SCCOL &rX2, SCROW &rY2, SCTAB nTab)
Definition: document.cxx:4756
void StripHidden(SCCOL &rX1, SCROW &rY1, SCCOL &rX2, SCROW &rY2, SCTAB nTab)
Definition: document.cxx:4750
void ClearSelectionItems(const sal_uInt16 *pWhich, const ScMarkData &rMark)
Definition: document.cxx:5965
sal_uLong GetXMLImportedFormulaCount() const
Definition: document.hxx:2364
::boost::intrusive_ptr< ScFormulaCellGroup > ScFormulaCellGroupRef
Definition: types.hxx:43
SCCOL SanitizeCol(SCCOL nCol) const
Definition: document.hxx:879
SC_DLLPUBLIC void ApplyStyleAreaTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, const ScStyleSheet &rStyle)
Definition: document.cxx:4901
ScFormulaCell * pFormulaTree
Definition: document.hxx:382
void CalculateInColumnInThread(ScInterpreterContext &rContext, const ScRange &rCalcRange, unsigned nThisThread, unsigned nThreadsTotal)
Definition: documen8.cxx:411
SC_DLLPUBLIC bool HasColHeader(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: documen3.cxx:1524
void FitBlock(const ScRange &rOld, const ScRange &rNew, bool bClear=true)
Definition: document.cxx:1854
SC_DLLPUBLIC const ScRange * GetRepeatColRange(SCTAB nTab)
Definition: document.cxx:6332
bool HasLink(std::u16string_view rDoc, std::u16string_view rFilter, std::u16string_view rOptions) const
Definition: documen3.cxx:554
SC_DLLPUBLIC ScDBCollection * GetDBCollection() const
Definition: document.hxx:813
void DeleteConditionalFormat(sal_uLong nIndex, SCTAB nTab)
Definition: documen4.cxx:880
SC_DLLPUBLIC void ShowRows(SCROW nRow1, SCROW nRow2, SCTAB nTab, bool bShow)
Definition: document.cxx:4360
SfxItemSet * GetPreviewFont()
Definition: document.hxx:1338
void GetClipStart(SCCOL &nClipX, SCROW &nClipY)
Definition: document.cxx:3220
void IncXMLImportedFormulaCount(sal_uLong nVal)
Definition: document.hxx:2365
bool HasScenarioRange(SCTAB nTab, const ScRange &rRange) const
Definition: documen3.cxx:864
bool HasUnoRefUndo() const
Definition: document.hxx:1063
void EndChangeTracking()
Definition: documen2.cxx:269
SC_DLLPUBLIC void ApplyPatternIfNumberformatIncompatible(const ScRange &rRange, const ScMarkData &rMark, const ScPatternAttr &rPattern, SvNumFormatType nNewType)
Definition: document.cxx:4844
SC_DLLPUBLIC void SetScenario(SCTAB nTab, bool bFlag)
Definition: documen3.cxx:426
SC_DLLPUBLIC bool GetDataStart(SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow) const
Definition: documen2.cxx:643
std::unique_ptr< ScChangeTrack > pChangeTrack
Definition: document.hxx:390
SC_DLLPUBLIC svl::SharedStringPool & GetSharedStringPool()
Definition: documen2.cxx:565
void SetForcedFormulas(bool bVal)
Definition: document.hxx:2314
sal_uLong nFormulaCount
Definition: document.hxx:279
void SetConsolidateDlgData(std::unique_ptr< ScConsolidateParam > pData)
Definition: documen2.cxx:1106
SC_DLLPUBLIC bool IsTabProtected(SCTAB nTab) const
Definition: documen3.cxx:1906
SC_DLLPUBLIC void GetInputString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rString)
Definition: document.cxx:3590
todo: It should be possible to have MarkArrays for each table, in order to enable "search all" across...
Definition: markdata.hxx:42
std::unique_ptr< ScPatternAttr > CreateSelectionPattern(const ScMarkData &rMark, bool bDeep=true)
Definition: document.cxx:5101
Store parameters used in the ScDocument::SetString() method.
Definition: stringutil.hxx:34
SC_DLLPUBLIC bool HasPrintRange()
Definition: document.cxx:6295
sal_uInt16 nInterpretLevel
Definition: document.hxx:459
void HandleStuffAfterParallelCalculation(SCCOL nColStart, SCCOL nColEnd, SCROW nRow, size_t nLen, SCTAB nTab, ScInterpreter *pInterpreter)
Definition: documen8.cxx:431
SC_DLLPUBLIC CRFlags GetColFlags(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4378
VclPtr< VirtualDevice > mpVirtualDevice_100th_mm
Definition: document.hxx:369
void SetEmbedUsedFontsOnly(bool bUse)
Definition: document.hxx:579
bool IsInInterpreter() const
Definition: document.hxx:2317
bool bChartListenerCollectionNeedsUpdate
Definition: document.hxx:506
void LoadDdeLinks(SvStream &rStream)
Definition: documen8.cxx:747
void SetCutMode(bool bCut)
Definition: document.cxx:2047
Definition: global.hxx:192
SC_DLLPUBLIC bool IsNegativePage(SCTAB nTab) const
Definition: document.cxx:993
Use this to lock all charts in the calc for a little time.
Definition: chartlock.hxx:52
ScUnoListenerCalls stores notifications to XModifyListener that can't be processed during BroadcastUn...
bool IsEnabledDelayStartListeningFormulaCells(ScColumn *column) const
Definition: document10.cxx:421
bool mbUndoEnabled
Definition: document.hxx:542
bool bInDtorClear
Definition: document.hxx:510
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:1799
SC_DLLPUBLIC ScRangeName * GetRangeName() const
Definition: documen3.cxx:176
ScInterpreterContext & GetThreadedContext() const
Definition: document.hxx:609
SCTAB nVisibleTab
Definition: document.hxx:476
OUString maFileURL
Definition: document.hxx:415
void SetEmbedFontScriptComplex(bool bUse)
Definition: document.hxx:582
std::unique_ptr< ScRefreshTimerControl > const & GetRefreshTimerControlAddress() const
Definition: document.hxx:2425
bool UpdateOutlineCol(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bShow)
Adapt Outline.
Definition: documen3.cxx:1408
SC_DLLPUBLIC void SetChangeViewSettings(const ScChangeViewSettings &rNew)
Definition: documen2.cxx:1111
void SetPreviewSelection(const ScMarkData &rSel)
Definition: documen2.cxx:1359
SCSIZE Query(SCTAB nTab, const ScQueryParam &rQueryParam, bool bKeepSub)
Definition: documen3.cxx:1462
SC_DLLPUBLIC void SetTabProtection(SCTAB nTab, const ScTableProtection *pProtect)
Definition: documen3.cxx:1923
const OUString & GetFileURL() const
Definition: document.hxx:597
void CopyCellToDocument(const ScAddress &rSrcPos, const ScAddress &rDestPos, ScDocument &rDestDoc)
Copy only cell, nothing but cell to another document.
Definition: document.cxx:2255
SC_DLLPUBLIC void DoMergeContents(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow)
Definition: documen3.cxx:2031
Definition: global.hxx:317
void SetSheetEvents(SCTAB nTab, std::unique_ptr< ScSheetEvents > pNew)
Definition: documen3.cxx:666
const css::uno::Reference< css::script::vba::XVBAEventProcessor > & GetVbaEventProcessor() const
Definition: document.hxx:2442
SC_DLLPUBLIC 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:2835
SCROW FirstNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4581
ScTable * FetchTable(SCTAB nTab)
Definition: document.cxx:2540
void SetAsianKerning(bool bNew)
Definition: documen9.cxx:664
void RegroupFormulaCells(SCTAB nTab, SCCOL nCol)
Definition: document10.cxx:360
void SetRepeatArea(SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol, SCROW nStartRow, SCROW nEndRow)
Definition: document.cxx:6254
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:2124
void LimitChartIfAll(ScRangeListRef &rRangeList)
Definition: document.cxx:1115
SC_DLLPUBLIC bool IsActiveScenario(SCTAB nTab) const
Definition: documen3.cxx:877
SC_DLLPUBLIC void SetAnonymousDBData(SCTAB nTab, std::unique_ptr< ScDBData > pDBData)
Definition: document.cxx:318
std::unique_ptr< ScClipParam > mpClipParam
Definition: document.hxx:404
void SetInLinkUpdate(bool bSet)
Definition: documen8.cxx:776
sheet protection state container
Definition: drwlayer.hxx:89
std::unique_ptr< ScFieldEditEngine > pCacheFieldEditEngine
Definition: document.hxx:401
SC_DLLPUBLIC void SetTabBgColor(SCTAB nTab, const Color &rColor)
Definition: documen3.cxx:455
SfxObjectShell * mpShell
Definition: document.hxx:367
ScRangePairList * GetColNameRanges()
Definition: document.hxx:805
SC_DLLPUBLIC void SetDrawPageSize(SCTAB nTab)
Definition: documen9.cxx:195
SC_DLLPUBLIC bool InsertTabs(SCTAB nPos, const std::vector< OUString > &rNames, bool bNamesValid=false)
Definition: document.cxx:591
ScInterpreterContext maInterpreterContext
Definition: document.hxx:469
SC_DLLPUBLIC const ScFormulaCell * GetFormulaCell(const ScAddress &rPos) const
Definition: document.cxx:3773
Think of this as a mini-ScColumn like storage that only stores cell values in a column.
Definition: cellvalues.hxx:40
Definition: global.hxx:235
bool IsAddressInRangeName(RangeNameScope eScope, const ScAddress &rAddress)
Definition: documen3.cxx:196
void CopyScenario(SCTAB nSrcTab, SCTAB nDestTab, bool bNewScenario=false)
Definition: documen3.cxx:808
SC_DLLPUBLIC sal_uLong GetFormulaGroupCount() const
Definition: document.cxx:6193
bool IsExpandRefs() const
Definition: document.hxx:2362
SC_DLLPUBLIC void CopyStdStylesFrom(const ScDocument &rSrcDoc)
Definition: documen8.cxx:288
bool IsEmbedFontScriptLatin() const
Definition: document.hxx:574
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:567
SC_DLLPUBLIC void SetLayoutRTL(SCTAB nTab, bool bRTL, ScObjectHandling eObjectHandling=ScObjectHandling::RecalcPosMode)
Definition: document.cxx:949
ScDetOpList * GetDetOpList() const
Definition: document.hxx:1771
SC_DLLPUBLIC bool IsUserInteractionEnabled() const
Definition: document.hxx:1544
SCROW GetLOKFreezeRow(SCTAB nTab) const
bool IsPageStyleInUse(std::u16string_view rStrPageStyle, SCTAB *pInTab)
Definition: documen8.cxx:310
sc::IconSetBitmapMap & GetIconSetBitmapMap()
Definition: documen2.cxx:1385
SC_DLLPUBLIC bool HasTabNotes(SCTAB nTab) const
Definition: document.cxx:6611
sal_uIntPtr sal_uLong
long Long
SC_DLLPUBLIC void CompileHybridFormula()
Call this immediately after updating named ranges.
Definition: document10.cxx:315
bool ValidRange(const ScRange &rRange) const
Definition: document.hxx:877
bool mbUserInteractionEnabled
Definition: document.hxx:546
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:6348
void SetName(const OUString &r)
Definition: document.hxx:594
SC_DLLPUBLIC bool ApplyFlagsTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, ScMF nFlags)
Definition: document.cxx:5057
Enumeration to determine which pieces of the code should not be mutated when set. ...
Definition: document.hxx:304
SC_DLLPUBLIC bool InitColumnBlockPosition(sc::ColumnBlockPosition &rBlockPos, SCTAB nTab, SCCOL nCol)
Definition: document.cxx:2646
bool mbStreamValidLocked
Definition: document.hxx:545
exports embed
std::shared_ptr< sc::FormulaGroupContext > & GetFormulaGroupContext()
Definition: document.cxx:3574
SC_DLLPUBLIC ScDPCollection * GetDPCollection()
Definition: documen3.cxx:365
bool IsUndo() const
Definition: document.hxx:1531
List of RefUpdate changes made to UNO objects during ScUpdateRefHint broadcast.
Definition: unoreflist.hxx:41
sal_Int16 mnNamedRangesLockCount
Definition: document.hxx:548
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:993
void ApplySelectionLineStyle(const ScMarkData &rMark, const ::editeng::SvxBorderLine *pLine, bool bColorOnly)
Definition: document.cxx:4932
static const sal_uInt16 nSrcVer
Definition: document.hxx:473
SC_DLLPUBLIC void InitUndo(const ScDocument &rSrcDoc, SCTAB nTab1, SCTAB nTab2, bool bColInfo=false, bool bRowInfo=false)
Definition: document.cxx:2002
bool IsInDdeLinkUpdate() const
Definition: document.hxx:1018
SC_DLLPUBLIC void SetColHidden(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bHidden)
Definition: document.cxx:4517
rtl::Reference< XColorList > pColorList
Definition: document.hxx:371
void BlockFormulaGroupContextDiscard(bool block)
Definition: document.hxx:1188
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:2629
const ScMarkData & GetPreviewSelection() const
Definition: document.hxx:1340
void SetPendingRowHeights(SCTAB nTab, bool bSet)
Definition: document.cxx:943
rtl_TextEncoding eSrcSet
Definition: document.hxx:451
bool IsTrackFormulasPending() const
Definition: document.hxx:2302
sal_uLong GetCodeCount() const
Definition: document.cxx:6206
sal_uInt16 nFormulaTrackCount
Definition: document.hxx:474
Store position data for column array storage.
SC_DLLPUBLIC sal_Unicode GetSheetSeparator() const
Obtain the sheet separator corresponding to the document's grammar.
Definition: documen4.cxx:1350
ScDocumentThreadSpecific maNonThreaded
Definition: document.hxx:463
bool HasPartOfMerged(const ScRange &rRange)
Definition: document.cxx:1730
void DecInterpreterTableOpLevel()
Definition: document.hxx:2350
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:3052
SC_DLLPUBLIC const ScDBData * GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2) const
Definition: documen3.cxx:338
Cache for faster lookup of automatic names during CompileXML (during CompileXML, no document content ...
bool IsClipOrUndo() const
Definition: document.hxx:1530
void EndListeningIntersectedGroup(sc::EndListeningContext &rCxt, const ScAddress &rPos, std::vector< ScAddress > *pGroupPos)
Definition: document10.cxx:463
void SC_DLLPUBLIC SetSortParam(const ScSortParam &rParam, SCTAB nTab)
Definition: documen3.cxx:2135
Stores cell values for multiple tables.
Definition: cellvalues.hxx:85
SC_DLLPUBLIC void SetRepeatColRange(SCTAB nTab, std::unique_ptr< ScRange > pNew)
Definition: document.cxx:6366
SC_DLLPUBLIC SCROW FirstVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4525
SC_DLLPUBLIC void GetNumberFormat(SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt32 &rFormat) const
Definition: document.cxx:3691
OString dumpSheetGeomData(SCTAB nTab, bool bColumns, SheetGeomType eGeomType)
Serializes the specified sheet's geometry data.
SvtBroadcaster * GetBroadcaster(const ScAddress &rPos)
Definition: document.cxx:2489
SC_DLLPUBLIC sal_uLong AddCondFormat(std::unique_ptr< ScConditionalFormat > pNew, SCTAB nTab)
Definition: documen4.cxx:706
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:76
SC_DLLPUBLIC SCROW LastVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4533
bool bLoadingMedium
Definition: document.hxx:499
bool InsertCol(SCROW nStartRow, SCTAB nStartTab, SCROW nEndRow, SCTAB nEndTab, SCCOL nStartCol, SCSIZE nSize, ScDocument *pRefUndoDoc=nullptr, const ScMarkData *pTabMark=nullptr)
Definition: document.cxx:1491
bool bCalcingAfterLoad
Definition: document.hxx:501
HardRecalcState eHardRecalcState
Definition: document.hxx:475
VirtualDevice * GetVirtualDevice_100th_mm()
Definition: documen8.cxx:181
SC_DLLPUBLIC double * GetValueCell(const ScAddress &rPos)
Return a pointer to the double value stored in value cell.
Definition: document.cxx:3558
Stores options which are only relevant for clipboard documents.
Definition: clipoptions.hxx:21
ScDocShellRecalcGuard(ScDocument &rDoc)
Definition: document.hxx:2689
SC_DLLPUBLIC void SetValue(SCCOL nCol, SCROW nRow, SCTAB nTab, const double &rVal)
Definition: document.cxx:3508
SC_DLLPUBLIC void InsertTableOp(const ScTabOpParam &rParam, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark)
Definition: documen4.cxx:356
sal_Int64 GetNewUnoId()
Definition: document.hxx:1066
This is very similar to ScCellValue, except that it references the original value instead of copying ...
Definition: cellvalue.hxx:103
SC_DLLPUBLIC formula::FormulaGrammar::Grammar GetGrammar() const
Definition: document.hxx:983
sal_uInt16 nInterpreterTableOpLevel
Definition: document.hxx:461
bool IsHorOverlapped(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:5774
void GetEmbedded(ScRange &rRange) const
Definition: documen3.cxx:1701
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:1479
SC_DLLPUBLIC ScDBData * GetAnonymousDBData()
Definition: document.cxx:329
std::unique_ptr< ScExtDocOptions > pExtDocOptions
Definition: document.hxx:421
SC_DLLPUBLIC ScRange GetRange(SCTAB nTab, const tools::Rectangle &rMMRect, bool bHiddenAsZero=true) const
Definition: documen3.cxx:1798
std::unique_ptr< ScValidationDataList > pValidationList
Definition: document.hxx:372
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:4807
Accessor class to ScDocument.
bool bImportingXML
Definition: document.hxx:500
ScFormulaVectorState GetFormulaVectorState(const ScAddress &rPos) const
Definition: document.cxx:1761
void SetPreviewFont(std::unique_ptr< SfxItemSet > pFontSet)
Definition: documen2.cxx:1354
Lookup cache for one range used with interpreter functions such as VLOOKUP and MATCH.
Definition: lookupcache.hxx:39
void ApplyAsianEditSettings(ScEditEngineDefaulter &rEngine)
Definition: documen9.cxx:673
sc::DocumentLinkManager & GetDocLinkManager()
Definition: documen2.cxx:227
void SetClipOptions(std::unique_ptr< ScClipOptions > pClipOptions)
Definition: documen3.cxx:2026
bool IsLinked(SCTAB nTab) const
Definition: documen3.cxx:485
SC_DLLPUBLIC SfxUndoManager * GetUndoManager()
Definition: document.cxx:6421
SC_DLLPUBLIC void SetRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual)
Definition: document.cxx:4439
void SetPrinter(VclPtr< SfxPrinter > const &pNewPrinter)
Definition: documen8.cxx:141
css::uno::Reference< css::embed::XEmbeddedObject > FindOleObjectByName(std::u16string_view rName)
Definition: documen5.cxx:536
bool HasStringWeakCharacters(const OUString &rString)
Definition: documen6.cxx:51
css::uno::Sequence< css::sheet::TablePageBreakData > GetRowBreakData(SCTAB nTab) const
Definition: document.cxx:4471
ScFormulaCell * pEOFormulaTrack
Definition: document.hxx:385
void SetHardRecalcState(HardRecalcState eVal)
Definition: document.hxx:2308
SCSIZE GetPatternCount(SCTAB nTab, SCCOL nCol) const
Definition: documen3.cxx:2108
void GetClipArea(SCCOL &nClipX, SCROW &nClipY, bool bIncludeFiltered)
Definition: document.cxx:3168
bool DoSubTotals(SCTAB nTab, ScSubTotalParam &rParam)
Definition: documen3.cxx:777
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:1153
std::map< SCTAB, ScSortParam > mSheetSortParams
Definition: document.hxx:2602
css::uno::Reference< css::chart2::XChartDocument > GetChartByName(std::u16string_view rChartName)
Definition: documen5.cxx:137
SC_DLLPUBLIC void SetVisible(SCTAB nTab, bool bVisible)
Definition: document.cxx:900
SC_DLLPUBLIC formula::FormulaGrammar::AddressConvention GetAddressConvention() const
Definition: documen3.cxx:494
bool ValidColRowTab(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.hxx:876
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:70
sal_uLong nXMLImportedFormulaCount
Definition: document.hxx:458
SC_DLLPUBLIC bool HasAttrib(SCCOL nCol1, SCROW nRow1, SCTAB nTab1, SCCOL nCol2, SCROW nRow2, SCTAB nTab2, HasAttrFlags nMask) const
Definition: document.cxx:5224
bool HasAutoFilter(SCCOL nCol, SCROW nRow, SCTAB nTab)
Definition: documen3.cxx:1492
std::unique_ptr< ScPrintRangeSaver > CreatePrintRangeSaver() const
Definition: document.cxx:6378
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:193
void GetNotesInRange(const ScRangeList &rRange, std::vector< sc::NoteEntry > &rNotes) const
Definition: document.cxx:6811
void EndListeningGroups(const std::vector< ScAddress > &rPosArray)
Definition: document10.cxx:488
bool TableExists(SCTAB nTab) const
Definition: document.cxx:2535
void UpdateChart(const OUString &rName)
Definition: documen5.cxx:335
SC_DLLPUBLIC SvtScriptType GetStringScriptType(const OUString &rString)
Definition: documen6.cxx:76
SvNumberFormatterIndexTable * pFormatExchangeList
Definition: document.hxx:373
SC_DLLPUBLIC void GetFormula(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rFormula) const
Definition: document.cxx:3765
bool IsAdjustHeightLocked() const
Definition: document.hxx:1537
SC_DLLPUBLIC ScBreakType HasRowBreak(SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4409
SC_DLLPUBLIC sal_uInt16 GetRowHeight(SCROW nRow, SCTAB nTab, bool bHiddenAsZero=true) const
Definition: document.cxx:4211
void StartAnimations(SCTAB nTab)
Definition: documen9.cxx:319
SC_DLLPUBLIC ScNoteEditEngine & GetNoteEngine()
Definition: documen2.cxx:469
void SetClipParam(const ScClipParam &rParam)
Definition: document.cxx:2592
bool mbChangeReadOnlyEnabled
Definition: document.hxx:544
ScAddress aCurTextWidthCalcPos
Definition: document.hxx:435
void AddUnoRefChange(sal_Int64 nId, const ScRangeList &rOldRanges)
Definition: documen3.cxx:999
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:3481
exports sheet
void MixDocument(const ScRange &rRange, ScPasteFunc nFunction, bool bSkipEmpty, ScDocument &rSrcDoc)
Definition: document.cxx:3258
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:5292
bool GetNextSpellingCell(SCCOL &nCol, SCROW &nRow, SCTAB nTab, bool bInSel, const ScMarkData &rMark) const
Definition: documen4.cxx:531
std::unique_ptr< SfxBroadcaster > pUnoBroadcaster
Definition: document.hxx:391
Row-wise value iterator.
Definition: dociter.hxx:478
std::map< sal_uInt16, sal_uInt32 > SvNumberFormatterIndexTable
SC_DLLPUBLIC void CopyStaticToDocument(const ScRange &rSrcRange, SCTAB nDestTab, ScDocument &rDestDoc)
Copy only raw cell values to another document.
Definition: document.cxx:2239
void UnlockTable(SCTAB nTab)
Definition: document.cxx:5362
bool HasAnySheetEventScript(ScSheetEventId nEvent, bool bWithVbaEvents=false) const
Definition: documen3.cxx:696
bool IsExecuteLinkEnabled() const
Definition: document.hxx:1540
SC_DLLPUBLIC ScDocumentPool * GetPool()
Definition: document.cxx:6106
void Sort(SCTAB nTab, const ScSortParam &rSortParam, bool bKeepQuery, bool bUpdateRefs, ScProgress *pProgress, sc::ReorderParam *pUndo)
Sort a range of data.
Definition: documen3.cxx:1426
void TransliterateText(const ScMarkData &rMultiMark, TransliterationFlags nType)
Definition: documen8.cxx:1210
SC_DLLPUBLIC const ScValidationData * GetValidationEntry(sal_uLong nIndex) const
Definition: documen4.cxx:872
LanguageType eCjkLanguage
Definition: document.hxx:449
void InvalidateTableArea()
Definition: documen4.cxx:577
ScLkUpdMode eLinkMode
Definition: document.hxx:480
SC_DLLPUBLIC bool IsManualRowHeight(SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4605
SfxPrinter * GetPrinter(bool bCreateIfNotExist=true)
Definition: documen8.cxx:113
void DeleteDrawLayer()
Definition: documen9.cxx:229
SC_DLLPUBLIC void SetImportingXML(bool bVal)
Definition: documen9.cxx:592
size_t GetFormulaHash(const ScAddress &rPos) const
Definition: document.cxx:1752
void SetAllFormulasDirty(const sc::SetFormulaDirtyContext &rCxt)
Definition: document.cxx:3885
SC_DLLPUBLIC void SetGrammar(formula::FormulaGrammar::Grammar eGram)
Definition: documen3.cxx:499
const ScStyleSheet * GetStyle(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4948
SC_DLLPUBLIC bool GetPrintAreaVer(SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol, SCROW &rEndRow, bool bNotes) const
Definition: documen2.cxx:621
void RepaintRange(const ScRange &rRange)
Definition: documen8.cxx:689
sal_uInt16 sal_Unicode
bool IsPendingRowHeights(SCTAB nTab) const
Definition: document.cxx:935
SC_DLLPUBLIC ScPostIt * GetNote(const ScAddress &rPos)
Definition: document.cxx:6553
void SetEmbedFontScriptLatin(bool bUse)
Definition: document.hxx:580
SC_DLLPUBLIC bool LinkExternalTab(SCTAB &nTab, const OUString &aDocTab, const OUString &aFileName, const OUString &aTabName)
Definition: documen3.cxx:568
SC_DLLPUBLIC ScConditionalFormatList * GetCondFormList(SCTAB nTab) const
Definition: documen4.cxx:858
CommentCaptionState GetAllNoteCaptionsState(const ScRangeList &rRanges)
Definition: document.cxx:6694
SC_DLLPUBLIC void CheckLinkFormulaNeedingCheck(const ScTokenArray &rCode)
Check token array and set link check if ocDde/ocWebservice is contained.
Definition: documen8.cxx:1154
bool ValidColRowTab(SCCOL nCol, SCROW nRow, SCTAB nTab, SCCOL nMaxCol, SCROW nMaxRow)
Definition: address.hxx:120
bool HandleRefArrayForParallelism(const ScAddress &rPos, SCROW nLength, const ScFormulaCellGroupRef &mxGroup)
Definition: document.cxx:1814
bool bForcedFormulaPending
Definition: document.hxx:487
std::unordered_map< ScColumn *, std::pair< SCROW, SCROW > > pDelayedStartListeningFormulaCells
Definition: document.hxx:524
const std::shared_ptr< SvxForbiddenCharactersTable > & GetForbiddenCharacters() const
Definition: documen9.cxx:615
void SetChartListenerCollectionNeedsUpdate(bool bFlg)
Definition: document.hxx:2157
void DoAutoOutline(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: documen3.cxx:759
SC_DLLPUBLIC bool RenameTab(SCTAB nTab, const OUString &rName, bool bExternalDocument=false)
Definition: document.cxx:852
formula::FormulaGrammar::Grammar eGrammar
Definition: document.hxx:538
ScClipParam & GetClipParam()
Definition: document.cxx:2584
SC_DLLPUBLIC sal_uInt16 GetOriginalWidth(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4187
void InvalidateStyleSheetUsage()
Definition: document.hxx:2436
void UpdateReference(sc::RefUpdateContext &rCxt, ScDocument *pUndoDoc=nullptr, bool bIncludeDraw=true, bool bUpdateNoteCaptionPos=true)
Definition: documen3.cxx:1005
ScDocument & mrDocument
Definition: document.hxx:2642
Definition: document.hxx:871
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:44
sal_Int32 SCCOLROW
a type capable of holding either SCCOL or SCROW
Definition: types.hxx:23
const BorderLinePrimitive2D *pCandidateB assert(pCandidateA)
void SetNamedRangesLockCount(sal_Int16 nCount)
Definition: document.hxx:1547
void SetCodeName(const OUString &r)
Definition: document.hxx:596
SC_DLLPUBLIC SCTAB GetTableCount() const
Definition: document.cxx:313
SC_DLLPUBLIC SCROW GetLastFlaggedRow(SCTAB nTab) const
Definition: document.cxx:4622
SvtScriptType GetRangeScriptType(sc::ColumnBlockPosition &rBlockPos, const ScAddress &rPos, SCROW nLength)
Definition: documen6.cxx:183
Additional class containing cell annotation data.
Definition: postit.hxx:159
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:426
ScFormulaCell * pEOFormulaTree
Definition: document.hxx:383
SC_DLLPUBLIC void PreprocessAllRangeNamesUpdate(const std::map< OUString, std::unique_ptr< ScRangeName >> &rRangeMap)
Call this immediately before updating all named ranges.
Definition: document10.cxx:245
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:800
SC_DLLPUBLIC void SetColWidth(SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth)
Definition: document.cxx:4133
void SetExpandRefs(bool bVal)
Definition: documen2.cxx:307
const ScPatternAttr * GetSelectionPattern(const ScMarkData &rMark)
Definition: document.cxx:5145
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:368
sal_uLong GetFormulaCodeInTree() const
Definition: document.hxx:2315
TableContainer maTabs
Definition: document.hxx:374
bool SetDdeLinkResultMatrix(size_t nDdePos, const ScMatrixRef &pResults)
Sets a result matrix for the specified DDE link.
Definition: documen8.cxx:1024
void SetEmbedFontScriptAsian(bool bUse)
Definition: document.hxx:581
Definition: global.hxx:418
const ScValidationDataList * GetValidationList() const
Definition: document.hxx:1798
Definition: global.hxx:342
std::unique_ptr< ScRefreshTimerControl > pRefreshTimerControl
Definition: document.hxx:396
void DecInDdeLinkUpdate()
Definition: document.hxx:1017
SC_DLLPUBLIC sc::ExternalDataMapper & GetExternalDataMapper()
SC_DLLPUBLIC OUString GetString(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScInterpreterContext *pContext=nullptr) const
Definition: document.cxx:3536
void DecInterpretLevel()
Definition: document.hxx:2325
std::unique_ptr< ScBroadcastAreaSlotMachine > pBASM
Definition: document.hxx:386
bool IsFinalTrackFormulas() const
Definition: document.hxx:2304
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:2068
std::unique_ptr< ScConsolidateParam > pConsolidateDlgData
Definition: document.hxx:423
void SetChartListenerCollection(std::unique_ptr< ScChartListenerCollection >, bool bSetChartRangeLists)
Definition: documen3.cxx:412
void SetNoListening(bool bVal)
Definition: document.hxx:2146
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:4290
bool bInsertingFromOtherDoc
Definition: document.hxx:498
bool ValidRange(const ScRange &rRange, SCCOL nMaxCol=MAXCOL, SCROW nMaxRow=MAXROW)
Definition: address.hxx:792
SC_DLLPUBLIC void TransferDrawPage(const ScDocument &rSrcDoc, SCTAB nSrcPos, SCTAB nDestPos)
Definition: documen9.cxx:66
void GetOldChartParameters(std::u16string_view rName, ScRangeList &rRanges, bool &rColHeaders, bool &rRowHeaders)
Definition: documen5.cxx:202
SC_DLLPUBLIC bool GetTable(const OUString &rName, SCTAB &rTab) const
Definition: document.cxx:259
SC_DLLPUBLIC ScExternalRefManager * GetExternalRefManager() const
Definition: documen3.cxx:623
SC_DLLPUBLIC bool IsDocVisible() const
Definition: document.hxx:1554
void UpdateScriptTypes(const ScAddress &rPos, SCCOL nColSize, SCROW nRowSize)
Definition: document10.cxx:333
bool IsAutoCalcShellDisabled() const
Definition: document.hxx:1361
std::unique_ptr< ScDocProtection > pDocProtection
Definition: document.hxx:403
::boost::intrusive_ptr< ScMatrix > ScMatrixRef
Definition: types.hxx:25
std::map< OUString, BitmapEx > IconSetBitmapMap
Definition: document.hxx:207
OUString aDocCodeName
Definition: document.hxx:414
Walk through all cells in an area.
Definition: dociter.hxx:207
tools::Rectangle GetEmbeddedRect() const
Definition: documen3.cxx:1706
bool RemovePageStyleInUse(std::u16string_view rStrPageStyle)
Definition: documen8.cxx:325
SC_DLLPUBLIC bool HasTable(SCTAB nTab) const
Definition: document.cxx:190
Definition: global.hxx:224
void EndListeningIntersectedGroups(sc::EndListeningContext &rCxt, const ScRange &rRange, std::vector< ScAddress > *pGroupPos)
Definition: document10.cxx:473
bool mbIdleEnabled
Definition: document.hxx:504
void DiscardFormulaGroupContext()
Definition: document.cxx:3583
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:6139
formula::VectorRefArray FetchVectorRefArray(const ScAddress &rPos, SCROW nLength)
Definition: document.cxx:1789
SC_DLLPUBLIC const ScRange * GetPrintRange(SCTAB nTab, sal_uInt16 nPos)
Definition: document.cxx:6324
std::set< ScFormulaCell * > maSubTotalCells
Definition: document.hxx:550
void SetError(SCCOL nCol, SCROW nRow, SCTAB nTab, const FormulaError nError)
Definition: documen2.cxx:1058
bool HasSheetEventScript(SCTAB nTab, ScSheetEventId nEvent, bool bWithVbaEvents=false) const
Definition: documen3.cxx:672
const sal_uInt8 SC_DDE_IGNOREMODE
Definition: document.hxx:294
void RestoreChartListener(const OUString &rName)
Definition: documen5.cxx:363
void CopyTabProtection(SCTAB nTabSrc, SCTAB nTabDest)
Definition: documen3.cxx:1931
void Clear(bool bFromDestructor=false)
Definition: documen9.cxx:500
SCTAB GetMaxTableNumber() const
Definition: document.hxx:803
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:326
Optimized ColumnSpanSet version that operates on a single ScRange.
bool IsEmbedUsedFontsOnly() const
Definition: document.hxx:573
std::unique_ptr< ScDBData > mpAnonymousDBData
Definition: document.hxx:398
sal_uInt16 ColDifferences(SCCOL nThisCol, SCTAB nThisTab, ScDocument &rOtherDoc, SCCOL nOtherCol, SCTAB nOtherTab, SCROW nMaxRow, const SCCOLROW *pOtherRows)
Definition: documen4.cxx:955
bool SetOutlineTable(SCTAB nTab, const ScOutlineTable *pNewOutline)
Definition: documen3.cxx:754
SCROW SanitizeRow(SCROW nRow, SCROW nMaxRow)
Definition: address.hxx:132
void PrepareFormulaCalc()
Call this before any operations that might trigger one or more formula cells to get calculated...
Definition: document.cxx:2483
void PageStyleModified(SCTAB nTab, const OUString &rNewName)
Definition: document.cxx:6219
SC_DLLPUBLIC void SetColWidthOnly(SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth)
Definition: document.cxx:4139
SC_DLLPUBLIC void ResetClip(ScDocument *pSourceDoc, const ScMarkData *pMarks)
Definition: documen2.cxx:487
ScBroadcastAreaSlotMachine * GetBASM() const
Definition: document.hxx:2148
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:4819
SC_DLLPUBLIC void SetRowHeightOnly(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, sal_uInt16 nNewHeight)
Definition: document.cxx:4158
bool mbTrackFormulasPending
Definition: document.hxx:561
SC_DLLPUBLIC const ScPatternAttr * GetPattern(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4785
void ReplaceStyle(const SvxSearchItem &rSearchItem, SCCOL nCol, SCROW nRow, SCTAB nTab, const ScMarkData &rMark)
Definition: documen4.cxx:549
SfxUndoManager * mpUndoManager
Definition: document.hxx:364
bool CopyOneCellFromClip(sc::CopyFromClipContext &rCxt, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2)
Definition: document10.cxx:81
void MarkUsedExternalReferences()
Definition: documen3.cxx:637
bool IsPrintEntireSheet(SCTAB nTab) const
Returns true, if the specified sheet is always printed.
Definition: document.cxx:6311
bool bHasForcedFormulas
Definition: document.hxx:508
void FinalTrackFormulas(SfxHintId nHintId)
Definition: documen7.cxx:506
ScChangeTrack * GetChangeTrack() const
Definition: document.hxx:2399
std::unique_ptr< ScDrawLayer > mpDrawLayer
Definition: document.hxx:370
void CopyTabToClip(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, SCTAB nTab, ScDocument *pClipDoc)
Definition: document.cxx:2266
bool ColFiltered(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4565
bool mbFinalTrackFormulas
Definition: document.hxx:562
void GetFilterEntries(SCCOL nCol, SCROW nRow, SCTAB nTab, ScFilterEntries &rFilterEntries)
Get a list of unique strings to use in filtering criteria.
Definition: documen3.cxx:1551
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:4764
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:2145
void StylesToNames()
Definition: document.cxx:6167
void StartListeningCell(const ScAddress &rAddress, SvtListener *pListener)
Definition: documen7.cxx:208
void ImplCreateOptions()
Definition: documen8.cxx:100
void SetInsertingFromOtherDoc(bool bVal)
Definition: document.hxx:2140
void SetSrcCharSet(rtl_TextEncoding eNew)
Definition: document.hxx:2056
void ResetEmbedded()
Definition: documen3.cxx:1745
bool GetNoListening() const
Definition: document.hxx:2147
bool IsStreamValid(SCTAB nTab) const
Definition: document.cxx:916
ScStyleSheet * GetPreviewCellStyle()
Definition: document.hxx:1342
bool HasValidationData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3859
SC_DLLPUBLIC bool GetCellArea(SCTAB nTab, SCCOL &rEndCol, SCROW &rEndRow) const
Definition: document.cxx:1009
ScRangePairListRef xColNameRanges
Definition: document.hxx:416
bool IsClipboard() const
Definition: document.hxx:1532
SC_DLLPUBLIC bool HasRowHeader(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: documen3.cxx:1530
SC_DLLPUBLIC double GetValue(const ScAddress &rPos) const
Definition: document.cxx:3678
ScMutationDisable(ScDocument &rDocument, ScMutationGuardFlags nFlags)
Definition: document.hxx:2630
SC_DLLPUBLIC const ScDocOptions & GetDocOptions() const
Definition: documen3.cxx:1939
SCCOL SanitizeCol(SCCOL nCol, SCCOL nMaxCol)
Definition: address.hxx:126
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:258
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:435
bool HasCalcNotification(SCTAB nTab) const
Definition: documen3.cxx:714
A pretty assertion that checks that the relevant bits in the are not set on the document at entry an...
Definition: document.hxx:2660
bool bInUnoBroadcast
Definition: document.hxx:535
size_t mnMutationGuardFlags
Definition: document.hxx:566
void AddOLEObjectToCollection(const OUString &rName)
Definition: documen5.cxx:645
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:3444
SC_DLLPUBLIC void DumpColumnStorage(SCTAB nTab, SCCOL nCol) const
void AddDetectiveOperation(const ScDetOpData &rData)
Definition: documen4.cxx:891
void InvalidateStreamOnSave()
Definition: document.cxx:494
bool HasDetectiveObjects(SCTAB nTab) const
Definition: documen9.cxx:515
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:1088
SC_DLLPUBLIC void SetAutoNameCache(std::unique_ptr< ScAutoNameCache > pCache)
Definition: document.cxx:6844
void SwapNonEmpty(sc::TableValues &rValues)
Definition: document10.cxx:223
bool ValidCol(SCCOL nCol, SCCOL nMaxCol)
Definition: address.hxx:92
ScRefCellValue GetRefCellValue(const ScAddress &rPos)
Definition: documen2.cxx:549
SC_DLLPUBLIC void SetVisibleTab(SCTAB nTab)
Definition: document.hxx:858
Enum used to indicate which portion of the DBArea is to be considered.
Definition: dbdata.hxx:40
Definition: global.hxx:188
SC_DLLPUBLIC bool SetString(SCCOL nCol, SCROW nRow, SCTAB nTab, const OUString &rString, const ScSetStringParam *pParam=nullptr)
Definition: document.cxx:3413
std::unique_ptr< ScViewOptions > pViewOptions
Definition: document.hxx:419
SC_DLLPUBLIC ScDocProtection * GetDocProtection() const
Definition: documen3.cxx:1882
bool HasOLEObjectsInArea(const ScRange &rRange, const ScMarkData *pTabMark=nullptr)
Definition: documen9.cxx:276
bool IsCellInChangeTrack(const ScAddress &cell, Color *pColCellBorder)
Definition: documen2.cxx:1203
bool HasAnyCalcNotification() const
Definition: documen3.cxx:705
bool HasClipFilteredRows()
Definition: document.cxx:3237
bool bExpandRefs
Definition: document.hxx:515
formula::FormulaGrammar::Grammar eStorageGrammar
The compiler grammar used in document storage.
Definition: document.hxx:455
SC_DLLPUBLIC ScPostIt * GetOrCreateNote(const ScAddress &rPos)
Definition: document.cxx:6644
SC_DLLPUBLIC void SetScenarioData(SCTAB nTab, const OUString &rComment, const Color &rColor, ScScenarioFlags nFlags)
Definition: documen3.cxx:437
SC_DLLPUBLIC ScDrawLayer * GetDrawLayer()
Definition: document.hxx:1057
void SetClipArea(const ScRange &rArea, bool bCut=false)
Definition: document.cxx:3153
Definition: document.hxx:870
T * get() const
std::unique_ptr< ScUnoRefList > EndUnoRefUndo()
Definition: documen3.cxx:993
const ScStyleSheet * GetSelectionStyle(const ScMarkData &rMark) const
Definition: document.cxx:4956
SC_DLLPUBLIC SvNumberFormatter * GetFormatTable() const
Definition: documen2.cxx:440
SC_DLLPUBLIC bool ColHidden(SCCOL nCol, SCTAB nTab, SCCOL *pFirstCol=nullptr, SCCOL *pLastCol=nullptr) const
Definition: document.cxx:4495
SC_DLLPUBLIC void SetPattern(const ScAddress &, const ScPatternAttr &rAttr)
Definition: document.cxx:5094
bool IsChartListenerCollectionNeedsUpdate() const
Definition: document.hxx:2156
bool IsInsertingFromOtherDoc() const
Definition: document.hxx:2141
void ApplyFrameAreaTab(const ScRange &rRange, const SvxBoxItem &rLineOuter, const SvxBoxInfoItem &rLineInner)
Definition: document.cxx:5906
bool CopyTab(SCTAB nOldPos, SCTAB nNewPos, const ScMarkData *pOnlyMarked=nullptr)
Definition: documen2.cxx:767
SC_DLLPUBLIC void InitDrawLayer(SfxObjectShell *pDocShell=nullptr)
Definition: documen9.cxx:98
Parameter for data table aka multiple operations.
Definition: paramisc.hxx:45
bool PastingDrawFromOtherDoc() const
Definition: document.hxx:2430
void GetScenarioFlags(SCTAB nTab, ScScenarioFlags &rFlags) const
Definition: documen3.cxx:479
bool bIsFunctionAccess
Definition: document.hxx:491
void Reorder(const sc::ReorderParam &rParam)
Definition: documen3.cxx:1439
Definition: global.hxx:325
void DelayFormulaGrouping(bool delay)
If set, joining cells into shared formula groups will be delayed until reset again (RegroupFormulaCel...
Definition: document10.cxx:376
void SetStorageGrammar(formula::FormulaGrammar::Grammar eGrammar)
Should only be GRAM_PODF or GRAM_ODFF.
Definition: documen2.cxx:237
ScRecursionHelper & GetRecursionHelper()
Definition: document.cxx:6851
SC_DLLPUBLIC sal_uInt16 GetPrintRangeCount(SCTAB nTab)
Definition: document.cxx:6316
SCROW CountNonFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4597
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:6260
void SetDBCollection(std::unique_ptr< ScDBCollection > pNewDBCollection, bool bRemoveAutoFilter=false)
Definition: documen3.cxx:275
std::unique_ptr< ScDPCollection > pDPCollection
Definition: document.hxx:379
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:2144
Keep track of all named expressions that have been updated during reference update.
SCCOL nPosLeft
Definition: document.hxx:477
void EnableExecuteLink(bool bVal)
Definition: document.hxx:1541
sal_uInt16 RowDifferences(SCROW nThisRow, SCTAB nThisTab, ScDocument &rOtherDoc, SCROW nOtherRow, SCTAB nOtherTab, SCCOL nMaxCol, const SCCOLROW *pOtherCols)
Definition: documen4.cxx:917
bool bIsEmbedded
Definition: document.hxx:494
void GetCellChangeTrackNote(const ScAddress &cell, OUString &strTrackText, bool &pbLeftEdge)
Definition: documen2.cxx:1266
SCROW GetNextDifferentChangedRow(SCTAB nTab, SCROW nStart) const
Definition: document.cxx:4661
SC_DLLPUBLIC bool HasPivotTable() const
Definition: documen3.cxx:360
LanguageType eCtlLanguage
Definition: document.hxx:450
SC_DLLPUBLIC const ScRangeList * GetScenarioRanges(SCTAB nTab) const
Definition: documen3.cxx:869
SC_DLLPUBLIC bool IsDefaultTabBgColor(SCTAB nTab) const
Definition: documen3.cxx:461
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:342
void GetColDefault(SCTAB nTab, SCCOL nCol, SCROW nLastRow, SCROW &nDefault)
Definition: document.cxx:4703
rtl::Reference< ScSheetLimits > mxSheetLimits
Definition: document.hxx:375
void DeleteBroadcasters(sc::ColumnBlockPosition &rBlockPos, const ScAddress &rTopPos, SCROW nLength)
Definition: document.cxx:2507
void UpdateAllRowHeights(sc::RowHeightContext &rCxt, const ScMarkData *pTabMark)
Definition: document.cxx:4325
SC_DLLPUBLIC void SetActiveScenario(SCTAB nTab, bool bActive)
Definition: documen3.cxx:882
void DelBroadcastAreasInRange(const ScRange &rRange)
Definition: documen7.cxx:202
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:1657
SC_DLLPUBLIC bool FindDdeLink(std::u16string_view rAppl, std::u16string_view rTopic, std::u16string_view rItem, sal_uInt8 nMode, size_t &rnDdePos)
Tries to find a DDE link with the specified connection data.
Definition: documen8.cxx:959
void FillTab(const ScRange &rSrcArea, const ScMarkData &rMark, InsertDeleteFlags nFlags, ScPasteFunc nFunction, bool bSkipEmpty, bool bAsLink)
Definition: document.cxx:3278
void CompileXML()
Definition: document.cxx:4020
SC_DLLPUBLIC bool RowFiltered(SCROW nRow, SCTAB nTab, SCROW *pFirstRow=nullptr, SCROW *pLastRow=nullptr) const
Definition: document.cxx:4549
bool bDetectiveDirty
Definition: document.hxx:517
std::shared_ptr< sc::FormulaGroupContext > mpFormulaGroupCxt
Definition: document.hxx:359
Definition: global.hxx:334
ScAddress GetNotePosition(size_t nIndex) const
Definition: document.cxx:6727
std::unique_ptr< ScDocument, o3tl::default_delete< ScDocument > > ScDocumentUniquePtr
Definition: document.hxx:2620
SC_DLLPUBLIC void GetAllColBreaks(std::set< SCCOL > &rBreaks, SCTAB nTab, bool bPage, bool bManual) const
Definition: document.cxx:4401
void IncMacroInterpretLevel()
Definition: document.hxx:2332
SC_DLLPUBLIC void RestoreTabFromCache(SCTAB nTab, SvStream &rStream)
sal_Int16 SCCOL
Definition: types.hxx:21
void DeleteSelection(InsertDeleteFlags nDelFlag, const ScMarkData &rMark, bool bBroadcast=true)
Definition: document.cxx:5977
std::unique_ptr< sc::ExternalDataMapper > mpDataMapper
Definition: document.hxx:399
void GetAutoFormatData(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, ScAutoFormatData &rData)
Definition: documen3.cxx:1200
Definition: global.hxx:157
SC_DLLPUBLIC const ScMatrix * GetDdeLinkResultMatrix(size_t nDdePos) const
Returns the result matrix of the specified DDE link.
Definition: documen8.cxx:987
SCCOL GetNextDifferentChangedCol(SCTAB nTab, SCCOL nStart) const
Definition: document.cxx:4643
bool ValidCol(SCCOL nCol) const
Definition: document.hxx:873
void SetVbaEventProcessor(const css::uno::Reference< css::script::vba::XVBAEventProcessor > &rxVbaEvents)
Definition: document.hxx:2440
NumFmtMergeHandler(ScDocument &rDoc, const ScDocument &rSrcDoc)
Definition: document.cxx:2471
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:965
LanguageType eLanguage
Definition: document.hxx:448
bool HasBackgroundDraw(SCTAB nTab, const tools::Rectangle &rMMRect) const
Definition: documen9.cxx:343
sal_uLong GetScaledRowHeight(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, double fScale, const sal_uLong *pnMaxHeight=nullptr) const
Definition: document.cxx:4248
void RestorePrintRanges(const ScPrintRangeSaver &rSaver)
Definition: document.cxx:6388
SC_DLLPUBLIC void SetAutoCalc(bool bNewAutoCalc)
Definition: documen7.cxx:602
void EnableChangeReadOnly(bool bVal)
Definition: document.hxx:1543
bool HasAreaLinks() const
Definition: documen8.cxx:1034
void LimitChartArea(SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow, SCCOL &rEndCol, SCROW &rEndRow)
Definition: document.cxx:1107
ScMarkData maPreviewSelection
Definition: document.hxx:429
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:666
bool IsForcedFormulaPending() const
Definition: document.hxx:1364
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:2101
SC_DLLPUBLIC void SetViewOptions(const ScViewOptions &rOpt)
Definition: documen3.cxx:1959
ScSheetLimits & GetSheetLimits() const
Definition: document.hxx:872
bool HasRangeOverflow() const
Definition: document.hxx:2136
void RemoveEditTextCharAttribs(const ScAddress &rPos, const ScPatternAttr &rAttr)
Definition: document.cxx:3670
void GetUnprotectedCells(ScRangeList &rRange, SCTAB nTab) const
Definition: document.cxx:6823
bool IsFunctionAccess() const
Definition: document.hxx:1535
bool InsertRow(SCCOL nStartCol, SCTAB nStartTab, SCCOL nEndCol, SCTAB nEndTab, SCROW nStartRow, SCSIZE nSize, ScDocument *pRefUndoDoc=nullptr, const ScMarkData *pTabMark=nullptr)
Definition: document.cxx:1240
bool GetDdeLinkMode(size_t nDdePos, sal_uInt8 &rnMode) const
Returns the link mode of the specified DDE link.
Definition: documen8.cxx:977
SC_DLLPUBLIC void CreateValidTabName(OUString &rName) const
Definition: document.cxx:391
ScFormulaParserPool & GetFormulaParserPool() const
Returns the pool containing external formula parsers.
Definition: documen3.cxx:652
void DeleteBeforeCopyFromClip(sc::CopyFromClipContext &rCxt, const ScMarkData &rMark, sc::ColumnSpanSet &rBroadcastSpans)
Definition: document10.cxx:56
SC_DLLPUBLIC SfxItemPool * GetEnginePool() const
Definition: documen2.cxx:451
SC_DLLPUBLIC void ApplyPattern(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScPatternAttr &rAttr)
Definition: document.cxx:4813
ScRange aEmbedRange
Definition: document.hxx:434
SC_DLLPUBLIC sal_uLong TransferTab(ScDocument &rSrcDoc, SCTAB nSrcPos, SCTAB nDestPos, bool bInsertNew=true, bool bResultsOnly=false)
Definition: documen2.cxx:908
OUString GetAutoFillPreview(const ScRange &rSource, SCCOL nEndX, SCROW nEndY)
Definition: documen3.cxx:1176
sal_uInt16 GetMacroInterpretLevel() const
Definition: document.hxx:2331
SC_DLLPUBLIC void UnlockAdjustHeight()
Definition: document.cxx:1807
SC_DLLPUBLIC SCCOL ClampToAllocatedColumns(SCTAB nTab, SCCOL nCol) const
Definition: documen3.cxx:2140
::boost::intrusive_ptr< FormulaToken > FormulaTokenRef
bool IsInInterpreterTableOp() const
Definition: document.hxx:2344
bool RenamePageStyleInUse(std::u16string_view rOld, const OUString &rNew)
Definition: documen8.cxx:340
void SetLinkFormulaNeedingCheck(bool bSet)
Definition: document.hxx:2131
void EndListeningCell(const ScAddress &rAddress, SvtListener *pListener)
Definition: documen7.cxx:217
void SharePooledResources(const ScDocument *pSrcDoc)
Definition: document10.cxx:326
void MarkScenario(SCTAB nSrcTab, SCTAB nDestTab, ScMarkData &rDestMark, bool bResetMark=true, ScScenarioFlags nNeededBits=ScScenarioFlags::NONE) const
Definition: documen3.cxx:852
bool HasManualBreaks(SCTAB nTab) const
Definition: document.cxx:6278
Structure that stores segments of boolean flags per column, and perform custom action on those segmen...
bool IsDetectiveDirty() const
Definition: document.hxx:2127
exports i18n
ScDPObject * GetDPAtBlock(const ScRange &rBlock) const
Definition: documen3.cxx:391
void SetLink(SCTAB nTab, ScLinkMode nMode, const OUString &rDoc, const OUString &rFilter, const OUString &rOptions, const OUString &rTabName, sal_uLong nRefreshDelay)
Definition: documen3.cxx:546
bool IsCutMode()
Definition: document.cxx:2057
SC_DLLPUBLIC void SetRowHeight(SCROW nRow, SCTAB nTab, sal_uInt16 nNewHeight)
Definition: document.cxx:4145
void SetNote(const ScAddress &rPos, std::unique_ptr< ScPostIt > pNote)
Definition: document.cxx:6568
bool mbEmbedFontScriptAsian
Definition: document.hxx:556
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:172
bool ShrinkToDataArea(SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow, SCCOL &rEndCol, SCROW &rEndRow) const
Shrink a range to only include data area.
Definition: document.cxx:1031
SC_DLLPUBLIC ScDocument(ScDocumentMode eMode=SCDOCMODE_DOCUMENT, SfxObjectShell *pDocShell=nullptr)
Definition: documen2.cxx:104
HardRecalcState GetHardRecalcState() const
Definition: document.hxx:2307
bool GetDataAreaSubrange(ScRange &rRange) const
Returns true if there is a non-empty subrange in the range given as input.
Definition: document.cxx:1095
SC_DLLPUBLIC void ApplyPatternAreaTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, const ScPatternAttr &rAttr)
Definition: document.cxx:4836
SdrObject * GetObjectAtPoint(SCTAB nTab, const Point &rPos)
Definition: documen9.cxx:399
void TrackFormulas(SfxHintId nHintId=SfxHintId::ScDataChanged)
Definition: documen7.cxx:527
SC_DLLPUBLIC OUString GetPageStyle(SCTAB nTab) const
Definition: document.cxx:6231
BroadcastAreaSlots and their management, once per document.
Definition: bcaslot.hxx:245
SC_DLLPUBLIC void SetRowHeightRange(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, sal_uInt16 nNewHeight)
Definition: document.cxx:4151
void CreateColumnIfNotExists(SCTAB nTab, SCCOL nCol)
Definition: document10.cxx:975
void DecXMLImportedFormulaCount(sal_uLong nVal)
Definition: document.hxx:2370
SC_DLLPUBLIC SCROW GetFirstEditTextRow(const ScRange &rRange) const
Definition: document.cxx:3472
Instantiate this to ensure that subsequent modification of the document will cause an assertion failu...
Definition: document.hxx:2627
void BroadcastUno(const SfxHint &rHint)
Definition: documen3.cxx:949
const T * GetEffItem(SCCOL nCol, SCROW nRow, SCTAB nTab, TypedWhichId< T > nWhich) const
Definition: document.hxx:1751
OUString GetLinkFlt(SCTAB nTab) const
Definition: documen3.cxx:518
void SetSubTotalCellsDirty(const ScRange &rDirtyRange)
Definition: document.cxx:6469
void RemoveSubTotalCell(ScFormulaCell *pCell)
Definition: document.cxx:6448
SC_DLLPUBLIC const EditTextObject * GetEditText(const ScAddress &rPos) const
Definition: document.cxx:3661
bool IsInExternalReferenceMarking() const
Definition: documen3.cxx:632
void SaveDdeLinks(SvStream &rStream) const
Definition: documen8.cxx:709
formula::FormulaGrammar::Grammar GetStorageGrammar() const
Definition: document.hxx:2446
sal_uLong nFormulaCodeInTree
Definition: document.hxx:457
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:1988
bool IsBlockEmpty(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool bIgnoreNotes=false) const
Definition: document.cxx:5341
void IncInterpreterTableOpLevel()
Definition: document.hxx:2345
void DeleteObjectsInArea(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, bool bAnchored=false)
Definition: documen9.cxx:252
sal_uInt16 GetCommonWidth(SCCOL nEndCol, SCTAB nTab) const
Definition: document.cxx:4195
void ResetChanged(const ScRange &rRange)
Definition: document.cxx:4121
SCROW GetRowForHeight(SCTAB nTab, sal_uLong nHeight) const
Given the height i.e.
Definition: document.cxx:4243
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:598
std::set< ScTypedStrData, ScTypedStrData::LessCaseSensitive > ScTypedCaseStrSet
Definition: document.hxx:259
void SetLoadingMedium(bool bVal)
Definition: documen9.cxx:580
void GetSearchAndReplaceStart(const SvxSearchItem &rSearchItem, SCCOL &rCol, SCROW &rRow)
Definition: documen3.cxx:1214
SC_DLLPUBLIC void DoMerge(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool bDeleteCaptions=true)
Definition: documen3.cxx:2068
SC_DLLPUBLIC void AddPrintRange(SCTAB nTab, const ScRange &rNew)
Adds a new print ranges.
Definition: document.cxx:6354
bool CompileErrorCells(FormulaError nErrCode)
Re-compile formula cells with error.
Definition: document.cxx:4060
Definition: document.hxx:252
std::unique_ptr< ScScriptTypeData > pScriptTypeData
Definition: document.hxx:395
Definition: document.hxx:862
void RemoveManualBreaks(SCTAB nTab)
Definition: document.cxx:6272
SC_DLLPUBLIC bool HasValueData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3815
SC_DLLPUBLIC ScPostIt * CreateNote(const ScAddress &rPos)
Definition: document.cxx:6651
bool HasSelectedBlockMatrixFragment(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, const ScMarkData &rMark) const
Definition: document.cxx:5452
std::unique_ptr< sc::DocumentLinkManager > mpDocLinkMgr
Definition: document.hxx:357
SC_DLLPUBLIC const SfxItemSet * GetCondResult(SCCOL nCol, SCROW nRow, SCTAB nTab, ScRefCellValue *pCell=nullptr) const
Definition: documen4.cxx:789
bool HasLinkFormulaNeedingCheck() const
Definition: document.hxx:2130
void GetNumberFormatInfo(const ScInterpreterContext &rContext, SvNumFormatType &nType, sal_uInt32 &nIndex, const ScAddress &rPos) const
Definition: document.cxx:3749
bool CanInsertCol(const ScRange &rRange) const
Definition: document.cxx:1470
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:2563
std::unique_ptr< ScNoteEditEngine > mpNoteEngine
Definition: document.hxx:366
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:391
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:6154
bool CanInsertRow(const ScRange &rRange) const
Definition: document.cxx:1184
void CheckVectorizationState()
Definition: document.cxx:3871
SC_DLLPUBLIC bool ExtendMerge(SCCOL nStartCol, SCROW nStartRow, SCCOL &rEndCol, SCROW &rEndRow, SCTAB nTab, bool bRefresh=false)
Definition: document.cxx:5613
SC_DLLPUBLIC bool HasNote(const ScAddress &rPos) const
Definition: document.cxx:6578
void CompileDBFormula()
Definition: documen4.cxx:557
void ForgetNoteCaptions(const ScRangeList &rRanges, bool bPreserveData)
Definition: document.cxx:6676
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:589
bool ValidAddress(const ScAddress &rAddress) const
Definition: document.hxx:878
ScAutoNameCache * GetAutoNameCache()
Definition: document.hxx:1336
void UpdateRefAreaLinks(UpdateRefMode eUpdateRefMode, const ScRange &r, SCCOL nDx, SCROW nDy, SCTAB nDz)
Definition: documen8.cxx:1083
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:254
css::uno::Reference< css::script::vba::XVBAEventProcessor > mxVbaEvents
Definition: document.hxx:440
bool HasFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4557
bool mbExecuteLinkEnabled
Definition: document.hxx:543
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:1617
void BroadcastCells(const ScRange &rRange, SfxHintId nHint, bool bBroadcastSingleBroadcasters=true)
Definition: documen7.cxx:143
bool bCalculatingFormulaTree
Definition: document.hxx:488
SC_DLLPUBLIC bool HasStringData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3806
SC_DLLPUBLIC void SetRepeatRowRange(SCTAB nTab, std::unique_ptr< ScRange > pNew)
Definition: document.cxx:6372
SC_DLLPUBLIC void EnsureTable(SCTAB nTab)
Definition: documen2.cxx:539
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:1603
void SetCalcNotification(SCTAB nTab)
Definition: documen3.cxx:721
ScDocument & mrDoc
Definition: document.hxx:2686
SC_DLLPUBLIC void SetColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual)
Definition: document.cxx:4447
SC_DLLPUBLIC ScMacroManager * GetMacroManager()
Definition: documen8.cxx:377
FormulaError GetErrCode(const ScAddress &) const
Definition: document.cxx:4113
bool bInLinkUpdate
Definition: document.hxx:505
SC_DLLPUBLIC const ScViewOptions & GetViewOptions() const
Definition: documen3.cxx:1953
Definition: document.hxx:478
Represents the type of sheet geometry data.
Definition: document.hxx:266
void RemoveSubTotals(SCTAB nTab, ScSubTotalParam &rParam)
Definition: documen3.cxx:771
void AddUnoObject(SfxListener &rObject)
Definition: documen3.cxx:898
std::unique_ptr< ScUnoRefList > pUnoRefUndoList
Definition: document.hxx:393
std::unique_ptr< SvMemoryStream > pClipData
Definition: document.hxx:388
bool bIsVisible
Definition: document.hxx:492
SC_DLLPUBLIC void CalcAfterLoad(bool bStartListening=true)
Definition: document.cxx:4076
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:2654
void SetRangeOverflowType(ErrCode nType)
Definition: document.hxx:2135
bool IsEditActionAllowed(sc::ColRowEditAction eAction, SCTAB nTab, SCCOLROW nStart, SCCOLROW nEnd) const
Definition: document10.cxx:949
Configuration options for formula interpreter.
Definition: calcconfig.hxx:43
bool IsDelayedFormulaGrouping() const
Definition: document.hxx:1370
bool IsCalculatingFormulaTree() const
Definition: document.hxx:1366
Definition: global.hxx:148
void GetUpperCellString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rStr)
Definition: documen3.cxx:1471
SCROW SanitizeRow(SCROW nRow) const
Definition: document.hxx:880
SC_DLLPUBLIC void DoEmptyBlock(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow)
Definition: documen3.cxx:2055
SC_DLLPUBLIC ScLkUpdMode GetLinkMode() const
Definition: document.hxx:2177
SC_DLLPUBLIC void GetScenarioData(SCTAB nTab, OUString &rComment, Color &rColor, ScScenarioFlags &rFlags) const
Definition: documen3.cxx:468
void LockTable(SCTAB nTab)
Definition: document.cxx:5352
bool IdleCalcTextWidth()
Definition: documen8.cxx:532
SC_DLLPUBLIC double RoundValueAsShown(double fVal, sal_uInt32 nFormat, const ScInterpreterContext *pContext=nullptr) const
Definition: documen4.cxx:634
void CreateAllNoteCaptions()
Ensure that all note objects have an associated sdr object.
Definition: document.cxx:6667
SCROW CopyNonFilteredFromClip(sc::CopyFromClipContext &rCxt, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, SCCOL nDx, SCROW &rClipStartRow, SCROW nClipEndRow)
Definition: document.cxx:2757
void finalizeOutlineImport()
Definition: document10.cxx:568
void InvalidateTextWidth(std::u16string_view rStyleName)
Definition: documen8.cxx:295
void SetDetOpList(std::unique_ptr< ScDetOpList > pNew)
Definition: documen4.cxx:904
bool ValidColRow(SCCOL nCol, SCROW nRow) const
Definition: document.hxx:875
void SyncColRowFlags()
Write all column row flags to table's flag data, because not all column row attributes are stored in ...
Definition: document.cxx:4613
bool IsStyleSheetUsed(const ScStyleSheet &rStyle) const
Definition: document.cxx:5025
static thread_local ScDocumentThreadSpecific maThreadSpecific
Definition: document.hxx:467
void FindMaxRotCol(SCTAB nTab, RowInfo *pRowInfo, SCSIZE nArrCount, SCCOL nX1, SCCOL nX2) const
Definition: document.cxx:5281
bool IsInDtorClear() const
Definition: document.hxx:2360
o3tl::sorted_vector< sal_uInt32 > ScCondFormatIndexes
Definition: document.hxx:201
void SetNumberFormat(const ScAddress &rPos, sal_uInt32 nNumberFormat)
Definition: document.cxx:3739
SC_DLLPUBLIC void SetPageStyle(SCTAB nTab, const OUString &rName)
Definition: document.cxx:6225
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:984
Definition: global.hxx:309
SC_DLLPUBLIC Color GetTabBgColor(SCTAB nTab) const
Definition: documen3.cxx:448