pub struct NodeSpec { /* private fields */ }Implementations§
Source§impl NodeSpec
impl NodeSpec
pub fn new(id: impl Into<SharedString>, role: Role) -> Self
pub fn checked(self, checked: bool) -> Self
pub fn tristate(self, checked: Option<bool>) -> Self
pub fn expanded(self, expanded: bool) -> Self
Sourcepub fn value(self, value: impl Into<SharedString>) -> Self
pub fn value(self, value: impl Into<SharedString>) -> Self
Records the committed value of an editable control.
Values pass through redact_sensitive_text before publication so a
snapshot never carries a credential typed by a user.
pub fn placeholder(self, placeholder: impl Into<SharedString>) -> Self
pub fn range(self, min: f32, max: f32, now: f32) -> Self
pub fn orientation(self, orientation: Orientation) -> Self
pub fn level(self, level: u32) -> Self
pub fn busy(self, busy: bool) -> Self
pub fn invalid(self, invalid: bool) -> Self
pub fn required(self, required: bool) -> Self
pub fn live(self, live: LiveRegion) -> Self
pub fn live_atomic(self, atomic: bool) -> Self
pub fn modal(self, modal: bool) -> Self
pub fn parent(self, parent: impl Into<SharedString>) -> Self
pub fn text(self, text: impl Into<SharedString>) -> Self
Sourcepub fn description(self, description: impl Into<SharedString>) -> Self
pub fn description(self, description: impl Into<SharedString>) -> Self
Publishes supplementary literal help on the same native node.
This maps to AccessKit’s description property. It does not claim a cross-tree described-by relationship.
Sourcepub fn labels(self, control: impl Into<SharedString>) -> Self
pub fn labels(self, control: impl Into<SharedString>) -> Self
Names the control this node labels.
A label is rarely an ancestor of the field it names, so the association is published rather than inferred from the tree.
Sourcepub fn describes(self, control: impl Into<SharedString>) -> Self
pub fn describes(self, control: impl Into<SharedString>) -> Self
Records which semantic node this node describes without claiming a native relationship or changing actual tree topology.
pub fn focus(self, focus: &FocusHandle) -> Self
pub fn disabled(self, disabled: bool) -> Self
pub fn read_only(self, read_only: bool) -> Self
pub fn selected(self, selected: bool) -> Self
pub fn hovered(self, hovered: bool) -> Self
pub fn pressed(self, pressed: bool) -> Self
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for NodeSpec
impl !UnwindSafe for NodeSpec
impl Freeze for NodeSpec
impl Send for NodeSpec
impl Sync for NodeSpec
impl Unpin for NodeSpec
impl UnsafeUnpin for NodeSpec
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more