I'm writing a reusable font property, as described here and here. Here's my property
property font button2: Qt.font({
family: defaultFont.name,
styleName: "Bold",
pointSize: 16
})
and here it how I use it, and it works fine
Text {
text: "button"
font: MyFont.button2
}
Now I would add the capitalization but adding it to the property like this
property font button2: Qt.font({
family: defaultFont.name,
styleName: "Bold",
capitalization: "AllUppercase",
pointSize: 16
})
It does not have effect at all. If I add it in the text component instead
Text {
text: "button"
font: MyFont.button2
font.capitalization: Font.AllUppercase
}
it gives me a "Property has already been assigned a value" error.
How should I do that?