Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-97513

Teach QLocale to recognise known aliases for languages and territories

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Unresolved
    • P2: Important
    • None
    • 6.2
    • Core: Locales (i18n)
    • None
    • All

    Description

      Prompted by recent discussion on a code review:

      There are assorted international standards for language and territory codes, some with two letter codes, some three letter codes (e.g. ISO 639-2), possibly others. CLDR's common/supplemental/supplementalMetadata.xml contains a supplementalData/metadata/alias/ element that contains languageAlias, territoryAlias and (at least for now just one) scriptAlias elements (apparently generated by something called CountItems), 1144 of them in all (in v39), that would also be sensible sources of aliases for the tags used by CLDR and thus QLocale.
      Probably some of these can be filtered out by virtue of mapping to codes we don't actually support (due to CLDR providing no actual locale data for them).
      If we can obtain a suitably robust script-parseable source for data from other international standards, we could include data taken from these.

      Including suitably-designed alias tables for these in qlocale_data_p.h would enable QLocale to recognise these codes when parsing language, script and territory tags in locale specifications from some sources that we otherwise fail to understand, improving interoperability.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              cnn Qt Core & Network
              Eddy Edward Welbourne
              Vladimir Minenko Vladimir Minenko
              Alex Blasche Alex Blasche
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes