Skip to content

Leave self-floating windows out of the floating workspace open rule - #18749

Open
LordMelkor wants to merge 3 commits into
omacom:quattrofrom
LordMelkor:self-floating-open-rule
Open

LordMelkor wants to merge 3 commits into
omacom:quattrofrom
LordMelkor:self-floating-open-rule

Conversation

@LordMelkor

@LordMelkor LordMelkor commented Nov 13, 2026 •

Copy link
Copy Markdown

What changes

On floating workspaces, omarchy-floating-open-N forces 1100×760 centered geometry onto windows Hyprland already floats before rules run (X11 popup/dropdown menus, tooltips, utility/splash/transient/fixed-size windows, parented Wayland toplevels), misplacing context menus.

Note: No new shell test was added for this one-key declarative match rule; live after-state was checked with a standalone Xlib probe rather than re-testing every affected app.

Verification

  • bash test/shell.d/hyprland-floating-workspaces-test.sh passes (updated the rule-lifecycle test for window.open_early).
  • Standalone Xlib probe on Omarchy 4.5.0 / Hyprland 0.56.2 (x, y, w, h):
Window Requested Before After
Normal (100,140,600,400) (730,173,1100,734) (682,125,1100,734)
Popup menu (200,220,180,80) (754,197,1100,734) (200,220,180,80)

Screenshots

No screenshot — the geometry table above shows menus opening at their requested coordinates and size.

Fixes #18832

Fixes #21427

The open rule sized and centered every non-modal window on a floating
workspace, including windows Hyprland already floats on its own: X11
popup and dropdown menus, tooltips, utility windows, transient and
fixed-size windows. Menus then opened at app-window size, far from where
they were clicked. Hyprland decides that floating before rules apply, so
matching float = false leaves those windows at their own size.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Confidence Score: 5/5RetriggerView in Greptile

[Medium impact] The PR appears safe to merge; no actionable defect was confirmed.

Summary

Leaves windows that already float out of the floating-workspace size and position rule.

  • Popup menus keep their requested size on floating workspaces.

No actionable new issue was confirmed. Automated tests and live UI checks were not run during this review.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Window opens] --> B{Already floating?}
  B -->|Yes| C[Keep requested size and position]
  B -->|No, on floating workspace| D[Apply floating-workspace rule]
  D --> E[Claim window during window.open_early]
  E --> F[Keep permanent claim tag]
  F --> G[Tile window when floating mode ends]
Loading

Reviews (3) · Last reviewed commit: "Update the floating workspace open rule ..." · Reviewed by Greptile

With float = false in its match, the open rule stops matching a window as soon as its own float = true effect floats it, and Hyprland drops the rule's omarchy-mode-opened tag before window.open fires. claim_opened then found no tag, the window went unclaimed, and it stayed floating when the workspace went back to tiling. window.open_early still carries the tag, so the claim moves there.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@omarchybot omarchybot added the verified Omarchy Triage has verified that this issue is ready for final review label Nov 17, 2026
@omarchybot

Copy link
Copy Markdown
Collaborator

Reviewed and run on an Omarchy ISO worker (Hyprland 0.57.2). The menu fix works, but on its own it stopped the mode from claiming ordinary windows. I pushed a fix for that to your branch as 77c4e8c.

What was run. A raw Xlib probe mapped three managed windows on a workspace switched to floating with omarchy-hyprland-workspace-layout-toggle: a NORMAL window, a POPUP_MENU asking for 180×80 at 200,220, and a UTILITY window asking for 344×80. The workspace was then switched back to tiling.

  • On the base (3f974d0), the menu and the utility window both opened at 820×544, centred, and were tagged as claimed by the mode, so switching back to tiling tiled them too.
  • On e150dcd, the menu and the utility window kept their own size and position. But the NORMAL window came up at the mode's size with no omarchy-mode-opened or omarchy-mode-floated tag, and it stayed floating after the workspace went back to tiling. This happened on both runs. Logging both hooks showed the rule's tag present at window.open_early and gone by window.open. The rule's own float = true makes the window floating, the new float = false match then fails, and Hyprland drops the rule's tag before claim_opened ran on window.open. The sentence in the description saying the rule is not re-evaluated does not hold here.
  • On 77c4e8c, claim_opened runs on window.open_early, where the tag is still there. The NORMAL window is claimed and tiles again when the mode ends, and the menu and the utility window keep their own geometry and stay floating. The test case in test/shell.d/hyprland-floating-workspaces-test.sh now drops the rule's tag between the two hooks, so it fails if the claim moves back to window.open.

Before, on the base: the orange 180×80 menu and the green utility window both opened at 820×544 in the middle of the screen
After, at 77c4e8cbd: the orange menu sits at 200,220 at its own 180×80, the green utility window keeps its 344×80, and the blue normal window still gets the mode's size

The two captures show where each window opened. That each window tiles or stays floating when the mode ends comes from hyprctl clients output, not from these pictures.

Tests on the worker at 77c4e8c: ./test/cli passed. hyprland-workspace-layout-test.sh passed 14 of 14. hyprland-floating-workspaces-test.sh passed 30 of 31; the one failure is required command is available: node, because the worker has no Node, and the base fails the same way.

Second opinion: Codex Medium and muse-wonder via pi (thinking high) reviewed the change with the fix on top and found no defects. They agree with the above, though their independence is not guaranteed. muse-wonder pointed out that no test asserts the float = false match itself. I left that as is.

Related: this fixes the menu half of #16736; the unmaximize half is #17491, so the PR does not close it. A UTILITY window that is typed before it maps is now left alone, which is the #17540 case. The report there says that toolbar maps tiled, so whether it is covered needs a check with that app.

Waiting on: you, for one edit to the description. Drop the sentence about rules re-checked on tag changes, and say that the claim moved to window.open_early because the float = false match lets go of the window once the rule floats it. After that it is the maintainer's call.

@omarchybot

Copy link
Copy Markdown
Collaborator

The description now correctly explains why the claim runs on window.open_early; the earlier description-edit request is addressed. GPT-6 in Codex (reasoning effort not exposed) checked it against the unchanged head 77c4e8cbdb9e04811c8883afe77b40a8dd8cf49c and read the earlier worker logs. No code changes or fresh runtime tests were made in this pass.

My classification is still bug, but the configured second classifier, deepseek-v4p1-flash, returned no valid classification for this head. Classification remains unsettled, so this now waits on maintainer review. No new second opinion on the pull request completed in this pass.

@omarchybot omarchybot added bug Something isn't working and removed bug Something isn't working labels Nov 22, 2026
@omarchybot

Copy link
Copy Markdown
Collaborator

Classification is now settled as bug for unchanged head 77c4e8cbdb9e04811c8883afe77b40a8dd8cf49c. GPT-6 in Codex (reasoning effort not exposed) checked the current diff, description, surrounding code and prior worker evidence. Opus 5.5 High and muse-wonder via pi (thinking high) provided a fresh second opinion and found no concrete defect. Their agreement is not guaranteed independent.

Verification still rests on the November 17 ISO-worker run: popup and utility probes kept their geometry, and an ordinary window was claimed and tiled again when floating mode ended. CLI checks passed, workspace-layout tests passed 14/14, and floating-workspace tests passed 30/31; the missing-Node failure also occurred on the base. No runtime tests were rerun in this pass, and the actual toolbar from #17540 remains unverified.

The verified label is retained. Adding ready was refused because the existing readiness judgment remains below its required threshold. This now waits on maintainer review.

@omarchybot

Copy link
Copy Markdown
Collaborator

The new link to #18832 is supported by its LibreOffice worker reproduction at unchanged head 77c4e8cbdb9e04811c8883afe77b40a8dd8cf49c. I checked that session's base, head and restored-base logs and its before/after captures: the splash changed from an oversized 820×544 window with repeated logos to its natural 644×199 with one logo. The normal Start Center was still claimed and returned to tiling when floating mode ended. These observations used Hyprland 0.57.2, LibreOffice 26.8.3 and scale 1; the reporter's exact versions and fractional scale remain untested.

GPT-6 in Codex (reasoning effort not exposed) reviewed this additional evidence; no new code changes or runtime tests were made in this pass. A fresh second opinion could not run: Opus 5.5 High hit its weekly limit, confirmed by omabot review --ping. The earlier clean code review remains separate from this new evidence. The existing readiness refusal still stands, so this remains waiting on maintainer review.

@omarchybot omarchybot removed the verified Omarchy Triage has verified that this issue is ready for final review label Nov 29, 2026
Keep the early workspace claim when resolving the conflict with the current workspace open handler. Use the persistent claim for Steam games because the temporary rule tag has already dropped by window.open.

Co-Authored-By: GPT-6 in Codex <noreply@openai.com>
@omarchybot omarchybot added the verified Omarchy Triage has verified that this issue is ready for final review label Dec 3, 2026
@omarchybot

Copy link
Copy Markdown
Collaborator

Recommend: Hold — the Tests workflow needs maintainer approval and the readiness check fell short. Tests workflow

3f086a3855 resolves the quattro conflict and updates the Steam handler to use the persistent workspace claim. On an Omarchy ISO worker the LibreOffice splash kept its natural size, the Start Center returned to tiling, and a simulated native Steam game still went fullscreen. CLI and three Hyprland suites passed. GPT-6 High in Codex and Opus 5.5 High found no remaining code defects. Reviewer independence is unverified.

Before on quattro, LibreOffice repeats its logo in an 820×544 splash
After on the PR, LibreOffice shows one logo in its 644×199 splash

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working verified Omarchy Triage has verified that this issue is ready for final review

Projects

None yet

2 participants