summaryrefslogtreecommitdiff
path: root/sw/source/filter
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/filter')
-rw-r--r--sw/source/filter/ww8/ww8par.cxx19
-rw-r--r--sw/source/filter/ww8/ww8par.hxx2
-rw-r--r--sw/source/filter/ww8/ww8par2.cxx4
-rw-r--r--sw/source/filter/ww8/ww8par5.cxx2
-rw-r--r--sw/source/filter/ww8/ww8par6.cxx4
-rw-r--r--sw/source/filter/xml/xmlfmte.cxx2
6 files changed, 15 insertions, 18 deletions
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 27d6032dd4d2..a2d959d7d3f7 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -2478,7 +2478,7 @@ void wwSectionManager::SetHdFt(wwSection const &rSection, int nSect,
}
-void SwWW8ImplReader::FinalizeTextNode(SwPosition& rPos, bool bAddNew)
+void SwWW8ImplReader::AppendTextNode(SwPosition& rPos)
{
SwTextNode* pText = m_pPaM->GetPointNode().GetTextNode();
@@ -2565,8 +2565,7 @@ void SwWW8ImplReader::FinalizeTextNode(SwPosition& rPos, bool bAddNew)
m_bFirstPara = false;
- if (bAddNew)
- m_rDoc.getIDocumentContentOperations().AppendTextNode(rPos);
+ m_rDoc.getIDocumentContentOperations().AppendTextNode(rPos);
// We can flush all anchored graphics at the end of a paragraph.
m_xAnchorStck->Flush();
@@ -3482,13 +3481,13 @@ void SwWW8ImplReader::simpleAddTextToParagraph(std::u16string_view aAddString)
else
{
m_rDoc.getIDocumentContentOperations().InsertString(*m_pPaM, addString.copy(0, nCharsLeft));
- FinalizeTextNode(*m_pPaM->GetPoint());
+ AppendTextNode(*m_pPaM->GetPoint());
m_rDoc.getIDocumentContentOperations().InsertString(*m_pPaM, addString.copy(nCharsLeft));
}
}
else
{
- FinalizeTextNode(*m_pPaM->GetPoint());
+ AppendTextNode(*m_pPaM->GetPoint());
m_rDoc.getIDocumentContentOperations().InsertString(*m_pPaM, addString);
}
@@ -3559,7 +3558,7 @@ bool SwWW8ImplReader::HandlePageBreakChar()
&& (m_bFirstPara || m_bFirstParaOfPage))
{
IsTemp = false;
- FinalizeTextNode(*m_pPaM->GetPoint());
+ AppendTextNode(*m_pPaM->GetPoint());
pTemp->SetAttr(*GetDfltAttr(RES_PARATR_NUMRULE));
}
@@ -3638,7 +3637,7 @@ bool SwWW8ImplReader::ReadChar(tools::Long nPosCp, tools::Long nCpOfs)
// Always insert a txtnode for a column break, e.g. ##
SwContentNode *pCntNd=m_pPaM->GetPointContentNode();
if (pCntNd!=nullptr && pCntNd->Len()>0) // if par is empty not break is needed
- FinalizeTextNode(*m_pPaM->GetPoint());
+ AppendTextNode(*m_pPaM->GetPoint());
m_rDoc.getIDocumentContentOperations().InsertPoolItem(*m_pPaM, SvxFormatBreakItem(SvxBreak::ColumnBefore, RES_BREAK));
}
break;
@@ -4107,7 +4106,7 @@ bool SwWW8ImplReader::ReadText(WW8_CP nStartCp, WW8_CP nTextLen, ManTypes nType)
}
if (bSplit)
{
- FinalizeTextNode(*m_pPaM->GetPoint());
+ AppendTextNode(*m_pPaM->GetPoint());
}
}
@@ -4222,7 +4221,7 @@ bool SwWW8ImplReader::ReadText(WW8_CP nStartCp, WW8_CP nTextLen, ManTypes nType)
// to insert a text node.
if (!bStartLine && !m_xAnchorStck->empty())
{
- FinalizeTextNode(*m_pPaM->GetPoint());
+ AppendTextNode(*m_pPaM->GetPoint());
}
m_rDoc.getIDocumentContentOperations().InsertPoolItem(*m_pPaM,
SvxFormatBreakItem(SvxBreak::PageBefore, RES_BREAK));
@@ -4235,7 +4234,7 @@ bool SwWW8ImplReader::ReadText(WW8_CP nStartCp, WW8_CP nTextLen, ManTypes nType)
m_xPreviousNode.reset();
if (m_pPaM->GetPoint()->GetContentIndex())
- FinalizeTextNode(*m_pPaM->GetPoint());
+ AppendTextNode(*m_pPaM->GetPoint());
if (!m_bInHyperlink)
bJoined = JoinNode(*m_pPaM);
diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx
index ca5b34f8e033..f98bcc2ff58e 100644
--- a/sw/source/filter/ww8/ww8par.hxx
+++ b/sw/source/filter/ww8/ww8par.hxx
@@ -1421,7 +1421,7 @@ private:
bool StyleExists(unsigned int nColl) const { return (nColl < m_vColl.size()); }
SwWW8StyInf *GetStyle(sal_uInt16 nColl) const;
- void FinalizeTextNode(SwPosition& rPos, bool bAddNew = true);
+ void AppendTextNode(SwPosition& rPos);
void Read_HdFt(int nSect, const SwPageDesc *pPrev,
const wwSection &rSection);
diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx
index 07348ff888d3..602256428563 100644
--- a/sw/source/filter/ww8/ww8par2.cxx
+++ b/sw/source/filter/ww8/ww8par2.cxx
@@ -2402,7 +2402,7 @@ void WW8TabDesc::CreateSwTable()
}
if (bInsNode)
- m_pIo->FinalizeTextNode(*pPoint);
+ m_pIo->AppendTextNode(*pPoint);
m_xTmpPos = m_pIo->m_rDoc.CreateUnoCursor(*m_pIo->m_pPaM->GetPoint());
@@ -3497,8 +3497,6 @@ bool SwWW8ImplReader::StartTable(WW8_CP nStartCp)
void SwWW8ImplReader::TabCellEnd()
{
- FinalizeTextNode(*m_pPaM->GetPoint(), false);
-
if (m_nInTable && m_xTableDesc)
m_xTableDesc->TableCellEnd();
diff --git a/sw/source/filter/ww8/ww8par5.cxx b/sw/source/filter/ww8/ww8par5.cxx
index 975280376800..6750fa21ae76 100644
--- a/sw/source/filter/ww8/ww8par5.cxx
+++ b/sw/source/filter/ww8/ww8par5.cxx
@@ -3478,7 +3478,7 @@ eF_ResT SwWW8ImplReader::Read_F_Tox( WW8FieldDesc* pF, OUString& rStr )
}
if (m_pPaM->GetPoint()->GetContentIndex())
- FinalizeTextNode(*m_pPaM->GetPoint());
+ AppendTextNode(*m_pPaM->GetPoint());
const SwPosition* pPos = m_pPaM->GetPoint();
diff --git a/sw/source/filter/ww8/ww8par6.cxx b/sw/source/filter/ww8/ww8par6.cxx
index b8272f55ccd0..13270b28c144 100644
--- a/sw/source/filter/ww8/ww8par6.cxx
+++ b/sw/source/filter/ww8/ww8par6.cxx
@@ -881,7 +881,7 @@ void wwSectionManager::CreateSep(const tools::Long nTextPos)
if( txtNode->Len() == 0 )
insert = false;
if( insert )
- mrReader.FinalizeTextNode(*mrReader.m_pPaM->GetPoint());
+ mrReader.AppendTextNode(*mrReader.m_pPaM->GetPoint());
}
ww::WordVersion eVer = mrReader.GetFib().GetFIBVersion();
@@ -2528,7 +2528,7 @@ bool SwWW8ImplReader::StartApo(const ApoTestResults &rApo, const WW8_TablePos *p
{
// The two fly frames would have the same anchor position, leading to
// potentially overlapping text, prevent that.
- FinalizeTextNode(*pPoint);
+ AppendTextNode(*pPoint);
}
}
}
diff --git a/sw/source/filter/xml/xmlfmte.cxx b/sw/source/filter/xml/xmlfmte.cxx
index 0999076212c1..8e20f46e4299 100644
--- a/sw/source/filter/xml/xmlfmte.cxx
+++ b/sw/source/filter/xml/xmlfmte.cxx
@@ -250,7 +250,7 @@ void SwXMLExport::collectAutoStyles()
GetFormExport()->examineForms(xPage);
}
- GetTextParagraphExport()->collectTextAutoStylesAndNodeExportOrder(m_bShowProgress);
+ GetTextParagraphExport()->collectTextAutoStylesOptimized( m_bShowProgress );
}
mbAutoStylesCollected = true;