In computing, a locale is a set of parameters that defines the user's language, region and any special variant preferences that the user wants to see in their user interface. Usually a locale identifier consists of at least a language code and a country/region code. On POSIX platforms such as Unix, Linux and others, locale identifiers are defined by ISO/IEC 15897, which is similar to the BCP 47 definition of language tags, but the locale variant modifier is defined differently, and the character set is included as a part of the identifier. It is defined in this format: @modifier.
General locale settings
These settings usually include the following display format settings:
Number format setting
Character classification, case conversion settings
The locale settings are about formatting output given a locale. So, the time zone information and daylight saving time are not usually part of the locale settings. Less usual is the input format setting, which is mostly defined on a per application basis. Furthermore, the general settings usually include the keyboard layout setting.
and other Unicode-based environments, they are defined in a format similar to BCP 47. They are usually defined with just ISO 639 and ISO 3166-1 alpha-2 codes.
POSIX platforms
On POSIX platforms, locale identifiers are defined by ISO/IEC 15897, which is similar to the BCP 47 definition of language tags, but the locale variant modifier is defined differently, and the character set is included as a part of the identifier. In the next example there is an output of command locale for Czech language, Czech Republic with explicit UTF-8 encoding: $ locale LANG=cs_CZ.UTF-8 LC_CTYPE="cs_CZ.UTF-8" LC_NUMERIC="cs_CZ.UTF-8" LC_TIME="cs_CZ.UTF-8" LC_COLLATE="cs_CZ.UTF-8" LC_MONETARY="cs_CZ.UTF-8" LC_MESSAGES="cs_CZ.UTF-8" LC_PAPER="cs_CZ.UTF-8" LC_NAME="cs_CZ.UTF-8" LC_ADDRESS="cs_CZ.UTF-8" LC_TELEPHONE="cs_CZ.UTF-8" LC_MEASUREMENT="cs_CZ.UTF-8" LC_IDENTIFICATION="cs_CZ.UTF-8" LC_ALL=
Windows uses specific and strings. The locale identifier for unmanaged code on Microsoft Windows is a number such as 1033 for English or 1041 for Japanese. These numbers consist of a language code and culture code and are therefore often written in hexadecimal notation, such as 0x0409 or 0x0411. The list of those codesets are described in character encoding. Microsoft is starting to introduce managed codeapplication programming interfaces for.NET that use this format. One of the first to be generally released is a function to mitigate issues with internationalized domain names, but more are in Windows VistaBeta 1. Starting with Windows Vista, new functions that use BCP 47 locale names have been introduced to replace nearly all LCID-based APIs.