Hello all,
I am creating an app with the accessibility mode support for an iPad device. I have a requirement where user needs to switch to a particular view and the user is allowed to draw in that area as well as pass keyboard key inputs to the view. When VoiceOver is on, all the touch and keyboard inputs are being captured by Accessibility engine and these events are not received in the app. As per my requirement I need to capture the keyboard key inputs as well as touch events for the view. For receiving the touch inputs directly in the app I am using “UIAccessibilityTraitAllowsDirectInteraction” and it works fine, but the keyboard doesn’t.
My query is : is there anything available like “UIAccessibilityTraitAllowsDirectInteraction” for keyboards in accessibility/ VoiceOver mode? Or is there a way if I can disable the accessibility/ VoiceOver for a particular view in a ViewController when the accessibility mode is on for the iPad device? Any help would be appreciated!
There's nothing you can do to change the way VoiceOver processes keyboard events. I assume you're asking about a hardware keyboard here? VoiceOver shouldn't be stealing keyboard input from the app, with the exception of VO commands that are performed while holding down the VO modifier keys.
It's possible you might have quick nav on, which will process single letter inputs as VoiceOver commands. Check out this document to learn more about quick nav and how to turn it on or off: https://support.apple.com/guide/voiceover/with-quick-nav-vo27943/mac
If quick nav is off and you are still not seeing your app get keyboard input, could you elaborate on what type of keyboard input you are trying to get in your app?