pub enum Role {
Show 184 variants Unknown, InlineTextBox, Cell, StaticText, Image, Link, Row, ListItem, ListMarker, TreeItem, ListBoxOption, MenuItem, MenuListOption, Paragraph, GenericContainer, Presentation, CheckBox, RadioButton, TextField, Button, LabelText, Pane, RowHeader, ColumnHeader, Column, RowGroup, List, Table, TableHeaderContainer, LayoutTableCell, LayoutTableRow, LayoutTable, Switch, ToggleButton, Menu, Abbr, Alert, AlertDialog, Application, Article, Audio, Banner, Blockquote, Canvas, Caption, Caret, Client, Code, ColorWell, ComboBoxGrouping, ComboBoxMenuButton, Complementary, Comment, ContentDeletion, ContentInsertion, ContentInfo, Date, DateTime, Definition, DescriptionList, DescriptionListDetail, DescriptionListTerm, Details, Dialog, Directory, DisclosureTriangle, Document, EmbeddedObject, Emphasis, Feed, FigureCaption, Figure, Footer, FooterAsNonLandmark, Form, Grid, Group, Header, HeaderAsNonLandmark, Heading, Iframe, IframePresentational, ImeCandidate, InputTime, Keyboard, Legend, LineBreak, ListBox, Log, Main, Mark, Marquee, Math, MenuBar, MenuItemCheckBox, MenuItemRadio, MenuListPopup, Meter, Navigation, Note, PluginObject, PopupButton, Portal, Pre, ProgressIndicator, RadioGroup, Region, RootWebArea, Ruby, RubyAnnotation, ScrollBar, ScrollView, Search, SearchBox, Section, Slider, SpinButton, Splitter, Status, Strong, Suggestion, SvgRoot, Tab, TabList, TabPanel, Term, TextFieldWithComboBox, Time, Timer, TitleBar, Toolbar, Tooltip, Tree, TreeGrid, Video, WebView, Window, PdfActionableHighlight, PdfRoot, GraphicsDocument, GraphicsObject, GraphicsSymbol, DocAbstract, DocAcknowledgements, DocAfterword, DocAppendix, DocBackLink, DocBiblioEntry, DocBibliography, DocBiblioRef, DocChapter, DocColophon, DocConclusion, DocCover, DocCredit, DocCredits, DocDedication, DocEndnote, DocEndnotes, DocEpigraph, DocEpilogue, DocErrata, DocExample, DocFootnote, DocForeword, DocGlossary, DocGlossRef, DocIndex, DocIntroduction, DocNoteRef, DocNotice, DocPageBreak, DocPageFooter, DocPageHeader, DocPageList, DocPart, DocPreface, DocPrologue, DocPullquote, DocQna, DocSubtitle, DocTip, DocToc, ListGrid,
}
Expand description

The type of an accessibility node.

The majority of these roles come from the ARIA specification. Reference the latest draft for proper usage.

Like the AccessKit schema as a whole, this list is largely taken from Chromium. However, unlike Chromium’s alphabetized list, this list is ordered roughly by expected usage frequency (with the notable exception of Role::Unknown). This is more efficient in serialization formats where integers use a variable-length encoding.

Variants

Unknown

InlineTextBox

Cell

StaticText

Image

Row

ListItem

ListMarker

Contains the bullet, number, or other marker for a list item.

TreeItem

ListBoxOption

MenuItem

MenuListOption

Paragraph

GenericContainer

Presentation

Used for ARIA role=“none”/“presentation” – ignored in platform tree.

CheckBox

RadioButton

TextField

Button

LabelText

Pane

RowHeader

ColumnHeader

Column

RowGroup

List

Table

TableHeaderContainer

LayoutTableCell

LayoutTableRow

LayoutTable

Switch

ToggleButton

Menu

Abbr

Alert

AlertDialog

Application

Article

Audio

Banner

Blockquote

Canvas

Caption

Caret

Client

Code

ColorWell

ComboBoxGrouping

ComboBoxMenuButton

Complementary

Comment

ContentDeletion

ContentInsertion

ContentInfo

Date

DateTime

Definition

DescriptionList

DescriptionListDetail

DescriptionListTerm

Details

Dialog

Directory

DisclosureTriangle

Document

EmbeddedObject

Emphasis

Feed

FigureCaption

Figure

Footer

FooterAsNonLandmark

Form

Grid

Group

Header

HeaderAsNonLandmark

Heading

Iframe

IframePresentational

ImeCandidate

InputTime

Keyboard

Legend

LineBreak

ListBox

Log

Main

Mark

Marquee

Math

MenuBar

MenuItemCheckBox

MenuItemRadio

MenuListPopup

Meter

Navigation

Note

PluginObject

PopupButton

Portal

Pre

ProgressIndicator

RadioGroup

Region

RootWebArea

Ruby

RubyAnnotation

ScrollBar

ScrollView

Search

SearchBox

Section

Slider

SpinButton

Splitter

Status

Strong

Suggestion

SvgRoot

Tab

TabList

TabPanel

Term

TextFieldWithComboBox

Time

Timer

TitleBar

Toolbar

Tooltip

Tree

TreeGrid

Video

WebView

Window

PdfActionableHighlight

PdfRoot

GraphicsDocument

GraphicsObject

GraphicsSymbol

DocAbstract

DocAcknowledgements

DocAfterword

DocAppendix

DocBiblioEntry

DocBibliography

DocBiblioRef

DocChapter

DocColophon

DocConclusion

DocCover

DocCredit

DocCredits

DocDedication

DocEndnote

DocEndnotes

DocEpigraph

DocEpilogue

DocErrata

DocExample

DocFootnote

DocForeword

DocGlossary

DocGlossRef

DocIndex

DocIntroduction

DocNoteRef

DocNotice

DocPageBreak

DocPageFooter

DocPageHeader

DocPageList

DocPart

DocPreface

DocPrologue

DocPullquote

DocQna

DocSubtitle

DocTip

DocToc

ListGrid

Behaves similar to an ARIA grid but is primarily used by Chromium’s TableView and its subclasses, so they can be exposed correctly on certain platforms.

Trait Implementations

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Returns the “default value” for a type. Read more
Deserialize this value from the given Serde deserializer. Read more
Feeds this value into the given Hasher. Read more
Feeds a slice of this type into the given Hasher. Read more
The name of the generated JSON Schema. Read more
Generates a JSON Schema for this type. Read more
Whether JSON Schemas generated for this type should be re-used where possible using the $ref keyword. Read more
This method tests for self and other values to be equal, and is used by ==. Read more
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more
Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.