pub struct A11yNode {Show 14 fields
pub id: A11yNodeId,
pub role: A11yRole,
pub name: String,
pub description: String,
pub bounds_x: i32,
pub bounds_y: i32,
pub bounds_w: u32,
pub bounds_h: u32,
pub children: Vec<A11yNodeId>,
pub focusable: bool,
pub focused: bool,
pub actions: Vec<A11yAction>,
pub value: String,
pub expanded: bool,
}Expand description
A single node in the accessibility tree.
Fields§
§id: A11yNodeIdUnique identifier.
role: A11yRoleRole of this element.
name: StringHuman-readable name.
description: StringOptional longer description.
bounds_x: i32Bounding rectangle (x, y, width, height).
bounds_y: i32§bounds_w: u32§bounds_h: u32§children: Vec<A11yNodeId>Child node IDs.
focusable: boolWhether this node can receive keyboard focus.
focused: boolWhether this node currently has focus.
actions: Vec<A11yAction>Available actions.
value: StringCurrent value (for sliders, text fields, etc.).
expanded: boolWhether this node is expanded (for tree items, menus).
Implementations§
Source§impl A11yNode
impl A11yNode
Sourcepub fn new(id: A11yNodeId, role: A11yRole, name: &str) -> Self
pub fn new(id: A11yNodeId, role: A11yRole, name: &str) -> Self
Create a new node with the given role and name.
Sourcepub fn set_bounds(&mut self, x: i32, y: i32, w: u32, h: u32)
pub fn set_bounds(&mut self, x: i32, y: i32, w: u32, h: u32)
Set the bounding rectangle.
Sourcepub fn add_child(&mut self, child_id: A11yNodeId)
pub fn add_child(&mut self, child_id: A11yNodeId)
Add a child node ID.
Sourcepub fn add_action(&mut self, action: A11yAction)
pub fn add_action(&mut self, action: A11yAction)
Add an available action.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for A11yNode
impl RefUnwindSafe for A11yNode
impl Send for A11yNode
impl Sync for A11yNode
impl Unpin for A11yNode
impl UnwindSafe for A11yNode
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)