diff options
author | Kohei Yoshida <kyoshida@novell.com> | 2010-11-03 14:41:59 -0400 |
---|---|---|
committer | Kohei Yoshida <kyoshida@novell.com> | 2010-11-03 14:46:59 -0400 |
commit | 55cd5ed89d0eb1f3be976d592438fa9f8fabc52d (patch) | |
tree | f7380c09b1500f495347adc7b43c87c74524bfb7 | |
parent | 287d59ff7b1002f698ecf4a4e7a6a08ec4e6269a (diff) |
Set correct default formula syntax value in case it's not explicitly set.
When starting from a fresh config, Calc failed to assign default 'Calc A1'
syntax unless the user specifically goes to the Options page and sets the
formula syntax in the Calc - Formula options page. This caused e.g.
print range editing to fail miserably. (fdo#31041)
-rw-r--r-- | sc/source/core/tool/docoptio.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/core/tool/docoptio.cxx b/sc/source/core/tool/docoptio.cxx index 50fb8cb0c..ccc5eae58 100644 --- a/sc/source/core/tool/docoptio.cxx +++ b/sc/source/core/tool/docoptio.cxx @@ -452,7 +452,8 @@ ScDocCfg::ScDocCfg() : { case SCFORMULAOPT_GRAMMAR: { - ::formula::FormulaGrammar::Grammar eGram = ::formula::FormulaGrammar::GRAM_DEFAULT; + // Get default value in case this option is not set. + ::formula::FormulaGrammar::Grammar eGram = GetFormulaSyntax(); do { @@ -471,6 +472,8 @@ ScDocCfg::ScDocCfg() : case 2: // Excel R1C1 eGram = ::formula::FormulaGrammar::GRAM_NATIVE_XL_R1C1; break; + default: + ; } } while (false); |