diff --git a/changes b/changes index aa5867727c0ccda0642d5fd99dd6ba0ca78dcf59..c867efc4d756c1148b61845172300d708b43a83f 100644 --- a/changes +++ b/changes @@ -1,6 +1,7 @@ 1.5.2 alpha3 - extended grand staff, beaming notes on every staff separately - score supports bowing symbols, read them from XML + - keyboard shortcuts for changing rhythm, accidentals, etc. - all playing routines moved to separate thread - improved level creator diff --git a/src/qml/settings/InstrumentPage.qml b/src/qml/settings/InstrumentPage.qml index a22d1407bfd392d428117f62ee615440e416b110..e7d1ec7f7e61eaa488930584164ce2cb27554e7b 100644 --- a/src/qml/settings/InstrumentPage.qml +++ b/src/qml/settings/InstrumentPage.qml @@ -91,6 +91,11 @@ Flickable { } Score { id: score +// onFocusChanged: { // FIXME: workaround to make score keyboard shortcuts working, but it stop other controls TAB navigation +// if (!focus) +// focus = true +// } +// bgRect.border { width: score.activeFocus ? 2 : 0; color: activPal.highlight } height: Noo.fontSize() * 20 width: Math.min(parent.width * 0.9, Noo.fontSize() * 26) anchors.horizontalCenter: parent.horizontalCenter @@ -100,6 +105,7 @@ Flickable { Component.onCompleted: { stringNrSpin.valueModified.connect(strNrChanged) tuningCombo.activated.connect(tuningSelected) + focus = true } function strNrChanged() { if (stringNrSpin.value > score.notesCount) { diff --git a/src/qml/shared/TcheckBox.qml b/src/qml/shared/TcheckBox.qml index d51c8fce0a425e8e2a348e4bf003bcd8a6aa3bee..c53f596f9de33533e9fbf5f1738d73430c51ccce 100755 --- a/src/qml/shared/TcheckBox.qml +++ b/src/qml/shared/TcheckBox.qml @@ -18,7 +18,10 @@ CheckBox { x: chB.leftPadding y: chB.height / 2 - height / 2 radius: Noo.fontSize() * 0.1 - border.color: chB.enabled ? (chB.down ? activPal.highlight : activPal.dark) : disdPal.text + border { + color: chB.enabled ? (chB.down ? activPal.highlight : activPal.dark) : disdPal.text + width: chB.activeFocus ? 3 : 1 + } color: chB.enabled ? activPal.base : disdPal.base Rectangle { @@ -38,6 +41,6 @@ CheckBox { y: (chB.height - height) / 2 leftPadding: indicator.width + font.pixelSize / 2 color: chB.enabled ? activPal.text : disdPal.text - font { family: chB.font.family; pixelSize: chB.font.pixelSize } + font { family: chB.font.family; pixelSize: chB.font.pixelSize; bold: chB.activeFocus } } } diff --git a/src/qml/shared/TcuteButton.qml b/src/qml/shared/TcuteButton.qml index 86444185d02d683bef5b19c8ac47fc91c97a0f83..7f910445fdced81147a51b51f83da1977577715f 100644 --- a/src/qml/shared/TcuteButton.qml +++ b/src/qml/shared/TcuteButton.qml @@ -8,7 +8,8 @@ import QtQuick.Controls 2.2 AbstractButton { id: root - font.pixelSize: Noo.fontSize() + font { pixelSize: Noo.fontSize(); bold: activeFocus } + focus: true property alias radius: bg.radius property alias color: bg.color diff --git a/src/qml/shared/TiconButton.qml b/src/qml/shared/TiconButton.qml index 1cc6c46a54b21e88ebc78e19ebce12b4de5fff30..462025a2aeb4f729d52650f5b18a95ade0894078 100644 --- a/src/qml/shared/TiconButton.qml +++ b/src/qml/shared/TiconButton.qml @@ -1,5 +1,5 @@ /** This file is part of Nootka (http://nootka.sf.net) * - * Copyright (C) 2017 by Tomasz Bojczuk (seelook@gmail.com) * + * Copyright (C) 2017-2018 by Tomasz Bojczuk (seelook@gmail.com) * * on the terms of GNU GPLv3 license (http://www.gnu.org/licenses) */ import QtQuick 2.9 @@ -8,7 +8,8 @@ import QtQuick.Controls 2.2 AbstractButton { id: root - font.pixelSize: Noo.fontSize() + font { pixelSize: Noo.fontSize(); bold: activeFocus } + focus: true property alias radius: bg.radius property alias color: bg.color @@ -24,6 +25,7 @@ AbstractButton { id: img sourceSize.height: Noo.fontSize() * 2 anchors.verticalCenter: parent.verticalCenter + scale: root.activeFocus ? 1.1 : 1.0 } Text { padding: Noo.fontSize() / 3