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

Expose currency symbols from ISO4217 codes

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Unresolved
    • Not Evaluated
    • None
    • None
    • Active Qt
    • None

    Description

      QLocale has good support for iso4217 currency codes (USD, GBP, EUR,...) and it's already possible to retrieve the current currency symbol using `currencySymbol()`. But it's not possible to retrieve other currency symbols.

      Currency symbols are not unique. They depend on the system "locale". For example, "$" means USD in some countries, in others, it is "US$".

       

      I suggest a method to retrieve other currency symbols from a `QLocale`.

       

      Example:
      Let's say that the current locale is "fr_FR". Currency: EUR, currency symbol "€". How to create a string with the currency USD and the symbol "$"?
      Now, let's say I change locale and I pick Saint Lucia ("en-LC"). The same string should be using the symbol "US$".
      Generalizing, how to create a string using a currency value in ISO4217 (`QLocale::CurrencyIsoCode`)?

      Attachments

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

        Activity

          People

            laknoll Lars Knoll
            baku Andrea Marchesini
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes