Enum atspi_common::state::State
source · #[non_exhaustive]#[repr(u64)]pub enum State {
Show 44 variants
Invalid = 1,
Active = 2,
Armed = 4,
Busy = 8,
Checked = 16,
Collapsed = 32,
Defunct = 64,
Editable = 128,
Enabled = 256,
Expandable = 512,
Expanded = 1_024,
Focusable = 2_048,
Focused = 4_096,
HasTooltip = 8_192,
Horizontal = 16_384,
Iconified = 32_768,
Modal = 65_536,
MultiLine = 131_072,
Multiselectable = 262_144,
Opaque = 524_288,
Pressed = 1_048_576,
Resizable = 2_097_152,
Selectable = 4_194_304,
Selected = 8_388_608,
Sensitive = 16_777_216,
Showing = 33_554_432,
SingleLine = 67_108_864,
Stale = 134_217_728,
Transient = 268_435_456,
Vertical = 536_870_912,
Visible = 1_073_741_824,
ManagesDescendants = 2_147_483_648,
Indeterminate = 4_294_967_296,
Required = 8_589_934_592,
Truncated = 17_179_869_184,
Animated = 34_359_738_368,
InvalidEntry = 68_719_476_736,
SupportsAutocompletion = 137_438_953_472,
SelectableText = 274_877_906_944,
IsDefault = 549_755_813_888,
Visited = 1_099_511_627_776,
Checkable = 2_199_023_255_552,
HasPopup = 4_398_046_511_104,
ReadOnly = 8_796_093_022_208,
}
Expand description
Used by various interfaces indicating every possible state of an accessibility object.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Invalid = 1
Indicates an invalid state - probably an error condition.
Active = 2
Indicates a window is currently the active window, or an object is the active subelement within a container or table.
Active
should not be used for objects which have
State::Focusable
or State::Selectable
: Those objects should use
State::Focused
and State::Selected
respectively.
Active
is a means to indicate that an object which is not
focusable and not selectable is the currently-active item within its
parent container.
Armed = 4
Indicates that the object is armed.
Busy = 8
Indicates the current object is busy, i.e. onscreen representation is in the process of changing, or the object is temporarily unavailable for interaction due to activity already in progress.
Checked = 16
Indicates this object is currently checked.
Collapsed = 32
Indicates this object is collapsed.
Defunct = 64
Indicates that this object no longer has a valid backing widget (for instance, if its peer object has been destroyed).
Editable = 128
Indicates the user can change the contents of this object.
Enabled = 256
Indicates that this object is enabled, i.e. that it
currently reflects some application state. Objects that are “greyed out”
may lack this state, and may lack the State::Sensitive
if direct
user interaction cannot cause them to acquire Enabled
.
See State::Sensitive
.
Expandable = 512
Indicates this object allows progressive disclosure of its children.
Expanded = 1_024
Indicates this object is expanded.
Focusable = 2_048
Indicates this object can accept keyboard focus, which means all events resulting from typing on the keyboard will normally be passed to it when it has focus.
Focused = 4_096
Indicates this object currently has the keyboard focus.
HasTooltip = 8_192
Indicates that the object has an associated tooltip.
Horizontal = 16_384
Indicates the orientation of this object is horizontal.
Iconified = 32_768
Indicates this object is minimized and is represented only by an icon.
Modal = 65_536
Indicates something must be done with this object before the user can interact with an object in a different window.
MultiLine = 131_072
Indicates this (text) object can contain multiple lines of text.
Multiselectable = 262_144
Indicates this object allows more than one of its children to be selected at the same time, or in the case of text objects, that the object supports non-contiguous text selections.
Opaque = 524_288
Indicates this object paints every pixel within its rectangular region. It also indicates an alpha value of unity, if it supports alpha blending.
Pressed = 1_048_576
Indicates this object is currently pressed.
Resizable = 2_097_152
Indicates the size of this object’s size is not fixed.
Selectable = 4_194_304
Indicates this object is the child of an object that allows its children to be selected and that this child is one of those children that can be selected.
Selected = 8_388_608
Indicates this object is the child of an object that allows its children to be selected and that this child is one of those children that has been selected.
Sensitive = 16_777_216
Indicates this object is sensitive, e.g. to user
interaction. Sensitive
usually accompanies.
State::Enabled
for user-actionable controls, but may be found in the
absence of State::Enabled
if the current visible state of the control
is “disconnected” from the application state. In such cases, direct user
interaction can often result in the object gaining Sensitive
,
for instance if a user makes an explicit selection using an object whose
current state is ambiguous or undefined.
Showing = 33_554_432
Indicates this object, the object’s parent, the object’s parent’s parent, and so on, are all ‘shown’ to the end-user, i.e. subject to “exposure” if blocking or obscuring objects do not interpose between this object and the top of the window stack.
SingleLine = 67_108_864
Indicates this (text) object can contain only a single line of text.
Stale = 134_217_728
Indicates that the information returned for this object
may no longer be synchronized with the application state. This can occur
if the object has State::Transient
, and can also occur towards the
end of the object peer’s lifecycle.
Transient = 268_435_456
Indicates this object is transient.
Vertical = 536_870_912
Indicates the orientation of this object is vertical; for example this state may appear on such objects as scrollbars, text objects (with vertical text flow), separators, etc.
Visible = 1_073_741_824
Indicates this object is visible, e.g. has been
explicitly marked for exposure to the user. Visible
is no
guarantee that the object is actually unobscured on the screen, only that
it is ‘potentially’ visible, barring obstruction, being scrolled or clipped
out of the field of view, or having an ancestor container that has not yet
made visible. A widget is potentially onscreen if it has both
Visible
and State::Showing
. The absence of
Visible
and State::Showing
is
semantically equivalent to saying that an object is ‘hidden’.
ManagesDescendants = 2_147_483_648
Indicates that “active-descendant-changed”
event is sent when children become ‘active’ (i.e. are selected or
navigated to onscreen). Used to prevent need to enumerate all children
in very large containers, like tables. The presence of
ManagesDescendants
is an indication to the client that the
children should not, and need not, be enumerated by the client.
Objects implementing this state are expected to provide relevant state
notifications to listening clients, for instance notifications of
visibility changes and activation of their contained child objects, without
the client having previously requested references to those children.
Indeterminate = 4_294_967_296
Indicates that a check box or other boolean indicator is in a state other than checked or not checked.
This usually means that the boolean value reflected or controlled by the
object does not apply consistently to the entire current context.
For example, a checkbox for the “Bold” attribute of text may have
Indeterminate
if the currently selected text contains a mixture
of weight attributes. In many cases interacting with a
Indeterminate
object will cause the context’s corresponding
boolean attribute to be homogenized, whereupon the object will lose
Indeterminate
and a corresponding state-changed event will be
fired.
Required = 8_589_934_592
Indicates that user interaction with this object is ‘required’ from the user, for instance before completing the processing of a form.
Truncated = 17_179_869_184
Indicates that an object’s onscreen content is truncated, e.g. a text value in a spreadsheet cell.
Animated = 34_359_738_368
Indicates this object’s visual representation is
dynamic, not static. This state may be applied to an object during an
animated ‘effect’ and be removed from the object once its visual
representation becomes static. Some applications, notably content viewers,
may not be able to detect all kinds of animated content. Therefore the
absence of this state should not be taken as
definitive evidence that the object’s visual representation is
static; this state is advisory.
InvalidEntry = 68_719_476_736
This object has indicated an error condition due to failure of input validation. For instance, a form control may acquire this state in response to invalid or malformed user input.
SupportsAutocompletion = 137_438_953_472
This state indicates that the object
in question implements some form of typeahead or
pre-selection behavior whereby entering the first character of one or more
sub-elements causes those elements to scroll into view or become
selected. Subsequent character input may narrow the selection further as
long as one or more sub-elements match the string. This state is normally
only useful and encountered on objects that implement crate::interface::Interface::Selection
.
In some cases the typeahead behavior may result in full or partial
completion of the data in the input field, in which case
these input events may trigger text-changed events from the source.
SelectableText = 274_877_906_944
Indicates that the object in
question supports text selection. It should only be exposed on objects
which implement the crate::interface::Interface::Text
interface, in order to distinguish this state
from State::Selectable
, which infers that the object in question is a
selectable child of an object which implements crate::interface::Interface::Selection
. While
similar, text selection and subelement selection are distinct operations.
IsDefault = 549_755_813_888
Indicates that the object in question is the ‘default’ interaction object in a dialog, i.e. the one that gets activated if the user presses “Enter” when the dialog is initially posted.
Visited = 1_099_511_627_776
Indicates that the object (typically a hyperlink) has already been activated or invoked, with the result that some backing data has been downloaded or rendered.
Checkable = 2_199_023_255_552
Indicates this object has the potential to be checked, such as a checkbox or toggle-able table cell.
HasPopup = 4_398_046_511_104
Indicates that the object has a popup context menu or sub-level menu which may or may not be showing. This means that activation renders conditional content. Note that ordinary tooltips are not considered popups in this context.
ReadOnly = 8_796_093_022_208
Indicates that an object which is State::Enabled
and
State::Sensitive
has a value which can be read, but not modified, by the
user.
Trait Implementations§
source§impl BitFlag for State
impl BitFlag for State
source§fn empty() -> BitFlags<Self>
fn empty() -> BitFlags<Self>
BitFlags
with no flags set (in other words, with a value of 0). Read moresource§fn from_bits(bits: Self::Numeric) -> Result<BitFlags<Self>, FromBitsError<Self>>
fn from_bits(bits: Self::Numeric) -> Result<BitFlags<Self>, FromBitsError<Self>>
BitFlags
if the raw value provided does not contain
any illegal flags. Read moresource§fn from_bits_truncate(bits: Self::Numeric) -> BitFlags<Self>
fn from_bits_truncate(bits: Self::Numeric) -> BitFlags<Self>
BitFlags
from an underlying bitwise value. If any
invalid bits are set, ignore them. Read moresource§unsafe fn from_bits_unchecked(bits: Self::Numeric) -> BitFlags<Self>
unsafe fn from_bits_unchecked(bits: Self::Numeric) -> BitFlags<Self>
BitFlags
unsafely, without checking if the bits form
a valid bit pattern for the type. Read more