From a42c6a1ebba9a35fc487fa1d6f2a0158cba04298 Mon Sep 17 00:00:00 2001 From: Flavio Carrara Date: Sun, 2 Mar 2025 19:14:56 -0300 Subject: [PATCH 1/5] Added transparency keybind, fixed on Ctrl+Shift+Up and Ctrl+Shift+Down --- app/qml/TerminalContainer.qml | 3 ++- app/qml/main.qml | 18 ++++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/app/qml/TerminalContainer.qml b/app/qml/TerminalContainer.qml index b6be4359..36cd898a 100644 --- a/app/qml/TerminalContainer.qml +++ b/app/qml/TerminalContainer.qml @@ -29,7 +29,8 @@ ShaderTerminal { property real devicePixelRatio: terminalWindow.screen.devicePixelRatio id: mainShader - opacity: appSettings.windowOpacity * 0.3 + 0.7 + + opacity: appSettings.windowOpacity + 0.001 source: terminal.mainSource burnInEffect: terminal.burnInEffect diff --git a/app/qml/main.qml b/app/qml/main.qml index 8ae07743..3d76e547 100644 --- a/app/qml/main.qml +++ b/app/qml/main.qml @@ -29,6 +29,8 @@ ApplicationWindow { width: 1024 height: 768 + property real keybindStep: 0.005 + // Save window properties automatically onXChanged: appSettings.x = x onYChanged: appSettings.y = y @@ -128,6 +130,22 @@ ApplicationWindow { shortcut: "Ctrl+-" onTriggered: appSettings.decrementScaling() } + Action { + id: lessOpaque + text: qsTr("Make less opaque.") + shortcut: "Ctrl+Shift+Up" + onTriggered: { + appSettings.windowOpacity -= appSettings.windowOpacity > keybindStep ? keybindStep : 0 + } + } + Action { + id: moreOpaque + text: qsTr("Make more opaque.") + shortcut: "Ctrl+Shift+Down" + onTriggered: { + appSettings.windowOpacity += appSettings.windowOpacity < (2 - keybindStep) ? keybindStep : 0 + } + } Action { id: showAboutAction text: qsTr("About") From bcdf0cea17d0b0f1e04079b788c8877affac1c4a Mon Sep 17 00:00:00 2001 From: fde-capu Date: Sun, 2 Mar 2025 21:20:37 -0300 Subject: [PATCH 2/5] Steeper step and max correction. --- app/qml/main.qml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/qml/main.qml b/app/qml/main.qml index 3d76e547..9586ced1 100644 --- a/app/qml/main.qml +++ b/app/qml/main.qml @@ -29,7 +29,7 @@ ApplicationWindow { width: 1024 height: 768 - property real keybindStep: 0.005 + property real keybindStep: 0.01 // Save window properties automatically onXChanged: appSettings.x = x @@ -143,7 +143,7 @@ ApplicationWindow { text: qsTr("Make more opaque.") shortcut: "Ctrl+Shift+Down" onTriggered: { - appSettings.windowOpacity += appSettings.windowOpacity < (2 - keybindStep) ? keybindStep : 0 + appSettings.windowOpacity += appSettings.windowOpacity < (1 - keybindStep) ? keybindStep : 0 } } Action { From 9aaca6252796894768ecf30d1e4524fdf5629b5f Mon Sep 17 00:00:00 2001 From: fde-capu Date: Sun, 2 Mar 2025 22:17:08 -0300 Subject: [PATCH 3/5] Contrast bind set to Ctrl+Up, Ctrl+Down. --- app/qml/main.qml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/app/qml/main.qml b/app/qml/main.qml index 9586ced1..0811f9c5 100644 --- a/app/qml/main.qml +++ b/app/qml/main.qml @@ -146,6 +146,22 @@ ApplicationWindow { appSettings.windowOpacity += appSettings.windowOpacity < (1 - keybindStep) ? keybindStep : 0 } } + Action { + id: moreContrast + text: qsTr("More contrast.") + shortcut: "Ctrl+Up" + onTriggered: { + appSettings.contrast += appSettings.contrast < (1 - keybindStep) ? keybindStep : 0 + } + } + Action { + id: lessContrast + text: qsTr("Less contrast.") + shortcut: "Ctrl+Down" + onTriggered: { + appSettings.contrast -= appSettings.contrast > keybindStep ? keybindStep : 0 + } + } Action { id: showAboutAction text: qsTr("About") From 64f2b6a14afa39750cb4100d0c7a5e6baee05942 Mon Sep 17 00:00:00 2001 From: fde-capu Date: Sun, 2 Mar 2025 22:25:08 -0300 Subject: [PATCH 4/5] Alt+Up for brighter, Alt+Down for darker. --- app/qml/main.qml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/app/qml/main.qml b/app/qml/main.qml index 0811f9c5..0be972d0 100644 --- a/app/qml/main.qml +++ b/app/qml/main.qml @@ -162,6 +162,22 @@ ApplicationWindow { appSettings.contrast -= appSettings.contrast > keybindStep ? keybindStep : 0 } } + Action { + id: brighter + text: qsTr("Brighter.") + shortcut: "Alt+Up" + onTriggered: { + appSettings.brightness += appSettings.brightness < (1 - keybindStep) ? keybindStep : 0 + } + } + Action { + id: darker + text: qsTr("Darker.") + shortcut: "Alt+Down" + onTriggered: { + appSettings.brightness -= appSettings.brightness > keybindStep ? keybindStep : 0 + } + } Action { id: showAboutAction text: qsTr("About") From db9d8990803531736a9db8cdf63011ac92a76500 Mon Sep 17 00:00:00 2001 From: fde-capu Date: Mon, 3 Mar 2025 15:09:55 -0300 Subject: [PATCH 5/5] Added Use Keybinds on Options. --- app/qml/ApplicationSettings.qml | 3 +++ app/qml/SettingsTerminalTab.qml | 10 ++++++++-- app/qml/main.qml | 8 ++++++++ 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/app/qml/ApplicationSettings.qml b/app/qml/ApplicationSettings.qml index 424f0bd8..2c77ede8 100644 --- a/app/qml/ApplicationSettings.qml +++ b/app/qml/ApplicationSettings.qml @@ -57,6 +57,7 @@ QtObject { property real burnInQuality: 0.5 property bool blinkingCursor: false + property bool useKeybinds: false onWindowScalingChanged: handleFontChanged() @@ -271,6 +272,7 @@ QtObject { "fontWidth": fontWidth, "margin": _margin, "blinkingCursor": blinkingCursor, + "useKeybinds": useKeybinds, "frameMargin": _frameMargin, } return settings @@ -381,6 +383,7 @@ QtObject { _frameMargin = settings.frameMargin !== undefined ? settings.frameMargin : _frameMargin blinkingCursor = settings.blinkingCursor !== undefined ? settings.blinkingCursor : blinkingCursor + useKeybinds = settings.useKeybinds !== undefined ? settings.useKeybinds : useKeybinds handleFontChanged() } diff --git a/app/qml/SettingsTerminalTab.qml b/app/qml/SettingsTerminalTab.qml index 222ea781..7ea4142c 100644 --- a/app/qml/SettingsTerminalTab.qml +++ b/app/qml/SettingsTerminalTab.qml @@ -114,9 +114,9 @@ ColumnLayout { } } GroupBox { - title: qsTr("Cursor") + title: qsTr("Misc.") Layout.fillWidth: true - ColumnLayout { + RowLayout { anchors.fill: parent CheckBox { id: blinkingCursor @@ -129,6 +129,12 @@ ColumnLayout { property: "checked" value: appSettings.blinkingCursor } + CheckBox { + id: useBindings + text: qsTr("Use Keybinds") + checked: appSettings.useKeybinds + onCheckedChanged: appSettings.useKeybinds = checked + } } } GroupBox { diff --git a/app/qml/main.qml b/app/qml/main.qml index 0be972d0..82073859 100644 --- a/app/qml/main.qml +++ b/app/qml/main.qml @@ -130,9 +130,11 @@ ApplicationWindow { shortcut: "Ctrl+-" onTriggered: appSettings.decrementScaling() } + Action { id: lessOpaque text: qsTr("Make less opaque.") + enabled: appSettings.useKeybinds shortcut: "Ctrl+Shift+Up" onTriggered: { appSettings.windowOpacity -= appSettings.windowOpacity > keybindStep ? keybindStep : 0 @@ -141,6 +143,7 @@ ApplicationWindow { Action { id: moreOpaque text: qsTr("Make more opaque.") + enabled: appSettings.useKeybinds shortcut: "Ctrl+Shift+Down" onTriggered: { appSettings.windowOpacity += appSettings.windowOpacity < (1 - keybindStep) ? keybindStep : 0 @@ -149,6 +152,7 @@ ApplicationWindow { Action { id: moreContrast text: qsTr("More contrast.") + enabled: appSettings.useKeybinds shortcut: "Ctrl+Up" onTriggered: { appSettings.contrast += appSettings.contrast < (1 - keybindStep) ? keybindStep : 0 @@ -157,6 +161,7 @@ ApplicationWindow { Action { id: lessContrast text: qsTr("Less contrast.") + enabled: appSettings.useKeybinds shortcut: "Ctrl+Down" onTriggered: { appSettings.contrast -= appSettings.contrast > keybindStep ? keybindStep : 0 @@ -165,6 +170,7 @@ ApplicationWindow { Action { id: brighter text: qsTr("Brighter.") + enabled: appSettings.useKeybinds shortcut: "Alt+Up" onTriggered: { appSettings.brightness += appSettings.brightness < (1 - keybindStep) ? keybindStep : 0 @@ -173,11 +179,13 @@ ApplicationWindow { Action { id: darker text: qsTr("Darker.") + enabled: appSettings.useKeybinds shortcut: "Alt+Down" onTriggered: { appSettings.brightness -= appSettings.brightness > keybindStep ? keybindStep : 0 } } + Action { id: showAboutAction text: qsTr("About")