summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-04-23 16:07:32 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-04-27 14:07:56 +0200
commitc7c6f0af6c836ebe0968967a1e7c8320b0ac17d6 (patch)
tree4bc5b2fa623b9765b88bbfe7de10a7590c87d5c8
parent99482297c7dd497e41fad2e7193759043e305101 (diff)
loplugin:stringadd convert chained append to +
which can use the more efficient *StringConcat Also fix a crash in stringview plugin which started happening while I working on this. Change-Id: I91a5b9b7707d1594d27d80b73930f5afac8ae608 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114568 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--UnoControls/source/controls/progressmonitor.cxx8
-rw-r--r--avmedia/source/viewer/mediawindow.cxx4
-rw-r--r--basctl/source/basicide/baside2b.cxx2
-rw-r--r--basic/source/runtime/methods.cxx2
-rw-r--r--chart2/source/tools/ExponentialRegressionCurveCalculator.cxx10
-rw-r--r--chart2/source/tools/LogarithmicRegressionCurveCalculator.cxx8
-rw-r--r--chart2/source/tools/PolynomialRegressionCurveCalculator.cxx2
-rw-r--r--chart2/source/tools/PotentialRegressionCurveCalculator.cxx6
-rw-r--r--chart2/source/view/charttypes/VSeriesPlotter.cxx2
-rw-r--r--comphelper/source/misc/xmlsechelper.cxx2
-rw-r--r--compilerplugins/clang/stringadd.cxx58
-rw-r--r--compilerplugins/clang/stringview.cxx2
-rw-r--r--compilerplugins/clang/test/stringadd.cxx4
-rw-r--r--connectivity/source/commontools/dbtools2.cxx4
-rw-r--r--connectivity/source/commontools/sqlerror.cxx6
-rw-r--r--connectivity/source/drivers/firebird/Util.cxx2
-rw-r--r--connectivity/source/drivers/postgresql/pq_xkeys.cxx5
-rw-r--r--connectivity/source/drivers/postgresql/pq_xviews.cxx2
-rw-r--r--cui/source/customize/cfg.cxx2
-rw-r--r--dbaccess/source/core/api/CacheSet.cxx6
-rw-r--r--dbaccess/source/core/api/KeySet.cxx12
-rw-r--r--dbaccess/source/core/api/OptimisticSet.cxx4
-rw-r--r--dbaccess/source/core/api/SingleSelectQueryComposer.cxx20
-rw-r--r--dbaccess/source/core/dataaccess/ContentHelper.cxx2
-rw-r--r--dbaccess/source/filter/xml/xmlServerDatabase.cxx22
-rw-r--r--dbaccess/source/ui/dlg/directsql.cxx2
-rw-r--r--dbaccess/source/ui/dlg/tablespage.cxx4
-rw-r--r--dbaccess/source/ui/misc/WCopyTable.cxx2
-rw-r--r--dbaccess/source/ui/uno/copytablewizard.cxx2
-rw-r--r--desktop/source/deployment/registry/component/dp_component.cxx2
-rw-r--r--extensions/source/propctrlr/selectlabeldialog.cxx7
-rw-r--r--filter/source/config/cache/filtercache.cxx24
-rw-r--r--forms/source/xforms/model_ui.cxx2
-rw-r--r--framework/source/accelerators/storageholder.cxx2
-rw-r--r--i18nlangtag/source/languagetag/languagetag.cxx6
-rw-r--r--i18npool/source/collator/collator_unicode.cxx4
-rw-r--r--lotuswordpro/source/filter/lwptblformula.cxx2
-rw-r--r--oox/source/core/xmlfilterbase.cxx2
-rw-r--r--oox/source/dump/dumperbase.cxx2
-rw-r--r--oox/source/export/drawingml.cxx3
-rw-r--r--oox/source/export/vmlexport.cxx12
-rw-r--r--oox/source/ole/vbamodule.cxx3
-rw-r--r--reportdesign/source/filter/xml/xmlControlProperty.cxx24
-rw-r--r--sc/source/core/data/postit.cxx2
-rw-r--r--sc/source/core/tool/address.cxx2
-rw-r--r--sc/source/core/tool/chgtrack.cxx49
-rw-r--r--sc/source/core/tool/compiler.cxx4
-rw-r--r--sc/source/filter/dif/difimp.cxx4
-rw-r--r--sc/source/filter/excel/xehelper.cxx6
-rw-r--r--sc/source/filter/html/htmlexp.cxx28
-rw-r--r--sc/source/filter/oox/formulabase.cxx6
-rw-r--r--sc/source/filter/oox/numberformatsbuffer.cxx6
-rw-r--r--sc/source/filter/oox/querytablebuffer.cxx2
-rw-r--r--sc/source/ui/app/inputhdl.cxx2
-rw-r--r--sc/source/ui/cctrl/checklistmenu.cxx2
-rw-r--r--sc/source/ui/condformat/condformathelper.cxx4
-rw-r--r--sc/source/ui/dataprovider/datatransformation.cxx2
-rw-r--r--sc/source/ui/dbgui/asciiopt.cxx12
-rw-r--r--sc/source/ui/optdlg/tpusrlst.cxx4
-rw-r--r--sc/source/ui/unoobj/PivotTableDataProvider.cxx2
-rw-r--r--sc/source/ui/vba/vbahyperlink.cxx2
-rw-r--r--sc/source/ui/vba/vbanames.cxx2
-rw-r--r--sc/source/ui/view/tabview.cxx10
-rw-r--r--sd/source/filter/eppt/pptx-epptooxml.cxx24
-rw-r--r--sd/source/filter/html/htmlex.cxx10
-rw-r--r--sd/source/ui/remotecontrol/Communicator.cxx11
-rw-r--r--sd/source/ui/remotecontrol/DiscoveryService.cxx7
-rw-r--r--sfx2/source/appl/newhelp.cxx9
-rw-r--r--sfx2/source/bastyp/frmhtmlw.cxx14
-rw-r--r--sfx2/source/control/unoctitm.cxx5
-rw-r--r--sfx2/source/dialog/templdlg.cxx2
-rw-r--r--sfx2/source/view/lokhelper.cxx6
-rw-r--r--starmath/source/mathtype.cxx10
-rw-r--r--svl/source/misc/urihelper.cxx8
-rw-r--r--svl/source/numbers/zforlist.cxx4
-rw-r--r--svl/source/numbers/zformat.cxx2
-rw-r--r--svtools/source/svhtml/htmlout.cxx65
-rw-r--r--sw/source/core/edit/editsh.cxx2
-rw-r--r--sw/source/core/fields/cellfml.cxx14
-rw-r--r--sw/source/filter/html/htmldrawwriter.cxx28
-rw-r--r--sw/source/filter/html/htmlfldw.cxx6
-rw-r--r--sw/source/filter/html/htmlflywriter.cxx66
-rw-r--r--sw/source/filter/html/htmlftn.cxx12
-rw-r--r--sw/source/filter/html/htmlplug.cxx24
-rw-r--r--sw/source/filter/html/htmltabw.cxx56
-rw-r--r--sw/source/filter/html/swhtml.cxx2
-rw-r--r--sw/source/filter/ww8/docxattributeoutput.cxx8
-rw-r--r--sw/source/filter/ww8/docxsdrexport.cxx6
-rw-r--r--sw/source/filter/ww8/rtfattributeoutput.cxx32
-rw-r--r--sw/source/filter/ww8/rtfexport.cxx33
-rw-r--r--sw/source/filter/ww8/rtfsdrexport.cxx34
-rw-r--r--sw/source/ui/dbui/createaddresslistdialog.cxx4
-rw-r--r--sw/source/uibase/app/docstyle.cxx4
-rw-r--r--sw/source/uibase/shells/annotsh.cxx2
-rw-r--r--sw/source/uibase/shells/drwtxtsh.cxx2
-rw-r--r--sw/source/uibase/wrtsh/wrtundo.cxx2
-rw-r--r--ucb/source/core/provprox.cxx4
-rw-r--r--ucb/source/ucp/cmis/cmis_url.cxx2
-rw-r--r--ucb/source/ucp/ftp/ftpurl.cxx2
-rw-r--r--unotools/source/config/bootstrap.cxx7
-rw-r--r--unotools/source/config/configpaths.cxx4
-rw-r--r--unotools/source/i18n/localedatawrapper.cxx6
-rw-r--r--unoxml/source/rdf/librdf_repository.cxx8
-rw-r--r--vcl/skia/gdiimpl.cxx5
-rw-r--r--vcl/source/gdi/pdfobjectcopier.cxx2
-rw-r--r--vcl/source/treelist/transfer.cxx4
-rw-r--r--vcl/source/treelist/treelistbox.cxx2
-rw-r--r--vcl/source/uitest/logger.cxx12
-rw-r--r--vcl/source/uitest/uiobject.cxx4
-rw-r--r--xmloff/source/forms/elementimport.cxx22
-rw-r--r--xmloff/source/forms/layerimport.cxx4
-rw-r--r--xmloff/source/forms/propertyimport.cxx24
-rw-r--r--xmloff/source/style/xmlexppr.cxx7
-rw-r--r--xmloff/source/style/xmlnumfi.cxx6
-rw-r--r--xmlsecurity/source/framework/saxeventkeeperimpl.cxx6
115 files changed, 521 insertions, 577 deletions
diff --git a/UnoControls/source/controls/progressmonitor.cxx b/UnoControls/source/controls/progressmonitor.cxx
index 05296e35915b..de9d596513de 100644
--- a/UnoControls/source/controls/progressmonitor.cxx
+++ b/UnoControls/source/controls/progressmonitor.cxx
@@ -722,7 +722,7 @@ void ProgressMonitor::impl_rebuildFixedText ()
// "\n" MUST BE at the end of line!!! => Else ... topic and his text are not in the same line!!!
for (auto const & pSearchItem : maTextlist_Top)
{
- aCollectString.append(pSearchItem->sTopic).append("\n");
+ aCollectString.append(pSearchItem->sTopic + "\n");
}
m_xTopic_Top->setText ( aCollectString.makeStringAndClear() );
@@ -737,7 +737,7 @@ void ProgressMonitor::impl_rebuildFixedText ()
// "\n" MUST BE at the end of line!!! => Else ... topic and his text are not in the same line!!!
for (auto const & pSearchItem : maTextlist_Top)
{
- aCollectString.append(pSearchItem->sText).append("\n");
+ aCollectString.append(pSearchItem->sText + "\n");
}
m_xText_Top->setText ( aCollectString.makeStringAndClear() );
@@ -754,7 +754,7 @@ void ProgressMonitor::impl_rebuildFixedText ()
// "\n" MUST BE at the end of line!!! => Else ... topic and his text are not in the same line!!!
for (auto const & pSearchItem : maTextlist_Bottom)
{
- aCollectString.append(pSearchItem->sTopic).append("\n");
+ aCollectString.append(pSearchItem->sTopic + "\n");
}
m_xTopic_Bottom->setText ( aCollectString.makeStringAndClear() );
@@ -770,7 +770,7 @@ void ProgressMonitor::impl_rebuildFixedText ()
// "\n" MUST BE at the end of line!!! => Else ... topic and his text are not in the same line!!!
for (auto const & pSearchItem : maTextlist_Bottom)
{
- aCollectString.append(pSearchItem->sText).append("\n");
+ aCollectString.append(pSearchItem->sText + "\n");
}
m_xText_Bottom->setText ( aCollectString.makeStringAndClear() );
diff --git a/avmedia/source/viewer/mediawindow.cxx b/avmedia/source/viewer/mediawindow.cxx
index e823c2e8dac5..0807de0f5a45 100644
--- a/avmedia/source/viewer/mediawindow.cxx
+++ b/avmedia/source/viewer/mediawindow.cxx
@@ -225,7 +225,7 @@ bool MediaWindow::executeMediaURLDialog(weld::Window* pParent, OUString& rURL, b
if( !aAllTypes.isEmpty() )
aAllTypes.append(aSeparator);
- aAllTypes.append(aWildcard).append(aFilters[ i ].second.getToken( 0, ';', nIndex ));
+ aAllTypes.append(aWildcard + aFilters[ i ].second.getToken( 0, ';', nIndex ));
}
}
@@ -241,7 +241,7 @@ bool MediaWindow::executeMediaURLDialog(weld::Window* pParent, OUString& rURL, b
if( !aTypes.isEmpty() )
aTypes.append(aSeparator);
- aTypes.append(aWildcard).append(aFilters[ i ].second.getToken( 0, ';', nIndex ));
+ aTypes.append(aWildcard + aFilters[ i ].second.getToken( 0, ';', nIndex ));
}
// add single filters
diff --git a/basctl/source/basicide/baside2b.cxx b/basctl/source/basicide/baside2b.cxx
index cdc69b96b355..73cedfd04776 100644
--- a/basctl/source/basicide/baside2b.cxx
+++ b/basctl/source/basicide/baside2b.cxx
@@ -1885,7 +1885,7 @@ void StackWindow::UpdateCalls()
OUStringBuffer aEntry( OUString::number(nScope ));
if ( aEntry.getLength() < 2 )
aEntry.insert(0, " ");
- aEntry.append(": ").append(pMethod->GetName());
+ aEntry.append(": " + pMethod->GetName());
SbxArray* pParams = pMethod->GetParameters();
SbxInfo* pInfo = pMethod->GetInfo();
if ( pParams )
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index 0276a41c1b17..910b95f084fa 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -4643,7 +4643,7 @@ void SbRtl_Partition(StarBASIC *, SbxArray & rPar, bool)
aRetStr.append(" ");
}
}
- aRetStr.append( aLowerValue ).append(":");
+ aRetStr.append( aLowerValue + ":");
if( nLen > nLen2 )
{
// appending the leading spaces for the uppervalue
diff --git a/chart2/source/tools/ExponentialRegressionCurveCalculator.cxx b/chart2/source/tools/ExponentialRegressionCurveCalculator.cxx
index 1aa962ab5e3e..1d389d6f99bf 100644
--- a/chart2/source/tools/ExponentialRegressionCurveCalculator.cxx
+++ b/chart2/source/tools/ExponentialRegressionCurveCalculator.cxx
@@ -183,13 +183,13 @@ OUString ExponentialRegressionCurveCalculator::ImplGetRepresentation(
// if nValueLength not calculated then nullptr
sal_Int32* pValueLength = nValueLength ? &nValueLength : nullptr;
if ( m_fSign < 0.0 )
- aTmpBuf.append( OUStringChar(aMinusSign) ).append( " " );
+ aTmpBuf.append( OUStringChar(aMinusSign) + " " );
if ( bHasIntercept )
{
OUString aValueString = getFormattedString( xNumFormatter, nNumberFormatKey, fIntercept, pValueLength );
if ( aValueString != "1" ) // aValueString may be rounded to 1 if nValueLength is small
{
- aTmpBuf.append( aValueString ).append( " " );
+ aTmpBuf.append( aValueString + " " );
addStringToEquation( aBuf, nLineLength, aTmpBuf, pFormulaMaxWidth );
aTmpBuf.truncate();
}
@@ -208,16 +208,16 @@ OUString ExponentialRegressionCurveCalculator::ImplGetRepresentation(
}
}
if ( m_fLogSlope < 0.0 )
- aTmpBuf.append( OUStringChar(aMinusSign) ).append( " " );
+ aTmpBuf.append( OUStringChar(aMinusSign) + " " );
if ( bHasLogSlope )
{
OUString aValueString = getFormattedString( xNumFormatter, nNumberFormatKey, fabs(m_fLogSlope), pValueLength );
if ( aValueString != "1" ) // aValueString may be rounded to 1 if nValueLength is small
{
- aTmpBuf.append( aValueString ).append( " " );
+ aTmpBuf.append( aValueString + " " );
}
}
- aTmpBuf.append( mXName ).append(" )");
+ aTmpBuf.append( mXName + " )");
addStringToEquation( aBuf, nLineLength, aTmpBuf, pFormulaMaxWidth );
return aBuf.makeStringAndClear();
diff --git a/chart2/source/tools/LogarithmicRegressionCurveCalculator.cxx b/chart2/source/tools/LogarithmicRegressionCurveCalculator.cxx
index c09eab50975c..bfa5d9e4be5d 100644
--- a/chart2/source/tools/LogarithmicRegressionCurveCalculator.cxx
+++ b/chart2/source/tools/LogarithmicRegressionCurveCalculator.cxx
@@ -156,17 +156,17 @@ OUString LogarithmicRegressionCurveCalculator::ImplGetRepresentation(
{
if( m_fSlope < 0.0 )
{
- aTmpBuf.append( OUStringChar(aMinusSign) ).append( " " );
+ aTmpBuf.append( OUStringChar(aMinusSign) + " " );
}
if( bHasSlope )
{
OUString aValueString = getFormattedString( xNumFormatter, nNumberFormatKey, fabs(m_fSlope), pValueLength );
if ( aValueString != "1" ) // aValueString may be rounded to 1 if nValueLength is small
{
- aTmpBuf.append( aValueString ).append( " " );
+ aTmpBuf.append( aValueString + " " );
}
}
- aTmpBuf.append( "ln(" ).append( mXName ).append( ") " );
+ aTmpBuf.append( "ln(" + mXName + ") " );
addStringToEquation( aBuf, nLineLength, aTmpBuf, pFormulaMaxWidth );
aTmpBuf.truncate();
@@ -175,7 +175,7 @@ OUString LogarithmicRegressionCurveCalculator::ImplGetRepresentation(
}
// add intercept value
if( m_fIntercept < 0.0 )
- aTmpBuf.append( OUStringChar(aMinusSign) ).append( " " );
+ aTmpBuf.append( OUStringChar(aMinusSign) + " " );
OUString aValueString = getFormattedString( xNumFormatter, nNumberFormatKey, fabs(m_fIntercept), pValueLength );
if ( aValueString != "0" ) // aValueString may be rounded to 0 if nValueLength is small
{
diff --git a/chart2/source/tools/PolynomialRegressionCurveCalculator.cxx b/chart2/source/tools/PolynomialRegressionCurveCalculator.cxx
index b3585b71f5e3..38e326cbbbc4 100644
--- a/chart2/source/tools/PolynomialRegressionCurveCalculator.cxx
+++ b/chart2/source/tools/PolynomialRegressionCurveCalculator.cxx
@@ -345,7 +345,7 @@ OUString PolynomialRegressionCurveCalculator::ImplGetRepresentation(
{
if ( bFindValue ) // if it is not the first aValue
aTmpBuf.append( " " );
- aTmpBuf.append( OUStringChar(aMinusSign) ).append(" ");
+ aTmpBuf.append( OUStringChar(aMinusSign) + " ");
aValue = - aValue;
}
else
diff --git a/chart2/source/tools/PotentialRegressionCurveCalculator.cxx b/chart2/source/tools/PotentialRegressionCurveCalculator.cxx
index eb054bd8db66..89f6dc5b9e6e 100644
--- a/chart2/source/tools/PotentialRegressionCurveCalculator.cxx
+++ b/chart2/source/tools/PotentialRegressionCurveCalculator.cxx
@@ -170,18 +170,18 @@ OUString PotentialRegressionCurveCalculator::ImplGetRepresentation(
// if nValueLength not calculated then nullptr
sal_Int32* pValueLength = nValueLength ? &nValueLength : nullptr;
if ( m_fIntercept < 0.0 ) // add intercept value
- aTmpBuf.append( OUStringChar(aMinusSign) ).append( " " );
+ aTmpBuf.append( OUStringChar(aMinusSign) + " " );
if( bHasIntercept )
{
OUString aValueString = getFormattedString( xNumFormatter, nNumberFormatKey, fabs(m_fIntercept), pValueLength );
if ( aValueString != "1" ) // aValueString may be rounded to 1 if nValueLength is small
{
- aTmpBuf.append( aValueString ).append( " " );
+ aTmpBuf.append( aValueString + " " );
}
}
if( m_fSlope != 0.0 ) // add slope value
{
- aTmpBuf.append( mXName ).append( "^" );
+ aTmpBuf.append( mXName + "^" );
aTmpBuf.append( getFormattedString( xNumFormatter, nNumberFormatKey, m_fSlope, pValueLength ));
}
addStringToEquation( aBuf, nLineLength, aTmpBuf, pFormulaMaxWidth );
diff --git a/chart2/source/view/charttypes/VSeriesPlotter.cxx b/chart2/source/view/charttypes/VSeriesPlotter.cxx
index 39a97c618a47..fda17a91964b 100644
--- a/chart2/source/view/charttypes/VSeriesPlotter.cxx
+++ b/chart2/source/view/charttypes/VSeriesPlotter.cxx
@@ -1542,7 +1542,7 @@ void VSeriesPlotter::createRegressionCurveEquationShapes(
}
if( bShowCorrCoeff )
{
- aFormula.append( "R" ).append( OUStringChar( aSuperscriptFigures[2] ) ).append( " = " );
+ aFormula.append( "R" + OUStringChar( aSuperscriptFigures[2] ) + " = " );
double fR( xRegressionCurveCalculator->getCorrelationCoefficient());
if (m_apNumberFormatterWrapper)
{
diff --git a/comphelper/source/misc/xmlsechelper.cxx b/comphelper/source/misc/xmlsechelper.cxx
index c01743b36615..8f7184d2abee 100644
--- a/comphelper/source/misc/xmlsechelper.cxx
+++ b/comphelper/source/misc/xmlsechelper.cxx
@@ -61,7 +61,7 @@ namespace comphelper::xmlsec
s2.append('\n');
}
s1.append(i->second);
- s2.append(i->first).append(" = ").append(i->second);
+ s2.append(i->first + " = " + i->second);
}
return make_pair(s1.makeStringAndClear(), s2.makeStringAndClear());
}
diff --git a/compilerplugins/clang/stringadd.cxx b/compilerplugins/clang/stringadd.cxx
index 5723b5bb6e3b..9c6d11fd55b1 100644
--- a/compilerplugins/clang/stringadd.cxx
+++ b/compilerplugins/clang/stringadd.cxx
@@ -72,6 +72,7 @@ public:
bool VisitCompoundStmt(CompoundStmt const*);
bool VisitCXXOperatorCallExpr(CXXOperatorCallExpr const*);
+ bool VisitCXXMemberCallExpr(CXXMemberCallExpr const*);
private:
enum class Summands
@@ -262,6 +263,63 @@ bool StringAdd::VisitCXXOperatorCallExpr(CXXOperatorCallExpr const* operatorCall
return true;
}
+bool StringAdd::VisitCXXMemberCallExpr(CXXMemberCallExpr const* methodCall)
+{
+ if (ignoreLocation(methodCall))
+ return true;
+
+ auto methodDecl = methodCall->getMethodDecl();
+ if (!methodDecl || !methodDecl->getIdentifier() || methodDecl->getName() != "append"
+ || methodCall->getNumArgs() == 0)
+ return true;
+ auto tc1 = loplugin::TypeCheck(methodCall->getType());
+ if (!tc1.Class("OUStringBuffer").Namespace("rtl").GlobalNamespace()
+ && !tc1.Class("OStringBuffer").Namespace("rtl").GlobalNamespace())
+ return true;
+ auto paramType = methodDecl->getParamDecl(0)->getType();
+ // if we convert one of the number append methods, we need to create an extra temporary to hold the string convertion of the number
+ if (paramType->isIntegerType())
+ return true;
+ if (paramType->isCharType())
+ return true;
+ if (paramType->isFloatingType())
+ return true;
+ auto arg = methodCall->getArg(0);
+ // I don't think the OUStringAppend functionality can handle this efficiently
+ if (isa<ConditionalOperator>(ignore(arg)))
+ return true;
+
+ auto methodCall2 = dyn_cast<CXXMemberCallExpr>(ignore(methodCall->getImplicitObjectArgument()));
+ if (!methodCall2)
+ return true;
+ auto tc = loplugin::TypeCheck(methodCall2->getType());
+ if (!tc.Class("OUStringBuffer").Namespace("rtl").GlobalNamespace()
+ && !tc.Class("OStringBuffer").Namespace("rtl").GlobalNamespace())
+ return true;
+ auto methodDecl2 = methodCall2->getMethodDecl();
+ if (!methodDecl2->getIdentifier() || methodDecl2->getName() != "append"
+ || methodCall2->getNumArgs() == 0)
+ return true;
+ auto paramType2 = methodDecl2->getParamDecl(0)->getType();
+ // if we convert one of the number append methods, we need to create an extra temporary to hold the string convertion of the number
+ if (paramType2->isIntegerType())
+ return true;
+ if (paramType2->isCharType())
+ return true;
+ if (paramType2->isFloatingType())
+ return true;
+ arg = methodCall2->getArg(0);
+ // I don't think the OUStringAppend functionality can handle this efficiently
+ if (isa<ConditionalOperator>(ignore(arg)))
+ return true;
+ report(DiagnosticsEngine::Warning,
+ "chained append, rather use single append call and + operator",
+ compat::getBeginLoc(methodCall2))
+ << methodCall2->getSourceRange();
+
+ return true;
+}
+
Expr const* StringAdd::ignore(Expr const* expr)
{
return compat::IgnoreImplicit(compat::IgnoreImplicit(expr)->IgnoreParens());
diff --git a/compilerplugins/clang/stringview.cxx b/compilerplugins/clang/stringview.cxx
index 5df91dcad054..95d7d6368572 100644
--- a/compilerplugins/clang/stringview.cxx
+++ b/compilerplugins/clang/stringview.cxx
@@ -70,7 +70,7 @@ bool StringView::VisitCXXOperatorCallExpr(CXXOperatorCallExpr const* cxxOperator
if (!memberCallExpr)
return;
auto methodDecl = memberCallExpr->getMethodDecl();
- if (!methodDecl->getIdentifier() || methodDecl->getName() != "copy")
+ if (!methodDecl || !methodDecl->getIdentifier() || methodDecl->getName() != "copy")
return;
report(DiagnosticsEngine::Warning, "rather than copy, pass with a view using subView()",
compat::getBeginLoc(expr))
diff --git a/compilerplugins/clang/test/stringadd.cxx b/compilerplugins/clang/test/stringadd.cxx
index a953e44062bb..a18b562a052f 100644
--- a/compilerplugins/clang/test/stringadd.cxx
+++ b/compilerplugins/clang/test/stringadd.cxx
@@ -217,6 +217,10 @@ void f1(OUString s, OUString t, int i, const char* pChar)
// no warning expected
OUString c;
c = c + OUString(pChar, strlen(pChar), RTL_TEXTENCODING_UTF8);
+
+ OUStringBuffer buf;
+ // expected-error@+1 {{chained append, rather use single append call and + operator [loplugin:stringadd]}}
+ buf.append(" ").append(b);
}
void f2(char ch)
{
diff --git a/connectivity/source/commontools/dbtools2.cxx b/connectivity/source/commontools/dbtools2.cxx
index 907bc7fd3698..9805f63afba4 100644
--- a/connectivity/source/commontools/dbtools2.cxx
+++ b/connectivity/source/commontools/dbtools2.cxx
@@ -261,8 +261,8 @@ namespace
for(sal_Int32 i=0;i<nColCount;++i)
{
if ( (_xColumns->getByIndex(i) >>= xColProp) && xColProp.is() )
- sSql.append( ::dbtools::quoteName(sQuote,::comphelper::getString(xColProp->getPropertyValue(rPropMap.getNameByIndex(PROPERTY_ID_NAME)))) )
- .append(",");
+ sSql.append( ::dbtools::quoteName(sQuote,::comphelper::getString(xColProp->getPropertyValue(rPropMap.getNameByIndex(PROPERTY_ID_NAME)))) +
+ ",");
}
if ( nColCount )
diff --git a/connectivity/source/commontools/sqlerror.cxx b/connectivity/source/commontools/sqlerror.cxx
index dee6f36f0b61..9f8608384d1d 100644
--- a/connectivity/source/commontools/sqlerror.cxx
+++ b/connectivity/source/commontools/sqlerror.cxx
@@ -222,13 +222,9 @@ namespace connectivity
OUString SQLError_Impl::impl_getErrorMessage( ErrorCondition _eCondition )
{
- OUStringBuffer aMessage;
-
OUString sResMessage(Translate::get(lcl_getResourceErrorID(_eCondition), m_aResources));
OSL_ENSURE( !sResMessage.isEmpty(), "SQLError_Impl::impl_getErrorMessage: illegal error condition, or invalid resource!" );
- aMessage.append( getMessagePrefix() ).append( " " ).append( sResMessage );
-
- return aMessage.makeStringAndClear();
+ return getMessagePrefix() + " " + sResMessage;
}
OUString SQLError_Impl::impl_getSQLState( ErrorCondition _eCondition )
diff --git a/connectivity/source/drivers/firebird/Util.cxx b/connectivity/source/drivers/firebird/Util.cxx
index 3bf3cfbc4d82..46b87d7caf12 100644
--- a/connectivity/source/drivers/firebird/Util.cxx
+++ b/connectivity/source/drivers/firebird/Util.cxx
@@ -51,7 +51,7 @@ OUString firebird::StatusVectorToString(const ISC_STATUS_ARRAY& rStatusVector,
{
SAL_WARN("connectivity.firebird", "ignore fb_interpret exception");
}
- buf.append("\ncaused by\n'").append(rCause).append("'\n");
+ buf.append(OUString::Concat("\ncaused by\n'") + rCause + "'\n");
OUString error = buf.makeStringAndClear();
SAL_WARN("connectivity.firebird", error);
diff --git a/connectivity/source/drivers/postgresql/pq_xkeys.cxx b/connectivity/source/drivers/postgresql/pq_xkeys.cxx
index 88d8b5b1189b..84507202fa9a 100644
--- a/connectivity/source/drivers/postgresql/pq_xkeys.cxx
+++ b/connectivity/source/drivers/postgresql/pq_xkeys.cxx
@@ -172,10 +172,9 @@ void Keys::refresh()
if( css::sdbcx::KeyType::FOREIGN == keyType )
{
- OUStringBuffer buf( 128 );
- buf.append( xRow->getString( 6 ) ).append( "." ).append( xRow->getString( 5 ) );
+ OUString buf = xRow->getString( 6 ) + "." + xRow->getString( 5 );
pKey->setPropertyValue_NoBroadcast_public(
- st.REFERENCED_TABLE, makeAny( buf.makeStringAndClear() ) );
+ st.REFERENCED_TABLE, makeAny( buf ) );
Int2StringMap foreignMap;
fillAttnum2attnameMap( foreignMap, m_origin, xRow->getString(6), xRow->getString(5));
diff --git a/connectivity/source/drivers/postgresql/pq_xviews.cxx b/connectivity/source/drivers/postgresql/pq_xviews.cxx
index 3f36c168b6d2..d71219fa6420 100644
--- a/connectivity/source/drivers/postgresql/pq_xviews.cxx
+++ b/connectivity/source/drivers/postgresql/pq_xviews.cxx
@@ -149,7 +149,7 @@ void Views::appendByDescriptor(
buf.append( "CREATE VIEW ");
bufferQuoteQualifiedIdentifier( buf, schema, name, m_pSettings );
- buf.append(" AS " ).append( command );
+ buf.append(" AS " + command );
stmt->executeUpdate( buf.makeStringAndClear() );
diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index fe1b68db85b9..3ab8e4288703 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -3075,7 +3075,7 @@ void SvxIconSelectorDialog::ImportGraphics(
fPath = OUString::Concat(rPaths[0].subView(8)) + "/";
for ( sal_Int32 i = 0; i < rejectedCount; ++i )
{
- message.append(fPath).append(rejected[i]).append("\n");
+ message.append(fPath + rejected[i] + "\n");
}
SvxIconChangeDialog aDialog(m_xDialog.get(), message.makeStringAndClear());
diff --git a/dbaccess/source/core/api/CacheSet.cxx b/dbaccess/source/core/api/CacheSet.cxx
index e6f31962834f..366a727be58d 100644
--- a/dbaccess/source/core/api/CacheSet.cxx
+++ b/dbaccess/source/core/api/CacheSet.cxx
@@ -160,7 +160,7 @@ void OCacheSet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQ
connectivity::ORowVector< ORowSetValue > ::Vector::iterator aEnd = _rInsertRow->end();
for(; aIter != aEnd;++aIter)
{
- aSql.append(::dbtools::quoteName( aQuote,m_xSetMetaData->getColumnName(i++)) ).append(",");
+ aSql.append(::dbtools::quoteName( aQuote,m_xSetMetaData->getColumnName(i++)) + ",");
aValues.append("?,");
}
@@ -261,7 +261,7 @@ void OCacheSet::fillParameters( const ORowSetRow& _rRow
}
if(aIter->isModified())
{
- _sParameter.append(::dbtools::quoteName( aQuote,aColumnName) ).append("?,");
+ _sParameter.append(::dbtools::quoteName( aQuote,aColumnName) + "?,");
}
}
}
@@ -282,7 +282,7 @@ void OCacheSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOri
{
aCondition.setLength(aCondition.getLength()-5);
- aSql.append(" WHERE " ).append( aCondition.makeStringAndClear());
+ aSql.append(" WHERE " + aCondition.makeStringAndClear());
}
else
::dbtools::throwSQLException(
diff --git a/dbaccess/source/core/api/KeySet.cxx b/dbaccess/source/core/api/KeySet.cxx
index e61259bf61b1..8999ded1e3c7 100644
--- a/dbaccess/source/core/api/KeySet.cxx
+++ b/dbaccess/source/core/api/KeySet.cxx
@@ -220,11 +220,11 @@ namespace
fullName = OUString::Concat(tblName) + "." + colName;
if ( _rValue.isNull() )
{
- o_buf.append(fullName).append(" IS NULL ");
+ o_buf.append(fullName + " IS NULL ");
}
else
{
- o_buf.append(fullName).append(" = ? ");
+ o_buf.append(fullName + " = ? ");
}
}
}
@@ -496,7 +496,7 @@ void OKeySet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrigi
}
if((*_rInsertRow)[columnName.second.nPosition].isModified())
{
- aSql.append(::dbtools::quoteName( aQuote,columnName.second.sRealName)).append(aPara);
+ aSql.append(::dbtools::quoteName( aQuote,columnName.second.sRealName) + aPara);
}
++i;
}
@@ -513,7 +513,7 @@ void OKeySet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrigi
aSql.append(" WHERE ");
if(!sKeyCondition.isEmpty() && !sIndexCondition.isEmpty())
{
- aSql.append(sKeyCondition.makeStringAndClear()).append(sIndexCondition.makeStringAndClear());
+ aSql.append(sKeyCondition.makeStringAndClear() + sIndexCondition.makeStringAndClear());
}
else if(!sKeyCondition.isEmpty())
{
@@ -611,7 +611,7 @@ void OKeySet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQLT
{
bRefetch = std::find(m_aFilterColumns.begin(),m_aFilterColumns.end(),columnName.second.sRealName) == m_aFilterColumns.end();
}
- aSql.append(::dbtools::quoteName( aQuote,columnName.second.sRealName)).append(",");
+ aSql.append(::dbtools::quoteName( aQuote,columnName.second.sRealName) + ",");
aValues.append("?,");
bModified = true;
}
@@ -717,7 +717,7 @@ void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const OUString& i_sSQ
SelectColumnsMetaData::const_iterator aFind = m_pKeyColumnNames->find(autoColumn);
if ( aFind != aEnd )
{
- sMaxStmt.append(" MAX(").append(::dbtools::quoteName( sQuote,aFind->second.sRealName)).append("),");
+ sMaxStmt.append(" MAX(" + ::dbtools::quoteName( sQuote,aFind->second.sRealName) + "),");
}
}
diff --git a/dbaccess/source/core/api/OptimisticSet.cxx b/dbaccess/source/core/api/OptimisticSet.cxx
index 4cec7ed6839b..c214402f50c5 100644
--- a/dbaccess/source/core/api/OptimisticSet.cxx
+++ b/dbaccess/source/core/api/OptimisticSet.cxx
@@ -188,7 +188,7 @@ void OptimisticSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _
OUStringBuffer& rPart = aSql[columnName.second.sTableName];
if ( !rPart.isEmpty() )
rPart.append(", ");
- rPart.append(sQuotedColumnName).append(" = ?");
+ rPart.append(sQuotedColumnName + " = ?");
}
}
@@ -211,7 +211,7 @@ void OptimisticSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _
" SET " + elem.second.toString());
OUStringBuffer& rCondition = aKeyConditions[elem.first];
if ( !rCondition.isEmpty() )
- sSql.append(" WHERE ").append( rCondition );
+ sSql.append(" WHERE " + rCondition );
executeUpdate(_rInsertRow ,_rOriginalRow,sSql.makeStringAndClear(),elem.first);
}
diff --git a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
index 879342932cc0..2284f1db3e3f 100644
--- a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
+++ b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
@@ -174,28 +174,28 @@ namespace
switch( i_nFilterOperator )
{
case SQLFilterOperator::EQUAL:
- o_sRet.append(" = " ).append( i_sValue);
+ o_sRet.append(OUString::Concat(" = ") + i_sValue);
break;
case SQLFilterOperator::NOT_EQUAL:
- o_sRet.append(" <> " ).append( i_sValue);
+ o_sRet.append(OUString::Concat(" <> ") + i_sValue);
break;
case SQLFilterOperator::LESS:
- o_sRet.append(" < " ).append( i_sValue);
+ o_sRet.append(OUString::Concat(" < ") + i_sValue);
break;
case SQLFilterOperator::GREATER:
- o_sRet.append(" > " ).append( i_sValue);
+ o_sRet.append(OUString::Concat(" > ") + i_sValue);
break;
case SQLFilterOperator::LESS_EQUAL:
- o_sRet.append(" <= " ).append( i_sValue);
+ o_sRet.append(OUString::Concat(" <= ") + i_sValue);
break;
case SQLFilterOperator::GREATER_EQUAL:
- o_sRet.append(" >= " ).append( i_sValue);
+ o_sRet.append(OUString::Concat(" >= ") + i_sValue);
break;
case SQLFilterOperator::LIKE:
- o_sRet.append(" LIKE " ).append( i_sValue);
+ o_sRet.append(OUString::Concat(" LIKE ") + i_sValue);
break;
case SQLFilterOperator::NOT_LIKE:
- o_sRet.append(" NOT LIKE " ).append( i_sValue);
+ o_sRet.append(OUString::Concat(" NOT LIKE ") + i_sValue);
break;
case SQLFilterOperator::SQLNULL:
o_sRet.append(" IS NULL");
@@ -759,7 +759,7 @@ Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getColumns( )
OUString sOriginalWhereClause = getSQLPart( Where, m_aSqlIterator, false );
if ( !sOriginalWhereClause.isEmpty() )
{
- aSQL.append( " AND ( " ).append( sOriginalWhereClause ).append( " ) " );
+ aSQL.append( " AND ( " + sOriginalWhereClause + " ) " );
}
OUString sGroupBy = getSQLPart( Group, m_aSqlIterator, true );
@@ -1665,7 +1665,7 @@ void OSingleSelectQueryComposer::setConditionByColumn( const Reference< XPropert
const ::sal_Int64 nLength = xClob->length();
if ( sal_Int64(nLength + aSQL.getLength() + STR_LIKE.getLength() ) < sal_Int64(SAL_MAX_INT32) )
{
- aSQL.append("'").append(xClob->getSubString(1,static_cast<sal_Int32>(nLength))).append("'");
+ aSQL.append("'" + xClob->getSubString(1,static_cast<sal_Int32>(nLength)) + "'");
}
}
else
diff --git a/dbaccess/source/core/dataaccess/ContentHelper.cxx b/dbaccess/source/core/dataaccess/ContentHelper.cxx
index e237d8ea3b88..94cb7168d037 100644
--- a/dbaccess/source/core/dataaccess/ContentHelper.cxx
+++ b/dbaccess/source/core/dataaccess/ContentHelper.cxx
@@ -123,7 +123,7 @@ OUString OContentHelper::impl_getHierarchicalName( bool _includingRootContainer
xProp->getPropertyValue( PROPERTY_NAME ) >>= sName;
OUString sPrevious = aHierarchicalName.makeStringAndClear();
- aHierarchicalName.append( sName ).append( "/" ).append( sPrevious );
+ aHierarchicalName.append( sName + "/" + sPrevious );
}
}
OUString sHierarchicalName( aHierarchicalName.makeStringAndClear() );
diff --git a/dbaccess/source/filter/xml/xmlServerDatabase.cxx b/dbaccess/source/filter/xml/xmlServerDatabase.cxx
index 590db077437b..654a9f403402 100644
--- a/dbaccess/source/filter/xml/xmlServerDatabase.cxx
+++ b/dbaccess/source/filter/xml/xmlServerDatabase.cxx
@@ -74,46 +74,46 @@ OXMLServerDatabase::OXMLServerDatabase( ODBFilter& rImport,
OUStringBuffer sURL;
if ( sType == "sdbc:mysql:jdbc" || sType == "sdbc:mysqlc" || sType == "sdbc:mysql:mysqlc" )
{
- sURL.append( sType ).append( ":" ).append(sHostName);
+ sURL.append( sType + ":" + sHostName);
if ( !sPortNumber.isEmpty() )
{
- sURL.append(":").append(sPortNumber);
+ sURL.append(":" + sPortNumber);
}
if ( !sDatabaseName.isEmpty() )
{
- sURL.append("/").append(sDatabaseName);
+ sURL.append("/" + sDatabaseName);
}
}
else if ( sType == "jdbc:oracle:thin" )
{
- sURL.append("jdbc:oracle:thin:@").append(sHostName);
+ sURL.append("jdbc:oracle:thin:@" + sHostName);
if ( !sPortNumber.isEmpty() )
{
- sURL.append(":").append(sPortNumber);
+ sURL.append(":" + sPortNumber);
}
if ( !sDatabaseName.isEmpty() )
{
- sURL.append(":").append(sDatabaseName);
+ sURL.append(":" + sDatabaseName);
}
}
else if ( sType == "sdbc:address:ldap" )
{
- sURL.append("sdbc:address:ldap:").append(sHostName);
+ sURL.append("sdbc:address:ldap:" + sHostName);
if ( !sPortNumber.isEmpty() )
{
- sURL.append(":").append(sPortNumber);
+ sURL.append(":" + sPortNumber);
}
}
else
{
- sURL.append(sType).append(":").append(sHostName);
+ sURL.append(sType + ":" + sHostName);
if ( !sPortNumber.isEmpty() )
{
- sURL.append(":").append(sPortNumber);
+ sURL.append(":" + sPortNumber);
}
if ( !sDatabaseName.isEmpty() )
{
- sURL.append(":").append(sDatabaseName);
+ sURL.append(":" + sDatabaseName);
}
}
try
diff --git a/dbaccess/source/ui/dlg/directsql.cxx b/dbaccess/source/ui/dlg/directsql.cxx
index fc8191707c44..ac3425999cf9 100644
--- a/dbaccess/source/ui/dlg/directsql.cxx
+++ b/dbaccess/source/ui/dlg/directsql.cxx
@@ -258,7 +258,7 @@ namespace dbaui
for (;;)
{
// be dumb, treat everything as a string
- out.append(xRow->getString(i)).append(",");
+ out.append(xRow->getString(i) + ",");
i++;
}
}
diff --git a/dbaccess/source/ui/dlg/tablespage.cxx b/dbaccess/source/ui/dlg/tablespage.cxx
index 8162126a3749..91456123ec58 100644
--- a/dbaccess/source/ui/dlg/tablespage.cxx
+++ b/dbaccess/source/ui/dlg/tablespage.cxx
@@ -381,7 +381,7 @@ namespace dbaui
bCatalogWildcard = m_xTablesList->isWildcardChecked(*xCatalog);
if (m_bCatalogAtStart)
{
- sComposedName.append(m_xTablesList->GetWidget().get_text(*xCatalog)).append(m_sCatalogSeparator);
+ sComposedName.append(m_xTablesList->GetWidget().get_text(*xCatalog) + m_sCatalogSeparator);
if (bCatalogWildcard)
sComposedName.append(sWildcard);
}
@@ -396,7 +396,7 @@ namespace dbaui
}
}
bSchemaWildcard = m_xTablesList->isWildcardChecked(*xSchema);
- sComposedName.append(m_xTablesList->GetWidget().get_text(*xSchema)).append(".");
+ sComposedName.append(m_xTablesList->GetWidget().get_text(*xSchema) + ".");
}
if (bSchemaWildcard)
diff --git a/dbaccess/source/ui/misc/WCopyTable.cxx b/dbaccess/source/ui/misc/WCopyTable.cxx
index 4420b83bf428..05d6181ca881 100644
--- a/dbaccess/source/ui/misc/WCopyTable.cxx
+++ b/dbaccess/source/ui/misc/WCopyTable.cxx
@@ -230,7 +230,7 @@ OUString ObjectCopySource::getSelectStatement() const
aSQL.append( ", " );
}
- aSQL.append( "FROM " ).append( ::dbtools::composeTableNameForSelect( m_xConnection, m_xObject ) );
+ aSQL.append( "FROM " + ::dbtools::composeTableNameForSelect( m_xConnection, m_xObject ) );
sSelectStatement = aSQL.makeStringAndClear();
}
diff --git a/dbaccess/source/ui/uno/copytablewizard.cxx b/dbaccess/source/ui/uno/copytablewizard.cxx
index 50fa22f6dad4..12e3575dbafd 100644
--- a/dbaccess/source/ui/uno/copytablewizard.cxx
+++ b/dbaccess/source/ui/uno/copytablewizard.cxx
@@ -1448,7 +1448,7 @@ OUString CopyTableWizard::impl_getServerSideCopyStatement_throw(const Reference<
{
if ( !sColumns.isEmpty() )
sColumns.append(",");
- sColumns.append(sQuote).append(aDestColumnNames[rColumnPositionPair.second - 1]).append(sQuote);
+ sColumns.append(sQuote + aDestColumnNames[rColumnPositionPair.second - 1] + sQuote);
}
}
const OUString sComposedTableName = ::dbtools::composeTableName( xDestMetaData, _xTable, ::dbtools::EComposeRule::InDataManipulation, true );
diff --git a/desktop/source/deployment/registry/component/dp_component.cxx b/desktop/source/deployment/registry/component/dp_component.cxx
index 5bf230c17f68..ac859a3d946f 100644
--- a/desktop/source/deployment/registry/component/dp_component.cxx
+++ b/desktop/source/deployment/registry/component/dp_component.cxx
@@ -1090,7 +1090,7 @@ Reference<XComponentContext> raise_uno_process(
catch (...) {
OUStringBuffer sMsg = "error starting process: " + url;
for(const auto& arg : args)
- sMsg.append(" ").append(arg);
+ sMsg.append(" " + arg);
throw uno::RuntimeException(sMsg.makeStringAndClear());
}
try {
diff --git a/extensions/source/propctrlr/selectlabeldialog.cxx b/extensions/source/propctrlr/selectlabeldialog.cxx
index 9cefcb72b273..1987de8d85c5 100644
--- a/extensions/source/propctrlr/selectlabeldialog.cxx
+++ b/extensions/source/propctrlr/selectlabeldialog.cxx
@@ -205,10 +205,9 @@ namespace pcr
if (!::comphelper::hasProperty(PROPERTY_LABEL, xAsSet))
continue;
- OUString sDisplayName = OUStringBuffer(
- ::comphelper::getString(xAsSet->getPropertyValue(PROPERTY_LABEL))).
- append(" (").append(sName).append(')').
- makeStringAndClear();
+ OUString sDisplayName =
+ ::comphelper::getString(xAsSet->getPropertyValue(PROPERTY_LABEL)) +
+ " (" + sName + ")";
// all requirements met -> insert
m_xUserData.emplace_back(new Reference<XPropertySet>(xAsSet));
diff --git a/filter/source/config/cache/filtercache.cxx b/filter/source/config/cache/filtercache.cxx
index b3ac1594fade..c97d39f2319b 100644
--- a/filter/source/config/cache/filtercache.cxx
+++ b/filter/source/config/cache/filtercache.cxx
@@ -995,13 +995,13 @@ void FilterCache::impl_validateAndOptimize()
aType[PROPNAME_NAME] >>= sInternalTypeNameCheck;
if (sInternalTypeNameCheck != sType)
{
- sLog.append("Warning\t:\t" "The type \"").append(sType).append("\" does support the property \"Name\" correctly.\n");
+ sLog.append("Warning\t:\t" "The type \"" + sType + "\" does support the property \"Name\" correctly.\n");
++nWarnings;
}
if (!ce && !cu)
{
- sLog.append("Warning\t:\t" "The type \"").append(sType).append("\" does not contain any URL pattern nor any extensions.\n");
+ sLog.append("Warning\t:\t" "The type \"" + sType + "\" does not contain any URL pattern nor any extensions.\n");
++nWarnings;
}
#endif
@@ -1077,7 +1077,7 @@ void FilterCache::impl_validateAndOptimize()
(!bReferencedByHandler)
)
{
- sLog.append("Warning\t:\t" "The type \"").append(sType).append("\" is not used by any filter, loader or content handler.\n");
+ sLog.append("Warning\t:\t" "The type \"" + sType + "\" is not used by any filter, loader or content handler.\n");
++nWarnings;
}
}
@@ -1098,7 +1098,7 @@ void FilterCache::impl_validateAndOptimize()
sLog.append("warning\t:\t");
}
- sLog.append("The type \"").append(sType).append("\" points to an invalid filter \"").append(sPrefFilter).append("\".\n");
+ sLog.append("The type \"" + sType + "\" points to an invalid filter \"" + sPrefFilter + "\".\n");
continue;
}
@@ -1107,10 +1107,10 @@ void FilterCache::impl_validateAndOptimize()
aPrefFilter[PROPNAME_TYPE] >>= sFilterTypeReg;
if (sFilterTypeReg != sType)
{
- sLog.append("error\t:\t" "The preferred filter \"")
- .append(sPrefFilter).append("\" of type \"").append(sType)
- .append("\" is registered for another type \"").append(sFilterTypeReg)
- .append("\".\n");
+ sLog.append("error\t:\t" "The preferred filter \"" +
+ sPrefFilter + "\" of type \"" + sType +
+ "\" is registered for another type \"" + sFilterTypeReg +
+ "\".\n");
++nErrors;
}
@@ -1118,8 +1118,8 @@ void FilterCache::impl_validateAndOptimize()
aPrefFilter[PROPNAME_FLAGS] >>= nFlags;
if (!(static_cast<SfxFilterFlags>(nFlags) & SfxFilterFlags::IMPORT))
{
- sLog.append("error\t:\t" "The preferred filter \"").append(sPrefFilter).append("\" of type \"")
- .append(sType).append("\" is not an IMPORT filter!\n");
+ sLog.append("error\t:\t" "The preferred filter \"" + sPrefFilter + "\" of type \"" +
+ sType + "\" is not an IMPORT filter!\n");
++nErrors;
}
@@ -1127,8 +1127,8 @@ void FilterCache::impl_validateAndOptimize()
aPrefFilter[PROPNAME_NAME] >>= sInternalFilterNameCheck;
if (sInternalFilterNameCheck != sPrefFilter)
{
- sLog.append("Warning\t:\t" "The filter \"").append(sPrefFilter)
- .append("\" does support the property \"Name\" correctly.\n");
+ sLog.append("Warning\t:\t" "The filter \"" + sPrefFilter +
+ "\" does support the property \"Name\" correctly.\n");
++nWarnings;
}
}
diff --git a/forms/source/xforms/model_ui.cxx b/forms/source/xforms/model_ui.cxx
index 8591186b4bbb..4592fa3efe97 100644
--- a/forms/source/xforms/model_ui.cxx
+++ b/forms/source/xforms/model_ui.cxx
@@ -287,7 +287,7 @@ OUString Model::getNodeDisplayName( const css::uno::Reference<css::xml::dom::XNo
OUString sContent = xNode->getNodeValue();
if( bDetail || ! lcl_isWhitespace( sContent ) )
{
- aBuffer.append("\"").append(Convert::collapseWhitespace( sContent )).append("\"");
+ aBuffer.append("\"" + Convert::collapseWhitespace( sContent ) + "\"");
}
}
break;
diff --git a/framework/source/accelerators/storageholder.cxx b/framework/source/accelerators/storageholder.cxx
index 4c7702e579ca..e8a26845f489 100644
--- a/framework/source/accelerators/storageholder.cxx
+++ b/framework/source/accelerators/storageholder.cxx
@@ -345,7 +345,7 @@ css::uno::Reference< css::embed::XStorage > StorageHolder::getParentStorage(cons
sal_Int32 i = 0;
for (i = 0; i < c - 1; ++i)
{
- sParentPath.append(lFolders[i]).append(PATH_SEPARATOR);
+ sParentPath.append(lFolders[i] + PATH_SEPARATOR);
}
auto pParent = m_lStorages.find(sParentPath.makeStringAndClear());
diff --git a/i18nlangtag/source/languagetag/languagetag.cxx b/i18nlangtag/source/languagetag/languagetag.cxx
index acdb3374b6ff..41f23973020f 100644
--- a/i18nlangtag/source/languagetag/languagetag.cxx
+++ b/i18nlangtag/source/languagetag/languagetag.cxx
@@ -1115,11 +1115,11 @@ bool LanguageTagImpl::canonicalize()
1 + aCountry.getLength() + 1 + aVariants.getLength());
aBuf.append( aLanguage);
if (!aScript.isEmpty())
- aBuf.append("-").append(aScript);
+ aBuf.append("-" + aScript);
if (!aCountry.isEmpty())
- aBuf.append("-").append(aCountry);
+ aBuf.append("-" + aCountry);
if (!aVariants.isEmpty())
- aBuf.append("-").append(aVariants);
+ aBuf.append("-" + aVariants);
OUString aStr( aBuf.makeStringAndClear());
if (maBcp47 != aStr)
diff --git a/i18npool/source/collator/collator_unicode.cxx b/i18npool/source/collator/collator_unicode.cxx
index 8c8255a18229..2cff45a6d68d 100644
--- a/i18npool/source/collator/collator_unicode.cxx
+++ b/i18npool/source/collator/collator_unicode.cxx
@@ -160,10 +160,10 @@ Collator_Unicode::loadCollatorAlgorithm(const OUString& rAlgorithm, const lang::
#ifdef SAL_DLLPREFIX
aBuf.append(SAL_DLLPREFIX);
#endif
- aBuf.append( "collator_data" ).append( SAL_DLLEXTENSION );
+ aBuf.append( "collator_data" SAL_DLLEXTENSION );
hModule = osl_loadModuleRelative( &thisModule, aBuf.makeStringAndClear().pData, SAL_LOADMODULE_DEFAULT );
if (hModule) {
- aBuf.append("get_").append(rLocale.Language).append("_");
+ aBuf.append("get_" + rLocale.Language + "_");
if ( rLocale.Language == "zh" ) {
OUString func_base = aBuf.makeStringAndClear();
if (OUString("TW HK MO").indexOf(rLocale.Country) >= 0)
diff --git a/lotuswordpro/source/filter/lwptblformula.cxx b/lotuswordpro/source/filter/lwptblformula.cxx
index 6c9f29f722af..301b414e1b4d 100644
--- a/lotuswordpro/source/filter/lwptblformula.cxx
+++ b/lotuswordpro/source/filter/lwptblformula.cxx
@@ -428,7 +428,7 @@ OUString LwpFormulaFunc::ToString(LwpTableLayout* pCellsMap)
//Append args
for (auto const& elem : m_aArgs)
{
- aFormula.append(elem->ToArgString(pCellsMap)).append("|"); //separator
+ aFormula.append(elem->ToArgString(pCellsMap) + "|"); //separator
}
//erase the last "|"
diff --git a/oox/source/core/xmlfilterbase.cxx b/oox/source/core/xmlfilterbase.cxx
index bb63873f5540..b46392d1a246 100644
--- a/oox/source/core/xmlfilterbase.cxx
+++ b/oox/source/core/xmlfilterbase.cxx
@@ -602,7 +602,7 @@ writeElement( const FSHelperPtr& pDoc, sal_Int32 nXmlElement, const Sequence< OU
for( const OUString& rItem : aItems )
{
- sRep.append( " " ).append( rItem );
+ sRep.append( " " + rItem );
}
writeElement( pDoc, nXmlElement, sRep.makeStringAndClear() );
diff --git a/oox/source/dump/dumperbase.cxx b/oox/source/dump/dumperbase.cxx
index b73c24accef0..1638d51a6964 100644
--- a/oox/source/dump/dumperbase.cxx
+++ b/oox/source/dump/dumperbase.cxx
@@ -2409,7 +2409,7 @@ void XmlStreamObject::implDumpText( TextInputStream& rTextStrm )
matching end element on the same line in the next iteration. */
if( bStartElem )
{
- aOldStartElem.append( aElem ).append( aText );
+ aOldStartElem.append( aElem + aText );
}
else
{
diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx
index c6c81a9bec3c..dfb81a27e713 100644
--- a/oox/source/export/drawingml.cxx
+++ b/oox/source/export/drawingml.cxx
@@ -4735,8 +4735,7 @@ OString DrawingML::WriteWdpPicture( const OUString& rFileId, const Sequence< sal
OUString sFileName = "media/hdphoto" + OUString::number( mnWdpImageCounter++ ) + ".wdp";
Reference< XOutputStream > xOutStream = mpFB->openFragmentStream( OUStringBuffer()
.appendAscii( GetComponentDir() )
- .append( "/" )
- .append( sFileName )
+ .append( "/" + sFileName )
.makeStringAndClear(),
"image/vnd.ms-photo" );
OUString sId;
diff --git a/oox/source/export/vmlexport.cxx b/oox/source/export/vmlexport.cxx
index 36d35a7ed18b..0506041e67d5 100644
--- a/oox/source/export/vmlexport.cxx
+++ b/oox/source/export/vmlexport.cxx
@@ -1120,15 +1120,9 @@ void VMLExport::AddLineDimensions( const tools::Rectangle& rRectangle )
aBottom = OString::number( rRectangle.Bottom() );
}
- m_pShapeAttrList->add( XML_from,
- OStringBuffer( 20 ).append( aLeft )
- .append( "," ).append( aTop )
- .makeStringAndClear() );
-
- m_pShapeAttrList->add( XML_to,
- OStringBuffer( 20 ).append( aRight )
- .append( "," ).append( aBottom )
- .makeStringAndClear() );
+ m_pShapeAttrList->add( XML_from, aLeft + "," + aTop );
+
+ m_pShapeAttrList->add( XML_to, aRight + "," + aBottom );
}
void VMLExport::AddRectangleDimensions( OStringBuffer& rBuffer, const tools::Rectangle& rRectangle, bool rbAbsolutePos)
diff --git a/oox/source/ole/vbamodule.cxx b/oox/source/ole/vbamodule.cxx
index 47c676cdc086..ade0bd97aeae 100644
--- a/oox/source/ole/vbamodule.cxx
+++ b/oox/source/ole/vbamodule.cxx
@@ -301,8 +301,7 @@ void VbaModule::createModule( std::u16string_view rVBASourceCode,
else
{
// add a subroutine named after the module itself
- aSourceCode.append( "Sub " ).
- append( maName.replace( ' ', '_' ) ).append( '\n' );
+ aSourceCode.append( "Sub " + maName.replace( ' ', '_' ) + "\n" );
}
// append passed VBA source code
diff --git a/reportdesign/source/filter/xml/xmlControlProperty.cxx b/reportdesign/source/filter/xml/xmlControlProperty.cxx
index 1bc323d466c1..4cebfa18a7ea 100644
--- a/reportdesign/source/filter/xml/xmlControlProperty.cxx
+++ b/reportdesign/source/filter/xml/xmlControlProperty.cxx
@@ -188,9 +188,9 @@ Any OXMLControlProperty::convertString(const css::uno::Type& _rExpectedType, con
bool bSuccess =
::sax::Converter::convertBool(bValue, _rReadCharacters);
OSL_ENSURE(bSuccess,
- OStringBuffer("OXMLControlProperty::convertString: could not convert \"").
- append(OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US)).
- append("\" into a boolean!").getStr());
+ OStringBuffer("OXMLControlProperty::convertString: could not convert \"" +
+ OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US) +
+ "\" into a boolean!").getStr());
aReturn <<= bValue;
}
break;
@@ -201,9 +201,9 @@ Any OXMLControlProperty::convertString(const css::uno::Type& _rExpectedType, con
bool bSuccess =
::sax::Converter::convertNumber(nValue, _rReadCharacters);
OSL_ENSURE(bSuccess,
- OStringBuffer("OXMLControlProperty::convertString: could not convert \"").
- append(OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US)).
- append("\" into an integer!").getStr());
+ OStringBuffer("OXMLControlProperty::convertString: could not convert \"" +
+ OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US) +
+ "\" into an integer!").getStr());
if (TypeClass_SHORT == _rExpectedType.getTypeClass())
aReturn <<= static_cast<sal_Int16>(nValue);
else
@@ -221,9 +221,9 @@ Any OXMLControlProperty::convertString(const css::uno::Type& _rExpectedType, con
bool bSuccess =
::sax::Converter::convertDouble(nValue, _rReadCharacters);
OSL_ENSURE(bSuccess,
- OStringBuffer("OXMLControlProperty::convertString: could not convert \"").
- append(OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US)).
- append("\" into a double!").getStr());
+ OStringBuffer("OXMLControlProperty::convertString: could not convert \"" +
+ OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US) +
+ "\" into a double!").getStr());
aReturn <<= nValue;
}
break;
@@ -250,9 +250,9 @@ Any OXMLControlProperty::convertString(const css::uno::Type& _rExpectedType, con
bool bSuccess =
::sax::Converter::convertDouble(nValue, _rReadCharacters);
OSL_ENSURE(bSuccess,
- OStringBuffer("OPropertyImport::convertString: could not convert \"").
- append(OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US)).
- append("\" into a double!").getStr());
+ OStringBuffer("OPropertyImport::convertString: could not convert \"" +
+ OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US) +
+ "\" into a double!").getStr());
// then convert it into the target type
switch (nType)
diff --git a/sc/source/core/data/postit.cxx b/sc/source/core/data/postit.cxx
index 84633a640de8..882cc8c190bb 100644
--- a/sc/source/core/data/postit.cxx
+++ b/sc/source/core/data/postit.cxx
@@ -1169,7 +1169,7 @@ ScCaptionPtr ScNoteUtil::CreateTempCaption(
if( pNote && !pNote->IsCaptionShown() )
{
if( !aBuffer.isEmpty() )
- aBuffer.append( "\n--------\n" ).append( pNote->GetText() );
+ aBuffer.append( "\n--------\n" + pNote->GetText() );
pNoteCaption = pNote->GetOrCreateCaption( rPos );
}
diff --git a/sc/source/core/tool/address.cxx b/sc/source/core/tool/address.cxx
index 06ffd08c7d44..283f45ee8d0a 100644
--- a/sc/source/core/tool/address.cxx
+++ b/sc/source/core/tool/address.cxx
@@ -2185,7 +2185,7 @@ static void lcl_ScRange_Format_XL_Header( OUStringBuffer& rString, const ScRange
default:
if (!aDocName.isEmpty())
{
- rString.append("[").append(aDocName).append("]");
+ rString.append("[" + aDocName + "]");
}
rString.append(aTabName);
break;
diff --git a/sc/source/core/tool/chgtrack.cxx b/sc/source/core/tool/chgtrack.cxx
index 7abcc01864ac..ebe614ed7b81 100644
--- a/sc/source/core/tool/chgtrack.cxx
+++ b/sc/source/core/tool/chgtrack.cxx
@@ -426,20 +426,15 @@ void ScChangeAction::GetDescription(
// not properly restored in formulas. See specification at
// http://specs.openoffice.org/calc/ease-of-use/redlining_comment.sxw
- OUStringBuffer aBuf(rStr); // Take the original string.
if (GetType() == SC_CAT_MOVE)
{
- aBuf.append(
- ScResId(STR_CHANGED_MOVE_REJECTION_WARNING)).append(" ");
- rStr = aBuf.makeStringAndClear();
+ rStr += ScResId(STR_CHANGED_MOVE_REJECTION_WARNING) + " ";
return;
}
if (IsInsertType())
{
- aBuf.append(
- ScResId(STR_CHANGED_DELETE_REJECTION_WARNING)).append(" ");
- rStr = aBuf.makeStringAndClear();
+ rStr += ScResId(STR_CHANGED_DELETE_REJECTION_WARNING) + " ";
return;
}
@@ -454,19 +449,13 @@ void ScChangeAction::GetDescription(
if (pReject->GetType() == SC_CAT_MOVE)
{
- aBuf.append(
- ScResId(STR_CHANGED_MOVE_REJECTION_WARNING));
- aBuf.append(' ');
- rStr = aBuf.makeStringAndClear();
+ rStr += ScResId(STR_CHANGED_MOVE_REJECTION_WARNING) + " ";
return;
}
if (pReject->IsDeleteType())
{
- aBuf.append(
- ScResId(STR_CHANGED_DELETE_REJECTION_WARNING));
- aBuf.append(' ');
- rStr = aBuf.makeStringAndClear();
+ rStr += ScResId(STR_CHANGED_DELETE_REJECTION_WARNING) + " ";
return;
}
@@ -482,15 +471,9 @@ void ScChangeAction::GetDescription(
return;
if( itChangeAction->second->GetType() == SC_CAT_MOVE)
- aBuf.append(
- ScResId(STR_CHANGED_MOVE_REJECTION_WARNING));
+ rStr += ScResId(STR_CHANGED_MOVE_REJECTION_WARNING) + " ";
else
- aBuf.append(
- ScResId(STR_CHANGED_DELETE_REJECTION_WARNING));
-
- aBuf.append(' ');
- rStr = aBuf.makeStringAndClear();
- return;
+ rStr += ScResId(STR_CHANGED_DELETE_REJECTION_WARNING) + " ";
}
OUString ScChangeAction::GetRefString(
@@ -707,15 +690,13 @@ void ScChangeActionIns::GetDescription(
return;
// Construct a range string to replace '#1' first.
- OUStringBuffer aBuf(ScResId(pWhatId));
- aBuf.append(' ');
- aBuf.append(GetRefString(GetBigRange(), rDoc));
- OUString aRangeStr = aBuf.makeStringAndClear();
+ OUString aRangeStr = ScResId(pWhatId) +
+ " " +
+ GetRefString(GetBigRange(), rDoc);
aRsc = aRsc.replaceAt(nPos, 2, aRangeStr); // replace '#1' with the range string.
- aBuf.append(rStr).append(aRsc);
- rStr = aBuf.makeStringAndClear();
+ rStr += aRsc;
}
bool ScChangeActionIns::IsEndOfList() const
@@ -955,15 +936,11 @@ void ScChangeActionDel::GetDescription(
return;
// Build a string to replace with.
- OUStringBuffer aBuf;
- aBuf.append(ScResId(pWhatId));
- aBuf.append(' ');
- aBuf.append(GetRefString(aTmpRange, rDoc));
- OUString aRangeStr = aBuf.makeStringAndClear();
+ OUString aRangeStr = ScResId(pWhatId) + " " +
+ GetRefString(aTmpRange, rDoc);
aRsc = aRsc.replaceAt(nPos, 2, aRangeStr); // replace '#1' with the string.
- aBuf.append(rStr).append(aRsc);
- rStr = aBuf.makeStringAndClear(); // append to the original.
+ rStr += aRsc; // append to the original.
}
bool ScChangeActionDel::Reject( ScDocument& rDoc )
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index 233038b90c24..488e5ab1fd9f 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -688,7 +688,7 @@ static OUString lcl_makeExternalNameStr(const OUString& rFile, const OUString& r
OUStringBuffer aBuf(aFile.getLength() + aName.getLength() + 9);
if (bODF)
aBuf.append( '[');
- aBuf.append( "'" ).append( aFile ).append( "'" ).append( OUStringChar(cSep) );
+ aBuf.append( "'" + aFile + "'" + OUStringChar(cSep) );
if (bODF)
aBuf.append( "$$'" );
aBuf.append( aName);
@@ -952,7 +952,7 @@ struct ConventionOOO_A1 : public Convention_A1
else
aFile = INetURLObject::decode(rFileName, INetURLObject::DecodeMechanism::Unambiguous);
- rBuffer.append("'").append(aFile.replaceAll("'", "''")).append("'#");
+ rBuffer.append("'" + aFile.replaceAll("'", "''") + "'#");
if (!rRef.IsTabRel())
rBuffer.append('$');
diff --git a/sc/source/filter/dif/difimp.cxx b/sc/source/filter/dif/difimp.cxx
index 2e68d4ba57ec..a640ebfba70a 100644
--- a/sc/source/filter/dif/difimp.cxx
+++ b/sc/source/filter/dif/difimp.cxx
@@ -502,9 +502,7 @@ DATASET DifParser::GetNextDataset()
ReadNextLine( aTmpLine );
if ( eRet == D_SYNT_ERROR )
{ // for broken records write "#ERR: data" to cell
- m_aData = "#ERR: ";
- m_aData.append(pCurrentBuffer).append(" (");
- m_aData.append(aTmpLine).append(')');
+ m_aData = OUString::Concat("#ERR: ") + pCurrentBuffer + " (" + aTmpLine + ")";
eRet = D_STRING;
}
else
diff --git a/sc/source/filter/excel/xehelper.cxx b/sc/source/filter/excel/xehelper.cxx
index d7b769e2c811..d841789e8b5e 100644
--- a/sc/source/filter/excel/xehelper.cxx
+++ b/sc/source/filter/excel/xehelper.cxx
@@ -739,7 +739,7 @@ void XclExpHFConverter::AppendPortion( const EditTextObject* pTextObj, sal_Unico
(aFontData.mbItalic != aNewData.mbItalic);
if( bNewFont || (bNewStyle && pFontList) )
{
- aParaText.append("&\"").append(aNewData.maName);
+ aParaText.append("&\"" + aNewData.maName);
if( pFontList )
{
FontMetric aFontMetric( pFontList->Get(
@@ -748,7 +748,7 @@ void XclExpHFConverter::AppendPortion( const EditTextObject* pTextObj, sal_Unico
aNewData.mbItalic ? ITALIC_NORMAL : ITALIC_NONE ) );
aNewData.maStyle = pFontList->GetStyleName( aFontMetric );
if( !aNewData.maStyle.isEmpty() )
- aParaText.append(",").append(aNewData.maStyle);
+ aParaText.append("," + aNewData.maStyle);
}
aParaText.append("\"");
}
@@ -784,7 +784,7 @@ void XclExpHFConverter::AppendPortion( const EditTextObject* pTextObj, sal_Unico
aNewData.maColor = aFont.GetColor();
if ( !aFontData.maColor.IsRGBEqual( aNewData.maColor ) )
{
- aParaText.append("&K").append(aNewData.maColor.AsRGBHexString());
+ aParaText.append("&K" + aNewData.maColor.AsRGBHexString());
}
// strikeout
diff --git a/sc/source/filter/html/htmlexp.cxx b/sc/source/filter/html/htmlexp.cxx
index 5d527f6ca167..ca93cdc02f34 100644
--- a/sc/source/filter/html/htmlexp.cxx
+++ b/sc/source/filter/html/htmlexp.cxx
@@ -490,7 +490,7 @@ OString ScHTMLExport::BorderToStyle(const char* pBorderName,
aOut.append("; ");
// which border
- aOut.append("border-").append(pBorderName).append(": ");
+ aOut.append(OString::Concat("border-") + pBorderName + ": ");
// thickness
int nWidth = pLine->GetWidth();
@@ -715,19 +715,18 @@ void ScHTMLExport::WriteTables()
// more <TABLE ...>
if ( bTabAlignedLeft )
{
- aByteStrOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align).
- append("=\"").
- append(OOO_STRING_SVTOOLS_HTML_AL_left).append('"');
+ aByteStrOut.append(" " OOO_STRING_SVTOOLS_HTML_O_align
+ "=\""
+ OOO_STRING_SVTOOLS_HTML_AL_left "\"");
}
// ALIGN=LEFT allow text and graphics to flow around
// CELLSPACING
- aByteStrOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_cellspacing).
- append("=\"").
+ aByteStrOut.append(" " OOO_STRING_SVTOOLS_HTML_O_cellspacing
+ "=\"").
append(static_cast<sal_Int32>(nCellSpacing)).append('"');
// BORDER=0, we do the styling of the cells in <TD>
- aByteStrOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_border).
- append("=\"0\"");
+ aByteStrOut.append(" " OOO_STRING_SVTOOLS_HTML_O_border "=\"0\"");
IncIndent(1); TAG_ON_LF( aByteStrOut.makeStringAndClear().getStr() );
// --- <COLGROUP> ----
@@ -877,8 +876,7 @@ void ScHTMLExport::WriteCell( sc::ColumnBlockPosition& rBlockPos, SCCOL nCol, SC
const SvxBoxItem* pBorder = pDoc->GetAttr( nCol, nRow, nTab, ATTR_BORDER );
if ( pBorder && (pBorder->GetTop() || pBorder->GetBottom() || pBorder->GetLeft() || pBorder->GetRight()) )
{
- aStrTD.append(' ').append(OOO_STRING_SVTOOLS_HTML_style).
- append("=\"");
+ aStrTD.append(" " OOO_STRING_SVTOOLS_HTML_style "=\"");
bool bInsertSemicolon = false;
aStrTD.append(BorderToStyle("top", pBorder->GetTop(),
@@ -937,8 +935,7 @@ void ScHTMLExport::WriteCell( sc::ColumnBlockPosition& rBlockPos, SCCOL nCol, SC
if ( bTableDataHeight )
{
- aStrTD.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_height).
- append("=\"").
+ aStrTD.append(" " OOO_STRING_SVTOOLS_HTML_O_height "=\"").
append(static_cast<sal_Int32>(nHeightPixel)).append('"');
}
@@ -1016,8 +1013,8 @@ void ScHTMLExport::WriteCell( sc::ColumnBlockPosition& rBlockPos, SCCOL nCol, SC
default: pChar = OOO_STRING_SVTOOLS_HTML_AL_left; break;
}
- aStrTD.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align).
- append("=\"").append(pChar).append('"');
+ aStrTD.append(" " OOO_STRING_SVTOOLS_HTML_O_align "=\"" +
+ OString::Concat(pChar) + "\"");
switch( rVerJustifyItem.GetValue() )
{
@@ -1093,8 +1090,7 @@ void ScHTMLExport::WriteCell( sc::ColumnBlockPosition& rBlockPos, SCCOL nCol, SC
OStringBuffer aStr(OOO_STRING_SVTOOLS_HTML_font);
if ( bSetFontName )
{
- aStr.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_face).
- append("=\"");
+ aStr.append(" " OOO_STRING_SVTOOLS_HTML_O_face "=\"");
if (!rFontItem.GetFamilyName().isEmpty())
{
diff --git a/sc/source/filter/oox/formulabase.cxx b/sc/source/filter/oox/formulabase.cxx
index f6553af07cd9..a6e058c5c453 100644
--- a/sc/source/filter/oox/formulabase.cxx
+++ b/sc/source/filter/oox/formulabase.cxx
@@ -1292,9 +1292,9 @@ bool OpCodeProviderImpl::initOpCode( sal_Int32& ornOpCode, const ApiTokenMap& rT
}
return true;
}
- OSL_FAIL( OStringBuffer( "OpCodeProviderImpl::initOpCode - opcode for \"" ).
- append( OUStringToOString( rOdfName, RTL_TEXTENCODING_ASCII_US ) ).
- append( "\" not found" ).getStr() );
+ OSL_FAIL( OStringBuffer( "OpCodeProviderImpl::initOpCode - opcode for \"" +
+ OUStringToOString( rOdfName, RTL_TEXTENCODING_ASCII_US ) +
+ "\" not found" ).getStr() );
return false;
}
diff --git a/sc/source/filter/oox/numberformatsbuffer.cxx b/sc/source/filter/oox/numberformatsbuffer.cxx
index 70146cd0747c..eaf960f9e9e2 100644
--- a/sc/source/filter/oox/numberformatsbuffer.cxx
+++ b/sc/source/filter/oox/numberformatsbuffer.cxx
@@ -2040,9 +2040,9 @@ void NumberFormatsBuffer::insertBuiltinFormats()
BuiltinVec aBuiltinVec;
BuiltinMap::const_iterator aMIt = aBuiltinMap.find( maLocaleStr ), aMEnd = aBuiltinMap.end();
OSL_ENSURE( aMIt != aMEnd,
- OStringBuffer( "NumberFormatsBuffer::insertBuiltinFormats - locale '" ).
- append( OUStringToOString( maLocaleStr, RTL_TEXTENCODING_ASCII_US ) ).
- append( "' not supported (#i29949#)" ).getStr() );
+ OStringBuffer( "NumberFormatsBuffer::insertBuiltinFormats - locale '" +
+ OUStringToOString( maLocaleStr, RTL_TEXTENCODING_ASCII_US ) +
+ "' not supported (#i29949#)" ).getStr() );
// start with default table, if no table has been found
if( aMIt == aMEnd )
aMIt = aBuiltinMap.find( "*" );
diff --git a/sc/source/filter/oox/querytablebuffer.cxx b/sc/source/filter/oox/querytablebuffer.cxx
index 0f561c5ab629..14974c30da71 100644
--- a/sc/source/filter/oox/querytablebuffer.cxx
+++ b/sc/source/filter/oox/querytablebuffer.cxx
@@ -69,7 +69,7 @@ void lclAppendWebQueryTableName( OUStringBuffer& rTables, std::u16string_view rT
{
if( !rTables.isEmpty() )
rTables.append( ';' );
- rTables.append( "HTML__" ).append( rTableName );
+ rTables.append( OUString::Concat("HTML__") + rTableName );
}
}
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index 168334f5cce9..3abf07641963 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -1455,7 +1455,7 @@ void ScInputHandler::ShowFuncList( const ::std::vector< OUString > & rFuncStrVec
{
if ( !ppFDesc->getFunctionName().isEmpty() )
{
- aTipStr.append(" : ").append(ppFDesc->getDescription());
+ aTipStr.append(" : " + ppFDesc->getDescription());
}
}
ShowTip( aTipStr.makeStringAndClear() );
diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx
index 55072f5d5f9c..4200457956fe 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -1349,7 +1349,7 @@ void ScCheckListMenuControl::getResult(ResultType& rResult)
std::unique_ptr<weld::TreeIter> xIter(mpChecks->make_iterator(maMembers[i].mxParent.get()));
do
{
- aLabel.append(";").append(mpChecks->get_text(*xIter));
+ aLabel.append(";" + mpChecks->get_text(*xIter));
}
while (mpChecks->iter_parent(*xIter));
}
diff --git a/sc/source/ui/condformat/condformathelper.cxx b/sc/source/ui/condformat/condformathelper.cxx
index 3ae4f301a1a5..b595b6f8d157 100644
--- a/sc/source/ui/condformat/condformathelper.cxx
+++ b/sc/source/ui/condformat/condformathelper.cxx
@@ -204,7 +204,7 @@ OUString ScCondFormatHelper::GetExpression( ScCondFormatEntryType eType, sal_Int
aBuffer.append(getExpression(nIndex));
if(nIndex <= 7 || nIndex >= 19)
{
- aBuffer.append(" ").append(aStr1);
+ aBuffer.append(OUString::Concat(" ") + aStr1);
if(nIndex == 6 || nIndex == 7)
{
aBuffer.append(" ");
@@ -216,7 +216,7 @@ OUString ScCondFormatHelper::GetExpression( ScCondFormatEntryType eType, sal_Int
}
else if(eType == FORMULA)
{
- aBuffer.append(" ").append(aStr1);
+ aBuffer.append(OUString::Concat(" ") + aStr1);
}
else if(eType == DATE)
{
diff --git a/sc/source/ui/dataprovider/datatransformation.cxx b/sc/source/ui/dataprovider/datatransformation.cxx
index 7a03f7ed3871..dfdc72375cb1 100644
--- a/sc/source/ui/dataprovider/datatransformation.cxx
+++ b/sc/source/ui/dataprovider/datatransformation.cxx
@@ -135,7 +135,7 @@ void MergeColumnTransformation::Transform(ScDocument& rDoc) const
{
if (itr != nTargetCol)
{
- aStr.append(maMergeString).append(rDoc.GetString(itr, nRow, 0));
+ aStr.append(maMergeString + rDoc.GetString(itr, nRow, 0));
}
}
rDoc.SetString(nTargetCol, nRow, 0, aStr.makeStringAndClear());
diff --git a/sc/source/ui/dbgui/asciiopt.cxx b/sc/source/ui/dbgui/asciiopt.cxx
index 5dcb1cbd251f..0d584b5291a6 100644
--- a/sc/source/ui/dbgui/asciiopt.cxx
+++ b/sc/source/ui/dbgui/asciiopt.cxx
@@ -228,17 +228,17 @@ OUString ScAsciiOptions::WriteToString() const
aOutStr.append(",")
//Token 5: Language
- .append(static_cast<sal_Int32>(static_cast<sal_uInt16>(eLang))).append(",")
+ .append(static_cast<sal_Int32>(static_cast<sal_uInt16>(eLang))).append("," +
//Token 6: Import quoted field as text.
- .append(OUString::boolean( bQuotedFieldAsText )).append(",")
+ OUString::boolean( bQuotedFieldAsText ) + "," +
//Token 7: Detect special numbers.
- .append(OUString::boolean( bDetectSpecialNumber )).append(",")
+ OUString::boolean( bDetectSpecialNumber ) + "," +
// Token 8: used for "Save as shown" in export options
- .append(OUString::boolean( bSaveAsShown )).append(",")
+ OUString::boolean( bSaveAsShown ) +"," +
// Token 9: used for "Save cell formulas" in export options
- .append(OUString::boolean( bSaveFormulas )).append(",")
+ OUString::boolean( bSaveFormulas ) + "," +
//Token 10: Trim Space
- .append(OUString::boolean( bRemoveSpace ));
+ OUString::boolean( bRemoveSpace ));
return aOutStr.makeStringAndClear();
}
diff --git a/sc/source/ui/optdlg/tpusrlst.cxx b/sc/source/ui/optdlg/tpusrlst.cxx
index 0dc4692645d9..c7bcf1c8b893 100644
--- a/sc/source/ui/optdlg/tpusrlst.cxx
+++ b/sc/source/ui/optdlg/tpusrlst.cxx
@@ -363,7 +363,7 @@ void ScTpUserLists::CopyListFromArea( const ScRefAddress& rStartPos,
if ( !aStrField.isEmpty() )
{
- aStrList.append(aStrField).append("\n");
+ aStrList.append(aStrField + "\n");
}
}
else
@@ -386,7 +386,7 @@ void ScTpUserLists::CopyListFromArea( const ScRefAddress& rStartPos,
if ( !aStrField.isEmpty() )
{
- aStrList.append(aStrField).append("\n");
+ aStrList.append(aStrField + "\n");
}
}
else
diff --git a/sc/source/ui/unoobj/PivotTableDataProvider.cxx b/sc/source/ui/unoobj/PivotTableDataProvider.cxx
index 03e53c640718..9d167d862e0e 100644
--- a/sc/source/ui/unoobj/PivotTableDataProvider.cxx
+++ b/sc/source/ui/unoobj/PivotTableDataProvider.cxx
@@ -615,7 +615,7 @@ PivotTableDataProvider::assignLabelsToDataSequence(size_t nIndex)
}
else
{
- aLabel.append(" - ").append(rItem.m_aString);
+ aLabel.append(" - " + rItem.m_aString);
}
}
}
diff --git a/sc/source/ui/vba/vbahyperlink.cxx b/sc/source/ui/vba/vbahyperlink.cxx
index 9b5140cd0fb1..2bd35542130b 100644
--- a/sc/source/ui/vba/vbahyperlink.cxx
+++ b/sc/source/ui/vba/vbahyperlink.cxx
@@ -78,7 +78,7 @@ ScVbaHyperlink::ScVbaHyperlink( const uno::Reference< XHelperInterface >& rxAnch
{
OUStringBuffer aBuffer( aUrlComp.first );
if( !aUrlComp.second.isEmpty() )
- aBuffer.append( " - " ).append( aUrlComp.second );
+ aBuffer.append( " - " + aUrlComp.second );
aTextToDisplay = aBuffer.makeStringAndClear();
}
}
diff --git a/sc/source/ui/vba/vbanames.cxx b/sc/source/ui/vba/vbanames.cxx
index 7c145f83bda8..8eba8097b236 100644
--- a/sc/source/ui/vba/vbanames.cxx
+++ b/sc/source/ui/vba/vbanames.cxx
@@ -211,7 +211,7 @@ ScVbaNames::Add( const css::uno::Any& Name ,
OUString sRangeAdd = xArea->Address( aAny2, aAny2 , aAny2 , aAny2, aAny2 );
if ( nArea > 1 )
sTmp.append(",");
- sTmp.append("'").append(xRange->getWorksheet()->getName()).append("'.").append(sRangeAdd);
+ sTmp.append("'" + xRange->getWorksheet()->getName() + "'." + sRangeAdd);
}
mxNames->addNewByName( sName, sTmp.makeStringAndClear(), aCellAddr, 0/*nUnoType*/);
return Item( uno::makeAny( sName ), uno::Any() );
diff --git a/sc/source/ui/view/tabview.cxx b/sc/source/ui/view/tabview.cxx
index f4581d394dd0..b727d817e185 100644
--- a/sc/source/ui/view/tabview.cxx
+++ b/sc/source/ui/view/tabview.cxx
@@ -2411,11 +2411,11 @@ void lcl_createGroupsData(
bool bGroupHidden = pEntry->IsHidden();
rGroupsBuffer
- .append("{ \"level\": ").append(sal_Int32(nLevel + 1)).append(", ")
- .append("\"index\": ").append(sal_Int32(nIndex)).append(", ")
- .append("\"startPos\": ").append(rGroupStartPositions[nLevel]).append(", ")
- .append("\"endPos\": ").append(nTotalPx).append(", ")
- .append("\"hidden\": ").append(sal_Int32(bGroupHidden ? 1 : 0)).append(" }");
+ .append("{ \"level\": ").append(sal_Int32(nLevel + 1)).append(", "
+ "\"index\": ").append(sal_Int32(nIndex)).append(", "
+ "\"startPos\": ").append(rGroupStartPositions[nLevel]).append(", "
+ "\"endPos\": ").append(nTotalPx).append(", "
+ "\"hidden\": ").append(sal_Int32(bGroupHidden ? 1 : 0)).append(" }");
// look for the next visible group control at level nLevel
bool bFound = false;
diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx
index 13ec3572b701..afed524c0452 100644
--- a/sd/source/filter/eppt/pptx-epptooxml.cxx
+++ b/sd/source/filter/eppt/pptx-epptooxml.cxx
@@ -1746,20 +1746,12 @@ void PowerPointExport::WriteDefaultColorSchemes(const FSHelperPtr& pFS)
break;
}
- OUString sOpenColorScheme = OUStringBuffer()
- .append("<a:")
- .append(sName)
- .append(">")
- .makeStringAndClear();
+ OUString sOpenColorScheme = "<a:" + sName + ">";
pFS->write(sOpenColorScheme);
pFS->singleElementNS(XML_a, XML_srgbClr, XML_val, I32SHEX(nColor));
- OUString sCloseColorScheme = OUStringBuffer()
- .append("</a:")
- .append(sName)
- .append(">")
- .makeStringAndClear();
+ OUString sCloseColorScheme = "</a:" + sName + ">";
pFS->write(sCloseColorScheme);
}
}
@@ -1799,20 +1791,12 @@ bool PowerPointExport::WriteColorSchemes(const FSHelperPtr& pFS, const OUString&
}
}
- OUString sOpenColorScheme = OUStringBuffer()
- .append("<a:")
- .append(sName)
- .append(">")
- .makeStringAndClear();
+ OUString sOpenColorScheme ="<a:" + sName + ">";
pFS->write(sOpenColorScheme);
pFS->singleElementNS(XML_a, XML_srgbClr, XML_val, I32SHEX(nColor));
- OUString sCloseColorScheme = OUStringBuffer()
- .append("</a:")
- .append(sName)
- .append(">")
- .makeStringAndClear();
+ OUString sCloseColorScheme = "</a:" + sName + ">";
pFS->write(sCloseColorScheme);
}
diff --git a/sd/source/filter/html/htmlex.cxx b/sd/source/filter/html/htmlex.cxx
index e9aba13346e3..78914a0adf14 100644
--- a/sd/source/filter/html/htmlex.cxx
+++ b/sd/source/filter/html/htmlex.cxx
@@ -325,9 +325,9 @@ OUString getParagraphStyle( SdrOutliner* pOutliner, sal_Int32 nPara )
void lclAppendStyle(OUStringBuffer& aBuffer, std::u16string_view aTag, std::u16string_view aStyle)
{
if (aStyle.empty())
- aBuffer.append("<").append(aTag).append(">");
+ aBuffer.append(OUString::Concat("<") + aTag + ">");
else
- aBuffer.append("<").append(aTag).append(" style=\"").append(aStyle).append("\">");
+ aBuffer.append(OUString::Concat("<") + aTag + " style=\"" + aStyle + "\">");
}
} // anonymous namespace
@@ -1334,7 +1334,7 @@ void HtmlExport::WriteOutlinerParagraph(OUStringBuffer& aStr, SdrOutliner* pOutl
lclAppendStyle(aStr, aTag, getParagraphStyle(pOutliner, nIndex));
aStr.append(aParaText);
- aStr.append("</").append(aTag).append(">\r\n");
+ aStr.append("</" + aTag + ">\r\n");
}
else
{
@@ -1578,7 +1578,7 @@ bool HtmlExport::CreateHtmlForPresPages()
// HTML Head
OUStringBuffer aStr(gaHTMLHeader);
aStr.append(CreateMetaCharset());
- aStr.append(" <title>" ).append( StringToHTMLString(maPageNames[nSdPage]) ).append("</title>\r\n");
+ aStr.append(" <title>" + StringToHTMLString(maPageNames[nSdPage]) + "</title>\r\n");
// insert timing information
pPage = maPages[ nSdPage ];
@@ -2793,7 +2793,7 @@ OUString HtmlExport::CreateHTMLPolygonArea( const ::basegfx::B2DPolyPolygon& rPo
if (nPoint < nNoOfPoints - 1)
aStr.append(',');
}
- aStr.append("\" href=\"").append(rHRef).append("\">\n");
+ aStr.append(OUString::Concat("\" href=\"") + rHRef + "\">\n");
}
return aStr.makeStringAndClear();
diff --git a/sd/source/ui/remotecontrol/Communicator.cxx b/sd/source/ui/remotecontrol/Communicator.cxx
index a500d9191131..de55f38f8514 100644
--- a/sd/source/ui/remotecontrol/Communicator.cxx
+++ b/sd/source/ui/remotecontrol/Communicator.cxx
@@ -82,13 +82,12 @@ void Communicator::execute()
Transmitter::PRIORITY_HIGH );
}
- OStringBuffer aBuffer;
- aBuffer
- .append( "slideshow_info\n" )
- .append( OUStringToOString( ::comphelper::DocumentInfo::getDocumentTitle( xFrame->getController()->getModel() ), RTL_TEXTENCODING_UTF8 ) )
- .append("\n\n");
+ OString aBuffer =
+ "slideshow_info\n" +
+ OUStringToOString( ::comphelper::DocumentInfo::getDocumentTitle( xFrame->getController()->getModel() ), RTL_TEXTENCODING_UTF8 ) +
+ "\n\n";
- pTransmitter->addMessage( aBuffer.makeStringAndClear(), Transmitter::PRIORITY_LOW );
+ pTransmitter->addMessage( aBuffer.getStr(), Transmitter::PRIORITY_LOW );
}
catch (uno::RuntimeException &)
{
diff --git a/sd/source/ui/remotecontrol/DiscoveryService.cxx b/sd/source/ui/remotecontrol/DiscoveryService.cxx
index 90f88a6c5374..9ed2ae727761 100644
--- a/sd/source/ui/remotecontrol/DiscoveryService.cxx
+++ b/sd/source/ui/remotecontrol/DiscoveryService.cxx
@@ -164,10 +164,9 @@ void SAL_CALL DiscoveryService::run()
OString aString( aBuffer, strlen( "LOREMOTE_SEARCH" ) );
if ( aString == "LOREMOTE_SEARCH" )
{
- OStringBuffer aStringBuffer("LOREMOTE_ADVERTISE\n");
- aStringBuffer.append( OUStringToOString(
- osl::SocketAddr::getLocalHostname(), RTL_TEXTENCODING_UTF8 ) )
- .append( "\n\n" );
+ OString aStringBuffer = "LOREMOTE_ADVERTISE\n" +
+ OUStringToOString(osl::SocketAddr::getLocalHostname(), RTL_TEXTENCODING_UTF8 ) +
+ "\n\n";
if ( sendto( mSocket, aStringBuffer.getStr(),
aStringBuffer.getLength(), 0, reinterpret_cast<sockaddr*>(&aAddr),
sizeof(aAddr) ) <= 0 )
diff --git a/sfx2/source/appl/newhelp.cxx b/sfx2/source/appl/newhelp.cxx
index 4657c87f89c9..102738a8705e 100644
--- a/sfx2/source/appl/newhelp.cxx
+++ b/sfx2/source/appl/newhelp.cxx
@@ -945,10 +945,11 @@ SearchTabPage_Impl::~SearchTabPage_Impl()
for ( sal_Int32 i = 0; i < nCount; ++i )
{
- aUserData.append(";").append(INetURLObject::encode(
- m_xSearchED->get_text(i),
- INetURLObject::PART_UNO_PARAM_VALUE,
- INetURLObject::EncodeMechanism::All ));
+ aUserData.append(";" +
+ INetURLObject::encode(
+ m_xSearchED->get_text(i),
+ INetURLObject::PART_UNO_PARAM_VALUE,
+ INetURLObject::EncodeMechanism::All ));
}
Any aUserItem = makeAny( aUserData.makeStringAndClear() );
diff --git a/sfx2/source/bastyp/frmhtmlw.cxx b/sfx2/source/bastyp/frmhtmlw.cxx
index 4c8b237bb90a..1b83c2be8b1e 100644
--- a/sfx2/source/bastyp/frmhtmlw.cxx
+++ b/sfx2/source/bastyp/frmhtmlw.cxx
@@ -61,13 +61,13 @@ void SfxFrameHTMLWriter::OutMeta( SvStream& rStrm,
rStrm.WriteCharPtr( pIndent );
OStringBuffer sOut;
- sOut.append('<').append(OOO_STRING_SVTOOLS_HTML_meta).append(' ')
+ sOut.append("<" OOO_STRING_SVTOOLS_HTML_meta " ")
.append(bHTTPEquiv ? OOO_STRING_SVTOOLS_HTML_O_httpequiv : OOO_STRING_SVTOOLS_HTML_O_name).append("=\"");
rStrm.WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rStrm, rName, eDestEnc, pNonConvertableChars );
- sOut.append("\" ").append(OOO_STRING_SVTOOLS_HTML_O_content).append("=\"");
+ sOut.append("\" " OOO_STRING_SVTOOLS_HTML_O_content "=\"");
rStrm.WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rStrm, rContent, eDestEnc, pNonConvertableChars ).WriteCharPtr( "\"/>" );
@@ -239,8 +239,7 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor(
{
aURL = URIHelper::simpleNormalizedMakeRelative(
rBaseURL, aURL );
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_src)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_src "=\"");
rOut.WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rOut, aURL, eDestEnc, pNonConvertableChars );
sOut.append('\"');
@@ -250,8 +249,7 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor(
aAny = xSet->getPropertyValue("FrameName");
if ( (aAny >>= aStr) && !aStr.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_name)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_name "=\"");
rOut.WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rOut, aStr, eDestEnc, pNonConvertableChars );
sOut.append('\"');
@@ -279,8 +277,8 @@ void SfxFrameHTMLWriter::Out_FrameDescriptor(
if ( aAny >>= bVal )
{
const char *pStr = bVal ? sHTML_SC_yes : sHTML_SC_no;
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_scrolling)
- .append(pStr);
+ sOut.append(OString::Concat(" " OOO_STRING_SVTOOLS_HTML_O_scrolling) +
+ pStr);
}
}
diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx
index fbecef81125e..830df11c319b 100644
--- a/sfx2/source/control/unoctitm.cxx
+++ b/sfx2/source/control/unoctitm.cxx
@@ -538,8 +538,7 @@ void UsageInfo::save()
OStringBuffer aUsageInfoMsg("Document Type;Command;Count");
for (auto const& elem : maUsage)
- aUsageInfoMsg.append("\n").append(elem.first.toUtf8())
- .append(";").append(static_cast<sal_Int32>(elem.second));
+ aUsageInfoMsg.append("\n" + elem.first.toUtf8() + ";").append(static_cast<sal_Int32>(elem.second));
sal_uInt64 written = 0;
auto s = aUsageInfoMsg.makeStringAndClear();
@@ -1309,7 +1308,7 @@ static void InterceptLOKStateChangeEvent(sal_uInt16 nSID, SfxViewFrame* pViewFra
aBuffer.append(u'{');
for (sal_Int32 itSeq = 0; itSeq < aSeq.getLength(); itSeq++)
{
- aBuffer.append("\"").append(aSeq[itSeq]);
+ aBuffer.append("\"" + aSeq[itSeq]);
if (itSeq != aSeq.getLength() - 1)
aBuffer.append("\":true,");
else
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index efc99c1af294..54ae8fc0e2db 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -1777,7 +1777,7 @@ void SfxCommonTemplateDialog_Impl::DeleteHdl()
const SfxStyleFamilyItem* pItem = GetFamilyItem_Impl();
OUStringBuffer aMsg;
- aMsg.append(SfxResId(STR_DELETE_STYLE_USED)).append(SfxResId(STR_DELETE_STYLE));
+ aMsg.append(SfxResId(STR_DELETE_STYLE_USED) + SfxResId(STR_DELETE_STYLE));
pTreeView->selected_foreach([this, pTreeView, pItem, &aList, &bUsedStyle, &aMsg](weld::TreeIter& rEntry){
aList.emplace_back(pTreeView->make_iterator(&rEntry));
diff --git a/sfx2/source/view/lokhelper.cxx b/sfx2/source/view/lokhelper.cxx
index a19498de467d..d334177d71e6 100644
--- a/sfx2/source/view/lokhelper.cxx
+++ b/sfx2/source/view/lokhelper.cxx
@@ -477,14 +477,14 @@ void SfxLokHelper::notifyWindow(const SfxViewShell* pThisView,
OStringBuffer aPayload;
aPayload.append("{ \"id\": \"").append(static_cast<sal_Int64>(nLOKWindowId)).append('"');
- aPayload.append(", \"action\": \"").append(OUStringToOString(rAction, RTL_TEXTENCODING_UTF8)).append('"');
+ aPayload.append(", \"action\": \"" + OUStringToOString(rAction, RTL_TEXTENCODING_UTF8) + "\"");
for (const auto& rItem: rPayload)
{
if (!rItem.first.isEmpty() && !rItem.second.isEmpty())
{
- aPayload.append(", \"").append(rItem.first).append("\": \"")
- .append(rItem.second).append('"');
+ aPayload.append(", \"" + rItem.first + "\": \"" +
+ rItem.second).append('"');
}
}
aPayload.append('}');
diff --git a/starmath/source/mathtype.cxx b/starmath/source/mathtype.cxx
index 6a3147d2f817..cb46776cc618 100644
--- a/starmath/source/mathtype.cxx
+++ b/starmath/source/mathtype.cxx
@@ -316,7 +316,7 @@ bool MathType::LookupChar(sal_Unicode nChar,OUStringBuffer &rRet,sal_uInt8 nVers
break;
case 0x2208: // in
case 0x2209: // notin
- rRet.append(" func ").append(OUStringChar(nChar)).append(" ");
+ rRet.append(" func " + OUStringChar(nChar) + " ");
break;
case 0x220d: // owns
rRet.append(u" func \u220b ");
@@ -432,7 +432,7 @@ bool MathType::LookupChar(sal_Unicode nChar,OUStringBuffer &rRet,sal_uInt8 nVers
case 0x2289: // nsupseteq
case 0x22b2: // NORMAL SUBGROUP OF
case 0x22b3: // CONTAINS AS NORMAL SUBGROUP
- rRet.append(" func ").append(OUStringChar(nChar)).append(" ");
+ rRet.append(" func " + OUStringChar(nChar) + " ");
break;
case 0x22a5:
pC = " ortho ";
@@ -1438,7 +1438,7 @@ bool MathType::HandleRecords(int nLevel, sal_uInt8 nSelector,
else if (nPart == 1)
{
rRet.insert(0, sPush);
- rRet.append(" over ").append(sMainTerm);
+ rRet.append(" over " + sMainTerm);
sPush.clear();
sMainTerm.clear();
}
@@ -2891,7 +2891,7 @@ bool MathType::HandleChar(sal_Int32 &rTextStart, int &rSetSize, int nLevel,
aStr.clear();
TypeFaceToString(aStr,nTypeFace);
- rRet.append(aStr).append("{");
+ rRet.append(aStr + "{");
}
else
rRet.append(" {");
@@ -2935,7 +2935,7 @@ bool MathType::HandleChar(sal_Int32 &rTextStart, int &rSetSize, int nLevel,
if ((xfEMBELL(nTag)) && (!bSilent))
{
- rRet.append("}}").append(sPost); // #i24340# make what would be "vec {A}_n" become "{vec {A}}_n"
+ rRet.append("}}" + sPost); // #i24340# make what would be "vec {A}_n" become "{vec {A}}_n"
rTextStart = rRet.getLength();
}
return bRet;
diff --git a/svl/source/misc/urihelper.cxx b/svl/source/misc/urihelper.cxx
index 43a4cd500e1b..f5ac858474c2 100644
--- a/svl/source/misc/urihelper.cxx
+++ b/svl/source/misc/urihelper.cxx
@@ -786,16 +786,16 @@ OUString URIHelper::resolveIdnaHost(OUString const & url) {
return url;
}
OUStringBuffer buf(uri->getScheme());
- buf.append("://").append(auth.subView(0, hostStart));
+ buf.append(OUString::Concat("://") + auth.subView(0, hostStart));
buf.append(
reinterpret_cast<sal_Unicode const *>(ascii.getBuffer()),
ascii.length());
- buf.append(auth.subView(hostEnd)).append(uri->getPath());
+ buf.append(auth.subView(hostEnd) + uri->getPath());
if (uri->hasQuery()) {
- buf.append('?').append(uri->getQuery());
+ buf.append("?" + uri->getQuery());
}
if (uri->hasFragment()) {
- buf.append('#').append(uri->getFragment());
+ buf.append("#" + uri->getFragment());
}
return buf.makeStringAndClear();
}
diff --git a/svl/source/numbers/zforlist.cxx b/svl/source/numbers/zforlist.cxx
index 85ee27638587..a3207d20831b 100644
--- a/svl/source/numbers/zforlist.cxx
+++ b/svl/source/numbers/zforlist.cxx
@@ -4335,7 +4335,7 @@ OUString NfCurrencyEntry::BuildSymbolString(bool bBank,
if ( aSymbol.indexOf( '-' ) >= 0 ||
aSymbol.indexOf( ']' ) >= 0)
{
- aBuf.append('"').append(aSymbol).append('"');
+ aBuf.append("\"" + aSymbol + "\"");
}
else
{
@@ -4355,7 +4355,7 @@ OUString NfCurrencyEntry::Impl_BuildFormatStringNumChars( const LocaleDataWrappe
sal_uInt16 nDecimalFormat) const
{
OUStringBuffer aBuf;
- aBuf.append('#').append(rLoc.getNumThousandSep()).append("##0");
+ aBuf.append("#" + rLoc.getNumThousandSep() + "##0");
if (nDecimalFormat && nDigits)
{
aBuf.append(rLoc.getNumDecimalSep());
diff --git a/svl/source/numbers/zformat.cxx b/svl/source/numbers/zformat.cxx
index ade0dac4768f..de73817ff474 100644
--- a/svl/source/numbers/zformat.cxx
+++ b/svl/source/numbers/zformat.cxx
@@ -5136,7 +5136,7 @@ OUString SvNumberformat::GetMappedFormatstring( const NfKeywordTable& rKeywords,
// lcl_insertLCID() below, in practice as long as it is used for system
// time and date modifiers it shouldn't (i.e. there is no calendar or
// numeral specified as well).
- aStr.append("[$-").append( maLocale.generateCode()).append(']');
+ aStr.append("[$-" + maLocale.generateCode() + "]");
}
bool bDefault[4];
// 1 subformat matches all if no condition specified,
diff --git a/svtools/source/svhtml/htmlout.cxx b/svtools/source/svhtml/htmlout.cxx
index 48beab0039cd..c75d293b6f77 100644
--- a/svtools/source/svhtml/htmlout.cxx
+++ b/svtools/source/svhtml/htmlout.cxx
@@ -625,11 +625,11 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream,
return rStream;
OStringBuffer sOut;
- sOut.append('<')
- .append(OOO_STRING_SVTOOLS_HTML_map)
- .append(' ')
- .append(OOO_STRING_SVTOOLS_HTML_O_name)
- .append("=\"");
+ sOut.append(OString::Concat("<") +
+ OOO_STRING_SVTOOLS_HTML_map
+ " "
+ OOO_STRING_SVTOOLS_HTML_O_name
+ "=\"");
rStream.WriteOString( sOut.makeStringAndClear() );
Out_String( rStream, rOutName, eDestEnc, pNonConvertableChars );
rStream.WriteCharPtr( "\">" );
@@ -718,11 +718,11 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream,
if( pIndentArea )
rStream.WriteCharPtr( pIndentArea );
- sOut.append('<').append(OOO_STRING_SVTOOLS_HTML_area)
- .append(' ').append(OOO_STRING_SVTOOLS_HTML_O_shape)
- .append('=').append(pShape).append(' ')
- .append(OOO_STRING_SVTOOLS_HTML_O_coords).append("=\"")
- .append(aCoords).append("\" ");
+ sOut.append(OString::Concat("<") + OOO_STRING_SVTOOLS_HTML_area
+ " " OOO_STRING_SVTOOLS_HTML_O_shape
+ "=" + pShape + " "
+ OOO_STRING_SVTOOLS_HTML_O_coords "=\"" +
+ aCoords + "\" ");
rStream.WriteOString( sOut.makeStringAndClear() );
OUString aURL( pObj->GetURL() );
@@ -730,7 +730,7 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream,
{
aURL = URIHelper::simpleNormalizedMakeRelative(
rBaseURL, aURL );
- sOut.append(OOO_STRING_SVTOOLS_HTML_O_href).append("=\"");
+ sOut.append(OOO_STRING_SVTOOLS_HTML_O_href "=\"");
rStream.WriteOString( sOut.makeStringAndClear() );
Out_String( rStream, aURL, eDestEnc, pNonConvertableChars ).WriteChar( '\"' );
}
@@ -740,8 +740,7 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream,
const OUString& rObjName = pObj->GetName();
if( !rObjName.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_name)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_name "=\"");
rStream.WriteOString( sOut.makeStringAndClear() );
Out_String( rStream, rObjName, eDestEnc, pNonConvertableChars ).WriteChar( '\"' );
}
@@ -749,8 +748,7 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream,
const OUString& rTarget = pObj->GetTarget();
if( !rTarget.isEmpty() && pObj->IsActive() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_target)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_target "=\"");
rStream.WriteOString( sOut.makeStringAndClear() );
Out_String( rStream, rTarget, eDestEnc, pNonConvertableChars ).WriteChar( '\"' );
}
@@ -761,8 +759,7 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream,
if( !rDesc.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_alt)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_alt "=\"");
rStream.WriteOString( sOut.makeStringAndClear() );
Out_String( rStream, rDesc, eDestEnc, pNonConvertableChars ).WriteChar( '\"' );
}
@@ -808,9 +805,7 @@ SvStream& HTMLOutFuncs::OutScript( SvStream& rStrm,
if( !rLanguage.isEmpty() )
{
- sOut.append(' ')
- .append(OOO_STRING_SVTOOLS_HTML_O_language)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_language "=\"");
rStrm.WriteOString( sOut.makeStringAndClear() );
Out_String( rStrm, rLanguage, eDestEnc, pNonConvertableChars );
sOut.append('\"');
@@ -818,7 +813,7 @@ SvStream& HTMLOutFuncs::OutScript( SvStream& rStrm,
if( !rSrc.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_src).append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_src "=\"");
rStrm.WriteOString( sOut.makeStringAndClear() );
Out_String( rStrm, URIHelper::simpleNormalizedMakeRelative(rBaseURL, rSrc), eDestEnc, pNonConvertableChars );
sOut.append('\"');
@@ -826,8 +821,7 @@ SvStream& HTMLOutFuncs::OutScript( SvStream& rStrm,
if( STARBASIC != eScriptType && pSBLibrary )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_sdlibrary)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_sdlibrary "=\"");
rStrm.WriteOString( sOut.makeStringAndClear() );
Out_String( rStrm, *pSBLibrary, eDestEnc, pNonConvertableChars );
sOut.append('\"');
@@ -835,8 +829,7 @@ SvStream& HTMLOutFuncs::OutScript( SvStream& rStrm,
if( STARBASIC != eScriptType && pSBModule )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_sdmodule)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_sdmodule "=\"");
rStrm.WriteOString( sOut.makeStringAndClear() );
Out_String( rStrm, *pSBModule, eDestEnc, pNonConvertableChars );
sOut.append('\"');
@@ -860,19 +853,15 @@ SvStream& HTMLOutFuncs::OutScript( SvStream& rStrm,
{
if( pSBLibrary )
{
- sOut.append("' ")
- .append(OOO_STRING_SVTOOLS_HTML_SB_library)
- .append(' ')
- .append(OUStringToOString(*pSBLibrary, eDestEnc));
+ sOut.append("' " OOO_STRING_SVTOOLS_HTML_SB_library " " +
+ OUStringToOString(*pSBLibrary, eDestEnc));
rStrm.WriteOString( sOut.makeStringAndClear() ).WriteCharPtr( SAL_NEWLINE_STRING );
}
if( pSBModule )
{
- sOut.append("' ")
- .append(OOO_STRING_SVTOOLS_HTML_SB_module)
- .append(' ')
- .append(OUStringToOString(*pSBModule, eDestEnc));
+ sOut.append("' " OOO_STRING_SVTOOLS_HTML_SB_module " " +
+ OUStringToOString(*pSBModule, eDestEnc));
rStrm.WriteOString( sOut.makeStringAndClear() ).WriteCharPtr( SAL_NEWLINE_STRING );
}
}
@@ -948,16 +937,12 @@ OString HTMLOutFuncs::CreateTableDataOptionsValNum(
OUString aValStr;
rFormatter.GetInputLineString( fVal, 0, aValStr );
OString sTmp(OUStringToOString(aValStr, eDestEnc));
- aStrTD.append(' ').
- append(OOO_STRING_SVTOOLS_HTML_O_SDval).
- append("=\"").
- append(sTmp).append('\"');
+ aStrTD.append(" " OOO_STRING_SVTOOLS_HTML_O_SDval "=\"" +
+ sTmp + "\"");
}
if ( bValue || nFormat )
{
- aStrTD.append(' ').
- append(OOO_STRING_SVTOOLS_HTML_O_SDnum).
- append("=\"").
+ aStrTD.append(" " OOO_STRING_SVTOOLS_HTML_O_SDnum "=\"").
append(static_cast<sal_Int32>(static_cast<sal_uInt16>(
Application::GetSettings().GetLanguageTag().getLanguageType()))).
append(';'); // Language for Format 0
diff --git a/sw/source/core/edit/editsh.cxx b/sw/source/core/edit/editsh.cxx
index 60a0b7eea389..9be63fb05251 100644
--- a/sw/source/core/edit/editsh.cxx
+++ b/sw/source/core/edit/editsh.cxx
@@ -576,7 +576,7 @@ OUString SwEditShell::Calculate()
pStart->nContent.GetIndex() );
bValidFields = true;
}
- aFormel.append("(").append(aCalc.GetStrResult( aCalc.VarLook( sVar )->nValue )).append(")");
+ aFormel.append("(" + aCalc.GetStrResult( aCalc.VarLook( sVar )->nValue ) + ")");
}
else
aFormel.append(sVar);
diff --git a/sw/source/core/fields/cellfml.cxx b/sw/source/core/fields/cellfml.cxx
index 17c5dbf1d070..0ed5d21c293d 100644
--- a/sw/source/core/fields/cellfml.cxx
+++ b/sw/source/core/fields/cellfml.cxx
@@ -1115,17 +1115,17 @@ void SwTableFormula::SplitMergeBoxNm_( const SwTable& rTable, OUStringBuffer& rN
if( pFnd == rTableUpd.m_aData.pDelTable )
{
if( rTableUpd.m_pTable != &rTable ) // not the current one
- rNewStr.append(rTableUpd.m_pTable->GetFrameFormat()->GetName()).append("."); // set new table name
+ rNewStr.append(rTableUpd.m_pTable->GetFrameFormat()->GetName() + "."); // set new table name
rTableUpd.m_bModified = true;
}
else if( pFnd != rTableUpd.m_pTable ||
( rTableUpd.m_pTable != &rTable && &rTable != rTableUpd.m_aData.pDelTable))
- rNewStr.append(sTableNm).append("."); // keep table name
+ rNewStr.append(sTableNm + "."); // keep table name
else
rTableUpd.m_bModified = true;
}
else
- rNewStr.append(sTableNm).append("."); // keep table name
+ rNewStr.append(sTableNm + "."); // keep table name
}
}
if( pTableNmBox == pLastBox )
@@ -1207,18 +1207,18 @@ void SwTableFormula::SplitMergeBoxNm_( const SwTable& rTable, OUStringBuffer& rN
if( !bInNewTable )
{
rTableUpd.m_bModified = true;
- rNewStr.append(rTableUpd.m_pTable->GetFrameFormat()->GetName()).append(".");
+ rNewStr.append(rTableUpd.m_pTable->GetFrameFormat()->GetName() + ".");
}
else if( !sTableNm.isEmpty() )
- rNewStr.append(sTableNm).append(".");
+ rNewStr.append(sTableNm + ".");
}
else if( bInNewTable )
{
rTableUpd.m_bModified = true;
- rNewStr.append(*rTableUpd.m_aData.pNewTableNm).append(".");
+ rNewStr.append(*rTableUpd.m_aData.pNewTableNm + ".");
}
else if( !sTableNm.isEmpty() )
- rNewStr.append(sTableNm).append(".");
+ rNewStr.append(sTableNm + ".");
}
if( pLastBox )
diff --git a/sw/source/filter/html/htmldrawwriter.cxx b/sw/source/filter/html/htmldrawwriter.cxx
index 504bf766f78c..f9ac9a39542c 100644
--- a/sw/source/filter/html/htmldrawwriter.cxx
+++ b/sw/source/filter/html/htmldrawwriter.cxx
@@ -152,8 +152,8 @@ Writer& OutHTML_DrawFrameFormatAsMarquee( Writer& rWrt,
if( pStr )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_behavior).
- append("=\"").append(pStr).append("\"");
+ sOut.append(OString::Concat(" " OOO_STRING_SVTOOLS_HTML_O_behavior "=\"") +
+ pStr + "\"");
}
// DIRECTION
@@ -169,21 +169,21 @@ Writer& OutHTML_DrawFrameFormatAsMarquee( Writer& rWrt,
if( pStr )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_direction).
- append("=\"").append(pStr).append("\"");
+ sOut.append(OString::Concat(" " OOO_STRING_SVTOOLS_HTML_O_direction
+ "=\"") + pStr + "\"");
}
// LOOP
sal_Int32 nCount = rItemSet.Get( SDRATTR_TEXT_ANICOUNT ).GetValue();
if( 0==nCount )
nCount = SdrTextAniKind::Slide==eAniKind ? 1 : -1;
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_loop).append("=\"").
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_loop "=\"").
append(nCount).append("\"");
// SCROLLDELAY
sal_uInt16 nDelay = rItemSet.Get( SDRATTR_TEXT_ANIDELAY ).GetValue();
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_scrolldelay).
- append("=\"").append(static_cast<sal_Int32>(nDelay)).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_scrolldelay
+ "=\"").append(static_cast<sal_Int32>(nDelay)).append("\"");
// SCROLLAMOUNT
sal_Int16 nAmount = rItemSet.Get( SDRATTR_TEXT_ANIAMOUNT ).GetValue();
@@ -199,8 +199,8 @@ Writer& OutHTML_DrawFrameFormatAsMarquee( Writer& rWrt,
}
if( nAmount )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_scrollamount).
- append("=\"").append(static_cast<sal_Int32>(nAmount)).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_scrollamount
+ "=\"").append(static_cast<sal_Int32>(nAmount)).append("\"");
}
Size aTwipSz( pTextObj->GetLogicRect().GetSize() );
@@ -230,14 +230,14 @@ Writer& OutHTML_DrawFrameFormatAsMarquee( Writer& rWrt,
if( aPixelSz.Width() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_width).
- append("=\"").append(static_cast<sal_Int32>(aPixelSz.Width())).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_width
+ "=\"").append(static_cast<sal_Int32>(aPixelSz.Width())).append("\"");
}
if( aPixelSz.Height() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_height).
- append("=\"").append(static_cast<sal_Int32>(aPixelSz.Height())).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_height
+ "=\"").append(static_cast<sal_Int32>(aPixelSz.Height())).append("\"");
}
}
@@ -249,7 +249,7 @@ Writer& OutHTML_DrawFrameFormatAsMarquee( Writer& rWrt,
const Color& rFillColor =
rItemSet.Get(XATTR_FILLCOLOR).GetColorValue();
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_bgcolor).append("=");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_bgcolor "=");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_Color( rWrt.Strm(), rFillColor );
}
diff --git a/sw/source/filter/html/htmlfldw.cxx b/sw/source/filter/html/htmlfldw.cxx
index dac2ffc2108b..a8c15702686c 100644
--- a/sw/source/filter/html/htmlfldw.cxx
+++ b/sw/source/filter/html/htmlfldw.cxx
@@ -284,16 +284,14 @@ static Writer& OutHTML_SwField( Writer& rWrt, const SwField* pField,
}
if( !aName.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_name).
- append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_name "=\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), aName, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
sOut.append('\"');
}
if( !aValue.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_value).
- append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_value "=\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), aValue, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
sOut.append('\"');
diff --git a/sw/source/filter/html/htmlflywriter.cxx b/sw/source/filter/html/htmlflywriter.cxx
index 2d323864a4e3..7064622fb7f9 100644
--- a/sw/source/filter/html/htmlflywriter.cxx
+++ b/sw/source/filter/html/htmlflywriter.cxx
@@ -436,9 +436,9 @@ void SwHTMLWriter::OutFrameFormat( AllHtmlFlags nMode, const SwFrameFormat& rFra
aContainerStr = (HtmlContainerFlags::Div == nCntnrMode)
? OOO_STRING_SVTOOLS_HTML_division
: OOO_STRING_SVTOOLS_HTML_span;
- sOut.append('<').append(GetNamespace() + aContainerStr).append(' ')
- .append(OOO_STRING_SVTOOLS_HTML_O_class).append("=\"")
- .append("sd-abs-pos").append('\"');
+ sOut.append("<" + GetNamespace() + aContainerStr + " "
+ OOO_STRING_SVTOOLS_HTML_O_class "=\""
+ "sd-abs-pos\"");
Strm().WriteOString( sOut.makeStringAndClear() );
// Output a width for non-draw objects
@@ -532,8 +532,7 @@ OString SwHTMLWriter::OutFrameFormatOptions( const SwFrameFormat &rFrameFormat,
{
const char *pStr =
(nFrameOpts & HtmlFrmOpts::Id) ? OOO_STRING_SVTOOLS_HTML_O_id : OOO_STRING_SVTOOLS_HTML_O_name;
- sOut.append(' ').append(pStr).
- append("=\"");
+ sOut.append(OString::Concat(" ") + pStr + "=\"");
Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( Strm(), rFrameFormat.GetName(), m_eDestEnc, &m_aNonConvertableCharacters );
sOut.append('\"');
@@ -550,8 +549,7 @@ OString SwHTMLWriter::OutFrameFormatOptions( const SwFrameFormat &rFrameFormat,
// ALT
if( (nFrameOpts & HtmlFrmOpts::Alt) && !rAlternateText.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_alt).
- append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_alt "=\"");
Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( Strm(), rAlternateText, m_eDestEnc, &m_aNonConvertableCharacters );
sOut.append('\"');
@@ -597,8 +595,8 @@ OString SwHTMLWriter::OutFrameFormatOptions( const SwFrameFormat &rFrameFormat,
}
if( pStr )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align).append("=\"").
- append(pStr).append("\"");
+ sOut.append(OString::Concat(" " OOO_STRING_SVTOOLS_HTML_O_align "=\"") +
+ pStr + "\"");
}
// HSPACE and VSPACE
@@ -634,14 +632,14 @@ OString SwHTMLWriter::OutFrameFormatOptions( const SwFrameFormat &rFrameFormat,
if( aPixelSpc.Width() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_hspace).
- append("=\"").append(static_cast<sal_Int32>(aPixelSpc.Width())).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_hspace
+ "=\"").append(static_cast<sal_Int32>(aPixelSpc.Width())).append("\"");
}
if( aPixelSpc.Height() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_vspace).
- append("=\"").append(static_cast<sal_Int32>(aPixelSpc.Height())).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_vspace
+ "=\"").append(static_cast<sal_Int32>(aPixelSpc.Height())).append("\"");
}
}
@@ -708,8 +706,7 @@ OString SwHTMLWriter::OutFrameFormatOptions( const SwFrameFormat &rFrameFormat,
if( (nFrameOpts & HtmlFrmOpts::Width) &&
((nPercentWidth && nPercentWidth!=255) || aPixelSz.Width()) )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_width).
- append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_width "=\"");
if( nPercentWidth )
sOut.append(static_cast<sal_Int32>(nPercentWidth)).append('%');
else
@@ -720,8 +717,7 @@ OString SwHTMLWriter::OutFrameFormatOptions( const SwFrameFormat &rFrameFormat,
if( (nFrameOpts & HtmlFrmOpts::Height) &&
((nPercentHeight && nPercentHeight!=255) || aPixelSz.Height()) )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_height).
- append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_height "=\"");
if( nPercentHeight )
sOut.append(static_cast<sal_Int32>(nPercentHeight)).append('%');
else
@@ -791,9 +787,9 @@ OString SwHTMLWriter::OutFrameFormatOptions( const SwFrameFormat &rFrameFormat,
if( pStr )
{
- sOut.append('<').append(OOO_STRING_SVTOOLS_HTML_linebreak).
- append(' ').append(OOO_STRING_SVTOOLS_HTML_O_clear).
- append("=\"").append(pStr).append("\">");
+ sOut.append("<" OOO_STRING_SVTOOLS_HTML_linebreak
+ " " OOO_STRING_SVTOOLS_HTML_O_clear
+ "=\"" + OString::Concat(pStr) + "\">");
sRetEndTags = sOut.makeStringAndClear();
}
}
@@ -1494,17 +1490,17 @@ Writer& OutHTML_BulletImage( Writer& rWrt,
sOut.append('<').append(pTag);
sOut.append(' ');
- sOut.append(OOO_STRING_SVTOOLS_HTML_O_style).append("=\"");
+ sOut.append(OOO_STRING_SVTOOLS_HTML_O_style "=\"");
if(!aLink.isEmpty())
{
- sOut.append(OOO_STRING_SVTOOLS_HTML_O_src).append("=\"");
+ sOut.append(OOO_STRING_SVTOOLS_HTML_O_src "=\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), aLink, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
}
else
{
- sOut.append("list-style-image: ").append("url(").
- append(OOO_STRING_SVTOOLS_HTML_O_data).append(":");
+ sOut.append("list-style-image: url("
+ OOO_STRING_SVTOOLS_HTML_O_data ":");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), aGraphicInBase64, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
sOut.append(");");
@@ -1590,8 +1586,8 @@ static Writer & OutHTML_FrameFormatAsMulticol( Writer& rWrt,
sal_uInt16 nCols = rFormatCol.GetNumCols();
if( nCols )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_cols).
- append("=\"").append(static_cast<sal_Int32>(nCols)).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_cols
+ "=\"").append(static_cast<sal_Int32>(nCols)).append("\"");
}
// the Gutter width (minimum value) as GUTTER
@@ -1604,8 +1600,8 @@ static Writer & OutHTML_FrameFormatAsMulticol( Writer& rWrt,
->LogicToPixel( Size(nGutter,0),
MapMode(MapUnit::MapTwip) ).Width());
}
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_gutter).
- append("=\"").append(static_cast<sal_Int32>(nGutter)).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_gutter
+ "=\"").append(static_cast<sal_Int32>(nGutter)).append("\"");
}
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
@@ -1941,8 +1937,8 @@ Writer& OutHTML_HeaderFooter( Writer& rWrt, const SwFrameFormat& rFrameFormat,
// output as Multicol
rHTMLWrt.OutNewLine();
OStringBuffer sOut;
- sOut.append(OOO_STRING_SVTOOLS_HTML_division).append(' ')
- .append(OOO_STRING_SVTOOLS_HTML_O_title).append("=\"")
+ sOut.append(OOO_STRING_SVTOOLS_HTML_division " "
+ OOO_STRING_SVTOOLS_HTML_O_title "=\"")
.append( bHeader ? "header" : "footer" ).append("\"");
HTMLOutFuncs::Out_AsciiTag( rWrt.Strm(), OString(rHTMLWrt.GetNamespace() + sOut) );
@@ -1963,11 +1959,11 @@ Writer& OutHTML_HeaderFooter( Writer& rWrt, const SwFrameFormat& rFrameFormat,
nSize = static_cast<sal_Int16>(Application::GetDefaultDevice()
->LogicToPixel( Size(nSize,0), MapMode(MapUnit::MapTwip) ).Width());
- aSpacer = OStringBuffer(OOO_STRING_SVTOOLS_HTML_spacer).
- append(' ').append(OOO_STRING_SVTOOLS_HTML_O_type).
- append("=\"").append(OOO_STRING_SVTOOLS_HTML_SPTYPE_vertical).append("\"").
- append(' ').append(OOO_STRING_SVTOOLS_HTML_O_size).
- append("=\"").append(static_cast<sal_Int32>(nSize)).append("\"").
+ aSpacer = OStringBuffer(OOO_STRING_SVTOOLS_HTML_spacer
+ " " OOO_STRING_SVTOOLS_HTML_O_type
+ "=\"" OOO_STRING_SVTOOLS_HTML_SPTYPE_vertical "\""
+ " " OOO_STRING_SVTOOLS_HTML_O_size
+ "=\"").append(static_cast<sal_Int32>(nSize)).append("\"").
makeStringAndClear();
}
diff --git a/sw/source/filter/html/htmlftn.cxx b/sw/source/filter/html/htmlftn.cxx
index 4dbe9f3250dd..0f0a0098e1a8 100644
--- a/sw/source/filter/html/htmlftn.cxx
+++ b/sw/source/filter/html/htmlftn.cxx
@@ -434,18 +434,18 @@ void SwHTMLWriter::OutFootEndNoteSym( const SwFormatFootnote& rFormatFootnote,
}
OStringBuffer sOut;
- sOut.append('<').append(GetNamespace() + OOO_STRING_SVTOOLS_HTML_anchor).append(' ')
- .append(OOO_STRING_SVTOOLS_HTML_O_class).append("=\"");
+ sOut.append("<" + GetNamespace() + OOO_STRING_SVTOOLS_HTML_anchor " "
+ OOO_STRING_SVTOOLS_HTML_O_class "=\"");
Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( Strm(), sClass, m_eDestEnc, &m_aNonConvertableCharacters );
- sOut.append("\" ").append(OOO_STRING_SVTOOLS_HTML_O_name).append("=\"");
+ sOut.append("\" " OOO_STRING_SVTOOLS_HTML_O_name "=\"");
Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( Strm(), sFootnoteName, m_eDestEnc, &m_aNonConvertableCharacters );
- sOut.append(OOO_STRING_SVTOOLS_HTML_FTN_symbol).append("\" ")
- .append(OOO_STRING_SVTOOLS_HTML_O_href).append("=\"#");
+ sOut.append(OOO_STRING_SVTOOLS_HTML_FTN_symbol "\" "
+ OOO_STRING_SVTOOLS_HTML_O_href "=\"#");
Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( Strm(), sFootnoteName, m_eDestEnc, &m_aNonConvertableCharacters );
- sOut.append(OOO_STRING_SVTOOLS_HTML_FTN_anchor).append("\">");
+ sOut.append(OOO_STRING_SVTOOLS_HTML_FTN_anchor "\">");
Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( Strm(), rNum, m_eDestEnc, &m_aNonConvertableCharacters );
diff --git a/sw/source/filter/html/htmlplug.cxx b/sw/source/filter/html/htmlplug.cxx
index 95dbd157c620..9e82ac075e83 100644
--- a/sw/source/filter/html/htmlplug.cxx
+++ b/sw/source/filter/html/htmlplug.cxx
@@ -1235,8 +1235,7 @@ Writer& OutHTML_FrameFormatOLENode( Writer& rWrt, const SwFrameFormat& rFrameFor
if( !aURL.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_src)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_src "=\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), aURL, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
sOut.append('\"');
@@ -1246,8 +1245,7 @@ Writer& OutHTML_FrameFormatOLENode( Writer& rWrt, const SwFrameFormat& rFrameFor
aAny = xSet->getPropertyValue("PluginMimeType");
if( (aAny >>= aType) && !aType.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_type)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_type "=\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), aType, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
sOut.append('\"');
@@ -1281,8 +1279,7 @@ Writer& OutHTML_FrameFormatOLENode( Writer& rWrt, const SwFrameFormat& rFrameFor
OUString sCodeBase( URIHelper::simpleNormalizedMakeRelative(rWrt.GetBaseURL(), aCd) );
if( !sCodeBase.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_codebase)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_codebase "=\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), sCodeBase, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
sOut.append('\"');
@@ -1293,8 +1290,7 @@ Writer& OutHTML_FrameFormatOLENode( Writer& rWrt, const SwFrameFormat& rFrameFor
OUString aClass;
aAny = xSet->getPropertyValue("AppletCode");
aAny >>= aClass;
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_code)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_code "=\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), aClass, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
sOut.append('\"');
@@ -1305,8 +1301,7 @@ Writer& OutHTML_FrameFormatOLENode( Writer& rWrt, const SwFrameFormat& rFrameFor
aAny >>= aAppletName;
if( !aAppletName.isEmpty() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_name)
- .append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_name "=\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), aAppletName, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
sOut.append('\"');
@@ -1390,13 +1385,12 @@ Writer& OutHTML_FrameFormatOLENode( Writer& rWrt, const SwFrameFormat& rFrameFor
const OUString& rValue = rCommand.GetArgument();
rHTMLWrt.OutNewLine();
OStringBuffer sBuf;
- sBuf.append('<').append(rHTMLWrt.GetNamespace() + OOO_STRING_SVTOOLS_HTML_param)
- .append(' ').append(OOO_STRING_SVTOOLS_HTML_O_name)
- .append("=\"");
+ sBuf.append("<" + rHTMLWrt.GetNamespace() + OOO_STRING_SVTOOLS_HTML_param
+ " " OOO_STRING_SVTOOLS_HTML_O_name
+ "=\"");
rWrt.Strm().WriteOString( sBuf.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), rName, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters );
- sBuf.append("\" ").append(OOO_STRING_SVTOOLS_HTML_O_value)
- .append("=\"");
+ sBuf.append("\" " OOO_STRING_SVTOOLS_HTML_O_value "=\"");
rWrt.Strm().WriteOString( sBuf.makeStringAndClear() );
HTMLOutFuncs::Out_String( rWrt.Strm(), rValue, rHTMLWrt.m_eDestEnc, &rHTMLWrt.m_aNonConvertableCharacters ).WriteCharPtr( "\">" );
}
diff --git a/sw/source/filter/html/htmltabw.cxx b/sw/source/filter/html/htmltabw.cxx
index 817d74784356..e05d4124e6b5 100644
--- a/sw/source/filter/html/htmltabw.cxx
+++ b/sw/source/filter/html/htmltabw.cxx
@@ -309,13 +309,13 @@ void SwHTMLWrtTable::OutTableCell( SwHTMLWriter& rWrt,
// output ROW- and COLSPAN
if( nRowSpan>1 )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_rowspan).
- append("=\"").append(static_cast<sal_Int32>(nRowSpan)).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_rowspan
+ "=\"").append(static_cast<sal_Int32>(nRowSpan)).append("\"");
}
if( nColSpan > 1 )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_colspan).
- append("=\"").append(static_cast<sal_Int32>(nColSpan)).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_colspan
+ "=\"").append(static_cast<sal_Int32>(nColSpan)).append("\"");
}
tools::Long nWidth = 0;
@@ -367,8 +367,7 @@ void SwHTMLWrtTable::OutTableCell( SwHTMLWriter& rWrt,
// output WIDTH: from layout or calculated
if( bOutWidth )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_width).
- append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_width "=\"");
if( nPercentWidth != SAL_MAX_UINT32 )
{
sOut.append(static_cast<sal_Int32>(nPercentWidth)).append('%');
@@ -388,8 +387,8 @@ void SwHTMLWrtTable::OutTableCell( SwHTMLWriter& rWrt,
if( nHeight )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_height)
- .append("=\"").append(static_cast<sal_Int32>(aPixelSz.Height())).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_height
+ "=\"").append(static_cast<sal_Int32>(aPixelSz.Height())).append("\"");
}
const SfxItemSet& rItemSet = pBox->GetFrameFormat()->GetAttrSet();
@@ -403,8 +402,8 @@ void SwHTMLWrtTable::OutTableCell( SwHTMLWriter& rWrt,
sal_Int16 eVertOri = pCell->GetVertOri();
if( text::VertOrientation::TOP==eVertOri || text::VertOrientation::BOTTOM==eVertOri )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_valign)
- .append("=\"").append(text::VertOrientation::TOP==eVertOri ?
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_valign
+ "=\"").append(text::VertOrientation::TOP==eVertOri ?
OOO_STRING_SVTOOLS_HTML_VA_top :
OOO_STRING_SVTOOLS_HTML_VA_bottom)
.append("\"");
@@ -544,8 +543,8 @@ void SwHTMLWrtTable::OutTableCells( SwHTMLWriter& rWrt,
if( text::VertOrientation::TOP==eRowVertOri || text::VertOrientation::BOTTOM==eRowVertOri )
{
OStringBuffer sOut;
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_valign)
- .append("=\"").append(text::VertOrientation::TOP==eRowVertOri ? OOO_STRING_SVTOOLS_HTML_VA_top : OOO_STRING_SVTOOLS_HTML_VA_bottom)
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_valign
+ "=\"").append(text::VertOrientation::TOP==eRowVertOri ? OOO_STRING_SVTOOLS_HTML_VA_top : OOO_STRING_SVTOOLS_HTML_VA_bottom)
.append("\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
}
@@ -628,25 +627,24 @@ void SwHTMLWrtTable::Write( SwHTMLWriter& rWrt, sal_Int16 eAlign,
// output ALIGN=
if( text::HoriOrientation::RIGHT == eAlign )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align).
- append("=\"").append(OOO_STRING_SVTOOLS_HTML_AL_right).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_align
+ "=\"" OOO_STRING_SVTOOLS_HTML_AL_right "\"");
}
else if( text::HoriOrientation::CENTER == eAlign )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align).
- append("=\"").append(OOO_STRING_SVTOOLS_HTML_AL_center).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_align
+ "=\"" OOO_STRING_SVTOOLS_HTML_AL_center "\"");
}
else if( text::HoriOrientation::LEFT == eAlign )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align).
- append("=\"").append(OOO_STRING_SVTOOLS_HTML_AL_left).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_align
+ "=\"" OOO_STRING_SVTOOLS_HTML_AL_left "\"");
}
// output WIDTH: from layout or calculated
if( m_nTabWidth )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_width).
- append("=\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_width "=\"");
if( HasRelWidths() )
sOut.append(static_cast<sal_Int32>(m_nTabWidth)).append('%');
else if( Application::GetDefaultDevice() )
@@ -678,24 +676,24 @@ void SwHTMLWrtTable::Write( SwHTMLWriter& rWrt, sal_Int16 eAlign,
if( aPixelSpc.Width() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_hspace).
- append("=\"").append(static_cast<sal_Int32>(aPixelSpc.Width())).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_hspace
+ "=\"").append(static_cast<sal_Int32>(aPixelSpc.Width())).append("\"");
}
if( aPixelSpc.Height() )
{
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_vspace).
- append("=\"").append(static_cast<sal_Int32>(aPixelSpc.Height())).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_vspace
+ "=\"").append(static_cast<sal_Int32>(aPixelSpc.Height())).append("\"");
}
}
// output CELLPADDING: from layout or calculated
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_cellpadding).
- append("=\"").append(static_cast<sal_Int32>(SwHTMLWriter::ToPixel(m_nCellPadding,false))).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_cellpadding
+ "=\"").append(static_cast<sal_Int32>(SwHTMLWriter::ToPixel(m_nCellPadding,false))).append("\"");
// output CELLSPACING: from layout or calculated
- sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_cellspacing).
- append("=\"").append(static_cast<sal_Int32>(SwHTMLWriter::ToPixel(m_nCellSpacing,false))).append("\"");
+ sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_cellspacing
+ "=\"").append(static_cast<sal_Int32>(SwHTMLWriter::ToPixel(m_nCellSpacing,false))).append("\"");
rWrt.Strm().WriteOString( sOut.makeStringAndClear() );
@@ -718,7 +716,7 @@ void SwHTMLWrtTable::Write( SwHTMLWriter& rWrt, sal_Int16 eAlign,
{
rWrt.OutNewLine(); // <CAPTION> in new line
OStringBuffer sOutStr(OOO_STRING_SVTOOLS_HTML_caption);
- sOutStr.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_align).append("=\"")
+ sOutStr.append(" " OOO_STRING_SVTOOLS_HTML_O_align "=\"")
.append(bTopCaption ? OOO_STRING_SVTOOLS_HTML_VA_top : OOO_STRING_SVTOOLS_HTML_VA_bottom)
.append("\"");
HTMLOutFuncs::Out_AsciiTag( rWrt.Strm(), OString(rWrt.GetNamespace() + sOutStr) );
diff --git a/sw/source/filter/html/swhtml.cxx b/sw/source/filter/html/swhtml.cxx
index 768361341d01..078dae27f0ac 100644
--- a/sw/source/filter/html/swhtml.cxx
+++ b/sw/source/filter/html/swhtml.cxx
@@ -2103,7 +2103,7 @@ void SwHTMLParser::NextToken( HtmlTokenId nToken )
if( !aToken.isEmpty() )
{
UnescapeToken();
- aComment.append(" ").append(aToken);
+ aComment.append(" " + aToken);
}
aComment.append(">");
InsertComment( aComment.makeStringAndClear() );
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx
index 2b7cb420d6c6..48f1e1512f79 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -9038,8 +9038,8 @@ void DocxAttributeOutput::FormatVertOrientation( const SwFormatVertOrient& rFlyV
{
m_rExport.SdrExporter().getTextFrameStyle().append(";margin-top:").append(double(rFlyVert.GetPos()) / 20).append("pt");
if ( !sAlign.isEmpty() )
- m_rExport.SdrExporter().getTextFrameStyle().append(";mso-position-vertical:").append(sAlign);
- m_rExport.SdrExporter().getTextFrameStyle().append(";mso-position-vertical-relative:").append(sVAnchor);
+ m_rExport.SdrExporter().getTextFrameStyle().append(";mso-position-vertical:" + sAlign);
+ m_rExport.SdrExporter().getTextFrameStyle().append(";mso-position-vertical-relative:" + sVAnchor);
}
else if (m_rExport.SdrExporter().getDMLTextFrameSyntax())
{
@@ -9064,8 +9064,8 @@ void DocxAttributeOutput::FormatHorizOrientation( const SwFormatHoriOrient& rFly
{
m_rExport.SdrExporter().getTextFrameStyle().append(";margin-left:").append(double(rFlyHori.GetPos()) / 20).append("pt");
if ( !sAlign.isEmpty() )
- m_rExport.SdrExporter().getTextFrameStyle().append(";mso-position-horizontal:").append(sAlign);
- m_rExport.SdrExporter().getTextFrameStyle().append(";mso-position-horizontal-relative:").append(sHAnchor);
+ m_rExport.SdrExporter().getTextFrameStyle().append(";mso-position-horizontal:" + sAlign);
+ m_rExport.SdrExporter().getTextFrameStyle().append(";mso-position-horizontal-relative:" + sHAnchor);
}
else if (m_rExport.SdrExporter().getDMLTextFrameSyntax())
{
diff --git a/sw/source/filter/ww8/docxsdrexport.cxx b/sw/source/filter/ww8/docxsdrexport.cxx
index 1803ae90084a..539eb63c20b1 100644
--- a/sw/source/filter/ww8/docxsdrexport.cxx
+++ b/sw/source/filter/ww8/docxsdrexport.cxx
@@ -1622,11 +1622,7 @@ void DocxSdrExport::writeVMLTextFrame(ww8::Frame const* pParentFrame, bool bText
if (!bTextBoxOnly)
{
OString sRotation(OString::number(m_pImpl->getDMLandVMLTextFrameRotation().get() / -100));
- m_pImpl->getExport()
- .SdrExporter()
- .getTextFrameStyle()
- .append(";rotation:")
- .append(sRotation);
+ m_pImpl->getExport().SdrExporter().getTextFrameStyle().append(";rotation:" + sRotation);
}
m_pImpl->getExport().OutputFormat(pParentFrame->GetFrameFormat(), false, false, true);
m_pImpl->getFlyAttrList()->add(XML_style, m_pImpl->getTextFrameStyle().makeStringAndClear());
diff --git a/sw/source/filter/ww8/rtfattributeoutput.cxx b/sw/source/filter/ww8/rtfattributeoutput.cxx
index 63fd05d4d225..978e44ded2c0 100644
--- a/sw/source/filter/ww8/rtfattributeoutput.cxx
+++ b/sw/source/filter/ww8/rtfattributeoutput.cxx
@@ -451,34 +451,28 @@ OString RtfAttributeOutput::MoveCharacterProperties(bool aAutoWriteRtlLtr)
{
if (!aAssocRtlch.isEmpty())
{
- aBuf.append(OOO_STRING_SVTOOLS_RTF_LTRCH)
- .append(aAssocLtrch)
- .append(' ')
- .append(OOO_STRING_SVTOOLS_RTF_RTLCH)
- .append(aAssocRtlch);
+ aBuf.append(OOO_STRING_SVTOOLS_RTF_LTRCH + aAssocLtrch
+ + " " OOO_STRING_SVTOOLS_RTF_RTLCH + aAssocRtlch);
}
}
else
{
if (!aAssocRtlch.isEmpty())
{
- aBuf.append(OOO_STRING_SVTOOLS_RTF_RTLCH)
- .append(aAssocRtlch)
- .append(' ')
- .append(OOO_STRING_SVTOOLS_RTF_LTRCH)
- .append(aAssocLtrch);
+ aBuf.append(OOO_STRING_SVTOOLS_RTF_RTLCH + aAssocRtlch
+ + " " OOO_STRING_SVTOOLS_RTF_LTRCH + aAssocLtrch);
}
if (!aAssocHich.isEmpty())
{
- aBuf.append(OOO_STRING_SVTOOLS_RTF_HICH).append(aAssocHich);
+ aBuf.append(OOO_STRING_SVTOOLS_RTF_HICH + aAssocHich);
}
if (!aNormal.isEmpty())
{
- aBuf.append(OOO_STRING_SVTOOLS_RTF_LOCH).append(aNormal);
+ aBuf.append(OOO_STRING_SVTOOLS_RTF_LOCH + aNormal);
}
if (!aAssocDbch.isEmpty())
{
- aBuf.append(OOO_STRING_SVTOOLS_RTF_DBCH).append(aAssocDbch);
+ aBuf.append(OOO_STRING_SVTOOLS_RTF_DBCH + aAssocDbch);
}
}
@@ -1086,7 +1080,7 @@ void RtfAttributeOutput::EndTableRow()
m_aAfterRuns.append(m_aTables.back());
m_aTables.pop_back();
}
- m_aAfterRuns.append(OOO_STRING_SVTOOLS_RTF_ROW).append(OOO_STRING_SVTOOLS_RTF_PARD);
+ m_aAfterRuns.append(OOO_STRING_SVTOOLS_RTF_ROW OOO_STRING_SVTOOLS_RTF_PARD);
}
m_bTableRowEnded = true;
}
@@ -2321,12 +2315,10 @@ void RtfAttributeOutput::OutputFlyFrame_Impl(const ww8::Frame& rFrame, const Poi
xPropSet->getPropertyValue("StringItemList") >>= aStrSeq;
for (const auto& rStr : std::as_const(aStrSeq))
- m_aRun
- ->append(
- "{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFL
- " ")
- .append(OUStringToOString(rStr, m_rExport.GetCurrentEncoding()))
- .append('}');
+ m_aRun->append(
+ "{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFL " "
+ + OUStringToOString(rStr, m_rExport.GetCurrentEncoding())
+ + "}");
m_aRun->append("}}");
diff --git a/sw/source/filter/ww8/rtfexport.cxx b/sw/source/filter/ww8/rtfexport.cxx
index f3bc81771ad1..ca3247ba3498 100644
--- a/sw/source/filter/ww8/rtfexport.cxx
+++ b/sw/source/filter/ww8/rtfexport.cxx
@@ -352,28 +352,23 @@ void RtfExport::DoFormText(const SwInputField* pField)
m_pAttrOutput->RunText().append(OOO_STRING_SVTOOLS_RTF_FFTYPETXT "0");
if (!sName.isEmpty())
- m_pAttrOutput->RunText()
- .append("{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFNAME " ")
- .append(msfilter::rtfutil::OutString(sName, m_eDefaultEncoding))
- .append("}");
+ m_pAttrOutput->RunText().append(
+ "{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFNAME " "
+ + msfilter::rtfutil::OutString(sName, m_eDefaultEncoding) + "}");
if (!rHelp.isEmpty())
- m_pAttrOutput->RunText()
- .append("{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFHELPTEXT " ")
- .append(msfilter::rtfutil::OutString(rHelp, m_eDefaultEncoding))
- .append("}");
- m_pAttrOutput->RunText()
- .append("{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFDEFTEXT " ")
- .append(msfilter::rtfutil::OutString(sResult, m_eDefaultEncoding))
- .append("}");
+ m_pAttrOutput->RunText().append(
+ "{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFHELPTEXT " "
+ + msfilter::rtfutil::OutString(rHelp, m_eDefaultEncoding) + "}");
+ m_pAttrOutput->RunText().append(
+ "{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFDEFTEXT " "
+ + msfilter::rtfutil::OutString(sResult, m_eDefaultEncoding) + "}");
if (!rStatus.isEmpty())
- m_pAttrOutput->RunText()
- .append("{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFSTATTEXT " ")
- .append(msfilter::rtfutil::OutString(rStatus, m_eDefaultEncoding))
- .append("}");
+ m_pAttrOutput->RunText().append(
+ "{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_FFSTATTEXT " "
+ + msfilter::rtfutil::OutString(rStatus, m_eDefaultEncoding) + "}");
m_pAttrOutput->RunText().append("}}}{" OOO_STRING_SVTOOLS_RTF_FLDRSLT " ");
- m_pAttrOutput->RunText()
- .append(msfilter::rtfutil::OutString(sResult, m_eDefaultEncoding))
- .append("}}");
+ m_pAttrOutput->RunText().append(msfilter::rtfutil::OutString(sResult, m_eDefaultEncoding)
+ + "}}");
}
sal_uLong RtfExport::ReplaceCr(sal_uInt8 /*nChar*/)
diff --git a/sw/source/filter/ww8/rtfsdrexport.cxx b/sw/source/filter/ww8/rtfsdrexport.cxx
index 59be0e879393..f4c2e3deca3e 100644
--- a/sw/source/filter/ww8/rtfsdrexport.cxx
+++ b/sw/source/filter/ww8/rtfsdrexport.cxx
@@ -435,10 +435,8 @@ void RtfSdrExport::Commit(EscherPropertyContainer& rProps, const tools::Rectangl
case ESCHER_Prop_fillBlip:
{
OStringBuffer aBuf;
- aBuf.append('{')
- .append(OOO_STRING_SVTOOLS_RTF_PICT)
- .append(OOO_STRING_SVTOOLS_RTF_PNGBLIP)
- .append(SAL_NEWLINE_STRING);
+ aBuf.append("{" OOO_STRING_SVTOOLS_RTF_PICT OOO_STRING_SVTOOLS_RTF_PNGBLIP
+ SAL_NEWLINE_STRING);
int nHeaderSize
= 25; // The first bytes are WW8-specific, we're only interested in the PNG
aBuf.append(msfilter::rtfutil::WriteHex(rOpt.nProp.data() + nHeaderSize,
@@ -486,19 +484,15 @@ void RtfSdrExport::AddRectangleDimensions(OStringBuffer& rBuffer,
rBuffer.append(OOO_STRING_SVTOOLS_RTF_SHPBOTTOM).append(rRectangle.Bottom());
}
-static void lcl_AppendSP(OStringBuffer& rRunText, const char cName[], std::string_view rValue)
+static void lcl_AppendSP(OStringBuffer& rRunText, const char* cName, std::string_view rValue)
{
- rRunText.append('{')
- .append(OOO_STRING_SVTOOLS_RTF_SP)
- .append('{')
- .append(OOO_STRING_SVTOOLS_RTF_SN " ")
- .append(cName)
- .append('}')
- .append('{')
- .append(OOO_STRING_SVTOOLS_RTF_SV " ")
- .append(rValue)
- .append('}')
- .append('}');
+ rRunText.append(OString::Concat("{" OOO_STRING_SVTOOLS_RTF_SP "{" OOO_STRING_SVTOOLS_RTF_SN " ")
+ + cName
+ + "}"
+ "{" OOO_STRING_SVTOOLS_RTF_SV " "
+ + rValue
+ + "}"
+ "}");
}
void RtfSdrExport::impl_writeGraphic()
@@ -536,7 +530,7 @@ void RtfSdrExport::impl_writeGraphic()
// Add it to the properties.
RtfStringBuffer aBuf;
- aBuf->append('{').append(OOO_STRING_SVTOOLS_RTF_PICT).append(OOO_STRING_SVTOOLS_RTF_PNGBLIP);
+ aBuf->append("{" OOO_STRING_SVTOOLS_RTF_PICT OOO_STRING_SVTOOLS_RTF_PNGBLIP);
aBuf->append(OOO_STRING_SVTOOLS_RTF_PICW).append(sal_Int32(aMapped.Width()));
aBuf->append(OOO_STRING_SVTOOLS_RTF_PICH)
.append(sal_Int32(aMapped.Height()))
@@ -556,10 +550,8 @@ sal_Int32 RtfSdrExport::StartShape()
impl_writeGraphic();
m_rAttrOutput.RunText().append('{').append(OOO_STRING_SVTOOLS_RTF_SHP);
- m_rAttrOutput.RunText()
- .append('{')
- .append(OOO_STRING_SVTOOLS_RTF_IGNORE)
- .append(OOO_STRING_SVTOOLS_RTF_SHPINST);
+ m_rAttrOutput.RunText().append(
+ "{" OOO_STRING_SVTOOLS_RTF_IGNORE OOO_STRING_SVTOOLS_RTF_SHPINST);
m_rAttrOutput.RunText().append(m_aShapeStyle.makeStringAndClear());
// Ignore \shpbxpage, \shpbxmargin, and \shpbxcolumn, in favor of the posrelh property.
diff --git a/sw/source/ui/dbui/createaddresslistdialog.cxx b/sw/source/ui/dbui/createaddresslistdialog.cxx
index 969bff35d7ad..39a8a1dc8a59 100644
--- a/sw/source/ui/dbui/createaddresslistdialog.cxx
+++ b/sw/source/ui/dbui/createaddresslistdialog.cxx
@@ -402,11 +402,11 @@ void lcl_WriteValues(const std::vector<OUString> *pFields, SvStream* pStream)
{
if (aIter==aBegin)
{
- sLine.append("\"").append(*aIter).append("\"");
+ sLine.append("\"" + *aIter + "\"");
}
else
{
- sLine.append("\t\"").append(*aIter).append("\"");
+ sLine.append("\t\"" + *aIter + "\"");
}
}
pStream->WriteByteStringLine( sLine.makeStringAndClear(), RTL_TEXTENCODING_UTF8 );
diff --git a/sw/source/uibase/app/docstyle.cxx b/sw/source/uibase/app/docstyle.cxx
index 570d2575c6c1..ce8a92633018 100644
--- a/sw/source/uibase/app/docstyle.cxx
+++ b/sw/source/uibase/app/docstyle.cxx
@@ -1006,10 +1006,10 @@ OUString SwDocStyleSheet::GetDescription(MapUnit eUnit)
{
if (!aDesc.isEmpty())
aDesc.append(sPlus);
- aDesc.append(SwResId(STR_PAGEBREAK)).append(sPlus).append(sModel);
+ aDesc.append(SwResId(STR_PAGEBREAK) + sPlus + sModel);
if (sPageNum != "0")
{
- aDesc.append(sPlus).append(SwResId(STR_PAGEOFFSET)).append(sPageNum);
+ aDesc.append(sPlus + SwResId(STR_PAGEOFFSET) + sPageNum);
}
}
else if (!sBreak.isEmpty()) // Break can be valid only when NO Model
diff --git a/sw/source/uibase/shells/annotsh.cxx b/sw/source/uibase/shells/annotsh.cxx
index 70e1ef1086dd..d29ba3d24bb2 100644
--- a/sw/source/uibase/shells/annotsh.cxx
+++ b/sw/source/uibase/shells/annotsh.cxx
@@ -1647,7 +1647,7 @@ void SwAnnotationShell::StateUndo(SfxItemSet &rSet)
if( nCount )
{
for( sal_uInt16 n = 0; n < nCount; ++n )
- sList.append( (pUndoManager->*fnGetComment)( n, SfxUndoManager::TopLevel ) ).append("\n");
+ sList.append( (pUndoManager->*fnGetComment)( n, SfxUndoManager::TopLevel ) + "\n");
}
SfxStringListItem aItem( nWhich );
diff --git a/sw/source/uibase/shells/drwtxtsh.cxx b/sw/source/uibase/shells/drwtxtsh.cxx
index 780b7260a5ae..d8f5fa419999 100644
--- a/sw/source/uibase/shells/drwtxtsh.cxx
+++ b/sw/source/uibase/shells/drwtxtsh.cxx
@@ -568,7 +568,7 @@ void SwDrawTextShell::StateUndo(SfxItemSet &rSet)
{
OUStringBuffer sList;
for( sal_uInt16 n = 0; n < nCount; ++n )
- sList.append( (pUndoManager->*fnGetComment)( n, SfxUndoManager::TopLevel ) ).append("\n");
+ sList.append( (pUndoManager->*fnGetComment)( n, SfxUndoManager::TopLevel ) + "\n");
SfxStringListItem aItem( nWhich );
aItem.SetString( sList.makeStringAndClear() );
diff --git a/sw/source/uibase/wrtsh/wrtundo.cxx b/sw/source/uibase/wrtsh/wrtundo.cxx
index 49d73d75e579..6b087fad7b6d 100644
--- a/sw/source/uibase/wrtsh/wrtundo.cxx
+++ b/sw/source/uibase/wrtsh/wrtundo.cxx
@@ -130,7 +130,7 @@ void SwWrtShell::GetDoStrings( DoType eDoType, SfxStringListItem& rStrs ) const
for (const OUString & comment : comments)
{
OSL_ENSURE(!comment.isEmpty(), "no Undo/Redo Text set");
- buf.append(comment).append("\n");
+ buf.append(comment + "\n");
}
rStrs.SetString(buf.makeStringAndClear());
}
diff --git a/ucb/source/core/provprox.cxx b/ucb/source/core/provprox.cxx
index 08836311b0cf..3424b27aca94 100644
--- a/ucb/source/core/provprox.cxx
+++ b/ucb/source/core/provprox.cxx
@@ -351,7 +351,9 @@ UcbContentProviderProxy::getContentProvider()
}
OSL_ENSURE( m_xProvider.is(),
- OStringBuffer("UcbContentProviderProxy::getContentProvider - No provider for '").append(OUStringToOString(m_aService, osl_getThreadTextEncoding())).append(".").getStr() );
+ OStringBuffer("UcbContentProviderProxy::getContentProvider - No provider for '" +
+ OUStringToOString(m_aService, osl_getThreadTextEncoding()) +
+ ".").getStr() );
return m_xTargetProvider;
}
diff --git a/ucb/source/ucp/cmis/cmis_url.cxx b/ucb/source/ucp/cmis/cmis_url.cxx
index ae2bce9dd59a..38c63df8bf9f 100644
--- a/ucb/source/ucp/cmis/cmis_url.cxx
+++ b/ucb/source/ucp/cmis/cmis_url.cxx
@@ -90,7 +90,7 @@ namespace cmis
if ( !sSegment.isEmpty( ) )
{
- sEncodedPath.append("/").append(rtl::Uri::encode( sSegment,
+ sEncodedPath.append("/" + rtl::Uri::encode( sSegment,
rtl_UriCharClassRelSegment,
rtl_UriEncodeKeepEscapes,
RTL_TEXTENCODING_UTF8 ));
diff --git a/ucb/source/ucp/ftp/ftpurl.cxx b/ucb/source/ucp/ftp/ftpurl.cxx
index da2db0eaa208..d6afdc8610df 100644
--- a/ucb/source/ucp/ftp/ftpurl.cxx
+++ b/ucb/source/ucp/ftp/ftpurl.cxx
@@ -332,7 +332,7 @@ OUString FTPURL::parent(bool internal) const
if(last.isEmpty())
bff.append("..");
else if ( last == ".." )
- bff.append(last).append("/..");
+ bff.append(last + "/..");
bff.append(m_aType);
return bff.makeStringAndClear();
diff --git a/unotools/source/config/bootstrap.cxx b/unotools/source/config/bootstrap.cxx
index 98a2ac802f69..ad6202cf1479 100644
--- a/unotools/source/config/bootstrap.cxx
+++ b/unotools/source/config/bootstrap.cxx
@@ -416,15 +416,14 @@ static void addFileError(OUStringBuffer& _rBuf, OUString const& _aPath, AsciiStr
OUString sSimpleFileName = _aPath.copy(1 +_aPath.lastIndexOf(cURLSeparator));
_rBuf.append("The configuration file");
- _rBuf.append(" '").append(sSimpleFileName).append("' ");
+ _rBuf.append(" '" + sSimpleFileName + "' ");
_rBuf.appendAscii(_sWhat).append(PERIOD);
}
static void addMissingDirectoryError(OUStringBuffer& _rBuf, std::u16string_view _aPath)
{
- _rBuf.append("The configuration directory");
- _rBuf.append(" '").append(_aPath).append("' ");
- _rBuf.append(IS_MISSING).append(PERIOD);
+ _rBuf.append(OUString::Concat("The configuration directory '") + _aPath + "' " +
+ IS_MISSING + PERIOD);
}
static void addUnexpectedError(OUStringBuffer& _rBuf, AsciiString _sExtraInfo = nullptr)
diff --git a/unotools/source/config/configpaths.cxx b/unotools/source/config/configpaths.cxx
index 8c206d03a3cd..8c3ee31f2641 100644
--- a/unotools/source/config/configpaths.cxx
+++ b/unotools/source/config/configpaths.cxx
@@ -53,7 +53,7 @@ void lcl_resolveCharEntities(OUString & aLocalString)
OSL_ENSURE(ch,"Configuration path contains '&' that is not part of a valid character escape");
if (ch)
{
- aResult.append(aLocalString.subView(nStart,nEscapePos-nStart)).append(ch);
+ aResult.append(aLocalString.subView(nStart,nEscapePos-nStart) + OUStringChar(ch));
sal_Int32 nEscapeEnd=aLocalString.indexOf(';',nEscapePos);
nStart = nEscapeEnd+1;
@@ -245,7 +245,7 @@ OUString lcl_wrapName(const OUString& _sContent, const OUString& _sType)
OUStringBuffer aNormalized(_sType.getLength() + _sContent.getLength() + 4); // reserve approximate size initially
// prefix: type, opening bracket and quote
- aNormalized.append( _sType ).append( "['" );
+ aNormalized.append( _sType + "['" );
// content: copy over each char and handle escaping
for(const sal_Unicode* pCur = pBeginContent; pCur != pEndContent; ++pCur)
diff --git a/unotools/source/i18n/localedatawrapper.cxx b/unotools/source/i18n/localedatawrapper.cxx
index 0565e7f291a2..8c59d0a6267c 100644
--- a/unotools/source/i18n/localedatawrapper.cxx
+++ b/unotools/source/i18n/localedatawrapper.cxx
@@ -1384,13 +1384,13 @@ OUString LocaleDataWrapper::getLongDate( const Date& rDate, CalendarWrapper& rCa
switch ( getLongDateOrder() )
{
case DateOrder::DMY :
- aStr.append(aDay).append(getLongDateDaySep()).append(aMonth).append(getLongDateMonthSep()).append(aYear);
+ aStr.append(aDay + getLongDateDaySep() + aMonth + getLongDateMonthSep() + aYear);
break;
case DateOrder::MDY :
- aStr.append(aMonth).append(getLongDateMonthSep()).append(aDay).append(getLongDateDaySep()).append(aYear);
+ aStr.append(aMonth + getLongDateMonthSep() + aDay + getLongDateDaySep() + aYear);
break;
default: // YMD
- aStr.append(aYear).append(getLongDateYearSep()).append(aMonth).append(getLongDateMonthSep()).append(aDay);
+ aStr.append(aYear + getLongDateYearSep() + aMonth + getLongDateMonthSep() + aDay);
}
return aStr.makeStringAndClear();
}
diff --git a/unoxml/source/rdf/librdf_repository.cxx b/unoxml/source/rdf/librdf_repository.cxx
index 85b05260484a..7b4461aca83a 100644
--- a/unoxml/source/rdf/librdf_repository.cxx
+++ b/unoxml/source/rdf/librdf_repository.cxx
@@ -2150,9 +2150,9 @@ librdf_TypeConverter::extractResourceToCacheKey_NoLock(
}
uno::Reference< rdf::XBlankNode > xBlankNode(i_xResource, uno::UNO_QUERY);
if (xBlankNode.is()) {
- rBuffer.append("BlankNode ").append(xBlankNode->getStringValue());
+ rBuffer.append("BlankNode " + xBlankNode->getStringValue());
} else { // assumption: everything else is URI
- rBuffer.append("URI ").append(i_xResource->getStringValue());
+ rBuffer.append("URI " + i_xResource->getStringValue());
}
}
@@ -2242,10 +2242,10 @@ librdf_TypeConverter::extractNodeToCacheKey_NoLock(
if (!xLiteral.is()) {
return;
}
- rBuffer.append("Literal ").append(xLiteral->getValue()).append("\t").append(xLiteral->getLanguage());
+ rBuffer.append("Literal " + xLiteral->getValue() + "\t" + xLiteral->getLanguage());
const uno::Reference< rdf::XURI > xType(xLiteral->getDatatype());
if (xType.is())
- rBuffer.append("\t").append(xType->getStringValue());
+ rBuffer.append("\t" + xType->getStringValue());
}
// create blank or URI or literal node
diff --git a/vcl/skia/gdiimpl.cxx b/vcl/skia/gdiimpl.cxx
index 145bbf19cc4c..f0b9fb2e0d5c 100644
--- a/vcl/skia/gdiimpl.cxx
+++ b/vcl/skia/gdiimpl.cxx
@@ -1627,10 +1627,9 @@ sk_sp<SkImage> SkiaSalGraphicsImpl::mergeCacheBitmaps(const SkiaSalBitmap& bitma
keyBuf.append(targetSize.Width())
.append("x")
.append(targetSize.Height())
- .append("_")
- .append(bitmap.GetImageKey());
+ .append("_" + bitmap.GetImageKey());
if (alphaBitmap)
- keyBuf.append("_").append(alphaBitmap->GetAlphaImageKey());
+ keyBuf.append("_" + alphaBitmap->GetAlphaImageKey());
key = keyBuf.makeStringAndClear();
image = findCachedImage(key);
if (image)
diff --git a/vcl/source/gdi/pdfobjectcopier.cxx b/vcl/source/gdi/pdfobjectcopier.cxx
index 121eddb8b6de..c9e332aba28f 100644
--- a/vcl/source/gdi/pdfobjectcopier.cxx
+++ b/vcl/source/gdi/pdfobjectcopier.cxx
@@ -230,7 +230,7 @@ OString PDFObjectCopier::copyExternalResources(filter::PDFObjectElement& rPage,
OStringBuffer sRet("/" + rKind + "<<");
for (const auto& rPair : aRet)
{
- sRet.append("/").append(rPair.first).append(" ").append(rPair.second).append(" 0 R");
+ sRet.append("/" + rPair.first + " ").append(rPair.second).append(" 0 R");
}
sRet.append(">>");
diff --git a/vcl/source/treelist/transfer.cxx b/vcl/source/treelist/transfer.cxx
index 932cdca68a18..5f57a7ff07b6 100644
--- a/vcl/source/treelist/transfer.cxx
+++ b/vcl/source/treelist/transfer.cxx
@@ -785,9 +785,9 @@ bool TransferableHelper::SetINetBookmark( const INetBookmark& rBmk,
OString sDesc(OUStringToOString(rBmk.GetDescription(), eSysCSet));
OStringBuffer sOut;
sOut.append(sURL.getLength());
- sOut.append('@').append(sURL);
+ sOut.append("@" + sURL);
sOut.append(sDesc.getLength());
- sOut.append('@').append(sDesc);
+ sOut.append("@" + sDesc);
Sequence< sal_Int8 > aSeq(sOut.getLength());
memcpy(aSeq.getArray(), sOut.getStr(), sOut.getLength());
diff --git a/vcl/source/treelist/treelistbox.cxx b/vcl/source/treelist/treelistbox.cxx
index 9af367f2f460..8fa1ff9bbd0f 100644
--- a/vcl/source/treelist/treelistbox.cxx
+++ b/vcl/source/treelist/treelistbox.cxx
@@ -1296,7 +1296,7 @@ OUString SvTreeListBox::SearchEntryTextWithHeadTitle( SvTreeListEntry* pEntry )
if ( (rItem.GetType() == SvLBoxItemType::String) &&
!static_cast<SvLBoxString&>( rItem ).GetText().isEmpty() )
{
- sRet.append(static_cast<SvLBoxString&>( rItem ).GetText()).append(",");
+ sRet.append(static_cast<SvLBoxString&>( rItem ).GetText() + ",");
}
nCur++;
}
diff --git a/vcl/source/uitest/logger.cxx b/vcl/source/uitest/logger.cxx
index ffb6b1a8f6c8..8c23eb8b1cb2 100644
--- a/vcl/source/uitest/logger.cxx
+++ b/vcl/source/uitest/logger.cxx
@@ -99,21 +99,21 @@ void UITestLogger::logCommand(const OUString& rAction,
{
sal_Int32 nValue = 0;
rProp.Value >>= nValue;
- aBuffer.append("\"").append(rProp.Name).append("\": ");
+ aBuffer.append("\"" + rProp.Name + "\": ");
aBuffer.append(nValue).append(", ");
}
else if (aTypeName == "unsigned long")
{
sal_uInt32 nValue = 0;
rProp.Value >>= nValue;
- aBuffer.append("\"").append(rProp.Name).append("\": ");
+ aBuffer.append("\"" + rProp.Name + "\": ");
aBuffer.append(static_cast<sal_Int64>(nValue)).append(", ");
}
else if (aTypeName == "boolean")
{
bool bValue = false;
rProp.Value >>= bValue;
- aBuffer.append("\"").append(rProp.Name).append("\": ");
+ aBuffer.append("\"" + rProp.Name + "\": ");
if (bValue)
aBuffer.append("True, ");
else
@@ -333,11 +333,7 @@ OUString StringMapToOUString(const std::map<OUString, OUString>& rParameters)
{
if (itr != rParameters.begin())
aParameterString.append(", ");
- aParameterString.append("\"")
- .append(itr->first)
- .append("\": \"")
- .append(itr->second)
- .append("\"");
+ aParameterString.append("\"" + itr->first + "\": \"" + itr->second + "\"");
}
aParameterString.append("}");
diff --git a/vcl/source/uitest/uiobject.cxx b/vcl/source/uitest/uiobject.cxx
index 11c6e7ec7d6e..6861cd1bdfc3 100644
--- a/vcl/source/uitest/uiobject.cxx
+++ b/vcl/source/uitest/uiobject.cxx
@@ -370,7 +370,7 @@ void WindowUIObject::execute(const OUString& rAction,
{
OStringBuffer buf;
for (auto const & rPair : rParameters)
- buf.append(",").append(rPair.first.toUtf8()).append("=").append(rPair.second.toUtf8());
+ buf.append("," + rPair.first.toUtf8() + "=" + rPair.second.toUtf8());
SAL_WARN("vcl.uitest", "missing parameter TEXT to action TYPE "
<< buf.makeStringAndClear());
throw std::logic_error("missing parameter TEXT to action TYPE");
@@ -384,7 +384,7 @@ void WindowUIObject::execute(const OUString& rAction,
{
OStringBuffer buf;
for (auto const & rPair : rParameters)
- buf.append(",").append(rPair.first.toUtf8()).append("=").append(rPair.second.toUtf8());
+ buf.append("," + rPair.first.toUtf8() + "=" + rPair.second.toUtf8());
SAL_WARN("vcl.uitest", "unknown action for " << get_name()
<< ". Action: " << rAction << buf.makeStringAndClear());
throw std::logic_error("unknown action");
diff --git a/xmloff/source/forms/elementimport.cxx b/xmloff/source/forms/elementimport.cxx
index 06d69218e294..8c94cd738c65 100644
--- a/xmloff/source/forms/elementimport.cxx
+++ b/xmloff/source/forms/elementimport.cxx
@@ -226,9 +226,9 @@ namespace xmloff
for ( const auto& rCheck : m_aValues )
{
OSL_ENSURE(m_xInfo->hasPropertyByName(rCheck.Name),
- OStringBuffer("OElementImport::implApplySpecificProperties: read a property (").
- append(OUStringToOString(rCheck.Name, RTL_TEXTENCODING_ASCII_US)).
- append(") which does not exist on the element!").getStr());
+ OStringBuffer("OElementImport::implApplySpecificProperties: read a property (" +
+ OUStringToOString(rCheck.Name, RTL_TEXTENCODING_ASCII_US) +
+ ") which does not exist on the element!").getStr());
}
}
#endif
@@ -286,9 +286,9 @@ namespace xmloff
catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION("xmloff.forms");
- OSL_FAIL(OStringBuffer("OElementImport::implApplySpecificProperties: could not set the property \"").
- append(OUStringToOString(rPropValues.Name, RTL_TEXTENCODING_ASCII_US)).
- append("\"!").getStr());
+ OSL_FAIL(OStringBuffer("OElementImport::implApplySpecificProperties: could not set the property \"" +
+ OUStringToOString(rPropValues.Name, RTL_TEXTENCODING_ASCII_US) +
+ "\"!").getStr());
}
}
}
@@ -430,9 +430,9 @@ namespace xmloff
catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION("xmloff.forms");
- OSL_FAIL(OStringBuffer("OElementImport::EndElement: could not set the property \"").
- append(OUStringToOString(rPropValues.Name, RTL_TEXTENCODING_ASCII_US)).
- append("\"!").getStr());
+ OSL_FAIL(OStringBuffer("OElementImport::EndElement: could not set the property \"" +
+ OUStringToOString(rPropValues.Name, RTL_TEXTENCODING_ASCII_US) +
+ "\"!").getStr());
}
}
}
@@ -562,7 +562,9 @@ namespace xmloff
Reference< XComponentContext > xContext = m_rFormImport.getGlobalContext().GetComponentContext();
Reference< XInterface > xPure = xContext->getServiceManager()->createInstanceWithContext(m_sServiceName, xContext);
OSL_ENSURE(xPure.is(),
- OStringBuffer("OElementImport::createElement: service factory gave me no object (service name: ").append(OUStringToOString(m_sServiceName, RTL_TEXTENCODING_ASCII_US)).append(")!").getStr());
+ OStringBuffer("OElementImport::createElement: service factory gave me no object (service name: " +
+ OUStringToOString(m_sServiceName, RTL_TEXTENCODING_ASCII_US) +
+ ")!").getStr());
xReturn.set(xPure, UNO_QUERY);
}
else
diff --git a/xmloff/source/forms/layerimport.cxx b/xmloff/source/forms/layerimport.cxx
index 6039a1e303f0..40845d735a64 100644
--- a/xmloff/source/forms/layerimport.cxx
+++ b/xmloff/source/forms/layerimport.cxx
@@ -324,7 +324,9 @@ const SvXMLStyleContext* OFormLayerXMLImport_Impl::getStyleElement(const OUStrin
const SvXMLStyleContext* pControlStyle =
m_xAutoStyles.is() ? m_xAutoStyles->FindStyleChildContext( XmlStyleFamily::TEXT_PARAGRAPH, _rStyleName ) : nullptr;
OSL_ENSURE( pControlStyle || !m_xAutoStyles.is(),
- OStringBuffer("OFormLayerXMLImport_Impl::getStyleElement: did not find the style named \"").append(OUStringToOString(_rStyleName, RTL_TEXTENCODING_ASCII_US)).append("\"!").getStr() );
+ OStringBuffer("OFormLayerXMLImport_Impl::getStyleElement: did not find the style named \"" +
+ OUStringToOString(_rStyleName, RTL_TEXTENCODING_ASCII_US) +
+ "\"!").getStr() );
return pControlStyle;
}
diff --git a/xmloff/source/forms/propertyimport.cxx b/xmloff/source/forms/propertyimport.cxx
index ce1293baafea..ded9fa8565b1 100644
--- a/xmloff/source/forms/propertyimport.cxx
+++ b/xmloff/source/forms/propertyimport.cxx
@@ -100,9 +100,9 @@ Any PropertyConversion::convertString( const css::uno::Type& _rExpectedType,
bool bSuccess =
::sax::Converter::convertBool(bValue, _rReadCharacters);
OSL_ENSURE(bSuccess,
- OStringBuffer("PropertyConversion::convertString: could not convert \"").
- append(OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US)).
- append("\" into a boolean!").getStr());
+ OStringBuffer("PropertyConversion::convertString: could not convert \"" +
+ OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US) +
+ "\" into a boolean!").getStr());
aReturn <<= (_bInvertBoolean ? !bValue : bValue);
}
break;
@@ -114,9 +114,9 @@ Any PropertyConversion::convertString( const css::uno::Type& _rExpectedType,
bool bSuccess =
::sax::Converter::convertNumber(nValue, _rReadCharacters);
OSL_ENSURE(bSuccess,
- OStringBuffer("PropertyConversion::convertString: could not convert \"").
- append(OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US)).
- append("\" into an integer!").getStr());
+ OStringBuffer("PropertyConversion::convertString: could not convert \"" +
+ OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US) +
+ "\" into an integer!").getStr());
if (TypeClass_SHORT == _rExpectedType.getTypeClass())
aReturn <<= static_cast<sal_Int16>(nValue);
else
@@ -151,9 +151,9 @@ Any PropertyConversion::convertString( const css::uno::Type& _rExpectedType,
bool bSuccess =
::sax::Converter::convertDouble(nValue, _rReadCharacters);
OSL_ENSURE(bSuccess,
- OStringBuffer("PropertyConversion::convertString: could not convert \"").
- append(OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US)).
- append("\" into a double!").getStr());
+ OStringBuffer(OString::Concat("PropertyConversion::convertString: could not convert \"") +
+ OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US) +
+ "\" into a double!").getStr());
aReturn <<= nValue;
}
break;
@@ -177,9 +177,9 @@ Any PropertyConversion::convertString( const css::uno::Type& _rExpectedType,
bool bSuccess =
::sax::Converter::convertDouble(nValue, _rReadCharacters);
OSL_ENSURE(bSuccess,
- OStringBuffer("PropertyConversion::convertString: could not convert \"").
- append(OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US)).
- append("\" into a double!").getStr());
+ OStringBuffer("PropertyConversion::convertString: could not convert \"" +
+ OUStringToOString(_rReadCharacters, RTL_TEXTENCODING_ASCII_US) +
+ "\" into a double!").getStr());
// then convert it into the target type
switch (nType)
diff --git a/xmloff/source/style/xmlexppr.cxx b/xmloff/source/style/xmlexppr.cxx
index 291c2ee36041..bd3ee809ec1a 100644
--- a/xmloff/source/style/xmlexppr.cxx
+++ b/xmloff/source/style/xmlexppr.cxx
@@ -1005,7 +1005,7 @@ void SvXMLExportPropertyMapper::_exportXML(
sPrefix = pNamespaceMap->GetPrefixByKey( nKey );
}
// In any case, the attribute name has to be adapted.
- sNameBuffer.append(sPrefix).append(":").append(rAttribName.subView(nColonPos+1));
+ sNameBuffer.append(sPrefix + ":" + rAttribName.subView(nColonPos+1));
sAttribName = sNameBuffer.makeStringAndClear();
}
@@ -1017,9 +1017,8 @@ void SvXMLExportPropertyMapper::_exportXML(
pNamespaceMap = pNewNamespaceMap.get();
}
pNewNamespaceMap->Add( sPrefix, sNamespace );
- sNameBuffer.append( GetXMLToken(XML_XMLNS) ).append( ":" ).append( sPrefix );
- rAttrList.AddAttribute( sNameBuffer.makeStringAndClear(),
- sNamespace );
+ OUString sAttr = GetXMLToken(XML_XMLNS) + ":" + sPrefix;
+ rAttrList.AddAttribute( sAttr, sNamespace );
}
}
}
diff --git a/xmloff/source/style/xmlnumfi.cxx b/xmloff/source/style/xmlnumfi.cxx
index 8bfaf4d35464..a62133cfff99 100644
--- a/xmloff/source/style/xmlnumfi.cxx
+++ b/xmloff/source/style/xmlnumfi.cxx
@@ -1857,7 +1857,7 @@ void SvXMLNumFormatContext::AddCurrency( const OUString& rContent, LanguageType
if ( nLang != LANGUAGE_SYSTEM )
{
// '-' sign and language code in hex:
- aFormatCode.append("-").append(OUString(OUString::number(sal_uInt16(nLang), 16)).toAsciiUpperCase());
+ aFormatCode.append("-" + OUString(OUString::number(sal_uInt16(nLang), 16)).toAsciiUpperCase());
}
aFormatCode.append( ']' ); // end of "new" currency symbol
@@ -1885,7 +1885,7 @@ void SvXMLNumFormatContext::AddNfKeyword( sal_uInt16 nIndex )
if ( !bTruncate && !bHasDateTime )
{
// with truncate-on-overflow = false, add "[]" to first time part
- aFormatCode.append("[").append(sKeyword).append("]");
+ aFormatCode.append("[" + sKeyword + "]");
}
else
{
@@ -2011,7 +2011,7 @@ void SvXMLNumFormatContext::AddCondition( const sal_Int32 nIndex )
sRealCond = sRealCond.replaceAt( nPos, 1, rDecSep );
}
}
- aConditions.append("[").append(sRealCond).append("]");
+ aConditions.append("[" + sRealCond + "]");
}
const SvNumberformat* pFormat = pFormatter->GetEntry(l_nKey);
diff --git a/xmlsecurity/source/framework/saxeventkeeperimpl.cxx b/xmlsecurity/source/framework/saxeventkeeperimpl.cxx
index 41b0a89b57ad..738fec308546 100644
--- a/xmlsecurity/source/framework/saxeventkeeperimpl.cxx
+++ b/xmlsecurity/source/framework/saxeventkeeperimpl.cxx
@@ -295,15 +295,15 @@ OUString SAXEventKeeperImpl::printBufferNode(
rc.append("[B]");
}
- rc.append(" ").append(m_xXMLDocument->getNodeName(pBufferNode->getXMLElement()));
+ rc.append(" " + m_xXMLDocument->getNodeName(pBufferNode->getXMLElement()));
BufferNode* pParent = const_cast<BufferNode*>(pBufferNode->getParent());
if (pParent != nullptr)
{
- rc.append("[").append(m_xXMLDocument->getNodeName(pParent->getXMLElement())).append("]");
+ rc.append("[" + m_xXMLDocument->getNodeName(pParent->getXMLElement()) + "]");
}
- rc.append(":EC=").append(pBufferNode->printChildren()).append(" BR=");
+ rc.append(":EC=" + pBufferNode->printChildren() + " BR=");
ElementMark * pBlocker = pBufferNode->getBlocker();
if (pBlocker != nullptr)