/vcl/inc/qt5/

reoffice-7-1 LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat
-rw-r--r--avmedia/source/framework/mediaitem.cxx4
-rw-r--r--basctl/qa/unit/basctl-dialogs-test.cxx2
-rw-r--r--basctl/source/basicide/bastype3.cxx4
-rw-r--r--basctl/source/basicide/bastypes.cxx18
-rw-r--r--basctl/source/basicide/localizationmgr.cxx37
-rw-r--r--basctl/source/basicide/moduldlg.cxx4
-rw-r--r--basctl/source/basicide/moduldlg.hxx6
-rw-r--r--basctl/source/inc/basidesh.hxx3
-rw-r--r--basctl/source/inc/bastypes.hxx13
-rw-r--r--basctl/source/inc/localizationmgr.hxx24
-rw-r--r--basic/qa/cppunit/basic_coverage.cxx2
-rw-r--r--basic/qa/cppunit/test_vba.cxx2
-rw-r--r--basic/source/classes/sbunoobj.cxx10
-rw-r--r--basic/source/inc/sbunoobj.hxx2
-rw-r--r--basic/source/uno/namecont.cxx7
-rw-r--r--canvas/source/tools/propertysethelper.cxx10
-rw-r--r--chart2/qa/extras/PivotChartTest.cxx4
-rw-r--r--chart2/qa/extras/chart2_trendcalculators.cxx2
-rw-r--r--chart2/qa/extras/chart2dump/chart2dump.cxx21
-rw-r--r--chart2/qa/extras/chart2export.cxx304
-rw-r--r--chart2/qa/extras/chart2geometry.cxx28
-rw-r--r--chart2/qa/extras/chart2import.cxx222
-rw-r--r--chart2/qa/extras/charttest.hxx13
-rw-r--r--chart2/qa/extras/xshape/chart2xshape.cxx28
-rw-r--r--chart2/qa/unit/chart2-dialogs-test.cxx2
-rw-r--r--chart2/source/inc/ObjectIdentifier.hxx6
-rw-r--r--chart2/source/tools/ObjectIdentifier.cxx2
-rw-r--r--codemaker/source/codemaker/typemanager.cxx2
-rw-r--r--codemaker/source/commoncpp/commoncpp.cxx4
-rw-r--r--codemaker/source/commonjava/commonjava.cxx4
-rw-r--r--codemaker/source/cppumaker/cpputype.cxx54
-rw-r--r--codemaker/source/cppumaker/dependencies.cxx6
-rw-r--r--codemaker/source/cppumaker/dependencies.hxx3
-rw-r--r--codemaker/source/javamaker/javatype.cxx57
-rw-r--r--comphelper/source/misc/DirectoryHelper.cxx7
-rw-r--r--comphelper/source/misc/backupfilehelper.cxx95
-rw-r--r--comphelper/source/misc/configuration.cxx7
-rw-r--r--comphelper/source/property/propertystatecontainer.cxx8
-rw-r--r--comphelper/source/xml/ofopxmlhelper.cxx4
-rw-r--r--compilerplugins/clang/stringviewparam.cxx5
-rw-r--r--configmgr/source/components.cxx4
-rw-r--r--configmgr/source/components.hxx3
-rw-r--r--configmgr/source/writemodfile.cxx6
-rw-r--r--configmgr/source/xcuparser.cxx6
-rw-r--r--configmgr/source/xcuparser.hxx3
-rw-r--r--connectivity/qa/connectivity/ado/DriverTest.cxx2
-rw-r--r--connectivity/source/commontools/TColumnsHelper.cxx2
-rw-r--r--connectivity/source/commontools/dbtools2.cxx6
-rw-r--r--connectivity/source/drivers/firebird/DatabaseMetaData.cxx6
-rw-r--r--connectivity/source/drivers/firebird/DatabaseMetaData.hxx6
-rw-r--r--connectivity/source/drivers/firebird/Table.cxx2
-rw-r--r--connectivity/source/drivers/firebird/Table.hxx6
-rw-r--r--connectivity/source/drivers/hsqldb/HTable.cxx2
-rw-r--r--connectivity/source/drivers/mysql_jdbc/YTable.cxx2
-rw-r--r--connectivity/source/drivers/postgresql/pq_databasemetadata.cxx8
-rw-r--r--connectivity/source/drivers/postgresql/pq_statement.cxx2
-rw-r--r--connectivity/source/drivers/postgresql/pq_statement.hxx7
-rw-r--r--connectivity/source/drivers/postgresql/pq_tools.cxx4
-rw-r--r--connectivity/source/drivers/postgresql/pq_tools.hxx2
-rw-r--r--connectivity/source/inc/hsqldb/HTable.hxx6
-rw-r--r--connectivity/source/inc/mysql/YTable.hxx6
-rw-r--r--connectivity/source/parse/sqlnode.cxx4
-rw-r--r--cppu/source/uno/lbenv.cxx4
-rw-r--r--cppuhelper/source/servicemanager.cxx12
-rw-r--r--cppuhelper/source/servicemanager.hxx5
-rw-r--r--cppuhelper/source/shlib.cxx7
-rw-r--r--cui/qa/unit/cui-dialogs-test.cxx2
-rw-r--r--cui/qa/unit/cui-dialogs-test_2.cxx2
-rw-r--r--cui/qa/unit/cui-dialogs-test_3.cxx2
-rw-r--r--cui/qa/unit/cui-dialogs-test_4.cxx2
-rw-r--r--cui/source/customize/cfg.cxx4
-rw-r--r--cui/source/customize/cfgutil.cxx9
-rw-r--r--cui/source/dialogs/SignatureLineDialogBase.cxx4
-rw-r--r--cui/source/dialogs/cuigaldlg.cxx4
-rw-r--r--cui/source/dialogs/postdlg.cxx4
-rw-r--r--cui/source/dialogs/screenshotannotationdlg.cxx10
-rw-r--r--cui/source/dialogs/scriptdlg.cxx13
-rw-r--r--cui/source/inc/SignatureLineDialogBase.hxx6
-rw-r--r--cui/source/inc/cfg.hxx3
-rw-r--r--cui/source/inc/cfgutil.hxx6
-rw-r--r--cui/source/inc/cuigaldlg.hxx4
-rw-r--r--cui/source/inc/postdlg.hxx6
-rw-r--r--cui/source/options/optsave.cxx16
-rw-r--r--dbaccess/qa/extras/dialog-save.cxx2
-rw-r--r--dbaccess/qa/extras/empty-stdlib-save.cxx2
-rw-r--r--dbaccess/qa/extras/macros-test.cxx2
-rw-r--r--dbaccess/qa/extras/nolib-save.cxx2
-rw-r--r--dbaccess/qa/extras/rowsetclones.cxx2
-rw-r--r--dbaccess/qa/unit/dbaccess-dialogs-test.cxx2
-rw-r--r--dbaccess/qa/unit/dbtest_base.cxx10
-rw-r--r--dbaccess/qa/unit/embeddeddb_performancetest.cxx2
-rw-r--r--dbaccess/qa/unit/firebird-regression.cxx4
-rw-r--r--dbaccess/qa/unit/firebird.cxx4
-rw-r--r--dbaccess/qa/unit/hsql_binary_import.cxx2
-rw-r--r--dbaccess/qa/unit/hsqldb.cxx2
-rw-r--r--dbaccess/qa/unit/tdf119625.cxx2
-rw-r--r--dbaccess/qa/unit/tdf126268.cxx2
-rw-r--r--dbaccess/source/core/api/KeySet.cxx8
-rw-r--r--dbaccess/source/core/api/SingleSelectQueryComposer.cxx2
-rw-r--r--dbaccess/source/filter/hsqldb/parseschema.cxx8
-rw-r--r--dbaccess/source/ui/app/DocumentInfoPreview.cxx4
-rw-r--r--dbaccess/source/ui/app/DocumentInfoPreview.hxx5
-rw-r--r--dbaccess/source/ui/dlg/directsql.cxx11
-rw-r--r--dbaccess/source/ui/inc/directsql.hxx5
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignView.cxx5
-rw-r--r--desktop/inc/app.hxx3
-rw-r--r--desktop/inc/lib/init.hxx3
-rw-r--r--desktop/qa/desktop_lib/test_desktop_lib.cxx63
-rw-r--r--desktop/qa/unit/desktop-dialogs-test.cxx2
-rw-r--r--desktop/source/app/app.cxx7
-rw-r--r--desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx9
-rw-r--r--desktop/source/deployment/gui/dp_gui_updateinstalldialog.hxx6
-rw-r--r--desktop/source/deployment/gui/license_dialog.cxx5
-rw-r--r--desktop/source/deployment/inc/dp_descriptioninfoset.hxx6
-rw-r--r--desktop/source/deployment/inc/dp_identifier.hxx6
-rw-r--r--desktop/source/deployment/manager/dp_extensionmanager.cxx3
-rw-r--r--desktop/source/deployment/manager/dp_manager.cxx2
-rw-r--r--desktop/source/deployment/manager/dp_manager.h4
-rw-r--r--desktop/source/deployment/manager/dp_properties.cxx8
-rw-r--r--desktop/source/deployment/manager/dp_properties.hxx5
-rw-r--r--desktop/source/deployment/misc/dp_descriptioninfoset.cxx18
-rw-r--r--desktop/source/deployment/misc/dp_identifier.cxx6
-rw-r--r--desktop/source/deployment/registry/component/dp_compbackenddb.cxx22
-rw-r--r--desktop/source/deployment/registry/component/dp_compbackenddb.hxx4
-rw-r--r--desktop/source/deployment/registry/component/dp_component.cxx8
-rw-r--r--desktop/source/deployment/registry/configuration/dp_configuration.cxx23
-rw-r--r--desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx10
-rw-r--r--desktop/source/deployment/registry/configuration/dp_configurationbackenddb.hxx4
-rw-r--r--desktop/source/deployment/registry/dp_backenddb.cxx40
-rw-r--r--desktop/source/deployment/registry/executable/dp_executable.cxx10
-rw-r--r--desktop/source/deployment/registry/help/dp_help.cxx13
-rw-r--r--desktop/source/deployment/registry/help/dp_helpbackenddb.cxx8
-rw-r--r--desktop/source/deployment/registry/help/dp_helpbackenddb.hxx4
-rw-r--r--desktop/source/deployment/registry/inc/dp_backenddb.hxx41
-rw-r--r--desktop/source/deployment/registry/package/dp_extbackenddb.cxx10
-rw-r--r--desktop/source/deployment/registry/package/dp_extbackenddb.hxx5
-rw-r--r--desktop/source/deployment/registry/package/dp_package.cxx9
-rw-r--r--desktop/source/deployment/registry/script/dp_script.cxx10
-rw-r--r--desktop/source/lib/init.cxx24
-rw-r--r--desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx7
-rw-r--r--desktop/source/pkgchk/unopkg/unopkg_misc.cxx18
-rw-r--r--editeng/source/lookuptree/Trie.cxx14
-rw-r--r--embeddedobj/qa/cppunit/general.cxx6
-rw-r--r--embeddedobj/source/msole/oleembed.cxx2
-rw-r--r--embeddedobj/source/msole/ownview.cxx6
-rw-r--r--embeddedobj/source/msole/ownview.hxx6
-rw-r--r--emfio/qa/cppunit/emf/EmfImportTest.cxx23
-rw-r--r--emfio/qa/cppunit/wmf/wmfimporttest.cxx18
-rw-r--r--extensions/qa/update/test_update.cxx14
-rw-r--r--extensions/source/propctrlr/eformshelper.cxx6
-rw-r--r--extensions/source/propctrlr/eventhandler.cxx3
-rw-r--r--extensions/source/update/check/updateprotocol.cxx8
-rw-r--r--extensions/source/update/check/updateprotocol.hxx10
-rw-r--r--extensions/source/update/feed/updatefeed.cxx14
-rw-r--r--filter/qa/cppunit/filters-dxf-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-eps-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-met-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-pcd-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-pcx-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-pict-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-ppm-test.cxx4
-rw-r--r--filter/qa/cppunit/filters-psd-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-ras-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-tga-test.cxx2
-rw-r--r--filter/qa/cppunit/filters-tiff-test.cxx2
-rw-r--r--filter/qa/cppunit/xslt-test.cxx12
-rw-r--r--filter/qa/unit/filter-dialogs-test.cxx2
-rw-r--r--filter/qa/unit/svg.cxx16
-rw-r--r--filter/source/msfilter/mstoolbar.cxx5
-rw-r--r--filter/source/msfilter/msvbahelper.cxx2
-rw-r--r--filter/source/pdf/impdialog.cxx4
-rw-r--r--filter/source/pdf/pdffilter.cxx2
-rw-r--r--filter/source/svg/svgexport.cxx11
-rw-r--r--filter/source/svg/svgfilter.hxx3
-rw-r--r--filter/source/xsltdialog/typedetectionexport.cxx7
-rw-r--r--filter/source/xsltdialog/xmlfiltercommon.hxx3
-rw-r--r--filter/source/xsltdialog/xmlfiltersettingsdialog.cxx6
-rw-r--r--forms/source/component/DatabaseForm.cxx12
-rw-r--r--forms/source/component/DatabaseForm.hxx6
-rw-r--r--forms/source/xforms/submission.cxx11
-rw-r--r--formula/qa/unit/formula-dialogs-test.cxx2
-rw-r--r--fpicker/qa/unit/fpicker-dialogs-test.cxx2
-rw-r--r--fpicker/source/office/iodlg.cxx16
-rw-r--r--fpicker/source/office/iodlg.hxx4
-rw-r--r--fpicker/source/office/iodlgimp.cxx8
-rw-r--r--framework/inc/helper/persistentwindowstate.hxx4
-rw-r--r--framework/inc/jobs/helponstartup.hxx10
-rw-r--r--framework/inc/jobs/jobdata.hxx3
-rw-r--r--framework/inc/uifactory/configurationaccessfactorymanager.hxx7
-rw-r--r--framework/inc/uifactory/factoryconfiguration.hxx10
-rw-r--r--framework/source/accelerators/acceleratorconfiguration.cxx10
-rw-r--r--framework/source/accelerators/presethandler.cxx16
-rw-r--r--framework/source/fwe/classes/addonsoptions.cxx68
-rw-r--r--framework/source/helper/persistentwindowstate.cxx8
-rw-r--r--framework/source/inc/accelerators/presethandler.hxx12
-rw-r--r--framework/source/jobs/helponstartup.cxx8
-rw-r--r--framework/source/jobs/jobdata.cxx4
-rw-r--r--framework/source/services/pathsettings.cxx15
-rw-r--r--framework/source/uiconfiguration/ImageList.cxx4
-rw-r--r--framework/source/uiconfiguration/ImageList.hxx4
-rw-r--r--framework/source/uiconfiguration/uicategorydescription.cxx8
-rw-r--r--framework/source/uiconfiguration/windowstateconfiguration.cxx8
-rw-r--r--framework/source/uielement/uicommanddescription.cxx16
-rw-r--r--framework/source/uifactory/factoryconfiguration.cxx31
-rw-r--r--framework/source/uifactory/uicontrollerfactory.cxx19
-rw-r--r--framework/source/uifactory/uielementfactorymanager.cxx19
-rw-r--r--helpcompiler/source/HelpIndexer.cxx6
-rw-r--r--helpcompiler/source/HelpLinker.cxx4
-rw-r--r--hwpfilter/qa/cppunit/test_hwpfilter.cxx2
-rw-r--r--i18nlangtag/source/languagetag/languagetag.cxx4
-rw-r--r--i18npool/inc/indexentrysupplier.hxx6
-rw-r--r--i18npool/source/indexentry/indexentrysupplier.cxx12
-rw-r--r--i18npool/source/nativenumber/nativenumbersupplier.cxx8
-rw-r--r--include/avmedia/mediaitem.hxx4
-rw-r--r--include/codemaker/commoncpp.hxx2
-rw-r--r--include/codemaker/commonjava.hxx4
-rw-r--r--include/codemaker/typemanager.hxx2
-rw-r--r--include/comphelper/DirectoryHelper.hxx3
-rw-r--r--include/comphelper/backupfilehelper.hxx19
-rw-r--r--include/comphelper/configuration.hxx4
-rw-r--r--include/comphelper/ofopxmlhelper.hxx6
-rw-r--r--include/connectivity/dbtools.hxx4
-rw-r--r--include/filter/msfilter/mstoolbar.hxx3
-rw-r--r--include/filter/msfilter/msvbahelper.hxx6
-rw-r--r--include/helpcompiler/HelpIndexer.hxx3
-rw-r--r--include/helpcompiler/compilehelp.hxx2
-rw-r--r--include/i18nlangtag/languagetag.hxx3
-rw-r--r--include/oox/core/contexthandler.hxx3
-rw-r--r--include/oox/core/relations.hxx5
-rw-r--r--include/oox/core/xmlfilterbase.hxx3
-rw-r--r--include/oox/drawingml/shape.hxx3
-rw-r--r--include/oox/dump/dumperbase.hxx4
-rw-r--r--include/oox/export/drawingml.hxx3
-rw-r--r--include/oox/export/vmlexport.hxx6
-rw-r--r--include/oox/ole/vbaproject.hxx5
-rw-r--r--include/sfx2/linkmgr.hxx6
-rw-r--r--include/sfx2/lokhelper.hxx4
-rw-r--r--include/sfx2/notebookbar/SfxNotebookBar.hxx7
-rw-r--r--include/sfx2/objsh.hxx4
-rw-r--r--include/svl/lockfilecommon.hxx4
-rw-r--r--include/svtools/HtmlWriter.hxx2
-rw-r--r--include/svtools/parhtml.hxx3
-rw-r--r--include/svx/SmartTagMgr.hxx5
-rw-r--r--include/svx/xmlgrhlp.hxx5
-rw-r--r--include/test/helper/form.hxx7
-rw-r--r--include/test/helper/shape.hxx10
-rw-r--r--include/test/screenshot_test.hxx2
-rw-r--r--include/test/unoapi_test.hxx5
-rw-r--r--include/test/xmltesttools.hxx3
-rw-r--r--include/unotest/directories.hxx10
-rw-r--r--include/unotest/filters-test.hxx6
-rw-r--r--include/unotest/gettestargument.hxx6
-rw-r--r--include/unotools/optionsdlg.hxx16
-rw-r--r--include/vbahelper/vbahelper.hxx5
-rw-r--r--include/vbahelper/vbashapes.hxx3
-rw-r--r--include/vcl/FilterConfigItem.hxx10
-rw-r--r--include/vcl/embeddedfontshelper.hxx5
-rw-r--r--include/vcl/formatter.hxx3
-rw-r--r--include/vcl/opengl/OpenGLHelper.hxx7
-rw-r--r--include/xmloff/xmlimp.hxx3
-rw-r--r--io/source/acceptor/acceptor.cxx5
-rw-r--r--jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx8
-rw-r--r--l10ntools/inc/common.hxx4
-rw-r--r--l10ntools/inc/export.hxx11
-rw-r--r--l10ntools/inc/helper.hxx5
-rw-r--r--l10ntools/inc/helpmerge.hxx6
-rw-r--r--l10ntools/inc/po.hxx10
-rw-r--r--l10ntools/inc/xrmmerge.hxx4
-rw-r--r--l10ntools/source/common.cxx2
-rw-r--r--l10ntools/source/helper.cxx4
-rw-r--r--l10ntools/source/helpmerge.cxx2
-rw-r--r--l10ntools/source/merge.cxx12
-rw-r--r--l10ntools/source/po.cxx18
-rw-r--r--l10ntools/source/xrmmerge.cxx4
-rw-r--r--linguistic/source/convdiclist.cxx6
-rw-r--r--linguistic/source/misc2.cxx17
-rw-r--r--lotuswordpro/qa/cppunit/test_lotuswordpro.cxx2
-rw-r--r--oox/qa/unit/shape.cxx12
-rw-r--r--oox/qa/unit/vba_compression.cxx28
-rw-r--r--oox/qa/unit/vml.cxx14
-rw-r--r--oox/source/core/contexthandler.cxx3
-rw-r--r--oox/source/core/relations.cxx18
-rw-r--r--oox/source/core/xmlfilterbase.cxx11
-rw-r--r--oox/source/drawingml/diagram/diagram.cxx2
-rw-r--r--oox/source/drawingml/graphicshapecontext.cxx8
-rw-r--r--oox/source/drawingml/shape.cxx6
-rw-r--r--oox/source/dump/dumperbase.cxx7
-rw-r--r--oox/source/export/drawingml.cxx9
-rw-r--r--oox/source/export/vmlexport.cxx7
-rw-r--r--oox/source/ole/vbaproject.cxx8
-rw-r--r--oox/source/ppt/pptimport.cxx8
-rw-r--r--oox/source/ppt/presentationfragmenthandler.cxx10
-rw-r--r--oox/source/ppt/slidefragmenthandler.cxx4
-rw-r--r--oox/source/shape/ShapeContextHandler.cxx4
-rw-r--r--oox/source/shape/ShapeFilterBase.cxx2
-rw-r--r--opencl/inc/opencl_device.hxx6
-rw-r--r--opencl/source/opencl_device.cxx9
-rw-r--r--package/inc/ZipPackageFolder.hxx4
-rw-r--r--package/qa/cppunit/test_package.cxx4
-rw-r--r--package/source/xstor/owriteablestream.cxx14
-rw-r--r--package/source/xstor/owriteablestream.hxx5
-rw-r--r--package/source/xstor/xstorage.cxx23
-rw-r--r--package/source/xstor/xstorage.hxx8
-rw-r--r--package/source/zippackage/ZipPackage.cxx3
-rw-r--r--package/source/zippackage/ZipPackageFolder.cxx8
-rw-r--r--pyuno/source/module/pyuno_impl.hxx6
-rw-r--r--pyuno/source/module/pyuno_util.cxx12
-rw-r--r--registry/source/keyimpl.cxx37
-rw-r--r--registry/source/keyimpl.hxx22
-rw-r--r--reportdesign/qa/unit/reportdesign-dialogs-test.cxx2
-rw-r--r--reportdesign/source/ui/inc/GeometryHandler.hxx4
-rw-r--r--reportdesign/source/ui/inspection/GeometryHandler.cxx6
-rw-r--r--sax/qa/cppunit/xmlimport.cxx2
-rw-r--r--sax/source/expatwrap/sax_expat.cxx5
-rw-r--r--sc/inc/addincol.hxx3
-rw-r--r--sc/inc/calcconfig.hxx3
-rw-r--r--sc/inc/chartlis.hxx3
-rw-r--r--sc/inc/dpdimsave.hxx4
-rw-r--r--sc/inc/global.hxx5
-rw-r--r--sc/inc/unitconv.hxx7
-rw-r--r--sc/qa/extras/anchor.cxx16
-rw-r--r--sc/qa/extras/htmlexporttest.cxx8
-rw-r--r--sc/qa/extras/macros-test.cxx30
-rw-r--r--sc/qa/extras/new_cond_format.cxx2
-rw-r--r--sc/qa/extras/recordchanges-test.cxx2
-rw-r--r--sc/qa/extras/scannotationobj.cxx2
-rw-r--r--sc/qa/extras/scannotationsobj.cxx2
-rw-r--r--sc/qa/extras/scarealinkobj.cxx4
-rw-r--r--sc/qa/extras/sccellcursorobj.cxx2
-rw-r--r--sc/qa/extras/sccellrangeobj.cxx2
-rw-r--r--sc/qa/extras/scdatabaserangeobj.cxx2
-rw-r--r--sc/qa/extras/scdatapilotfieldobj.cxx2
-rw-r--r--sc/qa/extras/scdatapilottableobj.cxx2
-rw-r--r--sc/qa/extras/scddelinkobj.cxx2
-rw-r--r--sc/qa/extras/scddelinksobj.cxx6
-rw-r--r--sc/qa/extras/scmodelobj.cxx2
-rw-r--r--sc/qa/extras/scnamedrangeobj.cxx2
-rw-r--r--sc/qa/extras/scnamedrangesobj.cxx2
-rw-r--r--sc/qa/extras/scoutlineobj.cxx2
-rw-r--r--sc/qa/extras/scsheetlinkobj.cxx4
-rw-r--r--sc/qa/extras/scsheetlinksobj.cxx4
-rw-r--r--sc/qa/extras/scstylefamiliesobj.cxx2
-rw-r--r--sc/qa/extras/sctablesheetobj.cxx2
-rw-r--r--sc/qa/unit/bugfix-test.cxx55
-rw-r--r--sc/qa/unit/chart2dataprovider.cxx2
-rw-r--r--sc/qa/unit/cond_format_merge.cxx2
-rw-r--r--sc/qa/unit/copy_paste_test.cxx29
-rw-r--r--sc/qa/unit/dataproviders_test.cxx8
-rw-r--r--sc/qa/unit/filters-test.cxx66
-rw-r--r--sc/qa/unit/functions_addin.cxx2
-rw-r--r--sc/qa/unit/functions_array.cxx2
-rw-r--r--sc/qa/unit/functions_database.cxx2
-rw-r--r--sc/qa/unit/functions_datetime.cxx2
-rw-r--r--sc/qa/unit/functions_financial.cxx2
-rw-r--r--sc/qa/unit/functions_information.cxx2
-rw-r--r--sc/qa/unit/functions_logical.cxx2
-rw-r--r--sc/qa/unit/functions_mathematical.cxx2
-rw-r--r--sc/qa/unit/functions_spreadsheet.cxx2
-rw-r--r--sc/qa/unit/functions_statistical.cxx2
-rw-r--r--sc/qa/unit/functions_test_old.cxx2
-rw-r--r--sc/qa/unit/functions_text.cxx2
-rw-r--r--sc/qa/unit/helper/qahelper.cxx4
-rw-r--r--sc/qa/unit/helper/qahelper.hxx6
-rw-r--r--sc/qa/unit/jumbosheets-test.cxx2
-rw-r--r--sc/qa/unit/opencl-test.cxx453
-rw-r--r--sc/qa/unit/pivottable_filters_test.cxx96
-rw-r--r--sc/qa/unit/screenshots/screenshots.cxx2
-rw-r--r--sc/qa/unit/scshapetest.cxx52
-rw-r--r--sc/qa/unit/subsequent_export-test.cxx315
-rw-r--r--sc/qa/unit/subsequent_filters-test.cxx331
-rw-r--r--sc/source/core/data/dpdimsave.cxx2
-rw-r--r--sc/source/core/data/dpoutput.cxx4
-rw-r--r--sc/source/core/data/global2.cxx6
-rw-r--r--sc/source/core/tool/addincol.cxx4
-rw-r--r--sc/source/core/tool/calcconfig.cxx4
-rw-r--r--sc/source/core/tool/chartlis.cxx2
-rw-r--r--sc/source/core/tool/unitconv.cxx6
-rw-r--r--sc/source/filter/excel/excimp8.cxx2
-rw-r--r--sc/source/filter/excel/xecontent.cxx8
-rw-r--r--sc/source/filter/excel/xehelper.cxx2
-rw-r--r--sc/source/filter/excel/xelink.cxx4
-rw-r--r--sc/source/filter/ftools/ftools.cxx2
-rw-r--r--sc/source/filter/inc/ftools.hxx4
-rw-r--r--sc/source/filter/inc/xehelper.hxx4
-rw-r--r--sc/source/filter/oox/excelfilter.cxx2
-rw-r--r--sc/source/filter/oox/excelvbaproject.cxx2
-rw-r--r--sc/source/filter/oox/workbookfragment.cxx8
-rw-r--r--sc/source/filter/oox/worksheetfragment.cxx8
-rw-r--r--sc/source/filter/xml/XMLTableShapeResizer.cxx2
-rw-r--r--sc/source/ui/app/inputwin.cxx5
-rw-r--r--sc/source/ui/dbgui/PivotLayoutTreeListData.cxx4
-rw-r--r--sc/source/ui/docshell/docsh4.cxx2
-rw-r--r--sc/source/ui/inc/hfedtdlg.hxx26
-rw-r--r--sc/source/ui/inc/optsolver.hxx3
-rw-r--r--sc/source/ui/miscdlgs/optsolver.cxx2
-rw-r--r--sc/source/ui/navipi/content.cxx4
-rw-r--r--sc/source/ui/pagedlg/hfedtdlg.cxx22
-rw-r--r--sc/source/ui/unoobj/cellsuno.cxx2
-rw-r--r--sc/source/ui/unoobj/linkuno.cxx5
-rw-r--r--sc/source/ui/vba/vbachartobjects.cxx4
-rw-r--r--sc/source/ui/vba/vbaformatconditions.cxx2
-rw-r--r--sc/source/ui/vba/vbaworksheet.cxx10
-rw-r--r--sc/source/ui/view/colrowba.cxx8
-rw-r--r--sc/source/ui/view/dbfunc3.cxx3
-rw-r--r--sccomp/qa/unit/SwarmSolverTest.cxx10
-rw-r--r--sd/inc/drawdoc.hxx6
-rw-r--r--sd/inc/sdpage.hxx3
-rw-r--r--sd/inc/stlpool.hxx17
-rw-r--r--sd/qa/unit/HtmlExportTest.cxx2
-rw-r--r--sd/qa/unit/SVGExportTests.cxx8
-rw-r--r--sd/qa/unit/SdrPdfImportTest.cxx4
-rw-r--r--sd/qa/unit/activex-controls-tests.cxx26
-rw-r--r--sd/qa/unit/dialogs-test.cxx2
-rw-r--r--sd/qa/unit/export-tests-ooxml1.cxx92
-rw-r--r--sd/qa/unit/export-tests-ooxml2.cxx233
-rw-r--r--sd/qa/unit/export-tests.cxx71
-rw-r--r--sd/qa/unit/filters-test.cxx10
-rw-r--r--sd/qa/unit/import-tests-smartart.cxx88
-rw-r--r--sd/qa/unit/import-tests.cxx201
-rw-r--r--sd/qa/unit/layout-tests.cxx6
-rw-r--r--sd/qa/unit/misc-tests.cxx32
-rw-r--r--sd/qa/unit/sdmodeltestbase.hxx2
-rw-r--r--sd/qa/unit/uiimpress.cxx14
-rw-r--r--sd/source/core/drawdoc2.cxx4
-rw-r--r--sd/source/core/drawdoc3.cxx7
-rw-r--r--sd/source/core/sdpage2.cxx4
-rw-r--r--sd/source/core/stlpool.cxx32
-rw-r--r--sd/source/filter/eppt/pptx-epptooxml.cxx2
-rw-r--r--sd/source/filter/html/htmlex.cxx8
-rw-r--r--sd/source/filter/html/htmlex.hxx8
-rw-r--r--sd/source/filter/html/pubdlg.cxx2
-rw-r--r--sd/source/ui/docshell/docshell.cxx4
-rw-r--r--sd/source/ui/sidebar/DocumentHelper.cxx2
-rw-r--r--sd/source/ui/sidebar/DocumentHelper.hxx3
-rw-r--r--sd/source/ui/unoidl/sddetect.cxx2
-rw-r--r--sd/source/ui/view/ToolBarManager.cxx6
-rw-r--r--sdext/source/pdfimport/test/tests.cxx12
-rw-r--r--sdext/source/presenter/PresenterScreen.cxx4
-rw-r--r--sdext/source/presenter/PresenterScreen.hxx3
-rw-r--r--sfx2/inc/guisaveas.hxx6
-rw-r--r--sfx2/qa/cppunit/test_misc.cxx8
-rw-r--r--sfx2/qa/unit/sfx2-dialogs-test.cxx2
-rw-r--r--sfx2/source/appl/linkmgr2.cxx4
-rw-r--r--sfx2/source/doc/graphhelp.cxx6
-rw-r--r--sfx2/source/doc/graphhelp.hxx6
-rw-r--r--sfx2/source/doc/guisaveas.cxx25
-rw-r--r--sfx2/source/doc/objmisc.cxx4
-rw-r--r--sfx2/source/notebookbar/SfxNotebookBar.cxx6
-rw-r--r--sfx2/source/view/ipclient.cxx2
-rw-r--r--sfx2/source/view/lokhelper.cxx10
-rw-r--r--sfx2/source/view/viewfrm.cxx4
-rw-r--r--smoketest/smoketest.cxx2
-rw-r--r--sot/qa/cppunit/test_sot.cxx5
-rw-r--r--starmath/qa/extras/mmlimport-test.cxx16
-rw-r--r--starmath/qa/unit/starmath-dialogs-test.cxx2
-rw-r--r--starmath/source/cfgitem.cxx8
-rw-r--r--starmath/source/cfgitem.hxx7
-rw-r--r--stoc/source/implementationregistration/implreg.cxx5
-rw-r--r--stoc/source/security/file_policy.cxx25
-rw-r--r--stoc/source/servicemanager/servicemanager.cxx11
-rw-r--r--svgio/qa/cppunit/SvgImportTest.cxx73
-rw-r--r--svl/qa/unit/lockfiles/test_lockfiles.cxx70
-rw-r--r--svl/source/misc/documentlockfile.cxx2
-rw-r--r--svl/source/misc/lockfilecommon.cxx3
-rw-r--r--svl/source/misc/sharecontrolfile.cxx2
-rw-r--r--svtools/qa/unit/svtools-dialogs-test.cxx2
-rw-r--r--svtools/qa/unit/testHtmlReader.cxx2
-rw-r--r--svtools/source/config/extcolorcfg.cxx9
-rw-r--r--svtools/source/dialogs/prnsetup.cxx6
-rw-r--r--svtools/source/misc/langtab.cxx8
-rw-r--r--svtools/source/svhtml/HtmlWriter.cxx6
-rw-r--r--svtools/source/svhtml/parhtml.cxx4
-rw-r--r--svx/qa/unit/customshapes.cxx19
-rw-r--r--svx/qa/unit/gallery/test_gallery.cxx6
-rw-r--r--svx/qa/unit/sdr.cxx2
-rw-r--r--svx/qa/unit/svx-dialogs-test.cxx2
-rw-r--r--svx/qa/unit/xoutdev.cxx2
-rw-r--r--svx/source/form/fmview.cxx2
-rw-r--r--svx/source/form/fmvwimp.cxx4
-rw-r--r--svx/source/inc/fmvwimp.hxx5
-rw-r--r--svx/source/smarttags/SmartTagMgr.cxx7
-rw-r--r--svx/source/svdraw/svdomedia.cxx2
-rw-r--r--svx/source/xml/xmlgrhlp.cxx7
-rw-r--r--sw/inc/docstyle.hxx7
-rw-r--r--sw/inc/unocrsrhelper.hxx7
-rw-r--r--sw/qa/core/accessibilitycheck/AccessibilityCheckTest.cxx2
-rw-r--r--sw/qa/core/filters-test.cxx24
-rw-r--r--sw/qa/core/filters-test2.cxx2
-rw-r--r--sw/qa/core/macros-test.cxx13
-rw-r--r--sw/qa/extras/globalfilter/globalfilter.cxx36
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport10.cxx7
-rw-r--r--sw/qa/extras/rtfexport/rtfexport2.cxx12
-rw-r--r--sw/qa/extras/rtfexport/rtfexport5.cxx6
-rw-r--r--sw/qa/extras/rtfimport/rtfimport.cxx8
-rw-r--r--sw/qa/extras/uiwriter/uiwriter.cxx21
-rw-r--r--sw/qa/extras/uiwriter/uiwriter2.cxx2
-rw-r--r--sw/qa/inc/swmodeltestbase.hxx9
-rw-r--r--sw/qa/unit/sw-dialogs-test.cxx2
-rw-r--r--sw/qa/unit/sw-dialogs-test_2.cxx2
-rw-r--r--sw/qa/unit/swmodeltestbase.cxx8
-rw-r--r--sw/source/core/bastyp/SwSmartTagMgr.cxx2
-rw-r--r--sw/source/core/crsr/annotationmark.cxx2
-rw-r--r--sw/source/core/crsr/bookmrk.cxx10
-rw-r--r--sw/source/core/crsr/crossrefbookmark.cxx4
-rw-r--r--sw/source/core/doc/docnew.cxx3
-rw-r--r--sw/source/core/edit/edfcol.cxx2
-rw-r--r--sw/source/core/graphic/ndgrf.cxx6
-rw-r--r--sw/source/core/inc/bookmrk.hxx4
-rw-r--r--sw/source/core/inc/crossrefbookmark.hxx6
-rw-r--r--sw/source/core/text/porfld.cxx2
-rw-r--r--sw/source/core/text/porfld.hxx6
-rw-r--r--sw/source/core/text/porhyph.hxx10
-rw-r--r--sw/source/core/text/txthyph.cxx2
-rw-r--r--sw/source/core/undo/unbkmk.cxx6
-rw-r--r--sw/source/core/unocore/unochart.cxx17
-rw-r--r--sw/source/core/unocore/unoobj.cxx15
-rw-r--r--sw/source/filter/html/htmlcss1.cxx6
-rw-r--r--sw/source/filter/html/htmlform.cxx6
-rw-r--r--sw/source/filter/html/swcss1.hxx6
-rw-r--r--sw/source/filter/html/wrthtml.cxx4
-rw-r--r--sw/source/filter/html/wrthtml.hxx2
-rw-r--r--sw/source/filter/ww8/docxattributeoutput.cxx4
-rw-r--r--sw/source/filter/ww8/docxattributeoutput.hxx4
-rw-r--r--sw/source/filter/ww8/wrtww8.hxx4
-rw-r--r--sw/source/filter/ww8/ww8atr.cxx6
-rw-r--r--sw/source/filter/ww8/ww8graf.cxx4
-rw-r--r--sw/source/filter/ww8/ww8par.cxx2
-rw-r--r--sw/source/filter/ww8/ww8par.hxx2
-rw-r--r--sw/source/filter/xml/xmlexp.hxx4
-rw-r--r--sw/source/filter/xml/xmltble.cxx27
-rw-r--r--sw/source/ui/dbui/dbinsdlg.cxx42
-rw-r--r--sw/source/ui/dialog/uiregionsw.cxx15
-rw-r--r--sw/source/ui/dochdl/selglos.cxx2
-rw-r--r--sw/source/uibase/app/docsh.cxx2
-rw-r--r--sw/source/uibase/app/docstyle.cxx6
-rw-r--r--sw/source/uibase/inc/inputwin.hxx6
-rw-r--r--sw/source/uibase/inc/selglos.hxx10
-rw-r--r--sw/source/uibase/misc/glosdoc.cxx5
-rw-r--r--sw/source/uibase/ribbar/inputwin.cxx4
-rw-r--r--test/source/bootstrapfixture.cxx8
-rw-r--r--test/source/helper/form.cxx11
-rw-r--r--test/source/helper/shape.cxx16
-rw-r--r--test/source/screenshot_test.cxx2
-rw-r--r--test/source/unoapi_test.cxx2
-rw-r--r--test/source/view/xcontrolaccess.cxx2
-rw-r--r--test/source/xmltesttools.cxx2
-rw-r--r--tools/qa/cppunit/test_config.cxx2
-rw-r--r--tools/qa/cppunit/test_xmlwalker.cxx2
-rw-r--r--ucb/source/core/ucb.cxx13
-rw-r--r--ucb/source/ucp/file/filglob.cxx4
-rw-r--r--ucb/source/ucp/file/filglob.hxx2
-rw-r--r--ucb/source/ucp/package/pkgcontent.cxx4
-rw-r--r--ucb/source/ucp/package/pkgcontent.hxx5
-rw-r--r--unodevtools/source/skeletonmaker/cppcompskeleton.cxx15
-rw-r--r--unodevtools/source/skeletonmaker/cpptypemaker.cxx7
-rw-r--r--unodevtools/source/skeletonmaker/javatypemaker.cxx6
-rw-r--r--unodevtools/source/skeletonmaker/skeletoncommon.cxx13
-rw-r--r--unodevtools/source/skeletonmaker/skeletoncpp.hxx3
-rw-r--r--unodevtools/source/skeletonmaker/skeletonjava.hxx3
-rw-r--r--unoidl/source/unoidl-check.cxx13
-rw-r--r--unoidl/source/unoidl-read.cxx7
-rw-r--r--unotest/source/cpp/directories.cxx8
-rw-r--r--unotest/source/cpp/filters-test.cxx8
-rw-r--r--unotest/source/cpp/getargument.cxx4
-rw-r--r--unotest/source/cpp/getargument.hxx4
-rw-r--r--unotest/source/cpp/gettestargument.cxx4
-rw-r--r--unotest/source/cpp/macros_test.cxx5
-rw-r--r--unotest/source/cpp/officeconnection.cxx6
-rw-r--r--unotools/source/config/bootstrap.cxx12
-rw-r--r--unotools/source/config/dynamicmenuoptions.cxx10
-rw-r--r--unotools/source/config/moduleoptions.cxx12
-rw-r--r--unotools/source/config/optionsdlg.cxx42
-rw-r--r--uui/qa/unit/uui-dialogs-test.cxx2
-rw-r--r--vbahelper/source/vbahelper/vbahelper.cxx4
-rw-r--r--vbahelper/source/vbahelper/vbashapes.cxx10
-rw-r--r--vcl/inc/unx/printerjob.hxx5
-rw-r--r--vcl/qa/api/XGraphicTest.cxx8
-rw-r--r--vcl/qa/cppunit/BitmapFilterTest.cxx19
-rw-r--r--vcl/qa/cppunit/GraphicFormatDetectorTest.cxx40
-rw-r--r--vcl/qa/cppunit/GraphicNativeMetadataTest.cxx18
-rw-r--r--vcl/qa/cppunit/GraphicTest.cxx2
-rw-r--r--vcl/qa/cppunit/PDFiumLibraryTest.cxx18
-rw-r--r--vcl/qa/cppunit/VectorGraphicSearchTest.cxx16
-rw-r--r--vcl/qa/cppunit/bitmaprender/BitmapRenderTest.cxx14
-rw-r--r--vcl/qa/cppunit/blocklistparsertest.cxx6
-rw-r--r--vcl/qa/cppunit/graphicfilter/filters-test.cxx18
-rw-r--r--vcl/qa/cppunit/jpeg/JpegReaderTest.cxx14
-rw-r--r--vcl/qa/cppunit/jpeg/JpegWriterTest.cxx10
-rw-r--r--vcl/qa/cppunit/pdfexport/pdfexport.cxx39
-rw-r--r--vcl/qa/cppunit/png/PngFilterTest.cxx6
-rw-r--r--vcl/qa/cppunit/svm/svmtest.cxx91
-rw-r--r--vcl/qa/cppunit/widgetdraw/WidgetDefinitionReaderTest.cxx17
-rw-r--r--vcl/qa/unit/vcl-dialogs-test.cxx2
-rw-r--r--vcl/source/app/brand.cxx12
-rw-r--r--vcl/source/control/fmtfield.cxx6
-rw-r--r--vcl/source/control/notebookbar.cxx8
-rw-r--r--vcl/source/filter/FilterConfigItem.cxx8
-rw-r--r--vcl/source/filter/graphicfilter.cxx2
-rw-r--r--vcl/source/gdi/FileDefinitionWidgetDraw.cxx10
-rw-r--r--vcl/source/gdi/embeddedfontshelper.cxx4
-rw-r--r--vcl/source/image/ImplImageTree.cxx13
-rw-r--r--vcl/source/opengl/OpenGLHelper.cxx36
-rw-r--r--vcl/unx/generic/print/glyphset.cxx6
-rw-r--r--vcl/unx/generic/print/glyphset.hxx3
-rw-r--r--vcl/unx/generic/print/printerjob.cxx12
-rw-r--r--vcl/unx/gtk3/gtk3gtkinst.cxx2
-rw-r--r--writerfilter/qa/cppunittests/filters-test/filters-test.cxx2
-rw-r--r--writerfilter/source/filter/WriterFilter.cxx2
-rw-r--r--writerfilter/source/ooxml/OOXMLDocumentImpl.cxx4
-rw-r--r--writerperfect/qa/unit/EPUBExportTest.cxx107
-rw-r--r--writerperfect/qa/unit/ImportTest.cxx17
-rw-r--r--writerperfect/qa/unit/WpftCalcFilterTest.cxx8
-rw-r--r--writerperfect/qa/unit/WpftDrawFilterTest.cxx21
-rw-r--r--writerperfect/qa/unit/WpftFilterTestBase.cxx4
-rw-r--r--writerperfect/qa/unit/WpftFilterTestBase.hxx5
-rw-r--r--writerperfect/qa/unit/WpftImpressFilterTest.cxx4
-rw-r--r--writerperfect/qa/unit/WpftWriterFilterTest.cxx14
-rw-r--r--writerperfect/qa/unit/writerperfect-dialogs-test.cxx2
-rw-r--r--writerperfect/source/common/WPXSvInputStream.cxx12
-rw-r--r--xmlhelp/source/cxxhelp/provider/databases.cxx25
-rw-r--r--xmlhelp/source/cxxhelp/provider/databases.hxx7
-rw-r--r--xmloff/inc/txtflde.hxx2
-rw-r--r--xmloff/qa/unit/style.cxx10
-rw-r--r--xmloff/source/core/xmlimp.cxx6
-rw-r--r--xmloff/source/style/xmlnumfi.cxx3
-rw-r--r--xmloff/source/text/XMLTextFrameContext.cxx3
-rw-r--r--xmloff/source/text/txtflde.cxx4
-rw-r--r--xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx12
-rw-r--r--xmlsecurity/qa/unit/xmlsecurity-dialogs-test.cxx2
-rw-r--r--xmlsecurity/source/helper/documentsignaturehelper.cxx27
-rw-r--r--xmlsecurity/source/helper/xmlsignaturehelper.cxx4
631 files changed, 4168 insertions, 3491 deletions
diff --git a/avmedia/source/framework/mediaitem.cxx b/avmedia/source/framework/mediaitem.cxx
index 3b83f3853ce8..f42065e8e81e 100644
--- a/avmedia/source/framework/mediaitem.cxx
+++ b/avmedia/source/framework/mediaitem.cxx
@@ -478,7 +478,7 @@ bool EmbedMedia(uno::Reference<frame::XModel> const& xModel,
}
bool CreateMediaTempFile(uno::Reference<io::XInputStream> const& xInStream,
- OUString& o_rTempFileURL, const OUString& rDesiredExtension)
+ OUString& o_rTempFileURL, std::u16string_view rDesiredExtension)
{
OUString tempFileURL;
::osl::FileBase::RC const err =
@@ -489,7 +489,7 @@ bool CreateMediaTempFile(uno::Reference<io::XInputStream> const& xInStream,
return false;
}
- if (!rDesiredExtension.isEmpty())
+ if (!rDesiredExtension.empty())
{
OUString newTempFileURL = tempFileURL + rDesiredExtension;
if (osl::File::move(tempFileURL, newTempFileURL) != osl::FileBase::E_None)
diff --git a/basctl/qa/unit/basctl-dialogs-test.cxx b/basctl/qa/unit/basctl-dialogs-test.cxx
index b907681f629d..3b58757f38dc 100644
--- a/basctl/qa/unit/basctl-dialogs-test.cxx
+++ b/basctl/qa/unit/basctl-dialogs-test.cxx
@@ -51,7 +51,7 @@ VclPtr<VclAbstractDialog> BasctlDialogsTest::createDialogByID(sal_uInt32 /*nID*/
void BasctlDialogsTest::openAnyDialog()
{
/// process input file containing the UXMLDescriptions of the dialogs to dump
- processDialogBatchFile("basctl/qa/unit/data/basctl-dialogs-test.txt");
+ processDialogBatchFile(u"basctl/qa/unit/data/basctl-dialogs-test.txt");
}
CPPUNIT_TEST_SUITE_REGISTRATION(BasctlDialogsTest);
diff --git a/basctl/source/basicide/bastype3.cxx b/basctl/source/basicide/bastype3.cxx
index 4318ad803306..5e409a267423 100644
--- a/basctl/source/basicide/bastype3.cxx
+++ b/basctl/source/basicide/bastype3.cxx
@@ -429,9 +429,9 @@ bool SbTreeListBox::FindRootEntry( const ScriptDocument& rDocument, LibraryLocat
return false;
}
-OUString CreateMgrAndLibStr( const OUString& rMgrName, const OUString& rLibName )
+OUString CreateMgrAndLibStr( std::u16string_view rMgrName, std::u16string_view rLibName )
{
- return "[" + rMgrName + "]." + rLibName;
+ return OUString::Concat("[") + rMgrName + "]." + rLibName;
}
diff --git a/basctl/source/basicide/bastypes.cxx b/basctl/source/basicide/bastypes.cxx
index 99a54894a3e8..0a4f2efc62cf 100644
--- a/basctl/source/basicide/bastypes.cxx
+++ b/basctl/source/basicide/bastypes.cxx
@@ -17,6 +17,10 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <sal/config.h>
+
+#include <string_view>
+
#include <strings.hrc>
#include <helpids.h>
#include <iderid.hxx>
@@ -692,36 +696,36 @@ LibInfo::Item::Item (
m_eCurrentType(eCurrentType)
{ }
-static bool QueryDel(const OUString& rName, const OUString &rStr, weld::Widget* pParent)
+static bool QueryDel(std::u16string_view rName, const OUString &rStr, weld::Widget* pParent)
{
- OUString aName = "\'" + rName + "\'";
+ OUString aName = OUString::Concat("\'") + rName + "\'";
OUString aQuery = rStr.replaceAll("XX", aName);
std::unique_ptr<weld::MessageDialog> xQueryBox(Application::CreateMessageDialog(pParent,
VclMessageType::Question, VclButtonsType::YesNo, aQuery));
return (xQueryBox->run() == RET_YES);
}
-bool QueryDelMacro( const OUString& rName, weld::Widget* pParent )
+bool QueryDelMacro( std::u16string_view rName, weld::Widget* pParent )
{
return QueryDel( rName, IDEResId( RID_STR_QUERYDELMACRO ), pParent );
}
-bool QueryReplaceMacro( const OUString& rName, weld::Widget* pParent )
+bool QueryReplaceMacro( std::u16string_view rName, weld::Widget* pParent )
{
return QueryDel( rName, IDEResId( RID_STR_QUERYREPLACEMACRO ), pParent );
}
-bool QueryDelDialog( const OUString& rName, weld::Widget* pParent )
+bool QueryDelDialog( std::u16string_view rName, weld::Widget* pParent )
{
return QueryDel( rName, IDEResId( RID_STR_QUERYDELDIALOG ), pParent );
}
-bool QueryDelLib( const OUString& rName, bool bRef, weld::Widget* pParent )
+bool QueryDelLib( std::u16string_view rName, bool bRef, weld::Widget* pParent )
{
return QueryDel( rName, IDEResId( bRef ? RID_STR_QUERYDELLIBREF : RID_STR_QUERYDELLIB ), pParent );
}
-bool QueryDelModule( const OUString& rName, weld::Widget* pParent )
+bool QueryDelModule( std::u16string_view rName, weld::Widget* pParent )
{
return QueryDel( rName, IDEResId( RID_STR_QUERYDELMODULE ), pParent );
}
diff --git a/basctl/source/basicide/localizationmgr.cxx b/basctl/source/basicide/localizationmgr.cxx
index 1e31f8a47d0f..72408cd61ac0 100644
--- a/basctl/source/basicide/localizationmgr.cxx
+++ b/basctl/source/basicide/localizationmgr.cxx
@@ -17,6 +17,10 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <sal/config.h>
+
+#include <string_view>
+
#include <localizationmgr.hxx>
#include <basidesh.hxx>
@@ -146,7 +150,7 @@ void LocalizationMgr::implEnableDisableResourceForAllLibraryDialogs( HandleResou
Any aDialogCtrl;
aDialogCtrl <<= xDialog;
implHandleControlResourceProperties( aDialogCtrl, aDlgName,
- OUString(), m_xStringResourceManager, xDummyStringResolver, eMode );
+ std::u16string_view(), m_xStringResourceManager, xDummyStringResolver, eMode );
// Handle all controls
Sequence< OUString > aNames = xDialog->getElementNames();
@@ -166,7 +170,7 @@ void LocalizationMgr::implEnableDisableResourceForAllLibraryDialogs( HandleResou
static OUString implCreatePureResourceId
- ( const OUString& aDialogName, const OUString& aCtrlName,
+ ( std::u16string_view aDialogName, std::u16string_view aCtrlName,
const OUString& aPropName,
const Reference< XStringResourceManager >& xStringResourceManager )
{
@@ -175,7 +179,7 @@ static OUString implCreatePureResourceId
+ aDot
+ aDialogName
+ aDot;
- if( !aCtrlName.isEmpty() )
+ if( !aCtrlName.empty() )
{
aPureIdStr += aCtrlName + aDot;
}
@@ -187,7 +191,7 @@ static OUString implCreatePureResourceId
// anyway only one language should exist when calling this method then,
// either the first one for mode SET_IDS or the last one for mode RESET_IDS
sal_Int32 LocalizationMgr::implHandleControlResourceProperties
- (const Any& rControlAny, const OUString& aDialogName, const OUString& aCtrlName,
+ (const Any& rControlAny, std::u16string_view aDialogName, std::u16string_view aCtrlName,
const Reference< XStringResourceManager >& xStringResourceManager,
const Reference< XStringResourceResolver >& xSourceStringResolver, HandleResourceMode eMode )
{
@@ -791,7 +795,7 @@ static DialogWindow* FindDialogWindowForEditor( DlgEditor const * pEditor )
void LocalizationMgr::setControlResourceIDsForNewEditorObject( DlgEditor const * pEditor,
- const Any& rControlAny, const OUString& aCtrlName )
+ const Any& rControlAny, std::u16string_view aCtrlName )
{
// Get library for DlgEditor
DialogWindow* pDlgWin = FindDialogWindowForEditor( pEditor );
@@ -821,7 +825,7 @@ void LocalizationMgr::setControlResourceIDsForNewEditorObject( DlgEditor const *
}
void LocalizationMgr::renameControlResourceIDsForEditorObject( DlgEditor const * pEditor,
- const css::uno::Any& rControlAny, const OUString& aNewCtrlName )
+ const css::uno::Any& rControlAny, std::u16string_view aNewCtrlName )
{
// Get library for DlgEditor
DialogWindow* pDlgWin = FindDialogWindowForEditor( pEditor );
@@ -849,7 +853,7 @@ void LocalizationMgr::renameControlResourceIDsForEditorObject( DlgEditor const *
void LocalizationMgr::deleteControlResourceIDsForDeletedEditorObject( DlgEditor const * pEditor,
- const Any& rControlAny, const OUString& aCtrlName )
+ const Any& rControlAny, std::u16string_view aCtrlName )
{
// Get library for DlgEditor
DialogWindow* pDlgWin = FindDialogWindowForEditor( pEditor );
@@ -875,7 +879,7 @@ void LocalizationMgr::deleteControlResourceIDsForDeletedEditorObject( DlgEditor
}
void LocalizationMgr::setStringResourceAtDialog( const ScriptDocument& rDocument, const OUString& aLibName,
- const OUString& aDlgName, const Reference< container::XNameContainer >& xDialogModel )
+ std::u16string_view aDlgName, const Reference< container::XNameContainer >& xDialogModel )
{
// Get library
Reference< container::XNameContainer > xDialogLib( rDocument.getLibrary( E_DIALOGS, aLibName, true ) );
@@ -894,7 +898,7 @@ void LocalizationMgr::setStringResourceAtDialog( const ScriptDocument& rDocument
aDialogCtrl <<= xDialogModel;
Reference< XStringResourceResolver > xDummyStringResolver;
implHandleControlResourceProperties( aDialogCtrl, aDlgName,
- OUString(), xStringResourceManager,
+ std::u16string_view(), xStringResourceManager,
xDummyStringResolver, SET_IDS );
}
@@ -903,7 +907,7 @@ void LocalizationMgr::setStringResourceAtDialog( const ScriptDocument& rDocument
}
void LocalizationMgr::renameStringResourceIDs( const ScriptDocument& rDocument, const OUString& aLibName,
- const OUString& aDlgName, const Reference< container::XNameContainer >& xDialogModel )
+ std::u16string_view aDlgName, const Reference< container::XNameContainer >& xDialogModel )
{
// Get library
Reference< container::XNameContainer > xDialogLib( rDocument.getLibrary( E_DIALOGS, aLibName, true ) );
@@ -916,7 +920,7 @@ void LocalizationMgr::renameStringResourceIDs( const ScriptDocument& rDocument,
aDialogCtrl <<= xDialogModel;
Reference< XStringResourceResolver > xDummyStringResolver;
implHandleControlResourceProperties( aDialogCtrl, aDlgName,
- OUString(), xStringResourceManager,
+ std::u16string_view(), xStringResourceManager,
xDummyStringResolver, RENAME_DIALOG_IDS );
// Handle all controls
@@ -934,7 +938,7 @@ void LocalizationMgr::renameStringResourceIDs( const ScriptDocument& rDocument,
}
void LocalizationMgr::removeResourceForDialog( const ScriptDocument& rDocument, const OUString& aLibName,
- const OUString& aDlgName, const Reference< container::XNameContainer >& xDialogModel )
+ std::u16string_view aDlgName, const Reference< container::XNameContainer >& xDialogModel )
{
// Get library
Reference< container::XNameContainer > xDialogLib( rDocument.getLibrary( E_DIALOGS, aLibName, true ) );
@@ -947,7 +951,7 @@ void LocalizationMgr::removeResourceForDialog( const ScriptDocument& rDocument,
aDialogCtrl <<= xDialogModel;
Reference< XStringResourceResolver > xDummyStringResolver;
implHandleControlResourceProperties( aDialogCtrl, aDlgName,
- OUString(), xStringResourceManager,
+ std::u16string_view(), xStringResourceManager,
xDummyStringResolver, REMOVE_IDS_FROM_RESOURCE );
// Handle all controls
@@ -1019,7 +1023,7 @@ void LocalizationMgr::setResourceIDsForDialog( const Reference< container::XName
}
void LocalizationMgr::copyResourcesForPastedEditorObject( DlgEditor const * pEditor,
- const Any& rControlAny, const OUString& aCtrlName,
+ const Any& rControlAny, std::u16string_view aCtrlName,
const Reference< XStringResourceResolver >& xSourceStringResolver )
{
// Get library for DlgEditor
@@ -1046,7 +1050,8 @@ void LocalizationMgr::copyResourcesForPastedEditorObject( DlgEditor const * pEdi
}
void LocalizationMgr::copyResourceForDroppedDialog( const Reference< container::XNameContainer >& xDialogModel,
- const OUString& aDialogName, const Reference< XStringResourceManager >& xStringResourceManager,
+ std::u16string_view aDialogName,
+ const Reference< XStringResourceManager >& xStringResourceManager,
const Reference< XStringResourceResolver >& xSourceStringResolver )
{
if( !xStringResourceManager.is() )
@@ -1056,7 +1061,7 @@ void LocalizationMgr::copyResourceForDroppedDialog( const Reference< container::
Any aDialogCtrl;
aDialogCtrl <<= xDialogModel;
implHandleControlResourceProperties( aDialogCtrl, aDialogName,
- OUString(), xStringResourceManager, xSourceStringResolver, MOVE_RESOURCES );
+ std::u16string_view(), xStringResourceManager, xSourceStringResolver, MOVE_RESOURCES );
// Handle all controls
Sequence< OUString > aNames = xDialogModel->getElementNames();
diff --git a/basctl/source/basicide/moduldlg.cxx b/basctl/source/basicide/moduldlg.cxx
index 92c3ee9654ff..9f5daa34d644 100644
--- a/basctl/source/basicide/moduldlg.cxx
+++ b/basctl/source/basicide/moduldlg.cxx
@@ -133,7 +133,7 @@ void Shell::CopyDialogResources(
OUString const& rSourceLibName,
ScriptDocument const& rDestDoc,
OUString const& rDestLibName,
- OUString const& rDlgName
+ std::u16string_view rDlgName
)
{
if ( !io_xISP.is() )
@@ -906,7 +906,7 @@ LibDialog::~LibDialog()
{
}
-void LibDialog::SetStorageName( const OUString& rName )
+void LibDialog::SetStorageName( std::u16string_view rName )
{
OUString aName = IDEResId(RID_STR_FILENAME) + rName;
m_xStorageFrame->set_label(aName);
diff --git a/basctl/source/basicide/moduldlg.hxx b/basctl/source/basicide/moduldlg.hxx
index 37e3d9556185..b7fb13d8901e 100644
--- a/basctl/source/basicide/moduldlg.hxx
+++ b/basctl/source/basicide/moduldlg.hxx
@@ -19,6 +19,10 @@
#pragma once
+#include <sal/config.h>
+
+#include <string_view>
+
#include <bastype2.hxx>
#include <tools/solar.h>
#include <vcl/weld.hxx>
@@ -94,7 +98,7 @@ public:
explicit LibDialog(weld::Window* pParent);
virtual ~LibDialog() override;
- void SetStorageName( const OUString& rName );
+ void SetStorageName( std::u16string_view rName );
weld::TreeView& GetLibBox() { return *m_xLibBox; }
bool IsReference() const { return m_xReferenceBox->get_active(); }
diff --git a/basctl/source/inc/basidesh.hxx b/basctl/source/inc/basidesh.hxx
index d8fe56feb43c..f3127186ce93 100644
--- a/basctl/source/inc/basidesh.hxx
+++ b/basctl/source/inc/basidesh.hxx
@@ -29,6 +29,7 @@
#include <vcl/scrbar.hxx>
#include <map>
#include <memory>
+#include <string_view>
class SfxViewFactory;
class SdrView;
@@ -197,7 +198,7 @@ public:
static void CopyDialogResources(
css::uno::Reference< css::io::XInputStreamProvider >& io_xISP,
const ScriptDocument& rSourceDoc, const OUString& rSourceLibName, const ScriptDocument& rDestDoc,
- const OUString& rDestLibName, const OUString& rDlgName );
+ const OUString& rDestLibName, std::u16string_view rDlgName );
static void InvalidateControlSlots();
diff --git a/basctl/source/inc/bastypes.hxx b/basctl/source/inc/bastypes.hxx
index 21e6c0227a9c..fecebced52ee 100644
--- a/basctl/source/inc/bastypes.hxx
+++ b/basctl/source/inc/bastypes.hxx
@@ -26,6 +26,7 @@
#include <vcl/dockwin.hxx>
#include <vcl/weld.hxx>
+#include <string_view>
#include <unordered_map>
class SbModule;
@@ -288,14 +289,14 @@ private:
};
void CutLines( OUString& rStr, sal_Int32 nStartLine, sal_Int32 nLines );
-OUString CreateMgrAndLibStr( const OUString& rMgrName, const OUString& rLibName );
+OUString CreateMgrAndLibStr( std::u16string_view rMgrName, std::u16string_view rLibName );
sal_uInt32 CalcLineCount( SvStream& rStream );
-bool QueryReplaceMacro( const OUString& rName, weld::Widget* pParent );
-bool QueryDelMacro( const OUString& rName, weld::Widget* pParent );
-bool QueryDelDialog( const OUString& rName, weld::Widget* pParent );
-bool QueryDelModule( const OUString& rName, weld::Widget* pParent );
-bool QueryDelLib( const OUString& rName, bool bRef, weld::Widget* pParent );
+bool QueryReplaceMacro( std::u16string_view rName, weld::Widget* pParent );
+bool QueryDelMacro( std::u16string_view rName, weld::Widget* pParent );
+bool QueryDelDialog( std::u16string_view rName, weld::Widget* pParent );
+bool QueryDelModule( std::u16string_view rName, weld::Widget* pParent );
+bool QueryDelLib( std::u16string_view rName, bool bRef, weld::Widget* pParent );
bool QueryPassword(weld::Widget* pDialogParent, const css::uno::Reference< css::script::XLibraryContainer >& xLibContainer, const OUString& rLibName, OUString& rPassword, bool bRepeat = false, bool bNewTitle = false);
class ModuleInfoHelper
diff --git a/basctl/source/inc/localizationmgr.hxx b/basctl/source/inc/localizationmgr.hxx
index 4b72a7d8e58d..847ef0f75729 100644
--- a/basctl/source/inc/localizationmgr.hxx
+++ b/basctl/source/inc/localizationmgr.hxx
@@ -19,6 +19,10 @@
#pragma once
+#include <sal/config.h>
+
+#include <string_view>
+
#include "scriptdocument.hxx"
#include <com/sun/star/resource/XStringResourceManager.hpp>
@@ -51,8 +55,8 @@ class LocalizationMgr
COPY_RESOURCES
};
static sal_Int32 implHandleControlResourceProperties(const css::uno::Any& rControlAny,
- const OUString& aDialogName,
- const OUString& aCtrlName,
+ std::u16string_view aDialogName,
+ std::u16string_view aCtrlName,
const css::uno::Reference< css::resource::XStringResourceManager >& xStringResourceManager,
const css::uno::Reference< css::resource::XStringResourceResolver >& xSourceStringResolver,
HandleResourceMode eMode );
@@ -95,21 +99,21 @@ public:
void handleBasicStopped();
static void setControlResourceIDsForNewEditorObject(DlgEditor const * pEditor,
- const css::uno::Any& rControlAny, const OUString& aCtrlName);
+ const css::uno::Any& rControlAny, std::u16string_view aCtrlName);
static void renameControlResourceIDsForEditorObject(DlgEditor const * pEditor,
- const css::uno::Any& rControlAny, const OUString& aNewCtrlName);
+ const css::uno::Any& rControlAny, std::u16string_view aNewCtrlName);
static void deleteControlResourceIDsForDeletedEditorObject(DlgEditor const * pEditor,
- const css::uno::Any& rControlAny, const OUString& aCtrlName);
+ const css::uno::Any& rControlAny, std::u16string_view aCtrlName);
- static void setStringResourceAtDialog( const ScriptDocument& rDocument, const OUString& aLibName, const OUString& aDlgName,
+ static void setStringResourceAtDialog( const ScriptDocument& rDocument, const OUString& aLibName, std::u16string_view aDlgName,
const css::uno::Reference< css::container::XNameContainer >& xDialogModel );
- static void renameStringResourceIDs( const ScriptDocument& rDocument, const OUString& aLibName, const OUString& aDlgName,
+ static void renameStringResourceIDs( const ScriptDocument& rDocument, const OUString& aLibName, std::u16string_view aDlgName,
const css::uno::Reference< css::container::XNameContainer >& xDialogModel );
- static void removeResourceForDialog( const ScriptDocument& rDocument, const OUString& aLibName, const OUString& aDlgName,
+ static void removeResourceForDialog( const ScriptDocument& rDocument, const OUString& aLibName, std::u16string_view aDlgName,
const css::uno::Reference< css::container::XNameContainer >& xDialogModel );
static css::uno::Reference< css::resource::XStringResourceManager >
@@ -125,12 +129,12 @@ public:
const css::uno::Reference< css::resource::XStringResourceManager >& xStringResourceManager );
static void copyResourcesForPastedEditorObject( DlgEditor const * pEditor,
- const css::uno::Any& rControlAny, const OUString& aCtrlName,
+ const css::uno::Any& rControlAny, std::u16string_view aCtrlName,
const css::uno::Reference< css::resource::XStringResourceResolver >& xSourceStringResolver );
static void copyResourceForDroppedDialog(
const css::uno::Reference< css::container::XNameContainer >& xDialogModel,
- const OUString& aDialogName,
+ std::u16string_view aDialogName,
const css::uno::Reference< css::resource::XStringResourceManager >& xStringResourceManager,
const css::uno::Reference< css::resource::XStringResourceResolver >& xSourceStringResolver );
diff --git a/basic/qa/cppunit/basic_coverage.cxx b/basic/qa/cppunit/basic_coverage.cxx
index effda584dee7..856736b293be 100644
--- a/basic/qa/cppunit/basic_coverage.cxx
+++ b/basic/qa/cppunit/basic_coverage.cxx
@@ -130,7 +130,7 @@ void Coverage::process_directory(const OUString& sDirName)
void Coverage::Coverage_Iterator()
{
- OUString sDirName = m_directories.getURLFromSrc("/basic/qa/basic_coverage/");
+ OUString sDirName = m_directories.getURLFromSrc(u"/basic/qa/basic_coverage/");
CPPUNIT_ASSERT(!sDirName.isEmpty());
process_directory(sDirName); // any files in the root test dir are run in test harness default locale ( en-US )
diff --git a/basic/qa/cppunit/test_vba.cxx b/basic/qa/cppunit/test_vba.cxx
index 3f0818424a70..a38e4ceaab16 100644
--- a/basic/qa/cppunit/test_vba.cxx
+++ b/basic/qa/cppunit/test_vba.cxx
@@ -145,7 +145,7 @@ void VBATest::testMiscVBAFunctions()
#endif
"win32compatb.vb" // same methods, different signatures.
};
- OUString sMacroPathURL = m_directories.getURLFromSrc("/basic/qa/vba_tests/");
+ OUString sMacroPathURL = m_directories.getURLFromSrc(u"/basic/qa/vba_tests/");
OUString sMacroUtilsURL = sMacroPathURL + "_test_asserts.vb";
// Some test data expects the uk locale
LanguageTag aLocale(LANGUAGE_ENGLISH_UK);
diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx
index 82ffb8c11699..af9ca9e73da1 100644
--- a/basic/source/classes/sbunoobj.cxx
+++ b/basic/source/classes/sbunoobj.cxx
@@ -83,6 +83,7 @@
#include <algorithm>
#include <math.h>
#include <memory>
+#include <string_view>
#include <unordered_map>
#include <com/sun/star/reflection/XTypeDescriptionEnumerationAccess.hpp>
#include <com/sun/star/reflection/XConstantsTypeDescription.hpp>
@@ -4179,7 +4180,7 @@ class ModuleInvocationProxy : public WeakImplHelper< XInvocation, XComponent >
::comphelper::OInterfaceContainerHelper2 m_aListeners;
public:
- ModuleInvocationProxy( OUString const & aPrefix, SbxObjectRef const & xScopeObj );
+ ModuleInvocationProxy( std::u16string_view aPrefix, SbxObjectRef const & xScopeObj );
// XInvocation
virtual Reference< XIntrospectionAccess > SAL_CALL getIntrospection() override;
@@ -4201,9 +4202,9 @@ public:
}
-ModuleInvocationProxy::ModuleInvocationProxy( OUString const & aPrefix, SbxObjectRef const & xScopeObj )
+ModuleInvocationProxy::ModuleInvocationProxy( std::u16string_view aPrefix, SbxObjectRef const & xScopeObj )
: m_aMutex()
- , m_aPrefix( aPrefix + "_" )
+ , m_aPrefix( OUString::Concat(aPrefix) + "_" )
, m_xScopeObj( xScopeObj )
, m_aListeners( m_aMutex )
{
@@ -4381,7 +4382,8 @@ void SAL_CALL ModuleInvocationProxy::removeEventListener( const Reference< XEven
Reference< XInterface > createComListener( const Any& aControlAny, const OUString& aVBAType,
- const OUString& aPrefix, const SbxObjectRef& xScopeObj )
+ std::u16string_view aPrefix,
+ const SbxObjectRef& xScopeObj )
{
Reference< XInterface > xRet;
diff --git a/basic/source/inc/sbunoobj.hxx b/basic/source/inc/sbunoobj.hxx
index 6476c3f65c01..47081b7633f3 100644
--- a/basic/source/inc/sbunoobj.hxx
+++ b/basic/source/inc/sbunoobj.hxx
@@ -379,7 +379,7 @@ SbxVariable* getDefaultProp( SbxVariable* pRef );
css::uno::Reference< css::uno::XInterface > createComListener( const css::uno::Any& aControlAny,
const OUString& aVBAType,
- const OUString& aPrefix,
+ std::u16string_view aPrefix,
const SbxObjectRef& xScopeObj );
bool checkUnoObjectType(SbUnoObject& refVal, const OUString& aClass);
diff --git a/basic/source/uno/namecont.cxx b/basic/source/uno/namecont.cxx
index ec112b466f3f..dc83ae5a3546 100644
--- a/basic/source/uno/namecont.cxx
+++ b/basic/source/uno/namecont.cxx
@@ -66,6 +66,7 @@
#include <cppuhelper/supportsservice.hxx>
#include <cppuhelper/typeprovider.hxx>
#include <memory>
+#include <string_view>
namespace basic
{
@@ -571,8 +572,8 @@ static void checkAndCopyFileImpl( const INetURLObject& rSourceFolderInetObj,
}
}
-static void createVariableURL( OUString& rStr, const OUString& rLibName,
- const OUString& rInfoFileName, bool bUser )
+static void createVariableURL( OUString& rStr, std::u16string_view rLibName,
+ std::u16string_view rInfoFileName, bool bUser )
{
if( bUser )
{
@@ -582,7 +583,7 @@ static void createVariableURL( OUString& rStr, const OUString& rLibName,
{
rStr = "$(INST)/" LIBO_SHARE_FOLDER "/basic/";
}
- rStr += rLibName + "/" + rInfoFileName + ".xlb/";
+ rStr += OUString::Concat(rLibName) + "/" + rInfoFileName + ".xlb/";
}
void SfxLibraryContainer::init( const OUString& rInitialDocumentURL, const uno::Reference< embed::XStorage >& rxInitialStorage )
diff --git a/canvas/source/tools/propertysethelper.cxx b/canvas/source/tools/propertysethelper.cxx
index e7880fe4bd83..92f2e3bd28e4 100644
--- a/canvas/source/tools/propertysethelper.cxx
+++ b/canvas/source/tools/propertysethelper.cxx
@@ -19,6 +19,8 @@
#include <sal/config.h>
+#include <string_view>
+
#include <propertysethelper.hxx>
#include <com/sun/star/beans/PropertyVetoException.hpp>
#include <com/sun/star/beans/UnknownPropertyException.hpp>
@@ -29,18 +31,18 @@ namespace canvas
{
namespace
{
- void throwUnknown( const OUString& aPropertyName )
+ void throwUnknown( std::u16string_view aPropertyName )
{
throw beans::UnknownPropertyException(
- "PropertySetHelper: property " +
+ OUString::Concat("PropertySetHelper: property ") +
aPropertyName + " not found."
);
}
- void throwVeto( const OUString& aPropertyName )
+ void throwVeto( std::u16string_view aPropertyName )
{
throw beans::PropertyVetoException(
- "PropertySetHelper: property " +
+ OUString::Concat("PropertySetHelper: property ") +
aPropertyName + " access was vetoed." );
}
diff --git a/chart2/qa/extras/PivotChartTest.cxx b/chart2/qa/extras/PivotChartTest.cxx
index 44998835dbcc..cda42a2bd632 100644
--- a/chart2/qa/extras/PivotChartTest.cxx
+++ b/chart2/qa/extras/PivotChartTest.cxx
@@ -316,7 +316,7 @@ void PivotChartTest::testRoundtrip()
std::vector<double> aReference2 { 101879.458079, 178636.929704, 314626.484864 };
- load("/chart2/qa/extras/data/ods/", "PivotChartRoundTrip.ods");
+ load(u"/chart2/qa/extras/data/ods/", "PivotChartRoundTrip.ods");
xChartDoc = getPivotChartDocFromSheet(1, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -371,7 +371,7 @@ void PivotChartTest::testChangePivotTable()
uno::Sequence<uno::Any> xSequence;
Reference<chart2::XChartDocument> xChartDoc;
- load("/chart2/qa/extras/data/ods/", "PivotTableExample.ods");
+ load(u"/chart2/qa/extras/data/ods/", "PivotTableExample.ods");
// Check we have the Pivot Table
OUString sPivotTableName("DataPilot1");
diff --git a/chart2/qa/extras/chart2_trendcalculators.cxx b/chart2/qa/extras/chart2_trendcalculators.cxx
index 42dce791d83b..b8eb367524bb 100644
--- a/chart2/qa/extras/chart2_trendcalculators.cxx
+++ b/chart2/qa/extras/chart2_trendcalculators.cxx
@@ -64,7 +64,7 @@ private:
void Chart2TrendCalculators::setUp()
{
ChartTest::setUp();
- load("/chart2/qa/extras/data/ods/", "trend_calculators.ods");
+ load(u"/chart2/qa/extras/data/ods/", "trend_calculators.ods");
}
void Chart2TrendCalculators::tearDown()
diff --git a/chart2/qa/extras/chart2dump/chart2dump.cxx b/chart2/qa/extras/chart2dump/chart2dump.cxx
index 77739fb67034..838234f7c78c 100644
--- a/chart2/qa/extras/chart2dump/chart2dump.cxx
+++ b/chart2/qa/extras/chart2dump/chart2dump.cxx
@@ -22,6 +22,7 @@
#include <rtl/ustrbuf.hxx>
#include <fstream>
+#include <string_view>
#if defined(X86)
#define INT_EPS 2.1
@@ -50,7 +51,7 @@
else \
{ \
OString sTestFileName = OUStringToOString(getTestFileName(), RTL_TEXTENCODING_UTF8); \
- CPPUNIT_ASSERT_EQUAL_MESSAGE(OString("Failing test file is: " + sTestFileName).getStr(), readExpected(#aActual), OUString(OUString::number(aActual))); \
+ CPPUNIT_ASSERT_EQUAL_MESSAGE(OString("Failing test file is: " + sTestFileName).getStr(), readExpected(u ## #aActual), OUString(OUString::number(aActual))); \
}
#define CPPUNIT_DUMP_ASSERT_DOUBLES_EQUAL(aActual, EPS_) \
@@ -59,7 +60,7 @@
else \
{ \
OString sTestFileName = OUStringToOString(getTestFileName(), RTL_TEXTENCODING_UTF8); \
- CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE(OString("Failing test file is: " + sTestFileName).getStr(), readExpectedDouble(#aActual), aActual, EPS_); \
+ CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE(OString("Failing test file is: " + sTestFileName).getStr(), readExpectedDouble(u ## #aActual), aActual, EPS_); \
}
#define CPPUNIT_DUMP_ASSERT_STRINGS_EQUAL(aActual) \
@@ -68,7 +69,7 @@
else \
{ \
OString sTestFileName = OUStringToOString(getTestFileName(), RTL_TEXTENCODING_UTF8); \
- CPPUNIT_ASSERT_EQUAL_MESSAGE(OString("Failing test file is: " + sTestFileName).getStr(), readExpected(#aActual), aActual.trim()); \
+ CPPUNIT_ASSERT_EQUAL_MESSAGE(OString("Failing test file is: " + sTestFileName).getStr(), readExpected(u ## #aActual), aActual.trim()); \
}
#define CPPUNIT_DUMP_ASSERT_TRANSFORMATIONS_EQUAL(aActual, EPS_) \
@@ -77,7 +78,7 @@
else \
{ \
OUString expectedTransform; \
- if (!readAndCheckTransformation (aActual, #aActual, EPS_, expectedTransform)) \
+ if (!readAndCheckTransformation (aActual, u ## #aActual, EPS_, expectedTransform)) \
{ \
OString sTestFileName = OUStringToOString(getTestFileName(), RTL_TEXTENCODING_UTF8); \
CPPUNIT_ASSERT_EQUAL_MESSAGE(OString("Failing test file is: " + sTestFileName).getStr(), expectedTransform, transformationToOneLineString(aActual)); \
@@ -143,7 +144,7 @@ protected:
CPPUNIT_FAIL("verify method must be overridden");
}
- OUString readExpected(const OUString& sCheck)
+ OUString readExpected(std::u16string_view sCheck)
{
assert(!m_bDumpMode);
assert(m_aReferenceFile.is_open());
@@ -152,7 +153,7 @@ protected:
OString sAssertMessage =
"The reference file does not contain the right content. Maybe it needs an update:"
+ OUStringToOString(m_sTestFileName, RTL_TEXTENCODING_UTF8);
- CPPUNIT_ASSERT_EQUAL_MESSAGE(sAssertMessage.getStr(), OUString("// " + sCheck), OUString(sTemp.data(), sTemp.length(), RTL_TEXTENCODING_UTF8));
+ CPPUNIT_ASSERT_EQUAL_MESSAGE(sAssertMessage.getStr(), OUString(OUString::Concat("// ") + sCheck), OUString(sTemp.data(), sTemp.length(), RTL_TEXTENCODING_UTF8));
getline(m_aReferenceFile, sTemp);
return OUString(sTemp.data(), sTemp.length(), RTL_TEXTENCODING_UTF8);
}
@@ -165,7 +166,7 @@ protected:
m_aDumpFile << sActualValue.trim() << "\n"; // Write out the checked value, will be used as reference later
}
- void readNote(const OUString& sNote)
+ void readNote(std::u16string_view sNote)
{
assert(!m_bDumpMode);
assert(m_aReferenceFile.is_open());
@@ -174,7 +175,7 @@ protected:
OString sAssertMessage =
"The reference file does not contain the right content. Maybe it needs an update:"
+ OUStringToOString(m_sTestFileName, RTL_TEXTENCODING_UTF8);
- CPPUNIT_ASSERT_EQUAL_MESSAGE(sAssertMessage.getStr(), OUString("/// " + sNote), OUString(sTemp.data(), sTemp.length(), RTL_TEXTENCODING_UTF8));
+ CPPUNIT_ASSERT_EQUAL_MESSAGE(sAssertMessage.getStr(), OUString(OUString::Concat("/// ") + sNote), OUString(sTemp.data(), sTemp.length(), RTL_TEXTENCODING_UTF8));
}
void writeNote(const OUString& sNote)
@@ -184,7 +185,7 @@ protected:
m_aDumpFile << "/// " << sNote << "\n";
}
- double readExpectedDouble(const OUString& sCheck)
+ double readExpectedDouble(std::u16string_view sCheck)
{
OUString sExpected = readExpected(sCheck);
return sExpected.toDouble();
@@ -195,7 +196,7 @@ protected:
writeActual(transformationToOneLineString(rTransform), sCheck);
}
- bool readAndCheckTransformation(const drawing::HomogenMatrix3& rTransform, const OUString& sCheck, const double fEPS, OUString& rExpectedTransform)
+ bool readAndCheckTransformation(const drawing::HomogenMatrix3& rTransform, std::u16string_view sCheck, const double fEPS, OUString& rExpectedTransform)
{
rExpectedTransform = readExpected(sCheck); // Reference transformation string
diff --git a/chart2/qa/extras/chart2export.cxx b/chart2/qa/extras/chart2export.cxx
index d0cd3be67d66..a702d5113b13 100644
--- a/chart2/qa/extras/chart2export.cxx
+++ b/chart2/qa/extras/chart2export.cxx
@@ -580,7 +580,7 @@ void checkTrendlinesInChart(uno::Reference< chart2::XChartDocument > const & xCh
// improve the test
void Chart2ExportTest::testErrorBarXLSX()
{
- load("/chart2/qa/extras/data/ods/", "error_bar.ods");
+ load(u"/chart2/qa/extras/data/ods/", "error_bar.ods");
{
// make sure the ODS import was successful
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
@@ -616,7 +616,7 @@ void Chart2ExportTest::testErrorBarXLSX()
void Chart2ExportTest::testErrorBarPropXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "testErrorBarProp.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testErrorBarProp.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -636,7 +636,7 @@ void Chart2ExportTest::testErrorBarPropXLSX()
void Chart2ExportTest::testTrendline()
{
mbSkipValidation = true;
- load("/chart2/qa/extras/data/ods/", "trendline.ods");
+ load(u"/chart2/qa/extras/data/ods/", "trendline.ods");
checkTrendlinesInChart(getChartDocFromSheet( 0, mxComponent));
reload("calc8");
checkTrendlinesInChart(getChartDocFromSheet( 0, mxComponent));
@@ -644,7 +644,7 @@ void Chart2ExportTest::testTrendline()
void Chart2ExportTest::testTrendlineOOXML()
{
- load("/chart2/qa/extras/data/ods/", "trendline.ods");
+ load(u"/chart2/qa/extras/data/ods/", "trendline.ods");
checkTrendlinesInChart(getChartDocFromSheet( 0, mxComponent));
reload("Calc Office Open XML");
checkTrendlinesInChart(getChartDocFromSheet( 0, mxComponent));
@@ -653,7 +653,7 @@ void Chart2ExportTest::testTrendlineOOXML()
void Chart2ExportTest::testTrendlineXLS()
{
mbSkipValidation = true;
- load("/chart2/qa/extras/data/ods/", "trendline.ods");
+ load(u"/chart2/qa/extras/data/ods/", "trendline.ods");
checkTrendlinesInChart(getChartDocFromSheet( 0, mxComponent));
reload("MS Excel 97");
checkTrendlinesInChart(getChartDocFromSheet( 0, mxComponent));
@@ -668,7 +668,7 @@ void Chart2ExportTest::testStockChart()
* an attribute val of index should start from 1 and not from 0.
* Which was problem area.
*/
- load("/chart2/qa/extras/data/docx/", "testStockChart.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testStockChart.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -683,7 +683,7 @@ void Chart2ExportTest::testStockChart()
void Chart2ExportTest::testBarChart()
{
- load("/chart2/qa/extras/data/docx/", "testBarChart.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testBarChart.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -692,7 +692,7 @@ void Chart2ExportTest::testBarChart()
void Chart2ExportTest::testCrosses()
{
- load("/chart2/qa/extras/data/docx/", "Bar_horizontal_cone.docx");
+ load(u"/chart2/qa/extras/data/docx/", "Bar_horizontal_cone.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:catAx/c:crosses", "val", "autoZero");
@@ -700,7 +700,7 @@ void Chart2ExportTest::testCrosses()
void Chart2ExportTest::testScatterChartTextXValues()
{
- load("/chart2/qa/extras/data/docx/", "scatter-chart-text-x-values.docx");
+ load(u"/chart2/qa/extras/data/docx/", "scatter-chart-text-x-values.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -748,7 +748,7 @@ void Chart2ExportTest::testScatterChartTextXValues()
void Chart2ExportTest::testScatterXAxisValues()
{
- load("/chart2/qa/extras/data/odt/", "tdf114657.odt");
+ load(u"/chart2/qa/extras/data/odt/", "tdf114657.odt");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -762,7 +762,7 @@ void Chart2ExportTest::testScatterXAxisValues()
void Chart2ExportTest::testScatterXAxisCategories()
{
- load("/chart2/qa/extras/data/odt/", "tdf131143.odt");
+ load(u"/chart2/qa/extras/data/odt/", "tdf131143.odt");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -773,7 +773,7 @@ void Chart2ExportTest::testScatterXAxisCategories()
void Chart2ExportTest::testChartDataTable()
{
- load("/chart2/qa/extras/data/docx/", "testChartDataTable.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testChartDataTable.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -784,7 +784,7 @@ void Chart2ExportTest::testChartDataTable()
void Chart2ExportTest::testChartExternalData()
{
- load("/chart2/qa/extras/data/docx/", "testMultipleChart.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testMultipleChart.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -799,7 +799,7 @@ void Chart2ExportTest::testEmbeddingsGrabBag()
// after saving file.
// This test case tests whether embeddings files grabbagged properly in correct object.
- load("/chart2/qa/extras/data/docx/", "testMultiplechartembeddings.docx" );
+ load(u"/chart2/qa/extras/data/docx/", "testMultiplechartembeddings.docx" );
uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
uno::Reference<beans::XPropertySet> xTextDocumentPropertySet(xTextDocument, uno::UNO_QUERY);
uno::Sequence<beans::PropertyValue> aGrabBag(0);
@@ -834,7 +834,7 @@ void Chart2ExportTest::testEmbeddingsGrabBag()
void Chart2ExportTest::testAreaChartLoad()
{
- load ("/chart2/qa/extras/data/docx/", "testAreaChartLoad.docx");
+ load (u"/chart2/qa/extras/data/docx/", "testAreaChartLoad.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:areaChart/c:ser/c:dLbls/c:showVal", "val", "1");
@@ -853,7 +853,7 @@ void Chart2ExportTest::testUpDownBars()
void Chart2ExportTest::testDoughnutChart()
{
- load("/chart2/qa/extras/data/docx/", "doughnutChart.docx");
+ load(u"/chart2/qa/extras/data/docx/", "doughnutChart.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -862,7 +862,7 @@ void Chart2ExportTest::testDoughnutChart()
void Chart2ExportTest::testDisplayUnits()
{
- load("/chart2/qa/extras/data/docx/", "DisplayUnits.docx");
+ load(u"/chart2/qa/extras/data/docx/", "DisplayUnits.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -880,7 +880,7 @@ void Chart2ExportTest::testDisplayUnits()
void Chart2ExportTest::testFdo74115WallBitmapFill()
{
- load("/chart2/qa/extras/data/docx/", "fdo74115_WallBitmapFill.docx");
+ load(u"/chart2/qa/extras/data/docx/", "fdo74115_WallBitmapFill.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:spPr/a:blipFill");
@@ -888,7 +888,7 @@ void Chart2ExportTest::testFdo74115WallBitmapFill()
void Chart2ExportTest::testPieChartWallLineStyle()
{
- load("/chart2/qa/extras/data/odt/", "testPieChartWallLineStyle.odt");
+ load(u"/chart2/qa/extras/data/odt/", "testPieChartWallLineStyle.odt");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:spPr/a:ln/a:noFill");
@@ -898,7 +898,7 @@ void Chart2ExportTest::testPieChartWallLineStyle()
void Chart2ExportTest::testFdo78290LineChartMarkerX()
{
- load("/chart2/qa/extras/data/docx/", "fdo78290_Line_Chart_Marker_x.docx");
+ load(u"/chart2/qa/extras/data/docx/", "fdo78290_Line_Chart_Marker_x.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace[1]/c:chart[1]/c:plotArea[1]/c:lineChart[1]/c:ser[1]/c:marker[1]/c:symbol[1]","val","x");
@@ -909,7 +909,7 @@ void Chart2ExportTest::testFdo78290LineChartMarkerX()
void Chart2ExportTest::testFdo78290ScatterChartMarkerX()
{
- load("/chart2/qa/extras/data/docx/", "fdo78290_Scatter_Chart_Marker_x.docx");
+ load(u"/chart2/qa/extras/data/docx/", "fdo78290_Scatter_Chart_Marker_x.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace[1]/c:chart[1]/c:plotArea[1]/c:scatterChart[1]/c:ser[1]/c:marker[1]/c:symbol[1]","val","x");
@@ -921,7 +921,7 @@ void Chart2ExportTest::testFdo78290ScatterChartMarkerX()
void Chart2ExportTest::testFdo78290CombinationChartMarkerX()
{
- load("/chart2/qa/extras/data/docx/", "fdo78290_Combination_Chart_Marker_x.docx");
+ load(u"/chart2/qa/extras/data/docx/", "fdo78290_Combination_Chart_Marker_x.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace[1]/c:chart[1]/c:plotArea[1]/c:lineChart[1]/c:ser[1]/c:marker[1]/c:symbol[1]","val","x");
@@ -931,7 +931,7 @@ void Chart2ExportTest::testFdo78290CombinationChartMarkerX()
void Chart2ExportTest::testTdf126115IndividualMarker()
{
// Check individual marker properties.
- load("/chart2/qa/extras/data/xlsx/", "tdf126115.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf126115.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// 1. series
@@ -981,7 +981,7 @@ void Chart2ExportTest::testAxisNumberFormatODS()
} aTest;
- load("/chart2/qa/extras/data/ods/", "axis-numformats-linked.ods");
+ load(u"/chart2/qa/extras/data/ods/", "axis-numformats-linked.ods");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
aTest.check(xChartDoc);
@@ -1037,7 +1037,7 @@ void Chart2ExportTest::testAxisNumberFormatXLS()
} aTest;
- load( "/chart2/qa/extras/data/xls/", "axis_sourceformatting.xls" );
+ load( u"/chart2/qa/extras/data/xls/", "axis_sourceformatting.xls" );
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet( 0, mxComponent );
aTest.check( xChartDoc, true, util::NumberFormat::PERCENT );
@@ -1136,7 +1136,7 @@ void Chart2ExportTest::testDataLabelBordersDOCX()
} aTest;
- load("/chart2/qa/extras/data/docx/", "data-label-borders.docx");
+ load(u"/chart2/qa/extras/data/docx/", "data-label-borders.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
@@ -1164,7 +1164,7 @@ void Chart2ExportTest::testDataLabelBordersDOCX()
void Chart2ExportTest::testDataLabel3DChartDOCX()
{
- load("/chart2/qa/extras/data/docx/", "3d-bar-label.docx");
+ load(u"/chart2/qa/extras/data/docx/", "3d-bar-label.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1180,7 +1180,7 @@ void Chart2ExportTest::testDataLabel3DChartDOCX()
void Chart2ExportTest::testDataLabelBarChartDOCX()
{
- load("/chart2/qa/extras/data/docx/", "bar-chart-labels.docx");
+ load(u"/chart2/qa/extras/data/docx/", "bar-chart-labels.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1195,7 +1195,7 @@ void Chart2ExportTest::testDataLabelBarChartDOCX()
void Chart2ExportTest::testDataLabelClusteredBarChartDOCX()
{
- load("/chart2/qa/extras/data/docx/", "clustered-bar-chart-labels.docx");
+ load(u"/chart2/qa/extras/data/docx/", "clustered-bar-chart-labels.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1209,7 +1209,7 @@ void Chart2ExportTest::testDataLabelClusteredBarChartDOCX()
void Chart2ExportTest::testDataLabelRadarChartDOCX()
{
- load("/chart2/qa/extras/data/docx/", "radar-chart-labels.docx");
+ load(u"/chart2/qa/extras/data/docx/", "radar-chart-labels.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1224,7 +1224,7 @@ void Chart2ExportTest::testDataLabelRadarChartDOCX()
void Chart2ExportTest::testDataLabelDoughnutChartDOCX()
{
- load("/chart2/qa/extras/data/docx/", "doughnut-chart-labels.docx");
+ load(u"/chart2/qa/extras/data/docx/", "doughnut-chart-labels.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1239,7 +1239,7 @@ void Chart2ExportTest::testDataLabelDoughnutChartDOCX()
void Chart2ExportTest::testDataLabelAreaChartDOCX()
{
- load("/chart2/qa/extras/data/docx/", "area-chart-labels.docx");
+ load(u"/chart2/qa/extras/data/docx/", "area-chart-labels.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1258,7 +1258,7 @@ void Chart2ExportTest::testDataLabelDefaultLineChartDOCX()
// label position (2010 does). Make sure its default data label position
// is RIGHT when exporting.
- load("/chart2/qa/extras/data/docx/", "line-chart-label-default-placement.docx");
+ load(u"/chart2/qa/extras/data/docx/", "line-chart-label-default-placement.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1277,7 +1277,7 @@ void Chart2ExportTest::testDataLabelDefaultLineChartDOCX()
void Chart2ExportTest::testIndividualDataLabelProps()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf122915.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf122915.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:scatterChart/c:ser[3]/c:dLbls/c:dLbl/c:txPr/a:p/a:pPr/a:defRPr", "b", "1");
@@ -1288,7 +1288,7 @@ void Chart2ExportTest::testIndividualDataLabelProps()
void Chart2ExportTest::testTdf108107()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf108107.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf108107.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:lineChart/c:ser/c:dLbls/c:dLbl[1]/c:idx", "val", "1");
@@ -1298,7 +1298,7 @@ void Chart2ExportTest::testTdf108107()
void Chart2ExportTest::testTdf114139()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf114139.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf114139.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1310,7 +1310,7 @@ void Chart2ExportTest::testTdf114139()
void Chart2ExportTest::testTdf64224()
{
- load("/chart2/qa/extras/data/ods/", "tdf64224.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf64224.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1321,7 +1321,7 @@ void Chart2ExportTest::testTdf64224()
void Chart2ExportTest::testChartTitlePropertiesColorFillDOCX()
{
- load("/chart2/qa/extras/data/docx/", "testChartTitlePropertiesColorFill.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testChartTitlePropertiesColorFill.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:solidFill/a:srgbClr", "val", "ff0000");
@@ -1330,7 +1330,7 @@ void Chart2ExportTest::testChartTitlePropertiesColorFillDOCX()
void Chart2ExportTest::testChartTitlePropertiesGradientFillDOCX()
{
- load("/chart2/qa/extras/data/docx/", "testChartTitlePropertiesGradientFill.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testChartTitlePropertiesGradientFill.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:gradFill/a:gsLst/a:gs[1]/a:srgbClr", "val", "cccccc");
@@ -1340,7 +1340,7 @@ void Chart2ExportTest::testChartTitlePropertiesGradientFillDOCX()
void Chart2ExportTest::testChartTitlePropertiesBitmapFillDOCX()
{
- load("/chart2/qa/extras/data/docx/", "testChartTitlePropertiesBitmapFill.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testChartTitlePropertiesBitmapFill.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:blipFill/a:blip", "embed", "rId1");
@@ -1350,7 +1350,7 @@ void Chart2ExportTest::testChartTitlePropertiesBitmapFillDOCX()
void Chart2ExportTest::testColorGradientWithTransparencyDOCX()
{
// Test color gradient (two color) with gradient transparency
- load("/chart2/qa/extras/data/docx/", "testColorGradientWithTransparency.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testColorGradientWithTransparency.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
// Test the transparency of the first color
@@ -1362,7 +1362,7 @@ void Chart2ExportTest::testColorGradientWithTransparencyDOCX()
void Chart2ExportTest::testColorGradientWithTransparencyODS()
{
// Test color gradient (two color) with simple transparency
- load("/chart2/qa/extras/data/ods/", "testColorGradientWithTransparency.ods");
+ load(u"/chart2/qa/extras/data/ods/", "testColorGradientWithTransparency.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// Test the transparency of the first color
@@ -1374,7 +1374,7 @@ void Chart2ExportTest::testColorGradientWithTransparencyODS()
void Chart2ExportTest::testColorGradientStopXLSX()
{
// Test color gradient (two color) stop of the first color
- load("/chart2/qa/extras/data/xlsx/", "tdf128619.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf128619.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// Test the position of the first color
@@ -1385,7 +1385,7 @@ void Chart2ExportTest::testColorGradientStopXLSX()
void Chart2ExportTest::testRadialColorGradientDOCX()
{
- load("/chart2/qa/extras/data/docx/", "tdf128794.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf128794.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
// Test the gradient style (if there is no 'a:path' attribute, it is a linear gradient)
@@ -1396,7 +1396,7 @@ void Chart2ExportTest::testRadialColorGradientDOCX()
void Chart2ExportTest::testBarChartDataPointPropDOCX()
{
- load("/chart2/qa/extras/data/docx/", "testBarChartDataPointPropDOCX.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testBarChartDataPointPropDOCX.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1414,7 +1414,7 @@ void Chart2ExportTest::testBarChartDataPointPropDOCX()
void Chart2ExportTest::testBarChartRotation()
{
- load ("/chart2/qa/extras/data/docx/", "barChartRotation.docx");
+ load (u"/chart2/qa/extras/data/docx/", "barChartRotation.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1429,7 +1429,7 @@ void Chart2ExportTest::testShapeFollowedByChart()
docPr Id is being repeated, ECMA 20.4.2.5 says that the
docPr Id should be unique, ensuring the same here.
*/
- load("/chart2/qa/extras/data/docx/", "FDO74430.docx");
+ load(u"/chart2/qa/extras/data/docx/", "FDO74430.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/document", "Office Open XML Text" );
CPPUNIT_ASSERT(pXmlDoc);
@@ -1441,7 +1441,7 @@ void Chart2ExportTest::testShapeFollowedByChart()
void Chart2ExportTest::testPieChartDataLabels()
{
- load("/chart2/qa/extras/data/docx/", "PieChartDataLabels.docx");
+ load(u"/chart2/qa/extras/data/docx/", "PieChartDataLabels.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:pie3DChart/c:ser[1]/c:dLbls/c:dLbl[1]/c:dLblPos", "val", "outEnd");
@@ -1449,7 +1449,7 @@ void Chart2ExportTest::testPieChartDataLabels()
void Chart2ExportTest::testSeriesIdxOrder()
{
- load("/chart2/qa/extras/data/docx/", "testSeriesIdxOrder.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testSeriesIdxOrder.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace[1]/c:chart[1]/c:plotArea[1]/c:lineChart[1]/c:ser[1]/c:idx[1]", "val", "1");
@@ -1458,7 +1458,7 @@ void Chart2ExportTest::testSeriesIdxOrder()
void Chart2ExportTest::testScatterPlotLabels()
{
- load("/chart2/qa/extras/data/odt/", "scatter-plot-labels.odt");
+ load(u"/chart2/qa/extras/data/odt/", "scatter-plot-labels.odt");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1490,7 +1490,7 @@ void Chart2ExportTest::testScatterPlotLabels()
void Chart2ExportTest::testErrorBarDataRangeODS()
{
- load("/chart2/qa/extras/data/ods/", "ErrorBarRange.ods");
+ load(u"/chart2/qa/extras/data/ods/", "ErrorBarRange.ods");
reload("calc8");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
@@ -1519,14 +1519,14 @@ void Chart2ExportTest::testErrorBarDataRangeODS()
void Chart2ExportTest::testChartCrash()
{
- load("/chart2/qa/extras/data/docx/", "FDO75975.docx");
+ load(u"/chart2/qa/extras/data/docx/", "FDO75975.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
}
void Chart2ExportTest::testPieChartRotation()
{
- load ("/chart2/qa/extras/data/docx/", "pieChartRotation.docx");
+ load (u"/chart2/qa/extras/data/docx/", "pieChartRotation.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:view3D/c:rotX", "val", "40");
@@ -1539,7 +1539,7 @@ void Chart2ExportTest::testEmbeddingsOleObjectGrabBag()
// after saving file.
// This test case tests whether embeddings files grabbagged properly in correct object.
- load("/chart2/qa/extras/data/docx/", "testchartoleobjectembeddings.docx" );
+ load(u"/chart2/qa/extras/data/docx/", "testchartoleobjectembeddings.docx" );
uno::Reference<text::XTextDocument> xTextDocument(mxComponent, uno::UNO_QUERY);
uno::Reference<beans::XPropertySet> xTextDocumentPropertySet(xTextDocument, uno::UNO_QUERY);
uno::Sequence<beans::PropertyValue> aGrabBag(0);
@@ -1610,7 +1610,7 @@ void checkSheetForGapWidthAndOverlap(uno::Reference< chart2::XChartDocument > co
void Chart2ExportTest::testGapWidthXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "gapWidth.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "gapWidth.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
checkSheetForGapWidthAndOverlap(xChartDoc, 120, -60);
@@ -1629,7 +1629,7 @@ void Chart2ExportTest::testGapWidthXLSX()
void Chart2ExportTest::testSmoothedLines()
{
- load("/chart2/qa/extras/data/ods/", "smoothedLines.ods");
+ load(u"/chart2/qa/extras/data/ods/", "smoothedLines.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:lineChart/c:ser[1]/c:smooth", "val", "0");
@@ -1637,7 +1637,7 @@ void Chart2ExportTest::testSmoothedLines()
void Chart2ExportTest::testLabelStringODS()
{
- load("/chart2/qa/extras/data/ods/", "labelString.ods");
+ load(u"/chart2/qa/extras/data/ods/", "labelString.ods");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
Reference< chart2::data::XDataSequence > xLabelSeq =
@@ -1659,7 +1659,7 @@ void Chart2ExportTest::testLabelStringODS()
void Chart2ExportTest::testFdo83058dlblPos()
{
- load ("/chart2/qa/extras/data/docx/", "fdo83058_dlblPos.docx");
+ load (u"/chart2/qa/extras/data/docx/", "fdo83058_dlblPos.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:barChart/c:ser[1]/c:dLbls[1]/c:dLbl[2]/c:dLblPos", "val", "outEnd");
@@ -1670,7 +1670,7 @@ void Chart2ExportTest::testFdo83058dlblPos()
void Chart2ExportTest::testAutoTitleDelXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "autotitledel_2007.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "autotitledel_2007.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:autoTitleDeleted", "val", "0");
@@ -1678,7 +1678,7 @@ void Chart2ExportTest::testAutoTitleDelXLSX()
void Chart2ExportTest::testDispBlanksAsXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "dispBlanksAs_2007.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "dispBlanksAs_2007.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:dispBlanksAs", "val", "gap");
@@ -1686,7 +1686,7 @@ void Chart2ExportTest::testDispBlanksAsXLSX()
void Chart2ExportTest::testMarkerColorXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "markerColor.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "markerColor.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:scatterChart/c:ser/c:marker/c:spPr/a:solidFill/a:srgbClr", "val", "92d050");
@@ -1694,7 +1694,7 @@ void Chart2ExportTest::testMarkerColorXLSX()
void Chart2ExportTest::testRoundedCornersXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "markerColor.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "markerColor.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:roundedCorners", "val", "0");
@@ -1702,7 +1702,7 @@ void Chart2ExportTest::testRoundedCornersXLSX()
void Chart2ExportTest::testAxisNumberFormatXLSX()
{
- load("/chart2/qa/extras/data/ods/", "axis_number_format.ods");
+ load(u"/chart2/qa/extras/data/ods/", "axis_number_format.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:valAx", 2);
@@ -1715,7 +1715,7 @@ void Chart2ExportTest::testAxisNumberFormatXLSX()
void Chart2ExportTest::testDataPointLabelNumberFormatXLSX()
{
- load("/chart2/qa/extras/data/ods/", "tdf123774.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf123774.ods");
{
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1726,7 +1726,7 @@ void Chart2ExportTest::testDataPointLabelNumberFormatXLSX()
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:pieChart/c:ser/c:dLbls/c:dLbl[1]/c:numFmt", "sourceLinked", "0");
}
- load("/chart2/qa/extras/data/xlsx/", "tdf130986.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf130986.xlsx");
{
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1738,7 +1738,7 @@ void Chart2ExportTest::testDataPointLabelNumberFormatXLSX()
void Chart2ExportTest::testDataLabelDefaultValuesXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "data_label.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "data_label.xlsx");
Reference< chart2::XChartDocument> xDoc = getChartDocFromSheet(0, mxComponent);
Reference<chart2::XDataSeries> xSeries = getDataSeriesFromDoc(xDoc, 0);
Reference<beans::XPropertySet> xPropSet(xSeries, uno::UNO_QUERY_THROW);
@@ -1755,7 +1755,7 @@ void Chart2ExportTest::testDataLabelDefaultValuesXLSX()
void Chart2ExportTest::testDataLabelFillColor()
{
- load("/chart2/qa/extras/data/xlsx/", "data_labels_fill_color.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "data_labels_fill_color.xlsx");
Reference< chart2::XChartDocument> xDoc = getChartDocFromSheet(0, mxComponent);
Reference<chart2::XDataSeries> xSeries = getDataSeriesFromDoc(xDoc, 0);
Reference<beans::XPropertySet> xPropSet(xSeries, uno::UNO_QUERY_THROW);
@@ -1770,7 +1770,7 @@ void Chart2ExportTest::testDataLabelFillColor()
void Chart2ExportTest::testTitleOverlayXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "chart_title.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "chart_title.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:overlay", "val", "0");
@@ -1778,7 +1778,7 @@ void Chart2ExportTest::testTitleOverlayXLSX()
void Chart2ExportTest::testInvertIfNegativeXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "bar_chart_simple.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "bar_chart_simple.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:barChart/c:ser/c:invertIfNegative", "val", "0");
@@ -1786,7 +1786,7 @@ void Chart2ExportTest::testInvertIfNegativeXLSX()
void Chart2ExportTest::testBubble3DXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "bubble_chart_simple.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "bubble_chart_simple.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:bubbleChart/c:ser[1]/c:bubble3D", "val", "0");
@@ -1796,7 +1796,7 @@ void Chart2ExportTest::testBubble3DXLSX()
void Chart2ExportTest::testNoMarkerXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "no_marker.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "no_marker.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:lineChart/c:ser[1]/c:marker/c:symbol", "val", "none");
@@ -1806,7 +1806,7 @@ void Chart2ExportTest::testNoMarkerXLSX()
void Chart2ExportTest::testTitleManualLayoutXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "title_manual_layout.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "title_manual_layout.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:layout/c:manualLayout/c:layoutTarget", 0);
@@ -1827,7 +1827,7 @@ void Chart2ExportTest::testTitleManualLayoutXLSX()
void Chart2ExportTest::testPlotAreaManualLayoutXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "plot_area_manual_layout.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "plot_area_manual_layout.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1856,7 +1856,7 @@ void Chart2ExportTest::testPlotAreaManualLayoutXLSX()
void Chart2ExportTest::testLegendManualLayoutXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "legend_manual_layout.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "legend_manual_layout.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1888,7 +1888,7 @@ void Chart2ExportTest::testLegendManualLayoutXLSX()
void Chart2ExportTest::testChartSubTitle()
{
- load("/chart2/qa/extras/data/ods/", "testChartSubTitle.ods");
+ load(u"/chart2/qa/extras/data/ods/", "testChartSubTitle.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// test properties of subtitle
@@ -1902,7 +1902,7 @@ void Chart2ExportTest::testChartSubTitle()
void Chart2ExportTest::testChartMainWithSubTitle()
{
- load("/chart2/qa/extras/data/ods/", "testChartMainWithSubTitle.ods");
+ load(u"/chart2/qa/extras/data/ods/", "testChartMainWithSubTitle.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// test properties of title
@@ -1917,7 +1917,7 @@ void Chart2ExportTest::testChartMainWithSubTitle()
void Chart2ExportTest::testAutoTitleDeleted()
{
- load("/chart2/qa/extras/data/xlsx/", "testAutoTitleDeleted.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testAutoTitleDeleted.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:autoTitleDeleted", "val", "1");
@@ -1925,7 +1925,7 @@ void Chart2ExportTest::testAutoTitleDeleted()
void Chart2ExportTest::testChartTitlePropertiesColorFillXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "testChartTitlePropertiesColorFill.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testChartTitlePropertiesColorFill.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:solidFill/a:srgbClr", "val", "ff0000");
@@ -1934,7 +1934,7 @@ void Chart2ExportTest::testChartTitlePropertiesColorFillXLSX()
void Chart2ExportTest::testChartTitlePropertiesGradientFillXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "testChartTitlePropertiesGradientFill.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testChartTitlePropertiesGradientFill.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:gradFill/a:gsLst/a:gs[1]/a:srgbClr", "val", "cccccc");
@@ -1944,7 +1944,7 @@ void Chart2ExportTest::testChartTitlePropertiesGradientFillXLSX()
void Chart2ExportTest::testChartTitlePropertiesBitmapFillXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "testChartTitlePropertiesBitmapFill.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testChartTitlePropertiesBitmapFill.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:blipFill/a:blip", "embed", "rId1");
@@ -1953,7 +1953,7 @@ void Chart2ExportTest::testChartTitlePropertiesBitmapFillXLSX()
void Chart2ExportTest::testBarChartDataPointPropXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "testBarChartDataPointPropXLSX.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testBarChartDataPointPropXLSX.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -1971,7 +1971,7 @@ void Chart2ExportTest::testBarChartDataPointPropXLSX()
void Chart2ExportTest::testDataseriesOverlapStackedChartXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "testDataseriesOverlapStackedChart.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testDataseriesOverlapStackedChart.xlsx");
// test the overlap value of a simple Stacked Column Chart
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
@@ -1992,7 +1992,7 @@ void Chart2ExportTest::testDataseriesOverlapStackedChartXLSX()
void Chart2ExportTest::testAxisCharacterPropertiesXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "axis_character_properties.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "axis_character_properties.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2009,7 +2009,7 @@ void Chart2ExportTest::testAxisCharacterPropertiesXLSX()
void Chart2ExportTest::testTitleCharacterPropertiesXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "title_character_properties.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "title_character_properties.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2022,7 +2022,7 @@ void Chart2ExportTest::testTitleCharacterPropertiesXLSX()
void Chart2ExportTest::testPlotVisOnlyXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "hidden_cells.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "hidden_cells.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2031,7 +2031,7 @@ void Chart2ExportTest::testPlotVisOnlyXLSX()
void Chart2ExportTest::testBarChartVaryColorsXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf90876.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf90876.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2040,7 +2040,7 @@ void Chart2ExportTest::testBarChartVaryColorsXLSX()
void Chart2ExportTest::testMultipleAxisXLSX()
{
- load("/chart2/qa/extras/data/ods/", "multiple_axis.ods");
+ load(u"/chart2/qa/extras/data/ods/", "multiple_axis.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2055,7 +2055,7 @@ void Chart2ExportTest::testMultipleAxisXLSX()
void Chart2ExportTest::testSecondaryAxisXLSX()
{
- load("/chart2/qa/extras/data/ods/", "secondary_axis.ods");
+ load(u"/chart2/qa/extras/data/ods/", "secondary_axis.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2071,7 +2071,7 @@ void Chart2ExportTest::testSecondaryAxisXLSX()
void Chart2ExportTest::testSetSeriesToSecondaryAxisXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "add_series_secondary_axis.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "add_series_secondary_axis.xlsx");
Reference< chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
// Second series
Reference<chart2::XDataSeries> xSeries = getDataSeriesFromDoc(xChartDoc, 1);
@@ -2091,7 +2091,7 @@ void Chart2ExportTest::testSetSeriesToSecondaryAxisXLSX()
void Chart2ExportTest::testCombinedChartSecondaryAxisXLSX()
{
// Original file was created with MS Office
- load("/chart2/qa/extras/data/xlsx/", "combined_chart_secondary_axis.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "combined_chart_secondary_axis.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// Collect barchart axID on secondary Axis
@@ -2110,7 +2110,7 @@ void Chart2ExportTest::testCombinedChartSecondaryAxisXLSX()
void Chart2ExportTest::testCombinedChartSecondaryAxisODS()
{
// Original file was created with LibreOffice
- load("/chart2/qa/extras/data/ods/", "combined_chart_secondary_axis.ods");
+ load(u"/chart2/qa/extras/data/ods/", "combined_chart_secondary_axis.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// Collect barchart axID on secondary Axis
@@ -2132,13 +2132,13 @@ void Chart2ExportTest::testCrossBetweenXLSX()
{
// Original files were created with MS Office
{
- load("/chart2/qa/extras/data/xlsx/", "tdf127777.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf127777.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:valAx/c:crossBetween", "val", "between");
}
{
- load("/chart2/qa/extras/data/xlsx/", "tdf132076.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf132076.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:valAx/c:crossBetween", "val", "between");
@@ -2148,7 +2148,7 @@ void Chart2ExportTest::testCrossBetweenXLSX()
void Chart2ExportTest::testCrossBetweenWithDeletedAxis()
{
// Original file was created with MS Office (the category axis is deleted in the file)
- load("/chart2/qa/extras/data/xlsx/", "tdf128633.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf128633.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:valAx/c:crossBetween", "val", "between");
@@ -2157,7 +2157,7 @@ void Chart2ExportTest::testCrossBetweenWithDeletedAxis()
void Chart2ExportTest::testCrossBetweenODS()
{
// Original file was created with LibreOffice
- load("/chart2/qa/extras/data/ods/", "test_CrossBetween.ods");
+ load(u"/chart2/qa/extras/data/ods/", "test_CrossBetween.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:valAx/c:crossBetween", "val", "between");
@@ -2165,7 +2165,7 @@ void Chart2ExportTest::testCrossBetweenODS()
void Chart2ExportTest::testAxisTitleRotationXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "axis_title_rotation.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "axis_title_rotation.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2174,7 +2174,7 @@ void Chart2ExportTest::testAxisTitleRotationXLSX()
void Chart2ExportTest::testAxisTitlePositionDOCX()
{
- load("/chart2/qa/extras/data/docx/", "testAxisTitlePosition.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testAxisTitlePosition.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2198,14 +2198,14 @@ void Chart2ExportTest::testAxisTitlePositionDOCX()
void Chart2ExportTest::testAxisCrossBetweenDOCX()
{
- load("/chart2/qa/extras/data/odt/", "axis-position.odt");
+ load(u"/chart2/qa/extras/data/odt/", "axis-position.odt");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
assertXPath(pXmlDoc, "(//c:crossBetween)[1]", "val", "midCat");
}
void Chart2ExportTest::testPieChartDataPointExplosionXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "pie_chart_datapoint_explosion.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "pie_chart_datapoint_explosion.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2214,7 +2214,7 @@ void Chart2ExportTest::testPieChartDataPointExplosionXLSX()
void Chart2ExportTest::testCustomDataLabel()
{
- load("/chart2/qa/extras/data/pptx/", "tdf115107.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf115107.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart1", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
// Check the data labels font color for the complete data series
@@ -2312,7 +2312,7 @@ void Chart2ExportTest::testCustomDataLabel()
void Chart2ExportTest::testCustomPositionofDataLabel()
{
- load("/chart2/qa/extras/data/xlsx/", "testCustomPosDataLabels.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testCustomPosDataLabels.xlsx");
{
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2328,7 +2328,7 @@ void Chart2ExportTest::testCustomPositionofDataLabel()
CPPUNIT_ASSERT_DOUBLES_EQUAL(-0.0742140311063737, nY, 1e-7);
}
- load("/chart2/qa/extras/data/docx/", "testTdf108110.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testTdf108110.docx");
{
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2344,7 +2344,7 @@ void Chart2ExportTest::testCustomPositionofDataLabel()
CPPUNIT_ASSERT_DOUBLES_EQUAL(0.172648731408574, nY, 1e-7);
}
- load("/chart2/qa/extras/data/ods/", "tdf136024.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf136024.ods");
{
reload("calc8");
// tdf#136024: test custom position of pie chart data label after an ods export
@@ -2364,7 +2364,7 @@ void Chart2ExportTest::testCustomPositionofDataLabel()
void Chart2ExportTest::testCustomDataLabelMultipleSeries()
{
- load("/chart2/qa/extras/data/pptx/", "tdf115107-2.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf115107-2.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart2", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2421,14 +2421,14 @@ void Chart2ExportTest::testCustomDataLabelMultipleSeries()
void Chart2ExportTest::testLeaderLines()
{
- load("/chart2/qa/extras/data/xlsx/", "testTdf90749.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testTdf90749.xlsx");
{
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:lineChart/c:ser[1]/c:dLbls/c:extLst/c:ext/c15:showLeaderLines", "val", "1");
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:lineChart/c:ser[2]/c:dLbls/c:extLst/c:ext/c15:showLeaderLines", "val", "0");
}
- load("/chart2/qa/extras/data/docx/", "MSO_Custom_Leader_Line.docx");
+ load(u"/chart2/qa/extras/data/docx/", "MSO_Custom_Leader_Line.docx");
{
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart1", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2439,7 +2439,7 @@ void Chart2ExportTest::testLeaderLines()
void Chart2ExportTest::testNumberFormatExportPPTX()
{
- load("/chart2/qa/extras/data/pptx/", "tdf115859.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf115859.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2449,7 +2449,7 @@ void Chart2ExportTest::testNumberFormatExportPPTX()
void Chart2ExportTest::testLabelSeparatorExportDOCX()
{
- load("/chart2/qa/extras/data/docx/", "testLabelSeparator.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testLabelSeparator.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2467,7 +2467,7 @@ void Chart2ExportTest::testLabelSeparatorExportDOCX()
void Chart2ExportTest::testChartTitlePropertiesColorFillPPTX()
{
- load("/chart2/qa/extras/data/pptx/", "testChartTitlePropertiesColorFill.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "testChartTitlePropertiesColorFill.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:solidFill/a:srgbClr", "val", "ff0000");
@@ -2476,7 +2476,7 @@ void Chart2ExportTest::testChartTitlePropertiesColorFillPPTX()
void Chart2ExportTest::testChartTitlePropertiesGradientFillPPTX()
{
- load("/chart2/qa/extras/data/pptx/", "testChartTitlePropertiesGradientFill.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "testChartTitlePropertiesGradientFill.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:gradFill/a:gsLst/a:gs[1]/a:srgbClr", "val", "f6f8fc");
@@ -2486,7 +2486,7 @@ void Chart2ExportTest::testChartTitlePropertiesGradientFillPPTX()
void Chart2ExportTest::testChartTitlePropertiesBitmapFillPPTX()
{
- load("/chart2/qa/extras/data/pptx/", "testChartTitlePropertiesBitmapFill.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "testChartTitlePropertiesBitmapFill.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:title/c:spPr/a:blipFill/a:blip", "embed", "rId1");
@@ -2495,7 +2495,7 @@ void Chart2ExportTest::testChartTitlePropertiesBitmapFillPPTX()
void Chart2ExportTest::testxAxisLabelsRotation()
{
- load ("/chart2/qa/extras/data/xlsx/", "xAxisLabelsRotation.xlsx");
+ load (u"/chart2/qa/extras/data/xlsx/", "xAxisLabelsRotation.xlsx");
xmlDocUniquePtr pXmlDoc1 = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc1);
@@ -2505,7 +2505,7 @@ void Chart2ExportTest::testxAxisLabelsRotation()
void Chart2ExportTest::testMultipleCategoryAxisLablesXLSX()
{
- load("/chart2/qa/extras/data/ods/", "multilevelcat.ods");
+ load(u"/chart2/qa/extras/data/ods/", "multilevelcat.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// check category axis labels number of first level
@@ -2522,7 +2522,7 @@ void Chart2ExportTest::testMultipleCategoryAxisLablesXLSX()
void Chart2ExportTest::testMultipleCategoryAxisLablesDOCX()
{
- load("/chart2/qa/extras/data/odt/", "multilevelcat.odt");
+ load(u"/chart2/qa/extras/data/odt/", "multilevelcat.odt");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
// check category axis labels number of first level
@@ -2539,7 +2539,7 @@ void Chart2ExportTest::testMultipleCategoryAxisLablesDOCX()
void Chart2ExportTest::testTdf116163()
{
- load("/chart2/qa/extras/data/pptx/", "tdf116163.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf116163.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2548,7 +2548,7 @@ void Chart2ExportTest::testTdf116163()
void Chart2ExportTest::testTdf111824()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf111824.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf111824.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2560,7 +2560,7 @@ void Chart2ExportTest::testTdf111824()
void Chart2ExportTest::test3DAreaChartZAxis()
{
- load("/chart2/qa/extras/data/xlsx/", "test3DAreaChartZAxis.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "test3DAreaChartZAxis.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2572,7 +2572,7 @@ void Chart2ExportTest::test3DAreaChartZAxis()
void Chart2ExportTest::testTdf119029()
{
- load("/chart2/qa/extras/data/odp/", "tdf119029.odp");
+ load(u"/chart2/qa/extras/data/odp/", "tdf119029.odp");
// Only use "chart", without number, because the number depends on the previous tests
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2584,7 +2584,7 @@ void Chart2ExportTest::testTdf119029()
void Chart2ExportTest::testTdf108022()
{
- load("/chart2/qa/extras/data/odt/", "tdf108022.odt");
+ load(u"/chart2/qa/extras/data/odt/", "tdf108022.odt");
reload("Office Open XML Text");
// assert we really have two charts
@@ -2596,7 +2596,7 @@ void Chart2ExportTest::testTdf108022()
void Chart2ExportTest::testTdf121744()
{
- load("/chart2/qa/extras/data/docx/", "tdf121744.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf121744.docx");
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart","Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2609,7 +2609,7 @@ void Chart2ExportTest::testTdf121744()
void Chart2ExportTest::testTdf121189()
{
- load("/chart2/qa/extras/data/odp/", "tdf121189.odp");
+ load(u"/chart2/qa/extras/data/odp/", "tdf121189.odp");
reload("Impress Office Open XML");
uno::Reference<drawing::XDrawPagesSupplier> xDoc(mxComponent, uno::UNO_QUERY_THROW);
@@ -2623,7 +2623,7 @@ void Chart2ExportTest::testTdf122031()
{
//Checks pie chart data label format.
- load("/chart2/qa/extras/data/xlsx/", "tdf122031.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf122031.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2635,7 +2635,7 @@ void Chart2ExportTest::testTdf122031()
void Chart2ExportTest::testTdf115012()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf115012.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf115012.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// workaround: use-zero instead of leave-gap to show the original line chart
@@ -2644,7 +2644,7 @@ void Chart2ExportTest::testTdf115012()
void Chart2ExportTest::testTdf134118()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf134118.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf134118.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
// workaround: use leave-gap instead of zero to show the original line chart
@@ -2653,7 +2653,7 @@ void Chart2ExportTest::testTdf134118()
void Chart2ExportTest::testTdf123206_customLabelText()
{
- load("/chart2/qa/extras/data/docx/", "tdf123206.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf123206.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2666,7 +2666,7 @@ void Chart2ExportTest::testTdf123206_customLabelText()
void Chart2ExportTest::testCustomLabelText()
{
- load("/chart2/qa/extras/data/docx/", "testCustomlabeltext.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testCustomlabeltext.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2685,7 +2685,7 @@ void Chart2ExportTest::testCustomLabelText()
void Chart2ExportTest::testDeletedLegendEntries()
{
- load("/chart2/qa/extras/data/xlsx/", "deleted_legend_entry.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "deleted_legend_entry.xlsx");
{
reload("Calc Office Open XML");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
@@ -2698,7 +2698,7 @@ void Chart2ExportTest::testDeletedLegendEntries()
CPPUNIT_ASSERT(!bShowLegendEntry);
}
- load("/chart2/qa/extras/data/xlsx/", "deleted_legend_entry2.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "deleted_legend_entry2.xlsx");
{
reload("Calc Office Open XML");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
@@ -2723,7 +2723,7 @@ void Chart2ExportTest::testDeletedLegendEntries()
void Chart2ExportTest::testTdf60316()
{
- load("/chart2/qa/extras/data/pptx/", "tdf60316.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf60316.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2734,7 +2734,7 @@ void Chart2ExportTest::testTdf60316()
void Chart2ExportTest::testTdf130225()
{
- load("/chart2/qa/extras/data/docx/", "piechart_deleted_legend_entry.docx");
+ load(u"/chart2/qa/extras/data/docx/", "piechart_deleted_legend_entry.docx");
reload("Office Open XML Text");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2748,7 +2748,7 @@ void Chart2ExportTest::testTdf130225()
void Chart2ExportTest::testTdf59857()
{
- load("/chart2/qa/extras/data/ods/", "tdf59857.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf59857.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2760,7 +2760,7 @@ void Chart2ExportTest::testTdf59857()
void Chart2ExportTest::testTdf126076()
{
- load("/chart2/qa/extras/data/xlsx/", "auto_marker_excel10.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "auto_marker_excel10.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2772,7 +2772,7 @@ void Chart2ExportTest::testTdf126076()
void Chart2ExportTest::testTdf75330()
{
- load("/chart2/qa/extras/data/ods/", "legend_overlay.ods");
+ load(u"/chart2/qa/extras/data/ods/", "legend_overlay.ods");
reload("calc8");
{
uno::Reference<chart2::XChartDocument> xChart2Doc = getChartDocFromSheet(0, mxComponent);
@@ -2797,7 +2797,7 @@ void Chart2ExportTest::testTdf75330()
void Chart2ExportTest::testTdf127792()
{
- load("/chart2/qa/extras/data/docx/", "MSO_axis_position.docx");
+ load(u"/chart2/qa/extras/data/docx/", "MSO_axis_position.docx");
{
xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart1", "Office Open XML Text");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2812,7 +2812,7 @@ void Chart2ExportTest::testTdf127792()
void Chart2ExportTest::testTdf131979()
{
- load("/chart2/qa/extras/data/ods/", "tdf131115.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf131115.ods");
{
reload("calc8");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
@@ -2826,7 +2826,7 @@ void Chart2ExportTest::testTdf131979()
CPPUNIT_ASSERT_MESSAGE("\"LinkNumberFormatToSource\" should be set to false.", !blinknumberformattosource);
}
- load("/chart2/qa/extras/data/ods/", "tdf131979.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf131979.ods");
{
reload("calc8");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
@@ -2844,14 +2844,14 @@ void Chart2ExportTest::testTdf131979()
void Chart2ExportTest::testTdf132076()
{
{
- load("/chart2/qa/extras/data/ods/", "tdf132076.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf132076.ods");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:catAx/c:numFmt", "formatCode", "dd");
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:catAx/c:numFmt", "sourceLinked", "0");
}
{
- load("/chart2/qa/extras/data/xlsx/", "tdf132076.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf132076.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:dateAx/c:numFmt", "formatCode", "dd");
@@ -2861,7 +2861,7 @@ void Chart2ExportTest::testTdf132076()
void Chart2ExportTest::testTdf125812()
{
- load("/chart2/qa/extras/data/odp/", "ellipticalGradientFill.odp");
+ load(u"/chart2/qa/extras/data/odp/", "ellipticalGradientFill.odp");
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
CPPUNIT_ASSERT(pXmlDoc);
assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:spPr/a:gradFill/a:path", "path", "circle");
@@ -2873,7 +2873,7 @@ void Chart2ExportTest::testTdf125812()
void Chart2ExportTest::testTdf133190()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf133190_tdf133191.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf133190_tdf133191.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2884,7 +2884,7 @@ void Chart2ExportTest::testTdf133190()
void Chart2ExportTest::testTdf133191()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf133190_tdf133191.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf133190_tdf133191.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2894,7 +2894,7 @@ void Chart2ExportTest::testTdf133191()
void Chart2ExportTest::testTdf132594()
{
- load("/chart2/qa/extras/data/xlsx/", "chart_pie2007.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "chart_pie2007.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2903,7 +2903,7 @@ void Chart2ExportTest::testTdf132594()
void Chart2ExportTest::testTdf134255()
{
- load("/chart2/qa/extras/data/docx/", "tdf134255.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf134255.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2923,7 +2923,7 @@ void Chart2ExportTest::testTdf134255()
void Chart2ExportTest::testTdf134977()
{
- load("/chart2/qa/extras/data/xlsx/", "custom_data_label.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "custom_data_label.xlsx");
//import test
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
@@ -2945,7 +2945,7 @@ void Chart2ExportTest::testTdf134977()
void Chart2ExportTest::testTdf123647()
{
- load("/chart2/qa/extras/data/xlsx/", "empty_chart.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "empty_chart.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2954,7 +2954,7 @@ void Chart2ExportTest::testTdf123647()
void Chart2ExportTest::testTdf136267()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf136267.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf136267.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2963,7 +2963,7 @@ void Chart2ExportTest::testTdf136267()
void Chart2ExportTest::testDataLabelPlacementPieChart()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf134978.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf134978.xlsx");
reload("calc8");
uno::Reference<chart::XChartDocument> xChartDoc(getChartCompFromSheet(0, mxComponent),
UNO_QUERY_THROW);
@@ -2980,7 +2980,7 @@ void Chart2ExportTest::testDataLabelPlacementPieChart()
void Chart2ExportTest::testTdf137917()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf137917.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf137917.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -2993,7 +2993,7 @@ void Chart2ExportTest::testTdf137917()
void Chart2ExportTest::testTdf138204()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf138204.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf138204.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -3018,7 +3018,7 @@ void Chart2ExportTest::testTdf138204()
void Chart2ExportTest::testTdf138181()
{
- load("/chart2/qa/extras/data/xlsx/", "piechart_deleted_legendentry.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "piechart_deleted_legendentry.xlsx");
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
UNO_QUERY_THROW);
Reference<drawing::XDrawPageSupplier> xDrawPageSupplier(xChartDoc, UNO_QUERY_THROW);
@@ -3044,7 +3044,7 @@ void Chart2ExportTest::testTdf138181()
void Chart2ExportTest::testCustomShapeText()
{
- load("/chart2/qa/extras/data/ods/", "tdf72776.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf72776.ods");
reload("calc8");
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
UNO_QUERY_THROW);
@@ -3060,7 +3060,7 @@ void Chart2ExportTest::testCustomShapeText()
void Chart2ExportTest::testuserShapesXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf128621.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf128621.xlsx");
reload("Calc Office Open XML");
Reference< chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
diff --git a/chart2/qa/extras/chart2geometry.cxx b/chart2/qa/extras/chart2geometry.cxx
index c15f15f66864..4f57654a3587 100644
--- a/chart2/qa/extras/chart2geometry.cxx
+++ b/chart2/qa/extras/chart2geometry.cxx
@@ -181,7 +181,7 @@ static OString OU2O(std::u16string_view sOUSource)
void Chart2GeometryTest::testTdf135184RoundLineCap()
{
// It tests chart area, data series line and regression-curve line.
- load("/chart2/qa/extras/data/xlsx/", "tdf135184RoundLineCap.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf135184RoundLineCap.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("Object 1/content.xml", "calc8");
CPPUNIT_ASSERT(pXmlDoc);
@@ -208,7 +208,7 @@ void Chart2GeometryTest::testTdf135184RoundLineCap()
void Chart2GeometryTest::testTdf135184RoundLineCap2()
{
// It tests legend, data series sector and title.
- load("/chart2/qa/extras/data/xlsx/", "tdf135184RoundLineCap2.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf135184RoundLineCap2.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("Object 1/content.xml", "calc8");
CPPUNIT_ASSERT(pXmlDoc);
@@ -237,7 +237,7 @@ void Chart2GeometryTest::testTdf135184RoundLineCap2()
void Chart2GeometryTest::testTdf135184RoundLineCap3()
{
// It tests chart area, data series line and regression-curve line.
- load("/chart2/qa/extras/data/xlsx/", "tdf135184RoundLineCap.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf135184RoundLineCap.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -254,7 +254,7 @@ void Chart2GeometryTest::testTdf135184RoundLineCap3()
void Chart2GeometryTest::testTdf135184RoundLineCap4()
{
// It tests legend, data series sector and title.
- load("/chart2/qa/extras/data/xlsx/", "tdf135184RoundLineCap2.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf135184RoundLineCap2.xlsx");
xmlDocUniquePtr pXmlDoc = parseExport("xl/charts/chart", "Calc Office Open XML");
CPPUNIT_ASSERT(pXmlDoc);
@@ -270,7 +270,7 @@ void Chart2GeometryTest::testTdf128345ChartArea_CG_TS_export()
{
// chart area with color gradient and solid transparency
// Without the patch the transparency was lost in saved pptx file.
- load("/chart2/qa/extras/data/odp/", "tdf128345_ChartArea_CG_TS.odp");
+ load(u"/chart2/qa/extras/data/odp/", "tdf128345_ChartArea_CG_TS.odp");
// Make sure the chart area has a transparency in gradient stops in saved pptx file.
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
@@ -289,7 +289,7 @@ void Chart2GeometryTest::testTdf128345ChartArea_CG_TS_import()
// Make sure chart area has transparency when pptx document is opened and resaved as odp.
// As of Aug 2020, the import generates a transparency gradient. When import is changed to
// generate solid transparency, the test needs to be adapted.
- load("/chart2/qa/extras/data/pptx/", "tdf128345_ChartArea_CG_TS.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf128345_ChartArea_CG_TS.pptx");
// Find transparency gradient name
xmlDocUniquePtr pXmlDoc = parseExport("Object 1/content.xml", "impress8");
@@ -322,7 +322,7 @@ void Chart2GeometryTest::testTdf128345ChartWall_CS_TG_export()
{
// chart wall with solid color and transparency gradient
// Without the patch the transparency was lost.
- load("/chart2/qa/extras/data/odp/", "tdf128345_ChartWall_CS_TG.odp");
+ load(u"/chart2/qa/extras/data/odp/", "tdf128345_ChartWall_CS_TG.odp");
// Make sure the chart has a gradient with transparency in gradient stops in saved pptx file.
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
@@ -340,7 +340,7 @@ void Chart2GeometryTest::testTdf128345ChartWall_CS_TG_import()
{
// This works on the file, which was exported from file tdf128345_ChartWall_CS_TG.odp to pptx.
// Make sure chart wall has transparency when pptx document is resaved as odp.
- load("/chart2/qa/extras/data/pptx/", "tdf128345_ChartWall_CS_TG.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf128345_ChartWall_CS_TG.pptx");
// Find transparency gradient name
xmlDocUniquePtr pXmlDoc = parseExport("Object 1/content.xml", "impress8");
@@ -371,7 +371,7 @@ void Chart2GeometryTest::testTdf128345Legend_CS_TG_axial_export()
{
// legend with solid color and transparency gradient
// Without the patch the transparency was lost.
- load("/chart2/qa/extras/data/odp/", "tdf128345_Legend_CS_TG_axial.odp");
+ load(u"/chart2/qa/extras/data/odp/", "tdf128345_Legend_CS_TG_axial.odp");
// Make sure the chart has a gradient with transparency in gradient stops in saved pptx file.
xmlDocUniquePtr pXmlDoc = parseExport("ppt/charts/chart", "Impress MS PowerPoint 2007 XML");
@@ -391,7 +391,7 @@ void Chart2GeometryTest::testTdf128345Legend_CS_TG_axial_import()
{
// This works on the file, which was exported from file tdf128345_Legend_CS_TG_axial.odp to pptx.
// Error was, that in case of axial not the middle value was taken but start and end value.
- load("/chart2/qa/extras/data/pptx/", "tdf128345_Legend_CS_TG_axial.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf128345_Legend_CS_TG_axial.pptx");
// Find transparency gradient name
xmlDocUniquePtr pXmlDoc = parseExport("Object 1/content.xml", "impress8");
@@ -422,7 +422,7 @@ void Chart2GeometryTest::testTdf135366LabelOnSeries()
{
// Error was, that the fill and line properties of a <chart:data-label> were not
// imported at all. Here they should be at the series.
- load("/chart2/qa/extras/data/ods/", "tdf135366_data_label_series.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf135366_data_label_series.ods");
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
Reference<chart2::XDataSeries> xDataSeries = getDataSeriesFromDoc(xChartDoc, 0);
@@ -460,7 +460,7 @@ void Chart2GeometryTest::testTdf135366LabelOnPoint()
{
// Error was, that the fill and line properties of a <chart:data-label> were not
// imported at all. Here they should be at point 2.
- load("/chart2/qa/extras/data/odt/", "tdf135366_data_label_point.odt");
+ load(u"/chart2/qa/extras/data/odt/", "tdf135366_data_label_point.odt");
uno::Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
Reference<chart2::XDataSeries> xDataSeries = getDataSeriesFromDoc(xChartDoc, 0);
@@ -507,7 +507,7 @@ void Chart2GeometryTest::testTdf135366LabelExport()
// Error was, that line and fill properties were not exported as
// graphic-properties of a <chart:data-label> element, but only
// as loext chart-properties of the <chart:data-point> element.
- load("/chart2/qa/extras/data/odt/", "tdf135366_data_label_export.odt");
+ load(u"/chart2/qa/extras/data/odt/", "tdf135366_data_label_export.odt");
xmlDocUniquePtr pXmlDoc = parseExport("Object 1/content.xml", "writer8");
CPPUNIT_ASSERT(pXmlDoc);
@@ -535,7 +535,7 @@ void Chart2GeometryTest::testTdf135366_CustomLabelText()
SvtSaveOptions aSaveOpt;
const SvtSaveOptions::ODFDefaultVersion nCurrentODFVersion(aSaveOpt.GetODFDefaultVersion());
aSaveOpt.SetODFDefaultVersion(SvtSaveOptions::ODFVER_012);
- load("/chart2/qa/extras/data/pptx/", "tdf135366_CustomLabelText.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf135366_CustomLabelText.pptx");
xmlDocUniquePtr pXmlDoc = parseExport("Object 1/content.xml", "impress8");
CPPUNIT_ASSERT(pXmlDoc);
diff --git a/chart2/qa/extras/chart2import.cxx b/chart2/qa/extras/chart2import.cxx
index 943cbd57ea99..272639ad069c 100644
--- a/chart2/qa/extras/chart2import.cxx
+++ b/chart2/qa/extras/chart2import.cxx
@@ -304,7 +304,7 @@ private:
// split method up into smaller chunks for more detailed tests
void Chart2ImportTest::Fdo60083()
{
- load("/chart2/qa/extras/data/ods/", "fdo60083.ods");
+ load(u"/chart2/qa/extras/data/ods/", "fdo60083.ods");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
CPPUNIT_ASSERT(xChartDoc.is());
@@ -353,7 +353,7 @@ void Chart2ImportTest::Fdo60083()
void Chart2ImportTest::testErrorBarRange()
{
- load("/chart2/qa/extras/data/ods/", "error_bar_range.ods");
+ load(u"/chart2/qa/extras/data/ods/", "error_bar_range.ods");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
CPPUNIT_ASSERT(xChartDoc.is());
@@ -382,7 +382,7 @@ void Chart2ImportTest::testErrorBarRange()
void Chart2ImportTest::testErrorBarFormatting()
{
- load("/chart2/qa/extras/data/ods/", "error_bar_properties.ods");
+ load(u"/chart2/qa/extras/data/ods/", "error_bar_properties.ods");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
CPPUNIT_ASSERT(xChartDoc.is());
@@ -423,7 +423,7 @@ void Chart2ImportTest::testSteppedLines()
chart2::CurveStyle_STEP_CENTER_Y
};
- load("/chart2/qa/extras/data/ods/", "stepped_lines.ods");
+ load(u"/chart2/qa/extras/data/ods/", "stepped_lines.ods");
for(sal_Int32 nSheet = 0; nSheet < MAXSHEET; ++nSheet)
{
uno::Reference< chart2::XChartDocument > xChart2Doc = getChartDocFromSheet( nSheet, mxComponent );
@@ -451,7 +451,7 @@ static uno::Sequence < OUString > getChartColumnDescriptions( uno::Reference< ch
void Chart2ImportTest::testODSChartSeries()
{
- load("/chart2/qa/extras/data/ods/", "chart.ods");
+ load(u"/chart2/qa/extras/data/ods/", "chart.ods");
uno::Reference< chart::XChartDocument > xChart1Doc ( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW);
uno::Sequence < OUString > seriesList = getChartColumnDescriptions( xChart1Doc);
CPPUNIT_ASSERT_EQUAL(OUString("Col 1"), seriesList[0]);
@@ -462,7 +462,7 @@ void Chart2ImportTest::testODSChartSeries()
void Chart2ImportTest::testXLSXChartSeries()
{
- load("/chart2/qa/extras/data/xlsx/", "chart.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "chart.xlsx");
uno::Reference< chart::XChartDocument > xChart1Doc ( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW);
uno::Sequence < OUString > seriesList = getChartColumnDescriptions(xChart1Doc );
CPPUNIT_ASSERT_EQUAL(OUString("Col 1"), seriesList[0]);
@@ -473,7 +473,7 @@ void Chart2ImportTest::testXLSXChartSeries()
void Chart2ImportTest::testXLSChartSeries()
{
- load("/chart2/qa/extras/data/xls/", "chart.xls");
+ load(u"/chart2/qa/extras/data/xls/", "chart.xls");
uno::Reference< chart::XChartDocument > xChart1Doc ( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW);
uno::Sequence < OUString > seriesList = getChartColumnDescriptions(xChart1Doc );
CPPUNIT_ASSERT_EQUAL(OUString("Col 1"), seriesList[0]);
@@ -484,7 +484,7 @@ void Chart2ImportTest::testXLSChartSeries()
void Chart2ImportTest::testODTChartSeries()
{
- load("/chart2/qa/extras/data/odt/", "chart.odt");
+ load(u"/chart2/qa/extras/data/odt/", "chart.odt");
uno::Sequence< OUString > seriesList = getWriterChartColumnDescriptions(mxComponent);
CPPUNIT_ASSERT_EQUAL(OUString("Column 1"), seriesList[0]);
CPPUNIT_ASSERT_EQUAL(OUString("Column 2"), seriesList[1]);
@@ -494,7 +494,7 @@ void Chart2ImportTest::testODTChartSeries()
void Chart2ImportTest::testDOCChartSeries()
{
- load("/chart2/qa/extras/data/doc/", "chart.doc");
+ load(u"/chart2/qa/extras/data/doc/", "chart.doc");
uno::Sequence< OUString > seriesList = getWriterChartColumnDescriptions(mxComponent);
CPPUNIT_ASSERT_EQUAL(OUString("Column 1"), seriesList[0]);
CPPUNIT_ASSERT_EQUAL(OUString("Column 2"), seriesList[1]);
@@ -503,7 +503,7 @@ void Chart2ImportTest::testDOCChartSeries()
void Chart2ImportTest::testDOCXChartSeries()
{
- load("/chart2/qa/extras/data/docx/", "chart.docx");
+ load(u"/chart2/qa/extras/data/docx/", "chart.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -519,7 +519,7 @@ void Chart2ImportTest::testDOCXChartSeries()
void Chart2ImportTest::testDOCXChartEmptySeries()
{
- load("/chart2/qa/extras/data/docx/", "tdf125337.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf125337.docx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -545,7 +545,7 @@ void Chart2ImportTest::testDOCXChartEmptySeries()
void Chart2ImportTest::testDOCXChartValuesSize()
{
- load( "/chart2/qa/extras/data/docx/", "bubblechart.docx" );
+ load( u"/chart2/qa/extras/data/docx/", "bubblechart.docx" );
Reference<chart2::XChartDocument> xChartDoc( getChartDocFromWriter(0), uno::UNO_QUERY );
CPPUNIT_ASSERT( xChartDoc.is() );
@@ -567,7 +567,7 @@ void Chart2ImportTest::testDOCXChartValuesSize()
void Chart2ImportTest::testPPTChartSeries()
{
//test chart series names for ppt
- uno::Sequence < OUString > seriesList = getImpressChartColumnDescriptions("/chart2/qa/extras/data/ppt/", "chart.ppt");
+ uno::Sequence < OUString > seriesList = getImpressChartColumnDescriptions(u"/chart2/qa/extras/data/ppt/", "chart.ppt");
CPPUNIT_ASSERT_EQUAL(OUString("Column 1"), seriesList[0]);
CPPUNIT_ASSERT_EQUAL(OUString("Column 2"), seriesList[1]);
@@ -578,7 +578,7 @@ void Chart2ImportTest::testPPTChartSeries()
void Chart2ImportTest::testPPTXChartSeries()
{
//test chart series names for pptx
- load("/chart2/qa/extras/data/pptx/", "chart.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "chart.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -595,7 +595,7 @@ void Chart2ImportTest::testPPTXChartSeries()
void Chart2ImportTest::testPPTXSparseChartSeries()
{
//test chart series sparse data for pptx
- load("/chart2/qa/extras/data/pptx/", "sparse-chart.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "sparse-chart.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -616,7 +616,7 @@ void Chart2ImportTest::testPPTXSparseChartSeries()
void Chart2ImportTest::testPPTXHiddenDataSeries()
{
- load("/chart2/qa/extras/data/pptx/", "stacked-bar-chart-hidden-series.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "stacked-bar-chart-hidden-series.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -655,7 +655,7 @@ void Chart2ImportTest::testPPTXHiddenDataSeries()
void Chart2ImportTest::testPPTXPercentageNumberFormats()
{
- load("/chart2/qa/extras/data/pptx/", "percentage-number-formats.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "percentage-number-formats.pptx");
// 1st chart
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
@@ -720,7 +720,7 @@ void Chart2ImportTest::testPPTXPercentageNumberFormats()
void Chart2ImportTest::testPieChartLabelsNumFormat()
{
- load("/chart2/qa/extras/data/xlsx/", "tdfPieNumFormat.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdfPieNumFormat.xlsx");
uno::Reference< chart::XChartDocument > xChartDoc(getChartCompFromSheet(0, mxComponent), UNO_QUERY_THROW);
CPPUNIT_ASSERT(xChartDoc.is());
// test data point labels format
@@ -732,7 +732,7 @@ void Chart2ImportTest::testPieChartLabelsNumFormat()
void Chart2ImportTest::testPPTXStackedNonStackedYAxis()
{
- load("/chart2/qa/extras/data/pptx/", "stacked-non-stacked-mix-y-axis.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "stacked-non-stacked-mix-y-axis.pptx");
// 1st chart is a normal stacked column.
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
@@ -792,7 +792,7 @@ void Chart2ImportTest::testPPTXStackedNonStackedYAxis()
void Chart2ImportTest::testODPChartSeries()
{
//test chart series names for odp
- uno::Sequence < OUString > seriesList = getImpressChartColumnDescriptions("/chart2/qa/extras/data/odp/", "chart.odp");
+ uno::Sequence < OUString > seriesList = getImpressChartColumnDescriptions(u"/chart2/qa/extras/data/odp/", "chart.odp");
CPPUNIT_ASSERT_EQUAL(OUString("Column 1"), seriesList[0]);
CPPUNIT_ASSERT_EQUAL(OUString("Column 2"), seriesList[1]);
CPPUNIT_ASSERT_EQUAL(OUString("Column 3"), seriesList[2]);
@@ -801,7 +801,7 @@ void Chart2ImportTest::testODPChartSeries()
void Chart2ImportTest::testBnc864396()
{
- uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromImpress("/chart2/qa/extras/data/pptx/", "bnc864396.pptx"), uno::UNO_QUERY_THROW);
+ uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromImpress(u"/chart2/qa/extras/data/pptx/", "bnc864396.pptx"), uno::UNO_QUERY_THROW);
CPPUNIT_ASSERT(xChartDoc->hasInternalDataProvider());
uno::Reference< chart2::XInternalDataProvider > xDataProvider( xChartDoc->getDataProvider(), uno::UNO_QUERY_THROW );
@@ -816,7 +816,7 @@ void Chart2ImportTest::testBnc864396()
void Chart2ImportTest::testBnc889755()
{
- load("/chart2/qa/extras/data/pptx/", "bnc889755.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "bnc889755.pptx");
uno::Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 6), uno::UNO_QUERY_THROW);
CPPUNIT_ASSERT(xChartDoc->hasInternalDataProvider());
@@ -844,7 +844,7 @@ void Chart2ImportTest::testBnc889755()
void Chart2ImportTest::testBnc882383()
{
- load("/chart2/qa/extras/data/pptx/", "bnc882383.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "bnc882383.pptx");
uno::Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY_THROW);
uno::Reference<chart2::XDataSeries> xDataSeries(getDataSeriesFromDoc(xChartDoc, 0));
CPPUNIT_ASSERT(xDataSeries.is());
@@ -857,7 +857,7 @@ void Chart2ImportTest::testBnc882383()
void Chart2ImportTest::testTransparancyGradientValue()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf128732.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf128732.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
uno::Reference<chart2::XDataSeries> xDataSeries(getDataSeriesFromDoc(xChartDoc, 0));
@@ -880,7 +880,7 @@ void Chart2ImportTest::testTransparancyGradientValue()
void Chart2ImportTest::testSimpleStrictXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "strict_chart.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "strict_chart.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
CPPUNIT_ASSERT(xChartDoc.is());
@@ -891,7 +891,7 @@ void Chart2ImportTest::testSimpleStrictXLSX()
void Chart2ImportTest::testDelayedCellImport()
{
- load("/chart2/qa/extras/data/xlsx/", "fdo70609.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "fdo70609.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
Reference< chart2::data::XDataSequence > xDataSeq =
getDataSequenceFromDocByRole(xChartDoc, u"values-x");
@@ -902,7 +902,7 @@ void Chart2ImportTest::testDelayedCellImport()
void Chart2ImportTest::testFlatODSStackedColumnChart()
{
- load("/chart2/qa/extras/data/fods/", "stacked-column-chart.fods");
+ load(u"/chart2/qa/extras/data/fods/", "stacked-column-chart.fods");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -919,7 +919,7 @@ void Chart2ImportTest::testFlatODSStackedColumnChart()
void Chart2ImportTest::testFdo78080()
{
- load("/chart2/qa/extras/data/xlsx/", "fdo78080.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "fdo78080.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -930,7 +930,7 @@ void Chart2ImportTest::testFdo78080()
void Chart2ImportTest::testTdf127811()
{
- load("/chart2/qa/extras/data/pptx/", "tdf127811.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf127811.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -949,7 +949,7 @@ void Chart2ImportTest::testTdf127811()
void Chart2ImportTest::testTdf86624()
{
- load("/chart2/qa/extras/data/ods/", "tdf86624.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf86624.ods");
uno::Reference< chart2::XChartDocument > xChart2Doc = getChartDocFromSheet(0, mxComponent);
uno::Reference< chart::XChartDocument > xChartDoc (xChart2Doc, uno::UNO_QUERY);
uno::Reference<drawing::XShape> xLegend = xChartDoc->getLegend();
@@ -960,7 +960,7 @@ void Chart2ImportTest::testTdf86624()
void Chart2ImportTest::testTdf105517()
{
- load("/chart2/qa/extras/data/pptx/", "tdf105517.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf105517.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -988,7 +988,7 @@ void Chart2ImportTest::testTdf105517()
void Chart2ImportTest::testTdf106217()
{
- load("/chart2/qa/extras/data/pptx/", "tdf106217.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf106217.pptx");
uno::Reference< chart::XChartDocument > xChartDoc = getChartDocFromDrawImpress(0, 0);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1011,7 +1011,7 @@ void Chart2ImportTest::testTdf106217()
void Chart2ImportTest::testTdf108021()
{
// Tdf108021 : To check TextBreak value is true.
- load("/chart2/qa/extras/data/ods/", "tdf108021.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf108021.ods");
uno::Reference< chart::XDiagram > mxDiagram;
uno::Reference< beans::XPropertySet > xAxisProp;
bool bTextBreak = false;
@@ -1029,7 +1029,7 @@ void Chart2ImportTest::testTdf108021()
void Chart2ImportTest::testTdf100084()
{
// The test file was created with IBM Cognos, make sure there is a diagram.
- load("/chart2/qa/extras/data/xlsx/", "tdf100084.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf100084.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
Reference<beans::XPropertySet> xDiagram(xChartDoc->getFirstDiagram(), UNO_QUERY);
@@ -1038,7 +1038,7 @@ void Chart2ImportTest::testTdf100084()
void Chart2ImportTest::testTdf124817()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf124817.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf124817.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1066,7 +1066,7 @@ void Chart2ImportTest::testTdf124817()
void Chart2ImportTest::testTdf126033()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf126033.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf126033.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1083,7 +1083,7 @@ void Chart2ImportTest::testTdf126033()
void Chart2ImportTest::testTransparentBackground(OUString const & filename)
{
- load("/chart2/qa/extras/data/xlsx/", filename);
+ load(u"/chart2/qa/extras/data/xlsx/", filename);
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1110,7 +1110,7 @@ void Chart2ImportTest::testFdo54361_1()
void Chart2ImportTest::testAutoBackgroundXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "chart-auto-background.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "chart-auto-background.xlsx");
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1127,7 +1127,7 @@ void Chart2ImportTest::testAutoBackgroundXLSX()
void Chart2ImportTest::testAutoChartAreaBorderPropXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "chart-area-style-border.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "chart-area-style-border.xlsx");
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1147,7 +1147,7 @@ void Chart2ImportTest::testAutoChartAreaBorderPropXLSX()
void Chart2ImportTest::testChartAreaStyleBackgroundXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "chart-area-style-background.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "chart-area-style-background.xlsx");
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1164,7 +1164,7 @@ void Chart2ImportTest::testChartAreaStyleBackgroundXLSX()
void Chart2ImportTest::testChartHatchFillXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "chart-hatch-fill.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "chart-hatch-fill.xlsx");
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1206,7 +1206,7 @@ void Chart2ImportTest::testChartHatchFillXLSX()
void Chart2ImportTest::testAxisTextRotationXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "axis-label-rotation.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "axis-label-rotation.xlsx");
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1244,7 +1244,7 @@ void Chart2ImportTest::testTextCanOverlapXLSX()
void Chart2ImportTest::testTextBreakXLSX()
{
// tdf#122091: To check textbreak value is true in case of 0° degree of Axis label rotation.
- load("/chart2/qa/extras/data/xlsx/", "chart_label_text_break.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "chart_label_text_break.xlsx");
uno::Reference< chart::XDiagram > mxDiagram;
uno::Reference< beans::XPropertySet > xAxisProp;
bool textBreak = false;
@@ -1262,7 +1262,7 @@ void Chart2ImportTest::testTextBreakXLSX()
void Chart2ImportTest::testNumberFormatsXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "number-formats.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "number-formats.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1311,7 +1311,7 @@ void Chart2ImportTest::testNumberFormatsXLSX()
void Chart2ImportTest::testNumberFormatsDOCX()
{
- load("/chart2/qa/extras/data/docx/", "tdf132174.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf132174.docx");
{
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1332,7 +1332,7 @@ void Chart2ImportTest::testNumberFormatsDOCX()
CPPUNIT_ASSERT_MESSAGE("\"LinkNumberFormatToSource\" should be set to false.", !bLinkNumberFormatToSource);
}
- load("/chart2/qa/extras/data/docx/", "tdf136650.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf136650.docx");
{
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1356,7 +1356,7 @@ void Chart2ImportTest::testNumberFormatsDOCX()
void Chart2ImportTest::testPercentageNumberFormatsDOCX()
{
- load("/chart2/qa/extras/data/docx/", "tdf133632.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf133632.docx");
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1376,7 +1376,7 @@ void Chart2ImportTest::testPercentageNumberFormatsDOCX()
void Chart2ImportTest::testAutoTitleDelDefaultValue2007XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "autotitledel_2007.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "autotitledel_2007.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1388,7 +1388,7 @@ void Chart2ImportTest::testAutoTitleDelDefaultValue2007XLSX()
void Chart2ImportTest::testAutoTitleDelDefaultValue2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "autotitledel_2013.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "autotitledel_2013.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1400,7 +1400,7 @@ void Chart2ImportTest::testAutoTitleDelDefaultValue2013XLSX()
void Chart2ImportTest::testDispBlanksAsDefaultValue2007XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "dispBlanksAs_2007.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "dispBlanksAs_2007.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1414,7 +1414,7 @@ void Chart2ImportTest::testDispBlanksAsDefaultValue2007XLSX()
void Chart2ImportTest::testDispBlanksAsDefaultValue2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "dispBlanksAs_2013.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "dispBlanksAs_2013.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -1428,7 +1428,7 @@ void Chart2ImportTest::testDispBlanksAsDefaultValue2013XLSX()
void Chart2ImportTest::testSmoothDefaultValue2007XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "smoothed_series2007.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "smoothed_series2007.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1446,7 +1446,7 @@ void Chart2ImportTest::testSmoothDefaultValue2007XLSX()
void Chart2ImportTest::testSmoothDefaultValue2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "smoothed_series.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "smoothed_series.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1464,7 +1464,7 @@ void Chart2ImportTest::testSmoothDefaultValue2013XLSX()
void Chart2ImportTest::testTrendlineDefaultValue2007XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "trendline2007.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "trendline2007.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1490,7 +1490,7 @@ void Chart2ImportTest::testTrendlineDefaultValue2007XLSX()
void Chart2ImportTest::testTrendlineDefaultValue2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "trendline.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "trendline.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1516,7 +1516,7 @@ void Chart2ImportTest::testTrendlineDefaultValue2013XLSX()
void Chart2ImportTest::testVaryColorDefaultValues2007XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "vary_color2007.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "vary_color2007.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1531,7 +1531,7 @@ void Chart2ImportTest::testVaryColorDefaultValues2007XLSX()
void Chart2ImportTest::testVaryColorDefaultValues2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "vary_color.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "vary_color.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1546,7 +1546,7 @@ void Chart2ImportTest::testVaryColorDefaultValues2013XLSX()
void Chart2ImportTest::testPlotVisOnlyDefaultValue2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "plotVisOnly.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "plotVisOnly.xlsx");
uno::Reference< chart::XChartDocument > xChart1Doc ( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW);
Reference<beans::XPropertySet> xPropSet(xChart1Doc->getDiagram(), uno::UNO_QUERY_THROW);
uno::Any aAny = xPropSet->getPropertyValue("IncludeHiddenCells");
@@ -1558,7 +1558,7 @@ void Chart2ImportTest::testPlotVisOnlyDefaultValue2013XLSX()
void Chart2ImportTest::testRAngAxDefaultValue2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "rAngAx.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "rAngAx.xlsx");
uno::Reference< chart::XChartDocument > xChart1Doc ( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW);
Reference<beans::XPropertySet> xPropSet(xChart1Doc->getDiagram(), uno::UNO_QUERY_THROW);
uno::Any aAny = xPropSet->getPropertyValue("RightAngledAxes");
@@ -1570,7 +1570,7 @@ void Chart2ImportTest::testRAngAxDefaultValue2013XLSX()
void Chart2ImportTest::testMajorTickMarksDefaultValue2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "majorTickMark.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "majorTickMark.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
Reference<chart2::XAxis> xXAxis = getAxisFromDoc(xChartDoc, 0, 0, 0);
@@ -1585,7 +1585,7 @@ void Chart2ImportTest::testMajorTickMarksDefaultValue2013XLSX()
void Chart2ImportTest::testMinorTickMarksDefaultValue2013XLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "minorTickMark.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "minorTickMark.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
Reference<chart2::XAxis> xXAxis = getAxisFromDoc(xChartDoc, 0, 0, 0);
@@ -1600,7 +1600,7 @@ void Chart2ImportTest::testMinorTickMarksDefaultValue2013XLSX()
void Chart2ImportTest::testAxisTitleDefaultRotationXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "axis_title_default_rotation.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "axis_title_default_rotation.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
Reference<chart2::XAxis> xYAxis = getAxisFromDoc(xChartDoc, 0, 1, 0);
@@ -1617,7 +1617,7 @@ void Chart2ImportTest::testAxisTitleDefaultRotationXLSX()
void Chart2ImportTest::testSecondaryAxisTitleDefaultRotationXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "secondary_axis_title_default_rotation.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "secondary_axis_title_default_rotation.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
Reference<chart2::XAxis> xYAxis = getAxisFromDoc(xChartDoc, 0, 1, 1);
@@ -1634,7 +1634,7 @@ void Chart2ImportTest::testSecondaryAxisTitleDefaultRotationXLSX()
void Chart2ImportTest::testAxisTitleRotationXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "axis_title_rotated.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "axis_title_rotated.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
{
@@ -1666,7 +1666,7 @@ void Chart2ImportTest::testAxisTitleRotationXLSX()
void Chart2ImportTest::testAxisTitlePositionDOCX()
{
- load("/chart2/qa/extras/data/docx/", "testAxisTitlePosition.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testAxisTitlePosition.docx");
uno::Reference< chart::XDiagram > mxDiagram;
uno::Reference< drawing::XShape > xAxisTitle;
uno::Reference< chart::XChartDocument > xChartDoc = getChartDocFromWriter(0);
@@ -1698,7 +1698,7 @@ void Chart2ImportTest::testAxisTitlePositionDOCX()
void Chart2ImportTest::testCombinedChartAttachedAxisXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "testCombinedChartAxis.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testCombinedChartAxis.xlsx");
Reference< chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
// First series
Reference<chart2::XDataSeries> xSeries = getDataSeriesFromDoc(xChartDoc, 0);
@@ -1723,7 +1723,7 @@ void Chart2ImportTest::testCombinedChartAttachedAxisXLSX()
}
void Chart2ImportTest::testInternalDataProvider() {
- uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromImpress("/chart2/qa/extras/data/odp/", "chart.odp"), uno::UNO_QUERY_THROW);
+ uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromImpress(u"/chart2/qa/extras/data/odp/", "chart.odp"), uno::UNO_QUERY_THROW);
const uno::Reference< chart2::data::XDataProvider >& rxDataProvider = xChartDoc->getDataProvider();
// Parse 42 array
@@ -1769,7 +1769,7 @@ void Chart2ImportTest::testInternalDataProvider() {
void Chart2ImportTest::testTdf90510()
{
- load("/chart2/qa/extras/data/xls/", "piechart_outside.xls");
+ load(u"/chart2/qa/extras/data/xls/", "piechart_outside.xls");
uno::Reference< chart::XChartDocument > xChart1Doc( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW );
Reference<beans::XPropertySet> xPropSet( xChart1Doc->getDiagram()->getDataPointProperties( 0, 0 ), uno::UNO_SET_THROW );
uno::Any aAny = xPropSet->getPropertyValue( "LabelPlacement" );
@@ -1781,7 +1781,7 @@ void Chart2ImportTest::testTdf90510()
void Chart2ImportTest::testTdf109858()
{
- load("/chart2/qa/extras/data/xlsx/", "piechart_outside.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "piechart_outside.xlsx");
uno::Reference< chart::XChartDocument > xChart1Doc( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW );
// test data point labels position
@@ -1801,7 +1801,7 @@ void Chart2ImportTest::testTdf109858()
void Chart2ImportTest::testTdf130105()
{
- load("/chart2/qa/extras/data/xlsx/", "barchart_outend.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "barchart_outend.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
uno::Reference<chart2::XDataSeries> xDataSeries(getDataSeriesFromDoc(xChartDoc, 0));
@@ -1817,13 +1817,13 @@ void Chart2ImportTest::testTdf130105()
void Chart2ImportTest::testTdf111173()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf111173.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf111173.xlsx");
uno::Reference< chart::XChartDocument > xChart1Doc( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW );
}
void Chart2ImportTest::testTdf122226()
{
- load( "/chart2/qa/extras/data/docx/", "testTdf122226.docx" );
+ load( u"/chart2/qa/extras/data/docx/", "testTdf122226.docx" );
uno::Reference< chart2::XChartDocument > xChartDoc ( getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT( xChartDoc.is() );
@@ -1841,7 +1841,7 @@ void Chart2ImportTest::testTdf122226()
void Chart2ImportTest::testTdf115107()
{
- load("/chart2/qa/extras/data/pptx/", "tdf115107.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf115107.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1932,7 +1932,7 @@ void Chart2ImportTest::testTdf115107()
void Chart2ImportTest::testTdf115107_2()
{
- load("/chart2/qa/extras/data/pptx/", "tdf115107-2.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf115107-2.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -1987,7 +1987,7 @@ void Chart2ImportTest::testTdf115107_2()
void Chart2ImportTest::testTdf116163()
{
- load("/chart2/qa/extras/data/pptx/", "tdf116163.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf116163.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2052,7 +2052,7 @@ void Chart2ImportTest::testTdf116163()
void Chart2ImportTest::testTdf48041()
{
- load("/chart2/qa/extras/data/pptx/", "tdf48041.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf48041.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2102,7 +2102,7 @@ void Chart2ImportTest::testTdf48041()
void Chart2ImportTest::testTdf121205()
{
- load("/chart2/qa/extras/data/pptx/", "tdf121205.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf121205.pptx");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
uno::Reference<chart2::XTitled> xTitled(xChartDoc, uno::UNO_QUERY_THROW);
@@ -2115,7 +2115,7 @@ void Chart2ImportTest::testTdf121205()
void Chart2ImportTest::testTdf114179()
{
- load( "/chart2/qa/extras/data/docx/", "testTdf114179.docx" );
+ load( u"/chart2/qa/extras/data/docx/", "testTdf114179.docx" );
uno::Reference< chart2::XChartDocument > xChartDoc ( getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT( xChartDoc.is() );
css::uno::Reference<chart2::XDiagram> xDiagram;
@@ -2129,7 +2129,7 @@ void Chart2ImportTest::testTdf114179()
void Chart2ImportTest::testTdf124243()
{
- load("/chart2/qa/extras/data/docx/", "tdf124243.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf124243.docx");
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -2146,7 +2146,7 @@ void Chart2ImportTest::testTdf124243()
void Chart2ImportTest::testTdf127393()
{
- load("/chart2/qa/extras/data/pptx/", "tdf127393.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf127393.pptx");
// 1st chart
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
@@ -2173,7 +2173,7 @@ void Chart2ImportTest::testTdf127393()
void Chart2ImportTest::testTdf128733()
{
- load("/chart2/qa/extras/data/odt/", "tdf128733.odt");
+ load(u"/chart2/qa/extras/data/odt/", "tdf128733.odt");
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2188,7 +2188,7 @@ void Chart2ImportTest::testTdf128733()
void Chart2ImportTest::testTdf128432()
{
- load("/chart2/qa/extras/data/ods/", "tdf128432.ods");
+ load(u"/chart2/qa/extras/data/ods/", "tdf128432.ods");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2203,7 +2203,7 @@ void Chart2ImportTest::testTdf128432()
void Chart2ImportTest::testTdf128627()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf128627.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf128627.xlsx");
// Test ShiftedCategoryPosition for Radar Chart
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -2218,7 +2218,7 @@ void Chart2ImportTest::testTdf128627()
void Chart2ImportTest::testTdf128634()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf128634.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf128634.xlsx");
// Test ShiftedCategoryPosition for 3D Charts
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -2233,7 +2233,7 @@ void Chart2ImportTest::testTdf128634()
void Chart2ImportTest::testTdf130657()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf130657.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf130657.xlsx");
// Test ShiftedCategoryPosition for charts which is not contain a "crossbetween" OOXML tag.
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -2261,7 +2261,7 @@ void checkDataLabelProperties(const Reference<chart2::XDataSeries>& xDataSeries,
void Chart2ImportTest::testDeletedDataLabel()
{
- load("/chart2/qa/extras/data/xlsx/", "deleted_data_labels.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "deleted_data_labels.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW );
Reference<chart2::XDataSeries> xDataSeries0 = getDataSeriesFromDoc(xChartDoc, 0);
CPPUNIT_ASSERT(xDataSeries0.is());
@@ -2277,7 +2277,7 @@ void Chart2ImportTest::testDeletedDataLabel()
void Chart2ImportTest::testDataPointInheritedColorDOCX()
{
- load( "/chart2/qa/extras/data/docx/", "data_point_inherited_color.docx" );
+ load( u"/chart2/qa/extras/data/docx/", "data_point_inherited_color.docx" );
uno::Reference< chart2::XChartDocument > xChartDoc ( getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT( xChartDoc.is() );
css::uno::Reference<chart2::XDiagram> xDiagram(xChartDoc->getFirstDiagram(), UNO_SET_THROW);
@@ -2291,7 +2291,7 @@ void Chart2ImportTest::testDataPointInheritedColorDOCX()
void Chart2ImportTest::testExternalStrRefsXLSX()
{
- load("/chart2/qa/extras/data/xlsx/", "external_str_ref.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "external_str_ref.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW );
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2304,7 +2304,7 @@ void Chart2ImportTest::testExternalStrRefsXLSX()
void Chart2ImportTest::testSourceNumberFormatComplexCategoriesXLS()
{
- load("/chart2/qa/extras/data/xls/", "source_number_format_axis.xls");
+ load(u"/chart2/qa/extras/data/xls/", "source_number_format_axis.xls");
uno::Reference< chart2::XChartDocument > xChartDoc( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW );
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2316,7 +2316,7 @@ void Chart2ImportTest::testSourceNumberFormatComplexCategoriesXLS()
void Chart2ImportTest::testSimpleCategoryAxis()
{
- load("/chart2/qa/extras/data/docx/", "testSimpleCategoryAxis.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testSimpleCategoryAxis.docx");
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2343,7 +2343,7 @@ void Chart2ImportTest::testSimpleCategoryAxis()
void Chart2ImportTest::testMultilevelCategoryAxis()
{
- load("/chart2/qa/extras/data/docx/", "testMultilevelCategoryAxis.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testMultilevelCategoryAxis.docx");
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2371,7 +2371,7 @@ void Chart2ImportTest::testMultilevelCategoryAxis()
void Chart2ImportTest::testXaxisValues()
{
- load("/chart2/qa/extras/data/docx/", "tdf124083.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf124083.docx");
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2387,7 +2387,7 @@ void Chart2ImportTest::testXaxisValues()
void Chart2ImportTest::testTdf123504()
{
- load("/chart2/qa/extras/data/ods/", "pie_chart_100_and_0.ods");
+ load(u"/chart2/qa/extras/data/ods/", "pie_chart_100_and_0.ods");
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
UNO_QUERY_THROW);
@@ -2419,7 +2419,7 @@ void Chart2ImportTest::testTdf123504()
void Chart2ImportTest::testTdf122765()
{
// The horizontal position of the slices was wrong.
- load("/chart2/qa/extras/data/pptx/", "tdf122765.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf122765.pptx");
Reference<chart::XChartDocument> xChartDoc = getChartDocFromDrawImpress(0, 0);
Reference<drawing::XDrawPageSupplier> xDrawPageSupplier(xChartDoc, UNO_QUERY_THROW);
Reference<drawing::XDrawPage> xDrawPage(xDrawPageSupplier->getDrawPage(), UNO_SET_THROW);
@@ -2442,7 +2442,7 @@ void Chart2ImportTest::testTdf123206CustomLabelField()
// File contains the deprecated "custom-label-field" attribute of the
// "data-point" element. It should be interpreted and stored as a data point
// property.
- uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromImpress("/chart2/qa/extras/data/odp/", "tdf123206.odp"), uno::UNO_QUERY_THROW);
+ uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromImpress(u"/chart2/qa/extras/data/odp/", "tdf123206.odp"), uno::UNO_QUERY_THROW);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
CPPUNIT_ASSERT(xChartDoc.is());
Reference<chart2::XDataSeries> xDataSeries = getDataSeriesFromDoc(xChartDoc, 0);
@@ -2457,7 +2457,7 @@ void Chart2ImportTest::testTdf123206CustomLabelField()
void Chart2ImportTest::testTdf125444PercentageCustomLabel()
{
- load("/chart2/qa/extras/data/pptx/", "tdf125444.pptx");
+ load(u"/chart2/qa/extras/data/pptx/", "tdf125444.pptx");
// 1st chart
Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY);
@@ -2477,7 +2477,7 @@ void Chart2ImportTest::testTdf125444PercentageCustomLabel()
void Chart2ImportTest::testDataPointLabelCustomPos()
{
// test CustomLabelPosition on Bar chart
- load("/chart2/qa/extras/data/xlsx/", "testDataPointLabelCustomPos.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testDataPointLabelCustomPos.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
uno::Reference<chart2::XDataSeries> xDataSeries(getDataSeriesFromDoc(xChartDoc, 0));
@@ -2499,7 +2499,7 @@ void Chart2ImportTest::testDataPointLabelCustomPos()
void Chart2ImportTest::testTdf130032()
{
// test CustomLabelPosition on Line chart
- load("/chart2/qa/extras/data/xlsx/", "testTdf130032.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "testTdf130032.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
uno::Reference<chart2::XDataSeries> xDataSeries(getDataSeriesFromDoc(xChartDoc, 0));
@@ -2521,7 +2521,7 @@ void Chart2ImportTest::testTdf130032()
void Chart2ImportTest::testTdf134978()
{
// test CustomLabelPosition on Pie chart
- load("/chart2/qa/extras/data/xlsx/", "tdf134978.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf134978.xlsx");
uno::Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT(xChartDoc.is());
uno::Reference<chart2::XDataSeries> xDataSeries(getDataSeriesFromDoc(xChartDoc, 0));
@@ -2539,7 +2539,7 @@ void Chart2ImportTest::testTdf134978()
void Chart2ImportTest::testTdf119138MissingAutoTitleDeleted()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf119138-missing-autotitledeleted.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf119138-missing-autotitledeleted.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
@@ -2550,7 +2550,7 @@ void Chart2ImportTest::testTdf119138MissingAutoTitleDeleted()
void Chart2ImportTest::testStockChartShiftedCategoryPosition()
{
- load("/chart2/qa/extras/data/odt/", "stock_chart_LO_6_2.odt");
+ load(u"/chart2/qa/extras/data/odt/", "stock_chart_LO_6_2.odt");
uno::Reference<chart2::XChartDocument> xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2570,7 +2570,7 @@ void Chart2ImportTest::testTdf133376()
if (!IsDefaultDPI())
return;
- load("/chart2/qa/extras/data/xlsx/", "tdf133376.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf133376.xlsx");
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
UNO_QUERY_THROW);
@@ -2589,7 +2589,7 @@ void Chart2ImportTest::testTdf133376()
void Chart2ImportTest::testTdf134225()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf134225.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf134225.xlsx");
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
UNO_QUERY_THROW);
@@ -2622,7 +2622,7 @@ void Chart2ImportTest::testTdf136105()
if (!IsDefaultDPI())
return;
- load("/chart2/qa/extras/data/xlsx/", "tdf136105.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf136105.xlsx");
// 1st chart with fix inner position and size
{
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
@@ -2661,7 +2661,7 @@ void Chart2ImportTest::testTdf136105()
void Chart2ImportTest::testTdf91250()
{
- load("/chart2/qa/extras/data/docx/", "tdf91250.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf91250.docx");
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
Reference<chart2::XInternalDataProvider> xInternalProvider(xChartDoc->getDataProvider(), uno::UNO_QUERY);
@@ -2682,7 +2682,7 @@ void Chart2ImportTest::testTdf91250()
void Chart2ImportTest::testTdf134111()
{
// tdf134111 : To check TextBreak value is true
- load("/chart2/qa/extras/data/docx/", "tdf134111.docx");
+ load(u"/chart2/qa/extras/data/docx/", "tdf134111.docx");
uno::Reference< chart::XChartDocument > xChartDoc = getChartDocFromWriter(0);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
uno::Reference< chart::XDiagram > mxDiagram(xChartDoc->getDiagram());
@@ -2698,7 +2698,7 @@ void Chart2ImportTest::testTdf134111()
void Chart2ImportTest::testTdf136752()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf136752.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf136752.xlsx");
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
UNO_QUERY_THROW);
@@ -2717,7 +2717,7 @@ void Chart2ImportTest::testTdf136752()
void Chart2ImportTest::testTdf137505()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf137505.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf137505.xlsx");
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
UNO_QUERY_THROW);
@@ -2737,7 +2737,7 @@ void Chart2ImportTest::testTdf137505()
void Chart2ImportTest::testTdf137734()
{
- load("/chart2/qa/extras/data/xlsx/", "tdf137734.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "tdf137734.xlsx");
Reference<chart2::XChartDocument> xChartDoc = getChartDocFromSheet(0, mxComponent);
CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
CPPUNIT_ASSERT(xChartDoc.is());
@@ -2764,7 +2764,7 @@ void Chart2ImportTest::testTdf137734()
void Chart2ImportTest::testTdf137874()
{
- load("/chart2/qa/extras/data/xlsx/", "piechart_legend.xlsx");
+ load(u"/chart2/qa/extras/data/xlsx/", "piechart_legend.xlsx");
Reference<chart::XChartDocument> xChartDoc(getChartDocFromSheet(0, mxComponent),
UNO_QUERY_THROW);
Reference<drawing::XDrawPageSupplier> xDrawPageSupplier(xChartDoc, UNO_QUERY_THROW);
@@ -2778,7 +2778,7 @@ void Chart2ImportTest::testTdf137874()
void Chart2ImportTest::testTdfCustomShapePos()
{
- load("/chart2/qa/extras/data/docx/", "testcustomshapepos.docx");
+ load(u"/chart2/qa/extras/data/docx/", "testcustomshapepos.docx");
Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), UNO_QUERY_THROW);
Reference<drawing::XDrawPageSupplier> xDrawPageSupplier(xChartDoc, UNO_QUERY_THROW);
Reference<drawing::XDrawPage> xDrawPage(xDrawPageSupplier->getDrawPage(), UNO_SET_THROW);
diff --git a/chart2/qa/extras/charttest.hxx b/chart2/qa/extras/charttest.hxx
index b696231a6c54..eeebd0ea237a 100644
--- a/chart2/qa/extras/charttest.hxx
+++ b/chart2/qa/extras/charttest.hxx
@@ -54,6 +54,7 @@
#include <iostream>
#include <memory>
+#include <string_view>
#include <com/sun/star/embed/Aspects.hpp>
#include <com/sun/star/embed/XVisualObject.hpp>
@@ -71,13 +72,13 @@ class ChartTest : public test::BootstrapFixture, public unotest::MacrosTest
{
public:
ChartTest():mbSkipValidation(false) {}
- void load( const OUString& rDir, const OUString& rFileName );
+ void load( std::u16string_view rDir, const OUString& rFileName );
std::shared_ptr<utl::TempFile> save( const OUString& rFileName );
std::shared_ptr<utl::TempFile> reload( const OUString& rFileName );
- uno::Sequence < OUString > getImpressChartColumnDescriptions( const OUString& pDir, const char* pName );
+ uno::Sequence < OUString > getImpressChartColumnDescriptions( std::u16string_view pDir, const char* pName );
OUString getFileExtension( const OUString& rFileName );
- uno::Reference< chart::XChartDocument > getChartDocFromImpress( const OUString& pDir, const char* pName );
+ uno::Reference< chart::XChartDocument > getChartDocFromImpress( std::u16string_view pDir, const char* pName );
uno::Reference<chart::XChartDocument> getChartDocFromDrawImpress( sal_Int32 nPage, sal_Int32 nShape );
@@ -101,7 +102,7 @@ OUString ChartTest::getFileExtension( const OUString& aFileName )
return aFileName.copy(nDotLocation+1); // Skip the dot.
}
-void ChartTest::load( const OUString& aDir, const OUString& aName )
+void ChartTest::load( std::u16string_view aDir, const OUString& aName )
{
OUString extension = getFileExtension(aName);
if (extension == "ods" || extension == "xlsx" || extension == "fods")
@@ -476,7 +477,7 @@ std::vector<uno::Sequence<uno::Any> > getDataSeriesLabelsFromChartType( const Re
return aRet;
}
-uno::Reference< chart::XChartDocument > ChartTest::getChartDocFromImpress( const OUString& pDir, const char* pName )
+uno::Reference< chart::XChartDocument > ChartTest::getChartDocFromImpress( std::u16string_view pDir, const char* pName )
{
mxComponent = loadFromDesktop(m_directories.getURLFromSrc(pDir) + OUString::createFromAscii(pName), "com.sun.star.comp.Draw.PresentationDocument");
uno::Reference< drawing::XDrawPagesSupplier > xDoc(mxComponent, uno::UNO_QUERY_THROW );
@@ -538,7 +539,7 @@ uno::Reference<chart::XChartDocument> ChartTest::getChartDocFromWriter( sal_Int3
return xChartDoc;
}
-uno::Sequence < OUString > ChartTest::getImpressChartColumnDescriptions( const OUString& pDir, const char* pName )
+uno::Sequence < OUString > ChartTest::getImpressChartColumnDescriptions( std::u16string_view pDir, const char* pName )
{
uno::Reference< chart::XChartDocument > xChartDoc = getChartDocFromImpress( pDir, pName );
uno::Reference< chart::XChartDataArray > xChartData ( xChartDoc->getData(), uno::UNO_QUERY_THROW);
diff --git a/chart2/qa/extras/xshape/chart2xshape.cxx b/chart2/qa/extras/xshape/chart2xshape.cxx
index 3acb981cb78d..70b9a80770b4 100644
--- a/chart2/qa/extras/xshape/chart2xshape.cxx
+++ b/chart2/qa/extras/xshape/chart2xshape.cxx
@@ -43,7 +43,7 @@ public:
CPPUNIT_TEST_SUITE_END();
private:
- void compareAgainstReference(const OUString& rReferenceFile, bool bCreateReference = false);
+ void compareAgainstReference(std::u16string_view rReferenceFile, bool bCreateReference = false);
OUString getXShapeDumpString();
xmlDocUniquePtr getXShapeDumpXmlDoc();
};
@@ -76,13 +76,13 @@ xmlDocUniquePtr Chart2XShapeTest::getXShapeDumpXmlDoc()
return xmlDocUniquePtr(xmlParseDoc(reinterpret_cast<const xmlChar*>(aXmlDump.getStr())));
}
-void Chart2XShapeTest::compareAgainstReference(const OUString& rReferenceFile,
+void Chart2XShapeTest::compareAgainstReference(std::u16string_view rReferenceFile,
bool bCreateReference)
{
OUString aDump = getXShapeDumpString();
- OUString aReference
- = m_directories.getPathFromSrc("/chart2/qa/extras/xshape/data/reference/") + rReferenceFile;
+ OUString aReference = m_directories.getPathFromSrc(u"/chart2/qa/extras/xshape/data/reference/")
+ + rReferenceFile;
if (bCreateReference)
{
OString aOFile = OUStringToOString(aReference, RTL_TEXTENCODING_UTF8);
@@ -120,8 +120,8 @@ void Chart2XShapeTest::testPieChartLabels1()
return;
// inside placement for the best fit case
- load("chart2/qa/extras/xshape/data/xlsx/", "tdf90839-1.xlsx");
- compareAgainstReference("tdf90839-1.xml");
+ load(u"chart2/qa/extras/xshape/data/xlsx/", "tdf90839-1.xlsx");
+ compareAgainstReference(u"tdf90839-1.xml");
}
void Chart2XShapeTest::testPieChartLabels2()
@@ -132,8 +132,8 @@ void Chart2XShapeTest::testPieChartLabels2()
return;
// text wrap: wrap all text labels except one
- load("chart2/qa/extras/xshape/data/xlsx/", "tdf90839-2.xlsx");
- compareAgainstReference("tdf90839-2.xml");
+ load(u"chart2/qa/extras/xshape/data/xlsx/", "tdf90839-2.xlsx");
+ compareAgainstReference(u"tdf90839-2.xml");
}
void Chart2XShapeTest::testPieChartLabels3()
@@ -144,8 +144,8 @@ void Chart2XShapeTest::testPieChartLabels3()
return;
// text wrap: wrap no text label except one
- load("chart2/qa/extras/xshape/data/xlsx/", "tdf90839-3.xlsx");
- compareAgainstReference("tdf90839-3.xml");
+ load(u"chart2/qa/extras/xshape/data/xlsx/", "tdf90839-3.xlsx");
+ compareAgainstReference(u"tdf90839-3.xml");
}
void Chart2XShapeTest::testPieChartLabels4()
@@ -156,8 +156,8 @@ void Chart2XShapeTest::testPieChartLabels4()
return;
// data value and percent value are centered horizontally
- load("chart2/qa/extras/xshape/data/ods/", "tdf90839-4.ods");
- compareAgainstReference("tdf90839-4.xml");
+ load(u"chart2/qa/extras/xshape/data/ods/", "tdf90839-4.ods");
+ compareAgainstReference(u"tdf90839-4.xml");
}
void Chart2XShapeTest::testTdf76649TrendLineBug()
@@ -165,7 +165,7 @@ void Chart2XShapeTest::testTdf76649TrendLineBug()
// This bug prevents that the trendline (regression curve) is drawn
// if the first cell is empty. See tdf#76649 for details.
- load("chart2/qa/extras/xshape/data/ods/", "tdf76649_TrendLineBug.ods");
+ load(u"chart2/qa/extras/xshape/data/ods/", "tdf76649_TrendLineBug.ods");
xmlDocUniquePtr pXmlDoc = getXShapeDumpXmlDoc();
@@ -176,7 +176,7 @@ void Chart2XShapeTest::testTdf76649TrendLineBug()
void Chart2XShapeTest::testTdf88154LabelRotatedLayout()
{
- load("chart2/qa/extras/xshape/data/pptx/", "tdf88154_LabelRotatedLayout.pptx");
+ load(u"chart2/qa/extras/xshape/data/pptx/", "tdf88154_LabelRotatedLayout.pptx");
uno::Reference<chart::XChartDocument> xChartDoc = getChartDocFromDrawImpress(0, 6);
uno::Reference<qa::XDumper> xDumper(xChartDoc, UNO_QUERY_THROW);
OUString rDump = xDumper->dump();
diff --git a/chart2/qa/unit/chart2-dialogs-test.cxx b/chart2/qa/unit/chart2-dialogs-test.cxx
index c37fb1e1bbe2..00bb9179dfdf 100644
--- a/chart2/qa/unit/chart2-dialogs-test.cxx
+++ b/chart2/qa/unit/chart2-dialogs-test.cxx
@@ -51,7 +51,7 @@ VclPtr<VclAbstractDialog> Chart2DialogsTest::createDialogByID(sal_uInt32 /*nID*/
void Chart2DialogsTest::openAnyDialog()
{
/// process input file containing the UXMLDescriptions of the dialogs to dump
- processDialogBatchFile("chart2/qa/unit/data/chart2-dialogs-test.txt");
+ processDialogBatchFile(u"chart2/qa/unit/data/chart2-dialogs-test.txt");
}
CPPUNIT_TEST_SUITE_REGISTRATION(Chart2DialogsTest);
diff --git a/chart2/source/inc/ObjectIdentifier.hxx b/chart2/source/inc/ObjectIdentifier.hxx
index 55f6f58bd343..6f534305359e 100644
--- a/chart2/source/inc/ObjectIdentifier.hxx
+++ b/chart2/source/inc/ObjectIdentifier.hxx
@@ -18,6 +18,10 @@
*/
#pragma once
+#include <sal/config.h>
+
+#include <string_view>
+
#include "TitleHelper.hxx"
#include "charttoolsdllapi.hxx"
@@ -177,7 +181,7 @@ public:
, const OUString& rSeriesParticle
, const OUString& rDragMethodServiceName = OUString()
, const OUString& rDragParameterString = OUString() );
- static OUString createPointCID( const OUString& rPointCID_Stub, sal_Int32 nIndex );
+ static OUString createPointCID( std::u16string_view rPointCID_Stub, sal_Int32 nIndex );
static OUString createDataCurveCID( const OUString& rSeriesParticle, sal_Int32 nCurveIndex, bool bAverageLine );
static OUString createDataCurveEquationCID( const OUString& rSeriesParticle, sal_Int32 nCurveIndex );
diff --git a/chart2/source/tools/ObjectIdentifier.cxx b/chart2/source/tools/ObjectIdentifier.cxx
index c2979f13f5b3..b5faa312d46b 100644
--- a/chart2/source/tools/ObjectIdentifier.cxx
+++ b/chart2/source/tools/ObjectIdentifier.cxx
@@ -1124,7 +1124,7 @@ OUString ObjectIdentifier::createSeriesSubObjectStub( ObjectType eSubObjectType
, rDragMethodServiceName, rDragParameterString );
}
-OUString ObjectIdentifier::createPointCID( const OUString& rPointCID_Stub, sal_Int32 nIndex )
+OUString ObjectIdentifier::createPointCID( std::u16string_view rPointCID_Stub, sal_Int32 nIndex )
{
return rPointCID_Stub + OUString::number( nIndex );
}
diff --git a/codemaker/source/codemaker/typemanager.cxx b/codemaker/source/codemaker/typemanager.cxx
index 12a00495ee56..194840ca9d5b 100644
--- a/codemaker/source/codemaker/typemanager.cxx
+++ b/codemaker/source/codemaker/typemanager.cxx
@@ -158,7 +158,7 @@ codemaker::UnoType::Sort TypeManager::getSort(
}
codemaker::UnoType::Sort TypeManager::decompose(
- OUString const & name, bool resolveTypedefs, OUString * nucleus,
+ std::u16string_view name, bool resolveTypedefs, OUString * nucleus,
sal_Int32 * rank, std::vector< OUString > * arguments,
rtl::Reference< unoidl::Entity > * entity) const
{
diff --git a/codemaker/source/commoncpp/commoncpp.cxx b/codemaker/source/commoncpp/commoncpp.cxx
index efe0dd0b48bf..c7dc2bdeb26c 100644
--- a/codemaker/source/commoncpp/commoncpp.cxx
+++ b/codemaker/source/commoncpp/commoncpp.cxx
@@ -87,7 +87,7 @@ OString translateUnoToCppType(
}
OString translateUnoToCppIdentifier(
- OString const & unoIdentifier, OString const & prefix,
+ OString const & unoIdentifier, std::string_view prefix,
IdentifierTranslationMode transmode, OString const * forbidden)
{
if (// Keywords:
@@ -287,7 +287,7 @@ OString translateUnoToCppIdentifier(
|| unoIdentifier == "NDEBUG"
|| (forbidden != nullptr && unoIdentifier == *forbidden) )
{
- return prefix + "_" + unoIdentifier;
+ return OString::Concat(prefix) + "_" + unoIdentifier;
} else {
return unoIdentifier;
}
diff --git a/codemaker/source/commonjava/commonjava.cxx b/codemaker/source/commonjava/commonjava.cxx
index d33969676ee6..0d01bee54048 100644
--- a/codemaker/source/commonjava/commonjava.cxx
+++ b/codemaker/source/commonjava/commonjava.cxx
@@ -71,7 +71,7 @@ OString translateUnoToJavaType(
}
OString translateUnoToJavaIdentifier(
- OString const & identifier, OString const & prefix)
+ OString const & identifier, std::string_view prefix)
{
if (identifier == "abstract"
|| identifier == "assert" // since Java 1.4
@@ -124,7 +124,7 @@ OString translateUnoToJavaIdentifier(
|| identifier == "volatile"
|| identifier == "while")
{
- return prefix + "_" + identifier;
+ return OString::Concat(prefix) + "_" + identifier;
} else {
return identifier;
}
diff --git a/codemaker/source/cppumaker/cpputype.cxx b/codemaker/source/cppumaker/cpputype.cxx
index c98d8d76e214..1ab587040b82 100644
--- a/codemaker/source/cppumaker/cpputype.cxx
+++ b/codemaker/source/cppumaker/cpputype.cxx
@@ -165,7 +165,7 @@ public:
void dump(CppuOptions const & options);
void dumpFile(
- std::u16string_view uri, OUString const & name, bool hpp,
+ std::u16string_view uri, std::u16string_view name, bool hpp,
CppuOptions const & options);
void dumpDependedTypes(
@@ -178,7 +178,7 @@ public:
virtual void dumpHppFile(FileStream& o, codemaker::cppumaker::Includes & includes) = 0;
- OUString dumpHeaderDefine(FileStream& o, OUString const & extension) const;
+ OUString dumpHeaderDefine(FileStream& o, std::u16string_view extension) const;
void dumpGetCppuType(FileStream & out);
@@ -193,14 +193,14 @@ public:
}
void dumpType(
- FileStream & out, OUString const & name, bool isConst = false,
+ FileStream & out, std::u16string_view name, bool isConst = false,
bool isRef = false, bool native = false, bool cppuUnoType = false)
const;
OUString getTypeClass(OUString const & name, bool cStyle = false);
void dumpCppuGetType(
- FileStream & out, OUString const & name, OUString const * ownName = nullptr) const;
+ FileStream & out, std::u16string_view name, OUString const * ownName = nullptr) const;
sal_uInt32 getInheritedMemberCount();
@@ -253,7 +253,7 @@ protected:
void addDefaultHxxIncludes(codemaker::cppumaker::Includes & includes) const;
void dumpInitializer(
- FileStream & out, bool parameterized, OUString const & name) const;
+ FileStream & out, bool parameterized, std::u16string_view name) const;
void dumpHFileContent(
FileStream & out, codemaker::cppumaker::Includes & includes);
@@ -413,14 +413,14 @@ void CppuType::dump(CppuOptions const & options)
}
void CppuType::dumpFile(
- std::u16string_view uri, OUString const & name, bool hpp,
+ std::u16string_view uri, std::u16string_view name, bool hpp,
CppuOptions const & options)
{
OUString fileUri(
b2u(createFileNameFromType(
u2b(uri), u2b(name), hpp ? ".hpp" : ".hdl")));
if (fileUri.isEmpty()) {
- throw CannotDumpException("empty target URI for entity " + name);
+ throw CannotDumpException(OUString::Concat("empty target URI for entity ") + name);
}
bool exists = fileExists(u2b(fileUri));
if (exists && options.isValid("-G")) {
@@ -468,7 +468,7 @@ void CppuType::dumpDependedTypes(
}
OUString CppuType::dumpHeaderDefine(
- FileStream & out, OUString const & extension) const
+ FileStream & out, std::u16string_view extension) const
{
OUString def(
"INCLUDED_" + name_.replace('.', '_').toAsciiUpperCase() + "_"
@@ -500,7 +500,7 @@ const
}
void CppuType::dumpInitializer(
- FileStream & out, bool parameterized, OUString const & name) const
+ FileStream & out, bool parameterized, std::u16string_view name) const
{
out << "(";
if (!parameterized) {
@@ -541,7 +541,7 @@ void CppuType::dumpInitializer(
break;
default:
throw CannotDumpException(
- "unexpected entity \"" + name
+ OUString::Concat("unexpected entity \"") + name
+ "\" in call to CppuType::dumpInitializer");
}
}
@@ -553,7 +553,7 @@ void CppuType::dumpHFileContent(
FileStream & out, codemaker::cppumaker::Includes & includes)
{
addDefaultHIncludes(includes);
- dumpHeaderDefine(out, "HDL");
+ dumpHeaderDefine(out, u"HDL");
out << "\n";
includes.dump(out, nullptr, false);
// 'exceptions = false' would be wrong for services/singletons, but
@@ -746,7 +746,7 @@ OUString CppuType::getTypeClass(OUString const & name, bool cStyle)
}
void CppuType::dumpType(
- FileStream & out, OUString const & name, bool isConst, bool isRef,
+ FileStream & out, std::u16string_view name, bool isConst, bool isRef,
bool native, bool cppuUnoType) const
{
sal_Int32 k;
@@ -838,7 +838,7 @@ void CppuType::dumpType(
break;
default:
throw CannotDumpException(
- "unexpected entity \"" + name + "\" in call to CppuType::dumpType");
+ OUString::Concat("unexpected entity \"") + name + "\" in call to CppuType::dumpType");
}
for (sal_Int32 i = 0; i != k; ++i) {
out << " >";
@@ -849,7 +849,7 @@ void CppuType::dumpType(
}
void CppuType::dumpCppuGetType(
- FileStream & out, OUString const & name, OUString const * ownName) const
+ FileStream & out, std::u16string_view name, OUString const * ownName) const
{
//TODO: What are these calls good for?
OUString nucleus;
@@ -890,7 +890,7 @@ void CppuType::dumpCppuGetType(
for (;;) std::abort(); // this cannot happen
default:
throw CannotDumpException(
- "unexpected entity \"" + name
+ OUString::Concat("unexpected entity \"") + name
+ "\" in call to CppuType::dumpCppuGetType");
}
}
@@ -1182,7 +1182,7 @@ void InterfaceType::dumpDeclaration(FileStream & out)
void InterfaceType::dumpHppFile(
FileStream & out, codemaker::cppumaker::Includes & includes)
{
- OUString headerDefine(dumpHeaderDefine(out, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(out, u"HPP"));
out << "\n";
addDefaultHxxIncludes(includes);
includes.dump(out, &name_, !(m_cppuTypeLeak || m_cppuTypeDynamic));
@@ -1376,7 +1376,7 @@ void InterfaceType::dumpComprehensiveGetCppuType(FileStream & out)
std::set< OUString > seen;
// Type for RuntimeException is always needed:
seen.insert("com.sun.star.uno.RuntimeException");
- dumpCppuGetType(out, "com.sun.star.uno.RuntimeException");
+ dumpCppuGetType(out, u"com.sun.star.uno.RuntimeException");
dumpAttributesCppuDecl(out, &seen);
dumpMethodsCppuDecl(out, &seen);
if (count != 0) {
@@ -1651,7 +1651,7 @@ private:
void ConstantGroup::dumpHdlFile(
FileStream & out, codemaker::cppumaker::Includes & includes)
{
- OUString headerDefine(dumpHeaderDefine(out, "HDL"));
+ OUString headerDefine(dumpHeaderDefine(out, u"HDL"));
out << "\n";
addDefaultHIncludes(includes);
includes.dump(out, nullptr, true);
@@ -1671,7 +1671,7 @@ void ConstantGroup::dumpHdlFile(
void ConstantGroup::dumpHppFile(
FileStream & out, codemaker::cppumaker::Includes &)
{
- OUString headerDefine(dumpHeaderDefine(out, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(out, u"HPP"));
out << "\n";
codemaker::cppumaker::Includes::dumpInclude(out, u2b(name_), false);
out << "\n#endif // "<< headerDefine << "\n";
@@ -1867,7 +1867,7 @@ void PlainStructType::dumpDeclaration(FileStream & out)
void PlainStructType::dumpHppFile(
FileStream & out, codemaker::cppumaker::Includes & includes)
{
- OUString headerDefine(dumpHeaderDefine(out, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(out, u"HPP"));
out << "\n";
includes.dump(out, &name_, true);
out << "\n";
@@ -2259,7 +2259,7 @@ void PolyStructType::dumpDeclaration(FileStream & out)
void PolyStructType::dumpHppFile(
FileStream & out, codemaker::cppumaker::Includes & includes)
{
- OUString headerDefine(dumpHeaderDefine(out, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(out, u"HPP"));
out << "\n";
includes.dump(out, &name_, true);
out << "\n";
@@ -2811,7 +2811,7 @@ void ExceptionType::addComprehensiveGetCppuTypeIncludes(
void ExceptionType::dumpHppFile(
FileStream & out, codemaker::cppumaker::Includes & includes)
{
- OUString headerDefine(dumpHeaderDefine(out, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(out, u"HPP"));
out << "\n";
addDefaultHxxIncludes(includes);
includes.dump(out, &name_, true);
@@ -3321,7 +3321,7 @@ void EnumType::dumpDeclaration(FileStream& o)
void EnumType::dumpHppFile(
FileStream& o, codemaker::cppumaker::Includes & includes)
{
- OUString headerDefine(dumpHeaderDefine(o, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(o, u"HPP"));
o << "\n";
addDefaultHxxIncludes(includes);
@@ -3455,7 +3455,7 @@ private:
void Typedef::dumpHdlFile(
FileStream& o, codemaker::cppumaker::Includes & includes)
{
- OUString headerDefine(dumpHeaderDefine(o, "HDL"));
+ OUString headerDefine(dumpHeaderDefine(o, u"HDL"));
o << "\n";
addDefaultHIncludes(includes);
@@ -3485,7 +3485,7 @@ void Typedef::dumpDeclaration(FileStream& o)
void Typedef::dumpHppFile(
FileStream& o, codemaker::cppumaker::Includes & includes)
{
- OUString headerDefine(dumpHeaderDefine(o, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(o, u"HPP"));
o << "\n";
addDefaultHxxIncludes(includes);
@@ -3607,7 +3607,7 @@ void ServiceType::dumpHppFile(
OString cppName(
codemaker::cpp::translateUnoToCppIdentifier(
u2b(id_), "service", isGlobal()));
- OUString headerDefine(dumpHeaderDefine(o, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(o, u"HPP"));
o << "\n";
includes.dump(o, nullptr, true);
if (!entity_->getConstructors().empty()) {
@@ -3903,7 +3903,7 @@ void SingletonType::dumpHppFile(
u2b(id_), "singleton", isGlobal()));
OString baseName(u2b(entity_->getBase()));
OString scopedBaseName(codemaker::cpp::scopedCppName(baseName));
- OUString headerDefine(dumpHeaderDefine(o, "HPP"));
+ OUString headerDefine(dumpHeaderDefine(o, u"HPP"));
o << "\n";
//TODO: Decide whether the types added to includes should rather be added to
// m_dependencies (and thus be generated during dumpDependedTypes):
diff --git a/codemaker/source/cppumaker/dependencies.cxx b/codemaker/source/cppumaker/dependencies.cxx
index eb257c6966af..1af6b9d46061 100644
--- a/codemaker/source/cppumaker/dependencies.cxx
+++ b/codemaker/source/cppumaker/dependencies.cxx
@@ -102,7 +102,7 @@ Dependencies::Dependencies(
if (!(ent2->getDirectAttributes().empty()
&& ent2->getDirectMethods().empty()))
{
- insert("com.sun.star.uno.RuntimeException", KIND_EXCEPTION);
+ insert(u"com.sun.star.uno.RuntimeException", KIND_EXCEPTION);
}
for (const unoidl::InterfaceTypeEntity::Attribute& attr : ent2->getDirectAttributes())
{
@@ -212,7 +212,7 @@ Dependencies::Dependencies(
Dependencies::~Dependencies() {}
-void Dependencies::insert(OUString const & name, Kind kind) {
+void Dependencies::insert(std::u16string_view name, Kind kind) {
sal_Int32 k;
std::vector< OString > args;
OUString n(b2u(UnoType::decompose(u2b(name), &k, &args)));
@@ -286,7 +286,7 @@ void Dependencies::insert(OUString const & name, Kind kind) {
}
default:
throw CannotDumpException(
- "unexpected type \"" + name
+ OUString::Concat("unexpected type \"") + name
+ "\" in call to codemaker::cppumaker::Dependencies::Dependencies");
}
}
diff --git a/codemaker/source/cppumaker/dependencies.hxx b/codemaker/source/cppumaker/dependencies.hxx
index 9d805f382aae..0071397aa0ef 100644
--- a/codemaker/source/cppumaker/dependencies.hxx
+++ b/codemaker/source/cppumaker/dependencies.hxx
@@ -22,6 +22,7 @@
#include <sal/config.h>
#include <map>
+#include <string_view>
#include <rtl/ref.hxx>
@@ -100,7 +101,7 @@ public:
bool hasSequenceDependency() const { return m_sequenceDependency; }
private:
- void insert(OUString const & name, Kind kind);
+ void insert(std::u16string_view name, Kind kind);
rtl::Reference< TypeManager > m_manager;
Map m_map;
diff --git a/codemaker/source/javamaker/javatype.cxx b/codemaker/source/javamaker/javatype.cxx
index e29c5d5b6a13..25406d07234c 100644
--- a/codemaker/source/javamaker/javatype.cxx
+++ b/codemaker/source/javamaker/javatype.cxx
@@ -25,6 +25,7 @@
#include <map>
#include <memory>
#include <set>
+#include <string_view>
#include <utility>
#include <vector>
@@ -107,7 +108,7 @@ bool isSpecialType(SpecialType special) {
}
OString translateUnoidlEntityNameToJavaFullyQualifiedName(
- OUString const & name, OString const & prefix)
+ OUString const & name, std::string_view prefix)
{
assert(!name.startsWith("[]"));
assert(name.indexOf('<') == -1);
@@ -126,7 +127,7 @@ struct PolymorphicUnoType {
};
SpecialType translateUnoTypeToDescriptor(
- rtl::Reference< TypeManager > const & manager, OUString const & type,
+ rtl::Reference< TypeManager > const & manager, std::u16string_view type,
bool array, bool classType, std::set<OUString> * dependencies,
OStringBuffer * descriptor, OStringBuffer * signature,
bool * needsSignature, PolymorphicUnoType * polymorphicUnoType);
@@ -272,7 +273,7 @@ SpecialType translateUnoTypeToDescriptor(
}
SpecialType translateUnoTypeToDescriptor(
- rtl::Reference< TypeManager > const & manager, OUString const & type,
+ rtl::Reference< TypeManager > const & manager, std::u16string_view type,
bool array, bool classType, std::set<OUString> * dependencies,
OStringBuffer * descriptor, OStringBuffer * signature,
bool * needsSignature, PolymorphicUnoType * polymorphicUnoType)
@@ -290,7 +291,7 @@ SpecialType translateUnoTypeToDescriptor(
SpecialType getFieldDescriptor(
rtl::Reference< TypeManager > const & manager, std::set<OUString> * dependencies,
- OUString const & type, OString * descriptor, OString * signature,
+ std::u16string_view type, OString * descriptor, OString * signature,
PolymorphicUnoType * polymorphicUnoType)
{
assert(descriptor != nullptr);
@@ -315,12 +316,12 @@ class MethodDescriptor {
public:
MethodDescriptor(
rtl::Reference< TypeManager > const & manager,
- std::set<OUString> * dependencies, OUString const & returnType,
+ std::set<OUString> * dependencies, std::u16string_view returnType,
SpecialType * specialReturnType,
PolymorphicUnoType * polymorphicUnoType);
SpecialType addParameter(
- OUString const & type, bool array, bool dependency,
+ std::u16string_view type, bool array, bool dependency,
PolymorphicUnoType * polymorphicUnoType);
void addTypeParameter(OUString const & name);
@@ -341,7 +342,7 @@ private:
MethodDescriptor::MethodDescriptor(
rtl::Reference< TypeManager > const & manager, std::set<OUString> * dependencies,
- OUString const & returnType, SpecialType * specialReturnType,
+ std::u16string_view returnType, SpecialType * specialReturnType,
PolymorphicUnoType * polymorphicUnoType):
m_manager(manager), m_dependencies(dependencies), m_needsSignature(false)
{
@@ -363,7 +364,7 @@ MethodDescriptor::MethodDescriptor(
}
SpecialType MethodDescriptor::addParameter(
- OUString const & type, bool array, bool dependency,
+ std::u16string_view type, bool array, bool dependency,
PolymorphicUnoType * polymorphicUnoType)
{
return translateUnoTypeToDescriptor(
@@ -845,7 +846,7 @@ void addField(
sal_uInt16 addFieldInit(
rtl::Reference< TypeManager > const & manager, OString const & className,
- OUString const & fieldName, bool typeParameter, OUString const & fieldType,
+ OUString const & fieldName, bool typeParameter, std::u16string_view fieldType,
std::set<OUString> * dependencies, ClassFile::Code * code)
{
assert(manager.is());
@@ -931,7 +932,7 @@ sal_uInt16 addFieldInit(
for (;;) std::abort(); // this cannot happen
default:
throw CannotDumpException(
- "unexpected entity \"" + fieldType
+ OUString::Concat("unexpected entity \"") + fieldType
+ "\" in call to addFieldInit");
}
}
@@ -965,7 +966,7 @@ sal_uInt16 addFieldInit(
sal_uInt16 addLoadLocal(
rtl::Reference< TypeManager > const & manager, ClassFile::Code * code,
- sal_uInt16 * index, bool typeParameter, OUString const & type, bool any,
+ sal_uInt16 * index, bool typeParameter, std::u16string_view type, bool any,
std::set<OUString> * dependencies)
{
assert(manager.is());
@@ -1234,7 +1235,7 @@ sal_uInt16 addLoadLocal(
for (;;) std::abort(); // this cannot happen
default:
throw CannotDumpException(
- "unexpected entity \"" + type
+ OUString::Concat("unexpected entity \"") + type
+ "\" in call to addLoadLocal");
}
} else {
@@ -1272,7 +1273,7 @@ sal_uInt16 addLoadLocal(
for (;;) std::abort(); // this cannot happen
default:
throw CannotDumpException(
- "unexpected entity \"" + type
+ OUString::Concat("unexpected entity \"") + type
+ "\" in call to addLoadLocal");
}
}
@@ -1404,7 +1405,7 @@ void handlePlainStructType(
cf->addMethod(
ClassFile::ACC_PUBLIC, "<init>", "()V", code.get(),
std::vector< OString >(), "");
- MethodDescriptor desc(manager, dependencies, "void", nullptr, nullptr);
+ MethodDescriptor desc(manager, dependencies, u"void", nullptr, nullptr);
code = cf->newCode();
code->loadLocalReference(0);
sal_uInt16 index2 = 1;
@@ -1495,7 +1496,7 @@ void handlePolyStructType(
cf->addMethod(
ClassFile::ACC_PUBLIC, "<init>", "()V", code.get(),
std::vector< OString >(), "");
- MethodDescriptor desc(manager, dependencies, "void", nullptr, nullptr);
+ MethodDescriptor desc(manager, dependencies, u"void", nullptr, nullptr);
code = cf->newCode();
code->loadLocalReference(0);
sal_uInt16 index2 = 1;
@@ -1611,7 +1612,7 @@ void handleExceptionType(
stack,
addFieldInit(
manager, className, "Context", false,
- "com.sun.star.uno.XInterface", dependencies, code.get()));
+ u"com.sun.star.uno.XInterface", dependencies, code.get()));
}
for (std::vector< unoidl::ExceptionTypeEntity::Member >::const_iterator i(
entity->getDirectMembers().begin());
@@ -1643,7 +1644,7 @@ void handleExceptionType(
stack,
addFieldInit(
manager, className, "Context", false,
- "com.sun.star.uno.XInterface", dependencies, code.get()));
+ u"com.sun.star.uno.XInterface", dependencies, code.get()));
}
for (std::vector< unoidl::ExceptionTypeEntity::Member >::const_iterator i(
entity->getDirectMembers().begin());
@@ -1681,7 +1682,7 @@ void handleExceptionType(
stack,
addFieldInit(
manager, className, "Context", false,
- "com.sun.star.uno.XInterface", dependencies, code.get()));
+ u"com.sun.star.uno.XInterface", dependencies, code.get()));
}
for (std::vector< unoidl::ExceptionTypeEntity::Member >::const_iterator i(
entity->getDirectMembers().begin());
@@ -1712,7 +1713,7 @@ void handleExceptionType(
stack,
addFieldInit(
manager, className, "Context", false,
- "com.sun.star.uno.XInterface", dependencies, code.get()));
+ u"com.sun.star.uno.XInterface", dependencies, code.get()));
}
for (std::vector< unoidl::ExceptionTypeEntity::Member >::const_iterator i(
entity->getDirectMembers().begin());
@@ -1734,12 +1735,12 @@ void handleExceptionType(
// create (String Message, Object Context, T1 m1, ..., Tn mn) constructor
- MethodDescriptor desc1(manager, dependencies, "void", nullptr, nullptr);
+ MethodDescriptor desc1(manager, dependencies, u"void", nullptr, nullptr);
code = cf->newCode();
code->loadLocalReference(0);
sal_uInt16 index2 = 1;
code->loadLocalReference(index2++);
- desc1.addParameter("string", false, true, nullptr);
+ desc1.addParameter(u"string", false, true, nullptr);
if (!(baseException || baseRuntimeException)) {
addExceptionBaseArguments(
manager, dependencies, &desc1, code.get(), entity->getDirectBase(),
@@ -1774,13 +1775,13 @@ void handleExceptionType(
std::vector< OString >(), desc1.getSignature());
// create (Throwable Cause, String Message, Object Context, T1 m1, ..., Tn mn) constructor
- MethodDescriptor desc2(manager, dependencies, "void", nullptr, nullptr);
+ MethodDescriptor desc2(manager, dependencies, u"void", nullptr, nullptr);
code = cf->newCode();
code->loadLocalReference(0);
sal_uInt16 index3 = 3;
// Note that we hack in the java.lang.Throwable parameter further down,
// because MethodDescriptor does not know how to handle it.
- desc2.addParameter("string", false, true, nullptr);
+ desc2.addParameter(u"string", false, true, nullptr);
if (baseException || baseRuntimeException) {
code->loadLocalReference(2);
code->loadLocalReference(1);
@@ -1888,7 +1889,7 @@ void handleInterfaceType(
"get" + attrName, gdesc.getDescriptor(), nullptr, exc,
gdesc.getSignature());
if (!attr.readOnly) {
- MethodDescriptor sdesc(manager, dependencies, "void", nullptr, nullptr);
+ MethodDescriptor sdesc(manager, dependencies, u"void", nullptr, nullptr);
sdesc.addParameter(attr.type, false, true, nullptr);
std::vector< OString > exc2;
createExceptionsAttribute(
@@ -2079,7 +2080,7 @@ void addExceptionHandlers(
void addConstructor(
rtl::Reference< TypeManager > const & manager,
- OString const & realJavaBaseName, OString const & unoName,
+ std::string_view realJavaBaseName, OString const & unoName,
OString const & className,
unoidl::SingleInterfaceBasedServiceEntity::Constructor const & constructor,
OUString const & returnType, std::set<OUString> * dependencies,
@@ -2088,7 +2089,7 @@ void addConstructor(
assert(dependencies != nullptr);
assert(classFile != nullptr);
MethodDescriptor desc(manager, dependencies, returnType, nullptr, nullptr);
- desc.addParameter("com.sun.star.uno.XComponentContext", false, false, nullptr);
+ desc.addParameter(u"com.sun.star.uno.XComponentContext", false, false, nullptr);
std::unique_ptr< ClassFile::Code > code(classFile->newCode());
code->loadLocalReference(0);
// stack: context
@@ -2123,7 +2124,7 @@ void addConstructor(
if (constructor.parameters.size() == 1
&& constructor.parameters[0].rest)
{
- desc.addParameter("any", true, true, nullptr);
+ desc.addParameter(u"any", true, true, nullptr);
code->loadLocalReference(localIndex++);
// stack: factory serviceName args
stack = 4;
@@ -2345,7 +2346,7 @@ void handleSingleton(
| ClassFile::ACC_SUPER),
className, "java/lang/Object", ""));
MethodDescriptor desc(manager, dependencies, entity->getBase(), nullptr, nullptr);
- desc.addParameter("com.sun.star.uno.XComponentContext", false, false, nullptr);
+ desc.addParameter(u"com.sun.star.uno.XComponentContext", false, false, nullptr);
std::unique_ptr< ClassFile::Code > code(cf->newCode());
code->loadLocalReference(0);
// stack: context
diff --git a/comphelper/source/misc/DirectoryHelper.cxx b/comphelper/source/misc/DirectoryHelper.cxx
index 5b0ffbf68465..4ac2dfe7e829 100644
--- a/comphelper/source/misc/DirectoryHelper.cxx
+++ b/comphelper/source/misc/DirectoryHelper.cxx
@@ -142,7 +142,8 @@ bool DirectoryHelper::deleteDirRecursively(const OUString& rDirURL)
}
// both exist, move content
-bool DirectoryHelper::moveDirContent(const OUString& rSourceDirURL, const OUString& rTargetDirURL,
+bool DirectoryHelper::moveDirContent(const OUString& rSourceDirURL,
+ std::u16string_view rTargetDirURL,
const std::set<OUString>& rExcludeList)
{
std::set<OUString> aDirs;
@@ -161,7 +162,7 @@ bool DirectoryHelper::moveDirContent(const OUString& rSourceDirURL, const OUStri
if (dirExists(aNewSourceDirURL))
{
- const OUString aNewTargetDirURL(rTargetDirURL + "/" + dir);
+ const OUString aNewTargetDirURL(OUString::Concat(rTargetDirURL) + "/" + dir);
if (dirExists(aNewTargetDirURL))
{
@@ -185,7 +186,7 @@ bool DirectoryHelper::moveDirContent(const OUString& rSourceDirURL, const OUStri
if (fileExists(aSourceFileURL))
{
- OUString aTargetFileURL(rTargetDirURL + "/" + file.first);
+ OUString aTargetFileURL(OUString::Concat(rTargetDirURL) + "/" + file.first);
if (!file.second.isEmpty())
{
diff --git a/comphelper/source/misc/backupfilehelper.cxx b/comphelper/source/misc/backupfilehelper.cxx
index fcde7879255b..c7bcd4253ed0 100644
--- a/comphelper/source/misc/backupfilehelper.cxx
+++ b/comphelper/source/misc/backupfilehelper.cxx
@@ -18,6 +18,7 @@
#include <algorithm>
#include <deque>
#include <memory>
+#include <string_view>
#include <vector>
#include <zlib.h>
@@ -172,30 +173,31 @@ namespace
return osl_File_E_None == osl_writeFile(rHandle, static_cast<const void*>(rSource.getStr()), nLength, &nBaseWritten) && nLength == nBaseWritten;
}
- OUString createFileURL(const OUString& rURL, const OUString& rName, const OUString& rExt)
+ OUString createFileURL(
+ std::u16string_view rURL, std::u16string_view rName, std::u16string_view rExt)
{
OUString aRetval;
- if (!rURL.isEmpty() && !rName.isEmpty())
+ if (!rURL.empty() && !rName.empty())
{
- aRetval = rURL + "/" + rName;
+ aRetval = OUString::Concat(rURL) + "/" + rName;
- if (!rExt.isEmpty())
+ if (!rExt.empty())
{
- aRetval += "." + rExt;
+ aRetval += OUString::Concat(".") + rExt;
}
}
return aRetval;
}
- OUString createPackURL(const OUString& rURL, const OUString& rName)
+ OUString createPackURL(std::u16string_view rURL, std::u16string_view rName)
{
OUString aRetval;
- if (!rURL.isEmpty() && !rName.isEmpty())
+ if (!rURL.empty() && !rName.empty())
{
- aRetval = rURL + "/" + rName + ".pack";
+ aRetval = OUString::Concat(rURL) + "/" + rName + ".pack";
}
return aRetval;
@@ -479,21 +481,24 @@ namespace
}
public:
- void createUserExtensionRegistryEntriesFromXML(const OUString& rUserConfigWorkURL)
+ void createUserExtensionRegistryEntriesFromXML(std::u16string_view rUserConfigWorkURL)
{
- const OUString aPath(rUserConfigWorkURL + "/uno_packages/cache" + gaRegPath);
+ const OUString aPath(
+ OUString::Concat(rUserConfigWorkURL) + "/uno_packages/cache" + gaRegPath);
createExtensionRegistryEntriesFromXML(aPath);
}
- void createSharedExtensionRegistryEntriesFromXML(const OUString& rUserConfigWorkURL)
+ void createSharedExtensionRegistryEntriesFromXML(std::u16string_view rUserConfigWorkURL)
{
- const OUString aPath(rUserConfigWorkURL + "/extensions/shared" + gaRegPath);
+ const OUString aPath(
+ OUString::Concat(rUserConfigWorkURL) + "/extensions/shared" + gaRegPath);
createExtensionRegistryEntriesFromXML(aPath);
}
- void createBundledExtensionRegistryEntriesFromXML(const OUString& rUserConfigWorkURL)
+ void createBundledExtensionRegistryEntriesFromXML(std::u16string_view rUserConfigWorkURL)
{
- const OUString aPath(rUserConfigWorkURL + "/extensions/bundled" + gaRegPath);
+ const OUString aPath(
+ OUString::Concat(rUserConfigWorkURL) + "/extensions/bundled" + gaRegPath);
createExtensionRegistryEntriesFromXML(aPath);
}
@@ -657,7 +662,7 @@ namespace
public:
static void changeEnableDisableStateInXML(
- const OUString& rUserConfigWorkURL,
+ std::u16string_view rUserConfigWorkURL,
const ExtensionInfoEntryVector& rToBeEnabled,
const ExtensionInfoEntryVector& rToBeDisabled)
{
@@ -665,7 +670,7 @@ namespace
const OUString aRegPathBack(".PackageRegistryBackend/backenddb.xml");
// first appearance to check
{
- const OUString aUnoPackagReg(rUserConfigWorkURL + aRegPathFront + "bundle" + aRegPathBack);
+ const OUString aUnoPackagReg(OUString::Concat(rUserConfigWorkURL) + aRegPathFront + "bundle" + aRegPathBack);
visitNodesXMLChangeOneCase(
aUnoPackagReg,
@@ -676,7 +681,7 @@ namespace
// second appearance to check
{
- const OUString aUnoPackagReg(rUserConfigWorkURL + aRegPathFront + "configuration" + aRegPathBack);
+ const OUString aUnoPackagReg(OUString::Concat(rUserConfigWorkURL) + aRegPathFront + "configuration" + aRegPathBack);
visitNodesXMLChangeOneCase(
aUnoPackagReg,
@@ -687,7 +692,7 @@ namespace
// third appearance to check
{
- const OUString aUnoPackagReg(rUserConfigWorkURL + aRegPathFront + "script" + aRegPathBack);
+ const OUString aUnoPackagReg(OUString::Concat(rUserConfigWorkURL) + aRegPathFront + "script" + aRegPathBack);
visitNodesXMLChangeOneCase(
aUnoPackagReg,
@@ -2017,8 +2022,8 @@ namespace comphelper
bool BackupFileHelper::tryPush_Files(
const std::set< OUString >& rDirs,
const std::set< std::pair< OUString, OUString > >& rFiles,
- const OUString& rSourceURL, // source dir without trailing '/'
- const OUString& rTargetURL // target dir without trailing '/'
+ std::u16string_view rSourceURL, // source dir without trailing '/'
+ const OUString& rTargetURL // target dir without trailing '/'
)
{
bool bDidPush(false);
@@ -2037,7 +2042,7 @@ namespace comphelper
// process dirs
for (const auto& dir : rDirs)
{
- OUString aNewSourceURL(rSourceURL + "/" + dir);
+ OUString aNewSourceURL(OUString::Concat(rSourceURL) + "/" + dir);
OUString aNewTargetURL(rTargetURL + "/" + dir);
std::set< OUString > aNewDirs;
std::set< std::pair< OUString, OUString > > aNewFiles;
@@ -2067,10 +2072,10 @@ namespace comphelper
}
bool BackupFileHelper::tryPush_file(
- const OUString& rSourceURL, // source dir without trailing '/'
- const OUString& rTargetURL, // target dir without trailing '/'
- const OUString& rName, // filename
- const OUString& rExt // extension (or empty)
+ std::u16string_view rSourceURL, // source dir without trailing '/'
+ std::u16string_view rTargetURL, // target dir without trailing '/'
+ std::u16string_view rName, // filename
+ std::u16string_view rExt // extension (or empty)
)
{
const OUString aFileURL(createFileURL(rSourceURL, rName, rExt));
@@ -2099,8 +2104,8 @@ namespace comphelper
bool BackupFileHelper::isPopPossible_files(
const std::set< OUString >& rDirs,
const std::set< std::pair< OUString, OUString > >& rFiles,
- const OUString& rSourceURL, // source dir without trailing '/'
- const OUString& rTargetURL // target dir without trailing '/'
+ std::u16string_view rSourceURL, // source dir without trailing '/'
+ std::u16string_view rTargetURL // target dir without trailing '/'
)
{
bool bPopPossible(false);
@@ -2118,8 +2123,8 @@ namespace comphelper
// process dirs
for (const auto& dir : rDirs)
{
- OUString aNewSourceURL(rSourceURL + "/" + dir);
- OUString aNewTargetURL(rTargetURL + "/" + dir);
+ OUString aNewSourceURL(OUString::Concat(rSourceURL) + "/" + dir);
+ OUString aNewTargetURL(OUString::Concat(rTargetURL) + "/" + dir);
std::set< OUString > aNewDirs;
std::set< std::pair< OUString, OUString > > aNewFiles;
@@ -2142,10 +2147,10 @@ namespace comphelper
}
bool BackupFileHelper::isPopPossible_file(
- const OUString& rSourceURL, // source dir without trailing '/'
- const OUString& rTargetURL, // target dir without trailing '/'
- const OUString& rName, // filename
- const OUString& rExt // extension (or empty)
+ std::u16string_view rSourceURL, // source dir without trailing '/'
+ std::u16string_view rTargetURL, // target dir without trailing '/'
+ std::u16string_view rName, // filename
+ std::u16string_view rExt // extension (or empty)
)
{
const OUString aFileURL(createFileURL(rSourceURL, rName, rExt));
@@ -2166,7 +2171,7 @@ namespace comphelper
bool BackupFileHelper::tryPop_files(
const std::set< OUString >& rDirs,
const std::set< std::pair< OUString, OUString > >& rFiles,
- const OUString& rSourceURL, // source dir without trailing '/'
+ std::u16string_view rSourceURL, // source dir without trailing '/'
const OUString& rTargetURL // target dir without trailing '/'
)
{
@@ -2185,7 +2190,7 @@ namespace comphelper
// process dirs
for (const auto& dir : rDirs)
{
- OUString aNewSourceURL(rSourceURL + "/" + dir);
+ OUString aNewSourceURL(OUString::Concat(rSourceURL) + "/" + dir);
OUString aNewTargetURL(rTargetURL + "/" + dir);
std::set< OUString > aNewDirs;
std::set< std::pair< OUString, OUString > > aNewFiles;
@@ -2215,10 +2220,10 @@ namespace comphelper
}
bool BackupFileHelper::tryPop_file(
- const OUString& rSourceURL, // source dir without trailing '/'
- const OUString& rTargetURL, // target dir without trailing '/'
- const OUString& rName, // filename
- const OUString& rExt // extension (or empty)
+ std::u16string_view rSourceURL, // source dir without trailing '/'
+ std::u16string_view rTargetURL, // target dir without trailing '/'
+ std::u16string_view rName, // filename
+ std::u16string_view rExt // extension (or empty)
)
{
const OUString aFileURL(createFileURL(rSourceURL, rName, rExt));
@@ -2268,7 +2273,7 @@ namespace comphelper
/////////////////// ExtensionInfo helpers ///////////////////////
bool BackupFileHelper::tryPush_extensionInfo(
- const OUString& rTargetURL // target dir without trailing '/'
+ std::u16string_view rTargetURL // target dir without trailing '/'
)
{
ExtensionInfo aExtensionInfo;
@@ -2278,7 +2283,7 @@ namespace comphelper
// create current configuration and write to temp file - it exists until deleted
if (aExtensionInfo.createTempFile(aTempURL))
{
- const OUString aPackURL(createPackURL(rTargetURL, "ExtensionInfo"));
+ const OUString aPackURL(createPackURL(rTargetURL, u"ExtensionInfo"));
PackedFile aPackedFile(aPackURL);
FileSharedPtr aBaseFile = std::make_shared<osl::File>(aTempURL);
@@ -2297,22 +2302,22 @@ namespace comphelper
}
bool BackupFileHelper::isPopPossible_extensionInfo(
- const OUString& rTargetURL // target dir without trailing '/'
+ std::u16string_view rTargetURL // target dir without trailing '/'
)
{
// extensionInfo always exists internally, no test needed
- const OUString aPackURL(createPackURL(rTargetURL, "ExtensionInfo"));
+ const OUString aPackURL(createPackURL(rTargetURL, u"ExtensionInfo"));
PackedFile aPackedFile(aPackURL);
return !aPackedFile.empty();
}
bool BackupFileHelper::tryPop_extensionInfo(
- const OUString& rTargetURL // target dir without trailing '/'
+ std::u16string_view rTargetURL // target dir without trailing '/'
)
{
// extensionInfo always exists internally, no test needed
- const OUString aPackURL(createPackURL(rTargetURL, "ExtensionInfo"));
+ const OUString aPackURL(createPackURL(rTargetURL, u"ExtensionInfo"));
PackedFile aPackedFile(aPackURL);
if (!aPackedFile.empty())
diff --git a/comphelper/source/misc/configuration.cxx b/comphelper/source/misc/configuration.cxx
index a4041de4bb54..56b186dea805 100644
--- a/comphelper/source/misc/configuration.cxx
+++ b/comphelper/source/misc/configuration.cxx
@@ -11,6 +11,7 @@
#include <cassert>
#include <memory>
+#include <string_view>
#include <com/sun/star/beans/PropertyAttribute.hpp>
#include <com/sun/star/configuration/ReadOnlyAccess.hpp>
@@ -53,14 +54,14 @@ OUString getDefaultLocale(
getLocale()).getBcp47(false);
}
-OUString extendLocalizedPath(OUString const & path, OUString const & locale) {
+OUString extendLocalizedPath(std::u16string_view path, OUString const & locale) {
SAL_WARN_IF(
locale.match("*"), "comphelper",
"Locale \"" << locale << "\" starts with \"*\"");
assert(locale.indexOf('&') == -1);
assert(locale.indexOf('"') == -1);
assert(locale.indexOf('\'') == -1);
- return path + "/['*" + locale + "']";
+ return OUString::Concat(path) + "/['*" + locale + "']";
}
}
@@ -145,7 +146,7 @@ void comphelper::detail::ConfigurationWrapper::setPropertyValue(
css::uno::Any
comphelper::detail::ConfigurationWrapper::getLocalizedPropertyValue(
- OUString const & path) const
+ std::u16string_view path) const
{
return access_->getByHierarchicalName(
extendLocalizedPath(path, getDefaultLocale(context_)));
diff --git a/comphelper/source/property/propertystatecontainer.cxx b/comphelper/source/property/propertystatecontainer.cxx
index 35598b262a68..e19e78733689 100644
--- a/comphelper/source/property/propertystatecontainer.cxx
+++ b/comphelper/source/property/propertystatecontainer.cxx
@@ -17,6 +17,10 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <sal/config.h>
+
+#include <string_view>
+
#include <comphelper/propertystatecontainer.hxx>
@@ -30,13 +34,13 @@ namespace comphelper
namespace
{
- OUString lcl_getUnknownPropertyErrorMessage( const OUString& _rPropertyName )
+ OUString lcl_getUnknownPropertyErrorMessage( std::u16string_view _rPropertyName )
{
// TODO: perhaps it's time to think about resources in the comphelper module?
// Would be nice to have localized exception strings (a simply resource file containing
// strings only would suffice, and could be realized with a UNO service, so we do not
// need the dependency to the Tools project)
- return "The property \"" + _rPropertyName + "\" is unknown.";
+ return OUString::Concat("The property \"") + _rPropertyName + "\" is unknown.";
}
}
diff --git a/comphelper/source/xml/ofopxmlhelper.cxx b/comphelper/source/xml/ofopxmlhelper.cxx
index 3bf5984f9d83..2da35bdd0a3a 100644
--- a/comphelper/source/xml/ofopxmlhelper.cxx
+++ b/comphelper/source/xml/ofopxmlhelper.cxx
@@ -79,10 +79,10 @@ static uno::Sequence<uno::Sequence< beans::StringPair>> ReadSequence_Impl(
uno::Sequence< uno::Sequence< beans::StringPair > > ReadRelationsInfoSequence(
const uno::Reference< io::XInputStream >& xInStream,
- const OUString & aStreamName,
+ std::u16string_view aStreamName,
const uno::Reference< uno::XComponentContext >& rContext )
{
- OUString aStringID = "_rels/" + aStreamName;
+ OUString aStringID = OUString::Concat("_rels/") + aStreamName;
return ReadSequence_Impl( xInStream, aStringID, RELATIONINFO_FORMAT, rContext );
}
diff --git a/compilerplugins/clang/stringviewparam.cxx b/compilerplugins/clang/stringviewparam.cxx
index 2ef18f75cf60..9d3aac5fed0a 100644
--- a/compilerplugins/clang/stringviewparam.cxx
+++ b/compilerplugins/clang/stringviewparam.cxx
@@ -172,7 +172,8 @@ SmallVector<DeclRefExpr const*, 2> wrap(DeclRefExpr const* expr)
SmallVector<DeclRefExpr const*, 2> relevantCXXOperatorCallExpr(CXXOperatorCallExpr const* expr)
{
- if (expr->getOperator() == OO_Subscript)
+ auto const op = expr->getOperator();
+ if (op == OO_Subscript)
{
auto const e = expr->getArg(0);
if (relevantStringType(e->getType()) == StringType::None)
@@ -181,7 +182,7 @@ SmallVector<DeclRefExpr const*, 2> relevantCXXOperatorCallExpr(CXXOperatorCallEx
}
return wrap(relevantDeclRefExpr(e));
}
- if (compat::isComparisonOp(expr))
+ if (compat::isComparisonOp(expr) || (op == OO_Plus && expr->getNumArgs() == 2))
{
SmallVector<DeclRefExpr const*, 2> v;
if (auto const e = relevantDeclRefExpr(expr->getArg(0)))
diff --git a/configmgr/source/components.cxx b/configmgr/source/components.cxx
index cd1fceddb2ef..65bc00da9517 100644
--- a/configmgr/source/components.cxx
+++ b/configmgr/source/components.cxx
@@ -855,8 +855,8 @@ void Components::parseXcsXcuIniLayer(
}
}
-void Components::parseResLayer(int layer, OUString const & url) {
- OUString resUrl(url + "/res");
+void Components::parseResLayer(int layer, std::u16string_view url) {
+ OUString resUrl(OUString::Concat(url) + "/res");
parseXcdFiles(layer, resUrl);
parseFiles(layer, ".xcu", &parseXcuFile, resUrl, false);
}
diff --git a/configmgr/source/components.hxx b/configmgr/source/components.hxx
index 0647002f0d15..a44097810015 100644
--- a/configmgr/source/components.hxx
+++ b/configmgr/source/components.hxx
@@ -22,6 +22,7 @@
#include <sal/config.h>
#include <set>
+#include <string_view>
#include <com/sun/star/beans/Optional.hpp>
#include <com/sun/star/uno/Reference.hxx>
@@ -131,7 +132,7 @@ private:
void parseXcsXcuIniLayer(
int layer, OUString const & url, bool recordAdditions);
- void parseResLayer(int layer, OUString const & url);
+ void parseResLayer(int layer, std::u16string_view url);
void parseModificationLayer(int layer, OUString const & url);
diff --git a/configmgr/source/writemodfile.cxx b/configmgr/source/writemodfile.cxx
index 04da5f9a50ab..759959ab3bb7 100644
--- a/configmgr/source/writemodfile.cxx
+++ b/configmgr/source/writemodfile.cxx
@@ -401,7 +401,7 @@ struct PairEntrySorter
void writeModifications(
Components & components, TempFile &handle,
- OUString const & parentPathRepresentation,
+ std::u16string_view parentPathRepresentation,
rtl::Reference< Node > const & parent, OUString const & nodeName,
rtl::Reference< Node > const & node,
Modifications::Node const & modifications)
@@ -448,7 +448,7 @@ void writeModifications(
} else {
assert(node.is());
OUString pathRep(
- parentPathRepresentation + "/" +
+ OUString::Concat(parentPathRepresentation) + "/" +
Data::createSegment(node->getTemplateName(), nodeName));
// copy configmgr::Modifications::Node's to a sortable list. Use pointers
@@ -627,7 +627,7 @@ void writeModFile(
for (const auto& j : ModNodePairEntryVector)
{
writeModifications(
- components, tmp, "", rtl::Reference< Node >(), j->first,
+ components, tmp, u"", rtl::Reference< Node >(), j->first,
data.getComponents().findNode(Data::NO_LAYER, j->first),
j->second);
}
diff --git a/configmgr/source/xcuparser.cxx b/configmgr/source/xcuparser.cxx
index 03e3c60ab067..af21518abd78 100644
--- a/configmgr/source/xcuparser.cxx
+++ b/configmgr/source/xcuparser.cxx
@@ -651,7 +651,7 @@ void XcuParser::handleUnknownGroupProp(
void XcuParser::handlePlainGroupProp(
xmlreader::XmlReader const & reader, GroupNode * group,
- NodeMap::iterator const & propertyIndex, OUString const & name,
+ NodeMap::iterator const & propertyIndex, std::u16string_view name,
Type type, Operation operation, bool finalized)
{
PropertyNode * property = static_cast< PropertyNode * >(
@@ -672,7 +672,7 @@ void XcuParser::handlePlainGroupProp(
type != property->getStaticType())
{
throw css::uno::RuntimeException(
- "invalid type for prop " + name + " in " + reader.getUrl());
+ OUString::Concat("invalid type for prop ") + name + " in " + reader.getUrl());
}
valueParser_.type_ = type == TYPE_ERROR ? property->getStaticType() : type;
switch (operation) {
@@ -685,7 +685,7 @@ void XcuParser::handlePlainGroupProp(
case OPERATION_REMOVE:
if (!property->isExtension()) {
throw css::uno::RuntimeException(
- "invalid remove of non-extension prop " + name + " in " +
+ OUString::Concat("invalid remove of non-extension prop ") + name + " in " +
reader.getUrl());
}
group->getMembers().erase(propertyIndex);
diff --git a/configmgr/source/xcuparser.hxx b/configmgr/source/xcuparser.hxx
index 9bec6a26081a..cf6fb3e91b2d 100644
--- a/configmgr/source/xcuparser.hxx
+++ b/configmgr/source/xcuparser.hxx
@@ -23,6 +23,7 @@
#include <set>
#include <stack>
+#include <string_view>
#include <rtl/ref.hxx>
#include <rtl/ustring.hxx>
@@ -89,7 +90,7 @@ private:
void handlePlainGroupProp(
xmlreader::XmlReader const & reader, GroupNode * group,
- NodeMap::iterator const & propertyIndex, OUString const & name,
+ NodeMap::iterator const & propertyIndex, std::u16string_view name,
Type type, Operation operation, bool finalized);
void handleLocalizedGroupProp(
diff --git a/connectivity/qa/connectivity/ado/DriverTest.cxx b/connectivity/qa/connectivity/ado/DriverTest.cxx
index f4dd0ebc2791..1be8c04c7fb5 100644
--- a/connectivity/qa/connectivity/ado/DriverTest.cxx
+++ b/connectivity/qa/connectivity/ado/DriverTest.cxx
@@ -62,7 +62,7 @@ void AdoDriverTest::setUp()
CPPUNIT_ASSERT_MESSAGE("no ado component!", m_xAdoComponent.is());
OUString url = "sdbc:ado:access:PROVIDER=Microsoft.Jet.OLEDB.4.0;DATA SOURCE=" +
- m_directories.getPathFromWorkdir("/CppunitTest/TS001018407.mdb");
+ m_directories.getPathFromWorkdir(u"/CppunitTest/TS001018407.mdb");
Sequence< PropertyValue > info;
Reference< XDriver> xDriver(m_xAdoComponent, UNO_QUERY);
diff --git a/connectivity/source/commontools/TColumnsHelper.cxx b/connectivity/source/commontools/TColumnsHelper.cxx
index f06393778953..8671df0b042f 100644
--- a/connectivity/source/commontools/TColumnsHelper.cxx
+++ b/connectivity/source/commontools/TColumnsHelper.cxx
@@ -84,7 +84,7 @@ sdbcx::ObjectType OColumnsHelper::createObject(const OUString& _rName)
if ( aFind == m_pImpl->m_aColumnInfo.end() ) // we have to fill it
{
OUString sComposedName = ::dbtools::composeTableNameForSelect( xConnection, m_pTable );
- collectColumnInformation(xConnection,sComposedName,"*" ,m_pImpl->m_aColumnInfo);
+ collectColumnInformation(xConnection,sComposedName,u"*" ,m_pImpl->m_aColumnInfo);
aFind = m_pImpl->m_aColumnInfo.find(_rName);
}
if ( aFind != m_pImpl->m_aColumnInfo.end() )
diff --git a/connectivity/source/commontools/dbtools2.cxx b/connectivity/source/commontools/dbtools2.cxx
index db6e81a7400a..a57ca9749770 100644
--- a/connectivity/source/commontools/dbtools2.cxx
+++ b/connectivity/source/commontools/dbtools2.cxx
@@ -798,11 +798,11 @@ sal_Int32 getTablePrivileges(const Reference< XDatabaseMetaData>& _xMetaData,
// we need some more information about the column
void collectColumnInformation(const Reference< XConnection>& _xConnection,
- const OUString& _sComposedName,
- const OUString& _rName,
+ std::u16string_view _sComposedName,
+ std::u16string_view _rName,
ColumnInformationMap& _rInfo)
{
- OUString sSelect = "SELECT " + _rName +
+ OUString sSelect = OUString::Concat("SELECT ") + _rName +
" FROM " + _sComposedName +
" WHERE 0 = 1";
diff --git a/connectivity/source/drivers/firebird/DatabaseMetaData.cxx b/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
index d06e7cc71985..fdea4e4026eb 100644
--- a/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
+++ b/connectivity/source/drivers/firebird/DatabaseMetaData.cxx
@@ -1475,7 +1475,7 @@ uno::Reference< XResultSet > SAL_CALL ODatabaseMetaData::getImportedKeys(
return ODatabaseMetaData::lcl_getKeys(true, table);
}
-uno::Reference< XResultSet > ODatabaseMetaData::lcl_getKeys(const bool& bIsImport, const OUString& table )
+uno::Reference< XResultSet > ODatabaseMetaData::lcl_getKeys(const bool& bIsImport, std::u16string_view table )
{
ODatabaseMetaDataResultSet* pResultSet = new
ODatabaseMetaDataResultSet(ODatabaseMetaDataResultSet::eImportedKeys);
@@ -1506,9 +1506,9 @@ uno::Reference< XResultSet > ODatabaseMetaData::lcl_getKeys(const bool& bIsImpor
"ON FOREI.RDB$INDEX_NAME = FOREIGN_INDEX.RDB$INDEX_NAME "
"WHERE FOREI.RDB$CONSTRAINT_TYPE = 'FOREIGN KEY' ";
if (bIsImport)
- sSQL += "AND FOREI.RDB$RELATION_NAME = '"+ table +"'";
+ sSQL += OUString::Concat("AND FOREI.RDB$RELATION_NAME = '")+ table +"'";
else
- sSQL += "AND PRIM.RDB$RELATION_NAME = '"+ table +"'";
+ sSQL += OUString::Concat("AND PRIM.RDB$RELATION_NAME = '")+ table +"'";
uno::Reference< XResultSet > rs = statement->executeQuery(sSQL);
uno::Reference< XRow > xRow( rs, UNO_QUERY_THROW );
diff --git a/connectivity/source/drivers/firebird/DatabaseMetaData.hxx b/connectivity/source/drivers/firebird/DatabaseMetaData.hxx
index ccad90f3925f..fda5bb31bc88 100644
--- a/connectivity/source/drivers/firebird/DatabaseMetaData.hxx
+++ b/connectivity/source/drivers/firebird/DatabaseMetaData.hxx
@@ -20,6 +20,10 @@
#ifndef INCLUDED_CONNECTIVITY_SOURCE_DRIVERS_FIREBIRD_DATABASEMETADATA_HXX
#define INCLUDED_CONNECTIVITY_SOURCE_DRIVERS_FIREBIRD_DATABASEMETADATA_HXX
+#include <sal/config.h>
+
+#include <string_view>
+
#include "Connection.hxx"
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
@@ -38,7 +42,7 @@ namespace connectivity::firebird
{
::rtl::Reference<Connection> m_pConnection;
private:
- css::uno::Reference< css::sdbc::XResultSet > lcl_getKeys( const bool& bIsImport, const OUString& table );
+ css::uno::Reference< css::sdbc::XResultSet > lcl_getKeys( const bool& bIsImport, std::u16string_view table );
public:
explicit ODatabaseMetaData(Connection* _pCon);
diff --git a/connectivity/source/drivers/firebird/Table.cxx b/connectivity/source/drivers/firebird/Table.cxx
index e0eba9d7e264..02718c78e731 100644
--- a/connectivity/source/drivers/firebird/Table.cxx
+++ b/connectivity/source/drivers/firebird/Table.cxx
@@ -254,7 +254,7 @@ uno::Sequence< Type > SAL_CALL Table::getTypes()
return OTableHelper::getTypes();
}
-OUString Table::getAlterTableColumn(const OUString& rColumn)
+OUString Table::getAlterTableColumn(std::u16string_view rColumn)
{
return ("ALTER TABLE \"" + getName() + "\" ALTER COLUMN \"" + rColumn + "\" ");
}
diff --git a/connectivity/source/drivers/firebird/Table.hxx b/connectivity/source/drivers/firebird/Table.hxx
index 8cf0ff53f90d..d2646dcd168d 100644
--- a/connectivity/source/drivers/firebird/Table.hxx
+++ b/connectivity/source/drivers/firebird/Table.hxx
@@ -10,6 +10,10 @@
#ifndef INCLUDED_CONNECTIVITY_SOURCE_DRIVERS_FIREBIRD_TABLE_HXX
#define INCLUDED_CONNECTIVITY_SOURCE_DRIVERS_FIREBIRD_TABLE_HXX
+#include <sal/config.h>
+
+#include <string_view>
+
#include "Tables.hxx"
#include <connectivity/TTableHelper.hxx>
@@ -31,7 +35,7 @@ namespace connectivity::firebird
* Get the ALTER TABLE [TABLE] ALTER [COLUMN] String.
* Includes a trailing space.
*/
- OUString getAlterTableColumn(const OUString& rColumn);
+ OUString getAlterTableColumn(std::u16string_view rColumn);
protected:
void construct() override;
diff --git a/connectivity/source/drivers/hsqldb/HTable.cxx b/connectivity/source/drivers/hsqldb/HTable.cxx
index f8dee57c510c..0049ff919fc3 100644
--- a/connectivity/source/drivers/hsqldb/HTable.cxx
+++ b/connectivity/source/drivers/hsqldb/HTable.cxx
@@ -269,7 +269,7 @@ void OHSQLTable::alterColumnType(sal_Int32 nNewType,const OUString& _rColName, c
executeStatement(sSql);
}
-void OHSQLTable::alterDefaultValue(const OUString& _sNewDefault,const OUString& _rColName)
+void OHSQLTable::alterDefaultValue(std::u16string_view _sNewDefault,const OUString& _rColName)
{
const OUString sQuote = getMetaData()->getIdentifierQuoteString( );
OUString sSql = getAlterTableColumnPart() +
diff --git a/connectivity/source/drivers/mysql_jdbc/YTable.cxx b/connectivity/source/drivers/mysql_jdbc/YTable.cxx
index 79da47723258..374825d32abb 100644
--- a/connectivity/source/drivers/mysql_jdbc/YTable.cxx
+++ b/connectivity/source/drivers/mysql_jdbc/YTable.cxx
@@ -281,7 +281,7 @@ void OMySQLTable::alterColumnType(sal_Int32 nNewType, const OUString& _rColName,
OUString OMySQLTable::getTypeCreatePattern() const { return "(M,D)"; }
-void OMySQLTable::alterDefaultValue(const OUString& _sNewDefault, const OUString& _rColName)
+void OMySQLTable::alterDefaultValue(std::u16string_view _sNewDefault, const OUString& _rColName)
{
const OUString sQuote = getMetaData()->getIdentifierQuoteString();
OUString sSql = getAlterTableColumnPart() + " ALTER " + ::dbtools::quoteName(sQuote, _rColName)
diff --git a/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx b/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
index 22130ed7c6d8..07e0e85815c1 100644
--- a/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
+++ b/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
@@ -65,6 +65,8 @@
************************************************************************/
#include <algorithm>
+#include <string_view>
+
#include <sal/log.hxx>
#include "pq_databasemetadata.hxx"
#include "pq_driver.hxx"
@@ -2162,12 +2164,12 @@ namespace
return ret;
}
- OUString construct_full_typename(const OUString &ns, const OUString &tn)
+ OUString construct_full_typename(std::u16string_view ns, const OUString &tn)
{
- if(ns.isEmpty() || ns == "pg_catalog")
+ if(ns.empty() || ns == u"pg_catalog")
return tn;
else
- return ns + "." + tn;
+ return OUString::Concat(ns) + "." + tn;
}
void pgTypeInfo2ResultSet(
diff --git a/connectivity/source/drivers/postgresql/pq_statement.cxx b/connectivity/source/drivers/postgresql/pq_statement.cxx
index ff3b05dc8190..946d25b0c91e 100644
--- a/connectivity/source/drivers/postgresql/pq_statement.cxx
+++ b/connectivity/source/drivers/postgresql/pq_statement.cxx
@@ -210,7 +210,7 @@ void Statement::close( )
}
void Statement::raiseSQLException(
- const OUString & sql, const char * errorMsg )
+ std::u16string_view sql, const char * errorMsg )
{
OUString error = "pq_driver: "
+ OUString( errorMsg, strlen(errorMsg), ConnectionSettings::encoding )
diff --git a/connectivity/source/drivers/postgresql/pq_statement.hxx b/connectivity/source/drivers/postgresql/pq_statement.hxx
index 8e93c07b7125..6f9fb3bb1ecc 100644
--- a/connectivity/source/drivers/postgresql/pq_statement.hxx
+++ b/connectivity/source/drivers/postgresql/pq_statement.hxx
@@ -36,6 +36,11 @@
#ifndef INCLUDED_CONNECTIVITY_SOURCE_DRIVERS_POSTGRESQL_PQ_STATEMENT_HXX
#define INCLUDED_CONNECTIVITY_SOURCE_DRIVERS_POSTGRESQL_PQ_STATEMENT_HXX
+
+#include <sal/config.h>
+
+#include <string_view>
+
#include <cppuhelper/propshlp.hxx>
#include <cppuhelper/compbase.hxx>
#include <cppuhelper/component.hxx>
@@ -161,7 +166,7 @@ private:
/// @throws css::uno::RuntimeException
void checkClosed();
/// @throws css::sdbc::SQLException
- void raiseSQLException( const OUString & sql, const char * errorMsg );
+ void raiseSQLException( std::u16string_view sql, const char * errorMsg );
};
diff --git a/connectivity/source/drivers/postgresql/pq_tools.cxx b/connectivity/source/drivers/postgresql/pq_tools.cxx
index 543f042f921e..1bb089a5407a 100644
--- a/connectivity/source/drivers/postgresql/pq_tools.cxx
+++ b/connectivity/source/drivers/postgresql/pq_tools.cxx
@@ -87,9 +87,9 @@ using com::sun::star::container::XEnumerationAccess;
namespace pq_sdbc_driver
{
-OUString concatQualified( const OUString & a, const OUString &b)
+OUString concatQualified( std::u16string_view a, std::u16string_view b)
{
- return a + "." + b;
+ return OUString::Concat(a) + "." + b;
}
static OString iOUStringToOString( std::u16string_view str, ConnectionSettings const *settings) {
diff --git a/connectivity/source/drivers/postgresql/pq_tools.hxx b/connectivity/source/drivers/postgresql/pq_tools.hxx
index 18b105870705..6d11e9b40425 100644
--- a/connectivity/source/drivers/postgresql/pq_tools.hxx
+++ b/connectivity/source/drivers/postgresql/pq_tools.hxx
@@ -63,7 +63,7 @@ namespace pq_sdbc_driver
{
bool isWhitespace( sal_Unicode c );
-OUString concatQualified( const OUString & a, const OUString &b);
+OUString concatQualified( std::u16string_view a, std::u16string_view b);
OString OUStringToOString( std::u16string_view str, ConnectionSettings const *settings);
diff --git a/connectivity/source/inc/hsqldb/HTable.hxx b/connectivity/source/inc/hsqldb/HTable.hxx
index 455a048110fa..ff947cbf484c 100644
--- a/connectivity/source/inc/hsqldb/HTable.hxx
+++ b/connectivity/source/inc/hsqldb/HTable.hxx
@@ -20,6 +20,10 @@
#ifndef INCLUDED_CONNECTIVITY_SOURCE_INC_HSQLDB_HTABLE_HXX
#define INCLUDED_CONNECTIVITY_SOURCE_INC_HSQLDB_HTABLE_HXX
+#include <sal/config.h>
+
+#include <string_view>
+
#include <connectivity/TTableHelper.hxx>
#include <comphelper/IdPropArrayHelper.hxx>
@@ -102,7 +106,7 @@ namespace connectivity::hsqldb
// some methods to alter table structures
void alterColumnType(sal_Int32 nNewType,const OUString& _rColName,const css::uno::Reference< css::beans::XPropertySet >& _xDescriptor);
- void alterDefaultValue(const OUString& _sNewDefault,const OUString& _rColName);
+ void alterDefaultValue(std::u16string_view _sNewDefault,const OUString& _rColName);
void dropDefaultValue(const OUString& _sNewDefault);
};
diff --git a/connectivity/source/inc/mysql/YTable.hxx b/connectivity/source/inc/mysql/YTable.hxx
index a971a9f9c8f1..7df10ead2af3 100644
--- a/connectivity/source/inc/mysql/YTable.hxx
+++ b/connectivity/source/inc/mysql/YTable.hxx
@@ -20,6 +20,10 @@
#ifndef INCLUDED_CONNECTIVITY_SOURCE_INC_MYSQL_YTABLE_HXX
#define INCLUDED_CONNECTIVITY_SOURCE_INC_MYSQL_YTABLE_HXX
+#include <sal/config.h>
+
+#include <string_view>
+
#include <connectivity/TTableHelper.hxx>
#include <comphelper/IdPropArrayHelper.hxx>
@@ -101,7 +105,7 @@ namespace connectivity::mysql
// some methods to alter table structures
void alterColumnType(sal_Int32 nNewType,const OUString& _rColName,const css::uno::Reference< css::beans::XPropertySet >& _xDescriptor);
- void alterDefaultValue(const OUString& _sNewDefault,const OUString& _rColName);
+ void alterDefaultValue(std::u16string_view _sNewDefault,const OUString& _rColName);
void dropDefaultValue(const OUString& _sNewDefault);
virtual OUString getTypeCreatePattern() const override;
diff --git a/connectivity/source/parse/sqlnode.cxx b/connectivity/source/parse/sqlnode.cxx
index 544d14e6491a..77c1306d699d 100644
--- a/connectivity/source/parse/sqlnode.cxx
+++ b/connectivity/source/parse/sqlnode.cxx
@@ -55,6 +55,8 @@
#include <algorithm>
#include <functional>
#include <memory>
+#include <string_view>
+
#include <rtl/ustrbuf.hxx>
#include <sal/log.hxx>
@@ -104,7 +106,7 @@ namespace
@return
The quoted string.
*/
- OUString SetQuotation(const OUString& rValue, const OUString& rQuot, const OUString& rQuotToReplace)
+ OUString SetQuotation(std::u16string_view rValue, const OUString& rQuot, const OUString& rQuotToReplace)
{
OUString rNewValue = rQuot + rValue;
sal_Int32 nIndex = sal_Int32(-1); // Replace quotes with double quotes or the parser gets into problems
diff --git a/cppu/source/uno/lbenv.cxx b/cppu/source/uno/lbenv.cxx
index 93a6a1bb588f..03dbc99eafcc 100644
--- a/cppu/source/uno/lbenv.cxx
+++ b/cppu/source/uno/lbenv.cxx
@@ -118,7 +118,7 @@ struct EnvironmentsData
~EnvironmentsData();
void getEnvironment(
- uno_Environment ** ppEnv, const OUString & rEnvDcp, void * pContext );
+ uno_Environment ** ppEnv, std::u16string_view rEnvDcp, void * pContext );
void registerEnvironment( uno_Environment ** ppEnv );
void getRegisteredEnvironments(
uno_Environment *** pppEnvs, sal_Int32 * pnLen,
@@ -908,7 +908,7 @@ EnvironmentsData::~EnvironmentsData()
void EnvironmentsData::getEnvironment(
- uno_Environment ** ppEnv, const OUString & rEnvDcp, void * pContext )
+ uno_Environment ** ppEnv, std::u16string_view rEnvDcp, void * pContext )
{
if (*ppEnv)
{
diff --git a/cppuhelper/source/servicemanager.cxx b/cppuhelper/source/servicemanager.cxx
index 070f1edd966b..d7eff0b74cf6 100644
--- a/cppuhelper/source/servicemanager.cxx
+++ b/cppuhelper/source/servicemanager.cxx
@@ -1466,7 +1466,7 @@ bool cppuhelper::ServiceManager::readLegacyRdbFile(OUString const & uri) {
}
OUString cppuhelper::ServiceManager::readLegacyRdbString(
- OUString const & uri, RegistryKey & key, OUString const & path)
+ std::u16string_view uri, RegistryKey & key, OUString const & path)
{
RegistryKey subkey;
RegValueType t;
@@ -1477,7 +1477,7 @@ OUString cppuhelper::ServiceManager::readLegacyRdbString(
|| s == 0 || s > o3tl::make_unsigned(SAL_MAX_INT32))
{
throw css::uno::DeploymentException(
- "Failure reading legacy rdb file " + uri,
+ OUString::Concat("Failure reading legacy rdb file ") + uri,
static_cast< cppu::OWeakObject * >(this));
}
OUString val;
@@ -1492,14 +1492,14 @@ OUString cppuhelper::ServiceManager::readLegacyRdbString(
| RTL_TEXTTOUNICODE_FLAGS_INVALID_ERROR)))
{
throw css::uno::DeploymentException(
- "Failure reading legacy rdb file " + uri,
+ OUString::Concat("Failure reading legacy rdb file ") + uri,
static_cast< cppu::OWeakObject * >(this));
}
return val;
}
void cppuhelper::ServiceManager::readLegacyRdbStrings(
- OUString const & uri, RegistryKey & key, OUString const & path,
+ std::u16string_view uri, RegistryKey & key, OUString const & path,
std::vector< OUString > * strings)
{
assert(strings != nullptr);
@@ -1511,14 +1511,14 @@ void cppuhelper::ServiceManager::readLegacyRdbStrings(
return;
default:
throw css::uno::DeploymentException(
- "Failure reading legacy rdb file " + uri,
+ OUString::Concat("Failure reading legacy rdb file ") + uri,
static_cast< cppu::OWeakObject * >(this));
}
OUString prefix(subkey.getName() + "/");
RegistryKeyNames names;
if (subkey.getKeyNames(OUString(), names) != RegError::NO_ERROR) {
throw css::uno::DeploymentException(
- "Failure reading legacy rdb file " + uri,
+ OUString::Concat("Failure reading legacy rdb file ") + uri,
static_cast< cppu::OWeakObject * >(this));
}
for (sal_uInt32 i = 0; i != names.getLength(); ++i) {
diff --git a/cppuhelper/source/servicemanager.hxx b/cppuhelper/source/servicemanager.hxx
index 24a7e56a4ba9..f6a505492be8 100644
--- a/cppuhelper/source/servicemanager.hxx
+++ b/cppuhelper/source/servicemanager.hxx
@@ -14,6 +14,7 @@
#include <cassert>
#include <map>
#include <memory>
+#include <string_view>
#include <vector>
#include <com/sun/star/beans/XPropertySet.hpp>
@@ -321,11 +322,11 @@ private:
bool readLegacyRdbFile(OUString const & uri);
OUString readLegacyRdbString(
- OUString const & uri, RegistryKey & key,
+ std::u16string_view uri, RegistryKey & key,
OUString const & path);
void readLegacyRdbStrings(
- OUString const & uri, RegistryKey & key,
+ std::u16string_view uri, RegistryKey & key,
OUString const & path, std::vector< OUString > * strings);
void insertRdbFiles(
diff --git a/cppuhelper/source/shlib.cxx b/cppuhelper/source/shlib.cxx
index 89ce8b8554db..b0a938a4abac 100644
--- a/cppuhelper/source/shlib.cxx
+++ b/cppuhelper/source/shlib.cxx
@@ -21,6 +21,7 @@
#include <cassert>
#include <cstdlib>
+#include <string_view>
#include <com/sun/star/loader/CannotActivateFactoryException.hpp>
#include <com/sun/star/registry/CannotRegisterImplementationException.hpp>
@@ -112,8 +113,8 @@ extern "C" void getFactory(va_list * args) {
css::uno::Reference<css::uno::XInterface> invokeComponentFactory(
css::uno::Environment const & source, css::uno::Environment const & target,
- component_getFactoryFunc function, OUString const & uri,
- OUString const & implementation,
+ component_getFactoryFunc function, std::u16string_view uri,
+ std::u16string_view implementation,
css::uno::Reference<css::lang::XMultiServiceFactory> const & serviceManager)
{
if (!(source.is() && target.is())) {
@@ -147,7 +148,7 @@ css::uno::Reference<css::uno::XInterface> invokeComponentFactory(
}
if (factory == nullptr) {
throw css::loader::CannotActivateFactoryException(
- ("calling factory function for \"" + implementation + "\" in <"
+ (OUString::Concat("calling factory function for \"") + implementation + "\" in <"
+ uri + "> returned null"),
css::uno::Reference<css::uno::XInterface>());
}
diff --git a/cui/qa/unit/cui-dialogs-test.cxx b/cui/qa/unit/cui-dialogs-test.cxx
index 85f6b5f55bbf..f4f73facbaa6 100644
--- a/cui/qa/unit/cui-dialogs-test.cxx
+++ b/cui/qa/unit/cui-dialogs-test.cxx
@@ -91,7 +91,7 @@ void CuiDialogsTest::openAnyDialog()
initialize();
/// process input file containing the UXMLDescriptions of the dialogs to dump
- processDialogBatchFile("cui/qa/unit/data/cui-dialogs-test.txt");
+ processDialogBatchFile(u"cui/qa/unit/data/cui-dialogs-test.txt");
}
CPPUNIT_TEST_SUITE_REGISTRATION(CuiDialogsTest);
diff --git a/cui/qa/unit/cui-dialogs-test_2.cxx b/cui/qa/unit/cui-dialogs-test_2.cxx
index 2f9b07f7d465..5d98650fd84a 100644
--- a/cui/qa/unit/cui-dialogs-test_2.cxx
+++ b/cui/qa/unit/cui-dialogs-test_2.cxx
@@ -48,7 +48,7 @@ VclPtr<VclAbstractDialog> CuiDialogsTest2::createDialogByID(sal_uInt32 /*nID*/)
void CuiDialogsTest2::openAnyDialog()
{
/// process input file containing the UXMLDescriptions of the dialogs to dump
- processDialogBatchFile("cui/qa/unit/data/cui-dialogs-test_2.txt");
+ processDialogBatchFile(u"cui/qa/unit/data/cui-dialogs-test_2.txt");
}
CPPUNIT_TEST_SUITE_REGISTRATION(CuiDialogsTest2);
diff --git a/cui/qa/unit/cui-dialogs-test_3.cxx b/cui/qa/unit/cui-dialogs-test_3.cxx
index 9c3a09a8d240..ebd194885415 100644
--- a/cui/qa/unit/cui-dialogs-test_3.cxx
+++ b/cui/qa/unit/cui-dialogs-test_3.cxx
@@ -48,7 +48,7 @@ VclPtr<VclAbstractDialog> CuiDialogsTest3::createDialogByID(sal_uInt32 /*nID*/)
void CuiDialogsTest3::openAnyDialog()
{
/// process input file containing the UXMLDescriptions of the dialogs to dump
- processDialogBatchFile("cui/qa/unit/data/cui-dialogs-test_3.txt");
+ processDialogBatchFile(u"cui/qa/unit/data/cui-dialogs-test_3.txt");
}
CPPUNIT_TEST_SUITE_REGISTRATION(CuiDialogsTest3);
diff --git a/cui/qa/unit/cui-dialogs-test_4.cxx b/cui/qa/unit/cui-dialogs-test_4.cxx
index 11820389968c..157ffa8b3765 100644
--- a/cui/qa/unit/cui-dialogs-test_4.cxx
+++ b/cui/qa/unit/cui-dialogs-test_4.cxx
@@ -48,7 +48,7 @@ VclPtr<VclAbstractDialog> CuiDialogsTest4::createDialogByID(sal_uInt32 /*nID*/)
void CuiDialogsTest4::openAnyDialog()
{
/// process input file containing the UXMLDescriptions of the dialogs to dump
- processDialogBatchFile("cui/qa/unit/data/cui-dialogs-test_4.txt");
+ processDialogBatchFile(u"cui/qa/unit/data/cui-dialogs-test_4.txt");
}
CPPUNIT_TEST_SUITE_REGISTRATION(CuiDialogsTest4);
diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index 3d786af57553..0988fca71feb 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -1355,13 +1355,13 @@ void SvxConfigPage::ReloadTopLevelListBox( SvxConfigEntry const * pToSelect )
}
void SvxConfigPage::AddSubMenusToUI(
- const OUString& rBaseTitle, SvxConfigEntry const * pParentData )
+ std::u16string_view rBaseTitle, SvxConfigEntry const * pParentData )
{
for (auto const& entryData : *pParentData->GetEntries())
{
if (entryData->IsPopup())
{
- OUString subMenuTitle = rBaseTitle + aMenuSeparatorStr + SvxConfigPageHelper::stripHotKey(entryData->GetName());
+ OUString subMenuTitle = OUString::Concat(rBaseTitle) + aMenuSeparatorStr + SvxConfigPageHelper::stripHotKey(entryData->GetName());
OUString sId(OUString::number(reinterpret_cast<sal_Int64>(entryData)));
m_xTopLevelListBox->append(sId, subMenuTitle);
diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx
index e538bc25bcee..6c81c18fb573 100644
--- a/cui/source/customize/cfgutil.cxx
+++ b/cui/source/customize/cfgutil.cxx
@@ -76,9 +76,10 @@ const char CMDURL_FPART_ONLY [] = "FamilyName:string=";
const OUStringLiteral STYLEPROP_UINAME = u"DisplayName";
-OUString SfxStylesInfo_Impl::generateCommand(const OUString& sFamily, const OUString& sStyle)
+OUString SfxStylesInfo_Impl::generateCommand(
+ std::u16string_view sFamily, std::u16string_view sStyle)
{
- return ".uno:StyleApply?Style:string="
+ return OUString::Concat(".uno:StyleApply?Style:string=")
+ sStyle
+ "&FamilyName:string="
+ sFamily;
@@ -999,10 +1000,10 @@ void CuiConfigGroupListBox::SelectMacro( const SfxMacroInfoItem *pItem )
pItem->GetQualifiedName() );
}
-void CuiConfigGroupListBox::SelectMacro( const OUString& rBasic,
+void CuiConfigGroupListBox::SelectMacro( std::u16string_view rBasic,
const OUString& rMacro )
{
- const OUString aBasicName(rBasic + " " + xImp->m_sMacros);
+ const OUString aBasicName(OUString::Concat(rBasic) + " " + xImp->m_sMacros);
sal_Int32 nIdx {rMacro.lastIndexOf('.')};
const OUString aMethod( rMacro.copy(nIdx+1) );
OUString aLib;
diff --git a/cui/source/dialogs/SignatureLineDialogBase.cxx b/cui/source/dialogs/SignatureLineDialogBase.cxx
index d824e85e8e3e..4e591124bc44 100644
--- a/cui/source/dialogs/SignatureLineDialogBase.cxx
+++ b/cui/source/dialogs/SignatureLineDialogBase.cxx
@@ -32,9 +32,9 @@ short SignatureLineDialogBase::run()
return nRet;
}
-OUString SignatureLineDialogBase::getCDataString(const OUString& rString)
+OUString SignatureLineDialogBase::getCDataString(std::u16string_view rString)
{
- return "<![CDATA[" + rString + "]]>";
+ return OUString::Concat("<![CDATA[") + rString + "]]>";
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/cui/source/dialogs/cuigaldlg.cxx b/cui/source/dialogs/cuigaldlg.cxx
index 76abb324b583..eae624c7e0db 100644
--- a/cui/source/dialogs/cuigaldlg.cxx
+++ b/cui/source/dialogs/cuigaldlg.cxx
@@ -645,12 +645,12 @@ std::unique_ptr<SfxTabPage> TPGalleryThemeProperties::Create(weld::Container* pP
return std::make_unique<TPGalleryThemeProperties>(pPage, pController, *rSet);
}
-OUString TPGalleryThemeProperties::addExtension( const OUString& _rDisplayText, const OUString& _rExtension )
+OUString TPGalleryThemeProperties::addExtension( const OUString& _rDisplayText, std::u16string_view _rExtension )
{
OUString sRet = _rDisplayText;
if ( sRet.indexOf( "(*.*)" ) == -1 )
{
- sRet += " (" + _rExtension + ")";
+ sRet += OUString::Concat(" (") + _rExtension + ")";
}
return sRet;
}
diff --git a/cui/source/dialogs/postdlg.cxx b/cui/source/dialogs/postdlg.cxx
index b96c1dd85fbf..fe9f2e065bf3 100644
--- a/cui/source/dialogs/postdlg.cxx
+++ b/cui/source/dialogs/postdlg.cxx
@@ -110,9 +110,9 @@ SvxPostItDialog::~SvxPostItDialog()
{
}
-void SvxPostItDialog::ShowLastAuthor(const OUString& rAuthor, const OUString& rDate)
+void SvxPostItDialog::ShowLastAuthor(std::u16string_view rAuthor, std::u16string_view rDate)
{
- OUString sTxt = rAuthor + ", " + rDate;
+ OUString sTxt = OUString::Concat(rAuthor) + ", " + rDate;
m_xLastEditFT->set_label( sTxt );
}
diff --git a/cui/source/dialogs/screenshotannotationdlg.cxx b/cui/source/dialogs/screenshotannotationdlg.cxx
index 676dda6bca55..fd378f7686f1 100644
--- a/cui/source/dialogs/screenshotannotationdlg.cxx
+++ b/cui/source/dialogs/screenshotannotationdlg.cxx
@@ -49,7 +49,7 @@ using namespace com::sun::star;
namespace
{
- OUString lcl_genRandom( const OUString &rId )
+ OUString lcl_genRandom( std::u16string_view rId )
{
//FIXME: plus timestamp
unsigned int nRand = comphelper::rng::uniform_uint_distribution(0, 0xFFFF);
@@ -62,7 +62,7 @@ namespace
OUString aTempl("<alt id=\"%1\">"
" " //FIXME real dialog title or something
"</alt>");
- aTempl = aTempl.replaceFirst( "%1", lcl_genRandom("alt_id") );
+ aTempl = aTempl.replaceFirst( "%1", lcl_genRandom(u"alt_id") );
return aTempl;
}
@@ -73,7 +73,7 @@ namespace
" width=\"%3cm\" height=\"%4cm\">"
"%5"
"</image>");
- aTempl = aTempl.replaceFirst( "%1", lcl_genRandom("img_id") );
+ aTempl = aTempl.replaceFirst( "%1", lcl_genRandom(u"img_id") );
aTempl = aTempl.replaceFirst( "%2", rScreenshotId );
aTempl = aTempl.replaceFirst( "%3", OUString::number( rSize.Width() ) );
aTempl = aTempl.replaceFirst( "%4", OUString::number( rSize.Height() ) );
@@ -86,7 +86,7 @@ namespace
{
OUString aTempl( "<paragraph id=\"%1\" role=\"paragraph\">%2"
"</paragraph>" SAL_NEWLINE_STRING );
- aTempl = aTempl.replaceFirst( "%1", lcl_genRandom("par_id") );
+ aTempl = aTempl.replaceFirst( "%1", lcl_genRandom(u"par_id") );
aTempl = aTempl.replaceFirst( "%2", lcl_Image(rScreenshotId, rSize) );
return aTempl;
@@ -98,7 +98,7 @@ namespace
"<bookmark branch=\"hid/%2\" id=\"%3\" localize=\"false\"/>" SAL_NEWLINE_STRING;
aTempl = aTempl.replaceFirst( "%1", rWidgetId );
aTempl = aTempl.replaceFirst( "%2", rWidgetId );
- aTempl = aTempl.replaceFirst( "%3", lcl_genRandom("bm_id") );
+ aTempl = aTempl.replaceFirst( "%3", lcl_genRandom(u"bm_id") );
return aTempl;
}
diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx
index cb7d8776dcbd..824aaa0c81d8 100644
--- a/cui/source/dialogs/scriptdlg.cxx
+++ b/cui/source/dialogs/scriptdlg.cxx
@@ -18,6 +18,7 @@
*/
#include <memory>
+#include <string_view>
#include <utility>
#include <sfx2/objsh.hxx>
@@ -1106,8 +1107,8 @@ OUString FormatErrorString(
const OUString& language,
const OUString& script,
const OUString& line,
- const OUString& type,
- const OUString& message )
+ std::u16string_view type,
+ std::u16string_view message )
{
OUString result = unformatted.copy( 0 );
@@ -1115,12 +1116,12 @@ OUString FormatErrorString(
result = ReplaceString(result, "%SCRIPTNAME", script );
result = ReplaceString(result, "%LINENUMBER", line );
- if ( !type.isEmpty() )
+ if ( !type.empty() )
{
result += "\n\n" + CuiResId(RID_SVXSTR_ERROR_TYPE_LABEL) + " " + type;
}
- if ( !message.isEmpty() )
+ if ( !message.empty() )
{
result += "\n\n" + CuiResId(RID_SVXSTR_ERROR_MESSAGE_LABEL) + " " + message;
}
@@ -1164,7 +1165,7 @@ OUString GetErrorMessage(
}
return FormatErrorString(
- unformatted, language, script, line, "", message );
+ unformatted, language, script, line, u"", message );
}
OUString GetErrorMessage(
@@ -1243,7 +1244,7 @@ OUString GetErrorMessage(
message = sError.Message;
}
return FormatErrorString(
- unformatted, language, script, OUString(), OUString(), message );
+ unformatted, language, script, OUString(), std::u16string_view(), message );
}
OUString GetErrorMessage( const css::uno::Any& aException )
diff --git a/cui/source/inc/SignatureLineDialogBase.hxx b/cui/source/inc/SignatureLineDialogBase.hxx
index 2fe0e95d1fec..3cc645819be8 100644
--- a/cui/source/inc/SignatureLineDialogBase.hxx
+++ b/cui/source/inc/SignatureLineDialogBase.hxx
@@ -8,6 +8,10 @@
*/
#pragma once
+#include <sal/config.h>
+
+#include <string_view>
+
#include <vcl/weld.hxx>
#include <com/sun/star/frame/XModel.hpp>
@@ -24,7 +28,7 @@ public:
protected:
css::uno::Reference<css::frame::XModel> m_xModel;
virtual void Apply() = 0;
- static OUString getCDataString(const OUString& rString);
+ static OUString getCDataString(std::u16string_view rString);
};
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/cui/source/inc/cfg.hxx b/cui/source/inc/cfg.hxx
index 4fd7fb801ebc..32e19e3bd774 100644
--- a/cui/source/inc/cfg.hxx
+++ b/cui/source/inc/cfg.hxx
@@ -34,6 +34,7 @@
#include <sfx2/tabdlg.hxx>
#include <memory>
+#include <string_view>
#include <vector>
#include "cfgutil.hxx"
@@ -446,7 +447,7 @@ protected:
int AppendEntry(SvxConfigEntry* pNewEntryData,
int nTarget);
- void AddSubMenusToUI( const OUString& rBaseTitle,
+ void AddSubMenusToUI( std::u16string_view rBaseTitle,
SvxConfigEntry const * pParentData );
void InsertEntryIntoUI(SvxConfigEntry* pNewEntryData,
diff --git a/cui/source/inc/cfgutil.hxx b/cui/source/inc/cfgutil.hxx
index 8187d5e14314..bd4e8e8e2d76 100644
--- a/cui/source/inc/cfgutil.hxx
+++ b/cui/source/inc/cfgutil.hxx
@@ -20,6 +20,8 @@
#include <vector>
#include <memory>
+#include <string_view>
+
#include <rtl/ustring.hxx>
#include <com/sun/star/frame/DispatchInformation.hpp>
@@ -70,7 +72,7 @@ public:
std::vector< SfxStyleInfo_Impl > getStyleFamilies() const;
std::vector< SfxStyleInfo_Impl > getStyles(const OUString& sFamily);
- static OUString generateCommand(const OUString& sFamily, const OUString& sStyle);
+ static OUString generateCommand(std::u16string_view sFamily, std::u16string_view sStyle);
};
enum class SfxCfgKind
@@ -223,7 +225,7 @@ public:
{ m_pFunctionListBox = pBox; }
void GroupSelected();
void SelectMacro(const SfxMacroInfoItem*);
- void SelectMacro(const OUString&, const OUString&);
+ void SelectMacro(std::u16string_view, const OUString&);
void SetStylesInfo(SfxStylesInfo_Impl* pStyles);
};
diff --git a/cui/source/inc/cuigaldlg.hxx b/cui/source/inc/cuigaldlg.hxx
index c89acbfc1294..4a20724ffd81 100644
--- a/cui/source/inc/cuigaldlg.hxx
+++ b/cui/source/inc/cuigaldlg.hxx
@@ -30,6 +30,8 @@
#include <com/sun/star/media/XPlayer.hpp>
#include <com/sun/star/ui/dialogs/XFolderPicker2.hpp>
#include <svtools/dialogclosedlistener.hxx>
+
+#include <string_view>
#include <vector>
class GalleryTheme;
@@ -241,7 +243,7 @@ class TPGalleryThemeProperties : public SfxTabPage
virtual void Reset( const SfxItemSet* /*rSet*/ ) override {}
virtual bool FillItemSet( SfxItemSet* /*rSet*/ ) override { return true; }
- static OUString addExtension( const OUString&, const OUString& );
+ static OUString addExtension( const OUString&, std::u16string_view );
void FillFilterList();
void SearchFiles();
diff --git a/cui/source/inc/postdlg.hxx b/cui/source/inc/postdlg.hxx
index 206dbdb181bf..b294fbcc77df 100644
--- a/cui/source/inc/postdlg.hxx
+++ b/cui/source/inc/postdlg.hxx
@@ -18,6 +18,10 @@
*/
#pragma once
+#include <sal/config.h>
+
+#include <string_view>
+
#include <sfx2/basedlgs.hxx>
// class SvxPostItDialog -------------------------------------------------
@@ -57,7 +61,7 @@ public:
{
m_xEditED->set_text(rTxt);
}
- void ShowLastAuthor(const OUString& rAuthor, const OUString& rDate);
+ void ShowLastAuthor(std::u16string_view rAuthor, std::u16string_view rDate);
void DontChangeAuthor()
{
m_xAuthorBtn->set_sensitive(false);
diff --git a/cui/source/options/optsave.cxx b/cui/source/options/optsave.cxx
index 74b6f408d249..f2d54205db5c 100644
--- a/cui/source/options/optsave.cxx
+++ b/cui/source/options/optsave.cxx
@@ -17,6 +17,10 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <sal/config.h>
+
+#include <string_view>
+
#include <svl/eitem.hxx>
#include <svl/intitem.hxx>
#include "optsave.hxx"
@@ -44,7 +48,7 @@ using namespace com::sun::star::beans;
using namespace com::sun::star::container;
using namespace comphelper;
-#define CFG_PAGE_AND_GROUP "General", "LoadSave"
+#define CFG_PAGE_AND_GROUP u"General", u"LoadSave"
struct SvxSaveTabPage_Impl
@@ -191,13 +195,13 @@ void SvxSaveTabPage::DetectHiddenControls()
{
SvtOptionsDialogOptions aOptionsDlgOpt;
- if ( aOptionsDlgOpt.IsOptionHidden( "Backup", CFG_PAGE_AND_GROUP ) )
+ if ( aOptionsDlgOpt.IsOptionHidden( u"Backup", CFG_PAGE_AND_GROUP ) )
{
// hide controls of "Backup"
m_xBackupCB->hide();
}
- if ( aOptionsDlgOpt.IsOptionHidden( "AutoSave", CFG_PAGE_AND_GROUP ) )
+ if ( aOptionsDlgOpt.IsOptionHidden( u"AutoSave", CFG_PAGE_AND_GROUP ) )
{
// hide controls of "AutoSave"
m_xAutoSaveCB->hide();
@@ -205,7 +209,7 @@ void SvxSaveTabPage::DetectHiddenControls()
m_xMinuteFT->hide();
}
- if ( aOptionsDlgOpt.IsOptionHidden( "UserAutoSave", CFG_PAGE_AND_GROUP ) )
+ if ( aOptionsDlgOpt.IsOptionHidden( u"UserAutoSave", CFG_PAGE_AND_GROUP ) )
{
// hide controls of "UserAutoSave"
m_xUserAutoSaveCB->hide();
@@ -485,7 +489,7 @@ IMPL_LINK(SvxSaveTabPage, AutoClickHdl_Impl, weld::Button&, rBox, void)
}
}
-static OUString lcl_ExtracUIName(const Sequence<PropertyValue> &rProperties, const OUString& rExtension)
+static OUString lcl_ExtracUIName(const Sequence<PropertyValue> &rProperties, std::u16string_view rExtension)
{
OUString sName;
const PropertyValue* pPropVal = rProperties.getConstArray();
@@ -498,7 +502,7 @@ static OUString lcl_ExtracUIName(const Sequence<PropertyValue> &rProperties, con
OUString sUIName;
if ( ( pPropVal->Value >>= sUIName ) && sUIName.getLength() )
{
- if (!rExtension.isEmpty())
+ if (!rExtension.empty())
{
return sUIName + " (" + rExtension + ")";
}
diff --git a/dbaccess/qa/extras/dialog-save.cxx b/dbaccess/qa/extras/dialog-save.cxx
index af7b9fda3f8e..5eac41e67041 100644
--- a/dbaccess/qa/extras/dialog-save.cxx
+++ b/dbaccess/qa/extras/dialog-save.cxx
@@ -55,7 +55,7 @@ void DialogSaveTest::test()
// be locked anyway:
SolarMutexReleaser rel;
- const OUString aFileName(m_directories.getURLFromWorkdir("CppunitTest/testDialogSave.odb"));
+ const OUString aFileName(m_directories.getURLFromWorkdir(u"CppunitTest/testDialogSave.odb"));
{
uno::Reference< lang::XComponent > xComponent = loadFromDesktop(aFileName);
CPPUNIT_ASSERT(xComponent.is());
diff --git a/dbaccess/qa/extras/empty-stdlib-save.cxx b/dbaccess/qa/extras/empty-stdlib-save.cxx
index ea9c660a4e87..aa7dd293004f 100644
--- a/dbaccess/qa/extras/empty-stdlib-save.cxx
+++ b/dbaccess/qa/extras/empty-stdlib-save.cxx
@@ -53,7 +53,7 @@ void DialogSaveTest::test()
// be locked anyway:
SolarMutexReleaser rel;
- const OUString aFileName(m_directories.getURLFromWorkdir("CppunitTest/testEmptyStdlibSave.odb"));
+ const OUString aFileName(m_directories.getURLFromWorkdir(u"CppunitTest/testEmptyStdlibSave.odb"));
{
uno::Reference< lang::XComponent > xComponent = loadFromDesktop(aFileName);
CPPUNIT_ASSERT(xComponent.is());
diff --git a/dbaccess/qa/extras/macros-test.cxx b/dbaccess/qa/extras/macros-test.cxx
index 5d65133664b3..e102c75896b3 100644
--- a/dbaccess/qa/extras/macros-test.cxx
+++ b/dbaccess/qa/extras/macros-test.cxx
@@ -35,7 +35,7 @@ DBAccessTest::DBAccessTest()
void DBAccessTest::test()
{
OUString aFileName;
- createFileURL("testdb.odb", aFileName);
+ createFileURL(u"testdb.odb", aFileName);
uno::Reference<lang::XComponent> xComponent = loadFromDesktop(aFileName);
CPPUNIT_ASSERT(xComponent.is());
xComponent->dispose();
diff --git a/dbaccess/qa/extras/nolib-save.cxx b/dbaccess/qa/extras/nolib-save.cxx
index 5914511e6dbe..e191402425f9 100644
--- a/dbaccess/qa/extras/nolib-save.cxx
+++ b/dbaccess/qa/extras/nolib-save.cxx
@@ -53,7 +53,7 @@ void DialogSaveTest::test()
// be locked anyway:
SolarMutexReleaser rel;
- const OUString aFileName(m_directories.getURLFromWorkdir("CppunitTest/testNolibSave.odb"));
+ const OUString aFileName(m_directories.getURLFromWorkdir(u"CppunitTest/testNolibSave.odb"));
{
uno::Reference< lang::XComponent > xComponent = loadFromDesktop(aFileName);
CPPUNIT_ASSERT(xComponent.is());
diff --git a/dbaccess/qa/extras/rowsetclones.cxx b/dbaccess/qa/extras/rowsetclones.cxx
index f62314205be3..d4637c5d8ae6 100644
--- a/dbaccess/qa/extras/rowsetclones.cxx
+++ b/dbaccess/qa/extras/rowsetclones.cxx
@@ -48,7 +48,7 @@ RowSetClones::RowSetClones()
void RowSetClones::test()
{
- const OUString sFilePath(m_directories.getURLFromWorkdir("CppunitTest/RowSetClones.odb"));
+ const OUString sFilePath(m_directories.getURLFromWorkdir(u"CppunitTest/RowSetClones.odb"));
uno::Reference< lang::XComponent > xComponent (loadFromDesktop(sFilePath));
CPPUNIT_ASSERT(xComponent.is());
diff --git a/dbaccess/qa/unit/dbaccess-dialogs-test.cxx b/dbaccess/qa/unit/dbaccess-dialogs-test.cxx
index 49eff86ecd9a..0551b31187a5 100644
--- a/dbaccess/qa/unit/dbaccess-dialogs-test.cxx
+++ b/dbaccess/qa/unit/dbaccess-dialogs-test.cxx
@@ -51,7 +51,7 @@ VclPtr<VclAbstractDialog> DbaccessDialogsTest::createDialogByID(sal_uInt32 /*nID
void DbaccessDialogsTest::openAnyDialog()
{
/// process input file containing the UXMLDescriptions of the dialogs to dump
- processDialogBatchFile("dbaccess/qa/unit/data/dbaccess-dialogs-test.txt");
+ processDialogBatchFile(u"dbaccess/qa/unit/data/dbaccess-dialogs-test.txt");
}
CPPUNIT_TEST_SUITE_REGISTRATION(DbaccessDialogsTest);
diff --git a/dbaccess/qa/unit/dbtest_base.cxx b/dbaccess/qa/unit/dbtest_base.cxx
index f0b276cbb1ea..caee25fa70ac 100644
--- a/dbaccess/qa/unit/dbtest_base.cxx
+++ b/dbaccess/qa/unit/dbtest_base.cxx
@@ -9,6 +9,8 @@
#include <sal/config.h>
+#include <string_view>
+
#include <cppunit/TestAssert.h>
#include <test/unoapi_test.hxx>
@@ -28,10 +30,10 @@ class DBTestBase
public:
DBTestBase() : UnoApiTest("dbaccess/qa/unit/data") {};
- utl::TempFile createTempCopy(OUString const & pathname);
+ utl::TempFile createTempCopy(std::u16string_view pathname);
uno::Reference< XOfficeDatabaseDocument >
- getDocumentForFileName(const OUString &sFileName);
+ getDocumentForFileName(std::u16string_view sFileName);
uno::Reference<XOfficeDatabaseDocument> getDocumentForUrl(OUString const & url);
@@ -40,7 +42,7 @@ public:
uno::Reference< XOfficeDatabaseDocument > const & xDocument);
};
-utl::TempFile DBTestBase::createTempCopy(OUString const & pathname) {
+utl::TempFile DBTestBase::createTempCopy(std::u16string_view pathname) {
OUString url;
createFileURL(pathname, url);
utl::TempFile tmp;
@@ -56,7 +58,7 @@ utl::TempFile DBTestBase::createTempCopy(OUString const & pathname) {
}
uno::Reference< XOfficeDatabaseDocument >
- DBTestBase::getDocumentForFileName(const OUString &sFileName)
+ DBTestBase::getDocumentForFileName(std::u16string_view sFileName)
{
OUString sFilePath;
createFileURL(sFileName, sFilePath);
diff --git a/dbaccess/qa/unit/embeddeddb_performancetest.cxx b/dbaccess/qa/unit/embeddeddb_performancetest.cxx
index abd72db66fe4..e4119804d3b1 100644
--- a/dbaccess/qa/unit/embeddeddb_performancetest.cxx
+++ b/dbaccess/qa/unit/embeddeddb_performancetest.cxx
@@ -125,7 +125,7 @@ public:
SvFileStream* EmbeddedDBPerformanceTest::getWordListStream()
{
OUString wlPath;
- createFileURL("wordlist", wlPath);
+ createFileURL(u"wordlist", wlPath);
return new SvFileStream(wlPath, StreamMode::READ);
}
diff --git a/dbaccess/qa/unit/firebird-regression.cxx b/dbaccess/qa/unit/firebird-regression.cxx
index faf0a834b9c4..d5c53b93a64d 100644
--- a/dbaccess/qa/unit/firebird-regression.cxx
+++ b/dbaccess/qa/unit/firebird-regression.cxx
@@ -43,7 +43,7 @@ void FirebirdTest::testEmptyDBConnection()
#ifdef OSL_BIGENDIAN
auto const tmp = createTempCopy("firebird_empty_be.odb");
#else
- auto const tmp = createTempCopy("firebird_empty_le.odb");
+ auto const tmp = createTempCopy(u"firebird_empty_le.odb");
#endif
uno::Reference< XOfficeDatabaseDocument > xDocument =
getDocumentForUrl(tmp.GetURL());
@@ -64,7 +64,7 @@ void FirebirdTest::testIntegerDatabase()
getDocumentForFileName("firebird_integer_be_ods12.odb");
#else
uno::Reference< XOfficeDatabaseDocument > xDocument =
- getDocumentForFileName("firebird_integer_le_ods12.odb");
+ getDocumentForFileName(u"firebird_integer_le_ods12.odb");
#endif
uno::Reference< XConnection > xConnection =
diff --git a/dbaccess/qa/unit/firebird.cxx b/dbaccess/qa/unit/firebird.cxx
index 95581332466a..e67a4d10c097 100644
--- a/dbaccess/qa/unit/firebird.cxx
+++ b/dbaccess/qa/unit/firebird.cxx
@@ -40,7 +40,7 @@ public:
*/
void FirebirdTest::testEmptyDBConnection()
{
- auto const tmp = createTempCopy("firebird_empty.odb");
+ auto const tmp = createTempCopy(u"firebird_empty.odb");
uno::Reference< XOfficeDatabaseDocument > xDocument =
getDocumentForUrl(tmp.GetURL());
@@ -56,7 +56,7 @@ void FirebirdTest::testEmptyDBConnection()
void FirebirdTest::testIntegerDatabase()
{
uno::Reference< XOfficeDatabaseDocument > xDocument =
- getDocumentForFileName("firebird_integer_ods12.odb");
+ getDocumentForFileName(u"firebird_integer_ods12.odb");
uno::Reference< XConnection > xConnection =
getConnectionForDocument(xDocument);
diff --git a/dbaccess/qa/unit/hsql_binary_import.cxx b/dbaccess/qa/unit/hsql_binary_import.cxx
index 842e03e74621..4eac0cdc4130 100644
--- a/dbaccess/qa/unit/hsql_binary_import.cxx
+++ b/dbaccess/qa/unit/hsql_binary_import.cxx
@@ -46,7 +46,7 @@ void HsqlBinaryImportTest::testBinaryImport()
}
// the migration requires the file to be writable
- utl::TempFile const temp(createTempCopy("hsqldb_migration_test.odb"));
+ utl::TempFile const temp(createTempCopy(u"hsqldb_migration_test.odb"));
uno::Reference<XOfficeDatabaseDocument> const xDocument = getDocumentForUrl(temp.GetURL());
uno::Reference<XConnection> xConnection = getConnectionForDocument(xDocument);
diff --git a/dbaccess/qa/unit/hsqldb.cxx b/dbaccess/qa/unit/hsqldb.cxx
index 0e3c2494bc5b..5ee011af276e 100644
--- a/dbaccess/qa/unit/hsqldb.cxx
+++ b/dbaccess/qa/unit/hsqldb.cxx
@@ -32,7 +32,7 @@ public:
*/
void HSQLDBTest::testEmptyDBConnection()
{
- auto const file = createTempCopy("hsqldb_empty.odb");
+ auto const file = createTempCopy(u"hsqldb_empty.odb");
uno::Reference<XOfficeDatabaseDocument> xDocument = getDocumentForUrl(file.GetURL());
getConnectionForDocument(xDocument);
diff --git a/dbaccess/qa/unit/tdf119625.cxx b/dbaccess/qa/unit/tdf119625.cxx
index 632089f94e9e..22fb5849305e 100644
--- a/dbaccess/qa/unit/tdf119625.cxx
+++ b/dbaccess/qa/unit/tdf119625.cxx
@@ -66,7 +66,7 @@ void Tdf119625Test::testTime()
}
// the migration requires the file to be writable
- utl::TempFile const temp(createTempCopy("tdf119625.odb"));
+ utl::TempFile const temp(createTempCopy(u"tdf119625.odb"));
uno::Reference<XOfficeDatabaseDocument> const xDocument = getDocumentForUrl(temp.GetURL());
uno::Reference<XConnection> xConnection = getConnectionForDocument(xDocument);
diff --git a/dbaccess/qa/unit/tdf126268.cxx b/dbaccess/qa/unit/tdf126268.cxx
index 5cba7c1923f7..a4ed9dc3b868 100644
--- a/dbaccess/qa/unit/tdf126268.cxx
+++ b/dbaccess/qa/unit/tdf126268.cxx
@@ -60,7 +60,7 @@ void Tdf126268Test::testNumbers()
}
// the migration requires the file to be writable
- utl::TempFile const temp(createTempCopy("tdf126268.odb"));
+ utl::TempFile const temp(createTempCopy(u"tdf126268.odb"));
uno::Reference<XOfficeDatabaseDocument> const xDocument = getDocumentForUrl(temp.GetURL());
uno::Reference<XConnection> xConnection = getConnectionForDocument(xDocument);
diff --git a/dbaccess/source/core/api/KeySet.cxx b/dbaccess/source/core/api/KeySet.cxx
index 21c1ff0ef9a7..e61259bf61b1 100644
--- a/dbaccess/source/core/api/KeySet.cxx
+++ b/dbaccess/source/core/api/KeySet.cxx
@@ -18,6 +18,8 @@
*/
#include <memory>
+#include <string_view>
+
#include "KeySet.hxx"
#include <sal/log.hxx>
#include <core_resource.hxx>
@@ -209,13 +211,13 @@ void OKeySet::findTableColumnsMatching_throw( const Any& i_aTable,
namespace
{
- void appendOneKeyColumnClause( const OUString &tblName, const OUString &colName, const connectivity::ORowSetValue &_rValue, OUStringBuffer &o_buf )
+ void appendOneKeyColumnClause( std::u16string_view tblName, const OUString &colName, const connectivity::ORowSetValue &_rValue, OUStringBuffer &o_buf )
{
OUString fullName;
- if (tblName.isEmpty())
+ if (tblName.empty())
fullName = colName;
else
- fullName = tblName + "." + colName;
+ fullName = OUString::Concat(tblName) + "." + colName;
if ( _rValue.isNull() )
{
o_buf.append(fullName).append(" IS NULL ");
diff --git a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
index 6ca83d6d9879..f3f401b3cb99 100644
--- a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
+++ b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
@@ -611,7 +611,7 @@ void SAL_CALL OSingleSelectQueryComposer::setElementaryQuery( const OUString& _r
namespace
{
OUString getComposedClause( const OUString& _rElementaryClause, const OUString& _rAdditionalClause,
- TokenComposer& _rComposer, const OUString& _rKeyword )
+ TokenComposer& _rComposer, std::u16string_view _rKeyword )
{
_rComposer.clear();
_rComposer.append( _rElementaryClause );
diff --git a/dbaccess/source/filter/hsqldb/parseschema.cxx b/dbaccess/source/filter/hsqldb/parseschema.cxx
index e1d794cdca8b..3e615428f2d4 100644
--- a/dbaccess/source/filter/hsqldb/parseschema.cxx
+++ b/dbaccess/source/filter/hsqldb/parseschema.cxx
@@ -17,6 +17,10 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <sal/config.h>
+
+#include <string_view>
+
#include "parseschema.hxx"
#include "fbcreateparser.hxx"
#include "fbalterparser.hxx"
@@ -89,9 +93,9 @@ public:
}
};
-OUString lcl_createAlterForeign(const OUString& sForeignPart, const OUString& sTableName)
+OUString lcl_createAlterForeign(std::u16string_view sForeignPart, std::u16string_view sTableName)
{
- return "ALTER TABLE " + sTableName + " ADD " + sForeignPart;
+ return OUString::Concat("ALTER TABLE ") + sTableName + " ADD " + sForeignPart;
}
} // anonymous namespace
diff --git a/dbaccess/source/ui/app/DocumentInfoPreview.cxx b/dbaccess/source/ui/app/DocumentInfoPreview.cxx
index d112c7fb0427..d00a77899572 100644
--- a/dbaccess/source/ui/app/DocumentInfoPreview.cxx
+++ b/dbaccess/source/ui/app/DocumentInfoPreview.cxx
@@ -117,13 +117,13 @@ namespace
}
void ODocumentInfoPreview::insertEntry(
- OUString const & title, OUString const & value)
+ std::u16string_view title, OUString const & value)
{
if (!m_xEditEngine->GetText().isEmpty()) {
m_xEditEngine->QuickInsertText("\n\n", InsertAtEnd(*m_xEditEngine));
}
- OUString caption(title + ":\n");
+ OUString caption(OUString::Concat(title) + ":\n");
m_xEditEngine->QuickInsertText(caption, InsertAtEnd(*m_xEditEngine));
SfxItemSet aSet(m_xEditEngine->GetEmptyItemSet());
diff --git a/dbaccess/source/ui/app/DocumentInfoPreview.hxx b/dbaccess/source/ui/app/DocumentInfoPreview.hxx
index 9fb69af4d0f3..0c9548d0a759 100644
--- a/dbaccess/source/ui/app/DocumentInfoPreview.hxx
+++ b/dbaccess/source/ui/app/DocumentInfoPreview.hxx
@@ -20,6 +20,9 @@
#pragma once
#include <sal/config.h>
+
+#include <string_view>
+
#include <svx/weldeditview.hxx>
namespace com :: sun :: star :: uno { template <typename > class Reference; }
@@ -44,7 +47,7 @@ public:
void fill(css::uno::Reference< css::document::XDocumentProperties > const & xDocProps);
private:
- void insertEntry(OUString const & title, OUString const & value);
+ void insertEntry(std::u16string_view title, OUString const & value);
void insertNonempty(tools::Long id, OUString const & value);
diff --git a/dbaccess/source/ui/dlg/directsql.cxx b/dbaccess/source/ui/dlg/directsql.cxx
index ffd174ba1d29..fc8191707c44 100644
--- a/dbaccess/source/ui/dlg/directsql.cxx
+++ b/dbaccess/source/ui/dlg/directsql.cxx
@@ -194,7 +194,8 @@ namespace dbaui
display(xRS);
}
else
- addOutputText(OUString::number(xMR->getUpdateCount()) + " rows updated\n");
+ addOutputText(
+ OUString(OUString::number(xMR->getUpdateCount()) + " rows updated\n"));
for (;;)
{
hasRS = xMR->getMoreResults();
@@ -219,7 +220,7 @@ namespace dbaui
else
{
sal_Int32 resultCount = xStatement->executeUpdate(_rStatement);
- addOutputText(OUString::number(resultCount) + " rows updated\n");
+ addOutputText(OUString(OUString::number(resultCount) + " rows updated\n"));
}
}
// successful
@@ -270,7 +271,7 @@ namespace dbaui
}
}
- void DirectSQLDialog::addStatusText(const OUString& _rMessage)
+ void DirectSQLDialog::addStatusText(std::u16string_view _rMessage)
{
OUString sAppendMessage = OUString::number(m_nStatusCount++) + ": " + _rMessage + "\n\n";
@@ -280,9 +281,9 @@ namespace dbaui
m_xStatus->select_region(sCompleteMessage.getLength(), sCompleteMessage.getLength());
}
- void DirectSQLDialog::addOutputText(const OUString& _rMessage)
+ void DirectSQLDialog::addOutputText(std::u16string_view _rMessage)
{
- OUString sAppendMessage = _rMessage + "\n";
+ OUString sAppendMessage = OUString::Concat(_rMessage) + "\n";
OUString sCompleteMessage = m_xOutput->get_text() + sAppendMessage;
m_xOutput->set_text(sCompleteMessage);
diff --git a/dbaccess/source/ui/inc/directsql.hxx b/dbaccess/source/ui/inc/directsql.hxx
index b67ad6d264fc..b9f419d9a686 100644
--- a/dbaccess/source/ui/inc/directsql.hxx
+++ b/dbaccess/source/ui/inc/directsql.hxx
@@ -24,6 +24,7 @@
#include <sal/log.hxx>
#include <vcl/weld.hxx>
#include <deque>
+#include <string_view>
#include <com/sun/star/sdbc/XConnection.hpp>
#include <unotools/eventlisteneradapter.hxx>
@@ -94,10 +95,10 @@ namespace dbaui
void implExecuteStatement(const OUString& _rStatement);
/// adds a status text to the status list
- void addStatusText(const OUString& _rMessage);
+ void addStatusText(std::u16string_view _rMessage);
/// adds a status text to the output list
- void addOutputText(const OUString& _rMessage);
+ void addOutputText(std::u16string_view _rMessage);
/// displays resultset
void display(const css::uno::Reference< css::sdbc::XResultSet >& xRS);
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index b8aa3f7c4b81..e2f338b30737 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -49,6 +49,7 @@
#include <unotools/syslocale.hxx>
#include <memory>
#include <set>
+#include <string_view>
using namespace ::dbaui;
using namespace ::utl;
@@ -368,7 +369,7 @@ namespace
}
OUString BuildJoin( const Reference< XConnection>& _xConnection,
const OUString& rLh,
- const OUString& rRh,
+ std::u16string_view rRh,
const OQueryTableConnectionData* pData)
{
@@ -395,7 +396,7 @@ namespace
aErg += " FULL OUTER ";
break;
}
- aErg += "JOIN " + rRh;
+ aErg += OUString::Concat("JOIN ") + rRh;
if ( CROSS_JOIN != pData->GetJoinType() && !pData->isNatural() )
{
aErg += " ON " + BuildJoinCriteria(_xConnection,&pData->GetConnLineDataList(),pData);
diff --git a/desktop/inc/app.hxx b/desktop/inc/app.hxx
index 26e4691ab53c..e2ecf5920aa0 100644
--- a/desktop/inc/app.hxx
+++ b/desktop/inc/app.hxx
@@ -29,6 +29,7 @@
#include <com/sun/star/uno/Reference.h>
#include <memory>
+#include <string_view>
#include <thread>
namespace com::sun::star::uno { class XComponentContext; }
@@ -135,7 +136,7 @@ class Desktop final : public Application
static void FlushConfiguration();
static bool InitializeQuickstartMode( const css::uno::Reference< css::uno::XComponentContext >& rxContext );
- static void HandleBootstrapPathErrors( ::utl::Bootstrap::Status, const OUString& aMsg );
+ static void HandleBootstrapPathErrors( ::utl::Bootstrap::Status, std::u16string_view aMsg );
// Create an error message depending on bootstrap failure code and an optional file url
static OUString CreateErrorMsgString( utl::Bootstrap::FailureCode nFailureCode,
diff --git a/desktop/inc/lib/init.hxx b/desktop/inc/lib/init.hxx
index 84d9d5299fd4..e47c92cc5c0a 100644
--- a/desktop/inc/lib/init.hxx
+++ b/desktop/inc/lib/init.hxx
@@ -13,6 +13,7 @@
#include <unordered_map>
#include <memory>
#include <mutex>
+#include <string_view>
#include <boost/property_tree/ptree.hpp>
#include <boost/variant.hpp>
@@ -177,7 +178,7 @@ namespace desktop {
/// Helper function to extract the value from parameters delimited by
/// comma, like: Name1=Value1,Name2=Value2,Name3=Value3.
/// @param rOptions When extracted, the Param=Value is removed from it.
- DESKTOP_DLLPUBLIC OUString extractParameter(OUString& aOptions, const OUString& rName);
+ DESKTOP_DLLPUBLIC OUString extractParameter(OUString& aOptions, std::u16string_view rName);
/// Helper function to convert JSON to a vector of PropertyValues.
/// Public to be unit-test-able.
diff --git a/desktop/qa/desktop_lib/test_desktop_lib.cxx b/desktop/qa/desktop_lib/test_desktop_lib.cxx
index 82586de384b1..99fba50f14bb 100644
--- a/desktop/qa/desktop_lib/test_desktop_lib.cxx
+++ b/desktop/qa/desktop_lib/test_desktop_lib.cxx
@@ -8,6 +8,8 @@
*/
#include <memory>
+#include <string_view>
+
#include <com/sun/star/frame/Desktop.hpp>
#include <com/sun/star/lang/XComponent.hpp>
#include <com/sun/star/text/XTextDocument.hpp>
@@ -94,7 +96,8 @@ public:
{
}
- void readFileIntoByteVector(OUString const & sFilename, std::vector<sal_uInt8> & rByteVector);
+ void readFileIntoByteVector(
+ std::u16string_view sFilename, std::vector<sal_uInt8> & rByteVector);
virtual void setUp() override
{
@@ -696,7 +699,7 @@ void DesktopLOKTest::testPasteWriterJPEG()
LibLODocument_Impl* pDocument = loadDoc("blank_text.odt");
OUString aFileURL;
- createFileURL("paste.jpg", aFileURL);
+ createFileURL(u"paste.jpg", aFileURL);
std::ifstream aImageStream(aFileURL.toUtf8().copy(strlen("file://")).getStr());
std::vector<char> aImageContents((std::istreambuf_iterator<char>(aImageStream)), std::istreambuf_iterator<char>());
@@ -2418,32 +2421,32 @@ void DesktopLOKTest::testRunMacro()
void DesktopLOKTest::testExtractParameter()
{
OUString aOptions("Language=de-DE");
- OUString aValue = extractParameter(aOptions, "Language");
+ OUString aValue = extractParameter(aOptions, u"Language");
CPPUNIT_ASSERT_EQUAL(OUString("de-DE"), aValue);
CPPUNIT_ASSERT_EQUAL(OUString(), aOptions);
aOptions = "Language=en-US,Something";
- aValue = extractParameter(aOptions, "Language");
+ aValue = extractParameter(aOptions, u"Language");
CPPUNIT_ASSERT_EQUAL(OUString("en-US"), aValue);
CPPUNIT_ASSERT_EQUAL(OUString("Something"), aOptions);
aOptions = "SomethingElse,Language=cs-CZ";
- aValue = extractParameter(aOptions, "Language");
+ aValue = extractParameter(aOptions, u"Language");
CPPUNIT_ASSERT_EQUAL(OUString("cs-CZ"), aValue);
CPPUNIT_ASSERT_EQUAL(OUString("SomethingElse"), aOptions);
aOptions = "Something1,Language=hu-HU,Something2";
- aValue = extractParameter(aOptions, "Language");
+ aValue = extractParameter(aOptions, u"Language");
CPPUNIT_ASSERT_EQUAL(OUString("hu-HU"), aValue);
CPPUNIT_ASSERT_EQUAL(OUString("Something1,Something2"), aOptions);
aOptions = "Something1,Something2=blah,Something3";
- aValue = extractParameter(aOptions, "Language");
+ aValue = extractParameter(aOptions, u"Language");
CPPUNIT_ASSERT_EQUAL(OUString(), aValue);
CPPUNIT_ASSERT_EQUAL(OUString("Something1,Something2=blah,Something3"), aOptions);
}
-void DesktopLOKTest::readFileIntoByteVector(OUString const & sFilename, std::vector<unsigned char> & rByteVector)
+void DesktopLOKTest::readFileIntoByteVector(std::u16string_view sFilename, std::vector<unsigned char> & rByteVector)
{
rByteVector.clear();
OUString aURL;
@@ -2469,14 +2472,14 @@ void DesktopLOKTest::testGetSignatureState_Signed()
std::vector<unsigned char> aCertificate;
{
- readFileIntoByteVector("rootCA.der", aCertificate);
+ readFileIntoByteVector(u"rootCA.der", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
CPPUNIT_ASSERT(bResult);
}
{
- readFileIntoByteVector("intermediateRootCA.der", aCertificate);
+ readFileIntoByteVector(u"intermediateRootCA.der", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
CPPUNIT_ASSERT(bResult);
@@ -2515,7 +2518,7 @@ void DesktopLOKTest::testInsertCertificate_DER_ODT()
std::vector<unsigned char> aPrivateKey;
{
- readFileIntoByteVector("rootCA.der", aCertificate);
+ readFileIntoByteVector(u"rootCA.der", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2523,7 +2526,7 @@ void DesktopLOKTest::testInsertCertificate_DER_ODT()
}
{
- readFileIntoByteVector("intermediateRootCA.der", aCertificate);
+ readFileIntoByteVector(u"intermediateRootCA.der", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2531,8 +2534,8 @@ void DesktopLOKTest::testInsertCertificate_DER_ODT()
}
{
- readFileIntoByteVector("certificate.der", aCertificate);
- readFileIntoByteVector("certificatePrivateKey.der", aPrivateKey);
+ readFileIntoByteVector(u"certificate.der", aCertificate);
+ readFileIntoByteVector(u"certificatePrivateKey.der", aPrivateKey);
bool bResult = pDocument->m_pDocumentClass->insertCertificate(pDocument,
aCertificate.data(), int(aCertificate.size()),
@@ -2565,7 +2568,7 @@ void DesktopLOKTest::testInsertCertificate_PEM_ODT()
std::vector<unsigned char> aPrivateKey;
{
- readFileIntoByteVector("test-cert-chain-1.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-1.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2573,7 +2576,7 @@ void DesktopLOKTest::testInsertCertificate_PEM_ODT()
}
{
- readFileIntoByteVector("test-cert-chain-2.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-2.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2581,7 +2584,7 @@ void DesktopLOKTest::testInsertCertificate_PEM_ODT()
}
{
- readFileIntoByteVector("test-cert-chain-3.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-3.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2589,8 +2592,8 @@ void DesktopLOKTest::testInsertCertificate_PEM_ODT()
}
{
- readFileIntoByteVector("test-cert-signing.pem", aCertificate);
- readFileIntoByteVector("test-PK-signing.pem", aPrivateKey);
+ readFileIntoByteVector(u"test-cert-signing.pem", aCertificate);
+ readFileIntoByteVector(u"test-PK-signing.pem", aPrivateKey);
bool bResult = pDocument->m_pDocumentClass->insertCertificate(pDocument,
aCertificate.data(), int(aCertificate.size()),
@@ -2622,7 +2625,7 @@ void DesktopLOKTest::testInsertCertificate_PEM_DOCX()
std::vector<unsigned char> aPrivateKey;
{
- readFileIntoByteVector("test-cert-chain-1.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-1.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2630,7 +2633,7 @@ void DesktopLOKTest::testInsertCertificate_PEM_DOCX()
}
{
- readFileIntoByteVector("test-cert-chain-2.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-2.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2638,7 +2641,7 @@ void DesktopLOKTest::testInsertCertificate_PEM_DOCX()
}
{
- readFileIntoByteVector("test-cert-chain-3.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-3.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2646,8 +2649,8 @@ void DesktopLOKTest::testInsertCertificate_PEM_DOCX()
}
{
- readFileIntoByteVector("test-cert-signing.pem", aCertificate);
- readFileIntoByteVector("test-PK-signing.pem", aPrivateKey);
+ readFileIntoByteVector(u"test-cert-signing.pem", aCertificate);
+ readFileIntoByteVector(u"test-PK-signing.pem", aPrivateKey);
bool bResult = pDocument->m_pDocumentClass->insertCertificate(pDocument,
aCertificate.data(), int(aCertificate.size()),
@@ -2675,7 +2678,7 @@ void DesktopLOKTest::testSignDocument_PEM_PDF()
std::vector<unsigned char> aPrivateKey;
{
- readFileIntoByteVector("test-cert-chain-1.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-1.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2683,7 +2686,7 @@ void DesktopLOKTest::testSignDocument_PEM_PDF()
}
{
- readFileIntoByteVector("test-cert-chain-2.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-2.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2691,7 +2694,7 @@ void DesktopLOKTest::testSignDocument_PEM_PDF()
}
{
- readFileIntoByteVector("test-cert-chain-3.pem", aCertificate);
+ readFileIntoByteVector(u"test-cert-chain-3.pem", aCertificate);
bool bResult = pDocument->m_pDocumentClass->addCertificate(
pDocument, aCertificate.data(), int(aCertificate.size()));
@@ -2704,8 +2707,8 @@ void DesktopLOKTest::testSignDocument_PEM_PDF()
Scheduler::ProcessEventsToIdle();
- readFileIntoByteVector("test-cert-signing.pem", aCertificate);
- readFileIntoByteVector("test-PK-signing.pem", aPrivateKey);
+ readFileIntoByteVector(u"test-cert-signing.pem", aCertificate);
+ readFileIntoByteVector(u"test-PK-signing.pem", aPrivateKey);
LibLibreOffice_Impl aOffice;
bool bResult = aOffice.m_pOfficeClass->signDocument(&aOffice, aTempFile.GetURL().toUtf8().getStr(),
@@ -2821,7 +2824,7 @@ void DesktopLOKTest::testComplexSelection()
// Paste an image.
OUString aFileURL;
- createFileURL("paste.jpg", aFileURL);
+ createFileURL(u"paste.jpg", aFileURL);
std::ifstream aImageStream(aFileURL.toUtf8().copy(strlen("file://")).getStr());
std::vector<char> aImageContents((std::istreambuf_iterator<char>(aImageStream)), std::istreambuf_iterator<char>());
CPPUNIT_ASSERT(pDocument->pClass->paste(pDocument, "image/jpeg", aImageContents.data(), aImageContents.size()));
diff --git a/desktop/qa/unit/desktop-dialogs-test.cxx b/desktop/qa/unit/desktop-dialogs-test.cxx
index 54cadc33794c..56c39eb7108a 100644
--- a/desktop/qa/unit/desktop-dialogs-test.cxx
+++ b/desktop/qa/unit/desktop-dialogs-test.cxx
@@ -51,7 +51,7 @@ VclPtr<VclAbstractDialog> DesktopDialogsTest::createDialogByID(sal_uInt32 /*nID*
void DesktopDialogsTest::openAnyDialog()
{
/// process input file containing the UXMLDescriptions of the dialogs to dump
- processDialogBatchFile("desktop/qa/unit/data/desktop-dialogs-test.txt");
+ processDialogBatchFile(u"desktop/qa/unit/data/desktop-dialogs-test.txt");
}
CPPUNIT_TEST_SUITE_REGISTRATION(DesktopDialogsTest);
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index 596e83b14ebf..2f4fcdc6904b 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -28,6 +28,7 @@
#include <sal/config.h>
#include <iostream>
+#include <string_view>
#include <app.hxx>
#include <dp_shared.hxx>
@@ -335,7 +336,7 @@ void RemoveIconCacheDirectory()
namespace {
-OUString MakeStartupErrorMessage(OUString const & aErrorMessage)
+OUString MakeStartupErrorMessage(std::u16string_view aErrorMessage)
{
return DpResId(STR_BOOTSTRAP_ERR_CANNOT_START) + "\n" + aErrorMessage;
}
@@ -597,7 +598,7 @@ void Desktop::Shutdown()
framework::getDesktop(::comphelper::getProcessComponentContext())->shutdown();
}
-void Desktop::HandleBootstrapPathErrors( ::utl::Bootstrap::Status aBootstrapStatus, const OUString& aDiagnosticMessage )
+void Desktop::HandleBootstrapPathErrors( ::utl::Bootstrap::Status aBootstrapStatus, std::u16string_view aDiagnosticMessage )
{
if ( aBootstrapStatus == ::utl::Bootstrap::DATA_OK )
return;
@@ -614,7 +615,7 @@ void Desktop::HandleBootstrapPathErrors( ::utl::Bootstrap::Status aBootstrapStat
if ( !aTemp.isEmpty() )
aProductKey = aTemp;
- OUString const aMessage(aDiagnosticMessage + "\n");
+ OUString const aMessage(OUString::Concat(aDiagnosticMessage) + "\n");
std::unique_ptr<weld::MessageDialog> xBootstrapFailedBox(Application::CreateMessageDialog(nullptr,
VclMessageType::Warning, VclButtonsType::Ok, aMessage));
diff --git a/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx b/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx
index bf15f687f0dd..5983313de51b 100644
--- a/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx
+++ b/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx
@@ -52,6 +52,7 @@
#include <com/sun/star/uno/Sequence.h>
#include <comphelper/anytostring.hxx>
+#include <string_view>
#include <vector>
using dp_misc::StrTitle;
@@ -233,7 +234,7 @@ void UpdateInstallDialog::updateDone()
// make sure the solar mutex is locked before calling
//sets an error message in the text area
void UpdateInstallDialog::setError(INSTALL_ERROR err, std::u16string_view sExtension,
- OUString const & exceptionMessage)
+ std::u16string_view exceptionMessage)
{
OUString sError;
m_bError = true;
@@ -264,7 +265,7 @@ void UpdateInstallDialog::setError(INSTALL_ERROR err, std::u16string_view sExten
sMsg += "\n";
sMsg += sError;
//Insert more information about the error
- if (!exceptionMessage.isEmpty())
+ if (!exceptionMessage.empty())
sMsg += m_sThisErrorOccurred + exceptionMessage + "\n";
sMsg += m_sNoInstall + "\n";
@@ -272,7 +273,7 @@ void UpdateInstallDialog::setError(INSTALL_ERROR err, std::u16string_view sExten
m_xMle_info->set_text(sMsg);
}
-void UpdateInstallDialog::setError(OUString const & exceptionMessage)
+void UpdateInstallDialog::setError(std::u16string_view exceptionMessage)
{
m_bError = true;
m_xMle_info->set_text(m_xMle_info->get_text() + exceptionMessage + "\n");
@@ -493,7 +494,7 @@ void UpdateInstallDialog::Thread::installExtensions()
return;
}
m_dialog.setError(UpdateInstallDialog::ERROR_LICENSE_DECLINED,
- updateData.aInstalledPackage->getDisplayName(), OUString());
+ updateData.aInstalledPackage->getDisplayName(), std::u16string_view());
}
else if (!xExtension.is() || bError)
{
diff --git a/desktop/source/deployment/gui/dp_gui_updateinstalldialog.hxx b/desktop/source/deployment/gui/dp_gui_updateinstalldialog.hxx
index 7e970f7b346c..224307f71b30 100644
--- a/desktop/source/deployment/gui/dp_gui_updateinstalldialog.hxx
+++ b/desktop/source/deployment/gui/dp_gui_updateinstalldialog.hxx
@@ -22,6 +22,8 @@
#include <sal/config.h>
#include <vcl/weld.hxx>
#include <rtl/ref.hxx>
+
+#include <string_view>
#include <vector>
/// @HTML
@@ -78,8 +80,8 @@ private:
ERROR_INSTALLATION,
ERROR_LICENSE_DECLINED
};
- void setError(INSTALL_ERROR err, std::u16string_view sExtension, OUString const & exceptionMessage);
- void setError(OUString const & exceptionMessage);
+ void setError(INSTALL_ERROR err, std::u16string_view sExtension, std::u16string_view exceptionMessage);
+ void setError(std::u16string_view exceptionMessage);
const css::uno::Reference< css::deployment::XExtensionManager >& getExtensionManager() const
{ return m_xExtensionManager; }
diff --git a/desktop/source/deployment/gui/license_dialog.cxx b/desktop/source/deployment/gui/license_dialog.cxx
index ef2b64b91101..34fa924b8128 100644
--- a/desktop/source/deployment/gui/license_dialog.cxx
+++ b/desktop/source/deployment/gui/license_dialog.cxx
@@ -29,6 +29,7 @@
#include "license_dialog.hxx"
#include <functional>
+#include <string_view>
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -64,7 +65,7 @@ struct LicenseDialogImpl : public weld::GenericDialogController
DECL_LINK(SizeAllocHdl, const Size&, void);
LicenseDialogImpl(weld::Window * pParent,
- const OUString & sExtensionName,
+ std::u16string_view sExtensionName,
const OUString & sLicenseText);
bool IsEndReached() const;
@@ -74,7 +75,7 @@ struct LicenseDialogImpl : public weld::GenericDialogController
LicenseDialogImpl::LicenseDialogImpl(
weld::Window * pParent,
- const OUString & sExtensionName,
+ std::u16string_view sExtensionName,
const OUString & sLicenseText)
: GenericDialogController(pParent, "desktop/ui/licensedialog.ui", "LicenseDialog")
, m_bLicenseRead(false)
diff --git a/desktop/source/deployment/inc/dp_descriptioninfoset.hxx b/desktop/source/deployment/inc/dp_descriptioninfoset.hxx
index 40197f7efb7c..08d533a79d3a 100644
--- a/desktop/source/deployment/inc/dp_descriptioninfoset.hxx
+++ b/desktop/source/deployment/inc/dp_descriptioninfoset.hxx
@@ -22,6 +22,8 @@
#include <sal/config.h>
#include <optional>
+#include <string_view>
+
#include <com/sun/star/uno/Reference.hxx>
#include <com/sun/star/uno/Sequence.hxx>
#include <sal/types.h>
@@ -225,7 +227,7 @@ private:
SAL_DLLPRIVATE css::uno::Reference< css::xml::dom::XNode>
matchLanguageTag(
css::uno::Reference< css::xml::dom::XNode > const & xParent,
- OUString const & rTag) const;
+ std::u16string_view rTag) const;
/** If there is no child element with a locale matching the office locale, then we use
the first child. In the case of the simple-license we also use the former default locale, which
@@ -279,7 +281,7 @@ inline bool DescriptionInfoset::hasDescription() const
the description.xml.
*/
DESKTOP_DEPLOYMENTMISC_DLLPUBLIC
-DescriptionInfoset getDescriptionInfoset(OUString const & sExtensionFolderURL);
+DescriptionInfoset getDescriptionInfoset(std::u16string_view sExtensionFolderURL);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/desktop/source/deployment/inc/dp_identifier.hxx b/desktop/source/deployment/inc/dp_identifier.hxx
index 85735c659357..bd11170b6a7e 100644
--- a/desktop/source/deployment/inc/dp_identifier.hxx
+++ b/desktop/source/deployment/inc/dp_identifier.hxx
@@ -22,6 +22,8 @@
#include <sal/config.h>
#include <optional>
+#include <string_view>
+
#include <com/sun/star/uno/Reference.hxx>
#include "dp_misc_api.hxx"
@@ -47,7 +49,7 @@ namespace dp_misc {
*/
DESKTOP_DEPLOYMENTMISC_DLLPUBLIC OUString generateIdentifier(
::std::optional< OUString > const & optional,
- OUString const & fileName);
+ std::u16string_view fileName);
/**
Gets the identifier of a package.
@@ -75,7 +77,7 @@ DESKTOP_DEPLOYMENTMISC_DLLPUBLIC OUString getIdentifier(
a legacy identifier based on the given file name
*/
DESKTOP_DEPLOYMENTMISC_DLLPUBLIC OUString generateLegacyIdentifier(
- OUString const & fileName);
+ std::u16string_view fileName);
}
diff --git a/desktop/source/deployment/manager/dp_extensionmanager.cxx b/desktop/source/deployment/manager/dp_extensionmanager.cxx
index 62063f81e148..2a17e2d6860c 100644
--- a/desktop/source/deployment/manager/dp_extensionmanager.cxx
+++ b/desktop/source/deployment/manager/dp_extensionmanager.cxx
@@ -54,6 +54,7 @@
#include <vector>
#include <algorithm>
#include <set>
+#include <string_view>
namespace lang = com::sun::star::lang;
namespace task = com::sun::star::task;
@@ -566,7 +567,7 @@ bool ExtensionManager::doChecksForAddExtension(
}
//Prevent showing the license if requested.
Reference<ucb::XCommandEnvironment> _xCmdEnv(xCmdEnv);
- ExtensionProperties props(OUString(), properties, Reference<ucb::XCommandEnvironment>(), m_xContext);
+ ExtensionProperties props(std::u16string_view(), properties, Reference<ucb::XCommandEnvironment>(), m_xContext);
dp_misc::DescriptionInfoset info(dp_misc::getDescriptionInfoset(xTmpExtension->getURL()));
const ::std::optional<dp_misc::SimpleLicenseAttributes> licenseAttributes =
diff --git a/desktop/source/deployment/manager/dp_manager.cxx b/desktop/source/deployment/manager/dp_manager.cxx
index 22fd91370f11..5ff55abe6b33 100644
--- a/desktop/source/deployment/manager/dp_manager.cxx
+++ b/desktop/source/deployment/manager/dp_manager.cxx
@@ -974,7 +974,7 @@ Reference<deployment::XPackage> PackageManagerImpl::getDeployedPackage_(
Reference<deployment::XPackage> PackageManagerImpl::getDeployedPackage_(
- OUString const & id, ActivePackages::Data const & data,
+ std::u16string_view id, ActivePackages::Data const & data,
Reference<XCommandEnvironment> const & xCmdEnv, bool ignoreAlienPlatforms )
{
if (ignoreAlienPlatforms)
diff --git a/desktop/source/deployment/manager/dp_manager.h b/desktop/source/deployment/manager/dp_manager.h
index 335099d3215d..ec34461aa6f7 100644
--- a/desktop/source/deployment/manager/dp_manager.h
+++ b/desktop/source/deployment/manager/dp_manager.h
@@ -27,7 +27,7 @@
#include <com/sun/star/deployment/XPackageRegistry.hpp>
#include <com/sun/star/deployment/XPackageManager.hpp>
#include <memory>
-
+#include <string_view>
namespace dp_manager {
@@ -173,7 +173,7 @@ public:
OUString const & id, OUString const & fileName,
css::uno::Reference<css::ucb::XCommandEnvironment> const & xCmdEnv );
css::uno::Reference<css::deployment::XPackage> getDeployedPackage_(
- OUString const & id, ActivePackages::Data const & data,
+ std::u16string_view id, ActivePackages::Data const & data,
css::uno::Reference<css::ucb::XCommandEnvironment> const & xCmdEnv,
bool ignoreAlienPlatforms = false );
virtual css::uno::Reference<css::deployment::XPackage> SAL_CALL
diff --git a/desktop/source/deployment/manager/dp_properties.cxx b/desktop/source/deployment/manager/dp_properties.cxx
index ab5ccc7eb5c7..92d7191111d3 100644
--- a/desktop/source/deployment/manager/dp_properties.cxx
+++ b/desktop/source/deployment/manager/dp_properties.cxx
@@ -41,12 +41,12 @@ namespace dp_manager {
//Reading the file
ExtensionProperties::ExtensionProperties(
- OUString const & urlExtension,
+ std::u16string_view urlExtension,
Reference<ucb::XCommandEnvironment> const & xCmdEnv,
Reference<uno::XComponentContext> const & xContext) :
m_xCmdEnv(xCmdEnv), m_xContext(xContext)
{
- m_propFileUrl = urlExtension + "properties";
+ m_propFileUrl = OUString::Concat(urlExtension) + "properties";
std::vector< std::pair< OUString, OUString> > props;
if (! dp_misc::create_ucb_content(nullptr, m_propFileUrl, nullptr, false))
@@ -64,13 +64,13 @@ ExtensionProperties::ExtensionProperties(
//Writing the file
ExtensionProperties::ExtensionProperties(
- OUString const & urlExtension,
+ std::u16string_view urlExtension,
uno::Sequence<css::beans::NamedValue> const & properties,
Reference<ucb::XCommandEnvironment> const & xCmdEnv,
Reference<uno::XComponentContext> const & xContext) :
m_xCmdEnv(xCmdEnv), m_xContext(xContext)
{
- m_propFileUrl = urlExtension + "properties";
+ m_propFileUrl = OUString::Concat(urlExtension) + "properties";
for (css::beans::NamedValue const & v : properties)
{
diff --git a/desktop/source/deployment/manager/dp_properties.hxx b/desktop/source/deployment/manager/dp_properties.hxx
index d87e2951ccb2..06139ece3c7d 100644
--- a/desktop/source/deployment/manager/dp_properties.hxx
+++ b/desktop/source/deployment/manager/dp_properties.hxx
@@ -23,6 +23,7 @@
#include <com/sun/star/ucb/XCommandEnvironment.hpp>
#include <com/sun/star/uno/XComponentContext.hpp>
#include <optional>
+#include <string_view>
namespace dp_manager
{
@@ -37,11 +38,11 @@ class ExtensionProperties final
static OUString getPropertyValue(css::beans::NamedValue const& v);
public:
- ExtensionProperties(OUString const& urlExtension,
+ ExtensionProperties(std::u16string_view urlExtension,
css::uno::Reference<css::ucb::XCommandEnvironment> const& xCmdEnv,
css::uno::Reference<css::uno::XComponentContext> const& xContext);
- ExtensionProperties(OUString const& urlExtension,
+ ExtensionProperties(std::u16string_view urlExtension,
css::uno::Sequence<css::beans::NamedValue> const& properties,
css::uno::Reference<css::ucb::XCommandEnvironment> const& xCmdEnv,
css::uno::Reference<css::uno::XComponentContext> const& xContext);
diff --git a/desktop/source/deployment/misc/dp_descriptioninfoset.cxx b/desktop/source/deployment/misc/dp_descriptioninfoset.cxx
index 183434efba24..2db2145070fc 100644
--- a/desktop/source/deployment/misc/dp_descriptioninfoset.cxx
+++ b/desktop/source/deployment/misc/dp_descriptioninfoset.cxx
@@ -17,6 +17,10 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <sal/config.h>
+
+#include <string_view>
+
#include <dp_descriptioninfoset.hxx>
#include <dp_resource.h>
@@ -118,7 +122,7 @@ public:
*/
ExtensionDescription(
const css::uno::Reference<css::uno::XComponentContext>& xContext,
- const OUString& installDir,
+ std::u16string_view installDir,
const css::uno::Reference< css::ucb::XCommandEnvironment >& xCmdEnv);
const css::uno::Reference<css::xml::dom::XNode>& getRootElement() const
@@ -160,7 +164,7 @@ public:
ExtensionDescription::ExtensionDescription(
const Reference<css::uno::XComponentContext>& xContext,
- const OUString& installDir,
+ std::u16string_view installDir,
const Reference< css::ucb::XCommandEnvironment >& xCmdEnv)
{
try {
@@ -168,7 +172,7 @@ ExtensionDescription::ExtensionDescription(
//If there is no description.xml then ucb will start an interaction which
//brings up a dialog.We want to prevent this. Therefore we wrap the xCmdEnv
//and filter the respective exception out.
- OUString sDescriptionUri(installDir + "/description.xml");
+ OUString sDescriptionUri(OUString::Concat(installDir) + "/description.xml");
Reference<css::ucb::XCommandEnvironment> xFilter = new FileDoesNotExistFilter(xCmdEnv);
::ucbhelper::Content descContent(sDescriptionUri, xFilter, xContext);
@@ -289,7 +293,7 @@ void FileDoesNotExistFilter::handle(
namespace dp_misc {
-DescriptionInfoset getDescriptionInfoset(OUString const & sExtensionFolderURL)
+DescriptionInfoset getDescriptionInfoset(std::u16string_view sExtensionFolderURL)
{
Reference< css::xml::dom::XNode > root;
Reference<css::uno::XComponentContext> context(
@@ -706,13 +710,13 @@ DescriptionInfoset::getLocalizedChild( const OUString & sParent) const
css::uno::Reference<css::xml::dom::XNode>
DescriptionInfoset::matchLanguageTag(
- css::uno::Reference< css::xml::dom::XNode > const & xParent, OUString const & rTag) const
+ css::uno::Reference< css::xml::dom::XNode > const & xParent, std::u16string_view rTag) const
{
OSL_ASSERT(xParent.is());
css::uno::Reference<css::xml::dom::XNode> nodeMatch;
//first try exact match for lang
- const OUString exp1("*[@lang=\"" + rTag + "\"]");
+ const OUString exp1(OUString::Concat("*[@lang=\"") + rTag + "\"]");
try {
nodeMatch = m_xpath->selectSingleNode(xParent, exp1);
} catch (const css::xml::xpath::XPathException &) {
@@ -724,7 +728,7 @@ DescriptionInfoset::matchLanguageTag(
if (!nodeMatch.is())
{
const OUString exp2(
- "*[starts-with(@lang,\"" + rTag + "-\")]");
+ OUString::Concat("*[starts-with(@lang,\"") + rTag + "-\")]");
try {
nodeMatch = m_xpath->selectSingleNode(xParent, exp2);
} catch (const css::xml::xpath::XPathException &) {
diff --git a/desktop/source/deployment/misc/dp_identifier.cxx b/desktop/source/deployment/misc/dp_identifier.cxx
index 350f9a1f0541..8669710c7b16 100644
--- a/desktop/source/deployment/misc/dp_identifier.cxx
+++ b/desktop/source/deployment/misc/dp_identifier.cxx
@@ -33,7 +33,7 @@ namespace dp_misc {
OUString generateIdentifier(
::std::optional< OUString > const & optional,
- OUString const & fileName)
+ std::u16string_view fileName)
{
return optional ? *optional : generateLegacyIdentifier(fileName);
}
@@ -47,8 +47,8 @@ OUString getIdentifier(
? id.Value : generateLegacyIdentifier(package->getName());
}
-OUString generateLegacyIdentifier(OUString const & fileName) {
- return "org.openoffice.legacy." + fileName;
+OUString generateLegacyIdentifier(std::u16string_view fileName) {
+ return OUString::Concat("org.openoffice.legacy.") + fileName;
}
}
diff --git a/desktop/source/deployment/registry/component/dp_compbackenddb.cxx b/desktop/source/deployment/registry/component/dp_compbackenddb.cxx
index 05f265404f55..37356fd78333 100644
--- a/desktop/source/deployment/registry/component/dp_compbackenddb.cxx
+++ b/desktop/source/deployment/registry/component/dp_compbackenddb.cxx
@@ -67,22 +67,22 @@ void ComponentBackendDb::addEntry(OUString const & url, Data const & data)
if (!activateEntry(url))
{
Reference<css::xml::dom::XNode> componentNode = writeKeyElement(url);
- writeSimpleElement("java-type-library",
+ writeSimpleElement(u"java-type-library",
OUString::boolean(data.javaTypeLibrary),
componentNode);
writeSimpleList(
data.implementationNames,
- "implementation-names",
- "name",
+ u"implementation-names",
+ u"name",
componentNode);
writeVectorOfPair(
data.singletons,
- "singletons",
- "item",
- "key",
- "value",
+ u"singletons",
+ u"item",
+ u"key",
+ u"value",
componentNode);
save();
@@ -97,7 +97,7 @@ void ComponentBackendDb::addEntry(OUString const & url, Data const & data)
}
}
-ComponentBackendDb::Data ComponentBackendDb::getEntry(OUString const & url)
+ComponentBackendDb::Data ComponentBackendDb::getEntry(std::u16string_view url)
{
try
{
@@ -105,14 +105,14 @@ ComponentBackendDb::Data ComponentBackendDb::getEntry(OUString const & url)
Reference<css::xml::dom::XNode> aNode = getKeyElement(url);
if (aNode.is())
{
- bool bJava = readSimpleElement("java-type-library", aNode) == "true";
+ bool bJava = readSimpleElement(u"java-type-library", aNode) == "true";
retData.javaTypeLibrary = bJava;
retData.implementationNames =
- readList( aNode, "implementation-names", "name");
+ readList( aNode, u"implementation-names", u"name");
retData.singletons =
- readVectorOfPair( aNode, "singletons", "item", "key", "value");
+ readVectorOfPair( aNode, u"singletons", u"item", u"key", u"value");
}
return retData;
}
diff --git a/desktop/source/deployment/registry/component/dp_compbackenddb.hxx b/desktop/source/deployment/registry/component/dp_compbackenddb.hxx
index e1797056d498..84153b6fa259 100644
--- a/desktop/source/deployment/registry/component/dp_compbackenddb.hxx
+++ b/desktop/source/deployment/registry/component/dp_compbackenddb.hxx
@@ -23,6 +23,8 @@
#include <rtl/string.hxx>
#include <vector>
#include <deque>
+#include <string_view>
+
#include <dp_backenddb.hxx>
namespace com::sun::star::uno { class XComponentContext; }
@@ -81,7 +83,7 @@ public:
void addEntry(OUString const & url, Data const & data);
- Data getEntry(OUString const & url);
+ Data getEntry(std::u16string_view url);
};
diff --git a/desktop/source/deployment/registry/component/dp_component.cxx b/desktop/source/deployment/registry/component/dp_component.cxx
index 3ff6d653477a..5bf230c17f68 100644
--- a/desktop/source/deployment/registry/component/dp_component.cxx
+++ b/desktop/source/deployment/registry/component/dp_component.cxx
@@ -287,8 +287,8 @@ class BackendImpl : public ::dp_registry::backend::PackageRegistryBackend
std::unique_ptr<ComponentBackendDb> m_backendDb;
void addDataToDb(OUString const & url, ComponentBackendDb::Data const & data);
- ComponentBackendDb::Data readDataFromDb(OUString const & url);
- void revokeEntryFromDb(OUString const & url);
+ ComponentBackendDb::Data readDataFromDb(std::u16string_view url);
+ void revokeEntryFromDb(std::u16string_view url);
Reference<registry::XSimpleRegistry> m_xCommonRDB;
Reference<registry::XSimpleRegistry> m_xNativeRDB;
@@ -576,7 +576,7 @@ void BackendImpl::addDataToDb(
m_backendDb->addEntry(url, data);
}
-ComponentBackendDb::Data BackendImpl::readDataFromDb(OUString const & url)
+ComponentBackendDb::Data BackendImpl::readDataFromDb(std::u16string_view url)
{
ComponentBackendDb::Data data;
if (m_backendDb)
@@ -584,7 +584,7 @@ ComponentBackendDb::Data BackendImpl::readDataFromDb(OUString const & url)
return data;
}
-void BackendImpl::revokeEntryFromDb(OUString const & url)
+void BackendImpl::revokeEntryFromDb(std::u16string_view url)
{
if (m_backendDb)
m_backendDb->revokeEntry(url);
diff --git a/desktop/source/deployment/registry/configuration/dp_configuration.cxx b/desktop/source/deployment/registry/configuration/dp_configuration.cxx
index 578e164f13b7..7949ab353b0a 100644
--- a/desktop/source/deployment/registry/configuration/dp_configuration.cxx
+++ b/desktop/source/deployment/registry/configuration/dp_configuration.cxx
@@ -42,6 +42,7 @@
#include <com/sun/star/lang/WrappedTargetRuntimeException.hpp>
#include <deque>
#include <memory>
+#include <string_view>
#include <utility>
#include "dp_configurationbackenddb.hxx"
@@ -129,10 +130,10 @@ class BackendImpl : public ::dp_registry::backend::PackageRegistryBackend
Reference<XCommandEnvironment> const & xCmdEnv );
#endif
void addDataToDb(OUString const & url, ConfigurationBackendDb::Data const & data);
- ::std::optional<ConfigurationBackendDb::Data> readDataFromDb(OUString const & url);
- void revokeEntryFromDb(OUString const & url);
- bool hasActiveEntry(OUString const & url);
- bool activateEntry(OUString const & url);
+ ::std::optional<ConfigurationBackendDb::Data> readDataFromDb(std::u16string_view url);
+ void revokeEntryFromDb(std::u16string_view url);
+ bool hasActiveEntry(std::u16string_view url);
+ bool activateEntry(std::u16string_view url);
public:
BackendImpl( Sequence<Any> const & args,
@@ -261,7 +262,7 @@ void BackendImpl::addDataToDb(
}
::std::optional<ConfigurationBackendDb::Data> BackendImpl::readDataFromDb(
- OUString const & url)
+ std::u16string_view url)
{
::std::optional<ConfigurationBackendDb::Data> data;
if (m_backendDb)
@@ -269,20 +270,20 @@ void BackendImpl::addDataToDb(
return data;
}
-void BackendImpl::revokeEntryFromDb(OUString const & url)
+void BackendImpl::revokeEntryFromDb(std::u16string_view url)
{
if (m_backendDb)
m_backendDb->revokeEntry(url);
}
-bool BackendImpl::hasActiveEntry(OUString const & url)
+bool BackendImpl::hasActiveEntry(std::u16string_view url)
{
if (m_backendDb)
return m_backendDb->hasActiveEntry(url);
return false;
}
-bool BackendImpl::activateEntry(OUString const & url)
+bool BackendImpl::activateEntry(std::u16string_view url)
{
if (m_backendDb)
return m_backendDb->activateEntry(url);
@@ -600,7 +601,7 @@ OUString encodeForXml( OUString const & text )
OUString replaceOrigin(
- OUString const & url, OUString const & destFolder, Reference< XCommandEnvironment > const & xCmdEnv, Reference< XComponentContext > const & xContext, bool & out_replaced)
+ OUString const & url, std::u16string_view destFolder, Reference< XCommandEnvironment > const & xCmdEnv, Reference< XComponentContext > const & xContext, bool & out_replaced)
{
// looking for %origin%:
::ucbhelper::Content ucb_content( url, xCmdEnv, xContext );
@@ -671,11 +672,11 @@ OUString replaceOrigin(
if (write_pos < filtered.size())
filtered.resize( write_pos );
OUString newUrl(url);
- if (!destFolder.isEmpty())
+ if (!destFolder.empty())
{
//get the file name of the xcu and add it to the url of the temporary folder
sal_Int32 i = url.lastIndexOf('/');
- newUrl = destFolder + url.subView(i);
+ newUrl = OUString::Concat(destFolder) + url.subView(i);
}
ucbhelper::Content(newUrl, xCmdEnv, xContext).writeStream(
diff --git a/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx b/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx
index fd5d3b3c4833..0028f32ce352 100644
--- a/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx
+++ b/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx
@@ -71,8 +71,8 @@ void ConfigurationBackendDb::addEntry(OUString const & url, Data const & data)
Reference<css::xml::dom::XNode> helpNode
= writeKeyElement(url);
- writeSimpleElement("data-url", data.dataUrl, helpNode);
- writeSimpleElement("ini-entry", data.iniEntry, helpNode);
+ writeSimpleElement(u"data-url", data.dataUrl, helpNode);
+ writeSimpleElement(u"ini-entry", data.iniEntry, helpNode);
save();
}
}
@@ -91,7 +91,7 @@ void ConfigurationBackendDb::addEntry(OUString const & url, Data const & data)
::std::optional<ConfigurationBackendDb::Data>
-ConfigurationBackendDb::getEntry(OUString const & url)
+ConfigurationBackendDb::getEntry(std::u16string_view url)
{
try
{
@@ -99,8 +99,8 @@ ConfigurationBackendDb::getEntry(OUString const & url)
Reference<css::xml::dom::XNode> aNode = getKeyElement(url);
if (aNode.is())
{
- retData.dataUrl = readSimpleElement("data-url", aNode);
- retData.iniEntry = readSimpleElement("ini-entry", aNode);
+ retData.dataUrl = readSimpleElement(u"data-url", aNode);
+ retData.iniEntry = readSimpleElement(u"ini-entry", aNode);
}
else
{
diff --git a/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.hxx b/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.hxx
index 15ac91853019..bd48aab7b2f8 100644
--- a/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.hxx
+++ b/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.hxx
@@ -23,6 +23,8 @@
#include <rtl/string.hxx>
#include <vector>
#include <optional>
+#include <string_view>
+
#include <dp_backenddb.hxx>
namespace com::sun::star::uno
@@ -64,7 +66,7 @@ public:
void addEntry(OUString const& url, Data const& data);
- ::std::optional<Data> getEntry(OUString const& url);
+ ::std::optional<Data> getEntry(std::u16string_view url);
std::vector<OUString> getAllDataUrls();
};
}
diff --git a/desktop/source/deployment/registry/dp_backenddb.cxx b/desktop/source/deployment/registry/dp_backenddb.cxx
index edc64b1996ef..1cd3007b25a3 100644
--- a/desktop/source/deployment/registry/dp_backenddb.cxx
+++ b/desktop/source/deployment/registry/dp_backenddb.cxx
@@ -147,7 +147,7 @@ void BackendDb::removeElement(OUString const & sXPathExpression)
}
}
-void BackendDb::removeEntry(OUString const & url)
+void BackendDb::removeEntry(std::u16string_view url)
{
const OUString sKeyElement = getKeyElementName();
const OUString sPrefix = getNSPrefix();
@@ -162,7 +162,7 @@ void BackendDb::removeEntry(OUString const & url)
removeElement(sExpression);
}
-void BackendDb::revokeEntry(OUString const & url)
+void BackendDb::revokeEntry(std::u16string_view url)
{
try
{
@@ -182,7 +182,7 @@ void BackendDb::revokeEntry(OUString const & url)
}
}
-bool BackendDb::activateEntry(OUString const & url)
+bool BackendDb::activateEntry(std::u16string_view url)
{
try
{
@@ -206,7 +206,7 @@ bool BackendDb::activateEntry(OUString const & url)
}
}
-bool BackendDb::hasActiveEntry(OUString const & url)
+bool BackendDb::hasActiveEntry(std::u16string_view url)
{
try
{
@@ -231,7 +231,7 @@ bool BackendDb::hasActiveEntry(OUString const & url)
}
Reference<css::xml::dom::XNode> BackendDb::getKeyElement(
- OUString const & url)
+ std::u16string_view url)
{
try
{
@@ -262,10 +262,10 @@ Reference<css::xml::dom::XNode> BackendDb::getKeyElement(
//Only writes the data if there is at least one entry
void BackendDb::writeVectorOfPair(
std::vector< std::pair< OUString, OUString > > const & vecPairs,
- OUString const & sVectorTagName,
- OUString const & sPairTagName,
- OUString const & sFirstTagName,
- OUString const & sSecondTagName,
+ std::u16string_view sVectorTagName,
+ std::u16string_view sPairTagName,
+ std::u16string_view sFirstTagName,
+ std::u16string_view sSecondTagName,
css::uno::Reference<css::xml::dom::XNode> const & xParent)
{
try{
@@ -332,10 +332,10 @@ void BackendDb::writeVectorOfPair(
std::vector< std::pair< OUString, OUString > >
BackendDb::readVectorOfPair(
Reference<css::xml::dom::XNode> const & parent,
- OUString const & sListTagName,
- OUString const & sPairTagName,
- OUString const & sFirstTagName,
- OUString const & sSecondTagName)
+ std::u16string_view sListTagName,
+ std::u16string_view sPairTagName,
+ std::u16string_view sFirstTagName,
+ std::u16string_view sSecondTagName)
{
try
{
@@ -378,8 +378,8 @@ BackendDb::readVectorOfPair(
//Only writes the data if there is at least one entry
void BackendDb::writeSimpleList(
std::deque< OUString> const & list,
- OUString const & sListTagName,
- OUString const & sMemberTagName,
+ std::u16string_view sListTagName,
+ std::u16string_view sMemberTagName,
Reference<css::xml::dom::XNode> const & xParent)
{
try
@@ -422,7 +422,7 @@ void BackendDb::writeSimpleList(
//Writes only the element if is has a value.
//The prefix is automatically added to the element name
void BackendDb::writeSimpleElement(
- OUString const & sElementName, OUString const & value,
+ std::u16string_view sElementName, OUString const & value,
Reference<css::xml::dom::XNode> const & xParent)
{
try
@@ -501,7 +501,7 @@ Reference<css::xml::dom::XNode> BackendDb::writeKeyElement(
}
OUString BackendDb::readSimpleElement(
- OUString const & sElementName, Reference<css::xml::dom::XNode> const & xParent)
+ std::u16string_view sElementName, Reference<css::xml::dom::XNode> const & xParent)
{
try
{
@@ -526,8 +526,8 @@ OUString BackendDb::readSimpleElement(
std::deque< OUString> BackendDb::readList(
Reference<css::xml::dom::XNode> const & parent,
- OUString const & sListTagName,
- OUString const & sMemberTagName)
+ std::u16string_view sListTagName,
+ std::u16string_view sMemberTagName)
{
try
{
@@ -558,7 +558,7 @@ std::deque< OUString> BackendDb::readList(
}
std::vector<OUString> BackendDb::getOneChildFromAllEntries(
- OUString const & name)
+ std::u16string_view name)
{
try
{
diff --git a/desktop/source/deployment/registry/executable/dp_executable.cxx b/desktop/source/deployment/registry/executable/dp_executable.cxx
index 7631c6402a9a..f41836f8e4d0 100644
--- a/desktop/source/deployment/registry/executable/dp_executable.cxx
+++ b/desktop/source/deployment/registry/executable/dp_executable.cxx
@@ -19,6 +19,8 @@
#include <memory>
+#include <string_view>
+
#include <dp_misc.h>
#include <dp_backend.h>
#include <dp_ucb.h>
@@ -77,8 +79,8 @@ class BackendImpl : public ::dp_registry::backend::PackageRegistryBackend
OUString const & identifier, Reference<XCommandEnvironment> const & xCmdEnv ) override;
void addDataToDb(OUString const & url);
- bool hasActiveEntry(OUString const & url);
- void revokeEntryFromDb(OUString const & url);
+ bool hasActiveEntry(std::u16string_view url);
+ void revokeEntryFromDb(std::u16string_view url);
Reference<deployment::XPackageTypeInfo> m_xExecutableTypeInfo;
std::unique_ptr<ExecutableBackendDb> m_backendDb;
@@ -137,13 +139,13 @@ void BackendImpl::addDataToDb(OUString const & url)
m_backendDb->addEntry(url);
}
-void BackendImpl::revokeEntryFromDb(OUString const & url)
+void BackendImpl::revokeEntryFromDb(std::u16string_view url)
{
if (m_backendDb)
m_backendDb->revokeEntry(url);
}
-bool BackendImpl::hasActiveEntry(OUString const & url)
+bool BackendImpl::hasActiveEntry(std::u16string_view url)
{
if (m_backendDb)
return m_backendDb->hasActiveEntry(url);
diff --git a/desktop/source/deployment/registry/help/dp_help.cxx b/desktop/source/deployment/registry/help/dp_help.cxx
index 49be2a23f87d..1f1eb5f2fe90 100644
--- a/desktop/source/deployment/registry/help/dp_help.cxx
+++ b/desktop/source/deployment/registry/help/dp_help.cxx
@@ -40,6 +40,7 @@
#include <com/sun/star/ucb/SimpleFileAccess.hpp>
#include <com/sun/star/util/XMacroExpander.hpp>
#include <optional>
+#include <string_view>
using namespace ::dp_misc;
using namespace ::com::sun::star;
@@ -94,9 +95,9 @@ class BackendImpl : public ::dp_registry::backend::PackageRegistryBackend
void implCollectXhpFiles( const OUString& aDir,
std::vector< OUString >& o_rXhpFileVector );
- ::std::optional<HelpBackendDb::Data> readDataFromDb(OUString const & url);
- bool hasActiveEntry(OUString const & url);
- bool activateEntry(OUString const & url);
+ ::std::optional<HelpBackendDb::Data> readDataFromDb(std::u16string_view url);
+ bool hasActiveEntry(std::u16string_view url);
+ bool activateEntry(std::u16string_view url);
Reference< ucb::XSimpleFileAccess3 > const & getFileAccess();
Reference< ucb::XSimpleFileAccess3 > m_xSFA;
@@ -221,7 +222,7 @@ Reference<deployment::XPackage> BackendImpl::bindPackage_(
}
::std::optional<HelpBackendDb::Data> BackendImpl::readDataFromDb(
- OUString const & url)
+ std::u16string_view url)
{
::std::optional<HelpBackendDb::Data> data;
if (m_backendDb)
@@ -229,14 +230,14 @@ Reference<deployment::XPackage> BackendImpl::bindPackage_(
return data;
}
-bool BackendImpl::hasActiveEntry(OUString const & url)
+bool BackendImpl::hasActiveEntry(std::u16string_view url)
{
if (m_backendDb)
return m_backendDb->hasActiveEntry(url);
return false;
}
-bool BackendImpl::activateEntry(OUString const & url)
+bool BackendImpl::activateEntry(std::u16string_view url)
{
if (m_backendDb)
return m_backendDb->activateEntry(url);
diff --git a/desktop/source/deployment/registry/help/dp_helpbackenddb.cxx b/desktop/source/deployment/registry/help/dp_helpbackenddb.cxx
index 73b7279d13de..5d208d821e07 100644
--- a/desktop/source/deployment/registry/help/dp_helpbackenddb.cxx
+++ b/desktop/source/deployment/registry/help/dp_helpbackenddb.cxx
@@ -70,7 +70,7 @@ void HelpBackendDb::addEntry(OUString const & url, Data const & data)
Reference<css::xml::dom::XNode> helpNode
= writeKeyElement(url);
- writeSimpleElement("data-url", data.dataUrl, helpNode);
+ writeSimpleElement(u"data-url", data.dataUrl, helpNode);
save();
}
}
@@ -88,7 +88,7 @@ void HelpBackendDb::addEntry(OUString const & url, Data const & data)
::std::optional<HelpBackendDb::Data>
-HelpBackendDb::getEntry(OUString const & url)
+HelpBackendDb::getEntry(std::u16string_view url)
{
try
{
@@ -96,7 +96,7 @@ HelpBackendDb::getEntry(OUString const & url)
Reference<css::xml::dom::XNode> aNode = getKeyElement(url);
if (aNode.is())
{
- retData.dataUrl = readSimpleElement("data-url", aNode);
+ retData.dataUrl = readSimpleElement(u"data-url", aNode);
}
else
{
@@ -118,7 +118,7 @@ HelpBackendDb::getEntry(OUString const & url)
std::vector<OUString> HelpBackendDb::getAllDataUrls()
{
- return getOneChildFromAllEntries("data-url");
+ return getOneChildFromAllEntries(u"data-url");
}
} // namespace dp_registry::backend::help
diff --git a/desktop/source/deployment/registry/help/dp_helpbackenddb.hxx b/desktop/source/deployment/registry/help/dp_helpbackenddb.hxx
index 60172f32e6f3..a46bd8663cd7 100644
--- a/desktop/source/deployment/registry/help/dp_helpbackenddb.hxx
+++ b/desktop/source/deployment/registry/help/dp_helpbackenddb.hxx
@@ -21,6 +21,8 @@
#include <rtl/ustring.hxx>
#include <optional>
+#include <string_view>
+
#include <dp_backenddb.hxx>
namespace com::sun::star::uno
@@ -58,7 +60,7 @@ public:
void addEntry(OUString const& url, Data const& data);
- ::std::optional<Data> getEntry(OUString const& url);
+ ::std::optional<Data> getEntry(std::u16string_view url);
//must also return the data urls for entries with @active="false". That is,
//those are currently revoked.
std::vector<OUString> getAllDataUrls();
diff --git a/desktop/source/deployment/registry/inc/dp_backenddb.hxx b/desktop/source/deployment/registry/inc/dp_backenddb.hxx
index 7c8d5397fb1d..785201466772 100644
--- a/desktop/source/deployment/registry/inc/dp_backenddb.hxx
+++ b/desktop/source/deployment/registry/inc/dp_backenddb.hxx
@@ -22,6 +22,7 @@
#include <com/sun/star/uno/Reference.hxx>
#include <rtl/ustring.hxx>
#include <deque>
+#include <string_view>
#include <vector>
namespace com::sun::star {
@@ -66,50 +67,50 @@ protected:
void removeElement(OUString const & sXPathExpression);
css::uno::Reference<css::xml::dom::XNode> getKeyElement(
- OUString const & url);
+ std::u16string_view url);
void writeSimpleList(
std::deque< OUString> const & list,
- OUString const & sListTagName,
- OUString const & sMemberTagName,
+ std::u16string_view sListTagName,
+ std::u16string_view sMemberTagName,
css::uno::Reference<css::xml::dom::XNode> const & xParent);
void writeVectorOfPair(
std::vector< std::pair< OUString, OUString > > const & vecPairs,
- OUString const & sVectorTagName,
- OUString const & sPairTagName,
- OUString const & sFirstTagName,
- OUString const & sSecondTagName,
+ std::u16string_view sVectorTagName,
+ std::u16string_view sPairTagName,
+ std::u16string_view sFirstTagName,
+ std::u16string_view sSecondTagName,
css::uno::Reference<css::xml::dom::XNode> const & xParent);
void writeSimpleElement(
- OUString const & sElementName, OUString const & value,
+ std::u16string_view sElementName, OUString const & value,
css::uno::Reference<css::xml::dom::XNode> const & xParent);
css::uno::Reference<css::xml::dom::XNode> writeKeyElement(
OUString const & url);
OUString readSimpleElement(
- OUString const & sElementName,
+ std::u16string_view sElementName,
css::uno::Reference<css::xml::dom::XNode> const & xParent);
std::vector< std::pair< OUString, OUString > >
readVectorOfPair(
css::uno::Reference<css::xml::dom::XNode> const & parent,
- OUString const & sListTagName,
- OUString const & sPairTagName,
- OUString const & sFirstTagName,
- OUString const & sSecondTagName);
+ std::u16string_view sListTagName,
+ std::u16string_view sPairTagName,
+ std::u16string_view sFirstTagName,
+ std::u16string_view sSecondTagName);
std::deque< OUString> readList(
css::uno::Reference<css::xml::dom::XNode> const & parent,
- OUString const & sListTagName,
- OUString const & sMemberTagName);
+ std::u16string_view sListTagName,
+ std::u16string_view sMemberTagName);
/* returns the values of one particularly child element of all key elements.
*/
std::vector< OUString> getOneChildFromAllEntries(
- OUString const & sElementName);
+ std::u16string_view sElementName);
/* returns the namespace which is to be written as xmlns attribute
@@ -133,18 +134,18 @@ public:
OUString const & url);
virtual ~BackendDb() {};
- void removeEntry(OUString const & url);
+ void removeEntry(std::u16string_view url);
/* This is called to write the "revoked" attribute to the entry.
This is done when XPackage::revokePackage is called.
*/
- void revokeEntry(OUString const & url);
+ void revokeEntry(std::u16string_view url);
/* returns false if the entry does not exist yet.
*/
- bool activateEntry(OUString const & url);
+ bool activateEntry(std::u16string_view url);
- bool hasActiveEntry(OUString const & url);
+ bool hasActiveEntry(std::u16string_view url);
};
diff --git a/desktop/source/deployment/registry/package/dp_extbackenddb.cxx b/desktop/source/deployment/registry/package/dp_extbackenddb.cxx
index c96d1466b51f..ac4180f87f70 100644
--- a/desktop/source/deployment/registry/package/dp_extbackenddb.cxx
+++ b/desktop/source/deployment/registry/package/dp_extbackenddb.cxx
@@ -68,8 +68,8 @@ void ExtensionBackendDb::addEntry(OUString const & url, Data const & data)
if (!activateEntry(url))
{
Reference<css::xml::dom::XNode> extensionNodeNode = writeKeyElement(url);
- writeVectorOfPair( data.items, "extension-items", "item",
- "url", "media-type", extensionNodeNode);
+ writeVectorOfPair( data.items, u"extension-items", u"item",
+ u"url", u"media-type", extensionNodeNode);
save();
}
}
@@ -82,7 +82,7 @@ void ExtensionBackendDb::addEntry(OUString const & url, Data const & data)
}
}
-ExtensionBackendDb::Data ExtensionBackendDb::getEntry(OUString const & url)
+ExtensionBackendDb::Data ExtensionBackendDb::getEntry(std::u16string_view url)
{
try
{
@@ -92,8 +92,8 @@ ExtensionBackendDb::Data ExtensionBackendDb::getEntry(OUString const & url)
if (aNode.is())
{
retData.items =
- readVectorOfPair( aNode, "extension-items", "item",
- "url", "media-type");
+ readVectorOfPair( aNode, u"extension-items", u"item",
+ u"url", u"media-type");
}
return retData;
}
diff --git a/desktop/source/deployment/registry/package/dp_extbackenddb.hxx b/desktop/source/deployment/registry/package/dp_extbackenddb.hxx
index c9a607e7a8c0..fb736e6e260c 100644
--- a/desktop/source/deployment/registry/package/dp_extbackenddb.hxx
+++ b/desktop/source/deployment/registry/package/dp_extbackenddb.hxx
@@ -19,6 +19,9 @@
#pragma once
+#include <sal/config.h>
+
+#include <string_view>
#include <utility>
#include <vector>
@@ -59,7 +62,7 @@ public:
void addEntry(OUString const& url, Data const& data);
- Data getEntry(OUString const& url);
+ Data getEntry(std::u16string_view url);
};
}
diff --git a/desktop/source/deployment/registry/package/dp_package.cxx b/desktop/source/deployment/registry/package/dp_package.cxx
index e0adb4395f4c..0f20a9203ea6 100644
--- a/desktop/source/deployment/registry/package/dp_package.cxx
+++ b/desktop/source/deployment/registry/package/dp_package.cxx
@@ -69,6 +69,7 @@
#include <algorithm>
#include <memory>
+#include <string_view>
#include <vector>
#include "dp_extbackenddb.hxx"
@@ -214,8 +215,8 @@ class BackendImpl : public ImplBaseT
std::unique_ptr<ExtensionBackendDb> m_backendDb;
void addDataToDb(OUString const & url, ExtensionBackendDb::Data const & data);
- ExtensionBackendDb::Data readDataFromDb(OUString const & url);
- void revokeEntryFromDb(OUString const & url);
+ ExtensionBackendDb::Data readDataFromDb(std::u16string_view url);
+ void revokeEntryFromDb(std::u16string_view url);
// PackageRegistryBackend
virtual Reference<deployment::XPackage> bindPackage_(
@@ -419,7 +420,7 @@ void BackendImpl::addDataToDb(
}
ExtensionBackendDb::Data BackendImpl::readDataFromDb(
- OUString const & url)
+ std::u16string_view url)
{
ExtensionBackendDb::Data data;
if (m_backendDb)
@@ -427,7 +428,7 @@ ExtensionBackendDb::Data BackendImpl::readDataFromDb(
return data;
}
-void BackendImpl::revokeEntryFromDb(OUString const & url)
+void BackendImpl::revokeEntryFromDb(std::u16string_view url)
{
if (m_backendDb)
m_backendDb->revokeEntry(url);
diff --git a/desktop/source/deployment/registry/script/dp_script.cxx b/desktop/source/deployment/registry/script/dp_script.cxx
index e4fd8e07fead..fa0cc83d0618 100644
--- a/desktop/source/deployment/registry/script/dp_script.cxx
+++ b/desktop/source/deployment/registry/script/dp_script.cxx
@@ -28,6 +28,8 @@
#include <com/sun/star/util/XUpdatable.hpp>
#include <com/sun/star/script/XLibraryContainer3.hpp>
#include <memory>
+#include <string_view>
+
#include "dp_scriptbackenddb.hxx"
#include <cppuhelper/supportsservice.hxx>
@@ -81,8 +83,8 @@ class BackendImpl : public t_helper
Reference<XCommandEnvironment> const & xCmdEnv ) override;
void addDataToDb(OUString const & url);
- bool hasActiveEntry(OUString const & url);
- void revokeEntryFromDb(OUString const & url);
+ bool hasActiveEntry(std::u16string_view url);
+ void revokeEntryFromDb(std::u16string_view url);
const Reference<deployment::XPackageTypeInfo> m_xBasicLibTypeInfo;
const Reference<deployment::XPackageTypeInfo> m_xDialogLibTypeInfo;
@@ -189,7 +191,7 @@ void BackendImpl::addDataToDb(OUString const & url)
m_backendDb->addEntry(url);
}
-bool BackendImpl::hasActiveEntry(OUString const & url)
+bool BackendImpl::hasActiveEntry(std::u16string_view url)
{
if (m_backendDb)
return m_backendDb->hasActiveEntry(url);
@@ -210,7 +212,7 @@ BackendImpl::getSupportedPackageTypes()
{
return m_typeInfos;
}
-void BackendImpl::revokeEntryFromDb(OUString const & url)
+void BackendImpl::revokeEntryFromDb(std::u16string_view url)
{
if (m_backendDb)
m_backendDb->revokeEntry(url);
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 2b87faecc677..a512f33868ac 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -946,12 +946,12 @@ VclPtr<Window> getSidebarWindow()
// Could be anonymous in principle, but for the unit testing purposes, we
// declare it in init.hxx.
-OUString desktop::extractParameter(OUString& rOptions, const OUString& rName)
+OUString desktop::extractParameter(OUString& rOptions, std::u16string_view rName)
{
OUString aValue;
- OUString aNameEquals(rName + "=");
- OUString aCommaNameEquals("," + rName + "=");
+ OUString aNameEquals(OUString::Concat(rName) + "=");
+ OUString aCommaNameEquals(OUString::Concat(",") + rName + "=");
int nIndex = -1;
if (rOptions.startsWith(aNameEquals))
@@ -2212,7 +2212,7 @@ static LibreOfficeKitDocument* lo_documentLoadWithOptions(LibreOfficeKit* pThis,
// 'Language=...' is an option that LOK consumes by itself, and does
// not pass it as a parameter to the filter
OUString aOptions = getUString(pOptions);
- const OUString aLanguage = extractParameter(aOptions, "Language");
+ const OUString aLanguage = extractParameter(aOptions, u"Language");
bool isValidLangTag = LanguageTag::isValidBcp47(aLanguage, nullptr);
if (!aLanguage.isEmpty() && isValidLangTag)
@@ -2230,7 +2230,7 @@ static LibreOfficeKitDocument* lo_documentLoadWithOptions(LibreOfficeKit* pThis,
SvNumberFormatter::resetTheCurrencyTable();
}
- const OUString aDeviceFormFactor = extractParameter(aOptions, "DeviceFormFactor");
+ const OUString aDeviceFormFactor = extractParameter(aOptions, u"DeviceFormFactor");
SfxLokHelper::setDeviceFormFactor(aDeviceFormFactor);
uno::Sequence<css::beans::PropertyValue> aFilterOptions(3);
@@ -5128,7 +5128,7 @@ static int doc_createViewWithOptions(LibreOfficeKitDocument* pThis,
SetLastExceptionMsg();
OUString aOptions = getUString(pOptions);
- const OUString aLanguage = extractParameter(aOptions, "Language");
+ const OUString aLanguage = extractParameter(aOptions, u"Language");
if (!aLanguage.isEmpty())
{
@@ -5137,7 +5137,7 @@ static int doc_createViewWithOptions(LibreOfficeKitDocument* pThis,
comphelper::LibreOfficeKit::setLocale(LanguageTag(aLanguage));
}
- const OUString aDeviceFormFactor = extractParameter(aOptions, "DeviceFormFactor");
+ const OUString aDeviceFormFactor = extractParameter(aOptions, u"DeviceFormFactor");
SfxLokHelper::setDeviceFormFactor(aDeviceFormFactor);
LibLODocument_Impl* pDocument = static_cast<LibLODocument_Impl*>(pThis);
@@ -6028,9 +6028,9 @@ public:
}
};
-static void activateNotebookbar(const OUString& rApp)
+static void activateNotebookbar(std::u16string_view rApp)
{
- OUString aPath = "org.openoffice.Office.UI.ToolbarMode/Applications/" + rApp;
+ OUString aPath = OUString::Concat("org.openoffice.Office.UI.ToolbarMode/Applications/") + rApp;
const utl::OConfigurationTreeRoot aAppNode(xContext, aPath, true);
@@ -6354,9 +6354,9 @@ static int lo_initialize(LibreOfficeKit* pThis, const char* pAppPath, const char
if (bNotebookbar)
{
- activateNotebookbar("Writer");
- activateNotebookbar("Calc");
- activateNotebookbar("Impress");
+ activateNotebookbar(u"Writer");
+ activateNotebookbar(u"Calc");
+ activateNotebookbar(u"Impress");
}
return bInitialized;
diff --git a/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx b/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx
index 1d4907b9a263..2180695d85b7 100644
--- a/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx
+++ b/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx
@@ -17,6 +17,9 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <sal/config.h>
+
+#include <string_view>
#include <strings.hrc>
#include <dp_misc.h>
@@ -64,7 +67,7 @@ class CommandEnvironmentImpl
/// @throws RuntimeException
void update_( Any const & Status );
- void printLicense(std::u16string_view sName,const OUString& sLicense,
+ void printLicense(std::u16string_view sName,std::u16string_view sLicense,
bool & accept, bool & decline);
public:
@@ -125,7 +128,7 @@ CommandEnvironmentImpl::~CommandEnvironmentImpl()
//May throw exceptions
void CommandEnvironmentImpl::printLicense(
- std::u16string_view sName, const OUString& sLicense, bool & accept, bool &decline)
+ std::u16string_view sName, std::u16string_view sLicense, bool & accept, bool &decline)
{
OUString s1tmp(DpResId(RID_STR_UNOPKG_ACCEPT_LIC_1));
OUString s1(s1tmp.replaceAll("$NAME", sName));
diff --git a/desktop/source/pkgchk/unopkg/unopkg_misc.cxx b/desktop/source/pkgchk/unopkg/unopkg_misc.cxx
index 3b16dc59855e..6861f6459cc0 100644
--- a/desktop/source/pkgchk/unopkg/unopkg_misc.cxx
+++ b/desktop/source/pkgchk/unopkg/unopkg_misc.cxx