Spotlight pill does not shrink after its workspaces or widgets are turned off #46

Closed
opened 2026-10-01 00:39:53 +08:00 by Breadway · 0 comments
Owner

How found: Reported by the owner: in the stage's Settings, turning off Widgets and setting Workspaces to None leaves the pill at its old width with just the time in the middle, until the stage is closed. Turning them back on resizes correctly. Code: the pill window is anchored to the top edge only, so its width follows its content (src/main.rs apply_window_spec, apply_prefs).

Confidence: High. Reproduced by the owner. Cause inferred from GTK behaviour: a GTK4 window grows when its content needs more room but keeps its current size when content shrinks. Closing the stage fixes it only because the pill's layer change forces a fresh configure.

Explanation: Expected: the pill hugs its content after any change. Actual: it stays wide and empty until an unrelated layer change. The same applies whenever pill content shrinks on its own (a workspace closing, a widget disappearing, level mode ending). Impact: a visibly broken pill after using its own settings.

Fix (BAR-38 branch): after pill content changes, set the window's default width to its measured natural width.

**How found:** Reported by the owner: in the stage's Settings, turning off Widgets and setting Workspaces to None leaves the pill at its old width with just the time in the middle, until the stage is closed. Turning them back on resizes correctly. Code: the pill window is anchored to the top edge only, so its width follows its content (src/main.rs `apply_window_spec`, `apply_prefs`). **Confidence:** High. Reproduced by the owner. Cause inferred from GTK behaviour: a GTK4 window grows when its content needs more room but keeps its current size when content shrinks. Closing the stage fixes it only because the pill's layer change forces a fresh configure. **Explanation:** Expected: the pill hugs its content after any change. Actual: it stays wide and empty until an unrelated layer change. The same applies whenever pill content shrinks on its own (a workspace closing, a widget disappearing, level mode ending). Impact: a visibly broken pill after using its own settings. **Fix (BAR-38 branch):** after pill content changes, set the window's default width to its measured natural width.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Breadway/breadbar#46
No description provided.