<html>
<head>
<base href="https://bugs.documentfoundation.org/">
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - FORMATTING: Enhancement: Expand usage of local settings (regional settings) in Options/Languages"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=73242#c8">Comment # 8</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - FORMATTING: Enhancement: Expand usage of local settings (regional settings) in Options/Languages"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=73242">bug 73242</a>
from <span class="vcard"><a class="email" href="mailto:jsd.libreoffice@bvac.co.za" title="jsd.libreoffice@bvac.co.za">jsd.libreoffice@bvac.co.za</a>
</span></b>
<pre>(In reply to Buovjaga from <a href="show_bug.cgi?id=73242#c7">comment #7</a>)
<span class="quote">> *** <a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED DUPLICATE - Numeric format inconsistency: Macros vs Writer fields, formula calculation fails"
href="show_bug.cgi?id=123878">Bug 123878</a> has been marked as a duplicate of this bug. ***</span >
I'd like to point out, since it isn't mentioned so far in this thread, that my
reason for logging <a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED DUPLICATE - Numeric format inconsistency: Macros vs Writer fields, formula calculation fails"
href="show_bug.cgi?id=123878">bug 123878</a> originally was because of how LO is parsing
numeric literals.
Brace yourself, this gets confusing...
My complaint is that for me, numbers with decimal places, LO does not interpret
a period as the decimal point; it expects a comma instead.
So for example, the string "123.4" (with a period) gets treated as zero when
used in a formula. However, the string "123,4" gets treated correctly (i.e. as
a tenth of 1234)
Now on the one hand, this is arguably correct, given that my OS locale is South
Africa, where the _standard_ decimal separator is indeed a comma.
However in the OS settings I have _changed_ the decimal separator to a period,
and LO isn't picking that up.
Yet in the LO preferences, the locale _there_ is English (UK), where I'm pretty
sure the decimal separator is a period.
So it's not clear to me where LO's idea of the comma as decimal separator is
coming from.
But regardless of that, IMHO LO should actually *ignore* the regional settings
when parsing numeric literals. My reasoning is:
(1) it makes numeric literals in macros and formulae locale-independent
(2) it's consistent with OpenOffice and MS Office behaviour
(3) it plays nice with Calc, because cell values are extracted with decimal
_periods_ even with my locale settings.
FWIW, I logged that bug after migrating from OO to LO.
I have a Writer template with calculations that failed in LO because it
contained numbers with decimal periods (not commas). Changing the periods to
commas fixed the calculations.
That template also has a macro that extracts a cell value from a spreadsheet
and uses it in a formula. The formula failed for the same reason: the
extracted value (which was truly a number, not s string) is converted
implicitly by LO to a string, with a decimal _period_. Calculations with that
value fail unless the period is replaced with a comma.
OK finally, FYI: there's an attachment to <a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED DUPLICATE - Numeric format inconsistency: Macros vs Writer fields, formula calculation fails"
href="show_bug.cgi?id=123878">bug 123878</a> with a minimal demo of the
calculation problem in a Writer template.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>