move bar to root window
This commit is contained in:
parent
8c59137716
commit
dc35aa770f
2 changed files with 75 additions and 51 deletions
|
|
@ -4,8 +4,9 @@ import "launcher"
|
||||||
import "pomodoro"
|
import "pomodoro"
|
||||||
import "powermenu"
|
import "powermenu"
|
||||||
import "storybook"
|
import "storybook"
|
||||||
import Quickshell
|
|
||||||
import QtQuick
|
import QtQuick
|
||||||
|
import Quickshell
|
||||||
|
import Quickshell.Wayland
|
||||||
|
|
||||||
Variants {
|
Variants {
|
||||||
model: Quickshell.screens
|
model: Quickshell.screens
|
||||||
|
|
@ -15,7 +16,65 @@ Variants {
|
||||||
|
|
||||||
required property ShellScreen modelData
|
required property ShellScreen modelData
|
||||||
|
|
||||||
Bar {}
|
PanelWindow {
|
||||||
|
id: exclusionZone
|
||||||
|
|
||||||
|
anchors.top: true
|
||||||
|
anchors.left: true
|
||||||
|
anchors.right: true
|
||||||
|
|
||||||
|
implicitWidth: bar.width
|
||||||
|
implicitHeight: bar.height
|
||||||
|
|
||||||
|
color: "transparent"
|
||||||
|
}
|
||||||
|
|
||||||
|
PanelWindow {
|
||||||
|
id: topWindow
|
||||||
|
|
||||||
|
anchors.top: true
|
||||||
|
anchors.left: true
|
||||||
|
anchors.right: true
|
||||||
|
anchors.bottom: true
|
||||||
|
|
||||||
|
color: 'transparent'
|
||||||
|
|
||||||
|
WlrLayershell.exclusionMode: ExclusionMode.Ignore
|
||||||
|
WlrLayershell.layer: WlrLayer.Top
|
||||||
|
|
||||||
|
mask: Region {
|
||||||
|
width: topWindow.width
|
||||||
|
height: topWindow.height
|
||||||
|
intersection: Intersection.Xor
|
||||||
|
regions: regions.instances
|
||||||
|
}
|
||||||
|
|
||||||
|
Variants {
|
||||||
|
id: regions
|
||||||
|
|
||||||
|
model: panels.children
|
||||||
|
|
||||||
|
Region {
|
||||||
|
required property Item modelData
|
||||||
|
|
||||||
|
x: modelData.x
|
||||||
|
y: modelData.y
|
||||||
|
width: modelData.width
|
||||||
|
height: modelData.height
|
||||||
|
intersection: Intersection.Subtract
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Item {
|
||||||
|
id: panels
|
||||||
|
|
||||||
|
anchors.fill: parent
|
||||||
|
|
||||||
|
Bar {
|
||||||
|
id: bar
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
Launcher {}
|
Launcher {}
|
||||||
Pomodoro {}
|
Pomodoro {}
|
||||||
PowerMenu {}
|
PowerMenu {}
|
||||||
|
|
|
||||||
|
|
@ -3,55 +3,29 @@ import "components/bluetooth"
|
||||||
import "components/hyprland"
|
import "components/hyprland"
|
||||||
import "components/notifications"
|
import "components/notifications"
|
||||||
import "components/tray"
|
import "components/tray"
|
||||||
|
import qs.components
|
||||||
import qs.config
|
import qs.config
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Quickshell
|
|
||||||
import Quickshell.Wayland
|
|
||||||
|
|
||||||
PanelWindow {
|
StyledWrapperRectangle {
|
||||||
id: parentWindow
|
id: root
|
||||||
|
|
||||||
anchors.top: true
|
anchors.left: parent.left
|
||||||
anchors.left: true
|
anchors.right: parent.right
|
||||||
anchors.right: true
|
anchors.top: parent.top
|
||||||
|
anchors.leftMargin: 8
|
||||||
|
anchors.rightMargin: 8
|
||||||
|
anchors.topMargin: 6
|
||||||
|
anchors.bottomMargin: 6
|
||||||
|
|
||||||
implicitHeight: 50
|
margin: 4
|
||||||
color: 'transparent'
|
|
||||||
|
|
||||||
WlrLayershell.layer: WlrLayer.Top
|
RowLayout {
|
||||||
|
|
||||||
Item {
|
|
||||||
|
|
||||||
anchors.fill: parent
|
|
||||||
anchors.leftMargin: 8
|
|
||||||
anchors.rightMargin: 8
|
|
||||||
anchors.topMargin: 4
|
|
||||||
anchors.bottomMargin: 4
|
|
||||||
|
|
||||||
Rectangle {
|
|
||||||
id: background
|
|
||||||
anchors.fill: parent
|
|
||||||
color: Styling.theme.base100
|
|
||||||
radius: Styling.theme.radiusBox
|
|
||||||
|
|
||||||
border {
|
|
||||||
color: Styling.theme.base200
|
|
||||||
width: Styling.theme.border
|
|
||||||
pixelAligned: true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: leftbar
|
id: leftbar
|
||||||
|
|
||||||
anchors.left: parent.left
|
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
|
||||||
|
|
||||||
anchors.leftMargin: 8
|
|
||||||
anchors.topMargin: 4
|
|
||||||
anchors.bottomMargin: 4
|
|
||||||
|
|
||||||
spacing: Styling.layout.spacing.base
|
spacing: Styling.layout.spacing.base
|
||||||
|
|
||||||
SystemLogo {
|
SystemLogo {
|
||||||
|
|
@ -66,11 +40,7 @@ PanelWindow {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: centerbar
|
id: centerbar
|
||||||
|
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
|
||||||
|
|
||||||
anchors.topMargin: 4
|
|
||||||
anchors.bottomMargin: 4
|
|
||||||
|
|
||||||
spacing: Styling.layout.spacing.base
|
spacing: Styling.layout.spacing.base
|
||||||
|
|
||||||
|
|
@ -80,12 +50,7 @@ PanelWindow {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: rightbar
|
id: rightbar
|
||||||
|
|
||||||
anchors.right: parent.right
|
Layout.alignment: Qt.AlignRight
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
|
||||||
|
|
||||||
anchors.rightMargin: 8
|
|
||||||
anchors.topMargin: 4
|
|
||||||
anchors.bottomMargin: 4
|
|
||||||
|
|
||||||
spacing: Styling.layout.spacing.base
|
spacing: Styling.layout.spacing.base
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue