From f16cde45559827af426452c7545d4a42ea9bded5 Mon Sep 17 00:00:00 2001 From: Samuel Fadel Date: Fri, 15 Jan 2016 13:58:41 +0100 Subject: QML: added components for handling selection modes in the future. --- main_view.qml | 43 ++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 40 insertions(+), 3 deletions(-) (limited to 'main_view.qml') diff --git a/main_view.qml b/main_view.qml index 3ea6fc7..a0290e1 100644 --- a/main_view.qml +++ b/main_view.qml @@ -46,6 +46,18 @@ ApplicationWindow { } } + Menu { + title: "Mode" + MenuItem { + action: cpModeAction + exclusiveGroup: modeGroup + } + MenuItem { + action: rpModeAction + exclusiveGroup: modeGroup + } + } + Menu { title: "View" MenuItem { @@ -67,6 +79,16 @@ ApplicationWindow { } } + statusBar: StatusBar { + RowLayout { + anchors.fill: parent + Label { + id: statusLabel + text: "Selecting control points" + } + } + } + ColumnLayout { spacing: 10 anchors.fill: parent @@ -147,7 +169,6 @@ ApplicationWindow { Main.setTechnique(InteractionHandler.TECHNIQUE_LAMP) } } - Action { id: lspTechniqueAction text: "LSP" @@ -157,7 +178,6 @@ ApplicationWindow { Main.setTechnique(InteractionHandler.TECHNIQUE_LSP) } } - Action { id: plmpTechniqueAction text: "PLMP" @@ -167,7 +187,6 @@ ApplicationWindow { Main.setTechnique(InteractionHandler.TECHNIQUE_PLMP) } } - Action { id: pekalskaTechniqueAction text: "Pekalska" @@ -179,6 +198,24 @@ ApplicationWindow { } } + ExclusiveGroup { + id: modeGroup + + Action { + id: cpModeAction + text: "Control points" + checked: true + checkable: true + onTriggered: statusLabel.text = "Selecting control points" + } + Action { + id: rpModeAction + text: "Regular points" + checkable: true + onTriggered: statusLabel.text = "Selecting regular points" + } + } + ExclusiveGroup { id: coloringGroup -- cgit v1.2.3