loplugin:stringloop
resurrect the plugin and run it over the codebase Change-Id: I443a75961124aabd1e62b3c4bc166d52e4621b52 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194870 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins
This commit is contained in:
@@ -452,11 +452,11 @@ OUString ChartTest::getTitleString( const Reference<chart2::XTitled>& xTitled )
|
||||
uno::Reference<chart2::XTitle> xTitle = xTitled->getTitleObject();
|
||||
CPPUNIT_ASSERT(xTitle.is());
|
||||
const uno::Sequence<uno::Reference<chart2::XFormattedString> > aFSSeq = xTitle->getText();
|
||||
OUString aText;
|
||||
OUStringBuffer aText;
|
||||
for (auto const & fs : aFSSeq)
|
||||
aText += fs->getString();
|
||||
aText.append(fs->getString());
|
||||
|
||||
return aText;
|
||||
return aText.makeStringAndClear();
|
||||
}
|
||||
|
||||
sal_Int32 ChartTest::getNumberFormatFromAxis( const Reference<chart2::XAxis>& xAxis )
|
||||
|
||||
@@ -0,0 +1,307 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/*
|
||||
* This file is part of the LibreOffice project.
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*/
|
||||
|
||||
#include "check.hxx"
|
||||
#include "plugin.hxx"
|
||||
#include "config_clang.h"
|
||||
#include <vector>
|
||||
|
||||
/** Look for OUString/OString being appended to inside a loop, where OUStringBuffer/OStringBuffer would be a better idea
|
||||
*/
|
||||
namespace
|
||||
{
|
||||
class StringLoop : public clang::RecursiveASTVisitor<StringLoop>, public loplugin::Plugin
|
||||
{
|
||||
public:
|
||||
explicit StringLoop(loplugin::InstantiationData const& rData)
|
||||
: Plugin(rData)
|
||||
{
|
||||
}
|
||||
|
||||
void run() override;
|
||||
bool TraverseForStmt(ForStmt*);
|
||||
bool TraverseCXXForRangeStmt(CXXForRangeStmt*);
|
||||
bool TraverseDoStmt(DoStmt*);
|
||||
bool TraverseWhileStmt(WhileStmt*);
|
||||
bool VisitVarDecl(VarDecl const*);
|
||||
bool VisitCallExpr(CallExpr const*);
|
||||
|
||||
private:
|
||||
int m_insideLoop = 0;
|
||||
using VarDeclList = std::vector<VarDecl const*>;
|
||||
std::vector<VarDeclList> m_varsPerLoopLevel;
|
||||
};
|
||||
|
||||
void StringLoop::run()
|
||||
{
|
||||
// Various places are not worth changing, the code becomes too awkward
|
||||
// Just exclude stuff as I go
|
||||
StringRef fn(handler.getMainFileName());
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/bridges/"))
|
||||
return;
|
||||
if (loplugin::isSamePathname(fn, SRCDIR "/cppuhelper/source/shlib.cxx"))
|
||||
return;
|
||||
// if (loplugin::hasPathnamePrefix(fn, SRCDIR "/tools/qa/"))
|
||||
// return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.cxx"))
|
||||
return;
|
||||
if (loplugin::isSamePathname(fn, SRCDIR "/svl/source/numbers/zformat.cxx"))
|
||||
return;
|
||||
if (loplugin::isSamePathname(fn, SRCDIR "/svl/source/numbers/zforscan.cxx"))
|
||||
return;
|
||||
if (loplugin::isSamePathname(fn, SRCDIR "/vcl/source/control/combobox.cxx"))
|
||||
return;
|
||||
if (loplugin::isSamePathname(fn, SRCDIR "/vcl/source/control/calendar.cxx"))
|
||||
return;
|
||||
if (loplugin::isSamePathname(fn, SRCDIR "/vcl/source/treelist/svtabbx.cxx"))
|
||||
return;
|
||||
if (loplugin::isSamePathname(fn, SRCDIR "/vcl/source/pdf/pdfwriter_impl.cxx"))
|
||||
return;
|
||||
if (loplugin::isSamePathname(fn, SRCDIR "/vcl/jsdialog/jsdialogregister.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/idl/source/prj/command.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/framework/source/accelerators/storageholder.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/basic/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sfx2/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/connectivity/source/drivers/odbc/OConnection.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/connectivity/source/parse/sqliterator.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/editeng/source/editeng/eertfpar.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/editeng/source/rtf/svxrtf.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/svx/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/basctl/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/filter/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/hwpfilter/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/cui/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/dbaccess/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/desktop/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/extensions/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/lingucomponent/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/i18npool/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/embeddedobj/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sd/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/xmloff/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/xmlhelp/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/forms/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/core/tool/address.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/ui/view/gridwin2.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/core/tool/compiler.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/core/tool/interpr1.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/ui/docshell/impex.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/ui/miscdlgs/acredlin.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/ui/pagedlg/areasdlg.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/ui/dbgui/scuiasciiopt.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/core/data/SolverSettings.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/ui/unoobj/solveruno.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sc/source/filter/html/htmlpars.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sdext/"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/core/layout/dbg_lay.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/core/edit/edattr.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/core/tox/ToxTextGenerator.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/filter/html/parcss1.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/filter/html/svxcss1.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/core/fields/authfld.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/filter/ascii/ascatr.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/core/unocore/unosect.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/core/unocore/unoobj.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/core/edit/acorrect.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/filter/html/swhtml.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/uibase/utlui/gloslst.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/core/doc/doctxm.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/uibase/docvw/edtwin.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/filter/ww8/ww8atr.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/filter/ww8/ww8scan.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/filter/ww8/ww8par5.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/ui/fldui/fldfunc.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/ui/dbui/dbinsdlg.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/ui/index/cnttab.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/ui/dbui/mmlayoutpage.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/ui/dbui/mmresultdialogs.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/uibase/shells/textsh1.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/sw/source/uibase/utlui/content.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn,
|
||||
SRCDIR "/sw/source/writerfilter/dmapper/NumberingManager.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn,
|
||||
SRCDIR "/sw/source/writerfilter/dmapper/DomainMapper_Impl.cxx"))
|
||||
return;
|
||||
if (loplugin::hasPathnamePrefix(fn, SRCDIR "/ucb/source/ucp/file/bc.cxx"))
|
||||
return;
|
||||
|
||||
TraverseDecl(compiler.getASTContext().getTranslationUnitDecl());
|
||||
}
|
||||
|
||||
bool StringLoop::TraverseForStmt(ForStmt* stmt)
|
||||
{
|
||||
++m_insideLoop;
|
||||
m_varsPerLoopLevel.push_back({});
|
||||
auto const ret = RecursiveASTVisitor::TraverseForStmt(stmt);
|
||||
m_varsPerLoopLevel.pop_back();
|
||||
--m_insideLoop;
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool StringLoop::TraverseCXXForRangeStmt(CXXForRangeStmt* stmt)
|
||||
{
|
||||
++m_insideLoop;
|
||||
m_varsPerLoopLevel.push_back({});
|
||||
auto const ret = RecursiveASTVisitor::TraverseCXXForRangeStmt(stmt);
|
||||
m_varsPerLoopLevel.pop_back();
|
||||
--m_insideLoop;
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool StringLoop::TraverseDoStmt(DoStmt* stmt)
|
||||
{
|
||||
++m_insideLoop;
|
||||
m_varsPerLoopLevel.push_back({});
|
||||
auto const ret = RecursiveASTVisitor::TraverseDoStmt(stmt);
|
||||
m_varsPerLoopLevel.pop_back();
|
||||
--m_insideLoop;
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool StringLoop::TraverseWhileStmt(WhileStmt* stmt)
|
||||
{
|
||||
++m_insideLoop;
|
||||
m_varsPerLoopLevel.push_back({});
|
||||
auto const ret = RecursiveASTVisitor::TraverseWhileStmt(stmt);
|
||||
m_varsPerLoopLevel.pop_back();
|
||||
--m_insideLoop;
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool StringLoop::VisitVarDecl(VarDecl const* varDecl)
|
||||
{
|
||||
if (ignoreLocation(varDecl))
|
||||
return true;
|
||||
if (!m_insideLoop)
|
||||
return true;
|
||||
m_varsPerLoopLevel.back().push_back(varDecl);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool StringLoop::VisitCallExpr(CallExpr const* callExpr)
|
||||
{
|
||||
if (ignoreLocation(callExpr))
|
||||
return true;
|
||||
if (!m_insideLoop)
|
||||
return true;
|
||||
auto operatorCallExpr = dyn_cast<CXXOperatorCallExpr>(callExpr);
|
||||
if (!operatorCallExpr)
|
||||
return true;
|
||||
if (operatorCallExpr->getOperator() != OO_PlusEqual)
|
||||
return true;
|
||||
|
||||
if (auto memberExpr = dyn_cast<MemberExpr>(callExpr->getArg(0)))
|
||||
{
|
||||
auto tc = loplugin::TypeCheck(memberExpr->getType());
|
||||
if (!tc.Class("OUString").Namespace("rtl").GlobalNamespace()
|
||||
&& !tc.Class("OString").Namespace("rtl").GlobalNamespace())
|
||||
return true;
|
||||
auto fieldDecl = dyn_cast<FieldDecl>(memberExpr->getMemberDecl());
|
||||
if (isInUnoIncludeFile(
|
||||
compiler.getSourceManager().getSpellingLoc(fieldDecl->getLocation())))
|
||||
return true;
|
||||
if (ignoreLocation(compiler.getSourceManager().getSpellingLoc(fieldDecl->getLocation())))
|
||||
return true;
|
||||
report(DiagnosticsEngine::Warning,
|
||||
"appending to OUString in loop, rather use OUStringBuffer",
|
||||
operatorCallExpr->getBeginLoc())
|
||||
<< operatorCallExpr->getSourceRange();
|
||||
report(DiagnosticsEngine::Note, "field here", fieldDecl->getBeginLoc())
|
||||
<< fieldDecl->getSourceRange();
|
||||
}
|
||||
else if (auto declRefExpr = dyn_cast<DeclRefExpr>(callExpr->getArg(0)))
|
||||
{
|
||||
if (auto varDecl = dyn_cast<VarDecl>(declRefExpr->getDecl()))
|
||||
{
|
||||
auto tc = loplugin::TypeCheck(varDecl->getType());
|
||||
if (!tc.Class("OUString").Namespace("rtl").GlobalNamespace()
|
||||
&& !tc.Class("OString").Namespace("rtl").GlobalNamespace())
|
||||
return true;
|
||||
// if the var is at the same block scope as the +=, not interesting
|
||||
auto vars = m_varsPerLoopLevel.back();
|
||||
if (std::find(vars.begin(), vars.end(), varDecl) != vars.end())
|
||||
return true;
|
||||
report(DiagnosticsEngine::Warning,
|
||||
"appending to OUString in loop, rather use OUStringBuffer",
|
||||
operatorCallExpr->getBeginLoc())
|
||||
<< operatorCallExpr->getSourceRange();
|
||||
report(DiagnosticsEngine::Note, "var here", varDecl->getBeginLoc())
|
||||
<< varDecl->getSourceRange();
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/** off by default because it needs hand-holding */
|
||||
loplugin::Plugin::Registration<StringLoop> X("stringloop", false);
|
||||
|
||||
} // namespace
|
||||
|
||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
||||
@@ -0,0 +1,41 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
|
||||
/*
|
||||
* This file is part of the LibreOffice project.
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*/
|
||||
|
||||
#include "sal/config.h"
|
||||
#include "rtl/string.hxx"
|
||||
#include "rtl/ustring.hxx"
|
||||
|
||||
#pragma clang diagnostic ignored "-Wunknown-warning-option" // for Clang < 13
|
||||
#pragma clang diagnostic ignored "-Wunused-but-set-variable"
|
||||
|
||||
struct Foo
|
||||
{
|
||||
OUString m_field; // expected-note {{field here [loplugin:stringloop]}}
|
||||
void func1()
|
||||
{
|
||||
for (int i = 0; i < 10; ++i)
|
||||
m_field += "xxx";
|
||||
// expected-error@-1 {{appending to OUString in loop, rather use OUStringBuffer [loplugin:stringloop]}}
|
||||
// no warning expected
|
||||
m_field += "xxx";
|
||||
}
|
||||
};
|
||||
|
||||
void func2()
|
||||
{
|
||||
OUString s; // expected-note {{var here [loplugin:stringloop]}}
|
||||
for (int i = 0; i < 10; ++i)
|
||||
s += "xxx"; // expected-error {{appending to OUString in loop, rather use OUStringBuffer [loplugin:stringloop]}}
|
||||
|
||||
// no warning expected
|
||||
OUString s2;
|
||||
s2 += "xxx";
|
||||
}
|
||||
|
||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
|
||||
@@ -672,7 +672,7 @@ void TPGalleryThemeProperties::FillFilterList()
|
||||
aName = rFilter.GetImportFormatName( i );
|
||||
bool bInList = false;
|
||||
|
||||
OUString aExtensions;
|
||||
OUStringBuffer aExtensions;
|
||||
int j = 0;
|
||||
OUString sWildcard;
|
||||
while( true )
|
||||
@@ -683,8 +683,8 @@ void TPGalleryThemeProperties::FillFilterList()
|
||||
if ( aExtensions.indexOf( sWildcard ) == -1 )
|
||||
{
|
||||
if ( !aExtensions.isEmpty() )
|
||||
aExtensions += ";";
|
||||
aExtensions += sWildcard;
|
||||
aExtensions.append(";");
|
||||
aExtensions.append(sWildcard);
|
||||
}
|
||||
}
|
||||
aName = addExtension( aName, aExtensions );
|
||||
@@ -720,7 +720,7 @@ void TPGalleryThemeProperties::FillFilterList()
|
||||
#endif
|
||||
|
||||
// 'All' filters
|
||||
OUString aExtensions;
|
||||
OUStringBuffer aExtensions;
|
||||
|
||||
// graphic filters
|
||||
for ( i = 0; i < nKeyCount; ++i )
|
||||
@@ -735,9 +735,9 @@ void TPGalleryThemeProperties::FillFilterList()
|
||||
if ( aExtensions.indexOf( sWildcard ) == -1 )
|
||||
{
|
||||
if ( !aExtensions.isEmpty() )
|
||||
aExtensions += ";";
|
||||
aExtensions.append(";");
|
||||
|
||||
aExtensions += sWildcard;
|
||||
aExtensions.append(sWildcard);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -749,8 +749,8 @@ void TPGalleryThemeProperties::FillFilterList()
|
||||
for( sal_Int32 nIndex = 0; nIndex >= 0; )
|
||||
{
|
||||
if ( !aExtensions.isEmpty() )
|
||||
aExtensions += ";";
|
||||
aExtensions += OUString::Concat(aWildcard) + o3tl::getToken(aFilter.second, 0, ';', nIndex );
|
||||
aExtensions.append(";");
|
||||
aExtensions.append(OUString::Concat(aWildcard) + o3tl::getToken(aFilter.second, 0, ';', nIndex ));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
#include <dialmgr.hxx>
|
||||
#include <editeng/editids.hrc>
|
||||
#include <officecfg/Office/Common.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <strings.hrc>
|
||||
#include <sfx2/AdditionsDialogHelper.hxx>
|
||||
#include <svtools/colorcfg.hxx>
|
||||
@@ -177,17 +178,17 @@ std::unique_ptr<SfxTabPage> SvxAppearanceTabPage::Create(weld::Container* pPage,
|
||||
|
||||
OUString SvxAppearanceTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"libreofficethemeslb"_ustr, u"optionslb"_ustr, u"appearancelb"_ustr,
|
||||
u"itemslb"_ustr, u"colorlb"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxAppearanceTabPage::FillItemSet(SfxItemSet* /* rSet */)
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
#include <osl/diagnose.h>
|
||||
#include "connpooloptions.hxx"
|
||||
#include "connpoolsettings.hxx"
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <svl/eitem.hxx>
|
||||
#include <svx/databaseregistrationui.hxx>
|
||||
#include <strings.hrc>
|
||||
@@ -173,13 +174,13 @@ namespace offapp
|
||||
|
||||
OUString ConnectionPoolOptionsPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"driverslabel"_ustr, u"driverlabel"_ustr, u"timeoutlabel"_ustr, u"driver"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"connectionpooling"_ustr, u"enablepooling"_ustr };
|
||||
@@ -187,10 +188,10 @@ namespace offapp
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ConnectionPoolOptionsPage::FillItemSet(SfxItemSet* _rSet)
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#include <svtools/fontsubstconfig.hxx>
|
||||
#include "fontsubs.hxx"
|
||||
#include <helpids.h>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
/*********************************************************************/
|
||||
/* */
|
||||
@@ -148,13 +149,13 @@ std::unique_ptr<SfxTabPage> SvxFontSubstTabPage::Create( weld::Container* pPage,
|
||||
|
||||
OUString SvxFontSubstTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label4"_ustr, u"label2"_ustr, u"label3"_ustr, u"label1"_ustr, u"label8"_ustr, u"label9"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"usetable"_ustr, u"nonpropfontonly"_ustr };
|
||||
@@ -162,10 +163,10 @@ OUString SvxFontSubstTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxFontSubstTabPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <officecfg/Office/Common.hxx>
|
||||
#include <unotools/resmgr.hxx>
|
||||
#include <dialmgr.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
namespace
|
||||
{
|
||||
@@ -113,7 +114,7 @@ std::unique_ptr<SfxTabPage> SvxAccessibilityOptionsTabPage::Create(weld::Contain
|
||||
|
||||
OUString SvxAccessibilityOptionsTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label13"_ustr,
|
||||
u"animationframelabel"_ustr, u"animatedgraphiclabel"_ustr, u"animatedtextlabel"_ustr,
|
||||
u"animatedotherslabel"_ustr, u"label11"_ustr };
|
||||
@@ -121,7 +122,7 @@ OUString SvxAccessibilityOptionsTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"textselinreadonly"_ustr,
|
||||
@@ -130,10 +131,10 @@ OUString SvxAccessibilityOptionsTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxAccessibilityOptionsTabPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
|
||||
#include <com/sun/star/i18n/XForbiddenCharacters.hpp>
|
||||
#include <com/sun/star/beans/XPropertySet.hpp>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <sfx2/viewfrm.hxx>
|
||||
#include <sfx2/objsh.hxx>
|
||||
#include <vcl/svapp.hxx>
|
||||
@@ -143,14 +144,14 @@ std::unique_ptr<SfxTabPage> SvxAsianLayoutPage::Create(weld::Container* pPage, w
|
||||
|
||||
OUString SvxAsianLayoutPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[]
|
||||
= { u"label1"_ustr, u"label2"_ustr, u"label3"_ustr, u"languageft"_ustr, u"startft"_ustr, u"endft"_ustr, u"hintft"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"charkerning"_ustr, u"charpunctkerning"_ustr, u"nocompression"_ustr,
|
||||
@@ -159,12 +160,12 @@ OUString SvxAsianLayoutPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
sAllStrings += m_xStandardCB->get_label() + " ";
|
||||
sAllStrings.append(m_xStandardCB->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxAsianLayoutPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
#include "optbasic.hxx"
|
||||
#include <basic/codecompletecache.hxx>
|
||||
#include <officecfg/Office/BasicIDE.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
SvxBasicIDEOptionsPage::SvxBasicIDEOptionsPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rSet)
|
||||
: SfxTabPage(pPage, pController, u"cui/ui/optbasicidepage.ui"_ustr, u"OptBasicIDEPage"_ustr, &rSet)
|
||||
@@ -55,13 +56,13 @@ void SvxBasicIDEOptionsPage::LoadConfig()
|
||||
|
||||
OUString SvxBasicIDEOptionsPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label3"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"codecomplete_enable"_ustr, u"autocorrect"_ustr, u"autoclose_quotes"_ustr,
|
||||
@@ -70,10 +71,10 @@ OUString SvxBasicIDEOptionsPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxBasicIDEOptionsPage::FillItemSet( SfxItemSet* /*rCoreSet*/ )
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
|
||||
#include "optchart.hxx"
|
||||
#include <svx/SvxColorValueSet.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <vcl/virdev.hxx>
|
||||
#include <vcl/weld.hxx>
|
||||
#include <vcl/settings.hxx>
|
||||
@@ -189,13 +190,13 @@ std::unique_ptr<SfxTabPage> SvxDefaultColorOptPage::Create( weld::Container* pPa
|
||||
|
||||
OUString SvxDefaultColorOptPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label20"_ustr, u"label1"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString buttons[] = { u"add"_ustr, u"delete"_ustr, u"default"_ustr };
|
||||
@@ -203,10 +204,10 @@ OUString SvxDefaultColorOptPage::GetAllStrings()
|
||||
for (const auto& btn : buttons)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_button(btn))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxDefaultColorOptPage::FillItemSet( SfxItemSet* rOutAttrs )
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
*/
|
||||
|
||||
#include "optctl.hxx"
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <svl/ctloptions.hxx>
|
||||
#include <sal/log.hxx>
|
||||
#include <tools/debug.hxx>
|
||||
@@ -60,13 +61,13 @@ std::unique_ptr<SfxTabPage> SvxCTLOptionsPage::Create( weld::Container* pPage, w
|
||||
|
||||
OUString SvxCTLOptionsPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label3"_ustr, u"label4"_ustr, u"label5"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"sequencechecking"_ustr, u"restricted"_ustr, u"typeandreplace"_ustr };
|
||||
@@ -74,7 +75,7 @@ OUString SvxCTLOptionsPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"movementlogical"_ustr, u"movementvisual"_ustr };
|
||||
@@ -82,10 +83,10 @@ OUString SvxCTLOptionsPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxCTLOptionsPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
|
||||
#include "optdeepl.hxx"
|
||||
#include <officecfg/Office/Linguistic.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
OptDeeplTabPage::OptDeeplTabPage(weld::Container* pPage, weld::DialogController* pController,
|
||||
const SfxItemSet& rSet)
|
||||
@@ -45,19 +46,19 @@ void OptDeeplTabPage::Reset(const SfxItemSet*)
|
||||
|
||||
OUString OptDeeplTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label3"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
if (const auto pString = m_xBuilder->weld_link_button(u"privacy"_ustr))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool OptDeeplTabPage::FillItemSet(SfxItemSet*)
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <officecfg/Office/Calc.hxx>
|
||||
#include <officecfg/Office/Writer.hxx>
|
||||
#include <officecfg/Office/Impress.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include "optfltr.hxx"
|
||||
#include <strings.hrc>
|
||||
#include <dialmgr.hxx>
|
||||
@@ -85,13 +86,13 @@ std::unique_ptr<SfxTabPage> OfaMSFilterTabPage::Create( weld::Container* pPage,
|
||||
|
||||
OUString OfaMSFilterTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label3"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"wo_basic"_ustr, u"wo_exec"_ustr, u"wo_saveorig"_ustr, u"ex_basic"_ustr,
|
||||
@@ -100,10 +101,10 @@ OUString OfaMSFilterTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool OfaMSFilterTabPage::FillItemSet( SfxItemSet* )
|
||||
@@ -211,13 +212,13 @@ std::unique_ptr<SfxTabPage> OfaMSFilterTabPage2::Create( weld::Container* pPage,
|
||||
|
||||
OUString OfaMSFilterTabPage2::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label3"_ustr, u"label4"_ustr, u"label5"_ustr, u"label6"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"highlighting"_ustr, u"shading"_ustr };
|
||||
@@ -225,12 +226,12 @@ OUString OfaMSFilterTabPage2::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
sAllStrings += m_xMSOLockFileCB->get_label() + " ";
|
||||
sAllStrings.append(m_xMSOLockFileCB->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
namespace
|
||||
|
||||
@@ -218,14 +218,14 @@ std::unique_ptr<SfxTabPage> OfaMiscTabPage::Create( weld::Container* pPage, weld
|
||||
|
||||
OUString OfaMiscTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label4"_ustr, u"label5"_ustr, u"yearslabel"_ustr,
|
||||
u"toyear"_ustr, u"label8"_ustr, u"label9"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -235,13 +235,13 @@ OUString OfaMiscTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
if (const auto pString = m_xBuilder->weld_button(u"assocfiles"_ustr))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool OfaMiscTabPage::FillItemSet( SfxItemSet* rSet )
|
||||
@@ -649,7 +649,7 @@ std::unique_ptr<SfxTabPage> OfaViewTabPage::Create( weld::Container* pPage, weld
|
||||
|
||||
OUString OfaViewTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label16"_ustr, u"label1"_ustr, u"label6"_ustr, u"label15"_ustr,
|
||||
u"label14"_ustr, u"label8"_ustr, u"label9"_ustr, u"label4"_ustr, u"label12"_ustr,
|
||||
u"label2"_ustr, u"skiaenabled"_ustr, u"skiadisabled"_ustr, u"label5"_ustr, u"aafrom"_ustr };
|
||||
@@ -657,7 +657,7 @@ OUString OfaViewTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -666,12 +666,12 @@ OUString OfaViewTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
sAllStrings += m_xSkiaLog->get_label() + " " + m_xRunGPTests->get_label() + " ";
|
||||
sAllStrings.append(m_xSkiaLog->get_label() + " " + m_xRunGPTests->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool OfaViewTabPage::FillItemSet( SfxItemSet* )
|
||||
@@ -1071,7 +1071,7 @@ std::unique_ptr<SfxTabPage> OfaLanguagesTabPage::Create( weld::Container* pPage,
|
||||
|
||||
OUString OfaLanguagesTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[]
|
||||
= { u"label1"_ustr, u"label4"_ustr, u"label7"_ustr, u"localesettingFT"_ustr, u"defaultcurrency"_ustr,
|
||||
u"label6"_ustr, u"dataaccpatterns"_ustr, u"label2"_ustr, u"western"_ustr, u"label3"_ustr };
|
||||
@@ -1079,7 +1079,7 @@ OUString OfaLanguagesTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -1088,10 +1088,10 @@ OUString OfaLanguagesTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool OfaLanguagesTabPage::FillItemSet( SfxItemSet* rSet )
|
||||
|
||||
@@ -404,7 +404,7 @@ std::unique_ptr<SfxTabPage> SvxGeneralTabPage::Create( weld::Container* pPage, w
|
||||
|
||||
OUString SvxGeneralTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[]
|
||||
= { u"label1"_ustr, u"companyft"_ustr, u"nameft"_ustr, u"rusnameft"_ustr,
|
||||
u"eastnameft"_ustr, u"streetft"_ustr, u"russtreetft"_ustr, u"icityft"_ustr,
|
||||
@@ -414,12 +414,12 @@ OUString SvxGeneralTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
sAllStrings += m_xUseDataCB->get_label() + " " + m_xEncryptToSelfCB->get_label() + " ";
|
||||
sAllStrings.append(m_xUseDataCB->get_label() + " " + m_xEncryptToSelfCB->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxGeneralTabPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
#include <comphelper/configuration.hxx>
|
||||
#include <officecfg/Office/Common.hxx>
|
||||
#include "opthtml.hxx"
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
|
||||
OfaHtmlTabPage::OfaHtmlTabPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rSet)
|
||||
@@ -83,14 +84,14 @@ std::unique_ptr<SfxTabPage> OfaHtmlTabPage::Create( weld::Container* pPage, weld
|
||||
|
||||
OUString OfaHtmlTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label3"_ustr, u"size1FT"_ustr, u"size2FT"_ustr,
|
||||
u"size3FT"_ustr, u"size4FT"_ustr, u"size5FT"_ustr, u"size6FT"_ustr, u"size7FT"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"numbersenglishus"_ustr, u"unknowntag"_ustr, u"ignorefontnames"_ustr, u"starbasic"_ustr,
|
||||
@@ -99,10 +100,10 @@ OUString OfaHtmlTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool OfaHtmlTabPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -310,17 +310,17 @@ void SvxProxyTabPage::Reset(const SfxItemSet*)
|
||||
|
||||
OUString SvxProxyTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"httpft"_ustr, u"httpsft"_ustr,
|
||||
u"noproxyft"_ustr, u"httpportft"_ustr, u"httpsportft"_ustr, u"noproxydesc"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxProxyTabPage::FillItemSet(SfxItemSet* )
|
||||
@@ -835,7 +835,7 @@ DeactivateRC SvxSecurityTabPage::DeactivatePage( SfxItemSet* _pSet )
|
||||
|
||||
OUString SvxSecurityTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label4"_ustr, u"label2"_ustr, u"masterpasswordtext"_ustr,
|
||||
u"nopasswordsave"_ustr, u"label3"_ustr, u"label5"_ustr, u"label8"_ustr,
|
||||
u"label7"_ustr, u"label10"_ustr, u"label9"_ustr, u"label12"_ustr,
|
||||
@@ -844,7 +844,7 @@ OUString SvxSecurityTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"savepassword"_ustr, u"usemasterpassword"_ustr };
|
||||
@@ -852,7 +852,7 @@ OUString SvxSecurityTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
// TODO: Should we exclude button strings from the search?
|
||||
@@ -862,10 +862,10 @@ OUString SvxSecurityTabPage::GetAllStrings()
|
||||
for (const auto& btn : buttons)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_button(btn))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxSecurityTabPage::FillItemSet( SfxItemSet* )
|
||||
@@ -945,16 +945,16 @@ std::unique_ptr<SfxTabPage> SvxEMailTabPage::Create( weld::Container* pPage, wel
|
||||
|
||||
OUString SvxEMailTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"browsetitle"_ustr, u"suppress"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
/* -------------------------------------------------------------------------*/
|
||||
|
||||
@@ -476,13 +476,13 @@ std::unique_ptr<SfxTabPage> SvxJavaOptionsPage::Create(weld::Container* pPage, w
|
||||
|
||||
OUString SvxJavaOptionsPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"javapath"_ustr, u"selectruntime"_ustr, u"label12"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"javaenabled"_ustr, u"experimental"_ustr, u"macrorecording"_ustr };
|
||||
@@ -490,7 +490,7 @@ OUString SvxJavaOptionsPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString buttons[] = { u"add"_ustr, u"parameters"_ustr, u"classpath"_ustr, u"expertconfig"_ustr };
|
||||
@@ -498,10 +498,10 @@ OUString SvxJavaOptionsPage::GetAllStrings()
|
||||
for (const auto& btn : buttons)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_button(btn))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxJavaOptionsPage::FillItemSet( SfxItemSet* /*rCoreSet*/ )
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
#include <tools/debug.hxx>
|
||||
#include <unotools/searchopt.hxx>
|
||||
#include <i18nutil/transliteration.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include "optjsearch.hxx"
|
||||
|
||||
|
||||
@@ -201,13 +202,13 @@ void SvxJSearchOptionsPage::Reset( const SfxItemSet* )
|
||||
|
||||
OUString SvxJSearchOptionsPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"matchcase"_ustr,
|
||||
@@ -233,10 +234,10 @@ OUString SvxJSearchOptionsPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxJSearchOptionsPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
|
||||
#include "optlanguagetool.hxx"
|
||||
#include <officecfg/Office/Linguistic.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <dialmgr.hxx>
|
||||
#include <strings.hrc>
|
||||
|
||||
@@ -111,7 +112,7 @@ void OptLanguageToolTabPage::Reset(const SfxItemSet*)
|
||||
|
||||
OUString OptLanguageToolTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = {
|
||||
u"langtoolsettings"_ustr, u"disclaimer"_ustr, u"apisettingsheader"_ustr, u"base"_ustr,
|
||||
u"urldesc"_ustr, u"usernamelbl"_ustr, u"usernamedesc"_ustr, u"apikeylbl"_ustr,
|
||||
@@ -121,7 +122,7 @@ OUString OptLanguageToolTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"activate"_ustr, u"verifyssl"_ustr };
|
||||
@@ -129,13 +130,13 @@ OUString OptLanguageToolTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
if (const auto pString = m_xBuilder->weld_link_button(u"policy"_ustr))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool OptLanguageToolTabPage::FillItemSet(SfxItemSet*)
|
||||
|
||||
@@ -878,18 +878,18 @@ std::unique_ptr<SfxTabPage> SvxLinguTabPage::Create( weld::Container* pPage, wel
|
||||
|
||||
OUString SvxLinguTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"lingumodulesft"_ustr, u"lingudictsft"_ustr, u"label4"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
sAllStrings += m_xMoreDictsLink->get_label() + " ";
|
||||
sAllStrings.append(m_xMoreDictsLink->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxLinguTabPage::FillItemSet( SfxItemSet* rCoreSet )
|
||||
|
||||
@@ -42,6 +42,7 @@
|
||||
#include <sfx2/docfilt.hxx>
|
||||
#include <tools/debug.hxx>
|
||||
#include <osl/diagnose.h>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <comphelper/diagnose_ex.hxx>
|
||||
#include <officecfg/Office/Recovery.hxx>
|
||||
#include <unotools/confignode.hxx>
|
||||
@@ -223,14 +224,14 @@ std::unique_ptr<SfxTabPage> SvxSaveTabPage::Create(weld::Container* pPage, weld:
|
||||
|
||||
OUString SvxSaveTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"autosave_mins"_ustr, u"label3"_ustr,
|
||||
u"label5"_ustr, u"label6"_ustr, u"saveas_label"_ustr, u"odfwarning_label"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -241,10 +242,10 @@ OUString SvxSaveTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxSaveTabPage::FillItemSet( SfxItemSet* rSet )
|
||||
|
||||
@@ -197,21 +197,20 @@ void SvxOnlineUpdateTabPage::UpdateLastCheckedText()
|
||||
|
||||
static inline OUString WrapString(const OUString& aStr)
|
||||
{
|
||||
OUString sResult;
|
||||
OUString sPos;
|
||||
OUStringBuffer sResult;
|
||||
int nPos = 0;
|
||||
for (int i = 0; i < aStr.getLength(); i++)
|
||||
{
|
||||
sPos = aStr.subView(i, 1);
|
||||
sResult += sPos;
|
||||
if ((nPos > 50) && (sPos == ";"))
|
||||
std::u16string_view sPos = aStr.subView(i, 1);
|
||||
sResult.append(sPos);
|
||||
if ((nPos > 50) && (sPos == u";"))
|
||||
{
|
||||
sResult += "\n";
|
||||
sResult.append("\n");
|
||||
nPos = 0;
|
||||
}
|
||||
nPos++;
|
||||
}
|
||||
return sResult;
|
||||
return sResult.toString();
|
||||
}
|
||||
|
||||
void SvxOnlineUpdateTabPage::UpdateUserAgent()
|
||||
@@ -249,14 +248,14 @@ std::unique_ptr<SfxTabPage> SvxOnlineUpdateTabPage::Create( weld::Container* pPa
|
||||
|
||||
OUString SvxOnlineUpdateTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"lastchecked"_ustr, u"neverchecked"_ustr, u"labeldest"_ustr,
|
||||
u"destpathlabel"_ustr, u"labelagent"_ustr, u"useragent_label"_ustr, u"useragent_changed"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"autocheck"_ustr, u"autodownload"_ustr, u"extrabits"_ustr };
|
||||
@@ -264,7 +263,7 @@ OUString SvxOnlineUpdateTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"everyday"_ustr, u"everyweek"_ustr, u"everymonth"_ustr };
|
||||
@@ -272,13 +271,13 @@ OUString SvxOnlineUpdateTabPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
// some buttons are not included
|
||||
sAllStrings += m_xPrivacyPolicyButton->get_label() + " ";
|
||||
sAllStrings.append(m_xPrivacyPolicyButton->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxOnlineUpdateTabPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include <svx/xbtmpit.hxx>
|
||||
#include <svx/xgrscit.hxx>
|
||||
#include <cuitabarea.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <sfx2/tabdlg.hxx>
|
||||
#include <unotools/pathoptions.hxx>
|
||||
|
||||
@@ -273,17 +274,17 @@ bool SvxAreaTabPage::FillItemSet_Impl( SfxItemSet* rAttrs)
|
||||
|
||||
OUString SvxAreaTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString toggleButton[] = { u"btnnone"_ustr, u"btncolor"_ustr, u"btngradient"_ustr, u"btnbitmap"_ustr,
|
||||
u"btnpattern"_ustr, u"btnhatch"_ustr, u"btnusebackground"_ustr };
|
||||
|
||||
for (const auto& toggle : toggleButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_toggle_button(toggle))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxAreaTabPage::FillItemSet( SfxItemSet* rAttrs )
|
||||
|
||||
@@ -583,8 +583,7 @@ void fillTypeInfo( const Reference< css::sdbc::XConnection>& _rxConnection,
|
||||
}
|
||||
if ( !aName.empty() )
|
||||
{
|
||||
pInfo->aUIName = aName;
|
||||
pInfo->aUIName += " [ ";
|
||||
pInfo->aUIName = OUString::Concat(aName) + " [ ";
|
||||
}
|
||||
pInfo->aUIName += pInfo->aTypeName;
|
||||
if ( !aName.empty() )
|
||||
|
||||
@@ -4744,18 +4744,18 @@ static void doc_registerCallback(LibreOfficeKitDocument* pThis,
|
||||
|
||||
if (!pDocument->maFontsMissing.empty())
|
||||
{
|
||||
OString sPayload = "{ \"fontsmissing\": [ "_ostr;
|
||||
OStringBuffer sPayload("{ \"fontsmissing\": [ ");
|
||||
bool bFirst = true;
|
||||
for (const auto &f : pDocument->maFontsMissing)
|
||||
{
|
||||
if (bFirst)
|
||||
bFirst = false;
|
||||
else
|
||||
sPayload += ", ";
|
||||
sPayload += "\"" + f.toUtf8() + "\"";
|
||||
sPayload.append(", ");
|
||||
sPayload.append("\"" + f.toUtf8() + "\"");
|
||||
}
|
||||
sPayload += " ] }";
|
||||
pCallback(LOK_CALLBACK_FONTS_MISSING, sPayload.getStr(), pData);
|
||||
sPayload.append(" ] }");
|
||||
pCallback(LOK_CALLBACK_FONTS_MISSING, sPayload.toString().getStr(), pData);
|
||||
pDocument->maFontsMissing.clear();
|
||||
}
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
#include <basegfx/polygon/b2dpolygontools.hxx>
|
||||
#include <basegfx/polygon/b2dpolypolygoncutter.hxx>
|
||||
#include <emfreader.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <sal/log.hxx>
|
||||
#include <osl/diagnose.h>
|
||||
#include <vcl/dibtools.hxx>
|
||||
@@ -442,7 +443,7 @@ namespace emfio
|
||||
sal_uInt32 nDescChars(0);
|
||||
mpInputStream->ReadUInt32(nDescChars);
|
||||
|
||||
OUString aDesc;
|
||||
OUStringBuffer aDesc;
|
||||
for (sal_uInt32 i=0; i < nDescChars; i++)
|
||||
{
|
||||
sal_uInt16 cChar(0);
|
||||
@@ -451,10 +452,10 @@ namespace emfio
|
||||
break;
|
||||
|
||||
sal_Unicode cUniChar = static_cast<sal_Unicode>(cChar);
|
||||
aDesc += OUStringChar(cUniChar);
|
||||
aDesc.append(OUStringChar(cUniChar));
|
||||
}
|
||||
|
||||
SAL_INFO("emfio", "\t\tDescription: " << aDesc);
|
||||
SAL_INFO("emfio", "\t\tDescription: " << aDesc.toString());
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -2186,18 +2187,18 @@ namespace emfio
|
||||
sal_Int32 ihCS(0);
|
||||
mpInputStream->ReadInt32(ihCS);
|
||||
sal_Int32 nDescChars = nRemainingRecSize - 4;
|
||||
OUString aDesc;
|
||||
OUStringBuffer aDesc;
|
||||
for (sal_Int32 i=0; i < nDescChars; i++)
|
||||
{
|
||||
unsigned char cChar(0);
|
||||
mpInputStream->ReadUChar(cChar);
|
||||
if (cChar == 0)
|
||||
break;
|
||||
aDesc += OUStringChar(static_cast<sal_Unicode>(cChar));
|
||||
aDesc.append(OUStringChar(static_cast<sal_Unicode>(cChar)));
|
||||
}
|
||||
// if it's the standard color space name, no need to do anything
|
||||
if (aDesc != "COSP")
|
||||
SAL_WARN("emfio", "TODO: color space change for EMR_CREATECOLORSPACE not implemented: '" << aDesc << "' " << nDescChars);
|
||||
if (std::u16string_view(aDesc) != u"COSP")
|
||||
SAL_WARN("emfio", "TODO: color space change for EMR_CREATECOLORSPACE not implemented: '" << aDesc.toString() << "' " << nDescChars);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -568,7 +568,7 @@ static EquationResult Read_SubF_Combined(WW8ReadFieldParams& rReadParam)
|
||||
{
|
||||
EquationResult aResult;
|
||||
|
||||
OUString sCombinedCharacters;
|
||||
OUStringBuffer sCombinedCharacters;
|
||||
WW8ReadFieldParams aOriFldParam = rReadParam;
|
||||
const sal_Int32 cGetChar = rReadParam.SkipToNextToken();
|
||||
switch( cGetChar )
|
||||
@@ -607,8 +607,8 @@ static EquationResult Read_SubF_Combined(WW8ReadFieldParams& rReadParam)
|
||||
|
||||
if (nBegin != -1 && nEnd != -1)
|
||||
{
|
||||
sCombinedCharacters +=
|
||||
sPart.subView(nBegin+1,nEnd-nBegin-1);
|
||||
sCombinedCharacters.append(
|
||||
sPart.subView(nBegin+1,nEnd-nBegin-1));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -641,7 +641,7 @@ static EquationResult Read_SubF_Combined(WW8ReadFieldParams& rReadParam)
|
||||
else
|
||||
break;
|
||||
}
|
||||
sCombinedCharacters = sPart.copy( nBegin+1, nEnd-nBegin-1 );
|
||||
sCombinedCharacters = sPart.subView( nBegin+1, nEnd-nBegin-1 );
|
||||
if ( !sCombinedCharacters.isEmpty() )
|
||||
{
|
||||
aResult.sType = "Input";
|
||||
|
||||
@@ -1066,10 +1066,10 @@ IMPL_LINK(SvtFileView, HeaderSelect_Impl, int, nColumn, void)
|
||||
OUString SvtFileView::GetConfigString() const
|
||||
{
|
||||
// sort order
|
||||
OUString sRet = OUString::number( mpImpl->mnSortColumn ) + ";";
|
||||
OUStringBuffer sRet = OUString::number( mpImpl->mnSortColumn ) + ";";
|
||||
|
||||
bool bUp = mpImpl->mbAscending;
|
||||
sRet += OUString::Concat(bUp ? std::u16string_view(u"1") : std::u16string_view(u"0")) + ";";
|
||||
sRet.append(OUString::Concat(bUp ? std::u16string_view(u"1") : std::u16string_view(u"0")) + ";");
|
||||
|
||||
weld::TreeView* pView = mpImpl->mxView->getWidget();
|
||||
sal_uInt16 nCount = mpImpl->mxView->TypeColumnVisible() ? 4 : 3;
|
||||
@@ -1080,13 +1080,13 @@ OUString SvtFileView::GetConfigString() const
|
||||
if (!mpImpl->mxView->TypeColumnVisible() && nId != COLUMN_TITLE)
|
||||
++nId;
|
||||
|
||||
sRet += OUString::number( nId )
|
||||
sRet.append(OUString::number( nId )
|
||||
+ ";"
|
||||
+ OUString::number(pView->get_column_width(i))
|
||||
+ ";";
|
||||
+ ";");
|
||||
}
|
||||
|
||||
return comphelper::string::stripEnd(sRet, ';');
|
||||
return comphelper::string::stripEnd(sRet.toString(), ';');
|
||||
}
|
||||
|
||||
::std::vector< SvtContentEntry > SvtFileView::GetContent()
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
#include <rtl/bootstrap.hxx>
|
||||
#include <rtl/ref.hxx>
|
||||
#include <rtl/ustring.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <osl/diagnose.h>
|
||||
#include <osl/file.hxx>
|
||||
#ifdef _WIN32
|
||||
@@ -233,18 +234,18 @@ javaFrameworkError jfw_startVM(
|
||||
// Expand user classpath (might contain bootstrap vars)
|
||||
const OUString& sUserPath(settings.getUserClassPath());
|
||||
std::vector paths = jfw_convertUserPathList(sUserPath);
|
||||
OUString sUserPathExpanded;
|
||||
OUStringBuffer sUserPathExpanded;
|
||||
for (auto& path : paths)
|
||||
{
|
||||
if (!sUserPathExpanded.isEmpty())
|
||||
sUserPathExpanded += OUStringChar(SAL_PATHSEPARATOR);
|
||||
sUserPathExpanded.append(OUStringChar(SAL_PATHSEPARATOR));
|
||||
if (path.startsWith("$"))
|
||||
{
|
||||
OUString sURL = path;
|
||||
rtl::Bootstrap::expandMacros(sURL);
|
||||
osl::FileBase::getSystemPathFromFileURL(sURL, path);
|
||||
}
|
||||
sUserPathExpanded += path;
|
||||
sUserPathExpanded.append(path);
|
||||
}
|
||||
sUserClassPath = jfw::makeClassPathOption(sUserPathExpanded);
|
||||
} // end mode FWK_MODE_OFFICE
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
#include <rtl/strbuf.hxx>
|
||||
#include <osl/diagnose.h>
|
||||
#include <oox/helper/textinputstream.hxx>
|
||||
#include <o3tl/string_view.hxx>
|
||||
|
||||
namespace oox::vml {
|
||||
|
||||
@@ -354,20 +355,20 @@ void InputStream::updateBuffer()
|
||||
if( bHasOpeningBracket && !mxTextStrm->isEOF() )
|
||||
{
|
||||
// read the element text (add the leading opening bracket manually)
|
||||
OString aElement = "<" + readToElementEnd();
|
||||
OStringBuffer aElement = "<" + readToElementEnd();
|
||||
// check for CDATA part, starting with '<![CDATA['
|
||||
if( aElement.match( gaOpeningCData ) )
|
||||
if( o3tl::starts_with(aElement, gaOpeningCData) )
|
||||
{
|
||||
// search the end tag ']]>'
|
||||
while( ((aElement.getLength() < gaClosingCData.getLength()) || !aElement.endsWith( gaClosingCData )) && !mxTextStrm->isEOF() )
|
||||
aElement += readToElementEnd();
|
||||
while( ((aElement.getLength() < gaClosingCData.getLength()) || !o3tl::ends_with(aElement, gaClosingCData)) && !mxTextStrm->isEOF() )
|
||||
aElement.append(readToElementEnd());
|
||||
// copy the entire CDATA part
|
||||
aBuffer.append( aElement );
|
||||
}
|
||||
else
|
||||
{
|
||||
// no CDATA part - process the contents of the element
|
||||
lclProcessElement( aBuffer, aElement );
|
||||
lclProcessElement( aBuffer, aElement.toString() );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -148,7 +148,7 @@ void SAL_CALL TestDocumentHandler::endDocument()
|
||||
|
||||
void SAL_CALL TestDocumentHandler::startElement( const OUString& aName, const Reference< XAttributeList >& xAttribs )
|
||||
{
|
||||
OUString sAttributes;
|
||||
OUStringBuffer sAttributes;
|
||||
m_aCountStack.push(0);
|
||||
sal_uInt16 len = xAttribs->getLength();
|
||||
for (sal_uInt16 i=0; i<len; i++)
|
||||
@@ -156,7 +156,7 @@ void SAL_CALL TestDocumentHandler::startElement( const OUString& aName, const Re
|
||||
OUString sAttrValue = xAttribs->getValueByIndex(i);
|
||||
OUString sAttrName = canonicalform(xAttribs->getNameByIndex(i), sAttrValue, false);
|
||||
if (!sAttrName.isEmpty())
|
||||
sAttributes += sAttrName + sAttrValue;
|
||||
sAttributes.append(sAttrName + sAttrValue);
|
||||
}
|
||||
m_aStr.append(canonicalform(aName, u""_ustr, true) + sAttributes);
|
||||
}
|
||||
|
||||
@@ -70,8 +70,8 @@ bool FunctionsTest::load(const OUString& rFilter, const OUString& rURL,
|
||||
continue;
|
||||
if (!rtl::math::approxEqual(1.0, rDoc.GetValue(nCorrectCol, row, tab)))
|
||||
{
|
||||
OUString result;
|
||||
OUString expected;
|
||||
OUStringBuffer result;
|
||||
OUStringBuffer expected;
|
||||
for (SCCOL nOffset = 0; nOffset < nExpectedCol; ++ nOffset)
|
||||
{
|
||||
if (rDoc.HasValueData(nExpectedCol + nOffset, row, tab))
|
||||
@@ -80,20 +80,20 @@ bool FunctionsTest::load(const OUString& rFilter, const OUString& rURL,
|
||||
// rounds to 15 decimals
|
||||
char buf[25];
|
||||
int len = snprintf(buf, 25, "%.17G", rDoc.GetValue(0 + nOffset, row, tab));
|
||||
result += OUString::createFromAscii(std::string_view(buf, len));
|
||||
result.append( OUString::createFromAscii(std::string_view(buf, len)) );
|
||||
len = snprintf(buf, 25, "%.17G", rDoc.GetValue(nExpectedCol + nOffset, row, tab));
|
||||
expected += OUString::createFromAscii(std::string_view(buf, len));
|
||||
expected.append( OUString::createFromAscii(std::string_view(buf, len)) );
|
||||
}
|
||||
else
|
||||
{
|
||||
result += rDoc.GetString(0 + nOffset, row, tab);
|
||||
expected += rDoc.GetString(nExpectedCol + nOffset, row, tab);
|
||||
result.append(rDoc.GetString(0 + nOffset, row, tab));
|
||||
expected.append(rDoc.GetString(nExpectedCol + nOffset, row, tab));
|
||||
}
|
||||
|
||||
if (nOffset < nExpectedCol - 1)
|
||||
{
|
||||
result += ", ";
|
||||
expected += ", ";
|
||||
result.append(", ");
|
||||
expected.append(", ");
|
||||
}
|
||||
}
|
||||
CPPUNIT_FAIL( OUString( "Testing " + rURL + " failed, "
|
||||
|
||||
@@ -1787,7 +1787,7 @@ struct SheetDimData
|
||||
continue;
|
||||
|
||||
bool bBooleanValue = rEntry.aKey != "sizes";
|
||||
OString aExpectedEncoding;
|
||||
OStringBuffer aExpectedEncoding;
|
||||
bool bFirst = true;
|
||||
for (const auto& rSpan : rEntry.rSpanList)
|
||||
{
|
||||
@@ -1795,15 +1795,15 @@ struct SheetDimData
|
||||
if (bBooleanValue && bFirst)
|
||||
nVal = static_cast<size_t>(!!nVal);
|
||||
if (!bBooleanValue || bFirst)
|
||||
aExpectedEncoding += OString::number(nVal) + ":";
|
||||
aExpectedEncoding += OString::number(rSpan.nEnd) + " ";
|
||||
aExpectedEncoding.append(OString::number(nVal) + ":");
|
||||
aExpectedEncoding.append(OString::number(rSpan.nEnd) + " ");
|
||||
bFirst = false;
|
||||
}
|
||||
|
||||
// Get the tree's value for the property key ("sizes"/"hidden"/"filtered").
|
||||
OString aTreeValue(rTree.get<std::string>(rEntry.aKey.getStr()));
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(aExpectedEncoding, aTreeValue);
|
||||
CPPUNIT_ASSERT_EQUAL(aExpectedEncoding.toString(), aTreeValue);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@@ -143,12 +143,12 @@ ScOutlineCollection::iterator ScOutlineCollection::FindStart(SCCOLROW nMinStart)
|
||||
|
||||
OString ScOutlineCollection::dumpAsString() const
|
||||
{
|
||||
OString aOutput;
|
||||
OStringBuffer aOutput;
|
||||
const char* const pGroupEntrySep = ",";
|
||||
for (const auto& rKeyValuePair : m_Entries)
|
||||
aOutput += rKeyValuePair.second.dumpAsString() + pGroupEntrySep;
|
||||
aOutput.append(rKeyValuePair.second.dumpAsString() + pGroupEntrySep);
|
||||
|
||||
return aOutput;
|
||||
return aOutput.toString();
|
||||
}
|
||||
|
||||
ScOutlineArray::ScOutlineArray() :
|
||||
@@ -730,16 +730,16 @@ void ScOutlineArray::finalizeImport(const ScTable& rTable)
|
||||
|
||||
OString ScOutlineArray::dumpAsString() const
|
||||
{
|
||||
OString aOutput;
|
||||
OStringBuffer aOutput;
|
||||
const char* const pLevelSep = " ";
|
||||
for (const auto& rCollection : aCollections)
|
||||
{
|
||||
if (rCollection.empty())
|
||||
continue;
|
||||
aOutput += rCollection.dumpAsString() + pLevelSep;
|
||||
aOutput.append(rCollection.dumpAsString() + pLevelSep);
|
||||
}
|
||||
|
||||
return aOutput;
|
||||
return aOutput.toString();
|
||||
}
|
||||
|
||||
ScOutlineTable::ScOutlineTable()
|
||||
|
||||
@@ -65,16 +65,16 @@ std::unique_ptr<SfxTabPage> ScRedlineOptionsTabPage::Create( weld::Container* pP
|
||||
|
||||
OUString ScRedlineOptionsTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr, u"label3"_ustr, u"label4"_ustr, u"label5"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScRedlineOptionsTabPage::FillItemSet( SfxItemSet* /* rSet */ )
|
||||
|
||||
@@ -273,7 +273,7 @@ void ScTpCalcOptions::Reset(const SfxItemSet* rCoreAttrs)
|
||||
|
||||
OUString ScTpCalcOptions::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label5"_ustr, u"label1"_ustr, u"precft"_ustr,
|
||||
u"label2"_ustr, u"stepsft"_ustr, u"minchangeft"_ustr,
|
||||
u"label4"_ustr, u"label3"_ustr, u"openclframe"_ustr };
|
||||
@@ -281,7 +281,7 @@ OUString ScTpCalcOptions::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -290,7 +290,7 @@ OUString ScTpCalcOptions::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"formulawildcards"_ustr, u"formularegex"_ustr, u"formulaliteral"_ustr,
|
||||
@@ -299,10 +299,10 @@ OUString ScTpCalcOptions::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScTpCalcOptions::FillItemSet( SfxItemSet* rCoreAttrs )
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
|
||||
#undef SC_DLLIMPLEMENTATION
|
||||
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <svl/intitem.hxx>
|
||||
#include <svl/eitem.hxx>
|
||||
#include <officecfg/Office/Calc.hxx>
|
||||
@@ -37,18 +38,18 @@ std::unique_ptr<SfxTabPage> ScTpCompatOptions::Create(weld::Container* pPage, we
|
||||
|
||||
OUString ScTpCompatOptions::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
// id "keybindings" GtkComboBoxText is not included
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScTpCompatOptions::FillItemSet(SfxItemSet *rCoreAttrs)
|
||||
|
||||
@@ -46,18 +46,18 @@ std::unique_ptr<SfxTabPage> ScTpDefaultsOptions::Create(weld::Container* pPage,
|
||||
|
||||
OUString ScTpDefaultsOptions::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"textsheetsnumber"_ustr, u"textsheetprefix"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
sAllStrings += m_xEdJumboSheets->get_label() + " ";
|
||||
sAllStrings.append(m_xEdJumboSheets->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScTpDefaultsOptions::FillItemSet(SfxItemSet *rCoreSet)
|
||||
|
||||
@@ -261,7 +261,7 @@ std::unique_ptr<SfxTabPage> ScTpFormulaOptions::Create(weld::Container* pPage, w
|
||||
|
||||
OUString ScTpFormulaOptions::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"formulasyntaxlabel"_ustr,
|
||||
u"label3"_ustr, u"label6"_ustr,
|
||||
u"label7"_ustr, u"label8"_ustr,
|
||||
@@ -271,7 +271,7 @@ OUString ScTpFormulaOptions::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"calcdefault"_ustr, u"calccustom"_ustr };
|
||||
@@ -279,7 +279,7 @@ OUString ScTpFormulaOptions::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString buttons[] = { u"reset"_ustr, u"details"_ustr };
|
||||
@@ -287,13 +287,13 @@ OUString ScTpFormulaOptions::GetAllStrings()
|
||||
for (const auto& btn : buttons)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_button(btn))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
// check button
|
||||
sAllStrings += mxCbEnglishFuncName->get_label() + " ";
|
||||
sAllStrings.append(mxCbEnglishFuncName->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScTpFormulaOptions::FillItemSet(SfxItemSet* rCoreSet)
|
||||
|
||||
@@ -95,13 +95,13 @@ void ScTpPrintOptions::Reset( const SfxItemSet* rCoreSet )
|
||||
|
||||
OUString ScTpPrintOptions::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label2"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"suppressCB"_ustr, u"forceBreaksCB"_ustr, u"printCB"_ustr };
|
||||
@@ -109,10 +109,10 @@ OUString ScTpPrintOptions::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScTpPrintOptions::FillItemSet( SfxItemSet* rCoreAttrs )
|
||||
|
||||
@@ -189,13 +189,13 @@ void ScTpUserLists::Reset( const SfxItemSet* rCoreAttrs )
|
||||
|
||||
OUString ScTpUserLists::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"listslabel"_ustr, u"entrieslabel"_ustr, u"copyfromlabel"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString buttons[] = { u"new"_ustr, u"discard"_ustr, u"add"_ustr, u"modify"_ustr, u"delete"_ustr, u"copy"_ustr };
|
||||
@@ -203,10 +203,10 @@ OUString ScTpUserLists::GetAllStrings()
|
||||
for (const auto& btn : buttons)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_button(btn))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScTpUserLists::FillItemSet( SfxItemSet* rCoreAttrs )
|
||||
|
||||
@@ -128,14 +128,14 @@ std::unique_ptr<SfxTabPage> ScTpContentOptions::Create( weld::Container* pPage,
|
||||
|
||||
OUString ScTpContentOptions::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label4"_ustr, u"label5"_ustr, u"label3"_ustr, u"label1"_ustr, u"grid_label"_ustr,
|
||||
u"lbCursor"_ustr, u"label2"_ustr, u"objgrf_label"_ustr, u"diagram_label"_ustr, u"draw_label"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -146,10 +146,10 @@ OUString ScTpContentOptions::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScTpContentOptions::FillItemSet( SfxItemSet* rCoreSet )
|
||||
@@ -550,13 +550,13 @@ std::unique_ptr<SfxTabPage> ScTpLayoutOptions::Create( weld::Container* pPage, w
|
||||
|
||||
OUString ScTpLayoutOptions::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label4"_ustr, u"label5"_ustr, u"label6"_ustr, u"label3"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"aligncb"_ustr, u"editmodecb"_ustr, u"enter_paste_mode_cb"_ustr,
|
||||
@@ -567,7 +567,7 @@ OUString ScTpLayoutOptions::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"alwaysrb"_ustr, u"requestrb"_ustr, u"neverrb"_ustr };
|
||||
@@ -575,10 +575,10 @@ OUString ScTpLayoutOptions::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool ScTpLayoutOptions::FillItemSet( SfxItemSet* rCoreSet )
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
#include <optsitem.hxx>
|
||||
#include <prntopts.hxx>
|
||||
#include <app.hrc>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <svl/intitem.hxx>
|
||||
#include <officecfg/Office/Impress.hxx>
|
||||
#include <officecfg/Office/Draw.hxx>
|
||||
@@ -84,13 +85,13 @@ SdPrintOptions::~SdPrintOptions()
|
||||
|
||||
OUString SdPrintOptions::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label3"_ustr, u"label2"_ustr, u"printlbl"_ustr, u"contentlbl"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"frontcb"_ustr, u"backcb"_ustr, u"papertryfrmprntrcb"_ustr, u"pagenmcb"_ustr,
|
||||
@@ -100,7 +101,7 @@ OUString SdPrintOptions::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"pagedefaultrb"_ustr, u"fittopgrb"_ustr, u"tilepgrb"_ustr, u"brouchrb"_ustr,
|
||||
@@ -109,10 +110,10 @@ OUString SdPrintOptions::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SdPrintOptions::FillItemSet( SfxItemSet* rAttrs )
|
||||
|
||||
@@ -241,13 +241,13 @@ SdTpOptionsContents::~SdTpOptionsContents() {}
|
||||
|
||||
OUString SdTpOptionsContents::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -256,10 +256,10 @@ OUString SdTpOptionsContents::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SdTpOptionsContents::FillItemSet(SfxItemSet*)
|
||||
@@ -540,7 +540,7 @@ DeactivateRC SdTpOptionsMisc::DeactivatePage(SfxItemSet* pActiveSet)
|
||||
|
||||
OUString SdTpOptionsMisc::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"newdoclbl"_ustr, u"label4"_ustr, u"label6"_ustr, u"tabstoplabel"_ustr,
|
||||
u"label1"_ustr, u"label7"_ustr, u"label2"_ustr, u"label5"_ustr,
|
||||
u"label8"_ustr, u"widthlbl"_ustr, u"info1"_ustr, u"heightlbl"_ustr,
|
||||
@@ -549,7 +549,7 @@ OUString SdTpOptionsMisc::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -560,10 +560,10 @@ OUString SdTpOptionsMisc::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SdTpOptionsMisc::FillItemSet(SfxItemSet* rAttrs)
|
||||
|
||||
@@ -440,39 +440,39 @@ public:
|
||||
auto xClass = mxMethod->getReturnType();
|
||||
aOutString = simpleTypeName(xClass);
|
||||
|
||||
OUString aInString;
|
||||
OUStringBuffer aInString;
|
||||
const auto aParameters = mxMethod->getParameterInfos();
|
||||
bool bFirst = true;
|
||||
for (auto const& rParameterInfo : aParameters)
|
||||
{
|
||||
if (!bFirst)
|
||||
aInString += ", ";
|
||||
aInString.append(", ");
|
||||
else
|
||||
bFirst = false;
|
||||
|
||||
switch (rParameterInfo.aMode)
|
||||
{
|
||||
case reflection::ParamMode_IN:
|
||||
aInString += SfxResId(STR_PARMETER_MODE_IN) + " ";
|
||||
aInString.append(SfxResId(STR_PARMETER_MODE_IN) + " ");
|
||||
break;
|
||||
case reflection::ParamMode_OUT:
|
||||
aInString += SfxResId(STR_PARMETER_MODE_OUT) + " ";
|
||||
aInString.append(SfxResId(STR_PARMETER_MODE_OUT) + " ");
|
||||
break;
|
||||
case reflection::ParamMode_INOUT:
|
||||
aInString += SfxResId(STR_PARMETER_MODE_IN_AND_OUT) + " ";
|
||||
aInString.append(SfxResId(STR_PARMETER_MODE_IN_AND_OUT) + " ");
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
aInString += rParameterInfo.aName + " : " + simpleTypeName(rParameterInfo.aType);
|
||||
aInString.append(rParameterInfo.aName + " : " + simpleTypeName(rParameterInfo.aType));
|
||||
}
|
||||
|
||||
OUString aImplementationClass = mxMethod->getDeclaringClass()->getName();
|
||||
|
||||
return {
|
||||
{ 1, aOutString },
|
||||
{ 2, aInString },
|
||||
{ 2, aInString.toString() },
|
||||
{ 3, aImplementationClass },
|
||||
};
|
||||
}
|
||||
@@ -827,19 +827,19 @@ void GenericPropertiesNode::fillChildren(std::unique_ptr<weld::TreeView>& pTree,
|
||||
aInfoCollection.push_back(SfxResId(STR_PROPERTY_ATTRIBUTE_MAYBEDEFAULT));
|
||||
|
||||
bool bSet = false;
|
||||
OUString aInfoString;
|
||||
OUStringBuffer aInfoString;
|
||||
for (auto const& rString : aInfoCollection)
|
||||
{
|
||||
if (bSet)
|
||||
aInfoString += ", ";
|
||||
aInfoString.append(", ");
|
||||
else
|
||||
bSet = true;
|
||||
|
||||
aInfoString += rString;
|
||||
aInfoString.append(rString);
|
||||
}
|
||||
|
||||
auto* pObjectInspectorNode
|
||||
= createNodeObjectForAny(aPropertyName, aCurrentAny, aInfoString);
|
||||
= createNodeObjectForAny(aPropertyName, aCurrentAny, aInfoString.toString());
|
||||
if (pObjectInspectorNode)
|
||||
lclAppendNodeToParent(pTree, pParent, pObjectInspectorNode);
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
#include <officecfg/Office/Common.hxx>
|
||||
#include <svtools/printoptions.hxx>
|
||||
#include <svtools/restartdialog.hxx>
|
||||
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <comphelper/processfactory.hxx>
|
||||
|
||||
#include <sfx2/printopt.hxx>
|
||||
@@ -92,13 +92,13 @@ std::unique_ptr<SfxTabPage> SfxCommonPrintOptionsTabPage::Create(weld::Container
|
||||
|
||||
OUString SfxCommonPrintOptionsTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label4"_ustr, u"label6"_ustr, u"label2"_ustr, u"label3"_ustr, u"label1"_ustr, u"label5"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"converttogray"_ustr, u"reducebitmaptrans"_ustr, u"reducebitmap"_ustr, u"reducetrans"_ustr,
|
||||
@@ -107,7 +107,7 @@ OUString SfxCommonPrintOptionsTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"printer"_ustr,
|
||||
@@ -123,10 +123,10 @@ OUString SfxCommonPrintOptionsTabPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append( pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SfxCommonPrintOptionsTabPage::FillItemSet( SfxItemSet* /*rSet*/ )
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
|
||||
#include "uiobject.hxx"
|
||||
#include <sfx2/sidebar/SidebarController.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
namespace sfx2::sidebar
|
||||
{
|
||||
@@ -21,14 +22,14 @@ TabBarUIObject::TabBarUIObject(const VclPtr<TabBar>& xTabBar)
|
||||
StringMap TabBarUIObject::get_state()
|
||||
{
|
||||
StringMap aMap = WindowUIObject::get_state();
|
||||
OUString rsHighlightedTabsIds;
|
||||
OUStringBuffer rsHighlightedTabsIds;
|
||||
for (auto const& item : mxTabBar->maItems)
|
||||
{
|
||||
if (item->mxButton->get_item_active(u"toggle"_ustr))
|
||||
{
|
||||
if (!rsHighlightedTabsIds.isEmpty())
|
||||
rsHighlightedTabsIds += ",";
|
||||
rsHighlightedTabsIds += item->msDeckId;
|
||||
rsHighlightedTabsIds.append(",");
|
||||
rsHighlightedTabsIds.append(item->msDeckId);
|
||||
}
|
||||
}
|
||||
aMap[u"HighlightedTabsIds"_ustr] = rsHighlightedTabsIds;
|
||||
|
||||
@@ -94,6 +94,7 @@ $(eval $(call gb_CompilerTest_add_exception_objects,compilerplugins_clang, \
|
||||
compilerplugins/clang/test/stringconcatliterals \
|
||||
compilerplugins/clang/test/stringconstant \
|
||||
compilerplugins/clang/test/stringliteralvar \
|
||||
compilerplugins/clang/test/stringloop \
|
||||
compilerplugins/clang/test/stringplusequal \
|
||||
compilerplugins/clang/test/stringstatic \
|
||||
compilerplugins/clang/test/stringview \
|
||||
|
||||
@@ -222,13 +222,13 @@ SmPrintOptionsTabPage::~SmPrintOptionsTabPage()
|
||||
|
||||
OUString SmPrintOptionsTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label4"_ustr, u"label5"_ustr, u"label1"_ustr, u"label6"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -237,7 +237,7 @@ OUString SmPrintOptionsTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"sizenormal"_ustr, u"sizescaled"_ustr, u"sizezoomed"_ustr };
|
||||
@@ -245,10 +245,10 @@ OUString SmPrintOptionsTabPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SmPrintOptionsTabPage::FillItemSet(SfxItemSet* rSet)
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <comphelper/string.hxx>
|
||||
#include <o3tl/untaint.hxx>
|
||||
#include <o3tl/string_view.hxx>
|
||||
#include <sal/log.hxx>
|
||||
#include <tools/debug.hxx>
|
||||
#include <i18nlangtag/mslangid.hxx>
|
||||
@@ -1885,14 +1886,14 @@ sal_Int32 ImpSvNumberformatScan::FinalScan( OUString& rString )
|
||||
else if (sStrArray[i][0] >= '0' &&
|
||||
sStrArray[i][0] <= '9' && !bDenomin) // denominator was not yet found
|
||||
{
|
||||
OUString sDiv;
|
||||
OUStringBuffer sDiv;
|
||||
sal_uInt16 j = i;
|
||||
while(j < nStringsCnt && sStrArray[j][0] >= '0' && sStrArray[j][0] <= '9')
|
||||
{
|
||||
sDiv += sStrArray[j++];
|
||||
sDiv.append(sStrArray[j++]);
|
||||
}
|
||||
assert(j > 0 && "if i is 0, first iteration through loop is guaranteed by surrounding if condition");
|
||||
if (std::u16string_view(OUString::number(sDiv.toInt32())) == sDiv)
|
||||
if (std::u16string_view(OUString::number(o3tl::toInt32(sDiv))) == sDiv)
|
||||
{
|
||||
// Found a Divisor
|
||||
while (i < j)
|
||||
|
||||
@@ -103,7 +103,7 @@ static std::vector< OUString > getInfoFromInd( std::u16string_view aInd )
|
||||
}
|
||||
else
|
||||
{
|
||||
OUString aNum;
|
||||
OUStringBuffer aNum;
|
||||
for( int i = 1; i < 3; i++ )
|
||||
{
|
||||
if( !pLine[i]
|
||||
@@ -115,10 +115,10 @@ static std::vector< OUString > getInfoFromInd( std::u16string_view aInd )
|
||||
return aResult;
|
||||
}
|
||||
|
||||
aNum += OUStringChar( pLine[i] );
|
||||
aNum.append(OUStringChar( pLine[i] ));
|
||||
}
|
||||
|
||||
newItem.append( sal_Unicode( aNum.toUInt32( 16 ) ) );
|
||||
newItem.append( sal_Unicode( o3tl::toUInt32(aNum, 16) ) );
|
||||
pLine += 3;
|
||||
}
|
||||
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#include <vcl/outdev.hxx>
|
||||
#include <vcl/gfxlink.hxx>
|
||||
#include <vcl/TypeSerializer.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <bitmaps.hlst>
|
||||
|
||||
#include <sal/log.hxx>
|
||||
@@ -945,7 +946,7 @@ bool EmbeddedObjectRef::IsChart() const
|
||||
// MT: Only used for getting accessible attributes, which are not localized
|
||||
OUString EmbeddedObjectRef::GetChartType()
|
||||
{
|
||||
OUString Style;
|
||||
OUStringBuffer Style;
|
||||
if ( mpImpl->mxObj.is() )
|
||||
{
|
||||
if ( IsChart() )
|
||||
@@ -968,20 +969,20 @@ OUString EmbeddedObjectRef::GetChartType()
|
||||
const uno::Sequence< uno::Reference< chart2::XChartType > > aChartTypes( xCTCnt->getChartTypes());
|
||||
int nDimesionCount = rCooSys->getDimension();
|
||||
if( nDimesionCount == 3 )
|
||||
Style += "3D ";
|
||||
Style.append("3D ");
|
||||
else
|
||||
Style += "2D ";
|
||||
Style.append("2D ");
|
||||
for( const auto& rChartType : aChartTypes )
|
||||
{
|
||||
OUString strChartType = rChartType->getChartType();
|
||||
if (strChartType == "com.sun.star.chart2.AreaChartType")
|
||||
{
|
||||
Style += "Areas";
|
||||
Style.append("Areas");
|
||||
bGetChartType = true;
|
||||
}
|
||||
else if (strChartType == "com.sun.star.chart2.BarChartType")
|
||||
{
|
||||
Style += "Bars";
|
||||
Style.append("Bars");
|
||||
bGetChartType = true;
|
||||
}
|
||||
else if (strChartType == "com.sun.star.chart2.ColumnChartType")
|
||||
@@ -993,47 +994,47 @@ OUString EmbeddedObjectRef::GetChartType()
|
||||
if( xProp->getPropertyValue( u"SwapXAndYAxis"_ustr ) >>= bCurrent )
|
||||
{
|
||||
if (bCurrent)
|
||||
Style += "Bars";
|
||||
Style.append("Bars");
|
||||
else
|
||||
Style += "Columns";
|
||||
Style.append("Columns");
|
||||
bGetChartType = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (strChartType == "com.sun.star.chart2.LineChartType")
|
||||
{
|
||||
Style += "Lines";
|
||||
Style.append("Lines");
|
||||
bGetChartType = true;
|
||||
}
|
||||
else if (strChartType == "com.sun.star.chart2.ScatterChartType")
|
||||
{
|
||||
Style += "XY Chart";
|
||||
Style.append("XY Chart");
|
||||
bGetChartType = true;
|
||||
}
|
||||
else if (strChartType == "com.sun.star.chart2.PieChartType")
|
||||
{
|
||||
Style += "Pies";
|
||||
Style.append("Pies");
|
||||
bGetChartType = true;
|
||||
}
|
||||
else if (strChartType == "com.sun.star.chart2.NetChartType")
|
||||
{
|
||||
Style += "Radar";
|
||||
Style.append("Radar");
|
||||
bGetChartType = true;
|
||||
}
|
||||
else if (strChartType == "com.sun.star.chart2.CandleStickChartType")
|
||||
{
|
||||
Style += "Candle Stick Chart";
|
||||
Style.append("Candle Stick Chart");
|
||||
bGetChartType = true;
|
||||
}
|
||||
if (bGetChartType)
|
||||
return Style;
|
||||
return Style.toString();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return Style;
|
||||
return Style.toString();
|
||||
}
|
||||
|
||||
// #i104867#
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <officecfg/Office/Draw.hxx>
|
||||
#include <sfx2/viewfrm.hxx>
|
||||
#include <vcl/commandinfoprovider.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
#include <svx/svxids.hrc>
|
||||
#include <svx/optgrid.hxx>
|
||||
@@ -201,7 +202,7 @@ std::unique_ptr<SfxTabPage> SvxGridTabPage::Create(weld::Container* pPage, weld:
|
||||
|
||||
OUString SvxGridTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[]
|
||||
= { u"label1"_ustr, u"label2"_ustr, u"flddrawx"_ustr, u"flddrawy"_ustr, u"label6"_ustr, u"label7"_ustr, u"label3"_ustr,
|
||||
u"divisionx"_ustr, u"label4"_ustr, u"divisiony"_ustr, u"label5"_ustr, u"label8"_ustr, u"label9"_ustr };
|
||||
@@ -209,7 +210,7 @@ OUString SvxGridTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -219,10 +220,10 @@ OUString SvxGridTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SvxGridTabPage::FillItemSet( SfxItemSet* rCoreSet )
|
||||
|
||||
@@ -1109,7 +1109,7 @@ void SdrMarkView::SetMarkHandlesForLOKit(tools::Rectangle const & rRect, const S
|
||||
|
||||
Point aOffsetPx = pWin->GetOffsetPixelFrom(*pViewShellWindow);
|
||||
Point aLogicOffset = pWin->PixelToLogic(aOffsetPx);
|
||||
OString sPolygonElem("<polygon points=\\\""_ostr);
|
||||
OStringBuffer sPolygonElem("<polygon points=\\\"");
|
||||
for (sal_uInt32 nIndex = 0; nIndex < nPolySize; ++nIndex)
|
||||
{
|
||||
const basegfx::B2DPoint aB2Point = aPolygon.getB2DPoint(nIndex);
|
||||
@@ -1118,10 +1118,10 @@ void SdrMarkView::SetMarkHandlesForLOKit(tools::Rectangle const & rRect, const S
|
||||
if (mbNegativeX)
|
||||
aPoint.setX(-aPoint.X());
|
||||
if (nIndex > 0)
|
||||
sPolygonElem += " ";
|
||||
sPolygonElem += aPoint.toString();
|
||||
sPolygonElem.append(" ");
|
||||
sPolygonElem.append(aPoint.toString());
|
||||
}
|
||||
sPolygonElem += R"elem(\" style=\"stroke: none; fill: rgb(114,159,207); fill-opacity: 0.8\"/>)elem";
|
||||
sPolygonElem.append(R"elem(\" style=\"stroke: none; fill: rgb(114,159,207); fill-opacity: 0.8\"/>)elem");
|
||||
|
||||
OString sSVGElem = R"elem(<svg version=\"1.2\" width=\")elem" +
|
||||
OString::number(aSelection.GetWidth() / 100.0) +
|
||||
|
||||
@@ -1429,14 +1429,14 @@ static void buildCMapAndFeatures(const OUString& CMapUrl, SvFileStream& Features
|
||||
{
|
||||
sal_Int32 nLigatureGlyph = ligature.first;
|
||||
OString sLigatureChars = ligature.second;
|
||||
OString ligatureLine = "substitute"_ostr;
|
||||
OStringBuffer ligatureLine("substitute");
|
||||
for (sal_Int32 i = 0; i < sLigatureChars.getLength(); i += 4)
|
||||
{
|
||||
OString sLigatureChar = sLigatureChars.copy(i, 4);
|
||||
sal_Int32 nCharGlyph = charsToGlyph[sLigatureChar];
|
||||
ligatureLine += " \\" + OString::number(nCharGlyph);
|
||||
ligatureLine.append(" \\" + OString::number(nCharGlyph));
|
||||
}
|
||||
ligatureLine += " by \\" + OString::number(nLigatureGlyph) + ";";
|
||||
ligatureLine.append(" by \\" + OString::number(nLigatureGlyph) + ";");
|
||||
Features.WriteLine(ligatureLine);
|
||||
}
|
||||
Features.WriteLine("} liga;");
|
||||
@@ -1607,14 +1607,14 @@ static EmbeddedFontInfo mergeFontSubsets(sal_Int64 prefix, const OUString& merge
|
||||
{
|
||||
sal_Int32 nLigatureGlyph = ligature.first;
|
||||
OString sLigatureChars = ligature.second;
|
||||
OString ligatureLine = "substitute"_ostr;
|
||||
OStringBuffer ligatureLine("substitute");
|
||||
for (sal_Int32 i = 0; i < sLigatureChars.getLength(); i += 4)
|
||||
{
|
||||
OString sLigatureChar = sLigatureChars.copy(i, 4);
|
||||
sal_Int32 nCharGlyph = charsToGlyph[sLigatureChar];
|
||||
ligatureLine += " \\" + OString::number(nCharGlyph);
|
||||
ligatureLine.append(" \\" + OString::number(nCharGlyph));
|
||||
}
|
||||
ligatureLine += " by \\" + OString::number(nLigatureGlyph) + ";";
|
||||
ligatureLine.append(" by \\" + OString::number(nLigatureGlyph) + ";");
|
||||
Features.WriteLine(ligatureLine);
|
||||
}
|
||||
Features.WriteLine("} liga;");
|
||||
|
||||
@@ -1228,7 +1228,7 @@ CPPUNIT_TEST_FIXTURE(Test, testListLabelPDFExport)
|
||||
uno::Reference<container::XIndexReplace> xNumRule(
|
||||
xFactory->createInstance(u"com.sun.star.text.NumberingRules"_ustr),
|
||||
uno::UNO_QUERY_THROW);
|
||||
OUString listFormat;
|
||||
OUStringBuffer listFormat;
|
||||
for (sal_Int32 i = 0; i < xNumRule->getCount(); ++i)
|
||||
{
|
||||
uno::Sequence<beans::PropertyValue> format;
|
||||
@@ -1247,10 +1247,10 @@ CPPUNIT_TEST_FIXTURE(Test, testListLabelPDFExport)
|
||||
[](auto const& r) { return r.Name == "ParentNumbering"; }));
|
||||
const_cast<uno::Any&>(it->Value) <<= sal_Int16(i + 1);
|
||||
#endif
|
||||
listFormat += "%" + OUString::number(i+1) + "%.";
|
||||
listFormat.append("%" + OUString::number(i+1) + "%.");
|
||||
auto it(::std::find_if(format.begin(), format.end(),
|
||||
[](auto const& r) { return r.Name == "ListFormat"; }));
|
||||
const_cast<uno::Any&>(it->Value) <<= listFormat;
|
||||
const_cast<uno::Any&>(it->Value) <<= listFormat.toString();
|
||||
}
|
||||
xNumRule->replaceByIndex(i, uno::Any(format));
|
||||
}
|
||||
|
||||
@@ -885,7 +885,7 @@ DECLARE_ODFEXPORT_TEST(testTdf115815, "tdf115815.odt")
|
||||
uno::Reference<container::XEnumeration> xRunEnum = xRunEnumAccess->createEnumeration();
|
||||
bool bAnnotationStart = false;
|
||||
bool bBeforeAnnotation = true;
|
||||
OUString sTextBeforeAnnotation;
|
||||
OUStringBuffer sTextBeforeAnnotation;
|
||||
while (xRunEnum->hasMoreElements())
|
||||
{
|
||||
uno::Reference<beans::XPropertySet> xPropertySet(xRunEnum->nextElement(), uno::UNO_QUERY);
|
||||
@@ -904,13 +904,13 @@ DECLARE_ODFEXPORT_TEST(testTdf115815, "tdf115815.odt")
|
||||
else if (aType == "Text")
|
||||
{
|
||||
uno::Reference<text::XTextRange> xRun(xPropertySet, uno::UNO_QUERY);
|
||||
sTextBeforeAnnotation += xRun->getString();
|
||||
sTextBeforeAnnotation.append(xRun->getString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// This was "Lorem ipsum" (collapsed annotation range)
|
||||
CPPUNIT_ASSERT_EQUAL(u"Lorem "_ustr, sTextBeforeAnnotation);
|
||||
CPPUNIT_ASSERT_EQUAL(u"Lorem "_ustr, sTextBeforeAnnotation.toString());
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(Test, testFdo58949)
|
||||
|
||||
@@ -407,7 +407,7 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest5, testTdf140982)
|
||||
uno::Reference<container::XEnumeration> xRunEnum = xRunEnumAccess->createEnumeration();
|
||||
bool bAnnotationStart = false;
|
||||
bool bBeforeAnnotation = true;
|
||||
OUString sTextBeforeAnnotation;
|
||||
OUStringBuffer sTextBeforeAnnotation;
|
||||
while (xRunEnum->hasMoreElements())
|
||||
{
|
||||
uno::Reference<beans::XPropertySet> xPropertySet(xRunEnum->nextElement(), uno::UNO_QUERY);
|
||||
@@ -426,13 +426,13 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest5, testTdf140982)
|
||||
else if (aType == "Text")
|
||||
{
|
||||
uno::Reference<text::XTextRange> xRun(xPropertySet, uno::UNO_QUERY);
|
||||
sTextBeforeAnnotation += xRun->getString();
|
||||
sTextBeforeAnnotation.append(xRun->getString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// This was "Lorem ipsum" (collapsed annotation range)
|
||||
CPPUNIT_ASSERT_EQUAL(u"Lorem "_ustr, sTextBeforeAnnotation);
|
||||
CPPUNIT_ASSERT_EQUAL(u"Lorem "_ustr, sTextBeforeAnnotation.toString());
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(SwUiWriterTest5, testTdf126206)
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <com/sun/star/accessibility/AccessibleTableModelChangeType.hpp>
|
||||
#include <com/sun/star/lang/IndexOutOfBoundsException.hpp>
|
||||
#include <o3tl/safeint.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <vcl/svapp.hxx>
|
||||
#include <frmfmt.hxx>
|
||||
#include <tabfrm.hxx>
|
||||
@@ -673,7 +674,7 @@ OUString SAL_CALL SwAccessibleTable::getAccessibleRowDescription(
|
||||
{
|
||||
// #i87532# - determine table cell in <nRow>th row and
|
||||
// in first column of row header table and return its text content.
|
||||
OUString sRowDesc;
|
||||
OUStringBuffer sRowDesc;
|
||||
|
||||
GetTableData().CheckRowAndCol(nRow, 0);
|
||||
|
||||
@@ -693,12 +694,12 @@ OUString SAL_CALL SwAccessibleTable::getAccessibleRowDescription(
|
||||
uno::Reference< XAccessibleText > xChildText( xChild, uno::UNO_QUERY );
|
||||
if ( xChildText.is() )
|
||||
{
|
||||
sRowDesc += xChildText->getText();
|
||||
sRowDesc.append(xChildText->getText());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return sRowDesc;
|
||||
return sRowDesc.makeStringAndClear();
|
||||
}
|
||||
|
||||
OUString SAL_CALL SwAccessibleTable::getAccessibleColumnDescription(
|
||||
@@ -706,7 +707,7 @@ OUString SAL_CALL SwAccessibleTable::getAccessibleColumnDescription(
|
||||
{
|
||||
// #i87532# - determine table cell in first row and
|
||||
// in <nColumn>th column of column header table and return its text content.
|
||||
OUString sColumnDesc;
|
||||
OUStringBuffer sColumnDesc;
|
||||
|
||||
GetTableData().CheckRowAndCol(0, nColumn);
|
||||
|
||||
@@ -726,12 +727,12 @@ OUString SAL_CALL SwAccessibleTable::getAccessibleColumnDescription(
|
||||
uno::Reference< XAccessibleText > xChildText( xChild, uno::UNO_QUERY );
|
||||
if ( xChildText.is() )
|
||||
{
|
||||
sColumnDesc += xChildText->getText();
|
||||
sColumnDesc.append(xChildText->getText());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return sColumnDesc;
|
||||
return sColumnDesc.makeStringAndClear();
|
||||
}
|
||||
|
||||
sal_Int32 SAL_CALL SwAccessibleTable::getAccessibleRowExtentAt(
|
||||
|
||||
@@ -1021,14 +1021,14 @@ OUString SwNumRule::MakeRefNumString( const SwNodeNum& rNodeNum,
|
||||
|
||||
OUString SwNumRule::MakeParagraphStyleListString() const
|
||||
{
|
||||
OUString aParagraphStyleListString;
|
||||
OUStringBuffer aParagraphStyleListString;
|
||||
for (const auto& rParagraphStyle : maParagraphStyleList)
|
||||
{
|
||||
if (!aParagraphStyleListString.isEmpty())
|
||||
aParagraphStyleListString += ", ";
|
||||
aParagraphStyleListString += rParagraphStyle->GetName().toString();
|
||||
aParagraphStyleListString.append(", ");
|
||||
aParagraphStyleListString.append(rParagraphStyle->GetName().toString());
|
||||
}
|
||||
return aParagraphStyleListString;
|
||||
return aParagraphStyleListString.toString();
|
||||
}
|
||||
|
||||
/** Copy method of SwNumRule
|
||||
|
||||
@@ -982,7 +982,7 @@ uno::Sequence< beans::PropertyValue > SAL_CALL SwChartDataProvider::detectArgume
|
||||
uno::Sequence< sal_Int32 > aSequenceMapping( nNumDS_LDS );
|
||||
sal_Int32 *pSequenceMapping = aSequenceMapping.getArray();
|
||||
|
||||
OUString aCellRanges;
|
||||
OUStringBuffer aCellRanges;
|
||||
sal_Int16 nDtaSrcIsColumns = -1;// -1: don't know yet, 0: false, 1: true -2: neither
|
||||
sal_Int32 nLabelSeqLen = -1; // used to see if labels are always used or not and have
|
||||
// the expected size of 1 (i.e. if FirstCellAsLabel can
|
||||
@@ -1200,8 +1200,8 @@ uno::Sequence< beans::PropertyValue > SAL_CALL SwChartDataProvider::detectArgume
|
||||
OUString aEndCell( sw_GetCellName( k + nColSubLen - 1, i + nRowSubLen - 1) );
|
||||
aCurRange = aCellRangeBase + aStartCell + ":" + aEndCell;
|
||||
if (!aCellRanges.isEmpty())
|
||||
aCellRanges += ";";
|
||||
aCellRanges += aCurRange;
|
||||
aCellRanges.append(";");
|
||||
aCellRanges.append(aCurRange);
|
||||
|
||||
// clear already found sub-range from map
|
||||
for (sal_Int32 nRowIndex2 = 0; nRowIndex2 < nRowSubLen; ++nRowIndex2)
|
||||
@@ -1215,12 +1215,12 @@ uno::Sequence< beans::PropertyValue > SAL_CALL SwChartDataProvider::detectArgume
|
||||
uno::Sequence< OUString > aSortedRanges;
|
||||
GetSubranges( aCellRanges, aSortedRanges, false /*sub ranges should already be normalized*/ );
|
||||
SortSubranges( aSortedRanges, (nDtaSrcIsColumns == 1) );
|
||||
OUString aSortedCellRanges;
|
||||
OUStringBuffer aSortedCellRanges;
|
||||
for (const OUString& rSortedRange : aSortedRanges)
|
||||
{
|
||||
if (!aSortedCellRanges.isEmpty())
|
||||
aSortedCellRanges += ";";
|
||||
aSortedCellRanges += rSortedRange;
|
||||
aSortedCellRanges.append(";");
|
||||
aSortedCellRanges.append(rSortedRange);
|
||||
}
|
||||
|
||||
// build value for 'SequenceMapping'
|
||||
@@ -1261,7 +1261,7 @@ uno::Sequence< beans::PropertyValue > SAL_CALL SwChartDataProvider::detectArgume
|
||||
pResult[nProps ].Name = "FirstCellAsLabel";
|
||||
pResult[nProps++].Value <<= bFirstCellIsLabel;
|
||||
pResult[nProps ].Name = "CellRangeRepresentation";
|
||||
pResult[nProps++].Value <<= aSortedCellRanges;
|
||||
pResult[nProps++].Value <<= aSortedCellRanges.toString();
|
||||
if (!aBrokenCellRangeForExport.isEmpty())
|
||||
{
|
||||
pResult[nProps ].Name = "BrokenCellRangeForExport";
|
||||
|
||||
@@ -918,11 +918,11 @@ SwHTMLWriter& OutHTML_DrawFrameFormatAsControl( SwHTMLWriter& rWrt,
|
||||
return rWrt;
|
||||
|
||||
const OString tag = rWrt.GetNamespace() + TagNames[eTag];
|
||||
OString sOut = OString::Concat("<") + tag;
|
||||
OStringBuffer sOut = OString::Concat("<") + tag;
|
||||
if( eType != TYPE_NONE )
|
||||
{
|
||||
sOut += OString::Concat(" " OOO_STRING_SVTOOLS_HTML_O_type "=\"") +
|
||||
TypeNames[eType] + "\"";
|
||||
sOut.append(OString::Concat(" " OOO_STRING_SVTOOLS_HTML_O_type "=\"") +
|
||||
TypeNames[eType] + "\"");
|
||||
}
|
||||
|
||||
aTmp = xPropSet->getPropertyValue(u"Name"_ustr);
|
||||
@@ -930,10 +930,10 @@ SwHTMLWriter& OutHTML_DrawFrameFormatAsControl( SwHTMLWriter& rWrt,
|
||||
{
|
||||
if( !s->isEmpty() )
|
||||
{
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_name "=\"";
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_name "=\"");
|
||||
rWrt.Strm().WriteOString( sOut );
|
||||
HTMLOutFuncs::Out_String( rWrt.Strm(), *s );
|
||||
sOut = "\""_ostr;
|
||||
sOut = "\"";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -942,19 +942,19 @@ SwHTMLWriter& OutHTML_DrawFrameFormatAsControl( SwHTMLWriter& rWrt,
|
||||
{
|
||||
if( !*b )
|
||||
{
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_disabled;
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_disabled);
|
||||
}
|
||||
}
|
||||
|
||||
if( !sValue.isEmpty() || bEmptyValue )
|
||||
{
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_value "=\"";
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_value "=\"");
|
||||
rWrt.Strm().WriteOString( sOut );
|
||||
HTMLOutFuncs::Out_String( rWrt.Strm(), sValue );
|
||||
sOut = "\""_ostr;
|
||||
sOut = "\"";
|
||||
}
|
||||
|
||||
sOut += " " + sOptions;
|
||||
sOut.append(" " + sOptions);
|
||||
|
||||
if( TYPE_IMAGE == eType )
|
||||
{
|
||||
@@ -963,11 +963,11 @@ SwHTMLWriter& OutHTML_DrawFrameFormatAsControl( SwHTMLWriter& rWrt,
|
||||
{
|
||||
if( !s->isEmpty() )
|
||||
{
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_src "=\"";
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_src "=\"");
|
||||
rWrt.Strm().WriteOString( sOut );
|
||||
|
||||
HTMLOutFuncs::Out_String(rWrt.Strm(), rWrt.normalizeURL(*s, false));
|
||||
sOut = "\""_ostr;
|
||||
sOut = "\"";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -975,14 +975,14 @@ SwHTMLWriter& OutHTML_DrawFrameFormatAsControl( SwHTMLWriter& rWrt,
|
||||
|
||||
if( aPixelSz.Width() )
|
||||
{
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_width "=\"" +
|
||||
OString::number(static_cast<sal_Int32>(aPixelSz.Width())) + "\"";
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_width "=\"" +
|
||||
OString::number(static_cast<sal_Int32>(aPixelSz.Width())) + "\"");
|
||||
}
|
||||
|
||||
if( aPixelSz.Height() )
|
||||
{
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_height "=\"" +
|
||||
OString::number(static_cast<sal_Int32>(aPixelSz.Height())) + "\"";
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_height "=\"" +
|
||||
OString::number(static_cast<sal_Int32>(aPixelSz.Height())) + "\"");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -995,8 +995,8 @@ SwHTMLWriter& OutHTML_DrawFrameFormatAsControl( SwHTMLWriter& rWrt,
|
||||
if( nTabIndex >= 32767 )
|
||||
nTabIndex = 32767;
|
||||
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_tabindex "=\"" +
|
||||
OString::number(static_cast<sal_Int32>(nTabIndex)) + "\"";
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_tabindex "=\"" +
|
||||
OString::number(static_cast<sal_Int32>(nTabIndex)) + "\"");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1181,15 +1181,15 @@ SwHTMLWriter& OutHTML_DrawFrameFormatAsControl( SwHTMLWriter& rWrt,
|
||||
sOut = "<" + rWrt.GetNamespace() + OOO_STRING_SVTOOLS_HTML_option;
|
||||
if( !sVal.isEmpty() || bEmptyVal )
|
||||
{
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_value "=\"";
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_value "=\"");
|
||||
rWrt.Strm().WriteOString( sOut );
|
||||
HTMLOutFuncs::Out_String( rWrt.Strm(), sVal );
|
||||
sOut = "\""_ostr;
|
||||
sOut = "\"";
|
||||
}
|
||||
if( bSelected )
|
||||
sOut += " " OOO_STRING_SVTOOLS_HTML_O_selected;
|
||||
sOut.append(" " OOO_STRING_SVTOOLS_HTML_O_selected);
|
||||
|
||||
sOut += ">";
|
||||
sOut.append(">");
|
||||
rWrt.Strm().WriteOString( sOut );
|
||||
|
||||
HTMLOutFuncs::Out_String( rWrt.Strm(), pStrings[i] );
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <mmconfigitem.hxx>
|
||||
#include <mailmergehelper.hxx>
|
||||
#include <officecfg/Office/Writer.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <vcl/svapp.hxx>
|
||||
#include <vcl/weld.hxx>
|
||||
#include <comphelper/processfactory.hxx>
|
||||
@@ -146,14 +147,14 @@ std::unique_ptr<SfxTabPage> SwMailConfigPage::Create(weld::Container* pPage, wel
|
||||
|
||||
OUString SwMailConfigPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"displayname_label"_ustr, u"address_label"_ustr, u"replyto_label"_ustr,
|
||||
u"label2"_ustr, u"server_label"_ustr, u"port_label"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"replytocb"_ustr, u"secure"_ustr };
|
||||
@@ -161,7 +162,7 @@ OUString SwMailConfigPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString buttons[] = { u"serverauthentication"_ustr, u"test"_ustr };
|
||||
@@ -169,10 +170,10 @@ OUString SwMailConfigPage::GetAllStrings()
|
||||
for (const auto& btn : buttons)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_button(btn))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwMailConfigPage::FillItemSet( SfxItemSet* /*rSet*/ )
|
||||
|
||||
@@ -568,14 +568,14 @@ IMPL_LINK_NOARG(SwLoadOptPage, StandardizedPageCountCheckHdl, weld::Toggleable&,
|
||||
|
||||
OUString SwLoadOptPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label2"_ustr, u"label1"_ustr, u"label3"_ustr, u"label5"_ustr,
|
||||
u"tablabel"_ustr, u"label4"_ustr, u"label7"_ustr, u"labelstandardpages"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -584,7 +584,7 @@ OUString SwLoadOptPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"always"_ustr, u"onrequest"_ustr, u"never"_ustr };
|
||||
@@ -592,10 +592,10 @@ OUString SwLoadOptPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwLoadOptPage::FillItemSet( SfxItemSet* rSet )
|
||||
@@ -1039,7 +1039,7 @@ std::unique_ptr<SfxTabPage> SwCaptionOptPage::Create(weld::Container* pPage, wel
|
||||
|
||||
OUString SwCaptionOptPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"label13"_ustr, u"label2"_ustr, u"label7"_ustr, u"numberingft"_ustr,
|
||||
u"numseparatorft"_ustr, u"separatorft"_ustr, u"label18"_ustr, u"label11"_ustr, u"label4"_ustr,
|
||||
u"label6"_ustr, u"label10"_ustr, u"label3"_ustr };
|
||||
@@ -1047,13 +1047,13 @@ OUString SwCaptionOptPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
if (const auto pString = m_xBuilder->weld_check_button(u"applyborder"_ustr))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwCaptionOptPage::FillItemSet( SfxItemSet* )
|
||||
|
||||
@@ -54,6 +54,7 @@
|
||||
#include <officecfg/Office/Common.hxx>
|
||||
#include <officecfg/Office/Writer.hxx>
|
||||
#include <officecfg/Office/WriterWeb.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <sal/macros.h>
|
||||
#include <sfx2/dialoghelper.hxx>
|
||||
#include <sfx2/printer.hxx>
|
||||
@@ -360,7 +361,7 @@ void SwContentOptPage::Reset(const SfxItemSet* rSet)
|
||||
|
||||
OUString SwContentOptPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[]
|
||||
= { u"guideslabel"_ustr, u"displaylabel"_ustr, u"displayfl1"_ustr, u"changeslabel"_ustr, u"label3"_ustr,
|
||||
u"hruler"_ustr, u"settingslabel"_ustr, u"measureunitlabel"_ustr, u"outlinelabel"_ustr };
|
||||
@@ -368,7 +369,7 @@ OUString SwContentOptPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"helplines"_ustr,
|
||||
@@ -390,10 +391,10 @@ OUString SwContentOptPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwContentOptPage::FillItemSet(SfxItemSet* rSet)
|
||||
@@ -600,13 +601,13 @@ std::unique_ptr<SfxTabPage> SwAddPrinterTabPage::Create( weld::Container* pPage,
|
||||
|
||||
OUString SwAddPrinterTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label2"_ustr, u"label10"_ustr, u"label1"_ustr, u"label5"_ustr, u"4"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -616,7 +617,7 @@ OUString SwAddPrinterTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"none"_ustr, u"only"_ustr, u"end"_ustr, u"endpage"_ustr, u"inmargins"_ustr };
|
||||
@@ -624,10 +625,10 @@ OUString SwAddPrinterTabPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwAddPrinterTabPage::FillItemSet( SfxItemSet* rCoreSet )
|
||||
@@ -934,19 +935,19 @@ static void lcl_SetColl(SwWrtShell* pWrtShell, sal_uInt16 nType,
|
||||
|
||||
OUString SwStdFontTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"font_label"_ustr, u"size_label"_ustr, u"default_label"_ustr,
|
||||
u"heading_label"_ustr, u"list_label"_ustr, u"caption_label"_ustr, u"index_label"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
sAllStrings += m_xStandardPB->get_label() + " ";
|
||||
sAllStrings.append(m_xStandardPB->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwStdFontTabPage::FillItemSet( SfxItemSet* )
|
||||
@@ -1439,7 +1440,7 @@ std::unique_ptr<SfxTabPage> SwTableOptionsTabPage::Create( weld::Container* pPag
|
||||
|
||||
OUString SwTableOptionsTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[]
|
||||
= { u"label1"_ustr, u"label3"_ustr, u"label4"_ustr, u"label5"_ustr, u"label6"_ustr, u"label10"_ustr, u"label2"_ustr,
|
||||
u"label14"_ustr, u"label15"_ustr, u"label16"_ustr, u"label11"_ustr, u"label12"_ustr, u"label13"_ustr };
|
||||
@@ -1447,7 +1448,7 @@ OUString SwTableOptionsTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[] = { u"header"_ustr, u"repeatheader"_ustr, u"dontsplit"_ustr, u"border"_ustr,
|
||||
@@ -1456,7 +1457,7 @@ OUString SwTableOptionsTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"fix"_ustr, u"fixprop"_ustr, u"var"_ustr };
|
||||
@@ -1464,10 +1465,10 @@ OUString SwTableOptionsTabPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwTableOptionsTabPage::FillItemSet( SfxItemSet* )
|
||||
@@ -1817,14 +1818,14 @@ void SwShdwCursorOptionsTabPage::PageCreated( const SfxAllItemSet& aSet )
|
||||
|
||||
OUString SwShdwCursorOptionsTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"layoutopt"_ustr, u"displayfl"_ustr, u"cursoropt"_ustr, u"cursorlabel"_ustr,
|
||||
u"fillmode"_ustr, u"lbImage"_ustr, u"lbDefaultAnchor"_ustr, u"autocomplete"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString checkButton[]
|
||||
@@ -1835,10 +1836,10 @@ OUString SwShdwCursorOptionsTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwShdwCursorOptionsTabPage::FillItemSet( SfxItemSet* rSet )
|
||||
@@ -2330,7 +2331,7 @@ std::unique_ptr<SfxTabPage> SwRedlineOptionsTabPage::Create( weld::Container* pP
|
||||
|
||||
OUString SwRedlineOptionsTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label2"_ustr, u"insert_label"_ustr, u"insertcolor_label"_ustr,
|
||||
u"label3"_ustr, u"deleted_label"_ustr, u"deletedcolor_label"_ustr,
|
||||
u"label4"_ustr, u"changed_label"_ustr, u"changedcolor_label"_ustr,
|
||||
@@ -2339,10 +2340,10 @@ OUString SwRedlineOptionsTabPage::GetAllStrings()
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwRedlineOptionsTabPage::FillItemSet( SfxItemSet* )
|
||||
@@ -2748,13 +2749,13 @@ std::unique_ptr<SfxTabPage> SwCompareOptionsTabPage::Create( weld::Container* pP
|
||||
|
||||
OUString SwCompareOptionsTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString labels[] = { u"label1"_ustr, u"setting"_ustr };
|
||||
|
||||
for (const auto& label : labels)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_label(label))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
OUString radioButton[] = { u"auto"_ustr, u"byword"_ustr, u"bycharacter"_ustr };
|
||||
@@ -2762,10 +2763,10 @@ OUString SwCompareOptionsTabPage::GetAllStrings()
|
||||
for (const auto& radio : radioButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_radio_button(radio))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwCompareOptionsTabPage::FillItemSet( SfxItemSet* )
|
||||
@@ -2889,7 +2890,7 @@ std::unique_ptr<SfxTabPage> SwTestTabPage::Create( weld::Container* pPage, weld:
|
||||
|
||||
OUString SwTestTabPage::GetAllStrings()
|
||||
{
|
||||
OUString sAllStrings;
|
||||
OUStringBuffer sAllStrings;
|
||||
OUString checkButton[] = { u"unused"_ustr, u"dynamic"_ustr, u"nocalm"_ustr,
|
||||
u"wysiwygdbg"_ustr, u"noidle"_ustr, u"noscreenadj"_ustr,
|
||||
u"winformat"_ustr, u"noscroll"_ustr, u"DrawingLayerNotLoading"_ustr,
|
||||
@@ -2898,13 +2899,13 @@ OUString SwTestTabPage::GetAllStrings()
|
||||
for (const auto& check : checkButton)
|
||||
{
|
||||
if (const auto pString = m_xBuilder->weld_check_button(check))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
}
|
||||
|
||||
if (const auto pString = m_xBuilder->weld_label(u"label1"_ustr))
|
||||
sAllStrings += pString->get_label() + " ";
|
||||
sAllStrings.append(pString->get_label() + " ");
|
||||
|
||||
return sAllStrings.replaceAll("_", "");
|
||||
return sAllStrings.toString().replaceAll("_", "");
|
||||
}
|
||||
|
||||
bool SwTestTabPage::FillItemSet( SfxItemSet* rCoreSet )
|
||||
|
||||
@@ -617,12 +617,12 @@ void GetDocStructureCharts(tools::JsonWriter& rJsonWriter, const SwDocShell* pDo
|
||||
uno::Reference<chart2::XTitle> xTitle = xTitled->getTitleObject();
|
||||
if (xTitle.is())
|
||||
{
|
||||
OUString aTitle;
|
||||
OUStringBuffer aTitle;
|
||||
const uno::Sequence<uno::Reference<chart2::XFormattedString>> aFSSeq
|
||||
= xTitle->getText();
|
||||
for (auto const& fs : aFSSeq)
|
||||
aTitle += fs->getString();
|
||||
rJsonWriter.put("title", aTitle);
|
||||
aTitle.append(fs->getString());
|
||||
rJsonWriter.put("title", aTitle.toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -633,12 +633,12 @@ void GetDocStructureCharts(tools::JsonWriter& rJsonWriter, const SwDocShell* pDo
|
||||
uno::Reference<chart2::XTitle> xSubTitle = xSubTitled->getTitleObject();
|
||||
if (xSubTitle.is())
|
||||
{
|
||||
OUString aSubTitle;
|
||||
OUStringBuffer aSubTitle;
|
||||
const uno::Sequence<uno::Reference<chart2::XFormattedString>> aFSSeq
|
||||
= xSubTitle->getText();
|
||||
for (auto const& fs : aFSSeq)
|
||||
aSubTitle += fs->getString();
|
||||
rJsonWriter.put("subtitle", aSubTitle);
|
||||
aSubTitle.append(fs->getString());
|
||||
rJsonWriter.put("subtitle", aSubTitle.makeStringAndClear());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -415,7 +415,7 @@ OUString AccessibilityTools::getRoleName(const sal_Int16 role)
|
||||
|
||||
OUString AccessibilityTools::debugAccessibleStateSet(const sal_Int64 nCombinedState)
|
||||
{
|
||||
OUString combinedName;
|
||||
OUStringBuffer combinedName;
|
||||
|
||||
for (int i = 0; i < 63; i++)
|
||||
{
|
||||
@@ -538,13 +538,13 @@ OUString AccessibilityTools::debugAccessibleStateSet(const sal_Int64 nCombinedSt
|
||||
break;
|
||||
}
|
||||
if (combinedName.getLength())
|
||||
combinedName += " | ";
|
||||
combinedName += name;
|
||||
combinedName.append(" | ");
|
||||
combinedName.append(name);
|
||||
}
|
||||
|
||||
if (combinedName.isEmpty())
|
||||
return u"unknown"_ustr;
|
||||
return combinedName;
|
||||
return combinedName.makeStringAndClear();
|
||||
}
|
||||
|
||||
OUString AccessibilityTools::getEventIdName(const sal_Int16 event_id)
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
#include <cppunit/TestFixture.h>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
#include <cppunit/plugin/TestPlugIn.h>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <rtl/ustring.hxx>
|
||||
#include <vector>
|
||||
|
||||
@@ -68,7 +69,7 @@ namespace
|
||||
sal_Int32 nLength = aAllChars.size();
|
||||
CPPUNIT_ASSERT_EQUAL(sOrigText.getLength(), nLength);
|
||||
|
||||
OUString sFinalText;
|
||||
OUStringBuffer sFinalText;
|
||||
|
||||
//Split up in chunks of the same encoding returned by
|
||||
//getBestMSEncodingByChar, convert to it, and back
|
||||
@@ -81,7 +82,7 @@ namespace
|
||||
if (eCurrEncoding != ePrevEncoding)
|
||||
{
|
||||
OString aChunk(pStr+nChunkStart, i-nChunkStart, ePrevEncoding);
|
||||
sFinalText += OStringToOUString(aChunk, ePrevEncoding);
|
||||
sFinalText.append(OStringToOUString(aChunk, ePrevEncoding));
|
||||
nChunkStart = i;
|
||||
}
|
||||
ePrevEncoding = eCurrEncoding;
|
||||
@@ -89,11 +90,11 @@ namespace
|
||||
if (nChunkStart < 255)
|
||||
{
|
||||
OString aChunk(pStr+nChunkStart, 255-nChunkStart, ePrevEncoding);
|
||||
sFinalText += OStringToOUString(aChunk, ePrevEncoding);
|
||||
sFinalText.append(OStringToOUString(aChunk, ePrevEncoding));
|
||||
}
|
||||
|
||||
//Final text should be the same as original
|
||||
CPPUNIT_ASSERT_EQUAL(sOrigText, sFinalText);
|
||||
CPPUNIT_ASSERT_EQUAL(sOrigText, sFinalText.toString());
|
||||
}
|
||||
|
||||
void Test::test1252()
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include <vcl/test/GraphicsRenderTests.hxx>
|
||||
#include <vcl/graphicfilter.hxx>
|
||||
#include <tools/stream.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
#include <svdata.hxx>
|
||||
#include <salinst.hxx>
|
||||
@@ -2234,41 +2235,41 @@ void GraphicsRenderTests::run(bool storeResultBitmap)
|
||||
{
|
||||
aTests[tests.getStatus()].push_back(tests.getTestName());
|
||||
}
|
||||
OUString writeResult = getResultString() + "\n---Name of the tests that failed---\n";
|
||||
OUStringBuffer writeResult(getResultString() + "\n---Name of the tests that failed---\n");
|
||||
if (static_cast<int>(aTests[u"FAILED"_ustr].size()) > 0)
|
||||
{
|
||||
for (const class OUString& tests : aTests[u"FAILED"_ustr])
|
||||
{
|
||||
writeResult += tests + "\n";
|
||||
writeResult.append(tests + "\n");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
writeResult += "No test has been failed.\n";
|
||||
writeResult.append("No test has been failed.\n");
|
||||
}
|
||||
writeResult += "\n---Name of the tests that were Quirky---\n";
|
||||
writeResult.append("\n---Name of the tests that were Quirky---\n");
|
||||
if (static_cast<int>(aTests[u"QUIRKY"_ustr].size()) > 0)
|
||||
{
|
||||
for (const class OUString& tests : aTests[u"QUIRKY"_ustr])
|
||||
{
|
||||
writeResult += tests + "\n";
|
||||
writeResult.append(tests + "\n");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
writeResult += "No test was Quirky.\n";
|
||||
writeResult.append("No test was Quirky.\n");
|
||||
}
|
||||
writeResult += "\n---Name of the tests that were Skipped---\n";
|
||||
writeResult.append("\n---Name of the tests that were Skipped---\n");
|
||||
if (static_cast<int>(aTests[u"SKIPPED"_ustr].size()) > 0)
|
||||
{
|
||||
for (const class OUString& tests : aTests[u"SKIPPED"_ustr])
|
||||
{
|
||||
writeResult += tests + "\n";
|
||||
writeResult.append(tests + "\n");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
writeResult += "No test was Skipped.";
|
||||
writeResult.append("No test was Skipped.");
|
||||
}
|
||||
logFile.WriteOString(OUStringToOString(writeResult, RTL_TEXTENCODING_UTF8));
|
||||
}
|
||||
|
||||
@@ -57,10 +57,10 @@ void FontFeatureTest::testGetFontFeaturesGraphite()
|
||||
std::vector<vcl::font::Feature> rFontFeatures;
|
||||
CPPUNIT_ASSERT(aVDev->GetFontFeatures(rFontFeatures));
|
||||
|
||||
OUString aFeaturesString;
|
||||
OUStringBuffer aFeaturesString;
|
||||
for (vcl::font::Feature const& rFeature : rFontFeatures)
|
||||
{
|
||||
aFeaturesString += vcl::font::featureCodeAsString(rFeature.m_nCode) + " ";
|
||||
aFeaturesString.append(vcl::font::featureCodeAsString(rFeature.m_nCode) + " ");
|
||||
}
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(53), rFontFeatures.size());
|
||||
@@ -72,7 +72,7 @@ void FontFeatureTest::testGetFontFeaturesGraphite()
|
||||
"itlc para algn arti circ dash dbls foot "
|
||||
"frsp grkn hang lng minu nfsp name quot "
|
||||
"texm thou vari caps ligc "_ustr,
|
||||
aFeaturesString);
|
||||
aFeaturesString.toString());
|
||||
|
||||
// Check C2SC feature
|
||||
{
|
||||
@@ -141,16 +141,16 @@ void FontFeatureTest::testGetFontFeaturesOpenType()
|
||||
std::vector<vcl::font::Feature> rFontFeatures;
|
||||
CPPUNIT_ASSERT(aVDev->GetFontFeatures(rFontFeatures));
|
||||
|
||||
OUString aFeaturesString;
|
||||
OUStringBuffer aFeaturesString;
|
||||
for (vcl::font::Feature const& rFeature : rFontFeatures)
|
||||
aFeaturesString += vcl::font::featureCodeAsString(rFeature.m_nCode) + " ";
|
||||
aFeaturesString.append(vcl::font::featureCodeAsString(rFeature.m_nCode) + " ");
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(15), rFontFeatures.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(u"dnom liga numr pnum ss01 ss02 "
|
||||
"ss03 ss04 ss05 ss06 ss07 ss08 kern kern "
|
||||
"ss05 "_ustr,
|
||||
aFeaturesString);
|
||||
aFeaturesString.toString());
|
||||
|
||||
// Check ss01 feature
|
||||
{
|
||||
@@ -190,15 +190,15 @@ void FontFeatureTest::testGetFontFeaturesOpenTypeEnum()
|
||||
std::vector<vcl::font::Feature> rFontFeatures;
|
||||
CPPUNIT_ASSERT(aVDev->GetFontFeatures(rFontFeatures));
|
||||
|
||||
OUString aFeaturesString;
|
||||
OUStringBuffer aFeaturesString;
|
||||
for (vcl::font::Feature const& rFeature : rFontFeatures)
|
||||
aFeaturesString += vcl::font::featureCodeAsString(rFeature.m_nCode) + " ";
|
||||
aFeaturesString.append(vcl::font::featureCodeAsString(rFeature.m_nCode) + " ");
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(size_t(10), rFontFeatures.size());
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(u"aalt case cv01 cv02 cv03 frac ordn sups "
|
||||
"zero kern "_ustr,
|
||||
aFeaturesString);
|
||||
aFeaturesString.toString());
|
||||
|
||||
// Check aalt feature
|
||||
{
|
||||
|
||||
@@ -3614,16 +3614,16 @@ CPPUNIT_TEST_FIXTURE(PdfExportTest, testTdf115967)
|
||||
// Make sure the elements inside a formula in a RTL document are exported
|
||||
// LTR ( m=750abc ) and not RTL ( m=057cba )
|
||||
int nPageObjectCount = pPdfPage->getObjectCount();
|
||||
OUString sText;
|
||||
OUStringBuffer sText;
|
||||
for (int i = 0; i < nPageObjectCount; ++i)
|
||||
{
|
||||
std::unique_ptr<vcl::pdf::PDFiumPageObject> pPageObject = pPdfPage->getObject(i);
|
||||
if (pPageObject->getType() != vcl::pdf::PDFPageObjectType::Text)
|
||||
continue;
|
||||
OUString sChar = pPageObject->getText(pTextPage);
|
||||
sText += o3tl::trim(sChar);
|
||||
sText.append(o3tl::trim(sChar));
|
||||
}
|
||||
CPPUNIT_ASSERT_EQUAL(u"m=750abc"_ustr, sText);
|
||||
CPPUNIT_ASSERT_EQUAL(u"m=750abc"_ustr, sText.toString());
|
||||
}
|
||||
|
||||
CPPUNIT_TEST_FIXTURE(PdfExportTest, testTdf167659)
|
||||
|
||||
@@ -188,7 +188,7 @@ CPPUNIT_TEST_FIXTURE(PdfExportTest2, testTdf159895)
|
||||
auto pStart = static_cast<const char*>(aUncompressed.GetData());
|
||||
const char* const pEnd = pStart + aUncompressed.GetSize();
|
||||
|
||||
OString sText;
|
||||
OStringBuffer sText;
|
||||
while (true)
|
||||
{
|
||||
auto const pLine = ::std::find(pStart, pEnd, '\n');
|
||||
@@ -199,10 +199,10 @@ CPPUNIT_TEST_FIXTURE(PdfExportTest2, testTdf159895)
|
||||
pStart = pLine + 1;
|
||||
if (!line.empty() && line[0] != '%')
|
||||
{
|
||||
sText += line + "\n"_ostr;
|
||||
sText.append(line + "\n"_ostr);
|
||||
}
|
||||
}
|
||||
CPPUNIT_ASSERT_EQUAL("/Tx BMC\nEMC\n"_ostr, sText);
|
||||
CPPUNIT_ASSERT_EQUAL("/Tx BMC\nEMC\n"_ostr, sText.toString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
#include <string_view>
|
||||
|
||||
#include <vcl/skia/SkiaHelper.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
#if !HAVE_FEATURE_SKIA
|
||||
|
||||
@@ -125,12 +126,12 @@ OUString readLog()
|
||||
{
|
||||
SvFileStream logFile(getCacheFolder() + "/skia.log", StreamMode::READ);
|
||||
|
||||
OUString sResult;
|
||||
OUStringBuffer sResult;
|
||||
OStringBuffer sLine;
|
||||
while (logFile.ReadLine(sLine))
|
||||
sResult += OStringToOUString(sLine, RTL_TEXTENCODING_UTF8) + "\n";
|
||||
sResult.append(OStringToOUString(sLine, RTL_TEXTENCODING_UTF8) + "\n");
|
||||
|
||||
return sResult;
|
||||
return sResult.toString();
|
||||
}
|
||||
|
||||
uint32_t vendorId = 0;
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
#include <com/sun/star/text/TextMarkupType.hpp>
|
||||
#include <o3tl/any.hxx>
|
||||
#include <tools/color.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
|
||||
namespace
|
||||
{
|
||||
@@ -245,7 +246,7 @@ static OUString ConvertUnoToIAccessible2TextAttributes(
|
||||
const css::uno::Sequence<css::beans::PropertyValue>& rUnoAttributes,
|
||||
IA2AttributeType eAttributeType)
|
||||
{
|
||||
OUString aRet;
|
||||
OUStringBuffer aRet;
|
||||
for (css::beans::PropertyValue const& prop : rUnoAttributes)
|
||||
{
|
||||
OUString sAttribute;
|
||||
@@ -291,7 +292,7 @@ static OUString ConvertUnoToIAccessible2TextAttributes(
|
||||
else if (prop.Name == "CharStrikeout")
|
||||
{
|
||||
const sal_Int16 nStrikeout = *o3tl::doAccess<sal_Int16>(prop.Value);
|
||||
aRet += lcl_ConverCharStrikeout(nStrikeout);
|
||||
aRet.append(lcl_ConverCharStrikeout(nStrikeout));
|
||||
}
|
||||
else if (prop.Name == "CharUnderline")
|
||||
{
|
||||
@@ -304,11 +305,11 @@ static OUString ConvertUnoToIAccessible2TextAttributes(
|
||||
|
||||
// leave 'sAttribute' and 'sName' empty, set all attributes here
|
||||
if (!sUnderlineStyle.isEmpty())
|
||||
aRet += u"text-underline-style:" + sUnderlineStyle + ";";
|
||||
aRet.append(u"text-underline-style:" + sUnderlineStyle + ";");
|
||||
if (!sUnderlineType.isEmpty())
|
||||
aRet += u"text-underline-type:" + sUnderlineType + ";";
|
||||
aRet.append(u"text-underline-type:" + sUnderlineType + ";");
|
||||
if (!sUnderlineWidth.isEmpty())
|
||||
aRet += u"text-underline-width:" + sUnderlineWidth + ";";
|
||||
aRet.append(u"text-underline-width:" + sUnderlineWidth + ";");
|
||||
}
|
||||
else if (prop.Name == "CharWeight")
|
||||
{
|
||||
@@ -338,10 +339,10 @@ static OUString ConvertUnoToIAccessible2TextAttributes(
|
||||
}
|
||||
|
||||
if (!sAttribute.isEmpty() && !sValue.isEmpty())
|
||||
aRet += sAttribute + ":" + sValue + ";";
|
||||
aRet.append(sAttribute + ":" + sValue + ";");
|
||||
}
|
||||
|
||||
return aRet;
|
||||
return aRet.toString();
|
||||
}
|
||||
|
||||
OUString AccessibleTextAttributeHelper::GetIAccessible2TextAttributes(
|
||||
|
||||
@@ -3003,13 +3003,13 @@ void RadioButton::DumpAsPropertyTree(tools::JsonWriter& rJsonWriter)
|
||||
Button::DumpAsPropertyTree(rJsonWriter);
|
||||
rJsonWriter.put("checked", IsChecked());
|
||||
|
||||
OUString sGroupId;
|
||||
OUStringBuffer sGroupId;
|
||||
std::vector<VclPtr<RadioButton>> aGroup = GetRadioButtonGroup();
|
||||
for(const auto& pButton : aGroup)
|
||||
sGroupId += pButton->get_id();
|
||||
sGroupId.append(pButton->get_id());
|
||||
|
||||
if (!sGroupId.isEmpty())
|
||||
rJsonWriter.put("group", sGroupId);
|
||||
rJsonWriter.put("group", sGroupId.toString());
|
||||
|
||||
if (!!maImage)
|
||||
{
|
||||
|
||||
@@ -461,11 +461,11 @@ void EmbeddedFontsManager::activateFonts(std::vector<std::pair<OUString, OUStrin
|
||||
std::set<OUString> filteredFamilies; // families can repeat, e.g. for bold/italic
|
||||
for (const auto& pair : temp)
|
||||
filteredFamilies.insert(pair.first);
|
||||
OUString fontlist;
|
||||
OUStringBuffer fontlist;
|
||||
for (const auto& family : filteredFamilies)
|
||||
fontlist += "\n" + family;
|
||||
fontlist.append("\n" + family);
|
||||
rtl::Reference pRequest(new comphelper::OInteractionRequest(
|
||||
uno::Any(document::FontsDisallowEditingRequest({}, {}, fontlist))));
|
||||
uno::Any(document::FontsDisallowEditingRequest({}, {}, fontlist.toString()))));
|
||||
rtl::Reference pApprove(new comphelper::OInteractionApprove);
|
||||
pRequest->addContinuation(pApprove);
|
||||
pRequest->addContinuation(new comphelper::OInteractionDisapprove);
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include <comphelper/sequence.hxx>
|
||||
#include <comphelper/xmlsechelper.hxx>
|
||||
#include <comphelper/lok.hxx>
|
||||
#include <rtl/ustrbuf.hxx>
|
||||
#include <sfx2/viewsh.hxx>
|
||||
#include <svl/cryptosign.hxx>
|
||||
|
||||
@@ -321,15 +322,14 @@ void CertificateChooser::ImplInitialize(bool mbSearch)
|
||||
seqLoadedCertsLabels.push_back(XsResId(STR_LOADED_CERTS_X509_NSS_NEWLINE) + nssPath);
|
||||
#endif // _WIN32
|
||||
}
|
||||
OUString loadedCertsLabel = XsResId(STR_LOADED_CERTS_BASE
|
||||
);
|
||||
OUStringBuffer loadedCertsLabel(XsResId(STR_LOADED_CERTS_BASE));
|
||||
for (size_t label_i=0; label_i<seqLoadedCertsLabels.size(); label_i++)
|
||||
{
|
||||
if (label_i > 0)
|
||||
loadedCertsLabel += ", ";
|
||||
loadedCertsLabel += seqLoadedCertsLabels[label_i];
|
||||
loadedCertsLabel.append(", ");
|
||||
loadedCertsLabel.append(seqLoadedCertsLabels[label_i]);
|
||||
}
|
||||
m_xFTLoadedCerts->set_label(loadedCertsLabel);
|
||||
m_xFTLoadedCerts->set_label(loadedCertsLabel.toString());
|
||||
m_xFTLoadedCerts->set_visible(true);
|
||||
|
||||
m_xCertLB->thaw();
|
||||
|
||||
Reference in New Issue
Block a user