Use GUI locale date formats on GUI and dialogs

This commit is contained in:
Veronica Berglyd Olsen
2024-03-12 22:01:54 +01:00
parent dc2c6d2a0d
commit 7d9040005e
5 changed files with 6 additions and 6 deletions
+1 -1
View File
@@ -829,7 +829,7 @@ class _PreviewWidget(QTextBrowser):
"""Update the build time and the fuzzy age."""
if self._docTime > 0:
strBuildTime = "%s (%s)" % (
datetime.fromtimestamp(self._docTime).strftime("%x %X"),
CONFIG.localDateTime(datetime.fromtimestamp(self._docTime)),
fuzzyTime(int(time()) - self._docTime)
)
else:
+1 -1
View File
@@ -456,7 +456,7 @@ class _ProjectListModel(QAbstractListModel):
opened = self.tr("Last Opened")
records = sorted(CONFIG.recentProjects.listEntries(), key=lambda x: x[3], reverse=True)
for path, title, count, time in records:
when = datetime.fromtimestamp(time).strftime("%x")
when = CONFIG.localDate(datetime.fromtimestamp(time))
data.append((title, path, f"{opened}: {when}, {words}: {formatInt(count)}"))
self._data = data
return