Beginning to make JLearner Work and a bit of Code clean up
This commit is contained in:
@@ -5,6 +5,7 @@ import Quickshell.Wayland
|
||||
import Quickshell.Hyprland
|
||||
import Quickshell.Io
|
||||
import "../../colors"
|
||||
import "./modules"
|
||||
|
||||
PanelWindow {
|
||||
id: learner
|
||||
@@ -18,7 +19,7 @@ PanelWindow {
|
||||
id: jLearnerScope
|
||||
focus: true
|
||||
|
||||
Keys.onReleased: {
|
||||
Keys.onReleased: function(event) {
|
||||
if (event.key === Qt.Key_Escape) {
|
||||
console.log("Pressed Escape, closing JLearner")
|
||||
jLearnerLoader.active = false
|
||||
@@ -40,5 +41,44 @@ PanelWindow {
|
||||
border.color: Colors.outlineVariant
|
||||
|
||||
clip: true
|
||||
|
||||
Column {
|
||||
id: window
|
||||
anchors.fill: parent
|
||||
spacing: 10
|
||||
|
||||
Rectangle {
|
||||
id: head
|
||||
width: window.width
|
||||
height: window.height * 0.1
|
||||
color: "#FFFFFF"
|
||||
|
||||
Text {
|
||||
text: "Language Learner"
|
||||
anchors.centerIn: parent
|
||||
font.pixelSize: 48
|
||||
color: "black"
|
||||
}
|
||||
}
|
||||
|
||||
function switch_KanaVoicing() {
|
||||
languageChooser.visible = false
|
||||
kanaVoicing.visible = true
|
||||
}
|
||||
|
||||
function switchModeChooser() {
|
||||
languageChooser.visible = true
|
||||
kanaVoicing.visible = false
|
||||
}
|
||||
|
||||
ModeChooser {
|
||||
id: languageChooser
|
||||
}
|
||||
|
||||
KanaVoicing {
|
||||
id: kanaVoicing
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user