pub struct WidgetAccessInfo { /* private fields */ }
Expand description
Accessibility info for a widget.
Implementations§
source§impl WidgetAccessInfo
impl WidgetAccessInfo
sourcepub fn info(&self) -> &WidgetInfo
pub fn info(&self) -> &WidgetInfo
Full widget info.
sourcepub fn role(&self) -> Option<AccessRole>
pub fn role(&self) -> Option<AccessRole>
Accessibility role of the widget.
sourcepub fn commands(&self) -> &[AccessCmdName]
pub fn commands(&self) -> &[AccessCmdName]
Accessibility commands supported by the widget.
sourcepub fn auto_complete(&self) -> Option<AutoComplete>
pub fn auto_complete(&self) -> Option<AutoComplete>
How input text triggers display of one or more predictions of the user’s intended value.
sourcepub fn checked(&self) -> Option<Option<bool>>
pub fn checked(&self) -> Option<Option<bool>>
If the widget is checked (Some(true)
), unchecked (Some(false)
), or if the checked status is indeterminate (None
).
Note that the value is wrapped in another Option<_>
that indicates if it was set or not.
sourcepub fn current(&self) -> Option<CurrentKind>
pub fn current(&self) -> Option<CurrentKind>
Kind of current item the widget represents.
sourcepub fn error_message(&self) -> Option<WidgetInfo>
pub fn error_message(&self) -> Option<WidgetInfo>
Gets the invalid widget that this widget is an error message for.
sourcepub fn active_descendant(&self) -> Option<WidgetInfo>
pub fn active_descendant(&self) -> Option<WidgetInfo>
Identifies the currently active widget when focus is on a composite widget.
sourcepub fn has_popup(&self) -> Option<Popup>
pub fn has_popup(&self) -> Option<Popup>
Indicates the availability and type of interactive popup widget.
sourcepub fn labelled_by_child(&self) -> bool
pub fn labelled_by_child(&self) -> bool
If the widget children must be used like labelled_by
.
sourcepub fn lang(&self) -> Option<LanguageIdentifier>
pub fn lang(&self) -> Option<LanguageIdentifier>
Gets the language of texts inside this widget and descendants.
If not set it is the parents language.
sourcepub fn scroll_horizontal(&self) -> Option<Box<dyn VarBoxed<Factor>>>
pub fn scroll_horizontal(&self) -> Option<Box<dyn VarBoxed<Factor>>>
Normalized (0..1) horizontal scroll, 0 is showing the content leftmost edge, 1 is showing the content the rightmost edge.
Also signals that the content is horizontally scrollable.
sourcepub fn scroll_vertical(&self) -> Option<Box<dyn VarBoxed<Factor>>>
pub fn scroll_vertical(&self) -> Option<Box<dyn VarBoxed<Factor>>>
Normalized (0..1) vertical scroll, 0 is showing the content topmost edge, 1 is showing the content the bottommost edge.
Also signals that the content is vertically scrollable.
sourcepub fn is_multi_selectable(&self) -> bool
pub fn is_multi_selectable(&self) -> bool
Indicates that the user may select more than one item from the current selectable descendants.
sourcepub fn orientation(&self) -> Option<Orientation>
pub fn orientation(&self) -> Option<Orientation>
Indicates whether the widget’s orientation is horizontal, vertical, or unknown/ambiguous.
sourcepub fn placeholder(&self) -> Option<Txt>
pub fn placeholder(&self) -> Option<Txt>
Short hint (a word or short phrase) intended to help the user with data entry when a form control has no value.
sourcepub fn is_read_only(&self) -> bool
pub fn is_read_only(&self) -> bool
Indicates that the widget is not editable, but is otherwise operable.
sourcepub fn is_required(&self) -> bool
pub fn is_required(&self) -> bool
Indicates that user input is required on the widget before a form may be submitted.
sourcepub fn level(&self) -> Option<NonZero<u32>>
pub fn level(&self) -> Option<NonZero<u32>>
Defines the hierarchical level of a widget within a structure.
sourcepub fn is_selected(&self) -> bool
pub fn is_selected(&self) -> bool
Indicates that the widget is selected.
sourcepub fn sort(&self) -> Option<SortDirection>
pub fn sort(&self) -> Option<SortDirection>
Indicates if items in a table or grid are sorted in ascending or descending order.
sourcepub fn value_text(&self) -> Option<Txt>
pub fn value_text(&self) -> Option<Txt>
Current value in a readable format.
Note that this returns Some(_)
only when a value text was set, value
may or may not be set also.
sourcepub fn live(&self) -> Option<(LiveIndicator, bool, bool)>
pub fn live(&self) -> Option<(LiveIndicator, bool, bool)>
Gets the live indicator, atomic and busy.
See AccessState::Live
for more details.
sourcepub fn col_index(&self) -> Option<usize>
pub fn col_index(&self) -> Option<usize>
Defines a widget’s column index in the parent table or grid.
sourcepub fn col_span(&self) -> Option<usize>
pub fn col_span(&self) -> Option<usize>
Defines the number of columns spanned by the widget in the parent table or grid.
sourcepub fn row_index(&self) -> Option<usize>
pub fn row_index(&self) -> Option<usize>
Defines a widget’s column index in the parent table or grid.
sourcepub fn row_span(&self) -> Option<usize>
pub fn row_span(&self) -> Option<usize>
Defines the number of columns spanned by the widget in the parent table or grid.
sourcepub fn item_count(&self) -> Option<usize>
pub fn item_count(&self) -> Option<usize>
Defines the number of items in the current set of list items or tree items when not all items in the set are present in the tree.
sourcepub fn item_index(&self) -> Option<usize>
pub fn item_index(&self) -> Option<usize>
Defines the widget’s number or position in the current set of list items or tree items when not all items are present in the tree.
sourcepub fn controls(&self) -> impl Iterator<Item = WidgetInfo>
pub fn controls(&self) -> impl Iterator<Item = WidgetInfo>
Widget(s) whose contents or presence are controlled by this widget.
sourcepub fn described_by(&self) -> impl Iterator<Item = WidgetInfo>
pub fn described_by(&self) -> impl Iterator<Item = WidgetInfo>
Identifies the widget(s) that describes this widget.
sourcepub fn describes(&self) -> Option<WidgetInfo>
pub fn describes(&self) -> Option<WidgetInfo>
Identifies the widget that is described by this widget.
Note that this is not a query for all widgets that have this one in their described_by
list, it is only
set if it was set explicitly during info build.
sourcepub fn details(&self) -> impl Iterator<Item = WidgetInfo>
pub fn details(&self) -> impl Iterator<Item = WidgetInfo>
Identifies the widget(s) that provide additional information related to this widget.
sourcepub fn labelled_by(&self) -> impl Iterator<Item = WidgetInfo>
pub fn labelled_by(&self) -> impl Iterator<Item = WidgetInfo>
Identifies the widget(s) that labels the widget it is applied to.
sourcepub fn labels(&self) -> Option<WidgetInfo>
pub fn labels(&self) -> Option<WidgetInfo>
Identifies the widget that is labelled by this widget.
Note that this is not a query for all widgets that have this one in their labelled_by
list, it is only
set if it was set explicitly during info build.
sourcepub fn owns(&self) -> impl Iterator<Item = WidgetInfo>
pub fn owns(&self) -> impl Iterator<Item = WidgetInfo>
Extra widgets that are child to this widget, but are not descendants on the info tree.
sourcepub fn flows_to(&self) -> impl Iterator<Item = WidgetInfo>
pub fn flows_to(&self) -> impl Iterator<Item = WidgetInfo>
Options for next widget to read.
sourcepub fn is_accessible(&self) -> bool
pub fn is_accessible(&self) -> bool
If the widget and descendants is visible in the view-process and screen readers.
Note that the accessibility info for the widget and descendants is still available in the app-process.
Auto Trait Implementations§
impl Freeze for WidgetAccessInfo
impl !RefUnwindSafe for WidgetAccessInfo
impl Send for WidgetAccessInfo
impl Sync for WidgetAccessInfo
impl Unpin for WidgetAccessInfo
impl !UnwindSafe for WidgetAccessInfo
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
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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