1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-06-08 04:09:15 -04:00

refactor(Settings): Rename fullscreen properties to overlay layer for consistency

- Updated property names from `showOverFullscreen` to `useOverlayLayer` across various components.
- Fixed Darken Modal Overlay in Standalone mode
This commit is contained in:
purian23
2026-05-19 22:03:33 -04:00
parent 4634763840
commit 548c2305fb
15 changed files with 189 additions and 156 deletions
+3 -3
View File
@@ -449,7 +449,7 @@ Singleton {
property bool dankLauncherV2UnloadOnClose: false property bool dankLauncherV2UnloadOnClose: false
property bool dankLauncherV2IncludeFilesInAll: false property bool dankLauncherV2IncludeFilesInAll: false
property bool dankLauncherV2IncludeFoldersInAll: false property bool dankLauncherV2IncludeFoldersInAll: false
property bool launcherShowOverFullscreen: false property bool launcherUseOverlayLayer: false
property string launcherStyle: "full" property string launcherStyle: "full"
property string _legacyWeatherLocation: "New York, NY" property string _legacyWeatherLocation: "New York, NY"
@@ -607,7 +607,7 @@ Singleton {
property bool showDock: false property bool showDock: false
property bool dockAutoHide: false property bool dockAutoHide: false
property bool dockSmartAutoHide: false property bool dockSmartAutoHide: false
property bool dockShowOverFullscreen: false property bool dockUseOverlayLayer: false
property bool dockGroupByApp: false property bool dockGroupByApp: false
property bool dockRestoreSpecialWorkspaceOnClick: false property bool dockRestoreSpecialWorkspaceOnClick: false
property bool dockOpenOnOverview: false property bool dockOpenOnOverview: false
@@ -788,7 +788,7 @@ Singleton {
"popupGapsAuto": true, "popupGapsAuto": true,
"popupGapsManual": 4, "popupGapsManual": 4,
"maximizeDetection": true, "maximizeDetection": true,
"showOverFullscreen": false, "useOverlayLayer": false,
"scrollEnabled": true, "scrollEnabled": true,
"scrollXBehavior": "column", "scrollXBehavior": "column",
"scrollYBehavior": "workspace", "scrollYBehavior": "workspace",
+3 -3
View File
@@ -213,7 +213,7 @@ var SPEC = {
dankLauncherV2UnloadOnClose: { def: false }, dankLauncherV2UnloadOnClose: { def: false },
dankLauncherV2IncludeFilesInAll: { def: false }, dankLauncherV2IncludeFilesInAll: { def: false },
dankLauncherV2IncludeFoldersInAll: { def: false }, dankLauncherV2IncludeFoldersInAll: { def: false },
launcherShowOverFullscreen: { def: false }, launcherUseOverlayLayer: { def: false },
launcherStyle: { def: "full" }, launcherStyle: { def: "full" },
useAutoLocation: { def: false }, useAutoLocation: { def: false },
@@ -333,7 +333,7 @@ var SPEC = {
showDock: { def: false }, showDock: { def: false },
dockAutoHide: { def: false }, dockAutoHide: { def: false },
dockSmartAutoHide: { def: false }, dockSmartAutoHide: { def: false },
dockShowOverFullscreen: { def: false }, dockUseOverlayLayer: { def: false },
dockGroupByApp: { def: false }, dockGroupByApp: { def: false },
dockRestoreSpecialWorkspaceOnClick: { def: false }, dockRestoreSpecialWorkspaceOnClick: { def: false },
dockOpenOnOverview: { def: false }, dockOpenOnOverview: { def: false },
@@ -497,7 +497,7 @@ var SPEC = {
popupGapsAuto: true, popupGapsAuto: true,
popupGapsManual: 4, popupGapsManual: 4,
maximizeDetection: true, maximizeDetection: true,
showOverFullscreen: false, useOverlayLayer: false,
scrollEnabled: true, scrollEnabled: true,
scrollXBehavior: "column", scrollXBehavior: "column",
scrollYBehavior: "workspace", scrollYBehavior: "workspace",
@@ -41,7 +41,7 @@ Item {
readonly property real screenWidth: effectiveScreen?.width ?? 1920 readonly property real screenWidth: effectiveScreen?.width ?? 1920
readonly property real screenHeight: effectiveScreen?.height ?? 1080 readonly property real screenHeight: effectiveScreen?.height ?? 1080
readonly property real dpr: effectiveScreen ? CompositorService.getScreenScale(effectiveScreen) : 1 readonly property real dpr: effectiveScreen ? CompositorService.getScreenScale(effectiveScreen) : 1
readonly property bool usesOverlayLayer: SettingsData.launcherShowOverFullscreen || triggerUsesOverlayLayer readonly property bool usesOverlayLayer: SettingsData.launcherUseOverlayLayer || triggerUsesOverlayLayer
readonly property var effectiveLauncherLayer: { readonly property var effectiveLauncherLayer: {
switch (Quickshell.env("DMS_MODAL_LAYER")) { switch (Quickshell.env("DMS_MODAL_LAYER")) {
case "bottom": case "bottom":
@@ -30,7 +30,8 @@ Item {
readonly property real screenWidth: effectiveScreen?.width ?? 1920 readonly property real screenWidth: effectiveScreen?.width ?? 1920
readonly property real screenHeight: effectiveScreen?.height ?? 1080 readonly property real screenHeight: effectiveScreen?.height ?? 1080
readonly property real dpr: effectiveScreen ? CompositorService.getScreenScale(effectiveScreen) : 1 readonly property real dpr: effectiveScreen ? CompositorService.getScreenScale(effectiveScreen) : 1
readonly property bool usesOverlayLayer: SettingsData.launcherShowOverFullscreen || triggerUsesOverlayLayer readonly property bool useBackgroundDarken: !SettingsData.frameEnabled && SettingsData.modalDarkenBackground
readonly property bool usesOverlayLayer: useBackgroundDarken || SettingsData.launcherUseOverlayLayer || triggerUsesOverlayLayer
readonly property var effectiveLauncherLayer: { readonly property var effectiveLauncherLayer: {
switch (Quickshell.env("DMS_MODAL_LAYER")) { switch (Quickshell.env("DMS_MODAL_LAYER")) {
case "bottom": case "bottom":
@@ -275,7 +276,7 @@ Item {
PanelWindow { PanelWindow {
id: clickCatcher id: clickCatcher
screen: launcherWindow.screen screen: launcherWindow.screen
visible: spotlightOpen || isClosing visible: (spotlightOpen || isClosing) && !root.useBackgroundDarken
color: "transparent" color: "transparent"
WlrLayershell.namespace: "dms:spotlight:clickcatcher" WlrLayershell.namespace: "dms:spotlight:clickcatcher"
@@ -347,17 +348,19 @@ Item {
anchors { anchors {
top: true top: true
left: true left: true
right: root.useBackgroundDarken
bottom: root.useBackgroundDarken
} }
WlrLayershell.margins { WlrLayershell.margins {
left: root.windowX left: root.useBackgroundDarken ? 0 : root.windowX
top: root.windowY top: root.useBackgroundDarken ? 0 : root.windowY
right: 0 right: 0
bottom: 0 bottom: 0
} }
implicitWidth: root.windowWidth implicitWidth: root.useBackgroundDarken ? 0 : root.windowWidth
implicitHeight: root.windowHeight implicitHeight: root.useBackgroundDarken ? 0 : root.windowHeight
mask: Region { mask: Region {
item: inputMask item: inputMask
@@ -367,19 +370,44 @@ Item {
id: inputMask id: inputMask
visible: false visible: false
color: "transparent" color: "transparent"
x: modalContainer.x x: root.useBackgroundDarken ? 0 : modalContainer.x
y: modalContainer.y + modalContainer.slideOffset y: root.useBackgroundDarken ? 0 : modalContainer.y + modalContainer.slideOffset
width: root.alignedWidth width: root.useBackgroundDarken ? launcherWindow.width : root.alignedWidth
height: root._contentImplicitH height: root.useBackgroundDarken ? launcherWindow.height : root._contentImplicitH
}
MouseArea {
anchors.fill: parent
enabled: root.useBackgroundDarken && spotlightOpen
z: -2
onClicked: root.hide()
}
Rectangle {
id: backgroundDarken
anchors.fill: parent
color: "black"
opacity: contentVisible && root.useBackgroundDarken ? 0.5 : 0
visible: (spotlightOpen || isClosing) && (root.useBackgroundDarken || opacity > 0)
z: -3
Behavior on opacity {
NumberAnimation {
duration: contentVisible ? root._openDuration : root._closeDuration
easing.type: Easing.BezierSpline
easing.bezierCurve: contentVisible ? [0.0, 0.0, 0.2, 1.0, 1.0, 1.0] : [0.4, 0.0, 1.0, 1.0, 1.0, 1.0]
}
}
} }
Item { Item {
id: modalContainer id: modalContainer
x: root.contentX x: root.useBackgroundDarken ? root.alignedX : root.contentX
y: root.contentY y: root.useBackgroundDarken ? root.alignedY : root.contentY
width: root.alignedWidth width: root.alignedWidth
height: root._animatedContentH height: root._animatedContentH
visible: _renderActive visible: _renderActive
z: 0
property bool _renderActive: contentVisible property bool _renderActive: contentVisible
property real slideOffset: contentVisible ? 0 : -root._animHeadroom property real slideOffset: contentVisible ? 0 : -root._animHeadroom
@@ -80,7 +80,7 @@ Item {
readonly property color backgroundColor: Theme.withAlpha(Theme.surfaceContainer, Theme.popupTransparency) readonly property color backgroundColor: Theme.withAlpha(Theme.surfaceContainer, Theme.popupTransparency)
readonly property bool useBackgroundDarken: !SettingsData.frameEnabled && SettingsData.modalDarkenBackground readonly property bool useBackgroundDarken: !SettingsData.frameEnabled && SettingsData.modalDarkenBackground
readonly property bool usesOverlayLayer: useBackgroundDarken || SettingsData.launcherShowOverFullscreen || triggerUsesOverlayLayer readonly property bool usesOverlayLayer: useBackgroundDarken || SettingsData.launcherUseOverlayLayer || triggerUsesOverlayLayer
readonly property var effectiveLauncherLayer: { readonly property var effectiveLauncherLayer: {
switch (Quickshell.env("DMS_MODAL_LAYER")) { switch (Quickshell.env("DMS_MODAL_LAYER")) {
case "bottom": case "bottom":
@@ -312,9 +312,8 @@ Item {
PanelWindow { PanelWindow {
id: clickCatcher id: clickCatcher
screen: launcherWindow.screen screen: launcherWindow.screen
visible: spotlightOpen || isClosing visible: (spotlightOpen || isClosing) && !root.useBackgroundDarken
color: "transparent" color: "transparent"
updatesEnabled: root.useBackgroundDarken && (spotlightOpen || isClosing)
WlrLayershell.namespace: "dms:spotlight:clickcatcher" WlrLayershell.namespace: "dms:spotlight:clickcatcher"
WlrLayershell.layer: root.effectiveLauncherLayer WlrLayershell.layer: root.effectiveLauncherLayer
@@ -358,22 +357,6 @@ Item {
enabled: spotlightOpen enabled: spotlightOpen
onClicked: root.hide() onClicked: root.hide()
} }
Rectangle {
id: backgroundDarken
anchors.fill: parent
color: "black"
opacity: contentVisible && root.useBackgroundDarken ? 0.5 : 0
visible: (spotlightOpen || isClosing) && (root.useBackgroundDarken || opacity > 0)
Behavior on opacity {
NumberAnimation {
easing.type: Easing.BezierSpline
duration: Theme.modalAnimationDuration
easing.bezierCurve: contentVisible ? Theme.expressiveCurves.expressiveDefaultSpatial : Theme.expressiveCurves.emphasized
}
}
}
} }
PanelWindow { PanelWindow {
@@ -401,17 +384,19 @@ Item {
anchors { anchors {
top: true top: true
left: true left: true
right: root.useBackgroundDarken
bottom: root.useBackgroundDarken
} }
WlrLayershell.margins { WlrLayershell.margins {
left: root.windowX left: root.useBackgroundDarken ? 0 : root.windowX
top: root.windowY top: root.useBackgroundDarken ? 0 : root.windowY
right: 0 right: 0
bottom: 0 bottom: 0
} }
implicitWidth: root.windowWidth implicitWidth: root.useBackgroundDarken ? 0 : root.windowWidth
implicitHeight: root.windowHeight implicitHeight: root.useBackgroundDarken ? 0 : root.windowHeight
mask: Region { mask: Region {
item: launcherInputMask item: launcherInputMask
@@ -421,19 +406,44 @@ Item {
id: launcherInputMask id: launcherInputMask
visible: false visible: false
color: "transparent" color: "transparent"
x: modalContainer.x x: root.useBackgroundDarken ? 0 : modalContainer.x
y: modalContainer.y y: root.useBackgroundDarken ? 0 : modalContainer.y
width: modalContainer.width width: root.useBackgroundDarken ? launcherWindow.width : modalContainer.width
height: modalContainer.height height: root.useBackgroundDarken ? launcherWindow.height : modalContainer.height
}
MouseArea {
anchors.fill: parent
enabled: root.useBackgroundDarken && spotlightOpen
z: -2
onClicked: root.hide()
}
Rectangle {
id: backgroundDarken
anchors.fill: parent
color: "black"
opacity: contentVisible && root.useBackgroundDarken ? 0.5 : 0
visible: (spotlightOpen || isClosing) && (root.useBackgroundDarken || opacity > 0)
z: -3
Behavior on opacity {
NumberAnimation {
easing.type: Easing.BezierSpline
duration: Theme.modalAnimationDuration
easing.bezierCurve: contentVisible ? Theme.expressiveCurves.expressiveDefaultSpatial : Theme.expressiveCurves.emphasized
}
}
} }
Item { Item {
id: modalContainer id: modalContainer
x: root.contentX x: root.useBackgroundDarken ? root.alignedX : root.contentX
y: root.contentY y: root.useBackgroundDarken ? root.alignedY : root.contentY
width: root.alignedWidth width: root.alignedWidth
height: root.alignedHeight height: root.alignedHeight
visible: _renderActive visible: _renderActive
z: 0
property bool _renderActive: contentVisible property bool _renderActive: contentVisible
property real publishedScale: contentVisible ? 1 : 0.96 property real publishedScale: contentVisible ? 1 : 0.96
+1 -1
View File
@@ -10,7 +10,7 @@ Item {
required property var axis required property var axis
required property var barConfig required property var barConfig
readonly property bool frameShapesBar: SettingsData.frameEnabled && barWindow.usesConnectedFrameChrome readonly property bool frameShapesBar: SettingsData.frameEnabled && barWindow.usesFrameBarChrome
visible: !frameShapesBar visible: !frameShapesBar
+10 -10
View File
@@ -25,8 +25,8 @@ Item {
readonly property real outlineThickness: (barConfig?.widgetOutlineEnabled ?? false) ? (barConfig?.widgetOutlineThickness ?? 1) : 0 readonly property real outlineThickness: (barConfig?.widgetOutlineEnabled ?? false) ? (barConfig?.widgetOutlineThickness ?? 1) : 0
readonly property real _edgeBaseMargin: Math.max(Theme.spacingXS, innerPadding * 0.8) readonly property real _edgeBaseMargin: Math.max(Theme.spacingXS, innerPadding * 0.8)
readonly property bool _hasBarWindow: barWindow !== undefined && barWindow !== null readonly property bool _hasBarWindow: barWindow !== undefined && barWindow !== null
readonly property bool _usesConnectedFrameChrome: _hasBarWindow && (barWindow.usesConnectedFrameChrome ?? false) readonly property bool _usesFrameBarChrome: _hasBarWindow && (barWindow.usesFrameBarChrome ?? false)
readonly property real _frameEdgeFloorInset: (SettingsData.frameEnabled && _usesConnectedFrameChrome) ? Math.max(0, SettingsData.frameThickness - _edgeBaseMargin) : 0 readonly property real _frameEdgeFloorInset: (SettingsData.frameEnabled && _usesFrameBarChrome) ? Math.max(0, SettingsData.frameThickness - _edgeBaseMargin) : 0
readonly property bool _barIsVertical: _hasBarWindow ? barWindow.isVertical : false readonly property bool _barIsVertical: _hasBarWindow ? barWindow.isVertical : false
readonly property string _barScreenName: _hasBarWindow ? (barWindow.screenName || "") : "" readonly property string _barScreenName: _hasBarWindow ? (barWindow.screenName || "") : ""
readonly property bool hasAdjacentTopBarLive: _hasBarWindow && barWindow.hasAdjacentTopBar readonly property bool hasAdjacentTopBarLive: _hasBarWindow && barWindow.hasAdjacentTopBar
@@ -48,22 +48,22 @@ Item {
_hadAdjacentRightBar = true _hadAdjacentRightBar = true
readonly property real _frameLeftInset: { readonly property real _frameLeftInset: {
if (!_hasBarWindow || !SettingsData.frameEnabled || !_usesConnectedFrameChrome || _barIsVertical) if (!_hasBarWindow || !SettingsData.frameEnabled || !_usesFrameBarChrome || _barIsVertical)
return 0; return 0;
return hasAdjacentLeftBarLive ? SettingsData.frameBarSize : (_hadAdjacentLeftBar ? _frameEdgeFloorInset : 0); return hasAdjacentLeftBarLive ? SettingsData.frameBarSize : (_hadAdjacentLeftBar ? _frameEdgeFloorInset : 0);
} }
readonly property real _frameRightInset: { readonly property real _frameRightInset: {
if (!_hasBarWindow || !SettingsData.frameEnabled || !_usesConnectedFrameChrome || _barIsVertical) if (!_hasBarWindow || !SettingsData.frameEnabled || !_usesFrameBarChrome || _barIsVertical)
return 0; return 0;
return hasAdjacentRightBarLive ? SettingsData.frameBarSize : (_hadAdjacentRightBar ? _frameEdgeFloorInset : 0); return hasAdjacentRightBarLive ? SettingsData.frameBarSize : (_hadAdjacentRightBar ? _frameEdgeFloorInset : 0);
} }
readonly property real _frameTopInset: { readonly property real _frameTopInset: {
if (!_hasBarWindow || !SettingsData.frameEnabled || !_usesConnectedFrameChrome || !_barIsVertical) if (!_hasBarWindow || !SettingsData.frameEnabled || !_usesFrameBarChrome || !_barIsVertical)
return 0; return 0;
return hasAdjacentTopBarLive ? SettingsData.frameThickness : (_hadAdjacentTopBar ? _frameEdgeFloorInset : 0); return hasAdjacentTopBarLive ? SettingsData.frameThickness : (_hadAdjacentTopBar ? _frameEdgeFloorInset : 0);
} }
readonly property real _frameBottomInset: { readonly property real _frameBottomInset: {
if (!_hasBarWindow || !SettingsData.frameEnabled || !_usesConnectedFrameChrome || !_barIsVertical) if (!_hasBarWindow || !SettingsData.frameEnabled || !_usesFrameBarChrome || !_barIsVertical)
return 0; return 0;
return hasAdjacentBottomBarLive ? SettingsData.frameThickness : (_hadAdjacentBottomBar ? _frameEdgeFloorInset : 0); return hasAdjacentBottomBarLive ? SettingsData.frameThickness : (_hadAdjacentBottomBar ? _frameEdgeFloorInset : 0);
} }
@@ -96,7 +96,7 @@ Item {
} }
Behavior on anchors.leftMargin { Behavior on anchors.leftMargin {
enabled: _animateFrameInsets && _usesConnectedFrameChrome enabled: _animateFrameInsets && _usesFrameBarChrome
NumberAnimation { NumberAnimation {
duration: Theme.shortDuration duration: Theme.shortDuration
easing.type: Easing.OutCubic easing.type: Easing.OutCubic
@@ -104,7 +104,7 @@ Item {
} }
Behavior on anchors.rightMargin { Behavior on anchors.rightMargin {
enabled: _animateFrameInsets && _usesConnectedFrameChrome enabled: _animateFrameInsets && _usesFrameBarChrome
NumberAnimation { NumberAnimation {
duration: Theme.shortDuration duration: Theme.shortDuration
easing.type: Easing.OutCubic easing.type: Easing.OutCubic
@@ -112,7 +112,7 @@ Item {
} }
Behavior on anchors.topMargin { Behavior on anchors.topMargin {
enabled: _animateFrameInsets && _usesConnectedFrameChrome enabled: _animateFrameInsets && _usesFrameBarChrome
NumberAnimation { NumberAnimation {
duration: Theme.shortDuration duration: Theme.shortDuration
easing.type: Easing.OutCubic easing.type: Easing.OutCubic
@@ -120,7 +120,7 @@ Item {
} }
Behavior on anchors.bottomMargin { Behavior on anchors.bottomMargin {
enabled: _animateFrameInsets && _usesConnectedFrameChrome enabled: _animateFrameInsets && _usesFrameBarChrome
NumberAnimation { NumberAnimation {
duration: Theme.shortDuration duration: Theme.shortDuration
easing.type: Easing.OutCubic easing.type: Easing.OutCubic
+12 -8
View File
@@ -108,7 +108,7 @@ PanelWindow {
triggerDashTab(2); triggerDashTab(2);
} }
readonly property bool usesOverlayLayer: CompositorService.framePeerSurfacesUseOverlayForScreen(barWindow.screen) || (barConfig?.showOverFullscreen ?? false) readonly property bool usesOverlayLayer: CompositorService.framePeerSurfacesUseOverlayForScreen(barWindow.screen) || (barConfig?.useOverlayLayer ?? false)
readonly property var dBarLayer: { readonly property var dBarLayer: {
switch (Quickshell.env("DMS_DANKBAR_LAYER")) { switch (Quickshell.env("DMS_DANKBAR_LAYER")) {
@@ -156,6 +156,9 @@ PanelWindow {
function onUsesConnectedFrameChromeChanged() { function onUsesConnectedFrameChromeChanged() {
_blurRebuildTimer.restart(); _blurRebuildTimer.restart();
} }
function onUsesFrameBarChromeChanged() {
_blurRebuildTimer.restart();
}
} }
Component { Component {
@@ -185,7 +188,7 @@ PanelWindow {
// In frame mode, FrameWindow owns the blur region for the entire screen edge // In frame mode, FrameWindow owns the blur region for the entire screen edge
// (including the bar area). The bar must not set its own competing blur region // (including the bar area). The bar must not set its own competing blur region
// so that frameBlurEnabled acts as the single control for all blur in frame mode. // so that frameBlurEnabled acts as the single control for all blur in frame mode.
if (SettingsData.frameEnabled && barWindow.usesConnectedFrameChrome) if (SettingsData.frameEnabled && barWindow.usesFrameBarChrome)
return; return;
const widgets = barWindow._blurWidgetItems.filter(w => w && w.visible && w.width > 0 && w.height > 0); const widgets = barWindow._blurWidgetItems.filter(w => w && w.visible && w.width > 0 && w.height > 0);
@@ -298,7 +301,7 @@ PanelWindow {
readonly property color _surfaceContainer: Theme.surfaceContainer readonly property color _surfaceContainer: Theme.surfaceContainer
readonly property string _barId: barConfig?.id ?? "default" readonly property string _barId: barConfig?.id ?? "default"
property real _backgroundAlpha: barConfig?.transparency ?? 1.0 property real _backgroundAlpha: barConfig?.transparency ?? 1.0
readonly property color _bgColor: (SettingsData.frameEnabled && usesConnectedFrameChrome) ? Qt.rgba(SettingsData.effectiveFrameColor.r, SettingsData.effectiveFrameColor.g, SettingsData.effectiveFrameColor.b, SettingsData.frameOpacity) : Theme.withAlpha(_surfaceContainer, _backgroundAlpha) readonly property color _bgColor: (SettingsData.frameEnabled && usesFrameBarChrome) ? Qt.rgba(SettingsData.effectiveFrameColor.r, SettingsData.effectiveFrameColor.g, SettingsData.effectiveFrameColor.b, SettingsData.frameOpacity) : Theme.withAlpha(_surfaceContainer, _backgroundAlpha)
function _updateBackgroundAlpha() { function _updateBackgroundAlpha() {
const live = SettingsData.barConfigs.find(c => c.id === _barId); const live = SettingsData.barConfigs.find(c => c.id === _barId);
@@ -323,10 +326,11 @@ PanelWindow {
property string screenName: modelData.name property string screenName: modelData.name
readonly property bool usesConnectedFrameChrome: CompositorService.usesConnectedFrameChromeForScreen(screenName) readonly property bool usesConnectedFrameChrome: CompositorService.usesConnectedFrameChromeForScreen(screenName)
readonly property bool usesFrameBarChrome: CompositorService.frameWindowVisibleForScreen(screenName)
// Flatten/spacing collapse for maximized windows is only for frame-integrated layout. // Flatten/spacing collapse for maximized windows is only for frame-integrated layout.
// When the bar draws its own pill, keep rounded corners and spacing like the dock. // When the bar draws its own pill, keep rounded corners and spacing like the dock.
readonly property bool flattenForMaximizedWindow: !SettingsData.frameEnabled || usesConnectedFrameChrome readonly property bool flattenForMaximizedWindow: !SettingsData.frameEnabled || usesFrameBarChrome
property bool hasMaximizedToplevel: false property bool hasMaximizedToplevel: false
property bool shouldHideForWindows: false property bool shouldHideForWindows: false
@@ -430,7 +434,7 @@ PanelWindow {
shouldHideForWindows = filtered.length > 0; shouldHideForWindows = filtered.length > 0;
} }
property real effectiveSpacing: (SettingsData.frameEnabled && usesConnectedFrameChrome) ? 0 : ((flattenForMaximizedWindow && hasMaximizedToplevel) ? 0 : (barConfig?.spacing ?? 4)) property real effectiveSpacing: (SettingsData.frameEnabled && usesFrameBarChrome) ? 0 : ((flattenForMaximizedWindow && hasMaximizedToplevel) ? 0 : (barConfig?.spacing ?? 4))
Behavior on effectiveSpacing { Behavior on effectiveSpacing {
enabled: barWindow.visible enabled: barWindow.visible
@@ -441,7 +445,7 @@ PanelWindow {
} }
readonly property int notificationCount: NotificationService.notifications.length readonly property int notificationCount: NotificationService.notifications.length
readonly property real effectiveBarThickness: (SettingsData.frameEnabled && usesConnectedFrameChrome) ? SettingsData.frameBarSize : Theme.snap(Math.max(barWindow.widgetThickness + (barConfig?.innerPadding ?? 4) + 4, Theme.barHeight - 4 - (8 - (barConfig?.innerPadding ?? 4))), _dpr) readonly property real effectiveBarThickness: (SettingsData.frameEnabled && usesFrameBarChrome) ? SettingsData.frameBarSize : Theme.snap(Math.max(barWindow.widgetThickness + (barConfig?.innerPadding ?? 4) + 4, Theme.barHeight - 4 - (8 - (barConfig?.innerPadding ?? 4))), _dpr)
readonly property bool effectiveOpenOnOverview: SettingsData.frameEnabled ? SettingsData.frameShowOnOverview : (barConfig?.openOnOverview ?? false) readonly property bool effectiveOpenOnOverview: SettingsData.frameEnabled ? SettingsData.frameShowOnOverview : (barConfig?.openOnOverview ?? false)
readonly property real widgetThickness: Theme.snap(Math.max(20, 26 + (barConfig?.innerPadding ?? 4) * 0.6), _dpr) readonly property real widgetThickness: Theme.snap(Math.max(20, 26 + (barConfig?.innerPadding ?? 4) * 0.6), _dpr)
@@ -639,9 +643,9 @@ PanelWindow {
anchors.left: !isVertical ? true : (barPos === SettingsData.Position.Left) anchors.left: !isVertical ? true : (barPos === SettingsData.Position.Left)
anchors.right: !isVertical ? true : (barPos === SettingsData.Position.Right) anchors.right: !isVertical ? true : (barPos === SettingsData.Position.Right)
readonly property bool reserveExclusiveWhenAutoHidden: SettingsData.connectedFrameModeActive && usesConnectedFrameChrome && !!barWindow.screen && SettingsData.isScreenInPreferences(barWindow.screen, SettingsData.frameScreenPreferences) readonly property bool reserveExclusiveWhenAutoHidden: SettingsData.frameEnabled && usesFrameBarChrome && !!barWindow.screen && SettingsData.isScreenInPreferences(barWindow.screen, SettingsData.frameScreenPreferences)
exclusiveZone: (!(barConfig?.visible ?? true) || (topBarCore.autoHide && !barWindow.reserveExclusiveWhenAutoHidden)) ? -1 : (barWindow.effectiveBarThickness + effectiveSpacing + (usesConnectedFrameChrome ? 0 : (barConfig?.bottomGap ?? 0))) exclusiveZone: (!(barConfig?.visible ?? true) || (topBarCore.autoHide && !barWindow.reserveExclusiveWhenAutoHidden)) ? -1 : (barWindow.effectiveBarThickness + effectiveSpacing + (usesFrameBarChrome ? 0 : (barConfig?.bottomGap ?? 0)))
Item { Item {
id: inputMask id: inputMask
+1 -1
View File
@@ -176,7 +176,7 @@ Variants {
readonly property string _dockScreenName: dock.modelData ? dock.modelData.name : (dock.screen ? dock.screen.name : "") readonly property string _dockScreenName: dock.modelData ? dock.modelData.name : (dock.screen ? dock.screen.name : "")
readonly property bool usesConnectedFrameChrome: CompositorService.usesConnectedFrameChromeForScreen(dock._dockScreenName) readonly property bool usesConnectedFrameChrome: CompositorService.usesConnectedFrameChromeForScreen(dock._dockScreenName)
readonly property bool usesOverlayLayer: CompositorService.framePeerSurfacesUseOverlayForScreen(dock._dockScreenName) || SettingsData.dockShowOverFullscreen readonly property bool usesOverlayLayer: CompositorService.framePeerSurfacesUseOverlayForScreen(dock._dockScreenName) || SettingsData.dockUseOverlayLayer
function _syncDockChromeState() { function _syncDockChromeState() {
if (!dock._dockScreenName) if (!dock._dockScreenName)
+1 -1
View File
@@ -48,7 +48,7 @@ Item {
case "top": case "top":
return false; return false;
default: default:
return (barConfig?.showOverFullscreen ?? false) || CompositorService.framePeerSurfacesUseOverlayForScreen(parentScreen); return (barConfig?.useOverlayLayer ?? false) || CompositorService.framePeerSurfacesUseOverlayForScreen(parentScreen);
} }
} }
+6 -6
View File
@@ -137,7 +137,7 @@ Item {
popupGapsAuto: defaultBar.popupGapsAuto ?? true, popupGapsAuto: defaultBar.popupGapsAuto ?? true,
popupGapsManual: defaultBar.popupGapsManual ?? 4, popupGapsManual: defaultBar.popupGapsManual ?? 4,
maximizeDetection: defaultBar.maximizeDetection ?? true, maximizeDetection: defaultBar.maximizeDetection ?? true,
showOverFullscreen: defaultBar.showOverFullscreen ?? false, useOverlayLayer: defaultBar.useOverlayLayer ?? false,
scrollEnabled: defaultBar.scrollEnabled ?? true, scrollEnabled: defaultBar.scrollEnabled ?? true,
scrollXBehavior: defaultBar.scrollXBehavior ?? "column", scrollXBehavior: defaultBar.scrollXBehavior ?? "column",
scrollYBehavior: defaultBar.scrollYBehavior ?? "workspace", scrollYBehavior: defaultBar.scrollYBehavior ?? "workspace",
@@ -729,14 +729,14 @@ Item {
} }
SettingsToggleRow { SettingsToggleRow {
settingKey: "barShowOverFullscreen" settingKey: "barUseOverlayLayer"
tags: ["bar", "fullscreen", "overlay", "layer"] tags: ["bar", "fullscreen", "overlay", "layer"]
text: I18n.tr("Show Over Fullscreen", "bar layer toggle: show the bar over fullscreen windows") text: I18n.tr("Use Overlay Layer", "bar layer toggle: use Wayland overlay layer")
description: I18n.tr("Use the overlay layer so this bar appears above fullscreen windows") description: I18n.tr("Place the bar on the Wayland overlay layer")
checked: selectedBarConfig?.showOverFullscreen ?? false checked: selectedBarConfig?.useOverlayLayer ?? false
onToggled: toggled => { onToggled: toggled => {
SettingsData.updateBarConfig(selectedBarId, { SettingsData.updateBarConfig(selectedBarId, {
showOverFullscreen: toggled useOverlayLayer: toggled
}); });
notifyHorizontalBarChange(); notifyHorizontalBarChange();
} }
+5 -5
View File
@@ -90,13 +90,13 @@ Item {
} }
SettingsToggleRow { SettingsToggleRow {
settingKey: "dockShowOverFullscreen" settingKey: "dockUseOverlayLayer"
tags: ["dock", "fullscreen", "overlay", "layer"] tags: ["dock", "fullscreen", "overlay", "layer"]
text: I18n.tr("Show Over Fullscreen", "dock layer toggle: show the dock over fullscreen windows") text: I18n.tr("Use Overlay Layer", "dock layer toggle: use Wayland overlay layer")
description: I18n.tr("Use the overlay layer so the dock appears above fullscreen windows") description: I18n.tr("Place the dock on the Wayland overlay layer")
checked: SettingsData.dockShowOverFullscreen checked: SettingsData.dockUseOverlayLayer
visible: SettingsData.showDock visible: SettingsData.showDock
onToggled: checked => SettingsData.set("dockShowOverFullscreen", checked) onToggled: checked => SettingsData.set("dockUseOverlayLayer", checked)
} }
} }
+4 -4
View File
@@ -69,12 +69,12 @@ Item {
} }
SettingsToggleRow { SettingsToggleRow {
settingKey: "launcherShowOverFullscreen" settingKey: "launcherUseOverlayLayer"
tags: ["launcher", "fullscreen", "overlay", "layer"] tags: ["launcher", "fullscreen", "overlay", "layer"]
text: I18n.tr("Show Over Fullscreen", "launcher layer toggle: show the launcher over fullscreen windows") text: I18n.tr("Use Overlay Layer", "launcher layer toggle: use Wayland overlay layer")
description: I18n.tr("Use the overlay layer when opening the launcher") description: I18n.tr("Use the overlay layer when opening the launcher")
checked: SettingsData.launcherShowOverFullscreen checked: SettingsData.launcherUseOverlayLayer
onToggled: checked => SettingsData.set("launcherShowOverFullscreen", checked) onToggled: checked => SettingsData.set("launcherUseOverlayLayer", checked)
} }
} }
+1 -1
View File
@@ -178,7 +178,7 @@ Item {
case "top": case "top":
return false; return false;
default: default:
return (barConfig?.showOverFullscreen ?? false) || CompositorService.framePeerSurfacesUseOverlayForScreen(targetScreen); return (barConfig?.useOverlayLayer ?? false) || CompositorService.framePeerSurfacesUseOverlayForScreen(targetScreen);
} }
} }
@@ -854,29 +854,6 @@
"icon": "layers", "icon": "layers",
"description": "Override the global shadow with per-bar settings" "description": "Override the global shadow with per-bar settings"
}, },
{
"section": "barShowOverFullscreen",
"label": "Show Over Fullscreen",
"tabIndex": 3,
"category": "Dank Bar",
"keywords": [
"above",
"appears",
"bar",
"dank",
"fullscreen",
"layer",
"over",
"overlay",
"panel",
"show",
"statusbar",
"taskbar",
"topbar",
"windows"
],
"description": "Use the overlay layer so this bar appears above fullscreen windows"
},
{ {
"section": "barSpacing", "section": "barSpacing",
"label": "Spacing", "label": "Spacing",
@@ -944,14 +921,32 @@
], ],
"icon": "opacity" "icon": "opacity"
}, },
{
"section": "barUseOverlayLayer",
"label": "Use Overlay Layer",
"tabIndex": 3,
"category": "Dank Bar",
"keywords": [
"bar",
"dank",
"fullscreen",
"layer",
"overlay",
"panel",
"place",
"statusbar",
"taskbar",
"topbar",
"wayland"
],
"description": "Place this bar on the Wayland overlay layer"
},
{ {
"section": "barVisibility", "section": "barVisibility",
"label": "Visibility", "label": "Visibility",
"tabIndex": 3, "tabIndex": 3,
"category": "Dank Bar", "category": "Dank Bar",
"keywords": [ "keywords": [
"above",
"appears",
"auto-hide", "auto-hide",
"autohide", "autohide",
"bar", "bar",
@@ -962,16 +957,17 @@
"layer", "layer",
"overlay", "overlay",
"panel", "panel",
"place",
"show", "show",
"statusbar", "statusbar",
"taskbar", "taskbar",
"topbar", "topbar",
"visibility", "visibility",
"visible", "visible",
"windows" "wayland"
], ],
"icon": "visibility_off", "icon": "visibility_off",
"description": "Use the overlay layer so this bar appears above fullscreen windows" "description": "Place this bar on the Wayland overlay layer"
}, },
{ {
"section": "workspaceDragReorder", "section": "workspaceDragReorder",
@@ -1757,27 +1753,6 @@
"taskbar" "taskbar"
] ]
}, },
{
"section": "dockShowOverFullscreen",
"label": "Show Over Fullscreen",
"tabIndex": 5,
"category": "Dock",
"keywords": [
"above",
"appears",
"dock",
"fullscreen",
"launcher bar",
"layer",
"over",
"overlay",
"panel",
"show",
"taskbar",
"windows"
],
"description": "Use the overlay layer so the dock appears above fullscreen windows"
},
{ {
"section": "dockShowOverflowBadge", "section": "dockShowOverflowBadge",
"label": "Show Overflow Badge Count", "label": "Show Overflow Badge Count",
@@ -1924,6 +1899,24 @@
"icon": "delete", "icon": "delete",
"description": "Place a trash bin at the end of the dock" "description": "Place a trash bin at the end of the dock"
}, },
{
"section": "dockUseOverlayLayer",
"label": "Use Overlay Layer",
"tabIndex": 5,
"category": "Dock",
"keywords": [
"dock",
"fullscreen",
"launcher bar",
"layer",
"overlay",
"panel",
"place",
"taskbar",
"wayland"
],
"description": "Place the dock on the Wayland overlay layer"
},
{ {
"section": "_tab_7", "section": "_tab_7",
"label": "Network", "label": "Network",
@@ -2401,29 +2394,6 @@
], ],
"description": "Show mode tabs and keyboard hints at the bottom." "description": "Show mode tabs and keyboard hints at the bottom."
}, },
{
"section": "launcherShowOverFullscreen",
"label": "Show Over Fullscreen",
"tabIndex": 9,
"category": "Launcher",
"keywords": [
"app drawer",
"app menu",
"applications",
"drawer",
"fullscreen",
"launcher",
"layer",
"menu",
"opening",
"over",
"overlay",
"show",
"start",
"start menu"
],
"description": "Use the overlay layer when opening the launcher"
},
{ {
"section": "launcherLogoSizeOffset", "section": "launcherLogoSizeOffset",
"label": "Size Offset", "label": "Size Offset",
@@ -2546,6 +2516,27 @@
], ],
"description": "Free VRAM/memory when the launcher is closed. May cause a slight delay when reopening." "description": "Free VRAM/memory when the launcher is closed. May cause a slight delay when reopening."
}, },
{
"section": "launcherUseOverlayLayer",
"label": "Use Overlay Layer",
"tabIndex": 9,
"category": "Launcher",
"keywords": [
"app drawer",
"app menu",
"applications",
"drawer",
"fullscreen",
"launcher",
"layer",
"menu",
"opening",
"overlay",
"start",
"start menu"
],
"description": "Use the overlay layer when opening the launcher"
},
{ {
"section": "matugenTemplateAlacritty", "section": "matugenTemplateAlacritty",
"label": "Alacritty", "label": "Alacritty",