Questions tagged [uiaccessibility]

UIAccessibility is an informal protocol in UIKit that provides accessibility information about user interface elements. This information is used by VoiceOver and other assistive technologies to help users with disabilities interact with your application. All of the standard views and controls in UIKit implement UIAccessibility, so applications are accessible by default.

This tag is for any questions about making iOS apps more accessible to users via the UIAccessibility protocols.

By default, all objects that inherit from UIView adhere to this informal protocol. In fact, for many views with a low level of customization, iOS is clever enough to set the accessibility attributes automatically. For higher levels of customization, though, the following fields can be set manually (from the Apple docs):

  • Label. A short, localized word or phrase that succinctly describes the control or view, but does not identify the element’s type. Examples are “Add” or “Play.”
  • Traits. A combination of one or more individual traits, each of which describes a single aspect of an element’s state, behavior, or usage. For example, an element that behaves like a keyboard key and that is currently selected can be characterized by the combination of the Keyboard Key and Selected traits.
  • Hint. A brief, localized phrase that describes the results of an action on an element. Examples are “Adds a title” or “Opens the shopping list.”
  • Frame. The frame of the element in screen coordinates, which is given by the CGRect structure that specifies an element’s screen location and size.
  • Value. The current value of an element, when the value is not represented by the label. For example, the label for a slider might be “Speed,” but its current value might be “50%.”

When a VoiceOver user taps a view (or a Switch Control user scans over it), that view's properties are read out loud. These properties also help to determine how VoiceOver and Switch Control facilitate user interaction.

For more information, See the official Apple documentation here: Accessibility Programming Guide

546 questions
8
votes
3 answers

Is there some kind of UIAccessibility Alert Tone?

Is there any way to get iOS to play the tone that UIActionSheet plays when presented? It’s a sudden beep followed by the word "Alert". I've searched the documentation and haven't been able to find anything that looks appropriate.
Matthew Bischoff
  • 1,043
  • 11
  • 27
8
votes
2 answers

UIPageViewController accessibility or voiceover

I'm using UIPageViewController to swipe through pages (UIViewController array). I push the page view controller on the top navigation controller. While I start the app, I could page through all the VCs inside the page view controller. However,the…
7
votes
2 answers

How to setup accessibility containers so that gestures work properly?

I have a view controller with this layout (note that yellow and table views are siblings): I want the yellow view to act as a container, so I'm doing this in viewDidLoad: yellowView.isAccessibilityElement = true view.accessibilityElements =…
phi
  • 10,634
  • 6
  • 53
  • 88
7
votes
1 answer

What is the difference between IAccessible, IAccessible2, UIAutomation and MSAA?

I am starting work on accessibility and I am a bit confused by the different technologies I have encountered. What is the difference between IAccessible and IAccessible2? I originally thought IAccessible2 may be a newer version of IAccessible, but…
Anna
  • 93
  • 7
7
votes
0 answers

UIAccessibility notifications not being posted by UIKit

Code: override func viewDidLoad() { ... NotificationCenter.default.addObserver(self, selector: #selector(closedCaptioningStatusChanged(_:)), name: .UIAccessibilityClosedCaptioningStatusDidChange, object: nil) } @objc func…
MendyK
  • 1,643
  • 1
  • 17
  • 30
7
votes
1 answer

How to set the accessibility label of the alert message in iOS?

I have UIAlertController with a message. I want the alert message accessibility label to be different than the alert message string. How can I do that?
Tal Haham
  • 1,500
  • 12
  • 16
7
votes
2 answers

How do I support VoiceOver in UIPickerView on an iPad running an iPhone only app (non-universal)?

Generally I look at Apple's UICatalog sample code for basic VoiceOver support however it looks like there is VoiceOver support for UIPickerViews in the sample code. Do I need to provide an accessibilityLabel method somewhere to add VoiceOver…
Steve Moser
  • 7,647
  • 5
  • 55
  • 94
7
votes
0 answers

How to make a DIV get Voiceover focus when it doesn't contain any focusable HTML?

I have an email client application, and I'm changing the way we show attachments for an email. Previously we had them up at the top of the email viewer in a scrollable list; now we're moving them so that they're displayed as a list at the bottom of…
MusiGenesis
  • 74,184
  • 40
  • 190
  • 334
7
votes
1 answer

Accessibility: How to always set the focus on the navigation item's title view

I'm using a UINavigationController in my app. When using VoiceOver the backButton has the focus, when a new ViewController is pushed. I'd rather have the accessibilityLabel of the titleView been focused if the view appears, so that its…
roplacebo
  • 2,837
  • 2
  • 17
  • 19
7
votes
4 answers

Accessibility for iOS, VoiceOver read order issue

Is it possible to change the order in which the VoiceOver feature for accessibility in iPad reads out the elements, when the 'Two-finger Flick Down' gesture is done? For the attached image, which contains 3 labels and a button, the VoiceOver reads…
Breakpoint
  • 1,511
  • 1
  • 18
  • 41
6
votes
4 answers

Accessibility set focus to navigation bar title item

Overview: I would like to set the accessibility focus to the navigation bar's title item. By default the focus is set from top left, meaning the back button would be on focus. I would like the title item to be in focus. Attempts made so far: …
user1046037
  • 16,755
  • 12
  • 92
  • 138
6
votes
1 answer

How can I enable VoiceOver for webview content on tableview

Normally, VoiceOver correctly reads web contents loaded with WKWebView and it is possible to read buttons and links. However, when I added WKWebView on UITableViewCell and displayed in UITableVIew, VoiceOver could not recognize it. According to the…
mrqb335
  • 61
  • 1
  • 2
6
votes
1 answer

setting view.accessibilityElements with embedded view controllers

I am trying to add iOS accessibility support/Voice Over to my app. My main screen has three main controls, but the third control is hosted within an embedded view controller. I am setting accessibility elements in prepareForSegue and have confirmed…
Dan Loughney
  • 4,647
  • 3
  • 25
  • 40
6
votes
1 answer

VoiceOver does not consistently focus on UILabel when when view is presented

We have a login screen with a UILabel hidden initially to represent a message when the user logs out of the app. When VoiceOver is turned on in iOS and the user tries to log out from the app, the voice over should ideally read out the logout…
6
votes
1 answer

How to set accessibility only to annotations in map view?

I am trying to make my mapview accessible, but I have an isuue in doing so: If I try to make the mapView accessible,by doing this: self.mapView.isAccessibilityElement=YES; Then, the map view is not read by the voice over. If I set like this: …
ZeeroCool77
  • 191
  • 1
  • 13
1 2
3
36 37