#[non_exhaustive]pub enum AccessCmd {
Click(bool),
Focus(bool),
FocusNavOrigin,
SetExpanded(bool),
Increment(i32),
SetToolTipVis(bool),
Scroll(ScrollCmd),
ReplaceSelectedText(Txt),
SelectText {
start: (AccessNodeId, usize),
caret: (AccessNodeId, usize),
},
SetString(Txt),
SetNumber(f64),
}Expand description
Accessibility command.
The command must run in the context of the target widow and widget, see Event::AccessCommand for more details.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Click(bool)
Run the click action on the widget.
If true run the primary (default) action, if false run the context action.
Focus(bool)
Focus or escape focus on the widget.
If true the widget is focused, if false and the widget is already focused does ESC.
Sets the focus navigation origin to the widget.
The navigation origin is the widget that logical and directional focus requests moves from. If not set the focus moves from the current focus, if set it moves from this origin. The origin widget does not need to be focusable and it is not focused by this command.
SetExpanded(bool)
Expand or collapse the widget content.
Increment(i32)
Increment by steps.
Associated value is usually is -1 or 1.
SetToolTipVis(bool)
Show or hide the widget’s tooltip.
Scroll(ScrollCmd)
Scroll command.
ReplaceSelectedText(Txt)
Insert the text.
SelectText
Set the text selection.
The two points are defined by the widget and string byte char index. The start can be before or after (textually). The byte index must be at the start of a grapheme and UTF-8 char.
Fields
start: (AccessNodeId, usize)Selection start.
caret: (AccessNodeId, usize)Selection end, where the caret is positioned.
SetString(Txt)
Replace the value of the control with the specified value and reset the selection, if applicable.
SetNumber(f64)
Replace the value of the control with the specified value and reset the selection, if applicable.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for AccessCmd
impl<'de> Deserialize<'de> for AccessCmd
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl IntoValue<Option<AccessCmd>> for AccessCmd
impl StructuralPartialEq for AccessCmd
Auto Trait Implementations§
impl Freeze for AccessCmd
impl RefUnwindSafe for AccessCmd
impl Send for AccessCmd
impl Sync for AccessCmd
impl Unpin for AccessCmd
impl UnwindSafe for AccessCmd
Blanket Implementations§
Source§impl<T> AnyVarValue for T
impl<T> AnyVarValue for T
Source§fn clone_boxed(&self) -> BoxAnyVarValue
fn clone_boxed(&self) -> BoxAnyVarValue
Source§fn eq_any(&self, other: &(dyn AnyVarValue + 'static)) -> bool
fn eq_any(&self, other: &(dyn AnyVarValue + 'static)) -> bool
self and other are equal.Source§fn try_swap(&mut self, other: &mut (dyn AnyVarValue + 'static)) -> bool
fn try_swap(&mut self, other: &mut (dyn AnyVarValue + 'static)) -> bool
other if both are of the same type.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
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>
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