summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-05-18 21:14:00 +0100
committerCaolán McNamara <caolanm@redhat.com>2017-05-19 15:40:40 +0200
commit2155e04d6343638ca9815d394cbc4f78c2b17c3a (patch)
tree0378142f6ce9edb63074291aed45527568e7b254 /sc
parentcee02e81cd3b55fb46eacf5db5713e8bf4363bcd (diff)
make string translation loading more uniform
change various ResId classes that use conversion operator to OUString to functions that return a OUString drop various defines drop unnecessary toString calls Change-Id: Ibeccdf2b91a46a2ed5b4b74e6024e301a023bc92 Reviewed-on: https://gerrit.libreoffice.org/37817 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc')
-rw-r--r--sc/inc/scresid.hxx10
-rw-r--r--sc/qa/unit/screenshots/screenshots.cxx6
-rw-r--r--sc/source/core/data/documen8.cxx4
-rw-r--r--sc/source/core/data/dpdimsave.cxx1
-rw-r--r--sc/source/core/data/dpoutput.cxx4
-rw-r--r--sc/source/core/data/funcdesc.cxx4
-rw-r--r--sc/source/core/tool/autoform.cxx2
-rw-r--r--sc/source/core/tool/inputopt.cxx1
-rw-r--r--sc/source/core/tool/rangeutl.cxx1
-rw-r--r--sc/source/ui/Accessibility/AccessibleDocument.cxx6
-rw-r--r--sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx2
-rw-r--r--sc/source/ui/Accessibility/AccessiblePageHeader.cxx6
-rw-r--r--sc/source/ui/Accessibility/AccessiblePageHeaderArea.cxx6
-rw-r--r--sc/source/ui/Accessibility/AccessiblePreviewTable.cxx2
-rw-r--r--sc/source/ui/Accessibility/AccessibleTableBase.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx22
-rw-r--r--sc/source/ui/StatisticsDialogs/ChiSquareTestDialog.cxx14
-rw-r--r--sc/source/ui/StatisticsDialogs/CorrelationDialog.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/CovarianceDialog.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/DescriptiveStatisticsDialog.cxx6
-rw-r--r--sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx6
-rw-r--r--sc/source/ui/StatisticsDialogs/FTestDialog.cxx32
-rw-r--r--sc/source/ui/StatisticsDialogs/MatrixComparisonGenerator.cxx8
-rw-r--r--sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx4
-rw-r--r--sc/source/ui/StatisticsDialogs/RandomNumberGeneratorDialog.cxx28
-rw-r--r--sc/source/ui/StatisticsDialogs/RegressionDialog.cxx14
-rw-r--r--sc/source/ui/StatisticsDialogs/SamplingDialog.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/StatisticsInputOutputDialog.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/TTestDialog.cxx36
-rw-r--r--sc/source/ui/StatisticsDialogs/ZTestDialog.cxx30
-rw-r--r--sc/source/ui/app/inputwin.cxx4
-rw-r--r--sc/source/ui/app/scdll.cxx4
-rw-r--r--sc/source/ui/app/scmod.cxx4
-rw-r--r--sc/source/ui/cctrl/checklistmenu.cxx8
-rw-r--r--sc/source/ui/condformat/condformatdlgentry.cxx2
-rw-r--r--sc/source/ui/dbgui/filtdlg.cxx10
-rw-r--r--sc/source/ui/dbgui/pfiltdlg.cxx8
-rw-r--r--sc/source/ui/dbgui/pvfundlg.cxx3
-rw-r--r--sc/source/ui/dbgui/scuiimoptdlg.cxx4
-rw-r--r--sc/source/ui/dbgui/sfiltdlg.cxx2
-rw-r--r--sc/source/ui/dbgui/tpsort.cxx12
-rw-r--r--sc/source/ui/dbgui/tpsubt.cxx4
-rw-r--r--sc/source/ui/dialogs/searchresults.cxx2
-rw-r--r--sc/source/ui/docshell/docsh.cxx2
-rw-r--r--sc/source/ui/docshell/documentlinkmgr.cxx2
-rw-r--r--sc/source/ui/drawfunc/fuconrec.cxx18
-rw-r--r--sc/source/ui/drawfunc/graphsh.cxx2
-rw-r--r--sc/source/ui/miscdlgs/acredlin.cxx32
-rw-r--r--sc/source/ui/miscdlgs/filldlg.cxx2
-rw-r--r--sc/source/ui/navipi/navipi.cxx6
-rw-r--r--sc/source/ui/optdlg/tpformula.cxx6
-rw-r--r--sc/source/ui/optdlg/tpview.cxx2
-rw-r--r--sc/source/ui/pagedlg/tphfedit.cxx6
-rw-r--r--sc/source/ui/unoobj/PivotTableDataProvider.cxx4
-rw-r--r--sc/source/ui/unoobj/docuno.cxx20
-rw-r--r--sc/source/ui/view/drawvie3.cxx4
-rw-r--r--sc/source/ui/view/gridwin.cxx12
-rw-r--r--sc/source/ui/view/gridwin2.cxx6
-rw-r--r--sc/source/ui/view/tabvwshf.cxx10
60 files changed, 233 insertions, 235 deletions
diff --git a/sc/inc/scresid.hxx b/sc/inc/scresid.hxx
index d74c870d8101..d754f8eeea8f 100644
--- a/sc/inc/scresid.hxx
+++ b/sc/inc/scresid.hxx
@@ -20,16 +20,10 @@
#ifndef INCLUDED_SC_INC_SCRESID_HXX
#define INCLUDED_SC_INC_SCRESID_HXX
-#include <tools/resid.hxx>
+#include <rtl/ustring.hxx>
#include "scdllapi.h"
-class SC_DLLPUBLIC ScResId : public ResId
-{
- public:
- ScResId( sal_uInt16 nId ); // in scdll.cxx
-};
-
-#define SC_RESSTR(x) ScResId(x).toString()
+OUString SC_DLLPUBLIC ScResId(sal_uInt16 nId);
#endif // SC_SCRESMGR_HXX
diff --git a/sc/qa/unit/screenshots/screenshots.cxx b/sc/qa/unit/screenshots/screenshots.cxx
index ee6441535450..9e6b65ec4a5f 100644
--- a/sc/qa/unit/screenshots/screenshots.cxx
+++ b/sc/qa/unit/screenshots/screenshots.cxx
@@ -206,7 +206,7 @@ VclPtr<VclAbstractDialog> ScScreenshotTest::createDialogByID(sal_uInt32 nID)
{
const OString aEmpty("");
pReturnDialog = mpFact->CreateScStringInputDlg(mpViewShell->GetDialogParent(),
- OUString(ScResId(SCSTR_APDTABLE)), OUString(ScResId(SCSTR_NAME)),
+ ScResId(SCSTR_APDTABLE), ScResId(SCSTR_NAME),
aDefaultSheetName, aEmpty, aEmpty );
break;
}
@@ -214,8 +214,8 @@ VclPtr<VclAbstractDialog> ScScreenshotTest::createDialogByID(sal_uInt32 nID)
case 9: // "modules/scalc/ui/tabcolordialog.ui"
{
pReturnDialog = mpFact->CreateScTabBgColorDlg(mpViewShell->GetDialogParent(),
- OUString(ScResId(SCSTR_SET_TAB_BG_COLOR)),
- OUString(ScResId(SCSTR_NO_TAB_BG_COLOR)), Color(0xff00ff) );
+ ScResId(SCSTR_SET_TAB_BG_COLOR),
+ ScResId(SCSTR_NO_TAB_BG_COLOR), Color(0xff00ff) );
break;
}
diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx
index 4c6b9b51a19b..418de1e29fa1 100644
--- a/sc/source/core/data/documen8.cxx
+++ b/sc/source/core/data/documen8.cxx
@@ -814,7 +814,7 @@ void ScDocument::UpdateExternalRefLinks(vcl::Window* pWin)
sc::WaitPointerSwitch aWaitSwitch(pWin);
pExternalRefMgr->enableDocTimer(false);
- ScProgress aProgress(GetDocumentShell(), ScResId(SCSTR_UPDATE_EXTDOCS).toString(), aRefLinks.size(), true);
+ ScProgress aProgress(GetDocumentShell(), ScResId(SCSTR_UPDATE_EXTDOCS), aRefLinks.size(), true);
for (size_t i = 0, n = aRefLinks.size(); i < n; ++i)
{
aProgress.SetState(i+1);
@@ -835,7 +835,7 @@ void ScDocument::UpdateExternalRefLinks(vcl::Window* pWin)
aFile = aUrl.GetMainURL(INetURLObject::DecodeMechanism::Unambiguous);
OUStringBuffer aBuf;
- aBuf.append(OUString(ScResId(SCSTR_EXTDOC_NOT_LOADED)));
+ aBuf.append(ScResId(SCSTR_EXTDOC_NOT_LOADED));
aBuf.append("\n\n");
aBuf.append(aFile);
ScopedVclPtrInstance< MessageDialog > aBox(pWin, aBuf.makeStringAndClear());
diff --git a/sc/source/core/data/dpdimsave.cxx b/sc/source/core/data/dpdimsave.cxx
index 1a67cb577fc4..3ecc2ee04e75 100644
--- a/sc/source/core/data/dpdimsave.cxx
+++ b/sc/source/core/data/dpdimsave.cxx
@@ -26,6 +26,7 @@
#include <com/sun/star/sheet/DataPilotFieldGroupBy.hpp>
#include <svl/zforlist.hxx>
+#include <osl/diagnose.h>
#include <rtl/math.hxx>
#include <algorithm>
diff --git a/sc/source/core/data/dpoutput.cxx b/sc/source/core/data/dpoutput.cxx
index b8c02b9d4963..d9fe4a1aaadd 100644
--- a/sc/source/core/data/dpoutput.cxx
+++ b/sc/source/core/data/dpoutput.cxx
@@ -977,13 +977,13 @@ void ScDPOutput::Output()
FieldCell(nHdrCol, nHdrRow, nTab, pPageFields[nField], false);
SCCOL nFldCol = nHdrCol + 1;
- OUString aPageValue = ScResId(SCSTR_ALL).toString();
+ OUString aPageValue = ScResId(SCSTR_ALL);
const uno::Sequence<sheet::MemberResult>& rRes = pPageFields[nField].maResult;
sal_Int32 n = rRes.getLength();
if (n == 1)
aPageValue = rRes[0].Caption;
else if (n > 1)
- aPageValue = ScResId(SCSTR_MULTIPLE).toString();
+ aPageValue = ScResId(SCSTR_MULTIPLE);
ScSetStringParam aParam;
aParam.setTextInput();
diff --git a/sc/source/core/data/funcdesc.cxx b/sc/source/core/data/funcdesc.cxx
index a5c825a462dc..012308cc99bc 100644
--- a/sc/source/core/data/funcdesc.cxx
+++ b/sc/source/core/data/funcdesc.cxx
@@ -810,7 +810,7 @@ ScFunctionList::ScFunctionList()
// OpCodes, which is utopian...
for (sal_uInt16 i = 0; i <= SC_OPCODE_LAST_OPCODE_ID; ++i)
{
- ScResId aRes(RID_SC_FUNC_DESCRIPTIONS_START + i);
+ ResId aRes(RID_SC_FUNC_DESCRIPTIONS_START + i, *SC_MOD()->GetResMgr());
aRes.SetRT(RSC_STRINGARRAY);
// Opcode Resource available?
if (SC_MOD()->GetResMgr()->IsAvailable(aRes))
@@ -1179,7 +1179,7 @@ OUString ScFunctionMgr::GetCategoryName(sal_uInt32 _nCategoryNumber )
return OUString();
}
- ResStringArray aStringArray(ScResId(RID_FUNCTION_CATEGORIES));
+ ResStringArray aStringArray(ResId(RID_FUNCTION_CATEGORIES, *SC_MOD()->GetResMgr()));
return aStringArray.GetString(_nCategoryNumber);
}
diff --git a/sc/source/core/tool/autoform.cxx b/sc/source/core/tool/autoform.cxx
index 045581c3d4ba..6b7cd8b84452 100644
--- a/sc/source/core/tool/autoform.cxx
+++ b/sc/source/core/tool/autoform.cxx
@@ -773,7 +773,7 @@ bool ScAutoFormatData::Load( SvStream& rStream, const ScAfVersions& rVersions )
if( RID_SVXSTR_TBLAFMT_BEGIN <= nId &&
nId < RID_SVXSTR_TBLAFMT_END )
{
- aName = SVX_RESSTR( nId );
+ aName = SvxResId( nId );
}
else
nStrResId = USHRT_MAX;
diff --git a/sc/source/core/tool/inputopt.cxx b/sc/source/core/tool/inputopt.cxx
index 4337194a425a..b2cdf34646b4 100644
--- a/sc/source/core/tool/inputopt.cxx
+++ b/sc/source/core/tool/inputopt.cxx
@@ -19,6 +19,7 @@
#include <com/sun/star/uno/Any.hxx>
#include <com/sun/star/uno/Sequence.hxx>
+#include <osl/diagnose.h>
#include "cfgids.hxx"
#include "inputopt.hxx"
diff --git a/sc/source/core/tool/rangeutl.cxx b/sc/source/core/tool/rangeutl.cxx
index ea0dbf962be8..0d8ee77dd82d 100644
--- a/sc/source/core/tool/rangeutl.cxx
+++ b/sc/source/core/tool/rangeutl.cxx
@@ -18,6 +18,7 @@
*/
#include <memory>
+#include <osl/diagnose.h>
#include "rangeutl.hxx"
#include "document.hxx"
#include "global.hxx"
diff --git a/sc/source/ui/Accessibility/AccessibleDocument.cxx b/sc/source/ui/Accessibility/AccessibleDocument.cxx
index 2fbabe9efa36..e2336902a3bd 100644
--- a/sc/source/ui/Accessibility/AccessibleDocument.cxx
+++ b/sc/source/ui/Accessibility/AccessibleDocument.cxx
@@ -1566,7 +1566,7 @@ void ScAccessibleDocument::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
{
mpTempAccEdit = new ScAccessibleEditObject(this, rViewData.GetEditView(meSplitPos),
mpViewShell->GetWindowByPos(meSplitPos), GetCurrentCellName(),
- OUString(ScResId(STR_ACC_EDITLINE_DESCR)), ScAccessibleEditObject::CellInEditMode);
+ ScResId(STR_ACC_EDITLINE_DESCR), ScAccessibleEditObject::CellInEditMode);
uno::Reference<XAccessible> xAcc = mpTempAccEdit;
AddChild(xAcc, true);
@@ -2120,7 +2120,7 @@ OUString SAL_CALL
{
SolarMutexGuard aGuard;
IsObjectValid();
- OUString sName = OUString(ScResId(STR_ACC_DOC_NAME));
+ OUString sName = ScResId(STR_ACC_DOC_NAME);
sal_Int32 nNumber(sal_Int32(meSplitPos) + 1);
sName += OUString::number(nNumber);
return sName;
@@ -2238,7 +2238,7 @@ void ScAccessibleDocument::RemoveChild(const uno::Reference<XAccessible>& xAcc,
OUString ScAccessibleDocument::GetCurrentCellName() const
{
- OUString sName(SC_RESSTR(STR_ACC_CELL_NAME));
+ OUString sName(ScResId(STR_ACC_CELL_NAME));
if (mpViewShell)
{
// Document not needed, because only the cell address, but not the tablename is needed
diff --git a/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx b/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx
index 21e84ddaaca7..4a76e4abb9f5 100644
--- a/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx
+++ b/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx
@@ -1521,7 +1521,7 @@ OUString SAL_CALL ScAccessibleDocumentPagePreview::createAccessibleDescription()
OUString SAL_CALL ScAccessibleDocumentPagePreview::createAccessibleName()
{
- OUString sName = OUString(ScResId(STR_ACC_PREVIEWDOC_NAME));
+ OUString sName = ScResId(STR_ACC_PREVIEWDOC_NAME);
return sName;
}
diff --git a/sc/source/ui/Accessibility/AccessiblePageHeader.cxx b/sc/source/ui/Accessibility/AccessiblePageHeader.cxx
index 7bc640910bdf..80f33b6e9516 100644
--- a/sc/source/ui/Accessibility/AccessiblePageHeader.cxx
+++ b/sc/source/ui/Accessibility/AccessiblePageHeader.cxx
@@ -299,13 +299,13 @@ uno::Sequence<OUString> SAL_CALL ScAccessiblePageHeader::getSupportedServiceName
OUString SAL_CALL ScAccessiblePageHeader::createAccessibleDescription()
{
OUString sDesc(mbHeader ? OUString(STR_ACC_HEADER_DESCR) : OUString(STR_ACC_FOOTER_DESCR));
- return sDesc.replaceFirst("%1", SC_RESSTR(SCSTR_UNKNOWN));
+ return sDesc.replaceFirst("%1", ScResId(SCSTR_UNKNOWN));
}
OUString SAL_CALL ScAccessiblePageHeader::createAccessibleName()
{
- OUString sName(SC_RESSTR(mbHeader ? STR_ACC_HEADER_NAME : STR_ACC_FOOTER_NAME));
- return sName.replaceFirst("%1", SC_RESSTR(SCSTR_UNKNOWN));
+ OUString sName(ScResId(mbHeader ? STR_ACC_HEADER_NAME : STR_ACC_FOOTER_NAME));
+ return sName.replaceFirst("%1", ScResId(SCSTR_UNKNOWN));
}
tools::Rectangle ScAccessiblePageHeader::GetBoundingBoxOnScreen() const
diff --git a/sc/source/ui/Accessibility/AccessiblePageHeaderArea.cxx b/sc/source/ui/Accessibility/AccessiblePageHeaderArea.cxx
index 5f05a33da2cb..da2c3bcc02c3 100644
--- a/sc/source/ui/Accessibility/AccessiblePageHeaderArea.cxx
+++ b/sc/source/ui/Accessibility/AccessiblePageHeaderArea.cxx
@@ -229,13 +229,13 @@ OUString SAL_CALL ScAccessiblePageHeaderArea::createAccessibleName()
switch (meAdjust)
{
case SvxAdjust::Left :
- sName = OUString(ScResId(STR_ACC_LEFTAREA_NAME));
+ sName = ScResId(STR_ACC_LEFTAREA_NAME);
break;
case SvxAdjust::Right:
- sName = OUString(ScResId(STR_ACC_RIGHTAREA_NAME));
+ sName = ScResId(STR_ACC_RIGHTAREA_NAME);
break;
case SvxAdjust::Center:
- sName = OUString(ScResId(STR_ACC_CENTERAREA_NAME));
+ sName = ScResId(STR_ACC_CENTERAREA_NAME);
break;
default:
OSL_FAIL("wrong adjustment found");
diff --git a/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx b/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
index e4b47a759da7..7354b92bf90e 100644
--- a/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
+++ b/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
@@ -586,7 +586,7 @@ OUString SAL_CALL ScAccessiblePreviewTable::createAccessibleDescription()
OUString SAL_CALL ScAccessiblePreviewTable::createAccessibleName()
{
- OUString sName(SC_RESSTR(STR_ACC_TABLE_NAME));
+ OUString sName(ScResId(STR_ACC_TABLE_NAME));
if (mpViewShell)
{
diff --git a/sc/source/ui/Accessibility/AccessibleTableBase.cxx b/sc/source/ui/Accessibility/AccessibleTableBase.cxx
index e83a421e542c..b598dba0953a 100644
--- a/sc/source/ui/Accessibility/AccessibleTableBase.cxx
+++ b/sc/source/ui/Accessibility/AccessibleTableBase.cxx
@@ -349,7 +349,7 @@ OUString SAL_CALL
OUString SAL_CALL ScAccessibleTableBase::createAccessibleName()
{
- OUString sName(SC_RESSTR(STR_ACC_TABLE_NAME));
+ OUString sName(ScResId(STR_ACC_TABLE_NAME));
OUString sCoreName;
if (mpDoc && mpDoc->GetName( maRange.aStart.Tab(), sCoreName ))
sName = sName.replaceFirst("%1", sCoreName);
diff --git a/sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx b/sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx
index 26918937235f..4c62091840f8 100644
--- a/sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx
@@ -182,7 +182,7 @@ void ScAnalysisOfVarianceDialog::RowColumn(ScRangeList& rRangeList, AddressWalke
else
{
sal_Int16 aLabelId = (aGroupedBy == BY_COLUMN) ? STR_COLUMN_LABEL_TEMPLATE : STR_ROW_LABEL_TEMPLATE;
- OUString aLabelTemplate(SC_RESSTR(aLabelId));
+ OUString aLabelTemplate(ScResId(aLabelId));
for (size_t i = 0; i < rRangeList.size(); i++)
{
@@ -198,11 +198,11 @@ void ScAnalysisOfVarianceDialog::RowColumn(ScRangeList& rRangeList, AddressWalke
void ScAnalysisOfVarianceDialog::AnovaSingleFactor(AddressWalkerWriter& output, FormulaTemplate& aTemplate)
{
- output.writeBoldString(SC_RESSTR(STR_ANOVA_SINGLE_FACTOR_LABEL));
+ output.writeBoldString(ScResId(STR_ANOVA_SINGLE_FACTOR_LABEL));
output.newLine();
double aAlphaValue = mpAlphaField->GetValue() / 100.0;
- output.writeString(SC_RESSTR(STR_LABEL_ALPHA));
+ output.writeString(ScResId(STR_LABEL_ALPHA));
output.nextColumn();
output.writeValue(aAlphaValue);
aTemplate.autoReplaceAddress("%ALPHA%", output.current());
@@ -212,7 +212,7 @@ void ScAnalysisOfVarianceDialog::AnovaSingleFactor(AddressWalkerWriter& output,
// Write labels
for(sal_Int32 i = 0; lclBasicStatistics[i].aLabelId != 0; i++)
{
- output.writeString(SC_RESSTR(lclBasicStatistics[i].aLabelId));
+ output.writeString(ScResId(lclBasicStatistics[i].aLabelId));
output.nextColumn();
}
output.newLine();
@@ -244,7 +244,7 @@ void ScAnalysisOfVarianceDialog::AnovaSingleFactor(AddressWalkerWriter& output,
output.resetColumn();
for(sal_Int32 i = 0; lclAnovaLabels[i] != 0; i++)
{
- output.writeString(SC_RESSTR(lclAnovaLabels[i]));
+ output.writeString(ScResId(lclAnovaLabels[i]));
output.nextColumn();
}
output.nextRow();
@@ -255,7 +255,7 @@ void ScAnalysisOfVarianceDialog::AnovaSingleFactor(AddressWalkerWriter& output,
{
// Label
output.resetColumn();
- output.writeString(SC_RESSTR(STR_ANOVA_LABEL_BETWEEN_GROUPS));
+ output.writeString(ScResId(STR_ANOVA_LABEL_BETWEEN_GROUPS));
output.nextColumn();
// Sum of Squares
@@ -301,7 +301,7 @@ void ScAnalysisOfVarianceDialog::AnovaSingleFactor(AddressWalkerWriter& output,
{
// Label
output.resetColumn();
- output.writeString(SC_RESSTR(STR_ANOVA_LABEL_WITHIN_GROUPS));
+ output.writeString(ScResId(STR_ANOVA_LABEL_WITHIN_GROUPS));
output.nextColumn();
// Sum of Squares
@@ -328,7 +328,7 @@ void ScAnalysisOfVarianceDialog::AnovaSingleFactor(AddressWalkerWriter& output,
{
// Label
output.resetColumn();
- output.writeString(SC_RESSTR(STR_ANOVA_LABEL_TOTAL));
+ output.writeString(ScResId(STR_ANOVA_LABEL_TOTAL));
output.nextColumn();
// Sum of Squares
@@ -346,7 +346,7 @@ void ScAnalysisOfVarianceDialog::AnovaSingleFactor(AddressWalkerWriter& output,
void ScAnalysisOfVarianceDialog::AnovaTwoFactor(AddressWalkerWriter& output, FormulaTemplate& aTemplate)
{
- output.writeBoldString(SC_RESSTR(STR_ANOVA_TWO_FACTOR_LABEL));
+ output.writeBoldString(ScResId(STR_ANOVA_TWO_FACTOR_LABEL));
output.newLine();
double aAlphaValue = mpAlphaField->GetValue() / 100.0;
@@ -360,7 +360,7 @@ void ScAnalysisOfVarianceDialog::AnovaTwoFactor(AddressWalkerWriter& output, For
// Write labels
for(sal_Int32 i = 0; lclBasicStatistics[i].aLabelId != 0; i++)
{
- output.writeString(SC_RESSTR(lclBasicStatistics[i].aLabelId));
+ output.writeString(ScResId(lclBasicStatistics[i].aLabelId));
output.nextColumn();
}
output.newLine();
@@ -409,7 +409,7 @@ void ScAnalysisOfVarianceDialog::AnovaTwoFactor(AddressWalkerWriter& output, For
// Write ANOVA labels
for(sal_Int32 i = 0; lclAnovaLabels[i] != 0; i++)
{
- output.writeString(SC_RESSTR(lclAnovaLabels[i]));
+ output.writeString(ScResId(lclAnovaLabels[i]));
output.nextColumn();
}
output.nextRow();
diff --git a/sc/source/ui/StatisticsDialogs/ChiSquareTestDialog.cxx b/sc/source/ui/StatisticsDialogs/ChiSquareTestDialog.cxx
index 0e5e1b3df014..1a7591a121e1 100644
--- a/sc/source/ui/StatisticsDialogs/ChiSquareTestDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/ChiSquareTestDialog.cxx
@@ -31,7 +31,7 @@ ScChiSquareTestDialog::ScChiSquareTestDialog(
pSfxBindings, pChildWindow, pParent, pViewData,
"ChiSquareTestDialog", "modules/scalc/ui/chisquaretestdialog.ui" )
{
- SetText(SC_RESSTR(STR_CHI_SQUARE_TEST));
+ SetText(ScResId(STR_CHI_SQUARE_TEST));
}
ScChiSquareTestDialog::~ScChiSquareTestDialog()
@@ -55,18 +55,18 @@ ScRange ScChiSquareTestDialog::ApplyOutput(ScDocShell* pDocShell)
aTemplate.autoReplaceRange("%RANGE%", mInputRange);
- aOutput.writeBoldString(SC_RESSTR(STR_CHI_SQUARE_TEST));
+ aOutput.writeBoldString(ScResId(STR_CHI_SQUARE_TEST));
aOutput.newLine();
// Alpha
- aOutput.writeString(SC_RESSTR(STR_LABEL_ALPHA));
+ aOutput.writeString(ScResId(STR_LABEL_ALPHA));
aOutput.nextColumn();
aOutput.writeValue(0.05);
aTemplate.autoReplaceAddress("%ALPHA%", aOutput.current());
aOutput.newLine();
// DF
- aOutput.writeString(SC_RESSTR(STR_DEGREES_OF_FREEDOM_LABEL));
+ aOutput.writeString(ScResId(STR_DEGREES_OF_FREEDOM_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=(COLUMNS(%RANGE%) - 1) * (ROWS(%RANGE%) - 1)");
aTemplate.autoReplaceAddress("%DEGREES_OF_FREEDOM%", aOutput.current());
@@ -74,7 +74,7 @@ ScRange ScChiSquareTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// p Value
- aOutput.writeString(SC_RESSTR(STR_P_VALUE_LABEL));
+ aOutput.writeString(ScResId(STR_P_VALUE_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=CHITEST(%RANGE%; MMULT(MMULT(%RANGE%;TRANSPOSE(IF(COLUMN(%RANGE%))));MMULT(TRANSPOSE(IF(ROW(%RANGE%)));%RANGE%)) / SUM(%RANGE%))");
aTemplate.autoReplaceAddress("%P_VALUE%", aOutput.current());
@@ -82,14 +82,14 @@ ScRange ScChiSquareTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// Test Statistic
- aOutput.writeString(SC_RESSTR(STR_TEST_STATISTIC_LABEL));
+ aOutput.writeString(ScResId(STR_TEST_STATISTIC_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=CHIINV(%P_VALUE%; %DEGREES_OF_FREEDOM%)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
// Critical value
- aOutput.writeString(SC_RESSTR(STR_CRITICAL_VALUE_LABEL));
+ aOutput.writeString(ScResId(STR_CRITICAL_VALUE_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=CHIINV(%ALPHA%; %DEGREES_OF_FREEDOM%)");
aOutput.writeFormula(aTemplate.getTemplate());
diff --git a/sc/source/ui/StatisticsDialogs/CorrelationDialog.cxx b/sc/source/ui/StatisticsDialogs/CorrelationDialog.cxx
index 09254e39af72..7eafe239aa40 100644
--- a/sc/source/ui/StatisticsDialogs/CorrelationDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/CorrelationDialog.cxx
@@ -28,7 +28,7 @@ bool ScCorrelationDialog::Close()
const OUString ScCorrelationDialog::getLabel()
{
- return SC_RESSTR(STR_CORRELATION_LABEL);
+ return ScResId(STR_CORRELATION_LABEL);
}
const OUString ScCorrelationDialog::getTemplate()
diff --git a/sc/source/ui/StatisticsDialogs/CovarianceDialog.cxx b/sc/source/ui/StatisticsDialogs/CovarianceDialog.cxx
index bb35aa7dce0e..5506444bfd41 100644
--- a/sc/source/ui/StatisticsDialogs/CovarianceDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/CovarianceDialog.cxx
@@ -33,7 +33,7 @@ bool ScCovarianceDialog::Close()
const OUString ScCovarianceDialog::getLabel()
{
- return SC_RESSTR(STR_COVARIANCE_LABEL);
+ return ScResId(STR_COVARIANCE_LABEL);
}
const OUString ScCovarianceDialog::getTemplate()
diff --git a/sc/source/ui/StatisticsDialogs/DescriptiveStatisticsDialog.cxx b/sc/source/ui/StatisticsDialogs/DescriptiveStatisticsDialog.cxx
index ce309cb135e9..2dcc463a840e 100644
--- a/sc/source/ui/StatisticsDialogs/DescriptiveStatisticsDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/DescriptiveStatisticsDialog.cxx
@@ -97,9 +97,9 @@ ScRange ScDescriptiveStatisticsDialog::ApplyOutput(ScDocShell* pDocShell)
for( ; pIterator->hasNext(); pIterator->next() )
{
if (mGroupedBy == BY_COLUMN)
- aTemplate.setTemplate(SC_RESSTR(STR_COLUMN_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_COLUMN_LABEL_TEMPLATE));
else
- aTemplate.setTemplate(SC_RESSTR(STR_ROW_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_ROW_LABEL_TEMPLATE));
aTemplate.applyNumber("%NUMBER%", pIterator->index() + 1);
aOutput.writeBoldString(aTemplate.getTemplate());
@@ -112,7 +112,7 @@ ScRange ScDescriptiveStatisticsDialog::ApplyOutput(ScDocShell* pDocShell)
// Write calculation labels
for(sal_Int32 i = 0; lclCalcDefinitions[i].aFormula != nullptr; i++)
{
- OUString aLabel(SC_RESSTR(lclCalcDefinitions[i].aCalculationNameId));
+ OUString aLabel(ScResId(lclCalcDefinitions[i].aCalculationNameId));
aOutput.writeString(aLabel);
aOutput.nextRow();
}
diff --git a/sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx b/sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx
index 0a7e5785340b..f5d679c3d339 100644
--- a/sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx
@@ -66,7 +66,7 @@ ScRange ScExponentialSmoothingDialog::ApplyOutput(ScDocShell* pDocShell)
double aSmoothingFactor = mpSmoothingFactor->GetValue() / 100.0;
// Alpha
- output.writeBoldString(SC_RESSTR(STR_LABEL_ALPHA));
+ output.writeBoldString(ScResId(STR_LABEL_ALPHA));
output.nextRow();
// Alpha Value
@@ -91,9 +91,9 @@ ScRange ScExponentialSmoothingDialog::ApplyOutput(ScDocShell* pDocShell)
// Write column label
if (mGroupedBy == BY_COLUMN)
- aTemplate.setTemplate(SC_RESSTR(STR_COLUMN_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_COLUMN_LABEL_TEMPLATE));
else
- aTemplate.setTemplate(SC_RESSTR(STR_ROW_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_ROW_LABEL_TEMPLATE));
aTemplate.applyNumber("%NUMBER%", pIterator->index() + 1);
output.writeBoldString(aTemplate.getTemplate());
output.nextRow();
diff --git a/sc/source/ui/StatisticsDialogs/FTestDialog.cxx b/sc/source/ui/StatisticsDialogs/FTestDialog.cxx
index 57b4ac77e0f0..a3cc2cb8b2b1 100644
--- a/sc/source/ui/StatisticsDialogs/FTestDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/FTestDialog.cxx
@@ -32,7 +32,7 @@ ScFTestDialog::ScFTestDialog(
pSfxBindings, pChildWindow, pParent, pViewData,
"TTestDialog", "modules/scalc/ui/ttestdialog.ui" )
{
- SetText(SC_RESSTR(STR_FTEST));
+ SetText(ScResId(STR_FTEST));
}
ScFTestDialog::~ScFTestDialog()
@@ -69,23 +69,23 @@ ScRange ScFTestDialog::ApplyOutput(ScDocShell* pDocShell)
aTemplate.autoReplaceRange("%VARIABLE1_RANGE%", pVariable1Iterator->get());
aTemplate.autoReplaceRange("%VARIABLE2_RANGE%", pVariable2Iterator->get());
- aOutput.writeBoldString(SC_RESSTR(STR_FTEST_UNDO_NAME));
+ aOutput.writeBoldString(ScResId(STR_FTEST_UNDO_NAME));
aOutput.newLine();
// Alpha
- aOutput.writeString(SC_RESSTR(STR_LABEL_ALPHA));
+ aOutput.writeString(ScResId(STR_LABEL_ALPHA));
aOutput.nextColumn();
aOutput.writeValue(0.05);
aTemplate.autoReplaceAddress("%ALPHA%", aOutput.current());
aOutput.newLine();
aOutput.nextColumn();
- aOutput.writeBoldString(SC_RESSTR(STR_VARIABLE_1_LABEL));
+ aOutput.writeBoldString(ScResId(STR_VARIABLE_1_LABEL));
aOutput.nextColumn();
- aOutput.writeBoldString(SC_RESSTR(STR_VARIABLE_2_LABEL));
+ aOutput.writeBoldString(ScResId(STR_VARIABLE_2_LABEL));
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STRID_CALC_MEAN));
+ aOutput.writeString(ScResId(STRID_CALC_MEAN));
aOutput.nextColumn();
aTemplate.setTemplate("=AVERAGE(%VARIABLE1_RANGE%)");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -94,7 +94,7 @@ ScRange ScFTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STRID_CALC_VARIANCE));
+ aOutput.writeString(ScResId(STRID_CALC_VARIANCE));
aOutput.nextColumn();
aTemplate.setTemplate("=VAR(%VARIABLE1_RANGE%)");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -105,7 +105,7 @@ ScRange ScFTestDialog::ApplyOutput(ScDocShell* pDocShell)
aTemplate.autoReplaceAddress("%VARIABLE2_VARIANCE%", aOutput.current());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_OBSERVATIONS_LABEL));
+ aOutput.writeString(ScResId(STR_OBSERVATIONS_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=COUNT(%VARIABLE1_RANGE%)");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -116,7 +116,7 @@ ScRange ScFTestDialog::ApplyOutput(ScDocShell* pDocShell)
aTemplate.autoReplaceAddress("%VARIABLE2_OBSERVATIONS%", aOutput.current());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_ANOVA_LABEL_DF));
+ aOutput.writeString(ScResId(STR_ANOVA_LABEL_DF));
aOutput.nextColumn();
aTemplate.setTemplate("=%VARIABLE1_OBSERVATIONS% - 1");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -127,46 +127,46 @@ ScRange ScFTestDialog::ApplyOutput(ScDocShell* pDocShell)
aTemplate.autoReplaceAddress("%VARIABLE2_DEGREE_OF_FREEDOM%", aOutput.current());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_ANOVA_LABEL_F));
+ aOutput.writeString(ScResId(STR_ANOVA_LABEL_F));
aOutput.nextColumn();
aTemplate.setTemplate("=%VARIABLE1_VARIANCE% / %VARIABLE2_VARIANCE%");
aOutput.writeFormula(aTemplate.getTemplate());
aTemplate.autoReplaceAddress("%F_VALUE%", aOutput.current());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_FTEST_P_RIGHT_TAIL));
+ aOutput.writeString(ScResId(STR_FTEST_P_RIGHT_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=FDIST(%F_VALUE%; %VARIABLE1_DEGREE_OF_FREEDOM%; %VARIABLE2_DEGREE_OF_FREEDOM%)");
aOutput.writeFormula(aTemplate.getTemplate());
aTemplate.autoReplaceAddress("%P_RIGHT_TAIL_VALUE%", aOutput.current());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_FTEST_F_CRITICAL_RIGHT_TAIL));
+ aOutput.writeString(ScResId(STR_FTEST_F_CRITICAL_RIGHT_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=FINV(%ALPHA%; %VARIABLE1_DEGREE_OF_FREEDOM%; %VARIABLE2_DEGREE_OF_FREEDOM%)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_FTEST_P_LEFT_TAIL));
+ aOutput.writeString(ScResId(STR_FTEST_P_LEFT_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=1 - %P_RIGHT_TAIL_VALUE%");
aOutput.writeFormula(aTemplate.getTemplate());
aTemplate.autoReplaceAddress("%P_LEFT_TAIL_VALUE%", aOutput.current());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_FTEST_F_CRITICAL_LEFT_TAIL));
+ aOutput.writeString(ScResId(STR_FTEST_F_CRITICAL_LEFT_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=FINV(1-%ALPHA%; %VARIABLE1_DEGREE_OF_FREEDOM%; %VARIABLE2_DEGREE_OF_FREEDOM%)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_FTEST_P_TWO_TAIL));
+ aOutput.writeString(ScResId(STR_FTEST_P_TWO_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=2*MIN(%P_RIGHT_TAIL_VALUE%; %P_LEFT_TAIL_VALUE%)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STR_FTEST_F_CRITICAL_TWO_TAIL));
+ aOutput.writeString(ScResId(STR_FTEST_F_CRITICAL_TWO_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=FINV(1-(%ALPHA%/2); %VARIABLE1_DEGREE_OF_FREEDOM%; %VARIABLE2_DEGREE_OF_FREEDOM%)");
aOutput.writeFormula(aTemplate.getTemplate());
diff --git a/sc/source/ui/StatisticsDialogs/MatrixComparisonGenerator.cxx b/sc/source/ui/StatisticsDialogs/MatrixComparisonGenerator.cxx
index 413e8c9be2ab..5d02286c98e9 100644
--- a/sc/source/ui/StatisticsDialogs/MatrixComparisonGenerator.cxx
+++ b/sc/source/ui/StatisticsDialogs/MatrixComparisonGenerator.cxx
@@ -86,9 +86,9 @@ ScRange ScMatrixComparisonGenerator::ApplyOutput(ScDocShell* pDocShell)
for (size_t i = 0; i < aRangeList.size(); i++)
{
if (mGroupedBy == BY_COLUMN)
- aTemplate.setTemplate(SC_RESSTR(STR_COLUMN_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_COLUMN_LABEL_TEMPLATE));
else
- aTemplate.setTemplate(SC_RESSTR(STR_ROW_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_ROW_LABEL_TEMPLATE));
aTemplate.applyNumber(strWildcardNumber, i + 1);
output.writeString(aTemplate.getTemplate());
@@ -101,9 +101,9 @@ ScRange ScMatrixComparisonGenerator::ApplyOutput(ScDocShell* pDocShell)
for (size_t i = 0; i < aRangeList.size(); i++)
{
if (mGroupedBy == BY_COLUMN)
- aTemplate.setTemplate(SC_RESSTR(STR_COLUMN_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_COLUMN_LABEL_TEMPLATE));
else
- aTemplate.setTemplate(SC_RESSTR(STR_ROW_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_ROW_LABEL_TEMPLATE));
aTemplate.applyNumber(strWildcardNumber, i + 1);
output.writeString(aTemplate.getTemplate());
diff --git a/sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx b/sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx
index 7ea5fadbbff5..540dd33e721c 100644
--- a/sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx
@@ -77,9 +77,9 @@ ScRange ScMovingAverageDialog::ApplyOutput(ScDocShell* pDocShell)
// Write label
if (mGroupedBy == BY_COLUMN)
- aTemplate.setTemplate(SC_RESSTR(STR_COLUMN_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_COLUMN_LABEL_TEMPLATE));
else
- aTemplate.setTemplate(SC_RESSTR(STR_ROW_LABEL_TEMPLATE));
+ aTemplate.setTemplate(ScResId(STR_ROW_LABEL_TEMPLATE));
aTemplate.applyNumber("%NUMBER%", pIterator->index() + 1);
output.writeBoldString(aTemplate.getTemplate());
diff --git a/sc/source/ui/StatisticsDialogs/RandomNumberGeneratorDialog.cxx b/sc/source/ui/StatisticsDialogs/RandomNumberGeneratorDialog.cxx
index eb639e60cc92..1c6e40b5a60a 100644
--- a/sc/source/ui/StatisticsDialogs/RandomNumberGeneratorDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/RandomNumberGeneratorDialog.cxx
@@ -281,8 +281,8 @@ void ScRandomNumberGeneratorDialog::SelectGeneratorAndGenerateNumbers()
template<class RNG>
void ScRandomNumberGeneratorDialog::GenerateNumbers(RNG& randomGenerator, const sal_Int16 aDistributionStringId, boost::optional<sal_Int8> aDecimalPlaces)
{
- OUString aUndo = SC_RESSTR(STR_UNDO_DISTRIBUTION_TEMPLATE);
- OUString aDistributionName = SC_RESSTR(aDistributionStringId);
+ OUString aUndo = ScResId(STR_UNDO_DISTRIBUTION_TEMPLATE);
+ OUString aDistributionName = ScResId(aDistributionStringId);
aUndo = aUndo.replaceAll("$(DISTRIBUTION)", aDistributionName);
ScDocShell* pDocShell = mpViewData->GetDocShell();
@@ -435,19 +435,19 @@ IMPL_LINK_NOARG(ScRandomNumberGeneratorDialog, DistributionChanged, ListBox&, vo
{
case DIST_UNIFORM:
{
- mpParameter1Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_MINIMUM));
- mpParameter2Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_MAXIMUM));
+ mpParameter1Text->SetText(ScResId(STR_RNG_PARAMETER_MINIMUM));
+ mpParameter2Text->SetText(ScResId(STR_RNG_PARAMETER_MAXIMUM));
mpParameter2Text->Show();
mpParameter2Value->Show();
break;
}
case DIST_UNIFORM_INTEGER:
{
- mpParameter1Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_MINIMUM));
+ mpParameter1Text->SetText(ScResId(STR_RNG_PARAMETER_MINIMUM));
mpParameter1Value->SetDecimalDigits(0);
mpParameter1Value->SetSpinSize(1);
- mpParameter2Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_MAXIMUM));
+ mpParameter2Text->SetText(ScResId(STR_RNG_PARAMETER_MAXIMUM));
mpParameter2Value->SetDecimalDigits(0);
mpParameter2Value->SetSpinSize(1);
@@ -457,16 +457,16 @@ IMPL_LINK_NOARG(ScRandomNumberGeneratorDialog, DistributionChanged, ListBox&, vo
}
case DIST_NORMAL:
{
- mpParameter1Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_MEAN));
- mpParameter2Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_STANDARD_DEVIATION));
+ mpParameter1Text->SetText(ScResId(STR_RNG_PARAMETER_MEAN));
+ mpParameter2Text->SetText(ScResId(STR_RNG_PARAMETER_STANDARD_DEVIATION));
mpParameter2Text->Show();
mpParameter2Value->Show();
break;
}
case DIST_CAUCHY:
{
- mpParameter1Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_STANDARD_MEDIAN));
- mpParameter2Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_STANDARD_SIGMA));
+ mpParameter1Text->SetText(ScResId(STR_RNG_PARAMETER_STANDARD_MEDIAN));
+ mpParameter2Text->SetText(ScResId(STR_RNG_PARAMETER_STANDARD_SIGMA));
mpParameter2Text->Show();
mpParameter2Value->Show();
break;
@@ -474,7 +474,7 @@ IMPL_LINK_NOARG(ScRandomNumberGeneratorDialog, DistributionChanged, ListBox&, vo
case DIST_BERNOULLI:
case DIST_GEOMETRIC:
{
- mpParameter1Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_STANDARD_PROBABILITY));
+ mpParameter1Text->SetText(ScResId(STR_RNG_PARAMETER_STANDARD_PROBABILITY));
mpParameter1Value->SetMin( 0 );
mpParameter1Value->SetMax( PERCISION );
mpParameter1Value->SetSpinSize(1000);
@@ -486,12 +486,12 @@ IMPL_LINK_NOARG(ScRandomNumberGeneratorDialog, DistributionChanged, ListBox&, vo
case DIST_BINOMIAL:
case DIST_NEGATIVE_BINOMIAL:
{
- mpParameter1Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_STANDARD_PROBABILITY));
+ mpParameter1Text->SetText(ScResId(STR_RNG_PARAMETER_STANDARD_PROBABILITY));
mpParameter1Value->SetMin( 0 );
mpParameter1Value->SetMax( PERCISION );
mpParameter1Value->SetSpinSize(1000);
- mpParameter2Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_STANDARD_NUMBER_OF_TRIALS));
+ mpParameter2Text->SetText(ScResId(STR_RNG_PARAMETER_STANDARD_NUMBER_OF_TRIALS));
mpParameter2Value->SetDecimalDigits(0);
mpParameter2Value->SetSpinSize(1);
mpParameter2Value->SetMin(0);
@@ -502,7 +502,7 @@ IMPL_LINK_NOARG(ScRandomNumberGeneratorDialog, DistributionChanged, ListBox&, vo
}
case DIST_CHI_SQUARED:
{
- mpParameter1Text->SetText(SC_RESSTR(STR_RNG_PARAMETER_STANDARD_NU_VALUE));
+ mpParameter1Text->SetText(ScResId(STR_RNG_PARAMETER_STANDARD_NU_VALUE));
mpParameter2Text->Hide();
mpParameter2Value->Hide();
diff --git a/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx b/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx
index 272b4b541c1f..6950c8dea61f 100644
--- a/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx
@@ -128,31 +128,31 @@ ScRange ScRegressionDialog::ApplyOutput(ScDocShell* pDocShell)
aTemplate.autoReplaceRange("%VARIABLE1_RANGE%", pVariable1Iterator->get());
aTemplate.autoReplaceRange("%VARIABLE2_RANGE%", pVariable2Iterator->get());
- aOutput.writeBoldString(SC_RESSTR(STR_REGRESSION));
+ aOutput.writeBoldString(ScResId(STR_REGRESSION));
aOutput.newLine();
aOutput.newLine();
aOutput.push();
// REGRESSION MODEL
- aOutput.writeString(SC_RESSTR(STR_LABEL_REGRESSION_MODEL));
+ aOutput.writeString(ScResId(STR_LABEL_REGRESSION_MODEL));
aOutput.nextRow();
// RSQUARED
- aOutput.writeString(SC_RESSTR(STR_LABEL_RSQUARED));
+ aOutput.writeString(ScResId(STR_LABEL_RSQUARED));
aOutput.nextRow();
// Standard Error
- aOutput.writeString(SC_RESSTR(STRID_CALC_STD_ERROR));
+ aOutput.writeString(ScResId(STRID_CALC_STD_ERROR));
aOutput.nextRow();
aOutput.nextRow();
// Slope
- aOutput.writeString(SC_RESSTR(STR_LABEL_SLOPE));
+ aOutput.writeString(ScResId(STR_LABEL_SLOPE));
aOutput.nextRow();
// Intercept
- aOutput.writeString(SC_RESSTR(STR_LABEL_INTERCEPT));
+ aOutput.writeString(ScResId(STR_LABEL_INTERCEPT));
aOutput.nextRow();
aOutput.nextRow();
@@ -192,7 +192,7 @@ ScRange ScRegressionDialog::ApplyOutput(ScDocShell* pDocShell)
nColumn += 1;
// REGRESSION MODEL
- aOutput.writeString(SC_RESSTR(constRegressionModel[nRegressionIndex]));
+ aOutput.writeString(ScResId(constRegressionModel[nRegressionIndex]));
aOutput.nextRow();
// RSQUARED
diff --git a/sc/source/ui/StatisticsDialogs/SamplingDialog.cxx b/sc/source/ui/StatisticsDialogs/SamplingDialog.cxx
index dd31179d3bcf..7f683556bb65 100644
--- a/sc/source/ui/StatisticsDialogs/SamplingDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/SamplingDialog.cxx
@@ -265,7 +265,7 @@ ScRange ScSamplingDialog::PerformRandomSampling(ScDocShell* pDocShell)
void ScSamplingDialog::PerformSampling()
{
- OUString aUndo(SC_RESSTR(STR_SAMPLING_UNDO_NAME));
+ OUString aUndo(ScResId(STR_SAMPLING_UNDO_NAME));
ScDocShell* pDocShell = mViewData->GetDocShell();
svl::IUndoManager* pUndoManager = pDocShell->GetUndoManager();
diff --git a/sc/source/ui/StatisticsDialogs/StatisticsInputOutputDialog.cxx b/sc/source/ui/StatisticsDialogs/StatisticsInputOutputDialog.cxx
index 5d6025ac7449..ef60c05147e2 100644
--- a/sc/source/ui/StatisticsDialogs/StatisticsInputOutputDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/StatisticsInputOutputDialog.cxx
@@ -283,7 +283,7 @@ IMPL_LINK_NOARG( ScStatisticsInputOutputDialog, RefInputModifyHandler, Edit&, vo
void ScStatisticsInputOutputDialog::CalculateInputAndWriteToOutput()
{
- OUString aUndo(SC_RESSTR(GetUndoNameId()));
+ OUString aUndo(ScResId(GetUndoNameId()));
ScDocShell* pDocShell = mViewData->GetDocShell();
svl::IUndoManager* pUndoManager = pDocShell->GetUndoManager();
pUndoManager->EnterListAction( aUndo, aUndo, 0, mViewData->GetViewShell()->GetViewShellId() );
diff --git a/sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx b/sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx
index 90dcea171573..c66d7173ac84 100644
--- a/sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx
@@ -322,7 +322,7 @@ IMPL_LINK_NOARG( ScStatisticsTwoVariableDialog, RefInputModifyHandler, Edit&, vo
void ScStatisticsTwoVariableDialog::CalculateInputAndWriteToOutput()
{
- OUString aUndo(SC_RESSTR(GetUndoNameId()));
+ OUString aUndo(ScResId(GetUndoNameId()));
ScDocShell* pDocShell = mViewData->GetDocShell();
svl::IUndoManager* pUndoManager = pDocShell->GetUndoManager();
pUndoManager->EnterListAction( aUndo, aUndo, 0, mViewData->GetViewShell()->GetViewShellId() );
diff --git a/sc/source/ui/StatisticsDialogs/TTestDialog.cxx b/sc/source/ui/StatisticsDialogs/TTestDialog.cxx
index 8509f72d6226..a94c82943dd6 100644
--- a/sc/source/ui/StatisticsDialogs/TTestDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/TTestDialog.cxx
@@ -32,7 +32,7 @@ ScTTestDialog::ScTTestDialog(
pSfxBindings, pChildWindow, pParent, pViewData,
"TTestDialog", "modules/scalc/ui/ttestdialog.ui" )
{
- SetText(SC_RESSTR(STR_TTEST));
+ SetText(ScResId(STR_TTEST));
}
ScTTestDialog::~ScTTestDialog()
@@ -69,30 +69,30 @@ ScRange ScTTestDialog::ApplyOutput(ScDocShell* pDocShell)
aTemplate.autoReplaceRange("%VARIABLE1_RANGE%", pVariable1Iterator->get());
aTemplate.autoReplaceRange("%VARIABLE2_RANGE%", pVariable2Iterator->get());
- aOutput.writeBoldString(SC_RESSTR(STR_TTEST_UNDO_NAME));
+ aOutput.writeBoldString(ScResId(STR_TTEST_UNDO_NAME));
aOutput.newLine();
// Alpha
- aOutput.writeString(SC_RESSTR(STR_LABEL_ALPHA));
+ aOutput.writeString(ScResId(STR_LABEL_ALPHA));
aOutput.nextColumn();
aOutput.writeValue(0.05);
aTemplate.autoReplaceAddress("%ALPHA%", aOutput.current());
aOutput.newLine();
// Hypothesized mean difference
- aOutput.writeString(SC_RESSTR(STR_HYPOTHESIZED_MEAN_DIFFERENCE_LABEL));
+ aOutput.writeString(ScResId(STR_HYPOTHESIZED_MEAN_DIFFERENCE_LABEL));
aOutput.nextColumn();
aOutput.writeValue(0);
aTemplate.autoReplaceAddress("%HYPOTHESIZED_MEAN_DIFFERENCE%", aOutput.current());
aOutput.newLine();
aOutput.nextColumn();
- aOutput.writeBoldString(SC_RESSTR(STR_VARIABLE_1_LABEL));
+ aOutput.writeBoldString(ScResId(STR_VARIABLE_1_LABEL));
aOutput.nextColumn();
- aOutput.writeBoldString(SC_RESSTR(STR_VARIABLE_2_LABEL));
+ aOutput.writeBoldString(ScResId(STR_VARIABLE_2_LABEL));
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STRID_CALC_MEAN));
+ aOutput.writeString(ScResId(STRID_CALC_MEAN));
aOutput.nextColumn();
aTemplate.setTemplate("=AVERAGE(%VARIABLE1_RANGE%)");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -101,7 +101,7 @@ ScRange ScTTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
- aOutput.writeString(SC_RESSTR(STRID_CALC_VARIANCE));
+ aOutput.writeString(ScResId(STRID_CALC_VARIANCE));
aOutput.nextColumn();
aTemplate.setTemplate("=VAR(%VARIABLE1_RANGE%)");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -111,7 +111,7 @@ ScRange ScTTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// Observations
- aOutput.writeString(SC_RESSTR(STR_OBSERVATIONS_LABEL));
+ aOutput.writeString(ScResId(STR_OBSERVATIONS_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=COUNT(%VARIABLE1_RANGE%)");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -121,14 +121,14 @@ ScRange ScTTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// Pearson Correlation
- aOutput.writeString(SC_RESSTR(STR_TTEST_PEARSON_CORRELATION));
+ aOutput.writeString(ScResId(STR_TTEST_PEARSON_CORRELATION));
aOutput.nextColumn();
aTemplate.setTemplate("=CORREL(%VARIABLE1_RANGE%;%VARIABLE2_RANGE%)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
// Observed mean difference
- aOutput.writeString(SC_RESSTR(STR_OBSERVED_MEAN_DIFFERENCE_LABEL));
+ aOutput.writeString(ScResId(STR_OBSERVED_MEAN_DIFFERENCE_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=AVERAGE(IF(ISODD(IF(ISNUMBER(%VARIABLE1_RANGE%); 1; 0) * IF(ISNUMBER(%VARIABLE2_RANGE%); 1; 0)); %VARIABLE1_RANGE% - %VARIABLE2_RANGE%; \"NA\"))");
aOutput.writeMatrixFormula(aTemplate.getTemplate());
@@ -136,7 +136,7 @@ ScRange ScTTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// Variance of the Differences
- aOutput.writeString(SC_RESSTR(STR_TTEST_VARIANCE_OF_THE_DIFFERENCES));
+ aOutput.writeString(ScResId(STR_TTEST_VARIANCE_OF_THE_DIFFERENCES));
aOutput.nextColumn();
aTemplate.setTemplate("=VAR(IF(ISODD(IF(ISNUMBER(%VARIABLE1_RANGE%); 1; 0) * IF(ISNUMBER(%VARIABLE2_RANGE%); 1; 0)); %VARIABLE1_RANGE% - %VARIABLE2_RANGE%; \"NA\"))");
aOutput.writeMatrixFormula(aTemplate.getTemplate());
@@ -144,7 +144,7 @@ ScRange ScTTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// df
- aOutput.writeString(SC_RESSTR(STR_ANOVA_LABEL_DF));
+ aOutput.writeString(ScResId(STR_ANOVA_LABEL_DF));
aOutput.nextColumn();
aTemplate.setTemplate("=SUM(IF(ISNUMBER(%VARIABLE1_RANGE%); 1; 0) * IF(ISNUMBER(%VARIABLE2_RANGE%); 1; 0)) - 1");
aOutput.writeMatrixFormula(aTemplate.getTemplate());
@@ -152,7 +152,7 @@ ScRange ScTTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// t stat
- aOutput.writeString(SC_RESSTR(STR_TTEST_T_STAT));
+ aOutput.writeString(ScResId(STR_TTEST_T_STAT));
aOutput.nextColumn();
aTemplate.setTemplate("=(%OBSERVED_MEAN_DIFFERENCE% - %HYPOTHESIZED_MEAN_DIFFERENCE%) / (%VARIANCE_OF_DIFFERENCES% / ( %DEGREE_OF_FREEDOM% + 1)) ^ 0.5");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -160,28 +160,28 @@ ScRange ScTTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// P one-tail
- aOutput.writeString(SC_RESSTR(STR_TTEST_P_ONE_TAIL));
+ aOutput.writeString(ScResId(STR_TTEST_P_ONE_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=TDIST(ABS(%T_STAT%); %DEGREE_OF_FREEDOM%; 1)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
// T critical one-tail
- aOutput.writeString(SC_RESSTR(STR_TTEST_T_CRITICAL_ONE_TAIL));
+ aOutput.writeString(ScResId(STR_TTEST_T_CRITICAL_ONE_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=TINV(2*%ALPHA%; %DEGREE_OF_FREEDOM%)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
// P two-tail
- aOutput.writeString(SC_RESSTR(STR_TTEST_P_TWO_TAIL));
+ aOutput.writeString(ScResId(STR_TTEST_P_TWO_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=TDIST(ABS(%T_STAT%); %DEGREE_OF_FREEDOM%; 2)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
// T critical two-tail
- aOutput.writeString(SC_RESSTR(STR_TTEST_T_CRITICAL_TWO_TAIL));
+ aOutput.writeString(ScResId(STR_TTEST_T_CRITICAL_TWO_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=TINV(%ALPHA%; %DEGREE_OF_FREEDOM%)");
aOutput.writeFormula(aTemplate.getTemplate());
diff --git a/sc/source/ui/StatisticsDialogs/ZTestDialog.cxx b/sc/source/ui/StatisticsDialogs/ZTestDialog.cxx
index 91460d3778c7..b7a3f67ebd71 100644
--- a/sc/source/ui/StatisticsDialogs/ZTestDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/ZTestDialog.cxx
@@ -32,7 +32,7 @@ ScZTestDialog::ScZTestDialog(
pSfxBindings, pChildWindow, pParent, pViewData,
"ZTestDialog", "modules/scalc/ui/ztestdialog.ui" )
{
- SetText(SC_RESSTR(STR_ZTEST));
+ SetText(ScResId(STR_ZTEST));
}
ScZTestDialog::~ScZTestDialog()
@@ -69,18 +69,18 @@ ScRange ScZTestDialog::ApplyOutput(ScDocShell* pDocShell)
aTemplate.autoReplaceRange("%VARIABLE1_RANGE%", pVariable1Iterator->get());
aTemplate.autoReplaceRange("%VARIABLE2_RANGE%", pVariable2Iterator->get());
- aOutput.writeBoldString(SC_RESSTR(STR_ZTEST));
+ aOutput.writeBoldString(ScResId(STR_ZTEST));
aOutput.newLine();
// Alpha
- aOutput.writeString(SC_RESSTR(STR_LABEL_ALPHA));
+ aOutput.writeString(ScResId(STR_LABEL_ALPHA));
aOutput.nextColumn();
aOutput.writeValue(0.05);
aTemplate.autoReplaceAddress("%ALPHA%", aOutput.current());
aOutput.newLine();
// Hypothesized mean difference
- aOutput.writeString(SC_RESSTR(STR_HYPOTHESIZED_MEAN_DIFFERENCE_LABEL));
+ aOutput.writeString(ScResId(STR_HYPOTHESIZED_MEAN_DIFFERENCE_LABEL));
aOutput.nextColumn();
aOutput.writeValue(0);
aTemplate.autoReplaceAddress("%HYPOTHESIZED_MEAN_DIFFERENCE%", aOutput.current());
@@ -88,13 +88,13 @@ ScRange ScZTestDialog::ApplyOutput(ScDocShell* pDocShell)
// Variable Label
aOutput.nextColumn();
- aOutput.writeBoldString(SC_RESSTR(STR_VARIABLE_1_LABEL));
+ aOutput.writeBoldString(ScResId(STR_VARIABLE_1_LABEL));
aOutput.nextColumn();
- aOutput.writeBoldString(SC_RESSTR(STR_VARIABLE_2_LABEL));
+ aOutput.writeBoldString(ScResId(STR_VARIABLE_2_LABEL));
aOutput.newLine();
// Known Variance
- aOutput.writeString(SC_RESSTR(STR_ZTEST_KNOWN_VARIANCE));
+ aOutput.writeString(ScResId(STR_ZTEST_KNOWN_VARIANCE));
aOutput.nextColumn();
aOutput.writeValue(0);
aTemplate.autoReplaceAddress("%KNOWN_VARIANCE_VARIABLE1%", aOutput.current());
@@ -104,7 +104,7 @@ ScRange ScZTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// Mean
- aOutput.writeString(SC_RESSTR(STRID_CALC_MEAN));
+ aOutput.writeString(ScResId(STRID_CALC_MEAN));
aOutput.nextColumn();
aTemplate.setTemplate("=AVERAGE(%VARIABLE1_RANGE%)");
aTemplate.autoReplaceAddress("%MEAN_VARIABLE1%", aOutput.current());
@@ -116,7 +116,7 @@ ScRange ScZTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// Observations
- aOutput.writeString(SC_RESSTR(STR_OBSERVATIONS_LABEL));
+ aOutput.writeString(ScResId(STR_OBSERVATIONS_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=COUNT(%VARIABLE1_RANGE%)");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -128,7 +128,7 @@ ScRange ScZTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// Observed mean difference
- aOutput.writeString(SC_RESSTR(STR_OBSERVED_MEAN_DIFFERENCE_LABEL));
+ aOutput.writeString(ScResId(STR_OBSERVED_MEAN_DIFFERENCE_LABEL));
aOutput.nextColumn();
aTemplate.setTemplate("=%MEAN_VARIABLE1% - %MEAN_VARIABLE2%");
aOutput.writeMatrixFormula(aTemplate.getTemplate());
@@ -136,7 +136,7 @@ ScRange ScZTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// z
- aOutput.writeString(SC_RESSTR(STR_ZTEST_Z_VALUE));
+ aOutput.writeString(ScResId(STR_ZTEST_Z_VALUE));
aOutput.nextColumn();
aTemplate.setTemplate("=(%OBSERVED_MEAN_DIFFERENCE% - %HYPOTHESIZED_MEAN_DIFFERENCE%) / SQRT( %KNOWN_VARIANCE_VARIABLE1% / %OBSERVATION_VARIABLE1% + %KNOWN_VARIANCE_VARIABLE2% / %OBSERVATION_VARIABLE2% )");
aOutput.writeFormula(aTemplate.getTemplate());
@@ -144,28 +144,28 @@ ScRange ScZTestDialog::ApplyOutput(ScDocShell* pDocShell)
aOutput.newLine();
// P one-tail
- aOutput.writeString(SC_RESSTR(STR_ZTEST_P_ONE_TAIL));
+ aOutput.writeString(ScResId(STR_ZTEST_P_ONE_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=1 - NORMSDIST(ABS(%Z_STAT%))");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
// z critical one-tail
- aOutput.writeString(SC_RESSTR(STR_ZTEST_Z_CRITICAL_ONE_TAIL));
+ aOutput.writeString(ScResId(STR_ZTEST_Z_CRITICAL_ONE_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=-NORMSINV(%ALPHA%)");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
// P two-tail
- aOutput.writeString(SC_RESSTR(STR_ZTEST_P_TWO_TAIL));
+ aOutput.writeString(ScResId(STR_ZTEST_P_TWO_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=2 * NORMSDIST(-ABS(%Z_STAT%))");
aOutput.writeFormula(aTemplate.getTemplate());
aOutput.newLine();
// z critical two-tail
- aOutput.writeString(SC_RESSTR(STR_ZTEST_Z_CRITICAL_TWO_TAIL));
+ aOutput.writeString(ScResId(STR_ZTEST_Z_CRITICAL_TWO_TAIL));
aOutput.nextColumn();
aTemplate.setTemplate("=-NORMSINV(%ALPHA%/2)");
aOutput.writeFormula(aTemplate.getTemplate());
diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx
index 15dd433c418a..70957b3aa601 100644
--- a/sc/source/ui/app/inputwin.cxx
+++ b/sc/source/ui/app/inputwin.cxx
@@ -1721,8 +1721,8 @@ void ScTextWnd::ImplInitSettings()
css::uno::Reference< css::accessibility::XAccessible > ScTextWnd::CreateAccessible()
{
return new ScAccessibleEditObject(GetAccessibleParentWindow()->GetAccessible(), nullptr, this,
- OUString(ScResId(STR_ACC_EDITLINE_NAME)),
- OUString(ScResId(STR_ACC_EDITLINE_DESCR)), ScAccessibleEditObject::EditLine);
+ ScResId(STR_ACC_EDITLINE_NAME),
+ ScResId(STR_ACC_EDITLINE_DESCR), ScAccessibleEditObject::EditLine);
}
void ScTextWnd::InsertAccessibleTextData( ScAccessibleEditLineTextData& rTextData )
diff --git a/sc/source/ui/app/scdll.cxx b/sc/source/ui/app/scdll.cxx
index 18ec897177fa..d75a481b1a3d 100644
--- a/sc/source/ui/app/scdll.cxx
+++ b/sc/source/ui/app/scdll.cxx
@@ -106,9 +106,9 @@
#include <o3tl/make_unique.hxx>
#include "scabstdlg.hxx"
-ScResId::ScResId( sal_uInt16 nId ) :
- ResId( nId, *SC_MOD()->GetResMgr() )
+OUString ScResId(sal_uInt16 nId)
{
+ return ResId(nId, *SC_MOD()->GetResMgr());
}
void ScDLL::Init()
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx
index 5778f38725ff..863f328c28e7 100644
--- a/sc/source/ui/app/scmod.cxx
+++ b/sc/source/ui/app/scmod.cxx
@@ -2283,12 +2283,12 @@ SfxStyleFamilies* ScModule::CreateStyleFamilies()
pStyleFamilies->emplace_back(SfxStyleFamilyItem(SfxStyleFamily::Para,
ScGlobal::GetRscString(STR_STYLE_FAMILY_CELL),
Image(BitmapEx(BMP_STYLES_FAMILY_CELL)),
- ScResId(RID_CELLSTYLEFAMILY)));
+ ResId(RID_CELLSTYLEFAMILY, *SC_MOD()->GetResMgr())));
pStyleFamilies->emplace_back(SfxStyleFamilyItem(SfxStyleFamily::Page,
ScGlobal::GetRscString(STR_STYLE_FAMILY_PAGE),
Image(BitmapEx(BMP_STYLES_FAMILY_PAGE)),
- ScResId(RID_PAGESTYLEFAMILY)));
+ ResId(RID_PAGESTYLEFAMILY, *SC_MOD()->GetResMgr())));
return pStyleFamilies;
}
diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx
index 347021ca3757..d3ed848145da 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -1082,7 +1082,7 @@ void ScCheckListMenuWindow::packWindow()
maEdSearch->SetPosSizePixel(aPos, aSize);
maEdSearch->SetFont(getLabelFont());
maEdSearch->SetControlBackground(rStyle.GetFieldColor());
- maEdSearch->SetPlaceholderText(SC_RESSTR(STR_EDIT_SEARCH_ITEMS));
+ maEdSearch->SetPlaceholderText(ScResId(STR_EDIT_SEARCH_ITEMS));
maEdSearch->SetModifyHdl( LINK(this, ScCheckListMenuWindow, EdModifyHdl) );
maEdSearch->Show();
@@ -1095,7 +1095,7 @@ void ScCheckListMenuWindow::packWindow()
getSectionPosSize(aPos, aSize, CHECK_TOGGLE_ALL);
maChkToggleAll->SetPosSizePixel(aPos, aSize);
maChkToggleAll->SetFont(getLabelFont());
- maChkToggleAll->SetText(SC_RESSTR(STR_BTN_TOGGLE_ALL));
+ maChkToggleAll->SetText(ScResId(STR_BTN_TOGGLE_ALL));
maChkToggleAll->SetTextColor(rStyle.GetMenuTextColor());
maChkToggleAll->SetControlBackground(rStyle.GetMenuColor());
maChkToggleAll->SetClickHdl( LINK(this, ScCheckListMenuWindow, TriStateHdl) );
@@ -1110,7 +1110,7 @@ void ScCheckListMenuWindow::packWindow()
getSectionPosSize(aPos, aSize, BTN_SINGLE_SELECT);
maBtnSelectSingle->SetPosSizePixel(aPos, aSize);
- maBtnSelectSingle->SetQuickHelpText(SC_RESSTR(STR_BTN_SELECT_CURRENT));
+ maBtnSelectSingle->SetQuickHelpText(ScResId(STR_BTN_SELECT_CURRENT));
maBtnSelectSingle->SetModeImage(aSingleSelect);
maBtnSelectSingle->SetClickHdl( LINK(this, ScCheckListMenuWindow, ButtonHdl) );
maBtnSelectSingle->Show();
@@ -1122,7 +1122,7 @@ void ScCheckListMenuWindow::packWindow()
getSectionPosSize(aPos, aSize, BTN_SINGLE_UNSELECT);
maBtnUnselectSingle->SetPosSizePixel(aPos, aSize);
- maBtnUnselectSingle->SetQuickHelpText(SC_RESSTR(STR_BTN_UNSELECT_CURRENT));
+ maBtnUnselectSingle->SetQuickHelpText(ScResId(STR_BTN_UNSELECT_CURRENT));
maBtnUnselectSingle->SetModeImage(aSingleUnselect);
maBtnUnselectSingle->SetClickHdl( LINK(this, ScCheckListMenuWindow, ButtonHdl) );
maBtnUnselectSingle->Show();
diff --git a/sc/source/ui/condformat/condformatdlgentry.cxx b/sc/source/ui/condformat/condformatdlgentry.cxx
index 241838ef171d..d52452b6391c 100644
--- a/sc/source/ui/condformat/condformatdlgentry.cxx
+++ b/sc/source/ui/condformat/condformatdlgentry.cxx
@@ -42,7 +42,7 @@ ScCondFrmtEntry::ScCondFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, const S
: VclContainer(pParent, WB_CLIPCHILDREN | WB_BORDER)
, mbActive(false)
, mnIndex(0)
- , maStrCondition(ScResId(SCSTR_CONDITION).toString())
+ , maStrCondition(ScResId(SCSTR_CONDITION))
, mpDoc(pDoc)
, maPos(rPos)
{
diff --git a/sc/source/ui/dbgui/filtdlg.cxx b/sc/source/ui/dbgui/filtdlg.cxx
index 69dfa163c1b6..6ce9b10bed84 100644
--- a/sc/source/ui/dbgui/filtdlg.cxx
+++ b/sc/source/ui/dbgui/filtdlg.cxx
@@ -52,11 +52,11 @@ ScFilterDlg::ScFilterDlg(SfxBindings* pB, SfxChildWindow* pCW, vcl::Window* pPar
const SfxItemSet& rArgSet)
: ScAnyRefDlg ( pB, pCW, pParent, "StandardFilterDialog",
"modules/scalc/ui/standardfilterdialog.ui" )
- , aStrUndefined(SC_RESSTR(SCSTR_UNDEFINED))
- , aStrNone(SC_RESSTR(SCSTR_NONE))
- , aStrEmpty(SC_RESSTR(SCSTR_FILTER_EMPTY))
- , aStrNotEmpty(SC_RESSTR(SCSTR_FILTER_NOTEMPTY))
- , aStrColumn(SC_RESSTR(SCSTR_COLUMN))
+ , aStrUndefined(ScResId(SCSTR_UNDEFINED))
+ , aStrNone(ScResId(SCSTR_NONE))
+ , aStrEmpty(ScResId(SCSTR_FILTER_EMPTY))
+ , aStrNotEmpty(ScResId(SCSTR_FILTER_NOTEMPTY))
+ , aStrColumn(ScResId(SCSTR_COLUMN))
, pOptionsMgr(nullptr)
, nWhichQuery(rArgSet.GetPool()->GetWhich(SID_QUERY))
, theQueryData(static_cast<const ScQueryItem&>(rArgSet.Get(nWhichQuery)).GetQueryData())
diff --git a/sc/source/ui/dbgui/pfiltdlg.cxx b/sc/source/ui/dbgui/pfiltdlg.cxx
index e0f0e9ec3b06..209b7ceed17f 100644
--- a/sc/source/ui/dbgui/pfiltdlg.cxx
+++ b/sc/source/ui/dbgui/pfiltdlg.cxx
@@ -44,10 +44,10 @@ ScPivotFilterDlg::ScPivotFilterDlg(vcl::Window* pParent, const SfxItemSet& rArgS
"modules/scalc/ui/pivotfilterdialog.ui" )
,
- aStrNone ( SC_RESSTR(SCSTR_NONE) ),
- aStrEmpty ( SC_RESSTR(SCSTR_FILTER_EMPTY) ),
- aStrNotEmpty ( SC_RESSTR(SCSTR_FILTER_NOTEMPTY) ),
- aStrColumn ( SC_RESSTR(SCSTR_COLUMN) ),
+ aStrNone ( ScResId(SCSTR_NONE) ),
+ aStrEmpty ( ScResId(SCSTR_FILTER_EMPTY) ),
+ aStrNotEmpty ( ScResId(SCSTR_FILTER_NOTEMPTY) ),
+ aStrColumn ( ScResId(SCSTR_COLUMN) ),
nWhichQuery ( rArgSet.GetPool()->GetWhich( SID_QUERY ) ),
theQueryData ( static_cast<const ScQueryItem&>(
diff --git a/sc/source/ui/dbgui/pvfundlg.cxx b/sc/source/ui/dbgui/pvfundlg.cxx
index 7bf29db6c805..042ddc4907d3 100644
--- a/sc/source/ui/dbgui/pvfundlg.cxx
+++ b/sc/source/ui/dbgui/pvfundlg.cxx
@@ -35,6 +35,7 @@
#include "dpobject.hxx"
#include "dpsave.hxx"
#include "scres.hrc"
+#include "scmod.hxx"
#include "globstr.hrc"
#include "dputil.hxx"
@@ -180,7 +181,7 @@ void ScDPFunctionListBox::FillFunctionNames()
{
OSL_ENSURE( !GetEntryCount(), "ScDPMultiFuncListBox::FillFunctionNames - do not add texts to resource" );
Clear();
- ResStringArray aArr( ScResId( SCSTR_DPFUNCLISTBOX ) );
+ ResStringArray aArr(ResId(SCSTR_DPFUNCLISTBOX, *SC_MOD()->GetResMgr()));
for( sal_uInt16 nIndex = 0, nCount = sal::static_int_cast<sal_uInt16>(aArr.Count()); nIndex < nCount; ++nIndex )
InsertEntry( aArr.GetString( nIndex ) );
assert(GetEntryCount() == SAL_N_ELEMENTS(spnFunctions));
diff --git a/sc/source/ui/dbgui/scuiimoptdlg.cxx b/sc/source/ui/dbgui/scuiimoptdlg.cxx
index dbd9132c6a59..cb45ed52b803 100644
--- a/sc/source/ui/dbgui/scuiimoptdlg.cxx
+++ b/sc/source/ui/dbgui/scuiimoptdlg.cxx
@@ -135,8 +135,8 @@ ScImportOptionsDlg::ScImportOptionsDlg(
get(m_pBtnOk, "ok");
OUString sFieldSep(SCSTR_FIELDSEP);
- sFieldSep = sFieldSep.replaceFirst( "%TAB", SC_RESSTR(SCSTR_FIELDSEP_TAB) );
- sFieldSep = sFieldSep.replaceFirst( "%SPACE", SC_RESSTR(SCSTR_FIELDSEP_SPACE) );
+ sFieldSep = sFieldSep.replaceFirst( "%TAB", ScResId(SCSTR_FIELDSEP_TAB) );
+ sFieldSep = sFieldSep.replaceFirst( "%SPACE", ScResId(SCSTR_FIELDSEP_SPACE) );
// not possible in the Ctor initializer (MSC cannot do that):
pFieldSepTab = new ScDelimiterTable(sFieldSep);
diff --git a/sc/source/ui/dbgui/sfiltdlg.cxx b/sc/source/ui/dbgui/sfiltdlg.cxx
index be4c9a06cd91..59a7caceb59c 100644
--- a/sc/source/ui/dbgui/sfiltdlg.cxx
+++ b/sc/source/ui/dbgui/sfiltdlg.cxx
@@ -47,7 +47,7 @@ ScSpecialFilterDlg::ScSpecialFilterDlg( SfxBindings* pB, SfxChildWindow* pCW, vc
: ScAnyRefDlg ( pB, pCW, pParent, "AdvancedFilterDialog", "modules/scalc/ui/advancedfilterdialog.ui" ),
- aStrUndefined ( SC_RESSTR(SCSTR_UNDEFINED) ),
+ aStrUndefined ( ScResId(SCSTR_UNDEFINED) ),
pOptionsMgr ( nullptr ),
nWhichQuery ( rArgSet.GetPool()->GetWhich( SID_QUERY ) ),
theQueryData ( static_cast<const ScQueryItem&>(
diff --git a/sc/source/ui/dbgui/tpsort.cxx b/sc/source/ui/dbgui/tpsort.cxx
index 78bfa428a6b1..3ee1093e18a3 100644
--- a/sc/source/ui/dbgui/tpsort.cxx
+++ b/sc/source/ui/dbgui/tpsort.cxx
@@ -73,9 +73,9 @@ ScTabPageSortFields::ScTabPageSortFields(vcl::Window* pParent,
"modules/scalc/ui/sortcriteriapage.ui", &rArgSet)
,
- aStrUndefined ( SC_RESSTR( SCSTR_UNDEFINED ) ),
- aStrColumn ( SC_RESSTR( SCSTR_COLUMN ) ),
- aStrRow ( SC_RESSTR( SCSTR_ROW ) ),
+ aStrUndefined ( ScResId( SCSTR_UNDEFINED ) ),
+ aStrColumn ( ScResId( SCSTR_COLUMN ) ),
+ aStrRow ( ScResId( SCSTR_ROW ) ),
nWhichSort ( rArgSet.GetPool()->GetWhich( SID_SORT ) ),
pDlg ( static_cast<ScSortDlg*>(GetParentDialog()) ),
@@ -488,9 +488,9 @@ ScTabPageSortOptions::ScTabPageSortOptions( vcl::Window* pParent,
const SfxItemSet& rArgSet )
: SfxTabPage(pParent, "SortOptionsPage",
"modules/scalc/ui/sortoptionspage.ui", &rArgSet)
- , aStrRowLabel(SC_RESSTR(SCSTR_ROW_LABEL))
- , aStrColLabel(SC_RESSTR(SCSTR_COL_LABEL))
- , aStrUndefined(SC_RESSTR(SCSTR_UNDEFINED))
+ , aStrRowLabel(ScResId(SCSTR_ROW_LABEL))
+ , aStrColLabel(ScResId(SCSTR_COL_LABEL))
+ , aStrUndefined(ScResId(SCSTR_UNDEFINED))
, nWhichSort(rArgSet.GetPool()->GetWhich(SID_SORT))
, aSortData(static_cast<const ScSortItem&>(rArgSet.Get(nWhichSort)).GetSortData())
, pViewData(nullptr)
diff --git a/sc/source/ui/dbgui/tpsubt.cxx b/sc/source/ui/dbgui/tpsubt.cxx
index 5771d16e4d13..0d3b1e1747b9 100644
--- a/sc/source/ui/dbgui/tpsubt.cxx
+++ b/sc/source/ui/dbgui/tpsubt.cxx
@@ -39,8 +39,8 @@ ScTpSubTotalGroup::ScTpSubTotalGroup( vcl::Window* pParent,
: SfxTabPage ( pParent,
"SubTotalGrpPage", "modules/scalc/ui/subtotalgrppage.ui",
&rArgSet ),
- aStrNone ( SC_RESSTR( SCSTR_NONE ) ),
- aStrColumn ( SC_RESSTR( SCSTR_COLUMN ) ),
+ aStrNone ( ScResId( SCSTR_NONE ) ),
+ aStrColumn ( ScResId( SCSTR_COLUMN ) ),
pViewData ( nullptr ),
pDoc ( nullptr ),
nWhichSubTotals ( rArgSet.GetPool()->GetWhich( SID_SUBTOTALS ) ),
diff --git a/sc/source/ui/dialogs/searchresults.cxx b/sc/source/ui/dialogs/searchresults.cxx
index 4f8e65a71b75..d0f343035a72 100644
--- a/sc/source/ui/dialogs/searchresults.cxx
+++ b/sc/source/ui/dialogs/searchresults.cxx
@@ -37,7 +37,7 @@ SearchResultsDlg::SearchResultsDlg( SfxBindings* _pBindings, vcl::Window* pParen
mpList = VclPtr<SvSimpleTable>::Create(*pContainer);
long nTabs[] = {3, 0, 40, 60};
mpList->SetTabs(&nTabs[0]);
- mpList->InsertHeaderEntry(SC_RESSTR(STR_SHEET) + "\t" + SC_RESSTR(STR_CELL) + "\t" + SC_RESSTR(STR_CONTENT));
+ mpList->InsertHeaderEntry(ScResId(STR_SHEET) + "\t" + ScResId(STR_CELL) + "\t" + ScResId(STR_CONTENT));
mpList->SetSelectHdl( LINK(this, SearchResultsDlg, ListSelectHdl) );
}
diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx
index c1097630d48b..77db8cd073f4 100644
--- a/sc/source/ui/docshell/docsh.cxx
+++ b/sc/source/ui/docshell/docsh.cxx
@@ -194,7 +194,7 @@ void ScDocShell::FillClass( SvGlobalName* pClassName,
*pClassName = SvGlobalName( SO3_SC_CLASSID_60 );
*pFormat = bTemplate ? SotClipboardFormatId::STARCALC_8_TEMPLATE : SotClipboardFormatId::STARCALC_8;
*pFullTypeName = "calc8";
- *pShortTypeName = ScResId(SCSTR_SHORT_SCDOC_NAME).toString();
+ *pShortTypeName = ScResId(SCSTR_SHORT_SCDOC_NAME);
}
else
{
diff --git a/sc/source/ui/docshell/documentlinkmgr.cxx b/sc/source/ui/docshell/documentlinkmgr.cxx
index 71b7fba56d3b..cdabc4674044 100644
--- a/sc/source/ui/docshell/documentlinkmgr.cxx
+++ b/sc/source/ui/docshell/documentlinkmgr.cxx
@@ -177,7 +177,7 @@ bool DocumentLinkManager::updateDdeOrOleLinks( vcl::Window* pWin )
OUString aType = pDdeLink->GetAppl();
OUStringBuffer aBuf;
- aBuf.append(OUString(ScResId(SCSTR_DDEDOC_NOT_LOADED)));
+ aBuf.append(ScResId(SCSTR_DDEDOC_NOT_LOADED));
aBuf.append("\n\n");
aBuf.append("Source : ");
aBuf.append(aFile);
diff --git a/sc/source/ui/drawfunc/fuconrec.cxx b/sc/source/ui/drawfunc/fuconrec.cxx
index d9e476260573..3e0742bc5c6f 100644
--- a/sc/source/ui/drawfunc/fuconrec.cxx
+++ b/sc/source/ui/drawfunc/fuconrec.cxx
@@ -64,7 +64,7 @@ namespace {
if( pLineEndList.is() )
{
- OUString aArrowName( SVX_RES(nResId) );
+ OUString aArrowName( SvxResId(nResId) );
long nCount = pLineEndList->Count();
long nIndex;
for( nIndex = 0L; nIndex < nCount; nIndex++ )
@@ -279,9 +279,9 @@ void FuConstRectangle::SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj, sal_uInt1
case SID_LINE_ARROWS:
{
// connector with arrow ends
- rAttr.Put(XLineStartItem(SVX_RESSTR(RID_SVXSTR_ARROW), aArrow));
+ rAttr.Put(XLineStartItem(SvxResId(RID_SVXSTR_ARROW), aArrow));
rAttr.Put(XLineStartWidthItem(nWidth));
- rAttr.Put(XLineEndItem(SVX_RESSTR(RID_SVXSTR_ARROW), aArrow));
+ rAttr.Put(XLineEndItem(SvxResId(RID_SVXSTR_ARROW), aArrow));
rAttr.Put(XLineEndWidthItem(nWidth));
}
break;
@@ -291,7 +291,7 @@ void FuConstRectangle::SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj, sal_uInt1
case SID_LINE_ARROW_SQUARE:
{
// connector with arrow start
- rAttr.Put(XLineStartItem(SVX_RESSTR(RID_SVXSTR_ARROW), aArrow));
+ rAttr.Put(XLineStartItem(SvxResId(RID_SVXSTR_ARROW), aArrow));
rAttr.Put(XLineStartWidthItem(nWidth));
}
break;
@@ -301,7 +301,7 @@ void FuConstRectangle::SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj, sal_uInt1
case SID_LINE_SQUARE_ARROW:
{
// connector with arrow end
- rAttr.Put(XLineEndItem(SVX_RESSTR(RID_SVXSTR_ARROW), aArrow));
+ rAttr.Put(XLineEndItem(SvxResId(RID_SVXSTR_ARROW), aArrow));
rAttr.Put(XLineEndWidthItem(nWidth));
}
break;
@@ -313,7 +313,7 @@ void FuConstRectangle::SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj, sal_uInt1
case SID_LINE_ARROW_CIRCLE:
{
// circle end
- rAttr.Put(XLineEndItem(SVX_RESSTR(RID_SVXSTR_CIRCLE), aCircle));
+ rAttr.Put(XLineEndItem(SvxResId(RID_SVXSTR_CIRCLE), aCircle));
rAttr.Put(XLineEndWidthItem(nWidth));
}
break;
@@ -321,7 +321,7 @@ void FuConstRectangle::SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj, sal_uInt1
case SID_LINE_CIRCLE_ARROW:
{
// circle start
- rAttr.Put(XLineStartItem(SVX_RESSTR(RID_SVXSTR_CIRCLE), aCircle));
+ rAttr.Put(XLineStartItem(SvxResId(RID_SVXSTR_CIRCLE), aCircle));
rAttr.Put(XLineStartWidthItem(nWidth));
}
break;
@@ -329,7 +329,7 @@ void FuConstRectangle::SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj, sal_uInt1
case SID_LINE_ARROW_SQUARE:
{
// square end
- rAttr.Put(XLineEndItem(SVX_RESSTR(RID_SVXSTR_SQUARE), aSquare));
+ rAttr.Put(XLineEndItem(SvxResId(RID_SVXSTR_SQUARE), aSquare));
rAttr.Put(XLineEndWidthItem(nWidth));
}
break;
@@ -337,7 +337,7 @@ void FuConstRectangle::SetLineEnds(SfxItemSet& rAttr, SdrObject* pObj, sal_uInt1
case SID_LINE_SQUARE_ARROW:
{
// square start
- rAttr.Put(XLineStartItem(SVX_RESSTR(RID_SVXSTR_SQUARE), aSquare));
+ rAttr.Put(XLineStartItem(SvxResId(RID_SVXSTR_SQUARE), aSquare));
rAttr.Put(XLineStartWidthItem(nWidth));
}
break;
diff --git a/sc/source/ui/drawfunc/graphsh.cxx b/sc/source/ui/drawfunc/graphsh.cxx
index 7077711154fa..9c1dfe325e49 100644
--- a/sc/source/ui/drawfunc/graphsh.cxx
+++ b/sc/source/ui/drawfunc/graphsh.cxx
@@ -123,7 +123,7 @@ void ScGraphicShell::ExecuteFilter( SfxRequest& rReq )
if( pPageView )
{
SdrGrafObj* pFilteredObj = static_cast<SdrGrafObj*>(pObj->Clone());
- OUString aStr = pView->GetDescriptionOfMarkedObjects() + " " + OUString(ScResId( SCSTR_UNDO_GRAFFILTER ));
+ OUString aStr = pView->GetDescriptionOfMarkedObjects() + " " + ScResId(SCSTR_UNDO_GRAFFILTER);
pView->BegUndo( aStr );
pFilteredObj->SetGraphicObject( aFilterObj );
pView->ReplaceObjectAtView( pObj, *pPageView, pFilteredObj );
diff --git a/sc/source/ui/miscdlgs/acredlin.cxx b/sc/source/ui/miscdlgs/acredlin.cxx
index 996f0719c2d7..e7f2c3964722 100644
--- a/sc/source/ui/miscdlgs/acredlin.cxx
+++ b/sc/source/ui/miscdlgs/acredlin.cxx
@@ -81,22 +81,22 @@ ScAcceptChgDlg::ScAcceptChgDlg(SfxBindings* pB, SfxChildWindow* pCW, vcl::Window
m_xPopup(get_menu("calcmenu")),
pViewData ( ptrViewData ),
pDoc ( ptrViewData->GetDocument() ),
- aStrInsertCols (SC_RESSTR(STR_CHG_INSERT_COLS)),
- aStrInsertRows (SC_RESSTR(STR_CHG_INSERT_ROWS)),
- aStrInsertTabs (SC_RESSTR(STR_CHG_INSERT_TABS)),
- aStrDeleteCols (SC_RESSTR(STR_CHG_DELETE_COLS)),
- aStrDeleteRows (SC_RESSTR(STR_CHG_DELETE_ROWS)),
- aStrDeleteTabs (SC_RESSTR(STR_CHG_DELETE_TABS)),
- aStrMove (SC_RESSTR(STR_CHG_MOVE)),
- aStrContent (SC_RESSTR(STR_CHG_CONTENT)),
- aStrReject (SC_RESSTR(STR_CHG_REJECT)),
- aStrAllAccepted (SC_RESSTR(STR_CHG_ACCEPTED)),
- aStrAllRejected (SC_RESSTR(STR_CHG_REJECTED)),
- aStrNoEntry (SC_RESSTR(STR_CHG_NO_ENTRY)),
- aStrContentWithChild (SC_RESSTR(STR_CHG_CONTENT_WITH_CHILD)),
- aStrChildContent (SC_RESSTR(STR_CHG_CHILD_CONTENT)),
- aStrChildOrgContent (SC_RESSTR(STR_CHG_CHILD_ORGCONTENT)),
- aStrEmpty (SC_RESSTR(STR_CHG_EMPTY)),
+ aStrInsertCols (ScResId(STR_CHG_INSERT_COLS)),
+ aStrInsertRows (ScResId(STR_CHG_INSERT_ROWS)),
+ aStrInsertTabs (ScResId(STR_CHG_INSERT_TABS)),
+ aStrDeleteCols (ScResId(STR_CHG_DELETE_COLS)),
+ aStrDeleteRows (ScResId(STR_CHG_DELETE_ROWS)),
+ aStrDeleteTabs (ScResId(STR_CHG_DELETE_TABS)),
+ aStrMove (ScResId(STR_CHG_MOVE)),
+ aStrContent (ScResId(STR_CHG_CONTENT)),
+ aStrReject (ScResId(STR_CHG_REJECT)),
+ aStrAllAccepted (ScResId(STR_CHG_ACCEPTED)),
+ aStrAllRejected (ScResId(STR_CHG_REJECTED)),
+ aStrNoEntry (ScResId(STR_CHG_NO_ENTRY)),
+ aStrContentWithChild (ScResId(STR_CHG_CONTENT_WITH_CHILD)),
+ aStrChildContent (ScResId(STR_CHG_CHILD_CONTENT)),
+ aStrChildOrgContent (ScResId(STR_CHG_CHILD_ORGCONTENT)),
+ aStrEmpty (ScResId(STR_CHG_EMPTY)),
aUnknown("Unknown"),
bAcceptEnableFlag(true),
bRejectEnableFlag(true),
diff --git a/sc/source/ui/miscdlgs/filldlg.cxx b/sc/source/ui/miscdlgs/filldlg.cxx
index 66e47cc3629d..a984cb5a030f 100644
--- a/sc/source/ui/miscdlgs/filldlg.cxx
+++ b/sc/source/ui/miscdlgs/filldlg.cxx
@@ -42,7 +42,7 @@ ScFillSeriesDlg::ScFillSeriesDlg( vcl::Window* pParent,
sal_uInt16 nPossDir )
: ModalDialog(pParent, "FillSeriesDialog", "modules/scalc/ui/filldlg.ui"),
aStartStrVal ( aStartStr),
- aErrMsgInvalidVal( SC_RESSTR(SCSTR_VALERR) ),
+ aErrMsgInvalidVal( ScResId(SCSTR_VALERR) ),
rDoc ( rDocument ),
theFillDir ( eFillDir ),
theFillCmd ( eFillCmd ),
diff --git a/sc/source/ui/navipi/navipi.cxx b/sc/source/ui/navipi/navipi.cxx
index ca1e861c738e..9b2819281c02 100644
--- a/sc/source/ui/navipi/navipi.cxx
+++ b/sc/source/ui/navipi/navipi.cxx
@@ -500,9 +500,9 @@ ScNavigatorDlg::ScNavigatorDlg(SfxBindings* pB, vcl::Window* pParent)
aTbxCmd->SetLineCount(2);
aLbDocuments->SetDropDownLineCount(9);
aLbDocuments->SetSelectHdl(LINK(this, ScNavigatorDlg, DocumentSelectHdl));
- aStrActive = " (" + OUString(ScResId(SCSTR_ACTIVE)) + ")"; // " (active)"
- aStrNotActive = " (" + OUString(ScResId(SCSTR_NOTACTIVE)) + ")"; // " (not active)"
- aStrHidden = " (" + OUString(ScResId(SCSTR_HIDDEN)) + ")"; // " (hidden)"
+ aStrActive = " (" + ScResId(SCSTR_ACTIVE) + ")"; // " (active)"
+ aStrNotActive = " (" + ScResId(SCSTR_NOTACTIVE) + ")"; // " (not active)"
+ aStrHidden = " (" + ScResId(SCSTR_HIDDEN) + ")"; // " (hidden)"
aTitleBase = GetText();
diff --git a/sc/source/ui/optdlg/tpformula.cxx b/sc/source/ui/optdlg/tpformula.cxx
index dd047ff813ff..376a22681259 100644
--- a/sc/source/ui/optdlg/tpformula.cxx
+++ b/sc/source/ui/optdlg/tpformula.cxx
@@ -49,9 +49,9 @@ ScTpFormulaOptions::ScTpFormulaOptions(vcl::Window* pParent, const SfxItemSet& r
get(mpLbOOXMLRecalcOptions, "ooxmlrecalc");
get(mpLbODFRecalcOptions, "odfrecalc");
- mpLbFormulaSyntax->InsertEntry(ScResId(SCSTR_FORMULA_SYNTAX_CALC_A1).toString());
- mpLbFormulaSyntax->InsertEntry(ScResId(SCSTR_FORMULA_SYNTAX_XL_A1).toString());
- mpLbFormulaSyntax->InsertEntry(ScResId(SCSTR_FORMULA_SYNTAX_XL_R1C1).toString());
+ mpLbFormulaSyntax->InsertEntry(ScResId(SCSTR_FORMULA_SYNTAX_CALC_A1));
+ mpLbFormulaSyntax->InsertEntry(ScResId(SCSTR_FORMULA_SYNTAX_XL_A1));
+ mpLbFormulaSyntax->InsertEntry(ScResId(SCSTR_FORMULA_SYNTAX_XL_R1C1));
Link<Button*,void> aLink2 = LINK( this, ScTpFormulaOptions, ButtonHdl );
mpBtnSepReset->SetClickHdl(aLink2);
diff --git a/sc/source/ui/optdlg/tpview.cxx b/sc/source/ui/optdlg/tpview.cxx
index 38aa83ea6f4d..bf47a82f5b62 100644
--- a/sc/source/ui/optdlg/tpview.cxx
+++ b/sc/source/ui/optdlg/tpview.cxx
@@ -329,7 +329,7 @@ ScTpLayoutOptions::ScTpLayoutOptions( vcl::Window* pParent,
const SfxItemSet& rArgSet ) :
SfxTabPage( pParent, "ScGeneralPage",
"modules/scalc/ui/scgeneralpage.ui", &rArgSet),
- aUnitArr( ScResId(SCSTR_UNIT )),
+ aUnitArr(ResId(SCSTR_UNIT, *SC_MOD()->GetResMgr())),
pDoc(nullptr)
{
get( m_pUnitLB, "unitlb");
diff --git a/sc/source/ui/pagedlg/tphfedit.cxx b/sc/source/ui/pagedlg/tphfedit.cxx
index ca1b9f43a116..a0a73ce8cae8 100644
--- a/sc/source/ui/pagedlg/tphfedit.cxx
+++ b/sc/source/ui/pagedlg/tphfedit.cxx
@@ -314,17 +314,17 @@ css::uno::Reference< css::accessibility::XAccessible > ScEditWindow::CreateAcces
{
case Left:
{
- sName = OUString(ScResId(STR_ACC_LEFTAREA_NAME));
+ sName = ScResId(STR_ACC_LEFTAREA_NAME);
}
break;
case Center:
{
- sName = OUString(ScResId(STR_ACC_CENTERAREA_NAME));
+ sName = ScResId(STR_ACC_CENTERAREA_NAME);
}
break;
case Right:
{
- sName = OUString(ScResId(STR_ACC_RIGHTAREA_NAME));
+ sName = ScResId(STR_ACC_RIGHTAREA_NAME);
}
break;
}
diff --git a/sc/source/ui/unoobj/PivotTableDataProvider.cxx b/sc/source/ui/unoobj/PivotTableDataProvider.cxx
index a9d453454918..d412265b033c 100644
--- a/sc/source/ui/unoobj/PivotTableDataProvider.cxx
+++ b/sc/source/ui/unoobj/PivotTableDataProvider.cxx
@@ -511,11 +511,11 @@ void PivotTableDataProvider::collectPivotTableData()
if (aMembers.size() == 1)
aFieldOutputDescription = aMembers[0];
else
- aFieldOutputDescription = ScResId(SCSTR_MULTIPLE).toString();
+ aFieldOutputDescription = ScResId(SCSTR_MULTIPLE);
}
else
{
- aFieldOutputDescription = ScResId(SCSTR_ALL).toString();
+ aFieldOutputDescription = ScResId(SCSTR_ALL);
}
m_aFieldOutputDescriptionMap[nDim] = aFieldOutputDescription;
}
diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx
index 0e5c0ab6bb84..5df2608e73e6 100644
--- a/sc/source/ui/unoobj/docuno.cxx
+++ b/sc/source/ui/unoobj/docuno.cxx
@@ -255,30 +255,30 @@ ScPrintUIOptions::ScPrintUIOptions()
// create Section for spreadsheet (results in an extra tab page in dialog)
SvtModuleOptions aOpt;
- OUString aAppGroupname( SC_RESSTR( SCSTR_PRINTOPT_PRODNAME ) );
+ OUString aAppGroupname( ScResId( SCSTR_PRINTOPT_PRODNAME ) );
aAppGroupname = aAppGroupname.replaceFirst( "%s", aOpt.GetModuleName( SvtModuleOptions::EModule::CALC ) );
m_aUIProperties[nIdx++].Value = setGroupControlOpt("tabcontrol-page2", aAppGroupname, OUString());
// show subgroup for pages
- m_aUIProperties[nIdx++].Value = setSubgroupControlOpt("pages", SC_RESSTR( SCSTR_PRINTOPT_PAGES ), OUString());
+ m_aUIProperties[nIdx++].Value = setSubgroupControlOpt("pages", ScResId( SCSTR_PRINTOPT_PAGES ), OUString());
// create a bool option for empty pages
- m_aUIProperties[nIdx++].Value = setBoolControlOpt("suppressemptypages", SC_RESSTR( SCSTR_PRINTOPT_SUPPRESSEMPTY ),
+ m_aUIProperties[nIdx++].Value = setBoolControlOpt("suppressemptypages", ScResId( SCSTR_PRINTOPT_SUPPRESSEMPTY ),
".HelpID:vcl:PrintDialog:IsSuppressEmptyPages:CheckBox",
"IsSuppressEmptyPages",
bSuppress);
// show Subgroup for print content
vcl::PrinterOptionsHelper::UIControlOptions aPrintRangeOpt;
aPrintRangeOpt.maGroupHint = "PrintRange";
- m_aUIProperties[nIdx++].Value = setSubgroupControlOpt("printrange", SC_RESSTR( SCSTR_PRINTOPT_PRNTCONTENT ),
+ m_aUIProperties[nIdx++].Value = setSubgroupControlOpt("printrange", ScResId( SCSTR_PRINTOPT_PRNTCONTENT ),
OUString(),
aPrintRangeOpt);
// create a choice for the content to create
uno::Sequence< OUString > aChoices{
- SC_RESSTR( SCSTR_PRINTOPT_ALLSHEETS ),
- SC_RESSTR( SCSTR_PRINTOPT_SELECTEDSHEETS ),
- SC_RESSTR( SCSTR_PRINTOPT_SELECTEDCELLS )};
+ ScResId( SCSTR_PRINTOPT_ALLSHEETS ),
+ ScResId( SCSTR_PRINTOPT_SELECTEDSHEETS ),
+ ScResId( SCSTR_PRINTOPT_SELECTEDCELLS )};
uno::Sequence< OUString > aHelpIds{
".HelpID:vcl:PrintDialog:PrintContent:RadioButton:0",
".HelpID:vcl:PrintDialog:PrintContent:RadioButton:1",
@@ -293,7 +293,7 @@ ScPrintUIOptions::ScPrintUIOptions()
// show Subgroup for print range
aPrintRangeOpt.mbInternalOnly = true;
- m_aUIProperties[nIdx++].Value = setSubgroupControlOpt("fromwhich", SC_RESSTR( SCSTR_PRINTOPT_FROMWHICH ),
+ m_aUIProperties[nIdx++].Value = setSubgroupControlOpt("fromwhich", ScResId( SCSTR_PRINTOPT_FROMWHICH ),
OUString(),
aPrintRangeOpt);
@@ -302,10 +302,10 @@ ScPrintUIOptions::ScPrintUIOptions()
aChoices.realloc( 2 );
aHelpIds.realloc( 2 );
aWidgetIds.realloc( 2 );
- aChoices[0] = SC_RESSTR( SCSTR_PRINTOPT_ALLPAGES );
+ aChoices[0] = ScResId( SCSTR_PRINTOPT_ALLPAGES );
aHelpIds[0] = ".HelpID:vcl:PrintDialog:PrintRange:RadioButton:0";
aWidgetIds[0] = "printallpages";
- aChoices[1] = SC_RESSTR( SCSTR_PRINTOPT_PAGES_ );
+ aChoices[1] = ScResId( SCSTR_PRINTOPT_PAGES_ );
aHelpIds[1] = ".HelpID:vcl:PrintDialog:PrintRange:RadioButton:1";
aWidgetIds[1] = "printpages";
m_aUIProperties[nIdx++].Value = setChoiceRadiosControlOpt(aWidgetIds, OUString(),
diff --git a/sc/source/ui/view/drawvie3.cxx b/sc/source/ui/view/drawvie3.cxx
index 346d3d85cfcb..daf4666a15ab 100644
--- a/sc/source/ui/view/drawvie3.cxx
+++ b/sc/source/ui/view/drawvie3.cxx
@@ -62,7 +62,7 @@ void ScDrawView::SetPageAnchored()
const SdrMarkList* pMark = &GetMarkedObjectList();
const size_t nCount = pMark->GetMarkCount();
- BegUndo( OUString(ScResId( SCSTR_UNDO_PAGE_ANCHOR )) );
+ BegUndo(ScResId(SCSTR_UNDO_PAGE_ANCHOR));
for( size_t i=0; i<nCount; ++i )
{
SdrObject* pObj = pMark->GetMark(i)->GetMarkedSdrObj();
@@ -90,7 +90,7 @@ void ScDrawView::SetCellAnchored()
const SdrMarkList* pMark = &GetMarkedObjectList();
const size_t nCount = pMark->GetMarkCount();
- BegUndo( OUString(ScResId( SCSTR_UNDO_CELL_ANCHOR )) );
+ BegUndo(ScResId(SCSTR_UNDO_CELL_ANCHOR));
for( size_t i=0; i<nCount; ++i )
{
SdrObject* pObj = pMark->GetMark(i)->GetMarkedSdrObj();
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 95ffc0e67ba5..a464447c20fd 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -680,21 +680,21 @@ void ScGridWindow::LaunchAutoFilterMenu(SCCOL nCol, SCROW nRow)
// Populate the menu.
mpAutoFilterPopup->addMenuItem(
- SC_RESSTR(STR_MENU_SORT_ASC),
+ ScResId(STR_MENU_SORT_ASC),
new AutoFilterAction(this, SortAscending));
mpAutoFilterPopup->addMenuItem(
- SC_RESSTR(STR_MENU_SORT_DESC),
+ ScResId(STR_MENU_SORT_DESC),
new AutoFilterAction(this, SortDescending));
mpAutoFilterPopup->addSeparator();
mpAutoFilterPopup->addMenuItem(
- SC_RESSTR(SCSTR_TOP10FILTER), new AutoFilterAction(this, Top10));
+ ScResId(SCSTR_TOP10FILTER), new AutoFilterAction(this, Top10));
mpAutoFilterPopup->addMenuItem(
- SC_RESSTR(SCSTR_FILTER_EMPTY), new AutoFilterAction(this, Empty));
+ ScResId(SCSTR_FILTER_EMPTY), new AutoFilterAction(this, Empty));
mpAutoFilterPopup->addMenuItem(
- SC_RESSTR(SCSTR_FILTER_NOTEMPTY), new AutoFilterAction(this, NonEmpty));
+ ScResId(SCSTR_FILTER_NOTEMPTY), new AutoFilterAction(this, NonEmpty));
mpAutoFilterPopup->addSeparator();
mpAutoFilterPopup->addMenuItem(
- SC_RESSTR(SCSTR_STDFILTER), new AutoFilterAction(this, Custom));
+ ScResId(SCSTR_STDFILTER), new AutoFilterAction(this, Custom));
ScCheckListMenuWindow::Config aConfig;
aConfig.mbAllowEmptySet = false;
diff --git a/sc/source/ui/view/gridwin2.cxx b/sc/source/ui/view/gridwin2.cxx
index 653776227e0e..ebd9a63f2a2d 100644
--- a/sc/source/ui/view/gridwin2.cxx
+++ b/sc/source/ui/view/gridwin2.cxx
@@ -509,13 +509,13 @@ void ScGridWindow::DPLaunchFieldPopupMenu(const Point& rScrPos, const Size& rScr
// Populate the menus.
ScTabViewShell* pViewShell = pViewData->GetViewShell();
mpDPFieldPopup->addMenuItem(
- SC_RESSTR(STR_MENU_SORT_ASC),
+ ScResId(STR_MENU_SORT_ASC),
new PopupSortAction(pDPObj, nDimIndex, PopupSortAction::ASCENDING, 0, pViewShell));
mpDPFieldPopup->addMenuItem(
- SC_RESSTR(STR_MENU_SORT_DESC),
+ ScResId(STR_MENU_SORT_DESC),
new PopupSortAction(pDPObj, nDimIndex, PopupSortAction::DESCENDING, 0, pViewShell));
ScMenuFloatingWindow* pSubMenu = mpDPFieldPopup->addSubMenuItem(
- SC_RESSTR(STR_MENU_SORT_CUSTOM), !aUserSortNames.empty());
+ ScResId(STR_MENU_SORT_CUSTOM), !aUserSortNames.empty());
if (pSubMenu && !aUserSortNames.empty())
{
diff --git a/sc/source/ui/view/tabvwshf.cxx b/sc/source/ui/view/tabvwshf.cxx
index d2980486bb4e..03b35199c6b2 100644
--- a/sc/source/ui/view/tabvwshf.cxx
+++ b/sc/source/ui/view/tabvwshf.cxx
@@ -372,13 +372,13 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
switch ( nSlot )
{
case FID_TAB_APPEND:
- aDlgTitle = OUString(ScResId(SCSTR_APDTABLE));
+ aDlgTitle = ScResId(SCSTR_APDTABLE);
pDoc->CreateValidTabName( aName );
pHelpId = HID_SC_APPEND_NAME;
break;
case FID_TAB_RENAME:
- aDlgTitle = OUString(ScResId(SCSTR_RENAMETAB));
+ aDlgTitle = ScResId(SCSTR_RENAMETAB);
pDoc->GetName( rViewData.GetTabNo(), aName );
pHelpId = HID_SC_RENAME_NAME;
break;
@@ -388,7 +388,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
ScopedVclPtr<AbstractScStringInputDlg> pDlg(pFact->CreateScStringInputDlg(
- GetDialogParent(), aDlgTitle, OUString(ScResId(SCSTR_NAME)),
+ GetDialogParent(), aDlgTitle, ScResId(SCSTR_NAME),
aName, GetStaticInterface()->GetSlot(nSlot)->GetCommand(),
pHelpId));
@@ -773,8 +773,8 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
ScopedVclPtr<AbstractScTabBgColorDlg> pDlg(pFact->CreateScTabBgColorDlg(
GetDialogParent(),
- OUString(ScResId(SCSTR_SET_TAB_BG_COLOR)),
- OUString(ScResId(SCSTR_NO_TAB_BG_COLOR)),
+ ScResId(SCSTR_SET_TAB_BG_COLOR),
+ ScResId(SCSTR_NO_TAB_BG_COLOR),
aTabBgColor));
while ( !bDone && nRet == RET_OK )
{