Skip to content

feat(view): anchor the zoomed view to the screen centre (0.32.0) (#512) - #627

Merged
Maxaubert merged 6 commits into
mainfrom
feat/512-anchor-centre
Nov 30, 2026
Merged

Maxaubert merged 6 commits into
mainfrom
feat/512-anchor-centre

Conversation

@Maxaubert

Copy link
Copy Markdown
Owner

Closes #512.

What

A new extra key, Anchor to centre (Settings > Hotkeys > Extra keys). Like Hide pointer and Inspect mode it ships unbound with its switch on. Press it to keep the zoomed view on the middle of the screen; press again to follow the pointer.

  • While anchored and zoomed, nothing moves the view: not the pointer, not game mouselook (raw deltas), not caret/focus/Java tracking, pan keys, edge mode, recenter or the pan glide. Zoom in/out scales about the centre.
  • The pointer stays free: Wind never moves it, clicks land where it really is, and it can leave the zoomed area.
  • Toggling snaps: on jumps to the centre; off jumps back to the pointer (free sessions) or keeps panning from the centre (mouselook games).
  • Inspect wins while on. The state survives zoom-out, reloads and profile switches, and clears when its key is removed (switch off, unbound, a profile without it) so it never sticks.
  • Works in transform Native, transform Wind (txNativeCursor=0) and render.

How

  • src/track/fixed_view.h (pure, tested): the monitor centre, clamped by the MPO wall when armed (crosses it above ~17.7x on 3840 px). Keyboard pan now uses the same ClampViewCentre.
  • StepTracking: one more detached-view branch (t.fixedEff). Detached already means no weld, DWM centring off (one private forced write), input transform of the fixed rect.
  • Gates: panArmed, trackEnabled, glideOk, warmAllowed, the edge-mode lock-tell hide, recenter. Off edge resets the mapper to the pointer in free sessions (render would otherwise weld the pointer to the centre).
  • Key: RegisterHotKey (id 0xB004) like Hide pointer. A combo that fails to register now logs a Warn (Hide pointer too).
  • Ini: fixedViewVk, fixedViewMods, fixedViewOn (per profile, default unbound / on).
  • UI: the row, defaults, KEY_SLOTS. Also fixes a middle click on a keyboard-only key box starting autoscroll and eating the next key (surfaced because the Hotkeys page now scrolls).
  • Docs 02/05/06/07/08, README, CLAUDE.md. Version 0.32.0.

Tests

  • build.bat test 720/720, build.bat check, copyright gate.
  • ui/: npm run test:rules 5/5, Playwright 219/219.
  • Field test on the signed UIAccess build: pending (desktop in all three engines, a mouselook shooter).

🤖 Generated with Claude Code

https://claude.ai/code/session_01Kg7JN3dEn7yoXtDj7EBqMT

Maxaubert and others added 6 commits November 30, 2026 13:00
A middle click on a keyboard-only key box no longer starts autoscroll,
which ate the next key once the Hotkeys page began to scroll.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Kg7JN3dEn7yoXtDj7EBqMT
- Release the anchor when a reload leaves no registered key, also when a
  new combo fails to register.
- Hide edge-pinned motion of the free pointer from the lock tell while
  anchored, so a corner push never reads LOCKED.
- Judge the anchor-off reset on this tick's lock, after ResolvePanDelta.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Kg7JN3dEn7yoXtDj7EBqMT
@Maxaubert
Maxaubert merged commit 65ebadf into main Nov 30, 2026
1 check passed
@Maxaubert
Maxaubert deleted the feat/512-anchor-centre branch November 30, 2026 12:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

add anchoring to the center of the screen

1 participant