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 <optional>
51 #include <set>
52 #include <unordered_map>
53 #include <vector>
55 #include "markdata.hxx"
56 #include "drwlayer.hxx"
58 namespace com::sun::star::chart2 { class XChartDocument; }
60 class Timer;
62 enum class SvtScriptType;
63 enum class ScMF;
64 enum class FormulaError : sal_uInt16;
65 enum class CharCompressType;
66 enum class EEHorizontalTextDirection;
67 namespace editeng { class SvxBorderLine; }
68 namespace formula { struct VectorRefArray; }
69 namespace svl {
71 class SharedString;
72 class SharedStringPool;
74 }
76 namespace sc {
78 struct FormulaGroupContext;
79 class StartListeningContext;
80 class EndListeningContext;
81 class CopyFromClipContext;
82 class ColumnSpanSet;
83 class RangeColumnSpanSet;
84 struct ColumnBlockPosition;
85 struct RefUpdateContext;
86 class EditTextIterator;
87 struct NoteEntry;
88 class DocumentStreamAccess;
89 class DocumentLinkManager;
90 class CellValues;
91 class TableValues;
92 class RowHeightContext;
93 struct SetFormulaDirtyContext;
94 class RefMovedHint;
95 struct ReorderParam;
96 class FormulaGroupAreaListener;
97 class ColumnSet;
98 class UpdatedRangeNames;
99 class TableColumnBlockPositionSet;
100 class ColumnIterator;
101 class ExternalDataMapper;
103 }
105 class Fraction;
107 class OutputDevice;
108 class SdrObject;
109 class SfxBroadcaster;
110 class SfxListener;
111 class SfxItemSet;
112 class SfxObjectShell;
113 class SfxBindings;
114 class SfxPoolItem;
115 class SfxItemPool;
116 class SfxPrinter;
117 class SfxStyleSheetBase;
118 class SvMemoryStream;
119 class SvxBoxInfoItem;
120 class SvxBoxItem;
122 namespace sfx2 {
123  class LinkManager;
124  }
125 class SvxSearchItem;
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;
204 struct ScDataAreaExtras;
206 namespace sc {
208 typedef std::map<OUString, BitmapEx> IconSetBitmapMap;
210 }
212 namespace com::sun::star {
213  namespace lang {
214  struct EventObject;
215  }
216  namespace i18n {
217  class XBreakIterator;
218  }
219  namespace util {
220  class XModifyListener;
221  }
222  namespace embed {
223  class XEmbeddedObject;
224  }
225  namespace script::vba {
226  class XVBAEventProcessor;
227  }
228  namespace sheet {
229  struct TablePageBreakData;
230  }
231 }
233 namespace weld {
235 class Window;
237 }
239 #define SC_DOC_NEW 0xFFFF
246 {
251 };
254 {
255  ALLSHOWN, // All comments captions are shown
256  ALLHIDDEN, // All comments captions are hidden
257  MIXED // There are comments in shown and hidden.
258 };
261 {
262  GLOBAL, // A range name can be defined
263  SHEET // with two scope on Manage Names dialog.
264 };
267 enum class SheetGeomType
268 {
269  SIZES, // Column widths or row heights.
270  HIDDEN, // Hidden columns/rows.
271  FILTERED, // Filtered columns/rows.
272  GROUPS // Grouping of columns/rows.
273 };
275 struct ScDocStat
276 {
277  OUString aDocName;
281  sal_uInt16 nPageCount;
283  : nTableCount(0)
284  , nCellCount(0)
285  , nFormulaCount(0)
286  , nPageCount(0)
287  {
288  }
289 };
291 // DDE link modes
297 // During threaded calculation fields being mutated are kept in this struct
299 {
300  std::unique_ptr<ScRecursionHelper> xRecursionHelper; // information for recursive and iterative cell formulas
301  ScInterpreterContext* pContext = nullptr; // references the context passed around for easier access
302 };
306 {
307  // Bit mask bits
308  CORE = 0x0001,
309 };
311 typedef std::unique_ptr<ScTable, o3tl::default_delete<ScTable>> ScTableUniquePtr;
314 {
315 friend class ScValueIterator;
319 friend class ScCellIterator;
320 friend class ScQueryCellIterator;
324 friend class ScDocAttrIterator;
326 friend class ScAttrRectIterator;
327 friend class ScDocShell;
330 friend class ScFormulaCell;
331 friend class ScTable;
332 friend class ScColumn;
333 friend struct ScRefCellValue;
334 friend class ScDocumentImport;
336 friend class sc::ColumnSpanSet;
338 friend class sc::EditTextIterator;
341 friend struct ScMutationGuard;
342 friend struct ScMutationDisable;
344  typedef std::vector<ScTableUniquePtr> TableContainer;
346 public:
347  enum class HardRecalcState
348  {
349  OFF,
352  };
354 private:
357  std::shared_ptr<svl::SharedStringPool> mpCellStringPool;
358  std::unique_ptr<sc::DocumentLinkManager> mpDocLinkMgr;
360  std::shared_ptr<sc::FormulaGroupContext> mpFormulaGroupCxt;
366  std::unique_ptr<ScFieldEditEngine> mpEditEngine; // uses pEditPool from xPoolHelper
367  std::unique_ptr<ScNoteEditEngine> mpNoteEngine; // uses pEditPool from xPoolHelper
371  std::unique_ptr<ScDrawLayer> mpDrawLayer; // SdrModel
373  std::unique_ptr<ScValidationDataList> pValidationList; // validity
374  SvNumberFormatterIndexTable* pFormatExchangeList; // for application of number formats
375  TableContainer maTabs;
377  std::vector<OUString> maTabNames; // for undo document, we need the information tab name <-> index
378  mutable std::unique_ptr<ScRangeName> pRangeName;
379  std::unique_ptr<ScDBCollection> pDBCollection;
380  std::unique_ptr<ScDPCollection> pDPCollection;
381  std::unique_ptr< ScTemporaryChartLock > apTemporaryChartLock;
382  std::unique_ptr<ScPatternAttr> pSelectionAttr; // Attributes of a block
383  ScFormulaCell* pFormulaTree; // formula tree (start)
384  ScFormulaCell* pEOFormulaTree; // formula tree (end), last cell
385  ScFormulaCell* pFormulaTrack; // BroadcastTrack (start)
386  ScFormulaCell* pEOFormulaTrack; // BroadcastTrack (end), last cell
387  std::unique_ptr<ScBroadcastAreaSlotMachine> pBASM; // BroadcastAreas
388  std::unique_ptr<ScChartListenerCollection> pChartListenerCollection;
389  std::unique_ptr<SvMemoryStream> pClipData;
390  std::unique_ptr<ScDetOpList> pDetOpList;
391  std::unique_ptr<ScChangeTrack> pChangeTrack;
392  std::unique_ptr<SfxBroadcaster> pUnoBroadcaster;
393  std::unique_ptr<ScUnoListenerCalls> pUnoListenerCalls;
394  std::unique_ptr<ScUnoRefList> pUnoRefUndoList;
395  std::unique_ptr<ScChangeViewSettings> pChangeViewSettings;
396  std::unique_ptr<ScScriptTypeData> pScriptTypeData;
397  std::unique_ptr<ScRefreshTimerControl> pRefreshTimerControl;
398  std::shared_ptr<SvxForbiddenCharactersTable> xForbiddenCharacters;
399  std::unique_ptr<ScDBData> mpAnonymousDBData;
400  std::unique_ptr<sc::ExternalDataMapper> mpDataMapper;
402  std::unique_ptr<ScFieldEditEngine> pCacheFieldEditEngine;
404  std::unique_ptr<ScDocProtection> pDocProtection;
405  std::unique_ptr<ScClipParam> mpClipParam;
407  std::unique_ptr<ScExternalRefManager> pExternalRefMgr;
408  std::unique_ptr<ScMacroManager> mpMacroMgr;
410  // mutable for lazy construction
411  mutable std::unique_ptr< ScFormulaParserPool >
414  OUString aDocName; // optional: name of document
415  OUString aDocCodeName; // optional: name of document (twice?)
416  OUString maFileURL; // file URL for copy & paste
420  std::unique_ptr<ScViewOptions> pViewOptions; // view options
421  std::unique_ptr<ScDocOptions> pDocOptions; // document options
422  std::unique_ptr<ScExtDocOptions> pExtDocOptions; // for import etc.
423  std::unique_ptr<ScClipOptions> mpClipOptions; // clipboard options
424  std::unique_ptr<ScConsolidateParam> pConsolidateDlgData;
426  std::unique_ptr<ScAutoNameCache> pAutoNameCache; // for automatic name lookup during CompileXML
428  std::unique_ptr<SfxItemSet> pPreviewFont; // convert to std::unique_ptr or whatever
431  sal_Int64 nUnoObjectId; // counted up for UNO objects
433  ErrCode nRangeOverflowType; // used in (xml) loading for overflow warnings
440  css::uno::Reference< css::script::vba::XVBAEventProcessor >
442 public:
444  std::vector<ScInterpreterTableOpParams*> m_TableOpList;
447 private:
449  LanguageType eLanguage; // default language
450  LanguageType eCjkLanguage; // default language for asian text
451  LanguageType eCtlLanguage; // default language for complex text
452  rtl_TextEncoding eSrcSet; // during reading: source character set
458  sal_uLong nFormulaCodeInTree; // formula RPN in the formula tree
459  sal_uLong nXMLImportedFormulaCount; // progress count during XML import
460  sal_uInt16 nInterpretLevel; // >0 if in interpreter
461  sal_uInt16 nMacroInterpretLevel; // >0 if macro in interpreter
462  sal_uInt16 nInterpreterTableOpLevel; // >0 if in interpreter TableOp
466  // There can be only one ScDocument being calculated in a thread at a time, so we can use a
467  // plain thread_local static member.
472  osl::Mutex mScLookupMutex; // protection for thread-unsafe parts of handling ScLookup
474  static const sal_uInt16 nSrcVer; // file version (load/save)
475  sal_uInt16 nFormulaTrackCount;
476  HardRecalcState eHardRecalcState; // off, temporary, eternal
477  SCTAB nVisibleTab; // for OLE etc., don't use inside ScDocument
478  SCCOL nPosLeft; // for OLE etc., don't use inside ScDocument
479  SCROW nPosTop; // for OLE etc., don't use inside ScDocument
483  bool bAutoCalc; // calculate automatically
484  bool bAutoCalcShellDisabled; // in/from/for ScDocShell disabled
485  // are there ForcedFormulas which have to be calculated
486  // in interaction with ScDocShell SetDocumentModified,
487  // AutoCalcShellDisabled and TrackFormulas
490  bool bIsClip;
491  bool bIsUndo;
493  bool bIsVisible; // set from view ctor
495  bool bIsEmbedded; // display/adjust Embedded area?
497  // no broadcast, construct no listener during insert from a different
498  // Doc (per filter or the like ), not until CompileAll / CalcAfterLoad
501  bool bImportingXML; // special handling of formula text
502  bool bCalcingAfterLoad; // in CalcAfterLoad TRUE
503  // don't construct/destruct listeners temporarily
506  bool bInLinkUpdate; // TableLink or AreaLink
508  // are/were there RC_FORCED formula cells in the document (if set once to TRUE then set forever)
510  // is the Doc being destroyed? (no Notify-Tracking etc. needed anymore)
512  // expand reference if insert column/row takes place at the border
513  // of a reference
514  // is fetched in each UpdateReference from InputOptions,
515  // assigned, and restored at the end of UpdateReference
517  // for detective update, is set for each change of a formula
519  // If the pointer is set, formula cells will not be automatically grouped into shared formula groups,
520  // instead the range will be extended to contain all such cells.
521  std::unique_ptr< ScRange > pDelayedFormulaGrouping;
522  // If non-empty, ScColumn::StartListeningFormulaCells() calls may be delayed using this,
523  // avoiding repeated calling for the same cells in the given range. The function will be called once
524  // later for all the cells in the range.
525  std::unordered_map< ScColumn*, std::pair<SCROW, SCROW>> pDelayedStartListeningFormulaCells;
527  bool bLinkFormulaNeedingCheck; // valid only after loading, for ocDde and ocWebservice
534  sal_uInt8 nInDdeLinkUpdate; // originating DDE links (stacked bool)
538  sal_uInt32 nAdjustHeightLock;
545  bool mbChangeReadOnlyEnabled:1; // allow changes in read-only document (for API import filters)
547  bool mbUserInteractionEnabled:1; // whether or not to launch any kind of interactive dialogs.
551  std::set<ScFormulaCell*> maSubTotalCells;
554  bool mbEmbedFonts : 1;
560  std::unique_ptr<sc::IconSetBitmapMap> m_pIconSetBitmapMap;
564  // This indicates if a ScDocShell::DoRecalc() or ScDocShell::DoHardRecalc() is in progress.
569 public:
570  bool IsCellInChangeTrack(const ScAddress &cell,Color *pColCellBorder);
571  void GetCellChangeTrackNote(const ScAddress &cell, OUString &strTrackText, bool &pbLeftEdge);
573  bool IsEmbedFonts() const { return mbEmbedFonts; }
579  void SetEmbedFonts(bool bUse) { mbEmbedFonts = bUse; }
580  void SetEmbedUsedFontsOnly(bool bUse) { mbEmbedUsedFontsOnly = bUse; }
585  SC_DLLPUBLIC sal_uLong GetCellCount() const; // all cells
586  SC_DLLPUBLIC sal_uLong GetFormulaGroupCount() const; // all cells
587  sal_uLong GetCodeCount() const; // RPN-Code in formulas
588  DECL_LINK( GetUserDefinedColor, sal_uInt16, Color* );
589  // number formatter
590 public:
592  SfxObjectShell* pDocShell = nullptr );
595  void SetName( const OUString& r ) { aDocName = r; }
596  const OUString& GetCodeName() const { return aDocCodeName; }
597  void SetCodeName( const OUString& r ) { aDocCodeName = r; }
598  const OUString& GetFileURL() const { return maFileURL; }
600  void GetDocStat( ScDocStat& rDocStat );
602  SC_DLLPUBLIC void InitDrawLayer( SfxObjectShell* pDocShell = nullptr );
605  {
607  return maInterpreterContext;
608  }
609  // Uses thread_local.
611  {
612  return IsThreadedGroupCalcInProgress() ? *maThreadSpecific.pContext : GetNonThreadedContext();
613  }
614  void SetupContextFromNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber );
615  void MergeContextBackIntoNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber );
625  SC_DLLPUBLIC const ScDocOptions& GetDocOptions() const;
626  SC_DLLPUBLIC void SetDocOptions( const ScDocOptions& rOpt );
628  SC_DLLPUBLIC void SetViewOptions( const ScViewOptions& rOpt );
629  void SetPrintOptions();
631  ScExtDocOptions* GetExtDocOptions() { return pExtDocOptions.get(); }
632  SC_DLLPUBLIC void SetExtDocOptions( std::unique_ptr<ScExtDocOptions> pNewOptions );
634  ScClipOptions* GetClipOptions() { return mpClipOptions.get(); }
635  void SetClipOptions(std::unique_ptr<ScClipOptions> pClipOptions);
637  SC_DLLPUBLIC void GetLanguage( LanguageType& rLatin, LanguageType& rCjk, LanguageType& rCtl ) const;
638  void SetLanguage( LanguageType eLatin, LanguageType eCjk, LanguageType eCtl );
640  void SetConsolidateDlgData( std::unique_ptr<ScConsolidateParam> pData );
641  const ScConsolidateParam* GetConsolidateDlgData() const { return pConsolidateDlgData.get(); }
643  void Clear( bool bFromDestructor = false );
645  std::unique_ptr<ScFieldEditEngine> CreateFieldEditEngine();
646  void DisposeFieldEditEngine(std::unique_ptr<ScFieldEditEngine>& rpEditEngine);
653  SC_DLLPUBLIC void SetAllRangeNames(const std::map<OUString, std::unique_ptr<ScRangeName>>& rRangeMap);
654  SC_DLLPUBLIC void GetRangeNameMap(std::map<OUString, ScRangeName*>& rRangeName);
657  void SetRangeName(SCTAB nTab, std::unique_ptr<ScRangeName> pNew);
658  void SetRangeName( std::unique_ptr<ScRangeName> pNewRangeName );
659  bool IsAddressInRangeName( RangeNameScope eScope, const ScAddress& rAddress);
668  ScRangeData* FindRangeNameBySheetAndIndex( SCTAB nTab, sal_uInt16 nIndex ) const;
714  SCTAB nTokenTab, const sal_uInt16 nTokenIndex,
715  SCTAB nGlobalRefTab, SCTAB nLocalRefTab, SCTAB nOldTokenTab, SCTAB nOldTokenTabReplacement,
716  bool bSameDoc, int nRecursion ) const;
758  bool CopyAdjustRangeName( SCTAB& rSheet, sal_uInt16& rIndex, ScRangeData*& rpRangeData, ScDocument& rNewDoc,
759  const ScAddress& rNewPos, const ScAddress& rOldPos, const bool bGlobalNamesToLocal,
760  const bool bUsedByFormula ) const;
765  SC_DLLPUBLIC void PreprocessAllRangeNamesUpdate( const std::map<OUString, std::unique_ptr<ScRangeName>>& rRangeMap );
783  bool InsertNewRangeName( const OUString& rName, const ScAddress& rPos, const OUString& rExpr );
796  bool InsertNewRangeName( SCTAB nTab, const OUString& rName, const ScAddress& rPos, const OUString& rExpr );
804  SCTAB GetMaxTableNumber() const { return static_cast<SCTAB>(maTabs.size()) - 1; }
806  ScRangePairList* GetColNameRanges() { return xColNameRanges.get(); }
807  ScRangePairList* GetRowNameRanges() { return xRowNameRanges.get(); }
814  SC_DLLPUBLIC ScDBCollection* GetDBCollection() const { return pDBCollection.get();}
815  void SetDBCollection( std::unique_ptr<ScDBCollection> pNewDBCollection,
816  bool bRemoveAutoFilter = false );
817  const ScDBData* GetDBAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab, ScDBDataPortion ePortion) const;
818  ScDBData* GetDBAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab, ScDBDataPortion ePortion);
819  SC_DLLPUBLIC const ScDBData* GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2) const;
820  SC_DLLPUBLIC ScDBData* GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2);
824  SC_DLLPUBLIC const ScRangeData* GetRangeAtBlock( const ScRange& rBlock, OUString& rName,
825  bool* pSheetLocal = nullptr ) const;
827  SC_DLLPUBLIC bool HasPivotTable() const;
830  SC_DLLPUBLIC ScDPObject* GetDPAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab) const;
831  ScDPObject* GetDPAtBlock( const ScRange& rBlock ) const;
833  void StopTemporaryChartLock();
835  void EnsureGraphicNames();
837  SdrObject* GetObjectAtPoint( SCTAB nTab, const Point& rPos );
838  bool HasChartAtPoint( SCTAB nTab, const Point& rPos, OUString& rName );
840  css::uno::Reference< css::chart2::XChartDocument > GetChartByName( std::u16string_view rChartName );
842  SC_DLLPUBLIC void GetChartRanges( std::u16string_view rChartName, std::vector< ScRangeList >& rRanges, const ScDocument& rSheetNameDoc );
843  void SetChartRanges( std::u16string_view rChartName, const std::vector< ScRangeList >& rRanges );
845  void UpdateChartArea( const OUString& rChartName, const ScRange& rNewArea,
846  bool bColHeaders, bool bRowHeaders, bool bAdd );
847  void UpdateChartArea( const OUString& rChartName,
848  const ScRangeListRef& rNewList,
849  bool bColHeaders, bool bRowHeaders, bool bAdd );
850  void GetOldChartParameters( std::u16string_view rName,
851  ScRangeList& rRanges, bool& rColHeaders, bool& rRowHeaders );
852  css::uno::Reference<
853  css::embed::XEmbeddedObject >
854  FindOleObjectByName( std::u16string_view rName );
856  SC_DLLPUBLIC void MakeTable( SCTAB nTab,bool _bNeedsNameCheck = true );
858  SCTAB GetVisibleTab() const { return nVisibleTab; }
859  SC_DLLPUBLIC void SetVisibleTab(SCTAB nTab) { nVisibleTab = nTab; }
860  SCCOL GetPosLeft() const { return nPosLeft; }
861  SC_DLLPUBLIC void SetPosLeft(SCCOL nCol) { nPosLeft = nCol; }
862  SCROW GetPosTop() const { return nPosTop; }
863  SC_DLLPUBLIC void SetPosTop(SCROW nRow) { nPosTop = nRow; }
865  SC_DLLPUBLIC bool HasTable( SCTAB nTab ) const;
866  SC_DLLPUBLIC bool GetHashCode( SCTAB nTab, sal_Int64& rHashCode) const;
867  SC_DLLPUBLIC bool GetName( SCTAB nTab, OUString& rName ) const;
868  SC_DLLPUBLIC bool GetCodeName( SCTAB nTab, OUString& rName ) const;
869  SC_DLLPUBLIC bool SetCodeName( SCTAB nTab, const OUString& rName );
870  SC_DLLPUBLIC bool GetTable( const OUString& rName, SCTAB& rTab ) const;
871  SC_DLLPUBLIC SCCOL MaxCol() const { return mxSheetLimits->mnMaxCol; }
872  SC_DLLPUBLIC SCROW MaxRow() const { return mxSheetLimits->mnMaxRow; }
874  [[nodiscard]] bool ValidCol(SCCOL nCol) const { return ::ValidCol(nCol, mxSheetLimits->mnMaxCol); }
875  [[nodiscard]] bool ValidRow(SCROW nRow) const { return ::ValidRow(nRow, mxSheetLimits->mnMaxRow); }
876  [[nodiscard]] bool ValidColRow(SCCOL nCol, SCROW nRow) const { return ::ValidColRow(nCol, nRow, MaxCol(), MaxRow()); }
877  [[nodiscard]] bool ValidColRowTab(SCCOL nCol, SCROW nRow, SCTAB nTab) const { return ::ValidColRowTab(nCol, nRow, nTab, MaxCol(), MaxRow()); }
878  [[nodiscard]] bool ValidRange(const ScRange& rRange) const { return ::ValidRange(rRange, MaxCol(), MaxRow()); }
879  [[nodiscard]] bool ValidAddress(const ScAddress& rAddress) const { return ::ValidAddress(rAddress, MaxCol(), MaxRow()); }
880  [[nodiscard]] SCCOL SanitizeCol( SCCOL nCol ) const { return ::SanitizeCol(nCol, MaxCol()); }
881  [[nodiscard]] SCROW SanitizeRow( SCROW nRow ) const { return ::SanitizeRow(nRow, MaxRow()); }
883  SC_DLLPUBLIC std::vector<OUString> GetAllTableNames() const;
885  OUString GetCopyTabName(SCTAB nTab) const;
887  SC_DLLPUBLIC void SetAnonymousDBData(SCTAB nTab, std::unique_ptr<ScDBData> pDBData);
894  SC_DLLPUBLIC void SetAnonymousDBData(std::unique_ptr<ScDBData> pDBData);
901  SC_DLLPUBLIC void SetDocProtection(const ScDocProtection* pProtect);
902  SC_DLLPUBLIC bool IsDocProtected() const;
903  bool IsDocEditable() const;
904  SC_DLLPUBLIC bool IsTabProtected( SCTAB nTab ) const;
906  SC_DLLPUBLIC void SetTabProtection(SCTAB nTab, const ScTableProtection* pProtect);
907  void CopyTabProtection(SCTAB nTabSrc, SCTAB nTabDest);
909  void LockTable(SCTAB nTab);
910  void UnlockTable(SCTAB nTab);
912  bool IsBlockEditable( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
913  SCCOL nEndCol, SCROW nEndRow,
914  bool* pOnlyNotBecauseOfMatrix = nullptr,
915  bool bNoMatrixAtAll = false ) const;
916  bool IsSelectionEditable( const ScMarkData& rMark,
917  bool* pOnlyNotBecauseOfMatrix = nullptr ) const;
918  bool HasSelectedBlockMatrixFragment( SCCOL nStartCol, SCROW nStartRow,
919  SCCOL nEndCol, SCROW nEndRow,
920  const ScMarkData& rMark ) const;
922  bool IsEditActionAllowed( sc::ColRowEditAction eAction, SCTAB nTab, SCCOLROW nStart, SCCOLROW nEnd ) const;
923  bool IsEditActionAllowed( sc::ColRowEditAction eAction, const ScMarkData& rMark, SCCOLROW nStart, SCCOLROW nEnd ) const;
925  SC_DLLPUBLIC bool GetMatrixFormulaRange( const ScAddress& rCellPos, ScRange& rMatrix );
927  bool IsEmbedded() const { return bIsEmbedded;}
928  void GetEmbedded( ScRange& rRange ) const;
929  void SetEmbedded( const ScRange& rRange );
930  void ResetEmbedded();
931  tools::Rectangle GetEmbeddedRect() const; // 1/100 mm
932  void SetEmbedded( SCTAB nTab, const tools::Rectangle& rRect ); // from VisArea (1/100 mm)
934  static SC_DLLPUBLIC bool ValidTabName( const OUString& rName );
936  SC_DLLPUBLIC bool ValidNewTabName( const OUString& rName ) const;
937  SC_DLLPUBLIC void CreateValidTabName(OUString& rName) const;
938  SC_DLLPUBLIC void CreateValidTabNames(std::vector<OUString>& aNames, SCTAB nCount) const;
940  void AppendTabOnLoad(const OUString& rName);
941  void SetTabNameOnLoad(SCTAB nTab, const OUString& rName);
942  void InvalidateStreamOnSave();
944  SC_DLLPUBLIC bool InsertTab( SCTAB nPos, const OUString& rName,
945  bool bExternalDocument = false, bool bUndoDeleteTab = false );
947  SC_DLLPUBLIC bool InsertTabs( SCTAB nPos, const std::vector<OUString>& rNames,
948  bool bNamesValid = false );
949  SC_DLLPUBLIC bool DeleteTabs( SCTAB nTab, SCTAB nSheets );
950  SC_DLLPUBLIC bool DeleteTab( SCTAB nTab );
951  SC_DLLPUBLIC bool RenameTab( SCTAB nTab, const OUString& rName,
952  bool bExternalDocument = false );
953  bool MoveTab( SCTAB nOldPos, SCTAB nNewPos, ScProgress* pProgress = nullptr );
954  bool CopyTab( SCTAB nOldPos, SCTAB nNewPos,
955  const ScMarkData* pOnlyMarked = nullptr );
956  SC_DLLPUBLIC sal_uLong TransferTab(ScDocument& rSrcDoc, SCTAB nSrcPos, SCTAB nDestPos,
957  bool bInsertNew = true,
958  bool bResultsOnly = false );
959  SC_DLLPUBLIC void TransferDrawPage(const ScDocument& rSrcDoc, SCTAB nSrcPos, SCTAB nDestPos);
960  SC_DLLPUBLIC void SetVisible( SCTAB nTab, bool bVisible );
961  SC_DLLPUBLIC bool IsVisible( SCTAB nTab ) const;
962  bool IsStreamValid( SCTAB nTab ) const;
963  void SetStreamValid( SCTAB nTab, bool bSet, bool bIgnoreLock = false );
964  void LockStreamValid( bool bLock );
965  bool IsStreamValidLocked() const { return mbStreamValidLocked; }
966  bool IsPendingRowHeights( SCTAB nTab ) const;
967  void SetPendingRowHeights( SCTAB nTab, bool bSet );
968  SC_DLLPUBLIC void SetLayoutRTL( SCTAB nTab, bool bRTL, ScObjectHandling eObjectHandling = ScObjectHandling::RecalcPosMode);
969  SC_DLLPUBLIC bool IsLayoutRTL( SCTAB nTab ) const;
970  SC_DLLPUBLIC bool IsNegativePage( SCTAB nTab ) const;
971  SC_DLLPUBLIC void SetScenario( SCTAB nTab, bool bFlag );
972  SC_DLLPUBLIC bool IsScenario( SCTAB nTab ) const;
973  SC_DLLPUBLIC void GetScenarioData(SCTAB nTab, OUString& rComment,
974  Color& rColor, ScScenarioFlags &rFlags) const;
975  SC_DLLPUBLIC void SetScenarioData(SCTAB nTab, const OUString& rComment,
976  const Color& rColor, ScScenarioFlags nFlags);
977  SC_DLLPUBLIC Color GetTabBgColor( SCTAB nTab ) const;
978  SC_DLLPUBLIC void SetTabBgColor( SCTAB nTab, const Color& rColor );
979  SC_DLLPUBLIC bool IsDefaultTabBgColor( SCTAB nTab ) const;
980  void GetScenarioFlags(SCTAB nTab, ScScenarioFlags &rFlags) const;
981  SC_DLLPUBLIC bool IsActiveScenario( SCTAB nTab ) const;
982  SC_DLLPUBLIC void SetActiveScenario( SCTAB nTab, bool bActive ); // only for Undo etc.
987  bool IsLinked( SCTAB nTab ) const;
988  SC_DLLPUBLIC OUString GetLinkDoc( SCTAB nTab ) const;
989  OUString GetLinkFlt( SCTAB nTab ) const;
990  OUString GetLinkOpt( SCTAB nTab ) const;
991  SC_DLLPUBLIC OUString GetLinkTab( SCTAB nTab ) const;
992  sal_uLong GetLinkRefreshDelay( SCTAB nTab ) const;
993  void SetLink( SCTAB nTab, ScLinkMode nMode, const OUString& rDoc,
994  const OUString& rFilter, const OUString& rOptions,
995  const OUString& rTabName, sal_uLong nRefreshDelay );
996  bool HasLink( std::u16string_view rDoc,
997  std::u16string_view rFilter, std::u16string_view rOptions ) const;
998  SC_DLLPUBLIC bool LinkExternalTab( SCTAB& nTab, const OUString& aDocTab,
999  const OUString& aFileName,
1000  const OUString& aTabName );
1002  bool HasExternalRefManager() const { return bool(pExternalRefMgr); }
1004  bool IsInExternalReferenceMarking() const;
1006  bool MarkUsedExternalReferences( const ScTokenArray& rArr, const ScAddress& rPos );
1012  bool HasAreaLinks() const;
1014  void UpdateAreaLinks();
1016  // originating DDE links
1017  void IncInDdeLinkUpdate() { if ( nInDdeLinkUpdate < 255 ) ++nInDdeLinkUpdate; }
1018  void DecInDdeLinkUpdate() { if ( nInDdeLinkUpdate ) --nInDdeLinkUpdate; }
1019  bool IsInDdeLinkUpdate() const { return nInDdeLinkUpdate != 0; }
1021  SC_DLLPUBLIC void CopyDdeLinks( ScDocument& rDestDoc ) const;
1026  SC_DLLPUBLIC bool FindDdeLink( std::u16string_view rAppl, std::u16string_view rTopic,
1027  std::u16string_view rItem, sal_uInt8 nMode, size_t& rnDdePos );
1035  bool GetDdeLinkData( size_t nDdePos, OUString& rAppl, OUString& rTopic, OUString& rItem ) const;
1040  bool GetDdeLinkMode( size_t nDdePos, sal_uInt8& rnMode ) const;
1044  SC_DLLPUBLIC const ScMatrix* GetDdeLinkResultMatrix( size_t nDdePos ) const;
1049  SC_DLLPUBLIC bool CreateDdeLink( const OUString& rAppl, const OUString& rTopic, const OUString& rItem, sal_uInt8 nMode, const ScMatrixRef& pResults );
1054  bool SetDdeLinkResultMatrix( size_t nDdePos, const ScMatrixRef& pResults );
1058  SC_DLLPUBLIC ScDrawLayer* GetDrawLayer() { return mpDrawLayer.get(); }
1059  SC_DLLPUBLIC const ScDrawLayer* GetDrawLayer() const { return mpDrawLayer.get(); }
1060  SfxBroadcaster* GetDrawBroadcaster(); // to avoid header
1061  void BeginDrawUndo();
1063  void BeginUnoRefUndo();
1064  bool HasUnoRefUndo() const { return ( pUnoRefUndoList != nullptr ); }
1065  [[nodiscard]]
1066  std::unique_ptr<ScUnoRefList> EndUnoRefUndo(); // must be deleted by caller!
1067  sal_Int64 GetNewUnoId() { return ++nUnoObjectId; }
1068  void AddUnoRefChange( sal_Int64 nId, const ScRangeList& rOldRanges );
1070  static bool IsChart( const SdrObject* pObject );
1072  void UpdateChartRef( UpdateRefMode eUpdateRefMode,
1073  SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1074  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1075  SCCOL nDx, SCROW nDy, SCTAB nDz );
1077  void SetChartRangeList( std::u16string_view rChartName,
1078  const ScRangeListRef& rNewRangeListRef );
1080  void StartAnimations( SCTAB nTab );
1082  bool HasBackgroundDraw( SCTAB nTab, const tools::Rectangle& rMMRect ) const;
1083  bool HasAnyDraw( SCTAB nTab, const tools::Rectangle& rMMRect ) const;
1085  const ScSheetEvents* GetSheetEvents( SCTAB nTab ) const;
1086  void SetSheetEvents( SCTAB nTab, std::unique_ptr<ScSheetEvents> pNew );
1087  bool HasSheetEventScript( SCTAB nTab, ScSheetEventId nEvent, bool bWithVbaEvents = false ) const;
1088  bool HasAnySheetEventScript( ScSheetEventId nEvent, bool bWithVbaEvents = false ) const; // on any sheet
1090  bool HasAnyCalcNotification() const;
1091  bool HasCalcNotification( SCTAB nTab ) const;
1092  void SetCalcNotification( SCTAB nTab );
1093  void ResetCalcNotifications();
1095  SC_DLLPUBLIC ScOutlineTable* GetOutlineTable( SCTAB nTab, bool bCreate = false );
1096  bool SetOutlineTable( SCTAB nTab, const ScOutlineTable* pNewOutline );
1098  void DoAutoOutline( SCCOL nStartCol, SCROW nStartRow,
1099  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab );
1101  bool DoSubTotals( SCTAB nTab, ScSubTotalParam& rParam );
1102  void RemoveSubTotals( SCTAB nTab, ScSubTotalParam& rParam );
1103  bool TestRemoveSubTotals( SCTAB nTab, const ScSubTotalParam& rParam );
1104  bool HasSubTotalCells( const ScRange& rRange );
1106  SC_DLLPUBLIC void EnsureTable( SCTAB nTab );
1108  // return TRUE = number format is set
1109  SC_DLLPUBLIC bool SetString( SCCOL nCol, SCROW nRow, SCTAB nTab, const OUString& rString,
1110  const ScSetStringParam * pParam = nullptr );
1111  SC_DLLPUBLIC bool SetString( const ScAddress& rPos, const OUString& rString,
1112  const ScSetStringParam* pParam = nullptr );
1123  SC_DLLPUBLIC bool SetEditText( const ScAddress& rPos, std::unique_ptr<EditTextObject> pEditText );
1124  void SetEditText( const ScAddress& rPos, const EditTextObject& rEditText, const SfxItemPool* pEditPool );
1125  SC_DLLPUBLIC void SetEditText( const ScAddress& rPos, const OUString& rStr );
1126  SC_DLLPUBLIC SCROW GetFirstEditTextRow( const ScRange& rRange ) const;
1132  SC_DLLPUBLIC void SetTextCell( const ScAddress& rPos, const OUString& rStr );
1133  void SetEmptyCell( const ScAddress& rPos );
1134  SC_DLLPUBLIC void SetValue( SCCOL nCol, SCROW nRow, SCTAB nTab, const double& rVal );
1135  SC_DLLPUBLIC void SetValue( const ScAddress& rPos, double fVal );
1136  void SetValues( const ScAddress& rPos, const std::vector<double>& rVals );
1137  void SetError( SCCOL nCol, SCROW nRow, SCTAB nTab, const FormulaError nError);
1138  SC_DLLPUBLIC void SetFormula( const ScAddress& rPos, const ScTokenArray& rArray );
1139  SC_DLLPUBLIC void SetFormula( const ScAddress& rPos, const OUString& rFormula,
1151  bool SetFormulaCells( const ScAddress& rPos, std::vector<ScFormulaCell*>& rCells );
1156  bool HasFormulaCell( const ScRange& rRange ) const;
1157  SC_DLLPUBLIC void InsertMatrixFormula(SCCOL nCol1, SCROW nRow1,
1158  SCCOL nCol2, SCROW nRow2,
1159  const ScMarkData& rMark,
1160  const OUString& rFormula,
1161  const ScTokenArray* p = nullptr,
1163  SC_DLLPUBLIC void InsertTableOp(const ScTabOpParam& rParam, // multi-operation
1164  SCCOL nCol1, SCROW nRow1,
1165  SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark);
1167  SC_DLLPUBLIC OUString GetString( SCCOL nCol, SCROW nRow, SCTAB nTab,
1168  const ScInterpreterContext* pContext = nullptr ) const;
1169  SC_DLLPUBLIC OUString GetString( const ScAddress& rPos,
1170  const ScInterpreterContext* pContext = nullptr ) const;
1180  SC_DLLPUBLIC double* GetValueCell( const ScAddress& rPos );
1185  svl::SharedString GetSharedString( const ScAddress& rPos ) const;
1187  std::shared_ptr<sc::FormulaGroupContext>& GetFormulaGroupContext();
1190  { mbFormulaGroupCxtBlockDiscard = block; }
1192  SC_DLLPUBLIC void GetInputString( SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rString );
1193  FormulaError GetStringForFormula( const ScAddress& rPos, OUString& rString );
1194  SC_DLLPUBLIC double GetValue( const ScAddress& rPos ) const;
1195  SC_DLLPUBLIC double GetValue( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1196  SC_DLLPUBLIC void GetValue( SCCOL nCol, SCROW nRow, SCTAB nTab, double& rValue ) const;
1197  SC_DLLPUBLIC const EditTextObject* GetEditText( const ScAddress& rPos ) const;
1198  void RemoveEditTextCharAttribs( const ScAddress& rPos, const ScPatternAttr& rAttr );
1199  SC_DLLPUBLIC double RoundValueAsShown( double fVal, sal_uInt32 nFormat, const ScInterpreterContext* pContext = nullptr ) const;
1200  SC_DLLPUBLIC void GetNumberFormat( SCCOL nCol, SCROW nRow, SCTAB nTab,
1201  sal_uInt32& rFormat ) const;
1202  sal_uInt32 GetNumberFormat( const ScRange& rRange ) const;
1203  SC_DLLPUBLIC sal_uInt32 GetNumberFormat( const ScInterpreterContext& rContext, const ScAddress& ) const;
1204  void SetNumberFormat( const ScAddress& rPos, sal_uInt32 nNumberFormat );
1206  void GetNumberFormatInfo( const ScInterpreterContext& rContext, SvNumFormatType& nType, sal_uInt32& nIndex, const ScAddress& rPos ) const;
1207  SC_DLLPUBLIC const ScFormulaCell* GetFormulaCell( const ScAddress& rPos ) const;
1209  SC_DLLPUBLIC void GetFormula( SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rFormula ) const;
1210  SC_DLLPUBLIC void GetCellType( SCCOL nCol, SCROW nRow, SCTAB nTab, CellType& rCellType ) const;
1211  SC_DLLPUBLIC CellType GetCellType( const ScAddress& rPos ) const;
1213  SC_DLLPUBLIC bool HasData( SCCOL nCol, SCROW nRow, SCTAB nTab );
1214  SC_DLLPUBLIC bool HasStringData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1215  SC_DLLPUBLIC bool HasValueData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1216  SC_DLLPUBLIC bool HasValueData( const ScAddress& rPos ) const;
1217  bool HasStringCells( const ScRange& rRange ) const;
1220  bool HasSelectionData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1221  bool HasValidationData( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1229  sc::MultiDataCellState HasMultipleDataCells( const ScRange& rRange ) const;
1232  SC_DLLPUBLIC ScPostIt* GetNote(const ScAddress& rPos);
1233  SC_DLLPUBLIC ScPostIt* GetNote(SCCOL nCol, SCROW nRow, SCTAB nTab);
1234  void SetNote(const ScAddress& rPos, std::unique_ptr<ScPostIt> pNote);
1235  void SetNote(SCCOL nCol, SCROW nRow, SCTAB nTab, std::unique_ptr<ScPostIt> pNote);
1236  SC_DLLPUBLIC bool HasNote(const ScAddress& rPos) const;
1237  bool HasNote(SCCOL nCol, SCROW nRow, SCTAB nTab) const;
1238  bool HasNote(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow) const;
1239  SC_DLLPUBLIC bool HasColNotes(SCCOL nCol, SCTAB nTab) const;
1240  SC_DLLPUBLIC bool HasTabNotes(SCTAB nTab) const;
1241  bool HasNotes() const;
1242  SC_DLLPUBLIC std::unique_ptr<ScPostIt> ReleaseNote(const ScAddress& rPos);
1244  SC_DLLPUBLIC ScPostIt* CreateNote(const ScAddress& rPos);
1245  size_t GetNoteCount( SCTAB nTab, SCCOL nCol ) const;
1251  void CreateAllNoteCaptions();
1252  void ForgetNoteCaptions( const ScRangeList& rRanges, bool bPreserveData );
1255  ScAddress GetNotePosition( size_t nIndex ) const;
1256  ScAddress GetNotePosition( size_t nIndex, SCTAB nTab ) const;
1257  SCROW GetNotePosition( SCTAB nTab, SCCOL nCol, size_t nIndex ) const;
1259  SC_DLLPUBLIC void GetAllNoteEntries( std::vector<sc::NoteEntry>& rNotes ) const;
1260  SC_DLLPUBLIC void GetAllNoteEntries( SCTAB nTab, std::vector<sc::NoteEntry>& rNotes ) const;
1261  void GetNotesInRange( const ScRangeList& rRange, std::vector<sc::NoteEntry>& rNotes ) const;
1262  bool ContainsNotesInRange( const ScRangeList& rRange ) const;
1264  SC_DLLPUBLIC void SetDrawPageSize(SCTAB nTab);
1266  bool IsMerged( const ScAddress& rPos ) const;
1268  void ExtendMergeSel( SCCOL nStartCol, SCROW nStartRow,
1269  SCCOL& rEndCol, SCROW& rEndRow, const ScMarkData& rMark,
1270  bool bRefresh = false );
1271  SC_DLLPUBLIC bool ExtendMerge( SCCOL nStartCol, SCROW nStartRow,
1272  SCCOL& rEndCol, SCROW& rEndRow, SCTAB nTab,
1273  bool bRefresh = false );
1274  bool ExtendMerge( ScRange& rRange, bool bRefresh = false );
1275  SC_DLLPUBLIC void ExtendTotalMerge( ScRange& rRange ) const;
1276  SC_DLLPUBLIC void ExtendOverlapped( SCCOL& rStartCol, SCROW& rStartRow,
1277  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab ) const;
1278  SC_DLLPUBLIC void ExtendOverlapped( ScRange& rRange ) const;
1280  bool RefreshAutoFilter( SCCOL nStartCol, SCROW nStartRow,
1281  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab );
1283  SC_DLLPUBLIC void DoMergeContents( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1284  SCCOL nEndCol, SCROW nEndRow );
1285  SC_DLLPUBLIC void DoEmptyBlock( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1286  SCCOL nEndCol, SCROW nEndRow );
1287  // without checking:
1288  SC_DLLPUBLIC void DoMerge( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1289  SCCOL nEndCol, SCROW nEndRow, bool bDeleteCaptions = true );
1290  void RemoveMerge( SCCOL nCol, SCROW nRow, SCTAB nTab );
1292  bool IsBlockEmpty( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1293  SCCOL nEndCol, SCROW nEndRow, bool bIgnoreNotes = false ) const;
1294  bool IsPrintEmpty( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow,
1295  SCCOL nEndCol, SCROW nEndRow,
1296  bool bLeftIsEmpty = false,
1297  ScRange* pLastRange = nullptr,
1298  tools::Rectangle* pLastMM = nullptr ) const;
1300  void SkipOverlapped( SCCOL& rCol, SCROW& rRow, SCTAB nTab ) const;
1301  bool IsHorOverlapped( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1302  bool IsVerOverlapped( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1304  SC_DLLPUBLIC bool HasAttrib( SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1305  SCCOL nCol2, SCROW nRow2, SCTAB nTab2, HasAttrFlags nMask ) const;
1306  SC_DLLPUBLIC bool HasAttrib( const ScRange& rRange, HasAttrFlags nMask ) const;
1308  SC_DLLPUBLIC void GetBorderLines( SCCOL nCol, SCROW nRow, SCTAB nTab,
1309  const ::editeng::SvxBorderLine** ppLeft,
1310  const ::editeng::SvxBorderLine** ppTop,
1311  const ::editeng::SvxBorderLine** ppRight,
1312  const ::editeng::SvxBorderLine** ppBottom ) const;
1314  void ResetChanged( const ScRange& rRange );
1316  void CheckVectorizationState();
1317  void SetAllFormulasDirty( const sc::SetFormulaDirtyContext& rCxt );
1318  void SetDirty( const ScRange&, bool bIncludeEmptyCells );
1319  void SetTableOpDirty( const ScRange& ); // for Interpreter TableOp
1320  void InterpretDirtyCells( const ScRangeList& rRanges );
1321  SC_DLLPUBLIC void CalcAll();
1322  SC_DLLPUBLIC void CalcAfterLoad( bool bStartListening = true );
1323  void CompileAll();
1324  void CompileXML();
1336  bool CompileErrorCells(FormulaError nErrCode);
1338  ScAutoNameCache* GetAutoNameCache() { return pAutoNameCache.get(); }
1339  void SetPreviewFont( std::unique_ptr<SfxItemSet> pFontSet );
1340  SfxItemSet* GetPreviewFont() { return pPreviewFont.get(); }
1341  SfxItemSet* GetPreviewFont( SCCOL nCol, SCROW nRow, SCTAB nTab );
1343  void SetPreviewSelection( const ScMarkData& rSel );
1345  ScStyleSheet* GetPreviewCellStyle( SCCOL nCol, SCROW nRow, SCTAB nTab );
1346  void SetPreviewCellStyle( ScStyleSheet* pStyle ) { pPreviewCellStyle = pStyle; }
1347  SC_DLLPUBLIC void SetAutoNameCache( std::unique_ptr<ScAutoNameCache> pCache );
1351  ScLookupCache & GetLookupCache( const ScRange & rRange, ScInterpreterContext* pContext );
1354  void RemoveLookupCache( ScLookupCache & rCache );
1356  void ClearLookupCaches();
1358  // calculate automatically
1359  SC_DLLPUBLIC void SetAutoCalc( bool bNewAutoCalc );
1360  SC_DLLPUBLIC bool GetAutoCalc() const { return bAutoCalc; }
1361  // calculate automatically in/from/for ScDocShell disabled
1362  void SetAutoCalcShellDisabled( bool bNew ) { bAutoCalcShellDisabled = bNew; }
1364  // ForcedFormulas are to be calculated
1365  void SetForcedFormulaPending( bool bNew ) { bForcedFormulaPending = bNew; }
1367  // if CalcFormulaTree() is currently running
1371  void DelayFormulaGrouping( bool delay );
1372  bool IsDelayedFormulaGrouping() const { return bool(pDelayedFormulaGrouping); }
1374  void AddDelayedFormulaGroupingCell( const ScFormulaCell* cell );
1378  void EnableDelayStartListeningFormulaCells( ScColumn* column, bool delay );
1379  bool IsEnabledDelayStartListeningFormulaCells( ScColumn* column ) const;
1382  bool CanDelayStartListeningFormulaCells( ScColumn* column, SCROW row1, SCROW row2 );
1384  FormulaError GetErrCode( const ScAddress& ) const;
1398  bool ShrinkToDataArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow, SCCOL& rEndCol, SCROW& rEndRow ) const;
1419  bool ShrinkToUsedDataArea( bool& o_bShrunk,
1420  SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1421  SCCOL& rEndCol, SCROW& rEndRow, bool bColumnsOnly,
1422  bool bStickyTopRow = false, bool bStickyLeftCol = false,
1423  ScDataAreaExtras* pDataAreaExtras = nullptr ) const;
1435  SCROW GetLastDataRow( SCTAB nTab, SCCOL nCol1, SCCOL nCol2, SCROW nLastRow ) const;
1450  SC_DLLPUBLIC void GetDataArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1451  SCCOL& rEndCol, SCROW& rEndRow,
1452  bool bIncludeOld, bool bOnlyDown ) const;
1461  bool GetDataAreaSubrange(ScRange& rRange) const;
1463  SC_DLLPUBLIC bool GetCellArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow ) const;
1464  SC_DLLPUBLIC bool GetTableArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow,
1465  bool bCalcHiddens = false) const;
1466  SC_DLLPUBLIC bool GetPrintArea( SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow,
1467  bool bNotes = true) const;
1468  SC_DLLPUBLIC bool GetPrintAreaHor( SCTAB nTab, SCROW nStartRow, SCROW nEndRow,
1469  SCCOL& rEndCol ) const;
1470  SC_DLLPUBLIC bool GetPrintAreaVer( SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol,
1471  SCROW& rEndRow, bool bNotes ) const;
1472  void InvalidateTableArea();
1475  SC_DLLPUBLIC void GetTiledRenderingArea(SCTAB nTab, SCCOL& rEndCol, SCROW& rEndRow) const;
1477  SC_DLLPUBLIC bool GetDataStart( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow ) const;
1484  void ExtendPrintArea( OutputDevice* pDev, SCTAB nTab,
1485  SCCOL nStartCol, SCROW nStartRow,
1486  SCCOL& rEndCol, SCROW nEndRow ) const;
1487  SC_DLLPUBLIC SCSIZE GetEmptyLinesInBlock( SCCOL nStartCol, SCROW nStartRow, SCTAB nStartTab,
1488  SCCOL nEndCol, SCROW nEndRow, SCTAB nEndTab,
1489  ScDirection eDir );
1491  void FindAreaPos( SCCOL& rCol, SCROW& rRow, SCTAB nTab, ScMoveDirection eDirection ) const;
1492  SC_DLLPUBLIC void GetNextPos( SCCOL& rCol, SCROW& rRow, SCTAB nTab, SCCOL nMovX, SCROW nMovY,
1493  bool bMarked, bool bUnprotected, const ScMarkData& rMark,
1494  SCCOL nTabStartCol = SC_TABSTART_NONE ) const;
1496  bool GetNextMarkedCell( SCCOL& rCol, SCROW& rRow, SCTAB nTab,
1497  const ScMarkData& rMark );
1499  void LimitChartArea( SCTAB nTab, SCCOL& rStartCol, SCROW& rStartRow,
1500  SCCOL& rEndCol, SCROW& rEndRow );
1501  void LimitChartIfAll( ScRangeListRef& rRangeList );
1503  bool InsertRow( SCCOL nStartCol, SCTAB nStartTab,
1504  SCCOL nEndCol, SCTAB nEndTab,
1505  SCROW nStartRow, SCSIZE nSize, ScDocument* pRefUndoDoc = nullptr,
1506  const ScMarkData* pTabMark = nullptr );
1507  SC_DLLPUBLIC bool InsertRow( const ScRange& rRange );
1508  void DeleteRow( SCCOL nStartCol, SCTAB nStartTab,
1509  SCCOL nEndCol, SCTAB nEndTab,
1510  SCROW nStartRow, SCSIZE nSize,
1511  ScDocument* pRefUndoDoc = nullptr, bool* pUndoOutline = nullptr,
1512  const ScMarkData* pTabMark = nullptr );
1513  SC_DLLPUBLIC void DeleteRow( const ScRange& rRange );
1514  bool InsertCol( SCROW nStartRow, SCTAB nStartTab,
1515  SCROW nEndRow, SCTAB nEndTab,
1516  SCCOL nStartCol, SCSIZE nSize, ScDocument* pRefUndoDoc = nullptr,
1517  const ScMarkData* pTabMark = nullptr );
1518  SC_DLLPUBLIC bool InsertCol( const ScRange& rRange );
1519  void DeleteCol( SCROW nStartRow, SCTAB nStartTab,
1520  SCROW nEndRow, SCTAB nEndTab,
1521  SCCOL nStartCol, SCSIZE nSize,
1522  ScDocument* pRefUndoDoc = nullptr, bool* pUndoOutline = nullptr,
1523  const ScMarkData* pTabMark = nullptr );
1524  void DeleteCol( const ScRange& rRange );
1526  bool CanInsertRow( const ScRange& rRange ) const;
1527  bool CanInsertCol( const ScRange& rRange ) const;
1529  void FitBlock( const ScRange& rOld, const ScRange& rNew, bool bClear = true );
1530  bool CanFitBlock( const ScRange& rOld, const ScRange& rNew );
1532  bool IsClipOrUndo() const { return bIsClip || bIsUndo; }
1533  bool IsUndo() const { return bIsUndo; }
1534  bool IsClipboard() const { return bIsClip; }
1535  bool IsUndoEnabled() const { return mbUndoEnabled; }
1536  SC_DLLPUBLIC void EnableUndo( bool bVal );
1537  bool IsFunctionAccess() const { return bIsFunctionAccess; }
1539  bool IsAdjustHeightLocked() const { return nAdjustHeightLock != 0; }
1543  void EnableExecuteLink( bool bVal ) { mbExecuteLinkEnabled = bVal; }
1545  void EnableChangeReadOnly( bool bVal ) { mbChangeReadOnlyEnabled = bVal; }
1547  SC_DLLPUBLIC void EnableUserInteraction( bool bVal );
1549  void SetNamedRangesLockCount( sal_Int16 nCount ) { mnNamedRangesLockCount = nCount; }
1550  SC_DLLPUBLIC void ResetClip( ScDocument* pSourceDoc, const ScMarkData* pMarks );
1551  SC_DLLPUBLIC void ResetClip( ScDocument* pSourceDoc, SCTAB nTab );
1552  void SetCutMode( bool bCut );
1553  bool IsCutMode();
1554  void SetClipArea( const ScRange& rArea, bool bCut = false );
1556  SC_DLLPUBLIC bool IsDocVisible() const { return bIsVisible; }
1557  SC_DLLPUBLIC void SetDocVisible( bool bSet );
1559  bool HasOLEObjectsInArea( const ScRange& rRange, const ScMarkData* pTabMark = nullptr );
1561  void DeleteObjectsInArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1562  const ScMarkData& rMark, bool bAnchored = false );
1563  void DeleteObjectsInSelection( const ScMarkData& rMark );
1565  SC_DLLPUBLIC void DeleteArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark,
1566  InsertDeleteFlags nDelFlag, bool bBroadcast = true,
1567  sc::ColumnSpanSet* pBroadcastSpans = nullptr );
1569  SC_DLLPUBLIC void DeleteAreaTab(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1570  SCTAB nTab, InsertDeleteFlags nDelFlag);
1571  void DeleteAreaTab(const ScRange& rRange, InsertDeleteFlags nDelFlag);
1573  SC_DLLPUBLIC void CopyToClip( const ScClipParam& rClipParam, ScDocument* pClipDoc,
1574  const ScMarkData* pMarks, bool bKeepScenarioFlags,
1575  bool bIncludeObjects );
1586  SC_DLLPUBLIC void CopyStaticToDocument(const ScRange& rSrcRange, SCTAB nDestTab, ScDocument& rDestDoc);
1595  void CopyCellToDocument( const ScAddress& rSrcPos, const ScAddress& rDestPos, ScDocument& rDestDoc );
1597  void CopyTabToClip( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1598  SCTAB nTab, ScDocument* pClipDoc);
1603  sc::ColumnSpanSet& rBroadcastSpans );
1606  SCCOL nCol2, SCROW nRow2 );
1607  void CopyBlockFromClip( sc::CopyFromClipContext& rCxt, SCCOL nCol1, SCROW nRow1,
1608  SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark,
1609  SCCOL nDx, SCROW nDy );
1614  SCCOL nCol2, SCROW nRow2, const ScMarkData& rMark, SCCOL nDx,
1615  SCROW& rClipStartRow, SCROW nClipEndRow);
1617  void StartListeningFromClip( SCCOL nCol1, SCROW nRow1,
1618  SCCOL nCol2, SCROW nRow2,
1619  const ScMarkData& rMark, InsertDeleteFlags nInsFlag );
1621  void SetDirtyFromClip( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1622  const ScMarkData& rMark, InsertDeleteFlags nInsFlag,
1623  sc::ColumnSpanSet& rBroadcastSpans );
1627  SC_DLLPUBLIC void CopyFromClip( const ScRange& rDestRange, const ScMarkData& rMark,
1628  InsertDeleteFlags nInsFlag,
1629  ScDocument* pRefUndoDoc,
1630  ScDocument* pClipDoc,
1631  bool bResetCut = true,
1632  bool bAsLink = false,
1633  bool bIncludeFiltered = true,
1634  bool bSkipAttrForEmpty = false,
1635  const ScRangeList * pDestRanges = nullptr );
1637  void CopyMultiRangeFromClip(const ScAddress& rDestPos, const ScMarkData& rMark,
1638  InsertDeleteFlags nInsFlag, ScDocument* pClipDoc,
1639  bool bResetCut = true, bool bAsLink = false,
1640  bool bIncludeFiltered = true,
1641  bool bSkipAttrForEmpty = false);
1643  void GetClipArea(SCCOL& nClipX, SCROW& nClipY, bool bIncludeFiltered);
1644  void GetClipStart(SCCOL& nClipX, SCROW& nClipY);
1646  bool HasClipFilteredRows();
1648  bool IsClipboardSource() const;
1650  SC_DLLPUBLIC void TransposeClip(ScDocument* pTransClip, InsertDeleteFlags nFlags, bool bAsLink,
1651  bool bIncludeFiltered);
1654  void SetClipParam(const ScClipParam& rParam);
1661  void ClosingClipboardSource();
1663  void MixDocument( const ScRange& rRange, ScPasteFunc nFunction, bool bSkipEmpty,
1664  ScDocument& rSrcDoc );
1666  void FillTab( const ScRange& rSrcArea, const ScMarkData& rMark,
1667  InsertDeleteFlags nFlags, ScPasteFunc nFunction,
1668  bool bSkipEmpty, bool bAsLink );
1669  void FillTabMarked( SCTAB nSrcTab, const ScMarkData& rMark,
1670  InsertDeleteFlags nFlags, ScPasteFunc nFunction,
1671  bool bSkipEmpty, bool bAsLink );
1673  void TransliterateText( const ScMarkData& rMultiMark, TransliterationFlags nType );
1675  SC_DLLPUBLIC void InitUndo( const ScDocument& rSrcDoc, SCTAB nTab1, SCTAB nTab2,
1676  bool bColInfo = false, bool bRowInfo = false );
1677  void AddUndoTab( SCTAB nTab1, SCTAB nTab2,
1678  bool bColInfo = false, bool bRowInfo = false );
1679  SC_DLLPUBLIC void InitUndoSelected( const ScDocument& rSrcDoc, const ScMarkData& rTabSelection,
1680  bool bColInfo = false, bool bRowInfo = false );
1682  // don't use anymore:
1683  void CopyToDocument(SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1684  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1685  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc,
1686  const ScMarkData* pMarks = nullptr, bool bColRowFlags = true);
1687  void UndoToDocument(SCCOL nCol1, SCROW nRow1, SCTAB nTab1,
1688  SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
1689  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc);
1691  SC_DLLPUBLIC void CopyToDocument(const ScRange& rRange,
1692  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc,
1693  const ScMarkData* pMarks = nullptr, bool bColRowFlags = true);
1694  void UndoToDocument(const ScRange& rRange,
1695  InsertDeleteFlags nFlags, bool bMarked, ScDocument& rDestDoc);
1697  void CopyScenario( SCTAB nSrcTab, SCTAB nDestTab, bool bNewScenario = false );
1698  bool TestCopyScenario( SCTAB nSrcTab, SCTAB nDestTab ) const;
1699  void MarkScenario(SCTAB nSrcTab, SCTAB nDestTab,
1700  ScMarkData& rDestMark, bool bResetMark = true,
1701  ScScenarioFlags nNeededBits = ScScenarioFlags::NONE) const;
1702  bool HasScenarioRange( SCTAB nTab, const ScRange& rRange ) const;
1703  SC_DLLPUBLIC const ScRangeList* GetScenarioRanges( SCTAB nTab ) const;
1705  SC_DLLPUBLIC void CopyUpdated( ScDocument* pPosDoc, ScDocument* pDestDoc );
1708  pUndoDoc = nullptr, bool bIncludeDraw = true,
1709  bool bUpdateNoteCaptionPos = true );
1714  SC_DLLPUBLIC void UpdateTranspose( const ScAddress& rDestPos, ScDocument* pClipDoc,
1715  const ScMarkData& rMark, ScDocument* pUndoDoc );
1717  void UpdateGrow( const ScRange& rArea, SCCOL nGrowX, SCROW nGrowY );
1719  SC_DLLPUBLIC void Fill( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
1720  ScProgress* pProgress, const ScMarkData& rMark,
1721  sal_uLong nFillCount, FillDir eFillDir = FILL_TO_BOTTOM,
1722  FillCmd eFillCmd = FILL_LINEAR, FillDateCmd eFillDateCmd = FILL_DAY,
1723  double nStepValue = 1.0, double nMaxValue = 1E307 );
1724  OUString GetAutoFillPreview( const ScRange& rSource, SCCOL nEndX, SCROW nEndY );
1727  const ScAddress& rCursor, const ScMarkData& rMark,
1728  double& rResult );
1730  SC_DLLPUBLIC const SfxPoolItem* GetAttr( SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich ) const;
1731  template<class T> const T* GetAttr( SCCOL nCol, SCROW nRow, SCTAB nTab, TypedWhichId<T> nWhich ) const
1732  {
1733  return static_cast<const T*>(GetAttr(nCol, nRow, nTab, sal_uInt16(nWhich)));
1734  }
1735  SC_DLLPUBLIC const SfxPoolItem* GetAttr( const ScAddress& rPos, sal_uInt16 nWhich ) const;
1736  template<class T> const T* GetAttr( const ScAddress& rPos, TypedWhichId<T> nWhich ) const
1737  {
1738  return static_cast<const T*>(GetAttr(rPos, sal_uInt16(nWhich)));
1739  }
1740  SC_DLLPUBLIC const ScPatternAttr* GetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1741  SC_DLLPUBLIC const ScPatternAttr* GetPattern( const ScAddress& rPos ) const;
1742  SC_DLLPUBLIC const ScPatternAttr* GetMostUsedPattern( SCCOL nCol, SCROW nStartRow, SCROW nEndRow, SCTAB nTab ) const;
1743  const ScPatternAttr* GetSelectionPattern( const ScMarkData& rMark );
1744  std::unique_ptr<ScPatternAttr> CreateSelectionPattern( const ScMarkData& rMark, bool bDeep = true );
1745  SC_DLLPUBLIC void AddCondFormatData( const ScRangeList& rRange, SCTAB nTab, sal_uInt32 nIndex );
1746  void RemoveCondFormatData( const ScRangeList& rRange, SCTAB nTab, sal_uInt32 nIndex );
1748  SC_DLLPUBLIC ScConditionalFormat* GetCondFormat( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1749  // pCell is an optimization, must point to rPos
1750  SC_DLLPUBLIC const SfxItemSet* GetCondResult( SCCOL nCol, SCROW nRow, SCTAB nTab,
1751  ScRefCellValue* pCell = nullptr ) const;
1752  const SfxItemSet* GetCondResult( ScRefCellValue& rCell, const ScAddress& rPos,
1753  const ScConditionalFormatList& rList,
1754  const ScCondFormatIndexes& rIndex ) const;
1755  const SfxPoolItem* GetEffItem( SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich ) const;
1756  template<class T> const T* GetEffItem( SCCOL nCol, SCROW nRow, SCTAB nTab, TypedWhichId<T> nWhich ) const
1757  {
1758  return static_cast<const T*>(GetEffItem(nCol, nRow, nTab, sal_uInt16(nWhich)));
1759  }
1761  SC_DLLPUBLIC const css::uno::Reference< css::i18n::XBreakIterator >& GetBreakIterator();
1762  bool HasStringWeakCharacters( const OUString& rString );
1763  SC_DLLPUBLIC SvtScriptType GetStringScriptType( const OUString& rString );
1764  // pCell is an optimization, must point to rPos
1765  SC_DLLPUBLIC SvtScriptType GetCellScriptType( const ScAddress& rPos, sal_uInt32 nNumberFormat,
1766  const ScRefCellValue* pCell = nullptr );
1767  // pCell is an optimization, must point to nCol,nRow,nTab
1769  const ScRefCellValue* pCell = nullptr );
1770  SvtScriptType GetRangeScriptType( sc::ColumnBlockPosition& rBlockPos, const ScAddress& rPos, SCROW nLength );
1771  SvtScriptType GetRangeScriptType( const ScRangeList& rRanges );
1773  bool HasDetectiveOperations() const;
1774  void AddDetectiveOperation( const ScDetOpData& rData );
1775  void ClearDetectiveOperations();
1776  ScDetOpList* GetDetOpList() const { return pDetOpList.get(); }
1777  void SetDetOpList(std::unique_ptr<ScDetOpList> pNew);
1779  bool HasDetectiveObjects(SCTAB nTab) const;
1781  void GetSelectionFrame( const ScMarkData& rMark,
1782  SvxBoxItem& rLineOuter,
1783  SvxBoxInfoItem& rLineInner );
1784  void ApplySelectionFrame(const ScMarkData& rMark,
1785  const SvxBoxItem& rLineOuter,
1786  const SvxBoxInfoItem* pLineInner);
1787  void ApplyFrameAreaTab(const ScRange& rRange,
1788  const SvxBoxItem& rLineOuter,
1789  const SvxBoxInfoItem& rLineInner);
1791  void ClearSelectionItems( const sal_uInt16* pWhich, const ScMarkData& rMark );
1792  void ChangeSelectionIndent( bool bIncrement, const ScMarkData& rMark );
1794  SC_DLLPUBLIC sal_uLong AddCondFormat( std::unique_ptr<ScConditionalFormat> pNew, SCTAB nTab );
1795  void DeleteConditionalFormat( sal_uLong nIndex, SCTAB nTab );
1797  void SetCondFormList( ScConditionalFormatList* pList, SCTAB nTab );
1803  const ScValidationDataList* GetValidationList() const { return pValidationList.get();}
1804  ScValidationDataList* GetValidationList() { return pValidationList.get();}
1806  SC_DLLPUBLIC void ApplyAttr( SCCOL nCol, SCROW nRow, SCTAB nTab,
1807  const SfxPoolItem& rAttr );
1808  SC_DLLPUBLIC void ApplyPattern( SCCOL nCol, SCROW nRow, SCTAB nTab,
1809  const ScPatternAttr& rAttr );
1810  SC_DLLPUBLIC void ApplyPatternArea( SCCOL nStartCol, SCROW nStartRow,
1811  SCCOL nEndCol, SCROW nEndRow,
1812  const ScMarkData& rMark, const ScPatternAttr& rAttr,
1813  ScEditDataArray* pDataArray = nullptr,
1814  bool* const pIsChanged = nullptr );
1815  SC_DLLPUBLIC void ApplyPatternAreaTab( SCCOL nStartCol, SCROW nStartRow,
1816  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab,
1817  const ScPatternAttr& rAttr );
1820  const ScMarkData& rMark,
1821  const ScPatternAttr& rPattern,
1822  SvNumFormatType nNewType );
1824  void ApplyStyle( SCCOL nCol, SCROW nRow, SCTAB nTab,
1825  const ScStyleSheet& rStyle);
1826  void ApplyStyleArea( SCCOL nStartCol, SCROW nStartRow,
1827  SCCOL nEndCol, SCROW nEndRow,
1828  const ScMarkData& rMark, const ScStyleSheet& rStyle);
1829  SC_DLLPUBLIC void ApplyStyleAreaTab( SCCOL nStartCol, SCROW nStartRow,
1830  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab,
1831  const ScStyleSheet& rStyle);
1833  SC_DLLPUBLIC void ApplySelectionStyle( const ScStyleSheet& rStyle, const ScMarkData& rMark );
1834  void ApplySelectionLineStyle( const ScMarkData& rMark,
1835  const ::editeng::SvxBorderLine* pLine, bool bColorOnly );
1837  const ScStyleSheet* GetStyle( SCCOL nCol, SCROW nRow, SCTAB nTab ) const;
1838  const ScStyleSheet* GetSelectionStyle( const ScMarkData& rMark ) const;
1840  void StyleSheetChanged( const SfxStyleSheetBase* pStyleSheet, bool bRemoved,
1841  OutputDevice* pDev,
1842  double nPPTX, double nPPTY,
1843  const Fraction& rZoomX, const Fraction& rZoomY );
1845  bool IsStyleSheetUsed( const ScStyleSheet& rStyle ) const;
1847  SC_DLLPUBLIC bool ApplyFlagsTab( SCCOL nStartCol, SCROW nStartRow,
1848  SCCOL nEndCol, SCROW nEndRow,
1849  SCTAB nTab, ScMF nFlags );
1850  SC_DLLPUBLIC bool RemoveFlagsTab( SCCOL nStartCol, SCROW nStartRow,
1851  SCCOL nEndCol, SCROW nEndRow,
1852  SCTAB nTab, ScMF nFlags );
1854  SC_DLLPUBLIC void SetPattern( const ScAddress&, const ScPatternAttr& rAttr );
1855  SC_DLLPUBLIC const ScPatternAttr* SetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab, std::unique_ptr<ScPatternAttr> );
1856  SC_DLLPUBLIC void SetPattern( SCCOL nCol, SCROW nRow, SCTAB nTab, const ScPatternAttr& rAttr );
1858  void AutoFormat( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
1859  sal_uInt16 nFormatNo, const ScMarkData& rMark );
1860  void GetAutoFormatData( SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
1861  ScAutoFormatData& rData );
1862  bool SearchAndReplace( const SvxSearchItem& rSearchItem,
1863  SCCOL& rCol, SCROW& rRow, SCTAB& rTab,
1864  const ScMarkData& rMark, ScRangeList& rMatchedRanges,
1865  OUString& rUndoStr, ScDocument* pUndoDoc = nullptr );
1866  static bool IsEmptyCellSearch( const SvxSearchItem& rSearchItem );
1868  // determine Col/Row of subsequent calls
1869  // (e.g. not found from the beginning, or subsequent tables)
1870  // meaning of explanation in "()" was already unclear in German
1871  void GetSearchAndReplaceStart( const SvxSearchItem& rSearchItem,
1872  SCCOL& rCol, SCROW& rRow );
1874  bool Solver( SCCOL nFCol, SCROW nFRow, SCTAB nFTab,
1875  SCCOL nVCol, SCROW nVRow, SCTAB nVTab,
1876  const OUString& sValStr, double& nX);
1878  SC_DLLPUBLIC void ApplySelectionPattern( const ScPatternAttr& rAttr, const ScMarkData& rMark,
1879  ScEditDataArray* pDataArray = nullptr, bool* pIsChanged = nullptr );
1880  SC_DLLPUBLIC void DeleteSelection( InsertDeleteFlags nDelFlag, const ScMarkData& rMark, bool bBroadcast = true );
1881  void DeleteSelectionTab( SCTAB nTab, InsertDeleteFlags nDelFlag, const ScMarkData& rMark );
1883  SC_DLLPUBLIC void SetColWidth( SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth );
1884  SC_DLLPUBLIC void SetColWidthOnly( SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth );
1885  SC_DLLPUBLIC void SetRowHeight( SCROW nRow, SCTAB nTab, sal_uInt16 nNewHeight );
1886  SC_DLLPUBLIC void SetRowHeightRange( SCROW nStartRow, SCROW nEndRow, SCTAB nTab,
1887  sal_uInt16 nNewHeight );
1889  SC_DLLPUBLIC void SetRowHeightOnly( SCROW nStartRow, SCROW nEndRow, SCTAB nTab,
1890  sal_uInt16 nNewHeight );
1891  SC_DLLPUBLIC void SetManualHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bManual );
1893  SC_DLLPUBLIC sal_uInt16 GetColWidth( SCCOL nCol, SCTAB nTab, bool bHiddenAsZero = true ) const;
1894  SC_DLLPUBLIC sal_uLong GetColWidth( SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab ) const;
1895  SC_DLLPUBLIC sal_uInt16 GetRowHeight( SCROW nRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1896  SC_DLLPUBLIC sal_uInt16 GetRowHeight( SCROW nRow, SCTAB nTab, SCROW* pStartRow, SCROW* pEndRow ) const;
1897  SC_DLLPUBLIC sal_uLong GetRowHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1904  SCROW GetRowForHeight( SCTAB nTab, sal_uLong nHeight ) const;
1905  sal_uLong GetScaledRowHeight( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, double fScale, const sal_uLong* pnMaxHeight = nullptr ) const;
1906  SC_DLLPUBLIC sal_uLong GetColOffset( SCCOL nCol, SCTAB nTab, bool bHiddenAsZero = true ) const;
1907  SC_DLLPUBLIC sal_uLong GetRowOffset( SCROW nRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
1909  SC_DLLPUBLIC sal_uInt16 GetOriginalWidth( SCCOL nCol, SCTAB nTab ) const;
1910  SC_DLLPUBLIC sal_uInt16 GetOriginalHeight( SCROW nRow, SCTAB nTab ) const;
1912  sal_uInt16 GetCommonWidth( SCCOL nEndCol, SCTAB nTab ) const;
1914  SCROW GetHiddenRowCount( SCROW nRow, SCTAB nTab ) const;
1916  sal_uInt16 GetOptimalColWidth( SCCOL nCol, SCTAB nTab, OutputDevice* pDev,
1917  double nPPTX, double nPPTY,
1918  const Fraction& rZoomX, const Fraction& rZoomY,
1919  bool bFormula,
1920  const ScMarkData* pMarkData = nullptr,
1921  const ScColWidthParam* pParam = nullptr );
1924  SCROW nEndRow, SCTAB nTab, bool bApi );
1926  void UpdateAllRowHeights( sc::RowHeightContext& rCxt, const ScMarkData* pTabMark );
1928  tools::Long GetNeededSize( SCCOL nCol, SCROW nRow, SCTAB nTab,
1929  OutputDevice* pDev,
1930  double nPPTX, double nPPTY,
1931  const Fraction& rZoomX, const Fraction& rZoomY,
1932  bool bWidth, bool bTotalSize = false,
1933  bool bInPrintTwips = false );
1935  SC_DLLPUBLIC void ShowCol(SCCOL nCol, SCTAB nTab, bool bShow);
1936  SC_DLLPUBLIC void ShowRow(SCROW nRow, SCTAB nTab, bool bShow);
1937  SC_DLLPUBLIC void ShowRows(SCROW nRow1, SCROW nRow2, SCTAB nTab, bool bShow);
1938  SC_DLLPUBLIC void SetRowFlags( SCROW nRow, SCTAB nTab, CRFlags nNewFlags );
1939  SC_DLLPUBLIC void SetRowFlags( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, CRFlags nNewFlags );
1941  SC_DLLPUBLIC CRFlags GetColFlags( SCCOL nCol, SCTAB nTab ) const;
1942  SC_DLLPUBLIC CRFlags GetRowFlags( SCROW nRow, SCTAB nTab ) const;
1944  SC_DLLPUBLIC void GetAllRowBreaks(std::set<SCROW>& rBreaks, SCTAB nTab, bool bPage, bool bManual) const;
1945  SC_DLLPUBLIC void GetAllColBreaks(std::set<SCCOL>& rBreaks, SCTAB nTab, bool bPage, bool bManual) const;
1946  SC_DLLPUBLIC ScBreakType HasRowBreak(SCROW nRow, SCTAB nTab) const;
1947  SC_DLLPUBLIC ScBreakType HasColBreak(SCCOL nCol, SCTAB nTab) const;
1948  SC_DLLPUBLIC void SetRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual);
1949  SC_DLLPUBLIC void SetColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual);
1950  void RemoveRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual);
1951  void RemoveColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual);
1952  css::uno::Sequence<
1953  css::sheet::TablePageBreakData> GetRowBreakData(SCTAB nTab) const;
1955  SC_DLLPUBLIC bool RowHidden(SCROW nRow, SCTAB nTab, SCROW* pFirstRow = nullptr, SCROW* pLastRow = nullptr) const;
1956  SC_DLLPUBLIC bool HasHiddenRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1957  SC_DLLPUBLIC bool ColHidden(SCCOL nCol, SCTAB nTab, SCCOL* pFirstCol = nullptr, SCCOL* pLastCol = nullptr) const;
1958  SC_DLLPUBLIC void SetRowHidden(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bHidden);
1959  SC_DLLPUBLIC void SetColHidden(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bHidden);
1960  SC_DLLPUBLIC SCROW FirstVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1961  SC_DLLPUBLIC SCROW LastVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1962  SCROW CountVisibleRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1964  SC_DLLPUBLIC bool RowFiltered(SCROW nRow, SCTAB nTab, SCROW* pFirstRow = nullptr, SCROW* pLastRow = nullptr) const;
1965  bool HasFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1966  bool ColFiltered(SCCOL nCol, SCTAB nTab) const;
1967  SC_DLLPUBLIC void SetRowFiltered(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bFiltered);
1968  SCROW FirstNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1969  SCROW LastNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1970  SCROW CountNonFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const;
1972  SC_DLLPUBLIC bool IsManualRowHeight(SCROW nRow, SCTAB nTab) const;
1974  bool HasUniformRowHeight( SCTAB nTab, SCROW nRow1, SCROW nRow2 ) const;
1981  void SyncColRowFlags();
1984  SC_DLLPUBLIC SCROW GetLastFlaggedRow( SCTAB nTab ) const;
1987  SCCOL GetLastChangedCol( SCTAB nTab ) const;
1989  SCROW GetLastChangedRow( SCTAB nTab ) const;
1991  SCCOL GetNextDifferentChangedCol( SCTAB nTab, SCCOL nStart) const;
1993  SCROW GetNextDifferentChangedRow( SCTAB nTab, SCROW nStart) const;
1995  // returns whether to export a Default style for this col or not
1996  // nDefault is set to one position in the current row where the Default style is
1997  void GetColDefault( SCTAB nTab, SCCOL nCol, SCROW nLastRow, SCROW& nDefault);
1999  bool UpdateOutlineCol( SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bShow );
2000  bool UpdateOutlineRow( SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bShow );
2002  void StripHidden( SCCOL& rX1, SCROW& rY1, SCCOL& rX2, SCROW& rY2, SCTAB nTab );
2003  void ExtendHidden( SCCOL& rX1, SCROW& rY1, SCCOL& rX2, SCROW& rY2, SCTAB nTab );
2008  void GetUnprotectedCells( ScRangeList& rRange, SCTAB nTab ) const;
2010  // PageStyle:
2011  SC_DLLPUBLIC OUString GetPageStyle( SCTAB nTab ) const;
2012  SC_DLLPUBLIC void SetPageStyle( SCTAB nTab, const OUString& rName );
2013  Size GetPageSize( SCTAB nTab ) const;
2014  void SetPageSize( SCTAB nTab, const Size& rSize );
2015  void SetRepeatArea( SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol, SCROW nStartRow, SCROW nEndRow );
2016  void InvalidatePageBreaks(SCTAB nTab);
2017  void UpdatePageBreaks( SCTAB nTab, const ScRange* pUserArea = nullptr );
2018  void RemoveManualBreaks( SCTAB nTab );
2019  bool HasManualBreaks( SCTAB nTab ) const;
2021  bool IsPageStyleInUse( std::u16string_view rStrPageStyle, SCTAB* pInTab );
2022  bool RemovePageStyleInUse( std::u16string_view rStrPageStyle );
2023  bool RenamePageStyleInUse( std::u16string_view rOld, const OUString& rNew );
2024  void ModifyStyleSheet( SfxStyleSheetBase& rPageStyle,
2025  const SfxItemSet& rChanges );
2027  void PageStyleModified( SCTAB nTab, const OUString& rNewName );
2029  SC_DLLPUBLIC bool NeedPageResetAfterTab( SCTAB nTab ) const;
2031  // Was stored in PageStyle previously. Now it exists for every table:
2032  SC_DLLPUBLIC bool HasPrintRange();
2033  SC_DLLPUBLIC sal_uInt16 GetPrintRangeCount( SCTAB nTab );
2034  SC_DLLPUBLIC const ScRange* GetPrintRange( SCTAB nTab, sal_uInt16 nPos );
2038  bool IsPrintEntireSheet( SCTAB nTab ) const;
2041  SC_DLLPUBLIC void ClearPrintRanges( SCTAB nTab );
2043  SC_DLLPUBLIC void AddPrintRange( SCTAB nTab, const ScRange& rNew );
2045  SC_DLLPUBLIC void SetPrintEntireSheet( SCTAB nTab );
2046  SC_DLLPUBLIC void SetRepeatColRange( SCTAB nTab, std::unique_ptr<ScRange> pNew );
2047  SC_DLLPUBLIC void SetRepeatRowRange( SCTAB nTab, std::unique_ptr<ScRange> pNew );
2048  std::unique_ptr<ScPrintRangeSaver> CreatePrintRangeSaver() const;
2049  void RestorePrintRanges( const ScPrintRangeSaver& rSaver );
2051  SC_DLLPUBLIC tools::Rectangle GetMMRect( SCCOL nStartCol, SCROW nStartRow,
2052  SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, bool bHiddenAsZero = true ) const;
2053  SC_DLLPUBLIC ScRange GetRange( SCTAB nTab, const tools::Rectangle& rMMRect, bool bHiddenAsZero = true ) const;
2055  void UpdStlShtPtrsFrmNms();
2056  void StylesToNames();
2058  SC_DLLPUBLIC void CopyStdStylesFrom( const ScDocument& rSrcDoc );
2060  static sal_uInt16 GetSrcVersion() { return nSrcVer; }
2062  void SetSrcCharSet( rtl_TextEncoding eNew ) { eSrcSet = eNew; }
2063  void UpdateFontCharSet();
2065  void FillInfo( ScTableInfo& rTabInfo, SCCOL nCol1, SCROW nRow1,
2066  SCCOL nCol2, SCROW nRow2, SCTAB nTab, double fColScale,
2067  double fRowScale, bool bPageMode, bool bFormulaMode,
2068  const ScMarkData* pMarkData = nullptr );
2073  void Sort( SCTAB nTab, const ScSortParam& rSortParam,
2074  bool bKeepQuery, bool bUpdateRefs,
2075  ScProgress* pProgress, sc::ReorderParam* pUndo );
2077  void Reorder( const sc::ReorderParam& rParam );
2079  void PrepareQuery( SCTAB nTab, ScQueryParam& rQueryParam );
2080  SCSIZE Query( SCTAB nTab, const ScQueryParam& rQueryParam, bool bKeepSub );
2081  SC_DLLPUBLIC bool CreateQueryParam( const ScRange& rRange, ScQueryParam& rQueryParam );
2082  void GetUpperCellString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString& rStr);
2090  void GetFilterEntries( SCCOL nCol, SCROW nRow,
2091  SCTAB nTab, ScFilterEntries& rFilterEntries );
2093  SC_DLLPUBLIC void GetFilterEntriesArea( SCCOL nCol, SCROW nStartRow, SCROW nEndRow,
2094  SCTAB nTab, bool bCaseSens,
2095  ScFilterEntries& rFilterEntries );
2097  void GetDataEntries( SCCOL nCol, SCROW nRow, SCTAB nTab,
2098  std::vector<ScTypedStrData>& rStrings, bool bValidation = false );
2099  void GetFormulaEntries( ScTypedCaseStrSet& rStrings );
2101  bool HasAutoFilter( SCCOL nCol, SCROW nRow, SCTAB nTab );
2102  void GetFilterSelCount( SCCOL nCol, SCROW nRow, SCTAB nTab, SCSIZE& nSelected, SCSIZE& nTotal );
2104  SC_DLLPUBLIC bool HasColHeader( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
2105  SCTAB nTab );
2106  SC_DLLPUBLIC bool HasRowHeader( SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow,
2107  SCTAB nTab );
2109  SfxPrinter* GetPrinter( bool bCreateIfNotExist = true );
2110  void SetPrinter( VclPtr<SfxPrinter> const & pNewPrinter );
2112  SC_DLLPUBLIC OutputDevice* GetRefDevice(); // WYSIWYG: Printer, otherwise VirtualDevice...
2114  bool GetNextSpellingCell( SCCOL& nCol, SCROW& nRow, SCTAB nTab,
2115  bool bInSel, const ScMarkData& rMark) const;
2117  void ReplaceStyle( const SvxSearchItem& rSearchItem,
2118  SCCOL nCol, SCROW nRow, SCTAB nTab,
2119  const ScMarkData& rMark);
2121  void InvalidateTextWidth( std::u16string_view rStyleName );
2122  void InvalidateTextWidth( SCTAB nTab );
2123  void InvalidateTextWidth( const ScAddress* pAdrFrom, const ScAddress* pAdrTo, bool bNumFormatChanged );
2125  bool IdleCalcTextWidth();
2127  void RepaintRange( const ScRange& rRange );
2128  void RepaintRange( const ScRangeList& rRange );
2130  bool IsIdleEnabled() const { return mbIdleEnabled; }
2131  void EnableIdle(bool bDo) { mbIdleEnabled = bDo; }
2133  bool IsDetectiveDirty() const { return bDetectiveDirty; }
2134  void SetDetectiveDirty(bool bSet) { bDetectiveDirty = bSet; }
2137  void SetLinkFormulaNeedingCheck(bool bSet) { bLinkFormulaNeedingCheck = bSet; }
2141  void SetRangeOverflowType(ErrCode nType) { nRangeOverflowType = nType; }
2142  bool HasRangeOverflow() const { return nRangeOverflowType != ERRCODE_NONE; }
2145  // for broadcasting/listening
2146  void SetInsertingFromOtherDoc( bool bVal ) { bInsertingFromOtherDoc = bVal; }
2148  void SetLoadingMedium( bool bVal );
2149  SC_DLLPUBLIC void SetImportingXML( bool bVal );
2150  bool IsImportingXML() const { return bImportingXML; }
2151  bool IsCalcingAfterLoad() const { return bCalcingAfterLoad; }
2152  void SetNoListening( bool bVal ) { bNoListening = bVal; }
2153  bool GetNoListening() const { return bNoListening; }
2154  ScBroadcastAreaSlotMachine* GetBASM() const { return pBASM.get(); }
2156  SC_DLLPUBLIC ScChartListenerCollection* GetChartListenerCollection() const { return pChartListenerCollection.get(); }
2157  void SetChartListenerCollection( std::unique_ptr<ScChartListenerCollection>,
2158  bool bSetChartRangeLists );
2159  void UpdateChart( const OUString& rName );
2160  void RestoreChartListener( const OUString& rName );
2163  void SetChartListenerCollectionNeedsUpdate( bool bFlg ) { bChartListenerCollectionNeedsUpdate = bFlg; }
2164  void AddOLEObjectToCollection(const OUString& rName);
2166  ScChangeViewSettings* GetChangeViewSettings() const { return pChangeViewSettings.get(); }
2169  const std::shared_ptr<SvxForbiddenCharactersTable>& GetForbiddenCharacters() const;
2170  void SetForbiddenCharacters(const std::shared_ptr<SvxForbiddenCharactersTable>& rNew);
2173  bool IsValidAsianCompression() const;
2176  bool GetAsianKerning() const;
2177  bool IsValidAsianKerning() const;
2178  void SetAsianKerning(bool bNew);
2181  EEHorizontalTextDirection GetEditTextDirection(SCTAB nTab) const; // EEHorizontalTextDirection values
2184  void SetLinkMode( ScLkUpdMode nSet ) { eLinkMode = nSet;}
2188  void FillMatrix( ScMatrix& rMat, SCTAB nTab, SCCOL nCol1,
2189  SCROW nRow1, SCCOL nCol2, SCROW nRow2,
2190  svl::SharedStringPool* pPool = nullptr) const;
2200  void SC_DLLPUBLIC SetFormulaResults( const ScAddress& rTopPos, const double* pResults, size_t nLen );
2202  void CalculateInColumnInThread( ScInterpreterContext& rContext, const ScRange& rCalcRange, unsigned nThisThread, unsigned nThreadsTotal);
2203  void HandleStuffAfterParallelCalculation( SCCOL nColStart, SCCOL nColEnd, SCROW nRow, size_t nLen, SCTAB nTab, ScInterpreter* pInterpreter );
2210  void TransferCellValuesTo( const ScAddress& rTopPos, size_t nLen, sc::CellValues& rDest );
2211  void CopyCellValuesFrom( const ScAddress& rTopPos, const sc::CellValues& rSrc );
2213  std::set<Color> GetDocColors();
2216 private:
2217  ScDocument(const ScDocument& r) = delete;
2219  void FindMaxRotCol( SCTAB nTab, RowInfo* pRowInfo, SCSIZE nArrCount,
2220  SCCOL nX1, SCCOL nX2 ) const;
2222  sal_uInt16 RowDifferences( SCROW nThisRow, SCTAB nThisTab,
2223  ScDocument& rOtherDoc,
2224  SCROW nOtherRow, SCTAB nOtherTab,
2225  SCCOL nMaxCol, const SCCOLROW* pOtherCols );
2226  sal_uInt16 ColDifferences( SCCOL nThisCol, SCTAB nThisTab,
2227  ScDocument& rOtherDoc,
2228  SCCOL nOtherCol, SCTAB nOtherTab,
2229  SCROW nMaxRow, const SCCOLROW* pOtherRows );
2230  void FindOrder( SCCOLROW* pOtherRows, SCCOLROW nThisEndRow, SCCOLROW nOtherEndRow,
2231  bool bColumns,
2232  ScDocument& rOtherDoc, SCTAB nThisTab, SCTAB nOtherTab,
2233  SCCOLROW nEndCol, const SCCOLROW* pTranslate,
2234  ScProgress* pProgress, sal_uLong nProAdd );
2236  DECL_LINK(TrackTimeHdl, Timer *, void);
2253  bool LimitRangeToAvailableSheets( const ScRange& rRange, ScRange& o_rRange,
2254  bool& o_bEntirelyOutOfBounds ) const;
2256 public:
2257  void StartListeningArea( const ScRange& rRange, bool bGroupListening, SvtListener* pListener );
2259  void EndListeningArea( const ScRange& rRange, bool bGroupListening, SvtListener* pListener );
2265  void Broadcast( const ScHint& rHint );
2267  void BroadcastCells( const ScRange& rRange, SfxHintId nHint, bool bBroadcastSingleBroadcasters = true );
2270  void AreaBroadcast( const ScHint& rHint );
2271  void DelBroadcastAreasInRange( const ScRange& rRange );
2272  void UpdateBroadcastAreas( UpdateRefMode eUpdateRefMode,
2273  const ScRange& rRange,
2274  SCCOL nDx, SCROW nDy, SCTAB nDz );
2276  void StartListeningCell( const ScAddress& rAddress,
2277  SvtListener* pListener );
2278  void EndListeningCell( const ScAddress& rAddress,
2279  SvtListener* pListener );
2281  void StartListeningCell( sc::StartListeningContext& rCxt, const ScAddress& rPos, SvtListener& rListener );
2282  void EndListeningCell( sc::EndListeningContext& rCxt, const ScAddress& rPos, SvtListener& rListener );
2284  void EndListeningFormulaCells( std::vector<ScFormulaCell*>& rCells );
2286  void PutInFormulaTree( ScFormulaCell* pCell );
2287  void RemoveFromFormulaTree( ScFormulaCell* pCell );
2302  SC_DLLPUBLIC void CalcFormulaTree( bool bOnlyForced = false, bool bProgressBar = true, bool bSetAllDirty = true );
2303  void ClearFormulaTree();
2304  void AppendToFormulaTrack( ScFormulaCell* pCell );
2305  void RemoveFromFormulaTrack( ScFormulaCell* pCell );
2306  void TrackFormulas( SfxHintId nHintId = SfxHintId::ScDataChanged );
2309  void FinalTrackFormulas( SfxHintId nHintId );
2311  bool IsInFormulaTree( const ScFormulaCell* pCell ) const;
2312  bool IsInFormulaTrack( const ScFormulaCell* pCell ) const;
2314  void SetHardRecalcState( HardRecalcState eVal ) { eHardRecalcState = eVal; }
2315  void StartAllListeners();
2316  void StartNeededListeners();
2317  void StartNeededListeners( const std::shared_ptr<const sc::ColumnSet>& rpColSet );
2318  SC_DLLPUBLIC void StartAllListeners( const ScRange& rRange );
2320  void SetForcedFormulas( bool bVal ) { bHasForcedFormulas = bVal; }
2323  bool IsInInterpreter() const { return nInterpretLevel != 0; }
2326  {
2327  assert(!IsThreadedGroupCalcInProgress());
2328  if ( nInterpretLevel < USHRT_MAX )
2329  nInterpretLevel++;
2330  }
2332  {
2333  assert(!IsThreadedGroupCalcInProgress());
2334  if ( nInterpretLevel )
2335  nInterpretLevel--;
2336  }
2337  sal_uInt16 GetMacroInterpretLevel() const { return nMacroInterpretLevel; }
2339  {
2340  assert(!IsThreadedGroupCalcInProgress());
2341  if ( nMacroInterpretLevel < USHRT_MAX )
2342  nMacroInterpretLevel++;
2343  }
2345  {
2346  assert(!IsThreadedGroupCalcInProgress());
2347  if ( nMacroInterpretLevel )
2348  nMacroInterpretLevel--;
2349  }
2350  bool IsInInterpreterTableOp() const { return nInterpreterTableOpLevel != 0; }
2352  {
2353  if ( nInterpreterTableOpLevel < USHRT_MAX )
2354  nInterpreterTableOpLevel++;
2355  }
2357  {
2358  if ( nInterpreterTableOpLevel )
2359  nInterpreterTableOpLevel--;
2360  }
2362  // add a formula to be remembered for TableOp broadcasts
2364  void InvalidateLastTableOpParams() { aLastTableOpParams.bValid = false; }
2366  bool IsInDtorClear() const { return bInDtorClear; }
2367  void SetExpandRefs( bool bVal );
2368  bool IsExpandRefs() const { return bExpandRefs; }
2372  {
2373  if ( nXMLImportedFormulaCount + nVal > nXMLImportedFormulaCount )
2374  nXMLImportedFormulaCount += nVal;
2375  }
2377  {
2378  if ( nVal <= nXMLImportedFormulaCount )
2379  nXMLImportedFormulaCount -= nVal;
2380  else
2381  nXMLImportedFormulaCount = 0;
2382  }
2384  void StartTrackTimer();
2386  void CompileDBFormula();
2387  void CompileColRowNameFormula();
2393  sal_Int32 GetMaxStringLen( SCTAB nTab, SCCOL nCol,
2394  SCROW nRowStart, SCROW nRowEnd,
2395  rtl_TextEncoding eCharSet ) const;
2399  sal_Int32 GetMaxNumberStringLen( sal_uInt16& nPrecision,
2400  SCTAB nTab, SCCOL nCol,
2401  SCROW nRowStart, SCROW nRowEnd ) const;
2403  void KeyInput(); // TimerDelays etc.
2405  ScChangeTrack* GetChangeTrack() const { return pChangeTrack.get(); }
2409  SC_DLLPUBLIC void SetChangeTrack( std::unique_ptr<ScChangeTrack> pTrack );
2411  void StartChangeTracking();
2412  void EndChangeTracking();
2414  SC_DLLPUBLIC void CompareDocument( ScDocument& rOtherDoc );
2416  void AddUnoObject( SfxListener& rObject );
2417  void RemoveUnoObject( SfxListener& rObject );
2418  void BroadcastUno( const SfxHint &rHint );
2419  void AddUnoListenerCall( const css::uno::Reference<
2420  css::util::XModifyListener >& rListener,
2421  const css::lang::EventObject& rEvent );
2423  void SetInLinkUpdate(bool bSet); // TableLink or AreaLink
2424  bool IsInLinkUpdate() const; // including DdeLink
2431  std::unique_ptr<ScRefreshTimerControl> const & GetRefreshTimerControlAddress() const
2432  { return pRefreshTimerControl; }
2434  void SetPastingDrawFromOtherDoc( bool bVal )
2435  { bPastingDrawFromOtherDoc = bVal; }
2437  { return bPastingDrawFromOtherDoc; }
2440  sal_uInt32 GetDocumentID() const;
2442  void InvalidateStyleSheetUsage() { bStyleSheetUsageInvalid = true; }
2443  void SC_DLLPUBLIC GetSortParam( ScSortParam& rParam, SCTAB nTab );
2444  void SC_DLLPUBLIC SetSortParam( const ScSortParam& rParam, SCTAB nTab );
2446  void SetVbaEventProcessor( const css::uno::Reference< css::script::vba::XVBAEventProcessor >& rxVbaEvents )
2447  { mxVbaEvents = rxVbaEvents; }
2448  const css::uno::Reference< css::script::vba::XVBAEventProcessor >& GetVbaEventProcessor() const { return mxVbaEvents; }
2455  bool IsInVBAMode() const;
2458  void AddSubTotalCell(ScFormulaCell* pCell);
2459  void RemoveSubTotalCell(ScFormulaCell* pCell);
2460  void SetSubTotalCellsDirty(const ScRange& rDirtyRange);
2462  sal_uInt16 GetTextWidth( const ScAddress& rPos ) const;
2464  SvtScriptType GetScriptType( const ScAddress& rPos ) const;
2465  void SetScriptType( const ScAddress& rPos, SvtScriptType nType );
2466  void UpdateScriptTypes( const ScAddress& rPos, SCCOL nColSize, SCROW nRowSize );
2478  void UnshareFormulaCells( SCTAB nTab, SCCOL nCol, std::vector<SCROW>& rRows );
2479  void RegroupFormulaCells( SCTAB nTab, SCCOL nCol );
2480  void RegroupFormulaCells( const ScRange& range );
2486  bool HandleRefArrayForParallelism( const ScAddress& rPos, SCROW nLength, const ScFormulaCellGroupRef& mxGroup );
2487 #ifdef DBG_UTIL
2488  void AssertNoInterpretNeeded( const ScAddress& rPos, SCROW nLength );
2489 #endif
2495  void PrepareFormulaCalc();
2511  SC_DLLPUBLIC bool EnsureFormulaCellResults( const ScRange& rRange, bool bSkipRunning = false );
2513  SvtBroadcaster* GetBroadcaster( const ScAddress& rPos );
2514  const SvtBroadcaster* GetBroadcaster( const ScAddress& rPos ) const;
2515  void DeleteBroadcasters( sc::ColumnBlockPosition& rBlockPos, const ScAddress& rTopPos, SCROW nLength );
2517  std::optional<sc::ColumnIterator> GetColumnIterator( SCTAB nTab, SCCOL nCol, SCROW nRow1, SCROW nRow2 ) const;
2518  void CreateColumnIfNotExists( SCTAB nTab, SCCOL nCol );
2520  SC_DLLPUBLIC void StoreTabToCache(SCTAB nTab, SvStream& rStrm) const;
2521  SC_DLLPUBLIC void RestoreTabFromCache(SCTAB nTab, SvStream& rStream);
2524  SC_DLLPUBLIC void DumpColumnStorage( SCTAB nTab, SCCOL nCol ) const;
2525 #endif
2528  SC_DLLPUBLIC void DumpAreaBroadcasters() const;
2529 #endif
2531  SC_DLLPUBLIC void SetCalcConfig( const ScCalcConfig& rConfig );
2532  const ScCalcConfig& GetCalcConfig() const { return maCalcConfig; }
2533  void ConvertFormulaToValue( const ScRange& rRange, sc::TableValues* pUndo );
2534  void SwapNonEmpty( sc::TableValues& rValues );
2535  void finalizeOutlineImport();
2536  bool TableExists( SCTAB nTab ) const;
2538  SC_DLLPUBLIC ScColumnsRange GetColumnsRange(SCTAB nTab, SCCOL nColBegin, SCCOL nColEnd) const;
2540  bool IsInDocShellRecalc() const { return mbDocShellRecalc; }
2541  void SetDocShellRecalc(bool bSet) { mbDocShellRecalc = bSet; }
2551  OString dumpSheetGeomData(SCTAB nTab, bool bColumns, SheetGeomType eGeomType);
2553  SCCOL GetLOKFreezeCol(SCTAB nTab) const;
2554  SCROW GetLOKFreezeRow(SCTAB nTab) const;
2555  bool SetLOKFreezeCol(SCCOL nFreezeCol, SCTAB nTab);
2556  bool SetLOKFreezeRow(SCROW nFreezeRow, SCTAB nTab);
2558 private:
2566  {
2567  public:
2568  explicit NumFmtMergeHandler(ScDocument& rDoc, const ScDocument& rSrcDoc);
2571  private:
2573  };
2575  ScTable* FetchTable( SCTAB nTab );
2576  const ScTable* FetchTable( SCTAB nTab ) const;
2578  void MergeNumberFormatter(const ScDocument& rSrcDoc);
2580  void ImplCreateOptions(); // Suggestion: switch to on-demand?
2581  void ImplDeleteOptions();
2583  void DeleteDrawLayer();
2584  SC_DLLPUBLIC bool DrawGetPrintArea( ScRange& rRange, bool bSetHor, bool bSetVer ) const;
2586  void UpdateDrawPrinter();
2587  void UpdateDrawLanguages();
2588  SC_DLLPUBLIC void InitClipPtrs( ScDocument* pSourceDoc );
2590  void LoadDdeLinks(SvStream& rStream);
2591  void SaveDdeLinks(SvStream& rStream) const;
2593  void DeleteAreaLinksOnTab( SCTAB nTab );
2594  void UpdateRefAreaLinks( UpdateRefMode eUpdateRefMode,
2595  const ScRange& r, SCCOL nDx, SCROW nDy, SCTAB nDz );
2597  void CopyRangeNamesToClip(ScDocument* pClipDoc, const ScRange& rClipRange, const ScMarkData* pMarks);
2599  bool HasPartOfMerged( const ScRange& rRange );
2601  ScRefCellValue GetRefCellValue( const ScAddress& rPos );
2604  std::map< SCTAB, ScSortParam > mSheetSortParams;
2606  SCSIZE GetPatternCount( SCTAB nTab, SCCOL nCol ) const;
2607  SCSIZE GetPatternCount( SCTAB nTab, SCCOL nCol, SCROW nRow1, SCROW nRow2 ) const;
2608  void ReservePatternCount( SCTAB nTab, SCCOL nCol, SCSIZE nReserve );
2610  void SharePooledResources( const ScDocument* pSrcDoc );
2613  sc::EndListeningContext& rCxt, const ScAddress& rPos, std::vector<ScAddress>* pGroupPos );
2616  sc::EndListeningContext& rCxt, const ScRange& rRange, std::vector<ScAddress>* pGroupPos );
2618  void EndListeningGroups( const std::vector<ScAddress>& rPosArray );
2619  void SetNeedsListeningGroups( const std::vector<ScAddress>& rPosArray );
2620 };
2622 typedef std::unique_ptr<ScDocument, o3tl::default_delete<ScDocument>> ScDocumentUniquePtr;
2630 {
2631 #ifndef NDEBUG
2633  : mnFlagRestore(rDocument.mnMutationGuardFlags)
2634  , mrDocument(rDocument)
2635  {
2636  assert((mnFlagRestore & nFlags) == 0);
2637  mrDocument.mnMutationGuardFlags |= static_cast<size_t>(nFlags);
2638  }
2640  {
2642  }
2645 #else
2647  {
2648  (void)rDocument; (void)nFlags;
2649  }
2650 #endif
2651 };
2663 {
2664 #ifndef NDEBUG
2666  : mnFlags(static_cast<size_t>(nFlags))
2667  , mrDocument(rDocument)
2668  {
2669  assert((mrDocument.mnMutationGuardFlags & mnFlags) == 0);
2670  }
2673  {
2674  assert((mrDocument.mnMutationGuardFlags & mnFlags) == 0);
2675  }
2676  size_t mnFlags;
2678 #else
2679  ScMutationGuard(ScDocument& rDocument, ScMutationGuardFlags nFlags)
2680  {
2681  (void)rDocument; (void)nFlags;
2682  }
2683 #endif
2684 };
2687 {
2690 public:
2692  : mrDoc(rDoc)
2693  {
2694  assert(!mrDoc.IsInDocShellRecalc());
2695  mrDoc.SetDocShellRecalc(true);
2696  }
2699  {
2700  mrDoc.SetDocShellRecalc(false);
2701  }
2702 };
2704 /* 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:3327
SC_DLLPUBLIC OUString GetLinkDoc(SCTAB nTab) const
Definition: documen3.cxx:511
SC_DLLPUBLIC bool IsDocProtected() const
Definition: documen3.cxx:1903
void SetupContextFromNonThreadedContext(ScInterpreterContext &threadedContext, int threadNumber)
Definition: document.cxx:6862
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:576
void SetThreadedGroupCalcInProgress(bool set)
Definition: document.hxx:616
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:541
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:4781
bool mbEmbedFontScriptComplex
Definition: document.hxx:558
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:2540
void ClearDetectiveOperations()
Definition: documen4.cxx:909
void RemoveMerge(SCCOL nCol, SCROW nRow, SCTAB nTab)
Definition: documen3.cxx:2093
ScCalcConfig maCalcConfig
Definition: document.hxx:363
bool IsBlockEditable(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool *pOnlyNotBecauseOfMatrix=nullptr, bool bNoMatrixAtAll=false) const
Definition: document.cxx:5353
ScMutationGuard(ScDocument &rDocument, ScMutationGuardFlags nFlags)
Definition: document.hxx:2665
void AssertNoInterpretNeeded(const ScAddress &rPos, SCROW nLength)
Definition: document.cxx:1781
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:4329
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:1805
std::shared_ptr< SvxForbiddenCharactersTable > xForbiddenCharacters
Definition: document.hxx:398
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:1017
std::unique_ptr< ScFieldEditEngine > mpEditEngine
Definition: document.hxx:366
void EnableIdle(bool bDo)
Definition: document.hxx:2131
void ClearLookupCaches()
Zap all caches.
Definition: documen2.cxx:1197
void UpdatePageBreaks(SCTAB nTab, const ScRange *pUserArea=nullptr)
Definition: document.cxx:6247
static SC_DLLPUBLIC bool bThreadedGroupCalcInProgress
Calc's threaded group calculation is in progress.
Definition: global.hxx:819
SC_DLLPUBLIC void ApplySelectionStyle(const ScStyleSheet &rStyle, const ScMarkData &rMark)
Definition: document.cxx:4890
VclPtr< SfxPrinter > mpPrinter
Definition: document.hxx:369
bool HasExternalRefManager() const
Definition: document.hxx:1002
bool bIsUndo
Definition: document.hxx:491
void ApplyStyle(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScStyleSheet &rStyle)
Definition: document.cxx:4860
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:5698
bool bStyleSheetUsageInvalid
Definition: document.hxx:541
void ExtendHidden(SCCOL &rX1, SCROW &rY1, SCCOL &rX2, SCROW &rY2, SCTAB nTab)
Definition: document.cxx:4737
void StripHidden(SCCOL &rX1, SCROW &rY1, SCCOL &rX2, SCROW &rY2, SCTAB nTab)
Definition: document.cxx:4731
void ClearSelectionItems(const sal_uInt16 *pWhich, const ScMarkData &rMark)
Definition: document.cxx:5946
sal_uLong GetXMLImportedFormulaCount() const
Definition: document.hxx:2370
::boost::intrusive_ptr< ScFormulaCellGroup > ScFormulaCellGroupRef
Definition: types.hxx:43
SCCOL SanitizeCol(SCCOL nCol) const
Definition: document.hxx:880
SC_DLLPUBLIC void ApplyStyleAreaTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, const ScStyleSheet &rStyle)
Definition: document.cxx:4882
ScFormulaCell * pFormulaTree
Definition: document.hxx:383
void CalculateInColumnInThread(ScInterpreterContext &rContext, const ScRange &rCalcRange, unsigned nThisThread, unsigned nThreadsTotal)
Definition: documen8.cxx:413
SC_DLLPUBLIC bool HasColHeader(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: documen3.cxx:1532
void FitBlock(const ScRange &rOld, const ScRange &rNew, bool bClear=true)
Definition: document.cxx:1836
SC_DLLPUBLIC const ScRange * GetRepeatColRange(SCTAB nTab)
Definition: document.cxx:6313
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:814
void DeleteConditionalFormat(sal_uLong nIndex, SCTAB nTab)
Definition: documen4.cxx:890
SC_DLLPUBLIC void ShowRows(SCROW nRow1, SCROW nRow2, SCTAB nTab, bool bShow)
Definition: document.cxx:4341
SfxItemSet * GetPreviewFont()
Definition: document.hxx:1340
void GetClipStart(SCCOL &nClipX, SCROW &nClipY)
Definition: document.cxx:3201
void IncXMLImportedFormulaCount(sal_uLong nVal)
Definition: document.hxx:2371
bool HasScenarioRange(SCTAB nTab, const ScRange &rRange) const
Definition: documen3.cxx:864
bool HasUnoRefUndo() const
Definition: document.hxx:1064
void EndChangeTracking()
Definition: documen2.cxx:270
SC_DLLPUBLIC void ApplyPatternIfNumberformatIncompatible(const ScRange &rRange, const ScMarkData &rMark, const ScPatternAttr &rPattern, SvNumFormatType nNewType)
Definition: document.cxx:4825
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:644
std::unique_ptr< ScChangeTrack > pChangeTrack
Definition: document.hxx:391
SC_DLLPUBLIC svl::SharedStringPool & GetSharedStringPool()
Definition: documen2.cxx:566
void SetForcedFormulas(bool bVal)
Definition: document.hxx:2320
sal_uLong nFormulaCount
Definition: document.hxx:280
void SetConsolidateDlgData(std::unique_ptr< ScConsolidateParam > pData)
Definition: documen2.cxx:1109
SC_DLLPUBLIC bool IsTabProtected(SCTAB nTab) const
Definition: documen3.cxx:1914
SC_DLLPUBLIC void GetInputString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rString)
Definition: document.cxx:3571
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:5082
Store parameters used in the ScDocument::SetString() method.
Definition: stringutil.hxx:34
SC_DLLPUBLIC bool HasPrintRange()
Definition: document.cxx:6276
sal_uInt16 nInterpretLevel
Definition: document.hxx:460
void HandleStuffAfterParallelCalculation(SCCOL nColStart, SCCOL nColEnd, SCROW nRow, size_t nLen, SCTAB nTab, ScInterpreter *pInterpreter)
Definition: documen8.cxx:433
SC_DLLPUBLIC CRFlags GetColFlags(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4359
VclPtr< VirtualDevice > mpVirtualDevice_100th_mm
Definition: document.hxx:370
void SetEmbedUsedFontsOnly(bool bUse)
Definition: document.hxx:580
bool IsInInterpreter() const
Definition: document.hxx:2323
bool bChartListenerCollectionNeedsUpdate
Definition: document.hxx:507
void LoadDdeLinks(SvStream &rStream)
Definition: documen8.cxx:749
void SetCutMode(bool bCut)
Definition: document.cxx:2029
Definition: global.hxx:193
SC_DLLPUBLIC bool IsNegativePage(SCTAB nTab) const
Definition: document.cxx:994
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:543
bool bInDtorClear
Definition: document.hxx:511
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:404
ScValidationDataList * GetValidationList()
Definition: document.hxx:1804
SC_DLLPUBLIC ScRangeName * GetRangeName() const
Definition: documen3.cxx:176
ScInterpreterContext & GetThreadedContext() const
Definition: document.hxx:610
SCTAB nVisibleTab
Definition: document.hxx:477
OUString maFileURL
Definition: document.hxx:416
void SetEmbedFontScriptComplex(bool bUse)
Definition: document.hxx:583
std::unique_ptr< ScRefreshTimerControl > const & GetRefreshTimerControlAddress() const
Definition: document.hxx:2431
bool UpdateOutlineCol(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bShow)
Adapt Outline.
Definition: documen3.cxx:1416
SC_DLLPUBLIC void SetChangeViewSettings(const ScChangeViewSettings &rNew)
Definition: documen2.cxx:1114
void SetPreviewSelection(const ScMarkData &rSel)
Definition: documen2.cxx:1361
SCSIZE Query(SCTAB nTab, const ScQueryParam &rQueryParam, bool bKeepSub)
Definition: documen3.cxx:1470
SC_DLLPUBLIC void SetTabProtection(SCTAB nTab, const ScTableProtection *pProtect)
Definition: documen3.cxx:1931
const OUString & GetFileURL() const
Definition: document.hxx:598
void CopyCellToDocument(const ScAddress &rSrcPos, const ScAddress &rDestPos, ScDocument &rDestDoc)
Copy only cell, nothing but cell to another document.
Definition: document.cxx:2237
SC_DLLPUBLIC void DoMergeContents(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow)
Definition: documen3.cxx:2039
Definition: global.hxx:318
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:2448
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:2816
SCROW FirstNonFilteredRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4562
ScTable * FetchTable(SCTAB nTab)
Definition: document.cxx:2521
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:6235
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:2132
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:319
std::unique_ptr< ScClipParam > mpClipParam
Definition: document.hxx:405
void SetInLinkUpdate(bool bSet)
Definition: documen8.cxx:778
sheet protection state container
Definition: drwlayer.hxx:89
std::unique_ptr< ScFieldEditEngine > pCacheFieldEditEngine
Definition: document.hxx:402
SC_DLLPUBLIC void SetTabBgColor(SCTAB nTab, const Color &rColor)
Definition: documen3.cxx:455
SfxObjectShell * mpShell
Definition: document.hxx:368
ScRangePairList * GetColNameRanges()
Definition: document.hxx:806
std::optional< sc::ColumnIterator > GetColumnIterator(SCTAB nTab, SCCOL nCol, SCROW nRow1, SCROW nRow2) const
Definition: document10.cxx:966
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:592
ScInterpreterContext maInterpreterContext
Definition: document.hxx:470
SC_DLLPUBLIC const ScFormulaCell * GetFormulaCell(const ScAddress &rPos) const
Definition: document.cxx:3754
Think of this as a mini-ScColumn like storage that only stores cell values in a column.
Definition: cellvalues.hxx:40
Definition: global.hxx:236
bool IsAddressInRangeName(RangeNameScope eScope, const ScAddress &rAddress)
Definition: documen3.cxx:196
void CopyScenario(SCTAB nSrcTab, SCTAB nDestTab, bool bNewScenario=false)
Definition: documen3.cxx:808
SC_DLLPUBLIC sal_uLong GetFormulaGroupCount() const
Definition: document.cxx:6174
bool IsExpandRefs() const
Definition: document.hxx:2368
SC_DLLPUBLIC void CopyStdStylesFrom(const ScDocument &rSrcDoc)
Definition: documen8.cxx:290
bool IsEmbedFontScriptLatin() const
Definition: document.hxx:575
void FillMatrix(ScMatrix &rMat, SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, svl::SharedStringPool *pPool=nullptr) const
Definition: documen8.cxx:386
void CompileColRowNameFormula()
Definition: documen4.cxx:568
SC_DLLPUBLIC void SetLayoutRTL(SCTAB nTab, bool bRTL, ScObjectHandling eObjectHandling=ScObjectHandling::RecalcPosMode)
Definition: document.cxx:950
ScDetOpList * GetDetOpList() const
Definition: document.hxx:1776
SC_DLLPUBLIC bool IsUserInteractionEnabled() const
Definition: document.hxx:1546
SCROW GetLOKFreezeRow(SCTAB nTab) const
bool IsPageStyleInUse(std::u16string_view rStrPageStyle, SCTAB *pInTab)
Definition: documen8.cxx:312
sc::IconSetBitmapMap & GetIconSetBitmapMap()
Definition: documen2.cxx:1387
SC_DLLPUBLIC bool HasTabNotes(SCTAB nTab) const
Definition: document.cxx:6606
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:878
bool mbUserInteractionEnabled
Definition: document.hxx:547
Context for reference update during shifting, moving or copying of cell ranges.
SC_DLLPUBLIC std::vector< OUString > GetAllTableNames() const
Definition: document.cxx:287
SC_DLLPUBLIC bool ValidNewTabName(const OUString &rName) const
Definition: document.cxx:374
const sal_uInt8 SC_DDE_DEFAULT
Definition: document.hxx:292
SC_DLLPUBLIC void ClearPrintRanges(SCTAB nTab)
Removes all print ranges.
Definition: document.cxx:6329
void SetName(const OUString &r)
Definition: document.hxx:595
SC_DLLPUBLIC bool ApplyFlagsTab(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, ScMF nFlags)
Definition: document.cxx:5038
Enumeration to determine which pieces of the code should not be mutated when set. ...
Definition: document.hxx:305
SC_DLLPUBLIC bool InitColumnBlockPosition(sc::ColumnBlockPosition &rBlockPos, SCTAB nTab, SCCOL nCol)
Definition: document.cxx:2627
bool mbStreamValidLocked
Definition: document.hxx:546
exports embed
std::shared_ptr< sc::FormulaGroupContext > & GetFormulaGroupContext()
Definition: document.cxx:3555
SC_DLLPUBLIC ScDPCollection * GetDPCollection()
Definition: documen3.cxx:365
bool IsUndo() const
Definition: document.hxx:1533
List of RefUpdate changes made to UNO objects during ScUpdateRefHint broadcast.
Definition: unoreflist.hxx:41
sal_Int16 mnNamedRangesLockCount
Definition: document.hxx:549
ScInterpreterContext * pContext
Definition: document.hxx:301
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:995
void ApplySelectionLineStyle(const ScMarkData &rMark, const ::editeng::SvxBorderLine *pLine, bool bColorOnly)
Definition: document.cxx:4913
static const sal_uInt16 nSrcVer
Definition: document.hxx:474
SC_DLLPUBLIC void InitUndo(const ScDocument &rSrcDoc, SCTAB nTab1, SCTAB nTab2, bool bColInfo=false, bool bRowInfo=false)
Definition: document.cxx:1984
bool IsInDdeLinkUpdate() const
Definition: document.hxx:1019
SC_DLLPUBLIC void SetColHidden(SCCOL nStartCol, SCCOL nEndCol, SCTAB nTab, bool bHidden)
Definition: document.cxx:4498
rtl::Reference< XColorList > pColorList
Definition: document.hxx:372
void BlockFormulaGroupContextDiscard(bool block)
Definition: document.hxx:1189
normal calculation of dependencies
void ModifyStyleSheet(SfxStyleSheetBase &rPageStyle, const SfxItemSet &rChanges)
Definition: documen8.cxx:211
void SetDirtyFromClip(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, InsertDeleteFlags nInsFlag, sc::ColumnSpanSet &rBroadcastSpans)
Definition: document.cxx:2610
const ScMarkData & GetPreviewSelection() const
Definition: document.hxx:1342
void SetPendingRowHeights(SCTAB nTab, bool bSet)
Definition: document.cxx:944
rtl_TextEncoding eSrcSet
Definition: document.hxx:452
bool IsTrackFormulasPending() const
Definition: document.hxx:2308
sal_uLong GetCodeCount() const
Definition: document.cxx:6187
sal_uInt16 nFormulaTrackCount
Definition: document.hxx:475
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:1360
ScDocumentThreadSpecific maNonThreaded
Definition: document.hxx:464
bool HasPartOfMerged(const ScRange &rRange)
Definition: document.cxx:1730
void DecInterpreterTableOpLevel()
Definition: document.hxx:2356
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:3033
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:1532
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:2143
Stores cell values for multiple tables.
Definition: cellvalues.hxx:85
SC_DLLPUBLIC void SetRepeatColRange(SCTAB nTab, std::unique_ptr< ScRange > pNew)
Definition: document.cxx:6347
SC_DLLPUBLIC SCROW FirstVisibleRow(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4506
SC_DLLPUBLIC void GetNumberFormat(SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt32 &rFormat) const
Definition: document.cxx:3672
OString dumpSheetGeomData(SCTAB nTab, bool bColumns, SheetGeomType eGeomType)
Serializes the specified sheet's geometry data.
SvtBroadcaster * GetBroadcaster(const ScAddress &rPos)
Definition: document.cxx:2470
SC_DLLPUBLIC sal_uLong AddCondFormat(std::unique_ptr< ScConditionalFormat > pNew, SCTAB nTab)
Definition: documen4.cxx:716
SC_DLLPUBLIC bool DeleteTabs(SCTAB nTab, SCTAB nSheets)
Definition: document.cxx:761
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:4514
bool bLoadingMedium
Definition: document.hxx:500
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:502
HardRecalcState eHardRecalcState
Definition: document.hxx:476
VirtualDevice * GetVirtualDevice_100th_mm()
Definition: documen8.cxx:183
SC_DLLPUBLIC double * GetValueCell(const ScAddress &rPos)
Return a pointer to the double value stored in value cell.
Definition: document.cxx:3539
Stores options which are only relevant for clipboard documents.
Definition: clipoptions.hxx:21
ScDocShellRecalcGuard(ScDocument &rDoc)
Definition: document.hxx:2691
SC_DLLPUBLIC void SetValue(SCCOL nCol, SCROW nRow, SCTAB nTab, const double &rVal)
Definition: document.cxx:3489
SC_DLLPUBLIC void InsertTableOp(const ScTabOpParam &rParam, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark)
Definition: documen4.cxx:357
sal_Int64 GetNewUnoId()
Definition: document.hxx:1067
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:984
sal_uInt16 nInterpreterTableOpLevel
Definition: document.hxx:462
bool IsHorOverlapped(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:5755
void GetEmbedded(ScRange &rRange) const
Definition: documen3.cxx:1709
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:1487
SC_DLLPUBLIC ScDBData * GetAnonymousDBData()
Definition: document.cxx:330
std::unique_ptr< ScExtDocOptions > pExtDocOptions
Definition: document.hxx:422
SC_DLLPUBLIC ScRange GetRange(SCTAB nTab, const tools::Rectangle &rMMRect, bool bHiddenAsZero=true) const
Definition: documen3.cxx:1806
std::unique_ptr< ScValidationDataList > pValidationList
Definition: document.hxx:373
void AppendToFormulaTrack(ScFormulaCell *pCell)
Definition: documen7.cxx:451
const sal_uInt8 SC_DDE_TEXT
Definition: document.hxx:294
SC_DLLPUBLIC void ApplyAttr(SCCOL nCol, SCROW nRow, SCTAB nTab, const SfxPoolItem &rAttr)
Definition: document.cxx:4788
Accessor class to ScDocument.
bool bImportingXML
Definition: document.hxx:501
void SetPreviewFont(std::unique_ptr< SfxItemSet > pFontSet)
Definition: documen2.cxx:1356
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:228
void SetClipOptions(std::unique_ptr< ScClipOptions > pClipOptions)
Definition: documen3.cxx:2034
bool IsLinked(SCTAB nTab) const
Definition: documen3.cxx:485
SC_DLLPUBLIC SfxUndoManager * GetUndoManager()
Definition: document.cxx:6402
SC_DLLPUBLIC void SetRowBreak(SCROW nRow, SCTAB nTab, bool bPage, bool bManual)
Definition: document.cxx:4420
void SetPrinter(VclPtr< SfxPrinter > const &pNewPrinter)
Definition: documen8.cxx:143
css::uno::Reference< css::embed::XEmbeddedObject > FindOleObjectByName(std::u16string_view rName)
Definition: documen5.cxx:534
bool HasStringWeakCharacters(const OUString &rString)
Definition: documen6.cxx:51
css::uno::Sequence< css::sheet::TablePageBreakData > GetRowBreakData(SCTAB nTab) const
Definition: document.cxx:4452
ScFormulaCell * pEOFormulaTrack
Definition: document.hxx:386
void SetHardRecalcState(HardRecalcState eVal)
Definition: document.hxx:2314
SCSIZE GetPatternCount(SCTAB nTab, SCCOL nCol) const
Definition: documen3.cxx:2116
void GetClipArea(SCCOL &nClipX, SCROW &nClipY, bool bIncludeFiltered)
Definition: document.cxx:3149
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:2604
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:901
SC_DLLPUBLIC formula::FormulaGrammar::AddressConvention GetAddressConvention() const
Definition: documen3.cxx:494
bool ValidColRowTab(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.hxx:877
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:71
sal_uLong nXMLImportedFormulaCount
Definition: document.hxx:459
SC_DLLPUBLIC bool HasAttrib(SCCOL nCol1, SCROW nRow1, SCTAB nTab1, SCCOL nCol2, SCROW nRow2, SCTAB nTab2, HasAttrFlags nMask) const
Definition: document.cxx:5205
bool HasAutoFilter(SCCOL nCol, SCROW nRow, SCTAB nTab)
Definition: documen3.cxx:1500
std::unique_ptr< ScPrintRangeSaver > CreatePrintRangeSaver() const
Definition: document.cxx:6359
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:6806
void EndListeningGroups(const std::vector< ScAddress > &rPosArray)
Definition: document10.cxx:488
bool TableExists(SCTAB nTab) const
Definition: document.cxx:2516
void UpdateChart(const OUString &rName)
Definition: documen5.cxx:333
SC_DLLPUBLIC SvtScriptType GetStringScriptType(const OUString &rString)
Definition: documen6.cxx:76
SvNumberFormatterIndexTable * pFormatExchangeList
Definition: document.hxx:374
SC_DLLPUBLIC void GetFormula(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rFormula) const
Definition: document.cxx:3746
bool IsAdjustHeightLocked() const
Definition: document.hxx:1539
SC_DLLPUBLIC ScBreakType HasRowBreak(SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4390
SC_DLLPUBLIC sal_uInt16 GetRowHeight(SCROW nRow, SCTAB nTab, bool bHiddenAsZero=true) const
Definition: document.cxx:4192
void StartAnimations(SCTAB nTab)
Definition: documen9.cxx:319
SC_DLLPUBLIC ScNoteEditEngine & GetNoteEngine()
Definition: documen2.cxx:470
void SetClipParam(const ScClipParam &rParam)
Definition: document.cxx:2573
bool mbChangeReadOnlyEnabled
Definition: document.hxx:545
ScAddress aCurTextWidthCalcPos
Definition: document.hxx:436
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:3462
exports sheet
void MixDocument(const ScRange &rRange, ScPasteFunc nFunction, bool bSkipEmpty, ScDocument &rSrcDoc)
Definition: document.cxx:3239
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:5273
bool GetNextSpellingCell(SCCOL &nCol, SCROW &nRow, SCTAB nTab, bool bInSel, const ScMarkData &rMark) const
Definition: documen4.cxx:532
std::unique_ptr< SfxBroadcaster > pUnoBroadcaster
Definition: document.hxx:392
Row-wise value iterator.
Definition: dociter.hxx:478
SC_DLLPUBLIC void CopyStaticToDocument(const ScRange &rSrcRange, SCTAB nDestTab, ScDocument &rDestDoc)
Copy only raw cell values to another document.
Definition: document.cxx:2221
void UnlockTable(SCTAB nTab)
Definition: document.cxx:5343
bool HasAnySheetEventScript(ScSheetEventId nEvent, bool bWithVbaEvents=false) const
Definition: documen3.cxx:696
bool IsExecuteLinkEnabled() const
Definition: document.hxx:1542
SC_DLLPUBLIC ScDocumentPool * GetPool()
Definition: document.cxx:6087
void Sort(SCTAB nTab, const ScSortParam &rSortParam, bool bKeepQuery, bool bUpdateRefs, ScProgress *pProgress, sc::ReorderParam *pUndo)
Sort a range of data.
Definition: documen3.cxx:1434
void TransliterateText(const ScMarkData &rMultiMark, TransliterationFlags nType)
Definition: documen8.cxx:1212
SC_DLLPUBLIC const ScValidationData * GetValidationEntry(sal_uLong nIndex) const
Definition: documen4.cxx:882
LanguageType eCjkLanguage
Definition: document.hxx:450
void InvalidateTableArea()
Definition: documen4.cxx:578
ScLkUpdMode eLinkMode
Definition: document.hxx:481
SC_DLLPUBLIC bool IsManualRowHeight(SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4586
SfxPrinter * GetPrinter(bool bCreateIfNotExist=true)
Definition: documen8.cxx:115
void DeleteDrawLayer()
Definition: documen9.cxx:229
SC_DLLPUBLIC void SetImportingXML(bool bVal)
Definition: documen9.cxx:592
void SetAllFormulasDirty(const sc::SetFormulaDirtyContext &rCxt)
Definition: document.cxx:3866
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:4929
SC_DLLPUBLIC bool GetPrintAreaVer(SCTAB nTab, SCCOL nStartCol, SCCOL nEndCol, SCROW &rEndRow, bool bNotes) const
Definition: documen2.cxx:622
void RepaintRange(const ScRange &rRange)
Definition: documen8.cxx:691
sal_uInt16 sal_Unicode
bool IsPendingRowHeights(SCTAB nTab) const
Definition: document.cxx:936
SC_DLLPUBLIC ScPostIt * GetNote(const ScAddress &rPos)
Definition: document.cxx:6534
void SetEmbedFontScriptLatin(bool bUse)
Definition: document.hxx:581
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:868
CommentCaptionState GetAllNoteCaptionsState(const ScRangeList &rRanges)
Definition: document.cxx:6689
SC_DLLPUBLIC void CheckLinkFormulaNeedingCheck(const ScTokenArray &rCode)
Check token array and set link check if ocDde/ocWebservice is contained.
Definition: documen8.cxx:1156
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:1796
bool bForcedFormulaPending
Definition: document.hxx:488
std::unordered_map< ScColumn *, std::pair< SCROW, SCROW > > pDelayedStartListeningFormulaCells
Definition: document.hxx:525
const std::shared_ptr< SvxForbiddenCharactersTable > & GetForbiddenCharacters() const
Definition: documen9.cxx:615
void SetChartListenerCollectionNeedsUpdate(bool bFlg)
Definition: document.hxx:2163
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:853
formula::FormulaGrammar::Grammar eGrammar
Definition: document.hxx:539
ScClipParam & GetClipParam()
Definition: document.cxx:2565
SC_DLLPUBLIC sal_uInt16 GetOriginalWidth(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4168
void InvalidateStyleSheetUsage()
Definition: document.hxx:2442
void UpdateReference(sc::RefUpdateContext &rCxt, ScDocument *pUndoDoc=nullptr, bool bIncludeDraw=true, bool bUpdateNoteCaptionPos=true)
Definition: documen3.cxx:1005
ScDocument & mrDocument
Definition: document.hxx:2644
Definition: document.hxx:872
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
void SetNamedRangesLockCount(sal_Int16 nCount)
Definition: document.hxx:1549
void SetCodeName(const OUString &r)
Definition: document.hxx:597
SC_DLLPUBLIC SCTAB GetTableCount() const
Definition: document.cxx:314
SC_DLLPUBLIC SCROW GetLastFlaggedRow(SCTAB nTab) const
Definition: document.cxx:4603
SvtScriptType GetRangeScriptType(sc::ColumnBlockPosition &rBlockPos, const ScAddress &rPos, SCROW nLength)
Definition: documen6.cxx:183
Additional class containing cell annotation data.
Definition: postit.hxx:161
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:384
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:4114
void SetExpandRefs(bool bVal)
Definition: documen2.cxx:308
const ScPatternAttr * GetSelectionPattern(const ScMarkData &rMark)
Definition: document.cxx:5126
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:2321
TableContainer maTabs
Definition: document.hxx:375
bool SetDdeLinkResultMatrix(size_t nDdePos, const ScMatrixRef &pResults)
Sets a result matrix for the specified DDE link.
Definition: documen8.cxx:1026
void SetEmbedFontScriptAsian(bool bUse)
Definition: document.hxx:582
Definition: global.hxx:419
const ScValidationDataList * GetValidationList() const
Definition: document.hxx:1803
Definition: global.hxx:343
std::unique_ptr< ScRefreshTimerControl > pRefreshTimerControl
Definition: document.hxx:397
void DecInDdeLinkUpdate()
Definition: document.hxx:1018
SC_DLLPUBLIC sc::ExternalDataMapper & GetExternalDataMapper()
SC_DLLPUBLIC OUString GetString(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScInterpreterContext *pContext=nullptr) const
Definition: document.cxx:3517
void DecInterpretLevel()
Definition: document.hxx:2331
std::unique_ptr< ScBroadcastAreaSlotMachine > pBASM
Definition: document.hxx:387
bool IsFinalTrackFormulas() const
Definition: document.hxx:2310
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:2050
std::unique_ptr< ScConsolidateParam > pConsolidateDlgData
Definition: document.hxx:424
void SetChartListenerCollection(std::unique_ptr< ScChartListenerCollection >, bool bSetChartRangeLists)
Definition: documen3.cxx:412
void SetNoListening(bool bVal)
Definition: document.hxx:2152
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:4271
bool bInsertingFromOtherDoc
Definition: document.hxx:499
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:260
SC_DLLPUBLIC ScExternalRefManager * GetExternalRefManager() const
Definition: documen3.cxx:623
SC_DLLPUBLIC bool IsDocVisible() const
Definition: document.hxx:1556
void UpdateScriptTypes(const ScAddress &rPos, SCCOL nColSize, SCROW nRowSize)
Definition: document10.cxx:333
bool IsAutoCalcShellDisabled() const
Definition: document.hxx:1363
std::unique_ptr< ScDocProtection > pDocProtection
Definition: document.hxx:404
::boost::intrusive_ptr< ScMatrix > ScMatrixRef
Definition: types.hxx:25
std::map< OUString, BitmapEx > IconSetBitmapMap
Definition: document.hxx:208
OUString aDocCodeName
Definition: document.hxx:415
Walk through all cells in an area.
Definition: dociter.hxx:207
tools::Rectangle GetEmbeddedRect() const
Definition: documen3.cxx:1714
bool RemovePageStyleInUse(std::u16string_view rStrPageStyle)
Definition: documen8.cxx:327
SC_DLLPUBLIC bool HasTable(SCTAB nTab) const
Definition: document.cxx:191
Definition: global.hxx:225
void EndListeningIntersectedGroups(sc::EndListeningContext &rCxt, const ScRange &rRange, std::vector< ScAddress > *pGroupPos)
Definition: document10.cxx:473
bool mbIdleEnabled
Definition: document.hxx:505
void DiscardFormulaGroupContext()
Definition: document.cxx:3564
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:6120
formula::VectorRefArray FetchVectorRefArray(const ScAddress &rPos, SCROW nLength)
Definition: document.cxx:1771
SC_DLLPUBLIC const ScRange * GetPrintRange(SCTAB nTab, sal_uInt16 nPos)
Definition: document.cxx:6305
std::set< ScFormulaCell * > maSubTotalCells
Definition: document.hxx:551
void SetError(SCCOL nCol, SCROW nRow, SCTAB nTab, const FormulaError nError)
Definition: documen2.cxx:1061
bool HasSheetEventScript(SCTAB nTab, ScSheetEventId nEvent, bool bWithVbaEvents=false) const
Definition: documen3.cxx:672
const sal_uInt8 SC_DDE_IGNOREMODE
Definition: document.hxx:295
void RestoreChartListener(const OUString &rName)
Definition: documen5.cxx:361
void CopyTabProtection(SCTAB nTabSrc, SCTAB nTabDest)
Definition: documen3.cxx:1939
void Clear(bool bFromDestructor=false)
Definition: documen9.cxx:500
SCTAB GetMaxTableNumber() const
Definition: document.hxx:804
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:327
Optimized ColumnSpanSet version that operates on a single ScRange.
bool IsEmbedUsedFontsOnly() const
Definition: document.hxx:574
std::unique_ptr< ScDBData > mpAnonymousDBData
Definition: document.hxx:399
sal_uInt16 ColDifferences(SCCOL nThisCol, SCTAB nThisTab, ScDocument &rOtherDoc, SCCOL nOtherCol, SCTAB nOtherTab, SCROW nMaxRow, const SCCOLROW *pOtherRows)
Definition: documen4.cxx:965
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:2464
void PageStyleModified(SCTAB nTab, const OUString &rNewName)
Definition: document.cxx:6200
SC_DLLPUBLIC void SetColWidthOnly(SCCOL nCol, SCTAB nTab, sal_uInt16 nNewWidth)
Definition: document.cxx:4120
SC_DLLPUBLIC void ResetClip(ScDocument *pSourceDoc, const ScMarkData *pMarks)
Definition: documen2.cxx:488
ScBroadcastAreaSlotMachine * GetBASM() const
Definition: document.hxx:2154
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:4800
SC_DLLPUBLIC void SetRowHeightOnly(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, sal_uInt16 nNewHeight)
Definition: document.cxx:4139
bool mbTrackFormulasPending
Definition: document.hxx:562
SC_DLLPUBLIC const ScPatternAttr * GetPattern(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:4766
void ReplaceStyle(const SvxSearchItem &rSearchItem, SCCOL nCol, SCROW nRow, SCTAB nTab, const ScMarkData &rMark)
Definition: documen4.cxx:550
SfxUndoManager * mpUndoManager
Definition: document.hxx:365
SC_DLLPUBLIC 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:6292
bool bHasForcedFormulas
Definition: document.hxx:509
void FinalTrackFormulas(SfxHintId nHintId)
Definition: documen7.cxx:506
ScChangeTrack * GetChangeTrack() const
Definition: document.hxx:2405
bool ShrinkToUsedDataArea(bool &o_bShrunk, SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow, SCCOL &rEndCol, SCROW &rEndRow, bool bColumnsOnly, bool bStickyTopRow=false, bool bStickyLeftCol=false, ScDataAreaExtras *pDataAreaExtras=nullptr) const
Shrink a range to only include used data area.
Definition: document.cxx:1063
std::unique_ptr< ScDrawLayer > mpDrawLayer
Definition: document.hxx:371
void CopyTabToClip(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, SCTAB nTab, ScDocument *pClipDoc)
Definition: document.cxx:2248
bool ColFiltered(SCCOL nCol, SCTAB nTab) const
Definition: document.cxx:4546
bool mbFinalTrackFormulas
Definition: document.hxx:563
void GetFilterEntries(SCCOL nCol, SCROW nRow, SCTAB nTab, ScFilterEntries &rFilterEntries)
Get a list of unique strings to use in filtering criteria.
Definition: documen3.cxx:1559
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:4745
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:2153
void StylesToNames()
Definition: document.cxx:6148
void StartListeningCell(const ScAddress &rAddress, SvtListener *pListener)
Definition: documen7.cxx:208
void ImplCreateOptions()
Definition: documen8.cxx:102
void SetInsertingFromOtherDoc(bool bVal)
Definition: document.hxx:2146
void SetSrcCharSet(rtl_TextEncoding eNew)
Definition: document.hxx:2062
void ResetEmbedded()
Definition: documen3.cxx:1753
bool GetNoListening() const
Definition: document.hxx:2153
bool IsStreamValid(SCTAB nTab) const
Definition: document.cxx:917
ScStyleSheet * GetPreviewCellStyle()
Definition: document.hxx:1344
bool HasValidationData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3840
SC_DLLPUBLIC bool GetCellArea(SCTAB nTab, SCCOL &rEndCol, SCROW &rEndRow) const
Definition: document.cxx:1010
ScRangePairListRef xColNameRanges
Definition: document.hxx:417
bool IsClipboard() const
Definition: document.hxx:1534
SC_DLLPUBLIC bool HasRowHeader(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab)
Definition: documen3.cxx:1538
void GetDataEntries(SCCOL nCol, SCROW nRow, SCTAB nTab, std::vector< ScTypedStrData > &rStrings, bool bValidation=false)
Entries for selection list listbox (no numbers/formulas)
Definition: documen3.cxx:1625
SC_DLLPUBLIC double GetValue(const ScAddress &rPos) const
Definition: document.cxx:3659
ScMutationDisable(ScDocument &rDocument, ScMutationGuardFlags nFlags)
Definition: document.hxx:2632
SC_DLLPUBLIC const ScDocOptions & GetDocOptions() const
Definition: documen3.cxx:1947
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:259
constexpr double nPPTX
void SetTabNameOnLoad(SCTAB nTab, const OUString &rName)
Definition: document.cxx:484
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:2662
bool bInUnoBroadcast
Definition: document.hxx:536
size_t mnMutationGuardFlags
Definition: document.hxx:567
void AddOLEObjectToCollection(const OUString &rName)
Definition: documen5.cxx:643
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:3425
SC_DLLPUBLIC void DumpColumnStorage(SCTAB nTab, SCCOL nCol) const
void AddDetectiveOperation(const ScDetOpData &rData)
Definition: documen4.cxx:901
void InvalidateStreamOnSave()
Definition: document.cxx:495
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:6839
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:550
SC_DLLPUBLIC void SetVisibleTab(SCTAB nTab)
Definition: document.hxx:859
Enum used to indicate which portion of the DBArea is to be considered.
Definition: dbdata.hxx:40
Definition: global.hxx:189
SC_DLLPUBLIC bool SetString(SCCOL nCol, SCROW nRow, SCTAB nTab, const OUString &rString, const ScSetStringParam *pParam=nullptr)
Definition: document.cxx:3394
std::unique_ptr< ScViewOptions > pViewOptions
Definition: document.hxx:420
SC_DLLPUBLIC ScDocProtection * GetDocProtection() const
Definition: documen3.cxx:1890
bool HasOLEObjectsInArea(const ScRange &rRange, const ScMarkData *pTabMark=nullptr)
Definition: documen9.cxx:276
bool IsCellInChangeTrack(const ScAddress &cell, Color *pColCellBorder)
Definition: documen2.cxx:1205
bool HasAnyCalcNotification() const
Definition: documen3.cxx:705
bool HasClipFilteredRows()
Definition: document.cxx:3218
bool bExpandRefs
Definition: document.hxx:516
formula::FormulaGrammar::Grammar eStorageGrammar
The compiler grammar used in document storage.
Definition: document.hxx:456
SC_DLLPUBLIC ScPostIt * GetOrCreateNote(const ScAddress &rPos)
Definition: document.cxx:6639
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:1058
void SetClipArea(const ScRange &rArea, bool bCut=false)
Definition: document.cxx:3134
Definition: document.hxx:871
T * get() const
std::unique_ptr< ScUnoRefList > EndUnoRefUndo()
Definition: documen3.cxx:993
const ScStyleSheet * GetSelectionStyle(const ScMarkData &rMark) const
Definition: document.cxx:4937
SC_DLLPUBLIC SvNumberFormatter * GetFormatTable() const
Definition: documen2.cxx:441
SC_DLLPUBLIC bool ColHidden(SCCOL nCol, SCTAB nTab, SCCOL *pFirstCol=nullptr, SCCOL *pLastCol=nullptr) const
Definition: document.cxx:4476
SC_DLLPUBLIC void SetPattern(const ScAddress &, const ScPatternAttr &rAttr)
Definition: document.cxx:5075
bool IsChartListenerCollectionNeedsUpdate() const
Definition: document.hxx:2162
bool IsInsertingFromOtherDoc() const
Definition: document.hxx:2147
void ApplyFrameAreaTab(const ScRange &rRange, const SvxBoxItem &rLineOuter, const SvxBoxInfoItem &rLineInner)
Definition: document.cxx:5887
bool CopyTab(SCTAB nOldPos, SCTAB nNewPos, const ScMarkData *pOnlyMarked=nullptr)
Definition: documen2.cxx:768
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:2436
void GetScenarioFlags(SCTAB nTab, ScScenarioFlags &rFlags) const
Definition: documen3.cxx:479
bool bIsFunctionAccess
Definition: document.hxx:492
void Reorder(const sc::ReorderParam &rParam)
Definition: documen3.cxx:1447
Definition: global.hxx:326
void DelayFormulaGrouping(bool delay)
If set, joining cells into shared formula groups will be delayed until reset again (RegroupFormulaCel...
Definition: document10.cxx:376
void SetStorageGrammar(formula::FormulaGrammar::Grammar eGrammar)
Should only be GRAM_PODF or GRAM_ODFF.
Definition: documen2.cxx:238
ScRecursionHelper & GetRecursionHelper()
Definition: document.cxx:6846
SC_DLLPUBLIC sal_uInt16 GetPrintRangeCount(SCTAB nTab)
Definition: document.cxx:6297
SCROW CountNonFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4578
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:6241
void SetDBCollection(std::unique_ptr< ScDBCollection > pNewDBCollection, bool bRemoveAutoFilter=false)
Definition: documen3.cxx:275
std::unique_ptr< ScDPCollection > pDPCollection
Definition: document.hxx:380
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:2150
Keep track of all named expressions that have been updated during reference update.
SCCOL nPosLeft
Definition: document.hxx:478
void EnableExecuteLink(bool bVal)
Definition: document.hxx:1543
sal_uInt16 RowDifferences(SCROW nThisRow, SCTAB nThisTab, ScDocument &rOtherDoc, SCROW nOtherRow, SCTAB nOtherTab, SCCOL nMaxCol, const SCCOLROW *pOtherCols)
Definition: documen4.cxx:927
bool bIsEmbedded
Definition: document.hxx:495
void GetCellChangeTrackNote(const ScAddress &cell, OUString &strTrackText, bool &pbLeftEdge)
Definition: documen2.cxx:1268
SCROW GetNextDifferentChangedRow(SCTAB nTab, SCROW nStart) const
Definition: document.cxx:4642
SC_DLLPUBLIC bool HasPivotTable() const
Definition: documen3.cxx:360
LanguageType eCtlLanguage
Definition: document.hxx:451
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:4684
rtl::Reference< ScSheetLimits > mxSheetLimits
Definition: document.hxx:376
void DeleteBroadcasters(sc::ColumnBlockPosition &rBlockPos, const ScAddress &rTopPos, SCROW nLength)
Definition: document.cxx:2488
void UpdateAllRowHeights(sc::RowHeightContext &rCxt, const ScMarkData *pTabMark)
Definition: document.cxx:4306
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:439
void GetFormulaEntries(ScTypedCaseStrSet &rStrings)
Entries for Formula auto input.
Definition: documen3.cxx:1665
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:961
void FillTab(const ScRange &rSrcArea, const ScMarkData &rMark, InsertDeleteFlags nFlags, ScPasteFunc nFunction, bool bSkipEmpty, bool bAsLink)
Definition: document.cxx:3259
void CompileXML()
Definition: document.cxx:4001
SC_DLLPUBLIC bool RowFiltered(SCROW nRow, SCTAB nTab, SCROW *pFirstRow=nullptr, SCROW *pLastRow=nullptr) const
Definition: document.cxx:4530
bool bDetectiveDirty
Definition: document.hxx:518
std::shared_ptr< sc::FormulaGroupContext > mpFormulaGroupCxt
Definition: document.hxx:360
Definition: global.hxx:335
ScAddress GetNotePosition(size_t nIndex) const
Definition: document.cxx:6722
std::unique_ptr< ScDocument, o3tl::default_delete< ScDocument > > ScDocumentUniquePtr
Definition: document.hxx:2622
SC_DLLPUBLIC void GetAllColBreaks(std::set< SCCOL > &rBreaks, SCTAB nTab, bool bPage, bool bManual) const
Definition: document.cxx:4382
void IncMacroInterpretLevel()
Definition: document.hxx:2338
SC_DLLPUBLIC void RestoreTabFromCache(SCTAB nTab, SvStream &rStream)
sal_Int16 SCCOL
Definition: types.hxx:21
SC_DLLPUBLIC void DeleteSelection(InsertDeleteFlags nDelFlag, const ScMarkData &rMark, bool bBroadcast=true)
Definition: document.cxx:5958
std::unique_ptr< sc::ExternalDataMapper > mpDataMapper
Definition: document.hxx:400
void GetAutoFormatData(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, ScAutoFormatData &rData)
Definition: documen3.cxx:1200
Definition: global.hxx:158
SC_DLLPUBLIC const ScMatrix * GetDdeLinkResultMatrix(size_t nDdePos) const
Returns the result matrix of the specified DDE link.
Definition: documen8.cxx:989
SCCOL GetNextDifferentChangedCol(SCTAB nTab, SCCOL nStart) const
Definition: document.cxx:4624
bool ValidCol(SCCOL nCol) const
Definition: document.hxx:874
void SetVbaEventProcessor(const css::uno::Reference< css::script::vba::XVBAEventProcessor > &rxVbaEvents)
Definition: document.hxx:2446
NumFmtMergeHandler(ScDocument &rDoc, const ScDocument &rSrcDoc)
Definition: document.cxx:2452
sal_uLong nCellCount
Definition: document.hxx:279
bool GetDdeLinkData(size_t nDdePos, OUString &rAppl, OUString &rTopic, OUString &rItem) const
Returns the connection data of the specified DDE link.
Definition: documen8.cxx:967
LanguageType eLanguage
Definition: document.hxx:449
bool HasBackgroundDraw(SCTAB nTab, const tools::Rectangle &rMMRect) const
Definition: documen9.cxx:343
Struct to hold non-data extended area, used with ScDocument::ShrinkToUsedDataArea().
Definition: sortparam.hxx:43
sal_uLong GetScaledRowHeight(SCROW nStartRow, SCROW nEndRow, SCTAB nTab, double fScale, const sal_uLong *pnMaxHeight=nullptr) const
Definition: document.cxx:4229
void RestorePrintRanges(const ScPrintRangeSaver &rSaver)
Definition: document.cxx:6369
SC_DLLPUBLIC void SetAutoCalc(bool bNewAutoCalc)
Definition: documen7.cxx:602
void EnableChangeReadOnly(bool bVal)
Definition: document.hxx:1545
bool HasAreaLinks() const
Definition: documen8.cxx:1036
void LimitChartArea(SCTAB nTab, SCCOL &rStartCol, SCROW &rStartRow, SCCOL &rEndCol, SCROW &rEndRow)
Definition: document.cxx:1107
ScMarkData maPreviewSelection
Definition: document.hxx:430
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:667
bool IsForcedFormulaPending() const
Definition: document.hxx:1366
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:2109
SC_DLLPUBLIC void SetViewOptions(const ScViewOptions &rOpt)
Definition: documen3.cxx:1967
ScSheetLimits & GetSheetLimits() const
Definition: document.hxx:873
bool HasRangeOverflow() const
Definition: document.hxx:2142
void RemoveEditTextCharAttribs(const ScAddress &rPos, const ScPatternAttr &rAttr)
Definition: document.cxx:3651
void GetUnprotectedCells(ScRangeList &rRange, SCTAB nTab) const
Definition: document.cxx:6818
bool IsFunctionAccess() const
Definition: document.hxx:1537
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:979
SC_DLLPUBLIC void CreateValidTabName(OUString &rName) const
Definition: document.cxx:392
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:452
SC_DLLPUBLIC void ApplyPattern(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScPatternAttr &rAttr)
Definition: document.cxx:4794
ScRange aEmbedRange
Definition: document.hxx:435
SC_DLLPUBLIC sal_uLong TransferTab(ScDocument &rSrcDoc, SCTAB nSrcPos, SCTAB nDestPos, bool bInsertNew=true, bool bResultsOnly=false)
Definition: documen2.cxx:909
OUString GetAutoFillPreview(const ScRange &rSource, SCCOL nEndX, SCROW nEndY)
Definition: documen3.cxx:1176
sal_uInt16 GetMacroInterpretLevel() const
Definition: document.hxx:2337
SC_DLLPUBLIC void UnlockAdjustHeight()
Definition: document.cxx:1789
SC_DLLPUBLIC SCCOL ClampToAllocatedColumns(SCTAB nTab, SCCOL nCol) const
Definition: documen3.cxx:2148
::boost::intrusive_ptr< FormulaToken > FormulaTokenRef
bool IsInInterpreterTableOp() const
Definition: document.hxx:2350
bool RenamePageStyleInUse(std::u16string_view rOld, const OUString &rNew)
Definition: documen8.cxx:342
void SetLinkFormulaNeedingCheck(bool bSet)
Definition: document.hxx:2137
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:6259
Structure that stores segments of boolean flags per column, and perform custom action on those segmen...
bool IsDetectiveDirty() const
Definition: document.hxx:2133
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:2039
SC_DLLPUBLIC void SetRowHeight(SCROW nRow, SCTAB nTab, sal_uInt16 nNewHeight)
Definition: document.cxx:4126
void SetNote(const ScAddress &rPos, std::unique_ptr< ScPostIt > pNote)
Definition: document.cxx:6549
bool mbEmbedFontScriptAsian
Definition: document.hxx:557
SC_DLLPUBLIC bool InsertTab(SCTAB nPos, const OUString &rName, bool bExternalDocument=false, bool bUndoDeleteTab=false)
Definition: document.cxx:504
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:1032
SC_DLLPUBLIC ScDocument(ScDocumentMode eMode=SCDOCMODE_DOCUMENT, SfxObjectShell *pDocShell=nullptr)
Definition: documen2.cxx:105
HardRecalcState GetHardRecalcState() const
Definition: document.hxx:2313
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:4817
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:6212
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:4132
void CreateColumnIfNotExists(SCTAB nTab, SCCOL nCol)
Definition: document10.cxx:975
void DecXMLImportedFormulaCount(sal_uLong nVal)
Definition: document.hxx:2376
SC_DLLPUBLIC SCROW GetFirstEditTextRow(const ScRange &rRange) const
Definition: document.cxx:3453
Instantiate this to ensure that subsequent modification of the document will cause an assertion failu...
Definition: document.hxx:2629
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:1756
OUString GetLinkFlt(SCTAB nTab) const
Definition: documen3.cxx:518
void SetSubTotalCellsDirty(const ScRange &rDirtyRange)
Definition: document.cxx:6450
void RemoveSubTotalCell(ScFormulaCell *pCell)
Definition: document.cxx:6429
SC_DLLPUBLIC const EditTextObject * GetEditText(const ScAddress &rPos) const
Definition: document.cxx:3642
bool IsInExternalReferenceMarking() const
Definition: documen3.cxx:632
void SaveDdeLinks(SvStream &rStream) const
Definition: documen8.cxx:711
formula::FormulaGrammar::Grammar GetStorageGrammar() const
Definition: document.hxx:2452
sal_uLong nFormulaCodeInTree
Definition: document.hxx:458
SCTAB nTableCount
Definition: document.hxx:278
SC_DLLPUBLIC tools::Rectangle GetMMRect(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab, bool bHiddenAsZero=true) const
Definition: documen3.cxx:1996
bool IsBlockEmpty(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, bool bIgnoreNotes=false) const
Definition: document.cxx:5322
void IncInterpreterTableOpLevel()
Definition: document.hxx:2351
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:4176
void ResetChanged(const ScRange &rRange)
Definition: document.cxx:4102
SCROW GetRowForHeight(SCTAB nTab, sal_uLong nHeight) const
Given the height i.e.
Definition: document.cxx:4224
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:599
std::set< ScTypedStrData, ScTypedStrData::LessCaseSensitive > ScTypedCaseStrSet
Definition: document.hxx:260
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:2076
SC_DLLPUBLIC void AddPrintRange(SCTAB nTab, const ScRange &rNew)
Adds a new print ranges.
Definition: document.cxx:6335
bool CompileErrorCells(FormulaError nErrCode)
Re-compile formula cells with error.
Definition: document.cxx:4041
Definition: document.hxx:253
std::unique_ptr< ScScriptTypeData > pScriptTypeData
Definition: document.hxx:396
Definition: document.hxx:863
void RemoveManualBreaks(SCTAB nTab)
Definition: document.cxx:6253
SC_DLLPUBLIC bool HasValueData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3796
SC_DLLPUBLIC ScPostIt * CreateNote(const ScAddress &rPos)
Definition: document.cxx:6646
bool HasSelectedBlockMatrixFragment(SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, const ScMarkData &rMark) const
Definition: document.cxx:5433
std::unique_ptr< sc::DocumentLinkManager > mpDocLinkMgr
Definition: document.hxx:358
SC_DLLPUBLIC const SfxItemSet * GetCondResult(SCCOL nCol, SCROW nRow, SCTAB nTab, ScRefCellValue *pCell=nullptr) const
Definition: documen4.cxx:799
bool HasLinkFormulaNeedingCheck() const
Definition: document.hxx:2136
void GetNumberFormatInfo(const ScInterpreterContext &rContext, SvNumFormatType &nType, sal_uInt32 &nIndex, const ScAddress &rPos) const
Definition: document.cxx:3730
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:2565
std::unique_ptr< ScNoteEditEngine > mpNoteEngine
Definition: document.hxx:367
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:389
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:6135
bool CanInsertRow(const ScRange &rRange) const
Definition: document.cxx:1184
void CheckVectorizationState()
Definition: document.cxx:3852
SC_DLLPUBLIC bool ExtendMerge(SCCOL nStartCol, SCROW nStartRow, SCCOL &rEndCol, SCROW &rEndRow, SCTAB nTab, bool bRefresh=false)
Definition: document.cxx:5594
SC_DLLPUBLIC bool HasNote(const ScAddress &rPos) const
Definition: document.cxx:6559
void CompileDBFormula()
Definition: documen4.cxx:558
void ForgetNoteCaptions(const ScRangeList &rRanges, bool bPreserveData)
Definition: document.cxx:6671
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:590
bool ValidAddress(const ScAddress &rAddress) const
Definition: document.hxx:879
ScAutoNameCache * GetAutoNameCache()
Definition: document.hxx:1338
void UpdateRefAreaLinks(UpdateRefMode eUpdateRefMode, const ScRange &r, SCCOL nDx, SCROW nDy, SCTAB nDz)
Definition: documen8.cxx:1085
sal_uInt16 nPageCount
Definition: document.hxx:281
void LockStreamValid(bool bLock)
Definition: document.cxx:931
sal_uInt32 GetDocumentID() const
an ID unique to each document instance
Definition: documen2.cxx:255
css::uno::Reference< css::script::vba::XVBAEventProcessor > mxVbaEvents
Definition: document.hxx:441
bool HasFilteredRows(SCROW nStartRow, SCROW nEndRow, SCTAB nTab) const
Definition: document.cxx:4538
bool mbExecuteLinkEnabled
Definition: document.hxx:544
void BroadcastCells(const ScRange &rRange, SfxHintId nHint, bool bBroadcastSingleBroadcasters=true)
Definition: documen7.cxx:143
bool bCalculatingFormulaTree
Definition: document.hxx:489
SC_DLLPUBLIC bool HasStringData(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Definition: document.cxx:3787
SC_DLLPUBLIC void SetRepeatRowRange(SCTAB nTab, std::unique_ptr< ScRange > pNew)
Definition: document.cxx:6353
SC_DLLPUBLIC void EnsureTable(SCTAB nTab)
Definition: documen2.cxx:540
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:1611
void SetCalcNotification(SCTAB nTab)
Definition: documen3.cxx:721
ScDocument & mrDoc
Definition: document.hxx:2688
SC_DLLPUBLIC void SetColBreak(SCCOL nCol, SCTAB nTab, bool bPage, bool bManual)
Definition: document.cxx:4428
SC_DLLPUBLIC ScMacroManager * GetMacroManager()
Definition: documen8.cxx:379
FormulaError GetErrCode(const ScAddress &) const
Definition: document.cxx:4094
bool bInLinkUpdate
Definition: document.hxx:506
SC_DLLPUBLIC const ScViewOptions & GetViewOptions() const
Definition: documen3.cxx:1961
Definition: document.hxx:479
Represents the type of sheet geometry data.
Definition: document.hxx:267
void RemoveSubTotals(SCTAB nTab, ScSubTotalParam &rParam)
Definition: documen3.cxx:771
static bool IsEmptyCellSearch(const SvxSearchItem &rSearchItem)
Definition: documen3.cxx:1301
void AddUnoObject(SfxListener &rObject)
Definition: documen3.cxx:898
std::unique_ptr< ScUnoRefList > pUnoRefUndoList
Definition: document.hxx:394
std::unique_ptr< SvMemoryStream > pClipData
Definition: document.hxx:389
bool bIsVisible
Definition: document.hxx:493
SC_DLLPUBLIC void CalcAfterLoad(bool bStartListening=true)
Definition: document.cxx:4057
OUString GetCopyTabName(SCTAB nTab) const
Definition: document.cxx:227
void CopyBlockFromClip(sc::CopyFromClipContext &rCxt, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, const ScMarkData &rMark, SCCOL nDx, SCROW nDy)
Definition: document.cxx:2635
void SetRangeOverflowType(ErrCode nType)
Definition: document.hxx:2141
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:1372
bool IsCalculatingFormulaTree() const
Definition: document.hxx:1368
Definition: global.hxx:149
void GetUpperCellString(SCCOL nCol, SCROW nRow, SCTAB nTab, OUString &rStr)
Definition: documen3.cxx:1479
SCROW SanitizeRow(SCROW nRow) const
Definition: document.hxx:881
SC_DLLPUBLIC void DoEmptyBlock(SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow)
Definition: documen3.cxx:2063
SC_DLLPUBLIC ScLkUpdMode GetLinkMode() const
Definition: document.hxx:2183
SC_DLLPUBLIC void GetScenarioData(SCTAB nTab, OUString &rComment, Color &rColor, ScScenarioFlags &rFlags) const
Definition: documen3.cxx:468
void LockTable(SCTAB nTab)
Definition: document.cxx:5333
bool IdleCalcTextWidth()
Definition: documen8.cxx:534
SC_DLLPUBLIC double RoundValueAsShown(double fVal, sal_uInt32 nFormat, const ScInterpreterContext *pContext=nullptr) const
Definition: documen4.cxx:635
void CreateAllNoteCaptions()
Ensure that all note objects have an associated sdr object.
Definition: document.cxx:6662
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:2738
void finalizeOutlineImport()
Definition: document10.cxx:568
void InvalidateTextWidth(std::u16string_view rStyleName)
Definition: documen8.cxx:297
void SetDetOpList(std::unique_ptr< ScDetOpList > pNew)
Definition: documen4.cxx:914
bool ValidColRow(SCCOL nCol, SCROW nRow) const
Definition: document.hxx:876
void SyncColRowFlags()
Write all column row flags to table's flag data, because not all column row attributes are stored in ...
Definition: document.cxx:4594
bool IsStyleSheetUsed(const ScStyleSheet &rStyle) const
Definition: document.cxx:5006
static thread_local ScDocumentThreadSpecific maThreadSpecific
Definition: document.hxx:468
void FindMaxRotCol(SCTAB nTab, RowInfo *pRowInfo, SCSIZE nArrCount, SCCOL nX1, SCCOL nX2) const
Definition: document.cxx:5262
bool IsInDtorClear() const
Definition: document.hxx:2366
o3tl::sorted_vector< sal_uInt32 > ScCondFormatIndexes
Definition: document.hxx:201
void SetNumberFormat(const ScAddress &rPos, sal_uInt32 nNumberFormat)
Definition: document.cxx:3720
SC_DLLPUBLIC void SetPageStyle(SCTAB nTab, const OUString &rName)
Definition: document.cxx:6206
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:310
SC_DLLPUBLIC Color GetTabBgColor(SCTAB nTab) const
Definition: documen3.cxx:448
SCCOL GetPosLeft() const
Definition: document.hxx:860
void SkipOverlapped(SCCOL &rCol, SCROW &rRow, SCTAB nTab) const
Definition: document.cxx:5747
void SetNeedsListeningGroups(const std::vector< ScAddress > &rPosArray)
Definition: document10.cxx:503
SC_DLLPUBLIC bool SetOptimalHeight(sc::RowHeightContext &rCxt, SCROW nStartRow, SCROW nEndRow, SCTAB nTab, bool bApi)
Definition: document.cxx:4297
SC_DLLPUBLIC sal_uLong AddValidationEntry(const ScValidationData &rNew)
Definition: documen4.cxx:727
SC_DLLPUBLIC SCSIZE GetEmptyLinesInBlock(SCCOL nStartCol, SCROW nStartRow, SCTAB nStartTab, SCCOL nEndCol, SCROW nEndRow, SCTAB nEndTab, ScDirection eDir)