summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
Diffstat (limited to 'svx')
-rw-r--r--svx/source/gallery2/galini.cxx6
-rw-r--r--svx/source/svdraw/svdobj.cxx3
-rw-r--r--svx/source/unodraw/unoprov.cxx7
3 files changed, 9 insertions, 7 deletions
diff --git a/svx/source/gallery2/galini.cxx b/svx/source/gallery2/galini.cxx
index d825fd1471d2..8cdfb23ae1a2 100644
--- a/svx/source/gallery2/galini.cxx
+++ b/svx/source/gallery2/galini.cxx
@@ -61,10 +61,10 @@ OUString GalleryBinaryEngineEntry::ReadStrFromIni(std::u16string_view aKeyName )
if( ( n = aKey.indexOf( '[' ) ) >= 1 )
{
- aLocale = aKey.copy( n + 1 ).trim();
- aKey = aKey.copy( 0, n ).trim();
+ aLocale = o3tl::trim(aKey.subView( n + 1 ));
+ aKey = o3tl::trim(aKey.subView( 0, n ));
if( (n = aLocale.indexOf( ']' ) ) >= 1 )
- aLocale = aLocale.copy( 0, n ).trim();
+ aLocale = o3tl::trim(aLocale.subView( 0, n ));
}
}
SAL_INFO("svx", "ini file has '" << aKey << "' [ '" << aLocale << "' ] = '" << aValue << "'");
diff --git a/svx/source/svdraw/svdobj.cxx b/svx/source/svdraw/svdobj.cxx
index 9a4964dcbaf2..f8e597b8e1d2 100644
--- a/svx/source/svdraw/svdobj.cxx
+++ b/svx/source/svdraw/svdobj.cxx
@@ -123,6 +123,7 @@
#include <svx/scene3d.hxx>
#include <rtl/character.hxx>
#include <tools/UnitConversion.hxx>
+#include <o3tl/string_view.hxx>
using namespace ::com::sun::star;
@@ -3156,7 +3157,7 @@ void SdrObject::MakeNameUnique(std::unordered_set<OUString>& rNameSet)
{
sal_Int32 nPos(sName.getLength() - 1);
while (nPos > 0 && rtl::isAsciiDigit(sName[--nPos]));
- sRootName = sName.copy(0, nPos + 1).trim();
+ sRootName = o3tl::trim(sName.subView(0, nPos + 1));
}
else
sName += " 1";
diff --git a/svx/source/unodraw/unoprov.cxx b/svx/source/unodraw/unoprov.cxx
index 4d6e56db37c0..85892826ed99 100644
--- a/svx/source/unodraw/unoprov.cxx
+++ b/svx/source/unodraw/unoprov.cxx
@@ -43,6 +43,7 @@
#include <svx/svxids.hrc>
#include <svx/svdobjkind.hxx>
#include <svx/strings.hrc>
+#include <o3tl/string_view.hxx>
#include <strings.hxx>
#include "shapeimpl.hxx"
@@ -1962,7 +1963,7 @@ static bool SvxUnoConvertResourceStringBuiltInToApi(const TranslateId* pSourceRe
break;
nLength--;
}
- OUString sStr = rString.copy(0, nLength).trim();
+ std::u16string_view sStr = o3tl::trim(rString.subView(0, nLength));
for(int i = 0; i < nCount; ++i )
{
@@ -1990,11 +1991,11 @@ static bool SvxUnoConvertResourceStringBuiltInFromApi(rtl::OUStringConstExpr con
break;
nLength--;
}
- OUString sStr = rString.copy(0, nLength).trim();
+ std::u16string_view sStr = o3tl::trim(rString.subView(0, nLength));
for(int i = 0; i < nCount; ++i )
{
- if( sStr == pSourceResIds[i] )
+ if( sStr == pSourceResIds[i].asView() )
{
OUString aReplace = SvxResId(pDestResIds[i]);
rString = rString.replaceAt( 0, OUString(pSourceResIds[i]).getLength(), aReplace );