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

Add qTrId() alias for qtTrId()

XMLWordPrintable

    • Icon: User Story User Story
    • Resolution: Unresolved
    • Icon: P3: Somewhat important P3: Somewhat important
    • None
    • 6.9
    • Tools: Linguist
    • None
    • All

      For id-based translations in C++ code we have the function qtTrId. It was introduced with the following comment:

      // Defined in qcoreapplication.cpp
      // The better name qTrId() is reserved for an upcoming function which would
      // return a much more powerful QStringFormatter instead of a QString.
      Q_CORE_EXPORT QString qtTrId(const char *id, int n = -1);
      

      QStringFormatter never materialized, though. See https://lists.qt-project.org/pipermail/development/2017-August/030677.html

      Standard C++ has std::format now, but it's questionable whether qTrId should wrap it or aid format strings in another way.

      Consider adding qTrId as alias for qtTrId.
      Or at least remove the comment.

        For Gerrit Dashboard: QTBUG-134544
        # Subject Branch Project Status CR V

            masoud.jami Masoud Jami
            jbornema Joerg Bornemann
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:

                There are 2 open Gerrit changes