Bug 134155 - Calc VIEWING: Boolean values shown in number formatting language instead of UI language
Summary: Calc VIEWING: Boolean values shown in number formatting language instead of U...
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-19 16:06 UTC by christos
Modified: 2020-08-01 09:43 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Why Boolean values shown as words should be in the UI language (107.73 KB, application/vnd.oasis.opendocument.spreadsheet)
2020-06-27 12:08 UTC, christos
Details

Note You need to log in before you can comment on or make changes to this bug.
Description christos 2020-06-19 16:06:50 UTC
Description:
Calc shows Boolean values in the locale language. However, Calc should show Boolean values in the language in which LibreOffice communicates with the user, as it does for functions. Locale serves a different purpose. For example, someone living in a country with a different convention for the decimal separator can paste numbers with decimal digits from websites or text files into Calc with no risk of Calc converting these numbers into text. The UI language is a communication language, the locale a technical language. Booleans belong to the former.

Steps to Reproduce:
1. Make sure that English is the UI language and the locale setting is different.
2. Open a new spreadsheet.
3. Type =TRUE() and ENTER.

Actual Results:
TRUE is shown in the cell translated into the locale language, becoming, for example, VRAI in French.

Expected Results:
The Boolean value should be shown in the UI language. This is the language in which all functions including TRUE() are shown in both the input line and the cells once the user has chosen, from the menu, View > Show Formula.


Reproducible: Always


User Profile Reset: Yes



Additional Info:
Version: 6.4.4.2 (x64)
Build ID: 3d775be2011f3886db32dfd395a6a6d1ca2630ff
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: default; VCL: win; 
Locale: fr-FR (en_US); UI-Language: en-US
Calc: threaded
Comment 1 m.a.riosv 2020-06-19 23:11:49 UTC
With a UI different from English you can set up to see the functions names in English, but functions names are not part of cell's result.

To me a clear wontfix, there is no reason to show a result in a different language than what is set up for the cell involved, which has nothing to do with UI.

If you don't want change the local language, it's possible to select the desire language to show cell's result in Default Style, o configure one specific for those cells.
Comment 2 christos 2020-06-22 07:57:46 UTC
As mentioned in the summary and the steps to reproduce, the bug is not that the function names are shown in English for this configuration (English UI, different locale, e.g. French). The bug is that the Boolean VALUE is shown in the locale language. The function was mentioned in the steps to reproduce as a way of obtaining a Boolean value for the cell's result.

The reason to show Boolean results in a different language from the one in the locale is that they should be in the UI language. A Calc user may need to tolerate different date or decimal formats by choosing a locale different from the UI language. However, Boolean results shown as words in a human language ought to be in the UI language. This should be the case for any user who may need to open the file.
Comment 3 m.a.riosv 2020-06-22 11:04:07 UTC
Sorry @Christos, I don't know what it's no clear.

The result in a cell has nothing to do with the UI language but document language, as mentioned if you want to see the boolean in other language different document's default language, select it for that cell(S), maybe using styles make it simple.

And please don't ask for a new option for this very particular corner case, there is a just lot of them now.
Comment 4 christos 2020-06-27 12:08:08 UTC
Created attachment 162452 [details]
Why Boolean values shown as words should be in the UI language

Despite having read the excellent instructions for reporting bugs in the wiki and done my best to explain, I seem not to be getting my point across. Why do you keep referring to the language "set up for the cell involved" or the "document language"? I said nothing about this language, because Calc does not apply it in this case.

Perhaps our disagreement has to do with semantics, the meaning of locale. I am attaching a spreadsheet with a more detailed explanation including examples as well as the pros and cons of the various alternatives. We both want to make LibreOffice better and this means fixing bugs such as this one, although there are certainly others that should take priority.
Comment 5 Mike Kaganski 2020-07-30 20:07:54 UTC
(In reply to christos from comment #4)

The cell value is displayed always according to the language defined for the number format of that cell.

(In reply to christos from comment #0)
> Calc should show
> Boolean values in the language in which LibreOffice communicates with the
> user, as it does for functions. Locale serves a different purpose. For
> example, someone living in a country with a different convention for the
> decimal separator can paste numbers with decimal digits from websites or
> text files into Calc with no risk of Calc converting these numbers into
> text. The UI language is a communication language, the locale a technical
> language.

The question is: given the locale that you chose (Spanish) and UI language (en-US), how do you thing should *numbers* be displayed in a new spreadsheet by default? According to Spanish rules, or according to rules used in USA?

In LibreOffice, the convention is that locale rules are used to format numbers - *by default*. Note that the language shown in status bar is misleading and only shows the language used for spell check (available on cell format's Font tab); but number format locale is available on cell format's *Numbers* tab. And that is what gives you the "unexpected" boolean value display: just like formatting of numbers would use comma for decimal separator for Spanish locale, the same logic requires that true value be formatted according to same locale's rules.

If you think that not only boolean values, but any formats should *by default* follow UI language and not locale, then there's a place for discussion (which I can't participate in). Likely it's considered that being in sole place (locale), display of values in the spreadsheet should match the place rules ... but as I said, I can't discuss reasons. My point is that either it should stay as it is, or *all* formats should by default follow UI language, not only booleans, but also numbers, dates, times, currencies (!), etc.
Comment 6 christos 2020-07-31 15:45:37 UTC
(In reply to Mike Kaganski from comment #5)

Thank you for your comment. I am updating the summary accordingly.

> (In reply to christos from comment #4)
> 
> The cell value is displayed always according to the language defined for the
> number format of that cell.
> 
That's the bug. This "always", this one-size-fits-all is not right for Boolean words. They are a different beast. Roughly speaking, this has to do with the difference between words and numbers. In the spreadsheet, I tried to show why the UI language is more appropriate for Boolean words.

> (In reply to christos from comment #0)
> [...]
> The question is: given the locale that you chose (Spanish) and UI language
> (en-US), how do you thing should *numbers* be displayed in a new spreadsheet
> by default?
Genuine numbers are displayed fine. This report is about the display of Boolean words.
 
> If you think that not only boolean values, but any formats should *by
> default* follow UI language and not locale, [...]
No, this is only about the Boolean values that are displayed automatically as words. The locale language, when it differs from the UI language, is a useful default for the display of genuine numbers.
Comment 7 m.a.riosv 2020-08-01 09:43:04 UTC
When one doesn't want to earht, it's really difficult.

Boolean it's a property format of the cell, it has nothing to do with the UI language, because it's a number value in the cell.

Do you think that a such huge development to get it done, will happen only for cover your personal interest?

While you can get it easly by creating a cell style for that cells.

In any case it is not a bug, you can go with a new request for enchancement, but IMHO it's a lost of time.