1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
2 /* ***** BEGIN LICENSE BLOCK *****
3 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
5 * The contents of this file are subject to the Mozilla Public License Version
6 * 1.1 (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 * http://www.mozilla.org/MPL/
10 * Software distributed under the License is distributed on an "AS IS" basis,
11 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
12 * for the specific language governing rights and limitations under the
15 * The Original Code is mozilla.org code.
17 * The Initial Developer of the Original Code is
19 * Portions created by the Initial Developer are Copyright (C) 2007
20 * the Initial Developer. All Rights Reserved.
23 * Alexander Surkov <surkov.alexander@gmail.com>
25 * Alternatively, the contents of this file may be used under the terms of
26 * either the GNU General Public License Version 2 or later (the "GPL"), or
27 * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
28 * in which case the provisions of the GPL or the LGPL are applicable instead
29 * of those above. If you wish to allow use of your version of this file only
30 * under the terms of either the GPL or the LGPL, and not to allow others to
31 * use your version of this file under the terms of the MPL, indicate your
32 * decision by deleting the provisions above and replace them with the notice
33 * and other provisions required by the GPL or the LGPL. If you do not delete
34 * the provisions above, a recipient may use your version of this file under
35 * the terms of any one of the MPL, the GPL or the LGPL.
37 * ***** END LICENSE BLOCK ***** */
39 #include
"nsISupports.idl"
42 * Defines cross platform (Gecko) roles.
44 * @note - When adding a new role, be sure to also add it to nsRoleMap.h for
47 [scriptable
, uuid(8c0f68f8
-164a
-4078-a9ee
-36a7d180f0e4
)]
48 interface nsIAccessibleRole
: nsISupports
51 * Used when accessible hans't strong defined role.
53 const unsigned long ROLE_NOTHING
= 0;
56 * Represents a title or caption bar for a window. It is used by MSAA only,
57 * supported automatically by MS Windows.
59 const unsigned long ROLE_TITLEBAR
= 1;
62 * Represents the menu bar (positioned beneath the title bar of a window)
63 * from which menus are selected by the user. The role is used by
64 * xul:menubar or role="menubar".
66 const unsigned long ROLE_MENUBAR
= 2;
69 * Represents a vertical or horizontal scroll bar, which is part of the client
70 * area or used in a control.
72 const unsigned long ROLE_SCROLLBAR
= 3;
75 * Represents a special mouse pointer, which allows a user to manipulate user
76 * interface elements such as windows. For example, a user clicks and drags
77 * a sizing grip in the lower-right corner of a window to resize it.
79 const unsigned long ROLE_GRIP
= 4;
82 * Represents a system sound, which is associated with various system events.
84 const unsigned long ROLE_SOUND
= 5;
87 * Represents the system mouse pointer.
89 const unsigned long ROLE_CURSOR
= 6;
92 * Represents the system caret. The role is supported for caret.
94 const unsigned long ROLE_CARET
= 7;
97 * Represents an alert or a condition that a user should be notified about.
98 * Assistive Technologies typically respond to the role by reading the entire
99 * onscreen contents of containers advertising this role. Should be used for
100 * warning dialogs, etc. The role is used by xul:browsermessage,
101 * role="alert", xforms:message.
103 const unsigned long ROLE_ALERT
= 8;
106 * Represents the window frame, which contains child objects such as
107 * a title bar, client, and other objects contained in a window. The role
108 * is supported automatically by MS Windows.
110 const unsigned long ROLE_WINDOW
= 9;
113 * A sub-document (<frame> or <iframe>)
115 const unsigned long ROLE_INTERNAL_FRAME
= 10;
118 * Represents a menu, which presents a list of options from which the user can
119 * make a selection to perform an action. It is used for role="menu".
121 const unsigned long ROLE_MENUPOPUP
= 11;
124 * Represents a menu item, which is an entry in a menu that a user can choose
125 * to carry out a command, select an option. It is used for xul:menuitem,
128 const unsigned long ROLE_MENUITEM
= 12;
131 * Represents a ToolTip that provides helpful hints.
133 const unsigned long ROLE_TOOLTIP
= 13;
136 * Represents a main window for an application. It is used for
137 * role="application". Also refer to ROLE_APP_ROOT
139 const unsigned long ROLE_APPLICATION
= 14;
142 * Represents a document window. A document window is always contained within
143 * an application window. It is used for role="document".
145 const unsigned long ROLE_DOCUMENT
= 15;
148 * Represents a pane within a frame or document window. Users can navigate
149 * between panes and within the contents of the current pane, but cannot
150 * navigate between items in different panes. Thus, panes represent a level
151 * of grouping lower than frame windows or documents, but above individual
152 * controls. It is used for the first child of a <frame> or <iframe>.
154 const unsigned long ROLE_PANE
= 16;
157 * Represents a graphical image used to represent data.
159 const unsigned long ROLE_CHART
= 17;
162 * Represents a dialog box or message box. It is used for xul:dialog,
165 const unsigned long ROLE_DIALOG
= 18;
168 * Represents a window border.
170 const unsigned long ROLE_BORDER
= 19;
173 * Logically groups other objects. There is not always a parent-child
174 * relationship between the grouping object and the objects it contains. It
175 * is used for html:textfield, xul:groupbox, role="group".
177 const unsigned long ROLE_GROUPING
= 20;
180 * Used to visually divide a space into two regions, such as a separator menu
181 * item or a bar that divides split panes within a window. It is used for
182 * xul:separator, html:hr, role="separator".
184 const unsigned long ROLE_SEPARATOR
= 21;
187 * Represents a toolbar, which is a grouping of controls (push buttons or
188 * toggle buttons) that provides easy access to frequently used features. It
189 * is used for xul:toolbar, role="toolbar".
191 const unsigned long ROLE_TOOLBAR
= 22;
194 * Represents a status bar, which is an area at the bottom of a window that
195 * displays information about the current operation, state of the application,
196 * or selected object. The status bar has multiple fields, which display
197 * different kinds of information. It is used for xul:statusbar.
199 const unsigned long ROLE_STATUSBAR
= 23;
202 * Represents a table that contains rows and columns of cells, and optionally,
203 * row headers and column headers. It is used for html:table,
204 * role="grid". Also refer to the following roles: ROLE_COLUMNHEADER,
205 * ROLE_ROWHEADER, ROLE_COLUMN, ROLE_ROW, ROLE_CELL.
207 const unsigned long ROLE_TABLE
= 24;
210 * Represents a column header, providing a visual label for a column in
211 * a table. It is used for XUL tree column headers, html:th,
212 * role="colheader". Also refer to ROLE_TABLE.
214 const unsigned long ROLE_COLUMNHEADER
= 25;
217 * Represents a row header, which provides a visual label for a table row.
218 * It is used for role="rowheader". Also, see ROLE_TABLE.
220 const unsigned long ROLE_ROWHEADER
= 26;
223 * Represents a column of cells within a table. Also, see ROLE_TABLE.
225 const unsigned long ROLE_COLUMN
= 27;
228 * Represents a row of cells within a table. Also, see ROLE_TABLE.
230 const unsigned long ROLE_ROW
= 28;
233 * Represents a cell within a table. Is is used for html:td,
234 * role="gridcell". Also, see ROLE_TABLE.
236 const unsigned long ROLE_CELL
= 29;
239 * Represents a link to something else. This object might look like text or
240 * a graphic, but it acts like a button. It is used for
241 * xul:label@class="text-link", html:a, html:area,
242 * xforms:trigger@appearance="minimal".
244 const unsigned long ROLE_LINK
= 30;
247 * Displays a Help topic in the form of a ToolTip or Help balloon.
249 const unsigned long ROLE_HELPBALLOON
= 31;
252 * Represents a cartoon-like graphic object, such as Microsoft Office
253 * Assistant, which is displayed to provide help to users of an application.
255 const unsigned long ROLE_CHARACTER
= 32;
258 * Represents a list box, allowing the user to select one or more items. It
259 * is used for xul:listbox, html:select@size, role="list". See also
262 const unsigned long ROLE_LIST
= 33;
265 * Represents an item in a list. See also ROLE_LIST.
267 const unsigned long ROLE_LISTITEM
= 34;
270 * Represents an outline or tree structure, such as a tree view control,
271 * that displays a hierarchical list and allows the user to expand and
272 * collapse branches. Is is used for role="tree".
274 const unsigned long ROLE_OUTLINE
= 35;
277 * Represents an item in an outline or tree structure. It is used for
280 const unsigned long ROLE_OUTLINEITEM
= 36;
283 * Represents a page tab, it is a child of a page tab list. It is used for
284 * xul:tab, role="treeitem". Also refer to ROLE_PAGETABLIST.
286 const unsigned long ROLE_PAGETAB
= 37;
289 * Represents a property sheet. It is used for xul:tabpanel,
292 const unsigned long ROLE_PROPERTYPAGE
= 38;
295 * Represents an indicator, such as a pointer graphic, that points to the
298 const unsigned long ROLE_INDICATOR
= 39;
301 * Represents a picture. Is is used for xul:image, html:img.
303 const unsigned long ROLE_GRAPHIC
= 40;
306 * Represents read-only text, such as labels for other controls or
307 * instructions in a dialog box. Static text cannot be modified or selected.
308 * Is is used for xul:label, xul:description, html:lablel,
309 * role="label" or role="description", xforms:output.
311 const unsigned long ROLE_STATICTEXT
= 41;
314 * Represents selectable text that allows edits or is designated read-only.
316 const unsigned long ROLE_TEXT_LEAF
= 42;
319 * Represents a push button control. It is used for xul:button, html:button,
320 * role="button", xforms:trigger, xforms:submit.
322 const unsigned long ROLE_PUSHBUTTON
= 43;
325 * Represents a check box control. It is used for xul:checkbox,
326 * html:input@type="checkbox", role="checkbox", boolean xforms:input.
328 const unsigned long ROLE_CHECKBUTTON
= 44;
331 * Represents an option button, also called a radio button. It is one of a
332 * group of mutually exclusive options. All objects sharing a single parent
333 * that have this attribute are assumed to be part of single mutually
334 * exclusive group. It is used for xul:radio, html:input@type="radio",
337 const unsigned long ROLE_RADIOBUTTON
= 45;
340 * Represents a combo box; an edit control with an associated list box that
341 * provides a set of predefined choices. It is used for html:select,
342 * xul:menulist, role="combobox".
344 const unsigned long ROLE_COMBOBOX
= 46;
347 * Represents the calendar control. It is used for date xforms:input.
349 const unsigned long ROLE_DROPLIST
= 47;
352 * Represents a progress bar, dynamically showing the user the percent
353 * complete of an operation in progress. It is used for xul:progressmeter,
354 * role="progressbar".
356 const unsigned long ROLE_PROGRESSBAR
= 48;
359 * Represents a dial or knob whose purpose is to allow a user to set a value.
361 const unsigned long ROLE_DIAL
= 49;
364 * Represents a hot-key field that allows the user to enter a combination or
365 * sequence of keystrokes.
367 const unsigned long ROLE_HOTKEYFIELD
= 50;
370 * Represents a slider, which allows the user to adjust a setting in given
371 * increments between minimum and maximum values. It is used by xul:scale,
372 * role="slider", xforms:range.
374 const unsigned long ROLE_SLIDER
= 51;
377 * Represents a spin box, which is a control that allows the user to increment
378 * or decrement the value displayed in a separate "buddy" control associated
379 * with the spin box. It is used for xul:spinbuttons.
381 const unsigned long ROLE_SPINBUTTON
= 52;
384 * Represents a graphical image used to diagram data. It is used for svg:svg.
386 const unsigned long ROLE_DIAGRAM
= 53;
389 * Represents an animation control, which contains content that changes over
390 * time, such as a control that displays a series of bitmap frames.
392 const unsigned long ROLE_ANIMATION
= 54;
395 * Represents a mathematical equation. It is used by MATHML, where there is a
396 * rich DOM subtree for an equation. Use ROLE_FLAT_EQUATION for <img role="math" alt="[TeX]"/>
398 const unsigned long ROLE_EQUATION
= 55;
401 * Represents a button that drops down a list of items.
403 const unsigned long ROLE_BUTTONDROPDOWN
= 56;
406 * Represents a button that drops down a menu.
408 const unsigned long ROLE_BUTTONMENU
= 57;
411 * Represents a button that drops down a grid. It is used for xul:colorpicker.
413 const unsigned long ROLE_BUTTONDROPDOWNGRID
= 58;
416 * Represents blank space between other objects.
418 const unsigned long ROLE_WHITESPACE
= 59;
421 * Represents a container of page tab controls. Is it used for xul:tabs,
422 * DHTML: role="tabs". Also refer to ROLE_PAGETAB.
424 const unsigned long ROLE_PAGETABLIST
= 60;
427 * Represents a control that displays time.
429 const unsigned long ROLE_CLOCK
= 61;
432 * Represents a button on a toolbar that has a drop-down list icon directly
433 * adjacent to the button.
435 const unsigned long ROLE_SPLITBUTTON
= 62;
438 * Represents an edit control designed for an Internet Protocol (IP) address.
439 * The edit control is divided into sections for the different parts of the
442 const unsigned long ROLE_IPADDRESS
= 63;
445 * Represents a label control that has an accelerator.
447 const unsigned long ROLE_ACCEL_LABEL
= 64;
450 * Represents an arrow in one of the four cardinal directions.
452 const unsigned long ROLE_ARROW
= 65;
455 * Represents a control that can be drawn into and is used to trap events.
456 * It is used for html:canvas.
458 const unsigned long ROLE_CANVAS
= 66;
461 * Represents a menu item with a check box.
463 const unsigned long ROLE_CHECK_MENU_ITEM
= 67;
466 * Represents a specialized dialog that lets the user choose a color.
468 const unsigned long ROLE_COLOR_CHOOSER
= 68;
471 * Represents control whose purpose is to allow a user to edit a date.
473 const unsigned long ROLE_DATE_EDITOR
= 69;
476 * An iconified internal frame in an ROLE_DESKTOP_PANE. Also refer to
477 * ROLE_INTERNAL_FRAME.
479 const unsigned long ROLE_DESKTOP_ICON
= 70;
482 * A desktop pane. A pane that supports internal frames and iconified
483 * versions of those internal frames.
485 const unsigned long ROLE_DESKTOP_FRAME
= 71;
488 * A directory pane. A pane that allows the user to navigate through
489 * and select the contents of a directory. May be used by a file chooser.
490 * Also refer to ROLE_FILE_CHOOSER.
492 const unsigned long ROLE_DIRECTORY_PANE
= 72;
495 * A file chooser. A specialized dialog that displays the files in the
496 * directory and lets the user select a file, browse a different directory,
497 * or specify a filename. May use the directory pane to show the contents of
498 * a directory. Also refer to ROLE_DIRECTORY_PANE.
500 const unsigned long ROLE_FILE_CHOOSER
= 73;
503 * A font chooser. A font chooser is a component that lets the user pick
504 * various attributes for fonts.
506 const unsigned long ROLE_FONT_CHOOSER
= 74;
509 * Frame role. A top level window with a title bar, border, menu bar, etc.
510 * It is often used as the primary window for an application.
512 const unsigned long ROLE_CHROME_WINDOW
= 75;
515 * A glass pane. A pane that is guaranteed to be painted on top of all
516 * panes beneath it. Also refer to ROLE_ROOT_PANE.
518 const unsigned long ROLE_GLASS_PANE
= 76;
521 * A document container for HTML, whose children represent the document
524 const unsigned long ROLE_HTML_CONTAINER
= 77;
527 * A small fixed size picture, typically used to decorate components.
529 const unsigned long ROLE_ICON
= 78;
532 * Presents an icon or short string in an interface.
534 const unsigned long ROLE_LABEL
= 79;
537 * A layered pane. A specialized pane that allows its children to be drawn
538 * in layers, providing a form of stacking order. This is usually the pane
539 * that holds the menu bar as well as the pane that contains most of the
540 * visual components in a window. Also refer to ROLE_GLASS_PANE and
543 const unsigned long ROLE_LAYERED_PANE
= 80;
546 * A specialized pane whose primary use is inside a dialog.
548 const unsigned long ROLE_OPTION_PANE
= 81;
551 * A text object uses for passwords, or other places where the text content
552 * is not shown visibly to the user.
554 const unsigned long ROLE_PASSWORD_TEXT
= 82;
557 * A temporary window that is usually used to offer the user a list of
558 * choices, and then hides when the user selects one of those choices.
560 const unsigned long ROLE_POPUP_MENU
= 83;
563 * A radio button that is a menu item.
565 const unsigned long ROLE_RADIO_MENU_ITEM
= 84;
568 * A root pane. A specialized pane that has a glass pane and a layered pane
569 * as its children. Also refer to ROLE_GLASS_PANE and ROLE_LAYERED_PANE.
571 const unsigned long ROLE_ROOT_PANE
= 85;
574 * A scroll pane. An object that allows a user to incrementally view a large
575 * amount of information. Its children can include scroll bars and a
576 * viewport. Also refer to ROLE_VIEW_PORT.
578 const unsigned long ROLE_SCROLL_PANE
= 86;
581 * A split pane. A specialized panel that presents two other panels at the
582 * same time. Between the two panels is a divider the user can manipulate to
583 * make one panel larger and the other panel smaller.
585 const unsigned long ROLE_SPLIT_PANE
= 87;
588 * The header for a column of a table.
589 * XXX: it looks this role is dupe of ROLE_COLUMNHEADER.
591 const unsigned long ROLE_TABLE_COLUMN_HEADER
= 88;
594 * The header for a row of a table.
595 * XXX: it looks this role is dupe of ROLE_ROWHEADER
597 const unsigned long ROLE_TABLE_ROW_HEADER
= 89;
600 * A menu item used to tear off and reattach its menu.
602 const unsigned long ROLE_TEAR_OFF_MENU_ITEM
= 90;
605 * Represents an accessible terminal.
607 const unsigned long ROLE_TERMINAL
= 91;
610 * Collection of objects that constitute a logical text entity.
612 const unsigned long ROLE_TEXT_CONTAINER
= 92;
615 * A toggle button. A specialized push button that can be checked or
616 * unchecked, but does not provide a separate indicator for the current state.
618 const unsigned long ROLE_TOGGLE_BUTTON
= 93;
621 * Representas a control that is capable of expanding and collapsing rows as
622 * well as showing multiple columns of data.
623 * XXX: it looks like this role is dupe of ROLE_OUTLINE.
625 const unsigned long ROLE_TREE_TABLE
= 94;
628 * A viewport. An object usually used in a scroll pane. It represents the
629 * portion of the entire data that the user can see. As the user manipulates
630 * the scroll bars, the contents of the viewport can change. Also refer to
633 const unsigned long ROLE_VIEWPORT
= 95;
636 * Header of a document page. Also refer to ROLE_FOOTER.
638 const unsigned long ROLE_HEADER
= 96;
641 * Footer of a document page. Also refer to ROLE_HEADER.
643 const unsigned long ROLE_FOOTER
= 97;
646 * A paragraph of text.
648 const unsigned long ROLE_PARAGRAPH
= 98;
651 * A ruler such as those used in word processors.
653 const unsigned long ROLE_RULER
= 99;
656 * A text entry having dialog or list containing items for insertion into
657 * an entry widget, for instance a list of words for completion of a
658 * text entry. It is used for xul:textbox@autocomplete
660 const unsigned long ROLE_AUTOCOMPLETE
= 100;
663 * An editable text object in a toolbar.
665 const unsigned long ROLE_EDITBAR
= 101;
668 * An control whose textual content may be entered or modified by the user.
670 const unsigned long ROLE_ENTRY
= 102;
673 * A caption describing another object.
675 const unsigned long ROLE_CAPTION
= 103;
678 * A visual frame or container which contains a view of document content.
679 * Document frames may occur within another Document instance, in which case
680 * the second document may be said to be embedded in the containing instance.
681 * HTML frames are often ROLE_DOCUMENT_FRAME. Either this object, or a
682 * singleton descendant, should implement the Document interface.
684 const unsigned long ROLE_DOCUMENT_FRAME
= 104;
689 const unsigned long ROLE_HEADING
= 105;
692 * An object representing a page of document content. It is used in documents
693 * which are accessed by the user on a page by page basis.
695 const unsigned long ROLE_PAGE
= 106;
698 * A container of document content. An example of the use of this role is to
699 * represent an html:div.
701 const unsigned long ROLE_SECTION
= 107;
704 * An object which is redundant with another object in the accessible
705 * hierarchy. ATs typically ignore objects with this role.
707 const unsigned long ROLE_REDUNDANT_OBJECT
= 108;
710 * A container of form controls. An example of the use of this role is to
711 * represent an html:form.
713 const unsigned long ROLE_FORM
= 109;
716 * An object which is used to allow input of characters not found on a
717 * keyboard, such as the input of Chinese characters on a Western keyboard.
719 const unsigned long ROLE_IME
= 110;
722 * XXX: document this.
724 const unsigned long ROLE_APP_ROOT
= 111;
727 * Represents a menu item, which is an entry in a menu that a user can choose
728 * to display another menu.
730 const unsigned long ROLE_PARENT_MENUITEM
= 112;
733 * A calendar that allows the user to select a date.
735 const unsigned long ROLE_CALENDAR
= 113;
738 * A list of items that is shown by combobox.
740 const unsigned long ROLE_COMBOBOX_LIST
= 114;
743 * A item of list that is shown by combobox;
745 const unsigned long ROLE_COMBOBOX_OPTION
= 115;
748 * An image map -- has child links representing the areas
750 const unsigned long ROLE_IMAGE_MAP
= 116;
753 * An option in a listbox
755 const unsigned long ROLE_OPTION
= 117;
758 * A rich option in a listbox, it can have other widgets as children
760 const unsigned long ROLE_RICH_OPTION
= 118;
765 const unsigned long ROLE_LISTBOX
= 119;
768 * Represents a mathematical equation in the accessible name
770 const unsigned long ROLE_FLAT_EQUATION
= 120;
773 * It's not role actually. This contanst is important to help ensure
774 * nsRoleMap's are synchronized.
776 const unsigned long ROLE_LAST_ENTRY
= 121;