diff options
author | Eike Rathke <erack@redhat.com> | 2021-03-11 16:55:14 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2021-03-12 11:16:19 +0100 |
commit | 1d0b2ae1423142f3688de00d9938917329e958af (patch) | |
tree | 4fdc68454ef6b3f90058390bcebb3989bfe9b71e /xmloff | |
parent | 2e334998f4a821ea05ce25dc6346b556bcb1347b (diff) |
ODF save: write explicit "gregorian" calendar, not empty if default
Other implementations may have different opinions about default
calendars and the context here is to switch to Gregorian.
Change-Id: I14a27826e627f890911adaf01935c58b43ad766a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112354
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
Diffstat (limited to 'xmloff')
-rw-r--r-- | xmloff/source/style/xmlnumfe.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/xmloff/source/style/xmlnumfe.cxx b/xmloff/source/style/xmlnumfe.cxx index 24c0524a4239..1392c4e0f2f7 100644 --- a/xmloff/source/style/xmlnumfe.cxx +++ b/xmloff/source/style/xmlnumfe.cxx @@ -1651,12 +1651,12 @@ void SvXMLNumFmtExport::ExportPart_Impl( const SvNumberformat& rFormat, sal_uInt // Calendar attribute for E and EE and R is set in // first loop. If set and not an explicit calendar and // YY or YYYY is encountered, switch temporarily to - // Gregorian, i.e. empty calendar name. + // Gregorian. bool bLong = ( nElemType == NF_KEY_YYYY || nElemType == NF_KEY_EEC || nElemType == NF_KEY_R ); WriteYearElement_Impl( ((bImplicitOtherCalendar && !bExplicitCalendar - && (nElemType == NF_KEY_YY || nElemType == NF_KEY_YYYY)) ? OUString() : aCalendar), + && (nElemType == NF_KEY_YY || nElemType == NF_KEY_YYYY)) ? "gregorian" : aCalendar), (bSystemDate ? bLongSysDate : bLong)); bAnyContent = true; } |