summaryrefslogtreecommitdiff
path: root/share/qtcreator/snippets/qml.xml
blob: eecb21dc4173509d908b9385870dc225791fc891 (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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
<?xml version="1.0" encoding="utf-8"?>
<snippets>
<snippet group="QML" trigger="property" id="qml_property">property $type$ $name$: $value$</snippet>
<snippet group="QML" trigger="Item" id="qml_item">Item {
    id: $name$
}</snippet>
<snippet group="QML" trigger="BorderImage" id="qml_borderimage">BorderImage {
    id: $name$
    source: "$file$"
    width: $100$; height: $100$
    border.left: $5$; border.top: $5$
    border.right: $5$; border.bottom: $5$
}</snippet>
<snippet  group="QML" trigger="Image" id="qml_image">Image {
    id: $name$
    source: "$file$"
}</snippet>
<snippet group="QML" trigger="Text" id="qml_text">Text {
    id: $name$
    text: qsTr("$text$")
}</snippet>
<snippet group="QML" trigger="states" id="qml_states">states: [
    State {
        name: "$name$"
        PropertyChanges {
            target: $object$
            $$
        }
    }
]</snippet>
<snippet group="QML" trigger="State" id="qml_state">State {
    name: "$name$"
    PropertyChanges {
        target: $object$
        $$
    }
}</snippet>
<snippet group="QML" trigger="transitions" id="qml_transitions">transitions: [
    Transition {
        from: "$fromState$"
        to: "$toState$"
        $$
     }
]</snippet>
<snippet group="QML" trigger="Transition" id="qml_transition">Transition {
    from: "$fromState$"
    to: "$toState$"
    $$
}</snippet>
<snippet group="QML" trigger="PropertyChanges" id="qml_propertychanges">PropertyChanges {
    target: $object$
    $$
}</snippet>
<snippet group="QML" trigger="NumberAnimation" id="qml_numberanimationwithtargets" complement="with targets">
NumberAnimation {
    targets: [$object$]
    properties: "$name$"
    duration: $200$
}</snippet>
<snippet group="QML" trigger="NumberAnimation" id="qml_numberanimationwithtarget" complement="with target">
NumberAnimation {
    target: $object$
    property: "$name$"
    duration: $200$
    easing.type: Easing.$InOutQuad$
}</snippet>
<snippet group="QML" trigger="PropertyAction" id="qml_propertyactionwithtargets" complement="with targets">
PropertyAction {
    targets: [$object$]
    properties: "$name$"
}</snippet>
<snippet group="QML" trigger="PropertyAction" id="qml_propertyactionwithtarget" complement="with target">
PropertyAction {
    target: $object$; property: "$name$" }</snippet>
<snippet group="QML" trigger="PauseAnimation" id="qml_pauseanimation">
PauseAnimation {
    duration: $200$
}</snippet>
<snippet group="QML" trigger="ColorAnimation" id="qml_coloranimation">
ColorAnimation {
    from: $"white"$
    to: $"black"$
    duration: $200$
}</snippet>
</snippets>