Skip to main content

WidgetType

Type Alias WidgetType 

Source
pub type WidgetType = Role;
๐Ÿ‘ŽDeprecated:

Renamed to egui::Role (a re-export of accesskit::Role). Note that some variants were renamed too, e.g. WidgetType::TextEdit is now Role::TextInput.

Available on crate feature egui only.
Expand description

The old name for the type of a widget, now expressed as an accesskit::Role.

Most variants kept their name, so e.g. WidgetType::Button still resolves, but some were renamed to their accessibility counterparts:

Old WidgetTypeNew Role
TextEditRole::TextInput
DragValueRole::SpinButton
ColorButtonRole::ColorWell
CollapsingHeaderRole::DisclosureTriangle
SelectableLabelRole::Button
PanelRole::Pane
ResizeHandleRole::Splitter
OtherRole::Unknown

Aliased Typeยง

#[repr(u8)]
pub enum WidgetType {
Show 182 variants Unknown = 0, TextRun = 1, Cell = 2, Label = 3, Image = 4, Link = 5, Row = 6, ListItem = 7, ListMarker = 8, TreeItem = 9, ListBoxOption = 10, MenuItem = 11, MenuListOption = 12, Paragraph = 13, GenericContainer = 14, CheckBox = 15, RadioButton = 16, TextInput = 17, Button = 18, DefaultButton = 19, Pane = 20, RowHeader = 21, ColumnHeader = 22, RowGroup = 23, List = 24, Table = 25, LayoutTableCell = 26, LayoutTableRow = 27, LayoutTable = 28, Switch = 29, Menu = 30, MultilineTextInput = 31, SearchInput = 32, DateInput = 33, DateTimeInput = 34, WeekInput = 35, MonthInput = 36, TimeInput = 37, EmailInput = 38, NumberInput = 39, PasswordInput = 40, PhoneNumberInput = 41, UrlInput = 42, Abbr = 43, Alert = 44, AlertDialog = 45, Application = 46, Article = 47, Audio = 48, Banner = 49, Blockquote = 50, Canvas = 51, Caption = 52, Caret = 53, Code = 54, ColorWell = 55, ComboBox = 56, EditableComboBox = 57, Complementary = 58, Comment = 59, ContentDeletion = 60, ContentInsertion = 61, ContentInfo = 62, Definition = 63, DescriptionList = 64, Details = 65, Dialog = 66, DisclosureTriangle = 67, Document = 68, EmbeddedObject = 69, Emphasis = 70, Feed = 71, FigureCaption = 72, Figure = 73, Footer = 74, Form = 75, Grid = 76, GridCell = 77, Group = 78, Header = 79, Heading = 80, Iframe = 81, IframePresentational = 82, ImeCandidate = 83, Keyboard = 84, Legend = 85, LineBreak = 86, ListBox = 87, Log = 88, Main = 89, Mark = 90, Marquee = 91, Math = 92, MenuBar = 93, MenuItemCheckBox = 94, MenuItemRadio = 95, MenuListPopup = 96, Meter = 97, Navigation = 98, Note = 99, PluginObject = 100, ProgressIndicator = 101, RadioGroup = 102, Region = 103, RootWebArea = 104, Ruby = 105, RubyAnnotation = 106, ScrollBar = 107, ScrollView = 108, Search = 109, Section = 110, SectionFooter = 111, SectionHeader = 112, Slider = 113, SpinButton = 114, Splitter = 115, Status = 116, Strong = 117, Suggestion = 118, SvgRoot = 119, Tab = 120, TabList = 121, TabPanel = 122, Term = 123, Time = 124, Timer = 125, TitleBar = 126, Toolbar = 127, Tooltip = 128, Tree = 129, TreeGrid = 130, Video = 131, WebView = 132, Window = 133, PdfActionableHighlight = 134, PdfRoot = 135, GraphicsDocument = 136, GraphicsObject = 137, GraphicsSymbol = 138, DocAbstract = 139, DocAcknowledgements = 140, DocAfterword = 141, DocAppendix = 142, DocBackLink = 143, DocBiblioEntry = 144, DocBibliography = 145, DocBiblioRef = 146, DocChapter = 147, DocColophon = 148, DocConclusion = 149, DocCover = 150, DocCredit = 151, DocCredits = 152, DocDedication = 153, DocEndnote = 154, DocEndnotes = 155, DocEpigraph = 156, DocEpilogue = 157, DocErrata = 158, DocExample = 159, DocFootnote = 160, DocForeword = 161, DocGlossary = 162, DocGlossRef = 163, DocIndex = 164, DocIntroduction = 165, DocNoteRef = 166, DocNotice = 167, DocPageBreak = 168, DocPageFooter = 169, DocPageHeader = 170, DocPageList = 171, DocPart = 172, DocPreface = 173, DocPrologue = 174, DocPullquote = 175, DocQna = 176, DocSubtitle = 177, DocTip = 178, DocToc = 179, ListGrid = 180, Terminal = 181,
}

Variantsยง

ยง

Unknown = 0

ยง

TextRun = 1

ยง

Cell = 2

ยง

Label = 3

ยง

Image = 4

ยง

Row = 6

ยง

ListItem = 7

ยง

ListMarker = 8

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

ยง

TreeItem = 9

ยง

ListBoxOption = 10

ยง

MenuItem = 11

ยง

MenuListOption = 12

ยง

Paragraph = 13

ยง

GenericContainer = 14

A generic container that should be ignored by assistive technologies and filtered out of platform accessibility trees. Equivalent to the ARIA none or presentation role, or to an HTML div with no role.

ยง

CheckBox = 15

ยง

RadioButton = 16

ยง

TextInput = 17

ยง

Button = 18

ยง

DefaultButton = 19

ยง

Pane = 20

ยง

RowHeader = 21

ยง

ColumnHeader = 22

ยง

RowGroup = 23

ยง

List = 24

ยง

Table = 25

ยง

LayoutTableCell = 26

ยง

LayoutTableRow = 27

ยง

LayoutTable = 28

ยง

Switch = 29

ยง

Menu = 30

ยง

MultilineTextInput = 31

ยง

SearchInput = 32

ยง

DateInput = 33

ยง

DateTimeInput = 34

ยง

WeekInput = 35

ยง

MonthInput = 36

ยง

TimeInput = 37

ยง

EmailInput = 38

ยง

NumberInput = 39

ยง

PasswordInput = 40

ยง

PhoneNumberInput = 41

ยง

UrlInput = 42

ยง

Abbr = 43

ยง

Alert = 44

ยง

AlertDialog = 45

ยง

Application = 46

ยง

Article = 47

ยง

Audio = 48

ยง

Banner = 49

ยง

Blockquote = 50

ยง

Canvas = 51

ยง

Caption = 52

ยง

Caret = 53

ยง

Code = 54

ยง

ColorWell = 55

ยง

ComboBox = 56

ยง

EditableComboBox = 57

ยง

Complementary = 58

ยง

Comment = 59

ยง

ContentDeletion = 60

ยง

ContentInsertion = 61

ยง

ContentInfo = 62

ยง

Definition = 63

ยง

DescriptionList = 64

ยง

Details = 65

ยง

Dialog = 66

ยง

DisclosureTriangle = 67

ยง

Document = 68

ยง

EmbeddedObject = 69

ยง

Emphasis = 70

ยง

Feed = 71

ยง

FigureCaption = 72

ยง

Figure = 73

ยง

Footer = 74

ยง

Form = 75

ยง

Grid = 76

ยง

GridCell = 77

ยง

Group = 78

ยง

Header = 79

ยง

Heading = 80

ยง

Iframe = 81

ยง

IframePresentational = 82

ยง

ImeCandidate = 83

ยง

Keyboard = 84

ยง

Legend = 85

ยง

LineBreak = 86

ยง

ListBox = 87

ยง

Log = 88

ยง

Main = 89

ยง

Mark = 90

ยง

Marquee = 91

ยง

Math = 92

ยง

MenuBar = 93

ยง

MenuItemCheckBox = 94

ยง

MenuItemRadio = 95

ยง

MenuListPopup = 96

ยง

Meter = 97

ยง

Navigation = 98

ยง

Note = 99

ยง

PluginObject = 100

ยง

ProgressIndicator = 101

ยง

RadioGroup = 102

ยง

Region = 103

ยง

RootWebArea = 104

ยง

Ruby = 105

ยง

RubyAnnotation = 106

ยง

ScrollBar = 107

ยง

ScrollView = 108

ยง

Search = 109

ยง

Section = 110

ยง

SectionFooter = 111

ยง

SectionHeader = 112

ยง

Slider = 113

ยง

SpinButton = 114

ยง

Splitter = 115

ยง

Status = 116

ยง

Strong = 117

ยง

Suggestion = 118

ยง

SvgRoot = 119

ยง

Tab = 120

ยง

TabList = 121

ยง

TabPanel = 122

ยง

Term = 123

ยง

Time = 124

ยง

Timer = 125

ยง

TitleBar = 126

ยง

Toolbar = 127

ยง

Tooltip = 128

ยง

Tree = 129

ยง

TreeGrid = 130

ยง

Video = 131

ยง

WebView = 132

ยง

Window = 133

ยง

PdfActionableHighlight = 134

ยง

PdfRoot = 135

ยง

GraphicsDocument = 136

ยง

GraphicsObject = 137

ยง

GraphicsSymbol = 138

ยง

DocAbstract = 139

ยง

DocAcknowledgements = 140

ยง

DocAfterword = 141

ยง

DocAppendix = 142

ยง

DocBiblioEntry = 144

ยง

DocBibliography = 145

ยง

DocBiblioRef = 146

ยง

DocChapter = 147

ยง

DocColophon = 148

ยง

DocConclusion = 149

ยง

DocCover = 150

ยง

DocCredit = 151

ยง

DocCredits = 152

ยง

DocDedication = 153

ยง

DocEndnote = 154

ยง

DocEndnotes = 155

ยง

DocEpigraph = 156

ยง

DocEpilogue = 157

ยง

DocErrata = 158

ยง

DocExample = 159

ยง

DocFootnote = 160

ยง

DocForeword = 161

ยง

DocGlossary = 162

ยง

DocGlossRef = 163

ยง

DocIndex = 164

ยง

DocIntroduction = 165

ยง

DocNoteRef = 166

ยง

DocNotice = 167

ยง

DocPageBreak = 168

ยง

DocPageFooter = 169

ยง

DocPageHeader = 170

ยง

DocPageList = 171

ยง

DocPart = 172

ยง

DocPreface = 173

ยง

DocPrologue = 174

ยง

DocPullquote = 175

ยง

DocQna = 176

ยง

DocSubtitle = 177

ยง

DocTip = 178

ยง

DocToc = 179

ยง

ListGrid = 180

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.

ยง

Terminal = 181

This is just like a multi-line document, but signals that assistive technologies should implement behavior specific to a VT-100-style terminal.