Bug 48110 - FORMATTING: Get rid of the confusing and wrong "Automatically" currency format.
Summary: FORMATTING: Get rid of the confusing and wrong "Automatically" currency format.
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: framework (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Eike Rathke
URL:
Whiteboard: target:4.4.0 target:4.3.2
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-30 23:18 UTC by gleppert
Modified: 2014-08-16 09:09 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Example-wrong-default-currency-Austrian-Shillings.jpg (55.81 KB, image/jpeg)
2012-04-15 11:02 UTC, gleppert
Details

Note You need to log in before you can comment on or make changes to this bug.
Description gleppert 2012-03-30 23:18:04 UTC
In the German locale of LibreOffice 3.5.1 the default currency is still DM instead of EUR. I believe this is just a outdated setting in Calc.

Steps to reproduce:
* Open Calc
* Right mouse click on any cell
* Choose "Numbers" -> "Currency"
* and choose in the scroll bar "Format" the currency "Automatically"
* The chosen currency is DM which is wrong since the Euro was introduced in 2002.

Thanks for fixing this trivial bug!
Comment 1 Andras Timar 2012-04-15 05:48:07 UTC
I cannot reproduce your problem. Could you please give more details, operating system, locale settings, etc.?
Comment 2 gleppert 2012-04-15 10:49:37 UTC
Thanks Andras for looking into it.

The LibreOffice version is 3.5.2 from the Ubuntu PPA, Ubuntu 11.10 64-Bit, German locale de-DE. However, I believe that the OS does not make a difference.

Here the information from Tools -> Options -> Language Settings -> Languages:
User Interface: English (UK)
Locale Setting: English (UK)
Default currency: EUR € German (Germany)
Default language for documents; Default-English (UK)

Do you need any other information?
Comment 3 gleppert 2012-04-15 11:02:22 UTC
Created attachment 60021 [details]
Example-wrong-default-currency-Austrian-Shillings.jpg

Some more additions: 

Please find attached a screen shot which shows the same problem with German (Austria) in the currency-format dialog. If you choose in the pull down menu "Automatically", the currency goes wrongly to Austrian shillings.

I tried some more Euro-countries and apparently it was forgotten after 2002 to change the automatic default currencies, e.g.

French (France) redirects automatically to F instead of Euro
French (Luxembourg) redirects to F
French (Belgium) redirects to FB
German (Austria) redirects to öS
German (Germany) redirects to DM
Italian (Italy) redirects to ₤ (Lira)
Comment 4 Andras Timar 2012-04-19 03:08:56 UTC
@Eike: in i18pool/source/localedata/data xml files for Euro countries still contain old currencies as default in FormatElements used for currency. Is this intentional, or does it need to be fixed?

E.g. in de_AT.xml
<FormatElement msgid="CurrencyFormatskey1" default="true" type="short" usage="CURRENCY" formatindex="12">
      <FormatCode>[$öS-C07] #.##0;-[$öS-C07] #.##0</FormatCode>
</FormatElement>
Comment 5 Eike Rathke 2012-04-19 08:16:10 UTC
This is on purpose. It is for backwards compatibility with legacy documents where "Automatically" was used and resulted in the legacy currency, you certainly don't want that to suddenly display Euro instead ... If loaded in another locale and the original locale of the number format was system (and not fixed to a specific locale) the currency changes as well, this is all crap ...  In fact the "Automatically" currency format should not be used nowadays, there is no easy way to get rid of it though, as legacy documents still need it.

The actual default currency format is determined differently and obtained from the LC_CURRENCY Currency elements that are correct and replace the symbol in the currency FormatCode elements.

Taking this bug as a placeholder. Maybe there's a way to offer the format only if it is used.
Comment 6 gleppert 2012-04-20 14:20:15 UTC
Thanks Eike, I learnt that a "trivial correction" is not necessarily trivial :-)
Comment 7 retired 2014-01-08 09:27:22 UTC
This bug hasn't seen any action in a very long time. Freeing this bug and switching ASSIGNED to NEW

Eike if you are still working on this, please re-assign yourself. Or can this bug be closed already?
Comment 8 Eike Rathke 2014-01-09 14:56:36 UTC
The task to display the "automatic currency" format entry only if it is used by the current document content still needs to be done.
Comment 9 Commit Notification 2014-08-15 20:59:34 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=2e3d7c742a1c1253c4bb2af1c3d1b1506d2e7af4

fdo#48110 disable the "Automatically" currency unless already used



The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds
Affected users are encouraged to test the fix and report feedback.
Comment 10 Eike Rathke 2014-08-15 21:07:03 UTC
Pending review for 4-3 at https://gerrit.libreoffice.org/10939
Comment 11 Commit Notification 2014-08-16 09:09:25 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-4-3":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=2d52a907e26c306fa6738766409df2d7760fe3c4&h=libreoffice-4-3

fdo#48110 disable the "Automatically" currency unless already used


It will be available in LibreOffice 4.3.2.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds
Affected users are encouraged to test the fix and report feedback.