blob: 849dc0bdd0c54154e875a83129bbf9ebf3cad67f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
import QtQuick 2.4
import QmlBench 1.0
// Tests the creation of FontMetrics with some simple props
CreationBenchmark {
id: root;
count: 50;
staticCount: 2500;
property string fontName: {
if (Qt.platform.os == "osx") {
return "Helvetica"
} else if (Qt.platform.os == "linux") {
return "Open Sans"
} else if (Qt.platform.os == "windows") {
return "Arial"
}
}
delegate: Item {
FontMetrics {
font.family: root.fontName
}
}
}
|