text stringlengths 1 372 |
|---|
gestures on mobile and keyboard shortcuts on desktop. |
turn on VoiceOver or TalkBack on your mobile device and |
navigate around your app. |
to turn on the screen reader on your device, complete the following steps: |
to learn how to find and customize android’s |
accessibility features, view the following video. |
to learn how to find and customize iOS |
accessibility features, view the following video. |
for web, the following screen readers are currently supported: |
mobile browsers: |
desktop browsers: |
screen readers users on web must toggle the |
“enable accessibility” button to build the semantics tree. |
users can skip this step if you programmatically auto-enable |
accessibility for your app using this API: |
windows comes with a screen reader called narrator |
but some developers recommend using the more popular |
NVDA screen reader. to learn about using NVDA to test |
windows apps, check out |
screen readers 101 for Front-End developers (windows). |
on a mac, you can use the desktop version of VoiceOver, |
which is included in macOS. |
on linux, a popular screen reader is called orca. |
it comes pre-installed with some distributions |
and is available on package repositories such as apt. |
to learn about using orca, check out |
getting started with orca screen reader on gnome desktop. |
check out the following video demo to see victor tsaran, |
using VoiceOver with the now-archived flutter gallery web app. |
flutter’s standard widgets generate an accessibility tree automatically. |
however, if your app needs something different, |
it can be customized using the semantics widget. |
when there is text in your app that should be voiced |
with a specific voice, inform the screen reader |
which voice to use by calling TextSpan.locale. |
note that MaterialApp.locale and localizations.override |
don’t affect which voice the screen reader uses. |
usually, the screen reader uses the system voice |
except where you explicitly set it with TextSpan.locale. |
<topic_end> |
<topic_start> |
sufficient contrast |
sufficient color contrast makes text and images easier to read. |
along with benefitting users with various visual impairments, |
sufficient color contrast helps all users when viewing an interface |
on devices in extreme lighting conditions, |
such as when exposed to direct sunlight or on a display with low |
brightness. |
the W3C recommends: |
<topic_end> |
<topic_start> |
building with accessibility in mind |
ensuring your app can be used by everyone means building accessibility |
into it from the start. for some apps, that’s easier said than done. |
in the video below, two of our engineers take a mobile app from a dire |
accessibility state to one that takes advantage of flutter’s built-in |
widgets to offer a dramatically more accessible experience. |
<topic_end> |
<topic_start> |
testing accessibility on mobile |
test your app using flutter’s accessibility guideline API. |
this API checks if your app’s UI meets flutter’s accessibility recommendations. |
these cover recommendations for text contrast, target size, and target labels. |
the following example shows how to use the guideline API on name generator. |
you created this app as part of the |
write your first flutter app codelab. |
each button on the app’s main screen serves as a tappable target |
with text represented in 18 point. |
<code_start> |
final SemanticsHandle handle = tester.ensureSemantics(); |
await tester.pumpWidget(MyApp()); |
// checks that tappable nodes have a minimum size of 48 by 48 pixels |
// for android. |
await expectLater(tester, meetsGuideline(androidTapTargetGuideline)); |
// checks that tappable nodes have a minimum size of 44 by 44 pixels |
// for iOS. |
await expectLater(tester, meetsGuideline(iOSTapTargetGuideline)); |
// checks that touch targets with a tap or long press action are labeled. |
await expectLater(tester, meetsGuideline(labeledTapTargetGuideline)); |
// checks whether semantic nodes meet the minimum text contrast levels. |
// the recommended text contrast is 3:1 for larger text |
// (18 point and above regular). |
await expectLater(tester, meetsGuideline(textContrastGuideline)); |
handle.dispose(); |
<code_end> |
you can add guideline API tests |
in test/widget_test.dart of your app directory, or as a separate test |
file (such as test/a11y_test.dart in the case of the name generator). |
<topic_end> |
<topic_start> |
testing accessibility on web |
you can debug accessibility by visualizing the semantic nodes created for your web app |
using the following command line flag in profile and release modes: |
with the flag activated, the semantic nodes appear on top of the widgets; |
you can verify that the semantic elements are placed where they should be. |
if the semantic nodes are incorrectly placed, please file a bug report. |
<topic_end> |
<topic_start> |
accessibility release checklist |
here is a non-exhaustive list of things to consider as you prepare your |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.