Date format trouble (locale)

Thomas Baumgart thb at net-bembel.de
Tue Aug 11 20:51:21 BST 2020


On Montag, 10. August 2020 22:17:33 CEST Koos Pol wrote:

> 
> Op 10-08-2020 om 22:02 schreef Jack:
> 
> > It's worth opening a wishlist bug, just so this isn't forgotten in
> > case this thread doesn't lead to a definitive action.  You can list
> > several possible actions there, so it doesn't limit you to only one
> > choice.
> 
> Not a bad idea. I'll wait for a couple of days to see if this thread
> gains some more traction. If not I'll do that.
> 
> > Have you looked at the KDE SystemSettings tool - under
> > Personalization/Regional Settings/Formats, if you check Detailed
> > Settings, you can then hunt through all the possible locales just for
> > the Time setting.  You might be ablet o find one with a long format
> > similar enough to nl_NL, but a short format with four digit year.
> 
> Yeah, I found one, but than the date picker starts to look funny. So
> that sort of doesn't work ;-)
> 
> > Another possibility is to create a new locale, which you copy from
> > nl_NL and then modify the short format time setting.  I think I tried
> > this once (for a similar reason, if I remember) and although I don't
> > think I actually succeeded, it might be worth a new attempt.  It might
> > be possible to combine these two - create a new locale with your
> > desired short date format, and then just use that single format as a
> > change to the rest of nl_NL.
> 
> That would be bliss. Let me look into that!

I wondered how this would work for me using the German locale. There, the
date is also shown with two digit year information. And I was not able to
enter any date in the 20th century at all except using the date picker and
entering the year using 4 digits. That worked. See the attached screenshot
of the datepicker.

I then scanned the sources and could not find anything in KMyMoney but
the following comment in Qt:

  Note that if you specify a two digit year, it will be interpreted
  to be in the century in which the date time edit was initialized.
  The default century is the 21 (2000-2099).

That would explain the behavior I have seen. Not sure if KMyMoney can
override the date format of the locale in a way that Qt will pick it up.

-- 

Regards

Thomas Baumgart

https://www.signal.org/       Signal, the better WhatsApp
-------------------------------------------------------------
What we call chaos is just patterns we haven't recognized.
What we call random is just patterns we can't decipher.
What we can't understand we call nonsense.
What we can't read we call gibberish. - Chuck Palahniuk
-------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: datepicker.png
Type: image/png
Size: 19479 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kmymoney/attachments/20200811/247cdfae/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 868 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kmymoney/attachments/20200811/247cdfae/attachment-0001.sig>


More information about the KMyMoney mailing list