feat(menu): tabbed category layout for in-game options with bumper and Q/E navigation #588

Merged
oscarlosu-lab merged 1 commit from feat/tabbed-options-menu into main 2026-11-08 19:22:24 +00:00
oscarlosu-lab commented 2026-11-08 13:19:14 +00:00 (Migrated from github.com)

Summary

This PR reorganizes the in-game options menu (opened with F1, Insert, or gamepad Home / Select+Start) from a single, vertically overflowing list into 3 distinct, clean categories: GRAPHICS, GAMEPLAY, and CONTROLS.

It introduces full gamepad bumper (LB / RB, LT / RT) and keyboard (Q / E, Tab / Shift+Tab) category cycling, accompanied by visual tab pills, a golden Zelda-style active tab underline, an active item selection notch, and a stable layout height that prevents window jittering.


Motivation & Problem

As the in-game configuration menu has expanded with essential settings (quality presets, frame generation, upscaling, resolution scaling, frame pacing, ultrawide, camera inversion, and controller options), the menu grew into an unbroken single column.
At standard resolutions (720p / 1080p), this single column stretched across almost the entire vertical window height, resulting in:

  1. Visual clutter and a debug-like presentation.
  2. Excessive vertical scrolling to reach audio, gameplay, or control settings.
  3. Difficulties scaling when new runtime options or features land.

Key Improvements & Architecture

  1. Three Categorized Tabs:
    • GRAPHICS: Quality preset, Fullscreen, Frame generation, Frame pacing, Resolution, Upscaling, Sharpness, Handheld profile, Ultrawide.
    • GAMEPLAY: FPS counter, Game speed, Text speed.
    • CONTROLS: Controller in background, Controls button rebinding.
  2. Dual-Input Category Switching (Pure Gamepad & Keyboard):
    • Gamepad: LB / RB (also supports LT / RT triggers).
    • Keyboard: Q / E or Tab / Shift+Tab.
    • Zero mouse interference; navigation remains 100% deterministic through D-pad and arrows.
  3. Rock-Solid Visual Layout:
    • Width: Set to 480px (at scale 1: 720 lines) for generous padding and balanced proportions across all monitor aspects.
    • Height: Anchored to a stable 11-row maximum height (kMaxTabRows), ensuring the menu dimensions and help text footer remain perfectly still without bouncing or resizing when switching between tabs of varying lengths.
    • Visual Accents: Golden active tab indicator (RGB(235, 205, 95)), clear inactive tab dimming, and an emerald green selection bar on the active option.
  4. Per-Tab Memory:
    • Switching between tabs preserves the selected row position within each category, providing smooth navigation when adjusting settings across pages.

Compatibility & Zero Regressions

  • Option Persistence: Fully compatible with existing hookshot_options.ini. Every setting is saved and read through the identical keys.
  • Subpage Integration: Seamlessly switches to the Controls binding subpage (page == 1) and returns cleanly to the CONTROLS tab on Esc / gamepad B.
  • CI / Build: Compiles cleanly with zero warnings under MSVC and Clang.

Testing & Verification

  • Tested in-game under Vulkan backend with both Xbox Controller and mechanical keyboard.
  • Verified tab switching via LB/RB, LT/RT, Q/E, and Tab.
  • Verified option modifications, preset changes, and full round-trip persistence to hookshot_options.ini.
### Summary This PR reorganizes the in-game options menu (opened with F1, Insert, or gamepad Home / Select+Start) from a single, vertically overflowing list into 3 distinct, clean categories: **GRAPHICS**, **GAMEPLAY**, and **CONTROLS**. It introduces full gamepad bumper (LB / RB, LT / RT) and keyboard (Q / E, Tab / Shift+Tab) category cycling, accompanied by visual tab pills, a golden Zelda-style active tab underline, an active item selection notch, and a stable layout height that prevents window jittering. --- ### Motivation & Problem As the in-game configuration menu has expanded with essential settings (quality presets, frame generation, upscaling, resolution scaling, frame pacing, ultrawide, camera inversion, and controller options), the menu grew into an unbroken single column. At standard resolutions (720p / 1080p), this single column stretched across almost the entire vertical window height, resulting in: 1. Visual clutter and a debug-like presentation. 2. Excessive vertical scrolling to reach audio, gameplay, or control settings. 3. Difficulties scaling when new runtime options or features land. --- ### Key Improvements & Architecture 1. **Three Categorized Tabs:** - **GRAPHICS**: Quality preset, Fullscreen, Frame generation, Frame pacing, Resolution, Upscaling, Sharpness, Handheld profile, Ultrawide. - **GAMEPLAY**: FPS counter, Game speed, Text speed. - **CONTROLS**: Controller in background, Controls button rebinding. 2. **Dual-Input Category Switching (Pure Gamepad & Keyboard):** - **Gamepad**: LB / RB (also supports LT / RT triggers). - **Keyboard**: Q / E or Tab / Shift+Tab. - Zero mouse interference; navigation remains 100% deterministic through D-pad and arrows. 3. **Rock-Solid Visual Layout:** - **Width**: Set to 480px (at scale 1: 720 lines) for generous padding and balanced proportions across all monitor aspects. - **Height**: Anchored to a stable 11-row maximum height (kMaxTabRows), ensuring the menu dimensions and help text footer remain perfectly still without bouncing or resizing when switching between tabs of varying lengths. - **Visual Accents**: Golden active tab indicator (RGB(235, 205, 95)), clear inactive tab dimming, and an emerald green selection bar on the active option. 4. **Per-Tab Memory:** - Switching between tabs preserves the selected row position within each category, providing smooth navigation when adjusting settings across pages. --- ### Compatibility & Zero Regressions - **Option Persistence**: Fully compatible with existing hookshot_options.ini. Every setting is saved and read through the identical keys. - **Subpage Integration**: Seamlessly switches to the Controls binding subpage (page == 1) and returns cleanly to the CONTROLS tab on Esc / gamepad B. - **CI / Build**: Compiles cleanly with zero warnings under MSVC and Clang. --- ### Testing & Verification - Tested in-game under Vulkan backend with both Xbox Controller and mechanical keyboard. - Verified tab switching via LB/RB, LT/RT, Q/E, and Tab. - Verified option modifications, preset changes, and full round-trip persistence to hookshot_options.ini.
Commenting is not possible because the repository is archived.
No description provided.