From 8e84312242d7acb566874e536db80aa665cd78fe Mon Sep 17 00:00:00 2001 From: ppouchet <pierre.pouchet@etu.ec-lyon.fr> Date: Wed, 26 Mar 2025 22:01:56 +0100 Subject: [PATCH] =?UTF-8?q?Design=20+=20traitement=20dictionnaire=20fran?= =?UTF-8?q?=C3=A7ais?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Motus/Choosebutton.qml | 1 + Motus/LangageButton.qml | 11 ++- Motus/Main.qml | 130 ++++++++++++++++++++++------------- Motus/NumberLetterButton.qml | 4 +- 4 files changed, 95 insertions(+), 51 deletions(-) diff --git a/Motus/Choosebutton.qml b/Motus/Choosebutton.qml index c5b0fb0..bb95b7b 100644 --- a/Motus/Choosebutton.qml +++ b/Motus/Choosebutton.qml @@ -5,6 +5,7 @@ Item { property alias buttonText: button.text width: 300 height: 200 + Rectangle { id: rectangle x: 0 diff --git a/Motus/LangageButton.qml b/Motus/LangageButton.qml index 0695ab3..7ad8cd4 100644 --- a/Motus/LangageButton.qml +++ b/Motus/LangageButton.qml @@ -4,13 +4,20 @@ Item { width: 200 height: 100 property alias _textText: _text.text + + Rectangle { id: rectangle x: 0 y: 0 width: 200 height: 100 - color: "#b43737" + color: "#7a7a7a" + radius: 10 + border.color: "#ffffff" + border.width: 5 + + Text { id: _text @@ -18,10 +25,12 @@ Item { y: 0 width: 200 height: 100 + color: "#ffffff" text: qsTr("Langage") font.pixelSize: 30 horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter + font.family: "Tahoma" } } diff --git a/Motus/Main.qml b/Motus/Main.qml index 1eafbac..d08bb24 100644 --- a/Motus/Main.qml +++ b/Motus/Main.qml @@ -55,52 +55,6 @@ Window { } } - Rectangle { - id: rectangle2 - x: 1144 - y: 89 - width: 265 - height: 286 - color: "#ffffff" - - LangageButton { - id: langageButton - x: 33 - y: 32 - _textText: "Français" - - MouseArea { - id: mouseArea2 - x: 0 - y: 0 - width: 200 - height: 100 - onClicked: motusGame.dictionnaryChoosed="Motus\\mots_francais.txt" - - } - - - } - - LangageButton { - id: langageButton1 - x: 33 - y: 160 - _textText: "English" - - MouseArea { - id: mouseArea3 - x: 0 - y: 0 - width: 200 - height: 100 - onClicked: motusGame.dictionnaryChoosed="Motus\\words_alpha.txt" - - } - - } - } - MotusTimer { id: motusTimer x: 498 @@ -109,8 +63,8 @@ Window { NumberLetterButton { id: numberLetterButton - x: 1163 - y: 421 + x: 1165 + y: 299 } @@ -435,6 +389,86 @@ Window { } } } + + + Rectangle{ + + id: big_rectangle_langue + x: -360 + y: -107 + width: 270 + height: 340 + color: "#7a7a7a" + radius: 10 + border.color: "#ffffff" + border.width: 5 + + Rectangle { + id: rectangle_langue + x: 100 + y: 60 + width: 270 + height: 280 + color: "#323232" + radius: 10 + border.color: "#ffffff" + border.width: 5 + anchors.horizontalCenterOffset: 0 + anchors.horizontalCenter: parent.horizontalCenter + + LangageButton { + id: langageButton + x: 33 + y: 32 + _textText: "Français" + + MouseArea { + id: mouseArea2 + x: 0 + y: 0 + width: 200 + height: 100 + cursorShape: Qt.PointingHandCursor + onClicked: motusGame.dictionnaryChoosed="Motus\\mots_francais.txt" + + } + + + } + + LangageButton { + id: langageButton1 + x: 33 + y: 160 + _textText: "English" + + MouseArea { + id: mouseArea3 + anchors.fill: parent + cursorShape: Qt.PointingHandCursor + onClicked: motusGame.dictionnaryChoosed="Motus\\words_alpha.txt" + + } + + } + } + + Text { + id: _text + x: 0 + y: 0 + width: 270 + height: 63 + color: "#ffffff" + text: qsTr("Language/Langage") + font.pixelSize: 30 + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter + font.family: "Tahoma" + } + + + } } } diff --git a/Motus/NumberLetterButton.qml b/Motus/NumberLetterButton.qml index 4f40ac7..3387305 100644 --- a/Motus/NumberLetterButton.qml +++ b/Motus/NumberLetterButton.qml @@ -21,8 +21,8 @@ Item { width: 100 height: 50 flat: true - editable: true - model: ["aléatoire","5","6","7","8","9","10"] + editable: false + model: ["Aléatoire / Random","5","6","7","8","9","10"] displayText: "Number of letters" onCurrentTextChanged: { -- GitLab