summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2023-01-01 15:35:16 +0100
committerMike Kaganski <mike.kaganski@collabora.com>2023-01-11 16:31:06 +0000
commitfdc28c4b2b42c2028f3a6bf7cfc18c94ee072969 (patch)
tree3300d1d86e8052d664370330dacbeb1c767ccf5f /sc
parentf388ea5b3734aca80d7c61c850413c649294c446 (diff)
Resolves: tdf#151886 Use default locale with English function names again
Automatically switching to en-US locale when using English function names caused too much confusion. There also might be the possibility that the '.' dot decimal separator clashes with the inline array column separator in some locales. A proper solution would make this user-specified and if set also adjust the separators to the common English ones. For now keep the default locale again as it previously was the case. Change-Id: Ic4712c6609c14f35cf0d1d842ac7443806a6e115 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144924 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins (cherry picked from commit cf8cfee9d4e64dba6a14dde16f08a7699fdff863) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144906 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/tool/compiler.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index 1180c559881b..cdb7dedff68e 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -2156,8 +2156,8 @@ std::vector<ScCompiler::Whitespace> ScCompiler::NextSymbol(bool bInArray)
sal_Unicode cSep = mxSymbols->getSymbolChar( ocSep);
sal_Unicode cArrayColSep = mxSymbols->getSymbolChar( ocArrayColSep);
sal_Unicode cArrayRowSep = mxSymbols->getSymbolChar( ocArrayRowSep);
- sal_Unicode cDecSep = (mxSymbols->isEnglish() ? '.' : ScGlobal::getLocaleData().getNumDecimalSep()[0]);
- sal_Unicode cDecSepAlt = (mxSymbols->isEnglish() ? 0 : ScGlobal::getLocaleData().getNumDecimalSepAlt().toChar());
+ sal_Unicode cDecSep = (mxSymbols->isEnglishLocale() ? '.' : ScGlobal::getLocaleData().getNumDecimalSep()[0]);
+ sal_Unicode cDecSepAlt = (mxSymbols->isEnglishLocale() ? 0 : ScGlobal::getLocaleData().getNumDecimalSepAlt().toChar());
// special symbols specific to address convention used
sal_Unicode cSheetPrefix = pConv->getSpecialSymbol(ScCompiler::Convention::ABS_SHEET_PREFIX);
@@ -3170,7 +3170,7 @@ bool ScCompiler::ParseValue( const OUString& rSym )
}
double fVal;
- sal_uInt32 nIndex = mxSymbols->isEnglish() ? mpFormatter->GetStandardIndex(LANGUAGE_ENGLISH_US) : 0;
+ sal_uInt32 nIndex = mxSymbols->isEnglishLocale() ? mpFormatter->GetStandardIndex(LANGUAGE_ENGLISH_US) : 0;
if (!mpFormatter->IsNumberFormat(rSym, nIndex, fVal))
return false;
@@ -3427,7 +3427,7 @@ bool ScCompiler::ParseReference( const OUString& rName, const OUString* pErrRef
mnCurrentSheetTab = -1;
sal_Unicode ch1 = rName[0];
- sal_Unicode cDecSep = ( mxSymbols->isEnglish() ? '.' : ScGlobal::getLocaleData().getNumDecimalSep()[0] );
+ sal_Unicode cDecSep = ( mxSymbols->isEnglishLocale() ? '.' : ScGlobal::getLocaleData().getNumDecimalSep()[0] );
if ( ch1 == cDecSep )
return false;
// Code further down checks only if cDecSep=='.' so simply obtaining the