Repository navigation
Include open special workspaces in the screen-recording picker - #11441
Tunahanyrd wants to merge 1 commit into
Conversation
|
Reviewed at e4f6d7d, and the bug is real. Reproduced on a disposable Omarchy VM (Hyprland 0.56.2) with a second display added at 1280,0 at scale 2 and a terminal on each display, focus on the first. On Tests on the same VM: The diff is about as small as this fix can be, and I found no defects in it. Two things the maintainer should know:
This review was one model's, Claude Opus 5.5. There was no second opinion: the reviewer, Codex Medium, answers, but today's review budget was spent before this item. That review is still owed before this can be marked ready. Labelled |
|
@Tunahanyrd, this conflicted with What I changed on your branch:
Checked on a disposable Omarchy VM (Hyprland 0.57.2), with the scratchpad open over an otherwise empty workspace and one terminal on it. The before and after below are cropped to that display:
The screenshots show where the cursor landed, not slurp's highlight. What was picked is the geometry listed above. The second opinion was Codex Medium and muse-wonder (via pi, thinking high), over two rounds. Codex found the name-collision problem, which e3a5d1f fixes. The second round, on that fix, came back clean from both. The last commit only changes a comment, and the picker test was re-run on it. Both models agreed that the special-workspace part is what's left worth keeping after #19030; that agreement came after my own reading, and their independence isn't guaranteed. One limit for the maintainer. muse-wonder raised it and I agree with it: the picker and slurp both pick the smallest rectangle under the cursor. A full-size scratchpad window over a workspace with tiled windows still loses to the smaller windows underneath, both on hover and for Tab. The Quake console's smaller panel, and a scratchpad over an empty workspace, work. This is no worse than on Waiting on you: the title and description still describe the all-displays change and say draft. Could you update them to describe the special-workspace fix? After that it goes to the maintainer. |
[Medium impact] No new blocking issue was found in the reviewed changes. SummaryThe picker now includes windows from open special workspaces alongside windows from each display’s active workspace.
Reviews (2) · Last reviewed commit: "Include open special workspaces in the c..." · Reviewed by Greptile |
Key visible workspaces by id, falling back to names for special workspaces on Hyprland 0.57. Preserve multi-monitor selection and exclude inactive workspaces with colliding names. Co-authored-by: Omarchybot <317366263+omarchybot@users.noreply.github.com>
935515a to
686f733
Compare
|
Read the revised description, the diff at Classification is unsettled: GPT-6 in Codex (high effort) calls omitting a visible scratchpad window from the picker a bug; the configured classifier, DeepSeek v4p1 Flash via pi (effort unspecified), returned |


What changes
The screen-recording region picker omits windows on an open special workspace, including the scratchpad and Quake console. Include each laid-out monitor's open special workspace alongside its active workspace when collecting window rectangles.
Match workspaces by ID when present, falling back to the name for Hyprland 0.57 special workspaces, which have no ID. This keeps compatibility with older negative special-workspace IDs and prevents an inactive normal workspace with a duplicate name from leaking its windows into the picker. Closed special workspaces and hidden group members remain excluded.
#19030 already supplied the multi-monitor behavior. This PR now contains only the remaining special-workspace fix and its regression coverage, rebased onto
quattroatc3c8acf1eas one commit. The capture implementation is unchanged from the reviewed935515ae6; the fixture additionally covers older negative IDs, a closed special workspace and a hidden special-workspace client. Omarchybot's fixes are retained and credited.Verification
Ran the following against the rebased tree in isolated Bubblewrap sandboxes with networking disabled and the real home directory and desktop session unavailable:
bash test/shell.d/capture-picker-binds-test.sh: passed. Covers both special-workspace representations, inactive workspace name collisions, closed special workspaces, hidden clients and the existing unfocused-monitor behavior.bin/omarchy-capture-regionreplaced by currentquattro's version, because the special-workspace rectangles are missing; it passes with the fix.bash test/shell.d/screenrecording-test.sh: passed, 40 checks.bash test/shell.d/screenrecording-process-test.sh: passed, 10 checks.bash test/shell.d/crash-capture-test.sh: passed, 28 checks.bash test/cli: passed, 136 checks. The isolated environment emitted missing theme-directory/fontconfig warnings during safe-dispatch probes; those checks still passed.git diff --check: passed.Full
test/alland a new live desktop interaction were not run during this revision. The existing Hyprland 0.57.2 VM review exercised this same capture implementation: with a scratchpad over an empty workspace, Tab selects its terminal and Enter returns its rectangle; onquattrono window is offered and Enter selects the whole monitor.Screenshots
Existing before/after evidence from omarchybot's VM review, linked above. These images show the cursor position after Tab; the selected geometry was verified separately in that review.
Before: no scratchpad window is offered.
After: Tab moves to the scratchpad terminal.
Known limitation
Selection still follows slurp's smallest-rectangle behavior rather than window stacking order. A large scratchpad covering smaller tiled windows can therefore lose selection to the windows underneath. This existing occlusion limitation remains outside this fix; the PR adds the missing candidates without changing selection precedence.