Skip to content

Hotkeys: reserve X/Y/Z, bindable keys, settings docs, reject toasts - #236

Merged
trailcode merged 2 commits into
mainfrom
Trailcode/hotkeys-fix
Aug 1, 2026
Merged

Hotkeys: reserve X/Y/Z, bindable keys, settings docs, reject toasts#236
trailcode merged 2 commits into
mainfrom
Trailcode/hotkeys-fix

Conversation

@trailcode

@trailcode trailcode commented Aug 1, 2026

Copy link
Copy Markdown
Owner

Summary

  • Fixes Move/Rotate axis keys being stolen when Settings binds unmodified X/Y/Z (reserve in is_reserved_chord; drop on load).
  • Rejects non-round-trippable remap keys (punctuation/numpad) via is_bindable_key; toast + inline message on unsupported, reserved, and conflict (including Reset).
  • Documents remapping in usage-settings.md#keyboard-shortcuts; Settings ? links there.

Closes #235

Test plan

  • Settings: try assign unmodified X/Y/Z — reserved toast; Move/Rotate X/Y/Z still toggle axes.
  • Try assign comma or period — unsupported toast; no opaque KeyN saved.
  • Assign a chord already used by another action — conflict toast; Reset conflict when factory chord taken.
  • ? on Keyboard shortcuts opens settings guide (verbosity high enough).
  • Reload settings with a hand-edited "X" binding — dropped on load.
  • Docs: review usage-settings.md#keyboard-shortcuts and links from usage.md / sketch hotkeys.

Note

Low Risk
Localized to hotkey capture, load/save of gui.hotkeys, and documentation; no changes to core modeling or auth paths.

Overview
Tightens Settings → Keyboard shortcuts so remaps cannot break Move/Rotate or save unreadable chords.

Validation — Adds is_bindable_key (letters, digits, Space, and named keys that round-trip in JSON); punctuation and numpad are rejected at capture, in set_chord, and when loading gui.hotkeys. Unmodified X / Y / Z are now reserved in is_reserved_chord so axis constraints and rotation-axis pick stay available; invalid stored bindings are dropped on load.

UX — Unsupported, reserved, and conflict outcomes (including per-row Reset) call show_message for a status toast in addition to the inline table message. Settings adds a ? link (doc_urls::k_hotkeys) and updated help copy.

Docs — New Keyboard shortcuts section in usage-settings.md; usage.md / usage-sketch.md point there; CHANGELOG.md and src/doc/gui.md updated.

Reviewed by Cursor Bugbot for commit e2cb60c. Bugbot is set up for automated code reviews on this repo. Configure here.

@trailcode
trailcode merged commit 0339154 into main Aug 1, 2026
4 checks passed
@trailcode
trailcode deleted the Trailcode/hotkeys-fix branch August 1, 2026 16:28
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.

Hotkeys: reserve Move/Rotate X/Y/Z, bindable keys, settings docs and reject toasts

1 participant