Open jpetrell opened 2 weeks ago
Arrow navigation e.g. between main views and vertically on the settings pages seems pretty straight-forward (i.e. the keyboard focus is moved to the adjacent item that is located in the arrow direction), and for the common UI components (dialogs, sliders, spin boxes, etc.) I can initially use gui-v1 behavior as an example.
Some open items to decide:
Key navigation prototype: Screencast from 2024-05-03 13-28-08.webm
Branch: https://github.com/victronenergy/gui-v2/pull/new/jpetrell/key-navigation
Doesn't require many lines of code to get the main navigation paths covered, thanks to nice key navigation enablers in Qt Quick. But adding support for all the settings pages and dozens of different list items and controls (dialogs, sliders, etc.) will take few days. One enabler that is missing is ObjectModel variant that removes hidden items from the model like done by VisibleItemModel for gui-v1, which is needed so ListView navigation doesn't try to move focus to the hidden (disabled/disallowed) settings items.
Current key navigation on gui-v1:
Up/Down
keys, Space
opens a page, Left
goes back, Esc
jumps to Overview pageSpace
toggles on/offUp/Down
keys, confirm with Space
, dismiss with Esc
Space
opens the edit mode, during editing Esc
cancels, Space
commits, Up/Down
and Left/Right
changes the slider valueUp/Down
moves the lower, and Left/Right
the higher valueSpace
opens the edit mode with the first value focused, Esc
cancels, Space
commits, Left/Right
moves the focus, Up/Down
increments/decrements valuesSpace
opens the edit mode with the first character focused, Esc
cancels, Space
commits, Left/Right
moves the focus, typing replaces the focused charactergui-v1 shows slightly different controls when you access the spin box or text field setting using touch or with keyboard:
Should we show the keyboard layout somewhere like shown above in the Remote Console case?
In gui-v1, there is keyboard navigation when using it on Remote console. And that is used everyday by many technicians that sit behind their laptop and sort issues out or configure systems. Enable keyboard navigation on gui-v2 also.