|
1 | 1 | # TalkBack Guidelines
|
2 | 2 |
|
3 |
| - |
4 | 3 | ### Table of Contents
|
5 | 4 |
|
6 | 5 | - [Getting Started](#getting-started)
|
|
14 | 13 | - [Custom Views](#custom-views)
|
15 | 14 | - [Auditing](#auditing)
|
16 | 15 | - [Further Reading](#further-reading)
|
17 |
| - |
18 | 16 |
|
19 | 17 | ## <a name="getting-started"></a>Getting Started
|
20 | 18 | “Making applications accessible not only ensures equal access to the roughly 1 billion people in the world with disabilities but also benefits people without disabilities by allowing them to customize their experiences.” - [Google Accessibility](https://www.google.com/accessibility/for-developers/)
|
@@ -60,22 +58,20 @@ The accessibility framework within Android has several ways in which you can pro
|
60 | 58 | </LinearLayout>
|
61 | 59 | ```
|
62 | 60 |
|
63 |
| - |
64 | 61 | #### Labels / Content Description
|
65 | 62 | To make a view ready for accessibility these are the rules that should govern the content descriptions that are set.
|
66 | 63 |
|
67 | 64 | * Do not include the type of the control. TalkBack will automatically announce the description you have set and the type.
|
68 | 65 | * Ensure that each description is unique. This ensures that TalkBack can communicate different views of the same type to the user without causing any confusion. This is especially useful in list controls such as `ListView` or `RecyclerView` where a view template is being used for each row with similar controls. In such cases, each row should have unique content descriptions.
|
69 | 66 | * Like all strings, content descriptions should be localized for maximum support in all languages.
|
70 | 67 |
|
71 |
| - |
72 | 68 | #### Activity titles
|
73 |
| -When an Activity comes to the foreground, TalkBack announces it’s title. When the activity has no title, TalkBack announces the name of the application, which might confuse the user -> **_set a title to all visible activities_**, either in `AndroidManifest` or using `Activity.setTitle()` method. |
| 69 | +When an Activity comes to the foreground, TalkBack announces it’s title. When the activity has no title, TalkBack announces the name of the application, which might confuse the user → **_set a title to all visible activities_**, either in `AndroidManifest` or using `Activity.setTitle()` method. |
74 | 70 |
|
75 | 71 | #### Images
|
76 | 72 | Set `contentDescription` attribute to all ImageViews (null is a valid value).
|
77 | 73 |
|
78 |
| -Illustrative images and images with labels should have contentDescription set to null -> “`android:contentDescription="@null`" or have `importantForAccessibility` set to “no” -> “`android:importantForAccessibility="no"`. |
| 74 | +Illustrative images and images with labels should have contentDescription set to null → “`android:contentDescription="@null`" or have `importantForAccessibility` set to “no” → “`android:importantForAccessibility="no"`. |
79 | 75 |
|
80 | 76 | <img src="images/accessibility-guidelines/image_inaccessible.png" width="300">
|
81 | 77 |
|
@@ -275,7 +271,6 @@ There might be times when a custom view, such as a chart, might not be accessibl
|
275 | 271 |
|
276 | 272 | <img style="clear: left;" src="images/accessibility-guidelines/stats_chart.gif">
|
277 | 273 |
|
278 |
| - |
279 | 274 | ### <a name="appearing-disappearing"></a>Appearing and Disappearing Elements
|
280 | 275 |
|
281 | 276 | There are several views and UI patterns that involve views that appear for a limited to show something to the user. The most common ones are `Toasts` and `Snackbars`. These components already have accessibility support built-in. However, the `SnackBar` behavior has to be extended to be more accessible.
|
@@ -329,7 +324,7 @@ You can test the app using TalkBack since it's simply an app that's built on top
|
329 | 324 |
|
330 | 325 | * Once TalkBack is enabled, you can navigate to TalkBack Settings to optimize it's behavior, so that you can get as much diagnostics from your audit. One of the best options available is the enabling of captions. This allows TalkBack to display it's output at the bottom of the screen so you can validate what you are hearing. If necessary, you can also take screenshots that encapsulate TalkBack behavior when captions are enabled.
|
331 | 326 |
|
332 |
| -* To enable captions, go to Accessibility -> TalkBack -> Settings -> Miscellaneous -> Developer settings and then enable "Display speech output" similar to the screenshot below. |
| 327 | +* To enable captions, go to Accessibility → TalkBack → Settings → Miscellaneous → Developer settings and then enable "Display speech output" similar to the screenshot below. |
333 | 328 |
|
334 | 329 | <img src="images/accessibility-guidelines/talkback_captions.png" width="300">
|
335 | 330 |
|
|
0 commit comments