XCL window: window_pos setting; free the cursor while dragging the window #176
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!176
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/176/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@ryosen0 on GitHub · 2026-11-23 18:58 UTC · original
ryosen0:window-position→main· +118 −5 · 3 files · 2 commits · merged 2026-11-23 21:08 UTCTwo related window fixes, both reproduced on a 4-monitor desktop (one portrait 440x1920).
1.
window_possetting (commit 1). The XCL window was created withCW_USEDEFAULTfor its position; Windows may place it on any monitor — observed landing on the portrait side monitor, mostly off-screen. Newwindow_posin xcl.toml (XCL_WINDOW_POSoverrides):"auto"(default, unchanged),"center"(primary work area),"x,y"(clamped into the nearest monitor's work area). Verified: with"center"the rect is (312,160)-(1608,919) on the primary 1920x1080.2. Cursor teleport while dragging the window (commit 2). While the window has the focus, kbm clips the cursor to the client centre (the mouse plays the right stick).
WM_MOVEre-clipped it during a title-bar drag: the cursor teleported back to the moving centre mid-drag and broke the drag. NowWM_ENTERSIZEMOVEreleases the clip for the whole drag/resize loop andWM_EXITSIZEMOVErestores it. Verified interactively: the window drags smoothly, the cursor stays hidden in the client area otherwise.Tests:
window_position_modes(all modes, clamp, env override), kbm suite 7 passed.@ivall on GitHub · 2026-11-23 21:09 UTC · original
Merged (main
6da33fa). Checked on an RX 9070 (RDNA4) with the 22 PRs merged together on maineaa36b6:cargo build --workspace && cargo test --workspace -- --test-threads=4- 582 unit tests passed, 0 failed (20 ignored), the integration and e2e tests passed too; and the retail game still reaches its first menu (646 frames in 30 s, no device removal).