Description
The auto-cursor navigation can make unexpected jumps when dealing with a scrollable panel.Reproduction steps
- Open "Control settings" panel, with auto-cursor enabled.
- Focus cursor on "Move" label (it becomes yellow and shows tooltip)
- Hold left-stick downwards, to hop from label to label (the ones with hints at least)
Expected result
- Label "Move"
- Label "Alternative GUI move up"
- Label "Alternative GUI move down"
- Label "Alternative GUI move left"
- Label "Alternative GUI move right"
- Section header "Basic interaction"
- Label "Super-forced build" (the first focusable binding row within basic interaction)
Actual result
- Label "Move"
- Label "Alternative GUI move up"
- Label "Alternative GUI move down"
- Label "Alternative GUI move left"
- Label "Alternative GUI move right"
- Section header "Basic interaction"
- Button "Back", outside of scrollable panel
Solutions
It seems to me that the UI is navigated by reference of screen-space coordinates, when a focussable element exists in a scrollable container it can be out of sight, below the bottom of the container and sit in screen space further below a button that is outside the container, just below its bottom border.When searching for focus candidates, the search should bubble up from the focussed element's parent while keeping track of the logical boundary offset that the parent has. So, just taking the bottom border into account, as you inspect the scrollable container's parent you add onto any downwards element the invisible section of the panel that is outside the viewport. Because in order to reach a button outside the scrollable panel you first should go through all elements in that panels local space.
This you then do for each direction (up, down, left, right). The top border would be impacted by a scrollable panel when the user has scrolled down a bit.
The downside with this is that the scrollable panel must be fully traversed before the user can escape out, which can be problematic in a long panel like in the settings menu.
Alternatively, perhaps a modifier (e.g. shoulders) could be used to use the stick not to navigate focus but to scroll the first scrollable parent relative to the current element.