Languages, translations, locales, timezones, keyboard layouts and the lang-table

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

with the UI rewrite of the language selection, I would like to get rid of the lang-table, and most of the hardcoded language specific stuff. I got code that can find out all the translations we have available for anaconda in the runtime, and also code to get all available locales, with preferred timezones, native names, etc., and I'm trying to make it work together and put it to language.py.

So the 1st part is to get rid of lang-table and lang-names somehow. The 2nd part is to be able to preselect language/location/timezone to some sane defaults based on the geoip location, or language selection.

So I was looking at language.py, localeinfo.py and the lang-table file, and here's a sample line from lang-table:

Czech	cs	True	cs_CZ.UTF-8	cz-lat2	Europe/Prague

In my code I got "cs_CZ", "Czech" and "Europe/Prague" figured out. I also have the native language name, but some problems arise with the other columns.
What is the 2nd column (short name) for? Do we need it? And if yes, is there some standard where I can get this mapping? Most of the short names are just the language name from the locale, but there are some exceptions where we also use the territory part for the short name to differentiate between the languages, for example:

Chinese(Simplified)	zh_CN	False	zh_CN.UTF-8	us	Asia/Shanghai
Chinese(Traditional)	zh_TW	False	zh_TW.UTF-8	us	Asia/Taipei

or:

Portuguese	pt	True	pt_PT.UTF-8	pt-latin1	Europe/Lisbon
Portuguese(Brazilian)	pt_BR	True	pt_BR.UTF-8	br-abnt2	America/Sao_Paulo

Another problem is the 3rd column "text mode supported". Any ideas how we can get rid of this information from the lang-table?

The last part (5th column) is the preferred keyboard layout, which I think we can get from system-config-keyboard, as we do try in language.py now.

If anyone has some better ideas please let me know.

Thanks.

--

  Martin Gracik

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux