Set textFormat for the setting items to PlainText

Based on the Qt guide on making qml run much faster, it seems that the default of textFormatting (auto)
is quite expensive. As we make a *lot* of settingItems, which we don't want to format, it's better to set it to plain.
I haven't checked how much faster it actually is, but i didn't see visual changes, so it's at least a safe step.
This commit is contained in:
Jaime van Kessel 2018-09-20 15:22:35 +02:00
parent 6535f7890b
commit 2dbaa304a0
7 changed files with 12 additions and 3 deletions

View file

@ -39,10 +39,11 @@ Item
Label
{
id: globalProfileLabel
text: catalog.i18nc("@label","Profile:");
text: catalog.i18nc("@label","Profile:")
textFormat: Text.PlainText
width: Math.round(parent.width * 0.45 - UM.Theme.getSize("sidebar_margin").width - 2)
font: UM.Theme.getFont("default");
color: UM.Theme.getColor("text");
font: UM.Theme.getFont("default")
color: UM.Theme.getColor("text")
verticalAlignment: Text.AlignVCenter
anchors.top: parent.top
anchors.bottom: parent.bottom