Bug 115780

Summary: Date fields in .docx files are shown in American English instead of the document language after loading a document
Product: LibreOffice Reporter: Martijn van de Streek <martijn>
Component: WriterAssignee: Not Assigned <libreoffice-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal CC: dgp-mail
Priority: medium    
Version: 6.0.1.1 release   
Hardware: All   
OS: All   
See Also: https://bugs.documentfoundation.org/show_bug.cgi?id=99236
Whiteboard:
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 112969    
Attachments: Document showing the problem

Description Martijn van de Streek 2018-02-16 13:22:30 UTC
Description:
Contents of date fields in .docx files with a non-English "dc:language" in docProps/core.xml  get rendered in American English instead of the document language defined in that "dc:language" element.

This is not the case if they're in a paragraph with an explicitly defined language.

(neither MS Word nor LibreOffice explicitly define paragraph language if the paragraph language matches the document language)

Steps to Reproduce:
1. Create a new document
 
2. Set document language to a non-English language

3. Insert a date field in a format that "shows off" which language it's in (include the month or week day, for instance). Observe that the date is shown in the document language (which is correct!).

4. Save the document as .docx

5. Close the file

6. Open the .docx again. Observe that the date is shown in US English (which is incorrect)

Actual Results:  
Date field is (re)rendered in US English.

Expected Results:
Date field is (re)rendered in the document language.


Reproducible: Always


User Profile Reset: Yes



Additional Info:


User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36
Comment 1 Martijn van de Streek 2018-02-16 13:26:02 UTC
Created attachment 139945 [details]
Document showing the problem

This document has a document language (docProps/core.xml - dc:language) of "nl-NL" (Dutch).

There are 3 paragraphs: one Dutch, one French, one US/English.

On loading the document, only the French date field is shown in French; both others will be shown in English.

Adding a new date field in the Dutch paragraph will show it in Dutch until the document is saved and loaded again. After loading, it is also in English.
Comment 2 Martijn van de Streek 2018-02-16 13:59:18 UTC
I've tried this on both Linux and Windows, and it happens on both.
Comment 3 Dieter 2018-02-16 15:16:24 UTC
Duplicate of Bug 99236?
Comment 4 Martijn van de Streek 2018-02-16 15:18:49 UTC
Looks like it, yes.

*** This bug has been marked as a duplicate of bug 99236 ***