chart2/source/controller/drawinglayer/DrawViewWrapper.cxx | 2 - editeng/inc/editdoc.hxx | 4 +++ editeng/source/editeng/editeng.cxx | 8 +++---- editeng/source/editeng/impedit.hxx | 4 --- editeng/source/editeng/impedit2.cxx | 1 editeng/source/editeng/impedit4.cxx | 2 - editeng/source/outliner/outlin2.cxx | 8 +++---- include/editeng/editeng.hxx | 4 +-- include/editeng/outliner.hxx | 4 +-- sc/inc/document.hxx | 1 sc/inc/editutil.hxx | 8 ++----- sc/inc/textuno.hxx | 4 +-- sc/source/core/data/column2.cxx | 2 - sc/source/core/data/column3.cxx | 4 +-- sc/source/core/data/documen2.cxx | 11 ++------- sc/source/core/data/documen8.cxx | 2 - sc/source/core/data/drwlayer.cxx | 4 +-- sc/source/core/data/poolhelp.cxx | 11 --------- sc/source/core/data/stlpool.cxx | 2 - sc/source/core/data/table4.cxx | 1 sc/source/core/inc/poolhelp.hxx | 2 - sc/source/core/tool/editutil.cxx | 16 +++----------- sc/source/filter/excel/xlroot.cxx | 1 sc/source/filter/oox/workbookhelper.cxx | 1 sc/source/filter/rtf/eeimpars.cxx | 2 - sc/source/filter/rtf/expbase.cxx | 2 - sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx | 4 +-- sc/source/filter/xml/XMLTrackedChangesContext.cxx | 3 -- sc/source/filter/xml/xmlexprt.cxx | 4 +-- sc/source/filter/xml/xmlfonte.cxx | 2 - sc/source/filter/xml/xmlimprt.cxx | 1 sc/source/ui/Accessibility/AccessibleText.cxx | 6 ++--- sc/source/ui/app/inputhdl.cxx | 2 - sc/source/ui/app/inputwin.cxx | 8 +++---- sc/source/ui/app/transobj.cxx | 2 - sc/source/ui/docshell/docsh8.cxx | 2 - sc/source/ui/unoobj/cellsuno.cxx | 1 sc/source/ui/unoobj/textuno.cxx | 13 ++++++----- sc/source/ui/view/gridwin.cxx | 2 - sc/source/ui/view/spelleng.cxx | 2 - sc/source/ui/view/viewfun2.cxx | 2 - sc/source/ui/view/viewfun4.cxx | 1 sc/source/ui/view/viewfunc.cxx | 2 - sd/source/core/sdpage.cxx | 2 - sd/source/ui/view/Outliner.cxx | 1 svx/source/svdraw/svdetc.cxx | 1 svx/source/svdraw/svdmodel.cxx | 2 - 47 files changed, 68 insertions(+), 106 deletions(-)
New commits: commit 4f8b32e92c0e85430c49e00ce0b32dff55a20efd Author: Noel Grandin <noelgran...@gmail.com> AuthorDate: Wed Jul 16 18:07:14 2025 +0200 Commit: Noel Grandin <noelgran...@gmail.com> CommitDate: Sat Jul 19 14:23:31 2025 +0200 Drop separate EditTextObject itempool and just have a single pool for the EditEngine machinery. I cannot find a reason for a separat pool anymore, probably it was a thing from the distant past. This also shaves 5% off the load time of tdf#162126 because we no longer have to spend losts of time re-creating SfxItemSets because they belong to different pools. Change-Id: I837045809dc292548b10e2cf5173d2a29b0879a0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/187969 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/chart2/source/controller/drawinglayer/DrawViewWrapper.cxx b/chart2/source/controller/drawinglayer/DrawViewWrapper.cxx index 74be51a5ee11..4c345b6eb783 100644 --- a/chart2/source/controller/drawinglayer/DrawViewWrapper.cxx +++ b/chart2/source/controller/drawinglayer/DrawViewWrapper.cxx @@ -84,7 +84,7 @@ DrawViewWrapper::DrawViewWrapper( // #i12587# support for shapes in chart SdrOutliner* pOutliner = getOutliner(); - SfxItemPool* pOutlinerPool = ( pOutliner ? pOutliner->GetEditTextObjectPool() : nullptr ); + SfxItemPool* pOutlinerPool = ( pOutliner ? pOutliner->GetEditEnginePool() : nullptr ); if ( pOutlinerPool ) { SvtLinguConfig aLinguConfig; diff --git a/editeng/inc/editdoc.hxx b/editeng/inc/editdoc.hxx index 13a1d3f1d1a4..43fbcc7027ae 100644 --- a/editeng/inc/editdoc.hxx +++ b/editeng/inc/editdoc.hxx @@ -215,6 +215,10 @@ public: { return *mpItemPool; } + void SetItemPool(SfxItemPool* pPool) + { + mpItemPool = pPool; + } void InsertAttrib( const SfxPoolItem& rItem, ContentNode* pNode, sal_Int32 nStart, sal_Int32 nEnd ); void InsertAttrib( ContentNode* pNode, sal_Int32 nStart, sal_Int32 nEnd, const SfxPoolItem& rPoolItem ); diff --git a/editeng/source/editeng/editeng.cxx b/editeng/source/editeng/editeng.cxx index 3a0a0eb2eb24..b9a23c68f4d2 100644 --- a/editeng/source/editeng/editeng.cxx +++ b/editeng/source/editeng/editeng.cxx @@ -1194,14 +1194,14 @@ bool EditEngine::IsTextPos( const Point& rPaperPos, sal_uInt16 nBorder ) return false; } -void EditEngine::SetEditTextObjectPool( SfxItemPool* pPool ) +void EditEngine::SetItemPool( SfxItemPool* pPool ) { - getImpl().SetEditTextObjectPool(pPool); + getImpl().GetEditDoc().SetItemPool(pPool); } -SfxItemPool* EditEngine::GetEditTextObjectPool() const +SfxItemPool* EditEngine::GetItemPool() const { - return getImpl().GetEditTextObjectPool(); + return &getImpl().GetEditDoc().GetItemPool(); } void EditEngine::QuickSetAttribs( const SfxItemSet& rSet, const ESelection& rSel ) diff --git a/editeng/source/editeng/impedit.hxx b/editeng/source/editeng/impedit.hxx index 32bcbd1337d1..8e61f99c8dd6 100644 --- a/editeng/source/editeng/impedit.hxx +++ b/editeng/source/editeng/impedit.hxx @@ -557,7 +557,6 @@ private: std::unique_ptr<TextRanger> mpTextRanger; SfxStyleSheetPool* mpStylePool; - SfxItemPool* mpTextObjectPool; VclPtr<VirtualDevice> mpVirtDev; VclPtr<OutputDevice> mpRefDev; @@ -1267,9 +1266,6 @@ public: sal_Int32 StartSearchAndReplace( EditView* pEditView, const SvxSearchItem& rSearchItem ); bool HasText( const SvxSearchItem& rSearchItem ); - void SetEditTextObjectPool( SfxItemPool* pP ) { mpTextObjectPool = pP; } - SfxItemPool* GetEditTextObjectPool() const { return mpTextObjectPool; } - const SvxNumberFormat * GetNumberFormat( const ContentNode* pNode ) const; sal_Int32 GetSpaceBeforeAndMinLabelWidth( const ContentNode *pNode, sal_Int32 *pnSpaceBefore = nullptr, sal_Int32 *pnMinLabelWidth = nullptr ) const; diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx index 423223e6357f..a03026da03ad 100644 --- a/editeng/source/editeng/impedit2.cxx +++ b/editeng/source/editeng/impedit2.cxx @@ -103,7 +103,6 @@ ImpEditEngine::ImpEditEngine( EditEngine* pEE, SfxItemPool* pItemPool ) : mpEditEngine(pEE), mpActiveView(nullptr), mpStylePool(nullptr), - mpTextObjectPool(nullptr), mpUndoManager(nullptr), maWordDelimiters(u" .,;:-`'?!_=\"{}()[]"_ustr), maBackgroundColor(COL_AUTO), diff --git a/editeng/source/editeng/impedit4.cxx b/editeng/source/editeng/impedit4.cxx index c21eecb893a2..b8e9e0a0de81 100644 --- a/editeng/source/editeng/impedit4.cxx +++ b/editeng/source/editeng/impedit4.cxx @@ -1185,7 +1185,7 @@ std::unique_ptr<EditTextObject> ImpEditEngine::CreateTextObject() std::unique_ptr<EditTextObject> ImpEditEngine::CreateTextObject(const EditSelection& rSel) { - return CreateTextObject(rSel, GetEditTextObjectPool(), maStatus.AllowBigObjects(), mnBigTextObjectStart); + return CreateTextObject(rSel, &maEditDoc.GetItemPool(), maStatus.AllowBigObjects(), mnBigTextObjectStart); } std::unique_ptr<EditTextObject> ImpEditEngine::CreateTextObject( EditSelection aSel, SfxItemPool* pPool, bool bAllowBigObjects, sal_Int32 nBigObjectStart ) diff --git a/editeng/source/outliner/outlin2.cxx b/editeng/source/outliner/outlin2.cxx index 2305d85b50f0..a53c11db8676 100644 --- a/editeng/source/outliner/outlin2.cxx +++ b/editeng/source/outliner/outlin2.cxx @@ -358,14 +358,14 @@ bool Outliner::HasText( const SvxSearchItem& rSearchItem ) return pEditEngine->HasText( rSearchItem ); } -void Outliner::SetEditTextObjectPool( SfxItemPool* pPool ) +void Outliner::SetEditEnginePool( SfxItemPool* pPool ) { - pEditEngine->SetEditTextObjectPool( pPool ); + pEditEngine->SetItemPool( pPool ); } -SfxItemPool* Outliner::GetEditTextObjectPool() const +SfxItemPool* Outliner::GetEditEnginePool() const { - return pEditEngine->GetEditTextObjectPool(); + return pEditEngine->GetItemPool(); } bool Outliner::SpellNextDocument() diff --git a/include/editeng/editeng.hxx b/include/editeng/editeng.hxx index 593fce2a59be..ca00ddd807d6 100644 --- a/include/editeng/editeng.hxx +++ b/include/editeng/editeng.hxx @@ -420,8 +420,8 @@ public: SAL_DLLPRIVATE void setRoundFontSizeToPt(bool bRound); - void SetEditTextObjectPool( SfxItemPool* pPool ); - SfxItemPool* GetEditTextObjectPool() const; + void SetItemPool( SfxItemPool* pPool ); + SfxItemPool* GetItemPool() const; void SetStyleSheetPool( SfxStyleSheetPool* pSPool ); SfxStyleSheetPool* GetStyleSheetPool(); diff --git a/include/editeng/outliner.hxx b/include/editeng/outliner.hxx index a6f740d3ec36..92d7117f5796 100644 --- a/include/editeng/outliner.hxx +++ b/include/editeng/outliner.hxx @@ -825,8 +825,8 @@ public: bool HasConvertibleTextPortion( LanguageType nLang ); virtual bool ConvertNextDocument(); - void SetEditTextObjectPool( SfxItemPool* pPool ); - SfxItemPool* GetEditTextObjectPool() const; + void SetEditEnginePool( SfxItemPool* pPool ); + SfxItemPool* GetEditEnginePool() const; void SetRefDevice( OutputDevice* pRefDev ); OutputDevice* GetRefDevice() const; diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx index 6c25687ef774..08b27296514f 100644 --- a/sc/inc/document.hxx +++ b/sc/inc/document.hxx @@ -2594,7 +2594,6 @@ public: void SetInLinkUpdate(bool bSet); // TableLink or AreaLink bool IsInLinkUpdate() const; // including DdeLink - SC_DLLPUBLIC SfxItemPool* GetEditTextObjectPool() const; SC_DLLPUBLIC SfxItemPool* GetEditEnginePool() const; SC_DLLPUBLIC ScFieldEditEngine& GetEditEngine(); SC_DLLPUBLIC ScNoteEditEngine& GetNoteEngine(); diff --git a/sc/inc/editutil.hxx b/sc/inc/editutil.hxx index 368690019913..b580a811d4da 100644 --- a/sc/inc/editutil.hxx +++ b/sc/inc/editutil.hxx @@ -178,8 +178,7 @@ private: public: ScFieldEditEngine( - ScDocument* pDoc, SfxItemPool* pEnginePool, SfxItemPool* pTextObjectPool = nullptr, - bool bDeleteEnginePool = false); + ScDocument* pDoc, SfxItemPool* pEnginePool, bool bDeleteEnginePool = false); void SetExecuteURL(bool bSet) { bExecuteURL = bSet; } @@ -195,8 +194,7 @@ private: public: ScTabEditEngine( ScDocument& rDoc ); // Default ScTabEditEngine(const ScPatternAttr& rPattern, - SfxItemPool *pEngineItemPool, ScDocument& rDoc, - SfxItemPool* pTextObjectPool = nullptr ); + SfxItemPool *pEngineItemPool, ScDocument& rDoc ); }; struct ScHeaderFieldData @@ -232,7 +230,7 @@ class ScNoteEditEngine final : public ScEditEngineDefaulter { public: - ScNoteEditEngine( SfxItemPool* pEnginePool, SfxItemPool* pTextObjectPool ); + ScNoteEditEngine( SfxItemPool* pEnginePool ); }; diff --git a/sc/inc/textuno.hxx b/sc/inc/textuno.hxx index 87faca864992..673b66d36994 100644 --- a/sc/inc/textuno.hxx +++ b/sc/inc/textuno.hxx @@ -298,7 +298,7 @@ class ScSimpleEditSourceHelper std::unique_ptr<ScSimpleEditSource> pOriginalSource; public: - ScSimpleEditSourceHelper(); + ScSimpleEditSourceHelper(SfxItemPool* pEditEnginePool); ~ScSimpleEditSourceHelper(); ScSimpleEditSource* GetOriginalSource() const { return pOriginalSource.get(); } @@ -308,7 +308,7 @@ public: class ScEditEngineTextObj final : public ScSimpleEditSourceHelper, public SvxUnoText { public: - ScEditEngineTextObj(); + ScEditEngineTextObj(SfxItemPool* pEditEngineItemPool); virtual ~ScEditEngineTextObj() noexcept override; void SetText( const EditTextObject& rTextObject ); diff --git a/sc/source/core/data/column2.cxx b/sc/source/core/data/column2.cxx index c3bf713ad2f4..cb88956f7ec6 100644 --- a/sc/source/core/data/column2.cxx +++ b/sc/source/core/data/column2.cxx @@ -1210,7 +1210,7 @@ public: // test for attributes if (!mpEngine) { - mpEngine.reset(new ScFieldEditEngine(&mrDoc, mrDoc.GetEditTextObjectPool())); + mpEngine.reset(new ScFieldEditEngine(&mrDoc, mrDoc.GetEditEnginePool())); // EEControlBits::ONLINESPELLING if there are errors already mpEngine->SetControlWord(mpEngine->GetControlWord() | EEControlBits::ONLINESPELLING); mrDoc.ApplyAsianEditSettings(*mpEngine); diff --git a/sc/source/core/data/column3.cxx b/sc/source/core/data/column3.cxx index 6c685d2061bb..a56bb6bbcb59 100644 --- a/sc/source/core/data/column3.cxx +++ b/sc/source/core/data/column3.cxx @@ -2394,7 +2394,7 @@ void ScColumn::SetEditText( sc::ColumnBlockPosition& rBlockPos, SCROW nRow, std: void ScColumn::SetEditText( sc::ColumnBlockPosition& rBlockPos, SCROW nRow, const EditTextObject& rEditText ) { - if (GetDoc().GetEditTextObjectPool() == rEditText.GetPool()) + if (GetDoc().GetEditEnginePool() == rEditText.GetPool()) { SetEditText(rBlockPos, nRow, rEditText.Clone()); return; @@ -2410,7 +2410,7 @@ void ScColumn::SetEditText( sc::ColumnBlockPosition& rBlockPos, SCROW nRow, cons void ScColumn::SetEditText( SCROW nRow, const EditTextObject& rEditText, const SfxItemPool* pEditPool ) { - if (pEditPool && GetDoc().GetEditTextObjectPool() == pEditPool) + if (pEditPool && GetDoc().GetEditEnginePool() == pEditPool) { SetEditText(nRow, rEditText.Clone()); return; diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx index 87a236dff2a6..dba7aaa821a7 100644 --- a/sc/source/core/data/documen2.cxx +++ b/sc/source/core/data/documen2.cxx @@ -486,11 +486,6 @@ SvNumberFormatter* ScDocument::GetFormatTable() const return mxPoolHelper->GetFormTable(); } -SfxItemPool* ScDocument::GetEditTextObjectPool() const -{ - return mxPoolHelper->GetEditTextObjectPool(); -} - SfxItemPool* ScDocument::GetEditEnginePool() const { return mxPoolHelper->GetEditEnginePool(); @@ -500,7 +495,7 @@ ScFieldEditEngine& ScDocument::GetEditEngine() { if ( !mpEditEngine ) { - mpEditEngine.reset( new ScFieldEditEngine(this, GetEditEnginePool(), GetEditTextObjectPool()) ); + mpEditEngine.reset( new ScFieldEditEngine(this, GetEditEnginePool()) ); mpEditEngine->SetUpdateLayout( false ); mpEditEngine->EnableUndo( false ); mpEditEngine->SetRefMapMode(MapMode(MapUnit::Map100thMM)); @@ -514,7 +509,7 @@ ScNoteEditEngine& ScDocument::GetNoteEngine() if ( !mpNoteEngine ) { ScMutationGuard aGuard(*this, ScMutationGuardFlags::CORE); - mpNoteEngine.reset( new ScNoteEditEngine( GetEditEnginePool(), GetEditTextObjectPool() ) ); + mpNoteEngine.reset( new ScNoteEditEngine( GetEditEnginePool() ) ); mpNoteEngine->SetUpdateLayout( false ); mpNoteEngine->EnableUndo( false ); mpNoteEngine->SetRefMapMode(MapMode(MapUnit::Map100thMM)); @@ -1211,7 +1206,7 @@ std::unique_ptr<ScFieldEditEngine> ScDocument::CreateFieldEditEngine() if (!pCacheFieldEditEngine) { pNewEditEngine.reset( new ScFieldEditEngine( - this, GetEditEnginePool(), GetEditTextObjectPool(), false) ); + this, GetEditEnginePool(), false) ); } else { diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx index 1208ed0f3cd3..8d4d70eb4437 100644 --- a/sc/source/core/data/documen8.cxx +++ b/sc/source/core/data/documen8.cxx @@ -1241,7 +1241,7 @@ void ScDocument::TransliterateText( const ScMarkData& rMultiMark, Transliteratio ( nType == TransliterationFlags::SENTENCE_CASE || nType == TransliterationFlags::TITLE_CASE))) { if (!pEngine) - pEngine.reset(new ScFieldEditEngine(this, GetEditEnginePool(), GetEditTextObjectPool())); + pEngine.reset(new ScFieldEditEngine(this, GetEditEnginePool())); // defaults from cell attributes must be set so right language is used const ScPatternAttr* pPattern = GetPattern( nCol, nRow, nTab ); diff --git a/sc/source/core/data/drwlayer.cxx b/sc/source/core/data/drwlayer.cxx index d41f21e86d71..88103e4ed20a 100644 --- a/sc/source/core/data/drwlayer.cxx +++ b/sc/source/core/data/drwlayer.cxx @@ -317,14 +317,14 @@ ScDrawLayer::ScDrawLayer( ScDocument* pDocument, OUString _aName ) : rHitOutliner.SetStyleSheetPool(static_cast<SfxStyleSheetPool*>(GetStyleSheetPool())); // set FontHeight pool defaults without changing static SdrEngineDefaults - SfxItemPool* pOutlinerPool = rOutliner.GetEditTextObjectPool(); + SfxItemPool* pOutlinerPool = rOutliner.GetEditEnginePool(); if ( pOutlinerPool ) { m_pItemPool->SetUserDefaultItem(SvxFontHeightItem( 423, 100, EE_CHAR_FONTHEIGHT )); // 12Pt m_pItemPool->SetUserDefaultItem(SvxFontHeightItem( 423, 100, EE_CHAR_FONTHEIGHT_CJK )); // 12Pt m_pItemPool->SetUserDefaultItem(SvxFontHeightItem( 423, 100, EE_CHAR_FONTHEIGHT_CTL )); // 12Pt } - SfxItemPool* pHitOutlinerPool = rHitOutliner.GetEditTextObjectPool(); + SfxItemPool* pHitOutlinerPool = rHitOutliner.GetEditEnginePool(); if ( pHitOutlinerPool ) { pHitOutlinerPool->SetUserDefaultItem(SvxFontHeightItem( 423, 100, EE_CHAR_FONTHEIGHT )); // 12Pt diff --git a/sc/source/core/data/poolhelp.cxx b/sc/source/core/data/poolhelp.cxx index 829c3f69e27d..21384dac1683 100644 --- a/sc/source/core/data/poolhelp.cxx +++ b/sc/source/core/data/poolhelp.cxx @@ -35,23 +35,12 @@ ScPoolHelper::ScPoolHelper( ScDocument& rSourceDoc ) ScPoolHelper::~ScPoolHelper() { - mpEditTextObjectPool.clear(); mpEditEnginePool.clear(); pFormTable.reset(); mxStylePool.clear(); pDocPool.clear(); } -SfxItemPool* ScPoolHelper::GetEditTextObjectPool() const -{ - if ( !mpEditTextObjectPool ) - { - mpEditTextObjectPool = EditEngine::CreatePool(); - mpEditTextObjectPool->SetDefaultMetric( MapUnit::Map100thMM ); - } - return mpEditTextObjectPool.get(); -} - SfxItemPool* ScPoolHelper::GetEditEnginePool() const { if ( !mpEditEnginePool ) diff --git a/sc/source/core/data/stlpool.cxx b/sc/source/core/data/stlpool.cxx index 2dde31f721ef..bc7225d4e06d 100644 --- a/sc/source/core/data/stlpool.cxx +++ b/sc/source/core/data/stlpool.cxx @@ -263,7 +263,7 @@ void ScStyleSheetPool::CreateStandardStyles() const OUString aHelpFile;//which text??? SfxItemSet* pSet = nullptr; SfxItemSet* pHFSet = nullptr; - ScEditEngineDefaulter aEdEngine( EditEngine::CreatePool().get(), true ); + ScEditEngineDefaulter aEdEngine( pDoc->GetEditEnginePool(), true ); aEdEngine.SetUpdateLayout( false ); std::unique_ptr<EditTextObject> pEmptyTxtObj = aEdEngine.CreateTextObject(); std::unique_ptr<EditTextObject> pTxtObj; diff --git a/sc/source/core/data/table4.cxx b/sc/source/core/data/table4.cxx index d667824394e8..7fdc1d116943 100644 --- a/sc/source/core/data/table4.cxx +++ b/sc/source/core/data/table4.cxx @@ -161,7 +161,6 @@ void setSuffixCell( } EditEngine aEngine(rDoc.GetEditEnginePool()); - aEngine.SetEditTextObjectPool(rDoc.GetEditTextObjectPool()); SfxItemSet aAttr = aEngine.GetEmptyItemSet(); aAttr.Put( SvxEscapementItem( SvxEscapement::Superscript, EE_CHAR_ESCAPEMENT)); diff --git a/sc/source/core/inc/poolhelp.hxx b/sc/source/core/inc/poolhelp.hxx index f8f3777a8bd2..32ac4031fb4d 100644 --- a/sc/source/core/inc/poolhelp.hxx +++ b/sc/source/core/inc/poolhelp.hxx @@ -39,7 +39,6 @@ private: rtl::Reference<ScDocumentPool> pDocPool; rtl::Reference< ScStyleSheetPool > mxStylePool; mutable std::unique_ptr<SvNumberFormatter> pFormTable; - mutable rtl::Reference<SfxItemPool> mpEditTextObjectPool; // EditTextObjectPool mutable rtl::Reference<SfxItemPool> mpEditEnginePool; // EditEnginePool public: @@ -53,7 +52,6 @@ public: ScDocumentPool* GetDocPool() const { return pDocPool.get(); } ScStyleSheetPool* GetStylePool() const { return mxStylePool.get(); } SvNumberFormatter* GetFormTable() const; - SfxItemPool* GetEditTextObjectPool() const; SfxItemPool* GetEditEnginePool() const; void SetFormTableOpt(const ScDocOptions& rOpt); diff --git a/sc/source/core/tool/editutil.cxx b/sc/source/core/tool/editutil.cxx index 7dbbea06cb6e..89a4622f8f41 100644 --- a/sc/source/core/tool/editutil.cxx +++ b/sc/source/core/tool/editutil.cxx @@ -732,17 +732,14 @@ void ScEditEngineDefaulter::RemoveParaAttribs() ScTabEditEngine::ScTabEditEngine( ScDocument& rDoc ) : ScFieldEditEngine( &rDoc, rDoc.GetEditEnginePool() ) { - SetEditTextObjectPool( rDoc.GetEditTextObjectPool() ); const ScPatternAttr& rScPatternAttr(rDoc.getCellAttributeHelper().getDefaultCellAttribute()); Init(rScPatternAttr); } ScTabEditEngine::ScTabEditEngine( const ScPatternAttr& rPattern, - SfxItemPool* pEngineItemPool, ScDocument& rDoc, SfxItemPool* pTextObjectPool ) - : ScFieldEditEngine( &rDoc, pEngineItemPool, pTextObjectPool ) + SfxItemPool* pEngineItemPool, ScDocument& rDoc ) + : ScFieldEditEngine( &rDoc, pEngineItemPool ) { - if ( pTextObjectPool ) - SetEditTextObjectPool( pTextObjectPool ); Init( rPattern ); } @@ -887,12 +884,10 @@ OUString ScHeaderEditEngine::CalcFieldValue( const SvxFieldItem& rField, ScFieldEditEngine::ScFieldEditEngine( ScDocument* pDoc, SfxItemPool* pEnginePoolP, - SfxItemPool* pTextObjectPool, bool bDeleteEnginePoolP) : + bool bDeleteEnginePoolP) : ScEditEngineDefaulter( pEnginePoolP, bDeleteEnginePoolP ), mpDoc(pDoc), bExecuteURL(true) { - if ( pTextObjectPool ) - SetEditTextObjectPool( pTextObjectPool ); SetControlWord( EEControlBits(GetControlWord() | EEControlBits::MARKFIELDS) & ~EEControlBits::RTFSTYLESHEETS ); } @@ -922,12 +917,9 @@ bool ScFieldEditEngine::FieldClicked( const SvxFieldItem& rField ) return false; } -ScNoteEditEngine::ScNoteEditEngine( SfxItemPool* pEnginePoolP, - SfxItemPool* pTextObjectPool ) : +ScNoteEditEngine::ScNoteEditEngine( SfxItemPool* pEnginePoolP ) : ScEditEngineDefaulter( pEnginePoolP, false/*bDeleteEnginePoolP*/ ) { - if ( pTextObjectPool ) - SetEditTextObjectPool( pTextObjectPool ); SetControlWord( EEControlBits(GetControlWord() | EEControlBits::MARKFIELDS) & ~EEControlBits::RTFSTYLESHEETS ); } diff --git a/sc/source/filter/excel/xlroot.cxx b/sc/source/filter/excel/xlroot.cxx index 71089d10ec8f..7dea69cc1384 100644 --- a/sc/source/filter/excel/xlroot.cxx +++ b/sc/source/filter/excel/xlroot.cxx @@ -368,7 +368,6 @@ ScEditEngineDefaulter& XclRoot::GetEditEngine() const mrData.mxEditEngine = std::make_shared<ScEditEngineDefaulter>( GetDoc().GetEditEnginePool() ); ScEditEngineDefaulter& rEE = *mrData.mxEditEngine; rEE.SetRefMapMode(MapMode(MapUnit::Map100thMM)); - rEE.SetEditTextObjectPool( GetDoc().GetEditTextObjectPool() ); rEE.SetUpdateLayout( false ); rEE.EnableUndo( false ); rEE.SetControlWord( rEE.GetControlWord() & ~EEControlBits::ALLOWBIGOBJS ); diff --git a/sc/source/filter/oox/workbookhelper.cxx b/sc/source/filter/oox/workbookhelper.cxx index b99fa5f4b089..a8b534fe9032 100644 --- a/sc/source/filter/oox/workbookhelper.cxx +++ b/sc/source/filter/oox/workbookhelper.cxx @@ -606,7 +606,6 @@ void WorkbookGlobals::initialize() ScDocument& rDoc = getScDocument(); mxEditEngine.reset( new ScEditEngineDefaulter( rDoc.GetEditEnginePool() ) ); mxEditEngine->SetRefMapMode(MapMode(MapUnit::Map100thMM)); - mxEditEngine->SetEditTextObjectPool( rDoc.GetEditTextObjectPool() ); mxEditEngine->SetUpdateLayout( false ); mxEditEngine->EnableUndo( false ); mxEditEngine->SetControlWord( mxEditEngine->GetControlWord() & ~EEControlBits::ALLOWBIGOBJS ); diff --git a/sc/source/filter/rtf/eeimpars.cxx b/sc/source/filter/rtf/eeimpars.cxx index eb58054289f4..107f316c0496 100644 --- a/sc/source/filter/rtf/eeimpars.cxx +++ b/sc/source/filter/rtf/eeimpars.cxx @@ -65,7 +65,7 @@ ScEEImport::ScEEImport( ScDocument& rDoc, const ScRange& rRange ) : { const ScPatternAttr* pPattern = mrDoc.GetPattern( maRange.aStart.Col(), maRange.aStart.Row(), maRange.aStart.Tab() ); - mpEngine.reset( new ScTabEditEngine(*pPattern, mrDoc.GetEditTextObjectPool(), mrDoc, mrDoc.GetEditTextObjectPool()) ); + mpEngine.reset( new ScTabEditEngine(*pPattern, mrDoc.GetEditEnginePool(), mrDoc) ); mpEngine->SetUpdateLayout( false ); mpEngine->EnableUndo( false ); } diff --git a/sc/source/filter/rtf/expbase.cxx b/sc/source/filter/rtf/expbase.cxx index e33d547cf448..c1dec52d3897 100644 --- a/sc/source/filter/rtf/expbase.cxx +++ b/sc/source/filter/rtf/expbase.cxx @@ -68,7 +68,7 @@ bool ScExportBase::IsEmptyTable( SCTAB nTab ) const ScFieldEditEngine& ScExportBase::GetEditEngine() const { if ( !pEditEngine ) - const_cast<ScExportBase*>(this)->pEditEngine.reset( new ScFieldEditEngine(pDoc, pDoc->GetEditTextObjectPool()) ); + const_cast<ScExportBase*>(this)->pEditEngine.reset( new ScFieldEditEngine(pDoc, pDoc->GetEditEnginePool()) ); return *pEditEngine; } diff --git a/sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx b/sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx index 36374e96509d..9f15084a466e 100644 --- a/sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx +++ b/sc/source/filter/xml/XMLChangeTrackingExportHelper.cxx @@ -295,7 +295,7 @@ void ScChangeTrackingExportHelper::WriteEditCell(const ScCellValue& rCell) if (rCell.getEditText() && !sString.isEmpty()) { if (!pEditTextObj) - pEditTextObj = new ScEditEngineTextObj(); + pEditTextObj = new ScEditEngineTextObj(m_rDoc.GetEditEnginePool()); pEditTextObj->SetText(*rCell.getEditText()); rExport.GetTextParagraphExport()->exportText(pEditTextObj, false, false); } @@ -598,7 +598,7 @@ void ScChangeTrackingExportHelper::CollectCellAutoStyles(const ScCellValue& rCel return; if (!pEditTextObj) - pEditTextObj = new ScEditEngineTextObj(); + pEditTextObj = new ScEditEngineTextObj(m_rDoc.GetEditEnginePool()); pEditTextObj->SetText(*rCell.getEditText()); rExport.GetTextParagraphExport()->collectTextAutoStyles(pEditTextObj, false, false); diff --git a/sc/source/filter/xml/XMLTrackedChangesContext.cxx b/sc/source/filter/xml/XMLTrackedChangesContext.cxx index 2cbc2a499807..3984abca5f2c 100644 --- a/sc/source/filter/xml/XMLTrackedChangesContext.cxx +++ b/sc/source/filter/xml/XMLTrackedChangesContext.cxx @@ -828,8 +828,7 @@ void ScXMLChangeCellContext::CreateTextPContext(bool bIsNewParagraph) if (!pDoc) return; - mpEditTextObj = new ScEditEngineTextObj(); - mpEditTextObj->GetEditEngine()->SetEditTextObjectPool(pDoc->GetEditTextObjectPool()); + mpEditTextObj = new ScEditEngineTextObj(pDoc->GetEditEnginePool()); uno::Reference<text::XTextCursor> xTextCursor(mpEditTextObj->createTextCursor()); if (bIsNewParagraph) { diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx index 0bf76547bead..ffe0b364338d 100644 --- a/sc/source/filter/xml/xmlexprt.cxx +++ b/sc/source/filter/xml/xmlexprt.cxx @@ -5421,8 +5421,8 @@ ErrCode ScXMLExport::exportDoc( enum XMLTokenEnum eClass ) } CollectUserDefinedNamespaces(pDoc->GetPool(), ATTR_USERDEF); - CollectUserDefinedNamespaces(pDoc->GetEditTextObjectPool(), EE_PARA_XMLATTRIBS); - CollectUserDefinedNamespaces(pDoc->GetEditTextObjectPool(), EE_CHAR_XMLATTRIBS); + CollectUserDefinedNamespaces(pDoc->GetEditEnginePool(), EE_PARA_XMLATTRIBS); + CollectUserDefinedNamespaces(pDoc->GetEditEnginePool(), EE_CHAR_XMLATTRIBS); ScDrawLayer* pDrawLayer = pDoc->GetDrawLayer(); if (pDrawLayer) { diff --git a/sc/source/filter/xml/xmlfonte.cxx b/sc/source/filter/xml/xmlfonte.cxx index 69120ed68e12..6a76475e0732 100644 --- a/sc/source/filter/xml/xmlfonte.cxx +++ b/sc/source/filter/xml/xmlfonte.cxx @@ -85,7 +85,7 @@ ScXMLFontAutoStylePool_Impl::ScXMLFontAutoStylePool_Impl(ScDocument* pDoc, ScXML const SfxItemPool* pItemPool(pDoc->GetPool()); AddFontItems(aWhichIds, 3, pItemPool, true); - const SfxItemPool* pEditPool(pDoc->GetEditTextObjectPool()); + const SfxItemPool* pEditPool(pDoc->GetEditEnginePool()); AddFontItems(aEditWhichIds, 3, pEditPool, false); std::unique_ptr<SfxStyleSheetIterator> pItr = pDoc->GetStyleSheetPool()->CreateIterator(SfxStyleFamily::Page); diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx index 2cc965549aaf..4fe9904f6db0 100644 --- a/sc/source/filter/xml/xmlimprt.cxx +++ b/sc/source/filter/xml/xmlimprt.cxx @@ -1642,7 +1642,6 @@ ScEditEngineDefaulter* ScXMLImport::GetEditEngine() { mpEditEngine.reset(new ScEditEngineDefaulter(mpDoc->GetEditEnginePool())); mpEditEngine->SetRefMapMode(MapMode(MapUnit::Map100thMM)); - mpEditEngine->SetEditTextObjectPool(mpDoc->GetEditTextObjectPool()); mpEditEngine->SetUpdateLayout(false); mpEditEngine->EnableUndo(false); mpEditEngine->SetControlWord(mpEditEngine->GetControlWord() & ~EEControlBits::ALLOWBIGOBJS); diff --git a/sc/source/ui/Accessibility/AccessibleText.cxx b/sc/source/ui/Accessibility/AccessibleText.cxx index db1fb175a3ec..240505559943 100644 --- a/sc/source/ui/Accessibility/AccessibleText.cxx +++ b/sc/source/ui/Accessibility/AccessibleText.cxx @@ -817,7 +817,7 @@ SvxTextForwarder* ScAccessibleEditLineTextData::GetTextForwarder() if (!mpEditEngine) { rtl::Reference<SfxItemPool> pEnginePool = EditEngine::CreatePool(); - mpEditEngine = new ScFieldEditEngine(nullptr, pEnginePool.get(), nullptr, true); + mpEditEngine = new ScFieldEditEngine(nullptr, pEnginePool.get(), true); mbEditEngineCreated = true; mpEditEngine->EnableUndo( false ); mpEditEngine->SetRefMapMode(MapMode(MapUnit::Map100thMM)); @@ -1020,7 +1020,7 @@ SvxTextForwarder* ScAccessiblePreviewHeaderCellTextData::GetTextForwarder() else { rtl::Reference<SfxItemPool> pEnginePool = EditEngine::CreatePool(); - pEditEngine.reset( new ScFieldEditEngine(nullptr, pEnginePool.get(), nullptr, true) ); + pEditEngine.reset( new ScFieldEditEngine(nullptr, pEnginePool.get(), true) ); } pEditEngine->EnableUndo( false ); if (pDocShell) @@ -1247,7 +1247,7 @@ SvxTextForwarder* ScAccessibleNoteTextData::GetTextForwarder() else { rtl::Reference<SfxItemPool> pEnginePool = EditEngine::CreatePool(); - mpEditEngine.reset( new ScFieldEditEngine(nullptr, pEnginePool.get(), nullptr, true) ); + mpEditEngine.reset( new ScFieldEditEngine(nullptr, pEnginePool.get(), true) ); } mpEditEngine->EnableUndo( false ); if (mpDocSh) diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx index af3de62fbaaf..c564832b8956 100644 --- a/sc/source/ui/app/inputhdl.cxx +++ b/sc/source/ui/app/inputhdl.cxx @@ -926,7 +926,7 @@ void ScInputHandler::ImplCreateEditEngine() // we cannot create a properly initialised EditEngine until we have a document assert( pActiveViewSh ); ScDocument& rDoc = pActiveViewSh->GetViewData().GetDocShell().GetDocument(); - mpEditEngine = std::make_unique<ScFieldEditEngine>(&rDoc, rDoc.GetEditEnginePool(), rDoc.GetEditTextObjectPool()); + mpEditEngine = std::make_unique<ScFieldEditEngine>(&rDoc, rDoc.GetEditEnginePool()); mpEditEngine->SetWordDelimiters( ScEditUtil::ModifyDelimiters( mpEditEngine->GetWordDelimiters() ) ); UpdateRefDevice(); // also sets MapMode mpEditEngine->SetPaperSize( Size( 1000000, 1000000 ) ); diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx index 18b18836c746..645e73eb7531 100644 --- a/sc/source/ui/app/inputwin.cxx +++ b/sc/source/ui/app/inputwin.cxx @@ -1536,10 +1536,10 @@ void ScTextWnd::InitEditEngine() { pDocSh = &mpViewShell->GetViewData().GetDocShell(); ScDocument& rDoc = mpViewShell->GetViewData().GetDocument(); - pNew = std::make_unique<ScFieldEditEngine>(&rDoc, rDoc.GetEditEnginePool(), rDoc.GetEditTextObjectPool()); + pNew = std::make_unique<ScFieldEditEngine>(&rDoc, rDoc.GetEditEnginePool()); } else - pNew = std::make_unique<ScFieldEditEngine>(nullptr, EditEngine::CreatePool().get(), nullptr, true); + pNew = std::make_unique<ScFieldEditEngine>(nullptr, EditEngine::CreatePool().get(), true); pNew->SetExecuteURL( false ); m_xEditEngine = std::move(pNew); @@ -2106,10 +2106,10 @@ void ScTextWnd::MakeDialogEditView() if ( pViewSh ) { ScDocument& rDoc = pViewSh->GetViewData().GetDocument(); - pNew = std::make_unique<ScFieldEditEngine>(&rDoc, rDoc.GetEditEnginePool(), rDoc.GetEditTextObjectPool()); + pNew = std::make_unique<ScFieldEditEngine>(&rDoc, rDoc.GetEditEnginePool()); } else - pNew = std::make_unique<ScFieldEditEngine>(nullptr, EditEngine::CreatePool().get(), nullptr, true); + pNew = std::make_unique<ScFieldEditEngine>(nullptr, EditEngine::CreatePool().get(), true); pNew->SetExecuteURL( false ); m_xEditEngine = std::move(pNew); diff --git a/sc/source/ui/app/transobj.cxx b/sc/source/ui/app/transobj.cxx index 053ecc02c93d..7430232e57c4 100644 --- a/sc/source/ui/app/transobj.cxx +++ b/sc/source/ui/app/transobj.cxx @@ -317,7 +317,7 @@ bool ScTransferObj::GetData( const datatransfer::DataFlavor& rFlavor, const OUSt const ScPatternAttr* pPattern = m_pDoc->GetPattern( nCol, nRow, nTab ); if (pPattern) { - ScTabEditEngine aEngine(*pPattern, m_pDoc->GetEditTextObjectPool(), *m_pDoc); + ScTabEditEngine aEngine(*pPattern, m_pDoc->GetEditEnginePool(), *m_pDoc); ScRefCellValue aCell(*m_pDoc, aPos); if (aCell.getType() == CELLTYPE_EDIT) { diff --git a/sc/source/ui/docshell/docsh8.cxx b/sc/source/ui/docshell/docsh8.cxx index babab2abb4a6..63d2026195b2 100644 --- a/sc/source/ui/docshell/docsh8.cxx +++ b/sc/source/ui/docshell/docsh8.cxx @@ -785,7 +785,7 @@ ErrCodeMsg ScDocShell::DBaseExport( const OUString& rFullFileName, rtl_TextEncod bHasMemo, eCharSet ); // also needed for exception catch SCROW nDocRow = 0; - ScFieldEditEngine aEditEngine(m_pDocument.get(), m_pDocument->GetEditTextObjectPool()); + ScFieldEditEngine aEditEngine(m_pDocument.get(), m_pDocument->GetEditEnginePool()); OUString aString; try diff --git a/sc/source/ui/unoobj/cellsuno.cxx b/sc/source/ui/unoobj/cellsuno.cxx index 60d2bbc51bbc..e0ce8a80f45f 100644 --- a/sc/source/ui/unoobj/cellsuno.cxx +++ b/sc/source/ui/unoobj/cellsuno.cxx @@ -2145,7 +2145,6 @@ void ScCellRangesBase::SetOnePropertyValue( const SfxItemPropertyMapEntry* pEntr OUString aStr = aCell.getString(rDoc); EditEngine aEngine( rDoc.GetEditEnginePool() ); - aEngine.SetEditTextObjectPool(rDoc.GetEditTextObjectPool()); /* EE_CHAR_ESCAPEMENT seems to be set on the cell _only_ when * there are no other attribs for the cell. diff --git a/sc/source/ui/unoobj/textuno.cxx b/sc/source/ui/unoobj/textuno.cxx index 8fd8c0813ad5..038342ca4160 100644 --- a/sc/source/ui/unoobj/textuno.cxx +++ b/sc/source/ui/unoobj/textuno.cxx @@ -683,11 +683,11 @@ uno::Reference<text::XTextRange> SAL_CALL ScDrawTextCursor::getEnd() UNO3_GETIMPLEMENTATION2_IMPL(ScDrawTextCursor, SvxUnoTextCursor); -ScSimpleEditSourceHelper::ScSimpleEditSourceHelper() +ScSimpleEditSourceHelper::ScSimpleEditSourceHelper(SfxItemPool* pEditEnginePool) { - rtl::Reference<SfxItemPool> pEnginePool = EditEngine::CreatePool(); - pEnginePool->SetDefaultMetric( MapUnit::Map100thMM ); - pEditEngine.reset( new ScFieldEditEngine(nullptr, pEnginePool.get(), nullptr, true) ); // TRUE: become owner of pool +// rtl::Reference<SfxItemPool> pEnginePool = EditEngine::CreatePool(); +// pEnginePool->SetDefaultMetric( MapUnit::Map100thMM ); + pEditEngine.reset( new ScFieldEditEngine(nullptr, pEditEnginePool, false) ); // TRUE: become owner of pool pForwarder.reset( new SvxEditEngineForwarder( *pEditEngine ) ); pOriginalSource.reset( new ScSimpleEditSource( pForwarder.get() ) ); } @@ -701,7 +701,8 @@ ScSimpleEditSourceHelper::~ScSimpleEditSourceHelper() pEditEngine.reset(); } -ScEditEngineTextObj::ScEditEngineTextObj() : +ScEditEngineTextObj::ScEditEngineTextObj(SfxItemPool* pEditEnginePool) : + ScSimpleEditSourceHelper(pEditEnginePool), SvxUnoText( GetOriginalSource(), ScCellObj::GetEditPropertySet(), uno::Reference<text::XText>() ) { } @@ -772,7 +773,7 @@ SvxTextForwarder* ScCellTextData::GetTextForwarder() else { rtl::Reference<SfxItemPool> pEnginePool = EditEngine::CreatePool(); - pEditEngine.reset( new ScFieldEditEngine(nullptr, pEnginePool.get(), nullptr, true) ); + pEditEngine.reset( new ScFieldEditEngine(nullptr, pEnginePool.get(), true) ); } // currently, GetPortions doesn't work if UpdateMode is sal_False, // this will be fixed (in EditEngine) by src600 diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx index 2c1ab215aa2c..8b5122e2c365 100644 --- a/sc/source/ui/view/gridwin.cxx +++ b/sc/source/ui/view/gridwin.cxx @@ -5789,7 +5789,7 @@ std::shared_ptr<ScFieldEditEngine> createEditEngine( ScDocShell& rDocSh, const S { ScDocument& rDoc = rDocSh.GetDocument(); - auto pEngine = std::make_shared<ScFieldEditEngine>(&rDoc, rDoc.GetEditTextObjectPool()); + auto pEngine = std::make_shared<ScFieldEditEngine>(&rDoc, rDoc.GetEditEnginePool()); ScSizeDeviceProvider aProv(rDocSh); pEngine->SetRefDevice(aProv.GetDevice()); pEngine->SetRefMapMode(MapMode(MapUnit::Map100thMM)); diff --git a/sc/source/ui/view/spelleng.cxx b/sc/source/ui/view/spelleng.cxx index 6b87175c7987..edb894a29432 100644 --- a/sc/source/ui/view/spelleng.cxx +++ b/sc/source/ui/view/spelleng.cxx @@ -126,7 +126,7 @@ bool ScConversionEngineBase::FindNextConversionCell() if (!bSimpleString || eCellType == CELLTYPE_EDIT) { std::unique_ptr<EditTextObject> pEditObj(CreateTextObject()); - mrDoc.SetEditText(aPos, *pEditObj, GetEditTextObjectPool()); + mrDoc.SetEditText(aPos, *pEditObj, GetItemPool()); } else { diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx index 36b62e31d599..3e2f1b2d3489 100644 --- a/sc/source/ui/view/viewfun2.cxx +++ b/sc/source/ui/view/viewfun2.cxx @@ -940,7 +940,7 @@ void ScViewFunc::EnterBlock( const OUString& rString, const EditTextObject* pDat else if ( pData ) { // A copy of pData will be stored. - pInsDoc->SetEditText(aPos, *pData, rDoc.GetEditTextObjectPool()); + pInsDoc->SetEditText(aPos, *pData, rDoc.GetEditEnginePool()); } else pInsDoc->SetString( nCol, nRow, nTab, aNewStr ); diff --git a/sc/source/ui/view/viewfun4.cxx b/sc/source/ui/view/viewfun4.cxx index a917f534dfd2..4a64af774613 100644 --- a/sc/source/ui/view/viewfun4.cxx +++ b/sc/source/ui/view/viewfun4.cxx @@ -358,7 +358,6 @@ void ScViewFunc::DoThesaurus() uno::Reference<linguistic2::XSpellChecker1> xSpeller = LinguMgr::GetSpellChecker(); pThesaurusEngine.reset(new ScEditEngineDefaulter(rDoc.GetEditEnginePool())); - pThesaurusEngine->SetEditTextObjectPool( rDoc.GetEditTextObjectPool() ); pThesaurusEngine->SetRefDevice(GetViewData().GetActiveWin()->GetOutDev()); pThesaurusEngine->SetSpeller(xSpeller); MakeEditView(*pThesaurusEngine, nCol, nRow); diff --git a/sc/source/ui/view/viewfunc.cxx b/sc/source/ui/view/viewfunc.cxx index 8c0b2c58e188..89d80ac4b7b1 100644 --- a/sc/source/ui/view/viewfunc.cxx +++ b/sc/source/ui/view/viewfunc.cxx @@ -899,7 +899,7 @@ void ScViewFunc::EnterData( SCCOL nCol, SCROW nRow, SCTAB nTab, for (const auto& rTab : rMark) { ScAddress aPos(nCol, nRow, rTab); - rDoc.SetEditText(aPos, rData, rDoc.GetEditTextObjectPool()); + rDoc.SetEditText(aPos, rData, rDoc.GetEditEnginePool()); } if ( bRecord ) diff --git a/sd/source/core/sdpage.cxx b/sd/source/core/sdpage.cxx index 86ac8c19f4de..8500c0a71ef3 100644 --- a/sd/source/core/sdpage.cxx +++ b/sd/source/core/sdpage.cxx @@ -2430,7 +2430,7 @@ void SdPage::SetObjText(SdrTextObj* pObj, SdrOutliner* pOutliner, PresObjKind eO SfxItemPool* pPool(static_cast< SdDrawDocument& >(getSdrModelFromSdrPage()).GetDrawOutliner().GetEmptyItemSet().GetPool()); pOutl = new ::Outliner( pPool, OutlinerMode::OutlineObject ); pOutl->SetRefDevice(SdModule::get()->GetVirtualRefDevice()); - pOutl->SetEditTextObjectPool(pPool); + pOutl->SetEditEnginePool(pPool); pOutl->SetStyleSheetPool(static_cast<SfxStyleSheetPool*>(getSdrModelFromSdrPage().GetStyleSheetPool())); pOutl->EnableUndo(false); pOutl->SetUpdateLayout( false ); diff --git a/sd/source/ui/view/Outliner.cxx b/sd/source/ui/view/Outliner.cxx index ffefc3e884d3..d68097546da5 100644 --- a/sd/source/ui/view/Outliner.cxx +++ b/sd/source/ui/view/Outliner.cxx @@ -185,7 +185,6 @@ SdOutliner::SdOutliner( SdDrawDocument& rDoc, OutlinerMode nMode ) mbPrepareSpellingPending(true) { SetStyleSheetPool(static_cast<SfxStyleSheetPool*>( mrDrawDocument.GetStyleSheetPool() )); - SetEditTextObjectPool( &rDoc.GetItemPool() ); SetCalcFieldValueHdl(LINK(SdModule::get(), SdModule, CalcFieldValueHdl)); SetForbiddenCharsTable( rDoc.GetForbiddenCharsTable() ); diff --git a/svx/source/svdraw/svdetc.cxx b/svx/source/svdraw/svdetc.cxx index 5d3788789136..69a5a5bca4ab 100644 --- a/svx/source/svdraw/svdetc.cxx +++ b/svx/source/svdraw/svdetc.cxx @@ -351,7 +351,6 @@ std::unique_ptr<SdrOutliner> SdrMakeOutliner(OutlinerMode nOutlinerMode, SdrMode { SfxItemPool* pPool = &rModel.GetItemPool(); std::unique_ptr<SdrOutliner> pOutl(new SdrOutliner( pPool, nOutlinerMode )); - pOutl->SetEditTextObjectPool( pPool ); pOutl->SetStyleSheetPool( static_cast<SfxStyleSheetPool*>(rModel.GetStyleSheetPool())); pOutl->SetDefTab(rModel.GetDefaultTabulator()); Outliner::SetForbiddenCharsTable(rModel.GetForbiddenCharsTable()); diff --git a/svx/source/svdraw/svdmodel.cxx b/svx/source/svdraw/svdmodel.cxx index a3d6de78ec99..7e1948dc0597 100644 --- a/svx/source/svdraw/svdmodel.cxx +++ b/svx/source/svdraw/svdmodel.cxx @@ -713,7 +713,7 @@ void SdrModel::ImpSetOutlinerDefaults( SdrOutliner* pOutliner, bool bInit ) { pOutliner->EraseVirtualDevice(); pOutliner->SetUpdateLayout(false); - pOutliner->SetEditTextObjectPool(m_pItemPool.get()); + pOutliner->SetEditEnginePool(m_pItemPool.get()); pOutliner->SetDefTab(m_nDefaultTabulator); }