summaryrefslogtreecommitdiff
path: root/sc/source/ui/dbgui/asciiopt.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-05-03 14:09:20 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-05-03 15:32:53 +0200
commitc5a0b7af847a71fd50f713934b29305f8ce96c6b (patch)
treed7c0193bc183250c36e467f830a4327ab94dc24e /sc/source/ui/dbgui/asciiopt.cxx
parentd19dbcc139d18771e5e20e82a694f1512476e41c (diff)
loplugin:stringadd improvement for appending numbers
I was wrong, the Concat framework already optimised appending numbers by stack-allocating small buffers, so include them in the plugin Change-Id: I922edbdde273c89abfe21d51c5d25dc01c97db25 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115037 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui/dbgui/asciiopt.cxx')
-rw-r--r--sc/source/ui/dbgui/asciiopt.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/sc/source/ui/dbgui/asciiopt.cxx b/sc/source/ui/dbgui/asciiopt.cxx
index 270ca6b01069..4d9e8dea6fe8 100644
--- a/sc/source/ui/dbgui/asciiopt.cxx
+++ b/sc/source/ui/dbgui/asciiopt.cxx
@@ -211,24 +211,24 @@ OUString ScAsciiOptions::WriteToString() const
aOutStr.append(ScGlobal::GetCharsetString( eCharSet ));
//Token 3: Number of start row.
- aOutStr.append(",").append(nStartRow).append(",");
+ aOutStr.append("," + OUString::number(nStartRow) + ",");
//Token 4: Column info.
for (size_t nInfo=0; nInfo<mvColStart.size(); nInfo++)
{
if (nInfo)
aOutStr.append("/");
- aOutStr.append(mvColStart[nInfo])
- .append("/")
- .append(static_cast<sal_Int32>(mvColFormat[nInfo]));
+ aOutStr.append(OUString::number(mvColStart[nInfo]) +
+ "/" +
+ OUString::number(mvColFormat[nInfo]));
}
// #i112025# the options string is used in macros and linked sheets,
// so new options must be added at the end, to remain compatible
- aOutStr.append(",")
+ aOutStr.append("," +
//Token 5: Language
- .append(static_cast<sal_Int32>(static_cast<sal_uInt16>(eLang))).append("," +
+ OUString::number(static_cast<sal_uInt16>(eLang)) + "," +
//Token 6: Import quoted field as text.
OUString::boolean( bQuotedFieldAsText ) + "," +
//Token 7: Detect special numbers.