aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp
diff options
context:
space:
mode:
authorSafiyyah Moosa <safiyyah.moosa@qt.io>2024-09-11 14:07:21 +0200
committerSafiyyah Moosa <safiyyah.moosa@qt.io>2024-09-23 20:06:54 +0200
commit9005a3551a3a0c170980890eecb4a8cf89f0a28c (patch)
treed9195a8c6fc69f28dd422c4ba16c81b35660e462 /tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp
parent98459ff5a3e2988c24a79edd919f1acf29dae344 (diff)
Doc: Clarify the use of qsTranslate()
There are two QT QML types that can be used for translations, namely, qsTr() and qsTranslate(). This change adds a description to the docs to help the user determine when to use qsTranslate() over qsTr(). qsTranslate() takes an explicit context as its first argument, whereas qsTr() takes the text to be translated as its first argument. If the user has a translation context that differs from the file context for some strings, then it would be better to use qsTranslate() for those strings. Fixes: QTBUG-127796 Pick-to: 6.7 6.8 Change-Id: Ic7d44228f293666c112ecf47cf989ce2617f71e0 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp')
0 files changed, 0 insertions, 0 deletions