19. Accessibility
In this chapter you will make CriminalIntent more accessible. An accessible app is usable by anyone,
regardless of any impairments in vision, mobility, or hearing. These impairments may be permanent,
but they could also be temporary or situational: Dilated eyes after an eye exam can make focusing
difficult. Greasy hands while cooking may mean you do not want to touch the screen. And if you are at
a loud concert, the music drowns out any sounds made by your device. The more accessible an app is,
the more pleasant it is to use for everyone.
Making an app fully accessible is a tall order. But that is no excuse not to try. In this chapter, you will
take some steps to make CriminalIntent more usable for people with a visual impairment. This is a
good place to begin learning about accessibility issues and accessible app design.
The changes you make in this chapter will not alter the appearance of the app. Instead, the changes will
make your app easier to explore with TalkBack.
TalkBack
TalkBack is an Android screen reader made by Google. It speaks out the contents of a screen based on
what the user is doing.
TalkBack works because it is an accessibility service, which is a special component that can read
information from the screen (no matter which app you are using). Anyone can write their own
accessibility service, but TalkBack is the most popular.
To use TalkBack, you need an Android device. (Unfortunately, the emulator does not have TalkBack.)
Make sure the device’s sound output is not muted – but you may want to grab headphones, because
once TalkBack is enabled the device will do a lot of “talking.”