Krusader time display

139 visualizações
Pular para a primeira mensagem não lida

Udvarias Ur

não lida,
20 de ago. de 2019, 22:09:5620/08/2019
para Krusader users mailing list
Dear List,

How can I change the Krusader time display to a 24 hour format?

--------------------------------------------------------------------------------------------------------------

The system forces me to use the Canada (English) region, which is pretty
out to lunch because…

The developers of Linux OS time formatting system seem to have assumed
that every country / region uses ONLY ONE time format. This may be
correct in most parts of the world. It is NOT TRUE in Canada! (In fact
scientist, all over the world, use the 24 hour format and a YYYY-MM-DD
date format regardless of regional norms.)

1. Canada is a nation of immigrants, the huge majority of whom used the
24 hour time format before they arrived, and continue to use once they
are here.

2. Canada shares a very long border with the US. (To the best of my
knowledge one of the few countries in the world that still uses the 12
hour time format, with the exception of scientists.) As a result, we
here in (English) Canada, are a bit schizophrenic. Among ourselves, for
the most part, we use the 24 hour time format. When dealing with the US
we use the 12 hour time format. (That is especially true here in Québec.)

Another example of this is our calendars which have both Canadian and US
holidays on them.

--
Udvarias Ur

This letter was generated and sent from Thunderbird 60.5.1 on Ubuntu Linux 16.04.6 LTS.

Cette lettre a été générée et envoyée à partir de Thunderbird 60.5.1 sur Ubuntu Linux 16.04.6 LTS.

Yuri Chornoivan

não lida,
21 de ago. de 2019, 03:26:1521/08/2019
para krusade...@googlegroups.com
ср, 21 серп. 2019 о 05:09 Udvarias Ur <udva...@gmail.com> пише:
Dear List,

How can I change the Krusader time display to a 24 hour format?

--------------------------------------------------------------------------------------------------------------

The system forces me to use the Canada (English) region, which is pretty
out to lunch because…

The developers of Linux OS time formatting system seem to have assumed
that every country / region uses ONLY ONE time format. This may be
correct in most parts of the world. It is NOT TRUE in Canada! (In fact
scientist, all over the world, use the 24 hour format and a YYYY-MM-DD
date format regardless of regional norms.)

1. Canada is a nation of immigrants, the huge majority of whom used the
24 hour time format before they arrived, and continue to use once they
are here.

2. Canada shares a very long border with the US. (To the best of my
knowledge one of the few countries in the world that still uses the 12
hour time format, with the exception of scientists.) As a result, we
here in (English) Canada, are a bit schizophrenic. Among ourselves, for
the most part, we use the 24 hour time format. When dealing with the US
we use the 12 hour time format. (That is especially true here in Québec.)

Another example of this is our calendars which have both Canadian and US
holidays on them.
Hi,

Regretfully, there is no way to change the formatting system globally now [1].

On the other hand, it can be relatively easy to add the formatting control to Krusader itself [2, 3]. You can

1. Edit the source code (just add the format you need directly into the listmodel.cpp), recompile, install, and use it right now (that is very easy and instructive [4], just ask this list if you need some additional instructions).
For example, replace line 528 in listmodel.cpp
 return QLocale().toString(dateTime, QLocale::ShortFormat);
with
 return QLocale().toString(dateTime, "yyyy-MM-ddTHH:mm:ss");
Format data can be stolen from [5].
2. Implement an option for this on the "Panel" page of Konfigurator and send a review request through Phabricator [6]. Not that easy but manageable for anybody with very basic programming skills. Everybody with the same problem will be grateful to you.
3. Wait for someone to implement this feature. Easy but boring. ;)

Hope this helps.

Best regards,
Yuri

A. Bikadorov

não lida,
21 de ago. de 2019, 14:26:2921/08/2019
para krusade...@googlegroups.com
Hi,

it is much easier. With the switch to Qt 5 Krusader is using QLocale for date formatting
and Qt is deriving the date&time format from the LC_TIME variable.
So with
LC_TIME=en_US.UTF8 && krusader
I have the date/time in US format, or with
LC_TIME=de_DE.UTF-8 && krusader
in German format.

How to set this globally does depend on your Linux distribution.
If you only have user rights this could help:
https://wiki.archlinux.org/index.php/Locale#Overriding_system_locale_per_user_session

Cheers
Alex

On 21.08.19 09:26, Yuri Chornoivan wrote:
> ср, 21 серп. 2019 о 05:09 Udvarias Ur <udva...@gmail.com <mailto:udva...@gmail.com>> пише:
signature.asc

Rafael Linux User

não lida,
21 de ago. de 2019, 15:43:3321/08/2019
para krusader-users
Awesome workaround!!! That's is makes work a complex situation with an intelligent suggestion  ;)
Responder a todos
Responder ao autor
Encaminhar
0 nova mensagem