Details
-
Suggestion
-
Resolution: Unresolved
-
P3: Somewhat important
-
6.3.0, 6.8.0 FF
Description
The overload of QString::arg() in C++ that gives possibility to substitute arguments in one pass is very useful.
See https://doc.qt.io/qt-5/qstring.html#arg-14 for motivation.
Unfortunately this isn't supported in QML.
Simple,
readonly property string text: '%1, %2'.arg('Hello', 'world!')
in Qt 6.3.0 generates error
Error: String.arg(): Invalid arguments
So the suggestion is to make it available in QML as well.
Attachments
Issue Links
- relates to
-
QTBUG-101387 Provide specialization for qsTr and string.arg()
-
- Closed
-