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

Support translation bindings in qmltc

    XMLWordPrintable

Details

    Description

      qmltc must be able to correctly handle translation bindings such as:

      Text { text: qsTr("hello") } // should be translated in German to "hallo" (?)
      

      There are several ways on how to create translation bindings. The interesting functions are part of the Qt QML. The exhaustive list should be:

      • string qsTr(string sourceText, string disambiguation, int n)
      • string qsTrId(string id, int n)
      • string qsTrIdNoOp(string id)
      • string qsTrNoOp(string sourceText, string disambiguation)
      • string qsTranslate(string context, string sourceText, string disambiguation, int n)
      • string qsTranslateNoOp(string context, string sourceText, string disambiguation)

      At the code level, qmltc should be able to compile QQmlJSMetaPropertyBinding (coming from QQmlJSScope) into something meaningful when the binding type is one of

      {Translation, TranslationById}

      .

      Attachments

        Issue Links

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

          Activity

            People

              sami.shalayel Sami Shalayel
              agolubev Andrei Golubev
              Vladimir Minenko Vladimir Minenko
              Fabian Kosmale Fabian Kosmale
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes