diff --git a/Bar/Bar.qml b/Bar/Bar.qml index 161a19e..52e7f34 100644 --- a/Bar/Bar.qml +++ b/Bar/Bar.qml @@ -99,11 +99,15 @@ Scope { Brightness { id: widgetsBrightness + anchors.verticalCenter: parent.verticalCenter + anchors.verticalCenterOffset: 1 } Volume { id: widgetsVolume shell: rootScope.shell + anchors.verticalCenter: parent.verticalCenter + anchors.verticalCenterOffset: 1 } SystemTray { @@ -117,7 +121,10 @@ Scope { id: externalTrayMenu } - ClockWidget {} + ClockWidget { + anchors.verticalCenter: parent.verticalCenter + anchors.verticalCenterOffset: 1 + } PanelPopup { id: sidebarPopup @@ -125,6 +132,8 @@ Scope { Button { barBackground: barBackground + anchors.verticalCenter: parent.verticalCenter + anchors.verticalCenterOffset: 1 screen: modelData sidebarPopup: sidebarPopup } diff --git a/Bar/Modules/ActiveWindow.qml b/Bar/Modules/ActiveWindow.qml index 86f5a19..d3cf692 100644 --- a/Bar/Modules/ActiveWindow.qml +++ b/Bar/Modules/ActiveWindow.qml @@ -26,6 +26,9 @@ Item { if (ToplevelManager.activeToplevel?.appId) { activeWindowWrapper.shouldShow = true visibilityTimer.restart() + } else { + activeWindowWrapper.shouldShow = false + visibilityTimer.stop() } } } diff --git a/Bar/Modules/CustomTrayMenu.qml b/Bar/Modules/CustomTrayMenu.qml index 1543d0d..78ea369 100644 --- a/Bar/Modules/CustomTrayMenu.qml +++ b/Bar/Modules/CustomTrayMenu.qml @@ -89,10 +89,12 @@ PopupWindow { } Rectangle { + id: bg anchors.fill: parent color: mouseArea.containsMouse ? Theme.highlight : "transparent" radius: 6 visible: !(modelData?.isSeparator ?? false) + property color hoverTextColor: mouseArea.containsMouse ? Theme.onAccent : Theme.textPrimary RowLayout { anchors.fill: parent @@ -102,7 +104,7 @@ PopupWindow { Text { Layout.fillWidth: true - color: (modelData?.enabled ?? true) ? Theme.textPrimary : Theme.textDisabled + color: (modelData?.enabled ?? true) ? bg.hoverTextColor : Theme.textDisabled text: modelData?.text ?? "" font.family: Theme.fontFamily font.pixelSize: Theme.fontSizeSmall diff --git a/Services/WallpaperManager.qml b/Services/WallpaperManager.qml index 4937021..727b04c 100644 --- a/Services/WallpaperManager.qml +++ b/Services/WallpaperManager.qml @@ -19,6 +19,8 @@ Singleton { property var wallpaperList: [] property string currentWallpaper: Settings.currentWallpaper property bool scanning: false + property string transitionType: Settings.transitionType + property var randomChoices: ["fade", "left", "right", "top", "bottom", "wipe", "wave", "grow", "center", "any", "outer"] function loadWallpapers() { scanning = true; @@ -40,6 +42,11 @@ Singleton { Settings.saveSettings(); } if (Settings.useSWWW) { + if (Settings.transitionType === "random") { + transitionType = randomChoices[Math.floor(Math.random() * randomChoices.length)]; + } else { + transitionType = Settings.transitionType; + } changeWallpaperProcess.running = true; } generateTheme(); @@ -106,7 +113,7 @@ Singleton { Process { id: changeWallpaperProcess - command: ["swww", "img", "--resize", Settings.wallpaperResize, "--transition-fps", Settings.transitionFps.toString(), "--transition-type", Settings.transitionType, "--transition-duration", Settings.transitionDuration.toString(), currentWallpaper] + command: ["swww", "img", "--resize", Settings.wallpaperResize, "--transition-fps", Settings.transitionFps.toString(), "--transition-type", transitionType, "--transition-duration", Settings.transitionDuration.toString(), currentWallpaper] running: false } diff --git a/Templates/templates/quickshell.json b/Templates/templates/quickshell.json index 26500c5..58d6afd 100644 --- a/Templates/templates/quickshell.json +++ b/Templates/templates/quickshell.json @@ -17,8 +17,8 @@ "error": "{{ color5 | darken(0.1) }}", "warning": "{{ color5 | lighten(0.1) }}", - "highlight": "{{ color6 | lighten(0.2) }}", - "rippleEffect": "{{ color6 | lighten(0.2) }}", + "highlight": "{{ color4 | lighten(0.4) }}", + "rippleEffect": "{{ color4 | lighten(0.1) }}", "onAccent": "{{ background }}", "outline": "{{ background | lighten(0.3) }}", diff --git a/Widgets/Sidebar/Config/CollapsibleCategory.qml b/Widgets/Sidebar/Config/CollapsibleCategory.qml index a5b70ab..97d3c3e 100644 --- a/Widgets/Sidebar/Config/CollapsibleCategory.qml +++ b/Widgets/Sidebar/Config/CollapsibleCategory.qml @@ -19,6 +19,7 @@ ColumnLayout { anchors.fill: parent anchors.margins: 8 spacing: 8 + Item { width: 2 } Text { id: headerText font.family: Theme.fontFamily diff --git a/Widgets/Sidebar/Panel/WallpaperPanel.qml b/Widgets/Sidebar/Panel/WallpaperPanel.qml index 45cdd91..81adb50 100644 --- a/Widgets/Sidebar/Panel/WallpaperPanel.qml +++ b/Widgets/Sidebar/Panel/WallpaperPanel.qml @@ -3,6 +3,7 @@ import QtQuick.Layouts 1.15 import QtQuick.Controls 2.15 import Quickshell import Quickshell.Io +import Quickshell.Widgets import qs.Settings import qs.Services @@ -18,11 +19,11 @@ PanelWindow { margins.top: -24 property var wallpapers: [] - + Connections { target: WallpaperManager function onWallpaperListChanged() { - wallpapers = WallpaperManager.wallpaperList + wallpapers = WallpaperManager.wallpaperList; } } @@ -53,7 +54,9 @@ PanelWindow { Layout.fillWidth: true } Rectangle { - width: 36; height: 36; radius: 18 + width: 36 + height: 36 + radius: 18 color: closeButtonArea.containsMouse ? Theme.accentPrimary : "transparent" border.color: Theme.accentPrimary border.width: 1 @@ -109,30 +112,30 @@ PanelWindow { delegate: Item { width: wallpaperGrid.cellWidth - 8 height: wallpaperGrid.cellHeight - 8 - Rectangle { - id: wallpaperItem + MouseArea { anchors.fill: parent - anchors.margins: 4 - color: Qt.darker(Theme.backgroundPrimary, 1.1) - radius: 12 - border.color: Settings.currentWallpaper === modelData ? Theme.accentPrimary : Theme.outline - border.width: Settings.currentWallpaper === modelData ? 3 : 1 - Image { - id: wallpaperImage + hoverEnabled: true + onClicked: { + WallpaperManager.changeWallpaper(modelData); + } + + ClippingWrapperRectangle { + id: wallpaperItem anchors.fill: parent anchors.margins: 4 - source: modelData - fillMode: Image.PreserveAspectCrop - asynchronous: true - cache: true - sourceSize.width: Math.min(width, 150) - sourceSize.height: Math.min(height, 90) - } - MouseArea { - anchors.fill: parent - hoverEnabled: true - onClicked: { - WallpaperManager.changeWallpaper(modelData); + color: Qt.darker(Theme.backgroundPrimary, 1.1) + radius: 12 + border.color: Settings.currentWallpaper === modelData ? Theme.accentPrimary : Theme.outline + border.width: Settings.currentWallpaper === modelData ? 3 : 1 + Image { + id: wallpaperImage + anchors.fill: parent + source: modelData + fillMode: Image.PreserveAspectCrop + asynchronous: true + cache: true + sourceSize.width: Math.min(width, 150) + sourceSize.height: Math.min(height, 90) } } } @@ -142,4 +145,4 @@ PanelWindow { } } } -} \ No newline at end of file +}