pub struct ScreenReader {
pub enabled: bool,
/* private fields */
}Expand description
Screen reader that generates text announcements from the a11y tree.
Fields§
§enabled: boolWhether the screen reader is enabled.
Implementations§
Source§impl ScreenReader
impl ScreenReader
Sourcepub fn read_focused(&mut self, tree: &A11yTree)
pub fn read_focused(&mut self, tree: &A11yTree)
Read the focused element and announce its name and role.
Sourcepub fn read_all_children(&mut self, tree: &A11yTree, parent_id: A11yNodeId)
pub fn read_all_children(&mut self, tree: &A11yTree, parent_id: A11yNodeId)
Read all children of a node.
Sourcepub fn drain_announcements(&mut self) -> Vec<String>
pub fn drain_announcements(&mut self) -> Vec<String>
Drain all pending announcements.
Sourcepub fn pending_count(&self) -> usize
pub fn pending_count(&self) -> usize
Number of pending announcements.