From ab699bfdb3375f7142a50cc35322e2924c9e5945 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 15 Apr 2022 12:25:12 +0200 Subject: new loplugin:stringviewvar looks for OUString vars that can be ... that can be string_view Change-Id: I0ddf66725e08b58e866a764f57200dd188b9f639 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133066 Tested-by: Jenkins Reviewed-by: Noel Grandin --- svgio/source/svgreader/svgtextpathnode.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'svgio') diff --git a/svgio/source/svgreader/svgtextpathnode.cxx b/svgio/source/svgreader/svgtextpathnode.cxx index 3b341eea3d40..9b177383677f 100644 --- a/svgio/source/svgreader/svgtextpathnode.cxx +++ b/svgio/source/svgreader/svgtextpathnode.cxx @@ -150,10 +150,10 @@ namespace svgio::svgreader if(basegfx::fTools::more(fSnippetWidth, 0.0)) { const OUString aText(getSource().getText()); - const OUString aTrimmedChars(o3tl::trim(aText.subView(nIndex, nLength))); + const std::u16string_view aTrimmedChars(o3tl::trim(aText.subView(nIndex, nLength))); const double fEndPos(mfPosition + fSnippetWidth); - if(!aTrimmedChars.isEmpty() && (mfPosition < mfBasegfxPathLength || fEndPos > 0.0)) + if(!aTrimmedChars.empty() && (mfPosition < mfBasegfxPathLength || fEndPos > 0.0)) { const double fHalfSnippetWidth(fSnippetWidth * 0.5); -- cgit