diff --git a/Motus/Case.qml b/Motus/Case.qml index 6b531453d122e55b532f38c84a361f471b357a99..950811467882a02af55bb017cb726bf802725978 100644 --- a/Motus/Case.qml +++ b/Motus/Case.qml @@ -3,8 +3,10 @@ import QtQuick Item { width: 90 height: 90 + property alias _textColor: _text.color property alias _textText: _text.text + Text { id: _text x: 0 diff --git a/Motus/Main.qml b/Motus/Main.qml index 6c465af22717929a4d94729facaa09f2fcdd73e3..c78bee2fd5a49b901ada3197dde701caf0cc2bc8 100644 --- a/Motus/Main.qml +++ b/Motus/Main.qml @@ -34,6 +34,20 @@ Window { x: 76 y: 47 _textText: "Générer un mot" + + MouseArea { + id: mouseArea + x: 0 + y: 0 + width: 400 + height: 200 + onClicked: case3._textColor="#51c3e1" + + Case { + id: case3 + _textText: "test" + } + } } Rectangle {