Fix bg tracking, use slow spatial for detach, default spatial for everything else, adjust deform, move instead of width scale
81 lines
2.2 KiB
QML
81 lines
2.2 KiB
QML
pragma ComponentBehavior: Bound
|
|
|
|
import QtQuick
|
|
import Quickshell
|
|
import qs.config
|
|
import qs.modules.bar as Bar
|
|
|
|
Region {
|
|
id: root
|
|
|
|
required property Bar.BarWrapper bar
|
|
required property Panels panels
|
|
required property var win
|
|
|
|
x: bar.clampedWidth + win.dragMaskPadding
|
|
y: Config.border.clampedThickness + win.dragMaskPadding
|
|
width: win.width - bar.clampedWidth - Config.border.clampedThickness - win.dragMaskPadding * 2
|
|
height: win.height - Config.border.clampedThickness * 2 - win.dragMaskPadding * 2
|
|
intersection: Intersection.Xor
|
|
|
|
R {
|
|
panel: root.panels.dashboard
|
|
y: 0
|
|
height: panel.height * (1 - root.panels.dashboard.offsetScale) + Config.border.thickness
|
|
}
|
|
|
|
R {
|
|
panel: root.panels.launcher
|
|
y: root.win.height - height
|
|
height: panel.height * (1 - root.panels.launcher.offsetScale) + Config.border.thickness
|
|
}
|
|
|
|
R {
|
|
id: sessionRegion
|
|
|
|
panel: root.panels.sessionWrapper
|
|
x: root.win.width - width
|
|
width: panel.width * (1 - root.panels.session.offsetScale) + Config.border.thickness + sidebarRegion.width
|
|
}
|
|
|
|
R {
|
|
id: sidebarRegion
|
|
|
|
panel: root.panels.sidebar
|
|
x: root.win.width - width
|
|
width: panel.width * (1 - root.panels.sidebar.offsetScale) + Config.border.thickness
|
|
}
|
|
|
|
R {
|
|
panel: root.panels.osdWrapper
|
|
x: root.win.width - width
|
|
width: panel.width * (1 - root.panels.osd.offsetScale) + Config.border.thickness + sessionRegion.width
|
|
}
|
|
|
|
R {
|
|
panel: root.panels.notifications
|
|
y: 0
|
|
height: panel.height + Config.border.thickness
|
|
}
|
|
|
|
R {
|
|
panel: root.panels.utilities
|
|
y: root.win.height - height
|
|
height: panel.height * (1 - root.panels.utilities.offsetScale) + Config.border.thickness
|
|
}
|
|
|
|
R {
|
|
panel: root.panels.popoutsWrapper
|
|
width: panel.width * (1 - root.panels.popoutsWrapper.offsetScale)
|
|
}
|
|
|
|
component R: Region {
|
|
required property Item panel
|
|
|
|
x: panel.x + root.bar.implicitWidth
|
|
y: panel.y + Config.border.thickness
|
|
width: panel.width
|
|
height: panel.height
|
|
intersection: Intersection.Subtract
|
|
}
|
|
}
|