summaryrefslogtreecommitdiff
path: root/sw/source/core/txtnode
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/txtnode')
-rw-r--r--sw/source/core/txtnode/fntcache.cxx8
-rw-r--r--sw/source/core/txtnode/modeltoviewhelper.cxx2
-rw-r--r--sw/source/core/txtnode/ndtxt.cxx12
-rw-r--r--sw/source/core/txtnode/thints.cxx4
4 files changed, 13 insertions, 13 deletions
diff --git a/sw/source/core/txtnode/fntcache.cxx b/sw/source/core/txtnode/fntcache.cxx
index ccc25f50df9c..f2c18d7b1ce9 100644
--- a/sw/source/core/txtnode/fntcache.cxx
+++ b/sw/source/core/txtnode/fntcache.cxx
@@ -1616,16 +1616,16 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf )
if ((i + nCopyStart + 1 >= sal_Int32(rInf.GetLen())) ||
aKernArray[i + nCopyStart] != aKernArray[ i + nCopyStart + 1])
{
- aBulletOverlay = aBulletOverlay.replaceAt(i, 1, OUString(CH_BULLET));
+ aBulletOverlay = aBulletOverlay.replaceAt(i, 1, rtl::OUStringChar(CH_BULLET));
}
else
{
- aBulletOverlay = aBulletOverlay.replaceAt(i, 1, OUString(CH_BLANK));
+ aBulletOverlay = aBulletOverlay.replaceAt(i, 1, rtl::OUStringChar(CH_BLANK));
}
}
else
{
- aBulletOverlay = aBulletOverlay.replaceAt(i, 1, OUString(CH_BLANK));
+ aBulletOverlay = aBulletOverlay.replaceAt(i, 1, rtl::OUStringChar(CH_BLANK));
}
}
@@ -2502,7 +2502,7 @@ TextFrameIndex SwFont::GetTextBreak(SwDrawTextInfo const & rInf, tools::Long nTe
// In this case, the beginning of aTmpText is wrong.
OUString aSnippetTmp(aSnippet.copy(0, 1));
aSnippetTmp = m_aSub[m_nActual].CalcCaseMap( aSnippetTmp );
- aTmpText = aTmpText.replaceAt( 0, aSnippetTmp.getLength(), OUString(aSnippet[0]) );
+ aTmpText = aTmpText.replaceAt( 0, aSnippetTmp.getLength(), rtl::OUStringChar(aSnippet[0]) );
}
}
diff --git a/sw/source/core/txtnode/modeltoviewhelper.cxx b/sw/source/core/txtnode/modeltoviewhelper.cxx
index cf4983192b23..c8c6095726cb 100644
--- a/sw/source/core/txtnode/modeltoviewhelper.cxx
+++ b/sw/source/core/txtnode/modeltoviewhelper.cxx
@@ -226,7 +226,7 @@ ModelToViewHelper::ModelToViewHelper(const SwTextNode &rNode,
sal_Int32 const viewBlockPos(nBlockStart + nOffset);
m_aMap.emplace_back(modelBlockPos, viewBlockPos, false);
- m_aRetText = m_aRetText.replaceAt(nOffset + nBlockStart, nBlockLen, OUString());
+ m_aRetText = m_aRetText.replaceAt(nOffset + nBlockStart, nBlockLen, u"");
nOffset -= nBlockLen;
}
else
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index 33509d405aad..5134d7672fa2 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -2392,8 +2392,8 @@ void SwTextNode::CutImpl( SwTextNode * const pDest, const SwIndex & rDestStart,
abort();
}
pDest->m_Text = pDest->m_Text.replaceAt(nDestStart, 0,
- m_Text.copy(nTextStartIdx, nLen));
- OUString const newText = m_Text.replaceAt(nTextStartIdx, nLen, "");
+ m_Text.subView(nTextStartIdx, nLen));
+ OUString const newText = m_Text.replaceAt(nTextStartIdx, nLen, u"");
nLen = pDest->m_Text.getLength() - nInitSize; // update w/ current size!
if (!nLen) // String didn't grow?
return;
@@ -2639,7 +2639,7 @@ void SwTextNode::EraseText(const SwIndex &rIdx, const sal_Int32 nCount,
? m_Text.getLength() - nStartIdx : nCount;
const sal_Int32 nEndIdx = nStartIdx + nCnt;
if (nEndIdx <= m_Text.getLength())
- m_Text = m_Text.replaceAt(nStartIdx, nCnt, "");
+ m_Text = m_Text.replaceAt(nStartIdx, nCnt, u"");
// GCAttr(); don't remove all empty ones, just the ones that are in the
// range but not at the end of the range.
@@ -3679,10 +3679,10 @@ void SwTextNode::ReplaceText( const SwIndex& rStart, const sal_Int32 nDelLen,
{
// Replace the 1st char, then delete the rest and insert.
// This way the attributes of the 1st char are expanded!
- m_Text = m_Text.replaceAt(nStartPos, 1, sInserted.copy(0, 1));
+ m_Text = m_Text.replaceAt(nStartPos, 1, sInserted.subView(0, 1));
++const_cast<SwIndex&>(rStart);
- m_Text = m_Text.replaceAt(rStart.GetIndex(), nLen - 1, "");
+ m_Text = m_Text.replaceAt(rStart.GetIndex(), nLen - 1, u"");
Update( rStart, nLen - 1, true );
OUString aTmpText( sInserted.copy(1) );
@@ -3691,7 +3691,7 @@ void SwTextNode::ReplaceText( const SwIndex& rStart, const sal_Int32 nDelLen,
}
else
{
- m_Text = m_Text.replaceAt(nStartPos, nLen, "");
+ m_Text = m_Text.replaceAt(nStartPos, nLen, u"");
Update( rStart, nLen, true );
m_Text = m_Text.replaceAt(nStartPos, 0, sInserted);
diff --git a/sw/source/core/txtnode/thints.cxx b/sw/source/core/txtnode/thints.cxx
index e97df81267df..5aba3a2b6e64 100644
--- a/sw/source/core/txtnode/thints.cxx
+++ b/sw/source/core/txtnode/thints.cxx
@@ -1389,7 +1389,7 @@ bool SwTextNode::InsertHint( SwTextAttr * const pAttr, const SetAttrMode nMode )
// delete the char from the string
assert(CH_TXTATR_BREAKWORD == m_Text[pAttr->GetStart()]
|| CH_TXTATR_INWORD == m_Text[pAttr->GetStart()]);
- m_Text = m_Text.replaceAt(pAttr->GetStart(), 1, "");
+ m_Text = m_Text.replaceAt(pAttr->GetStart(), 1, u"");
// Update SwIndexes
SwIndex aTmpIdx( this, pAttr->GetStart() );
Update( aTmpIdx, 1, true );
@@ -1420,7 +1420,7 @@ bool SwTextNode::InsertHint( SwTextAttr * const pAttr, const SetAttrMode nMode )
// delete the char from the string
assert(CH_TXTATR_BREAKWORD == m_Text[pAttr->GetStart()]
|| CH_TXTATR_INWORD == m_Text[pAttr->GetStart()]);
- m_Text = m_Text.replaceAt(pAttr->GetStart(), 1, "");
+ m_Text = m_Text.replaceAt(pAttr->GetStart(), 1, u"");
// Update SwIndexes
SwIndex aTmpIdx( this, pAttr->GetStart() );
Update( aTmpIdx, 1, true );