Bug 308674 - KDE ignores LC_TIME variable
Summary: KDE ignores LC_TIME variable
Status: ASSIGNED
Alias: None
Product: kdelibs
Classification: Frameworks and Libraries
Component: klocale (show other bugs)
Version: 4.9.2
Platform: Arch Linux Linux
: NOR wishlist
Target Milestone: ---
Assignee: John Layt
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-19 19:31 UTC by Kirill Gagarski
Modified: 2019-04-28 18:31 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kirill Gagarski 2012-10-19 19:31:55 UTC
Hi.
This is my 'locale' output:

LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME=ru_RU.UTF-8
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=

As you can see, I am using en_US locale for all except of time (I don't like AM/PM time format). The problem is that KDE using en_US for date and time too.
I understand that I can adjust date and time format in KDE System Settings. But shouldn't it be read from LC_TIME variable? Is there some reasons for current behaviour?

Reproducible: Always

Steps to Reproduce:
1. Set LC_TIME different to other locale variables
2. Start KDE

Actual Results:  
The time format is taken from some other of locale variables.

Expected Results:  
The time format is that was set in item (1.).
Comment 1 Chusslove Illich 2012-10-20 09:41:39 UTC
The reason for current behavior is that KDE does not use the GNU libc as its
locale system. GNU libc (or its forks) is the system C library on many free
operating systems; LC_* variables are settings for its locale system. Long
time ago (I don't know the exact historical context), KDE decided to create
its own locale system, which it has kept up to today. At the moment, there
is no true link between GNU libc locale system and KDE locale system.

In KDE 3 this was quite apparent, by user having to select explicitly a KDE
locale on first login, regardless of what LC_* variables were. In KDE 4 a
small compromise was introduced, to automatically select a KDE locale based
on the language and country from LC_* variables. But it still holds that, if
the user manually selects a particular language and country in the KDE
System Settings, LC_* variables are ignored thereafter.

Some larger changes in KDE locale system are planned for "KDE 5"
(approximatelly speaking, there will be no thing called exactly this), but
_from what I understood so far, they don't include extending the use of GNU
libc locale settings.