[Abandoned] Re: Libreoffice Latvian format

Julien Nabet serval2412 at yahoo.fr
Tue May 4 17:57:48 UTC 2021

On 04/05/2021 17:44, Eike Rathke wrote:
> ...
> If we would really introduce DateOrder::YDM the extra check for
> rCode.indexOf('g') as an lv-LV speciality wouldn't be necessary.
> (btw, it should be "nDay <= nMonth" instead of "nDay << nMonth", and the
> condition be made another else if like the others).

My goal was indeed to be the most specific possible to not guess 
dateformat at random in other cases than Latvian.

Perhaps these other cases should be considered as wrong.

> Ugh.. there are quite some places that assume only the three values
> exist. Anything using those would have to be inspected what happens with
> the new value, and possibly adapting. ( git grep DateOrder:: )
> I haven't encountered YDM in short or medium date formats, so maybe that
> should be reserved for long date formats. Which then would be an
> additional LongDateOrder enum used only with
> LocaleDataWrapper::getLongDateOrder(), narrowing down the having to
> be adjusted cases quite by some and avoiding unnecessary code and
> complications.

Ok it's more complicate to deal with than I thought.

No need to spend some time and make the code more complicated because of 
this slight warning then.

Thank you for your feedback! :-)

More information about the LibreOffice mailing list