Add a notch mode that splits the bar around a pocket-dots style notch

Settings → Notch switches it on. The bar becomes left and right islands
with a notch at the top centre. Super+C, Super+X and a click on the notch
open a three-column panel: dashboard pages on the left (Media,
Performance, Calendar; the wheel switches them), the Control Center tiles
and weather in the middle, and notifications on the right. The
Performance card opens the full "Your computer" view. The launcher drops
out of the notch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
mxandClaude Opus 5.5 committed 2026-11-12 16:39:35 +01:00
1 parent 178041edf9
commit 5217af4f67
20 files changed
+919 -14

No files matched your search

+44 -7
View File
@@ -2,6 +2,7 @@ pragma ComponentBehavior: Bound
import QtQuick
import QtQuick.Controls
import QtQuick.Layouts
import QtQuick.Shapes
import Quickshell
import Quickshell.Wayland
import "../components"
@@ -76,7 +77,11 @@ PanelWindow {
// A hovered mode pill names itself in the empty search bar.
property string pillHover: ""
readonly property int barHeight: 60
readonly property real maxBodyHeight: Math.min(460, root.height * 0.78 - barHeight - (root.height * 0.22))
// Notch mode: the launcher drops out of the notch at the top edge. The
// panel's top corners sit above the screen and concave ears join it there.
readonly property bool notch: ShellState.notchMode
readonly property real notchInset: notch ? panel.radius : 0
readonly property real maxBodyHeight: Math.min(460, root.height * 0.78 - barHeight - (notch ? 0 : root.height * 0.22))
// Clipboard mode shows the latest five rows; the rest scroll.
readonly property real clipboardRows: 5 * 48 - 2
// Emoji mode shows six rows of the grid; the rest scroll.
@@ -193,7 +198,7 @@ PanelWindow {
id: pills
objectName: "launcherPills"
x: panel.x + panel.width + 10
y: panel.y + (root.barHeight - root.pillSize) / 2
y: panel.y + root.notchInset + (root.barHeight - root.pillSize) / 2
spacing: 10
opacity: panel.opacity
scale: panel.scale
@@ -256,16 +261,47 @@ PanelWindow {
}
}
}
// Notch ears: concave fillets joining the panel to the screen's top edge.
Repeater {
model: root.notch ? [0, 1] : []
Shape {
id: earShape
required property int modelData
readonly property real e: BarDrawers.ear
x: modelData === 0 ? panel.x - e : panel.x + panel.width
y: 0
width: e
height: e
opacity: panel.opacity
preferredRendererType: Shape.CurveRenderer
ShapePath {
fillColor: panel.color
strokeColor: "transparent"
strokeWidth: 0
PathSvg {
path: earShape.modelData === 0 ? `M 0 0 L ${earShape.e} 0 L ${earShape.e} ${earShape.e} A ${earShape.e} ${earShape.e} 0 0 0 0 0 Z` : `M 0 0 L ${earShape.e} 0 A ${earShape.e} ${earShape.e} 0 0 0 0 ${earShape.e} Z`
}
}
ShapePath {
fillColor: "transparent"
strokeColor: panel.border.color
strokeWidth: 1
PathSvg {
path: earShape.modelData === 0 ? `M 0 0.5 A ${earShape.e} ${earShape.e} 0 0 1 ${earShape.e - 0.5} ${earShape.e}` : `M 0.5 ${earShape.e} A ${earShape.e} ${earShape.e} 0 0 1 ${earShape.e} 0.5`
}
}
}
}
GlassPanel {
id: panel
objectName: "launcherSurface"
x: Math.round((root.width - width) / 2)
y: Math.round(root.height * 0.22)
width: ShellState.launcherOpen ? root.targetWidth : Math.min(320, root.targetWidth)
height: root.barHeight + root.bodyHeight
y: root.notch ? -root.notchInset : Math.round(root.height * 0.22)
width: ShellState.launcherOpen ? root.targetWidth : root.notch ? ShellState.notchPillWidth : Math.min(320, root.targetWidth)
height: root.barHeight + root.bodyHeight + root.notchInset
radius: Math.min(Theme.radius + 6, root.barHeight / 2)
opacity: ShellState.launcherOpen ? 1 : 0
scale: ShellState.launcherOpen ? 1 : 1 - 0.04 * Theme.intensity
scale: ShellState.launcherOpen || root.notch ? 1 : 1 - 0.04 * Theme.intensity
clip: true
Behavior on width {
NumberAnimation {
@@ -301,6 +337,7 @@ PanelWindow {
anchors.left: parent.left
anchors.right: parent.right
anchors.top: parent.top
anchors.topMargin: root.notchInset
height: root.barHeight
anchors.leftMargin: 12
anchors.rightMargin: 18
@@ -401,7 +438,7 @@ PanelWindow {
anchors.right: parent.right
anchors.top: bar.bottom
anchors.bottom: parent.bottom
visible: root.bodyHeight > 0 || panel.height > root.barHeight + 1
visible: root.bodyHeight > 0 || panel.height > root.barHeight + root.notchInset + 1
Rectangle {
anchors.left: parent.left
anchors.right: parent.right