summaryrefslogtreecommitdiff
path: root/starmath/source
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-03-13 12:51:29 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-03-13 16:47:32 +0000
commit13d3ae64dbf2ac4bda8e831c1da890b09024a8bb (patch)
tree5097d7b6d54186490452a62adc3e84634a0d8d4e /starmath/source
parent25ae332bbafd0cb416a6a5c0db467e501661c679 (diff)
make more use of OUStringBuffer::append(OUStringConcat)
where we can avoid constructing temporary OUStrings Change-Id: I0eacd68a8d1b450894c2ea769055f16886b78ad0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148780 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'starmath/source')
-rw-r--r--starmath/source/mathtype.cxx12
1 files changed, 4 insertions, 8 deletions
diff --git a/starmath/source/mathtype.cxx b/starmath/source/mathtype.cxx
index 9273a4498b61..a3199c06c686 100644
--- a/starmath/source/mathtype.cxx
+++ b/starmath/source/mathtype.cxx
@@ -683,8 +683,7 @@ bool MathType::HandleRecords(int nLevel, sal_uInt8 nSelector,
{
OUString aStr;
TypeFaceToString(aStr,nTypeFace);
- aStr += "\"";
- rRet.insert(nTextStart,aStr);
+ rRet.insert(nTextStart, aStr + "\"");
rRet.append("\"");
}
else if (nRecord == END && !rRet.isEmpty())
@@ -2895,8 +2894,7 @@ bool MathType::HandleChar(sal_Int32 &rTextStart, int &rSetSize, int nLevel,
{
OUString aStr;
TypeFaceToString(aStr,nOldTypeFace);
- aStr += "\"";
- rRet.insert(std::min(rTextStart, rRet.getLength()), aStr);
+ rRet.insert(std::min(rTextStart, rRet.getLength()), aStr + "\"");
aStr.clear();
TypeFaceToString(aStr,nTypeFace);
@@ -2921,8 +2919,7 @@ bool MathType::HandleChar(sal_Int32 &rTextStart, int &rSetSize, int nLevel,
rRet.insert(nOldLen, "\"");
OUString aStr;
TypeFaceToString(aStr,nOldTypeFace);
- aStr += "\"";
- rRet.insert(rTextStart,aStr);
+ rRet.insert(rTextStart, aStr + "\"");
}
rTextStart = rRet.getLength();
}
@@ -2934,8 +2931,7 @@ bool MathType::HandleChar(sal_Int32 &rTextStart, int &rSetSize, int nLevel,
rRet.insert(nOldLen, "\"");
OUString aStr;
TypeFaceToString(aStr,nOldTypeFace);
- aStr += "\"";
- rRet.insert(rTextStart, aStr);
+ rRet.insert(rTextStart, aStr + "\"");
}
rTextStart = rRet.getLength();
}