Compare commits

..

No commits in common. "d5706742245c159f3aa25521b8529431a779b45d" and "4f2053b584f6b74a4b985d331dd065a0e4969ba8" have entirely different histories.

View file

@ -214,16 +214,14 @@ in
visible = false; visible = false;
} }
// Lock/reboot/shutdown spawn via Quickshell.execDetached fully // Power actions go through Hyprland's exec dispatcher so they
// detached, so a quickshell restart can never kill a running // are NOT children of quickshell a quickshell restart must
// hyprlock. Logout (empty cmd) goes through Hyprland IPC; with a // never kill a running hyprlock.
// Lua config the dispatch body is evaluated as a Lua dispatcher
// expression, so it must use hl.dsp.* syntax, not hyprlang's.
readonly property var powerActions: [ readonly property var powerActions: [
{ name: "Lock", glyph: "", cmd: [Commands.hyprlock] }, { name: "Lock", glyph: "", dispatch: "exec " + Commands.hyprlock },
{ name: "Logout", glyph: "", cmd: [] }, { name: "Logout", glyph: "", dispatch: "exit" },
{ name: "Reboot", glyph: "", cmd: [Commands.systemctl, "reboot"] }, { name: "Reboot", glyph: "", dispatch: "exec " + Commands.systemctl + " reboot" },
{ name: "Shutdown", glyph: "", cmd: [Commands.systemctl, "poweroff"] } { name: "Shutdown", glyph: "", dispatch: "exec " + Commands.systemctl + " poweroff" }
] ]
function score(name, extra, q) { function score(name, extra, q) {
@ -257,8 +255,7 @@ in
function activate(item) { function activate(item) {
if (!item) return; if (!item) return;
if (mode === "power") { if (mode === "power") {
if (item.cmd.length === 0) Hyprland.dispatch("hl.dsp.exit()"); Hyprland.dispatch(item.dispatch);
else Quickshell.execDetached(item.cmd);
} else { } else {
item.execute(); item.execute();
} }
@ -472,11 +469,8 @@ in
// Bar bottom border left segment (up to gap) // Bar bottom border left segment (up to gap)
Rectangle { Rectangle {
id: barBorderLeft id: barBorderLeft
// Inset (inside the bar) so it lines up with the inset ear x: 0; y: 30
// and dropdown borders; overlaps 8px into the gap to meet width: bar.hasGap ? bar.gapLeft : bar.width
// the ear curve's tapered start.
x: 0; y: 30 - Theme.borderWidth
width: bar.hasGap ? bar.gapLeft + 8 : bar.width
height: Theme.borderWidth height: Theme.borderWidth
color: Theme.base03 color: Theme.base03
} }
@ -485,8 +479,8 @@ in
Rectangle { Rectangle {
id: barBorderRight id: barBorderRight
visible: bar.hasGap && !bar.gapAlignRight visible: bar.hasGap && !bar.gapAlignRight
x: bar.gapRight - 8 x: bar.gapRight
y: 30 - Theme.borderWidth y: 30
width: bar.width - x width: bar.width - x
height: Theme.borderWidth height: Theme.borderWidth
color: Theme.base03 color: Theme.base03
@ -1141,9 +1135,8 @@ in
ctx.strokeStyle = Theme.base03; ctx.strokeStyle = Theme.base03;
ctx.lineWidth = b; ctx.lineWidth = b;
ctx.beginPath(); ctx.beginPath();
// Start just under the bar the ear band tapers // Start below the top ear, go down left side
// through the first few px and this fills behind it ctx.moveTo(o, r);
ctx.moveTo(o, b);
ctx.lineTo(o, h - r); ctx.lineTo(o, h - r);
// Bottom-left curve arc centered on the corner circle so // Bottom-left curve arc centered on the corner circle so
// the stroke's outer edge matches the bg corner exactly // the stroke's outer edge matches the bg corner exactly
@ -1156,8 +1149,8 @@ in
ctx.lineTo(w - r - o, h - o); ctx.lineTo(w - r - o, h - o);
// Bottom-right curve // Bottom-right curve
ctx.arc(w - r, h - r, r - o, Math.PI / 2, 0, true); ctx.arc(w - r, h - r, r - o, Math.PI / 2, 0, true);
// Right side up to just under the bar // Right side up (stop at ear height)
ctx.lineTo(w - o, b); ctx.lineTo(w - o, r);
} }
ctx.stroke(); ctx.stroke();
} }
@ -2442,12 +2435,12 @@ in
ctx.strokeStyle = Theme.base03; ctx.strokeStyle = Theme.base03;
ctx.lineWidth = b; ctx.lineWidth = b;
ctx.beginPath(); ctx.beginPath();
ctx.moveTo(o, b); ctx.moveTo(o, r);
ctx.lineTo(o, h - r); ctx.lineTo(o, h - r);
ctx.arc(r, h - r, r - o, Math.PI, Math.PI / 2, true); ctx.arc(r, h - r, r - o, Math.PI, Math.PI / 2, true);
ctx.lineTo(w - r - o, h - o); ctx.lineTo(w - r - o, h - o);
ctx.arc(w - r, h - r, r - o, Math.PI / 2, 0, true); ctx.arc(w - r, h - r, r - o, Math.PI / 2, 0, true);
ctx.lineTo(w - o, b); ctx.lineTo(w - o, r);
ctx.stroke(); ctx.stroke();
} }
onWidthChanged: requestPaint() onWidthChanged: requestPaint()