summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--UnoControls/source/controls/progressmonitor.cxx2
-rw-r--r--UnoControls/source/inc/progressmonitor.hxx2
-rw-r--r--accessibility/inc/standard/vclxaccessiblelist.hxx2
-rw-r--r--accessibility/source/standard/vclxaccessiblelist.cxx2
-rw-r--r--basctl/source/basicide/basides1.cxx4
-rw-r--r--basctl/source/basicide/basidesh.cxx2
-rw-r--r--basctl/source/basicide/bastype2.cxx4
-rw-r--r--basctl/source/basicide/bastypes.cxx4
-rw-r--r--basctl/source/basicide/scriptdocument.cxx4
-rw-r--r--basctl/source/inc/basidesh.hxx4
-rw-r--r--basctl/source/inc/bastype2.hxx4
-rw-r--r--basctl/source/inc/bastypes.hxx2
-rw-r--r--basctl/source/inc/scriptdocument.hxx2
-rw-r--r--binaryurp/source/bridge.cxx2
-rw-r--r--binaryurp/source/bridge.hxx2
-rw-r--r--chart2/qa/extras/PivotChartTest.cxx126
-rw-r--r--chart2/qa/extras/chart2dump/chart2dump.cxx6
-rw-r--r--chart2/qa/extras/chart2import.cxx4
-rw-r--r--chart2/qa/extras/charttest.hxx2
-rw-r--r--chart2/source/model/template/DataInterpreter.cxx6
-rw-r--r--chart2/source/model/template/DataInterpreter.hxx2
-rw-r--r--chart2/source/view/axes/VCartesianAxis.cxx4
-rw-r--r--chart2/source/view/axes/VPolarAngleAxis.cxx2
-rw-r--r--chart2/source/view/inc/PropertyMapper.hxx2
-rw-r--r--chart2/source/view/main/LabelPositionHelper.cxx10
-rw-r--r--chart2/source/view/main/PropertyMapper.cxx2
-rw-r--r--chart2/source/view/main/VLegend.cxx2
-rw-r--r--chart2/source/view/main/VLegendSymbolFactory.cxx2
-rw-r--r--comphelper/source/misc/mimeconfighelper.cxx8
-rw-r--r--compilerplugins/clang/stringviewparam.cxx42
-rw-r--r--compilerplugins/clang/test/stringviewparam.cxx5
-rw-r--r--connectivity/source/cpool/ZPoolCollection.cxx2
-rw-r--r--connectivity/source/cpool/ZPoolCollection.hxx2
-rw-r--r--connectivity/source/drivers/dbase/DTable.cxx2
-rw-r--r--connectivity/source/drivers/mysqlc/mysqlc_services.cxx2
-rw-r--r--connectivity/source/inc/dbase/DTable.hxx2
-rw-r--r--connectivity/source/parse/sqliterator.cxx2
-rw-r--r--cppu/source/uno/lbenv.cxx8
-rw-r--r--cui/source/customize/SvxNotebookbarConfigPage.cxx6
-rw-r--r--cui/source/customize/cfgutil.cxx2
-rw-r--r--cui/source/dialogs/hlinettp.cxx2
-rw-r--r--cui/source/dialogs/hlmailtp.cxx4
-rw-r--r--cui/source/dialogs/hlmarkwn.cxx4
-rw-r--r--cui/source/dialogs/scriptdlg.cxx6
-rw-r--r--cui/source/inc/cfgutil.hxx2
-rw-r--r--cui/source/inc/cuitabarea.hxx10
-rw-r--r--cui/source/inc/hlinettp.hxx2
-rw-r--r--cui/source/inc/hlmailtp.hxx4
-rw-r--r--cui/source/inc/hlmarkwn.hxx4
-rw-r--r--cui/source/inc/optdict.hxx2
-rw-r--r--cui/source/inc/scriptdlg.hxx6
-rw-r--r--cui/source/inc/treeopt.hxx8
-rw-r--r--cui/source/options/fontsubs.cxx4
-rw-r--r--cui/source/options/optdict.cxx2
-rw-r--r--cui/source/options/optjava.cxx2
-rw-r--r--cui/source/options/optjava.hxx2
-rw-r--r--cui/source/options/optlingu.cxx14
-rw-r--r--cui/source/options/treeopt.cxx50
-rw-r--r--cui/source/tabpages/autocdlg.cxx2
-rw-r--r--cui/source/tabpages/tpbitmap.cxx2
-rw-r--r--cui/source/tabpages/tpcolor.cxx2
-rw-r--r--cui/source/tabpages/tpgradnt.cxx2
-rw-r--r--cui/source/tabpages/tphatch.cxx2
-rw-r--r--cui/source/tabpages/tppattern.cxx2
-rw-r--r--dbaccess/source/core/api/KeySet.cxx16
-rw-r--r--dbaccess/source/core/api/KeySet.hxx4
-rw-r--r--dbaccess/source/core/api/OptimisticSet.cxx2
-rw-r--r--dbaccess/source/core/api/OptimisticSet.hxx2
-rw-r--r--dbaccess/source/core/dataaccess/databaseregistrations.cxx4
-rw-r--r--dbaccess/source/core/misc/dsntypes.cxx4
-rw-r--r--dbaccess/source/inc/dsntypes.hxx2
-rw-r--r--dbaccess/source/ui/app/subcomponentmanager.cxx4
-rw-r--r--dbaccess/source/ui/app/subcomponentmanager.hxx2
-rw-r--r--dbaccess/source/ui/browser/unodatbr.cxx4
-rw-r--r--dbaccess/source/ui/control/FieldDescControl.cxx2
-rw-r--r--dbaccess/source/ui/control/dbtreelistbox.cxx2
-rw-r--r--dbaccess/source/ui/dlg/dbfindex.cxx4
-rw-r--r--dbaccess/source/ui/dlg/dbfindex.hxx4
-rw-r--r--dbaccess/source/ui/dlg/queryfilter.cxx4
-rw-r--r--dbaccess/source/ui/inc/FieldDescControl.hxx2
-rw-r--r--dbaccess/source/ui/inc/QueryDesignView.hxx4
-rw-r--r--dbaccess/source/ui/inc/TableCopyHelper.hxx12
-rw-r--r--dbaccess/source/ui/inc/WColumnSelect.hxx2
-rw-r--r--dbaccess/source/ui/inc/dbtreelistbox.hxx2
-rw-r--r--dbaccess/source/ui/inc/queryfilter.hxx4
-rw-r--r--dbaccess/source/ui/inc/unodatbr.hxx4
-rw-r--r--dbaccess/source/ui/misc/TableCopyHelper.cxx12
-rw-r--r--dbaccess/source/ui/misc/WColumnSelect.cxx2
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignView.cxx6
-rw-r--r--dbaccess/source/ui/querydesign/QueryTableView.cxx2
-rw-r--r--dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx14
-rw-r--r--dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx10
-rw-r--r--dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx2
-rw-r--r--desktop/source/deployment/inc/dp_descriptioninfoset.hxx2
-rw-r--r--desktop/source/deployment/manager/dp_extensionmanager.cxx8
-rw-r--r--desktop/source/deployment/manager/dp_extensionmanager.hxx2
-rw-r--r--desktop/source/deployment/manager/dp_informationprovider.cxx4
-rw-r--r--desktop/source/deployment/misc/dp_descriptioninfoset.cxx2
-rw-r--r--desktop/source/deployment/misc/dp_platform.cxx80
-rw-r--r--desktop/source/deployment/registry/script/dp_script.cxx2
-rw-r--r--desktop/source/lib/init.cxx6
-rw-r--r--desktop/source/migration/migration.cxx6
-rw-r--r--desktop/source/migration/migration_impl.hxx6
-rw-r--r--desktop/source/pkgchk/unopkg/unopkg_app.cxx2
-rw-r--r--editeng/qa/unit/core-test.cxx30
-rw-r--r--editeng/source/editeng/editobj.cxx10
-rw-r--r--editeng/source/editeng/editobj2.hxx6
-rw-r--r--editeng/source/editeng/eertfpar.cxx2
-rw-r--r--editeng/source/editeng/eertfpar.hxx2
-rw-r--r--editeng/source/outliner/outlobj.cxx4
-rw-r--r--embeddedobj/source/commonembedding/persistence.cxx6
-rw-r--r--extensions/source/bibliography/datman.cxx2
-rw-r--r--extensions/source/propctrlr/browserlistbox.cxx2
-rw-r--r--extensions/source/propctrlr/browserlistbox.hxx2
-rw-r--r--extensions/source/propctrlr/cellbindinghelper.cxx2
-rw-r--r--filter/source/xsltdialog/xmlfiltercommon.hxx2
-rw-r--r--filter/source/xsltdialog/xmlfiltersettingsdialog.cxx2
-rw-r--r--forms/source/inc/frm_strings.hxx4
-rw-r--r--forms/source/richtext/richtextmodel.cxx2
-rw-r--r--forms/source/xforms/model_helper.hxx2
-rw-r--r--forms/source/xforms/model_ui.cxx10
-rw-r--r--fpicker/source/office/fileview.cxx8
-rw-r--r--framework/inc/jobs/helponstartup.hxx2
-rw-r--r--framework/inc/targets.h2
-rw-r--r--framework/inc/uielement/menubarmerger.hxx2
-rw-r--r--framework/inc/uielement/statusbarmerger.hxx2
-rw-r--r--framework/inc/uielement/toolbarmerger.hxx2
-rw-r--r--framework/source/classes/framecontainer.cxx2
-rw-r--r--framework/source/fwe/classes/addonmenu.cxx6
-rw-r--r--framework/source/jobs/helponstartup.cxx4
-rw-r--r--framework/source/layoutmanager/toolbarlayoutmanager.cxx44
-rw-r--r--framework/source/layoutmanager/toolbarlayoutmanager.hxx44
-rw-r--r--framework/source/uiconfiguration/ImageList.cxx4
-rw-r--r--framework/source/uiconfiguration/ImageList.hxx2
-rw-r--r--framework/source/uielement/menubarmerger.cxx2
-rw-r--r--framework/source/uielement/statusbarmerger.cxx2
-rw-r--r--framework/source/uielement/toolbarmerger.cxx2
-rw-r--r--i18npool/inc/collatorImpl.hxx2
-rw-r--r--include/comphelper/mimeconfighelper.hxx4
-rw-r--r--include/connectivity/sqliterator.hxx2
-rw-r--r--include/editeng/editobj.hxx4
-rw-r--r--include/editeng/outlobj.hxx4
-rw-r--r--include/framework/framecontainer.hxx2
-rw-r--r--include/oox/crypto/StrongEncryptionDataSpace.hxx2
-rw-r--r--include/oox/export/drawingml.hxx2
-rw-r--r--include/sfx2/StyleManager.hxx2
-rw-r--r--include/sfx2/classificationhelper.hxx2
-rw-r--r--include/sfx2/docfac.hxx2
-rw-r--r--include/sfx2/doctempl.hxx2
-rw-r--r--include/sfx2/fcontnr.hxx2
-rw-r--r--include/sfx2/infobar.hxx4
-rw-r--r--include/sfx2/objsh.hxx2
-rw-r--r--include/sfx2/sidebar/Deck.hxx2
-rw-r--r--include/sfx2/sidebar/Panel.hxx2
-rw-r--r--include/sfx2/sidebar/ResourceManager.hxx14
-rw-r--r--include/sfx2/sidebar/Sidebar.hxx8
-rw-r--r--include/sfx2/sidebar/SidebarController.hxx18
-rw-r--r--include/sfx2/sidebar/TabBar.hxx2
-rw-r--r--include/sfx2/templatedlg.hxx2
-rw-r--r--include/sfx2/templatedlglocalview.hxx2
-rw-r--r--include/sfx2/templatelocalview.hxx8
-rw-r--r--include/sfx2/viewfrm.hxx6
-rw-r--r--include/sot/stg.hxx2
-rw-r--r--include/svl/style.hxx2
-rw-r--r--include/svl/zforlist.hxx18
-rw-r--r--include/svtools/inettbc.hxx2
-rw-r--r--include/svtools/insdlg.hxx2
-rw-r--r--include/svtools/langtab.hxx2
-rw-r--r--include/svx/ClassificationCommon.hxx2
-rw-r--r--include/svx/ColorSets.hxx2
-rw-r--r--include/svx/ctredlin.hxx4
-rw-r--r--include/svx/gallery.hxx14
-rw-r--r--include/svx/gallery1.hxx8
-rw-r--r--include/svx/gallerybinaryengineentry.hxx2
-rw-r--r--include/svx/numfmtsh.hxx8
-rw-r--r--include/svx/xtable.hxx2
-rw-r--r--include/test/xmltesttools.hxx4
-rw-r--r--include/unotools/compatibility.hxx2
-rw-r--r--include/unotools/lingucfg.hxx2
-rw-r--r--include/vcl/toolkit/combobox.hxx2
-rw-r--r--include/vcl/toolkit/lstbox.hxx4
-rw-r--r--include/xmloff/odffields.hxx2
-rw-r--r--include/xmloff/table/XMLTableExport.hxx2
-rw-r--r--include/xmloff/xmlprmap.hxx4
-rw-r--r--linguistic/source/convdic.cxx4
-rw-r--r--linguistic/source/convdic.hxx4
-rw-r--r--linguistic/source/convdiclist.cxx12
-rw-r--r--linguistic/source/spelldsp.cxx4
-rw-r--r--linguistic/source/spelldta.cxx2
-rw-r--r--lotuswordpro/inc/lwpfoundry.hxx2
-rw-r--r--lotuswordpro/inc/xfilter/xfstylecont.hxx2
-rw-r--r--lotuswordpro/inc/xfilter/xfstylemanager.hxx6
-rw-r--r--lotuswordpro/source/filter/lwpdoc.cxx2
-rw-r--r--lotuswordpro/source/filter/lwpfoundry.cxx2
-rw-r--r--lotuswordpro/source/filter/lwpfribmark.cxx2
-rw-r--r--lotuswordpro/source/filter/lwpmarker.cxx2
-rw-r--r--lotuswordpro/source/filter/lwpmarker.hxx2
-rw-r--r--lotuswordpro/source/filter/lwpproplist.cxx6
-rw-r--r--lotuswordpro/source/filter/lwpproplist.hxx6
-rw-r--r--lotuswordpro/source/filter/xfilter/xfstylecont.cxx2
-rw-r--r--lotuswordpro/source/filter/xfilter/xfstylemanager.cxx6
-rw-r--r--oox/inc/drawingml/customshapeproperties.hxx2
-rw-r--r--oox/source/crypto/StrongEncryptionDataSpace.cxx4
-rw-r--r--oox/source/drawingml/customshapeproperties.cxx2
-rw-r--r--oox/source/drawingml/diagram/datamodel.cxx2
-rw-r--r--oox/source/drawingml/diagram/diagramlayoutatoms.cxx4
-rw-r--r--oox/source/export/drawingml.cxx6
-rw-r--r--opencl/source/openclwrapper.cxx2
-rw-r--r--sax/qa/cppunit/xmlimport.cxx8
-rw-r--r--sc/inc/ChartTools.hxx4
-rw-r--r--sc/inc/afmtuno.hxx2
-rw-r--r--sc/inc/arealink.hxx4
-rw-r--r--sc/inc/conditio.hxx4
-rw-r--r--sc/inc/docpool.hxx2
-rw-r--r--sc/inc/document.hxx28
-rw-r--r--sc/inc/documentlinkmgr.hxx2
-rw-r--r--sc/inc/docuno.hxx4
-rw-r--r--sc/inc/dpcache.hxx2
-rw-r--r--sc/inc/dpgroup.hxx2
-rw-r--r--sc/inc/dpobject.hxx8
-rw-r--r--sc/inc/dpsave.hxx6
-rw-r--r--sc/inc/dptabsrc.hxx2
-rw-r--r--sc/inc/drwlayer.hxx2
-rw-r--r--sc/inc/externalrefmgr.hxx2
-rw-r--r--sc/inc/linkuno.hxx2
-rw-r--r--sc/inc/userlist.hxx2
-rw-r--r--sc/qa/unit/pivottable_filters_test.cxx70
-rw-r--r--sc/qa/unit/subsequent_export-test.cxx2
-rw-r--r--sc/qa/unit/ucalc.cxx2
-rw-r--r--sc/qa/unit/ucalc.hxx2
-rw-r--r--sc/qa/unit/ucalc_pivottable.cxx30
-rw-r--r--sc/source/core/data/conditio.cxx4
-rw-r--r--sc/source/core/data/docpool.cxx2
-rw-r--r--sc/source/core/data/documen3.cxx4
-rw-r--r--sc/source/core/data/documen5.cxx12
-rw-r--r--sc/source/core/data/documen8.cxx12
-rw-r--r--sc/source/core/data/dpcache.cxx2
-rw-r--r--sc/source/core/data/dpgroup.cxx2
-rw-r--r--sc/source/core/data/dpobject.cxx8
-rw-r--r--sc/source/core/data/dpsave.cxx6
-rw-r--r--sc/source/core/data/dptabsrc.cxx2
-rw-r--r--sc/source/core/data/drwlayer.cxx4
-rw-r--r--sc/source/core/tool/addincol.cxx4
-rw-r--r--sc/source/core/tool/interpr2.cxx2
-rw-r--r--sc/source/core/tool/interpr7.cxx2
-rw-r--r--sc/source/core/tool/userlist.cxx2
-rw-r--r--sc/source/filter/excel/xechart.cxx4
-rw-r--r--sc/source/filter/excel/xelink.cxx24
-rw-r--r--sc/source/filter/excel/xepivot.cxx14
-rw-r--r--sc/source/filter/excel/xiname.cxx2
-rw-r--r--sc/source/filter/inc/xechart.hxx4
-rw-r--r--sc/source/filter/inc/xepivot.hxx12
-rw-r--r--sc/source/filter/inc/xiname.hxx2
-rw-r--r--sc/source/filter/inc/xlchart.hxx26
-rw-r--r--sc/source/filter/oox/condformatbuffer.cxx2
-rw-r--r--sc/source/filter/oox/formulabuffer.cxx2
-rw-r--r--sc/source/filter/oox/querytablebuffer.cxx4
-rw-r--r--sc/source/filter/xml/xmlexprt.cxx58
-rw-r--r--sc/source/filter/xml/xmlimprt.cxx2
-rw-r--r--sc/source/filter/xml/xmlimprt.hxx2
-rw-r--r--sc/source/ui/cctrl/checklistmenu.cxx6
-rw-r--r--sc/source/ui/dbgui/pvfundlg.cxx4
-rw-r--r--sc/source/ui/dbgui/scuiimoptdlg.cxx4
-rw-r--r--sc/source/ui/docshell/arealink.cxx4
-rw-r--r--sc/source/ui/docshell/docsh4.cxx6
-rw-r--r--sc/source/ui/docshell/documentlinkmgr.cxx2
-rw-r--r--sc/source/ui/docshell/externalrefmgr.cxx2
-rw-r--r--sc/source/ui/inc/checklistmenu.hxx6
-rw-r--r--sc/source/ui/inc/content.hxx2
-rw-r--r--sc/source/ui/inc/docsh.hxx2
-rw-r--r--sc/source/ui/inc/drawview.hxx6
-rw-r--r--sc/source/ui/inc/navipi.hxx2
-rw-r--r--sc/source/ui/inc/pvfundlg.hxx4
-rw-r--r--sc/source/ui/inc/solverutil.hxx4
-rw-r--r--sc/source/ui/inc/tabview.hxx2
-rw-r--r--sc/source/ui/inc/tabvwsh.hxx2
-rw-r--r--sc/source/ui/inc/viewfunc.hxx4
-rw-r--r--sc/source/ui/miscdlgs/solverutil.cxx4
-rw-r--r--sc/source/ui/navipi/content.cxx4
-rw-r--r--sc/source/ui/navipi/navipi.cxx2
-rw-r--r--sc/source/ui/undo/undoblk3.cxx6
-rw-r--r--sc/source/ui/unoobj/ChartTools.cxx4
-rw-r--r--sc/source/ui/unoobj/afmtuno.cxx4
-rw-r--r--sc/source/ui/unoobj/cellsuno.cxx4
-rw-r--r--sc/source/ui/unoobj/dapiuno.cxx2
-rw-r--r--sc/source/ui/unoobj/docuno.cxx4
-rw-r--r--sc/source/ui/unoobj/eventuno.cxx2
-rw-r--r--sc/source/ui/unoobj/linkuno.cxx2
-rw-r--r--sc/source/ui/vba/vbaworksheet.cxx2
-rw-r--r--sc/source/ui/vba/vbaworksheet.hxx2
-rw-r--r--sc/source/ui/vba/vbaworksheets.cxx2
-rw-r--r--sc/source/ui/vba/vbaworksheets.hxx2
-rw-r--r--sc/source/ui/view/dbfunc3.cxx2
-rw-r--r--sc/source/ui/view/drawview.cxx6
-rw-r--r--sc/source/ui/view/gridwin.cxx2
-rw-r--r--sc/source/ui/view/tabview3.cxx2
-rw-r--r--sc/source/ui/view/tabvwsh2.cxx2
-rw-r--r--sc/source/ui/view/tabvwsh3.cxx2
-rw-r--r--sc/source/ui/view/tabvwsh9.cxx2
-rw-r--r--sc/source/ui/view/tabvwsha.cxx2
-rw-r--r--sc/source/ui/view/viewfun2.cxx4
-rw-r--r--sc/source/ui/view/viewfun5.cxx2
-rw-r--r--sc/source/ui/view/viewfun7.cxx2
-rw-r--r--scaddins/source/analysis/analysishelper.hxx4
-rw-r--r--scaddins/source/datefunc/datefunc.hxx2
-rw-r--r--scaddins/source/pricing/pricing.hxx2
-rw-r--r--sd/inc/CustomAnimationEffect.hxx4
-rw-r--r--sd/inc/CustomAnimationPreset.hxx2
-rw-r--r--sd/inc/drawdoc.hxx6
-rw-r--r--sd/qa/unit/export-tests.cxx2
-rw-r--r--sd/qa/unit/tiledrendering/tiledrendering.cxx4
-rw-r--r--sd/source/core/CustomAnimationEffect.cxx4
-rw-r--r--sd/source/core/CustomAnimationPreset.cxx2
-rw-r--r--sd/source/core/drawdoc2.cxx6
-rw-r--r--sd/source/core/drawdoc3.cxx4
-rw-r--r--sd/source/core/stlpool.cxx4
-rw-r--r--sd/source/filter/eppt/pptexsoundcollection.cxx2
-rw-r--r--sd/source/filter/eppt/pptexsoundcollection.hxx2
-rw-r--r--sd/source/ui/animations/CustomAnimationPane.cxx26
-rw-r--r--sd/source/ui/annotations/annotationmanager.cxx2
-rw-r--r--sd/source/ui/annotations/annotationmanagerimpl.hxx2
-rw-r--r--sd/source/ui/dlg/LayerTabBar.cxx2
-rw-r--r--sd/source/ui/dlg/sdtreelb.cxx10
-rw-r--r--sd/source/ui/docshell/docshel2.cxx2
-rw-r--r--sd/source/ui/docshell/docshel3.cxx6
-rw-r--r--sd/source/ui/framework/factories/BasicPaneFactory.cxx2
-rw-r--r--sd/source/ui/func/fuconrec.cxx4
-rw-r--r--sd/source/ui/inc/DrawDocShell.hxx2
-rw-r--r--sd/source/ui/inc/LayerTabBar.hxx2
-rw-r--r--sd/source/ui/inc/RemoteServer.hxx2
-rw-r--r--sd/source/ui/inc/sdtreelb.hxx6
-rw-r--r--sd/source/ui/inc/unomodel.hxx2
-rw-r--r--sd/source/ui/inc/unopage.hxx2
-rw-r--r--sd/source/ui/remotecontrol/Server.cxx2
-rw-r--r--sd/source/ui/slideshow/slideshowimpl.cxx6
-rw-r--r--sd/source/ui/slideshow/slideshowimpl.hxx2
-rw-r--r--sd/source/ui/slidesorter/controller/SlsSlotManager.cxx4
-rw-r--r--sd/source/ui/table/tablefunction.cxx2
-rw-r--r--sd/source/ui/uitest/uiobject.cxx2
-rw-r--r--sd/source/ui/unoidl/unocpres.cxx2
-rw-r--r--sd/source/ui/unoidl/unocpres.hxx2
-rw-r--r--sd/source/ui/unoidl/unomodel.cxx2
-rw-r--r--sd/source/ui/unoidl/unopage.cxx2
-rw-r--r--sd/source/ui/view/ViewShellImplementation.cxx2
-rw-r--r--sd/source/ui/view/drviews2.cxx2
-rw-r--r--sdext/source/minimizer/impoptimizer.cxx2
-rw-r--r--sdext/source/minimizer/pagecollector.cxx4
-rw-r--r--sdext/source/minimizer/pagecollector.hxx4
-rw-r--r--sdext/source/presenter/PresenterConfigurationAccess.cxx2
-rw-r--r--sdext/source/presenter/PresenterConfigurationAccess.hxx2
-rw-r--r--sfx2/inc/autoredactdialog.hxx4
-rw-r--r--sfx2/source/appl/newhelp.cxx2
-rw-r--r--sfx2/source/appl/newhelp.hxx2
-rw-r--r--sfx2/source/bastyp/fltfnc.cxx2
-rw-r--r--sfx2/source/control/templatedlglocalview.cxx2
-rw-r--r--sfx2/source/control/templatelocalview.cxx8
-rw-r--r--sfx2/source/dialog/filedlghelper.cxx4
-rw-r--r--sfx2/source/dialog/filedlgimpl.hxx4
-rw-r--r--sfx2/source/dialog/infobar.cxx4
-rw-r--r--sfx2/source/dialog/templdlg.cxx2
-rw-r--r--sfx2/source/doc/autoredactdialog.cxx4
-rw-r--r--sfx2/source/doc/docfac.cxx2
-rw-r--r--sfx2/source/doc/doctempl.cxx8
-rw-r--r--sfx2/source/doc/doctemplates.cxx8
-rw-r--r--sfx2/source/doc/objcont.cxx4
-rw-r--r--sfx2/source/doc/objmisc.cxx4
-rw-r--r--sfx2/source/doc/objserv.cxx10
-rw-r--r--sfx2/source/doc/templatedlg.cxx2
-rw-r--r--sfx2/source/sidebar/Deck.cxx2
-rw-r--r--sfx2/source/sidebar/Panel.cxx2
-rw-r--r--sfx2/source/sidebar/ResourceManager.cxx14
-rw-r--r--sfx2/source/sidebar/Sidebar.cxx8
-rw-r--r--sfx2/source/sidebar/SidebarController.cxx20
-rw-r--r--sfx2/source/sidebar/SidebarDockingWindow.cxx2
-rw-r--r--sfx2/source/sidebar/TabBar.cxx2
-rw-r--r--sfx2/source/styles/StyleManager.cxx2
-rw-r--r--sfx2/source/view/classificationhelper.cxx8
-rw-r--r--sfx2/source/view/viewfrm.cxx10
-rw-r--r--sot/source/sdstor/ucbstorage.cxx6
-rw-r--r--starmath/inc/dialog.hxx4
-rw-r--r--starmath/inc/smmod.hxx4
-rw-r--r--starmath/inc/symbol.hxx2
-rw-r--r--starmath/source/cfgitem.cxx4
-rw-r--r--starmath/source/cfgitem.hxx4
-rw-r--r--starmath/source/dialog.cxx6
-rw-r--r--starmath/source/parse.cxx2
-rw-r--r--starmath/source/smmod.cxx4
-rw-r--r--starmath/source/symbol.cxx4
-rw-r--r--stoc/source/implementationregistration/implreg.cxx12
-rw-r--r--stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx4
-rw-r--r--svl/source/items/style.cxx2
-rw-r--r--svl/source/numbers/zforfind.cxx2
-rw-r--r--svl/source/numbers/zforfind.hxx2
-rw-r--r--svl/source/numbers/zforlist.cxx22
-rw-r--r--svl/source/passwordcontainer/passwordcontainer.cxx8
-rw-r--r--svl/source/passwordcontainer/passwordcontainer.hxx6
-rw-r--r--svtools/source/dialogs/insdlg.cxx2
-rw-r--r--svtools/source/misc/langtab.cxx6
-rw-r--r--svx/inc/galbrws2.hxx2
-rw-r--r--svx/source/dialog/ClassificationCommon.cxx2
-rw-r--r--svx/source/dialog/ctredlin.cxx4
-rw-r--r--svx/source/gallery2/galbrws1.cxx2
-rw-r--r--svx/source/gallery2/galbrws1.hxx2
-rw-r--r--svx/source/gallery2/galbrws2.cxx2
-rw-r--r--svx/source/gallery2/galexpl.cxx14
-rw-r--r--svx/source/gallery2/galini.cxx2
-rw-r--r--svx/source/gallery2/gallery1.cxx10
-rw-r--r--svx/source/inc/datanavi.hxx4
-rw-r--r--svx/source/items/numfmtsh.cxx8
-rw-r--r--svx/source/styles/ColorSets.cxx2
-rw-r--r--svx/source/svdraw/svdotext.cxx6
-rw-r--r--svx/source/tbxctrls/tbcontrl.cxx6
-rw-r--r--svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.cxx6
-rw-r--r--svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.hxx6
-rw-r--r--svx/source/unodraw/unomtabl.cxx2
-rw-r--r--svx/source/unogallery/unogaltheme.cxx2
-rw-r--r--svx/source/unogallery/unogaltheme.hxx2
-rw-r--r--svx/source/xoutdev/xtable.cxx2
-rw-r--r--sw/inc/PostItMgr.hxx2
-rw-r--r--sw/inc/authfld.hxx2
-rw-r--r--sw/inc/cellfml.hxx2
-rw-r--r--sw/inc/crsrsh.hxx4
-rw-r--r--sw/inc/doc.hxx20
-rw-r--r--sw/inc/editsh.hxx10
-rw-r--r--sw/inc/format.hxx2
-rw-r--r--sw/inc/iodetect.hxx6
-rw-r--r--sw/inc/pagedesc.hxx6
-rw-r--r--sw/inc/swcrsr.hxx2
-rw-r--r--sw/inc/tblafmt.hxx6
-rw-r--r--sw/inc/unostyle.hxx2
-rw-r--r--sw/qa/core/uwriter.cxx2
-rw-r--r--sw/qa/extras/layout/layout.cxx2
-rw-r--r--sw/qa/extras/odfimport/odfimport.cxx6
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport10.cxx2
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport13.cxx4
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport4.cxx2
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport6.cxx6
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport9.cxx2
-rw-r--r--sw/qa/extras/ooxmlimport/ooxmlimport.cxx2
-rw-r--r--sw/qa/extras/ooxmlimport/ooxmlimport2.cxx6
-rw-r--r--sw/qa/extras/rtfimport/rtfimport.cxx8
-rw-r--r--sw/qa/extras/uiwriter/uiwriter.cxx28
-rw-r--r--sw/qa/extras/unowriter/unowriter.cxx4
-rw-r--r--sw/qa/extras/ww8import/ww8import.cxx4
-rw-r--r--sw/qa/inc/swmodeltestbase.hxx2
-rw-r--r--sw/qa/unit/swmodeltestbase.cxx2
-rw-r--r--sw/source/core/crsr/crstrvl.cxx2
-rw-r--r--sw/source/core/crsr/trvlreg.cxx4
-rw-r--r--sw/source/core/doc/doc.cxx4
-rw-r--r--sw/source/core/doc/docchart.cxx2
-rw-r--r--sw/source/core/doc/docfmt.cxx4
-rw-r--r--sw/source/core/doc/docglbl.cxx2
-rw-r--r--sw/source/core/doc/docnum.cxx2
-rw-r--r--sw/source/core/doc/tblafmt.cxx6
-rw-r--r--sw/source/core/docnode/ndtbl.cxx4
-rw-r--r--sw/source/core/edit/edfcol.cxx16
-rw-r--r--sw/source/core/edit/edfmt.cxx4
-rw-r--r--sw/source/core/edit/editsh.cxx6
-rw-r--r--sw/source/core/fields/authfld.cxx2
-rw-r--r--sw/source/core/fields/cellfml.cxx2
-rw-r--r--sw/source/core/layout/pagedesc.cxx2
-rw-r--r--sw/source/core/text/porlay.hxx2
-rw-r--r--sw/source/core/text/txtftn.cxx2
-rw-r--r--sw/source/core/txtnode/ndtxt.cxx4
-rw-r--r--sw/source/core/unocore/unochart.cxx2
-rw-r--r--sw/source/core/unocore/unostyle.cxx6
-rw-r--r--sw/source/filter/basflt/iodetect.cxx2
-rw-r--r--sw/source/filter/ww8/docxattributeoutput.cxx2
-rw-r--r--sw/source/filter/ww8/ww8par.cxx4
-rw-r--r--sw/source/filter/ww8/ww8par.hxx4
-rw-r--r--sw/source/filter/ww8/ww8par2.cxx2
-rw-r--r--sw/source/filter/xml/XMLRedlineImportHelper.cxx2
-rw-r--r--sw/source/filter/xml/XMLRedlineImportHelper.hxx2
-rw-r--r--sw/source/ui/dbui/selectdbtabledialog.cxx2
-rw-r--r--sw/source/ui/dbui/selectdbtabledialog.hxx2
-rw-r--r--sw/source/ui/dialog/uiregionsw.cxx2
-rw-r--r--sw/source/ui/envelp/label1.cxx2
-rw-r--r--sw/source/ui/fldui/changedb.cxx2
-rw-r--r--sw/source/ui/fldui/flddb.cxx4
-rw-r--r--sw/source/ui/index/swuiidxmrk.cxx2
-rw-r--r--sw/source/ui/misc/glossary.cxx6
-rw-r--r--sw/source/ui/misc/outline.cxx2
-rw-r--r--sw/source/ui/vba/vbadocument.cxx2
-rw-r--r--sw/source/ui/vba/vbadocument.hxx2
-rw-r--r--sw/source/uibase/app/docsh2.cxx4
-rw-r--r--sw/source/uibase/app/docstyle.cxx2
-rw-r--r--sw/source/uibase/dbui/dbtree.cxx6
-rw-r--r--sw/source/uibase/docvw/PostItMgr.cxx2
-rw-r--r--sw/source/uibase/fldui/fldmgr.cxx2
-rw-r--r--sw/source/uibase/inc/dbtree.hxx4
-rw-r--r--sw/source/uibase/inc/fldmgr.hxx2
-rw-r--r--sw/source/uibase/inc/gloslst.hxx4
-rw-r--r--sw/source/uibase/inc/glossary.hxx2
-rw-r--r--sw/source/uibase/inc/label.hxx2
-rw-r--r--sw/source/uibase/inc/langhelper.hxx4
-rw-r--r--sw/source/uibase/inc/outline.hxx2
-rw-r--r--sw/source/uibase/inc/regionsw.hxx2
-rw-r--r--sw/source/uibase/inc/wrtsh.hxx6
-rw-r--r--sw/source/uibase/shells/frmsh.cxx2
-rw-r--r--sw/source/uibase/shells/langhelper.cxx4
-rw-r--r--sw/source/uibase/sidebar/StylePresetsPanel.cxx8
-rw-r--r--sw/source/uibase/sidebar/ThemePanel.cxx6
-rw-r--r--sw/source/uibase/uiview/view2.cxx2
-rw-r--r--sw/source/uibase/utlui/content.cxx4
-rw-r--r--sw/source/uibase/utlui/gloslst.cxx4
-rw-r--r--sw/source/uibase/wrtsh/move.cxx2
-rw-r--r--sw/source/uibase/wrtsh/wrtsh1.cxx8
-rw-r--r--test/source/text/textsettings.cxx2
-rw-r--r--test/source/xmltesttools.cxx2
-rw-r--r--toolkit/inc/controls/controlmodelcontainerbase.hxx2
-rw-r--r--toolkit/source/controls/controlmodelcontainerbase.cxx2
-rw-r--r--tools/qa/cppunit/test_color.cxx34
-rw-r--r--ucb/source/cacher/cachedcontentresultset.cxx12
-rw-r--r--ucb/source/ucp/ftp/ftpcontentprovider.cxx6
-rw-r--r--ucb/source/ucp/ftp/ftpcontentprovider.hxx6
-rw-r--r--ucbhelper/source/client/proxydecider.cxx2
-rw-r--r--ucbhelper/source/provider/contentinfo.cxx4
-rw-r--r--ucbhelper/source/provider/contentinfo.hxx4
-rw-r--r--ucbhelper/source/provider/resultset.cxx4
-rw-r--r--unoidl/source/sourceprovider-parser.y4
-rw-r--r--unoidl/source/sourceprovider-scanner.hxx2
-rw-r--r--unotools/source/config/lingucfg.cxx4
-rw-r--r--unotools/source/misc/fontdefs.cxx2
-rw-r--r--uui/source/iahndl-ioexceptions.cxx18
-rw-r--r--vcl/inc/fontinstance.hxx2
-rw-r--r--vcl/inc/listbox.hxx2
-rw-r--r--vcl/inc/outdev.h2
-rw-r--r--vcl/inc/ppdparser.hxx4
-rw-r--r--vcl/source/control/combobox.cxx2
-rw-r--r--vcl/source/control/imp_listbox.cxx2
-rw-r--r--vcl/source/control/listbox.cxx4
-rw-r--r--vcl/source/filter/graphicfilter.cxx2
-rw-r--r--vcl/source/font/fontinstance.cxx2
-rw-r--r--vcl/source/outdev/font.cxx2
-rw-r--r--vcl/unx/generic/printer/ppdparser.cxx4
-rw-r--r--vcl/workben/vcldemo.cxx4
-rw-r--r--writerfilter/source/dmapper/DomainMapperTableHandler.cxx2
-rw-r--r--writerfilter/source/dmapper/DomainMapper_Impl.cxx2
-rw-r--r--writerfilter/source/dmapper/DomainMapper_Impl.hxx2
-rw-r--r--writerfilter/source/dmapper/NumberingManager.cxx2
-rw-r--r--writerfilter/source/dmapper/PropertyMap.cxx18
-rw-r--r--writerfilter/source/dmapper/SettingsTable.cxx2
-rw-r--r--writerfilter/source/dmapper/SettingsTable.hxx2
-rw-r--r--writerfilter/source/dmapper/StyleSheetTable.cxx4
-rw-r--r--writerfilter/source/dmapper/StyleSheetTable.hxx4
-rw-r--r--writerfilter/source/rtftok/rtfdocumentimpl.cxx2
-rw-r--r--writerperfect/qa/unit/EPUBExportTest.cxx58
-rw-r--r--writerperfect/source/common/DirectoryStream.cxx2
-rw-r--r--xmlhelp/source/cxxhelp/provider/databases.cxx2
-rw-r--r--xmlhelp/source/cxxhelp/provider/databases.hxx2
-rw-r--r--xmloff/inc/txtlists.hxx4
-rw-r--r--xmloff/source/chart/SchXMLAxisContext.cxx2
-rw-r--r--xmloff/source/chart/SchXMLExport.cxx2
-rw-r--r--xmloff/source/chart/SchXMLPlotAreaContext.cxx32
-rw-r--r--xmloff/source/chart/SchXMLSeries2Context.cxx10
-rw-r--r--xmloff/source/chart/SchXMLTools.cxx2
-rw-r--r--xmloff/source/chart/SchXMLTools.hxx2
-rw-r--r--xmloff/source/draw/XMLGraphicsDefaultStyle.cxx6
-rw-r--r--xmloff/source/draw/sdxmlexp.cxx4
-rw-r--r--xmloff/source/draw/sdxmlexp_impl.hxx2
-rw-r--r--xmloff/source/draw/ximpstyl.cxx2
-rw-r--r--xmloff/source/forms/formcellbinding.cxx2
-rw-r--r--xmloff/source/style/xmlnumfi.cxx4
-rw-r--r--xmloff/source/style/xmlprmap.cxx4
-rw-r--r--xmloff/source/table/XMLTableExport.cxx2
-rw-r--r--xmloff/source/text/txtexppr.cxx4
-rw-r--r--xmloff/source/text/txtimp.cxx6
-rw-r--r--xmloff/source/text/txtlists.cxx8
-rw-r--r--xmlscript/source/xmldlg_imexp/imp_share.hxx2
-rw-r--r--xmlscript/source/xmldlg_imexp/xmldlg_import.cxx2
-rw-r--r--xmlsecurity/inc/xsecctl.hxx2
-rw-r--r--xmlsecurity/source/component/certificatecontainer.cxx12
-rw-r--r--xmlsecurity/source/helper/xsecverify.cxx2
573 files changed, 1502 insertions, 1469 deletions
diff --git a/UnoControls/source/controls/progressmonitor.cxx b/UnoControls/source/controls/progressmonitor.cxx
index cabbdc1e4204..9902758f8536 100644
--- a/UnoControls/source/controls/progressmonitor.cxx
+++ b/UnoControls/source/controls/progressmonitor.cxx
@@ -788,7 +788,7 @@ void ProgressMonitor::impl_cleanMemory ()
}
// private method
-IMPL_TextlistItem* ProgressMonitor::impl_searchTopic ( const OUString& rTopic, bool bbeforeProgress )
+IMPL_TextlistItem* ProgressMonitor::impl_searchTopic ( std::u16string_view rTopic, bool bbeforeProgress )
{
// Get right textlist for following operations.
::std::vector< std::unique_ptr<IMPL_TextlistItem> >* pTextList;
diff --git a/UnoControls/source/inc/progressmonitor.hxx b/UnoControls/source/inc/progressmonitor.hxx
index ad4accba562d..7be8056396f3 100644
--- a/UnoControls/source/inc/progressmonitor.hxx
+++ b/UnoControls/source/inc/progressmonitor.hxx
@@ -219,7 +219,7 @@ private:
void impl_cleanMemory();
- IMPL_TextlistItem* impl_searchTopic( const OUString& sTopic , bool bbeforeProgress );
+ IMPL_TextlistItem* impl_searchTopic( std::u16string_view sTopic , bool bbeforeProgress );
// debug methods
diff --git a/accessibility/inc/standard/vclxaccessiblelist.hxx b/accessibility/inc/standard/vclxaccessiblelist.hxx
index 7d05067b0aa6..49f48d9b8b56 100644
--- a/accessibility/inc/standard/vclxaccessiblelist.hxx
+++ b/accessibility/inc/standard/vclxaccessiblelist.hxx
@@ -74,7 +74,7 @@ public:
This string contains the text of the currently selected
item. It is used to retrieve the index of that item.
*/
- void UpdateSelection (const OUString& sTextOfSelectedItem);
+ void UpdateSelection (std::u16string_view sTextOfSelectedItem);
// XInterface
DECLARE_XINTERFACE()
diff --git a/accessibility/source/standard/vclxaccessiblelist.cxx b/accessibility/source/standard/vclxaccessiblelist.cxx
index ecb3274d0b0e..353312e6bbae 100644
--- a/accessibility/source/standard/vclxaccessiblelist.cxx
+++ b/accessibility/source/standard/vclxaccessiblelist.cxx
@@ -435,7 +435,7 @@ void VCLXAccessibleList::ProcessWindowEvent (const VclWindowEvent& rVclWindowEve
state of the associated accessibility objects accordingly we exploit the
fact that the
*/
-void VCLXAccessibleList::UpdateSelection (const OUString& sTextOfSelectedItem)
+void VCLXAccessibleList::UpdateSelection (std::u16string_view sTextOfSelectedItem)
{
if ( m_aBoxType != COMBOBOX )
return;
diff --git a/basctl/source/basicide/basides1.cxx b/basctl/source/basicide/basides1.cxx
index 25967f4f4ca4..d49060c0719d 100644
--- a/basctl/source/basicide/basides1.cxx
+++ b/basctl/source/basicide/basides1.cxx
@@ -1250,12 +1250,12 @@ void Shell::ManageToolbars()
VclPtr<BaseWindow> Shell::FindApplicationWindow()
{
- return FindWindow( ScriptDocument::getApplicationScriptDocument(), "", "", TYPE_UNKNOWN );
+ return FindWindow( ScriptDocument::getApplicationScriptDocument(), u"", u"", TYPE_UNKNOWN );
}
VclPtr<BaseWindow> Shell::FindWindow(
ScriptDocument const& rDocument,
- OUString const& rLibName, OUString const& rName,
+ std::u16string_view rLibName, std::u16string_view rName,
ItemType eType, bool bFindSuspended
)
{
diff --git a/basctl/source/basicide/basidesh.cxx b/basctl/source/basicide/basidesh.cxx
index 3cf2ed621457..28fea6e3dcc1 100644
--- a/basctl/source/basicide/basidesh.cxx
+++ b/basctl/source/basicide/basidesh.cxx
@@ -563,7 +563,7 @@ void Shell::CheckWindows()
}
-void Shell::RemoveWindows( const ScriptDocument& rDocument, const OUString& rLibName )
+void Shell::RemoveWindows( const ScriptDocument& rDocument, std::u16string_view rLibName )
{
bool bChangeCurWindow = pCurWin;
std::vector<VclPtr<BaseWindow> > aDeleteVec;
diff --git a/basctl/source/basicide/bastype2.cxx b/basctl/source/basicide/bastype2.cxx
index 904ff8307670..eed521ce3fd6 100644
--- a/basctl/source/basicide/bastype2.cxx
+++ b/basctl/source/basicide/bastype2.cxx
@@ -475,7 +475,7 @@ void SbTreeListBox::ImpCreateLibSubSubEntriesInVBAMode(const weld::TreeIter& rLi
}
}
-bool SbTreeListBox::ImpFindEntry(weld::TreeIter& rIter, const OUString& rText)
+bool SbTreeListBox::ImpFindEntry(weld::TreeIter& rIter, std::u16string_view rText)
{
bool bValidIter = m_xControl->iter_children(rIter);
while (bValidIter)
@@ -599,7 +599,7 @@ void SbTreeListBox::RemoveEntry (ScriptDocument const& rDocument)
}
}
-bool SbTreeListBox::FindEntry(const OUString& rText, EntryType eType, weld::TreeIter& rIter)
+bool SbTreeListBox::FindEntry(std::u16string_view rText, EntryType eType, weld::TreeIter& rIter)
{
bool bValidIter = m_xControl->iter_children(rIter);
while (bValidIter)
diff --git a/basctl/source/basicide/bastypes.cxx b/basctl/source/basicide/bastypes.cxx
index eabb6ea12f69..99a54894a3e8 100644
--- a/basctl/source/basicide/bastypes.cxx
+++ b/basctl/source/basicide/bastypes.cxx
@@ -226,14 +226,14 @@ void BaseWindow::InsertLibInfo () const
bool BaseWindow::Is (
ScriptDocument const& rDocument,
- OUString const& rLibName, OUString const& rName,
+ std::u16string_view rLibName, std::u16string_view rName,
ItemType eType, bool bFindSuspended
)
{
if (bFindSuspended || !IsSuspended())
{
// any non-suspended window is ok
- if (rLibName.isEmpty() || rName.isEmpty() || eType == TYPE_UNKNOWN)
+ if (rLibName.empty() || rName.empty() || eType == TYPE_UNKNOWN)
return true;
// ok if the parameters match
if (m_aDocument == rDocument && m_aLibName == rLibName && m_aName == rName && GetType() == eType)
diff --git a/basctl/source/basicide/scriptdocument.cxx b/basctl/source/basicide/scriptdocument.cxx
index d557bd5f31f4..61c2747d5eb3 100644
--- a/basctl/source/basicide/scriptdocument.cxx
+++ b/basctl/source/basicide/scriptdocument.cxx
@@ -1068,10 +1068,10 @@ namespace basctl
}
- ScriptDocument ScriptDocument::getDocumentWithURLOrCaption( const OUString& _rUrlOrCaption )
+ ScriptDocument ScriptDocument::getDocumentWithURLOrCaption( std::u16string_view _rUrlOrCaption )
{
ScriptDocument aDocument( getApplicationScriptDocument() );
- if ( _rUrlOrCaption.isEmpty() )
+ if ( _rUrlOrCaption.empty() )
return aDocument;
docs::Documents aDocuments;
diff --git a/basctl/source/inc/basidesh.hxx b/basctl/source/inc/basidesh.hxx
index 6f04b4269a2b..d8fe56feb43c 100644
--- a/basctl/source/inc/basidesh.hxx
+++ b/basctl/source/inc/basidesh.hxx
@@ -93,7 +93,7 @@ private:
void InitTabBar();
void InitScrollBars();
void CheckWindows();
- void RemoveWindows( const ScriptDocument& rDocument, const OUString& rLibName );
+ void RemoveWindows( const ScriptDocument& rDocument, std::u16string_view rLibName );
void UpdateWindows();
static void InvalidateBasicIDESlots();
void StoreAllWindowData( bool bPersistent = true );
@@ -183,7 +183,7 @@ public:
bool CallBasicErrorHdl( StarBASIC const * pBasic );
BasicDebugFlags CallBasicBreakHdl( StarBASIC const * pBasic );
- VclPtr<BaseWindow> FindWindow( const ScriptDocument& rDocument, const OUString& rLibName, const OUString& rName, ItemType nType, bool bFindSuspended = false );
+ VclPtr<BaseWindow> FindWindow( const ScriptDocument& rDocument, std::u16string_view rLibName, std::u16string_view rName, ItemType nType, bool bFindSuspended = false );
VclPtr<DialogWindow> FindDlgWin( const ScriptDocument& rDocument, const OUString& rLibName, const OUString& rName, bool bCreateIfNotExist = false, bool bFindSuspended = false );
VclPtr<ModulWindow> FindBasWin( const ScriptDocument& rDocument, const OUString& rLibName, const OUString& rModName, bool bCreateIfNotExist = false, bool bFindSuspended = false );
VclPtr<BaseWindow> FindApplicationWindow();
diff --git a/basctl/source/inc/bastype2.hxx b/basctl/source/inc/bastype2.hxx
index 5325bb75c1c5..3eb4de6beec9 100644
--- a/basctl/source/inc/bastype2.hxx
+++ b/basctl/source/inc/bastype2.hxx
@@ -189,7 +189,7 @@ protected:
void ImpCreateLibSubEntries(const weld::TreeIter& rLibRootEntry, const ScriptDocument& rDocument, const OUString& rLibName);
void ImpCreateLibSubEntriesInVBAMode(const weld::TreeIter& rLibRootEntry, const ScriptDocument& rDocument, const OUString& rLibName );
void ImpCreateLibSubSubEntriesInVBAMode(const weld::TreeIter& rLibRootEntry, const ScriptDocument& rDocument, const OUString& rLibName);
- bool ImpFindEntry(weld::TreeIter& rIter, const OUString& rText);
+ bool ImpFindEntry(weld::TreeIter& rIter, std::u16string_view rText);
// DocumentEventListener
virtual void onDocumentCreated( const ScriptDocument& _rDocument ) override;
@@ -218,7 +218,7 @@ public:
SbModule* FindModule(const weld::TreeIter* pEntry);
SbxVariable* FindVariable(const weld::TreeIter* pEntry);
bool FindRootEntry(const ScriptDocument& rDocument, LibraryLocation eLocation, weld::TreeIter& rIter);
- bool FindEntry(const OUString& rText, EntryType eType, weld::TreeIter& rIter);
+ bool FindEntry(std::u16string_view rText, EntryType eType, weld::TreeIter& rIter);
EntryDescriptor GetEntryDescriptor(const weld::TreeIter* pEntry);
static ItemType ConvertType (EntryType eType);
diff --git a/basctl/source/inc/bastypes.hxx b/basctl/source/inc/bastypes.hxx
index 052bd2f420c7..21e6c0227a9c 100644
--- a/basctl/source/inc/bastypes.hxx
+++ b/basctl/source/inc/bastypes.hxx
@@ -236,7 +236,7 @@ public:
virtual char const* GetHid () const = 0;
virtual ItemType GetType () const = 0;
void InsertLibInfo () const;
- bool Is (ScriptDocument const&, OUString const&, OUString const&, ItemType, bool bFindSuspended);
+ bool Is (ScriptDocument const&, std::u16string_view, std::u16string_view, ItemType, bool bFindSuspended);
virtual bool HasActiveEditor () const;
};
diff --git a/basctl/source/inc/scriptdocument.hxx b/basctl/source/inc/scriptdocument.hxx
index 6a0bfb2f0f62..da7f2b50d307 100644
--- a/basctl/source/inc/scriptdocument.hxx
+++ b/basctl/source/inc/scriptdocument.hxx
@@ -121,7 +121,7 @@ namespace basctl
@see getApplicationScriptDocument
*/
static ScriptDocument
- getDocumentWithURLOrCaption( const OUString& _rUrlOrCaption );
+ getDocumentWithURLOrCaption( std::u16string_view _rUrlOrCaption );
/** operation mode for getAllScriptDocuments
*/
diff --git a/binaryurp/source/bridge.cxx b/binaryurp/source/bridge.cxx
index 9a73a04b9039..fccef42d98f4 100644
--- a/binaryurp/source/bridge.cxx
+++ b/binaryurp/source/bridge.cxx
@@ -818,7 +818,7 @@ OutgoingRequest Bridge::lastOutgoingRequest(rtl::ByteSequence const & tid) {
}
bool Bridge::isProtocolPropertiesRequest(
- OUString const & oid, css::uno::TypeDescription const & type) const
+ std::u16string_view oid, css::uno::TypeDescription const & type) const
{
return oid == protPropOid_ && type.equals(protPropType_);
}
diff --git a/binaryurp/source/bridge.hxx b/binaryurp/source/bridge.hxx
index f3a6badd2283..1a51ffac0626 100644
--- a/binaryurp/source/bridge.hxx
+++ b/binaryurp/source/bridge.hxx
@@ -158,7 +158,7 @@ public:
OutgoingRequest lastOutgoingRequest(rtl::ByteSequence const & tid);
bool isProtocolPropertiesRequest(
- OUString const & oid,
+ std::u16string_view oid,
com::sun::star::uno::TypeDescription const & type) const;
void setCurrentContextMode();
diff --git a/chart2/qa/extras/PivotChartTest.cxx b/chart2/qa/extras/PivotChartTest.cxx
index 80bfcf14202b..44998835dbcc 100644
--- a/chart2/qa/extras/PivotChartTest.cxx
+++ b/chart2/qa/extras/PivotChartTest.cxx
@@ -60,7 +60,7 @@ namespace
{
void lclModifyOrientation(uno::Reference<sheet::XDataPilotDescriptor> const & xDescriptor,
- OUString const & sFieldName,
+ std::u16string_view sFieldName,
sheet::DataPilotFieldOrientation eOrientation)
{
uno::Reference<container::XIndexAccess> xIndexAccess(xDescriptor->getDataPilotFields(), UNO_SET_THROW);
@@ -76,7 +76,7 @@ void lclModifyOrientation(uno::Reference<sheet::XDataPilotDescriptor> const & xD
}
void lclModifyFunction(uno::Reference<sheet::XDataPilotDescriptor> const & xDescriptor,
- OUString const & sFieldName,
+ std::u16string_view sFieldName,
sheet::GeneralFunction eFunction)
{
uno::Reference<container::XIndexAccess> xPilotIndexAccess(xDescriptor->getDataPilotFields(), UNO_SET_THROW);
@@ -92,7 +92,7 @@ void lclModifyFunction(uno::Reference<sheet::XDataPilotDescriptor> const & xDesc
}
void lclModifyLayoutInfo(uno::Reference<sheet::XDataPilotDescriptor> const & xDescriptor,
- OUString const & sFieldName,
+ std::u16string_view sFieldName,
sheet::DataPilotFieldLayoutInfo aLayoutInfo)
{
uno::Reference<container::XIndexAccess> xIndexAccess(xDescriptor->getDataPilotFields(), UNO_SET_THROW);
@@ -112,7 +112,7 @@ void lclModifyLayoutInfo(uno::Reference<sheet::XDataPilotDescriptor> const & xDe
}
void lclModifySubtotals(uno::Reference<sheet::XDataPilotDescriptor> const & xDescriptor,
- OUString const & sFieldName,
+ std::u16string_view sFieldName,
uno::Sequence<sheet::GeneralFunction> const & rSubtotalFunctions)
{
uno::Reference<container::XIndexAccess> xIndexAccess(xDescriptor->getDataPilotFields(), UNO_SET_THROW);
@@ -325,12 +325,12 @@ void PivotChartTest::testRoundtrip()
// Check the data series
{
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference1, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Exp."), lclGetLabel(xChartDoc, 0));
}
{
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 1)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 1)->getData();
lclCheckSequence(aReference2, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Rev."), lclGetLabel(xChartDoc, 1));
}
@@ -339,14 +339,14 @@ void PivotChartTest::testRoundtrip()
{
uno::Reference<sheet::XDataPilotTable> xDataPilotTable = lclGetPivotTableByName(1, "DataPilot1", mxComponent);
uno::Reference<sheet::XDataPilotDescriptor> xDataPilotDescriptor(xDataPilotTable, UNO_QUERY_THROW);
- lclModifyOrientation(xDataPilotDescriptor, "Exp.", sheet::DataPilotFieldOrientation_HIDDEN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Exp.", sheet::DataPilotFieldOrientation_HIDDEN);
}
CPPUNIT_ASSERT_EQUAL(sal_Int32(1), getNumberOfDataSeries(xChartDoc));
// Check again the data series
{
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference2, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Total"), lclGetLabel(xChartDoc, 0));
}
@@ -360,7 +360,7 @@ void PivotChartTest::testRoundtrip()
// Check again the data series
{
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference2, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Total"), lclGetLabel(xChartDoc, 0));
}
@@ -398,7 +398,7 @@ void PivotChartTest::testChangePivotTable()
{
std::vector<double> aReference { 10162.033139, 16614.523063, 27944.146101 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Exp."), lclGetLabel(xChartDoc, 0));
@@ -408,7 +408,7 @@ void PivotChartTest::testChangePivotTable()
{
std::vector<double> aReference { 101879.458079, 178636.929704, 314626.484864 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 1)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 1)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Rev."), lclGetLabel(xChartDoc, 1));
@@ -419,9 +419,9 @@ void PivotChartTest::testChangePivotTable()
{
uno::Reference<sheet::XDataPilotDescriptor> xDataPilotDescriptor(xDataPilotTable, UNO_QUERY_THROW);
- lclModifyOrientation(xDataPilotDescriptor, "Service Month", sheet::DataPilotFieldOrientation_ROW);
- lclModifyOrientation(xDataPilotDescriptor, "Group Segment", sheet::DataPilotFieldOrientation_COLUMN);
- lclModifyOrientation(xDataPilotDescriptor, "Rev.", sheet::DataPilotFieldOrientation_HIDDEN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Service Month", sheet::DataPilotFieldOrientation_ROW);
+ lclModifyOrientation(xDataPilotDescriptor, u"Group Segment", sheet::DataPilotFieldOrientation_COLUMN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Rev.", sheet::DataPilotFieldOrientation_HIDDEN);
}
// Check the pivot chart again as we expect it has been updated when we updated the pivot table
@@ -432,7 +432,7 @@ void PivotChartTest::testChangePivotTable()
{
std::vector<double> aReference { 2855.559, 1780.326, 2208.713, 2130.064, 1187.371 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Big"), lclGetLabel(xChartDoc, 0));
@@ -442,7 +442,7 @@ void PivotChartTest::testChangePivotTable()
{
std::vector<double> aReference { 4098.908, 2527.286, 4299.716, 2362.225, 3326.389 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 1)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 1)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Medium"), lclGetLabel(xChartDoc, 1));
@@ -452,7 +452,7 @@ void PivotChartTest::testChangePivotTable()
{
std::vector<double> aReference { 4926.303, 5684.060, 4201.398, 7290.795, 5841.591 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 2)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 2)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Small"), lclGetLabel(xChartDoc, 2));
@@ -461,7 +461,7 @@ void PivotChartTest::testChangePivotTable()
// Remove "Service Month" so row fields are empty - check we handle empty rows
{
uno::Reference<sheet::XDataPilotDescriptor> xDataPilotDescriptor(xDataPilotTable, uno::UNO_QUERY_THROW);
- lclModifyOrientation(xDataPilotDescriptor, "Service Month", sheet::DataPilotFieldOrientation_HIDDEN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Service Month", sheet::DataPilotFieldOrientation_HIDDEN);
}
// Check the pivot chart again as we expect it has been updated when we updated the pivot table
@@ -471,21 +471,21 @@ void PivotChartTest::testChangePivotTable()
// Check the first data series
{
std::vector<double> aReference { 10162.033139 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Big"), lclGetLabel(xChartDoc, 0));
}
// Check the second data series
{
std::vector<double> aReference { 16614.523063 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 1)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 1)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Medium"), lclGetLabel(xChartDoc, 1));
}
// Check the third data series
{
std::vector<double> aReference { 27944.146101 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 2)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 2)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Small"), lclGetLabel(xChartDoc, 2));
}
@@ -501,21 +501,21 @@ void PivotChartTest::testChangePivotTable()
// Check the first data series
{
std::vector<double> aReference { 10162.033139 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Big"), lclGetLabel(xChartDoc, 0));
}
// Check the second data series
{
std::vector<double> aReference { 16614.523063 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 1)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 1)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Medium"), lclGetLabel(xChartDoc, 1));
}
// Check the third data series
{
std::vector<double> aReference { 27944.146101 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 2)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 2)->getData();
lclCheckSequence(aReference, xSequence, 1E-3);
CPPUNIT_ASSERT_EQUAL(OUString("Small"), lclGetLabel(xChartDoc, 2));
}
@@ -542,9 +542,9 @@ void PivotChartTest::testPivotChartWithOneColumnField()
uno::Reference<sheet::XDataPilotDescriptor> xDataPilotDescriptor = xDataPilotTables->createDataPilotDescriptor();
xDataPilotDescriptor->setSourceRange(sCellRangeAdress);
- lclModifyOrientation(xDataPilotDescriptor, "Country", sheet::DataPilotFieldOrientation_COLUMN);
- lclModifyOrientation(xDataPilotDescriptor, "Sales T1", sheet::DataPilotFieldOrientation_DATA);
- lclModifyFunction(xDataPilotDescriptor, "Sales T1", sheet::GeneralFunction_SUM);
+ lclModifyOrientation(xDataPilotDescriptor, u"Country", sheet::DataPilotFieldOrientation_COLUMN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Sales T1", sheet::DataPilotFieldOrientation_DATA);
+ lclModifyFunction(xDataPilotDescriptor, u"Sales T1", sheet::GeneralFunction_SUM);
xDataPilotTables->insertNewByName(sPivotTableName, table::CellAddress{1, 0, 0}, xDataPilotDescriptor);
@@ -577,7 +577,7 @@ void PivotChartTest::testPivotChartWithOneColumnField()
{
std::vector<double> aReference { 1738.0 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("DE"), lclGetLabel(xChartDoc, 0));
@@ -587,7 +587,7 @@ void PivotChartTest::testPivotChartWithOneColumnField()
{
std::vector<double> aReference { 2003.0 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 1)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 1)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("EN"), lclGetLabel(xChartDoc, 1));
@@ -596,7 +596,7 @@ void PivotChartTest::testPivotChartWithOneColumnField()
{
std::vector<double> aReference { 1936.0 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 2)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 2)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("FR"), lclGetLabel(xChartDoc, 2));
@@ -624,9 +624,9 @@ void PivotChartTest::testPivotChartWithOneRowField()
uno::Reference<sheet::XDataPilotDescriptor> xDataPilotDescriptor = xDataPilotTables->createDataPilotDescriptor();
xDataPilotDescriptor->setSourceRange(sCellRangeAdress);
- lclModifyOrientation(xDataPilotDescriptor, "Country", sheet::DataPilotFieldOrientation_ROW);
- lclModifyOrientation(xDataPilotDescriptor, "Sales T1", sheet::DataPilotFieldOrientation_DATA);
- lclModifyFunction(xDataPilotDescriptor, "Sales T1", sheet::GeneralFunction_SUM);
+ lclModifyOrientation(xDataPilotDescriptor, u"Country", sheet::DataPilotFieldOrientation_ROW);
+ lclModifyOrientation(xDataPilotDescriptor, u"Sales T1", sheet::DataPilotFieldOrientation_DATA);
+ lclModifyFunction(xDataPilotDescriptor, u"Sales T1", sheet::GeneralFunction_SUM);
xDataPilotTables->insertNewByName(sPivotTableName, table::CellAddress{1, 0, 0}, xDataPilotDescriptor);
@@ -659,7 +659,7 @@ void PivotChartTest::testPivotChartWithOneRowField()
{
std::vector<double> aReference { 1738.0, 2003.0, 1936.0 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Total"), lclGetLabel(xChartDoc, 0));
@@ -684,13 +684,13 @@ void PivotChartTest::testPivotTableDataProvider_PivotTableFields()
uno::Reference<sheet::XDataPilotDescriptor> xDataPilotDescriptor = xDataPilotTables->createDataPilotDescriptor();
xDataPilotDescriptor->setSourceRange(sCellRangeAdress);
- lclModifyOrientation(xDataPilotDescriptor, "City", sheet::DataPilotFieldOrientation_ROW);
- lclModifyOrientation(xDataPilotDescriptor, "Country", sheet::DataPilotFieldOrientation_COLUMN);
- lclModifyOrientation(xDataPilotDescriptor, "Type", sheet::DataPilotFieldOrientation_COLUMN);
- lclModifyOrientation(xDataPilotDescriptor, "Sales T1", sheet::DataPilotFieldOrientation_DATA);
- lclModifyFunction(xDataPilotDescriptor, "Sales T1", sheet::GeneralFunction_SUM);
- lclModifyOrientation(xDataPilotDescriptor, "Sales T2", sheet::DataPilotFieldOrientation_DATA);
- lclModifyFunction(xDataPilotDescriptor, "Sales T2", sheet::GeneralFunction_SUM);
+ lclModifyOrientation(xDataPilotDescriptor, u"City", sheet::DataPilotFieldOrientation_ROW);
+ lclModifyOrientation(xDataPilotDescriptor, u"Country", sheet::DataPilotFieldOrientation_COLUMN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Type", sheet::DataPilotFieldOrientation_COLUMN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Sales T1", sheet::DataPilotFieldOrientation_DATA);
+ lclModifyFunction(xDataPilotDescriptor, u"Sales T1", sheet::GeneralFunction_SUM);
+ lclModifyOrientation(xDataPilotDescriptor, u"Sales T2", sheet::DataPilotFieldOrientation_DATA);
+ lclModifyFunction(xDataPilotDescriptor, u"Sales T2", sheet::GeneralFunction_SUM);
lclModifyColumnGrandTotal(xDataPilotDescriptor, true);
lclModifyRowGrandTotal(xDataPilotDescriptor, true);
@@ -743,14 +743,14 @@ void PivotChartTest::testPivotTableDataProvider_PivotTableFields()
CPPUNIT_ASSERT_EQUAL(OUString("Sum - Sales T2"), aFieldEntries[1].Name);
// Data to column fields
- lclModifyOrientation(xDataPilotDescriptor, "Data", sheet::DataPilotFieldOrientation_COLUMN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Data", sheet::DataPilotFieldOrientation_COLUMN);
// Change the order of column fields: expected data, type, country
- lclModifyOrientation(xDataPilotDescriptor, "Country", sheet::DataPilotFieldOrientation_HIDDEN);
- lclModifyOrientation(xDataPilotDescriptor, "Type", sheet::DataPilotFieldOrientation_HIDDEN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Country", sheet::DataPilotFieldOrientation_HIDDEN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Type", sheet::DataPilotFieldOrientation_HIDDEN);
- lclModifyOrientation(xDataPilotDescriptor, "Type", sheet::DataPilotFieldOrientation_COLUMN);
- lclModifyOrientation(xDataPilotDescriptor, "Country", sheet::DataPilotFieldOrientation_COLUMN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Type", sheet::DataPilotFieldOrientation_COLUMN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Country", sheet::DataPilotFieldOrientation_COLUMN);
// set the XPivotTableDataProvider again as the old one was exchanged
xPivotTableDataProvider.set(xChartDoc->getDataProvider(), uno::UNO_QUERY_THROW);
@@ -792,10 +792,10 @@ void PivotChartTest::testPivotChartRowFieldInOutlineMode()
uno::Reference<sheet::XDataPilotDescriptor> xDataPilotDescriptor = xDataPilotTables->createDataPilotDescriptor();
xDataPilotDescriptor->setSourceRange(sCellRangeAdress);
- lclModifyOrientation(xDataPilotDescriptor, "Country", sheet::DataPilotFieldOrientation_ROW);
- lclModifyOrientation(xDataPilotDescriptor, "City", sheet::DataPilotFieldOrientation_ROW);
- lclModifyOrientation(xDataPilotDescriptor, "Sales T1", sheet::DataPilotFieldOrientation_DATA);
- lclModifyFunction(xDataPilotDescriptor, "Sales T1", sheet::GeneralFunction_SUM);
+ lclModifyOrientation(xDataPilotDescriptor, u"Country", sheet::DataPilotFieldOrientation_ROW);
+ lclModifyOrientation(xDataPilotDescriptor, u"City", sheet::DataPilotFieldOrientation_ROW);
+ lclModifyOrientation(xDataPilotDescriptor, u"Sales T1", sheet::DataPilotFieldOrientation_DATA);
+ lclModifyFunction(xDataPilotDescriptor, u"Sales T1", sheet::GeneralFunction_SUM);
xDataPilotTables->insertNewByName(sPivotTableName, table::CellAddress{1, 0, 0}, xDataPilotDescriptor);
// TEST
@@ -830,7 +830,7 @@ void PivotChartTest::testPivotChartRowFieldInOutlineMode()
{
std::vector<double> aReference { 1116.0, 622.0, 298.0, 562.0, 1143.0, 1168.0, 768.0 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Total"), lclGetLabel(xChartDoc, 0));
@@ -851,18 +851,18 @@ void PivotChartTest::testPivotChartRowFieldInOutlineMode()
// Enable subtotals - set to auto
aGeneralFunctionSequence[0] = sheet::GeneralFunction_AUTO;
- lclModifySubtotals(xDataPilotDescriptor, "Country", aGeneralFunctionSequence);
+ lclModifySubtotals(xDataPilotDescriptor, u"Country", aGeneralFunctionSequence);
// Set Subtotals layout to bottom + add empty lines
aLayoutInfoValue.AddEmptyLines = true;
aLayoutInfoValue.LayoutMode = sheet::DataPilotFieldLayoutMode::OUTLINE_SUBTOTALS_BOTTOM;
- lclModifyLayoutInfo(xDataPilotDescriptor, "Country", aLayoutInfoValue);
+ lclModifyLayoutInfo(xDataPilotDescriptor, u"Country", aLayoutInfoValue);
// Check data is unchanged
CPPUNIT_ASSERT_EQUAL(sal_Int32(1), getNumberOfDataSeries(xChartDoc));
{
std::vector<double> aReference { 1116.0, 622.0, 298.0, 562.0, 1143.0, 1168.0, 768.0 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Total"), lclGetLabel(xChartDoc, 0));
@@ -880,18 +880,18 @@ void PivotChartTest::testPivotChartRowFieldInOutlineMode()
// Enable subtotals - set to auto
aGeneralFunctionSequence[0] = sheet::GeneralFunction_AUTO;
- lclModifySubtotals(xDataPilotDescriptor, "Country", aGeneralFunctionSequence);
+ lclModifySubtotals(xDataPilotDescriptor, u"Country", aGeneralFunctionSequence);
// Set Subtotals layout to top + add empty lines
aLayoutInfoValue.AddEmptyLines = true;
aLayoutInfoValue.LayoutMode = sheet::DataPilotFieldLayoutMode::OUTLINE_SUBTOTALS_TOP;
- lclModifyLayoutInfo(xDataPilotDescriptor, "Country", aLayoutInfoValue);
+ lclModifyLayoutInfo(xDataPilotDescriptor, u"Country", aLayoutInfoValue);
// Check data is unchanged
CPPUNIT_ASSERT_EQUAL(sal_Int32(1), getNumberOfDataSeries(xChartDoc));
{
std::vector<double> aReference { 1116.0, 622.0, 298.0, 562.0, 1143.0, 1168.0, 768.0 };
- xSequence = getDataSequenceFromDocByRole(xChartDoc, "values-y", 0)->getData();
+ xSequence = getDataSequenceFromDocByRole(xChartDoc, u"values-y", 0)->getData();
lclCheckSequence(aReference, xSequence, 1E-4);
CPPUNIT_ASSERT_EQUAL(OUString("Total"), lclGetLabel(xChartDoc, 0));
@@ -923,12 +923,12 @@ void PivotChartTest::testPivotChartWithDateRowField()
uno::Reference<sheet::XDataPilotDescriptor> xDataPilotDescriptor = xDataPilotTables->createDataPilotDescriptor();
xDataPilotDescriptor->setSourceRange(sCellRangeAdress);
- lclModifyOrientation(xDataPilotDescriptor, "Date", sheet::DataPilotFieldOrientation_ROW);
- lclModifyOrientation(xDataPilotDescriptor, "City", sheet::DataPilotFieldOrientation_ROW);
- lclModifyOrientation(xDataPilotDescriptor, "Country", sheet::DataPilotFieldOrientation_ROW);
- lclModifyOrientation(xDataPilotDescriptor, "Type", sheet::DataPilotFieldOrientation_COLUMN);
- lclModifyOrientation(xDataPilotDescriptor, "Sales T1", sheet::DataPilotFieldOrientation_DATA);
- lclModifyFunction(xDataPilotDescriptor, "Sales T1", sheet::GeneralFunction_SUM);
+ lclModifyOrientation(xDataPilotDescriptor, u"Date", sheet::DataPilotFieldOrientation_ROW);
+ lclModifyOrientation(xDataPilotDescriptor, u"City", sheet::DataPilotFieldOrientation_ROW);
+ lclModifyOrientation(xDataPilotDescriptor, u"Country", sheet::DataPilotFieldOrientation_ROW);
+ lclModifyOrientation(xDataPilotDescriptor, u"Type", sheet::DataPilotFieldOrientation_COLUMN);
+ lclModifyOrientation(xDataPilotDescriptor, u"Sales T1", sheet::DataPilotFieldOrientation_DATA);
+ lclModifyFunction(xDataPilotDescriptor, u"Sales T1", sheet::GeneralFunction_SUM);
lclModifyColumnGrandTotal(xDataPilotDescriptor, true);
lclModifyRowGrandTotal(xDataPilotDescriptor, true);
diff --git a/chart2/qa/extras/chart2dump/chart2dump.cxx b/chart2/qa/extras/chart2dump/chart2dump.cxx
index 0c011aa93fd3..544eec6b5373 100644
--- a/chart2/qa/extras/chart2dump/chart2dump.cxx
+++ b/chart2/qa/extras/chart2dump/chart2dump.cxx
@@ -366,19 +366,19 @@ DECLARE_DUMP_TEST(ChartDataTest, Chart2DumpTest, false)
// Check source ranges
for (size_t nIndex = 0; nIndex < aDataSeriesYValues.size(); ++nIndex)
{
- Reference< chart2::data::XDataSequence > xDataSeq = getDataSequenceFromDocByRole(xChartDoc2, "values-x", nIndex);
+ Reference< chart2::data::XDataSequence > xDataSeq = getDataSequenceFromDocByRole(xChartDoc2, u"values-x", nIndex);
if (xDataSeq.is())
{
OUString aXValuesSourceRange = xDataSeq->getSourceRangeRepresentation();
CPPUNIT_DUMP_ASSERT_STRINGS_EQUAL(aXValuesSourceRange);
}
- xDataSeq.set(getDataSequenceFromDocByRole(xChartDoc2, "values-y", nIndex));
+ xDataSeq.set(getDataSequenceFromDocByRole(xChartDoc2, u"values-y", nIndex));
if (xDataSeq.is())
{
OUString aYValuesSourceRange = xDataSeq->getSourceRangeRepresentation();
CPPUNIT_DUMP_ASSERT_STRINGS_EQUAL(aYValuesSourceRange);
}
- xDataSeq.set(getDataSequenceFromDocByRole(xChartDoc2, "categories", nIndex));
+ xDataSeq.set(getDataSequenceFromDocByRole(xChartDoc2, u"categories", nIndex));
if (xDataSeq.is())
{
OUString aCategoriesSourceRange = xDataSeq->getSourceRangeRepresentation();
diff --git a/chart2/qa/extras/chart2import.cxx b/chart2/qa/extras/chart2import.cxx
index 6b55d112d5fb..8e8f0886d50f 100644
--- a/chart2/qa/extras/chart2import.cxx
+++ b/chart2/qa/extras/chart2import.cxx
@@ -918,7 +918,7 @@ void Chart2ImportTest::testDelayedCellImport()
load("/chart2/qa/extras/data/xlsx/", "fdo70609.xlsx");
uno::Reference< chart2::XChartDocument > xChartDoc = getChartDocFromSheet( 0, mxComponent );
Reference< chart2::data::XDataSequence > xDataSeq =
- getDataSequenceFromDocByRole(xChartDoc, "values-x");
+ getDataSequenceFromDocByRole(xChartDoc, u"values-x");
OUString aRange = xDataSeq->getSourceRangeRepresentation();
CPPUNIT_ASSERT_EQUAL(OUString("$Sheet2.$C$5:$C$9"), aRange);
@@ -2399,7 +2399,7 @@ void Chart2ImportTest::testXaxisValues()
uno::Reference< chart2::XChartDocument > xChartDoc(getChartDocFromWriter(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xChartDoc.is());
- const uno::Reference< chart2::data::XDataSequence > xDataSeq = getDataSequenceFromDocByRole(xChartDoc, "values-x");
+ const uno::Reference< chart2::data::XDataSequence > xDataSeq = getDataSequenceFromDocByRole(xChartDoc, u"values-x");
Sequence<uno::Any> xSequence = xDataSeq->getData();
// test X values
CPPUNIT_ASSERT_EQUAL(uno::Any(0.04), xSequence[0]);
diff --git a/chart2/qa/extras/charttest.hxx b/chart2/qa/extras/charttest.hxx
index bcd1f101189d..04794bbeb607 100644
--- a/chart2/qa/extras/charttest.hxx
+++ b/chart2/qa/extras/charttest.hxx
@@ -349,7 +349,7 @@ Reference< chart2::data::XDataSequence > getLabelDataSequenceFromDoc(
}
Reference< chart2::data::XDataSequence > getDataSequenceFromDocByRole(
- Reference< chart2::XChartDocument > const & xChartDoc, const OUString& rRole,
+ Reference< chart2::XChartDocument > const & xChartDoc, std::u16string_view rRole,
sal_Int32 nDataSeries = 0, sal_Int32 nChartType = 0 )
{
Reference< chart2::XDataSeries > xDataSeries =
diff --git a/chart2/source/model/template/DataInterpreter.cxx b/chart2/source/model/template/DataInterpreter.cxx
index 7e85e0b36199..ad473df9e8d7 100644
--- a/chart2/source/model/template/DataInterpreter.cxx
+++ b/chart2/source/model/template/DataInterpreter.cxx
@@ -335,7 +335,7 @@ void DataInterpreter::SetRole( const Reference< data::XDataSequence > & xSeq, co
uno::Any DataInterpreter::GetProperty(
const Sequence< beans::PropertyValue > & aArguments,
- const OUString & rName )
+ std::u16string_view rName )
{
for( sal_Int32 i=aArguments.getLength(); i--; )
{
@@ -352,7 +352,7 @@ bool DataInterpreter::HasCategories(
bool bHasCategories = false;
if( rArguments.hasElements() )
- GetProperty( rArguments, "HasCategories" ) >>= bHasCategories;
+ GetProperty( rArguments, u"HasCategories" ) >>= bHasCategories;
for( sal_Int32 nLSeqIdx=0; ! bHasCategories && nLSeqIdx<rData.getLength(); ++nLSeqIdx )
bHasCategories = ( rData[nLSeqIdx].is() && GetRole( rData[nLSeqIdx]->getValues() ) == "categories");
@@ -364,7 +364,7 @@ bool DataInterpreter::UseCategoriesAsX( const Sequence< beans::PropertyValue > &
{
bool bUseCategoriesAsX = true;
if( rArguments.hasElements() )
- GetProperty( rArguments, "UseCategoriesAsX" ) >>= bUseCategoriesAsX;
+ GetProperty( rArguments, u"UseCategoriesAsX" ) >>= bUseCategoriesAsX;
return bUseCategoriesAsX;
}
diff --git a/chart2/source/model/template/DataInterpreter.hxx b/chart2/source/model/template/DataInterpreter.hxx
index 2b8bd50fc3a2..8294f5ca4c9c 100644
--- a/chart2/source/model/template/DataInterpreter.hxx
+++ b/chart2/source/model/template/DataInterpreter.hxx
@@ -47,7 +47,7 @@ public:
static css::uno::Any GetProperty(
const css::uno::Sequence<css::beans::PropertyValue > & aArguments,
- const OUString & rName );
+ std::u16string_view rName );
static bool HasCategories(
const css::uno::Sequence< css::beans::PropertyValue > & rArguments,
diff --git a/chart2/source/view/axes/VCartesianAxis.cxx b/chart2/source/view/axes/VCartesianAxis.cxx
index 44e64973e0b8..cb57a6a62207 100644
--- a/chart2/source/view/axes/VCartesianAxis.cxx
+++ b/chart2/source/view/axes/VCartesianAxis.cxx
@@ -790,7 +790,7 @@ bool VCartesianAxis::createTextShapes(
tAnySequence aPropValues;
getAxisLabelProperties(aPropNames, aPropValues, m_aAxisProperties, rAxisLabelProperties, nLimitedSpaceForText, bLimitedHeight);
- uno::Any* pColorAny = PropertyMapper::getValuePointer(aPropValues,aPropNames,"CharColor");
+ uno::Any* pColorAny = PropertyMapper::getValuePointer(aPropValues,aPropNames,u"CharColor");
Color nColor = COL_AUTO;
if(pColorAny)
*pColorAny >>= nColor;
@@ -981,7 +981,7 @@ bool VCartesianAxis::createTextShapesSimple(
tAnySequence aPropValues;
getAxisLabelProperties(aPropNames, aPropValues, m_aAxisProperties, rAxisLabelProperties, -1, bLimitedHeight);
- uno::Any* pColorAny = PropertyMapper::getValuePointer(aPropValues,aPropNames,"CharColor");
+ uno::Any* pColorAny = PropertyMapper::getValuePointer(aPropValues,aPropNames,u"CharColor");
Color nColor = COL_AUTO;
if(pColorAny)
*pColorAny >>= nColor;
diff --git a/chart2/source/view/axes/VPolarAngleAxis.cxx b/chart2/source/view/axes/VPolarAngleAxis.cxx
index 70d9ac85fbb4..ae06bcf4d6da 100644
--- a/chart2/source/view/axes/VPolarAngleAxis.cxx
+++ b/chart2/source/view/axes/VPolarAngleAxis.cxx
@@ -67,7 +67,7 @@ void VPolarAngleAxis::createTextShapes_ForAngleAxis(
LabelPositionHelper::doDynamicFontResize( aPropValues, aPropNames, xProps
, rAxisLabelProperties.m_aFontReferenceSize );
- uno::Any* pColorAny = PropertyMapper::getValuePointer(aPropValues,aPropNames,"CharColor");
+ uno::Any* pColorAny = PropertyMapper::getValuePointer(aPropValues,aPropNames,u"CharColor");
Color nColor = COL_AUTO;
if(pColorAny)
*pColorAny >>= nColor;
diff --git a/chart2/source/view/inc/PropertyMapper.hxx b/chart2/source/view/inc/PropertyMapper.hxx
index 7a44584349b8..2039ebdde185 100644
--- a/chart2/source/view/inc/PropertyMapper.hxx
+++ b/chart2/source/view/inc/PropertyMapper.hxx
@@ -82,7 +82,7 @@ public:
static css::uno::Any*
getValuePointer( tAnySequence& rPropValues
, const tNameSequence& rPropNames
- , const OUString& rPropName );
+ , std::u16string_view rPropName );
static css::uno::Any*
getValuePointerForLimitedSpace( tAnySequence& rPropValues
diff --git a/chart2/source/view/main/LabelPositionHelper.cxx b/chart2/source/view/main/LabelPositionHelper.cxx
index 35d19ebc5ab5..74fd1ed78174 100644
--- a/chart2/source/view/main/LabelPositionHelper.cxx
+++ b/chart2/source/view/main/LabelPositionHelper.cxx
@@ -61,7 +61,7 @@ void LabelPositionHelper::changeTextAdjustment( tAnySequence& rPropValues, const
eHorizontalAdjust = drawing::TextHorizontalAdjust_LEFT;
else if( eAlignment==LABEL_ALIGN_LEFT || eAlignment==LABEL_ALIGN_LEFT_TOP || eAlignment==LABEL_ALIGN_LEFT_BOTTOM )
eHorizontalAdjust = drawing::TextHorizontalAdjust_RIGHT;
- uno::Any* pHorizontalAdjustAny = PropertyMapper::getValuePointer(rPropValues,rPropNames,"TextHorizontalAdjust");
+ uno::Any* pHorizontalAdjustAny = PropertyMapper::getValuePointer(rPropValues,rPropNames,u"TextHorizontalAdjust");
if(pHorizontalAdjustAny)
*pHorizontalAdjustAny <<= eHorizontalAdjust;
}
@@ -73,7 +73,7 @@ void LabelPositionHelper::changeTextAdjustment( tAnySequence& rPropValues, const
eVerticalAdjust = drawing::TextVerticalAdjust_BOTTOM;
else if( eAlignment==LABEL_ALIGN_BOTTOM || eAlignment==LABEL_ALIGN_RIGHT_BOTTOM || eAlignment==LABEL_ALIGN_LEFT_BOTTOM )
eVerticalAdjust = drawing::TextVerticalAdjust_TOP;
- uno::Any* pVerticalAdjustAny = PropertyMapper::getValuePointer(rPropValues,rPropNames,"TextVerticalAdjust");
+ uno::Any* pVerticalAdjustAny = PropertyMapper::getValuePointer(rPropValues,rPropNames,u"TextVerticalAdjust");
if(pVerticalAdjustAny)
*pVerticalAdjustAny <<= eVerticalAdjust;
}
@@ -101,11 +101,11 @@ void LabelPositionHelper::doDynamicFontResize( tAnySequence& rPropValues
awt::Size aOldReferenceSize;
if( xAxisModelProps->getPropertyValue( "ReferencePageSize") >>= aOldReferenceSize )
{
- uno::Any* pAOldAndNewFontHeightAny = PropertyMapper::getValuePointer( rPropValues, rPropNames, "CharHeight" );
+ uno::Any* pAOldAndNewFontHeightAny = PropertyMapper::getValuePointer( rPropValues, rPropNames, u"CharHeight" );
lcl_doDynamicFontResize( pAOldAndNewFontHeightAny, aOldReferenceSize, rNewReferenceSize );
- pAOldAndNewFontHeightAny = PropertyMapper::getValuePointer( rPropValues, rPropNames, "CharHeightAsian" );
+ pAOldAndNewFontHeightAny = PropertyMapper::getValuePointer( rPropValues, rPropNames, u"CharHeightAsian" );
lcl_doDynamicFontResize( pAOldAndNewFontHeightAny, aOldReferenceSize, rNewReferenceSize );
- pAOldAndNewFontHeightAny = PropertyMapper::getValuePointer( rPropValues, rPropNames, "CharHeightComplex" );
+ pAOldAndNewFontHeightAny = PropertyMapper::getValuePointer( rPropValues, rPropNames, u"CharHeightComplex" );
lcl_doDynamicFontResize( pAOldAndNewFontHeightAny, aOldReferenceSize, rNewReferenceSize );
}
}
diff --git a/chart2/source/view/main/PropertyMapper.cxx b/chart2/source/view/main/PropertyMapper.cxx
index 8611cef5d43a..c7327974249a 100644
--- a/chart2/source/view/main/PropertyMapper.cxx
+++ b/chart2/source/view/main/PropertyMapper.cxx
@@ -159,7 +159,7 @@ void PropertyMapper::getMultiPropertyListsFromValueMap(
uno::Any* PropertyMapper::getValuePointer( tAnySequence& rPropValues
, const tNameSequence& rPropNames
- , const OUString& rPropName )
+ , std::u16string_view rPropName )
{
sal_Int32 nCount = rPropNames.getLength();
for( sal_Int32 nN = 0; nN < nCount; nN++ )
diff --git a/chart2/source/view/main/VLegend.cxx b/chart2/source/view/main/VLegend.cxx
index 2a2048c35016..353fd4d9630c 100644
--- a/chart2/source/view/main/VLegend.cxx
+++ b/chart2/source/view/main/VLegend.cxx
@@ -291,7 +291,7 @@ awt::Size lcl_placeLegendEntries(
const sal_Int32 nSymbolToTextDistance = static_cast< sal_Int32 >( std::max( 100.0, fViewFontSize * 0.22 ) );//minimum 1mm
const sal_Int32 nSymbolPlusDistanceWidth = rMaxSymbolExtent.Width + nSymbolToTextDistance;
sal_Int32 nMaxTextWidth = rRemainingSpace.Width - nSymbolPlusDistanceWidth;
- uno::Any* pFrameWidthAny = PropertyMapper::getValuePointer( rTextProperties.second, rTextProperties.first, "TextMaximumFrameWidth");
+ uno::Any* pFrameWidthAny = PropertyMapper::getValuePointer( rTextProperties.second, rTextProperties.first, u"TextMaximumFrameWidth");
if(pFrameWidthAny)
{
if( eExpansion == css::chart::ChartLegendExpansion_HIGH )
diff --git a/chart2/source/view/main/VLegendSymbolFactory.cxx b/chart2/source/view/main/VLegendSymbolFactory.cxx
index 1ccc0de34324..8af21c374dba 100644
--- a/chart2/source/view/main/VLegendSymbolFactory.cxx
+++ b/chart2/source/view/main/VLegendSymbolFactory.cxx
@@ -60,7 +60,7 @@ void getPropNamesAndValues( const Reference< beans::XPropertySet >& xProp,
::chart::PropertyMapper::getMultiPropertyListsFromValueMap( rNames, rValues, aValueMap );
- uno::Any* pLineWidthAny = ::chart::PropertyMapper::getValuePointer(rValues,rNames,"LineWidth");
+ uno::Any* pLineWidthAny = ::chart::PropertyMapper::getValuePointer(rValues,rNames,u"LineWidth");
sal_Int32 nLineWidth = 0;
if( pLineWidthAny && (*pLineWidthAny>>=nLineWidth) )
{
diff --git a/comphelper/source/misc/mimeconfighelper.cxx b/comphelper/source/misc/mimeconfighelper.cxx
index b41b1d3850c7..73adf6918baf 100644
--- a/comphelper/source/misc/mimeconfighelper.cxx
+++ b/comphelper/source/misc/mimeconfighelper.cxx
@@ -443,9 +443,9 @@ uno::Sequence< beans::NamedValue > MimeConfigurationHelper::GetObjectPropsByFilt
}
-uno::Sequence< beans::NamedValue > MimeConfigurationHelper::GetObjectPropsByDocumentName( const OUString& aDocName )
+uno::Sequence< beans::NamedValue > MimeConfigurationHelper::GetObjectPropsByDocumentName( std::u16string_view aDocName )
{
- if ( !aDocName.isEmpty() )
+ if ( !aDocName.empty() )
{
uno::Reference< container::XNameAccess > xObjConfig = GetObjConfiguration();
if ( xObjConfig.is() )
@@ -507,11 +507,11 @@ OUString MimeConfigurationHelper::GetFactoryNameByStringClassID( const OUString&
}
-OUString MimeConfigurationHelper::GetFactoryNameByDocumentName( const OUString& aDocName )
+OUString MimeConfigurationHelper::GetFactoryNameByDocumentName( std::u16string_view aDocName )
{
OUString aResult;
- if ( !aDocName.isEmpty() )
+ if ( !aDocName.empty() )
{
uno::Reference< container::XNameAccess > xObjConfig = GetObjConfiguration();
if ( xObjConfig.is() )
diff --git a/compilerplugins/clang/stringviewparam.cxx b/compilerplugins/clang/stringviewparam.cxx
index 0f5ebfc70a3b..c359c1a9dc82 100644
--- a/compilerplugins/clang/stringviewparam.cxx
+++ b/compilerplugins/clang/stringviewparam.cxx
@@ -106,9 +106,14 @@ DeclRefExpr const* relevantDeclRefExpr(Expr const* expr)
return e;
}
+bool isStringView(QualType qt)
+{
+ return bool(loplugin::TypeCheck(qt).ClassOrStruct("basic_string_view").StdNamespace());
+}
+
DeclRefExpr const* relevantImplicitCastExpr(ImplicitCastExpr const* expr)
{
- if (!loplugin::TypeCheck(expr->getType()).ClassOrStruct("basic_string_view").StdNamespace())
+ if (!isStringView(expr->getType()))
{
return nullptr;
}
@@ -158,17 +163,38 @@ DeclRefExpr const* relevantCXXMemberCallExpr(CXXMemberCallExpr const* expr)
DeclRefExpr const* relevantCXXOperatorCallExpr(CXXOperatorCallExpr const* expr)
{
- // TODO OO_EqualEqual and similar
- if (expr->getOperator() != OO_Subscript)
+ if (expr->getOperator() == OO_Subscript)
{
- return nullptr;
+ auto const e = expr->getArg(0);
+ if (relevantStringType(e->getType()) == StringType::None)
+ {
+ return nullptr;
+ }
+ return relevantDeclRefExpr(e);
}
- auto const e = expr->getArg(0);
- if (relevantStringType(e->getType()) == StringType::None)
+ else if (compat::isComparisonOp(expr))
{
- return nullptr;
+ // TODO Can't currently convert rtl::OString because we end up with ambiguous operator==
+ // (one in string_view header and one in rtl/string.hxx header)
+ auto st1 = relevantStringType(compat::IgnoreImplicit(expr->getArg(0))->getType());
+ auto st2 = relevantStringType(compat::IgnoreImplicit(expr->getArg(1))->getType());
+ if (st1 == StringType::RtlOustring && st2 == StringType::RtlOustring)
+ {
+ auto e1 = relevantDeclRefExpr(expr->getArg(0));
+ if (e1)
+ return e1;
+ return relevantDeclRefExpr(expr->getArg(1));
+ }
+ if (st1 == StringType::RtlOustring && isStringView(expr->getArg(1)->getType()))
+ {
+ return relevantDeclRefExpr(expr->getArg(0));
+ }
+ if (st2 == StringType::RtlOustring && isStringView(expr->getArg(0)->getType()))
+ {
+ return relevantDeclRefExpr(expr->getArg(1));
+ }
}
- return relevantDeclRefExpr(e);
+ return nullptr;
}
class StringViewParam final
diff --git a/compilerplugins/clang/test/stringviewparam.cxx b/compilerplugins/clang/test/stringviewparam.cxx
index afa0454b0b43..decd17408506 100644
--- a/compilerplugins/clang/test/stringviewparam.cxx
+++ b/compilerplugins/clang/test/stringviewparam.cxx
@@ -50,4 +50,9 @@ template <> void f5<OUString>(OUString const&) {}
void f6([[maybe_unused]] OUString const&) {}
+// expected-error@+1 {{replace function parameter of type 'const rtl::OUString &' with 'std::u16string_view' [loplugin:stringviewparam]}}
+bool f7(const OUString& p1, OUString p2) { return p1 == p2; }
+// expected-error@+1 {{replace function parameter of type 'const rtl::OUString &' with 'std::u16string_view' [loplugin:stringviewparam]}}
+bool f8(const OUString& p1, std::u16string_view p2) { return p1 == p2; }
+
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/connectivity/source/cpool/ZPoolCollection.cxx b/connectivity/source/cpool/ZPoolCollection.cxx
index 53c1cea0d3c3..34d24b0be4f9 100644
--- a/connectivity/source/cpool/ZPoolCollection.cxx
+++ b/connectivity/source/cpool/ZPoolCollection.cxx
@@ -188,7 +188,7 @@ Reference< XDriver > SAL_CALL OPoolCollection::getDriverByURL( const OUString& _
return xDriver;
}
-bool OPoolCollection::isDriverPoolingEnabled(const OUString& _sDriverImplName,
+bool OPoolCollection::isDriverPoolingEnabled(std::u16string_view _sDriverImplName,
Reference< XInterface >& _rxDriverNode)
{
bool bEnabled = false;
diff --git a/connectivity/source/cpool/ZPoolCollection.hxx b/connectivity/source/cpool/ZPoolCollection.hxx
index f9078c1baa72..dc54e2f6b171 100644
--- a/connectivity/source/cpool/ZPoolCollection.hxx
+++ b/connectivity/source/cpool/ZPoolCollection.hxx
@@ -88,7 +88,7 @@ namespace connectivity
static css::uno::Reference< css::uno::XInterface > openNode( const OUString& _rPath,
const css::uno::Reference< css::uno::XInterface >& _xTreeNode) throw();
bool isPoolingEnabled();
- bool isDriverPoolingEnabled(const OUString& _sDriverImplName,
+ bool isDriverPoolingEnabled(std::u16string_view _sDriverImplName,
css::uno::Reference< css::uno::XInterface >& _rxDriverNode);
bool isPoolingEnabledByUrl( const OUString& _sUrl,
css::uno::Reference< css::sdbc::XDriver >& _rxDriver,
diff --git a/connectivity/source/drivers/dbase/DTable.cxx b/connectivity/source/drivers/dbase/DTable.cxx
index f16d2f1ee3eb..4f3e07be5938 100644
--- a/connectivity/source/drivers/dbase/DTable.cxx
+++ b/connectivity/source/drivers/dbase/DTable.cxx
@@ -589,7 +589,7 @@ void ODbaseTable::ReadMemoHeader()
}
}
-OUString ODbaseTable::getEntry(file::OConnection const * _pConnection,const OUString& _sName )
+OUString ODbaseTable::getEntry(file::OConnection const * _pConnection, std::u16string_view _sName )
{
OUString sURL;
try
diff --git a/connectivity/source/drivers/mysqlc/mysqlc_services.cxx b/connectivity/source/drivers/mysqlc/mysqlc_services.cxx
index de611375c371..6e4e2fbb5e84 100644
--- a/connectivity/source/drivers/mysqlc/mysqlc_services.cxx
+++ b/connectivity/source/drivers/mysqlc/mysqlc_services.cxx
@@ -48,7 +48,7 @@ struct ProviderRequest
{
}
- bool CREATE_PROVIDER(const OUString& Implname, const Sequence<OUString>& Services,
+ bool CREATE_PROVIDER(std::u16string_view Implname, const Sequence<OUString>& Services,
::cppu::ComponentInstantiation Factory, createFactoryFunc creator)
{
if (!xRet.is() && (Implname == sImplementationName))
diff --git a/connectivity/source/inc/dbase/DTable.hxx b/connectivity/source/inc/dbase/DTable.hxx
index 49b7bcc5a264..872b4d3d8c1b 100644
--- a/connectivity/source/inc/dbase/DTable.hxx
+++ b/connectivity/source/inc/dbase/DTable.hxx
@@ -182,7 +182,7 @@ namespace connectivity::dbase
virtual void addColumn(const css::uno::Reference< css::beans::XPropertySet>& descriptor) override;
virtual void dropColumn(sal_Int32 _nPos) override;
- static OUString getEntry(file::OConnection const * _pConnection,const OUString& _sURL );
+ static OUString getEntry(file::OConnection const * _pConnection, std::u16string_view _sURL );
static bool Drop_Static(const OUString& _sUrl, bool _bHasMemoFields, sdbcx::OCollection* _pIndexes );
virtual void refreshHeader() override;
diff --git a/connectivity/source/parse/sqliterator.cxx b/connectivity/source/parse/sqliterator.cxx
index a91390eca2b8..d7d7512b7acd 100644
--- a/connectivity/source/parse/sqliterator.cxx
+++ b/connectivity/source/parse/sqliterator.cxx
@@ -1919,7 +1919,7 @@ const OSQLParseNode* OSQLParseTreeIterator::getSimpleHavingTree() const
}
-Reference< XPropertySet > OSQLParseTreeIterator::findSelectColumn( const OUString & rColumnName )
+Reference< XPropertySet > OSQLParseTreeIterator::findSelectColumn( std::u16string_view rColumnName )
{
for (auto const& lookupColumn : *m_aSelectColumns)
{
diff --git a/cppu/source/uno/lbenv.cxx b/cppu/source/uno/lbenv.cxx
index 32529b8e4564..3a86f9882b7f 100644
--- a/cppu/source/uno/lbenv.cxx
+++ b/cppu/source/uno/lbenv.cxx
@@ -121,7 +121,7 @@ struct EnvironmentsData
void registerEnvironment( uno_Environment ** ppEnv );
void getRegisteredEnvironments(
uno_Environment *** pppEnvs, sal_Int32 * pnLen,
- uno_memAlloc memAlloc, const OUString & rEnvDcp );
+ uno_memAlloc memAlloc, std::u16string_view rEnvDcp );
bool isDisposing;
};
@@ -968,7 +968,7 @@ void EnvironmentsData::registerEnvironment( uno_Environment ** ppEnv )
void EnvironmentsData::getRegisteredEnvironments(
uno_Environment *** pppEnvs, sal_Int32 * pnLen, uno_memAlloc memAlloc,
- const OUString & rEnvDcp )
+ std::u16string_view rEnvDcp )
{
assert(pppEnvs && pnLen && memAlloc && "### null ptr!");
@@ -980,8 +980,8 @@ void EnvironmentsData::getRegisteredEnvironments(
for ( const auto& rEntry : aName2EnvMap )
{
uno_Environment * pWeak = rEntry.second;
- if (rEnvDcp.isEmpty() ||
- rEnvDcp == pWeak->pTypeName )
+ if (rEnvDcp.empty() ||
+ rEnvDcp == OUString::unacquired(&pWeak->pTypeName) )
{
aFounds[nSize] = nullptr;
(*pWeak->harden)( &aFounds[nSize], pWeak );
diff --git a/cui/source/customize/SvxNotebookbarConfigPage.cxx b/cui/source/customize/SvxNotebookbarConfigPage.cxx
index c8b594b9039e..b3dd97f1d43d 100644
--- a/cui/source/customize/SvxNotebookbarConfigPage.cxx
+++ b/cui/source/customize/SvxNotebookbarConfigPage.cxx
@@ -49,8 +49,8 @@ namespace container = com::sun::star::container;
namespace beans = com::sun::star::beans;
namespace graphic = com::sun::star::graphic;
-static bool isCategoryAvailable(const OUString& sClassId, const OUString& sUIItemId,
- const OUString& sActiveCategory, bool& isCategory)
+static bool isCategoryAvailable(const OUString& sClassId, std::u16string_view sUIItemId,
+ std::u16string_view sActiveCategory, bool& isCategory)
{
if (sUIItemId == sActiveCategory)
return true;
@@ -474,7 +474,7 @@ SvxNotebookbarEntriesListBox::SvxNotebookbarEntriesListBox(std::unique_ptr<weld:
SvxNotebookbarEntriesListBox::~SvxNotebookbarEntriesListBox() {}
-static void EditRegistryFile(const OUString& sUIItemId, const OUString& sSetEntry,
+static void EditRegistryFile(std::u16string_view sUIItemId, const OUString& sSetEntry,
const OUString& sNotebookbarInterface)
{
int nFlag = 0;
diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx
index f1c5ccef7221..778e2940ba1d 100644
--- a/cui/source/customize/cfgutil.cxx
+++ b/cui/source/customize/cfgutil.cxx
@@ -757,7 +757,7 @@ OUString CuiConfigGroupListBox::GetImage(
}
Reference< XInterface >
-CuiConfigGroupListBox::getDocumentModel( Reference< XComponentContext > const & xCtx, OUString const & docName )
+CuiConfigGroupListBox::getDocumentModel( Reference< XComponentContext > const & xCtx, std::u16string_view docName )
{
Reference< XInterface > xModel;
Reference< frame::XDesktop2 > desktop = frame::Desktop::create( xCtx );
diff --git a/cui/source/dialogs/hlinettp.cxx b/cui/source/dialogs/hlinettp.cxx
index f2deeb9b3c78..140d2a59da3b 100644
--- a/cui/source/dialogs/hlinettp.cxx
+++ b/cui/source/dialogs/hlinettp.cxx
@@ -279,7 +279,7 @@ void SvxHyperlinkInternetTp::SetScheme(const OUString& rScheme)
|*
|************************************************************************/
-void SvxHyperlinkInternetTp::RemoveImproperProtocol(const OUString& aProperScheme)
+void SvxHyperlinkInternetTp::RemoveImproperProtocol(std::u16string_view aProperScheme)
{
OUString aStrURL ( m_xCbbTarget->get_active_text() );
if ( !aStrURL.isEmpty() )
diff --git a/cui/source/dialogs/hlmailtp.cxx b/cui/source/dialogs/hlmailtp.cxx
index 1cae4b29d2fa..521af033b422 100644
--- a/cui/source/dialogs/hlmailtp.cxx
+++ b/cui/source/dialogs/hlmailtp.cxx
@@ -167,7 +167,7 @@ void SvxHyperlinkMailTp::SetInitFocus()
/*************************************************************************
|************************************************************************/
-void SvxHyperlinkMailTp::SetScheme(const OUString& rScheme)
+void SvxHyperlinkMailTp::SetScheme(std::u16string_view rScheme)
{
//update target:
RemoveImproperProtocol(rScheme);
@@ -183,7 +183,7 @@ void SvxHyperlinkMailTp::SetScheme(const OUString& rScheme)
|* Remove protocol if it does not fit to the current button selection
|*
|************************************************************************/
-void SvxHyperlinkMailTp::RemoveImproperProtocol(const OUString& aProperScheme)
+void SvxHyperlinkMailTp::RemoveImproperProtocol(std::u16string_view aProperScheme)
{
OUString aStrURL(m_xCbbReceiver->get_active_text());
if ( !aStrURL.isEmpty() )
diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx
index ab28675b4932..8996c0e6790c 100644
--- a/cui/source/dialogs/hlmarkwn.cxx
+++ b/cui/source/dialogs/hlmarkwn.cxx
@@ -382,7 +382,7 @@ void SvxHlinkDlgMarkWnd::ClearTree()
}
// Find Entry for String
-std::unique_ptr<weld::TreeIter> SvxHlinkDlgMarkWnd::FindEntry (const OUString& aStrName)
+std::unique_ptr<weld::TreeIter> SvxHlinkDlgMarkWnd::FindEntry (std::u16string_view aStrName)
{
bool bFound=false;
std::unique_ptr<weld::TreeIter> xEntry = mxLbTree->make_iterator();
@@ -404,7 +404,7 @@ std::unique_ptr<weld::TreeIter> SvxHlinkDlgMarkWnd::FindEntry (const OUString& a
}
// Select Entry
-bool SvxHlinkDlgMarkWnd::SelectEntry(const OUString& aStrMark)
+bool SvxHlinkDlgMarkWnd::SelectEntry(std::u16string_view aStrMark)
{
std::unique_ptr<weld::TreeIter> xEntry = FindEntry(aStrMark);
if (!xEntry)
diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx
index 78bb8be5d8f8..cb7d8776dcbd 100644
--- a/cui/source/dialogs/scriptdlg.cxx
+++ b/cui/source/dialogs/scriptdlg.cxx
@@ -113,7 +113,7 @@ void SvxScriptOrgDialog::deleteAllTree()
while (bNextEntry);
}
-void SvxScriptOrgDialog::Init( const OUString& language )
+void SvxScriptOrgDialog::Init( std::u16string_view language )
{
m_xScriptsBox->freeze();
@@ -202,7 +202,7 @@ void SvxScriptOrgDialog::Init( const OUString& language )
}
Reference< XInterface >
-SvxScriptOrgDialog::getDocumentModel( Reference< XComponentContext > const & xCtx, OUString const & docName )
+SvxScriptOrgDialog::getDocumentModel( Reference< XComponentContext > const & xCtx, std::u16string_view docName )
{
Reference< XInterface > xModel;
Reference< frame::XDesktop2 > desktop = frame::Desktop::create(xCtx);
@@ -229,7 +229,7 @@ SvxScriptOrgDialog::getDocumentModel( Reference< XComponentContext > const & xCt
}
Reference< browse::XBrowseNode >
-SvxScriptOrgDialog::getLangNodeFromRootNode( Reference< browse::XBrowseNode > const & rootNode, OUString const & language )
+SvxScriptOrgDialog::getLangNodeFromRootNode( Reference< browse::XBrowseNode > const & rootNode, std::u16string_view language )
{
Reference< browse::XBrowseNode > langNode;
diff --git a/cui/source/inc/cfgutil.hxx b/cui/source/inc/cfgutil.hxx
index c4d50e2aeb12..8187d5e14314 100644
--- a/cui/source/inc/cfgutil.hxx
+++ b/cui/source/inc/cfgutil.hxx
@@ -196,7 +196,7 @@ class CuiConfigGroupListBox
static css::uno::Reference< css::uno::XInterface > getDocumentModel(
css::uno::Reference< css::uno::XComponentContext > const & xCtx,
- OUString const & docName);
+ std::u16string_view docName);
void InitModule();
void FillScriptList(const css::uno::Reference< css::script::browse::XBrowseNode >& xRootNode,
diff --git a/cui/source/inc/cuitabarea.hxx b/cui/source/inc/cuitabarea.hxx
index a1927624f20d..aa660c6d791d 100644
--- a/cui/source/inc/cuitabarea.hxx
+++ b/cui/source/inc/cuitabarea.hxx
@@ -392,7 +392,7 @@ private:
void ModifiedHdl_Impl(void const *);
void SetControlState_Impl( css::awt::GradientStyle eXGS );
- sal_Int32 SearchGradientList(const OUString& rGradientName);
+ sal_Int32 SearchGradientList(std::u16string_view rGradientName);
public:
SvxGradientTabPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rInAttrs);
@@ -460,7 +460,7 @@ private:
DECL_LINK( ClickRenameHdl_Impl, SvxPresetListBox*, void );
DECL_LINK( ClickDeleteHdl_Impl, SvxPresetListBox*, void );
- sal_Int32 SearchHatchList(const OUString& rHatchName);
+ sal_Int32 SearchHatchList(std::u16string_view rHatchName);
public:
SvxHatchTabPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rInAttrs);
@@ -538,7 +538,7 @@ private:
DECL_LINK( ClickImportHdl, weld::Button&, void );
void ClickBitmapHdl_Impl();
void CalculateBitmapPresetSize();
- sal_Int32 SearchBitmapList(const OUString& rBitmapName);
+ sal_Int32 SearchBitmapList(std::u16string_view rBitmapName);
sal_Int32 SearchBitmapList(const GraphicObject& rGraphicObject);
public:
@@ -593,7 +593,7 @@ private:
DECL_LINK( ClickRenameHdl_Impl, SvxPresetListBox*, void );
DECL_LINK( ClickDeleteHdl_Impl, SvxPresetListBox*, void );
- sal_Int32 SearchPatternList(const OUString& rPatternName);
+ sal_Int32 SearchPatternList(std::u16string_view rPatternName);
public:
SvxPatternTabPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rInAttrs);
@@ -706,7 +706,7 @@ private:
void UpdateModified();
- static sal_Int32 FindInCustomColors( OUString const & aColorName );
+ static sal_Int32 FindInCustomColors( std::u16string_view aColorName );
sal_Int32 FindInPalette( const Color& rColor );
public:
diff --git a/cui/source/inc/hlinettp.hxx b/cui/source/inc/hlinettp.hxx
index 528a54594fcb..c317fc122fd4 100644
--- a/cui/source/inc/hlinettp.hxx
+++ b/cui/source/inc/hlinettp.hxx
@@ -55,7 +55,7 @@ private:
void SetScheme(const OUString& rScheme);
- void RemoveImproperProtocol(const OUString& rProperScheme);
+ void RemoveImproperProtocol(std::u16string_view rProperScheme);
OUString GetSchemeFromButtons() const;
INetProtocol GetSmartProtocolFromButtons() const;
diff --git a/cui/source/inc/hlmailtp.hxx b/cui/source/inc/hlmailtp.hxx
index 12600f32e890..8b8bc39d88cb 100644
--- a/cui/source/inc/hlmailtp.hxx
+++ b/cui/source/inc/hlmailtp.hxx
@@ -38,8 +38,8 @@ private:
///< Button : Address book
DECL_LINK (ModifiedReceiverHdl_Impl, weld::ComboBox&, void ); ///< Combobox "receiver" modified
- void SetScheme(const OUString& rScheme);
- void RemoveImproperProtocol(const OUString& aProperScheme);
+ void SetScheme(std::u16string_view rScheme);
+ void RemoveImproperProtocol(std::u16string_view aProperScheme);
OUString CreateAbsoluteURL() const;
diff --git a/cui/source/inc/hlmarkwn.hxx b/cui/source/inc/hlmarkwn.hxx
index ee7924e3aa03..9552bc10097c 100644
--- a/cui/source/inc/hlmarkwn.hxx
+++ b/cui/source/inc/hlmarkwn.hxx
@@ -47,7 +47,7 @@ protected:
bool RefreshFromDoc( const OUString& aURL );
void RestoreLastSelection();
- std::unique_ptr<weld::TreeIter> FindEntry(const OUString& aStrName);
+ std::unique_ptr<weld::TreeIter> FindEntry(std::u16string_view aStrName);
void ClearTree();
int FillTree( const css::uno::Reference< css::container::XNameAccess >& xLinks, const weld::TreeIter* pParentEntry =nullptr );
@@ -61,7 +61,7 @@ public:
void MoveTo(const Point& rNewPos);
void RefreshTree(const OUString& aStrURL);
- bool SelectEntry(const OUString& aStrMark);
+ bool SelectEntry(std::u16string_view aStrMark);
sal_uInt16 SetError( sal_uInt16 nError);
};
diff --git a/cui/source/inc/optdict.hxx b/cui/source/inc/optdict.hxx
index 2465613322af..1449e9457ad9 100644
--- a/cui/source/inc/optdict.hxx
+++ b/cui/source/inc/optdict.hxx
@@ -102,7 +102,7 @@ private:
int GetLBInsertPos(const OUString &rDicWord);
public:
- SvxEditDictionaryDialog(weld::Window* pParent, const OUString& rName);
+ SvxEditDictionaryDialog(weld::Window* pParent, std::u16string_view rName);
virtual ~SvxEditDictionaryDialog() override;
};
diff --git a/cui/source/inc/scriptdlg.hxx b/cui/source/inc/scriptdlg.hxx
index 65e76e534ffd..6a1cbd15ae5c 100644
--- a/cui/source/inc/scriptdlg.hxx
+++ b/cui/source/inc/scriptdlg.hxx
@@ -115,7 +115,7 @@ protected:
void StoreCurrentSelection();
void RestorePreviousSelection();
- void Init(const OUString& language);
+ void Init(std::u16string_view language);
void delUserData(const weld::TreeIter& rIter);
void deleteTree(weld::TreeIter& rIter);
void deleteAllTree();
@@ -135,9 +135,9 @@ protected:
css::uno::Reference< css::frame::XModel>& model);
static css::uno::Reference< css::script::browse::XBrowseNode >
- getLangNodeFromRootNode( css::uno::Reference< css::script::browse::XBrowseNode > const & root, OUString const & language );
+ getLangNodeFromRootNode( css::uno::Reference< css::script::browse::XBrowseNode > const & root, std::u16string_view language );
- static css::uno::Reference< css::uno::XInterface > getDocumentModel( css::uno::Reference< css::uno::XComponentContext > const & xCtx, OUString const & docName );
+ static css::uno::Reference< css::uno::XInterface > getDocumentModel( css::uno::Reference< css::uno::XComponentContext > const & xCtx, std::u16string_view docName );
public:
// prob need another arg in the ctor
diff --git a/cui/source/inc/treeopt.hxx b/cui/source/inc/treeopt.hxx
index a07232848b6c..59f7ef2d3e03 100644
--- a/cui/source/inc/treeopt.hxx
+++ b/cui/source/inc/treeopt.hxx
@@ -150,11 +150,11 @@ private:
void Initialize( const css::uno::Reference< css::frame::XFrame >& _xFrame );
void InitWidgets();
- void LoadExtensionOptions( const OUString& rExtensionId );
+ void LoadExtensionOptions( std::u16string_view rExtensionId );
static OUString GetModuleIdentifier( const css::uno::Reference<
css::frame::XFrame >& xFrame );
- static std::unique_ptr<Module> LoadModule( const OUString& rModuleIdentifier );
- static VectorOfNodes LoadNodes( Module* pModule, const OUString& rExtensionId );
+ static std::unique_ptr<Module> LoadModule( std::u16string_view rModuleIdentifier );
+ static VectorOfNodes LoadNodes( Module* pModule, std::u16string_view rExtensionId );
void InsertNodes( const VectorOfNodes& rNodeList );
void ApplyOptions();
@@ -177,7 +177,7 @@ public:
OfaTreeOptionsDialog(weld::Window* pParent,
const css::uno::Reference< css::frame::XFrame >& _xFrame,
bool bActivateLastSelection);
- OfaTreeOptionsDialog(weld::Window* pParent, const OUString& rExtensionId);
+ OfaTreeOptionsDialog(weld::Window* pParent, std::u16string_view rExtensionId);
virtual ~OfaTreeOptionsDialog() override;
OptionsPageInfo* AddTabPage( sal_uInt16 nId, const OUString& rPageName, sal_uInt16 nGroup );
diff --git a/cui/source/options/fontsubs.cxx b/cui/source/options/fontsubs.cxx
index b067aaf05f80..997f57798860 100644
--- a/cui/source/options/fontsubs.cxx
+++ b/cui/source/options/fontsubs.cxx
@@ -267,7 +267,7 @@ IMPL_LINK(SvxFontSubstTabPage, SelectComboBoxHdl, weld::ComboBox&, rBox, void)
namespace
{
// search in the "font" column
- int findText(const weld::TreeView& rTreeView, const OUString& rCol)
+ int findText(const weld::TreeView& rTreeView, std::u16string_view rCol)
{
for (int i = 0, nEntryCount = rTreeView.n_children(); i < nEntryCount; ++i)
{
@@ -277,7 +277,7 @@ namespace
return -1;
}
- bool findRow(const weld::TreeView& rTreeView, const OUString& rCol1, const OUString& rCol2)
+ bool findRow(const weld::TreeView& rTreeView, std::u16string_view rCol1, std::u16string_view rCol2)
{
int nRow = findText(rTreeView, rCol1);
if (nRow == -1)
diff --git a/cui/source/options/optdict.cxx b/cui/source/options/optdict.cxx
index 5832e8321c53..55bfd4b72224 100644
--- a/cui/source/options/optdict.cxx
+++ b/cui/source/options/optdict.cxx
@@ -198,7 +198,7 @@ IMPL_LINK_NOARG(SvxNewDictionaryDialog, ModifyHdl_Impl, weld::Entry&, void)
// class SvxEditDictionaryDialog -------------------------------------------
-SvxEditDictionaryDialog::SvxEditDictionaryDialog(weld::Window* pParent, const OUString& rName)
+SvxEditDictionaryDialog::SvxEditDictionaryDialog(weld::Window* pParent, std::u16string_view rName)
: GenericDialogController(pParent, "cui/ui/editdictionarydialog.ui", "EditDictionaryDialog")
, sModify(CuiResId(STR_MODIFY))
, bFirstSelect(false)
diff --git a/cui/source/options/optjava.cxx b/cui/source/options/optjava.cxx
index ed695295b583..e6af34320fe7 100644
--- a/cui/source/options/optjava.cxx
+++ b/cui/source/options/optjava.cxx
@@ -893,7 +893,7 @@ IMPL_LINK_NOARG(SvxJavaClassPathDlg, SelectHdl_Impl, weld::TreeView&, void)
EnableRemoveButton();
}
-bool SvxJavaClassPathDlg::IsPathDuplicate( const OUString& _rPath )
+bool SvxJavaClassPathDlg::IsPathDuplicate( std::u16string_view _rPath )
{
bool bRet = false;
int nCount = m_xPathList->n_children();
diff --git a/cui/source/options/optjava.hxx b/cui/source/options/optjava.hxx
index d850986a45b0..a3af9aaf71b1 100644
--- a/cui/source/options/optjava.hxx
+++ b/cui/source/options/optjava.hxx
@@ -185,7 +185,7 @@ private:
DECL_LINK(RemoveHdl_Impl, weld::Button&, void);
DECL_LINK(SelectHdl_Impl, weld::TreeView&, void);
- bool IsPathDuplicate(const OUString& _rPath);
+ bool IsPathDuplicate(std::u16string_view _rPath);
void EnableRemoveButton()
{
m_xRemoveBtn->set_sensitive(m_xPathList->get_selected_index() != -1);
diff --git a/cui/source/options/optlingu.cxx b/cui/source/options/optlingu.cxx
index 09cdb0d9e1b5..1b646fc51043 100644
--- a/cui/source/options/optlingu.cxx
+++ b/cui/source/options/optlingu.cxx
@@ -75,7 +75,7 @@ const char cThes[] = SN_THESAURUS;
// static ----------------------------------------------------------------
static sal_Int32 lcl_SeqGetEntryPos(
- const Sequence< OUString > &rSeq, const OUString &rEntry )
+ const Sequence< OUString > &rSeq, std::u16string_view rEntry )
{
sal_Int32 i;
sal_Int32 nLen = rSeq.getLength();
@@ -357,7 +357,7 @@ public:
uno::Reference<XLinguServiceManager2> & GetManager() { return xLinguSrvcMgr; }
void SetChecked( const Sequence< OUString > &rConfiguredServices );
- void Reconfigure( const OUString &rDisplayName, bool bEnable );
+ void Reconfigure( std::u16string_view rDisplayName, bool bEnable );
const Sequence<Locale> & GetAllSupportedLocales() const { return aAllServiceLocales; }
@@ -380,11 +380,11 @@ public:
// language.
Sequence< OUString > GetSortedImplNames( LanguageType nLang, sal_uInt8 nType );
- ServiceInfo_Impl * GetInfoByImplName( const OUString &rSvcImplName );
+ ServiceInfo_Impl * GetInfoByImplName( std::u16string_view rSvcImplName );
};
-static sal_Int32 lcl_SeqGetIndex( const Sequence< OUString > &rSeq, const OUString &rTxt )
+static sal_Int32 lcl_SeqGetIndex( const Sequence< OUString > &rSeq, std::u16string_view rTxt )
{
sal_Int32 nRes = -1;
sal_Int32 nLen = rSeq.getLength();
@@ -449,7 +449,7 @@ Sequence< OUString > SvxLinguData_Impl::GetSortedImplNames( LanguageType nLang,
}
-ServiceInfo_Impl * SvxLinguData_Impl::GetInfoByImplName( const OUString &rSvcImplName )
+ServiceInfo_Impl * SvxLinguData_Impl::GetInfoByImplName( std::u16string_view rSvcImplName )
{
for (sal_uInt32 i = 0; i < nDisplayServices; ++i)
{
@@ -730,9 +730,9 @@ bool SvxLinguData_Impl::AddRemove(
}
-void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, bool bEnable )
+void SvxLinguData_Impl::Reconfigure( std::u16string_view rDisplayName, bool bEnable )
{
- DBG_ASSERT( !rDisplayName.isEmpty(), "empty DisplayName" );
+ DBG_ASSERT( !rDisplayName.empty(), "empty DisplayName" );
ServiceInfo_Impl *pInfo = nullptr;
for (sal_uInt32 i = 0; i < nDisplayServices; ++i)
diff --git a/cui/source/options/treeopt.cxx b/cui/source/options/treeopt.cxx
index 6e822e974c5e..6f63828c173f 100644
--- a/cui/source/options/treeopt.cxx
+++ b/cui/source/options/treeopt.cxx
@@ -159,7 +159,7 @@ static ModuleToGroupNameMap_Impl ModuleMap[] =
{ u"Base", OUString(), SID_SB_STARBASEOPTIONS },
};
-static void setGroupName( const OUString& rModule, const OUString& rGroupName )
+static void setGroupName( std::u16string_view rModule, const OUString& rGroupName )
{
for (ModuleToGroupNameMap_Impl& rEntry : ModuleMap)
{
@@ -209,7 +209,7 @@ static void deleteGroupNames()
rEntry.m_sGroupName.clear();
}
-static sal_uInt16 getGroupNodeId( const OUString& rModule )
+static sal_uInt16 getGroupNodeId( std::u16string_view rModule )
{
sal_uInt16 nNodeId = 0xFFFF;
for (const ModuleToGroupNameMap_Impl& rEntry : ModuleMap)
@@ -496,7 +496,7 @@ OfaTreeOptionsDialog::OfaTreeOptionsDialog(weld::Window* pParent, const Referenc
InitTreeAndHandler();
Initialize( _xFrame );
- LoadExtensionOptions( OUString() );
+ LoadExtensionOptions( u"" );
if (bActivateLastSelection)
ActivateLastSelection();
@@ -504,13 +504,13 @@ OfaTreeOptionsDialog::OfaTreeOptionsDialog(weld::Window* pParent, const Referenc
}
// Ctor() with ExtensionId -----------------------------------------------
-OfaTreeOptionsDialog::OfaTreeOptionsDialog(weld::Window* pParent, const OUString& rExtensionId)
+OfaTreeOptionsDialog::OfaTreeOptionsDialog(weld::Window* pParent, std::u16string_view rExtensionId)
: SfxOkDialogController(pParent, "cui/ui/optionsdialog.ui", "OptionsDialog")
INI_LIST()
{
InitWidgets();
- bIsFromExtensionManager = ( !rExtensionId.isEmpty() );
+ bIsFromExtensionManager = ( !rExtensionId.empty() );
InitTreeAndHandler();
LoadExtensionOptions( rExtensionId );
ActivateLastSelection();
@@ -1359,7 +1359,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
// %PRODUCTNAME options
if ( !lcl_isOptionHidden( SID_GENERAL_OPTIONS, aOptionsDlgOpt ) )
{
- setGroupName("ProductName", CuiResId(SID_GENERAL_OPTIONS_RES[0].first));
+ setGroupName(u"ProductName", CuiResId(SID_GENERAL_OPTIONS_RES[0].first));
nGroup = AddGroup(CuiResId(SID_GENERAL_OPTIONS_RES[0].first), nullptr, nullptr, SID_GENERAL_OPTIONS );
const sal_uInt16 nEnd = static_cast<sal_uInt16>(SAL_N_ELEMENTS(SID_GENERAL_OPTIONS_RES));
@@ -1399,7 +1399,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
// Load and Save options
if ( !lcl_isOptionHidden( SID_FILTER_DLG, aOptionsDlgOpt ) )
{
- setGroupName( "LoadSave", CuiResId(SID_FILTER_DLG_RES[0].first) );
+ setGroupName( u"LoadSave", CuiResId(SID_FILTER_DLG_RES[0].first) );
nGroup = AddGroup( CuiResId(SID_FILTER_DLG_RES[0].first), nullptr, nullptr, SID_FILTER_DLG );
for ( size_t i = 1; i < SAL_N_ELEMENTS(SID_FILTER_DLG_RES); ++i )
{
@@ -1413,7 +1413,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
SvtLanguageOptions aLanguageOptions;
if ( !lcl_isOptionHidden( SID_LANGUAGE_OPTIONS, aOptionsDlgOpt ) )
{
- setGroupName("LanguageSettings", CuiResId(SID_LANGUAGE_OPTIONS_RES[0].first));
+ setGroupName(u"LanguageSettings", CuiResId(SID_LANGUAGE_OPTIONS_RES[0].first));
nGroup = AddGroup(CuiResId(SID_LANGUAGE_OPTIONS_RES[0].first), nullptr, nullptr, SID_LANGUAGE_OPTIONS );
for (size_t i = 1; i < SAL_N_ELEMENTS(SID_LANGUAGE_OPTIONS_RES); ++i)
{
@@ -1443,9 +1443,9 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
if ( !lcl_isOptionHidden( SID_SW_EDITOPTIONS, aOptionsDlgOpt ) )
{
if ( aFactory == "com.sun.star.text.WebDocument" )
- setGroupName( "WriterWeb", CuiResId(SID_SW_EDITOPTIONS_RES[0].first) );
+ setGroupName( u"WriterWeb", CuiResId(SID_SW_EDITOPTIONS_RES[0].first) );
else
- setGroupName( "Writer", CuiResId(SID_SW_EDITOPTIONS_RES[0].first) );
+ setGroupName( u"Writer", CuiResId(SID_SW_EDITOPTIONS_RES[0].first) );
nGroup = AddGroup(CuiResId(SID_SW_EDITOPTIONS_RES[0].first), pSwMod, pSwMod, SID_SW_EDITOPTIONS );
for ( size_t i = 1; i < SAL_N_ELEMENTS(SID_SW_EDITOPTIONS_RES); ++i )
{
@@ -1487,7 +1487,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
if ( !lcl_isOptionHidden( SID_SC_EDITOPTIONS, aOptionsDlgOpt ) )
{
SfxModule* pScMod = SfxApplication::GetModule( SfxToolsModule::Calc );
- setGroupName( "Calc", CuiResId(SID_SC_EDITOPTIONS_RES[0].first) );
+ setGroupName( u"Calc", CuiResId(SID_SC_EDITOPTIONS_RES[0].first) );
nGroup = AddGroup( CuiResId(SID_SC_EDITOPTIONS_RES[0].first), pScMod, pScMod, SID_SC_EDITOPTIONS );
const sal_uInt16 nCount = static_cast<sal_uInt16>(SAL_N_ELEMENTS(SID_SC_EDITOPTIONS_RES));
for ( sal_uInt16 i = 1; i < nCount; ++i )
@@ -1510,7 +1510,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
{
if ( !lcl_isOptionHidden( SID_SD_EDITOPTIONS, aOptionsDlgOpt ) )
{
- setGroupName( "Impress", CuiResId(SID_SD_EDITOPTIONS_RES[0].first) );
+ setGroupName( u"Impress", CuiResId(SID_SD_EDITOPTIONS_RES[0].first) );
nGroup = AddGroup( CuiResId(SID_SD_EDITOPTIONS_RES[0].first), pSdMod, pSdMod, SID_SD_EDITOPTIONS );
const sal_uInt16 nCount = static_cast<sal_uInt16>(SAL_N_ELEMENTS(SID_SD_EDITOPTIONS_RES));
for ( sal_uInt16 i = 1; i < nCount; ++i )
@@ -1532,7 +1532,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
{
if ( !lcl_isOptionHidden( SID_SD_GRAPHIC_OPTIONS, aOptionsDlgOpt ) )
{
- setGroupName( "Draw", CuiResId(SID_SD_GRAPHIC_OPTIONS_RES[0].first) );
+ setGroupName( u"Draw", CuiResId(SID_SD_GRAPHIC_OPTIONS_RES[0].first) );
nGroup = AddGroup( CuiResId(SID_SD_GRAPHIC_OPTIONS_RES[0].first), pSdMod, pSdMod, SID_SD_GRAPHIC_OPTIONS );
const sal_uInt16 nCount = static_cast<sal_uInt16>(SAL_N_ELEMENTS(SID_SD_GRAPHIC_OPTIONS_RES));
for ( sal_uInt16 i = 1; i < nCount; ++i )
@@ -1555,7 +1555,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
if ( !lcl_isOptionHidden( SID_SM_EDITOPTIONS, aOptionsDlgOpt ) )
{
SfxModule* pSmMod = SfxApplication::GetModule(SfxToolsModule::Math);
- setGroupName( "Math", CuiResId(SID_SM_EDITOPTIONS_RES[0].first) );
+ setGroupName( u"Math", CuiResId(SID_SM_EDITOPTIONS_RES[0].first) );
nGroup = AddGroup(CuiResId(SID_SM_EDITOPTIONS_RES[0].first), pSmMod, pSmMod, SID_SM_EDITOPTIONS );
for ( size_t i = 1; i < SAL_N_ELEMENTS(SID_SM_EDITOPTIONS_RES); ++i )
{
@@ -1574,7 +1574,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
|| aModuleOpt.IsModuleInstalled( SvtModuleOptions::EModule::CALC )
) )
{
- setGroupName( "Base", CuiResId(SID_SB_STARBASEOPTIONS_RES[0].first) );
+ setGroupName( u"Base", CuiResId(SID_SB_STARBASEOPTIONS_RES[0].first) );
nGroup = AddGroup( CuiResId(SID_SB_STARBASEOPTIONS_RES[0].first), nullptr, nullptr, SID_SB_STARBASEOPTIONS );
for ( size_t i = 1; i < SAL_N_ELEMENTS(SID_SB_STARBASEOPTIONS_RES); ++i )
{
@@ -1587,7 +1587,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
// Chart options (always installed and active)
if ( !lcl_isOptionHidden( SID_SCH_EDITOPTIONS, aOptionsDlgOpt ) )
{
- setGroupName( "Charts", CuiResId(SID_SCH_EDITOPTIONS_RES[0].first) );
+ setGroupName( u"Charts", CuiResId(SID_SCH_EDITOPTIONS_RES[0].first) );
nGroup = AddGroup( CuiResId(SID_SCH_EDITOPTIONS_RES[0].first), nullptr, nullptr, SID_SCH_EDITOPTIONS );
for ( size_t i = 1; i < SAL_N_ELEMENTS(SID_SCH_EDITOPTIONS_RES); ++i )
{
@@ -1601,7 +1601,7 @@ void OfaTreeOptionsDialog::Initialize( const Reference< XFrame >& _xFrame )
if ( lcl_isOptionHidden( SID_INET_DLG, aOptionsDlgOpt ) )
return;
- setGroupName("Internet", CuiResId(SID_INET_DLG_RES[0].first));
+ setGroupName(u"Internet", CuiResId(SID_INET_DLG_RES[0].first));
nGroup = AddGroup(CuiResId(SID_INET_DLG_RES[0].first), nullptr, nullptr, SID_INET_DLG );
for ( size_t i = 1; i < SAL_N_ELEMENTS(SID_INET_DLG_RES); ++i )
@@ -1645,12 +1645,12 @@ static bool isNodeActive( OptionsNode const * pNode, Module* pModule )
return false;
}
-void OfaTreeOptionsDialog::LoadExtensionOptions( const OUString& rExtensionId )
+void OfaTreeOptionsDialog::LoadExtensionOptions( std::u16string_view rExtensionId )
{
std::unique_ptr<Module> pModule;
// when called by Tools - Options then load nodes of active module
- if ( rExtensionId.isEmpty() )
+ if ( rExtensionId.empty() )
{
pModule = LoadModule( GetModuleIdentifier( Reference< XFrame >() ) );
}
@@ -1691,7 +1691,7 @@ OUString OfaTreeOptionsDialog::GetModuleIdentifier( const Reference< XFrame >& r
}
std::unique_ptr<Module> OfaTreeOptionsDialog::LoadModule(
- const OUString& rModuleIdentifier )
+ std::u16string_view rModuleIdentifier )
{
std::unique_ptr<Module> pModule;
Reference< XNameAccess > xSet(
@@ -1754,7 +1754,7 @@ std::unique_ptr<Module> OfaTreeOptionsDialog::LoadModule(
}
VectorOfNodes OfaTreeOptionsDialog::LoadNodes(
- Module* pModule, const OUString& rExtensionId)
+ Module* pModule, std::u16string_view rExtensionId)
{
VectorOfNodes aOutNodeList;
@@ -1780,12 +1780,12 @@ VectorOfNodes OfaTreeOptionsDialog::LoadNodes(
if ( sLabel.isEmpty() )
sLabel = sGroupName;
- OUString sTemp = getGroupName( sLabel, !rExtensionId.isEmpty() );
+ OUString sTemp = getGroupName( sLabel, !rExtensionId.empty() );
if ( !sTemp.isEmpty() )
sLabel = sTemp;
std::unique_ptr<OptionsNode> pNode(new OptionsNode(sNodeId, sLabel, bAllModules));
- if ( rExtensionId.isEmpty() && !isNodeActive( pNode.get(), pModule ) )
+ if ( rExtensionId.empty() && !isNodeActive( pNode.get(), pModule ) )
{
continue;
}
@@ -1812,7 +1812,7 @@ VectorOfNodes OfaTreeOptionsDialog::LoadNodes(
xLeaveAccess->getByName( "GroupId" ) >>= sLeafGrpId;
xLeaveAccess->getByName( "GroupIndex" ) >>= nLeafGrpIdx;
- if ( rExtensionId.isEmpty() || sId == rExtensionId )
+ if ( rExtensionId.empty() || sId == rExtensionId )
{
std::unique_ptr<OptionsLeaf> pLeaf(new OptionsLeaf(
sLeafLabel, sLeafURL, sEventHdl, sLeafGrpId, nLeafGrpIdx ));
@@ -1883,7 +1883,7 @@ VectorOfNodes OfaTreeOptionsDialog::LoadNodes(
return aOutNodeList;
}
-static sal_uInt16 lcl_getGroupId( const OUString& rGroupName, const weld::TreeView& rTreeLB )
+static sal_uInt16 lcl_getGroupId( std::u16string_view rGroupName, const weld::TreeView& rTreeLB )
{
sal_uInt16 nRet = 0;
diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx
index 2328277eb4d8..9b5ff2e30418 100644
--- a/cui/source/tabpages/autocdlg.cxx
+++ b/cui/source/tabpages/autocdlg.cxx
@@ -1175,7 +1175,7 @@ IMPL_LINK(OfaAutocorrReplacePage, ModifyHdl, weld::Entry&, rEdt, void)
m_xNewReplacePB->set_sensitive(bEnableNew);
}
-static bool lcl_FindInArray(std::vector<OUString>& rStrings, const OUString& rString)
+static bool lcl_FindInArray(std::vector<OUString>& rStrings, std::u16string_view rString)
{
for (auto const& elem : rStrings)
{
diff --git a/cui/source/tabpages/tpbitmap.cxx b/cui/source/tabpages/tpbitmap.cxx
index ebb4426f6ce2..647bcaa105e3 100644
--- a/cui/source/tabpages/tpbitmap.cxx
+++ b/cui/source/tabpages/tpbitmap.cxx
@@ -802,7 +802,7 @@ sal_Int32 SvxBitmapTabPage::SearchBitmapList(const GraphicObject& rGraphicObject
return nPos;
}
-sal_Int32 SvxBitmapTabPage::SearchBitmapList(const OUString& rBitmapName)
+sal_Int32 SvxBitmapTabPage::SearchBitmapList(std::u16string_view rBitmapName)
{
tools::Long nCount = m_pBitmapList->Count();
bool bValidBitmapName = true;
diff --git a/cui/source/tabpages/tpcolor.cxx b/cui/source/tabpages/tpcolor.cxx
index c9a6060f8169..6eac86883c99 100644
--- a/cui/source/tabpages/tpcolor.cxx
+++ b/cui/source/tabpages/tpcolor.cxx
@@ -620,7 +620,7 @@ void SvxColorTabPage::UpdateColorValues( bool bUpdatePreset )
}
}
-sal_Int32 SvxColorTabPage::FindInCustomColors(OUString const & aColorName)
+sal_Int32 SvxColorTabPage::FindInCustomColors(std::u16string_view aColorName)
{
css::uno::Sequence< OUString > aCustomColorNameList(officecfg::Office::Common::UserColors::CustomColorName::get());
tools::Long nCount = aCustomColorNameList.getLength();
diff --git a/cui/source/tabpages/tpgradnt.cxx b/cui/source/tabpages/tpgradnt.cxx
index 76b58d775cc0..573659a471aa 100644
--- a/cui/source/tabpages/tpgradnt.cxx
+++ b/cui/source/tabpages/tpgradnt.cxx
@@ -609,7 +609,7 @@ void SvxGradientTabPage::SetControlState_Impl( css::awt::GradientStyle eXGS )
}
}
-sal_Int32 SvxGradientTabPage::SearchGradientList(const OUString& rGradientName)
+sal_Int32 SvxGradientTabPage::SearchGradientList(std::u16string_view rGradientName)
{
tools::Long nCount = m_pGradientList->Count();
bool bValidGradientName = true;
diff --git a/cui/source/tabpages/tphatch.cxx b/cui/source/tabpages/tphatch.cxx
index f2ff5360e73b..ec391dba935d 100644
--- a/cui/source/tabpages/tphatch.cxx
+++ b/cui/source/tabpages/tphatch.cxx
@@ -199,7 +199,7 @@ DeactivateRC SvxHatchTabPage::DeactivatePage( SfxItemSet* _pSet )
return DeactivateRC::LeavePage;
}
-sal_Int32 SvxHatchTabPage::SearchHatchList(const OUString& rHatchName)
+sal_Int32 SvxHatchTabPage::SearchHatchList(std::u16string_view rHatchName)
{
tools::Long nCount = m_pHatchingList->Count();
bool bValidHatchName = true;
diff --git a/cui/source/tabpages/tppattern.cxx b/cui/source/tabpages/tppattern.cxx
index 227100915483..9dfa12799c93 100644
--- a/cui/source/tabpages/tppattern.cxx
+++ b/cui/source/tabpages/tppattern.cxx
@@ -534,7 +534,7 @@ void SvxPatternTabPage::PointChanged(weld::DrawingArea* pDrawingArea, RectPoint)
m_xPatternLB->SetNoSelection();
}
-sal_Int32 SvxPatternTabPage::SearchPatternList(const OUString& rPatternName)
+sal_Int32 SvxPatternTabPage::SearchPatternList(std::u16string_view rPatternName)
{
tools::Long nCount = m_pPatternList->Count();
bool bValidPatternName = true;
diff --git a/dbaccess/source/core/api/KeySet.cxx b/dbaccess/source/core/api/KeySet.cxx
index 513f99105962..21c1ff0ef9a7 100644
--- a/dbaccess/source/core/api/KeySet.cxx
+++ b/dbaccess/source/core/api/KeySet.cxx
@@ -527,10 +527,10 @@ void OKeySet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrigi
::dbtools::throwSQLException( DBA_RES( RID_STR_NO_CONDITION_FOR_PK ), StandardSQLState::GENERAL_ERROR, m_xConnection );
// now create end execute the prepared statement
- executeUpdate(_rInsertRow ,_rOriginalRow,aSql.makeStringAndClear(),"",aIndexColumnPositions);
+ executeUpdate(_rInsertRow ,_rOriginalRow,aSql.makeStringAndClear(),u"",aIndexColumnPositions);
}
-void OKeySet::executeUpdate(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOriginalRow,const OUString& i_sSQL,const OUString& i_sTableName,const std::vector<sal_Int32>& _aIndexColumnPositions)
+void OKeySet::executeUpdate(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOriginalRow,const OUString& i_sSQL,std::u16string_view i_sTableName,const std::vector<sal_Int32>& _aIndexColumnPositions)
{
// now create end execute the prepared statement
Reference< XPreparedStatement > xPrep(m_xConnection->prepareStatement(i_sSQL));
@@ -542,7 +542,7 @@ void OKeySet::executeUpdate(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rO
// first the set values
for (auto const& columnName : *m_pColumnNames)
{
- if ( i_sTableName.isEmpty() || columnName.second.sTableName == i_sTableName )
+ if ( i_sTableName.empty() || columnName.second.sTableName == i_sTableName )
{
sal_Int32 nPos = columnName.second.nPosition;
if((*_rInsertRow)[nPos].isModified())
@@ -560,7 +560,7 @@ void OKeySet::executeUpdate(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rO
// and then the values of the where condition
for (auto const& keyColumnName : *m_pKeyColumnNames)
{
- if ( i_sTableName.isEmpty() || keyColumnName.second.sTableName == i_sTableName )
+ if ( i_sTableName.empty() || keyColumnName.second.sTableName == i_sTableName )
{
setParameter(i++,xParameter,(*_rOriginalRow)[keyColumnName.second.nPosition],keyColumnName.second.nType,keyColumnName.second.nScale);
}
@@ -621,10 +621,10 @@ void OKeySet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQLT
aValues[aValues.getLength() - 1] = ')';
aSql.append(aValues.makeStringAndClear());
// now create,fill and execute the prepared statement
- executeInsert(_rInsertRow,aSql.makeStringAndClear(),"",bRefetch);
+ executeInsert(_rInsertRow,aSql.makeStringAndClear(),u"",bRefetch);
}
-void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const OUString& i_sSQL,const OUString& i_sTableName,bool bRefetch )
+void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const OUString& i_sSQL,std::u16string_view i_sTableName,bool bRefetch )
{
// now create,fill and execute the prepared statement
Reference< XPreparedStatement > xPrep(m_xConnection->prepareStatement(i_sSQL));
@@ -633,7 +633,7 @@ void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const OUString& i_sSQ
sal_Int32 i = 1;
for (auto const& columnName : *m_pColumnNames)
{
- if ( i_sTableName.isEmpty() || columnName.second.sTableName == i_sTableName )
+ if ( i_sTableName.empty() || columnName.second.sTableName == i_sTableName )
{
const sal_Int32 nPos = columnName.second.nPosition;
if((*_rInsertRow)[nPos].isModified())
@@ -703,7 +703,7 @@ void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const OUString& i_sSQ
::comphelper::disposeComponent(xPrep);
- if ( i_sTableName.isEmpty() && !bAutoValuesFetched && m_bInserted )
+ if ( i_sTableName.empty() && !bAutoValuesFetched && m_bInserted )
{
// first check if all key column values were set
const OUString sQuote = getIdentifierQuoteString();
diff --git a/dbaccess/source/core/api/KeySet.hxx b/dbaccess/source/core/api/KeySet.hxx
index cc6175923063..e5d3c61ea5ac 100644
--- a/dbaccess/source/core/api/KeySet.hxx
+++ b/dbaccess/source/core/api/KeySet.hxx
@@ -136,8 +136,8 @@ namespace dbaccess
/// @throws css::uno::RuntimeException
bool doTryRefetch_throw();
void tryRefetch(const ORowSetRow& _rInsertRow,bool bRefetch);
- void executeUpdate(const ORowSetRow& _rInsertRow, const ORowSetRow& _rOriginalRow, const OUString& i_sSQL, const OUString& i_sTableName,const std::vector<sal_Int32>& _aIndexColumnPositions = std::vector<sal_Int32>());
- void executeInsert( const ORowSetRow& _rInsertRow, const OUString& i_sSQL, const OUString& i_sTableName, bool bRefetch = false);
+ void executeUpdate(const ORowSetRow& _rInsertRow, const ORowSetRow& _rOriginalRow, const OUString& i_sSQL, std::u16string_view i_sTableName,const std::vector<sal_Int32>& _aIndexColumnPositions = std::vector<sal_Int32>());
+ void executeInsert( const ORowSetRow& _rInsertRow, const OUString& i_sSQL, std::u16string_view i_sTableName, bool bRefetch = false);
void executeStatement(OUStringBuffer& io_aFilter, css::uno::Reference< css::sdb::XSingleSelectQueryComposer>& io_xAnalyzer);
virtual ~OKeySet() override;
diff --git a/dbaccess/source/core/api/OptimisticSet.cxx b/dbaccess/source/core/api/OptimisticSet.cxx
index 67fd18aaaea7..7db4ca08740b 100644
--- a/dbaccess/source/core/api/OptimisticSet.cxx
+++ b/dbaccess/source/core/api/OptimisticSet.cxx
@@ -336,7 +336,7 @@ void OptimisticSet::deleteRow(const ORowSetRow& _rDeleteRow,const connectivity::
}
}
-void OptimisticSet::executeDelete(const ORowSetRow& _rDeleteRow,const OUString& i_sSQL,const OUString& i_sTableName)
+void OptimisticSet::executeDelete(const ORowSetRow& _rDeleteRow,const OUString& i_sSQL,std::u16string_view i_sTableName)
{
// now create and execute the prepared statement
Reference< XPreparedStatement > xPrep(m_xConnection->prepareStatement(i_sSQL));
diff --git a/dbaccess/source/core/api/OptimisticSet.hxx b/dbaccess/source/core/api/OptimisticSet.hxx
index d5c2c069579c..bf5e3a80370a 100644
--- a/dbaccess/source/core/api/OptimisticSet.hxx
+++ b/dbaccess/source/core/api/OptimisticSet.hxx
@@ -39,7 +39,7 @@ namespace dbaccess
mutable bool m_bResultSetChanged;
- void executeDelete(const ORowSetRow& _rDeleteRow,const OUString& i_sSQL,const OUString& i_sTableName);
+ void executeDelete(const ORowSetRow& _rDeleteRow,const OUString& i_sSQL,std::u16string_view i_sTableName);
void fillJoinedColumns_throw(const std::vector< ::connectivity::TNodePair>& i_aJoinColumns);
void fillJoinedColumns_throw(const OUString& i_sLeftColumn,const OUString& i_sRightColumn);
protected:
diff --git a/dbaccess/source/core/dataaccess/databaseregistrations.cxx b/dbaccess/source/core/dataaccess/databaseregistrations.cxx
index 3e9b59551546..6009653ce1a7 100644
--- a/dbaccess/source/core/dataaccess/databaseregistrations.cxx
+++ b/dbaccess/source/core/dataaccess/databaseregistrations.cxx
@@ -131,7 +131,7 @@ namespace dbaccess
::utl::OConfigurationNode
- impl_getNodeForName_nothrow(const OUString& _rName);
+ impl_getNodeForName_nothrow(std::u16string_view _rName);
private:
Reference<XComponentContext> m_aContext;
@@ -155,7 +155,7 @@ namespace dbaccess
{
}
- ::utl::OConfigurationNode DatabaseRegistrations::impl_getNodeForName_nothrow( const OUString& _rName )
+ ::utl::OConfigurationNode DatabaseRegistrations::impl_getNodeForName_nothrow( std::u16string_view _rName )
{
const Sequence< OUString > aNames( m_aConfigurationRoot.getNodeNames() );
for ( auto const & nodeName : aNames )
diff --git a/dbaccess/source/core/misc/dsntypes.cxx b/dbaccess/source/core/misc/dsntypes.cxx
index 3662148b9462..b44b11fc16f0 100644
--- a/dbaccess/source/core/misc/dsntypes.cxx
+++ b/dbaccess/source/core/misc/dsntypes.cxx
@@ -152,7 +152,7 @@ OUString ODsnTypeCollection::getMediaType(const OUString& _sURL) const
return aFeatures.getOrDefault("MediaType",OUString());
}
-OUString ODsnTypeCollection::getDatasourcePrefixFromMediaType(const OUString& _sMediaType,const OUString& _sExtension)
+OUString ODsnTypeCollection::getDatasourcePrefixFromMediaType(std::u16string_view _sMediaType,std::u16string_view _sExtension)
{
OUString sURL, sFallbackURL;
const uno::Sequence< OUString > aURLs = m_aDriverConfig.getURLs();
@@ -169,7 +169,7 @@ OUString ODsnTypeCollection::getDatasourcePrefixFromMediaType(const OUString& _s
sURL = *pIter;
break;
}
- if ( sFileExtension.isEmpty() && !_sExtension.isEmpty() )
+ if ( sFileExtension.isEmpty() && !_sExtension.empty() )
sFallbackURL = *pIter;
}
}
diff --git a/dbaccess/source/inc/dsntypes.hxx b/dbaccess/source/inc/dsntypes.hxx
index 334b297b0bf5..38f8ba9213a0 100644
--- a/dbaccess/source/inc/dsntypes.hxx
+++ b/dbaccess/source/inc/dsntypes.hxx
@@ -135,7 +135,7 @@ public:
OUString getMediaType(const OUString& _sURL) const;
/// returns the dsn prefix for a given media type
- OUString getDatasourcePrefixFromMediaType(const OUString& _sMediaType, const OUString& _sExtension );
+ OUString getDatasourcePrefixFromMediaType(std::u16string_view _sMediaType, std::u16string_view _sExtension );
void extractHostNamePort(const OUString& _rDsn,OUString& _sDatabaseName,OUString& _rHostname,sal_Int32& _nPortNumber) const;
diff --git a/dbaccess/source/ui/app/subcomponentmanager.cxx b/dbaccess/source/ui/app/subcomponentmanager.cxx
index 08df1dff0930..f2a81ecf98a1 100644
--- a/dbaccess/source/ui/app/subcomponentmanager.cxx
+++ b/dbaccess/source/ui/app/subcomponentmanager.cxx
@@ -508,10 +508,10 @@ namespace dbaui
return true;
}
- bool SubComponentManager::closeSubFrames( const OUString& i_rName, const sal_Int32 _nComponentType )
+ bool SubComponentManager::closeSubFrames( std::u16string_view i_rName, const sal_Int32 _nComponentType )
{
::osl::MutexGuard aGuard( m_pData->getMutex() );
- ENSURE_OR_RETURN_FALSE( !i_rName.isEmpty(), "SubComponentManager::closeSubFrames: illegal name!" );
+ ENSURE_OR_RETURN_FALSE( !i_rName.empty(), "SubComponentManager::closeSubFrames: illegal name!" );
SubComponents aWorkingCopy( m_pData->m_aComponents );
for (auto const& elem : aWorkingCopy)
diff --git a/dbaccess/source/ui/app/subcomponentmanager.hxx b/dbaccess/source/ui/app/subcomponentmanager.hxx
index b14e96d68116..402a3d593b90 100644
--- a/dbaccess/source/ui/app/subcomponentmanager.hxx
+++ b/dbaccess/source/ui/app/subcomponentmanager.hxx
@@ -90,7 +90,7 @@ namespace dbaui
exist.
*/
bool closeSubFrames(
- const OUString& _rName,
+ std::u16string_view _rName,
const sal_Int32 _nComponentType
);
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx
index b05ad037377f..67ae3cac0f6d 100644
--- a/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/dbaccess/source/ui/browser/unodatbr.cxx
@@ -2783,7 +2783,7 @@ void SAL_CALL SbaTableQueryBrowser::elementInserted(const ContainerEvent& rEvent
SbaXDataBrowserController::elementInserted(rEvent);
}
-bool SbaTableQueryBrowser::isCurrentlyDisplayedChanged(const OUString& rName, const weld::TreeIter& rContainer)
+bool SbaTableQueryBrowser::isCurrentlyDisplayedChanged(std::u16string_view rName, const weld::TreeIter& rContainer)
{
if (!m_xCurrentlyDisplayed)
return false;
@@ -3758,7 +3758,7 @@ void SAL_CALL SbaTableQueryBrowser::registeredDatabaseLocation( const DatabaseRe
implAddDatasource( Event.Name, SharedConnection() );
}
-void SbaTableQueryBrowser::impl_cleanupDataSourceEntry(const OUString& rDataSourceName)
+void SbaTableQueryBrowser::impl_cleanupDataSourceEntry(std::u16string_view rDataSourceName)
{
// get the top-level representing the removed data source
weld::TreeView& rTreeView = m_pTreeView->GetWidget();
diff --git a/dbaccess/source/ui/control/FieldDescControl.cxx b/dbaccess/source/ui/control/FieldDescControl.cxx
index f0d9b9ee4468..8f3854f3740d 100644
--- a/dbaccess/source/ui/control/FieldDescControl.cxx
+++ b/dbaccess/source/ui/control/FieldDescControl.cxx
@@ -133,7 +133,7 @@ void OFieldDescControl::dispose()
m_xBuilder.reset();
}
-OUString OFieldDescControl::BoolStringPersistent(const OUString& rUIString) const
+OUString OFieldDescControl::BoolStringPersistent(std::u16string_view rUIString) const
{
if (rUIString == aNo)
return OUString('0');
diff --git a/dbaccess/source/ui/control/dbtreelistbox.cxx b/dbaccess/source/ui/control/dbtreelistbox.cxx
index d63beff8c346..11215d56ac93 100644
--- a/dbaccess/source/ui/control/dbtreelistbox.cxx
+++ b/dbaccess/source/ui/control/dbtreelistbox.cxx
@@ -180,7 +180,7 @@ TreeListBox::~TreeListBox()
{
}
-std::unique_ptr<weld::TreeIter> TreeListBox::GetEntryPosByName(const OUString& aName, const weld::TreeIter* pStart, const IEntryFilter* _pFilter) const
+std::unique_ptr<weld::TreeIter> TreeListBox::GetEntryPosByName(std::u16string_view aName, const weld::TreeIter* pStart, const IEntryFilter* _pFilter) const
{
auto xEntry(m_xTreeView->make_iterator(pStart));
if (!pStart && !m_xTreeView->get_iter_first(*xEntry))
diff --git a/dbaccess/source/ui/dlg/dbfindex.cxx b/dbaccess/source/ui/dlg/dbfindex.cxx
index 011050e8f8cf..d66e48405d00 100644
--- a/dbaccess/source/ui/dlg/dbfindex.cxx
+++ b/dbaccess/source/ui/dlg/dbfindex.cxx
@@ -116,7 +116,7 @@ void ODbaseIndexDialog::implInsertIndex(const OTableIndex& _rIndex, TableIndexLi
_rDisplay.select(0);
}
-OTableIndex ODbaseIndexDialog::RemoveTableIndex( const OUString& _rTableName, const OUString& _rIndexName )
+OTableIndex ODbaseIndexDialog::RemoveTableIndex( std::u16string_view _rTableName, const OUString& _rIndexName )
{
OTableIndex aReturn;
@@ -130,7 +130,7 @@ OTableIndex ODbaseIndexDialog::RemoveTableIndex( const OUString& _rTableName, co
return implRemoveIndex(_rIndexName, aTablePos->aIndexList, *m_xLB_TableIndexes, true/*_bMustExist*/);
}
-void ODbaseIndexDialog::InsertTableIndex( const OUString& _rTableName, const OTableIndex& _rIndex)
+void ODbaseIndexDialog::InsertTableIndex( std::u16string_view _rTableName, const OTableIndex& _rIndex)
{
TableInfoList::iterator aTablePos = std::find_if(m_aTableInfoList.begin(), m_aTableInfoList.end(),
[&] (const OTableInfo& arg) { return arg.aTableName == _rTableName; });
diff --git a/dbaccess/source/ui/dlg/dbfindex.hxx b/dbaccess/source/ui/dlg/dbfindex.hxx
index 0349b6c58b75..53b75640e6f4 100644
--- a/dbaccess/source/ui/dlg/dbfindex.hxx
+++ b/dbaccess/source/ui/dlg/dbfindex.hxx
@@ -95,8 +95,8 @@ protected:
OTableIndex RemoveFreeIndex( const OUString& _rName, bool _bMustExist ) { return implRemoveIndex(_rName, m_aFreeIndexList, *m_xLB_FreeIndexes, _bMustExist); }
void InsertFreeIndex( const OTableIndex& _rIndex ) { implInsertIndex(_rIndex, m_aFreeIndexList, *m_xLB_FreeIndexes); }
- OTableIndex RemoveTableIndex( const OUString& _rTableName, const OUString& _rIndexName );
- void InsertTableIndex( const OUString& _rTableName, const OTableIndex& _rIndex );
+ OTableIndex RemoveTableIndex( std::u16string_view _rTableName, const OUString& _rIndexName );
+ void InsertTableIndex( std::u16string_view _rTableName, const OTableIndex& _rIndex );
void checkButtons();
diff --git a/dbaccess/source/ui/dlg/queryfilter.cxx b/dbaccess/source/ui/dlg/queryfilter.cxx
index 56db11946315..67df2db8ccdf 100644
--- a/dbaccess/source/ui/dlg/queryfilter.cxx
+++ b/dbaccess/source/ui/dlg/queryfilter.cxx
@@ -183,7 +183,7 @@ DlgFilterCrit::~DlgFilterCrit()
#define LbText(x) ((x).get_active_text())
#define LbPos(x) ((x).get_active())
-sal_Int32 DlgFilterCrit::GetOSQLPredicateType( const OUString& _rSelectedPredicate ) const
+sal_Int32 DlgFilterCrit::GetOSQLPredicateType( std::u16string_view _rSelectedPredicate ) const
{
sal_Int32 nPredicateIndex = -1;
for ( size_t i=0; i < m_aSTR_COMPARE_OPERATORS.size(); ++i)
@@ -493,7 +493,7 @@ void DlgFilterCrit::SetLine( int nIdx, const PropertyValue& _rItem, bool _bOr )
pPredicateValueControl->set_text( aString );
}
-void DlgFilterCrit::SelectField(weld::ComboBox& rBox, const OUString& rField)
+void DlgFilterCrit::SelectField(weld::ComboBox& rBox, std::u16string_view rField)
{
const sal_Int32 nCnt = rBox.get_count();
diff --git a/dbaccess/source/ui/inc/FieldDescControl.hxx b/dbaccess/source/ui/inc/FieldDescControl.hxx
index c467d4ca5402..f321276827b0 100644
--- a/dbaccess/source/ui/inc/FieldDescControl.hxx
+++ b/dbaccess/source/ui/inc/FieldDescControl.hxx
@@ -145,7 +145,7 @@ namespace dbaui
virtual bool isAutoIncrementValueEnabled() const = 0;
virtual OUString getAutoIncrementValue() const = 0;
- OUString BoolStringPersistent(const OUString& rUIString) const;
+ OUString BoolStringPersistent(std::u16string_view rUIString) const;
OUString BoolStringUI(const OUString& rPersistentString) const;
const OPropColumnEditCtrl* getColumnCtrl() const { return m_xColumnName.get(); }
diff --git a/dbaccess/source/ui/inc/QueryDesignView.hxx b/dbaccess/source/ui/inc/QueryDesignView.hxx
index 8bcb0f58e1a0..efef444e8670 100644
--- a/dbaccess/source/ui/inc/QueryDesignView.hxx
+++ b/dbaccess/source/ui/inc/QueryDesignView.hxx
@@ -105,12 +105,12 @@ namespace dbaui
const OUString& getDecimalSeparator() const { return m_sDecimalSep;}
SqlParseError InsertField( const OTableFieldDescRef& rInfo, bool bActivate = true);
- bool HasFieldByAliasName(const OUString& rFieldName, OTableFieldDescRef const & rInfo) const;
+ bool HasFieldByAliasName(std::u16string_view rFieldName, OTableFieldDescRef const & rInfo) const;
// called when a table from tabview was deleted
void TableDeleted(const OUString& rAliasName);
sal_Int32 getColWidth( sal_uInt16 _nColPos) const;
- void fillValidFields(const OUString& strTableName, weld::ComboBox& rFieldList);
+ void fillValidFields(std::u16string_view strTableName, weld::ComboBox& rFieldList);
void SaveUIConfig();
void stopTimer();
diff --git a/dbaccess/source/ui/inc/TableCopyHelper.hxx b/dbaccess/source/ui/inc/TableCopyHelper.hxx
index 3d39d368307e..92ddceb37507 100644
--- a/dbaccess/source/ui/inc/TableCopyHelper.hxx
+++ b/dbaccess/source/ui/inc/TableCopyHelper.hxx
@@ -96,7 +96,7 @@ namespace dbaui
The name of the dest data source.
*/
void pasteTable( const TransferableDataHelper& _rTransData
- ,const OUString& _sDestDataSourceName
+ ,std::u16string_view _sDestDataSourceName
,const SharedConnection& _xConnection);
/** pastes a table into the data source
@@ -109,7 +109,7 @@ namespace dbaui
*/
void pasteTable( SotClipboardFormatId _nFormatId
,const TransferableDataHelper& _rTransData
- ,const OUString& _sDestDataSourceName
+ ,std::u16string_view _sDestDataSourceName
,const SharedConnection& _xConnection);
/** copies a table which was constructed by tags like HTML or RTF
@@ -133,7 +133,7 @@ namespace dbaui
The connection
*/
void asyncCopyTagTable( DropDescriptor& _rDesc
- ,const OUString& _sDestDataSourceName
+ ,std::u16string_view _sDestDataSourceName
,const SharedConnection& _xConnection);
/** copies a table which was constructed by tags like HTML or RTF
@@ -164,21 +164,21 @@ namespace dbaui
*/
void pasteTable(
const svx::ODataAccessDescriptor& _rPasteData,
- const OUString& _sDestDataSourceName,
+ std::u16string_view _sDestDataSourceName,
const SharedConnection& _xDestConnection
);
/** insert a table into the data source. The source can either be a table or a query
*/
void insertTable(
- const OUString& i_rSourceDataSource,
+ std::u16string_view i_rSourceDataSource,
const css::uno::Reference< css::sdbc::XConnection>& i_rSourceConnection,
const OUString& i_rCommand,
const sal_Int32 i_nCommandType,
const css::uno::Reference< css::sdbc::XResultSet >& i_rSourceRows,
const css::uno::Sequence< css::uno::Any >& i_rSelection,
const bool i_bBookmarkSelection,
- const OUString& i_rDestDataSource,
+ std::u16string_view i_rDestDataSource,
const css::uno::Reference< css::sdbc::XConnection>& i_rDestConnection
);
diff --git a/dbaccess/source/ui/inc/WColumnSelect.hxx b/dbaccess/source/ui/inc/WColumnSelect.hxx
index 405ac7f31c2b..706ccfd0371c 100644
--- a/dbaccess/source/ui/inc/WColumnSelect.hxx
+++ b/dbaccess/source/ui/inc/WColumnSelect.hxx
@@ -64,7 +64,7 @@ namespace dbaui
void enableButtons();
sal_Int32 adjustColumnPosition(weld::TreeView const * _pLeft,
- const OUString& _sColumnName,
+ std::u16string_view _sColumnName,
ODatabaseExport::TColumnVector::size_type nCurrentPos,
const ::comphelper::UStringMixEqual& _aCase);
diff --git a/dbaccess/source/ui/inc/dbtreelistbox.hxx b/dbaccess/source/ui/inc/dbtreelistbox.hxx
index af68b9e9b8d7..4838e5c74d10 100644
--- a/dbaccess/source/ui/inc/dbtreelistbox.hxx
+++ b/dbaccess/source/ui/inc/dbtreelistbox.hxx
@@ -90,7 +90,7 @@ namespace dbaui
TreeListBox(std::unique_ptr<weld::TreeView> xTreeView, bool bSQLType);
virtual ~TreeListBox();
- std::unique_ptr<weld::TreeIter> GetEntryPosByName(const OUString& rName,
+ std::unique_ptr<weld::TreeIter> GetEntryPosByName(std::u16string_view rName,
const weld::TreeIter* pStart = nullptr,
const IEntryFilter* pFilter = nullptr) const;
diff --git a/dbaccess/source/ui/inc/queryfilter.hxx b/dbaccess/source/ui/inc/queryfilter.hxx
index 258dcc51ec08..396778f22997 100644
--- a/dbaccess/source/ui/inc/queryfilter.hxx
+++ b/dbaccess/source/ui/inc/queryfilter.hxx
@@ -75,13 +75,13 @@ namespace dbaui
std::unique_ptr<weld::ComboBox> m_xLB_WHERECOMP3;
std::unique_ptr<weld::Entry> m_xET_WHEREVALUE3;
- static void SelectField(weld::ComboBox& rBox, const OUString& rField);
+ static void SelectField(weld::ComboBox& rBox, std::u16string_view rField);
DECL_LINK(ListSelectHdl, weld::ComboBox&, void);
DECL_LINK(ListSelectCompHdl, weld::ComboBox&, void);
void SetLine( int nIdx, const css::beans::PropertyValue& _rItem, bool _bOr );
void EnableLines();
- sal_Int32 GetOSQLPredicateType( const OUString& _rSelectedPredicate ) const;
+ sal_Int32 GetOSQLPredicateType( std::u16string_view _rSelectedPredicate ) const;
static sal_Int32 GetSelectionPos(sal_Int32 eType, const weld::ComboBox& rListBox);
bool getCondition(const weld::ComboBox& _rField, const weld::ComboBox& _rComp, const weld::Entry& _rValue, css::beans::PropertyValue& _rFilter) const;
void fillLines(int &i, const css::uno::Sequence< css::uno::Sequence< css::beans::PropertyValue > >& _aValues);
diff --git a/dbaccess/source/ui/inc/unodatbr.hxx b/dbaccess/source/ui/inc/unodatbr.hxx
index e147b44b9e02..637f173da20e 100644
--- a/dbaccess/source/ui/inc/unodatbr.hxx
+++ b/dbaccess/source/ui/inc/unodatbr.hxx
@@ -268,7 +268,7 @@ namespace dbaui
void implAddDatasource( const OUString& _rDataSourceName, const SharedConnection& _rxConnection );
/// removes (and cleans up) the entry for the given data source
- void impl_cleanupDataSourceEntry( const OUString& _rDataSourceName );
+ void impl_cleanupDataSourceEntry( std::u16string_view _rDataSourceName );
/// clears the tree list box
void clearTreeModel();
@@ -430,7 +430,7 @@ namespace dbaui
@return
<TRUE/> if it is the currently displayed otherwise <FALSE/>
*/
- bool isCurrentlyDisplayedChanged(const OUString& rName, const weld::TreeIter& rContainer);
+ bool isCurrentlyDisplayedChanged(std::u16string_view rName, const weld::TreeIter& rContainer);
/** called whenever the content of the browser is used for preview, as the very last action
of the load process
diff --git a/dbaccess/source/ui/misc/TableCopyHelper.cxx b/dbaccess/source/ui/misc/TableCopyHelper.cxx
index 36d7ab70fa14..7e944e4d9516 100644
--- a/dbaccess/source/ui/misc/TableCopyHelper.cxx
+++ b/dbaccess/source/ui/misc/TableCopyHelper.cxx
@@ -61,10 +61,10 @@ OTableCopyHelper::OTableCopyHelper(OGenericUnoController* _pController)
{
}
-void OTableCopyHelper::insertTable( const OUString& i_rSourceDataSource, const Reference<XConnection>& i_rSourceConnection,
+void OTableCopyHelper::insertTable( std::u16string_view i_rSourceDataSource, const Reference<XConnection>& i_rSourceConnection,
const OUString& i_rCommand, const sal_Int32 i_nCommandType,
const Reference< XResultSet >& i_rSourceRows, const Sequence< Any >& i_rSelection, const bool i_bBookmarkSelection,
- const OUString& i_rDestDataSource, const Reference<XConnection>& i_rDestConnection)
+ std::u16string_view i_rDestDataSource, const Reference<XConnection>& i_rDestConnection)
{
if ( CommandType::QUERY != i_nCommandType && CommandType::TABLE != i_nCommandType )
{
@@ -121,7 +121,7 @@ void OTableCopyHelper::insertTable( const OUString& i_rSourceDataSource, const R
}
}
-void OTableCopyHelper::pasteTable( const svx::ODataAccessDescriptor& _rPasteData, const OUString& i_rDestDataSourceName,
+void OTableCopyHelper::pasteTable( const svx::ODataAccessDescriptor& _rPasteData, std::u16string_view i_rDestDataSourceName,
const SharedConnection& i_rDestConnection )
{
OUString sSrcDataSourceName = _rPasteData.getDataSource();
@@ -166,7 +166,7 @@ void OTableCopyHelper::pasteTable( const svx::ODataAccessDescriptor& _rPasteData
void OTableCopyHelper::pasteTable( SotClipboardFormatId _nFormatId
,const TransferableDataHelper& _rTransData
- ,const OUString& i_rDestDataSource
+ ,std::u16string_view i_rDestDataSource
,const SharedConnection& _xConnection)
{
if ( _nFormatId == SotClipboardFormatId::DBACCESS_TABLE || _nFormatId == SotClipboardFormatId::DBACCESS_QUERY )
@@ -208,7 +208,7 @@ void OTableCopyHelper::pasteTable( SotClipboardFormatId _nFormatId
}
void OTableCopyHelper::pasteTable( const TransferableDataHelper& _rTransData
- ,const OUString& i_rDestDataSource
+ ,std::u16string_view i_rDestDataSource
,const SharedConnection& _xConnection)
{
if ( _rTransData.HasFormat(SotClipboardFormatId::DBACCESS_TABLE) || _rTransData.HasFormat(SotClipboardFormatId::DBACCESS_QUERY) )
@@ -286,7 +286,7 @@ bool OTableCopyHelper::copyTagTable(const TransferableDataHelper& _aDroppedData
}
void OTableCopyHelper::asyncCopyTagTable( DropDescriptor& _rDesc
- ,const OUString& i_rDestDataSource
+ ,std::u16string_view i_rDestDataSource
,const SharedConnection& _xConnection)
{
if ( _rDesc.aHtmlRtfStorage.is() )
diff --git a/dbaccess/source/ui/misc/WColumnSelect.cxx b/dbaccess/source/ui/misc/WColumnSelect.cxx
index 8941119e9234..544b79d03267 100644
--- a/dbaccess/source/ui/misc/WColumnSelect.cxx
+++ b/dbaccess/source/ui/misc/WColumnSelect.cxx
@@ -346,7 +346,7 @@ void OWizColumnSelect::moveColumn( weld::TreeView* _pRight,
// been removed earlier and adjust accordingly. Based on the
// algorithm employed in moveColumn().
sal_Int32 OWizColumnSelect::adjustColumnPosition(weld::TreeView const * _pLeft,
- const OUString& _sColumnName,
+ std::u16string_view _sColumnName,
ODatabaseExport::TColumnVector::size_type nCurrentPos,
const ::comphelper::UStringMixEqual& _aCase)
{
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index 96e44ab6e68d..b8aa3f7c4b81 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -2627,7 +2627,7 @@ void OQueryDesignView::TableDeleted(const OUString& rAliasName)
static_cast<OQueryController&>(getController()).InvalidateFeature(ID_BROWSER_ADDTABLE); // inform the view again
}
-bool OQueryDesignView::HasFieldByAliasName(const OUString& rFieldName, OTableFieldDescRef const & rInfo) const
+bool OQueryDesignView::HasFieldByAliasName(std::u16string_view rFieldName, OTableFieldDescRef const & rInfo) const
{
return m_pSelectionBox->HasFieldByAliasName( rFieldName, rInfo);
}
@@ -2646,11 +2646,11 @@ sal_Int32 OQueryDesignView::getColWidth(sal_uInt16 _nColPos) const
return nWidth;
}
-void OQueryDesignView::fillValidFields(const OUString& sAliasName, weld::ComboBox& rFieldList)
+void OQueryDesignView::fillValidFields(std::u16string_view sAliasName, weld::ComboBox& rFieldList)
{
rFieldList.clear();
- bool bAllTables = sAliasName.isEmpty();
+ bool bAllTables = sAliasName.empty();
OJoinTableView::OTableWindowMap& rTabWins = m_pTableView->GetTabWinMap();
OUString strCurrentPrefix;
diff --git a/dbaccess/source/ui/querydesign/QueryTableView.cxx b/dbaccess/source/ui/querydesign/QueryTableView.cxx
index 22a456e81ea9..77ca793e5077 100644
--- a/dbaccess/source/ui/querydesign/QueryTableView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryTableView.cxx
@@ -353,7 +353,7 @@ void OQueryTableView::AddTabWin(const OUString& _rTableName, const OUString& _rA
}
// find the table which has a foreign key with this referencedTable name
-static Reference<XPropertySet> getKeyReferencedTo(const Reference<XIndexAccess>& _rxKeys,const OUString& _rReferencedTable)
+static Reference<XPropertySet> getKeyReferencedTo(const Reference<XIndexAccess>& _rxKeys,std::u16string_view _rReferencedTable)
{
if(!_rxKeys.is())
return Reference<XPropertySet>();
diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
index 22e17c01ec36..fccd2e800814 100644
--- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
+++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
@@ -554,14 +554,14 @@ void OSelectionBrowseBox::InitController(CellControllerRef& /*rController*/, sal
Controller()->SaveValue();
}
-void OSelectionBrowseBox::notifyTableFieldChanged(const OUString& _sOldAlias, const OUString& _sAlias, bool& _bListAction, sal_uInt16 _nColumnId)
+void OSelectionBrowseBox::notifyTableFieldChanged(const OUString& _sOldAlias, std::u16string_view _sAlias, bool& _bListAction, sal_uInt16 _nColumnId)
{
appendUndoAction(_sOldAlias,_sAlias,BROW_TABLE_ROW,_bListAction);
if ( m_bVisibleRow[BROW_TABLE_ROW] )
RowModified(GetBrowseRow(BROW_TABLE_ROW), _nColumnId);
}
-void OSelectionBrowseBox::notifyFunctionFieldChanged(const OUString& _sOldFunctionName, const OUString& _sFunctionName, bool& _bListAction, sal_uInt16 _nColumnId)
+void OSelectionBrowseBox::notifyFunctionFieldChanged(const OUString& _sOldFunctionName, std::u16string_view _sFunctionName, bool& _bListAction, sal_uInt16 _nColumnId)
{
appendUndoAction(_sOldFunctionName,_sFunctionName,BROW_FUNCTION_ROW,_bListAction);
if ( !m_bVisibleRow[BROW_FUNCTION_ROW] )
@@ -1056,7 +1056,7 @@ bool OSelectionBrowseBox::SaveModified()
// we have to change the visible flag, so we must append also an undo action
pEntry->SetVisible();
m_pVisibleCell->GetBox().set_active(true);
- appendUndoAction("0","1",BROW_VIS_ROW,bListAction);
+ appendUndoAction("0",u"1",BROW_VIS_ROW,bListAction);
RowModified(GetBrowseRow(BROW_VIS_ROW), GetCurColumnId());
}
@@ -1197,7 +1197,7 @@ bool OSelectionBrowseBox::SaveModified()
{
// Default to visible
pEntry->SetVisible();
- appendUndoAction("0","1",BROW_VIS_ROW,bListAction);
+ appendUndoAction("0",u"1",BROW_VIS_ROW,bListAction);
RowModified(BROW_VIS_ROW, GetCurColumnId());
// if required add empty columns
@@ -2461,7 +2461,7 @@ void OSelectionBrowseBox::copy()
}
}
-void OSelectionBrowseBox::appendUndoAction(const OUString& _rOldValue, const OUString& _rNewValue, sal_Int32 _nRow, bool& _bListAction)
+void OSelectionBrowseBox::appendUndoAction(const OUString& _rOldValue, std::u16string_view _rNewValue, sal_Int32 _nRow, bool& _bListAction)
{
if ( !m_bInUndoMode && _rNewValue != _rOldValue )
{
@@ -2474,7 +2474,7 @@ void OSelectionBrowseBox::appendUndoAction(const OUString& _rOldValue, const OUS
}
}
-void OSelectionBrowseBox::appendUndoAction(const OUString& _rOldValue,const OUString& _rNewValue,sal_Int32 _nRow)
+void OSelectionBrowseBox::appendUndoAction(const OUString& _rOldValue,std::u16string_view _rNewValue,sal_Int32 _nRow)
{
if ( !m_bInUndoMode && _rNewValue != _rOldValue )
{
@@ -2691,7 +2691,7 @@ Reference< XAccessible > OSelectionBrowseBox::CreateAccessibleCell( sal_Int32 _n
return EditBrowseBox::CreateAccessibleCell( _nRow, _nColumnPos );
}
-bool OSelectionBrowseBox::HasFieldByAliasName(const OUString& rFieldName, OTableFieldDescRef const & rInfo) const
+bool OSelectionBrowseBox::HasFieldByAliasName(std::u16string_view rFieldName, OTableFieldDescRef const & rInfo) const
{
for (auto const& field : getFields())
{
diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx b/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
index 8c2ea555a98e..c3cd5641d3e1 100644
--- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
+++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
@@ -86,7 +86,7 @@ namespace dbaui
void RemoveColumn( sal_uInt16 _nColumnId );
void DeleteFields( const OUString& rAliasName );
- bool HasFieldByAliasName(const OUString& rFieldName, OTableFieldDescRef const & rInfo) const;
+ bool HasFieldByAliasName(std::u16string_view rFieldName, OTableFieldDescRef const & rInfo) const;
// AddGroupBy:: inserts a field with function == grouping. If the fields already exists and uses an aggregate function,
// the flag is not set
@@ -219,8 +219,8 @@ namespace dbaui
sal_Int32 GetRealRow(sal_Int32 nRow) const;
sal_Int32 GetBrowseRow(sal_Int32 nRowId) const;
bool GetFunctionName(sal_uInt32 _nFunctionTokenId, OUString& rFkt);
- void appendUndoAction(const OUString& _rOldValue,const OUString& _rNewValue,sal_Int32 _nRow, bool& _bListAction);
- void appendUndoAction(const OUString& _rOldValue,const OUString& _rNewValue,sal_Int32 _nRow);
+ void appendUndoAction(const OUString& _rOldValue,std::u16string_view _rNewValue,sal_Int32 _nRow, bool& _bListAction);
+ void appendUndoAction(const OUString& _rOldValue,std::u16string_view _rNewValue,sal_Int32 _nRow);
OTableFields& getFields() const;
static void enableControl(const OTableFieldDescRef& _rEntry,Window* _pControl);
void setTextCellContext(const OTableFieldDescRef& _rEntry,const OUString& _sText,const OString& _sHelpId);
@@ -281,7 +281,7 @@ namespace dbaui
@param _bListAction
Will be set to <TRUE/> when we are in a list action otherwise <FALSE/>
*/
- void notifyTableFieldChanged(const OUString& _sOldAlias,const OUString& _sAlias, bool& _bListAction,sal_uInt16 _nColumnId);
+ void notifyTableFieldChanged(const OUString& _sOldAlias,std::u16string_view _sAlias, bool& _bListAction,sal_uInt16 _nColumnId);
/** append an undo action for the function field
@param _sOldFunctionName
@@ -291,7 +291,7 @@ namespace dbaui
@param _bListAction
Will be set to <TRUE/> when we are in a list action otherwise <FALSE/>
*/
- void notifyFunctionFieldChanged(const OUString& _sOldFunctionName,const OUString& _sFunctionName, bool& _bListAction,sal_uInt16 _nColumnId);
+ void notifyFunctionFieldChanged(const OUString& _sOldFunctionName,std::u16string_view _sFunctionName, bool& _bListAction,sal_uInt16 _nColumnId);
/** clears the function fields of the submitted entry if it doesn't match the SQL standard and append an undo action.
E.q. AGGREGATE functions are only valid when the field name isn't an asterisk
diff --git a/dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx b/dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx
index 1e65397a70dd..9f15c1e1b90b 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx
@@ -64,7 +64,7 @@ namespace dbaui
void SetControlText( sal_uInt16 nControlId, const OUString& rText )
{ m_xFieldControl->SetControlText(nControlId,rText); }
- OUString BoolStringPersistent(const OUString& rUIString) const { return m_xFieldControl->BoolStringPersistent(rUIString); }
+ OUString BoolStringPersistent(std::u16string_view rUIString) const { return m_xFieldControl->BoolStringPersistent(rUIString); }
OUString BoolStringUI(const OUString& rPersistentString) const { return m_xFieldControl->BoolStringUI(rPersistentString); }
virtual bool HasChildPathFocus() const override;
diff --git a/desktop/source/deployment/inc/dp_descriptioninfoset.hxx b/desktop/source/deployment/inc/dp_descriptioninfoset.hxx
index 9b857746c005..40197f7efb7c 100644
--- a/desktop/source/deployment/inc/dp_descriptioninfoset.hxx
+++ b/desktop/source/deployment/inc/dp_descriptioninfoset.hxx
@@ -260,7 +260,7 @@ private:
/** Helper method to compare the versions with the current version
*/
SAL_DLLPRIVATE static bool
- checkDenylistVersion(const OUString& currentversion,
+ checkDenylistVersion(std::u16string_view currentversion,
css::uno::Sequence< OUString > const & versions);
css::uno::Reference< css::uno::XComponentContext > m_context;
diff --git a/desktop/source/deployment/manager/dp_extensionmanager.cxx b/desktop/source/deployment/manager/dp_extensionmanager.cxx
index 2f82d3d500ad..d126ccdd8412 100644
--- a/desktop/source/deployment/manager/dp_extensionmanager.cxx
+++ b/desktop/source/deployment/manager/dp_extensionmanager.cxx
@@ -244,7 +244,7 @@ ExtensionManager::getPackageManager(OUString const & repository)
void ExtensionManager::addExtensionsToMap(
id2extensions & mapExt,
uno::Sequence<Reference<css::deployment::XPackage> > const & seqExt,
- OUString const & repository)
+ std::u16string_view repository)
{
//Determine the index in the vector where these extensions are to be
//added.
@@ -1095,13 +1095,13 @@ uno::Sequence< uno::Sequence<Reference<css::deployment::XPackage> > >
uno::Sequence<Reference<css::deployment::XPackage> > userExt =
getUserRepository()->getDeployedPackages(xAbort, xCmdEnv);
- addExtensionsToMap(mapExt, userExt, "user");
+ addExtensionsToMap(mapExt, userExt, u"user");
uno::Sequence<Reference<css::deployment::XPackage> > sharedExt =
getSharedRepository()->getDeployedPackages(xAbort, xCmdEnv);
- addExtensionsToMap(mapExt, sharedExt, "shared");
+ addExtensionsToMap(mapExt, sharedExt, u"shared");
uno::Sequence<Reference<css::deployment::XPackage> > bundledExt =
getBundledRepository()->getDeployedPackages(xAbort, xCmdEnv);
- addExtensionsToMap(mapExt, bundledExt, "bundled");
+ addExtensionsToMap(mapExt, bundledExt, u"bundled");
// Create the tmp repository to trigger its clean up (deletion
// of old temporary data.)
diff --git a/desktop/source/deployment/manager/dp_extensionmanager.hxx b/desktop/source/deployment/manager/dp_extensionmanager.hxx
index 944653b72640..28c2f569f6ef 100644
--- a/desktop/source/deployment/manager/dp_extensionmanager.hxx
+++ b/desktop/source/deployment/manager/dp_extensionmanager.hxx
@@ -199,7 +199,7 @@ private:
void addExtensionsToMap(
id2extensions & mapExt,
css::uno::Sequence<css::uno::Reference<css::deployment::XPackage> > const & seqExt,
- OUString const & repository);
+ std::u16string_view repository);
/// @throws css::lang::IllegalArgumentException
/// @throws css::uno::RuntimeException
diff --git a/desktop/source/deployment/manager/dp_informationprovider.cxx b/desktop/source/deployment/manager/dp_informationprovider.cxx
index 7825ae058041..738600556dd9 100644
--- a/desktop/source/deployment/manager/dp_informationprovider.cxx
+++ b/desktop/source/deployment/manager/dp_informationprovider.cxx
@@ -80,7 +80,7 @@ private:
uno::Reference< uno::XComponentContext> mxContext;
OUString getPackageLocation( const OUString& repository,
- const OUString& _sExtensionId );
+ std::u16string_view _sExtensionId );
uno::Reference< deployment::XUpdateInformationProvider > mxUpdateInformation;
};
@@ -112,7 +112,7 @@ css::uno::Sequence< OUString > PackageInformationProvider::getSupportedServiceNa
OUString PackageInformationProvider::getPackageLocation(
const OUString & repository,
- const OUString& _rExtensionId )
+ std::u16string_view _rExtensionId )
{
OUString aLocationURL;
uno::Reference<deployment::XExtensionManager> xManager =
diff --git a/desktop/source/deployment/misc/dp_descriptioninfoset.cxx b/desktop/source/deployment/misc/dp_descriptioninfoset.cxx
index 3a55a4483e18..183434efba24 100644
--- a/desktop/source/deployment/misc/dp_descriptioninfoset.cxx
+++ b/desktop/source/deployment/misc/dp_descriptioninfoset.cxx
@@ -430,7 +430,7 @@ void DescriptionInfoset::checkDenylist() const
}
bool DescriptionInfoset::checkDenylistVersion(
- const OUString& currentversion,
+ std::u16string_view currentversion,
css::uno::Sequence< OUString > const & versions)
{
sal_Int32 nLen = versions.getLength();
diff --git a/desktop/source/deployment/misc/dp_platform.cxx b/desktop/source/deployment/misc/dp_platform.cxx
index fb72d7d2b3ff..229208916598 100644
--- a/desktop/source/deployment/misc/dp_platform.cxx
+++ b/desktop/source/deployment/misc/dp_platform.cxx
@@ -62,7 +62,7 @@ namespace
}
};
- bool checkOSandCPU(OUString const & os, OUString const & cpu)
+ bool checkOSandCPU(std::u16string_view os, std::u16string_view cpu)
{
return (os == StrOperatingSystem::get())
&& (cpu == StrCPU::get());
@@ -74,83 +74,83 @@ namespace
if (token == PLATFORM_ALL)
ret = true;
else if (token == "windows_x86")
- ret = checkOSandCPU("Windows", "x86");
+ ret = checkOSandCPU(u"Windows", u"x86");
else if (token == "windows_x86_64")
- ret = checkOSandCPU("Windows", "X86_64");
+ ret = checkOSandCPU(u"Windows", u"X86_64");
else if (token == "solaris_sparc")
- ret = checkOSandCPU("Solaris", "SPARC");
+ ret = checkOSandCPU(u"Solaris", u"SPARC");
else if (token == "solaris_sparc64")
- ret = checkOSandCPU("Solaris", "SPARC64");
+ ret = checkOSandCPU(u"Solaris", u"SPARC64");
else if (token == "solaris_x86")
- ret = checkOSandCPU("Solaris", "x86");
+ ret = checkOSandCPU(u"Solaris", u"x86");
else if (token == "aix_powerpc")
- ret = checkOSandCPU("AIX", "PowerPC");
+ ret = checkOSandCPU(u"AIX", u"PowerPC");
else if (token == "macosx_x86_64")
- ret = checkOSandCPU("MacOSX", "X86_64");
+ ret = checkOSandCPU(u"MacOSX", u"X86_64");
else if (token == "linux_x86")
- ret = checkOSandCPU("Linux", "x86");
+ ret = checkOSandCPU(u"Linux", u"x86");
else if (token == "linux_x86_64")
- ret = checkOSandCPU("Linux", "X86_64");
+ ret = checkOSandCPU(u"Linux", u"X86_64");
else if (token == "linux_sparc")
- ret = checkOSandCPU("Linux", "SPARC");
+ ret = checkOSandCPU(u"Linux", u"SPARC");
else if (token == "linux_sparc64")
- ret = checkOSandCPU("Linux", "SPARC64");
+ ret = checkOSandCPU(u"Linux", u"SPARC64");
else if (token == "linux_powerpc")
- ret = checkOSandCPU("Linux", "PowerPC");
+ ret = checkOSandCPU(u"Linux", u"PowerPC");
else if (token == "linux_powerpc64")
- ret = checkOSandCPU("Linux", "PowerPC_64");
+ ret = checkOSandCPU(u"Linux", u"PowerPC_64");
else if (token == "linux_powerpc64_le")
- ret = checkOSandCPU("Linux", "PowerPC_64_LE");
+ ret = checkOSandCPU(u"Linux", u"PowerPC_64_LE");
else if (token == "linux_arm_eabi")
- ret = checkOSandCPU("Linux", "ARM_EABI");
+ ret = checkOSandCPU(u"Linux", u"ARM_EABI");
else if (token == "linux_arm_oabi")
- ret = checkOSandCPU("Linux", "ARM_OABI");
+ ret = checkOSandCPU(u"Linux", u"ARM_OABI");
else if (token == "linux_mips_el")
- ret = checkOSandCPU("Linux", "MIPS_EL");
+ ret = checkOSandCPU(u"Linux", u"MIPS_EL");
else if (token == "linux_mips64_el")
- ret = checkOSandCPU("Linux", "MIPS64_EL");
+ ret = checkOSandCPU(u"Linux", u"MIPS64_EL");
else if (token == "linux_mips_eb")
- ret = checkOSandCPU("Linux", "MIPS_EB");
+ ret = checkOSandCPU(u"Linux", u"MIPS_EB");
else if (token == "linux_mips64_eb")
- ret = checkOSandCPU("Linux", "MIPS64_EB");
+ ret = checkOSandCPU(u"Linux", u"MIPS64_EB");
else if (token == "linux_ia64")
- ret = checkOSandCPU("Linux", "IA64");
+ ret = checkOSandCPU(u"Linux", u"IA64");
else if (token == "linux_m68k")
- ret = checkOSandCPU("Linux", "M68K");
+ ret = checkOSandCPU(u"Linux", u"M68K");
else if (token == "linux_s390")
- ret = checkOSandCPU("Linux", "S390");
+ ret = checkOSandCPU(u"Linux", u"S390");
else if (token == "linux_s390x")
- ret = checkOSandCPU("Linux", "S390x");
+ ret = checkOSandCPU(u"Linux", u"S390x");
else if (token == "linux_hppa")
- ret = checkOSandCPU("Linux", "HPPA");
+ ret = checkOSandCPU(u"Linux", u"HPPA");
else if (token == "linux_alpha")
- ret = checkOSandCPU("Linux", "ALPHA");
+ ret = checkOSandCPU(u"Linux", u"ALPHA");
else if (token == "linux_aarch64")
- ret = checkOSandCPU("Linux", "AARCH64");
+ ret = checkOSandCPU(u"Linux", u"AARCH64");
else if (token == "freebsd_x86")
- ret = checkOSandCPU("FreeBSD", "x86");
+ ret = checkOSandCPU(u"FreeBSD", u"x86");
else if (token == "freebsd_x86_64")
- ret = checkOSandCPU("FreeBSD", "X86_64");
+ ret = checkOSandCPU(u"FreeBSD", u"X86_64");
else if (token == "freebsd_powerpc")
- ret = checkOSandCPU("FreeBSD", "PowerPC");
+ ret = checkOSandCPU(u"FreeBSD", u"PowerPC");
else if (token == "freebsd_powerpc64")
- ret = checkOSandCPU("FreeBSD", "PowerPC64");
+ ret = checkOSandCPU(u"FreeBSD", u"PowerPC64");
else if (token == "kfreebsd_x86")
- ret = checkOSandCPU("kFreeBSD", "x86");
+ ret = checkOSandCPU(u"kFreeBSD", u"x86");
else if (token == "kfreebsd_x86_64")
- ret = checkOSandCPU("kFreeBSD", "X86_64");
+ ret = checkOSandCPU(u"kFreeBSD", u"X86_64");
else if (token == "netbsd_x86")
- ret = checkOSandCPU("NetBSD", "x86");
+ ret = checkOSandCPU(u"NetBSD", u"x86");
else if (token == "netbsd_x86_64")
- ret = checkOSandCPU("NetBSD", "X86_64");
+ ret = checkOSandCPU(u"NetBSD", u"X86_64");
else if (token == "openbsd_x86")
- ret = checkOSandCPU("OpenBSD", "x86");
+ ret = checkOSandCPU(u"OpenBSD", u"x86");
else if (token == "openbsd_x86_64")
- ret = checkOSandCPU("OpenBSD", "X86_64");
+ ret = checkOSandCPU(u"OpenBSD", u"X86_64");
else if (token == "dragonfly_x86")
- ret = checkOSandCPU("DragonFly", "x86");
+ ret = checkOSandCPU(u"DragonFly", u"x86");
else if (token == "dragonfly_x86_64")
- ret = checkOSandCPU("DragonFly", "X86_64");
+ ret = checkOSandCPU(u"DragonFly", u"X86_64");
else
{
OSL_FAIL("Extension Manager: The extension supports an unknown platform. "
diff --git a/desktop/source/deployment/registry/script/dp_script.cxx b/desktop/source/deployment/registry/script/dp_script.cxx
index 29b75fbfe53d..e4fd8e07fead 100644
--- a/desktop/source/deployment/registry/script/dp_script.cxx
+++ b/desktop/source/deployment/registry/script/dp_script.cxx
@@ -330,7 +330,7 @@ void
lcl_maybeRemoveScript(
bool const bExists,
OUString const& rName,
- OUString const& rScriptURL,
+ std::u16string_view rScriptURL,
Reference<css::script::XLibraryContainer3> const& xScriptLibs)
{
if (bExists && xScriptLibs.is() && xScriptLibs->hasByName(rName))
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index cf8503bf136d..06d0a1de31d2 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -880,7 +880,7 @@ void ExecuteOrientationChange()
mxUndoManager->leaveUndoContext();
}
-void setupSidebar(const OUString& sidebarDeckId = "")
+void setupSidebar(std::u16string_view sidebarDeckId = u"")
{
SfxViewShell* pViewShell = SfxViewShell::Current();
SfxViewFrame* pViewFrame = pViewShell ? pViewShell->GetViewFrame() : nullptr;
@@ -908,7 +908,7 @@ void setupSidebar(const OUString& sidebarDeckId = "")
if (currentDeckId == "ChartDeck")
switchToDefault = false;
- if (!sidebarDeckId.isEmpty())
+ if (!sidebarDeckId.empty())
{
pDockingWin->GetSidebarController()->SwitchToDeck(sidebarDeckId);
}
@@ -3954,7 +3954,7 @@ static void doc_postUnoCommand(LibreOfficeKitDocument* pThis, const char* pComma
}
else if (gImpl && aCommand == ".uno:LOKSidebarWriterPage")
{
- setupSidebar("WriterPageDeck");
+ setupSidebar(u"WriterPageDeck");
return;
}
else if (gImpl && aCommand == ".uno:SidebarShow")
diff --git a/desktop/source/migration/migration.cxx b/desktop/source/migration/migration.cxx
index ab22b4abdfe2..4197a245cd94 100644
--- a/desktop/source/migration/migration.cxx
+++ b/desktop/source/migration/migration.cxx
@@ -1016,7 +1016,7 @@ void MigrationImpl::mergeOldToNewVersion(const uno::Reference< ui::XUIConfigurat
xUIConfigurationPersistence->store();
}
-uno::Reference< ui::XUIConfigurationManager > NewVersionUIInfo::getConfigManager(const OUString& sModuleShortName) const
+uno::Reference< ui::XUIConfigurationManager > NewVersionUIInfo::getConfigManager(std::u16string_view sModuleShortName) const
{
uno::Reference< ui::XUIConfigurationManager > xCfgManager;
@@ -1030,7 +1030,7 @@ uno::Reference< ui::XUIConfigurationManager > NewVersionUIInfo::getConfigManager
return xCfgManager;
}
-uno::Reference< container::XIndexContainer > NewVersionUIInfo::getNewMenubarSettings(const OUString& sModuleShortName) const
+uno::Reference< container::XIndexContainer > NewVersionUIInfo::getNewMenubarSettings(std::u16string_view sModuleShortName) const
{
uno::Reference< container::XIndexContainer > xNewMenuSettings;
@@ -1044,7 +1044,7 @@ uno::Reference< container::XIndexContainer > NewVersionUIInfo::getNewMenubarSett
return xNewMenuSettings;
}
-uno::Reference< container::XIndexContainer > NewVersionUIInfo::getNewToolbarSettings(const OUString& sModuleShortName, const OUString& sToolbarName) const
+uno::Reference< container::XIndexContainer > NewVersionUIInfo::getNewToolbarSettings(std::u16string_view sModuleShortName, std::u16string_view sToolbarName) const
{
uno::Reference< container::XIndexContainer > xNewToolbarSettings;
diff --git a/desktop/source/migration/migration_impl.hxx b/desktop/source/migration/migration_impl.hxx
index 0a1e7d8dc61b..3b9cb09d3856 100644
--- a/desktop/source/migration/migration_impl.hxx
+++ b/desktop/source/migration/migration_impl.hxx
@@ -127,9 +127,9 @@ class NewVersionUIInfo
{
public:
- css::uno::Reference< css::ui::XUIConfigurationManager > getConfigManager(const OUString& sModuleShortName) const;
- css::uno::Reference< css::container::XIndexContainer > getNewMenubarSettings(const OUString& sModuleShortName) const;
- css::uno::Reference< css::container::XIndexContainer > getNewToolbarSettings(const OUString& sModuleShortName, const OUString& sToolbarName) const;
+ css::uno::Reference< css::ui::XUIConfigurationManager > getConfigManager(std::u16string_view sModuleShortName) const;
+ css::uno::Reference< css::container::XIndexContainer > getNewMenubarSettings(std::u16string_view sModuleShortName) const;
+ css::uno::Reference< css::container::XIndexContainer > getNewToolbarSettings(std::u16string_view sModuleShortName, std::u16string_view sToolbarName) const;
void init(const std::vector< MigrationModuleInfo >& vModulesInfo);
private:
diff --git a/desktop/source/pkgchk/unopkg/unopkg_app.cxx b/desktop/source/pkgchk/unopkg/unopkg_app.cxx
index 6c9f8ce00bae..53b2a23aec91 100644
--- a/desktop/source/pkgchk/unopkg/unopkg_app.cxx
+++ b/desktop/source/pkgchk/unopkg/unopkg_app.cxx
@@ -162,7 +162,7 @@ Reference<deployment::XPackage> findPackage(
OUString const & repository,
Reference<deployment::XExtensionManager> const & manager,
Reference<ucb::XCommandEnvironment > const & environment,
- OUString const & idOrFileName )
+ std::u16string_view idOrFileName )
{
const Sequence< Reference<deployment::XPackage> > ps(
manager->getDeployedExtensions(repository,
diff --git a/editeng/qa/unit/core-test.cxx b/editeng/qa/unit/core-test.cxx
index 0a2cb4d8f82b..35094ca07af2 100644
--- a/editeng/qa/unit/core-test.cxx
+++ b/editeng/qa/unit/core-test.cxx
@@ -228,7 +228,7 @@ void Test::testConstruction()
aEngine.SetText("I am Edit Engine.");
}
-bool includes(const uno::Sequence<OUString>& rSeq, const OUString& rVal)
+bool includes(const uno::Sequence<OUString>& rSeq, std::u16string_view rVal)
{
for (OUString const & s : rSeq)
if (s == rVal)
@@ -243,7 +243,7 @@ void Test::testUnoTextFields()
// DATE
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::DATE));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.DateTime");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.DateTime");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -251,7 +251,7 @@ void Test::testUnoTextFields()
// URL
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::URL));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.URL");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.URL");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -259,7 +259,7 @@ void Test::testUnoTextFields()
// PAGE
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::PAGE));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.PageNumber");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.PageNumber");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -267,7 +267,7 @@ void Test::testUnoTextFields()
// PAGES
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::PAGES));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.PageCount");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.PageCount");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -275,7 +275,7 @@ void Test::testUnoTextFields()
// TIME
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::TIME));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.DateTime");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.DateTime");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -283,7 +283,7 @@ void Test::testUnoTextFields()
// FILE
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::DOCINFO_TITLE));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.docinfo.Title");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.docinfo.Title");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -291,7 +291,7 @@ void Test::testUnoTextFields()
// TABLE
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::TABLE));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.SheetName");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.SheetName");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -299,7 +299,7 @@ void Test::testUnoTextFields()
// EXTENDED TIME
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::EXTENDED_TIME));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.DateTime");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.DateTime");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -307,7 +307,7 @@ void Test::testUnoTextFields()
// EXTENDED FILE
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::EXTENDED_FILE));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.FileName");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.FileName");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -315,7 +315,7 @@ void Test::testUnoTextFields()
// AUTHOR
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::AUTHOR));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.Author");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.Author");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -323,7 +323,7 @@ void Test::testUnoTextFields()
// MEASURE
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::MEASURE));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.text.textfield.Measure");
+ bool bGood = includes(aSvcs, u"com.sun.star.text.textfield.Measure");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -331,7 +331,7 @@ void Test::testUnoTextFields()
// PRESENTATION HEADER
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::PRESENTATION_HEADER));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.presentation.textfield.Header");
+ bool bGood = includes(aSvcs, u"com.sun.star.presentation.textfield.Header");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -339,7 +339,7 @@ void Test::testUnoTextFields()
// PRESENTATION FOOTER
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::PRESENTATION_FOOTER));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.presentation.textfield.Footer");
+ bool bGood = includes(aSvcs, u"com.sun.star.presentation.textfield.Footer");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
@@ -347,7 +347,7 @@ void Test::testUnoTextFields()
// PRESENTATION DATE TIME
rtl::Reference<SvxUnoTextField> xField(new SvxUnoTextField(text::textfield::Type::PRESENTATION_DATE_TIME));
uno::Sequence<OUString> aSvcs = xField->getSupportedServiceNames();
- bool bGood = includes(aSvcs, "com.sun.star.presentation.textfield.DateTime");
+ bool bGood = includes(aSvcs, u"com.sun.star.presentation.textfield.DateTime");
CPPUNIT_ASSERT_MESSAGE("expected service is not present.", bGood);
}
}
diff --git a/editeng/source/editeng/editobj.cxx b/editeng/source/editeng/editobj.cxx
index 88cef3a89c35..fb872ca870eb 100644
--- a/editeng/source/editeng/editobj.cxx
+++ b/editeng/source/editeng/editobj.cxx
@@ -304,13 +304,13 @@ void EditTextObject::SetStyleSheet(sal_Int32 nPara, const OUString& rName, const
}
bool EditTextObject::ChangeStyleSheets(
- const OUString& rOldName, SfxStyleFamily eOldFamily, const OUString& rNewName, SfxStyleFamily eNewFamily)
+ std::u16string_view rOldName, SfxStyleFamily eOldFamily, const OUString& rNewName, SfxStyleFamily eNewFamily)
{
return mpImpl->ChangeStyleSheets(rOldName, eOldFamily, rNewName, eNewFamily);
}
void EditTextObject::ChangeStyleSheetName(
- SfxStyleFamily eFamily, const OUString& rOldName, const OUString& rNewName)
+ SfxStyleFamily eFamily, std::u16string_view rOldName, const OUString& rNewName)
{
mpImpl->ChangeStyleSheetName(eFamily, rOldName, rNewName);
}
@@ -1000,7 +1000,7 @@ void EditTextObjectImpl::SetStyleSheet(sal_Int32 nPara, const OUString& rName, c
}
bool EditTextObjectImpl::ImpChangeStyleSheets(
- const OUString& rOldName, SfxStyleFamily eOldFamily,
+ std::u16string_view rOldName, SfxStyleFamily eOldFamily,
const OUString& rNewName, SfxStyleFamily eNewFamily )
{
const size_t nParagraphs = aContents.size();
@@ -1023,7 +1023,7 @@ bool EditTextObjectImpl::ImpChangeStyleSheets(
}
bool EditTextObjectImpl::ChangeStyleSheets(
- const OUString& rOldName, SfxStyleFamily eOldFamily,
+ std::u16string_view rOldName, SfxStyleFamily eOldFamily,
const OUString& rNewName, SfxStyleFamily eNewFamily)
{
bool bChanges = ImpChangeStyleSheets( rOldName, eOldFamily, rNewName, eNewFamily );
@@ -1034,7 +1034,7 @@ bool EditTextObjectImpl::ChangeStyleSheets(
}
void EditTextObjectImpl::ChangeStyleSheetName( SfxStyleFamily eFamily,
- const OUString& rOldName, const OUString& rNewName )
+ std::u16string_view rOldName, const OUString& rNewName )
{
ImpChangeStyleSheets( rOldName, eFamily, rNewName, eFamily );
}
diff --git a/editeng/source/editeng/editobj2.hxx b/editeng/source/editeng/editobj2.hxx
index 605571be46cf..45862f31303d 100644
--- a/editeng/source/editeng/editobj2.hxx
+++ b/editeng/source/editeng/editobj2.hxx
@@ -189,7 +189,7 @@ private:
bool bVertical:1;
TextRotation mnRotation;
- bool ImpChangeStyleSheets( const OUString& rOldName, SfxStyleFamily eOldFamily,
+ bool ImpChangeStyleSheets( std::u16string_view rOldName, SfxStyleFamily eOldFamily,
const OUString& rNewName, SfxStyleFamily eNewFamily );
public:
@@ -251,8 +251,8 @@ public:
void GetStyleSheet(sal_Int32 nPara, OUString& rName, SfxStyleFamily& eFamily) const;
void SetStyleSheet(sal_Int32 nPara, const OUString& rName, const SfxStyleFamily& eFamily);
bool ChangeStyleSheets(
- const OUString& rOldName, SfxStyleFamily eOldFamily, const OUString& rNewName, SfxStyleFamily eNewFamily);
- void ChangeStyleSheetName(SfxStyleFamily eFamily, const OUString& rOldName, const OUString& rNewName);
+ std::u16string_view rOldName, SfxStyleFamily eOldFamily, const OUString& rNewName, SfxStyleFamily eNewFamily);
+ void ChangeStyleSheetName(SfxStyleFamily eFamily, std::u16string_view rOldName, const OUString& rNewName);
editeng::FieldUpdater GetFieldUpdater() const { return editeng::FieldUpdater(*mpFront);}
diff --git a/editeng/source/editeng/eertfpar.cxx b/editeng/source/editeng/eertfpar.cxx
index a05c3a3b9771..2be675266f36 100644
--- a/editeng/source/editeng/eertfpar.cxx
+++ b/editeng/source/editeng/eertfpar.cxx
@@ -433,7 +433,7 @@ void EditRTFParser::SetAttrInDoc( SvxRTFItemStackType &rSet )
}
}
-SvxRTFStyleType* EditRTFParser::FindStyleSheet( const OUString& rName )
+SvxRTFStyleType* EditRTFParser::FindStyleSheet( std::u16string_view rName )
{
SvxRTFStyleTbl& rTable = GetStyleTbl();
for (auto const& iter : rTable)
diff --git a/editeng/source/editeng/eertfpar.hxx b/editeng/source/editeng/eertfpar.hxx
index 140385027b1a..582e46a68a81 100644
--- a/editeng/source/editeng/eertfpar.hxx
+++ b/editeng/source/editeng/eertfpar.hxx
@@ -47,7 +47,7 @@ private:
virtual void CalcValue() override;
void CreateStyleSheets();
SfxStyleSheet* CreateStyleSheet( SvxRTFStyleType const * pRTFStyle );
- SvxRTFStyleType* FindStyleSheet( const OUString& rName );
+ SvxRTFStyleType* FindStyleSheet( std::u16string_view rName );
void AddRTFDefaultValues( const EditPaM& rStart, const EditPaM& rEnd );
void ReadField();
void SkipGroup();
diff --git a/editeng/source/outliner/outlobj.cxx b/editeng/source/outliner/outlobj.cxx
index c8a589911079..f9d3479a8b2f 100644
--- a/editeng/source/outliner/outlobj.cxx
+++ b/editeng/source/outliner/outlobj.cxx
@@ -199,14 +199,14 @@ void OutlinerParaObject::ClearPortionInfo()
mpImpl->mpEditTextObject->ClearPortionInfo();
}
-bool OutlinerParaObject::ChangeStyleSheets(const OUString& rOldName,
+bool OutlinerParaObject::ChangeStyleSheets(std::u16string_view rOldName,
SfxStyleFamily eOldFamily, const OUString& rNewName, SfxStyleFamily eNewFamily)
{
return mpImpl->mpEditTextObject->ChangeStyleSheets(rOldName, eOldFamily, rNewName, eNewFamily);
}
void OutlinerParaObject::ChangeStyleSheetName(SfxStyleFamily eFamily,
- const OUString& rOldName, const OUString& rNewName)
+ std::u16string_view rOldName, const OUString& rNewName)
{
mpImpl->mpEditTextObject->ChangeStyleSheetName(eFamily, rOldName, rNewName);
}
diff --git a/embeddedobj/source/commonembedding/persistence.cxx b/embeddedobj/source/commonembedding/persistence.cxx
index 3e4ab0dd989f..6dda3c67830b 100644
--- a/embeddedobj/source/commonembedding/persistence.cxx
+++ b/embeddedobj/source/commonembedding/persistence.cxx
@@ -715,7 +715,7 @@ void OCommonEmbeddedObject::SwitchDocToStorage_Impl( const uno::Reference< docum
namespace {
-OUString getStringPropertyValue( const uno::Sequence<beans::PropertyValue>& rProps, const OUString& rName )
+OUString getStringPropertyValue( const uno::Sequence<beans::PropertyValue>& rProps, std::u16string_view rName )
{
OUString aStr;
@@ -775,9 +775,9 @@ void OCommonEmbeddedObject::StoreDocToStorage_Impl(
aArgs[2].Name = "DocumentBaseURL";
aArgs[2].Value <<= aBaseURL;
aArgs[3].Name = "SourceShellID";
- aArgs[3].Value <<= getStringPropertyValue(rObjArgs, "SourceShellID");
+ aArgs[3].Value <<= getStringPropertyValue(rObjArgs, u"SourceShellID");
aArgs[4].Name = "DestinationShellID";
- aArgs[4].Value <<= getStringPropertyValue(rObjArgs, "DestinationShellID");
+ aArgs[4].Value <<= getStringPropertyValue(rObjArgs, u"DestinationShellID");
xDoc->storeToStorage( xStorage, aArgs );
if ( bAttachToTheStorage )
diff --git a/extensions/source/bibliography/datman.cxx b/extensions/source/bibliography/datman.cxx
index 23f8e464f1ce..a492c839712e 100644
--- a/extensions/source/bibliography/datman.cxx
+++ b/extensions/source/bibliography/datman.cxx
@@ -231,7 +231,7 @@ public:
}
static sal_uInt16 lcl_FindLogicalName(BibConfig const * pConfig ,
- const OUString& rLogicalColumnName)
+ std::u16string_view rLogicalColumnName)
{
for(sal_uInt16 i = 0; i < COLUMN_COUNT; i++)
{
diff --git a/extensions/source/propctrlr/browserlistbox.cxx b/extensions/source/propctrlr/browserlistbox.cxx
index 6ac118cc91ba..b30f4f3eeee5 100644
--- a/extensions/source/propctrlr/browserlistbox.cxx
+++ b/extensions/source/propctrlr/browserlistbox.cxx
@@ -404,7 +404,7 @@ namespace pcr
}
}
- sal_uInt16 OBrowserListBox::GetPropertyPos( const OUString& _rEntryName ) const
+ sal_uInt16 OBrowserListBox::GetPropertyPos( std::u16string_view _rEntryName ) const
{
sal_uInt16 nPos = 0;
for (auto const& line : m_aLines)
diff --git a/extensions/source/propctrlr/browserlistbox.hxx b/extensions/source/propctrlr/browserlistbox.hxx
index aac20fc5d7c8..67cc5286f245 100644
--- a/extensions/source/propctrlr/browserlistbox.hxx
+++ b/extensions/source/propctrlr/browserlistbox.hxx
@@ -102,7 +102,7 @@ namespace pcr
void ChangeEntry( const OLineDescriptor&, ListBoxLines::size_type nPos );
void SetPropertyValue( const OUString& rEntryName, const css::uno::Any& rValue, bool _bUnknownValue );
- sal_uInt16 GetPropertyPos( const OUString& rEntryName ) const;
+ sal_uInt16 GetPropertyPos( std::u16string_view rEntryName ) const;
css::uno::Reference< css::inspection::XPropertyControl >
GetPropertyControl( const OUString& rEntryName );
void EnablePropertyControls( const OUString& _rEntryName, sal_Int16 _nControls, bool _bEnable );
diff --git a/extensions/source/propctrlr/cellbindinghelper.cxx b/extensions/source/propctrlr/cellbindinghelper.cxx
index 5207a9621fc8..4b93d048ddaa 100644
--- a/extensions/source/propctrlr/cellbindinghelper.cxx
+++ b/extensions/source/propctrlr/cellbindinghelper.cxx
@@ -65,7 +65,7 @@ namespace pcr
public:
explicit StringCompare( const OUString& _rReference ) : m_sReference( _rReference ) { }
- bool operator()( const OUString& _rCompare )
+ bool operator()( std::u16string_view _rCompare )
{
return ( _rCompare == m_sReference );
}
diff --git a/filter/source/xsltdialog/xmlfiltercommon.hxx b/filter/source/xsltdialog/xmlfiltercommon.hxx
index 9ec13206c9f4..f9fa9424c8c9 100644
--- a/filter/source/xsltdialog/xmlfiltercommon.hxx
+++ b/filter/source/xsltdialog/xmlfiltercommon.hxx
@@ -76,7 +76,7 @@ struct application_info_impl
extern std::vector< application_info_impl > const & getApplicationInfos();
extern OUString getApplicationUIName( const OUString& rServiceName );
-extern const application_info_impl* getApplicationInfo( const OUString& rServiceName );
+extern const application_info_impl* getApplicationInfo( std::u16string_view rServiceName );
OUString XsltResId(const char* pId);
#endif
diff --git a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
index 256fb9a8c551..959667db8cf0 100644
--- a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
@@ -1187,7 +1187,7 @@ std::vector< application_info_impl > const & getApplicationInfos()
return aInfos;
}
-const application_info_impl* getApplicationInfo( const OUString& rServiceName )
+const application_info_impl* getApplicationInfo( std::u16string_view rServiceName )
{
std::vector< application_info_impl > const & rInfos = getApplicationInfos();
for (auto const& info : rInfos)
diff --git a/forms/source/inc/frm_strings.hxx b/forms/source/inc/frm_strings.hxx
index 9e20636fc2ae..06d3f8cb148b 100644
--- a/forms/source/inc/frm_strings.hxx
+++ b/forms/source/inc/frm_strings.hxx
@@ -122,7 +122,7 @@ namespace frm
#define PROPERTY_TIMEMAX "TimeMax"
#define PROPERTY_LINECOUNT "LineCount"
#define PROPERTY_BOUNDCOLUMN "BoundColumn"
- #define PROPERTY_FONT "FontDescriptor"
+ #define PROPERTY_FONT u"FontDescriptor"
#define PROPERTY_FILLCOLOR "FillColor"
#define PROPERTY_LINECOLOR "LineColor"
#define PROPERTY_DROPDOWN "Dropdown"
@@ -213,7 +213,7 @@ namespace frm
#define PROPERTY_RICH_TEXT "RichText"
#define PROPERTY_ENFORCE_FORMAT "EnforceFormat"
#define PROPERTY_LINEEND_FORMAT "LineEndFormat"
- #define PROPERTY_WRITING_MODE "WritingMode"
+ #define PROPERTY_WRITING_MODE u"WritingMode"
#define PROPERTY_CONTEXT_WRITING_MODE "ContextWritingMode"
#define PROPERTY_NATIVE_LOOK "NativeWidgetLook"
diff --git a/forms/source/richtext/richtextmodel.cxx b/forms/source/richtext/richtextmodel.cxx
index cd00e8032997..ece2d36e96fe 100644
--- a/forms/source/richtext/richtextmodel.cxx
+++ b/forms/source/richtext/richtextmodel.cxx
@@ -268,7 +268,7 @@ namespace frm
namespace
{
- void lcl_removeProperty( Sequence< Property >& _rSeq, const OUString& _rPropertyName )
+ void lcl_removeProperty( Sequence< Property >& _rSeq, std::u16string_view _rPropertyName )
{
Property* pLoop = _rSeq.getArray();
Property* pEnd = _rSeq.getArray() + _rSeq.getLength();
diff --git a/forms/source/xforms/model_helper.hxx b/forms/source/xforms/model_helper.hxx
index 59056bf26e62..51b65b67127a 100644
--- a/forms/source/xforms/model_helper.hxx
+++ b/forms/source/xforms/model_helper.hxx
@@ -123,7 +123,7 @@ public:
sal_Int32 lcl_findInstance( const InstanceCollection*,
- const OUString& );
+ std::u16string_view );
// get values from Sequence<PropertyValue> describing an Instance
diff --git a/forms/source/xforms/model_ui.cxx b/forms/source/xforms/model_ui.cxx
index 0dca32ac5b91..2ce182031579 100644
--- a/forms/source/xforms/model_ui.cxx
+++ b/forms/source/xforms/model_ui.cxx
@@ -411,7 +411,7 @@ css::uno::Reference<css::xml::dom::XDocument> Model::newInstance( const OUString
static sal_Int32 lcl_findProp( const PropertyValue* pValues,
sal_Int32 nLength,
- const OUString& rName )
+ std::u16string_view rName )
{
bool bFound = false;
sal_Int32 n = 0;
@@ -423,7 +423,7 @@ static sal_Int32 lcl_findProp( const PropertyValue* pValues,
}
sal_Int32 xforms::lcl_findInstance( const InstanceCollection* pInstances,
- const OUString& rName )
+ std::u16string_view rName )
{
sal_Int32 nLength = pInstances->countItems();
sal_Int32 n = 0;
@@ -450,7 +450,7 @@ void Model::renameInstance( const OUString& sFrom,
PropertyValue* pSeq = aSeq.getArray();
sal_Int32 nLength = aSeq.getLength();
- sal_Int32 nProp = lcl_findProp( pSeq, nLength, "ID" );
+ sal_Int32 nProp = lcl_findProp( pSeq, nLength, u"ID" );
if( nProp == -1 )
{
// add name property
@@ -464,12 +464,12 @@ void Model::renameInstance( const OUString& sFrom,
pSeq[ nProp ].Value <<= sTo;
// change url
- nProp = lcl_findProp( pSeq, nLength, "URL" );
+ nProp = lcl_findProp( pSeq, nLength, u"URL" );
if(nProp != -1)
pSeq[ nProp ].Value <<= sURL;
// change urlonce
- nProp = lcl_findProp( pSeq, nLength, "URLOnce" );
+ nProp = lcl_findProp( pSeq, nLength, u"URLOnce" );
if(nProp != -1)
pSeq[ nProp ].Value <<= bURLOnce;
diff --git a/fpicker/source/office/fileview.cxx b/fpicker/source/office/fileview.cxx
index ad82be6c0463..be49c1ba37c6 100644
--- a/fpicker/source/office/fileview.cxx
+++ b/fpicker/source/office/fileview.cxx
@@ -301,13 +301,13 @@ public:
void CreateDisplayText_Impl();
void SortFolderContent_Impl();
- void EntryRemoved( const OUString& rURL );
+ void EntryRemoved( std::u16string_view rURL );
void EntryRenamed( OUString& rURL,
const OUString& rName );
const SortingData_Impl& FolderInserted( const OUString& rURL,
const OUString& rTitle );
- int GetEntryPos( const OUString& rURL );
+ int GetEntryPos( std::u16string_view rURL );
void SetViewMode( FileViewMode eMode );
@@ -1668,7 +1668,7 @@ void SvtFileView_Impl::SortFolderContent_Impl()
}
-void SvtFileView_Impl::EntryRemoved( const OUString& rURL )
+void SvtFileView_Impl::EntryRemoved( std::u16string_view rURL )
{
::osl::MutexGuard aGuard( maMutex );
@@ -1727,7 +1727,7 @@ const SortingData_Impl& SvtFileView_Impl::FolderInserted( const OUString& rURL,
return *maContent.back();
}
-int SvtFileView_Impl::GetEntryPos(const OUString& rURL)
+int SvtFileView_Impl::GetEntryPos(std::u16string_view rURL)
{
::osl::MutexGuard aGuard( maMutex );
diff --git a/framework/inc/jobs/helponstartup.hxx b/framework/inc/jobs/helponstartup.hxx
index 4c070627dbae..d22e8b98071f 100644
--- a/framework/inc/jobs/helponstartup.hxx
+++ b/framework/inc/jobs/helponstartup.hxx
@@ -137,7 +137,7 @@ class HelpOnStartup final : public ::cppu::WeakImplHelper< css::lang::XServiceIn
sal_True if the given URL is any default one ...
sal_False otherwise.
*/
- bool its_isHelpUrlADefaultOne(const OUString& sHelpURL);
+ bool its_isHelpUrlADefaultOne(std::u16string_view sHelpURL);
/** @short checks, if the help module should be shown automatically for the
currently opened office module.
diff --git a/framework/inc/targets.h b/framework/inc/targets.h
index a15db1e84851..b0bf251f0e8d 100644
--- a/framework/inc/targets.h
+++ b/framework/inc/targets.h
@@ -29,7 +29,7 @@ namespace framework{
#define SPECIALTARGET_TOP "_top" // Search at our parents for the first task (if any exist) or a frame without a parent.
#define SPECIALTARGET_BLANK "_blank" // Create a new task.
#define SPECIALTARGET_DEFAULT "_default" // Create a new task or recycle an existing one
-#define SPECIALTARGET_BEAMER "_beamer" // special frame in hierarchy
+#define SPECIALTARGET_BEAMER u"_beamer" // special frame in hierarchy
#define SPECIALTARGET_HELPTASK "OFFICE_HELP_TASK" // special name for our help task
} // namespace framework
diff --git a/framework/inc/uielement/menubarmerger.hxx b/framework/inc/uielement/menubarmerger.hxx
index 8646563b86d8..910bc58f2014 100644
--- a/framework/inc/uielement/menubarmerger.hxx
+++ b/framework/inc/uielement/menubarmerger.hxx
@@ -66,7 +66,7 @@ namespace MenuBarMerger
void RetrieveReferencePath( const OUString&,
std::vector< OUString >& aReferencePath );
ReferencePathInfo FindReferencePath( const std::vector< OUString >& aReferencePath, Menu* pMenu );
- sal_uInt16 FindMenuItem( const OUString& rCmd,
+ sal_uInt16 FindMenuItem( std::u16string_view rCmd,
Menu const * pMenu );
void GetMenuEntry( const css::uno::Sequence< css::beans::PropertyValue >& rAddonMenuEntry,
AddonMenuItem& aAddonMenu );
diff --git a/framework/inc/uielement/statusbarmerger.hxx b/framework/inc/uielement/statusbarmerger.hxx
index 497862fae127..964559de777e 100644
--- a/framework/inc/uielement/statusbarmerger.hxx
+++ b/framework/inc/uielement/statusbarmerger.hxx
@@ -55,7 +55,7 @@ namespace StatusbarMerger
AddonStatusbarItemContainer& rContainer );
sal_uInt16 FindReferencePos( StatusBar* pStatusbar,
- const OUString& rReferencePoint );
+ std::u16string_view rReferencePoint );
bool ProcessMergeOperation( StatusBar* pStatusbar,
sal_uInt16 nPos,
diff --git a/framework/inc/uielement/toolbarmerger.hxx b/framework/inc/uielement/toolbarmerger.hxx
index 03b9a1d8325e..482b730aa749 100644
--- a/framework/inc/uielement/toolbarmerger.hxx
+++ b/framework/inc/uielement/toolbarmerger.hxx
@@ -73,7 +73,7 @@ class ToolBarMerger
sal_uInt16& rWidth );
static ReferenceToolbarPathInfo FindReferencePoint( const ToolBox* pToolbar,
- const OUString& rReferencePoint );
+ std::u16string_view rReferencePoint );
static bool ProcessMergeOperation( ToolBox* pToolbar,
ToolBox::ImplToolItems::size_type nPos,
diff --git a/framework/source/classes/framecontainer.cxx b/framework/source/classes/framecontainer.cxx
index 4063ed938001..a23e3633e149 100644
--- a/framework/source/classes/framecontainer.cxx
+++ b/framework/source/classes/framecontainer.cxx
@@ -273,7 +273,7 @@ FrameContainer::searchOnAllChildrens(const OUString& sName) const
@threadsafe yes
*****************************************************************************************************************/
css::uno::Reference<css::frame::XFrame>
-FrameContainer::searchOnDirectChildrens(const OUString& sName) const
+FrameContainer::searchOnDirectChildrens(std::u16string_view sName) const
{
SolarMutexGuard g;
css::uno::Reference<css::frame::XFrame> xSearchedFrame;
diff --git a/framework/source/fwe/classes/addonmenu.cxx b/framework/source/fwe/classes/addonmenu.cxx
index c7a52f96747a..582460a0ed2c 100644
--- a/framework/source/fwe/classes/addonmenu.cxx
+++ b/framework/source/fwe/classes/addonmenu.cxx
@@ -70,7 +70,7 @@ sal_uInt16 AddonMenuManager::GetNextPos( sal_uInt16 nPos )
return ( nPos == MENU_APPEND ) ? MENU_APPEND : ( nPos+1 );
}
-static sal_uInt16 FindMenuId( Menu const * pMenu, const OUString& aCommand )
+static sal_uInt16 FindMenuId( Menu const * pMenu, std::u16string_view aCommand )
{
sal_uInt16 nPos = 0;
OUString aCmd;
@@ -93,7 +93,7 @@ void AddonMenuManager::MergeAddonHelpMenu( const Reference< XFrame >& rFrame,
return;
PopupMenu* pHelpMenu(nullptr);
- sal_uInt16 nId = FindMenuId(pMergeMenuBar, ".uno:HelpMenu");
+ sal_uInt16 nId = FindMenuId(pMergeMenuBar, u".uno:HelpMenu");
if ( nId != USHRT_MAX )
pHelpMenu = pMergeMenuBar->GetPopupMenu( nId );
@@ -107,7 +107,7 @@ void AddonMenuManager::MergeAddonHelpMenu( const Reference< XFrame >& rFrame,
AddonsOptions aOptions;
// try to detect the about menu item with the command URL
- nId = FindMenuId(pHelpMenu, ".uno:About");
+ nId = FindMenuId(pHelpMenu, u".uno:About");
sal_uInt16 nInsPos = pHelpMenu->GetItemPos( nId );
const Sequence< Sequence< PropertyValue > >& rAddonHelpMenuEntries = aOptions.GetAddonsHelpMenu();
diff --git a/framework/source/jobs/helponstartup.cxx b/framework/source/jobs/helponstartup.cxx
index b78c4ed50dad..43b94cfa8021 100644
--- a/framework/source/jobs/helponstartup.cxx
+++ b/framework/source/jobs/helponstartup.cxx
@@ -233,9 +233,9 @@ OUString HelpOnStartup::its_getCurrentHelpURL()
return sCurrentHelpURL;
}
-bool HelpOnStartup::its_isHelpUrlADefaultOne(const OUString& sHelpURL)
+bool HelpOnStartup::its_isHelpUrlADefaultOne(std::u16string_view sHelpURL)
{
- if (sHelpURL.isEmpty())
+ if (sHelpURL.empty())
return false;
// SAFE ->
diff --git a/framework/source/layoutmanager/toolbarlayoutmanager.cxx b/framework/source/layoutmanager/toolbarlayoutmanager.cxx
index 912675147086..154374ee0d56 100644
--- a/framework/source/layoutmanager/toolbarlayoutmanager.cxx
+++ b/framework/source/layoutmanager/toolbarlayoutmanager.cxx
@@ -661,7 +661,7 @@ void ToolbarLayoutManager::destroyToolbars()
}
}
-bool ToolbarLayoutManager::showToolbar( const OUString& rResourceURL )
+bool ToolbarLayoutManager::showToolbar( std::u16string_view rResourceURL )
{
UIElement aUIElement = implts_findToolbar( rResourceURL );
@@ -692,7 +692,7 @@ bool ToolbarLayoutManager::showToolbar( const OUString& rResourceURL )
return false;
}
-bool ToolbarLayoutManager::hideToolbar( const OUString& rResourceURL )
+bool ToolbarLayoutManager::hideToolbar( std::u16string_view rResourceURL )
{
UIElement aUIElement = implts_findToolbar( rResourceURL );
@@ -795,7 +795,7 @@ void ToolbarLayoutManager::setVisible( bool bVisible )
resetDockingArea();
}
-bool ToolbarLayoutManager::dockToolbar( const OUString& rResourceURL, ui::DockingArea eDockingArea, const awt::Point& aPos )
+bool ToolbarLayoutManager::dockToolbar( std::u16string_view rResourceURL, ui::DockingArea eDockingArea, const awt::Point& aPos )
{
UIElement aUIElement = implts_findToolbar( rResourceURL );
@@ -1614,7 +1614,7 @@ void ToolbarLayoutManager::implts_writeWindowStateData( const UIElement& rElemen
LOOKUP PART FOR TOOLBARS
******************************************************************************/
-UIElement& ToolbarLayoutManager::impl_findToolbar( const OUString& aName )
+UIElement& ToolbarLayoutManager::impl_findToolbar( std::u16string_view aName )
{
static UIElement aEmptyElement;
@@ -1628,7 +1628,7 @@ UIElement& ToolbarLayoutManager::impl_findToolbar( const OUString& aName )
return aEmptyElement;
}
-UIElement ToolbarLayoutManager::implts_findToolbar( const OUString& aName )
+UIElement ToolbarLayoutManager::implts_findToolbar( std::u16string_view aName )
{
SolarMutexGuard g;
return impl_findToolbar( aName );
@@ -1655,7 +1655,7 @@ UIElement ToolbarLayoutManager::implts_findToolbar( const uno::Reference< uno::X
return aToolbar;
}
-uno::Reference< awt::XWindow > ToolbarLayoutManager::implts_getXWindow( const OUString& aName )
+uno::Reference< awt::XWindow > ToolbarLayoutManager::implts_getXWindow( std::u16string_view aName )
{
uno::Reference< awt::XWindow > xWindow;
@@ -1672,7 +1672,7 @@ uno::Reference< awt::XWindow > ToolbarLayoutManager::implts_getXWindow( const OU
return xWindow;
}
-vcl::Window* ToolbarLayoutManager::implts_getWindow( const OUString& aName )
+vcl::Window* ToolbarLayoutManager::implts_getWindow( std::u16string_view aName )
{
uno::Reference< awt::XWindow > xWindow = implts_getXWindow( aName );
VclPtr<vcl::Window> pWindow = VCLUnoHelper::GetWindow( xWindow );
@@ -2138,7 +2138,7 @@ void ToolbarLayoutManager::implts_getDockingAreaElementInfoOnSingleRowCol( ui::D
ui::DockingArea DockingArea,
const SingleRowColumnWindowData& rRowColumnWindowData,
const ::Point& rMousePos,
- const OUString& rExcludeElementName )
+ std::u16string_view rExcludeElementName )
{
::tools::Rectangle aWinRect;
@@ -2186,7 +2186,7 @@ void ToolbarLayoutManager::implts_getDockingAreaElementInfoOnSingleRowCol( ui::D
ui::DockingArea eDockingArea,
sal_Int32 nRowCol,
const ::tools::Rectangle& rDockedElementRect,
- const OUString& rMovedElementName,
+ std::u16string_view rMovedElementName,
const ::tools::Rectangle& rMovedElementRect )
{
SingleRowColumnWindowData aRowColumnWindowData;
@@ -3916,7 +3916,7 @@ void SAL_CALL ToolbarLayoutManager::elementReplaced( const ui::ConfigurationEven
pParentLayouter->requestLayout();
}
-uno::Reference< ui::XUIElement > ToolbarLayoutManager::getToolbar( const OUString& aName )
+uno::Reference< ui::XUIElement > ToolbarLayoutManager::getToolbar( std::u16string_view aName )
{
return implts_findToolbar( aName ).m_xUIElement;
}
@@ -3943,7 +3943,7 @@ uno::Sequence< uno::Reference< ui::XUIElement > > ToolbarLayoutManager::getToolb
return aSeq;
}
-bool ToolbarLayoutManager::floatToolbar( const OUString& rResourceURL )
+bool ToolbarLayoutManager::floatToolbar( std::u16string_view rResourceURL )
{
UIElement aUIElement = implts_findToolbar( rResourceURL );
if ( aUIElement.m_xUIElement.is() )
@@ -3970,7 +3970,7 @@ bool ToolbarLayoutManager::floatToolbar( const OUString& rResourceURL )
return false;
}
-bool ToolbarLayoutManager::lockToolbar( const OUString& rResourceURL )
+bool ToolbarLayoutManager::lockToolbar( std::u16string_view rResourceURL )
{
UIElement aUIElement = implts_findToolbar( rResourceURL );
if ( aUIElement.m_xUIElement.is() )
@@ -3997,7 +3997,7 @@ bool ToolbarLayoutManager::lockToolbar( const OUString& rResourceURL )
return false;
}
-bool ToolbarLayoutManager::unlockToolbar( const OUString& rResourceURL )
+bool ToolbarLayoutManager::unlockToolbar( std::u16string_view rResourceURL )
{
UIElement aUIElement = implts_findToolbar( rResourceURL );
if ( aUIElement.m_xUIElement.is() )
@@ -4024,30 +4024,30 @@ bool ToolbarLayoutManager::unlockToolbar( const OUString& rResourceURL )
return false;
}
-bool ToolbarLayoutManager::isToolbarVisible( const OUString& rResourceURL )
+bool ToolbarLayoutManager::isToolbarVisible( std::u16string_view rResourceURL )
{
uno::Reference< awt::XWindow2 > xWindow2( implts_getXWindow( rResourceURL ), uno::UNO_QUERY );
return ( xWindow2.is() && xWindow2->isVisible() );
}
-bool ToolbarLayoutManager::isToolbarFloating( const OUString& rResourceURL )
+bool ToolbarLayoutManager::isToolbarFloating( std::u16string_view rResourceURL )
{
uno::Reference< awt::XDockableWindow > xDockWindow( implts_getXWindow( rResourceURL ), uno::UNO_QUERY );
return ( xDockWindow.is() && xDockWindow->isFloating() );
}
-bool ToolbarLayoutManager::isToolbarDocked( const OUString& rResourceURL )
+bool ToolbarLayoutManager::isToolbarDocked( std::u16string_view rResourceURL )
{
return !isToolbarFloating( rResourceURL );
}
-bool ToolbarLayoutManager::isToolbarLocked( const OUString& rResourceURL )
+bool ToolbarLayoutManager::isToolbarLocked( std::u16string_view rResourceURL )
{
uno::Reference< awt::XDockableWindow > xDockWindow( implts_getXWindow( rResourceURL ), uno::UNO_QUERY );
return ( xDockWindow.is() && xDockWindow->isLocked() );
}
-awt::Size ToolbarLayoutManager::getToolbarSize( const OUString& rResourceURL )
+awt::Size ToolbarLayoutManager::getToolbarSize( std::u16string_view rResourceURL )
{
vcl::Window* pWindow = implts_getWindow( rResourceURL );
@@ -4064,7 +4064,7 @@ awt::Size ToolbarLayoutManager::getToolbarSize( const OUString& rResourceURL )
return awt::Size();
}
-awt::Point ToolbarLayoutManager::getToolbarPos( const OUString& rResourceURL )
+awt::Point ToolbarLayoutManager::getToolbarPos( std::u16string_view rResourceURL )
{
awt::Point aPos;
UIElement aUIElement = implts_findToolbar( rResourceURL );
@@ -4085,7 +4085,7 @@ awt::Point ToolbarLayoutManager::getToolbarPos( const OUString& rResourceURL )
return aPos;
}
-void ToolbarLayoutManager::setToolbarSize( const OUString& rResourceURL, const awt::Size& aSize )
+void ToolbarLayoutManager::setToolbarSize( std::u16string_view rResourceURL, const awt::Size& aSize )
{
uno::Reference< awt::XWindow2 > xWindow( implts_getXWindow( rResourceURL ), uno::UNO_QUERY );
uno::Reference< awt::XDockableWindow > xDockWindow( xWindow, uno::UNO_QUERY );
@@ -4101,7 +4101,7 @@ void ToolbarLayoutManager::setToolbarSize( const OUString& rResourceURL, const a
}
}
-void ToolbarLayoutManager::setToolbarPos( const OUString& rResourceURL, const awt::Point& aPos )
+void ToolbarLayoutManager::setToolbarPos( std::u16string_view rResourceURL, const awt::Point& aPos )
{
uno::Reference< awt::XWindow > xWindow( implts_getXWindow( rResourceURL ));
uno::Reference< awt::XDockableWindow > xDockWindow( xWindow, uno::UNO_QUERY );
@@ -4117,7 +4117,7 @@ void ToolbarLayoutManager::setToolbarPos( const OUString& rResourceURL, const aw
}
}
-void ToolbarLayoutManager::setToolbarPosSize( const OUString& rResourceURL, const awt::Point& aPos, const awt::Size& aSize )
+void ToolbarLayoutManager::setToolbarPosSize( std::u16string_view rResourceURL, const awt::Point& aPos, const awt::Size& aSize )
{
setToolbarPos( rResourceURL, aPos );
setToolbarSize( rResourceURL, aSize );
diff --git a/framework/source/layoutmanager/toolbarlayoutmanager.hxx b/framework/source/layoutmanager/toolbarlayoutmanager.hxx
index 6a1df781dde3..96edbe157742 100644
--- a/framework/source/layoutmanager/toolbarlayoutmanager.hxx
+++ b/framework/source/layoutmanager/toolbarlayoutmanager.hxx
@@ -91,29 +91,29 @@ class ToolbarLayoutManager : public ::cppu::WeakImplHelper< css::awt::XDockableW
bool destroyToolbar( const OUString& rResourceURL );
// visibility
- bool showToolbar( const OUString& rResourceURL );
- bool hideToolbar( const OUString& rResourceURL );
+ bool showToolbar( std::u16string_view rResourceURL );
+ bool hideToolbar( std::u16string_view rResourceURL );
void refreshToolbarsVisibility( bool bAutomaticToolbars );
void setFloatingToolbarsVisibility( bool bVisible );
void setVisible(bool bVisible);
// docking and further functions
- bool dockToolbar( const OUString& rResourceURL, css::ui::DockingArea eDockingArea, const css::awt::Point& aPos );
+ bool dockToolbar( std::u16string_view rResourceURL, css::ui::DockingArea eDockingArea, const css::awt::Point& aPos );
bool dockAllToolbars();
- bool floatToolbar( const OUString& rResourceURL );
- bool lockToolbar( const OUString& rResourceURL );
- bool unlockToolbar( const OUString& rResourceURL );
- void setToolbarPos( const OUString& rResourceURL, const css::awt::Point& aPos );
- void setToolbarSize( const OUString& rResourceURL, const css::awt::Size& aSize );
- void setToolbarPosSize( const OUString& rResourceURL, const css::awt::Point& aPos, const css::awt::Size& aSize );
- bool isToolbarVisible( const OUString& rResourceURL );
- bool isToolbarFloating( const OUString& rResourceURL );
- bool isToolbarDocked( const OUString& rResourceURL );
- bool isToolbarLocked( const OUString& rResourceURL );
- css::awt::Point getToolbarPos( const OUString& rResourceURL );
- css::awt::Size getToolbarSize( const OUString& rResourceURL );
- css::uno::Reference< css::ui::XUIElement > getToolbar( const OUString& aName );
+ bool floatToolbar( std::u16string_view rResourceURL );
+ bool lockToolbar( std::u16string_view rResourceURL );
+ bool unlockToolbar( std::u16string_view rResourceURL );
+ void setToolbarPos( std::u16string_view rResourceURL, const css::awt::Point& aPos );
+ void setToolbarSize( std::u16string_view rResourceURL, const css::awt::Size& aSize );
+ void setToolbarPosSize( std::u16string_view rResourceURL, const css::awt::Point& aPos, const css::awt::Size& aSize );
+ bool isToolbarVisible( std::u16string_view rResourceURL );
+ bool isToolbarFloating( std::u16string_view rResourceURL );
+ bool isToolbarDocked( std::u16string_view rResourceURL );
+ bool isToolbarLocked( std::u16string_view rResourceURL );
+ css::awt::Point getToolbarPos( std::u16string_view rResourceURL );
+ css::awt::Size getToolbarSize( std::u16string_view rResourceURL );
+ css::uno::Reference< css::ui::XUIElement > getToolbar( std::u16string_view aName );
css::uno::Sequence< css::uno::Reference< css::ui::XUIElement > > getToolbars();
// child window notifications
@@ -201,11 +201,11 @@ class ToolbarLayoutManager : public ::cppu::WeakImplHelper< css::awt::XDockableW
// lookup/container methods
- UIElement implts_findToolbar( const OUString& aName );
+ UIElement implts_findToolbar( std::u16string_view aName );
UIElement implts_findToolbar( const css::uno::Reference< css::uno::XInterface >& xToolbar );
- UIElement& impl_findToolbar( const OUString& aName );
- css::uno::Reference< css::awt::XWindow > implts_getXWindow( const OUString& aName );
- vcl::Window* implts_getWindow( const OUString& aName );
+ UIElement& impl_findToolbar( std::u16string_view aName );
+ css::uno::Reference< css::awt::XWindow > implts_getXWindow( std::u16string_view aName );
+ vcl::Window* implts_getWindow( std::u16string_view aName );
bool implts_insertToolbar( const UIElement& rUIElement );
void implts_setToolbar( const UIElement& rUIElement );
::Size implts_getTopBottomDockingAreaSizes();
@@ -216,11 +216,11 @@ class ToolbarLayoutManager : public ::cppu::WeakImplHelper< css::awt::XDockableW
::tools::Rectangle implts_calcHotZoneRect( const ::tools::Rectangle& rRect, sal_Int32 nHotZoneOffset );
void implts_calcDockingPosSize( UIElement& aUIElement, DockingOperation& eDockOperation, ::tools::Rectangle& rTrackingRect, const Point& rMousePos );
DockingOperation implts_determineDockingOperation( css::ui::DockingArea DockingArea, const ::tools::Rectangle& rRowColRect, const Point& rMousePos );
- ::tools::Rectangle implts_getWindowRectFromRowColumn( css::ui::DockingArea DockingArea, const SingleRowColumnWindowData& rRowColumnWindowData, const ::Point& rMousePos, const OUString& rExcludeElementName );
+ ::tools::Rectangle implts_getWindowRectFromRowColumn( css::ui::DockingArea DockingArea, const SingleRowColumnWindowData& rRowColumnWindowData, const ::Point& rMousePos, std::u16string_view rExcludeElementName );
::tools::Rectangle implts_determineFrontDockingRect( css::ui::DockingArea eDockingArea,
sal_Int32 nRowCol,
const ::tools::Rectangle& rDockedElementRect,
- const OUString& rMovedElementName,
+ std::u16string_view rMovedElementName,
const ::tools::Rectangle& rMovedElementRect );
::tools::Rectangle implts_calcTrackingAndElementRect( css::ui::DockingArea eDockingArea,
sal_Int32 nRowCol,
diff --git a/framework/source/uiconfiguration/ImageList.cxx b/framework/source/uiconfiguration/ImageList.cxx
index 8e775aeda62d..8aef25517fb4 100644
--- a/framework/source/uiconfiguration/ImageList.cxx
+++ b/framework/source/uiconfiguration/ImageList.cxx
@@ -139,9 +139,9 @@ sal_uInt16 ImageList::GetImageCount() const
return static_cast< sal_uInt16 >( maImages.size() );
}
-sal_uInt16 ImageList::GetImagePos( const OUString& rImageName ) const
+sal_uInt16 ImageList::GetImagePos( std::u16string_view rImageName ) const
{
- if( !rImageName.isEmpty() )
+ if( !rImageName.empty() )
{
for( size_t i = 0; i < maImages.size(); i++ )
{
diff --git a/framework/source/uiconfiguration/ImageList.hxx b/framework/source/uiconfiguration/ImageList.hxx
index 946805f6cdd2..b91a9482c07b 100644
--- a/framework/source/uiconfiguration/ImageList.hxx
+++ b/framework/source/uiconfiguration/ImageList.hxx
@@ -53,7 +53,7 @@ public:
Image GetImage( const OUString& rImageName ) const;
- sal_uInt16 GetImagePos( const OUString& rImageName ) const;
+ sal_uInt16 GetImagePos( std::u16string_view rImageName ) const;
sal_uInt16 GetImageId( sal_uInt16 nPos ) const;
diff --git a/framework/source/uielement/menubarmerger.cxx b/framework/source/uielement/menubarmerger.cxx
index 532cab083b7d..1d59a7e152a6 100644
--- a/framework/source/uielement/menubarmerger.cxx
+++ b/framework/source/uielement/menubarmerger.cxx
@@ -144,7 +144,7 @@ ReferencePathInfo MenuBarMerger::FindReferencePath(
return aResult;
}
-sal_uInt16 MenuBarMerger::FindMenuItem( const OUString& rCmd, Menu const * pCurrMenu )
+sal_uInt16 MenuBarMerger::FindMenuItem( std::u16string_view rCmd, Menu const * pCurrMenu )
{
for ( sal_uInt16 i = 0; i < pCurrMenu->GetItemCount(); i++ )
{
diff --git a/framework/source/uielement/statusbarmerger.cxx b/framework/source/uielement/statusbarmerger.cxx
index 5b3868e9a0ac..c2b9e3abca47 100644
--- a/framework/source/uielement/statusbarmerger.cxx
+++ b/framework/source/uielement/statusbarmerger.cxx
@@ -173,7 +173,7 @@ bool StatusbarMerger::ConvertSeqSeqToVector(
sal_uInt16 StatusbarMerger::FindReferencePos(
StatusBar* pStatusbar,
- const OUString& rReferencePoint )
+ std::u16string_view rReferencePoint )
{
for ( sal_uInt16 nPos = 0; nPos < pStatusbar->GetItemCount(); nPos++ )
{
diff --git a/framework/source/uielement/toolbarmerger.cxx b/framework/source/uielement/toolbarmerger.cxx
index 4a56afe933d9..89847cf47135 100644
--- a/framework/source/uielement/toolbarmerger.cxx
+++ b/framework/source/uielement/toolbarmerger.cxx
@@ -224,7 +224,7 @@ void ToolBarMerger::ConvertSequenceToValues(
*/
ReferenceToolbarPathInfo ToolBarMerger::FindReferencePoint(
const ToolBox* pToolbar,
- const OUString& rReferencePoint )
+ std::u16string_view rReferencePoint )
{
ReferenceToolbarPathInfo aResult;
aResult.bResult = false;
diff --git a/i18npool/inc/collatorImpl.hxx b/i18npool/inc/collatorImpl.hxx
index d56554264ddb..14a4489a256a 100644
--- a/i18npool/inc/collatorImpl.hxx
+++ b/i18npool/inc/collatorImpl.hxx
@@ -82,7 +82,7 @@ private:
css::uno::Reference < XCollator > xC;
lookupTableItem(const css::lang::Locale& rLocale, const OUString& _algorithm, const OUString& _service,
css::uno::Reference < XCollator > const & _xC) : aLocale(rLocale), algorithm(_algorithm), service(_service), xC(_xC) {}
- bool equals(const css::lang::Locale& rLocale, const OUString& _algorithm) {
+ bool equals(const css::lang::Locale& rLocale, std::u16string_view _algorithm) {
return aLocale.Language == rLocale.Language &&
aLocale.Country == rLocale.Country &&
aLocale.Variant == rLocale.Variant &&
diff --git a/include/comphelper/mimeconfighelper.hxx b/include/comphelper/mimeconfighelper.hxx
index f7472dfd2918..5a5585f00d55 100644
--- a/include/comphelper/mimeconfighelper.hxx
+++ b/include/comphelper/mimeconfighelper.hxx
@@ -94,12 +94,12 @@ public:
const OUString& aFilterName );
css::uno::Sequence< css::beans::NamedValue > GetObjectPropsByDocumentName(
- const OUString& aDocumentName );
+ std::u16string_view aDocumentName );
// retrieving object factory from configuration
OUString GetFactoryNameByStringClassID( const OUString& aStringClassID );
OUString GetFactoryNameByClassID( const css::uno::Sequence< sal_Int8 >& aClassID );
- OUString GetFactoryNameByDocumentName( const OUString& aDocName );
+ OUString GetFactoryNameByDocumentName( std::u16string_view aDocName );
OUString GetFactoryNameByMediaType( const OUString& aMediaType );
// typedetection related
diff --git a/include/connectivity/sqliterator.hxx b/include/connectivity/sqliterator.hxx
index e4f0450ea4bb..d0f3711e6968 100644
--- a/include/connectivity/sqliterator.hxx
+++ b/include/connectivity/sqliterator.hxx
@@ -139,7 +139,7 @@ namespace connectivity
@return
*/
css::uno::Reference< css::beans::XPropertySet > findSelectColumn(
- const OUString & rColumnName );
+ std::u16string_view rColumnName );
void setSelectColumnName(::rtl::Reference<OSQLColumns> const & _rColumns,const OUString & rColumnName,const OUString & rColumnAlias, const OUString & rTableRange, bool bFkt=false, sal_Int32 _nType = css::sdbc::DataType::VARCHAR, bool bAggFkt=false);
void appendColumns(::rtl::Reference<OSQLColumns> const & _rColumns,const OUString& _rTableAlias,const OSQLTable& _rTable);
diff --git a/include/editeng/editobj.hxx b/include/editeng/editobj.hxx
index f635a93e9fbf..ea68d92df507 100644
--- a/include/editeng/editobj.hxx
+++ b/include/editeng/editobj.hxx
@@ -125,8 +125,8 @@ public:
void GetStyleSheet(sal_Int32 nPara, OUString& rName, SfxStyleFamily& eFamily) const;
void SetStyleSheet(sal_Int32 nPara, const OUString& rName, const SfxStyleFamily& eFamily);
bool ChangeStyleSheets(
- const OUString& rOldName, SfxStyleFamily eOldFamily, const OUString& rNewName, SfxStyleFamily eNewFamily);
- void ChangeStyleSheetName(SfxStyleFamily eFamily, const OUString& rOldName, const OUString& rNewName);
+ std::u16string_view rOldName, SfxStyleFamily eOldFamily, const OUString& rNewName, SfxStyleFamily eNewFamily);
+ void ChangeStyleSheetName(SfxStyleFamily eFamily, std::u16string_view rOldName, const OUString& rNewName);
editeng::FieldUpdater GetFieldUpdater() const;
diff --git a/include/editeng/outlobj.hxx b/include/editeng/outlobj.hxx
index 2d95a39c1a4f..0b961e9f30f3 100644
--- a/include/editeng/outlobj.hxx
+++ b/include/editeng/outlobj.hxx
@@ -104,9 +104,9 @@ public:
void ClearPortionInfo();
// StyleSheet support
- bool ChangeStyleSheets(const OUString& rOldName, SfxStyleFamily eOldFamily,
+ bool ChangeStyleSheets(std::u16string_view rOldName, SfxStyleFamily eOldFamily,
const OUString& rNewName, SfxStyleFamily eNewFamily);
- void ChangeStyleSheetName(SfxStyleFamily eFamily, const OUString& rOldName,
+ void ChangeStyleSheetName(SfxStyleFamily eFamily, std::u16string_view rOldName,
const OUString& rNewName);
void SetStyleSheets(sal_uInt16 nLevel, const OUString& rNewName,
const SfxStyleFamily& rNewFamily);
diff --git a/include/framework/framecontainer.hxx b/include/framework/framecontainer.hxx
index 9cd896ac7f61..1678a8670067 100644
--- a/include/framework/framecontainer.hxx
+++ b/include/framework/framecontainer.hxx
@@ -82,7 +82,7 @@ class FrameContainer final
/// special helper for Frame::findFrame()
css::uno::Reference< css::frame::XFrame > searchOnAllChildrens ( const OUString& sName ) const;
- css::uno::Reference< css::frame::XFrame > searchOnDirectChildrens( const OUString& sName ) const;
+ css::uno::Reference< css::frame::XFrame > searchOnDirectChildrens( std::u16string_view sName ) const;
}; // class FrameContainer
diff --git a/include/oox/crypto/StrongEncryptionDataSpace.hxx b/include/oox/crypto/StrongEncryptionDataSpace.hxx
index f3fcff9edaab..327308a4c6ac 100644
--- a/include/oox/crypto/StrongEncryptionDataSpace.hxx
+++ b/include/oox/crypto/StrongEncryptionDataSpace.hxx
@@ -33,7 +33,7 @@ class StrongEncryptionDataSpace final
css::uno::Reference<css::io::XInputStream>
getStream(const css::uno::Sequence<css::beans::NamedValue>& rStreams,
- const rtl::OUString sStreamName);
+ std::u16string_view sStreamName);
public:
StrongEncryptionDataSpace(const css::uno::Reference<css::uno::XComponentContext>& rxContext);
diff --git a/include/oox/export/drawingml.hxx b/include/oox/export/drawingml.hxx
index a4ef6af0530f..6c310fa0cbac 100644
--- a/include/oox/export/drawingml.hxx
+++ b/include/oox/export/drawingml.hxx
@@ -291,7 +291,7 @@ public:
const OUString& sGrabBagProperyName, int nDiagramId);
static bool IsGroupShape( const css::uno::Reference< css::drawing::XShape >& rXShape );
static bool IsDiagram(const css::uno::Reference<css::drawing::XShape>& rXShape);
- sal_Int32 getBulletMarginIndentation (const css::uno::Reference< css::beans::XPropertySet >& rXPropSet,sal_Int16 nLevel, const OUString& propName);
+ sal_Int32 getBulletMarginIndentation (const css::uno::Reference< css::beans::XPropertySet >& rXPropSet,sal_Int16 nLevel, std::u16string_view propName);
static void ResetCounters();
diff --git a/include/sfx2/StyleManager.hxx b/include/sfx2/StyleManager.hxx
index 0c747eba5831..1c19b981d64c 100644
--- a/include/sfx2/StyleManager.hxx
+++ b/include/sfx2/StyleManager.hxx
@@ -37,7 +37,7 @@ public:
virtual ~StyleManager()
{}
- SfxStyleSheetBase* Search(const OUString& rStyleName, SfxStyleFamily eFamily);
+ SfxStyleSheetBase* Search(std::u16string_view rStyleName, SfxStyleFamily eFamily);
virtual std::unique_ptr<StylePreviewRenderer> CreateStylePreviewRenderer(
OutputDevice& rOutputDev, SfxStyleSheetBase* pStyle,
diff --git a/include/sfx2/classificationhelper.hxx b/include/sfx2/classificationhelper.hxx
index f5c47064c9af..ca9ffc386b5d 100644
--- a/include/sfx2/classificationhelper.hxx
+++ b/include/sfx2/classificationhelper.hxx
@@ -74,7 +74,7 @@ public:
/// Get the currently selected category abbreviation for eType. Returns full name if no abbreviation defined.
const OUString& GetAbbreviatedBACName(const OUString& sFullName);
/// Get the currently selected category for the identifier.
- OUString GetBACNameForIdentifier(const OUString& sIdentifier);
+ OUString GetBACNameForIdentifier(std::u16string_view sIdentifier);
/// Return all possible valid abbreviated category names, based on the policy.
std::vector<OUString> GetAbbreviatedBACNames();
/// Setting this sets all the other properties, based on the policy.
diff --git a/include/sfx2/docfac.hxx b/include/sfx2/docfac.hxx
index 38716ea34f7d..f3ec43c109bb 100644
--- a/include/sfx2/docfac.hxx
+++ b/include/sfx2/docfac.hxx
@@ -59,7 +59,7 @@ public:
SfxViewFactory& GetViewFactory(sal_uInt16 i = 0) const;
/// returns the view factory whose GetAPIViewName or GetLegacyViewName delivers the requested logical name
- SfxViewFactory* GetViewFactoryByViewName( const OUString& i_rViewName ) const;
+ SfxViewFactory* GetViewFactoryByViewName( std::u16string_view i_rViewName ) const;
// Filter
std::shared_ptr<const SfxFilter> GetTemplateFilter() const;
diff --git a/include/sfx2/doctempl.hxx b/include/sfx2/doctempl.hxx
index 6ad16ceb63c2..4afe91438773 100644
--- a/include/sfx2/doctempl.hxx
+++ b/include/sfx2/doctempl.hxx
@@ -94,7 +94,7 @@ public:
bool CopyTo(sal_uInt16 nRegion, sal_uInt16 nIdx, const OUString &rName) const;
bool CopyFrom(sal_uInt16 nRegion, sal_uInt16 nIdx, OUString &rName);
- bool GetFull( const OUString& rRegion, const OUString& rName, OUString& rPath );
+ bool GetFull( std::u16string_view rRegion, const OUString& rName, OUString& rPath );
bool GetLogicNames( const OUString& rPath, OUString& rRegion, OUString& rName ) const;
/** updates the configuration where the document templates structure is stored.
diff --git a/include/sfx2/fcontnr.hxx b/include/sfx2/fcontnr.hxx
index 86f20bf111c7..68403c5755d8 100644
--- a/include/sfx2/fcontnr.hxx
+++ b/include/sfx2/fcontnr.hxx
@@ -90,7 +90,7 @@ public:
std::shared_ptr<const SfxFilter> GetFilter4EA( const OUString& rEA, SfxFilterFlags nMust = SfxFilterFlags::IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
std::shared_ptr<const SfxFilter> GetFilter4Extension( const OUString& rExt, SfxFilterFlags nMust = SfxFilterFlags::IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
std::shared_ptr<const SfxFilter> GetFilter4FilterName( const OUString& rName, SfxFilterFlags nMust = SfxFilterFlags::NONE, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
- std::shared_ptr<const SfxFilter> GetFilter4UIName( const OUString& rName, SfxFilterFlags nMust = SfxFilterFlags::NONE, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
+ std::shared_ptr<const SfxFilter> GetFilter4UIName( std::u16string_view rName, SfxFilterFlags nMust = SfxFilterFlags::NONE, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
std::shared_ptr<const SfxFilter> GetFilterForProps( const css::uno::Sequence < css::beans::NamedValue >& aSeq, SfxFilterFlags nMust = SfxFilterFlags::NONE, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
std::shared_ptr<const SfxFilter> GetAnyFilter( SfxFilterFlags nMustg=SfxFilterFlags::NONE, SfxFilterFlags nDont=SFX_FILTER_NOTINSTALLED ) const;
};
diff --git a/include/sfx2/infobar.hxx b/include/sfx2/infobar.hxx
index b2c490297d87..3b821a785c42 100644
--- a/include/sfx2/infobar.hxx
+++ b/include/sfx2/infobar.hxx
@@ -125,8 +125,8 @@ public:
VclPtr<SfxInfoBarWindow> appendInfoBar(const OUString& sId, const OUString& sPrimaryMessage,
const OUString& sSecondaryMessage, InfobarType ibType,
bool bShowCloseButton);
- VclPtr<SfxInfoBarWindow> getInfoBar(const OUString& sId);
- bool hasInfoBarWithID(const OUString& sId);
+ VclPtr<SfxInfoBarWindow> getInfoBar(std::u16string_view sId);
+ bool hasInfoBarWithID(std::u16string_view sId);
void removeInfoBar(VclPtr<SfxInfoBarWindow> const& pInfoBar);
static bool isInfobarEnabled(const OUString& sId);
diff --git a/include/sfx2/objsh.hxx b/include/sfx2/objsh.hxx
index 40ab5b46639a..c4ec915588b4 100644
--- a/include/sfx2/objsh.hxx
+++ b/include/sfx2/objsh.hxx
@@ -374,7 +374,7 @@ public:
virtual std::shared_ptr<SfxDocumentInfoDialog> CreateDocumentInfoDialog(weld::Window* pParent, const SfxItemSet& rItemSet);
- ErrCode CallBasic( const OUString& rMacro, const OUString& rBasicName,
+ ErrCode CallBasic( std::u16string_view rMacro, std::u16string_view rBasicName,
SbxArray* pArgs, SbxValue* pRet = nullptr );
ErrCode CallXScript(
diff --git a/include/sfx2/sidebar/Deck.hxx b/include/sfx2/sidebar/Deck.hxx
index 5122e915da14..69ac7f20de95 100644
--- a/include/sfx2/sidebar/Deck.hxx
+++ b/include/sfx2/sidebar/Deck.hxx
@@ -50,7 +50,7 @@ public:
void ResetPanels(const SharedPanelContainer& rPanels);
const SharedPanelContainer& GetPanels() const { return maPanels; }
- Panel* GetPanel(OUString const& panelId);
+ Panel* GetPanel(std::u16string_view panelId);
void RequestLayout();
vcl::Window* GetPanelParentWindow();
diff --git a/include/sfx2/sidebar/Panel.hxx b/include/sfx2/sidebar/Panel.hxx
index c934f3e58169..ea4a81870744 100644
--- a/include/sfx2/sidebar/Panel.hxx
+++ b/include/sfx2/sidebar/Panel.hxx
@@ -72,7 +72,7 @@ public:
css::uno::Reference<css::awt::XWindow> GetElementWindow();
void SetExpanded(const bool bIsExpanded);
bool IsExpanded() const { return mbIsExpanded; }
- bool HasIdPredicate(const OUString& rsId) const;
+ bool HasIdPredicate(std::u16string_view rsId) const;
const OUString& GetId() const { return msPanelId; }
void TriggerDeckLayouting() { maDeckLayoutTrigger(); }
diff --git a/include/sfx2/sidebar/ResourceManager.hxx b/include/sfx2/sidebar/ResourceManager.hxx
index 5f0768ac7fcc..6f20c08caba3 100644
--- a/include/sfx2/sidebar/ResourceManager.hxx
+++ b/include/sfx2/sidebar/ResourceManager.hxx
@@ -44,8 +44,8 @@ public:
ResourceManager();
~ResourceManager();
- std::shared_ptr<DeckDescriptor> GetDeckDescriptor(const OUString& rsDeckId) const;
- std::shared_ptr<PanelDescriptor> GetPanelDescriptor(const OUString& rsPanelId) const;
+ std::shared_ptr<DeckDescriptor> GetDeckDescriptor(std::u16string_view rsDeckId) const;
+ std::shared_ptr<PanelDescriptor> GetPanelDescriptor(std::u16string_view rsPanelId) const;
void UpdateModel(const css::uno::Reference<css::frame::XModel>& xModel);
@@ -83,7 +83,7 @@ public:
const PanelContextDescriptorContainer& GetMatchingPanels(
PanelContextDescriptorContainer& rPanelDescriptors,
const Context& rContext,
- const OUString& rsDeckId,
+ std::u16string_view rsDeckId,
const css::uno::Reference<css::frame::XController>& rxController);
const OUString& GetLastActiveDeck( const Context& rContext );
@@ -91,7 +91,7 @@ public:
/** Remember the expansions state per panel and context.
*/
- void StorePanelExpansionState(const OUString& rsPanelId,
+ void StorePanelExpansionState(std::u16string_view rsPanelId,
const bool bExpansionState,
const Context& rContext);
@@ -117,12 +117,12 @@ private:
static utl::OConfigurationTreeRoot GetLegacyAddonRootNode(const OUString& rsModuleName);
static void GetToolPanelNodeNames(std::vector<OUString>& rMatchingNames,
const utl::OConfigurationTreeRoot& aRoot);
- bool IsDeckEnabled(const OUString& rsDeckId,
+ bool IsDeckEnabled(std::u16string_view rsDeckId,
const Context& rContext,
const css::uno::Reference<css::frame::XController>& rxController);
- std::shared_ptr<DeckDescriptor> ImplGetDeckDescriptor(const OUString& rsDeckId) const;
- std::shared_ptr<PanelDescriptor> ImplGetPanelDescriptor(const OUString& rsPanelId) const;
+ std::shared_ptr<DeckDescriptor> ImplGetDeckDescriptor(std::u16string_view rsDeckId) const;
+ std::shared_ptr<PanelDescriptor> ImplGetPanelDescriptor(std::u16string_view rsPanelId) const;
};
} // end of namespace sfx2::sidebar
diff --git a/include/sfx2/sidebar/Sidebar.hxx b/include/sfx2/sidebar/Sidebar.hxx
index 4b104301da8d..38e3dfc010b9 100644
--- a/include/sfx2/sidebar/Sidebar.hxx
+++ b/include/sfx2/sidebar/Sidebar.hxx
@@ -34,7 +34,7 @@ namespace sfx2::sidebar {
class SFX2_DLLPUBLIC Sidebar
{
public:
- static void ToggleDeck(const OUString& rsDeckId, SfxViewFrame *pViewFrame);
+ static void ToggleDeck(std::u16string_view rsDeckId, SfxViewFrame *pViewFrame);
/** Switch to the deck that contains the specified panel and make
sure that the panel is visible (expanded and scrolled into the
@@ -43,7 +43,7 @@ public:
this function probably returns before the requested panel is visible.
*/
static void ShowPanel (
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
const css::uno::Reference<css::frame::XFrame>& rxFrame, bool bFocus = false);
/** Switch to the deck that contains the specified panel and toggle
@@ -53,11 +53,11 @@ public:
this function probably returns before the requested panel is visible.
*/
static void TogglePanel (
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
const css::uno::Reference<css::frame::XFrame>& rxFrame);
static bool IsPanelVisible(
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
const css::uno::Reference<css::frame::XFrame>& rxFrame);
};
diff --git a/include/sfx2/sidebar/SidebarController.hxx b/include/sfx2/sidebar/SidebarController.hxx
index cd4f329e99d9..490367caba91 100644
--- a/include/sfx2/sidebar/SidebarController.hxx
+++ b/include/sfx2/sidebar/SidebarController.hxx
@@ -113,7 +113,7 @@ public:
const static sal_Int32 SwitchFlag_ForceNewDeck = 0x02;
const static sal_Int32 SwitchFlag_ForceNewPanels = 0x02;
- void OpenThenSwitchToDeck(const OUString& rsDeckId);
+ void OpenThenSwitchToDeck(std::u16string_view rsDeckId);
void OpenThenToggleDeck(const OUString& rsDeckId);
/** Show only the tab bar, not the deck.
@@ -126,7 +126,7 @@ public:
/** Returns true when the given deck is the currently visible deck
*/
- bool IsDeckVisible(const OUString& rsDeckId);
+ bool IsDeckVisible(std::u16string_view rsDeckId);
bool IsDeckOpen(const sal_Int32 nIndex = -1);
@@ -140,18 +140,18 @@ public:
const Context& GetCurrentContext() const { return maCurrentContext;}
bool IsDocumentReadOnly (void) const { return mbIsDocumentReadOnly;}
- void SwitchToDeck(const OUString& rsDeckId);
+ void SwitchToDeck(std::u16string_view rsDeckId);
void SwitchToDefaultDeck();
bool WasFloatingDeckClosed() const { return mbFloatingDeckClosed; }
void SetFloatingDeckClosed(bool bWasClosed) { mbFloatingDeckClosed = bWasClosed; }
- void CreateDeck(const OUString& rDeckId);
- void CreateDeck(const OUString& rDeckId, const Context& rContext, bool bForceCreate = false);
+ void CreateDeck(std::u16string_view rDeckId);
+ void CreateDeck(std::u16string_view rDeckId, const Context& rContext, bool bForceCreate = false);
ResourceManager::DeckContextDescriptorContainer GetMatchingDecks();
- ResourceManager::PanelContextDescriptorContainer GetMatchingPanels(const OUString& rDeckId);
+ ResourceManager::PanelContextDescriptorContainer GetMatchingPanels(std::u16string_view rDeckId);
- void notifyDeckTitle(const OUString& targetDeckId);
+ void notifyDeckTitle(std::u16string_view targetDeckId);
void updateModel(const css::uno::Reference<css::frame::XModel>& xModel);
@@ -232,10 +232,10 @@ private:
const Context& rContext);
void CreatePanels(
- const OUString& rDeckId,
+ std::u16string_view rDeckId,
const Context& rContext);
VclPtr<Panel> CreatePanel (
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
vcl::Window* pParentWindow,
const bool bIsInitiallyExpanded,
const Context& rContext,
diff --git a/include/sfx2/sidebar/TabBar.hxx b/include/sfx2/sidebar/TabBar.hxx
index ebe80c7a59e7..e52202ac1bb0 100644
--- a/include/sfx2/sidebar/TabBar.hxx
+++ b/include/sfx2/sidebar/TabBar.hxx
@@ -77,7 +77,7 @@ public:
void SetDecks (
const ResourceManager::DeckContextDescriptorContainer& rDecks);
- void HighlightDeck (const OUString& rsDeckId);
+ void HighlightDeck (std::u16string_view rsDeckId);
void RemoveDeckHighlight ();
OUString const & GetDeckIdForIndex (const sal_Int32 nIndex) const;
void ToggleHideFlag (const sal_Int32 nIndex);
diff --git a/include/sfx2/templatedlg.hxx b/include/sfx2/templatedlg.hxx
index e9cf26d2cb8a..e106680c74db 100644
--- a/include/sfx2/templatedlg.hxx
+++ b/include/sfx2/templatedlg.hxx
@@ -90,7 +90,7 @@ protected:
DECL_LINK(FocusRectLocalHdl, weld::Widget&, tools::Rectangle);
DECL_LINK(FocusRectSearchHdl, weld::Widget&, tools::Rectangle);
- void OnTemplateImportCategory(const OUString& sCategory);
+ void OnTemplateImportCategory(std::u16string_view sCategory);
// static void OnTemplateLink ();
void OnTemplateOpen();
void OnTemplateExport();
diff --git a/include/sfx2/templatedlglocalview.hxx b/include/sfx2/templatedlglocalview.hxx
index a8fc57e254c3..bd51d72766c5 100644
--- a/include/sfx2/templatedlglocalview.hxx
+++ b/include/sfx2/templatedlglocalview.hxx
@@ -24,7 +24,7 @@ public:
void showRegion(TemplateContainerItem const* pItem);
- void showRegion(const OUString& rName);
+ void showRegion(std::u16string_view rName);
void createContextMenu(const bool bIsDefault);
diff --git a/include/sfx2/templatelocalview.hxx b/include/sfx2/templatelocalview.hxx
index 1ed2ee1a4e61..99ccbab5ecc1 100644
--- a/include/sfx2/templatelocalview.hxx
+++ b/include/sfx2/templatelocalview.hxx
@@ -86,17 +86,17 @@ public:
void showRegion (TemplateContainerItem const *pItem);
- void showRegion (const OUString &rName);
+ void showRegion (std::u16string_view rName);
void createContextMenu(const bool bIsDefault );
void ContextMenuSelectHdl(const OString& rIdent);
- TemplateContainerItem* getRegion(OUString const & sStr);
+ TemplateContainerItem* getRegion(std::u16string_view sStr);
sal_uInt16 getRegionId (size_t pos) const;
- sal_uInt16 getRegionId (OUString const & sRegionName) const;
+ sal_uInt16 getRegionId (std::u16string_view sRegionName) const;
OUString getRegionName(const sal_uInt16 nRegionId) const;
@@ -109,7 +109,7 @@ public:
sal_uInt16 createRegion (const OUString &rName);
- bool renameRegion(const OUString &rTitle, const OUString &rNewTitle);
+ bool renameRegion(std::u16string_view rTitle, const OUString &rNewTitle);
bool removeRegion (const sal_uInt16 nItemId);
diff --git a/include/sfx2/viewfrm.hxx b/include/sfx2/viewfrm.hxx
index aedd362f8781..4c62c51aff28 100644
--- a/include/sfx2/viewfrm.hxx
+++ b/include/sfx2/viewfrm.hxx
@@ -158,11 +158,11 @@ public:
const OUString& sSecondaryMessage,
InfobarType aInfobarType,
bool bShowCloseButton=true);
- void RemoveInfoBar(const OUString& sId);
- void UpdateInfoBar(const OUString& sId, const OUString& sPrimaryMessage,
+ void RemoveInfoBar(std::u16string_view sId);
+ void UpdateInfoBar(std::u16string_view sId, const OUString& sPrimaryMessage,
const OUString& sSecondaryMessage,
InfobarType eType);
- bool HasInfoBarWithID(const OUString& sId);
+ bool HasInfoBarWithID(std::u16string_view sId);
void AppendReadOnlyInfobar();
SAL_DLLPRIVATE void GetDocNumber_Impl();
diff --git a/include/sot/stg.hxx b/include/sot/stg.hxx
index 429ea01ecf7a..5ccb55b5ce6d 100644
--- a/include/sot/stg.hxx
+++ b/include/sot/stg.hxx
@@ -307,7 +307,7 @@ public:
virtual bool ValidateMode( StreamMode ) const override;
virtual bool Equals( const BaseStorage& rStream ) const override;
- UCBStorageElement_Impl* FindElement_Impl( const OUString& rName ) const;
+ UCBStorageElement_Impl* FindElement_Impl( std::u16string_view rName ) const;
bool CopyStorageElement_Impl( UCBStorageElement_Impl const & rElement,
BaseStorage* pDest, const OUString& rNew ) const;
BaseStorage* OpenStorage_Impl( const OUString & rEleName,
diff --git a/include/svl/style.hxx b/include/svl/style.hxx
index 85f3934db783..4cc856bd5641 100644
--- a/include/svl/style.hxx
+++ b/include/svl/style.hxx
@@ -236,7 +236,7 @@ protected:
SfxItemPool& rPool;
- void ChangeParent(const OUString& rOld, const OUString& rNew, SfxStyleFamily eFamily, bool bVirtual = true);
+ void ChangeParent(std::u16string_view rOld, const OUString& rNew, SfxStyleFamily eFamily, bool bVirtual = true);
virtual SfxStyleSheetBase* Create( const OUString&, SfxStyleFamily, SfxStyleSearchBits );
virtual SfxStyleSheetBase* Create( const SfxStyleSheetBase& );
diff --git a/include/svl/zforlist.hxx b/include/svl/zforlist.hxx
index 2639ac138998..405249b5c7ce 100644
--- a/include/svl/zforlist.hxx
+++ b/include/svl/zforlist.hxx
@@ -626,11 +626,11 @@ public:
OUString GetCalcCellReturn( sal_uInt32 nFormat ) const;
/// Check if format code string may be deleted by user
- bool IsUserDefined( const OUString& sStr, LanguageType eLnge = LANGUAGE_DONTKNOW );
+ bool IsUserDefined( std::u16string_view sStr, LanguageType eLnge = LANGUAGE_DONTKNOW );
/** Return the format index of the format code string for language/country,
or NUMBERFORMAT_ENTRY_NOT_FOUND */
- sal_uInt32 GetEntryKey( const OUString& sStr, LanguageType eLnge = LANGUAGE_DONTKNOW );
+ sal_uInt32 GetEntryKey( std::u16string_view sStr, LanguageType eLnge = LANGUAGE_DONTKNOW );
/// Return the format for a format index
const SvNumberformat* GetEntry( sal_uInt32 nKey ) const;
@@ -767,7 +767,7 @@ public:
<NULL/> if not found
else pointer to NfCurrencyEntry
*/
- static const NfCurrencyEntry* GetCurrencyEntry( const OUString& rAbbrev,
+ static const NfCurrencyEntry* GetCurrencyEntry( std::u16string_view rAbbrev,
LanguageType eLang );
/** Return a NfCurrencyEntry pointer matching the symbol
@@ -779,14 +779,14 @@ public:
@return
A matching entry, or else <NULL/>.
*/
- static const NfCurrencyEntry* GetLegacyOnlyCurrencyEntry( const OUString& rSymbol, const OUString& rAbbrev );
+ static const NfCurrencyEntry* GetLegacyOnlyCurrencyEntry( std::u16string_view rSymbol, std::u16string_view rAbbrev );
/** Set the default system currency. The combination of abbreviation and
language must match an existent element of theCurrencyTable. If not,
the SYSTEM (current locale) entry becomes the default.
This method is meant for the configuration of the default currency.
*/
- static void SetDefaultSystemCurrency( const OUString& rAbbrev, LanguageType eLang );
+ static void SetDefaultSystemCurrency( std::u16string_view rAbbrev, LanguageType eLang );
/** Get all standard formats for a specific currency, formats are
appended to the NfWSStringsDtor list.
@@ -845,7 +845,7 @@ public:
else <NULL/>.
*/
static const NfCurrencyEntry* GetCurrencyEntry( bool & bFoundBank,
- const OUString& rSymbol,
+ std::u16string_view rSymbol,
const OUString& rExtension,
LanguageType eFormatLanguage,
bool bOnlyStringLanguage = false );
@@ -974,7 +974,7 @@ private:
// Test whether format code already exists, then return index key,
// otherwise NUMBERFORMAT_ENTRY_NOT_FOUND
- SVL_DLLPRIVATE sal_uInt32 ImpIsEntry( const OUString& rString,
+ SVL_DLLPRIVATE sal_uInt32 ImpIsEntry( std::u16string_view rString,
sal_uInt32 CLOffset,
LanguageType eLnge );
@@ -1017,7 +1017,7 @@ private:
// used as a loop body inside of GetNewCurrencySymbolString() and GetCurrencyEntry()
static bool ImpLookupCurrencyEntryLoopBody(
const NfCurrencyEntry*& pFoundEntry, bool& bFoundBank, const NfCurrencyEntry* pData,
- sal_uInt16 nPos, const OUString& rSymbol );
+ sal_uInt16 nPos, std::u16string_view rSymbol );
// link to be set at <method>SvtSysLocaleOptions::SetCurrencyChangeLink()</method>
DECL_DLLPRIVATE_STATIC_LINK( SvNumberFormatter, CurrencyChangeLink, LinkParamNone*, void );
@@ -1090,7 +1090,7 @@ public:
const OUString& GetDateSep() const;
// checks for decimal separator and optional alternative
- bool IsDecimalSep( const OUString& rStr ) const;
+ bool IsDecimalSep( std::u16string_view rStr ) const;
};
#endif // INCLUDED_SVL_ZFORLIST_HXX
diff --git a/include/svtools/inettbc.hxx b/include/svtools/inettbc.hxx
index 21e4e0913dd9..1789440f6799 100644
--- a/include/svtools/inettbc.hxx
+++ b/include/svtools/inettbc.hxx
@@ -96,7 +96,7 @@ public:
void SetPlaceHolder(const OUString& sPlaceHolder) { aPlaceHolder = sPlaceHolder; }
const OUString& GetPlaceHolder() const { return aPlaceHolder; }
- bool MatchesPlaceHolder(const OUString& sToMatch) const
+ bool MatchesPlaceHolder(std::u16string_view sToMatch) const
{
return (!aPlaceHolder.isEmpty() && aPlaceHolder == sToMatch);
}
diff --git a/include/svtools/insdlg.hxx b/include/svtools/insdlg.hxx
index 58be96c4fe90..826933bd32d1 100644
--- a/include/svtools/insdlg.hxx
+++ b/include/svtools/insdlg.hxx
@@ -46,7 +46,7 @@ private:
std::vector< SvObjectServer > aObjectServerList;
public:
- const SvObjectServer * Get( const OUString & rHumanName ) const;
+ const SvObjectServer * Get( std::u16string_view rHumanName ) const;
const SvObjectServer * Get( const SvGlobalName & ) const;
void Remove( const SvGlobalName & );
void FillInsertObjects();
diff --git a/include/svtools/langtab.hxx b/include/svtools/langtab.hxx
index 6d50d05b0382..61e2f0815022 100644
--- a/include/svtools/langtab.hxx
+++ b/include/svtools/langtab.hxx
@@ -30,7 +30,7 @@ public:
static bool HasLanguageType( const LanguageType eType );
static OUString GetLanguageString( const LanguageType eType );
- static LanguageType GetLanguageType( const OUString& rStr );
+ static LanguageType GetLanguageType( std::u16string_view rStr );
static sal_uInt32 GetLanguageEntryCount();
static LanguageType GetLanguageTypeAtIndex( sal_uInt32 nIndex );
diff --git a/include/svx/ClassificationCommon.hxx b/include/svx/ClassificationCommon.hxx
index dbdb578c0755..71be4b85c91b 100644
--- a/include/svx/ClassificationCommon.hxx
+++ b/include/svx/ClassificationCommon.hxx
@@ -39,7 +39,7 @@ getProperty(css::uno::Reference<css::beans::XPropertyContainer> const& rxPropert
OUString const& rName);
SVX_DLLPUBLIC bool containsProperty(css::uno::Sequence<css::beans::Property> const& rProperties,
- OUString const& rName);
+ std::u16string_view rName);
SVX_DLLPUBLIC void
removeAllProperties(css::uno::Reference<css::beans::XPropertyContainer> const& rxPropertyContainer);
diff --git a/include/svx/ColorSets.hxx b/include/svx/ColorSets.hxx
index 88e401aa332c..3b347ede0690 100644
--- a/include/svx/ColorSets.hxx
+++ b/include/svx/ColorSets.hxx
@@ -61,7 +61,7 @@ public:
return maColorSets[nIndex];
}
- const ColorSet& getColorSet(const OUString& rName);
+ const ColorSet& getColorSet(std::u16string_view rName);
};
} // end of namespace svx
diff --git a/include/svx/ctredlin.hxx b/include/svx/ctredlin.hxx
index 4dd80bafd709..cffb5be2fbee 100644
--- a/include/svx/ctredlin.hxx
+++ b/include/svx/ctredlin.hxx
@@ -127,8 +127,8 @@ public:
void SetCalcView();
void SetWriterView();
- bool IsValidEntry(const OUString &rAuthor, const DateTime &rDateTime, const OUString &rComment);
- bool IsValidEntry(const OUString &rAuthor, const DateTime &rDateTime);
+ bool IsValidEntry(std::u16string_view rAuthor, const DateTime &rDateTime, const OUString &rComment);
+ bool IsValidEntry(std::u16string_view rAuthor, const DateTime &rDateTime);
bool IsValidComment(const OUString &rComment);
DECL_LINK(HeaderBarClick, int, void);
diff --git a/include/svx/gallery.hxx b/include/svx/gallery.hxx
index 28d99de9fa59..c4a51f4191db 100644
--- a/include/svx/gallery.hxx
+++ b/include/svx/gallery.hxx
@@ -103,32 +103,32 @@ public:
static bool FillThemeList( std::vector<OUString>& rThemeList );
// FillObjList is filling rObjList with Strings of the internal Gallery Object URL
- static bool FillObjList( const OUString& rThemeName, std::vector<OUString> &rObjList );
+ static bool FillObjList( std::u16string_view rThemeName, std::vector<OUString> &rObjList );
static bool FillObjList( const sal_uInt32 nThemeId, std::vector<OUString> &rObjList );
// FillObjTitleList is filling the rList with the title for each gallery object
static bool FillObjListTitle( const sal_uInt32 nThemeId, std::vector< OUString >& rList );
- static bool InsertURL( const OUString& rThemeName, const OUString& rURL );
+ static bool InsertURL( std::u16string_view rThemeName, const OUString& rURL );
static bool InsertURL( sal_uInt32 nThemeId, const OUString& rURL );
- static bool GetGraphicObj( const OUString& rThemeName, sal_uInt32 nPos,
+ static bool GetGraphicObj( std::u16string_view rThemeName, sal_uInt32 nPos,
Graphic* pGraphic );
static bool GetGraphicObj( sal_uInt32 nThemeId, sal_uInt32 nPos,
Graphic* pGraphic );
- static sal_uInt32 GetSdrObjCount( const OUString& rThemeName );
+ static sal_uInt32 GetSdrObjCount( std::u16string_view rThemeName );
static sal_uInt32 GetSdrObjCount( sal_uInt32 nThemeId );
- static bool GetSdrObj( const OUString& rThemeName, sal_uInt32 nSdrModelPos,
+ static bool GetSdrObj( std::u16string_view rThemeName, sal_uInt32 nSdrModelPos,
SdrModel* pModel, BitmapEx* pThumb = nullptr );
static bool GetSdrObj( sal_uInt32 nThemeId, sal_uInt32 nSdrModelPos,
SdrModel* pModel, BitmapEx* pThumb = nullptr );
- static bool BeginLocking( const OUString& rThemeName );
+ static bool BeginLocking( std::u16string_view rThemeName );
static bool BeginLocking( sal_uInt32 nThemeId );
- static bool EndLocking( const OUString& rThemeName );
+ static bool EndLocking( std::u16string_view rThemeName );
static bool EndLocking( sal_uInt32 nThemeId );
};
diff --git a/include/svx/gallery1.hxx b/include/svx/gallery1.hxx
index 69ec2728a6df..8de817484bd2 100644
--- a/include/svx/gallery1.hxx
+++ b/include/svx/gallery1.hxx
@@ -105,7 +105,7 @@ private:
SAL_DLLPRIVATE void ImplLoad( const OUString& rMultiPath );
SAL_DLLPRIVATE void ImplLoadSubDirs( const INetURLObject& rBaseURL, bool& rbIsReadOnly );
- GalleryThemeEntry* ImplGetThemeEntry( const OUString& rThemeName );
+ GalleryThemeEntry* ImplGetThemeEntry( std::u16string_view rThemeName );
SAL_DLLPRIVATE GalleryTheme* ImplGetCachedTheme( GalleryThemeEntry* pThemeEntry );
SAL_DLLPRIVATE void ImplDeleteCachedTheme( GalleryTheme const * pTheme );
@@ -123,16 +123,16 @@ public:
size_t GetThemeCount() const { return aThemeList.size(); }
SAL_DLLPRIVATE const GalleryThemeEntry* GetThemeInfo( size_t nPos )
{ return nPos < aThemeList.size() ? aThemeList[ nPos ].get() : nullptr; }
- const GalleryThemeEntry* GetThemeInfo( const OUString& rThemeName ) { return ImplGetThemeEntry( rThemeName ); }
+ const GalleryThemeEntry* GetThemeInfo( std::u16string_view rThemeName ) { return ImplGetThemeEntry( rThemeName ); }
- bool HasTheme( const OUString& rThemeName );
+ bool HasTheme( std::u16string_view rThemeName );
SAL_DLLPRIVATE OUString GetThemeName( sal_uInt32 nThemeId ) const;
bool CreateTheme( const OUString& rThemeName );
void RenameTheme( const OUString& rOldName, const OUString& rNewName );
bool RemoveTheme( const OUString& rThemeName );
- GalleryTheme* AcquireTheme( const OUString& rThemeName, SfxListener& rListener );
+ GalleryTheme* AcquireTheme( std::u16string_view rThemeName, SfxListener& rListener );
void ReleaseTheme( GalleryTheme* pTheme, SfxListener& rListener );
public:
diff --git a/include/svx/gallerybinaryengineentry.hxx b/include/svx/gallerybinaryengineentry.hxx
index b1130127765c..7637e3d8caae 100644
--- a/include/svx/gallerybinaryengineentry.hxx
+++ b/include/svx/gallerybinaryengineentry.hxx
@@ -40,7 +40,7 @@ public:
GalleryBinaryEngineEntry();
static void CreateUniqueURL(const INetURLObject& rBaseURL, INetURLObject& aURL);
- OUString ReadStrFromIni(const OUString& aKeyName);
+ OUString ReadStrFromIni(std::u16string_view aKeyName);
const INetURLObject& GetThmURL() const { return mpGalleryStorageLocations->GetThmURL(); }
const INetURLObject& GetSdgURL() const { return mpGalleryStorageLocations->GetSdgURL(); }
diff --git a/include/svx/numfmtsh.hxx b/include/svx/numfmtsh.hxx
index 9e5a0a8a18ee..1beaaf35e9b3 100644
--- a/include/svx/numfmtsh.hxx
+++ b/include/svx/numfmtsh.hxx
@@ -108,7 +108,7 @@ public:
short& rFmtSelPos,
std::vector<OUString>& rFmtEntries );
- void RemoveFormat( const OUString& rFormat,
+ void RemoveFormat( std::u16string_view rFormat,
sal_uInt16& rCatLbSelPos,
short& rFmtSelPos,
std::vector<OUString>& rFmtEntries );
@@ -127,7 +127,7 @@ public:
sal_uInt16& rLeadingZeroes,
sal_uInt16& rCatLbPos );
- sal_uInt16 GetFormatIntegerDigits( const OUString& rFormat ) const;
+ sal_uInt16 GetFormatIntegerDigits( std::u16string_view rFormat ) const;
void MakePreviewString( const OUString& rFormatStr,
OUString& rPreviewStr,
@@ -164,13 +164,13 @@ public:
sal_uInt16 FindCurrencyFormat( const OUString& rFmtString );
sal_uInt16 FindCurrencyFormat(const NfCurrencyEntry* pTmpCurrencyEntry,bool bTmpBanking);
void SetCurCurrencyEntry(NfCurrencyEntry*);
- short GetListPos4Entry( sal_uInt32 nIdx, const OUString& rFmtString );
+ short GetListPos4Entry( sal_uInt32 nIdx, std::u16string_view rFmtString );
void GetCurrencySymbols(std::vector<OUString>& rList, sal_uInt16* pPos );
sal_uInt16 FindCurrencyTableEntry( const OUString& rFmtString, bool &bTestBanking );
bool IsInTable(sal_uInt16 nPos, bool bTmpBanking,
- OUString const& rFmtString);
+ std::u16string_view rFmtString);
void SetUseStarFormat( bool bUse ) { bUseStarFormat = bUse; }
private:
diff --git a/include/svx/xtable.hxx b/include/svx/xtable.hxx
index 2c48fc7b1006..a4e192a0704a 100644
--- a/include/svx/xtable.hxx
+++ b/include/svx/xtable.hxx
@@ -180,7 +180,7 @@ public:
void Remove(tools::Long nIndex);
XPropertyEntry* Get(tools::Long nIndex) const;
- tools::Long GetIndex(const OUString& rName) const;
+ tools::Long GetIndex(std::u16string_view rName) const;
BitmapEx GetUiBitmap(tools::Long nIndex) const;
const OUString& GetName() const { return maName; }
diff --git a/include/test/xmltesttools.hxx b/include/test/xmltesttools.hxx
index f69255b9b85f..cd5f30c064fe 100644
--- a/include/test/xmltesttools.hxx
+++ b/include/test/xmltesttools.hxx
@@ -84,8 +84,8 @@ protected:
/**
* Assert that rXPath exists and it has an rNSPrefix=rNSHref namespace definition.
*/
- void assertXPathNSDef(const xmlDocUniquePtr& pXmlDoc, const OString& rXPath, const OUString& rNSPrefix,
- const OUString& rNSHref);
+ void assertXPathNSDef(const xmlDocUniquePtr& pXmlDoc, const OString& rXPath, std::u16string_view rNSPrefix,
+ std::u16string_view rNSHref);
/**
* Assert that rXPath exists, and has exactly nNumberOfChildNodes child nodes.
* Useful for checking that we do have a no child nodes to a specific node (nNumberOfChildNodes == 0).
diff --git a/include/unotools/compatibility.hxx b/include/unotools/compatibility.hxx
index 39674470e125..3c025224ea1b 100644
--- a/include/unotools/compatibility.hxx
+++ b/include/unotools/compatibility.hxx
@@ -85,7 +85,7 @@ class UNOTOOLS_DLLPUBLIC SvtCompatibilityEntry
return "_default";
}
- static Index getIndex( const OUString& rName )
+ static Index getIndex( std::u16string_view rName )
{
for ( int i = static_cast<int>(Index::Name); i < static_cast<int>(Index::INVALID); ++i )
if ( getName( Index(i) ) == rName )
diff --git a/include/unotools/lingucfg.hxx b/include/unotools/lingucfg.hxx
index b586b688fd95..20c678b96b4f 100644
--- a/include/unotools/lingucfg.hxx
+++ b/include/unotools/lingucfg.hxx
@@ -194,7 +194,7 @@ public:
css::uno::Sequence< OUString > GetDisabledDictionaries() const;
- std::vector< SvtLinguConfigDictionaryEntry > GetActiveDictionariesByFormat( const OUString &rFormatName ) const;
+ std::vector< SvtLinguConfigDictionaryEntry > GetActiveDictionariesByFormat( std::u16string_view rFormatName ) const;
// functions returning file URLs to the respective images (if found) and empty string otherwise
OUString GetSpellAndGrammarContextSuggestionImage( const OUString &rServiceImplName ) const;
diff --git a/include/vcl/toolkit/combobox.hxx b/include/vcl/toolkit/combobox.hxx
index dc21395d7f68..f31d0a83152e 100644
--- a/include/vcl/toolkit/combobox.hxx
+++ b/include/vcl/toolkit/combobox.hxx
@@ -91,7 +91,7 @@ public:
void RemoveEntryAt(sal_Int32 nPos);
void Clear();
- sal_Int32 GetEntryPos( const OUString& rStr ) const;
+ sal_Int32 GetEntryPos( std::u16string_view rStr ) const;
Image GetEntryImage( sal_Int32 nPos ) const;
OUString GetEntry( sal_Int32 nPos ) const;
sal_Int32 GetEntryCount() const;
diff --git a/include/vcl/toolkit/lstbox.hxx b/include/vcl/toolkit/lstbox.hxx
index fe67d90569cf..56e76f42ad82 100644
--- a/include/vcl/toolkit/lstbox.hxx
+++ b/include/vcl/toolkit/lstbox.hxx
@@ -156,12 +156,12 @@ public:
void Clear();
- sal_Int32 GetEntryPos( const OUString& rStr ) const;
+ sal_Int32 GetEntryPos( std::u16string_view rStr ) const;
Image GetEntryImage( sal_Int32 nPos ) const;
OUString GetEntry( sal_Int32 nPos ) const;
sal_Int32 GetEntryCount() const;
- void SelectEntry( const OUString& rStr, bool bSelect = true );
+ void SelectEntry( std::u16string_view rStr, bool bSelect = true );
void SelectEntryPos( sal_Int32 nPos, bool bSelect = true );
void SelectEntriesPos( const std::vector<sal_Int32>& rPositions, bool bSelect = true );
diff --git a/include/xmloff/odffields.hxx b/include/xmloff/odffields.hxx
index e1014e8310e3..890c618cc604 100644
--- a/include/xmloff/odffields.hxx
+++ b/include/xmloff/odffields.hxx
@@ -37,7 +37,7 @@
#define ODF_FORMDATE_DATEFORMAT "DateField_DateFormat" // e.g. "MM.DD.YY"
#define ODF_FORMDATE_DATEFORMAT_LANGUAGE "DateField_DateFormat_Language" // e.g. "en-US", "hu-HU"
#define ODF_FORMDATE_CURRENTDATE "DateField_CurrentDate" // date string in a specific format
-#define ODF_FORMDATE_CURRENTDATE_FORMAT "YYYY-MM-DD" // Coming from MSO
+#define ODF_FORMDATE_CURRENTDATE_FORMAT u"YYYY-MM-DD" // Coming from MSO
#define ODF_FORMDATE_CURRENTDATE_LANGUAGE LANGUAGE_ENGLISH_US
#define ODF_TOC "vnd.oasis.opendocument.field.TOC"
diff --git a/include/xmloff/table/XMLTableExport.hxx b/include/xmloff/table/XMLTableExport.hxx
index f49a4236e2d0..dfdb08d7315d 100644
--- a/include/xmloff/table/XMLTableExport.hxx
+++ b/include/xmloff/table/XMLTableExport.hxx
@@ -88,7 +88,7 @@ private:
SAL_DLLPRIVATE void ImpExportText( const css::uno::Reference < css::table::XCell >& xCell );
- void ExportCell( const css::uno::Reference < css::table::XCell >& xCell, const std::shared_ptr< XMLTableInfo >& pTableInfo, const OUString& sDefaultCellStyle );
+ void ExportCell( const css::uno::Reference < css::table::XCell >& xCell, const std::shared_ptr< XMLTableInfo >& pTableInfo, std::u16string_view sDefaultCellStyle );
void ExportTableColumns( const css::uno::Reference < css::container::XIndexAccess >& xtableColumns, const std::shared_ptr< XMLTableInfo >& pTableInfo );
};
diff --git a/include/xmloff/xmlprmap.hxx b/include/xmloff/xmlprmap.hxx
index f38223cc13b8..2a4b93e8495e 100644
--- a/include/xmloff/xmlprmap.hxx
+++ b/include/xmloff/xmlprmap.hxx
@@ -90,7 +90,7 @@ public:
/** Returns the index of an entry with the given XML-name and namespace
If there is no matching entry the method returns -1 */
sal_Int32 GetEntryIndex(
- sal_uInt16 nNamespace, const OUString& rStrName, sal_uInt32 nPropType,
+ sal_uInt16 nNamespace, std::u16string_view rStrName, sal_uInt32 nPropType,
sal_Int32 nStartAt = -1 ) const;
/** Returns the index of an entry with the given XML-name and namespace
@@ -114,7 +114,7 @@ public:
/** searches for an entry that matches the given api name, namespace and local name or -1 if nothing found */
sal_Int32 FindEntryIndex(
- const char* sApiName, sal_uInt16 nNameSpace, const OUString& sXMLName ) const;
+ const char* sApiName, sal_uInt16 nNameSpace, std::u16string_view sXMLName ) const;
/** searches for an entry that matches the given ContextId or gives -1 if nothing found */
sal_Int32 FindEntryIndex( const sal_Int16 nContextId ) const;
diff --git a/linguistic/source/convdic.cxx b/linguistic/source/convdic.cxx
index 4803dd3ad74d..573e2eb04517 100644
--- a/linguistic/source/convdic.cxx
+++ b/linguistic/source/convdic.cxx
@@ -244,7 +244,7 @@ void ConvDic::Save()
}
-ConvMap::iterator ConvDic::GetEntry( ConvMap &rMap, const OUString &rFirstText, const OUString &rSecondText )
+ConvMap::iterator ConvDic::GetEntry( ConvMap &rMap, const OUString &rFirstText, std::u16string_view rSecondText )
{
pair< ConvMap::iterator, ConvMap::iterator > aRange =
rMap.equal_range( rFirstText );
@@ -260,7 +260,7 @@ ConvMap::iterator ConvDic::GetEntry( ConvMap &rMap, const OUString &rFirstText,
}
-bool ConvDic::HasEntry( const OUString &rLeftText, const OUString &rRightText )
+bool ConvDic::HasEntry( const OUString &rLeftText, std::u16string_view rRightText )
{
if (bNeedEntries)
Load();
diff --git a/linguistic/source/convdic.hxx b/linguistic/source/convdic.hxx
index ed26c81f244b..df0cd955a4c9 100644
--- a/linguistic/source/convdic.hxx
+++ b/linguistic/source/convdic.hxx
@@ -77,7 +77,7 @@ protected:
ConvDic(const ConvDic &);
ConvDic & operator = (const ConvDic &);
- static ConvMap::iterator GetEntry( ConvMap &rMap, const OUString &rFirstText, const OUString &rSecondText );
+ static ConvMap::iterator GetEntry( ConvMap &rMap, const OUString &rFirstText, std::u16string_view rSecondText );
void Load();
void Save();
@@ -116,7 +116,7 @@ public:
virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) override;
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( ) override;
- bool HasEntry( const OUString &rLeftText, const OUString &rRightText );
+ bool HasEntry( const OUString &rLeftText, std::u16string_view rRightText );
void AddEntry( const OUString &rLeftText, const OUString &rRightText );
void RemoveEntry( const OUString &rLeftText, const OUString &rRightText );
};
diff --git a/linguistic/source/convdiclist.cxx b/linguistic/source/convdiclist.cxx
index fd291e2130f2..afea6469ed38 100644
--- a/linguistic/source/convdiclist.cxx
+++ b/linguistic/source/convdiclist.cxx
@@ -74,7 +74,7 @@ class ConvDicNameContainer :
{
std::vector< uno::Reference< XConversionDictionary > > aConvDics;
- sal_Int32 GetIndexByName_Impl( const OUString& rName );
+ sal_Int32 GetIndexByName_Impl( std::u16string_view rName );
public:
ConvDicNameContainer();
@@ -105,7 +105,7 @@ public:
void FlushDics() const;
sal_Int32 GetCount() const { return aConvDics.size(); }
- uno::Reference< XConversionDictionary > GetByName( const OUString& rName );
+ uno::Reference< XConversionDictionary > GetByName( std::u16string_view rName );
const uno::Reference< XConversionDictionary >& GetByIndex( sal_Int32 nIdx )
{
@@ -138,7 +138,7 @@ void ConvDicNameContainer::FlushDics() const
}
sal_Int32 ConvDicNameContainer::GetIndexByName_Impl(
- const OUString& rName )
+ std::u16string_view rName )
{
sal_Int32 nRes = -1;
sal_Int32 nLen = aConvDics.size();
@@ -151,7 +151,7 @@ sal_Int32 ConvDicNameContainer::GetIndexByName_Impl(
}
uno::Reference< XConversionDictionary > ConvDicNameContainer::GetByName(
- const OUString& rName )
+ std::u16string_view rName )
{
uno::Reference< XConversionDictionary > xRes;
sal_Int32 nIdx = GetIndexByName_Impl( rName );
@@ -370,9 +370,9 @@ ConvDicNameContainer & ConvDicList::GetNameContainer()
// since there is no UI to active/deactivate the dictionaries
// for chinese text conversion they should be activated by default
uno::Reference< XConversionDictionary > xS2TDic =
- mxNameContainer->GetByName( "ChineseS2T" );
+ mxNameContainer->GetByName( u"ChineseS2T" );
uno::Reference< XConversionDictionary > xT2SDic =
- mxNameContainer->GetByName( "ChineseT2S" );
+ mxNameContainer->GetByName( u"ChineseT2S" );
if (xS2TDic.is())
xS2TDic->setActive( true );
if (xT2SDic.is())
diff --git a/linguistic/source/spelldsp.cxx b/linguistic/source/spelldsp.cxx
index fb58843a0efb..dbece3def648 100644
--- a/linguistic/source/spelldsp.cxx
+++ b/linguistic/source/spelldsp.cxx
@@ -59,7 +59,7 @@ class ProposalList
{
std::vector< OUString > aVec;
- bool HasEntry( const OUString &rText ) const;
+ bool HasEntry( std::u16string_view rText ) const;
public:
ProposalList() {}
@@ -76,7 +76,7 @@ public:
}
-bool ProposalList::HasEntry( const OUString &rText ) const
+bool ProposalList::HasEntry( std::u16string_view rText ) const
{
bool bFound = false;
size_t nCnt = aVec.size();
diff --git a/linguistic/source/spelldta.cxx b/linguistic/source/spelldta.cxx
index 7588cb949eda..7ae3d3d7f42d 100644
--- a/linguistic/source/spelldta.cxx
+++ b/linguistic/source/spelldta.cxx
@@ -45,7 +45,7 @@ namespace linguistic
static bool SeqHasEntry(
const std::vector< OUString > &rSeq,
- const OUString &rTxt)
+ std::u16string_view rTxt)
{
bool bRes = false;
sal_Int32 nLen = rSeq.size();
diff --git a/lotuswordpro/inc/lwpfoundry.hxx b/lotuswordpro/inc/lwpfoundry.hxx
index fc9989107639..6f5776d3c286 100644
--- a/lotuswordpro/inc/lwpfoundry.hxx
+++ b/lotuswordpro/inc/lwpfoundry.hxx
@@ -267,7 +267,7 @@ public:
LwpSection* EnumSections(LwpSection* pSection);
LwpBulletStyleMgr* GetBulletStyleMgr() { return m_xBulletStyleMgr.get(); }
- LwpObjectID* FindParaStyleByName(const OUString& name);
+ LwpObjectID* FindParaStyleByName(std::u16string_view name);
OUString FindActuralStyleName(const OUString& name);
};
diff --git a/lotuswordpro/inc/xfilter/xfstylecont.hxx b/lotuswordpro/inc/xfilter/xfstylecont.hxx
index 601fbd252a61..f2617eefa3c8 100644
--- a/lotuswordpro/inc/xfilter/xfstylecont.hxx
+++ b/lotuswordpro/inc/xfilter/xfstylecont.hxx
@@ -109,7 +109,7 @@ public:
/**
* @descr get style by name.
*/
- IXFStyle* FindStyle(const OUString& name);
+ IXFStyle* FindStyle(std::u16string_view name);
/**
* @descr clear container.
diff --git a/lotuswordpro/inc/xfilter/xfstylemanager.hxx b/lotuswordpro/inc/xfilter/xfstylemanager.hxx
index d2de7b5759b9..c6a96f560823 100644
--- a/lotuswordpro/inc/xfilter/xfstylemanager.hxx
+++ b/lotuswordpro/inc/xfilter/xfstylemanager.hxx
@@ -95,11 +95,11 @@ public:
IXFStyleRet AddStyle(std::unique_ptr<IXFStyle> pStyle);
- IXFStyle* FindStyle(const OUString& name);
+ IXFStyle* FindStyle(std::u16string_view name);
- XFParaStyle* FindParaStyle(const OUString& name);
+ XFParaStyle* FindParaStyle(std::u16string_view name);
- XFTextStyle* FindTextStyle(const OUString& name);
+ XFTextStyle* FindTextStyle(std::u16string_view name);
void SetLineNumberConfig(XFLineNumberConfig *pLNConfig);
diff --git a/lotuswordpro/source/filter/lwpdoc.cxx b/lotuswordpro/source/filter/lwpdoc.cxx
index c09d670b150c..bb9c8810e899 100644
--- a/lotuswordpro/source/filter/lwpdoc.cxx
+++ b/lotuswordpro/source/filter/lwpdoc.cxx
@@ -785,7 +785,7 @@ void LwpDocument::XFConvertFrameInPage(XFContentContainer* pCont)
void LwpDocument::ChangeStyleName()
{
XFStyleManager* pXFStyleManager = LwpGlobalMgr::GetInstance()->GetXFStyleManager();
- XFTextStyle* pStyle = dynamic_cast<XFTextStyle*>(pXFStyleManager->FindStyle("ClickHere"));
+ XFTextStyle* pStyle = dynamic_cast<XFTextStyle*>(pXFStyleManager->FindStyle(u"ClickHere"));
if (pStyle)
{
pStyle->SetStyleName("Placeholder");
diff --git a/lotuswordpro/source/filter/lwpfoundry.cxx b/lotuswordpro/source/filter/lwpfoundry.cxx
index d18dcd3903b6..5c3d12524fdb 100644
--- a/lotuswordpro/source/filter/lwpfoundry.cxx
+++ b/lotuswordpro/source/filter/lwpfoundry.cxx
@@ -264,7 +264,7 @@ LwpObjectID * LwpFoundry::GetDefaultTextStyle()
* @descr: Get paragraph style object id according to its style name
*
*/
-LwpObjectID * LwpFoundry::FindParaStyleByName(const OUString& name)
+LwpObjectID * LwpFoundry::FindParaStyleByName(std::u16string_view name)
{
LwpDLVListHeadHolder* pParaStyleHolder = dynamic_cast<LwpDLVListHeadHolder*>(GetTextStyleHead().obj().get());
if(pParaStyleHolder)
diff --git a/lotuswordpro/source/filter/lwpfribmark.cxx b/lotuswordpro/source/filter/lwpfribmark.cxx
index 093d462fb29a..eba748865d10 100644
--- a/lotuswordpro/source/filter/lwpfribmark.cxx
+++ b/lotuswordpro/source/filter/lwpfribmark.cxx
@@ -104,7 +104,7 @@ void LwpFribCHBlock::XFConvert(XFContentContainer* pXFPara, LwpStory* pStory)
if (pHyperlink)
{
pHyperlink->SetHyperlinkFlag(true);
- pHyperlink->SetHyperlink(pMarker->GetNamedProperty("URL"));
+ pHyperlink->SetHyperlink(pMarker->GetNamedProperty(u"URL"));
}
}
else if (type == MARKER_END) //or none
diff --git a/lotuswordpro/source/filter/lwpmarker.cxx b/lotuswordpro/source/filter/lwpmarker.cxx
index 7433042849b2..653121532a09 100644
--- a/lotuswordpro/source/filter/lwpmarker.cxx
+++ b/lotuswordpro/source/filter/lwpmarker.cxx
@@ -87,7 +87,7 @@ void LwpMarker::Read()
m_pObjStrm->SkipExtra();
}
-OUString LwpMarker::GetNamedProperty(const OUString& name)
+OUString LwpMarker::GetNamedProperty(std::u16string_view name)
{
LwpPropList* pProp = GetPropList();
if (pProp)
diff --git a/lotuswordpro/source/filter/lwpmarker.hxx b/lotuswordpro/source/filter/lwpmarker.hxx
index 2a94aaaa2f76..8375d07327d4 100644
--- a/lotuswordpro/source/filter/lwpmarker.hxx
+++ b/lotuswordpro/source/filter/lwpmarker.hxx
@@ -70,7 +70,7 @@ class LwpMarker : public LwpDLNFPVList
public:
LwpMarker(LwpObjectHeader const &objHdr, LwpSvStream *pStrm);
void Read() override;
- OUString GetNamedProperty(const OUString& name);
+ OUString GetNamedProperty(std::u16string_view name);
protected:
enum{
MARKER_START=1,
diff --git a/lotuswordpro/source/filter/lwpproplist.cxx b/lotuswordpro/source/filter/lwpproplist.cxx
index 9e4f6df2877f..e0e159cad43b 100644
--- a/lotuswordpro/source/filter/lwpproplist.cxx
+++ b/lotuswordpro/source/filter/lwpproplist.cxx
@@ -78,12 +78,12 @@ void LwpPropListElement::Read()
m_pObjStrm->SkipExtra();
}
-bool LwpPropListElement::IsNamed(const OUString& name)
+bool LwpPropListElement::IsNamed(std::u16string_view name)
{
return name == m_Name.str();
}
-OUString LwpPropList::GetNamedProperty(const OUString& name)
+OUString LwpPropList::GetNamedProperty(std::u16string_view name)
{
LwpPropListElement* pProp = FindPropByName(name);
if (pProp)
@@ -93,7 +93,7 @@ OUString LwpPropList::GetNamedProperty(const OUString& name)
return OUString();
}
-LwpPropListElement* LwpPropList::FindPropByName(const OUString& name)
+LwpPropListElement* LwpPropList::FindPropByName(std::u16string_view name)
{
LwpPropListElement* pElement = GetFirst();
diff --git a/lotuswordpro/source/filter/lwpproplist.hxx b/lotuswordpro/source/filter/lwpproplist.hxx
index f0ae21451df9..3600b8417c13 100644
--- a/lotuswordpro/source/filter/lwpproplist.hxx
+++ b/lotuswordpro/source/filter/lwpproplist.hxx
@@ -69,7 +69,7 @@ class LwpPropListElement : public LwpDLVList
public:
LwpPropListElement(LwpObjectHeader const& objHdr, LwpSvStream* pStrm);
void Read() override;
- bool IsNamed(const OUString& name);
+ bool IsNamed(std::u16string_view name);
LwpPropListElement* GetNext();
const LwpAtomHolder& GetValue() const { return m_Value; }
const LwpAtomHolder& GetName() const { return m_Name; }
@@ -87,11 +87,11 @@ public:
LwpPropList() {}
using LwpDLVListHead::Read;
LwpPropListElement* GetFirst();
- OUString GetNamedProperty(const OUString& name);
+ OUString GetNamedProperty(std::u16string_view name);
OUString EnumNamedProperty(OUString& name, OUString& value);
private:
- LwpPropListElement* FindPropByName(const OUString& name);
+ LwpPropListElement* FindPropByName(std::u16string_view name);
};
#endif
diff --git a/lotuswordpro/source/filter/xfilter/xfstylecont.cxx b/lotuswordpro/source/filter/xfilter/xfstylecont.cxx
index 16fe9725cd72..c9bcfc3c8c97 100644
--- a/lotuswordpro/source/filter/xfilter/xfstylecont.cxx
+++ b/lotuswordpro/source/filter/xfilter/xfstylecont.cxx
@@ -137,7 +137,7 @@ IXFStyle* XFStyleContainer::FindSameStyle(IXFStyle *pStyle)
return nullptr;
}
-IXFStyle* XFStyleContainer::FindStyle(const OUString& name)
+IXFStyle* XFStyleContainer::FindStyle(std::u16string_view name)
{
for (auto const& style : m_aStyles)
{
diff --git a/lotuswordpro/source/filter/xfilter/xfstylemanager.cxx b/lotuswordpro/source/filter/xfilter/xfstylemanager.cxx
index 34ddb7d09363..7cf97f8a41d5 100644
--- a/lotuswordpro/source/filter/xfilter/xfstylemanager.cxx
+++ b/lotuswordpro/source/filter/xfilter/xfstylemanager.cxx
@@ -219,7 +219,7 @@ IXFStyleRet XFStyleManager::AddStyle(std::unique_ptr<IXFStyle> pStyle)
return aRet;
}
-IXFStyle* XFStyleManager::FindStyle(const OUString& name)
+IXFStyle* XFStyleManager::FindStyle(std::u16string_view name)
{
IXFStyle *pStyle = FindParaStyle(name);
if( pStyle )
@@ -272,7 +272,7 @@ IXFStyle* XFStyleManager::FindStyle(const OUString& name)
return nullptr;
}
-XFParaStyle* XFStyleManager::FindParaStyle(const OUString& name)
+XFParaStyle* XFStyleManager::FindParaStyle(std::u16string_view name)
{
IXFStyle *pStyle = s_aParaStyles.FindStyle(name);
if( pStyle )
@@ -281,7 +281,7 @@ XFParaStyle* XFStyleManager::FindParaStyle(const OUString& name)
return static_cast<XFParaStyle*>(s_aStdParaStyles.FindStyle(name));
}
-XFTextStyle* XFStyleManager::FindTextStyle(const OUString& name)
+XFTextStyle* XFStyleManager::FindTextStyle(std::u16string_view name)
{
IXFStyle *pStyle = s_aTextStyles.FindStyle(name);
if( pStyle )
diff --git a/oox/inc/drawingml/customshapeproperties.hxx b/oox/inc/drawingml/customshapeproperties.hxx
index a8f4c19b051b..55bf387282dc 100644
--- a/oox/inc/drawingml/customshapeproperties.hxx
+++ b/oox/inc/drawingml/customshapeproperties.hxx
@@ -120,7 +120,7 @@ public:
void setTextCameraZRotateAngle( sal_Int32 nAngle ) { mnTextCameraZRotateAngle = nAngle; };
static sal_Int32 SetCustomShapeGuideValue( std::vector< CustomShapeGuide >& rGuideList, const CustomShapeGuide& rGuide );
- static sal_Int32 GetCustomShapeGuideValue( const std::vector< CustomShapeGuide >& rGuideList, const OUString& rFormulaName );
+ static sal_Int32 GetCustomShapeGuideValue( const std::vector< CustomShapeGuide >& rGuideList, std::u16string_view rFormulaName );
sal_Int32 getArcNum() { return mnArcNum++; }
diff --git a/oox/source/crypto/StrongEncryptionDataSpace.cxx b/oox/source/crypto/StrongEncryptionDataSpace.cxx
index 9fd1778aa831..fd1b823b8870 100644
--- a/oox/source/crypto/StrongEncryptionDataSpace.cxx
+++ b/oox/source/crypto/StrongEncryptionDataSpace.cxx
@@ -65,7 +65,7 @@ sal_Bool StrongEncryptionDataSpace::decrypt(const Reference<XInputStream>& rxInp
}
Reference<XInputStream> StrongEncryptionDataSpace::getStream(const Sequence<NamedValue>& rStreams,
- const OUString sStreamName)
+ std::u16string_view sStreamName)
{
for (const auto& aStream : rStreams)
{
@@ -84,7 +84,7 @@ Reference<XInputStream> StrongEncryptionDataSpace::getStream(const Sequence<Name
sal_Bool StrongEncryptionDataSpace::readEncryptionInfo(const Sequence<NamedValue>& aStreams)
{
- Reference<XInputStream> xEncryptionInfo = getStream(aStreams, "EncryptionInfo");
+ Reference<XInputStream> xEncryptionInfo = getStream(aStreams, u"EncryptionInfo");
if (!xEncryptionInfo.is())
return false;
diff --git a/oox/source/drawingml/customshapeproperties.cxx b/oox/source/drawingml/customshapeproperties.cxx
index 1b4d6b4a59f6..fd39bb36e30e 100644
--- a/oox/source/drawingml/customshapeproperties.cxx
+++ b/oox/source/drawingml/customshapeproperties.cxx
@@ -71,7 +71,7 @@ sal_Int32 CustomShapeProperties::SetCustomShapeGuideValue( std::vector< CustomSh
// returns the index into the guidelist for a given formula name,
// if the return value is < 0 then the guide value could not be found
-sal_Int32 CustomShapeProperties::GetCustomShapeGuideValue( const std::vector< CustomShapeGuide >& rGuideList, const OUString& rFormulaName )
+sal_Int32 CustomShapeProperties::GetCustomShapeGuideValue( const std::vector< CustomShapeGuide >& rGuideList, std::u16string_view rFormulaName )
{
// traverse the list from the end, because guide names can be reused
// and current is the last one
diff --git a/oox/source/drawingml/diagram/datamodel.cxx b/oox/source/drawingml/diagram/datamodel.cxx
index 469f404367f6..6185ee7acfb9 100644
--- a/oox/source/drawingml/diagram/datamodel.cxx
+++ b/oox/source/drawingml/diagram/datamodel.cxx
@@ -289,7 +289,7 @@ OString normalizeDotName( const OUString& rStr )
}
#endif
-static sal_Int32 calcDepth( const OUString& rNodeName,
+static sal_Int32 calcDepth( std::u16string_view rNodeName,
const dgm::Connections& rCnx )
{
// find length of longest path in 'isChild' graph, ending with rNodeName
diff --git a/oox/source/drawingml/diagram/diagramlayoutatoms.cxx b/oox/source/drawingml/diagram/diagramlayoutatoms.cxx
index 5071a7bd52d4..20b7a2df4233 100644
--- a/oox/source/drawingml/diagram/diagramlayoutatoms.cxx
+++ b/oox/source/drawingml/diagram/diagramlayoutatoms.cxx
@@ -547,7 +547,7 @@ namespace
* Takes the connection list from rLayoutNode, navigates from rFrom on an edge
* of type nType, using a direction determined by bSourceToDestination.
*/
-OUString navigate(LayoutNode& rLayoutNode, sal_Int32 nType, const OUString& rFrom,
+OUString navigate(LayoutNode& rLayoutNode, sal_Int32 nType, std::u16string_view rFrom,
bool bSourceToDestination)
{
for (const auto& rConnection : rLayoutNode.getDiagram().getData()->getConnections())
@@ -570,7 +570,7 @@ OUString navigate(LayoutNode& rLayoutNode, sal_Int32 nType, const OUString& rFro
return OUString();
}
-sal_Int32 calcMaxDepth(const OUString& rNodeName, const dgm::Connections& rConnections)
+sal_Int32 calcMaxDepth(std::u16string_view rNodeName, const dgm::Connections& rConnections)
{
sal_Int32 nMaxLength = 0;
for (auto const& aCxn : rConnections)
diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx
index 3ed451710b55..fc5051cb4bb0 100644
--- a/oox/source/export/drawingml.cxx
+++ b/oox/source/export/drawingml.cxx
@@ -2597,7 +2597,7 @@ bool DrawingML::IsDiagram(const Reference<XShape>& rXShape)
});
}
-sal_Int32 DrawingML::getBulletMarginIndentation (const Reference< XPropertySet >& rXPropSet,sal_Int16 nLevel, const OUString& propName)
+sal_Int32 DrawingML::getBulletMarginIndentation (const Reference< XPropertySet >& rXPropSet,sal_Int16 nLevel, std::u16string_view propName)
{
if (nLevel < 0 || !GetProperty(rXPropSet, "NumberingRules"))
return 0;
@@ -2712,8 +2712,8 @@ void DrawingML::WriteParagraphProperties( const Reference< XTextContent >& rPara
if (GetProperty(rXPropSet, "ParaBottomMargin"))
mAny >>= nParaBottomMargin;
- sal_Int32 nLeftMargin = getBulletMarginIndentation ( rXPropSet, nLevel,"LeftMargin");
- sal_Int32 nLineIndentation = getBulletMarginIndentation ( rXPropSet, nLevel,"FirstLineOffset");
+ sal_Int32 nLeftMargin = getBulletMarginIndentation ( rXPropSet, nLevel,u"LeftMargin");
+ sal_Int32 nLineIndentation = getBulletMarginIndentation ( rXPropSet, nLevel,u"FirstLineOffset");
if( !(nLevel != -1
|| nAlignment != style::ParagraphAdjust_LEFT
diff --git a/opencl/source/openclwrapper.cxx b/opencl/source/openclwrapper.cxx
index c7ac9525d620..29ad83ca2aae 100644
--- a/opencl/source/openclwrapper.cxx
+++ b/opencl/source/openclwrapper.cxx
@@ -703,7 +703,7 @@ const std::vector<OpenCLPlatformInfo>& fillOpenCLInfo()
namespace {
-cl_device_id findDeviceIdByDeviceString(const OUString& rString, const std::vector<OpenCLPlatformInfo>& rPlatforms)
+cl_device_id findDeviceIdByDeviceString(std::u16string_view rString, const std::vector<OpenCLPlatformInfo>& rPlatforms)
{
for (const OpenCLPlatformInfo& rPlatform : rPlatforms)
{
diff --git a/sax/qa/cppunit/xmlimport.cxx b/sax/qa/cppunit/xmlimport.cxx
index 1ae4a0320a47..261b46f284c3 100644
--- a/sax/qa/cppunit/xmlimport.cxx
+++ b/sax/qa/cppunit/xmlimport.cxx
@@ -75,7 +75,7 @@ private:
stack<sal_uInt16> m_aCountStack;
OUString canonicalform(const OUString &sName, const OUString &sValue, bool isElement);
- OUString getNamespace(const OUString &sName);
+ OUString getNamespace(std::u16string_view sName);
public:
TestDocumentHandler() {}
@@ -107,12 +107,12 @@ OUString TestDocumentHandler::canonicalform(const OUString &sName, const OUStrin
{
if ( nIndex >= 0 )
{
- OUString sNamespace = getNamespace( sName.copy( 0, nIndex ) );
+ OUString sNamespace = getNamespace( sName.subView( 0, nIndex ) );
return sNamespace + sName.subView(nIndex);
}
else
{
- OUString sDefaultns = getNamespace( "default" );
+ OUString sDefaultns = getNamespace( u"default" );
if ( !isElement || sDefaultns.isEmpty() )
return sName;
else
@@ -122,7 +122,7 @@ OUString TestDocumentHandler::canonicalform(const OUString &sName, const OUStrin
return OUString();
}
-OUString TestDocumentHandler::getNamespace(const OUString &sName)
+OUString TestDocumentHandler::getNamespace(std::u16string_view sName)
{
for (sal_Int16 i = m_aNamespaceStack.size() - 1; i>=0; i--)
{
diff --git a/sc/inc/ChartTools.hxx b/sc/inc/ChartTools.hxx
index 79aa00fb6056..08b53437d43e 100644
--- a/sc/inc/ChartTools.hxx
+++ b/sc/inc/ChartTools.hxx
@@ -42,13 +42,13 @@ public:
};
SdrOle2Obj* findChartsByName(ScDocShell* pDocShell, SCTAB nTab,
- OUString const & rName,
+ std::u16string_view rName,
ChartSourceType eChartSourceType);
SdrOle2Obj* getChartByIndex(ScDocShell* pDocShell, SCTAB nTab,
::tools::Long nIndex, ChartSourceType eChartSourceType);
-std::vector<SdrOle2Obj*> getAllPivotChartsConnectedTo(OUString const & sPivotTableName, ScDocShell* pDocShell);
+std::vector<SdrOle2Obj*> getAllPivotChartsConnectedTo(std::u16string_view sPivotTableName, ScDocShell* pDocShell);
} // end sc::tools
diff --git a/sc/inc/afmtuno.hxx b/sc/inc/afmtuno.hxx
index fca864ecf136..f3d9ba2a3d20 100644
--- a/sc/inc/afmtuno.hxx
+++ b/sc/inc/afmtuno.hxx
@@ -46,7 +46,7 @@ class ScAutoFormatsObj final : public ::cppu::WeakImplHelper<
{
private:
static ScAutoFormatObj* GetObjectByIndex_Impl(sal_uInt16 nIndex);
- static ScAutoFormatObj* GetObjectByName_Impl(const OUString& aName);
+ static ScAutoFormatObj* GetObjectByName_Impl(std::u16string_view aName);
public:
ScAutoFormatsObj();
diff --git a/sc/inc/arealink.hxx b/sc/inc/arealink.hxx
index 9419dc14d13e..f4a59750e68c 100644
--- a/sc/inc/arealink.hxx
+++ b/sc/inc/arealink.hxx
@@ -63,8 +63,8 @@ public:
void SetSource(const OUString& rDoc, const OUString& rFlt, const OUString& rOpt,
const OUString& rArea);
- bool IsEqual( const OUString& rFile, const OUString& rFilter, const OUString& rOpt,
- const OUString& rSource, const ScRange& rDest ) const;
+ bool IsEqual( std::u16string_view rFile, std::u16string_view rFilter, std::u16string_view rOpt,
+ std::u16string_view rSource, const ScRange& rDest ) const;
const OUString& GetFile() const { return aFileName; }
const OUString& GetFilter() const { return aFilterName; }
diff --git a/sc/inc/conditio.hxx b/sc/inc/conditio.hxx
index b3caae236efb..d22c623bd06e 100644
--- a/sc/inc/conditio.hxx
+++ b/sc/inc/conditio.hxx
@@ -577,7 +577,7 @@ public:
void InsertCol(SCTAB nTab, SCROW nRowStart, SCROW nRowEnd, SCCOL nColStart, SCSIZE nSize);
void DeleteArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2 );
- void RenameCellStyle( const OUString& rOld, const OUString& rNew );
+ void RenameCellStyle( std::u16string_view rOld, const OUString& rNew );
const ScFormatEntry* GetEntry( sal_uInt16 nPos ) const;
@@ -660,7 +660,7 @@ public:
void InsertRow(SCTAB nTab, SCCOL nColStart, SCCOL nColEnd, SCROW nRowStart, SCSIZE nSize);
void InsertCol(SCTAB nTab, SCROW nRowStart, SCROW nRowEnd, SCCOL nColStart, SCSIZE nSize);
- void RenameCellStyle( const OUString& rOld, const OUString& rNew );
+ void RenameCellStyle( std::u16string_view rOld, const OUString& rNew );
void DeleteArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2 );
typedef ConditionalFormatContainer::iterator iterator;
diff --git a/sc/inc/docpool.hxx b/sc/inc/docpool.hxx
index 9c3a6edcc50a..6a6e6be3d189 100644
--- a/sc/inc/docpool.hxx
+++ b/sc/inc/docpool.hxx
@@ -42,7 +42,7 @@ public:
virtual MapUnit GetMetric( sal_uInt16 nWhich ) const override;
void StyleDeleted( const ScStyleSheet* pStyle ); // delete templates(?) in organizer
- void CellStyleCreated( const OUString& rName, const ScDocument& rDoc );
+ void CellStyleCreated( std::u16string_view rName, const ScDocument& rDoc );
virtual bool GetPresentation( const SfxPoolItem& rItem,
MapUnit ePresentationMetric,
OUString& rText,
diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx
index 5bab5a19d80c..44c1fc6fd4b4 100644
--- a/sc/inc/document.hxx
+++ b/sc/inc/document.hxx
@@ -844,21 +844,21 @@ public:
SdrObject* GetObjectAtPoint( SCTAB nTab, const Point& rPos );
bool HasChartAtPoint( SCTAB nTab, const Point& rPos, OUString& rName );
- css::uno::Reference< css::chart2::XChartDocument > GetChartByName( const OUString& rChartName );
+ css::uno::Reference< css::chart2::XChartDocument > GetChartByName( std::u16string_view rChartName );
- SC_DLLPUBLIC void GetChartRanges( const OUString& rChartName, std::vector< ScRangeList >& rRanges, const ScDocument& rSheetNameDoc );
- void SetChartRanges( const OUString& rChartName, const std::vector< ScRangeList >& rRanges );
+ SC_DLLPUBLIC void GetChartRanges( std::u16string_view rChartName, std::vector< ScRangeList >& rRanges, const ScDocument& rSheetNameDoc );
+ void SetChartRanges( std::u16string_view rChartName, const std::vector< ScRangeList >& rRanges );
void UpdateChartArea( const OUString& rChartName, const ScRange& rNewArea,
bool bColHeaders, bool bRowHeaders, bool bAdd );
void UpdateChartArea( const OUString& rChartName,
const ScRangeListRef& rNewList,
bool bColHeaders, bool bRowHeaders, bool bAdd );
- void GetOldChartParameters( const OUString& rName,
+ void GetOldChartParameters( std::u16string_view rName,
ScRangeList& rRanges, bool& rColHeaders, bool& rRowHeaders );
css::uno::Reference<
css::embed::XEmbeddedObject >
- FindOleObjectByName( const OUString& rName );
+ FindOleObjectByName( std::u16string_view rName );
SC_DLLPUBLIC void MakeTable( SCTAB nTab,bool _bNeedsNameCheck = true );
@@ -1000,8 +1000,8 @@ public:
void SetLink( SCTAB nTab, ScLinkMode nMode, const OUString& rDoc,
const OUString& rFilter, const OUString& rOptions,
const OUString& rTabName, sal_uLong nRefreshDelay );
- bool HasLink( const OUString& rDoc,
- const OUString& rFilter, const OUString& rOptions ) const;
+ bool HasLink( std::u16string_view rDoc,
+ std::u16string_view rFilter, std::u16string_view rOptions ) const;
SC_DLLPUBLIC bool LinkExternalTab( SCTAB& nTab, const OUString& aDocTab,
const OUString& aFileName,
const OUString& aTabName );
@@ -1030,8 +1030,8 @@ public:
/** Tries to find a DDE link with the specified connection data.
@param rnDdePos (out-param) Returns the index of the DDE link (does not include other links from link manager).
@return true = DDE link found, rnDdePos valid. */
- SC_DLLPUBLIC bool FindDdeLink( const OUString& rAppl, const OUString& rTopic,
- const OUString& rItem, sal_uInt8 nMode, size_t& rnDdePos );
+ SC_DLLPUBLIC bool FindDdeLink( std::u16string_view rAppl, std::u16string_view rTopic,
+ std::u16string_view rItem, sal_uInt8 nMode, size_t& rnDdePos );
/** Returns the connection data of the specified DDE link.
@param nDdePos Index of the DDE link (does not include other links from link manager).
@@ -1081,7 +1081,7 @@ public:
SCCOL nCol2, SCROW nRow2, SCTAB nTab2,
SCCOL nDx, SCROW nDy, SCTAB nDz );
//! only assigns the new RangeList, no ChartListener or the like
- void SetChartRangeList( const OUString& rChartName,
+ void SetChartRangeList( std::u16string_view rChartName,
const ScRangeListRef& rNewRangeListRef );
void StartAnimations( SCTAB nTab );
@@ -2012,9 +2012,9 @@ public:
void RemoveManualBreaks( SCTAB nTab );
bool HasManualBreaks( SCTAB nTab ) const;
- bool IsPageStyleInUse( const OUString& rStrPageStyle, SCTAB* pInTab );
- bool RemovePageStyleInUse( const OUString& rStrPageStyle );
- bool RenamePageStyleInUse( const OUString& rOld, const OUString& rNew );
+ bool IsPageStyleInUse( std::u16string_view rStrPageStyle, SCTAB* pInTab );
+ bool RemovePageStyleInUse( std::u16string_view rStrPageStyle );
+ bool RenamePageStyleInUse( std::u16string_view rOld, const OUString& rNew );
void ModifyStyleSheet( SfxStyleSheetBase& rPageStyle,
const SfxItemSet& rChanges );
@@ -2111,7 +2111,7 @@ public:
SCCOL nCol, SCROW nRow, SCTAB nTab,
const ScMarkData& rMark);
- void InvalidateTextWidth( const OUString& rStyleName );
+ void InvalidateTextWidth( std::u16string_view rStyleName );
void InvalidateTextWidth( SCTAB nTab );
void InvalidateTextWidth( const ScAddress* pAdrFrom, const ScAddress* pAdrTo, bool bNumFormatChanged );
diff --git a/sc/inc/documentlinkmgr.hxx b/sc/inc/documentlinkmgr.hxx
index 99a3ca3e5a95..3d7bb9b82ddb 100644
--- a/sc/inc/documentlinkmgr.hxx
+++ b/sc/inc/documentlinkmgr.hxx
@@ -57,7 +57,7 @@ public:
bool updateDdeOrOleOrWebServiceLinks(weld::Window* pWin);
- void updateDdeLink( const OUString& rAppl, const OUString& rTopic, const OUString& rItem );
+ void updateDdeLink( std::u16string_view rAppl, std::u16string_view rTopic, std::u16string_view rItem );
size_t getDdeLinkCount() const;
diff --git a/sc/inc/docuno.hxx b/sc/inc/docuno.hxx
index 44fdc3463aed..6c80b3f0f2c7 100644
--- a/sc/inc/docuno.hxx
+++ b/sc/inc/docuno.hxx
@@ -715,9 +715,9 @@ private:
ScDocShell* pDocShell;
SCTAB nTab;
- bool GetScenarioIndex_Impl( const OUString& rName, SCTAB& rIndex );
+ bool GetScenarioIndex_Impl( std::u16string_view rName, SCTAB& rIndex );
ScTableSheetObj* GetObjectByIndex_Impl(sal_Int32 nIndex);
- ScTableSheetObj* GetObjectByName_Impl(const OUString& aName);
+ ScTableSheetObj* GetObjectByName_Impl(std::u16string_view aName);
public:
ScScenariosObj(ScDocShell* pDocSh, SCTAB nT);
diff --git a/sc/inc/dpcache.hxx b/sc/inc/dpcache.hxx
index 404ebf2ddaac..ccb26df2492f 100644
--- a/sc/inc/dpcache.hxx
+++ b/sc/inc/dpcache.hxx
@@ -163,7 +163,7 @@ public:
*/
sal_Int32 GetGroupType(tools::Long nDim) const;
- SCCOL GetDimensionIndex(const OUString& sName) const;
+ SCCOL GetDimensionIndex(std::u16string_view sName) const;
sal_uInt32 GetNumberFormat( tools::Long nDim ) const;
bool IsDateDimension( tools::Long nDim ) const ;
tools::Long GetDimMemberCount(tools::Long nDim) const;
diff --git a/sc/inc/dpgroup.hxx b/sc/inc/dpgroup.hxx
index eaf560437b8d..30254b321efa 100644
--- a/sc/inc/dpgroup.hxx
+++ b/sc/inc/dpgroup.hxx
@@ -139,7 +139,7 @@ public:
void AddGroupDimension( const ScDPGroupDimension& rGroup );
void SetNumGroupDimension( sal_Int32 nIndex, const ScDPNumGroupDimension& rGroup );
- sal_Int32 GetDimensionIndex( const OUString& rName );
+ sal_Int32 GetDimensionIndex( std::u16string_view rName );
virtual sal_Int32 GetColumnCount() override;
virtual sal_Int32 GetMembersCount( sal_Int32 nDim ) override;
diff --git a/sc/inc/dpobject.hxx b/sc/inc/dpobject.hxx
index 6d8fc8cf0357..4459b4b06dce 100644
--- a/sc/inc/dpobject.hxx
+++ b/sc/inc/dpobject.hxx
@@ -186,7 +186,7 @@ public:
tools::Rectangle& rPosRect, css::sheet::DataPilotFieldOrientation& rOrient, tools::Long& rDimPos );
bool IsFilterButton( const ScAddress& rPos );
- OUString GetFormattedString( const OUString& rDimName, const double fValue );
+ OUString GetFormattedString( std::u16string_view rDimName, const double fValue );
double GetPivotData(
const OUString& rDataFieldName,
@@ -392,7 +392,7 @@ public:
SC_DLLPUBLIC ScDPObject& operator[](size_t nIndex);
SC_DLLPUBLIC const ScDPObject& operator[](size_t nIndex) const;
- ScDPObject* GetByName(const OUString& rName) const;
+ ScDPObject* GetByName(std::u16string_view rName) const;
void DeleteOnTab( SCTAB nTab );
void UpdateReference( UpdateRefMode eUpdateRefMode,
@@ -434,9 +434,9 @@ private:
void RemoveCache(const ScDPCache* pCache);
void GetAllTables(const ScRange& rSrcRange, o3tl::sorted_vector<ScDPObject*>& rRefs) const;
- void GetAllTables(const OUString& rSrcName, o3tl::sorted_vector<ScDPObject*>& rRefs) const;
+ void GetAllTables(std::u16string_view rSrcName, o3tl::sorted_vector<ScDPObject*>& rRefs) const;
void GetAllTables(
- sal_Int32 nSdbType, const OUString& rDBName, const OUString& rCommand,
+ sal_Int32 nSdbType, std::u16string_view rDBName, std::u16string_view rCommand,
o3tl::sorted_vector<ScDPObject*>& rRefs) const;
private:
diff --git a/sc/inc/dpsave.hxx b/sc/inc/dpsave.hxx
index 54a04d7ed4ad..79145ec833f0 100644
--- a/sc/inc/dpsave.hxx
+++ b/sc/inc/dpsave.hxx
@@ -306,10 +306,10 @@ public:
SC_DLLPUBLIC ScDPSaveDimension* GetDataLayoutDimension();
SC_DLLPUBLIC ScDPSaveDimension* GetExistingDataLayoutDimension() const;
- ScDPSaveDimension* DuplicateDimension(const OUString& rName);
+ ScDPSaveDimension* DuplicateDimension(std::u16string_view rName);
SC_DLLPUBLIC ScDPSaveDimension& DuplicateDimension(const ScDPSaveDimension& rDim);
- SC_DLLPUBLIC ScDPSaveDimension* GetExistingDimensionByName(const OUString& rName) const;
+ SC_DLLPUBLIC ScDPSaveDimension* GetExistingDimensionByName(std::u16string_view rName) const;
SC_DLLPUBLIC ScDPSaveDimension* GetNewDimensionByName(const OUString& rName);
void RemoveDimensionByName(const OUString& rName);
@@ -361,7 +361,7 @@ public:
*
* @param rDimName dimension name
*/
- SC_DLLPUBLIC bool HasInvisibleMember(const OUString& rDimName) const;
+ SC_DLLPUBLIC bool HasInvisibleMember(std::u16string_view rDimName) const;
#if DUMP_PIVOT_TABLE
void Dump() const;
diff --git a/sc/inc/dptabsrc.hxx b/sc/inc/dptabsrc.hxx
index c12d80a80e66..38892ea1bceb 100644
--- a/sc/inc/dptabsrc.hxx
+++ b/sc/inc/dptabsrc.hxx
@@ -165,7 +165,7 @@ public:
bool SubTotalAllowed(sal_Int32 nColumn); //! move to ScDPResultData
- ScDPDimension* AddDuplicated(const OUString& rNewName);
+ ScDPDimension* AddDuplicated(std::u16string_view rNewName);
sal_Int32 GetDupCount() const { return nDupCount; }
sal_Int32 GetSourceDim(sal_Int32 nDim);
diff --git a/sc/inc/drwlayer.hxx b/sc/inc/drwlayer.hxx
index d0efb68513fa..030fd3855ec8 100644
--- a/sc/inc/drwlayer.hxx
+++ b/sc/inc/drwlayer.hxx
@@ -164,7 +164,7 @@ public:
// (ChartListenerCollection etc. must use GetPersistName directly)
static OUString GetVisibleName( const SdrObject* pObj );
- SdrObject* GetNamedObject( const OUString& rName, sal_uInt16 nId, SCTAB& rFoundTab ) const;
+ SdrObject* GetNamedObject( std::u16string_view rName, sal_uInt16 nId, SCTAB& rFoundTab ) const;
// if pnCounter != NULL, the search for a name starts with this index + 1,
// and the index really used is returned.
OUString GetNewGraphicName( tools::Long* pnCounter = nullptr ) const;
diff --git a/sc/inc/externalrefmgr.hxx b/sc/inc/externalrefmgr.hxx
index db81502b3ef6..fd07fa0e657a 100644
--- a/sc/inc/externalrefmgr.hxx
+++ b/sc/inc/externalrefmgr.hxx
@@ -571,7 +571,7 @@ public:
bool isValidRangeName(sal_uInt16 nFileId, const OUString& rName);
OUString getOwnDocumentName() const;
- bool isOwnDocument(const OUString& rFile) const;
+ bool isOwnDocument(std::u16string_view rFile) const;
/**
* Takes a flat file name, and convert it to an absolute URL path. An
diff --git a/sc/inc/linkuno.hxx b/sc/inc/linkuno.hxx
index d1a93f2ed6cd..34e0d7e5584c 100644
--- a/sc/inc/linkuno.hxx
+++ b/sc/inc/linkuno.hxx
@@ -327,7 +327,7 @@ private:
ScDocShell* pDocShell;
ScDDELinkObj* GetObjectByIndex_Impl(sal_Int32 nIndex);
- ScDDELinkObj* GetObjectByName_Impl(const OUString& aName);
+ ScDDELinkObj* GetObjectByName_Impl(std::u16string_view aName);
public:
ScDDELinksObj(ScDocShell* pDocSh);
diff --git a/sc/inc/userlist.hxx b/sc/inc/userlist.hxx
index ba3ac290153a..b71ceb4cc3f6 100644
--- a/sc/inc/userlist.hxx
+++ b/sc/inc/userlist.hxx
@@ -78,7 +78,7 @@ public:
const ScUserListData* GetData(const OUString& rSubStr) const;
/// If the list in rStr is already inserted
- bool HasEntry(const OUString& rStr) const;
+ bool HasEntry(std::u16string_view rStr) const;
const ScUserListData& operator[](size_t nIndex) const;
ScUserListData& operator[](size_t nIndex);
diff --git a/sc/qa/unit/pivottable_filters_test.cxx b/sc/qa/unit/pivottable_filters_test.cxx
index 49248230ee28..6322c9a809d4 100644
--- a/sc/qa/unit/pivottable_filters_test.cxx
+++ b/sc/qa/unit/pivottable_filters_test.cxx
@@ -320,7 +320,7 @@ void ScPivotTableFiltersTest::testPivotTableNamedRangeSourceODS()
namespace
{
bool checkVisiblePageFieldMember(const ScDPSaveDimension::MemberList& rMembers,
- const OUString& rVisibleMember)
+ std::u16string_view rVisibleMember)
{
bool bFound = false;
for (const ScDPSaveMember* pMem : rMembers)
@@ -356,23 +356,23 @@ void ScPivotTableFiltersTest::testPivotTableSharedCacheGroupODS()
CPPUNIT_ASSERT_MESSAGE("There should be a pivot table here.", pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT_MESSAGE("Save data is expected.", pSaveData);
- ScDPSaveDimension* pDim = pSaveData->GetExistingDimensionByName("Project Name");
+ ScDPSaveDimension* pDim = pSaveData->GetExistingDimensionByName(u"Project Name");
CPPUNIT_ASSERT_MESSAGE("Failed to get page field named 'Project Name'.", pDim);
const ScDPSaveDimension::MemberList* pMembers = &pDim->GetMembers();
CPPUNIT_ASSERT_EQUAL(static_cast<size_t>(14), pMembers->size());
CPPUNIT_ASSERT_MESSAGE("Incorrect member visibility.",
- checkVisiblePageFieldMember(*pMembers, "APL-01-1"));
+ checkVisiblePageFieldMember(*pMembers, u"APL-01-1"));
pDPObj = rDoc.GetDPAtCursor(0, 1, 2); // A2 on 3rd sheet
CPPUNIT_ASSERT_MESSAGE("There should be a pivot table here.", pDPObj);
pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT_MESSAGE("Save data is expected.", pSaveData);
- pDim = pSaveData->GetExistingDimensionByName("Project Name");
+ pDim = pSaveData->GetExistingDimensionByName(u"Project Name");
CPPUNIT_ASSERT_MESSAGE("Failed to get page field named 'Project Name'.", pDim);
pMembers = &pDim->GetMembers();
CPPUNIT_ASSERT_EQUAL(static_cast<size_t>(14), pMembers->size());
CPPUNIT_ASSERT_MESSAGE("Incorrect member visibility.",
- checkVisiblePageFieldMember(*pMembers, "VEN-01-1"));
+ checkVisiblePageFieldMember(*pMembers, u"VEN-01-1"));
// These two pivot tables share the same data range. We should only have
// one pivot cache.
@@ -389,7 +389,7 @@ void ScPivotTableFiltersTest::testPivotTableSharedCacheGroupODS()
CPPUNIT_ASSERT_EQUAL(static_cast<size_t>(9), pCache->GetFieldCount());
CPPUNIT_ASSERT_EQUAL(static_cast<size_t>(2), pCache->GetGroupFieldCount());
- SCCOL nDim = pCache->GetDimensionIndex("StartDate");
+ SCCOL nDim = pCache->GetDimensionIndex(u"StartDate");
CPPUNIT_ASSERT_MESSAGE("Dimension 'StartDate' doesn't exist in the cache.", nDim >= 0);
sal_Int32 nGrpType = pCache->GetGroupType(nDim);
CPPUNIT_ASSERT_EQUAL(sheet::DataPilotFieldGroupBy::DAYS, nGrpType);
@@ -1490,7 +1490,7 @@ void ScPivotTableFiltersTest::testPivotTableDoubleFieldFilter()
CPPUNIT_ASSERT(pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double field1");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double field1");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1515,7 +1515,7 @@ void ScPivotTableFiltersTest::testPivotTableDoubleFieldFilter()
CPPUNIT_ASSERT(pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double field2");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double field2");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1540,7 +1540,7 @@ void ScPivotTableFiltersTest::testPivotTableDoubleFieldFilter()
CPPUNIT_ASSERT(pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double field3");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double field3");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1581,7 +1581,7 @@ void ScPivotTableFiltersTest::testPivotTableStringFieldFilter()
CPPUNIT_ASSERT(pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Country");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Country");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1616,7 +1616,7 @@ void ScPivotTableFiltersTest::testPivotTableDateFieldFilter()
CPPUNIT_ASSERT(pSaveData);
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Date");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Date");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1636,7 +1636,7 @@ void ScPivotTableFiltersTest::testPivotTableDateFieldFilter()
}
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Date2");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Date2");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1656,7 +1656,7 @@ void ScPivotTableFiltersTest::testPivotTableDateFieldFilter()
}
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Date3");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Date3");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1697,7 +1697,7 @@ void ScPivotTableFiltersTest::testPivotTableBoolFieldFilter()
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Bool field");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Bool field");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1733,7 +1733,7 @@ void ScPivotTableFiltersTest::testPivotTableRowColPageFieldFilter()
// Row field
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Order ID");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Order ID");
CPPUNIT_ASSERT(pSaveDim);
CPPUNIT_ASSERT_EQUAL(sheet::DataPilotFieldOrientation_ROW, pSaveDim->GetOrientation());
@@ -1752,7 +1752,7 @@ void ScPivotTableFiltersTest::testPivotTableRowColPageFieldFilter()
// Column field
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double2 field");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double2 field");
CPPUNIT_ASSERT(pSaveDim);
CPPUNIT_ASSERT_EQUAL(sheet::DataPilotFieldOrientation_COLUMN, pSaveDim->GetOrientation());
@@ -1771,7 +1771,7 @@ void ScPivotTableFiltersTest::testPivotTableRowColPageFieldFilter()
// Page field
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double3 field");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double3 field");
CPPUNIT_ASSERT(pSaveDim);
CPPUNIT_ASSERT_EQUAL(sheet::DataPilotFieldOrientation_PAGE, pSaveDim->GetOrientation());
@@ -1790,7 +1790,7 @@ void ScPivotTableFiltersTest::testPivotTableRowColPageFieldFilter()
// Hidden field
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double4 field");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double4 field");
CPPUNIT_ASSERT(pSaveDim);
CPPUNIT_ASSERT_EQUAL(sheet::DataPilotFieldOrientation_HIDDEN, pSaveDim->GetOrientation());
@@ -1829,7 +1829,7 @@ void ScPivotTableFiltersTest::testPivotTableEmptyItem()
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Category");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Category");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1868,7 +1868,7 @@ void ScPivotTableFiltersTest::testPivotTablePageFieldFilter()
// Only one item is selected (an empty item)
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Product");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Product");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
CPPUNIT_ASSERT_EQUAL(size_t(3), rMembers.size());
@@ -1885,7 +1885,7 @@ void ScPivotTableFiltersTest::testPivotTablePageFieldFilter()
// More items are selected, but not all
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Category");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Category");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1903,7 +1903,7 @@ void ScPivotTableFiltersTest::testPivotTablePageFieldFilter()
// All items are selected
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Order ID");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Order ID");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1921,7 +1921,7 @@ void ScPivotTableFiltersTest::testPivotTablePageFieldFilter()
// Only one item is selected (a non-empty item)
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Country");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Country");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -1986,7 +1986,7 @@ void ScPivotTableFiltersTest::testPivotTableDoubleFieldFilterXLSX()
CPPUNIT_ASSERT(pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double field1");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double field1");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -2011,7 +2011,7 @@ void ScPivotTableFiltersTest::testPivotTableDoubleFieldFilterXLSX()
CPPUNIT_ASSERT(pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double field2");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double field2");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -2036,7 +2036,7 @@ void ScPivotTableFiltersTest::testPivotTableDoubleFieldFilterXLSX()
CPPUNIT_ASSERT(pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double field3");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double field3");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -2077,7 +2077,7 @@ void ScPivotTableFiltersTest::testPivotTableStringFieldFilterXLSX()
CPPUNIT_ASSERT(pDPObj);
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Country");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Country");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -2112,7 +2112,7 @@ void ScPivotTableFiltersTest::testPivotTableDateFieldFilterXLSX()
CPPUNIT_ASSERT(pSaveData);
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Date");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Date");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -2128,7 +2128,7 @@ void ScPivotTableFiltersTest::testPivotTableDateFieldFilterXLSX()
}
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Date2");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Date2");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -2144,7 +2144,7 @@ void ScPivotTableFiltersTest::testPivotTableDateFieldFilterXLSX()
}
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Date3");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Date3");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -2181,7 +2181,7 @@ void ScPivotTableFiltersTest::testPivotTableBoolFieldFilterXLSX()
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Bool field");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Bool field");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
@@ -2217,7 +2217,7 @@ void ScPivotTableFiltersTest::testPivotTableRowColPageFieldFilterXLSX()
// Row field
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Order ID");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Order ID");
CPPUNIT_ASSERT(pSaveDim);
CPPUNIT_ASSERT_EQUAL(sheet::DataPilotFieldOrientation_ROW, pSaveDim->GetOrientation());
@@ -2236,7 +2236,7 @@ void ScPivotTableFiltersTest::testPivotTableRowColPageFieldFilterXLSX()
// Column field
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double2 field");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double2 field");
CPPUNIT_ASSERT(pSaveDim);
CPPUNIT_ASSERT_EQUAL(sheet::DataPilotFieldOrientation_COLUMN, pSaveDim->GetOrientation());
@@ -2255,7 +2255,7 @@ void ScPivotTableFiltersTest::testPivotTableRowColPageFieldFilterXLSX()
// Page field
{
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("Double3 field");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"Double3 field");
CPPUNIT_ASSERT(pSaveDim);
CPPUNIT_ASSERT_EQUAL(sheet::DataPilotFieldOrientation_PAGE, pSaveDim->GetOrientation());
@@ -2314,7 +2314,7 @@ void ScPivotTableFiltersTest::testPivotTableErrorItemFilterXLSX()
ScDPSaveData* pSaveData = pDPObj->GetSaveData();
CPPUNIT_ASSERT(pSaveData);
- ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName("b");
+ ScDPSaveDimension* pSaveDim = pSaveData->GetExistingDimensionByName(u"b");
CPPUNIT_ASSERT(pSaveDim);
const ScDPSaveDimension::MemberList& rMembers = pSaveDim->GetMembers();
CPPUNIT_ASSERT_EQUAL(size_t(4), rMembers.size());
diff --git a/sc/qa/unit/subsequent_export-test.cxx b/sc/qa/unit/subsequent_export-test.cxx
index f9e6e1f3ebb5..36d85d8f2343 100644
--- a/sc/qa/unit/subsequent_export-test.cxx
+++ b/sc/qa/unit/subsequent_export-test.cxx
@@ -2817,7 +2817,7 @@ void ScExportTest::testTrackChangesSimpleXLSX()
return true;
}
- bool checkRevisionUserAndTime( ScDocument& rDoc, const OUString& rOwnerName )
+ bool checkRevisionUserAndTime( ScDocument& rDoc, std::u16string_view rOwnerName )
{
ScChangeTrack* pCT = rDoc.GetChangeTrack();
if (!pCT)
diff --git a/sc/qa/unit/ucalc.cxx b/sc/qa/unit/ucalc.cxx
index f5da5620744c..774f3eb7069a 100644
--- a/sc/qa/unit/ucalc.cxx
+++ b/sc/qa/unit/ucalc.cxx
@@ -6647,7 +6647,7 @@ void Test::testEmptyCalcDocDefaults()
CPPUNIT_ASSERT_EQUAL( false, m_pDoc->HasManualBreaks(tab) );
}
-ScDocShell* Test::findLoadedDocShellByName(const OUString& rName)
+ScDocShell* Test::findLoadedDocShellByName(std::u16string_view rName)
{
ScDocShell* pShell = static_cast<ScDocShell*>(SfxObjectShell::GetFirst(checkSfxObjectShell<ScDocShell>, false));
while (pShell)
diff --git a/sc/qa/unit/ucalc.hxx b/sc/qa/unit/ucalc.hxx
index 40ef0d2898a0..e72e2e94128d 100644
--- a/sc/qa/unit/ucalc.hxx
+++ b/sc/qa/unit/ucalc.hxx
@@ -43,7 +43,7 @@ public:
sal_uInt16 mnIndex;
};
- static ScDocShell* findLoadedDocShellByName(const OUString& rName);
+ static ScDocShell* findLoadedDocShellByName(std::u16string_view rName);
static bool insertRangeNames(ScDocument* pDoc, ScRangeName* pNames, const RangeNameDef* p,
const RangeNameDef* pEnd);
static void printRange(ScDocument* pDoc, const ScRange& rRange, const char* pCaption);
diff --git a/sc/qa/unit/ucalc_pivottable.cxx b/sc/qa/unit/ucalc_pivottable.cxx
index 54a4e85d6dcf..00bb90dfe2c2 100644
--- a/sc/qa/unit/ucalc_pivottable.cxx
+++ b/sc/qa/unit/ucalc_pivottable.cxx
@@ -1629,7 +1629,7 @@ void Test::testPivotTableTextNumber()
// Set the Name dimension to page dimension.
pDPObj->BuildAllDimensionMembers();
ScDPSaveData aSaveData(*pDPObj->GetSaveData());
- ScDPSaveDimension* pDim = aSaveData.GetExistingDimensionByName("Name");
+ ScDPSaveDimension* pDim = aSaveData.GetExistingDimensionByName(u"Name");
CPPUNIT_ASSERT(pDim);
pDim->SetOrientation(sheet::DataPilotFieldOrientation_PAGE);
OUString aVisiblePage("0004");
@@ -2407,9 +2407,9 @@ void Test::testPivotTableDPCollection()
CPPUNIT_ASSERT_EQUAL_MESSAGE("there should be no DP table", size_t(0), pDPs->GetCount());
CPPUNIT_ASSERT_EQUAL_MESSAGE("should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName("DP1"));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u"DP1"));
CPPUNIT_ASSERT_EQUAL_MESSAGE("should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName(""));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u""));
// Add 2 DP objects
ScDPObject* pDPObj = createDPFromRange(m_pDoc, aDataRange , aFields, nFieldCount, false);
@@ -2424,36 +2424,36 @@ void Test::testPivotTableDPCollection()
CPPUNIT_ASSERT_EQUAL_MESSAGE("there should be two DP tables", size_t(2), pDPs->GetCount());
CPPUNIT_ASSERT_EQUAL_MESSAGE("should return first DPObject",
- pDPObj, pDPs->GetByName("DP1"));
+ pDPObj, pDPs->GetByName(u"DP1"));
CPPUNIT_ASSERT_EQUAL_MESSAGE("should return second DPObject",
- pDPObj2, pDPs->GetByName("DP2"));
+ pDPObj2, pDPs->GetByName(u"DP2"));
CPPUNIT_ASSERT_EQUAL_MESSAGE("empty string should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName(""));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u""));
CPPUNIT_ASSERT_EQUAL_MESSAGE("non existent name should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName("Non"));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u"Non"));
// Remove first DP Object
pDPs->FreeTable(pDPObj);
CPPUNIT_ASSERT_EQUAL_MESSAGE("there should be only one DP table", size_t(1), pDPs->GetCount());
CPPUNIT_ASSERT_EQUAL_MESSAGE("first DP object was deleted, should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName("DP1"));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u"DP1"));
CPPUNIT_ASSERT_EQUAL_MESSAGE("should return second DPObject",
- pDPObj2, pDPs->GetByName("DP2"));
+ pDPObj2, pDPs->GetByName(u"DP2"));
CPPUNIT_ASSERT_EQUAL_MESSAGE("empty string should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName(""));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u""));
CPPUNIT_ASSERT_EQUAL_MESSAGE("non existent name should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName("Non"));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u"Non"));
// Remove second DP Object
pDPs->FreeTable(pDPObj2);
CPPUNIT_ASSERT_EQUAL_MESSAGE("first DP object was deleted, should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName("DP1"));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u"DP1"));
CPPUNIT_ASSERT_EQUAL_MESSAGE("second DP object was deleted, should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName("DP2"));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u"DP2"));
CPPUNIT_ASSERT_EQUAL_MESSAGE("empty string should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName(""));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u""));
CPPUNIT_ASSERT_EQUAL_MESSAGE("non existent name should return nullptr",
- static_cast<ScDPObject*>(nullptr), pDPs->GetByName("Non"));
+ static_cast<ScDPObject*>(nullptr), pDPs->GetByName(u"Non"));
// Clean-up
m_pDoc->DeleteTab(1);
diff --git a/sc/source/core/data/conditio.cxx b/sc/source/core/data/conditio.cxx
index f71946688f6f..11e74fa258db 100644
--- a/sc/source/core/data/conditio.cxx
+++ b/sc/source/core/data/conditio.cxx
@@ -1992,7 +1992,7 @@ void ScConditionalFormat::DeleteArea( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCR
maRanges.DeleteArea( nCol1, nRow1, nTab, nCol2, nRow2, nTab );
}
-void ScConditionalFormat::RenameCellStyle(const OUString& rOld, const OUString& rNew)
+void ScConditionalFormat::RenameCellStyle(std::u16string_view rOld, const OUString& rNew)
{
for(const auto& rxEntry : maEntries)
if(rxEntry->GetType() == ScFormatEntry::Type::Condition ||
@@ -2156,7 +2156,7 @@ void ScConditionalFormatList::UpdateMoveTab( sc::RefUpdateMoveTabContext& rCxt )
}
}
-void ScConditionalFormatList::RenameCellStyle( const OUString& rOld, const OUString& rNew )
+void ScConditionalFormatList::RenameCellStyle( std::u16string_view rOld, const OUString& rNew )
{
for (auto const& it : m_ConditionalFormats)
{
diff --git a/sc/source/core/data/docpool.cxx b/sc/source/core/data/docpool.cxx
index a4691f69ef81..f49f99bd0c69 100644
--- a/sc/source/core/data/docpool.cxx
+++ b/sc/source/core/data/docpool.cxx
@@ -358,7 +358,7 @@ void ScDocumentPool::StyleDeleted( const ScStyleSheet* pStyle )
}
}
-void ScDocumentPool::CellStyleCreated( const OUString& rName, const ScDocument& rDoc )
+void ScDocumentPool::CellStyleCreated( std::u16string_view rName, const ScDocument& rDoc )
{
// If a style was created, don't keep any pattern with its name string in the pool,
// because it would compare equal to a pattern with a pointer to the new style.
diff --git a/sc/source/core/data/documen3.cxx b/sc/source/core/data/documen3.cxx
index c2adce1c3ae7..944ca8c75982 100644
--- a/sc/source/core/data/documen3.cxx
+++ b/sc/source/core/data/documen3.cxx
@@ -546,8 +546,8 @@ void ScDocument::SetLink( SCTAB nTab, ScLinkMode nMode, const OUString& rDoc,
maTabs[nTab]->SetLink( nMode, rDoc, rFilter, rOptions, rTabName, nRefreshDelay );
}
-bool ScDocument::HasLink( const OUString& rDoc,
- const OUString& rFilter, const OUString& rOptions ) const
+bool ScDocument::HasLink( std::u16string_view rDoc,
+ std::u16string_view rFilter, std::u16string_view rOptions ) const
{
SCTAB nCount = static_cast<SCTAB>(maTabs.size());
for (SCTAB i=0; i<nCount; i++)
diff --git a/sc/source/core/data/documen5.cxx b/sc/source/core/data/documen5.cxx
index 33d0d74703b0..1933601aa7db 100644
--- a/sc/source/core/data/documen5.cxx
+++ b/sc/source/core/data/documen5.cxx
@@ -134,7 +134,7 @@ void ScDocument::UpdateChartArea( const OUString& rChartName,
UpdateChartArea( rChartName, aRLR, bColHeaders, bRowHeaders, bAdd );
}
-uno::Reference< chart2::XChartDocument > ScDocument::GetChartByName( const OUString& rChartName )
+uno::Reference< chart2::XChartDocument > ScDocument::GetChartByName( std::u16string_view rChartName )
{
uno::Reference< chart2::XChartDocument > xReturn;
@@ -164,7 +164,7 @@ uno::Reference< chart2::XChartDocument > ScDocument::GetChartByName( const OUStr
return xReturn;
}
-void ScDocument::GetChartRanges( const OUString& rChartName, ::std::vector< ScRangeList >& rRangesVector, const ScDocument& rSheetNameDoc )
+void ScDocument::GetChartRanges( std::u16string_view rChartName, ::std::vector< ScRangeList >& rRangesVector, const ScDocument& rSheetNameDoc )
{
rRangesVector.clear();
uno::Reference< chart2::XChartDocument > xChartDoc( GetChartByName( rChartName ) );
@@ -181,7 +181,7 @@ void ScDocument::GetChartRanges( const OUString& rChartName, ::std::vector< ScRa
}
}
-void ScDocument::SetChartRanges( const OUString& rChartName, const ::std::vector< ScRangeList >& rRangesVector )
+void ScDocument::SetChartRanges( std::u16string_view rChartName, const ::std::vector< ScRangeList >& rRangesVector )
{
uno::Reference< chart2::XChartDocument > xChartDoc( GetChartByName( rChartName ) );
if ( !xChartDoc.is() )
@@ -199,7 +199,7 @@ void ScDocument::SetChartRanges( const OUString& rChartName, const ::std::vector
ScChartHelper::SetChartRanges( xChartDoc, aRangeStrings );
}
-void ScDocument::GetOldChartParameters( const OUString& rName,
+void ScDocument::GetOldChartParameters( std::u16string_view rName,
ScRangeList& rRanges, bool& rColHeaders, bool& rRowHeaders )
{
// used for undo of changing chart source area
@@ -479,7 +479,7 @@ void ScDocument::UpdateChartRef( UpdateRefMode eUpdateRefMode,
}
}
-void ScDocument::SetChartRangeList( const OUString& rChartName,
+void ScDocument::SetChartRangeList( std::u16string_view rChartName,
const ScRangeListRef& rNewRangeListRef )
{
// called from ChartListener
@@ -533,7 +533,7 @@ bool ScDocument::HasData( SCCOL nCol, SCROW nRow, SCTAB nTab )
}
uno::Reference< embed::XEmbeddedObject >
- ScDocument::FindOleObjectByName( const OUString& rName )
+ ScDocument::FindOleObjectByName( std::u16string_view rName )
{
if (!mpDrawLayer)
return uno::Reference< embed::XEmbeddedObject >();
diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx
index 3e09e16656ab..e4cb29e8fae7 100644
--- a/sc/source/core/data/documen8.cxx
+++ b/sc/source/core/data/documen8.cxx
@@ -292,7 +292,7 @@ void ScDocument::CopyStdStylesFrom( const ScDocument& rSrcDoc )
mxPoolHelper->GetStylePool()->CopyStdStylesFrom( rSrcDoc.mxPoolHelper->GetStylePool() );
}
-void ScDocument::InvalidateTextWidth( const OUString& rStyleName )
+void ScDocument::InvalidateTextWidth( std::u16string_view rStyleName )
{
const SCTAB nCount = GetTableCount();
for ( SCTAB i=0; i<nCount && maTabs[i]; i++ )
@@ -307,7 +307,7 @@ void ScDocument::InvalidateTextWidth( SCTAB nTab )
InvalidateTextWidth( &aAdrFrom, &aAdrTo, false );
}
-bool ScDocument::IsPageStyleInUse( const OUString& rStrPageStyle, SCTAB* pInTab )
+bool ScDocument::IsPageStyleInUse( std::u16string_view rStrPageStyle, SCTAB* pInTab )
{
bool bInUse = false;
const SCTAB nCount = GetTableCount();
@@ -322,7 +322,7 @@ bool ScDocument::IsPageStyleInUse( const OUString& rStrPageStyle, SCTAB* pInTab
return bInUse;
}
-bool ScDocument::RemovePageStyleInUse( const OUString& rStyle )
+bool ScDocument::RemovePageStyleInUse( std::u16string_view rStyle )
{
bool bWasInUse = false;
const SCTAB nCount = GetTableCount();
@@ -337,7 +337,7 @@ bool ScDocument::RemovePageStyleInUse( const OUString& rStyle )
return bWasInUse;
}
-bool ScDocument::RenamePageStyleInUse( const OUString& rOld, const OUString& rNew )
+bool ScDocument::RenamePageStyleInUse( std::u16string_view rOld, const OUString& rNew )
{
bool bWasInUse = false;
const SCTAB nCount = GetTableCount();
@@ -903,7 +903,7 @@ namespace {
@return The DDE link, if it exists, otherwise 0. */
ScDdeLink* lclGetDdeLink(
const sfx2::LinkManager* pLinkManager,
- const OUString& rAppl, const OUString& rTopic, const OUString& rItem, sal_uInt8 nMode,
+ std::u16string_view rAppl, std::u16string_view rTopic, std::u16string_view rItem, sal_uInt8 nMode,
size_t* pnDdePos = nullptr )
{
if( pLinkManager )
@@ -954,7 +954,7 @@ ScDdeLink* lclGetDdeLink( const sfx2::LinkManager* pLinkManager, size_t nDdePos
} // namespace
-bool ScDocument::FindDdeLink( const OUString& rAppl, const OUString& rTopic, const OUString& rItem,
+bool ScDocument::FindDdeLink( std::u16string_view rAppl, std::u16string_view rTopic, std::u16string_view rItem,
sal_uInt8 nMode, size_t& rnDdePos )
{
return lclGetDdeLink( GetLinkManager(), rAppl, rTopic, rItem, nMode, &rnDdePos ) != nullptr;
diff --git a/sc/source/core/data/dpcache.cxx b/sc/source/core/data/dpcache.cxx
index 02fc414e2642..d16ceb957c61 100644
--- a/sc/source/core/data/dpcache.cxx
+++ b/sc/source/core/data/dpcache.cxx
@@ -1084,7 +1084,7 @@ tools::Long ScDPCache::GetDimMemberCount(tools::Long nDim) const
return maFields[nDim]->maItems.size();
}
-SCCOL ScDPCache::GetDimensionIndex(const OUString& sName) const
+SCCOL ScDPCache::GetDimensionIndex(std::u16string_view sName) const
{
for (size_t i = 1; i < maLabelNames.size(); ++i)
{
diff --git a/sc/source/core/data/dpgroup.cxx b/sc/source/core/data/dpgroup.cxx
index e2ef44e785bd..b2b5b4681306 100644
--- a/sc/source/core/data/dpgroup.cxx
+++ b/sc/source/core/data/dpgroup.cxx
@@ -493,7 +493,7 @@ void ScDPGroupTableData::SetNumGroupDimension( sal_Int32 nIndex, const ScDPNumGr
}
}
-sal_Int32 ScDPGroupTableData::GetDimensionIndex( const OUString& rName )
+sal_Int32 ScDPGroupTableData::GetDimensionIndex( std::u16string_view rName )
{
for (tools::Long i = 0; i < nSourceCount; ++i) // nSourceCount excludes data layout
if (pSourceData->getDimensionName(i) == rName) //TODO: ignore case?
diff --git a/sc/source/core/data/dpobject.cxx b/sc/source/core/data/dpobject.cxx
index 74a99790422a..ba1a8f4d398e 100644
--- a/sc/source/core/data/dpobject.cxx
+++ b/sc/source/core/data/dpobject.cxx
@@ -1426,7 +1426,7 @@ void ScDPObject::GetMemberResultNames(ScDPUniqueStringSet& rNames, tools::Long n
pOutput->GetMemberResultNames(rNames, nDimension); // used only with table data -> level not needed
}
-OUString ScDPObject::GetFormattedString(const OUString& rDimName, const double fValue)
+OUString ScDPObject::GetFormattedString(std::u16string_view rDimName, const double fValue)
{
ScDPTableData* pTableData = GetTableData();
if(!pTableData)
@@ -3689,7 +3689,7 @@ const ScDPObject& ScDPCollection::operator [](size_t nIndex) const
return *maTables[nIndex];
}
-ScDPObject* ScDPCollection::GetByName(const OUString& rName) const
+ScDPObject* ScDPCollection::GetByName(std::u16string_view rName) const
{
for (std::unique_ptr<ScDPObject> const & pObject : maTables)
{
@@ -3872,7 +3872,7 @@ void ScDPCollection::GetAllTables(const ScRange& rSrcRange, o3tl::sorted_vector<
rRefs.swap(aRefs);
}
-void ScDPCollection::GetAllTables(const OUString& rSrcName, o3tl::sorted_vector<ScDPObject*>& rRefs) const
+void ScDPCollection::GetAllTables(std::u16string_view rSrcName, o3tl::sorted_vector<ScDPObject*>& rRefs) const
{
o3tl::sorted_vector<ScDPObject*> aRefs;
for (const auto& rxTable : maTables)
@@ -3901,7 +3901,7 @@ void ScDPCollection::GetAllTables(const OUString& rSrcName, o3tl::sorted_vector<
}
void ScDPCollection::GetAllTables(
- sal_Int32 nSdbType, const OUString& rDBName, const OUString& rCommand,
+ sal_Int32 nSdbType, std::u16string_view rDBName, std::u16string_view rCommand,
o3tl::sorted_vector<ScDPObject*>& rRefs) const
{
o3tl::sorted_vector<ScDPObject*> aRefs;
diff --git a/sc/source/core/data/dpsave.cxx b/sc/source/core/data/dpsave.cxx
index 95bd2a84985f..cb8e56e6d6fa 100644
--- a/sc/source/core/data/dpsave.cxx
+++ b/sc/source/core/data/dpsave.cxx
@@ -842,7 +842,7 @@ ScDPSaveDimension* ScDPSaveData::GetDimensionByName(const OUString& rName)
return AppendNewDimension(rName, false);
}
-ScDPSaveDimension* ScDPSaveData::GetExistingDimensionByName(const OUString& rName) const
+ScDPSaveDimension* ScDPSaveData::GetExistingDimensionByName(std::u16string_view rName) const
{
for (auto const& iter : m_DimList)
{
@@ -882,7 +882,7 @@ ScDPSaveDimension* ScDPSaveData::GetExistingDataLayoutDimension() const
return nullptr;
}
-ScDPSaveDimension* ScDPSaveData::DuplicateDimension(const OUString& rName)
+ScDPSaveDimension* ScDPSaveData::DuplicateDimension(std::u16string_view rName)
{
// always insert new
@@ -1292,7 +1292,7 @@ void ScDPSaveData::SyncAllDimensionMembers(ScDPTableData* pData)
}
}
-bool ScDPSaveData::HasInvisibleMember(const OUString& rDimName) const
+bool ScDPSaveData::HasInvisibleMember(std::u16string_view rDimName) const
{
ScDPSaveDimension* pDim = GetExistingDimensionByName(rDimName);
if (!pDim)
diff --git a/sc/source/core/data/dptabsrc.cxx b/sc/source/core/data/dptabsrc.cxx
index 56f5256929a0..b57bf76dcb96 100644
--- a/sc/source/core/data/dptabsrc.cxx
+++ b/sc/source/core/data/dptabsrc.cxx
@@ -310,7 +310,7 @@ void ScDPSource::SetDupCount( tools::Long nNew )
nDupCount = nNew;
}
-ScDPDimension* ScDPSource::AddDuplicated(const OUString& rNewName)
+ScDPDimension* ScDPSource::AddDuplicated(std::u16string_view rNewName)
{
OSL_ENSURE( pDimensions.is(), "AddDuplicated without dimensions?" );
diff --git a/sc/source/core/data/drwlayer.cxx b/sc/source/core/data/drwlayer.cxx
index 3901434df913..477eefead496 100644
--- a/sc/source/core/data/drwlayer.cxx
+++ b/sc/source/core/data/drwlayer.cxx
@@ -2055,7 +2055,7 @@ OUString ScDrawLayer::GetVisibleName( const SdrObject* pObj )
return aName;
}
-static bool IsNamedObject( const SdrObject* pObj, const OUString& rName )
+static bool IsNamedObject( const SdrObject* pObj, std::u16string_view rName )
{
// sal_True if rName is the object's Name or PersistName
// (used to find a named object)
@@ -2065,7 +2065,7 @@ static bool IsNamedObject( const SdrObject* pObj, const OUString& rName )
static_cast<const SdrOle2Obj*>(pObj)->GetPersistName() == rName ) );
}
-SdrObject* ScDrawLayer::GetNamedObject( const OUString& rName, sal_uInt16 nId, SCTAB& rFoundTab ) const
+SdrObject* ScDrawLayer::GetNamedObject( std::u16string_view rName, sal_uInt16 nId, SCTAB& rFoundTab ) const
{
sal_uInt16 nTabCount = GetPageCount();
for (sal_uInt16 nTab=0; nTab<nTabCount; nTab++)
diff --git a/sc/source/core/tool/addincol.cxx b/sc/source/core/tool/addincol.cxx
index fba985930b78..aa6e15111808 100644
--- a/sc/source/core/tool/addincol.cxx
+++ b/sc/source/core/tool/addincol.cxx
@@ -595,7 +595,7 @@ bool ScUnoAddInCollection::GetCalcName( const OUString& rExcelName, OUString& rR
return false;
}
-static bool IsTypeName( const OUString& rName, const uno::Type& rType )
+static bool IsTypeName( std::u16string_view rName, const uno::Type& rType )
{
return rName == rType.getTypeName();
}
@@ -930,7 +930,7 @@ static void lcl_UpdateFunctionList( const ScFunctionList& rFunctionList, const S
}
}
-static const ScAddInArgDesc* lcl_FindArgDesc( const ScUnoAddInFuncData& rFuncData, const OUString& rArgIntName )
+static const ScAddInArgDesc* lcl_FindArgDesc( const ScUnoAddInFuncData& rFuncData, std::u16string_view rArgIntName )
{
tools::Long nArgCount = rFuncData.GetArgumentCount();
const ScAddInArgDesc* pArguments = rFuncData.GetArguments();
diff --git a/sc/source/core/tool/interpr2.cxx b/sc/source/core/tool/interpr2.cxx
index f7fd4a96fbd0..f917e40acae2 100644
--- a/sc/source/core/tool/interpr2.cxx
+++ b/sc/source/core/tool/interpr2.cxx
@@ -2708,7 +2708,7 @@ void ScInterpreter::ScStyle()
}
static ScDdeLink* lcl_GetDdeLink( const sfx2::LinkManager* pLinkMgr,
- const OUString& rA, const OUString& rT, const OUString& rI, sal_uInt8 nM )
+ std::u16string_view rA, std::u16string_view rT, std::u16string_view rI, sal_uInt8 nM )
{
size_t nCount = pLinkMgr->GetLinks().size();
for (size_t i=0; i<nCount; i++ )
diff --git a/sc/source/core/tool/interpr7.cxx b/sc/source/core/tool/interpr7.cxx
index b615830e4e56..fbc403db56a7 100644
--- a/sc/source/core/tool/interpr7.cxx
+++ b/sc/source/core/tool/interpr7.cxx
@@ -241,7 +241,7 @@ void ScInterpreter::ScFilterXML()
}
}
-static ScWebServiceLink* lcl_GetWebServiceLink(const sfx2::LinkManager* pLinkMgr, const OUString& rURL)
+static ScWebServiceLink* lcl_GetWebServiceLink(const sfx2::LinkManager* pLinkMgr, std::u16string_view rURL)
{
size_t nCount = pLinkMgr->GetLinks().size();
for (size_t i=0; i<nCount; ++i)
diff --git a/sc/source/core/tool/userlist.cxx b/sc/source/core/tool/userlist.cxx
index 6d68545e3284..4facfde96b8f 100644
--- a/sc/source/core/tool/userlist.cxx
+++ b/sc/source/core/tool/userlist.cxx
@@ -325,7 +325,7 @@ bool ScUserList::operator!=( const ScUserList& r ) const
return !operator==( r );
}
-bool ScUserList::HasEntry( const OUString& rStr ) const
+bool ScUserList::HasEntry( std::u16string_view rStr ) const
{
return ::std::any_of(maData.begin(), maData.end(),
[&] (std::unique_ptr<ScUserListData> const& pData)
diff --git a/sc/source/filter/excel/xechart.cxx b/sc/source/filter/excel/xechart.cxx
index 95ece38d976d..0b1f109f665c 100644
--- a/sc/source/filter/excel/xechart.cxx
+++ b/sc/source/filter/excel/xechart.cxx
@@ -1953,7 +1953,7 @@ bool XclExpChSeries::ConvertDataSeries(
}
bool XclExpChSeries::ConvertStockSeries( css::uno::Reference< css::chart2::XDataSeries > const & xDataSeries,
- const OUString& rValueRole, sal_uInt16 nGroupIdx, sal_uInt16 nFormatIdx, bool bCloseSymbol )
+ std::u16string_view rValueRole, sal_uInt16 nGroupIdx, sal_uInt16 nFormatIdx, bool bCloseSymbol )
{
bool bOk = false;
Reference< XDataSource > xDataSource( xDataSeries, UNO_QUERY );
@@ -2569,7 +2569,7 @@ void XclExpChTypeGroup::CreateAllStockSeries(
}
bool XclExpChTypeGroup::CreateStockSeries( Reference< XDataSeries > const & xDataSeries,
- const OUString& rValueRole, bool bCloseSymbol )
+ std::u16string_view rValueRole, bool bCloseSymbol )
{
bool bOk = false;
// let chart create series object with correct series index
diff --git a/sc/source/filter/excel/xelink.cxx b/sc/source/filter/excel/xelink.cxx
index 644c7a57a35f..d8b3a954f278 100644
--- a/sc/source/filter/excel/xelink.cxx
+++ b/sc/source/filter/excel/xelink.cxx
@@ -137,7 +137,7 @@ public:
sal_uInt16 InsertEuroTool( const OUString& rName );
/** Inserts a DDE link.
@return The 1-based (Excel-like) list index of the DDE link. */
- sal_uInt16 InsertDde( const OUString& rApplic, const OUString& rTopic, const OUString& rItem );
+ sal_uInt16 InsertDde( std::u16string_view rApplic, std::u16string_view rTopic, const OUString& rItem );
sal_uInt16 InsertExtName( const XclExpSupbook& rSupbook, const OUString& rName, const ScExternalRefCache::TokenArrayRef& rArray );
@@ -148,7 +148,7 @@ public:
private:
/** Returns the 1-based (Excel-like) list index of the external name or 0, if not found. */
- sal_uInt16 GetIndex( const OUString& rName ) const;
+ sal_uInt16 GetIndex( std::u16string_view rName ) const;
/** Appends the passed newly crested external name.
@return The 1-based (Excel-like) list index of the appended name. */
sal_uInt16 AppendNew( XclExpExtNameBase* pExtName );
@@ -300,9 +300,9 @@ public:
explicit XclExpSupbook( const XclExpRoot& rRoot, const OUString& rApplic, const OUString& rTopic );
/** Returns true, if this SUPBOOK contains the passed URL of an external document. */
- bool IsUrlLink( const OUString& rUrl ) const;
+ bool IsUrlLink( std::u16string_view rUrl ) const;
/** Returns true, if this SUPBOOK contains the passed DDE link. */
- bool IsDdeLink( const OUString& rApplic, const OUString& rTopic ) const;
+ bool IsDdeLink( std::u16string_view rApplic, std::u16string_view rTopic ) const;
/** Fills the passed reference log entry with the URL and sheet names. */
void FillRefLogEntry( XclExpRefLogEntry& rRefLogEntry,
sal_uInt16 nFirstSBTab, sal_uInt16 nLastSBTab ) const;
@@ -460,13 +460,13 @@ private:
@param rnIndex (out-param) Returns the list index, if the SUPBOOK exists.
@return True, if the SUPBOOK record exists (out-parameters are valid). */
bool GetSupbookUrl( XclExpSupbookRef& rxSupbook, sal_uInt16& rnIndex,
- const OUString& rUrl ) const;
+ std::u16string_view rUrl ) const;
/** Searches for the SUPBOOK record containing the passed DDE link.
@param rxSupbook (out-param) Returns a reference to the SUPBOOK record, or 0.
@param rnIndex (out-param) Returns the list index, if the SUPBOOK exists.
@return True, if the SUPBOOK record exists (out-parameters are valid). */
bool GetSupbookDde( XclExpSupbookRef& rxSupbook, sal_uInt16& rnIndex,
- const OUString& rApplic, const OUString& rTopic ) const;
+ std::u16string_view rApplic, std::u16string_view rTopic ) const;
/** Appends a new SUPBOOK to the list.
@return The list index of the SUPBOOK record. */
@@ -1090,7 +1090,7 @@ sal_uInt16 XclExpExtNameBuffer::InsertEuroTool( const OUString& rName )
}
sal_uInt16 XclExpExtNameBuffer::InsertDde(
- const OUString& rApplic, const OUString& rTopic, const OUString& rItem )
+ std::u16string_view rApplic, std::u16string_view rTopic, const OUString& rItem )
{
sal_uInt16 nIndex = GetIndex( rItem );
if( nIndex == 0 )
@@ -1128,7 +1128,7 @@ void XclExpExtNameBuffer::SaveXml(XclExpXmlStream& rStrm)
maNameList.SaveXml(rStrm);
}
-sal_uInt16 XclExpExtNameBuffer::GetIndex( const OUString& rName ) const
+sal_uInt16 XclExpExtNameBuffer::GetIndex( std::u16string_view rName ) const
{
for( size_t nPos = 0, nSize = maNameList.GetSize(); nPos < nSize; ++nPos )
if( maNameList.GetRecord( nPos )->GetName() == rName )
@@ -1562,12 +1562,12 @@ XclExpSupbook::XclExpSupbook( const XclExpRoot& rRoot, const OUString& rApplic,
SetRecSize( 2 + maUrlEncoded.GetSize() );
}
-bool XclExpSupbook::IsUrlLink( const OUString& rUrl ) const
+bool XclExpSupbook::IsUrlLink( std::u16string_view rUrl ) const
{
return (meType == XclSupbookType::Extern || meType == XclSupbookType::Eurotool) && (maUrl == rUrl);
}
-bool XclExpSupbook::IsDdeLink( const OUString& rApplic, const OUString& rTopic ) const
+bool XclExpSupbook::IsDdeLink( std::u16string_view rApplic, std::u16string_view rTopic ) const
{
return (meType == XclSupbookType::Special) && (maUrl == rApplic) && (maDdeTopic == rTopic);
}
@@ -2127,7 +2127,7 @@ bool XclExpSupbookBuffer::HasExternalReferences() const
}
bool XclExpSupbookBuffer::GetSupbookUrl(
- XclExpSupbookRef& rxSupbook, sal_uInt16& rnIndex, const OUString& rUrl ) const
+ XclExpSupbookRef& rxSupbook, sal_uInt16& rnIndex, std::u16string_view rUrl ) const
{
for( size_t nPos = 0, nSize = maSupbookList.GetSize(); nPos < nSize; ++nPos )
{
@@ -2142,7 +2142,7 @@ bool XclExpSupbookBuffer::GetSupbookUrl(
}
bool XclExpSupbookBuffer::GetSupbookDde( XclExpSupbookRef& rxSupbook,
- sal_uInt16& rnIndex, const OUString& rApplic, const OUString& rTopic ) const
+ sal_uInt16& rnIndex, std::u16string_view rApplic, std::u16string_view rTopic ) const
{
for( size_t nPos = 0, nSize = maSupbookList.GetSize(); nPos < nSize; ++nPos )
{
diff --git a/sc/source/filter/excel/xepivot.cxx b/sc/source/filter/excel/xepivot.cxx
index 2a962da3e5ea..7f8ace82683f 100644
--- a/sc/source/filter/excel/xepivot.cxx
+++ b/sc/source/filter/excel/xepivot.cxx
@@ -130,9 +130,9 @@ XclExpPCItem::XclExpPCItem( bool bValue, const OUString& rText ) :
SetBool( bValue, rText );
}
-bool XclExpPCItem::EqualsText( const OUString& rText ) const
+bool XclExpPCItem::EqualsText( std::u16string_view rText ) const
{
- return rText.isEmpty() ? IsEmpty() : (GetText() && (*GetText() == rText));
+ return rText.empty() ? IsEmpty() : (GetText() && (*GetText() == rText));
}
bool XclExpPCItem::EqualsDouble( double fValue ) const
@@ -268,7 +268,7 @@ const XclExpPCItem* XclExpPCField::GetItem( sal_uInt16 nItemIdx ) const
return GetVisItemList().GetRecord( nItemIdx );
}
-sal_uInt16 XclExpPCField::GetItemIndex( const OUString& rItemName ) const
+sal_uInt16 XclExpPCField::GetItemIndex( std::u16string_view rItemName ) const
{
const XclExpPCItemList& rItemList = GetVisItemList();
for( size_t nPos = 0, nSize = rItemList.GetSize(); nPos < nSize; ++nPos )
@@ -961,7 +961,7 @@ sal_uInt16 XclExpPTField::GetLastDataInfoIndex() const
return static_cast< sal_uInt16 >( maDataInfoVec.size() - 1 );
}
-sal_uInt16 XclExpPTField::GetItemIndex( const OUString& rName, sal_uInt16 nDefaultIdx ) const
+sal_uInt16 XclExpPTField::GetItemIndex( std::u16string_view rName, sal_uInt16 nDefaultIdx ) const
{
for( size_t nPos = 0, nSize = maItemList.GetSize(); nPos < nSize; ++nPos )
if( maItemList.GetRecord( nPos )->GetItemName() == rName )
@@ -1144,7 +1144,7 @@ void XclExpPTField::Save( XclExpStream& rStrm )
// private --------------------------------------------------------------------
-XclExpPTItem* XclExpPTField::GetItemAcc( const OUString& rName )
+XclExpPTItem* XclExpPTField::GetItemAcc( std::u16string_view rName )
{
XclExpPTItem* pItem = nullptr;
for( size_t nPos = 0, nSize = maItemList.GetSize(); !pItem && (nPos < nSize); ++nPos )
@@ -1240,7 +1240,7 @@ const XclExpPTField* XclExpPivotTable::GetField( sal_uInt16 nFieldIdx ) const
return (nFieldIdx == EXC_SXIVD_DATA) ? &maDataOrientField : maFieldList.GetRecord( nFieldIdx );
}
-const XclExpPTField* XclExpPivotTable::GetField( const OUString& rName ) const
+const XclExpPTField* XclExpPivotTable::GetField( std::u16string_view rName ) const
{
return const_cast< XclExpPivotTable* >( this )->GetFieldAcc( rName );
}
@@ -1284,7 +1284,7 @@ void XclExpPivotTable::Save( XclExpStream& rStrm )
WriteSxViewEx9( rStrm );
}
-XclExpPTField* XclExpPivotTable::GetFieldAcc( const OUString& rName )
+XclExpPTField* XclExpPivotTable::GetFieldAcc( std::u16string_view rName )
{
XclExpPTField* pField = nullptr;
for( size_t nPos = 0, nSize = maFieldList.GetSize(); !pField && (nPos < nSize); ++nPos )
diff --git a/sc/source/filter/excel/xiname.cxx b/sc/source/filter/excel/xiname.cxx
index 50a16a76cb99..11d1d753963a 100644
--- a/sc/source/filter/excel/xiname.cxx
+++ b/sc/source/filter/excel/xiname.cxx
@@ -287,7 +287,7 @@ void XclImpNameManager::ReadName( XclImpStream& rStrm )
maNameList.push_back( std::make_unique<XclImpName>( rStrm, static_cast< sal_uInt16 >( nCount + 1 ) ) );
}
-const XclImpName* XclImpNameManager::FindName( const OUString& rXclName, SCTAB nScTab ) const
+const XclImpName* XclImpNameManager::FindName( std::u16string_view rXclName, SCTAB nScTab ) const
{
const XclImpName* pGlobalName = nullptr; // a found global name
const XclImpName* pLocalName = nullptr; // a found local name
diff --git a/sc/source/filter/inc/xechart.hxx b/sc/source/filter/inc/xechart.hxx
index 5e45b4d07878..dd2b92b30d0c 100644
--- a/sc/source/filter/inc/xechart.hxx
+++ b/sc/source/filter/inc/xechart.hxx
@@ -713,7 +713,7 @@ public:
/** Converts the passed data series for stock charts. */
bool ConvertStockSeries(
css::uno::Reference< css::chart2::XDataSeries > const & xDataSeries,
- const OUString& rValueRole,
+ std::u16string_view rValueRole,
sal_uInt16 nGroupIdx, sal_uInt16 nFormatIdx, bool bCloseSymbol );
/** Converts the passed error bar settings (called at trend line child series). */
bool ConvertTrendLine( const XclExpChSeries& rParent,
@@ -919,7 +919,7 @@ private:
css::uno::Reference< css::chart2::XDataSeries > const & xDataSeries );
/** Creates a single data series of a stock chart. */
bool CreateStockSeries( css::uno::Reference< css::chart2::XDataSeries > const & xDataSeries,
- const OUString& rValueRole, bool bCloseSymbol );
+ std::u16string_view rValueRole, bool bCloseSymbol );
virtual void WriteBody( XclExpStream& rStrm ) override;
diff --git a/sc/source/filter/inc/xepivot.hxx b/sc/source/filter/inc/xepivot.hxx
index d508e7135c1d..2b6387550ff3 100644
--- a/sc/source/filter/inc/xepivot.hxx
+++ b/sc/source/filter/inc/xepivot.hxx
@@ -45,7 +45,7 @@ public:
sal_uInt16 GetTypeFlag() const { return mnTypeFlag; }
- bool EqualsText( const OUString& rText ) const;
+ bool EqualsText( std::u16string_view rText ) const;
bool EqualsDouble( double fValue ) const;
bool EqualsDateTime( const DateTime& rDateTime ) const;
bool EqualsBool( bool bValue ) const;
@@ -82,7 +82,7 @@ public:
/** Returns the specified pivot cache item (returns visible items in groupings). */
const XclExpPCItem* GetItem( sal_uInt16 nItemIdx ) const;
/** Returns the index of a pivot cache item, or EXC_PC_NOITEM on error. */
- sal_uInt16 GetItemIndex( const OUString& rItemName ) const;
+ sal_uInt16 GetItemIndex( std::u16string_view rItemName ) const;
/** Returns the size an item index needs to write out. */
std::size_t GetIndexSize() const;
@@ -268,7 +268,7 @@ public:
/** Returns the list index of an item by its name.
@param nDefaultIdx This value will be returned, if the item could not be found. */
- sal_uInt16 GetItemIndex( const OUString& rName, sal_uInt16 nDefaultIdx ) const;
+ sal_uInt16 GetItemIndex( std::u16string_view rName, sal_uInt16 nDefaultIdx ) const;
// fill data --------------------------------------------------------------
@@ -292,7 +292,7 @@ public:
private:
/** Returns an item by its name. */
- XclExpPTItem* GetItemAcc( const OUString& rName );
+ XclExpPTItem* GetItemAcc( std::u16string_view rName );
/** Appends a special item describing a field subtotal entry. */
void AppendSubtotalItem( sal_uInt16 nItemType );
@@ -330,7 +330,7 @@ public:
/** Returns a pivot table field by its name. */
const XclExpPTField* GetField( sal_uInt16 nFieldIdx ) const;
/** Returns a pivot table field by its name. */
- const XclExpPTField* GetField( const OUString& rName ) const;
+ const XclExpPTField* GetField( std::u16string_view rName ) const;
/** Returns the data-field-only index of the first data field with the passed name.
@param nDefaultIdx This value will be returned, if the field could not be found. */
@@ -341,7 +341,7 @@ public:
private:
/** Returns a pivot table field by its name. */
- XclExpPTField* GetFieldAcc( const OUString& rName );
+ XclExpPTField* GetFieldAcc( std::u16string_view rName );
/** Returns a pivot table field corresponding to the passed save dimension. */
XclExpPTField* GetFieldAcc( const ScDPSaveDimension& rSaveDim );
diff --git a/sc/source/filter/inc/xiname.hxx b/sc/source/filter/inc/xiname.hxx
index 658d81e195a3..f26d593c5c88 100644
--- a/sc/source/filter/inc/xiname.hxx
+++ b/sc/source/filter/inc/xiname.hxx
@@ -91,7 +91,7 @@ public:
@param nScTab The sheet index for local names or SCTAB_MAX for global names.
If no local name is found, tries to find a matching global name.
@return Pointer to the defined name or 0 on error. */
- const XclImpName* FindName( const OUString& rXclName, SCTAB nScTab ) const;
+ const XclImpName* FindName( std::u16string_view rXclName, SCTAB nScTab ) const;
/** Returns the defined name specified by its Excel index.
@param nXclNameIdx The index of the internal defined name.
diff --git a/sc/source/filter/inc/xlchart.hxx b/sc/source/filter/inc/xlchart.hxx
index 10d481913755..8f5508f65fd3 100644
--- a/sc/source/filter/inc/xlchart.hxx
+++ b/sc/source/filter/inc/xlchart.hxx
@@ -133,19 +133,19 @@ class XclRoot;
#define EXC_CHPROP_WHITEDAY "WhiteDay"
// data series roles
-#define EXC_CHPROP_ROLE_CATEG "categories"
-#define EXC_CHPROP_ROLE_ERRORBARS_NEGX "error-bars-x-negative"
-#define EXC_CHPROP_ROLE_ERRORBARS_NEGY "error-bars-y-negative"
-#define EXC_CHPROP_ROLE_ERRORBARS_POSX "error-bars-x-positive"
-#define EXC_CHPROP_ROLE_ERRORBARS_POSY "error-bars-y-positive"
-#define EXC_CHPROP_ROLE_LABEL "label"
-#define EXC_CHPROP_ROLE_XVALUES "values-x"
-#define EXC_CHPROP_ROLE_YVALUES "values-y"
-#define EXC_CHPROP_ROLE_OPENVALUES "values-first"
-#define EXC_CHPROP_ROLE_CLOSEVALUES "values-last"
-#define EXC_CHPROP_ROLE_LOWVALUES "values-min"
-#define EXC_CHPROP_ROLE_HIGHVALUES "values-max"
-#define EXC_CHPROP_ROLE_SIZEVALUES "values-size"
+#define EXC_CHPROP_ROLE_CATEG u"categories"
+#define EXC_CHPROP_ROLE_ERRORBARS_NEGX u"error-bars-x-negative"
+#define EXC_CHPROP_ROLE_ERRORBARS_NEGY u"error-bars-y-negative"
+#define EXC_CHPROP_ROLE_ERRORBARS_POSX u"error-bars-x-positive"
+#define EXC_CHPROP_ROLE_ERRORBARS_POSY u"error-bars-y-positive"
+#define EXC_CHPROP_ROLE_LABEL u"label"
+#define EXC_CHPROP_ROLE_XVALUES u"values-x"
+#define EXC_CHPROP_ROLE_YVALUES u"values-y"
+#define EXC_CHPROP_ROLE_OPENVALUES u"values-first"
+#define EXC_CHPROP_ROLE_CLOSEVALUES u"values-last"
+#define EXC_CHPROP_ROLE_LOWVALUES u"values-min"
+#define EXC_CHPROP_ROLE_HIGHVALUES u"values-max"
+#define EXC_CHPROP_ROLE_SIZEVALUES u"values-size"
// Constants and Enumerations =================================================
diff --git a/sc/source/filter/oox/condformatbuffer.cxx b/sc/source/filter/oox/condformatbuffer.cxx
index 551cd1585a54..ca28b0ebf818 100644
--- a/sc/source/filter/oox/condformatbuffer.cxx
+++ b/sc/source/filter/oox/condformatbuffer.cxx
@@ -345,7 +345,7 @@ void IconSetRule::importFormula(const OUString& rFormula)
namespace {
-ScIconSetType getType(const OUString& rName)
+ScIconSetType getType(std::u16string_view rName)
{
ScIconSetType eIconSetType = IconSet_3TrafficLights1;
const ScIconSetMap* pIconSetMap = ScIconSetFormat::g_IconSetMap;
diff --git a/sc/source/filter/oox/formulabuffer.cxx b/sc/source/filter/oox/formulabuffer.cxx
index 9d39c831afce..50c3722723f1 100644
--- a/sc/source/filter/oox/formulabuffer.cxx
+++ b/sc/source/filter/oox/formulabuffer.cxx
@@ -57,7 +57,7 @@ public:
explicit CachedTokenArray( const ScDocument& rDoc ) :
maCxt(rDoc, formula::FormulaGrammar::GRAM_OOXML) {}
- Item* get( const ScAddress& rPos, const OUString& rFormula )
+ Item* get( const ScAddress& rPos, std::u16string_view rFormula )
{
// Check if a token array is cached for this column.
ColCacheType::iterator it = maCache.find(rPos.Col());
diff --git a/sc/source/filter/oox/querytablebuffer.cxx b/sc/source/filter/oox/querytablebuffer.cxx
index 883e0cd90041..9ab1c550a14a 100644
--- a/sc/source/filter/oox/querytablebuffer.cxx
+++ b/sc/source/filter/oox/querytablebuffer.cxx
@@ -101,7 +101,7 @@ OUString lclBuildWebQueryTables( const WebPrModel::TablesVector& rTables )
Reference< XAreaLink > lclFindAreaLink(
const Reference< XAreaLinks >& rxAreaLinks, const ScAddress& rDestPos,
- const OUString& rFileUrl, const OUString& rTables, const OUString& rFilterName, const OUString& rFilterOptions )
+ std::u16string_view rFileUrl, std::u16string_view rTables, std::u16string_view rFilterName, std::u16string_view rFilterOptions )
{
try
{
@@ -252,7 +252,7 @@ void QueryTable::finalizeImport()
sal_Int32 nRefreshPeriod = xConnection->getModel().mnInterval * 60;
if( nRefreshPeriod > 0 )
{
- PropertySet aPropSet( lclFindAreaLink( xAreaLinks, aDestRange.aStart, aFileUrl, aTables, aFilterName, /*aFilterOptions*/"" ) );
+ PropertySet aPropSet( lclFindAreaLink( xAreaLinks, aDestRange.aStart, aFileUrl, aTables, aFilterName, /*aFilterOptions*/u"" ) );
aPropSet.setProperty( PROP_RefreshPeriod, nRefreshPeriod );
}
}
diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx
index 1f31e5d52c6d..41218fe5c227 100644
--- a/sc/source/filter/xml/xmlexprt.cxx
+++ b/sc/source/filter/xml/xmlexprt.cxx
@@ -880,7 +880,7 @@ void ScXMLExport::ExportColumns(const sal_Int32 nTable, const ScRange& aColumnHe
void ScXMLExport::ExportExternalRefCacheStyles()
{
sal_Int32 nEntryIndex = GetCellStylesPropertySetMapper()->FindEntryIndex(
- "NumberFormat", XML_NAMESPACE_STYLE, "data-style-name");
+ "NumberFormat", XML_NAMESPACE_STYLE, u"data-style-name");
if (nEntryIndex < 0)
// No entry index for the number format is found.
@@ -929,7 +929,7 @@ namespace {
void handleFont(
std::vector<XMLPropertyState>& rPropStates,
- const SfxPoolItem* p, const rtl::Reference<XMLPropertySetMapper>& xMapper, const OUString& rXMLName )
+ const SfxPoolItem* p, const rtl::Reference<XMLPropertySetMapper>& xMapper, std::u16string_view rXMLName )
{
sal_Int32 nEntryCount = xMapper->GetEntryCount();
@@ -977,13 +977,13 @@ const SvxFieldData* toXMLPropertyStates(
switch (p->Which())
{
case EE_CHAR_FONTINFO:
- handleFont(rPropStates, p, xMapper, "font-name");
+ handleFont(rPropStates, p, xMapper, u"font-name");
break;
case EE_CHAR_FONTINFO_CJK:
- handleFont(rPropStates, p, xMapper, "font-name-asian");
+ handleFont(rPropStates, p, xMapper, u"font-name-asian");
break;
case EE_CHAR_FONTINFO_CTL:
- handleFont(rPropStates, p, xMapper, "font-name-complex");
+ handleFont(rPropStates, p, xMapper, u"font-name-complex");
break;
case EE_CHAR_WEIGHT:
case EE_CHAR_WEIGHT_CJK:
@@ -1018,23 +1018,23 @@ const SvxFieldData* toXMLPropertyStates(
case EE_CHAR_UNDERLINE:
{
// Underline attribute needs to export multiple entries.
- sal_Int32 nIndexStyle = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, "text-underline-style", 0);
+ sal_Int32 nIndexStyle = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, u"text-underline-style", 0);
if (nIndexStyle == -1 || nIndexStyle > nEntryCount)
break;
- sal_Int32 nIndexWidth = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, "text-underline-width", 0);
+ sal_Int32 nIndexWidth = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, u"text-underline-width", 0);
if (nIndexWidth == -1 || nIndexWidth > nEntryCount)
break;
- sal_Int32 nIndexType = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, "text-underline-type", 0);
+ sal_Int32 nIndexType = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, u"text-underline-type", 0);
if (nIndexType == -1 || nIndexType > nEntryCount)
break;
- sal_Int32 nIndexColor = xMapper->FindEntryIndex("CharUnderlineColor", XML_NAMESPACE_STYLE, "text-underline-color");
+ sal_Int32 nIndexColor = xMapper->FindEntryIndex("CharUnderlineColor", XML_NAMESPACE_STYLE, u"text-underline-color");
if (nIndexColor == -1 || nIndexColor > nEntryCount)
break;
- sal_Int32 nIndexHasColor = xMapper->FindEntryIndex("CharUnderlineHasColor", XML_NAMESPACE_STYLE, "text-underline-color");
+ sal_Int32 nIndexHasColor = xMapper->FindEntryIndex("CharUnderlineHasColor", XML_NAMESPACE_STYLE, u"text-underline-color");
if (nIndexHasColor == -1 || nIndexHasColor > nEntryCount)
break;
@@ -1054,23 +1054,23 @@ const SvxFieldData* toXMLPropertyStates(
case EE_CHAR_OVERLINE:
{
// Same with overline. Do just as we do with underline attributes.
- sal_Int32 nIndexStyle = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, "text-overline-style", 0);
+ sal_Int32 nIndexStyle = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, u"text-overline-style", 0);
if (nIndexStyle == -1 || nIndexStyle > nEntryCount)
break;
- sal_Int32 nIndexWidth = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, "text-overline-width", 0);
+ sal_Int32 nIndexWidth = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, u"text-overline-width", 0);
if (nIndexWidth == -1 || nIndexWidth > nEntryCount)
break;
- sal_Int32 nIndexType = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, "text-overline-type", 0);
+ sal_Int32 nIndexType = xMapper->GetEntryIndex(XML_NAMESPACE_STYLE, u"text-overline-type", 0);
if (nIndexType == -1 || nIndexType > nEntryCount)
break;
- sal_Int32 nIndexColor = xMapper->FindEntryIndex("CharOverlineColor", XML_NAMESPACE_STYLE, "text-overline-color");
+ sal_Int32 nIndexColor = xMapper->FindEntryIndex("CharOverlineColor", XML_NAMESPACE_STYLE, u"text-overline-color");
if (nIndexColor == -1 || nIndexColor > nEntryCount)
break;
- sal_Int32 nIndexHasColor = xMapper->FindEntryIndex("CharOverlineHasColor", XML_NAMESPACE_STYLE, "text-overline-color");
+ sal_Int32 nIndexHasColor = xMapper->FindEntryIndex("CharOverlineHasColor", XML_NAMESPACE_STYLE, u"text-overline-color");
if (nIndexHasColor == -1 || nIndexHasColor > nEntryCount)
break;
@@ -1167,11 +1167,11 @@ const SvxFieldData* toXMLPropertyStates(
break;
case EE_CHAR_ESCAPEMENT:
{
- sal_Int32 nIndexEsc = xMapper->FindEntryIndex("CharEscapement", XML_NAMESPACE_STYLE, "text-position");
+ sal_Int32 nIndexEsc = xMapper->FindEntryIndex("CharEscapement", XML_NAMESPACE_STYLE, u"text-position");
if (nIndexEsc == -1 || nIndexEsc > nEntryCount)
break;
- sal_Int32 nIndexEscHeight = xMapper->FindEntryIndex("CharEscapementHeight", XML_NAMESPACE_STYLE, "text-position");
+ sal_Int32 nIndexEscHeight = xMapper->FindEntryIndex("CharEscapementHeight", XML_NAMESPACE_STYLE, u"text-position");
if (nIndexEscHeight == -1 || nIndexEscHeight > nEntryCount)
break;
@@ -1205,22 +1205,22 @@ const SvxFieldData* toXMLPropertyStates(
switch (p->Which())
{
case EE_CHAR_LANGUAGE:
- nIndexLanguage = xMapper->GetEntryIndex( XML_NAMESPACE_FO, "language", 0);
- nIndexCountry = xMapper->GetEntryIndex( XML_NAMESPACE_FO, "country", 0);
- nIndexScript = xMapper->GetEntryIndex( XML_NAMESPACE_FO, "script", 0);
- nIndexTag = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "rfc-language-tag", 0);
+ nIndexLanguage = xMapper->GetEntryIndex( XML_NAMESPACE_FO, u"language", 0);
+ nIndexCountry = xMapper->GetEntryIndex( XML_NAMESPACE_FO, u"country", 0);
+ nIndexScript = xMapper->GetEntryIndex( XML_NAMESPACE_FO, u"script", 0);
+ nIndexTag = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"rfc-language-tag", 0);
break;
case EE_CHAR_LANGUAGE_CJK:
- nIndexLanguage = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "language-asian", 0);
- nIndexCountry = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "country-asian", 0);
- nIndexScript = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "script-asian", 0);
- nIndexTag = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "rfc-language-tag-asian", 0);
+ nIndexLanguage = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"language-asian", 0);
+ nIndexCountry = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"country-asian", 0);
+ nIndexScript = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"script-asian", 0);
+ nIndexTag = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"rfc-language-tag-asian", 0);
break;
case EE_CHAR_LANGUAGE_CTL:
- nIndexLanguage = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "language-complex", 0);
- nIndexCountry = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "country-complex", 0);
- nIndexScript = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "script-complex", 0);
- nIndexTag = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, "rfc-language-tag-complex", 0);
+ nIndexLanguage = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"language-complex", 0);
+ nIndexCountry = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"country-complex", 0);
+ nIndexScript = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"script-complex", 0);
+ nIndexTag = xMapper->GetEntryIndex( XML_NAMESPACE_STYLE, u"rfc-language-tag-complex", 0);
break;
default:
nIndexLanguage = nIndexCountry = nIndexScript = nIndexTag = -1;
diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx
index e29112fab2b1..fb226b7c30ad 100644
--- a/sc/source/filter/xml/xmlimprt.cxx
+++ b/sc/source/filter/xml/xmlimprt.cxx
@@ -1026,7 +1026,7 @@ sal_Int32 ScXMLImport::SetCurrencySymbol(const sal_Int32 nKey, const OUString& r
return nKey;
}
-bool ScXMLImport::IsCurrencySymbol(const sal_Int32 nNumberFormat, const OUString& sCurrentCurrency, const OUString& sBankSymbol)
+bool ScXMLImport::IsCurrencySymbol(const sal_Int32 nNumberFormat, const OUString& sCurrentCurrency, std::u16string_view sBankSymbol)
{
uno::Reference <util::XNumberFormatsSupplier> xNumberFormatsSupplier(GetNumberFormatsSupplier());
if (xNumberFormatsSupplier.is())
diff --git a/sc/source/filter/xml/xmlimprt.hxx b/sc/source/filter/xml/xmlimprt.hxx
index 910617027beb..daae1d3a98ed 100644
--- a/sc/source/filter/xml/xmlimprt.hxx
+++ b/sc/source/filter/xml/xmlimprt.hxx
@@ -355,7 +355,7 @@ public:
ScMyStylesImportHelper* GetStylesImportHelper() { return pStylesImportHelper.get(); }
sal_Int32 SetCurrencySymbol(const sal_Int32 nKey, const OUString& rCurrency);
- bool IsCurrencySymbol(const sal_Int32 nNumberFormat, const OUString& sCurrencySymbol, const OUString& sBankSymbol);
+ bool IsCurrencySymbol(const sal_Int32 nNumberFormat, const OUString& sCurrencySymbol, std::u16string_view sBankSymbol);
void SetType(const css::uno::Reference <css::beans::XPropertySet>& rProperties,
sal_Int32& rNumberFormat,
const sal_Int16 nCellType,
diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx
index a55547cbc12b..42ec6f3e711e 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -986,7 +986,7 @@ void ScCheckListMenuControl::addMember(const OUString& rName, bool bVisible)
maMembers.emplace_back(std::move(aMember));
}
-std::unique_ptr<weld::TreeIter> ScCheckListMenuControl::FindEntry(const weld::TreeIter* pParent, const OUString& sNode)
+std::unique_ptr<weld::TreeIter> ScCheckListMenuControl::FindEntry(const weld::TreeIter* pParent, std::u16string_view sNode)
{
std::unique_ptr<weld::TreeIter> xEntry = mpChecks->make_iterator(pParent);
bool bEntry = pParent ? mpChecks->iter_children(*xEntry) : mpChecks->get_iter_first(*xEntry);
@@ -1051,13 +1051,13 @@ std::unordered_set<OUString> ScCheckListMenuControl::GetAllChecked()
return vResults;
}
-bool ScCheckListMenuControl::IsChecked(const OUString& sName, const weld::TreeIter* pParent)
+bool ScCheckListMenuControl::IsChecked(std::u16string_view sName, const weld::TreeIter* pParent)
{
std::unique_ptr<weld::TreeIter> xEntry = FindEntry(pParent, sName);
return xEntry && mpChecks->get_toggle(*xEntry) == TRISTATE_TRUE;
}
-void ScCheckListMenuControl::CheckEntry(const OUString& sName, const weld::TreeIter* pParent, bool bCheck)
+void ScCheckListMenuControl::CheckEntry(std::u16string_view sName, const weld::TreeIter* pParent, bool bCheck)
{
std::unique_ptr<weld::TreeIter> xEntry = FindEntry(pParent, sName);
if (xEntry)
diff --git a/sc/source/ui/dbgui/pvfundlg.cxx b/sc/source/ui/dbgui/pvfundlg.cxx
index 5af5a68befc7..7d8c7bc42b12 100644
--- a/sc/source/ui/dbgui/pvfundlg.cxx
+++ b/sc/source/ui/dbgui/pvfundlg.cxx
@@ -363,7 +363,7 @@ const OUString& ScDPFunctionDlg::GetBaseItemName(const OUString& rLayoutName) co
return itr == maBaseItemNameMap.end() ? rLayoutName : itr->second;
}
-sal_Int32 ScDPFunctionDlg::FindBaseItemPos( const OUString& rEntry, sal_Int32 nStartPos ) const
+sal_Int32 ScDPFunctionDlg::FindBaseItemPos( std::u16string_view rEntry, sal_Int32 nStartPos ) const
{
sal_Int32 nPos = nStartPos;
bool bFound = false;
@@ -801,7 +801,7 @@ ScDPName ScDPSubtotalOptDlg::GetFieldName(const OUString& rLayoutName) const
}
sal_Int32 ScDPSubtotalOptDlg::FindListBoxEntry(
- const weld::ComboBox& rLBox, const OUString& rEntry, sal_Int32 nStartPos ) const
+ const weld::ComboBox& rLBox, std::u16string_view rEntry, sal_Int32 nStartPos ) const
{
sal_Int32 nPos = nStartPos;
bool bFound = false;
diff --git a/sc/source/ui/dbgui/scuiimoptdlg.cxx b/sc/source/ui/dbgui/scuiimoptdlg.cxx
index f81e3c50794a..9969251729e8 100644
--- a/sc/source/ui/dbgui/scuiimoptdlg.cxx
+++ b/sc/source/ui/dbgui/scuiimoptdlg.cxx
@@ -39,7 +39,7 @@ public:
nDelIdx ( 0 )
{}
- sal_uInt16 GetCode( const OUString& rDelimiter ) const;
+ sal_uInt16 GetCode( std::u16string_view rDelimiter ) const;
OUString GetDelimiter( sal_Unicode nCode ) const;
OUString FirstDel() { nDelIdx = 0; return theDelTab.getToken( 0, cSep, nDelIdx ); }
@@ -51,7 +51,7 @@ private:
sal_Int32 nDelIdx;
};
-sal_uInt16 ScDelimiterTable::GetCode( const OUString& rDel ) const
+sal_uInt16 ScDelimiterTable::GetCode( std::u16string_view rDel ) const
{
if (!theDelTab.isEmpty())
{
diff --git a/sc/source/ui/docshell/arealink.cxx b/sc/source/ui/docshell/arealink.cxx
index 2920ca6ad08d..791c2a3b4085 100644
--- a/sc/source/ui/docshell/arealink.cxx
+++ b/sc/source/ui/docshell/arealink.cxx
@@ -172,8 +172,8 @@ void ScAreaLink::SetSource(const OUString& rDoc, const OUString& rFlt, const OUS
SetName( aNewLinkName );
}
-bool ScAreaLink::IsEqual( const OUString& rFile, const OUString& rFilter, const OUString& rOpt,
- const OUString& rSource, const ScRange& rDest ) const
+bool ScAreaLink::IsEqual( std::u16string_view rFile, std::u16string_view rFilter, std::u16string_view rOpt,
+ std::u16string_view rSource, const ScRange& rDest ) const
{
return aFileName == rFile && aFilterName == rFilter && aOptions == rOpt &&
aSourceArea == rSource && aDestArea.aStart == rDest.aStart;
diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx
index 111fb8262234..50a1ef3ecda3 100644
--- a/sc/source/ui/docshell/docsh4.cxx
+++ b/sc/source/ui/docshell/docsh4.cxx
@@ -146,7 +146,7 @@ IMPL_LINK_NOARG( ScDocShell, ReloadAllLinksHdl, weld::Button&, void )
ScTabViewShell* pViewSh = GetBestViewShell();
SfxViewFrame* pViewFrame = pViewSh ? pViewSh->GetFrame() : nullptr;
if (pViewFrame)
- pViewFrame->RemoveInfoBar("enablecontent");
+ pViewFrame->RemoveInfoBar(u"enablecontent");
SAL_WARN_IF(!pViewFrame, "sc", "expected there to be a ViewFrame");
}
@@ -500,7 +500,7 @@ void ScDocShell::Execute( SfxRequest& rReq )
SfxViewFrame* pViewFrame = pViewSh ? pViewSh->GetFrame() : nullptr;
if (pViewFrame)
{
- pViewFrame->RemoveInfoBar("enablecontent");
+ pViewFrame->RemoveInfoBar(u"enablecontent");
auto pInfoBar = pViewFrame->AppendInfoBar("enablecontent", "", ScResId(STR_RELOAD_TABLES), InfobarType::WARNING);
if (pInfoBar)
{
@@ -1712,7 +1712,7 @@ bool ScDocShell::AdjustPrintZoom( const ScRange& rRange )
return bChange;
}
-void ScDocShell::PageStyleModified( const OUString& rStyleName, bool bApi )
+void ScDocShell::PageStyleModified( std::u16string_view rStyleName, bool bApi )
{
ScDocShellModificator aModificator( *this );
diff --git a/sc/source/ui/docshell/documentlinkmgr.cxx b/sc/source/ui/docshell/documentlinkmgr.cxx
index 1796b02b5434..842c1052bb45 100644
--- a/sc/source/ui/docshell/documentlinkmgr.cxx
+++ b/sc/source/ui/docshell/documentlinkmgr.cxx
@@ -214,7 +214,7 @@ bool DocumentLinkManager::updateDdeOrOleOrWebServiceLinks(weld::Window* pWin)
return bAny;
}
-void DocumentLinkManager::updateDdeLink( const OUString& rAppl, const OUString& rTopic, const OUString& rItem )
+void DocumentLinkManager::updateDdeLink( std::u16string_view rAppl, std::u16string_view rTopic, std::u16string_view rItem )
{
sfx2::LinkManager* pMgr = mpImpl->mpLinkManager;
if (!pMgr)
diff --git a/sc/source/ui/docshell/externalrefmgr.cxx b/sc/source/ui/docshell/externalrefmgr.cxx
index 7c1566472cbc..3243bfb6f6ed 100644
--- a/sc/source/ui/docshell/externalrefmgr.cxx
+++ b/sc/source/ui/docshell/externalrefmgr.cxx
@@ -2687,7 +2687,7 @@ OUString ScExternalRefManager::getOwnDocumentName() const
return pMed->GetName();
}
-bool ScExternalRefManager::isOwnDocument(const OUString& rFile) const
+bool ScExternalRefManager::isOwnDocument(std::u16string_view rFile) const
{
return getOwnDocumentName() == rFile;
}
diff --git a/sc/source/ui/inc/checklistmenu.hxx b/sc/source/ui/inc/checklistmenu.hxx
index eb5c418a3cad..7e54f218cb13 100644
--- a/sc/source/ui/inc/checklistmenu.hxx
+++ b/sc/source/ui/inc/checklistmenu.hxx
@@ -179,17 +179,17 @@ private:
void updateMemberParents(const weld::TreeIter* pLeaf, size_t nIdx);
std::unique_ptr<weld::TreeIter> ShowCheckEntry(const OUString& sName, ScCheckListMember& rMember, bool bShow = true, bool bCheck = true);
- void CheckEntry(const OUString& sName, const weld::TreeIter* pParent, bool bCheck);
+ void CheckEntry(std::u16string_view sName, const weld::TreeIter* pParent, bool bCheck);
void CheckEntry(const weld::TreeIter& rEntry, bool bCheck);
void GetRecursiveChecked(const weld::TreeIter* pEntry, std::unordered_set<OUString>& vOut, OUString& rLabel);
std::unordered_set<OUString> GetAllChecked();
- bool IsChecked(const OUString& sName, const weld::TreeIter* pParent);
+ bool IsChecked(std::u16string_view sName, const weld::TreeIter* pParent);
int GetCheckedEntryCount() const;
void CheckAllChildren(const weld::TreeIter& rEntry, bool bCheck);
void setSelectedMenuItem(size_t nPos, bool bSubMenuTimer);
- std::unique_ptr<weld::TreeIter> FindEntry(const weld::TreeIter* pParent, const OUString& sNode);
+ std::unique_ptr<weld::TreeIter> FindEntry(const weld::TreeIter* pParent, std::u16string_view sNode);
void executeMenuItem(size_t nPos);
diff --git a/sc/source/ui/inc/content.hxx b/sc/source/ui/inc/content.hxx
index 53f234fdd145..ca1e5a1c6e0c 100644
--- a/sc/source/ui/inc/content.hxx
+++ b/sc/source/ui/inc/content.hxx
@@ -158,7 +158,7 @@ public:
void SetManualDoc(const OUString& rName);
void LoadFile(const OUString& rUrl);
void SelectDoc(const OUString& rName);
- void SelectEntryByName(const ScContentId nRoot, const OUString& rName);
+ void SelectEntryByName(const ScContentId nRoot, std::u16string_view rName);
const OUString& GetHiddenTitle() const { return aHiddenTitle; }
diff --git a/sc/source/ui/inc/docsh.hxx b/sc/source/ui/inc/docsh.hxx
index bfdaf85af4b3..80ae6022ba6f 100644
--- a/sc/source/ui/inc/docsh.hxx
+++ b/sc/source/ui/inc/docsh.hxx
@@ -253,7 +253,7 @@ public:
void LoadStylesArgs( ScDocShell& rSource, bool bReplace, bool bCellStyles, bool bPageStyles );
- void PageStyleModified( const OUString& rStyleName, bool bApi );
+ void PageStyleModified( std::u16string_view rStyleName, bool bApi );
void NotifyStyle( const SfxStyleSheetHint& rHint );
void DoAutoStyle( const ScRange& rRange, const OUString& rStyle );
diff --git a/sc/source/ui/inc/drawview.hxx b/sc/source/ui/inc/drawview.hxx
index c484a76e5bef..db52b1914122 100644
--- a/sc/source/ui/inc/drawview.hxx
+++ b/sc/source/ui/inc/drawview.hxx
@@ -113,7 +113,7 @@ public:
void SetMarkedOriginalSize();
void FitToCellSize();
- bool SelectObject( const OUString& rName );
+ bool SelectObject( std::u16string_view rName );
bool HasMarkedControl() const;
bool HasMarkedInternal() const;
@@ -140,9 +140,9 @@ public:
SdrEndTextEditKind ScEndTextEdit(); // calls SetDrawTextUndo(0)
css::uno::Reference< css::datatransfer::XTransferable > CopyToTransferable();
- SdrObject* GetObjectByName(const OUString& rName);
+ SdrObject* GetObjectByName(std::u16string_view rName);
bool GetObjectIsMarked( const SdrObject * pObject );
- void SelectCurrentViewObject( const OUString& rName );
+ void SelectCurrentViewObject( std::u16string_view rName );
// #i123922# helper which checks if a Graphic may be applied to an existing
// SdrObject; if it's a SdrGrafObj the fill will be replaced. If it's a
diff --git a/sc/source/ui/inc/navipi.hxx b/sc/source/ui/inc/navipi.hxx
index 43d48dc74f59..988822a69ee8 100644
--- a/sc/source/ui/inc/navipi.hxx
+++ b/sc/source/ui/inc/navipi.hxx
@@ -138,7 +138,7 @@ private:
void SetCurrentCell( SCCOL nCol, SCROW Row );
void SetCurrentCellStr( const OUString& rName );
void SetCurrentTable( SCTAB nTab );
- void SetCurrentTableStr( const OUString& rName );
+ void SetCurrentTableStr( std::u16string_view rName );
void SetCurrentObject( const OUString& rName );
void SetCurrentDoc( const OUString& rDocName );
void UpdateSelection();
diff --git a/sc/source/ui/inc/pvfundlg.hxx b/sc/source/ui/inc/pvfundlg.hxx
index 4c74ceb4e04e..79bd41f60bd2 100644
--- a/sc/source/ui/inc/pvfundlg.hxx
+++ b/sc/source/ui/inc/pvfundlg.hxx
@@ -67,7 +67,7 @@ private:
const OUString& GetBaseItemName(const OUString& rLayoutName) const;
/** Searches for a listbox entry, starts search at specified position. */
- sal_Int32 FindBaseItemPos( const OUString& rEntry, sal_Int32 nStartPos ) const;
+ sal_Int32 FindBaseItemPos( std::u16string_view rEntry, sal_Int32 nStartPos ) const;
DECL_LINK(SelectHdl, weld::ComboBox&, void);
DECL_LINK(DblClickHdl, weld::TreeView&, bool);
@@ -140,7 +140,7 @@ private:
ScDPName GetFieldName(const OUString& rLayoutName) const;
/** Searches for a listbox entry, starts search at specified position. */
- sal_Int32 FindListBoxEntry( const weld::ComboBox& rLBox, const OUString& rEntry, sal_Int32 nStartPos ) const;
+ sal_Int32 FindListBoxEntry( const weld::ComboBox& rLBox, std::u16string_view rEntry, sal_Int32 nStartPos ) const;
DECL_LINK( RadioClickHdl, weld::Button&, void );
DECL_LINK( CheckHdl, weld::Button&, void );
diff --git a/sc/source/ui/inc/solverutil.hxx b/sc/source/ui/inc/solverutil.hxx
index fd6a8f26b50f..add2b2337e08 100644
--- a/sc/source/ui/inc/solverutil.hxx
+++ b/sc/source/ui/inc/solverutil.hxx
@@ -33,8 +33,8 @@ class ScSolverUtil
public:
static void GetImplementations( css::uno::Sequence<OUString>& rImplNames,
css::uno::Sequence<OUString>& rDescriptions );
- static css::uno::Reference<css::sheet::XSolver> GetSolver( const OUString& rImplName );
- static css::uno::Sequence<css::beans::PropertyValue> GetDefaults( const OUString& rImplName );
+ static css::uno::Reference<css::sheet::XSolver> GetSolver( std::u16string_view rImplName );
+ static css::uno::Sequence<css::beans::PropertyValue> GetDefaults( std::u16string_view rImplName );
};
#endif
diff --git a/sc/source/ui/inc/tabview.hxx b/sc/source/ui/inc/tabview.hxx
index 17809c51fdc8..b07ac0236b0c 100644
--- a/sc/source/ui/inc/tabview.hxx
+++ b/sc/source/ui/inc/tabview.hxx
@@ -493,7 +493,7 @@ public:
void ClearHighlightRanges();
void DoChartSelection( const css::uno::Sequence< css::chart2::data::HighlightedRange > & rHilightRanges );
- void DoDPFieldPopup(OUString const & rPivotTableName, sal_Int32 nDimensionIndex, Point aPoint, Size aSize);
+ void DoDPFieldPopup(std::u16string_view rPivotTableName, sal_Int32 nDimensionIndex, Point aPoint, Size aSize);
tools::Long GetGridWidth( ScHSplitPos eWhich );
tools::Long GetGridHeight( ScVSplitPos eWhich );
diff --git a/sc/source/ui/inc/tabvwsh.hxx b/sc/source/ui/inc/tabvwsh.hxx
index 480f4ca9c73b..1061dbe90a6e 100644
--- a/sc/source/ui/inc/tabvwsh.hxx
+++ b/sc/source/ui/inc/tabvwsh.hxx
@@ -342,7 +342,7 @@ public:
const Point* pInsPos );
void InsertURLField( const OUString& rName, const OUString& rURL, const OUString& rTarget );
- bool SelectObject( const OUString& rName );
+ bool SelectObject( std::u16string_view rName );
void SetInFormatDialog(bool bFlag) {bInFormatDialog=bFlag;}
diff --git a/sc/source/ui/inc/viewfunc.hxx b/sc/source/ui/inc/viewfunc.hxx
index df35741a4f3f..497c09729280 100644
--- a/sc/source/ui/inc/viewfunc.hxx
+++ b/sc/source/ui/inc/viewfunc.hxx
@@ -133,7 +133,7 @@ public:
void PasteDraw();
void PasteDraw( const Point& rLogicPos, SdrModel* pModel, bool bGroup,
- const OUString& rSrcShellID, const OUString& rDestShellID );
+ std::u16string_view rSrcShellID, std::u16string_view rDestShellID );
bool PasteOnDrawObjectLinked(
const css::uno::Reference< css::datatransfer::XTransferable >& rxTransferable,
@@ -279,7 +279,7 @@ public:
void InsertTableLink( const OUString& rFile,
const OUString& rFilter, const OUString& rOptions,
- const OUString& rTabName );
+ std::u16string_view rTabName );
void InsertAreaLink( const OUString& rFile,
const OUString& rFilter, const OUString& rOptions,
const OUString& rSource );
diff --git a/sc/source/ui/miscdlgs/solverutil.cxx b/sc/source/ui/miscdlgs/solverutil.cxx
index e5d045378113..09c7aff18baa 100644
--- a/sc/source/ui/miscdlgs/solverutil.cxx
+++ b/sc/source/ui/miscdlgs/solverutil.cxx
@@ -95,7 +95,7 @@ void ScSolverUtil::GetImplementations( uno::Sequence<OUString>& rImplNames,
}
}
-uno::Reference<sheet::XSolver> ScSolverUtil::GetSolver( const OUString& rImplName )
+uno::Reference<sheet::XSolver> ScSolverUtil::GetSolver( std::u16string_view rImplName )
{
uno::Reference<sheet::XSolver> xSolver;
@@ -133,7 +133,7 @@ uno::Reference<sheet::XSolver> ScSolverUtil::GetSolver( const OUString& rImplNam
return xSolver;
}
-uno::Sequence<beans::PropertyValue> ScSolverUtil::GetDefaults( const OUString& rImplName )
+uno::Sequence<beans::PropertyValue> ScSolverUtil::GetDefaults( std::u16string_view rImplName )
{
uno::Sequence<beans::PropertyValue> aDefaults;
diff --git a/sc/source/ui/navipi/content.cxx b/sc/source/ui/navipi/content.cxx
index 31fce4ea8bb8..6a638f88390f 100644
--- a/sc/source/ui/navipi/content.cxx
+++ b/sc/source/ui/navipi/content.cxx
@@ -1128,7 +1128,7 @@ static bool lcl_GetRange( const ScDocument& rDoc, ScContentId nType, const OUStr
return bFound;
}
-static bool lcl_DoDragObject( ScDocShell* pSrcShell, const OUString& rName, ScContentId nType, weld::TreeView& rTreeView )
+static bool lcl_DoDragObject( ScDocShell* pSrcShell, std::u16string_view rName, ScContentId nType, weld::TreeView& rTreeView )
{
bool bDisallow = true;
@@ -1542,7 +1542,7 @@ void ScContentTree::SelectDoc(const OUString& rName) // rName like shown in
}
}
-void ScContentTree::SelectEntryByName(const ScContentId nRoot, const OUString& rName)
+void ScContentTree::SelectEntryByName(const ScContentId nRoot, std::u16string_view rName)
{
weld::TreeIter* pParent = m_aRootNodes[nRoot].get();
diff --git a/sc/source/ui/navipi/navipi.cxx b/sc/source/ui/navipi/navipi.cxx
index 64b12b05902f..4b7247657e10 100644
--- a/sc/source/ui/navipi/navipi.cxx
+++ b/sc/source/ui/navipi/navipi.cxx
@@ -611,7 +611,7 @@ void ScNavigatorDlg::SetCurrentTable( SCTAB nTabNo )
}
}
-void ScNavigatorDlg::SetCurrentTableStr( const OUString& rName )
+void ScNavigatorDlg::SetCurrentTableStr( std::u16string_view rName )
{
if (!GetViewData()) return;
diff --git a/sc/source/ui/undo/undoblk3.cxx b/sc/source/ui/undo/undoblk3.cxx
index ef0a5eff9738..2080f6e8d4bf 100644
--- a/sc/source/ui/undo/undoblk3.cxx
+++ b/sc/source/ui/undo/undoblk3.cxx
@@ -1462,9 +1462,9 @@ bool ScUndoRefreshLink::CanRepeat(SfxRepeatTarget& /* rTarget */) const
return false;
}
-static ScAreaLink* lcl_FindAreaLink( const sfx2::LinkManager* pLinkManager, const OUString& rDoc,
- const OUString& rFlt, const OUString& rOpt,
- const OUString& rSrc, const ScRange& rDest )
+static ScAreaLink* lcl_FindAreaLink( const sfx2::LinkManager* pLinkManager, std::u16string_view rDoc,
+ std::u16string_view rFlt, std::u16string_view rOpt,
+ std::u16string_view rSrc, const ScRange& rDest )
{
const ::sfx2::SvBaseLinks& rLinks = pLinkManager->GetLinks();
sal_uInt16 nCount = pLinkManager->GetLinks().size();
diff --git a/sc/source/ui/unoobj/ChartTools.cxx b/sc/source/ui/unoobj/ChartTools.cxx
index b1763699334c..b405557d1c8b 100644
--- a/sc/source/ui/unoobj/ChartTools.cxx
+++ b/sc/source/ui/unoobj/ChartTools.cxx
@@ -95,7 +95,7 @@ SdrOle2Obj* ChartIterator::next()
return nullptr;
}
-SdrOle2Obj* findChartsByName(ScDocShell* pDocShell, SCTAB nTab, OUString const & rName, ChartSourceType eChartSourceType)
+SdrOle2Obj* findChartsByName(ScDocShell* pDocShell, SCTAB nTab, std::u16string_view rName, ChartSourceType eChartSourceType)
{
if (!pDocShell)
return nullptr;
@@ -139,7 +139,7 @@ SdrOle2Obj* getChartByIndex(ScDocShell* pDocShell, SCTAB nTab, ::tools::Long nIn
return nullptr;
}
-std::vector<SdrOle2Obj*> getAllPivotChartsConnectedTo(OUString const & sPivotTableName, ScDocShell* pDocShell)
+std::vector<SdrOle2Obj*> getAllPivotChartsConnectedTo(std::u16string_view sPivotTableName, ScDocShell* pDocShell)
{
std::vector<SdrOle2Obj*> aObjects;
diff --git a/sc/source/ui/unoobj/afmtuno.cxx b/sc/source/ui/unoobj/afmtuno.cxx
index 177e7572fad2..9516b92e570c 100644
--- a/sc/source/ui/unoobj/afmtuno.cxx
+++ b/sc/source/ui/unoobj/afmtuno.cxx
@@ -131,7 +131,7 @@ SC_SIMPLE_SERVICE_INFO( ScAutoFormatFieldObj, "ScAutoFormatFieldObj", "com.sun.s
SC_SIMPLE_SERVICE_INFO( ScAutoFormatObj, "ScAutoFormatObj", "com.sun.star.sheet.TableAutoFormat" )
SC_SIMPLE_SERVICE_INFO( ScAutoFormatsObj, "stardiv.StarCalc.ScAutoFormatsObj", SCAUTOFORMATSOBJ_SERVICE )
-static bool lcl_FindAutoFormatIndex( const ScAutoFormat& rFormats, const OUString& rName, sal_uInt16& rOutIndex )
+static bool lcl_FindAutoFormatIndex( const ScAutoFormat& rFormats, std::u16string_view rName, sal_uInt16& rOutIndex )
{
ScAutoFormat::const_iterator itBeg = rFormats.begin(), itEnd = rFormats.end();
for (ScAutoFormat::const_iterator it = itBeg; it != itEnd; ++it)
@@ -176,7 +176,7 @@ ScAutoFormatObj* ScAutoFormatsObj::GetObjectByIndex_Impl(sal_uInt16 nIndex)
return nullptr; // wrong index
}
-ScAutoFormatObj* ScAutoFormatsObj::GetObjectByName_Impl(const OUString& aName)
+ScAutoFormatObj* ScAutoFormatsObj::GetObjectByName_Impl(std::u16string_view aName)
{
sal_uInt16 nIndex;
if (lcl_FindAutoFormatIndex(
diff --git a/sc/source/ui/unoobj/cellsuno.cxx b/sc/source/ui/unoobj/cellsuno.cxx
index 7ab5335529b2..4b8613fc30be 100644
--- a/sc/source/ui/unoobj/cellsuno.cxx
+++ b/sc/source/ui/unoobj/cellsuno.cxx
@@ -4223,7 +4223,7 @@ void SAL_CALL ScCellRangesObj::removeRangeAddresses( const uno::Sequence<table::
// XNameContainer
-static void lcl_RemoveNamedEntry( ScNamedEntryArr_Impl& rNamedEntries, const OUString& rName )
+static void lcl_RemoveNamedEntry( ScNamedEntryArr_Impl& rNamedEntries, std::u16string_view rName )
{
sal_uInt16 nCount = rNamedEntries.size();
for ( sal_uInt16 n=nCount; n--; )
@@ -4283,7 +4283,7 @@ void SAL_CALL ScCellRangesObj::insertByName( const OUString& aName, const uno::A
}
static bool lcl_FindRangeByName( const ScRangeList& rRanges, ScDocShell* pDocSh,
- const OUString& rName, size_t& rIndex )
+ std::u16string_view rName, size_t& rIndex )
{
if (pDocSh)
{
diff --git a/sc/source/ui/unoobj/dapiuno.cxx b/sc/source/ui/unoobj/dapiuno.cxx
index 76ae587cba03..d848b05ceb2f 100644
--- a/sc/source/ui/unoobj/dapiuno.cxx
+++ b/sc/source/ui/unoobj/dapiuno.cxx
@@ -245,7 +245,7 @@ void ScDataPilotConversion::FillGroupInfo( DataPilotFieldGroupInfo& rInfo, const
rInfo.Step = rGroupInfo.mfStep;
}
-static ScDPObject* lcl_GetDPObject( ScDocShell* pDocShell, SCTAB nTab, const OUString& rName )
+static ScDPObject* lcl_GetDPObject( ScDocShell* pDocShell, SCTAB nTab, std::u16string_view rName )
{
if (pDocShell)
{
diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx
index 1fbbf37ac812..c677e3639fb1 100644
--- a/sc/source/ui/unoobj/docuno.cxx
+++ b/sc/source/ui/unoobj/docuno.cxx
@@ -4630,7 +4630,7 @@ void ScScenariosObj::Notify( SfxBroadcaster&, const SfxHint& rHint )
// XScenarios
-bool ScScenariosObj::GetScenarioIndex_Impl( const OUString& rName, SCTAB& rIndex )
+bool ScScenariosObj::GetScenarioIndex_Impl( std::u16string_view rName, SCTAB& rIndex )
{
//! Case-insensitive ????
@@ -4660,7 +4660,7 @@ ScTableSheetObj* ScScenariosObj::GetObjectByIndex_Impl(sal_Int32 nIndex)
return nullptr; // no document or wrong index
}
-ScTableSheetObj* ScScenariosObj::GetObjectByName_Impl(const OUString& aName)
+ScTableSheetObj* ScScenariosObj::GetObjectByName_Impl(std::u16string_view aName)
{
SCTAB nIndex;
if ( pDocShell && GetScenarioIndex_Impl( aName, nIndex ) )
diff --git a/sc/source/ui/unoobj/eventuno.cxx b/sc/source/ui/unoobj/eventuno.cxx
index 3aab2004dd66..c1d37d1d4490 100644
--- a/sc/source/ui/unoobj/eventuno.cxx
+++ b/sc/source/ui/unoobj/eventuno.cxx
@@ -53,7 +53,7 @@ void ScSheetEventsObj::Notify( SfxBroadcaster&, const SfxHint& rHint )
}
}
-static ScSheetEventId lcl_GetEventFromName( const OUString& aName )
+static ScSheetEventId lcl_GetEventFromName( std::u16string_view aName )
{
for (sal_Int32 nEvent=0; nEvent<static_cast<sal_Int32>(ScSheetEventId::COUNT); ++nEvent)
if ( aName == ScSheetEvents::GetEventName(static_cast<ScSheetEventId>(nEvent)) )
diff --git a/sc/source/ui/unoobj/linkuno.cxx b/sc/source/ui/unoobj/linkuno.cxx
index 46a0755d802b..b4c45d5360d4 100644
--- a/sc/source/ui/unoobj/linkuno.cxx
+++ b/sc/source/ui/unoobj/linkuno.cxx
@@ -1218,7 +1218,7 @@ ScDDELinkObj* ScDDELinksObj::GetObjectByIndex_Impl(sal_Int32 nIndex)
return nullptr;
}
-ScDDELinkObj* ScDDELinksObj::GetObjectByName_Impl(const OUString& aName)
+ScDDELinkObj* ScDDELinksObj::GetObjectByName_Impl(std::u16string_view aName)
{
if (pDocShell)
{
diff --git a/sc/source/ui/vba/vbaworksheet.cxx b/sc/source/ui/vba/vbaworksheet.cxx
index a2caa3fb3a77..f856ff0087bd 100644
--- a/sc/source/ui/vba/vbaworksheet.cxx
+++ b/sc/source/ui/vba/vbaworksheet.cxx
@@ -943,7 +943,7 @@ ScVbaWorksheet::hasProperty( const OUString& aName )
}
uno::Any
-ScVbaWorksheet::getControlShape( const OUString& sName )
+ScVbaWorksheet::getControlShape( std::u16string_view sName )
{
// ideally we would get an XControl object but it appears an XControl
// implementation only exists for a Control implementation obtained from the
diff --git a/sc/source/ui/vba/vbaworksheet.hxx b/sc/source/ui/vba/vbaworksheet.hxx
index a582c7858ba4..784d08b74db3 100644
--- a/sc/source/ui/vba/vbaworksheet.hxx
+++ b/sc/source/ui/vba/vbaworksheet.hxx
@@ -56,7 +56,7 @@ class ScVbaWorksheet : public WorksheetImpl_BASE
css::uno::Reference< ov::excel::XRange > getSheetRange();
css::uno::Reference< css::container::XNameAccess > getFormControls() const;
- css::uno::Any getControlShape( const OUString& sName );
+ css::uno::Any getControlShape( std::u16string_view sName );
css::uno::Any getButtons( const css::uno::Any &rIndex, bool bOptionButtons );
diff --git a/sc/source/ui/vba/vbaworksheets.cxx b/sc/source/ui/vba/vbaworksheets.cxx
index 5ff95d735e72..d1acee975d3c 100644
--- a/sc/source/ui/vba/vbaworksheets.cxx
+++ b/sc/source/ui/vba/vbaworksheets.cxx
@@ -462,7 +462,7 @@ ScVbaWorksheets::getServiceNames()
return sNames;
}
-bool ScVbaWorksheets::nameExists( const uno::Reference <sheet::XSpreadsheetDocument>& xSpreadDoc, const OUString & name, SCTAB& nTab )
+bool ScVbaWorksheets::nameExists( const uno::Reference <sheet::XSpreadsheetDocument>& xSpreadDoc, std::u16string_view name, SCTAB& nTab )
{
if (!xSpreadDoc.is())
throw lang::IllegalArgumentException( "nameExists() xSpreadDoc is null", uno::Reference< uno::XInterface >(), 1 );
diff --git a/sc/source/ui/vba/vbaworksheets.hxx b/sc/source/ui/vba/vbaworksheets.hxx
index fdb2400d4c01..54c324db4c76 100644
--- a/sc/source/ui/vba/vbaworksheets.hxx
+++ b/sc/source/ui/vba/vbaworksheets.hxx
@@ -63,7 +63,7 @@ public:
/// @throws css::lang::IllegalArgumentException
/// @throws css::uno::RuntimeException
- static bool nameExists( const css::uno::Reference <css::sheet::XSpreadsheetDocument>& xSpreadDoc, const OUString & name, SCTAB& nTab );
+ static bool nameExists( const css::uno::Reference <css::sheet::XSpreadsheetDocument>& xSpreadDoc, std::u16string_view name, SCTAB& nTab );
};
#endif // INCLUDED_SC_SOURCE_UI_VBA_VBAWORKSHEETS_HXX
diff --git a/sc/source/ui/view/dbfunc3.cxx b/sc/source/ui/view/dbfunc3.cxx
index f7a79a173e0f..60a57777c073 100644
--- a/sc/source/ui/view/dbfunc3.cxx
+++ b/sc/source/ui/view/dbfunc3.cxx
@@ -1332,7 +1332,7 @@ void ScDBFunc::UngroupDataPilot()
Unmark();
}
-static OUString lcl_replaceMemberNameInSubtotal(const OUString& rSubtotal, const OUString& rMemberName)
+static OUString lcl_replaceMemberNameInSubtotal(const OUString& rSubtotal, std::u16string_view rMemberName)
{
sal_Int32 n = rSubtotal.getLength();
const sal_Unicode* p = rSubtotal.getStr();
diff --git a/sc/source/ui/view/drawview.cxx b/sc/source/ui/view/drawview.cxx
index c589e661e88c..7b213050bf31 100644
--- a/sc/source/ui/view/drawview.cxx
+++ b/sc/source/ui/view/drawview.cxx
@@ -645,7 +645,7 @@ void ScDrawView::UpdateUserViewOptions()
rGrid.GetFieldDrawY() / (rGrid.GetFieldDivisionY() + 1) ) );
}
-SdrObject* ScDrawView::GetObjectByName(const OUString& rName)
+SdrObject* ScDrawView::GetObjectByName(std::u16string_view rName)
{
SfxObjectShell* pShell = rDoc.GetDocumentShell();
if (pShell)
@@ -676,7 +676,7 @@ SdrObject* ScDrawView::GetObjectByName(const OUString& rName)
//realize multi-selection of objects
-void ScDrawView::SelectCurrentViewObject( const OUString& rName )
+void ScDrawView::SelectCurrentViewObject( std::u16string_view rName )
{
sal_uInt16 nObjectTab = 0;
SdrObject* pFound = nullptr;
@@ -727,7 +727,7 @@ void ScDrawView::SelectCurrentViewObject( const OUString& rName )
MarkObj( pFound, pPV, bUnMark);
}
-bool ScDrawView::SelectObject( const OUString& rName )
+bool ScDrawView::SelectObject( std::u16string_view rName )
{
UnmarkAll();
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 34d3ed07be21..e817730ed97e 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -4453,7 +4453,7 @@ sal_Int8 ScGridWindow::ExecuteDrop( const ExecuteDropEvent& rEvt )
bPasteIsMove = bIsMove;
mrViewData.GetView()->PasteDraw(
- aLogicPos, rData.pDrawTransfer->GetModel(), false, "A", "B");
+ aLogicPos, rData.pDrawTransfer->GetModel(), false, u"A", u"B");
if (bPasteIsMove)
rData.pDrawTransfer->SetDragWasInternal();
diff --git a/sc/source/ui/view/tabview3.cxx b/sc/source/ui/view/tabview3.cxx
index 214f5a02ca3d..4f3d2eaec6b0 100644
--- a/sc/source/ui/view/tabview3.cxx
+++ b/sc/source/ui/view/tabview3.cxx
@@ -2598,7 +2598,7 @@ void ScTabView::DoChartSelection(
ScInputHandler::SendReferenceMarks( aViewData.GetViewShell(), aReferenceMarks );
}
-void ScTabView::DoDPFieldPopup(OUString const & rPivotTableName, sal_Int32 nDimensionIndex, Point aPoint, Size aSize)
+void ScTabView::DoDPFieldPopup(std::u16string_view rPivotTableName, sal_Int32 nDimensionIndex, Point aPoint, Size aSize)
{
ScDocument& rDocument = aViewData.GetDocShell()->GetDocument();
ScGridWindow* pWin = pGridWin[aViewData.GetActivePart()].get();
diff --git a/sc/source/ui/view/tabvwsh2.cxx b/sc/source/ui/view/tabvwsh2.cxx
index 5a7bcc2088b6..83f47834c0b6 100644
--- a/sc/source/ui/view/tabvwsh2.cxx
+++ b/sc/source/ui/view/tabvwsh2.cxx
@@ -445,7 +445,7 @@ void ScTabViewShell::GetDrawState(SfxItemSet &rSet)
}
}
-bool ScTabViewShell::SelectObject( const OUString& rName )
+bool ScTabViewShell::SelectObject( std::u16string_view rName )
{
ScDrawView* pView = GetViewData().GetScDrawView();
if (!pView)
diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx
index 72e6a72707ab..b6e401991684 100644
--- a/sc/source/ui/view/tabvwsh3.cxx
+++ b/sc/source/ui/view/tabvwsh3.cxx
@@ -623,7 +623,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
// First make sure that the sidebar is visible
pThisFrame->ShowChildWindow(SID_SIDEBAR);
- ::sfx2::sidebar::Sidebar::ShowPanel("ScFunctionsPanel",
+ ::sfx2::sidebar::Sidebar::ShowPanel(u"ScFunctionsPanel",
pThisFrame->GetFrame().GetFrameInterface());
rReq.Done ();
}
diff --git a/sc/source/ui/view/tabvwsh9.cxx b/sc/source/ui/view/tabvwsh9.cxx
index 740f6af4cfad..7bf98acce6a4 100644
--- a/sc/source/ui/view/tabvwsh9.cxx
+++ b/sc/source/ui/view/tabvwsh9.cxx
@@ -53,7 +53,7 @@ void ScTabViewShell::ExecChildWin(const SfxRequest& rReq)
GetViewFrame()->ShowChildWindow(SID_SIDEBAR);
::sfx2::sidebar::Sidebar::ShowPanel(
- "GalleryPanel",
+ u"GalleryPanel",
GetViewFrame()->GetFrame().GetFrameInterface());
}
break;
diff --git a/sc/source/ui/view/tabvwsha.cxx b/sc/source/ui/view/tabvwsha.cxx
index 4a6062fddff5..d6f2884ec182 100644
--- a/sc/source/ui/view/tabvwsha.cxx
+++ b/sc/source/ui/view/tabvwsha.cxx
@@ -341,7 +341,7 @@ void ScTabViewShell::GetState( SfxItemSet& rSet )
case FID_FUNCTION_BOX:
{
- const bool bBoxOpen = ::sfx2::sidebar::Sidebar::IsPanelVisible("ScFunctionsPanel",
+ const bool bBoxOpen = ::sfx2::sidebar::Sidebar::IsPanelVisible(u"ScFunctionsPanel",
pThisFrame->GetFrame().GetFrameInterface());
rSet.Put(SfxBoolItem(nWhich, bBoxOpen));
break;
diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx
index 9bad80bb01d0..92452d24f71d 100644
--- a/sc/source/ui/view/viewfun2.cxx
+++ b/sc/source/ui/view/viewfun2.cxx
@@ -2636,7 +2636,7 @@ void ScViewFunc::InsertAreaLink( const OUString& rFile,
void ScViewFunc::InsertTableLink( const OUString& rFile,
const OUString& rFilter, const OUString& rOptions,
- const OUString& rTabName )
+ std::u16string_view rTabName )
{
OUString aFilterName = rFilter;
OUString aOpt = rOptions;
@@ -2647,7 +2647,7 @@ void ScViewFunc::InsertTableLink( const OUString& rFile,
ScDocShell* pSrcSh = aLoader.GetDocShell();
ScDocument& rSrcDoc = pSrcSh->GetDocument();
SCTAB nTab = MAXTAB+1;
- if (rTabName.isEmpty()) // no name given -> first table
+ if (rTabName.empty()) // no name given -> first table
nTab = 0;
else
{
diff --git a/sc/source/ui/view/viewfun5.cxx b/sc/source/ui/view/viewfun5.cxx
index 90429fbde4e4..f85fbf75d6bd 100644
--- a/sc/source/ui/view/viewfun5.cxx
+++ b/sc/source/ui/view/viewfun5.cxx
@@ -547,7 +547,7 @@ bool ScViewFunc::PasteDataFormat( SotClipboardFormatId nFormatId,
nObjCount += pPage->GetObjCount(); // count group object only once
}
- PasteDraw(aPos, pModel.get(), (nObjCount > 1), "A", "B"); // grouped if more than 1 object
+ PasteDraw(aPos, pModel.get(), (nObjCount > 1), u"A", u"B"); // grouped if more than 1 object
pModel.reset();
aDragShellRef->DoClose();
bRet = true;
diff --git a/sc/source/ui/view/viewfun7.cxx b/sc/source/ui/view/viewfun7.cxx
index c1b93d0799b0..d58c4300a684 100644
--- a/sc/source/ui/view/viewfun7.cxx
+++ b/sc/source/ui/view/viewfun7.cxx
@@ -70,7 +70,7 @@ static void lcl_AdjustInsertPos( ScViewData& rData, Point& rPos, const Size& rSi
}
void ScViewFunc::PasteDraw( const Point& rLogicPos, SdrModel* pModel,
- bool bGroup, const OUString& rSrcShellID, const OUString& rDestShellID )
+ bool bGroup, std::u16string_view rSrcShellID, std::u16string_view rDestShellID )
{
bool bSameDocClipboard = rSrcShellID == rDestShellID;
diff --git a/scaddins/source/analysis/analysishelper.hxx b/scaddins/source/analysis/analysishelper.hxx
index 26c9a668ed49..6a8c3bb87ab9 100644
--- a/scaddins/source/analysis/analysishelper.hxx
+++ b/scaddins/source/analysis/analysishelper.hxx
@@ -223,7 +223,7 @@ public:
inline const OUString& GetSuffix() const;
sal_uInt16 GetStrIndex( sal_uInt16 nParamNum ) const;
- inline bool Is( const OUString& rCompareTo ) const;
+ inline bool Is( std::u16string_view rCompareTo ) const;
inline const std::vector<OUString> &
GetCompNameList() const;
@@ -618,7 +618,7 @@ inline const OUString& FuncData::GetSuffix() const
}
-inline bool FuncData::Is( const OUString& r ) const
+inline bool FuncData::Is( std::u16string_view r ) const
{
return aIntName == r;
}
diff --git a/scaddins/source/datefunc/datefunc.hxx b/scaddins/source/datefunc/datefunc.hxx
index 590ac64ceec1..666b221b81db 100644
--- a/scaddins/source/datefunc/datefunc.hxx
+++ b/scaddins/source/datefunc/datefunc.hxx
@@ -77,7 +77,7 @@ public:
bool IsDouble() const { return bDouble; }
sal_uInt16 GetStrIndex( sal_uInt16 nParam ) const;
- bool Is( const OUString& rCompare ) const
+ bool Is( std::u16string_view rCompare ) const
{ return aIntName == rCompare; }
const std::vector<OUString>& GetCompNameList() const { return aCompList; }
diff --git a/scaddins/source/pricing/pricing.hxx b/scaddins/source/pricing/pricing.hxx
index 9fe391f349ef..ffc13499831d 100644
--- a/scaddins/source/pricing/pricing.hxx
+++ b/scaddins/source/pricing/pricing.hxx
@@ -92,7 +92,7 @@ public:
bool IsDouble() const { return bDouble; }
sal_uInt16 GetStrIndex( sal_uInt16 nParam ) const;
- bool Is( const OUString& rCompare ) const
+ bool Is( std::u16string_view rCompare ) const
{ return aIntName == rCompare; }
const std::vector<OUString>& GetCompNameList() const { return aCompList; }
diff --git a/sd/inc/CustomAnimationEffect.hxx b/sd/inc/CustomAnimationEffect.hxx
index e4af8b713aa5..59c29717995a 100644
--- a/sd/inc/CustomAnimationEffect.hxx
+++ b/sd/inc/CustomAnimationEffect.hxx
@@ -127,8 +127,8 @@ public:
SAL_DLLPRIVATE bool getAutoReverse() const { return mbAutoReverse; }
SAL_DLLPRIVATE void setAutoReverse( bool bAutoReverse );
- SAL_DLLPRIVATE css::uno::Any getProperty( sal_Int32 nNodeType, const OUString& rAttributeName, EValue eValue );
- SAL_DLLPRIVATE bool setProperty( sal_Int32 nNodeType, const OUString& rAttributeName, EValue eValue, const css::uno::Any& rValue );
+ SAL_DLLPRIVATE css::uno::Any getProperty( sal_Int32 nNodeType, std::u16string_view rAttributeName, EValue eValue );
+ SAL_DLLPRIVATE bool setProperty( sal_Int32 nNodeType, std::u16string_view rAttributeName, EValue eValue, const css::uno::Any& rValue );
SAL_DLLPRIVATE css::uno::Any getTransformationProperty( sal_Int32 nTransformType, EValue eValue );
SAL_DLLPRIVATE bool setTransformationProperty( sal_Int32 nTransformType, EValue eValue, const css::uno::Any& rValue );
diff --git a/sd/inc/CustomAnimationPreset.hxx b/sd/inc/CustomAnimationPreset.hxx
index b05f1675c6a7..e2739fd3213c 100644
--- a/sd/inc/CustomAnimationPreset.hxx
+++ b/sd/inc/CustomAnimationPreset.hxx
@@ -53,7 +53,7 @@ public:
std::vector<OUString> getSubTypes();
std::vector<OUString> getProperties() const;
- bool hasProperty( const OUString& rProperty ) const;
+ bool hasProperty( std::u16string_view rProperty ) const;
bool isTextOnly() const { return mbIsTextOnly; }
private:
diff --git a/sd/inc/drawdoc.hxx b/sd/inc/drawdoc.hxx
index 2d05e269ff58..e18a1492ea4b 100644
--- a/sd/inc/drawdoc.hxx
+++ b/sd/inc/drawdoc.hxx
@@ -355,7 +355,7 @@ public:
void CloseBookmarkDoc();
- SAL_DLLPRIVATE SdrObject* GetObj(const OUString& rObjName) const;
+ SAL_DLLPRIVATE SdrObject* GetObj(std::u16string_view rObjName) const;
/** Return the first page that has the given name. Regular pages and
notes pages are searched first. When not found then the master
@@ -370,14 +370,14 @@ public:
Returns the index of the page with the given name or
SDRPAGE_NOTFOUND (=0xffff) when such a page does not exist.
*/
- SAL_DLLPRIVATE sal_uInt16 GetPageByName(const OUString& rPgName, bool& rbIsMasterPage ) const;
+ SAL_DLLPRIVATE sal_uInt16 GetPageByName(std::u16string_view rPgName, bool& rbIsMasterPage ) const;
/** checks, if the given name is a *unique* name for an *existing* slide
@param rPageName the name of an existing slide
@return true, if the name is unique and the slide exists
*/
- bool IsPageNameUnique( const OUString& rPageName ) const;
+ bool IsPageNameUnique( std::u16string_view rPageName ) const;
SdPage*GetSdPage(sal_uInt16 nPgNum, PageKind ePgKind) const;
sal_uInt16 GetSdPageCount(PageKind ePgKind) const;
diff --git a/sd/qa/unit/export-tests.cxx b/sd/qa/unit/export-tests.cxx
index e54e02ddecd5..cc883a8fb019 100644
--- a/sd/qa/unit/export-tests.cxx
+++ b/sd/qa/unit/export-tests.cxx
@@ -570,7 +570,7 @@ void SdExportTest::testUnknownAttributes()
// TODO: if the namespace is *known*, the attribute is not preserved, but that seems to be a pre-existing problem, or maybe it's even intentional?
// assertXPath(pXmlDoc, "/office:document-content/office:automatic-styles/style:style[@style:name='gr1']/style:graphic-properties[@svg:non-existent-att='blah']");
// this was on style:graphic-properties on the import, but the export moves it to root node which is OK
- assertXPathNSDef(pXmlDoc, "/office:document-content", "foo", "http://example.com/");
+ assertXPathNSDef(pXmlDoc, "/office:document-content", u"foo", u"http://example.com/");
}
void SdExportTest::testTdf80020()
diff --git a/sd/qa/unit/tiledrendering/tiledrendering.cxx b/sd/qa/unit/tiledrendering/tiledrendering.cxx
index 1aba4c65a77a..c9bd05d737d4 100644
--- a/sd/qa/unit/tiledrendering/tiledrendering.cxx
+++ b/sd/qa/unit/tiledrendering/tiledrendering.cxx
@@ -2309,7 +2309,7 @@ void SdTiledRenderingTest::testTdf115873()
pNavigator->InitTreeLB(pXImpressDocument->GetDoc());
pNavigator->Show();
SdPageObjsTLV& rObjects = pNavigator->GetObjects();
- rObjects.SelectEntry("Slide 1");
+ rObjects.SelectEntry(u"Slide 1");
rObjects.Select();
sd::ViewShell* pSdViewShell = pXImpressDocument->GetDocShell()->GetViewShell();
SdrView* pSdrView = pSdViewShell->GetView();
@@ -2323,7 +2323,7 @@ void SdTiledRenderingTest::testTdf115873()
// Single-click with the mouse.
MouseEvent aMouseEvent(Point(0, 0), /*nClicks=*/1, MouseEventModifiers::NONE, MOUSE_LEFT);
rObjects.MousePressHdl(aMouseEvent);
- rObjects.SelectEntry("Rectangle");
+ rObjects.SelectEntry(u"Rectangle");
rObjects.Select();
rObjects.MouseReleaseHdl(aMouseEvent);
Scheduler::ProcessEventsToIdle();
diff --git a/sd/source/core/CustomAnimationEffect.cxx b/sd/source/core/CustomAnimationEffect.cxx
index ca84ab88285a..492c9c0e45fc 100644
--- a/sd/source/core/CustomAnimationEffect.cxx
+++ b/sd/source/core/CustomAnimationEffect.cxx
@@ -1146,7 +1146,7 @@ void CustomAnimationEffect::setPath( const OUString& rPath )
}
}
-Any CustomAnimationEffect::getProperty( sal_Int32 nNodeType, const OUString& rAttributeName, EValue eValue )
+Any CustomAnimationEffect::getProperty( sal_Int32 nNodeType, std::u16string_view rAttributeName, EValue eValue )
{
Any aProperty;
if( mxNode.is() ) try
@@ -1186,7 +1186,7 @@ Any CustomAnimationEffect::getProperty( sal_Int32 nNodeType, const OUString& rAt
return aProperty;
}
-bool CustomAnimationEffect::setProperty( sal_Int32 nNodeType, const OUString& rAttributeName, EValue eValue, const Any& rValue )
+bool CustomAnimationEffect::setProperty( sal_Int32 nNodeType, std::u16string_view rAttributeName, EValue eValue, const Any& rValue )
{
bool bChanged = false;
if( mxNode.is() ) try
diff --git a/sd/source/core/CustomAnimationPreset.cxx b/sd/source/core/CustomAnimationPreset.cxx
index b40b271d9910..d65d8aebce65 100644
--- a/sd/source/core/CustomAnimationPreset.cxx
+++ b/sd/source/core/CustomAnimationPreset.cxx
@@ -193,7 +193,7 @@ std::vector<OUString> CustomAnimationPreset::getProperties() const
return aPropertyList;
}
-bool CustomAnimationPreset::hasProperty( const OUString& rProperty )const
+bool CustomAnimationPreset::hasProperty( std::u16string_view rProperty )const
{
if (maProperty.isEmpty())
return false;
diff --git a/sd/source/core/drawdoc2.cxx b/sd/source/core/drawdoc2.cxx
index 2a12ebc9a600..c6d663ba2696 100644
--- a/sd/source/core/drawdoc2.cxx
+++ b/sd/source/core/drawdoc2.cxx
@@ -65,7 +65,7 @@ const ::tools::Long PRINT_OFFSET = 30; // see /svx/source/dialog/page.cxx
using namespace com::sun::star;
// Looks up an object by name
-SdrObject* SdDrawDocument::GetObj(const OUString& rObjName) const
+SdrObject* SdDrawDocument::GetObj(std::u16string_view rObjName) const
{
SdrObject* pObj = nullptr;
SdrObject* pObjFound = nullptr;
@@ -125,7 +125,7 @@ SdrObject* SdDrawDocument::GetObj(const OUString& rObjName) const
}
// Find SdPage by name
-sal_uInt16 SdDrawDocument::GetPageByName(const OUString& rPgName, bool& rbIsMasterPage) const
+sal_uInt16 SdDrawDocument::GetPageByName(std::u16string_view rPgName, bool& rbIsMasterPage) const
{
SdPage* pPage = nullptr;
sal_uInt16 nPage = 0;
@@ -172,7 +172,7 @@ sal_uInt16 SdDrawDocument::GetPageByName(const OUString& rPgName, bool& rbIsMast
return nPageNum;
}
-bool SdDrawDocument::IsPageNameUnique( const OUString& rPgName ) const
+bool SdDrawDocument::IsPageNameUnique( std::u16string_view rPgName ) const
{
sal_uInt16 nCount = 0;
SdPage* pPage = nullptr;
diff --git a/sd/source/core/drawdoc3.cxx b/sd/source/core/drawdoc3.cxx
index 02c6054751b2..143b5a47a2fd 100644
--- a/sd/source/core/drawdoc3.cxx
+++ b/sd/source/core/drawdoc3.cxx
@@ -1321,9 +1321,9 @@ void SdDrawDocument::RemoveUnnecessaryMasterPages(SdPage* pMasterPage, bool bOnl
* If rLayoutName is empty, the first master page is used.
*/
// #i121863# factored out functionality
-static bool isMasterPageLayoutNameUnique(const SdDrawDocument& rDoc, const OUString& rCandidate)
+static bool isMasterPageLayoutNameUnique(const SdDrawDocument& rDoc, std::u16string_view rCandidate)
{
- if (rCandidate.isEmpty())
+ if (rCandidate.empty())
{
return false;
}
diff --git a/sd/source/core/stlpool.cxx b/sd/source/core/stlpool.cxx
index 14b2c3fe1ec8..30707c9be125 100644
--- a/sd/source/core/stlpool.cxx
+++ b/sd/source/core/stlpool.cxx
@@ -84,9 +84,9 @@ OUString lcl_findRenamedStyleName(std::vector< std::pair< OUString, OUString > >
return OUString();
}
-SfxStyleSheet *lcl_findStyle(StyleSheetCopyResultVector& rStyles, const OUString& aStyleName)
+SfxStyleSheet *lcl_findStyle(StyleSheetCopyResultVector& rStyles, std::u16string_view aStyleName)
{
- if( aStyleName.isEmpty() )
+ if( aStyleName.empty() )
return nullptr;
for (const auto& a : rStyles)
{
diff --git a/sd/source/filter/eppt/pptexsoundcollection.cxx b/sd/source/filter/eppt/pptexsoundcollection.cxx
index 34e26bd354d0..c4770e6442e9 100644
--- a/sd/source/filter/eppt/pptexsoundcollection.cxx
+++ b/sd/source/filter/eppt/pptexsoundcollection.cxx
@@ -65,7 +65,7 @@ OUString ExSoundEntry::ImplGetExtension() const
return aExtension;
}
-bool ExSoundEntry::IsSameURL(const OUString& rURL) const
+bool ExSoundEntry::IsSameURL(std::u16string_view rURL) const
{
return ( rURL == aSoundURL );
}
diff --git a/sd/source/filter/eppt/pptexsoundcollection.hxx b/sd/source/filter/eppt/pptexsoundcollection.hxx
index a104cd4a7eb3..2e990aba06b2 100644
--- a/sd/source/filter/eppt/pptexsoundcollection.hxx
+++ b/sd/source/filter/eppt/pptexsoundcollection.hxx
@@ -42,7 +42,7 @@ class ExSoundEntry
public:
- bool IsSameURL(const OUString& rURL) const;
+ bool IsSameURL(std::u16string_view rURL) const;
sal_uInt32 GetFileSize( ) const { return nFileSize; };
ExSoundEntry(const OUString& rSoundURL);
diff --git a/sd/source/ui/animations/CustomAnimationPane.cxx b/sd/source/ui/animations/CustomAnimationPane.cxx
index 2e6d511253ee..39ea654879a9 100644
--- a/sd/source/ui/animations/CustomAnimationPane.cxx
+++ b/sd/source/ui/animations/CustomAnimationPane.cxx
@@ -956,7 +956,7 @@ Any CustomAnimationPane::getProperty1Value( sal_Int32 nType, const CustomAnimati
}
case nPropertyTypeFont:
- return pEffect->getProperty( AnimationNodeType::SET, "CharFontName" , EValue::To );
+ return pEffect->getProperty( AnimationNodeType::SET, u"CharFontName" , EValue::To );
case nPropertyTypeCharHeight:
{
@@ -971,7 +971,7 @@ Any CustomAnimationPane::getProperty1Value( sal_Int32 nType, const CustomAnimati
return pEffect->getTransformationProperty( AnimationTransformType::ROTATE, EValue::By);
case nPropertyTypeTransparency:
- return pEffect->getProperty( AnimationNodeType::SET, "Opacity" , EValue::To );
+ return pEffect->getProperty( AnimationNodeType::SET, u"Opacity" , EValue::To );
case nPropertyTypeScale:
return pEffect->getTransformationProperty( AnimationTransformType::SCALE, EValue::By );
@@ -979,9 +979,9 @@ Any CustomAnimationPane::getProperty1Value( sal_Int32 nType, const CustomAnimati
case nPropertyTypeCharDecoration:
{
Sequence< Any > aValues(3);
- aValues[0] = pEffect->getProperty( AnimationNodeType::SET, "CharWeight" , EValue::To );
- aValues[1] = pEffect->getProperty( AnimationNodeType::SET, "CharPosture" , EValue::To );
- aValues[2] = pEffect->getProperty( AnimationNodeType::SET, "CharUnderline" , EValue::To );
+ aValues[0] = pEffect->getProperty( AnimationNodeType::SET, u"CharWeight" , EValue::To );
+ aValues[1] = pEffect->getProperty( AnimationNodeType::SET, u"CharPosture" , EValue::To );
+ aValues[2] = pEffect->getProperty( AnimationNodeType::SET, u"CharUnderline" , EValue::To );
return makeAny( aValues );
}
}
@@ -1027,7 +1027,7 @@ bool CustomAnimationPane::setProperty1Value( sal_Int32 nType, const CustomAnimat
break;
case nPropertyTypeFont:
- bEffectChanged = pEffect->setProperty( AnimationNodeType::SET, "CharFontName" , EValue::To, rValue );
+ bEffectChanged = pEffect->setProperty( AnimationNodeType::SET, u"CharFontName" , EValue::To, rValue );
break;
case nPropertyTypeCharHeight:
@@ -1043,7 +1043,7 @@ bool CustomAnimationPane::setProperty1Value( sal_Int32 nType, const CustomAnimat
break;
case nPropertyTypeTransparency:
- bEffectChanged = pEffect->setProperty( AnimationNodeType::SET, "Opacity" , EValue::To, rValue );
+ bEffectChanged = pEffect->setProperty( AnimationNodeType::SET, u"Opacity" , EValue::To, rValue );
break;
case nPropertyTypeScale:
@@ -1054,9 +1054,9 @@ bool CustomAnimationPane::setProperty1Value( sal_Int32 nType, const CustomAnimat
{
Sequence< Any > aValues(3);
rValue >>= aValues;
- bEffectChanged = pEffect->setProperty( AnimationNodeType::SET, "CharWeight" , EValue::To, aValues[0] );
- bEffectChanged |= pEffect->setProperty( AnimationNodeType::SET, "CharPosture" , EValue::To, aValues[1] );
- bEffectChanged |= pEffect->setProperty( AnimationNodeType::SET, "CharUnderline" , EValue::To, aValues[2] );
+ bEffectChanged = pEffect->setProperty( AnimationNodeType::SET, u"CharWeight" , EValue::To, aValues[0] );
+ bEffectChanged |= pEffect->setProperty( AnimationNodeType::SET, u"CharPosture" , EValue::To, aValues[1] );
+ bEffectChanged |= pEffect->setProperty( AnimationNodeType::SET, u"CharUnderline" , EValue::To, aValues[2] );
}
break;
@@ -1185,17 +1185,17 @@ std::unique_ptr<STLPropertySet> CustomAnimationPane::createSelectionSet()
addValue( pSet, nHandleProperty1Value, getProperty1Value( nType, pEffect ) );
}
- if( pDescriptor->hasProperty( "Accelerate" ) )
+ if( pDescriptor->hasProperty( u"Accelerate" ) )
{
addValue( pSet, nHandleAccelerate, makeAny( pEffect->getAcceleration() ) );
}
- if( pDescriptor->hasProperty( "Decelerate" ) )
+ if( pDescriptor->hasProperty( u"Decelerate" ) )
{
addValue( pSet, nHandleDecelerate, makeAny( pEffect->getDecelerate() ) );
}
- if( pDescriptor->hasProperty( "AutoReverse" ) )
+ if( pDescriptor->hasProperty( u"AutoReverse" ) )
{
addValue( pSet, nHandleAutoReverse, makeAny( pEffect->getAutoReverse() ) );
}
diff --git a/sd/source/ui/annotations/annotationmanager.cxx b/sd/source/ui/annotations/annotationmanager.cxx
index 155862469313..d24897a5c7dd 100644
--- a/sd/source/ui/annotations/annotationmanager.cxx
+++ b/sd/source/ui/annotations/annotationmanager.cxx
@@ -639,7 +639,7 @@ void AnnotationManagerImpl::DeleteAnnotation( const Reference< XAnnotation >& xA
}
}
-void AnnotationManagerImpl::DeleteAnnotationsByAuthor( const OUString& sAuthor )
+void AnnotationManagerImpl::DeleteAnnotationsByAuthor( std::u16string_view sAuthor )
{
if( mpDoc->IsUndoEnabled() )
mpDoc->BegUndo( SdResId( STR_ANNOTATION_UNDO_DELETE ) );
diff --git a/sd/source/ui/annotations/annotationmanagerimpl.hxx b/sd/source/ui/annotations/annotationmanagerimpl.hxx
index 533b6658644c..a00fc0e1882b 100644
--- a/sd/source/ui/annotations/annotationmanagerimpl.hxx
+++ b/sd/source/ui/annotations/annotationmanagerimpl.hxx
@@ -79,7 +79,7 @@ public:
void InsertAnnotation(const OUString& rText);
void DeleteAnnotation( const css::uno::Reference< css::office::XAnnotation >& xAnnotation );
- void DeleteAnnotationsByAuthor( const OUString& sAuthor );
+ void DeleteAnnotationsByAuthor( std::u16string_view sAuthor );
void DeleteAllAnnotations();
void ExecuteAnnotationContextMenu( const css::uno::Reference< css::office::XAnnotation >& xAnnotation, vcl::Window* pParent, const ::tools::Rectangle& rContextRect, bool bButtonMenu = false );
diff --git a/sd/source/ui/dlg/LayerTabBar.cxx b/sd/source/ui/dlg/LayerTabBar.cxx
index c37aa9637885..7b274dd7210f 100644
--- a/sd/source/ui/dlg/LayerTabBar.cxx
+++ b/sd/source/ui/dlg/LayerTabBar.cxx
@@ -113,7 +113,7 @@ void LayerTabBar::SetPageText( sal_uInt16 nPageId, const OUString& rText )
TabBar::SetPageText(nPageId, sLocalizedName);
}
-bool LayerTabBar::IsLocalizedNameOfStandardLayer(const OUString& rName)
+bool LayerTabBar::IsLocalizedNameOfStandardLayer(std::u16string_view rName)
{
return ( rName == SdResId(STR_LAYER_LAYOUT)
|| rName == SdResId(STR_LAYER_CONTROLS)
diff --git a/sd/source/ui/dlg/sdtreelb.cxx b/sd/source/ui/dlg/sdtreelb.cxx
index 780f8a6ce35b..68ca6bdbff69 100644
--- a/sd/source/ui/dlg/sdtreelb.cxx
+++ b/sd/source/ui/dlg/sdtreelb.cxx
@@ -166,11 +166,11 @@ SotClipboardFormatId SdPageObjsTLV::SdPageObjsTransferable::GetListBoxDropFormat
/**
* @return true if children of the specified string are selected
*/
-bool SdPageObjsTLV::HasSelectedChildren( const OUString& rName )
+bool SdPageObjsTLV::HasSelectedChildren( std::u16string_view rName )
{
bool bChildren = false;
- if( !rName.isEmpty() )
+ if( !rName.empty() )
{
std::unique_ptr<weld::TreeIter> xEntry(m_xTreeView->make_iterator());
OUString aTmp;
@@ -216,7 +216,7 @@ void SdPageObjsTLV::SetShowAllShapes (
}
bool SdPageObjsTLV::IsEqualToShapeList(std::unique_ptr<weld::TreeIter>& rEntry, const SdrObjList& rList,
- const OUString& rListName)
+ std::u16string_view rListName)
{
if (!rEntry)
return false;
@@ -1144,11 +1144,11 @@ void SdPageObjsTLV::Fill( const SdDrawDocument* pInDoc, SfxMedium* pInMedium,
/**
* select an entry in TreeLB
*/
-bool SdPageObjsTLV::SelectEntry( const OUString& rName )
+bool SdPageObjsTLV::SelectEntry( std::u16string_view rName )
{
bool bFound = false;
- if (!rName.isEmpty())
+ if (!rName.empty())
{
std::unique_ptr<weld::TreeIter> xEntry(m_xTreeView->make_iterator());
OUString aTmp;
diff --git a/sd/source/ui/docshell/docshel2.cxx b/sd/source/ui/docshell/docshel2.cxx
index 084c0d313359..bfbb92ab61c5 100644
--- a/sd/source/ui/docshell/docshel2.cxx
+++ b/sd/source/ui/docshell/docshel2.cxx
@@ -404,7 +404,7 @@ bool DrawDocShell::IsNewPageNameValid( OUString & rInOutPageName, bool bResetStr
return bCanUseNewName;
}
-bool DrawDocShell::IsPageNameUnique( const OUString & rPageName ) const
+bool DrawDocShell::IsPageNameUnique( std::u16string_view rPageName ) const
{
return mpDoc->IsPageNameUnique(rPageName);
}
diff --git a/sd/source/ui/docshell/docshel3.cxx b/sd/source/ui/docshell/docshel3.cxx
index 8ae543c5c9d5..302f96bf4d96 100644
--- a/sd/source/ui/docshell/docshel3.cxx
+++ b/sd/source/ui/docshell/docshel3.cxx
@@ -109,7 +109,7 @@ static void lcl_setLanguageForObj( SdrObject *pObj, LanguageType nLang, bool bLa
}
}
-static void lcl_setLanguage( const SdDrawDocument *pDoc, const OUString &rLanguage, bool bLanguageNone = false )
+static void lcl_setLanguage( const SdDrawDocument *pDoc, std::u16string_view rLanguage, bool bLanguageNone = false )
{
LanguageType nLang = SvtLanguageTable::GetLanguageType( rLanguage );
@@ -313,9 +313,9 @@ void DrawDocShell::Execute( SfxRequest& rReq )
aNewLangTxt = aNewLangTxt.replaceAt( nPos, aDocumentLangPrefix.getLength(), "" );
if (aNewLangTxt == "LANGUAGE_NONE")
- lcl_setLanguage( pDoc, OUString(), true );
+ lcl_setLanguage( pDoc, u"", true );
else if (aNewLangTxt == "RESET_LANGUAGES")
- lcl_setLanguage( pDoc, OUString() );
+ lcl_setLanguage( pDoc, u"" );
else
lcl_setLanguage( pDoc, aNewLangTxt );
}
diff --git a/sd/source/ui/framework/factories/BasicPaneFactory.cxx b/sd/source/ui/framework/factories/BasicPaneFactory.cxx
index 969981c2c7be..d60476dcaf76 100644
--- a/sd/source/ui/framework/factories/BasicPaneFactory.cxx
+++ b/sd/source/ui/framework/factories/BasicPaneFactory.cxx
@@ -69,7 +69,7 @@ public:
*/
bool mbIsReleased;
- bool CompareURL(const OUString& rsPaneURL) const { return msPaneURL == rsPaneURL; }
+ bool CompareURL(std::u16string_view rsPaneURL) const { return msPaneURL == rsPaneURL; }
bool ComparePane(const Reference<XResource>& rxPane) const { return mxPane == rxPane; }
};
diff --git a/sd/source/ui/func/fuconrec.cxx b/sd/source/ui/func/fuconrec.cxx
index 958ed8042c81..b998191083f9 100644
--- a/sd/source/ui/func/fuconrec.cxx
+++ b/sd/source/ui/func/fuconrec.cxx
@@ -501,9 +501,9 @@ void FuConstructRectangle::Deactivate()
// Update infobar to offer "finish signing".
SfxViewFrame* pFrame = mpViewShell->GetViewFrame();
- if (pFrame && pFrame->HasInfoBarWithID("readonly"))
+ if (pFrame && pFrame->HasInfoBarWithID(u"readonly"))
{
- pFrame->RemoveInfoBar("readonly");
+ pFrame->RemoveInfoBar(u"readonly");
pFrame->AppendReadOnlyInfobar();
}
}
diff --git a/sd/source/ui/inc/DrawDocShell.hxx b/sd/source/ui/inc/DrawDocShell.hxx
index d6639c78a736..9634c3d6c97f 100644
--- a/sd/source/ui/inc/DrawDocShell.hxx
+++ b/sd/source/ui/inc/DrawDocShell.hxx
@@ -183,7 +183,7 @@ public:
@return true, if the name is unique and the slide exists
*/
- bool IsPageNameUnique(const OUString& rPagName) const;
+ bool IsPageNameUnique(std::u16string_view rPagName) const;
/** Return the reference device for the current document. When the
inherited implementation returns a device then this is passed to the
diff --git a/sd/source/ui/inc/LayerTabBar.hxx b/sd/source/ui/inc/LayerTabBar.hxx
index 2e0bee3aabef..a7fbefc4fb35 100644
--- a/sd/source/ui/inc/LayerTabBar.hxx
+++ b/sd/source/ui/inc/LayerTabBar.hxx
@@ -69,7 +69,7 @@ public:
static bool IsRealNameOfStandardLayer(const OUString& rName);
// Used e.g. in validity test of user entered names
- static bool IsLocalizedNameOfStandardLayer(const OUString& rName);
+ static bool IsLocalizedNameOfStandardLayer(std::u16string_view rName);
// In case rName is one of the sUNO_LayerName_*, it generates a localized name,
// otherwise it returns value of rName.
diff --git a/sd/source/ui/inc/RemoteServer.hxx b/sd/source/ui/inc/RemoteServer.hxx
index a25a93009aa0..0d7087d2f281 100644
--- a/sd/source/ui/inc/RemoteServer.hxx
+++ b/sd/source/ui/inc/RemoteServer.hxx
@@ -61,7 +61,7 @@ namespace sd
// For the control dialog
SD_DLLPUBLIC static std::vector< std::shared_ptr< ClientInfo > > getClients();
SD_DLLPUBLIC static bool connectClient( const std::shared_ptr< ClientInfo >& pClient,
- const OUString& aPin );
+ std::u16string_view aPin );
SD_DLLPUBLIC static void deauthoriseClient( const std::shared_ptr< ClientInfo >& pClient );
/// ensure that discoverability (eg. for Bluetooth) is enabled
diff --git a/sd/source/ui/inc/sdtreelb.hxx b/sd/source/ui/inc/sdtreelb.hxx
index 888fbfcf3b9c..328cc0f23b47 100644
--- a/sd/source/ui/inc/sdtreelb.hxx
+++ b/sd/source/ui/inc/sdtreelb.hxx
@@ -206,8 +206,8 @@ public:
m_aRowActivatedHdl = rLink;
}
- bool HasSelectedChildren(const OUString& rName);
- bool SelectEntry(const OUString& rName);
+ bool HasSelectedChildren(std::u16string_view rName);
+ bool SelectEntry(std::u16string_view rName);
OUString get_selected_text() const
{
@@ -266,7 +266,7 @@ public:
bool IsEqualToDoc(const SdDrawDocument* pInDoc);
/// Visits rList recursively and tries to advance rEntry accordingly.
bool IsEqualToShapeList(std::unique_ptr<weld::TreeIter>& rEntry, const SdrObjList& rList,
- const OUString& rListName);
+ std::u16string_view rListName);
static bool IsInDrag();
diff --git a/sd/source/ui/inc/unomodel.hxx b/sd/source/ui/inc/unomodel.hxx
index 4f4ba44e170e..7856e46aa33f 100644
--- a/sd/source/ui/inc/unomodel.hxx
+++ b/sd/source/ui/inc/unomodel.hxx
@@ -399,7 +399,7 @@ public:
// intern
/// @throws std::exception
- SdPage* FindPage( const OUString& rName ) const;
+ SdPage* FindPage( std::u16string_view rName ) const;
};
#endif
diff --git a/sd/source/ui/inc/unopage.hxx b/sd/source/ui/inc/unopage.hxx
index 1607e3779ead..b66db4f90e88 100644
--- a/sd/source/ui/inc/unopage.hxx
+++ b/sd/source/ui/inc/unopage.hxx
@@ -284,7 +284,7 @@ public:
virtual ~SdPageLinkTargets() throw() override;
// intern
- SdrObject* FindObject( const OUString& rName ) const throw();
+ SdrObject* FindObject( std::u16string_view rName ) const throw();
// XServiceInfo
virtual OUString SAL_CALL getImplementationName() override;
diff --git a/sd/source/ui/remotecontrol/Server.cxx b/sd/source/ui/remotecontrol/Server.cxx
index 840784d538eb..d3f1ac67f904 100644
--- a/sd/source/ui/remotecontrol/Server.cxx
+++ b/sd/source/ui/remotecontrol/Server.cxx
@@ -260,7 +260,7 @@ std::vector< std::shared_ptr< ClientInfo > > RemoteServer::getClients()
return aClients;
}
-bool RemoteServer::connectClient( const std::shared_ptr< ClientInfo >& pClient, const OUString& aPin )
+bool RemoteServer::connectClient( const std::shared_ptr< ClientInfo >& pClient, std::u16string_view aPin )
{
SAL_INFO( "sdremote", "RemoteServer::connectClient called" );
if ( !spServer )
diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx
index 8d518c65011d..4219c5f76a1f 100644
--- a/sd/source/ui/slideshow/slideshowimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowimpl.cxx
@@ -2216,7 +2216,7 @@ Reference< XSlideShow > SlideshowImpl::createSlideShow()
return xShow;
}
-void SlideshowImpl::createSlideList( bool bAll, const OUString& rPresSlide )
+void SlideshowImpl::createSlideList( bool bAll, std::u16string_view rPresSlide )
{
const sal_uInt16 nSlideCount = mpDoc->GetSdPageCount( PageKind::Standard );
@@ -2244,7 +2244,7 @@ void SlideshowImpl::createSlideList( bool bAll, const OUString& rPresSlide )
sal_Int32 nFirstVisibleSlide = 0;
// normal presentation
- if( !rPresSlide.isEmpty() )
+ if( !rPresSlide.empty() )
{
sal_Int32 nSlide;
bool bTakeNextAvailable = false;
@@ -2280,7 +2280,7 @@ void SlideshowImpl::createSlideList( bool bAll, const OUString& rPresSlide )
}
else
{
- if( meAnimationMode != ANIMATIONMODE_SHOW && !rPresSlide.isEmpty() )
+ if( meAnimationMode != ANIMATIONMODE_SHOW && !rPresSlide.empty() )
{
sal_Int32 nSlide;
for( nSlide = 0; nSlide < nSlideCount; nSlide++ )
diff --git a/sd/source/ui/slideshow/slideshowimpl.hxx b/sd/source/ui/slideshow/slideshowimpl.hxx
index d870d7ec49d3..ac84875c4c65 100644
--- a/sd/source/ui/slideshow/slideshowimpl.hxx
+++ b/sd/source/ui/slideshow/slideshowimpl.hxx
@@ -223,7 +223,7 @@ private:
void update();
- void createSlideList( bool bAll, const OUString& rPresSlide );
+ void createSlideList( bool bAll, std::u16string_view rPresSlide );
void displayCurrentSlide (const bool bSkipAllMainSequenceEffects = false);
diff --git a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
index 91deb290441f..c3bd9adcb31c 100644
--- a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
@@ -184,7 +184,7 @@ void SlotManager::FuTemporary (SfxRequest& rRequest)
// First make sure that the sidebar is visible
pShell->GetViewFrame()->ShowChildWindow(SID_SIDEBAR);
::sfx2::sidebar::Sidebar::ShowPanel(
- "SdSlideTransitionPanel",
+ u"SdSlideTransitionPanel",
pShell->GetViewFrame()->GetFrame().GetFrameInterface());
rRequest.Ignore ();
break;
@@ -195,7 +195,7 @@ void SlotManager::FuTemporary (SfxRequest& rRequest)
// First make sure that the sidebar is visible
pShell->GetViewFrame()->ShowChildWindow(SID_SIDEBAR);
::sfx2::sidebar::Sidebar::ShowPanel(
- "SdAllMasterPagesPanel",
+ u"SdAllMasterPagesPanel",
pShell->GetViewFrame()->GetFrame().GetFrameInterface());
rRequest.Ignore ();
break;
diff --git a/sd/source/ui/table/tablefunction.cxx b/sd/source/ui/table/tablefunction.cxx
index c420397e1621..6f84adf95d6f 100644
--- a/sd/source/ui/table/tablefunction.cxx
+++ b/sd/source/ui/table/tablefunction.cxx
@@ -234,7 +234,7 @@ void DrawViewShell::FuTable(SfxRequest& rReq)
// First make sure that the sidebar is visible
GetViewFrame()->ShowChildWindow(SID_SIDEBAR);
::sfx2::sidebar::Sidebar::ShowPanel(
- "SdTableDesignPanel",
+ u"SdTableDesignPanel",
GetViewFrame()->GetFrame().GetFrameInterface());
Cancel();
diff --git a/sd/source/ui/uitest/uiobject.cxx b/sd/source/ui/uitest/uiobject.cxx
index 54e5b586df7b..0b67f75c0ba2 100644
--- a/sd/source/ui/uitest/uiobject.cxx
+++ b/sd/source/ui/uitest/uiobject.cxx
@@ -47,7 +47,7 @@ OUString getObjectName(SdrObject const* pObject)
return pObject->GetName();
}
-SdrObject* getObject(const VclPtr<sd::Window>& xWindow, const OUString& rName)
+SdrObject* getObject(const VclPtr<sd::Window>& xWindow, std::u16string_view rName)
{
SdrPage* pPage = getViewShell(xWindow)->getCurrentPage();
diff --git a/sd/source/ui/unoidl/unocpres.cxx b/sd/source/ui/unoidl/unocpres.cxx
index 2571b1388bbf..ff169dc9b13d 100644
--- a/sd/source/ui/unoidl/unocpres.cxx
+++ b/sd/source/ui/unoidl/unocpres.cxx
@@ -429,7 +429,7 @@ sal_Bool SAL_CALL SdXCustomPresentationAccess::hasElements()
return pList && !pList->empty();
}
-SdCustomShow * SdXCustomPresentationAccess::getSdCustomShow( const OUString& rName ) const throw()
+SdCustomShow * SdXCustomPresentationAccess::getSdCustomShow( std::u16string_view rName ) const throw()
{
sal_uInt32 nIdx = 0;
diff --git a/sd/source/ui/unoidl/unocpres.hxx b/sd/source/ui/unoidl/unocpres.hxx
index bf1b7b7efa5b..8328e0dcc1a9 100644
--- a/sd/source/ui/unoidl/unocpres.hxx
+++ b/sd/source/ui/unoidl/unocpres.hxx
@@ -105,7 +105,7 @@ private:
// intern
inline SdCustomShowList* GetCustomShowList() const throw();
- SdCustomShow * getSdCustomShow( const OUString& Name ) const throw();
+ SdCustomShow * getSdCustomShow( std::u16string_view Name ) const throw();
public:
explicit SdXCustomPresentationAccess(SdXImpressDocument& rMyModel) throw();
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index 2ffc5acc0664..314741f228cf 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -3375,7 +3375,7 @@ sal_Bool SAL_CALL SdDocLinkTargets::hasElements()
return mpModel->GetDoc() != nullptr;
}
-SdPage* SdDocLinkTargets::FindPage( const OUString& rName ) const
+SdPage* SdDocLinkTargets::FindPage( std::u16string_view rName ) const
{
SdDrawDocument* pDoc = mpModel->GetDoc();
if( pDoc == nullptr )
diff --git a/sd/source/ui/unoidl/unopage.cxx b/sd/source/ui/unoidl/unopage.cxx
index 0ea67fbd7bcb..11417c30651b 100644
--- a/sd/source/ui/unoidl/unopage.cxx
+++ b/sd/source/ui/unoidl/unopage.cxx
@@ -1973,7 +1973,7 @@ sal_Bool SAL_CALL SdPageLinkTargets::hasByName( const OUString& aName )
return FindObject( aName ) != nullptr;
}
-SdrObject* SdPageLinkTargets::FindObject( const OUString& rName ) const throw()
+SdrObject* SdPageLinkTargets::FindObject( std::u16string_view rName ) const throw()
{
SdPage* pPage = mpUnoPage->GetPage();
if( pPage == nullptr )
diff --git a/sd/source/ui/view/ViewShellImplementation.cxx b/sd/source/ui/view/ViewShellImplementation.cxx
index a8f3be88994a..4ca73b2bb5dc 100644
--- a/sd/source/ui/view/ViewShellImplementation.cxx
+++ b/sd/source/ui/view/ViewShellImplementation.cxx
@@ -114,7 +114,7 @@ void ViewShell::Implementation::ProcessModifyPageSlot (
mrViewShell.GetDrawView()->UnmarkAll();
mrViewShell.GetViewFrame()->ShowChildWindow(SID_SIDEBAR);
sfx2::sidebar::Sidebar::TogglePanel(
- "SdLayoutsPanel",
+ u"SdLayoutsPanel",
mrViewShell.GetViewFrame()->GetFrame().GetFrameInterface());
break;
}
diff --git a/sd/source/ui/view/drviews2.cxx b/sd/source/ui/view/drviews2.cxx
index 30a334bfd6ec..a81fa4f5a5e4 100644
--- a/sd/source/ui/view/drviews2.cxx
+++ b/sd/source/ui/view/drviews2.cxx
@@ -211,7 +211,7 @@ const SvxFieldItem* findField(editeng::Section const & rSection)
return nullptr;
}
-bool hasCustomPropertyField(std::vector<editeng::Section> const & aSections, OUString const & rName)
+bool hasCustomPropertyField(std::vector<editeng::Section> const & aSections, std::u16string_view rName)
{
for (editeng::Section const & rSection : aSections)
{
diff --git a/sdext/source/minimizer/impoptimizer.cxx b/sdext/source/minimizer/impoptimizer.cxx
index d3cf48a8a458..6f9e2416ac94 100644
--- a/sdext/source/minimizer/impoptimizer.cxx
+++ b/sdext/source/minimizer/impoptimizer.cxx
@@ -65,7 +65,7 @@ using namespace ::com::sun::star::document;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::presentation;
-static void ImpExtractCustomShow( const Reference< XModel >& rxModel, const OUString& rCustomShowName )
+static void ImpExtractCustomShow( const Reference< XModel >& rxModel, std::u16string_view rCustomShowName )
{
vector< Reference< XDrawPage > > vNonUsedPageList;
try
diff --git a/sdext/source/minimizer/pagecollector.cxx b/sdext/source/minimizer/pagecollector.cxx
index b1673a18866b..f42c7d271a1a 100644
--- a/sdext/source/minimizer/pagecollector.cxx
+++ b/sdext/source/minimizer/pagecollector.cxx
@@ -35,7 +35,7 @@ using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::presentation;
-void PageCollector::CollectCustomShowPages( const css::uno::Reference< css::frame::XModel >& rxModel, const OUString& rCustomShowName, std::vector< Reference< XDrawPage > >& rUsedPageList )
+void PageCollector::CollectCustomShowPages( const css::uno::Reference< css::frame::XModel >& rxModel, std::u16string_view rCustomShowName, std::vector< Reference< XDrawPage > >& rUsedPageList )
{
try
{
@@ -68,7 +68,7 @@ void PageCollector::CollectCustomShowPages( const css::uno::Reference< css::fram
}
}
-void PageCollector::CollectNonCustomShowPages( const css::uno::Reference< css::frame::XModel >& rxModel, const OUString& rCustomShowName, std::vector< Reference< XDrawPage > >& rNonUsedPageList )
+void PageCollector::CollectNonCustomShowPages( const css::uno::Reference< css::frame::XModel >& rxModel, std::u16string_view rCustomShowName, std::vector< Reference< XDrawPage > >& rNonUsedPageList )
{
try
{
diff --git a/sdext/source/minimizer/pagecollector.hxx b/sdext/source/minimizer/pagecollector.hxx
index f3cf7fd5200e..d2cc48d9ed55 100644
--- a/sdext/source/minimizer/pagecollector.hxx
+++ b/sdext/source/minimizer/pagecollector.hxx
@@ -33,8 +33,8 @@ class PageCollector
css::uno::Reference< css::drawing::XDrawPage > xMasterPage;
bool bUsed;
};
- static void CollectCustomShowPages( const css::uno::Reference< css::frame::XModel >&, const OUString& rCustomShow, std::vector< css::uno::Reference< css::drawing::XDrawPage > >& );
- static void CollectNonCustomShowPages( const css::uno::Reference< css::frame::XModel >&, const OUString& rCustomShow, std::vector< css::uno::Reference< css::drawing::XDrawPage > >& );
+ static void CollectCustomShowPages( const css::uno::Reference< css::frame::XModel >&, std::u16string_view rCustomShow, std::vector< css::uno::Reference< css::drawing::XDrawPage > >& );
+ static void CollectNonCustomShowPages( const css::uno::Reference< css::frame::XModel >&, std::u16string_view rCustomShow, std::vector< css::uno::Reference< css::drawing::XDrawPage > >& );
static void CollectMasterPages( const css::uno::Reference< css::frame::XModel >&, std::vector< MasterPageEntity >& );
};
diff --git a/sdext/source/presenter/PresenterConfigurationAccess.cxx b/sdext/source/presenter/PresenterConfigurationAccess.cxx
index 467308426a26..c4a08812a631 100644
--- a/sdext/source/presenter/PresenterConfigurationAccess.cxx
+++ b/sdext/source/presenter/PresenterConfigurationAccess.cxx
@@ -239,7 +239,7 @@ Any PresenterConfigurationAccess::Find (
}
bool PresenterConfigurationAccess::IsStringPropertyEqual (
- const OUString& rsValue,
+ std::u16string_view rsValue,
const OUString& rsPropertyName,
const css::uno::Reference<css::beans::XPropertySet>& rxNode)
{
diff --git a/sdext/source/presenter/PresenterConfigurationAccess.hxx b/sdext/source/presenter/PresenterConfigurationAccess.hxx
index bdd2c3afc9eb..afd1b9aa4e87 100644
--- a/sdext/source/presenter/PresenterConfigurationAccess.hxx
+++ b/sdext/source/presenter/PresenterConfigurationAccess.hxx
@@ -154,7 +154,7 @@ public:
const Predicate& rPredicate);
static bool IsStringPropertyEqual (
- const OUString& rsValue,
+ std::u16string_view rsValue,
const OUString& rsPropertyName,
const css::uno::Reference<css::beans::XPropertySet>& rxNode);
diff --git a/sfx2/inc/autoredactdialog.hxx b/sfx2/inc/autoredactdialog.hxx
index 1410d75dd44d..eef638538e80 100644
--- a/sfx2/inc/autoredactdialog.hxx
+++ b/sfx2/inc/autoredactdialog.hxx
@@ -59,12 +59,12 @@ struct RedactionTarget
class TargetsTable
{
std::unique_ptr<weld::TreeView> m_xControl;
- int GetRowByTargetName(const OUString& sName);
+ int GetRowByTargetName(std::u16string_view sName);
public:
TargetsTable(std::unique_ptr<weld::TreeView> xControl);
void InsertTarget(RedactionTarget* pTarget);
- RedactionTarget* GetTargetByName(const OUString& sName);
+ RedactionTarget* GetTargetByName(std::u16string_view sName);
OUString GetNameProposal() const;
int get_selected_index() const { return m_xControl->get_selected_index(); }
diff --git a/sfx2/source/appl/newhelp.cxx b/sfx2/source/appl/newhelp.cxx
index 10e53fa6c435..ecca2f806228 100644
--- a/sfx2/source/appl/newhelp.cxx
+++ b/sfx2/source/appl/newhelp.cxx
@@ -1505,7 +1505,7 @@ void SfxHelpIndexWindow_Impl::AddBookmarks( const OUString& rTitle, const OUStri
GetBookmarksPage()->AddBookmarks( rTitle, rURL );
}
-bool SfxHelpIndexWindow_Impl::IsValidFactory( const OUString& _rFactory )
+bool SfxHelpIndexWindow_Impl::IsValidFactory( std::u16string_view _rFactory )
{
bool bValid = false;
for (sal_Int32 i = 0, nEntryCount = m_xActiveLB->get_count(); i < nEntryCount; ++i)
diff --git a/sfx2/source/appl/newhelp.hxx b/sfx2/source/appl/newhelp.hxx
index 25be4e6e3e12..d12f38e29ccf 100644
--- a/sfx2/source/appl/newhelp.hxx
+++ b/sfx2/source/appl/newhelp.hxx
@@ -267,7 +267,7 @@ public:
OUString const & GetFactory() const { return xIPage->GetFactory(); }
OUString GetSelectedEntry() const;
void AddBookmarks( const OUString& rTitle, const OUString& rURL );
- bool IsValidFactory( const OUString& _rFactory );
+ bool IsValidFactory( std::u16string_view _rFactory );
OUString GetActiveFactoryTitle() const { return m_xActiveLB->get_active_text(); }
void ClearSearchPage();
void GrabFocusBack();
diff --git a/sfx2/source/bastyp/fltfnc.cxx b/sfx2/source/bastyp/fltfnc.cxx
index f1d3ac399f27..39a4d8ff48a6 100644
--- a/sfx2/source/bastyp/fltfnc.cxx
+++ b/sfx2/source/bastyp/fltfnc.cxx
@@ -712,7 +712,7 @@ std::shared_ptr<const SfxFilter> SfxFilterMatcher::GetFilter4ClipBoardId( SotCli
return GetFilterForProps( aSeq, nMust, nDont );
}
-std::shared_ptr<const SfxFilter> SfxFilterMatcher::GetFilter4UIName( const OUString& rName, SfxFilterFlags nMust, SfxFilterFlags nDont ) const
+std::shared_ptr<const SfxFilter> SfxFilterMatcher::GetFilter4UIName( std::u16string_view rName, SfxFilterFlags nMust, SfxFilterFlags nDont ) const
{
m_rImpl.InitForIterating();
std::shared_ptr<const SfxFilter> pFirstFilter;
diff --git a/sfx2/source/control/templatedlglocalview.cxx b/sfx2/source/control/templatedlglocalview.cxx
index 84aa6cdca363..1a50f09e2816 100644
--- a/sfx2/source/control/templatedlglocalview.cxx
+++ b/sfx2/source/control/templatedlglocalview.cxx
@@ -52,7 +52,7 @@ void TemplateDlgLocalView::showRegion(TemplateContainerItem const* pItem)
maOpenRegionHdl.Call(nullptr);
}
-void TemplateDlgLocalView::showRegion(const OUString& rName)
+void TemplateDlgLocalView::showRegion(std::u16string_view rName)
{
for (auto const& pRegion : maRegions)
{
diff --git a/sfx2/source/control/templatelocalview.cxx b/sfx2/source/control/templatelocalview.cxx
index 4063e3453aaf..67481d7600e9 100644
--- a/sfx2/source/control/templatelocalview.cxx
+++ b/sfx2/source/control/templatelocalview.cxx
@@ -178,7 +178,7 @@ void TemplateLocalView::showRegion(TemplateContainerItem const *pItem)
maOpenRegionHdl.Call(nullptr);
}
-void TemplateLocalView::showRegion(const OUString &rName)
+void TemplateLocalView::showRegion(std::u16string_view rName)
{
for (auto const & pRegion : maRegions)
{
@@ -190,7 +190,7 @@ void TemplateLocalView::showRegion(const OUString &rName)
}
}
-TemplateContainerItem* TemplateLocalView::getRegion(OUString const & rName)
+TemplateContainerItem* TemplateLocalView::getRegion(std::u16string_view rName)
{
for (auto const & pRegion : maRegions)
if (pRegion->maTitle == rName)
@@ -263,7 +263,7 @@ sal_uInt16 TemplateLocalView::getRegionId(size_t pos) const
return maRegions[pos]->mnId;
}
-sal_uInt16 TemplateLocalView::getRegionId(OUString const & sRegion) const
+sal_uInt16 TemplateLocalView::getRegionId(std::u16string_view sRegion) const
{
for (auto const & pRegion : maRegions)
{
@@ -349,7 +349,7 @@ sal_uInt16 TemplateLocalView::createRegion(const OUString &rName)
return nItemId;
}
-bool TemplateLocalView::renameRegion(const OUString &rTitle, const OUString &rNewTitle)
+bool TemplateLocalView::renameRegion(std::u16string_view rTitle, const OUString &rNewTitle)
{
TemplateContainerItem *pRegion = getRegion(rTitle);
diff --git a/sfx2/source/dialog/filedlghelper.cxx b/sfx2/source/dialog/filedlghelper.cxx
index bfc4c893b739..7c86ca18b98d 100644
--- a/sfx2/source/dialog/filedlghelper.cxx
+++ b/sfx2/source/dialog/filedlghelper.cxx
@@ -2218,7 +2218,7 @@ void FileDialogHelper_Impl::addFilterPair( const OUString& rFilter,
}
-OUString FileDialogHelper_Impl::getFilterName( const OUString& rFilterWithExtension ) const
+OUString FileDialogHelper_Impl::getFilterName( std::u16string_view rFilterWithExtension ) const
{
OUString sRet;
for (auto const& filter : maFilters)
@@ -2232,7 +2232,7 @@ OUString FileDialogHelper_Impl::getFilterName( const OUString& rFilterWithExtens
return sRet;
}
-OUString FileDialogHelper_Impl::getFilterWithExtension( const OUString& rFilter ) const
+OUString FileDialogHelper_Impl::getFilterWithExtension( std::u16string_view rFilter ) const
{
OUString sRet;
for (auto const& filter : maFilters)
diff --git a/sfx2/source/dialog/filedlgimpl.hxx b/sfx2/source/dialog/filedlgimpl.hxx
index c755bcc9f26f..e5e02e209748 100644
--- a/sfx2/source/dialog/filedlgimpl.hxx
+++ b/sfx2/source/dialog/filedlgimpl.hxx
@@ -200,8 +200,8 @@ namespace sfx2
bool isShowFilterExtensionEnabled() const;
void addFilterPair( const OUString& rFilter,
const OUString& rFilterWithExtension );
- OUString getFilterName( const OUString& rFilterWithExtension ) const;
- OUString getFilterWithExtension( const OUString& rFilter ) const;
+ OUString getFilterName( std::u16string_view rFilterWithExtension ) const;
+ OUString getFilterWithExtension( std::u16string_view rFilter ) const;
void SetContext( FileDialogHelper::Context _eNewContext );
diff --git a/sfx2/source/dialog/infobar.cxx b/sfx2/source/dialog/infobar.cxx
index e8b176763c56..d46eb8f01440 100644
--- a/sfx2/source/dialog/infobar.cxx
+++ b/sfx2/source/dialog/infobar.cxx
@@ -399,7 +399,7 @@ VclPtr<SfxInfoBarWindow> SfxInfoBarContainerWindow::appendInfoBar(const OUString
return pInfoBar;
}
-VclPtr<SfxInfoBarWindow> SfxInfoBarContainerWindow::getInfoBar(const OUString& sId)
+VclPtr<SfxInfoBarWindow> SfxInfoBarContainerWindow::getInfoBar(std::u16string_view sId)
{
for (auto const& infoBar : m_pInfoBars)
{
@@ -409,7 +409,7 @@ VclPtr<SfxInfoBarWindow> SfxInfoBarContainerWindow::getInfoBar(const OUString& s
return nullptr;
}
-bool SfxInfoBarContainerWindow::hasInfoBarWithID(const OUString& sId)
+bool SfxInfoBarContainerWindow::hasInfoBarWithID(std::u16string_view sId)
{
return (getInfoBar(sId) != nullptr);
}
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index d9577bc852e3..182c20296d9e 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -475,7 +475,7 @@ static void MakeTree_Impl(StyleTreeArr_Impl& rArr, const OUString& aUIName)
}
static bool IsExpanded_Impl( const std::vector<OUString>& rEntries,
- const OUString &rStr)
+ std::u16string_view rStr)
{
for (const auto & rEntry : rEntries)
{
diff --git a/sfx2/source/doc/autoredactdialog.cxx b/sfx2/source/doc/autoredactdialog.cxx
index 2fea27f6975b..1466077e1dbd 100644
--- a/sfx2/source/doc/autoredactdialog.cxx
+++ b/sfx2/source/doc/autoredactdialog.cxx
@@ -25,7 +25,7 @@
#define FILEDIALOG_FILTER_JSON "*.json"
-int TargetsTable::GetRowByTargetName(const OUString& sName)
+int TargetsTable::GetRowByTargetName(std::u16string_view sName)
{
for (int i = 0, nCount = m_xControl->n_children(); i < nCount; ++i)
{
@@ -137,7 +137,7 @@ void TargetsTable::InsertTarget(RedactionTarget* pTarget)
nRow, pTarget->bWholeWords ? SfxResId(STR_REDACTION_YES) : SfxResId(STR_REDACTION_NO), 4);
}
-RedactionTarget* TargetsTable::GetTargetByName(const OUString& sName)
+RedactionTarget* TargetsTable::GetTargetByName(std::u16string_view sName)
{
int nEntry = GetRowByTargetName(sName);
if (nEntry == -1)
diff --git a/sfx2/source/doc/docfac.cxx b/sfx2/source/doc/docfac.cxx
index 55dfdf46b850..27d5134075ed 100644
--- a/sfx2/source/doc/docfac.cxx
+++ b/sfx2/source/doc/docfac.cxx
@@ -334,7 +334,7 @@ sal_uInt16 SfxObjectFactory::GetViewNo_Impl( const SfxInterfaceId i_nViewId, con
return i_nFallback;
}
-SfxViewFactory* SfxObjectFactory::GetViewFactoryByViewName( const OUString& i_rViewName ) const
+SfxViewFactory* SfxObjectFactory::GetViewFactoryByViewName( std::u16string_view i_rViewName ) const
{
for ( sal_uInt16 nViewNo = 0;
nViewNo < GetViewFactoryCount();
diff --git a/sfx2/source/doc/doctempl.cxx b/sfx2/source/doc/doctempl.cxx
index 726122c9f1cb..b57c11d98847 100644
--- a/sfx2/source/doc/doctempl.cxx
+++ b/sfx2/source/doc/doctempl.cxx
@@ -206,7 +206,7 @@ public:
size_t GetRegionCount() const
{ return maRegions.size(); }
- RegionData_Impl* GetRegion( const OUString& rName ) const;
+ RegionData_Impl* GetRegion( std::u16string_view rName ) const;
RegionData_Impl* GetRegion( size_t nIndex ) const;
bool GetTitleFromURL( const OUString& rURL, OUString& aTitle );
@@ -1089,7 +1089,7 @@ bool SfxDocumentTemplates::SetName( const OUString& rName, sal_uInt16 nRegion, s
bool SfxDocumentTemplates::GetFull
(
- const OUString &rRegion, // Region Name
+ std::u16string_view rRegion, // Region Name
const OUString &rName, // Template Name
OUString &rPath // Out: Path + File name
)
@@ -1126,7 +1126,7 @@ bool SfxDocumentTemplates::GetFull
RegionData_Impl *pRegion = pImp->GetRegion( i );
if( pRegion &&
- ( rRegion.isEmpty() || ( rRegion == pRegion->GetTitle() ) ) )
+ ( rRegion.empty() || ( rRegion == pRegion->GetTitle() ) ) )
{
pEntry = pRegion->GetEntry( rName );
@@ -1450,7 +1450,7 @@ RegionData_Impl* SfxDocTemplate_Impl::GetRegion( size_t nIndex ) const
}
-RegionData_Impl* SfxDocTemplate_Impl::GetRegion( const OUString& rName )
+RegionData_Impl* SfxDocTemplate_Impl::GetRegion( std::u16string_view rName )
const
{
for (auto& pData : maRegions)
diff --git a/sfx2/source/doc/doctemplates.cxx b/sfx2/source/doc/doctemplates.cxx
index 1d17dc828f84..7c06fc7ac34c 100644
--- a/sfx2/source/doc/doctemplates.cxx
+++ b/sfx2/source/doc/doctemplates.cxx
@@ -226,10 +226,10 @@ class SfxDocTplService_Impl
const OUString& aNewFolderName );
bool ReplaceUINamesForTemplateDir_Impl( const OUString& aUserPath,
const OUString& aFsysGroupName,
- const OUString& aOldGroupName,
+ std::u16string_view aOldGroupName,
const OUString& aNewGroupName );
void RemoveUINamesForTemplateDir_Impl( const OUString& aUserPath,
- const OUString& aGroupName );
+ std::u16string_view aGroupName );
bool WriteUINamesForTemplateDir_Impl( const OUString& aUserPath,
const std::vector< beans::StringPair >& aUINames );
@@ -1242,7 +1242,7 @@ bool SfxDocTplService_Impl::UpdateUINamesForTemplateDir_Impl( const OUString& aU
bool SfxDocTplService_Impl::ReplaceUINamesForTemplateDir_Impl( const OUString& aUserPath,
const OUString& aDefaultFsysGroupName,
- const OUString& aOldGroupName,
+ std::u16string_view aOldGroupName,
const OUString& aNewGroupName )
{
std::vector< beans::StringPair > aUINames = ReadUINamesForTemplateDir_Impl( aUserPath );
@@ -1267,7 +1267,7 @@ bool SfxDocTplService_Impl::ReplaceUINamesForTemplateDir_Impl( const OUString& a
void SfxDocTplService_Impl::RemoveUINamesForTemplateDir_Impl( const OUString& aUserPath,
- const OUString& aGroupName )
+ std::u16string_view aGroupName )
{
std::vector< beans::StringPair > aUINames = ReadUINamesForTemplateDir_Impl( aUserPath );
sal_Int32 nLen = aUINames.size();
diff --git a/sfx2/source/doc/objcont.cxx b/sfx2/source/doc/objcont.cxx
index 8d3faa98a8a0..04255063fd3f 100644
--- a/sfx2/source/doc/objcont.cxx
+++ b/sfx2/source/doc/objcont.cxx
@@ -476,7 +476,7 @@ void SfxObjectShell::UpdateFromTemplate_Impl( )
if( aFoundName.isEmpty() && !aTemplName.isEmpty() )
// if the template filename did not lead to success,
// try to get a file name for the logical template name
- aTempl.GetFull( OUString(), aTemplName, aFoundName );
+ aTempl.GetFull( u"", aTemplName, aFoundName );
}
if ( aFoundName.isEmpty() )
@@ -588,7 +588,7 @@ void SfxObjectShell::ResetFromTemplate( const OUString& rTemplateName, const OUS
return;
OUString aFoundName;
- if( SfxGetpApp()->Get_Impl()->GetDocumentTemplates()->GetFull( OUString(), rTemplateName, aFoundName ) )
+ if( SfxGetpApp()->Get_Impl()->GetDocumentTemplates()->GetFull( u"", rTemplateName, aFoundName ) )
{
INetURLObject aObj( rFileName );
xDocProps->setTemplateURL( aObj.GetMainURL(INetURLObject::DecodeMechanism::ToIUri) );
diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx
index 10be78bfe98d..0733ccc72752 100644
--- a/sfx2/source/doc/objmisc.cxx
+++ b/sfx2/source/doc/objmisc.cxx
@@ -1309,8 +1309,8 @@ SfxModule* SfxObjectShell::GetModule() const
return GetFactory().GetModule();
}
-ErrCode SfxObjectShell::CallBasic( const OUString& rMacro,
- const OUString& rBasic, SbxArray* pArgs,
+ErrCode SfxObjectShell::CallBasic( std::u16string_view rMacro,
+ std::u16string_view rBasic, SbxArray* pArgs,
SbxValue* pRet )
{
SfxApplication* pApp = SfxGetpApp();
diff --git a/sfx2/source/doc/objserv.cxx b/sfx2/source/doc/objserv.cxx
index 5a4354b92717..404b7422017c 100644
--- a/sfx2/source/doc/objserv.cxx
+++ b/sfx2/source/doc/objserv.cxx
@@ -328,7 +328,7 @@ void SfxObjectShell::CheckOut( )
// Remove the info bar
SfxViewFrame* pViewFrame = GetFrame();
- pViewFrame->RemoveInfoBar( "checkout" );
+ pViewFrame->RemoveInfoBar( u"checkout" );
}
catch ( const uno::RuntimeException& e )
{
@@ -1079,7 +1079,7 @@ void SfxObjectShell::ExecFile_Impl(SfxRequest &rReq)
{
SfxViewFrame *pFrame = GetFrame();
if (pFrame)
- pFrame->RemoveInfoBar("readonly");
+ pFrame->RemoveInfoBar(u"readonly");
SetReadOnlyUI(false);
}
}
@@ -1426,7 +1426,7 @@ void SfxObjectShell::GetState_Impl(SfxItemSet &rSet)
}
// new info bar
- if ( !pFrame->HasInfoBarWithID("signature") )
+ if ( !pFrame->HasInfoBarWithID(u"signature") )
{
if ( !sMessage.isEmpty() )
{
@@ -1441,9 +1441,9 @@ void SfxObjectShell::GetState_Impl(SfxItemSet &rSet)
else // info bar exists already
{
if ( eState == SignatureState::NOSIGNATURES )
- pFrame->RemoveInfoBar("signature");
+ pFrame->RemoveInfoBar(u"signature");
else
- pFrame->UpdateInfoBar("signature", "", sMessage, aInfobarType);
+ pFrame->UpdateInfoBar(u"signature", "", sMessage, aInfobarType);
}
}
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index 29751ac97d87..dcacebb95446 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -950,7 +950,7 @@ void SfxTemplateManagerDlg::OnTemplateState (const ThumbnailViewItem *pItem)
}
}
-void SfxTemplateManagerDlg::OnTemplateImportCategory(const OUString& sCategory)
+void SfxTemplateManagerDlg::OnTemplateImportCategory(std::u16string_view sCategory)
{
sfx2::FileDialogHelper aFileDlg(css::ui::dialogs::TemplateDescription::FILEOPEN_SIMPLE,
FileDialogFlags::MultiSelection, m_xDialog.get());
diff --git a/sfx2/source/sidebar/Deck.cxx b/sfx2/source/sidebar/Deck.cxx
index 1cc11cafc37e..c1d5974179a4 100644
--- a/sfx2/source/sidebar/Deck.cxx
+++ b/sfx2/source/sidebar/Deck.cxx
@@ -323,7 +323,7 @@ vcl::Window* Deck::GetPanelParentWindow()
return mpScrollContainer.get();
}
-Panel* Deck::GetPanel(const OUString & panelId)
+Panel* Deck::GetPanel(std::u16string_view panelId)
{
for (const VclPtr<Panel> & pPanel : maPanels)
{
diff --git a/sfx2/source/sidebar/Panel.cxx b/sfx2/source/sidebar/Panel.cxx
index c45a1e5efd42..793ee94ab85b 100644
--- a/sfx2/source/sidebar/Panel.cxx
+++ b/sfx2/source/sidebar/Panel.cxx
@@ -146,7 +146,7 @@ void Panel::SetExpanded (const bool bIsExpanded)
}
}
-bool Panel::HasIdPredicate (const OUString& rsId) const
+bool Panel::HasIdPredicate (std::u16string_view rsId) const
{
return msPanelId == rsId;
}
diff --git a/sfx2/source/sidebar/ResourceManager.cxx b/sfx2/source/sidebar/ResourceManager.cxx
index a1ff9752e1e0..b64b64e2c9ea 100644
--- a/sfx2/source/sidebar/ResourceManager.cxx
+++ b/sfx2/source/sidebar/ResourceManager.cxx
@@ -127,7 +127,7 @@ void ResourceManager::InitDeckContext(const Context& rContext)
}
}
-std::shared_ptr<DeckDescriptor> ResourceManager::ImplGetDeckDescriptor(const OUString& rsDeckId) const
+std::shared_ptr<DeckDescriptor> ResourceManager::ImplGetDeckDescriptor(std::u16string_view rsDeckId) const
{
for (auto const& deck : maDecks)
{
@@ -139,12 +139,12 @@ std::shared_ptr<DeckDescriptor> ResourceManager::ImplGetDeckDescriptor(const OUS
return nullptr;
}
-std::shared_ptr<DeckDescriptor> ResourceManager::GetDeckDescriptor(const OUString& rsDeckId) const
+std::shared_ptr<DeckDescriptor> ResourceManager::GetDeckDescriptor(std::u16string_view rsDeckId) const
{
return ImplGetDeckDescriptor( rsDeckId );
}
-std::shared_ptr<PanelDescriptor> ResourceManager::ImplGetPanelDescriptor(const OUString& rsPanelId) const
+std::shared_ptr<PanelDescriptor> ResourceManager::ImplGetPanelDescriptor(std::u16string_view rsPanelId) const
{
for (auto const& panel : maPanels)
{
@@ -154,7 +154,7 @@ std::shared_ptr<PanelDescriptor> ResourceManager::ImplGetPanelDescriptor(const O
return nullptr;
}
-std::shared_ptr<PanelDescriptor> ResourceManager::GetPanelDescriptor(const OUString& rsPanelId) const
+std::shared_ptr<PanelDescriptor> ResourceManager::GetPanelDescriptor(std::u16string_view rsPanelId) const
{
return ImplGetPanelDescriptor( rsPanelId );
}
@@ -198,7 +198,7 @@ const ResourceManager::DeckContextDescriptorContainer& ResourceManager::GetMatch
const ResourceManager::PanelContextDescriptorContainer& ResourceManager::GetMatchingPanels (
PanelContextDescriptorContainer& rPanelIds,
const Context& rContext,
- const OUString& sDeckId,
+ std::u16string_view sDeckId,
const Reference<frame::XController>& rxController)
{
ReadLegacyAddons(rxController);
@@ -697,7 +697,7 @@ void ResourceManager::ReadLegacyAddons (const Reference<frame::XController>& rxC
}
void ResourceManager::StorePanelExpansionState (
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
const bool bExpansionState,
const Context& rContext)
{
@@ -746,7 +746,7 @@ void ResourceManager::GetToolPanelNodeNames (
}
bool ResourceManager::IsDeckEnabled (
- const OUString& rsDeckId,
+ std::u16string_view rsDeckId,
const Context& rContext,
const Reference<frame::XController>& rxController)
{
diff --git a/sfx2/source/sidebar/Sidebar.cxx b/sfx2/source/sidebar/Sidebar.cxx
index ccd2fbc589d2..2a59ad7ef163 100644
--- a/sfx2/source/sidebar/Sidebar.cxx
+++ b/sfx2/source/sidebar/Sidebar.cxx
@@ -31,7 +31,7 @@ using namespace css;
namespace sfx2::sidebar {
-void Sidebar::ToggleDeck(const OUString& rsDeckId, SfxViewFrame* pViewFrame)
+void Sidebar::ToggleDeck(std::u16string_view rsDeckId, SfxViewFrame* pViewFrame)
{
if (!pViewFrame)
return;
@@ -61,7 +61,7 @@ void Sidebar::ToggleDeck(const OUString& rsDeckId, SfxViewFrame* pViewFrame)
}
void Sidebar::ShowPanel (
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
const css::uno::Reference<frame::XFrame>& rxFrame, bool bFocus)
{
SidebarController* pController = SidebarController::GetSidebarControllerForFrame(rxFrame);
@@ -86,7 +86,7 @@ void Sidebar::ShowPanel (
}
void Sidebar::TogglePanel (
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
const css::uno::Reference<frame::XFrame>& rxFrame)
{
SidebarController* pController = SidebarController::GetSidebarControllerForFrame(rxFrame);
@@ -108,7 +108,7 @@ void Sidebar::TogglePanel (
}
bool Sidebar::IsPanelVisible(
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
const css::uno::Reference<frame::XFrame>& rxFrame)
{
SidebarController* pController = SidebarController::GetSidebarControllerForFrame(rxFrame);
diff --git a/sfx2/source/sidebar/SidebarController.cxx b/sfx2/source/sidebar/SidebarController.cxx
index f359e768665e..5367292a8615 100644
--- a/sfx2/source/sidebar/SidebarController.cxx
+++ b/sfx2/source/sidebar/SidebarController.cxx
@@ -114,7 +114,7 @@ namespace {
/** When in doubt, show this deck.
*/
- const char gsDefaultDeckId[] = "PropertyDeck";
+ constexpr OUStringLiteral gsDefaultDeckId(u"PropertyDeck");
}
SidebarController::SidebarController (
@@ -639,7 +639,7 @@ void SidebarController::OpenThenToggleDeck (
}
void SidebarController::OpenThenSwitchToDeck (
- const OUString& rsDeckId)
+ std::u16string_view rsDeckId)
{
RequestOpenDeck();
SwitchToDeck(rsDeckId);
@@ -652,7 +652,7 @@ void SidebarController::SwitchToDefaultDeck()
}
void SidebarController::SwitchToDeck (
- const OUString& rsDeckId)
+ std::u16string_view rsDeckId)
{
if ( msCurrentDeckId != rsDeckId
|| ! mbIsDeckOpen
@@ -665,11 +665,11 @@ void SidebarController::SwitchToDeck (
}
}
-void SidebarController::CreateDeck(const OUString& rDeckId) {
+void SidebarController::CreateDeck(std::u16string_view rDeckId) {
CreateDeck(rDeckId, maCurrentContext);
}
-void SidebarController::CreateDeck(const OUString& rDeckId, const Context& rContext, bool bForceCreate)
+void SidebarController::CreateDeck(std::u16string_view rDeckId, const Context& rContext, bool bForceCreate)
{
std::shared_ptr<DeckDescriptor> xDeckDescriptor = mpResourceManager->GetDeckDescriptor(rDeckId);
@@ -691,7 +691,7 @@ void SidebarController::CreateDeck(const OUString& rDeckId, const Context& rCont
CreatePanels(rDeckId, rContext);
}
-void SidebarController::CreatePanels(const OUString& rDeckId, const Context& rContext)
+void SidebarController::CreatePanels(std::u16string_view rDeckId, const Context& rContext)
{
std::shared_ptr<DeckDescriptor> xDeckDescriptor = mpResourceManager->GetDeckDescriptor(rDeckId);
@@ -892,7 +892,7 @@ void SidebarController::SwitchToDeck (
UpdateTitleBarIcons();
}
-void SidebarController::notifyDeckTitle(const OUString& targetDeckId)
+void SidebarController::notifyDeckTitle(std::u16string_view targetDeckId)
{
if (msCurrentDeckId == targetDeckId)
{
@@ -903,7 +903,7 @@ void SidebarController::notifyDeckTitle(const OUString& targetDeckId)
}
VclPtr<Panel> SidebarController::CreatePanel (
- const OUString& rsPanelId,
+ std::u16string_view rsPanelId,
vcl::Window* pParentWindow,
const bool bIsInitiallyExpanded,
const Context& rContext,
@@ -1247,7 +1247,7 @@ bool SidebarController::IsDeckOpen(const sal_Int32 nIndex)
return mbIsDeckOpen && *mbIsDeckOpen;
}
-bool SidebarController::IsDeckVisible(const OUString& rsDeckId)
+bool SidebarController::IsDeckVisible(std::u16string_view rsDeckId)
{
return mbIsDeckOpen && *mbIsDeckOpen && msCurrentDeckId == rsDeckId;
}
@@ -1523,7 +1523,7 @@ ResourceManager::DeckContextDescriptorContainer SidebarController::GetMatchingDe
return aDecks;
}
-ResourceManager::PanelContextDescriptorContainer SidebarController::GetMatchingPanels(const OUString& rDeckId)
+ResourceManager::PanelContextDescriptorContainer SidebarController::GetMatchingPanels(std::u16string_view rDeckId)
{
ResourceManager::PanelContextDescriptorContainer aPanels;
diff --git a/sfx2/source/sidebar/SidebarDockingWindow.cxx b/sfx2/source/sidebar/SidebarDockingWindow.cxx
index c3bbe327fab7..3c187f117ba4 100644
--- a/sfx2/source/sidebar/SidebarDockingWindow.cxx
+++ b/sfx2/source/sidebar/SidebarDockingWindow.cxx
@@ -273,7 +273,7 @@ bool SidebarDockingWindow::EventNotify(NotifyEvent& rEvent)
if (".uno:DesignerDialog" == aCommand)
{
std::shared_ptr<PanelDescriptor> xPanelDescriptor =
- mpSidebarController->GetResourceManager()->GetPanelDescriptor( "StyleListPanel" );
+ mpSidebarController->GetResourceManager()->GetPanelDescriptor( u"StyleListPanel" );
if ( xPanelDescriptor && mpSidebarController->IsDeckVisible( xPanelDescriptor->msDeckId ) )
Close();
return true;
diff --git a/sfx2/source/sidebar/TabBar.cxx b/sfx2/source/sidebar/TabBar.cxx
index ee6b901c65de..6efe1133bda9 100644
--- a/sfx2/source/sidebar/TabBar.cxx
+++ b/sfx2/source/sidebar/TabBar.cxx
@@ -155,7 +155,7 @@ void TabBar::UpdateButtonIcons()
}
}
-void TabBar::HighlightDeck(const OUString& rsDeckId)
+void TabBar::HighlightDeck(std::u16string_view rsDeckId)
{
for (auto const& item : maItems)
item->mxButton->set_item_active("toggle", item->msDeckId == rsDeckId);
diff --git a/sfx2/source/styles/StyleManager.cxx b/sfx2/source/styles/StyleManager.cxx
index 95bdeac80122..4504be9db6ff 100644
--- a/sfx2/source/styles/StyleManager.cxx
+++ b/sfx2/source/styles/StyleManager.cxx
@@ -12,7 +12,7 @@
namespace sfx2
{
-SfxStyleSheetBase* StyleManager::Search(const OUString& rStyleName, SfxStyleFamily eFamily)
+SfxStyleSheetBase* StyleManager::Search(std::u16string_view rStyleName, SfxStyleFamily eFamily)
{
SfxStyleSheetBasePool* pPool = mrShell.GetStyleSheetPool();
if (!pPool)
diff --git a/sfx2/source/view/classificationhelper.cxx b/sfx2/source/view/classificationhelper.cxx
index 95126d996288..523fe75571bb 100644
--- a/sfx2/source/view/classificationhelper.cxx
+++ b/sfx2/source/view/classificationhelper.cxx
@@ -415,7 +415,7 @@ void SfxClassificationHelper::Impl::parsePolicy()
m_aIPPartNumbers = xClassificationParser->m_aIPPartNumbers;
}
-static bool lcl_containsProperty(const uno::Sequence<beans::Property>& rProperties, const OUString& rName)
+static bool lcl_containsProperty(const uno::Sequence<beans::Property>& rProperties, std::u16string_view rName)
{
return std::any_of(rProperties.begin(), rProperties.end(), [&](const beans::Property& rProperty)
{
@@ -622,9 +622,9 @@ const OUString& SfxClassificationHelper::GetAbbreviatedBACName(const OUString& s
return sFullName;
}
-OUString SfxClassificationHelper::GetBACNameForIdentifier(const OUString& sIdentifier)
+OUString SfxClassificationHelper::GetBACNameForIdentifier(std::u16string_view sIdentifier)
{
- if (sIdentifier.isEmpty())
+ if (sIdentifier.empty())
return "";
for (const auto& category : m_pImpl->m_aCategories)
@@ -884,7 +884,7 @@ void SfxClassificationHelper::UpdateInfobar(SfxViewFrame& rViewFrame)
OUString aMessage = SfxResId(STR_CLASSIFIED_DOCUMENT);
aMessage = aMessage.replaceFirst("%1", aBACName);
- rViewFrame.RemoveInfoBar("classification");
+ rViewFrame.RemoveInfoBar(u"classification");
rViewFrame.AppendInfoBar("classification", "", aMessage, GetImpactLevelType());
}
}
diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx
index 46a7c4d9dc42..8beeeab61f17 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -296,7 +296,7 @@ void SfxViewFrame::ExecReload_Impl( SfxRequest& rReq )
{
m_pSh->SetReadOnlyUI(m_bSetRO);
if (!m_bSetRO)
- m_pFrame->RemoveInfoBar("readonly");
+ m_pFrame->RemoveInfoBar(u"readonly");
if (m_pMed)
{
// tdf#116066: DoSaveCompleted should be called after SetReadOnlyUI
@@ -3157,7 +3157,7 @@ void SfxViewFrame::ChildWindowExecute( SfxRequest &rReq )
// First make sure that the sidebar is visible
ShowChildWindow(SID_SIDEBAR);
- ::sfx2::sidebar::Sidebar::ShowPanel("StyleListPanel",
+ ::sfx2::sidebar::Sidebar::ShowPanel(u"StyleListPanel",
GetFrame().GetFrameInterface(), true);
rReq.Done();
return;
@@ -3330,7 +3330,7 @@ VclPtr<SfxInfoBarWindow> SfxViewFrame::AppendInfoBar(const OUString& sId,
return pInfoBar;
}
-void SfxViewFrame::UpdateInfoBar(const OUString& sId, const OUString& sPrimaryMessage,
+void SfxViewFrame::UpdateInfoBar(std::u16string_view sId, const OUString& sPrimaryMessage,
const OUString& sSecondaryMessage, InfobarType eType)
{
const sal_uInt16 nId = SfxInfoBarContainerChild::GetChildWindowId();
@@ -3350,7 +3350,7 @@ void SfxViewFrame::UpdateInfoBar(const OUString& sId, const OUString& sPrimaryMe
}
}
-void SfxViewFrame::RemoveInfoBar( const OUString& sId )
+void SfxViewFrame::RemoveInfoBar( std::u16string_view sId )
{
const sal_uInt16 nId = SfxInfoBarContainerChild::GetChildWindowId();
@@ -3368,7 +3368,7 @@ void SfxViewFrame::RemoveInfoBar( const OUString& sId )
}
}
-bool SfxViewFrame::HasInfoBarWithID( const OUString& sId )
+bool SfxViewFrame::HasInfoBarWithID( std::u16string_view sId )
{
const sal_uInt16 nId = SfxInfoBarContainerChild::GetChildWindowId();
diff --git a/sot/source/sdstor/ucbstorage.cxx b/sot/source/sdstor/ucbstorage.cxx
index c97a02fb2e35..ee6576c6b87c 100644
--- a/sot/source/sdstor/ucbstorage.cxx
+++ b/sot/source/sdstor/ucbstorage.cxx
@@ -1799,7 +1799,7 @@ sal_Int32 UCBStorage_Impl::GetObjectCount()
return nCount;
}
-static OUString Find_Impl( const Sequence < Sequence < PropertyValue > >& rSequence, const OUString& rPath )
+static OUString Find_Impl( const Sequence < Sequence < PropertyValue > >& rSequence, std::u16string_view rPath )
{
bool bFound = false;
for ( const Sequence < PropertyValue >& rMyProps : rSequence )
@@ -2427,9 +2427,9 @@ bool UCBStorage::CopyStorageElement_Impl( UCBStorageElement_Impl const & rElemen
return Good() && pDest->Good();
}
-UCBStorageElement_Impl* UCBStorage::FindElement_Impl( const OUString& rName ) const
+UCBStorageElement_Impl* UCBStorage::FindElement_Impl( std::u16string_view rName ) const
{
- DBG_ASSERT( !rName.isEmpty(), "Name is empty!" );
+ DBG_ASSERT( !rName.empty(), "Name is empty!" );
for (const auto& pElement : pImp->GetChildrenList())
{
if ( pElement->m_aName == rName && !pElement->m_bIsRemoved )
diff --git a/starmath/inc/dialog.hxx b/starmath/inc/dialog.hxx
index cb3fcc677069..d3017f8e9554 100644
--- a/starmath/inc/dialog.hxx
+++ b/starmath/inc/dialog.hxx
@@ -34,7 +34,7 @@ class SvxShowCharSet;
/**************************************************************************/
-void SetFontStyle(const OUString &rStyleName, vcl::Font &rFont);
+void SetFontStyle(std::u16string_view rStyleName, vcl::Font &rFont);
/**************************************************************************/
@@ -432,7 +432,7 @@ class SmSymDefineDialog final : public weld::GenericDialogController
void FillStyles();
void SetSymbolSetManager(const SmSymbolManager &rMgr);
- void SetFont(const OUString &rFontName, const OUString &rStyleName);
+ void SetFont(const OUString &rFontName, std::u16string_view rStyleName);
void SetOrigSymbol(const SmSym *pSymbol, const OUString &rSymbolSetName);
void UpdateButtons();
diff --git a/starmath/inc/smmod.hxx b/starmath/inc/smmod.hxx
index a8f1ac17c467..3bab0068495b 100644
--- a/starmath/inc/smmod.hxx
+++ b/starmath/inc/smmod.hxx
@@ -57,10 +57,10 @@ public:
SmLocalizedSymbolData() = delete;
static OUString GetUiSymbolName( const OUString &rExportName );
- static OUString GetExportSymbolName( const OUString &rUiName );
+ static OUString GetExportSymbolName( std::u16string_view rUiName );
static OUString GetUiSymbolSetName( const OUString &rExportName );
- static OUString GetExportSymbolSetName( const OUString &rUiName );
+ static OUString GetExportSymbolSetName( std::u16string_view rUiName );
};
class SmModule final : public SfxModule, public utl::ConfigurationListener
diff --git a/starmath/inc/symbol.hxx b/starmath/inc/symbol.hxx
index 58f757c4e3a2..5b43d3f0692d 100644
--- a/starmath/inc/symbol.hxx
+++ b/starmath/inc/symbol.hxx
@@ -87,7 +87,7 @@ public:
// symbol sets are for UI purpose only, thus we assemble them here
std::set< OUString > GetSymbolSetNames() const;
- SymbolPtrVec_t GetSymbolSet( const OUString& rSymbolSetName );
+ SymbolPtrVec_t GetSymbolSet( std::u16string_view rSymbolSetName );
SymbolPtrVec_t GetSymbols() const;
bool AddOrReplaceSymbol( const SmSym & rSymbol, bool bForceChange = false );
diff --git a/starmath/source/cfgitem.cxx b/starmath/source/cfgitem.cxx
index f3c0ec3e99b8..a7d7d51f71af 100644
--- a/starmath/source/cfgitem.cxx
+++ b/starmath/source/cfgitem.cxx
@@ -237,7 +237,7 @@ void SmFontFormatList::AddFontFormat( const OUString &rFntFmtId,
}
-void SmFontFormatList::RemoveFontFormat( const OUString &rFntFmtId )
+void SmFontFormatList::RemoveFontFormat( std::u16string_view rFntFmtId )
{
// search for entry
@@ -254,7 +254,7 @@ void SmFontFormatList::RemoveFontFormat( const OUString &rFntFmtId )
}
-const SmFontFormat * SmFontFormatList::GetFontFormat( const OUString &rFntFmtId ) const
+const SmFontFormat * SmFontFormatList::GetFontFormat( std::u16string_view rFntFmtId ) const
{
const SmFontFormat *pRes = nullptr;
diff --git a/starmath/source/cfgitem.hxx b/starmath/source/cfgitem.hxx
index 8fa101187297..fe11ce08f409 100644
--- a/starmath/source/cfgitem.hxx
+++ b/starmath/source/cfgitem.hxx
@@ -77,9 +77,9 @@ public:
void Clear();
void AddFontFormat( const OUString &rFntFmtId, const SmFontFormat &rFntFmt );
- void RemoveFontFormat( const OUString &rFntFmtId );
+ void RemoveFontFormat( std::u16string_view rFntFmtId );
- const SmFontFormat * GetFontFormat( const OUString &rFntFmtId ) const;
+ const SmFontFormat * GetFontFormat( std::u16string_view rFntFmtId ) const;
const SmFontFormat * GetFontFormat( size_t nPos ) const;
OUString GetFontFormatId( const SmFontFormat &rFntFmt ) const;
OUString GetFontFormatId( const SmFontFormat &rFntFmt, bool bAdd );
diff --git a/starmath/source/dialog.cxx b/starmath/source/dialog.cxx
index 5902669c8df4..f13d0558abe3 100644
--- a/starmath/source/dialog.cxx
+++ b/starmath/source/dialog.cxx
@@ -134,12 +134,12 @@ static const SmFontStyles & GetFontStyles()
return aImpl;
}
-void SetFontStyle(const OUString &rStyleName, vcl::Font &rFont)
+void SetFontStyle(std::u16string_view rStyleName, vcl::Font &rFont)
{
// Find index related to StyleName. For an empty StyleName it's assumed to be
// 0 (neither bold nor italic).
sal_uInt16 nIndex = 0;
- if (!rStyleName.isEmpty())
+ if (!rStyleName.empty())
{
sal_uInt16 i;
const SmFontStyles &rStyles = GetFontStyles();
@@ -1952,7 +1952,7 @@ bool SmSymDefineDialog::SelectSymbol(weld::ComboBox& rComboBox,
}
-void SmSymDefineDialog::SetFont(const OUString &rFontName, const OUString &rStyleName)
+void SmSymDefineDialog::SetFont(const OUString &rFontName, std::u16string_view rStyleName)
{
// get Font (FontInfo) matching name and style
FontMetric aFontMetric;
diff --git a/starmath/source/parse.cxx b/starmath/source/parse.cxx
index 4ac26866e07c..b558da047cc0 100644
--- a/starmath/source/parse.cxx
+++ b/starmath/source/parse.cxx
@@ -2567,7 +2567,7 @@ std::unique_ptr<SmSpecialNode> SmParser::DoSpecial()
}
else if (IsExportSymbolNames())
{
- aNewName = SmLocalizedSymbolData::GetExportSymbolName(rName.copy(1));
+ aNewName = SmLocalizedSymbolData::GetExportSymbolName(rName.subView(1));
bReplace = true;
}
}
diff --git a/starmath/source/smmod.cxx b/starmath/source/smmod.cxx
index 208d6677f6c7..f0a809803a9e 100644
--- a/starmath/source/smmod.cxx
+++ b/starmath/source/smmod.cxx
@@ -61,7 +61,7 @@ OUString SmLocalizedSymbolData::GetUiSymbolName( const OUString &rExportName )
return aRes;
}
-OUString SmLocalizedSymbolData::GetExportSymbolName( const OUString &rUiName )
+OUString SmLocalizedSymbolData::GetExportSymbolName( std::u16string_view rUiName )
{
OUString aRes;
@@ -94,7 +94,7 @@ OUString SmLocalizedSymbolData::GetUiSymbolSetName( const OUString &rExportName
return aRes;
}
-OUString SmLocalizedSymbolData::GetExportSymbolSetName( const OUString &rUiName )
+OUString SmLocalizedSymbolData::GetExportSymbolSetName( std::u16string_view rUiName )
{
OUString aRes;
diff --git a/starmath/source/symbol.cxx b/starmath/source/symbol.cxx
index 5e6a6486a337..0d2f33045c08 100644
--- a/starmath/source/symbol.cxx
+++ b/starmath/source/symbol.cxx
@@ -187,10 +187,10 @@ std::set< OUString > SmSymbolManager::GetSymbolSetNames() const
}
-SymbolPtrVec_t SmSymbolManager::GetSymbolSet( const OUString& rSymbolSetName )
+SymbolPtrVec_t SmSymbolManager::GetSymbolSet( std::u16string_view rSymbolSetName )
{
SymbolPtrVec_t aRes;
- if (!rSymbolSetName.isEmpty())
+ if (!rSymbolSetName.empty())
{
for (const auto& rEntry : m_aSymbols)
{
diff --git a/stoc/source/implementationregistration/implreg.cxx b/stoc/source/implementationregistration/implreg.cxx
index d5813d7ad725..d6c80d16b5dc 100644
--- a/stoc/source/implementationregistration/implreg.cxx
+++ b/stoc/source/implementationregistration/implreg.cxx
@@ -210,7 +210,7 @@ void prepareLink( const Reference < XSimpleRegistry > & xDest,
OUString searchImplForLink(
const Reference < XRegistryKey > & xRootKey,
const OUString& linkName,
- const OUString& implName )
+ std::u16string_view implName )
// throw ( InvalidRegistryException, RuntimeException )
{
Reference < XRegistryKey > xKey = xRootKey->openKey( slash_IMPLEMENTATIONS );
@@ -349,7 +349,7 @@ bool deleteSubEntry(const Reference < XRegistryKey >& xSuperKey, const OUString&
void prepareUserLink(const Reference < XSimpleRegistry >& xDest,
const OUString& linkName,
const OUString& linkTarget,
- const OUString& implName)
+ std::u16string_view implName)
{
Reference < XRegistryKey > xRootKey = xDest->getRootKey();
@@ -399,7 +399,7 @@ void deletePathIfPossible(const Reference < XRegistryKey >& xRootKey,
void deleteUserLink(const Reference < XRegistryKey >& xRootKey,
const OUString& linkName,
- const OUString& linkTarget,
+ std::u16string_view linkTarget,
const OUString& implName)
// throw ( InvalidRegistryException, RuntimeException )
{
@@ -571,7 +571,7 @@ void prepareUserKeys(const Reference < XSimpleRegistry >& xDest,
void deleteAllImplementations( const Reference < XSimpleRegistry >& xReg,
const Reference < XRegistryKey >& xSource,
- const OUString& locationUrl,
+ std::u16string_view locationUrl,
std::vector<OUString> & implNames)
// throw (InvalidRegistryException, RuntimeException)
{
@@ -1091,7 +1091,7 @@ private: // helper methods
CannotRegisterImplementationException, RuntimeException ) */
static void doRevoke( const Reference < XSimpleRegistry >& xDest,
- const OUString& locationUrl );
+ std::u16string_view locationUrl );
// throw( InvalidRegistryException, RuntimeException )
Reference< XSimpleRegistry > getRegistryFromServiceManager() const;
@@ -1452,7 +1452,7 @@ Sequence< OUString > ImplementationRegistration::checkInstantiation(const OUStri
void ImplementationRegistration::doRevoke(
const Reference < XSimpleRegistry >& xDest,
- const OUString& locationUrl)
+ std::u16string_view locationUrl)
// throw ( InvalidRegistryException, RuntimeException )
{
if( !xDest.is() )
diff --git a/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx b/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx
index 960ecbcd16a8..958e728d76cf 100644
--- a/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx
+++ b/stoc/source/uriproc/UriSchemeParser_vndDOTsunDOTstarDOTscript.cxx
@@ -261,7 +261,7 @@ public:
private:
virtual ~UrlReference() override {}
- sal_Int32 findParameter(OUString const & key) const;
+ sal_Int32 findParameter(std::u16string_view key) const;
stoc::uriproc::UriReference m_base;
};
@@ -330,7 +330,7 @@ void UrlReference::setParameter(OUString const & key, OUString const & value)
m_base.m_path = newPath.makeStringAndClear();
}
-sal_Int32 UrlReference::findParameter(OUString const & key) const {
+sal_Int32 UrlReference::findParameter(std::u16string_view key) const {
sal_Int32 i = 0;
parsePart(m_base.m_path, true, &i); // skip name
for (;;) {
diff --git a/svl/source/items/style.cxx b/svl/source/items/style.cxx
index 8ef014755874..2d7eaf3c222f 100644
--- a/svl/source/items/style.cxx
+++ b/svl/source/items/style.cxx
@@ -791,7 +791,7 @@ void SfxStyleSheetBasePool::Clear()
pImpl->mxIndexedStyleSheets->Clear(cleanup);
}
-void SfxStyleSheetBasePool::ChangeParent(const OUString& rOld,
+void SfxStyleSheetBasePool::ChangeParent(std::u16string_view rOld,
const OUString& rNew,
SfxStyleFamily eFamily,
bool bVirtual)
diff --git a/svl/source/numbers/zforfind.cxx b/svl/source/numbers/zforfind.cxx
index eff5d48d9755..273e23bcd9d1 100644
--- a/svl/source/numbers/zforfind.cxx
+++ b/svl/source/numbers/zforfind.cxx
@@ -575,7 +575,7 @@ inline bool ImpSvNumberInputScan::GetThousandSep( const OUString& rString,
* "false"=> -1:
* else => 0:
*/
-short ImpSvNumberInputScan::GetLogical( const OUString& rString ) const
+short ImpSvNumberInputScan::GetLogical( std::u16string_view rString ) const
{
short res;
diff --git a/svl/source/numbers/zforfind.hxx b/svl/source/numbers/zforfind.hxx
index 0c66cb46f770..dfdbc0e7be1e 100644
--- a/svl/source/numbers/zforfind.hxx
+++ b/svl/source/numbers/zforfind.hxx
@@ -277,7 +277,7 @@ private:
sal_Int32& nPos,
sal_uInt16 nStringPos ) const;
// Get boolean value
- short GetLogical( const OUString& rString ) const;
+ short GetLogical( std::u16string_view rString ) const;
// Get month and advance string position
short GetMonth( const OUString& rString,
diff --git a/svl/source/numbers/zforlist.cxx b/svl/source/numbers/zforlist.cxx
index cced64f86d8c..f21f4448b873 100644
--- a/svl/source/numbers/zforlist.cxx
+++ b/svl/source/numbers/zforlist.cxx
@@ -548,7 +548,7 @@ const OUString& SvNumberFormatter::GetNumThousandSep() const { return aThousandS
const OUString& SvNumberFormatter::GetDateSep() const { return aDateSep; }
-bool SvNumberFormatter::IsDecimalSep( const OUString& rStr ) const
+bool SvNumberFormatter::IsDecimalSep( std::u16string_view rStr ) const
{
if (rStr == GetNumDecimalSep())
return true;
@@ -937,7 +937,7 @@ sal_uInt32 SvNumberFormatter::ImpGetCLOffset(LanguageType eLnge) const
return nOffset;
}
-sal_uInt32 SvNumberFormatter::ImpIsEntry(const OUString& rString,
+sal_uInt32 SvNumberFormatter::ImpIsEntry(std::u16string_view rString,
sal_uInt32 nCLOffset,
LanguageType eLnge)
{
@@ -3224,7 +3224,7 @@ OUString SvNumberFormatter::GenerateFormat(sal_uInt32 nIndex,
return sString.makeStringAndClear();
}
-bool SvNumberFormatter::IsUserDefined(const OUString& sStr,
+bool SvNumberFormatter::IsUserDefined(std::u16string_view sStr,
LanguageType eLnge)
{
::osl::MutexGuard aGuard( GetInstanceMutex() );
@@ -3244,7 +3244,7 @@ bool SvNumberFormatter::IsUserDefined(const OUString& sStr,
return pEntry && (pEntry->GetType() & SvNumFormatType::DEFINED);
}
-sal_uInt32 SvNumberFormatter::GetEntryKey(const OUString& sStr,
+sal_uInt32 SvNumberFormatter::GetEntryKey(std::u16string_view sStr,
LanguageType eLnge)
{
::osl::MutexGuard aGuard( GetInstanceMutex() );
@@ -3542,7 +3542,7 @@ const NfCurrencyEntry& SvNumberFormatter::GetCurrencyEntry( LanguageType eLang )
// static
-const NfCurrencyEntry* SvNumberFormatter::GetCurrencyEntry(const OUString& rAbbrev, LanguageType eLang )
+const NfCurrencyEntry* SvNumberFormatter::GetCurrencyEntry(std::u16string_view rAbbrev, LanguageType eLang )
{
eLang = MsLangId::getRealLanguage( eLang );
const NfCurrencyTable& rTable = GetTheCurrencyTable();
@@ -3560,8 +3560,8 @@ const NfCurrencyEntry* SvNumberFormatter::GetCurrencyEntry(const OUString& rAbbr
// static
-const NfCurrencyEntry* SvNumberFormatter::GetLegacyOnlyCurrencyEntry( const OUString& rSymbol,
- const OUString& rAbbrev )
+const NfCurrencyEntry* SvNumberFormatter::GetLegacyOnlyCurrencyEntry( std::u16string_view rSymbol,
+ std::u16string_view rAbbrev )
{
GetTheCurrencyTable(); // just for initialization
const NfCurrencyTable& rTable = theLegacyOnlyCurrencyTable::get();
@@ -3589,7 +3589,7 @@ IMPL_STATIC_LINK_NOARG( SvNumberFormatter, CurrencyChangeLink, LinkParamNone*, v
// static
-void SvNumberFormatter::SetDefaultSystemCurrency( const OUString& rAbbrev, LanguageType eLang )
+void SvNumberFormatter::SetDefaultSystemCurrency( std::u16string_view rAbbrev, LanguageType eLang )
{
::osl::MutexGuard aGuard( GetGlobalMutex() );
if ( eLang == LANGUAGE_SYSTEM )
@@ -3598,7 +3598,7 @@ void SvNumberFormatter::SetDefaultSystemCurrency( const OUString& rAbbrev, Langu
}
const NfCurrencyTable& rTable = GetTheCurrencyTable();
sal_uInt16 nCount = rTable.size();
- if ( !rAbbrev.isEmpty() )
+ if ( !rAbbrev.empty() )
{
for ( sal_uInt16 j = 0; j < nCount; j++ )
{
@@ -3719,7 +3719,7 @@ sal_uInt32 SvNumberFormatter::ImpGetDefaultCurrencyFormat()
// true: continue; false: break loop, if pFoundEntry==NULL dupe found
bool SvNumberFormatter::ImpLookupCurrencyEntryLoopBody(
const NfCurrencyEntry*& pFoundEntry, bool& bFoundBank, const NfCurrencyEntry* pData,
- sal_uInt16 nPos, const OUString& rSymbol )
+ sal_uInt16 nPos, std::u16string_view rSymbol )
{
bool bFound;
if ( pData->GetSymbol() == rSymbol )
@@ -3827,7 +3827,7 @@ bool SvNumberFormatter::GetNewCurrencySymbolString( sal_uInt32 nFormat, OUString
// static
const NfCurrencyEntry* SvNumberFormatter::GetCurrencyEntry( bool & bFoundBank,
- const OUString& rSymbol,
+ std::u16string_view rSymbol,
const OUString& rExtension,
LanguageType eFormatLanguage,
bool bOnlyStringLanguage )
diff --git a/svl/source/passwordcontainer/passwordcontainer.cxx b/svl/source/passwordcontainer/passwordcontainer.cxx
index 51fb129cddb1..893c7eb96ef8 100644
--- a/svl/source/passwordcontainer/passwordcontainer.cxx
+++ b/svl/source/passwordcontainer/passwordcontainer.cxx
@@ -659,7 +659,7 @@ void PasswordContainer::PrivateAdd( const OUString& Url, const OUString& UserNam
UrlRecord SAL_CALL PasswordContainer::find( const OUString& aURL, const Reference< XInteractionHandler >& aHandler )
{
- return find( aURL, OUString(), false, aHandler );
+ return find( aURL, u"", false, aHandler );
}
@@ -669,7 +669,7 @@ UrlRecord SAL_CALL PasswordContainer::findForName( const OUString& aURL, const O
}
-Sequence< UserRecord > PasswordContainer::FindUsr( const std::vector< NamePassRecord >& userlist, const OUString& aName, const Reference< XInteractionHandler >& aHandler )
+Sequence< UserRecord > PasswordContainer::FindUsr( const std::vector< NamePassRecord >& userlist, std::u16string_view aName, const Reference< XInteractionHandler >& aHandler )
{
sal_uInt32 nInd = 0;
for (auto const& aNPIter : userlist)
@@ -692,7 +692,7 @@ Sequence< UserRecord > PasswordContainer::FindUsr( const std::vector< NamePassRe
bool PasswordContainer::createUrlRecord(
const PassMap::iterator & rIter,
bool bName,
- const OUString & aName,
+ std::u16string_view aName,
const Reference< XInteractionHandler >& aHandler,
UrlRecord & rRec )
{
@@ -719,7 +719,7 @@ bool PasswordContainer::createUrlRecord(
UrlRecord PasswordContainer::find(
const OUString& aURL,
- const OUString& aName,
+ std::u16string_view aName,
bool bName, // only needed to support empty user names
const Reference< XInteractionHandler >& aHandler )
{
diff --git a/svl/source/passwordcontainer/passwordcontainer.hxx b/svl/source/passwordcontainer/passwordcontainer.hxx
index 46ffec888602..937a2be66975 100644
--- a/svl/source/passwordcontainer/passwordcontainer.hxx
+++ b/svl/source/passwordcontainer/passwordcontainer.hxx
@@ -231,20 +231,20 @@ private:
/// @throws css::uno::RuntimeException
css::uno::Sequence< css::task::UserRecord > FindUsr(
const ::std::vector< NamePassRecord >& userlist,
- const OUString& name,
+ std::u16string_view name,
const css::uno::Reference< css::task::XInteractionHandler >& Handler );
/// @throws css::uno::RuntimeException
bool createUrlRecord(
const PassMap::iterator & rIter,
bool bName,
- const OUString & aName,
+ std::u16string_view aName,
const css::uno::Reference< css::task::XInteractionHandler >& aHandler,
css::task::UrlRecord & rRec );
/// @throws css::uno::RuntimeException
css::task::UrlRecord find(
const OUString& aURL,
- const OUString& aName,
+ std::u16string_view aName,
bool bName, // only needed to support empty user names
const css::uno::Reference< css::task::XInteractionHandler >& aHandler );
diff --git a/svtools/source/dialogs/insdlg.cxx b/svtools/source/dialogs/insdlg.cxx
index 4698d4f186c8..91a9822c3248 100644
--- a/svtools/source/dialogs/insdlg.cxx
+++ b/svtools/source/dialogs/insdlg.cxx
@@ -75,7 +75,7 @@ static_assert(offsetof(OleObjectDescriptor, dwSrcOfCopy)
/********************** SvObjectServerList ********************************
**************************************************************************/
-const SvObjectServer * SvObjectServerList::Get( const OUString & rHumanName ) const
+const SvObjectServer * SvObjectServerList::Get( std::u16string_view rHumanName ) const
{
for(const auto & i : aObjectServerList)
{
diff --git a/svtools/source/misc/langtab.cxx b/svtools/source/misc/langtab.cxx
index c5df133b1daf..c8479d92445b 100644
--- a/svtools/source/misc/langtab.cxx
+++ b/svtools/source/misc/langtab.cxx
@@ -49,7 +49,7 @@ public:
bool HasType( const LanguageType eType ) const;
OUString GetString( const LanguageType eType ) const;
- LanguageType GetType( const OUString& rStr ) const;
+ LanguageType GetType( std::u16string_view rStr ) const;
sal_uInt32 GetEntryCount() const;
LanguageType GetTypeAtIndex( sal_uInt32 nIndex ) const;
sal_uInt32 AddItem(const OUString& rLanguage, const LanguageType eType)
@@ -235,7 +235,7 @@ OUString SvtLanguageTable::GetLanguageString( const LanguageType eType )
return theLanguageTable::get().GetString( eType );
}
-LanguageType SvtLanguageTableImpl::GetType( const OUString& rStr ) const
+LanguageType SvtLanguageTableImpl::GetType( std::u16string_view rStr ) const
{
LanguageType eType = LANGUAGE_DONTKNOW;
sal_uInt32 nCount = GetEntryCount();
@@ -251,7 +251,7 @@ LanguageType SvtLanguageTableImpl::GetType( const OUString& rStr ) const
return eType;
}
-LanguageType SvtLanguageTable::GetLanguageType( const OUString& rStr )
+LanguageType SvtLanguageTable::GetLanguageType( std::u16string_view rStr )
{
return theLanguageTable::get().GetType( rStr );
}
diff --git a/svx/inc/galbrws2.hxx b/svx/inc/galbrws2.hxx
index bbf13cff5c3f..0ee663835a74 100644
--- a/svx/inc/galbrws2.hxx
+++ b/svx/inc/galbrws2.hxx
@@ -128,7 +128,7 @@ public:
GalleryBrowser2(weld::Builder& rBuilder, Gallery* pGallery);
~GalleryBrowser2();
- void SelectTheme( const OUString& rThemeName );
+ void SelectTheme( std::u16string_view rThemeName );
GalleryBrowserMode GetMode() const { return meMode; }
void SetMode( GalleryBrowserMode eMode );
diff --git a/svx/source/dialog/ClassificationCommon.cxx b/svx/source/dialog/ClassificationCommon.cxx
index d5561ec5b32c..8ff87270e585 100644
--- a/svx/source/dialog/ClassificationCommon.cxx
+++ b/svx/source/dialog/ClassificationCommon.cxx
@@ -58,7 +58,7 @@ OUString getProperty(uno::Reference<beans::XPropertyContainer> const& rxProperty
return OUString();
}
-bool containsProperty(uno::Sequence<beans::Property> const& rProperties, OUString const& rName)
+bool containsProperty(uno::Sequence<beans::Property> const& rProperties, std::u16string_view rName)
{
return std::any_of(rProperties.begin(), rProperties.end(),
[&](const beans::Property& rProperty) { return rProperty.Name == rName; });
diff --git a/svx/source/dialog/ctredlin.cxx b/svx/source/dialog/ctredlin.cxx
index 2980d80ba6b2..d80f84890161 100644
--- a/svx/source/dialog/ctredlin.cxx
+++ b/svx/source/dialog/ctredlin.cxx
@@ -260,14 +260,14 @@ void SvxRedlinTable::SetCommentParams( const utl::SearchParam* pSearchPara )
}
}
-bool SvxRedlinTable::IsValidEntry(const OUString &rAuthorStr,
+bool SvxRedlinTable::IsValidEntry(std::u16string_view rAuthorStr,
const DateTime &rDateTime,
const OUString &rCommentStr)
{
return IsValidEntry(rAuthorStr, rDateTime) && IsValidComment(rCommentStr);
}
-bool SvxRedlinTable::IsValidEntry(const OUString &rAuthorStr, const DateTime &rDateTime)
+bool SvxRedlinTable::IsValidEntry(std::u16string_view rAuthorStr, const DateTime &rDateTime)
{
if (bAuthor && aAuthor!=rAuthorStr)
return false;
diff --git a/svx/source/gallery2/galbrws1.cxx b/svx/source/gallery2/galbrws1.cxx
index 6cf14753e524..8d71fe546b71 100644
--- a/svx/source/gallery2/galbrws1.cxx
+++ b/svx/source/gallery2/galbrws1.cxx
@@ -169,7 +169,7 @@ void GalleryBrowser1::ImplGetExecuteVector(std::vector<OString>& o_aExec)
mpGallery->ReleaseTheme( pTheme, *this );
}
-void GalleryBrowser1::ImplGalleryThemeProperties( const OUString & rThemeName, bool bCreateNew )
+void GalleryBrowser1::ImplGalleryThemeProperties( std::u16string_view rThemeName, bool bCreateNew )
{
DBG_ASSERT(!mpThemePropsDlgItemSet, "mpThemePropsDlgItemSet already set!");
mpThemePropsDlgItemSet.reset(new SfxItemSet( SfxGetpApp()->GetPool() ));
diff --git a/svx/source/gallery2/galbrws1.hxx b/svx/source/gallery2/galbrws1.hxx
index 222237a72a74..e0b83f940b9d 100644
--- a/svx/source/gallery2/galbrws1.hxx
+++ b/svx/source/gallery2/galbrws1.hxx
@@ -60,7 +60,7 @@ private:
static void ImplFillExchangeData( const GalleryTheme* pThm, ExchangeData& rData );
void ImplGetExecuteVector(std::vector<OString>& o_aExec);
void ImplExecute(const OString &rIdent);
- void ImplGalleryThemeProperties( const OUString & rThemeName, bool bCreateNew );
+ void ImplGalleryThemeProperties( std::u16string_view rThemeName, bool bCreateNew );
void EndNewThemePropertiesDlgHdl(sal_Int32 nResult);
void EndThemePropertiesDlgHdl(sal_Int32 nResult);
void ImplEndGalleryThemeProperties(bool bCreateNew, sal_Int32 nResult);
diff --git a/svx/source/gallery2/galbrws2.cxx b/svx/source/gallery2/galbrws2.cxx
index 71dd0ab32784..9338689c7c4a 100644
--- a/svx/source/gallery2/galbrws2.cxx
+++ b/svx/source/gallery2/galbrws2.cxx
@@ -600,7 +600,7 @@ bool GalleryBrowser2::KeyInput(const KeyEvent& rKEvt)
return bRet;
}
-void GalleryBrowser2::SelectTheme( const OUString& rThemeName )
+void GalleryBrowser2::SelectTheme( std::u16string_view rThemeName )
{
if( mpCurTheme )
mpGallery->ReleaseTheme( mpCurTheme, *this );
diff --git a/svx/source/gallery2/galexpl.cxx b/svx/source/gallery2/galexpl.cxx
index b2d34749b7df..83dc3b1688dd 100644
--- a/svx/source/gallery2/galexpl.cxx
+++ b/svx/source/gallery2/galexpl.cxx
@@ -48,7 +48,7 @@ bool GalleryExplorer::FillThemeList( std::vector<OUString>& rThemeList )
return !rThemeList.empty();
}
-bool GalleryExplorer::FillObjList( const OUString& rThemeName, std::vector<OUString> &rObjList )
+bool GalleryExplorer::FillObjList( std::u16string_view rThemeName, std::vector<OUString> &rObjList )
{
Gallery* pGal = ::Gallery::GetGalleryInstance();
@@ -104,7 +104,7 @@ bool GalleryExplorer::FillObjListTitle( const sal_uInt32 nThemeId, std::vector<
return !rList.empty();
}
-bool GalleryExplorer::InsertURL( const OUString& rThemeName, const OUString& rURL )
+bool GalleryExplorer::InsertURL( std::u16string_view rThemeName, const OUString& rURL )
{
Gallery* pGal = ::Gallery::GetGalleryInstance();
bool bRet = false;
@@ -132,7 +132,7 @@ bool GalleryExplorer::InsertURL( sal_uInt32 nThemeId, const OUString& rURL )
return pGal && InsertURL( pGal->GetThemeName( nThemeId ), rURL );
}
-bool GalleryExplorer::GetGraphicObj( const OUString& rThemeName, sal_uInt32 nPos,
+bool GalleryExplorer::GetGraphicObj( std::u16string_view rThemeName, sal_uInt32 nPos,
Graphic* pGraphic )
{
Gallery* pGal = ::Gallery::GetGalleryInstance();
@@ -162,7 +162,7 @@ bool GalleryExplorer::GetGraphicObj( sal_uInt32 nThemeId, sal_uInt32 nPos,
return pGal && GetGraphicObj( pGal->GetThemeName( nThemeId ), nPos, pGraphic );
}
-sal_uInt32 GalleryExplorer::GetSdrObjCount( const OUString& rThemeName )
+sal_uInt32 GalleryExplorer::GetSdrObjCount( std::u16string_view rThemeName )
{
Gallery* pGal = ::Gallery::GetGalleryInstance();
sal_uInt32 nRet = 0;
@@ -191,7 +191,7 @@ sal_uInt32 GalleryExplorer::GetSdrObjCount( sal_uInt32 nThemeId )
return( pGal ? GetSdrObjCount( pGal->GetThemeName( nThemeId ) ) : 0 );
}
-bool GalleryExplorer::GetSdrObj( const OUString& rThemeName, sal_uInt32 nSdrModelPos,
+bool GalleryExplorer::GetSdrObj( std::u16string_view rThemeName, sal_uInt32 nSdrModelPos,
SdrModel* pModel, BitmapEx* pThumb )
{
Gallery* pGal = ::Gallery::GetGalleryInstance();
@@ -233,7 +233,7 @@ bool GalleryExplorer::GetSdrObj( sal_uInt32 nThemeId, sal_uInt32 nSdrModelPos,
return pGal && GetSdrObj( pGal->GetThemeName( nThemeId ), nSdrModelPos, pModel, pThumb );
}
-bool GalleryExplorer::BeginLocking( const OUString& rThemeName )
+bool GalleryExplorer::BeginLocking( std::u16string_view rThemeName )
{
Gallery* pGal = ::Gallery::GetGalleryInstance();
bool bRet = false;
@@ -258,7 +258,7 @@ bool GalleryExplorer::BeginLocking( sal_uInt32 nThemeId )
return pGal && BeginLocking( pGal->GetThemeName( nThemeId ) );
}
-bool GalleryExplorer::EndLocking( const OUString& rThemeName )
+bool GalleryExplorer::EndLocking( std::u16string_view rThemeName )
{
Gallery* pGal = ::Gallery::GetGalleryInstance();
bool bRet = false;
diff --git a/svx/source/gallery2/galini.cxx b/svx/source/gallery2/galini.cxx
index 161b1ec6e24c..87f6abfb28a1 100644
--- a/svx/source/gallery2/galini.cxx
+++ b/svx/source/gallery2/galini.cxx
@@ -23,7 +23,7 @@
#include <vcl/settings.hxx>
#include <memory>
-OUString GalleryBinaryEngineEntry::ReadStrFromIni(const OUString &aKeyName )
+OUString GalleryBinaryEngineEntry::ReadStrFromIni(std::u16string_view aKeyName )
{
std::unique_ptr<SvStream> pStrm(::utl::UcbStreamHelper::CreateStream(
GetStrURL().GetMainURL( INetURLObject::DecodeMechanism::NONE ),
diff --git a/svx/source/gallery2/gallery1.cxx b/svx/source/gallery2/gallery1.cxx
index c522fdf49e93..69b4ab1f59c6 100644
--- a/svx/source/gallery2/gallery1.cxx
+++ b/svx/source/gallery2/gallery1.cxx
@@ -129,7 +129,7 @@ GalleryThemeEntry::GalleryThemeEntry( bool bCreateUniqueURL,
SetModified( _bNewFile );
- aName = mpGalleryStorageEngineEntry->ReadStrFromIni( "name" );
+ aName = mpGalleryStorageEngineEntry->ReadStrFromIni( u"name" );
// This is awful - we shouldn't use these resources if we
// possibly can avoid them
@@ -476,9 +476,9 @@ void Gallery::ImplLoadSubDirs( const INetURLObject& rBaseURL, bool& rbDirIsReadO
}
}
-GalleryThemeEntry* Gallery::ImplGetThemeEntry( const OUString& rThemeName )
+GalleryThemeEntry* Gallery::ImplGetThemeEntry( std::u16string_view rThemeName )
{
- if( !rThemeName.isEmpty() )
+ if( !rThemeName.empty() )
{
for ( size_t i = 0, n = aThemeList.size(); i < n; ++i )
if( rThemeName == aThemeList[ i ]->GetThemeName() )
@@ -567,7 +567,7 @@ OUString Gallery::GetThemeName( sal_uInt32 nThemeId ) const
return( pFound ? pFound->GetThemeName() : OUString() );
}
-bool Gallery::HasTheme( const OUString& rThemeName )
+bool Gallery::HasTheme( std::u16string_view rThemeName )
{
return( ImplGetThemeEntry( rThemeName ) != nullptr );
}
@@ -691,7 +691,7 @@ void Gallery::ImplDeleteCachedTheme( GalleryTheme const * pTheme )
}
}
-GalleryTheme* Gallery::AcquireTheme( const OUString& rThemeName, SfxListener& rListener )
+GalleryTheme* Gallery::AcquireTheme( std::u16string_view rThemeName, SfxListener& rListener )
{
GalleryTheme* pTheme = nullptr;
GalleryThemeEntry* pThemeEntry = ImplGetThemeEntry( rThemeName );
diff --git a/svx/source/inc/datanavi.hxx b/svx/source/inc/datanavi.hxx
index 30f140f2aad1..8feee550c5a8 100644
--- a/svx/source/inc/datanavi.hxx
+++ b/svx/source/inc/datanavi.hxx
@@ -110,7 +110,7 @@ namespace svxform
/** convert submission replace string from UI to API.
Use 'none' as default. */
- OUString toAPI( const OUString& rStr ) const
+ OUString toAPI( std::u16string_view rStr ) const
{
if( rStr == m_sDoc_UI )
return m_sDoc_API;
@@ -154,7 +154,7 @@ namespace svxform
}
/** convert from UI to API; put is default */
- OUString toAPI( const OUString& rStr ) const
+ OUString toAPI( std::u16string_view rStr ) const
{
if( rStr == m_sGet_UI )
return m_sGet_API;
diff --git a/svx/source/items/numfmtsh.cxx b/svx/source/items/numfmtsh.cxx
index 833dbccdfc3c..87fe7fa79b39 100644
--- a/svx/source/items/numfmtsh.cxx
+++ b/svx/source/items/numfmtsh.cxx
@@ -277,7 +277,7 @@ bool SvxNumberFormatShell::AddFormat(OUString& rFormat, sal_Int32& rErrPos,
return bInserted;
}
-void SvxNumberFormatShell::RemoveFormat(const OUString& rFormat, sal_uInt16& rCatLbSelPos,
+void SvxNumberFormatShell::RemoveFormat(std::u16string_view rFormat, sal_uInt16& rCatLbSelPos,
short& rFmtSelPos, std::vector<OUString>& rFmtEntries)
{
sal_uInt32 nDelKey = pFormatter->GetEntryKey(rFormat, eCurLanguage);
@@ -338,7 +338,7 @@ void SvxNumberFormatShell::MakeFormat(OUString& rFormat, bool bThousand, bool bN
}
}
-sal_uInt16 SvxNumberFormatShell::GetFormatIntegerDigits(const OUString& rFormat) const
+sal_uInt16 SvxNumberFormatShell::GetFormatIntegerDigits(std::u16string_view rFormat) const
{
sal_uInt32 nFmtKey = pFormatter->GetEntryKey(rFormat, eCurLanguage);
@@ -1333,7 +1333,7 @@ OUString SvxNumberFormatShell::GetFormat4Entry(short nEntry)
* Input: Number of the entry
* Output: Category number
*/
-short SvxNumberFormatShell::GetListPos4Entry(sal_uInt32 nIdx, const OUString& rFmtString)
+short SvxNumberFormatShell::GetListPos4Entry(sal_uInt32 nIdx, std::u16string_view rFmtString)
{
short nSelP = SELPOS_NONE;
if (nIdx != NUMBERFORMAT_ENTRY_NEW_CURRENCY)
@@ -1560,7 +1560,7 @@ sal_uInt16 SvxNumberFormatShell::FindCurrencyFormat(const NfCurrencyEntry* pTmpC
}
bool SvxNumberFormatShell::IsInTable(sal_uInt16 const nPos, bool const bTmpBanking,
- OUString const& rFmtString)
+ std::u16string_view rFmtString)
{
bool bFlag = false;
diff --git a/svx/source/styles/ColorSets.cxx b/svx/source/styles/ColorSets.cxx
index 2e7771caefac..0c68d726a017 100644
--- a/svx/source/styles/ColorSets.cxx
+++ b/svx/source/styles/ColorSets.cxx
@@ -92,7 +92,7 @@ void ColorSets::init()
}
}
-const ColorSet& ColorSets::getColorSet(const OUString& rName)
+const ColorSet& ColorSets::getColorSet(std::u16string_view rName)
{
for (const ColorSet & rColorSet : maColorSets)
{
diff --git a/svx/source/svdraw/svdotext.cxx b/svx/source/svdraw/svdotext.cxx
index 0daeb7cc9a5d..5685f0934872 100644
--- a/svx/source/svdraw/svdotext.cxx
+++ b/svx/source/svdraw/svdotext.cxx
@@ -1883,7 +1883,7 @@ void SdrTextObj::onEditOutlinerStatusEvent( EditStatus* pEditStatus )
/* Begin chaining code */
// XXX: Make it a method somewhere?
-static SdrObject *ImpGetObjByName(SdrObjList const *pObjList, OUString const& aObjName)
+static SdrObject *ImpGetObjByName(SdrObjList const *pObjList, std::u16string_view aObjName)
{
// scan the whole list
size_t nObjCount = pObjList->GetObjCount();
@@ -1899,12 +1899,12 @@ static SdrObject *ImpGetObjByName(SdrObjList const *pObjList, OUString const& aO
}
// XXX: Make it a (private) method of SdrTextObj
-static void ImpUpdateChainLinks(SdrTextObj *pTextObj, OUString const& aNextLinkName)
+static void ImpUpdateChainLinks(SdrTextObj *pTextObj, std::u16string_view aNextLinkName)
{
// XXX: Current implementation constraints text boxes to be on the same page
// No next link
- if (aNextLinkName.isEmpty()) {
+ if (aNextLinkName.empty()) {
pTextObj->SetNextLinkInChain(nullptr);
return;
}
diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index 954ebcf563e4..31507e4347a6 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -219,7 +219,7 @@ protected:
void ReleaseFocus();
static Color TestColorsVisible(const Color &FontCol, const Color &BackCol);
static void UserDrawEntry(vcl::RenderContext& rRenderContext, const tools::Rectangle& rRect, const OUString &rStyleName);
- void SetupEntry(vcl::RenderContext& rRenderContext, sal_Int32 nItem, const tools::Rectangle& rRect, const OUString& rStyleName, bool bIsNotSelected);
+ void SetupEntry(vcl::RenderContext& rRenderContext, sal_Int32 nItem, const tools::Rectangle& rRect, std::u16string_view rStyleName, bool bIsNotSelected);
static bool AdjustFontForItemHeight(OutputDevice& rDevice, tools::Rectangle const & rTextRect, tools::Long nHeight);
DECL_LINK(MenuSelectHdl, const OString&, void);
DECL_STATIC_LINK(SvxStyleBox_Base, ShowMoreHdl, void*, void);
@@ -933,7 +933,7 @@ IMPL_STATIC_LINK_NOARG(SvxStyleBox_Base, ShowMoreHdl, void*, void)
if (!pViewFrm)
return;
pViewFrm->ShowChildWindow(SID_SIDEBAR);
- ::sfx2::sidebar::Sidebar::ShowPanel("StyleListPanel", pViewFrm->GetFrame().GetFrameInterface(), true);
+ ::sfx2::sidebar::Sidebar::ShowPanel(u"StyleListPanel", pViewFrm->GetFrame().GetFrameInterface(), true);
}
IMPL_LINK(SvxStyleBox_Base, SelectHdl, weld::ComboBox&, rCombo, void)
@@ -1127,7 +1127,7 @@ void SvxStyleBox_Base::UserDrawEntry(vcl::RenderContext& rRenderContext, const t
rRenderContext.DrawText(aPos, rStyleName);
}
-void SvxStyleBox_Base::SetupEntry(vcl::RenderContext& rRenderContext, sal_Int32 nItem, const tools::Rectangle& rRect, const OUString& rStyleName, bool bIsNotSelected)
+void SvxStyleBox_Base::SetupEntry(vcl::RenderContext& rRenderContext, sal_Int32 nItem, const tools::Rectangle& rRect, std::u16string_view rStyleName, bool bIsNotSelected)
{
const StyleSettings& rStyleSettings = Application::GetSettings().GetStyleSettings();
if (!bIsNotSelected)
diff --git a/svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.cxx b/svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.cxx
index 54961330c503..33b8c27fa913 100644
--- a/svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.cxx
+++ b/svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.cxx
@@ -166,7 +166,7 @@ DictionaryEntry* DictionaryList::getEntryOnPos(sal_Int32 nPos) const
return reinterpret_cast<DictionaryEntry*>(sLBEntry.toInt64());
}
-DictionaryEntry* DictionaryList::getTermEntry( const OUString& rTerm ) const
+DictionaryEntry* DictionaryList::getTermEntry( std::u16string_view rTerm ) const
{
int nRowCount = m_xControl->n_children();
for( sal_Int32 nN = nRowCount; nN--; )
@@ -178,7 +178,7 @@ DictionaryEntry* DictionaryList::getTermEntry( const OUString& rTerm ) const
return nullptr;
}
-bool DictionaryList::hasTerm( const OUString& rTerm ) const
+bool DictionaryList::hasTerm( std::u16string_view rTerm ) const
{
return getTermEntry(rTerm) !=nullptr ;
}
@@ -211,7 +211,7 @@ void DictionaryList::deleteEntryOnPos( sal_Int32 nPos )
}
}
-int DictionaryList::deleteEntries( const OUString& rTerm )
+int DictionaryList::deleteEntries( std::u16string_view rTerm )
{
int nPos = -1;
int nRowCount = m_xControl->n_children();
diff --git a/svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.hxx b/svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.hxx
index 4d3b120c23b8..ee179dd92e58 100644
--- a/svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.hxx
+++ b/svx/source/unodialogs/textconversiondlgs/chinese_dictionarydialog.hxx
@@ -55,12 +55,12 @@ public:
void refillFromDictionary( sal_Int32 nTextConversionOptions /*i18n::TextConversionOption*/ );
void save();
- DictionaryEntry* getTermEntry( const OUString& rTerm ) const;
- bool hasTerm( const OUString& rTerm ) const;
+ DictionaryEntry* getTermEntry( std::u16string_view rTerm ) const;
+ bool hasTerm( std::u16string_view rTerm ) const;
void addEntry( const OUString& rTerm, const OUString& rMapping
, sal_Int16 nConversionPropertyType /*linguistic2::ConversionPropertyType*/, int nPos = -1);
- int deleteEntries( const OUString& rTerm ); //return lowest position of deleted entries or -1 if no entry was deleted
+ int deleteEntries( std::u16string_view rTerm ); //return lowest position of deleted entries or -1 if no entry was deleted
void deleteEntryOnPos( sal_Int32 nPos );
DictionaryEntry* getEntryOnPos( sal_Int32 nPos ) const;
DictionaryEntry* getFirstSelectedEntry() const;
diff --git a/svx/source/unodraw/unomtabl.cxx b/svx/source/unodraw/unomtabl.cxx
index b930fed67205..4e9de869ab40 100644
--- a/svx/source/unodraw/unomtabl.cxx
+++ b/svx/source/unodraw/unomtabl.cxx
@@ -265,7 +265,7 @@ void SAL_CALL SvxUnoMarkerTable::replaceByName( const OUString& aApiName, const
ImplInsertByName( aName, aElement );
}
-static bool getByNameFromPool( const OUString& rSearchName, SfxItemPool const * pPool, sal_uInt16 nWhich, uno::Any& rAny )
+static bool getByNameFromPool( std::u16string_view rSearchName, SfxItemPool const * pPool, sal_uInt16 nWhich, uno::Any& rAny )
{
if (pPool)
for (const SfxPoolItem* p : pPool->GetItemSurrogates(nWhich))
diff --git a/svx/source/unogallery/unogaltheme.cxx b/svx/source/unogallery/unogaltheme.cxx
index 39013c20ea4c..857555ac2838 100644
--- a/svx/source/unogallery/unogaltheme.cxx
+++ b/svx/source/unogallery/unogaltheme.cxx
@@ -36,7 +36,7 @@ using namespace ::com::sun::star;
namespace unogallery {
-GalleryTheme::GalleryTheme( const OUString& rThemeName )
+GalleryTheme::GalleryTheme( std::u16string_view rThemeName )
{
mpGallery = ::Gallery::GetGalleryInstance();
mpTheme = ( mpGallery ? mpGallery->AcquireTheme( rThemeName, *this ) : nullptr );
diff --git a/svx/source/unogallery/unogaltheme.hxx b/svx/source/unogallery/unogaltheme.hxx
index 7eb3b2ccf13d..31cde7003bbe 100644
--- a/svx/source/unogallery/unogaltheme.hxx
+++ b/svx/source/unogallery/unogaltheme.hxx
@@ -44,7 +44,7 @@ class GalleryTheme : public ::cppu::WeakImplHelper<
public:
- explicit GalleryTheme( const OUString& rThemeName );
+ explicit GalleryTheme( std::u16string_view rThemeName );
virtual ~GalleryTheme() override;
protected:
diff --git a/svx/source/xoutdev/xtable.cxx b/svx/source/xoutdev/xtable.cxx
index 3bb6ca063765..6a0744fe0a3d 100644
--- a/svx/source/xoutdev/xtable.cxx
+++ b/svx/source/xoutdev/xtable.cxx
@@ -141,7 +141,7 @@ XPropertyEntry* XPropertyList::Get( tools::Long nIndex ) const
return maList[nIndex].get();
}
-tools::Long XPropertyList::GetIndex(const OUString& rName) const
+tools::Long XPropertyList::GetIndex(std::u16string_view rName) const
{
if( mbListDirty )
{
diff --git a/sw/inc/PostItMgr.hxx b/sw/inc/PostItMgr.hxx
index 391f97a340c6..760fc7f8abe7 100644
--- a/sw/inc/PostItMgr.hxx
+++ b/sw/inc/PostItMgr.hxx
@@ -207,7 +207,7 @@ class SAL_DLLPUBLIC_RTTI SwPostItMgr final : public SfxListener
void ExecuteFormatAllDialog(SwView& rView);
void FormatAll(const SfxItemSet &rNewAttr);
- void Hide( const OUString& rAuthor );
+ void Hide( std::u16string_view rAuthor );
void Hide();
void Show();
void UpdateResolvedStatus(const sw::annotation::SwAnnotationWin* topNote);
diff --git a/sw/inc/authfld.hxx b/sw/inc/authfld.hxx
index be11b793f1af..05921ad7a454 100644
--- a/sw/inc/authfld.hxx
+++ b/sw/inc/authfld.hxx
@@ -91,7 +91,7 @@ public:
}
void GetAllEntryIdentifiers( std::vector<OUString>& rToFill ) const;
- SwAuthEntry* GetEntryByIdentifier(const OUString& rIdentifier) const;
+ SwAuthEntry* GetEntryByIdentifier(std::u16string_view rIdentifier) const;
bool ChangeEntryContent(const SwAuthEntry* pNewEntry);
// import interface
diff --git a/sw/inc/cellfml.hxx b/sw/inc/cellfml.hxx
index c7cb40e09694..1e3c2c506b11 100644
--- a/sw/inc/cellfml.hxx
+++ b/sw/inc/cellfml.hxx
@@ -84,7 +84,7 @@ typedef void (SwTableFormula::*FnScanFormula)( const SwTable&, OUStringBuffer&,
OUString ScanString( FnScanFormula fnFormula, const SwTable& rTable,
void*) const;
- static const SwTable* FindTable( SwDoc& rDoc, const OUString& rNm );
+ static const SwTable* FindTable( SwDoc& rDoc, std::u16string_view rNm );
protected:
enum NameType { EXTRNL_NAME, INTRNL_NAME, REL_NAME };
diff --git a/sw/inc/crsrsh.hxx b/sw/inc/crsrsh.hxx
index 572afdfd4f51..2fbb94509c6e 100644
--- a/sw/inc/crsrsh.hxx
+++ b/sw/inc/crsrsh.hxx
@@ -759,7 +759,7 @@ public:
// is the whole document protected/hidden (for UI...)
bool IsAllProtect() const { return m_bAllProtect; }
- bool GotoRegion( const OUString& rName );
+ bool GotoRegion( std::u16string_view rName );
// show the current selection
virtual void MakeSelVisible();
@@ -786,7 +786,7 @@ public:
bool SelectTextAttr( sal_uInt16 nWhich, bool bExpand, const SwTextAttr* pAttr = nullptr );
bool GotoINetAttr( const SwTextINetFormat& rAttr );
- const SwFormatINetFormat* FindINetAttr( const OUString& rName ) const;
+ const SwFormatINetFormat* FindINetAttr( std::u16string_view rName ) const;
bool SelectText( const sal_Int32 nStart,
const sal_Int32 nEnd );
diff --git a/sw/inc/doc.hxx b/sw/inc/doc.hxx
index 75ab76a7c471..1cf15c399293 100644
--- a/sw/inc/doc.hxx
+++ b/sw/inc/doc.hxx
@@ -756,18 +756,18 @@ public:
// Remove all language dependencies from all existing formats
void RemoveAllFormatLanguageDependencies();
- static SwFormat* FindFormatByName(const SwFormatsBase& rFormatArr, const OUString& rName);
+ static SwFormat* FindFormatByName(const SwFormatsBase& rFormatArr, std::u16string_view rName);
SwFrameFormat *MakeFrameFormat(const OUString &rFormatName, SwFrameFormat *pDerivedFrom,
bool bBroadcast = false, bool bAuto = true);
void DelFrameFormat( SwFrameFormat *pFormat, bool bBroadcast = false );
- SwFrameFormat* FindFrameFormatByName( const OUString& rName ) const;
+ SwFrameFormat* FindFrameFormatByName( std::u16string_view rName ) const;
SwCharFormat *MakeCharFormat(const OUString &rFormatName, SwCharFormat *pDerivedFrom,
bool bBroadcast = false );
void DelCharFormat(size_t nFormat, bool bBroadcast = false);
void DelCharFormat(SwCharFormat const * pFormat, bool bBroadcast = false);
- SwCharFormat* FindCharFormatByName( const OUString& rName ) const
+ SwCharFormat* FindCharFormatByName( std::u16string_view rName ) const
{ return static_cast<SwCharFormat*>(FindFormatByName( *mpCharFormatTable, rName )); }
// Formatcollections (styles)
@@ -795,7 +795,7 @@ public:
const bool bReset = true,
const bool bResetListAttrs = false,
SwRootFrame const* pLayout = nullptr);
- SwTextFormatColl* FindTextFormatCollByName( const OUString& rName ) const
+ SwTextFormatColl* FindTextFormatCollByName( std::u16string_view rName ) const
{ return static_cast<SwTextFormatColl*>(FindFormatByName( *mpTextFormatCollTable, rName )); }
void ChkCondColls();
@@ -813,7 +813,7 @@ public:
SwFrameFormat& GetTableFrameFormat(size_t nFormat, bool bUsed ) const;
SwTableFormat* MakeTableFrameFormat(const OUString &rFormatName, SwFrameFormat *pDerivedFrom);
void DelTableFrameFormat( SwTableFormat* pFormat );
- SwTableFormat* FindTableFormatByName( const OUString& rName, bool bAll = false ) const;
+ SwTableFormat* FindTableFormatByName( std::u16string_view rName, bool bAll = false ) const;
/** Access to frames.
Iterate over Flys - for Basic-Collections. */
@@ -1077,7 +1077,7 @@ public:
bool bBroadcast = false,
const SvxNumberFormat::SvxNumPositionAndSpaceMode eDefaultNumberFormatPositionAndSpaceMode =
SvxNumberFormat::LABEL_WIDTH_AND_POSITION );
- sal_uInt16 FindNumRule( const OUString& rName ) const;
+ sal_uInt16 FindNumRule( std::u16string_view rName ) const;
SwNumRule* FindNumRulePtr( const OUString& rName ) const;
// Deletion only possible if Rule is not used!
@@ -1268,7 +1268,7 @@ public:
const SwTable* pCpyTable, bool bCpyName = false,
bool bCorrPos = false );
- void UnProtectCells( const OUString& rTableName );
+ void UnProtectCells( std::u16string_view rTableName );
bool UnProtectCells( const SwSelBoxes& rBoxes );
void UnProtectTables( const SwPaM& rPam );
bool HasTableAnyProtection( const SwPosition* pPos,
@@ -1285,7 +1285,7 @@ public:
sal_uInt16 nMode = 0 );
// Make charts of given table update.
- void UpdateCharts( const OUString &rName ) const;
+ void UpdateCharts( std::u16string_view rName ) const;
// Update all charts, for that exists any table.
void UpdateAllCharts() { DoUpdateAllCharts(); }
@@ -1294,7 +1294,7 @@ public:
void SetTableName( SwFrameFormat& rTableFormat, const OUString &rNewName );
// @return the reference in document that is set for name.
- const SwFormatRefMark* GetRefMark( const OUString& rName ) const;
+ const SwFormatRefMark* GetRefMark( std::u16string_view rName ) const;
// @return RefMark via index - for UNO.
const SwFormatRefMark* GetRefMark( sal_uInt16 nIndex ) const;
@@ -1390,7 +1390,7 @@ public:
SwAutoCorrExceptWord* GetAutoCorrExceptWord() { return mpACEWord.get(); }
void DeleteAutoCorrExceptWord();
- const SwFormatINetFormat* FindINetAttr( const OUString& rName ) const;
+ const SwFormatINetFormat* FindINetAttr( std::u16string_view rName ) const;
// Call into intransparent Basic; expect possible Return String.
void ExecMacro( const SvxMacro& rMacro, OUString* pRet, SbxArray* pArgs );
diff --git a/sw/inc/editsh.hxx b/sw/inc/editsh.hxx
index ff7393292eb5..40a63023f8ac 100644
--- a/sw/inc/editsh.hxx
+++ b/sw/inc/editsh.hxx
@@ -294,7 +294,7 @@ public:
SwCharFormat* GetCurCharFormat() const;
void FillByEx(SwCharFormat*);
SwCharFormat* MakeCharFormat( const OUString& rName );
- SwCharFormat* FindCharFormatByName( const OUString& rName ) const;
+ SwCharFormat* FindCharFormatByName( std::u16string_view rName ) const;
/* FormatCollections (new) - Explaining the general naming pattern:
* GetXXXCount() returns the count of xxx in the document.
@@ -337,7 +337,7 @@ public:
SwTextFormatColl *MakeTextFormatColl(const OUString &rFormatCollName,
SwTextFormatColl *pDerivedFrom = nullptr);
void FillByEx(SwTextFormatColl*);
- SwTextFormatColl* FindTextFormatCollByName( const OUString& rName ) const;
+ SwTextFormatColl* FindTextFormatCollByName( std::u16string_view rName ) const;
/// @return "Auto-Collection" with given Id. If it does not exist create it.
SwTextFormatColl* GetTextCollFromPool( sal_uInt16 nId );
@@ -676,13 +676,13 @@ public:
svt::EmbeddedObjectRef& GetOLEObject() const;
/// Is there an OLEObject with this name (SwFormat)?
- bool HasOLEObj( const OUString &rName ) const;
+ bool HasOLEObj( std::u16string_view rName ) const;
/// @return pointer to the data of the chart in which Cursr is.
void SetChartName( const OUString &rName );
/// Update content of all charts for table with given name.
- void UpdateCharts( const OUString &rName );
+ void UpdateCharts( std::u16string_view rName );
OUString GetCurWord() const;
@@ -806,7 +806,7 @@ public:
void SetLinguRange( SwDocPositions eStart, SwDocPositions eEnd );
/// @return reference set in document according to given name.
- const SwFormatRefMark* GetRefMark( const OUString& rName ) const;
+ const SwFormatRefMark* GetRefMark( std::u16string_view rName ) const;
/** @return names of all references set in document.
If ArrayPointer == 0 then return only whether a RefMark is set in document. */
diff --git a/sw/inc/format.hxx b/sw/inc/format.hxx
index d04799bcf7fd..8a64b121e76c 100644
--- a/sw/inc/format.hxx
+++ b/sw/inc/format.hxx
@@ -109,7 +109,7 @@ public:
bool IsDefault() const { return DerivedFrom() == nullptr; }
const OUString& GetName() const { return m_aFormatName; }
- bool HasName(const OUString &rName) const { return m_aFormatName == rName; }
+ bool HasName(std::u16string_view rName) const { return m_aFormatName == rName; }
virtual void SetName( const OUString& rNewName, bool bBroadcast=false );
/// For querying the attribute array.
diff --git a/sw/inc/iodetect.hxx b/sw/inc/iodetect.hxx
index 53abd6872486..534b3c1f2bb5 100644
--- a/sw/inc/iodetect.hxx
+++ b/sw/inc/iodetect.hxx
@@ -28,11 +28,11 @@
#define FILTER_RTF "RTF" ///< RTF filter
#define sRtfWH "WH_RTF"
-#define FILTER_TEXT "TEXT" ///< text filter with default codeset
+#define FILTER_TEXT u"TEXT" ///< text filter with default codeset
#define FILTER_BAS "BAS" ///< StarBasic (identical to ANSI)
#define FILTER_WW8 "CWW8" ///< WinWord 97 filter
#define FILTER_TEXT_DLG "TEXT_DLG" ///< text filter with encoding dialog
-#define FILTER_XML "CXML" ///< XML filter
+#define FILTER_XML u"CXML" ///< XML filter
#define FILTER_XMLV "CXMLV" ///< XML filter
#define FILTER_XMLVW "CXMLVWEB" ///< XML filter
#define FILTER_DOCX "OXML"
@@ -92,7 +92,7 @@ class SwIoSystem
public:
/// find for an internal format name the corresponding filter entry
SW_DLLPUBLIC static std::shared_ptr<const SfxFilter>
- GetFilterOfFormat( const OUString& rFormat,
+ GetFilterOfFormat( std::u16string_view rFormat,
const SfxFilterContainer* pCnt = nullptr );
/** Detect for the given file which filter should be used. The filter name
diff --git a/sw/inc/pagedesc.hxx b/sw/inc/pagedesc.hxx
index 44bb7ee33b52..7f2eaa9c9d53 100644
--- a/sw/inc/pagedesc.hxx
+++ b/sw/inc/pagedesc.hxx
@@ -267,7 +267,7 @@ public:
/// Given a SwNode return the pagedesc in use at that location.
static const SwPageDesc* GetPageDescOfNode(const SwNode& rNd);
- static SwPageDesc* GetByName(SwDoc& rDoc, const OUString& rName);
+ static SwPageDesc* GetByName(SwDoc& rDoc, std::u16string_view rName);
SwPageDesc& operator=( const SwPageDesc& );
@@ -280,9 +280,9 @@ public:
namespace std {
template<>
struct less<SwPageDesc*> {
- bool operator()(const SwPageDesc *pPageDesc, const OUString &rName) const
+ bool operator()(const SwPageDesc *pPageDesc, std::u16string_view rName) const
{ return pPageDesc->GetName() < rName; }
- bool operator()(const OUString &rName, const SwPageDesc *pPageDesc) const
+ bool operator()(std::u16string_view rName, const SwPageDesc *pPageDesc) const
{ return rName < pPageDesc->GetName(); }
bool operator()(const SwPageDesc *lhs, const SwPageDesc *rhs) const
{ return lhs->GetName() < rhs->GetName(); }
diff --git a/sw/inc/swcrsr.hxx b/sw/inc/swcrsr.hxx
index 9aa390386221..234b0196d68e 100644
--- a/sw/inc/swcrsr.hxx
+++ b/sw/inc/swcrsr.hxx
@@ -175,7 +175,7 @@ public:
bool GoPrevCell( sal_uInt16 nCnt = 1 ) { return GoPrevNextCell( false, nCnt ); }
virtual bool GotoTable( const OUString& rName );
bool GotoTableBox( const OUString& rName );
- bool GotoRegion( const OUString& rName );
+ bool GotoRegion( std::u16string_view rName );
bool GotoFootnoteAnchor();
bool GotoFootnoteText();
bool GotoNextFootnoteAnchor();
diff --git a/sw/inc/tblafmt.hxx b/sw/inc/tblafmt.hxx
index 0a6866c3cb2a..2873f51e9196 100644
--- a/sw/inc/tblafmt.hxx
+++ b/sw/inc/tblafmt.hxx
@@ -292,7 +292,7 @@ public:
std::unique_ptr<SwTableAutoFormat> ReleaseAutoFormat(const OUString& rName);
/// Find table style with the provided name, return nullptr when not found.
- SwTableAutoFormat* FindAutoFormat(const OUString& rName) const;
+ SwTableAutoFormat* FindAutoFormat(std::u16string_view rName) const;
void Load();
bool Save() const;
@@ -321,11 +321,11 @@ public:
/// Add a copy of rBoxFormat
void AddBoxFormat(const SwBoxAutoFormat& rBoxFormat, const OUString& sName);
void RemoveBoxFormat(const OUString& sName);
- void ChangeBoxFormatName(const OUString& sFromName, const OUString& sToName);
+ void ChangeBoxFormatName(std::u16string_view sFromName, const OUString& sToName);
/// If found returns its name. If not found returns an empty OUString
OUString GetBoxFormatName(const SwBoxAutoFormat& rBoxFormat) const;
/// If found returns a ptr to a BoxFormat. If not found returns nullptr
- SwBoxAutoFormat* GetBoxFormat(const OUString& sName) const;
+ SwBoxAutoFormat* GetBoxFormat(std::u16string_view sName) const;
};
#endif
diff --git a/sw/inc/unostyle.hxx b/sw/inc/unostyle.hxx
index 0b40d1e73249..a865a3880d75 100644
--- a/sw/inc/unostyle.hxx
+++ b/sw/inc/unostyle.hxx
@@ -275,7 +275,7 @@ public:
SwXTextTableStyle(SwDocShell* pDocShell, const OUString& rTableAutoFormatName);
/// This function looks for a SwTableAutoFormat with given name. Returns nullptr if could not be found.
- static SwTableAutoFormat* GetTableAutoFormat(SwDocShell* pDocShell, const OUString& sName);
+ static SwTableAutoFormat* GetTableAutoFormat(SwDocShell* pDocShell, std::u16string_view sName);
/// Returns box format assigned to this style
SwTableAutoFormat* GetTableFormat();
void SetPhysical();
diff --git a/sw/qa/core/uwriter.cxx b/sw/qa/core/uwriter.cxx
index 676811c5baf3..868710550c2d 100644
--- a/sw/qa/core/uwriter.cxx
+++ b/sw/qa/core/uwriter.cxx
@@ -1403,7 +1403,7 @@ void SwDocTest::testTableAutoFormats()
CPPUNIT_ASSERT_EQUAL( size_t(2), aLoadTAFT.size() );
//assert the values
- SwTableAutoFormat* pLoadAF = aLoadTAFT.FindAutoFormat( "TestItemStyle" );
+ SwTableAutoFormat* pLoadAF = aLoadTAFT.FindAutoFormat( u"TestItemStyle" );
CPPUNIT_ASSERT( pLoadAF );
//GetFont
CPPUNIT_ASSERT( bool( pLoadAF->GetBoxFormat(0).GetFont() == aFont ) );
diff --git a/sw/qa/extras/layout/layout.cxx b/sw/qa/extras/layout/layout.cxx
index 4b6e9c22bd62..e2481d58686b 100644
--- a/sw/qa/extras/layout/layout.cxx
+++ b/sw/qa/extras/layout/layout.cxx
@@ -541,7 +541,7 @@ CPPUNIT_TEST_FIXTURE(SwLayoutWriter, testRedlineFlysInHeader)
SwWrtShell* pWrtShell = pTextDoc->GetDocShell()->GetWrtShell();
SwRootFrame* pLayout(pWrtShell->GetLayout());
CPPUNIT_ASSERT(!pLayout->IsHideRedlines());
- pWrtShell->ChangeHeaderOrFooter("Default Page Style", /*bHeader*/ true, /*bOn*/ true, false);
+ pWrtShell->ChangeHeaderOrFooter(u"Default Page Style", /*bHeader*/ true, /*bOn*/ true, false);
CPPUNIT_ASSERT(
pWrtShell
->IsInHeaderFooter()); // assume this is supposed to put cursor in the new header...
diff --git a/sw/qa/extras/odfimport/odfimport.cxx b/sw/qa/extras/odfimport/odfimport.cxx
index 73ce92082e60..3fc4f8e77cf1 100644
--- a/sw/qa/extras/odfimport/odfimport.cxx
+++ b/sw/qa/extras/odfimport/odfimport.cxx
@@ -897,9 +897,9 @@ DECLARE_ODFIMPORT_TEST(testTdf107392, "tdf107392.odt")
// as sorting failed.
// So instead of 0, 1, 2 these were 2, 0, 1.
- CPPUNIT_ASSERT_EQUAL(sal_Int32(0), getProperty<sal_Int32>(getShapeByName("Bitmap"), "ZOrder"));
- CPPUNIT_ASSERT_EQUAL(sal_Int32(1), getProperty<sal_Int32>(getShapeByName("Frame"), "ZOrder"));
- CPPUNIT_ASSERT_EQUAL(sal_Int32(2), getProperty<sal_Int32>(getShapeByName("SVG"), "ZOrder"));
+ CPPUNIT_ASSERT_EQUAL(sal_Int32(0), getProperty<sal_Int32>(getShapeByName(u"Bitmap"), "ZOrder"));
+ CPPUNIT_ASSERT_EQUAL(sal_Int32(1), getProperty<sal_Int32>(getShapeByName(u"Frame"), "ZOrder"));
+ CPPUNIT_ASSERT_EQUAL(sal_Int32(2), getProperty<sal_Int32>(getShapeByName(u"SVG"), "ZOrder"));
}
DECLARE_ODFIMPORT_TEST(testTdf100033_1, "tdf100033_1.odt")
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport10.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport10.cxx
index 47307b49789e..99cbb7fa4ee5 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport10.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport10.cxx
@@ -519,7 +519,7 @@ DECLARE_OOXMLEXPORT_TEST(testStrict, "strict.docx")
getParagraphOfText(1, xHeaderText, "This is a header.");
// Picture was missing.
- uno::Reference<lang::XServiceInfo> xServiceInfo(getShapeByName("Picture 2"), uno::UNO_QUERY);
+ uno::Reference<lang::XServiceInfo> xServiceInfo(getShapeByName(u"Picture 2"), uno::UNO_QUERY);
CPPUNIT_ASSERT(xServiceInfo->supportsService("com.sun.star.text.TextGraphicObject"));
// SmartArt was missing.
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
index daaecd43df9f..459d72d38605 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
@@ -627,10 +627,10 @@ DECLARE_OOXMLEXPORT_TEST(testTdf119201, "tdf119201.docx")
auto xShape(getShape(1));
CPPUNIT_ASSERT_MESSAGE("First shape should be visible.", getProperty<bool>(xShape, "Visible"));
CPPUNIT_ASSERT_MESSAGE("First shape should be printable.", getProperty<bool>(xShape, "Printable"));
- xShape = getShapeByName("Rectangle 1");
+ xShape = getShapeByName(u"Rectangle 1");
CPPUNIT_ASSERT_MESSAGE("Second shape should not be visible.", !getProperty<bool>(xShape, "Visible"));
CPPUNIT_ASSERT_MESSAGE("Second shape should not be printable.", !getProperty<bool>(xShape, "Printable"));
- xShape = getShapeByName("Oval 2");
+ xShape = getShapeByName(u"Oval 2");
CPPUNIT_ASSERT_MESSAGE("Third shape should be visible.", getProperty<bool>(xShape, "Visible"));
CPPUNIT_ASSERT_MESSAGE("Third shape should be printable.", getProperty<bool>(xShape, "Printable"));
}
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
index e4287f12e978..e503fe92bf6e 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
@@ -1055,7 +1055,7 @@ DECLARE_OOXMLEXPORT_TEST(testTdf102466, "tdf102466.docx")
// check content of the first page
{
- uno::Reference<beans::XPropertySet> xFrame(getShapeByName("Marco1"), uno::UNO_QUERY);
+ uno::Reference<beans::XPropertySet> xFrame(getShapeByName(u"Marco1"), uno::UNO_QUERY);
// no border
CPPUNIT_ASSERT_EQUAL(sal_Int32(0), getProperty<sal_Int32>(xFrame, "LineWidth"));
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport6.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport6.cxx
index cb00fff1f684..a2391cbe31b3 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport6.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport6.cxx
@@ -244,13 +244,13 @@ DECLARE_OOXMLEXPORT_TEST(testDMLTextFrameVertAdjust, "dml-textframe-vertadjust.d
// TextVerticalAdjust attribute so far.
// 1st frame's context is adjusted to the top
- uno::Reference<beans::XPropertySet> xFrame(getShapeByName("Rectangle 1"), uno::UNO_QUERY);
+ uno::Reference<beans::XPropertySet> xFrame(getShapeByName(u"Rectangle 1"), uno::UNO_QUERY);
CPPUNIT_ASSERT_EQUAL(drawing::TextVerticalAdjust_TOP, getProperty<drawing::TextVerticalAdjust>(xFrame, "TextVerticalAdjust"));
// 2nd frame's context is adjusted to the center
- xFrame.set(getShapeByName("Rectangle 2"), uno::UNO_QUERY);
+ xFrame.set(getShapeByName(u"Rectangle 2"), uno::UNO_QUERY);
CPPUNIT_ASSERT_EQUAL(drawing::TextVerticalAdjust_CENTER, getProperty<drawing::TextVerticalAdjust>(xFrame, "TextVerticalAdjust"));
// 3rd frame's context is adjusted to the bottom
- xFrame.set(getShapeByName("Rectangle 3"), uno::UNO_QUERY);
+ xFrame.set(getShapeByName(u"Rectangle 3"), uno::UNO_QUERY);
CPPUNIT_ASSERT_EQUAL(drawing::TextVerticalAdjust_BOTTOM, getProperty<drawing::TextVerticalAdjust>(xFrame, "TextVerticalAdjust"));
}
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport9.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport9.cxx
index b9f01391e3f2..251bc2dcb952 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport9.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport9.cxx
@@ -795,7 +795,7 @@ DECLARE_OOXMLEXPORT_TEST(testTdf103573, "tdf103573.docx")
DECLARE_OOXMLEXPORT_TEST(testTdf106132, "tdf106132.docx")
{
- uno::Reference<beans::XPropertySet> xShape(getShapeByName("Frame1"), uno::UNO_QUERY);
+ uno::Reference<beans::XPropertySet> xShape(getShapeByName(u"Frame1"), uno::UNO_QUERY);
// This was 250, <wps:bodyPr ... rIns="0" ...> was ignored for an outer shape.
CPPUNIT_ASSERT_EQUAL(static_cast<sal_Int32>(0), getProperty<sal_Int32>(xShape, "TextRightDistance"));
}
diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx
index ec680a69a6ad..e39d475d8718 100644
--- a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx
+++ b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx
@@ -1324,7 +1324,7 @@ DECLARE_OOXMLIMPORT_TEST(testFdo87488, "fdo87488.docx")
DECLARE_OOXMLIMPORT_TEST(testTdf85232, "tdf85232.docx")
{
- uno::Reference<drawing::XShapes> xShapes(getShapeByName("Group 219"), uno::UNO_QUERY);
+ uno::Reference<drawing::XShapes> xShapes(getShapeByName(u"Group 219"), uno::UNO_QUERY);
uno::Reference<drawing::XShape> xShape(xShapes->getByIndex(1), uno::UNO_QUERY);
uno::Reference<drawing::XShapeDescriptor> xShapeDescriptor = xShape;
// Make sure we're not testing the ellipse child.
diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport2.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport2.cxx
index 85317503c90a..b0589b913248 100644
--- a/sw/qa/extras/ooxmlimport/ooxmlimport2.cxx
+++ b/sw/qa/extras/ooxmlimport/ooxmlimport2.cxx
@@ -118,7 +118,7 @@ DECLARE_OOXMLIMPORT_TEST(testTdf97038, "tdf97038.docx")
{
// Without the accompanying fix in place, this test would have failed, as the importer lost the
// fLayoutInCell shape property for wrap-though shapes.
- CPPUNIT_ASSERT(getProperty<bool>(getShapeByName("Kep2"), "IsFollowingTextFlow"));
+ CPPUNIT_ASSERT(getProperty<bool>(getShapeByName(u"Kep2"), "IsFollowingTextFlow"));
}
DECLARE_OOXMLIMPORT_TEST(testTdf114212, "tdf114212.docx")
@@ -511,8 +511,8 @@ DECLARE_OOXMLIMPORT_TEST(testTdf115094v2, "tdf115094v2.docx")
{
// layoutInCell="1" combined with <wp:wrapNone/>
- CPPUNIT_ASSERT(getProperty<bool>(getShapeByName("Grafik 18"), "IsFollowingTextFlow"));
- CPPUNIT_ASSERT(getProperty<bool>(getShapeByName("Grafik 19"), "IsFollowingTextFlow"));
+ CPPUNIT_ASSERT(getProperty<bool>(getShapeByName(u"Grafik 18"), "IsFollowingTextFlow"));
+ CPPUNIT_ASSERT(getProperty<bool>(getShapeByName(u"Grafik 19"), "IsFollowingTextFlow"));
}
DECLARE_OOXMLIMPORT_TEST(testTdf122224, "tdf122224.docx")
diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx b/sw/qa/extras/rtfimport/rtfimport.cxx
index e1c940a00e7f..399ca38e0ab2 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -1354,22 +1354,22 @@ CPPUNIT_TEST_FIXTURE(Test, testFlip)
{
load(mpTestDocumentPath, "flip.rtf");
comphelper::SequenceAsHashMap aMap = getProperty<uno::Sequence<beans::PropertyValue>>(
- getShapeByName("h-and-v"), "CustomShapeGeometry");
+ getShapeByName(u"h-and-v"), "CustomShapeGeometry");
// This resulted in a uno::RuntimeException, as MirroredX wasn't set at all, so could not extract void to boolean.
CPPUNIT_ASSERT_EQUAL(true, aMap["MirroredX"].get<bool>());
CPPUNIT_ASSERT_EQUAL(true, aMap["MirroredY"].get<bool>());
- aMap = getProperty<uno::Sequence<beans::PropertyValue>>(getShapeByName("h-only"),
+ aMap = getProperty<uno::Sequence<beans::PropertyValue>>(getShapeByName(u"h-only"),
"CustomShapeGeometry");
CPPUNIT_ASSERT_EQUAL(true, aMap["MirroredX"].get<bool>());
CPPUNIT_ASSERT(!aMap["MirroredY"].hasValue());
- aMap = getProperty<uno::Sequence<beans::PropertyValue>>(getShapeByName("v-only"),
+ aMap = getProperty<uno::Sequence<beans::PropertyValue>>(getShapeByName(u"v-only"),
"CustomShapeGeometry");
CPPUNIT_ASSERT(!aMap["MirroredX"].hasValue());
CPPUNIT_ASSERT_EQUAL(true, aMap["MirroredY"].get<bool>());
- aMap = getProperty<uno::Sequence<beans::PropertyValue>>(getShapeByName("neither-h-nor-v"),
+ aMap = getProperty<uno::Sequence<beans::PropertyValue>>(getShapeByName(u"neither-h-nor-v"),
"CustomShapeGeometry");
CPPUNIT_ASSERT(!aMap["MirroredX"].hasValue());
CPPUNIT_ASSERT(!aMap["MirroredY"].hasValue());
diff --git a/sw/qa/extras/uiwriter/uiwriter.cxx b/sw/qa/extras/uiwriter/uiwriter.cxx
index 21b3e2f3b958..9e88e37f2aaa 100644
--- a/sw/qa/extras/uiwriter/uiwriter.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter.cxx
@@ -2162,7 +2162,7 @@ void SwUiWriterTest::testTextCursorInvalidation()
// can't go right in empty header
CPPUNIT_ASSERT(!xCursor->goRight(1, false));
// this does not actually delete the header: xPageStyle->setPropertyValue("HeaderIsOn", uno::makeAny(false));
- pWrtShell->ChangeHeaderOrFooter("Default Page Style", true, false, false);
+ pWrtShell->ChangeHeaderOrFooter(u"Default Page Style", true, false, false);
// must be disposed after deleting header
CPPUNIT_ASSERT_THROW(xCursor->goRight(1, false), uno::RuntimeException);
}
@@ -2506,7 +2506,7 @@ void SwUiWriterTest::testTdf79236()
SwDoc* pDoc = createDoc();
sw::UndoManager& rUndoManager = pDoc->GetUndoManager();
//Getting some paragraph style
- SwTextFormatColl* pTextFormat = pDoc->FindTextFormatCollByName("Text Body");
+ SwTextFormatColl* pTextFormat = pDoc->FindTextFormatCollByName(u"Text Body");
const SwAttrSet& rAttrSet = pTextFormat->GetAttrSet();
std::unique_ptr<SfxItemSet> pNewSet = rAttrSet.Clone();
sal_uInt16 initialCount = pNewSet->Count();
@@ -2527,7 +2527,7 @@ void SwUiWriterTest::testTdf79236()
//Setting the updated item set on the style
pDoc->ChgFormat(*pTextFormat, *pNewSet);
//Checking the Changes
- SwTextFormatColl* pTextFormat2 = pDoc->FindTextFormatCollByName("Text Body");
+ SwTextFormatColl* pTextFormat2 = pDoc->FindTextFormatCollByName(u"Text Body");
const SwAttrSet& rAttrSet2 = pTextFormat2->GetAttrSet();
const SvxAdjustItem& rAdjustItem2 = rAttrSet2.GetAdjust();
SvxAdjust Adjust2 = rAdjustItem2.GetAdjust();
@@ -2535,7 +2535,7 @@ void SwUiWriterTest::testTdf79236()
CPPUNIT_ASSERT_EQUAL(SvxAdjust::Right, Adjust2);
//Undo the changes
rUndoManager.Undo();
- SwTextFormatColl* pTextFormat3 = pDoc->FindTextFormatCollByName("Text Body");
+ SwTextFormatColl* pTextFormat3 = pDoc->FindTextFormatCollByName(u"Text Body");
const SwAttrSet& rAttrSet3 = pTextFormat3->GetAttrSet();
const SvxAdjustItem& rAdjustItem3 = rAttrSet3.GetAdjust();
SvxAdjust Adjust3 = rAdjustItem3.GetAdjust();
@@ -2543,7 +2543,7 @@ void SwUiWriterTest::testTdf79236()
CPPUNIT_ASSERT_EQUAL(SvxAdjust::Left, Adjust3);
//Redo the changes
rUndoManager.Redo();
- SwTextFormatColl* pTextFormat4 = pDoc->FindTextFormatCollByName("Text Body");
+ SwTextFormatColl* pTextFormat4 = pDoc->FindTextFormatCollByName(u"Text Body");
const SwAttrSet& rAttrSet4 = pTextFormat4->GetAttrSet();
const SvxAdjustItem& rAdjustItem4 = rAttrSet4.GetAdjust();
SvxAdjust Adjust4 = rAdjustItem4.GetAdjust();
@@ -2551,7 +2551,7 @@ void SwUiWriterTest::testTdf79236()
CPPUNIT_ASSERT_EQUAL(SvxAdjust::Right, Adjust4);
//Undo the changes
rUndoManager.Undo();
- SwTextFormatColl* pTextFormat5 = pDoc->FindTextFormatCollByName("Text Body");
+ SwTextFormatColl* pTextFormat5 = pDoc->FindTextFormatCollByName(u"Text Body");
const SwAttrSet& rAttrSet5 = pTextFormat5->GetAttrSet();
const SvxAdjustItem& rAdjustItem5 = rAttrSet5.GetAdjust();
SvxAdjust Adjust5 = rAdjustItem5.GetAdjust();
@@ -2960,7 +2960,7 @@ void SwUiWriterTest::testTdf60967()
SwWrtShell* pWrtShell = pDoc->GetDocShell()->GetWrtShell();
SwPaM* pCursor = pDoc->GetEditShell()->GetCursor();
sw::UndoManager& rUndoManager = pDoc->GetUndoManager();
- pWrtShell->ChangeHeaderOrFooter("Default Page Style", true, true, true);
+ pWrtShell->ChangeHeaderOrFooter(u"Default Page Style", true, true, true);
//Inserting table
SwInsertTableOptions TableOpt(SwInsertTableFlags::DefaultBorder, 0);
pWrtShell->InsertTable(TableOpt, 2, 2);
@@ -4372,7 +4372,7 @@ void SwUiWriterTest::testTdf86639()
{
SwDoc* pDoc = createDoc("tdf86639.rtf");
SwWrtShell* pWrtShell = pDoc->GetDocShell()->GetWrtShell();
- SwTextFormatColl* pColl = pDoc->FindTextFormatCollByName("Heading");
+ SwTextFormatColl* pColl = pDoc->FindTextFormatCollByName(u"Heading");
pWrtShell->SetTextFormatColl(pColl);
OUString aExpected = pColl->GetAttrSet().GetFont().GetFamilyName();
// This was Calibri, should be Liberation Sans.
@@ -5690,7 +5690,7 @@ void SwUiWriterTest::testTableStyleUndo()
rUndoManager.Redo();
CPPUNIT_ASSERT_EQUAL(sal_Int32(pDoc->GetTableStyles().size()), nStyleCount + 1);
// check if attributes are preserved
- pStyle = pDoc->GetTableStyles().FindAutoFormat("Test Style");
+ pStyle = pDoc->GetTableStyles().FindAutoFormat(u"Test Style");
CPPUNIT_ASSERT(pStyle);
CPPUNIT_ASSERT(bool(pStyle->GetBoxFormat(0).GetBackground() == aBackground));
@@ -5698,7 +5698,7 @@ void SwUiWriterTest::testTableStyleUndo()
CPPUNIT_ASSERT_EQUAL(sal_Int32(pDoc->GetTableStyles().size()), nStyleCount);
rUndoManager.Undo();
CPPUNIT_ASSERT_EQUAL(sal_Int32(pDoc->GetTableStyles().size()), nStyleCount + 1);
- pStyle = pDoc->GetTableStyles().FindAutoFormat("Test Style");
+ pStyle = pDoc->GetTableStyles().FindAutoFormat(u"Test Style");
// check if attributes are preserved
CPPUNIT_ASSERT(pStyle);
CPPUNIT_ASSERT(bool(pStyle->GetBoxFormat(0).GetBackground() == aBackground));
@@ -5708,7 +5708,7 @@ void SwUiWriterTest::testTableStyleUndo()
// undo delete so we can replace the style
rUndoManager.Undo();
CPPUNIT_ASSERT_EQUAL(sal_Int32(pDoc->GetTableStyles().size()), nStyleCount +1 );
- pStyle = pDoc->GetTableStyles().FindAutoFormat("Test Style");
+ pStyle = pDoc->GetTableStyles().FindAutoFormat(u"Test Style");
CPPUNIT_ASSERT(pStyle);
CPPUNIT_ASSERT(bool(pStyle->GetBoxFormat(0).GetBackground() == aBackground));
@@ -5717,15 +5717,15 @@ void SwUiWriterTest::testTableStyleUndo()
aNewStyle.GetBoxFormat(0).SetBackground(aBackground2);
pDoc->ChgTableStyle("Test Style", aNewStyle);
- pStyle = pDoc->GetTableStyles().FindAutoFormat("Test Style");
+ pStyle = pDoc->GetTableStyles().FindAutoFormat(u"Test Style");
CPPUNIT_ASSERT(pStyle);
CPPUNIT_ASSERT(bool(pStyle->GetBoxFormat(0).GetBackground() == aBackground2));
rUndoManager.Undo();
- pStyle = pDoc->GetTableStyles().FindAutoFormat("Test Style");
+ pStyle = pDoc->GetTableStyles().FindAutoFormat(u"Test Style");
CPPUNIT_ASSERT(pStyle);
CPPUNIT_ASSERT(bool(pStyle->GetBoxFormat(0).GetBackground() == aBackground));
rUndoManager.Redo();
- pStyle = pDoc->GetTableStyles().FindAutoFormat("Test Style");
+ pStyle = pDoc->GetTableStyles().FindAutoFormat(u"Test Style");
CPPUNIT_ASSERT(pStyle);
CPPUNIT_ASSERT(bool(pStyle->GetBoxFormat(0).GetBackground() == aBackground2));
}
diff --git a/sw/qa/extras/unowriter/unowriter.cxx b/sw/qa/extras/unowriter/unowriter.cxx
index 895728bd412f..a316f3485777 100644
--- a/sw/qa/extras/unowriter/unowriter.cxx
+++ b/sw/qa/extras/unowriter/unowriter.cxx
@@ -284,7 +284,7 @@ CPPUNIT_TEST_FIXTURE(SwUnoWriter, testGraphicDescriptorURLBitmap)
}
static bool ensureAutoTextExistsByTitle(const uno::Reference<text::XAutoTextGroup>& autoTextGroup,
- const OUString& autoTextName)
+ std::u16string_view autoTextName)
{
const uno::Sequence<OUString> aTitles(autoTextGroup->getTitles());
for (const auto& rTitle : aTitles)
@@ -296,7 +296,7 @@ static bool ensureAutoTextExistsByTitle(const uno::Reference<text::XAutoTextGrou
}
static bool ensureAutoTextExistsByName(const uno::Reference<text::XAutoTextGroup>& autoTextGroup,
- const OUString& autoTextName)
+ std::u16string_view autoTextName)
{
const uno::Sequence<OUString> aTitles(autoTextGroup->getElementNames());
for (const auto& rTitle : aTitles)
diff --git a/sw/qa/extras/ww8import/ww8import.cxx b/sw/qa/extras/ww8import/ww8import.cxx
index 9cbae7f83a3a..d63310b661c6 100644
--- a/sw/qa/extras/ww8import/ww8import.cxx
+++ b/sw/qa/extras/ww8import/ww8import.cxx
@@ -90,8 +90,8 @@ DECLARE_WW8IMPORT_TEST(testTdf124601, "tdf124601.doc")
{
// Without the accompanying fix in place, this test would have failed, as the importer lost the
// fLayoutInCell shape property for wrap-though shapes.
- CPPUNIT_ASSERT(getProperty<bool>(getShapeByName("Grafik 18"), "IsFollowingTextFlow"));
- CPPUNIT_ASSERT(getProperty<bool>(getShapeByName("Grafik 19"), "IsFollowingTextFlow"));
+ CPPUNIT_ASSERT(getProperty<bool>(getShapeByName(u"Grafik 18"), "IsFollowingTextFlow"));
+ CPPUNIT_ASSERT(getProperty<bool>(getShapeByName(u"Grafik 19"), "IsFollowingTextFlow"));
}
DECLARE_WW8IMPORT_TEST(testImageLazyRead, "image-lazy-read.doc")
diff --git a/sw/qa/inc/swmodeltestbase.hxx b/sw/qa/inc/swmodeltestbase.hxx
index cff9a4ca14c1..faaad80c6a7c 100644
--- a/sw/qa/inc/swmodeltestbase.hxx
+++ b/sw/qa/inc/swmodeltestbase.hxx
@@ -333,7 +333,7 @@ protected:
css::uno::Reference<css::drawing::XShape> getShape(int number);
/// Get shape by name
- css::uno::Reference<css::drawing::XShape> getShapeByName(const OUString& aName);
+ css::uno::Reference<css::drawing::XShape> getShapeByName(std::u16string_view aName);
/// Get TextFrame by name
css::uno::Reference<css::drawing::XShape> getTextFrameByName(const OUString& aName);
diff --git a/sw/qa/unit/swmodeltestbase.cxx b/sw/qa/unit/swmodeltestbase.cxx
index b520967b21f4..b69ade4d1b8e 100644
--- a/sw/qa/unit/swmodeltestbase.cxx
+++ b/sw/qa/unit/swmodeltestbase.cxx
@@ -440,7 +440,7 @@ uno::Reference<drawing::XShape> SwModelTestBase::getShape(int number)
return xShape;
}
-uno::Reference<drawing::XShape> SwModelTestBase::getShapeByName(const OUString& aName)
+uno::Reference<drawing::XShape> SwModelTestBase::getShapeByName(std::u16string_view aName)
{
uno::Reference<drawing::XShape> xRet;
diff --git a/sw/source/core/crsr/crstrvl.cxx b/sw/source/core/crsr/crstrvl.cxx
index 7e27e1ee899a..a41f3ae86799 100644
--- a/sw/source/core/crsr/crstrvl.cxx
+++ b/sw/source/core/crsr/crstrvl.cxx
@@ -2011,7 +2011,7 @@ bool SwCursorShell::GotoINetAttr( const SwTextINetFormat& rAttr )
return bRet;
}
-const SwFormatINetFormat* SwCursorShell::FindINetAttr( const OUString& rName ) const
+const SwFormatINetFormat* SwCursorShell::FindINetAttr( std::u16string_view rName ) const
{
return mxDoc->FindINetAttr( rName );
}
diff --git a/sw/source/core/crsr/trvlreg.cxx b/sw/source/core/crsr/trvlreg.cxx
index 190edf13f0a8..07d9061672aa 100644
--- a/sw/source/core/crsr/trvlreg.cxx
+++ b/sw/source/core/crsr/trvlreg.cxx
@@ -242,7 +242,7 @@ bool SwCursorShell::MoveRegion( SwWhichRegion fnWhichRegion, SwMoveFnCollection
return bRet;
}
-bool SwCursor::GotoRegion( const OUString& rName )
+bool SwCursor::GotoRegion( std::u16string_view rName )
{
bool bRet = false;
const SwSectionFormats& rFormats = GetDoc().GetSections();
@@ -267,7 +267,7 @@ bool SwCursor::GotoRegion( const OUString& rName )
return bRet;
}
-bool SwCursorShell::GotoRegion( const OUString& rName )
+bool SwCursorShell::GotoRegion( std::u16string_view rName )
{
SwCallLink aLk( *this ); // watch Cursor-Moves;call Link if needed
bool bRet = !m_pTableCursor && m_pCurrentCursor->GotoRegion( rName );
diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx
index c971d32f4ac9..9b3b3bb70991 100644
--- a/sw/source/core/doc/doc.cxx
+++ b/sw/source/core/doc/doc.cxx
@@ -1043,7 +1043,7 @@ void SwDoc::CalculatePagePairsForProspectPrinting(
}
/// @return the reference in the doc for the name
-const SwFormatRefMark* SwDoc::GetRefMark( const OUString& rName ) const
+const SwFormatRefMark* SwDoc::GetRefMark( std::u16string_view rName ) const
{
for (const SfxPoolItem* pItem : GetAttrPool().GetItemSurrogates(RES_TXTATR_REFMARK))
{
@@ -1200,7 +1200,7 @@ void SwDoc::InvalidateAutoCompleteFlag()
aLayout->SetIdleFlags();
}
-const SwFormatINetFormat* SwDoc::FindINetAttr( const OUString& rName ) const
+const SwFormatINetFormat* SwDoc::FindINetAttr( std::u16string_view rName ) const
{
for (const SfxPoolItem* pItem : GetAttrPool().GetItemSurrogates(RES_TXTATR_INETFMT))
{
diff --git a/sw/source/core/doc/docchart.cxx b/sw/source/core/doc/docchart.cxx
index 0e2cef59555b..053fbad4f3ee 100644
--- a/sw/source/core/doc/docchart.cxx
+++ b/sw/source/core/doc/docchart.cxx
@@ -117,7 +117,7 @@ void SwDoc::UpdateCharts_( const SwTable& rTable, SwViewShell const & rVSh ) con
}
}
-void SwDoc::UpdateCharts( const OUString &rName ) const
+void SwDoc::UpdateCharts( std::u16string_view rName ) const
{
SwTable* pTmpTable = SwTable::FindTable( FindTableFormatByName( rName ) );
if( pTmpTable )
diff --git a/sw/source/core/doc/docfmt.cxx b/sw/source/core/doc/docfmt.cxx
index a27aad094ce2..281e9cb9de64 100644
--- a/sw/source/core/doc/docfmt.cxx
+++ b/sw/source/core/doc/docfmt.cxx
@@ -731,7 +731,7 @@ void SwDoc::DelTableFrameFormat( SwTableFormat *pFormat )
delete pFormat;
}
-SwFrameFormat* SwDoc::FindFrameFormatByName( const OUString& rName ) const
+SwFrameFormat* SwDoc::FindFrameFormatByName( std::u16string_view rName ) const
{
return static_cast<SwFrameFormat*>(FindFormatByName( static_cast<SwFormatsBase&>(*mpFrameFormatTable), rName ));
}
@@ -1608,7 +1608,7 @@ void SwDoc::ReplaceStyles( const SwDoc& rSource, bool bIncludePageStyles )
}
SwFormat* SwDoc::FindFormatByName( const SwFormatsBase& rFormatArr,
- const OUString& rName )
+ std::u16string_view rName )
{
SwFormat* pFnd = nullptr;
for( size_t n = 0; n < rFormatArr.GetFormatCount(); ++n )
diff --git a/sw/source/core/doc/docglbl.cxx b/sw/source/core/doc/docglbl.cxx
index b933843ff6b3..176a1a2a443c 100644
--- a/sw/source/core/doc/docglbl.cxx
+++ b/sw/source/core/doc/docglbl.cxx
@@ -207,7 +207,7 @@ bool SwDoc::SplitDoc( sal_uInt16 eDocType, const OUString& rPath, bool bOutline,
switch( eDocType )
{
case SPLITDOC_TO_HTML:
- pFilter = SwIoSystem::GetFilterOfFormat("HTML");
+ pFilter = SwIoSystem::GetFilterOfFormat(u"HTML");
break;
default:
diff --git a/sw/source/core/doc/docnum.cxx b/sw/source/core/doc/docnum.cxx
index d84574375112..29905b64a246 100644
--- a/sw/source/core/doc/docnum.cxx
+++ b/sw/source/core/doc/docnum.cxx
@@ -2402,7 +2402,7 @@ SwNumRule* SwDoc::GetNumRuleAtPos(SwPosition& rPos,
return pRet;
}
-sal_uInt16 SwDoc::FindNumRule( const OUString& rName ) const
+sal_uInt16 SwDoc::FindNumRule( std::u16string_view rName ) const
{
for( sal_uInt16 n = mpNumRuleTable->size(); n; )
if( (*mpNumRuleTable)[ --n ]->GetName() == rName )
diff --git a/sw/source/core/doc/tblafmt.cxx b/sw/source/core/doc/tblafmt.cxx
index 2289b2290f3e..558c8d6f827d 100644
--- a/sw/source/core/doc/tblafmt.cxx
+++ b/sw/source/core/doc/tblafmt.cxx
@@ -992,7 +992,7 @@ std::unique_ptr<SwTableAutoFormat> SwTableAutoFormatTable::ReleaseAutoFormat(con
return pRet;
}
-SwTableAutoFormat* SwTableAutoFormatTable::FindAutoFormat(const OUString& rName) const
+SwTableAutoFormat* SwTableAutoFormatTable::FindAutoFormat(std::u16string_view rName) const
{
for (const auto &rFormat : m_pImpl->m_AutoFormats)
{
@@ -1218,7 +1218,7 @@ OUString SwCellStyleTable::GetBoxFormatName(const SwBoxAutoFormat& rBoxFormat) c
return OUString();
}
-SwBoxAutoFormat* SwCellStyleTable::GetBoxFormat(const OUString& sName) const
+SwBoxAutoFormat* SwCellStyleTable::GetBoxFormat(std::u16string_view sName) const
{
for (size_t i=0; i < m_aCellStyles.size(); ++i)
{
@@ -1229,7 +1229,7 @@ SwBoxAutoFormat* SwCellStyleTable::GetBoxFormat(const OUString& sName) const
return nullptr;
}
-void SwCellStyleTable::ChangeBoxFormatName(const OUString& sFromName, const OUString& sToName)
+void SwCellStyleTable::ChangeBoxFormatName(std::u16string_view sFromName, const OUString& sToName)
{
if (!GetBoxFormat(sToName))
{
diff --git a/sw/source/core/docnode/ndtbl.cxx b/sw/source/core/docnode/ndtbl.cxx
index acca43916522..5321d026b2ba 100644
--- a/sw/source/core/docnode/ndtbl.cxx
+++ b/sw/source/core/docnode/ndtbl.cxx
@@ -3944,7 +3944,7 @@ OUString SwDoc::GetUniqueTableName() const
return aName + OUString::number( ++nNum );
}
-SwTableFormat* SwDoc::FindTableFormatByName( const OUString& rName, bool bAll ) const
+SwTableFormat* SwDoc::FindTableFormatByName( std::u16string_view rName, bool bAll ) const
{
const SwFormat* pRet = nullptr;
if( bAll )
@@ -4441,7 +4441,7 @@ bool SwDoc::UnProtectTableCells( SwTable& rTable )
return bChgd;
}
-void SwDoc::UnProtectCells( const OUString& rName )
+void SwDoc::UnProtectCells( std::u16string_view rName )
{
SwTableFormat* pFormat = FindTableFormatByName( rName );
if( pFormat )
diff --git a/sw/source/core/edit/edfcol.cxx b/sw/source/core/edit/edfcol.cxx
index 49d7e26e9acc..f6b1291bee99 100644
--- a/sw/source/core/edit/edfcol.cxx
+++ b/sw/source/core/edit/edfcol.cxx
@@ -135,7 +135,7 @@ std::vector<OUString> lcl_getUsedPageStyles(SwViewShell const * pShell)
}
/// Search for a field named rFieldName of type rServiceName in xText and return it.
-uno::Reference<text::XTextField> lcl_findField(const uno::Reference<text::XText>& xText, const OUString& rServiceName, const OUString& rFieldName)
+uno::Reference<text::XTextField> lcl_findField(const uno::Reference<text::XText>& xText, const OUString& rServiceName, std::u16string_view rFieldName)
{
uno::Reference<text::XTextField> xField;
uno::Reference<container::XEnumerationAccess> xParagraphEnumerationAccess(xText, uno::UNO_QUERY);
@@ -172,7 +172,7 @@ uno::Reference<text::XTextField> lcl_findField(const uno::Reference<text::XText>
}
/// Search for a field named rFieldName of type rServiceName in xText and return true iff found.
-bool lcl_hasField(const uno::Reference<text::XText>& xText, const OUString& rServiceName, const OUString& rFieldName)
+bool lcl_hasField(const uno::Reference<text::XText>& xText, const OUString& rServiceName, std::u16string_view rFieldName)
{
return lcl_findField(xText, rServiceName, rFieldName).is();
}
@@ -314,7 +314,7 @@ bool lcl_IsParagraphSignatureField(const uno::Reference<frame::XModel>& xModel,
uno::Reference<text::XTextField> lcl_findFieldByRDF(const uno::Reference<frame::XModel>& xModel,
const uno::Reference<text::XTextContent>& xParagraph,
const OUString& sRDFName,
- const OUString& sRDFValue)
+ std::u16string_view sRDFValue)
{
uno::Reference<container::XEnumerationAccess> xTextPortionEnumerationAccess(xParagraph, uno::UNO_QUERY);
if (!xTextPortionEnumerationAccess.is())
@@ -339,7 +339,7 @@ uno::Reference<text::XTextField> lcl_findFieldByRDF(const uno::Reference<frame::
uno::Reference<text::XTextField> xField(xTextField, uno::UNO_QUERY);
const std::pair<OUString, OUString> pair = lcl_getRDF(xModel, xField, sRDFName);
- if (pair.first == sRDFName && (sRDFValue.isEmpty() || sRDFValue == pair.second))
+ if (pair.first == sRDFName && (sRDFValue.empty() || sRDFValue == pair.second))
return xField;
}
@@ -532,15 +532,15 @@ void lcl_RemoveParagraphMetadataField(const uno::Reference<css::text::XTextField
/// Note: must have associated RDF, since classifications are otherwise just metadata fields.
bool lcl_IsParagraphClassificationField(const uno::Reference<frame::XModel>& xModel,
const uno::Reference<css::text::XTextField>& xField,
- const OUString& sKey)
+ std::u16string_view sKey)
{
const std::pair<OUString, OUString> rdfPair = lcl_getRDF(xModel, xField, ParagraphClassificationNameRDFName);
- return rdfPair.first == ParagraphClassificationNameRDFName && (sKey.isEmpty() || rdfPair.second == sKey);
+ return rdfPair.first == ParagraphClassificationNameRDFName && (sKey.empty() || rdfPair.second == sKey);
}
uno::Reference<text::XTextField> lcl_FindParagraphClassificationField(const uno::Reference<frame::XModel>& xModel,
const uno::Reference<text::XTextContent>& xParagraph,
- const OUString& sKey = OUString())
+ std::u16string_view sKey = u"")
{
uno::Reference<text::XTextField> xTextField;
@@ -1113,7 +1113,7 @@ void SwEditShell::SetClassification(const OUString& rName, SfxClassificationPoli
if (bHeaderIsNeeded)
{
- if (!lcl_hasField(xHeaderText, DocInfoServiceName, SfxClassificationHelper::PROP_PREFIX_INTELLECTUALPROPERTY() + SfxClassificationHelper::PROP_DOCHEADER()))
+ if (!lcl_hasField(xHeaderText, DocInfoServiceName, OUString(SfxClassificationHelper::PROP_PREFIX_INTELLECTUALPROPERTY() + SfxClassificationHelper::PROP_DOCHEADER())))
{
// Append a field to the end of the header text.
uno::Reference<beans::XPropertySet> xField(xMultiServiceFactory->createInstance(DocInfoServiceName), uno::UNO_QUERY);
diff --git a/sw/source/core/edit/edfmt.cxx b/sw/source/core/edit/edfmt.cxx
index ec03360cdc8f..8f450077cde3 100644
--- a/sw/source/core/edit/edfmt.cxx
+++ b/sw/source/core/edit/edfmt.cxx
@@ -146,12 +146,12 @@ const SwFlyFrameFormat* SwEditShell::FindFlyByName( const OUString& rName ) cons
return mxDoc->FindFlyByName(rName);
}
-SwCharFormat* SwEditShell::FindCharFormatByName( const OUString& rName ) const
+SwCharFormat* SwEditShell::FindCharFormatByName( std::u16string_view rName ) const
{
return mxDoc->FindCharFormatByName( rName );
}
-SwTextFormatColl* SwEditShell::FindTextFormatCollByName( const OUString& rName ) const
+SwTextFormatColl* SwEditShell::FindTextFormatCollByName( std::u16string_view rName ) const
{
return mxDoc->FindTextFormatCollByName( rName );
}
diff --git a/sw/source/core/edit/editsh.cxx b/sw/source/core/edit/editsh.cxx
index 85c065d60fed..2a665015cc50 100644
--- a/sw/source/core/edit/editsh.cxx
+++ b/sw/source/core/edit/editsh.cxx
@@ -369,7 +369,7 @@ svt::EmbeddedObjectRef& SwEditShell::GetOLEObject() const
return rOObj.GetObject();
}
-bool SwEditShell::HasOLEObj( const OUString &rName ) const
+bool SwEditShell::HasOLEObj( std::u16string_view rName ) const
{
SwStartNode *pStNd;
SwNodeIndex aIdx( *GetNodes().GetEndOfAutotext().StartOfSectionNode(), 1 );
@@ -394,7 +394,7 @@ void SwEditShell::SetChartName( const OUString &rName )
pONd->SetChartTableName( rName );
}
-void SwEditShell::UpdateCharts( const OUString &rName )
+void SwEditShell::UpdateCharts( std::u16string_view rName )
{
GetDoc()->UpdateCharts( rName );
}
@@ -438,7 +438,7 @@ const SwDocStat& SwEditShell::GetUpdatedDocStat()
}
/// get the reference of a given name in the Doc
-const SwFormatRefMark* SwEditShell::GetRefMark( const OUString& rName ) const
+const SwFormatRefMark* SwEditShell::GetRefMark( std::u16string_view rName ) const
{
return GetDoc()->GetRefMark( rName );
}
diff --git a/sw/source/core/fields/authfld.cxx b/sw/source/core/fields/authfld.cxx
index d922c1269584..d75b079cf639 100644
--- a/sw/source/core/fields/authfld.cxx
+++ b/sw/source/core/fields/authfld.cxx
@@ -133,7 +133,7 @@ void SwAuthorityFieldType::GetAllEntryIdentifiers(
}
SwAuthEntry* SwAuthorityFieldType::GetEntryByIdentifier(
- const OUString& rIdentifier)const
+ std::u16string_view rIdentifier)const
{
for (const auto &rpTemp : m_DataArr)
{
diff --git a/sw/source/core/fields/cellfml.cxx b/sw/source/core/fields/cellfml.cxx
index 752193225283..04321a37a4f8 100644
--- a/sw/source/core/fields/cellfml.cxx
+++ b/sw/source/core/fields/cellfml.cxx
@@ -737,7 +737,7 @@ OUString SwTableFormula::ScanString( FnScanFormula fnFormula, const SwTable& rTa
return aStr.makeStringAndClear();
}
-const SwTable* SwTableFormula::FindTable( SwDoc& rDoc, const OUString& rNm )
+const SwTable* SwTableFormula::FindTable( SwDoc& rDoc, std::u16string_view rNm )
{
const SwFrameFormats& rTableFormats = *rDoc.GetTableFrameFormats();
const SwTable* pTmpTable = nullptr, *pRet = nullptr;
diff --git a/sw/source/core/layout/pagedesc.cxx b/sw/source/core/layout/pagedesc.cxx
index fc8b7b08787e..0deff1919ce3 100644
--- a/sw/source/core/layout/pagedesc.cxx
+++ b/sw/source/core/layout/pagedesc.cxx
@@ -400,7 +400,7 @@ static const char* STR_POOLPAGE[] =
STR_POOLPAGE_LANDSCAPE
};
-SwPageDesc* SwPageDesc::GetByName(SwDoc& rDoc, const OUString& rName)
+SwPageDesc* SwPageDesc::GetByName(SwDoc& rDoc, std::u16string_view rName)
{
const size_t nDCount = rDoc.GetPageDescCnt();
diff --git a/sw/source/core/text/porlay.hxx b/sw/source/core/text/porlay.hxx
index 811f1b19331b..0cc2948231a5 100644
--- a/sw/source/core/text/porlay.hxx
+++ b/sw/source/core/text/porlay.hxx
@@ -293,7 +293,7 @@ public:
TextFrameIndex GetParLen() const;
// For Prepare()
- bool UpdateQuoVadis( const OUString &rQuo );
+ bool UpdateQuoVadis( std::u16string_view rQuo );
// Flags
void SetFly() { m_bFlys = true; }
diff --git a/sw/source/core/text/txtftn.cxx b/sw/source/core/text/txtftn.cxx
index ecab7583e3b0..19880e023d7f 100644
--- a/sw/source/core/text/txtftn.cxx
+++ b/sw/source/core/text/txtftn.cxx
@@ -1529,7 +1529,7 @@ void SwParaPortion::SetErgoSumNum( const OUString& rErgo )
/**
* Is called in SwTextFrame::Prepare()
*/
-bool SwParaPortion::UpdateQuoVadis( const OUString &rQuo )
+bool SwParaPortion::UpdateQuoVadis( std::u16string_view rQuo )
{
SwLineLayout *pLay = this;
while( pLay->GetNext() )
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index e4cd823d74e0..6b00cf30e9cd 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -1756,9 +1756,9 @@ SwTextField* SwTextNode::GetFieldTextAttrAt(
return pTextField;
}
-static SwCharFormat* lcl_FindCharFormat( const SwCharFormats* pCharFormats, const OUString& rName )
+static SwCharFormat* lcl_FindCharFormat( const SwCharFormats* pCharFormats, std::u16string_view rName )
{
- if( !rName.isEmpty() )
+ if( !rName.empty() )
{
const size_t nArrLen = pCharFormats->size();
for( size_t i = 1; i < nArrLen; i++ )
diff --git a/sw/source/core/unocore/unochart.cxx b/sw/source/core/unocore/unochart.cxx
index 8bc55cc0487e..8004c18ee579 100644
--- a/sw/source/core/unocore/unochart.cxx
+++ b/sw/source/core/unocore/unochart.cxx
@@ -318,7 +318,7 @@ static bool GetTableAndCellsFromRangeRep(
return bSuccess;
}
-static void GetTableByName( const SwDoc &rDoc, const OUString &rTableName,
+static void GetTableByName( const SwDoc &rDoc, std::u16string_view rTableName,
SwFrameFormat **ppTableFormat, SwTable **ppTable)
{
SwFrameFormat *pTableFormat = nullptr;
diff --git a/sw/source/core/unocore/unostyle.cxx b/sw/source/core/unocore/unostyle.cxx
index 0049636a85d7..2f1d9d6f7e3d 100644
--- a/sw/source/core/unocore/unostyle.cxx
+++ b/sw/source/core/unocore/unostyle.cxx
@@ -208,7 +208,7 @@ namespace sw
SfxStyleSheetBasePool* m_pBasePool;
SwDocShell* m_pDocShell;
- SwXStyle* FindStyle(const OUString& rStyleName) const;
+ SwXStyle* FindStyle(std::u16string_view rStyleName) const;
sal_Int32 GetCountOrName(OUString* pString, sal_Int32 nIndex = SAL_MAX_INT32)
{ return m_rEntry.m_fGetCountOrName(*m_pDocShell->GetDoc(), pString, nIndex); };
static const StyleFamilyEntry& InitEntry(SfxStyleFamily eFamily)
@@ -1090,7 +1090,7 @@ uno::Any SAL_CALL XStyleFamily::getPropertyValue( const OUString& sPropertyName
}
-SwXStyle* XStyleFamily::FindStyle(const OUString& rStyleName) const
+SwXStyle* XStyleFamily::FindStyle(std::u16string_view rStyleName) const
{
const size_t nLCount = m_pBasePool->GetSizeOfVector();
for(size_t i = 0; i < nLCount; ++i)
@@ -4367,7 +4367,7 @@ SwTableAutoFormat* SwXTextTableStyle::GetTableFormat()
return m_pTableAutoFormat;
}
-SwTableAutoFormat* SwXTextTableStyle::GetTableAutoFormat(SwDocShell* pDocShell, const OUString& sName)
+SwTableAutoFormat* SwXTextTableStyle::GetTableAutoFormat(SwDocShell* pDocShell, std::u16string_view sName)
{
const size_t nStyles = pDocShell->GetDoc()->GetTableStyles().size();
for(size_t i=0; i < nStyles; ++i)
diff --git a/sw/source/filter/basflt/iodetect.cxx b/sw/source/filter/basflt/iodetect.cxx
index 04466aa80648..960497b8d27f 100644
--- a/sw/source/filter/basflt/iodetect.cxx
+++ b/sw/source/filter/basflt/iodetect.cxx
@@ -66,7 +66,7 @@ OUString SwIoSystem::GetSubStorageName( const SfxFilter& rFltr )
return OUString();
}
-std::shared_ptr<const SfxFilter> SwIoSystem::GetFilterOfFormat(const OUString& rFormatNm,
+std::shared_ptr<const SfxFilter> SwIoSystem::GetFilterOfFormat(std::u16string_view rFormatNm,
const SfxFilterContainer* pCnt)
{
SfxFilterContainer aCntSw( sSWRITER );
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx
index ad61fc767b41..c15f17493fad 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -2588,7 +2588,7 @@ const NameToId constNameToIdMapping[] =
{ OUString("styleSet"), FSNS( XML_w14, XML_styleSet ) },
};
-std::optional<sal_Int32> lclGetElementIdForName(const OUString& rName)
+std::optional<sal_Int32> lclGetElementIdForName(std::u16string_view rName)
{
for (auto const & i : constNameToIdMapping)
{
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index b98b8bda7f42..d7925942c954 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -4932,7 +4932,7 @@ void WW8Customizations::Import( SwDocShell* pShell )
}
}
-void SwWW8ImplReader::ReadGlobalTemplateSettings( const OUString& sCreatedFrom, const uno::Reference< container::XNameContainer >& xPrjNameCache )
+void SwWW8ImplReader::ReadGlobalTemplateSettings( std::u16string_view sCreatedFrom, const uno::Reference< container::XNameContainer >& xPrjNameCache )
{
if (utl::ConfigManager::IsFuzzing())
return;
@@ -4957,7 +4957,7 @@ void SwWW8ImplReader::ReadGlobalTemplateSettings( const OUString& sCreatedFrom,
aURL = rGlobalTemplate;
else
osl::FileBase::getFileURLFromSystemPath( rGlobalTemplate, aURL );
- if ( !aURL.endsWithIgnoreAsciiCase( ".dot" ) || ( !sCreatedFrom.isEmpty() && sCreatedFrom == aURL ) )
+ if ( !aURL.endsWithIgnoreAsciiCase( ".dot" ) || ( !sCreatedFrom.empty() && sCreatedFrom == aURL ) )
continue; // don't try and read the same document as ourselves
tools::SvRef<SotStorage> rRoot = new SotStorage( aURL, StreamMode::STD_READWRITE );
diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx
index 07beb3592bff..7629d2e5a63d 100644
--- a/sw/source/filter/ww8/ww8par.hxx
+++ b/sw/source/filter/ww8/ww8par.hxx
@@ -1695,7 +1695,7 @@ private:
// #i84783#
// determine object attribute "Layout in Table Cell"
bool IsObjectLayoutInTableCell( const sal_uInt32 nLayoutInTableCell ) const;
- void ReadGlobalTemplateSettings( const OUString& sCreatedFrom, const css::uno::Reference< css::container::XNameContainer >& xPrjNameMap );
+ void ReadGlobalTemplateSettings( std::u16string_view sCreatedFrom, const css::uno::Reference< css::container::XNameContainer >& xPrjNameMap );
SwWW8ImplReader(const SwWW8ImplReader &) = delete;
SwWW8ImplReader& operator=(const SwWW8ImplReader&) = delete;
public: // really private, but can only be done public
@@ -1896,7 +1896,7 @@ public: // really private, but can only be done public
void SetNCurrentColl( sal_uInt16 nColl ) { m_nCurrentColl = nColl; }
std::unique_ptr<SfxItemSet> SetCurrentItemSet(std::unique_ptr<SfxItemSet> pItemSet);
sal_uInt16 StyleUsingLFO( sal_uInt16 nLFOIndex ) const ;
- const SwFormat* GetStyleWithOrgWWName( OUString const & rName ) const ;
+ const SwFormat* GetStyleWithOrgWWName( std::u16string_view rName ) const ;
static bool GetPictGrafFromStream(Graphic& rGraphic, SvStream& rSrc);
static void PicRead( SvStream *pDataStream, WW8_PIC *pPic, bool bVer67);
diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx
index bf5a27528b6e..6bc5b6866f21 100644
--- a/sw/source/filter/ww8/ww8par2.cxx
+++ b/sw/source/filter/ww8/ww8par2.cxx
@@ -3566,7 +3566,7 @@ sal_uInt16 SwWW8ImplReader::StyleUsingLFO( sal_uInt16 nLFOIndex ) const
return nRes;
}
-const SwFormat* SwWW8ImplReader::GetStyleWithOrgWWName( OUString const & rName ) const
+const SwFormat* SwWW8ImplReader::GetStyleWithOrgWWName( std::u16string_view rName ) const
{
SwFormat* pRet = nullptr;
if( !m_vColl.empty() )
diff --git a/sw/source/filter/xml/XMLRedlineImportHelper.cxx b/sw/source/filter/xml/XMLRedlineImportHelper.cxx
index 99ff2933ad97..91aa7e048637 100644
--- a/sw/source/filter/xml/XMLRedlineImportHelper.cxx
+++ b/sw/source/filter/xml/XMLRedlineImportHelper.cxx
@@ -374,7 +374,7 @@ XMLRedlineImportHelper::~XMLRedlineImportHelper()
}
void XMLRedlineImportHelper::Add(
- const OUString& rType,
+ std::u16string_view rType,
const OUString& rId,
const OUString& rAuthor,
const OUString& rComment,
diff --git a/sw/source/filter/xml/XMLRedlineImportHelper.hxx b/sw/source/filter/xml/XMLRedlineImportHelper.hxx
index 4a479a9cc38e..38eff4dc56e6 100644
--- a/sw/source/filter/xml/XMLRedlineImportHelper.hxx
+++ b/sw/source/filter/xml/XMLRedlineImportHelper.hxx
@@ -75,7 +75,7 @@ public:
// (The redline will be inserted into the document after both start
// and end cursor has been set.)
void Add(
- const OUString& rType, // redline type (insert, del,... )
+ std::u16string_view rType, // redline type (insert, del,... )
const OUString& rId, // use to identify this redline
const OUString& rAuthor, // name of the author
const OUString& rComment, // redline comment
diff --git a/sw/source/ui/dbui/selectdbtabledialog.cxx b/sw/source/ui/dbui/selectdbtabledialog.cxx
index 19db636a54bb..e49624e48273 100644
--- a/sw/source/ui/dbui/selectdbtabledialog.cxx
+++ b/sw/source/ui/dbui/selectdbtabledialog.cxx
@@ -132,7 +132,7 @@ OUString SwSelectDBTableDialog::GetSelectedTable(bool& bIsTable)
return OUString();
}
-void SwSelectDBTableDialog::SetSelectedTable(const OUString& rTable, bool bIsTable)
+void SwSelectDBTableDialog::SetSelectedTable(std::u16string_view rTable, bool bIsTable)
{
for (int i = 0, nCount = m_xTable->n_children(); i < nCount; ++i)
{
diff --git a/sw/source/ui/dbui/selectdbtabledialog.hxx b/sw/source/ui/dbui/selectdbtabledialog.hxx
index 852a7570d285..01c1edcc49fe 100644
--- a/sw/source/ui/dbui/selectdbtabledialog.hxx
+++ b/sw/source/ui/dbui/selectdbtabledialog.hxx
@@ -37,7 +37,7 @@ public:
virtual ~SwSelectDBTableDialog() override;
OUString GetSelectedTable(bool& bIsTable);
- void SetSelectedTable(const OUString& rTable, bool bIsTable);
+ void SetSelectedTable(std::u16string_view rTable, bool bIsTable);
};
#endif
diff --git a/sw/source/ui/dialog/uiregionsw.cxx b/sw/source/ui/dialog/uiregionsw.cxx
index 843083c99eb4..14215accd178 100644
--- a/sw/source/ui/dialog/uiregionsw.cxx
+++ b/sw/source/ui/dialog/uiregionsw.cxx
@@ -535,7 +535,7 @@ SwEditRegionDlg::~SwEditRegionDlg( )
}
}
-void SwEditRegionDlg::SelectSection(const OUString& rSectionName)
+void SwEditRegionDlg::SelectSection(std::u16string_view rSectionName)
{
std::unique_ptr<weld::TreeIter> xIter(m_xTree->make_iterator());
if (!m_xTree->get_iter_first(*xIter))
diff --git a/sw/source/ui/envelp/label1.cxx b/sw/source/ui/envelp/label1.cxx
index 8aa1d8de9fc9..6dd5c5b1d4b7 100644
--- a/sw/source/ui/envelp/label1.cxx
+++ b/sw/source/ui/envelp/label1.cxx
@@ -184,7 +184,7 @@ void SwLabDlg::GetLabItem(SwLabItem &rItem)
}
}
-SwLabRec* SwLabDlg::GetRecord(const OUString &rRecName, bool bCont)
+SwLabRec* SwLabDlg::GetRecord(std::u16string_view rRecName, bool bCont)
{
SwLabRec* pRec = nullptr;
bool bFound = false;
diff --git a/sw/source/ui/fldui/changedb.cxx b/sw/source/ui/fldui/changedb.cxx
index e4e44316f9ab..6871bd4b6d26 100644
--- a/sw/source/ui/fldui/changedb.cxx
+++ b/sw/source/ui/fldui/changedb.cxx
@@ -80,7 +80,7 @@ void SwChangeDBDlg::FillDBPopup()
Reference< XComponentContext > xContext( ::comphelper::getProcessComponentContext() );
Reference<XDatabaseContext> xDBContext = DatabaseContext::create(xContext);
const SwDBData& rDBData = pSh->GetDBData();
- m_xAvailDBTLB->Select(rDBData.sDataSource, rDBData.sCommand, OUString());
+ m_xAvailDBTLB->Select(rDBData.sDataSource, rDBData.sCommand, u"");
TreeSelect();
Sequence< OUString > aDBNames = xDBContext->getElementNames();
diff --git a/sw/source/ui/fldui/flddb.cxx b/sw/source/ui/fldui/flddb.cxx
index 99a7d5f05b3b..267d318d8559 100644
--- a/sw/source/ui/fldui/flddb.cxx
+++ b/sw/source/ui/fldui/flddb.cxx
@@ -138,7 +138,7 @@ void SwFieldDBPage::Reset(const SfxItemSet*)
if(pSh)
{
SwDBData aTmp(pSh->GetDBData());
- m_xDatabaseTLB->Select(aTmp.sDataSource, aTmp.sCommand, OUString());
+ m_xDatabaseTLB->Select(aTmp.sDataSource, aTmp.sCommand, u"");
}
}
}
@@ -506,7 +506,7 @@ void SwFieldDBPage::ActivateMailMergeAddress()
m_xTypeLB->select_id(OUString::number(static_cast<sal_uInt16>(SwFieldTypesEnum::Database)));
TypeListBoxHdl(*m_xTypeLB);
const SwDBData& rData = SW_MOD()->GetDBConfig()->GetAddressSource();
- m_xDatabaseTLB->Select(rData.sDataSource, rData.sCommand, OUString());
+ m_xDatabaseTLB->Select(rData.sDataSource, rData.sCommand, u"");
}
void SwFieldDBPage::SetWrtShell(SwWrtShell& rSh)
diff --git a/sw/source/ui/index/swuiidxmrk.cxx b/sw/source/ui/index/swuiidxmrk.cxx
index 3ea8bb755bbc..cb3339e3c55f 100644
--- a/sw/source/ui/index/swuiidxmrk.cxx
+++ b/sw/source/ui/index/swuiidxmrk.cxx
@@ -1081,7 +1081,7 @@ const TextInfo aTextInfoArr[] =
{AUTH_FIELD_CUSTOM5, HID_AUTH_FIELD_CUSTOM5 }
};
-static OUString lcl_FindColumnEntry(const uno::Sequence<beans::PropertyValue>& rFields, const OUString& rColumnTitle)
+static OUString lcl_FindColumnEntry(const uno::Sequence<beans::PropertyValue>& rFields, std::u16string_view rColumnTitle)
{
for(const auto& rField : rFields)
{
diff --git a/sw/source/ui/misc/glossary.cxx b/sw/source/ui/misc/glossary.cxx
index 21e131891386..7b173f63e449 100644
--- a/sw/source/ui/misc/glossary.cxx
+++ b/sw/source/ui/misc/glossary.cxx
@@ -339,8 +339,8 @@ void SwGlossaryDlg::EnableShortName(bool bOn)
}
// does the title exist in the selected group?
-std::unique_ptr<weld::TreeIter> SwGlossaryDlg::DoesBlockExist(const OUString& rBlock,
- const OUString& rShort)
+std::unique_ptr<weld::TreeIter> SwGlossaryDlg::DoesBlockExist(std::u16string_view rBlock,
+ std::u16string_view rShort)
{
// look for possible entry in TreeListBox
std::unique_ptr<weld::TreeIter> xEntry = m_xCategoryBox->make_iterator();
@@ -353,7 +353,7 @@ std::unique_ptr<weld::TreeIter> SwGlossaryDlg::DoesBlockExist(const OUString& rB
do
{
if (rBlock == m_xCategoryBox->get_text(*xEntry) &&
- (rShort.isEmpty() ||
+ (rShort.empty() ||
rShort == m_xCategoryBox->get_id(*xEntry))
)
{
diff --git a/sw/source/ui/misc/outline.cxx b/sw/source/ui/misc/outline.cxx
index bef52a28777c..bdaa59f9015f 100644
--- a/sw/source/ui/misc/outline.cxx
+++ b/sw/source/ui/misc/outline.cxx
@@ -291,7 +291,7 @@ IMPL_LINK(SwOutlineTabDialog, MenuSelectHdl, const OString&, rIdent, void)
pPage->Reset(GetOutputItemSet());
}
-sal_uInt16 SwOutlineTabDialog::GetLevel(const OUString &rFormatName) const
+sal_uInt16 SwOutlineTabDialog::GetLevel(std::u16string_view rFormatName) const
{
for(sal_uInt16 i = 0; i < MAXLEVEL; ++i)
{
diff --git a/sw/source/ui/vba/vbadocument.cxx b/sw/source/ui/vba/vbadocument.cxx
index c7cfe8446cb0..4e305cc100e5 100644
--- a/sw/source/ui/vba/vbadocument.cxx
+++ b/sw/source/ui/vba/vbadocument.cxx
@@ -542,7 +542,7 @@ SwVbaDocument::SavePreviewPngAs( const uno::Any& FileName )
}
uno::Any
-SwVbaDocument::getControlShape( const OUString& sName )
+SwVbaDocument::getControlShape( std::u16string_view sName )
{
uno::Reference< drawing::XDrawPageSupplier > xDrawPageSupplier( mxTextDocument, uno::UNO_QUERY_THROW );
uno::Reference< container::XIndexAccess > xIndexAccess( xDrawPageSupplier->getDrawPage(), uno::UNO_QUERY_THROW );
diff --git a/sw/source/ui/vba/vbadocument.hxx b/sw/source/ui/vba/vbadocument.hxx
index a5e4dabf8452..0d213690a982 100644
--- a/sw/source/ui/vba/vbadocument.hxx
+++ b/sw/source/ui/vba/vbadocument.hxx
@@ -38,7 +38,7 @@ private:
std::vector<css::uno::Reference< ooo::vba::XSink >> mvSinks;
void Initialize();
- css::uno::Any getControlShape( const OUString& sName );
+ css::uno::Any getControlShape( std::u16string_view sName );
css::uno::Reference< css::container::XNameAccess > getFormControls() const;
public:
diff --git a/sw/source/uibase/app/docsh2.cxx b/sw/source/uibase/app/docsh2.cxx
index a2342c9f3d0e..bb135b823c92 100644
--- a/sw/source/uibase/app/docsh2.cxx
+++ b/sw/source/uibase/app/docsh2.cxx
@@ -648,7 +648,7 @@ void SwDocShell::Execute(SfxRequest& rReq)
// 3 - file saved in non-HTML -> QueryBox to save as HTML
std::shared_ptr<const SfxFilter> pHtmlFlt =
SwIoSystem::GetFilterOfFormat(
- "HTML",
+ u"HTML",
SwWebDocShell::Factory().GetFilterContainer() );
bool bLocalHasName = HasName();
if(bLocalHasName)
@@ -976,7 +976,7 @@ void SwDocShell::Execute(SfxRequest& rReq)
{
// for HTML there is only one filter!!
pFlt = SwIoSystem::GetFilterOfFormat(
- "HTML",
+ u"HTML",
SwWebDocShell::Factory().GetFilterContainer() );
pStrId = STR_LOAD_HTML_DOC;
}
diff --git a/sw/source/uibase/app/docstyle.cxx b/sw/source/uibase/app/docstyle.cxx
index a15f9000883b..c720c3775c8c 100644
--- a/sw/source/uibase/app/docstyle.cxx
+++ b/sw/source/uibase/app/docstyle.cxx
@@ -330,7 +330,7 @@ static SwTableAutoFormat* lcl_FindTableStyle(SwDoc& rDoc, const OUString& rName,
return pFormat;
}
-static const SwBoxAutoFormat* lcl_FindCellStyle(SwDoc& rDoc, const OUString& rName, SwDocStyleSheet *pStyle)
+static const SwBoxAutoFormat* lcl_FindCellStyle(SwDoc& rDoc, std::u16string_view rName, SwDocStyleSheet *pStyle)
{
const SwBoxAutoFormat* pFormat = rDoc.GetCellStyles().GetBoxFormat(rName);
diff --git a/sw/source/uibase/dbui/dbtree.cxx b/sw/source/uibase/dbui/dbtree.cxx
index 4dee21a4ed0c..e47c7dc92c9c 100644
--- a/sw/source/uibase/dbui/dbtree.cxx
+++ b/sw/source/uibase/dbui/dbtree.cxx
@@ -164,7 +164,7 @@ void SwDBTreeList::InitTreeList()
m_xTreeView->set_image(*m_xScratchIter, aImg);
}
}
- Select(OUString(), OUString(), OUString());
+ Select(u"", u"", u"");
bInitialized = true;
}
@@ -320,7 +320,7 @@ OUString SwDBTreeList::GetDBName(OUString& rTableName, OUString& rColumnName, sa
}
// Format: database.table
-void SwDBTreeList::Select(const OUString& rDBName, const OUString& rTableName, const OUString& rColumnName)
+void SwDBTreeList::Select(std::u16string_view rDBName, std::u16string_view rTableName, std::u16string_view rColumnName)
{
std::unique_ptr<weld::TreeIter> xParent(m_xTreeView->make_iterator());
if (!m_xTreeView->get_iter_first(*xParent))
@@ -345,7 +345,7 @@ void SwDBTreeList::Select(const OUString& rDBName, const OUString& rTableName, c
m_xTreeView->copy_iterator(*xChild, *xParent);
bool bNoChild = false;
- if (bShowColumns && !rColumnName.isEmpty())
+ if (bShowColumns && !rColumnName.empty())
{
if (!m_xTreeView->iter_has_child(*xParent))
{
diff --git a/sw/source/uibase/docvw/PostItMgr.cxx b/sw/source/uibase/docvw/PostItMgr.cxx
index d5153892a0dc..84144c447bbb 100644
--- a/sw/source/uibase/docvw/PostItMgr.cxx
+++ b/sw/source/uibase/docvw/PostItMgr.cxx
@@ -1726,7 +1726,7 @@ void SwPostItMgr::FormatAll(const SfxItemSet &rNewAttr)
LayoutPostIts();
}
-void SwPostItMgr::Hide( const OUString& rAuthor )
+void SwPostItMgr::Hide( std::u16string_view rAuthor )
{
for (auto const& postItField : mvPostItFields)
{
diff --git a/sw/source/uibase/fldui/fldmgr.cxx b/sw/source/uibase/fldui/fldmgr.cxx
index 42ac135fedcd..dcf02a29de31 100644
--- a/sw/source/uibase/fldui/fldmgr.cxx
+++ b/sw/source/uibase/fldui/fldmgr.cxx
@@ -373,7 +373,7 @@ SwFieldMgr::~SwFieldMgr()
}
// organise RefMark by names
-bool SwFieldMgr::CanInsertRefMark( const OUString& rStr )
+bool SwFieldMgr::CanInsertRefMark( std::u16string_view rStr )
{
bool bRet = false;
SwWrtShell *pSh = m_pWrtShell ? m_pWrtShell : lcl_GetShell();
diff --git a/sw/source/uibase/inc/dbtree.hxx b/sw/source/uibase/inc/dbtree.hxx
index 863ac1a40083..651654bb9843 100644
--- a/sw/source/uibase/inc/dbtree.hxx
+++ b/sw/source/uibase/inc/dbtree.hxx
@@ -45,8 +45,8 @@ public:
OUString GetDBName(OUString& rTableName, OUString& rColumnName, sal_Bool* pbIsTable = nullptr);
- void Select( const OUString& rDBName, const OUString& rTableName,
- const OUString& rColumnName );
+ void Select( std::u16string_view rDBName, std::u16string_view rTableName,
+ std::u16string_view rColumnName );
void ShowColumns(bool bShowCol);
diff --git a/sw/source/uibase/inc/fldmgr.hxx b/sw/source/uibase/inc/fldmgr.hxx
index 9a701e2a4280..ebc5c4966c09 100644
--- a/sw/source/uibase/inc/fldmgr.hxx
+++ b/sw/source/uibase/inc/fldmgr.hxx
@@ -154,7 +154,7 @@ public:
bool bIsTable, const OUString& rFieldName);
// organise RefMark with names
- bool CanInsertRefMark( const OUString& rStr );
+ bool CanInsertRefMark( std::u16string_view rStr );
// access to field types via ResId
size_t GetFieldTypeCount() const;
diff --git a/sw/source/uibase/inc/gloslst.hxx b/sw/source/uibase/inc/gloslst.hxx
index 3da5d88617a5..11192ecd6234 100644
--- a/sw/source/uibase/inc/gloslst.hxx
+++ b/sw/source/uibase/inc/gloslst.hxx
@@ -50,7 +50,7 @@ class SwGlossaryList : public AutoTimer
OUString sPath;
bool bFilled;
- AutoTextGroup* FindGroup(const OUString& rGroupName);
+ AutoTextGroup* FindGroup(std::u16string_view rGroupName);
static void FillGroup(AutoTextGroup* pGroup, SwGlossaries* pGloss);
public:
@@ -59,7 +59,7 @@ public:
void HasLongName(const std::vector<OUString>& rBeginCandidates,
std::vector<std::pair<OUString, sal_uInt16>>& rLongNames);
- bool GetShortName(const OUString& rLongName,
+ bool GetShortName(std::u16string_view rLongName,
OUString& rShortName, OUString& rGroupName );
size_t GetGroupCount();
diff --git a/sw/source/uibase/inc/glossary.hxx b/sw/source/uibase/inc/glossary.hxx
index 7f0dab68901f..4ac5b6c8e4ec 100644
--- a/sw/source/uibase/inc/glossary.hxx
+++ b/sw/source/uibase/inc/glossary.hxx
@@ -95,7 +95,7 @@ class SwGlossaryDlg : public SfxDialogController
void Apply();
void Init();
- std::unique_ptr<weld::TreeIter> DoesBlockExist(const OUString& sBlock, const OUString& rShort);
+ std::unique_ptr<weld::TreeIter> DoesBlockExist(std::u16string_view sBlock, std::u16string_view rShort);
void ShowAutoText(const OUString& rGroup, const OUString& rShortName);
void ResumeShowAutoText();
diff --git a/sw/source/uibase/inc/label.hxx b/sw/source/uibase/inc/label.hxx
index 86d08a2573a1..a7a1c66412c6 100644
--- a/sw/source/uibase/inc/label.hxx
+++ b/sw/source/uibase/inc/label.hxx
@@ -51,7 +51,7 @@ public:
SwDBManager* pDBManager, bool bLabel);
virtual ~SwLabDlg() override;
- SwLabRec* GetRecord(const OUString &rRecName, bool bCont);
+ SwLabRec* GetRecord(std::u16string_view rRecName, bool bCont);
void GetLabItem(SwLabItem &rItem);
SwLabRecs &Recs() { return *m_pRecs; }
diff --git a/sw/source/uibase/inc/langhelper.hxx b/sw/source/uibase/inc/langhelper.hxx
index 8c93d29d3c36..8efc5931e574 100644
--- a/sw/source/uibase/inc/langhelper.hxx
+++ b/sw/source/uibase/inc/langhelper.hxx
@@ -38,8 +38,8 @@ namespace SwLangHelper
extern void GetLanguageStatus( OutlinerView* pOLV, SfxItemSet& rSet );
extern bool SetLanguageStatus( OutlinerView* pOLV, SfxRequest &rReq, SwView const &rView, SwWrtShell &rSh );
- extern void SetLanguage( SwWrtShell &rWrtSh, const OUString &rLangText, bool bIsForSelection, SfxItemSet &rCoreSet );
- extern void SetLanguage( SwWrtShell &rWrtSh, OutlinerView const * pOLV, const ESelection& rSelection, const OUString &rLangText, bool bIsForSelection, SfxItemSet &rCoreSet );
+ extern void SetLanguage( SwWrtShell &rWrtSh, std::u16string_view rLangText, bool bIsForSelection, SfxItemSet &rCoreSet );
+ extern void SetLanguage( SwWrtShell &rWrtSh, OutlinerView const * pOLV, const ESelection& rSelection, std::u16string_view rLangText, bool bIsForSelection, SfxItemSet &rCoreSet );
extern void SetLanguage_None( SwWrtShell &rWrtSh, bool bIsForSelection, SfxItemSet &rCoreSet );
extern void SetLanguage_None( SwWrtShell &rWrtSh, OutlinerView const * pOLV, const ESelection& rSelection, bool bIsForSelection, SfxItemSet &rCoreSet );
extern void ResetLanguages( SwWrtShell &rWrtSh, OutlinerView const * pOLV = nullptr );
diff --git a/sw/source/uibase/inc/outline.hxx b/sw/source/uibase/inc/outline.hxx
index f9c3c1f15dde..f7702359c3ee 100644
--- a/sw/source/uibase/inc/outline.hxx
+++ b/sw/source/uibase/inc/outline.hxx
@@ -56,7 +56,7 @@ public:
virtual ~SwOutlineTabDialog() override;
SwNumRule* GetNumRule() { return xNumRule.get(); }
- sal_uInt16 GetLevel(const OUString &rFormatName) const;
+ sal_uInt16 GetLevel(std::u16string_view rFormatName) const;
OUString* GetCollNames() {return aCollNames;}
static sal_uInt16 GetActNumLevel() {return nNumLevel;}
diff --git a/sw/source/uibase/inc/regionsw.hxx b/sw/source/uibase/inc/regionsw.hxx
index adb2681efef2..a16fc1b93f5e 100644
--- a/sw/source/uibase/inc/regionsw.hxx
+++ b/sw/source/uibase/inc/regionsw.hxx
@@ -110,7 +110,7 @@ public:
SwEditRegionDlg(weld::Window* pParent, SwWrtShell& rWrtSh);
virtual ~SwEditRegionDlg() override;
- void SelectSection(const OUString& rSectionName);
+ void SelectSection(std::u16string_view rSectionName);
};
diff --git a/sw/source/uibase/inc/wrtsh.hxx b/sw/source/uibase/inc/wrtsh.hxx
index a8cc9a49d6cb..4499c0c15763 100644
--- a/sw/source/uibase/inc/wrtsh.hxx
+++ b/sw/source/uibase/inc/wrtsh.hxx
@@ -358,7 +358,7 @@ typedef bool (SwWrtShell::*FNSimpleMove)();
GetStyle eCreate = GETSTYLE_NOCREATE);
SwCharFormat* GetCharStyle(const OUString &rFormatName,
GetStyle eCreate = GETSTYLE_NOCREATE);
- SwFrameFormat* GetTableStyle(const OUString &rFormatName);
+ SwFrameFormat* GetTableStyle(std::u16string_view rFormatName);
void SetPageStyle(const OUString &rCollName);
@@ -475,7 +475,7 @@ typedef bool (SwWrtShell::*FNSimpleMove)();
bool GotoINetAttr( const SwTextINetFormat& rAttr );
void GotoOutline( SwOutlineNodes::size_type nIdx );
bool GotoOutline( const OUString& rName );
- bool GotoRegion( const OUString& rName );
+ bool GotoRegion( std::u16string_view rName );
bool GotoRefMark( const OUString& rRefMark, sal_uInt16 nSubType = 0,
sal_uInt16 nSeqNo = 0 );
bool GotoNextTOXBase( const OUString* pName = nullptr);
@@ -483,7 +483,7 @@ typedef bool (SwWrtShell::*FNSimpleMove)();
void GotoFormatField( const SwFormatField& rField );
const SwRangeRedline* GotoRedline( SwRedlineTable::size_type nArrPos, bool bSelect);
- void ChangeHeaderOrFooter(const OUString& rStyleName, bool bHeader, bool bOn, bool bShowWarning);
+ void ChangeHeaderOrFooter(std::u16string_view rStyleName, bool bHeader, bool bOn, bool bShowWarning);
virtual void SetShowHeaderFooterSeparator( FrameControlType eControl, bool bShow ) override;
/// Inserts a new annotation/comment at the current cursor position / selection.
diff --git a/sw/source/uibase/shells/frmsh.cxx b/sw/source/uibase/shells/frmsh.cxx
index c203ace11024..e6a758b37e5c 100644
--- a/sw/source/uibase/shells/frmsh.cxx
+++ b/sw/source/uibase/shells/frmsh.cxx
@@ -80,7 +80,7 @@ using namespace ::com::sun::star::uno;
// Prototypes
static void lcl_FrameGetMaxLineWidth(const SvxBorderLine* pBorderLine, SvxBorderLine& rBorderLine);
-static const SwFrameFormat* lcl_GetFrameFormatByName(SwWrtShell const & rSh, const OUString& rName)
+static const SwFrameFormat* lcl_GetFrameFormatByName(SwWrtShell const & rSh, std::u16string_view rName)
{
const size_t nCount = rSh.GetFlyCount(FLYCNTTYPE_FRM);
for( size_t i = 0; i < nCount; ++i )
diff --git a/sw/source/uibase/shells/langhelper.cxx b/sw/source/uibase/shells/langhelper.cxx
index 53e039f057e1..1be26660c34c 100644
--- a/sw/source/uibase/shells/langhelper.cxx
+++ b/sw/source/uibase/shells/langhelper.cxx
@@ -217,12 +217,12 @@ namespace SwLangHelper
return bRestoreSelection;
}
- void SetLanguage( SwWrtShell &rWrtSh, const OUString &rLangText, bool bIsForSelection, SfxItemSet &rCoreSet )
+ void SetLanguage( SwWrtShell &rWrtSh, std::u16string_view rLangText, bool bIsForSelection, SfxItemSet &rCoreSet )
{
SetLanguage( rWrtSh, nullptr , ESelection(), rLangText, bIsForSelection, rCoreSet );
}
- void SetLanguage( SwWrtShell &rWrtSh, OutlinerView const * pOLV, const ESelection& rSelection, const OUString &rLangText, bool bIsForSelection, SfxItemSet &rCoreSet )
+ void SetLanguage( SwWrtShell &rWrtSh, OutlinerView const * pOLV, const ESelection& rSelection, std::u16string_view rLangText, bool bIsForSelection, SfxItemSet &rCoreSet )
{
const LanguageType nLang = SvtLanguageTable::GetLanguageType( rLangText );
if (nLang == LANGUAGE_DONTKNOW)
diff --git a/sw/source/uibase/sidebar/StylePresetsPanel.cxx b/sw/source/uibase/sidebar/StylePresetsPanel.cxx
index f24bf135c706..ecb2e61bd3f6 100644
--- a/sw/source/uibase/sidebar/StylePresetsPanel.cxx
+++ b/sw/source/uibase/sidebar/StylePresetsPanel.cxx
@@ -33,7 +33,7 @@ namespace sw::sidebar {
namespace {
void renderPreview(sfx2::StyleManager* pStyleManager, OutputDevice& aOutputDevice,
- OUString const & sName, sal_Int32 nHeight, tools::Rectangle const & aRect)
+ std::u16string_view sName, sal_Int32 nHeight, tools::Rectangle const & aRect)
{
SfxStyleSheetBase* pStyleSheet = pStyleManager->Search(sName, SfxStyleFamily::Para);
@@ -98,18 +98,18 @@ BitmapEx GenerateStylePreview(SfxObjectShell& rSource, OUString const & aName)
{
tools::Rectangle aRenderRect(Point(nMargin, y), aSize);
- renderPreview(pStyleManager, *pVirtualDev, "Title", nTitleHeight, aRenderRect);
+ renderPreview(pStyleManager, *pVirtualDev, u"Title", nTitleHeight, aRenderRect);
y += nTitleHeight;
}
{
tools::Rectangle aRenderRect(Point(nMargin, y), aSize);
- renderPreview(pStyleManager, *pVirtualDev, "Heading 1", nHeadingHeight, aRenderRect);
+ renderPreview(pStyleManager, *pVirtualDev, u"Heading 1", nHeadingHeight, aRenderRect);
y += nHeadingHeight;
}
{
tools::Rectangle aRenderRect(Point(nMargin, y), aSize);
- renderPreview(pStyleManager, *pVirtualDev, "Text Body", nTextBodyHeight, aRenderRect);
+ renderPreview(pStyleManager, *pVirtualDev, u"Text Body", nTextBodyHeight, aRenderRect);
}
return pVirtualDev->GetBitmapEx(Point(), aSize);
diff --git a/sw/source/uibase/sidebar/ThemePanel.cxx b/sw/source/uibase/sidebar/ThemePanel.cxx
index f4c4951f6546..2ba276cf212e 100644
--- a/sw/source/uibase/sidebar/ThemePanel.cxx
+++ b/sw/source/uibase/sidebar/ThemePanel.cxx
@@ -104,7 +104,7 @@ public:
maStyles.push_back(aRedefinition);
}
- StyleRedefinition* get(const OUString& aString)
+ StyleRedefinition* get(std::u16string_view aString)
{
for (StyleRedefinition & rStyle : maStyles)
{
@@ -315,7 +315,7 @@ std::vector<FontSet> initFontSets()
return aFontSets;
}
-FontSet getFontSet(const OUString& rFontVariant, std::vector<FontSet>& aFontSets)
+FontSet getFontSet(std::u16string_view rFontVariant, std::vector<FontSet>& aFontSets)
{
for (const FontSet & rFontSet : aFontSets)
{
@@ -325,7 +325,7 @@ FontSet getFontSet(const OUString& rFontVariant, std::vector<FontSet>& aFontSets
return aFontSets[0];
}
-void applyTheme(SfxStyleSheetBasePool* pPool, const OUString& sFontSetName, const OUString& sColorSetName,
+void applyTheme(SfxStyleSheetBasePool* pPool, std::u16string_view sFontSetName, std::u16string_view sColorSetName,
StyleSet& rStyleSet, svx::ColorSets& rColorSets)
{
SwDocStyleSheet* pStyle;
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index 4b83a3d00e95..bf6804075822 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -1178,7 +1178,7 @@ void SwView::Execute(SfxRequest &rReq)
GetViewFrame()->ShowChildWindow(SID_SIDEBAR);
::sfx2::sidebar::Sidebar::ShowPanel(
- "GalleryPanel",
+ u"GalleryPanel",
GetViewFrame()->GetFrame().GetFrameInterface());
break;
case SID_AVMEDIA_PLAYER :
diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx
index 2ac47cd7efb7..dfaa0b123096 100644
--- a/sw/source/uibase/utlui/content.cxx
+++ b/sw/source/uibase/utlui/content.cxx
@@ -3092,9 +3092,9 @@ void SwContentTree::HideTree()
}
static void lcl_SelectByContentTypeAndName(SwContentTree* pThis, weld::TreeView& rContentTree,
- const OUString& rContentTypeName, const OUString& rName)
+ std::u16string_view rContentTypeName, std::u16string_view rName)
{
- if (!rName.isEmpty())
+ if (!rName.empty())
{
// find content type entry
std::unique_ptr<weld::TreeIter> xIter(rContentTree.make_iterator());
diff --git a/sw/source/uibase/utlui/gloslst.cxx b/sw/source/uibase/utlui/gloslst.cxx
index b58335850ad9..8d2dcc2af2d3 100644
--- a/sw/source/uibase/utlui/gloslst.cxx
+++ b/sw/source/uibase/utlui/gloslst.cxx
@@ -100,7 +100,7 @@ SwGlossaryList::~SwGlossaryList()
// will be filled. Otherwise also rGroupName will be set and
// on demand asked for the right group.
-bool SwGlossaryList::GetShortName(const OUString& rLongName,
+bool SwGlossaryList::GetShortName(std::u16string_view rLongName,
OUString& rShortName, OUString& rGroupName )
{
if(!bFilled)
@@ -336,7 +336,7 @@ void SwGlossaryList::Invoke()
Update();
}
-AutoTextGroup* SwGlossaryList::FindGroup(const OUString& rGroupName)
+AutoTextGroup* SwGlossaryList::FindGroup(std::u16string_view rGroupName)
{
for(const auto & pRet : aGroupArr)
{
diff --git a/sw/source/uibase/wrtsh/move.cxx b/sw/source/uibase/wrtsh/move.cxx
index 491a2fcbdb2a..bd076831167d 100644
--- a/sw/source/uibase/wrtsh/move.cxx
+++ b/sw/source/uibase/wrtsh/move.cxx
@@ -624,7 +624,7 @@ bool SwWrtShell::GotoOutline( const OUString& rName )
return bRet;
}
-bool SwWrtShell::GotoRegion( const OUString& rName )
+bool SwWrtShell::GotoRegion( std::u16string_view rName )
{
SwPosition aPos = *GetCursor()->GetPoint();
bool bRet = SwCursorShell::GotoRegion (rName);
diff --git a/sw/source/uibase/wrtsh/wrtsh1.cxx b/sw/source/uibase/wrtsh/wrtsh1.cxx
index 8251a9978142..3fb11b740ca4 100644
--- a/sw/source/uibase/wrtsh/wrtsh1.cxx
+++ b/sw/source/uibase/wrtsh/wrtsh1.cxx
@@ -1526,7 +1526,7 @@ SwCharFormat *SwWrtShell::GetCharStyle(const OUString &rFormatName, GetStyle eCr
// frame format with this name exists or
// this is a default format or the format is automatic.
-SwFrameFormat *SwWrtShell::GetTableStyle(const OUString &rFormatName)
+SwFrameFormat *SwWrtShell::GetTableStyle(std::u16string_view rFormatName)
{
for( size_t i = GetTableFrameFormatCount(); i; )
{
@@ -1804,7 +1804,7 @@ void SwWrtShell::SetReadonlyOption(bool bSet)
// given all styles are changed
void SwWrtShell::ChangeHeaderOrFooter(
- const OUString& rStyleName, bool bHeader, bool bOn, bool bShowWarning)
+ std::u16string_view rStyleName, bool bHeader, bool bOn, bool bShowWarning)
{
SdrView *const pSdrView = GetDrawView();
if (pSdrView && pSdrView->IsTextEdit())
@@ -1821,7 +1821,7 @@ void SwWrtShell::ChangeHeaderOrFooter(
{
SwPageDesc aDesc( GetPageDesc( nFrom ));
OUString sTmp(aDesc.GetName());
- if( rStyleName.isEmpty() || rStyleName == sTmp )
+ if( rStyleName.empty() || rStyleName == sTmp )
{
bool bChgd = false;
@@ -1872,7 +1872,7 @@ void SwWrtShell::ChangeHeaderOrFooter(
if ( !IsHeaderFooterEdit() )
ToggleHeaderFooterEdit();
bCursorSet = SetCursorInHdFt(
- rStyleName.isEmpty() ? SIZE_MAX : nFrom,
+ rStyleName.empty() ? SIZE_MAX : nFrom,
bHeader );
}
}
diff --git a/test/source/text/textsettings.cxx b/test/source/text/textsettings.cxx
index 880206e0963d..5b8cef60cdd0 100644
--- a/test/source/text/textsettings.cxx
+++ b/test/source/text/textsettings.cxx
@@ -27,7 +27,7 @@ bool extstsProperty(css::uno::Reference<css::beans::XPropertySet> const& rxPrope
}
bool isPropertyReadOnly(css::uno::Reference<css::beans::XPropertySet> const& rxPropertySet,
- OUString const& rPropertyName)
+ std::u16string_view rPropertyName)
{
css::uno::Reference<css::beans::XPropertySetInfo> xPropertySetInfo(
rxPropertySet->getPropertySetInfo());
diff --git a/test/source/xmltesttools.cxx b/test/source/xmltesttools.cxx
index 27833af1e90d..c1d03cd41fe7 100644
--- a/test/source/xmltesttools.cxx
+++ b/test/source/xmltesttools.cxx
@@ -195,7 +195,7 @@ void XmlTestTools::assertXPathContent(const xmlDocUniquePtr& pXmlDoc, const OStr
}
void XmlTestTools::assertXPathNSDef(const xmlDocUniquePtr& pXmlDoc, const OString& rXPath,
- const OUString& rNSPrefix, const OUString& rNSHref)
+ std::u16string_view rNSPrefix, std::u16string_view rNSHref)
{
xmlXPathObjectPtr pXmlObj = getXPathNode(pXmlDoc, rXPath);
xmlNodeSetPtr pXmlNodes = pXmlObj->nodesetval;
diff --git a/toolkit/inc/controls/controlmodelcontainerbase.hxx b/toolkit/inc/controls/controlmodelcontainerbase.hxx
index c2d715dc3b61..a08806ddd450 100644
--- a/toolkit/inc/controls/controlmodelcontainerbase.hxx
+++ b/toolkit/inc/controls/controlmodelcontainerbase.hxx
@@ -92,7 +92,7 @@ protected:
css::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const override;
::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() override;
- UnoControlModelHolderVector::iterator ImplFindElement( const OUString& rName );
+ UnoControlModelHolderVector::iterator ImplFindElement( std::u16string_view rName );
/// @throws css::lang::IllegalArgumentException
/// @throws css::container::ElementExistException
diff --git a/toolkit/source/controls/controlmodelcontainerbase.cxx b/toolkit/source/controls/controlmodelcontainerbase.cxx
index 880b25c53a82..6c5aedde4776 100644
--- a/toolkit/source/controls/controlmodelcontainerbase.cxx
+++ b/toolkit/source/controls/controlmodelcontainerbase.cxx
@@ -271,7 +271,7 @@ rtl::Reference<UnoControlModel> ControlModelContainerBase::Clone() const
return pClone;
}
-ControlModelContainerBase::UnoControlModelHolderVector::iterator ControlModelContainerBase::ImplFindElement( const OUString& rName )
+ControlModelContainerBase::UnoControlModelHolderVector::iterator ControlModelContainerBase::ImplFindElement( std::u16string_view rName )
{
return ::std::find_if( maModels.begin(), maModels.end(), [&](const UnoControlModelHolder& elem) { return elem.second == rName; });
}
diff --git a/tools/qa/cppunit/test_color.cxx b/tools/qa/cppunit/test_color.cxx
index 0a71c38191da..8ba4ea5839ed 100644
--- a/tools/qa/cppunit/test_color.cxx
+++ b/tools/qa/cppunit/test_color.cxx
@@ -103,7 +103,7 @@ void Test::test_asRGBColor()
CPPUNIT_ASSERT_EQUAL(OUString("ffffff"), aColor.AsRGBHexString());
}
-OUString createTintShade(sal_uInt8 nR, sal_uInt8 nG, sal_uInt8 nB, OUString const & sReference, sal_Int16 nTintShade)
+OUString createTintShade(sal_uInt8 nR, sal_uInt8 nG, sal_uInt8 nB, std::u16string_view sReference, sal_Int16 nTintShade)
{
Color aColor(nR, nG, nB);
if (sReference != aColor.AsRGBHexString())
@@ -117,48 +117,48 @@ void Test::test_ApplyTintOrShade()
// BLACK reference
// 5% tint
- CPPUNIT_ASSERT_EQUAL(OUString("0d0d0d"), createTintShade(0x00, 0x00, 0x00, "000000", 500));
+ CPPUNIT_ASSERT_EQUAL(OUString("0d0d0d"), createTintShade(0x00, 0x00, 0x00, u"000000", 500));
// 15% tint
- CPPUNIT_ASSERT_EQUAL(OUString("262626"), createTintShade(0x00, 0x00, 0x00, "000000", 1500));
+ CPPUNIT_ASSERT_EQUAL(OUString("262626"), createTintShade(0x00, 0x00, 0x00, u"000000", 1500));
// 25% tint
- CPPUNIT_ASSERT_EQUAL(OUString("404040"), createTintShade(0x00, 0x00, 0x00, "000000", 2500));
+ CPPUNIT_ASSERT_EQUAL(OUString("404040"), createTintShade(0x00, 0x00, 0x00, u"000000", 2500));
// 50% tint
- CPPUNIT_ASSERT_EQUAL(OUString("808080"), createTintShade(0x00, 0x00, 0x00, "000000", 5000));
+ CPPUNIT_ASSERT_EQUAL(OUString("808080"), createTintShade(0x00, 0x00, 0x00, u"000000", 5000));
// 100% tint
- CPPUNIT_ASSERT_EQUAL(OUString("ffffff"), createTintShade(0x00, 0x00, 0x00, "000000", 10000));
+ CPPUNIT_ASSERT_EQUAL(OUString("ffffff"), createTintShade(0x00, 0x00, 0x00, u"000000", 10000));
// WHITE reference
// 5% shade
- CPPUNIT_ASSERT_EQUAL(OUString("f2f2f2"), createTintShade(0xff, 0xff, 0xff, "ffffff", -500));
+ CPPUNIT_ASSERT_EQUAL(OUString("f2f2f2"), createTintShade(0xff, 0xff, 0xff, u"ffffff", -500));
// 15% shade
- CPPUNIT_ASSERT_EQUAL(OUString("d9d9d9"), createTintShade(0xff, 0xff, 0xff, "ffffff", -1500));
+ CPPUNIT_ASSERT_EQUAL(OUString("d9d9d9"), createTintShade(0xff, 0xff, 0xff, u"ffffff", -1500));
// 25% shade
- CPPUNIT_ASSERT_EQUAL(OUString("bfbfbf"), createTintShade(0xff, 0xff, 0xff, "ffffff", -2500));
+ CPPUNIT_ASSERT_EQUAL(OUString("bfbfbf"), createTintShade(0xff, 0xff, 0xff, u"ffffff", -2500));
// 50% shade
- CPPUNIT_ASSERT_EQUAL(OUString("808080"), createTintShade(0xff, 0xff, 0xff, "ffffff", -5000));
+ CPPUNIT_ASSERT_EQUAL(OUString("808080"), createTintShade(0xff, 0xff, 0xff, u"ffffff", -5000));
// 100% shade
- CPPUNIT_ASSERT_EQUAL(OUString("000000"), createTintShade(0xff, 0xff, 0xff, "ffffff", -10000));
+ CPPUNIT_ASSERT_EQUAL(OUString("000000"), createTintShade(0xff, 0xff, 0xff, u"ffffff", -10000));
// GREY reference
// 0% - no change
- CPPUNIT_ASSERT_EQUAL(OUString("808080"), createTintShade(0x80, 0x80, 0x80, "808080", 0));
+ CPPUNIT_ASSERT_EQUAL(OUString("808080"), createTintShade(0x80, 0x80, 0x80, u"808080", 0));
// 25% tint
- CPPUNIT_ASSERT_EQUAL(OUString("a0a0a0"), createTintShade(0x80, 0x80, 0x80, "808080", 2500));
+ CPPUNIT_ASSERT_EQUAL(OUString("a0a0a0"), createTintShade(0x80, 0x80, 0x80, u"808080", 2500));
// 50% tint
//CPPUNIT_ASSERT_EQUAL(OUString("c0c0c0"), createTintShade(0x80, 0x80, 0x80, "808080", 5000));
// disable for now - a rounding error happens on come platforms...
// 100% tint
- CPPUNIT_ASSERT_EQUAL(OUString("ffffff"), createTintShade(0x80, 0x80, 0x80, "808080", 10000));
+ CPPUNIT_ASSERT_EQUAL(OUString("ffffff"), createTintShade(0x80, 0x80, 0x80, u"808080", 10000));
// 25% shade
- CPPUNIT_ASSERT_EQUAL(OUString("606060"), createTintShade(0x80, 0x80, 0x80, "808080", -2500));
+ CPPUNIT_ASSERT_EQUAL(OUString("606060"), createTintShade(0x80, 0x80, 0x80, u"808080", -2500));
// 50% shade
- CPPUNIT_ASSERT_EQUAL(OUString("404040"), createTintShade(0x80, 0x80, 0x80, "808080", -5000));
+ CPPUNIT_ASSERT_EQUAL(OUString("404040"), createTintShade(0x80, 0x80, 0x80, u"808080", -5000));
// 100% shade
- CPPUNIT_ASSERT_EQUAL(OUString("000000"), createTintShade(0x80, 0x80, 0x80, "808080", -10000));
+ CPPUNIT_ASSERT_EQUAL(OUString("000000"), createTintShade(0x80, 0x80, 0x80, u"808080", -10000));
}
void Test::testGetColorError()
diff --git a/ucb/source/cacher/cachedcontentresultset.cxx b/ucb/source/cacher/cachedcontentresultset.cxx
index 483b7e3fcb74..9e713839e082 100644
--- a/ucb/source/cacher/cachedcontentresultset.cxx
+++ b/ucb/source/cacher/cachedcontentresultset.cxx
@@ -374,10 +374,10 @@ private:
bool
impl_queryProperty(
- const OUString& rName
+ std::u16string_view rName
, css::beans::Property& rProp ) const;
sal_Int32
- impl_getPos( const OUString& rName ) const;
+ impl_getPos( std::u16string_view rName ) const;
static bool
impl_isMyPropertyName( const OUString& rName );
@@ -411,8 +411,8 @@ public:
//some helping variables ( names for my special properties )
const char g_sPropertyNameForCount[] = "RowCount";
const char g_sPropertyNameForFinalCount[] = "IsRowCountFinal";
-const char g_sPropertyNameForFetchSize[] = "FetchSize";
-const char g_sPropertyNameForFetchDirection[] = "FetchDirection";
+constexpr OUStringLiteral g_sPropertyNameForFetchSize(u"FetchSize");
+constexpr OUStringLiteral g_sPropertyNameForFetchDirection(u"FetchDirection");
CCRS_PropertySetInfo::CCRS_PropertySetInfo(
Reference< XPropertySetInfo > const & xInfo )
@@ -543,7 +543,7 @@ sal_Bool SAL_CALL CCRS_PropertySetInfo
sal_Int32 CCRS_PropertySetInfo
- ::impl_getPos( const OUString& rName ) const
+ ::impl_getPos( std::u16string_view rName ) const
{
for( sal_Int32 nN = m_pProperties->getLength(); nN--; )
{
@@ -555,7 +555,7 @@ sal_Int32 CCRS_PropertySetInfo
}
bool CCRS_PropertySetInfo
- ::impl_queryProperty( const OUString& rName, Property& rProp ) const
+ ::impl_queryProperty( std::u16string_view rName, Property& rProp ) const
{
for( const Property& rMyProp : std::as_const(*m_pProperties) )
{
diff --git a/ucb/source/ucp/ftp/ftpcontentprovider.cxx b/ucb/source/ucp/ftp/ftpcontentprovider.cxx
index 72e427e22934..3f10357c395f 100644
--- a/ucb/source/ucp/ftp/ftpcontentprovider.cxx
+++ b/ucb/source/ucp/ftp/ftpcontentprovider.cxx
@@ -186,9 +186,9 @@ CURL* FTPContentProvider::handle()
}
-void FTPContentProvider::forHost( const OUString& host,
- const OUString& port,
- const OUString& username,
+void FTPContentProvider::forHost( std::u16string_view host,
+ std::u16string_view port,
+ std::u16string_view username,
OUString& password,
OUString& account)
{
diff --git a/ucb/source/ucp/ftp/ftpcontentprovider.hxx b/ucb/source/ucp/ftp/ftpcontentprovider.hxx
index 093ddf6e9f64..00a4fa1acc89 100644
--- a/ucb/source/ucp/ftp/ftpcontentprovider.hxx
+++ b/ucb/source/ucp/ftp/ftpcontentprovider.hxx
@@ -74,9 +74,9 @@ namespace ftp
/** host is in the form host:port.
*/
- void forHost(const OUString& host,
- const OUString& port,
- const OUString& username,
+ void forHost(std::u16string_view host,
+ std::u16string_view port,
+ std::u16string_view username,
OUString& password,
OUString& account);
diff --git a/ucbhelper/source/client/proxydecider.cxx b/ucbhelper/source/client/proxydecider.cxx
index 34ea7385139e..3052cd34003e 100644
--- a/ucbhelper/source/client/proxydecider.cxx
+++ b/ucbhelper/source/client/proxydecider.cxx
@@ -92,7 +92,7 @@ class HostnameCache
std::deque< HostListEntry > m_aHostList;
public:
- bool get( const OUString & rKey, OUString & rValue ) const
+ bool get( std::u16string_view rKey, OUString & rValue ) const
{
for (auto const& host : m_aHostList)
{
diff --git a/ucbhelper/source/provider/contentinfo.cxx b/ucbhelper/source/provider/contentinfo.cxx
index 85b3b6c741e3..820fb021d9b2 100644
--- a/ucbhelper/source/provider/contentinfo.cxx
+++ b/ucbhelper/source/provider/contentinfo.cxx
@@ -151,7 +151,7 @@ void PropertySetInfo::reset()
bool PropertySetInfo::queryProperty(
- const OUString& rName, beans::Property& rProp )
+ std::u16string_view rName, beans::Property& rProp )
{
osl::MutexGuard aGuard( m_aMutex );
@@ -280,7 +280,7 @@ void CommandProcessorInfo::reset()
bool CommandProcessorInfo::queryCommand(
- const OUString& rName,
+ std::u16string_view rName,
css::ucb::CommandInfo& rCommand )
{
osl::MutexGuard aGuard( m_aMutex );
diff --git a/ucbhelper/source/provider/contentinfo.hxx b/ucbhelper/source/provider/contentinfo.hxx
index 01d10e07545f..22591c8bc360 100644
--- a/ucbhelper/source/provider/contentinfo.hxx
+++ b/ucbhelper/source/provider/contentinfo.hxx
@@ -54,7 +54,7 @@ class PropertySetInfo :
ContentImplHelper* m_pContent;
private:
- bool queryProperty( const OUString& rName,
+ bool queryProperty( std::u16string_view rName,
css::beans::Property& rProp );
public:
@@ -94,7 +94,7 @@ class CommandProcessorInfo :
ContentImplHelper* m_pContent;
private:
- bool queryCommand( const OUString& rName,
+ bool queryCommand( std::u16string_view rName,
css::ucb::CommandInfo& rCommand );
bool queryCommand( sal_Int32 nHandle,
css::ucb::CommandInfo& rCommand );
diff --git a/ucbhelper/source/provider/resultset.cxx b/ucbhelper/source/provider/resultset.cxx
index 6d6fd5ee09b3..f954ad8e99e8 100644
--- a/ucbhelper/source/provider/resultset.cxx
+++ b/ucbhelper/source/provider/resultset.cxx
@@ -94,7 +94,7 @@ class PropertySetInfo :
private:
bool queryProperty(
- const OUString& aName, beans::Property& rProp ) const;
+ std::u16string_view aName, beans::Property& rProp ) const;
public:
PropertySetInfo(
@@ -1488,7 +1488,7 @@ sal_Bool SAL_CALL PropertySetInfo::hasPropertyByName(
bool PropertySetInfo::queryProperty(
- const OUString& aName, beans::Property& rProp ) const
+ std::u16string_view aName, beans::Property& rProp ) const
{
sal_Int32 nCount = m_pProps->getLength();
const beans::Property* pProps = m_pProps->getConstArray();
diff --git a/unoidl/source/sourceprovider-parser.y b/unoidl/source/sourceprovider-parser.y
index 569f9022b953..565ac9d8dec9 100644
--- a/unoidl/source/sourceprovider-parser.y
+++ b/unoidl/source/sourceprovider-parser.y
@@ -4086,7 +4086,7 @@ bool SourceProviderInterfaceTypeEntityPad::addDirectMember(
OUString const & name)
{
assert(data != nullptr);
- if (!checkMemberClashes(location, yyscanner, data, "", name, true)) {
+ if (!checkMemberClashes(location, yyscanner, data, u"", name, true)) {
return false;
}
allMembers.emplace(name, Member(data->currentName));
@@ -4228,7 +4228,7 @@ bool SourceProviderInterfaceTypeEntityPad::checkBaseClashes(
bool SourceProviderInterfaceTypeEntityPad::checkMemberClashes(
YYLTYPE location, yyscan_t yyscanner, SourceProviderScannerData * data,
- OUString const & interfaceName, OUString const & memberName,
+ std::u16string_view interfaceName, OUString const & memberName,
bool checkOptional) const
{
std::map<OUString, Member>::const_iterator i(allMembers.find(memberName));
diff --git a/unoidl/source/sourceprovider-scanner.hxx b/unoidl/source/sourceprovider-scanner.hxx
index 282c0a18430c..afd8b2e79b12 100644
--- a/unoidl/source/sourceprovider-scanner.hxx
+++ b/unoidl/source/sourceprovider-scanner.hxx
@@ -163,7 +163,7 @@ private:
bool checkMemberClashes(
YYLTYPE location, yyscan_t yyscanner, SourceProviderScannerData * data,
- OUString const & interfaceName, OUString const & memberName,
+ std::u16string_view interfaceName, OUString const & memberName,
bool checkOptional) const;
bool addBase(
diff --git a/unotools/source/config/lingucfg.cxx b/unotools/source/config/lingucfg.cxx
index 94da331f88ba..be0e52e769e0 100644
--- a/unotools/source/config/lingucfg.cxx
+++ b/unotools/source/config/lingucfg.cxx
@@ -1013,10 +1013,10 @@ uno::Sequence< OUString > SvtLinguConfig::GetDisabledDictionaries() const
}
std::vector< SvtLinguConfigDictionaryEntry > SvtLinguConfig::GetActiveDictionariesByFormat(
- const OUString &rFormatName ) const
+ std::u16string_view rFormatName ) const
{
std::vector< SvtLinguConfigDictionaryEntry > aRes;
- if (rFormatName.isEmpty())
+ if (rFormatName.empty())
return aRes;
try
diff --git a/unotools/source/misc/fontdefs.cxx b/unotools/source/misc/fontdefs.cxx
index 9effac2e839a..59830cb1e1b0 100644
--- a/unotools/source/misc/fontdefs.cxx
+++ b/unotools/source/misc/fontdefs.cxx
@@ -474,7 +474,7 @@ OUString GetNextFontToken( const OUString& rTokenStr, sal_Int32& rIndex )
return rTokenStr.copy( nTokenStart, nTokenLen );
}
-static bool ImplIsFontToken( const OUString& rName, const OUString& rToken )
+static bool ImplIsFontToken( const OUString& rName, std::u16string_view rToken )
{
OUString aTempName;
sal_Int32 nIndex = 0;
diff --git a/uui/source/iahndl-ioexceptions.cxx b/uui/source/iahndl-ioexceptions.cxx
index 6da1ea3a6fab..e15c9e457746 100644
--- a/uui/source/iahndl-ioexceptions.cxx
+++ b/uui/source/iahndl-ioexceptions.cxx
@@ -33,7 +33,7 @@ namespace {
template<class T>
bool
getRequestArgument(uno::Sequence< uno::Any > const & rArguments,
- OUString const & rKey,
+ std::u16string_view rKey,
T * pValue)
{
for (const auto& rArgument : rArguments)
@@ -57,11 +57,11 @@ bool
getResourceNameRequestArgument(uno::Sequence< uno::Any > const & rArguments,
OUString * pValue)
{
- if (!getRequestArgument(rArguments, "Uri", pValue))
+ if (!getRequestArgument(rArguments, u"Uri", pValue))
return false;
// Use the resource name only for file URLs, to avoid confusion:
if (pValue && comphelper::isFileUrl(*pValue))
- getRequestArgument(rArguments, "ResourceName", pValue);
+ getRequestArgument(rArguments, u"ResourceName", pValue);
return true;
}
@@ -162,7 +162,7 @@ UUIInteractionHelper::handleInteractiveIOException(
case ucb::IOErrorCode_CANT_CREATE:
{
OUString aArgFolder;
- if (getRequestArgument(aRequestArguments, "Folder", &aArgFolder))
+ if (getRequestArgument(aRequestArguments, u"Folder", &aArgFolder))
{
OUString aArgUri;
if (getResourceNameRequestArgument(aRequestArguments,
@@ -191,9 +191,9 @@ UUIInteractionHelper::handleInteractiveIOException(
&aArgUri))
{
OUString aResourceType;
- getRequestArgument(aRequestArguments, "ResourceType", &aResourceType);
+ getRequestArgument(aRequestArguments, u"ResourceType", &aResourceType);
bool bRemovable = false;
- getRequestArgument(aRequestArguments, "Removable", &bRemovable);
+ getRequestArgument(aRequestArguments, u"Removable", &bRemovable);
nErrorCode = aResourceType == "volume"
? (bRemovable
? ERRCODE_UUI_IO_NOTREADY_VOLUME_REMOVABLE
@@ -212,8 +212,8 @@ UUIInteractionHelper::handleInteractiveIOException(
{
OUString aArgVolume;
OUString aArgOtherVolume;
- if (getRequestArgument(aRequestArguments, "Volume", &aArgVolume)
- && getRequestArgument(aRequestArguments, "OtherVolume",
+ if (getRequestArgument(aRequestArguments, u"Volume", &aArgVolume)
+ && getRequestArgument(aRequestArguments, u"OtherVolume",
&aArgOtherVolume))
{
nErrorCode = aErrorCode[static_cast<sal_Int32>(aIoException.Code)][1];
@@ -233,7 +233,7 @@ UUIInteractionHelper::handleInteractiveIOException(
&aArgUri))
{
OUString aResourceType;
- getRequestArgument(aRequestArguments, "ResourceType",
+ getRequestArgument(aRequestArguments, u"ResourceType",
&aResourceType);
nErrorCode = aResourceType == "volume"
? ERRCODE_UUI_IO_NOTEXISTS_VOLUME
diff --git a/vcl/inc/fontinstance.hxx b/vcl/inc/fontinstance.hxx
index 7dc78ac05533..4918d612c5cf 100644
--- a/vcl/inc/fontinstance.hxx
+++ b/vcl/inc/fontinstance.hxx
@@ -63,7 +63,7 @@ public: // TODO: make data members private
void AddFallbackForUnicode( sal_UCS4, FontWeight eWeight, const OUString& rFontName );
bool GetFallbackForUnicode( sal_UCS4, FontWeight eWeight, OUString* pFontName ) const;
- void IgnoreFallbackForUnicode( sal_UCS4, FontWeight eWeight, const OUString& rFontName );
+ void IgnoreFallbackForUnicode( sal_UCS4, FontWeight eWeight, std::u16string_view rFontName );
inline hb_font_t* GetHbFont();
bool IsGraphiteFont();
diff --git a/vcl/inc/listbox.hxx b/vcl/inc/listbox.hxx
index f18233574e7f..816e7ff50c56 100644
--- a/vcl/inc/listbox.hxx
+++ b/vcl/inc/listbox.hxx
@@ -115,7 +115,7 @@ public:
void Clear();
sal_Int32 FindMatchingEntry( const OUString& rStr, sal_Int32 nStart, bool bLazy ) const;
- sal_Int32 FindEntry( const OUString& rStr, bool bSearchMRUArea = false ) const;
+ sal_Int32 FindEntry( std::u16string_view rStr, bool bSearchMRUArea = false ) const;
/// helper: add up heights up to index nEndIndex.
/// GetAddedHeight( 0 ) @return 0
diff --git a/vcl/inc/outdev.h b/vcl/inc/outdev.h
index 27f8dc5481db..df4c2f205182 100644
--- a/vcl/inc/outdev.h
+++ b/vcl/inc/outdev.h
@@ -100,7 +100,7 @@ public:
void AddFontSubstitute( const OUString& rFontName, const OUString& rSubstName, AddFontSubstituteFlags nFlags );
void RemoveFontsSubstitute();
- bool FindFontSubstitute( OUString& rSubstName, const OUString& rFontName ) const;
+ bool FindFontSubstitute( OUString& rSubstName, std::u16string_view rFontName ) const;
};
// PreMatchFontSubstitution
diff --git a/vcl/inc/ppdparser.hxx b/vcl/inc/ppdparser.hxx
index b5bf309ed917..fdcc0a68c186 100644
--- a/vcl/inc/ppdparser.hxx
+++ b/vcl/inc/ppdparser.hxx
@@ -193,7 +193,7 @@ public:
OUString getDefaultPaperDimension() const;
void getDefaultPaperDimension( int& rWidth, int& rHeight ) const
{ getPaperDimension( getDefaultPaperDimension(), rWidth, rHeight ); }
- bool getPaperDimension( const OUString& rPaperName,
+ bool getPaperDimension( std::u16string_view rPaperName,
int& rWidth, int& rHeight ) const;
// width and height in pt
// returns false if paper not found
@@ -201,7 +201,7 @@ public:
// match the best paper for width and height
OUString matchPaper( int nWidth, int nHeight ) const;
- bool getMargins( const OUString& rPaperName,
+ bool getMargins( std::u16string_view rPaperName,
int &rLeft, int& rRight,
int &rUpper, int& rLower ) const;
// values in pt
diff --git a/vcl/source/control/combobox.cxx b/vcl/source/control/combobox.cxx
index 188df87a4d9c..666feb9e3216 100644
--- a/vcl/source/control/combobox.cxx
+++ b/vcl/source/control/combobox.cxx
@@ -941,7 +941,7 @@ Image ComboBox::GetEntryImage( sal_Int32 nPos ) const
return Image();
}
-sal_Int32 ComboBox::GetEntryPos( const OUString& rStr ) const
+sal_Int32 ComboBox::GetEntryPos( std::u16string_view rStr ) const
{
sal_Int32 nPos = m_pImpl->m_pImplLB->GetEntryList()->FindEntry( rStr );
if ( nPos != LISTBOX_ENTRY_NOTFOUND )
diff --git a/vcl/source/control/imp_listbox.cxx b/vcl/source/control/imp_listbox.cxx
index 2125e0780afa..ddff67bae584 100644
--- a/vcl/source/control/imp_listbox.cxx
+++ b/vcl/source/control/imp_listbox.cxx
@@ -234,7 +234,7 @@ void ImplEntryList::RemoveEntry( sal_Int32 nPos )
}
}
-sal_Int32 ImplEntryList::FindEntry( const OUString& rString, bool bSearchMRUArea ) const
+sal_Int32 ImplEntryList::FindEntry( std::u16string_view rString, bool bSearchMRUArea ) const
{
const sal_Int32 nEntries = static_cast<sal_Int32>(maEntries.size());
for ( sal_Int32 n = bSearchMRUArea ? 0 : GetMRUCount(); n < nEntries; n++ )
diff --git a/vcl/source/control/listbox.cxx b/vcl/source/control/listbox.cxx
index bf4b71412514..4782807892fc 100644
--- a/vcl/source/control/listbox.cxx
+++ b/vcl/source/control/listbox.cxx
@@ -963,7 +963,7 @@ Image ListBox::GetEntryImage( sal_Int32 nPos ) const
return Image();
}
-sal_Int32 ListBox::GetEntryPos( const OUString& rStr ) const
+sal_Int32 ListBox::GetEntryPos( std::u16string_view rStr ) const
{
if (!mpImplLB)
return LISTBOX_ENTRY_NOTFOUND;
@@ -1019,7 +1019,7 @@ bool ListBox::IsEntryPosSelected( sal_Int32 nPos ) const
return mpImplLB->GetEntryList()->IsEntryPosSelected( nPos + mpImplLB->GetEntryList()->GetMRUCount() );
}
-void ListBox::SelectEntry( const OUString& rStr, bool bSelect )
+void ListBox::SelectEntry( std::u16string_view rStr, bool bSelect )
{
SelectEntryPos( GetEntryPos( rStr ), bSelect );
}
diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx
index 6d983008544f..ad3dabd4494e 100644
--- a/vcl/source/filter/graphicfilter.cxx
+++ b/vcl/source/filter/graphicfilter.cxx
@@ -613,7 +613,7 @@ struct ImpFilterLibCacheEntry
PFilterCall mpfnImport;
ImpFilterLibCacheEntry(const OUString& rPathname, const OUString& rFiltername, const OUString& rFormatName);
- bool operator==( const OUString& rFiltername ) const { return maFiltername == rFiltername; }
+ bool operator==( std::u16string_view rFiltername ) const { return maFiltername == rFiltername; }
PFilterCall GetImportFunction();
};
diff --git a/vcl/source/font/fontinstance.cxx b/vcl/source/font/fontinstance.cxx
index 40e334bd6d5c..f56333f6cf8a 100644
--- a/vcl/source/font/fontinstance.cxx
+++ b/vcl/source/font/fontinstance.cxx
@@ -136,7 +136,7 @@ bool LogicalFontInstance::GetFallbackForUnicode( sal_UCS4 cChar, FontWeight eWei
return true;
}
-void LogicalFontInstance::IgnoreFallbackForUnicode( sal_UCS4 cChar, FontWeight eWeight, const OUString& rFontName )
+void LogicalFontInstance::IgnoreFallbackForUnicode( sal_UCS4 cChar, FontWeight eWeight, std::u16string_view rFontName )
{
UnicodeFallbackList::iterator it = mpUnicodeFallbackList->find( std::pair< sal_UCS4,FontWeight >(cChar,eWeight) );
if( it == mpUnicodeFallbackList->end() )
diff --git a/vcl/source/outdev/font.cxx b/vcl/source/outdev/font.cxx
index 71dc5e861fcf..6963fd77c3e1 100644
--- a/vcl/source/outdev/font.cxx
+++ b/vcl/source/outdev/font.cxx
@@ -628,7 +628,7 @@ void ImplDirectFontSubstitution::RemoveFontsSubstitute()
}
bool ImplDirectFontSubstitution::FindFontSubstitute( OUString& rSubstName,
- const OUString& rSearchName ) const
+ std::u16string_view rSearchName ) const
{
// TODO: get rid of O(N) searches
std::vector<ImplFontSubstEntry>::const_iterator it = std::find_if (
diff --git a/vcl/unx/generic/printer/ppdparser.cxx b/vcl/unx/generic/printer/ppdparser.cxx
index 06ed7fecdb9e..2dbd268ae57e 100644
--- a/vcl/unx/generic/printer/ppdparser.cxx
+++ b/vcl/unx/generic/printer/ppdparser.cxx
@@ -1403,7 +1403,7 @@ OUString PPDParser::getDefaultPaperDimension() const
}
bool PPDParser::getMargins(
- const OUString& rPaperName,
+ std::u16string_view rPaperName,
int& rLeft, int& rRight,
int& rUpper, int& rLower ) const
{
@@ -1439,7 +1439,7 @@ bool PPDParser::getMargins(
}
bool PPDParser::getPaperDimension(
- const OUString& rPaperName,
+ std::u16string_view rPaperName,
int& rWidth, int& rHeight ) const
{
if( ! m_pPaperDimensions )
diff --git a/vcl/workben/vcldemo.cxx b/vcl/workben/vcldemo.cxx
index 09b1f47608e0..68a04d1384a9 100644
--- a/vcl/workben/vcldemo.cxx
+++ b/vcl/workben/vcldemo.cxx
@@ -167,7 +167,7 @@ public:
OUString getRendererList();
double getAndResetBenchmark(RenderStyle style);
- void selectRenderer(const OUString &rName);
+ void selectRenderer(std::u16string_view rName);
int selectNextRenderer();
void setIterCount(sal_Int32 iterCount);
sal_Int32 getIterCount() const;
@@ -1691,7 +1691,7 @@ void DemoRenderer::addTime(int i, double t)
maRenderers[i]->countTime++;
}
-void DemoRenderer::selectRenderer(const OUString &rName )
+void DemoRenderer::selectRenderer(std::u16string_view rName )
{
for (size_t i = 0; i < maRenderers.size(); i++)
{
diff --git a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
index 42024b048c45..654f2648ac78 100644
--- a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
+++ b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
@@ -1170,7 +1170,7 @@ void DomainMapperTableHandler::ApplyParagraphPropertiesFromTableStyle(TableParag
// The wording is confusing here. Normally, the paragraph style DOES override the table-style.
// But for these two special situations, do not override the table-style. So the default is false.
// If false, then "CompatOverride" the normal behaviour, and apply the table-style's value.
- bCompatOverride &= !m_rDMapper_Impl.GetSettingsTable()->GetCompatSettingValue("overrideTableStyleFontSizeAndJustification");
+ bCompatOverride &= !m_rDMapper_Impl.GetSettingsTable()->GetCompatSettingValue(u"overrideTableStyleFontSizeAndJustification");
}
// use table style when no paragraph style setting or a docDefault value is applied instead of it
diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
index 9ec336f263eb..556e5abc495d 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
@@ -255,7 +255,7 @@ static bool IsFieldNestingAllowed(const FieldContextPtr& pOuter, const FieldCont
return true;
}
-uno::Any FloatingTableInfo::getPropertyValue(const OUString &propertyName)
+uno::Any FloatingTableInfo::getPropertyValue(std::u16string_view propertyName)
{
for( beans::PropertyValue const & propVal : std::as_const(m_aFrameProperties) )
if( propVal.Name == propertyName )
diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.hxx b/writerfilter/source/dmapper/DomainMapper_Impl.hxx
index e3501da2d342..4b08d13e9649 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.hxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.hxx
@@ -396,7 +396,7 @@ struct FloatingTableInfo
m_nTableWidthType(nTableWidthType)
{
}
- css::uno::Any getPropertyValue(const OUString &propertyName);
+ css::uno::Any getPropertyValue(std::u16string_view propertyName);
};
/// Stores original/in-file-format info about a single anchored object.
diff --git a/writerfilter/source/dmapper/NumberingManager.cxx b/writerfilter/source/dmapper/NumberingManager.cxx
index a0ff5002e1ee..f6e8e454a6a6 100644
--- a/writerfilter/source/dmapper/NumberingManager.cxx
+++ b/writerfilter/source/dmapper/NumberingManager.cxx
@@ -56,7 +56,7 @@ static beans::PropertyValue lcl_makePropVal(PropertyIds nNameID, T const & aValu
return {getPropertyName(nNameID), 0, uno::makeAny(aValue), beans::PropertyState_DIRECT_VALUE};
}
-static sal_Int32 lcl_findProperty( const uno::Sequence< beans::PropertyValue >& aProps, const OUString& sName )
+static sal_Int32 lcl_findProperty( const uno::Sequence< beans::PropertyValue >& aProps, std::u16string_view sName )
{
sal_Int32 i = 0;
sal_Int32 nLen = aProps.getLength( );
diff --git a/writerfilter/source/dmapper/PropertyMap.cxx b/writerfilter/source/dmapper/PropertyMap.cxx
index acdcede9d6f9..335108f3c609 100644
--- a/writerfilter/source/dmapper/PropertyMap.cxx
+++ b/writerfilter/source/dmapper/PropertyMap.cxx
@@ -1145,26 +1145,26 @@ bool SectionPropertyMap::FloatingTableConversion( const DomainMapper_Impl& rDM_I
nTableWidth *= nTextAreaWidth / 100.0;
}
sal_Int32 nLeftMargin = 0;
- if ( rInfo.getPropertyValue( "LeftMargin" ) >>= nLeftMargin )
+ if ( rInfo.getPropertyValue( u"LeftMargin" ) >>= nLeftMargin )
nTableWidth += nLeftMargin;
sal_Int32 nRightMargin = 0;
- if ( rInfo.getPropertyValue( "RightMargin" ) >>= nRightMargin )
+ if ( rInfo.getPropertyValue( u"RightMargin" ) >>= nRightMargin )
nTableWidth += nRightMargin;
- sal_Int16 nHoriOrientRelation = rInfo.getPropertyValue( "HoriOrientRelation" ).get<sal_Int16>();
- sal_Int16 nVertOrientRelation = rInfo.getPropertyValue( "VertOrientRelation" ).get<sal_Int16>();
+ sal_Int16 nHoriOrientRelation = rInfo.getPropertyValue( u"HoriOrientRelation" ).get<sal_Int16>();
+ sal_Int16 nVertOrientRelation = rInfo.getPropertyValue( u"VertOrientRelation" ).get<sal_Int16>();
if ( nHoriOrientRelation == text::RelOrientation::PAGE_FRAME && nVertOrientRelation == text::RelOrientation::PAGE_FRAME )
{
- sal_Int16 nHoriOrient = rInfo.getPropertyValue( "HoriOrient" ).get<sal_Int16>();
- sal_Int16 nVertOrient = rInfo.getPropertyValue( "VertOrient" ).get<sal_Int16>();
+ sal_Int16 nHoriOrient = rInfo.getPropertyValue( u"HoriOrient" ).get<sal_Int16>();
+ sal_Int16 nVertOrient = rInfo.getPropertyValue( u"VertOrient" ).get<sal_Int16>();
if ( nHoriOrient == text::HoriOrientation::NONE && nVertOrient == text::VertOrientation::NONE )
{
// Anchor position is relative to the page horizontally and vertically as well and is an absolute position.
// The more close we are to the left edge, the less likely there will be any wrapping.
// The more close we are to the bottom, the more likely the table will span over to the next page
// So if we're in the bottom left quarter, don't do any conversion.
- sal_Int32 nHoriOrientPosition = rInfo.getPropertyValue( "HoriOrientPosition" ).get<sal_Int32>();
- sal_Int32 nVertOrientPosition = rInfo.getPropertyValue( "VertOrientPosition" ).get<sal_Int32>();
+ sal_Int32 nHoriOrientPosition = rInfo.getPropertyValue( u"HoriOrientPosition" ).get<sal_Int32>();
+ sal_Int32 nVertOrientPosition = rInfo.getPropertyValue( u"VertOrientPosition" ).get<sal_Int32>();
sal_Int32 nPageHeight = getProperty( PROP_HEIGHT )->second.get<sal_Int32>();
if ( nHoriOrientPosition < (nPageWidth / 2) && nVertOrientPosition >( nPageHeight / 2 ) )
return false;
@@ -1717,7 +1717,7 @@ void SectionPropertyMap::CloseSectionGroup( DomainMapper_Impl& rDM_Impl )
}
sal_Int32 nCharWidth = 423; //240 twip/ 12 pt
- const StyleSheetEntryPtr pEntry = rDM_Impl.GetStyleSheetTable()->FindStyleSheetByConvertedStyleName( "Standard" );
+ const StyleSheetEntryPtr pEntry = rDM_Impl.GetStyleSheetTable()->FindStyleSheetByConvertedStyleName( u"Standard" );
if ( pEntry )
{
std::optional< PropertyMap::Property > pPropHeight = pEntry->pProperties->getProperty( PROP_CHAR_HEIGHT_ASIAN );
diff --git a/writerfilter/source/dmapper/SettingsTable.cxx b/writerfilter/source/dmapper/SettingsTable.cxx
index 9cccf3ea1ba4..788fd93f25bc 100644
--- a/writerfilter/source/dmapper/SettingsTable.cxx
+++ b/writerfilter/source/dmapper/SettingsTable.cxx
@@ -810,7 +810,7 @@ void SettingsTable::ApplyProperties(uno::Reference<text::XTextDocument> const& x
}
}
-bool SettingsTable::GetCompatSettingValue( const OUString& sCompatName ) const
+bool SettingsTable::GetCompatSettingValue( std::u16string_view sCompatName ) const
{
bool bRet = false;
for (const auto& rProp : m_pImpl->m_aCompatSettings)
diff --git a/writerfilter/source/dmapper/SettingsTable.hxx b/writerfilter/source/dmapper/SettingsTable.hxx
index d2d0a28ce87e..035384af52be 100644
--- a/writerfilter/source/dmapper/SettingsTable.hxx
+++ b/writerfilter/source/dmapper/SettingsTable.hxx
@@ -90,7 +90,7 @@ public:
void ApplyProperties(css::uno::Reference<css::text::XTextDocument> const& xDoc);
- bool GetCompatSettingValue(const OUString& sCompatName) const;
+ bool GetCompatSettingValue(std::u16string_view sCompatName) const;
sal_Int32 GetWordCompatibilityMode() const;
const OUString& GetCurrentDatabaseDataSource() const;
diff --git a/writerfilter/source/dmapper/StyleSheetTable.cxx b/writerfilter/source/dmapper/StyleSheetTable.cxx
index ec258b7377c3..a67a7aed972e 100644
--- a/writerfilter/source/dmapper/StyleSheetTable.cxx
+++ b/writerfilter/source/dmapper/StyleSheetTable.cxx
@@ -1293,7 +1293,7 @@ void StyleSheetTable::ApplyStyleSheets( const FontTablePtr& rFontTable )
}
-StyleSheetEntryPtr StyleSheetTable::FindStyleSheetByISTD(const OUString& sIndex)
+StyleSheetEntryPtr StyleSheetTable::FindStyleSheetByISTD(std::u16string_view sIndex)
{
StyleSheetEntryPtr pRet;
for(const StyleSheetEntryPtr & rpEntry : m_pImpl->m_aStyleSheetEntries)
@@ -1308,7 +1308,7 @@ StyleSheetEntryPtr StyleSheetTable::FindStyleSheetByISTD(const OUString& sIndex)
}
-StyleSheetEntryPtr StyleSheetTable::FindStyleSheetByConvertedStyleName(const OUString& sIndex)
+StyleSheetEntryPtr StyleSheetTable::FindStyleSheetByConvertedStyleName(std::u16string_view sIndex)
{
StyleSheetEntryPtr pRet;
for(const StyleSheetEntryPtr & rpEntry : m_pImpl->m_aStyleSheetEntries)
diff --git a/writerfilter/source/dmapper/StyleSheetTable.hxx b/writerfilter/source/dmapper/StyleSheetTable.hxx
index f734cbb8822c..69469d19d37a 100644
--- a/writerfilter/source/dmapper/StyleSheetTable.hxx
+++ b/writerfilter/source/dmapper/StyleSheetTable.hxx
@@ -91,8 +91,8 @@ public:
void ApplyNumberingStyleNameToParaStyles();
void ApplyStyleSheets( const FontTablePtr& rFontTable );
- StyleSheetEntryPtr FindStyleSheetByISTD(const OUString& sIndex);
- StyleSheetEntryPtr FindStyleSheetByConvertedStyleName(const OUString& rIndex);
+ StyleSheetEntryPtr FindStyleSheetByISTD(std::u16string_view sIndex);
+ StyleSheetEntryPtr FindStyleSheetByConvertedStyleName(std::u16string_view rIndex);
StyleSheetEntryPtr FindDefaultParaStyle();
OUString ConvertStyleName( const OUString& rWWName, bool bExtendedSearch = false );
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 9977306b90f0..dc014457c8d5 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2152,7 +2152,7 @@ void RTFDocumentImpl::resetAttributes()
}
static bool lcl_containsProperty(const uno::Sequence<beans::Property>& rProperties,
- const OUString& rName)
+ std::u16string_view rName)
{
return std::any_of(rProperties.begin(), rProperties.end(),
[&](const beans::Property& rProperty) { return rProperty.Name == rName; });
diff --git a/writerperfect/qa/unit/EPUBExportTest.cxx b/writerperfect/qa/unit/EPUBExportTest.cxx
index e6ca36fed947..172b9e0ac9a2 100644
--- a/writerperfect/qa/unit/EPUBExportTest.cxx
+++ b/writerperfect/qa/unit/EPUBExportTest.cxx
@@ -55,7 +55,7 @@ public:
std::map<OUString, std::vector<OUString>> parseCss(const OUString& rName);
/// Looks up a key of a class in rCss.
static OUString getCss(std::map<OUString, std::vector<OUString>>& rCss, const OUString& rClass,
- const OUString& rKey);
+ std::u16string_view rKey);
};
void EPUBExportTest::setUp()
@@ -135,7 +135,7 @@ std::map<OUString, std::vector<OUString>> EPUBExportTest::parseCss(const OUStrin
}
OUString EPUBExportTest::getCss(std::map<OUString, std::vector<OUString>>& rCss,
- const OUString& rClass, const OUString& rKey)
+ const OUString& rClass, std::u16string_view rKey)
{
OUString aRet;
@@ -412,11 +412,11 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testNamedStyleInheritance)
std::map<OUString, std::vector<OUString>> aCssDoc = parseCss("OEBPS/styles/stylesheet.css");
OUString aBlue = getXPath(mpXmlDoc, "//xhtml:p[2]/xhtml:span[2]", "class");
- CPPUNIT_ASSERT_EQUAL(OUString("#0000ff"), EPUBExportTest::getCss(aCssDoc, aBlue, "color"));
+ CPPUNIT_ASSERT_EQUAL(OUString("#0000ff"), EPUBExportTest::getCss(aCssDoc, aBlue, u"color"));
// This failed, the span only had the properties from its style, but not
// from the style's parent(s).
CPPUNIT_ASSERT_EQUAL(OUString("'Liberation Mono'"),
- EPUBExportTest::getCss(aCssDoc, aBlue, "font-family"));
+ EPUBExportTest::getCss(aCssDoc, aBlue, u"font-family"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testNestedSpan)
@@ -432,9 +432,9 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testNestedSpan)
// Check formatting of nested span.
OUString aRed = getXPath(mpXmlDoc, "//xhtml:p/xhtml:span[2]", "class");
// This failed, direct formatting on top of named style was lost.
- CPPUNIT_ASSERT_EQUAL(OUString("#ff0000"), EPUBExportTest::getCss(aCssDoc, aRed, "color"));
+ CPPUNIT_ASSERT_EQUAL(OUString("#ff0000"), EPUBExportTest::getCss(aCssDoc, aRed, u"color"));
CPPUNIT_ASSERT_EQUAL(OUString("'Liberation Mono'"),
- EPUBExportTest::getCss(aCssDoc, aRed, "font-family"));
+ EPUBExportTest::getCss(aCssDoc, aRed, u"font-family"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testLineBreak)
@@ -473,10 +473,11 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testParaCharProps)
// Check formatting of the middle span.
OUString aMiddle = getXPath(mpXmlDoc, "//xhtml:p/xhtml:span[2]", "class");
CPPUNIT_ASSERT_EQUAL(OUString("italic"),
- EPUBExportTest::getCss(aCssDoc, aMiddle, "font-style"));
+ EPUBExportTest::getCss(aCssDoc, aMiddle, u"font-style"));
// Direct para formatting was lost, only direct char formatting was
// written, so this failed.
- CPPUNIT_ASSERT_EQUAL(OUString("bold"), EPUBExportTest::getCss(aCssDoc, aMiddle, "font-weight"));
+ CPPUNIT_ASSERT_EQUAL(OUString("bold"),
+ EPUBExportTest::getCss(aCssDoc, aMiddle, u"font-weight"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testSection)
@@ -517,7 +518,7 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testImageBorder)
OUString aClass = getXPath(mpXmlDoc, "//xhtml:img", "class");
// This failed, image had no border.
CPPUNIT_ASSERT_EQUAL(OUString("0.99pt dashed #ed1c24"),
- EPUBExportTest::getCss(aCssDoc, aClass, "border"));
+ EPUBExportTest::getCss(aCssDoc, aClass, u"border"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testImageNospan)
@@ -557,7 +558,7 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTableCellBorder)
= getXPath(mpXmlDoc, "//xhtml:table/xhtml:tbody/xhtml:tr[1]/xhtml:td[1]", "class");
// This failed, cell border wasn't exported.
CPPUNIT_ASSERT_EQUAL(OUString("0.05pt solid #000000"),
- EPUBExportTest::getCss(aCssDoc, aClass, "border-left"));
+ EPUBExportTest::getCss(aCssDoc, aClass, u"border-left"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTableCellWidth)
@@ -573,10 +574,10 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTableCellWidth)
OUString aClass3
= getXPath(mpXmlDoc, "//xhtml:table/xhtml:tbody/xhtml:tr[1]/xhtml:td[3]", "class");
// These failed, all widths were 0.
- CPPUNIT_ASSERT_GREATER(EPUBExportTest::getCss(aCssDoc, aClass2, "width").toDouble(),
- EPUBExportTest::getCss(aCssDoc, aClass1, "width").toDouble());
- CPPUNIT_ASSERT_GREATER(EPUBExportTest::getCss(aCssDoc, aClass3, "width").toDouble(),
- EPUBExportTest::getCss(aCssDoc, aClass1, "width").toDouble());
+ CPPUNIT_ASSERT_GREATER(EPUBExportTest::getCss(aCssDoc, aClass2, u"width").toDouble(),
+ EPUBExportTest::getCss(aCssDoc, aClass1, u"width").toDouble());
+ CPPUNIT_ASSERT_GREATER(EPUBExportTest::getCss(aCssDoc, aClass3, u"width").toDouble(),
+ EPUBExportTest::getCss(aCssDoc, aClass1, u"width").toDouble());
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTableRowHeight)
@@ -588,8 +589,8 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTableRowHeight)
OUString aClass1 = getXPath(mpXmlDoc, "//xhtml:table/xhtml:tbody/xhtml:tr[1]", "class");
OUString aClass2 = getXPath(mpXmlDoc, "//xhtml:table/xhtml:tbody/xhtml:tr[2]", "class");
// These failed, both heights were 0.
- CPPUNIT_ASSERT_GREATER(EPUBExportTest::getCss(aCssDoc, aClass2, "height").toDouble(),
- EPUBExportTest::getCss(aCssDoc, aClass1, "height").toDouble());
+ CPPUNIT_ASSERT_GREATER(EPUBExportTest::getCss(aCssDoc, aClass2, u"height").toDouble(),
+ EPUBExportTest::getCss(aCssDoc, aClass1, u"height").toDouble());
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testLink)
@@ -632,7 +633,7 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testLinkNamedCharFormat)
assertXPath(mpXmlDoc, "//xhtml:p/xhtml:a", "href", "http://libreoffice.org/");
OUString aClass = getXPath(mpXmlDoc, "//xhtml:p/xhtml:a/xhtml:span", "class");
- CPPUNIT_ASSERT_EQUAL(OUString("#ff0000"), EPUBExportTest::getCss(aCssDoc, aClass, "color"));
+ CPPUNIT_ASSERT_EQUAL(OUString("#ff0000"), EPUBExportTest::getCss(aCssDoc, aClass, u"color"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTableWidth)
@@ -644,7 +645,7 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTableWidth)
OUString aClass = getXPath(mpXmlDoc, "//xhtml:table", "class");
// This failed, relative total width of table was lost.
- CPPUNIT_ASSERT_EQUAL(OUString("50%"), EPUBExportTest::getCss(aCssDoc, aClass, "width"));
+ CPPUNIT_ASSERT_EQUAL(OUString("50%"), EPUBExportTest::getCss(aCssDoc, aClass, u"width"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTextBox)
@@ -664,7 +665,8 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTextBox)
OUString aClass = getXPath(mpXmlDoc, "//xhtml:div/xhtml:p/xhtml:span[3]", "class");
// This failed, the 3rd span was not italic.
- CPPUNIT_ASSERT_EQUAL(OUString("italic"), EPUBExportTest::getCss(aCssDoc, aClass, "font-style"));
+ CPPUNIT_ASSERT_EQUAL(OUString("italic"),
+ EPUBExportTest::getCss(aCssDoc, aClass, u"font-style"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testFontEmbedding)
@@ -676,7 +678,7 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testFontEmbedding)
// librevenge:name
std::map<OUString, std::vector<OUString>> aCssDoc = parseCss("OEBPS/styles/stylesheet.css");
// 'SketchFlow Print' or ''SketchFlow Print1'
- CPPUNIT_ASSERT(EPUBExportTest::getCss(aCssDoc, "font-face", "font-family")
+ CPPUNIT_ASSERT(EPUBExportTest::getCss(aCssDoc, "font-face", u"font-family")
.startsWith("'SketchFlow Print"));
// librevenge:mime-type
mpXmlDoc = parseExport("OEBPS/content.opf");
@@ -686,10 +688,10 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testFontEmbedding)
CPPUNIT_ASSERT(mxZipFile->hasByName("OEBPS/fonts/font0001.otf"));
// librevenge:font-style
CPPUNIT_ASSERT_EQUAL(OUString("normal"),
- EPUBExportTest::getCss(aCssDoc, "font-face", "font-style"));
+ EPUBExportTest::getCss(aCssDoc, "font-face", u"font-style"));
// librevenge:font-weight
CPPUNIT_ASSERT_EQUAL(OUString("normal"),
- EPUBExportTest::getCss(aCssDoc, "font-face", "font-weight"));
+ EPUBExportTest::getCss(aCssDoc, "font-face", u"font-weight"));
#endif
}
@@ -807,7 +809,7 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testSVG)
// This failed, we used the xlink attribute namespace, but we did not
// define its URL.
mpXmlDoc = parseExport("OEBPS/images/image0001.svg");
- assertXPathNSDef(mpXmlDoc, "/svg:svg", "xlink", "http://www.w3.org/1999/xlink");
+ assertXPathNSDef(mpXmlDoc, "/svg:svg", u"xlink", u"http://www.w3.org/1999/xlink");
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTdf115623SingleWritingMode)
@@ -818,7 +820,7 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTdf115623SingleWritingMode)
mpXmlDoc = parseExport("OEBPS/sections/section0001.xhtml");
OUString aClass = getXPath(mpXmlDoc, "//xhtml:body", "class");
CPPUNIT_ASSERT_EQUAL(OUString("vertical-rl"),
- EPUBExportTest::getCss(aCssDoc, aClass, "writing-mode"));
+ EPUBExportTest::getCss(aCssDoc, aClass, u"writing-mode"));
}
CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTdf115623SplitByChapter)
@@ -829,14 +831,14 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTdf115623SplitByChapter)
mpXmlDoc = parseExport("OEBPS/sections/section0001.xhtml");
OUString aClass = getXPath(mpXmlDoc, "//xhtml:body", "class");
CPPUNIT_ASSERT_EQUAL(OUString("vertical-rl"),
- EPUBExportTest::getCss(aCssDoc, aClass, "writing-mode"));
+ EPUBExportTest::getCss(aCssDoc, aClass, u"writing-mode"));
}
// Split HTML should keep the same writing-mode.
{
mpXmlDoc = parseExport("OEBPS/sections/section0002.xhtml");
OUString aClass = getXPath(mpXmlDoc, "//xhtml:body", "class");
CPPUNIT_ASSERT_EQUAL(OUString("vertical-rl"),
- EPUBExportTest::getCss(aCssDoc, aClass, "writing-mode"));
+ EPUBExportTest::getCss(aCssDoc, aClass, u"writing-mode"));
}
}
@@ -849,13 +851,13 @@ CPPUNIT_TEST_FIXTURE(EPUBExportTest, testTdf115623ManyPageSpans)
mpXmlDoc = parseExport("OEBPS/sections/section0001.xhtml");
OUString aClass = getXPath(mpXmlDoc, "//xhtml:body", "class");
CPPUNIT_ASSERT_EQUAL(OUString("vertical-rl"),
- EPUBExportTest::getCss(aCssDoc, aClass, "writing-mode"));
+ EPUBExportTest::getCss(aCssDoc, aClass, u"writing-mode"));
}
{
mpXmlDoc = parseExport("OEBPS/sections/section0002.xhtml");
OUString aClass = getXPath(mpXmlDoc, "//xhtml:body", "class");
CPPUNIT_ASSERT_EQUAL(OUString("horizontal-tb"),
- EPUBExportTest::getCss(aCssDoc, aClass, "writing-mode"));
+ EPUBExportTest::getCss(aCssDoc, aClass, u"writing-mode"));
}
}
diff --git a/writerperfect/source/common/DirectoryStream.cxx b/writerperfect/source/common/DirectoryStream.cxx
index 19ec454b293e..28c38daa686b 100644
--- a/writerperfect/source/common/DirectoryStream.cxx
+++ b/writerperfect/source/common/DirectoryStream.cxx
@@ -49,7 +49,7 @@ namespace writerperfect
{
namespace
{
-uno::Reference<io::XInputStream> findStream(ucbhelper::Content& rContent, const OUString& rName)
+uno::Reference<io::XInputStream> findStream(ucbhelper::Content& rContent, std::u16string_view rName)
{
uno::Reference<io::XInputStream> xInputStream;
diff --git a/xmlhelp/source/cxxhelp/provider/databases.cxx b/xmlhelp/source/cxxhelp/provider/databases.cxx
index b422d74efef8..fc6cdd2ed717 100644
--- a/xmlhelp/source/cxxhelp/provider/databases.cxx
+++ b/xmlhelp/source/cxxhelp/provider/databases.cxx
@@ -639,7 +639,7 @@ KeywordInfo::KeywordInfo( const std::vector< KeywordElement >& aVec )
}
bool Databases::checkModuleMatchForExtension
- ( const OUString& Database, const OUString& doclist )
+ ( std::u16string_view Database, const OUString& doclist )
{
bool bBelongsToDatabase = true;
diff --git a/xmlhelp/source/cxxhelp/provider/databases.hxx b/xmlhelp/source/cxxhelp/provider/databases.hxx
index f45032da7e12..9431328143c8 100644
--- a/xmlhelp/source/cxxhelp/provider/databases.hxx
+++ b/xmlhelp/source/cxxhelp/provider/databases.hxx
@@ -150,7 +150,7 @@ namespace chelp {
StaticModuleInformation* getStaticInformationForModule( const OUString& Module,
const OUString& Language );
- bool checkModuleMatchForExtension( const OUString& Database, const OUString& doclist );
+ bool checkModuleMatchForExtension( std::u16string_view Database, const OUString& doclist );
KeywordInfo* getKeyword( const OUString& Module,
const OUString& Language );
diff --git a/xmloff/inc/txtlists.hxx b/xmloff/inc/txtlists.hxx
index 1d335be473f9..0e77d60f2ec4 100644
--- a/xmloff/inc/txtlists.hxx
+++ b/xmloff/inc/txtlists.hxx
@@ -86,7 +86,7 @@ class XMLTextListsHelper
void PushListOnStack( const OUString& sListId,
const OUString& sListStyleName );
void PopListFromStack();
- bool EqualsToTopListStyleOnStack( const OUString& sListId ) const;
+ bool EqualsToTopListStyleOnStack( std::u16string_view sListId ) const;
/** for importing numbered-paragraph
note that the ID namespace for numbered-paragraph and regular list
@@ -101,7 +101,7 @@ class XMLTextListsHelper
/// get ID of the last numbered-paragraph iff it has given style-name
OUString GetNumberedParagraphListId(
const sal_uInt16 i_Level,
- const OUString& i_StyleName);
+ std::u16string_view i_StyleName);
/** Creates a NumRule from given style-name.
@param i_rImport the SvXMLImport
diff --git a/xmloff/source/chart/SchXMLAxisContext.cxx b/xmloff/source/chart/SchXMLAxisContext.cxx
index b4a6490e5a8d..d395fbae78f2 100644
--- a/xmloff/source/chart/SchXMLAxisContext.cxx
+++ b/xmloff/source/chart/SchXMLAxisContext.cxx
@@ -521,7 +521,7 @@ void SchXMLAxisContext::CreateAxis()
}
m_rbAxisPositionAttributeImported = m_rbAxisPositionAttributeImported || SchXMLTools::getPropertyFromContext(
- "CrossoverPosition", pPropStyleContext, pStylesCtxt ).hasValue();
+ u"CrossoverPosition", pPropStyleContext, pStylesCtxt ).hasValue();
}
}
}
diff --git a/xmloff/source/chart/SchXMLExport.cxx b/xmloff/source/chart/SchXMLExport.cxx
index 4c526f9b8236..af1f9e33bd4b 100644
--- a/xmloff/source/chart/SchXMLExport.cxx
+++ b/xmloff/source/chart/SchXMLExport.cxx
@@ -2275,7 +2275,7 @@ void disableLinkedNumberFormat(
}
// Entry not found. Insert a new entry for this.
- sal_Int32 nIndex = rMapper->GetEntryIndex(XML_NAMESPACE_CHART, "link-data-style-to-source", 0);
+ sal_Int32 nIndex = rMapper->GetEntryIndex(XML_NAMESPACE_CHART, u"link-data-style-to-source", 0);
XMLPropertyState aState(nIndex);
aState.maValue <<= false;
rPropStates.push_back(aState);
diff --git a/xmloff/source/chart/SchXMLPlotAreaContext.cxx b/xmloff/source/chart/SchXMLPlotAreaContext.cxx
index 521fcb58ce41..d64cb89ec573 100644
--- a/xmloff/source/chart/SchXMLPlotAreaContext.cxx
+++ b/xmloff/source/chart/SchXMLPlotAreaContext.cxx
@@ -305,7 +305,7 @@ void SchXMLPlotAreaContext::StartElement( const uno::Reference< xml::sax::XAttri
//lines on/off
//this old property is not supported fully anymore with the new chart, so we need to get the information a little bit different from similar properties
mrSeriesDefaultsAndStyles.maLinesOnProperty = SchXMLTools::getPropertyFromContext(
- "Lines", pPropStyleContext, pStylesCtxt );
+ u"Lines", pPropStyleContext, pStylesCtxt );
//handle automatic position and size
m_aOuterPositioning.readAutomaticPositioningProperties( pPropStyleContext, pStylesCtxt );
@@ -854,9 +854,9 @@ void SchXMLPositionAttributesHelper::readAutomaticPositioningProperties( XMLProp
{
//handle automatic position and size
SchXMLTools::getPropertyFromContext(
- "AutomaticSize", pPropStyleContext, pStylesCtxt ) >>= m_bAutoSize;
+ u"AutomaticSize", pPropStyleContext, pStylesCtxt ) >>= m_bAutoSize;
SchXMLTools::getPropertyFromContext(
- "AutomaticPosition", pPropStyleContext, pStylesCtxt ) >>= m_bAutoPosition;
+ u"AutomaticPosition", pPropStyleContext, pStylesCtxt ) >>= m_bAutoPosition;
}
}
@@ -1097,7 +1097,7 @@ void SetErrorBarPropertiesFromStyleName( const OUString& aStyleName, const uno::
XMLPropStyleContext * pSeriesStyleContext =
const_cast< XMLPropStyleContext * >( dynamic_cast< const XMLPropStyleContext * >( pStyle ));
- uno::Any aAny = SchXMLTools::getPropertyFromContext("ErrorBarStyle",
+ uno::Any aAny = SchXMLTools::getPropertyFromContext(u"ErrorBarStyle",
pSeriesStyleContext,pStylesCtxt);
if ( !aAny.hasValue() )
@@ -1107,68 +1107,68 @@ void SetErrorBarPropertiesFromStyleName( const OUString& aStyleName, const uno::
aAny >>= aBarStyle;
xBarProp->setPropertyValue("ErrorBarStyle", aAny);
- aAny = SchXMLTools::getPropertyFromContext("ShowPositiveError",
+ aAny = SchXMLTools::getPropertyFromContext(u"ShowPositiveError",
pSeriesStyleContext,pStylesCtxt);
if(aAny.hasValue())
xBarProp->setPropertyValue("ShowPositiveError",aAny);
- aAny = SchXMLTools::getPropertyFromContext("ShowNegativeError",
+ aAny = SchXMLTools::getPropertyFromContext(u"ShowNegativeError",
pSeriesStyleContext,pStylesCtxt);
if(aAny.hasValue())
xBarProp->setPropertyValue("ShowNegativeError",aAny);
- aAny = SchXMLTools::getPropertyFromContext("PositiveError",
+ aAny = SchXMLTools::getPropertyFromContext(u"PositiveError",
pSeriesStyleContext, pStylesCtxt);
if(aAny.hasValue())
xBarProp->setPropertyValue("PositiveError", aAny);
else
{
- aAny = SchXMLTools::getPropertyFromContext("ConstantErrorHigh",
+ aAny = SchXMLTools::getPropertyFromContext(u"ConstantErrorHigh",
pSeriesStyleContext, pStylesCtxt);
if(aAny.hasValue())
xBarProp->setPropertyValue("PositiveError", aAny);
}
- aAny = SchXMLTools::getPropertyFromContext("NegativeError",
+ aAny = SchXMLTools::getPropertyFromContext(u"NegativeError",
pSeriesStyleContext, pStylesCtxt);
if(aAny.hasValue())
xBarProp->setPropertyValue("NegativeError", aAny);
else
{
- aAny = SchXMLTools::getPropertyFromContext("ConstantErrorLow",
+ aAny = SchXMLTools::getPropertyFromContext(u"ConstantErrorLow",
pSeriesStyleContext, pStylesCtxt);
if(aAny.hasValue())
xBarProp->setPropertyValue("NegativeError", aAny);
}
- aAny = SchXMLTools::getPropertyFromContext("ErrorBarRangePositive",
+ aAny = SchXMLTools::getPropertyFromContext(u"ErrorBarRangePositive",
pSeriesStyleContext, pStylesCtxt);
if( aAny.hasValue() )
{
aAny >>= aPosRange;
}
- aAny = SchXMLTools::getPropertyFromContext("ErrorBarRangeNegative",
+ aAny = SchXMLTools::getPropertyFromContext(u"ErrorBarRangeNegative",
pSeriesStyleContext, pStylesCtxt);
if( aAny.hasValue() )
{
aAny >>= aNegRange;
}
- aAny = SchXMLTools::getPropertyFromContext("Weight",
+ aAny = SchXMLTools::getPropertyFromContext(u"Weight",
pSeriesStyleContext, pStylesCtxt);
if( aAny.hasValue() )
{
xBarProp->setPropertyValue("Weight", aAny);
}
- aAny = SchXMLTools::getPropertyFromContext("PercentageError",
+ aAny = SchXMLTools::getPropertyFromContext(u"PercentageError",
pSeriesStyleContext, pStylesCtxt);
if( aAny.hasValue() && aBarStyle == css::chart::ErrorBarStyle::RELATIVE )
{
@@ -1180,12 +1180,12 @@ void SetErrorBarPropertiesFromStyleName( const OUString& aStyleName, const uno::
{
case css::chart::ErrorBarStyle::ERROR_MARGIN:
{
- aAny = SchXMLTools::getPropertyFromContext("NegativeError",
+ aAny = SchXMLTools::getPropertyFromContext(u"NegativeError",
pSeriesStyleContext,pStylesCtxt);
xBarProp->setPropertyValue("NegativeError",aAny);
- aAny = SchXMLTools::getPropertyFromContext("PositiveError",
+ aAny = SchXMLTools::getPropertyFromContext(u"PositiveError",
pSeriesStyleContext,pStylesCtxt);
xBarProp->setPropertyValue("PositiveError",aAny);
diff --git a/xmloff/source/chart/SchXMLSeries2Context.cxx b/xmloff/source/chart/SchXMLSeries2Context.cxx
index 992a03d64113..939e2c3ae29c 100644
--- a/xmloff/source/chart/SchXMLSeries2Context.cxx
+++ b/xmloff/source/chart/SchXMLSeries2Context.cxx
@@ -165,7 +165,7 @@ void lcl_setSymbolSizeIfNeeded( const uno::Reference< beans::XPropertySet >& xSe
void lcl_resetSymbolSizeForPointsIfNecessary( const uno::Reference< beans::XPropertySet >& xPointProp, const SvXMLImport& rImport
, const XMLPropStyleContext * pPropStyleContext, const SvXMLStylesContext* pStylesCtxt )
{
- uno::Any aASymbolSize( SchXMLTools::getPropertyFromContext( "SymbolSize", pPropStyleContext, pStylesCtxt ) );
+ uno::Any aASymbolSize( SchXMLTools::getPropertyFromContext( u"SymbolSize", pPropStyleContext, pStylesCtxt ) );
if( !aASymbolSize.hasValue() )
lcl_setSymbolSizeIfNeeded( xPointProp, rImport );
}
@@ -173,7 +173,7 @@ void lcl_resetSymbolSizeForPointsIfNecessary( const uno::Reference< beans::XProp
void lcl_setLinkNumberFormatToSourceIfNeeded( const uno::Reference< beans::XPropertySet >& xPointProp
, const XMLPropStyleContext* pPropStyleContext, const SvXMLStylesContext* pStylesCtxt )
{
- uno::Any aAny( SchXMLTools::getPropertyFromContext("LinkNumberFormatToSource", pPropStyleContext, pStylesCtxt) );
+ uno::Any aAny( SchXMLTools::getPropertyFromContext(u"LinkNumberFormatToSource", pPropStyleContext, pStylesCtxt) );
if( aAny.hasValue() )
return;
@@ -519,7 +519,7 @@ void SchXMLSeries2Context::StartElement( const uno::Reference< xml::sax::XAttrib
const XMLPropStyleContext* pPropStyleContext = dynamic_cast< const XMLPropStyleContext * >( pStyle );
- uno::Any aASymbolSize( SchXMLTools::getPropertyFromContext( "SymbolSize"
+ uno::Any aASymbolSize( SchXMLTools::getPropertyFromContext( u"SymbolSize"
, pPropStyleContext, pStylesCtxt ) );
mbSymbolSizeIsMissingInFile = !aASymbolSize.hasValue();
}
@@ -981,7 +981,7 @@ void SchXMLSeries2Context::setStylesToRegressionCurves(
if( pCurrent )
{
pPropStyleContext = pCurrent;
- uno::Any aAny = SchXMLTools::getPropertyFromContext("RegressionType", pPropStyleContext, pStylesCtxt);
+ uno::Any aAny = SchXMLTools::getPropertyFromContext(u"RegressionType", pPropStyleContext, pStylesCtxt);
if ( aAny.hasValue() )
{
aAny >>= aServiceName;
@@ -995,7 +995,7 @@ void SchXMLSeries2Context::setStylesToRegressionCurves(
if( pCurrent )
{
pPropStyleContext = pCurrent;
- uno::Any aAny = SchXMLTools::getPropertyFromContext("RegressionType", pPropStyleContext, pStylesCtxt);
+ uno::Any aAny = SchXMLTools::getPropertyFromContext(u"RegressionType", pPropStyleContext, pStylesCtxt);
if ( aAny.hasValue() )
{
aAny >>= aServiceName;
diff --git a/xmloff/source/chart/SchXMLTools.cxx b/xmloff/source/chart/SchXMLTools.cxx
index 6ac7475a1afd..4c2a94c2292b 100644
--- a/xmloff/source/chart/SchXMLTools.cxx
+++ b/xmloff/source/chart/SchXMLTools.cxx
@@ -524,7 +524,7 @@ void CreateCategories(
}
}
-uno::Any getPropertyFromContext( const OUString& rPropertyName, const XMLPropStyleContext* pPropStyleContext, const SvXMLStylesContext* pStylesCtxt )
+uno::Any getPropertyFromContext( std::u16string_view rPropertyName, const XMLPropStyleContext* pPropStyleContext, const SvXMLStylesContext* pStylesCtxt )
{
uno::Any aRet;
if( !pPropStyleContext || !pStylesCtxt )
diff --git a/xmloff/source/chart/SchXMLTools.hxx b/xmloff/source/chart/SchXMLTools.hxx
index f57b41713ae1..f734faebaded 100644
--- a/xmloff/source/chart/SchXMLTools.hxx
+++ b/xmloff/source/chart/SchXMLTools.hxx
@@ -96,7 +96,7 @@ namespace SchXMLTools
sal_Int32 nDimensionIndex,
tSchXMLLSequencesPerIndex * pLSequencesPerIndex = nullptr );
- css::uno::Any getPropertyFromContext( const OUString& rPropertyName, const XMLPropStyleContext * pPropStyleContext, const SvXMLStylesContext* pStylesCtxt );
+ css::uno::Any getPropertyFromContext( std::u16string_view rPropertyName, const XMLPropStyleContext * pPropStyleContext, const SvXMLStylesContext* pStylesCtxt );
void exportText( SvXMLExport& rExport, const OUString& rText, bool bConvertTabsLFs );
diff --git a/xmloff/source/draw/XMLGraphicsDefaultStyle.cxx b/xmloff/source/draw/XMLGraphicsDefaultStyle.cxx
index 8795e0a7a645..c6c07e27ebcc 100644
--- a/xmloff/source/draw/XMLGraphicsDefaultStyle.cxx
+++ b/xmloff/source/draw/XMLGraphicsDefaultStyle.cxx
@@ -156,7 +156,7 @@ void XMLGraphicsDefaultStyle::SetDefaults()
GetStyles()->GetImportPropertyMapper(GetFamily())
->getPropertySetMapper());
sal_Int32 const nStrokeIndex(
- pImpPrMap->GetEntryIndex(XML_NAMESPACE_SVG, "stroke-color", 0));
+ pImpPrMap->GetEntryIndex(XML_NAMESPACE_SVG, u"stroke-color", 0));
if (std::none_of(GetProperties().begin(), GetProperties().end(),
XMLPropertyByIndex(nStrokeIndex)))
{
@@ -167,7 +167,7 @@ void XMLGraphicsDefaultStyle::SetDefaults()
Color const nFillColor( bIsAOO4
? Color(0xCF, 0xE7, 0xF5) : Color(153, 204, 255));
sal_Int32 const nFillIndex(
- pImpPrMap->GetEntryIndex(XML_NAMESPACE_DRAW, "fill-color", 0));
+ pImpPrMap->GetEntryIndex(XML_NAMESPACE_DRAW, u"fill-color", 0));
if (std::none_of(GetProperties().begin(), GetProperties().end(),
XMLPropertyByIndex(nFillIndex)))
{
@@ -176,7 +176,7 @@ void XMLGraphicsDefaultStyle::SetDefaults()
if (xInfo->hasPropertyByName("FillColor2"))
{
sal_Int32 const nFill2Index(pImpPrMap->GetEntryIndex(
- XML_NAMESPACE_DRAW, "secondary-fill-color", 0));
+ XML_NAMESPACE_DRAW, u"secondary-fill-color", 0));
if (std::none_of(GetProperties().begin(), GetProperties().end(),
XMLPropertyByIndex(nFill2Index)))
{
diff --git a/xmloff/source/draw/sdxmlexp.cxx b/xmloff/source/draw/sdxmlexp.cxx
index f7c4410659ed..c7a6b44401aa 100644
--- a/xmloff/source/draw/sdxmlexp.cxx
+++ b/xmloff/source/draw/sdxmlexp.cxx
@@ -1271,9 +1271,9 @@ void SdXMLExport::ImpWritePageMasterInfos()
}
}
-ImpXMLEXPPageMasterInfo* SdXMLExport::ImpGetPageMasterInfoByName(const OUString& rName)
+ImpXMLEXPPageMasterInfo* SdXMLExport::ImpGetPageMasterInfoByName(std::u16string_view rName)
{
- if(!rName.isEmpty())
+ if(!rName.empty())
{
for(const auto & pInfo : mvPageMasterInfoList)
{
diff --git a/xmloff/source/draw/sdxmlexp_impl.hxx b/xmloff/source/draw/sdxmlexp_impl.hxx
index c2c3f7a16c14..c350bf701e5a 100644
--- a/xmloff/source/draw/sdxmlexp_impl.hxx
+++ b/xmloff/source/draw/sdxmlexp_impl.hxx
@@ -122,7 +122,7 @@ class SdXMLExport : public SvXMLExport
void ImpWritePageMasterInfos();
void ImpPrepAutoLayoutInfos();
HeaderFooterPageSettingsImpl ImpPrepDrawPageHeaderFooterDecls( const css::uno::Reference< css::drawing::XDrawPage >& xDrawPage );
- ImpXMLEXPPageMasterInfo* ImpGetPageMasterInfoByName(const OUString& rName);
+ ImpXMLEXPPageMasterInfo* ImpGetPageMasterInfoByName(std::u16string_view rName);
void ImpPrepDrawPageInfos();
void ImpPrepMasterPageInfos();
diff --git a/xmloff/source/draw/ximpstyl.cxx b/xmloff/source/draw/ximpstyl.cxx
index 9e4fc706fe96..8cf89f450484 100644
--- a/xmloff/source/draw/ximpstyl.cxx
+++ b/xmloff/source/draw/ximpstyl.cxx
@@ -1102,7 +1102,7 @@ static bool canSkipReset(const OUString &rName, const XMLPropStyleContext* pProp
bool bOldStyleTextAutoGrowHeight(false);
rPropSet->getPropertyValue("TextAutoGrowHeight") >>= bOldStyleTextAutoGrowHeight;
- sal_Int32 nIndexStyle = rPrMap->GetEntryIndex(XML_NAMESPACE_DRAW, "auto-grow-height", 0);
+ sal_Int32 nIndexStyle = rPrMap->GetEntryIndex(XML_NAMESPACE_DRAW, u"auto-grow-height", 0);
if (nIndexStyle != -1)
{
const ::std::vector< XMLPropertyState > &rProperties = pPropStyle->GetProperties();
diff --git a/xmloff/source/forms/formcellbinding.cxx b/xmloff/source/forms/formcellbinding.cxx
index a32239ee551b..f27891c033a7 100644
--- a/xmloff/source/forms/formcellbinding.cxx
+++ b/xmloff/source/forms/formcellbinding.cxx
@@ -83,7 +83,7 @@ namespace
public:
explicit StringCompare( const OUString& _rReference ) : m_sReference( _rReference ) { }
- bool operator()( const OUString& _rCompare )
+ bool operator()( std::u16string_view _rCompare )
{
return ( _rCompare == m_sReference );
}
diff --git a/xmloff/source/style/xmlnumfi.cxx b/xmloff/source/style/xmlnumfi.cxx
index a7f9f1822cca..85c967eea110 100644
--- a/xmloff/source/style/xmlnumfi.cxx
+++ b/xmloff/source/style/xmlnumfi.cxx
@@ -77,7 +77,7 @@ public:
SvNumberFormatter* GetNumberFormatter() const { return pFormatter; }
const LocaleDataWrapper& GetLocaleData( LanguageType nLang );
- sal_uInt32 GetKeyForName( const OUString& rName );
+ sal_uInt32 GetKeyForName( std::u16string_view rName );
void AddKey( sal_uInt32 nKey, const OUString& rName, bool bRemoveAfterUse );
void SetUsed( sal_uInt32 nKey );
void RemoveVolatileFormats();
@@ -292,7 +292,7 @@ SvXMLNumImpData::SvXMLNumImpData(
SAL_WARN_IF( !rxContext.is(), "xmloff", "got no service manager" );
}
-sal_uInt32 SvXMLNumImpData::GetKeyForName( const OUString& rName )
+sal_uInt32 SvXMLNumImpData::GetKeyForName( std::u16string_view rName )
{
for (const auto& rObj : m_NameEntries)
{
diff --git a/xmloff/source/style/xmlprmap.cxx b/xmloff/source/style/xmlprmap.cxx
index 7d81ad0f3456..e6f8cd29ba4c 100644
--- a/xmloff/source/style/xmlprmap.cxx
+++ b/xmloff/source/style/xmlprmap.cxx
@@ -246,7 +246,7 @@ bool XMLPropertySetMapper::importXML(
// If there is no matching entry the method returns -1
sal_Int32 XMLPropertySetMapper::GetEntryIndex(
sal_uInt16 nNamespace,
- const OUString& rStrName,
+ std::u16string_view rStrName,
sal_uInt32 nPropType,
sal_Int32 nStartAt /* = -1 */ ) const
{
@@ -306,7 +306,7 @@ sal_Int32 XMLPropertySetMapper::GetEntryIndex(
sal_Int32 XMLPropertySetMapper::FindEntryIndex(
const char* sApiName,
sal_uInt16 nNameSpace,
- const OUString& sXMLName ) const
+ std::u16string_view sXMLName ) const
{
sal_Int32 nIndex = 0;
sal_Int32 nEntries = GetEntryCount();
diff --git a/xmloff/source/table/XMLTableExport.cxx b/xmloff/source/table/XMLTableExport.cxx
index 194f8e7121a1..a238bace6af5 100644
--- a/xmloff/source/table/XMLTableExport.cxx
+++ b/xmloff/source/table/XMLTableExport.cxx
@@ -417,7 +417,7 @@ static bool has_states( const std::vector< XMLPropertyState >& xPropStates )
// ODF export for a table cell.
- void XMLTableExport::ExportCell( const Reference < XCell >& xCell, const std::shared_ptr< XMLTableInfo >& rTableInfo, const OUString& rDefaultCellStyle )
+ void XMLTableExport::ExportCell( const Reference < XCell >& xCell, const std::shared_ptr< XMLTableInfo >& rTableInfo, std::u16string_view rDefaultCellStyle )
{
bool bIsMerged = false;
sal_Int32 nRowSpan = 0;
diff --git a/xmloff/source/text/txtexppr.cxx b/xmloff/source/text/txtexppr.cxx
index a381394cbb42..65cdf59b74ee 100644
--- a/xmloff/source/text/txtexppr.cxx
+++ b/xmloff/source/text/txtexppr.cxx
@@ -349,7 +349,7 @@ void XMLTextExportPropertySetMapper::ContextFontHeightFilter(
namespace {
// helper method; implementation below
-bool lcl_IsOutlineStyle(const SvXMLExport&, const OUString&);
+bool lcl_IsOutlineStyle(const SvXMLExport&, std::u16string_view);
void
lcl_checkMultiProperty(XMLPropertyState *const pState,
@@ -1173,7 +1173,7 @@ void XMLTextExportPropertySetMapper::ContextFilter(
namespace {
-bool lcl_IsOutlineStyle(const SvXMLExport &rExport, const OUString & rName)
+bool lcl_IsOutlineStyle(const SvXMLExport &rExport, std::u16string_view rName)
{
Reference< XChapterNumberingSupplier >
xCNSupplier(rExport.GetModel(), UNO_QUERY);
diff --git a/xmloff/source/text/txtimp.cxx b/xmloff/source/text/txtimp.cxx
index 2edf2d8f3f37..e5942678447c 100644
--- a/xmloff/source/text/txtimp.cxx
+++ b/xmloff/source/text/txtimp.cxx
@@ -1280,7 +1280,7 @@ static bool lcl_HasListStyle( const OUString& sStyleName,
const Reference < XNameContainer >& xParaStyles,
SvXMLImport const & rImport,
const OUString& sNumberingStyleName,
- const OUString& sOutlineStyleName )
+ std::u16string_view sOutlineStyleName )
{
bool bRet( false );
@@ -1818,8 +1818,8 @@ OUString XMLTextImportHelper::SetStyleAndAttrs(
{
if ( !lcl_HasListStyle( sStyleName,
m_xImpl->m_xParaStyles, GetXMLImport(),
- "NumberingStyleName",
- "" ) )
+ u"NumberingStyleName",
+ u"" ) )
{
// heading not in a list --> apply outline style
xPropSet->setPropertyValue( s_NumberingRules,
diff --git a/xmloff/source/text/txtlists.cxx b/xmloff/source/text/txtlists.cxx
index af53ad308d2f..b00852ce44be 100644
--- a/xmloff/source/text/txtlists.cxx
+++ b/xmloff/source/text/txtlists.cxx
@@ -299,7 +299,7 @@ void XMLTextListsHelper::PopListFromStack()
}
}
-bool XMLTextListsHelper::EqualsToTopListStyleOnStack( const OUString& sListId ) const
+bool XMLTextListsHelper::EqualsToTopListStyleOnStack( std::u16string_view sListId ) const
{
return mpListStack && sListId == mpListStack->back().second;
}
@@ -307,12 +307,12 @@ bool XMLTextListsHelper::EqualsToTopListStyleOnStack( const OUString& sListId )
OUString
XMLTextListsHelper::GetNumberedParagraphListId(
const sal_uInt16 i_Level,
- const OUString& i_StyleName)
+ std::u16string_view i_StyleName)
{
- if (i_StyleName.isEmpty()) {
+ if (i_StyleName.empty()) {
SAL_INFO("xmloff.text", "invalid numbered-paragraph: no style-name");
}
- if (!i_StyleName.isEmpty()
+ if (!i_StyleName.empty()
&& (i_Level < mLastNumberedParagraphs.size())
&& (mLastNumberedParagraphs[i_Level].first == i_StyleName) )
{
diff --git a/xmlscript/source/xmldlg_imexp/imp_share.hxx b/xmlscript/source/xmldlg_imexp/imp_share.hxx
index 6d8e9128a336..79ae41e4af0b 100644
--- a/xmlscript/source/xmldlg_imexp/imp_share.hxx
+++ b/xmlscript/source/xmldlg_imexp/imp_share.hxx
@@ -134,7 +134,7 @@ public:
OUString const & rStyleId,
css::uno::Reference< css::xml::input::XElement > const & xStyle );
css::uno::Reference< css::xml::input::XElement > getStyle(
- OUString const & rStyleId ) const;
+ std::u16string_view rStyleId ) const;
css::uno::Reference< css::uno::XComponentContext >
const & getComponentContext() const { return _xContext; }
diff --git a/xmlscript/source/xmldlg_imexp/xmldlg_import.cxx b/xmlscript/source/xmldlg_imexp/xmldlg_import.cxx
index 75d5bd481a63..2d3ae432e7a1 100644
--- a/xmlscript/source/xmldlg_imexp/xmldlg_import.cxx
+++ b/xmlscript/source/xmldlg_imexp/xmldlg_import.cxx
@@ -1756,7 +1756,7 @@ void DialogImport::addStyle(
}
Reference< xml::input::XElement > DialogImport::getStyle(
- OUString const & rStyleId ) const
+ std::u16string_view rStyleId ) const
{
for ( size_t nPos = 0; nPos < (*_pStyleNames).size(); ++nPos )
{
diff --git a/xmlsecurity/inc/xsecctl.hxx b/xmlsecurity/inc/xsecctl.hxx
index ff0b9e232137..a3551d4218b3 100644
--- a/xmlsecurity/inc/xsecctl.hxx
+++ b/xmlsecurity/inc/xsecctl.hxx
@@ -367,7 +367,7 @@ public:
/*
* For signature verification
*/
- void collectToVerify( const OUString& referenceId );
+ void collectToVerify( std::u16string_view referenceId );
void addSignature( sal_Int32 nSignatureId );
css::uno::Reference< css::xml::sax::XDocumentHandler > const & createSignatureReader(XMLSignatureHelper& rXMLSignatureHelper, sal_Int32 nType = 0);
void releaseSignatureReader();
diff --git a/xmlsecurity/source/component/certificatecontainer.cxx b/xmlsecurity/source/component/certificatecontainer.cxx
index 7e9db35583ca..8f921d881715 100644
--- a/xmlsecurity/source/component/certificatecontainer.cxx
+++ b/xmlsecurity/source/component/certificatecontainer.cxx
@@ -44,11 +44,11 @@ private:
Map certMap;
Map certTrustMap;
- static bool searchMap(const OUString& url, const OUString& certificate_name, Map& _certMap);
+ static bool searchMap(const OUString& url, std::u16string_view certificate_name, Map& _certMap);
/// @throws css::uno::RuntimeException
- bool isTemporaryCertificate(const OUString& url, const OUString& certificate_name);
+ bool isTemporaryCertificate(const OUString& url, std::u16string_view certificate_name);
/// @throws css::uno::RuntimeException
- bool isCertificateTrust(const OUString& url, const OUString& certificate_name);
+ bool isCertificateTrust(const OUString& url, std::u16string_view certificate_name);
public:
explicit CertificateContainer(const uno::Reference<uno::XComponentContext>&) {}
@@ -67,7 +67,7 @@ public:
}
bool
-CertificateContainer::searchMap( const OUString & url, const OUString & certificate_name, Map &_certMap )
+CertificateContainer::searchMap( const OUString & url, std::u16string_view certificate_name, Map &_certMap )
{
Map::iterator p = _certMap.find(url);
@@ -85,13 +85,13 @@ CertificateContainer::searchMap( const OUString & url, const OUString & certific
}
bool
-CertificateContainer::isTemporaryCertificate ( const OUString & url, const OUString & certificate_name )
+CertificateContainer::isTemporaryCertificate ( const OUString & url, std::u16string_view certificate_name )
{
return searchMap( url, certificate_name, certMap);
}
bool
-CertificateContainer::isCertificateTrust ( const OUString & url, const OUString & certificate_name )
+CertificateContainer::isCertificateTrust ( const OUString & url, std::u16string_view certificate_name )
{
return searchMap( url, certificate_name, certTrustMap);
}
diff --git a/xmlsecurity/source/helper/xsecverify.cxx b/xmlsecurity/source/helper/xsecverify.cxx
index 24cf8b33091a..ec8d4f34f6b3 100644
--- a/xmlsecurity/source/helper/xsecverify.cxx
+++ b/xmlsecurity/source/helper/xsecverify.cxx
@@ -451,7 +451,7 @@ void XSecController::setPropertyId( OUString const & ouPropertyId )
}
/* public: for signature verify */
-void XSecController::collectToVerify( const OUString& referenceId )
+void XSecController::collectToVerify( std::u16string_view referenceId )
{
/* SAL_WARN_IF( !m_xSAXEventKeeper.is(), "xmlsecurity", "the SAXEventKeeper is NULL" ); */