summaryrefslogtreecommitdiff
path: root/starmath
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-03-30 10:19:35 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-03-30 09:26:58 +0000
commitaa8fb790e8d3f975c7ffadcb5a4fa390186c6d5d (patch)
tree2f65cfbad847c47f7e7d6a2e2ff644c50d1726b4 /starmath
parent2ca71b5c6e0374254e7c75c75e54fa6a8caebfde (diff)
loplugin:stringadd in starmath..svl
when applying my upcoming patch to also consider O[U]StringBuffer Change-Id: Id8f229c3a5223dee8d2710caf15d4612594fc763 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149748 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'starmath')
-rw-r--r--starmath/source/ooxmlimport.cxx9
-rw-r--r--starmath/source/utility.cxx6
2 files changed, 6 insertions, 9 deletions
diff --git a/starmath/source/ooxmlimport.cxx b/starmath/source/ooxmlimport.cxx
index f040265ad31d..4023a5e652ac 100644
--- a/starmath/source/ooxmlimport.cxx
+++ b/starmath/source/ooxmlimport.cxx
@@ -355,8 +355,7 @@ OUString SmOoxmlImport::handleD()
opening = "left none ";
if( closing.isEmpty())
closing = " right none";
- OUStringBuffer ret;
- ret.append( opening );
+ OUStringBuffer ret( opening );
bool first = true;
while( m_rStream.findTag( OPENING( M_TOKEN( e ))))
{
@@ -378,9 +377,9 @@ OUString SmOoxmlImport::handleEqArr()
{ // there must be at least one m:e
if( !ret.isEmpty())
ret.append("#");
- ret.append(" ");
- ret.append(readOMathArgInElement( M_TOKEN( e )));
- ret.append(" ");
+ ret.append(" "
+ + readOMathArgInElement( M_TOKEN( e ))
+ + " ");
} while( !m_rStream.atEnd() && m_rStream.findTag( OPENING( M_TOKEN( e ))));
m_rStream.ensureClosingTag( M_TOKEN( eqArr ));
return "stack {" + ret + "}";
diff --git a/starmath/source/utility.cxx b/starmath/source/utility.cxx
index 5c957899092e..4a9225f6b363 100644
--- a/starmath/source/utility.cxx
+++ b/starmath/source/utility.cxx
@@ -82,13 +82,11 @@ OUString lcl_GetStringItem(const vcl::Font &rFont)
if (IsItalic( rFont ))
{
- aString.append(", ");
- aString.append(SmResId(RID_FONTITALIC));
+ aString.append(", " + SmResId(RID_FONTITALIC));
}
if (IsBold( rFont ))
{
- aString.append(", ");
- aString.append(SmResId(RID_FONTBOLD));
+ aString.append(", " + SmResId(RID_FONTBOLD));
}
return aString.makeStringAndClear();