From c9484d4448b9cf34a52dae378d7fc3747b5e4fd8 Mon Sep 17 00:00:00 2001 From: Ly-sec Date: Sun, 17 Aug 2025 22:01:56 +0200 Subject: [PATCH 1/4] Possible TrayMenu text fix --- Modules/Bar/TrayMenu.qml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Modules/Bar/TrayMenu.qml b/Modules/Bar/TrayMenu.qml index 50c61c0..1e4bccf 100644 --- a/Modules/Bar/TrayMenu.qml +++ b/Modules/Bar/TrayMenu.qml @@ -126,7 +126,7 @@ PopupWindow { id: text Layout.fillWidth: true color: (modelData?.enabled - ?? true) ? (mouseArea.containsMouse ? Color.mOnTertiary : Color.mOnSurface) : Color.textDisabled + ?? true) ? (mouseArea.containsMouse ? Color.mOnTertiary : Color.mOnSurface) : Color.mOnSurfaceVariant text: modelData?.text ?? "" font.pointSize: Style.fontSizeSmall * scaling verticalAlignment: Text.AlignVCenter @@ -148,7 +148,7 @@ PopupWindow { font.pointSize: Style.fontSizeSmall * scaling verticalAlignment: Text.AlignVCenter visible: modelData?.hasChildren ?? false - color: Color.mOnSurface + color: (modelData?.enabled ?? true) ? (mouseArea.containsMouse ? Color.mOnTertiary : Color.mOnSurface) : Color.mOnSurfaceVariant } } @@ -350,7 +350,6 @@ PopupWindow { color: mouseArea.containsMouse ? Color.mTertiary : Color.transparent radius: Style.radiusSmall * scaling visible: !(modelData?.isSeparator ?? false) - property color hoverTextColor: mouseArea.containsMouse ? Color.mOnSurface : Color.mOnSurface RowLayout { anchors.fill: parent @@ -361,7 +360,7 @@ PopupWindow { NText { id: subText Layout.fillWidth: true - color: (modelData?.enabled ?? true) ? bg.hoverTextColor : Color.textDisabled + color: (modelData?.enabled ?? true) ? (mouseArea.containsMouse ? Color.mOnTertiary : Color.mOnSurface) : Color.mOnSurfaceVariant text: modelData?.text ?? "" font.pointSize: Style.fontSizeSmall * scaling verticalAlignment: Text.AlignVCenter @@ -383,6 +382,7 @@ PopupWindow { font.pointSize: Style.fontSizeSmall * scaling verticalAlignment: Text.AlignVCenter visible: modelData?.hasChildren ?? false + color: (modelData?.enabled ?? true) ? (mouseArea.containsMouse ? Color.mOnTertiary : Color.mOnSurface) : Color.mOnSurfaceVariant } } From 41fdaac50362708b3e49c12400480cbabd5b32ba Mon Sep 17 00:00:00 2001 From: Lysec <52084453+Ly-sec@users.noreply.github.com> Date: Mon, 18 Aug 2025 14:53:40 +0200 Subject: [PATCH 2/4] Create LICENSE --- LICENSE | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 LICENSE diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..2bdaed9 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2025 noctalia-dev + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. From fdf475cabc2ad6436a3b1a2deede786e98bf7f29 Mon Sep 17 00:00:00 2001 From: quadbyte Date: Tue, 19 Aug 2025 08:01:59 -0400 Subject: [PATCH 3/4] Tray capsule hidden if empty + formatting --- Commons/Settings.qml | 17 +++++++++-------- Modules/Background/ScreenCorners.qml | 10 ++++------ Modules/Bar/Tray.qml | 2 +- 3 files changed, 14 insertions(+), 15 deletions(-) diff --git a/Commons/Settings.qml b/Commons/Settings.qml index 6302567..abe30c7 100644 --- a/Commons/Settings.qml +++ b/Commons/Settings.qml @@ -32,17 +32,17 @@ Singleton { // Needed to only have one NPanel loaded at a time. <--- VERY BROKEN //property var openPanel: null - + // Function to validate monitor configurations function validateMonitorConfigurations() { var availableScreenNames = [] for (var i = 0; i < Quickshell.screens.length; i++) { availableScreenNames.push(Quickshell.screens[i].name) } - + Logger.log("Settings", "Available monitors: [" + availableScreenNames.join(", ") + "]") Logger.log("Settings", "Configured bar monitors: [" + adapter.bar.monitors.join(", ") + "]") - + // Check bar monitors if (adapter.bar.monitors.length > 0) { var hasValidBarMonitor = false @@ -53,7 +53,8 @@ Singleton { } } if (!hasValidBarMonitor) { - Logger.log("Settings", "No configured bar monitors found on system, clearing bar monitor list to show on all screens") + Logger.log("Settings", + "No configured bar monitors found on system, clearing bar monitor list to show on all screens") adapter.bar.monitors = [] } else { Logger.log("Settings", "Found valid bar monitors, keeping configuration") @@ -88,10 +89,10 @@ Singleton { Logger.log("Settings", "Set current wallpaper", adapter.wallpaper.current) WallpaperService.setCurrentWallpaper(adapter.wallpaper.current, true) } - + // Validate monitor configurations - if none of the configured monitors exist, clear the lists validateMonitorConfigurations() - + isInitialLoad = false }) } @@ -108,7 +109,7 @@ Singleton { property JsonObject bar bar: JsonObject { - property string barPosition: "top" // Possible values: "top", "bottom", "left", "right" + property string barPosition: "top" // Possible values: "top", "bottom", "left", "right" property bool showActiveWindow: true property bool showSystemInfo: false property bool showMedia: false @@ -222,7 +223,7 @@ Singleton { property string fontFamily: "Roboto" // Family for all text } - // Scaling (not stored as JsonObject) + // Scaling (not stored inside JsonObject, or it crashes) property var monitorsScaling: { } diff --git a/Modules/Background/ScreenCorners.qml b/Modules/Background/ScreenCorners.qml index f8a58d7..cfbd19a 100644 --- a/Modules/Background/ScreenCorners.qml +++ b/Modules/Background/ScreenCorners.qml @@ -43,12 +43,10 @@ NLoader { } margins { - top: (Settings.data.bar.monitors.includes(modelData.name) - || (Settings.data.bar.monitors.length === 0)) && Settings.data.bar.barPosition === "top" - ? Math.floor(Style.barHeight * scaling) : 0 - bottom: (Settings.data.bar.monitors.includes(modelData.name) - || (Settings.data.bar.monitors.length === 0)) && Settings.data.bar.barPosition === "bottom" - ? Math.floor(Style.barHeight * scaling) : 0 + top: (Settings.data.bar.monitors.includes(modelData.name) || (Settings.data.bar.monitors.length === 0)) + && Settings.data.bar.barPosition === "top" ? Math.floor(Style.barHeight * scaling) : 0 + bottom: (Settings.data.bar.monitors.includes(modelData.name) || (Settings.data.bar.monitors.length === 0)) + && Settings.data.bar.barPosition === "bottom" ? Math.floor(Style.barHeight * scaling) : 0 } // Source we want to show only as a ring diff --git a/Modules/Bar/Tray.qml b/Modules/Bar/Tray.qml index 4476f8d..d05da25 100644 --- a/Modules/Bar/Tray.qml +++ b/Modules/Bar/Tray.qml @@ -12,7 +12,7 @@ import qs.Widgets Rectangle { readonly property real itemSize: 24 * scaling - visible: Settings.data.bar.showTray + visible: Settings.data.bar.showTray && SystemTray.items.length > 0 width: tray.width + Style.marginM * scaling * 2 height: Math.round(Style.capsuleHeight * scaling) From 3e95626298328e15e5e7d7c6be84efc264ccb185 Mon Sep 17 00:00:00 2001 From: quadbyte Date: Tue, 19 Aug 2025 08:03:06 -0400 Subject: [PATCH 4/4] Scaling: dont log catched erros when the monitorScaling is not set. --- Services/ScalingService.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Services/ScalingService.qml b/Services/ScalingService.qml index 7be015e..812daf0 100644 --- a/Services/ScalingService.qml +++ b/Services/ScalingService.qml @@ -20,7 +20,7 @@ Singleton { } } } catch (e) { - Logger.warn(e) + //Logger.warn(e) } return 1.0