quickshell: column merge is geometric — detaching panels release the frame border
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
0632777245
commit
8413ac293e
1 changed files with 10 additions and 4 deletions
|
|
@ -518,7 +518,7 @@ in
|
|||
// dropdown's bottom curve and follows the morph.
|
||||
Rectangle {
|
||||
x: bar.width - Theme.frameWidth - Theme.borderWidth / 2
|
||||
y: chrome.visible && chrome.flushRight ? 30 + chrome.height + 8 : 38
|
||||
y: chrome.mergedRight ? 30 + chrome.height + 8 : 38
|
||||
width: Theme.borderWidth
|
||||
height: Math.max(0, bar.height - Theme.frameWidth - 8 - y)
|
||||
color: Theme.base03
|
||||
|
|
@ -527,7 +527,7 @@ in
|
|||
// Frame top-right inner corner — hidden while a flush-right
|
||||
// dropdown is merged into the column there.
|
||||
Shape {
|
||||
visible: !(chrome.visible && chrome.flushRight)
|
||||
visible: !chrome.mergedRight
|
||||
preferredRendererType: Shape.CurveRenderer
|
||||
ShapePath {
|
||||
fillColor: "transparent"
|
||||
|
|
@ -1291,6 +1291,12 @@ in
|
|||
property real openH: bar.activeDropdown ? tH : 0
|
||||
property bool snap: false
|
||||
readonly property real stubW: 32
|
||||
// True only while the panel's right edge actually touches
|
||||
// the frame column — the flush shape and the column-border
|
||||
// gap key off this, so a detaching (shrinking) panel
|
||||
// releases the column instead of dragging its border.
|
||||
readonly property bool mergedRight: visible && flushRight
|
||||
&& x + width >= bar.width - Theme.frameWidth - 0.5
|
||||
|
||||
// Grow-from / shrink-to the widget that owns the dropdown:
|
||||
// the panel opens as a small stub on the button and
|
||||
|
|
@ -1354,12 +1360,12 @@ in
|
|||
}
|
||||
|
||||
PanelShape {
|
||||
visible: !chrome.flushRight
|
||||
visible: !chrome.mergedRight
|
||||
width: chrome.width
|
||||
height: chrome.height
|
||||
}
|
||||
PanelShapeFlush {
|
||||
visible: chrome.flushRight
|
||||
visible: chrome.mergedRight
|
||||
width: chrome.width
|
||||
height: chrome.height
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue