W3C home > Mailing lists > Public > www-international@w3.org > October to December 2000

Re: 3-Letter Language Code

From: by way of <avine@iplanet.com>
Date: Wed, 27 Dec 2000 07:04:01 +0900
Message-Id: <>
To: www-international@w3.org

 > Robert Vanraamsdonk wrote:
 > Hi Saleindra,
 > I would advise you to:
 > 1) NOT use country identifiers in the filename extensions. You might
 > run into filename extension conflicts when you port to different
 > platforms, plus all translation vendors (and translation memory tools
 > for that matter) will expect RC files to be named with the *.rc
 > extension, as this very common resource file type is usually processed
 > natively. Also, changing the extension prevents persons handling the
 > file from meaningful interpretation of the nature and format of the
 > file.

I concur, and for another reason, language and country are not
necessarily connected (e.g. Switzerland).

 > 2) Introduce the notion of LOCALE into your file naming convention.
 > The locale identifier is a widely accepted standard in software
 > development and i18n for denoting specific region + language
 > combinations. The format for locales is a lowercase two-letter country
 > code (use ISO 639-1 for this), followed by and underscore '_' and an
 > uppercase two letter language code (use ISO 3166-1). For your *.RC
 > files, your filename would look something like  'xxxx_fr_FR.rc' for
 > French in France, 'xxxx_fr_CA.rc' for French in Canada. French is a
 > good example written and spoken French has some seriously different
 > rules for spelling, punctuation and more, depending whether you are in
 > France or Canada. There are many more examples (such as 'en_US' for US
 > English versus 'en_UK' for UK English), and would also neatly solve
 > your Chinese naming issue.

Small correction - for Great Britain (or United Kingdom, if you prefer)
the 2 letter code is GB, not UK.  Locales are useful in that they
specify both the language and the country, narrowing down the nature of
the resource file.  For example, a Swiss French (fr_CH) file will have
translations in French, but currency values in Swiss Francs.  More
information can be added to the locale, such as the charset, e.g.
fr_CH.ISO-8859-1, but this tends to be more common on the Unix side than
on the Windows side.

Andrea Vine
iPlanet i18n architect

 > -----Original Message-----
 > From: Shailendra Musale [mailto:shailendra.musale@f-secure.com]
 > Sent: Friday, December 22, 2000 7:59 PM
 > To: www-international@w3.org
 > Subject: 3-Letter Language Code
 > Hello all,
 > We name the localized (RC) files as "filename.xxx",
 > where xxx is 3-letter language code.
 > For example, a Japanese localized file will have a name as
 > "filename.jpn"
 > For these 3-letter codes, we are currently using
 > the country-code list available on following site:
 >   http://www.unicode.org/unicode/onlinedat/countries.html
 > We can't use language codes provided at
 >   http://www.unicode.org/unicode/onlinedat/languages.html
 > because they are 2-letter codes.
 > My questions regarding this are as follows:
 > 1) Is there any International-Standard
 >      List of 3-letter language codes - codes which
 >      can be used for all popular operating systems?
 > 2) If we choose to use Microsoft-provided (or Windows-specific)
 >      3-letter language codes and later if we come-up with UNIX-version
 >      of the software, then for UNIX platform, we have to modify some
 > of the
 > existing
 >      language codes, right? will there be any problems due to
 >      conflicts in language-codes?
 > 3) Which codes should we use for Simplified Chinese
 >      and Traditional Chinese?
 >      Is it CHS and CHT respectively?
 >      or CHN and TWN respectively?
 > Please advise.
 > Regards,
 > 22 December, 2000
 > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 > Shailendra Musale
Received on Tuesday, 26 December 2000 17:14:44 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 21 September 2016 22:37:20 UTC