Details
-
Type:
Bug
-
Status: Open
-
Priority:
P2: Important
-
Resolution: Unresolved
-
Affects Version/s: 5.15.1
-
Fix Version/s: 6.2
-
Component/s: QML: Declarative and Javascript Engine
-
Labels:
-
Platform/s:
Description
If I use qsTr with conditional operator, it doesn't translate the string
Text{
property bool checked: true
text: checked? qsTr("Deselect all") : qsTr("Select all")
}
This is the workaround
Text{
property bool checked: true
property string deselectAllString: qsTr("Deselect all")
property string selectAllString: qsTr("Select all")
text: checked? deselectAllString : selectAllString
}