Bug 45256 - Meaning of LANG/LC_* only partially overrideable from Control Center.
Summary: Meaning of LANG/LC_* only partially overrideable from Control Center.
Status: RESOLVED INTENTIONAL
Alias: None
Product: kcontrol
Classification: Miscellaneous
Component: general (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Daniel Molkentin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-07-15 20:18 UTC by egmont
Modified: 2005-03-08 18:13 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 egmont 2002-07-15 20:16:01 UTC
(*** This bug was imported into bugs.kde.org ***)

Package:           kcontrol
Version:           KDE 3.0.0 
Severity:          normal
Installed from:    SuSE RPMs
Compiler:          gcc 2.95.3
OS:                Linux
OS/Compiler notes: Not Specified

Traditional Linux applications use LANG and LC_* env variables to determine the language.

KDE primarly uses the value set in the Control Center most of the time but not always. This approach is the worst possible design I guess either KDE should override/ignore all the LANG/LC_* variables or should only use those ones (and then Control Center could _set_ these values for the launched applications).

This inconsistency leads to the following two bugs or let's rather say consequences. (Sorry I write two bugs in one entry since this design misconception is IMHO much more important than the two bugs themselves which are only consequences of the same brain-damaged design).

Bug1. If all your LANG and LC_* environment variables refer to a Latin-1 language (e.g. the system administrator has set English or similar as default language) and then KDE is set to Hungarian (which is Latin-2) then accented letters are printed as question marks in window titles. Launch "Vezerlokozpont" (Control Center) from the K-menu. This word has an odoubleacute in it. The word appears correctly in the K-menu and on icon bar while the application window is not yet visible. As soon as it gets visible the icon bar changes to "Vezerl?kozpont" and the window titlebar will have this same string with an "?" instead of odoubleacute. If LC_CTYPE=hu_HU is set before KDE is launched this word always appears correctly. Then I wonder why KDE's language choosing utility is there if LC_CTYPE can override its settings. Consider a single user s/he won't ever find out why things are bad and how to fix those accents.

Bug2. File sorting order is determined based on LC_COLLATE not on the languages given in the Control Center. Even if I choose Hungarian language file names are sorted with accent letters at the end in Konqueror. This is because SuSE sets LC_COLLATE=POSIX. (They do have their reason for it e.g. the pattern [a-z]* matches a A b B ... z but not Z which really sucks in shell scripts if LC_COLLATE is set to a specific language.) However if I set LC_COLLATE=hu_HU konqueror sorts files in perfect Hungarian alphabetical order. If there is a language choosing utility in Control Center it should set the sorting method too a beginner user won't ever bother with setting environment variables s/he needs click-click-style settings of the sorting.


(Submitted via bugs.kde.org)
Comment 1 Daniel Molkentin 2002-09-13 10:49:13 UTC
This needs to be changed in a major release -- if at all. The problem with this is that it is dangerous to make any settings from the GUI, and just accepting the systems variables is not exactly userfriendly. This needs some communication and input from Distributors.