Accessibility label - Flutter
In Flutter, the semanticsLabel
property is used as accessibility name.
You can also use the attributedLabel
property for greater control over pronunciation. For example, spell out each character with SpellOutStringAttribute
or set a language using LocaleStringAttribute
.
For even more control, you can use the Semantics
widget. For example, if you want to ignore the semantics of underlaying widgets, you can set the excludeSemantics
attribute to true
.
Control(
semanticsLabel: 'Appt'
)
Semantics(
label: 'Appt',
attributedLabel: AttributedString('Appt', attributes: [
SpellOutStringAttribute(range: const TextRange(start: 0, end: 3))
]),
excludeSemantics: true;
);