[PyQt] SystemLocaleShortDate omits the century on Linux

Sibylle Koczian nulla.epistola at web.de
Wed Mar 11 18:18:14 GMT 2020


on Windows SystemLocaleShortDate gives 'dd.MM.yyyy', quite correct for
locale de-DE.

On Linux (at least on ArchLinux, I didn't try other distributions) it
gives 'dd.MM.yy' with the same locale.

The documentation calls SystemLocaleShortDate "The short format used by
the operating system". But the locale's date representation as given by
"date +%x" in the Linux terminal shows the date as it should be,
including the century.

Why the difference?

It is especially annoying with dates from this year in a QTableView: I
always try to drag the date column wider which doesn't help.

Looking for explanations,

More information about the PyQt mailing list