From 85e21d84688f3f9ff8e86c527e880b94a96a37a8 Mon Sep 17 00:00:00 2001 From: emmaus Date: Mon, 8 Oct 2018 22:47:30 +0000 Subject: [PATCH] add controls ui --- Ryujinx.UI/UI/Views/Configuration.qml | 61 ++- Ryujinx.UI/UI/Views/ControlsSettings.qml | 72 +++ Ryujinx.UI/UI/Views/GamePadSettings.qml | 621 +++++++++++++++++++++++ Ryujinx.UI/UI/Views/KeyboardSettings.qml | 553 ++++++++++++++++++++ Ryujinx.UI/UI/Views/MiscSettings.qml | 47 +- 5 files changed, 1302 insertions(+), 52 deletions(-) create mode 100644 Ryujinx.UI/UI/Views/ControlsSettings.qml create mode 100644 Ryujinx.UI/UI/Views/GamePadSettings.qml create mode 100644 Ryujinx.UI/UI/Views/KeyboardSettings.qml diff --git a/Ryujinx.UI/UI/Views/Configuration.qml b/Ryujinx.UI/UI/Views/Configuration.qml index 33375c58e3..f7ac395617 100644 --- a/Ryujinx.UI/UI/Views/Configuration.qml +++ b/Ryujinx.UI/UI/Views/Configuration.qml @@ -12,50 +12,48 @@ Window { title: "Configuration" modality: Qt.ApplicationModal - Column{ + ColumnLayout { spacing: 10 id: contentColumn - height: configWindow.height - width: configWindow.width + anchors.rightMargin: 10 + anchors.leftMargin: 10 + anchors.bottomMargin: 10 + anchors.topMargin: 10 + anchors.fill: parent TabBar { id: configTabs + Layout.fillHeight: false + Layout.fillWidth: true currentIndex: 0 - height: 50 - width: parent.width TabButton { width: 80 - height: 50 text: qsTr("General") - checked: true } - /*TabButton { + TabButton { + width: 80 text: qsTr("Controls") - }*/ + } TabButton { - x: 80 - y: 0 width: 80 text: qsTr("Misc") - checked: false - height: 50 } } StackLayout { id: pagesView + Layout.fillHeight: true + Layout.fillWidth: true currentIndex: configTabs.currentIndex - width: contentColumn.width - height: contentColumn.height - - configTabs.height - - bottomRow.height - - (contentColumn.spacing * 3) + Item { id: genConfigPage + Layout.fillHeight: true + Layout.fillWidth: true Loader { source: "./GeneralSettings.qml" @@ -65,8 +63,23 @@ Window { } } + Item { + id: controlConfigPage + Layout.fillHeight: true + Layout.fillWidth: true + + Loader { + source: "./ControlsSettings.qml" + + width: pagesView.width + height: pagesView.height + } + } + Item { id: miscConfigPage + Layout.fillHeight: true + Layout.fillWidth: true Loader { source: "./MiscSettings.qml" @@ -74,19 +87,13 @@ Window { height: pagesView.height } } - - /*onIndexChanged: { - if(currentIndex !== configContent.currentIndex){ - configContent.currentIndex = currentIndex - } - }*/ } - Row { + RowLayout { spacing: 20 id: bottomRow - anchors.right: parent.right - anchors.rightMargin: 55 + Layout.alignment: Qt.AlignRight | Qt.AlignVCenter + Layout.fillWidth: true Button{ id: acceptButton diff --git a/Ryujinx.UI/UI/Views/ControlsSettings.qml b/Ryujinx.UI/UI/Views/ControlsSettings.qml new file mode 100644 index 0000000000..eab12ddbb3 --- /dev/null +++ b/Ryujinx.UI/UI/Views/ControlsSettings.qml @@ -0,0 +1,72 @@ +import QtQuick 2.0 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +Frame { + id: miscSettingsFrame + width: 500 + height: 480 + + ColumnLayout{ + id: column + spacing: 5 + anchors.fill: parent + + TabBar { + id: controllerTypesBar + currentIndex: 0 + + TabButton { + width: 80 + text: "Keyboard" + } + + TabButton { + width: 80 + text: "GamePad" + } + } + + StackLayout { + id: controllerStack + currentIndex: controllerTypesBar.currentIndex + clip: true + + Item { + id: keyboardSettings + Layout.fillHeight: true + Layout.fillWidth: true + + ScrollView { + anchors.fill: parent + + Loader { + anchors.fill: parent + source: "./KeyboardSettings.qml" + + width: controllerStack.width + height: controllerStack.height + } + } + } + + Item { + id: gamePadSettings + Layout.fillHeight: true + Layout.fillWidth: true + + ScrollView { + anchors.fill: parent + + Loader { + anchors.fill: parent + source: "./GamePadSettings.qml" + + width: controllerStack.width + height: controllerStack.height + } + } + } + } + } +} diff --git a/Ryujinx.UI/UI/Views/GamePadSettings.qml b/Ryujinx.UI/UI/Views/GamePadSettings.qml new file mode 100644 index 0000000000..6a1a7bb0d3 --- /dev/null +++ b/Ryujinx.UI/UI/Views/GamePadSettings.qml @@ -0,0 +1,621 @@ +import QtQuick 2.0 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +Frame { + id: gamePadSettingsFrame + + ColumnLayout { + anchors.fill: parent + + GroupBox { + Layout.fillHeight: false + title: qsTr("Options") + + ColumnLayout { + anchors.fill: parent + CheckBox { + id: enableGamePadCheckBox + text: "Enable GamePad" + } + + GridLayout { + Layout.fillHeight: true + Layout.fillWidth: true + columns: 2 + rows: 3 + + Label { + text: "GamePad Index" + Layout.fillHeight: false + Layout.fillWidth: true + Layout.column: 0 + Layout.row: 0 + } + + Label { + text: "Deadzone" + Layout.fillWidth: true + Layout.column: 0 + Layout.row: 1 + } + + Label { + text: "Trigger Threshold" + Layout.fillWidth: true + Layout.column: 0 + Layout.row: 2 + } + + TextField { + id: gamePadIndexBox + Layout.fillWidth: true + Layout.column: 1 + Layout.row:0 + inputMethodHints: Qt.ImhDigitsOnly + } + + TextField { + id: deadzoneBox + Layout.column: 1 + Layout.row:1 + inputMethodHints: Qt.ImhFormattedNumbersOnly + } + + TextField { + id: triggerThresholdBox + Layout.column: 1 + Layout.row:2 + inputMethodHints: Qt.ImhFormattedNumbersOnly + } + } + } + } + + RowLayout { + Layout.fillWidth: true + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Left Joy Con") + + ColumnLayout { + anchors.fill: parent + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Stick") + + GridLayout { + anchors.fill: parent + rows: 3 + columns: 3 + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 0 + Layout.column: 1 + + Label { + text: "Up" + } + + Button { + text: "Up" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickUpButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "Down" + } + + Button { + text: "Down" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickDownButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 0 + + Label { + text: "Left" + } + + Button { + text: "Left" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickLeftButton + } + + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 2 + + Label { + text: "Right" + } + + Button { + text: "Right" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickRightButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 1 + + Label { + text: "Button" + } + + Button { + text: "Button" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickButton + } + } + } + } + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("D-Pad") + + GridLayout { + anchors.fill: parent + rows: 3 + columns: 3 + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 0 + Layout.column: 1 + + Label { + text: "Up" + } + + Button { + text: "Up" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftDPadUpButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "Down" + } + + Button { + text: "Down" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftDPadDownButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 0 + + Label { + text: "Left" + } + + Button { + text: "Left" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftDPadLeftButton + } + + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 2 + + Label { + text: "Right" + } + + Button { + text: "Right" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftDPadRightButton + } + } + } + } + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Buttons") + + ColumnLayout { + anchors.fill: parent + + RowLayout { + Layout.fillHeight: true + Layout.fillWidth: true + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "L" + } + + Button { + text: "L" + Layout.fillHeight: true + Layout.fillWidth: true + id: lButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "ZL" + } + + Button { + text: "ZL" + Layout.fillHeight: true + Layout.fillWidth: true + id: zLButton + } + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "-" + } + + Button { + text: "-" + Layout.fillHeight: true + Layout.fillWidth: true + id: minusButton + } + } + } + } + } + } + } + + ColumnLayout { + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Right Joy Con") + + ColumnLayout { + anchors.fill: parent + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Stick") + + GridLayout { + anchors.fill: parent + rows: 3 + columns: 3 + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 0 + Layout.column: 1 + + Label { + text: "Up" + } + + Button { + text: "Up" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickUpButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "Down" + } + + Button { + text: "Down" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickDownButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 0 + + Label { + text: "Left" + } + + Button { + text: "Left" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickLeftButton + } + + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 2 + + Label { + text: "Right" + } + + Button { + text: "Right" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickRightButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 1 + + Label { + text: "Button" + } + + Button { + text: "Button" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickButton + } + } + } + } + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Main Buttons") + + GridLayout { + anchors.fill: parent + rows: 3 + columns: 3 + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 0 + Layout.column: 1 + + Label { + text: "X" + } + + Button { + text: "X" + Layout.fillHeight: true + Layout.fillWidth: true + id: xButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "B" + } + + Button { + text: "B" + Layout.fillHeight: true + Layout.fillWidth: true + id: bButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 0 + + Label { + text: "Y" + } + + Button { + text: "Y" + Layout.fillHeight: true + Layout.fillWidth: true + id: yButton + } + + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 2 + + Label { + text: "A" + } + + Button { + text: "A" + Layout.fillHeight: true + Layout.fillWidth: true + id: aButton + } + } + } + } + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Extra Buttons") + + ColumnLayout { + anchors.fill: parent + + RowLayout { + Layout.fillHeight: true + Layout.fillWidth: true + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "R" + } + + Button { + text: "L" + Layout.fillHeight: true + Layout.fillWidth: true + id: rButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "ZR" + } + + Button { + text: "ZL" + Layout.fillHeight: true + Layout.fillWidth: true + id: zRButton + } + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "+" + } + + Button { + text: "+" + Layout.fillHeight: true + Layout.fillWidth: true + id: plusButton + } + } + } + } + } + } + } + } + + } +} diff --git a/Ryujinx.UI/UI/Views/KeyboardSettings.qml b/Ryujinx.UI/UI/Views/KeyboardSettings.qml new file mode 100644 index 0000000000..972141aeec --- /dev/null +++ b/Ryujinx.UI/UI/Views/KeyboardSettings.qml @@ -0,0 +1,553 @@ +import QtQuick 2.0 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +Frame { + id: keyboardSettingsFrame + width: 800 + height: 600 + + RowLayout { + anchors.fill: parent + + + ColumnLayout { + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Left Joy Con") + + ColumnLayout { + anchors.fill: parent + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Stick") + + GridLayout { + anchors.fill: parent + rows: 3 + columns: 3 + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 0 + Layout.column: 1 + + Label { + text: "Up" + } + + Button { + text: "Up" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickUpButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "Down" + } + + Button { + text: "Down" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickDownButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 0 + + Label { + text: "Left" + } + + Button { + text: "Left" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickLeftButton + } + + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 2 + + Label { + text: "Right" + } + + Button { + text: "Right" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickRightButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 1 + + Label { + text: "Button" + } + + Button { + text: "Button" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftStickButton + } + } + } + } + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("D-Pad") + + GridLayout { + anchors.fill: parent + rows: 3 + columns: 3 + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 0 + Layout.column: 1 + + Label { + text: "Up" + } + + Button { + text: "Up" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftDPadUpButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "Down" + } + + Button { + text: "Down" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftDPadDownButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 0 + + Label { + text: "Left" + } + + Button { + text: "Left" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftDPadLeftButton + } + + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 2 + + Label { + text: "Right" + } + + Button { + text: "Right" + Layout.fillHeight: true + Layout.fillWidth: true + id: leftDPadRightButton + } + } + } + } + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Buttons") + + ColumnLayout { + anchors.fill: parent + + RowLayout { + Layout.fillHeight: true + Layout.fillWidth: true + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "L" + } + + Button { + text: "L" + Layout.fillHeight: true + Layout.fillWidth: true + id: lButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "ZL" + } + + Button { + text: "ZL" + Layout.fillHeight: true + Layout.fillWidth: true + id: zLButton + } + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "-" + } + + Button { + text: "-" + Layout.fillHeight: true + Layout.fillWidth: true + id: minusButton + } + } + } + } + } + } + } + + ColumnLayout { + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Right Joy Con") + + ColumnLayout { + anchors.fill: parent + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Stick") + + GridLayout { + anchors.fill: parent + rows: 3 + columns: 3 + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 0 + Layout.column: 1 + + Label { + text: "Up" + } + + Button { + text: "Up" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickUpButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "Down" + } + + Button { + text: "Down" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickDownButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 0 + + Label { + text: "Left" + } + + Button { + text: "Left" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickLeftButton + } + + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 2 + + Label { + text: "Right" + } + + Button { + text: "Right" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickRightButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 1 + + Label { + text: "Button" + } + + Button { + text: "Button" + Layout.fillHeight: true + Layout.fillWidth: true + id: rightStickButton + } + } + } + } + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Main Buttons") + + GridLayout { + anchors.fill: parent + rows: 3 + columns: 3 + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 0 + Layout.column: 1 + + Label { + text: "X" + } + + Button { + text: "X" + Layout.fillHeight: true + Layout.fillWidth: true + id: xButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "B" + } + + Button { + text: "B" + Layout.fillHeight: true + Layout.fillWidth: true + id: bButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 0 + + Label { + text: "Y" + } + + Button { + text: "Y" + Layout.fillHeight: true + Layout.fillWidth: true + id: yButton + } + + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 1 + Layout.column: 2 + + Label { + text: "A" + } + + Button { + text: "A" + Layout.fillHeight: true + Layout.fillWidth: true + id: aButton + } + } + } + } + + GroupBox { + Layout.fillHeight: true + Layout.fillWidth: true + title: qsTr("Extra Buttons") + + ColumnLayout { + anchors.fill: parent + + RowLayout { + Layout.fillHeight: true + Layout.fillWidth: true + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "R" + } + + Button { + text: "L" + Layout.fillHeight: true + Layout.fillWidth: true + id: rButton + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "ZR" + } + + Button { + text: "ZL" + Layout.fillHeight: true + Layout.fillWidth: true + id: zRButton + } + } + } + + ColumnLayout { + Layout.fillHeight: true + Layout.fillWidth: true + Layout.row: 2 + Layout.column: 1 + + Label { + text: "+" + } + + Button { + text: "+" + Layout.fillHeight: true + Layout.fillWidth: true + id: plusButton + } + } + } + } + } + } + } + } +} diff --git a/Ryujinx.UI/UI/Views/MiscSettings.qml b/Ryujinx.UI/UI/Views/MiscSettings.qml index 81f957e445..50ec0bc944 100644 --- a/Ryujinx.UI/UI/Views/MiscSettings.qml +++ b/Ryujinx.UI/UI/Views/MiscSettings.qml @@ -6,33 +6,40 @@ Frame { id: miscSettingsFrame width: 500 height: 480 - Column{ + ColumnLayout { anchors.fill: parent GroupBox { - anchors.fill: parent + Layout.alignment: Qt.AlignLeft | Qt.AlignTop + Layout.fillHeight: false + Layout.fillWidth: true title: qsTr("Logging") - Column { + ColumnLayout { id: column anchors.fill: parent CheckBox { id: loggingCheckBox text: "Enable Logging" + Layout.fillHeight: false + Layout.fillWidth: true } - Row { + RowLayout { id: row - anchors.top: loggingCheckBox.bottom - anchors.topMargin: 0 + Layout.alignment: Qt.AlignLeft | Qt.AlignTop + Layout.fillHeight: false + Layout.fillWidth: true + GroupBox { id: logLevelsGroup + Layout.fillHeight: true + Layout.alignment: Qt.AlignLeft | Qt.AlignTop + Layout.fillWidth: false title: qsTr("Log Levels") - Column { - anchors.fill: parent - + ColumnLayout { CheckBox { id: debugLogCheckBox text: "Debug" @@ -62,21 +69,16 @@ Frame { GroupBox { id: groupBox - anchors.left: logLevelsGroup.right - anchors.leftMargin: 0 title: qsTr("Log Classes") - width: Math.min(200, column.width - logLevelsGroup.width) - 20 - height: logLevelsGroup.height + Layout.fillHeight: true + Layout.fillWidth: true - Column { - id: column1 + TextEdit { + id: logClassesTextArea + selectionColor: "#004a80" + renderType: Text.NativeRendering anchors.fill: parent - TextArea { - id: logClassesTextArea - anchors.fill: parent - - } } } @@ -85,8 +87,3 @@ Frame { } } } - -/*##^## Designer { - D{i:29;anchors_height:-243;anchors_width:-111}D{i:4;anchors_height:0;anchors_width:0} -} - ##^##*/