diff --git a/Modules/MainScreen/MainScreen.qml b/Modules/MainScreen/MainScreen.qml index fd4656274..685839c32 100644 --- a/Modules/MainScreen/MainScreen.qml +++ b/Modules/MainScreen/MainScreen.qml @@ -217,39 +217,21 @@ PanelWindow { bottomRightCorner: barPlaceholder.bottomRightCornerState } - // ── Framed bar: frame body (4 strips) + rounded hole subtraction ── - // The 4 strips cover the entire frame area including straight-edge inner - // corners. A nested Subtract region then removes the hole with correct - // frameRadius rounding, leaving the blur boundary exactly matching the - // visual frame shape. - - // Top strip (covers full width above hole) + // ── Framed bar: full screen minus rounded hole ── Region { x: 0 y: 0 width: (barPlaceholder.isFramed && root.barShouldShow) ? root.width : 0 - height: (barPlaceholder.isFramed && root.barShouldShow) ? backgroundBlur.frameHoleY : 0 - } - // Bottom strip - Region { - x: 0 - y: (barPlaceholder.isFramed && root.barShouldShow) ? backgroundBlur.frameHoleY2 : 0 - width: (barPlaceholder.isFramed && root.barShouldShow) ? root.width : 0 - height: (barPlaceholder.isFramed && root.barShouldShow) ? (root.height - backgroundBlur.frameHoleY2) : 0 - } - // Left strip (only at hole height - top/bottom strips already cover those rows) - Region { - x: 0 - y: (barPlaceholder.isFramed && root.barShouldShow) ? backgroundBlur.frameHoleY : 0 - width: (barPlaceholder.isFramed && root.barShouldShow) ? backgroundBlur.frameHoleX : 0 - height: (barPlaceholder.isFramed && root.barShouldShow) ? (backgroundBlur.frameHoleY2 - backgroundBlur.frameHoleY) : 0 - } - // Right strip - Region { - x: (barPlaceholder.isFramed && root.barShouldShow) ? backgroundBlur.frameHoleX2 : 0 - y: (barPlaceholder.isFramed && root.barShouldShow) ? backgroundBlur.frameHoleY : 0 - width: (barPlaceholder.isFramed && root.barShouldShow) ? (root.width - backgroundBlur.frameHoleX2) : 0 - height: (barPlaceholder.isFramed && root.barShouldShow) ? (backgroundBlur.frameHoleY2 - backgroundBlur.frameHoleY) : 0 + height: (barPlaceholder.isFramed && root.barShouldShow) ? root.height : 0 + + Region { + intersection: Intersection.Subtract + x: backgroundBlur.frameHoleX + y: backgroundBlur.frameHoleY + width: backgroundBlur.frameHoleX2 - backgroundBlur.frameHoleX + height: backgroundBlur.frameHoleY2 - backgroundBlur.frameHoleY + radius: backgroundBlur.frameR + } } // ── Panel blur regions ── @@ -572,7 +554,7 @@ PanelWindow { // Panel background geometry (from the currently open panel on this screen) readonly property var panelBg: { var op = PanelService.openedPanel; - if (!op || op.screen !== root.screen) + if (!op || op.screen !== root.screen || op.blurEnabled === false) return null; var region = op.panelRegion; return (region && region.visible) ? region.panelItem : null; @@ -581,7 +563,7 @@ PanelWindow { // Panel background geometry for the closing panel (may coexist with panelBg) readonly property var closingPanelBg: { var cp = PanelService.closingPanel; - if (!cp || cp.screen !== root.screen) + if (!cp || cp.screen !== root.screen || cp.blurEnabled === false) return null; var region = cp.panelRegion; return (region && region.visible) ? region.panelItem : null; diff --git a/Modules/MainScreen/SmartPanel.qml b/Modules/MainScreen/SmartPanel.qml index 2a30e8a84..36036a168 100644 --- a/Modules/MainScreen/SmartPanel.qml +++ b/Modules/MainScreen/SmartPanel.qml @@ -75,6 +75,9 @@ Item { property bool cachedShouldAnimateWidth: false property bool cachedShouldAnimateHeight: false + // Whether blur should be applied behind this panel + property bool blurEnabled: true + // Close with escape key property bool closeWithEscape: true diff --git a/Modules/Panels/SessionMenu/SessionMenu.qml b/Modules/Panels/SessionMenu/SessionMenu.qml index c74a39db1..2ab3ea81e 100644 --- a/Modules/Panels/SessionMenu/SessionMenu.qml +++ b/Modules/Panels/SessionMenu/SessionMenu.qml @@ -18,6 +18,9 @@ SmartPanel { readonly property bool largeButtonsStyle: Settings.data.sessionMenu.largeButtonsStyle || false readonly property bool largeButtonsLayout: Settings.data.sessionMenu.largeButtonsLayout || "grid" + // Large buttons style is fullscreen — disable blur behind it + blurEnabled: !largeButtonsStyle + // Make panel background transparent for large buttons style panelBackgroundColor: largeButtonsStyle ? "transparent" : Color.mSurface @@ -567,7 +570,7 @@ SmartPanel { } } - // Timer text for large buttons style (above buttons) - positioned absolutely with background + // Timer text for large buttons style, positioned absolutely with background Rectangle { id: timerTextContainer visible: largeButtonsStyle && timerActive @@ -577,7 +580,7 @@ SmartPanel { width: timerText.width + Style.margin2XL height: timerText.height + Style.margin2L radius: Style.radiusM - color: Qt.alpha(Color.mSurface, Settings.data.ui.panelBackgroundOpacity) + color: Color.mSurfaceVariant border.color: Color.mOutline border.width: Style.borderS z: 1000 @@ -591,7 +594,7 @@ SmartPanel { }) font.weight: Style.fontWeightBold pointSize: Style.fontSizeL - color: Color.mOnSurface + color: Color.mOnSurfaceVariant } } @@ -638,6 +641,7 @@ SmartPanel { visible: !largeButtonsStyle anchors.fill: parent anchors.margins: Style.marginL + color: Color.mSurface ColumnLayout { anchors.fill: parent @@ -838,7 +842,7 @@ SmartPanel { width: labelText.implicitWidth + Style.margin2M height: labelText.height + Style.margin2XS radius: Math.min(Style.radiusM, height / 2) - color: (buttonRoot.isSelected || buttonRoot.effectiveHover) ? Color.mOnPrimary : Qt.alpha(Color.mSurfaceVariant, 0.5) + color: (buttonRoot.isSelected || buttonRoot.effectiveHover) ? Color.mOnPrimary : Color.mSurfaceVariant border.width: Style.borderS border.color: (buttonRoot.isSelected || buttonRoot.effectiveHover) ? Color.mOnPrimary : Color.mOutline visible: Settings.data.sessionMenu.showKeybinds && (buttonRoot.keybind !== "") && !buttonRoot.pending @@ -944,7 +948,7 @@ SmartPanel { if (isSelected || effectiveHover) { return Qt.alpha(Color.mPrimary, 1.0); } - return Qt.alpha(Color.mSurfaceVariant, Settings.data.ui.panelBackgroundOpacity); + return Color.mSurface; } border.width: Style.borderS