-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve ability to navigate with TAB key #11893
Conversation
There was little to no visual indication that buttons where focused when TAB was pressed. I added visual queues and made so the expected inputs would be focused when pressing TAB Contribution Sponsor: Firestorm (launchfirestorm.com)
This pull request has been mentioned on Discussion Forum for PX4, Pixhawk, QGroundControl, MAVSDK, MAVLink. There might be relevant details there: |
This pull request has been mentioned on Discussion Forum for PX4, Pixhawk, QGroundControl, MAVSDK, MAVLink. There might be relevant details there: |
Hey @HTRamsey can you take a quick look here? I have gone through the changes and they seem fine to me, but another set of eyes wouldn't hurt. Thank you @gillamkid |
Maybe try using Google Chrome on a desktop? I don't see the videos on my phone, but I've tried several computers in Chrome and it works for them all. |
What happens with these sorts of changes on mobile? For example if you click a button in a dialog which then does some work? Does that now leave a focus visual on that button on Mobile which doesn't really make sense? |
Chrome shows me the videos. I built it myself on OSX but it's not working for me. For example in the instrument value edit dialog it will only move between two text fields in the range section. Strange. |
Changing everything from Reproduce:
Making sure field validation happens before you close out some part of the ui ends up being tricky. I think this might end up breaking that. I also thinks it's way better to trigger field validation when you click on any other ui control. |
A reason for the current state of affairs is that QGC kind of follows a more mobile and or Mac style of keyboard handling. You can tab between text fields but not every single thing. And there is limited support for things like Enter/Esc. It's been my experience that making a good end to end keyboard experience with UI takes a ton of work. It doesn't come for free by creating just any UI. And if you do it half-assed, well it ends up that way and doesn't add much value. I also tend to think all the focus display UI ends up cluttering everything up. Again for not enough value. If the tabFocus only thing worked then it would be great since I'd assume then the extra focus display would only start showing up if someone actually pressed tab. But without that I'm kind of negative on the whole tab focus thing cluttering up the ui if it's going to be there all the time. Do you have good reasons why full keyboard support is important? |
I wanted to fix this because TAB support already half works (focus will hop to different elements), it just isn't consistently visually indicated. Also some elements that one would expect to be in the TAB focus chain (namely buttons) could not be tabbed too Importance: sometimes I like to tab through a form, and I can't in QGC, at least not with the visual focus queues I would like I'll try to make some fixes so this can be good enough to merge. I've never built for android or macOS, but I'll experiment with that a bit and see if I can get this working on all supported devices |
Ok, but I don't want to support that to the detriment of a crufty UI for all users. Nor do I want to turn QGC into a Windows App with all the UI ridiculousness that goes along with that. I can live with keyboard support and focus indicators like Ubuntu does them. That means they normally don't show. Clicking a control with the mouse doesn't cause them show. They only show up the first time you click tab and start moving around a form. |
From poking around Qml docs. This means using |
Also the focusPolicy needs to be strongFocus which is both tab and click. This fixes the validation on click away problem. |
I hacked around with this again last night trying different things. Still no luck getting it to work on Mac. No idea why. |
Closing since I don't have immediate plans to finish this. I may take a stab at this again someday. |
Description
There was little to no visual indication to show which buttons where focused when TAB was pressed. I added visual queues and made so the expected inputs would be focused when pressing TAB
Sponsor
This contribution was sponsored by Firestorm
Demo of new TAB navigating ability (Light mode)
tab-navigation-light.mp4
Demo of new TAB navigating ability (Dark mode)
tab-navigation-dark.mp4