注: 该系列文章翻译自iOS Developer Library –> Cocoa Core Competencies
Cocoa Core Competencies, 顾名思义 Cocoa核心概念。只是各个部分概念介绍, 更加详尽的学习, 参见各个章节提供的相关链接。
译者水平有限, 难免存在各种问题, 欢迎指正交流。
欢迎转载, 转载请注明出处: Colin
Accessible apps can be used by everyone, regardless of their limitations or disabilities. By making your app accessible, you can reach broader markets and expand your user base.
易于理解/使用的App可以让任何人使用, 不拘于他们的限制(短处)或者伤残。使你的App易于使用, 你可以获取更广阔的市场以及扩大你的用户群。
Your users do not necessarily have the same abilities as you. Consider your app’s user experience from the perspective of someone with a seeing, hearing, interacting, or learning impairment. Is your app still operable if someone with one of these impairments tries to use it?
你的用户不一定和你有相同的能力。 从一个人的视力障碍,听力障碍,交流障碍, 学习障碍等角度来考虑你的App的用户体验。如果某个有以上障的人试图使用你的App, 那么它是否仍然是可运行/操作的?
Apple has done the majority of the work on the system level to make your app accessible—by providing features like screen zoom, visual alerts, AssistiveTouch, and Guided Access—but there is more you can do as a developer to enhance the accessibility of your app.
Apple已经在系统层面做了大量工作, 通过提供screen zoom(屏幕缩放), visual alerts(视觉警告 iPhone lets you know when something’s up, in a way you’ll notice. It delivers both visual and vibrating alerts...在某个事件发生的时候,Apple为了让你注意/知道, 提供了视觉和振动警报), AssistiveTouch (AssistiveTouch是设计为肢体缺失等特殊人群方便使用iPhone各种功能的功能), and Guided Access(引导访问)等功能来使你的App易于使用。
The primary way OS X and iOS apps present information is through a graphical user interface (GUI), so you need to pay particular attention to visual accessibility. Blind and low-vision users interact with your app using VoiceOver, a screen-reading technology built into the operating system that speaks your app’s user interface aloud. VoiceOver users use special gestures or keyboard commands to explore and control the GUI. Standard inputs—such as mouse movements and finger swipes—are translated by VoiceOver to move the VoiceOver cursor, which reads an element’s accessibility information.
OS X和iOS应用程序呈现信息的主要方式是通过一个图形用户界面( GUI ),所以你需要特别注意视觉可访问性/易于操作。 盲和低视力的用户与应用程序交互使用VoiceOver,屏幕阅读技术构建到操作系统,使得大声地朗读你的应用程序的用户界面。 VoiceOver用户使用特殊的手势或键盘命令来探索和控制GUI。 标准的输入如鼠标移动和手指点击由VoiceOver转换来移动VoiceOver光标,(光标)它读取一个元素的可理解信息。
VoiceOver helps low-vision users navigate the GUI by interpreting touches differently
VoiceOver通过对触碰不同的解释来帮助低视力用户导航GUI
The standard UI elements provided by AppKit and UIKit are accessible to VoiceOver by default. You only need to provide a description for visual UI elements such as images or icons that don’t already have text associated with them. You can change an element’s accessibility description and other default accessibility behavior—such as the role of an element, or whether VoiceOver should read the element—directly in Interface Builder.
AppKit和UIKit提供的标准UI元素是VoiceOver默认可理解的。你只需要为视觉UI元素,如图像或者没有文本的图标提供一个描述。你可以改变一个元素的易理解描述和其他默认的易理解行为-比如一个元素的作用,或VoiceOver是否应该读直接在界面构建器(Interface Builder)上的元素。
Custom UI elements and views, on the other hand, must conform to the NSAccessibility or UIAccessibility protocol so that they can describe themselves to VoiceOver to be read aloud. These are the same protocols that standard controls in AppKit and UIKit adopt. By adopting these protocols and implementing their methods, you provide VoiceOver the information it needs to make your custom UI elements accessible.
自定义UI元素和视图,从另一个方面来讲,必须符合 NSAccessibility 或 UIAccessibility 协议,这样他们可以把自己描述给VoiceOver以便大声朗读。 这些都是相同的协议,它是AppKit和UIKit中采用的标准控制。 采用这些协议和实现他们的方法,你提供VoiceOver它所需要的信息去定制UI元素。
The best way to confirm that your app works well with VoiceOver is to interact with your app using VoiceOver. Enable VoiceOver on iOS in Settings > General > Accessibility and on OS X in System Preferences > Accessibility (or hit Command-F5). VoiceOver is a sophisticated tool, but it only takes a few minutes to learn the basics. Navigate through your user interface using VoiceOver to make sure all your features are accessible and all of your UI elements have appropriate descriptions. Verify that your app promotes a positive accessibility experience by following the advice in Testing the Accessibility of Your iPhone Application.
最好的方法来确认你的App与VoiceOver工作良好是使用VoiceOver来与你的App进行交互。 iOS上启用VoiceOver 在设置> 通用> 辅助功能> VoiceOver。 VoiceOver是一个复杂的工具,但它只需要几分钟的时间来学习基础知识。 使用VoiceOver浏览你的用户界面来确保你所有的功能都可以访问和你所有的UI元素有适当的描述。 验证你的App促进了积极性的经验,通过遵循Testing the Accessibility of Your iPhone Application中的建议。
Related Articles
Internationalization
Definitive Discussion
Accessibility Programming Guide for iOS
Sample Code Projects
ImageMapExample