11#include <document.hxx>
15#include <tokenarray.hxx>
30#include <broadcast.hxx>
63 SCTAB nClipTabCount = rClipTabs.size();
74 while (!rClipTabs[nClipTab])
75 nClipTab = (nClipTab+1) % nClipTabCount;
79 nClipTab = (nClipTab+1) % nClipTabCount;
97 SCCOL nDestColSize = nCol2 - nCol1 + 1;
98 if (nDestColSize < nSrcColSize)
101 if (pClipDoc->
maTabs.size() > 1)
122 for (
SCCOL nColOffset = 0; nColOffset < nSrcColSize; ++nColOffset, aSrcPos.
IncCol())
145 maTabs[
i]->CopyOneCellFromClip(rCxt, nCol1, nRow1, nCol2, nRow2, aClipRange.
aStart.
Row(), pSrcTab);
189 std::set<Color> aDocColors;
192 for (sal_uInt16 nAttrib : pAttribs)
199 aDocColors.insert(aColor);
235 auto pPosSet = std::make_shared<sc::ColumnBlockPositionSet>(*
this);
259 std::map<OUString, ScRangeName*> aRangeNameMap;
261 for (
const auto& itTab : aRangeNameMap)
267 const auto& itNewTab( rRangeMap.find( itTab.first));
268 if (itNewTab == rRangeMap.end())
271 const ScRangeName& rNewRangeNames = itNewTab->second;
273 for (
const auto& rEntry : *pOldRangeNames)
288 for (
const auto& rxTab :
maTabs)
291 p->PreprocessRangeNameUpdate(aEndListenCxt, aCompileCxt);
300 for (
const auto& rxTab :
maTabs)
303 p->PreprocessRangeNameUpdate(aEndListenCxt, aCompileCxt);
312 for (
const auto& rxTab :
maTabs)
315 p->PreprocessDBDataUpdate(aEndListenCxt, aCompileCxt);
323 for (
const auto& rxTab :
maTabs)
326 p->CompileHybridFormula(aStartListenCxt, aCompileCxt);
413 if( it->second.first != -1 )
415 auto pPosSet = std::make_shared<sc::ColumnBlockPositionSet>(*
this);
435 if( it->second.first == -1 && it->second.second == -1 )
439 if( row1 > it->second.second + 1 || row2 < it->second.first - 1 )
443 it->second.first = std::min( it->second.first, row1 );
444 it->second.second = std::max( it->second.second, row2 );
456 for (
auto& rxTab :
maTabs)
458 rxTab->DeleteEmptyBroadcasters();
534class StartNeededListenersHandler
536 std::shared_ptr<sc::StartListeningContext> mpCxt;
539 explicit StartNeededListenersHandler(
ScDocument& rDoc,
const std::shared_ptr<const sc::ColumnSet>& rpColSet ) :
542 mpCxt->setColumnSet( rpColSet);
548 p->StartListeners(*mpCxt,
false);
556 std::for_each(
maTabs.begin(),
maTabs.end(), StartNeededListenersHandler(*
this));
561 std::for_each(
maTabs.begin(),
maTabs.end(), StartNeededListenersHandler(*
this, rpColSet));
569 auto pPosSet = std::make_shared<sc::ColumnBlockPositionSet>(*
this);
587 for (
const auto& rxTab :
maTabs)
590 p->finalizeOutlineImport();
595 SCTAB nTokenTab,
const sal_uInt16 nTokenIndex,
597 bool bSameDoc,
int nRecursion)
const
601 SAL_WARN(
"sc.core",
"ScDocument::FindRangeNamesReferencingSheet - nTokenTab < -1 : " <<
602 nTokenTab <<
", nTokenIndex " << nTokenIndex <<
" Fix the creator!");
603#if OSL_DEBUG_LEVEL > 0
605 SAL_WARN_IF(
pData,
"sc.core",
"ScDocument::FindRangeNamesReferencingSheet - named expression is: " <<
pData->GetName());
609 SCTAB nRefTab = nGlobalRefTab;
610 if (nTokenTab == nOldTokenTab)
612 nTokenTab = nOldTokenTabReplacement;
613 nRefTab = nLocalRefTab;
615 else if (nTokenTab == nOldTokenTabReplacement)
617 nRefTab = nLocalRefTab;
631 bool bRef = !bSameDoc;
632 if (nRecursion < 126)
640 nGlobalRefTab, nLocalRefTab, nOldTokenTab, nOldTokenTabReplacement, bSameDoc, nRecursion+1);
648 if (nPosTab == nOldTokenTab)
649 nPosTab = nOldTokenTabReplacement;
660enum MightReferenceSheet
668MightReferenceSheet mightRangeNameReferenceSheet(
ScRangeData* pData,
SCTAB nRefTab)
677 if (
p->GetOpCode() == ocName)
678 return MightReferenceSheet::NAME;
687 SCTAB nOldSheet,
const SCTAB nNewSheet,
bool bSameDoc)
691 aRangePos.SetTab( nNewSheet);
695 if (bSameDoc && nNewSheet >= 0)
697 if (bGlobalNamesToLocal && nOldSheet < 0)
699 nOldSheet = rOldPos.
Tab();
700 if (rNewPos.
Tab() <= nOldSheet)
718 return bInserted ? pRangeData :
nullptr;
726 SheetIndex(
SCTAB nSheet, sal_uInt16 nIndex ) : mnSheet(nSheet < -1 ? -1 : nSheet),
mnIndex(
nIndex) {}
727 bool operator<(
const SheetIndex& r )
const
730 if (mnSheet < r.mnSheet)
732 if (mnSheet == r.mnSheet)
737typedef std::map< SheetIndex, SheetIndex > SheetIndexMap;
739ScRangeData* copyRangeNames( SheetIndexMap& rSheetIndexMap, std::vector<ScRangeData*>& rRangeDataVec,
743 const SCTAB nOldSheet,
const SCTAB nNewSheet,
bool bSameDoc)
751 for (
auto const & rIndex : aSet)
760 if (pCopyData == pOldRangeData)
762 pRangeData = copyRangeName( pCopyData, rNewDoc, rOldDoc, rNewPos, rOldPos,
763 bGlobalNamesToLocal, nOldSheet, nNewSheet, bSameDoc);
766 rRangeDataVec.push_back(pRangeData);
767 rSheetIndexMap.insert( std::make_pair( SheetIndex( nOldSheet, pCopyData->
GetIndex()),
768 SheetIndex( nNewSheet, pRangeData->
GetIndex())));
778 rSheetIndexMap.insert( std::make_pair( SheetIndex( nOldSheet, pCopyData->
GetIndex()),
779 SheetIndex( nNewSheet, pFoundData->
GetIndex())));
783 ScRangeData* pTmpData = copyRangeName( pCopyData, rNewDoc, rOldDoc, rNewPos, rOldPos,
784 bGlobalNamesToLocal, nOldSheet, nNewSheet, bSameDoc);
787 rRangeDataVec.push_back(pTmpData);
788 rSheetIndexMap.insert( std::make_pair( SheetIndex( nOldSheet, pCopyData->
GetIndex()),
789 SheetIndex( nNewSheet, pTmpData->
GetIndex())));
803 const bool bUsedByFormula )
const
807 if (bSameDoc && ((rSheet < 0 && !bGlobalNamesToLocal) || (rSheet >= 0
815 const SCTAB nOldSheet = rSheet;
816 const sal_uInt16 nOldIndex = rIndex;
818 SAL_WARN_IF( !bSameDoc && nOldSheet >= 0 && nOldSheet != rOldPos.
Tab(),
819 "sc.core",
"adjustCopyRangeName - sheet-local name was on other sheet in other document");
826 bool bInsertingBefore = (bGlobalNamesToLocal && bSameDoc && rNewPos.
Tab() <= rOldPos.
Tab());
833 SCTAB nOldTab = (nOldSheet < 0 ? rOldPos.
Tab() : nOldSheet);
834 if (bInsertingBefore)
842 pOldRangeData = pNames ? pNames->
findByIndex(nOldIndex) :
nullptr;
865 if (!rpRangeData && !bGlobalNamesToLocal)
877 bool bEarlyBailOut = (nOldSheet < 0 && (bSameDoc || !bUsedByFormula));
878 MightReferenceSheet eMightReference = mightRangeNameReferenceSheet( pOldRangeData, nOldTab);
882 if (eMightReference == MightReferenceSheet::NAME)
885 const SCTAB nGlobalRefTab = nOldTab;
886 const SCTAB nLocalRefTab = (bInsertingBefore ? nOldTab-1 : nOldTab);
887 const SCTAB nOldTokenTab = (nOldSheet < 0 ? (bInsertingBefore ? nOldTab-1 : nOldTab) : nOldSheet);
888 const SCTAB nOldTokenTabReplacement = nOldTab;
891 nGlobalRefTab, nLocalRefTab, nOldTokenTab, nOldTokenTabReplacement, bSameDoc, 0);
892 if (bEarlyBailOut && aReferencingNames.
isEmpty(-1) && aReferencingNames.
isEmpty(nOldTokenTabReplacement))
895 SheetIndexMap aSheetIndexMap;
896 std::vector<ScRangeData*> aRangeDataVec;
897 if (!aReferencingNames.
isEmpty(nOldTokenTabReplacement))
899 const SCTAB nTmpOldSheet = (nOldSheet < 0 ? nOldTab : nOldSheet);
900 nNewSheet = rNewPos.
Tab();
901 rpRangeData = copyRangeNames( aSheetIndexMap, aRangeDataVec, aReferencingNames, nOldTab,
902 pOldRangeData, rNewDoc, *
this, rNewPos, rOldPos,
903 bGlobalNamesToLocal, nTmpOldSheet, nNewSheet, bSameDoc);
905 if ((bGlobalNamesToLocal || !bSameDoc) && !aReferencingNames.
isEmpty(-1))
907 const SCTAB nTmpOldSheet = -1;
908 const SCTAB nTmpNewSheet = (bGlobalNamesToLocal ? rNewPos.
Tab() : -1);
909 ScRangeData* pTmpData = copyRangeNames( aSheetIndexMap, aRangeDataVec, aReferencingNames, -1,
910 pOldRangeData, rNewDoc, *
this, rNewPos, rOldPos,
911 bGlobalNamesToLocal, nTmpOldSheet, nTmpNewSheet, bSameDoc);
914 rpRangeData = pTmpData;
915 nNewSheet = nTmpNewSheet;
920 for (
auto & iRD : aRangeDataVec)
930 auto it = aSheetIndexMap.find( SheetIndex(
p->GetSheet(),
p->GetIndex()));
931 if (it != aSheetIndexMap.end())
933 p->SetSheet( it->second.mnSheet);
934 p->SetIndex( it->second.mnIndex);
938 SAL_WARN(
"sc.core",
"adjustCopyRangeName - mapping to new name in other doc missing");
948 nNewSheet = ((nOldSheet < 0 && !bGlobalNamesToLocal) ? -1 : rNewPos.
Tab());
949 rpRangeData = copyRangeName( pOldRangeData, rNewDoc, *
this, rNewPos, rOldPos, bGlobalNamesToLocal,
950 nOldSheet, nNewSheet, bSameDoc);
962 rIndex = rpRangeData ? rpRangeData->
GetIndex() : 0;
979 return std::all_of(rMark.
begin(), rMark.
end(),
980 [
this, &eAction, &nStart, &nEnd](
const SCTAB& rTab) { return IsEditActionAllowed(eAction, rTab, nStart, nEnd); });
1003 bool bAnyDirty =
false;
1012 bAnyDirty = bAnyDirty || bRet;
1092 return std::set<SCCOL>{};
1110 for (
const auto& xTab :
maTabs)
1111 xTab->CollectBroadcasterState(aState);
1114 pBASM->CollectBroadcasterState(aState);
void IncCol(SCCOL nDelta=1)
void UpdateScriptTypes(SCROW nRow1, SCROW nRow2)
void StartListeningFormulaCells(sc::StartListeningContext &rStartCxt, sc::EndListeningContext &rEndCxt, SCROW nRow1, SCROW nRow2)
void SetAreasChangedNeedBroadcast()
std::unique_ptr< sc::ExternalDataMapper > mpDataMapper
std::shared_ptr< svl::SharedStringPool > mpCellStringPool
SC_DLLPUBLIC std::shared_ptr< sc::Sparkline > GetSparkline(ScAddress const &rPosition)
Returns sparkline at the address if it exists.
bool bDelayedDeletingBroadcasters
SC_DLLPUBLIC void GetRangeNameMap(std::map< OUString, ScRangeName * > &rRangeName)
std::set< SCCOL > QueryColumnsWithFormulaCells(SCTAB nTab) const
sc::MultiDataCellState HasMultipleDataCells(const ScRange &rRange) const
Check if the specified range contains either: 1) one non-empty cell, 2) more than one non-empty cells...
void EnableDelayStartListeningFormulaCells(ScColumn *column, bool delay)
If set, ScColumn::StartListeningFormulaCells() calls may be delayed using CanDelayStartListeningFormu...
void SetValues(const ScAddress &rPos, const std::vector< double > &rVals)
sc::BroadcasterState GetBroadcasterState() const
bool FindRangeNamesReferencingSheet(sc::UpdatedRangeNames &rIndexes, SCTAB nTokenTab, const sal_uInt16 nTokenIndex, SCTAB nGlobalRefTab, SCTAB nLocalRefTab, SCTAB nOldTokenTab, SCTAB nOldTokenTabReplacement, bool bSameDoc, int nRecursion) const
Recursively find all named expressions that directly or indirectly (nested) reference a given sheet,...
SC_DLLPUBLIC ScRangeName * GetRangeName() const
SC_DLLPUBLIC ScTable * FetchTable(SCTAB nTab)
bool SetLOKFreezeCol(SCCOL nFreezeCol, SCTAB nTab)
ScClipParam & GetClipParam()
SC_DLLPUBLIC void CompileHybridFormula()
Call this immediately after updating named ranges.
bool IsEditActionAllowed(sc::ColRowEditAction eAction, SCTAB nTab, SCCOLROW nStart, SCCOLROW nEnd) const
void EnableDelayDeletingBroadcasters(bool set)
If set, cells will not delete their empty broadcasters, avoiding possible extensive mdds vector chang...
void finalizeOutlineImport()
void SetNeedsListeningGroups(const std::vector< ScAddress > &rPosArray)
std::vector< ScTableUniquePtr > TableContainer
void SharePooledResources(const ScDocument *pSrcDoc)
bool HasUniformRowHeight(SCTAB nTab, SCROW nRow1, SCROW nRow2) const
rtl::Reference< ScPoolHelper > mxPoolHelper
SC_DLLPUBLIC ScDocumentPool * GetPool()
ScRangeData * FindRangeNameBySheetAndIndex(SCTAB nTab, sal_uInt16 nIndex) const
Find a named expression / range name in either global or a local scope.
std::unique_ptr< ScBroadcastAreaSlotMachine > pBASM
void UpdateReference(sc::RefUpdateContext &rCxt, ScDocument *pUndoDoc=nullptr, bool bIncludeDraw=true, bool bUpdateNoteCaptionPos=true)
SC_DLLPUBLIC ScPostIt * GetNote(const ScAddress &rPos)
void CreateColumnIfNotExists(SCTAB nTab, SCCOL nCol)
std::set< Color > GetDocColors()
bool HasFormulaCell(const ScRange &rRange) const
Check if there is at least one formula cell in specified range.
SC_DLLPUBLIC void PreprocessDBDataUpdate()
void DelayFormulaGrouping(bool delay)
If set, joining cells into shared formula groups will be delayed until reset again (RegroupFormulaCel...
SC_DLLPUBLIC void PreprocessRangeNameUpdate()
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.
void EndListeningGroups(const std::vector< ScAddress > &rPosArray)
void UnshareFormulaCells(SCTAB nTab, SCCOL nCol, std::vector< SCROW > &rRows)
Make specified formula cells non-grouped.
void AddDelayedFormulaGroupingCell(const ScFormulaCell *cell)
To be used only by SharedFormulaUtil::joinFormulaCells().
bool SetLOKFreezeRow(SCROW nFreezeRow, SCTAB nTab)
bool GetNoListening() const
SCCOL GetLOKFreezeCol(SCTAB nTab) const
void EndListeningIntersectedGroups(sc::EndListeningContext &rCxt, const ScRange &rRange, std::vector< ScAddress > *pGroupPos)
SC_DLLPUBLIC sc::ExternalDataMapper & GetExternalDataMapper()
SC_DLLPUBLIC bool CopyOneCellFromClip(sc::CopyFromClipContext &rCxt, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2)
OString dumpSheetGeomData(SCTAB nTab, bool bColumns, SheetGeomType eGeomType)
Serializes the specified sheet's geometry data.
SC_DLLPUBLIC void SetCalcConfig(const ScCalcConfig &rConfig)
void UpdateScriptTypes(const ScAddress &rPos, SCCOL nColSize, SCROW nRowSize)
void RegroupFormulaCells(SCTAB nTab, SCCOL nCol)
bool IsClipOrUndo() const
SCROW GetLOKFreezeRow(SCTAB nTab) const
void ConvertFormulaToValue(const ScRange &rRange, sc::TableValues *pUndo)
void CheckIntegrity(SCTAB nTab) const
Check the integrity of the internal table state.
SfxObjectShell * GetDocumentShell() const
void DeleteBeforeCopyFromClip(sc::CopyFromClipContext &rCxt, const ScMarkData &rMark, sc::ColumnSpanSet &rBroadcastSpans)
SC_DLLPUBLIC void RestoreTabFromCache(SCTAB nTab, SvStream &rStream)
std::unordered_map< ScColumn *, std::pair< SCROW, SCROW > > pDelayedStartListeningFormulaCells
SC_DLLPUBLIC void PreprocessAllRangeNamesUpdate(const std::map< OUString, ScRangeName > &rRangeMap)
Call this immediately before updating all named ranges.
SC_DLLPUBLIC void StoreTabToCache(SCTAB nTab, SvStream &rStrm) const
SC_DLLPUBLIC ScRangeName * GetRangeName(SCTAB nTab) const
void CopyCellValuesFrom(const ScAddress &rTopPos, const sc::CellValues &rSrc)
void SwapNonEmpty(sc::TableValues &rValues)
bool IsMerged(const ScAddress &rPos) const
bool CanDelayStartListeningFormulaCells(ScColumn *column, SCROW row1, SCROW row2)
If true is returned, ScColumn::StartListeningFormulaCells() for the given cells will be performed lat...
std::optional< sc::ColumnIterator > GetColumnIterator(SCTAB nTab, SCCOL nCol, SCROW nRow1, SCROW nRow2) const
bool CopyAdjustRangeName(SCTAB &rSheet, sal_uInt16 &rIndex, ScRangeData *&rpRangeData, ScDocument &rNewDoc, const ScAddress &rNewPos, const ScAddress &rOldPos, const bool bGlobalNamesToLocal, const bool bUsedByFormula) const
If necessary (name references sheet rOldPos.Tab()) copy and adjust named expression/range from sheet-...
ScCalcConfig maCalcConfig
void TransferCellValuesTo(const ScAddress &rTopPos, size_t nLen, sc::CellValues &rDest)
Transfer a series of contiguous cell values from specified position to the passed container.
std::unique_ptr< ScRange > pDelayedFormulaGrouping
void StartNeededListeners()
SC_DLLPUBLIC const ScPatternAttr * GetPattern(SCCOL nCol, SCROW nRow, SCTAB nTab) const
void EndListeningIntersectedGroup(sc::EndListeningContext &rCxt, const ScAddress &rPos, std::vector< ScAddress > *pGroupPos)
bool IsEnabledDelayStartListeningFormulaCells(ScColumn *column) const
SC_DLLPUBLIC SCTAB GetTableCount() const
todo: It should be possible to have MarkArrays for each table, in order to enable "search all" across...
const_iterator end() const
bool GetTableSelect(SCTAB nTab) const
const_iterator begin() const
void GetName(OUString &rName) const
void SetIndex(sal_uInt16 nInd)
void SetNewName(const OUString &rNewName)
Does not change the name, but sets maNewName for formula update after dialog.
const ScAddress & GetPos() const
sal_uInt16 GetIndex() const
const OUString & GetUpperName() const
SC_DLLPUBLIC ScRangeData * findByIndex(sal_uInt16 i) const
SC_DLLPUBLIC ScRangeData * findByUpperName(const OUString &rName)
SC_DLLPUBLIC bool insert(ScRangeData *p, bool bReuseFreeIndex=true)
Insert object into set.
SCCOL GetLOKFreezeCol() const
ScColumn * FetchColumn(SCCOL nCol)
bool HasFormulaCell(const SCCOL nCol1, SCROW nRow1, const SCCOL nCol2, SCROW nRow2) const
void EndListeningGroup(sc::EndListeningContext &rCxt, const SCCOL nCol, SCROW nRow)
bool IsEditActionAllowed(sc::ColRowEditAction eAction, SCCOLROW nStart, SCCOLROW nEnd) const
void UpdateScriptTypes(const SCCOL nCol1, SCROW nRow1, const SCCOL nCol2, SCROW nRow2)
ScColumn & CreateColumnIfNotExists(const SCCOL nScCol)
void CheckIntegrity() const
std::optional< sc::ColumnIterator > GetColumnIterator(SCCOL nCol, SCROW nRow1, SCROW nRow2) const
bool HasUniformRowHeight(SCROW nRow1, SCROW nRow2) const
SCROW GetLOKFreezeRow() const
sc::MultiDataCellState HasMultipleDataCells(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2) const
void SetNeedsListeningGroup(SCCOL nCol, SCROW nRow)
void SetValues(const SCCOL nCol, const SCROW nRow, const std::vector< double > &rVals)
void DeleteBeforeCopyFromClip(sc::CopyFromClipContext &rCxt, const ScTable &rClipTab, sc::ColumnSpanSet &rBroadcastSpans)
OString dumpSheetGeomData(bool bColumns, SheetGeomType eGeomType)
Serializes the sheet's geometry data.
void UnshareFormulaCells(SCCOL nCol, std::vector< SCROW > &rRows)
void EndListeningIntersectedGroups(sc::EndListeningContext &rCxt, const SCCOL nCol1, SCROW nRow1, const SCCOL nCol2, SCROW nRow2, std::vector< ScAddress > *pGroupPos)
void RestoreFromCache(SvStream &rStrm)
void ConvertFormulaToValue(sc::EndListeningContext &rCxt, const SCCOL nCol1, const SCROW nRow1, const SCCOL nCol2, const SCROW nRow2, sc::TableValues *pUndo)
bool EnsureFormulaCellResults(const SCCOL nCol1, SCROW nRow1, const SCCOL nCol2, SCROW nRow2, bool bSkipRunning=false)
void SwapNonEmpty(sc::TableValues &rValues, sc::StartListeningContext &rStartCxt, sc::EndListeningContext &rEndCxt)
std::set< SCCOL > QueryColumnsWithFormulaCells() const
void TransferCellValuesTo(const SCCOL nCol, SCROW nRow, size_t nLen, sc::CellValues &rDest)
void CopyCellValuesFrom(const SCCOL nCol, SCROW nRow, const sc::CellValues &rSrc)
void EndListeningIntersectedGroup(sc::EndListeningContext &rCxt, SCCOL nCol, SCROW nRow, std::vector< ScAddress > *pGroupPos)
void RegroupFormulaCells(SCCOL nCol)
void StoreToCache(SvStream &rStrm) const
bool SetLOKFreezeCol(SCCOL nFreezeCol)
void StartListeningFormulaCells(sc::StartListeningContext &rStartCxt, sc::EndListeningContext &rEndCxt, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2)
bool SetLOKFreezeRow(SCROW nFreezeRow)
bool IsMerged(SCCOL nCol, SCROW nRow) const
bool ReferencesSheet(SCTAB nTab, SCTAB nPosTab) const
Returns true if the sheet nTab is referenced in code.
void AdjustSheetLocalNameReferences(SCTAB nOldTab, SCTAB nNewTab)
When copying a sheet-local named expression, move sheet references that point to the originating shee...
void AdjustAbsoluteRefs(const ScDocument &rOldDoc, const ScAddress &rOldPos, const ScAddress &rNewPos, bool bCheckCopyArea)
Make all absolute references pointing to the copied range if the range is copied too.
void ReadjustAbsolute3DReferences(const ScDocument &rOldDoc, ScDocument &rNewDoc, const ScAddress &rPos, bool bRangeName=false)
Make all absolute references external references pointing to the old document.
Item2Range GetItemSurrogates(sal_uInt16 nWhich) const
const Color & GetValue() const
Think of this as a mini-ScColumn like storage that only stores cell values in a column.
Structure that stores segments of boolean flags per column, and perform custom action on those segmen...
void setSingleCellPattern(size_t nColOffset, const ScPatternAttr *pAttr)
void setSingleCellNote(size_t nColOffset, const ScPostIt *pNote)
void setSingleCellColumnSize(size_t nSize)
Set the column size of a "single cell" row, which is used when copying a single row of cells in a cli...
void setSingleSparkline(size_t nColOffset, std::shared_ptr< sc::Sparkline > const &pSparkline)
InsertDeleteFlags getInsertFlag() const
void setSingleCell(const ScAddress &rSrcPos, const ScColumn &rSrcCol)
SCTAB getTabStart() const
ScDocument * getUndoDoc()
ScDocument * getClipDoc()
void purgeEmptyBroadcasters()
Stores cell values for multiple tables.
const ScRange & getRange() const
Keep track of all named expressions that have been updated during reference update.
std::unordered_set< sal_uInt16 > NameIndicesType
NameIndicesType getUpdatedNames(SCTAB nTab) const
bool isNameUpdated(SCTAB nTab, sal_uInt16 nIndex) const
void setUpdatedName(SCTAB nTab, sal_uInt16 nIndex)
bool isEmpty(SCTAB nTab) const
constexpr ::Color COL_AUTO(ColorTransparency, 0xFF, 0xFF, 0xFF, 0xFF)
std::unique_ptr< ScTable, o3tl::default_delete< ScTable > > ScTableUniquePtr
SheetGeomType
Represents the type of sheet geometry data.
bool operator<(const ScDPCollection::DBType &left, const ScDPCollection::DBType &right)
@ SPARKLINES
Sheet / outlining (grouping) information.
@ NOTE
Strings (and string results if InsertDeleteFlags::FORMULA is not set).
@ ADDNOTES
Internal use only (undo etc.): do not copy/delete caption objects of cell notes.
#define SAL_WARN_IF(condition, area, stream)
#define SAL_WARN(area, stream)
std::unique_ptr< sal_Int32[]> pData
RttiCompleteObjectLocator col
void set(css::uno::UnoInterfaceReference const &value)
std::shared_ptr< T > make_shared(Args &&... args)
CAUTION! The following defines must be in the same namespace as the respective type.
constexpr TypedWhichId< SvxColorItem > ATTR_FONT_COLOR(109)
constexpr TypedWhichId< SvxBrushItem > ATTR_BACKGROUND(148)
Configuration options for formula interpreter.
ScRange getWholeRange() const
Return a single range that encompasses all individual ranges.
A pretty assertion that checks that the relevant bits in the @nFlags are not set on the document at e...
Context for reference update during shifting, moving or copying of cell ranges.
SCROW mnRowDelta
Amount and direction of movement in the row direction.
UpdateRefMode meMode
update mode - insert/delete, copy, or move.
SCCOL mnColDelta
Amount and direction of movement in the column direction.
SCTAB mnTabDelta
Amount and direction of movement in the sheet direction.
ScRange maRange
Range of cells that are about to be moved for insert/delete/move modes.
sal_Int32 SCCOLROW
a type capable of holding either SCCOL or SCROW