24 #include <officecfg/Office/Common.hxx>
52 #include <stlpool.hxx>
53 #include <stlsheet.hxx>
63 #include <progress.hxx>
64 #include <document.hxx>
71 #include <globstr.hrc>
72 #include <strings.hrc>
74 #include <charthelper.hxx>
82 #include <tokenarray.hxx>
108 pViewOptions.reset();
109 pExtDocOptions.reset();
114 if ( !mpPrinter && bCreateIfNotExist )
117 std::make_unique<SfxItemSet>( *mxPoolHelper->GetDocPool(),
118 svl::Items<SID_PRINTER_NOTFOUND_WARN, SID_PRINTER_NOTFOUND_WARN,
119 SID_PRINTER_CHANGESTODOC, SID_PRINTER_CHANGESTODOC,
120 SID_PRINT_SELECTEDSHEET, SID_PRINT_SELECTEDSHEET,
121 SID_SCPRINTOPTIONS, SID_SCPRINTOPTIONS>{} );
124 if (officecfg::Office::Common::Print::Warning::PaperOrientation::get())
125 nFlags |= SfxPrinterChangeFlags::CHG_ORIENTATION;
126 if (officecfg::Office::Common::Print::Warning::PaperSize::get())
127 nFlags |= SfxPrinterChangeFlags::CHG_SIZE;
128 pSet->Put(
SfxFlagItem( SID_PRINTER_CHANGESTODOC, static_cast<int>(nFlags) ) );
129 pSet->Put(
SfxBoolItem( SID_PRINTER_NOTFOUND_WARN, officecfg::Office::Common::Print::Warning::NotFound::get() ) );
132 mpPrinter->SetMapMode(
MapMode(MapUnit::Map100thMM));
134 mpPrinter->SetDigitLanguage(
SC_MOD()->GetOptDigitLanguage() );
142 if ( pNewPrinter == mpPrinter.
get() )
152 mpPrinter = pNewPrinter;
154 mpPrinter->SetDigitLanguage(
SC_MOD()->GetOptDigitLanguage() );
156 InvalidateTextWidth(
nullptr,
nullptr,
false);
161 if ( !mpPrinter ) GetPrinter();
162 OSL_ENSURE( mpPrinter,
"Error in printer creation :-/" );
167 SfxItemSet aOptSet( mpPrinter->GetOptions() );
170 if (officecfg::Office::Common::Print::Warning::PaperOrientation::get())
171 nFlags |= SfxPrinterChangeFlags::CHG_ORIENTATION;
172 if (officecfg::Office::Common::Print::Warning::PaperSize::get())
173 nFlags |= SfxPrinterChangeFlags::CHG_SIZE;
174 aOptSet.Put(
SfxFlagItem( SID_PRINTER_CHANGESTODOC, static_cast<int>(nFlags) ) );
175 aOptSet.Put(
SfxBoolItem( SID_PRINTER_NOTFOUND_WARN, officecfg::Office::Common::Print::Warning::NotFound::get() ) );
177 mpPrinter->SetOptions( aOptSet );
182 if (!mpVirtualDevice_100th_mm)
190 MapMode aMapMode( mpVirtualDevice_100th_mm->GetMapMode() );
191 aMapMode.SetMapUnit( MapUnit::Map100thMM );
192 mpVirtualDevice_100th_mm->SetMapMode( aMapMode );
194 return mpVirtualDevice_100th_mm;
201 if (
SC_MOD()->GetInputOptions().GetTextWysiwyg() )
202 pRefDevice = GetPrinter();
204 pRefDevice = GetVirtualDevice_100th_mm();
215 case SfxStyleFamily::Page:
217 const sal_uInt16 nOldScale = getScaleValue(rStyleSheet,
ATTR_PAGE_SCALE);
219 rSet.
Put( rChanges );
220 const sal_uInt16 nNewScale = getScaleValue(rStyleSheet,
ATTR_PAGE_SCALE);
223 if ( (nOldScale != nNewScale) || (nOldScaleToPages != nNewScaleToPages) )
224 InvalidateTextWidth( rStyleSheet.
GetName() );
235 case SfxStyleFamily::Para:
237 bool bNumFormatChanged;
240 InvalidateTextWidth(
nullptr,
nullptr, bNumFormatChanged );
244 maTabs[nTab]->SetStreamValid(
false );
252 if ( nNewFormat != nOldFormat )
268 if ( eState == SfxItemState::SET )
270 else if ( eState == SfxItemState::DONTCARE )
275 if ( eNewLang != eOldLang )
291 mxPoolHelper->GetStylePool()->CopyStdStylesFrom( rSrcDoc.
mxPoolHelper->GetStylePool() );
297 for (
SCTAB i=0;
i<nCount && maTabs[
i];
i++ )
298 if ( maTabs[
i]->GetPageStyle() == rStyleName )
299 InvalidateTextWidth(
i );
305 ScAddress aAdrTo ( MaxCol(), MaxRow(), nTab );
306 InvalidateTextWidth( &aAdrFrom, &aAdrTo,
false );
315 for ( i = 0; !bInUse && i < nCount && maTabs[i]; i++ )
316 bInUse = ( maTabs[i]->GetPageStyle() == rStrPageStyle );
326 bool bWasInUse =
false;
329 for (
SCTAB i=0;
i<nCount && maTabs[
i];
i++ )
330 if ( maTabs[
i]->GetPageStyle() == rStyle )
333 maTabs[
i]->SetPageStyle(
ScResId(STR_STYLENAME_STANDARD) );
341 bool bWasInUse =
false;
344 for (
SCTAB i=0;
i<nCount && maTabs[
i];
i++ )
345 if ( maTabs[
i]->GetPageStyle() == rOld )
348 maTabs[
i]->SetPageStyle( rNew );
358 OUString aStyleName = GetPageStyle( nTab );
359 SfxStyleSheetBase* pStyle = mxPoolHelper->GetStylePool()->Find( aStyleName, SfxStyleFamily::Page );
366 if ( eDirection == SvxFrameDirection::Horizontal_LR_TB )
367 eRet = EEHorizontalTextDirection::L2R;
368 else if ( eDirection == SvxFrameDirection::Horizontal_RL_TB )
369 eRet = EEHorizontalTextDirection::R2L;
380 return mpMacroMgr.get();
386 const ScTable* pTab = FetchTable(nTab);
390 if (nCol1 > nCol2 || nRow1 > nRow2)
395 if (static_cast<SCROW>(nR) != nRow2 - nRow1 + 1 || static_cast<SCCOL>(nC) != nCol2 - nCol1 + 1)
398 pTab->
FillMatrix(rMat, nCol1, nRow1, nCol2, nRow2, pPool);
416 assert(IsThreadedGroupCalcInProgress());
418 maThreadSpecific.pContext = &rContext;
421 assert(IsThreadedGroupCalcInProgress());
422 maThreadSpecific.pContext =
nullptr;
426 if(maThreadSpecific.xRecursionHelper)
427 maThreadSpecific.xRecursionHelper->Clear();
432 assert(!IsThreadedGroupCalcInProgress());
435 GetNonThreadedContext().maDelayedSetNumberFormat.clear();
437 ScTable* pTab = FetchTable(nTab);
445 bool bNumFormatChanged )
447 bool bBroadcast = (bNumFormatChanged && GetDocOptions().IsCalcAsShown() && !IsImportingXML() && !IsClipboard());
448 if ( pAdrFrom && !pAdrTo )
452 if (nTab < static_cast<SCTAB>(maTabs.size()) && maTabs[nTab] )
453 maTabs[nTab]->InvalidateTextWidth( pAdrFrom,
nullptr, bNumFormatChanged, bBroadcast );
457 const SCTAB nTabStart = pAdrFrom ? pAdrFrom->
Tab() : 0;
460 for (
SCTAB nTab=nTabStart; nTab<=nTabEnd && nTab < static_cast<SCTAB>(maTabs.size()); nTab++ )
462 maTabs[nTab]->InvalidateTextWidth( pAdrFrom, pAdrTo, bNumFormatChanged, bBroadcast );
466 #define CALCMAX 1000 // Calculations
490 ~IdleCalcTextWidthScope() COVERITY_NOEXCEPT_FALSE
494 pDev->SetMapMode(maOldMapMode);
506 void setTab(
SCTAB nTab) { mrCalcPos.
SetTab(nTab); }
507 void setCol(
SCCOL nCol) { mrCalcPos.
SetCol(nCol); }
508 void setRow(
SCROW nRow) { mrCalcPos.
SetRow(nRow); }
510 void incTab() { mrCalcPos.
IncTab(); }
511 void incCol(
SCCOL nInc) { mrCalcPos.
IncCol(nInc); }
513 void setOldMapMode(
const MapMode& rOldMapMode) { maOldMapMode = rOldMapMode; }
515 void setNeedMore(
bool b) { mbNeedMore = b; }
516 bool getNeedMore()
const {
return mbNeedMore; }
518 void createProgressBar()
524 bool hasProgressBar()
const {
return mbProgress; }
534 if (!mbIdleEnabled || IsInLinkUpdate() || GetPrinter(
false) ==
nullptr)
537 IdleCalcTextWidthScope aScope(*
this, aCurTextWidthCalcPos);
545 if (aScope.Col() < 0)
547 aScope.setCol(MaxCol());
551 if (!
ValidTab(aScope.Tab()) || aScope.Tab() >=
static_cast<SCTAB>(maTabs.size()) || !maTabs[aScope.Tab()])
554 ScTable* pTab = maTabs[aScope.Tab()].get();
556 OSL_ENSURE( pStyle,
"Missing StyleSheet :-/" );
572 std::unique_ptr<ScColumnTextWidthIterator> pColIter(
new ScColumnTextWidthIterator(*
this, *pCol, aScope.Row(), MaxRow()));
575 sal_uInt16 nRestart = 0;
577 while ( (nZoom > 0) && (nCount <
CALCMAX) && (nRestart < 2) )
579 if (pColIter->hasCell())
582 SCROW nRow = pColIter->getPos();
597 nPPTX = aPix1000.X() / 1000.0;
598 nPPTY = aPix1000.Y() / 1000.0;
602 aScope.createProgressBar();
604 sal_uInt16 nNewWidth =
static_cast<sal_uInt16
>(GetNeededSize(
605 aScope.Col(), aScope.Row(), aScope.Tab(),
606 pDev,
nPPTX,
nPPTY, aZoomFract,aZoomFract,
true,
true));
608 pColIter->setValue(nNewWidth);
609 aScope.setNeedMore(
true);
617 bool bNewTab =
false;
622 if (aScope.Col() < 0)
625 aScope.setCol(MaxCol());
630 if (!
ValidTab(aScope.Tab()) || aScope.Tab() >=
static_cast<SCTAB>(maTabs.size()) || !maTabs[aScope.Tab()] )
642 pTab = maTabs[aScope.Tab()].get();
644 pStyle =
static_cast<ScStyleSheet*
>(aScope.getStylePool()->Find(
662 OSL_FAIL(
"Missing StyleSheet :-/" );
668 pCol = &pTab->
aCol[aScope.Col()];
681 if (!aScope.continueIter())
685 return aScope.getNeedMore();
690 if ( bIsVisible && mpShell )
692 ScModelObj* pModel = comphelper::getUnoTunnelImplementation<ScModelObj>( mpShell->GetModel() );
700 if ( bIsVisible && mpShell )
702 ScModelObj* pModel = comphelper::getUnoTunnelImplementation<ScModelObj>( mpShell->GetModel() );
713 const ::sfx2::SvBaseLinks& rLinks = GetLinkManager()->GetLinks();
714 sal_uInt16
nCount = rLinks.size();
718 sal_uInt16 nDdeCount = 0;
720 for (i=0; i<nCount; i++)
735 for (i=0; i<nCount; i++)
741 pLink->Store( rStream, aHdr );
758 const size_t nMinStringSize = eCharSet == RTL_TEXTENCODING_UNICODE ?
sizeof(sal_uInt32) :
sizeof(sal_uInt16);
759 const size_t nMinRecordSize = 1 + nMinStringSize*3;
760 const size_t nMaxRecords = rStream.
remainingSize() / nMinRecordSize;
761 if (nCount > nMaxRecords)
763 SAL_WARN(
"sc",
"Parsing error: " << nMaxRecords <<
764 " max possible entries, but " << nCount <<
" claimed, truncating");
765 nCount = nMaxRecords;
768 for (sal_uInt16
i=0;
i<nCount; ++
i)
779 OSL_ENSURE( bInLinkUpdate != bSet,
"SetInLinkUpdate twice" );
780 bInLinkUpdate = bSet;
785 return bInLinkUpdate || IsInDdeLinkUpdate();
790 if (!pExternalRefMgr)
797 const ::sfx2::SvBaseLinks& rLinks = pMgr->
GetLinks();
798 sal_uInt16
nCount = rLinks.size();
803 std::vector<ScExternalRefLink*> aRefLinks;
804 for (sal_uInt16
i = 0;
i < nCount; ++
i)
809 aRefLinks.push_back(pRefLink);
814 pExternalRefMgr->enableDocTimer(
false);
815 ScProgress aProgress(GetDocumentShell(),
ScResId(SCSTR_UPDATE_EXTDOCS), aRefLinks.size(),
true);
816 for (
size_t i = 0,
n = aRefLinks.size();
i <
n; ++
i)
839 VclMessageType::Warning, VclButtonsType::Ok,
844 pExternalRefMgr->enableDocTimer(
true);
850 mpShell->Broadcast(
SfxHint(SfxHintId::ScDataChanged) );
853 if (!mpShell->IsModified())
855 mpShell->SetModified();
887 for (
const auto & rLink : rLinks)
890 if (
const ScDdeLink*
p = dynamic_cast<const ScDdeLink*>(pBase))
907 std::u16string_view rAppl, std::u16string_view rTopic, std::u16string_view rItem,
sal_uInt8 nMode,
908 size_t* pnDdePos =
nullptr )
912 const ::sfx2::SvBaseLinks& rLinks = pLinkManager->
GetLinks();
913 size_t nCount = rLinks.size();
914 if( pnDdePos ) *pnDdePos = 0;
918 if(
ScDdeLink* pDdeLink = dynamic_cast<ScDdeLink*>( pLink ) )
920 if( (pDdeLink->GetAppl() == rAppl) &&
921 (pDdeLink->GetTopic() == rTopic) &&
922 (pDdeLink->GetItem() == rItem) &&
925 if( pnDdePos ) ++*pnDdePos;
939 const ::sfx2::SvBaseLinks& rLinks = pLinkManager->
GetLinks();
940 size_t nCount = rLinks.size();
941 size_t nDdeIndex = 0;
945 if(
ScDdeLink* pDdeLink = dynamic_cast<ScDdeLink*>( pLink ) )
947 if( nDdeIndex == nDdePos )
961 return lclGetDdeLink( GetLinkManager(), rAppl, rTopic, rItem, nMode, &rnDdePos ) !=
nullptr;
966 if(
const ScDdeLink* pDdeLink = lclGetDdeLink( GetLinkManager(), nDdePos ) )
968 rAppl = pDdeLink->GetAppl();
969 rTopic = pDdeLink->GetTopic();
970 rItem = pDdeLink->GetItem();
978 if(
const ScDdeLink* pDdeLink = lclGetDdeLink( GetLinkManager(), nDdePos ) )
980 rnMode = pDdeLink->GetMode();
988 const ScDdeLink* pDdeLink = lclGetDdeLink( GetLinkManager(), nDdePos );
989 return pDdeLink ? pDdeLink->
GetResult() :
nullptr;
998 OSL_ENSURE( nMode !=
SC_DDE_IGNOREMODE,
"ScDocument::CreateDdeLink - SC_DDE_IGNOREMODE not allowed here" );
1006 ScDdeLink* pDdeLink = lclGetDdeLink(pMgr, rAppl, rTopic, rItem, nMode);
1010 pDdeLink =
new ScDdeLink( *
this, rAppl, rTopic, rItem, nMode );
1025 if(
ScDdeLink* pDdeLink = lclGetDdeLink( GetLinkManager(), nDdePos ) )
1027 pDdeLink->SetResult( pResults );
1039 const ::sfx2::SvBaseLinks& rLinks = pMgr->
GetLinks();
1040 sal_uInt16 nCount = rLinks.size();
1041 for (sal_uInt16
i=0;
i<nCount;
i++)
1042 if (
nullptr != dynamic_cast<const ScAreaLink* >(rLinks[
i].
get()))
1054 const ::sfx2::SvBaseLinks& rLinks = pMgr->
GetLinks();
1055 for (
const auto & rLink : rLinks)
1058 if (dynamic_cast<const ScAreaLink*>( pBase) !=
nullptr)
1069 const ::sfx2::SvBaseLinks& rLinks = pMgr->
GetLinks();
1070 sfx2::SvBaseLinks::size_type
nPos = 0;
1071 while ( nPos < rLinks.size() )
1073 const ::sfx2::SvBaseLink* pBase = rLinks[nPos].get();
1089 bool bAnyUpdate =
false;
1091 const ::sfx2::SvBaseLinks& rLinks = pMgr->
GetLinks();
1092 sal_uInt16 nCount = rLinks.size();
1093 for (sal_uInt16
i=0;
i<nCount;
i++)
1096 if (
ScAreaLink* pLink = dynamic_cast<ScAreaLink*>(pBase))
1098 ScRange aOutRange = pLink->GetDestArea();
1111 nCol1, nRow1, nTab1, nCol2, nRow2, nTab2 );
1114 pLink->SetDestArea(
ScRange( nCol1, nRow1, nTab1, nCol2, nRow2, nTab2 ) );
1127 sal_uInt16 nFirstIndex = 0;
1128 while ( nFirstIndex < nCount )
1130 bool bFound =
false;
1132 if (
ScAreaLink* pFirstLink = dynamic_cast<ScAreaLink*>(pFirst))
1134 ScAddress aFirstPos = pFirstLink->GetDestArea().aStart;
1135 for ( sal_uInt16 nSecondIndex = nFirstIndex + 1; nSecondIndex < nCount && !bFound; ++nSecondIndex )
1143 nCount = rLinks.size();
1155 if (HasLinkFormulaNeedingCheck())
1162 SetLinkFormulaNeedingCheck(
true);
1167 SetLinkFormulaNeedingCheck(
true);
1174 SAL_WARN(
"sc.core",
"ScDocument::CheckLinkFormulaNeedingCheck - called with empty ScTokenArray");
1181 if ( pChartListenerCollection->hasListeners() )
1182 pChartListenerCollection->StartTimer();
1183 if (apTemporaryChartLock)
1184 apTemporaryChartLock->StartOrContinueLocking();
1197 pViewFrame =
nullptr;
1211 OSL_ENSURE( rMultiMark.
IsMultiMarked(),
"TransliterateText: no selection" );
1214 bool bConsiderLanguage = aTransliterationWrapper.needLanguageForTheMode();
1217 std::unique_ptr<ScEditEngineDefaulter> pEngine;
1219 SCTAB nCount = GetTableCount();
1220 for (
const SCTAB& nTab : rMultiMark)
1230 bool bFound = rMultiMark.IsCellMarked( nCol, nRow );
1232 bFound = GetNextMarkedCell( nCol, nRow, nTab, rMultiMark );
1243 ( nType == TransliterationFlags::SENTENCE_CASE || nType == TransliterationFlags::TITLE_CASE)))
1249 const ScPatternAttr* pPattern = GetPattern( nCol, nRow, nTab );
1250 std::unique_ptr<SfxItemSet> pDefaults(
new SfxItemSet( pEngine->GetEmptyItemSet() ));
1251 if (
ScStyleSheet* pPreviewStyle = GetPreviewCellStyle( nCol, nRow, nTab ) )
1253 std::unique_ptr<ScPatternAttr> pPreviewPattern(
new ScPatternAttr( *pPattern ));
1254 pPreviewPattern->SetStyleSheet(pPreviewStyle);
1255 pPreviewPattern->FillEditItemSet( pDefaults.get() );
1259 SfxItemSet* pFontSet = GetPreviewFont( nCol, nRow, nTab );
1262 pEngine->SetDefaults( std::move(pDefaults) );
1266 pEngine->SetTextCurrentDefaults(*aCell.
mpEditText);
1268 pEngine->ClearModifyFlag();
1270 sal_Int32 nLastPar = pEngine->GetParagraphCount();
1273 sal_Int32 nTxtLen = pEngine->GetTextLen(nLastPar);
1274 ESelection aSelAll( 0, 0, nLastPar, nTxtLen );
1276 pEngine->TransliterateText( aSelAll, nType );
1278 if ( pEngine->IsModified() )
1281 if ( aTester.NeedsObject() )
1284 pEngine->SetDefaults( std::make_unique<SfxItemSet>( pEngine->GetEmptyItemSet() ) );
1287 SetEditText(
ScAddress(nCol,nRow,nTab), pEngine->CreateTextObject());
1301 sal_Int32 nOldLen = aOldStr.getLength();
1303 if ( bConsiderLanguage )
1312 uno::Sequence<sal_Int32> aOffsets;
1313 OUString aNewStr = aTransliterationWrapper.transliterate( aOldStr, nLanguage, 0, nOldLen, &aOffsets );
1315 if ( aNewStr != aOldStr )
1322 bFound = GetNextMarkedCell( nCol, nRow, nTab, rMultiMark );
Matrix data type that can store values of mixed types.
void EnableIdle(bool bDo)
void CalculateInColumnInThread(ScInterpreterContext &rContext, const ScRange &rCalcRange, unsigned nThisThread, unsigned nThreadsTotal)
static ScRefUpdateRes Update(const ScDocument *pDoc, UpdateRefMode eUpdateRefMode, SCCOL nCol1, SCROW nRow1, SCTAB nTab1, SCCOL nCol2, SCROW nRow2, SCTAB nTab2, SCCOL nDx, SCROW nDy, SCTAB nDz, SCCOL &theCol1, SCROW &theRow1, SCTAB &theTab1, SCCOL &theCol2, SCROW &theRow2, SCTAB &theTab2)
OUString getString() const
todo: It should be possible to have MarkArrays for each table, in order to enable "search all" across...
Store parameters used in the ScDocument::SetString() method.
constexpr TypedWhichId< SvxLanguageItem > ATTR_LANGUAGE_FORMAT(147)
void HandleStuffAfterParallelCalculation(SCCOL nColStart, SCCOL nColEnd, SCROW nRow, size_t nLen, SCTAB nTab, ScInterpreter *pInterpreter)
void LoadDdeLinks(SvStream &rStream)
SvStream & WriteUInt16(sal_uInt16 nUInt16)
void IncTab(SCTAB nDelta=1)
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. ...
void setTextInput()
Call this whenever you need to unconditionally set input as text, no matter what the input is...
constexpr TypedWhichId< SvxLanguageItem > ATTR_CJK_FONT_LANGUAGE(115)
constexpr sal_uInt16 ATTR_PATTERN_START(100)
SvStream & ReadUInt16(sal_uInt16 &rUInt16)
sal_Int32 GetVersion() const
void SetInLinkUpdate(bool bSet)
SC_DLLPUBLIC void CopyStdStylesFrom(const ScDocument &rSrcDoc)
void FillMatrix(ScMatrix &rMat, SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, svl::SharedStringPool *pPool=nullptr) const
constexpr TypedWhichId< SfxUInt16Item > ATTR_PAGE_SCALETOPAGES(175)
bool IsPageStyleInUse(std::u16string_view rStrPageStyle, SCTAB *pInTab)
constexpr TypedWhichId< SvxLanguageItem > ATTR_FONT_LANGUAGE(110)
const sal_uInt8 SC_DDE_DEFAULT
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.
void ModifyStyleSheet(SfxStyleSheetBase &rPageStyle, const SfxItemSet &rChanges)
void SetFormulaResults(SCCOL nCol, SCROW nRow, const double *pResults, size_t nLen)
const MapMode & GetMapMode() const
VirtualDevice * GetVirtualDevice_100th_mm()
virtual SfxItemSet & GetItemSet()
This is very similar to ScCellValue, except that it references the original value instead of copying ...
void RepaintRange(const ScRange &rRange)
void Invalidate(sal_uInt16 nId)
sc::DocumentLinkManager & GetDocLinkManager()
SfxStyleFamily GetFamily() const
virtual SfxObjectShell * GetObjectShell() override
void SetPrinter(VclPtr< SfxPrinter > const &pNewPrinter)
sfx2::LinkManager * getLinkManager(bool bCreate=true)
void SetString(SwCursor &rCursor, const OUString &rString)
void TransliterateText(const ScMarkData &rMultiMark, TransliterationFlags nType)
SfxPrinter * GetPrinter(bool bCreateIfNotExist=true)
void CalculateInColumnInThread(ScInterpreterContext &rContext, SCCOL nColStart, SCCOL nColEnd, SCROW nRowStart, SCROW nRowEnd, unsigned nThisThread, unsigned nThreadsTotal)
void RepaintRange(const ScRange &rRange)
SC_DLLPUBLIC void CheckLinkFormulaNeedingCheck(const ScTokenArray &rCode)
Check token array and set link check if ocDde/ocWebservice is contained.
const OUString & GetName() const
const EditTextObject * mpEditText
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 ...
const BorderLinePrimitive2D *pCandidateB assert(pCandidateA)
void FillMatrix(ScMatrix &rMat, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, svl::SharedStringPool *pPool) const
bool IsMultiMarked() const
bool SetDdeLinkResultMatrix(size_t nDdePos, const ScMatrixRef &pResults)
Sets a result matrix for the specified DDE link.
::boost::intrusive_ptr< ScMatrix > ScMatrixRef
void HandleStuffAfterParallelCalculation(SCCOL nColStart, SCCOL nColEnd, SCROW nRow, size_t nLen, ScInterpreter *pInterpreter)
bool RemovePageStyleInUse(std::u16string_view rStrPageStyle)
const sal_uInt8 SC_DDE_IGNOREMODE
sal_uInt64 remainingSize()
sal_uInt16 ClearItem(sal_uInt16 nWhich=0)
SfxItemState GetItemState(sal_uInt16 nWhich, bool bSrchInParent=true, const SfxPoolItem **ppItem=nullptr) const
const SvBaseLinks & GetLinks() const
const OUString & GetItem() const
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.
void Remove(SvBaseLink const *pLink)
void IncCol(SCCOL nDelta=1)
void GetDimensions(SCSIZE &rC, SCSIZE &rR) const
const svl::SharedString * mpString
SC_DLLPUBLIC const ScMatrix * GetDdeLinkResultMatrix(size_t nDdePos) const
Returns the result matrix of the specified DDE link.
bool GetDdeLinkData(size_t nDdePos, OUString &rAppl, OUString &rTopic, OUString &rItem) const
Returns the connection data of the specified DDE link.
bool HasAreaLinks() const
SfxBindings & GetBindings()
bool GetDdeLinkMode(size_t nDdePos, sal_uInt8 &rnMode) const
Returns the link mode of the specified DDE link.
const ScRange & GetDestArea() const
EEHorizontalTextDirection
bool RenamePageStyleInUse(std::u16string_view rOld, const OUString &rNew)
OUString ScResId(const char *pId)
#define LANGUAGE_DONTKNOW
constexpr TypedWhichId< SfxUInt32Item > ATTR_VALUE_FORMAT(146)
static void DeleteInterpretProgress()
void SaveDdeLinks(SvStream &rStream) const
static void CreateInterpretProgress(ScDocument *pDoc, bool bWait=true)
Use this class as a locale variable to merge number formatter from another document, and set NULL pointer to pFormatExchangeList when done.
void UpdateRefAreaLinks(UpdateRefMode eUpdateRefMode, const ScRange &r, SCCOL nDx, SCROW nDy, SCTAB nDz)
Reference not affected, no change at all.
exports com.sun.star.chart2. data
SC_DLLPUBLIC ScMacroManager * GetMacroManager()
Point LogicToPixel(const Point &rLogicPt) const
void InvalidateTextWidth(std::u16string_view rStyleName)
OUString GetMainURL(DecodeMechanism eMechanism, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8) const
constexpr TypedWhichId< SvxLanguageItem > ATTR_CTL_FONT_LANGUAGE(120)
void SetState(sal_uLong nVal, sal_uLong nNewRange=0)
static bool GetDisplayNames(const SvBaseLink *, OUString *pType, OUString *pFile=nullptr, OUString *pLink=nullptr, OUString *pFilter=nullptr)
constexpr TypedWhichId< SvxFrameDirectionItem > ATTR_WRITINGDIR(138)
const ScMatrix * GetResult() const
void InsertDDELink(SvBaseLink *, const OUString &rServer, std::u16string_view rTopic, std::u16string_view rItem)
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
void UpdateExternalRefLinks(weld::Window *pWin)
EEHorizontalTextDirection GetEditTextDirection(SCTAB nTab) const
SC_DLLPUBLIC OutputDevice * GetRefDevice()
void SetResult(const ScMatrixRef &pRes)
std::vector< tools::SvRef< SvBaseLink > > SvBaseLinks
static SfxViewFrame * Current()
const OUString & GetTopic() const
const SfxPoolItem & Get(sal_uInt16 nWhich, bool bSrchInParent=true) const
bool IsCTLFontEnabled() const
SfxBindings * GetViewBindings()
static VclPtr< reference_type > Create(Arg &&...arg)
static bool CheckWidthInvalidate(bool &bNumFormatChanged, const SfxItemSet &rNewAttrs, const SfxItemSet &rOldAttrs)
rtl_TextEncoding GetStreamCharSet() const
Reference< XComponentContext > getProcessComponentContext()
constexpr sal_uInt16 ATTR_PATTERN_END(155)
void DeleteAreaLinksOnTab(SCTAB nTab)
SC_DLLPUBLIC ScStyleSheetPool * GetStyleSheetPool() const
bool IsInLinkUpdate() const
bool ValidRow(SCROW nRow, SCROW nMaxRow)
reference_type * get() const
rtl::Reference< ScPoolHelper > mxPoolHelper
static SfxViewFrame * GetFirst(const SfxObjectShell *pDoc=nullptr, bool bOnlyVisible=true)
#define SAL_WARN(area, stream)
SC_DLLPUBLIC void CopyDdeLinks(ScDocument &rDestDoc) const
SCCOL ClampToAllocatedColumns(SCCOL nCol) const
bool IsFormulaDirty(SCROW nRow) const
const OUString & GetAppl() const
constexpr TypedWhichId< SfxUInt16Item > ATTR_PAGE_SCALE(174)
bool ValidTab(SCTAB nTab)
static weld::MessageDialog * CreateMessageDialog(weld::Widget *pParent, VclMessageType eMessageType, VclButtonsType eButtonType, const OUString &rPrimaryMessage, bool bMobile=false)
static sal_uInt16 DoUpdateAllCharts(ScDocument &rDoc)
void FillEditItemSet(SfxItemSet *pEditSet, const SfxItemSet *pCondSet=nullptr) const
Converts all Calc items contained in the own item set to edit engine items and puts them into pEditSe...